From 937246f64ce476d199183d7309a7a3044cc63207 Mon Sep 17 00:00:00 2001 From: gocha Date: Wed, 22 Jul 2009 04:06:10 +0000 Subject: [PATCH] add my 0.9.2+, a improved version of 0.9.2 rerecording (Unfortunately, I maintained only the windows port and core, because simply I don't use other ports) --- desmume/AUTHORS => AUTHORS | 20 +- desmume/COPYING => COPYING | 0 desmume/ChangeLog => ChangeLog | 815 +- desmume/Makefile.am => Makefile.am | 0 desmume/NEWS => NEWS | 0 desmume/README => README | 0 desmume/README.LIN => README.LIN | 0 desmume/README.MAC => README.MAC | 0 .../README.TRANSLATION => README.TRANSLATION | 0 README.WIN | 503 + desmume/TODO => TODO | 0 desmume/autogen.sh => autogen.sh | 0 .../default.apspec.in | 0 desmume/compile => compile | 0 desmume/configure.ac => configure.ac | 57 +- desmume/README.WIN | 672 - desmume/dsv.txt | 39 - desmume/po/zh_CN.po | 265 - desmume/src/GPU_osd.cpp | 429 - desmume/src/PACKED_END.h | 3 - desmume/src/addons/guitarGrip.cpp | 79 - desmume/src/agg2d.h | 929 - desmume/src/agg2d.inl | 1977 -- desmume/src/aggdraw.cpp | 699 - desmume/src/aggdraw.h | 468 - .../Chinese.lproj/Localizable.strings | Bin 8418 -> 0 bytes .../Chinese.lproj/MainMenu.nib/info.nib | 16 - .../MainMenu.nib/keyedobjects.nib | Bin 4850 -> 0 bytes .../Italian.lproj/MainMenu.nib/classes.nib | 19 - desmume/src/fat.h | 85 - desmume/src/gtk/cheatsGTK.cpp | 437 - desmume/src/gtk/cheatsGTK.h | 29 - desmume/src/gtk/main.h | 7 - desmume/src/matrix.h | 317 - desmume/src/mc.cpp | 817 - desmume/src/mic.cpp | 55 - desmume/src/mic.h | 42 - desmume/src/mic_alsa.cpp | 148 - desmume/src/path.h | 360 - desmume/src/version.h | 86 - desmume/src/windows/DeSmuME_2010.sln | 23 - desmume/src/windows/DeSmuME_2010.vcxproj | 393 - desmume/src/windows/agg/agg-2.5.lib | Bin 878718 -> 0 bytes desmume/src/windows/agg/agg-2.5.sln | 20 - desmume/src/windows/agg/agg-2.5.vcproj | 880 - .../src/windows/agg/examples/pixel_formats.h | 184 - .../agg/font_freetype/agg_font_freetype.cpp | 1155 -- .../agg/font_freetype/agg_font_freetype.h | 201 - .../agg/font_win32_tt/agg_font_win32_tt.cpp | 946 - .../agg/font_win32_tt/agg_font_win32_tt.h | 223 - .../windows/agg/include/agg_alpha_mask_u8.h | 505 - desmume/src/windows/agg/include/agg_arc.h | 79 - desmume/src/windows/agg/include/agg_array.h | 1129 -- .../src/windows/agg/include/agg_arrowhead.h | 88 - desmume/src/windows/agg/include/agg_basics.h | 539 - .../src/windows/agg/include/agg_bezier_arc.h | 163 - .../windows/agg/include/agg_bitset_iterator.h | 63 - desmume/src/windows/agg/include/agg_blur.h | 1303 -- .../windows/agg/include/agg_bounding_rect.h | 122 - desmume/src/windows/agg/include/agg_bspline.h | 81 - .../agg/include/agg_clip_liang_barsky.h | 339 - .../src/windows/agg/include/agg_color_gray.h | 423 - .../src/windows/agg/include/agg_color_rgba.h | 756 - desmume/src/windows/agg/include/agg_config.h | 44 - .../agg/include/agg_conv_adaptor_vcgen.h | 166 - .../agg/include/agg_conv_adaptor_vpgen.h | 168 - .../windows/agg/include/agg_conv_bspline.h | 58 - .../agg/include/agg_conv_clip_polygon.h | 72 - .../agg/include/agg_conv_clip_polyline.h | 72 - .../agg/include/agg_conv_close_polygon.h | 134 - .../src/windows/agg/include/agg_conv_concat.h | 82 - .../windows/agg/include/agg_conv_contour.h | 71 - .../src/windows/agg/include/agg_conv_curve.h | 206 - .../src/windows/agg/include/agg_conv_dash.h | 74 - .../src/windows/agg/include/agg_conv_gpc.h | 441 - .../src/windows/agg/include/agg_conv_marker.h | 154 - .../agg/include/agg_conv_marker_adaptor.h | 60 - .../agg/include/agg_conv_segmentator.h | 57 - .../agg/include/agg_conv_shorten_path.h | 59 - .../agg/include/agg_conv_smooth_poly1.h | 86 - .../src/windows/agg/include/agg_conv_stroke.h | 79 - .../windows/agg/include/agg_conv_transform.h | 74 - .../agg/include/agg_conv_unclose_polygon.h | 61 - desmume/src/windows/agg/include/agg_curves.h | 701 - .../src/windows/agg/include/agg_dda_line.h | 295 - desmume/src/windows/agg/include/agg_ellipse.h | 128 - .../agg/include/agg_ellipse_bresenham.h | 118 - .../agg/include/agg_embedded_raster_fonts.h | 68 - .../agg/include/agg_font_cache_manager.h | 418 - .../windows/agg/include/agg_gamma_functions.h | 132 - .../src/windows/agg/include/agg_gamma_lut.h | 130 - .../agg/include/agg_glyph_raster_bin.h | 164 - .../windows/agg/include/agg_gradient_lut.h | 253 - .../src/windows/agg/include/agg_gsv_text.h | 158 - .../windows/agg/include/agg_image_accessors.h | 490 - .../windows/agg/include/agg_image_filters.h | 453 - .../windows/agg/include/agg_line_aa_basics.h | 199 - desmume/src/windows/agg/include/agg_math.h | 446 - .../src/windows/agg/include/agg_math_stroke.h | 531 - .../src/windows/agg/include/agg_path_length.h | 75 - .../windows/agg/include/agg_path_storage.h | 1554 -- .../agg/include/agg_path_storage_integer.h | 304 - .../agg/include/agg_pattern_filters_rgba.h | 132 - .../agg/include/agg_pixfmt_amask_adaptor.h | 249 - .../src/windows/agg/include/agg_pixfmt_gray.h | 679 - .../src/windows/agg/include/agg_pixfmt_rgb.h | 869 - .../agg/include/agg_pixfmt_rgb_packed.h | 1318 -- .../src/windows/agg/include/agg_pixfmt_rgba.h | 2911 --- .../agg/include/agg_pixfmt_transposer.h | 166 - .../agg/include/agg_rasterizer_cells_aa.h | 764 - .../agg/include/agg_rasterizer_compound_aa.h | 698 - .../agg/include/agg_rasterizer_outline.h | 157 - .../agg/include/agg_rasterizer_outline_aa.h | 609 - .../agg/include/agg_rasterizer_scanline_aa.h | 520 - .../agg/include/agg_rasterizer_sl_clip.h | 361 - .../windows/agg/include/agg_renderer_base.h | 723 - .../agg/include/agg_renderer_markers.h | 711 - .../windows/agg/include/agg_renderer_mclip.h | 349 - .../agg/include/agg_renderer_outline_aa.h | 1847 -- .../agg/include/agg_renderer_outline_image.h | 1023 - .../agg/include/agg_renderer_primitives.h | 229 - .../agg/include/agg_renderer_raster_text.h | 273 - .../agg/include/agg_renderer_scanline.h | 861 - .../agg/include/agg_rendering_buffer.h | 305 - .../include/agg_rendering_buffer_dynarow.h | 142 - .../windows/agg/include/agg_rounded_rect.h | 77 - .../windows/agg/include/agg_scanline_bin.h | 269 - .../include/agg_scanline_boolean_algebra.h | 1576 -- .../src/windows/agg/include/agg_scanline_p.h | 334 - .../agg/include/agg_scanline_storage_aa.h | 824 - .../agg/include/agg_scanline_storage_bin.h | 595 - .../src/windows/agg/include/agg_scanline_u.h | 508 - .../windows/agg/include/agg_shorten_path.h | 75 - .../src/windows/agg/include/agg_simul_eq.h | 153 - .../windows/agg/include/agg_span_allocator.h | 63 - .../windows/agg/include/agg_span_converter.h | 65 - .../windows/agg/include/agg_span_gouraud.h | 181 - .../agg/include/agg_span_gouraud_gray.h | 250 - .../agg/include/agg_span_gouraud_rgba.h | 286 - .../windows/agg/include/agg_span_gradient.h | 373 - .../agg/include/agg_span_gradient_alpha.h | 135 - .../agg/include/agg_span_image_filter.h | 252 - .../agg/include/agg_span_image_filter_gray.h | 757 - .../agg/include/agg_span_image_filter_rgb.h | 901 - .../agg/include/agg_span_image_filter_rgba.h | 929 - .../include/agg_span_interpolator_adaptor.h | 86 - .../include/agg_span_interpolator_linear.h | 241 - .../agg/include/agg_span_interpolator_persp.h | 472 - .../agg/include/agg_span_interpolator_trans.h | 101 - .../agg/include/agg_span_pattern_gray.h | 102 - .../agg/include/agg_span_pattern_rgb.h | 105 - .../agg/include/agg_span_pattern_rgba.h | 103 - .../src/windows/agg/include/agg_span_solid.h | 58 - .../agg/include/agg_span_subdiv_adaptor.h | 151 - .../windows/agg/include/agg_trans_affine.h | 524 - .../windows/agg/include/agg_trans_bilinear.h | 172 - .../agg/include/agg_trans_double_path.h | 140 - .../agg/include/agg_trans_perspective.h | 737 - .../agg/include/agg_trans_single_path.h | 106 - .../windows/agg/include/agg_trans_viewport.h | 312 - .../agg/include/agg_trans_warp_magnifier.h | 65 - .../windows/agg/include/agg_vcgen_bspline.h | 83 - .../windows/agg/include/agg_vcgen_contour.h | 103 - .../src/windows/agg/include/agg_vcgen_dash.h | 99 - .../agg/include/agg_vcgen_markers_term.h | 75 - .../agg/include/agg_vcgen_smooth_poly1.h | 96 - .../windows/agg/include/agg_vcgen_stroke.h | 111 - .../agg/include/agg_vcgen_vertex_sequence.h | 144 - .../windows/agg/include/agg_vertex_sequence.h | 178 - .../agg/include/agg_vpgen_clip_polygon.h | 92 - .../agg/include/agg_vpgen_clip_polyline.h | 87 - .../agg/include/agg_vpgen_segmentator.h | 70 - .../agg/include/ctrl/agg_bezier_ctrl.h | 201 - .../windows/agg/include/ctrl/agg_cbox_ctrl.h | 117 - .../src/windows/agg/include/ctrl/agg_ctrl.h | 123 - .../windows/agg/include/ctrl/agg_gamma_ctrl.h | 175 - .../agg/include/ctrl/agg_gamma_spline.h | 100 - .../agg/include/ctrl/agg_polygon_ctrl.h | 171 - .../windows/agg/include/ctrl/agg_rbox_ctrl.h | 146 - .../windows/agg/include/ctrl/agg_scale_ctrl.h | 151 - .../agg/include/ctrl/agg_slider_ctrl.h | 155 - .../agg/include/ctrl/agg_spline_ctrl.h | 164 - .../include/platform/agg_platform_support.h | 680 - .../agg/include/platform/mac/agg_mac_pmap.h | 92 - .../include/platform/win32/agg_win32_bmp.h | 123 - .../windows/agg/include/util/agg_color_conv.h | 89 - .../agg/include/util/agg_color_conv_rgb16.h | 294 - .../agg/include/util/agg_color_conv_rgb8.h | 478 - desmume/src/windows/agg/src/ChangeLog | 0 desmume/src/windows/agg/src/Makefile | 59 - desmume/src/windows/agg/src/agg_arc.cpp | 111 - desmume/src/windows/agg/src/agg_arrowhead.cpp | 115 - .../src/windows/agg/src/agg_bezier_arc.cpp | 261 - desmume/src/windows/agg/src/agg_bspline.cpp | 289 - desmume/src/windows/agg/src/agg_curves.cpp | 620 - .../agg/src/agg_embedded_raster_fonts.cpp | 10435 ---------- desmume/src/windows/agg/src/agg_gsv_text.cpp | 681 - .../src/windows/agg/src/agg_image_filters.cpp | 107 - .../windows/agg/src/agg_line_aa_basics.cpp | 91 - .../windows/agg/src/agg_line_profile_aa.cpp | 125 - .../src/windows/agg/src/agg_rounded_rect.cpp | 169 - .../src/windows/agg/src/agg_sqrt_tables.cpp | 120 - .../src/windows/agg/src/agg_trans_affine.cpp | 200 - .../windows/agg/src/agg_trans_double_path.cpp | 282 - .../windows/agg/src/agg_trans_single_path.cpp | 211 - .../agg/src/agg_trans_warp_magnifier.cpp | 79 - .../src/windows/agg/src/agg_vcgen_bspline.cpp | 203 - .../src/windows/agg/src/agg_vcgen_contour.cpp | 170 - .../src/windows/agg/src/agg_vcgen_dash.cpp | 240 - .../agg/src/agg_vcgen_markers_term.cpp | 108 - .../agg/src/agg_vcgen_smooth_poly1.cpp | 230 - .../src/windows/agg/src/agg_vcgen_stroke.cpp | 219 - .../agg/src/agg_vpgen_clip_polygon.cpp | 142 - .../agg/src/agg_vpgen_clip_polyline.cpp | 86 - .../windows/agg/src/agg_vpgen_segmentator.cpp | 76 - desmume/src/windows/agg/src/authors | 0 desmume/src/windows/agg/src/autogen.sh | 20 - desmume/src/windows/agg/src/configure.in | 15 - desmume/src/windows/agg/src/copying | 21 - .../windows/agg/src/ctrl/agg_bezier_ctrl.cpp | 375 - .../windows/agg/src/ctrl/agg_cbox_ctrl.cpp | 219 - .../windows/agg/src/ctrl/agg_gamma_ctrl.cpp | 438 - .../windows/agg/src/ctrl/agg_gamma_spline.cpp | 135 - .../windows/agg/src/ctrl/agg_polygon_ctrl.cpp | 337 - .../windows/agg/src/ctrl/agg_rbox_ctrl.cpp | 330 - .../windows/agg/src/ctrl/agg_scale_ctrl.cpp | 459 - .../windows/agg/src/ctrl/agg_slider_ctrl.cpp | 354 - .../windows/agg/src/ctrl/agg_spline_ctrl.cpp | 412 - desmume/src/windows/agg/src/install | 0 desmume/src/windows/agg/src/news | 0 .../platform/win32/agg_platform_support.cpp | 1478 -- .../agg/src/platform/win32/agg_win32_bmp.cpp | 625 - desmume/src/windows/agg/src/readme | 5 - desmume/src/windows/aviout.h | 31 - .../src/windows/defaultconfig/SubWCRev.bat | 2 - .../src/windows/defaultconfig/SubWCRev.exe | Bin 294400 -> 0 bytes desmume/src/windows/defaultconfig/svnrev.h | 5 - .../windows/defaultconfig/svnrev_template.h | 2 - desmume/src/windows/filter/2xsai.cpp | 735 - desmume/src/windows/filter/bilinear.cpp | 236 - desmume/src/windows/filter/filter.h | 13 - desmume/src/windows/filter/hq2x.cpp | 462 - desmume/src/windows/filter/scanline.cpp | 48 - .../build/glib/gthread/gthread-impl.c | 372 - .../build/glib/gthread/gthread-none.c | 39 - .../build/glib/gthread/gthread-posix.c | 467 - .../build/glib/gthread/gthread-win32.c | 639 - .../glib-2.20.1/lib/glib-2.20.1-x86.lib | Bin 1750574 -> 0 bytes desmume/src/windows/mapView.cpp | 314 - desmume/src/windows/pathsettings.cpp | 262 - desmume/src/windows/pathsettings.h | 29 - desmume/src/windows/snddx.cpp | 322 - desmume/src/windows/userconfig/readme.txt | 1 - desmume/src/windows/video.h | 165 - desmume/dsm.txt => dsm.txt | 13 +- desmume/faq.htm => faq.htm | 0 {desmume/po => po}/ChangeLog | 0 {desmume/po => po}/LINGUAS | 1 - {desmume/po => po}/PACKAGE | 4 +- {desmume/po => po}/POTFILES.in | 0 {desmume/po => po}/desmume.pot | 0 {desmume/po => po}/fr.po | 0 {desmume/po => po}/pt_BR.po | 0 {desmume/po => po}/sv.po | 0 {desmume/po => po}/windows/en_US.po | 0 {desmume/po => po}/windows/fr_FR.po | 0 {desmume/src => src}/ARM9.h | 0 {desmume/src => src}/Disassembler.cpp | 0 {desmume/src => src}/Disassembler.h | 64 +- {desmume/src => src}/FIFO.cpp | 125 +- {desmume/src => src}/FIFO.h | 18 +- {desmume/src => src}/GPU.cpp | 664 +- {desmume/src => src}/GPU.h | 90 +- src/GPU_osd.cpp | 267 + {desmume/src => src}/GPU_osd.h | 46 +- {desmume/src => src}/MMU.cpp | 1012 +- {desmume/src => src}/MMU.h | 156 +- {desmume/src => src}/Makefile.am | 30 +- {desmume/src => src}/NDSSystem.cpp | 2379 +-- {desmume/src => src}/NDSSystem.h | 170 +- {desmume/src => src}/OGLRender.cpp | 24 +- {desmume/src => src}/OGLRender.h | 96 +- {desmume/src => src}/PACKED.h | 24 +- src/PACKED_END.h | 3 + {desmume/src => src}/ROMReader.cpp | 472 +- {desmume/src => src}/ROMReader.h | 102 +- {desmume/src => src}/SPU.cpp | 180 +- {desmume/src => src}/SPU.h | 26 +- {desmume/src => src}/addons.cpp | 153 +- {desmume/src => src}/addons.h | 184 +- {desmume/src => src}/addons/compactFlash.cpp | 85 +- {desmume/src => src}/addons/gbagame.cpp | 266 +- {desmume/src => src}/addons/none.cpp | 104 +- {desmume/src => src}/addons/rumblepak.cpp | 194 +- {desmume/src => src}/arm_instructions.cpp | 0 {desmume/src => src}/arm_instructions.h | 64 +- {desmume/src => src}/armcpu.cpp | 12 +- {desmume/src => src}/armcpu.h | 562 +- {desmume/src => src}/bios.cpp | 2264 +-- {desmume/src => src}/bios.h | 62 +- {desmume/src => src}/bits.h | 88 +- {desmume/src => src}/build.bat | 0 src/cflash.cpp | 880 + src/cflash.h | 28 + {desmume/src => src}/cheatSystem.cpp | 0 {desmume/src => src}/cheatSystem.h | 142 +- {desmume/src => src}/cli/Makefile.am | 4 +- {desmume/src => src}/cli/doc/Makefile.am | 0 {desmume/src => src}/cli/doc/desmume-cli.1 | 0 {desmume/src => src}/cli/main.cpp | 201 +- {desmume/src => src}/cocoa/DeSmuME.cbp | 0 {desmume/src => src}/cocoa/DeSmuME.icns | Bin .../cocoa/DeSmuME.xcodeproj/project.pbxproj | 33 +- {desmume/src => src}/cocoa/Info.plist | 0 {desmume/src => src}/cocoa/InfoPlist.strings | Bin {desmume/src => src}/cocoa/Makefile.am | 0 {desmume/src => src}/cocoa/PkgInfo | 0 {desmume/src => src}/cocoa/Rakefile | 0 {desmume/src => src}/cocoa/about.m | 0 {desmume/src => src}/cocoa/build_dmg.sh | 0 {desmume/src => src}/cocoa/cocoa_util.m | 0 {desmume/src => src}/cocoa/dialogs/rom_info.h | 64 +- {desmume/src => src}/cocoa/dialogs/rom_info.m | 0 .../dialogs/speed_limit_selection_window.h | 66 +- .../dialogs/speed_limit_selection_window.mm | 0 {desmume/src => src}/cocoa/globals.h | 80 +- {desmume/src => src}/cocoa/input.h | 100 +- {desmume/src => src}/cocoa/input.mm | 0 {desmume/src => src}/cocoa/main.mm | 25 +- {desmume/src => src}/cocoa/main_window.h | 227 +- {desmume/src => src}/cocoa/main_window.mm | 45 - {desmume/src => src}/cocoa/makeapp.sh | 0 {desmume/src => src}/cocoa/nds_control.h | 387 +- {desmume/src => src}/cocoa/nds_control.mm | 26 +- {desmume/src => src}/cocoa/preferences.h | 100 +- {desmume/src => src}/cocoa/preferences.mm | 0 {desmume/src => src}/cocoa/screen_state.h | 94 +- {desmume/src => src}/cocoa/screen_state.m | 0 {desmume/src => src}/cocoa/screenshot.h | 52 +- {desmume/src => src}/cocoa/screenshot.mm | 0 {desmume/src => src}/cocoa/sndOSX.h | 98 +- {desmume/src => src}/cocoa/sndOSX.mm | 0 .../English.lproj/Localizable.strings | Bin .../English.lproj/MainMenu.nib/classes.nib | 0 .../English.lproj/MainMenu.nib/info.nib | 0 .../MainMenu.nib/keyedobjects.nib | Bin .../French.lproj/Localizable.strings | 0 .../French.lproj/MainMenu.nib/classes.nib | 0 .../French.lproj/MainMenu.nib/info.nib | 0 .../MainMenu.nib/keyedobjects.nib | Bin .../Italian.lproj/Localizable.strings | Bin .../Italian.lproj}/MainMenu.nib/classes.nib | 0 .../Italian.lproj/MainMenu.nib/info.nib | 0 .../MainMenu.nib/keyedobjects.nib | Bin .../Japanese.lproj/Localizable.strings | Bin .../Japanese.lproj/MainMenu.nib/classes.nib | 0 .../Japanese.lproj/MainMenu.nib/info.nib | 0 .../MainMenu.nib/keyedobjects.nib | Bin .../src => src}/cocoa/video_output_view.h | 100 +- .../src => src}/cocoa/video_output_view.mm | 0 {desmume/src => src}/commandline.cpp | 284 +- {desmume/src => src}/commandline.h | 136 +- {desmume/src => src}/common.cpp | 54 +- {desmume/src => src}/common.h | 9 +- {desmume/src => src}/cp15.cpp | 1190 +- {desmume/src => src}/cp15.h | 188 +- {desmume/src => src}/ctrlssdl.cpp | 1001 +- {desmume/src => src}/ctrlssdl.h | 197 +- {desmume/src => src}/debug.cpp | 0 {desmume/src => src}/debug.h | 0 {desmume/src => src}/desmume.mk | 0 {desmume/src => src}/driver.h | 0 {desmume/src => src}/dscard.h | 68 +- src/fat.h | 131 + {desmume/src => src}/fs-linux.cpp | 230 +- {desmume/src => src}/fs-windows.cpp | 180 +- {desmume/src => src}/fs.h | 88 +- {desmume/src => src}/gdbstub.h | 116 +- {desmume/src => src}/gdbstub/Makefile.am | 0 {desmume/src => src}/gdbstub/gdbstub.cpp | 3234 +-- .../src => src}/gdbstub/gdbstub_internal.h | 320 +- {desmume/src => src}/gfx3d.cpp | 2022 +- {desmume/src => src}/gfx3d.h | 74 +- {desmume/src => src}/gtk-glade/Makefile.am | 4 +- {desmume/src => src}/gtk-glade/callbacks.cpp | 1068 +- {desmume/src => src}/gtk-glade/callbacks.h | 150 +- .../src => src}/gtk-glade/callbacks_IO.cpp | 878 +- {desmume/src => src}/gtk-glade/callbacks_IO.h | 104 +- .../gtk-glade/dTools/callbacks_1_ioregs.cpp | 326 +- .../gtk-glade/dTools/callbacks_2_memview.cpp | 578 +- .../gtk-glade/dTools/callbacks_3_palview.cpp | 334 +- .../gtk-glade/dTools/callbacks_4_tileview.cpp | 794 +- .../gtk-glade/dTools/callbacks_dtools.h | 158 +- .../gtk-glade/dTools/dTools_display.h | 220 +- .../gtk-glade/desmume-glade.desktop | 0 {desmume/src => src}/gtk-glade/desmume.cpp | 359 +- {desmume/src => src}/gtk-glade/desmume.h | 98 +- .../src => src}/gtk-glade/doc/Makefile.am | 0 .../src => src}/gtk-glade/doc/desmume-glade.1 | 0 {desmume/src => src}/gtk-glade/gdk_3Demu.cpp | 416 +- {desmume/src => src}/gtk-glade/gdk_3Demu.h | 64 +- {desmume/src => src}/gtk-glade/gdk_gl.cpp | 698 +- {desmume/src => src}/gtk-glade/gdk_gl.h | 96 +- {desmume/src => src}/gtk-glade/glade-xml.cpp | 258 +- .../src => src}/gtk-glade/glade/DeSmuME.xpm | 0 .../src => src}/gtk-glade/glade/DeSmuMe.glade | 0 .../gtk-glade/glade/DeSmuMe_Dtools.glade | 0 {desmume/src => src}/gtk-glade/globals.h | 261 +- .../src => src}/gtk-glade/keyval_names.cpp | 2768 +-- {desmume/src => src}/gtk-glade/keyval_names.h | 46 +- {desmume/src => src}/gtk-glade/main.cpp | 1276 +- {desmume/src => src}/gtk/DeSmuME.xpm | 0 {desmume/src => src}/gtk/Makefile.am | 23 +- {desmume/src => src}/gtk/dTool.h | 44 +- {desmume/src => src}/gtk/dToolsList.cpp | 62 +- {desmume/src => src}/gtk/desmume.cpp | 184 +- {desmume/src => src}/gtk/desmume.desktop | 1 - {desmume/src => src}/gtk/desmume.h | 80 +- {desmume/src => src}/gtk/desmume_config.cpp | 294 +- {desmume/src => src}/gtk/desmume_config.h | 64 +- {desmume/src => src}/gtk/doc/Makefile.am | 0 {desmume/src => src}/gtk/doc/desmume.1 | 0 {desmume/src => src}/gtk/main.cpp | 273 +- {desmume/src => src}/gtk/osmesa_3Demu.cpp | 106 +- {desmume/src => src}/gtk/osmesa_3Demu.h | 46 +- {desmume/src => src}/gtk/tools/ioregsView.cpp | 962 +- {desmume/src => src}/gtk/tools/ioregsView.h | 58 +- {desmume/src => src}/instruction_tabdef.inc | 0 {desmume/src => src}/lua-engine.cpp | 10436 +++++----- {desmume/src => src}/lua-engine.h | 190 +- {desmume/src => src}/matrix.cpp | 51 +- src/matrix.h | 146 + src/matrix_sse2-x64.asm | 182 + src/matrix_sse2-x86.asm | 214 + src/mc.cpp | 512 + {desmume/src => src}/mc.h | 224 +- {desmume/src => src}/mem.h | 328 +- {desmume/src => src}/memorystream.h | 608 +- src/mic.cpp | 35 + src/mic.h | 19 + {desmume/src => src}/movie.cpp | 98 +- {desmume/src => src}/movie.h | 8 +- {desmume/src => src}/rasterize.cpp | 68 +- {desmume/src => src}/rasterize.h | 62 +- {desmume/src => src}/readwrite.cpp | 340 +- {desmume/src => src}/readwrite.h | 54 +- {desmume/src => src}/registers.h | 666 +- {desmume/src => src}/render3D.cpp | 108 +- {desmume/src => src}/render3D.h | 134 +- {desmume/src => src}/rtc.cpp | 752 +- {desmume/src => src}/rtc.h | 70 +- {desmume/src => src}/saves.cpp | 240 +- {desmume/src => src}/saves.h | 136 +- {desmume/src => src}/shaders.h | 156 +- {desmume/src => src}/sndsdl.cpp | 378 +- {desmume/src => src}/sndsdl.h | 52 +- src/softrender.cpp | 752 + src/softrender.h | 235 + src/softrender_config.h | 14 + src/softrender_desmumefont.h | 574 + src/softrender_v3sysfont.h | 940 + {desmume/src => src}/texcache.cpp | 1300 +- {desmume/src => src}/texcache.h | 9 +- {desmume/src => src}/thumb_instructions.cpp | 0 {desmume/src => src}/thumb_instructions.h | 62 +- {desmume/src => src}/thumb_tabdef.inc | 0 {desmume/src => src}/types.h | 780 +- {desmume/src => src}/utils/ConvertUTF.c | 0 {desmume/src => src}/utils/ConvertUTF.h | 298 +- {desmume/src => src}/utils/decrypt/crc.cpp | 334 +- {desmume/src => src}/utils/decrypt/crc.h | 396 +- .../src => src}/utils/decrypt/decrypt.cpp | 0 {desmume/src => src}/utils/decrypt/decrypt.h | 0 {desmume/src => src}/utils/decrypt/header.cpp | 0 {desmume/src => src}/utils/decrypt/header.h | 0 {desmume/src => src}/utils/guid.cpp | 140 +- {desmume/src => src}/utils/guid.h | 38 +- {desmume/src => src}/utils/md5.cpp | 0 {desmume/src => src}/utils/md5.h | 46 +- {desmume/src => src}/utils/valuearray.h | 42 +- {desmume/src => src}/utils/xstring.cpp | 47 +- {desmume/src => src}/utils/xstring.h | 6 - {desmume/src => src}/wifi.cpp | 82 +- {desmume/src => src}/wifi.h | 0 {desmume/src => src}/windows/7z/7zip.lib | Bin {desmume/src => src}/windows/7z/7zip.vcproj | 0 {desmume/src => src}/windows/7z/C/7zCrc.c | 0 {desmume/src => src}/windows/7z/C/7zCrc.h | 0 {desmume/src => src}/windows/7z/C/Aes.c | 0 {desmume/src => src}/windows/7z/C/Aes.h | 0 {desmume/src => src}/windows/7z/C/Alloc.c | 0 {desmume/src => src}/windows/7z/C/Alloc.h | 0 {desmume/src => src}/windows/7z/C/Bra.c | 0 {desmume/src => src}/windows/7z/C/Bra.h | 0 {desmume/src => src}/windows/7z/C/Bra86.c | 0 {desmume/src => src}/windows/7z/C/BraIA64.c | 0 {desmume/src => src}/windows/7z/C/BwtSort.c | 0 {desmume/src => src}/windows/7z/C/BwtSort.h | 0 {desmume/src => src}/windows/7z/C/CpuArch.h | 0 {desmume/src => src}/windows/7z/C/HuffEnc.c | 0 {desmume/src => src}/windows/7z/C/HuffEnc.h | 0 {desmume/src => src}/windows/7z/C/LzFind.c | 0 {desmume/src => src}/windows/7z/C/LzFind.h | 0 {desmume/src => src}/windows/7z/C/LzFindMt.c | 0 {desmume/src => src}/windows/7z/C/LzFindMt.h | 0 {desmume/src => src}/windows/7z/C/LzHash.h | 0 {desmume/src => src}/windows/7z/C/LzmaDec.c | 0 {desmume/src => src}/windows/7z/C/LzmaDec.h | 0 {desmume/src => src}/windows/7z/C/LzmaEnc.c | 0 {desmume/src => src}/windows/7z/C/LzmaEnc.h | 0 .../src => src}/windows/7z/C/RotateDefs.h | 0 {desmume/src => src}/windows/7z/C/Sha256.c | 0 {desmume/src => src}/windows/7z/C/Sha256.h | 0 {desmume/src => src}/windows/7z/C/Sort.c | 0 {desmume/src => src}/windows/7z/C/Sort.h | 0 {desmume/src => src}/windows/7z/C/Threads.c | 0 {desmume/src => src}/windows/7z/C/Threads.h | 0 {desmume/src => src}/windows/7z/C/Types.h | 0 .../CPP/7zip/Archive/7z/7zCompressionMode.cpp | 0 .../CPP/7zip/Archive/7z/7zCompressionMode.h | 0 .../7z/CPP/7zip/Archive/7z/7zDecode.cpp | 0 .../windows/7z/CPP/7zip/Archive/7z/7zDecode.h | 0 .../7z/CPP/7zip/Archive/7z/7zExtract.cpp | 0 .../CPP/7zip/Archive/7z/7zFolderInStream.cpp | 0 .../7z/CPP/7zip/Archive/7z/7zFolderInStream.h | 0 .../CPP/7zip/Archive/7z/7zFolderOutStream.cpp | 0 .../CPP/7zip/Archive/7z/7zFolderOutStream.h | 0 .../7z/CPP/7zip/Archive/7z/7zHandler.cpp | 0 .../7z/CPP/7zip/Archive/7z/7zHandler.h | 0 .../7z/CPP/7zip/Archive/7z/7zHeader.cpp | 0 .../windows/7z/CPP/7zip/Archive/7z/7zHeader.h | 0 .../windows/7z/CPP/7zip/Archive/7z/7zIn.cpp | 0 .../windows/7z/CPP/7zip/Archive/7z/7zIn.h | 0 .../windows/7z/CPP/7zip/Archive/7z/7zItem.h | 0 .../7z/CPP/7zip/Archive/7z/7zProperties.cpp | 0 .../7z/CPP/7zip/Archive/7z/7zProperties.h | 0 .../7z/CPP/7zip/Archive/7z/7zRegister.cpp | 0 .../7z/CPP/7zip/Archive/7z/7zSpecStream.cpp | 0 .../7z/CPP/7zip/Archive/7z/7zSpecStream.h | 0 .../windows/7z/CPP/7zip/Archive/7z/StdAfx.h | 0 .../7z/CPP/7zip/Archive/ArchiveExports.cpp | 0 .../CPP/7zip/Archive/BZip2/BZip2Handler.cpp | 0 .../7z/CPP/7zip/Archive/BZip2/BZip2Handler.h | 0 .../7z/CPP/7zip/Archive/BZip2/BZip2Item.h | 0 .../7z/CPP/7zip/Archive/BZip2/StdAfx.h | 0 .../7z/CPP/7zip/Archive/BZip2/bz2Register.cpp | 0 .../CPP/7zip/Archive/Common/CoderMixer2.cpp | 0 .../7z/CPP/7zip/Archive/Common/CoderMixer2.h | 0 .../CPP/7zip/Archive/Common/CoderMixer2MT.cpp | 0 .../CPP/7zip/Archive/Common/CoderMixer2MT.h | 0 .../7zip/Archive/Common/DummyOutStream.cpp | 0 .../CPP/7zip/Archive/Common/DummyOutStream.h | 0 .../CPP/7zip/Archive/Common/FindSignature.cpp | 0 .../CPP/7zip/Archive/Common/FindSignature.h | 0 .../7zip/Archive/Common/InStreamWithCRC.cpp | 0 .../CPP/7zip/Archive/Common/InStreamWithCRC.h | 0 .../CPP/7zip/Archive/Common/ItemNameUtils.cpp | 0 .../CPP/7zip/Archive/Common/ItemNameUtils.h | 0 .../CPP/7zip/Archive/Common/MultiStream.cpp | 0 .../7z/CPP/7zip/Archive/Common/MultiStream.h | 0 .../7zip/Archive/Common/OutStreamWithCRC.cpp | 0 .../7zip/Archive/Common/OutStreamWithCRC.h | 0 .../7zip/Archive/Common/ParseProperties.cpp | 0 .../CPP/7zip/Archive/Common/ParseProperties.h | 0 .../7z/CPP/7zip/Archive/Common/StdAfx.h | 0 .../7z/CPP/7zip/Archive/DllExports2.cpp | 0 .../7z/CPP/7zip/Archive/GZip/GZipHandler.cpp | 0 .../7z/CPP/7zip/Archive/GZip/GZipHandler.h | 0 .../7z/CPP/7zip/Archive/GZip/GZipHeader.cpp | 0 .../7z/CPP/7zip/Archive/GZip/GZipHeader.h | 0 .../7z/CPP/7zip/Archive/GZip/GZipIn.cpp | 0 .../windows/7z/CPP/7zip/Archive/GZip/GZipIn.h | 0 .../7z/CPP/7zip/Archive/GZip/GZipItem.h | 0 .../7z/CPP/7zip/Archive/GZip/GZipRegister.cpp | 0 .../7z/CPP/7zip/Archive/GZip/GZipUpdate.h | 0 .../windows/7z/CPP/7zip/Archive/GZip/StdAfx.h | 0 .../windows/7z/CPP/7zip/Archive/IArchive.h | 0 .../7z/CPP/7zip/Archive/Lzh/LzhCRC.cpp | 0 .../windows/7z/CPP/7zip/Archive/Lzh/LzhCRC.h | 0 .../7z/CPP/7zip/Archive/Lzh/LzhHandler.cpp | 0 .../7z/CPP/7zip/Archive/Lzh/LzhHandler.h | 0 .../7z/CPP/7zip/Archive/Lzh/LzhHeader.h | 0 .../windows/7z/CPP/7zip/Archive/Lzh/LzhIn.cpp | 0 .../windows/7z/CPP/7zip/Archive/Lzh/LzhIn.h | 0 .../windows/7z/CPP/7zip/Archive/Lzh/LzhItem.h | 0 .../7zip/Archive/Lzh/LzhOutStreamWithCRC.cpp | 0 .../7zip/Archive/Lzh/LzhOutStreamWithCRC.h | 0 .../7z/CPP/7zip/Archive/Lzh/LzhRegister.cpp | 0 .../windows/7z/CPP/7zip/Archive/Lzh/StdAfx.h | 0 .../CPP/7zip/Archive/Lzma/LzmaArcRegister.cpp | 0 .../7zip/Archive/Lzma/LzmaFiltersDecode.cpp | 0 .../CPP/7zip/Archive/Lzma/LzmaFiltersDecode.h | 0 .../7z/CPP/7zip/Archive/Lzma/LzmaHandler.cpp | 0 .../7z/CPP/7zip/Archive/Lzma/LzmaHandler.h | 0 .../7z/CPP/7zip/Archive/Lzma/LzmaIn.cpp | 0 .../windows/7z/CPP/7zip/Archive/Lzma/LzmaIn.h | 0 .../7z/CPP/7zip/Archive/Lzma/LzmaItem.h | 0 .../windows/7z/CPP/7zip/Archive/Lzma/StdAfx.h | 0 .../7z/CPP/7zip/Archive/Rar/RarHandler.cpp | 0 .../7z/CPP/7zip/Archive/Rar/RarHandler.h | 0 .../7z/CPP/7zip/Archive/Rar/RarHeader.cpp | 0 .../7z/CPP/7zip/Archive/Rar/RarHeader.h | 0 .../windows/7z/CPP/7zip/Archive/Rar/RarIn.cpp | 0 .../windows/7z/CPP/7zip/Archive/Rar/RarIn.h | 0 .../7z/CPP/7zip/Archive/Rar/RarItem.cpp | 0 .../windows/7z/CPP/7zip/Archive/Rar/RarItem.h | 0 .../7z/CPP/7zip/Archive/Rar/RarRegister.cpp | 0 .../7zip/Archive/Rar/RarVolumeInStream.cpp | 0 .../CPP/7zip/Archive/Rar/RarVolumeInStream.h | 0 .../windows/7z/CPP/7zip/Archive/Rar/StdAfx.h | 0 .../CPP/7zip/Archive/Split/SplitHandler.cpp | 0 .../7z/CPP/7zip/Archive/Split/SplitHandler.h | 0 .../CPP/7zip/Archive/Split/SplitRegister.cpp | 0 .../7z/CPP/7zip/Archive/Split/StdAfx.h | 0 .../windows/7z/CPP/7zip/Archive/StdAfx.h | 0 .../windows/7z/CPP/7zip/Archive/Tar/StdAfx.h | 0 .../7z/CPP/7zip/Archive/Tar/TarHandler.cpp | 0 .../7z/CPP/7zip/Archive/Tar/TarHandler.h | 0 .../7z/CPP/7zip/Archive/Tar/TarHeader.cpp | 0 .../7z/CPP/7zip/Archive/Tar/TarHeader.h | 0 .../windows/7z/CPP/7zip/Archive/Tar/TarIn.cpp | 0 .../windows/7z/CPP/7zip/Archive/Tar/TarIn.h | 0 .../windows/7z/CPP/7zip/Archive/Tar/TarItem.h | 0 .../7z/CPP/7zip/Archive/Tar/TarRegister.cpp | 0 .../windows/7z/CPP/7zip/Archive/Zip/StdAfx.h | 0 .../CPP/7zip/Archive/Zip/ZipCompressionMode.h | 0 .../7z/CPP/7zip/Archive/Zip/ZipHandler.cpp | 0 .../7z/CPP/7zip/Archive/Zip/ZipHandler.h | 0 .../7z/CPP/7zip/Archive/Zip/ZipHeader.cpp | 0 .../7z/CPP/7zip/Archive/Zip/ZipHeader.h | 0 .../windows/7z/CPP/7zip/Archive/Zip/ZipIn.cpp | 0 .../windows/7z/CPP/7zip/Archive/Zip/ZipIn.h | 0 .../7z/CPP/7zip/Archive/Zip/ZipItem.cpp | 0 .../windows/7z/CPP/7zip/Archive/Zip/ZipItem.h | 0 .../7z/CPP/7zip/Archive/Zip/ZipItemEx.h | 0 .../7z/CPP/7zip/Archive/Zip/ZipRegister.cpp | 0 .../7z/CPP/7zip/Common/CreateCoder.cpp | 0 .../windows/7z/CPP/7zip/Common/CreateCoder.h | 0 .../windows/7z/CPP/7zip/Common/DeclareArcs.h | 0 .../7z/CPP/7zip/Common/DeclareCodecs.h | 0 .../7z/CPP/7zip/Common/FilterCoder.cpp | 0 .../windows/7z/CPP/7zip/Common/FilterCoder.h | 0 .../windows/7z/CPP/7zip/Common/InBuffer.cpp | 0 .../windows/7z/CPP/7zip/Common/InBuffer.h | 0 .../7z/CPP/7zip/Common/InOutTempBuffer.cpp | 0 .../7z/CPP/7zip/Common/InOutTempBuffer.h | 0 .../7z/CPP/7zip/Common/LimitedStreams.cpp | 0 .../7z/CPP/7zip/Common/LimitedStreams.h | 0 .../7z/CPP/7zip/Common/LockedStream.cpp | 0 .../windows/7z/CPP/7zip/Common/LockedStream.h | 0 .../windows/7z/CPP/7zip/Common/MemBlocks.cpp | 0 .../windows/7z/CPP/7zip/Common/MemBlocks.h | 0 .../windows/7z/CPP/7zip/Common/MethodId.cpp | 0 .../windows/7z/CPP/7zip/Common/MethodId.h | 0 .../7z/CPP/7zip/Common/MethodProps.cpp | 0 .../windows/7z/CPP/7zip/Common/MethodProps.h | 0 .../7z/CPP/7zip/Common/OffsetStream.cpp | 0 .../windows/7z/CPP/7zip/Common/OffsetStream.h | 0 .../windows/7z/CPP/7zip/Common/OutBuffer.cpp | 0 .../windows/7z/CPP/7zip/Common/OutBuffer.h | 0 .../7z/CPP/7zip/Common/OutMemStream.cpp | 0 .../windows/7z/CPP/7zip/Common/OutMemStream.h | 0 .../windows/7z/CPP/7zip/Common/ProgressMt.cpp | 0 .../windows/7z/CPP/7zip/Common/ProgressMt.h | 0 .../7z/CPP/7zip/Common/ProgressUtils.cpp | 0 .../7z/CPP/7zip/Common/ProgressUtils.h | 0 .../windows/7z/CPP/7zip/Common/RegisterArc.h | 0 .../7z/CPP/7zip/Common/RegisterCodec.h | 0 .../windows/7z/CPP/7zip/Common/StdAfx.h | 0 .../7z/CPP/7zip/Common/StreamBinder.cpp | 0 .../windows/7z/CPP/7zip/Common/StreamBinder.h | 0 .../7z/CPP/7zip/Common/StreamObjects.cpp | 0 .../7z/CPP/7zip/Common/StreamObjects.h | 0 .../7z/CPP/7zip/Common/StreamUtils.cpp | 0 .../windows/7z/CPP/7zip/Common/StreamUtils.h | 0 .../windows/7z/CPP/7zip/Common/VirtThread.cpp | 0 .../windows/7z/CPP/7zip/Common/VirtThread.h | 0 .../windows/7z/CPP/7zip/Compress/BZip2Const.h | 0 .../windows/7z/CPP/7zip/Compress/BZip2Crc.cpp | 0 .../windows/7z/CPP/7zip/Compress/BZip2Crc.h | 0 .../7z/CPP/7zip/Compress/BZip2Decoder.cpp | 0 .../7z/CPP/7zip/Compress/BZip2Decoder.h | 0 .../7z/CPP/7zip/Compress/BZip2Register.cpp | 0 .../7z/CPP/7zip/Compress/Bcj2Coder.cpp | 0 .../windows/7z/CPP/7zip/Compress/Bcj2Coder.h | 0 .../7z/CPP/7zip/Compress/Bcj2Register.cpp | 0 .../windows/7z/CPP/7zip/Compress/BcjCoder.cpp | 0 .../windows/7z/CPP/7zip/Compress/BcjCoder.h | 0 .../7z/CPP/7zip/Compress/BcjRegister.cpp | 0 .../7z/CPP/7zip/Compress/BitlDecoder.cpp | 0 .../7z/CPP/7zip/Compress/BitlDecoder.h | 0 .../7z/CPP/7zip/Compress/BitmDecoder.h | 0 .../7z/CPP/7zip/Compress/BranchCoder.cpp | 0 .../7z/CPP/7zip/Compress/BranchCoder.h | 0 .../7z/CPP/7zip/Compress/BranchMisc.cpp | 0 .../windows/7z/CPP/7zip/Compress/BranchMisc.h | 0 .../7z/CPP/7zip/Compress/BranchRegister.cpp | 0 .../windows/7z/CPP/7zip/Compress/ByteSwap.cpp | 0 .../windows/7z/CPP/7zip/Compress/ByteSwap.h | 0 .../7z/CPP/7zip/Compress/ByteSwapRegister.cpp | 0 .../windows/7z/CPP/7zip/Compress/Codec.def | 0 .../7z/CPP/7zip/Compress/CodecExports.cpp | 0 .../7z/CPP/7zip/Compress/CopyCoder.cpp | 0 .../windows/7z/CPP/7zip/Compress/CopyCoder.h | 0 .../7z/CPP/7zip/Compress/CopyRegister.cpp | 0 .../CPP/7zip/Compress/Deflate64Register.cpp | 0 .../7z/CPP/7zip/Compress/DeflateConst.h | 0 .../7z/CPP/7zip/Compress/DeflateDecoder.cpp | 0 .../7z/CPP/7zip/Compress/DeflateDecoder.h | 0 .../CPP/7zip/Compress/DeflateNsisRegister.cpp | 0 .../7z/CPP/7zip/Compress/DeflateRegister.cpp | 0 .../7z/CPP/7zip/Compress/HuffmanDecoder.h | 0 .../7z/CPP/7zip/Compress/ImplodeDecoder.cpp | 0 .../7z/CPP/7zip/Compress/ImplodeDecoder.h | 0 .../7zip/Compress/ImplodeHuffmanDecoder.cpp | 0 .../CPP/7zip/Compress/ImplodeHuffmanDecoder.h | 0 .../7z/CPP/7zip/Compress/LzOutWindow.cpp | 0 .../7z/CPP/7zip/Compress/LzOutWindow.h | 0 .../7z/CPP/7zip/Compress/LzhDecoder.cpp | 0 .../windows/7z/CPP/7zip/Compress/LzhDecoder.h | 0 .../7z/CPP/7zip/Compress/LzmaDecoder.cpp | 0 .../7z/CPP/7zip/Compress/LzmaDecoder.h | 0 .../7z/CPP/7zip/Compress/LzmaRegister.cpp | 0 .../windows/7z/CPP/7zip/Compress/Mtf8.h | 0 .../7z/CPP/7zip/Compress/PpmdContext.h | 0 .../windows/7z/CPP/7zip/Compress/PpmdDecode.h | 0 .../7z/CPP/7zip/Compress/PpmdDecoder.cpp | 0 .../7z/CPP/7zip/Compress/PpmdDecoder.h | 0 .../7z/CPP/7zip/Compress/PpmdRegister.cpp | 0 .../7z/CPP/7zip/Compress/PpmdSubAlloc.h | 0 .../windows/7z/CPP/7zip/Compress/PpmdType.h | 0 .../windows/7z/CPP/7zip/Compress/RangeCoder.h | 0 .../7z/CPP/7zip/Compress/RangeCoderBit.h | 0 .../7z/CPP/7zip/Compress/Rar1Decoder.cpp | 0 .../7z/CPP/7zip/Compress/Rar1Decoder.h | 0 .../7z/CPP/7zip/Compress/Rar2Decoder.cpp | 0 .../7z/CPP/7zip/Compress/Rar2Decoder.h | 0 .../7z/CPP/7zip/Compress/Rar3Decoder.cpp | 0 .../7z/CPP/7zip/Compress/Rar3Decoder.h | 0 .../windows/7z/CPP/7zip/Compress/Rar3Vm.cpp | 0 .../windows/7z/CPP/7zip/Compress/Rar3Vm.h | 0 .../CPP/7zip/Compress/RarCodecsRegister.cpp | 0 .../7z/CPP/7zip/Compress/ShrinkDecoder.cpp | 0 .../7z/CPP/7zip/Compress/ShrinkDecoder.h | 0 .../windows/7z/CPP/7zip/Compress/StdAfx.h | 0 .../7z/CPP/7zip/Compress/ZlibDecoder.cpp | 0 .../7z/CPP/7zip/Compress/ZlibDecoder.h | 0 .../windows/7z/CPP/7zip/Crypto/7zAes.cpp | 0 .../windows/7z/CPP/7zip/Crypto/7zAes.h | 0 .../7z/CPP/7zip/Crypto/7zAesRegister.cpp | 0 .../windows/7z/CPP/7zip/Crypto/HmacSha1.cpp | 0 .../windows/7z/CPP/7zip/Crypto/HmacSha1.h | 0 .../windows/7z/CPP/7zip/Crypto/MyAes.cpp | 0 .../windows/7z/CPP/7zip/Crypto/MyAes.h | 0 .../7z/CPP/7zip/Crypto/Pbkdf2HmacSha1.cpp | 0 .../7z/CPP/7zip/Crypto/Pbkdf2HmacSha1.h | 0 .../windows/7z/CPP/7zip/Crypto/RandGen.cpp | 0 .../windows/7z/CPP/7zip/Crypto/RandGen.h | 0 .../7z/CPP/7zip/Crypto/Rar20Crypto.cpp | 0 .../windows/7z/CPP/7zip/Crypto/Rar20Crypto.h | 0 .../windows/7z/CPP/7zip/Crypto/RarAes.cpp | 0 .../windows/7z/CPP/7zip/Crypto/RarAes.h | 0 .../windows/7z/CPP/7zip/Crypto/Sha1.cpp | 0 .../windows/7z/CPP/7zip/Crypto/Sha1.h | 0 .../windows/7z/CPP/7zip/Crypto/StdAfx.h | 0 .../windows/7z/CPP/7zip/Crypto/WzAes.cpp | 0 .../windows/7z/CPP/7zip/Crypto/WzAes.h | 0 .../windows/7z/CPP/7zip/Crypto/ZipCrypto.cpp | 0 .../windows/7z/CPP/7zip/Crypto/ZipCrypto.h | 0 .../windows/7z/CPP/7zip/Crypto/ZipStrong.cpp | 0 .../windows/7z/CPP/7zip/Crypto/ZipStrong.h | 0 .../src => src}/windows/7z/CPP/7zip/ICoder.h | 0 .../src => src}/windows/7z/CPP/7zip/IDecl.h | 0 .../windows/7z/CPP/7zip/IPassword.h | 0 .../windows/7z/CPP/7zip/IProgress.h | 0 .../src => src}/windows/7z/CPP/7zip/IStream.h | 0 .../src => src}/windows/7z/CPP/7zip/PropID.h | 0 .../windows/7z/CPP/Common/Buffer.h | 0 .../src => src}/windows/7z/CPP/Common/CRC.cpp | 0 .../windows/7z/CPP/Common/ComTry.h | 0 .../src => src}/windows/7z/CPP/Common/Defs.h | 0 .../windows/7z/CPP/Common/DynamicBuffer.h | 0 .../7z/CPP/Common/InitializeStaticLib.h | 0 .../windows/7z/CPP/Common/IntToString.cpp | 0 .../windows/7z/CPP/Common/IntToString.h | 0 .../src => src}/windows/7z/CPP/Common/MyCom.h | 0 .../windows/7z/CPP/Common/MyException.h | 0 .../windows/7z/CPP/Common/MyInitGuid.h | 0 .../windows/7z/CPP/Common/MyMap.cpp | 0 .../src => src}/windows/7z/CPP/Common/MyMap.h | 0 .../windows/7z/CPP/Common/MyString.cpp | 0 .../windows/7z/CPP/Common/MyString.h | 0 .../windows/7z/CPP/Common/MyUnknown.h | 0 .../windows/7z/CPP/Common/MyVector.cpp | 0 .../windows/7z/CPP/Common/MyVector.h | 0 .../windows/7z/CPP/Common/MyWindows.h | 0 .../windows/7z/CPP/Common/MyXml.cpp | 0 .../src => src}/windows/7z/CPP/Common/MyXml.h | 0 .../windows/7z/CPP/Common/NewHandler.cpp | 0 .../windows/7z/CPP/Common/NewHandler.h | 0 .../windows/7z/CPP/Common/StringConvert.cpp | 0 .../windows/7z/CPP/Common/StringConvert.h | 0 .../windows/7z/CPP/Common/StringToInt.cpp | 0 .../windows/7z/CPP/Common/StringToInt.h | 0 .../src => src}/windows/7z/CPP/Common/Types.h | 0 .../windows/7z/CPP/Common/UTFConvert.cpp | 0 .../windows/7z/CPP/Common/UTFConvert.h | 0 .../windows/7z/CPP/Common/Wildcard.cpp | 0 .../windows/7z/CPP/Common/Wildcard.h | 0 .../src => src}/windows/7z/CPP/Windows/Defs.h | 0 .../windows/7z/CPP/Windows/FileDir.cpp | 0 .../windows/7z/CPP/Windows/FileDir.h | 0 .../windows/7z/CPP/Windows/FileFind.cpp | 0 .../windows/7z/CPP/Windows/FileFind.h | 0 .../windows/7z/CPP/Windows/FileIO.cpp | 0 .../windows/7z/CPP/Windows/FileIO.h | 0 .../windows/7z/CPP/Windows/FileName.h | 0 .../windows/7z/CPP/Windows/Handle.h | 0 .../windows/7z/CPP/Windows/PropVariant.cpp | 0 .../windows/7z/CPP/Windows/PropVariant.h | 0 .../windows/7z/CPP/Windows/StdAfx.h | 0 .../windows/7z/CPP/Windows/Synchronization.h | 0 .../windows/7z/CPP/Windows/Thread.h | 0 .../windows/7z/CPP/Windows/Time.cpp | 0 .../src => src}/windows/7z/CPP/Windows/Time.h | 0 .../src => src}/windows/7z/DOC/License.txt | 0 {desmume/src => src}/windows/7z/DOC/gpl.txt | 0 .../src => src}/windows/7z/DOC/readme.txt | 0 .../windows/7z/DOC/unRarLicense.txt | 0 {desmume/src => src}/windows/7zip.cpp | 3 +- {desmume/src => src}/windows/7zip.h | 2 - {desmume/src => src}/windows/7zipstreams.h | 0 {desmume/src => src}/windows/AboutBox.cpp | 250 +- {desmume/src => src}/windows/AboutBox.h | 50 +- {desmume/src => src}/windows/CWindow.cpp | 670 +- {desmume/src => src}/windows/CWindow.h | 192 +- {desmume/src => src}/windows/DeSmuME.ico | Bin {desmume/src => src}/windows/DeSmuME_2005.sln | 2 +- .../src => src}/windows/DeSmuME_2005.vcproj | 2257 +-- {desmume/src => src}/windows/DeSmuME_2008.sln | 0 .../src => src}/windows/DeSmuME_2008.vcproj | 327 +- .../src => src}/windows/DeSmuME_Intel.icproj | 998 +- .../src => src}/windows/DeSmuME_Intel.sln | 0 .../src => src}/windows/DeSmuME_Intel.vcproj | 2088 +- .../src => src}/windows/DeSmuME_x64.manifest | 0 .../src => src}/windows/DeSmuME_x86.manifest | 0 {desmume/src => src}/windows/FirmConfig.cpp | 330 +- {desmume/src => src}/windows/FirmConfig.h | 56 +- {desmume/src => src}/windows/GL/glext.h | 16920 ++++++++-------- {desmume/src => src}/windows/IORegView.cpp | 0 {desmume/src => src}/windows/IORegView.h | 56 +- {desmume/src => src}/windows/Makefile.am | 4 +- {desmume/src => src}/windows/Makefile.win | 0 {desmume/src => src}/windows/OpenArchive.cpp | 0 {desmume/src => src}/windows/OpenArchive.h | 0 {desmume/src => src}/windows/afxres.h | 0 {desmume/src => src}/windows/aviout.cpp | 64 +- src/windows/aviout.h | 5 + {desmume/src => src}/windows/bitmap1.bmp | Bin {desmume/src => src}/windows/cheatsWin.cpp | 2544 +-- {desmume/src => src}/windows/cheatsWin.h | 54 +- {desmume/src => src}/windows/colorctrl.cpp | 316 +- {desmume/src => src}/windows/colorctrl.h | 28 +- {desmume/src => src}/windows/config.h | 12 +- {desmume/src => src}/windows/console.cpp | 2 +- {desmume/src => src}/windows/console.h | 80 +- .../windows/defaultconfig/userconfig.h | 6 +- .../src => src}/windows/directx/DxErr8.lib | Bin {desmume/src => src}/windows/directx/ddraw.h | 11584 +++++------ .../src => src}/windows/directx/ddraw.lib | Bin {desmume/src => src}/windows/directx/dinput.h | 8834 ++++---- .../src => src}/windows/directx/dinput8.lib | Bin {desmume/src => src}/windows/directx/dsound.h | 4716 ++--- .../src => src}/windows/directx/dsound.lib | Bin {desmume/src => src}/windows/directx/dxerr8.h | 198 +- .../src => src}/windows/directx/dxguid.lib | Bin {desmume/src => src}/windows/disView.cpp | 0 {desmume/src => src}/windows/disView.h | 70 +- .../src => src}/windows/gbaslot_config.cpp | 239 +- {desmume/src => src}/windows/gbaslot_config.h | 56 +- {desmume/src => src}/windows/ginfo.cpp | 692 +- {desmume/src => src}/windows/ginfo.h | 66 +- .../proxy-libintl-20080918/include/libintl.h | 0 .../windows/glib-2.20.1/build/dirent/README | 0 .../windows/glib-2.20.1/build/dirent/dirent.c | 0 .../windows/glib-2.20.1/build/dirent/dirent.h | 0 .../glib-2.20.1/build/dirent/wdirent.c | 0 .../windows/glib-2.20.1/build/glib/config.h | 0 .../windows/glib-2.20.1/build/glib/galias.h | 0 .../glib-2.20.1/build/glib/galiasdef.c | 0 .../windows/glib-2.20.1/build/glib/galloca.h | 0 .../windows/glib-2.20.1/build/glib/garray.c | 0 .../windows/glib-2.20.1/build/glib/garray.h | 0 .../glib-2.20.1/build/glib/gasyncqueue.c | 0 .../glib-2.20.1/build/glib/gasyncqueue.h | 0 .../windows/glib-2.20.1/build/glib/gatomic.c | 0 .../windows/glib-2.20.1/build/glib/gatomic.h | 0 .../glib-2.20.1/build/glib/gbacktrace.c | 0 .../glib-2.20.1/build/glib/gbacktrace.h | 0 .../windows/glib-2.20.1/build/glib/gbase64.c | 0 .../windows/glib-2.20.1/build/glib/gbase64.h | 0 .../glib-2.20.1/build/glib/gbookmarkfile.c | 0 .../glib-2.20.1/build/glib/gbookmarkfile.h | 0 .../glib-2.20.1/build/glib/gbsearcharray.h | 0 .../windows/glib-2.20.1/build/glib/gcache.c | 0 .../windows/glib-2.20.1/build/glib/gcache.h | 0 .../glib-2.20.1/build/glib/gchecksum.c | 0 .../glib-2.20.1/build/glib/gchecksum.h | 0 .../glib-2.20.1/build/glib/gcompletion.c | 0 .../glib-2.20.1/build/glib/gcompletion.h | 0 .../windows/glib-2.20.1/build/glib/gconvert.c | 0 .../windows/glib-2.20.1/build/glib/gconvert.h | 0 .../windows/glib-2.20.1/build/glib/gdataset.c | 0 .../windows/glib-2.20.1/build/glib/gdataset.h | 0 .../glib-2.20.1/build/glib/gdatasetprivate.h | 0 .../windows/glib-2.20.1/build/glib/gdate.c | 0 .../windows/glib-2.20.1/build/glib/gdate.h | 0 .../windows/glib-2.20.1/build/glib/gdebug.h | 0 .../windows/glib-2.20.1/build/glib/gdir.c | 0 .../windows/glib-2.20.1/build/glib/gdir.h | 0 .../windows/glib-2.20.1/build/glib/gerror.c | 0 .../windows/glib-2.20.1/build/glib/gerror.h | 0 .../glib-2.20.1/build/glib/gfileutils.c | 0 .../glib-2.20.1/build/glib/gfileutils.h | 0 .../windows/glib-2.20.1/build/glib/ghash.c | 0 .../windows/glib-2.20.1/build/glib/ghash.h | 0 .../windows/glib-2.20.1/build/glib/ghook.c | 0 .../windows/glib-2.20.1/build/glib/ghook.h | 0 .../glib-2.20.1/build/glib/gi18n-lib.h | 0 .../windows/glib-2.20.1/build/glib/gi18n.h | 0 .../glib-2.20.1/build/glib/giochannel.c | 0 .../glib-2.20.1/build/glib/giochannel.h | 0 .../windows/glib-2.20.1/build/glib/giounix.c | 0 .../windows/glib-2.20.1/build/glib/giowin32.c | 0 .../windows/glib-2.20.1/build/glib/gkeyfile.c | 0 .../windows/glib-2.20.1/build/glib/gkeyfile.h | 0 .../glib-2.20.1/build/glib/glib-object.h | 0 .../windows/glib-2.20.1/build/glib/glib.h | 0 .../windows/glib-2.20.1/build/glib/glibintl.h | 0 .../windows/glib-2.20.1/build/glib/glist.c | 0 .../windows/glib-2.20.1/build/glib/glist.h | 0 .../windows/glib-2.20.1/build/glib/gmacros.h | 0 .../windows/glib-2.20.1/build/glib/gmain.c | 0 .../windows/glib-2.20.1/build/glib/gmain.h | 0 .../glib-2.20.1/build/glib/gmappedfile.c | 0 .../glib-2.20.1/build/glib/gmappedfile.h | 0 .../windows/glib-2.20.1/build/glib/gmarkup.c | 0 .../windows/glib-2.20.1/build/glib/gmarkup.h | 0 .../windows/glib-2.20.1/build/glib/gmem.c | 0 .../windows/glib-2.20.1/build/glib/gmem.h | 0 .../glib-2.20.1/build/glib/gmessages.c | 0 .../glib-2.20.1/build/glib/gmessages.h | 0 .../glib-2.20.1/build/glib/gmirroringtable.h | 0 .../windows/glib-2.20.1/build/glib/gnode.c | 0 .../windows/glib-2.20.1/build/glib/gnode.h | 0 .../glib-2.20.1/build/glib/gnulib/README | 0 .../glib-2.20.1/build/glib/gnulib/asnprintf.c | 0 .../glib-2.20.1/build/glib/gnulib/g-gnulib.h | 0 .../build/glib/gnulib/printf-args.c | 0 .../build/glib/gnulib/printf-args.h | 0 .../build/glib/gnulib/printf-parse.c | 0 .../build/glib/gnulib/printf-parse.h | 0 .../glib-2.20.1/build/glib/gnulib/printf.c | 0 .../glib-2.20.1/build/glib/gnulib/printf.h | 0 .../build/glib/gnulib/vasnprintf.c | 0 .../build/glib/gnulib/vasnprintf.h | 0 .../windows/glib-2.20.1/build/glib/goption.c | 0 .../windows/glib-2.20.1/build/glib/goption.h | 0 .../windows/glib-2.20.1/build/glib/gpattern.c | 0 .../windows/glib-2.20.1/build/glib/gpattern.h | 0 .../windows/glib-2.20.1/build/glib/gpoll.c | 0 .../windows/glib-2.20.1/build/glib/gpoll.h | 0 .../windows/glib-2.20.1/build/glib/gprimes.c | 0 .../windows/glib-2.20.1/build/glib/gprimes.h | 0 .../windows/glib-2.20.1/build/glib/gprintf.c | 0 .../windows/glib-2.20.1/build/glib/gprintf.h | 0 .../glib-2.20.1/build/glib/gprintfint.h | 0 .../windows/glib-2.20.1/build/glib/gqsort.c | 0 .../windows/glib-2.20.1/build/glib/gqsort.h | 0 .../windows/glib-2.20.1/build/glib/gquark.h | 0 .../windows/glib-2.20.1/build/glib/gqueue.c | 0 .../windows/glib-2.20.1/build/glib/gqueue.h | 0 .../windows/glib-2.20.1/build/glib/grand.c | 0 .../windows/glib-2.20.1/build/glib/grand.h | 0 .../windows/glib-2.20.1/build/glib/gregex.c | 0 .../windows/glib-2.20.1/build/glib/gregex.h | 0 .../windows/glib-2.20.1/build/glib/grel.c | 0 .../windows/glib-2.20.1/build/glib/grel.h | 0 .../windows/glib-2.20.1/build/glib/gscanner.c | 0 .../windows/glib-2.20.1/build/glib/gscanner.h | 0 .../glib-2.20.1/build/glib/gscripttable.h | 0 .../glib-2.20.1/build/glib/gsequence.c | 0 .../glib-2.20.1/build/glib/gsequence.h | 0 .../windows/glib-2.20.1/build/glib/gshell.c | 0 .../windows/glib-2.20.1/build/glib/gshell.h | 0 .../windows/glib-2.20.1/build/glib/gslice.c | 0 .../windows/glib-2.20.1/build/glib/gslice.h | 0 .../windows/glib-2.20.1/build/glib/gslist.c | 0 .../windows/glib-2.20.1/build/glib/gslist.h | 0 .../build/glib/gspawn-win32-helper-console.c | 0 .../build/glib/gspawn-win32-helper.c | 0 .../glib-2.20.1/build/glib/gspawn-win32.c | 0 .../build/glib/gspawn-win64-helper-console.c | 0 .../build/glib/gspawn-win64-helper.c | 0 .../windows/glib-2.20.1/build/glib/gspawn.c | 0 .../windows/glib-2.20.1/build/glib/gspawn.h | 0 .../windows/glib-2.20.1/build/glib/gstdio.c | 0 .../windows/glib-2.20.1/build/glib/gstdio.h | 0 .../glib-2.20.1/build/glib/gstrfuncs.c | 0 .../glib-2.20.1/build/glib/gstrfuncs.h | 0 .../windows/glib-2.20.1/build/glib/gstring.c | 0 .../windows/glib-2.20.1/build/glib/gstring.h | 0 .../windows/glib-2.20.1/build/glib/gtester.c | 0 .../glib-2.20.1/build/glib/gtestutils.c | 0 .../glib-2.20.1/build/glib/gtestutils.h | 0 .../windows/glib-2.20.1/build/glib/gthread.c | 0 .../windows/glib-2.20.1/build/glib/gthread.h | 0 .../glib-2.20.1/build/glib/gthreadpool.c | 0 .../glib-2.20.1/build/glib/gthreadpool.h | 0 .../glib-2.20.1/build/glib/gthreadprivate.h | 0 .../windows/glib-2.20.1/build/glib/gtimer.c | 0 .../windows/glib-2.20.1/build/glib/gtimer.h | 0 .../windows/glib-2.20.1/build/glib/gtree.c | 0 .../windows/glib-2.20.1/build/glib/gtree.h | 0 .../windows/glib-2.20.1/build/glib/gtypes.h | 0 .../glib-2.20.1/build/glib/gunibreak.c | 0 .../glib-2.20.1/build/glib/gunibreak.h | 0 .../glib-2.20.1/build/glib/gunichartables.h | 0 .../windows/glib-2.20.1/build/glib/gunicode.h | 0 .../glib-2.20.1/build/glib/gunicodeprivate.h | 0 .../glib-2.20.1/build/glib/gunicollate.c | 0 .../windows/glib-2.20.1/build/glib/gunicomp.h | 0 .../glib-2.20.1/build/glib/gunidecomp.c | 0 .../glib-2.20.1/build/glib/gunidecomp.h | 0 .../windows/glib-2.20.1/build/glib/guniprop.c | 0 .../glib-2.20.1/build/glib/gurifuncs.c | 0 .../glib-2.20.1/build/glib/gurifuncs.h | 0 .../windows/glib-2.20.1/build/glib/gutf8.c | 0 .../windows/glib-2.20.1/build/glib/gutils.c | 0 .../windows/glib-2.20.1/build/glib/gutils.h | 0 .../windows/glib-2.20.1/build/glib/gwin32.c | 0 .../windows/glib-2.20.1/build/glib/gwin32.h | 0 .../glib-2.20.1/build/glib/libcharset/README | 0 .../build/glib/libcharset/libcharset.h | 0 .../build/glib/libcharset/localcharset.c | 0 .../build/glib/libcharset/localcharset.h | 0 .../windows/glib-2.20.1/build/glib/libintl.h | 0 .../build/glib/msvc_recommended_pragmas.h | 0 .../glib-2.20.1/build/glib/pcre/COPYING | 0 .../glib-2.20.1/build/glib/pcre/pcre.h | 0 .../build/glib/pcre/pcre_chartables.c | 0 .../build/glib/pcre/pcre_compile.c | 0 .../glib-2.20.1/build/glib/pcre/pcre_config.c | 0 .../build/glib/pcre/pcre_dfa_exec.c | 0 .../glib-2.20.1/build/glib/pcre/pcre_exec.c | 0 .../build/glib/pcre/pcre_fullinfo.c | 0 .../glib-2.20.1/build/glib/pcre/pcre_get.c | 0 .../build/glib/pcre/pcre_globals.c | 0 .../glib-2.20.1/build/glib/pcre/pcre_info.c | 0 .../build/glib/pcre/pcre_internal.h | 0 .../build/glib/pcre/pcre_maketables.c | 0 .../build/glib/pcre/pcre_newline.c | 0 .../build/glib/pcre/pcre_ord2utf8.c | 0 .../build/glib/pcre/pcre_refcount.c | 0 .../glib-2.20.1/build/glib/pcre/pcre_study.c | 0 .../glib-2.20.1/build/glib/pcre/pcre_tables.c | 0 .../build/glib/pcre/pcre_try_flipped.c | 0 .../build/glib/pcre/pcre_ucp_searchfuncs.c | 0 .../build/glib/pcre/pcre_valid_utf8.c | 0 .../build/glib/pcre/pcre_version.c | 0 .../glib-2.20.1/build/glib/pcre/pcre_xclass.c | 0 .../windows/glib-2.20.1/build/glib/pcre/ucp.h | 0 .../glib-2.20.1/build/glib/pcre/ucpinternal.h | 0 .../glib-2.20.1/build/glib/win_iconv.c | 0 .../windows/glib-2.20.1/build/glibconfig.h | 0 .../windows/glib-2.20.1/build/vs8/README | 0 .../windows/glib-2.20.1/build/vs8/gio.vcproj | 0 .../windows/glib-2.20.1/build/vs8/glib.sln | 0 .../windows/glib-2.20.1/build/vs8/glib.vcproj | 12 +- .../glib-2.20.1/lib/glib-2.20.1-x86.lib | Bin 0 -> 1818038 bytes .../glib-2.20.1/modified_for_desmume.txt | 0 {desmume/src => src}/windows/hotkey.cpp | 79 +- {desmume/src => src}/windows/hotkey.h | 2 - {desmume/src => src}/windows/inputdx.cpp | 199 +- {desmume/src => src}/windows/inputdx.h | 562 +- .../windows/langs/build_utils/gettextlib.dll | Bin .../windows/langs/build_utils/gettextpo.dll | Bin .../windows/langs/build_utils/gettextsrc.dll | Bin .../windows/langs/build_utils/iconv.dll | Bin .../windows/langs/build_utils/intl.dll | Bin .../windows/langs/build_utils/libiconv-2.dll | Bin .../windows/langs/build_utils/msgfmt.exe | Bin {desmume/src => src}/windows/langs/fr_FR.mo | Bin {desmume/src => src}/windows/lightView.cpp | 368 +- {desmume/src => src}/windows/lightView.h | 52 +- .../windows/lua/lib/lua-5.1.4-x86.lib | Bin .../windows/lua/lua-5.1.4/COPYRIGHT | 0 .../windows/lua/lua-5.1.4/src/Makefile | 0 .../windows/lua/lua-5.1.4/src/lapi.c | 0 .../windows/lua/lua-5.1.4/src/lapi.h | 0 .../windows/lua/lua-5.1.4/src/lauxlib.c | 0 .../windows/lua/lua-5.1.4/src/lauxlib.h | 0 .../windows/lua/lua-5.1.4/src/lbaselib.c | 0 .../windows/lua/lua-5.1.4/src/lcode.c | 0 .../windows/lua/lua-5.1.4/src/lcode.h | 0 .../windows/lua/lua-5.1.4/src/ldblib.c | 0 .../windows/lua/lua-5.1.4/src/ldebug.c | 0 .../windows/lua/lua-5.1.4/src/ldebug.h | 0 .../windows/lua/lua-5.1.4/src/ldo.c | 0 .../windows/lua/lua-5.1.4/src/ldo.h | 0 .../windows/lua/lua-5.1.4/src/ldump.c | 0 .../windows/lua/lua-5.1.4/src/lfunc.c | 0 .../windows/lua/lua-5.1.4/src/lfunc.h | 0 .../windows/lua/lua-5.1.4/src/lgc.c | 0 .../windows/lua/lua-5.1.4/src/lgc.h | 0 .../windows/lua/lua-5.1.4/src/linit.c | 0 .../windows/lua/lua-5.1.4/src/liolib.c | 0 .../windows/lua/lua-5.1.4/src/llex.c | 0 .../windows/lua/lua-5.1.4/src/llex.h | 0 .../windows/lua/lua-5.1.4/src/llimits.h | 0 .../windows/lua/lua-5.1.4/src/lmathlib.c | 0 .../windows/lua/lua-5.1.4/src/lmem.c | 0 .../windows/lua/lua-5.1.4/src/lmem.h | 0 .../windows/lua/lua-5.1.4/src/loadlib.c | 0 .../windows/lua/lua-5.1.4/src/lobject.c | 0 .../windows/lua/lua-5.1.4/src/lobject.h | 0 .../windows/lua/lua-5.1.4/src/lopcodes.c | 0 .../windows/lua/lua-5.1.4/src/lopcodes.h | 0 .../windows/lua/lua-5.1.4/src/loslib.c | 0 .../windows/lua/lua-5.1.4/src/lparser.c | 0 .../windows/lua/lua-5.1.4/src/lparser.h | 0 .../windows/lua/lua-5.1.4/src/lstate.c | 0 .../windows/lua/lua-5.1.4/src/lstate.h | 0 .../windows/lua/lua-5.1.4/src/lstring.c | 0 .../windows/lua/lua-5.1.4/src/lstring.h | 0 .../windows/lua/lua-5.1.4/src/lstrlib.c | 0 .../windows/lua/lua-5.1.4/src/ltable.c | 0 .../windows/lua/lua-5.1.4/src/ltable.h | 0 .../windows/lua/lua-5.1.4/src/ltablib.c | 0 .../windows/lua/lua-5.1.4/src/ltm.c | 0 .../windows/lua/lua-5.1.4/src/ltm.h | 0 .../windows/lua/lua-5.1.4/src/lua.c | 0 .../windows/lua/lua-5.1.4/src/lua.h | 0 .../windows/lua/lua-5.1.4/src/luac.c | 0 .../windows/lua/lua-5.1.4/src/luaconf.h | 0 .../windows/lua/lua-5.1.4/src/lualib.h | 0 .../windows/lua/lua-5.1.4/src/lundump.c | 0 .../windows/lua/lua-5.1.4/src/lundump.h | 0 .../windows/lua/lua-5.1.4/src/lvm.c | 0 .../windows/lua/lua-5.1.4/src/lvm.h | 0 .../windows/lua/lua-5.1.4/src/lzio.c | 0 .../windows/lua/lua-5.1.4/src/lzio.h | 0 .../windows/lua/lua-5.1.4/src/print.c | 0 {desmume/src => src}/windows/lua/vs8/lua.sln | 0 .../src => src}/windows/lua/vs8/lua.vcproj | 0 {desmume/src => src}/windows/luaconsole.cpp | 1412 +- {desmume/src => src}/windows/main.cpp | 1342 +- {desmume/src => src}/windows/main.h | 1 + src/windows/mapView.cpp | 298 + {desmume/src => src}/windows/mapView.h | 56 +- {desmume/src => src}/windows/matrixView.cpp | 512 +- {desmume/src => src}/windows/matrixView.h | 52 +- {desmume/src => src}/windows/memView.cpp | 1626 +- {desmume/src => src}/windows/memView.h | 70 +- {desmume/src => src}/windows/mic.cpp | 33 +- {desmume/src => src}/windows/oamView.cpp | 696 +- {desmume/src => src}/windows/oamView.h | 60 +- {desmume/src => src}/windows/ogl.cpp | 196 +- {desmume/src => src}/windows/palView.cpp | 590 +- {desmume/src => src}/windows/palView.h | 58 +- src/windows/pathsettings.cpp | 615 + src/windows/pathsettings.h | 90 + {desmume/src => src}/windows/ram_search.cpp | 1 - {desmume/src => src}/windows/ram_search.h | 104 +- {desmume/src => src}/windows/ramwatch.cpp | 7 +- {desmume/src => src}/windows/ramwatch.h | 84 +- {desmume/src => src}/windows/replay.cpp | 47 +- {desmume/src => src}/windows/replay.h | 4 +- {desmume/src => src}/windows/resource.h | 66 +- {desmume/src => src}/windows/resources.rc | Bin 686088 -> 681344 bytes src/windows/snddx.cpp | 319 + {desmume/src => src}/windows/snddx.h | 50 +- {desmume/src => src}/windows/soundView.cpp | 608 +- {desmume/src => src}/windows/soundView.h | 0 {desmume/src => src}/windows/throttle.cpp | 218 +- {desmume/src => src}/windows/throttle.h | 22 +- {desmume/src => src}/windows/tileView.cpp | 1316 +- {desmume/src => src}/windows/tileView.h | 64 +- src/windows/wavout.cpp | 204 + src/windows/wavout.h | 4 + {desmume/src => src}/windows/windriver.h | 87 +- .../src => src}/windows/winpcap/Devioctl.h | 180 +- {desmume/src => src}/windows/winpcap/Gnuc.h | 92 +- .../src => src}/windows/winpcap/Ntddndis.h | 2800 +-- .../src => src}/windows/winpcap/Ntddpack.h | 52 +- .../src => src}/windows/winpcap/Packet.lib | Bin .../src => src}/windows/winpcap/Packet32.h | 810 +- .../windows/winpcap/Win32-Extensions.h | 226 +- .../src => src}/windows/winpcap/bittypes.h | 270 +- .../windows/winpcap/bucket_lookup.h | 106 +- .../windows/winpcap/count_packets.h | 124 +- .../src => src}/windows/winpcap/ip6_misc.h | 330 +- .../src => src}/windows/winpcap/memory_t.h | 266 +- .../windows/winpcap/normal_lookup.h | 110 +- .../src => src}/windows/winpcap/pcap-bpf.h | 1472 +- .../src => src}/windows/winpcap/pcap-int.h | 746 +- .../src => src}/windows/winpcap/pcap-stdinc.h | 128 +- {desmume/src => src}/windows/winpcap/pcap.h | 688 +- .../src => src}/windows/winpcap/remote-ext.h | 882 +- .../src => src}/windows/winpcap/tcp_session.h | 190 +- .../src => src}/windows/winpcap/time_calls.h | 970 +- {desmume/src => src}/windows/winpcap/tme.h | 350 +- .../src => src}/windows/winpcap/wpcap.lib | Bin {desmume/src => src}/windows/winres.h | 0 {desmume/src => src}/windows/zlib123/README | 0 {desmume/src => src}/windows/zlib123/zconf.h | 664 +- .../windows/zlib123/zlib-2005-x32.lib | Bin .../windows/zlib123/zlib-2005-x64.lib | Bin .../windows/zlib123/zlib-2008-x32.lib | Bin .../windows/zlib123/zlib-2008-x64.lib | Bin {desmume/src => src}/windows/zlib123/zlib.h | 2714 +-- {desmume/src => src}/windows/zlib123/zutil.h | 538 +- {desmume/src => src}/windows/zziplib/README | 0 .../src => src}/windows/zziplib/zzip/_msvc.h | 426 +- .../src => src}/windows/zziplib/zzip/conf.h | 1080 +- .../src => src}/windows/zziplib/zzip/types.h | 114 +- .../src => src}/windows/zziplib/zzip/zzip.h | 536 +- .../windows/zziplib/zziplib-2005-x32.lib | Bin .../windows/zziplib/zziplib-2005-x64.lib | Bin .../windows/zziplib/zziplib-2008-x32.lib | Bin .../windows/zziplib/zziplib-2008-x64.lib | Bin 1231 files changed, 73764 insertions(+), 151838 deletions(-) rename desmume/AUTHORS => AUTHORS (71%) rename desmume/COPYING => COPYING (100%) rename desmume/ChangeLog => ChangeLog (82%) rename desmume/Makefile.am => Makefile.am (100%) rename desmume/NEWS => NEWS (100%) rename desmume/README => README (100%) rename desmume/README.LIN => README.LIN (100%) rename desmume/README.MAC => README.MAC (100%) rename desmume/README.TRANSLATION => README.TRANSLATION (100%) create mode 100644 README.WIN rename desmume/TODO => TODO (100%) rename desmume/autogen.sh => autogen.sh (100%) mode change 100755 => 100644 rename {desmume/autopackage => autopackage}/default.apspec.in (100%) rename desmume/compile => compile (100%) mode change 100755 => 100644 rename desmume/configure.ac => configure.ac (83%) delete mode 100644 desmume/README.WIN delete mode 100644 desmume/dsv.txt delete mode 100644 desmume/po/zh_CN.po delete mode 100644 desmume/src/GPU_osd.cpp delete mode 100644 desmume/src/PACKED_END.h delete mode 100644 desmume/src/addons/guitarGrip.cpp delete mode 100644 desmume/src/agg2d.h delete mode 100644 desmume/src/agg2d.inl delete mode 100644 desmume/src/aggdraw.cpp delete mode 100644 desmume/src/aggdraw.h delete mode 100644 desmume/src/cocoa/translations/Chinese.lproj/Localizable.strings delete mode 100644 desmume/src/cocoa/translations/Chinese.lproj/MainMenu.nib/info.nib delete mode 100644 desmume/src/cocoa/translations/Chinese.lproj/MainMenu.nib/keyedobjects.nib delete mode 100644 desmume/src/cocoa/translations/Italian.lproj/MainMenu.nib/classes.nib delete mode 100644 desmume/src/fat.h delete mode 100644 desmume/src/gtk/cheatsGTK.cpp delete mode 100644 desmume/src/gtk/cheatsGTK.h delete mode 100644 desmume/src/gtk/main.h delete mode 100644 desmume/src/matrix.h delete mode 100644 desmume/src/mc.cpp delete mode 100644 desmume/src/mic.cpp delete mode 100644 desmume/src/mic.h delete mode 100644 desmume/src/mic_alsa.cpp delete mode 100644 desmume/src/path.h delete mode 100644 desmume/src/version.h delete mode 100644 desmume/src/windows/DeSmuME_2010.sln delete mode 100644 desmume/src/windows/DeSmuME_2010.vcxproj delete mode 100644 desmume/src/windows/agg/agg-2.5.lib delete mode 100644 desmume/src/windows/agg/agg-2.5.sln delete mode 100644 desmume/src/windows/agg/agg-2.5.vcproj delete mode 100644 desmume/src/windows/agg/examples/pixel_formats.h delete mode 100644 desmume/src/windows/agg/font_freetype/agg_font_freetype.cpp delete mode 100644 desmume/src/windows/agg/font_freetype/agg_font_freetype.h delete mode 100644 desmume/src/windows/agg/font_win32_tt/agg_font_win32_tt.cpp delete mode 100644 desmume/src/windows/agg/font_win32_tt/agg_font_win32_tt.h delete mode 100644 desmume/src/windows/agg/include/agg_alpha_mask_u8.h delete mode 100644 desmume/src/windows/agg/include/agg_arc.h delete mode 100644 desmume/src/windows/agg/include/agg_array.h delete mode 100644 desmume/src/windows/agg/include/agg_arrowhead.h delete mode 100644 desmume/src/windows/agg/include/agg_basics.h delete mode 100644 desmume/src/windows/agg/include/agg_bezier_arc.h delete mode 100644 desmume/src/windows/agg/include/agg_bitset_iterator.h delete mode 100644 desmume/src/windows/agg/include/agg_blur.h delete mode 100644 desmume/src/windows/agg/include/agg_bounding_rect.h delete mode 100644 desmume/src/windows/agg/include/agg_bspline.h delete mode 100644 desmume/src/windows/agg/include/agg_clip_liang_barsky.h delete mode 100644 desmume/src/windows/agg/include/agg_color_gray.h delete mode 100644 desmume/src/windows/agg/include/agg_color_rgba.h delete mode 100644 desmume/src/windows/agg/include/agg_config.h delete mode 100644 desmume/src/windows/agg/include/agg_conv_adaptor_vcgen.h delete mode 100644 desmume/src/windows/agg/include/agg_conv_adaptor_vpgen.h delete mode 100644 desmume/src/windows/agg/include/agg_conv_bspline.h delete mode 100644 desmume/src/windows/agg/include/agg_conv_clip_polygon.h delete mode 100644 desmume/src/windows/agg/include/agg_conv_clip_polyline.h delete mode 100644 desmume/src/windows/agg/include/agg_conv_close_polygon.h delete mode 100644 desmume/src/windows/agg/include/agg_conv_concat.h delete mode 100644 desmume/src/windows/agg/include/agg_conv_contour.h delete mode 100644 desmume/src/windows/agg/include/agg_conv_curve.h delete mode 100644 desmume/src/windows/agg/include/agg_conv_dash.h delete mode 100644 desmume/src/windows/agg/include/agg_conv_gpc.h delete mode 100644 desmume/src/windows/agg/include/agg_conv_marker.h delete mode 100644 desmume/src/windows/agg/include/agg_conv_marker_adaptor.h delete mode 100644 desmume/src/windows/agg/include/agg_conv_segmentator.h delete mode 100644 desmume/src/windows/agg/include/agg_conv_shorten_path.h delete mode 100644 desmume/src/windows/agg/include/agg_conv_smooth_poly1.h delete mode 100644 desmume/src/windows/agg/include/agg_conv_stroke.h delete mode 100644 desmume/src/windows/agg/include/agg_conv_transform.h delete mode 100644 desmume/src/windows/agg/include/agg_conv_unclose_polygon.h delete mode 100644 desmume/src/windows/agg/include/agg_curves.h delete mode 100644 desmume/src/windows/agg/include/agg_dda_line.h delete mode 100644 desmume/src/windows/agg/include/agg_ellipse.h delete mode 100644 desmume/src/windows/agg/include/agg_ellipse_bresenham.h delete mode 100644 desmume/src/windows/agg/include/agg_embedded_raster_fonts.h delete mode 100644 desmume/src/windows/agg/include/agg_font_cache_manager.h delete mode 100644 desmume/src/windows/agg/include/agg_gamma_functions.h delete mode 100644 desmume/src/windows/agg/include/agg_gamma_lut.h delete mode 100644 desmume/src/windows/agg/include/agg_glyph_raster_bin.h delete mode 100644 desmume/src/windows/agg/include/agg_gradient_lut.h delete mode 100644 desmume/src/windows/agg/include/agg_gsv_text.h delete mode 100644 desmume/src/windows/agg/include/agg_image_accessors.h delete mode 100644 desmume/src/windows/agg/include/agg_image_filters.h delete mode 100644 desmume/src/windows/agg/include/agg_line_aa_basics.h delete mode 100644 desmume/src/windows/agg/include/agg_math.h delete mode 100644 desmume/src/windows/agg/include/agg_math_stroke.h delete mode 100644 desmume/src/windows/agg/include/agg_path_length.h delete mode 100644 desmume/src/windows/agg/include/agg_path_storage.h delete mode 100644 desmume/src/windows/agg/include/agg_path_storage_integer.h delete mode 100644 desmume/src/windows/agg/include/agg_pattern_filters_rgba.h delete mode 100644 desmume/src/windows/agg/include/agg_pixfmt_amask_adaptor.h delete mode 100644 desmume/src/windows/agg/include/agg_pixfmt_gray.h delete mode 100644 desmume/src/windows/agg/include/agg_pixfmt_rgb.h delete mode 100644 desmume/src/windows/agg/include/agg_pixfmt_rgb_packed.h delete mode 100644 desmume/src/windows/agg/include/agg_pixfmt_rgba.h delete mode 100644 desmume/src/windows/agg/include/agg_pixfmt_transposer.h delete mode 100644 desmume/src/windows/agg/include/agg_rasterizer_cells_aa.h delete mode 100644 desmume/src/windows/agg/include/agg_rasterizer_compound_aa.h delete mode 100644 desmume/src/windows/agg/include/agg_rasterizer_outline.h delete mode 100644 desmume/src/windows/agg/include/agg_rasterizer_outline_aa.h delete mode 100644 desmume/src/windows/agg/include/agg_rasterizer_scanline_aa.h delete mode 100644 desmume/src/windows/agg/include/agg_rasterizer_sl_clip.h delete mode 100644 desmume/src/windows/agg/include/agg_renderer_base.h delete mode 100644 desmume/src/windows/agg/include/agg_renderer_markers.h delete mode 100644 desmume/src/windows/agg/include/agg_renderer_mclip.h delete mode 100644 desmume/src/windows/agg/include/agg_renderer_outline_aa.h delete mode 100644 desmume/src/windows/agg/include/agg_renderer_outline_image.h delete mode 100644 desmume/src/windows/agg/include/agg_renderer_primitives.h delete mode 100644 desmume/src/windows/agg/include/agg_renderer_raster_text.h delete mode 100644 desmume/src/windows/agg/include/agg_renderer_scanline.h delete mode 100644 desmume/src/windows/agg/include/agg_rendering_buffer.h delete mode 100644 desmume/src/windows/agg/include/agg_rendering_buffer_dynarow.h delete mode 100644 desmume/src/windows/agg/include/agg_rounded_rect.h delete mode 100644 desmume/src/windows/agg/include/agg_scanline_bin.h delete mode 100644 desmume/src/windows/agg/include/agg_scanline_boolean_algebra.h delete mode 100644 desmume/src/windows/agg/include/agg_scanline_p.h delete mode 100644 desmume/src/windows/agg/include/agg_scanline_storage_aa.h delete mode 100644 desmume/src/windows/agg/include/agg_scanline_storage_bin.h delete mode 100644 desmume/src/windows/agg/include/agg_scanline_u.h delete mode 100644 desmume/src/windows/agg/include/agg_shorten_path.h delete mode 100644 desmume/src/windows/agg/include/agg_simul_eq.h delete mode 100644 desmume/src/windows/agg/include/agg_span_allocator.h delete mode 100644 desmume/src/windows/agg/include/agg_span_converter.h delete mode 100644 desmume/src/windows/agg/include/agg_span_gouraud.h delete mode 100644 desmume/src/windows/agg/include/agg_span_gouraud_gray.h delete mode 100644 desmume/src/windows/agg/include/agg_span_gouraud_rgba.h delete mode 100644 desmume/src/windows/agg/include/agg_span_gradient.h delete mode 100644 desmume/src/windows/agg/include/agg_span_gradient_alpha.h delete mode 100644 desmume/src/windows/agg/include/agg_span_image_filter.h delete mode 100644 desmume/src/windows/agg/include/agg_span_image_filter_gray.h delete mode 100644 desmume/src/windows/agg/include/agg_span_image_filter_rgb.h delete mode 100644 desmume/src/windows/agg/include/agg_span_image_filter_rgba.h delete mode 100644 desmume/src/windows/agg/include/agg_span_interpolator_adaptor.h delete mode 100644 desmume/src/windows/agg/include/agg_span_interpolator_linear.h delete mode 100644 desmume/src/windows/agg/include/agg_span_interpolator_persp.h delete mode 100644 desmume/src/windows/agg/include/agg_span_interpolator_trans.h delete mode 100644 desmume/src/windows/agg/include/agg_span_pattern_gray.h delete mode 100644 desmume/src/windows/agg/include/agg_span_pattern_rgb.h delete mode 100644 desmume/src/windows/agg/include/agg_span_pattern_rgba.h delete mode 100644 desmume/src/windows/agg/include/agg_span_solid.h delete mode 100644 desmume/src/windows/agg/include/agg_span_subdiv_adaptor.h delete mode 100644 desmume/src/windows/agg/include/agg_trans_affine.h delete mode 100644 desmume/src/windows/agg/include/agg_trans_bilinear.h delete mode 100644 desmume/src/windows/agg/include/agg_trans_double_path.h delete mode 100644 desmume/src/windows/agg/include/agg_trans_perspective.h delete mode 100644 desmume/src/windows/agg/include/agg_trans_single_path.h delete mode 100644 desmume/src/windows/agg/include/agg_trans_viewport.h delete mode 100644 desmume/src/windows/agg/include/agg_trans_warp_magnifier.h delete mode 100644 desmume/src/windows/agg/include/agg_vcgen_bspline.h delete mode 100644 desmume/src/windows/agg/include/agg_vcgen_contour.h delete mode 100644 desmume/src/windows/agg/include/agg_vcgen_dash.h delete mode 100644 desmume/src/windows/agg/include/agg_vcgen_markers_term.h delete mode 100644 desmume/src/windows/agg/include/agg_vcgen_smooth_poly1.h delete mode 100644 desmume/src/windows/agg/include/agg_vcgen_stroke.h delete mode 100644 desmume/src/windows/agg/include/agg_vcgen_vertex_sequence.h delete mode 100644 desmume/src/windows/agg/include/agg_vertex_sequence.h delete mode 100644 desmume/src/windows/agg/include/agg_vpgen_clip_polygon.h delete mode 100644 desmume/src/windows/agg/include/agg_vpgen_clip_polyline.h delete mode 100644 desmume/src/windows/agg/include/agg_vpgen_segmentator.h delete mode 100644 desmume/src/windows/agg/include/ctrl/agg_bezier_ctrl.h delete mode 100644 desmume/src/windows/agg/include/ctrl/agg_cbox_ctrl.h delete mode 100644 desmume/src/windows/agg/include/ctrl/agg_ctrl.h delete mode 100644 desmume/src/windows/agg/include/ctrl/agg_gamma_ctrl.h delete mode 100644 desmume/src/windows/agg/include/ctrl/agg_gamma_spline.h delete mode 100644 desmume/src/windows/agg/include/ctrl/agg_polygon_ctrl.h delete mode 100644 desmume/src/windows/agg/include/ctrl/agg_rbox_ctrl.h delete mode 100644 desmume/src/windows/agg/include/ctrl/agg_scale_ctrl.h delete mode 100644 desmume/src/windows/agg/include/ctrl/agg_slider_ctrl.h delete mode 100644 desmume/src/windows/agg/include/ctrl/agg_spline_ctrl.h delete mode 100644 desmume/src/windows/agg/include/platform/agg_platform_support.h delete mode 100644 desmume/src/windows/agg/include/platform/mac/agg_mac_pmap.h delete mode 100644 desmume/src/windows/agg/include/platform/win32/agg_win32_bmp.h delete mode 100644 desmume/src/windows/agg/include/util/agg_color_conv.h delete mode 100644 desmume/src/windows/agg/include/util/agg_color_conv_rgb16.h delete mode 100644 desmume/src/windows/agg/include/util/agg_color_conv_rgb8.h delete mode 100644 desmume/src/windows/agg/src/ChangeLog delete mode 100644 desmume/src/windows/agg/src/Makefile delete mode 100644 desmume/src/windows/agg/src/agg_arc.cpp delete mode 100644 desmume/src/windows/agg/src/agg_arrowhead.cpp delete mode 100644 desmume/src/windows/agg/src/agg_bezier_arc.cpp delete mode 100644 desmume/src/windows/agg/src/agg_bspline.cpp delete mode 100644 desmume/src/windows/agg/src/agg_curves.cpp delete mode 100644 desmume/src/windows/agg/src/agg_embedded_raster_fonts.cpp delete mode 100644 desmume/src/windows/agg/src/agg_gsv_text.cpp delete mode 100644 desmume/src/windows/agg/src/agg_image_filters.cpp delete mode 100644 desmume/src/windows/agg/src/agg_line_aa_basics.cpp delete mode 100644 desmume/src/windows/agg/src/agg_line_profile_aa.cpp delete mode 100644 desmume/src/windows/agg/src/agg_rounded_rect.cpp delete mode 100644 desmume/src/windows/agg/src/agg_sqrt_tables.cpp delete mode 100644 desmume/src/windows/agg/src/agg_trans_affine.cpp delete mode 100644 desmume/src/windows/agg/src/agg_trans_double_path.cpp delete mode 100644 desmume/src/windows/agg/src/agg_trans_single_path.cpp delete mode 100644 desmume/src/windows/agg/src/agg_trans_warp_magnifier.cpp delete mode 100644 desmume/src/windows/agg/src/agg_vcgen_bspline.cpp delete mode 100644 desmume/src/windows/agg/src/agg_vcgen_contour.cpp delete mode 100644 desmume/src/windows/agg/src/agg_vcgen_dash.cpp delete mode 100644 desmume/src/windows/agg/src/agg_vcgen_markers_term.cpp delete mode 100644 desmume/src/windows/agg/src/agg_vcgen_smooth_poly1.cpp delete mode 100644 desmume/src/windows/agg/src/agg_vcgen_stroke.cpp delete mode 100644 desmume/src/windows/agg/src/agg_vpgen_clip_polygon.cpp delete mode 100644 desmume/src/windows/agg/src/agg_vpgen_clip_polyline.cpp delete mode 100644 desmume/src/windows/agg/src/agg_vpgen_segmentator.cpp delete mode 100644 desmume/src/windows/agg/src/authors delete mode 100644 desmume/src/windows/agg/src/autogen.sh delete mode 100644 desmume/src/windows/agg/src/configure.in delete mode 100644 desmume/src/windows/agg/src/copying delete mode 100644 desmume/src/windows/agg/src/ctrl/agg_bezier_ctrl.cpp delete mode 100644 desmume/src/windows/agg/src/ctrl/agg_cbox_ctrl.cpp delete mode 100644 desmume/src/windows/agg/src/ctrl/agg_gamma_ctrl.cpp delete mode 100644 desmume/src/windows/agg/src/ctrl/agg_gamma_spline.cpp delete mode 100644 desmume/src/windows/agg/src/ctrl/agg_polygon_ctrl.cpp delete mode 100644 desmume/src/windows/agg/src/ctrl/agg_rbox_ctrl.cpp delete mode 100644 desmume/src/windows/agg/src/ctrl/agg_scale_ctrl.cpp delete mode 100644 desmume/src/windows/agg/src/ctrl/agg_slider_ctrl.cpp delete mode 100644 desmume/src/windows/agg/src/ctrl/agg_spline_ctrl.cpp delete mode 100644 desmume/src/windows/agg/src/install delete mode 100644 desmume/src/windows/agg/src/news delete mode 100644 desmume/src/windows/agg/src/platform/win32/agg_platform_support.cpp delete mode 100644 desmume/src/windows/agg/src/platform/win32/agg_win32_bmp.cpp delete mode 100644 desmume/src/windows/agg/src/readme delete mode 100644 desmume/src/windows/aviout.h delete mode 100644 desmume/src/windows/defaultconfig/SubWCRev.bat delete mode 100644 desmume/src/windows/defaultconfig/SubWCRev.exe delete mode 100644 desmume/src/windows/defaultconfig/svnrev.h delete mode 100644 desmume/src/windows/defaultconfig/svnrev_template.h delete mode 100644 desmume/src/windows/filter/2xsai.cpp delete mode 100644 desmume/src/windows/filter/bilinear.cpp delete mode 100644 desmume/src/windows/filter/filter.h delete mode 100644 desmume/src/windows/filter/hq2x.cpp delete mode 100644 desmume/src/windows/filter/scanline.cpp delete mode 100644 desmume/src/windows/glib-2.20.1/build/glib/gthread/gthread-impl.c delete mode 100644 desmume/src/windows/glib-2.20.1/build/glib/gthread/gthread-none.c delete mode 100644 desmume/src/windows/glib-2.20.1/build/glib/gthread/gthread-posix.c delete mode 100644 desmume/src/windows/glib-2.20.1/build/glib/gthread/gthread-win32.c delete mode 100644 desmume/src/windows/glib-2.20.1/lib/glib-2.20.1-x86.lib delete mode 100644 desmume/src/windows/mapView.cpp delete mode 100644 desmume/src/windows/pathsettings.cpp delete mode 100644 desmume/src/windows/pathsettings.h delete mode 100755 desmume/src/windows/snddx.cpp delete mode 100644 desmume/src/windows/userconfig/readme.txt delete mode 100644 desmume/src/windows/video.h rename desmume/dsm.txt => dsm.txt (80%) rename desmume/faq.htm => faq.htm (100%) rename {desmume/po => po}/ChangeLog (100%) rename {desmume/po => po}/LINGUAS (66%) rename {desmume/po => po}/PACKAGE (82%) rename {desmume/po => po}/POTFILES.in (100%) rename {desmume/po => po}/desmume.pot (100%) rename {desmume/po => po}/fr.po (100%) rename {desmume/po => po}/pt_BR.po (100%) rename {desmume/po => po}/sv.po (100%) rename {desmume/po => po}/windows/en_US.po (100%) rename {desmume/po => po}/windows/fr_FR.po (100%) rename {desmume/src => src}/ARM9.h (100%) rename {desmume/src => src}/Disassembler.cpp (100%) rename {desmume/src => src}/Disassembler.h (97%) rename {desmume/src => src}/FIFO.cpp (75%) rename {desmume/src => src}/FIFO.h (87%) rename {desmume/src => src}/GPU.cpp (84%) rename {desmume/src => src}/GPU.h (92%) create mode 100644 src/GPU_osd.cpp rename {desmume/src => src}/GPU_osd.h (69%) rename {desmume/src => src}/MMU.cpp (80%) rename {desmume/src => src}/MMU.h (80%) rename {desmume/src => src}/Makefile.am (76%) rename {desmume/src => src}/NDSSystem.cpp (57%) rename {desmume/src => src}/NDSSystem.h (74%) rename {desmume/src => src}/OGLRender.cpp (97%) rename {desmume/src => src}/OGLRender.h (96%) rename {desmume/src => src}/PACKED.h (94%) create mode 100644 src/PACKED_END.h rename {desmume/src => src}/ROMReader.cpp (95%) rename {desmume/src => src}/ROMReader.h (96%) rename {desmume/src => src}/SPU.cpp (89%) rename {desmume/src => src}/SPU.h (87%) rename {desmume/src => src}/addons.cpp (84%) rename {desmume/src => src}/addons.h (85%) rename {desmume/src => src}/addons/compactFlash.cpp (93%) rename {desmume/src => src}/addons/gbagame.cpp (96%) rename {desmume/src => src}/addons/none.cpp (96%) rename {desmume/src => src}/addons/rumblepak.cpp (95%) rename {desmume/src => src}/arm_instructions.cpp (100%) rename {desmume/src => src}/arm_instructions.h (97%) rename {desmume/src => src}/armcpu.cpp (97%) rename {desmume/src => src}/armcpu.h (95%) rename {desmume/src => src}/bios.cpp (96%) rename {desmume/src => src}/bios.h (96%) rename {desmume/src => src}/bits.h (96%) rename {desmume/src => src}/build.bat (100%) create mode 100644 src/cflash.cpp create mode 100644 src/cflash.h rename {desmume/src => src}/cheatSystem.cpp (100%) rename {desmume/src => src}/cheatSystem.h (97%) rename {desmume/src => src}/cli/Makefile.am (65%) rename {desmume/src => src}/cli/doc/Makefile.am (100%) rename {desmume/src => src}/cli/doc/desmume-cli.1 (100%) rename {desmume/src => src}/cli/main.cpp (88%) rename {desmume/src => src}/cocoa/DeSmuME.cbp (100%) rename {desmume/src => src}/cocoa/DeSmuME.icns (100%) mode change 100755 => 100644 rename {desmume/src => src}/cocoa/DeSmuME.xcodeproj/project.pbxproj (97%) rename {desmume/src => src}/cocoa/Info.plist (100%) rename {desmume/src => src}/cocoa/InfoPlist.strings (100%) rename {desmume/src => src}/cocoa/Makefile.am (100%) rename {desmume/src => src}/cocoa/PkgInfo (100%) rename {desmume/src => src}/cocoa/Rakefile (100%) rename {desmume/src => src}/cocoa/about.m (100%) rename {desmume/src => src}/cocoa/build_dmg.sh (100%) rename {desmume/src => src}/cocoa/cocoa_util.m (100%) rename {desmume/src => src}/cocoa/dialogs/rom_info.h (96%) rename {desmume/src => src}/cocoa/dialogs/rom_info.m (100%) rename {desmume/src => src}/cocoa/dialogs/speed_limit_selection_window.h (96%) rename {desmume/src => src}/cocoa/dialogs/speed_limit_selection_window.mm (100%) rename {desmume/src => src}/cocoa/globals.h (96%) rename {desmume/src => src}/cocoa/input.h (96%) rename {desmume/src => src}/cocoa/input.mm (100%) rename {desmume/src => src}/cocoa/main.mm (96%) rename {desmume/src => src}/cocoa/main_window.h (96%) rename {desmume/src => src}/cocoa/main_window.mm (97%) rename {desmume/src => src}/cocoa/makeapp.sh (100%) mode change 100755 => 100644 rename {desmume/src => src}/cocoa/nds_control.h (96%) rename {desmume/src => src}/cocoa/nds_control.mm (99%) rename {desmume/src => src}/cocoa/preferences.h (97%) rename {desmume/src => src}/cocoa/preferences.mm (100%) rename {desmume/src => src}/cocoa/screen_state.h (96%) rename {desmume/src => src}/cocoa/screen_state.m (100%) rename {desmume/src => src}/cocoa/screenshot.h (97%) rename {desmume/src => src}/cocoa/screenshot.mm (100%) rename {desmume/src => src}/cocoa/sndOSX.h (96%) rename {desmume/src => src}/cocoa/sndOSX.mm (100%) rename {desmume/src => src}/cocoa/translations/English.lproj/Localizable.strings (100%) rename {desmume/src => src}/cocoa/translations/English.lproj/MainMenu.nib/classes.nib (100%) mode change 100755 => 100644 rename {desmume/src => src}/cocoa/translations/English.lproj/MainMenu.nib/info.nib (100%) mode change 100755 => 100644 rename {desmume/src => src}/cocoa/translations/English.lproj/MainMenu.nib/keyedobjects.nib (100%) mode change 100755 => 100644 rename {desmume/src => src}/cocoa/translations/French.lproj/Localizable.strings (100%) rename {desmume/src => src}/cocoa/translations/French.lproj/MainMenu.nib/classes.nib (100%) rename {desmume/src => src}/cocoa/translations/French.lproj/MainMenu.nib/info.nib (100%) rename {desmume/src => src}/cocoa/translations/French.lproj/MainMenu.nib/keyedobjects.nib (100%) rename {desmume/src => src}/cocoa/translations/Italian.lproj/Localizable.strings (100%) rename {desmume/src/cocoa/translations/Chinese.lproj => src/cocoa/translations/Italian.lproj}/MainMenu.nib/classes.nib (100%) rename {desmume/src => src}/cocoa/translations/Italian.lproj/MainMenu.nib/info.nib (100%) rename {desmume/src => src}/cocoa/translations/Italian.lproj/MainMenu.nib/keyedobjects.nib (100%) rename {desmume/src => src}/cocoa/translations/Japanese.lproj/Localizable.strings (100%) rename {desmume/src => src}/cocoa/translations/Japanese.lproj/MainMenu.nib/classes.nib (100%) mode change 100755 => 100644 rename {desmume/src => src}/cocoa/translations/Japanese.lproj/MainMenu.nib/info.nib (100%) mode change 100755 => 100644 rename {desmume/src => src}/cocoa/translations/Japanese.lproj/MainMenu.nib/keyedobjects.nib (100%) mode change 100755 => 100644 rename {desmume/src => src}/cocoa/video_output_view.h (96%) rename {desmume/src => src}/cocoa/video_output_view.mm (100%) rename {desmume/src => src}/commandline.cpp (62%) rename {desmume/src => src}/commandline.h (86%) rename {desmume/src => src}/common.cpp (79%) rename {desmume/src => src}/common.h (93%) rename {desmume/src => src}/cp15.cpp (96%) rename {desmume/src => src}/cp15.h (97%) rename {desmume/src => src}/ctrlssdl.cpp (71%) rename {desmume/src => src}/ctrlssdl.h (91%) rename {desmume/src => src}/debug.cpp (100%) rename {desmume/src => src}/debug.h (100%) rename {desmume/src => src}/desmume.mk (100%) rename {desmume/src => src}/driver.h (100%) rename {desmume/src => src}/dscard.h (96%) create mode 100644 src/fat.h rename {desmume/src => src}/fs-linux.cpp (95%) rename {desmume/src => src}/fs-windows.cpp (96%) rename {desmume/src => src}/fs.h (96%) rename {desmume/src => src}/gdbstub.h (96%) rename {desmume/src => src}/gdbstub/Makefile.am (100%) rename {desmume/src => src}/gdbstub/gdbstub.cpp (96%) rename {desmume/src => src}/gdbstub/gdbstub_internal.h (96%) rename {desmume/src => src}/gfx3d.cpp (75%) rename {desmume/src => src}/gfx3d.h (99%) rename {desmume/src => src}/gtk-glade/Makefile.am (91%) rename {desmume/src => src}/gtk-glade/callbacks.cpp (96%) mode change 100755 => 100644 rename {desmume/src => src}/gtk-glade/callbacks.h (98%) mode change 100755 => 100644 rename {desmume/src => src}/gtk-glade/callbacks_IO.cpp (96%) mode change 100755 => 100644 rename {desmume/src => src}/gtk-glade/callbacks_IO.h (98%) mode change 100755 => 100644 rename {desmume/src => src}/gtk-glade/dTools/callbacks_1_ioregs.cpp (96%) mode change 100755 => 100644 rename {desmume/src => src}/gtk-glade/dTools/callbacks_2_memview.cpp (96%) mode change 100755 => 100644 rename {desmume/src => src}/gtk-glade/dTools/callbacks_3_palview.cpp (96%) mode change 100755 => 100644 rename {desmume/src => src}/gtk-glade/dTools/callbacks_4_tileview.cpp (66%) mode change 100755 => 100644 rename {desmume/src => src}/gtk-glade/dTools/callbacks_dtools.h (98%) mode change 100755 => 100644 rename {desmume/src => src}/gtk-glade/dTools/dTools_display.h (96%) mode change 100755 => 100644 rename {desmume/src => src}/gtk-glade/desmume-glade.desktop (100%) rename {desmume/src => src}/gtk-glade/desmume.cpp (89%) mode change 100755 => 100644 rename {desmume/src => src}/gtk-glade/desmume.h (97%) mode change 100755 => 100644 rename {desmume/src => src}/gtk-glade/doc/Makefile.am (100%) rename {desmume/src => src}/gtk-glade/doc/desmume-glade.1 (100%) rename {desmume/src => src}/gtk-glade/gdk_3Demu.cpp (97%) rename {desmume/src => src}/gtk-glade/gdk_3Demu.h (97%) rename {desmume/src => src}/gtk-glade/gdk_gl.cpp (96%) mode change 100755 => 100644 rename {desmume/src => src}/gtk-glade/gdk_gl.h (96%) mode change 100755 => 100644 rename {desmume/src => src}/gtk-glade/glade-xml.cpp (97%) mode change 100755 => 100644 rename {desmume/src => src}/gtk-glade/glade/DeSmuME.xpm (100%) mode change 100755 => 100644 rename {desmume/src => src}/gtk-glade/glade/DeSmuMe.glade (100%) mode change 100755 => 100644 rename {desmume/src => src}/gtk-glade/glade/DeSmuMe_Dtools.glade (100%) mode change 100755 => 100644 rename {desmume/src => src}/gtk-glade/globals.h (95%) mode change 100755 => 100644 rename {desmume/src => src}/gtk-glade/keyval_names.cpp (97%) mode change 100755 => 100644 rename {desmume/src => src}/gtk-glade/keyval_names.h (97%) mode change 100755 => 100644 rename {desmume/src => src}/gtk-glade/main.cpp (96%) mode change 100755 => 100644 rename {desmume/src => src}/gtk/DeSmuME.xpm (100%) rename {desmume/src => src}/gtk/Makefile.am (50%) rename {desmume/src => src}/gtk/dTool.h (75%) rename {desmume/src => src}/gtk/dToolsList.cpp (94%) rename {desmume/src => src}/gtk/desmume.cpp (90%) rename {desmume/src => src}/gtk/desmume.desktop (81%) rename {desmume/src => src}/gtk/desmume.h (97%) rename {desmume/src => src}/gtk/desmume_config.cpp (96%) rename {desmume/src => src}/gtk/desmume_config.h (97%) rename {desmume/src => src}/gtk/doc/Makefile.am (100%) rename {desmume/src => src}/gtk/doc/desmume.1 (100%) rename {desmume/src => src}/gtk/main.cpp (87%) rename {desmume/src => src}/gtk/osmesa_3Demu.cpp (96%) rename {desmume/src => src}/gtk/osmesa_3Demu.h (97%) rename {desmume/src => src}/gtk/tools/ioregsView.cpp (96%) rename {desmume/src => src}/gtk/tools/ioregsView.h (97%) rename {desmume/src => src}/instruction_tabdef.inc (100%) rename {desmume/src => src}/lua-engine.cpp (93%) rename {desmume/src => src}/lua-engine.h (96%) rename {desmume/src => src}/matrix.cpp (91%) create mode 100644 src/matrix.h create mode 100644 src/matrix_sse2-x64.asm create mode 100644 src/matrix_sse2-x86.asm create mode 100644 src/mc.cpp rename {desmume/src => src}/mc.h (57%) rename {desmume/src => src}/mem.h (96%) rename {desmume/src => src}/memorystream.h (95%) create mode 100644 src/mic.cpp create mode 100644 src/mic.h rename {desmume/src => src}/movie.cpp (92%) rename {desmume/src => src}/movie.h (92%) rename {desmume/src => src}/rasterize.cpp (94%) rename {desmume/src => src}/rasterize.h (96%) rename {desmume/src => src}/readwrite.cpp (63%) rename {desmume/src => src}/readwrite.h (78%) rename {desmume/src => src}/registers.h (97%) rename {desmume/src => src}/render3D.cpp (96%) rename {desmume/src => src}/render3D.h (96%) rename {desmume/src => src}/rtc.cpp (95%) rename {desmume/src => src}/rtc.h (96%) rename {desmume/src => src}/saves.cpp (86%) rename {desmume/src => src}/saves.h (96%) rename {desmume/src => src}/shaders.h (96%) rename {desmume/src => src}/sndsdl.cpp (96%) rename {desmume/src => src}/sndsdl.h (97%) create mode 100644 src/softrender.cpp create mode 100644 src/softrender.h create mode 100644 src/softrender_config.h create mode 100644 src/softrender_desmumefont.h create mode 100644 src/softrender_v3sysfont.h rename {desmume/src => src}/texcache.cpp (96%) rename {desmume/src => src}/texcache.h (90%) rename {desmume/src => src}/thumb_instructions.cpp (100%) rename {desmume/src => src}/thumb_instructions.h (97%) rename {desmume/src => src}/thumb_tabdef.inc (100%) rename {desmume/src => src}/types.h (72%) rename {desmume/src => src}/utils/ConvertUTF.c (100%) rename {desmume/src => src}/utils/ConvertUTF.h (97%) rename {desmume/src => src}/utils/decrypt/crc.cpp (98%) rename {desmume/src => src}/utils/decrypt/crc.h (96%) rename {desmume/src => src}/utils/decrypt/decrypt.cpp (100%) rename {desmume/src => src}/utils/decrypt/decrypt.h (100%) rename {desmume/src => src}/utils/decrypt/header.cpp (100%) rename {desmume/src => src}/utils/decrypt/header.h (100%) rename {desmume/src => src}/utils/guid.cpp (56%) rename {desmume/src => src}/utils/guid.h (94%) rename {desmume/src => src}/utils/md5.cpp (100%) rename {desmume/src => src}/utils/md5.h (95%) rename {desmume/src => src}/utils/valuearray.h (95%) rename {desmume/src => src}/utils/xstring.cpp (94%) rename {desmume/src => src}/utils/xstring.h (90%) rename {desmume/src => src}/wifi.cpp (95%) rename {desmume/src => src}/wifi.h (100%) rename {desmume/src => src}/windows/7z/7zip.lib (100%) rename {desmume/src => src}/windows/7z/7zip.vcproj (100%) rename {desmume/src => src}/windows/7z/C/7zCrc.c (100%) rename {desmume/src => src}/windows/7z/C/7zCrc.h (100%) rename {desmume/src => src}/windows/7z/C/Aes.c (100%) rename {desmume/src => src}/windows/7z/C/Aes.h (100%) rename {desmume/src => src}/windows/7z/C/Alloc.c (100%) rename {desmume/src => src}/windows/7z/C/Alloc.h (100%) rename {desmume/src => src}/windows/7z/C/Bra.c (100%) rename {desmume/src => src}/windows/7z/C/Bra.h (100%) rename {desmume/src => src}/windows/7z/C/Bra86.c (100%) rename {desmume/src => src}/windows/7z/C/BraIA64.c (100%) rename {desmume/src => src}/windows/7z/C/BwtSort.c (100%) rename {desmume/src => src}/windows/7z/C/BwtSort.h (100%) rename {desmume/src => src}/windows/7z/C/CpuArch.h (100%) rename {desmume/src => src}/windows/7z/C/HuffEnc.c (100%) rename {desmume/src => src}/windows/7z/C/HuffEnc.h (100%) rename {desmume/src => src}/windows/7z/C/LzFind.c (100%) rename {desmume/src => src}/windows/7z/C/LzFind.h (100%) rename {desmume/src => src}/windows/7z/C/LzFindMt.c (100%) rename {desmume/src => src}/windows/7z/C/LzFindMt.h (100%) rename {desmume/src => src}/windows/7z/C/LzHash.h (100%) rename {desmume/src => src}/windows/7z/C/LzmaDec.c (100%) rename {desmume/src => src}/windows/7z/C/LzmaDec.h (100%) rename {desmume/src => src}/windows/7z/C/LzmaEnc.c (100%) rename {desmume/src => src}/windows/7z/C/LzmaEnc.h (100%) rename {desmume/src => src}/windows/7z/C/RotateDefs.h (100%) rename {desmume/src => src}/windows/7z/C/Sha256.c (100%) rename {desmume/src => src}/windows/7z/C/Sha256.h (100%) rename {desmume/src => src}/windows/7z/C/Sort.c (100%) rename {desmume/src => src}/windows/7z/C/Sort.h (100%) rename {desmume/src => src}/windows/7z/C/Threads.c (100%) rename {desmume/src => src}/windows/7z/C/Threads.h (100%) rename {desmume/src => src}/windows/7z/C/Types.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/7z/7zCompressionMode.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/7z/7zCompressionMode.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/7z/7zDecode.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/7z/7zDecode.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/7z/7zExtract.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/7z/7zFolderInStream.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/7z/7zFolderInStream.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/7z/7zFolderOutStream.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/7z/7zFolderOutStream.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/7z/7zHandler.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/7z/7zHandler.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/7z/7zHeader.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/7z/7zHeader.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/7z/7zIn.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/7z/7zIn.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/7z/7zItem.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/7z/7zProperties.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/7z/7zProperties.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/7z/7zRegister.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/7z/7zSpecStream.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/7z/7zSpecStream.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/7z/StdAfx.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/ArchiveExports.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/BZip2/BZip2Handler.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/BZip2/BZip2Handler.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/BZip2/BZip2Item.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/BZip2/StdAfx.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/BZip2/bz2Register.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Common/CoderMixer2.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Common/CoderMixer2.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Common/CoderMixer2MT.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Common/CoderMixer2MT.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Common/DummyOutStream.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Common/DummyOutStream.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Common/FindSignature.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Common/FindSignature.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Common/InStreamWithCRC.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Common/InStreamWithCRC.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Common/ItemNameUtils.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Common/ItemNameUtils.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Common/MultiStream.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Common/MultiStream.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Common/OutStreamWithCRC.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Common/OutStreamWithCRC.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Common/ParseProperties.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Common/ParseProperties.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Common/StdAfx.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/DllExports2.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/GZip/GZipHandler.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/GZip/GZipHandler.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/GZip/GZipHeader.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/GZip/GZipHeader.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/GZip/GZipIn.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/GZip/GZipIn.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/GZip/GZipItem.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/GZip/GZipRegister.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/GZip/GZipUpdate.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/GZip/StdAfx.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/IArchive.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Lzh/LzhCRC.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Lzh/LzhCRC.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Lzh/LzhHandler.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Lzh/LzhHandler.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Lzh/LzhHeader.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Lzh/LzhIn.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Lzh/LzhIn.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Lzh/LzhItem.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Lzh/LzhOutStreamWithCRC.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Lzh/LzhOutStreamWithCRC.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Lzh/LzhRegister.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Lzh/StdAfx.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Lzma/LzmaArcRegister.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Lzma/LzmaFiltersDecode.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Lzma/LzmaFiltersDecode.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Lzma/LzmaHandler.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Lzma/LzmaHandler.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Lzma/LzmaIn.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Lzma/LzmaIn.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Lzma/LzmaItem.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Lzma/StdAfx.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Rar/RarHandler.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Rar/RarHandler.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Rar/RarHeader.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Rar/RarHeader.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Rar/RarIn.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Rar/RarIn.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Rar/RarItem.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Rar/RarItem.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Rar/RarRegister.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Rar/RarVolumeInStream.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Rar/RarVolumeInStream.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Rar/StdAfx.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Split/SplitHandler.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Split/SplitHandler.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Split/SplitRegister.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Split/StdAfx.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/StdAfx.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Tar/StdAfx.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Tar/TarHandler.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Tar/TarHandler.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Tar/TarHeader.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Tar/TarHeader.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Tar/TarIn.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Tar/TarIn.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Tar/TarItem.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Tar/TarRegister.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Zip/StdAfx.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Zip/ZipCompressionMode.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Zip/ZipHandler.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Zip/ZipHandler.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Zip/ZipHeader.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Zip/ZipHeader.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Zip/ZipIn.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Zip/ZipIn.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Zip/ZipItem.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Zip/ZipItem.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Zip/ZipItemEx.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Archive/Zip/ZipRegister.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Common/CreateCoder.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Common/CreateCoder.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Common/DeclareArcs.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Common/DeclareCodecs.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Common/FilterCoder.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Common/FilterCoder.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Common/InBuffer.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Common/InBuffer.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Common/InOutTempBuffer.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Common/InOutTempBuffer.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Common/LimitedStreams.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Common/LimitedStreams.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Common/LockedStream.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Common/LockedStream.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Common/MemBlocks.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Common/MemBlocks.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Common/MethodId.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Common/MethodId.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Common/MethodProps.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Common/MethodProps.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Common/OffsetStream.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Common/OffsetStream.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Common/OutBuffer.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Common/OutBuffer.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Common/OutMemStream.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Common/OutMemStream.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Common/ProgressMt.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Common/ProgressMt.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Common/ProgressUtils.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Common/ProgressUtils.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Common/RegisterArc.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Common/RegisterCodec.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Common/StdAfx.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Common/StreamBinder.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Common/StreamBinder.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Common/StreamObjects.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Common/StreamObjects.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Common/StreamUtils.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Common/StreamUtils.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Common/VirtThread.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Common/VirtThread.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/BZip2Const.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/BZip2Crc.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/BZip2Crc.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/BZip2Decoder.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/BZip2Decoder.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/BZip2Register.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/Bcj2Coder.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/Bcj2Coder.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/Bcj2Register.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/BcjCoder.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/BcjCoder.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/BcjRegister.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/BitlDecoder.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/BitlDecoder.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/BitmDecoder.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/BranchCoder.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/BranchCoder.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/BranchMisc.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/BranchMisc.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/BranchRegister.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/ByteSwap.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/ByteSwap.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/ByteSwapRegister.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/Codec.def (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/CodecExports.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/CopyCoder.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/CopyCoder.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/CopyRegister.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/Deflate64Register.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/DeflateConst.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/DeflateDecoder.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/DeflateDecoder.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/DeflateNsisRegister.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/DeflateRegister.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/HuffmanDecoder.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/ImplodeDecoder.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/ImplodeDecoder.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/ImplodeHuffmanDecoder.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/ImplodeHuffmanDecoder.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/LzOutWindow.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/LzOutWindow.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/LzhDecoder.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/LzhDecoder.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/LzmaDecoder.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/LzmaDecoder.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/LzmaRegister.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/Mtf8.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/PpmdContext.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/PpmdDecode.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/PpmdDecoder.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/PpmdDecoder.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/PpmdRegister.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/PpmdSubAlloc.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/PpmdType.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/RangeCoder.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/RangeCoderBit.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/Rar1Decoder.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/Rar1Decoder.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/Rar2Decoder.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/Rar2Decoder.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/Rar3Decoder.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/Rar3Decoder.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/Rar3Vm.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/Rar3Vm.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/RarCodecsRegister.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/ShrinkDecoder.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/ShrinkDecoder.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/StdAfx.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/ZlibDecoder.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Compress/ZlibDecoder.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Crypto/7zAes.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Crypto/7zAes.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Crypto/7zAesRegister.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Crypto/HmacSha1.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Crypto/HmacSha1.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Crypto/MyAes.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Crypto/MyAes.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Crypto/Pbkdf2HmacSha1.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Crypto/Pbkdf2HmacSha1.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Crypto/RandGen.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Crypto/RandGen.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Crypto/Rar20Crypto.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Crypto/Rar20Crypto.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Crypto/RarAes.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Crypto/RarAes.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Crypto/Sha1.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Crypto/Sha1.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Crypto/StdAfx.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Crypto/WzAes.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Crypto/WzAes.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Crypto/ZipCrypto.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Crypto/ZipCrypto.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Crypto/ZipStrong.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/Crypto/ZipStrong.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/ICoder.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/IDecl.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/IPassword.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/IProgress.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/IStream.h (100%) rename {desmume/src => src}/windows/7z/CPP/7zip/PropID.h (100%) rename {desmume/src => src}/windows/7z/CPP/Common/Buffer.h (100%) rename {desmume/src => src}/windows/7z/CPP/Common/CRC.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/Common/ComTry.h (100%) rename {desmume/src => src}/windows/7z/CPP/Common/Defs.h (100%) rename {desmume/src => src}/windows/7z/CPP/Common/DynamicBuffer.h (100%) rename {desmume/src => src}/windows/7z/CPP/Common/InitializeStaticLib.h (100%) rename {desmume/src => src}/windows/7z/CPP/Common/IntToString.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/Common/IntToString.h (100%) rename {desmume/src => src}/windows/7z/CPP/Common/MyCom.h (100%) rename {desmume/src => src}/windows/7z/CPP/Common/MyException.h (100%) rename {desmume/src => src}/windows/7z/CPP/Common/MyInitGuid.h (100%) rename {desmume/src => src}/windows/7z/CPP/Common/MyMap.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/Common/MyMap.h (100%) rename {desmume/src => src}/windows/7z/CPP/Common/MyString.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/Common/MyString.h (100%) rename {desmume/src => src}/windows/7z/CPP/Common/MyUnknown.h (100%) rename {desmume/src => src}/windows/7z/CPP/Common/MyVector.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/Common/MyVector.h (100%) rename {desmume/src => src}/windows/7z/CPP/Common/MyWindows.h (100%) rename {desmume/src => src}/windows/7z/CPP/Common/MyXml.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/Common/MyXml.h (100%) rename {desmume/src => src}/windows/7z/CPP/Common/NewHandler.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/Common/NewHandler.h (100%) rename {desmume/src => src}/windows/7z/CPP/Common/StringConvert.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/Common/StringConvert.h (100%) rename {desmume/src => src}/windows/7z/CPP/Common/StringToInt.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/Common/StringToInt.h (100%) rename {desmume/src => src}/windows/7z/CPP/Common/Types.h (100%) rename {desmume/src => src}/windows/7z/CPP/Common/UTFConvert.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/Common/UTFConvert.h (100%) rename {desmume/src => src}/windows/7z/CPP/Common/Wildcard.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/Common/Wildcard.h (100%) rename {desmume/src => src}/windows/7z/CPP/Windows/Defs.h (100%) rename {desmume/src => src}/windows/7z/CPP/Windows/FileDir.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/Windows/FileDir.h (100%) rename {desmume/src => src}/windows/7z/CPP/Windows/FileFind.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/Windows/FileFind.h (100%) rename {desmume/src => src}/windows/7z/CPP/Windows/FileIO.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/Windows/FileIO.h (100%) rename {desmume/src => src}/windows/7z/CPP/Windows/FileName.h (100%) rename {desmume/src => src}/windows/7z/CPP/Windows/Handle.h (100%) rename {desmume/src => src}/windows/7z/CPP/Windows/PropVariant.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/Windows/PropVariant.h (100%) rename {desmume/src => src}/windows/7z/CPP/Windows/StdAfx.h (100%) rename {desmume/src => src}/windows/7z/CPP/Windows/Synchronization.h (100%) rename {desmume/src => src}/windows/7z/CPP/Windows/Thread.h (100%) rename {desmume/src => src}/windows/7z/CPP/Windows/Time.cpp (100%) rename {desmume/src => src}/windows/7z/CPP/Windows/Time.h (100%) rename {desmume/src => src}/windows/7z/DOC/License.txt (100%) rename {desmume/src => src}/windows/7z/DOC/gpl.txt (100%) rename {desmume/src => src}/windows/7z/DOC/readme.txt (100%) rename {desmume/src => src}/windows/7z/DOC/unRarLicense.txt (100%) rename {desmume/src => src}/windows/7zip.cpp (95%) rename {desmume/src => src}/windows/7zip.h (93%) rename {desmume/src => src}/windows/7zipstreams.h (100%) rename {desmume/src => src}/windows/AboutBox.cpp (71%) rename {desmume/src => src}/windows/AboutBox.h (96%) rename {desmume/src => src}/windows/CWindow.cpp (93%) rename {desmume/src => src}/windows/CWindow.h (95%) rename {desmume/src => src}/windows/DeSmuME.ico (100%) rename {desmume/src => src}/windows/DeSmuME_2005.sln (93%) rename {desmume/src => src}/windows/DeSmuME_2005.vcproj (82%) rename {desmume/src => src}/windows/DeSmuME_2008.sln (100%) rename {desmume/src => src}/windows/DeSmuME_2008.vcproj (70%) rename {desmume/src => src}/windows/DeSmuME_Intel.icproj (96%) rename {desmume/src => src}/windows/DeSmuME_Intel.sln (100%) rename {desmume/src => src}/windows/DeSmuME_Intel.vcproj (95%) rename {desmume/src => src}/windows/DeSmuME_x64.manifest (100%) rename {desmume/src => src}/windows/DeSmuME_x86.manifest (100%) rename {desmume/src => src}/windows/FirmConfig.cpp (97%) rename {desmume/src => src}/windows/FirmConfig.h (97%) rename {desmume/src => src}/windows/GL/glext.h (98%) rename {desmume/src => src}/windows/IORegView.cpp (100%) rename {desmume/src => src}/windows/IORegView.h (97%) rename {desmume/src => src}/windows/Makefile.am (89%) rename {desmume/src => src}/windows/Makefile.win (100%) rename {desmume/src => src}/windows/OpenArchive.cpp (100%) rename {desmume/src => src}/windows/OpenArchive.h (100%) rename {desmume/src => src}/windows/afxres.h (100%) rename {desmume/src => src}/windows/aviout.cpp (90%) create mode 100644 src/windows/aviout.h rename {desmume/src => src}/windows/bitmap1.bmp (100%) rename {desmume/src => src}/windows/cheatsWin.cpp (96%) rename {desmume/src => src}/windows/cheatsWin.h (94%) rename {desmume/src => src}/windows/colorctrl.cpp (96%) rename {desmume/src => src}/windows/colorctrl.h (94%) rename {desmume/src => src}/windows/config.h (92%) rename {desmume/src => src}/windows/console.cpp (99%) rename {desmume/src => src}/windows/console.h (95%) rename {desmume/src => src}/windows/defaultconfig/userconfig.h (65%) rename {desmume/src => src}/windows/directx/DxErr8.lib (100%) rename {desmume/src => src}/windows/directx/ddraw.h (97%) rename {desmume/src => src}/windows/directx/ddraw.lib (100%) rename {desmume/src => src}/windows/directx/dinput.h (98%) rename {desmume/src => src}/windows/directx/dinput8.lib (100%) rename {desmume/src => src}/windows/directx/dsound.h (97%) rename {desmume/src => src}/windows/directx/dsound.lib (100%) rename {desmume/src => src}/windows/directx/dxerr8.h (96%) rename {desmume/src => src}/windows/directx/dxguid.lib (100%) rename {desmume/src => src}/windows/disView.cpp (100%) rename {desmume/src => src}/windows/disView.h (97%) rename {desmume/src => src}/windows/gbaslot_config.cpp (68%) rename {desmume/src => src}/windows/gbaslot_config.h (93%) rename {desmume/src => src}/windows/ginfo.cpp (96%) rename {desmume/src => src}/windows/ginfo.h (97%) rename {desmume/src => src}/windows/glib-2.20.1/build/dependencies/proxy-libintl-20080918/include/libintl.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/dirent/README (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/dirent/dirent.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/dirent/dirent.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/dirent/wdirent.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/config.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/galias.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/galiasdef.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/galloca.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/garray.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/garray.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gasyncqueue.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gasyncqueue.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gatomic.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gatomic.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gbacktrace.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gbacktrace.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gbase64.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gbase64.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gbookmarkfile.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gbookmarkfile.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gbsearcharray.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gcache.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gcache.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gchecksum.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gchecksum.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gcompletion.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gcompletion.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gconvert.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gconvert.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gdataset.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gdataset.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gdatasetprivate.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gdate.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gdate.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gdebug.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gdir.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gdir.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gerror.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gerror.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gfileutils.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gfileutils.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/ghash.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/ghash.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/ghook.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/ghook.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gi18n-lib.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gi18n.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/giochannel.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/giochannel.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/giounix.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/giowin32.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gkeyfile.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gkeyfile.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/glib-object.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/glib.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/glibintl.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/glist.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/glist.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gmacros.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gmain.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gmain.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gmappedfile.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gmappedfile.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gmarkup.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gmarkup.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gmem.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gmem.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gmessages.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gmessages.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gmirroringtable.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gnode.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gnode.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gnulib/README (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gnulib/asnprintf.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gnulib/g-gnulib.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gnulib/printf-args.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gnulib/printf-args.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gnulib/printf-parse.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gnulib/printf-parse.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gnulib/printf.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gnulib/printf.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gnulib/vasnprintf.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gnulib/vasnprintf.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/goption.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/goption.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gpattern.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gpattern.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gpoll.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gpoll.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gprimes.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gprimes.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gprintf.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gprintf.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gprintfint.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gqsort.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gqsort.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gquark.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gqueue.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gqueue.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/grand.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/grand.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gregex.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gregex.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/grel.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/grel.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gscanner.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gscanner.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gscripttable.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gsequence.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gsequence.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gshell.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gshell.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gslice.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gslice.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gslist.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gslist.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gspawn-win32-helper-console.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gspawn-win32-helper.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gspawn-win32.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gspawn-win64-helper-console.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gspawn-win64-helper.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gspawn.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gspawn.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gstdio.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gstdio.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gstrfuncs.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gstrfuncs.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gstring.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gstring.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gtester.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gtestutils.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gtestutils.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gthread.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gthread.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gthreadpool.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gthreadpool.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gthreadprivate.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gtimer.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gtimer.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gtree.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gtree.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gtypes.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gunibreak.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gunibreak.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gunichartables.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gunicode.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gunicodeprivate.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gunicollate.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gunicomp.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gunidecomp.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gunidecomp.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/guniprop.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gurifuncs.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gurifuncs.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gutf8.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gutils.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gutils.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gwin32.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/gwin32.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/libcharset/README (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/libcharset/libcharset.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/libcharset/localcharset.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/libcharset/localcharset.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/libintl.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/msvc_recommended_pragmas.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/pcre/COPYING (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/pcre/pcre.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/pcre/pcre_chartables.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/pcre/pcre_compile.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/pcre/pcre_config.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/pcre/pcre_dfa_exec.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/pcre/pcre_exec.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/pcre/pcre_fullinfo.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/pcre/pcre_get.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/pcre/pcre_globals.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/pcre/pcre_info.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/pcre/pcre_internal.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/pcre/pcre_maketables.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/pcre/pcre_newline.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/pcre/pcre_ord2utf8.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/pcre/pcre_refcount.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/pcre/pcre_study.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/pcre/pcre_tables.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/pcre/pcre_try_flipped.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/pcre/pcre_ucp_searchfuncs.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/pcre/pcre_valid_utf8.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/pcre/pcre_version.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/pcre/pcre_xclass.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/pcre/ucp.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/pcre/ucpinternal.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glib/win_iconv.c (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/glibconfig.h (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/vs8/README (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/vs8/gio.vcproj (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/vs8/glib.sln (100%) rename {desmume/src => src}/windows/glib-2.20.1/build/vs8/glib.vcproj (88%) create mode 100644 src/windows/glib-2.20.1/lib/glib-2.20.1-x86.lib rename {desmume/src => src}/windows/glib-2.20.1/modified_for_desmume.txt (100%) rename {desmume/src => src}/windows/hotkey.cpp (94%) rename {desmume/src => src}/windows/hotkey.h (99%) rename {desmume/src => src}/windows/inputdx.cpp (94%) rename {desmume/src => src}/windows/inputdx.h (96%) rename {desmume/src => src}/windows/langs/build_utils/gettextlib.dll (100%) rename {desmume/src => src}/windows/langs/build_utils/gettextpo.dll (100%) rename {desmume/src => src}/windows/langs/build_utils/gettextsrc.dll (100%) rename {desmume/src => src}/windows/langs/build_utils/iconv.dll (100%) rename {desmume/src => src}/windows/langs/build_utils/intl.dll (100%) rename {desmume/src => src}/windows/langs/build_utils/libiconv-2.dll (100%) rename {desmume/src => src}/windows/langs/build_utils/msgfmt.exe (100%) rename {desmume/src => src}/windows/langs/fr_FR.mo (100%) rename {desmume/src => src}/windows/lightView.cpp (96%) rename {desmume/src => src}/windows/lightView.h (96%) rename {desmume/src => src}/windows/lua/lib/lua-5.1.4-x86.lib (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/COPYRIGHT (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/Makefile (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/lapi.c (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/lapi.h (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/lauxlib.c (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/lauxlib.h (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/lbaselib.c (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/lcode.c (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/lcode.h (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/ldblib.c (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/ldebug.c (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/ldebug.h (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/ldo.c (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/ldo.h (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/ldump.c (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/lfunc.c (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/lfunc.h (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/lgc.c (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/lgc.h (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/linit.c (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/liolib.c (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/llex.c (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/llex.h (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/llimits.h (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/lmathlib.c (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/lmem.c (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/lmem.h (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/loadlib.c (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/lobject.c (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/lobject.h (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/lopcodes.c (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/lopcodes.h (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/loslib.c (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/lparser.c (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/lparser.h (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/lstate.c (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/lstate.h (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/lstring.c (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/lstring.h (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/lstrlib.c (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/ltable.c (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/ltable.h (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/ltablib.c (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/ltm.c (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/ltm.h (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/lua.c (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/lua.h (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/luac.c (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/luaconf.h (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/lualib.h (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/lundump.c (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/lundump.h (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/lvm.c (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/lvm.h (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/lzio.c (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/lzio.h (100%) rename {desmume/src => src}/windows/lua/lua-5.1.4/src/print.c (100%) rename {desmume/src => src}/windows/lua/vs8/lua.sln (100%) rename {desmume/src => src}/windows/lua/vs8/lua.vcproj (100%) rename {desmume/src => src}/windows/luaconsole.cpp (96%) rename {desmume/src => src}/windows/main.cpp (82%) rename {desmume/src => src}/windows/main.h (94%) create mode 100644 src/windows/mapView.cpp rename {desmume/src => src}/windows/mapView.h (96%) rename {desmume/src => src}/windows/matrixView.cpp (97%) rename {desmume/src => src}/windows/matrixView.h (96%) rename {desmume/src => src}/windows/memView.cpp (95%) rename {desmume/src => src}/windows/memView.h (96%) rename {desmume/src => src}/windows/mic.cpp (91%) rename {desmume/src => src}/windows/oamView.cpp (97%) rename {desmume/src => src}/windows/oamView.h (97%) rename {desmume/src => src}/windows/ogl.cpp (69%) rename {desmume/src => src}/windows/palView.cpp (97%) rename {desmume/src => src}/windows/palView.h (96%) create mode 100644 src/windows/pathsettings.cpp create mode 100644 src/windows/pathsettings.h rename {desmume/src => src}/windows/ram_search.cpp (99%) rename {desmume/src => src}/windows/ram_search.h (97%) rename {desmume/src => src}/windows/ramwatch.cpp (99%) rename {desmume/src => src}/windows/ramwatch.h (96%) rename {desmume/src => src}/windows/replay.cpp (75%) rename {desmume/src => src}/windows/replay.h (95%) rename {desmume/src => src}/windows/resource.h (94%) rename {desmume/src => src}/windows/resources.rc (99%) create mode 100644 src/windows/snddx.cpp rename {desmume/src => src}/windows/snddx.h (97%) mode change 100755 => 100644 rename {desmume/src => src}/windows/soundView.cpp (83%) rename {desmume/src => src}/windows/soundView.h (100%) rename {desmume/src => src}/windows/throttle.cpp (94%) rename {desmume/src => src}/windows/throttle.h (94%) rename {desmume/src => src}/windows/tileView.cpp (97%) rename {desmume/src => src}/windows/tileView.h (97%) create mode 100644 src/windows/wavout.cpp create mode 100644 src/windows/wavout.h rename {desmume/src => src}/windows/windriver.h (57%) rename {desmume/src => src}/windows/winpcap/Devioctl.h (97%) rename {desmume/src => src}/windows/winpcap/Gnuc.h (94%) rename {desmume/src => src}/windows/winpcap/Ntddndis.h (97%) rename {desmume/src => src}/windows/winpcap/Ntddpack.h (97%) rename {desmume/src => src}/windows/winpcap/Packet.lib (100%) rename {desmume/src => src}/windows/winpcap/Packet32.h (98%) rename {desmume/src => src}/windows/winpcap/Win32-Extensions.h (97%) rename {desmume/src => src}/windows/winpcap/bittypes.h (96%) rename {desmume/src => src}/windows/winpcap/bucket_lookup.h (97%) rename {desmume/src => src}/windows/winpcap/count_packets.h (97%) rename {desmume/src => src}/windows/winpcap/ip6_misc.h (97%) rename {desmume/src => src}/windows/winpcap/memory_t.h (96%) rename {desmume/src => src}/windows/winpcap/normal_lookup.h (97%) rename {desmume/src => src}/windows/winpcap/pcap-bpf.h (96%) rename {desmume/src => src}/windows/winpcap/pcap-int.h (97%) rename {desmume/src => src}/windows/winpcap/pcap-stdinc.h (97%) rename {desmume/src => src}/windows/winpcap/pcap.h (97%) rename {desmume/src => src}/windows/winpcap/remote-ext.h (97%) rename {desmume/src => src}/windows/winpcap/tcp_session.h (96%) rename {desmume/src => src}/windows/winpcap/time_calls.h (96%) rename {desmume/src => src}/windows/winpcap/tme.h (97%) rename {desmume/src => src}/windows/winpcap/wpcap.lib (100%) rename {desmume/src => src}/windows/winres.h (100%) rename {desmume/src => src}/windows/zlib123/README (100%) rename {desmume/src => src}/windows/zlib123/zconf.h (96%) rename {desmume/src => src}/windows/zlib123/zlib-2005-x32.lib (100%) rename {desmume/src => src}/windows/zlib123/zlib-2005-x64.lib (100%) rename {desmume/src => src}/windows/zlib123/zlib-2008-x32.lib (100%) rename {desmume/src => src}/windows/zlib123/zlib-2008-x64.lib (100%) rename {desmume/src => src}/windows/zlib123/zlib.h (97%) rename {desmume/src => src}/windows/zlib123/zutil.h (96%) rename {desmume/src => src}/windows/zziplib/README (100%) rename {desmume/src => src}/windows/zziplib/zzip/_msvc.h (96%) rename {desmume/src => src}/windows/zziplib/zzip/conf.h (92%) rename {desmume/src => src}/windows/zziplib/zzip/types.h (97%) rename {desmume/src => src}/windows/zziplib/zzip/zzip.h (96%) rename {desmume/src => src}/windows/zziplib/zziplib-2005-x32.lib (100%) rename {desmume/src => src}/windows/zziplib/zziplib-2005-x64.lib (100%) rename {desmume/src => src}/windows/zziplib/zziplib-2008-x32.lib (100%) rename {desmume/src => src}/windows/zziplib/zziplib-2008-x64.lib (100%) diff --git a/desmume/AUTHORS b/AUTHORS similarity index 71% rename from desmume/AUTHORS rename to AUTHORS index 955284518..5e85bd77a 100644 --- a/desmume/AUTHORS +++ b/AUTHORS @@ -7,6 +7,11 @@ Current team Guillaume Duhamel Normmatt Bernat Muñoz (shash) +thoduv +Tim Seidel (Mighty Max) +Pascal Giard (evilynux) +Ben Jaques (masscat) +Jeff Bland Riccardo Magliocchetti Max Tabachenko (CrazyMax) zeromus @@ -14,7 +19,6 @@ Luigi__ adelikat matusz pa__ -gocha Contributors ------------ @@ -27,17 +31,3 @@ delfare Romain Vallet snkmad Theo Berkau -thoduv -Tim Seidel (Mighty Max) -Pascal Giard (evilynux) -Ben Jaques (masscat) -Jeff Bland -Hicoder -ldesnogue - -Thanks to our super testers for this release ------------- -nash679 -pokefan999 -dottorleo -lbalbalba \ No newline at end of file diff --git a/desmume/COPYING b/COPYING similarity index 100% rename from desmume/COPYING rename to COPYING diff --git a/desmume/ChangeLog b/ChangeLog similarity index 82% rename from desmume/ChangeLog rename to ChangeLog index 649a1c77a..446420f95 100644 --- a/desmume/ChangeLog +++ b/ChangeLog @@ -1,448 +1,367 @@ -0.9.4 -> ??? (r2437-r???) - -??? introduces an entirely rewritten main emulation loop. -This totally changes the timing, and totally breaks old savestates. - -Highlights: - * win32: lua engine, path configuration, 7z dearchiving support - * rewritten main emulation loop - -General/Core: - bug: fix cflash directory support for non-windows - bug: fix freeze in cart irq - bug: correctly emulate dma to/from tcm - enh: add guitar grip emulation - enh: add more powerful antigrain-based drawing library and rewrite OSD system - enh: ideas-style debugging prints - -Graphics: - bug: fixing of obj blending, bmp obj rendering, and some obj window cases - bug: fix backdrop blending with garbage - bug: fix 256B granularity sprite addressing for sub gpu - bug: fix 128-wide captures - bug: swrast: add clear image emulation - bug: swrast: add edge marking - -Windows: - bug: improve map view tool to support more modes - enh: added 2x resizing filters (hq2x, 2xsai, supereagle, scanlines) - enh: soundview can now mute channels - -Linux: - enh: alsa microphone support - -0.9.2 -> 0.9.4 (r1844->r2352->r2437) - -0.9.3 was skipped due to emu news sites sneaking it out of our staging area and -releasing it prematurely while it still had bugs. I was going to curse them -individually, but then I decided that they would just like the publicity. - -Highlights: - * New save autodetection and save file format - * Full rerecording support - -General/Core: - bug: fix many 64 bit and endian issues - bug: fix mic input, which was nearly useless before - bug: fix failures of large dmas - bug: fix in ipc sync which broke devkitpro touch - bug: screenshots now exclude hud and rotation - bug: rewritten vram mapping (fixes corrupted or missing BG) - enh: add universal commandline system (same commandline options on every port) - enh: cheats: added Action Replay code parser - enh: more reliable and useful frameskipping - enh: SPU: speedup: add adpcm caching - enh: SPU: speedup: interpolation is now optional - enh: print svn build number so we can identify people's svn builds from screenshots - -Graphics: - bug: add polygon y-sorting (fixes 3d guis) - bug: fix texcoordgen mode 3; fixes some ortho sprites and some entirely broken games - bug: display capture fixes - bug: fix a number of OBJ modes - bug: fixes to affine BG modes - bug: better emulate some translucent OBJ - bug: more correct handling of color effect windows and backdrop colors - bug: fix matrix stack overrun which crashed emulator - bug: swrast: add clear depth image emulation and other fixes to depth buffering - bug: swrast: fix some toon and highlight cases - bug: fix bug in matrix stack, fixes some broken models - enh: add alternate flush mode HACK 3d config toggle, fixes some entirely broken 3d games - -Windows: - bug: more robust cheats engine and dialog - enh: more solid avi and wav recording - enh: improved tools: memory viewer - enh: added tools: spu viewer, ram watch, ram search - enh: change build configuration system - enh: speedup: add gpu core disabling to hide useless screens - enh: add background pause feature (for when emulator loses focus) - enh: add missing autohold for L and R - enh: add chinese translation - -Gtk frontend: - enh: switch all of menu/toolbar system to GtkAction + GtkUIManager - enh: remove the gtglext 3d code - enh: improve/speedup screen resize and final presentation logic in gtk frontend - enh: minimal rerecording hookups - -Cli frontend: - enh: hooked the frameskip (szigor) - enh: misc usability improvements: auto pause switch for pausing when focus is lost and exit on escape pressing (szigor) - enh: hook the fake noise mic; use m to toggle - -0.9.1 -> 0.9.2 -General/Core: - bug: fix error in SBCS/RSCS flags; fixes many odd behaviors and crashes [zeromus] - bug: add support for sleep mode and power registers [luigi__] - bug: important fixes to RTC so correct time is actually told [luigi__] - bug: fix card reads below 0x8000; fixes some game freezes [normatt] - bug: fix 4 mbit save type; fix non-autodetect savefile dumping [zeromus, matusz] - enh: add sram to GBA game addon emulation for importing savefiles [zeromus] - enh: many improvements and feature hookups in linux ports [matusz, luigi__] - -Graphics: - bug: fix specular texture mapping mode [luigi__] - bug: repairs to some capture modes and vram mapping [zeromus, CrazyMax] - bug: viewports finally correctly handled [zeromus] - enh: add software rasterizer. quirky, but on par with opengl [zeromus] - -Windows: - bug: mitigate bad frameskipper; default to old frameskipping mode [zeromus] - bug: fixes with recent roms and zipfile loading [zeromus] - bug: fix window position memory [zeromus] - enh: bios and firmware may now be used and booted [luigi__] - enh: many display, OSD, and input enhancements [luigi__] - enh: brand new hotkey and controls binding system [zeromus] - enh: configurable screen separation [luigi__] - enh: fast forward key [pa__] - enh: improvements to mic [luigi__] - enh: faster updates in debug tools, up to once per frame [pa__] - -Mac OS X Port: - enh: added Italian translation thanks to Paolo Bernini [jeff] - enh: resurrection of GDB stub [sigmaris] - -0.9 -> 0.9.1 -General/Core: - enh: GBA slot emulation [CrazyMax] - - Rumble support (windows only) - - GBA game - enh: Mic support (windows only?) [luigi__] - enh: Preliminary cheats system [CrazyMax] - enh: Savestates invalidated, as more variables have been added. - bug: Added PSG white noise [luigi__] - bug: fix arm/thumb ROR [zeromus] - bug: [ 2550645 ] Super Princess Peach: crash when starting a puzzle [zeromus] - bug: win32: fix spu wav file writer (regression from 0.8) [zeromus,luigi__] - bug: Much work on FIFOs, still not finished [CrazyMax] - bug: Many fixes to dma [zeromus, CrazyMax] - bug: bios WaitForVblank and WaitForInterrupt fixed [luigi__] - -Graphics: - bug: Added sprite blending [luigi__] - bug: more correct mosaic effects, still imperfect [zeromus] - bug: Many fixes to tile rendering; all graphics tests now pass [luigi__] - bug: fix crashes in some affine BG [zeromus] - bug: Implement some pos test function [luigi__] - bug: fix texture mapping across texture and palette banks and to unmapped banks [zeromus] - bug: fix texture handling for texels with MSB set (fixes some texture corruption) [zeromus] - bug: fix texture coordinate generation, including environment mapping [zeromus] - bug: texture cache invalidates when palettes change, prevents some texture corruption [zeromus] - bug: fix display capturing from 2d+3d source when display mode is display-vram [zeromus] - bug: [ 2488334 ].1 fixes to layer compositing [luigi__] - bug: [ 2488334 ].3 fix bug in support for hdma affine bg parameters [zeromus] - bug: Improvements to 3d h-scrolling [luigi__] - bug: Fix some errors in rendering 512 tall BG [zeromus,CrazyMax] (still not fully resolved) - bug: Add optional fragment shading pipeline (more precision) [luigi__] - bug: Fix bug where some sprites got cut of on x=255 [zeromus] - bug: Implement GXSTAT register [CrazyMax] - -Windows: - bug: resizing and rotating work in vista [luigi__] - enh: 0 frameskip now lets emulator run at excess speed [zeromus] - -Mac OS X Port: - bug: left key setting no longer gets confused with the right key [jeff] - enh: more keys can be mapped - -0.8 -> 0.9 - There have been so many changes that this list can hardly be considered complete. - For this release, we have formatted the list into a high level overview of big changes and bad bugs relative to the previous release. Hopefully what you're interested in. - This list does not include items which are solely performance boosts, for let us just say that virtually every system has been speeded up. - - * The savestate system is totally changed and incompatible with old savestates. - * The 3d system should be considered rewritten. - -General/Core: - enh: Convert to c++ - enh: Add functions for a lid open/close. Holding key (default "Backspace" in Windows port) while game is freeze/non freeze. [CrazyMax] - enh: Add secure area decryption from ndstool [zeromus] - enh: Change savestate code to support loosely bound chunks and more easily other parts of the emu (GE, GPU). - The savestate format is changed, but from now on it is in principle more resilient - (though it will continue to break as we tinker with the internals) [zeromus] - enh: Added SSE2 optimizations for matrices. Since we now make an SSE2 build, more optimizations can be made. [CrazyMax] - enh: Add a preliminary GUI hud system [CrazyMax,zeromus] - -CPU/MMU: - bug: Many fixes in IPC and GE FIFOs. Fixes freezes in NSMB, dsracing, and others. [CrazyMax,luigi__,shash] - bug: Fix ARM instructions SBC and RSC (likewise SBC in thumb) [normatt] - bug: Fixed Thumb LDMIA (fixes ingame Dead'n'Furious) [shash] - bug: Fix repeating DMA (fixes NSMB parallax BG) [zeromus] - bug: Proper handling for unaligned CPU accesses [luigi__] - bug: Proper handling for undefined instruction exceptions [Salva Peiró] - bug: correctly return vram control register values (fixes homebrew 3d games) [zeromus] - enh: Remove 16MB of WRAM at 0x01****** from arm9. Mapped to unused instead. Nobody knows what this was. [zeromus] - enh: Changed instruction execution to 16 at a time blocks (tested and stable) [shash] - -Hardware: - bug: Newer and better sqrt and div emulation; makes SM64DS playable [luigi__,shash,zeromus] - bug: Add preliminary RTC implementations [CrazyMax] - enh: Add cosine interpolation in the SPU (conditionally compiled) [zeromus,luigi__] - enh: Experimental: always one silent non-mixing SPU core at 44.1khz synched with emu, for more precision. - The audible core runs with the host, causing music to slow down but not tear or pitch bend. [zeromus] - -Graphics: - - Overhaul 3d: - . Move entire GE to core emu. - . Move OpenGL renderer to emu core for optional use by platforms, removing ogl_collector. Now every platform shares the same 3d code. - . Reorganize 3d code to defer rendering to after 3d vblank. Eliminates tearing, and texturing artifacts. [zeromus] - . Add optional fragment shading pipeline (more precision) [luigi__] - . Move lighting model to software instead of using opengl's fixed function model [zeromus] - . Render shadow volumes; toon shading and highlight table [zeromus, luigi__] - . Added texture caching! big speed up. [CrazyMax] - - bug: Many assorted tweaks and improvements to 3d and 2d precision [zeromus,CrazyMax,luigi__] - bug: Fixes to GE: command unpacking, projection and pos-vector mode matrix handling, mult and load commands [zeromus] - bug: Fix a bug in texture transformation mode 1 [zeromus] - bug: Fixed GPU rendering bugs in sprites and BG [CrazyMax] - bug: Fixes to texture conversion [CrazyMax,zeromus] - bug: Fixes in capture display (no blinking in many games with dual 3D) [CrazyMax] - bug: Fixes in master brightness (this fixes some games with black screens) [CrazyMax] - bug: Fixes in screen, backdrop, and sprite blending [luigi__] - bug: Changed clear depths and how depth initial values are calculated (fixes SM64DS skybox, Castlevania) [shash,lugi__] - bug: Add 3d layer h-scrolling [zeromus] - bug: Added transparency and fixed material alpha support and alpha testing on the 3D core [shash] - bug: Rewrite VRAM mapping control and rendering (more accurate) [CrazyMax,luigi__] - - bug: convert colors to opengl better to prevent alpha=31 polys from being ever so slightly transparent [zeromus] - enh: Add MMU->GPU signal for when vram mappings change to function as a texture cache invalidate signal [zeromus] - enh: Make matrix 4x4 multiply routines use W-coordinate; carry w coord through pipeline [zeromus] - -Mac OS X port: - bug: Fixed: Filenames and paths with unicode characters now work. [Jeff] - bug: Fixed: Load state from file button works again. [Jeff] - enh: Save State panel now pauses emulation while the file selection box is open. [Jeff] - bug: Fixed: Frozen video output (and/or messed 3d emulation) after loading a state. [Jeff] - bug: Added option to load the most recent file upon launching the program. [Jeff] - enh: Added French translation (thanks to Pierre Rudloff). [Jeff] - enh: Added basic key mapping configuration to application preferences (thanks to Julio GorgŽ). [Jeff] - enh: Added keyboard shortcuts for Execute, Pause and Reset command (thanks to Julio GorgŽ). [Jeff] - enh: Default key mappings are no longer case sensitive. [Jeff] - enh: Added ability to limit speed. [Jeff] - enh: Fixed: Video output should work on software-only 3D renderers. [Jeff] - -Windows port: - bug: Fix a race condition in NDS_3D_Reset and NDS_glInit [zeromus] - bug: Fix the buggy auto frameskip logic which made the emu slow to a crawl. Now it runs fast! [zeromus] - bug: Fix resizing, rotate & aspect ration of main window. [CrazyMax,_zeromus] - bug: Remove multithreading from user interface after finding several synchronization issues [zeromus] - enh: recent roms menu [luigi_] - enh: Changed graphics render core to DirectDraw (work faster) [CrazyMax] - enh: Add an arm9 cpu load average calculator similar to no$. but I dont think it works right. [zeromus] - enh: Rewrite all debug tools (autoupdate works now) [CrazyMax] - enh: Rewrite input core & replace config input dialog [CrazyMax] - enh: Add AVI output [zeromus] - enh: Add pause toggle and frame advance hotkeys [adelikat] - enh: Add frame counter display and hud messages framework [adelikat] - enh: Main window remembers position, size, and a few other emu preferences [adelikat] - enh: Removed directx sdk dependency for easier building. [zeromus] - enh: Savestate doesnt unpause emu if it is already paused [adelikat] - -0.7.3 -> 0.8 - Cocoa: - - Save State As function now works. [Jeff B] - - Recent Items menu now works. [Jeff B] - - Opening NDS files from Finder now works. [Jeff B] - - Added screenshot feature. [Jeff B] - - Added preferences. [Jeff B] - - Many more strings are translatable now. [Jeff B] - - Default screen color is black (better represents being "off" and easier on eyes at night). [Jeff B] - - Added sound. [Jeff B] - - Now is a universal binary. [Jeff B] - - Leopard resolution icon added. [Jeff B] - - Added a Japanese translation. [Jeff B] - - Added an optional status bar (resize handle no longer overlaps screen). [Jeff B] - - New ROM Info and About DeSmuME windows have been added. [Jeff B] - - Fixed several bugs in window resizing. [Jeff B] - - Added FAT image support for homebrew games (thanks to TypeError). [Jeff B] - - Key config can be changed on the command line. Save/load hotkeys changed (so expose doesn't override). [Jeff B] - - Key bindings may work better on non-US keyboards now (needs testing). [Jeff B] - general: - - Encapsulate GDB debug stub to avoid certain problems [shash] - - Fixed CPU LD*/ST* bugs [shash] - - Fixed New SMB mini-games freeze [shash] - - Fixed possible segfault in ROMReader on ia64 and amd64. [evilynux] - - Fixed a crash bug with 2D background corrupting memory [shash] - - Flag check optimization [carlo_bramini] - - Applied some endian fixes in GPU (thanks to Phazz) [Jeff B] - gtk-glade: - - Added DeSmuME version in about dialog. [evilynux] - - Updated website url in about dialog. [evilynux] - - Added Brazilian Portuguese translation by Dreampeppers99. [evilynux] - - Better desktop menu entry following FreeDesktop specifications. [evilynux] - gtk: - - Updated website url in about dialog. [evilynux] - - Better desktop menu entry following FreeDesktop specifications. [evilynux] - windows port: - - Added an "about" box [shash] - - DirectInput control interface with joystick support [CrazyMax] - - Matrix and Light viewer [Acid Burn] - -0.7.2 -> 0.7.3 - gtk-glade: - - Full localization using intltool/gettext. [evilynux] - general: - - Added a README.TRANSLATION documenting the localization process. [evilynux] - MacOS X: - - Initial version of the Mac interface added. [Jeff B] - -0.7.1 -> 0.7.2 - spu: - - big endian fixes. [cyberwarriorx] - gpu: - - big endian fixes. [marcus_c] - gtk-glade: - - opengl improvements. [masscat] - general: - - Added support for setting NDS firmware language value. [masscat] - - Function added for setting firmware language. [masscat] - - Mac/msys compilation fixes. [cyberwarriorx] - - Fix compilation when pkg-config macros are not available [evilynux] - -0.7.0 -> 0.7.1 - general: - - Added GDB debugger stub [masscat] - - Added new/different GBAMP CFlash image reader/writer [masscat] - gpu: - - Major speedup to the 2D core [shash] - gtk-glade: - - Added command line options. [masscat] - - Added FPS limiter [masscat] - cli: - - Added command line options. [masscat] - - Added FPS limiter [masscat] - - Added option to use OpenGl to render window (allows resizing). [masscat] - windows port: - - Added command line options. [masscat] - - Added multiple language support [cyberwarriorx] - - Added Danish language translation [thomas-2007] - -0.6.0 -> 0.7.0 - general: - - Added support for *.duc files [cyberwarriorx] - gpu: - - Added support for sprite rotation/scaling [shash] - - Added support for the 3D core (openGL and null plugins) [shash] - windows port: - - A bunch of fixes [Dmitry Krutskih] - - Fixed a bug in sound that was causing it to still not work for some - people [cyberwarriorx] - gtk: - - Added 3D emulation - - Added command line options. - - Added option to use OpenGL to render window (allows resizing). - gtk-glade: - - Added 3D emulation - -0.5.0 -> 0.6.0 - general: - - Added zipped (based on zziplib) and gzipped (based on zlib) rom support. - arm: - - Added relocation interrupt vector. - - Added region access right checks. - - Enabled LDC/STC instructions. - - Fixed powersave (cp15) IRQ wait. - - Fixed MOV instructions - gpu: - - Added special color effects. - - Added windowing feature. - - Fixed transparent direct color backgrounds. - - Fixed disabled sprites showing. - - Fixed 8/32 bit access to gpu registers. - - Fixed missing backgrounds - - Support for master brightness - wifi: - - Added RF chip interface. - - Added BB chip interface. - windows port: - - Fixed address calculation in disassembler. - - Added Force Maintain Ratio option for window stretching - linux port (cli, gtk and gtk-glade): - all: - - Added joystick support. - - Fixed X and Y buttons. - gtk-glade: - - Added joystick configuration. - - Improved I/O registers viewer tool. - - Added save and load states support. - -0.3.3 -> 0.5.0 - arm: - - Fixed MSR with immediate value opcode. - - Fixed LSR_0 thumb opcode (C flag is correctly set now). - - Fixed LDR*/STR* opcodes. - - Fixed unaligned memory access on THUMB Core. - - Added relocating SWI routines. - bios: - - Added decompression functions. - - Added GetPitchTable function. - - Added GetVolumeTable function. - - Added GetCRC16 function. - - Added experimental SoundBias function. - - Added GetSineTable function. - cart: - - Added CompactFlash/FAT emulation. - - Added Get ROM chip ID Cartridge command. - gpu: - - Added framebuffer emulation. - - Fixed a bug in GPU (xfin could be greater than LG causing a segfault). - - Added support for Display Mode 0(Display Off). - - Added the basic framework for Display Mode 3(Display from Main RAM). - spu: - - Added sound emulation. - - Added sound core system. - - Added WAV write core. - - Added dummy core. - - Added Direct Sound core. - linux port: - - Added GTK+ GUI. - - Added command line interface. - - Added stylus and arm9 keypad support in CLI version. - - Added FPS display. - - Added basic frameskip. - windows port: - - Fixed a bug when displaying a ROM's information. - - Added key configuration. - - Removed the debug key. - - Added new experimental auto frameskip/frame limit code. - - Added sound settings dialog. - - Added a few menu options for accessing the website, forums, and for - submitting bugs. - general: - - Rewrote code in C. - - Fixed warnings. - - Used defines and typedef's to make things more portable and easier to - read. - - Added autotools stuff. - - Changes to logging system. - - Added screenshot function. - - Translated most french to english. - - Added savestate support. - - Added firmware reading support(needs work). - - Added Backup Memory support with autodetection. - - Fixed some endianess issues. - - Fixed things so Visual C++ can compile code. - - Added bsd support. - - Reworked ROM loading so you can load a different rom without any problems. - - Finished NDS_Reset. Now the emulation can be reset even while running. +0.9.2 -> 0.9.3 +General/Core: + bug: fixed 64 bit issues and misc integer types usage cleanup [ldesnogues, rm] + enh: added Action Replay code parser [CrazyMax] +Gtk frontend: + enh: switch all of menu/toolbar system to GtkAction + GtkUIManager [matusz] + enh: remove the gtglext 3d code [rm] + enh: fix screen resize in gtk frontend, just resize the window [matusz] + +Windows: + bug: fixed many bugs in Cheats [CrazyMax] + +0.9.1 -> 0.9.2 +General/Core: + bug: fix error in SBCS/RSCS flags; fixes many odd behaviors and crashes [zeromus] + bug: add support for sleep mode and power registers [luigi__] + bug: important fixes to RTC so correct time is actually told [luigi__] + bug: fix card reads below 0x8000; fixes some game freezes [normatt] + bug: fix 4 mbit save type; fix non-autodetect savefile dumping [zeromus, matusz] + enh: add sram to GBA game addon emulation for importing savefiles [zeromus] + enh: many improvements and feature hookups in linux ports [matusz, luigi__] + +Graphics: + bug: fix specular texture mapping mode [luigi__] + bug: repairs to some capture modes and vram mapping [zeromus, CrazyMax] + bug: viewports finally correctly handled [zeromus] + enh: add software rasterizer. quirky, but on par with opengl [zeromus] + +Windows: + bug: mitigate bad frameskipper; default to old frameskipping mode [zeromus] + bug: fixes with recent roms and zipfile loading [zeromus] + bug: fix window position memory [zeromus] + enh: bios and firmware may now be used and booted [luigi__] + enh: many display, OSD, and input enhancements [luigi__] + enh: brand new hotkey and controls binding system [zeromus] + enh: configurable screen separation [luigi__] + enh: fast forward key [pa__] + enh: improvements to mic [luigi__] + enh: faster updates in debug tools, up to once per frame [pa__] + +Mac OS X Port: + enh: added Italian translation thanks to Paolo Bernini [jeff] + enh: resurrection of GDB stub [sigmaris] + +0.9 -> 0.9.1 +General/Core: + enh: GBA slot emulation [CrazyMax] + - Rumble support (windows only) + - GBA game + enh: Mic support (windows only?) [luigi__] + enh: Preliminary cheats system [CrazyMax] + enh: Savestates invalidated, as more variables have been added. + bug: Added PSG white noise [luigi__] + bug: fix arm/thumb ROR [zeromus] + bug: [ 2550645 ] Super Princess Peach: crash when starting a puzzle [zeromus] + bug: win32: fix spu wav file writer (regression from 0.8) [zeromus,luigi__] + bug: Much work on FIFOs, still not finished [CrazyMax] + bug: Many fixes to dma [zeromus, CrazyMax] + bug: bios WaitForVblank and WaitForInterrupt fixed [luigi__] + +Graphics: + bug: Added sprite blending [luigi__] + bug: more correct mosaic effects, still imperfect [zeromus] + bug: Many fixes to tile rendering; all graphics tests now pass [luigi__] + bug: fix crashes in some affine BG [zeromus] + bug: Implement some pos test function [luigi__] + bug: fix texture mapping across texture and palette banks and to unmapped banks [zeromus] + bug: fix texture handling for texels with MSB set (fixes some texture corruption) [zeromus] + bug: fix texture coordinate generation, including environment mapping [zeromus] + bug: texture cache invalidates when palettes change, prevents some texture corruption [zeromus] + bug: fix display capturing from 2d+3d source when display mode is display-vram [zeromus] + bug: [ 2488334 ].1 fixes to layer compositing [luigi__] + bug: [ 2488334 ].3 fix bug in support for hdma affine bg parameters [zeromus] + bug: Improvements to 3d h-scrolling [luigi__] + bug: Fix some errors in rendering 512 tall BG [zeromus,CrazyMax] (still not fully resolved) + bug: Add optional fragment shading pipeline (more precision) [luigi__] + bug: Fix bug where some sprites got cut of on x=255 [zeromus] + bug: Implement GXSTAT register [CrazyMax] + +Windows: + bug: resizing and rotating work in vista [luigi__] + enh: 0 frameskip now lets emulator run at excess speed [zeromus] + +Mac OS X Port: + bug: left key setting no longer gets confused with the right key [jeff] + enh: more keys can be mapped + +0.8 -> 0.9 + There have been so many changes that this list can hardly be considered complete. + For this release, we have formatted the list into a high level overview of big changes and bad bugs relative to the previous release. Hopefully what you're interested in. + This list does not include items which are solely performance boosts, for let us just say that virtually every system has been speeded up. + + * The savestate system is totally changed and incompatible with old savestates. + * The 3d system should be considered rewritten. + +General/Core: + enh: Convert to c++ + enh: Add functions for a lid open/close. Holding key (default "Backspace" in Windows port) while game is freeze/non freeze. [CrazyMax] + enh: Add secure area decryption from ndstool [zeromus] + enh: Change savestate code to support loosely bound chunks and more easily other parts of the emu (GE, GPU). + The savestate format is changed, but from now on it is in principle more resilient + (though it will continue to break as we tinker with the internals) [zeromus] + enh: Added SSE2 optimizations for matrices. Since we now make an SSE2 build, more optimizations can be made. [CrazyMax] + enh: Add a preliminary GUI hud system [CrazyMax,zeromus] + +CPU/MMU: + bug: Many fixes in IPC and GE FIFOs. Fixes freezes in NSMB, dsracing, and others. [CrazyMax,luigi__,shash] + bug: Fix ARM instructions SBC and RSC (likewise SBC in thumb) [normatt] + bug: Fixed Thumb LDMIA (fixes ingame Dead'n'Furious) [shash] + bug: Fix repeating DMA (fixes NSMB parallax BG) [zeromus] + bug: Proper handling for unaligned CPU accesses [luigi__] + bug: Proper handling for undefined instruction exceptions [Salva Peiró] + bug: correctly return vram control register values (fixes homebrew 3d games) [zeromus] + enh: Remove 16MB of WRAM at 0x01****** from arm9. Mapped to unused instead. Nobody knows what this was. [zeromus] + enh: Changed instruction execution to 16 at a time blocks (tested and stable) [shash] + +Hardware: + bug: Newer and better sqrt and div emulation; makes SM64DS playable [luigi__,shash,zeromus] + bug: Add preliminary RTC implementations [CrazyMax] + enh: Add cosine interpolation in the SPU (conditionally compiled) [zeromus,luigi__] + enh: Experimental: always one silent non-mixing SPU core at 44.1khz synched with emu, for more precision. + The audible core runs with the host, causing music to slow down but not tear or pitch bend. [zeromus] + +Graphics: + - Overhaul 3d: + . Move entire GE to core emu. + . Move OpenGL renderer to emu core for optional use by platforms, removing ogl_collector. Now every platform shares the same 3d code. + . Reorganize 3d code to defer rendering to after 3d vblank. Eliminates tearing, and texturing artifacts. [zeromus] + . Add optional fragment shading pipeline (more precision) [luigi__] + . Move lighting model to software instead of using opengl's fixed function model [zeromus] + . Render shadow volumes; toon shading and highlight table [zeromus, luigi__] + . Added texture caching! big speed up. [CrazyMax] + + bug: Many assorted tweaks and improvements to 3d and 2d precision [zeromus,CrazyMax,luigi__] + bug: Fixes to GE: command unpacking, projection and pos-vector mode matrix handling, mult and load commands [zeromus] + bug: Fix a bug in texture transformation mode 1 [zeromus] + bug: Fixed GPU rendering bugs in sprites and BG [CrazyMax] + bug: Fixes to texture conversion [CrazyMax,zeromus] + bug: Fixes in capture display (no blinking in many games with dual 3D) [CrazyMax] + bug: Fixes in master brightness (this fixes some games with black screens) [CrazyMax] + bug: Fixes in screen, backdrop, and sprite blending [luigi__] + bug: Changed clear depths and how depth initial values are calculated (fixes SM64DS skybox, Castlevania) [shash,lugi__] + bug: Add 3d layer h-scrolling [zeromus] + bug: Added transparency and fixed material alpha support and alpha testing on the 3D core [shash] + bug: Rewrite VRAM mapping control and rendering (more accurate) [CrazyMax,luigi__] + + bug: convert colors to opengl better to prevent alpha=31 polys from being ever so slightly transparent [zeromus] + enh: Add MMU->GPU signal for when vram mappings change to function as a texture cache invalidate signal [zeromus] + enh: Make matrix 4x4 multiply routines use W-coordinate; carry w coord through pipeline [zeromus] + +Mac OS X port: + bug: Fixed: Filenames and paths with unicode characters now work. [Jeff] + bug: Fixed: Load state from file button works again. [Jeff] + enh: Save State panel now pauses emulation while the file selection box is open. [Jeff] + bug: Fixed: Frozen video output (and/or messed 3d emulation) after loading a state. [Jeff] + bug: Added option to load the most recent file upon launching the program. [Jeff] + enh: Added French translation (thanks to Pierre Rudloff). [Jeff] + enh: Added basic key mapping configuration to application preferences (thanks to Julio GorgŽ). [Jeff] + enh: Added keyboard shortcuts for Execute, Pause and Reset command (thanks to Julio GorgŽ). [Jeff] + enh: Default key mappings are no longer case sensitive. [Jeff] + enh: Added ability to limit speed. [Jeff] + enh: Fixed: Video output should work on software-only 3D renderers. [Jeff] + +Windows port: + bug: Fix a race condition in NDS_3D_Reset and NDS_glInit [zeromus] + bug: Fix the buggy auto frameskip logic which made the emu slow to a crawl. Now it runs fast! [zeromus] + bug: Fix resizing, rotate & aspect ration of main window. [CrazyMax,_zeromus] + bug: Remove multithreading from user interface after finding several synchronization issues [zeromus] + enh: recent roms menu [luigi_] + enh: Changed graphics render core to DirectDraw (work faster) [CrazyMax] + enh: Add an arm9 cpu load average calculator similar to no$. but I dont think it works right. [zeromus] + enh: Rewrite all debug tools (autoupdate works now) [CrazyMax] + enh: Rewrite input core & replace config input dialog [CrazyMax] + enh: Add AVI output [zeromus] + enh: Add pause toggle and frame advance hotkeys [adelikat] + enh: Add frame counter display and hud messages framework [adelikat] + enh: Main window remembers position, size, and a few other emu preferences [adelikat] + enh: Removed directx sdk dependency for easier building. [zeromus] + enh: Savestate doesnt unpause emu if it is already paused [adelikat] + +0.7.3 -> 0.8 + Cocoa: + - Save State As function now works. [Jeff B] + - Recent Items menu now works. [Jeff B] + - Opening NDS files from Finder now works. [Jeff B] + - Added screenshot feature. [Jeff B] + - Added preferences. [Jeff B] + - Many more strings are translatable now. [Jeff B] + - Default screen color is black (better represents being "off" and easier on eyes at night). [Jeff B] + - Added sound. [Jeff B] + - Now is a universal binary. [Jeff B] + - Leopard resolution icon added. [Jeff B] + - Added a Japanese translation. [Jeff B] + - Added an optional status bar (resize handle no longer overlaps screen). [Jeff B] + - New ROM Info and About DeSmuME windows have been added. [Jeff B] + - Fixed several bugs in window resizing. [Jeff B] + - Added FAT image support for homebrew games (thanks to TypeError). [Jeff B] + - Key config can be changed on the command line. Save/load hotkeys changed (so expose doesn't override). [Jeff B] + - Key bindings may work better on non-US keyboards now (needs testing). [Jeff B] + general: + - Encapsulate GDB debug stub to avoid certain problems [shash] + - Fixed CPU LD*/ST* bugs [shash] + - Fixed New SMB mini-games freeze [shash] + - Fixed possible segfault in ROMReader on ia64 and amd64. [evilynux] + - Fixed a crash bug with 2D background corrupting memory [shash] + - Flag check optimization [carlo_bramini] + - Applied some endian fixes in GPU (thanks to Phazz) [Jeff B] + gtk-glade: + - Added DeSmuME version in about dialog. [evilynux] + - Updated website url in about dialog. [evilynux] + - Added Brazilian Portuguese translation by Dreampeppers99. [evilynux] + - Better desktop menu entry following FreeDesktop specifications. [evilynux] + gtk: + - Updated website url in about dialog. [evilynux] + - Better desktop menu entry following FreeDesktop specifications. [evilynux] + windows port: + - Added an "about" box [shash] + - DirectInput control interface with joystick support [CrazyMax] + - Matrix and Light viewer [Acid Burn] + +0.7.2 -> 0.7.3 + gtk-glade: + - Full localization using intltool/gettext. [evilynux] + general: + - Added a README.TRANSLATION documenting the localization process. [evilynux] + MacOS X: + - Initial version of the Mac interface added. [Jeff B] + +0.7.1 -> 0.7.2 + spu: + - big endian fixes. [cyberwarriorx] + gpu: + - big endian fixes. [marcus_c] + gtk-glade: + - opengl improvements. [masscat] + general: + - Added support for setting NDS firmware language value. [masscat] + - Function added for setting firmware language. [masscat] + - Mac/msys compilation fixes. [cyberwarriorx] + - Fix compilation when pkg-config macros are not available [evilynux] + +0.7.0 -> 0.7.1 + general: + - Added GDB debugger stub [masscat] + - Added new/different GBAMP CFlash image reader/writer [masscat] + gpu: + - Major speedup to the 2D core [shash] + gtk-glade: + - Added command line options. [masscat] + - Added FPS limiter [masscat] + cli: + - Added command line options. [masscat] + - Added FPS limiter [masscat] + - Added option to use OpenGl to render window (allows resizing). [masscat] + windows port: + - Added command line options. [masscat] + - Added multiple language support [cyberwarriorx] + - Added Danish language translation [thomas-2007] + +0.6.0 -> 0.7.0 + general: + - Added support for *.duc files [cyberwarriorx] + gpu: + - Added support for sprite rotation/scaling [shash] + - Added support for the 3D core (openGL and null plugins) [shash] + windows port: + - A bunch of fixes [Dmitry Krutskih] + - Fixed a bug in sound that was causing it to still not work for some + people [cyberwarriorx] + gtk: + - Added 3D emulation + - Added command line options. + - Added option to use OpenGL to render window (allows resizing). + gtk-glade: + - Added 3D emulation + +0.5.0 -> 0.6.0 + general: + - Added zipped (based on zziplib) and gzipped (based on zlib) rom support. + arm: + - Added relocation interrupt vector. + - Added region access right checks. + - Enabled LDC/STC instructions. + - Fixed powersave (cp15) IRQ wait. + - Fixed MOV instructions + gpu: + - Added special color effects. + - Added windowing feature. + - Fixed transparent direct color backgrounds. + - Fixed disabled sprites showing. + - Fixed 8/32 bit access to gpu registers. + - Fixed missing backgrounds + - Support for master brightness + wifi: + - Added RF chip interface. + - Added BB chip interface. + windows port: + - Fixed address calculation in disassembler. + - Added Force Maintain Ratio option for window stretching + linux port (cli, gtk and gtk-glade): + all: + - Added joystick support. + - Fixed X and Y buttons. + gtk-glade: + - Added joystick configuration. + - Improved I/O registers viewer tool. + - Added save and load states support. + +0.3.3 -> 0.5.0 + arm: + - Fixed MSR with immediate value opcode. + - Fixed LSR_0 thumb opcode (C flag is correctly set now). + - Fixed LDR*/STR* opcodes. + - Fixed unaligned memory access on THUMB Core. + - Added relocating SWI routines. + bios: + - Added decompression functions. + - Added GetPitchTable function. + - Added GetVolumeTable function. + - Added GetCRC16 function. + - Added experimental SoundBias function. + - Added GetSineTable function. + cart: + - Added CompactFlash/FAT emulation. + - Added Get ROM chip ID Cartridge command. + gpu: + - Added framebuffer emulation. + - Fixed a bug in GPU (xfin could be greater than LG causing a segfault). + - Added support for Display Mode 0(Display Off). + - Added the basic framework for Display Mode 3(Display from Main RAM). + spu: + - Added sound emulation. + - Added sound core system. + - Added WAV write core. + - Added dummy core. + - Added Direct Sound core. + linux port: + - Added GTK+ GUI. + - Added command line interface. + - Added stylus and arm9 keypad support in CLI version. + - Added FPS display. + - Added basic frameskip. + windows port: + - Fixed a bug when displaying a ROM's information. + - Added key configuration. + - Removed the debug key. + - Added new experimental auto frameskip/frame limit code. + - Added sound settings dialog. + - Added a few menu options for accessing the website, forums, and for + submitting bugs. + general: + - Rewrote code in C. + - Fixed warnings. + - Used defines and typedef's to make things more portable and easier to + read. + - Added autotools stuff. + - Changes to logging system. + - Added screenshot function. + - Translated most french to english. + - Added savestate support. + - Added firmware reading support(needs work). + - Added Backup Memory support with autodetection. + - Fixed some endianess issues. + - Fixed things so Visual C++ can compile code. + - Added bsd support. + - Reworked ROM loading so you can load a different rom without any problems. + - Finished NDS_Reset. Now the emulation can be reset even while running. diff --git a/desmume/Makefile.am b/Makefile.am similarity index 100% rename from desmume/Makefile.am rename to Makefile.am diff --git a/desmume/NEWS b/NEWS similarity index 100% rename from desmume/NEWS rename to NEWS diff --git a/desmume/README b/README similarity index 100% rename from desmume/README rename to README diff --git a/desmume/README.LIN b/README.LIN similarity index 100% rename from desmume/README.LIN rename to README.LIN diff --git a/desmume/README.MAC b/README.MAC similarity index 100% rename from desmume/README.MAC rename to README.MAC diff --git a/desmume/README.TRANSLATION b/README.TRANSLATION similarity index 100% rename from desmume/README.TRANSLATION rename to README.TRANSLATION diff --git a/README.WIN b/README.WIN new file mode 100644 index 000000000..45d860d18 --- /dev/null +++ b/README.WIN @@ -0,0 +1,503 @@ + + +DeSmuME Manual for the Windows port + +1 Quick Getting Started Guide +1.1 Menu Layout +1.1.1 File Menu +1.1.1.1 File | Open Rom +1.1.1.2 File | Recent Rom +1.1.1.3 File | Rom Info +1.1.1.4 File | Save State As... +1.1.1.5 File | Load State As... +1.1.1.6 File | Save State +1.1.1.7 File | Load State +1.1.1.8 File | Import Backup Memory +1.1.1.9 File | Save Screenshot As... +1.1.1.10 File | Quick Screenshot +1.1.1.11 File | Record AVI +1.1.1.12 File | Stop AVI +1.1.1.13 File | Quit +1.1.2 Emulation Menu +1.1.2.1 Emulation | Pause +1.1.2.2 Emulation | Reset +1.1.2.3 Emulation | Shut Up +1.1.2.4 Emulation | GBA Slot +1.1.2.5 Emulation | Cheats +1.1.2.6 Emulation | Cheats | List +1.1.2.7 Emulation | Cheats | Search +1.1.3 View Menu +1.1.3.1 View | Rotation +1.1.3.2 View | Window size +1.1.3.3 View | Screen Separation +1.1.3.4 View | Force Maintain Ratio +1.1.3.5 View | Display Frame Counter +1.1.3.6 View | Display FPS +1.1.3.7 View | Display Input +1.1.3.8 View | Display Lag Counter +1.1.3.9 View | HUD Editing Mode +1.1.4 Config Menu +1.1.4.1 Config | Save Type +1.1.4.2 Config | 3D Settings +1.1.4.3 Config | Control Config +1.1.4.4 Config | Hotkey Config +1.1.4.5 Config | Sound Settings +1.1.4.6 Config | WIFI Settings +1.1.4.7 Config | Firmware Settings +1.1.4.8 Config | Emulation Settings +1.1.4.9 Config | Frame Skip +1.1.4.10 Config | Language +1.1.5 Tools Menu +1.1.5.1 Tools | Disassembler +1.1.5.2 Tools | View Memory +1.1.5.3 Tools | View Registers +1.1.5.4 Tools | View Palette +1.1.5.5 Tools | View Tiles +1.1.5.6 Tools | View Maps +1.1.5.7 Tools | View OAM +1.1.5.8 Tools | View Matrices +1.1.5.9 Tools | View Lights +1.1.5.10 Tools | View Layers +1.1.6 Help Menu +1.1.6.1 Help | Website +1.1.6.2 Help | Forums +1.1.6.3 Help | Submit a bug report +1.1.6.4 Help | About + + +Quick Getting Started Guide +When you start the emulator for the first time, you probably just want to play a certain game. You can do this by going to 'File' in the menu, and selecting 'Open Rom'. This will open up an explorer window, within which you can browse to the rom (nds file) that you wish to play. Once the game has finished loading (and this should only take a few seconds at most), your game will automatically start running. But if you want, you can also compile from source. See the article Installing DeSmuME from source on Windows for details. + +Menu Layout +The rest of this manual will be spend on explaining all the other options in the menu. + + + + +File Menu +File | Open Rom +This option is for loading games. A game is typically called a rom file. Just use the explorer window to browse to the file, and click on open. The game should just load and start. The desmume windows port is also able to load some compressed formats, like zip, rar, and 7-zip. Just as long as there is a valid game (rom) file in the compressed archive ending with an .nds extension, it should load fine. + +File | Recent Rom +This menu option contains a list of the roms that you have most recently loaded. You can quickly access a game that way, without having browse to the right directory with the 'Open Rom' option. + +File | Rom Info +This option offers some information about the internals of the rom file, like name, code, manufacturer, and size. This should not concern the casual gamer, but may come in handy for developers. + +File | Save State As... +Imagine you have gotten to a certian point in a game, and you need to do something else. The emulator let's you save the current state of the game, so that you can continue the game later at precisely the same point somewhere in the future. + +File | Load State As... +Once you have saved a game's position, or 'state', you can load it again with this option. + +File | Save State +This option works fairly similair to the 'Save As' option, altough it let's you save numbers instead os specifying a chosen name. Also, All the states saved via this option end up with a pre-determined name of 'game (rom) name'.dsx. So if the game is called MyGame, the first savefile will be called MyGame.ds0, the second one MyGame.ds1, etc. + +File | Load State +This option let's you load the states that you saved via the 'File | Save State' option + +File | Import Backup Memory +Backup Memory is the data the game uses to remember its own state. It is stored on the cart in a normal game. The file format is '.duc'. .duc is the same thing as .sav but a different format. People use pro action replays to capture it from their card and post it online without using emulators. Go to gamefaqs.com and find a '.duc' save file for a game you can use that function to import it into desmume. Its the save file. save ram. where your saved game goes. desmume calls it .sav file + +File | Save Screenshot As... +This lets you take a screenshot of the current view of the emulator, and specify it's name to save as a bitmap (.bmp) file. + +File | Quick Screenshot +This option also dumps a screencapture, but it has a pre-determied filename and location. It will be called printscreen.bmp, and located in the current directory. In Windows, this is probably the same folder as where your desmume binary is located. + +File | Record AVI +This option lets you capture what's going on in the emulator, and save it in an avi file. + +File | Stop AVI +The 'Record AVI' option continues to record the game, untill you press the 'Stop Avi' option. + +File | Quit +Choosing this option exits the emulator. + + + + +Emulation Menu +Emulation | Pause +This option will pause the emulation, freezing it at the current moment of execution. Selecting it again will resume the execution of the ROM at the exact moment where you paused it. + +Emulation | Reset +This option will reset the ROM that is currently loaded to the very start of the ROM, just as if you chose 'File | Open Rom' again. + +Emulation | Shut Up +This option turns off all the sound. + +Emulation | GBA Slot +This menu option pop-ups a new window, which lets you specirfy what to do with the GBA slot of the Nintendo DS. It has the following choices : NONE, Compact Flash, Rumble Pack, GBA Game. Rumble pack allows some games to use vibration. Memory extension... Extends memory. And some DS games can have bonuses, unlockable by GBA cart. For example in Megaman ZX you can fight some Megaman Zero Bosses when correct cartridge is inserted. There are also other GBA slot extensions, like... a Guitar hero controller. But these are currently not emulated by desmume. Flash Cartridge is used for homebrew software emulation, for example that uses DLDI ( Dynamically Linked Device Interface). + +Emulation | Cheats +This option pulls down a drop-down menu, and presents the options list and search. Be aware though, that cheats are sort of half baked right now. If you are not having luck, wait for some news on an improved cheat system. + +Emulation | Cheats | List +Choosing 'list' will list all the currently known cheats. Please refer to the article Using Cheats in DeSmuMe for further details on how to use the cheat mechanism in desmume. + +Emulation | Cheats | Search +Choosing 'search' will let you search for cheats. Please refer to the article Using Cheats in DeSmuMe for further details on how to use the cheat mechanism in desmume. + +View Menu +View | Rotation +This option will let you rotate the screen a pre-determined amount of degrees in order to adjust the angle of the display. Some programs require that you normally turn the DS on its side. You can set it up in that manner using this. The options are 0 (no rotation),90 ,180, and 270. + +View | Window size +This option will let you enlarge the windows a pre-determined size. The resize options are: 1x, 1.5x, 2x, 3x, and 4x the default size. You can also adjust the window size by clicking on the edge of the window, and dragging the mouse. + +View | Screen Separation +This option controls how far the two windows should be apart of each other, in other words: how big the border between them should be. Valid choices are: None (which is the default), narrow border (which is slightly larger), DS (which is about the wsame amount of room there is on a real Nintendo DS). + +View | Force Maintain Ratio +Here you can choose, when re-sizing the windows, if you wan to maintain the ratio of the windows. Sometimes when the window size is changed it doesn't look correct on the screen. This option forces the window to maintain a correct ratio so it looks correct. You can select or de-select this option. + +View | Display Frame Counter +Selecting this option causes a counter to run, that counts all the frames that have been displayed. + +View | Display FPS +Selecting this option causes the 'frames-per-second' (or 'fps', for short) to be displayed. + +View | Display Input +Selecting this option displays the keys you press on the keyboard, which is the input + +View | Display Lag Counter +This option causes a counter to display that counts frames where the game doesn't poll input. + +View | HUD Editing Mode +This option will let you drag around hud elements to pick their position. + + + + +Config Menu +Config | Save Type +This option lets you specify the save type of a particular game. The default is 'automatic'. However, this is not fail-safe in all cases, so you might need to manually select one of the other savetypes. + +Config | 3D Settings +This option lets you select the method that is used to draw the screen. You can choose between OpenGL (an open standard) or SoftRasterizer (a desmume specific method). + +Config | Control Config +This option lets you configure keyboard keys or a joystick. The joystick support is implemented using a DirectInput control interface. + +Config | Hotkey Config +This menu option lets you define keys, that can be used to quickly select other options without having to go through the entire menu structure. Some examples are A hotkey for 'pause', or a hotkey for loading a specific savestate. + +Config | Sound Settings +This option lets you choose between different sound generating methods, which currectly are 'Direct Sound Interface' and 'WAV Write sound Interface'. it also let's you specify the size of the buffer to buffer the sound. + +Config | WIFI Settings +WIFI support is currently under heavy development, but it is not deemed ready for inclusion in the general public releases yet. Therefore, you may find this option missing, or simply 'greyed-out' for now. + +Config | Firmware Settings +This option provides you with the same set of options that a real Nintendo DS firmware does. The most important here is the language, for multi-langual games will often look at how this option is set. + +Config | Emulation Settings +These options let you boot from the extracted BIOS and Firmware of a real Nintendo DS. unless you have extracted/downloaded the firmware or bios from a Nintendo DS that you actually own yourself, these settings have no value for you qas desmume does not require them to run correctly. + +Config | Frame Skip +This option lets you select how many frames should not be displayed, in order to gain speed improvements. The default is 'Auto'. If you have speed problems, you could decide to skip (not display) one or more frames in order to improve the speed. 'Limit Frameskip' let's you limit the frame rate to 60fps maximum. 60fps is essentially the speed that the game plays at on the actual console itself. So by selecting this option, you're limiting the framerate to the actual speed of the actual console. + +Config | Language +This lets you set the langguage the emulator displays it's menu's and options in. + +Tools Menu +Tools | Disassembler +This option displays the ARM9 and ARM7 disassembler. Be aware though, that the windows are drawn exactly on top of each other, so that you have to move (drag n drop) the first windows before the second window shows. + +Tools | View Memory +This tool displays the ARM7 and ARM9 memory. Be aware though, that the windows are drawn exactly on top of each other, so that you have to move (drag n drop) the first windows before the second window shows. + +The "View mode" radio buttons allow you to choose how the memory will be shown: + +8-bit : shows the memory as bytes +16-bit : shows the memory as words +32-bit : shows the memory as dwords +The "View address" textbox and button allow you to jump to a different address: + +Enter an hexadecimal address without 0x prefix, with up to 8 digits +Click "Go" to jump to the entered address +The "View dump" buttons allow you to dump the current view: + +Text dump : dumps the view to a text file, in an human-readable form +Raw dump : dumps the memory directly to a binary file which can be read with an hex editor +Note that if you dump memory to a file already containing (a) dump(s), the new dump will be appended to the existing one(s). + +The scrollbar... well, you surely know how a scrollbar works. + +The viewers additionally allow to edit the memory. For it, click on the value you want to edit, then type the new value. The new value is applied only once you've entirely entered it. + +Tools | View Registers +This option lets you view the ARM7 and ARM9 I/O registers. + +Tools | View Palette +This option lets you view the palette in detail. + +Tools | View Tiles +This option lets you view the tiles in detail. + +Tools | View Maps +This option lets you view the maps in detail. + +Tools | View OAM +This option lets you view the OAM layer in detail. + +Tools | View Matrices +This option lets you view the matrices in detail. + +Tools | View Lights +This option lets you view the lights in detail. + +Tools | View Layers +This option lets you view the Layers one by one. + + + + +Help Menu +Help | Website +This option directs your browser to the desmume homepage. + +Help | Forums +This option directs your browser to the desmume forums. + +Help | Submit a bug report +This option directs your browser to the SourceForge bugtracker for desmume. + +Help | About +This option displays the authors of the emulator. + +Retrieved from "http://wiki.desmume.org/index.php?title=DeSmuME_Manual_for_the_Windows_port + +This page was last modified on 20 April 2009, at 10:45. + +==================================================================== + +Faq + +If the FAQ is unable to answer your question(s), then please make sure that you also consult the manual. + +Contents [hide] +1 General Questions +1.1 What does desmume emulate and on what systems? +1.2 What does DeSmuME mean? +1.3 Why doesn't my desmume play this game? +1.4 Why does this game fail to save? +1.5 Can I use my savefile's acrosss versions ? +1.6 Why can't I find a mac binary? +1.7 Why does my mac binary say something about being unsupported? +1.8 Where can I report bugs? +1.9 Can I attach files to bug reports I did not create myself ? +1.10 How do I get the latest svn code and build desmume myself? +1.11 Whats 'svn' ? +1.12 What compilers are supported for building desmume from source ? +1.13 Im a developer, and would like to contribute to the codebase. What can I do ? +1.14 Im not a developer, but would like to help out anyway. What can I do ? +1.15 It is hard to zoom in on a widescreen display due to the weird aspect ratio of the DS. +1.16 Why doesn't my openGL 3d work in linux? +1.17 Why doesn't my openGL 3d work in windows? +1.18 Why doesn't a menu option or tool exist in my linux or mac build? +1.19 Why does music sound bad sometimes? +1.20 Why doesn't my game boot or progress into the main game engine? +1.21 What hardware features are emulated? +1.22 Does the GDB stub still work? +1.23 Where/what is IRC? +1.24 Where is the manual? +1.25 How do I enter 'cheat codes' in desmume ? +1.26 Why is the emulator slow? +1.27 What are the minimum hardware requirements for desmume ? +1.28 What are the recommended hardware requirements for desmume ? +1.29 Does desmume support wifi ? +1.30 Why do I get an assert in wifi.cpp which keeps me from playing a game? +1.31 OK, then why does it make my firewall alert since 0.9.2 ? +1.32 Does desmume support the microphone ? +1.33 Where can I find technical details on the Nintendo DS and GBA ? +1.34 Does the 'GBA slot' option let me play GBA games ? +1.35 What is DLDI ? +1.36 I get the error: Data could not be accessed. Turn off the power and reinsert the DS card. +1.37 How can I post a screenshot file on the desmume forum ? +1.38 How can I post a savefile or avi capture on the desmume forum ? +1.39 How can I post a large log or other text file on the desmume IRC chat room ? +1.40 My display is incorrect or corrupted +1.41 What are the origins of DeSmuME ? + + +General Questions +What does desmume emulate and on what systems? +Desmume attempts to emulate, as faithfully as possible, the Nintendo DS and Nintendo DS Lite handheld game consoles (nds). It currently runs on Windows, Linux, and mac OSX. DSi is not supported. + +What does DeSmuME mean? +DeSmuME is a Nintendo DS emulator and the name is a play of words - DS Emu + ME (like FlashMe - firmware hack and PassMe mod-chip for DS) The name DeSmuME derives from the popular use of ME in Nintendo DS products by homebrew developers. So DeSmuME would equal DSemuMe. Other popular uses of ME include: + +LoadMe - a generic patcher for commercial DS roms that works with any GBA Flash Card +PassMe - "mod-chip" using which takes authentication from an original DS card an allows execution of unauthenticated DS rom code - from the GBA cartridge slot / GBA flash card. +FlashMe - a hacked firmware for DS that allows you to start code in DS mode from a flash card in the GBA slot. +WifiMe - are a set of a custom drivers and software by FireFly for RALink based wireless network cards enabling to boot homebrew code on DS via Nintendo Wireless Multiboot method. +Why doesn't my desmume play this game? +Go to desmume.org and make sure you are using the latest version. Hint: desmume 0.8 and 0.3.4 are very old. Older versions will not be supported, under any circumstances. +Why does this game fail to save? +Desmume's autodetection for save types is not very good. For now, you need to manually specify the correct save type for your game. Consult the manual for details on how to do this for your platform. We want to fix this, but there are no specific plans so far. You may also consult http://www.advanscene.com/ to easily identify the save type for your game. +Can I use my savefile's acrosss versions ? +Probably not. Due to the constant internal changes sin desmume, it is unlikely that a savefile created with one version will work with another version of desmume +Why can't I find a mac binary? +We have an 0.9.2 mac binary which might not be linked to from the downloads page yet. Go to https://sourceforge.net/project/showfiles.php?group_id=164579&package_id=186413 +Why does my mac binary say something about being unsupported? +There is no universal mac binary. Only i386 is supported. I blame the big endians. If you don't like this, better volunteer yourself to fix endian issues in the code (every day, I see something new that makes me say 'hmmmm that doesnt look endian safe') +Where can I report bugs? +In the official bug tracker; you may also request features around the same location, too, but in the other trackers. +Can I attach files to bug reports I did not create myself ? +SourceForge likes for folks to only respond on items they submit. If you see a ticket that represents something you are encountering, SourceForge doesn't necessarily want you commenting on that. The reasoning for this given by SourceForge is that they feel it is best to open your own ticket, which helps appreciate the extent of issues in many cases. The authors of desmume may or may not agree with this point of view from SourceForge. +How do I get the latest svn code and build desmume myself? +Please check out the instructions related to your platform, over at Installing DeSmuME from source +Whats 'svn' ? +svn is a developers tool. It's used to let multiple developers work on the same codebase without conflicts. If youre an end-user, don't worry about it. And if you're a developer, see the question on how to get the latest svn code and build desmume yourself. See wikipedia for more info + +What compilers are supported for building desmume from source ? +At the moment, for Windows Microsoft Visual C++ 2005 and 2008 are the only supported compilers. Dev-c++ is not supported. Why won't you just download visual c++ express? +For Linux, any recent version of GCC and toolchain should work. +Im a developer, and would like to contribute to the codebase. What can I do ? +To start you off in the right direction, the best thing you can do is join the developer team on IRC and discuss your intentions with the developers. + +Im not a developer, but would like to help out anyway. What can I do ? +The most helpful thing you can do is use it, learn its ins and outs, and learn how to compile svn builds. Then monitor it for regressions and report bugs. You can patrol the bug tracker for bugs which could use elucidation or which, based on your awareness of how the emulator is changing, might be fixed without us having specifically addressed the bug. Basically, be a super user. And hang out on irc. Also, adding to or perfecting the documentation in the wiki is usefull. You could also watch for and answer questions placed on the desmume forum. + +It is hard to zoom in on a widescreen display due to the weird aspect ratio of the DS. +In fact it is hard to zoom in on a 4:3 screen, too. Proposals involve tearing apart windows and floating them side by side or separately or something. This may happen one day, in the form of side by side windows. + +Why doesn't my openGL 3d work in linux? +Blame nvidia and ati for putting out shoddy drivers. Then switch to software rasterizer. + +Why doesn't my openGL 3d work in windows? +You are probably using an ATI video card. ATI driver support of OpenGL is known to be poor. Get an nvidia. Do not argue with that, we are professional programmers and know what we're talking about. Or, switch to software rasterizer + +Why doesn't a menu option or tool exist in my linux or mac build? +Because making portable tools and platform harnesses are not our cup of tea and so a developer puts a feature into whichever ports he cares about. This policy is never going to change, although some features might migrate to other platforms over time. Better check the manual. + +Why does music sound bad sometimes? +Most DS music is sequenced music, loaded from the cart to the ARM7 entirely when the level loads. This works fine. Your music that doesn't work is probably streaming music, which loads from the cart on the fly and goes straight to the speakers. This is much harder to emulate as it requires correct timing, which is not one of desmume's strengths right now. This may not be fixed for a while. + +Why doesn't my game boot or progress into the main game engine? +Desmume is not perfect yet. Some games may fail due to wifi emulation. Apparently if you search the web correctly you can find ways to patch games to work better on emulators. + +What hardware features are emulated? +All known 2d graphics features are correct. Mosaics work but are imperfect. There may be small issues with colors as the correct color bit depths are not used at all points in the pipeline. +All 3d features are emulated, except for: tests, wireframes, edge marking, fog, and antialising. The opengl engine is near its limit and renders some things incorrectly. Eventually the software rasterizer (will support more features and be far more precise in the basic features. Both engines have trouble with some shadows, but software rasterizer is better. Software rasterizer has some noticeable texturing issues right now, especially in 2d games. Software rasterizer supports more correct lighting interpolation than opengl ever will (e.g. glitches at the edge of the screen while scrolling.) In software rasterizer, there are issues similar to 2d with incorrect bit depth being used in the pipeline. There are inaccurate edge conditions in each renderer; in opengl, textures tend to get overdrawn; in software rasterizer, edges of textures tend to be jittery. +One last thing -- if buttons and labels and menus rendering on the 3d screen are obscured (for example, a button but no label is on it) then you may need to use the software rasterizer. + +All sound features are emulated. The microphone support is new and the manual should be consulted, where you will find out, among other things, that it is only supported in windows right now. +Wifi is not supported. It is currently under slow and incomplete development. Therefore, you may find this option missing, or simply 'greyed-out' for now. Also, since WIFI support does not work yet, don't ask any questions about it's functioning because it still is unfinished and does not work yet. +We are unaware of any outstanding issues in the core system hardware (cpu, dma, mmu) but there are certainly still some. The instruction and memory timings are quite incorrect; however, this seems not to hurt most softwares. +DLDI does anybody know if this still works? +Dynamically Linked Driver Interface, commonly known as DLDI, is a driver framework that allows NDS and GBA homebrew to easily read and write to any number of different devices, just by substituting a driver file. +RTC (real-time clock) works; This is what makes the time in your games stay at 00:00:00, and what makes your random number values always come up the same. +Does the GDB stub still work? +This has not been built into the public releases, nor has the feature been tested in a while. If you want to be a test user, please hop on IRC and coordinate with us. + +Where/what is IRC? +IRC is an on-line communication system. + +data you need: + +server: irc.freenode.net +port: 6667 +channel: #desmume +what to use: + +mIRC - windows +ChatZilla - FireFox add-on +xchat - X +plenty other, see wikipedia +Where is the manual? +A manual for desmume is over at http://wiki.desmume.org/index.php?title=Manual. It may not have the information that other entries in this FAQ promised that it would. + +How do I enter 'cheat codes' in desmume ? +It is impossible yet to use "commercial" codes, such as Action Replay and Codebreaker, so what you'll have to do is manually search for, and alter the memory positions to your advantage. There's an excellent article in the wiki on Using Cheats in DeSmuMe + +Why is the emulator slow? +Because nobody pays us to work on it full time and it runs fast enough for us to be happy. Well, almost. The cheapest way to get 60fps is to buy the cart. Buying a newer, faster computer is somewhat more expensive, and it has other side benefits. Also, if you are in Windows, make sure you have tried the SSE build which helps a little bit. Additionally, if you are using someone else's interim build it might not be fully optimized since we make our Windows releases using some profiler-guided optimization which helps by several FPS. You could try turning off the sound. And one last thing: try a new video card. But only as long as it is an nvidia. Also, a faster CPU is more helpfull than a bleeding edge graphics card. desmume is more CPU intensive than it is GPU intensive. It just needs a graphics card that is glitch-free, and currently the nvidia cards have a better track record. + +What are the minimum hardware requirements for desmume ? +From a purely technical viewpoint, there are no minimum requirements. However, for 'real-world' playable speeds, you would need at least the following : + +Windows OS: Windows XP or Vista +Linux OS: Any recent Linux distribution with a 2.6 kernel. +2 GHz Processor +512 MB Available System Memory +Available Hard Drive Space: A few MB for desmume, and several GB for the nds files. +128 MB 3D Video Card (Nvidia GeForce 6800 or better), ATI cards are not recommended. +Optional: Sound Card, if you want sound support +Optional: Microphone, if you wish to make use the Windows Microphone feature +What are the recommended hardware requirements for desmume ? +From a purely technical viewpoint, there are no recommended requirements. However, for 'real-world' playable speeds, the following gives you good performance: + +Windows OS: Windows XP or Vista +Linux OS: Any recent Linux distribution with a 2.6 kernel. +3 GHz Processor +1 GB Available System Memory +Available Hard Drive Space: A few MB for desmume, and lots of GB's for the nds files. +512 MB 3D Video Card (Nvidia GeForce), ATI cards are not recommended. +Sound Card. +Microphone. +Does desmume support wifi ? +Wifi is not supported. It is currently under slow and incomplete development. Therefore, you may find this option missing, or simply 'greyed-out' for now. Also, since WIFI support does not work yet, don't ask any questions about it's functioning because it still is unfinished and does not work yet. Furthermore, current development activities focus mainly on the Windows build. + +Why do I get an assert in wifi.cpp which keeps me from playing a game? +This was a glitch in 0.9.2 release. The download package has been replaced. Download it again and check the changelog to see if you have the fixed version. + +OK, then why does it make my firewall alert since 0.9.2 ? +Your firewall is stupid, or winsock is stupid, (I am not sure which yet) for alerting just when winsock gets initialized. The emulator hasnt actually tried to connect to the internet yet. How could it? There isn't any wifi. All we are doing is some network initialization code. For those of you who are still not satisfied, then I will admit that there is actually some wifi code--but it doesnt actually do anything yet! Except alert your firewall. Sorry. Also, maybe that is actually a good, unobtrusive time for firewalls to alert. But I am not sorry for calling them stupid. They are hyperactive crybabies. + +Does desmume support the microphone ? +Yes, but only on the Windows port. You do have to have an actual microphone attached to your PC, though. And perhaps somewhat confusing, the Linux ports do report 'Microphone successfully initialized' on startup of the emulator - but currently this is just a piece of stub (dummy) code used only to correctly start the emulator. + +Where can I find technical details on the Nintendo DS and GBA ? +http://nocash.emubase.de/gbatek.htm + +Does the 'GBA slot' option let me play GBA games ? +No. A 'real' Nintendo DS can use the gba slot to play gba games, but desmume does not emulate this. But a 'real' Nintnedo DS can also use the gba slot to access gba roms and sram so that ds games can import savefiles, and that part is emulated by desmume. If you are looking for a Game Boy Advance (GBA) emulator, perhaps you can try mednafen or visualboy advance. + +What is DLDI ? +let me give you an overview on DLDI. You should know that there are many various flash cartridges for DS. They use different file allocation systems, different storages, etc. They are used for launching homebrew. So to make one proram run on all cards. You’d have to write support for each and every card so that it worked for everyone. But none needs support for other cards than their And then genial solution was found. There was an universal IO unit made that’s just interface to IO operations. If you don't have a DS, why do you bother with desmume ? You surely don't have bought any game to run on it. And compiled program does not know how to handle file system etc. And then user can append IO routines for his own card. “DLDI patch”. So, now when I have an M3 cart. I download rom, patch it with m3 DLDI patch. And it works on my cart. Say you had Supercard instead. You’d have to download very same rom and apply Supercart DLDI patch to it. DLDI patch is the same for all roms. So it’s easy for both developper and end user. + +I get the error: Data could not be accessed. Turn off the power and reinsert the DS card. +The automatic savetype detection probably failed to detect the correct savetype, and you have to set it manually to the correct type. If you are lucky, information about your game (and the corresponding savetype) can be found on a website such as http://www.advanscene.com/. And if you're not as lucky, you'll just have to try them all out until you find the correct type. + +How can I post a screenshot file on the desmume forum ? +You can create a screenshot, and then upload it to a free external service provider like ImageShack (http://imageshack.us/), and then put the provided links to the page in the message you post on the forum. + +How can I post a savefile or avi capture on the desmume forum ? +After you created it, yo can upload it to a free external service provider like MediaFire (http://www.mediafire.com/), and then put the provided links to the page in the message you post on the forum. + +How can I post a large log or other text file on the desmume IRC chat room ? +Make use of the external service provider 'pastebin' (http://pastebin.com/), and post the url to it on the IRC channel. + +My display is incorrect or corrupted +Try switching the 3D Renderer from opengl or SoftRasterizer, or vice versa, to see if that resolves the bug. In windows, the default hotkey to do this quickly is numpad minus. + +What are the origins of DeSmuME ? +DeSmuME is a freeware emulator for the Nintendo DS created by YopYop156. + +Due to change in French laws regarding emulation YopYop has decided to stop development of DeSmuME Nintendo DS emulator but that doesn't mean that DeSmuME is obsolete - programmers in this project have picked up where Yopyop left off. The original website was http://yopyop156.ifrance.com/. + +Yopyop said: + +It’s release under GPL. I have just removed the new 3D engine because it’s too much bugged. Hopefully it will be helpful for some of you. + +The latest statement heard from yopyop was : + +DeSmuMe project is over. +You may don’t know but there are a new law in France that could put me in big trouble. +With DeSmuMe, I have closed the doors of game company but I can not offer to pay for it. +The worst thing is that I have found the bad coded instructions. +For those how have download the sources you have to look in sbc, rsbc instructions the Carry flag updating is wrong. +Sorry for the home brew programmers. +For the illegality the demonstration seemed to me convincing thus without proof clarify I prefer to stick to this decision. +It is also the fact that few people seem interested by the project. Put besides some people who sent demonstrations to me which did not go, I received only malls to wonder to make function such or such plays or to ask me why moved is in French . +Thus I will not do something of useless and illegal. +For the site it would not obstruct me if there were not the bond on the left which does nothing but add to confusion on the goal of the project. +And for the sources it is the same problem as for the project. +good week end +yopyop +edit the law relates to the royalties and the rights close, not? + +Retrieved from "http://wiki.desmume.org/index.php?title=Faq" diff --git a/desmume/TODO b/TODO similarity index 100% rename from desmume/TODO rename to TODO diff --git a/desmume/autogen.sh b/autogen.sh old mode 100755 new mode 100644 similarity index 100% rename from desmume/autogen.sh rename to autogen.sh diff --git a/desmume/autopackage/default.apspec.in b/autopackage/default.apspec.in similarity index 100% rename from desmume/autopackage/default.apspec.in rename to autopackage/default.apspec.in diff --git a/desmume/compile b/compile old mode 100755 new mode 100644 similarity index 100% rename from desmume/compile rename to compile diff --git a/desmume/configure.ac b/configure.ac similarity index 83% rename from desmume/configure.ac rename to configure.ac index 096f31c2b..5d528a4ff 100644 --- a/desmume/configure.ac +++ b/configure.ac @@ -24,15 +24,6 @@ AC_PROG_RANLIB dnl -- check for endianess AC_C_BIGENDIAN -# took this from geany, hope it works -REVISION="r0" -SVN=`which svn 2>/dev/null` -if test -d ".svn" -a "x${SVN}" != "x" -a -x "${SVN}" ; then - REVISION=r`$SVN info|grep 'Last Changed Rev'|cut -d' ' -f4` -fi -AC_DEFINE_UNQUOTED([SVN_REV], "$REVISION", [subversion revision number]) - - dnl --- Other prerequisites --- dnl - Check for pkg-config macros m4_ifdef([PKG_PROG_PKG_CONFIG], [PKG_PROG_PKG_CONFIG]) @@ -88,8 +79,6 @@ if test "x$osmesa" = "xyes" ; then fi dnl - Check for GTK and/or libglade -FOUND_GLIB=no -HAVE_ALSA=no GLIB_VER=2.8 GTK_VER=2.6 AC_CHECK_TOOL(HAVE_PKG, pkg-config) @@ -97,8 +86,8 @@ AC_PROVIDE_IFELSE([PKG_PROG_PKG_CONFIG], [ if test ! "x$HAVE_PKG" = "x" ; then PKG_CHECK_MODULES(GLIB, glib-2.0 >= $GLIB_VER, - FOUND_GLIB=yes, - FOUND_GLIB=no) + HAVE_GLIB=yes, + HAVE_GLIB=no) PKG_CHECK_MODULES(GTK, gtk+-2.0 >= $GTK_VER, @@ -143,16 +132,6 @@ AC_PROVIDE_IFELSE([PKG_PROG_PKG_CONFIG], [ HAVE_LUA=no) AC_SUBST(LUA_CFLAGS) AC_SUBST(LUA_LIBS) - - PKG_CHECK_MODULES(ALSA, alsa >= 1.0, HAVE_ALSA=yes, HAVE_ALSA=no) - AC_SUBST(ALSA_CFLAGS) - AC_SUBST(ALSA_LIBS) - - PKG_CHECK_MODULES(LIBAGG, libagg >= 2.5.0, HAVE_LIBAGG=yes, HAVE_LIBAGG=no) - AC_SUBST(LIBAGG_CFLAGS) - AC_SUBST(LIBAGG_LIBS) - - AC_PATH_PROG(UPDATEDESKTOP, [update-desktop-database]) fi ],[ echo "WARNING: pkg-config is not available therefore gtk, gtk-glade UIs and lua scripting are not available either." @@ -161,21 +140,6 @@ AC_PROVIDE_IFELSE([PKG_PROG_PKG_CONFIG], [ dnl -- force lua disabled AM_CONDITIONAL([HAVE_LUA], [test "${HAVE_LUA}x" = "yes"]) -AM_CONDITIONAL([HAVE_ALSA], [test "${HAVE_ALSA}" = "yes"]) -if test "x$HAVE_ALSA" = "xno"; then - AC_DEFINE([FAKE_MIC]) -fi - -AM_CONDITIONAL([HAVE_LIBAGG], [test "${HAVE_LIBAGG}" = "yes"]) -if test "x$HAVE_LIBAGG" = "xyes"; then - AC_DEFINE([HAVE_LIBAGG]) -else - AC_MSG_ERROR([Antigrain library is required to build desmume]) -fi - -dnl - set conditional for glib, needed to avoid commandline.cpp compilation for cli frontend since it depends on glib -AM_CONDITIONAL([HAVE_GLIB], [test "${FOUND_GLIB}" = "yes"]) - dnl - If the gtkGLext package is available define the corresponding C macro if test "x$HAVE_GTKGLEXT" = "xyes"; then AC_DEFINE([GTKGLEXT_AVAILABLE], [1]) @@ -202,7 +166,7 @@ if test "x$HAVE_SDL" = "xyes"; then GETTEXT_PACKAGE=desmume AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE, "$GETTEXT_PACKAGE", [Define to the gettext package name]) AC_SUBST(GETTEXT_PACKAGE) - ALL_LINGUAS="fr pt_BR zh_CN" + ALL_LINGUAS="fr pt_BR" AM_GLIB_GNU_GETTEXT PO_DIR="po" PO_FILES="intltool-extract intltool-merge intltool-update" @@ -214,16 +178,6 @@ if test "x$HAVE_SDL" = "xyes"; then fi fi -dnl - wifi support -AC_ARG_ENABLE(wifi, - [AC_HELP_STRING(--enable-wifi, enable experimental wifi support)], - [ - AC_CHECK_LIB(pcap, main,[ - AC_DEFINE(EXPERIMENTAL_WIFI) - LIBS="$LIBS -lpcap" - ]) - ]) - dnl Set compiler library flags per target. case $target in *linux* | *bsd*) @@ -235,8 +189,6 @@ case $target in ;; *darwin*) LIBS="$LIBS -framework OpenGL" - dnl - extra hackery needed for X includes - AC_PATH_XTRA ;; esac @@ -275,8 +227,7 @@ if test "x[$]ENABLE_HARDCORE" = "x1"; then dnl - only valid for C with newer gcc's CPPFLAGS="[$]CPPFLAGS -Wmissing-prototypes" fi - dnl - -Wshadow - CPPFLAGS="[$]CPPFLAGS -Wall -Wextra -D_FORTIFY_SOURCE=2 -Wno-missing-field-initializers -Wpointer-arith -Wcast-align -Wwrite-strings -Wno-unused-parameter -Wmissing-declarations -Wundef -Wmissing-noreturn -Wredundant-decls -Wformat-nonliteral -Wformat-security -Winit-self" + CPPFLAGS="[$]CPPFLAGS -Wall -Wextra -D_FORTIFY_SOURCE=2 -Wno-missing-field-initializers -Wpointer-arith -Wcast-align -Wwrite-strings -Wno-unused-parameter -Wmissing-declarations -Wundef -Wmissing-noreturn -Wshadow -Wredundant-decls -Wformat-nonliteral -Wformat-security -Winit-self" fi dnl - Enable debug mode diff --git a/desmume/README.WIN b/desmume/README.WIN deleted file mode 100644 index 5b45f54f0..000000000 --- a/desmume/README.WIN +++ /dev/null @@ -1,672 +0,0 @@ -DeSmuME Manual for the Windows port -Contents - * 1 Quick Getting Started Guide - o 1.1 Menu Layout - + 1.1.1 File Menu - # 1.1.1.1 File | Open Rom - # 1.1.1.2 File | Recent Rom - # 1.1.1.3 File | Rom Info - # 1.1.1.4 File | Save State As... - # 1.1.1.5 File | Load State As... - # 1.1.1.6 File | Save State - # 1.1.1.7 File | Load State - # 1.1.1.8 File | Import Backup Memory - # 1.1.1.9 File | Export Backup Memory - # 1.1.1.10 File | Save Screenshot As... - # 1.1.1.11 File | Quick Screenshot - # 1.1.1.12 File | Record AVI - # 1.1.1.13 File | Stop AVI - # 1.1.1.14 File | Record WAV - # 1.1.1.15 File | Record Movie - # 1.1.1.16 File | Play Movie - # 1.1.1.17 File | Stop Movie - # 1.1.1.18 File | Quit - + 1.1.2 Emulation Menu - # 1.1.2.1 Emulation | Pause - # 1.1.2.2 Emulation | Reset - # 1.1.2.3 Emulation | Clear Sound - # 1.1.2.4 Emulation | GBA Slot - # 1.1.2.5 Emulation | Cheats - # 1.1.2.6 Emulation | Cheats | List - # 1.1.2.7 Emulation | Cheats | Search - + 1.1.3 View Menu - # 1.1.3.1 View | Rotation - # 1.1.3.2 View | Window size - # 1.1.3.3 View | Screen Separation - # 1.1.3.4 View | Force Maintain Ratio - # 1.1.3.5 View | Display Frame Counter - # 1.1.3.6 View | Display FPS - # 1.1.3.7 View | Display Input - # 1.1.3.8 View | Display Lag Counter - # 1.1.3.9 View | HUD Editing Mode - + 1.1.4 Config Menu - # 1.1.4.1 Config | Save Type - # 1.1.4.2 Config | 3D Settings - # 1.1.4.3 Config | Control Config - # 1.1.4.4 Config | Hotkey Config - # 1.1.4.5 Config | Sound Settings - # 1.1.4.6 Config | WIFI Settings - # 1.1.4.7 Config | Firmware Settings - # 1.1.4.8 Config | Emulation Settings - # 1.1.4.9 Config | Frame Skip - # 1.1.4.10 Config | Language - + 1.1.5 Tools Menu - # 1.1.5.1 Tools | Disassembler - # 1.1.5.2 Tools | View Memory - # 1.1.5.3 Tools | View Registers - # 1.1.5.4 Tools | View Palette - # 1.1.5.5 Tools | View Tiles - # 1.1.5.6 Tools | View Maps - # 1.1.5.7 Tools | View OAM - # 1.1.5.8 Tools | View Matrices - # 1.1.5.9 Tools | View Lights - # 1.1.5.10 Tools | View Sound State - # 1.1.5.11 View | RAM Watch - # 1.1.5.12 View | RAM Search - # 1.1.5.13 Tools | View Layers - + 1.1.6 Help Menu - # 1.1.6.1 Help | Website - # 1.1.6.2 Help | Forums - # 1.1.6.3 Help | Submit a bug report - # 1.1.6.4 Help | About - -Quick Getting Started Guide - -When you start the emulator for the first time, you probably just want to play a certain game. You can do this by going to 'File' in the menu, and selecting 'Open Rom'. This will open up an explorer window, within which you can browse to the rom (nds file) that you wish to play. Once the game has finished loading (and this should only take a few seconds at most), your game will automatically start running. But if you want, you can also compile from source. See the article Installing DeSmuME from source on Windows for details. -Menu Layout - -The rest of this manual will be spend on explaining all the other options in the menu. - - -File Menu -File | Open Rom - -This option is for loading games. A game is typically called a rom file. Just use the explorer window to browse to the file, and click on open. The game should just load and start. The desmume windows port is also able to load some compressed formats, like zip and gz. Just as long as there is a valid game (rom) file in the compressed archive ending with an .nds extension, it should load fine. -File | Recent Rom - -This menu option contains a list of the roms that you have most recently loaded. You can quickly access a game that way, without having browse to the right directory with the 'Open Rom' option. -File | Rom Info - -This option offers some information about the internals of the rom file, like name, code, manufacturer, and size. This should not concern the casual gamer, but may come in handy for developers. -File | Save State As... - -Imagine you have gotten to a certian point in a game, and you need to do something else. The emulator let's you save the current state of the game, so that you can continue the game later at precisely the same point somewhere in the future. - -Please note that the use of SAVESTATES is discouraged, as these are likely to break between emulator versions. Instead use SAVE FILES. These are likely to survive between emulator versions. This means that you will have to use save points within the game. SAVE FILES are stored in .sav files. -File | Load State As... - -Once you have saved a game's position, or 'state', you can load it again with this option. -File | Save State - -This option works fairly similair to the 'Save As' option, altough it let's you save numbers instead os specifying a chosen name. Also, All the states saved via this option end up with a pre-determined name of 'game (rom) name'.dsx. So if the game is called MyGame, the first savefile will be called MyGame.ds0, the second one MyGame.ds1, etc. -File | Load State - -This option let's you load the states that you saved via the 'File | Save State' option -File | Import Backup Memory - -Backup Memory is the data the game uses to remember its own state. It is stored on the cart in a normal game. Desmume uses the .dsv extension and file format; other formats which can be imported are .duc and raw .sav. People use pro action replays to capture duc files from their card and post it online without using emulators. These are frequently found on gamefaqs.com. See the faq for details on how to use this function, where it has been documented better. -File | Export Backup Memory - -This lets you export the game's state for use in other Nintendo DS Emulators. It will write a 'raw' sav file. -File | Save Screenshot As... - -This lets you take a screenshot of the current view of the emulator, and specify it's name to save as a bitmap (.bmp) file. -File | Quick Screenshot - -This option also dumps a screencapture, but it has a pre-determied filename and location. It will be called printscreen.bmp, and located in the current directory. In Windows, this is probably the same folder as where your desmume binary is located. -File | Record AVI - -This option lets you capture what's going on in the emulator, and save it in an avi file. -File | Stop AVI - -The 'Record AVI' option continues to record the game, untill you press the 'Stop Avi' option. -File | Record WAV - -This option lets you capture the sound played in the emulator, and save it in a wav file. -File | Record Movie - -This option lets you record the gameplay in TAS format, see http://tasvideos.org for details on TAS (tool-assisted speedruns). -File | Play Movie - -This option lets you playback a pre-recorded TAS movie. -File | Stop Movie - -This options lets you stop recording a TAS movie. -File | Quit - -Choosing this option exits the emulator. -Emulation Menu -Emulation | Pause - -This option will pause the emulation, freezing it at the current moment of execution. Selecting it again will resume the execution of the ROM at the exact moment where you paused it. -Emulation | Reset - -This option will reset the ROM that is currently loaded to the very start of the ROM, just as if you chose 'File | Open Rom' again. -Emulation | Clear Sound - -This option turns off all the sound. -Emulation | GBA Slot - -This menu option pop-ups a new window, which lets you specirfy what to do with the GBA slot of the Nintendo DS. It has the following choices : NONE, Compact Flash, Rumble Pack, GBA Game. Rumble pack allows some games to use vibration. Memory extension... Extends memory. And some DS games can have bonuses, unlockable by GBA cart. For example in Megaman ZX you can fight some Megaman Zero Bosses when correct cartridge is inserted. There are also other GBA slot extensions, like... a Guitar hero controller. But these are currently not emulated by desmume. Flash Cartridge is used for homebrew software emulation, for example that uses DLDI ( Dynamically Linked Device Interface). -Emulation | Cheats - -This option pulls down a drop-down menu, and presents the options list and search. Be aware though, that cheats are sort of half baked right now. If you are not having luck, wait for some news on an improved cheat system. Also, it is impossible yet to use "commercial" codes, such as Action Replay and Codebreaker, so what you'll have to do is manually search for, and alter the memory positions to your advantage. They are called 'raw' or 'internal' cheats. There's an excellent article in the wiki on Using Cheats in DeSmuMe . In post-0.9.2 development builds, there is also the support for Action Replay cheat codes. -Emulation | Cheats | List - -Choosing 'list' will list all the currently known cheats. Please refer to the article Using Cheats in DeSmuMe for further details on how to use the cheat mechanism in desmume. -Emulation | Cheats | Search - -Choosing 'search' will let you search for cheats. Please refer to the article Using Cheats in DeSmuMe for further details on how to use the cheat mechanism in desmume. -View Menu -View | Rotation - -This option will let you rotate the screen a pre-determined amount of degrees in order to adjust the angle of the display. Some programs require that you normally turn the DS on its side. You can set it up in that manner using this. The options are 0 (no rotation),90 ,180, and 270. -View | Window size - -This option will let you enlarge the windows a pre-determined size. The resize options are: 1x, 1.5x, 2x, 3x, and 4x the default size. You can also adjust the window size by clicking on the edge of the window, and dragging the mouse. -View | Screen Separation - -This option controls how far the two windows should be apart of each other, in other words: how big the border between them should be. Valid choices are: None (which is the default), narrow border (which is slightly larger), DS (which is about the wsame amount of room there is on a real Nintendo DS). -View | Force Maintain Ratio - -Here you can choose, when re-sizing the windows, if you wan to maintain the ratio of the windows. Sometimes when the window size is changed it doesn't look correct on the screen. This option forces the window to maintain a correct ratio so it looks correct. You can select or de-select this option. -View | Display Frame Counter - -Selecting this option causes a counter to run, that counts all the frames that have been displayed. -View | Display FPS - -Selecting this option causes the 'frames-per-second' (or 'fps', for short) to be displayed. It also displays an additional '3D' counter, which tells how frequently the game is updating its 3d graphics. But unlike the fps counter, the 3d counter has nothing to do with the power of your system. If it is low, then the game is running slow on a retail cart, and so it runs slow in an emulator. -View | Display Input - -Selecting this option displays the keys you press on the keyboard, which is the input -View | Display Lag Counter - -This option causes a counter to display that counts frames where the game doesn't poll input. -View | HUD Editing Mode - -This option will let you drag around hud elements to pick their position. -Config Menu -Config | Save Type - -This option lets you specify the save type of a particular game. The default is 'automatic'. However, this is not fail-safe in all cases, so you might need to manually select one of the other savetypes. -Config | 3D Settings - -This option lets you select the method that is used to draw the screen. You can choose between OpenGL (an open standard) or SoftRasterizer (a desmume specific method). - -Furthermore, you have two checkboxes that you can either enable or disable: - - * Unrealistically High-Precision Color Interpolation. Presently only effective for SoftRasterizer. - * Alternate Flush Mode. This fixes some games with flickering graphics. This is apllicable to both the OpenGl and the SoftRasterizer. - -Config | Control Config - -This option lets you configure keyboard keys or a joystick. The joystick support is implemented using a DirectInput control interface. - -Here are the default key mappings (they may be subject to change): - - Up arrow - Up - Left arrow - Left - Down arrow - Down - Right arrow - Right - x - A button - z - B button - s - X button - a - Y button - q - Left Trigger - w - Right Trigger - Enter - Start button - Right Shift - Select button - Backspace - Lid fold/unfold - - n - Frame advance - Space - Pause/Unpause - p - Load current state - 1,2,3,4,5,6,7,8,9,0 - Select current state - F1-F10 - Load relevant state - Shift+F1-F10 - Save relevant state - -Config | Hotkey Config - -This menu option lets you define keys, that can be used to quickly select other options without having to go through the entire menu structure. Some examples are a hotkey for 'pause', or a hotkey for loading a specific savestate. -Config | Sound Settings - -This option lets you choose between different sound generating methods, which currectly are 'Direct Sound Interface' and 'WAV Write sound Interface'. You can set the interpolation to choose between better quality and faster emulation. It also let's you specify the size of the buffer to buffer the sound. For performance improvements, you can turn on the sound option "ADPCM Caching". 'ADPCM' is a type of sound compression which is supposed to be fast to decode. This is new and experimental, and will break some things, but it should offer a substantial speedup in some cases. And lastly, you can also set the sound volume in this dialog. -Config | WIFI Settings - -WIFI support is currently under heavy development, but it is not useful yet. Therefore, you may find this option missing, or simply 'greyed-out' for now. Even if you can fiddle with it, it won't do anything useful. -Config | Firmware Settings - -This option provides you with the same set of options that a real Nintendo DS firmware does. The most important here is the language, because multi-lingual games will often look at how this option is set. -Config | Emulation Settings - -These options let you boot from the extracted BIOS and Firmware of a real Nintendo DS. unless you have extracted/downloaded the firmware or bios from a Nintendo DS that you actually own yourself, these settings have no value for you qas desmume does not require them to run correctly. -Config | Frame Skip - -This option lets you select how many frames should not be displayed, in order to gain speed improvements. The default is 'Auto'. If you have speed problems, you could decide to skip (not display) one or more frames in order to improve the speed. 'Limit Frameskip' let's you limit the frame rate to 60fps maximum. 60fps is essentially the speed that the game plays at on the actual console itself. So by selecting this option, you're limiting the framerate to the actual speed of the actual console. -Config | Language - -This lets you set the langguage the emulator displays it's menu's and options in. -Tools Menu -Tools | Disassembler - -This option displays the ARM9 and ARM7 disassembler. Be aware though, that the windows are drawn exactly on top of each other, so that you have to move (drag n drop) the first windows before the second window shows. -Tools | View Memory - -This tool displays the ARM7 and ARM9 memory. Be aware though, that the windows are drawn exactly on top of each other, so that you have to move (drag n drop) the first windows before the second window shows. - -The "View mode" radio buttons allow you to choose how the memory will be shown: - - * 8-bit : shows the memory as bytes - * 16-bit : shows the memory as words - * 32-bit : shows the memory as dwords - -The "View address" textbox and button allow you to jump to a different address: - - * Enter an hexadecimal address without 0x prefix, with up to 8 digits - * Click "Go" to jump to the entered address - -The "View dump" buttons allow you to dump the current view: - - * Text dump : dumps the view to a text file, in an human-readable form - * Raw dump : dumps the memory directly to a binary file which can be read with an hex editor - -Note that if you dump memory to a file already containing (a) dump(s), the new dump will be appended to the existing one(s). - -The scrollbar... well, you surely know how a scrollbar works. - -The viewers additionally allow to edit the memory. For it, click on the value you want to edit, then type the new value. The new value is applied only once you've entirely entered it. -Tools | View Registers - -This option lets you view the ARM7 and ARM9 I/O registers. -Tools | View Palette - -This option lets you view the palette in detail. -Tools | View Tiles - -This option lets you view the tiles in detail. -Tools | View Maps - -This option lets you view the maps in detail. -Tools | View OAM - -This option lets you view the OAM layer in detail. -Tools | View Matrices - -This option lets you view the matrices in detail. -Tools | View Lights - -This option lets you view the lights in detail. -Tools | View Sound State - -This option displays the sound output. -View | RAM Watch - -This option will pop-up a new window, with extensive and advanced features to watch the emulated RAM memory. -View | RAM Search - -This option will pop-up a new window, with extensive and advanced features to search through the emulated RAM memory. -Tools | View Layers - -This option lets you view the Layers one by one. - - -Help Menu -Help | Website - -This option directs your browser to the desmume homepage. -Help | Forums - -This option directs your browser to the desmume forums. -Help | Submit a bug report - -This option directs your browser to the SourceForge bugtracker for desmume. -Help | About - -This option displays the authors of the emulator. -Retrieved from "http://wiki.desmume.org/index.php?title=DeSmuME_Manual_for_the_Windows_port" -This page was last modified on 17 June 2009, at 04:59. - -==================================================================== - -DesMuMe Faq - -If the FAQ is unable to answer your question(s), then please make sure that you also consult the manual. -Contents - * 1 General Questions - o 1.1 What does desmume emulate and on what systems? - o 1.2 What does DeSmuME mean? - o 1.3 Under what license is desmume distributed ? - o 1.4 Can I freely copy desmume ? - o 1.5 Why doesn't my desmume play this game? - o 1.6 Why does this game fail to save? or, I get the error: "Data could not be accessed. Turn off the power and reinsert the DS card." - o 1.7 I get the error: "Unable to write data. Please turn off the power and reinsert the game card." - o 1.8 Why did you change the save file format and extension from .sav to .dsv ? - o 1.9 Can I use my save states across versions ? - o 1.10 Can I convert an ideas or no$gba nocash .sav savefile to desmume .dsv ? - o 1.11 Why can't I find a mac binary? - o 1.12 Why does my mac binary say something about being unsupported? - o 1.13 Where can I report bugs? - o 1.14 Can I attach files to bug reports I did not create myself ? - o 1.15 How do I get the latest svn code and build desmume myself? - o 1.16 Whats 'svn' ? - o 1.17 What compilers are supported for building desmume from source ? - o 1.18 Im Compiling using MSVC Express On Windows, and I get the error : "ml.exe" not found. - o 1.19 Im a developer, and would like to contribute to the codebase. What can I do ? - o 1.20 Im not a developer, but would like to help out anyway. What can I do ? - o 1.21 It is hard to zoom in on a widescreen display due to the weird aspect ratio of the DS. - o 1.22 Why doesn't my openGL 3d work in linux? - o 1.23 Why doesn't my openGL 3d work in windows? - o 1.24 Why doesn't a menu option or tool exist in my linux or mac build? - o 1.25 Why does music sound bad sometimes? - o 1.26 Why doesn't my game boot or progress into the main game engine? - o 1.27 What hardware features are emulated? - o 1.28 Does the GDB stub still work? - o 1.29 How do I enable the GDB stub on the Windows port ? - o 1.30 Where/what is IRC? - o 1.31 Where is the manual? - o 1.32 How do I enter 'cheat codes' in desmume ? - o 1.33 Why is the emulator slow? - o 1.34 What does the number/percentage in the desmume title bar mean ? - o 1.35 What's the difference between the the Windows 'desmume' and 'desmume_nosse' versions ? - o 1.36 Does desmume make use of multiple CPU's or multiple cores ? - o 1.37 What are the minimum hardware requirements for desmume ? - o 1.38 What are the recommended hardware requirements for desmume ? - o 1.39 Does desmume support wifi ? - o 1.40 Why do I get an assert in wifi.cpp which keeps me from playing a game? - o 1.41 OK, then why does it make my firewall alert since 0.9.2 ? - o 1.42 OK, so then why did my build come with winpcap.dll? Or why do I get crashes when I run desmume on vista which mumble something about winpcap? - o 1.43 What is WFC / WIFI Connection - o 1.44 Does desmume support the microphone ? - o 1.45 Where can I find technical details on the Nintendo DS and GBA ? - o 1.46 Does the 'GBA slot' option let me play GBA games ? - o 1.47 What is DLDI ? - o 1.48 How can I post a savefile or avi capture on the desmume forum ? - o 1.49 How can I post a large log or other text file on the desmume IRC chat room ? - o 1.50 My display is incorrect or corrupted - o 1.51 My display has flickering graphics in a certain game - o 1.52 How do I easily capture the ASM code for troubleshooting purposes ? - o 1.53 How do I make pokemon save? - o 1.54 I got a gameplay related question - o 1.55 What are the origins of DeSmuME ? - -General Questions - -What does desmume emulate and on what systems? -Desmume attempts to emulate, as faithfully as possible, the Nintendo DS and Nintendo DS Lite handheld game consoles (nds). It currently runs on Windows, Linux, and mac OSX. DSi is not supported. - -What does DeSmuME mean? -DeSmuME is a Nintendo DS emulator and the name is a play of words - DS Emu + ME (like FlashMe - firmware hack and PassMe mod-chip for DS) The name DeSmuME derives from the popular use of ME in Nintendo DS products by homebrew developers. So DeSmuME would equal DSemuMe. Other popular uses of ME include: - - * LoadMe - a generic patcher for commercial DS roms that works with any GBA Flash Card - * PassMe - "mod-chip" using which takes authentication from an original DS card an allows execution of unauthenticated DS rom code - from the GBA cartridge slot / GBA flash card. - * FlashMe - a hacked firmware for DS that allows you to start code in DS mode from a flash card in the GBA slot. - * WifiMe - are a set of a custom drivers and software by FireFly for RALink based wireless network cards enabling to boot homebrew code on DS via Nintendo Wireless Multiboot method. - -Its name is derived from emu which is short for emulator, DS and me. It's possibly supposed to mean "DS emulator for me". - -Under what license is desmume distributed ? -Desmume is distributed under the Gnu General Public License, or GPL: http://www.gnu.org/licenses/old-licenses/gpl-2.0.html - -Can I freely copy desmume ? -Yes you can, as long as you adhere to the license as specified in the GNU GPL. - -Why doesn't my desmume play this game? -Go to desmume.org and make sure you are using the latest version. The latest version is 0.9.3. Hint: desmume 0.8 and 0.3.4 are very old, being numbers smaller than the latest version. Older versions will not be supported, under any circumstances. - -Why does this game fail to save? or, I get the error: "Data could not be accessed. Turn off the power and reinsert the DS card." -Until version 0.9.3 desmume's save size autodetection was poor. With 0.9.3, autodetection should work almost all the time. In fact, here is the entire list of games we know of that fail to autodetect correctly: - - * Spider-Man 3 - -If you find any other game for which automatic savetype detection does not work, please let the developers know by posting on the forum or submitting a bug. If you want to fix it yourself, you may need to manually specify the correct save type for your game. Consult the manual for details on how to do this for your platform. You may also consult http://www.advanscene.com/ to easily identify the save type for your game. - -I get the error: "Unable to write data. Please turn off the power and reinsert the game card." -Same problem and resolution as the previous question. - -Why did you change the save file format and extension from .sav to .dsv ? -Because it is better now. These raw save files that everyone uses aren't good enough and were causing problems with autodetection. See our bug tracker or forum for more details; the dsv format has been documented in the svn source tree as dsv.txt and if you don't like the degree of interoperability with other emulators, then go tell the other emulators to support our format. - -Can I use my save states across versions ? -Maybe, maybe not. Due to constant internal changes in desmume, it is possible that a save state created with one version may not work with another version of desmume. Savestate compatibility is preserved wherever possible, but it is not always possible. Please note that for easily confused gamers, the use of SAVESTATES is discouraged, as these are likely to break between emulator versions. Instead use SAVE FILES. These are likely to survive between emulator versions. This means that you will have to use save points within the game. SAVE FILES are stored in .dsv files. Also, see this article for further details : Savefile or savestate - -Can I convert an ideas or no$gba nocash .sav savefile to desmume .dsv ? - -1. Convert the save file using http://shunyweb.info/convert.php ; the target format should be "Acekard RPG | EZFlash V | RAW Format [Autodetection] (.sav)" 2. Load the game. Let it get to the main menu 3. Select the correct backup size*, as specified by advanscene.com (which is not always right, by the way) 4. Use File > Import Backup Memory and pick the converted save file 5. Reset the game - - * Step 3 is not always necessary, if you are smart, however, it will never hurt to do it. - -Why can't I find a mac binary? -Maybe we haven't made it yet. There arent a lot of people willing to compile mac software. Just to be sure, go to https://sourceforge.net/project/showfiles.php?group_id=164579&package_id=186413 - -Why does my mac binary say something about being unsupported? -You have probably downloaded the i386 version of desmume for MAC, and are running on the PPC platform (or the other way around). Please verify if you're running on Intel (i386) hardware, or on PPC (G4, G5) hardware, and download the appropriate binary. - -Where can I report bugs? -In the official bug tracker. Feel free to post to the bug tracker as long as you are willing to take ownership of testing that bug and letting the developers know when it is resolved to your satisfaction. Just don't submit a bug report and run. You may also request features around the same location, too, but in the other trackers. - -Can I attach files to bug reports I did not create myself ? -SourceForge likes for folks to only respond on items they submit. If you see a ticket that represents something you are encountering, SourceForge doesn't necessarily want you commenting on that. The reasoning for this given by SourceForge is that they feel it is best to open your own ticket, which helps appreciate the extent of issues in many cases. The authors of desmume may or may not agree with this point of view from SourceForge. - -How do I get the latest svn code and build desmume myself? -Please check out the instructions related to your platform, over at Installing DeSmuME from source - -Whats 'svn' ? -svn is a developers tool. It's used to let multiple developers work on the same codebase without conflicts. If youre an end-user, don't worry about it. And if you're a developer, see the question on how to get the latest svn code and build desmume yourself. See wikipedia for more info -What compilers are supported for building desmume from source ? - - * At the moment, for Windows Microsoft Visual C++ 2005 and 2008 are the only supported compilers. Dev-c++ is not supported. Why won't you just download visual c++ express? - * For Linux, any recent version of GCC and toolchain should work. - -Im Compiling using MSVC Express On Windows, and I get the error : "ml.exe" not found. -ml.exe was not included in earlier downloads of MSVC++ 2008 Express Edition. Uninstall, redownload and install again. See http://connect.microsoft.com/VisualStudio/feedback/ViewFeedback.aspx?FeedbackID=326875 for details. ml.exe shoud be located in the "Microsoft Visual Studio 9.0\VC\bin" directory. - -Im a developer, and would like to contribute to the codebase. What can I do ? -To start you off in the right direction, the best thing you can do is join the developer team on IRC and discuss your intentions with the developers. - -Im not a developer, but would like to help out anyway. What can I do ? -The most helpful thing you can do is use desmume, learn its ins and outs, and learn how to compile svn builds. Then monitor it for regressions and report bugs. You can patrol the bug tracker for bugs which could use elucidation or which, based on your awareness of how the emulator is changing, might be fixed without us having specifically addressed the bug. Basically, be a super user. And hang out on irc. Also, adding to or perfecting the documentation in the wiki is useful. You could also watch for and answer questions placed on the desmume forum. - -It is hard to zoom in on a widescreen display due to the weird aspect ratio of the DS. -In fact it is hard to zoom in on a 4:3 screen, too. Proposals involve tearing apart windows and floating them side by side or separately or something. This may happen one day, in the form of side by side windows. - -Why doesn't my openGL 3d work in linux? -Blame nvidia and ati for putting out shoddy and/or closed source drivers. Then switch to software rasterizer. - -Why doesn't my openGL 3d work in windows? -You are probably using an ATI video card. ATI driver support of OpenGL is known to be poor. Get an nvidia. Do not argue with that, we are professional programmers and know what we're talking about. Or, switch to software rasterizer - -Why doesn't a menu option or tool exist in my linux or mac build? -Because making portable tools and platform harnesses are not our cup of tea and so a developer puts a feature into whichever ports he cares about. This policy is never going to change, although some features might migrate to other platforms over time. Better check the manual. - -Why does music sound bad sometimes? -Most DS music is sequenced music, loaded from the cart entirely when the level loads. This works fine. Your music that doesn't work is probably streaming music, which loads from the cart on the fly and goes straight to the speakers. This is much harder to emulate as it requires correct timing, which is not one of desmume's strengths right now. This may not be fixed for a while. - -Why doesn't my game boot or progress into the main game engine? -Desmume is not perfect yet. Some games may fail due to wifi emulation. Apparently if you search the web correctly you can find ways to patch games to work better on emulators. Your mileage may vary. If it really doesn't boot up, you can submit a bug report for the game on the sourceforge bugtracker. -What hardware features are emulated? - - * All known 2d graphics features are correct. Mosaics work but are imperfect. There may be small issues with colors as the correct color bit depths are not used at all points in the pipeline. - - * All 3d features are emulated, except for: tests, wireframes, edge marking, fog, and antialising. The opengl engine is near its limit and renders some things incorrectly. Eventually the software rasterizer (will support more features and be far more precise in the basic features. Both engines have trouble with some shadows, but software rasterizer is better. Software rasterizer has some noticeable texturing issues right now, especially in 2d games. Software rasterizer supports more correct lighting interpolation than opengl ever will (e.g. glitches at the edge of the screen while scrolling.) In software rasterizer, there are issues similar to 2d with incorrect bit depth being used in the pipeline. There are inaccurate edge conditions in each renderer; in opengl, textures tend to get overdrawn; in software rasterizer, edges of textures tend to be jittery. - -One last thing -- if buttons and labels and menus rendering on the 3d screen are obscured (for example, a button but no label is on it) then you may need to use the software rasterizer. Or you may need to use openGL instead. Each renderer has strengths and weaknesses, which is why both are provided. - - * All sound features are emulated. The microphone support is new and the manual should be consulted, where you will find out, among other things, that it is only supported in windows right now. - - * Wifi is not supported. It is currently under slow and incomplete development. Therefore, you may find this option missing, or simply 'greyed-out' for now. Also, since WIFI support does not work yet, don't ask any questions about it's functioning because it still is unfinished and does not work yet. - - * We are unaware of any outstanding issues in the core system hardware (cpu, dma, mmu) but there are certainly still some. The instruction and memory timings are quite incorrect; however, this seems not to hurt most softwares. - - * DLDI (does anybody know if this still works?) - -Dynamically Linked Driver Interface, commonly known as DLDI, is a driver framework that allows NDS and GBA homebrew to easily read and write to any number of different devices, just by substituting a driver file. - - * RTC (real-time clock) works; If it didnt, then the time in your games stays at 00:00:00, and your random number values always come up the same. - -Does the GDB stub still work? -It seems as if it works in 0.9.3, tested with the Insight GDB variant on windows with a recent devkitpro. This support has been compiled into the dev+ build. - -How do I enable the GDB stub on the Windows port ? -Add #define GDB_STUB to src/windows/userconfig/userconfig.h which you have created according to the instructions in src/windows/defaultconfig/userconfig.h ; sorry for this confusing system, but that's how it is for now. - -Where/what is IRC? -IRC is an on-line communication system. - -data you need: - - * server: irc.freenode.net - * port: 6667 - * channel: #desmume - -what to use: - - * mIRC - windows - * ChatZilla - FireFox add-on - * xchat - X - * plenty other, see wikipedia - -Where is the manual? -A manual for desmume is over at http://wiki.desmume.org/index.php?title=Manual. It may not have the information that other entries in this FAQ promised that it would. - -How do I enter 'cheat codes' in desmume ? -Action Replay and 'raw' or 'internal' cheats work as of 0.9.3. There are also cheat-finding facilities where you may manually search for and alter the memory positions which work to your advantage. There's an excellent article in the wiki on Using Cheats in DeSmuMe . - -Why is the emulator slow? -Because nobody pays us to work on it full time and it runs fast enough for us to be happy. Well, almost. - -0.9.3 May be a step backwards in some (or many) cases from 0.9.2 in terms of speed. The development between these versions focused on compatibility and bugfixes. Once we better understand how some things need to be emulated, then some speed can return. However, in order to mitigate some of this backsliding, we have introduced a few speed hacks which you may find helpful. - - * The cheapest way to get 60fps is to buy the cart. - * If you are in Windows, make sure you have tried the SSE build which helps a little bit. - * If you are using someone else's unofficial "svn" build it probably is not fully optimized since we make our Windows releases using some profiler-guided optimization which helps by several FPS. For all I know they are also carriers of viruses, and lately they tend to crash on vista. - * If you can handle it, turn off the sound. - * Use frame skip. Even frameskipping 1 will help and many games will stay playable. Frameskipping was improved in 0.9.3 to get more bang for the buck, but beware that dual screen 3d games may not work well under frameskip. - * (0.9.3+) In the sound options, set interpolation to none which should help a little bit. - * (0.9.3+) Turn on the sound option "ADPCM Caching"; this is new and experimental, and will break some things, but it should offer a substantial speedup in some cases. - * (0.9.3+) There is now the option of disabling an entire screen. (Tools > View Layers > Main GPU, etc) Consider disabling a screen which is useless in the game you are playing. - * Try the software rasterizer. In many cases, especially games which make only light use of the 3d hardware, this will actually run faster, by as many as 10 FPS. But it might also run slower, again, by as many as 10 FPS. - * Buying a newer, faster computer is somewhat more expensive, but it has other side benefits. - * A faster CPU is more helpful than a bleeding edge graphics card. Desmume is more CPU intensive than it is GPU intensive. It just needs a graphics card that is glitch-free, and currently the nvidia cards have a better track record. A newer graphics card has a slim possibility of increasing speed. - -What does the number/percentage in the desmume title bar mean ? - - * For the windows port, the percentage is the emulated arm9 CPU load average. The CPU in an actual Nintendo DS is an ARM9 CPU. The percentage shows us how busy the emulated CPU is. This number isnt really for you. We really ought to just take it out. - * For the Linux GTK and Glade ports, it's frames per second (fps). - -What's the difference between the the Windows 'desmume' and 'desmume_nosse' versions ? -desmume uses some SSE2 optimizations for 3D matrix calculations. If your CPU supports SSE2, better use this version. Otherwise use desmume_nosse. Any modern Intel CPU (AMD or intel) will support SSE2. - -Does desmume make use of multiple CPU's or multiple cores ? -Currently, there are no multi core optimizations. Everything runs in a single thread. You benefit MUCH more from a single greater Ghz cpu than from multiple cores or from multiple CPU's. -What are the minimum hardware requirements for desmume ? - -From a purely technical viewpoint, there are no minimum requirements. However, for 'real-world' playable speeds, you would need at least the following : - - * Windows OS: Windows XP or Vista - * Linux OS: Any recent Linux distribution with a 2.6 kernel. - * 2 GHz Processor - * 512 MB Available System Memory - * Available Hard Drive Space: A few MB for the emulator - * 128 MB 3D Video Card (Nvidia GeForce 6800 or better), ATI cards are not recommended. - * Optional: Sound Card, if you want sound support - * Optional: Microphone, if you wish to make use the Windows Microphone feature - -What are the recommended hardware requirements for desmume ? - -From a purely technical viewpoint, there are no recommended requirements. However, for 'real-world' playable speeds, the following gives you good performance: - - * Windows OS: Windows XP or Vista - * Linux OS: Any recent Linux distribution with a 2.6 kernel. - * 3 GHz Processor - * 1 GB Available System Memory - * Available Hard Drive Space: A few MB for desmume, 100MB or so for a bunch of savestates and savefiles. - * 512 MB 3D Video Card (Nvidia GeForce), ATI cards are not recommended. - * Sound Card. - * Microphone. - -In general, the more Ghz, the better. The faster memory, the better. Desmume currently won't benefit from multiple cores. Desmume currently is, unfortunately, slower than no$gba. -Does desmume support wifi ? - -Wifi is not supported. It is currently under slow and incomplete development. Therefore, you may find this option missing, or simply 'greyed-out' for now. Also, since WIFI support does not work yet, don't ask any questions about it's functioning because it still is unfinished and does not work yet. Furthermore, current development activities focus mainly on the Windows build. -Why do I get an assert in wifi.cpp which keeps me from playing a game? - -This was a glitch in 0.9.2 release. Why arent you using 0.9.3? -OK, then why does it make my firewall alert since 0.9.2 ? - -Your firewall is stupid, or winsock is stupid, (I am not sure which yet) for alerting just when winsock gets initialized. The emulator hasnt actually tried to connect to the internet yet. How could it? There isn't any wifi. All we are doing is some network initialization code. For those of you who are still not satisfied, then I will admit that there is actually some wifi code--but it doesnt actually do anything yet! Except alert your firewall. Sorry. Also, maybe that is actually a good, unobtrusive time for firewalls to alert. But I am not sorry for calling them stupid. They are hyperactive crybabies. -OK, so then why did my build come with winpcap.dll? Or why do I get crashes when I run desmume on vista which mumble something about winpcap? - -Because you are running an unofficial build, from dubious origins, made by unknown people. The desmume team cannot support builds it did not create itself. Therefore, you are advised to stop using unofficial builds, as you can expect no support from the desmume team or on the desmume forums. Only use builds you downloaded from the desmume website. -What is WFC / WIFI Connection - -See the article Nintendo wifi config utility -Does desmume support the microphone ? - -Yes, but only on the Windows port. You do have to have an actual microphone attached to your PC, though. And perhaps somewhat confusing, the Linux ports do report 'Microphone successfully initialized' on startup of the emulator - but currently this is just a piece of stub (dummy) code used only to correctly start the emulator. In 0.9.2 the microphone in windows really only works for noise, but this was fixed in 0.9.3; it still hasn't been tested very well. -Where can I find technical details on the Nintendo DS and GBA ? - -http://nocash.emubase.de/gbatek.htm -Does the 'GBA slot' option let me play GBA games ? - -No. A 'real' DS can use the gba slot to play gba games, but desmume does not emulate this. But a 'real' DS can also use the gba slot to access gba roms and sram so that ds games can import savefiles, and that part is emulated by desmume. (please note that this is reportedly buggy for some games, including pokemon) If you are looking for a Game Boy Advance (GBA) emulator, perhaps you can try mednafen or visualboy advance. -What is DLDI ? - -let me give you an overview on DLDI. You should know that there are many various flash cartridges for DS. They use different file allocation systems, different storage's, etc. They are used for launching homebrew. So to make one program run on all cards. You’d have to write support for each and every card so that it worked for everyone. But none needs support for other cards than their own. And then a genial solution was found. There was an universal IO unit made that’s just interface to IO operations. And compiled program does not know how to handle file system etc. And then user can append IO routines for his own card. “DLDI patch”. So, now when I have an M3 cart, I download rom, patch it with m3 DLDI patch, and it works on my cart. Say you had Supercard instead. You’d have to download very same rom and apply Supercart DLDI patch to it. DLDI patch is the same for all roms. So it’s easy for both developer and end user. -How can I post a savefile or avi capture on the desmume forum ? - -After you created it, you can upload it to a free external service provider like MediaFire (http://www.mediafire.com/), and then put the provided links to the page in the message you post on the forum. -How can I post a large log or other text file on the desmume IRC chat room ? - -Make use of the external service provider 'pastebin' (http://pastebin.com/), and post the url to it on the IRC channel. -My display is incorrect or corrupted - -Try switching the 3D Renderer from opengl or SoftRasterizer, or vice versa, to see if that resolves the bug. In windows, the default hotkey to do this quickly is numpad minus. -My display has flickering graphics in a certain game - -In the Windows port, you can choose 'Alternate Flush Mode' in the 'Config | 3D Settings' menu. This fixes some games with flickering graphics. -How do I easily capture the ASM code for troubleshooting purposes ? - -Savestate during the problem or just before your problem occurs, and #define WANTASMLISTING in armcpu.cpp. Recompile. Then redirect stdout to a file. I know it aint easy but its what we got for now. -How do I make pokemon save? -Use 0.9.3 where this works correctly without you having to perform rituals beyond your capabilities or comprehension. - -I got a gameplay related question -Please check a site like http://www.gamefaqs.com, and dont post gameplay related questions on the forum or IRC *unless* you believe there is a bug in the emulation of desmume. - -What are the origins of DeSmuME ? -DeSmuME is a freeware emulator for the Nintendo DS originally created by YopYop156. The original website was http://yopyop156.ifrance.com - -Due to change in French laws regarding emulation YopYop decided to stop development of DeSmuME. However, he released the source under the GPL, and other programmers have picked it up and kept it under active development. - -Yopyop said: - - It’s release under GPL. I have just removed the new 3D engine because it’s too much bugged. Hopefully it will be helpful for some of you. - - -The latest statement heard from yopyop was : - - DeSmuMe project is over. - You may don’t know but there are a new law in France that could put me in big trouble. - With DeSmuMe, I have closed the doors of game company but I can not offer to pay for it. - - The worst thing is that I have found the bad coded instructions. - For those how have download the sources you have to look in sbc, rsbc instructions the Carry flag updating is wrong. - Sorry for the home brew programmers. - - For the illegality the demonstration seemed to me convincing thus without proof clarify I prefer to stick to this decision. - - It is also the fact that few people seem interested by the project. Put besides some people who sent demonstrations to me which did not go, I received only malls to wonder to make function such or such plays or to ask me why moved is in French . - Thus I will not do something of useless and illegal. - - For the site it would not obstruct me if there were not the bond on the left which does nothing but add to confusion on the goal of the project. - - And for the sources it is the same problem as for the project. - - good week end - - yopyop - - edit the law relates to the royalties and the rights close, not? - -Retrieved from "http://wiki.desmume.org/index.php?title=Faq_093" -This page was last modified on 17 June 2009, at 04:30. diff --git a/desmume/dsv.txt b/desmume/dsv.txt deleted file mode 100644 index 2f5b63b8f..000000000 --- a/desmume/dsv.txt +++ /dev/null @@ -1,39 +0,0 @@ -The desmume save file format is merely a raw save file with a FOOTER. - -This was chosen in order to maximize compatibility with other emulators, -which tend load the savefile as-is and let the game read out of whatever range -it is expecting. To assist with this, before writing the save file, desmume -will pad the raw save file out to the next highest known length. Note that this -may sometimes be incorrect if the savefile hasnt been written through to the end -during initialization. This could cause other emulators to fail to recognize the -save file. - -Additionally, the footer makes it easier to analyze save files, because the -game's data will be at the correct addresses starting at offset 0x0000. - -The footer format can be identified by locating the 16Byte ascii string -"|-DESMUME SAVE-|" -at the end of the file. This corresponds with the following save structure: - -struct Footer { - u32 actually_written_size; - u32 padded_size; - u32 save_type; //(not currently used) - u32 address_size; //address bus size - u32 save_size; //size parameter of the save type (not currently used) - u32 version_number; //should be 0 - char cookie[16]; -}; - -note that padded_size should be where you see the end of the raw save data -and the beginning of desmume-specific information, including some junk before -the actual footer. - -actually_written_size is the highest address (plus one) written to by the game. - -The new desmume savefile system tries to make as few decisions as possible, -which is the reason for the behavior of actually_written_size and the disuse -of save_type and save_size. If few decisions are made, then few mistakes can -be made. That is the idea, anyway. We'll make decisions later if we need to. -save_type and save_size are reserved in case we do. - diff --git a/desmume/po/zh_CN.po b/desmume/po/zh_CN.po deleted file mode 100644 index 064797979..000000000 --- a/desmume/po/zh_CN.po +++ /dev/null @@ -1,265 +0,0 @@ -# French translation for the desmume windows UI. -# Copyright (C) 2009 The DeSmuME Team. -# F.E.Nebula, 2009. -# -msgid "" -msgstr "" -"Project-Id-Version: PACKAGE VERSION\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2007-07-17 01:38-0400\n" -"PO-Revision-Date: 2009-06-24 11:00+0800\n" -"Last-Translator: F.E.Nebula \n" -"Language-Team: DeSmuME Team \n" -"MIME-Version: 1.0\n" -"Content-Type: text/plain; charset=utf-8\n" -"Content-Transfer-Encoding: 8bit\n" -"X-Poedit-Language: Chinese\n" -"X-Poedit-Country: CHINA\n" - -#: File menu -#, c-format -msgid "File" -msgstr "文件" - -msgid "Open ROM..." -msgstr "打开ROM..." - -msgid "Recent ROM" -msgstr "最近的ROM" - -msgid "None" -msgstr "空" - -msgid "Clear" -msgstr "清空" - -msgid "ROM info" -msgstr "ROMä¿¡æ¯" - -msgid "Save state as..." -msgstr "å³æ—¶å­˜æ¡£ä¸º..." - -msgid "Load state as..." -msgstr "å³æ—¶è¯»æ¡£ä¸º..." - -msgid "Save state" -msgstr "å³æ—¶å­˜æ¡£" - -msgid "Load state" -msgstr "å³æ—¶è¯»æ¡£" - -msgid "Import backup memory" -msgstr "导入åŽå¤‡å†…å­˜" - -msgid "Save screenshot as..." -msgstr "å¦å­˜å±å¹•æˆªå›¾ä¸º" - -msgid "Quick screenshot" -msgstr "快速截图" - -msgid "Record AVI" -msgstr "录制AVI" - -msgid "Stop AVI" -msgstr "åœæ­¢å½•åˆ¶AVI" - -msgid "Quit" -msgstr "退出" - -#: Emulation menu -msgid "Emulation" -msgstr "模拟" - -msgid "Pause" -msgstr "æš‚åœ" - -msgid "Reset" -msgstr "å¤ä½" - -msgid "Shut up" -msgstr "é™éŸ³" - -msgid "GBA slot" -msgstr "GBAæ’槽" - -msgid "Cheats" -msgstr "金手指" - -msgid "List" -msgstr "列表" - -msgid "Search" -msgstr "æœç´¢" - -#: View menu -msgid "View" -msgstr "查看" - -msgid "Rotation" -msgstr "旋转" - -msgid "Window size" -msgstr "窗å£å¤§å°" - -msgid "Screen separation" -msgstr "分割窗å£" - -msgid "None\t(0 px)" -msgstr "æ— \t(0 px)" - -msgid "Narrow border\t(5 px)" -msgstr "窄线\t(5 px)" - -msgid "DS\t(64 px)" -msgstr "DS实际宽度\t(64 px)" - -msgid "Force maintain ratio" -msgstr "强制ä¿æŒæ¯”例" - -msgid "Default size" -msgstr "默认大å°" - -msgid "Display frame counter" -msgstr "显示帧计数器" - -msgid "Display FPS" -msgstr "显示FPS" - -msgid "Display input" -msgstr "显示输入" - -msgid "Display lag counter" -msgstr "显示标志计数器" - -#: Config menu -msgid "Config" -msgstr "设置" - -msgid "Save type" -msgstr "存档类型" - -msgid "Autodetect" -msgstr "自动选择" - -msgid "EEPROM 4kbit" -msgstr "" - -msgid "EEPROM 64kbit" -msgstr "" - -msgid "EEPROM 512kbit" -msgstr "" - -msgid "FRAM 256kbit" -msgstr "" - -msgid "FLASH 2mbit" -msgstr "" - -msgid "FLASH 4mbit" -msgstr "" - -msgid "3D settings" -msgstr "3D设置" - -msgid "Control config" -msgstr "控制器设置" - -msgid "Hotkey config" -msgstr "热键设置" - -msgid "Sound settings" -msgstr "声音设置" - -msgid "Wifi settings" -msgstr "Wifi设置" - -msgid "Firmware settings" -msgstr "固件设置" - -msgid "Emulation settings" -msgstr "模拟选项设置" - -msgid "Frameskip" -msgstr "跳帧" - -msgid "Limit framerate" -msgstr "é™åˆ¶å¸§çŽ‡" - -msgid "Auto" -msgstr "自动" - -msgid "Language" -msgstr "语言" - -#: Tools menu -msgid "Disassembler" -msgstr "å汇编" - -msgid "View memory" -msgstr "查看内存" - -msgid "View registers" -msgstr "查看寄存器" - -msgid "View palettes" -msgstr "查看调色æ¿" - -msgid "View tiles" -msgstr "查看Tile" - -msgid "View maps" -msgstr "查看映射" - -msgid "View OAMs" -msgstr "产看OAM" - -msgid "View matrices" -msgstr "查看矩阵" - -msgid "View lights" -msgstr "查看光照" - -msgid "View layers" -msgstr "查看图层" - -msgid "Main BG 0" -msgstr "" - -msgid "Main BG 1" -msgstr "" - -msgid "Main BG 2" -msgstr "" - -msgid "Main BG 3" -msgstr "" - -msgid "Sub BG 0" -msgstr "" - -msgid "Sub BG 1" -msgstr "" - -msgid "Sub BG 2" -msgstr "" - -msgid "Sub BG 3" -msgstr "" - -#: Help menu -msgid "Help" -msgstr "帮助" - -msgid "Website" -msgstr "主页" - -msgid "Forums" -msgstr "论å›" - -msgid "Submit a bug report" -msgstr "æ交BUG报告" - -msgid "About" -msgstr "关于" - diff --git a/desmume/src/GPU_osd.cpp b/desmume/src/GPU_osd.cpp deleted file mode 100644 index a92f4fd1c..000000000 --- a/desmume/src/GPU_osd.cpp +++ /dev/null @@ -1,429 +0,0 @@ -/* Copyright (C) 2006 yopyop - yopyop156@ifrance.com - yopyop156.ifrance.com - - Copyright (C) 2006-2008 DeSmuME team - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#include "GPU_osd.h" -#include "GPU.h" -#include "mem.h" -#include //mem funcs -#include //va_start, etc -#include -#include -#include "debug.h" - -#include "aggdraw.h" -#include "movie.h" -#include "NDSSystem.h" -#include "mic.h" -#include "saves.h" - - -OSDCLASS *osd = NULL; -HudStruct Hud; - -static void SetHudDummy (HudCoordinates *hud) -{ - hud->x=666; - hud->y=666; -} - -static bool IsHudDummy (HudCoordinates *hud) -{ - return (hud->x == 666 && hud->y == 666); -} - -void EditHud(s32 x, s32 y, HudStruct *hudstruct) { - - u32 i = 0; - - while (!IsHudDummy(&hudstruct->hud(i))) { - HudCoordinates &hud = hudstruct->hud(i); - - //reset - if(!hud.clicked) { - hud.storedx=0; - hud.storedy=0; - } - - if((x >= hud.x && x <= hud.x + hud.xsize) && - (y >= hud.y && y <= hud.y + hud.ysize) && !hud.clicked ) { - - hud.clicked=1; - hud.storedx = x - hud.x; - hud.storedy = y - hud.y; - } - - if(hud.clicked) { - hud.x = x - hud.storedx; - hud.y = y - hud.storedy; - } - - //sanity checks - if(hud.x < 0) hud.x = 0; - if(hud.y < 0) hud.y = 0; - if(hud.x > 245)hud.x = 245; //margins - if(hud.y > 180)hud.y = 180; - - if(hud.clicked) - break;//prevent items from grouping together - - i++; - } -} - -void HudClickRelease(HudStruct *hudstruct) { - - u32 i = 0; - - while (!IsHudDummy(&hudstruct->hud(i))) { - HudCoordinates &hud = hudstruct->hud(i); - hud.clicked=0; - i++; - } -} - -void ResetHud(HudStruct *hudstruct) { - - hudstruct->FpsDisplay.x=0; - hudstruct->FpsDisplay.y=5; - hudstruct->FpsDisplay.xsize=120; - hudstruct->FpsDisplay.ysize=10; - - hudstruct->FrameCounter.x=0; - hudstruct->FrameCounter.y=25; - hudstruct->FrameCounter.xsize=60; - hudstruct->FrameCounter.ysize=10; - - hudstruct->InputDisplay.x=0; - hudstruct->InputDisplay.y=45; - hudstruct->InputDisplay.xsize=120; - hudstruct->InputDisplay.ysize=10; - - hudstruct->LagFrameCounter.x=0; - hudstruct->LagFrameCounter.y=65; - hudstruct->LagFrameCounter.xsize=30; - hudstruct->LagFrameCounter.ysize=10; - - hudstruct->Microphone.x=0; - hudstruct->Microphone.y=85; - hudstruct->Microphone.xsize=20; - hudstruct->Microphone.ysize=10; - - SetHudDummy(&hudstruct->Dummy); -} - - -struct TouchInfo{ - u16 X; - u16 Y; -}; -static int touchalpha[8]= {31, 63, 95, 127, 159, 191, 223, 255}; -static TouchInfo temptouch; -bool touchshadow = true; -static std::vector touch (8); - - -static void TouchDisplay() { - aggDraw.hud->lineWidth(1.0); - - temptouch.X = nds.touchX >> 4; - temptouch.Y = nds.touchY >> 4; - touch.push_back(temptouch); - - if(touch.size() > 8) touch.erase(touch.begin()); - - if(touchshadow) { - for (int i = 0; i < 8; i++) { - temptouch = touch[i]; - if(temptouch.X != 0 || temptouch.Y != 0) { - aggDraw.hud->lineColor(0, 255, 0, touchalpha[i]); - aggDraw.hud->line(temptouch.X - 256, temptouch.Y + 192, temptouch.X + 256, temptouch.Y + 192); //horiz - aggDraw.hud->line(temptouch.X, temptouch.Y - 256, temptouch.X, temptouch.Y + 384); //vert - aggDraw.hud->fillColor(0, 0, 0, touchalpha[i]); - aggDraw.hud->rectangle(temptouch.X-1, temptouch.Y-1 + 192, temptouch.X+1, temptouch.Y+1 + 192); - } - } - } - else - if(nds.isTouch) { - aggDraw.hud->line(temptouch.X - 256, temptouch.Y + 192, temptouch.X + 256, temptouch.Y + 192); //horiz - aggDraw.hud->line(temptouch.X, temptouch.Y - 256, temptouch.X, temptouch.Y + 384); //vert - } -} - -static int yheight; -static int xpos; -static int previousslot = 0; -static int fadecounter; -static char number[10]; - -static void DrawStateSlots(){ - - aggDraw.hud->lineWidth(1.0); - aggDraw.hud->lineColor(0, 0, 0, fadecounter); - aggDraw.hud->fillColor(255, 255, 255, fadecounter); - - for ( int i = 0; i < 10; xpos=xpos+24) { - - aggDraw.hud->fillLinearGradient(8 + xpos, 160 - yheight, 30 + xpos, 180 + yheight+20, agg::rgba8(100,200,255,fadecounter), agg::rgba8(255,255,255,0)); - - if(lastSaveState == i) { - yheight = 5; - aggDraw.hud->fillLinearGradient(8 + xpos, 160 - yheight, 30 + xpos, 180 + yheight+20, agg::rgba8(100,255,255,fadecounter), agg::rgba8(255,255,255,0)); - } - - aggDraw.hud->rectangle(8 + xpos , 160 - yheight, 30 + xpos , 180 + yheight); - snprintf(number, 10, "%d", i); - aggDraw.hud->renderText(9 + xpos + 4, 164, std::string(number)); - i++; - yheight=0; - } - - if(lastSaveState != previousslot) fadecounter = 256; - previousslot = lastSaveState; - fadecounter--; - - if(fadecounter < 1) fadecounter = 0; - - xpos = 0; -} -#ifdef WIN32 -#include "lua-engine.h" -#endif -void DrawHUD() -{ - if (CommonSettings.hud.ShowInputDisplay) - { - std::stringstream ss; - if(nds.isTouch) - ss << (nds.touchX >> 4) << " " << (nds.touchY >> 4); - osd->addFixed(Hud.InputDisplay.x, Hud.InputDisplay.y, "%s",(InputDisplayString += ss.str()).c_str()); - TouchDisplay(); - } - - if (CommonSettings.hud.FpsDisplay) - { - osd->addFixed(Hud.FpsDisplay.x, Hud.FpsDisplay.y, "Fps:%02d/%02d", Hud.fps, Hud.fps3d); - } - - if (CommonSettings.hud.FrameCounterDisplay) - { - if (movieMode == MOVIEMODE_PLAY) - osd->addFixed(Hud.FrameCounter.x, Hud.FrameCounter.y, "%d/%d",currFrameCounter,currMovieData.records.size()); - else if(movieMode == MOVIEMODE_RECORD) - osd->addFixed(Hud.FrameCounter.x, Hud.FrameCounter.y, "%d",currFrameCounter); - else - osd->addFixed(Hud.FrameCounter.x, Hud.FrameCounter.y, "%d (no movie)",currFrameCounter); - } - - if (CommonSettings.hud.ShowLagFrameCounter) - { - osd->addFixed(Hud.LagFrameCounter.x, Hud.LagFrameCounter.y, "%d",TotalLagFrames); - } - - #ifdef WIN32 - if (CommonSettings.hud.ShowMicrophone) - { - osd->addFixed(Hud.Microphone.x, Hud.Microphone.y, "%d",MicDisplay); - } - #endif -#ifdef WIN32 - CallRegisteredLuaFunctions(LUACALL_AFTEREMULATIONGUI); -#endif - DrawStateSlots(); -} - - - -OSDCLASS::OSDCLASS(u8 core) -{ - memset(name,0,7); - - mode=core; - offset=0; - - lastLineText=0; - lineText_x = 5; - lineText_y = 120; - lineText_color = AggColor(255, 255, 255); - for (int i=0; i < OSD_MAX_LINES+1; i++) - { - lineText[i] = new char[1024]; - memset(lineText[i], 0, 1024); - lineTimer[i] = 0; - lineColor[i] = lineText_color; - } - - rotAngle = 0; - - needUpdate = false; - - if (core==0) - strcpy(name,"Core A"); - else - if (core==1) - strcpy(name,"Core B"); - else - { - strcpy(name,"Main"); - mode=255; - } - - //border(false); - - LOG("OSD_Init (%s)\n",name); -} - -OSDCLASS::~OSDCLASS() -{ - LOG("OSD_Deinit (%s)\n",name); - - for (int i=0; i < OSD_MAX_LINES+1; i++) - { - if (lineText[i]) - delete [] lineText[i]; - lineText[i] = NULL; - } -} - -void OSDCLASS::setOffset(u16 ofs) -{ - offset=ofs; -} - -void OSDCLASS::setRotate(u16 angle) -{ - rotAngle = angle; -} - -void OSDCLASS::clear() -{ - needUpdate=false; -} - -bool OSDCLASS::checkTimers() -{ - if (lastLineText == 0) return false; - - time_t tmp_time = time(NULL); - - for (int i=0; i < lastLineText; i++) - { - if (tmp_time > (lineTimer[i] + OSD_TIMER_SECS) ) - { - if (i < lastLineText) - { - for (int j=i; j < lastLineText; j++) - { - strcpy(lineText[j], lineText[j+1]); - lineTimer[j] = lineTimer[j+1]; - lineColor[j] = lineColor[j+1]; - } - } - lineTimer[lastLineText] = 0; - lastLineText--; - if (lastLineText == 0) return false; - } - } - return true; -} - -void OSDCLASS::update() -{ - if ( (!needUpdate) && (!lastLineText) ) return; // don't update if buffer empty (speed up) - if (lastLineText) - { - if (checkTimers()) - { - for (int i=0; i < lastLineText; i++) - { - aggDraw.hud->lineColor(lineColor[i]); - aggDraw.hud->renderTextDropshadowed(lineText_x,lineText_y+(i*16),lineText[i]); - } - } - else - { - if (!needUpdate) return; - } - } -} - -void OSDCLASS::setListCoord(u16 x, u16 y) -{ - lineText_x = x; - lineText_y = y; -} - -void OSDCLASS::setLineColor(u8 r=255, u8 b=255, u8 g=255) -{ - lineText_color = AggColor(r,g,b); -} - -void OSDCLASS::addLine(const char *fmt, ...) -{ - va_list list; - - if (lastLineText > OSD_MAX_LINES) lastLineText = OSD_MAX_LINES; - if (lastLineText == OSD_MAX_LINES) // full - { - lastLineText--; - for (int j=0; j < lastLineText; j++) - { - strcpy(lineText[j], lineText[j+1]); - lineTimer[j] = lineTimer[j+1]; - lineColor[j] = lineColor[j+1]; - } - } - - va_start(list,fmt); -#if defined(_MSC_VER) || defined(__INTEL_COMPILER) - _vsnprintf(lineText[lastLineText],1023,fmt,list); -#else - vsnprintf(lineText[lastLineText],1023,fmt,list); -#endif - va_end(list); - lineColor[lastLineText] = lineText_color; - lineTimer[lastLineText] = time(NULL); - needUpdate = true; - - lastLineText++; -} - -void OSDCLASS::addFixed(u16 x, u16 y, const char *fmt, ...) -{ - va_list list; - char msg[1024]; - - va_start(list,fmt); - vsnprintf(msg,1023,fmt,list); - va_end(list); - - aggDraw.hud->lineColor(255,255,255); - aggDraw.hud->renderTextDropshadowed(x,y,msg); - - needUpdate = true; -} - -void OSDCLASS::border(bool enabled) -{ - //render51.setTextBoxBorder(enabled); -} diff --git a/desmume/src/PACKED_END.h b/desmume/src/PACKED_END.h deleted file mode 100644 index 4c0798dd0..000000000 --- a/desmume/src/PACKED_END.h +++ /dev/null @@ -1,3 +0,0 @@ -#ifndef __GNUC__ -#pragma pack(pop) -#endif diff --git a/desmume/src/addons/guitarGrip.cpp b/desmume/src/addons/guitarGrip.cpp deleted file mode 100644 index be629e46d..000000000 --- a/desmume/src/addons/guitarGrip.cpp +++ /dev/null @@ -1,79 +0,0 @@ -/* Copyright (C) 2006 yopyop - yopyop156@ifrance.com - yopyop156.ifrance.com - - Copyright (C) 2009 CrazyMax - Copyright (C) 2009 DeSmuME team - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -*/ - -#include "../addons.h" -#include - -static u8 guitarKeyStatus = 0; - -static BOOL guitarGrip_init(void) { return (TRUE); } -static void guitarGrip_reset(void) -{ - //INFO("GuitarGrip: Reset\n"); - guitarKeyStatus = 0; -} -static void guitarGrip_close(void) {} -static void guitarGrip_config(void) {} -static void guitarGrip_write08(u32 adr, u8 val) {} -static void guitarGrip_write16(u32 adr, u16 val) {} -static void guitarGrip_write32(u32 adr, u32 val) {} -static u8 guitarGrip_read08(u32 adr) -{ - //INFO("GuitarGrip: read 08 at 0x%08X\n", adr); - if (adr == 0x0A000000) return (~guitarKeyStatus); - return (0x0); -} -static u16 guitarGrip_read16(u32 adr) -{ - //INFO("GuitarGrip: read 16 at 0x%08X\n", adr); - if (adr == 0x080000BE) return (0xF9FF); - if (adr == 0x0801FFFE) return (0xF9FF); - - return (0); -} -static u32 guitarGrip_read32(u32 adr) -{ - //INFO("GuitarGrip: read 32 at 0x%08X\n", adr); - return (0); -} -static void guitarGrip_info(char *info) { strcpy(info, "Guitar Grip for Guitar Hero games"); } - -void guitarGrip_setKey(bool green, bool red, bool yellow, bool blue) -{ - guitarKeyStatus = 0 | (green << 6) | (red << 5) | (yellow << 4) | (blue << 3); -} - -ADDONINTERFACE addonGuitarGrip = { - "Guitar Grip", - guitarGrip_init, - guitarGrip_reset, - guitarGrip_close, - guitarGrip_config, - guitarGrip_write08, - guitarGrip_write16, - guitarGrip_write32, - guitarGrip_read08, - guitarGrip_read16, - guitarGrip_read32, - guitarGrip_info}; diff --git a/desmume/src/agg2d.h b/desmume/src/agg2d.h deleted file mode 100644 index 24c89b6d5..000000000 --- a/desmume/src/agg2d.h +++ /dev/null @@ -1,929 +0,0 @@ -//---------------------------------------------------------------------------- -// Agg2D - Version 1.0 -// Based on Anti-Grain Geometry -// Copyright (C) 2005 Maxim Shemanarev (http://www.antigrain.com) -// -// Permission to copy, use, modify, sell and distribute this software -// is granted provided this copyright notice appears in all copies. -// This software is provided "as is" without express or implied -// warranty, and with no claim as to its suitability for any purpose. -// -//---------------------------------------------------------------------------- -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://www.antigrain.com -//---------------------------------------------------------------------------- -//---------------------------------------------------------------------------- -// -// 25 Jan 2007 - Ported to AGG 2.4 Jerry Evans (jerry@novadsp.com) -// 11 Jul 2009 - significant refactors for introduction to desmume -// -//---------------------------------------------------------------------------- - -#ifndef AGG2D_INCLUDED -#define AGG2D_INCLUDED - -//we're not using vector fonts right now. -//#define AGG2D_USE_VECTORFONTS - -#ifdef AGG2D_USE_VECTORFONTS -#if defined(UNDER_CE) || not defined(WIN32) -#define AGG2D_USE_FREETYPE -#endif -#endif - -#pragma warning(disable: 4786) - -// JME -#include "agg_basics.h" -#include "agg_math_stroke.h" -#include "agg_trans_affine.h" -#include "agg_trans_viewport.h" -#include "agg_path_storage.h" -#include "agg_conv_stroke.h" -#include "agg_conv_transform.h" -#include "agg_conv_curve.h" -#include "agg_rendering_buffer.h" -#include "agg_renderer_base.h" -#include "agg_renderer_scanline.h" -#include "agg_span_gradient.h" -#include "agg_span_image_filter_rgba.h" - -//+ JME -#include "agg_span_allocator.h" -#include "agg_span_converter.h" -#include "agg_span_interpolator_linear.h" -#include "agg_rasterizer_scanline_aa.h" -#include "agg_gamma_functions.h" -#include "agg_scanline_u.h" -#include "agg_bezier_arc.h" -#include "agg_rounded_rect.h" -#include "agg_font_cache_manager.h" - -#include "agg_glyph_raster_bin.h" -#include "agg_renderer_raster_text.h" -#include "agg_embedded_raster_fonts.h" - - -#include - -#ifdef AGG2D_USE_VECTORFONTS -#ifdef AGG2D_USE_FREETYPE -#ifndef WIN32 -#include "agg_font_freetype.h" -#else -#include "../font_freetype/agg_font_freetype.h" -#endif -#else -#include "../font_win32_tt/agg_font_win32_tt.h" -#endif -#endif - -#include "agg_pixfmt_rgba.h" -//+ JME -#include "agg_image_accessors.h" - -#define AGG2D_TEMPLATE template -#define AGG2D_TEMPLATE_WITH_IMAGE template -#define AGG2D_TEMPLATE_ARG -#define AGG2D_IMAGE_TEMPLATE template -#define AGG2D_IMAGE_TEMPLATE_ARG -#define TIMAGE Agg2DBase :: Image AGG2D_IMAGE_TEMPLATE_ARG - - -template -class PixFormatSetDeclaration -{ -public: - typedef Main PixFormat; - typedef Pre PixFormatPre; -}; - -class Agg2DBase -{ -public: - // JME - //typedef agg::rect Rect; - typedef agg::rect_i Rect; - typedef agg::rect_d RectD; - typedef agg::trans_affine Affine; - - enum LineJoin - { - JOIN_MITER = agg::miter_join, - JOIN_ROUND = agg::round_join, - JOIN_BEVEL = agg::bevel_join - }; - - enum LineCap - { - CAP_BUTT = agg::butt_cap, - CAP_SQUARE = agg::square_cap, - CAP_ROUND = agg::round_cap - }; - - enum TextAlignment - { - AlignLeft, - AlignRight, - AlignCenter, - AlignBaseline, - AlignTop = AlignRight, - AlignBottom = AlignLeft - }; - - - enum DrawPathFlag - { - FillOnly, - StrokeOnly, - FillAndStroke, - FillWithLineColor - }; - - enum ViewportOption - { - Anisotropic, - XMinYMin, - XMidYMin, - XMaxYMin, - XMinYMid, - XMidYMid, - XMaxYMid, - XMinYMax, - XMidYMax, - XMaxYMax - }; - - enum WindowFitLogic - { - WindowFitLogic_meet, - WindowFitLogic_slice - }; - - struct Transformations - { - double affineMatrix[6]; - }; - - AGG2D_IMAGE_TEMPLATE struct Image - { - agg::rendering_buffer renBuf; - - Image(const agg::rendering_buffer& srcBuf) - : renBuf(srcBuf) - {} - Image(unsigned char* buf, unsigned width, unsigned height, int stride) : - renBuf(buf, width, height, stride) {} - void attach(unsigned char* buf, unsigned width, unsigned height, int stride) - { - renBuf.attach(buf, width, height, stride); - } - int width() const { return renBuf.width(); } - int height() const { return renBuf.height(); } - - AGG2D_TEMPLATE void premultiply() - { - typename PixFormatSet::PixFormat pixf(renBuf); - pixf.premultiply(); - } - - AGG2D_TEMPLATE void demultiply() - { - typename PixFormatSet::PixFormat pixf(renBuf); - pixf.demultiply(); - } - - }; - - enum ImageFilter - { - NoFilter, - Bilinear, - Hanning, - Hermite, - Quadric, - Bicubic, - Catrom, - Spline16, - Spline36, - Blackman144 - }; - - enum ImageResample - { - NoResample, - ResampleAlways, - ResampleOnZoomOut - }; - - enum FontCacheType - { - RasterFontCache, - VectorFontCache - }; - - enum BlendMode - { - BlendAlpha = agg::end_of_comp_op_e, - BlendClear = agg::comp_op_clear, - BlendSrc = agg::comp_op_src, - BlendDst = agg::comp_op_dst, - BlendSrcOver = agg::comp_op_src_over, - BlendDstOver = agg::comp_op_dst_over, - BlendSrcIn = agg::comp_op_src_in, - BlendDstIn = agg::comp_op_dst_in, - BlendSrcOut = agg::comp_op_src_out, - BlendDstOut = agg::comp_op_dst_out, - BlendSrcAtop = agg::comp_op_src_atop, - BlendDstAtop = agg::comp_op_dst_atop, - BlendXor = agg::comp_op_xor, - BlendAdd = agg::comp_op_plus, - BlendSub = agg::comp_op_minus, - BlendMultiply = agg::comp_op_multiply, - BlendScreen = agg::comp_op_screen, - BlendOverlay = agg::comp_op_overlay, - BlendDarken = agg::comp_op_darken, - BlendLighten = agg::comp_op_lighten, - BlendColorDodge = agg::comp_op_color_dodge, - BlendColorBurn = agg::comp_op_color_burn, - BlendHardLight = agg::comp_op_hard_light, - BlendSoftLight = agg::comp_op_soft_light, - BlendDifference = agg::comp_op_difference, - BlendExclusion = agg::comp_op_exclusion, - BlendContrast = agg::comp_op_contrast - }; - - enum Direction - { - CW, CCW - }; - -}; - -template class Agg2DRenderer; - -template class Agg2D : public Agg2DBase -{ -public: - typedef typename PixFormatSet::PixFormat PixFormat; - typedef Image MyImage; - typedef agg::order_bgra ComponentOrder; // Platform dependent! - - typedef agg::rgba8 ColorType; - typedef agg::blender_rgba Blender; - typedef agg::comp_op_adaptor_rgba BlenderComp; - typedef agg::blender_rgba_pre BlenderPre; - typedef agg::comp_op_adaptor_rgba_pre BlenderCompPre; - - // JME - //typedef agg::pixel_formats_rgba PixFormat; - //typedef agg::pixfmt_bgra32 PixFormat; - // JME - //typedef agg::pixfmt_custom_blend_rgba PixFormatComp; - typedef agg::pixfmt_custom_blend_rgba PixFormatComp; - // JME - //typedef agg::pixel_formats_rgba PixFormatPre; - typedef typename PixFormatSet::PixFormatPre PixFormatPre; - // JME - //typedef agg::pixfmt_custom_blend_rgba PixFormatCompPre; - typedef agg::pixfmt_custom_blend_rgba PixFormatCompPre; - - typedef agg::renderer_base RendererBase; - typedef agg::renderer_base RendererBaseComp; - typedef agg::renderer_base RendererBasePre; - typedef agg::renderer_base RendererBaseCompPre; - - typedef agg::renderer_scanline_aa_solid RendererSolid; - typedef agg::renderer_scanline_aa_solid RendererSolidComp; - - typedef agg::span_allocator SpanAllocator; - typedef agg::pod_auto_array GradientArray; - - typedef agg::span_gradient, agg::gradient_x, GradientArray> LinearGradientSpan; - typedef agg::span_gradient, agg::gradient_circle, GradientArray> RadialGradientSpan; - -#ifdef AGG2D_USE_VECTORFONTS -#ifdef AGG2D_USE_FREETYPE - typedef agg::font_engine_freetype_int32 FontEngine; -#else - typedef agg::font_engine_win32_tt_int32 FontEngine; -#endif - - typedef agg::font_cache_manager FontCacheManager; - typedef FontCacheManager::gray8_adaptor_type FontRasterizer; - typedef FontCacheManager::gray8_scanline_type FontScanline; -#endif - - typedef agg::conv_curve ConvCurve; - typedef agg::conv_stroke ConvStroke; - typedef agg::conv_transform PathTransform; - typedef agg::conv_transform StrokeTransform; - enum Gradient - { - Solid, - Linear, - Radial - }; - -public: - template friend class Agg2DRenderer; - - typedef ColorType Color; - - - - struct State - { - RectD m_clipBox; - - BlendMode m_blendMode; - BlendMode m_imageBlendMode; - Color m_imageBlendColor; - - double m_masterAlpha; - double m_antiAliasGamma; - - const agg::int8u* m_font; - - Color m_fillColor; - Color m_lineColor; - GradientArray m_fillGradient; - GradientArray m_lineGradient; - - LineCap m_lineCap; - LineJoin m_lineJoin; - - Gradient m_fillGradientFlag; - Gradient m_lineGradientFlag; - agg::trans_affine m_fillGradientMatrix; - agg::trans_affine m_lineGradientMatrix; - double m_fillGradientD1; - double m_lineGradientD1; - double m_fillGradientD2; - double m_lineGradientD2; - - double m_textAngle; - TextAlignment m_textAlignX; - TextAlignment m_textAlignY; - bool m_textHints; - double m_fontHeight; - double m_fontAscent; - double m_fontDescent; - FontCacheType m_fontCacheType; - - double m_lineWidth; - bool m_evenOddFlag; - - agg::trans_affine m_transform; - agg::trans_affine m_affine; - - }; - - - ~Agg2D(); - Agg2D(); - - // Setup - //----------------------- - void attach(unsigned char* buf, unsigned width, unsigned height, int stride); - void attach(MyImage& img); - - void clipBox(double x1, double y1, double x2, double y2); - RectD clipBox() const; - - void clearAll(Color c); - void clearAll(unsigned r, unsigned g, unsigned b, unsigned a = 255); - - void clearClipBox(Color c); - void clearClipBox(unsigned r, unsigned g, unsigned b, unsigned a = 255); - - unsigned width() const { return m_rbuf.width(); } - unsigned height() const { return m_rbuf.height(); } - unsigned stride() const { return m_rbuf.stride(); } - - // Conversions - //----------------------- - void worldToScreen(double& x, double& y) const; - void screenToWorld(double& x, double& y) const; - double worldToScreen(double scalar) const; - double screenToWorld(double scalar) const; - void alignPoint(double& x, double& y) const; - bool inBox(double worldX, double worldY) const; - - // General Attributes - //----------------------- - void blendMode(BlendMode m); - BlendMode blendMode() const; - - void imageBlendMode(BlendMode m); - BlendMode imageBlendMode() const; - - void imageBlendColor(Color c); - void imageBlendColor(unsigned r, unsigned g, unsigned b, unsigned a = 255); - Color imageBlendColor() const; - - void masterAlpha(double a); - double masterAlpha() const; - - void antiAliasGamma(double g); - double antiAliasGamma() const; - - void font(const agg::int8u* font) { m_font = font; } - const agg::int8u* font() { return m_font; } - - void fillColor(Color c); - void fillColor(unsigned r, unsigned g, unsigned b, unsigned a = 255); - void noFill(); - - void lineColor(Color c); - void lineColor(unsigned r, unsigned g, unsigned b, unsigned a = 255); - void noLine(); - - Color fillColor() const; - Color lineColor() const; - - void fillLinearGradient(double x1, double y1, double x2, double y2, Color c1, Color c2, double profile=1.0); - void lineLinearGradient(double x1, double y1, double x2, double y2, Color c1, Color c2, double profile=1.0); - - void fillRadialGradient(double x, double y, double r, Color c1, Color c2, double profile=1.0); - void lineRadialGradient(double x, double y, double r, Color c1, Color c2, double profile=1.0); - - void fillRadialGradient(double x, double y, double r, Color c1, Color c2, Color c3); - void lineRadialGradient(double x, double y, double r, Color c1, Color c2, Color c3); - - void fillRadialGradient(double x, double y, double r); - void lineRadialGradient(double x, double y, double r); - - void lineWidth(double w); - double lineWidth() const; - - void lineCap(LineCap cap); - LineCap lineCap() const; - - void lineJoin(LineJoin join); - LineJoin lineJoin() const; - - void fillEvenOdd(bool evenOddFlag); - bool fillEvenOdd() const; - - // Transformations - //----------------------- - Transformations transformations() const; - void transformations(const Transformations& tr); - - const Affine& affine() const; - void affine(const Affine&); - - void resetTransformations(); - void matrix(const Affine& tr); - void matrix(const Transformations& tr); - void rotate(double angle); - void rotate(double angle, double cx, double cy); - void scale(double s); - void scale(double sx, double sy); - void skew(double sx, double sy); - void translate(double x, double y); - void parallelogram(double x1, double y1, double x2, double y2, const double* para); - void viewport(double worldX1, double worldY1, double worldX2, double worldY2, - double screenX1, double screenY1, double screenX2, double screenY2, - ViewportOption opt=XMidYMid, WindowFitLogic fl = WindowFitLogic_meet); - - // Basic Shapes - //----------------------- - void line(double x1, double y1, double x2, double y2); - void triangle(double x1, double y1, double x2, double y2, double x3, double y3); - void rectangle(double x1, double y1, double x2, double y2); - void roundedRect(double x1, double y1, double x2, double y2, double r); - void roundedRect(double x1, double y1, double x2, double y2, double rx, double ry); - void roundedRect(double x1, double y1, double x2, double y2, - double rxBottom, double ryBottom, - double rxTop, double ryTop); - void ellipse(double cx, double cy, double rx, double ry); - void arc(double cx, double cy, double rx, double ry, double start, double sweep); - void star(double cx, double cy, double r1, double r2, double startAngle, int numRays); - void curve(double x1, double y1, double x2, double y2, double x3, double y3); - void curve(double x1, double y1, double x2, double y2, double x3, double y3, double x4, double y4); - void polygon(double* xy, int numPoints); - void polyline(double* xy, int numPoints); - - - // Text - //----------------------- - #ifdef AGG2D_USE_VECTORFONTS - void flipText(bool flip); - void font(const char* fileName, double height, - bool bold = false, - bool italic = false, - FontCacheType ch = RasterFontCache, - double angle = 0.0); - double fontHeight() const; - double fontAscent() const; - - void textAlignment(TextAlignment alignX, TextAlignment alignY); - bool textHints() const; - void textHints(bool hints); - double textWidth(const char* str, unsigned int len); - double textWidth(const wchar_t* str, unsigned int len); - void text(double x, double y, const char* str, unsigned int len, bool roundOff=false, double dx=0.0, double dy=0.0); - void text(double x, double y, const wchar_t* str, unsigned int len, bool roundOff=false, double dx=0.0, double dy=0.0); - - double textWidth(const char* str); - void text(double x, double y, const char* str, bool roundOff=false, double dx=0.0, double dy=0.0); - #endif - - // Path commands - //----------------------- - void resetPath(); - - void moveTo(double x, double y); - void moveRel(double dx, double dy); - - void lineTo(double x, double y); - void lineRel(double dx, double dy); - - void horLineTo(double x); - void horLineRel(double dx); - - void verLineTo(double y); - void verLineRel(double dy); - - void arcTo(double rx, double ry, - double angle, - bool largeArcFlag, - bool sweepFlag, - double x, double y); - - void arcRel(double rx, double ry, - double angle, - bool largeArcFlag, - bool sweepFlag, - double dx, double dy); - - void quadricCurveTo(double xCtrl, double yCtrl, - double xTo, double yTo); - void quadricCurveRel(double dxCtrl, double dyCtrl, - double dxTo, double dyTo); - void quadricCurveTo(double xTo, double yTo); - void quadricCurveRel(double dxTo, double dyTo); - - void cubicCurveTo(double xCtrl1, double yCtrl1, - double xCtrl2, double yCtrl2, - double xTo, double yTo); - - void cubicCurveRel(double dxCtrl1, double dyCtrl1, - double dxCtrl2, double dyCtrl2, - double dxTo, double dyTo); - - void cubicCurveTo(double xCtrl2, double yCtrl2, - double xTo, double yTo); - - void cubicCurveRel(double xCtrl2, double yCtrl2, - double xTo, double yTo); - - void addEllipse(double cx, double cy, double rx, double ry, Direction dir); - void closePolygon(); - - void drawPath(DrawPathFlag flag = FillAndStroke); - void drawPathNoTransform(DrawPathFlag flag = FillAndStroke); - - - // Image Transformations - //----------------------- - void imageFilter(ImageFilter f); - ImageFilter imageFilter() const; - - void imageResample(ImageResample f); - ImageResample imageResample() const; - - //--------- - //if anyone can figure out how to put these in the .inl file, theyre more than welcome to. I couldnt declare them correctly to match - //the .h file declaration - - AGG2D_IMAGE_TEMPLATE void transformImage(const TIMAGE& img, - int imgX1, int imgY1, int imgX2, int imgY2, - double dstX1, double dstY1, double dstX2, double dstY2) - { - resetPath(); - moveTo(dstX1, dstY1); - lineTo(dstX2, dstY1); - lineTo(dstX2, dstY2); - lineTo(dstX1, dstY2); - closePolygon(); - double parallelogram[6] = { dstX1, dstY1, dstX2, dstY1, dstX2, dstY2 }; - renderImage (img, imgX1, imgY1, imgX2, imgY2, parallelogram); - } - - AGG2D_IMAGE_TEMPLATE void transformImage(const TIMAGE& img, - double dstX1, double dstY1, double dstX2, double dstY2) - { - resetPath(); - moveTo(dstX1, dstY1); - lineTo(dstX2, dstY1); - lineTo(dstX2, dstY2); - lineTo(dstX1, dstY2); - closePolygon(); - double parallelogram[6] = { dstX1, dstY1, dstX2, dstY1, dstX2, dstY2 }; - renderImage(img, 0, 0, img.renBuf.width(), img.renBuf.height(), parallelogram); - } - - - AGG2D_IMAGE_TEMPLATE void transformImage(const TIMAGE& img, - int imgX1, int imgY1, int imgX2, int imgY2, - const double* parallelogram) - { - resetPath(); - moveTo(parallelogram[0], parallelogram[1]); - lineTo(parallelogram[2], parallelogram[3]); - lineTo(parallelogram[4], parallelogram[5]); - lineTo(parallelogram[0] + parallelogram[4] - parallelogram[2], - parallelogram[1] + parallelogram[5] - parallelogram[3]); - closePolygon(); - renderImage(img, imgX1, imgY1, imgX2, imgY2, parallelogram); - } - - - AGG2D_IMAGE_TEMPLATE void transformImage(const TIMAGE& img, const double* parallelogram) -{ - resetPath(); - moveTo(parallelogram[0], parallelogram[1]); - lineTo(parallelogram[2], parallelogram[3]); - lineTo(parallelogram[4], parallelogram[5]); - lineTo(parallelogram[0] + parallelogram[4] - parallelogram[2], - parallelogram[1] + parallelogram[5] - parallelogram[3]); - closePolygon(); - renderImage(img, 0, 0, img.renBuf.width(), img.renBuf.height(), parallelogram); -} - - - - AGG2D_IMAGE_TEMPLATE void transformImagePath(const TIMAGE& img, - int imgX1, int imgY1, int imgX2, int imgY2, - double dstX1, double dstY1, double dstX2, double dstY2) - { - double parallelogram[6] = { dstX1, dstY1, dstX2, dstY1, dstX2, dstY2 }; - renderImage(img, imgX1, imgY1, imgX2, imgY2, parallelogram); -} - - - AGG2D_IMAGE_TEMPLATE void transformImagePath(const TIMAGE& img, - double dstX1, double dstY1, double dstX2, double dstY2) -{ - double parallelogram[6] = { dstX1, dstY1, dstX2, dstY1, dstX2, dstY2 }; - renderImage(img, 0, 0, img.renBuf.width(), img.renBuf.height(), parallelogram); -} - - - - AGG2D_IMAGE_TEMPLATE void transformImagePath(const TIMAGE& img, - int imgX1, int imgY1, int imgX2, int imgY2, - const double* parallelogram) - { - renderImage(img, imgX1, imgY1, imgX2, imgY2, parallelogram); -} - - - AGG2D_IMAGE_TEMPLATE void transformImagePath(const TIMAGE& img, const double* parallelogram) -{ - renderImage(img, 0, 0, img.renBuf.width(), img.renBuf.height(), parallelogram); -} - - - - // Image Blending (no transformations available) - AGG2D_IMAGE_TEMPLATE void blendImage(TIMAGE& img, - int imgX1, int imgY1, int imgX2, int imgY2, - double dstX, double dstY, unsigned alpha=255) -{ - worldToScreen(dstX, dstY); - PixFormat pixF(img.renBuf); - // JME - //agg::rect r(imgX1, imgY1, imgX2, imgY2); - Rect r(imgX1, imgY1, imgX2, imgY2); - if(m_blendMode == BlendAlpha) - { - m_renBasePre.blend_from(pixF, &r, int(dstX)-imgX1, int(dstY)-imgY1, alpha); - } - else - { - m_renBaseCompPre.blend_from(pixF, &r, int(dstX)-imgX1, int(dstY)-imgY1, alpha); - } -} - - - void renderText(double dstX, double dstY, const std::string& str) - { - worldToScreen(dstX, dstY); - PixFormat pixF(m_rbuf); - //Rect r(imgX1, imgY1, imgX2, imgY2); - - typedef agg::glyph_raster_bin glyph_gen; - glyph_gen glyph(0); - - if(m_blendMode == BlendAlpha) - { - typedef agg::renderer_base ren_base; - agg::renderer_raster_htext_solid rt(m_renBasePre,glyph); - rt.color(m_lineColor); - glyph.font(m_font); - rt.render_text(dstX, dstY, str.c_str(), true); //flipy - } - else - { - typedef agg::renderer_base ren_base; - agg::renderer_raster_htext_solid rt(m_renBaseCompPre,glyph); - rt.color(m_lineColor); - glyph.font(m_font); - rt.render_text(dstX, dstY, str.c_str(), true); //flipy - } - } - - - AGG2D_IMAGE_TEMPLATE void blendImage(TIMAGE& img, double dstX, double dstY, unsigned alpha=255) - { - worldToScreen(dstX, dstY); - PixFormat pixF(img.renBuf); - m_renBasePre.blend_from(pixF, 0, int(dstX), int(dstY), alpha); - if(m_blendMode == BlendAlpha) - { - m_renBasePre.blend_from(pixF, 0, int(dstX), int(dstY), alpha); - } - else - { - m_renBaseCompPre.blend_from(pixF, 0, int(dstX), int(dstY), alpha); - } - } - - - - // Copy image directly, together with alpha-channel - AGG2D_IMAGE_TEMPLATE void copyImage(TIMAGE& img, - int imgX1, int imgY1, int imgX2, int imgY2, - double dstX, double dstY) -{ - worldToScreen(dstX, dstY); - // JME - //agg::rect r(imgX1, imgY1, imgX2, imgY2); - Rect r(imgX1, imgY1, imgX2, imgY2); - m_renBase.copy_from(img.renBuf, &r, int(dstX)-imgX1, int(dstY)-imgY1); -} - - AGG2D_IMAGE_TEMPLATE void copyImage(TIMAGE& img, double dstX, double dstY) -{ - worldToScreen(dstX, dstY); - m_renBase.copy_from(img.renBuf, 0, int(dstX), int(dstY)); -} - - // State - //----------------------- - - void saveStateTo(State& st); - void restoreStateFrom(const State& st); - - - - // Auxiliary - //----------------------- - static double pi() { return agg::pi; } - static double deg2Rad(double v) { return v * agg::pi / 180.0; } - static double rad2Deg(double v) { return v * 180.0 / agg::pi; } - - PixFormat & pixFormat() { return m_pixFormat; } - agg::rendering_buffer & buf() { return m_rbuf; } - -private: - void render(bool fillColor); - -#ifdef AGG2D_USE_VECTORFONTS -#if !defined( UNDER_CE ) - void render(FontRasterizer& ras, FontScanline& sl); -#endif -#endif - - void addLine(double x1, double y1, double x2, double y2); - void updateRasterizerGamma(); - AGG2D_IMAGE_TEMPLATE void renderImage(const TIMAGE& img, int x1, int y1, int x2, int y2, const double* parl) - { - agg::trans_affine mtx((double)x1, - (double)y1, - (double)x2, - (double)y2, - parl); - mtx *= m_transform; - mtx.invert(); - - m_rasterizer.reset(); - m_rasterizer.add_path(m_pathTransform); - - typedef agg::span_interpolator_linear Interpolator; - Interpolator interpolator(mtx); - - if(m_blendMode == BlendAlpha) - { - // JME audit - - Agg2DRenderer::renderImage(*this, img, m_renBasePre, interpolator); - } - else - { - Agg2DRenderer::renderImage(*this, img, m_renBaseCompPre, interpolator); - } - } - - - void updateTransformations(); - - agg::rendering_buffer m_rbuf; - PixFormat m_pixFormat; - PixFormatComp m_pixFormatComp; - PixFormatPre m_pixFormatPre; - PixFormatCompPre m_pixFormatCompPre; - RendererBase m_renBase; - RendererBaseComp m_renBaseComp; - RendererBasePre m_renBasePre; - RendererBaseCompPre m_renBaseCompPre; - RendererSolid m_renSolid; - RendererSolidComp m_renSolidComp; - - SpanAllocator m_allocator; - RectD m_clipBox; - - BlendMode m_blendMode; - BlendMode m_imageBlendMode; - Color m_imageBlendColor; - - agg::scanline_u8 m_scanline; - agg::rasterizer_scanline_aa<> m_rasterizer; - - double m_masterAlpha; - double m_antiAliasGamma; - - const agg::int8u* m_font; - - Color m_fillColor; - Color m_lineColor; - GradientArray m_fillGradient; - GradientArray m_lineGradient; - - LineCap m_lineCap; - LineJoin m_lineJoin; - - Gradient m_fillGradientFlag; - Gradient m_lineGradientFlag; - agg::trans_affine m_fillGradientMatrix; - agg::trans_affine m_lineGradientMatrix; - double m_fillGradientD1; - double m_lineGradientD1; - double m_fillGradientD2; - double m_lineGradientD2; - - double m_textAngle; - TextAlignment m_textAlignX; - TextAlignment m_textAlignY; - bool m_textHints; - double m_fontHeight; - double m_fontAscent; - double m_fontDescent; - FontCacheType m_fontCacheType; - - ImageFilter m_imageFilter; - ImageResample m_imageResample; - agg::image_filter_lut m_imageFilterLut; - - agg::span_interpolator_linear<> m_fillGradientInterpolator; - agg::span_interpolator_linear<> m_lineGradientInterpolator; - - agg::gradient_x m_linearGradientFunction; - agg::gradient_circle m_radialGradientFunction; - - double m_lineWidth; - bool m_evenOddFlag; - - double m_start_x; - double m_start_y; - - agg::path_storage m_path; - agg::trans_affine m_transform; - - agg::trans_affine m_viewport; - agg::trans_affine m_affine; - - ConvCurve m_convCurve; - ConvStroke m_convStroke; - - PathTransform m_pathTransform; - StrokeTransform m_strokeTransform; - -#ifdef AGG2D_USE_VECTORFONTS -#ifndef AGG2D_USE_FREETYPE - HDC m_fontDC; -#endif - FontEngine m_fontEngine; - FontCacheManager m_fontCacheManager; -#endif -}; - - - -#include "agg2d.inl" - -#endif diff --git a/desmume/src/agg2d.inl b/desmume/src/agg2d.inl deleted file mode 100644 index d4b7c51bc..000000000 --- a/desmume/src/agg2d.inl +++ /dev/null @@ -1,1977 +0,0 @@ -//---------------------------------------------------------------------------- -// Agg2D - Version 1.0 -// Based on Anti-Grain Geometry -// Copyright (C) 2005 Maxim Shemanarev (http://www.antigrain.com) -// -// Permission to copy, use, modify, sell and distribute this software -// is granted provided this copyright notice appears in all copies. -// This software is provided "as is" without express or implied -// warranty, and with no claim as to its suitability for any purpose. -// -//---------------------------------------------------------------------------- -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://www.antigrain.com -//---------------------------------------------------------------------------- -//---------------------------------------------------------------------------- -// -// 25 Jan 2007 - Ported to AGG 2.4 Jerry Evans (jerry@novadsp.com) -// 11 Jul 2009 - significant refactors for introduction to desmume -// -//---------------------------------------------------------------------------- -#include "agg2d.h" - -static const double g_approxScale = 2.0; - -#define TAGG2D Agg2D AGG2D_TEMPLATE_ARG -#define TAGG2DRENDERER Agg2DRenderer - -//AGG2D_TEMPLATE inline bool operator == (const TAGG2D::Color& c1, const TAGG2D::Color& c2) -//{ -// return c1.r == c2.r && c1.g == c2.g && c1.b == c2.b && c1.a == c2.a; -//} -// -//AGG2D_TEMPLATE inline bool operator != (const Agg2D::Color& c1, const Agg2D::Color& c2) -//{ -// return !(c1 == c2); -//} - -AGG2D_TEMPLATE inline TAGG2D::~Agg2D() -{ -#ifdef AGG2D_USE_VECTORFONTS -#ifndef AGG2D_USE_FREETYPE - ::ReleaseDC(0, m_fontDC); -#endif -#endif -} - -AGG2D_TEMPLATE inline TAGG2D::Agg2D() : - m_rbuf(), - m_pixFormat(m_rbuf), - m_pixFormatComp(m_rbuf), - m_pixFormatPre(m_rbuf), - m_pixFormatCompPre(m_rbuf), - m_renBase(m_pixFormat), - m_renBaseComp(m_pixFormatComp), - m_renBasePre(m_pixFormatPre), - m_renBaseCompPre(m_pixFormatCompPre), - m_renSolid(m_renBase), - m_renSolidComp(m_renBaseComp), - - m_allocator(), - m_clipBox(0,0,0,0), - - m_blendMode(BlendAlpha), - m_imageBlendMode(BlendDst), - m_imageBlendColor(0,0,0), - - m_scanline(), - m_rasterizer(), - - m_masterAlpha(1.0), - m_antiAliasGamma(1.0), - - m_font(agg::gse4x6), - m_fillColor(255, 255, 255), - m_lineColor(0, 0, 0), - m_fillGradient(), - m_lineGradient(), - - m_lineCap(CAP_ROUND), - m_lineJoin(JOIN_ROUND), - - m_fillGradientFlag(Solid), - m_lineGradientFlag(Solid), - m_fillGradientMatrix(), - m_lineGradientMatrix(), - m_fillGradientD1(0.0), - m_lineGradientD1(0.0), - m_fillGradientD2(100.0), - m_lineGradientD2(100.0), - - m_textAngle(0.0), - m_textAlignX(AlignLeft), - m_textAlignY(AlignBottom), - m_textHints(true), - m_fontHeight(0.0), - m_fontAscent(0.0), - m_fontDescent(0.0), - m_fontCacheType(RasterFontCache), - - m_imageFilter(Bilinear), //less quality more speed - //m_imageFilter(NoFilter), - m_imageResample(NoResample), - m_imageFilterLut(agg::image_filter_bilinear(), true), - - m_fillGradientInterpolator(m_fillGradientMatrix), - m_lineGradientInterpolator(m_lineGradientMatrix), - - m_linearGradientFunction(), - m_radialGradientFunction(), - - m_lineWidth(1), - m_evenOddFlag(false), - - m_start_x(0.0), - m_start_y(0.0), - - m_path(), - m_transform(), - - m_convCurve(m_path), - m_convStroke(m_convCurve), - - m_pathTransform(m_convCurve, m_transform), - m_strokeTransform(m_convStroke, m_transform) - -#ifdef AGG2D_USE_VECTORFONTS -#ifdef AGG2D_USE_FREETYPE - , m_fontEngine(), -#else - m_fontDC(::GetDC(0)), - m_fontEngine(m_fontDC), -#endif - m_fontCacheManager(m_fontEngine) -#endif -{ - lineCap(m_lineCap); - lineJoin(m_lineJoin); -} - -AGG2D_TEMPLATE void Agg2D AGG2D_TEMPLATE_ARG ::saveStateTo(State& st) -{ - - st.m_clipBox = m_clipBox; - - st.m_blendMode = m_blendMode; - st.m_imageBlendMode = m_imageBlendMode; - st.m_imageBlendColor = m_imageBlendColor; - - st.m_masterAlpha = m_masterAlpha; - st.m_antiAliasGamma = m_antiAliasGamma; - - st.m_font = m_font; - st.m_fillColor = m_fillColor; - st.m_lineColor = m_lineColor; - st.m_fillGradient = m_fillGradient; - st.m_lineGradient = m_lineGradient; - - st.m_lineCap = m_lineCap; - st.m_lineJoin = m_lineJoin; - - st.m_fillGradientFlag = m_fillGradientFlag; - st.m_lineGradientFlag = m_lineGradientFlag; - st.m_fillGradientMatrix = m_fillGradientMatrix; - st.m_lineGradientMatrix = m_lineGradientMatrix; - st.m_fillGradientD1 = m_fillGradientD1; - st.m_lineGradientD1 = m_lineGradientD1; - st.m_fillGradientD2 = m_fillGradientD2; - st.m_lineGradientD2 = m_lineGradientD2; - - st.m_textAngle = m_textAngle; - st.m_textAlignX = m_textAlignX; - st.m_textAlignY = m_textAlignY; - st.m_textHints = m_textHints; - st.m_fontHeight = m_fontHeight; - st.m_fontAscent = m_fontAscent; - st.m_fontDescent = m_fontDescent; - st.m_fontCacheType = m_fontCacheType; - - st.m_lineWidth = m_lineWidth; - st.m_evenOddFlag = m_evenOddFlag; - - st.m_transform = m_transform; - st.m_affine = m_affine; - -} - -AGG2D_TEMPLATE void Agg2D AGG2D_TEMPLATE_ARG ::restoreStateFrom(const State& st) -{ - - m_clipBox = st.m_clipBox; - - m_blendMode = st.m_blendMode; - m_imageBlendMode = st.m_imageBlendMode; - m_imageBlendColor = st.m_imageBlendColor; - - m_masterAlpha = st.m_masterAlpha; - m_antiAliasGamma = st.m_antiAliasGamma; - - m_font = st.m_font; - m_fillColor = st.m_fillColor; - m_lineColor = st.m_lineColor; - m_fillGradient = st.m_fillGradient; - m_lineGradient = st.m_lineGradient; - - m_lineCap = st.m_lineCap; - m_lineJoin = st.m_lineJoin; - - m_fillGradientFlag = st.m_fillGradientFlag; - m_lineGradientFlag = st.m_lineGradientFlag; - m_fillGradientMatrix = st.m_fillGradientMatrix; - m_lineGradientMatrix = st.m_lineGradientMatrix; - m_fillGradientD1 = st.m_fillGradientD1; - m_lineGradientD1 = st.m_lineGradientD1; - m_fillGradientD2 = st.m_fillGradientD2; - m_lineGradientD2 = st.m_lineGradientD2; - - m_textAngle = st.m_textAngle; - m_textAlignX = st.m_textAlignX; - m_textAlignY = st.m_textAlignY; - m_textHints = st.m_textHints; - m_fontHeight = st.m_fontHeight; - m_fontAscent = st.m_fontAscent; - m_fontDescent = st.m_fontDescent; - m_fontCacheType = st.m_fontCacheType; - - m_lineWidth = st.m_lineWidth; - m_evenOddFlag = st.m_evenOddFlag; - - m_affine = st.m_affine; - m_transform = st.m_transform; - -} - - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void Agg2D AGG2D_TEMPLATE_ARG ::attach(unsigned char* buf, unsigned width, unsigned height, int stride) -{ - m_rbuf.attach(buf, width, height, stride); - - m_renBase.reset_clipping(true); - m_renBaseComp.reset_clipping(true); - m_renBasePre.reset_clipping(true); - m_renBaseCompPre.reset_clipping(true); - - //why is all this reset here???? seems silly. - - resetTransformations(); - lineWidth(1.0), - lineColor(0,0,0); - fillColor(255,255,255); - clipBox(0, 0, width, height); - lineCap(CAP_ROUND); - lineJoin(JOIN_ROUND); - #ifdef AGG2D_USE_VECTORFONTS - textAlignment(AlignLeft, AlignBottom); - flipText(false); - #endif - imageFilter(Bilinear); //less quality more speed - //imageFilter(NoFilter); - imageResample(NoResample); - m_masterAlpha = 1.0; - m_antiAliasGamma = 1.0; - m_rasterizer.gamma(agg::gamma_none()); - m_blendMode = BlendAlpha; -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void Agg2D AGG2D_TEMPLATE_ARG ::attach(MyImage& img) -{ - attach(img.renBuf.buf(), img.renBuf.width(), img.renBuf.height(), img.renBuf.stride()); -} - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void Agg2D AGG2D_TEMPLATE_ARG ::clipBox(double x1, double y1, double x2, double y2) -{ - m_viewport.transform(&x1, &y1); // - m_viewport.transform(&x2, &y2); // see: http://article.gmane.org/gmane.comp.graphics.agg/3543 - - m_clipBox = RectD(x1, y1, x2, y2); - - int rx1 = int(x1); - int ry1 = int(y1); - int rx2 = int(x2); - int ry2 = int(y2); - - m_renBase.clip_box(rx1, ry1, rx2, ry2); - m_renBaseComp.clip_box(rx1, ry1, rx2, ry2); - m_renBasePre.clip_box(rx1, ry1, rx2, ry2); - m_renBaseCompPre.clip_box(rx1, ry1, rx2, ry2); - - // m_rasterizer.clip_box(x1, y1, x2, y2); - m_rasterizer.clip_box(m_renBase.xmin(), m_renBase.ymin(), - m_renBase.xmax()+1, m_renBase.ymax()+1); // see link above - -} - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void Agg2D AGG2D_TEMPLATE_ARG ::blendMode(BlendMode m) -{ - m_blendMode = m; - m_pixFormatComp.comp_op(m); - m_pixFormatCompPre.comp_op(m); -} - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE typename Agg2D AGG2D_TEMPLATE_ARG ::BlendMode Agg2D AGG2D_TEMPLATE_ARG ::blendMode() const -{ - return m_blendMode; -} - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void Agg2D AGG2D_TEMPLATE_ARG ::imageBlendMode(BlendMode m) -{ - m_imageBlendMode = m; -} - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE typename Agg2D AGG2D_TEMPLATE_ARG ::BlendMode Agg2D AGG2D_TEMPLATE_ARG ::imageBlendMode() const -{ - return m_imageBlendMode; -} - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void Agg2D AGG2D_TEMPLATE_ARG ::imageBlendColor(Color c) -{ - m_imageBlendColor = c; -} - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void Agg2D AGG2D_TEMPLATE_ARG ::imageBlendColor(unsigned r, unsigned g, unsigned b, unsigned a) -{ - imageBlendColor(Color(r, g, b, a)); -} - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE typename Agg2D AGG2D_TEMPLATE_ARG ::Color Agg2D AGG2D_TEMPLATE_ARG ::imageBlendColor() const -{ - return m_imageBlendColor; -} - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void Agg2D AGG2D_TEMPLATE_ARG ::masterAlpha(double a) -{ - m_masterAlpha = a; - updateRasterizerGamma(); -} - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE double Agg2D AGG2D_TEMPLATE_ARG ::masterAlpha() const -{ - return m_masterAlpha; -} - -//------------------------------------------------------------------------+ -AGG2D_TEMPLATE void Agg2D AGG2D_TEMPLATE_ARG ::antiAliasGamma(double g) -{ - m_antiAliasGamma = g; - updateRasterizerGamma(); -} - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE double Agg2D AGG2D_TEMPLATE_ARG ::antiAliasGamma() const -{ - return m_antiAliasGamma; -} - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE Agg2DBase::RectD Agg2D AGG2D_TEMPLATE_ARG ::clipBox() const -{ - return m_clipBox; -} - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void Agg2D AGG2D_TEMPLATE_ARG ::clearAll(Color c) -{ - m_renBase.clear(c); -} - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void Agg2D AGG2D_TEMPLATE_ARG ::clearAll(unsigned r, unsigned g, unsigned b, unsigned a) -{ - clearAll(Color(r, g, b, a)); -} - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void Agg2D AGG2D_TEMPLATE_ARG ::clearClipBox(Color c) -{ - m_renBase.copy_bar(0, 0, m_renBase.width(), m_renBase.height(), c); -} - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void Agg2D AGG2D_TEMPLATE_ARG ::clearClipBox(unsigned r, unsigned g, unsigned b, unsigned a) -{ - clearClipBox(Color(r, g, b, a)); -} - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void Agg2D AGG2D_TEMPLATE_ARG ::worldToScreen(double& x, double& y) const -{ - m_transform.transform(&x, &y); -} - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void Agg2D AGG2D_TEMPLATE_ARG ::screenToWorld(double& x, double& y) const -{ - m_transform.inverse_transform(&x, &y); -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE double Agg2D AGG2D_TEMPLATE_ARG ::worldToScreen(double scalar) const -{ - double x1 = 0; - double y1 = 0; - double x2 = scalar; - double y2 = scalar; - worldToScreen(x1, y1); - worldToScreen(x2, y2); - return sqrt((x2 - x1) * (x2 - x1) + (y2 - y1) * (y2 - y1)) * 0.7071068; -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE double Agg2D AGG2D_TEMPLATE_ARG ::screenToWorld(double scalar) const -{ - double x1 = 0; - double y1 = 0; - double x2 = scalar; - double y2 = scalar; - screenToWorld(x1, y1); - screenToWorld(x2, y2); - return sqrt((x2 - x1) * (x2 - x1) + (y2 - y1) * (y2 - y1)) * 0.7071068; -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void Agg2D AGG2D_TEMPLATE_ARG ::alignPoint(double& x, double& y) const -{ - worldToScreen(x, y); - x = floor(x) + 0.5; - y = floor(y) + 0.5; - screenToWorld(x, y); -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE bool Agg2D AGG2D_TEMPLATE_ARG ::inBox(double worldX, double worldY) const -{ - worldToScreen(worldX, worldY); - return m_renBase.inbox(int(worldX), int(worldY)); -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE Agg2DBase::Transformations Agg2D AGG2D_TEMPLATE_ARG ::transformations() const -{ - Transformations tr; - m_transform.store_to(tr.affineMatrix); - return tr; -} -//------------------------------------------------------------------------ -AGG2D_TEMPLATE const Agg2DBase::Affine& Agg2D AGG2D_TEMPLATE_ARG ::affine() const -{ - return m_affine; -} -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void Agg2D AGG2D_TEMPLATE_ARG ::affine(const Affine& af) -{ - m_affine = af; - updateTransformations(); -} -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void Agg2D AGG2D_TEMPLATE_ARG ::transformations(const Transformations& tr) -{ - m_transform.load_from(tr.affineMatrix); - m_convCurve.approximation_scale(worldToScreen(1.0) * g_approxScale); - m_convStroke.approximation_scale(worldToScreen(1.0) * g_approxScale); -} -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void Agg2D AGG2D_TEMPLATE_ARG ::resetTransformations() -{ - m_transform.reset(); -} -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::updateTransformations() -{ - m_transform = m_affine; - m_transform *= m_viewport; - m_convCurve.approximation_scale(worldToScreen(1.0) * g_approxScale); - m_convStroke.approximation_scale(worldToScreen(1.0) * g_approxScale); -} -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::rotate(double angle) -{ - m_affine.premultiply(agg::trans_affine_rotation(angle)); - updateTransformations(); -} -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::rotate(double angle, double cx, double cy) -{ - agg::trans_affine_translation m(-cx, -cy); - m *= agg::trans_affine_rotation(angle); - m *= agg::trans_affine_translation(cx, cy); - m_affine.premultiply(m); - updateTransformations(); -} -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void Agg2D AGG2D_TEMPLATE_ARG ::skew(double sx, double sy) -{ - m_affine.premultiply(agg::trans_affine_skewing(sx, sy)); - updateTransformations(); -} -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::translate(double x, double y) -{ - m_affine.premultiply(agg::trans_affine_translation(x, y)); - updateTransformations(); -} -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void Agg2D AGG2D_TEMPLATE_ARG ::matrix(const Affine& tr) -{ - m_affine.premultiply(tr); - updateTransformations(); -} -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void Agg2D AGG2D_TEMPLATE_ARG ::matrix(const Transformations& tr) -{ - matrix(agg::trans_affine(tr.affineMatrix[0], tr.affineMatrix[1], tr.affineMatrix[2], - tr.affineMatrix[3], tr.affineMatrix[4], tr.affineMatrix[5])); -} -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void Agg2D AGG2D_TEMPLATE_ARG ::scale(double s) -{ - m_affine.premultiply(agg::trans_affine_scaling(s)); - updateTransformations(); -} -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void Agg2D AGG2D_TEMPLATE_ARG ::scale(double sx, double sy) -{ - m_affine.premultiply(agg::trans_affine_scaling(sx, sy)); - updateTransformations(); -} -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void Agg2D AGG2D_TEMPLATE_ARG ::parallelogram(double x1, double y1, double x2, double y2, const double* para) -{ - m_affine.premultiply(agg::trans_affine(x1, y1, x2, y2, para)); - updateTransformations(); -} -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void Agg2D AGG2D_TEMPLATE_ARG ::viewport(double worldX1, double worldY1, double worldX2, double worldY2, - double screenX1, double screenY1, double screenX2, double screenY2, - ViewportOption opt, WindowFitLogic fl) -{ - agg::trans_viewport vp; - - agg::aspect_ratio_e ar = - (fl == WindowFitLogic_meet) ? agg::aspect_ratio_meet : - agg::aspect_ratio_slice; - switch(opt) - { - case Anisotropic: vp.preserve_aspect_ratio(0.0, 0.0, agg::aspect_ratio_stretch); break; - case XMinYMin: vp.preserve_aspect_ratio(0.0, 0.0, ar); break; - case XMidYMin: vp.preserve_aspect_ratio(0.5, 0.0, ar); break; - case XMaxYMin: vp.preserve_aspect_ratio(1.0, 0.0, ar); break; - case XMinYMid: vp.preserve_aspect_ratio(0.0, 0.5, ar); break; - case XMidYMid: vp.preserve_aspect_ratio(0.5, 0.5, ar); break; - case XMaxYMid: vp.preserve_aspect_ratio(1.0, 0.5, ar); break; - case XMinYMax: vp.preserve_aspect_ratio(0.0, 1.0, ar); break; - case XMidYMax: vp.preserve_aspect_ratio(0.5, 1.0, ar); break; - case XMaxYMax: vp.preserve_aspect_ratio(1.0, 1.0, ar); break; - } - vp.world_viewport(worldX1, worldY1, worldX2, worldY2); - vp.device_viewport(screenX1, screenY1, screenX2, screenY2); - - m_viewport = vp.to_affine(); - updateTransformations(); -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void Agg2D AGG2D_TEMPLATE_ARG ::fillColor(Color c) -{ - m_fillColor = c; - m_fillGradientFlag = Solid; -} - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void Agg2D AGG2D_TEMPLATE_ARG ::fillColor(unsigned r, unsigned g, unsigned b, unsigned a) -{ - fillColor(Color(r, g, b, a)); -} - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void Agg2D AGG2D_TEMPLATE_ARG ::noFill() -{ - fillColor(Color(0, 0, 0, 0)); -} - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void Agg2D AGG2D_TEMPLATE_ARG ::lineColor(Color c) -{ - m_lineColor = c; - m_lineGradientFlag = Solid; -} - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void Agg2D AGG2D_TEMPLATE_ARG ::lineColor(unsigned r, unsigned g, unsigned b, unsigned a) -{ - lineColor(Color(r, g, b, a)); -} - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void Agg2D AGG2D_TEMPLATE_ARG ::noLine() -{ - lineColor(Color(0, 0, 0, 0)); -} - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE typename TAGG2D::Color TAGG2D::fillColor() const -{ - return m_fillColor; -} - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE typename TAGG2D::Color TAGG2D::lineColor() const -{ - return m_lineColor; -} - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::fillLinearGradient(double x1, double y1, double x2, double y2, Color c1, Color c2, double profile) -{ - int i; - int startGradient = 128 - int(profile * 127.0); - int endGradient = 128 + int(profile * 127.0); - if (endGradient <= startGradient) endGradient = startGradient + 1; - double k = 1.0 / double(endGradient - startGradient); - for (i = 0; i < startGradient; i++) - { - m_fillGradient[i] = c1; - } - for (; i < endGradient; i++) - { - m_fillGradient[i] = c1.gradient(c2, double(i - startGradient) * k); - } - for (; i < 256; i++) - { - m_fillGradient[i] = c2; - } - double angle = atan2(y2-y1, x2-x1); - m_fillGradientMatrix.reset(); - m_fillGradientMatrix *= agg::trans_affine_rotation(angle); - m_fillGradientMatrix *= agg::trans_affine_translation(x1, y1); - m_fillGradientMatrix *= m_transform; - m_fillGradientMatrix.invert(); - m_fillGradientD1 = 0.0; - m_fillGradientD2 = sqrt((x2-x1) * (x2-x1) + (y2-y1) * (y2-y1)); - m_fillGradientFlag = Linear; - m_fillColor = Color(0,0,0); // Set some real color -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::lineLinearGradient(double x1, double y1, double x2, double y2, Color c1, Color c2, double profile) -{ - int i; - int startGradient = 128 - int(profile * 128.0); - int endGradient = 128 + int(profile * 128.0); - if (endGradient <= startGradient) endGradient = startGradient + 1; - double k = 1.0 / double(endGradient - startGradient); - for (i = 0; i < startGradient; i++) - { - m_lineGradient[i] = c1; - } - for (; i < endGradient; i++) - { - m_lineGradient[i] = c1.gradient(c2, double(i - startGradient) * k); - } - for (; i < 256; i++) - { - m_lineGradient[i] = c2; - } - double angle = atan2(y2-y1, x2-x1); - m_lineGradientMatrix.reset(); - m_lineGradientMatrix *= agg::trans_affine_rotation(angle); - m_lineGradientMatrix *= agg::trans_affine_translation(x1, y1); - m_fillGradientMatrix *= m_transform; - m_lineGradientMatrix.invert(); - m_lineGradientD1 = 0; - m_lineGradientD2 = sqrt((x2-x1) * (x2-x1) + (y2-y1) * (y2-y1)); - m_lineGradientFlag = Linear; - m_lineColor = Color(0,0,0); // Set some real color -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::fillRadialGradient(double x, double y, double r, Color c1, Color c2, double profile) -{ - int i; - int startGradient = 128 - int(profile * 127.0); - int endGradient = 128 + int(profile * 127.0); - if (endGradient <= startGradient) endGradient = startGradient + 1; - double k = 1.0 / double(endGradient - startGradient); - for (i = 0; i < startGradient; i++) - { - m_fillGradient[i] = c1; - } - for (; i < endGradient; i++) - { - m_fillGradient[i] = c1.gradient(c2, double(i - startGradient) * k); - } - for (; i < 256; i++) - { - m_fillGradient[i] = c2; - } - m_fillGradientD2 = worldToScreen(r); - worldToScreen(x, y); - m_fillGradientMatrix.reset(); - m_fillGradientMatrix *= agg::trans_affine_translation(x, y); - m_fillGradientMatrix.invert(); - m_fillGradientD1 = 0; - m_fillGradientFlag = Radial; - m_fillColor = Color(0,0,0); // Set some real color -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::lineRadialGradient(double x, double y, double r, Color c1, Color c2, double profile) -{ - int i; - int startGradient = 128 - int(profile * 128.0); - int endGradient = 128 + int(profile * 128.0); - if (endGradient <= startGradient) endGradient = startGradient + 1; - double k = 1.0 / double(endGradient - startGradient); - for (i = 0; i < startGradient; i++) - { - m_lineGradient[i] = c1; - } - for (; i < endGradient; i++) - { - m_lineGradient[i] = c1.gradient(c2, double(i - startGradient) * k); - } - for (; i < 256; i++) - { - m_lineGradient[i] = c2; - } - m_lineGradientD2 = worldToScreen(r); - worldToScreen(x, y); - m_lineGradientMatrix.reset(); - m_lineGradientMatrix *= agg::trans_affine_translation(x, y); - m_lineGradientMatrix.invert(); - m_lineGradientD1 = 0; - m_lineGradientFlag = Radial; - m_lineColor = Color(0,0,0); // Set some real color -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::fillRadialGradient(double x, double y, double r, Color c1, Color c2, Color c3) -{ - int i; - for (i = 0; i < 128; i++) - { - m_fillGradient[i] = c1.gradient(c2, double(i) / 127.0); - } - for (; i < 256; i++) - { - m_fillGradient[i] = c2.gradient(c3, double(i - 128) / 127.0); - } - m_fillGradientD2 = worldToScreen(r); - worldToScreen(x, y); - m_fillGradientMatrix.reset(); - m_fillGradientMatrix *= agg::trans_affine_translation(x, y); - m_fillGradientMatrix.invert(); - m_fillGradientD1 = 0; - m_fillGradientFlag = Radial; - m_fillColor = Color(0,0,0); // Set some real color -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::lineRadialGradient(double x, double y, double r, Color c1, Color c2, Color c3) -{ - int i; - for (i = 0; i < 128; i++) - { - m_lineGradient[i] = c1.gradient(c2, double(i) / 127.0); - } - for (; i < 256; i++) - { - m_lineGradient[i] = c2.gradient(c3, double(i - 128) / 127.0); - } - m_lineGradientD2 = worldToScreen(r); - worldToScreen(x, y); - m_lineGradientMatrix.reset(); - m_lineGradientMatrix *= agg::trans_affine_translation(x, y); - m_lineGradientMatrix.invert(); - m_lineGradientD1 = 0; - m_lineGradientFlag = Radial; - m_lineColor = Color(0,0,0); // Set some real color -} - - -AGG2D_TEMPLATE void TAGG2D::fillRadialGradient(double x, double y, double r) -{ - m_fillGradientD2 = worldToScreen(r); - worldToScreen(x, y); - m_fillGradientMatrix.reset(); - m_fillGradientMatrix *= agg::trans_affine_translation(x, y); - m_fillGradientMatrix.invert(); - m_fillGradientD1 = 0; -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::lineRadialGradient(double x, double y, double r) -{ - m_lineGradientD2 = worldToScreen(r); - worldToScreen(x, y); - m_lineGradientMatrix.reset(); - m_lineGradientMatrix *= agg::trans_affine_translation(x, y); - m_lineGradientMatrix.invert(); - m_lineGradientD1 = 0; -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::lineWidth(double w) -{ - m_lineWidth = w; - m_convStroke.width(w); -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE double TAGG2D::lineWidth() const -{ - return m_lineWidth; -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::fillEvenOdd(bool evenOddFlag) -{ - m_evenOddFlag = evenOddFlag; - m_rasterizer.filling_rule(evenOddFlag ? agg::fill_even_odd : agg::fill_non_zero); -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE bool TAGG2D::fillEvenOdd() const -{ - return m_evenOddFlag; -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::lineCap(LineCap cap) -{ - m_lineCap = cap; - m_convStroke.line_cap((agg::line_cap_e)cap); -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE Agg2DBase::LineCap TAGG2D::lineCap() const -{ - return m_lineCap; -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::lineJoin(LineJoin join) -{ - m_lineJoin = join; - m_convStroke.line_join((agg::line_join_e)join); -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE Agg2DBase::LineJoin TAGG2D::lineJoin() const -{ - return m_lineJoin; -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::addLine(double x1, double y1, double x2, double y2) -{ - m_path.move_to(x1, y1); - m_path.line_to(x2, y2); -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::line(double x1, double y1, double x2, double y2) -{ - m_path.remove_all(); - addLine(x1, y1, x2, y2); - drawPath(StrokeOnly); -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::triangle(double x1, double y1, double x2, double y2, double x3, double y3) -{ - m_path.remove_all(); - m_path.move_to(x1, y1); - m_path.line_to(x2, y2); - m_path.line_to(x3, y3); - m_path.close_polygon(); - drawPath(FillAndStroke); -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::rectangle(double x1, double y1, double x2, double y2) -{ - m_path.remove_all(); - m_path.move_to(x1, y1); - m_path.line_to(x2, y1); - m_path.line_to(x2, y2); - m_path.line_to(x1, y2); - m_path.close_polygon(); - drawPath(FillAndStroke); -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::roundedRect(double x1, double y1, double x2, double y2, double r) -{ - m_path.remove_all(); - agg::rounded_rect rc(x1, y1, x2, y2, r); - rc.normalize_radius(); - rc.approximation_scale(worldToScreen(1.0) * g_approxScale); - // JME audit - //m_path.add_path(rc, 0, false); - m_path.concat_path(rc,0); - drawPath(FillAndStroke); -} - - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::roundedRect(double x1, double y1, double x2, double y2, double rx, double ry) -{ - m_path.remove_all(); - agg::rounded_rect rc; - rc.rect(x1, y1, x2, y2); - rc.radius(rx, ry); - rc.normalize_radius(); - //m_path.add_path(rc, 0, false); - m_path.concat_path(rc,0); // JME - drawPath(FillAndStroke); -} - - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::roundedRect(double x1, double y1, double x2, double y2, - double rx_bottom, double ry_bottom, - double rx_top, double ry_top) -{ - m_path.remove_all(); - agg::rounded_rect rc; - rc.rect(x1, y1, x2, y2); - rc.radius(rx_bottom, ry_bottom, rx_top, ry_top); - rc.normalize_radius(); - rc.approximation_scale(worldToScreen(1.0) * g_approxScale); - //m_path.add_path(rc, 0, false); - m_path.concat_path(rc,0); // JME - drawPath(FillAndStroke); -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::ellipse(double cx, double cy, double rx, double ry) -{ - m_path.remove_all(); - agg::bezier_arc arc(cx, cy, rx, ry, 0, 2*pi()); - //m_path.add_path(arc, 0, false); - m_path.concat_path(arc,0); // JME - m_path.close_polygon(); - drawPath(FillAndStroke); -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::arc(double cx, double cy, double rx, double ry, double start, double sweep) -{ - m_path.remove_all(); - agg::bezier_arc arc(cx, cy, rx, ry, start, sweep); - //m_path.add_path(arc, 0, false); - m_path.concat_path(arc,0); // JME - drawPath(StrokeOnly); -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::star(double cx, double cy, double r1, double r2, double startAngle, int numRays) -{ - m_path.remove_all(); - double da = agg::pi / double(numRays); - double a = startAngle; - int i; - for (i = 0; i < numRays; i++) - { - double x = cos(a) * r2 + cx; - double y = sin(a) * r2 + cy; - if (i) m_path.line_to(x, y); - else m_path.move_to(x, y); - a += da; - m_path.line_to(cos(a) * r1 + cx, sin(a) * r1 + cy); - a += da; - } - closePolygon(); - drawPath(FillAndStroke); -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::curve(double x1, double y1, double x2, double y2, double x3, double y3) -{ - m_path.remove_all(); - m_path.move_to(x1, y1); - m_path.curve3(x2, y2, x3, y3); - drawPath(StrokeOnly); -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::curve(double x1, double y1, double x2, double y2, double x3, double y3, double x4, double y4) -{ - m_path.remove_all(); - m_path.move_to(x1, y1); - m_path.curve4(x2, y2, x3, y3, x4, y4); - drawPath(StrokeOnly); -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::polygon(double* xy, int numPoints) -{ - m_path.remove_all(); - //m_path.add_poly(xy, numPoints); - m_path.concat_poly(xy,numPoints,true); // JME, AF - closePolygon(); - drawPath(FillAndStroke); -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::polyline(double* xy, int numPoints) -{ - m_path.remove_all(); - //m_path.add_poly(xy, numPoints); - m_path.concat_poly(xy,numPoints,true); // JME, AF - drawPath(StrokeOnly); -} - - -//------------------------------------------------------------------------ - -#ifdef AGG2D_USE_VECTORFONTS -AGG2D_TEMPLATE void TAGG2D::flipText(bool flip) -{ - m_fontEngine.flip_y(flip); -} - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::font(const char* fontName, - double height, - bool bold, - bool italic, - FontCacheType ch, - double angle) -{ - m_textAngle = angle; - m_fontHeight = height; - m_fontCacheType = ch; - - -#ifdef AGG2D_USE_FREETYPE - m_fontEngine.load_font(fontName, - 0, - (ch == VectorFontCache) ? - agg::glyph_ren_outline : - agg::glyph_ren_agg_gray8); - m_fontEngine.hinting(m_textHints); - m_fontEngine.height((ch == VectorFontCache) ? height : worldToScreen(height)); -#else - m_fontEngine.hinting(m_textHints); - - m_fontEngine.create_font(fontName, - (ch == VectorFontCache) ? - agg::glyph_ren_outline : - agg::glyph_ren_agg_gray8, - (ch == VectorFontCache) ? height : worldToScreen(height), - 0.0, - bold ? 700 : 400, - italic); -#endif - -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE double TAGG2D::fontHeight() const -{ - return m_fontHeight; -} - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE double TAGG2D::fontAscent() const -{ - return m_fontAscent; -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::textAlignment(TextAlignment alignX, TextAlignment alignY) -{ - m_textAlignX = alignX; - m_textAlignY = alignY; -} - -//------------------------------------------------------------------------ - -AGG2D_TEMPLATE double TAGG2D::textWidth(const char* str, unsigned int len) -{ -#if defined( UNDER_CE ) - return 0; -#else - double x = 0; - double y = 0; - bool first = true; - while(*str && len) - { - const agg::glyph_cache* glyph = m_fontCacheManager.glyph(*str); - if(glyph) - { - if(!first) m_fontCacheManager.add_kerning(&x, &y); - x += glyph->advance_x; - y += glyph->advance_y; - first = true; - } - ++str; --len; - } - return (m_fontCacheType == VectorFontCache) ? x : screenToWorld(x); -#endif -} - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE double TAGG2D::textWidth(const wchar_t* str, unsigned int len) -{ -#if defined( UNDER_CE ) - return 0; -#else - double x = 0; - double y = 0; - bool first = true; - while(*str && len) - { - const agg::glyph_cache* glyph = m_fontCacheManager.glyph(*str); - if(glyph) - { - if(!first) m_fontCacheManager.add_kerning(&x, &y); - x += glyph->advance_x; - y += glyph->advance_y; - first = true; - } - ++str; --len; - } - return (m_fontCacheType == VectorFontCache) ? x : screenToWorld(x); -#endif -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE bool TAGG2D::textHints() const -{ - return m_textHints; -} - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::textHints(bool hints) -{ - m_textHints = hints; -} - - - -//------------------------------------------------------------------------ - -AGG2D_TEMPLATE void TAGG2D::text(double x, double y, const char* str, unsigned int len, bool roundOff, double ddx, double ddy) -{ - - double dx = 0.0; - double dy = 0.0; - - switch(m_textAlignX) - { - case AlignCenter: dx = -textWidth(str,len) * 0.5; break; - case AlignRight: dx = -textWidth(str,len); break; - default: break; - } - - - double asc = fontHeight(); - const agg::glyph_cache* glyph = m_fontCacheManager.glyph('H'); - if(glyph) - { - asc = glyph->bounds.y2 - glyph->bounds.y1; - } - - if(m_fontCacheType == RasterFontCache) - { - asc = screenToWorld(asc); - } - - switch(m_textAlignY) - { - case AlignCenter: dy = -asc * 0.5; break; - case AlignTop: dy = -asc; break; - case AlignBaseline: dy = -fontAscent(); break; - default: break; - } - - if(m_fontEngine.flip_y()) dy = -dy; - - agg::trans_affine mtx; - - double start_x = x + dx; - double start_y = y + dy; - - if (roundOff) - { - start_x = int(start_x); - start_y = int(start_y); - } - start_x += ddx; - start_y += ddy; - - mtx *= agg::trans_affine_translation(-x, -y); - mtx *= agg::trans_affine_rotation(m_textAngle); - mtx *= agg::trans_affine_translation(x, y); - - agg::conv_transform tr(m_fontCacheManager.path_adaptor(), mtx); - - if(m_fontCacheType == RasterFontCache) - { - worldToScreen(start_x, start_y); - } - - unsigned int i; - for (i = 0; i < len && str[i]; i++) - { - glyph = m_fontCacheManager.glyph(str[i]); - if(glyph) - { - if(i) m_fontCacheManager.add_kerning(&x, &y); - m_fontCacheManager.init_embedded_adaptors(glyph, start_x, start_y); - - if(glyph->data_type == agg::glyph_data_outline) - { - m_path.remove_all(); - m_path.concat_path(tr, 0); - drawPath(); - } - - if(glyph->data_type == agg::glyph_data_gray8) - { - render(m_fontCacheManager.gray8_adaptor(), - m_fontCacheManager.gray8_scanline()); - } - start_x += glyph->advance_x; - start_y += glyph->advance_y; - } - } - -} - -AGG2D_TEMPLATE void TAGG2D::text(double x, double y, const wchar_t* str, unsigned int len, bool roundOff, double ddx, double ddy) -{ - - double dx = 0.0; - double dy = 0.0; - - switch(m_textAlignX) - { - case AlignCenter: dx = -textWidth(str,len) * 0.5; break; - case AlignRight: dx = -textWidth(str,len); break; - default: break; - } - - double asc = fontHeight(); - const agg::glyph_cache* glyph = m_fontCacheManager.glyph('H'); - if(glyph) - { - asc = glyph->bounds.y2 - glyph->bounds.y1; - } - - if(m_fontCacheType == RasterFontCache) - { - asc = screenToWorld(asc); - } - - switch(m_textAlignY) - { - case AlignCenter: dy = -asc * 0.5; break; - case AlignTop: dy = -asc; break; - case AlignBaseline: dy = -fontAscent(); break; - default: break; - } - - if(m_fontEngine.flip_y()) dy = -dy; - - agg::trans_affine mtx; - - double start_x = x + dx; - double start_y = y + dy; - - if (roundOff) - { - start_x = int(start_x); - start_y = int(start_y); - } - start_x += ddx; - start_y += ddy; - - mtx *= agg::trans_affine_translation(-x, -y); - mtx *= agg::trans_affine_rotation(m_textAngle); - mtx *= agg::trans_affine_translation(x, y); - - agg::conv_transform tr(m_fontCacheManager.path_adaptor(), mtx); - - if(m_fontCacheType == RasterFontCache) - { - worldToScreen(start_x, start_y); - } - - unsigned int i; - for (i = 0; i < len && str[i]; i++) - { - glyph = m_fontCacheManager.glyph(str[i]); - if(glyph) - { - if(i) m_fontCacheManager.add_kerning(&x, &y); - m_fontCacheManager.init_embedded_adaptors(glyph, start_x, start_y); - - if(glyph->data_type == agg::glyph_data_outline) - { - m_path.remove_all(); - //m_path.add_path(tr, 0, false); - m_path.concat_path(tr,0); // JME - drawPath(); - } - - if(glyph->data_type == agg::glyph_data_gray8) - { - render(m_fontCacheManager.gray8_adaptor(), - m_fontCacheManager.gray8_scanline()); - } - start_x += glyph->advance_x; - start_y += glyph->advance_y; - } - } - -} -#endif - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::resetPath() { m_path.remove_all(); } - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::moveTo(double x, double y) -{ - m_start_x = x; - m_start_y = y; - - m_path.move_to(x, y); -} - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::moveRel(double dx, double dy) -{ - if(m_path.vertices().total_vertices()) - { - double x2; - double y2; - m_path.vertices().last_vertex(&x2, &y2); - - dx += x2; - dy += y2; - } - - moveTo(dx, dy); -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::lineTo(double x, double y) -{ - m_path.line_to(x, y); -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::lineRel(double dx, double dy) -{ - m_path.line_rel(dx, dy); -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::horLineTo(double x) -{ - m_path.hline_to(x); -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::horLineRel(double dx) -{ - m_path.hline_rel(dx); -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::verLineTo(double y) -{ - m_path.vline_to(y); -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::verLineRel(double dy) -{ - m_path.vline_rel(dy); -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::arcTo(double rx, double ry, - double angle, - bool largeArcFlag, - bool sweepFlag, - double x, double y) -{ - m_path.arc_to(rx, ry, angle, largeArcFlag, sweepFlag, x, y); -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::arcRel(double rx, double ry, - double angle, - bool largeArcFlag, - bool sweepFlag, - double dx, double dy) -{ - m_path.arc_rel(rx, ry, angle, largeArcFlag, sweepFlag, dx, dy); -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::quadricCurveTo(double xCtrl, double yCtrl, - double xTo, double yTo) -{ - m_path.curve3(xCtrl, yCtrl, xTo, yTo); -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::quadricCurveRel(double dxCtrl, double dyCtrl, - double dxTo, double dyTo) -{ - m_path.curve3_rel(dxCtrl, dyCtrl, dxTo, dyTo); -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::quadricCurveTo(double xTo, double yTo) -{ - m_path.curve3(xTo, yTo); -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::quadricCurveRel(double dxTo, double dyTo) -{ - m_path.curve3_rel(dxTo, dyTo); -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::cubicCurveTo(double xCtrl1, double yCtrl1, - double xCtrl2, double yCtrl2, - double xTo, double yTo) -{ - m_path.curve4(xCtrl1, yCtrl1, xCtrl2, yCtrl2, xTo, yTo); -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::cubicCurveRel(double dxCtrl1, double dyCtrl1, - double dxCtrl2, double dyCtrl2, - double dxTo, double dyTo) -{ - m_path.curve4_rel(dxCtrl1, dyCtrl1, dxCtrl2, dyCtrl2, dxTo, dyTo); -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::cubicCurveTo(double xCtrl2, double yCtrl2, - double xTo, double yTo) -{ - m_path.curve4(xCtrl2, yCtrl2, xTo, yTo); -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::cubicCurveRel(double xCtrl2, double yCtrl2, - double xTo, double yTo) -{ - m_path.curve4_rel(xCtrl2, yCtrl2, xTo, yTo); -} - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::addEllipse(double cx, double cy, double rx, double ry, Direction dir) -{ - agg::bezier_arc arc(cx, cy, rx, ry, 0, (dir == CCW) ? 2*pi() : -2*pi()); - //m_path.add_path(arc, 0, false); - m_path.concat_path(arc,0); // JME - m_path.close_polygon(); -} - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::closePolygon() -{ - if(agg::is_vertex(m_path.vertices().last_command())) - { - m_path.vertices().add_vertex(m_start_x, m_start_y, - agg::path_cmd_end_poly | agg::path_flags_close); - } -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::imageFilter(ImageFilter f) -{ - m_imageFilter = f; - switch(f) - { - case NoFilter: break; - case Bilinear: m_imageFilterLut.calculate(agg::image_filter_bilinear(), true); break; - case Hanning: m_imageFilterLut.calculate(agg::image_filter_hanning(), true); break; - case Hermite: m_imageFilterLut.calculate(agg::image_filter_hermite(), true); break; - case Quadric: m_imageFilterLut.calculate(agg::image_filter_quadric(), true); break; - case Bicubic: m_imageFilterLut.calculate(agg::image_filter_bicubic(), true); break; - case Catrom: m_imageFilterLut.calculate(agg::image_filter_catrom(), true); break; - case Spline16: m_imageFilterLut.calculate(agg::image_filter_spline16(), true); break; - case Spline36: m_imageFilterLut.calculate(agg::image_filter_spline36(), true); break; - case Blackman144: m_imageFilterLut.calculate(agg::image_filter_blackman144(), true); break; - } -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE Agg2DBase::ImageFilter TAGG2D::imageFilter() const -{ - return m_imageFilter; -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::imageResample(ImageResample f) -{ - m_imageResample = f; -} - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE Agg2DBase::ImageResample TAGG2D::imageResample() const -{ - return m_imageResample; -} - -//==============moved to .h file=========== - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::drawPath(DrawPathFlag flag) -{ - m_rasterizer.reset(); - switch(flag) - { - case FillOnly: - if (m_fillColor.a) - { - m_rasterizer.add_path(m_pathTransform); - render(true); - } - break; - - case StrokeOnly: - if (m_lineColor.a && m_lineWidth > 0.0) - { - m_rasterizer.add_path(m_strokeTransform); - render(false); - } - break; - - case FillAndStroke: - if (m_fillColor.a) - { - m_rasterizer.add_path(m_pathTransform); - render(true); - } - - if (m_lineColor.a && m_lineWidth > 0.0) - { - m_rasterizer.add_path(m_strokeTransform); - render(false); - } - break; - - case FillWithLineColor: - if (m_lineColor.a) - { - m_rasterizer.add_path(m_pathTransform); - render(false); - } - break; - } -} - - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE_WITH_IMAGE class Agg2DRenderer -{ -public: - typedef typename TAGG2D::Color Color; - typedef typename TIMAGE Image; - //-------------------------------------------------------------------- - template - void static render(TAGG2D& gr, BaseRenderer& renBase, SolidRenderer& renSolid, bool fillColor) - { - // JME - typedef agg::span_allocator span_allocator_type; - //- typedef agg::renderer_scanline_aa RendererLinearGradient; - typedef agg::renderer_scanline_aa RendererLinearGradient; - //- typedef agg::renderer_scanline_aa RendererRadialGradient; - typedef agg::renderer_scanline_aa RendererRadialGradient; - - if ((fillColor && gr.m_fillGradientFlag == TAGG2D::Linear) || - (!fillColor && gr.m_lineGradientFlag == TAGG2D::Linear)) - { - if (fillColor) - { - typename TAGG2D::LinearGradientSpan span(/*gr.m_allocator, */ - gr.m_fillGradientInterpolator, - gr.m_linearGradientFunction, - gr.m_fillGradient, - gr.m_fillGradientD1, - gr.m_fillGradientD2); - //-RendererLinearGradient ren(renBase,span); - RendererLinearGradient ren(renBase,gr.m_allocator,span); - agg::render_scanlines(gr.m_rasterizer, gr.m_scanline, ren); - } - else - { - typename TAGG2D::LinearGradientSpan span(/*gr.m_allocator,*/ - gr.m_lineGradientInterpolator, - gr.m_linearGradientFunction, - gr.m_lineGradient, - gr.m_lineGradientD1, - gr.m_lineGradientD2); - //- RendererLinearGradient ren(renBase, span); - RendererLinearGradient ren(renBase,gr.m_allocator,span); - agg::render_scanlines(gr.m_rasterizer, gr.m_scanline, ren); - } - } - else - { - if ((fillColor && gr.m_fillGradientFlag == TAGG2D::Radial) || - (!fillColor && gr.m_lineGradientFlag == TAGG2D::Radial)) - { - if (fillColor) - { - typename TAGG2D::RadialGradientSpan span(/*gr.m_allocator, */ - gr.m_fillGradientInterpolator, - gr.m_radialGradientFunction, - gr.m_fillGradient, - gr.m_fillGradientD1, - gr.m_fillGradientD2); - //-RendererRadialGradient ren(renBase, span); - RendererRadialGradient ren(renBase,gr.m_allocator,span); - agg::render_scanlines(gr.m_rasterizer, gr.m_scanline, ren); - } - else - { - typename TAGG2D::RadialGradientSpan span(/*gr.m_allocator,*/ - gr.m_lineGradientInterpolator, - gr.m_radialGradientFunction, - gr.m_lineGradient, - gr.m_lineGradientD1, - gr.m_lineGradientD2); - //-RendererRadialGradient ren(renBase, span); - RendererRadialGradient ren(renBase,gr.m_allocator,span); - agg::render_scanlines(gr.m_rasterizer, gr.m_scanline, ren); - } - } - else - { - renSolid.color(fillColor ? gr.m_fillColor : gr.m_lineColor); - agg::render_scanlines(gr.m_rasterizer, gr.m_scanline, renSolid); - } - } - } - - - //-------------------------------------------------------------------- - class SpanConvImageBlend - { - public: - SpanConvImageBlend(Agg2DBase::BlendMode m, Color c) : - m_mode(m), m_color(c) - {} - - void convert(Color* span, int x, int y, unsigned len) const - { - unsigned l2; - typename TAGG2D::Color* s2; - if(m_mode != TAGG2D::BlendDst) - { - l2 = len; - s2 = span; - typedef agg::comp_op_adaptor_clip_to_dst_rgba_pre OpType; - do - { - OpType::blend_pix(m_mode, - (typename TAGG2D::Color::value_type*)s2, - m_color.r, - m_color.g, - m_color.b, - TAGG2D::Color::base_mask, - agg::cover_full); - ++s2; - } - while(--l2); - } - if(m_color.a < TAGG2D::Color::base_mask) - { - l2 = len; - s2 = span; - unsigned a = m_color.a; - do - { - s2->r = (s2->r * a) >> TAGG2D::Color::base_shift; - s2->g = (s2->g * a) >> TAGG2D::Color::base_shift; - s2->b = (s2->b * a) >> TAGG2D::Color::base_shift; - s2->a = (s2->a * a) >> TAGG2D::Color::base_shift; - ++s2; - } - while(--l2); - } - } - - private: - Agg2DBase::BlendMode m_mode; - Color m_color; - }; - - - - - //-------------------------------------------------------------------- - template - void static render(TAGG2D& gr, BaseRenderer& renBase, SolidRenderer& renSolid, Rasterizer& ras, Scanline& sl) - { - // JME - typedef agg::span_allocator span_allocator_type; - typedef agg::renderer_scanline_aa RendererLinearGradient; - typedef agg::renderer_scanline_aa RendererRadialGradient; - - if(gr.m_fillGradientFlag == TAGG2D::Linear) - { - typename TAGG2D::LinearGradientSpan span( - gr.m_fillGradientInterpolator, - gr.m_linearGradientFunction, - gr.m_fillGradient, - gr.m_fillGradientD1, - gr.m_fillGradientD2); - RendererLinearGradient ren(renBase,gr.m_allocator,span); - agg::render_scanlines(ras, sl, ren); - } - else - { - if(gr.m_fillGradientFlag == TAGG2D::Radial) - { - typename TAGG2D::RadialGradientSpan span( - gr.m_fillGradientInterpolator, - gr.m_radialGradientFunction, - gr.m_fillGradient, - gr.m_fillGradientD1, - gr.m_fillGradientD2); - RendererRadialGradient ren(renBase,gr.m_allocator,span); - agg::render_scanlines(ras, sl, ren); - } - else - { - renSolid.color(gr.m_fillColor); - agg::render_scanlines(ras, sl, renSolid); - } - } - } - - - - //-------------------------------------------------------------------- - //! JME - this is where the bulk of the changes have taken place. - template - static void renderImage(TAGG2D& gr, const TIMAGE& img, - BaseRenderer& renBase, Interpolator& interpolator) - { - //! JME - have not quite figured which part of this is not const-correct - // hence the cast. - Image& imgc = const_cast(img); - typename ImagePixFormatSet::PixFormat img_pixf(imgc.renBuf); - typedef agg::image_accessor_clone img_source_type; - img_source_type source(img_pixf); - - SpanConvImageBlend blend(gr.m_imageBlendMode, gr.m_imageBlendColor); - if(gr.m_imageFilter == TAGG2D::NoFilter) - { - - //modifications less quality more speed - - typedef agg::span_image_filter_rgba_nn SpanGenType; - //typedef agg::span_converter SpanConvType; - typedef agg::renderer_scanline_aa RendererType; - //typedef agg::renderer_scanline_bin RendererType; - - SpanGenType sg(source,interpolator); - //SpanConvType sc(sg, blend); - RendererType ri(renBase,gr.m_allocator,sg); - agg::render_scanlines(gr.m_rasterizer, gr.m_scanline, ri); - } - else - { - bool resample = (gr.m_imageResample == TAGG2D::ResampleAlways); - if(gr.m_imageResample == TAGG2D::ResampleOnZoomOut) - { - double sx, sy; - interpolator.transformer().scaling_abs(&sx, &sy); - if (sx > 1.125 || sy > 1.125) - { - resample = true; - } - } - - if(resample) - { - typedef agg::span_image_resample_rgba_affine SpanGenType; - typedef agg::span_converter SpanConvType; - typedef agg::renderer_scanline_aa RendererType; - - SpanGenType sg(source,interpolator,gr.m_imageFilterLut); - SpanConvType sc(sg, blend); - RendererType ri(renBase,gr.m_allocator,sg); - agg::render_scanlines(gr.m_rasterizer, gr.m_scanline, ri); - } - else - { - // this is the AGG2D default - if(gr.m_imageFilter == TAGG2D::Bilinear) - { - typedef agg::span_image_filter_rgba_bilinear SpanGenType; - typedef agg::span_converter SpanConvType; - typedef agg::renderer_scanline_aa RendererType; - - SpanGenType sg(source,interpolator); - SpanConvType sc(sg, blend); - RendererType ri(renBase,gr.m_allocator,sg); - agg::render_scanlines(gr.m_rasterizer, gr.m_scanline, ri); - } - else - { - if(gr.m_imageFilterLut.diameter() == 2) - { - typedef agg::span_image_filter_rgba_2x2 SpanGenType; - typedef agg::span_converter SpanConvType; - typedef agg::renderer_scanline_aa RendererType; - - SpanGenType sg(source,interpolator,gr.m_imageFilterLut); - SpanConvType sc(sg, blend); - RendererType ri(renBase,gr.m_allocator,sg); - agg::render_scanlines(gr.m_rasterizer, gr.m_scanline, ri); - } - else - { - typedef agg::span_image_filter_rgba SpanGenType; - typedef agg::span_converter SpanConvType; - typedef agg::renderer_scanline_aa RendererType; - SpanGenType sg(source,interpolator,gr.m_imageFilterLut); - SpanConvType sc(sg, blend); - RendererType ri(renBase,gr.m_allocator,sg); - agg::render_scanlines(gr.m_rasterizer, gr.m_scanline, ri); - } - } - } - } - } -}; - - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::render(bool fillColor) -{ - if(m_blendMode == BlendAlpha) - { - TAGG2DRENDERER::render(*this, m_renBase, m_renSolid, fillColor); - } - else - { - TAGG2DRENDERER::render(*this, m_renBaseComp, m_renSolidComp, fillColor); - } -} - -#ifdef AGG2D_USE_VECTORFONTS -#if !defined( UNDER_CE ) - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::render(FontRasterizer& ras, FontScanline& sl) -{ - if(m_blendMode == BlendAlpha) - { - Agg2DRenderer::render(*this, m_renBase, m_renSolid, ras, sl); - } - else - { - Agg2DRenderer::render(*this, m_renBaseComp, m_renSolidComp, ras, sl); - } -} - -#endif -#endif - -//------------------------------------------------------------------------ -struct Agg2DRasterizerGamma -{ - - Agg2DRasterizerGamma(double alpha, double gamma) : - m_alpha(alpha), m_gamma(gamma) {} - - double operator() (double x) const - { - return m_alpha(m_gamma(x)); - } - agg::gamma_multiply m_alpha; - agg::gamma_power m_gamma; -}; - -//------------------------------------------------------------------------ -AGG2D_TEMPLATE void TAGG2D::updateRasterizerGamma() -{ - m_rasterizer.gamma(Agg2DRasterizerGamma(m_masterAlpha, m_antiAliasGamma)); -} - diff --git a/desmume/src/aggdraw.cpp b/desmume/src/aggdraw.cpp deleted file mode 100644 index e83be5986..000000000 --- a/desmume/src/aggdraw.cpp +++ /dev/null @@ -1,699 +0,0 @@ -//The MIT License -// -//Copyright (c) 2009 DeSmuME team -// -//Permission is hereby granted, free of charge, to any person obtaining a copy -//of this software and associated documentation files (the "Software"), to deal -//in the Software without restriction, including without limitation the rights -//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -//copies of the Software, and to permit persons to whom the Software is -//furnished to do so, subject to the following conditions: -// -//The above copyright notice and this permission notice shall be included in -//all copies or substantial portions of the Software. -// -//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -//IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -//FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -//AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -//LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -//OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -//THE SOFTWARE. - -#include - -#include "GPU.h" -#include "NDSSystem.h" - -#include "aggdraw.h" - -#include "agg_renderer_base.h" -#include "agg_renderer_primitives.h" -#include "agg_renderer_scanline.h" -#include "agg_bounding_rect.h" -#include "agg_trans_affine.h" -#include "agg_path_storage.h" -#include "agg_color_rgba.h" - -#include "agg_pixfmt_rgb.h" -#include "agg_pixfmt_rgba.h" -#include "agg_pixfmt_rgb_packed.h" - -#include "agg_rasterizer_scanline_aa.h" -#include "agg_scanline_u.h" -#include "agg_renderer_scanline.h" -#include "agg_scanline_p.h" - -//raster text -#include "agg_glyph_raster_bin.h" -#include "agg_embedded_raster_fonts.h" -#include "agg_renderer_raster_text.h" - -#include "ctrl/agg_bezier_ctrl.h" -#include "platform/agg_platform_support.h" -#include "agg_pattern_filters_rgba.h" -#include "agg_renderer_outline_image.h" -#include "agg_rasterizer_outline_aa.h" - -#include "agg_image_accessors.h" -#include "agg_span_interpolator_linear.h" -#include "agg_span_image_filter_rgb.h" -#include "agg_span_image_filter_rgba.h" -#include "agg_span_image_filter_gray.h" - -#include "agg_span_allocator.h" - -namespace agg -{ - //NOTE - these blenders are necessary to change the rgb order from the defaults, which are incorrect for us - - //this custom blender does more correct blending math than the default - //which is necessary or else drawing transparent pixels on (31,31,31) will yield (30,30,30) - struct my_blender_rgb555_pre - { - typedef rgba8 color_type; - typedef color_type::value_type value_type; - typedef color_type::calc_type calc_type; - typedef int16u pixel_type; - - static AGG_INLINE void blend_pix(pixel_type* p, - unsigned cr, unsigned cg, unsigned cb, - unsigned alpha, - unsigned cover) - { - //not sure whether this is right... - alpha = color_type::base_mask - alpha; - pixel_type rgb = *p; - calc_type b = (rgb >> 10) & 31; - calc_type g = (rgb >> 5) & 31; - calc_type r = (rgb ) & 31; - b = ((b+1)*(alpha+1) + (cb)*(cover)-1)>>8; - g = ((g+1)*(alpha+1) + (cg)*(cover)-1)>>8; - r = ((r+1)*(alpha+1) + (cr)*(cover)-1)>>8; - *p = (b<<10)|(g<<5)|r; - } - - static AGG_INLINE pixel_type make_pix(unsigned r, unsigned g, unsigned b) - { - return (pixel_type)(((b & 0xF8) << 7) | - ((g & 0xF8) << 2) | - (r >> 3) | 0x8000); - } - - static AGG_INLINE color_type make_color(pixel_type p) - { - return color_type((p << 3) & 0xF8, - (p >> 2) & 0xF8, - (p >> 7) & 0xF8); - } - }; - - struct my_blender_rgb555 - { - typedef rgba8 color_type; - typedef color_type::value_type value_type; - typedef color_type::calc_type calc_type; - typedef int16u pixel_type; - - static AGG_INLINE void blend_pix(pixel_type* p, - unsigned cr, unsigned cg, unsigned cb, - unsigned alpha, - unsigned) - { - pixel_type rgb = *p; - calc_type b = (rgb >> 7) & 0xF8; - calc_type g = (rgb >> 2) & 0xF8; - calc_type r = (rgb << 3) & 0xF8; - *p = (pixel_type) - (((((cb - b) * alpha + (b << 8)) >> 1) & 0x7C00) | - ((((cg - g) * alpha + (g << 8)) >> 6) & 0x03E0) | - (((cr - r) * alpha + (r << 8)) >> 11) | 0x8000); - } - - static AGG_INLINE pixel_type make_pix(unsigned r, unsigned g, unsigned b) - { - return (pixel_type)(((b & 0xF8) << 7) | - ((g & 0xF8) << 2) | - (r >> 3) | 0x8000); - } - - static AGG_INLINE color_type make_color(pixel_type p) - { - return color_type((p << 3) & 0xF8, - (p >> 2) & 0xF8, - (p >> 7) & 0xF8); - - } - }; - - - typedef pixfmt_alpha_blend_rgb_packed my_pixfmt_rgb555_pre; //----pixfmt_rgb555_pre - - typedef pixfmt_alpha_blend_rgb_packed my_pixfmt_rgb555; //----pixfmt_rgb555_pre -} - - - - -typedef std::map TAgg_Font_Table; -static TAgg_Font_Table font_table; - -const agg::int8u* AggDrawTarget::lookupFont(const std::string& name) -{ - TAgg_Font_Table::iterator it(font_table.find(name)); - if(it == font_table.end()) return NULL; - else return it->second; -} - -static void Agg_init_fonts() -{ - struct font_type - { - const agg::int8u* font; - const char* name; - } - fonts[] = - { - { agg::gse4x6, "gse4x6" }, - { agg::gse4x8, "gse4x8" }, - { agg::gse5x7, "gse5x7" }, - { agg::gse5x9, "gse5x9" }, - { agg::gse6x9, "gse6x9" }, - { agg::gse6x12, "gse6x12" }, - { agg::gse7x11, "gse7x11" }, - { agg::gse7x11_bold, "gse7x11_bold" }, - { agg::gse7x15, "gse7x15" }, - { agg::gse7x15_bold, "gse7x15_bold" }, - { agg::gse8x16, "gse8x16" }, - { agg::gse8x16_bold, "gse8x16_bold" }, - { agg::mcs11_prop, "mcs11_prop" }, - { agg::mcs11_prop_condensed, "mcs11_prop_condensed" }, - { agg::mcs12_prop, "mcs12_prop" }, - { agg::mcs13_prop, "mcs13_prop" }, - { agg::mcs5x10_mono, "mcs5x10_mono" }, - { agg::mcs5x11_mono, "mcs5x11_mono" }, - { agg::mcs6x10_mono, "mcs6x10_mono" }, - { agg::mcs6x11_mono, "mcs6x11_mono" }, - { agg::mcs7x12_mono_high, "mcs7x12_mono_high" }, - { agg::mcs7x12_mono_low, "mcs7x12_mono_low" }, - { agg::verdana12, "verdana12" }, - { agg::verdana12_bold, "verdana12_bold" }, - { agg::verdana13, "verdana13" }, - { agg::verdana13_bold, "verdana13_bold" }, - { agg::verdana14, "verdana14" }, - { agg::verdana14_bold, "verdana14_bold" }, - { agg::verdana16, "verdana16" }, - { agg::verdana16_bold, "verdana16_bold" }, - { agg::verdana17, "verdana17" }, - { agg::verdana17_bold, "verdana17_bold" }, - { agg::verdana18, "verdana18" }, - { agg::verdana18_bold, "verdana18_bold" }, - }; - - for(int i=0;i > T_AGG_RGB555; -typedef AggDrawTargetImplementation > T_AGG_RGBA; - -T_AGG_RGB555 agg_targetScreen(GPU_screen, 256, 384, 512); - -static u32 luaBuffer[256*192*2]; -T_AGG_RGBA agg_targetLua((u8*)luaBuffer, 256, 384, 1024); - -static u32 hudBuffer[256*192*2]; -T_AGG_RGBA agg_targetHud((u8*)hudBuffer, 256, 384, 1024); - -static AggDrawTarget* targets[] = { - &agg_targetScreen, - &agg_targetScreen, //THATS RIGHT! for now, hud maps to screen - &agg_targetLua, -}; - -void Agg_init() -{ - Agg_init_fonts(); - aggDraw.target = targets[0]; - aggDraw.screen = targets[0]; - aggDraw.hud = targets[1]; - aggDraw.lua = targets[2]; - - aggDraw.hud->setFont("verdana18_bold"); -} - -void AggDraw_Desmume::setTarget(AggTarget newTarget) -{ - target = targets[newTarget]; -} - -//this code would do compositing.. and maybe it will.. one day. but not for now. -//void AggDraw_Desmume::composite(void* dest) -//{ -// T_AGG_RGB555 target((u8*)dest, 256, 384, 512); -// -// ctr = 0; -// -// //if lua is nonempty, blend it -// if(!agg_targetLua.empty) -// { -// T_AGG_RGBA::MyImage luaImage(agg_targetLua.buf()); -// target.transformImage(luaImage, 0,40,256-1,384-1); -// } -// -// //if hud is nonempty, blend it -// if(!agg_targetHud.empty) -// { -// T_AGG_RGBA::MyImage hudImage(agg_targetHud.buf()); -// target.transformImage(hudImage, 0,0,256-1,384-1); -// } -//} - -////temporary, just for testing the lib -//void AGGDraw() { -//// -// aggDraw.setTarget(AggTarget_Screen); -// -//// aggDraw.target->clear(); -//// -//// aggDraw.target->clipBox(0,0,255,383); -//// -// aggDraw.target->lineColor(0, 0, 255, 128); -// aggDraw.target->fillColor(0, 0, 255, 128); -//// //aggDraw.target->noFill(); -// aggDraw.target->lineWidth(1.0); -// aggDraw.target->roundedRect(10,30,256-10,192-10,4); -//// -//// aggDraw.target->setFont("verdana18_bold"); -//// aggDraw.target->renderText(60,60, "testing testing testing"); -//// -//// // Gradients (Aqua Buttons) -//// //======================================= -////// m_graphics.font("Verdana", 20.0, false, false, TAGG2D::VectorFontCache); -//// double xb1 = 10; -//// double yb1 = 80; -//// double xb2 = xb1 + 150; -//// double yb2 = yb1 + 36; -//// -//// aggDraw.target->fillColor(0,50,180,180); -//// aggDraw.target->lineColor(0,0,80, 255); -//// aggDraw.target->lineWidth(1.0); -//// aggDraw.target->roundedRect(xb1, yb1, xb2, yb2, 12, 18); -//// -//// aggDraw.target->lineColor(0,0,0,0); -//// aggDraw.target->fillLinearGradient(xb1, yb1, xb1, yb1+30, -//// agg::rgba8(100,200,255,255), -//// agg::rgba8(255,255,255,0)); -//// aggDraw.target->roundedRect(xb1+3, yb1+2.5, xb2-3, yb1+30, 9, 18, 1, 1); -//// -//// aggDraw.target->fillColor(0,0,50, 200); -//// aggDraw.target->noLine(); -/////* m_graphics.textAlignment(TAGG2D::AlignCenter, TAGG2D::AlignCenter); -//// m_graphics.text((xb1 + xb2) / 2.0, (yb1 + yb2) / 2.0, "Aqua Button", true, 0.0, 0.0); -////*/ -//// aggDraw.target->fillLinearGradient(xb1, yb2-20, xb1, yb2-3, -//// agg::rgba8(0, 0, 255,0), -//// agg::rgba8(100,255,255,255)); -//// aggDraw.target->roundedRect(xb1+3, yb2-20, xb2-3, yb2-2, 1, 1, 9, 18); -//// -//// // Basic Shapes -- Ellipse -//// //=========================================== -//// aggDraw.target->lineWidth(3.5); -//// aggDraw.target->lineColor(20, 80, 80); -//// aggDraw.target->fillColor(200, 255, 80, 200); -//// aggDraw.target->ellipse(150, 200, 50, 90); -//// -//// // Paths -//// //=========================================== -//// aggDraw.target->resetPath(); -//// aggDraw.target->fillColor(255, 0, 0, 100); -//// aggDraw.target->lineColor(0, 0, 255, 100); -//// aggDraw.target->lineWidth(2); -//// aggDraw.target->moveTo(300/2, 200/2); -//// aggDraw.target->horLineRel(-150/2); -//// aggDraw.target->arcRel(150/2, 150/2, 0, 1, 0, 150/2, -150/2); -//// aggDraw.target->closePolygon(); -//// aggDraw.target->drawPath(); -//// -//// aggDraw.target->resetPath(); -//// aggDraw.target->fillColor(255, 255, 0, 100); -//// aggDraw.target->lineColor(0, 0, 255, 100); -//// aggDraw.target->lineWidth(2); -//// aggDraw.target->moveTo(275/2, 175/2); -//// aggDraw.target->verLineRel(-150/2); -//// aggDraw.target->arcRel(150/2, 150/2, 0, 0, 0, -150/2, 150/2); -//// aggDraw.target->closePolygon(); -//// aggDraw.target->drawPath(); -//// -//// aggDraw.target->resetPath(); -//// aggDraw.target->noFill(); -//// aggDraw.target->lineColor(127, 0, 0); -//// aggDraw.target->lineWidth(5); -//// aggDraw.target->moveTo(600/2, 350/2); -//// aggDraw.target->lineRel(50/2, -25/2); -//// aggDraw.target->arcRel(25/2, 25/2, aggDraw.target->deg2Rad(-30), 0, 1, 50/2, -25/2); -//// aggDraw.target->lineRel(50/2, -25/2); -//// aggDraw.target->arcRel(25/2, 50/2, aggDraw.target->deg2Rad(-30), 0, 1, 50/2, -25/2); -//// aggDraw.target->lineRel(50/2, -25/2); -//// aggDraw.target->arcRel(25/2, 75/2, aggDraw.target->deg2Rad(-30), 0, 1, 50/2, -25/2); -//// aggDraw.target->lineRel(50, -25); -//// aggDraw.target->arcRel(25/2, 100/2, aggDraw.target->deg2Rad(-30), 0, 1, 50/2, -25/2); -//// aggDraw.target->lineRel(50/2, -25/2); -//// aggDraw.target->drawPath(); -//} -//// - - -// -////======================== -////testing stufff -// -//int width = 256; -//int height = 384; -// -//Agg2D m_graphics; -// -//void AGGDraw(unsigned char * buffer) -// { -// m_graphics.attach(buffer, -// 256, -// 384, -// 512); -// -// m_graphics.clearAll(255, 255, 255); -// //m_graphics.clearAll(0, 0, 0); -// -// //m_graphics.blendMode(TAGG2D::BlendSub); -// //m_graphics.blendMode(TAGG2D::BlendAdd); -// -// m_graphics.antiAliasGamma(1.4); -// -// // Set flipText(true) if you have the Y axis upside down. -// //m_graphics.flipText(true); -// -// -// // ClipBox. -// //m_graphics.clipBox(50, 50, rbuf_window().width() - 50, rbuf_window().height() - 50); -// -// // Transfornations - Rotate around (300,300) to 5 degree -// //m_graphics.translate(-300, -300); -// //m_graphics.rotate(TAGG2D::deg2Rad(5.0)); -// //m_graphics.translate(300, 300); -// -// // Viewport - set 0,0,600,600 to the actual window size -// // preserving aspect ratio and placing the viewport in the center. -// // To ignore aspect ratio use TAGG2D::Anisotropic -// // Note that the viewport just adds transformations to the current -// // affine matrix. So that, set the viewport *after* all transformations! -// m_graphics.viewport(0, 0, 600, 600, -// 0, 0, width, height, -// //TAGG2D::Anisotropic); -// TAGG2D::XMidYMid); -// -// -// // Rounded Rect -// m_graphics.lineColor(0, 0, 0); -// m_graphics.noFill(); -// m_graphics.roundedRect(0.5, 0.5, 600-0.5, 600-0.5, 20.0); -///* -// -// // Reglar Text -// m_graphics.font("Times New Roman", 14.0, false, false); -// m_graphics.fillColor(0, 0, 0); -// m_graphics.noLine(); -// m_graphics.text(100, 20, "Regular Raster Text -- Fast, but can't be rotated"); -// -// // Outlined Text -// m_graphics.font("Times New Roman", 50.0, false, false, TAGG2D::VectorFontCache); -// m_graphics.lineColor(50, 0, 0); -// m_graphics.fillColor(180, 200, 100); -// m_graphics.lineWidth(1.0); -// m_graphics.text(100.5, 50.5, "Outlined Text"); -// -// // Text Alignment -// m_graphics.line(250.5-150, 150.5, 250.5+150, 150.5); -// m_graphics.line(250.5, 150.5-20, 250.5, 150.5+20); -// m_graphics.line(250.5-150, 200.5, 250.5+150, 200.5); -// m_graphics.line(250.5, 200.5-20, 250.5, 200.5+20); -// m_graphics.line(250.5-150, 250.5, 250.5+150, 250.5); -// m_graphics.line(250.5, 250.5-20, 250.5, 250.5+20); -// m_graphics.line(250.5-150, 300.5, 250.5+150, 300.5); -// m_graphics.line(250.5, 300.5-20, 250.5, 300.5+20); -// m_graphics.line(250.5-150, 350.5, 250.5+150, 350.5); -// m_graphics.line(250.5, 350.5-20, 250.5, 350.5+20); -// m_graphics.line(250.5-150, 400.5, 250.5+150, 400.5); -// m_graphics.line(250.5, 400.5-20, 250.5, 400.5+20); -// m_graphics.line(250.5-150, 450.5, 250.5+150, 450.5); -// m_graphics.line(250.5, 450.5-20, 250.5, 450.5+20); -// m_graphics.line(250.5-150, 500.5, 250.5+150, 500.5); -// m_graphics.line(250.5, 500.5-20, 250.5, 500.5+20); -// m_graphics.line(250.5-150, 550.5, 250.5+150, 550.5); -// m_graphics.line(250.5, 550.5-20, 250.5, 550.5+20); -//*/ -///* -// m_graphics.fillColor(100, 50, 50); -// m_graphics.noLine(); -// //m_graphics.textHints(false); -// m_graphics.font("Times New Roman", 40.0, false, false, TAGG2D::VectorFontCache); -// -// m_graphics.textAlignment(TAGG2D::AlignLeft, TAGG2D::AlignBottom); -// m_graphics.text(250.0, 150.0, "Left-Bottom", true, 0, 0); -// -// m_graphics.textAlignment(TAGG2D::AlignCenter, TAGG2D::AlignBottom); -// m_graphics.text(250.0, 200.0, "Center-Bottom", true, 0, 0); -// -// m_graphics.textAlignment(TAGG2D::AlignRight, TAGG2D::AlignBottom); -// m_graphics.text(250.0, 250.0, "Right-Bottom", true, 0, 0); -// -// m_graphics.textAlignment(TAGG2D::AlignLeft, TAGG2D::AlignCenter); -// m_graphics.text(250.0, 300.0, "Left-Center", true, 0, 0); -// -// m_graphics.textAlignment(TAGG2D::AlignCenter, TAGG2D::AlignCenter); -// m_graphics.text(250.0, 350.0, "Center-Center", true, 0, 0); -// -// m_graphics.textAlignment(TAGG2D::AlignRight, TAGG2D::AlignCenter); -// m_graphics.text(250.0, 400.0, "Right-Center", true, 0, 0); -// -// m_graphics.textAlignment(TAGG2D::AlignLeft, TAGG2D::AlignTop); -// m_graphics.text(250.0, 450.0, "Left-Top", true, 0, 0); -// -// m_graphics.textAlignment(TAGG2D::AlignCenter, TAGG2D::AlignTop); -// m_graphics.text(250.0, 500.0, "Center-Top", true, 0, 0); -// -// m_graphics.textAlignment(TAGG2D::AlignRight, TAGG2D::AlignTop); -// m_graphics.text(250.0, 550.0, "Right-Top", true, 0, 0); -// -//*/ -// // Gradients (Aqua Buttons) -// //======================================= -// m_graphics.font("Verdana", 20.0, false, false, TAGG2D::VectorFontCache); -// double xb1 = 400; -// double yb1 = 80; -// double xb2 = xb1 + 150; -// double yb2 = yb1 + 36; -// -// m_graphics.fillColor(TAGG2D::Color(0,50,180,180)); -// m_graphics.lineColor(TAGG2D::Color(0,0,80, 255)); -// m_graphics.lineWidth(1.0); -// m_graphics.roundedRect(xb1, yb1, xb2, yb2, 12, 18); -// -// m_graphics.lineColor(TAGG2D::Color(0,0,0,0)); -// m_graphics.fillLinearGradient(xb1, yb1, xb1, yb1+30, -// TAGG2D::Color(100,200,255,255), -// TAGG2D::Color(255,255,255,0)); -// m_graphics.roundedRect(xb1+3, yb1+2.5, xb2-3, yb1+30, 9, 18, 1, 1); -// -// m_graphics.fillColor(TAGG2D::Color(0,0,50, 200)); -// m_graphics.noLine(); -///* m_graphics.textAlignment(TAGG2D::AlignCenter, TAGG2D::AlignCenter); -// m_graphics.text((xb1 + xb2) / 2.0, (yb1 + yb2) / 2.0, "Aqua Button", true, 0.0, 0.0); -//*/ -// m_graphics.fillLinearGradient(xb1, yb2-20, xb1, yb2-3, -// TAGG2D::Color(0, 0, 255,0), -// TAGG2D::Color(100,255,255,255)); -// m_graphics.roundedRect(xb1+3, yb2-20, xb2-3, yb2-2, 1, 1, 9, 18); -// -// -// // Aqua Button Pressed -// xb1 = 400; -// yb1 = 30; -// xb2 = xb1 + 150; -// yb2 = yb1 + 36; -// -// m_graphics.fillColor(TAGG2D::Color(0,50,180,180)); -// m_graphics.lineColor(TAGG2D::Color(0,0,0, 255)); -// m_graphics.lineWidth(2.0); -// m_graphics.roundedRect(xb1, yb1, xb2, yb2, 12, 18); -// -// m_graphics.lineColor(TAGG2D::Color(0,0,0,0)); -// m_graphics.fillLinearGradient(xb1, yb1+2, xb1, yb1+25, -// TAGG2D::Color(60, 160,255,255), -// TAGG2D::Color(100,255,255,0)); -// m_graphics.roundedRect(xb1+3, yb1+2.5, xb2-3, yb1+30, 9, 18, 1, 1); -// -// m_graphics.fillColor(TAGG2D::Color(0,0,50, 255)); -// m_graphics.noLine(); -///* m_graphics.textAlignment(TAGG2D::AlignCenter, TAGG2D::AlignCenter); -// m_graphics.text((xb1 + xb2) / 2.0, (yb1 + yb2) / 2.0, "Aqua Pressed", 0.0, 0.0); -//*/ -// m_graphics.fillLinearGradient(xb1, yb2-25, xb1, yb2-5, -// TAGG2D::Color(0, 180,255,0), -// TAGG2D::Color(0, 200,255,255)); -// m_graphics.roundedRect(xb1+3, yb2-25, xb2-3, yb2-2, 1, 1, 9, 18); -// -// -// -// -// // Basic Shapes -- Ellipse -// //=========================================== -// m_graphics.lineWidth(3.5); -// m_graphics.lineColor(20, 80, 80); -// m_graphics.fillColor(200, 255, 80, 200); -// m_graphics.ellipse(450, 200, 50, 90); -// -// -// // Paths -// //=========================================== -// m_graphics.resetPath(); -// m_graphics.fillColor(255, 0, 0, 100); -// m_graphics.lineColor(0, 0, 255, 100); -// m_graphics.lineWidth(2); -// m_graphics.moveTo(300/2, 200/2); -// m_graphics.horLineRel(-150/2); -// m_graphics.arcRel(150/2, 150/2, 0, 1, 0, 150/2, -150/2); -// m_graphics.closePolygon(); -// m_graphics.drawPath(); -// -// m_graphics.resetPath(); -// m_graphics.fillColor(255, 255, 0, 100); -// m_graphics.lineColor(0, 0, 255, 100); -// m_graphics.lineWidth(2); -// m_graphics.moveTo(275/2, 175/2); -// m_graphics.verLineRel(-150/2); -// m_graphics.arcRel(150/2, 150/2, 0, 0, 0, -150/2, 150/2); -// m_graphics.closePolygon(); -// m_graphics.drawPath(); -// -// -// m_graphics.resetPath(); -// m_graphics.noFill(); -// m_graphics.lineColor(127, 0, 0); -// m_graphics.lineWidth(5); -// m_graphics.moveTo(600/2, 350/2); -// m_graphics.lineRel(50/2, -25/2); -// m_graphics.arcRel(25/2, 25/2, TAGG2D::deg2Rad(-30), 0, 1, 50/2, -25/2); -// m_graphics.lineRel(50/2, -25/2); -// m_graphics.arcRel(25/2, 50/2, TAGG2D::deg2Rad(-30), 0, 1, 50/2, -25/2); -// m_graphics.lineRel(50/2, -25/2); -// m_graphics.arcRel(25/2, 75/2, TAGG2D::deg2Rad(-30), 0, 1, 50/2, -25/2); -// m_graphics.lineRel(50, -25); -// m_graphics.arcRel(25/2, 100/2, TAGG2D::deg2Rad(-30), 0, 1, 50/2, -25/2); -// m_graphics.lineRel(50/2, -25/2); -// m_graphics.drawPath(); -// -// -// // Master Alpha. From now on everything will be translucent -// //=========================================== -// m_graphics.masterAlpha(0.85); -// -// -// // Image Transformations -// //=========================================== -///* TAGG2D::Image img(rbuf_img(0).buf(), -// rbuf_img(0).width(), -// rbuf_img(0).height(), -// rbuf_img(0).stride()); -// m_graphics.imageFilter(TAGG2D::Bilinear); -// -// //m_graphics.imageResample(TAGG2D::NoResample); -// //m_graphics.imageResample(TAGG2D::ResampleAlways); -// m_graphics.imageResample(TAGG2D::ResampleOnZoomOut); -// -// // Set the initial image blending operation as BlendDst, that actually -// // does nothing. -// //----------------- -// m_graphics.imageBlendMode(TAGG2D::BlendDst); -// -// -// // Transform the whole image to the destination rectangle -// //----------------- -// //m_graphics.transformImage(img, 450, 200, 595, 350); -// -// // Transform the rectangular part of the image to the destination rectangle -// //----------------- -// //m_graphics.transformImage(img, 60, 60, img.width()-60, img.height()-60, -// // 450, 200, 595, 350); -// -// // Transform the whole image to the destination parallelogram -// //----------------- -// //double parl[6] = { 450, 200, 595, 220, 575, 350 }; -// //m_graphics.transformImage(img, parl); -// -// // Transform the rectangular part of the image to the destination parallelogram -// //----------------- -// //double parl[6] = { 450, 200, 595, 220, 575, 350 }; -// //m_graphics.transformImage(img, 60, 60, img.width()-60, img.height()-60, parl); -// -// // Transform image to the destination path. The scale is determined by a rectangle -// //----------------- -// //m_graphics.resetPath(); -// //m_graphics.moveTo(450, 200); -// //m_graphics.cubicCurveTo(595, 220, 575, 350, 595, 350); -// //m_graphics.lineTo(470, 340); -// //m_graphics.transformImagePath(img, 450, 200, 595, 350); -// -// -// // Transform image to the destination path. -// // The scale is determined by a rectangle -// //----------------- -// m_graphics.resetPath(); -// m_graphics.moveTo(450, 200); -// m_graphics.cubicCurveTo(595, 220, 575, 350, 595, 350); -// m_graphics.lineTo(470, 340); -// m_graphics.transformImagePath(img, 60, 60, img.width()-60, img.height()-60, -// 450, 200, 595, 350); -// -// // Transform image to the destination path. -// // The transformation is determined by a parallelogram -// //m_graphics.resetPath(); -// //m_graphics.moveTo(450, 200); -// //m_graphics.cubicCurveTo(595, 220, 575, 350, 595, 350); -// //m_graphics.lineTo(470, 340); -// //double parl[6] = { 450, 200, 595, 220, 575, 350 }; -// //m_graphics.transformImagePath(img, parl); -// -// // Transform the rectangular part of the image to the destination path. -// // The transformation is determined by a parallelogram -// //m_graphics.resetPath(); -// //m_graphics.moveTo(450, 200); -// //m_graphics.cubicCurveTo(595, 220, 575, 350, 595, 350); -// //m_graphics.lineTo(470, 340); -// //double parl[6] = { 450, 200, 595, 220, 575, 350 }; -// //m_graphics.transformImagePath(img, 60, 60, img.width()-60, img.height()-60, parl); -//*/ -// -// // Add/Sub/Contrast Blending Modes -// m_graphics.noLine(); -// m_graphics.fillColor(70, 70, 0); -// m_graphics.blendMode(TAGG2D::BlendAdd); -// m_graphics.ellipse(500, 280, 20, 40); -// -// m_graphics.fillColor(255, 255, 255); -// m_graphics.blendMode(TAGG2D::BlendContrast); -// m_graphics.ellipse(500+40, 280, 20, 40); -// -// -// -// // Radial gradient. -// m_graphics.blendMode(TAGG2D::BlendAlpha); -// m_graphics.fillRadialGradient(400, 500, 40, -// TAGG2D::Color(255, 255, 0, 0), -// TAGG2D::Color(0, 0, 127), -// TAGG2D::Color(0, 255, 0, 0)); -// m_graphics.ellipse(400, 500, 40, 40); -// -// } -// diff --git a/desmume/src/aggdraw.h b/desmume/src/aggdraw.h deleted file mode 100644 index 3549c761c..000000000 --- a/desmume/src/aggdraw.h +++ /dev/null @@ -1,468 +0,0 @@ -//The MIT License -// -//Copyright (c) 2009 DeSmuME team -// -//Permission is hereby granted, free of charge, to any person obtaining a copy -//of this software and associated documentation files (the "Software"), to deal -//in the Software without restriction, including without limitation the rights -//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -//copies of the Software, and to permit persons to whom the Software is -//furnished to do so, subject to the following conditions: -// -//The above copyright notice and this permission notice shall be included in -//all copies or substantial portions of the Software. -// -//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -//IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -//FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -//AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -//LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -//OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -//THE SOFTWARE. - - -//This file contains code designed to be used by hud and lua systems in any emulator - - -#ifndef _AGGDRAW_H_ -#define _AGGDRAW_H_ - -#include "agg_color_rgba.h" -#include "agg_rendering_buffer.h" - -#include "agg_renderer_base.h" -#include "agg_renderer_primitives.h" -#include "agg_renderer_scanline.h" -#include "agg_bounding_rect.h" - -#include "agg_renderer_mclip.h" -#include "agg_renderer_outline_aa.h" -#include "agg_renderer_markers.h" - -#include "agg2d.h" - -typedef agg::rgba8 AggColor; - -class AggDrawTarget -{ -public: - AggDrawTarget() - : empty(true) - { - } - -protected: - void dirty() { empty = false; } - void undirty() { empty = true; } - -public: - - bool empty; - - virtual void clear() = 0; - - // Setup - virtual void attach(unsigned char* buf, unsigned width, unsigned height, int stride) = 0; -// virtual void attach(Agg2DBase::Image& img) {attach(img);}; - - virtual void clipBox(double x1, double y1, double x2, double y2) = 0; - virtual Agg2DBase::RectD clipBox() const = 0; - - virtual void clearAll(AggColor c) = 0; - virtual void clearAll(unsigned r, unsigned g, unsigned b, unsigned a = 255) = 0; - - virtual void clearClipBox(AggColor c) = 0; - virtual void clearClipBox(unsigned r, unsigned g, unsigned b, unsigned a = 255) = 0; - -// virtual unsigned width() const { return Agg2DBase::m_rbuf.width(); } -// virtual unsigned height() const { return Agg2DBase::m_rbuf.height(); } - - // Conversions - virtual void worldToScreen(double& x, double& y) const = 0; - virtual void screenToWorld(double& x, double& y) const = 0; - virtual double worldToScreen(double scalar) const = 0; - virtual double screenToWorld(double scalar) const = 0; - virtual void alignPoint(double& x, double& y) const = 0; - virtual bool inBox(double worldX, double worldY) const = 0; - - // General Attributes - virtual void blendMode(Agg2DBase::BlendMode m) = 0; - virtual Agg2DBase::BlendMode blendMode() = 0; - - virtual void imageBlendMode(Agg2DBase::BlendMode m) = 0; - virtual Agg2DBase::BlendMode imageBlendMode() = 0; - - virtual void imageBlendColor(AggColor c) = 0; - virtual void imageBlendColor(unsigned r, unsigned g, unsigned b, unsigned a = 255) = 0; - virtual AggColor imageBlendColor() = 0; - - virtual void masterAlpha(double a) = 0; - virtual double masterAlpha() = 0; - - virtual void antiAliasGamma(double g) = 0; - virtual double antiAliasGamma() = 0; - -// virtual void font(const agg::int8u* font) { m_font = font; } -// const agg::int8u* font() { return m_font; } - - virtual void fillColor(AggColor c) = 0; - virtual void fillColor(unsigned r, unsigned g, unsigned b, unsigned a = 255) = 0; - virtual void noFill() = 0; - - virtual void lineColor(AggColor c) = 0; - virtual void lineColor(unsigned r, unsigned g, unsigned b, unsigned a = 255) = 0; - virtual void noLine() = 0; - - virtual AggColor fillColor() = 0; - virtual AggColor lineColor() = 0; - - virtual void fillLinearGradient(double x1, double y1, double x2, double y2, AggColor c1, AggColor c2, double profile=1.0) = 0; - virtual void lineLinearGradient(double x1, double y1, double x2, double y2, AggColor c1, AggColor c2, double profile=1.0) = 0; - - virtual void fillRadialGradient(double x, double y, double r, AggColor c1, AggColor c2, double profile=1.0) = 0; - virtual void lineRadialGradient(double x, double y, double r, AggColor c1, AggColor c2, double profile=1.0) = 0; - - virtual void fillRadialGradient(double x, double y, double r, AggColor c1, AggColor c2, AggColor c3) = 0; - virtual void lineRadialGradient(double x, double y, double r, AggColor c1, AggColor c2, AggColor c3) = 0; - - virtual void fillRadialGradient(double x, double y, double r) = 0; - virtual void lineRadialGradient(double x, double y, double r) = 0; - - virtual void lineWidth(double w) = 0; - virtual double lineWidth() = 0; - - virtual void lineCap(Agg2DBase::LineCap cap) = 0; - virtual Agg2DBase::LineCap lineCap() = 0; - - virtual void lineJoin(Agg2DBase::LineJoin join) = 0; - virtual Agg2DBase::LineJoin lineJoin() = 0; - - virtual void fillEvenOdd(bool evenOddFlag) = 0; - virtual bool fillEvenOdd() = 0; - - // Transformations - virtual Agg2DBase::Transformations transformations() = 0; - virtual void transformations(const Agg2DBase::Transformations& tr) = 0; - - virtual const Agg2DBase::Affine& affine() = 0; -// virtual void affine(const Agg2DBase::Affine&) = 0; - - virtual void resetTransformations() = 0; - virtual void matrix(const Agg2DBase::Affine& tr) = 0; - virtual void matrix(const Agg2DBase::Transformations& tr) = 0; - virtual void rotate(double angle) = 0; - virtual void rotate(double angle, double cx, double cy) = 0; - virtual void scale(double s) = 0; - virtual void scale(double sx, double sy) = 0; - virtual void skew(double sx, double sy) = 0; - virtual void translate(double x, double y) = 0; - virtual void parallelogram(double x1, double y1, double x2, double y2, const double* para) = 0; - virtual void viewport(double worldX1, double worldY1, double worldX2, double worldY2, double screenX1, double screenY1, double screenX2, double screenY2, Agg2DBase::ViewportOption opt=Agg2DBase::XMidYMid, Agg2DBase::WindowFitLogic fl = Agg2DBase::WindowFitLogic_meet) = 0; - - // Basic Shapes - virtual void line(double x1, double y1, double x2, double y2) = 0; - virtual void triangle(double x1, double y1, double x2, double y2, double x3, double y3) = 0; - virtual void rectangle(double x1, double y1, double x2, double y2) = 0; - virtual void roundedRect(double x1, double y1, double x2, double y2, double r) = 0; - virtual void roundedRect(double x1, double y1, double x2, double y2, double rx, double ry) = 0; - virtual void roundedRect(double x1, double y1, double x2, double y2, double rxBottom, double ryBottom, double rxTop, double ryTop) = 0; - virtual void ellipse(double cx, double cy, double rx, double ry) = 0; - virtual void arc(double cx, double cy, double rx, double ry, double start, double sweep) = 0; - virtual void star(double cx, double cy, double r1, double r2, double startAngle, int numRays) = 0; - virtual void curve(double x1, double y1, double x2, double y2, double x3, double y3) = 0; - virtual void curve(double x1, double y1, double x2, double y2, double x3, double y3, double x4, double y4) = 0; - virtual void polygon(double* xy, int numPoints) = 0; - virtual void polyline(double* xy, int numPoints) = 0; - - // Path commands - virtual void resetPath() = 0; - - virtual void moveTo(double x, double y)= 0; - virtual void moveRel(double dx, double dy) = 0; - - virtual void lineTo(double x, double y) = 0; - virtual void lineRel(double dx, double dy) = 0; - - virtual void horLineTo(double x) = 0; - virtual void horLineRel(double dx) = 0; - - virtual void verLineTo(double y) = 0; - virtual void verLineRel(double dy) = 0; - - virtual void arcTo(double rx, double ry,double angle, bool largeArcFlag,bool sweepFlag,double x, double y) = 0; - - virtual void arcRel(double rx, double ry,double angle, bool largeArcFlag,bool sweepFlag,double dx, double dy) = 0; - - virtual void quadricCurveTo(double xCtrl, double yCtrl,double xTo, double yTo) = 0; - virtual void quadricCurveRel(double dxCtrl, double dyCtrl,double dxTo, double dyTo) = 0; - virtual void quadricCurveTo(double xTo, double yTo) = 0; - virtual void quadricCurveRel(double dxTo, double dyTo) = 0; - - virtual void cubicCurveTo(double xCtrl1, double yCtrl1,double xCtrl2, double yCtrl2,double xTo, double yTo) = 0; - virtual void cubicCurveRel(double dxCtrl1, double dyCtrl1,double dxCtrl2, double dyCtrl2,double dxTo, double dyTo) = 0; - virtual void cubicCurveTo(double xCtrl2, double yCtrl2,double xTo, double yTo) = 0; - virtual void cubicCurveRel(double xCtrl2, double yCtrl2,double xTo, double yTo) = 0; - - virtual void addEllipse(double cx, double cy, double rx, double ry, Agg2DBase::Direction dir) = 0; - virtual void closePolygon() = 0; - - virtual void drawPath(Agg2DBase::DrawPathFlag flag = Agg2DBase::FillAndStroke) = 0; -// virtual void drawPathNoTransform(Agg2DBase::DrawPathFlag flag = Agg2DBase::FillAndStroke) = 0; - - // Image Transformations - virtual void imageFilter(Agg2DBase::ImageFilter f) = 0; - virtual Agg2DBase::ImageFilter imageFilter() = 0; - - virtual void imageResample(Agg2DBase::ImageResample f) = 0; - virtual Agg2DBase::ImageResample imageResample() = 0; - static const agg::int8u* lookupFont(const std::string& name); - virtual void setFont(const std::string& name) = 0; - virtual void renderText(double dstX, double dstY, const std::string& str) = 0; - virtual void renderTextDropshadowed(double dstX, double dstY, const std::string& str) - { - AggColor lineColorOld = lineColor(); - lineColor(255-lineColorOld.r,255-lineColorOld.g,255-lineColorOld.b); - renderText(dstX-1,dstY-1,str); - renderText(dstX,dstY-1,str); - renderText(dstX+1,dstY-1,str); - renderText(dstX-1,dstY,str); - renderText(dstX+1,dstY,str); - renderText(dstX-1,dstY+1,str); - renderText(dstX,dstY+1,str); - renderText(dstX+1,dstY+1,str); - lineColor(lineColorOld); - renderText(dstX,dstY,str); - } - - - // Auxiliary - virtual double pi() { return agg::pi; } - virtual double deg2Rad(double v) { return v * agg::pi / 180.0; } - virtual double rad2Deg(double v) { return v * 180.0 / agg::pi; } -}; - - -template -class AggDrawTargetImplementation : public AggDrawTarget, public Agg2D -{ -public: - typedef typename PixFormatSet::PixFormat pixfmt; - typedef typename pixfmt::color_type color_type; - - typedef Agg2D BASE; - AggDrawTargetImplementation(agg::int8u* buf, int width, int height, int stride) - { - BASE::attach(buf,width,height,stride); - - BASE::viewport(0, 0, width-1, height-1, 0, 0, width-1, height-1, TAGG2D::Anisotropic); - } - - virtual void clear() { - if(!empty) - { - BASE::clearAll(0,0,0,0); - undirty(); - } - } - - // Setup - virtual void attach(unsigned char* buf, unsigned width, unsigned height, int stride) {BASE::attach(buf, width, height, stride);}; -// virtual void attach(Agg2DBase::Image& img) {attach(img);}; - - virtual void clipBox(double x1, double y1, double x2, double y2) { BASE::clipBox(x1,y1,x2,y2); } - virtual Agg2DBase::RectD clipBox() const {return BASE::clipBox();}; - - virtual void clearAll(AggColor c) {BASE::clearAll(c);}; - virtual void clearAll(unsigned r, unsigned g, unsigned b, unsigned a = 255) {BASE::clearAll(r, g, b, a);}; - - virtual void clearClipBox(AggColor c) {BASE::clearClipBox(c);}; - virtual void clearClipBox(unsigned r, unsigned g, unsigned b, unsigned a = 255) {BASE::clearClipBox(r, g, b, a);}; - -// virtual unsigned width() const { return Agg2DBase::m_rbuf.width(); } -// virtual unsigned height() const { return Agg2DBase::m_rbuf.height(); } - - // Conversions - virtual void worldToScreen(double& x, double& y) const {BASE::worldToScreen(x, y);}; - virtual void screenToWorld(double& x, double& y) const {BASE::screenToWorld(x, y);}; - virtual double worldToScreen(double scalar) const {return BASE::worldToScreen(scalar);}; - virtual double screenToWorld(double scalar) const {return BASE::screenToWorld(scalar);}; - virtual void alignPoint(double& x, double& y) const {BASE::alignPoint(x, y);}; - virtual bool inBox(double worldX, double worldY) const {return BASE::inBox(worldX, worldY);}; - - // General Attributes - virtual void blendMode(Agg2DBase::BlendMode m) {BASE::blendMode(m);}; - virtual Agg2DBase::BlendMode blendMode() {return BASE::blendMode();}; - - virtual void imageBlendMode(Agg2DBase::BlendMode m) {BASE::imageBlendMode(m);}; - virtual Agg2DBase::BlendMode imageBlendMode() {return BASE::imageBlendMode();}; - - virtual void imageBlendColor(AggColor c) {BASE::imageBlendColor(c);}; - virtual void imageBlendColor(unsigned r, unsigned g, unsigned b, unsigned a = 255) {BASE::imageBlendColor(r, g, b, a);}; - virtual AggColor imageBlendColor() {return BASE::imageBlendColor();}; - - virtual void masterAlpha(double a) {BASE::masterAlpha(a);}; - virtual double masterAlpha() {return BASE::masterAlpha();}; - - virtual void antiAliasGamma(double g) {BASE::antiAliasGamma(g);}; - virtual double antiAliasGamma() {return BASE::antiAliasGamma();}; - -// virtual void font(const agg::int8u* font) { m_font = font; } -// const agg::int8u* font() { return m_font; } - - virtual void fillColor(AggColor c) {BASE::fillColor(c);}; - virtual void fillColor(unsigned r, unsigned g, unsigned b, unsigned a = 255) {BASE::fillColor(r,g,b,a);}; - virtual void noFill() {BASE::noFill();}; - - virtual void lineColor(AggColor c) {BASE::lineColor(c);}; - virtual void lineColor(unsigned r, unsigned g, unsigned b, unsigned a = 255) {BASE::lineColor(r,g,b,a);}; - virtual void noLine() {BASE::noLine();}; - - virtual AggColor fillColor() {return BASE::fillColor();}; - virtual AggColor lineColor() {return BASE::lineColor();}; - - virtual void fillLinearGradient(double x1, double y1, double x2, double y2, AggColor c1, AggColor c2, double profile=1.0) {BASE::fillLinearGradient(x1, y1, x2, y2, c1, c2, profile);}; - virtual void lineLinearGradient(double x1, double y1, double x2, double y2, AggColor c1, AggColor c2, double profile=1.0) {BASE::lineLinearGradient(x1, y1, x2, y2, c1, c2, profile);}; - - virtual void fillRadialGradient(double x, double y, double r, AggColor c1, AggColor c2, double profile=1.0) {BASE::fillRadialGradient(x, y, r, c1, c2, profile);}; - virtual void lineRadialGradient(double x, double y, double r, AggColor c1, AggColor c2, double profile=1.0) {BASE::lineRadialGradient(x, y, r, c1, c2, profile);}; - - virtual void fillRadialGradient(double x, double y, double r, AggColor c1, AggColor c2, AggColor c3) {BASE::fillRadialGradient(x, y, r, c1, c2, c3);}; - virtual void lineRadialGradient(double x, double y, double r, AggColor c1, AggColor c2, AggColor c3) {BASE::lineRadialGradient(x, y, r, c1, c2, c3);}; - virtual void fillRadialGradient(double x, double y, double r) {BASE::fillRadialGradient(x, y, r);}; - virtual void lineRadialGradient(double x, double y, double r) {BASE::lineRadialGradient(x, y, r);}; - - virtual void lineWidth(double w) {BASE::lineWidth(w);}; - virtual double lineWidth() {return BASE::lineWidth();}; - - virtual void lineCap(Agg2DBase::LineCap cap) {BASE::lineCap(cap);}; - virtual Agg2DBase::LineCap lineCap() {return BASE::lineCap();}; - - virtual void lineJoin(Agg2DBase::LineJoin join) {BASE::lineJoin(join);}; - virtual Agg2DBase::LineJoin lineJoin() {return BASE::lineJoin();}; - - virtual void fillEvenOdd(bool evenOddFlag) {BASE::fillEvenOdd(evenOddFlag);}; - virtual bool fillEvenOdd() {return BASE::fillEvenOdd();}; - - // Transformations - virtual Agg2DBase::Transformations transformations() {return BASE::transformations();}; - virtual void transformations(const Agg2DBase::Transformations& tr) {BASE::transformations(tr);}; - - virtual const Agg2DBase::Affine& affine() {return BASE::affine();}; -// virtual void affine(const Agg2DBase::Affine&) {BASE::affine();}; - - virtual void resetTransformations() {BASE::resetTransformations();}; - virtual void matrix(const Agg2DBase::Affine& tr) {BASE::matrix(tr);}; - virtual void matrix(const Agg2DBase::Transformations& tr) {BASE::matrix(tr);}; - virtual void rotate(double angle) {BASE::rotate(angle);}; - virtual void rotate(double angle, double cx, double cy) {BASE::rotate(angle, cx, cy);}; - virtual void scale(double s) {BASE::scale(s);}; - virtual void scale(double sx, double sy) {BASE::scale(sx, sy);}; - virtual void skew(double sx, double sy) {BASE::skew(sx, sy);}; - virtual void translate(double x, double y) {BASE::translate(x, y);}; - virtual void parallelogram(double x1, double y1, double x2, double y2, const double* para) {BASE::parallelogram(x1, y1, x2, y2, para);}; - virtual void viewport(double worldX1, double worldY1, double worldX2, double worldY2, double screenX1, double screenY1, double screenX2, double screenY2, Agg2DBase::ViewportOption opt=Agg2DBase::XMidYMid, Agg2DBase::WindowFitLogic fl = Agg2DBase::WindowFitLogic_meet) {BASE::viewport(worldX1, worldY1, worldX2, worldY2, screenX1, screenY1, screenX2, screenY2, opt, fl);}; - - // Basic Shapes - virtual void line(double x1, double y1, double x2, double y2) {BASE::line(x1, y1, x2, y2);}; - virtual void triangle(double x1, double y1, double x2, double y2, double x3, double y3) {BASE::triangle(x1, y1, x2, y2, x3, y3);}; - virtual void rectangle(double x1, double y1, double x2, double y2) {BASE::rectangle(x1, y1, x2, y2);}; - virtual void roundedRect(double x1, double y1, double x2, double y2, double r) { dirty(); BASE::roundedRect(x1,y1,x2,y2,r); } - virtual void roundedRect(double x1, double y1, double x2, double y2, double rx, double ry) { dirty(); BASE::roundedRect(x1,y1,x2,y2,rx,ry); } - virtual void roundedRect(double x1, double y1, double x2, double y2,double rx_bottom, double ry_bottom,double rx_top,double ry_top) { dirty(); BASE::roundedRect(x1,y1,x2,y2,rx_bottom,ry_bottom,rx_top,ry_top); } - virtual void ellipse(double cx, double cy, double rx, double ry) {BASE::ellipse(cx, cy, rx, ry);} - virtual void arc(double cx, double cy, double rx, double ry, double start, double sweep) {BASE::arc(cx, cy, rx, ry, start, sweep);}; - virtual void star(double cx, double cy, double r1, double r2, double startAngle, int numRays) {BASE::star(cx, cy, r1, r2, startAngle, numRays);}; - virtual void curve(double x1, double y1, double x2, double y2, double x3, double y3) {BASE::curve(x1, y1, x2, y2, x3, y3);}; - virtual void curve(double x1, double y1, double x2, double y2, double x3, double y3, double x4, double y4) {BASE::curve(x1, y1, x2, y2, x3, y3, x4, y4);}; - virtual void polygon(double* xy, int numPoints) {BASE::polygon(xy, numPoints);}; - virtual void polyline(double* xy, int numPoints) {BASE::polyline(xy, numPoints);}; - - virtual void setFont(const std::string& name) { BASE::font(lookupFont(name)); } - virtual void renderText(double dstX, double dstY, const std::string& str) { - dirty(); - int height = BASE::font()[0]; - int base = BASE::font()[1]; - int offset = height-base*2; - BASE::renderText(dstX, dstY + offset, str); - } - - // Path commands - virtual void resetPath() {BASE::resetPath();}; - - virtual void moveTo(double x, double y) {BASE::moveTo(x, y);} - virtual void moveRel(double dx, double dy) {BASE::moveRel(dx,dy);}; - - virtual void lineTo(double x, double y) {BASE::lineTo(x, y);}; - virtual void lineRel(double dx, double dy) {BASE::lineRel(dx, dy);}; - - virtual void horLineTo(double x) {BASE::horLineTo(x);}; - virtual void horLineRel(double dx) {BASE::horLineRel(dx);}; - - virtual void verLineTo(double y) {BASE::verLineTo(y);}; - virtual void verLineRel(double dy) {BASE::verLineRel(dy);}; - - virtual void arcTo(double rx, double ry, double angle, bool largeArcFlag, bool sweepFlag, double x, double y) {BASE::arcTo(rx, ry, angle, largeArcFlag, sweepFlag, x, y);}; - - virtual void arcRel(double rx, double ry, double angle, bool largeArcFlag, bool sweepFlag, double dx, double dy) {BASE::arcRel(rx, ry, angle, largeArcFlag, sweepFlag, dx, dy);}; - - virtual void quadricCurveTo(double xCtrl, double yCtrl, double xTo, double yTo) {BASE::quadricCurveTo(xCtrl, yCtrl, xTo, yTo);}; - virtual void quadricCurveRel(double dxCtrl, double dyCtrl, double dxTo, double dyTo) {BASE::quadricCurveRel(dxCtrl, dyCtrl, dxTo, dyTo);}; - virtual void quadricCurveTo(double xTo, double yTo) {BASE::quadricCurveTo(xTo, yTo);}; - virtual void quadricCurveRel(double dxTo, double dyTo) {BASE::quadricCurveRel(dxTo, dyTo);}; - - virtual void cubicCurveTo(double xCtrl1, double yCtrl1, double xCtrl2, double yCtrl2, double xTo, double yTo) {BASE::cubicCurveTo(xCtrl1, yCtrl1, xCtrl2, yCtrl2, xTo, yTo);}; - virtual void cubicCurveRel(double dxCtrl1, double dyCtrl1, double dxCtrl2, double dyCtrl2, double dxTo, double dyTo) {BASE::cubicCurveRel(dxCtrl1, dyCtrl1, dxCtrl2, dyCtrl2, dxTo, dyTo);}; - virtual void cubicCurveTo(double xCtrl2, double yCtrl2, double xTo, double yTo) {BASE::cubicCurveTo(xCtrl2, yCtrl2, xTo, yTo);}; - virtual void cubicCurveRel(double xCtrl2, double yCtrl2, double xTo, double yTo) {BASE::cubicCurveRel(xCtrl2, yCtrl2, xTo, yTo);}; - - virtual void addEllipse(double cx, double cy, double rx, double ry, Agg2DBase::Direction dir) {BASE::addEllipse(cx, cy, rx, ry, dir);}; - virtual void closePolygon() {BASE::closePolygon();}; - - virtual void drawPath(Agg2DBase::DrawPathFlag flag = Agg2DBase::FillAndStroke) {BASE::drawPath(flag);}; -// virtual void drawPathNoTransform(DrawPathFlag flag = FillAndStroke) {BASE::drawPathNoTransform(flag);}; - - // Image Transformations - virtual void imageFilter(Agg2DBase::ImageFilter f) {BASE::imageFilter(f);}; - virtual Agg2DBase::ImageFilter imageFilter() {return BASE::imageFilter();}; - - virtual void imageResample(Agg2DBase::ImageResample f) {BASE::imageResample(f);}; - virtual Agg2DBase::ImageResample imageResample() {return BASE::imageResample();}; - - // Auxiliary - virtual double pi() { return agg::pi; } - virtual double deg2Rad(double v) { return v * agg::pi / 180.0; } - virtual double rad2Deg(double v) { return v * 180.0 / agg::pi; } -}; - -class AggDraw -{ -public: - AggDraw() - : target(NULL) - {} - AggDrawTarget *target; -}; - -enum AggTarget -{ - AggTarget_Screen = 0, - AggTarget_Hud = 1, - AggTarget_Lua = 2, -}; - -//specialized instance for desmume; should eventually move to another file -class AggDraw_Desmume : public AggDraw -{ -public: - void setTarget(AggTarget newTarget); - //void composite(void* dest); - - AggDrawTarget *screen, *hud, *lua; -}; - -extern AggDraw_Desmume aggDraw; - -void Agg_init(); - - -#endif diff --git a/desmume/src/cocoa/translations/Chinese.lproj/Localizable.strings b/desmume/src/cocoa/translations/Chinese.lproj/Localizable.strings deleted file mode 100644 index 6221ad69a4e655d75012d1c51c23dd001f234208..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 8418 zcmb7JTWnNS6g`?40tpg7{o+DIv{6dSyW*qt1yW|FbH_eXXz2{o8EBc-X$L3?BF1P* zV+tQw!k-CIln?#Us2}>He;Oq*7-EbXqlqLwViQatLDxQK&g0&@?{v(hk2!a*{W^Q^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ys??_+C|1$h-07-s43>#<;EXdPMd%P7gY4(}H6S_f}!tdb9 zak;~^*D7wG2L;9K(^h8k;EB@UrGtxS&zuuIx8;+l7yrMcoYYs%t#ppt`IVJTv(@~K zL_>APB^s**RgdWDu5xq=R;!-Ty)#n%guau|(>F~^W{1Y#C@fdfX0Ohl>Y=^1619ij zNtdGA*(;iM6OXefJMTL34*VUNc~y^<$BaqwO)*E2M|QX!eOzwFp^b&1ob^)4fm5;5 z0NvYA?v|m=h}6UIsdO)7SvytNNIfG}ZzuY5Z^cZn)b**GtTHl^qLb`4l4Mut_1=!T z-y4wLG1Q}ttX8!5h9>iHfJWU<1?`OUqxHKR1r*26$$Cp&td1-rZ}#)~QabO8=M^Wv#dGA9W@<{DV4{uMx z^1AU}rW3O3Y_c?SepSh z9YX6mV&4YXTB^@veZOP;9{W~DBQmmcp*=U4;_F^9Fz{>j*%Ih&HPCn#i*AQ))DcvDEdH{CN$ zixzmp?Ap2I+280Eueft~RrQHIy)@qxqAG_N@h}(7;5VK1YKEcdF6f_nXrmH#Awp7C zD`cVi9;NI;E_XVV`g@e}S#a!fDE0R!WePd!QtIzf%8Zom%C{?)I<6Pj{tR~BMkeHzgIgFuLeH)K3MIqes>k>m1=bK9H)A_d~FTK zBaNu08OeG36M5T39=EqJY7SCUg67OU59Ju$&BVOjB%hS=Q4_4K)OOWm)P)D<;-+Bg qK=Q~!x__oj)U!I(Ud7vkgd9F - - - - IBFramework Version - 677 - IBOldestOS - 5 - IBOpenObjects - - IBSystem Version - 9J61 - targetFramework - IBCocoaFramework - - diff --git a/desmume/src/cocoa/translations/Chinese.lproj/MainMenu.nib/keyedobjects.nib b/desmume/src/cocoa/translations/Chinese.lproj/MainMenu.nib/keyedobjects.nib deleted file mode 100644 index 6367d4fcb4cf0eadd49fc083946ac39024f3636d..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 4850 zcmbtX33wCL7CvWYGHYfSKm?SfVi5`m1rbYSv4w&~+R}!7t7$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#aG3R;%0G+xJ}$Ho)Lc(e-_V* zzly($e@L>VO0A`CQks-5^^kf=g_2h)mP({jDIf)LV8?!Qd%QDBdwFRN!z6z z(oSi&v{%|Eos!N-=VeJY@nlrHj&4>87M9=}Hf!mvWQhS0*WQl)1`0Wxi6SEL0XNOO?Bn*OfPwe=2V)?0R;ZKIDe6>p znmS#bsot*6R-abas?Vy=sV}H6sxPUpsIRFT)KAoX>KEz(^{9G6{aHP$HPc#XNm?r{ zS-VDStF_ZQXdSgwt&7%G>!zh?=~@phOY5%%w4he5g|(V)qXzR82wGXt7+GcHwwoTiv?a+2=yS2UAKJ5$bfV-Z%gS(r1 zpgZKA;a=c=(EXJACHG_SMt!rsMc<}x*LUbU z_1*ejeV_h?en3B@f2Dt|f1@AMkLxG&llp1>2mL4g7XuC6=xTH`(u{PYhtbQp$;dSN z8vTr$jRD3$Bi9&Y6c~ezp~i4yq%qnUYusuS89rm2QDT%D0V8OX8(|}AR2q|wsm3&8 zhH5Pc8B2_1#@)tpW2I4T)EKLcr;WA7I^z}NHRE+-z40N$UL5Cq - - - - IBClasses - - - CLASS - FirstResponder - LANGUAGE - ObjC - SUPERCLASS - NSObject - - - IBVersion - 1 - - diff --git a/desmume/src/fat.h b/desmume/src/fat.h deleted file mode 100644 index 6d2b7300b..000000000 --- a/desmume/src/fat.h +++ /dev/null @@ -1,85 +0,0 @@ -/* - FAT.H - Mic, 2006 - Structures taken from Michael Chisholm's FAT library -*/ - -#ifndef __FAT_H__ -#define __FAT_H__ - -#include "types.h" -#include "PACKED.h" -#include "PACKED_END.h" - -#define ATTRIB_DIR 0x10 -#define ATTRIB_LFN 0x0F - -#define FILE_FREE 0xE5 -/* Name and extension maximum length */ -#define NAME_LEN 8 -#define EXT_LEN 3 - -// Boot Sector - must be packed -#if defined(_MSC_VER) || defined(__INTEL_COMPILER) -#define DIR_SEP "\\" -#else -#define DIR_SEP "/" -#endif - -#include "PACKED.h" -typedef struct -{ - u8 jmpBoot[3] __PACKED; - u8 OEMName[8] __PACKED; - // BIOS Parameter Block - u16 bytesPerSector __PACKED; - u8 sectorsPerCluster __PACKED; - u16 reservedSectors __PACKED; - u8 numFATs __PACKED; - u16 rootEntries __PACKED; - u16 numSectorsSmall __PACKED; - u8 mediaDesc __PACKED; - u16 sectorsPerFAT __PACKED; - u16 sectorsPerTrk __PACKED; - u16 numHeads __PACKED; - u32 numHiddenSectors __PACKED; - u32 numSectors __PACKED; - - struct - { - // Ext BIOS Parameter Block for FAT16 - u8 driveNumber __PACKED; - u8 reserved1 __PACKED; - u8 extBootSig __PACKED; - u32 volumeID __PACKED; - u8 volumeLabel[11] __PACKED; - u8 fileSysType[8] __PACKED; - // Bootcode - u8 bootCode[448] __PACKED; - u16 signature __PACKED; - } __PACKED fat16; - -} __PACKED BOOT_RECORD; -#include "PACKED_END.h" - -// Directory entry - must be packed -#include "PACKED.h" -typedef struct -{ - u8 name[NAME_LEN] __PACKED; - u8 ext[EXT_LEN] __PACKED; - u8 attrib __PACKED; - u8 reserved __PACKED; - u8 cTime_ms __PACKED; - u16 cTime __PACKED; - u16 cDate __PACKED; - u16 aDate __PACKED; - u16 startClusterHigh __PACKED; - u16 mTime __PACKED; - u16 mDate __PACKED; - u16 startCluster __PACKED; - u32 fileSize __PACKED; -} __PACKED DIR_ENT; -#include "PACKED_END.h" - -#endif // diff --git a/desmume/src/gtk/cheatsGTK.cpp b/desmume/src/gtk/cheatsGTK.cpp deleted file mode 100644 index 3ab4838c7..000000000 --- a/desmume/src/gtk/cheatsGTK.cpp +++ /dev/null @@ -1,437 +0,0 @@ -/* cheats.cpp - this file is part of DeSmuME - * - * Copyright (C) 2006-2009 DeSmuME Team - * - * This file is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2, or (at your option) - * any later version. - * - * This file is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; see the file COPYING. If not, write to - * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - - -#include -#include -#include -#include "cheatsGTK.h" -#include "cheatSystem.h" -#include "main.h" -#include "desmume.h" - -enum { - COLUMN_ENABLED, - COLUMN_SIZE, - COLUMN_HI, - COLUMN_LO, - COLUMN_DESC, - NUM_COL -}; - -enum -{ - COLUMN_SIZE_TEXT, - NUM_SIZE_COLUMNS -}; - -enum { - TYPE_TOGGLE, - TYPE_COMBO, - TYPE_STRING -}; - -static struct { - const gchar *caption; - gint type; - gint column; -} columnTable[]={ - { "Enabled", TYPE_TOGGLE, COLUMN_ENABLED}, - { "Size", TYPE_COMBO, COLUMN_SIZE}, - { "Offset", TYPE_STRING, COLUMN_HI}, - { "Value", TYPE_STRING, COLUMN_LO}, - { "Description", TYPE_STRING, COLUMN_DESC} -}; - -static GtkWidget *win = NULL; -static BOOL shouldBeRunning = FALSE; - -// --------------------------------------------------------------------------------- -// SEARCH -// --------------------------------------------------------------------------------- - -static void -enabled_toggled(GtkCellRendererToggle * cell, - gchar * path_str, gpointer data) -{ - GtkTreeModel *model = (GtkTreeModel *) data; - GtkTreeIter iter; - GtkTreePath *path = gtk_tree_path_new_from_string(path_str); - gboolean enabled; - - gtk_tree_model_get_iter(model, &iter, path); - gtk_tree_model_get(model, &iter, COLUMN_ENABLED, &enabled, -1); - - enabled ^= 1; - CHEATS_LIST cheat; - u32 ii; - GtkTreePath *path1; - - path1 = gtk_tree_model_get_path (model, &iter); - ii = gtk_tree_path_get_indices (path)[0]; - - cheatsGet(&cheat, ii); - - cheatsUpdate(cheat.size, cheat.hi[0], cheat.lo[0], cheat.description, - enabled, ii); - - gtk_list_store_set(GTK_LIST_STORE(model), &iter, COLUMN_ENABLED, enabled, -1); - - gtk_tree_path_free(path); -} - -static void cheat_list_modify_cheat(GtkCellRendererText * cell, - const gchar * path_string, - const gchar * new_text, gpointer data) -{ - GtkTreeModel *model = (GtkTreeModel *) data; - GtkTreePath *path = gtk_tree_path_new_from_string(path_string); - GtkTreeIter iter; - - gint column = - GPOINTER_TO_INT(g_object_get_data(G_OBJECT(cell), "column")); - - gtk_tree_model_get_iter(model, &iter, path); - - { - u32 ii; - GtkTreePath *path1; - CHEATS_LIST cheat; - - path1 = gtk_tree_model_get_path (model, &iter); - ii = gtk_tree_path_get_indices (path)[0]; - - cheatsGet(&cheat, ii); - - gtk_tree_path_free (path1); - - if (column == COLUMN_LO || column == COLUMN_HI - || column == COLUMN_SIZE) { - u32 v = atoi(new_text); - switch (column) { - case COLUMN_SIZE: - cheatsUpdate(v-1, cheat.hi[0], cheat.lo[0], - cheat.description, cheat.enabled, ii); - break; - case COLUMN_HI: - cheatsUpdate(cheat.size, v, cheat.lo[0], cheat.description, - cheat.enabled, ii); - break; - case COLUMN_LO: - cheatsUpdate(cheat.size, cheat.hi[0], v, cheat.description, - cheat.enabled, ii); - break; - } - gtk_list_store_set(GTK_LIST_STORE(model), &iter, column, - atoi(new_text), -1); - } else if (column == COLUMN_DESC){ - cheatsUpdate(cheat.size, cheat.hi[0], cheat.lo[0], - g_strdup(new_text), cheat.enabled, ii); - gtk_list_store_set(GTK_LIST_STORE(model), &iter, column, - g_strdup(new_text), -1); - } - - } -} - -static void cheat_list_remove_cheat(GtkWidget * widget, gpointer data) -{ - GtkTreeView *tree = (GtkTreeView *) data; - GtkTreeSelection *selection = gtk_tree_view_get_selection (tree); - GtkTreeModel *model = gtk_tree_view_get_model (tree); - GtkTreeIter iter; - - if (gtk_tree_selection_get_selected (selection, NULL, &iter)){ - u32 ii; - GtkTreePath *path; - - path = gtk_tree_model_get_path (model, &iter); - ii = gtk_tree_path_get_indices (path)[0]; - - gtk_list_store_remove(GTK_LIST_STORE(model), &iter); - cheatsRemove(ii); - - gtk_tree_path_free (path); - } -} - -static void cheat_list_add_cheat(GtkWidget * widget, gpointer data) -{ -#define NEW_DESC "New cheat" - GtkListStore *store = (GtkListStore *) data; - GtkTreeIter iter; - cheatsAdd(1, 0, 0, g_strdup(NEW_DESC), FALSE); - gtk_list_store_append(store, &iter); - gtk_list_store_set(store, &iter, - COLUMN_ENABLED, FALSE, - COLUMN_SIZE, 1, - COLUMN_HI, 0, - COLUMN_LO, 0, COLUMN_DESC, NEW_DESC, -1); - -#undef NEW_DESC -} - -static GtkTreeModel * create_numbers_model (void) -{ -#define N_NUMBERS 4 - gint i = 0; - GtkListStore *model; - GtkTreeIter iter; - - /* create list store */ - model = gtk_list_store_new (NUM_SIZE_COLUMNS, G_TYPE_STRING, G_TYPE_INT); - - /* add numbers */ - for (i = 1; i < N_NUMBERS+1; i++) - { - char str[2]; - - str[0] = '0' + i; - str[1] = '\0'; - - gtk_list_store_append (model, &iter); - - gtk_list_store_set (model, &iter, - COLUMN_SIZE_TEXT, str, - -1); - } - - return GTK_TREE_MODEL (model); - -#undef N_NUMBERS -} - -static void cheat_list_add_columns(GtkTreeView * tree, GtkListStore * store) -{ - - GtkTreeModel *model = gtk_tree_view_get_model(GTK_TREE_VIEW(tree)); - static GtkTreeModel * size_model; - - for (u32 ii = 0; ii < sizeof(columnTable) / sizeof(columnTable[0]); ii++) { - GtkCellRenderer *renderer = NULL; - GtkTreeViewColumn *column; - const gchar *attrib = NULL; - switch (columnTable[ii].type) { - case TYPE_TOGGLE: - renderer = gtk_cell_renderer_toggle_new(); - g_signal_connect(renderer, "toggled", - G_CALLBACK(enabled_toggled), model); - attrib = "active"; - break; - case TYPE_STRING: - renderer = gtk_cell_renderer_text_new(); - g_object_set(renderer, "editable", TRUE, NULL); - g_signal_connect(renderer, "edited", - G_CALLBACK(cheat_list_modify_cheat), store); - attrib = "text"; - break; - case TYPE_COMBO: - renderer = gtk_cell_renderer_combo_new(); - size_model = create_numbers_model(); - g_object_set(renderer, - "model", size_model, - "text-column", COLUMN_SIZE_TEXT, - "editable", TRUE, - "has-entry", FALSE, - NULL); - g_object_unref(size_model); - g_signal_connect(renderer, "edited", - G_CALLBACK(cheat_list_modify_cheat), store); - attrib = "text"; - break; - } - column = - gtk_tree_view_column_new_with_attributes(columnTable[ii]. - caption, renderer, - attrib, columnTable[ii].column, - NULL); - g_object_set_data(G_OBJECT(renderer), "column", - GINT_TO_POINTER(columnTable[ii].column)); - gtk_tree_view_append_column(GTK_TREE_VIEW(tree), column); - } - -} - -static void cheatListEnd() -{ - cheatsSave(); - if(shouldBeRunning) - Launch(); -} - -static GtkListStore *cheat_list_populate() -{ - GtkListStore *store = gtk_list_store_new (5, G_TYPE_BOOLEAN, - G_TYPE_INT, G_TYPE_INT, G_TYPE_INT, G_TYPE_STRING); - - CHEATS_LIST cheat; - u32 chsize = cheatsGetSize(); - for(u32 ii = 0; ii < chsize; ii++){ - GtkTreeIter iter; - cheatsGet(&cheat, ii); - gtk_list_store_append(store, &iter); - gtk_list_store_set(store, &iter, - COLUMN_ENABLED, cheat.enabled, - COLUMN_SIZE, cheat.size+1, - COLUMN_HI, cheat.hi[0], - COLUMN_LO, cheat.lo[0], - COLUMN_DESC, cheat.description, - -1); - } - return store; -} - -static GtkWidget *cheat_list_create_ui() -{ - GtkListStore *store = cheat_list_populate(); - GtkWidget *tree = gtk_tree_view_new_with_model (GTK_TREE_MODEL (store)); - GtkWidget *vbox = gtk_vbox_new(FALSE, 1); - GtkWidget *hbbox = gtk_hbutton_box_new(); - GtkWidget *button; - - gtk_container_add(GTK_CONTAINER(vbox), GTK_WIDGET(tree)); - gtk_container_add(GTK_CONTAINER(vbox), GTK_WIDGET(hbbox)); - gtk_container_add(GTK_CONTAINER(win), GTK_WIDGET(vbox)); - - button = gtk_button_new_with_label("add cheat"); - g_signal_connect (button, "clicked", G_CALLBACK (cheat_list_add_cheat), store); - gtk_container_add(GTK_CONTAINER(hbbox),button); - - button = gtk_button_new_with_label("Remove cheat"); - g_signal_connect (button, "clicked", G_CALLBACK (cheat_list_remove_cheat), tree); - gtk_container_add(GTK_CONTAINER(hbbox),button); - - cheat_list_add_columns(GTK_TREE_VIEW(tree), store); - - /* Setup the selection handler */ - GtkTreeSelection *select; - select = gtk_tree_view_get_selection (GTK_TREE_VIEW (tree)); - gtk_tree_selection_set_mode (select, GTK_SELECTION_SINGLE); - - return tree; -} - -void CheatList () -{ - shouldBeRunning = desmume_running(); - Pause(); - win = gtk_window_new(GTK_WINDOW_TOPLEVEL); - gtk_window_set_title(GTK_WINDOW(win),"Cheat List"); - gtk_window_set_modal(GTK_WINDOW(win), TRUE); - g_signal_connect(G_OBJECT(win), "destroy", cheatListEnd, NULL); - - cheat_list_create_ui(); - - gtk_widget_show_all(win); -} - -// --------------------------------------------------------------------------------- -// SEARCH -// --------------------------------------------------------------------------------- - -static void cheat_search_create_ui() -{ - GtkWidget *button; - GtkWidget *vbox = gtk_vbox_new(FALSE, 1); - GtkWidget *hbbox = gtk_hbutton_box_new(); - GtkWidget *b; - - gtk_container_add(GTK_CONTAINER(win), GTK_WIDGET(vbox)); - - { - b = gtk_hbox_new(FALSE, 1); - gtk_container_add(GTK_CONTAINER(vbox), GTK_WIDGET(b)); - - { - GtkTreeModel * size_model; - GtkWidget *w; - w = gtk_label_new("size"); - gtk_container_add(GTK_CONTAINER(b), w); - - size_model = create_numbers_model(); - - w = gtk_combo_box_new_with_model(size_model); - g_object_unref(size_model); - GtkCellRenderer * renderer = gtk_cell_renderer_text_new (); - gtk_cell_layout_pack_start (GTK_CELL_LAYOUT (w), renderer, TRUE); - gtk_cell_layout_set_attributes (GTK_CELL_LAYOUT (w), renderer, - "text", COLUMN_SIZE_TEXT, - NULL); - gtk_combo_box_set_active (GTK_COMBO_BOX (w), 0); - gtk_container_add(GTK_CONTAINER(b), w); - } - - b = gtk_hbox_new(FALSE, 1); - gtk_container_add(GTK_CONTAINER(vbox), GTK_WIDGET(b)); - - { - GtkWidget *w; - w = gtk_label_new("signedness"); - gtk_container_add(GTK_CONTAINER(b), w); - -// m = create_sign_model(); - - w = gtk_combo_box_new(); -// w = gtk_combo_box_new_with_model(size_model); -// g_object_unref(size_model); -// size_model = NULL; - GtkCellRenderer * renderer = gtk_cell_renderer_text_new (); - gtk_cell_layout_pack_start (GTK_CELL_LAYOUT (w), renderer, TRUE); -// gtk_cell_layout_set_attributes (GTK_CELL_LAYOUT (w), renderer, -// "text", COLUMN_SIZE_TEXT, -// NULL); - gtk_combo_box_set_active (GTK_COMBO_BOX (w), 0); - gtk_container_add(GTK_CONTAINER(b), w); - } - } - - // BUTTONS: - - gtk_container_add(GTK_CONTAINER(vbox), GTK_WIDGET(hbbox)); - - button = gtk_button_new_with_label("add cheats"); -// g_signal_connect (button, "clicked", g_callback (cheat_list_add_cheat), store); - gtk_container_add(GTK_CONTAINER(hbbox),button); - - button = gtk_button_new_with_label("search"); -// g_signal_connect (button, "clicked", g_callback (cheat_list_add_cheat), store); - gtk_container_add(GTK_CONTAINER(hbbox),button); - -// GtkWidget *vbox = gtk_vbox_new(FALSE, 1); -// gtk_container_add(GTK_CONTAINER(win), GTK_WIDGET(vbox)); -} - -static void cheatSearchEnd() -{ -} - -void CheatSearch () -{ - shouldBeRunning = desmume_running(); - Pause(); - win = gtk_window_new(GTK_WINDOW_TOPLEVEL); - gtk_window_set_title(GTK_WINDOW(win),"Cheat Search"); - gtk_window_set_modal(GTK_WINDOW(win), TRUE); - g_signal_connect(G_OBJECT(win), "destroy", cheatSearchEnd, NULL); - - cheat_search_create_ui(); - - gtk_widget_show_all(win); -} diff --git a/desmume/src/gtk/cheatsGTK.h b/desmume/src/gtk/cheatsGTK.h deleted file mode 100644 index 141111348..000000000 --- a/desmume/src/gtk/cheatsGTK.h +++ /dev/null @@ -1,29 +0,0 @@ -/* desmume.h - this file is part of DeSmuME - * - * Copyright (C) 2006,2007 DeSmuME Team - * Copyright (C) 2007 Pascal Giard (evilynux) - * - * This file is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2, or (at your option) - * any later version. - * - * This file is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; see the file COPYING. If not, write to - * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -#ifndef __CHEATS_H__ -#define __CHEATS_H__ - -void CheatSearch (); -void CheatList (); - -#endif /*__CHEATS_H__*/ - diff --git a/desmume/src/gtk/main.h b/desmume/src/gtk/main.h deleted file mode 100644 index a12669fcf..000000000 --- a/desmume/src/gtk/main.h +++ /dev/null @@ -1,7 +0,0 @@ -#ifndef __DESMUME_GTK_MAIN_H__ -#define __DESMUME_GTK_MAIN_H__ - -void Pause(); -void Launch(); - -#endif diff --git a/desmume/src/matrix.h b/desmume/src/matrix.h deleted file mode 100644 index 0f15e6269..000000000 --- a/desmume/src/matrix.h +++ /dev/null @@ -1,317 +0,0 @@ -/* Copyright (C) 2006-2007 shash - Copyright (C) 2009 DeSmuME team - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#ifndef MATRIX_H -#define MATRIX_H - -#include -#include - -#include "types.h" -#include "mem.h" - -#ifdef ENABLE_SSE -#include -#endif - -#ifdef ENABLE_SSE2 -#include -#endif - -struct MatrixStack -{ - MatrixStack(int size); - float *matrix; - int position; - int size; -}; - -void MatrixInit (float *matrix); - -//In order to conditionally use these asm optimized functions in visual studio -//without having to make new build types to exclude the assembly files. -//a bit sloppy, but there aint much to it - -float MatrixGetMultipliedIndex (int index, float *matrix, float *rightMatrix); -void MatrixSet (float *matrix, int x, int y, float value); -void MatrixCopy (float * matrixDST, const float * matrixSRC); -int MatrixCompare (const float * matrixDST, const float * matrixSRC); -void MatrixIdentity (float *matrix); - -void MatrixTranspose (float *matrix); -void MatrixStackInit (MatrixStack *stack); -void MatrixStackSetMaxSize (MatrixStack *stack, int size); -void MatrixStackSetStackPosition (MatrixStack *stack, int pos); -void MatrixStackPushMatrix (MatrixStack *stack, const float *ptr); -float* MatrixStackPopMatrix (MatrixStack *stack, int size); -float* MatrixStackGetPos (MatrixStack *stack, int pos); -float* MatrixStackGet (MatrixStack *stack); -void MatrixStackLoadMatrix (MatrixStack *stack, int pos, const float *ptr); - -void Vector2Copy(float *dst, const float *src); -void Vector2Add(float *dst, const float *src); -void Vector2Subtract(float *dst, const float *src); -float Vector2Dot(const float *a, const float *b); -float Vector2Cross(const float *a, const float *b); - -float Vector3Dot(const float *a, const float *b); -void Vector3Cross(float* dst, const float *a, const float *b); -float Vector3Length(const float *a); -void Vector3Add(float *dst, const float *src); -void Vector3Subtract(float *dst, const float *src); -void Vector3Scale(float *dst, const float scale); -void Vector3Copy(float *dst, const float *src); -void Vector3Normalize(float *dst); - -void Vector4Copy(float *dst, const float *src); - -//these functions are an unreliable, inaccurate floor. -//it should only be used for positive numbers -//this isnt as fast as it could be if we used a visual c++ intrinsic, but those appear not to be universally available -FORCEINLINE u32 u32floor(float f) -{ -#ifdef ENABLE_SSE2 - return (u32)_mm_cvtt_ss2si(_mm_set_ss(f)); -#else - return (u32)f; -#endif -} -FORCEINLINE u32 u32floor(double d) -{ -#ifdef ENABLE_SSE2 - return (u32)_mm_cvttsd_si32(_mm_set_sd(d)); -#else - return (u32)d; -#endif -} - -//same as above but works for negative values too. -//be sure that the results are the same thing as floorf! -FORCEINLINE s32 s32floor(float f) -{ -#ifdef ENABLE_SSE2 - return _mm_cvtss_si32( _mm_add_ss(_mm_set_ss(-0.5f),_mm_add_ss(_mm_set_ss(f), _mm_set_ss(f))) ) >> 1; -#else - return (s32)floorf(f); -#endif -} - -//switched SSE2 functions -//------------- -#ifdef ENABLE_SSE - -template -FORCEINLINE void memset_u16_le(void* dst, u16 val) -{ - u32 u32val; - //just for the endian safety - T1WriteWord((u8*)&u32val,0,val); - T1WriteWord((u8*)&u32val,2,val); - ////const __m128i temp = _mm_set_epi32(u32val,u32val,u32val,u32val); - __m128 temp; temp.m128_i32[0] = u32val; - //MACRODO_N(NUM/8,_mm_store_si128((__m128i*)((u8*)dst+(X)*16), temp)); - MACRODO_N(NUM/8,_mm_store_ps1((float*)((u8*)dst+(X)*16), temp)); -} - -#else //no sse2 - -template -static FORCEINLINE void memset_u16_le(void* dst, u16 val) -{ - for(int i=0;i -FORCEINLINE void vector_fix2float(float* matrix, const float divisor) -{ - CTASSERT(NUM_ROWS==3 || NUM_ROWS==4); - - const __m128 val = _mm_set_ps1(divisor); - - _mm_store_ps(matrix,_mm_div_ps(_mm_load_ps(matrix),val)); - _mm_store_ps(matrix+4,_mm_div_ps(_mm_load_ps(matrix+4),val)); - _mm_store_ps(matrix+8,_mm_div_ps(_mm_load_ps(matrix+8),val)); - if(NUM_ROWS==4) - _mm_store_ps(matrix+12,_mm_div_ps(_mm_load_ps(matrix+12),val)); -} - -//WARNING: I do not think this is as fast as a memset, for some reason. -//at least in vc2005 with sse enabled. better figure out why before using it -template -static FORCEINLINE void memset_u8(void* _dst, u8 val) -{ - memset(_dst,val,NUM); - //const u8* dst = (u8*)_dst; - //u32 u32val = (val<<24)|(val<<16)|(val<<8)|val; - //const __m128i temp = _mm_set_epi32(u32val,u32val,u32val,u32val); - //MACRODO_N(NUM/16,_mm_store_si128((__m128i*)(dst+(X)*16), temp)); -} - -#else //no sse - -void MatrixMultVec4x4 (const float *matrix, float *vecPtr); -void MatrixMultVec3x3(const float * matrix, float * vecPtr); -void MatrixMultiply(float * matrix, const float * rightMatrix); -void MatrixTranslate(float *matrix, const float *ptr); -void MatrixScale(float * matrix, const float * ptr); - -FORCEINLINE void MatrixMultVec4x4_M2(const float *matrix, float *vecPtr) -{ - //there are hardly any gains from merging these manually - MatrixMultVec4x4(matrix+16,vecPtr); - MatrixMultVec4x4(matrix,vecPtr); -} - -template -FORCEINLINE void vector_fix2float(float* matrix, const float divisor) -{ - for(int i=0;i -static FORCEINLINE void memset_u8(void* dst, u8 val) -{ - memset(dst,val,NUM); -} - -#endif //switched SSE functions - - -#endif diff --git a/desmume/src/mc.cpp b/desmume/src/mc.cpp deleted file mode 100644 index e267c43c4..000000000 --- a/desmume/src/mc.cpp +++ /dev/null @@ -1,817 +0,0 @@ -/* Copyright (C) 2006 thoduv - Copyright (C) 2006-2007 Theo Berkau - Copyright (C) 2008-2009 DeSmuME team - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#include -#include -#include "debug.h" -#include "types.h" -#include "mc.h" -#include "movie.h" -#include "readwrite.h" -#include "NDSSystem.h" - -//temporary hack until we have better error reporting facilities -#ifdef _MSC_VER -#include -#endif - -#define FW_CMD_READ 0x3 -#define FW_CMD_WRITEDISABLE 0x4 -#define FW_CMD_READSTATUS 0x5 -#define FW_CMD_WRITEENABLE 0x6 -#define FW_CMD_PAGEWRITE 0xA - -#define BM_CMD_AUTODETECT 0xFF -#define BM_CMD_WRITESTATUS 0x1 -#define BM_CMD_WRITELOW 0x2 -#define BM_CMD_READLOW 0x3 -#define BM_CMD_WRITEDISABLE 0x4 -#define BM_CMD_READSTATUS 0x5 -#define BM_CMD_WRITEENABLE 0x6 -#define BM_CMD_WRITEHIGH 0xA -#define BM_CMD_READHIGH 0xB - -/* FLASH*/ -#define COMM_PAGE_WRITE 0x0A -#define COMM_PAGE_ERASE 0xDB -#define COMM_SECTOR_ERASE 0xD8 -#define COMM_CHIP_ERASE 0xC7 -#define CARDFLASH_READ_BYTES_FAST 0x0B /* Not used*/ -#define CARDFLASH_DEEP_POWDOWN 0xB9 /* Not used*/ -#define CARDFLASH_WAKEUP 0xAB /* Not used*/ - -//this should probably be 0xFF but we're using 0x00 until we find out otherwise -//(no$ appears definitely to initialized to 0xFF) -static const u8 kUninitializedSaveDataValue = 0x00; - -static const char* kDesmumeSaveCookie = "|-DESMUME SAVE-|"; - -static const u32 saveSizes[] = {512,8*1024,32*1024,64*1024,256*1024,512*1024,0xFFFFFFFF}; -static const u32 saveSizes_count = ARRAY_SIZE(saveSizes); - -//the lookup table from user save types to save parameters -static const int save_types[7][2] = { - {MC_TYPE_AUTODETECT,1}, - {MC_TYPE_EEPROM1,MC_SIZE_4KBITS}, - {MC_TYPE_EEPROM2,MC_SIZE_64KBITS}, - {MC_TYPE_EEPROM2,MC_SIZE_512KBITS}, - {MC_TYPE_FRAM,MC_SIZE_256KBITS}, - {MC_TYPE_FLASH,MC_SIZE_2MBITS}, - {MC_TYPE_FLASH,MC_SIZE_4MBITS} -}; - -void backup_setManualBackupType(int type) -{ - CommonSettings.manualBackupType = type; -} - -void mc_init(memory_chip_t *mc, int type) -{ - mc->com = 0; - mc->addr = 0; - mc->addr_shift = 0; - mc->data = NULL; - mc->size = 0; - mc->write_enable = FALSE; - mc->writeable_buffer = FALSE; - mc->type = type; - mc->autodetectsize = 0; - - switch(mc->type) - { - case MC_TYPE_EEPROM1: - mc->addr_size = 1; - break; - case MC_TYPE_EEPROM2: - case MC_TYPE_FRAM: - mc->addr_size = 2; - break; - case MC_TYPE_FLASH: - mc->addr_size = 3; - break; - default: break; - } -} - -u8 *mc_alloc(memory_chip_t *mc, u32 size) -{ - u8 *buffer; - buffer = new u8[size]; - memset(buffer,0,size); - - mc->data = buffer; - if(!buffer) { return NULL; } - mc->size = size; - mc->writeable_buffer = TRUE; - - return buffer; -} - -void mc_free(memory_chip_t *mc) -{ - if(mc->data) delete[] mc->data; - mc_init(mc, 0); -} - -void fw_reset_com(memory_chip_t *mc) -{ - if(mc->com == FW_CMD_PAGEWRITE) - { - if (mc->fp) - { - fseek(mc->fp, 0, SEEK_SET); - fwrite(mc->data, mc->size, 1, mc->fp); - } - - mc->write_enable = FALSE; - } - - mc->com = 0; -} - -u8 fw_transfer(memory_chip_t *mc, u8 data) -{ - if(mc->com == FW_CMD_READ || mc->com == FW_CMD_PAGEWRITE) /* check if we are in a command that needs 3 bytes address */ - { - if(mc->addr_shift > 0) /* if we got a complete address */ - { - mc->addr_shift--; - mc->addr |= data << (mc->addr_shift * 8); /* argument is a byte of address */ - } - else /* if we have received 3 bytes of address, proceed command */ - { - switch(mc->com) - { - case FW_CMD_READ: - if(mc->addr < mc->size) /* check if we can read */ - { - data = mc->data[mc->addr]; /* return byte */ - mc->addr++; /* then increment address */ - } - break; - - case FW_CMD_PAGEWRITE: - if(mc->addr < mc->size) - { - mc->data[mc->addr] = data; /* write byte */ - mc->addr++; - } - break; - } - - } - } - else if(mc->com == FW_CMD_READSTATUS) - { - return (mc->write_enable ? 0x02 : 0x00); - } - else /* finally, check if it's a new command */ - { - switch(data) - { - case 0: break; /* nothing */ - - case FW_CMD_READ: /* read command */ - mc->addr = 0; - mc->addr_shift = 3; - mc->com = FW_CMD_READ; - break; - - case FW_CMD_WRITEENABLE: /* enable writing */ - if(mc->writeable_buffer) { mc->write_enable = TRUE; } - break; - - case FW_CMD_WRITEDISABLE: /* disable writing */ - mc->write_enable = FALSE; - break; - - case FW_CMD_PAGEWRITE: /* write command */ - if(mc->write_enable) - { - mc->addr = 0; - mc->addr_shift = 3; - mc->com = FW_CMD_PAGEWRITE; - } - else { data = 0; } - break; - - case FW_CMD_READSTATUS: /* status register command */ - mc->com = FW_CMD_READSTATUS; - break; - - default: - printf("Unhandled FW command: %02X\n", data); - break; - } - } - - return data; -} - -bool BackupDevice::save_state(std::ostream* os) -{ - int version = 0; - write32le(version,os); - write32le(write_enable,os); - write32le(com,os); - write32le(addr_size,os); - write32le(addr_counter,os); - write32le((u32)state,os); - writebuffer(data,os); - writebuffer(data_autodetect,os); - return true; -} - -bool BackupDevice::load_state(std::istream* is) -{ - int version; - if(read32le(&version,is)!=1) return false; - if(version==0) { - read32le(&write_enable,is); - read32le(&com,is); - read32le(&addr_size,is); - read32le(&addr_counter,is); - u32 temp; - read32le(&temp,is); - state = (STATE)temp; - readbuffer(data,is); - readbuffer(data_autodetect,is); - } - return true; -} - -BackupDevice::BackupDevice() -{ -} - -//due to unfortunate shortcomings in the emulator architecture, -//at reset-time, we won't have a filename to the .dsv file. -//so the only difference between load_rom (init) and reset is that -//one of them saves the filename -void BackupDevice::load_rom(const char* filename) -{ - isMovieMode = false; - this->filename = filename; - reset(); -} - -void BackupDevice::movie_mode() -{ - isMovieMode = true; - reset(); -} - -void BackupDevice::reset() -{ - com = 0; - addr = addr_counter = 0; - flushPending = false; - lazyFlushPending = false; - data.resize(0); - write_enable = FALSE; - data_autodetect.resize(0); - - state = DETECTING; - addr_size = 0; - loadfile(); - - //if the user has requested a manual choice for backup type, and we havent imported a raw save file, then apply it now - if(state == DETECTING && CommonSettings.manualBackupType != MC_TYPE_AUTODETECT) - { - state = RUNNING; - int savetype = save_types[CommonSettings.manualBackupType][0]; - int savesize = save_types[CommonSettings.manualBackupType][1]; - ensure((u32)savesize); //expand properly if necessary - data.resize(savesize); //truncate if necessary - addr_size = addr_size_for_old_save_type(savetype); - flush(); - } -} - -void BackupDevice::close_rom() -{ - flush(); -} - -void BackupDevice::reset_command() -{ - //for a performance hack, save files are only flushed after each reset command - //(hopefully, after each page) - if(flushPending) - { - flush(); - flushPending = false; - lazyFlushPending = false; - } - - if(state == DETECTING && data_autodetect.size()>0) - { - //we can now safely detect the save address size - u32 autodetect_size = data_autodetect.size(); - - printf("Autodetecting with autodetect_size=%d\n",autodetect_size); - - const u8 sm64_sig[] = {0x01,0x80,0x00,0x00}; - if(autodetect_size == 4 && !memcmp(&data_autodetect[0],sm64_sig,4)) - { - addr_size = 2; - } - else //detect based on rules - switch(autodetect_size) - { - case 0: - case 1: - printf("Catastrophic error while autodetecting save type.\nIt will need to be specified manually\n"); - #ifdef _MSC_VER - MessageBox(0,"Catastrophic Error Code: Camel;\nyour save type has not been autodetected correctly;\nplease report to developers",0,0); - #endif - addr_size = 1; //choose 1 just to keep the busted savefile from growing too big - break; - case 2: - //the modern typical case for small eeproms - addr_size = 1; - break; - case 3: - //another modern typical case.. - //but unfortunately we select this case for spider-man 3, when what it meant to do was - //present the archaic 1+2 case - addr_size = 2; - break; - case 4: - //a modern typical case - addr_size = 3; - break; - default: - //the archaic case: write the address and then some modulo-4 number of bytes - //why modulo 4? who knows. - addr_size = autodetect_size & 3; - break; - } - - state = RUNNING; - data_autodetect.resize(0); - flush(); - } - - com = 0; -} -u8 BackupDevice::data_command(u8 val) -{ - if(com == BM_CMD_READLOW || com == BM_CMD_WRITELOW) - { - //handle data or address - if(state == DETECTING) - { - if(com == BM_CMD_WRITELOW) - { - printf("Unexpected backup device initialization sequence using writes!\n"); - } - - //just buffer the data until we're no longer detecting - data_autodetect.push_back(val); - val = 0; - } - else - { - if(addr_counterwrite_enable << 1); - return (write_enable << 1); - } - else - { - //there is no current command. receive one - switch(val) - { - case 0: break; //?? - - case BM_CMD_WRITEDISABLE: - write_enable = FALSE; - break; - - case BM_CMD_READSTATUS: - com = BM_CMD_READSTATUS; - break; - - case BM_CMD_WRITEENABLE: - write_enable = TRUE; - break; - - case BM_CMD_WRITELOW: - case BM_CMD_READLOW: - //printf("XLO: %08X\n",addr); - com = val; - addr_counter = 0; - addr = 0; - break; - - case BM_CMD_WRITEHIGH: - case BM_CMD_READHIGH: - //printf("XHI: %08X\n",addr); - if(val == BM_CMD_WRITEHIGH) val = BM_CMD_WRITELOW; - if(val == BM_CMD_READHIGH) val = BM_CMD_READLOW; - com = val; - addr_counter = 0; - addr = 0; - if(addr_size==1) { - //"write command that's only available on ST M95040-W that I know of" - //this makes sense, since this device would only have a 256 bytes address space with writelow - //and writehigh would allow access to the upper 256 bytes - //but it was detected in pokemon diamond also during the main save process - addr = 0x1; - } - break; - - default: - printf("COMMAND: Unhandled Backup Memory command: %02X\n", val); - break; - } - } - return val; -} - -//guarantees that the data buffer has room enough for the specified number of bytes -void BackupDevice::ensure(u32 addr) -{ - u32 size = data.size(); - if(sizeaddr_size = addr_size; - this->data.resize(datasize); - memcpy(&this->data[0],data,datasize); - - //dump back out as a dsv, just to keep things sane - flush(); -} - - -void BackupDevice::loadfile() -{ - //never use save files if we are in movie mode - if(isMovieMode) return; - if(filename.length() ==0) return; //No sense crashing if no filename supplied - - FILE* inf = fopen(filename.c_str(),"rb"); - if(!inf) - { - //no dsv found; we need to try auto-importing a file with .sav extension - printf("DeSmuME .dsv save file not found. Trying to load an old raw .sav file.\n"); - - //change extension to sav - char tmp[MAX_PATH]; - strcpy(tmp,filename.c_str()); - tmp[strlen(tmp)-3] = 0; - strcat(tmp,"sav"); - - inf = fopen(tmp,"rb"); - if(!inf) - { - printf("Missing save file %s\n",filename.c_str()); - return; - } - fclose(inf); - - load_raw(tmp); - } - else - { - //scan for desmume save footer - const s32 cookieLen = (s32)strlen(kDesmumeSaveCookie); - char *sigbuf = new char[cookieLen]; - fseek(inf, -cookieLen, SEEK_END); - fread(sigbuf,1,cookieLen,inf); - int cmp = memcmp(sigbuf,kDesmumeSaveCookie,cookieLen); - delete[] sigbuf; - if(cmp) - { - //maybe it is a misnamed raw save file. try loading it that way - printf("Not a DeSmuME .dsv save file. Trying to load as raw.\n"); - fclose(inf); - load_raw(filename.c_str()); - return; - } - //desmume format - fseek(inf, -cookieLen, SEEK_END); - fseek(inf, -4, SEEK_CUR); - u32 version = 0xFFFFFFFF; - read32le(&version,inf); - if(version!=0) { - printf("Unknown save file format\n"); - return; - } - fseek(inf, -24, SEEK_CUR); - struct { - u32 size,padSize,type,addr_size,mem_size; - } info; - read32le(&info.size,inf); - read32le(&info.padSize,inf); - read32le(&info.type,inf); - read32le(&info.addr_size,inf); - read32le(&info.mem_size,inf); - - //establish the save data - data.resize(info.size); - fseek(inf, 0, SEEK_SET); - if(info.size>0) - fread(&data[0],1,info.size,inf); //read all the raw data we have - state = RUNNING; - addr_size = info.addr_size; - //none of the other fields are used right now - - fclose(inf); - } -} - -bool BackupDevice::save_raw(const char* filename) -{ - FILE* outf = fopen(filename,"wb"); - if(!outf) return false; - u32 size = data.size(); - u32 padSize = pad_up_size(size); - if(data.size()>0) - fwrite(&data[0],1,size,outf); - for(u32 i=size;i saveSizes[ctr]) ctr++; - u32 padSize = saveSizes[ctr]; - if(padSize == 0xFFFFFFFF) - { - printf("PANIC! Couldn't pad up save size. Refusing to pad.\n"); - padSize = startSize; - } - return padSize; -} - -void BackupDevice::lazy_flush() -{ - if(flushPending || lazyFlushPending) - { - lazyFlushPending = flushPending = false; - flush(); - } -} - -void BackupDevice::flush() -{ - //never use save files if we are in movie mode - if(isMovieMode) return; - - FILE* outf = fopen(filename.c_str(),"wb"); - if(outf) - { - if(data.size()>0) - fwrite(&data[0],1,data.size(),outf); - - //write the footer. we use a footer so that we can maximize the chance of the - //save file being recognized as a raw save file by other emulators etc. - - //first, pad up to the next largest known save size. - u32 size = data.size(); - u32 padSize = pad_up_size(size); - - for(u32 i=size;iseekg(-cookieLen, std::ios::end); - is->seekg(-4, std::ios::cur); - - u32 version = 0xFFFFFFFF; - is->read((char*)&version,4); - if(version!=0) { - printf("Unknown save file format\n"); - return false; - } - is->seekg(-24, std::ios::cur); - - struct{ - u32 size,padSize,type,addr_size,mem_size; - }info; - - is->read((char*)&info.size,4); - is->read((char*)&info.padSize,4); - is->read((char*)&info.type,4); - is->read((char*)&info.addr_size,4); - is->read((char*)&info.mem_size,4); - - //establish the save data - data.resize(info.size); - is->seekg(0, std::ios::beg); - if(info.size>0) - is->read((char*)&data[0],info.size); - - state = RUNNING; - addr_size = info.addr_size; - //none of the other fields are used right now - - return true; -} diff --git a/desmume/src/mic.cpp b/desmume/src/mic.cpp deleted file mode 100644 index c4a468d9a..000000000 --- a/desmume/src/mic.cpp +++ /dev/null @@ -1,55 +0,0 @@ -/* mic.cpp - this file is part of DeSmuME - * - * Copyright (C) 2009 DeSmuME Team - * - * This file is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2, or (at your option) - * any later version. - * - * This file is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; see the file COPYING. If not, write to - * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -#ifndef WIN32 - -#include "types.h" -#include "mic.h" - -static BOOL silence = TRUE; -int MicButtonPressed; - -BOOL Mic_Init() -{ - return TRUE; -} - -void Mic_Reset() -{ -} - -void Mic_DeInit() -{ -} - -u8 Mic_ReadSample() -{ - if (silence) - return 0; - - return 150; -} - -void Mic_DoNoise(BOOL noise) -{ - silence = !noise; -} - -#endif diff --git a/desmume/src/mic.h b/desmume/src/mic.h deleted file mode 100644 index 4bbdea231..000000000 --- a/desmume/src/mic.h +++ /dev/null @@ -1,42 +0,0 @@ -/* mic.h - this file is part of DeSmuME - * - * Copyright (C) 2009 DeSmuME Team - * - * This file is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2, or (at your option) - * any later version. - * - * This file is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; see the file COPYING. If not, write to - * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -#ifndef MIC_H -#define MIC_H - -extern int MicButtonPressed; - -#ifdef WIN32 -static char MicSampleName[256]; -bool LoadSample(const char *name); -#endif - -extern int MicDisplay; - -#ifdef FAKE_MIC -void Mic_DoNoise(BOOL); -#endif - -BOOL Mic_Init(); -void Mic_Reset(); -void Mic_DeInit(); -u8 Mic_ReadSample(); - -#endif diff --git a/desmume/src/mic_alsa.cpp b/desmume/src/mic_alsa.cpp deleted file mode 100644 index d87ce50b7..000000000 --- a/desmume/src/mic_alsa.cpp +++ /dev/null @@ -1,148 +0,0 @@ -/* mic_alsa.cpp - this file is part of DeSmuME - * - * Copyright (C) 2009 DeSmuME Team - * - * This file is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2, or (at your option) - * any later version. - * - * This file is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; see the file COPYING. If not, write to - * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -#include -#include "types.h" -#include "mic.h" -#include "debug.h" - -#define MIC_BUFSIZE 4096 - -BOOL Mic_Inited = FALSE; -u8 Mic_Buffer[2][MIC_BUFSIZE]; -u16 Mic_BufPos; -u8 Mic_PlayBuf; -u8 Mic_WriteBuf; - -int MicButtonPressed; - -// Handle for the PCM device -static snd_pcm_t *pcm_handle; - -BOOL Mic_Init() -{ - snd_pcm_hw_params_t *hwparams; - - if (Mic_Inited) - return TRUE; - - // Open the default sound card in capture - if (snd_pcm_open(&pcm_handle, "plughw:0,0", SND_PCM_STREAM_CAPTURE, SND_PCM_NONBLOCK) < 0) - return FALSE; - - // Allocate the snd_pcm_hw_params_t structure and fill it. - snd_pcm_hw_params_alloca(&hwparams); - if (snd_pcm_hw_params_any(pcm_handle, hwparams) < 0) - return FALSE; - - //Set the access - if (snd_pcm_hw_params_set_access(pcm_handle, hwparams, SND_PCM_ACCESS_RW_INTERLEAVED) < 0) - return FALSE ; - - //dir 0 == exacte (Rate = 16K exacte) - if (snd_pcm_hw_params_set_rate(pcm_handle, hwparams, 16000, 0) < 0) - return FALSE; - - /* Set sample format */ - if (snd_pcm_hw_params_set_format(pcm_handle, hwparams, SND_PCM_FORMAT_S8) < 0) - return FALSE; - - // Set one channel (mono) - if (snd_pcm_hw_params_set_channels(pcm_handle, hwparams, 1) < 0) - return FALSE; - - // Set 2 periods - if (snd_pcm_hw_params_set_periods(pcm_handle, hwparams, 2, 0) < 0) - return FALSE; - - // Set the buffer sise - if (snd_pcm_hw_params_set_buffer_size(pcm_handle, hwparams, MIC_BUFSIZE) < 0) - return FALSE; - - //Set the params - if (snd_pcm_hw_params(pcm_handle, hwparams) < 0) - return FALSE; - - Mic_Inited = TRUE; - Mic_Reset(); - - return TRUE; -} - -void Mic_Reset() -{ - if (!Mic_Inited) - return; - - memset(Mic_Buffer, 0, MIC_BUFSIZE * 2); - Mic_BufPos = 0; - Mic_PlayBuf = 1; - Mic_WriteBuf = 0; -} - -void Mic_DeInit() -{ - if (!Mic_Inited) - return; - - Mic_Inited = FALSE; - - snd_pcm_drop(pcm_handle); - snd_pcm_close(pcm_handle); -} - -static void snd_pcm_read() -{ - int error; - - error = snd_pcm_readi(pcm_handle, Mic_Buffer[Mic_WriteBuf], MIC_BUFSIZE); - if (error < 0) - error = snd_pcm_recover(pcm_handle, error, 0); - if (error < 0) - LOG("snd_pcm_readi FAIL!: %s\n", snd_strerror(error)); -} - -u8 Mic_ReadSample() -{ - u8 tmp; - u8 ret; - - if (!Mic_Inited) - return 0; - - tmp = Mic_Buffer[Mic_PlayBuf][Mic_BufPos >> 1]; - - if (Mic_BufPos & 0x1) { - ret = ((tmp & 0x1) << 7); - } else { - ret = ((tmp & 0xFE) >> 1); - snd_pcm_read(); - } - - Mic_BufPos++; - if (Mic_BufPos >= (MIC_BUFSIZE << 1)) { - snd_pcm_read(); - Mic_BufPos = 0; - Mic_PlayBuf ^= 1; - Mic_WriteBuf ^= 1; - } - - return ret; -} diff --git a/desmume/src/path.h b/desmume/src/path.h deleted file mode 100644 index 6671842f0..000000000 --- a/desmume/src/path.h +++ /dev/null @@ -1,360 +0,0 @@ -#include - -#ifdef WIN32 -#include "resource.h" -#else -#include -#endif -#include "time.h" -#include "utils/xstring.h" - -class PathInfo -{ -public: - - std::string path; - std::string RomName; - - #define MAX_FORMAT 20 - #define SECTION "PathSettings" - - #define ROMKEY "Roms" - #define BATTERYKEY "Battery" - #define STATEKEY "States" - #define SCREENSHOTKEY "Screenshots" - #define AVIKEY "AviFiles" - #define CHEATKEY "Cheats" - #define SOUNDKEY "SoundSamples" - #define FIRMWAREKEY "Firmware" - #define FORMATKEY "format" - #define DEFAULTFORMATKEY "defaultFormat" - #define NEEDSSAVINGKEY "needsSaving" - #define LASTVISITKEY "lastVisit" - #define LUAKEY "Lua" - char screenshotFormat[MAX_FORMAT]; - bool savelastromvisit; - - enum KnownPath - { - FIRSTKNOWNPATH = 0, - ROMS = 0, - BATTERY, - STATES, - SCREENSHOTS, - AVI_FILES, - CHEATS, - SOUNDS, - FIRMWARE, - MODULE, - MAXKNOWNPATH = MODULE - }; - - char pathToRoms[MAX_PATH]; - char pathToBattery[MAX_PATH]; - char pathToStates[MAX_PATH]; - char pathToScreenshots[MAX_PATH]; - char pathToAviFiles[MAX_PATH]; - char pathToCheats[MAX_PATH]; - char pathToSounds[MAX_PATH]; - char pathToFirmware[MAX_PATH]; - char pathToModule[MAX_PATH]; - char pathToLua[MAX_PATH]; - - void init(const char * filename) { - - path = std::string(filename); - - //extract the internal part of the logical rom name - std::vector parts = tokenize_str(filename,"|"); - SetRomName(parts[parts.size()-1].c_str()); - LoadModulePath(); - #ifndef WIN32 - - ReadPathSettings(); - #endif - - } - - void LoadModulePath() - { - #ifdef WIN32 - char *p; - ZeroMemory(pathToModule, sizeof(pathToModule)); - GetModuleFileName(NULL, pathToModule, sizeof(pathToModule)); - p = pathToModule + lstrlen(pathToModule); - while (p >= pathToModule && *p != '\\') p--; - if (++p >= pathToModule) *p = 0; - #else -// strcpy(pathToModule, g_get_home_dir()); - const char *homedir = getenv ("HOME"); - strcpy(pathToModule, homedir); - #endif - } - - enum Action - { - GET, - SET - }; - - void GetDefaultPath(char *pathToDefault, const char *key, int maxCount) - { - strncpy(pathToDefault, pathToModule, maxCount); - } - - void ReadKey(char *pathToRead, const char *key) - { - #ifdef WIN32 - GetPrivateProfileString(SECTION, key, key, pathToRead, MAX_PATH, IniName); - if(strcmp(pathToRead, key) == 0) - #endif - //since the variables are all intialized in this file they all use MAX_PATH - GetDefaultPath(pathToRead, key, MAX_PATH); - } - - void ReadPathSettings() - { - if( ( strcmp(pathToModule, "") == 0) || !pathToModule) - LoadModulePath(); - - ReadKey(pathToRoms, ROMKEY); - ReadKey(pathToBattery, BATTERYKEY); - ReadKey(pathToStates, STATEKEY); - ReadKey(pathToScreenshots, SCREENSHOTKEY); - ReadKey(pathToAviFiles, AVIKEY); - ReadKey(pathToCheats, CHEATKEY); - ReadKey(pathToSounds, SOUNDKEY); - ReadKey(pathToFirmware, FIRMWAREKEY); - ReadKey(pathToLua, LUAKEY); - #ifdef WIN32 - GetPrivateProfileString(SECTION, FORMATKEY, "%f_%s_%r", screenshotFormat, MAX_FORMAT, IniName); - savelastromvisit = GetPrivateProfileInt(SECTION, LASTVISITKEY, TRUE, IniName); - currentimageformat = (ImageFormat)GetPrivateProfileInt(SECTION, DEFAULTFORMATKEY, PNG, IniName); - #endif - /* - needsSaving = GetPrivateProfileInt(SECTION, NEEDSSAVINGKEY, TRUE, IniName); - if(needsSaving) - { - needsSaving = FALSE; - WritePathSettings(); - }*/ - } - - void SwitchPath(Action action, KnownPath path, char * buffer) - { - char *pathToCopy = 0; - switch(path) - { - case ROMS: - pathToCopy = pathToRoms; - break; - case BATTERY: - pathToCopy = pathToBattery; - break; - case STATES: - pathToCopy = pathToStates; - break; - case SCREENSHOTS: - pathToCopy = pathToScreenshots; - break; - case AVI_FILES: - pathToCopy = pathToAviFiles; - break; - case CHEATS: - pathToCopy = pathToCheats; - break; - case SOUNDS: - pathToCopy = pathToSounds; - break; - case FIRMWARE: - pathToCopy = pathToFirmware; - break; - case MODULE: - pathToCopy = pathToModule; - break; - } - - if(action == GET) - { - strncpy(buffer, pathToCopy, MAX_PATH); - int len = strlen(buffer)-1; - #ifdef WIN32 - if(buffer[len] != '\\') - strcat(buffer, "\\"); - #else - if(buffer[len] != '/') - strcat(buffer, "/"); - #endif - - } - else if(action == SET) - { - int len = strlen(buffer)-1; - if(buffer[len] == '\\') - buffer[len] = '\0'; - - strncpy(pathToCopy, buffer, MAX_PATH); - } - } - - std::string getpath(KnownPath path) - { - char temp[MAX_PATH]; - SwitchPath(GET, path, temp); - return temp; - } - - void getpath(KnownPath path, char *buffer) - { - SwitchPath(GET, path, buffer); - } - - void setpath(KnownPath path, char *buffer) - { - SwitchPath(SET, path, buffer); - } - - void getfilename(char *buffer, int maxCount) - { - strcpy(buffer,noextension().c_str()); - } - - void getpathnoext(KnownPath path, char *buffer) - { - getpath(path, buffer); - strcat(buffer, GetRomNameWithoutExtension().c_str()); - } - - std::string extension() { - - for(int i = int(path.size()) - 1; i >= 0; --i) - { - if (path[i] == '.') { - return path.substr(i+1); - } - } - return path; - } - - std::string noextension() { - - for(int i = int(path.size()) - 1; i >= 0; --i) - { - if (path[i] == '.') { - return path.substr(0, i); - } - } - return path; - } - - void formatname(char *output) - { - std::string file; - time_t now = time(NULL); - tm *time_struct = localtime(&now); - srand(now); - - for(int i = 0; i < MAX_FORMAT;i++) - { - char *c = &screenshotFormat[i]; - char tmp[MAX_PATH] = {0}; - - if(*c == '%') - { - c = &screenshotFormat[++i]; - switch(*c) - { - case 'f': - - strcat(tmp, GetRomNameWithoutExtension().c_str()); - break; - case 'D': - strftime(tmp, MAX_PATH, "%d", time_struct); - break; - case 'M': - strftime(tmp, MAX_PATH, "%m", time_struct); - break; - case 'Y': - strftime(tmp, MAX_PATH, "%Y", time_struct); - break; - case 'h': - strftime(tmp, MAX_PATH, "%H", time_struct); - break; - case 'm': - strftime(tmp, MAX_PATH, "%M", time_struct); - break; - case 's': - strftime(tmp, MAX_PATH, "%S", time_struct); - break; - case 'r': - sprintf(tmp, "%d", rand() % RAND_MAX); - break; - } - } - else - { - int j; - for(j=i;j 0) - str = str.substr(x+1); - RomName = str; - } - - const char *GetRomName() - { - return RomName.c_str(); - } - - std::string GetRomNameWithoutExtension() - { - int x = RomName.find_last_of("."); - if (x > 0) - return RomName.substr(0,x); - else return RomName; - } - - bool isdsgba(std::string str) { - int x = str.find_last_of("."); - if (x > 0) - str = str.substr(x-2); - if(!strcmp(str.c_str(), "ds.gba")) - return true; - return false; - } -}; - -extern PathInfo path; diff --git a/desmume/src/version.h b/desmume/src/version.h deleted file mode 100644 index 7ceb38dee..000000000 --- a/desmume/src/version.h +++ /dev/null @@ -1,86 +0,0 @@ -/* Copyright (C) 2009 DeSmuME team - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -*/ - - -//todo - everyone will want to support this eventually, i suppose -#ifdef _MSC_VER -#include "svnrev.h" -#else -#ifdef SVN_REV -#define SVN_REV_STR SVN_REV -#else -#define SVN_REV_STR "" -#endif -#endif - -#define DESMUME_NAME "DeSmuME" - -#ifdef _WIN64 -#define DESMUME_PLATFORM_STRING " x64" -#else -#ifdef _WIN32 -#define DESMUME_PLATFORM_STRING " x86" -#else -#define DESMUME_PLATFORM_STRING "" -#endif -#endif - -#ifndef ENABLE_SSE2 - #ifndef ENABLE_SSE - #define DESMUME_CPUEXT_STRING " NOSSE" - #else - #define DESMUME_CPUEXT_STRING " NOSSE2" - #endif -#else -#define DESMUME_CPUEXT_STRING "" -#endif - -#ifdef DEVELOPER -#define DESMUME_FEATURE_STRING " dev+" -#else -#define DESMUME_FEATURE_STRING "" -#endif - -#ifdef DEBUG -#define DESMUME_SUBVERSION_STRING " debug" -#elif defined(PUBLIC_RELEASE) -#define DESMUME_SUBVERSION_STRING "" -#else -#define DESMUME_SUBVERSION_STRING " svn" SVN_REV_STR -#endif - -#ifdef __INTEL_COMPILER -#define DESMUME_COMPILER " (Intel) " -#define DESMUME_COMPILER_DETAIL " (Intel) " -#elif defined(_MSC_VER) -#define DESMUME_COMPILER "" -#define DESMUME_COMPILER_DETAIL " msvc " _Py_STRINGIZE(_MSC_VER) -#define _Py_STRINGIZE(X) _Py_STRINGIZE1((X)) -#define _Py_STRINGIZE1(X) _Py_STRINGIZE2 ## X -#define _Py_STRINGIZE2(X) #X -//re: http://72.14.203.104/search?q=cache:HG-okth5NGkJ:mail.python.org/pipermail/python-checkins/2002-November/030704.html+_msc_ver+compiler+version+string&hl=en&gl=us&ct=clnk&cd=5 -#else -// TODO: make for others compilers -#define DESMUME_COMPILER "" -#define DESMUME_COMPILER_DETAIL "" -#endif - -#define DESMUME_VERSION_NUMERIC 90500 -#define DESMUME_VERSION_STRING " " "0.9.5" DESMUME_SUBVERSION_STRING DESMUME_FEATURE_STRING DESMUME_PLATFORM_STRING DESMUME_CPUEXT_STRING DESMUME_COMPILER -#define DESMUME_NAME_AND_VERSION " " DESMUME_NAME DESMUME_VERSION_STRING diff --git a/desmume/src/windows/DeSmuME_2010.sln b/desmume/src/windows/DeSmuME_2010.sln deleted file mode 100644 index fad4cb2e8..000000000 --- a/desmume/src/windows/DeSmuME_2010.sln +++ /dev/null @@ -1,23 +0,0 @@ - -Microsoft Visual Studio Solution File, Format Version 11.00 -# Visual Studio 10 -Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "DeSmuME_VS2010", "DeSmuME_2010.vcxproj", "{9F5F72A1-D3A5-4918-B460-E076B16D10A9}" -EndProject -Global - GlobalSection(SolutionConfigurationPlatforms) = preSolution - Debug|Win32 = Debug|Win32 - Release FastBuild|Win32 = Release FastBuild|Win32 - Release|Win32 = Release|Win32 - EndGlobalSection - GlobalSection(ProjectConfigurationPlatforms) = postSolution - {9F5F72A1-D3A5-4918-B460-E076B16D10A9}.Debug|Win32.ActiveCfg = Debug|Win32 - {9F5F72A1-D3A5-4918-B460-E076B16D10A9}.Debug|Win32.Build.0 = Debug|Win32 - {9F5F72A1-D3A5-4918-B460-E076B16D10A9}.Release FastBuild|Win32.ActiveCfg = Release FastBuild|Win32 - {9F5F72A1-D3A5-4918-B460-E076B16D10A9}.Release FastBuild|Win32.Build.0 = Release FastBuild|Win32 - {9F5F72A1-D3A5-4918-B460-E076B16D10A9}.Release|Win32.ActiveCfg = Release|Win32 - {9F5F72A1-D3A5-4918-B460-E076B16D10A9}.Release|Win32.Build.0 = Release|Win32 - EndGlobalSection - GlobalSection(SolutionProperties) = preSolution - HideSolutionNode = FALSE - EndGlobalSection -EndGlobal diff --git a/desmume/src/windows/DeSmuME_2010.vcxproj b/desmume/src/windows/DeSmuME_2010.vcxproj deleted file mode 100644 index 6adf08494..000000000 --- a/desmume/src/windows/DeSmuME_2010.vcxproj +++ /dev/null @@ -1,393 +0,0 @@ - - - - Debug - Win32 - - - Release FastBuild - Win32 - - - Release - Win32 - - - - DeSmuME_VS2010 - {9F5F72A1-D3A5-4918-B460-E076B16D10A9} - DeSmuME - - - - Application - - - Application - true - - - Application - false - - - - - - - - - - - - - - - - - - - - <_ProjectFileVersion>10.0.20506.1 - $(SolutionDir)\__bins\ - $(SolutionDir)\.VS2010\$(Configuration)\$(Platform)\ - $(ProjectName)_debug - .exe - $(SolutionDir)\__bins\ - $(SolutionDir)\.VS2010\$(Configuration)\$(Platform)\ - $(ProjectName)_release - .exe - $(SolutionDir)\__bins\ - $(SolutionDir)\.VS2010\$(Configuration)\$(Platform)\ - $(ProjectName)_releaseFastBuild - .exe - - - - defaultconfig\SubWCRev.bat - - - Disabled - Disabled - false - Neither - false - false - .;..;lua\lua-5.1.4\src;glib-2.20.1\build;glib-2.20.1\build\glib;.\zlib123;.\zziplib;.\winpcap;userconfig;defaultconfig;.\7z;%(AdditionalIncludeDirectories) - DEBUG;_CRT_SECURE_NO_DEPRECATE;WIN32;BETA_VERSION;SPU_INTERPOLATE;NOMINMAX;EXPERIMENTAL_WIFI;HAVE_LIBZ;HAVE_LIBZZIP;%(PreprocessorDefinitions) - Sync - EnableFastChecks - true - StreamingSIMDExtensions2 - Fast - EditAndContinue - Cdecl - Default - - - lua-5.1.4-x86.lib;glib-2.20.1-x86.lib;vfw32.lib;winmm.lib;opengl32.lib;glu32.lib;ws2_32.lib;user32.lib;gdi32.lib;directx\dxguid.lib;shell32.lib;comdlg32.lib;directx\dxerr8.lib;directx\dsound.lib;directx\dinput8.lib;directx\ddraw.lib;zlib-2005-x32.lib;zziplib-2005-x32.lib;shlwapi.lib;winpcap\wpcap.lib;7zip.lib;%(AdditionalDependencies) - .\zlib123;.\zziplib;glib-2.20.1\lib;lua\lib;.\7z;%(AdditionalLibraryDirectories) - wpcap.dll;%(DelayLoadDLLs) - true - true - false - - - - - DeSmuME_x86.manifest;%(AdditionalManifestFiles) - - - - - defaultconfig\SubWCRev.bat - - - MaxSpeed - AnySuitable - true - Speed - true - true - true - .;..;lua\lua-5.1.4\src;glib-2.20.1\build;glib-2.20.1\build\glib;.\zlib123;.\zziplib;.\winpcap;userconfig;defaultconfig;%(AdditionalIncludeDirectories) - _CRT_SECURE_NO_DEPRECATE;WIN32;HAVE_LIBZ;HAVE_LIBZZIP;SSE2;SPU_INTERPOLATE;NOMINMAX;RELEASE;EXPERIMENTAL_WIFI;NDEBUG;%(PreprocessorDefinitions) - true - Sync - Default - false - StreamingSIMDExtensions2 - Fast - Level1 - ProgramDatabase - Cdecl - Default - - - lua-5.1.4-x86.lib;glib-2.20.1-x86.lib;vfw32.lib;winmm.lib;opengl32.lib;glu32.lib;ws2_32.lib;user32.lib;gdi32.lib;directx\dxguid.lib;shell32.lib;comdlg32.lib;directx\dxerr8.lib;directx\dsound.lib;directx\dinput8.lib;directx\ddraw.lib;zlib-2005-x32.lib;zziplib-2005-x32.lib;shlwapi.lib;winpcap\wpcap.lib;7zip.lib;%(AdditionalDependencies) - .\zlib123;.\zziplib;glib-2.20.1\lib;lua\lib;.\7z;%(AdditionalLibraryDirectories) - wpcap.dll;%(DelayLoadDLLs) - true - true - false - - - false - - - DeSmuME_x86.manifest;%(AdditionalManifestFiles) - - - - - defaultconfig\SubWCRev.bat - - - MaxSpeed - AnySuitable - true - Speed - true - true - false - .;..;lua\lua-5.1.4\src;glib-2.20.1\build;glib-2.20.1\build\glib;.\zlib123;.\zziplib;.\winpcap;userconfig;defaultconfig;.\7z;%(AdditionalIncludeDirectories) - _CRT_SECURE_NO_DEPRECATE;WIN32;HAVE_LIBZ;HAVE_LIBZZIP;SSE2;SPU_INTERPOLATE;NOMINMAX;RELEASE;EXPERIMENTAL_WIFI;NDEBUG;%(PreprocessorDefinitions) - true - Sync - Default - false - StreamingSIMDExtensions2 - Fast - Level1 - ProgramDatabase - Cdecl - Default - - - lua-5.1.4-x86.lib;glib-2.20.1-x86.lib;vfw32.lib;winmm.lib;opengl32.lib;glu32.lib;ws2_32.lib;user32.lib;gdi32.lib;directx\dxguid.lib;shell32.lib;comdlg32.lib;directx\dxerr8.lib;directx\dsound.lib;directx\dinput8.lib;directx\ddraw.lib;zlib-2005-x32.lib;zziplib-2005-x32.lib;shlwapi.lib;winpcap\wpcap.lib;7zip.lib;%(AdditionalDependencies) - .\zlib123;.\zziplib;glib-2.20.1\lib;lua\lib;.\7z;%(AdditionalLibraryDirectories) - wpcap.dll;%(DelayLoadDLLs) - true - true - - - false - - - false - - - DeSmuME_x86.manifest;%(AdditionalManifestFiles) - - - - - - - - - - - - - - Cdecl - Cdecl - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - true - Assembling x64... - ml64 /nologo /c /Zi /Fo"$(IntDir)%(FileName).obj" "%(FullPath)" - - true - Assembling x64... - ml64 /nologo /c /Zi /Fo"$(IntDir)%(FileName).obj" "%(FullPath)" - - $(IntDir)%(FileName).obj;%(Outputs) - true - Assembling x64... - ml64 /nologo /c /Zi /Fo"$(IntDir)%(FileName).obj" "%(FullPath)" - - $(IntDir)%(FileName).obj;%(Outputs) - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/desmume/src/windows/agg/agg-2.5.lib b/desmume/src/windows/agg/agg-2.5.lib deleted file mode 100644 index 600a2cf5df76d0ec193ac04951fd651a240a28ee..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 878718 zcmeFaeQ;#SaUb|*2fKq^&dvD5e3|4v zHu?kTT>#zeZp;8O&nC562S@N;P#0mH{;(~cLl<$O^I3`uovG956hn&QiaN@YC`DM5 zIHbagxT7tdkJKG$iD#Mj%dC%A^c_Jy)8x-xuW9*-~Nl3_pM1p&*#}jo`ldli$AI_jZH(e81~I9^9Aq zyYo+i`+UDY_VM7p|J;AS^o`&?$M50ej|C(Det#!8ob`KSE;u~s@2~z`aCns8uRalcFw`fY#nyT7Bz;A?*oO#CPCd;jgp;8p+q=Z^*V z5AyqKQ^Eb;A-@ltoeI9=et-7of(O3)`&}9QC#nNSe)(81(C=?81xMn)pZ{iXB+u`k zUJQ;5`8#?1SAxvncYHLM{7(A)`F|Qre)spgGWf0zd{+m)s{8YiKh1K%y_4%nvr3?h|{^H`=g>qND ztoHlW+Gf~qhwIy&a+2bWwaV3gbz@=W*-MqRmDQ!E%jGgMU*Br%)Dz$f=Lvjy@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fSciZ@QX)Xr=UsqWsH}dXE zN8fLYvM>ak)m54i&pJ>#ohUInN%nxPhNW_-4T+apqAV~8wV@kJrz0IurhU7xmRl8| zwitep-gs$N?0CF1Gj<#+x2%0WxlZ1-tf&)rBV-I6_u#g|x`Xj~!M0+o&*Ls1ewo&S z_X4SLq8HY?aW_ydocFoq&+*v$vZ=9y`%9Zm0PuEFjt;=gE+%d9+Ff!b_k{G~m4CgZW;I*G&eVM7dOx}ntwr>}FyviT!OGDX9UxDpIfEe)kA3))rRR4Raq3C6G-bbC6sPnVM zgh8%#QzYsQ{&Nk7j#Z5=6F)hv;5v_-RxllX#XR^T;S1t;iSU)gy<$|BtEvr;7i6lM{{`ZuhsEoLD`Hd#lET$%)qcv%`0<&m~&}=2*g#_|c1Ttdv-e z_NH^zfD5ER9KEI@3k6yO3GdZ7vOFb^ZVgU>oT=K#PpZZ{HK0=H%BR(OwhBvyoAK+w z&x}j1B{N1k_iED?DHKD9d#Xm8J1KN;a`-c)MT}d^y}ImP`Rh74?FuHr2D|at_3r z#i>Psg1TDQ9MV@D#kX#%8~F0Ry=KEN_>{>nVAyL3J^YG~9ZkYFj>N>)NtIee6R$_x fDv9e#Vv)v96rS-`t26SYYOk-JxWQO3>i_=$K_R7q diff --git a/desmume/src/windows/agg/agg-2.5.sln b/desmume/src/windows/agg/agg-2.5.sln deleted file mode 100644 index 99189bca3..000000000 --- a/desmume/src/windows/agg/agg-2.5.sln +++ /dev/null @@ -1,20 +0,0 @@ - -Microsoft Visual Studio Solution File, Format Version 9.00 -# Visual Studio 2005 -Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "agg-2.5", "agg-2.5.vcproj", "{887D5BD9-14EB-4B81-AABA-71E1E1063044}" -EndProject -Global - GlobalSection(SolutionConfigurationPlatforms) = preSolution - Debug|Win32 = Debug|Win32 - Release|Win32 = Release|Win32 - EndGlobalSection - GlobalSection(ProjectConfigurationPlatforms) = postSolution - {887D5BD9-14EB-4B81-AABA-71E1E1063044}.Debug|Win32.ActiveCfg = Debug|Win32 - {887D5BD9-14EB-4B81-AABA-71E1E1063044}.Debug|Win32.Build.0 = Debug|Win32 - {887D5BD9-14EB-4B81-AABA-71E1E1063044}.Release|Win32.ActiveCfg = Release|Win32 - {887D5BD9-14EB-4B81-AABA-71E1E1063044}.Release|Win32.Build.0 = Release|Win32 - EndGlobalSection - GlobalSection(SolutionProperties) = preSolution - HideSolutionNode = FALSE - EndGlobalSection -EndGlobal diff --git a/desmume/src/windows/agg/agg-2.5.vcproj b/desmume/src/windows/agg/agg-2.5.vcproj deleted file mode 100644 index 7d0d816fe..000000000 --- a/desmume/src/windows/agg/agg-2.5.vcproj +++ /dev/null @@ -1,880 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/desmume/src/windows/agg/examples/pixel_formats.h b/desmume/src/windows/agg/examples/pixel_formats.h deleted file mode 100644 index 0a601f687..000000000 --- a/desmume/src/windows/agg/examples/pixel_formats.h +++ /dev/null @@ -1,184 +0,0 @@ -#ifndef PIXEL_FORMATS_INCLUDED -#define PIXEL_FORMATS_INCLUDED - -#if defined(AGG_GRAY8) - -#include "agg_pixfmt_gray.h" -#define pix_format agg::pix_format_gray8 -typedef agg::pixfmt_gray8 pixfmt; -typedef agg::pixfmt_gray8_pre pixfmt_pre; -typedef agg::gray8 color_type; - -#elif defined(AGG_GRAY16) - -#include "agg_pixfmt_gray.h" -#define pix_format agg::pix_format_gray16 -typedef agg::pixfmt_gray16 pixfmt; -typedef agg::pixfmt_gray16_pre pixfmt_pre; -typedef agg::gray16 color_type; - -#elif defined(AGG_BGR24) - -#include "agg_pixfmt_rgb.h" -#define pix_format agg::pix_format_bgr24 -typedef agg::pixfmt_bgr24 pixfmt; -typedef agg::pixfmt_bgr24_pre pixfmt_pre; -#define pixfmt_gamma agg::pixfmt_bgr24_gamma -typedef agg::rgba8 color_type; -typedef agg::order_bgr component_order; - -#elif defined(AGG_RGB24) - -#include "agg_pixfmt_rgb.h" -#define pix_format agg::pix_format_rgb24 -typedef agg::pixfmt_rgb24 pixfmt; -typedef agg::pixfmt_rgb24_pre pixfmt_pre; -#define pixfmt_gamma agg::pixfmt_rgb24_gamma -typedef agg::rgba8 color_type; -typedef agg::order_rgb component_order; - -#elif defined(AGG_BGR48) - -#include "agg_pixfmt_rgb.h" -#define pix_format agg::pix_format_bgr48 -typedef agg::pixfmt_bgr48 pixfmt; -typedef agg::pixfmt_bgr48_pre pixfmt_pre; -#define pixfmt_gamma agg::pixfmt_bgr48_gamma -typedef agg::rgba16 color_type; -typedef agg::order_bgr component_order; - -#elif defined(AGG_RGB48) - -#include "agg_pixfmt_rgb.h" -#define pix_format agg::pix_format_rgb48 -typedef agg::pixfmt_rgb48 pixfmt; -typedef agg::pixfmt_rgb48_pre pixfmt_pre; -#define pixfmt_gamma agg::pixfmt_rgb48_gamma -typedef agg::rgba16 color_type; -typedef agg::order_rgb component_order; - -#elif defined(AGG_BGRA32) - -#include "agg_pixfmt_rgba.h" -#define pix_format agg::pix_format_bgra32 -typedef agg::pixfmt_bgra32 pixfmt; -typedef agg::pixfmt_bgra32_pre pixfmt_pre; -typedef agg::rgba8 color_type; -typedef agg::order_bgra component_order; - -#elif defined(AGG_RGBA32) - -#include "agg_pixfmt_rgba.h" -#define pix_format agg::pix_format_rgba32 -typedef agg::pixfmt_rgba32 pixfmt; -typedef agg::pixfmt_rgba32_pre pixfmt_pre; -typedef agg::rgba8 color_type; -typedef agg::order_rgba component_order; - -#elif defined(AGG_ARGB32) - -#include "agg_pixfmt_rgba.h" -#define pix_format agg::pix_format_argb32 -typedef agg::pixfmt_argb32 pixfmt; -typedef agg::pixfmt_argb32_pre pixfmt_pre; -typedef agg::rgba8 color_type; -typedef agg::order_argb component_order; - -#elif defined(AGG_ABGR32) - -#include "agg_pixfmt_rgba.h" -#define pix_format agg::pix_format_abgr32 -typedef agg::pixfmt_abgr32 pixfmt; -typedef agg::pixfmt_abgr32_pre pixfmt_pre; -typedef agg::rgba8 color_type; -typedef agg::order_argb component_order; - -#elif defined(AGG_BGRA64) - -#include "agg_pixfmt_rgba.h" -#define pix_format agg::pix_format_bgra64 -typedef agg::pixfmt_bgra64 pixfmt; -typedef agg::pixfmt_bgra64_pre pixfmt_pre; -typedef agg::rgba16 color_type; -typedef agg::order_bgra component_order; - -#elif defined(AGG_RGBA64) - -#include "agg_pixfmt_rgba.h" -#define pix_format agg::pix_format_rgba64 -typedef agg::pixfmt_rgba64 pixfmt; -typedef agg::pixfmt_rgba64_pre pixfmt_pre; -typedef agg::rgba16 color_type; -typedef agg::order_rgba component_order; - -#elif defined(AGG_ARGB64) - -#include "agg_pixfmt_rgba.h" -#define pix_format agg::pix_format_argb64 -typedef agg::pixfmt_argb64 pixfmt; -typedef agg::pixfmt_argb64_pre pixfmt_pre; -typedef agg::rgba16 color_type; -typedef agg::order_argb component_order; - -#elif defined(AGG_ABGR64) - -#include "agg_pixfmt_rgba.h" -#define pix_format agg::pix_format_abgr64 -typedef agg::pixfmt_abgr64 pixfmt; -typedef agg::pixfmt_abgr64_pre pixfmt_pre; -typedef agg::rgba16 color_type; -typedef agg::order_argb component_order; - -#elif defined(AGG_RGB565) - -#include "agg_pixfmt_rgb_packed.h" -#define pix_format agg::pix_format_rgb565 -typedef agg::pixfmt_rgb565 pixfmt; -typedef agg::pixfmt_rgb565_pre pixfmt_pre; -typedef agg::rgba8 color_type; - -#elif defined(AGG_RGB555) - -#include "agg_pixfmt_rgb_packed.h" -#define pix_format agg::pix_format_rgb555 -typedef agg::pixfmt_rgb555 pixfmt; -typedef agg::pixfmt_rgb555_pre pixfmt_pre; -typedef agg::rgba8 color_type; - -#elif defined(AGG_RGB_AAA) - -#include "agg_pixfmt_rgb_packed.h" -#define pix_format agg::pix_format_rgbAAA -typedef agg::pixfmt_rgbAAA pixfmt; -typedef agg::pixfmt_rgbAAA_pre pixfmt_pre; -typedef agg::rgba16 color_type; - -#elif defined(AGG_BGR_AAA) - -#include "agg_pixfmt_rgb_packed.h" -#define pix_format agg::pix_format_bgrAAA -typedef agg::pixfmt_bgrAAA pixfmt; -typedef agg::pixfmt_bgrAAA_pre pixfmt_pre; -typedef agg::rgba16 color_type; - -#elif defined(AGG_RGB_BBA) - -#include "agg_pixfmt_rgb_packed.h" -#define pix_format agg::pix_format_rgbBBA -typedef agg::pixfmt_rgbBBA pixfmt; -typedef agg::pixfmt_rgbBBA_pre pixfmt_pre; -typedef agg::rgba16 color_type; - -#elif defined(AGG_BGR_ABB) - -#include "agg_pixfmt_rgb_packed.h" -#define pix_format agg::pix_format_bgrABB -typedef agg::pixfmt_bgrABB pixfmt; -typedef agg::pixfmt_bgrABB_pre pixfmt_pre; -typedef agg::rgba16 color_type; - -#else -#error Please define pixel format: AGG_GRAY8, AGG_BGR24, AGG_RGB24, etc. See this file above -#endif - -#endif diff --git a/desmume/src/windows/agg/font_freetype/agg_font_freetype.cpp b/desmume/src/windows/agg/font_freetype/agg_font_freetype.cpp deleted file mode 100644 index b0f462265..000000000 --- a/desmume/src/windows/agg/font_freetype/agg_font_freetype.cpp +++ /dev/null @@ -1,1155 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#include -#include "agg_font_freetype.h" -#include "agg_bitset_iterator.h" -#include "agg_renderer_scanline.h" - - -namespace agg -{ - - //------------------------------------------------------------------------------ - // - // This code implements the AUTODIN II polynomial - // The variable corresponding to the macro argument "crc" should - // be an unsigned long. - // Oroginal code by Spencer Garrett - // - - // generated using the AUTODIN II polynomial - // x^32 + x^26 + x^23 + x^22 + x^16 + - // x^12 + x^11 + x^10 + x^8 + x^7 + x^5 + x^4 + x^2 + x^1 + 1 - // - //------------------------------------------------------------------------------ - - static const unsigned crc32tab[256] = - { - 0x00000000, 0x77073096, 0xee0e612c, 0x990951ba, - 0x076dc419, 0x706af48f, 0xe963a535, 0x9e6495a3, - 0x0edb8832, 0x79dcb8a4, 0xe0d5e91e, 0x97d2d988, - 0x09b64c2b, 0x7eb17cbd, 0xe7b82d07, 0x90bf1d91, - 0x1db71064, 0x6ab020f2, 0xf3b97148, 0x84be41de, - 0x1adad47d, 0x6ddde4eb, 0xf4d4b551, 0x83d385c7, - 0x136c9856, 0x646ba8c0, 0xfd62f97a, 0x8a65c9ec, - 0x14015c4f, 0x63066cd9, 0xfa0f3d63, 0x8d080df5, - 0x3b6e20c8, 0x4c69105e, 0xd56041e4, 0xa2677172, - 0x3c03e4d1, 0x4b04d447, 0xd20d85fd, 0xa50ab56b, - 0x35b5a8fa, 0x42b2986c, 0xdbbbc9d6, 0xacbcf940, - 0x32d86ce3, 0x45df5c75, 0xdcd60dcf, 0xabd13d59, - 0x26d930ac, 0x51de003a, 0xc8d75180, 0xbfd06116, - 0x21b4f4b5, 0x56b3c423, 0xcfba9599, 0xb8bda50f, - 0x2802b89e, 0x5f058808, 0xc60cd9b2, 0xb10be924, - 0x2f6f7c87, 0x58684c11, 0xc1611dab, 0xb6662d3d, - 0x76dc4190, 0x01db7106, 0x98d220bc, 0xefd5102a, - 0x71b18589, 0x06b6b51f, 0x9fbfe4a5, 0xe8b8d433, - 0x7807c9a2, 0x0f00f934, 0x9609a88e, 0xe10e9818, - 0x7f6a0dbb, 0x086d3d2d, 0x91646c97, 0xe6635c01, - 0x6b6b51f4, 0x1c6c6162, 0x856530d8, 0xf262004e, - 0x6c0695ed, 0x1b01a57b, 0x8208f4c1, 0xf50fc457, - 0x65b0d9c6, 0x12b7e950, 0x8bbeb8ea, 0xfcb9887c, - 0x62dd1ddf, 0x15da2d49, 0x8cd37cf3, 0xfbd44c65, - 0x4db26158, 0x3ab551ce, 0xa3bc0074, 0xd4bb30e2, - 0x4adfa541, 0x3dd895d7, 0xa4d1c46d, 0xd3d6f4fb, - 0x4369e96a, 0x346ed9fc, 0xad678846, 0xda60b8d0, - 0x44042d73, 0x33031de5, 0xaa0a4c5f, 0xdd0d7cc9, - 0x5005713c, 0x270241aa, 0xbe0b1010, 0xc90c2086, - 0x5768b525, 0x206f85b3, 0xb966d409, 0xce61e49f, - 0x5edef90e, 0x29d9c998, 0xb0d09822, 0xc7d7a8b4, - 0x59b33d17, 0x2eb40d81, 0xb7bd5c3b, 0xc0ba6cad, - 0xedb88320, 0x9abfb3b6, 0x03b6e20c, 0x74b1d29a, - 0xead54739, 0x9dd277af, 0x04db2615, 0x73dc1683, - 0xe3630b12, 0x94643b84, 0x0d6d6a3e, 0x7a6a5aa8, - 0xe40ecf0b, 0x9309ff9d, 0x0a00ae27, 0x7d079eb1, - 0xf00f9344, 0x8708a3d2, 0x1e01f268, 0x6906c2fe, - 0xf762575d, 0x806567cb, 0x196c3671, 0x6e6b06e7, - 0xfed41b76, 0x89d32be0, 0x10da7a5a, 0x67dd4acc, - 0xf9b9df6f, 0x8ebeeff9, 0x17b7be43, 0x60b08ed5, - 0xd6d6a3e8, 0xa1d1937e, 0x38d8c2c4, 0x4fdff252, - 0xd1bb67f1, 0xa6bc5767, 0x3fb506dd, 0x48b2364b, - 0xd80d2bda, 0xaf0a1b4c, 0x36034af6, 0x41047a60, - 0xdf60efc3, 0xa867df55, 0x316e8eef, 0x4669be79, - 0xcb61b38c, 0xbc66831a, 0x256fd2a0, 0x5268e236, - 0xcc0c7795, 0xbb0b4703, 0x220216b9, 0x5505262f, - 0xc5ba3bbe, 0xb2bd0b28, 0x2bb45a92, 0x5cb36a04, - 0xc2d7ffa7, 0xb5d0cf31, 0x2cd99e8b, 0x5bdeae1d, - 0x9b64c2b0, 0xec63f226, 0x756aa39c, 0x026d930a, - 0x9c0906a9, 0xeb0e363f, 0x72076785, 0x05005713, - 0x95bf4a82, 0xe2b87a14, 0x7bb12bae, 0x0cb61b38, - 0x92d28e9b, 0xe5d5be0d, 0x7cdcefb7, 0x0bdbdf21, - 0x86d3d2d4, 0xf1d4e242, 0x68ddb3f8, 0x1fda836e, - 0x81be16cd, 0xf6b9265b, 0x6fb077e1, 0x18b74777, - 0x88085ae6, 0xff0f6a70, 0x66063bca, 0x11010b5c, - 0x8f659eff, 0xf862ae69, 0x616bffd3, 0x166ccf45, - 0xa00ae278, 0xd70dd2ee, 0x4e048354, 0x3903b3c2, - 0xa7672661, 0xd06016f7, 0x4969474d, 0x3e6e77db, - 0xaed16a4a, 0xd9d65adc, 0x40df0b66, 0x37d83bf0, - 0xa9bcae53, 0xdebb9ec5, 0x47b2cf7f, 0x30b5ffe9, - 0xbdbdf21c, 0xcabac28a, 0x53b39330, 0x24b4a3a6, - 0xbad03605, 0xcdd70693, 0x54de5729, 0x23d967bf, - 0xb3667a2e, 0xc4614ab8, 0x5d681b02, 0x2a6f2b94, - 0xb40bbe37, 0xc30c8ea1, 0x5a05df1b, 0x2d02ef8d, - }; - - - //------------------------------------------------------------------------------ - - static unsigned calc_crc32(const unsigned char* buf, unsigned size) - { - unsigned crc = (unsigned)~0; - const unsigned char* p; - unsigned len = 0; - unsigned nr = size; - - for (len += nr, p = buf; nr--; ++p) - { - crc = (crc >> 8) ^ crc32tab[(crc ^ *p) & 0xff]; - } - return ~crc; - } - - //------------------------------------------------------------------------ - static inline int dbl_to_plain_fx(double d) - { - return int(d * 65536.0); - } - - //------------------------------------------------------------------------ - static inline double int26p6_to_dbl(int p) - { - return double(p) / 64.0; - } - - //------------------------------------------------------------------------ - static inline int dbl_to_int26p6(double p) - { - return int(p * 64.0 + 0.5); - } - - - //------------------------------------------------------------------------ - template - bool decompose_ft_outline(const FT_Outline& outline, - bool flip_y, - const trans_affine& mtx, - PathStorage& path) - { - typedef typename PathStorage::value_type value_type; - - FT_Vector v_last; - FT_Vector v_control; - FT_Vector v_start; - double x1, y1, x2, y2, x3, y3; - - FT_Vector* point; - FT_Vector* limit; - char* tags; - - int n; // index of contour in outline - int first; // index of first point in contour - char tag; // current point's state - - first = 0; - - for(n = 0; n < outline.n_contours; n++) - { - int last; // index of last point in contour - - last = outline.contours[n]; - limit = outline.points + last; - - v_start = outline.points[first]; - v_last = outline.points[last]; - - v_control = v_start; - - point = outline.points + first; - tags = outline.tags + first; - tag = FT_CURVE_TAG(tags[0]); - - // A contour cannot start with a cubic control point! - if(tag == FT_CURVE_TAG_CUBIC) return false; - - // check first point to determine origin - if( tag == FT_CURVE_TAG_CONIC) - { - // first point is conic control. Yes, this happens. - if(FT_CURVE_TAG(outline.tags[last]) == FT_CURVE_TAG_ON) - { - // start at last point if it is on the curve - v_start = v_last; - limit--; - } - else - { - // if both first and last points are conic, - // start at their middle and record its position - // for closure - v_start.x = (v_start.x + v_last.x) / 2; - v_start.y = (v_start.y + v_last.y) / 2; - - v_last = v_start; - } - point--; - tags--; - } - - x1 = int26p6_to_dbl(v_start.x); - y1 = int26p6_to_dbl(v_start.y); - if(flip_y) y1 = -y1; - mtx.transform(&x1, &y1); - path.move_to(value_type(dbl_to_int26p6(x1)), - value_type(dbl_to_int26p6(y1))); - - while(point < limit) - { - point++; - tags++; - - tag = FT_CURVE_TAG(tags[0]); - switch(tag) - { - case FT_CURVE_TAG_ON: // emit a single line_to - { - x1 = int26p6_to_dbl(point->x); - y1 = int26p6_to_dbl(point->y); - if(flip_y) y1 = -y1; - mtx.transform(&x1, &y1); - path.line_to(value_type(dbl_to_int26p6(x1)), - value_type(dbl_to_int26p6(y1))); - //path.line_to(conv(point->x), flip_y ? -conv(point->y) : conv(point->y)); - continue; - } - - case FT_CURVE_TAG_CONIC: // consume conic arcs - { - v_control.x = point->x; - v_control.y = point->y; - - Do_Conic: - if(point < limit) - { - FT_Vector vec; - FT_Vector v_middle; - - point++; - tags++; - tag = FT_CURVE_TAG(tags[0]); - - vec.x = point->x; - vec.y = point->y; - - if(tag == FT_CURVE_TAG_ON) - { - x1 = int26p6_to_dbl(v_control.x); - y1 = int26p6_to_dbl(v_control.y); - x2 = int26p6_to_dbl(vec.x); - y2 = int26p6_to_dbl(vec.y); - if(flip_y) { y1 = -y1; y2 = -y2; } - mtx.transform(&x1, &y1); - mtx.transform(&x2, &y2); - path.curve3(value_type(dbl_to_int26p6(x1)), - value_type(dbl_to_int26p6(y1)), - value_type(dbl_to_int26p6(x2)), - value_type(dbl_to_int26p6(y2))); - continue; - } - - if(tag != FT_CURVE_TAG_CONIC) return false; - - v_middle.x = (v_control.x + vec.x) / 2; - v_middle.y = (v_control.y + vec.y) / 2; - - x1 = int26p6_to_dbl(v_control.x); - y1 = int26p6_to_dbl(v_control.y); - x2 = int26p6_to_dbl(v_middle.x); - y2 = int26p6_to_dbl(v_middle.y); - if(flip_y) { y1 = -y1; y2 = -y2; } - mtx.transform(&x1, &y1); - mtx.transform(&x2, &y2); - path.curve3(value_type(dbl_to_int26p6(x1)), - value_type(dbl_to_int26p6(y1)), - value_type(dbl_to_int26p6(x2)), - value_type(dbl_to_int26p6(y2))); - - //path.curve3(conv(v_control.x), - // flip_y ? -conv(v_control.y) : conv(v_control.y), - // conv(v_middle.x), - // flip_y ? -conv(v_middle.y) : conv(v_middle.y)); - - v_control = vec; - goto Do_Conic; - } - - x1 = int26p6_to_dbl(v_control.x); - y1 = int26p6_to_dbl(v_control.y); - x2 = int26p6_to_dbl(v_start.x); - y2 = int26p6_to_dbl(v_start.y); - if(flip_y) { y1 = -y1; y2 = -y2; } - mtx.transform(&x1, &y1); - mtx.transform(&x2, &y2); - path.curve3(value_type(dbl_to_int26p6(x1)), - value_type(dbl_to_int26p6(y1)), - value_type(dbl_to_int26p6(x2)), - value_type(dbl_to_int26p6(y2))); - - //path.curve3(conv(v_control.x), - // flip_y ? -conv(v_control.y) : conv(v_control.y), - // conv(v_start.x), - // flip_y ? -conv(v_start.y) : conv(v_start.y)); - goto Close; - } - - default: // FT_CURVE_TAG_CUBIC - { - FT_Vector vec1, vec2; - - if(point + 1 > limit || FT_CURVE_TAG(tags[1]) != FT_CURVE_TAG_CUBIC) - { - return false; - } - - vec1.x = point[0].x; - vec1.y = point[0].y; - vec2.x = point[1].x; - vec2.y = point[1].y; - - point += 2; - tags += 2; - - if(point <= limit) - { - FT_Vector vec; - - vec.x = point->x; - vec.y = point->y; - - x1 = int26p6_to_dbl(vec1.x); - y1 = int26p6_to_dbl(vec1.y); - x2 = int26p6_to_dbl(vec2.x); - y2 = int26p6_to_dbl(vec2.y); - x3 = int26p6_to_dbl(vec.x); - y3 = int26p6_to_dbl(vec.y); - if(flip_y) { y1 = -y1; y2 = -y2; y3 = -y3; } - mtx.transform(&x1, &y1); - mtx.transform(&x2, &y2); - mtx.transform(&x3, &y3); - path.curve4(value_type(dbl_to_int26p6(x1)), - value_type(dbl_to_int26p6(y1)), - value_type(dbl_to_int26p6(x2)), - value_type(dbl_to_int26p6(y2)), - value_type(dbl_to_int26p6(x3)), - value_type(dbl_to_int26p6(y3))); - - //path.curve4(conv(vec1.x), - // flip_y ? -conv(vec1.y) : conv(vec1.y), - // conv(vec2.x), - // flip_y ? -conv(vec2.y) : conv(vec2.y), - // conv(vec.x), - // flip_y ? -conv(vec.y) : conv(vec.y)); - continue; - } - - x1 = int26p6_to_dbl(vec1.x); - y1 = int26p6_to_dbl(vec1.y); - x2 = int26p6_to_dbl(vec2.x); - y2 = int26p6_to_dbl(vec2.y); - x3 = int26p6_to_dbl(v_start.x); - y3 = int26p6_to_dbl(v_start.y); - if(flip_y) { y1 = -y1; y2 = -y2; y3 = -y3; } - mtx.transform(&x1, &y1); - mtx.transform(&x2, &y2); - mtx.transform(&x3, &y3); - path.curve4(value_type(dbl_to_int26p6(x1)), - value_type(dbl_to_int26p6(y1)), - value_type(dbl_to_int26p6(x2)), - value_type(dbl_to_int26p6(y2)), - value_type(dbl_to_int26p6(x3)), - value_type(dbl_to_int26p6(y3))); - - //path.curve4(conv(vec1.x), - // flip_y ? -conv(vec1.y) : conv(vec1.y), - // conv(vec2.x), - // flip_y ? -conv(vec2.y) : conv(vec2.y), - // conv(v_start.x), - // flip_y ? -conv(v_start.y) : conv(v_start.y)); - goto Close; - } - } - } - - path.close_polygon(); - - Close: - first = last + 1; - } - - return true; - } - - - - //------------------------------------------------------------------------ - template - void decompose_ft_bitmap_mono(const FT_Bitmap& bitmap, - int x, int y, - bool flip_y, - Scanline& sl, - ScanlineStorage& storage) - { - int i; - const int8u* buf = (const int8u*)bitmap.buffer; - int pitch = bitmap.pitch; - sl.reset(x, x + bitmap.width); - storage.prepare(); - if(flip_y) - { - buf += bitmap.pitch * (bitmap.rows - 1); - y += bitmap.rows; - pitch = -pitch; - } - for(i = 0; i < bitmap.rows; i++) - { - sl.reset_spans(); - bitset_iterator bits(buf, 0); - int j; - for(j = 0; j < bitmap.width; j++) - { - if(bits.bit()) sl.add_cell(x + j, cover_full); - ++bits; - } - buf += pitch; - if(sl.num_spans()) - { - sl.finalize(y - i - 1); - storage.render(sl); - } - } - } - - - - //------------------------------------------------------------------------ - template - void decompose_ft_bitmap_gray8(const FT_Bitmap& bitmap, - int x, int y, - bool flip_y, - Rasterizer& ras, - Scanline& sl, - ScanlineStorage& storage) - { - int i, j; - const int8u* buf = (const int8u*)bitmap.buffer; - int pitch = bitmap.pitch; - sl.reset(x, x + bitmap.width); - storage.prepare(); - if(flip_y) - { - buf += bitmap.pitch * (bitmap.rows - 1); - y += bitmap.rows; - pitch = -pitch; - } - for(i = 0; i < bitmap.rows; i++) - { - sl.reset_spans(); - const int8u* p = buf; - for(j = 0; j < bitmap.width; j++) - { - if(*p) sl.add_cell(x + j, ras.apply_gamma(*p)); - ++p; - } - buf += pitch; - if(sl.num_spans()) - { - sl.finalize(y - i - 1); - storage.render(sl); - } - } - } - - - - - - - - - - - - - - //------------------------------------------------------------------------ - font_engine_freetype_base::~font_engine_freetype_base() - { - unsigned i; - for(i = 0; i < m_num_faces; ++i) - { - delete [] m_face_names[i]; - FT_Done_Face(m_faces[i]); - } - delete [] m_face_names; - delete [] m_faces; - delete [] m_signature; - if(m_library_initialized) FT_Done_FreeType(m_library); - } - - - //------------------------------------------------------------------------ - font_engine_freetype_base::font_engine_freetype_base(bool flag32, - unsigned max_faces) : - m_flag32(flag32), - m_change_stamp(0), - m_last_error(0), - m_name(0), - m_name_len(256-16-1), - m_face_index(0), - m_char_map(FT_ENCODING_NONE), - m_signature(new char [256+256-16]), - m_height(0), - m_width(0), - m_hinting(true), - m_flip_y(false), - m_library_initialized(false), - m_library(0), - m_faces(new FT_Face [max_faces]), - m_face_names(new char* [max_faces]), - m_num_faces(0), - m_max_faces(max_faces), - m_cur_face(0), - m_resolution(0), - m_glyph_rendering(glyph_ren_native_gray8), - m_glyph_index(0), - m_data_size(0), - m_data_type(glyph_data_invalid), - m_bounds(1,1,0,0), - m_advance_x(0.0), - m_advance_y(0.0), - - m_path16(), - m_path32(), - m_curves16(m_path16), - m_curves32(m_path32), - m_scanline_aa(), - m_scanline_bin(), - m_scanlines_aa(), - m_scanlines_bin(), - m_rasterizer() - { - m_curves16.approximation_scale(4.0); - m_curves32.approximation_scale(4.0); - m_last_error = FT_Init_FreeType(&m_library); - if(m_last_error == 0) m_library_initialized = true; - } - - - - //------------------------------------------------------------------------ - void font_engine_freetype_base::resolution(unsigned dpi) - { - m_resolution = dpi; - update_char_size(); - } - - - //------------------------------------------------------------------------ - int font_engine_freetype_base::find_face(const char* face_name) const - { - unsigned i; - for(i = 0; i < m_num_faces; ++i) - { - if(strcmp(face_name, m_face_names[i]) == 0) return i; - } - return -1; - } - - - //------------------------------------------------------------------------ - double font_engine_freetype_base::ascender() const - { - if(m_cur_face) - { - return m_cur_face->ascender * height() / m_cur_face->height; - } - return 0.0; - } - - //------------------------------------------------------------------------ - double font_engine_freetype_base::descender() const - { - if(m_cur_face) - { - return m_cur_face->descender * height() / m_cur_face->height; - } - return 0.0; - } - - - //------------------------------------------------------------------------ - bool font_engine_freetype_base::load_font(const char* font_name, - unsigned face_index, - glyph_rendering ren_type, - const char* font_mem, - const long font_mem_size) - { - bool ret = false; - - if(m_library_initialized) - { - m_last_error = 0; - - int idx = find_face(font_name); - if(idx >= 0) - { - m_cur_face = m_faces[idx]; - m_name = m_face_names[idx]; - } - else - { - if(m_num_faces >= m_max_faces) - { - delete [] m_face_names[0]; - FT_Done_Face(m_faces[0]); - memcpy(m_faces, - m_faces + 1, - (m_max_faces - 1) * sizeof(FT_Face)); - memcpy(m_face_names, - m_face_names + 1, - (m_max_faces - 1) * sizeof(char*)); - m_num_faces = m_max_faces - 1; - } - - if (font_mem && font_mem_size) - { - m_last_error = FT_New_Memory_Face(m_library, - (const FT_Byte*)font_mem, - font_mem_size, - face_index, - &m_faces[m_num_faces]); - } - else - { - m_last_error = FT_New_Face(m_library, - font_name, - face_index, - &m_faces[m_num_faces]); - } - - if(m_last_error == 0) - { - m_face_names[m_num_faces] = new char [strlen(font_name) + 1]; - strcpy(m_face_names[m_num_faces], font_name); - m_cur_face = m_faces[m_num_faces]; - m_name = m_face_names[m_num_faces]; - ++m_num_faces; - } - else - { - m_face_names[m_num_faces] = 0; - m_cur_face = 0; - m_name = 0; - } - } - - - if(m_last_error == 0) - { - ret = true; - - switch(ren_type) - { - case glyph_ren_native_mono: - m_glyph_rendering = glyph_ren_native_mono; - break; - - case glyph_ren_native_gray8: - m_glyph_rendering = glyph_ren_native_gray8; - break; - - case glyph_ren_outline: - if(FT_IS_SCALABLE(m_cur_face)) - { - m_glyph_rendering = glyph_ren_outline; - } - else - { - m_glyph_rendering = glyph_ren_native_gray8; - } - break; - - case glyph_ren_agg_mono: - if(FT_IS_SCALABLE(m_cur_face)) - { - m_glyph_rendering = glyph_ren_agg_mono; - } - else - { - m_glyph_rendering = glyph_ren_native_mono; - } - break; - - case glyph_ren_agg_gray8: - if(FT_IS_SCALABLE(m_cur_face)) - { - m_glyph_rendering = glyph_ren_agg_gray8; - } - else - { - m_glyph_rendering = glyph_ren_native_gray8; - } - break; - } - update_signature(); - } - } - return ret; - } - - - //------------------------------------------------------------------------ - bool font_engine_freetype_base::attach(const char* file_name) - { - if(m_cur_face) - { - m_last_error = FT_Attach_File(m_cur_face, file_name); - return m_last_error == 0; - } - return false; - } - - //------------------------------------------------------------------------ - unsigned font_engine_freetype_base::num_faces() const - { - if(m_cur_face) - { - return m_cur_face->num_faces; - } - return 0; - } - - //------------------------------------------------------------------------ - bool font_engine_freetype_base::char_map(FT_Encoding char_map) - { - if(m_cur_face) - { - m_last_error = FT_Select_Charmap(m_cur_face, m_char_map); - if(m_last_error == 0) - { - update_signature(); - return true; - } - } - return false; - } - - //------------------------------------------------------------------------ - bool font_engine_freetype_base::height(double h) - { - m_height = int(h * 64.0); - if(m_cur_face) - { - update_char_size(); - return true; - } - return false; - } - - //------------------------------------------------------------------------ - bool font_engine_freetype_base::width(double w) - { - m_width = int(w * 64.0); - if(m_cur_face) - { - update_char_size(); - return true; - } - return false; - } - - //------------------------------------------------------------------------ - void font_engine_freetype_base::hinting(bool h) - { - m_hinting = h; - if(m_cur_face) - { - update_signature(); - } - } - - //------------------------------------------------------------------------ - void font_engine_freetype_base::flip_y(bool f) - { - m_flip_y = f; - if(m_cur_face) - { - update_signature(); - } - } - - //------------------------------------------------------------------------ - void font_engine_freetype_base::transform(const trans_affine& affine) - { - m_affine = affine; - if(m_cur_face) - { - update_signature(); - } - } - - //------------------------------------------------------------------------ - void font_engine_freetype_base::update_signature() - { - if(m_cur_face && m_name) - { - unsigned name_len = strlen(m_name); - if(name_len > m_name_len) - { - delete [] m_signature; - m_signature = new char [name_len + 32 + 256]; - m_name_len = name_len + 32 - 1; - } - - unsigned gamma_hash = 0; - if(m_glyph_rendering == glyph_ren_native_gray8 || - m_glyph_rendering == glyph_ren_agg_mono || - m_glyph_rendering == glyph_ren_agg_gray8) - { - unsigned char gamma_table[rasterizer_scanline_aa<>::aa_scale]; - unsigned i; - for(i = 0; i < rasterizer_scanline_aa<>::aa_scale; ++i) - { - gamma_table[i] = m_rasterizer.apply_gamma(i); - } - gamma_hash = calc_crc32(gamma_table, sizeof(gamma_table)); - } - - sprintf(m_signature, - "%s,%u,%d,%d,%d:%dx%d,%d,%d,%08X", - m_name, - m_char_map, - m_face_index, - int(m_glyph_rendering), - m_resolution, - m_height, - m_width, - int(m_hinting), - int(m_flip_y), - gamma_hash); - if(m_glyph_rendering == glyph_ren_outline || - m_glyph_rendering == glyph_ren_agg_mono || - m_glyph_rendering == glyph_ren_agg_gray8) - { - double mtx[6]; - char buf[100]; - m_affine.store_to(mtx); - sprintf(buf, ",%08X%08X%08X%08X%08X%08X", - dbl_to_plain_fx(mtx[0]), - dbl_to_plain_fx(mtx[1]), - dbl_to_plain_fx(mtx[2]), - dbl_to_plain_fx(mtx[3]), - dbl_to_plain_fx(mtx[4]), - dbl_to_plain_fx(mtx[5])); - strcat(m_signature, buf); - } - ++m_change_stamp; - } - } - - - //------------------------------------------------------------------------ - void font_engine_freetype_base::update_char_size() - { - if(m_cur_face) - { - if(m_resolution) - { - FT_Set_Char_Size(m_cur_face, - m_width, // char_width in 1/64th of points - m_height, // char_height in 1/64th of points - m_resolution, // horizontal device resolution - m_resolution); // vertical device resolution - } - else - { - FT_Set_Pixel_Sizes(m_cur_face, - m_width >> 6, // pixel_width - m_height >> 6); // pixel_height - } - update_signature(); - } - } - - - - - - //------------------------------------------------------------------------ - bool font_engine_freetype_base::prepare_glyph(unsigned glyph_code) - { - m_glyph_index = FT_Get_Char_Index(m_cur_face, glyph_code); - m_last_error = FT_Load_Glyph(m_cur_face, - m_glyph_index, - m_hinting ? FT_LOAD_DEFAULT : FT_LOAD_NO_HINTING); -// m_hinting ? FT_LOAD_FORCE_AUTOHINT : FT_LOAD_NO_HINTING); - if(m_last_error == 0) - { - switch(m_glyph_rendering) - { - case glyph_ren_native_mono: - m_last_error = FT_Render_Glyph(m_cur_face->glyph, FT_RENDER_MODE_MONO); - if(m_last_error == 0) - { - decompose_ft_bitmap_mono(m_cur_face->glyph->bitmap, - m_cur_face->glyph->bitmap_left, - m_flip_y ? -m_cur_face->glyph->bitmap_top : - m_cur_face->glyph->bitmap_top, - m_flip_y, - m_scanline_bin, - m_scanlines_bin); - m_bounds.x1 = m_scanlines_bin.min_x(); - m_bounds.y1 = m_scanlines_bin.min_y(); - m_bounds.x2 = m_scanlines_bin.max_x() + 1; - m_bounds.y2 = m_scanlines_bin.max_y() + 1; - m_data_size = m_scanlines_bin.byte_size(); - m_data_type = glyph_data_mono; - m_advance_x = int26p6_to_dbl(m_cur_face->glyph->advance.x); - m_advance_y = int26p6_to_dbl(m_cur_face->glyph->advance.y); - return true; - } - break; - - - case glyph_ren_native_gray8: - m_last_error = FT_Render_Glyph(m_cur_face->glyph, FT_RENDER_MODE_NORMAL); - if(m_last_error == 0) - { - decompose_ft_bitmap_gray8(m_cur_face->glyph->bitmap, - m_cur_face->glyph->bitmap_left, - m_flip_y ? -m_cur_face->glyph->bitmap_top : - m_cur_face->glyph->bitmap_top, - m_flip_y, - m_rasterizer, - m_scanline_aa, - m_scanlines_aa); - m_bounds.x1 = m_scanlines_aa.min_x(); - m_bounds.y1 = m_scanlines_aa.min_y(); - m_bounds.x2 = m_scanlines_aa.max_x() + 1; - m_bounds.y2 = m_scanlines_aa.max_y() + 1; - m_data_size = m_scanlines_aa.byte_size(); - m_data_type = glyph_data_gray8; - m_advance_x = int26p6_to_dbl(m_cur_face->glyph->advance.x); - m_advance_y = int26p6_to_dbl(m_cur_face->glyph->advance.y); - return true; - } - break; - - - case glyph_ren_outline: - if(m_last_error == 0) - { - if(m_flag32) - { - m_path32.remove_all(); - if(decompose_ft_outline(m_cur_face->glyph->outline, - m_flip_y, - m_affine, - m_path32)) - { - rect_d bnd = m_path32.bounding_rect(); - m_data_size = m_path32.byte_size(); - m_data_type = glyph_data_outline; - m_bounds.x1 = int(floor(bnd.x1)); - m_bounds.y1 = int(floor(bnd.y1)); - m_bounds.x2 = int(ceil(bnd.x2)); - m_bounds.y2 = int(ceil(bnd.y2)); - m_advance_x = int26p6_to_dbl(m_cur_face->glyph->advance.x); - m_advance_y = int26p6_to_dbl(m_cur_face->glyph->advance.y); - m_affine.transform(&m_advance_x, &m_advance_y); - return true; - } - } - else - { - m_path16.remove_all(); - if(decompose_ft_outline(m_cur_face->glyph->outline, - m_flip_y, - m_affine, - m_path16)) - { - rect_d bnd = m_path16.bounding_rect(); - m_data_size = m_path16.byte_size(); - m_data_type = glyph_data_outline; - m_bounds.x1 = int(floor(bnd.x1)); - m_bounds.y1 = int(floor(bnd.y1)); - m_bounds.x2 = int(ceil(bnd.x2)); - m_bounds.y2 = int(ceil(bnd.y2)); - m_advance_x = int26p6_to_dbl(m_cur_face->glyph->advance.x); - m_advance_y = int26p6_to_dbl(m_cur_face->glyph->advance.y); - m_affine.transform(&m_advance_x, &m_advance_y); - return true; - } - } - } - return false; - - case glyph_ren_agg_mono: - if(m_last_error == 0) - { - m_rasterizer.reset(); - if(m_flag32) - { - m_path32.remove_all(); - decompose_ft_outline(m_cur_face->glyph->outline, - m_flip_y, - m_affine, - m_path32); - m_rasterizer.add_path(m_curves32); - } - else - { - m_path16.remove_all(); - decompose_ft_outline(m_cur_face->glyph->outline, - m_flip_y, - m_affine, - m_path16); - m_rasterizer.add_path(m_curves16); - } - m_scanlines_bin.prepare(); // Remove all - render_scanlines(m_rasterizer, m_scanline_bin, m_scanlines_bin); - m_bounds.x1 = m_scanlines_bin.min_x(); - m_bounds.y1 = m_scanlines_bin.min_y(); - m_bounds.x2 = m_scanlines_bin.max_x() + 1; - m_bounds.y2 = m_scanlines_bin.max_y() + 1; - m_data_size = m_scanlines_bin.byte_size(); - m_data_type = glyph_data_mono; - m_advance_x = int26p6_to_dbl(m_cur_face->glyph->advance.x); - m_advance_y = int26p6_to_dbl(m_cur_face->glyph->advance.y); - m_affine.transform(&m_advance_x, &m_advance_y); - return true; - } - return false; - - - case glyph_ren_agg_gray8: - if(m_last_error == 0) - { - m_rasterizer.reset(); - if(m_flag32) - { - m_path32.remove_all(); - decompose_ft_outline(m_cur_face->glyph->outline, - m_flip_y, - m_affine, - m_path32); - m_rasterizer.add_path(m_curves32); - } - else - { - m_path16.remove_all(); - decompose_ft_outline(m_cur_face->glyph->outline, - m_flip_y, - m_affine, - m_path16); - m_rasterizer.add_path(m_curves16); - } - m_scanlines_aa.prepare(); // Remove all - render_scanlines(m_rasterizer, m_scanline_aa, m_scanlines_aa); - m_bounds.x1 = m_scanlines_aa.min_x(); - m_bounds.y1 = m_scanlines_aa.min_y(); - m_bounds.x2 = m_scanlines_aa.max_x() + 1; - m_bounds.y2 = m_scanlines_aa.max_y() + 1; - m_data_size = m_scanlines_aa.byte_size(); - m_data_type = glyph_data_gray8; - m_advance_x = int26p6_to_dbl(m_cur_face->glyph->advance.x); - m_advance_y = int26p6_to_dbl(m_cur_face->glyph->advance.y); - m_affine.transform(&m_advance_x, &m_advance_y); - return true; - } - return false; - } - } - return false; - } - - - - - //------------------------------------------------------------------------ - void font_engine_freetype_base::write_glyph_to(int8u* data) const - { - if(data && m_data_size) - { - switch(m_data_type) - { - default: return; - case glyph_data_mono: m_scanlines_bin.serialize(data); break; - case glyph_data_gray8: m_scanlines_aa.serialize(data); break; - case glyph_data_outline: - if(m_flag32) - { - m_path32.serialize(data); - } - else - { - m_path16.serialize(data); - } - break; - case glyph_data_invalid: break; - } - } - } - - - - //------------------------------------------------------------------------ - bool font_engine_freetype_base::add_kerning(unsigned first, unsigned second, - double* x, double* y) - { - if(m_cur_face && first && second && FT_HAS_KERNING(m_cur_face)) - { - FT_Vector delta; - FT_Get_Kerning(m_cur_face, first, second, - FT_KERNING_DEFAULT, &delta); - double dx = int26p6_to_dbl(delta.x); - double dy = int26p6_to_dbl(delta.y); - if(m_glyph_rendering == glyph_ren_outline || - m_glyph_rendering == glyph_ren_agg_mono || - m_glyph_rendering == glyph_ren_agg_gray8) - { - m_affine.transform_2x2(&dx, &dy); - } - *x += dx; - *y += dy; - - return true; - } - return false; - } - - - -} - - diff --git a/desmume/src/windows/agg/font_freetype/agg_font_freetype.h b/desmume/src/windows/agg/font_freetype/agg_font_freetype.h deleted file mode 100644 index db923eb5a..000000000 --- a/desmume/src/windows/agg/font_freetype/agg_font_freetype.h +++ /dev/null @@ -1,201 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_FONT_FREETYPE_INCLUDED -#define AGG_FONT_FREETYPE_INCLUDED - -#include -#include FT_FREETYPE_H - - -#include "agg_scanline_storage_aa.h" -#include "agg_scanline_storage_bin.h" -#include "agg_scanline_u.h" -#include "agg_scanline_bin.h" -#include "agg_path_storage_integer.h" -#include "agg_rasterizer_scanline_aa.h" -#include "agg_conv_curve.h" -#include "agg_font_cache_manager.h" -#include "agg_trans_affine.h" - -namespace agg -{ - - - //-----------------------------------------------font_engine_freetype_base - class font_engine_freetype_base - { - public: - //-------------------------------------------------------------------- - typedef serialized_scanlines_adaptor_aa gray8_adaptor_type; - typedef serialized_scanlines_adaptor_bin mono_adaptor_type; - typedef scanline_storage_aa8 scanlines_aa_type; - typedef scanline_storage_bin scanlines_bin_type; - - //-------------------------------------------------------------------- - ~font_engine_freetype_base(); - font_engine_freetype_base(bool flag32, unsigned max_faces = 32); - - // Set font parameters - //-------------------------------------------------------------------- - void resolution(unsigned dpi); - bool load_font(const char* font_name, unsigned face_index, glyph_rendering ren_type, - const char* font_mem = 0, const long font_mem_size = 0); - bool attach(const char* file_name); - bool char_map(FT_Encoding map); - bool height(double h); - bool width(double w); - void hinting(bool h); - void flip_y(bool f); - void transform(const trans_affine& affine); - - // Set Gamma - //-------------------------------------------------------------------- - template void gamma(const GammaF& f) - { - m_rasterizer.gamma(f); - } - - // Accessors - //-------------------------------------------------------------------- - int last_error() const { return m_last_error; } - unsigned resolution() const { return m_resolution; } - const char* name() const { return m_name; } - unsigned num_faces() const; - FT_Encoding char_map() const { return m_char_map; } - double height() const { return double(m_height) / 64.0; } - double width() const { return double(m_width) / 64.0; } - double ascender() const; - double descender() const; - bool hinting() const { return m_hinting; } - bool flip_y() const { return m_flip_y; } - - - // Interface mandatory to implement for font_cache_manager - //-------------------------------------------------------------------- - const char* font_signature() const { return m_signature; } - int change_stamp() const { return m_change_stamp; } - - bool prepare_glyph(unsigned glyph_code); - unsigned glyph_index() const { return m_glyph_index; } - unsigned data_size() const { return m_data_size; } - glyph_data_type data_type() const { return m_data_type; } - const rect_i& bounds() const { return m_bounds; } - double advance_x() const { return m_advance_x; } - double advance_y() const { return m_advance_y; } - void write_glyph_to(int8u* data) const; - bool add_kerning(unsigned first, unsigned second, - double* x, double* y); - - private: - font_engine_freetype_base(const font_engine_freetype_base&); - const font_engine_freetype_base& operator = (const font_engine_freetype_base&); - - void update_char_size(); - void update_signature(); - int find_face(const char* face_name) const; - - bool m_flag32; - int m_change_stamp; - int m_last_error; - char* m_name; - unsigned m_name_len; - unsigned m_face_index; - FT_Encoding m_char_map; - char* m_signature; - unsigned m_height; - unsigned m_width; - bool m_hinting; - bool m_flip_y; - bool m_library_initialized; - FT_Library m_library; // handle to library - FT_Face* m_faces; // A pool of font faces - char** m_face_names; - unsigned m_num_faces; - unsigned m_max_faces; - FT_Face m_cur_face; // handle to the current face object - int m_resolution; - glyph_rendering m_glyph_rendering; - unsigned m_glyph_index; - unsigned m_data_size; - glyph_data_type m_data_type; - rect_i m_bounds; - double m_advance_x; - double m_advance_y; - trans_affine m_affine; - - path_storage_integer m_path16; - path_storage_integer m_path32; - conv_curve > m_curves16; - conv_curve > m_curves32; - scanline_u8 m_scanline_aa; - scanline_bin m_scanline_bin; - scanlines_aa_type m_scanlines_aa; - scanlines_bin_type m_scanlines_bin; - rasterizer_scanline_aa<> m_rasterizer; - }; - - - - - //------------------------------------------------font_engine_freetype_int16 - // This class uses values of type int16 (10.6 format) for the vector cache. - // The vector cache is compact, but when rendering glyphs of height - // more that 200 there integer overflow can occur. - // - class font_engine_freetype_int16 : public font_engine_freetype_base - { - public: - typedef serialized_integer_path_adaptor path_adaptor_type; - typedef font_engine_freetype_base::gray8_adaptor_type gray8_adaptor_type; - typedef font_engine_freetype_base::mono_adaptor_type mono_adaptor_type; - typedef font_engine_freetype_base::scanlines_aa_type scanlines_aa_type; - typedef font_engine_freetype_base::scanlines_bin_type scanlines_bin_type; - - font_engine_freetype_int16(unsigned max_faces = 32) : - font_engine_freetype_base(false, max_faces) {} - }; - - //------------------------------------------------font_engine_freetype_int32 - // This class uses values of type int32 (26.6 format) for the vector cache. - // The vector cache is twice larger than in font_engine_freetype_int16, - // but it allows you to render glyphs of very large sizes. - // - class font_engine_freetype_int32 : public font_engine_freetype_base - { - public: - typedef serialized_integer_path_adaptor path_adaptor_type; - typedef font_engine_freetype_base::gray8_adaptor_type gray8_adaptor_type; - typedef font_engine_freetype_base::mono_adaptor_type mono_adaptor_type; - typedef font_engine_freetype_base::scanlines_aa_type scanlines_aa_type; - typedef font_engine_freetype_base::scanlines_bin_type scanlines_bin_type; - - font_engine_freetype_int32(unsigned max_faces = 32) : - font_engine_freetype_base(true, max_faces) {} - }; - - -} - -#endif diff --git a/desmume/src/windows/agg/font_win32_tt/agg_font_win32_tt.cpp b/desmume/src/windows/agg/font_win32_tt/agg_font_win32_tt.cpp deleted file mode 100644 index a47794919..000000000 --- a/desmume/src/windows/agg/font_win32_tt/agg_font_win32_tt.cpp +++ /dev/null @@ -1,946 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#include -#include "agg_font_win32_tt.h" -#include "agg_bitset_iterator.h" -#include "agg_renderer_scanline.h" - -#ifdef AGG_WIN9X_COMPLIANT -#define GetGlyphOutlineX GetGlyphOutline -#else -#define GetGlyphOutlineX GetGlyphOutlineW -#endif - -namespace agg -{ - - //------------------------------------------------------------------------------ - // - // This code implements the AUTODIN II polynomial - // The variable corresponding to the macro argument "crc" should - // be an unsigned long. - // Oroginal code by Spencer Garrett - // - - // generated using the AUTODIN II polynomial - // x^32 + x^26 + x^23 + x^22 + x^16 + - // x^12 + x^11 + x^10 + x^8 + x^7 + x^5 + x^4 + x^2 + x^1 + 1 - // - //------------------------------------------------------------------------------ - - static const unsigned crc32tab[256] = - { - 0x00000000, 0x77073096, 0xee0e612c, 0x990951ba, - 0x076dc419, 0x706af48f, 0xe963a535, 0x9e6495a3, - 0x0edb8832, 0x79dcb8a4, 0xe0d5e91e, 0x97d2d988, - 0x09b64c2b, 0x7eb17cbd, 0xe7b82d07, 0x90bf1d91, - 0x1db71064, 0x6ab020f2, 0xf3b97148, 0x84be41de, - 0x1adad47d, 0x6ddde4eb, 0xf4d4b551, 0x83d385c7, - 0x136c9856, 0x646ba8c0, 0xfd62f97a, 0x8a65c9ec, - 0x14015c4f, 0x63066cd9, 0xfa0f3d63, 0x8d080df5, - 0x3b6e20c8, 0x4c69105e, 0xd56041e4, 0xa2677172, - 0x3c03e4d1, 0x4b04d447, 0xd20d85fd, 0xa50ab56b, - 0x35b5a8fa, 0x42b2986c, 0xdbbbc9d6, 0xacbcf940, - 0x32d86ce3, 0x45df5c75, 0xdcd60dcf, 0xabd13d59, - 0x26d930ac, 0x51de003a, 0xc8d75180, 0xbfd06116, - 0x21b4f4b5, 0x56b3c423, 0xcfba9599, 0xb8bda50f, - 0x2802b89e, 0x5f058808, 0xc60cd9b2, 0xb10be924, - 0x2f6f7c87, 0x58684c11, 0xc1611dab, 0xb6662d3d, - 0x76dc4190, 0x01db7106, 0x98d220bc, 0xefd5102a, - 0x71b18589, 0x06b6b51f, 0x9fbfe4a5, 0xe8b8d433, - 0x7807c9a2, 0x0f00f934, 0x9609a88e, 0xe10e9818, - 0x7f6a0dbb, 0x086d3d2d, 0x91646c97, 0xe6635c01, - 0x6b6b51f4, 0x1c6c6162, 0x856530d8, 0xf262004e, - 0x6c0695ed, 0x1b01a57b, 0x8208f4c1, 0xf50fc457, - 0x65b0d9c6, 0x12b7e950, 0x8bbeb8ea, 0xfcb9887c, - 0x62dd1ddf, 0x15da2d49, 0x8cd37cf3, 0xfbd44c65, - 0x4db26158, 0x3ab551ce, 0xa3bc0074, 0xd4bb30e2, - 0x4adfa541, 0x3dd895d7, 0xa4d1c46d, 0xd3d6f4fb, - 0x4369e96a, 0x346ed9fc, 0xad678846, 0xda60b8d0, - 0x44042d73, 0x33031de5, 0xaa0a4c5f, 0xdd0d7cc9, - 0x5005713c, 0x270241aa, 0xbe0b1010, 0xc90c2086, - 0x5768b525, 0x206f85b3, 0xb966d409, 0xce61e49f, - 0x5edef90e, 0x29d9c998, 0xb0d09822, 0xc7d7a8b4, - 0x59b33d17, 0x2eb40d81, 0xb7bd5c3b, 0xc0ba6cad, - 0xedb88320, 0x9abfb3b6, 0x03b6e20c, 0x74b1d29a, - 0xead54739, 0x9dd277af, 0x04db2615, 0x73dc1683, - 0xe3630b12, 0x94643b84, 0x0d6d6a3e, 0x7a6a5aa8, - 0xe40ecf0b, 0x9309ff9d, 0x0a00ae27, 0x7d079eb1, - 0xf00f9344, 0x8708a3d2, 0x1e01f268, 0x6906c2fe, - 0xf762575d, 0x806567cb, 0x196c3671, 0x6e6b06e7, - 0xfed41b76, 0x89d32be0, 0x10da7a5a, 0x67dd4acc, - 0xf9b9df6f, 0x8ebeeff9, 0x17b7be43, 0x60b08ed5, - 0xd6d6a3e8, 0xa1d1937e, 0x38d8c2c4, 0x4fdff252, - 0xd1bb67f1, 0xa6bc5767, 0x3fb506dd, 0x48b2364b, - 0xd80d2bda, 0xaf0a1b4c, 0x36034af6, 0x41047a60, - 0xdf60efc3, 0xa867df55, 0x316e8eef, 0x4669be79, - 0xcb61b38c, 0xbc66831a, 0x256fd2a0, 0x5268e236, - 0xcc0c7795, 0xbb0b4703, 0x220216b9, 0x5505262f, - 0xc5ba3bbe, 0xb2bd0b28, 0x2bb45a92, 0x5cb36a04, - 0xc2d7ffa7, 0xb5d0cf31, 0x2cd99e8b, 0x5bdeae1d, - 0x9b64c2b0, 0xec63f226, 0x756aa39c, 0x026d930a, - 0x9c0906a9, 0xeb0e363f, 0x72076785, 0x05005713, - 0x95bf4a82, 0xe2b87a14, 0x7bb12bae, 0x0cb61b38, - 0x92d28e9b, 0xe5d5be0d, 0x7cdcefb7, 0x0bdbdf21, - 0x86d3d2d4, 0xf1d4e242, 0x68ddb3f8, 0x1fda836e, - 0x81be16cd, 0xf6b9265b, 0x6fb077e1, 0x18b74777, - 0x88085ae6, 0xff0f6a70, 0x66063bca, 0x11010b5c, - 0x8f659eff, 0xf862ae69, 0x616bffd3, 0x166ccf45, - 0xa00ae278, 0xd70dd2ee, 0x4e048354, 0x3903b3c2, - 0xa7672661, 0xd06016f7, 0x4969474d, 0x3e6e77db, - 0xaed16a4a, 0xd9d65adc, 0x40df0b66, 0x37d83bf0, - 0xa9bcae53, 0xdebb9ec5, 0x47b2cf7f, 0x30b5ffe9, - 0xbdbdf21c, 0xcabac28a, 0x53b39330, 0x24b4a3a6, - 0xbad03605, 0xcdd70693, 0x54de5729, 0x23d967bf, - 0xb3667a2e, 0xc4614ab8, 0x5d681b02, 0x2a6f2b94, - 0xb40bbe37, 0xc30c8ea1, 0x5a05df1b, 0x2d02ef8d, - }; - - //------------------------------------------------------------------------------ - static unsigned calc_crc32(const unsigned char* buf, unsigned size) - { - unsigned crc = (unsigned)~0; - const unsigned char* p; - unsigned len = 0; - unsigned nr = size; - - for (len += nr, p = buf; nr--; ++p) - { - crc = (crc >> 8) ^ crc32tab[(crc ^ *p) & 0xff]; - } - return ~crc; - } - - //------------------------------------------------------------------------ - static inline FIXED dbl_to_fx(double d) - { - int l; - l = int(d * 65536.0); - return *(FIXED*)&l; - } - - //------------------------------------------------------------------------ - static inline int dbl_to_plain_fx(double d) - { - return int(d * 65536.0); - } - - //------------------------------------------------------------------------ - static inline FIXED negate_fx(const FIXED& fx) - { - int l = -(*(int*)(&fx)); - return *(FIXED*)&l; - } - - //------------------------------------------------------------------------ - static inline double fx_to_dbl(const FIXED& p) - { - return double(p.value) + double(p.fract) * (1.0 / 65536.0); - } - - //------------------------------------------------------------------------ - static inline int fx_to_plain_int(const FIXED& fx) - { - return *(int*)(&fx); - } - - //------------------------------------------------------------------------ - static inline int fx_to_int26p6(const FIXED& p) - { - return (int(p.value) << 6) + (int(p.fract) >> 10); - } - - //------------------------------------------------------------------------ - static inline int dbl_to_int26p6(double p) - { - return int(p * 64.0 + 0.5); - } - - //------------------------------------------------------------------------ - template - void decompose_win32_glyph_bitmap_mono(const char* gbuf, - int w, int h, - int x, int y, - bool flip_y, - Scanline& sl, - ScanlineStorage& storage) - { - int i; - int pitch = ((w + 31) >> 5) << 2; - const int8u* buf = (const int8u*)gbuf; - sl.reset(x, x + w); - storage.prepare(); - if(flip_y) - { - buf += pitch * (h - 1); - y += h; - pitch = -pitch; - } - for(i = 0; i < h; i++) - { - sl.reset_spans(); - bitset_iterator bits(buf, 0); - int j; - for(j = 0; j < w; j++) - { - if(bits.bit()) sl.add_cell(x + j, cover_full); - ++bits; - } - buf += pitch; - if(sl.num_spans()) - { - sl.finalize(y - i - 1); - storage.render(sl); - } - } - } - - - - //------------------------------------------------------------------------ - template - void decompose_win32_glyph_bitmap_gray8(const char* gbuf, - int w, int h, - int x, int y, - bool flip_y, - Rasterizer& ras, - Scanline& sl, - ScanlineStorage& storage) - { - int i, j; - int pitch = ((w + 3) >> 2) << 2; - const int8u* buf = (const int8u*)gbuf; - sl.reset(x, x + w); - storage.prepare(); - if(flip_y) - { - buf += pitch * (h - 1); - y += h; - pitch = -pitch; - } - for(i = 0; i < h; i++) - { - sl.reset_spans(); - const int8u* p = buf; - for(j = 0; j < w; j++) - { - if(*p) - { - unsigned v = *p; - if(v == 64) v = 255; - else v <<= 2; - sl.add_cell(x + j, ras.apply_gamma(v)); - } - ++p; - } - buf += pitch; - if(sl.num_spans()) - { - sl.finalize(y - i - 1); - storage.render(sl); - } - } - } - - - - //------------------------------------------------------------------------ - template - bool decompose_win32_glyph_outline(const char* gbuf, - unsigned total_size, - bool flip_y, - const trans_affine& mtx, - PathStorage& path) - { - const char* cur_glyph = gbuf; - const char* end_glyph = gbuf + total_size; - double x, y; - typedef typename PathStorage::value_type value_type; - - while(cur_glyph < end_glyph) - { - const TTPOLYGONHEADER* th = (TTPOLYGONHEADER*)cur_glyph; - - const char* end_poly = cur_glyph + th->cb; - const char* cur_poly = cur_glyph + sizeof(TTPOLYGONHEADER); - - x = fx_to_dbl(th->pfxStart.x); - y = fx_to_dbl(th->pfxStart.y); - if(flip_y) y = -y; - mtx.transform(&x, &y); - path.move_to(value_type(dbl_to_int26p6(x)), - value_type(dbl_to_int26p6(y))); - - while(cur_poly < end_poly) - { - const TTPOLYCURVE* pc = (const TTPOLYCURVE*)cur_poly; - - if (pc->wType == TT_PRIM_LINE) - { - int i; - for (i = 0; i < pc->cpfx; i++) - { - x = fx_to_dbl(pc->apfx[i].x); - y = fx_to_dbl(pc->apfx[i].y); - if(flip_y) y = -y; - mtx.transform(&x, &y); - path.line_to(value_type(dbl_to_int26p6(x)), - value_type(dbl_to_int26p6(y))); - } - } - - if (pc->wType == TT_PRIM_QSPLINE) - { - int u; - for (u = 0; u < pc->cpfx - 1; u++) // Walk through points in spline - { - POINTFX pnt_b = pc->apfx[u]; // B is always the current point - POINTFX pnt_c = pc->apfx[u+1]; - - if (u < pc->cpfx - 2) // If not on last spline, compute C - { - // midpoint (x,y) - *(int*)&pnt_c.x = (*(int*)&pnt_b.x + *(int*)&pnt_c.x) / 2; - *(int*)&pnt_c.y = (*(int*)&pnt_b.y + *(int*)&pnt_c.y) / 2; - } - - double x2, y2; - x = fx_to_dbl(pnt_b.x); - y = fx_to_dbl(pnt_b.y); - x2 = fx_to_dbl(pnt_c.x); - y2 = fx_to_dbl(pnt_c.y); - if(flip_y) { y = -y; y2 = -y2; } - mtx.transform(&x, &y); - mtx.transform(&x2, &y2); - path.curve3(value_type(dbl_to_int26p6(x)), - value_type(dbl_to_int26p6(y)), - value_type(dbl_to_int26p6(x2)), - value_type(dbl_to_int26p6(y2))); - } - } - cur_poly += sizeof(WORD) * 2 + sizeof(POINTFX) * pc->cpfx; - } - cur_glyph += th->cb; - } - return true; - } - - - - - //------------------------------------------------------------------------ - font_engine_win32_tt_base::~font_engine_win32_tt_base() - { - delete [] m_kerning_pairs; - delete [] m_gbuf; - delete [] m_signature; - delete [] m_typeface; - if(m_dc && m_old_font) ::SelectObject(m_dc, m_old_font); - unsigned i; - for(i = 0; i < m_num_fonts; ++i) - { - delete [] m_font_names[i]; - ::DeleteObject(m_fonts[i]); - } - delete [] m_font_names; - delete [] m_fonts; - } - - - - //------------------------------------------------------------------------ - font_engine_win32_tt_base::font_engine_win32_tt_base(bool flag32, - HDC dc, - unsigned max_fonts) : - m_flag32(flag32), - m_dc(dc), - m_old_font(m_dc ? (HFONT)::GetCurrentObject(m_dc, OBJ_FONT) : 0), - m_fonts(new HFONT [max_fonts]), - m_num_fonts(0), - m_max_fonts(max_fonts), - m_font_names(new char* [max_fonts]), - m_cur_font(0), - - m_change_stamp(0), - m_typeface(new char [256-16]), - m_typeface_len(256-16-1), - m_signature(new char [256+256-16]), - m_height(0), - m_width(0), - m_weight(FW_REGULAR), - m_italic(false), - m_char_set(DEFAULT_CHARSET), - m_pitch_and_family(FF_DONTCARE), - m_hinting(true), - m_flip_y(false), - m_font_created(false), - m_resolution(0), - m_glyph_rendering(glyph_ren_native_gray8), - m_glyph_index(0), - m_data_size(0), - m_data_type(glyph_data_invalid), - m_bounds(1,1,0,0), - m_advance_x(0.0), - m_advance_y(0.0), - m_gbuf(new char [buf_size]), - m_kerning_pairs(0), - m_num_kerning_pairs(0), - m_max_kerning_pairs(0), - - m_path16(), - m_path32(), - m_curves16(m_path16), - m_curves32(m_path32), - m_scanline_aa(), - m_scanline_bin(), - m_scanlines_aa(), - m_scanlines_bin(), - m_rasterizer() - { - m_curves16.approximation_scale(4.0); - m_curves32.approximation_scale(4.0); - memset(&m_matrix, 0, sizeof(m_matrix)); - m_matrix.eM11.value = 1; - m_matrix.eM22.value = 1; - } - - - - //------------------------------------------------------------------------ - int font_engine_win32_tt_base::find_font(const char* name) const - { - unsigned i; - for(i = 0; i < m_num_fonts; ++i) - { - if(strcmp(name, m_font_names[i]) == 0) return i; - } - return -1; - } - - //------------------------------------------------------------------------ - bool font_engine_win32_tt_base::create_font(const char* typeface_, - glyph_rendering ren_type) - { - if(m_dc) - { - unsigned len = strlen(typeface_); - if(len > m_typeface_len) - { - delete [] m_signature; - delete [] m_typeface; - m_typeface = new char [len + 32]; - m_signature = new char [len + 32 + 256]; - m_typeface_len = len + 32 - 1; - } - - strcpy(m_typeface, typeface_); - - int h = m_height; - int w = m_width; - - if(m_resolution) - { - h = ::MulDiv(m_height, m_resolution, 72); - w = ::MulDiv(m_width, m_resolution, 72); - } - - m_glyph_rendering = ren_type; - update_signature(); - int idx = find_font(m_signature); - if(idx >= 0) - { - m_cur_font = m_fonts[idx]; - ::SelectObject(m_dc, m_cur_font); - m_num_kerning_pairs = 0; - return true; - } - else - { - m_cur_font = ::CreateFont(-h, // height of font - w, // average character width - 0, // angle of escapement - 0, // base-line orientation angle - m_weight, // font weight - m_italic, // italic attribute option - 0, // underline attribute option - 0, // strikeout attribute option - m_char_set, // character set identifier - OUT_DEFAULT_PRECIS, // output precision - CLIP_DEFAULT_PRECIS, // clipping precision - ANTIALIASED_QUALITY, // output quality - m_pitch_and_family, // pitch and family - m_typeface); // typeface name - if(m_cur_font) - { - if(m_num_fonts >= m_max_fonts) - { - delete [] m_font_names[0]; - if(m_old_font) ::SelectObject(m_dc, m_old_font); - ::DeleteObject(m_fonts[0]); - memcpy(m_fonts, - m_fonts + 1, - (m_max_fonts - 1) * sizeof(HFONT)); - memcpy(m_font_names, - m_font_names + 1, - (m_max_fonts - 1) * sizeof(char*)); - m_num_fonts = m_max_fonts - 1; - } - - update_signature(); - m_font_names[m_num_fonts] = new char[strlen(m_signature) + 1]; - strcpy(m_font_names[m_num_fonts], m_signature); - m_fonts[m_num_fonts] = m_cur_font; - ++m_num_fonts; - ::SelectObject(m_dc, m_cur_font); - m_num_kerning_pairs = 0; - return true; - } - } - } - return false; - } - - - - - - //------------------------------------------------------------------------ - bool font_engine_win32_tt_base::create_font(const char* typeface_, - glyph_rendering ren_type, - double height_, - double width_, - int weight_, - bool italic_, - DWORD char_set_, - DWORD pitch_and_family_) - { - height(height_); - width(width_); - weight(weight_); - italic(italic_); - char_set(char_set_); - pitch_and_family(pitch_and_family_); - return create_font(typeface_, ren_type); - } - - - - - //------------------------------------------------------------------------ - void font_engine_win32_tt_base::update_signature() - { - m_signature[0] = 0; - if(m_dc && m_cur_font) - { - unsigned gamma_hash = 0; - if(m_glyph_rendering == glyph_ren_native_gray8 || - m_glyph_rendering == glyph_ren_agg_mono || - m_glyph_rendering == glyph_ren_agg_gray8) - { - unsigned char gamma_table[rasterizer_scanline_aa<>::aa_scale]; - unsigned i; - for(i = 0; i < rasterizer_scanline_aa<>::aa_scale; ++i) - { - gamma_table[i] = m_rasterizer.apply_gamma(i); - } - gamma_hash = calc_crc32(gamma_table, sizeof(gamma_table)); - } - - sprintf(m_signature, - "%s,%u,%d,%d:%dx%d,%d,%d,%d,%d,%d,%08X", - m_typeface, - m_char_set, - int(m_glyph_rendering), - m_resolution, - m_height, - m_width, - m_weight, - int(m_italic), - int(m_hinting), - int(m_flip_y), - int(m_pitch_and_family), - gamma_hash); - - if(m_glyph_rendering == glyph_ren_outline || - m_glyph_rendering == glyph_ren_agg_mono || - m_glyph_rendering == glyph_ren_agg_gray8) - { - double mtx[6]; - char buf[100]; - m_affine.store_to(mtx); - sprintf(buf, ",%08X%08X%08X%08X%08X%08X", - dbl_to_plain_fx(mtx[0]), - dbl_to_plain_fx(mtx[1]), - dbl_to_plain_fx(mtx[2]), - dbl_to_plain_fx(mtx[3]), - dbl_to_plain_fx(mtx[4]), - dbl_to_plain_fx(mtx[5])); - strcat(m_signature, buf); - } - ++m_change_stamp; - } - } - - - - //------------------------------------------------------------------------ - bool font_engine_win32_tt_base::prepare_glyph(unsigned glyph_code) - { - if(m_dc && m_cur_font) - { - int format = GGO_BITMAP; - - switch(m_glyph_rendering) - { - case glyph_ren_native_gray8: - format = GGO_GRAY8_BITMAP; - break; - - case glyph_ren_outline: - case glyph_ren_agg_mono: - case glyph_ren_agg_gray8: - format = GGO_NATIVE; - break; - } - -#ifndef GGO_UNHINTED // For compatibility with old SDKs. -#define GGO_UNHINTED 0x0100 -#endif - if(!m_hinting) format |= GGO_UNHINTED; - - GLYPHMETRICS gm; - int total_size = GetGlyphOutlineX(m_dc, - glyph_code, - format, - &gm, - buf_size, - (void*)m_gbuf, - &m_matrix); - - if(total_size < 0) - { - // GetGlyphOutline() fails when being called for - // GGO_GRAY8_BITMAP and white space (stupid Microsoft). - // It doesn't even initialize the glyph metrics - // structure. So, we have to query the metrics - // separately (basically we need gmCellIncX). - int total_size = GetGlyphOutlineX(m_dc, - glyph_code, - GGO_METRICS, - &gm, - buf_size, - (void*)m_gbuf, - &m_matrix); - - if(total_size < 0) return false; - gm.gmBlackBoxX = gm.gmBlackBoxY = 0; - total_size = 0; - } - - m_glyph_index = glyph_code; - m_advance_x = gm.gmCellIncX; - m_advance_y = -gm.gmCellIncY; - - switch(m_glyph_rendering) - { - case glyph_ren_native_mono: - decompose_win32_glyph_bitmap_mono(m_gbuf, - gm.gmBlackBoxX, - gm.gmBlackBoxY, - gm.gmptGlyphOrigin.x, - m_flip_y ? -gm.gmptGlyphOrigin.y : - gm.gmptGlyphOrigin.y, - m_flip_y, - m_scanline_bin, - m_scanlines_bin); - m_bounds.x1 = m_scanlines_bin.min_x(); - m_bounds.y1 = m_scanlines_bin.min_y(); - m_bounds.x2 = m_scanlines_bin.max_x() + 1; - m_bounds.y2 = m_scanlines_bin.max_y() + 1; - m_data_size = m_scanlines_bin.byte_size(); - m_data_type = glyph_data_mono; - return true; - - case glyph_ren_native_gray8: - decompose_win32_glyph_bitmap_gray8(m_gbuf, - gm.gmBlackBoxX, - gm.gmBlackBoxY, - gm.gmptGlyphOrigin.x, - m_flip_y ? -gm.gmptGlyphOrigin.y : - gm.gmptGlyphOrigin.y, - m_flip_y, - m_rasterizer, - m_scanline_aa, - m_scanlines_aa); - m_bounds.x1 = m_scanlines_aa.min_x(); - m_bounds.y1 = m_scanlines_aa.min_y(); - m_bounds.x2 = m_scanlines_aa.max_x() + 1; - m_bounds.y2 = m_scanlines_aa.max_y() + 1; - m_data_size = m_scanlines_aa.byte_size(); - m_data_type = glyph_data_gray8; - return true; - - case glyph_ren_outline: - m_affine.transform(&m_advance_x, &m_advance_y); - if(m_flag32) - { - m_path32.remove_all(); - if(decompose_win32_glyph_outline(m_gbuf, - total_size, - m_flip_y, - m_affine, - m_path32)) - { - rect_d bnd = m_path32.bounding_rect(); - m_data_size = m_path32.byte_size(); - m_data_type = glyph_data_outline; - m_bounds.x1 = int(floor(bnd.x1)); - m_bounds.y1 = int(floor(bnd.y1)); - m_bounds.x2 = int(ceil(bnd.x2)); - m_bounds.y2 = int(ceil(bnd.y2)); - return true; - } - } - else - { - m_path16.remove_all(); - if(decompose_win32_glyph_outline(m_gbuf, - total_size, - m_flip_y, - m_affine, - m_path16)) - { - rect_d bnd = m_path16.bounding_rect(); - m_data_size = m_path16.byte_size(); - m_data_type = glyph_data_outline; - m_bounds.x1 = int(floor(bnd.x1)); - m_bounds.y1 = int(floor(bnd.y1)); - m_bounds.x2 = int(ceil(bnd.x2)); - m_bounds.y2 = int(ceil(bnd.y2)); - return true; - } - } - break; - - case glyph_ren_agg_mono: - m_rasterizer.reset(); - m_affine.transform(&m_advance_x, &m_advance_y); - if(m_flag32) - { - m_path32.remove_all(); - decompose_win32_glyph_outline(m_gbuf, - total_size, - m_flip_y, - m_affine, - m_path32); - m_rasterizer.add_path(m_curves32); - } - else - { - m_path16.remove_all(); - decompose_win32_glyph_outline(m_gbuf, - total_size, - m_flip_y, - m_affine, - m_path16); - m_rasterizer.add_path(m_curves16); - } - m_scanlines_bin.prepare(); // Remove all - render_scanlines(m_rasterizer, m_scanline_bin, m_scanlines_bin); - m_bounds.x1 = m_scanlines_bin.min_x(); - m_bounds.y1 = m_scanlines_bin.min_y(); - m_bounds.x2 = m_scanlines_bin.max_x() + 1; - m_bounds.y2 = m_scanlines_bin.max_y() + 1; - m_data_size = m_scanlines_bin.byte_size(); - m_data_type = glyph_data_mono; - return true; - - case glyph_ren_agg_gray8: - m_rasterizer.reset(); - m_affine.transform(&m_advance_x, &m_advance_y); - if(m_flag32) - { - m_path32.remove_all(); - decompose_win32_glyph_outline(m_gbuf, - total_size, - m_flip_y, - m_affine, - m_path32); - m_rasterizer.add_path(m_curves32); - } - else - { - m_path16.remove_all(); - decompose_win32_glyph_outline(m_gbuf, - total_size, - m_flip_y, - m_affine, - m_path16); - m_rasterizer.add_path(m_curves16); - } - m_scanlines_aa.prepare(); // Remove all - render_scanlines(m_rasterizer, m_scanline_aa, m_scanlines_aa); - m_bounds.x1 = m_scanlines_aa.min_x(); - m_bounds.y1 = m_scanlines_aa.min_y(); - m_bounds.x2 = m_scanlines_aa.max_x() + 1; - m_bounds.y2 = m_scanlines_aa.max_y() + 1; - m_data_size = m_scanlines_aa.byte_size(); - m_data_type = glyph_data_gray8; - return true; - } - } - return false; - } - - - - //------------------------------------------------------------------------ - void font_engine_win32_tt_base::write_glyph_to(int8u* data) const - { - if(data && m_data_size) - { - switch(m_data_type) - { - case glyph_data_mono: m_scanlines_bin.serialize(data); break; - case glyph_data_gray8: m_scanlines_aa.serialize(data); break; - case glyph_data_outline: - if(m_flag32) - { - m_path32.serialize(data); - } - else - { - m_path16.serialize(data); - } - break; - } - } - } - - - - //------------------------------------------------------------------------ - static bool pair_less(const KERNINGPAIR& v1, const KERNINGPAIR& v2) - { - if(v1.wFirst != v2.wFirst) return v1.wFirst < v2.wFirst; - return v1.wSecond < v2.wSecond; - } - - - //------------------------------------------------------------------------ - void font_engine_win32_tt_base::sort_kerning_pairs() - { - pod_array_adaptor pairs(m_kerning_pairs, m_num_kerning_pairs); - quick_sort(pairs, pair_less); - } - - - - //------------------------------------------------------------------------ - void font_engine_win32_tt_base::load_kerning_pairs() - { - if(m_dc && m_cur_font) - { - if(m_kerning_pairs == 0) - { - m_kerning_pairs = new KERNINGPAIR [16384-16]; - m_max_kerning_pairs = 16384-16; - } - m_num_kerning_pairs = ::GetKerningPairs(m_dc, - m_max_kerning_pairs, - m_kerning_pairs); - - if(m_num_kerning_pairs) - { - // Check to see if the kerning pairs are sorted and - // sort them if they are not. - //---------------- - unsigned i; - for(i = 1; i < m_num_kerning_pairs; ++i) - { - if(!pair_less(m_kerning_pairs[i - 1], m_kerning_pairs[i])) - { - sort_kerning_pairs(); - break; - } - } - } - } - } - - - //------------------------------------------------------------------------ - bool font_engine_win32_tt_base::add_kerning(unsigned first, unsigned second, - double* x, double* y) - { - if(m_dc && m_cur_font) - { - if(m_num_kerning_pairs == 0) - { - load_kerning_pairs(); - } - - int end = m_num_kerning_pairs - 1; - int beg = 0; - KERNINGPAIR t; - t.wFirst = (WORD)first; - t.wSecond = (WORD)second; - while(beg <= end) - { - int mid = (end + beg) / 2; - if(m_kerning_pairs[mid].wFirst == t.wFirst && - m_kerning_pairs[mid].wSecond == t.wSecond) - { - double dx = m_kerning_pairs[mid].iKernAmount; - double dy = 0.0; - if(m_glyph_rendering == glyph_ren_outline || - m_glyph_rendering == glyph_ren_agg_mono || - m_glyph_rendering == glyph_ren_agg_gray8) - { - m_affine.transform_2x2(&dx, &dy); - } - *x += dx; - *y += dy; - return true; - } - else - if(pair_less(t, m_kerning_pairs[mid])) - { - end = mid - 1; - } - else - { - beg = mid + 1; - } - } - return false; - } - return false; - } - - - -} - diff --git a/desmume/src/windows/agg/font_win32_tt/agg_font_win32_tt.h b/desmume/src/windows/agg/font_win32_tt/agg_font_win32_tt.h deleted file mode 100644 index 149a89a64..000000000 --- a/desmume/src/windows/agg/font_win32_tt/agg_font_win32_tt.h +++ /dev/null @@ -1,223 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_FONT_WIN32_TT_INCLUDED -#define AGG_FONT_WIN32_TT_INCLUDED - -#include -#include "agg_scanline_storage_aa.h" -#include "agg_scanline_storage_bin.h" -#include "agg_scanline_u.h" -#include "agg_scanline_bin.h" -#include "agg_path_storage_integer.h" -#include "agg_rasterizer_scanline_aa.h" -#include "agg_conv_curve.h" -#include "agg_trans_affine.h" -#include "agg_font_cache_manager.h" - -namespace agg -{ - - //-----------------------------------------------font_engine_win32_tt_base - class font_engine_win32_tt_base - { - enum { buf_size = 32768-32 }; - - public: - //-------------------------------------------------------------------- - typedef serialized_scanlines_adaptor_aa gray8_adaptor_type; - typedef serialized_scanlines_adaptor_bin mono_adaptor_type; - typedef scanline_storage_aa8 scanlines_aa_type; - typedef scanline_storage_bin scanlines_bin_type; - - //-------------------------------------------------------------------- - ~font_engine_win32_tt_base(); - font_engine_win32_tt_base(bool flag32, HDC dc, unsigned max_fonts = 32); - - // Set font parameters - //-------------------------------------------------------------------- - void resolution(unsigned dpi) { m_resolution = unsigned(dpi); } - void height(double h) { m_height = unsigned(h); } - void width(double w) { m_width = unsigned(w); } - void weight(int w) { m_weight = w; } - void italic(bool it) { m_italic = it; } - void char_set(DWORD c) { m_char_set = c; } - void pitch_and_family(DWORD p){ m_pitch_and_family = p; } - void flip_y(bool flip) { m_flip_y = flip; } - void hinting(bool h) { m_hinting = h; } - bool create_font(const char* typeface_, glyph_rendering ren_type); - - bool create_font(const char* typeface_, - glyph_rendering ren_type, - double height_, - double width_=0.0, - int weight_=FW_REGULAR, - bool italic_=false, - DWORD char_set_=ANSI_CHARSET, - DWORD pitch_and_family_=FF_DONTCARE); - - // Set Gamma - //-------------------------------------------------------------------- - template void gamma(const GammaF& f) - { - m_rasterizer.gamma(f); - } - - //-------------------------------------------------------------------- - void transform(const agg::trans_affine& mtx) - { - m_affine = mtx; - } - - // Accessors - //-------------------------------------------------------------------- - unsigned resolution() const { return m_resolution; } - const char* typeface() const { return m_typeface; } - double height() const { return m_height; } - double width() const { return m_width; } - int weight() const { return m_weight; } - bool italic() const { return m_italic; } - DWORD char_set() const { return m_char_set; } - DWORD pitch_and_family() const { return m_pitch_and_family; } - bool hinting() const { return m_hinting; } - bool flip_y() const { return m_flip_y; } - - - // Interface mandatory to implement for font_cache_manager - //-------------------------------------------------------------------- - const char* font_signature() const { return m_signature; } - int change_stamp() const { return m_change_stamp; } - - bool prepare_glyph(unsigned glyph_code); - unsigned glyph_index() const { return m_glyph_index; } - unsigned data_size() const { return m_data_size; } - glyph_data_type data_type() const { return m_data_type; } - const rect_i& bounds() const { return m_bounds; } - double advance_x() const { return m_advance_x; } - double advance_y() const { return m_advance_y; } - void write_glyph_to(int8u* data) const; - bool add_kerning(unsigned first, unsigned second, - double* x, double* y); - - private: - font_engine_win32_tt_base(const font_engine_win32_tt_base&); - const font_engine_win32_tt_base& operator = (const font_engine_win32_tt_base&); - - void update_signature(); - void load_kerning_pairs(); - void sort_kerning_pairs(); - int find_font(const char* name) const; - - bool m_flag32; - HDC m_dc; - HFONT m_old_font; - HFONT* m_fonts; - unsigned m_num_fonts; - unsigned m_max_fonts; - char** m_font_names; - HFONT m_cur_font; - - int m_change_stamp; - char* m_typeface; - unsigned m_typeface_len; - char* m_signature; - unsigned m_height; - unsigned m_width; - int m_weight; - bool m_italic; - DWORD m_char_set; - DWORD m_pitch_and_family; - bool m_hinting; - bool m_flip_y; - - bool m_font_created; - unsigned m_resolution; - glyph_rendering m_glyph_rendering; - unsigned m_glyph_index; - unsigned m_data_size; - glyph_data_type m_data_type; - rect_i m_bounds; - double m_advance_x; - double m_advance_y; - MAT2 m_matrix; - char* m_gbuf; - KERNINGPAIR* m_kerning_pairs; - unsigned m_num_kerning_pairs; - unsigned m_max_kerning_pairs; - trans_affine m_affine; - - path_storage_integer m_path16; - path_storage_integer m_path32; - conv_curve > m_curves16; - conv_curve > m_curves32; - scanline_u8 m_scanline_aa; - scanline_bin m_scanline_bin; - scanlines_aa_type m_scanlines_aa; - scanlines_bin_type m_scanlines_bin; - rasterizer_scanline_aa<> m_rasterizer; - }; - - - - - //------------------------------------------------font_engine_win32_tt_int16 - // This class uses values of type int16 (10.6 format) for the vector cache. - // The vector cache is compact, but when rendering glyphs of height - // more that 200 there integer overflow can occur. - // - class font_engine_win32_tt_int16 : public font_engine_win32_tt_base - { - public: - typedef serialized_integer_path_adaptor path_adaptor_type; - typedef font_engine_win32_tt_base::gray8_adaptor_type gray8_adaptor_type; - typedef font_engine_win32_tt_base::mono_adaptor_type mono_adaptor_type; - typedef font_engine_win32_tt_base::scanlines_aa_type scanlines_aa_type; - typedef font_engine_win32_tt_base::scanlines_bin_type scanlines_bin_type; - - font_engine_win32_tt_int16(HDC dc, unsigned max_fonts = 32) : - font_engine_win32_tt_base(false, dc, max_fonts) {} - }; - - //------------------------------------------------font_engine_win32_tt_int32 - // This class uses values of type int32 (26.6 format) for the vector cache. - // The vector cache is twice larger than in font_engine_win32_tt_int16, - // but it allows you to render glyphs of very large sizes. - // - class font_engine_win32_tt_int32 : public font_engine_win32_tt_base - { - public: - typedef serialized_integer_path_adaptor path_adaptor_type; - typedef font_engine_win32_tt_base::gray8_adaptor_type gray8_adaptor_type; - typedef font_engine_win32_tt_base::mono_adaptor_type mono_adaptor_type; - typedef font_engine_win32_tt_base::scanlines_aa_type scanlines_aa_type; - typedef font_engine_win32_tt_base::scanlines_bin_type scanlines_bin_type; - - font_engine_win32_tt_int32(HDC dc, unsigned max_fonts = 32) : - font_engine_win32_tt_base(true, dc, max_fonts) {} - }; - - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_alpha_mask_u8.h b/desmume/src/windows/agg/include/agg_alpha_mask_u8.h deleted file mode 100644 index 4a99a94e1..000000000 --- a/desmume/src/windows/agg/include/agg_alpha_mask_u8.h +++ /dev/null @@ -1,505 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_ALPHA_MASK_U8_INCLUDED -#define AGG_ALPHA_MASK_U8_INCLUDED - -#include -#include "agg_basics.h" -#include "agg_rendering_buffer.h" - -namespace agg -{ - //===================================================one_component_mask_u8 - struct one_component_mask_u8 - { - static unsigned calculate(const int8u* p) { return *p; } - }; - - - //=====================================================rgb_to_gray_mask_u8 - template - struct rgb_to_gray_mask_u8 - { - static unsigned calculate(const int8u* p) - { - return (p[R]*77 + p[G]*150 + p[B]*29) >> 8; - } - }; - - //==========================================================alpha_mask_u8 - template - class alpha_mask_u8 - { - public: - typedef int8u cover_type; - typedef alpha_mask_u8 self_type; - enum cover_scale_e - { - cover_shift = 8, - cover_none = 0, - cover_full = 255 - }; - - alpha_mask_u8() : m_rbuf(0) {} - explicit alpha_mask_u8(rendering_buffer& rbuf) : m_rbuf(&rbuf) {} - - void attach(rendering_buffer& rbuf) { m_rbuf = &rbuf; } - - MaskF& mask_function() { return m_mask_function; } - const MaskF& mask_function() const { return m_mask_function; } - - - //-------------------------------------------------------------------- - cover_type pixel(int x, int y) const - { - if(x >= 0 && y >= 0 && - x < (int)m_rbuf->width() && - y < (int)m_rbuf->height()) - { - return (cover_type)m_mask_function.calculate( - m_rbuf->row_ptr(y) + x * Step + Offset); - } - return 0; - } - - //-------------------------------------------------------------------- - cover_type combine_pixel(int x, int y, cover_type val) const - { - if(x >= 0 && y >= 0 && - x < (int)m_rbuf->width() && - y < (int)m_rbuf->height()) - { - return (cover_type)((cover_full + val * - m_mask_function.calculate( - m_rbuf->row_ptr(y) + x * Step + Offset)) >> - cover_shift); - } - return 0; - } - - - //-------------------------------------------------------------------- - void fill_hspan(int x, int y, cover_type* dst, int num_pix) const - { - int xmax = m_rbuf->width() - 1; - int ymax = m_rbuf->height() - 1; - - int count = num_pix; - cover_type* covers = dst; - - if(y < 0 || y > ymax) - { - memset(dst, 0, num_pix * sizeof(cover_type)); - return; - } - - if(x < 0) - { - count += x; - if(count <= 0) - { - memset(dst, 0, num_pix * sizeof(cover_type)); - return; - } - memset(covers, 0, -x * sizeof(cover_type)); - covers -= x; - x = 0; - } - - if(x + count > xmax) - { - int rest = x + count - xmax - 1; - count -= rest; - if(count <= 0) - { - memset(dst, 0, num_pix * sizeof(cover_type)); - return; - } - memset(covers + count, 0, rest * sizeof(cover_type)); - } - - const int8u* mask = m_rbuf->row_ptr(y) + x * Step + Offset; - do - { - *covers++ = (cover_type)m_mask_function.calculate(mask); - mask += Step; - } - while(--count); - } - - - //-------------------------------------------------------------------- - void combine_hspan(int x, int y, cover_type* dst, int num_pix) const - { - int xmax = m_rbuf->width() - 1; - int ymax = m_rbuf->height() - 1; - - int count = num_pix; - cover_type* covers = dst; - - if(y < 0 || y > ymax) - { - memset(dst, 0, num_pix * sizeof(cover_type)); - return; - } - - if(x < 0) - { - count += x; - if(count <= 0) - { - memset(dst, 0, num_pix * sizeof(cover_type)); - return; - } - memset(covers, 0, -x * sizeof(cover_type)); - covers -= x; - x = 0; - } - - if(x + count > xmax) - { - int rest = x + count - xmax - 1; - count -= rest; - if(count <= 0) - { - memset(dst, 0, num_pix * sizeof(cover_type)); - return; - } - memset(covers + count, 0, rest * sizeof(cover_type)); - } - - const int8u* mask = m_rbuf->row_ptr(y) + x * Step + Offset; - do - { - *covers = (cover_type)((cover_full + (*covers) * - m_mask_function.calculate(mask)) >> - cover_shift); - ++covers; - mask += Step; - } - while(--count); - } - - //-------------------------------------------------------------------- - void fill_vspan(int x, int y, cover_type* dst, int num_pix) const - { - int xmax = m_rbuf->width() - 1; - int ymax = m_rbuf->height() - 1; - - int count = num_pix; - cover_type* covers = dst; - - if(x < 0 || x > xmax) - { - memset(dst, 0, num_pix * sizeof(cover_type)); - return; - } - - if(y < 0) - { - count += y; - if(count <= 0) - { - memset(dst, 0, num_pix * sizeof(cover_type)); - return; - } - memset(covers, 0, -y * sizeof(cover_type)); - covers -= y; - y = 0; - } - - if(y + count > ymax) - { - int rest = y + count - ymax - 1; - count -= rest; - if(count <= 0) - { - memset(dst, 0, num_pix * sizeof(cover_type)); - return; - } - memset(covers + count, 0, rest * sizeof(cover_type)); - } - - const int8u* mask = m_rbuf->row_ptr(y) + x * Step + Offset; - do - { - *covers++ = (cover_type)m_mask_function.calculate(mask); - mask += m_rbuf->stride(); - } - while(--count); - } - - //-------------------------------------------------------------------- - void combine_vspan(int x, int y, cover_type* dst, int num_pix) const - { - int xmax = m_rbuf->width() - 1; - int ymax = m_rbuf->height() - 1; - - int count = num_pix; - cover_type* covers = dst; - - if(x < 0 || x > xmax) - { - memset(dst, 0, num_pix * sizeof(cover_type)); - return; - } - - if(y < 0) - { - count += y; - if(count <= 0) - { - memset(dst, 0, num_pix * sizeof(cover_type)); - return; - } - memset(covers, 0, -y * sizeof(cover_type)); - covers -= y; - y = 0; - } - - if(y + count > ymax) - { - int rest = y + count - ymax - 1; - count -= rest; - if(count <= 0) - { - memset(dst, 0, num_pix * sizeof(cover_type)); - return; - } - memset(covers + count, 0, rest * sizeof(cover_type)); - } - - const int8u* mask = m_rbuf->row_ptr(y) + x * Step + Offset; - do - { - *covers = (cover_type)((cover_full + (*covers) * - m_mask_function.calculate(mask)) >> - cover_shift); - ++covers; - mask += m_rbuf->stride(); - } - while(--count); - } - - - private: - alpha_mask_u8(const self_type&); - const self_type& operator = (const self_type&); - - rendering_buffer* m_rbuf; - MaskF m_mask_function; - }; - - - typedef alpha_mask_u8<1, 0> alpha_mask_gray8; //----alpha_mask_gray8 - - typedef alpha_mask_u8<3, 0> alpha_mask_rgb24r; //----alpha_mask_rgb24r - typedef alpha_mask_u8<3, 1> alpha_mask_rgb24g; //----alpha_mask_rgb24g - typedef alpha_mask_u8<3, 2> alpha_mask_rgb24b; //----alpha_mask_rgb24b - - typedef alpha_mask_u8<3, 2> alpha_mask_bgr24r; //----alpha_mask_bgr24r - typedef alpha_mask_u8<3, 1> alpha_mask_bgr24g; //----alpha_mask_bgr24g - typedef alpha_mask_u8<3, 0> alpha_mask_bgr24b; //----alpha_mask_bgr24b - - typedef alpha_mask_u8<4, 0> alpha_mask_rgba32r; //----alpha_mask_rgba32r - typedef alpha_mask_u8<4, 1> alpha_mask_rgba32g; //----alpha_mask_rgba32g - typedef alpha_mask_u8<4, 2> alpha_mask_rgba32b; //----alpha_mask_rgba32b - typedef alpha_mask_u8<4, 3> alpha_mask_rgba32a; //----alpha_mask_rgba32a - - typedef alpha_mask_u8<4, 1> alpha_mask_argb32r; //----alpha_mask_argb32r - typedef alpha_mask_u8<4, 2> alpha_mask_argb32g; //----alpha_mask_argb32g - typedef alpha_mask_u8<4, 3> alpha_mask_argb32b; //----alpha_mask_argb32b - typedef alpha_mask_u8<4, 0> alpha_mask_argb32a; //----alpha_mask_argb32a - - typedef alpha_mask_u8<4, 2> alpha_mask_bgra32r; //----alpha_mask_bgra32r - typedef alpha_mask_u8<4, 1> alpha_mask_bgra32g; //----alpha_mask_bgra32g - typedef alpha_mask_u8<4, 0> alpha_mask_bgra32b; //----alpha_mask_bgra32b - typedef alpha_mask_u8<4, 3> alpha_mask_bgra32a; //----alpha_mask_bgra32a - - typedef alpha_mask_u8<4, 3> alpha_mask_abgr32r; //----alpha_mask_abgr32r - typedef alpha_mask_u8<4, 2> alpha_mask_abgr32g; //----alpha_mask_abgr32g - typedef alpha_mask_u8<4, 1> alpha_mask_abgr32b; //----alpha_mask_abgr32b - typedef alpha_mask_u8<4, 0> alpha_mask_abgr32a; //----alpha_mask_abgr32a - - typedef alpha_mask_u8<3, 0, rgb_to_gray_mask_u8<0, 1, 2> > alpha_mask_rgb24gray; //----alpha_mask_rgb24gray - typedef alpha_mask_u8<3, 0, rgb_to_gray_mask_u8<2, 1, 0> > alpha_mask_bgr24gray; //----alpha_mask_bgr24gray - typedef alpha_mask_u8<4, 0, rgb_to_gray_mask_u8<0, 1, 2> > alpha_mask_rgba32gray; //----alpha_mask_rgba32gray - typedef alpha_mask_u8<4, 1, rgb_to_gray_mask_u8<0, 1, 2> > alpha_mask_argb32gray; //----alpha_mask_argb32gray - typedef alpha_mask_u8<4, 0, rgb_to_gray_mask_u8<2, 1, 0> > alpha_mask_bgra32gray; //----alpha_mask_bgra32gray - typedef alpha_mask_u8<4, 1, rgb_to_gray_mask_u8<2, 1, 0> > alpha_mask_abgr32gray; //----alpha_mask_abgr32gray - - - - //==========================================================amask_no_clip_u8 - template - class amask_no_clip_u8 - { - public: - typedef int8u cover_type; - typedef amask_no_clip_u8 self_type; - enum cover_scale_e - { - cover_shift = 8, - cover_none = 0, - cover_full = 255 - }; - - amask_no_clip_u8() : m_rbuf(0) {} - explicit amask_no_clip_u8(rendering_buffer& rbuf) : m_rbuf(&rbuf) {} - - void attach(rendering_buffer& rbuf) { m_rbuf = &rbuf; } - - MaskF& mask_function() { return m_mask_function; } - const MaskF& mask_function() const { return m_mask_function; } - - - //-------------------------------------------------------------------- - cover_type pixel(int x, int y) const - { - return (cover_type)m_mask_function.calculate( - m_rbuf->row_ptr(y) + x * Step + Offset); - } - - - //-------------------------------------------------------------------- - cover_type combine_pixel(int x, int y, cover_type val) const - { - return (cover_type)((cover_full + val * - m_mask_function.calculate( - m_rbuf->row_ptr(y) + x * Step + Offset)) >> - cover_shift); - } - - - //-------------------------------------------------------------------- - void fill_hspan(int x, int y, cover_type* dst, int num_pix) const - { - const int8u* mask = m_rbuf->row_ptr(y) + x * Step + Offset; - do - { - *dst++ = (cover_type)m_mask_function.calculate(mask); - mask += Step; - } - while(--num_pix); - } - - - - //-------------------------------------------------------------------- - void combine_hspan(int x, int y, cover_type* dst, int num_pix) const - { - const int8u* mask = m_rbuf->row_ptr(y) + x * Step + Offset; - do - { - *dst = (cover_type)((cover_full + (*dst) * - m_mask_function.calculate(mask)) >> - cover_shift); - ++dst; - mask += Step; - } - while(--num_pix); - } - - - //-------------------------------------------------------------------- - void fill_vspan(int x, int y, cover_type* dst, int num_pix) const - { - const int8u* mask = m_rbuf->row_ptr(y) + x * Step + Offset; - do - { - *dst++ = (cover_type)m_mask_function.calculate(mask); - mask += m_rbuf->stride(); - } - while(--num_pix); - } - - - //-------------------------------------------------------------------- - void combine_vspan(int x, int y, cover_type* dst, int num_pix) const - { - const int8u* mask = m_rbuf->row_ptr(y) + x * Step + Offset; - do - { - *dst = (cover_type)((cover_full + (*dst) * - m_mask_function.calculate(mask)) >> - cover_shift); - ++dst; - mask += m_rbuf->stride(); - } - while(--num_pix); - } - - private: - amask_no_clip_u8(const self_type&); - const self_type& operator = (const self_type&); - - rendering_buffer* m_rbuf; - MaskF m_mask_function; - }; - - - typedef amask_no_clip_u8<1, 0> amask_no_clip_gray8; //----amask_no_clip_gray8 - - typedef amask_no_clip_u8<3, 0> amask_no_clip_rgb24r; //----amask_no_clip_rgb24r - typedef amask_no_clip_u8<3, 1> amask_no_clip_rgb24g; //----amask_no_clip_rgb24g - typedef amask_no_clip_u8<3, 2> amask_no_clip_rgb24b; //----amask_no_clip_rgb24b - - typedef amask_no_clip_u8<3, 2> amask_no_clip_bgr24r; //----amask_no_clip_bgr24r - typedef amask_no_clip_u8<3, 1> amask_no_clip_bgr24g; //----amask_no_clip_bgr24g - typedef amask_no_clip_u8<3, 0> amask_no_clip_bgr24b; //----amask_no_clip_bgr24b - - typedef amask_no_clip_u8<4, 0> amask_no_clip_rgba32r; //----amask_no_clip_rgba32r - typedef amask_no_clip_u8<4, 1> amask_no_clip_rgba32g; //----amask_no_clip_rgba32g - typedef amask_no_clip_u8<4, 2> amask_no_clip_rgba32b; //----amask_no_clip_rgba32b - typedef amask_no_clip_u8<4, 3> amask_no_clip_rgba32a; //----amask_no_clip_rgba32a - - typedef amask_no_clip_u8<4, 1> amask_no_clip_argb32r; //----amask_no_clip_argb32r - typedef amask_no_clip_u8<4, 2> amask_no_clip_argb32g; //----amask_no_clip_argb32g - typedef amask_no_clip_u8<4, 3> amask_no_clip_argb32b; //----amask_no_clip_argb32b - typedef amask_no_clip_u8<4, 0> amask_no_clip_argb32a; //----amask_no_clip_argb32a - - typedef amask_no_clip_u8<4, 2> amask_no_clip_bgra32r; //----amask_no_clip_bgra32r - typedef amask_no_clip_u8<4, 1> amask_no_clip_bgra32g; //----amask_no_clip_bgra32g - typedef amask_no_clip_u8<4, 0> amask_no_clip_bgra32b; //----amask_no_clip_bgra32b - typedef amask_no_clip_u8<4, 3> amask_no_clip_bgra32a; //----amask_no_clip_bgra32a - - typedef amask_no_clip_u8<4, 3> amask_no_clip_abgr32r; //----amask_no_clip_abgr32r - typedef amask_no_clip_u8<4, 2> amask_no_clip_abgr32g; //----amask_no_clip_abgr32g - typedef amask_no_clip_u8<4, 1> amask_no_clip_abgr32b; //----amask_no_clip_abgr32b - typedef amask_no_clip_u8<4, 0> amask_no_clip_abgr32a; //----amask_no_clip_abgr32a - - typedef amask_no_clip_u8<3, 0, rgb_to_gray_mask_u8<0, 1, 2> > amask_no_clip_rgb24gray; //----amask_no_clip_rgb24gray - typedef amask_no_clip_u8<3, 0, rgb_to_gray_mask_u8<2, 1, 0> > amask_no_clip_bgr24gray; //----amask_no_clip_bgr24gray - typedef amask_no_clip_u8<4, 0, rgb_to_gray_mask_u8<0, 1, 2> > amask_no_clip_rgba32gray; //----amask_no_clip_rgba32gray - typedef amask_no_clip_u8<4, 1, rgb_to_gray_mask_u8<0, 1, 2> > amask_no_clip_argb32gray; //----amask_no_clip_argb32gray - typedef amask_no_clip_u8<4, 0, rgb_to_gray_mask_u8<2, 1, 0> > amask_no_clip_bgra32gray; //----amask_no_clip_bgra32gray - typedef amask_no_clip_u8<4, 1, rgb_to_gray_mask_u8<2, 1, 0> > amask_no_clip_abgr32gray; //----amask_no_clip_abgr32gray - - -} - - - -#endif diff --git a/desmume/src/windows/agg/include/agg_arc.h b/desmume/src/windows/agg/include/agg_arc.h deleted file mode 100644 index 6ff919e58..000000000 --- a/desmume/src/windows/agg/include/agg_arc.h +++ /dev/null @@ -1,79 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_ARC_INCLUDED -#define AGG_ARC_INCLUDED - -#include -#include "agg_basics.h" - -namespace agg -{ - - //=====================================================================arc - // - // See Implementation agg_arc.cpp - // - class arc - { - public: - arc() : m_scale(1.0), m_initialized(false) {} - arc(double x, double y, - double rx, double ry, - double a1, double a2, - bool ccw=true); - - void init(double x, double y, - double rx, double ry, - double a1, double a2, - bool ccw=true); - - void approximation_scale(double s); - double approximation_scale() const { return m_scale; } - - void rewind(unsigned); - unsigned vertex(double* x, double* y); - - private: - void normalize(double a1, double a2, bool ccw); - - double m_x; - double m_y; - double m_rx; - double m_ry; - double m_angle; - double m_start; - double m_end; - double m_scale; - double m_da; - bool m_ccw; - bool m_initialized; - unsigned m_path_cmd; - }; - - -} - - -#endif diff --git a/desmume/src/windows/agg/include/agg_array.h b/desmume/src/windows/agg/include/agg_array.h deleted file mode 100644 index 81ed4dd82..000000000 --- a/desmume/src/windows/agg/include/agg_array.h +++ /dev/null @@ -1,1129 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_ARRAY_INCLUDED -#define AGG_ARRAY_INCLUDED - -#include -#include -#include "agg_basics.h" - -namespace agg -{ - - //-------------------------------------------------------pod_array_adaptor - template class pod_array_adaptor - { - public: - typedef T value_type; - pod_array_adaptor(T* array, unsigned size) : - m_array(array), m_size(size) {} - - unsigned size() const { return m_size; } - const T& operator [] (unsigned i) const { return m_array[i]; } - T& operator [] (unsigned i) { return m_array[i]; } - const T& at(unsigned i) const { return m_array[i]; } - T& at(unsigned i) { return m_array[i]; } - T value_at(unsigned i) const { return m_array[i]; } - - private: - T* m_array; - unsigned m_size; - }; - - - //---------------------------------------------------------pod_auto_array - template class pod_auto_array - { - public: - typedef T value_type; - typedef pod_auto_array self_type; - - pod_auto_array() {} - explicit pod_auto_array(const T* c) - { - memcpy(m_array, c, sizeof(T) * Size); - } - - const self_type& operator = (const T* c) - { - memcpy(m_array, c, sizeof(T) * Size); - return *this; - } - - static unsigned size() { return Size; } - const T& operator [] (unsigned i) const { return m_array[i]; } - T& operator [] (unsigned i) { return m_array[i]; } - const T& at(unsigned i) const { return m_array[i]; } - T& at(unsigned i) { return m_array[i]; } - T value_at(unsigned i) const { return m_array[i]; } - - private: - T m_array[Size]; - }; - - - //--------------------------------------------------------pod_auto_vector - template class pod_auto_vector - { - public: - typedef T value_type; - typedef pod_auto_vector self_type; - - pod_auto_vector() : m_size(0) {} - - void remove_all() { m_size = 0; } - void clear() { m_size = 0; } - void add(const T& v) { m_array[m_size++] = v; } - void push_back(const T& v) { m_array[m_size++] = v; } - void inc_size(unsigned size) { m_size += size; } - - unsigned size() const { return m_size; } - const T& operator [] (unsigned i) const { return m_array[i]; } - T& operator [] (unsigned i) { return m_array[i]; } - const T& at(unsigned i) const { return m_array[i]; } - T& at(unsigned i) { return m_array[i]; } - T value_at(unsigned i) const { return m_array[i]; } - - private: - T m_array[Size]; - unsigned m_size; - }; - - - //---------------------------------------------------------------pod_array - template class pod_array - { - public: - typedef T value_type; - typedef pod_array self_type; - - ~pod_array() { pod_allocator::deallocate(m_array, m_size); } - pod_array() : m_array(0), m_size(0) {} - - pod_array(unsigned size) : - m_array(pod_allocator::allocate(size)), - m_size(size) - {} - - pod_array(const self_type& v) : - m_array(pod_allocator::allocate(v.m_size)), - m_size(v.m_size) - { - memcpy(m_array, v.m_array, sizeof(T) * m_size); - } - - void resize(unsigned size) - { - if(size != m_size) - { - pod_allocator::deallocate(m_array, m_size); - m_array = pod_allocator::allocate(m_size = size); - } - } - const self_type& operator = (const self_type& v) - { - resize(v.size()); - memcpy(m_array, v.m_array, sizeof(T) * m_size); - return *this; - } - - unsigned size() const { return m_size; } - const T& operator [] (unsigned i) const { return m_array[i]; } - T& operator [] (unsigned i) { return m_array[i]; } - const T& at(unsigned i) const { return m_array[i]; } - T& at(unsigned i) { return m_array[i]; } - T value_at(unsigned i) const { return m_array[i]; } - - const T* data() const { return m_array; } - T* data() { return m_array; } - private: - T* m_array; - unsigned m_size; - }; - - - - //--------------------------------------------------------------pod_vector - // A simple class template to store Plain Old Data, a vector - // of a fixed size. The data is continous in memory - //------------------------------------------------------------------------ - template class pod_vector - { - public: - typedef T value_type; - - ~pod_vector() { pod_allocator::deallocate(m_array, m_capacity); } - pod_vector() : m_size(0), m_capacity(0), m_array(0) {} - pod_vector(unsigned cap, unsigned extra_tail=0); - - // Copying - pod_vector(const pod_vector&); - const pod_vector& operator = (const pod_vector&); - - // Set new capacity. All data is lost, size is set to zero. - void capacity(unsigned cap, unsigned extra_tail=0); - unsigned capacity() const { return m_capacity; } - - // Allocate n elements. All data is lost, - // but elements can be accessed in range 0...size-1. - void allocate(unsigned size, unsigned extra_tail=0); - - // Resize keeping the content. - void resize(unsigned new_size); - - void zero() - { - memset(m_array, 0, sizeof(T) * m_size); - } - - void add(const T& v) { m_array[m_size++] = v; } - void push_back(const T& v) { m_array[m_size++] = v; } - void insert_at(unsigned pos, const T& val); - void inc_size(unsigned size) { m_size += size; } - unsigned size() const { return m_size; } - unsigned byte_size() const { return m_size * sizeof(T); } - void serialize(int8u* ptr) const; - void deserialize(const int8u* data, unsigned byte_size); - const T& operator [] (unsigned i) const { return m_array[i]; } - T& operator [] (unsigned i) { return m_array[i]; } - const T& at(unsigned i) const { return m_array[i]; } - T& at(unsigned i) { return m_array[i]; } - T value_at(unsigned i) const { return m_array[i]; } - - const T* data() const { return m_array; } - T* data() { return m_array; } - - void remove_all() { m_size = 0; } - void clear() { m_size = 0; } - void cut_at(unsigned num) { if(num < m_size) m_size = num; } - - private: - unsigned m_size; - unsigned m_capacity; - T* m_array; - }; - - //------------------------------------------------------------------------ - template - void pod_vector::capacity(unsigned cap, unsigned extra_tail) - { - m_size = 0; - if(cap > m_capacity) - { - pod_allocator::deallocate(m_array, m_capacity); - m_capacity = cap + extra_tail; - m_array = m_capacity ? pod_allocator::allocate(m_capacity) : 0; - } - } - - //------------------------------------------------------------------------ - template - void pod_vector::allocate(unsigned size, unsigned extra_tail) - { - capacity(size, extra_tail); - m_size = size; - } - - - //------------------------------------------------------------------------ - template - void pod_vector::resize(unsigned new_size) - { - if(new_size > m_size) - { - if(new_size > m_capacity) - { - T* data = pod_allocator::allocate(new_size); - memcpy(data, m_array, m_size * sizeof(T)); - pod_allocator::deallocate(m_array, m_capacity); - m_array = data; - } - } - else - { - m_size = new_size; - } - } - - //------------------------------------------------------------------------ - template pod_vector::pod_vector(unsigned cap, unsigned extra_tail) : - m_size(0), - m_capacity(cap + extra_tail), - m_array(pod_allocator::allocate(m_capacity)) {} - - //------------------------------------------------------------------------ - template pod_vector::pod_vector(const pod_vector& v) : - m_size(v.m_size), - m_capacity(v.m_capacity), - m_array(v.m_capacity ? pod_allocator::allocate(v.m_capacity) : 0) - { - memcpy(m_array, v.m_array, sizeof(T) * v.m_size); - } - - //------------------------------------------------------------------------ - template const pod_vector& - pod_vector::operator = (const pod_vector&v) - { - allocate(v.m_size); - if(v.m_size) memcpy(m_array, v.m_array, sizeof(T) * v.m_size); - return *this; - } - - //------------------------------------------------------------------------ - template void pod_vector::serialize(int8u* ptr) const - { - if(m_size) memcpy(ptr, m_array, m_size * sizeof(T)); - } - - //------------------------------------------------------------------------ - template - void pod_vector::deserialize(const int8u* data, unsigned byte_size) - { - byte_size /= sizeof(T); - allocate(byte_size); - if(byte_size) memcpy(m_array, data, byte_size * sizeof(T)); - } - - //------------------------------------------------------------------------ - template - void pod_vector::insert_at(unsigned pos, const T& val) - { - if(pos >= m_size) - { - m_array[m_size] = val; - } - else - { - memmove(m_array + pos + 1, m_array + pos, (m_size - pos) * sizeof(T)); - m_array[pos] = val; - } - ++m_size; - } - - //---------------------------------------------------------------pod_bvector - // A simple class template to store Plain Old Data, similar to std::deque - // It doesn't reallocate memory but instead, uses blocks of data of size - // of (1 << S), that is, power of two. The data is NOT contiguous in memory, - // so the only valid access method is operator [] or curr(), prev(), next() - // - // There reallocs occure only when the pool of pointers to blocks needs - // to be extended (it happens very rarely). You can control the value - // of increment to reallocate the pointer buffer. See the second constructor. - // By default, the incremeent value equals (1 << S), i.e., the block size. - //------------------------------------------------------------------------ - template class pod_bvector - { - public: - enum block_scale_e - { - block_shift = S, - block_size = 1 << block_shift, - block_mask = block_size - 1 - }; - - typedef T value_type; - - ~pod_bvector(); - pod_bvector(); - pod_bvector(unsigned block_ptr_inc); - - // Copying - pod_bvector(const pod_bvector& v); - const pod_bvector& operator = (const pod_bvector& v); - - void remove_all() { m_size = 0; } - void clear() { m_size = 0; } - void free_all() { free_tail(0); } - void free_tail(unsigned size); - void add(const T& val); - void push_back(const T& val) { add(val); } - void modify_last(const T& val); - void remove_last(); - - int allocate_continuous_block(unsigned num_elements); - - void add_array(const T* ptr, unsigned num_elem) - { - while(num_elem--) - { - add(*ptr++); - } - } - - template void add_data(DataAccessor& data) - { - while(data.size()) - { - add(*data); - ++data; - } - } - - void cut_at(unsigned size) - { - if(size < m_size) m_size = size; - } - - unsigned size() const { return m_size; } - - const T& operator [] (unsigned i) const - { - return m_blocks[i >> block_shift][i & block_mask]; - } - - T& operator [] (unsigned i) - { - return m_blocks[i >> block_shift][i & block_mask]; - } - - const T& at(unsigned i) const - { - return m_blocks[i >> block_shift][i & block_mask]; - } - - T& at(unsigned i) - { - return m_blocks[i >> block_shift][i & block_mask]; - } - - T value_at(unsigned i) const - { - return m_blocks[i >> block_shift][i & block_mask]; - } - - const T& curr(unsigned idx) const - { - return (*this)[idx]; - } - - T& curr(unsigned idx) - { - return (*this)[idx]; - } - - const T& prev(unsigned idx) const - { - return (*this)[(idx + m_size - 1) % m_size]; - } - - T& prev(unsigned idx) - { - return (*this)[(idx + m_size - 1) % m_size]; - } - - const T& next(unsigned idx) const - { - return (*this)[(idx + 1) % m_size]; - } - - T& next(unsigned idx) - { - return (*this)[(idx + 1) % m_size]; - } - - const T& last() const - { - return (*this)[m_size - 1]; - } - - T& last() - { - return (*this)[m_size - 1]; - } - - unsigned byte_size() const; - void serialize(int8u* ptr) const; - void deserialize(const int8u* data, unsigned byte_size); - void deserialize(unsigned start, const T& empty_val, - const int8u* data, unsigned byte_size); - - template - void deserialize(ByteAccessor data) - { - remove_all(); - unsigned elem_size = data.size() / sizeof(T); - - for(unsigned i = 0; i < elem_size; ++i) - { - int8u* ptr = (int8u*)data_ptr(); - for(unsigned j = 0; j < sizeof(T); ++j) - { - *ptr++ = *data; - ++data; - } - ++m_size; - } - } - - template - void deserialize(unsigned start, const T& empty_val, ByteAccessor data) - { - while(m_size < start) - { - add(empty_val); - } - - unsigned elem_size = data.size() / sizeof(T); - for(unsigned i = 0; i < elem_size; ++i) - { - int8u* ptr; - if(start + i < m_size) - { - ptr = (int8u*)(&((*this)[start + i])); - } - else - { - ptr = (int8u*)data_ptr(); - ++m_size; - } - for(unsigned j = 0; j < sizeof(T); ++j) - { - *ptr++ = *data; - ++data; - } - } - } - - const T* block(unsigned nb) const { return m_blocks[nb]; } - - private: - void allocate_block(unsigned nb); - T* data_ptr(); - - unsigned m_size; - unsigned m_num_blocks; - unsigned m_max_blocks; - T** m_blocks; - unsigned m_block_ptr_inc; - }; - - - //------------------------------------------------------------------------ - template pod_bvector::~pod_bvector() - { - if(m_num_blocks) - { - T** blk = m_blocks + m_num_blocks - 1; - while(m_num_blocks--) - { - pod_allocator::deallocate(*blk, block_size); - --blk; - } - } - pod_allocator::deallocate(m_blocks, m_max_blocks); - } - - - //------------------------------------------------------------------------ - template - void pod_bvector::free_tail(unsigned size) - { - if(size < m_size) - { - unsigned nb = (size + block_mask) >> block_shift; - while(m_num_blocks > nb) - { - pod_allocator::deallocate(m_blocks[--m_num_blocks], block_size); - } - if(m_num_blocks == 0) - { - pod_allocator::deallocate(m_blocks, m_max_blocks); - m_blocks = 0; - m_max_blocks = 0; - } - m_size = size; - } - } - - - //------------------------------------------------------------------------ - template pod_bvector::pod_bvector() : - m_size(0), - m_num_blocks(0), - m_max_blocks(0), - m_blocks(0), - m_block_ptr_inc(block_size) - { - } - - - //------------------------------------------------------------------------ - template - pod_bvector::pod_bvector(unsigned block_ptr_inc) : - m_size(0), - m_num_blocks(0), - m_max_blocks(0), - m_blocks(0), - m_block_ptr_inc(block_ptr_inc) - { - } - - - //------------------------------------------------------------------------ - template - pod_bvector::pod_bvector(const pod_bvector& v) : - m_size(v.m_size), - m_num_blocks(v.m_num_blocks), - m_max_blocks(v.m_max_blocks), - m_blocks(v.m_max_blocks ? - pod_allocator::allocate(v.m_max_blocks) : - 0), - m_block_ptr_inc(v.m_block_ptr_inc) - { - unsigned i; - for(i = 0; i < v.m_num_blocks; ++i) - { - m_blocks[i] = pod_allocator::allocate(block_size); - memcpy(m_blocks[i], v.m_blocks[i], block_size * sizeof(T)); - } - } - - - //------------------------------------------------------------------------ - template - const pod_bvector& - pod_bvector::operator = (const pod_bvector& v) - { - unsigned i; - for(i = m_num_blocks; i < v.m_num_blocks; ++i) - { - allocate_block(i); - } - for(i = 0; i < v.m_num_blocks; ++i) - { - memcpy(m_blocks[i], v.m_blocks[i], block_size * sizeof(T)); - } - m_size = v.m_size; - return *this; - } - - - //------------------------------------------------------------------------ - template - void pod_bvector::allocate_block(unsigned nb) - { - if(nb >= m_max_blocks) - { - T** new_blocks = pod_allocator::allocate(m_max_blocks + m_block_ptr_inc); - - if(m_blocks) - { - memcpy(new_blocks, - m_blocks, - m_num_blocks * sizeof(T*)); - - pod_allocator::deallocate(m_blocks, m_max_blocks); - } - m_blocks = new_blocks; - m_max_blocks += m_block_ptr_inc; - } - m_blocks[nb] = pod_allocator::allocate(block_size); - m_num_blocks++; - } - - - - //------------------------------------------------------------------------ - template - inline T* pod_bvector::data_ptr() - { - unsigned nb = m_size >> block_shift; - if(nb >= m_num_blocks) - { - allocate_block(nb); - } - return m_blocks[nb] + (m_size & block_mask); - } - - - - //------------------------------------------------------------------------ - template - inline void pod_bvector::add(const T& val) - { - *data_ptr() = val; - ++m_size; - } - - - //------------------------------------------------------------------------ - template - inline void pod_bvector::remove_last() - { - if(m_size) --m_size; - } - - - //------------------------------------------------------------------------ - template - void pod_bvector::modify_last(const T& val) - { - remove_last(); - add(val); - } - - - //------------------------------------------------------------------------ - template - int pod_bvector::allocate_continuous_block(unsigned num_elements) - { - if(num_elements < block_size) - { - data_ptr(); // Allocate initial block if necessary - unsigned rest = block_size - (m_size & block_mask); - unsigned index; - if(num_elements <= rest) - { - // The rest of the block is good, we can use it - //----------------- - index = m_size; - m_size += num_elements; - return index; - } - - // New block - //--------------- - m_size += rest; - data_ptr(); - index = m_size; - m_size += num_elements; - return index; - } - return -1; // Impossible to allocate - } - - - //------------------------------------------------------------------------ - template - unsigned pod_bvector::byte_size() const - { - return m_size * sizeof(T); - } - - - //------------------------------------------------------------------------ - template - void pod_bvector::serialize(int8u* ptr) const - { - unsigned i; - for(i = 0; i < m_size; i++) - { - memcpy(ptr, &(*this)[i], sizeof(T)); - ptr += sizeof(T); - } - } - - //------------------------------------------------------------------------ - template - void pod_bvector::deserialize(const int8u* data, unsigned byte_size) - { - remove_all(); - byte_size /= sizeof(T); - for(unsigned i = 0; i < byte_size; ++i) - { - T* ptr = data_ptr(); - memcpy(ptr, data, sizeof(T)); - ++m_size; - data += sizeof(T); - } - } - - - // Replace or add a number of elements starting from "start" position - //------------------------------------------------------------------------ - template - void pod_bvector::deserialize(unsigned start, const T& empty_val, - const int8u* data, unsigned byte_size) - { - while(m_size < start) - { - add(empty_val); - } - - byte_size /= sizeof(T); - for(unsigned i = 0; i < byte_size; ++i) - { - if(start + i < m_size) - { - memcpy(&((*this)[start + i]), data, sizeof(T)); - } - else - { - T* ptr = data_ptr(); - memcpy(ptr, data, sizeof(T)); - ++m_size; - } - data += sizeof(T); - } - } - - - //---------------------------------------------------------block_allocator - // Allocator for arbitrary POD data. Most usable in different cache - // systems for efficient memory allocations. - // Memory is allocated with blocks of fixed size ("block_size" in - // the constructor). If required size exceeds the block size the allocator - // creates a new block of the required size. However, the most efficient - // use is when the average reqired size is much less than the block size. - //------------------------------------------------------------------------ - class block_allocator - { - struct block_type - { - int8u* data; - unsigned size; - }; - - public: - void remove_all() - { - if(m_num_blocks) - { - block_type* blk = m_blocks + m_num_blocks - 1; - while(m_num_blocks--) - { - pod_allocator::deallocate(blk->data, blk->size); - --blk; - } - pod_allocator::deallocate(m_blocks, m_max_blocks); - } - m_num_blocks = 0; - m_max_blocks = 0; - m_blocks = 0; - m_buf_ptr = 0; - m_rest = 0; - } - - ~block_allocator() - { - remove_all(); - } - - block_allocator(unsigned block_size, unsigned block_ptr_inc=256-8) : - m_block_size(block_size), - m_block_ptr_inc(block_ptr_inc), - m_num_blocks(0), - m_max_blocks(0), - m_blocks(0), - m_buf_ptr(0), - m_rest(0) - { - } - - - int8u* allocate(unsigned size, unsigned alignment=1) - { - if(size == 0) return 0; - if(size <= m_rest) - { - int8u* ptr = m_buf_ptr; - if(alignment > 1) - { - unsigned align = - (alignment - unsigned((size_t)ptr) % alignment) % alignment; - - size += align; - ptr += align; - if(size <= m_rest) - { - m_rest -= size; - m_buf_ptr += size; - return ptr; - } - allocate_block(size); - return allocate(size - align, alignment); - } - m_rest -= size; - m_buf_ptr += size; - return ptr; - } - allocate_block(size + alignment - 1); - return allocate(size, alignment); - } - - - private: - void allocate_block(unsigned size) - { - if(size < m_block_size) size = m_block_size; - if(m_num_blocks >= m_max_blocks) - { - block_type* new_blocks = - pod_allocator::allocate(m_max_blocks + m_block_ptr_inc); - - if(m_blocks) - { - memcpy(new_blocks, - m_blocks, - m_num_blocks * sizeof(block_type)); - pod_allocator::deallocate(m_blocks, m_max_blocks); - } - m_blocks = new_blocks; - m_max_blocks += m_block_ptr_inc; - } - - m_blocks[m_num_blocks].size = size; - m_blocks[m_num_blocks].data = - m_buf_ptr = - pod_allocator::allocate(size); - - m_num_blocks++; - m_rest = size; - } - - unsigned m_block_size; - unsigned m_block_ptr_inc; - unsigned m_num_blocks; - unsigned m_max_blocks; - block_type* m_blocks; - int8u* m_buf_ptr; - unsigned m_rest; - }; - - - - - - - - - //------------------------------------------------------------------------ - enum quick_sort_threshold_e - { - quick_sort_threshold = 9 - }; - - - //-----------------------------------------------------------swap_elements - template inline void swap_elements(T& a, T& b) - { - T temp = a; - a = b; - b = temp; - } - - - //--------------------------------------------------------------quick_sort - template - void quick_sort(Array& arr, Less less) - { - if(arr.size() < 2) return; - - typename Array::value_type* e1; - typename Array::value_type* e2; - - int stack[80]; - int* top = stack; - int limit = arr.size(); - int base = 0; - - for(;;) - { - int len = limit - base; - - int i; - int j; - int pivot; - - if(len > quick_sort_threshold) - { - // we use base + len/2 as the pivot - pivot = base + len / 2; - swap_elements(arr[base], arr[pivot]); - - i = base + 1; - j = limit - 1; - - // now ensure that *i <= *base <= *j - e1 = &(arr[j]); - e2 = &(arr[i]); - if(less(*e1, *e2)) swap_elements(*e1, *e2); - - e1 = &(arr[base]); - e2 = &(arr[i]); - if(less(*e1, *e2)) swap_elements(*e1, *e2); - - e1 = &(arr[j]); - e2 = &(arr[base]); - if(less(*e1, *e2)) swap_elements(*e1, *e2); - - for(;;) - { - do i++; while( less(arr[i], arr[base]) ); - do j--; while( less(arr[base], arr[j]) ); - - if( i > j ) - { - break; - } - - swap_elements(arr[i], arr[j]); - } - - swap_elements(arr[base], arr[j]); - - // now, push the largest sub-array - if(j - base > limit - i) - { - top[0] = base; - top[1] = j; - base = i; - } - else - { - top[0] = i; - top[1] = limit; - limit = j; - } - top += 2; - } - else - { - // the sub-array is small, perform insertion sort - j = base; - i = j + 1; - - for(; i < limit; j = i, i++) - { - for(; less(*(e1 = &(arr[j + 1])), *(e2 = &(arr[j]))); j--) - { - swap_elements(*e1, *e2); - if(j == base) - { - break; - } - } - } - if(top > stack) - { - top -= 2; - base = top[0]; - limit = top[1]; - } - else - { - break; - } - } - } - } - - - - - //------------------------------------------------------remove_duplicates - // Remove duplicates from a sorted array. It doesn't cut the - // tail of the array, it just returns the number of remaining elements. - //----------------------------------------------------------------------- - template - unsigned remove_duplicates(Array& arr, Equal equal) - { - if(arr.size() < 2) return arr.size(); - - unsigned i, j; - for(i = 1, j = 1; i < arr.size(); i++) - { - typename Array::value_type& e = arr[i]; - if(!equal(e, arr[i - 1])) - { - arr[j++] = e; - } - } - return j; - } - - //--------------------------------------------------------invert_container - template void invert_container(Array& arr) - { - int i = 0; - int j = arr.size() - 1; - while(i < j) - { - swap_elements(arr[i++], arr[j--]); - } - } - - //------------------------------------------------------binary_search_pos - template - unsigned binary_search_pos(const Array& arr, const Value& val, Less less) - { - if(arr.size() == 0) return 0; - - unsigned beg = 0; - unsigned end = arr.size() - 1; - - if(less(val, arr[0])) return 0; - if(less(arr[end], val)) return end + 1; - - while(end - beg > 1) - { - unsigned mid = (end + beg) >> 1; - if(less(val, arr[mid])) end = mid; - else beg = mid; - } - - //if(beg <= 0 && less(val, arr[0])) return 0; - //if(end >= arr.size() - 1 && less(arr[end], val)) ++end; - - return end; - } - - //----------------------------------------------------------range_adaptor - template class range_adaptor - { - public: - typedef typename Array::value_type value_type; - - range_adaptor(Array& array, unsigned start, unsigned size) : - m_array(array), m_start(start), m_size(size) - {} - - unsigned size() const { return m_size; } - const value_type& operator [] (unsigned i) const { return m_array[m_start + i]; } - value_type& operator [] (unsigned i) { return m_array[m_start + i]; } - const value_type& at(unsigned i) const { return m_array[m_start + i]; } - value_type& at(unsigned i) { return m_array[m_start + i]; } - value_type value_at(unsigned i) const { return m_array[m_start + i]; } - - private: - Array& m_array; - unsigned m_start; - unsigned m_size; - }; - - //---------------------------------------------------------------int_less - inline bool int_less(int a, int b) { return a < b; } - - //------------------------------------------------------------int_greater - inline bool int_greater(int a, int b) { return a > b; } - - //----------------------------------------------------------unsigned_less - inline bool unsigned_less(unsigned a, unsigned b) { return a < b; } - - //-------------------------------------------------------unsigned_greater - inline bool unsigned_greater(unsigned a, unsigned b) { return a > b; } -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_arrowhead.h b/desmume/src/windows/agg/include/agg_arrowhead.h deleted file mode 100644 index 9c7c97c63..000000000 --- a/desmume/src/windows/agg/include/agg_arrowhead.h +++ /dev/null @@ -1,88 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_ARROWHEAD_INCLUDED -#define AGG_ARROWHEAD_INCLUDED - -#include "agg_basics.h" - -namespace agg -{ - - //===============================================================arrowhead - // - // See implementation agg_arrowhead.cpp - // - class arrowhead - { - public: - arrowhead(); - - void head(double d1, double d2, double d3, double d4) - { - m_head_d1 = d1; - m_head_d2 = d2; - m_head_d3 = d3; - m_head_d4 = d4; - m_head_flag = true; - } - - void head() { m_head_flag = true; } - void no_head() { m_head_flag = false; } - - void tail(double d1, double d2, double d3, double d4) - { - m_tail_d1 = d1; - m_tail_d2 = d2; - m_tail_d3 = d3; - m_tail_d4 = d4; - m_tail_flag = true; - } - - void tail() { m_tail_flag = true; } - void no_tail() { m_tail_flag = false; } - - void rewind(unsigned path_id); - unsigned vertex(double* x, double* y); - - private: - double m_head_d1; - double m_head_d2; - double m_head_d3; - double m_head_d4; - double m_tail_d1; - double m_tail_d2; - double m_tail_d3; - double m_tail_d4; - bool m_head_flag; - bool m_tail_flag; - double m_coord[16]; - unsigned m_cmd[8]; - unsigned m_curr_id; - unsigned m_curr_coord; - }; - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_basics.h b/desmume/src/windows/agg/include/agg_basics.h deleted file mode 100644 index f673863b4..000000000 --- a/desmume/src/windows/agg/include/agg_basics.h +++ /dev/null @@ -1,539 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_BASICS_INCLUDED -#define AGG_BASICS_INCLUDED - -#include -#include "agg_config.h" - -//---------------------------------------------------------AGG_CUSTOM_ALLOCATOR -#ifdef AGG_CUSTOM_ALLOCATOR -#include "agg_allocator.h" -#else -namespace agg -{ - // The policy of all AGG containers and memory allocation strategy - // in general is that no allocated data requires explicit construction. - // It means that the allocator can be really simple; you can even - // replace new/delete to malloc/free. The constructors and destructors - // won't be called in this case, however everything will remain working. - // The second argument of deallocate() is the size of the allocated - // block. You can use this information if you wish. - //------------------------------------------------------------pod_allocator - template struct pod_allocator - { - static T* allocate(unsigned num) { return new T [num]; } - static void deallocate(T* ptr, unsigned) { delete [] ptr; } - }; - - // Single object allocator. It's also can be replaced with your custom - // allocator. The difference is that it can only allocate a single - // object and the constructor and destructor must be called. - // In AGG there is no need to allocate an array of objects with - // calling their constructors (only single ones). So that, if you - // replace these new/delete to malloc/free make sure that the in-place - // new is called and take care of calling the destructor too. - //------------------------------------------------------------obj_allocator - template struct obj_allocator - { - static T* allocate() { return new T; } - static void deallocate(T* ptr) { delete ptr; } - }; -} -#endif - - -//-------------------------------------------------------- Default basic types -// -// If the compiler has different capacity of the basic types you can redefine -// them via the compiler command line or by generating agg_config.h that is -// empty by default. -// -#ifndef AGG_INT8 -#define AGG_INT8 signed char -#endif - -#ifndef AGG_INT8U -#define AGG_INT8U unsigned char -#endif - -#ifndef AGG_INT16 -#define AGG_INT16 short -#endif - -#ifndef AGG_INT16U -#define AGG_INT16U unsigned short -#endif - -#ifndef AGG_INT32 -#define AGG_INT32 int -#endif - -#ifndef AGG_INT32U -#define AGG_INT32U unsigned -#endif - -#ifndef AGG_INT64 -#if defined(_MSC_VER) || defined(__BORLANDC__) -#define AGG_INT64 signed __int64 -#else -#define AGG_INT64 signed long long -#endif -#endif - -#ifndef AGG_INT64U -#if defined(_MSC_VER) || defined(__BORLANDC__) -#define AGG_INT64U unsigned __int64 -#else -#define AGG_INT64U unsigned long long -#endif -#endif - -//------------------------------------------------ Some fixes for MS Visual C++ -#if defined(_MSC_VER) -#pragma warning(disable:4786) // Identifier was truncated... -#endif - -#if defined(_MSC_VER) -#define AGG_INLINE __forceinline -#else -#define AGG_INLINE inline -#endif - -namespace agg -{ - //------------------------------------------------------------------------- - typedef AGG_INT8 int8; //----int8 - typedef AGG_INT8U int8u; //----int8u - typedef AGG_INT16 int16; //----int16 - typedef AGG_INT16U int16u; //----int16u - typedef AGG_INT32 int32; //----int32 - typedef AGG_INT32U int32u; //----int32u - typedef AGG_INT64 int64; //----int64 - typedef AGG_INT64U int64u; //----int64u - -#if defined(AGG_FISTP) -#pragma warning(push) -#pragma warning(disable : 4035) //Disable warning "no return value" - AGG_INLINE int iround(double v) //-------iround - { - int t; - __asm fld qword ptr [v] - __asm fistp dword ptr [t] - __asm mov eax, dword ptr [t] - } - AGG_INLINE unsigned uround(double v) //-------uround - { - unsigned t; - __asm fld qword ptr [v] - __asm fistp dword ptr [t] - __asm mov eax, dword ptr [t] - } -#pragma warning(pop) - AGG_INLINE unsigned ufloor(double v) //-------ufloor - { - return unsigned(floor(v)); - } - AGG_INLINE unsigned uceil(double v) //--------uceil - { - return unsigned(ceil(v)); - } -#elif defined(AGG_QIFIST) - AGG_INLINE int iround(double v) - { - return int(v); - } - AGG_INLINE int uround(double v) - { - return unsigned(v); - } - AGG_INLINE unsigned ufloor(double v) - { - return unsigned(floor(v)); - } - AGG_INLINE unsigned uceil(double v) - { - return unsigned(ceil(v)); - } -#else - AGG_INLINE int iround(double v) - { - return int((v < 0.0) ? v - 0.5 : v + 0.5); - } - AGG_INLINE int uround(double v) - { - return unsigned(v + 0.5); - } - AGG_INLINE unsigned ufloor(double v) - { - return unsigned(v); - } - AGG_INLINE unsigned uceil(double v) - { - return unsigned(ceil(v)); - } -#endif - - //---------------------------------------------------------------saturation - template struct saturation - { - AGG_INLINE static int iround(double v) - { - if(v < double(-Limit)) return -Limit; - if(v > double( Limit)) return Limit; - return agg::iround(v); - } - }; - - //------------------------------------------------------------------mul_one - template struct mul_one - { - AGG_INLINE static unsigned mul(unsigned a, unsigned b) - { - register unsigned q = a * b + (1 << (Shift-1)); - return (q + (q >> Shift)) >> Shift; - } - }; - - //------------------------------------------------------------------------- - typedef unsigned char cover_type; //----cover_type - enum cover_scale_e - { - cover_shift = 8, //----cover_shift - cover_size = 1 << cover_shift, //----cover_size - cover_mask = cover_size - 1, //----cover_mask - cover_none = 0, //----cover_none - cover_full = cover_mask //----cover_full - }; - - //----------------------------------------------------poly_subpixel_scale_e - // These constants determine the subpixel accuracy, to be more precise, - // the number of bits of the fractional part of the coordinates. - // The possible coordinate capacity in bits can be calculated by formula: - // sizeof(int) * 8 - poly_subpixel_shift, i.e, for 32-bit integers and - // 8-bits fractional part the capacity is 24 bits. - enum poly_subpixel_scale_e - { - poly_subpixel_shift = 8, //----poly_subpixel_shift - poly_subpixel_scale = 1< struct rect_base - { - typedef T value_type; - typedef rect_base self_type; - T x1, y1, x2, y2; - - rect_base() {} - rect_base(T x1_, T y1_, T x2_, T y2_) : - x1(x1_), y1(y1_), x2(x2_), y2(y2_) {} - - void init(T x1_, T y1_, T x2_, T y2_) - { - x1 = x1_; y1 = y1_; x2 = x2_; y2 = y2_; - } - - const self_type& normalize() - { - T t; - if(x1 > x2) { t = x1; x1 = x2; x2 = t; } - if(y1 > y2) { t = y1; y1 = y2; y2 = t; } - return *this; - } - - bool clip(const self_type& r) - { - if(x2 > r.x2) x2 = r.x2; - if(y2 > r.y2) y2 = r.y2; - if(x1 < r.x1) x1 = r.x1; - if(y1 < r.y1) y1 = r.y1; - return x1 <= x2 && y1 <= y2; - } - - bool is_valid() const - { - return x1 <= x2 && y1 <= y2; - } - - bool hit_test(T x, T y) const - { - return (x >= x1 && x <= x2 && y >= y1 && y <= y2); - } - }; - - //-----------------------------------------------------intersect_rectangles - template - inline Rect intersect_rectangles(const Rect& r1, const Rect& r2) - { - Rect r = r1; - - // First process x2,y2 because the other order - // results in Internal Compiler Error under - // Microsoft Visual C++ .NET 2003 69462-335-0000007-18038 in - // case of "Maximize Speed" optimization option. - //----------------- - if(r.x2 > r2.x2) r.x2 = r2.x2; - if(r.y2 > r2.y2) r.y2 = r2.y2; - if(r.x1 < r2.x1) r.x1 = r2.x1; - if(r.y1 < r2.y1) r.y1 = r2.y1; - return r; - } - - - //---------------------------------------------------------unite_rectangles - template - inline Rect unite_rectangles(const Rect& r1, const Rect& r2) - { - Rect r = r1; - if(r.x2 < r2.x2) r.x2 = r2.x2; - if(r.y2 < r2.y2) r.y2 = r2.y2; - if(r.x1 > r2.x1) r.x1 = r2.x1; - if(r.y1 > r2.y1) r.y1 = r2.y1; - return r; - } - - typedef rect_base rect_i; //----rect_i - typedef rect_base rect_f; //----rect_f - typedef rect_base rect_d; //----rect_d - - //---------------------------------------------------------path_commands_e - enum path_commands_e - { - path_cmd_stop = 0, //----path_cmd_stop - path_cmd_move_to = 1, //----path_cmd_move_to - path_cmd_line_to = 2, //----path_cmd_line_to - path_cmd_curve3 = 3, //----path_cmd_curve3 - path_cmd_curve4 = 4, //----path_cmd_curve4 - path_cmd_curveN = 5, //----path_cmd_curveN - path_cmd_catrom = 6, //----path_cmd_catrom - path_cmd_ubspline = 7, //----path_cmd_ubspline - path_cmd_end_poly = 0x0F, //----path_cmd_end_poly - path_cmd_mask = 0x0F //----path_cmd_mask - }; - - //------------------------------------------------------------path_flags_e - enum path_flags_e - { - path_flags_none = 0, //----path_flags_none - path_flags_ccw = 0x10, //----path_flags_ccw - path_flags_cw = 0x20, //----path_flags_cw - path_flags_close = 0x40, //----path_flags_close - path_flags_mask = 0xF0 //----path_flags_mask - }; - - //---------------------------------------------------------------is_vertex - inline bool is_vertex(unsigned c) - { - return c >= path_cmd_move_to && c < path_cmd_end_poly; - } - - //--------------------------------------------------------------is_drawing - inline bool is_drawing(unsigned c) - { - return c >= path_cmd_line_to && c < path_cmd_end_poly; - } - - //-----------------------------------------------------------------is_stop - inline bool is_stop(unsigned c) - { - return c == path_cmd_stop; - } - - //--------------------------------------------------------------is_move_to - inline bool is_move_to(unsigned c) - { - return c == path_cmd_move_to; - } - - //--------------------------------------------------------------is_line_to - inline bool is_line_to(unsigned c) - { - return c == path_cmd_line_to; - } - - //----------------------------------------------------------------is_curve - inline bool is_curve(unsigned c) - { - return c == path_cmd_curve3 || c == path_cmd_curve4; - } - - //---------------------------------------------------------------is_curve3 - inline bool is_curve3(unsigned c) - { - return c == path_cmd_curve3; - } - - //---------------------------------------------------------------is_curve4 - inline bool is_curve4(unsigned c) - { - return c == path_cmd_curve4; - } - - //-------------------------------------------------------------is_end_poly - inline bool is_end_poly(unsigned c) - { - return (c & path_cmd_mask) == path_cmd_end_poly; - } - - //----------------------------------------------------------------is_close - inline bool is_close(unsigned c) - { - return (c & ~(path_flags_cw | path_flags_ccw)) == - (path_cmd_end_poly | path_flags_close); - } - - //------------------------------------------------------------is_next_poly - inline bool is_next_poly(unsigned c) - { - return is_stop(c) || is_move_to(c) || is_end_poly(c); - } - - //-------------------------------------------------------------------is_cw - inline bool is_cw(unsigned c) - { - return (c & path_flags_cw) != 0; - } - - //------------------------------------------------------------------is_ccw - inline bool is_ccw(unsigned c) - { - return (c & path_flags_ccw) != 0; - } - - //-------------------------------------------------------------is_oriented - inline bool is_oriented(unsigned c) - { - return (c & (path_flags_cw | path_flags_ccw)) != 0; - } - - //---------------------------------------------------------------is_closed - inline bool is_closed(unsigned c) - { - return (c & path_flags_close) != 0; - } - - //----------------------------------------------------------get_close_flag - inline unsigned get_close_flag(unsigned c) - { - return c & path_flags_close; - } - - //-------------------------------------------------------clear_orientation - inline unsigned clear_orientation(unsigned c) - { - return c & ~(path_flags_cw | path_flags_ccw); - } - - //---------------------------------------------------------get_orientation - inline unsigned get_orientation(unsigned c) - { - return c & (path_flags_cw | path_flags_ccw); - } - - //---------------------------------------------------------set_orientation - inline unsigned set_orientation(unsigned c, unsigned o) - { - return clear_orientation(c) | o; - } - - //--------------------------------------------------------------point_base - template struct point_base - { - typedef T value_type; - T x,y; - point_base() {} - point_base(T x_, T y_) : x(x_), y(y_) {} - }; - typedef point_base point_i; //-----point_i - typedef point_base point_f; //-----point_f - typedef point_base point_d; //-----point_d - - //-------------------------------------------------------------vertex_base - template struct vertex_base - { - typedef T value_type; - T x,y; - unsigned cmd; - vertex_base() {} - vertex_base(T x_, T y_, unsigned cmd_) : x(x_), y(y_), cmd(cmd_) {} - }; - typedef vertex_base vertex_i; //-----vertex_i - typedef vertex_base vertex_f; //-----vertex_f - typedef vertex_base vertex_d; //-----vertex_d - - //----------------------------------------------------------------row_info - template struct row_info - { - int x1, x2; - T* ptr; - row_info() {} - row_info(int x1_, int x2_, T* ptr_) : x1(x1_), x2(x2_), ptr(ptr_) {} - }; - - //----------------------------------------------------------const_row_info - template struct const_row_info - { - int x1, x2; - const T* ptr; - const_row_info() {} - const_row_info(int x1_, int x2_, const T* ptr_) : - x1(x1_), x2(x2_), ptr(ptr_) {} - }; - - //------------------------------------------------------------is_equal_eps - template inline bool is_equal_eps(T v1, T v2, T epsilon) - { - return fabs(v1 - v2) <= double(epsilon); - } - -} - - -#endif - diff --git a/desmume/src/windows/agg/include/agg_bezier_arc.h b/desmume/src/windows/agg/include/agg_bezier_arc.h deleted file mode 100644 index faca7b691..000000000 --- a/desmume/src/windows/agg/include/agg_bezier_arc.h +++ /dev/null @@ -1,163 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_BEZIER_ARC_INCLUDED -#define AGG_BEZIER_ARC_INCLUDED - -#include "agg_conv_transform.h" - -namespace agg -{ - - //----------------------------------------------------------------------- - void arc_to_bezier(double cx, double cy, double rx, double ry, - double start_angle, double sweep_angle, - double* curve); - - - //==============================================================bezier_arc - // - // See implemantaion agg_bezier_arc.cpp - // - class bezier_arc - { - public: - //-------------------------------------------------------------------- - bezier_arc() : m_vertex(26), m_num_vertices(0), m_cmd(path_cmd_line_to) {} - bezier_arc(double x, double y, - double rx, double ry, - double start_angle, - double sweep_angle) - { - init(x, y, rx, ry, start_angle, sweep_angle); - } - - //-------------------------------------------------------------------- - void init(double x, double y, - double rx, double ry, - double start_angle, - double sweep_angle); - - //-------------------------------------------------------------------- - void rewind(unsigned) - { - m_vertex = 0; - } - - //-------------------------------------------------------------------- - unsigned vertex(double* x, double* y) - { - if(m_vertex >= m_num_vertices) return path_cmd_stop; - *x = m_vertices[m_vertex]; - *y = m_vertices[m_vertex + 1]; - m_vertex += 2; - return (m_vertex == 2) ? path_cmd_move_to : m_cmd; - } - - // Supplemantary functions. num_vertices() actually returns doubled - // number of vertices. That is, for 1 vertex it returns 2. - //-------------------------------------------------------------------- - unsigned num_vertices() const { return m_num_vertices; } - const double* vertices() const { return m_vertices; } - double* vertices() { return m_vertices; } - - private: - unsigned m_vertex; - unsigned m_num_vertices; - double m_vertices[26]; - unsigned m_cmd; - }; - - - - //==========================================================bezier_arc_svg - // Compute an SVG-style bezier arc. - // - // Computes an elliptical arc from (x1, y1) to (x2, y2). The size and - // orientation of the ellipse are defined by two radii (rx, ry) - // and an x-axis-rotation, which indicates how the ellipse as a whole - // is rotated relative to the current coordinate system. The center - // (cx, cy) of the ellipse is calculated automatically to satisfy the - // constraints imposed by the other parameters. - // large-arc-flag and sweep-flag contribute to the automatic calculations - // and help determine how the arc is drawn. - class bezier_arc_svg - { - public: - //-------------------------------------------------------------------- - bezier_arc_svg() : m_arc(), m_radii_ok(false) {} - - bezier_arc_svg(double x1, double y1, - double rx, double ry, - double angle, - bool large_arc_flag, - bool sweep_flag, - double x2, double y2) : - m_arc(), m_radii_ok(false) - { - init(x1, y1, rx, ry, angle, large_arc_flag, sweep_flag, x2, y2); - } - - //-------------------------------------------------------------------- - void init(double x1, double y1, - double rx, double ry, - double angle, - bool large_arc_flag, - bool sweep_flag, - double x2, double y2); - - //-------------------------------------------------------------------- - bool radii_ok() const { return m_radii_ok; } - - //-------------------------------------------------------------------- - void rewind(unsigned) - { - m_arc.rewind(0); - } - - //-------------------------------------------------------------------- - unsigned vertex(double* x, double* y) - { - return m_arc.vertex(x, y); - } - - // Supplemantary functions. num_vertices() actually returns doubled - // number of vertices. That is, for 1 vertex it returns 2. - //-------------------------------------------------------------------- - unsigned num_vertices() const { return m_arc.num_vertices(); } - const double* vertices() const { return m_arc.vertices(); } - double* vertices() { return m_arc.vertices(); } - - private: - bezier_arc m_arc; - bool m_radii_ok; - }; - - - - -} - - -#endif diff --git a/desmume/src/windows/agg/include/agg_bitset_iterator.h b/desmume/src/windows/agg/include/agg_bitset_iterator.h deleted file mode 100644 index 1337f7819..000000000 --- a/desmume/src/windows/agg/include/agg_bitset_iterator.h +++ /dev/null @@ -1,63 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_BITSET_ITERATOR_INCLUDED -#define AGG_BITSET_ITERATOR_INCLUDED - -#include "agg_basics.h" - -namespace agg -{ - - class bitset_iterator - { - public: - bitset_iterator(const int8u* bits, unsigned offset = 0) : - m_bits(bits + (offset >> 3)), - m_mask(0x80 >> (offset & 7)) - {} - - void operator ++ () - { - m_mask >>= 1; - if(m_mask == 0) - { - ++m_bits; - m_mask = 0x80; - } - } - - unsigned bit() const - { - return (*m_bits) & m_mask; - } - - private: - const int8u* m_bits; - int8u m_mask; - }; - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_blur.h b/desmume/src/windows/agg/include/agg_blur.h deleted file mode 100644 index 26c36a8d2..000000000 --- a/desmume/src/windows/agg/include/agg_blur.h +++ /dev/null @@ -1,1303 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- -// -// The Stack Blur Algorithm was invented by Mario Klingemann, -// mario@quasimondo.com and described here: -// http://incubator.quasimondo.com/processing/fast_blur_deluxe.php -// (search phrase "Stackblur: Fast But Goodlooking"). -// The major improvement is that there's no more division table -// that was very expensive to create for large blur radii. Insted, -// for 8-bit per channel and radius not exceeding 254 the division is -// replaced by multiplication and shift. -// -//---------------------------------------------------------------------------- - -#ifndef AGG_BLUR_INCLUDED -#define AGG_BLUR_INCLUDED - -#include "agg_array.h" -#include "agg_pixfmt_transposer.h" - -namespace agg -{ - - template struct stack_blur_tables - { - static int16u const g_stack_blur8_mul[255]; - static int8u const g_stack_blur8_shr[255]; - }; - - //------------------------------------------------------------------------ - template - int16u const stack_blur_tables::g_stack_blur8_mul[255] = - { - 512,512,456,512,328,456,335,512,405,328,271,456,388,335,292,512, - 454,405,364,328,298,271,496,456,420,388,360,335,312,292,273,512, - 482,454,428,405,383,364,345,328,312,298,284,271,259,496,475,456, - 437,420,404,388,374,360,347,335,323,312,302,292,282,273,265,512, - 497,482,468,454,441,428,417,405,394,383,373,364,354,345,337,328, - 320,312,305,298,291,284,278,271,265,259,507,496,485,475,465,456, - 446,437,428,420,412,404,396,388,381,374,367,360,354,347,341,335, - 329,323,318,312,307,302,297,292,287,282,278,273,269,265,261,512, - 505,497,489,482,475,468,461,454,447,441,435,428,422,417,411,405, - 399,394,389,383,378,373,368,364,359,354,350,345,341,337,332,328, - 324,320,316,312,309,305,301,298,294,291,287,284,281,278,274,271, - 268,265,262,259,257,507,501,496,491,485,480,475,470,465,460,456, - 451,446,442,437,433,428,424,420,416,412,408,404,400,396,392,388, - 385,381,377,374,370,367,363,360,357,354,350,347,344,341,338,335, - 332,329,326,323,320,318,315,312,310,307,304,302,299,297,294,292, - 289,287,285,282,280,278,275,273,271,269,267,265,263,261,259 - }; - - //------------------------------------------------------------------------ - template - int8u const stack_blur_tables::g_stack_blur8_shr[255] = - { - 9, 11, 12, 13, 13, 14, 14, 15, 15, 15, 15, 16, 16, 16, 16, 17, - 17, 17, 17, 17, 17, 17, 18, 18, 18, 18, 18, 18, 18, 18, 18, 19, - 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 20, 20, 20, - 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 21, - 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, - 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 22, 22, 22, 22, 22, 22, - 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, - 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 23, - 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, - 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, - 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, - 23, 23, 23, 23, 23, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, - 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, - 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, - 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, - 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24 - }; - - - - //==============================================================stack_blur - template class stack_blur - { - public: - typedef ColorT color_type; - typedef CalculatorT calculator_type; - - //-------------------------------------------------------------------- - template void blur_x(Img& img, unsigned radius) - { - if(radius < 1) return; - - unsigned x, y, xp, i; - unsigned stack_ptr; - unsigned stack_start; - - color_type pix; - color_type* stack_pix; - calculator_type sum; - calculator_type sum_in; - calculator_type sum_out; - - unsigned w = img.width(); - unsigned h = img.height(); - unsigned wm = w - 1; - unsigned div = radius * 2 + 1; - - unsigned div_sum = (radius + 1) * (radius + 1); - unsigned mul_sum = 0; - unsigned shr_sum = 0; - unsigned max_val = color_type::base_mask; - - if(max_val <= 255 && radius < 255) - { - mul_sum = stack_blur_tables::g_stack_blur8_mul[radius]; - shr_sum = stack_blur_tables::g_stack_blur8_shr[radius]; - } - - m_buf.allocate(w, 128); - m_stack.allocate(div, 32); - - for(y = 0; y < h; y++) - { - sum.clear(); - sum_in.clear(); - sum_out.clear(); - - pix = img.pixel(0, y); - for(i = 0; i <= radius; i++) - { - m_stack[i] = pix; - sum.add(pix, i + 1); - sum_out.add(pix); - } - for(i = 1; i <= radius; i++) - { - pix = img.pixel((i > wm) ? wm : i, y); - m_stack[i + radius] = pix; - sum.add(pix, radius + 1 - i); - sum_in.add(pix); - } - - stack_ptr = radius; - for(x = 0; x < w; x++) - { - if(mul_sum) sum.calc_pix(m_buf[x], mul_sum, shr_sum); - else sum.calc_pix(m_buf[x], div_sum); - - sum.sub(sum_out); - - stack_start = stack_ptr + div - radius; - if(stack_start >= div) stack_start -= div; - stack_pix = &m_stack[stack_start]; - - sum_out.sub(*stack_pix); - - xp = x + radius + 1; - if(xp > wm) xp = wm; - pix = img.pixel(xp, y); - - *stack_pix = pix; - - sum_in.add(pix); - sum.add(sum_in); - - ++stack_ptr; - if(stack_ptr >= div) stack_ptr = 0; - stack_pix = &m_stack[stack_ptr]; - - sum_out.add(*stack_pix); - sum_in.sub(*stack_pix); - } - img.copy_color_hspan(0, y, w, &m_buf[0]); - } - } - - //-------------------------------------------------------------------- - template void blur_y(Img& img, unsigned radius) - { - pixfmt_transposer img2(img); - blur_x(img2, radius); - } - - //-------------------------------------------------------------------- - template void blur(Img& img, unsigned radius) - { - blur_x(img, radius); - pixfmt_transposer img2(img); - blur_x(img2, radius); - } - - private: - pod_vector m_buf; - pod_vector m_stack; - }; - - //====================================================stack_blur_calc_rgba - template struct stack_blur_calc_rgba - { - typedef T value_type; - value_type r,g,b,a; - - AGG_INLINE void clear() - { - r = g = b = a = 0; - } - - template AGG_INLINE void add(const ArgT& v) - { - r += v.r; - g += v.g; - b += v.b; - a += v.a; - } - - template AGG_INLINE void add(const ArgT& v, unsigned k) - { - r += v.r * k; - g += v.g * k; - b += v.b * k; - a += v.a * k; - } - - template AGG_INLINE void sub(const ArgT& v) - { - r -= v.r; - g -= v.g; - b -= v.b; - a -= v.a; - } - - template AGG_INLINE void calc_pix(ArgT& v, unsigned div) - { - typedef typename ArgT::value_type value_type; - v.r = value_type(r / div); - v.g = value_type(g / div); - v.b = value_type(b / div); - v.a = value_type(a / div); - } - - template - AGG_INLINE void calc_pix(ArgT& v, unsigned mul, unsigned shr) - { - typedef typename ArgT::value_type value_type; - v.r = value_type((r * mul) >> shr); - v.g = value_type((g * mul) >> shr); - v.b = value_type((b * mul) >> shr); - v.a = value_type((a * mul) >> shr); - } - }; - - - //=====================================================stack_blur_calc_rgb - template struct stack_blur_calc_rgb - { - typedef T value_type; - value_type r,g,b; - - AGG_INLINE void clear() - { - r = g = b = 0; - } - - template AGG_INLINE void add(const ArgT& v) - { - r += v.r; - g += v.g; - b += v.b; - } - - template AGG_INLINE void add(const ArgT& v, unsigned k) - { - r += v.r * k; - g += v.g * k; - b += v.b * k; - } - - template AGG_INLINE void sub(const ArgT& v) - { - r -= v.r; - g -= v.g; - b -= v.b; - } - - template AGG_INLINE void calc_pix(ArgT& v, unsigned div) - { - typedef typename ArgT::value_type value_type; - v.r = value_type(r / div); - v.g = value_type(g / div); - v.b = value_type(b / div); - } - - template - AGG_INLINE void calc_pix(ArgT& v, unsigned mul, unsigned shr) - { - typedef typename ArgT::value_type value_type; - v.r = value_type((r * mul) >> shr); - v.g = value_type((g * mul) >> shr); - v.b = value_type((b * mul) >> shr); - } - }; - - - //====================================================stack_blur_calc_gray - template struct stack_blur_calc_gray - { - typedef T value_type; - value_type v; - - AGG_INLINE void clear() - { - v = 0; - } - - template AGG_INLINE void add(const ArgT& a) - { - v += a.v; - } - - template AGG_INLINE void add(const ArgT& a, unsigned k) - { - v += a.v * k; - } - - template AGG_INLINE void sub(const ArgT& a) - { - v -= a.v; - } - - template AGG_INLINE void calc_pix(ArgT& a, unsigned div) - { - typedef typename ArgT::value_type value_type; - a.v = value_type(v / div); - } - - template - AGG_INLINE void calc_pix(ArgT& a, unsigned mul, unsigned shr) - { - typedef typename ArgT::value_type value_type; - a.v = value_type((v * mul) >> shr); - } - }; - - - - //========================================================stack_blur_gray8 - template - void stack_blur_gray8(Img& img, unsigned rx, unsigned ry) - { - unsigned x, y, xp, yp, i; - unsigned stack_ptr; - unsigned stack_start; - - const int8u* src_pix_ptr; - int8u* dst_pix_ptr; - unsigned pix; - unsigned stack_pix; - unsigned sum; - unsigned sum_in; - unsigned sum_out; - - unsigned w = img.width(); - unsigned h = img.height(); - unsigned wm = w - 1; - unsigned hm = h - 1; - - unsigned div; - unsigned mul_sum; - unsigned shr_sum; - - pod_vector stack; - - if(rx > 0) - { - if(rx > 254) rx = 254; - div = rx * 2 + 1; - mul_sum = stack_blur_tables::g_stack_blur8_mul[rx]; - shr_sum = stack_blur_tables::g_stack_blur8_shr[rx]; - stack.allocate(div); - - for(y = 0; y < h; y++) - { - sum = sum_in = sum_out = 0; - - src_pix_ptr = img.pix_ptr(0, y); - pix = *src_pix_ptr; - for(i = 0; i <= rx; i++) - { - stack[i] = pix; - sum += pix * (i + 1); - sum_out += pix; - } - for(i = 1; i <= rx; i++) - { - if(i <= wm) src_pix_ptr += Img::pix_step; - pix = *src_pix_ptr; - stack[i + rx] = pix; - sum += pix * (rx + 1 - i); - sum_in += pix; - } - - stack_ptr = rx; - xp = rx; - if(xp > wm) xp = wm; - src_pix_ptr = img.pix_ptr(xp, y); - dst_pix_ptr = img.pix_ptr(0, y); - for(x = 0; x < w; x++) - { - *dst_pix_ptr = (sum * mul_sum) >> shr_sum; - dst_pix_ptr += Img::pix_step; - - sum -= sum_out; - - stack_start = stack_ptr + div - rx; - if(stack_start >= div) stack_start -= div; - sum_out -= stack[stack_start]; - - if(xp < wm) - { - src_pix_ptr += Img::pix_step; - pix = *src_pix_ptr; - ++xp; - } - - stack[stack_start] = pix; - - sum_in += pix; - sum += sum_in; - - ++stack_ptr; - if(stack_ptr >= div) stack_ptr = 0; - stack_pix = stack[stack_ptr]; - - sum_out += stack_pix; - sum_in -= stack_pix; - } - } - } - - if(ry > 0) - { - if(ry > 254) ry = 254; - div = ry * 2 + 1; - mul_sum = stack_blur_tables::g_stack_blur8_mul[ry]; - shr_sum = stack_blur_tables::g_stack_blur8_shr[ry]; - stack.allocate(div); - - int stride = img.stride(); - for(x = 0; x < w; x++) - { - sum = sum_in = sum_out = 0; - - src_pix_ptr = img.pix_ptr(x, 0); - pix = *src_pix_ptr; - for(i = 0; i <= ry; i++) - { - stack[i] = pix; - sum += pix * (i + 1); - sum_out += pix; - } - for(i = 1; i <= ry; i++) - { - if(i <= hm) src_pix_ptr += stride; - pix = *src_pix_ptr; - stack[i + ry] = pix; - sum += pix * (ry + 1 - i); - sum_in += pix; - } - - stack_ptr = ry; - yp = ry; - if(yp > hm) yp = hm; - src_pix_ptr = img.pix_ptr(x, yp); - dst_pix_ptr = img.pix_ptr(x, 0); - for(y = 0; y < h; y++) - { - *dst_pix_ptr = (sum * mul_sum) >> shr_sum; - dst_pix_ptr += stride; - - sum -= sum_out; - - stack_start = stack_ptr + div - ry; - if(stack_start >= div) stack_start -= div; - sum_out -= stack[stack_start]; - - if(yp < hm) - { - src_pix_ptr += stride; - pix = *src_pix_ptr; - ++yp; - } - - stack[stack_start] = pix; - - sum_in += pix; - sum += sum_in; - - ++stack_ptr; - if(stack_ptr >= div) stack_ptr = 0; - stack_pix = stack[stack_ptr]; - - sum_out += stack_pix; - sum_in -= stack_pix; - } - } - } - } - - - - //========================================================stack_blur_rgb24 - template - void stack_blur_rgb24(Img& img, unsigned rx, unsigned ry) - { - typedef typename Img::color_type color_type; - typedef typename Img::order_type order_type; - enum order_e - { - R = order_type::R, - G = order_type::G, - B = order_type::B - }; - - unsigned x, y, xp, yp, i; - unsigned stack_ptr; - unsigned stack_start; - - const int8u* src_pix_ptr; - int8u* dst_pix_ptr; - color_type* stack_pix_ptr; - - unsigned sum_r; - unsigned sum_g; - unsigned sum_b; - unsigned sum_in_r; - unsigned sum_in_g; - unsigned sum_in_b; - unsigned sum_out_r; - unsigned sum_out_g; - unsigned sum_out_b; - - unsigned w = img.width(); - unsigned h = img.height(); - unsigned wm = w - 1; - unsigned hm = h - 1; - - unsigned div; - unsigned mul_sum; - unsigned shr_sum; - - pod_vector stack; - - if(rx > 0) - { - if(rx > 254) rx = 254; - div = rx * 2 + 1; - mul_sum = stack_blur_tables::g_stack_blur8_mul[rx]; - shr_sum = stack_blur_tables::g_stack_blur8_shr[rx]; - stack.allocate(div); - - for(y = 0; y < h; y++) - { - sum_r = - sum_g = - sum_b = - sum_in_r = - sum_in_g = - sum_in_b = - sum_out_r = - sum_out_g = - sum_out_b = 0; - - src_pix_ptr = img.pix_ptr(0, y); - for(i = 0; i <= rx; i++) - { - stack_pix_ptr = &stack[i]; - stack_pix_ptr->r = src_pix_ptr[R]; - stack_pix_ptr->g = src_pix_ptr[G]; - stack_pix_ptr->b = src_pix_ptr[B]; - sum_r += src_pix_ptr[R] * (i + 1); - sum_g += src_pix_ptr[G] * (i + 1); - sum_b += src_pix_ptr[B] * (i + 1); - sum_out_r += src_pix_ptr[R]; - sum_out_g += src_pix_ptr[G]; - sum_out_b += src_pix_ptr[B]; - } - for(i = 1; i <= rx; i++) - { - if(i <= wm) src_pix_ptr += Img::pix_width; - stack_pix_ptr = &stack[i + rx]; - stack_pix_ptr->r = src_pix_ptr[R]; - stack_pix_ptr->g = src_pix_ptr[G]; - stack_pix_ptr->b = src_pix_ptr[B]; - sum_r += src_pix_ptr[R] * (rx + 1 - i); - sum_g += src_pix_ptr[G] * (rx + 1 - i); - sum_b += src_pix_ptr[B] * (rx + 1 - i); - sum_in_r += src_pix_ptr[R]; - sum_in_g += src_pix_ptr[G]; - sum_in_b += src_pix_ptr[B]; - } - - stack_ptr = rx; - xp = rx; - if(xp > wm) xp = wm; - src_pix_ptr = img.pix_ptr(xp, y); - dst_pix_ptr = img.pix_ptr(0, y); - for(x = 0; x < w; x++) - { - dst_pix_ptr[R] = (sum_r * mul_sum) >> shr_sum; - dst_pix_ptr[G] = (sum_g * mul_sum) >> shr_sum; - dst_pix_ptr[B] = (sum_b * mul_sum) >> shr_sum; - dst_pix_ptr += Img::pix_width; - - sum_r -= sum_out_r; - sum_g -= sum_out_g; - sum_b -= sum_out_b; - - stack_start = stack_ptr + div - rx; - if(stack_start >= div) stack_start -= div; - stack_pix_ptr = &stack[stack_start]; - - sum_out_r -= stack_pix_ptr->r; - sum_out_g -= stack_pix_ptr->g; - sum_out_b -= stack_pix_ptr->b; - - if(xp < wm) - { - src_pix_ptr += Img::pix_width; - ++xp; - } - - stack_pix_ptr->r = src_pix_ptr[R]; - stack_pix_ptr->g = src_pix_ptr[G]; - stack_pix_ptr->b = src_pix_ptr[B]; - - sum_in_r += src_pix_ptr[R]; - sum_in_g += src_pix_ptr[G]; - sum_in_b += src_pix_ptr[B]; - sum_r += sum_in_r; - sum_g += sum_in_g; - sum_b += sum_in_b; - - ++stack_ptr; - if(stack_ptr >= div) stack_ptr = 0; - stack_pix_ptr = &stack[stack_ptr]; - - sum_out_r += stack_pix_ptr->r; - sum_out_g += stack_pix_ptr->g; - sum_out_b += stack_pix_ptr->b; - sum_in_r -= stack_pix_ptr->r; - sum_in_g -= stack_pix_ptr->g; - sum_in_b -= stack_pix_ptr->b; - } - } - } - - if(ry > 0) - { - if(ry > 254) ry = 254; - div = ry * 2 + 1; - mul_sum = stack_blur_tables::g_stack_blur8_mul[ry]; - shr_sum = stack_blur_tables::g_stack_blur8_shr[ry]; - stack.allocate(div); - - int stride = img.stride(); - for(x = 0; x < w; x++) - { - sum_r = - sum_g = - sum_b = - sum_in_r = - sum_in_g = - sum_in_b = - sum_out_r = - sum_out_g = - sum_out_b = 0; - - src_pix_ptr = img.pix_ptr(x, 0); - for(i = 0; i <= ry; i++) - { - stack_pix_ptr = &stack[i]; - stack_pix_ptr->r = src_pix_ptr[R]; - stack_pix_ptr->g = src_pix_ptr[G]; - stack_pix_ptr->b = src_pix_ptr[B]; - sum_r += src_pix_ptr[R] * (i + 1); - sum_g += src_pix_ptr[G] * (i + 1); - sum_b += src_pix_ptr[B] * (i + 1); - sum_out_r += src_pix_ptr[R]; - sum_out_g += src_pix_ptr[G]; - sum_out_b += src_pix_ptr[B]; - } - for(i = 1; i <= ry; i++) - { - if(i <= hm) src_pix_ptr += stride; - stack_pix_ptr = &stack[i + ry]; - stack_pix_ptr->r = src_pix_ptr[R]; - stack_pix_ptr->g = src_pix_ptr[G]; - stack_pix_ptr->b = src_pix_ptr[B]; - sum_r += src_pix_ptr[R] * (ry + 1 - i); - sum_g += src_pix_ptr[G] * (ry + 1 - i); - sum_b += src_pix_ptr[B] * (ry + 1 - i); - sum_in_r += src_pix_ptr[R]; - sum_in_g += src_pix_ptr[G]; - sum_in_b += src_pix_ptr[B]; - } - - stack_ptr = ry; - yp = ry; - if(yp > hm) yp = hm; - src_pix_ptr = img.pix_ptr(x, yp); - dst_pix_ptr = img.pix_ptr(x, 0); - for(y = 0; y < h; y++) - { - dst_pix_ptr[R] = (sum_r * mul_sum) >> shr_sum; - dst_pix_ptr[G] = (sum_g * mul_sum) >> shr_sum; - dst_pix_ptr[B] = (sum_b * mul_sum) >> shr_sum; - dst_pix_ptr += stride; - - sum_r -= sum_out_r; - sum_g -= sum_out_g; - sum_b -= sum_out_b; - - stack_start = stack_ptr + div - ry; - if(stack_start >= div) stack_start -= div; - - stack_pix_ptr = &stack[stack_start]; - sum_out_r -= stack_pix_ptr->r; - sum_out_g -= stack_pix_ptr->g; - sum_out_b -= stack_pix_ptr->b; - - if(yp < hm) - { - src_pix_ptr += stride; - ++yp; - } - - stack_pix_ptr->r = src_pix_ptr[R]; - stack_pix_ptr->g = src_pix_ptr[G]; - stack_pix_ptr->b = src_pix_ptr[B]; - - sum_in_r += src_pix_ptr[R]; - sum_in_g += src_pix_ptr[G]; - sum_in_b += src_pix_ptr[B]; - sum_r += sum_in_r; - sum_g += sum_in_g; - sum_b += sum_in_b; - - ++stack_ptr; - if(stack_ptr >= div) stack_ptr = 0; - stack_pix_ptr = &stack[stack_ptr]; - - sum_out_r += stack_pix_ptr->r; - sum_out_g += stack_pix_ptr->g; - sum_out_b += stack_pix_ptr->b; - sum_in_r -= stack_pix_ptr->r; - sum_in_g -= stack_pix_ptr->g; - sum_in_b -= stack_pix_ptr->b; - } - } - } - } - - - - //=======================================================stack_blur_rgba32 - template - void stack_blur_rgba32(Img& img, unsigned rx, unsigned ry) - { - typedef typename Img::color_type color_type; - typedef typename Img::order_type order_type; - enum order_e - { - R = order_type::R, - G = order_type::G, - B = order_type::B, - A = order_type::A - }; - - unsigned x, y, xp, yp, i; - unsigned stack_ptr; - unsigned stack_start; - - const int8u* src_pix_ptr; - int8u* dst_pix_ptr; - color_type* stack_pix_ptr; - - unsigned sum_r; - unsigned sum_g; - unsigned sum_b; - unsigned sum_a; - unsigned sum_in_r; - unsigned sum_in_g; - unsigned sum_in_b; - unsigned sum_in_a; - unsigned sum_out_r; - unsigned sum_out_g; - unsigned sum_out_b; - unsigned sum_out_a; - - unsigned w = img.width(); - unsigned h = img.height(); - unsigned wm = w - 1; - unsigned hm = h - 1; - - unsigned div; - unsigned mul_sum; - unsigned shr_sum; - - pod_vector stack; - - if(rx > 0) - { - if(rx > 254) rx = 254; - div = rx * 2 + 1; - mul_sum = stack_blur_tables::g_stack_blur8_mul[rx]; - shr_sum = stack_blur_tables::g_stack_blur8_shr[rx]; - stack.allocate(div); - - for(y = 0; y < h; y++) - { - sum_r = - sum_g = - sum_b = - sum_a = - sum_in_r = - sum_in_g = - sum_in_b = - sum_in_a = - sum_out_r = - sum_out_g = - sum_out_b = - sum_out_a = 0; - - src_pix_ptr = img.pix_ptr(0, y); - for(i = 0; i <= rx; i++) - { - stack_pix_ptr = &stack[i]; - stack_pix_ptr->r = src_pix_ptr[R]; - stack_pix_ptr->g = src_pix_ptr[G]; - stack_pix_ptr->b = src_pix_ptr[B]; - stack_pix_ptr->a = src_pix_ptr[A]; - sum_r += src_pix_ptr[R] * (i + 1); - sum_g += src_pix_ptr[G] * (i + 1); - sum_b += src_pix_ptr[B] * (i + 1); - sum_a += src_pix_ptr[A] * (i + 1); - sum_out_r += src_pix_ptr[R]; - sum_out_g += src_pix_ptr[G]; - sum_out_b += src_pix_ptr[B]; - sum_out_a += src_pix_ptr[A]; - } - for(i = 1; i <= rx; i++) - { - if(i <= wm) src_pix_ptr += Img::pix_width; - stack_pix_ptr = &stack[i + rx]; - stack_pix_ptr->r = src_pix_ptr[R]; - stack_pix_ptr->g = src_pix_ptr[G]; - stack_pix_ptr->b = src_pix_ptr[B]; - stack_pix_ptr->a = src_pix_ptr[A]; - sum_r += src_pix_ptr[R] * (rx + 1 - i); - sum_g += src_pix_ptr[G] * (rx + 1 - i); - sum_b += src_pix_ptr[B] * (rx + 1 - i); - sum_a += src_pix_ptr[A] * (rx + 1 - i); - sum_in_r += src_pix_ptr[R]; - sum_in_g += src_pix_ptr[G]; - sum_in_b += src_pix_ptr[B]; - sum_in_a += src_pix_ptr[A]; - } - - stack_ptr = rx; - xp = rx; - if(xp > wm) xp = wm; - src_pix_ptr = img.pix_ptr(xp, y); - dst_pix_ptr = img.pix_ptr(0, y); - for(x = 0; x < w; x++) - { - dst_pix_ptr[R] = (sum_r * mul_sum) >> shr_sum; - dst_pix_ptr[G] = (sum_g * mul_sum) >> shr_sum; - dst_pix_ptr[B] = (sum_b * mul_sum) >> shr_sum; - dst_pix_ptr[A] = (sum_a * mul_sum) >> shr_sum; - dst_pix_ptr += Img::pix_width; - - sum_r -= sum_out_r; - sum_g -= sum_out_g; - sum_b -= sum_out_b; - sum_a -= sum_out_a; - - stack_start = stack_ptr + div - rx; - if(stack_start >= div) stack_start -= div; - stack_pix_ptr = &stack[stack_start]; - - sum_out_r -= stack_pix_ptr->r; - sum_out_g -= stack_pix_ptr->g; - sum_out_b -= stack_pix_ptr->b; - sum_out_a -= stack_pix_ptr->a; - - if(xp < wm) - { - src_pix_ptr += Img::pix_width; - ++xp; - } - - stack_pix_ptr->r = src_pix_ptr[R]; - stack_pix_ptr->g = src_pix_ptr[G]; - stack_pix_ptr->b = src_pix_ptr[B]; - stack_pix_ptr->a = src_pix_ptr[A]; - - sum_in_r += src_pix_ptr[R]; - sum_in_g += src_pix_ptr[G]; - sum_in_b += src_pix_ptr[B]; - sum_in_a += src_pix_ptr[A]; - sum_r += sum_in_r; - sum_g += sum_in_g; - sum_b += sum_in_b; - sum_a += sum_in_a; - - ++stack_ptr; - if(stack_ptr >= div) stack_ptr = 0; - stack_pix_ptr = &stack[stack_ptr]; - - sum_out_r += stack_pix_ptr->r; - sum_out_g += stack_pix_ptr->g; - sum_out_b += stack_pix_ptr->b; - sum_out_a += stack_pix_ptr->a; - sum_in_r -= stack_pix_ptr->r; - sum_in_g -= stack_pix_ptr->g; - sum_in_b -= stack_pix_ptr->b; - sum_in_a -= stack_pix_ptr->a; - } - } - } - - if(ry > 0) - { - if(ry > 254) ry = 254; - div = ry * 2 + 1; - mul_sum = stack_blur_tables::g_stack_blur8_mul[ry]; - shr_sum = stack_blur_tables::g_stack_blur8_shr[ry]; - stack.allocate(div); - - int stride = img.stride(); - for(x = 0; x < w; x++) - { - sum_r = - sum_g = - sum_b = - sum_a = - sum_in_r = - sum_in_g = - sum_in_b = - sum_in_a = - sum_out_r = - sum_out_g = - sum_out_b = - sum_out_a = 0; - - src_pix_ptr = img.pix_ptr(x, 0); - for(i = 0; i <= ry; i++) - { - stack_pix_ptr = &stack[i]; - stack_pix_ptr->r = src_pix_ptr[R]; - stack_pix_ptr->g = src_pix_ptr[G]; - stack_pix_ptr->b = src_pix_ptr[B]; - stack_pix_ptr->a = src_pix_ptr[A]; - sum_r += src_pix_ptr[R] * (i + 1); - sum_g += src_pix_ptr[G] * (i + 1); - sum_b += src_pix_ptr[B] * (i + 1); - sum_a += src_pix_ptr[A] * (i + 1); - sum_out_r += src_pix_ptr[R]; - sum_out_g += src_pix_ptr[G]; - sum_out_b += src_pix_ptr[B]; - sum_out_a += src_pix_ptr[A]; - } - for(i = 1; i <= ry; i++) - { - if(i <= hm) src_pix_ptr += stride; - stack_pix_ptr = &stack[i + ry]; - stack_pix_ptr->r = src_pix_ptr[R]; - stack_pix_ptr->g = src_pix_ptr[G]; - stack_pix_ptr->b = src_pix_ptr[B]; - stack_pix_ptr->a = src_pix_ptr[A]; - sum_r += src_pix_ptr[R] * (ry + 1 - i); - sum_g += src_pix_ptr[G] * (ry + 1 - i); - sum_b += src_pix_ptr[B] * (ry + 1 - i); - sum_a += src_pix_ptr[A] * (ry + 1 - i); - sum_in_r += src_pix_ptr[R]; - sum_in_g += src_pix_ptr[G]; - sum_in_b += src_pix_ptr[B]; - sum_in_a += src_pix_ptr[A]; - } - - stack_ptr = ry; - yp = ry; - if(yp > hm) yp = hm; - src_pix_ptr = img.pix_ptr(x, yp); - dst_pix_ptr = img.pix_ptr(x, 0); - for(y = 0; y < h; y++) - { - dst_pix_ptr[R] = (sum_r * mul_sum) >> shr_sum; - dst_pix_ptr[G] = (sum_g * mul_sum) >> shr_sum; - dst_pix_ptr[B] = (sum_b * mul_sum) >> shr_sum; - dst_pix_ptr[A] = (sum_a * mul_sum) >> shr_sum; - dst_pix_ptr += stride; - - sum_r -= sum_out_r; - sum_g -= sum_out_g; - sum_b -= sum_out_b; - sum_a -= sum_out_a; - - stack_start = stack_ptr + div - ry; - if(stack_start >= div) stack_start -= div; - - stack_pix_ptr = &stack[stack_start]; - sum_out_r -= stack_pix_ptr->r; - sum_out_g -= stack_pix_ptr->g; - sum_out_b -= stack_pix_ptr->b; - sum_out_a -= stack_pix_ptr->a; - - if(yp < hm) - { - src_pix_ptr += stride; - ++yp; - } - - stack_pix_ptr->r = src_pix_ptr[R]; - stack_pix_ptr->g = src_pix_ptr[G]; - stack_pix_ptr->b = src_pix_ptr[B]; - stack_pix_ptr->a = src_pix_ptr[A]; - - sum_in_r += src_pix_ptr[R]; - sum_in_g += src_pix_ptr[G]; - sum_in_b += src_pix_ptr[B]; - sum_in_a += src_pix_ptr[A]; - sum_r += sum_in_r; - sum_g += sum_in_g; - sum_b += sum_in_b; - sum_a += sum_in_a; - - ++stack_ptr; - if(stack_ptr >= div) stack_ptr = 0; - stack_pix_ptr = &stack[stack_ptr]; - - sum_out_r += stack_pix_ptr->r; - sum_out_g += stack_pix_ptr->g; - sum_out_b += stack_pix_ptr->b; - sum_out_a += stack_pix_ptr->a; - sum_in_r -= stack_pix_ptr->r; - sum_in_g -= stack_pix_ptr->g; - sum_in_b -= stack_pix_ptr->b; - sum_in_a -= stack_pix_ptr->a; - } - } - } - } - - - - //===========================================================recursive_blur - template class recursive_blur - { - public: - typedef ColorT color_type; - typedef CalculatorT calculator_type; - typedef typename color_type::value_type value_type; - typedef typename calculator_type::value_type calc_type; - - //-------------------------------------------------------------------- - template void blur_x(Img& img, double radius) - { - if(radius < 0.62) return; - if(img.width() < 3) return; - - calc_type s = calc_type(radius * 0.5); - calc_type q = calc_type((s < 2.5) ? - 3.97156 - 4.14554 * sqrt(1 - 0.26891 * s) : - 0.98711 * s - 0.96330); - - calc_type q2 = calc_type(q * q); - calc_type q3 = calc_type(q2 * q); - - calc_type b0 = calc_type(1.0 / (1.578250 + - 2.444130 * q + - 1.428100 * q2 + - 0.422205 * q3)); - - calc_type b1 = calc_type( 2.44413 * q + - 2.85619 * q2 + - 1.26661 * q3); - - calc_type b2 = calc_type(-1.42810 * q2 + - -1.26661 * q3); - - calc_type b3 = calc_type(0.422205 * q3); - - calc_type b = calc_type(1 - (b1 + b2 + b3) * b0); - - b1 *= b0; - b2 *= b0; - b3 *= b0; - - int w = img.width(); - int h = img.height(); - int wm = w-1; - int x, y; - - m_sum1.allocate(w); - m_sum2.allocate(w); - m_buf.allocate(w); - - for(y = 0; y < h; y++) - { - calculator_type c; - c.from_pix(img.pixel(0, y)); - m_sum1[0].calc(b, b1, b2, b3, c, c, c, c); - c.from_pix(img.pixel(1, y)); - m_sum1[1].calc(b, b1, b2, b3, c, m_sum1[0], m_sum1[0], m_sum1[0]); - c.from_pix(img.pixel(2, y)); - m_sum1[2].calc(b, b1, b2, b3, c, m_sum1[1], m_sum1[0], m_sum1[0]); - - for(x = 3; x < w; ++x) - { - c.from_pix(img.pixel(x, y)); - m_sum1[x].calc(b, b1, b2, b3, c, m_sum1[x-1], m_sum1[x-2], m_sum1[x-3]); - } - - m_sum2[wm ].calc(b, b1, b2, b3, m_sum1[wm ], m_sum1[wm ], m_sum1[wm], m_sum1[wm]); - m_sum2[wm-1].calc(b, b1, b2, b3, m_sum1[wm-1], m_sum2[wm ], m_sum2[wm], m_sum2[wm]); - m_sum2[wm-2].calc(b, b1, b2, b3, m_sum1[wm-2], m_sum2[wm-1], m_sum2[wm], m_sum2[wm]); - m_sum2[wm ].to_pix(m_buf[wm ]); - m_sum2[wm-1].to_pix(m_buf[wm-1]); - m_sum2[wm-2].to_pix(m_buf[wm-2]); - - for(x = wm-3; x >= 0; --x) - { - m_sum2[x].calc(b, b1, b2, b3, m_sum1[x], m_sum2[x+1], m_sum2[x+2], m_sum2[x+3]); - m_sum2[x].to_pix(m_buf[x]); - } - img.copy_color_hspan(0, y, w, &m_buf[0]); - } - } - - //-------------------------------------------------------------------- - template void blur_y(Img& img, double radius) - { - pixfmt_transposer img2(img); - blur_x(img2, radius); - } - - //-------------------------------------------------------------------- - template void blur(Img& img, double radius) - { - blur_x(img, radius); - pixfmt_transposer img2(img); - blur_x(img2, radius); - } - - private: - agg::pod_vector m_sum1; - agg::pod_vector m_sum2; - agg::pod_vector m_buf; - }; - - - //=================================================recursive_blur_calc_rgba - template struct recursive_blur_calc_rgba - { - typedef T value_type; - typedef recursive_blur_calc_rgba self_type; - - value_type r,g,b,a; - - template - AGG_INLINE void from_pix(const ColorT& c) - { - r = c.r; - g = c.g; - b = c.b; - a = c.a; - } - - AGG_INLINE void calc(value_type b1, - value_type b2, - value_type b3, - value_type b4, - const self_type& c1, - const self_type& c2, - const self_type& c3, - const self_type& c4) - { - r = b1*c1.r + b2*c2.r + b3*c3.r + b4*c4.r; - g = b1*c1.g + b2*c2.g + b3*c3.g + b4*c4.g; - b = b1*c1.b + b2*c2.b + b3*c3.b + b4*c4.b; - a = b1*c1.a + b2*c2.a + b3*c3.a + b4*c4.a; - } - - template - AGG_INLINE void to_pix(ColorT& c) const - { - typedef typename ColorT::value_type cv_type; - c.r = (cv_type)uround(r); - c.g = (cv_type)uround(g); - c.b = (cv_type)uround(b); - c.a = (cv_type)uround(a); - } - }; - - - //=================================================recursive_blur_calc_rgb - template struct recursive_blur_calc_rgb - { - typedef T value_type; - typedef recursive_blur_calc_rgb self_type; - - value_type r,g,b; - - template - AGG_INLINE void from_pix(const ColorT& c) - { - r = c.r; - g = c.g; - b = c.b; - } - - AGG_INLINE void calc(value_type b1, - value_type b2, - value_type b3, - value_type b4, - const self_type& c1, - const self_type& c2, - const self_type& c3, - const self_type& c4) - { - r = b1*c1.r + b2*c2.r + b3*c3.r + b4*c4.r; - g = b1*c1.g + b2*c2.g + b3*c3.g + b4*c4.g; - b = b1*c1.b + b2*c2.b + b3*c3.b + b4*c4.b; - } - - template - AGG_INLINE void to_pix(ColorT& c) const - { - typedef typename ColorT::value_type cv_type; - c.r = (cv_type)uround(r); - c.g = (cv_type)uround(g); - c.b = (cv_type)uround(b); - } - }; - - - //================================================recursive_blur_calc_gray - template struct recursive_blur_calc_gray - { - typedef T value_type; - typedef recursive_blur_calc_gray self_type; - - value_type v; - - template - AGG_INLINE void from_pix(const ColorT& c) - { - v = c.v; - } - - AGG_INLINE void calc(value_type b1, - value_type b2, - value_type b3, - value_type b4, - const self_type& c1, - const self_type& c2, - const self_type& c3, - const self_type& c4) - { - v = b1*c1.v + b2*c2.v + b3*c3.v + b4*c4.v; - } - - template - AGG_INLINE void to_pix(ColorT& c) const - { - typedef typename ColorT::value_type cv_type; - c.v = (cv_type)uround(v); - } - }; - -} - - - - -#endif diff --git a/desmume/src/windows/agg/include/agg_bounding_rect.h b/desmume/src/windows/agg/include/agg_bounding_rect.h deleted file mode 100644 index eb869eb6d..000000000 --- a/desmume/src/windows/agg/include/agg_bounding_rect.h +++ /dev/null @@ -1,122 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_BOUNDING_RECT_INCLUDED -#define AGG_BOUNDING_RECT_INCLUDED - -#include "agg_basics.h" - -namespace agg -{ - - //-----------------------------------------------------------bounding_rect - template - bool bounding_rect(VertexSource& vs, GetId& gi, - unsigned start, unsigned num, - CoordT* x1, CoordT* y1, CoordT* x2, CoordT* y2) - { - unsigned i; - double x; - double y; - bool first = true; - - *x1 = CoordT(1); - *y1 = CoordT(1); - *x2 = CoordT(0); - *y2 = CoordT(0); - - for(i = 0; i < num; i++) - { - vs.rewind(gi[start + i]); - unsigned cmd; - while(!is_stop(cmd = vs.vertex(&x, &y))) - { - if(is_vertex(cmd)) - { - if(first) - { - *x1 = CoordT(x); - *y1 = CoordT(y); - *x2 = CoordT(x); - *y2 = CoordT(y); - first = false; - } - else - { - if(CoordT(x) < *x1) *x1 = CoordT(x); - if(CoordT(y) < *y1) *y1 = CoordT(y); - if(CoordT(x) > *x2) *x2 = CoordT(x); - if(CoordT(y) > *y2) *y2 = CoordT(y); - } - } - } - } - return *x1 <= *x2 && *y1 <= *y2; - } - - - //-----------------------------------------------------bounding_rect_single - template - bool bounding_rect_single(VertexSource& vs, unsigned path_id, - CoordT* x1, CoordT* y1, CoordT* x2, CoordT* y2) - { - double x; - double y; - bool first = true; - - *x1 = CoordT(1); - *y1 = CoordT(1); - *x2 = CoordT(0); - *y2 = CoordT(0); - - vs.rewind(path_id); - unsigned cmd; - while(!is_stop(cmd = vs.vertex(&x, &y))) - { - if(is_vertex(cmd)) - { - if(first) - { - *x1 = CoordT(x); - *y1 = CoordT(y); - *x2 = CoordT(x); - *y2 = CoordT(y); - first = false; - } - else - { - if(CoordT(x) < *x1) *x1 = CoordT(x); - if(CoordT(y) < *y1) *y1 = CoordT(y); - if(CoordT(x) > *x2) *x2 = CoordT(x); - if(CoordT(y) > *y2) *y2 = CoordT(y); - } - } - } - return *x1 <= *x2 && *y1 <= *y2; - } - - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_bspline.h b/desmume/src/windows/agg/include/agg_bspline.h deleted file mode 100644 index ff8eda4fc..000000000 --- a/desmume/src/windows/agg/include/agg_bspline.h +++ /dev/null @@ -1,81 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_BSPLINE_INCLUDED -#define AGG_BSPLINE_INCLUDED - -#include "agg_array.h" - -namespace agg -{ - //----------------------------------------------------------------bspline - // A very simple class of Bi-cubic Spline interpolation. - // First call init(num, x[], y[]) where num - number of source points, - // x, y - arrays of X and Y values respectively. Here Y must be a function - // of X. It means that all the X-coordinates must be arranged in the ascending - // order. - // Then call get(x) that calculates a value Y for the respective X. - // The class supports extrapolation, i.e. you can call get(x) where x is - // outside the given with init() X-range. Extrapolation is a simple linear - // function. - // - // See Implementation agg_bspline.cpp - //------------------------------------------------------------------------ - class bspline - { - public: - bspline(); - bspline(int num); - bspline(int num, const double* x, const double* y); - - void init(int num); - void add_point(double x, double y); - void prepare(); - - void init(int num, const double* x, const double* y); - - double get(double x) const; - double get_stateful(double x) const; - - private: - bspline(const bspline&); - const bspline& operator = (const bspline&); - - static void bsearch(int n, const double *x, double x0, int *i); - double extrapolation_left(double x) const; - double extrapolation_right(double x) const; - double interpolation(double x, int i) const; - - int m_max; - int m_num; - double* m_x; - double* m_y; - pod_array m_am; - mutable int m_last_idx; - }; - - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_clip_liang_barsky.h b/desmume/src/windows/agg/include/agg_clip_liang_barsky.h deleted file mode 100644 index a612ddf1f..000000000 --- a/desmume/src/windows/agg/include/agg_clip_liang_barsky.h +++ /dev/null @@ -1,339 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_CLIP_LIANG_BARSKY_INCLUDED -#define AGG_CLIP_LIANG_BARSKY_INCLUDED - -#include "agg_basics.h" - -namespace agg -{ - - //------------------------------------------------------------------------ - enum clipping_flags_e - { - clipping_flags_x1_clipped = 4, - clipping_flags_x2_clipped = 1, - clipping_flags_y1_clipped = 8, - clipping_flags_y2_clipped = 2, - clipping_flags_x_clipped = clipping_flags_x1_clipped | clipping_flags_x2_clipped, - clipping_flags_y_clipped = clipping_flags_y1_clipped | clipping_flags_y2_clipped - }; - - //----------------------------------------------------------clipping_flags - // Determine the clipping code of the vertex according to the - // Cyrus-Beck line clipping algorithm - // - // | | - // 0110 | 0010 | 0011 - // | | - // -------+--------+-------- clip_box.y2 - // | | - // 0100 | 0000 | 0001 - // | | - // -------+--------+-------- clip_box.y1 - // | | - // 1100 | 1000 | 1001 - // | | - // clip_box.x1 clip_box.x2 - // - // - template - inline unsigned clipping_flags(T x, T y, const rect_base& clip_box) - { - return (x > clip_box.x2) | - ((y > clip_box.y2) << 1) | - ((x < clip_box.x1) << 2) | - ((y < clip_box.y1) << 3); - } - - //--------------------------------------------------------clipping_flags_x - template - inline unsigned clipping_flags_x(T x, const rect_base& clip_box) - { - return (x > clip_box.x2) | ((x < clip_box.x1) << 2); - } - - - //--------------------------------------------------------clipping_flags_y - template - inline unsigned clipping_flags_y(T y, const rect_base& clip_box) - { - return ((y > clip_box.y2) << 1) | ((y < clip_box.y1) << 3); - } - - - //-------------------------------------------------------clip_liang_barsky - template - inline unsigned clip_liang_barsky(T x1, T y1, T x2, T y2, - const rect_base& clip_box, - T* x, T* y) - { - const double nearzero = 1e-30; - - double deltax = x2 - x1; - double deltay = y2 - y1; - double xin; - double xout; - double yin; - double yout; - double tinx; - double tiny; - double toutx; - double touty; - double tin1; - double tin2; - double tout1; - unsigned np = 0; - - if(deltax == 0.0) - { - // bump off of the vertical - deltax = (x1 > clip_box.x1) ? -nearzero : nearzero; - } - - if(deltay == 0.0) - { - // bump off of the horizontal - deltay = (y1 > clip_box.y1) ? -nearzero : nearzero; - } - - if(deltax > 0.0) - { - // points to right - xin = clip_box.x1; - xout = clip_box.x2; - } - else - { - xin = clip_box.x2; - xout = clip_box.x1; - } - - if(deltay > 0.0) - { - // points up - yin = clip_box.y1; - yout = clip_box.y2; - } - else - { - yin = clip_box.y2; - yout = clip_box.y1; - } - - tinx = (xin - x1) / deltax; - tiny = (yin - y1) / deltay; - - if (tinx < tiny) - { - // hits x first - tin1 = tinx; - tin2 = tiny; - } - else - { - // hits y first - tin1 = tiny; - tin2 = tinx; - } - - if(tin1 <= 1.0) - { - if(0.0 < tin1) - { - *x++ = (T)xin; - *y++ = (T)yin; - ++np; - } - - if(tin2 <= 1.0) - { - toutx = (xout - x1) / deltax; - touty = (yout - y1) / deltay; - - tout1 = (toutx < touty) ? toutx : touty; - - if(tin2 > 0.0 || tout1 > 0.0) - { - if(tin2 <= tout1) - { - if(tin2 > 0.0) - { - if(tinx > tiny) - { - *x++ = (T)xin; - *y++ = (T)(y1 + tinx * deltay); - } - else - { - *x++ = (T)(x1 + tiny * deltax); - *y++ = (T)yin; - } - ++np; - } - - if(tout1 < 1.0) - { - if(toutx < touty) - { - *x++ = (T)xout; - *y++ = (T)(y1 + toutx * deltay); - } - else - { - *x++ = (T)(x1 + touty * deltax); - *y++ = (T)yout; - } - } - else - { - *x++ = x2; - *y++ = y2; - } - ++np; - } - else - { - if(tinx > tiny) - { - *x++ = (T)xin; - *y++ = (T)yout; - } - else - { - *x++ = (T)xout; - *y++ = (T)yin; - } - ++np; - } - } - } - } - return np; - } - - - //---------------------------------------------------------------------------- - template - bool clip_move_point(T x1, T y1, T x2, T y2, - const rect_base& clip_box, - T* x, T* y, unsigned flags) - { - T bound; - - if(flags & clipping_flags_x_clipped) - { - if(x1 == x2) - { - return false; - } - bound = (flags & clipping_flags_x1_clipped) ? clip_box.x1 : clip_box.x2; - *y = (T)(double(bound - x1) * (y2 - y1) / (x2 - x1) + y1); - *x = bound; - } - - flags = clipping_flags_y(*y, clip_box); - if(flags & clipping_flags_y_clipped) - { - if(y1 == y2) - { - return false; - } - bound = (flags & clipping_flags_y1_clipped) ? clip_box.y1 : clip_box.y2; - *x = (T)(double(bound - y1) * (x2 - x1) / (y2 - y1) + x1); - *y = bound; - } - return true; - } - - //-------------------------------------------------------clip_line_segment - // Returns: ret >= 4 - Fully clipped - // (ret & 1) != 0 - First point has been moved - // (ret & 2) != 0 - Second point has been moved - // - template - unsigned clip_line_segment(T* x1, T* y1, T* x2, T* y2, - const rect_base& clip_box) - { - unsigned f1 = clipping_flags(*x1, *y1, clip_box); - unsigned f2 = clipping_flags(*x2, *y2, clip_box); - unsigned ret = 0; - - if((f2 | f1) == 0) - { - // Fully visible - return 0; - } - - if((f1 & clipping_flags_x_clipped) != 0 && - (f1 & clipping_flags_x_clipped) == (f2 & clipping_flags_x_clipped)) - { - // Fully clipped - return 4; - } - - if((f1 & clipping_flags_y_clipped) != 0 && - (f1 & clipping_flags_y_clipped) == (f2 & clipping_flags_y_clipped)) - { - // Fully clipped - return 4; - } - - T tx1 = *x1; - T ty1 = *y1; - T tx2 = *x2; - T ty2 = *y2; - if(f1) - { - if(!clip_move_point(tx1, ty1, tx2, ty2, clip_box, x1, y1, f1)) - { - return 4; - } - if(*x1 == *x2 && *y1 == *y2) - { - return 4; - } - ret |= 1; - } - if(f2) - { - if(!clip_move_point(tx1, ty1, tx2, ty2, clip_box, x2, y2, f2)) - { - return 4; - } - if(*x1 == *x2 && *y1 == *y2) - { - return 4; - } - ret |= 2; - } - return ret; - } - - -} - - -#endif diff --git a/desmume/src/windows/agg/include/agg_color_gray.h b/desmume/src/windows/agg/include/agg_color_gray.h deleted file mode 100644 index 74ed66e1d..000000000 --- a/desmume/src/windows/agg/include/agg_color_gray.h +++ /dev/null @@ -1,423 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- -// -// Adaptation for high precision colors has been sponsored by -// Liberty Technology Systems, Inc., visit http://lib-sys.com -// -// Liberty Technology Systems, Inc. is the provider of -// PostScript and PDF technology for software developers. -// -//---------------------------------------------------------------------------- -// -// color types gray8, gray16 -// -//---------------------------------------------------------------------------- - -#ifndef AGG_COLOR_GRAY_INCLUDED -#define AGG_COLOR_GRAY_INCLUDED - -#include "agg_basics.h" -#include "agg_color_rgba.h" - -namespace agg -{ - - //===================================================================gray8 - struct gray8 - { - typedef int8u value_type; - typedef int32u calc_type; - typedef int32 long_type; - enum base_scale_e - { - base_shift = 8, - base_scale = 1 << base_shift, - base_mask = base_scale - 1 - }; - typedef gray8 self_type; - - value_type v; - value_type a; - - //-------------------------------------------------------------------- - gray8() {} - - //-------------------------------------------------------------------- - gray8(unsigned v_, unsigned a_=base_mask) : - v(int8u(v_)), a(int8u(a_)) {} - - //-------------------------------------------------------------------- - gray8(const self_type& c, unsigned a_) : - v(c.v), a(value_type(a_)) {} - - //-------------------------------------------------------------------- - gray8(const rgba& c) : - v((value_type)uround((0.299*c.r + 0.587*c.g + 0.114*c.b) * double(base_mask))), - a((value_type)uround(c.a * double(base_mask))) {} - - //-------------------------------------------------------------------- - gray8(const rgba& c, double a_) : - v((value_type)uround((0.299*c.r + 0.587*c.g + 0.114*c.b) * double(base_mask))), - a((value_type)uround(a_ * double(base_mask))) {} - - //-------------------------------------------------------------------- - gray8(const rgba8& c) : - v((c.r*77 + c.g*150 + c.b*29) >> 8), - a(c.a) {} - - //-------------------------------------------------------------------- - gray8(const rgba8& c, unsigned a_) : - v((c.r*77 + c.g*150 + c.b*29) >> 8), - a(a_) {} - - //-------------------------------------------------------------------- - void clear() - { - v = a = 0; - } - - //-------------------------------------------------------------------- - const self_type& transparent() - { - a = 0; - return *this; - } - - //-------------------------------------------------------------------- - void opacity(double a_) - { - if(a_ < 0.0) a_ = 0.0; - if(a_ > 1.0) a_ = 1.0; - a = (value_type)uround(a_ * double(base_mask)); - } - - //-------------------------------------------------------------------- - double opacity() const - { - return double(a) / double(base_mask); - } - - - //-------------------------------------------------------------------- - const self_type& premultiply() - { - if(a == base_mask) return *this; - if(a == 0) - { - v = 0; - return *this; - } - v = value_type((calc_type(v) * a) >> base_shift); - return *this; - } - - //-------------------------------------------------------------------- - const self_type& premultiply(unsigned a_) - { - if(a == base_mask && a_ >= base_mask) return *this; - if(a == 0 || a_ == 0) - { - v = a = 0; - return *this; - } - calc_type v_ = (calc_type(v) * a_) / a; - v = value_type((v_ > a_) ? a_ : v_); - a = value_type(a_); - return *this; - } - - //-------------------------------------------------------------------- - const self_type& demultiply() - { - if(a == base_mask) return *this; - if(a == 0) - { - v = 0; - return *this; - } - calc_type v_ = (calc_type(v) * base_mask) / a; - v = value_type((v_ > base_mask) ? (value_type)base_mask : v_); - return *this; - } - - //-------------------------------------------------------------------- - self_type gradient(self_type c, double k) const - { - self_type ret; - calc_type ik = uround(k * base_scale); - ret.v = value_type(calc_type(v) + (((calc_type(c.v) - v) * ik) >> base_shift)); - ret.a = value_type(calc_type(a) + (((calc_type(c.a) - a) * ik) >> base_shift)); - return ret; - } - - //-------------------------------------------------------------------- - AGG_INLINE void add(const self_type& c, unsigned cover) - { - calc_type cv, ca; - if(cover == cover_mask) - { - if(c.a == base_mask) - { - *this = c; - } - else - { - cv = v + c.v; v = (cv > calc_type(base_mask)) ? calc_type(base_mask) : cv; - ca = a + c.a; a = (ca > calc_type(base_mask)) ? calc_type(base_mask) : ca; - } - } - else - { - cv = v + ((c.v * cover + cover_mask/2) >> cover_shift); - ca = a + ((c.a * cover + cover_mask/2) >> cover_shift); - v = (cv > calc_type(base_mask)) ? calc_type(base_mask) : cv; - a = (ca > calc_type(base_mask)) ? calc_type(base_mask) : ca; - } - } - - //-------------------------------------------------------------------- - static self_type no_color() { return self_type(0,0); } - }; - - - //-------------------------------------------------------------gray8_pre - inline gray8 gray8_pre(unsigned v, unsigned a = gray8::base_mask) - { - return gray8(v,a).premultiply(); - } - inline gray8 gray8_pre(const gray8& c, unsigned a) - { - return gray8(c,a).premultiply(); - } - inline gray8 gray8_pre(const rgba& c) - { - return gray8(c).premultiply(); - } - inline gray8 gray8_pre(const rgba& c, double a) - { - return gray8(c,a).premultiply(); - } - inline gray8 gray8_pre(const rgba8& c) - { - return gray8(c).premultiply(); - } - inline gray8 gray8_pre(const rgba8& c, unsigned a) - { - return gray8(c,a).premultiply(); - } - - - - - //==================================================================gray16 - struct gray16 - { - typedef int16u value_type; - typedef int32u calc_type; - typedef int64 long_type; - enum base_scale_e - { - base_shift = 16, - base_scale = 1 << base_shift, - base_mask = base_scale - 1 - }; - typedef gray16 self_type; - - value_type v; - value_type a; - - //-------------------------------------------------------------------- - gray16() {} - - //-------------------------------------------------------------------- - gray16(unsigned v_, unsigned a_=base_mask) : - v(int16u(v_)), a(int16u(a_)) {} - - //-------------------------------------------------------------------- - gray16(const self_type& c, unsigned a_) : - v(c.v), a(value_type(a_)) {} - - //-------------------------------------------------------------------- - gray16(const rgba& c) : - v((value_type)uround((0.299*c.r + 0.587*c.g + 0.114*c.b) * double(base_mask))), - a((value_type)uround(c.a * double(base_mask))) {} - - //-------------------------------------------------------------------- - gray16(const rgba& c, double a_) : - v((value_type)uround((0.299*c.r + 0.587*c.g + 0.114*c.b) * double(base_mask))), - a((value_type)uround(a_ * double(base_mask))) {} - - //-------------------------------------------------------------------- - gray16(const rgba8& c) : - v(c.r*77 + c.g*150 + c.b*29), - a((value_type(c.a) << 8) | c.a) {} - - //-------------------------------------------------------------------- - gray16(const rgba8& c, unsigned a_) : - v(c.r*77 + c.g*150 + c.b*29), - a((value_type(a_) << 8) | c.a) {} - - //-------------------------------------------------------------------- - void clear() - { - v = a = 0; - } - - //-------------------------------------------------------------------- - const self_type& transparent() - { - a = 0; - return *this; - } - - //-------------------------------------------------------------------- - void opacity(double a_) - { - if(a_ < 0.0) a_ = 0.0; - if(a_ > 1.0) a_ = 1.0; - a = (value_type)uround(a_ * double(base_mask)); - } - - //-------------------------------------------------------------------- - double opacity() const - { - return double(a) / double(base_mask); - } - - - //-------------------------------------------------------------------- - const self_type& premultiply() - { - if(a == base_mask) return *this; - if(a == 0) - { - v = 0; - return *this; - } - v = value_type((calc_type(v) * a) >> base_shift); - return *this; - } - - //-------------------------------------------------------------------- - const self_type& premultiply(unsigned a_) - { - if(a == base_mask && a_ >= base_mask) return *this; - if(a == 0 || a_ == 0) - { - v = a = 0; - return *this; - } - calc_type v_ = (calc_type(v) * a_) / a; - v = value_type((v_ > a_) ? a_ : v_); - a = value_type(a_); - return *this; - } - - //-------------------------------------------------------------------- - const self_type& demultiply() - { - if(a == base_mask) return *this; - if(a == 0) - { - v = 0; - return *this; - } - calc_type v_ = (calc_type(v) * base_mask) / a; - v = value_type((v_ > base_mask) ? base_mask : v_); - return *this; - } - - //-------------------------------------------------------------------- - self_type gradient(self_type c, double k) const - { - self_type ret; - calc_type ik = uround(k * base_scale); - ret.v = value_type(calc_type(v) + (((calc_type(c.v) - v) * ik) >> base_shift)); - ret.a = value_type(calc_type(a) + (((calc_type(c.a) - a) * ik) >> base_shift)); - return ret; - } - - //-------------------------------------------------------------------- - AGG_INLINE void add(const self_type& c, unsigned cover) - { - calc_type cv, ca; - if(cover == cover_mask) - { - if(c.a == base_mask) - { - *this = c; - } - else - { - cv = v + c.v; v = (cv > calc_type(base_mask)) ? calc_type(base_mask) : cv; - ca = a + c.a; a = (ca > calc_type(base_mask)) ? calc_type(base_mask) : ca; - } - } - else - { - cv = v + ((c.v * cover + cover_mask/2) >> cover_shift); - ca = a + ((c.a * cover + cover_mask/2) >> cover_shift); - v = (cv > calc_type(base_mask)) ? calc_type(base_mask) : cv; - a = (ca > calc_type(base_mask)) ? calc_type(base_mask) : ca; - } - } - - //-------------------------------------------------------------------- - static self_type no_color() { return self_type(0,0); } - }; - - - //------------------------------------------------------------gray16_pre - inline gray16 gray16_pre(unsigned v, unsigned a = gray16::base_mask) - { - return gray16(v,a).premultiply(); - } - inline gray16 gray16_pre(const gray16& c, unsigned a) - { - return gray16(c,a).premultiply(); - } - inline gray16 gray16_pre(const rgba& c) - { - return gray16(c).premultiply(); - } - inline gray16 gray16_pre(const rgba& c, double a) - { - return gray16(c,a).premultiply(); - } - inline gray16 gray16_pre(const rgba8& c) - { - return gray16(c).premultiply(); - } - inline gray16 gray16_pre(const rgba8& c, unsigned a) - { - return gray16(c,a).premultiply(); - } - - -} - - - - -#endif diff --git a/desmume/src/windows/agg/include/agg_color_rgba.h b/desmume/src/windows/agg/include/agg_color_rgba.h deleted file mode 100644 index 7cc25b5f0..000000000 --- a/desmume/src/windows/agg/include/agg_color_rgba.h +++ /dev/null @@ -1,756 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- -// -// Adaptation for high precision colors has been sponsored by -// Liberty Technology Systems, Inc., visit http://lib-sys.com -// -// Liberty Technology Systems, Inc. is the provider of -// PostScript and PDF technology for software developers. -// -//---------------------------------------------------------------------------- -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://www.antigrain.com -//---------------------------------------------------------------------------- - -#ifndef AGG_COLOR_RGBA_INCLUDED -#define AGG_COLOR_RGBA_INCLUDED - -#include -#include "agg_basics.h" - -namespace agg -{ - // Supported byte orders for RGB and RGBA pixel formats - //======================================================================= - struct order_rgb { enum rgb_e { R=0, G=1, B=2, rgb_tag }; }; //----order_rgb - struct order_bgr { enum bgr_e { B=0, G=1, R=2, rgb_tag }; }; //----order_bgr - struct order_rgba { enum rgba_e { R=0, G=1, B=2, A=3, rgba_tag }; }; //----order_rgba - struct order_argb { enum argb_e { A=0, R=1, G=2, B=3, rgba_tag }; }; //----order_argb - struct order_abgr { enum abgr_e { A=0, B=1, G=2, R=3, rgba_tag }; }; //----order_abgr - struct order_bgra { enum bgra_e { B=0, G=1, R=2, A=3, rgba_tag }; }; //----order_bgra - - //====================================================================rgba - struct rgba - { - typedef double value_type; - - double r; - double g; - double b; - double a; - - //-------------------------------------------------------------------- - rgba() {} - - //-------------------------------------------------------------------- - rgba(double r_, double g_, double b_, double a_=1.0) : - r(r_), g(g_), b(b_), a(a_) {} - - //-------------------------------------------------------------------- - rgba(const rgba& c, double a_) : r(c.r), g(c.g), b(c.b), a(a_) {} - - //-------------------------------------------------------------------- - void clear() - { - r = g = b = a = 0; - } - - //-------------------------------------------------------------------- - const rgba& transparent() - { - a = 0.0; - return *this; - } - - //-------------------------------------------------------------------- - const rgba& opacity(double a_) - { - if(a_ < 0.0) a_ = 0.0; - if(a_ > 1.0) a_ = 1.0; - a = a_; - return *this; - } - - //-------------------------------------------------------------------- - double opacity() const - { - return a; - } - - //-------------------------------------------------------------------- - const rgba& premultiply() - { - r *= a; - g *= a; - b *= a; - return *this; - } - - //-------------------------------------------------------------------- - const rgba& premultiply(double a_) - { - if(a <= 0.0 || a_ <= 0.0) - { - r = g = b = a = 0.0; - return *this; - } - a_ /= a; - r *= a_; - g *= a_; - b *= a_; - a = a_; - return *this; - } - - //-------------------------------------------------------------------- - const rgba& demultiply() - { - if(a == 0) - { - r = g = b = 0; - return *this; - } - double a_ = 1.0 / a; - r *= a_; - g *= a_; - b *= a_; - return *this; - } - - - //-------------------------------------------------------------------- - rgba gradient(rgba c, double k) const - { - rgba ret; - ret.r = r + (c.r - r) * k; - ret.g = g + (c.g - g) * k; - ret.b = b + (c.b - b) * k; - ret.a = a + (c.a - a) * k; - return ret; - } - - //-------------------------------------------------------------------- - static rgba no_color() { return rgba(0,0,0,0); } - - //-------------------------------------------------------------------- - static rgba from_wavelength(double wl, double gamma = 1.0); - - //-------------------------------------------------------------------- - explicit rgba(double wavelen, double gamma=1.0) - { - *this = from_wavelength(wavelen, gamma); - } - - }; - - //----------------------------------------------------------------rgba_pre - inline rgba rgba_pre(double r, double g, double b, double a=1.0) - { - return rgba(r, g, b, a).premultiply(); - } - inline rgba rgba_pre(const rgba& c) - { - return rgba(c).premultiply(); - } - inline rgba rgba_pre(const rgba& c, double a) - { - return rgba(c, a).premultiply(); - } - - //------------------------------------------------------------------------ - inline rgba rgba::from_wavelength(double wl, double gamma) - { - rgba t(0.0, 0.0, 0.0); - - if(wl >= 380.0 && wl <= 440.0) - { - t.r = -1.0 * (wl - 440.0) / (440.0 - 380.0); - t.b = 1.0; - } - else - if(wl >= 440.0 && wl <= 490.0) - { - t.g = (wl - 440.0) / (490.0 - 440.0); - t.b = 1.0; - } - else - if(wl >= 490.0 && wl <= 510.0) - { - t.g = 1.0; - t.b = -1.0 * (wl - 510.0) / (510.0 - 490.0); - } - else - if(wl >= 510.0 && wl <= 580.0) - { - t.r = (wl - 510.0) / (580.0 - 510.0); - t.g = 1.0; - } - else - if(wl >= 580.0 && wl <= 645.0) - { - t.r = 1.0; - t.g = -1.0 * (wl - 645.0) / (645.0 - 580.0); - } - else - if(wl >= 645.0 && wl <= 780.0) - { - t.r = 1.0; - } - - double s = 1.0; - if(wl > 700.0) s = 0.3 + 0.7 * (780.0 - wl) / (780.0 - 700.0); - else if(wl < 420.0) s = 0.3 + 0.7 * (wl - 380.0) / (420.0 - 380.0); - - t.r = pow(t.r * s, gamma); - t.g = pow(t.g * s, gamma); - t.b = pow(t.b * s, gamma); - return t; - } - - - - - //===================================================================rgba8 - struct rgba8 - { - typedef int8u value_type; - typedef int32u calc_type; - typedef int32 long_type; - enum base_scale_e - { - base_shift = 8, - base_scale = 1 << base_shift, - base_mask = base_scale - 1 - }; - typedef rgba8 self_type; - - - value_type r; - value_type g; - value_type b; - value_type a; - - //-------------------------------------------------------------------- - rgba8() {} - - //-------------------------------------------------------------------- - rgba8(unsigned r_, unsigned g_, unsigned b_, unsigned a_=base_mask) : - r(value_type(r_)), - g(value_type(g_)), - b(value_type(b_)), - a(value_type(a_)) {} - - //-------------------------------------------------------------------- - rgba8(const rgba& c, double a_) : - r((value_type)uround(c.r * double(base_mask))), - g((value_type)uround(c.g * double(base_mask))), - b((value_type)uround(c.b * double(base_mask))), - a((value_type)uround(a_ * double(base_mask))) {} - - //-------------------------------------------------------------------- - rgba8(const self_type& c, unsigned a_) : - r(c.r), g(c.g), b(c.b), a(value_type(a_)) {} - - //-------------------------------------------------------------------- - rgba8(const rgba& c) : - r((value_type)uround(c.r * double(base_mask))), - g((value_type)uround(c.g * double(base_mask))), - b((value_type)uround(c.b * double(base_mask))), - a((value_type)uround(c.a * double(base_mask))) {} - - //-------------------------------------------------------------------- - void clear() - { - r = g = b = a = 0; - } - - //-------------------------------------------------------------------- - const self_type& transparent() - { - a = 0; - return *this; - } - - //-------------------------------------------------------------------- - const self_type& opacity(double a_) - { - if(a_ < 0.0) a_ = 0.0; - if(a_ > 1.0) a_ = 1.0; - a = (value_type)uround(a_ * double(base_mask)); - return *this; - } - - //-------------------------------------------------------------------- - double opacity() const - { - return double(a) / double(base_mask); - } - - //-------------------------------------------------------------------- - AGG_INLINE const self_type& premultiply() - { - if(a == base_mask) return *this; - if(a == 0) - { - r = g = b = 0; - return *this; - } - r = value_type((calc_type(r) * a) >> base_shift); - g = value_type((calc_type(g) * a) >> base_shift); - b = value_type((calc_type(b) * a) >> base_shift); - return *this; - } - - //-------------------------------------------------------------------- - AGG_INLINE const self_type& premultiply(unsigned a_) - { - if(a == base_mask && a_ >= base_mask) return *this; - if(a == 0 || a_ == 0) - { - r = g = b = a = 0; - return *this; - } - calc_type r_ = (calc_type(r) * a_) / a; - calc_type g_ = (calc_type(g) * a_) / a; - calc_type b_ = (calc_type(b) * a_) / a; - r = value_type((r_ > a_) ? a_ : r_); - g = value_type((g_ > a_) ? a_ : g_); - b = value_type((b_ > a_) ? a_ : b_); - a = value_type(a_); - return *this; - } - - //-------------------------------------------------------------------- - AGG_INLINE const self_type& demultiply() - { - if(a == base_mask) return *this; - if(a == 0) - { - r = g = b = 0; - return *this; - } - calc_type r_ = (calc_type(r) * base_mask) / a; - calc_type g_ = (calc_type(g) * base_mask) / a; - calc_type b_ = (calc_type(b) * base_mask) / a; - r = value_type((r_ > calc_type(base_mask)) ? calc_type(base_mask) : r_); - g = value_type((g_ > calc_type(base_mask)) ? calc_type(base_mask) : g_); - b = value_type((b_ > calc_type(base_mask)) ? calc_type(base_mask) : b_); - return *this; - } - - //-------------------------------------------------------------------- - AGG_INLINE self_type gradient(const self_type& c, double k) const - { - self_type ret; - calc_type ik = uround(k * base_scale); - ret.r = value_type(calc_type(r) + (((calc_type(c.r) - r) * ik) >> base_shift)); - ret.g = value_type(calc_type(g) + (((calc_type(c.g) - g) * ik) >> base_shift)); - ret.b = value_type(calc_type(b) + (((calc_type(c.b) - b) * ik) >> base_shift)); - ret.a = value_type(calc_type(a) + (((calc_type(c.a) - a) * ik) >> base_shift)); - return ret; - } - - //-------------------------------------------------------------------- - AGG_INLINE void add(const self_type& c, unsigned cover) - { - calc_type cr, cg, cb, ca; - if(cover == cover_mask) - { - if(c.a == base_mask) - { - *this = c; - } - else - { - cr = r + c.r; r = (cr > calc_type(base_mask)) ? calc_type(base_mask) : cr; - cg = g + c.g; g = (cg > calc_type(base_mask)) ? calc_type(base_mask) : cg; - cb = b + c.b; b = (cb > calc_type(base_mask)) ? calc_type(base_mask) : cb; - ca = a + c.a; a = (ca > calc_type(base_mask)) ? calc_type(base_mask) : ca; - } - } - else - { - cr = r + ((c.r * cover + cover_mask/2) >> cover_shift); - cg = g + ((c.g * cover + cover_mask/2) >> cover_shift); - cb = b + ((c.b * cover + cover_mask/2) >> cover_shift); - ca = a + ((c.a * cover + cover_mask/2) >> cover_shift); - r = (cr > calc_type(base_mask)) ? calc_type(base_mask) : cr; - g = (cg > calc_type(base_mask)) ? calc_type(base_mask) : cg; - b = (cb > calc_type(base_mask)) ? calc_type(base_mask) : cb; - a = (ca > calc_type(base_mask)) ? calc_type(base_mask) : ca; - } - } - - //-------------------------------------------------------------------- - template - AGG_INLINE void apply_gamma_dir(const GammaLUT& gamma) - { - r = gamma.dir(r); - g = gamma.dir(g); - b = gamma.dir(b); - } - - //-------------------------------------------------------------------- - template - AGG_INLINE void apply_gamma_inv(const GammaLUT& gamma) - { - r = gamma.inv(r); - g = gamma.inv(g); - b = gamma.inv(b); - } - - //-------------------------------------------------------------------- - static self_type no_color() { return self_type(0,0,0,0); } - - //-------------------------------------------------------------------- - static self_type from_wavelength(double wl, double gamma = 1.0) - { - return self_type(rgba::from_wavelength(wl, gamma)); - } - }; - - - //-------------------------------------------------------------rgba8_pre - inline rgba8 rgba8_pre(unsigned r, unsigned g, unsigned b, - unsigned a = rgba8::base_mask) - { - return rgba8(r,g,b,a).premultiply(); - } - inline rgba8 rgba8_pre(const rgba8& c) - { - return rgba8(c).premultiply(); - } - inline rgba8 rgba8_pre(const rgba8& c, unsigned a) - { - return rgba8(c,a).premultiply(); - } - inline rgba8 rgba8_pre(const rgba& c) - { - return rgba8(c).premultiply(); - } - inline rgba8 rgba8_pre(const rgba& c, double a) - { - return rgba8(c,a).premultiply(); - } - - - //-------------------------------------------------------------rgb8_packed - inline rgba8 rgb8_packed(unsigned v) - { - return rgba8((v >> 16) & 0xFF, (v >> 8) & 0xFF, v & 0xFF); - } - - //-------------------------------------------------------------bgr8_packed - inline rgba8 bgr8_packed(unsigned v) - { - return rgba8(v & 0xFF, (v >> 8) & 0xFF, (v >> 16) & 0xFF); - } - - //------------------------------------------------------------argb8_packed - inline rgba8 argb8_packed(unsigned v) - { - return rgba8((v >> 16) & 0xFF, (v >> 8) & 0xFF, v & 0xFF, v >> 24); - } - - //---------------------------------------------------------rgba8_gamma_dir - template - rgba8 rgba8_gamma_dir(rgba8 c, const GammaLUT& gamma) - { - return rgba8(gamma.dir(c.r), gamma.dir(c.g), gamma.dir(c.b), c.a); - } - - //---------------------------------------------------------rgba8_gamma_inv - template - rgba8 rgba8_gamma_inv(rgba8 c, const GammaLUT& gamma) - { - return rgba8(gamma.inv(c.r), gamma.inv(c.g), gamma.inv(c.b), c.a); - } - - - - - - //==================================================================rgba16 - struct rgba16 - { - typedef int16u value_type; - typedef int32u calc_type; - typedef int64 long_type; - enum base_scale_e - { - base_shift = 16, - base_scale = 1 << base_shift, - base_mask = base_scale - 1 - }; - typedef rgba16 self_type; - - value_type r; - value_type g; - value_type b; - value_type a; - - //-------------------------------------------------------------------- - rgba16() {} - - //-------------------------------------------------------------------- - rgba16(unsigned r_, unsigned g_, unsigned b_, unsigned a_=base_mask) : - r(value_type(r_)), - g(value_type(g_)), - b(value_type(b_)), - a(value_type(a_)) {} - - //-------------------------------------------------------------------- - rgba16(const self_type& c, unsigned a_) : - r(c.r), g(c.g), b(c.b), a(value_type(a_)) {} - - //-------------------------------------------------------------------- - rgba16(const rgba& c) : - r((value_type)uround(c.r * double(base_mask))), - g((value_type)uround(c.g * double(base_mask))), - b((value_type)uround(c.b * double(base_mask))), - a((value_type)uround(c.a * double(base_mask))) {} - - //-------------------------------------------------------------------- - rgba16(const rgba& c, double a_) : - r((value_type)uround(c.r * double(base_mask))), - g((value_type)uround(c.g * double(base_mask))), - b((value_type)uround(c.b * double(base_mask))), - a((value_type)uround(a_ * double(base_mask))) {} - - //-------------------------------------------------------------------- - rgba16(const rgba8& c) : - r(value_type((value_type(c.r) << 8) | c.r)), - g(value_type((value_type(c.g) << 8) | c.g)), - b(value_type((value_type(c.b) << 8) | c.b)), - a(value_type((value_type(c.a) << 8) | c.a)) {} - - //-------------------------------------------------------------------- - rgba16(const rgba8& c, unsigned a_) : - r(value_type((value_type(c.r) << 8) | c.r)), - g(value_type((value_type(c.g) << 8) | c.g)), - b(value_type((value_type(c.b) << 8) | c.b)), - a(value_type(( a_ << 8) | c.a)) {} - - //-------------------------------------------------------------------- - void clear() - { - r = g = b = a = 0; - } - - //-------------------------------------------------------------------- - const self_type& transparent() - { - a = 0; - return *this; - } - - //-------------------------------------------------------------------- - AGG_INLINE const self_type& opacity(double a_) - { - if(a_ < 0.0) a_ = 0.0; - if(a_ > 1.0) a_ = 1.0; - a = (value_type)uround(a_ * double(base_mask)); - return *this; - } - - //-------------------------------------------------------------------- - double opacity() const - { - return double(a) / double(base_mask); - } - - //-------------------------------------------------------------------- - AGG_INLINE const self_type& premultiply() - { - if(a == base_mask) return *this; - if(a == 0) - { - r = g = b = 0; - return *this; - } - r = value_type((calc_type(r) * a) >> base_shift); - g = value_type((calc_type(g) * a) >> base_shift); - b = value_type((calc_type(b) * a) >> base_shift); - return *this; - } - - //-------------------------------------------------------------------- - AGG_INLINE const self_type& premultiply(unsigned a_) - { - if(a == base_mask && a_ >= base_mask) return *this; - if(a == 0 || a_ == 0) - { - r = g = b = a = 0; - return *this; - } - calc_type r_ = (calc_type(r) * a_) / a; - calc_type g_ = (calc_type(g) * a_) / a; - calc_type b_ = (calc_type(b) * a_) / a; - r = value_type((r_ > a_) ? a_ : r_); - g = value_type((g_ > a_) ? a_ : g_); - b = value_type((b_ > a_) ? a_ : b_); - a = value_type(a_); - return *this; - } - - //-------------------------------------------------------------------- - AGG_INLINE const self_type& demultiply() - { - if(a == base_mask) return *this; - if(a == 0) - { - r = g = b = 0; - return *this; - } - calc_type r_ = (calc_type(r) * base_mask) / a; - calc_type g_ = (calc_type(g) * base_mask) / a; - calc_type b_ = (calc_type(b) * base_mask) / a; - r = value_type((r_ > calc_type(base_mask)) ? calc_type(base_mask) : r_); - g = value_type((g_ > calc_type(base_mask)) ? calc_type(base_mask) : g_); - b = value_type((b_ > calc_type(base_mask)) ? calc_type(base_mask) : b_); - return *this; - } - - //-------------------------------------------------------------------- - AGG_INLINE self_type gradient(const self_type& c, double k) const - { - self_type ret; - calc_type ik = uround(k * base_scale); - ret.r = value_type(calc_type(r) + (((calc_type(c.r) - r) * ik) >> base_shift)); - ret.g = value_type(calc_type(g) + (((calc_type(c.g) - g) * ik) >> base_shift)); - ret.b = value_type(calc_type(b) + (((calc_type(c.b) - b) * ik) >> base_shift)); - ret.a = value_type(calc_type(a) + (((calc_type(c.a) - a) * ik) >> base_shift)); - return ret; - } - - //-------------------------------------------------------------------- - AGG_INLINE void add(const self_type& c, unsigned cover) - { - calc_type cr, cg, cb, ca; - if(cover == cover_mask) - { - if(c.a == base_mask) - { - *this = c; - } - else - { - cr = r + c.r; r = (cr > calc_type(base_mask)) ? calc_type(base_mask) : cr; - cg = g + c.g; g = (cg > calc_type(base_mask)) ? calc_type(base_mask) : cg; - cb = b + c.b; b = (cb > calc_type(base_mask)) ? calc_type(base_mask) : cb; - ca = a + c.a; a = (ca > calc_type(base_mask)) ? calc_type(base_mask) : ca; - } - } - else - { - cr = r + ((c.r * cover + cover_mask) >> cover_shift); - cg = g + ((c.g * cover + cover_mask) >> cover_shift); - cb = b + ((c.b * cover + cover_mask) >> cover_shift); - ca = a + ((c.a * cover + cover_mask) >> cover_shift); - r = (cr > calc_type(base_mask)) ? calc_type(base_mask) : cr; - g = (cg > calc_type(base_mask)) ? calc_type(base_mask) : cg; - b = (cb > calc_type(base_mask)) ? calc_type(base_mask) : cb; - a = (ca > calc_type(base_mask)) ? calc_type(base_mask) : ca; - } - } - - //-------------------------------------------------------------------- - template - AGG_INLINE void apply_gamma_dir(const GammaLUT& gamma) - { - r = gamma.dir(r); - g = gamma.dir(g); - b = gamma.dir(b); - } - - //-------------------------------------------------------------------- - template - AGG_INLINE void apply_gamma_inv(const GammaLUT& gamma) - { - r = gamma.inv(r); - g = gamma.inv(g); - b = gamma.inv(b); - } - - //-------------------------------------------------------------------- - static self_type no_color() { return self_type(0,0,0,0); } - - //-------------------------------------------------------------------- - static self_type from_wavelength(double wl, double gamma = 1.0) - { - return self_type(rgba::from_wavelength(wl, gamma)); - } - }; - - - - //--------------------------------------------------------------rgba16_pre - inline rgba16 rgba16_pre(unsigned r, unsigned g, unsigned b, - unsigned a = rgba16::base_mask) - { - return rgba16(r,g,b,a).premultiply(); - } - inline rgba16 rgba16_pre(const rgba16& c, unsigned a) - { - return rgba16(c,a).premultiply(); - } - inline rgba16 rgba16_pre(const rgba& c) - { - return rgba16(c).premultiply(); - } - inline rgba16 rgba16_pre(const rgba& c, double a) - { - return rgba16(c,a).premultiply(); - } - inline rgba16 rgba16_pre(const rgba8& c) - { - return rgba16(c).premultiply(); - } - inline rgba16 rgba16_pre(const rgba8& c, unsigned a) - { - return rgba16(c,a).premultiply(); - } - - - //------------------------------------------------------rgba16_gamma_dir - template - rgba16 rgba16_gamma_dir(rgba16 c, const GammaLUT& gamma) - { - return rgba16(gamma.dir(c.r), gamma.dir(c.g), gamma.dir(c.b), c.a); - } - - //------------------------------------------------------rgba16_gamma_inv - template - rgba16 rgba16_gamma_inv(rgba16 c, const GammaLUT& gamma) - { - return rgba16(gamma.inv(c.r), gamma.inv(c.g), gamma.inv(c.b), c.a); - } - - -} - - - -#endif diff --git a/desmume/src/windows/agg/include/agg_config.h b/desmume/src/windows/agg/include/agg_config.h deleted file mode 100644 index 372b77bfc..000000000 --- a/desmume/src/windows/agg/include/agg_config.h +++ /dev/null @@ -1,44 +0,0 @@ -#ifndef AGG_CONFIG_INCLUDED -#define AGG_CONFIG_INCLUDED - -// This file can be used to redefine certain data types. - -//--------------------------------------- -// 1. Default basic types such as: -// -// AGG_INT8 -// AGG_INT8U -// AGG_INT16 -// AGG_INT16U -// AGG_INT32 -// AGG_INT32U -// AGG_INT64 -// AGG_INT64U -// -// Just replace this file with new defines if necessary. -// For example, if your compiler doesn't have a 64 bit integer type -// you can still use AGG if you define the follows: -// -// #define AGG_INT64 int -// #define AGG_INT64U unsigned -// -// It will result in overflow in 16 bit-per-component image/pattern resampling -// but it won't result any crash and the rest of the library will remain -// fully functional. - - -//--------------------------------------- -// 2. Default rendering_buffer type. Can be: -// -// Provides faster access for massive pixel operations, -// such as blur, image filtering: -// #define AGG_RENDERING_BUFFER row_ptr_cache -// -// Provides cheaper creation and destruction (no mem allocs): -// #define AGG_RENDERING_BUFFER row_accessor -// -// You can still use both of them simultaneouslyin your applications -// This #define is used only for default rendering_buffer type, -// in short hand typedefs like pixfmt_rgba32. - -#endif diff --git a/desmume/src/windows/agg/include/agg_conv_adaptor_vcgen.h b/desmume/src/windows/agg/include/agg_conv_adaptor_vcgen.h deleted file mode 100644 index 9719c715e..000000000 --- a/desmume/src/windows/agg/include/agg_conv_adaptor_vcgen.h +++ /dev/null @@ -1,166 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_CONV_ADAPTOR_VCGEN_INCLUDED -#define AGG_CONV_ADAPTOR_VCGEN_INCLUDED - -#include "agg_basics.h" - -namespace agg -{ - //------------------------------------------------------------null_markers - struct null_markers - { - void remove_all() {} - void add_vertex(double, double, unsigned) {} - void prepare_src() {} - - void rewind(unsigned) {} - unsigned vertex(double*, double*) { return path_cmd_stop; } - }; - - - //------------------------------------------------------conv_adaptor_vcgen - template class conv_adaptor_vcgen - { - enum status - { - initial, - accumulate, - generate - }; - - public: - explicit conv_adaptor_vcgen(VertexSource& source) : - m_source(&source), - m_status(initial) - {} - void attach(VertexSource& source) { m_source = &source; } - - Generator& generator() { return m_generator; } - const Generator& generator() const { return m_generator; } - - Markers& markers() { return m_markers; } - const Markers& markers() const { return m_markers; } - - void rewind(unsigned path_id) - { - m_source->rewind(path_id); - m_status = initial; - } - - unsigned vertex(double* x, double* y); - - private: - // Prohibit copying - conv_adaptor_vcgen(const conv_adaptor_vcgen&); - const conv_adaptor_vcgen& - operator = (const conv_adaptor_vcgen&); - - VertexSource* m_source; - Generator m_generator; - Markers m_markers; - status m_status; - unsigned m_last_cmd; - double m_start_x; - double m_start_y; - }; - - - - - - //------------------------------------------------------------------------ - template - unsigned conv_adaptor_vcgen::vertex(double* x, double* y) - { - unsigned cmd = path_cmd_stop; - bool done = false; - while(!done) - { - switch(m_status) - { - case initial: - m_markers.remove_all(); - m_last_cmd = m_source->vertex(&m_start_x, &m_start_y); - m_status = accumulate; - - case accumulate: - if(is_stop(m_last_cmd)) return path_cmd_stop; - - m_generator.remove_all(); - m_generator.add_vertex(m_start_x, m_start_y, path_cmd_move_to); - m_markers.add_vertex(m_start_x, m_start_y, path_cmd_move_to); - - for(;;) - { - cmd = m_source->vertex(x, y); - if(is_vertex(cmd)) - { - m_last_cmd = cmd; - if(is_move_to(cmd)) - { - m_start_x = *x; - m_start_y = *y; - break; - } - m_generator.add_vertex(*x, *y, cmd); - m_markers.add_vertex(*x, *y, path_cmd_line_to); - } - else - { - if(is_stop(cmd)) - { - m_last_cmd = path_cmd_stop; - break; - } - if(is_end_poly(cmd)) - { - m_generator.add_vertex(*x, *y, cmd); - break; - } - } - } - m_generator.rewind(0); - m_status = generate; - - case generate: - cmd = m_generator.vertex(x, y); - if(is_stop(cmd)) - { - m_status = accumulate; - break; - } - done = true; - break; - } - } - return cmd; - } - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_conv_adaptor_vpgen.h b/desmume/src/windows/agg/include/agg_conv_adaptor_vpgen.h deleted file mode 100644 index 2243e1e87..000000000 --- a/desmume/src/windows/agg/include/agg_conv_adaptor_vpgen.h +++ /dev/null @@ -1,168 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_CONV_ADAPTOR_VPGEN_INCLUDED -#define AGG_CONV_ADAPTOR_VPGEN_INCLUDED - -#include "agg_basics.h" - -namespace agg -{ - - //======================================================conv_adaptor_vpgen - template class conv_adaptor_vpgen - { - public: - explicit conv_adaptor_vpgen(VertexSource& source) : m_source(&source) {} - void attach(VertexSource& source) { m_source = &source; } - - VPGen& vpgen() { return m_vpgen; } - const VPGen& vpgen() const { return m_vpgen; } - - void rewind(unsigned path_id); - unsigned vertex(double* x, double* y); - - private: - conv_adaptor_vpgen(const conv_adaptor_vpgen&); - const conv_adaptor_vpgen& - operator = (const conv_adaptor_vpgen&); - - VertexSource* m_source; - VPGen m_vpgen; - double m_start_x; - double m_start_y; - unsigned m_poly_flags; - int m_vertices; - }; - - - - //------------------------------------------------------------------------ - template - void conv_adaptor_vpgen::rewind(unsigned path_id) - { - m_source->rewind(path_id); - m_vpgen.reset(); - m_start_x = 0; - m_start_y = 0; - m_poly_flags = 0; - m_vertices = 0; - } - - - //------------------------------------------------------------------------ - template - unsigned conv_adaptor_vpgen::vertex(double* x, double* y) - { - unsigned cmd = path_cmd_stop; - for(;;) - { - cmd = m_vpgen.vertex(x, y); - if(!is_stop(cmd)) break; - - if(m_poly_flags && !m_vpgen.auto_unclose()) - { - *x = 0.0; - *y = 0.0; - cmd = m_poly_flags; - m_poly_flags = 0; - break; - } - - if(m_vertices < 0) - { - if(m_vertices < -1) - { - m_vertices = 0; - return path_cmd_stop; - } - m_vpgen.move_to(m_start_x, m_start_y); - m_vertices = 1; - continue; - } - - double tx, ty; - cmd = m_source->vertex(&tx, &ty); - if(is_vertex(cmd)) - { - if(is_move_to(cmd)) - { - if(m_vpgen.auto_close() && m_vertices > 2) - { - m_vpgen.line_to(m_start_x, m_start_y); - m_poly_flags = path_cmd_end_poly | path_flags_close; - m_start_x = tx; - m_start_y = ty; - m_vertices = -1; - continue; - } - m_vpgen.move_to(tx, ty); - m_start_x = tx; - m_start_y = ty; - m_vertices = 1; - } - else - { - m_vpgen.line_to(tx, ty); - ++m_vertices; - } - } - else - { - if(is_end_poly(cmd)) - { - m_poly_flags = cmd; - if(is_closed(cmd) || m_vpgen.auto_close()) - { - if(m_vpgen.auto_close()) m_poly_flags |= path_flags_close; - if(m_vertices > 2) - { - m_vpgen.line_to(m_start_x, m_start_y); - } - m_vertices = 0; - } - } - else - { - // path_cmd_stop - if(m_vpgen.auto_close() && m_vertices > 2) - { - m_vpgen.line_to(m_start_x, m_start_y); - m_poly_flags = path_cmd_end_poly | path_flags_close; - m_vertices = -2; - continue; - } - break; - } - } - } - return cmd; - } - - -} - - -#endif - diff --git a/desmume/src/windows/agg/include/agg_conv_bspline.h b/desmume/src/windows/agg/include/agg_conv_bspline.h deleted file mode 100644 index ff5fb751f..000000000 --- a/desmume/src/windows/agg/include/agg_conv_bspline.h +++ /dev/null @@ -1,58 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_CONV_BSPLINE_INCLUDED -#define AGG_CONV_BSPLINE_INCLUDED - -#include "agg_basics.h" -#include "agg_vcgen_bspline.h" -#include "agg_conv_adaptor_vcgen.h" - - -namespace agg -{ - - //---------------------------------------------------------conv_bspline - template - struct conv_bspline : public conv_adaptor_vcgen - { - typedef conv_adaptor_vcgen base_type; - - conv_bspline(VertexSource& vs) : - conv_adaptor_vcgen(vs) {} - - void interpolation_step(double v) { base_type::generator().interpolation_step(v); } - double interpolation_step() const { return base_type::generator().interpolation_step(); } - - private: - conv_bspline(const conv_bspline&); - const conv_bspline& - operator = (const conv_bspline&); - }; - -} - - -#endif - diff --git a/desmume/src/windows/agg/include/agg_conv_clip_polygon.h b/desmume/src/windows/agg/include/agg_conv_clip_polygon.h deleted file mode 100644 index e1e9d45a3..000000000 --- a/desmume/src/windows/agg/include/agg_conv_clip_polygon.h +++ /dev/null @@ -1,72 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- -// -// Polygon clipping converter -// There an optimized Liang-Basky algorithm is used. -// The algorithm doesn't optimize the degenerate edges, i.e. it will never -// break a closed polygon into two or more ones, instead, there will be -// degenerate edges coinciding with the respective clipping boundaries. -// This is a sub-optimal solution, because that optimization would require -// extra, rather expensive math while the rasterizer tolerates it quite well, -// without any considerable overhead. -// -//---------------------------------------------------------------------------- -#ifndef AGG_CONV_CLIP_POLYGON_INCLUDED -#define AGG_CONV_CLIP_POLYGON_INCLUDED - -#include "agg_basics.h" -#include "agg_conv_adaptor_vpgen.h" -#include "agg_vpgen_clip_polygon.h" - -namespace agg -{ - - //=======================================================conv_clip_polygon - template - struct conv_clip_polygon : public conv_adaptor_vpgen - { - typedef conv_adaptor_vpgen base_type; - - conv_clip_polygon(VertexSource& vs) : - conv_adaptor_vpgen(vs) {} - - void clip_box(double x1, double y1, double x2, double y2) - { - base_type::vpgen().clip_box(x1, y1, x2, y2); - } - - double x1() const { return base_type::vpgen().x1(); } - double y1() const { return base_type::vpgen().y1(); } - double x2() const { return base_type::vpgen().x2(); } - double y2() const { return base_type::vpgen().y2(); } - - private: - conv_clip_polygon(const conv_clip_polygon&); - const conv_clip_polygon& - operator = (const conv_clip_polygon&); - }; - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_conv_clip_polyline.h b/desmume/src/windows/agg/include/agg_conv_clip_polyline.h deleted file mode 100644 index 7614f7eb3..000000000 --- a/desmume/src/windows/agg/include/agg_conv_clip_polyline.h +++ /dev/null @@ -1,72 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- -// -// polyline clipping converter -// There an optimized Liang-Basky algorithm is used. -// The algorithm doesn't optimize the degenerate edges, i.e. it will never -// break a closed polyline into two or more ones, instead, there will be -// degenerate edges coinciding with the respective clipping boundaries. -// This is a sub-optimal solution, because that optimization would require -// extra, rather expensive math while the rasterizer tolerates it quite well, -// without any considerable overhead. -// -//---------------------------------------------------------------------------- -#ifndef AGG_CONV_CLIP_polyline_INCLUDED -#define AGG_CONV_CLIP_polyline_INCLUDED - -#include "agg_basics.h" -#include "agg_conv_adaptor_vpgen.h" -#include "agg_vpgen_clip_polyline.h" - -namespace agg -{ - - //=======================================================conv_clip_polyline - template - struct conv_clip_polyline : public conv_adaptor_vpgen - { - typedef conv_adaptor_vpgen base_type; - - conv_clip_polyline(VertexSource& vs) : - conv_adaptor_vpgen(vs) {} - - void clip_box(double x1, double y1, double x2, double y2) - { - base_type::vpgen().clip_box(x1, y1, x2, y2); - } - - double x1() const { return base_type::vpgen().x1(); } - double y1() const { return base_type::vpgen().y1(); } - double x2() const { return base_type::vpgen().x2(); } - double y2() const { return base_type::vpgen().y2(); } - - private: - conv_clip_polyline(const conv_clip_polyline&); - const conv_clip_polyline& - operator = (const conv_clip_polyline&); - }; - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_conv_close_polygon.h b/desmume/src/windows/agg/include/agg_conv_close_polygon.h deleted file mode 100644 index e50deed62..000000000 --- a/desmume/src/windows/agg/include/agg_conv_close_polygon.h +++ /dev/null @@ -1,134 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_CONV_CLOSE_POLYGON_INCLUDED -#define AGG_CONV_CLOSE_POLYGON_INCLUDED - -#include "agg_basics.h" - -namespace agg -{ - - //======================================================conv_close_polygon - template class conv_close_polygon - { - public: - explicit conv_close_polygon(VertexSource& vs) : m_source(&vs) {} - void attach(VertexSource& source) { m_source = &source; } - - void rewind(unsigned path_id); - unsigned vertex(double* x, double* y); - - private: - conv_close_polygon(const conv_close_polygon&); - const conv_close_polygon& - operator = (const conv_close_polygon&); - - VertexSource* m_source; - unsigned m_cmd[2]; - double m_x[2]; - double m_y[2]; - unsigned m_vertex; - bool m_line_to; - }; - - - - //------------------------------------------------------------------------ - template - void conv_close_polygon::rewind(unsigned path_id) - { - m_source->rewind(path_id); - m_vertex = 2; - m_line_to = false; - } - - - - //------------------------------------------------------------------------ - template - unsigned conv_close_polygon::vertex(double* x, double* y) - { - unsigned cmd = path_cmd_stop; - for(;;) - { - if(m_vertex < 2) - { - *x = m_x[m_vertex]; - *y = m_y[m_vertex]; - cmd = m_cmd[m_vertex]; - ++m_vertex; - break; - } - - cmd = m_source->vertex(x, y); - - if(is_end_poly(cmd)) - { - cmd |= path_flags_close; - break; - } - - if(is_stop(cmd)) - { - if(m_line_to) - { - m_cmd[0] = path_cmd_end_poly | path_flags_close; - m_cmd[1] = path_cmd_stop; - m_vertex = 0; - m_line_to = false; - continue; - } - break; - } - - if(is_move_to(cmd)) - { - if(m_line_to) - { - m_x[0] = 0.0; - m_y[0] = 0.0; - m_cmd[0] = path_cmd_end_poly | path_flags_close; - m_x[1] = *x; - m_y[1] = *y; - m_cmd[1] = cmd; - m_vertex = 0; - m_line_to = false; - continue; - } - break; - } - - if(is_vertex(cmd)) - { - m_line_to = true; - break; - } - } - return cmd; - } - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_conv_concat.h b/desmume/src/windows/agg/include/agg_conv_concat.h deleted file mode 100644 index 72ff0fc68..000000000 --- a/desmume/src/windows/agg/include/agg_conv_concat.h +++ /dev/null @@ -1,82 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_CONV_CONCAT_INCLUDED -#define AGG_CONV_CONCAT_INCLUDED - -#include "agg_basics.h" - -namespace agg -{ - //=============================================================conv_concat - // Concatenation of two paths. Usually used to combine lines or curves - // with markers such as arrowheads - template class conv_concat - { - public: - conv_concat(VS1& source1, VS2& source2) : - m_source1(&source1), m_source2(&source2), m_status(2) {} - void attach1(VS1& source) { m_source1 = &source; } - void attach2(VS2& source) { m_source2 = &source; } - - - void rewind(unsigned path_id) - { - m_source1->rewind(path_id); - m_source2->rewind(0); - m_status = 0; - } - - unsigned vertex(double* x, double* y) - { - unsigned cmd; - if(m_status == 0) - { - cmd = m_source1->vertex(x, y); - if(!is_stop(cmd)) return cmd; - m_status = 1; - } - if(m_status == 1) - { - cmd = m_source2->vertex(x, y); - if(!is_stop(cmd)) return cmd; - m_status = 2; - } - return path_cmd_stop; - } - - private: - conv_concat(const conv_concat&); - const conv_concat& - operator = (const conv_concat&); - - VS1* m_source1; - VS2* m_source2; - int m_status; - - }; -} - - -#endif diff --git a/desmume/src/windows/agg/include/agg_conv_contour.h b/desmume/src/windows/agg/include/agg_conv_contour.h deleted file mode 100644 index ae05b02a1..000000000 --- a/desmume/src/windows/agg/include/agg_conv_contour.h +++ /dev/null @@ -1,71 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_CONV_CONTOUR_INCLUDED -#define AGG_CONV_CONTOUR_INCLUDED - -#include "agg_basics.h" -#include "agg_vcgen_contour.h" -#include "agg_conv_adaptor_vcgen.h" - -namespace agg -{ - - //-----------------------------------------------------------conv_contour - template - struct conv_contour : public conv_adaptor_vcgen - { - typedef conv_adaptor_vcgen base_type; - - conv_contour(VertexSource& vs) : - conv_adaptor_vcgen(vs) - { - } - - void line_join(line_join_e lj) { base_type::generator().line_join(lj); } - void inner_join(inner_join_e ij) { base_type::generator().inner_join(ij); } - void width(double w) { base_type::generator().width(w); } - void miter_limit(double ml) { base_type::generator().miter_limit(ml); } - void miter_limit_theta(double t) { base_type::generator().miter_limit_theta(t); } - void inner_miter_limit(double ml) { base_type::generator().inner_miter_limit(ml); } - void approximation_scale(double as) { base_type::generator().approximation_scale(as); } - void auto_detect_orientation(bool v) { base_type::generator().auto_detect_orientation(v); } - - line_join_e line_join() const { return base_type::generator().line_join(); } - inner_join_e inner_join() const { return base_type::generator().inner_join(); } - double width() const { return base_type::generator().width(); } - double miter_limit() const { return base_type::generator().miter_limit(); } - double inner_miter_limit() const { return base_type::generator().inner_miter_limit(); } - double approximation_scale() const { return base_type::generator().approximation_scale(); } - bool auto_detect_orientation() const { return base_type::generator().auto_detect_orientation(); } - - private: - conv_contour(const conv_contour&); - const conv_contour& - operator = (const conv_contour&); - }; - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_conv_curve.h b/desmume/src/windows/agg/include/agg_conv_curve.h deleted file mode 100644 index 504bd4709..000000000 --- a/desmume/src/windows/agg/include/agg_conv_curve.h +++ /dev/null @@ -1,206 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_CONV_CURVE_INCLUDED -#define AGG_CONV_CURVE_INCLUDED - -#include "agg_basics.h" -#include "agg_curves.h" - -namespace agg -{ - - - //---------------------------------------------------------------conv_curve - // Curve converter class. Any path storage can have Bezier curves defined - // by their control points. There're two types of curves supported: curve3 - // and curve4. Curve3 is a conic Bezier curve with 2 endpoints and 1 control - // point. Curve4 has 2 control points (4 points in total) and can be used - // to interpolate more complicated curves. Curve4, unlike curve3 can be used - // to approximate arcs, both circular and elliptical. Curves are approximated - // with straight lines and one of the approaches is just to store the whole - // sequence of vertices that approximate our curve. It takes additional - // memory, and at the same time the consecutive vertices can be calculated - // on demand. - // - // Initially, path storages are not suppose to keep all the vertices of the - // curves (although, nothing prevents us from doing so). Instead, path_storage - // keeps only vertices, needed to calculate a curve on demand. Those vertices - // are marked with special commands. So, if the path_storage contains curves - // (which are not real curves yet), and we render this storage directly, - // all we will see is only 2 or 3 straight line segments (for curve3 and - // curve4 respectively). If we need to see real curves drawn we need to - // include this class into the conversion pipeline. - // - // Class conv_curve recognizes commands path_cmd_curve3 and path_cmd_curve4 - // and converts these vertices into a move_to/line_to sequence. - //----------------------------------------------------------------------- - template class conv_curve - { - public: - typedef Curve3 curve3_type; - typedef Curve4 curve4_type; - typedef conv_curve self_type; - - explicit conv_curve(VertexSource& source) : - m_source(&source), m_last_x(0.0), m_last_y(0.0) {} - void attach(VertexSource& source) { m_source = &source; } - - void approximation_method(curve_approximation_method_e v) - { - m_curve3.approximation_method(v); - m_curve4.approximation_method(v); - } - - curve_approximation_method_e approximation_method() const - { - return m_curve4.approximation_method(); - } - - void approximation_scale(double s) - { - m_curve3.approximation_scale(s); - m_curve4.approximation_scale(s); - } - - double approximation_scale() const - { - return m_curve4.approximation_scale(); - } - - void angle_tolerance(double v) - { - m_curve3.angle_tolerance(v); - m_curve4.angle_tolerance(v); - } - - double angle_tolerance() const - { - return m_curve4.angle_tolerance(); - } - - void cusp_limit(double v) - { - m_curve3.cusp_limit(v); - m_curve4.cusp_limit(v); - } - - double cusp_limit() const - { - return m_curve4.cusp_limit(); - } - - void rewind(unsigned path_id); - unsigned vertex(double* x, double* y); - - private: - conv_curve(const self_type&); - const self_type& operator = (const self_type&); - - VertexSource* m_source; - double m_last_x; - double m_last_y; - curve3_type m_curve3; - curve4_type m_curve4; - }; - - - - //------------------------------------------------------------------------ - template - void conv_curve::rewind(unsigned path_id) - { - m_source->rewind(path_id); - m_last_x = 0.0; - m_last_y = 0.0; - m_curve3.reset(); - m_curve4.reset(); - } - - - //------------------------------------------------------------------------ - template - unsigned conv_curve::vertex(double* x, double* y) - { - if(!is_stop(m_curve3.vertex(x, y))) - { - m_last_x = *x; - m_last_y = *y; - return path_cmd_line_to; - } - - if(!is_stop(m_curve4.vertex(x, y))) - { - m_last_x = *x; - m_last_y = *y; - return path_cmd_line_to; - } - - double ct2_x; - double ct2_y; - double end_x; - double end_y; - - unsigned cmd = m_source->vertex(x, y); - switch(cmd) - { - case path_cmd_curve3: - m_source->vertex(&end_x, &end_y); - - m_curve3.init(m_last_x, m_last_y, - *x, *y, - end_x, end_y); - - m_curve3.vertex(x, y); // First call returns path_cmd_move_to - m_curve3.vertex(x, y); // This is the first vertex of the curve - cmd = path_cmd_line_to; - break; - - case path_cmd_curve4: - m_source->vertex(&ct2_x, &ct2_y); - m_source->vertex(&end_x, &end_y); - - m_curve4.init(m_last_x, m_last_y, - *x, *y, - ct2_x, ct2_y, - end_x, end_y); - - m_curve4.vertex(x, y); // First call returns path_cmd_move_to - m_curve4.vertex(x, y); // This is the first vertex of the curve - cmd = path_cmd_line_to; - break; - } - m_last_x = *x; - m_last_y = *y; - return cmd; - } - - -} - - - -#endif diff --git a/desmume/src/windows/agg/include/agg_conv_dash.h b/desmume/src/windows/agg/include/agg_conv_dash.h deleted file mode 100644 index c3f1613b1..000000000 --- a/desmume/src/windows/agg/include/agg_conv_dash.h +++ /dev/null @@ -1,74 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_CONV_DASH_INCLUDED -#define AGG_CONV_DASH_INCLUDED - -#include "agg_basics.h" -#include "agg_vcgen_dash.h" -#include "agg_conv_adaptor_vcgen.h" - -namespace agg -{ - - //---------------------------------------------------------------conv_dash - template - struct conv_dash : public conv_adaptor_vcgen - { - typedef Markers marker_type; - typedef conv_adaptor_vcgen base_type; - - conv_dash(VertexSource& vs) : - conv_adaptor_vcgen(vs) - { - } - - void remove_all_dashes() - { - base_type::generator().remove_all_dashes(); - } - - void add_dash(double dash_len, double gap_len) - { - base_type::generator().add_dash(dash_len, gap_len); - } - - void dash_start(double ds) - { - base_type::generator().dash_start(ds); - } - - void shorten(double s) { base_type::generator().shorten(s); } - double shorten() const { return base_type::generator().shorten(); } - - private: - conv_dash(const conv_dash&); - const conv_dash& - operator = (const conv_dash&); - }; - - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_conv_gpc.h b/desmume/src/windows/agg/include/agg_conv_gpc.h deleted file mode 100644 index c837c08cc..000000000 --- a/desmume/src/windows/agg/include/agg_conv_gpc.h +++ /dev/null @@ -1,441 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- -// -// General Polygon Clipper based on the GPC library by Alan Murta -// Union, Intersection, XOR, A-B, B-A -// Contact the author if you intend to use it in commercial applications! -// http://www.cs.man.ac.uk/aig/staff/alan/software/ -// Alan Murta (email: gpc@cs.man.ac.uk) -// -//---------------------------------------------------------------------------- - -#ifndef AGG_CONV_GPC_INCLUDED -#define AGG_CONV_GPC_INCLUDED - -#include -#include "agg_basics.h" -#include "agg_array.h" - -extern "C" -{ -#include "gpc.h" -} - -namespace agg -{ - enum gpc_op_e - { - gpc_or, - gpc_and, - gpc_xor, - gpc_a_minus_b, - gpc_b_minus_a - }; - - - //================================================================conv_gpc - template class conv_gpc - { - enum status - { - status_move_to, - status_line_to, - status_stop - }; - - struct contour_header_type - { - int num_vertices; - int hole_flag; - gpc_vertex* vertices; - }; - - typedef pod_bvector vertex_array_type; - typedef pod_bvector contour_header_array_type; - - - public: - typedef VSA source_a_type; - typedef VSB source_b_type; - typedef conv_gpc self_type; - - ~conv_gpc() - { - free_gpc_data(); - } - - conv_gpc(source_a_type& a, source_b_type& b, gpc_op_e op = gpc_or) : - m_src_a(&a), - m_src_b(&b), - m_status(status_move_to), - m_vertex(-1), - m_contour(-1), - m_operation(op) - { - memset(&m_poly_a, 0, sizeof(m_poly_a)); - memset(&m_poly_b, 0, sizeof(m_poly_b)); - memset(&m_result, 0, sizeof(m_result)); - } - - void attach1(VSA& source) { m_src_a = &source; } - void attach2(VSB& source) { m_src_b = &source; } - - void operation(gpc_op_e v) { m_operation = v; } - - // Vertex Source Interface - void rewind(unsigned path_id); - unsigned vertex(double* x, double* y); - - private: - conv_gpc(const conv_gpc&); - const conv_gpc& operator = (const conv_gpc&); - - //-------------------------------------------------------------------- - void free_polygon(gpc_polygon& p); - void free_result(); - void free_gpc_data(); - void start_contour(); - void add_vertex(double x, double y); - void end_contour(unsigned orientation); - void make_polygon(gpc_polygon& p); - void start_extracting(); - bool next_contour(); - bool next_vertex(double* x, double* y); - - - //-------------------------------------------------------------------- - template void add(VS& src, gpc_polygon& p) - { - unsigned cmd; - double x, y; - double start_x = 0.0; - double start_y = 0.0; - bool line_to = false; - unsigned orientation = 0; - - m_contour_accumulator.remove_all(); - - while(!is_stop(cmd = src.vertex(&x, &y))) - { - if(is_vertex(cmd)) - { - if(is_move_to(cmd)) - { - if(line_to) - { - end_contour(orientation); - orientation = 0; - } - start_contour(); - start_x = x; - start_y = y; - } - add_vertex(x, y); - line_to = true; - } - else - { - if(is_end_poly(cmd)) - { - orientation = get_orientation(cmd); - if(line_to && is_closed(cmd)) - { - add_vertex(start_x, start_y); - } - } - } - } - if(line_to) - { - end_contour(orientation); - } - make_polygon(p); - } - - - private: - //-------------------------------------------------------------------- - source_a_type* m_src_a; - source_b_type* m_src_b; - status m_status; - int m_vertex; - int m_contour; - gpc_op_e m_operation; - vertex_array_type m_vertex_accumulator; - contour_header_array_type m_contour_accumulator; - gpc_polygon m_poly_a; - gpc_polygon m_poly_b; - gpc_polygon m_result; - }; - - - - - - //------------------------------------------------------------------------ - template - void conv_gpc::free_polygon(gpc_polygon& p) - { - int i; - for(i = 0; i < p.num_contours; i++) - { - pod_allocator::deallocate(p.contour[i].vertex, - p.contour[i].num_vertices); - } - pod_allocator::deallocate(p.contour, p.num_contours); - memset(&p, 0, sizeof(gpc_polygon)); - } - - - //------------------------------------------------------------------------ - template - void conv_gpc::free_result() - { - if(m_result.contour) - { - gpc_free_polygon(&m_result); - } - memset(&m_result, 0, sizeof(m_result)); - } - - - //------------------------------------------------------------------------ - template - void conv_gpc::free_gpc_data() - { - free_polygon(m_poly_a); - free_polygon(m_poly_b); - free_result(); - } - - - //------------------------------------------------------------------------ - template - void conv_gpc::start_contour() - { - contour_header_type h; - memset(&h, 0, sizeof(h)); - m_contour_accumulator.add(h); - m_vertex_accumulator.remove_all(); - } - - - //------------------------------------------------------------------------ - template - inline void conv_gpc::add_vertex(double x, double y) - { - gpc_vertex v; - v.x = x; - v.y = y; - m_vertex_accumulator.add(v); - } - - - //------------------------------------------------------------------------ - template - void conv_gpc::end_contour(unsigned orientation) - { - if(m_contour_accumulator.size()) - { - if(m_vertex_accumulator.size() > 2) - { - contour_header_type& h = - m_contour_accumulator[m_contour_accumulator.size() - 1]; - - h.num_vertices = m_vertex_accumulator.size(); - h.hole_flag = 0; - - // TO DO: Clarify the "holes" - //if(is_cw(orientation)) h.hole_flag = 1; - - h.vertices = pod_allocator::allocate(h.num_vertices); - gpc_vertex* d = h.vertices; - int i; - for(i = 0; i < h.num_vertices; i++) - { - const gpc_vertex& s = m_vertex_accumulator[i]; - d->x = s.x; - d->y = s.y; - ++d; - } - } - else - { - m_vertex_accumulator.remove_last(); - } - } - } - - - //------------------------------------------------------------------------ - template - void conv_gpc::make_polygon(gpc_polygon& p) - { - free_polygon(p); - if(m_contour_accumulator.size()) - { - p.num_contours = m_contour_accumulator.size(); - - p.hole = 0; - p.contour = pod_allocator::allocate(p.num_contours); - - int i; - gpc_vertex_list* pv = p.contour; - for(i = 0; i < p.num_contours; i++) - { - const contour_header_type& h = m_contour_accumulator[i]; - pv->num_vertices = h.num_vertices; - pv->vertex = h.vertices; - ++pv; - } - } - } - - - //------------------------------------------------------------------------ - template - void conv_gpc::start_extracting() - { - m_status = status_move_to; - m_contour = -1; - m_vertex = -1; - } - - - //------------------------------------------------------------------------ - template - bool conv_gpc::next_contour() - { - if(++m_contour < m_result.num_contours) - { - m_vertex = -1; - return true; - } - return false; - } - - - //------------------------------------------------------------------------ - template - inline bool conv_gpc::next_vertex(double* x, double* y) - { - const gpc_vertex_list& vlist = m_result.contour[m_contour]; - if(++m_vertex < vlist.num_vertices) - { - const gpc_vertex& v = vlist.vertex[m_vertex]; - *x = v.x; - *y = v.y; - return true; - } - return false; - } - - - //------------------------------------------------------------------------ - template - void conv_gpc::rewind(unsigned path_id) - { - free_result(); - m_src_a->rewind(path_id); - m_src_b->rewind(path_id); - add(*m_src_a, m_poly_a); - add(*m_src_b, m_poly_b); - switch(m_operation) - { - case gpc_or: - gpc_polygon_clip(GPC_UNION, - &m_poly_a, - &m_poly_b, - &m_result); - break; - - case gpc_and: - gpc_polygon_clip(GPC_INT, - &m_poly_a, - &m_poly_b, - &m_result); - break; - - case gpc_xor: - gpc_polygon_clip(GPC_XOR, - &m_poly_a, - &m_poly_b, - &m_result); - break; - - case gpc_a_minus_b: - gpc_polygon_clip(GPC_DIFF, - &m_poly_a, - &m_poly_b, - &m_result); - break; - - case gpc_b_minus_a: - gpc_polygon_clip(GPC_DIFF, - &m_poly_b, - &m_poly_a, - &m_result); - break; - } - start_extracting(); - } - - - //------------------------------------------------------------------------ - template - unsigned conv_gpc::vertex(double* x, double* y) - { - if(m_status == status_move_to) - { - if(next_contour()) - { - if(next_vertex(x, y)) - { - m_status = status_line_to; - return path_cmd_move_to; - } - m_status = status_stop; - return path_cmd_end_poly | path_flags_close; - } - } - else - { - if(next_vertex(x, y)) - { - return path_cmd_line_to; - } - else - { - m_status = status_move_to; - } - return path_cmd_end_poly | path_flags_close; - } - return path_cmd_stop; - } - - -} - - -#endif diff --git a/desmume/src/windows/agg/include/agg_conv_marker.h b/desmume/src/windows/agg/include/agg_conv_marker.h deleted file mode 100644 index 69f8f7bde..000000000 --- a/desmume/src/windows/agg/include/agg_conv_marker.h +++ /dev/null @@ -1,154 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_CONV_MARKER_INCLUDED -#define AGG_CONV_MARKER_INCLUDED - -#include "agg_basics.h" -#include "agg_trans_affine.h" - -namespace agg -{ - //-------------------------------------------------------------conv_marker - template - class conv_marker - { - public: - conv_marker(MarkerLocator& ml, MarkerShapes& ms); - - trans_affine& transform() { return m_transform; } - const trans_affine& transform() const { return m_transform; } - - void rewind(unsigned path_id); - unsigned vertex(double* x, double* y); - - private: - conv_marker(const conv_marker&); - const conv_marker& - operator = (const conv_marker&); - - enum status_e - { - initial, - markers, - polygon, - stop - }; - - MarkerLocator* m_marker_locator; - MarkerShapes* m_marker_shapes; - trans_affine m_transform; - trans_affine m_mtx; - status_e m_status; - unsigned m_marker; - unsigned m_num_markers; - }; - - - //------------------------------------------------------------------------ - template - conv_marker::conv_marker(MarkerLocator& ml, MarkerShapes& ms) : - m_marker_locator(&ml), - m_marker_shapes(&ms), - m_status(initial), - m_marker(0), - m_num_markers(1) - { - } - - - //------------------------------------------------------------------------ - template - void conv_marker::rewind(unsigned) - { - m_status = initial; - m_marker = 0; - m_num_markers = 1; - } - - - //------------------------------------------------------------------------ - template - unsigned conv_marker::vertex(double* x, double* y) - { - unsigned cmd = path_cmd_move_to; - double x1, y1, x2, y2; - - while(!is_stop(cmd)) - { - switch(m_status) - { - case initial: - if(m_num_markers == 0) - { - cmd = path_cmd_stop; - break; - } - m_marker_locator->rewind(m_marker); - ++m_marker; - m_num_markers = 0; - m_status = markers; - - case markers: - if(is_stop(m_marker_locator->vertex(&x1, &y1))) - { - m_status = initial; - break; - } - if(is_stop(m_marker_locator->vertex(&x2, &y2))) - { - m_status = initial; - break; - } - ++m_num_markers; - m_mtx = m_transform; - m_mtx *= trans_affine_rotation(atan2(y2 - y1, x2 - x1)); - m_mtx *= trans_affine_translation(x1, y1); - m_marker_shapes->rewind(m_marker - 1); - m_status = polygon; - - case polygon: - cmd = m_marker_shapes->vertex(x, y); - if(is_stop(cmd)) - { - cmd = path_cmd_move_to; - m_status = markers; - break; - } - m_mtx.transform(x, y); - return cmd; - - case stop: - cmd = path_cmd_stop; - break; - } - } - return cmd; - } - -} - - -#endif - diff --git a/desmume/src/windows/agg/include/agg_conv_marker_adaptor.h b/desmume/src/windows/agg/include/agg_conv_marker_adaptor.h deleted file mode 100644 index cef4ae99b..000000000 --- a/desmume/src/windows/agg/include/agg_conv_marker_adaptor.h +++ /dev/null @@ -1,60 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_CONV_MARKER_ADAPTOR_INCLUDED -#define AGG_CONV_MARKER_ADAPTOR_INCLUDED - -#include "agg_basics.h" -#include "agg_conv_adaptor_vcgen.h" -#include "agg_vcgen_vertex_sequence.h" - -namespace agg -{ - - //=====================================================conv_marker_adaptor - template - struct conv_marker_adaptor : - public conv_adaptor_vcgen - { - typedef Markers marker_type; - typedef conv_adaptor_vcgen base_type; - - conv_marker_adaptor(VertexSource& vs) : - conv_adaptor_vcgen(vs) - { - } - - void shorten(double s) { base_type::generator().shorten(s); } - double shorten() const { return base_type::generator().shorten(); } - - private: - conv_marker_adaptor(const conv_marker_adaptor&); - const conv_marker_adaptor& - operator = (const conv_marker_adaptor&); - }; - - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_conv_segmentator.h b/desmume/src/windows/agg/include/agg_conv_segmentator.h deleted file mode 100644 index a81c7f152..000000000 --- a/desmume/src/windows/agg/include/agg_conv_segmentator.h +++ /dev/null @@ -1,57 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_CONV_SEGMENTATOR_INCLUDED -#define AGG_CONV_SEGMENTATOR_INCLUDED - -#include "agg_basics.h" -#include "agg_conv_adaptor_vpgen.h" -#include "agg_vpgen_segmentator.h" - -namespace agg -{ - - //========================================================conv_segmentator - template - struct conv_segmentator : public conv_adaptor_vpgen - { - typedef conv_adaptor_vpgen base_type; - - conv_segmentator(VertexSource& vs) : - conv_adaptor_vpgen(vs) {} - - void approximation_scale(double s) { base_type::vpgen().approximation_scale(s); } - double approximation_scale() const { return base_type::vpgen().approximation_scale(); } - - private: - conv_segmentator(const conv_segmentator&); - const conv_segmentator& - operator = (const conv_segmentator&); - }; - - -} - -#endif - diff --git a/desmume/src/windows/agg/include/agg_conv_shorten_path.h b/desmume/src/windows/agg/include/agg_conv_shorten_path.h deleted file mode 100644 index c8c7bcfa6..000000000 --- a/desmume/src/windows/agg/include/agg_conv_shorten_path.h +++ /dev/null @@ -1,59 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_CONV_SHORTEN_PATH_INCLUDED -#define AGG_CONV_SHORTEN_PATH_INCLUDED - -#include "agg_basics.h" -#include "agg_conv_adaptor_vcgen.h" -#include "agg_vcgen_vertex_sequence.h" - -namespace agg -{ - - //=======================================================conv_shorten_path - template class conv_shorten_path : - public conv_adaptor_vcgen - { - public: - typedef conv_adaptor_vcgen base_type; - - conv_shorten_path(VertexSource& vs) : - conv_adaptor_vcgen(vs) - { - } - - void shorten(double s) { base_type::generator().shorten(s); } - double shorten() const { return base_type::generator().shorten(); } - - private: - conv_shorten_path(const conv_shorten_path&); - const conv_shorten_path& - operator = (const conv_shorten_path&); - }; - - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_conv_smooth_poly1.h b/desmume/src/windows/agg/include/agg_conv_smooth_poly1.h deleted file mode 100644 index 73d0e1066..000000000 --- a/desmume/src/windows/agg/include/agg_conv_smooth_poly1.h +++ /dev/null @@ -1,86 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_CONV_SMOOTH_POLY1_INCLUDED -#define AGG_CONV_SMOOTH_POLY1_INCLUDED - -#include "agg_basics.h" -#include "agg_vcgen_smooth_poly1.h" -#include "agg_conv_adaptor_vcgen.h" -#include "agg_conv_curve.h" - - -namespace agg -{ - - //-------------------------------------------------------conv_smooth_poly1 - template - struct conv_smooth_poly1 : - public conv_adaptor_vcgen - { - typedef conv_adaptor_vcgen base_type; - - conv_smooth_poly1(VertexSource& vs) : - conv_adaptor_vcgen(vs) - { - } - - void smooth_value(double v) { base_type::generator().smooth_value(v); } - double smooth_value() const { return base_type::generator().smooth_value(); } - - private: - conv_smooth_poly1(const conv_smooth_poly1&); - const conv_smooth_poly1& - operator = (const conv_smooth_poly1&); - }; - - - - //-------------------------------------------------conv_smooth_poly1_curve - template - struct conv_smooth_poly1_curve : - public conv_curve > - { - conv_smooth_poly1_curve(VertexSource& vs) : - conv_curve >(m_smooth), - m_smooth(vs) - { - } - - void smooth_value(double v) { m_smooth.generator().smooth_value(v); } - double smooth_value() const { return m_smooth.generator().smooth_value(); } - - private: - conv_smooth_poly1_curve(const conv_smooth_poly1_curve&); - const conv_smooth_poly1_curve& - operator = (const conv_smooth_poly1_curve&); - - conv_smooth_poly1 m_smooth; - }; - -} - - -#endif - diff --git a/desmume/src/windows/agg/include/agg_conv_stroke.h b/desmume/src/windows/agg/include/agg_conv_stroke.h deleted file mode 100644 index 73b7801fe..000000000 --- a/desmume/src/windows/agg/include/agg_conv_stroke.h +++ /dev/null @@ -1,79 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_CONV_STROKE_INCLUDED -#define AGG_CONV_STROKE_INCLUDED - -#include "agg_basics.h" -#include "agg_vcgen_stroke.h" -#include "agg_conv_adaptor_vcgen.h" - -namespace agg -{ - - //-------------------------------------------------------------conv_stroke - template - struct conv_stroke : - public conv_adaptor_vcgen - { - typedef Markers marker_type; - typedef conv_adaptor_vcgen base_type; - - conv_stroke(VertexSource& vs) : - conv_adaptor_vcgen(vs) - { - } - - void line_cap(line_cap_e lc) { base_type::generator().line_cap(lc); } - void line_join(line_join_e lj) { base_type::generator().line_join(lj); } - void inner_join(inner_join_e ij) { base_type::generator().inner_join(ij); } - - line_cap_e line_cap() const { return base_type::generator().line_cap(); } - line_join_e line_join() const { return base_type::generator().line_join(); } - inner_join_e inner_join() const { return base_type::generator().inner_join(); } - - void width(double w) { base_type::generator().width(w); } - void miter_limit(double ml) { base_type::generator().miter_limit(ml); } - void miter_limit_theta(double t) { base_type::generator().miter_limit_theta(t); } - void inner_miter_limit(double ml) { base_type::generator().inner_miter_limit(ml); } - void approximation_scale(double as) { base_type::generator().approximation_scale(as); } - - double width() const { return base_type::generator().width(); } - double miter_limit() const { return base_type::generator().miter_limit(); } - double inner_miter_limit() const { return base_type::generator().inner_miter_limit(); } - double approximation_scale() const { return base_type::generator().approximation_scale(); } - - void shorten(double s) { base_type::generator().shorten(s); } - double shorten() const { return base_type::generator().shorten(); } - - private: - conv_stroke(const conv_stroke&); - const conv_stroke& - operator = (const conv_stroke&); - - }; - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_conv_transform.h b/desmume/src/windows/agg/include/agg_conv_transform.h deleted file mode 100644 index 3ed2a9841..000000000 --- a/desmume/src/windows/agg/include/agg_conv_transform.h +++ /dev/null @@ -1,74 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_CONV_TRANSFORM_INCLUDED -#define AGG_CONV_TRANSFORM_INCLUDED - -#include "agg_basics.h" -#include "agg_trans_affine.h" - -namespace agg -{ - - //----------------------------------------------------------conv_transform - template class conv_transform - { - public: - conv_transform(VertexSource& source, const Transformer& tr) : - m_source(&source), m_trans(&tr) {} - void attach(VertexSource& source) { m_source = &source; } - - void rewind(unsigned path_id) - { - m_source->rewind(path_id); - } - - unsigned vertex(double* x, double* y) - { - unsigned cmd = m_source->vertex(x, y); - if(is_vertex(cmd)) - { - m_trans->transform(x, y); - } - return cmd; - } - - void transformer(const Transformer& tr) - { - m_trans = &tr; - } - - private: - conv_transform(const conv_transform&); - const conv_transform& - operator = (const conv_transform&); - - VertexSource* m_source; - const Transformer* m_trans; - }; - - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_conv_unclose_polygon.h b/desmume/src/windows/agg/include/agg_conv_unclose_polygon.h deleted file mode 100644 index 76070e92c..000000000 --- a/desmume/src/windows/agg/include/agg_conv_unclose_polygon.h +++ /dev/null @@ -1,61 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_CONV_UNCLOSE_POLYGON_INCLUDED -#define AGG_CONV_UNCLOSE_POLYGON_INCLUDED - -#include "agg_basics.h" - -namespace agg -{ - //====================================================conv_unclose_polygon - template class conv_unclose_polygon - { - public: - explicit conv_unclose_polygon(VertexSource& vs) : m_source(&vs) {} - void attach(VertexSource& source) { m_source = &source; } - - void rewind(unsigned path_id) - { - m_source->rewind(path_id); - } - - unsigned vertex(double* x, double* y) - { - unsigned cmd = m_source->vertex(x, y); - if(is_end_poly(cmd)) cmd &= ~path_flags_close; - return cmd; - } - - private: - conv_unclose_polygon(const conv_unclose_polygon&); - const conv_unclose_polygon& - operator = (const conv_unclose_polygon&); - - VertexSource* m_source; - }; - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_curves.h b/desmume/src/windows/agg/include/agg_curves.h deleted file mode 100644 index ca2f5bc65..000000000 --- a/desmume/src/windows/agg/include/agg_curves.h +++ /dev/null @@ -1,701 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_CURVES_INCLUDED -#define AGG_CURVES_INCLUDED - -#include "agg_array.h" - -namespace agg -{ - - // See Implementation agg_curves.cpp - - //--------------------------------------------curve_approximation_method_e - enum curve_approximation_method_e - { - curve_inc, - curve_div - }; - - //--------------------------------------------------------------curve3_inc - class curve3_inc - { - public: - curve3_inc() : - m_num_steps(0), m_step(0), m_scale(1.0) { } - - curve3_inc(double x1, double y1, - double x2, double y2, - double x3, double y3) : - m_num_steps(0), m_step(0), m_scale(1.0) - { - init(x1, y1, x2, y2, x3, y3); - } - - void reset() { m_num_steps = 0; m_step = -1; } - void init(double x1, double y1, - double x2, double y2, - double x3, double y3); - - void approximation_method(curve_approximation_method_e) {} - curve_approximation_method_e approximation_method() const { return curve_inc; } - - void approximation_scale(double s); - double approximation_scale() const; - - void angle_tolerance(double) {} - double angle_tolerance() const { return 0.0; } - - void cusp_limit(double) {} - double cusp_limit() const { return 0.0; } - - void rewind(unsigned path_id); - unsigned vertex(double* x, double* y); - - private: - int m_num_steps; - int m_step; - double m_scale; - double m_start_x; - double m_start_y; - double m_end_x; - double m_end_y; - double m_fx; - double m_fy; - double m_dfx; - double m_dfy; - double m_ddfx; - double m_ddfy; - double m_saved_fx; - double m_saved_fy; - double m_saved_dfx; - double m_saved_dfy; - }; - - - - - - //-------------------------------------------------------------curve3_div - class curve3_div - { - public: - curve3_div() : - m_approximation_scale(1.0), - m_angle_tolerance(0.0), - m_count(0) - {} - - curve3_div(double x1, double y1, - double x2, double y2, - double x3, double y3) : - m_approximation_scale(1.0), - m_angle_tolerance(0.0), - m_count(0) - { - init(x1, y1, x2, y2, x3, y3); - } - - void reset() { m_points.remove_all(); m_count = 0; } - void init(double x1, double y1, - double x2, double y2, - double x3, double y3); - - void approximation_method(curve_approximation_method_e) {} - curve_approximation_method_e approximation_method() const { return curve_div; } - - void approximation_scale(double s) { m_approximation_scale = s; } - double approximation_scale() const { return m_approximation_scale; } - - void angle_tolerance(double a) { m_angle_tolerance = a; } - double angle_tolerance() const { return m_angle_tolerance; } - - void cusp_limit(double) {} - double cusp_limit() const { return 0.0; } - - void rewind(unsigned) - { - m_count = 0; - } - - unsigned vertex(double* x, double* y) - { - if(m_count >= m_points.size()) return path_cmd_stop; - const point_d& p = m_points[m_count++]; - *x = p.x; - *y = p.y; - return (m_count == 1) ? path_cmd_move_to : path_cmd_line_to; - } - - private: - void bezier(double x1, double y1, - double x2, double y2, - double x3, double y3); - void recursive_bezier(double x1, double y1, - double x2, double y2, - double x3, double y3, - unsigned level); - - double m_approximation_scale; - double m_distance_tolerance_square; - double m_angle_tolerance; - unsigned m_count; - pod_bvector m_points; - }; - - - - - - - - //-------------------------------------------------------------curve4_points - struct curve4_points - { - double cp[8]; - curve4_points() {} - curve4_points(double x1, double y1, - double x2, double y2, - double x3, double y3, - double x4, double y4) - { - cp[0] = x1; cp[1] = y1; cp[2] = x2; cp[3] = y2; - cp[4] = x3; cp[5] = y3; cp[6] = x4; cp[7] = y4; - } - void init(double x1, double y1, - double x2, double y2, - double x3, double y3, - double x4, double y4) - { - cp[0] = x1; cp[1] = y1; cp[2] = x2; cp[3] = y2; - cp[4] = x3; cp[5] = y3; cp[6] = x4; cp[7] = y4; - } - double operator [] (unsigned i) const { return cp[i]; } - double& operator [] (unsigned i) { return cp[i]; } - }; - - - - //-------------------------------------------------------------curve4_inc - class curve4_inc - { - public: - curve4_inc() : - m_num_steps(0), m_step(0), m_scale(1.0) { } - - curve4_inc(double x1, double y1, - double x2, double y2, - double x3, double y3, - double x4, double y4) : - m_num_steps(0), m_step(0), m_scale(1.0) - { - init(x1, y1, x2, y2, x3, y3, x4, y4); - } - - curve4_inc(const curve4_points& cp) : - m_num_steps(0), m_step(0), m_scale(1.0) - { - init(cp[0], cp[1], cp[2], cp[3], cp[4], cp[5], cp[6], cp[7]); - } - - void reset() { m_num_steps = 0; m_step = -1; } - void init(double x1, double y1, - double x2, double y2, - double x3, double y3, - double x4, double y4); - - void init(const curve4_points& cp) - { - init(cp[0], cp[1], cp[2], cp[3], cp[4], cp[5], cp[6], cp[7]); - } - - void approximation_method(curve_approximation_method_e) {} - curve_approximation_method_e approximation_method() const { return curve_inc; } - - void approximation_scale(double s); - double approximation_scale() const; - - void angle_tolerance(double) {} - double angle_tolerance() const { return 0.0; } - - void cusp_limit(double) {} - double cusp_limit() const { return 0.0; } - - void rewind(unsigned path_id); - unsigned vertex(double* x, double* y); - - private: - int m_num_steps; - int m_step; - double m_scale; - double m_start_x; - double m_start_y; - double m_end_x; - double m_end_y; - double m_fx; - double m_fy; - double m_dfx; - double m_dfy; - double m_ddfx; - double m_ddfy; - double m_dddfx; - double m_dddfy; - double m_saved_fx; - double m_saved_fy; - double m_saved_dfx; - double m_saved_dfy; - double m_saved_ddfx; - double m_saved_ddfy; - }; - - - - //-------------------------------------------------------catrom_to_bezier - inline curve4_points catrom_to_bezier(double x1, double y1, - double x2, double y2, - double x3, double y3, - double x4, double y4) - { - // Trans. matrix Catmull-Rom to Bezier - // - // 0 1 0 0 - // -1/6 1 1/6 0 - // 0 1/6 1 -1/6 - // 0 0 1 0 - // - return curve4_points( - x2, - y2, - (-x1 + 6*x2 + x3) / 6, - (-y1 + 6*y2 + y3) / 6, - ( x2 + 6*x3 - x4) / 6, - ( y2 + 6*y3 - y4) / 6, - x3, - y3); - } - - - //----------------------------------------------------------------------- - inline curve4_points - catrom_to_bezier(const curve4_points& cp) - { - return catrom_to_bezier(cp[0], cp[1], cp[2], cp[3], - cp[4], cp[5], cp[6], cp[7]); - } - - - - //-----------------------------------------------------ubspline_to_bezier - inline curve4_points ubspline_to_bezier(double x1, double y1, - double x2, double y2, - double x3, double y3, - double x4, double y4) - { - // Trans. matrix Uniform BSpline to Bezier - // - // 1/6 4/6 1/6 0 - // 0 4/6 2/6 0 - // 0 2/6 4/6 0 - // 0 1/6 4/6 1/6 - // - return curve4_points( - (x1 + 4*x2 + x3) / 6, - (y1 + 4*y2 + y3) / 6, - (4*x2 + 2*x3) / 6, - (4*y2 + 2*y3) / 6, - (2*x2 + 4*x3) / 6, - (2*y2 + 4*y3) / 6, - (x2 + 4*x3 + x4) / 6, - (y2 + 4*y3 + y4) / 6); - } - - - //----------------------------------------------------------------------- - inline curve4_points - ubspline_to_bezier(const curve4_points& cp) - { - return ubspline_to_bezier(cp[0], cp[1], cp[2], cp[3], - cp[4], cp[5], cp[6], cp[7]); - } - - - - - //------------------------------------------------------hermite_to_bezier - inline curve4_points hermite_to_bezier(double x1, double y1, - double x2, double y2, - double x3, double y3, - double x4, double y4) - { - // Trans. matrix Hermite to Bezier - // - // 1 0 0 0 - // 1 0 1/3 0 - // 0 1 0 -1/3 - // 0 1 0 0 - // - return curve4_points( - x1, - y1, - (3*x1 + x3) / 3, - (3*y1 + y3) / 3, - (3*x2 - x4) / 3, - (3*y2 - y4) / 3, - x2, - y2); - } - - - - //----------------------------------------------------------------------- - inline curve4_points - hermite_to_bezier(const curve4_points& cp) - { - return hermite_to_bezier(cp[0], cp[1], cp[2], cp[3], - cp[4], cp[5], cp[6], cp[7]); - } - - - //-------------------------------------------------------------curve4_div - class curve4_div - { - public: - curve4_div() : - m_approximation_scale(1.0), - m_angle_tolerance(0.0), - m_cusp_limit(0.0), - m_count(0) - {} - - curve4_div(double x1, double y1, - double x2, double y2, - double x3, double y3, - double x4, double y4) : - m_approximation_scale(1.0), - m_angle_tolerance(0.0), - m_cusp_limit(0.0), - m_count(0) - { - init(x1, y1, x2, y2, x3, y3, x4, y4); - } - - curve4_div(const curve4_points& cp) : - m_approximation_scale(1.0), - m_angle_tolerance(0.0), - m_count(0) - { - init(cp[0], cp[1], cp[2], cp[3], cp[4], cp[5], cp[6], cp[7]); - } - - void reset() { m_points.remove_all(); m_count = 0; } - void init(double x1, double y1, - double x2, double y2, - double x3, double y3, - double x4, double y4); - - void init(const curve4_points& cp) - { - init(cp[0], cp[1], cp[2], cp[3], cp[4], cp[5], cp[6], cp[7]); - } - - void approximation_method(curve_approximation_method_e) {} - - curve_approximation_method_e approximation_method() const - { - return curve_div; - } - - void approximation_scale(double s) { m_approximation_scale = s; } - double approximation_scale() const { return m_approximation_scale; } - - void angle_tolerance(double a) { m_angle_tolerance = a; } - double angle_tolerance() const { return m_angle_tolerance; } - - void cusp_limit(double v) - { - m_cusp_limit = (v == 0.0) ? 0.0 : pi - v; - } - - double cusp_limit() const - { - return (m_cusp_limit == 0.0) ? 0.0 : pi - m_cusp_limit; - } - - void rewind(unsigned) - { - m_count = 0; - } - - unsigned vertex(double* x, double* y) - { - if(m_count >= m_points.size()) return path_cmd_stop; - const point_d& p = m_points[m_count++]; - *x = p.x; - *y = p.y; - return (m_count == 1) ? path_cmd_move_to : path_cmd_line_to; - } - - private: - void bezier(double x1, double y1, - double x2, double y2, - double x3, double y3, - double x4, double y4); - - void recursive_bezier(double x1, double y1, - double x2, double y2, - double x3, double y3, - double x4, double y4, - unsigned level); - - double m_approximation_scale; - double m_distance_tolerance_square; - double m_angle_tolerance; - double m_cusp_limit; - unsigned m_count; - pod_bvector m_points; - }; - - - //-----------------------------------------------------------------curve3 - class curve3 - { - public: - curve3() : m_approximation_method(curve_div) {} - curve3(double x1, double y1, - double x2, double y2, - double x3, double y3) : - m_approximation_method(curve_div) - { - init(x1, y1, x2, y2, x3, y3); - } - - void reset() - { - m_curve_inc.reset(); - m_curve_div.reset(); - } - - void init(double x1, double y1, - double x2, double y2, - double x3, double y3) - { - if(m_approximation_method == curve_inc) - { - m_curve_inc.init(x1, y1, x2, y2, x3, y3); - } - else - { - m_curve_div.init(x1, y1, x2, y2, x3, y3); - } - } - - void approximation_method(curve_approximation_method_e v) - { - m_approximation_method = v; - } - - curve_approximation_method_e approximation_method() const - { - return m_approximation_method; - } - - void approximation_scale(double s) - { - m_curve_inc.approximation_scale(s); - m_curve_div.approximation_scale(s); - } - - double approximation_scale() const - { - return m_curve_inc.approximation_scale(); - } - - void angle_tolerance(double a) - { - m_curve_div.angle_tolerance(a); - } - - double angle_tolerance() const - { - return m_curve_div.angle_tolerance(); - } - - void cusp_limit(double v) - { - m_curve_div.cusp_limit(v); - } - - double cusp_limit() const - { - return m_curve_div.cusp_limit(); - } - - void rewind(unsigned path_id) - { - if(m_approximation_method == curve_inc) - { - m_curve_inc.rewind(path_id); - } - else - { - m_curve_div.rewind(path_id); - } - } - - unsigned vertex(double* x, double* y) - { - if(m_approximation_method == curve_inc) - { - return m_curve_inc.vertex(x, y); - } - return m_curve_div.vertex(x, y); - } - - private: - curve3_inc m_curve_inc; - curve3_div m_curve_div; - curve_approximation_method_e m_approximation_method; - }; - - - - - - //-----------------------------------------------------------------curve4 - class curve4 - { - public: - curve4() : m_approximation_method(curve_div) {} - curve4(double x1, double y1, - double x2, double y2, - double x3, double y3, - double x4, double y4) : - m_approximation_method(curve_div) - { - init(x1, y1, x2, y2, x3, y3, x4, y4); - } - - curve4(const curve4_points& cp) : - m_approximation_method(curve_div) - { - init(cp[0], cp[1], cp[2], cp[3], cp[4], cp[5], cp[6], cp[7]); - } - - void reset() - { - m_curve_inc.reset(); - m_curve_div.reset(); - } - - void init(double x1, double y1, - double x2, double y2, - double x3, double y3, - double x4, double y4) - { - if(m_approximation_method == curve_inc) - { - m_curve_inc.init(x1, y1, x2, y2, x3, y3, x4, y4); - } - else - { - m_curve_div.init(x1, y1, x2, y2, x3, y3, x4, y4); - } - } - - void init(const curve4_points& cp) - { - init(cp[0], cp[1], cp[2], cp[3], cp[4], cp[5], cp[6], cp[7]); - } - - void approximation_method(curve_approximation_method_e v) - { - m_approximation_method = v; - } - - curve_approximation_method_e approximation_method() const - { - return m_approximation_method; - } - - void approximation_scale(double s) - { - m_curve_inc.approximation_scale(s); - m_curve_div.approximation_scale(s); - } - double approximation_scale() const { return m_curve_inc.approximation_scale(); } - - void angle_tolerance(double v) - { - m_curve_div.angle_tolerance(v); - } - - double angle_tolerance() const - { - return m_curve_div.angle_tolerance(); - } - - void cusp_limit(double v) - { - m_curve_div.cusp_limit(v); - } - - double cusp_limit() const - { - return m_curve_div.cusp_limit(); - } - - void rewind(unsigned path_id) - { - if(m_approximation_method == curve_inc) - { - m_curve_inc.rewind(path_id); - } - else - { - m_curve_div.rewind(path_id); - } - } - - unsigned vertex(double* x, double* y) - { - if(m_approximation_method == curve_inc) - { - return m_curve_inc.vertex(x, y); - } - return m_curve_div.vertex(x, y); - } - - private: - curve4_inc m_curve_inc; - curve4_div m_curve_div; - curve_approximation_method_e m_approximation_method; - }; - - - - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_dda_line.h b/desmume/src/windows/agg/include/agg_dda_line.h deleted file mode 100644 index 92bb0462a..000000000 --- a/desmume/src/windows/agg/include/agg_dda_line.h +++ /dev/null @@ -1,295 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_DDA_LINE_INCLUDED -#define AGG_DDA_LINE_INCLUDED - -#include -#include "agg_basics.h" - -namespace agg -{ - - //===================================================dda_line_interpolator - template class dda_line_interpolator - { - public: - //-------------------------------------------------------------------- - dda_line_interpolator() {} - - //-------------------------------------------------------------------- - dda_line_interpolator(int y1, int y2, unsigned count) : - m_y(y1), - m_inc(((y2 - y1) << FractionShift) / int(count)), - m_dy(0) - { - } - - //-------------------------------------------------------------------- - void operator ++ () - { - m_dy += m_inc; - } - - //-------------------------------------------------------------------- - void operator -- () - { - m_dy -= m_inc; - } - - //-------------------------------------------------------------------- - void operator += (unsigned n) - { - m_dy += m_inc * n; - } - - //-------------------------------------------------------------------- - void operator -= (unsigned n) - { - m_dy -= m_inc * n; - } - - - //-------------------------------------------------------------------- - int y() const { return m_y + (m_dy >> (FractionShift-YShift)); } - int dy() const { return m_dy; } - - - private: - int m_y; - int m_inc; - int m_dy; - }; - - - - - - //=================================================dda2_line_interpolator - class dda2_line_interpolator - { - public: - typedef int save_data_type; - enum save_size_e { save_size = 2 }; - - //-------------------------------------------------------------------- - dda2_line_interpolator() {} - - //-------------------------------------------- Forward-adjusted line - dda2_line_interpolator(int y1, int y2, int count) : - m_cnt(count <= 0 ? 1 : count), - m_lft((y2 - y1) / m_cnt), - m_rem((y2 - y1) % m_cnt), - m_mod(m_rem), - m_y(y1) - { - if(m_mod <= 0) - { - m_mod += count; - m_rem += count; - m_lft--; - } - m_mod -= count; - } - - //-------------------------------------------- Backward-adjusted line - dda2_line_interpolator(int y1, int y2, int count, int) : - m_cnt(count <= 0 ? 1 : count), - m_lft((y2 - y1) / m_cnt), - m_rem((y2 - y1) % m_cnt), - m_mod(m_rem), - m_y(y1) - { - if(m_mod <= 0) - { - m_mod += count; - m_rem += count; - m_lft--; - } - } - - //-------------------------------------------- Backward-adjusted line - dda2_line_interpolator(int y, int count) : - m_cnt(count <= 0 ? 1 : count), - m_lft(y / m_cnt), - m_rem(y % m_cnt), - m_mod(m_rem), - m_y(0) - { - if(m_mod <= 0) - { - m_mod += count; - m_rem += count; - m_lft--; - } - } - - - //-------------------------------------------------------------------- - void save(save_data_type* data) const - { - data[0] = m_mod; - data[1] = m_y; - } - - //-------------------------------------------------------------------- - void load(const save_data_type* data) - { - m_mod = data[0]; - m_y = data[1]; - } - - //-------------------------------------------------------------------- - void operator++() - { - m_mod += m_rem; - m_y += m_lft; - if(m_mod > 0) - { - m_mod -= m_cnt; - m_y++; - } - } - - //-------------------------------------------------------------------- - void operator--() - { - if(m_mod <= m_rem) - { - m_mod += m_cnt; - m_y--; - } - m_mod -= m_rem; - m_y -= m_lft; - } - - //-------------------------------------------------------------------- - void adjust_forward() - { - m_mod -= m_cnt; - } - - //-------------------------------------------------------------------- - void adjust_backward() - { - m_mod += m_cnt; - } - - //-------------------------------------------------------------------- - int mod() const { return m_mod; } - int rem() const { return m_rem; } - int lft() const { return m_lft; } - - //-------------------------------------------------------------------- - int y() const { return m_y; } - - private: - int m_cnt; - int m_lft; - int m_rem; - int m_mod; - int m_y; - }; - - - - - - - - //---------------------------------------------line_bresenham_interpolator - class line_bresenham_interpolator - { - public: - enum subpixel_scale_e - { - subpixel_shift = 8, - subpixel_scale = 1 << subpixel_shift, - subpixel_mask = subpixel_scale - 1 - }; - - //-------------------------------------------------------------------- - static int line_lr(int v) { return v >> subpixel_shift; } - - //-------------------------------------------------------------------- - line_bresenham_interpolator(int x1, int y1, int x2, int y2) : - m_x1_lr(line_lr(x1)), - m_y1_lr(line_lr(y1)), - m_x2_lr(line_lr(x2)), - m_y2_lr(line_lr(y2)), - m_ver(abs(m_x2_lr - m_x1_lr) < abs(m_y2_lr - m_y1_lr)), - m_len(m_ver ? abs(m_y2_lr - m_y1_lr) : - abs(m_x2_lr - m_x1_lr)), - m_inc(m_ver ? ((y2 > y1) ? 1 : -1) : ((x2 > x1) ? 1 : -1)), - m_interpolator(m_ver ? x1 : y1, - m_ver ? x2 : y2, - m_len) - { - } - - //-------------------------------------------------------------------- - bool is_ver() const { return m_ver; } - unsigned len() const { return m_len; } - int inc() const { return m_inc; } - - //-------------------------------------------------------------------- - void hstep() - { - ++m_interpolator; - m_x1_lr += m_inc; - } - - //-------------------------------------------------------------------- - void vstep() - { - ++m_interpolator; - m_y1_lr += m_inc; - } - - //-------------------------------------------------------------------- - int x1() const { return m_x1_lr; } - int y1() const { return m_y1_lr; } - int x2() const { return line_lr(m_interpolator.y()); } - int y2() const { return line_lr(m_interpolator.y()); } - int x2_hr() const { return m_interpolator.y(); } - int y2_hr() const { return m_interpolator.y(); } - - private: - int m_x1_lr; - int m_y1_lr; - int m_x2_lr; - int m_y2_lr; - bool m_ver; - unsigned m_len; - int m_inc; - dda2_line_interpolator m_interpolator; - - }; - - -} - - - -#endif diff --git a/desmume/src/windows/agg/include/agg_ellipse.h b/desmume/src/windows/agg/include/agg_ellipse.h deleted file mode 100644 index 8693a3c38..000000000 --- a/desmume/src/windows/agg/include/agg_ellipse.h +++ /dev/null @@ -1,128 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_ELLIPSE_INCLUDED -#define AGG_ELLIPSE_INCLUDED - -#include "agg_basics.h" -#include - -namespace agg -{ - - //----------------------------------------------------------------ellipse - class ellipse - { - public: - ellipse() : - m_x(0.0), m_y(0.0), m_rx(1.0), m_ry(1.0), m_scale(1.0), - m_num(4), m_step(0), m_cw(false) {} - - ellipse(double x, double y, double rx, double ry, - unsigned num_steps=0, bool cw=false) : - m_x(x), m_y(y), m_rx(rx), m_ry(ry), m_scale(1.0), - m_num(num_steps), m_step(0), m_cw(cw) - { - if(m_num == 0) calc_num_steps(); - } - - void init(double x, double y, double rx, double ry, - unsigned num_steps=0, bool cw=false); - - void approximation_scale(double scale); - void rewind(unsigned path_id); - unsigned vertex(double* x, double* y); - - private: - void calc_num_steps(); - - double m_x; - double m_y; - double m_rx; - double m_ry; - double m_scale; - unsigned m_num; - unsigned m_step; - bool m_cw; - }; - - //------------------------------------------------------------------------ - inline void ellipse::init(double x, double y, double rx, double ry, - unsigned num_steps, bool cw) - { - m_x = x; - m_y = y; - m_rx = rx; - m_ry = ry; - m_num = num_steps; - m_step = 0; - m_cw = cw; - if(m_num == 0) calc_num_steps(); - } - - //------------------------------------------------------------------------ - inline void ellipse::approximation_scale(double scale) - { - m_scale = scale; - calc_num_steps(); - } - - //------------------------------------------------------------------------ - inline void ellipse::calc_num_steps() - { - double ra = (fabs(m_rx) + fabs(m_ry)) / 2; - double da = acos(ra / (ra + 0.125 / m_scale)) * 2; - m_num = uround(2*pi / da); - } - - //------------------------------------------------------------------------ - inline void ellipse::rewind(unsigned) - { - m_step = 0; - } - - //------------------------------------------------------------------------ - inline unsigned ellipse::vertex(double* x, double* y) - { - if(m_step == m_num) - { - ++m_step; - return path_cmd_end_poly | path_flags_close | path_flags_ccw; - } - if(m_step > m_num) return path_cmd_stop; - double angle = double(m_step) / double(m_num) * 2.0 * pi; - if(m_cw) angle = 2.0 * pi - angle; - *x = m_x + cos(angle) * m_rx; - *y = m_y + sin(angle) * m_ry; - m_step++; - return ((m_step == 1) ? path_cmd_move_to : path_cmd_line_to); - } - -} - - - -#endif - - diff --git a/desmume/src/windows/agg/include/agg_ellipse_bresenham.h b/desmume/src/windows/agg/include/agg_ellipse_bresenham.h deleted file mode 100644 index dfb66e874..000000000 --- a/desmume/src/windows/agg/include/agg_ellipse_bresenham.h +++ /dev/null @@ -1,118 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_ELLIPSE_BRESENHAM_INCLUDED -#define AGG_ELLIPSE_BRESENHAM_INCLUDED - - -#include "agg_basics.h" - - -namespace agg -{ - - //------------------------------------------ellipse_bresenham_interpolator - class ellipse_bresenham_interpolator - { - public: - ellipse_bresenham_interpolator(int rx, int ry) : - m_rx2(rx * rx), - m_ry2(ry * ry), - m_two_rx2(m_rx2 << 1), - m_two_ry2(m_ry2 << 1), - m_dx(0), - m_dy(0), - m_inc_x(0), - m_inc_y(-ry * m_two_rx2), - m_cur_f(0) - {} - - int dx() const { return m_dx; } - int dy() const { return m_dy; } - - void operator++ () - { - int mx, my, mxy, min_m; - int fx, fy, fxy; - - mx = fx = m_cur_f + m_inc_x + m_ry2; - if(mx < 0) mx = -mx; - - my = fy = m_cur_f + m_inc_y + m_rx2; - if(my < 0) my = -my; - - mxy = fxy = m_cur_f + m_inc_x + m_ry2 + m_inc_y + m_rx2; - if(mxy < 0) mxy = -mxy; - - min_m = mx; - bool flag = true; - - if(min_m > my) - { - min_m = my; - flag = false; - } - - m_dx = m_dy = 0; - - if(min_m > mxy) - { - m_inc_x += m_two_ry2; - m_inc_y += m_two_rx2; - m_cur_f = fxy; - m_dx = 1; - m_dy = 1; - return; - } - - if(flag) - { - m_inc_x += m_two_ry2; - m_cur_f = fx; - m_dx = 1; - return; - } - - m_inc_y += m_two_rx2; - m_cur_f = fy; - m_dy = 1; - } - - private: - int m_rx2; - int m_ry2; - int m_two_rx2; - int m_two_ry2; - int m_dx; - int m_dy; - int m_inc_x; - int m_inc_y; - int m_cur_f; - - }; - -} - -#endif - diff --git a/desmume/src/windows/agg/include/agg_embedded_raster_fonts.h b/desmume/src/windows/agg/include/agg_embedded_raster_fonts.h deleted file mode 100644 index 795a90d00..000000000 --- a/desmume/src/windows/agg/include/agg_embedded_raster_fonts.h +++ /dev/null @@ -1,68 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_EMBEDDED_RASTER_FONTS_INCLUDED -#define AGG_EMBEDDED_RASTER_FONTS_INCLUDED - -#include "agg_basics.h" - -namespace agg -{ - extern const int8u gse4x6[]; - extern const int8u gse4x8[]; - extern const int8u gse5x7[]; - extern const int8u gse5x9[]; - extern const int8u gse6x12[]; - extern const int8u gse6x9[]; - extern const int8u gse7x11[]; - extern const int8u gse7x11_bold[]; - extern const int8u gse7x15[]; - extern const int8u gse7x15_bold[]; - extern const int8u gse8x16[]; - extern const int8u gse8x16_bold[]; - extern const int8u mcs11_prop[]; - extern const int8u mcs11_prop_condensed[]; - extern const int8u mcs12_prop[]; - extern const int8u mcs13_prop[]; - extern const int8u mcs5x10_mono[]; - extern const int8u mcs5x11_mono[]; - extern const int8u mcs6x10_mono[]; - extern const int8u mcs6x11_mono[]; - extern const int8u mcs7x12_mono_high[]; - extern const int8u mcs7x12_mono_low[]; - extern const int8u verdana12[]; - extern const int8u verdana12_bold[]; - extern const int8u verdana13[]; - extern const int8u verdana13_bold[]; - extern const int8u verdana14[]; - extern const int8u verdana14_bold[]; - extern const int8u verdana16[]; - extern const int8u verdana16_bold[]; - extern const int8u verdana17[]; - extern const int8u verdana17_bold[]; - extern const int8u verdana18[]; - extern const int8u verdana18_bold[]; -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_font_cache_manager.h b/desmume/src/windows/agg/include/agg_font_cache_manager.h deleted file mode 100644 index 6513868c7..000000000 --- a/desmume/src/windows/agg/include/agg_font_cache_manager.h +++ /dev/null @@ -1,418 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_FONT_CACHE_MANAGER_INCLUDED -#define AGG_FONT_CACHE_MANAGER_INCLUDED - -#include -#include "agg_array.h" - -namespace agg -{ - - //---------------------------------------------------------glyph_data_type - enum glyph_data_type - { - glyph_data_invalid = 0, - glyph_data_mono = 1, - glyph_data_gray8 = 2, - glyph_data_outline = 3 - }; - - - //-------------------------------------------------------------glyph_cache - struct glyph_cache - { - unsigned glyph_index; - int8u* data; - unsigned data_size; - glyph_data_type data_type; - rect_i bounds; - double advance_x; - double advance_y; - }; - - - //--------------------------------------------------------------font_cache - class font_cache - { - public: - enum block_size_e { block_size = 16384-16 }; - - //-------------------------------------------------------------------- - font_cache() : - m_allocator(block_size), - m_font_signature(0) - {} - - //-------------------------------------------------------------------- - void signature(const char* font_signature) - { - m_font_signature = (char*)m_allocator.allocate(strlen(font_signature) + 1); - strcpy(m_font_signature, font_signature); - memset(m_glyphs, 0, sizeof(m_glyphs)); - } - - //-------------------------------------------------------------------- - bool font_is(const char* font_signature) const - { - return strcmp(font_signature, m_font_signature) == 0; - } - - //-------------------------------------------------------------------- - const glyph_cache* find_glyph(unsigned glyph_code) const - { - unsigned msb = (glyph_code >> 8) & 0xFF; - if(m_glyphs[msb]) - { - return m_glyphs[msb][glyph_code & 0xFF]; - } - return 0; - } - - //-------------------------------------------------------------------- - glyph_cache* cache_glyph(unsigned glyph_code, - unsigned glyph_index, - unsigned data_size, - glyph_data_type data_type, - const rect_i& bounds, - double advance_x, - double advance_y) - { - unsigned msb = (glyph_code >> 8) & 0xFF; - if(m_glyphs[msb] == 0) - { - m_glyphs[msb] = - (glyph_cache**)m_allocator.allocate(sizeof(glyph_cache*) * 256, - sizeof(glyph_cache*)); - memset(m_glyphs[msb], 0, sizeof(glyph_cache*) * 256); - } - - unsigned lsb = glyph_code & 0xFF; - if(m_glyphs[msb][lsb]) return 0; // Already exists, do not overwrite - - glyph_cache* glyph = - (glyph_cache*)m_allocator.allocate(sizeof(glyph_cache), - sizeof(double)); - - glyph->glyph_index = glyph_index; - glyph->data = m_allocator.allocate(data_size); - glyph->data_size = data_size; - glyph->data_type = data_type; - glyph->bounds = bounds; - glyph->advance_x = advance_x; - glyph->advance_y = advance_y; - return m_glyphs[msb][lsb] = glyph; - } - - private: - block_allocator m_allocator; - glyph_cache** m_glyphs[256]; - char* m_font_signature; - }; - - - - - - - - //---------------------------------------------------------font_cache_pool - class font_cache_pool - { - public: - //-------------------------------------------------------------------- - ~font_cache_pool() - { - unsigned i; - for(i = 0; i < m_num_fonts; ++i) - { - obj_allocator::deallocate(m_fonts[i]); - } - pod_allocator::deallocate(m_fonts, m_max_fonts); - } - - //-------------------------------------------------------------------- - font_cache_pool(unsigned max_fonts=32) : - m_fonts(pod_allocator::allocate(max_fonts)), - m_max_fonts(max_fonts), - m_num_fonts(0), - m_cur_font(0) - {} - - - //-------------------------------------------------------------------- - void font(const char* font_signature, bool reset_cache = false) - { - int idx = find_font(font_signature); - if(idx >= 0) - { - if(reset_cache) - { - obj_allocator::deallocate(m_fonts[idx]); - m_fonts[idx] = obj_allocator::allocate(); - m_fonts[idx]->signature(font_signature); - } - m_cur_font = m_fonts[idx]; - } - else - { - if(m_num_fonts >= m_max_fonts) - { - obj_allocator::deallocate(m_fonts[0]); - memcpy(m_fonts, - m_fonts + 1, - (m_max_fonts - 1) * sizeof(font_cache*)); - m_num_fonts = m_max_fonts - 1; - } - m_fonts[m_num_fonts] = obj_allocator::allocate(); - m_fonts[m_num_fonts]->signature(font_signature); - m_cur_font = m_fonts[m_num_fonts]; - ++m_num_fonts; - } - } - - //-------------------------------------------------------------------- - const font_cache* font() const - { - return m_cur_font; - } - - //-------------------------------------------------------------------- - const glyph_cache* find_glyph(unsigned glyph_code) const - { - if(m_cur_font) return m_cur_font->find_glyph(glyph_code); - return 0; - } - - //-------------------------------------------------------------------- - glyph_cache* cache_glyph(unsigned glyph_code, - unsigned glyph_index, - unsigned data_size, - glyph_data_type data_type, - const rect_i& bounds, - double advance_x, - double advance_y) - { - if(m_cur_font) - { - return m_cur_font->cache_glyph(glyph_code, - glyph_index, - data_size, - data_type, - bounds, - advance_x, - advance_y); - } - return 0; - } - - - //-------------------------------------------------------------------- - int find_font(const char* font_signature) - { - unsigned i; - for(i = 0; i < m_num_fonts; i++) - { - if(m_fonts[i]->font_is(font_signature)) return int(i); - } - return -1; - } - - private: - font_cache** m_fonts; - unsigned m_max_fonts; - unsigned m_num_fonts; - font_cache* m_cur_font; - }; - - - - - //------------------------------------------------------------------------ - enum glyph_rendering - { - glyph_ren_native_mono, - glyph_ren_native_gray8, - glyph_ren_outline, - glyph_ren_agg_mono, - glyph_ren_agg_gray8 - }; - - - - - //------------------------------------------------------font_cache_manager - template class font_cache_manager - { - public: - typedef FontEngine font_engine_type; - typedef font_cache_manager self_type; - typedef typename font_engine_type::path_adaptor_type path_adaptor_type; - typedef typename font_engine_type::gray8_adaptor_type gray8_adaptor_type; - typedef typename gray8_adaptor_type::embedded_scanline gray8_scanline_type; - typedef typename font_engine_type::mono_adaptor_type mono_adaptor_type; - typedef typename mono_adaptor_type::embedded_scanline mono_scanline_type; - - //-------------------------------------------------------------------- - font_cache_manager(font_engine_type& engine, unsigned max_fonts=32) : - m_fonts(max_fonts), - m_engine(engine), - m_change_stamp(-1), - m_prev_glyph(0), - m_last_glyph(0) - {} - - //-------------------------------------------------------------------- - void reset_last_glyph() - { - m_prev_glyph = m_last_glyph = 0; - } - - //-------------------------------------------------------------------- - const glyph_cache* glyph(unsigned glyph_code) - { - synchronize(); - const glyph_cache* gl = m_fonts.find_glyph(glyph_code); - if(gl) - { - m_prev_glyph = m_last_glyph; - return m_last_glyph = gl; - } - else - { - if(m_engine.prepare_glyph(glyph_code)) - { - m_prev_glyph = m_last_glyph; - m_last_glyph = m_fonts.cache_glyph(glyph_code, - m_engine.glyph_index(), - m_engine.data_size(), - m_engine.data_type(), - m_engine.bounds(), - m_engine.advance_x(), - m_engine.advance_y()); - m_engine.write_glyph_to(m_last_glyph->data); - return m_last_glyph; - } - } - return 0; - } - - //-------------------------------------------------------------------- - void init_embedded_adaptors(const glyph_cache* gl, - double x, double y, - double scale=1.0) - { - if(gl) - { - switch(gl->data_type) - { - default: return; - case glyph_data_mono: - m_mono_adaptor.init(gl->data, gl->data_size, x, y); - break; - - case glyph_data_gray8: - m_gray8_adaptor.init(gl->data, gl->data_size, x, y); - break; - - case glyph_data_outline: - m_path_adaptor.init(gl->data, gl->data_size, x, y, scale); - break; - } - } - } - - - //-------------------------------------------------------------------- - path_adaptor_type& path_adaptor() { return m_path_adaptor; } - gray8_adaptor_type& gray8_adaptor() { return m_gray8_adaptor; } - gray8_scanline_type& gray8_scanline() { return m_gray8_scanline; } - mono_adaptor_type& mono_adaptor() { return m_mono_adaptor; } - mono_scanline_type& mono_scanline() { return m_mono_scanline; } - - //-------------------------------------------------------------------- - const glyph_cache* perv_glyph() const { return m_prev_glyph; } - const glyph_cache* last_glyph() const { return m_last_glyph; } - - //-------------------------------------------------------------------- - bool add_kerning(double* x, double* y) - { - if(m_prev_glyph && m_last_glyph) - { - return m_engine.add_kerning(m_prev_glyph->glyph_index, - m_last_glyph->glyph_index, - x, y); - } - return false; - } - - //-------------------------------------------------------------------- - void precache(unsigned from, unsigned to) - { - for(; from <= to; ++from) glyph(from); - } - - //-------------------------------------------------------------------- - void reset_cache() - { - m_fonts.font(m_engine.font_signature(), true); - m_change_stamp = m_engine.change_stamp(); - m_prev_glyph = m_last_glyph = 0; - } - - private: - //-------------------------------------------------------------------- - font_cache_manager(const self_type&); - const self_type& operator = (const self_type&); - - //-------------------------------------------------------------------- - void synchronize() - { - if(m_change_stamp != m_engine.change_stamp()) - { - m_fonts.font(m_engine.font_signature()); - m_change_stamp = m_engine.change_stamp(); - m_prev_glyph = m_last_glyph = 0; - } - } - - font_cache_pool m_fonts; - font_engine_type& m_engine; - int m_change_stamp; - double m_dx; - double m_dy; - const glyph_cache* m_prev_glyph; - const glyph_cache* m_last_glyph; - path_adaptor_type m_path_adaptor; - gray8_adaptor_type m_gray8_adaptor; - gray8_scanline_type m_gray8_scanline; - mono_adaptor_type m_mono_adaptor; - mono_scanline_type m_mono_scanline; - }; - -} - -#endif - diff --git a/desmume/src/windows/agg/include/agg_gamma_functions.h b/desmume/src/windows/agg/include/agg_gamma_functions.h deleted file mode 100644 index 8c49cfa7e..000000000 --- a/desmume/src/windows/agg/include/agg_gamma_functions.h +++ /dev/null @@ -1,132 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_GAMMA_FUNCTIONS_INCLUDED -#define AGG_GAMMA_FUNCTIONS_INCLUDED - -#include -#include "agg_basics.h" - -namespace agg -{ - //===============================================================gamma_none - struct gamma_none - { - double operator()(double x) const { return x; } - }; - - - //==============================================================gamma_power - class gamma_power - { - public: - gamma_power() : m_gamma(1.0) {} - gamma_power(double g) : m_gamma(g) {} - - void gamma(double g) { m_gamma = g; } - double gamma() const { return m_gamma; } - - double operator() (double x) const - { - return pow(x, m_gamma); - } - - private: - double m_gamma; - }; - - - //==========================================================gamma_threshold - class gamma_threshold - { - public: - gamma_threshold() : m_threshold(0.5) {} - gamma_threshold(double t) : m_threshold(t) {} - - void threshold(double t) { m_threshold = t; } - double threshold() const { return m_threshold; } - - double operator() (double x) const - { - return (x < m_threshold) ? 0.0 : 1.0; - } - - private: - double m_threshold; - }; - - - //============================================================gamma_linear - class gamma_linear - { - public: - gamma_linear() : m_start(0.0), m_end(1.0) {} - gamma_linear(double s, double e) : m_start(s), m_end(e) {} - - void set(double s, double e) { m_start = s; m_end = e; } - void start(double s) { m_start = s; } - void end(double e) { m_end = e; } - double start() const { return m_start; } - double end() const { return m_end; } - - double operator() (double x) const - { - if(x < m_start) return 0.0; - if(x > m_end) return 1.0; - return (x - m_start) / (m_end - m_start); - } - - private: - double m_start; - double m_end; - }; - - - //==========================================================gamma_multiply - class gamma_multiply - { - public: - gamma_multiply() : m_mul(1.0) {} - gamma_multiply(double v) : m_mul(v) {} - - void value(double v) { m_mul = v; } - double value() const { return m_mul; } - - double operator() (double x) const - { - double y = x * m_mul; - if(y > 1.0) y = 1.0; - return y; - } - - private: - double m_mul; - }; - -} - -#endif - - - diff --git a/desmume/src/windows/agg/include/agg_gamma_lut.h b/desmume/src/windows/agg/include/agg_gamma_lut.h deleted file mode 100644 index e9ffbf580..000000000 --- a/desmume/src/windows/agg/include/agg_gamma_lut.h +++ /dev/null @@ -1,130 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_GAMMA_LUT_INCLUDED -#define AGG_GAMMA_LUT_INCLUDED - -#include -#include "agg_basics.h" - -namespace agg -{ - template class gamma_lut - { - public: - typedef gamma_lut self_type; - - enum gamma_scale_e - { - gamma_shift = GammaShift, - gamma_size = 1 << gamma_shift, - gamma_mask = gamma_size - 1 - }; - - enum hi_res_scale_e - { - hi_res_shift = HiResShift, - hi_res_size = 1 << hi_res_shift, - hi_res_mask = hi_res_size - 1 - }; - - ~gamma_lut() - { - pod_allocator::deallocate(m_inv_gamma, hi_res_size); - pod_allocator::deallocate(m_dir_gamma, gamma_size); - } - - gamma_lut() : - m_gamma(1.0), - m_dir_gamma(pod_allocator::allocate(gamma_size)), - m_inv_gamma(pod_allocator::allocate(hi_res_size)) - { - unsigned i; - for(i = 0; i < gamma_size; i++) - { - m_dir_gamma[i] = HiResT(i << (hi_res_shift - gamma_shift)); - } - - for(i = 0; i < hi_res_size; i++) - { - m_inv_gamma[i] = LoResT(i >> (hi_res_shift - gamma_shift)); - } - } - - gamma_lut(double g) : - m_gamma(1.0), - m_dir_gamma(pod_allocator::allocate(gamma_size)), - m_inv_gamma(pod_allocator::allocate(hi_res_size)) - { - gamma(g); - } - - void gamma(double g) - { - m_gamma = g; - - unsigned i; - for(i = 0; i < gamma_size; i++) - { - m_dir_gamma[i] = (HiResT) - uround(pow(i / double(gamma_mask), m_gamma) * double(hi_res_mask)); - } - - double inv_g = 1.0 / g; - for(i = 0; i < hi_res_size; i++) - { - m_inv_gamma[i] = (LoResT) - uround(pow(i / double(hi_res_mask), inv_g) * double(gamma_mask)); - } - } - - double gamma() const - { - return m_gamma; - } - - HiResT dir(LoResT v) const - { - return m_dir_gamma[unsigned(v)]; - } - - LoResT inv(HiResT v) const - { - return m_inv_gamma[unsigned(v)]; - } - - private: - gamma_lut(const self_type&); - const self_type& operator = (const self_type&); - - double m_gamma; - HiResT* m_dir_gamma; - LoResT* m_inv_gamma; - }; -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_glyph_raster_bin.h b/desmume/src/windows/agg/include/agg_glyph_raster_bin.h deleted file mode 100644 index 085f1f21b..000000000 --- a/desmume/src/windows/agg/include/agg_glyph_raster_bin.h +++ /dev/null @@ -1,164 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_GLYPH_RASTER_BIN_INCLUDED -#define AGG_GLYPH_RASTER_BIN_INCLUDED - -#include -#include "agg_basics.h" - -namespace agg -{ - - //========================================================glyph_raster_bin - template class glyph_raster_bin - { - public: - typedef ColorT color_type; - - //-------------------------------------------------------------------- - struct glyph_rect - { - int x1,y1,x2,y2; - double dx, dy; - }; - - //-------------------------------------------------------------------- - glyph_raster_bin(const int8u* font) : - m_font(font), - m_big_endian(false) - { - int t = 1; - if(*(char*)&t == 0) m_big_endian = true; - memset(m_span, 0, sizeof(m_span)); - } - - //-------------------------------------------------------------------- - const int8u* font() const { return m_font; } - void font(const int8u* f) { m_font = f; } - - //-------------------------------------------------------------------- - double height() const { return m_font[0]; } - double base_line() const { return m_font[1]; } - - //-------------------------------------------------------------------- - template - double width(const CharT* str) const - { - unsigned start_char = m_font[2]; - unsigned num_chars = m_font[3]; - - unsigned w = 0; - while(*str) - { - unsigned glyph = *str; - const int8u* bits = m_font + 4 + num_chars * 2 + - value(m_font + 4 + (glyph - start_char) * 2); - w += *bits; - ++str; - } - return w; - } - - //-------------------------------------------------------------------- - void prepare(glyph_rect* r, double x, double y, unsigned glyph, bool flip) - { - unsigned start_char = m_font[2]; - unsigned num_chars = m_font[3]; - - m_bits = m_font + 4 + num_chars * 2 + - value(m_font + 4 + (glyph - start_char) * 2); - - m_glyph_width = *m_bits++; - m_glyph_byte_width = (m_glyph_width + 7) >> 3; - - r->x1 = int(x); - r->x2 = r->x1 + m_glyph_width - 1; - if(flip) - { - r->y1 = int(y) - m_font[0] + m_font[1]; - r->y2 = r->y1 + m_font[0] - 1; - } - else - { - r->y1 = int(y) - m_font[1] + 1; - r->y2 = r->y1 + m_font[0] - 1; - } - r->dx = m_glyph_width; - r->dy = 0; - } - - //-------------------------------------------------------------------- - const cover_type* span(unsigned i) - { - i = m_font[0] - i - 1; - const int8u* bits = m_bits + i * m_glyph_byte_width; - unsigned j; - unsigned val = *bits; - unsigned nb = 0; - for(j = 0; j < m_glyph_width; ++j) - { - m_span[j] = (cover_type)((val & 0x80) ? cover_full : cover_none); - val <<= 1; - if(++nb >= 8) - { - val = *++bits; - nb = 0; - } - } - return m_span; - } - - private: - //-------------------------------------------------------------------- - int16u value(const int8u* p) const - { - int16u v; - if(m_big_endian) - { - *(int8u*)&v = p[1]; - *((int8u*)&v + 1) = p[0]; - } - else - { - *(int8u*)&v = p[0]; - *((int8u*)&v + 1) = p[1]; - } - return v; - } - - - //-------------------------------------------------------------------- - const int8u* m_font; - bool m_big_endian; - cover_type m_span[32]; - const int8u* m_bits; - unsigned m_glyph_width; - unsigned m_glyph_byte_width; - }; - - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_gradient_lut.h b/desmume/src/windows/agg/include/agg_gradient_lut.h deleted file mode 100644 index 905780bd3..000000000 --- a/desmume/src/windows/agg/include/agg_gradient_lut.h +++ /dev/null @@ -1,253 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_GRADIENT_LUT_INCLUDED -#define AGG_GRADIENT_LUT_INCLUDED - -#include "agg_array.h" -#include "agg_dda_line.h" -#include "agg_color_rgba.h" -#include "agg_color_gray.h" - -namespace agg -{ - - //======================================================color_interpolator - template struct color_interpolator - { - public: - typedef ColorT color_type; - - color_interpolator(const color_type& c1, - const color_type& c2, - unsigned len) : - m_c1(c1), - m_c2(c2), - m_len(len), - m_count(0) - {} - - void operator ++ () - { - ++m_count; - } - - color_type color() const - { - return m_c1.gradient(m_c2, double(m_count) / m_len); - } - - private: - color_type m_c1; - color_type m_c2; - unsigned m_len; - unsigned m_count; - }; - - //======================================================================== - // Fast specialization for rgba8 - template<> struct color_interpolator - { - public: - typedef rgba8 color_type; - - color_interpolator(const color_type& c1, - const color_type& c2, - unsigned len) : - r(c1.r, c2.r, len), - g(c1.g, c2.g, len), - b(c1.b, c2.b, len), - a(c1.a, c2.a, len) - {} - - void operator ++ () - { - ++r; ++g; ++b; ++a; - } - - color_type color() const - { - return color_type(r.y(), g.y(), b.y(), a.y()); - } - - private: - agg::dda_line_interpolator<14> r, g, b, a; - }; - - //======================================================================== - // Fast specialization for gray8 - template<> struct color_interpolator - { - public: - typedef gray8 color_type; - - color_interpolator(const color_type& c1, - const color_type& c2, - unsigned len) : - v(c1.v, c2.v, len), - a(c1.a, c2.a, len) - {} - - void operator ++ () - { - ++v; ++a; - } - - color_type color() const - { - return color_type(v.y(), a.y()); - } - - private: - agg::dda_line_interpolator<14> v,a; - }; - - //============================================================gradient_lut - template class gradient_lut - { - public: - typedef ColorInterpolator interpolator_type; - typedef typename interpolator_type::color_type color_type; - enum { color_lut_size = ColorLutSize }; - - //-------------------------------------------------------------------- - gradient_lut() : m_color_lut(color_lut_size) {} - - // Build Gradient Lut - // First, call remove_all(), then add_color() at least twice, - // then build_lut(). Argument "offset" in add_color must be - // in range [0...1] and defines a color stop as it is described - // in SVG specification, section Gradients and Patterns. - // The simplest linear gradient is: - // gradient_lut.add_color(0.0, start_color); - // gradient_lut.add_color(1.0, end_color); - //-------------------------------------------------------------------- - void remove_all(); - void add_color(double offset, const color_type& color); - void build_lut(); - - // Size-index Interface. This class can be used directly as the - // ColorF in span_gradient. All it needs is two access methods - // size() and operator []. - //-------------------------------------------------------------------- - static unsigned size() - { - return color_lut_size; - } - const color_type& operator [] (unsigned i) const - { - return m_color_lut[i]; - } - - private: - //-------------------------------------------------------------------- - struct color_point - { - double offset; - color_type color; - - color_point() {} - color_point(double off, const color_type& c) : - offset(off), color(c) - { - if(offset < 0.0) offset = 0.0; - if(offset > 1.0) offset = 1.0; - } - }; - typedef agg::pod_bvector color_profile_type; - typedef agg::pod_array color_lut_type; - - static bool offset_less(const color_point& a, const color_point& b) - { - return a.offset < b.offset; - } - static bool offset_equal(const color_point& a, const color_point& b) - { - return a.offset == b.offset; - } - - //-------------------------------------------------------------------- - color_profile_type m_color_profile; - color_lut_type m_color_lut; - }; - - - - //------------------------------------------------------------------------ - template - void gradient_lut::remove_all() - { - m_color_profile.remove_all(); - } - - //------------------------------------------------------------------------ - template - void gradient_lut::add_color(double offset, const color_type& color) - { - m_color_profile.add(color_point(offset, color)); - } - - //------------------------------------------------------------------------ - template - void gradient_lut::build_lut() - { - quick_sort(m_color_profile, offset_less); - m_color_profile.cut_at(remove_duplicates(m_color_profile, offset_equal)); - if(m_color_profile.size() >= 2) - { - unsigned i; - unsigned start = uround(m_color_profile[0].offset * color_lut_size); - unsigned end; - color_type c = m_color_profile[0].color; - for(i = 0; i < start; i++) - { - m_color_lut[i] = c; - } - for(i = 1; i < m_color_profile.size(); i++) - { - end = uround(m_color_profile[i].offset * color_lut_size); - interpolator_type ci(m_color_profile[i-1].color, - m_color_profile[i ].color, - end - start + 1); - while(start < end) - { - m_color_lut[start] = ci.color(); - ++ci; - ++start; - } - } - c = m_color_profile.last().color; - for(; end < m_color_lut.size(); end++) - { - m_color_lut[end] = c; - } - } - } -} - - - - -#endif diff --git a/desmume/src/windows/agg/include/agg_gsv_text.h b/desmume/src/windows/agg/include/agg_gsv_text.h deleted file mode 100644 index adcefb430..000000000 --- a/desmume/src/windows/agg/include/agg_gsv_text.h +++ /dev/null @@ -1,158 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_GSV_TEXT_INCLUDED -#define AGG_GSV_TEXT_INCLUDED - -#include "agg_array.h" -#include "agg_conv_stroke.h" -#include "agg_conv_transform.h" - -namespace agg -{ - - - //---------------------------------------------------------------gsv_text - // - // See Implementation agg_gsv_text.cpp - // - class gsv_text - { - enum status - { - initial, - next_char, - start_glyph, - glyph - }; - - public: - gsv_text(); - - void font(const void* font); - void flip(bool flip_y) { m_flip = flip_y; } - void load_font(const char* file); - void size(double height, double width=0.0); - void space(double space); - void line_space(double line_space); - void start_point(double x, double y); - void text(const char* text); - - double text_width(); - - void rewind(unsigned path_id); - unsigned vertex(double* x, double* y); - - private: - // not supposed to be copied - gsv_text(const gsv_text&); - const gsv_text& operator = (const gsv_text&); - - int16u value(const int8u* p) const - { - int16u v; - if(m_big_endian) - { - *(int8u*)&v = p[1]; - *((int8u*)&v + 1) = p[0]; - } - else - { - *(int8u*)&v = p[0]; - *((int8u*)&v + 1) = p[1]; - } - return v; - } - - private: - double m_x; - double m_y; - double m_start_x; - double m_width; - double m_height; - double m_space; - double m_line_space; - char m_chr[2]; - char* m_text; - pod_array m_text_buf; - char* m_cur_chr; - const void* m_font; - pod_array m_loaded_font; - status m_status; - bool m_big_endian; - bool m_flip; - int8u* m_indices; - int8* m_glyphs; - int8* m_bglyph; - int8* m_eglyph; - double m_w; - double m_h; - }; - - - - - //--------------------------------------------------------gsv_text_outline - template class gsv_text_outline - { - public: - gsv_text_outline(gsv_text& text, const Transformer& trans) : - m_polyline(text), - m_trans(m_polyline, trans) - { - } - - void width(double w) - { - m_polyline.width(w); - } - - void transformer(const Transformer* trans) - { - m_trans->transformer(trans); - } - - void rewind(unsigned path_id) - { - m_trans.rewind(path_id); - m_polyline.line_join(round_join); - m_polyline.line_cap(round_cap); - } - - unsigned vertex(double* x, double* y) - { - return m_trans.vertex(x, y); - } - - private: - conv_stroke m_polyline; - conv_transform, Transformer> m_trans; - }; - - - -} - - -#endif diff --git a/desmume/src/windows/agg/include/agg_image_accessors.h b/desmume/src/windows/agg/include/agg_image_accessors.h deleted file mode 100644 index b4d72a28a..000000000 --- a/desmume/src/windows/agg/include/agg_image_accessors.h +++ /dev/null @@ -1,490 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_IMAGE_ACCESSORS_INCLUDED -#define AGG_IMAGE_ACCESSORS_INCLUDED - -#include "agg_basics.h" - -namespace agg -{ - - //-----------------------------------------------------image_accessor_clip - template class image_accessor_clip - { - public: - typedef PixFmt pixfmt_type; - typedef typename pixfmt_type::color_type color_type; - typedef typename pixfmt_type::order_type order_type; - typedef typename pixfmt_type::value_type value_type; - enum pix_width_e { pix_width = pixfmt_type::pix_width }; - - image_accessor_clip() {} - explicit image_accessor_clip(const pixfmt_type& pixf, - const color_type& bk) : - m_pixf(&pixf) - { - pixfmt_type::make_pix(m_bk_buf, bk); - } - - void attach(const pixfmt_type& pixf) - { - m_pixf = &pixf; - } - - void background_color(const color_type& bk) - { - pixfmt_type::make_pix(m_bk_buf, bk); - } - - private: - AGG_INLINE const int8u* pixel() const - { - if(m_y >= 0 && m_y < (int)m_pixf->height() && - m_x >= 0 && m_x < (int)m_pixf->width()) - { - return m_pixf->pix_ptr(m_x, m_y); - } - return m_bk_buf; - } - - public: - AGG_INLINE const int8u* span(int x, int y, unsigned len) - { - m_x = m_x0 = x; - m_y = y; - if(y >= 0 && y < (int)m_pixf->height() && - x >= 0 && x+(int)len <= (int)m_pixf->width()) - { - return m_pix_ptr = m_pixf->pix_ptr(x, y); - } - m_pix_ptr = 0; - return pixel(); - } - - AGG_INLINE const int8u* next_x() - { - if(m_pix_ptr) return m_pix_ptr += pix_width; - ++m_x; - return pixel(); - } - - AGG_INLINE const int8u* next_y() - { - ++m_y; - m_x = m_x0; - if(m_pix_ptr && - m_y >= 0 && m_y < (int)m_pixf->height()) - { - return m_pix_ptr = m_pixf->pix_ptr(m_x, m_y); - } - m_pix_ptr = 0; - return pixel(); - } - - private: - const pixfmt_type* m_pixf; - int8u m_bk_buf[4]; - int m_x, m_x0, m_y; - const int8u* m_pix_ptr; - }; - - - - - //--------------------------------------------------image_accessor_no_clip - template class image_accessor_no_clip - { - public: - typedef PixFmt pixfmt_type; - typedef typename pixfmt_type::color_type color_type; - typedef typename pixfmt_type::order_type order_type; - typedef typename pixfmt_type::value_type value_type; - enum pix_width_e { pix_width = pixfmt_type::pix_width }; - - image_accessor_no_clip() {} - explicit image_accessor_no_clip(const pixfmt_type& pixf) : - m_pixf(&pixf) - {} - - void attach(const pixfmt_type& pixf) - { - m_pixf = &pixf; - } - - AGG_INLINE const int8u* span(int x, int y, unsigned) - { - m_x = x; - m_y = y; - return m_pix_ptr = m_pixf->pix_ptr(x, y); - } - - AGG_INLINE const int8u* next_x() - { - return m_pix_ptr += pix_width; - } - - AGG_INLINE const int8u* next_y() - { - ++m_y; - return m_pix_ptr = m_pixf->pix_ptr(m_x, m_y); - } - - private: - const pixfmt_type* m_pixf; - int m_x, m_y; - const int8u* m_pix_ptr; - }; - - - - - //----------------------------------------------------image_accessor_clone - template class image_accessor_clone - { - public: - typedef PixFmt pixfmt_type; - typedef typename pixfmt_type::color_type color_type; - typedef typename pixfmt_type::order_type order_type; - typedef typename pixfmt_type::value_type value_type; - enum pix_width_e { pix_width = pixfmt_type::pix_width }; - - image_accessor_clone() {} - explicit image_accessor_clone(const pixfmt_type& pixf) : - m_pixf(&pixf) - {} - - void attach(const pixfmt_type& pixf) - { - m_pixf = &pixf; - } - - private: - AGG_INLINE const int8u* pixel() const - { - register int x = m_x; - register int y = m_y; - if(x < 0) x = 0; - if(y < 0) y = 0; - if(x >= (int)m_pixf->width()) x = m_pixf->width() - 1; - if(y >= (int)m_pixf->height()) y = m_pixf->height() - 1; - return m_pixf->pix_ptr(x, y); - } - - public: - AGG_INLINE const int8u* span(int x, int y, unsigned len) - { - m_x = m_x0 = x; - m_y = y; - if(y >= 0 && y < (int)m_pixf->height() && - x >= 0 && x+len <= (int)m_pixf->width()) - { - return m_pix_ptr = m_pixf->pix_ptr(x, y); - } - m_pix_ptr = 0; - return pixel(); - } - - AGG_INLINE const int8u* next_x() - { - if(m_pix_ptr) return m_pix_ptr += pix_width; - ++m_x; - return pixel(); - } - - AGG_INLINE const int8u* next_y() - { - ++m_y; - m_x = m_x0; - if(m_pix_ptr && - m_y >= 0 && m_y < (int)m_pixf->height()) - { - return m_pix_ptr = m_pixf->pix_ptr(m_x, m_y); - } - m_pix_ptr = 0; - return pixel(); - } - - private: - const pixfmt_type* m_pixf; - int m_x, m_x0, m_y; - const int8u* m_pix_ptr; - }; - - - - - - //-----------------------------------------------------image_accessor_wrap - template class image_accessor_wrap - { - public: - typedef PixFmt pixfmt_type; - typedef typename pixfmt_type::color_type color_type; - typedef typename pixfmt_type::order_type order_type; - typedef typename pixfmt_type::value_type value_type; - enum pix_width_e { pix_width = pixfmt_type::pix_width }; - - image_accessor_wrap() {} - explicit image_accessor_wrap(const pixfmt_type& pixf) : - m_pixf(&pixf), - m_wrap_x(pixf.width()), - m_wrap_y(pixf.height()) - {} - - void attach(const pixfmt_type& pixf) - { - m_pixf = &pixf; - } - - AGG_INLINE const int8u* span(int x, int y, unsigned) - { - m_x = x; - m_row_ptr = m_pixf->row_ptr(m_wrap_y(y)); - return m_row_ptr + m_wrap_x(x) * pix_width; - } - - AGG_INLINE const int8u* next_x() - { - int x = ++m_wrap_x; - return m_row_ptr + x * pix_width; - } - - AGG_INLINE const int8u* next_y() - { - m_row_ptr = m_pixf->row_ptr(++m_wrap_y); - return m_row_ptr + m_wrap_x(m_x) * pix_width; - } - - private: - const pixfmt_type* m_pixf; - const int8u* m_row_ptr; - int m_x; - WrapX m_wrap_x; - WrapY m_wrap_y; - }; - - - - - //--------------------------------------------------------wrap_mode_repeat - class wrap_mode_repeat - { - public: - wrap_mode_repeat() {} - wrap_mode_repeat(unsigned size) : - m_size(size), - m_add(size * (0x3FFFFFFF / size)), - m_value(0) - {} - - AGG_INLINE unsigned operator() (int v) - { - return m_value = (unsigned(v) + m_add) % m_size; - } - - AGG_INLINE unsigned operator++ () - { - ++m_value; - if(m_value >= m_size) m_value = 0; - return m_value; - } - private: - unsigned m_size; - unsigned m_add; - unsigned m_value; - }; - - - //---------------------------------------------------wrap_mode_repeat_pow2 - class wrap_mode_repeat_pow2 - { - public: - wrap_mode_repeat_pow2() {} - wrap_mode_repeat_pow2(unsigned size) : m_value(0) - { - m_mask = 1; - while(m_mask < size) m_mask = (m_mask << 1) | 1; - m_mask >>= 1; - } - AGG_INLINE unsigned operator() (int v) - { - return m_value = unsigned(v) & m_mask; - } - AGG_INLINE unsigned operator++ () - { - ++m_value; - if(m_value > m_mask) m_value = 0; - return m_value; - } - private: - unsigned m_mask; - unsigned m_value; - }; - - - //----------------------------------------------wrap_mode_repeat_auto_pow2 - class wrap_mode_repeat_auto_pow2 - { - public: - wrap_mode_repeat_auto_pow2() {} - wrap_mode_repeat_auto_pow2(unsigned size) : - m_size(size), - m_add(size * (0x3FFFFFFF / size)), - m_mask((m_size & (m_size-1)) ? 0 : m_size-1), - m_value(0) - {} - - AGG_INLINE unsigned operator() (int v) - { - if(m_mask) return m_value = unsigned(v) & m_mask; - return m_value = (unsigned(v) + m_add) % m_size; - } - AGG_INLINE unsigned operator++ () - { - ++m_value; - if(m_value >= m_size) m_value = 0; - return m_value; - } - - private: - unsigned m_size; - unsigned m_add; - unsigned m_mask; - unsigned m_value; - }; - - - //-------------------------------------------------------wrap_mode_reflect - class wrap_mode_reflect - { - public: - wrap_mode_reflect() {} - wrap_mode_reflect(unsigned size) : - m_size(size), - m_size2(size * 2), - m_add(m_size2 * (0x3FFFFFFF / m_size2)), - m_value(0) - {} - - AGG_INLINE unsigned operator() (int v) - { - m_value = (unsigned(v) + m_add) % m_size2; - if(m_value >= m_size) return m_size2 - m_value - 1; - return m_value; - } - - AGG_INLINE unsigned operator++ () - { - ++m_value; - if(m_value >= m_size2) m_value = 0; - if(m_value >= m_size) return m_size2 - m_value - 1; - return m_value; - } - private: - unsigned m_size; - unsigned m_size2; - unsigned m_add; - unsigned m_value; - }; - - - - //--------------------------------------------------wrap_mode_reflect_pow2 - class wrap_mode_reflect_pow2 - { - public: - wrap_mode_reflect_pow2() {} - wrap_mode_reflect_pow2(unsigned size) : m_value(0) - { - m_mask = 1; - m_size = 1; - while(m_mask < size) - { - m_mask = (m_mask << 1) | 1; - m_size <<= 1; - } - } - AGG_INLINE unsigned operator() (int v) - { - m_value = unsigned(v) & m_mask; - if(m_value >= m_size) return m_mask - m_value; - return m_value; - } - AGG_INLINE unsigned operator++ () - { - ++m_value; - m_value &= m_mask; - if(m_value >= m_size) return m_mask - m_value; - return m_value; - } - private: - unsigned m_size; - unsigned m_mask; - unsigned m_value; - }; - - - - //---------------------------------------------wrap_mode_reflect_auto_pow2 - class wrap_mode_reflect_auto_pow2 - { - public: - wrap_mode_reflect_auto_pow2() {} - wrap_mode_reflect_auto_pow2(unsigned size) : - m_size(size), - m_size2(size * 2), - m_add(m_size2 * (0x3FFFFFFF / m_size2)), - m_mask((m_size2 & (m_size2-1)) ? 0 : m_size2-1), - m_value(0) - {} - - AGG_INLINE unsigned operator() (int v) - { - m_value = m_mask ? unsigned(v) & m_mask : - (unsigned(v) + m_add) % m_size2; - if(m_value >= m_size) return m_size2 - m_value - 1; - return m_value; - } - AGG_INLINE unsigned operator++ () - { - ++m_value; - if(m_value >= m_size2) m_value = 0; - if(m_value >= m_size) return m_size2 - m_value - 1; - return m_value; - } - - private: - unsigned m_size; - unsigned m_size2; - unsigned m_add; - unsigned m_mask; - unsigned m_value; - }; - - -} - - -#endif diff --git a/desmume/src/windows/agg/include/agg_image_filters.h b/desmume/src/windows/agg/include/agg_image_filters.h deleted file mode 100644 index e66f8a782..000000000 --- a/desmume/src/windows/agg/include/agg_image_filters.h +++ /dev/null @@ -1,453 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_IMAGE_FILTERS_INCLUDED -#define AGG_IMAGE_FILTERS_INCLUDED - -#include "agg_array.h" -#include "agg_math.h" - -namespace agg -{ - - // See Implementation agg_image_filters.cpp - - enum image_filter_scale_e - { - image_filter_shift = 14, //----image_filter_shift - image_filter_scale = 1 << image_filter_shift, //----image_filter_scale - image_filter_mask = image_filter_scale - 1 //----image_filter_mask - }; - - enum image_subpixel_scale_e - { - image_subpixel_shift = 8, //----image_subpixel_shift - image_subpixel_scale = 1 << image_subpixel_shift, //----image_subpixel_scale - image_subpixel_mask = image_subpixel_scale - 1 //----image_subpixel_mask - }; - - - //-----------------------------------------------------image_filter_lut - class image_filter_lut - { - public: - template void calculate(const FilterF& filter, - bool normalization=true) - { - double r = filter.radius(); - realloc_lut(r); - unsigned i; - unsigned pivot = diameter() << (image_subpixel_shift - 1); - for(i = 0; i < pivot; i++) - { - double x = double(i) / double(image_subpixel_scale); - double y = filter.calc_weight(x); - m_weight_array[pivot + i] = - m_weight_array[pivot - i] = (int16)iround(y * image_filter_scale); - } - unsigned end = (diameter() << image_subpixel_shift) - 1; - m_weight_array[0] = m_weight_array[end]; - if(normalization) - { - normalize(); - } - } - - image_filter_lut() : m_radius(0), m_diameter(0), m_start(0) {} - - template image_filter_lut(const FilterF& filter, - bool normalization=true) - { - calculate(filter, normalization); - } - - double radius() const { return m_radius; } - unsigned diameter() const { return m_diameter; } - int start() const { return m_start; } - const int16* weight_array() const { return &m_weight_array[0]; } - void normalize(); - - private: - void realloc_lut(double radius); - image_filter_lut(const image_filter_lut&); - const image_filter_lut& operator = (const image_filter_lut&); - - double m_radius; - unsigned m_diameter; - int m_start; - pod_array m_weight_array; - }; - - - - //--------------------------------------------------------image_filter - template class image_filter : public image_filter_lut - { - public: - image_filter() - { - calculate(m_filter_function); - } - private: - FilterF m_filter_function; - }; - - - //-----------------------------------------------image_filter_bilinear - struct image_filter_bilinear - { - static double radius() { return 1.0; } - static double calc_weight(double x) - { - return 1.0 - x; - } - }; - - - //-----------------------------------------------image_filter_hanning - struct image_filter_hanning - { - static double radius() { return 1.0; } - static double calc_weight(double x) - { - return 0.5 + 0.5 * cos(pi * x); - } - }; - - - //-----------------------------------------------image_filter_hamming - struct image_filter_hamming - { - static double radius() { return 1.0; } - static double calc_weight(double x) - { - return 0.54 + 0.46 * cos(pi * x); - } - }; - - //-----------------------------------------------image_filter_hermite - struct image_filter_hermite - { - static double radius() { return 1.0; } - static double calc_weight(double x) - { - return (2.0 * x - 3.0) * x * x + 1.0; - } - }; - - //------------------------------------------------image_filter_quadric - struct image_filter_quadric - { - static double radius() { return 1.5; } - static double calc_weight(double x) - { - double t; - if(x < 0.5) return 0.75 - x * x; - if(x < 1.5) {t = x - 1.5; return 0.5 * t * t;} - return 0.0; - } - }; - - //------------------------------------------------image_filter_bicubic - class image_filter_bicubic - { - static double pow3(double x) - { - return (x <= 0.0) ? 0.0 : x * x * x; - } - - public: - static double radius() { return 2.0; } - static double calc_weight(double x) - { - return - (1.0/6.0) * - (pow3(x + 2) - 4 * pow3(x + 1) + 6 * pow3(x) - 4 * pow3(x - 1)); - } - }; - - //-------------------------------------------------image_filter_kaiser - class image_filter_kaiser - { - double a; - double i0a; - double epsilon; - - public: - image_filter_kaiser(double b = 6.33) : - a(b), epsilon(1e-12) - { - i0a = 1.0 / bessel_i0(b); - } - - static double radius() { return 1.0; } - double calc_weight(double x) const - { - return bessel_i0(a * sqrt(1. - x * x)) * i0a; - } - - private: - double bessel_i0(double x) const - { - int i; - double sum, y, t; - - sum = 1.; - y = x * x / 4.; - t = y; - - for(i = 2; t > epsilon; i++) - { - sum += t; - t *= (double)y / (i * i); - } - return sum; - } - }; - - //----------------------------------------------image_filter_catrom - struct image_filter_catrom - { - static double radius() { return 2.0; } - static double calc_weight(double x) - { - if(x < 1.0) return 0.5 * (2.0 + x * x * (-5.0 + x * 3.0)); - if(x < 2.0) return 0.5 * (4.0 + x * (-8.0 + x * (5.0 - x))); - return 0.; - } - }; - - //---------------------------------------------image_filter_mitchell - class image_filter_mitchell - { - double p0, p2, p3; - double q0, q1, q2, q3; - - public: - image_filter_mitchell(double b = 1.0/3.0, double c = 1.0/3.0) : - p0((6.0 - 2.0 * b) / 6.0), - p2((-18.0 + 12.0 * b + 6.0 * c) / 6.0), - p3((12.0 - 9.0 * b - 6.0 * c) / 6.0), - q0((8.0 * b + 24.0 * c) / 6.0), - q1((-12.0 * b - 48.0 * c) / 6.0), - q2((6.0 * b + 30.0 * c) / 6.0), - q3((-b - 6.0 * c) / 6.0) - {} - - static double radius() { return 2.0; } - double calc_weight(double x) const - { - if(x < 1.0) return p0 + x * x * (p2 + x * p3); - if(x < 2.0) return q0 + x * (q1 + x * (q2 + x * q3)); - return 0.0; - } - }; - - - //----------------------------------------------image_filter_spline16 - struct image_filter_spline16 - { - static double radius() { return 2.0; } - static double calc_weight(double x) - { - if(x < 1.0) - { - return ((x - 9.0/5.0 ) * x - 1.0/5.0 ) * x + 1.0; - } - return ((-1.0/3.0 * (x-1) + 4.0/5.0) * (x-1) - 7.0/15.0 ) * (x-1); - } - }; - - - //---------------------------------------------image_filter_spline36 - struct image_filter_spline36 - { - static double radius() { return 3.0; } - static double calc_weight(double x) - { - if(x < 1.0) - { - return ((13.0/11.0 * x - 453.0/209.0) * x - 3.0/209.0) * x + 1.0; - } - if(x < 2.0) - { - return ((-6.0/11.0 * (x-1) + 270.0/209.0) * (x-1) - 156.0/ 209.0) * (x-1); - } - return ((1.0/11.0 * (x-2) - 45.0/209.0) * (x-2) + 26.0/209.0) * (x-2); - } - }; - - - //----------------------------------------------image_filter_gaussian - struct image_filter_gaussian - { - static double radius() { return 2.0; } - static double calc_weight(double x) - { - return exp(-2.0 * x * x) * sqrt(2.0 / pi); - } - }; - - - //------------------------------------------------image_filter_bessel - struct image_filter_bessel - { - static double radius() { return 3.2383; } - static double calc_weight(double x) - { - return (x == 0.0) ? pi / 4.0 : besj(pi * x, 1) / (2.0 * x); - } - }; - - - //-------------------------------------------------image_filter_sinc - class image_filter_sinc - { - public: - image_filter_sinc(double r) : m_radius(r < 2.0 ? 2.0 : r) {} - double radius() const { return m_radius; } - double calc_weight(double x) const - { - if(x == 0.0) return 1.0; - x *= pi; - return sin(x) / x; - } - private: - double m_radius; - }; - - - //-----------------------------------------------image_filter_lanczos - class image_filter_lanczos - { - public: - image_filter_lanczos(double r) : m_radius(r < 2.0 ? 2.0 : r) {} - double radius() const { return m_radius; } - double calc_weight(double x) const - { - if(x == 0.0) return 1.0; - if(x > m_radius) return 0.0; - x *= pi; - double xr = x / m_radius; - return (sin(x) / x) * (sin(xr) / xr); - } - private: - double m_radius; - }; - - - //----------------------------------------------image_filter_blackman - class image_filter_blackman - { - public: - image_filter_blackman(double r) : m_radius(r < 2.0 ? 2.0 : r) {} - double radius() const { return m_radius; } - double calc_weight(double x) const - { - if(x == 0.0) return 1.0; - if(x > m_radius) return 0.0; - x *= pi; - double xr = x / m_radius; - return (sin(x) / x) * (0.42 + 0.5*cos(xr) + 0.08*cos(2*xr)); - } - private: - double m_radius; - }; - - //------------------------------------------------image_filter_sinc36 - class image_filter_sinc36 : public image_filter_sinc - { public: image_filter_sinc36() : image_filter_sinc(3.0){} }; - - //------------------------------------------------image_filter_sinc64 - class image_filter_sinc64 : public image_filter_sinc - { public: image_filter_sinc64() : image_filter_sinc(4.0){} }; - - //-----------------------------------------------image_filter_sinc100 - class image_filter_sinc100 : public image_filter_sinc - { public: image_filter_sinc100() : image_filter_sinc(5.0){} }; - - //-----------------------------------------------image_filter_sinc144 - class image_filter_sinc144 : public image_filter_sinc - { public: image_filter_sinc144() : image_filter_sinc(6.0){} }; - - //-----------------------------------------------image_filter_sinc196 - class image_filter_sinc196 : public image_filter_sinc - { public: image_filter_sinc196() : image_filter_sinc(7.0){} }; - - //-----------------------------------------------image_filter_sinc256 - class image_filter_sinc256 : public image_filter_sinc - { public: image_filter_sinc256() : image_filter_sinc(8.0){} }; - - //---------------------------------------------image_filter_lanczos36 - class image_filter_lanczos36 : public image_filter_lanczos - { public: image_filter_lanczos36() : image_filter_lanczos(3.0){} }; - - //---------------------------------------------image_filter_lanczos64 - class image_filter_lanczos64 : public image_filter_lanczos - { public: image_filter_lanczos64() : image_filter_lanczos(4.0){} }; - - //--------------------------------------------image_filter_lanczos100 - class image_filter_lanczos100 : public image_filter_lanczos - { public: image_filter_lanczos100() : image_filter_lanczos(5.0){} }; - - //--------------------------------------------image_filter_lanczos144 - class image_filter_lanczos144 : public image_filter_lanczos - { public: image_filter_lanczos144() : image_filter_lanczos(6.0){} }; - - //--------------------------------------------image_filter_lanczos196 - class image_filter_lanczos196 : public image_filter_lanczos - { public: image_filter_lanczos196() : image_filter_lanczos(7.0){} }; - - //--------------------------------------------image_filter_lanczos256 - class image_filter_lanczos256 : public image_filter_lanczos - { public: image_filter_lanczos256() : image_filter_lanczos(8.0){} }; - - //--------------------------------------------image_filter_blackman36 - class image_filter_blackman36 : public image_filter_blackman - { public: image_filter_blackman36() : image_filter_blackman(3.0){} }; - - //--------------------------------------------image_filter_blackman64 - class image_filter_blackman64 : public image_filter_blackman - { public: image_filter_blackman64() : image_filter_blackman(4.0){} }; - - //-------------------------------------------image_filter_blackman100 - class image_filter_blackman100 : public image_filter_blackman - { public: image_filter_blackman100() : image_filter_blackman(5.0){} }; - - //-------------------------------------------image_filter_blackman144 - class image_filter_blackman144 : public image_filter_blackman - { public: image_filter_blackman144() : image_filter_blackman(6.0){} }; - - //-------------------------------------------image_filter_blackman196 - class image_filter_blackman196 : public image_filter_blackman - { public: image_filter_blackman196() : image_filter_blackman(7.0){} }; - - //-------------------------------------------image_filter_blackman256 - class image_filter_blackman256 : public image_filter_blackman - { public: image_filter_blackman256() : image_filter_blackman(8.0){} }; - - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_line_aa_basics.h b/desmume/src/windows/agg/include/agg_line_aa_basics.h deleted file mode 100644 index 8c3d7ee20..000000000 --- a/desmume/src/windows/agg/include/agg_line_aa_basics.h +++ /dev/null @@ -1,199 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_LINE_AA_BASICS_INCLUDED -#define AGG_LINE_AA_BASICS_INCLUDED - -#include -#include "agg_basics.h" - -namespace agg -{ - - // See Implementation agg_line_aa_basics.cpp - - //------------------------------------------------------------------------- - enum line_subpixel_scale_e - { - line_subpixel_shift = 8, //----line_subpixel_shift - line_subpixel_scale = 1 << line_subpixel_shift, //----line_subpixel_scale - line_subpixel_mask = line_subpixel_scale - 1, //----line_subpixel_mask - line_max_coord = (1 << 28) - 1, //----line_max_coord - line_max_length = 1 << (line_subpixel_shift + 10) //----line_max_length - }; - - //------------------------------------------------------------------------- - enum line_mr_subpixel_scale_e - { - line_mr_subpixel_shift = 4, //----line_mr_subpixel_shift - line_mr_subpixel_scale = 1 << line_mr_subpixel_shift, //----line_mr_subpixel_scale - line_mr_subpixel_mask = line_mr_subpixel_scale - 1 //----line_mr_subpixel_mask - }; - - //------------------------------------------------------------------line_mr - AGG_INLINE int line_mr(int x) - { - return x >> (line_subpixel_shift - line_mr_subpixel_shift); - } - - //-------------------------------------------------------------------line_hr - AGG_INLINE int line_hr(int x) - { - return x << (line_subpixel_shift - line_mr_subpixel_shift); - } - - //---------------------------------------------------------------line_dbl_hr - AGG_INLINE int line_dbl_hr(int x) - { - return x << line_subpixel_shift; - } - - //---------------------------------------------------------------line_coord - struct line_coord - { - AGG_INLINE static int conv(double x) - { - return iround(x * line_subpixel_scale); - } - }; - - //-----------------------------------------------------------line_coord_sat - struct line_coord_sat - { - AGG_INLINE static int conv(double x) - { - return saturation::iround(x * line_subpixel_scale); - } - }; - - //==========================================================line_parameters - struct line_parameters - { - //--------------------------------------------------------------------- - line_parameters() {} - line_parameters(int x1_, int y1_, int x2_, int y2_, int len_) : - x1(x1_), y1(y1_), x2(x2_), y2(y2_), - dx(abs(x2_ - x1_)), - dy(abs(y2_ - y1_)), - sx((x2_ > x1_) ? 1 : -1), - sy((y2_ > y1_) ? 1 : -1), - vertical(dy >= dx), - inc(vertical ? sy : sx), - len(len_), - octant((sy & 4) | (sx & 2) | int(vertical)) - { - } - - //--------------------------------------------------------------------- - unsigned orthogonal_quadrant() const { return s_orthogonal_quadrant[octant]; } - unsigned diagonal_quadrant() const { return s_diagonal_quadrant[octant]; } - - //--------------------------------------------------------------------- - bool same_orthogonal_quadrant(const line_parameters& lp) const - { - return s_orthogonal_quadrant[octant] == s_orthogonal_quadrant[lp.octant]; - } - - //--------------------------------------------------------------------- - bool same_diagonal_quadrant(const line_parameters& lp) const - { - return s_diagonal_quadrant[octant] == s_diagonal_quadrant[lp.octant]; - } - - //--------------------------------------------------------------------- - void divide(line_parameters& lp1, line_parameters& lp2) const - { - int xmid = (x1 + x2) >> 1; - int ymid = (y1 + y2) >> 1; - int len2 = len >> 1; - - lp1 = *this; - lp2 = *this; - - lp1.x2 = xmid; - lp1.y2 = ymid; - lp1.len = len2; - lp1.dx = abs(lp1.x2 - lp1.x1); - lp1.dy = abs(lp1.y2 - lp1.y1); - - lp2.x1 = xmid; - lp2.y1 = ymid; - lp2.len = len2; - lp2.dx = abs(lp2.x2 - lp2.x1); - lp2.dy = abs(lp2.y2 - lp2.y1); - } - - //--------------------------------------------------------------------- - int x1, y1, x2, y2, dx, dy, sx, sy; - bool vertical; - int inc; - int len; - int octant; - - //--------------------------------------------------------------------- - static const int8u s_orthogonal_quadrant[8]; - static const int8u s_diagonal_quadrant[8]; - }; - - - - // See Implementation agg_line_aa_basics.cpp - - //----------------------------------------------------------------bisectrix - void bisectrix(const line_parameters& l1, - const line_parameters& l2, - int* x, int* y); - - - //-------------------------------------------fix_degenerate_bisectrix_start - void inline fix_degenerate_bisectrix_start(const line_parameters& lp, - int* x, int* y) - { - int d = iround((double(*x - lp.x2) * double(lp.y2 - lp.y1) - - double(*y - lp.y2) * double(lp.x2 - lp.x1)) / lp.len); - if(d < line_subpixel_scale/2) - { - *x = lp.x1 + (lp.y2 - lp.y1); - *y = lp.y1 - (lp.x2 - lp.x1); - } - } - - - //---------------------------------------------fix_degenerate_bisectrix_end - void inline fix_degenerate_bisectrix_end(const line_parameters& lp, - int* x, int* y) - { - int d = iround((double(*x - lp.x2) * double(lp.y2 - lp.y1) - - double(*y - lp.y2) * double(lp.x2 - lp.x1)) / lp.len); - if(d < line_subpixel_scale/2) - { - *x = lp.x2 + (lp.y2 - lp.y1); - *y = lp.y2 - (lp.x2 - lp.x1); - } - } - - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_math.h b/desmume/src/windows/agg/include/agg_math.h deleted file mode 100644 index 62bc57c3c..000000000 --- a/desmume/src/windows/agg/include/agg_math.h +++ /dev/null @@ -1,446 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- -// Bessel function (besj) was adapted for use in AGG library by Andy Wilk -// Contact: castor.vulgaris@gmail.com -//---------------------------------------------------------------------------- - -#ifndef AGG_MATH_INCLUDED -#define AGG_MATH_INCLUDED - -#include -#include "agg_basics.h" - -namespace agg -{ - - //------------------------------------------------------vertex_dist_epsilon - // Coinciding points maximal distance (Epsilon) - const double vertex_dist_epsilon = 1e-14; - - //-----------------------------------------------------intersection_epsilon - // See calc_intersection - const double intersection_epsilon = 1.0e-30; - - //------------------------------------------------------------cross_product - AGG_INLINE double cross_product(double x1, double y1, - double x2, double y2, - double x, double y) - { - return (x - x2) * (y2 - y1) - (y - y2) * (x2 - x1); - } - - //--------------------------------------------------------point_in_triangle - AGG_INLINE bool point_in_triangle(double x1, double y1, - double x2, double y2, - double x3, double y3, - double x, double y) - { - bool cp1 = cross_product(x1, y1, x2, y2, x, y) < 0.0; - bool cp2 = cross_product(x2, y2, x3, y3, x, y) < 0.0; - bool cp3 = cross_product(x3, y3, x1, y1, x, y) < 0.0; - return cp1 == cp2 && cp2 == cp3 && cp3 == cp1; - } - - //-----------------------------------------------------------calc_distance - AGG_INLINE double calc_distance(double x1, double y1, double x2, double y2) - { - double dx = x2-x1; - double dy = y2-y1; - return sqrt(dx * dx + dy * dy); - } - - //--------------------------------------------------------calc_sq_distance - AGG_INLINE double calc_sq_distance(double x1, double y1, double x2, double y2) - { - double dx = x2-x1; - double dy = y2-y1; - return dx * dx + dy * dy; - } - - //------------------------------------------------calc_line_point_distance - AGG_INLINE double calc_line_point_distance(double x1, double y1, - double x2, double y2, - double x, double y) - { - double dx = x2-x1; - double dy = y2-y1; - double d = sqrt(dx * dx + dy * dy); - if(d < vertex_dist_epsilon) - { - return calc_distance(x1, y1, x, y); - } - return ((x - x2) * dy - (y - y2) * dx) / d; - } - - //-------------------------------------------------------calc_line_point_u - AGG_INLINE double calc_segment_point_u(double x1, double y1, - double x2, double y2, - double x, double y) - { - double dx = x2 - x1; - double dy = y2 - y1; - - if(dx == 0 && dy == 0) - { - return 0; - } - - double pdx = x - x1; - double pdy = y - y1; - - return (pdx * dx + pdy * dy) / (dx * dx + dy * dy); - } - - //---------------------------------------------calc_line_point_sq_distance - AGG_INLINE double calc_segment_point_sq_distance(double x1, double y1, - double x2, double y2, - double x, double y, - double u) - { - if(u <= 0) - { - return calc_sq_distance(x, y, x1, y1); - } - else - if(u >= 1) - { - return calc_sq_distance(x, y, x2, y2); - } - return calc_sq_distance(x, y, x1 + u * (x2 - x1), y1 + u * (y2 - y1)); - } - - //---------------------------------------------calc_line_point_sq_distance - AGG_INLINE double calc_segment_point_sq_distance(double x1, double y1, - double x2, double y2, - double x, double y) - { - return - calc_segment_point_sq_distance( - x1, y1, x2, y2, x, y, - calc_segment_point_u(x1, y1, x2, y2, x, y)); - } - - //-------------------------------------------------------calc_intersection - AGG_INLINE bool calc_intersection(double ax, double ay, double bx, double by, - double cx, double cy, double dx, double dy, - double* x, double* y) - { - double num = (ay-cy) * (dx-cx) - (ax-cx) * (dy-cy); - double den = (bx-ax) * (dy-cy) - (by-ay) * (dx-cx); - if(fabs(den) < intersection_epsilon) return false; - double r = num / den; - *x = ax + r * (bx-ax); - *y = ay + r * (by-ay); - return true; - } - - //-----------------------------------------------------intersection_exists - AGG_INLINE bool intersection_exists(double x1, double y1, double x2, double y2, - double x3, double y3, double x4, double y4) - { - // It's less expensive but you can't control the - // boundary conditions: Less or LessEqual - double dx1 = x2 - x1; - double dy1 = y2 - y1; - double dx2 = x4 - x3; - double dy2 = y4 - y3; - return ((x3 - x2) * dy1 - (y3 - y2) * dx1 < 0.0) != - ((x4 - x2) * dy1 - (y4 - y2) * dx1 < 0.0) && - ((x1 - x4) * dy2 - (y1 - y4) * dx2 < 0.0) != - ((x2 - x4) * dy2 - (y2 - y4) * dx2 < 0.0); - - // It's is more expensive but more flexible - // in terms of boundary conditions. - //-------------------- - //double den = (x2-x1) * (y4-y3) - (y2-y1) * (x4-x3); - //if(fabs(den) < intersection_epsilon) return false; - //double nom1 = (x4-x3) * (y1-y3) - (y4-y3) * (x1-x3); - //double nom2 = (x2-x1) * (y1-y3) - (y2-y1) * (x1-x3); - //double ua = nom1 / den; - //double ub = nom2 / den; - //return ua >= 0.0 && ua <= 1.0 && ub >= 0.0 && ub <= 1.0; - } - - //--------------------------------------------------------calc_orthogonal - AGG_INLINE void calc_orthogonal(double thickness, - double x1, double y1, - double x2, double y2, - double* x, double* y) - { - double dx = x2 - x1; - double dy = y2 - y1; - double d = sqrt(dx*dx + dy*dy); - *x = thickness * dy / d; - *y = -thickness * dx / d; - } - - //--------------------------------------------------------dilate_triangle - AGG_INLINE void dilate_triangle(double x1, double y1, - double x2, double y2, - double x3, double y3, - double *x, double* y, - double d) - { - double dx1=0.0; - double dy1=0.0; - double dx2=0.0; - double dy2=0.0; - double dx3=0.0; - double dy3=0.0; - double loc = cross_product(x1, y1, x2, y2, x3, y3); - if(fabs(loc) > intersection_epsilon) - { - if(cross_product(x1, y1, x2, y2, x3, y3) > 0.0) - { - d = -d; - } - calc_orthogonal(d, x1, y1, x2, y2, &dx1, &dy1); - calc_orthogonal(d, x2, y2, x3, y3, &dx2, &dy2); - calc_orthogonal(d, x3, y3, x1, y1, &dx3, &dy3); - } - *x++ = x1 + dx1; *y++ = y1 + dy1; - *x++ = x2 + dx1; *y++ = y2 + dy1; - *x++ = x2 + dx2; *y++ = y2 + dy2; - *x++ = x3 + dx2; *y++ = y3 + dy2; - *x++ = x3 + dx3; *y++ = y3 + dy3; - *x++ = x1 + dx3; *y++ = y1 + dy3; - } - - //------------------------------------------------------calc_triangle_area - AGG_INLINE double calc_triangle_area(double x1, double y1, - double x2, double y2, - double x3, double y3) - { - return (x1*y2 - x2*y1 + x2*y3 - x3*y2 + x3*y1 - x1*y3) * 0.5; - } - - //-------------------------------------------------------calc_polygon_area - template double calc_polygon_area(const Storage& st) - { - unsigned i; - double sum = 0.0; - double x = st[0].x; - double y = st[0].y; - double xs = x; - double ys = y; - - for(i = 1; i < st.size(); i++) - { - const typename Storage::value_type& v = st[i]; - sum += x * v.y - y * v.x; - x = v.x; - y = v.y; - } - return (sum + x * ys - y * xs) * 0.5; - } - - //------------------------------------------------------------------------ - // Tables for fast sqrt - extern int16u g_sqrt_table[1024]; - extern int8 g_elder_bit_table[256]; - - - //---------------------------------------------------------------fast_sqrt - //Fast integer Sqrt - really fast: no cycles, divisions or multiplications - #if defined(_MSC_VER) - #pragma warning(push) - #pragma warning(disable : 4035) //Disable warning "no return value" - #endif - AGG_INLINE unsigned fast_sqrt(unsigned val) - { - #if defined(_M_IX86) && defined(_MSC_VER) && !defined(AGG_NO_ASM) - //For Ix86 family processors this assembler code is used. - //The key command here is bsr - determination the number of the most - //significant bit of the value. For other processors - //(and maybe compilers) the pure C "#else" section is used. - __asm - { - mov ebx, val - mov edx, 11 - bsr ecx, ebx - sub ecx, 9 - jle less_than_9_bits - shr ecx, 1 - adc ecx, 0 - sub edx, ecx - shl ecx, 1 - shr ebx, cl - less_than_9_bits: - xor eax, eax - mov ax, g_sqrt_table[ebx*2] - mov ecx, edx - shr eax, cl - } - #else - - //This code is actually pure C and portable to most - //arcitectures including 64bit ones. - unsigned t = val; - int bit=0; - unsigned shift = 11; - - //The following piece of code is just an emulation of the - //Ix86 assembler command "bsr" (see above). However on old - //Intels (like Intel MMX 233MHz) this code is about twice - //faster (sic!) then just one "bsr". On PIII and PIV the - //bsr is optimized quite well. - bit = t >> 24; - if(bit) - { - bit = g_elder_bit_table[bit] + 24; - } - else - { - bit = (t >> 16) & 0xFF; - if(bit) - { - bit = g_elder_bit_table[bit] + 16; - } - else - { - bit = (t >> 8) & 0xFF; - if(bit) - { - bit = g_elder_bit_table[bit] + 8; - } - else - { - bit = g_elder_bit_table[t]; - } - } - } - - //This code calculates the sqrt. - bit -= 9; - if(bit > 0) - { - bit = (bit >> 1) + (bit & 1); - shift -= bit; - val >>= (bit << 1); - } - return g_sqrt_table[val] >> shift; - #endif - } - #if defined(_MSC_VER) - #pragma warning(pop) - #endif - - - - - //--------------------------------------------------------------------besj - // Function BESJ calculates Bessel function of first kind of order n - // Arguments: - // n - an integer (>=0), the order - // x - value at which the Bessel function is required - //-------------------- - // C++ Mathematical Library - // Convereted from equivalent FORTRAN library - // Converetd by Gareth Walker for use by course 392 computational project - // All functions tested and yield the same results as the corresponding - // FORTRAN versions. - // - // If you have any problems using these functions please report them to - // M.Muldoon@UMIST.ac.uk - // - // Documentation available on the web - // http://www.ma.umist.ac.uk/mrm/Teaching/392/libs/392.html - // Version 1.0 8/98 - // 29 October, 1999 - //-------------------- - // Adapted for use in AGG library by Andy Wilk (castor.vulgaris@gmail.com) - //------------------------------------------------------------------------ - inline double besj(double x, int n) - { - if(n < 0) - { - return 0; - } - double d = 1E-6; - double b = 0; - if(fabs(x) <= d) - { - if(n != 0) return 0; - return 1; - } - double b1 = 0; // b1 is the value from the previous iteration - // Set up a starting order for recurrence - int m1 = (int)fabs(x) + 6; - if(fabs(x) > 5) - { - m1 = (int)(fabs(1.4 * x + 60 / x)); - } - int m2 = (int)(n + 2 + fabs(x) / 4); - if (m1 > m2) - { - m2 = m1; - } - - // Apply recurrence down from curent max order - for(;;) - { - double c3 = 0; - double c2 = 1E-30; - double c4 = 0; - int m8 = 1; - if (m2 / 2 * 2 == m2) - { - m8 = -1; - } - int imax = m2 - 2; - for (int i = 1; i <= imax; i++) - { - double c6 = 2 * (m2 - i) * c2 / x - c3; - c3 = c2; - c2 = c6; - if(m2 - i - 1 == n) - { - b = c6; - } - m8 = -1 * m8; - if (m8 > 0) - { - c4 = c4 + 2 * c6; - } - } - double c6 = 2 * c2 / x - c3; - if(n == 0) - { - b = c6; - } - c4 += c6; - b /= c4; - if(fabs(b - b1) < d) - { - return b; - } - b1 = b; - m2 += 3; - } - } - -} - - -#endif diff --git a/desmume/src/windows/agg/include/agg_math_stroke.h b/desmume/src/windows/agg/include/agg_math_stroke.h deleted file mode 100644 index 11e66b12b..000000000 --- a/desmume/src/windows/agg/include/agg_math_stroke.h +++ /dev/null @@ -1,531 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_STROKE_MATH_INCLUDED -#define AGG_STROKE_MATH_INCLUDED - -#include "agg_math.h" -#include "agg_vertex_sequence.h" - -namespace agg -{ - //-------------------------------------------------------------line_cap_e - enum line_cap_e - { - butt_cap, - square_cap, - round_cap - }; - - //------------------------------------------------------------line_join_e - enum line_join_e - { - miter_join = 0, - miter_join_revert = 1, - round_join = 2, - bevel_join = 3, - miter_join_round = 4 - }; - - - //-----------------------------------------------------------inner_join_e - enum inner_join_e - { - inner_bevel, - inner_miter, - inner_jag, - inner_round - }; - - //------------------------------------------------------------math_stroke - template class math_stroke - { - public: - typedef typename VertexConsumer::value_type coord_type; - - math_stroke(); - - void line_cap(line_cap_e lc) { m_line_cap = lc; } - void line_join(line_join_e lj) { m_line_join = lj; } - void inner_join(inner_join_e ij) { m_inner_join = ij; } - - line_cap_e line_cap() const { return m_line_cap; } - line_join_e line_join() const { return m_line_join; } - inner_join_e inner_join() const { return m_inner_join; } - - void width(double w); - void miter_limit(double ml) { m_miter_limit = ml; } - void miter_limit_theta(double t); - void inner_miter_limit(double ml) { m_inner_miter_limit = ml; } - void approximation_scale(double as) { m_approx_scale = as; } - - double width() const { return m_width * 2.0; } - double miter_limit() const { return m_miter_limit; } - double inner_miter_limit() const { return m_inner_miter_limit; } - double approximation_scale() const { return m_approx_scale; } - - void calc_cap(VertexConsumer& vc, - const vertex_dist& v0, - const vertex_dist& v1, - double len); - - void calc_join(VertexConsumer& vc, - const vertex_dist& v0, - const vertex_dist& v1, - const vertex_dist& v2, - double len1, - double len2); - - private: - AGG_INLINE void add_vertex(VertexConsumer& vc, double x, double y) - { - vc.add(coord_type(x, y)); - } - - void calc_arc(VertexConsumer& vc, - double x, double y, - double dx1, double dy1, - double dx2, double dy2); - - void calc_miter(VertexConsumer& vc, - const vertex_dist& v0, - const vertex_dist& v1, - const vertex_dist& v2, - double dx1, double dy1, - double dx2, double dy2, - line_join_e lj, - double mlimit, - double dbevel); - - double m_width; - double m_width_abs; - double m_width_eps; - int m_width_sign; - double m_miter_limit; - double m_inner_miter_limit; - double m_approx_scale; - line_cap_e m_line_cap; - line_join_e m_line_join; - inner_join_e m_inner_join; - }; - - //----------------------------------------------------------------------- - template math_stroke::math_stroke() : - m_width(0.5), - m_width_abs(0.5), - m_width_eps(0.5/1024.0), - m_width_sign(1), - m_miter_limit(4.0), - m_inner_miter_limit(1.01), - m_approx_scale(1.0), - m_line_cap(butt_cap), - m_line_join(miter_join), - m_inner_join(inner_miter) - { - } - - //----------------------------------------------------------------------- - template void math_stroke::width(double w) - { - m_width = w * 0.5; - if(m_width < 0) - { - m_width_abs = -m_width; - m_width_sign = -1; - } - else - { - m_width_abs = m_width; - m_width_sign = 1; - } - m_width_eps = m_width / 1024.0; - } - - //----------------------------------------------------------------------- - template void math_stroke::miter_limit_theta(double t) - { - m_miter_limit = 1.0 / sin(t * 0.5) ; - } - - //----------------------------------------------------------------------- - template - void math_stroke::calc_arc(VC& vc, - double x, double y, - double dx1, double dy1, - double dx2, double dy2) - { - double a1 = atan2(dy1 * m_width_sign, dx1 * m_width_sign); - double a2 = atan2(dy2 * m_width_sign, dx2 * m_width_sign); - double da = a1 - a2; - int i, n; - - da = acos(m_width_abs / (m_width_abs + 0.125 / m_approx_scale)) * 2; - - add_vertex(vc, x + dx1, y + dy1); - if(m_width_sign > 0) - { - if(a1 > a2) a2 += 2 * pi; - n = int((a2 - a1) / da); - da = (a2 - a1) / (n + 1); - a1 += da; - for(i = 0; i < n; i++) - { - add_vertex(vc, x + cos(a1) * m_width, y + sin(a1) * m_width); - a1 += da; - } - } - else - { - if(a1 < a2) a2 -= 2 * pi; - n = int((a1 - a2) / da); - da = (a1 - a2) / (n + 1); - a1 -= da; - for(i = 0; i < n; i++) - { - add_vertex(vc, x + cos(a1) * m_width, y + sin(a1) * m_width); - a1 -= da; - } - } - add_vertex(vc, x + dx2, y + dy2); - } - - //----------------------------------------------------------------------- - template - void math_stroke::calc_miter(VC& vc, - const vertex_dist& v0, - const vertex_dist& v1, - const vertex_dist& v2, - double dx1, double dy1, - double dx2, double dy2, - line_join_e lj, - double mlimit, - double dbevel) - { - double xi = v1.x; - double yi = v1.y; - double di = 1; - double lim = m_width_abs * mlimit; - bool miter_limit_exceeded = true; // Assume the worst - bool intersection_failed = true; // Assume the worst - - if(calc_intersection(v0.x + dx1, v0.y - dy1, - v1.x + dx1, v1.y - dy1, - v1.x + dx2, v1.y - dy2, - v2.x + dx2, v2.y - dy2, - &xi, &yi)) - { - // Calculation of the intersection succeeded - //--------------------- - di = calc_distance(v1.x, v1.y, xi, yi); - if(di <= lim) - { - // Inside the miter limit - //--------------------- - add_vertex(vc, xi, yi); - miter_limit_exceeded = false; - } - intersection_failed = false; - } - else - { - // Calculation of the intersection failed, most probably - // the three points lie one straight line. - // First check if v0 and v2 lie on the opposite sides of vector: - // (v1.x, v1.y) -> (v1.x+dx1, v1.y-dy1), that is, the perpendicular - // to the line determined by vertices v0 and v1. - // This condition determines whether the next line segments continues - // the previous one or goes back. - //---------------- - double x2 = v1.x + dx1; - double y2 = v1.y - dy1; - if((cross_product(v0.x, v0.y, v1.x, v1.y, x2, y2) < 0.0) == - (cross_product(v1.x, v1.y, v2.x, v2.y, x2, y2) < 0.0)) - { - // This case means that the next segment continues - // the previous one (straight line) - //----------------- - add_vertex(vc, v1.x + dx1, v1.y - dy1); - miter_limit_exceeded = false; - } - } - - if(miter_limit_exceeded) - { - // Miter limit exceeded - //------------------------ - switch(lj) - { - case miter_join_revert: - // For the compatibility with SVG, PDF, etc, - // we use a simple bevel join instead of - // "smart" bevel - //------------------- - add_vertex(vc, v1.x + dx1, v1.y - dy1); - add_vertex(vc, v1.x + dx2, v1.y - dy2); - break; - - case miter_join_round: - calc_arc(vc, v1.x, v1.y, dx1, -dy1, dx2, -dy2); - break; - - default: - // If no miter-revert, calculate new dx1, dy1, dx2, dy2 - //---------------- - if(intersection_failed) - { - mlimit *= m_width_sign; - add_vertex(vc, v1.x + dx1 + dy1 * mlimit, - v1.y - dy1 + dx1 * mlimit); - add_vertex(vc, v1.x + dx2 - dy2 * mlimit, - v1.y - dy2 - dx2 * mlimit); - } - else - { - double x1 = v1.x + dx1; - double y1 = v1.y - dy1; - double x2 = v1.x + dx2; - double y2 = v1.y - dy2; - di = (lim - dbevel) / (di - dbevel); - add_vertex(vc, x1 + (xi - x1) * di, - y1 + (yi - y1) * di); - add_vertex(vc, x2 + (xi - x2) * di, - y2 + (yi - y2) * di); - } - break; - } - } - } - - //--------------------------------------------------------stroke_calc_cap - template - void math_stroke::calc_cap(VC& vc, - const vertex_dist& v0, - const vertex_dist& v1, - double len) - { - vc.remove_all(); - - double dx1 = (v1.y - v0.y) / len; - double dy1 = (v1.x - v0.x) / len; - double dx2 = 0; - double dy2 = 0; - - dx1 *= m_width; - dy1 *= m_width; - - if(m_line_cap != round_cap) - { - if(m_line_cap == square_cap) - { - dx2 = dy1 * m_width_sign; - dy2 = dx1 * m_width_sign; - } - add_vertex(vc, v0.x - dx1 - dx2, v0.y + dy1 - dy2); - add_vertex(vc, v0.x + dx1 - dx2, v0.y - dy1 - dy2); - } - else - { - double da = acos(m_width_abs / (m_width_abs + 0.125 / m_approx_scale)) * 2; - double a1; - int i; - int n = int(pi / da); - - da = pi / (n + 1); - add_vertex(vc, v0.x - dx1, v0.y + dy1); - if(m_width_sign > 0) - { - a1 = atan2(dy1, -dx1); - a1 += da; - for(i = 0; i < n; i++) - { - add_vertex(vc, v0.x + cos(a1) * m_width, - v0.y + sin(a1) * m_width); - a1 += da; - } - } - else - { - a1 = atan2(-dy1, dx1); - a1 -= da; - for(i = 0; i < n; i++) - { - add_vertex(vc, v0.x + cos(a1) * m_width, - v0.y + sin(a1) * m_width); - a1 -= da; - } - } - add_vertex(vc, v0.x + dx1, v0.y - dy1); - } - } - - //----------------------------------------------------------------------- - template - void math_stroke::calc_join(VC& vc, - const vertex_dist& v0, - const vertex_dist& v1, - const vertex_dist& v2, - double len1, - double len2) - { - double dx1 = m_width * (v1.y - v0.y) / len1; - double dy1 = m_width * (v1.x - v0.x) / len1; - double dx2 = m_width * (v2.y - v1.y) / len2; - double dy2 = m_width * (v2.x - v1.x) / len2; - - vc.remove_all(); - - double cp = cross_product(v0.x, v0.y, v1.x, v1.y, v2.x, v2.y); - if(cp != 0 && (cp > 0) == (m_width > 0)) - { - // Inner join - //--------------- - double limit = ((len1 < len2) ? len1 : len2) / m_width_abs; - if(limit < m_inner_miter_limit) - { - limit = m_inner_miter_limit; - } - - switch(m_inner_join) - { - default: // inner_bevel - add_vertex(vc, v1.x + dx1, v1.y - dy1); - add_vertex(vc, v1.x + dx2, v1.y - dy2); - break; - - case inner_miter: - calc_miter(vc, - v0, v1, v2, dx1, dy1, dx2, dy2, - miter_join_revert, - limit, 0); - break; - - case inner_jag: - case inner_round: - cp = (dx1-dx2) * (dx1-dx2) + (dy1-dy2) * (dy1-dy2); - if(cp < len1 * len1 && cp < len2 * len2) - { - calc_miter(vc, - v0, v1, v2, dx1, dy1, dx2, dy2, - miter_join_revert, - limit, 0); - } - else - { - if(m_inner_join == inner_jag) - { - add_vertex(vc, v1.x + dx1, v1.y - dy1); - add_vertex(vc, v1.x, v1.y ); - add_vertex(vc, v1.x + dx2, v1.y - dy2); - } - else - { - add_vertex(vc, v1.x + dx1, v1.y - dy1); - add_vertex(vc, v1.x, v1.y ); - calc_arc(vc, v1.x, v1.y, dx2, -dy2, dx1, -dy1); - add_vertex(vc, v1.x, v1.y ); - add_vertex(vc, v1.x + dx2, v1.y - dy2); - } - } - break; - } - } - else - { - // Outer join - //--------------- - - // Calculate the distance between v1 and - // the central point of the bevel line segment - //--------------- - double dx = (dx1 + dx2) / 2; - double dy = (dy1 + dy2) / 2; - double dbevel = sqrt(dx * dx + dy * dy); - - if(m_line_join == round_join || m_line_join == bevel_join) - { - // This is an optimization that reduces the number of points - // in cases of almost collinear segments. If there's no - // visible difference between bevel and miter joins we'd rather - // use miter join because it adds only one point instead of two. - // - // Here we calculate the middle point between the bevel points - // and then, the distance between v1 and this middle point. - // At outer joins this distance always less than stroke width, - // because it's actually the height of an isosceles triangle of - // v1 and its two bevel points. If the difference between this - // width and this value is small (no visible bevel) we can - // add just one point. - // - // The constant in the expression makes the result approximately - // the same as in round joins and caps. You can safely comment - // out this entire "if". - //------------------- - if(m_approx_scale * (m_width_abs - dbevel) < m_width_eps) - { - if(calc_intersection(v0.x + dx1, v0.y - dy1, - v1.x + dx1, v1.y - dy1, - v1.x + dx2, v1.y - dy2, - v2.x + dx2, v2.y - dy2, - &dx, &dy)) - { - add_vertex(vc, dx, dy); - } - else - { - add_vertex(vc, v1.x + dx1, v1.y - dy1); - } - return; - } - } - - switch(m_line_join) - { - case miter_join: - case miter_join_revert: - case miter_join_round: - calc_miter(vc, - v0, v1, v2, dx1, dy1, dx2, dy2, - m_line_join, - m_miter_limit, - dbevel); - break; - - case round_join: - calc_arc(vc, v1.x, v1.y, dx1, -dy1, dx2, -dy2); - break; - - default: // Bevel join - add_vertex(vc, v1.x + dx1, v1.y - dy1); - add_vertex(vc, v1.x + dx2, v1.y - dy2); - break; - } - } - } - - - - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_path_length.h b/desmume/src/windows/agg/include/agg_path_length.h deleted file mode 100644 index 487959e1f..000000000 --- a/desmume/src/windows/agg/include/agg_path_length.h +++ /dev/null @@ -1,75 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_PATH_LENGTH_INCLUDED -#define AGG_PATH_LENGTH_INCLUDED - -#include "agg_math.h" - -namespace agg -{ - template - double path_length(VertexSource& vs, unsigned path_id = 0) - { - double len = 0.0; - double start_x = 0.0; - double start_y = 0.0; - double x1 = 0.0; - double y1 = 0.0; - double x2 = 0.0; - double y2 = 0.0; - bool first = true; - - unsigned cmd; - vs.rewind(path_id); - while(!is_stop(cmd = vs.vertex(&x2, &y2))) - { - if(is_vertex(cmd)) - { - if(first || is_move_to(cmd)) - { - start_x = x2; - start_y = y2; - } - else - { - len += calc_distance(x1, y1, x2, y2); - } - x1 = x2; - y1 = y2; - first = false; - } - else - { - if(is_close(cmd) && !first) - { - len += calc_distance(x1, y1, start_x, start_y); - } - } - } - return len; - } -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_path_storage.h b/desmume/src/windows/agg/include/agg_path_storage.h deleted file mode 100644 index e8cb7ab48..000000000 --- a/desmume/src/windows/agg/include/agg_path_storage.h +++ /dev/null @@ -1,1554 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_PATH_STORAGE_INCLUDED -#define AGG_PATH_STORAGE_INCLUDED - -#include -#include -#include "agg_math.h" -#include "agg_array.h" -#include "agg_bezier_arc.h" - -namespace agg -{ - - - //----------------------------------------------------vertex_block_storage - template - class vertex_block_storage - { - public: - // Allocation parameters - enum block_scale_e - { - block_shift = BlockShift, - block_size = 1 << block_shift, - block_mask = block_size - 1, - block_pool = BlockPool - }; - - typedef T value_type; - typedef vertex_block_storage self_type; - - ~vertex_block_storage(); - vertex_block_storage(); - vertex_block_storage(const self_type& v); - const self_type& operator = (const self_type& ps); - - void remove_all(); - void free_all(); - - void add_vertex(double x, double y, unsigned cmd); - void modify_vertex(unsigned idx, double x, double y); - void modify_vertex(unsigned idx, double x, double y, unsigned cmd); - void modify_command(unsigned idx, unsigned cmd); - void swap_vertices(unsigned v1, unsigned v2); - - unsigned last_command() const; - unsigned last_vertex(double* x, double* y) const; - unsigned prev_vertex(double* x, double* y) const; - - double last_x() const; - double last_y() const; - - unsigned total_vertices() const; - unsigned vertex(unsigned idx, double* x, double* y) const; - unsigned command(unsigned idx) const; - - private: - void allocate_block(unsigned nb); - int8u* storage_ptrs(T** xy_ptr); - - private: - unsigned m_total_vertices; - unsigned m_total_blocks; - unsigned m_max_blocks; - T** m_coord_blocks; - int8u** m_cmd_blocks; - }; - - - //------------------------------------------------------------------------ - template - void vertex_block_storage::free_all() - { - if(m_total_blocks) - { - T** coord_blk = m_coord_blocks + m_total_blocks - 1; - while(m_total_blocks--) - { - pod_allocator::deallocate( - *coord_blk, - block_size * 2 + - block_size / (sizeof(T) / sizeof(unsigned char))); - --coord_blk; - } - pod_allocator::deallocate(m_coord_blocks, m_max_blocks * 2); - m_total_blocks = 0; - m_max_blocks = 0; - m_coord_blocks = 0; - m_cmd_blocks = 0; - m_total_vertices = 0; - } - } - - //------------------------------------------------------------------------ - template - vertex_block_storage::~vertex_block_storage() - { - free_all(); - } - - //------------------------------------------------------------------------ - template - vertex_block_storage::vertex_block_storage() : - m_total_vertices(0), - m_total_blocks(0), - m_max_blocks(0), - m_coord_blocks(0), - m_cmd_blocks(0) - { - } - - //------------------------------------------------------------------------ - template - vertex_block_storage::vertex_block_storage(const vertex_block_storage& v) : - m_total_vertices(0), - m_total_blocks(0), - m_max_blocks(0), - m_coord_blocks(0), - m_cmd_blocks(0) - { - *this = v; - } - - //------------------------------------------------------------------------ - template - const vertex_block_storage& - vertex_block_storage::operator = (const vertex_block_storage& v) - { - remove_all(); - unsigned i; - for(i = 0; i < v.total_vertices(); i++) - { - double x, y; - unsigned cmd = v.vertex(i, &x, &y); - add_vertex(x, y, cmd); - } - return *this; - } - - //------------------------------------------------------------------------ - template - inline void vertex_block_storage::remove_all() - { - m_total_vertices = 0; - } - - //------------------------------------------------------------------------ - template - inline void vertex_block_storage::add_vertex(double x, double y, - unsigned cmd) - { - T* coord_ptr = 0; - *storage_ptrs(&coord_ptr) = (int8u)cmd; - coord_ptr[0] = T(x); - coord_ptr[1] = T(y); - m_total_vertices++; - } - - //------------------------------------------------------------------------ - template - inline void vertex_block_storage::modify_vertex(unsigned idx, - double x, double y) - { - T* pv = m_coord_blocks[idx >> block_shift] + ((idx & block_mask) << 1); - pv[0] = T(x); - pv[1] = T(y); - } - - //------------------------------------------------------------------------ - template - inline void vertex_block_storage::modify_vertex(unsigned idx, - double x, double y, - unsigned cmd) - { - unsigned block = idx >> block_shift; - unsigned offset = idx & block_mask; - T* pv = m_coord_blocks[block] + (offset << 1); - pv[0] = T(x); - pv[1] = T(y); - m_cmd_blocks[block][offset] = (int8u)cmd; - } - - //------------------------------------------------------------------------ - template - inline void vertex_block_storage::modify_command(unsigned idx, - unsigned cmd) - { - m_cmd_blocks[idx >> block_shift][idx & block_mask] = (int8u)cmd; - } - - //------------------------------------------------------------------------ - template - inline void vertex_block_storage::swap_vertices(unsigned v1, unsigned v2) - { - unsigned b1 = v1 >> block_shift; - unsigned b2 = v2 >> block_shift; - unsigned o1 = v1 & block_mask; - unsigned o2 = v2 & block_mask; - T* pv1 = m_coord_blocks[b1] + (o1 << 1); - T* pv2 = m_coord_blocks[b2] + (o2 << 1); - T val; - val = pv1[0]; pv1[0] = pv2[0]; pv2[0] = val; - val = pv1[1]; pv1[1] = pv2[1]; pv2[1] = val; - int8u cmd = m_cmd_blocks[b1][o1]; - m_cmd_blocks[b1][o1] = m_cmd_blocks[b2][o2]; - m_cmd_blocks[b2][o2] = cmd; - } - - //------------------------------------------------------------------------ - template - inline unsigned vertex_block_storage::last_command() const - { - if(m_total_vertices) return command(m_total_vertices - 1); - return path_cmd_stop; - } - - //------------------------------------------------------------------------ - template - inline unsigned vertex_block_storage::last_vertex(double* x, double* y) const - { - if(m_total_vertices) return vertex(m_total_vertices - 1, x, y); - return path_cmd_stop; - } - - //------------------------------------------------------------------------ - template - inline unsigned vertex_block_storage::prev_vertex(double* x, double* y) const - { - if(m_total_vertices > 1) return vertex(m_total_vertices - 2, x, y); - return path_cmd_stop; - } - - //------------------------------------------------------------------------ - template - inline double vertex_block_storage::last_x() const - { - if(m_total_vertices) - { - unsigned idx = m_total_vertices - 1; - return m_coord_blocks[idx >> block_shift][(idx & block_mask) << 1]; - } - return 0.0; - } - - //------------------------------------------------------------------------ - template - inline double vertex_block_storage::last_y() const - { - if(m_total_vertices) - { - unsigned idx = m_total_vertices - 1; - return m_coord_blocks[idx >> block_shift][((idx & block_mask) << 1) + 1]; - } - return 0.0; - } - - //------------------------------------------------------------------------ - template - inline unsigned vertex_block_storage::total_vertices() const - { - return m_total_vertices; - } - - //------------------------------------------------------------------------ - template - inline unsigned vertex_block_storage::vertex(unsigned idx, - double* x, double* y) const - { - unsigned nb = idx >> block_shift; - const T* pv = m_coord_blocks[nb] + ((idx & block_mask) << 1); - *x = pv[0]; - *y = pv[1]; - return m_cmd_blocks[nb][idx & block_mask]; - } - - //------------------------------------------------------------------------ - template - inline unsigned vertex_block_storage::command(unsigned idx) const - { - return m_cmd_blocks[idx >> block_shift][idx & block_mask]; - } - - //------------------------------------------------------------------------ - template - void vertex_block_storage::allocate_block(unsigned nb) - { - if(nb >= m_max_blocks) - { - T** new_coords = - pod_allocator::allocate((m_max_blocks + block_pool) * 2); - - unsigned char** new_cmds = - (unsigned char**)(new_coords + m_max_blocks + block_pool); - - if(m_coord_blocks) - { - memcpy(new_coords, - m_coord_blocks, - m_max_blocks * sizeof(T*)); - - memcpy(new_cmds, - m_cmd_blocks, - m_max_blocks * sizeof(unsigned char*)); - - pod_allocator::deallocate(m_coord_blocks, m_max_blocks * 2); - } - m_coord_blocks = new_coords; - m_cmd_blocks = new_cmds; - m_max_blocks += block_pool; - } - m_coord_blocks[nb] = - pod_allocator::allocate(block_size * 2 + - block_size / (sizeof(T) / sizeof(unsigned char))); - - m_cmd_blocks[nb] = - (unsigned char*)(m_coord_blocks[nb] + block_size * 2); - - m_total_blocks++; - } - - //------------------------------------------------------------------------ - template - int8u* vertex_block_storage::storage_ptrs(T** xy_ptr) - { - unsigned nb = m_total_vertices >> block_shift; - if(nb >= m_total_blocks) - { - allocate_block(nb); - } - *xy_ptr = m_coord_blocks[nb] + ((m_total_vertices & block_mask) << 1); - return m_cmd_blocks[nb] + (m_total_vertices & block_mask); - } - - - - - //-----------------------------------------------------poly_plain_adaptor - template class poly_plain_adaptor - { - public: - typedef T value_type; - - poly_plain_adaptor() : - m_data(0), - m_ptr(0), - m_end(0), - m_closed(false), - m_stop(false) - {} - - poly_plain_adaptor(const T* data, unsigned num_points, bool closed) : - m_data(data), - m_ptr(data), - m_end(data + num_points * 2), - m_closed(closed), - m_stop(false) - {} - - void init(const T* data, unsigned num_points, bool closed) - { - m_data = data; - m_ptr = data; - m_end = data + num_points * 2; - m_closed = closed; - m_stop = false; - } - - void rewind(unsigned) - { - m_ptr = m_data; - m_stop = false; - } - - unsigned vertex(double* x, double* y) - { - if(m_ptr < m_end) - { - bool first = m_ptr == m_data; - *x = *m_ptr++; - *y = *m_ptr++; - return first ? path_cmd_move_to : path_cmd_line_to; - } - *x = *y = 0.0; - if(m_closed && !m_stop) - { - m_stop = true; - return path_cmd_end_poly | path_flags_close; - } - return path_cmd_stop; - } - - private: - const T* m_data; - const T* m_ptr; - const T* m_end; - bool m_closed; - bool m_stop; - }; - - - - - - //-------------------------------------------------poly_container_adaptor - template class poly_container_adaptor - { - public: - typedef typename Container::value_type vertex_type; - - poly_container_adaptor() : - m_container(0), - m_index(0), - m_closed(false), - m_stop(false) - {} - - poly_container_adaptor(const Container& data, bool closed) : - m_container(&data), - m_index(0), - m_closed(closed), - m_stop(false) - {} - - void init(const Container& data, bool closed) - { - m_container = &data; - m_index = 0; - m_closed = closed; - m_stop = false; - } - - void rewind(unsigned) - { - m_index = 0; - m_stop = false; - } - - unsigned vertex(double* x, double* y) - { - if(m_index < m_container->size()) - { - bool first = m_index == 0; - const vertex_type& v = (*m_container)[m_index++]; - *x = v.x; - *y = v.y; - return first ? path_cmd_move_to : path_cmd_line_to; - } - *x = *y = 0.0; - if(m_closed && !m_stop) - { - m_stop = true; - return path_cmd_end_poly | path_flags_close; - } - return path_cmd_stop; - } - - private: - const Container* m_container; - unsigned m_index; - bool m_closed; - bool m_stop; - }; - - - - //-----------------------------------------poly_container_reverse_adaptor - template class poly_container_reverse_adaptor - { - public: - typedef typename Container::value_type vertex_type; - - poly_container_reverse_adaptor() : - m_container(0), - m_index(-1), - m_closed(false), - m_stop(false) - {} - - poly_container_reverse_adaptor(const Container& data, bool closed) : - m_container(&data), - m_index(-1), - m_closed(closed), - m_stop(false) - {} - - void init(const Container& data, bool closed) - { - m_container = &data; - m_index = m_container->size() - 1; - m_closed = closed; - m_stop = false; - } - - void rewind(unsigned) - { - m_index = m_container->size() - 1; - m_stop = false; - } - - unsigned vertex(double* x, double* y) - { - if(m_index >= 0) - { - bool first = m_index == int(m_container->size() - 1); - const vertex_type& v = (*m_container)[m_index--]; - *x = v.x; - *y = v.y; - return first ? path_cmd_move_to : path_cmd_line_to; - } - *x = *y = 0.0; - if(m_closed && !m_stop) - { - m_stop = true; - return path_cmd_end_poly | path_flags_close; - } - return path_cmd_stop; - } - - private: - const Container* m_container; - int m_index; - bool m_closed; - bool m_stop; - }; - - - - - - //--------------------------------------------------------line_adaptor - class line_adaptor - { - public: - typedef double value_type; - - line_adaptor() : m_line(m_coord, 2, false) {} - line_adaptor(double x1, double y1, double x2, double y2) : - m_line(m_coord, 2, false) - { - m_coord[0] = x1; - m_coord[1] = y1; - m_coord[2] = x2; - m_coord[3] = y2; - } - - void init(double x1, double y1, double x2, double y2) - { - m_coord[0] = x1; - m_coord[1] = y1; - m_coord[2] = x2; - m_coord[3] = y2; - m_line.rewind(0); - } - - void rewind(unsigned) - { - m_line.rewind(0); - } - - unsigned vertex(double* x, double* y) - { - return m_line.vertex(x, y); - } - - private: - double m_coord[4]; - poly_plain_adaptor m_line; - }; - - - - - - - - - - - - - - //---------------------------------------------------------------path_base - // A container to store vertices with their flags. - // A path consists of a number of contours separated with "move_to" - // commands. The path storage can keep and maintain more than one - // path. - // To navigate to the beginning of a particular path, use rewind(path_id); - // Where path_id is what start_new_path() returns. So, when you call - // start_new_path() you need to store its return value somewhere else - // to navigate to the path afterwards. - // - // See also: vertex_source concept - //------------------------------------------------------------------------ - template class path_base - { - public: - typedef VertexContainer container_type; - typedef path_base self_type; - - //-------------------------------------------------------------------- - path_base() : m_vertices(), m_iterator(0) {} - void remove_all() { m_vertices.remove_all(); m_iterator = 0; } - void free_all() { m_vertices.free_all(); m_iterator = 0; } - - // Make path functions - //-------------------------------------------------------------------- - unsigned start_new_path(); - - void move_to(double x, double y); - void move_rel(double dx, double dy); - - void line_to(double x, double y); - void line_rel(double dx, double dy); - - void hline_to(double x); - void hline_rel(double dx); - - void vline_to(double y); - void vline_rel(double dy); - - void arc_to(double rx, double ry, - double angle, - bool large_arc_flag, - bool sweep_flag, - double x, double y); - - void arc_rel(double rx, double ry, - double angle, - bool large_arc_flag, - bool sweep_flag, - double dx, double dy); - - void curve3(double x_ctrl, double y_ctrl, - double x_to, double y_to); - - void curve3_rel(double dx_ctrl, double dy_ctrl, - double dx_to, double dy_to); - - void curve3(double x_to, double y_to); - - void curve3_rel(double dx_to, double dy_to); - - void curve4(double x_ctrl1, double y_ctrl1, - double x_ctrl2, double y_ctrl2, - double x_to, double y_to); - - void curve4_rel(double dx_ctrl1, double dy_ctrl1, - double dx_ctrl2, double dy_ctrl2, - double dx_to, double dy_to); - - void curve4(double x_ctrl2, double y_ctrl2, - double x_to, double y_to); - - void curve4_rel(double x_ctrl2, double y_ctrl2, - double x_to, double y_to); - - - void end_poly(unsigned flags = path_flags_close); - void close_polygon(unsigned flags = path_flags_none); - - // Accessors - //-------------------------------------------------------------------- - const container_type& vertices() const { return m_vertices; } - container_type& vertices() { return m_vertices; } - - unsigned total_vertices() const; - - void rel_to_abs(double* x, double* y) const; - - unsigned last_vertex(double* x, double* y) const; - unsigned prev_vertex(double* x, double* y) const; - - double last_x() const; - double last_y() const; - - unsigned vertex(unsigned idx, double* x, double* y) const; - unsigned command(unsigned idx) const; - - void modify_vertex(unsigned idx, double x, double y); - void modify_vertex(unsigned idx, double x, double y, unsigned cmd); - void modify_command(unsigned idx, unsigned cmd); - - // VertexSource interface - //-------------------------------------------------------------------- - void rewind(unsigned path_id); - unsigned vertex(double* x, double* y); - - // Arrange the orientation of a polygon, all polygons in a path, - // or in all paths. After calling arrange_orientations() or - // arrange_orientations_all_paths(), all the polygons will have - // the same orientation, i.e. path_flags_cw or path_flags_ccw - //-------------------------------------------------------------------- - unsigned arrange_polygon_orientation(unsigned start, path_flags_e orientation); - unsigned arrange_orientations(unsigned path_id, path_flags_e orientation); - void arrange_orientations_all_paths(path_flags_e orientation); - void invert_polygon(unsigned start); - - // Flip all vertices horizontally or vertically, - // between x1 and x2, or between y1 and y2 respectively - //-------------------------------------------------------------------- - void flip_x(double x1, double x2); - void flip_y(double y1, double y2); - - // Concatenate path. The path is added as is. - //-------------------------------------------------------------------- - template - void concat_path(VertexSource& vs, unsigned path_id = 0) - { - double x, y; - unsigned cmd; - vs.rewind(path_id); - while(!is_stop(cmd = vs.vertex(&x, &y))) - { - m_vertices.add_vertex(x, y, cmd); - } - } - - //-------------------------------------------------------------------- - // Join path. The path is joined with the existing one, that is, - // it behaves as if the pen of a plotter was always down (drawing) - template - void join_path(VertexSource& vs, unsigned path_id = 0) - { - double x, y; - unsigned cmd; - vs.rewind(path_id); - cmd = vs.vertex(&x, &y); - if(!is_stop(cmd)) - { - if(is_vertex(cmd)) - { - double x0, y0; - unsigned cmd0 = last_vertex(&x0, &y0); - if(is_vertex(cmd0)) - { - if(calc_distance(x, y, x0, y0) > vertex_dist_epsilon) - { - if(is_move_to(cmd)) cmd = path_cmd_line_to; - m_vertices.add_vertex(x, y, cmd); - } - } - else - { - if(is_stop(cmd0)) - { - cmd = path_cmd_move_to; - } - else - { - if(is_move_to(cmd)) cmd = path_cmd_line_to; - } - m_vertices.add_vertex(x, y, cmd); - } - } - while(!is_stop(cmd = vs.vertex(&x, &y))) - { - m_vertices.add_vertex(x, y, is_move_to(cmd) ? - unsigned(path_cmd_line_to) : - cmd); - } - } - } - - // Concatenate polygon/polyline. - //-------------------------------------------------------------------- - template void concat_poly(const T* data, - unsigned num_points, - bool closed) - { - poly_plain_adaptor poly(data, num_points, closed); - concat_path(poly); - } - - // Join polygon/polyline continuously. - //-------------------------------------------------------------------- - template void join_poly(const T* data, - unsigned num_points, - bool closed) - { - poly_plain_adaptor poly(data, num_points, closed); - join_path(poly); - } - - //-------------------------------------------------------------------- - void translate(double dx, double dy, unsigned path_id=0); - void translate_all_paths(double dx, double dy); - - //-------------------------------------------------------------------- - template - void transform(const Trans& trans, unsigned path_id=0) - { - unsigned num_ver = m_vertices.total_vertices(); - for(; path_id < num_ver; path_id++) - { - double x, y; - unsigned cmd = m_vertices.vertex(path_id, &x, &y); - if(is_stop(cmd)) break; - if(is_vertex(cmd)) - { - trans.transform(&x, &y); - m_vertices.modify_vertex(path_id, x, y); - } - } - } - - //-------------------------------------------------------------------- - template - void transform_all_paths(const Trans& trans) - { - unsigned idx; - unsigned num_ver = m_vertices.total_vertices(); - for(idx = 0; idx < num_ver; idx++) - { - double x, y; - if(is_vertex(m_vertices.vertex(idx, &x, &y))) - { - trans.transform(&x, &y); - m_vertices.modify_vertex(idx, x, y); - } - } - } - - - - private: - unsigned perceive_polygon_orientation(unsigned start, unsigned end); - void invert_polygon(unsigned start, unsigned end); - - VertexContainer m_vertices; - unsigned m_iterator; - }; - - //------------------------------------------------------------------------ - template - unsigned path_base::start_new_path() - { - if(!is_stop(m_vertices.last_command())) - { - m_vertices.add_vertex(0.0, 0.0, path_cmd_stop); - } - return m_vertices.total_vertices(); - } - - - //------------------------------------------------------------------------ - template - inline void path_base::rel_to_abs(double* x, double* y) const - { - if(m_vertices.total_vertices()) - { - double x2; - double y2; - if(is_vertex(m_vertices.last_vertex(&x2, &y2))) - { - *x += x2; - *y += y2; - } - } - } - - //------------------------------------------------------------------------ - template - inline void path_base::move_to(double x, double y) - { - m_vertices.add_vertex(x, y, path_cmd_move_to); - } - - //------------------------------------------------------------------------ - template - inline void path_base::move_rel(double dx, double dy) - { - rel_to_abs(&dx, &dy); - m_vertices.add_vertex(dx, dy, path_cmd_move_to); - } - - //------------------------------------------------------------------------ - template - inline void path_base::line_to(double x, double y) - { - m_vertices.add_vertex(x, y, path_cmd_line_to); - } - - //------------------------------------------------------------------------ - template - inline void path_base::line_rel(double dx, double dy) - { - rel_to_abs(&dx, &dy); - m_vertices.add_vertex(dx, dy, path_cmd_line_to); - } - - //------------------------------------------------------------------------ - template - inline void path_base::hline_to(double x) - { - m_vertices.add_vertex(x, last_y(), path_cmd_line_to); - } - - //------------------------------------------------------------------------ - template - inline void path_base::hline_rel(double dx) - { - double dy = 0; - rel_to_abs(&dx, &dy); - m_vertices.add_vertex(dx, dy, path_cmd_line_to); - } - - //------------------------------------------------------------------------ - template - inline void path_base::vline_to(double y) - { - m_vertices.add_vertex(last_x(), y, path_cmd_line_to); - } - - //------------------------------------------------------------------------ - template - inline void path_base::vline_rel(double dy) - { - double dx = 0; - rel_to_abs(&dx, &dy); - m_vertices.add_vertex(dx, dy, path_cmd_line_to); - } - - //------------------------------------------------------------------------ - template - void path_base::arc_to(double rx, double ry, - double angle, - bool large_arc_flag, - bool sweep_flag, - double x, double y) - { - if(m_vertices.total_vertices() && is_vertex(m_vertices.last_command())) - { - const double epsilon = 1e-30; - double x0 = 0.0; - double y0 = 0.0; - m_vertices.last_vertex(&x0, &y0); - - rx = fabs(rx); - ry = fabs(ry); - - // Ensure radii are valid - //------------------------- - if(rx < epsilon || ry < epsilon) - { - line_to(x, y); - return; - } - - if(calc_distance(x0, y0, x, y) < epsilon) - { - // If the endpoints (x, y) and (x0, y0) are identical, then this - // is equivalent to omitting the elliptical arc segment entirely. - return; - } - bezier_arc_svg a(x0, y0, rx, ry, angle, large_arc_flag, sweep_flag, x, y); - if(a.radii_ok()) - { - join_path(a); - } - else - { - line_to(x, y); - } - } - else - { - move_to(x, y); - } - } - - //------------------------------------------------------------------------ - template - void path_base::arc_rel(double rx, double ry, - double angle, - bool large_arc_flag, - bool sweep_flag, - double dx, double dy) - { - rel_to_abs(&dx, &dy); - arc_to(rx, ry, angle, large_arc_flag, sweep_flag, dx, dy); - } - - //------------------------------------------------------------------------ - template - void path_base::curve3(double x_ctrl, double y_ctrl, - double x_to, double y_to) - { - m_vertices.add_vertex(x_ctrl, y_ctrl, path_cmd_curve3); - m_vertices.add_vertex(x_to, y_to, path_cmd_curve3); - } - - //------------------------------------------------------------------------ - template - void path_base::curve3_rel(double dx_ctrl, double dy_ctrl, - double dx_to, double dy_to) - { - rel_to_abs(&dx_ctrl, &dy_ctrl); - rel_to_abs(&dx_to, &dy_to); - m_vertices.add_vertex(dx_ctrl, dy_ctrl, path_cmd_curve3); - m_vertices.add_vertex(dx_to, dy_to, path_cmd_curve3); - } - - //------------------------------------------------------------------------ - template - void path_base::curve3(double x_to, double y_to) - { - double x0; - double y0; - if(is_vertex(m_vertices.last_vertex(&x0, &y0))) - { - double x_ctrl; - double y_ctrl; - unsigned cmd = m_vertices.prev_vertex(&x_ctrl, &y_ctrl); - if(is_curve(cmd)) - { - x_ctrl = x0 + x0 - x_ctrl; - y_ctrl = y0 + y0 - y_ctrl; - } - else - { - x_ctrl = x0; - y_ctrl = y0; - } - curve3(x_ctrl, y_ctrl, x_to, y_to); - } - } - - //------------------------------------------------------------------------ - template - void path_base::curve3_rel(double dx_to, double dy_to) - { - rel_to_abs(&dx_to, &dy_to); - curve3(dx_to, dy_to); - } - - //------------------------------------------------------------------------ - template - void path_base::curve4(double x_ctrl1, double y_ctrl1, - double x_ctrl2, double y_ctrl2, - double x_to, double y_to) - { - m_vertices.add_vertex(x_ctrl1, y_ctrl1, path_cmd_curve4); - m_vertices.add_vertex(x_ctrl2, y_ctrl2, path_cmd_curve4); - m_vertices.add_vertex(x_to, y_to, path_cmd_curve4); - } - - //------------------------------------------------------------------------ - template - void path_base::curve4_rel(double dx_ctrl1, double dy_ctrl1, - double dx_ctrl2, double dy_ctrl2, - double dx_to, double dy_to) - { - rel_to_abs(&dx_ctrl1, &dy_ctrl1); - rel_to_abs(&dx_ctrl2, &dy_ctrl2); - rel_to_abs(&dx_to, &dy_to); - m_vertices.add_vertex(dx_ctrl1, dy_ctrl1, path_cmd_curve4); - m_vertices.add_vertex(dx_ctrl2, dy_ctrl2, path_cmd_curve4); - m_vertices.add_vertex(dx_to, dy_to, path_cmd_curve4); - } - - //------------------------------------------------------------------------ - template - void path_base::curve4(double x_ctrl2, double y_ctrl2, - double x_to, double y_to) - { - double x0; - double y0; - if(is_vertex(last_vertex(&x0, &y0))) - { - double x_ctrl1; - double y_ctrl1; - unsigned cmd = prev_vertex(&x_ctrl1, &y_ctrl1); - if(is_curve(cmd)) - { - x_ctrl1 = x0 + x0 - x_ctrl1; - y_ctrl1 = y0 + y0 - y_ctrl1; - } - else - { - x_ctrl1 = x0; - y_ctrl1 = y0; - } - curve4(x_ctrl1, y_ctrl1, x_ctrl2, y_ctrl2, x_to, y_to); - } - } - - //------------------------------------------------------------------------ - template - void path_base::curve4_rel(double dx_ctrl2, double dy_ctrl2, - double dx_to, double dy_to) - { - rel_to_abs(&dx_ctrl2, &dy_ctrl2); - rel_to_abs(&dx_to, &dy_to); - curve4(dx_ctrl2, dy_ctrl2, dx_to, dy_to); - } - - //------------------------------------------------------------------------ - template - inline void path_base::end_poly(unsigned flags) - { - if(is_vertex(m_vertices.last_command())) - { - m_vertices.add_vertex(0.0, 0.0, path_cmd_end_poly | flags); - } - } - - //------------------------------------------------------------------------ - template - inline void path_base::close_polygon(unsigned flags) - { - end_poly(path_flags_close | flags); - } - - //------------------------------------------------------------------------ - template - inline unsigned path_base::total_vertices() const - { - return m_vertices.total_vertices(); - } - - //------------------------------------------------------------------------ - template - inline unsigned path_base::last_vertex(double* x, double* y) const - { - return m_vertices.last_vertex(x, y); - } - - //------------------------------------------------------------------------ - template - inline unsigned path_base::prev_vertex(double* x, double* y) const - { - return m_vertices.prev_vertex(x, y); - } - - //------------------------------------------------------------------------ - template - inline double path_base::last_x() const - { - return m_vertices.last_x(); - } - - //------------------------------------------------------------------------ - template - inline double path_base::last_y() const - { - return m_vertices.last_y(); - } - - //------------------------------------------------------------------------ - template - inline unsigned path_base::vertex(unsigned idx, double* x, double* y) const - { - return m_vertices.vertex(idx, x, y); - } - - //------------------------------------------------------------------------ - template - inline unsigned path_base::command(unsigned idx) const - { - return m_vertices.command(idx); - } - - //------------------------------------------------------------------------ - template - void path_base::modify_vertex(unsigned idx, double x, double y) - { - m_vertices.modify_vertex(idx, x, y); - } - - //------------------------------------------------------------------------ - template - void path_base::modify_vertex(unsigned idx, double x, double y, unsigned cmd) - { - m_vertices.modify_vertex(idx, x, y, cmd); - } - - //------------------------------------------------------------------------ - template - void path_base::modify_command(unsigned idx, unsigned cmd) - { - m_vertices.modify_command(idx, cmd); - } - - //------------------------------------------------------------------------ - template - inline void path_base::rewind(unsigned path_id) - { - m_iterator = path_id; - } - - //------------------------------------------------------------------------ - template - inline unsigned path_base::vertex(double* x, double* y) - { - if(m_iterator >= m_vertices.total_vertices()) return path_cmd_stop; - return m_vertices.vertex(m_iterator++, x, y); - } - - //------------------------------------------------------------------------ - template - unsigned path_base::perceive_polygon_orientation(unsigned start, - unsigned end) - { - // Calculate signed area (double area to be exact) - //--------------------- - unsigned np = end - start; - double area = 0.0; - unsigned i; - for(i = 0; i < np; i++) - { - double x1, y1, x2, y2; - m_vertices.vertex(start + i, &x1, &y1); - m_vertices.vertex(start + (i + 1) % np, &x2, &y2); - area += x1 * y2 - y1 * x2; - } - return (area < 0.0) ? path_flags_cw : path_flags_ccw; - } - - //------------------------------------------------------------------------ - template - void path_base::invert_polygon(unsigned start, unsigned end) - { - unsigned i; - unsigned tmp_cmd = m_vertices.command(start); - - --end; // Make "end" inclusive - - // Shift all commands to one position - for(i = start; i < end; i++) - { - m_vertices.modify_command(i, m_vertices.command(i + 1)); - } - - // Assign starting command to the ending command - m_vertices.modify_command(end, tmp_cmd); - - // Reverse the polygon - while(end > start) - { - m_vertices.swap_vertices(start++, end--); - } - } - - //------------------------------------------------------------------------ - template - void path_base::invert_polygon(unsigned start) - { - // Skip all non-vertices at the beginning - while(start < m_vertices.total_vertices() && - !is_vertex(m_vertices.command(start))) ++start; - - // Skip all insignificant move_to - while(start+1 < m_vertices.total_vertices() && - is_move_to(m_vertices.command(start)) && - is_move_to(m_vertices.command(start+1))) ++start; - - // Find the last vertex - unsigned end = start + 1; - while(end < m_vertices.total_vertices() && - !is_next_poly(m_vertices.command(end))) ++end; - - invert_polygon(start, end); - } - - //------------------------------------------------------------------------ - template - unsigned path_base::arrange_polygon_orientation(unsigned start, - path_flags_e orientation) - { - if(orientation == path_flags_none) return start; - - // Skip all non-vertices at the beginning - while(start < m_vertices.total_vertices() && - !is_vertex(m_vertices.command(start))) ++start; - - // Skip all insignificant move_to - while(start+1 < m_vertices.total_vertices() && - is_move_to(m_vertices.command(start)) && - is_move_to(m_vertices.command(start+1))) ++start; - - // Find the last vertex - unsigned end = start + 1; - while(end < m_vertices.total_vertices() && - !is_next_poly(m_vertices.command(end))) ++end; - - if(end - start > 2) - { - if(perceive_polygon_orientation(start, end) != unsigned(orientation)) - { - // Invert polygon, set orientation flag, and skip all end_poly - invert_polygon(start, end); - unsigned cmd; - while(end < m_vertices.total_vertices() && - is_end_poly(cmd = m_vertices.command(end))) - { - m_vertices.modify_command(end++, set_orientation(cmd, orientation)); - } - } - } - return end; - } - - //------------------------------------------------------------------------ - template - unsigned path_base::arrange_orientations(unsigned start, - path_flags_e orientation) - { - if(orientation != path_flags_none) - { - while(start < m_vertices.total_vertices()) - { - start = arrange_polygon_orientation(start, orientation); - if(is_stop(m_vertices.command(start))) - { - ++start; - break; - } - } - } - return start; - } - - //------------------------------------------------------------------------ - template - void path_base::arrange_orientations_all_paths(path_flags_e orientation) - { - if(orientation != path_flags_none) - { - unsigned start = 0; - while(start < m_vertices.total_vertices()) - { - start = arrange_orientations(start, orientation); - } - } - } - - //------------------------------------------------------------------------ - template - void path_base::flip_x(double x1, double x2) - { - unsigned i; - double x, y; - for(i = 0; i < m_vertices.total_vertices(); i++) - { - unsigned cmd = m_vertices.vertex(i, &x, &y); - if(is_vertex(cmd)) - { - m_vertices.modify_vertex(i, x2 - x + x1, y); - } - } - } - - //------------------------------------------------------------------------ - template - void path_base::flip_y(double y1, double y2) - { - unsigned i; - double x, y; - for(i = 0; i < m_vertices.total_vertices(); i++) - { - unsigned cmd = m_vertices.vertex(i, &x, &y); - if(is_vertex(cmd)) - { - m_vertices.modify_vertex(i, x, y2 - y + y1); - } - } - } - - //------------------------------------------------------------------------ - template - void path_base::translate(double dx, double dy, unsigned path_id) - { - unsigned num_ver = m_vertices.total_vertices(); - for(; path_id < num_ver; path_id++) - { - double x, y; - unsigned cmd = m_vertices.vertex(path_id, &x, &y); - if(is_stop(cmd)) break; - if(is_vertex(cmd)) - { - x += dx; - y += dy; - m_vertices.modify_vertex(path_id, x, y); - } - } - } - - //------------------------------------------------------------------------ - template - void path_base::translate_all_paths(double dx, double dy) - { - unsigned idx; - unsigned num_ver = m_vertices.total_vertices(); - for(idx = 0; idx < num_ver; idx++) - { - double x, y; - if(is_vertex(m_vertices.vertex(idx, &x, &y))) - { - x += dx; - y += dy; - m_vertices.modify_vertex(idx, x, y); - } - } - } - - //-----------------------------------------------------vertex_stl_storage - template class vertex_stl_storage - { - public: - typedef typename Container::value_type vertex_type; - typedef typename vertex_type::value_type value_type; - - void remove_all() { m_vertices.clear(); } - void free_all() { m_vertices.clear(); } - - void add_vertex(double x, double y, unsigned cmd) - { - m_vertices.push_back(vertex_type(value_type(x), - value_type(y), - int8u(cmd))); - } - - void modify_vertex(unsigned idx, double x, double y) - { - vertex_type& v = m_vertices[idx]; - v.x = value_type(x); - v.y = value_type(y); - } - - void modify_vertex(unsigned idx, double x, double y, unsigned cmd) - { - vertex_type& v = m_vertices[idx]; - v.x = value_type(x); - v.y = value_type(y); - v.cmd = int8u(cmd); - } - - void modify_command(unsigned idx, unsigned cmd) - { - m_vertices[idx].cmd = int8u(cmd); - } - - void swap_vertices(unsigned v1, unsigned v2) - { - vertex_type t = m_vertices[v1]; - m_vertices[v1] = m_vertices[v2]; - m_vertices[v2] = t; - } - - unsigned last_command() const - { - return m_vertices.size() ? - m_vertices[m_vertices.size() - 1].cmd : - path_cmd_stop; - } - - unsigned last_vertex(double* x, double* y) const - { - if(m_vertices.size() == 0) - { - *x = *y = 0.0; - return path_cmd_stop; - } - return vertex(m_vertices.size() - 1, x, y); - } - - unsigned prev_vertex(double* x, double* y) const - { - if(m_vertices.size() < 2) - { - *x = *y = 0.0; - return path_cmd_stop; - } - return vertex(m_vertices.size() - 2, x, y); - } - - double last_x() const - { - return m_vertices.size() ? m_vertices[m_vertices.size() - 1].x : 0.0; - } - - double last_y() const - { - return m_vertices.size() ? m_vertices[m_vertices.size() - 1].y : 0.0; - } - - unsigned total_vertices() const - { - return m_vertices.size(); - } - - unsigned vertex(unsigned idx, double* x, double* y) const - { - const vertex_type& v = m_vertices[idx]; - *x = v.x; - *y = v.y; - return v.cmd; - } - - unsigned command(unsigned idx) const - { - return m_vertices[idx].cmd; - } - - private: - Container m_vertices; - }; - - //-----------------------------------------------------------path_storage - typedef path_base > path_storage; - - // Example of declarations path_storage with pod_bvector as a container - //----------------------------------------------------------------------- - //typedef path_base > > path_storage; - -} - - - -// Example of declarations path_storage with std::vector as a container -//--------------------------------------------------------------------------- -//#include -//namespace agg -//{ -// typedef path_base > > stl_path_storage; -//} - - - - -#endif diff --git a/desmume/src/windows/agg/include/agg_path_storage_integer.h b/desmume/src/windows/agg/include/agg_path_storage_integer.h deleted file mode 100644 index 301e5f8af..000000000 --- a/desmume/src/windows/agg/include/agg_path_storage_integer.h +++ /dev/null @@ -1,304 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_PATH_STORAGE_INTEGER_INCLUDED -#define AGG_PATH_STORAGE_INTEGER_INCLUDED - -#include -#include "agg_array.h" - -namespace agg -{ - //---------------------------------------------------------vertex_integer - template struct vertex_integer - { - enum path_cmd - { - cmd_move_to = 0, - cmd_line_to = 1, - cmd_curve3 = 2, - cmd_curve4 = 3 - }; - - enum coord_scale_e - { - coord_shift = CoordShift, - coord_scale = 1 << coord_shift - }; - - T x,y; - vertex_integer() {} - vertex_integer(T x_, T y_, unsigned flag) : - x(((x_ << 1) & ~1) | (flag & 1)), - y(((y_ << 1) & ~1) | (flag >> 1)) {} - - unsigned vertex(double* x_, double* y_, - double dx=0, double dy=0, - double scale=1.0) const - { - *x_ = dx + (double(x >> 1) / coord_scale) * scale; - *y_ = dy + (double(y >> 1) / coord_scale) * scale; - switch(((y & 1) << 1) | (x & 1)) - { - case cmd_move_to: return path_cmd_move_to; - case cmd_line_to: return path_cmd_line_to; - case cmd_curve3: return path_cmd_curve3; - case cmd_curve4: return path_cmd_curve4; - } - return path_cmd_stop; - } - }; - - - //---------------------------------------------------path_storage_integer - template class path_storage_integer - { - public: - typedef T value_type; - typedef vertex_integer vertex_integer_type; - - //-------------------------------------------------------------------- - path_storage_integer() : m_storage(), m_vertex_idx(0), m_closed(true) {} - - //-------------------------------------------------------------------- - void remove_all() { m_storage.remove_all(); } - - //-------------------------------------------------------------------- - void move_to(T x, T y) - { - m_storage.add(vertex_integer_type(x, y, vertex_integer_type::cmd_move_to)); - } - - //-------------------------------------------------------------------- - void line_to(T x, T y) - { - m_storage.add(vertex_integer_type(x, y, vertex_integer_type::cmd_line_to)); - } - - //-------------------------------------------------------------------- - void curve3(T x_ctrl, T y_ctrl, - T x_to, T y_to) - { - m_storage.add(vertex_integer_type(x_ctrl, y_ctrl, vertex_integer_type::cmd_curve3)); - m_storage.add(vertex_integer_type(x_to, y_to, vertex_integer_type::cmd_curve3)); - } - - //-------------------------------------------------------------------- - void curve4(T x_ctrl1, T y_ctrl1, - T x_ctrl2, T y_ctrl2, - T x_to, T y_to) - { - m_storage.add(vertex_integer_type(x_ctrl1, y_ctrl1, vertex_integer_type::cmd_curve4)); - m_storage.add(vertex_integer_type(x_ctrl2, y_ctrl2, vertex_integer_type::cmd_curve4)); - m_storage.add(vertex_integer_type(x_to, y_to, vertex_integer_type::cmd_curve4)); - } - - //-------------------------------------------------------------------- - void close_polygon() {} - - //-------------------------------------------------------------------- - unsigned size() const { return m_storage.size(); } - unsigned vertex(unsigned idx, double* x, double* y) const - { - return m_storage[idx].vertex(x, y); - } - - //-------------------------------------------------------------------- - unsigned byte_size() const { return m_storage.size() * sizeof(vertex_integer_type); } - void serialize(int8u* ptr) const - { - unsigned i; - for(i = 0; i < m_storage.size(); i++) - { - memcpy(ptr, &m_storage[i], sizeof(vertex_integer_type)); - ptr += sizeof(vertex_integer_type); - } - } - - //-------------------------------------------------------------------- - void rewind(unsigned) - { - m_vertex_idx = 0; - m_closed = true; - } - - //-------------------------------------------------------------------- - unsigned vertex(double* x, double* y) - { - if(m_storage.size() < 2 || m_vertex_idx > m_storage.size()) - { - *x = 0; - *y = 0; - return path_cmd_stop; - } - if(m_vertex_idx == m_storage.size()) - { - *x = 0; - *y = 0; - ++m_vertex_idx; - return path_cmd_end_poly | path_flags_close; - } - unsigned cmd = m_storage[m_vertex_idx].vertex(x, y); - if(is_move_to(cmd) && !m_closed) - { - *x = 0; - *y = 0; - m_closed = true; - return path_cmd_end_poly | path_flags_close; - } - m_closed = false; - ++m_vertex_idx; - return cmd; - } - - //-------------------------------------------------------------------- - rect_d bounding_rect() const - { - rect_d bounds(1e100, 1e100, -1e100, -1e100); - if(m_storage.size() == 0) - { - bounds.x1 = bounds.y1 = bounds.x2 = bounds.y2 = 0.0; - } - else - { - unsigned i; - for(i = 0; i < m_storage.size(); i++) - { - double x, y; - m_storage[i].vertex(&x, &y); - if(x < bounds.x1) bounds.x1 = x; - if(y < bounds.y1) bounds.y1 = y; - if(x > bounds.x2) bounds.x2 = x; - if(y > bounds.y2) bounds.y2 = y; - } - } - return bounds; - } - - private: - pod_bvector m_storage; - unsigned m_vertex_idx; - bool m_closed; - }; - - - - - //-----------------------------------------serialized_integer_path_adaptor - template class serialized_integer_path_adaptor - { - public: - typedef vertex_integer vertex_integer_type; - - //-------------------------------------------------------------------- - serialized_integer_path_adaptor() : - m_data(0), - m_end(0), - m_ptr(0), - m_dx(0.0), - m_dy(0.0), - m_scale(1.0), - m_vertices(0) - {} - - //-------------------------------------------------------------------- - serialized_integer_path_adaptor(const int8u* data, unsigned size, - double dx, double dy) : - m_data(data), - m_end(data + size), - m_ptr(data), - m_dx(dx), - m_dy(dy), - m_vertices(0) - {} - - //-------------------------------------------------------------------- - void init(const int8u* data, unsigned size, - double dx, double dy, double scale=1.0) - { - m_data = data; - m_end = data + size; - m_ptr = data; - m_dx = dx; - m_dy = dy; - m_scale = scale; - m_vertices = 0; - } - - - //-------------------------------------------------------------------- - void rewind(unsigned) - { - m_ptr = m_data; - m_vertices = 0; - } - - //-------------------------------------------------------------------- - unsigned vertex(double* x, double* y) - { - if(m_data == 0 || m_ptr > m_end) - { - *x = 0; - *y = 0; - return path_cmd_stop; - } - - if(m_ptr == m_end) - { - *x = 0; - *y = 0; - m_ptr += sizeof(vertex_integer_type); - return path_cmd_end_poly | path_flags_close; - } - - vertex_integer_type v; - memcpy(&v, m_ptr, sizeof(vertex_integer_type)); - unsigned cmd = v.vertex(x, y, m_dx, m_dy, m_scale); - if(is_move_to(cmd) && m_vertices > 2) - { - *x = 0; - *y = 0; - m_vertices = 0; - return path_cmd_end_poly | path_flags_close; - } - ++m_vertices; - m_ptr += sizeof(vertex_integer_type); - return cmd; - } - - private: - const int8u* m_data; - const int8u* m_end; - const int8u* m_ptr; - double m_dx; - double m_dy; - double m_scale; - unsigned m_vertices; - }; - -} - - -#endif - diff --git a/desmume/src/windows/agg/include/agg_pattern_filters_rgba.h b/desmume/src/windows/agg/include/agg_pattern_filters_rgba.h deleted file mode 100644 index a58cb66f5..000000000 --- a/desmume/src/windows/agg/include/agg_pattern_filters_rgba.h +++ /dev/null @@ -1,132 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_PATTERN_FILTERS_RGBA8_INCLUDED -#define AGG_PATTERN_FILTERS_RGBA8_INCLUDED - -#include "agg_basics.h" -#include "agg_line_aa_basics.h" -#include "agg_color_rgba.h" - - -namespace agg -{ - - //=======================================================pattern_filter_nn - template struct pattern_filter_nn - { - typedef ColorT color_type; - static unsigned dilation() { return 0; } - - static void AGG_INLINE pixel_low_res(color_type const* const* buf, - color_type* p, int x, int y) - { - *p = buf[y][x]; - } - - static void AGG_INLINE pixel_high_res(color_type const* const* buf, - color_type* p, int x, int y) - { - *p = buf[y >> line_subpixel_shift] - [x >> line_subpixel_shift]; - } - }; - - typedef pattern_filter_nn pattern_filter_nn_rgba8; - typedef pattern_filter_nn pattern_filter_nn_rgba16; - - - //===========================================pattern_filter_bilinear_rgba - template struct pattern_filter_bilinear_rgba - { - typedef ColorT color_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - - - static unsigned dilation() { return 1; } - - static AGG_INLINE void pixel_low_res(color_type const* const* buf, - color_type* p, int x, int y) - { - *p = buf[y][x]; - } - - static AGG_INLINE void pixel_high_res(color_type const* const* buf, - color_type* p, int x, int y) - { - calc_type r, g, b, a; - r = g = b = a = line_subpixel_scale * line_subpixel_scale / 2; - - calc_type weight; - int x_lr = x >> line_subpixel_shift; - int y_lr = y >> line_subpixel_shift; - - x &= line_subpixel_mask; - y &= line_subpixel_mask; - const color_type* ptr = buf[y_lr] + x_lr; - - weight = (line_subpixel_scale - x) * - (line_subpixel_scale - y); - r += weight * ptr->r; - g += weight * ptr->g; - b += weight * ptr->b; - a += weight * ptr->a; - - ++ptr; - - weight = x * (line_subpixel_scale - y); - r += weight * ptr->r; - g += weight * ptr->g; - b += weight * ptr->b; - a += weight * ptr->a; - - ptr = buf[y_lr + 1] + x_lr; - - weight = (line_subpixel_scale - x) * y; - r += weight * ptr->r; - g += weight * ptr->g; - b += weight * ptr->b; - a += weight * ptr->a; - - ++ptr; - - weight = x * y; - r += weight * ptr->r; - g += weight * ptr->g; - b += weight * ptr->b; - a += weight * ptr->a; - - p->r = (value_type)(r >> line_subpixel_shift * 2); - p->g = (value_type)(g >> line_subpixel_shift * 2); - p->b = (value_type)(b >> line_subpixel_shift * 2); - p->a = (value_type)(a >> line_subpixel_shift * 2); - } - }; - - typedef pattern_filter_bilinear_rgba pattern_filter_bilinear_rgba8; - typedef pattern_filter_bilinear_rgba pattern_filter_bilinear_rgba16; -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_pixfmt_amask_adaptor.h b/desmume/src/windows/agg/include/agg_pixfmt_amask_adaptor.h deleted file mode 100644 index 66d7bb1b3..000000000 --- a/desmume/src/windows/agg/include/agg_pixfmt_amask_adaptor.h +++ /dev/null @@ -1,249 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_PIXFMT_AMASK_ADAPTOR_INCLUDED -#define AGG_PIXFMT_AMASK_ADAPTOR_INCLUDED - - -#include -#include "agg_array.h" -#include "agg_rendering_buffer.h" - - -namespace agg -{ - //==================================================pixfmt_amask_adaptor - template class pixfmt_amask_adaptor - { - public: - typedef PixFmt pixfmt_type; - typedef typename pixfmt_type::color_type color_type; - typedef typename pixfmt_type::row_data row_data; - typedef AlphaMask amask_type; - typedef typename amask_type::cover_type cover_type; - - private: - enum span_extra_tail_e { span_extra_tail = 256 }; - - void realloc_span(unsigned len) - { - if(len > m_span.size()) - { - m_span.resize(len + span_extra_tail); - } - } - - void init_span(unsigned len) - { - realloc_span(len); - memset(&m_span[0], amask_type::cover_full, len * sizeof(cover_type)); - } - - void init_span(unsigned len, const cover_type* covers) - { - realloc_span(len); - memcpy(&m_span[0], covers, len * sizeof(cover_type)); - } - - - public: - pixfmt_amask_adaptor(pixfmt_type& pixf, const amask_type& mask) : - m_pixf(&pixf), m_mask(&mask), m_span() - {} - - void attach_pixfmt(pixfmt_type& pixf) { m_pixf = &pixf; } - void attach_alpha_mask(const amask_type& mask) { m_mask = &mask; } - - //-------------------------------------------------------------------- - template - bool attach_pixfmt(PixFmt2& pixf, int x1, int y1, int x2, int y2) - { - return m_pixf->attach(pixf, x1, y1, x2, y2); - } - - //-------------------------------------------------------------------- - unsigned width() const { return m_pixf->width(); } - unsigned height() const { return m_pixf->height(); } - - //-------------------------------------------------------------------- - color_type pixel(int x, int y) - { - return m_pixf->pixel(x, y); - } - - //-------------------------------------------------------------------- - void copy_pixel(int x, int y, const color_type& c) - { - m_pixf->blend_pixel(x, y, c, m_mask->pixel(x, y)); - } - - //-------------------------------------------------------------------- - void blend_pixel(int x, int y, const color_type& c, cover_type cover) - { - m_pixf->blend_pixel(x, y, c, m_mask->combine_pixel(x, y, cover)); - } - - //-------------------------------------------------------------------- - void copy_hline(int x, int y, - unsigned len, - const color_type& c) - { - realloc_span(len); - m_mask->fill_hspan(x, y, &m_span[0], len); - m_pixf->blend_solid_hspan(x, y, len, c, &m_span[0]); - } - - //-------------------------------------------------------------------- - void blend_hline(int x, int y, - unsigned len, - const color_type& c, - cover_type cover) - { - init_span(len); - m_mask->combine_hspan(x, y, &m_span[0], len); - m_pixf->blend_solid_hspan(x, y, len, c, &m_span[0]); - } - - //-------------------------------------------------------------------- - void copy_vline(int x, int y, - unsigned len, - const color_type& c) - { - realloc_span(len); - m_mask->fill_vspan(x, y, &m_span[0], len); - m_pixf->blend_solid_vspan(x, y, len, c, &m_span[0]); - } - - //-------------------------------------------------------------------- - void blend_vline(int x, int y, - unsigned len, - const color_type& c, - cover_type cover) - { - init_span(len); - m_mask->combine_vspan(x, y, &m_span[0], len); - m_pixf->blend_solid_vspan(x, y, len, c, &m_span[0]); - } - - //-------------------------------------------------------------------- - void copy_from(const rendering_buffer& from, - int xdst, int ydst, - int xsrc, int ysrc, - unsigned len) - { - m_pixf->copy_from(from, xdst, ydst, xsrc, ysrc, len); - } - - - //-------------------------------------------------------------------- - void blend_solid_hspan(int x, int y, - unsigned len, - const color_type& c, - const cover_type* covers) - { - init_span(len, covers); - m_mask->combine_hspan(x, y, &m_span[0], len); - m_pixf->blend_solid_hspan(x, y, len, c, &m_span[0]); - } - - - //-------------------------------------------------------------------- - void blend_solid_vspan(int x, int y, - unsigned len, - const color_type& c, - const cover_type* covers) - { - init_span(len, covers); - m_mask->combine_vspan(x, y, &m_span[0], len); - m_pixf->blend_solid_vspan(x, y, len, c, &m_span[0]); - } - - - //-------------------------------------------------------------------- - void copy_color_hspan(int x, int y, unsigned len, const color_type* colors) - { - realloc_span(len); - m_mask->fill_hspan(x, y, &m_span[0], len); - m_pixf->blend_color_hspan(x, y, len, colors, &m_span[0], cover_full); - } - - //-------------------------------------------------------------------- - void copy_color_vspan(int x, int y, unsigned len, const color_type* colors) - { - realloc_span(len); - m_mask->fill_vspan(x, y, &m_span[0], len); - m_pixf->blend_color_vspan(x, y, len, colors, &m_span[0], cover_full); - } - - //-------------------------------------------------------------------- - void blend_color_hspan(int x, int y, - unsigned len, - const color_type* colors, - const cover_type* covers, - cover_type cover = cover_full) - { - if(covers) - { - init_span(len, covers); - m_mask->combine_hspan(x, y, &m_span[0], len); - } - else - { - realloc_span(len); - m_mask->fill_hspan(x, y, &m_span[0], len); - } - m_pixf->blend_color_hspan(x, y, len, colors, &m_span[0], cover); - } - - - //-------------------------------------------------------------------- - void blend_color_vspan(int x, int y, - unsigned len, - const color_type* colors, - const cover_type* covers, - cover_type cover = cover_full) - { - if(covers) - { - init_span(len, covers); - m_mask->combine_vspan(x, y, &m_span[0], len); - } - else - { - realloc_span(len); - m_mask->fill_vspan(x, y, &m_span[0], len); - } - m_pixf->blend_color_vspan(x, y, len, colors, &m_span[0], cover); - } - - private: - pixfmt_type* m_pixf; - const amask_type* m_mask; - pod_array m_span; - }; - -} - -#endif - diff --git a/desmume/src/windows/agg/include/agg_pixfmt_gray.h b/desmume/src/windows/agg/include/agg_pixfmt_gray.h deleted file mode 100644 index 5870b9523..000000000 --- a/desmume/src/windows/agg/include/agg_pixfmt_gray.h +++ /dev/null @@ -1,679 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- -// -// Adaptation for high precision colors has been sponsored by -// Liberty Technology Systems, Inc., visit http://lib-sys.com -// -// Liberty Technology Systems, Inc. is the provider of -// PostScript and PDF technology for software developers. -// -//---------------------------------------------------------------------------- - -#ifndef AGG_PIXFMT_GRAY_INCLUDED -#define AGG_PIXFMT_GRAY_INCLUDED - -#include -#include "agg_basics.h" -#include "agg_color_gray.h" -#include "agg_rendering_buffer.h" - -namespace agg -{ - - //============================================================blender_gray - template struct blender_gray - { - typedef ColorT color_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - enum base_scale_e { base_shift = color_type::base_shift }; - - static AGG_INLINE void blend_pix(value_type* p, unsigned cv, - unsigned alpha, unsigned cover=0) - { - *p = (value_type)((((cv - calc_type(*p)) * alpha) + (calc_type(*p) << base_shift)) >> base_shift); - } - }; - - - //======================================================blender_gray_pre - template struct blender_gray_pre - { - typedef ColorT color_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - enum base_scale_e { base_shift = color_type::base_shift }; - - static AGG_INLINE void blend_pix(value_type* p, unsigned cv, - unsigned alpha, unsigned cover) - { - alpha = color_type::base_mask - alpha; - cover = (cover + 1) << (base_shift - 8); - *p = (value_type)((*p * alpha + cv * cover) >> base_shift); - } - - static AGG_INLINE void blend_pix(value_type* p, unsigned cv, - unsigned alpha) - { - *p = (value_type)(((*p * (color_type::base_mask - alpha)) >> base_shift) + cv); - } - }; - - - - //=====================================================apply_gamma_dir_gray - template class apply_gamma_dir_gray - { - public: - typedef typename ColorT::value_type value_type; - - apply_gamma_dir_gray(const GammaLut& gamma) : m_gamma(gamma) {} - - AGG_INLINE void operator () (value_type* p) - { - *p = m_gamma.dir(*p); - } - - private: - const GammaLut& m_gamma; - }; - - - - //=====================================================apply_gamma_inv_gray - template class apply_gamma_inv_gray - { - public: - typedef typename ColorT::value_type value_type; - - apply_gamma_inv_gray(const GammaLut& gamma) : m_gamma(gamma) {} - - AGG_INLINE void operator () (value_type* p) - { - *p = m_gamma.inv(*p); - } - - private: - const GammaLut& m_gamma; - }; - - - - //=================================================pixfmt_alpha_blend_gray - template - class pixfmt_alpha_blend_gray - { - public: - typedef RenBuf rbuf_type; - typedef typename rbuf_type::row_data row_data; - typedef Blender blender_type; - typedef typename blender_type::color_type color_type; - typedef int order_type; // A fake one - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_scale = color_type::base_scale, - base_mask = color_type::base_mask, - pix_width = sizeof(value_type), - pix_step = Step, - pix_offset = Offset - }; - - private: - //-------------------------------------------------------------------- - static AGG_INLINE void copy_or_blend_pix(value_type* p, - const color_type& c, - unsigned cover) - { - if (c.a) - { - calc_type alpha = (calc_type(c.a) * (cover + 1)) >> 8; - if(alpha == base_mask) - { - *p = c.v; - } - else - { - Blender::blend_pix(p, c.v, alpha, cover); - } - } - } - - - static AGG_INLINE void copy_or_blend_pix(value_type* p, - const color_type& c) - { - if (c.a) - { - if(c.a == base_mask) - { - *p = c.v; - } - else - { - Blender::blend_pix(p, c.v, c.a); - } - } - } - - - public: - //-------------------------------------------------------------------- - explicit pixfmt_alpha_blend_gray(rbuf_type& rb) : - m_rbuf(&rb) - {} - void attach(rbuf_type& rb) { m_rbuf = &rb; } - //-------------------------------------------------------------------- - - template - bool attach(PixFmt& pixf, int x1, int y1, int x2, int y2) - { - rect_i r(x1, y1, x2, y2); - if(r.clip(rect_i(0, 0, pixf.width()-1, pixf.height()-1))) - { - int stride = pixf.stride(); - m_rbuf->attach(pixf.pix_ptr(r.x1, stride < 0 ? r.y2 : r.y1), - (r.x2 - r.x1) + 1, - (r.y2 - r.y1) + 1, - stride); - return true; - } - return false; - } - - //-------------------------------------------------------------------- - AGG_INLINE unsigned width() const { return m_rbuf->width(); } - AGG_INLINE unsigned height() const { return m_rbuf->height(); } - AGG_INLINE int stride() const { return m_rbuf->stride(); } - - //-------------------------------------------------------------------- - int8u* row_ptr(int y) { return m_rbuf->row_ptr(y); } - const int8u* row_ptr(int y) const { return m_rbuf->row_ptr(y); } - row_data row(int y) const { return m_rbuf->row(y); } - - const int8u* pix_ptr(int x, int y) const - { - return m_rbuf->row_ptr(y) + x * Step + Offset; - } - - int8u* pix_ptr(int x, int y) - { - return m_rbuf->row_ptr(y) + x * Step + Offset; - } - - //-------------------------------------------------------------------- - AGG_INLINE static void make_pix(int8u* p, const color_type& c) - { - *(value_type*)p = c.v; - } - - //-------------------------------------------------------------------- - AGG_INLINE color_type pixel(int x, int y) const - { - value_type* p = (value_type*)m_rbuf->row_ptr(y) + x * Step + Offset; - return color_type(*p); - } - - //-------------------------------------------------------------------- - AGG_INLINE void copy_pixel(int x, int y, const color_type& c) - { - *((value_type*)m_rbuf->row_ptr(x, y, 1) + x * Step + Offset) = c.v; - } - - //-------------------------------------------------------------------- - AGG_INLINE void blend_pixel(int x, int y, const color_type& c, int8u cover) - { - copy_or_blend_pix((value_type*) - m_rbuf->row_ptr(x, y, 1) + x * Step + Offset, - c, - cover); - } - - - //-------------------------------------------------------------------- - AGG_INLINE void copy_hline(int x, int y, - unsigned len, - const color_type& c) - { - value_type* p = (value_type*) - m_rbuf->row_ptr(x, y, len) + x * Step + Offset; - - do - { - *p = c.v; - p += Step; - } - while(--len); - } - - - //-------------------------------------------------------------------- - AGG_INLINE void copy_vline(int x, int y, - unsigned len, - const color_type& c) - { - do - { - value_type* p = (value_type*) - m_rbuf->row_ptr(x, y++, 1) + x * Step + Offset; - - *p = c.v; - } - while(--len); - } - - - //-------------------------------------------------------------------- - void blend_hline(int x, int y, - unsigned len, - const color_type& c, - int8u cover) - { - if (c.a) - { - value_type* p = (value_type*) - m_rbuf->row_ptr(x, y, len) + x * Step + Offset; - - calc_type alpha = (calc_type(c.a) * (cover + 1)) >> 8; - if(alpha == base_mask) - { - do - { - *p = c.v; - p += Step; - } - while(--len); - } - else - { - do - { - Blender::blend_pix(p, c.v, alpha, cover); - p += Step; - } - while(--len); - } - } - } - - - //-------------------------------------------------------------------- - void blend_vline(int x, int y, - unsigned len, - const color_type& c, - int8u cover) - { - if (c.a) - { - value_type* p; - calc_type alpha = (calc_type(c.a) * (cover + 1)) >> 8; - if(alpha == base_mask) - { - do - { - p = (value_type*) - m_rbuf->row_ptr(x, y++, 1) + x * Step + Offset; - - *p = c.v; - } - while(--len); - } - else - { - do - { - p = (value_type*) - m_rbuf->row_ptr(x, y++, 1) + x * Step + Offset; - - Blender::blend_pix(p, c.v, alpha, cover); - } - while(--len); - } - } - } - - - //-------------------------------------------------------------------- - void blend_solid_hspan(int x, int y, - unsigned len, - const color_type& c, - const int8u* covers) - { - if (c.a) - { - value_type* p = (value_type*) - m_rbuf->row_ptr(x, y, len) + x * Step + Offset; - - do - { - calc_type alpha = (calc_type(c.a) * (calc_type(*covers) + 1)) >> 8; - if(alpha == base_mask) - { - *p = c.v; - } - else - { - Blender::blend_pix(p, c.v, alpha, *covers); - } - p += Step; - ++covers; - } - while(--len); - } - } - - - //-------------------------------------------------------------------- - void blend_solid_vspan(int x, int y, - unsigned len, - const color_type& c, - const int8u* covers) - { - if (c.a) - { - do - { - calc_type alpha = (calc_type(c.a) * (calc_type(*covers) + 1)) >> 8; - - value_type* p = (value_type*) - m_rbuf->row_ptr(x, y++, 1) + x * Step + Offset; - - if(alpha == base_mask) - { - *p = c.v; - } - else - { - Blender::blend_pix(p, c.v, alpha, *covers); - } - ++covers; - } - while(--len); - } - } - - - //-------------------------------------------------------------------- - void copy_color_hspan(int x, int y, - unsigned len, - const color_type* colors) - { - value_type* p = (value_type*) - m_rbuf->row_ptr(x, y, len) + x * Step + Offset; - - do - { - *p = colors->v; - p += Step; - ++colors; - } - while(--len); - } - - - //-------------------------------------------------------------------- - void copy_color_vspan(int x, int y, - unsigned len, - const color_type* colors) - { - do - { - value_type* p = (value_type*) - m_rbuf->row_ptr(x, y++, 1) + x * Step + Offset; - *p = colors->v; - ++colors; - } - while(--len); - } - - - //-------------------------------------------------------------------- - void blend_color_hspan(int x, int y, - unsigned len, - const color_type* colors, - const int8u* covers, - int8u cover) - { - value_type* p = (value_type*) - m_rbuf->row_ptr(x, y, len) + x * Step + Offset; - - if(covers) - { - do - { - copy_or_blend_pix(p, *colors++, *covers++); - p += Step; - } - while(--len); - } - else - { - if(cover == 255) - { - do - { - if(colors->a == base_mask) - { - *p = colors->v; - } - else - { - copy_or_blend_pix(p, *colors); - } - p += Step; - ++colors; - } - while(--len); - } - else - { - do - { - copy_or_blend_pix(p, *colors++, cover); - p += Step; - } - while(--len); - } - } - } - - - - //-------------------------------------------------------------------- - void blend_color_vspan(int x, int y, - unsigned len, - const color_type* colors, - const int8u* covers, - int8u cover) - { - value_type* p; - if(covers) - { - do - { - p = (value_type*) - m_rbuf->row_ptr(x, y++, 1) + x * Step + Offset; - - copy_or_blend_pix(p, *colors++, *covers++); - } - while(--len); - } - else - { - if(cover == 255) - { - do - { - p = (value_type*) - m_rbuf->row_ptr(x, y++, 1) + x * Step + Offset; - - if(colors->a == base_mask) - { - *p = colors->v; - } - else - { - copy_or_blend_pix(p, *colors); - } - ++colors; - } - while(--len); - } - else - { - do - { - p = (value_type*) - m_rbuf->row_ptr(x, y++, 1) + x * Step + Offset; - - copy_or_blend_pix(p, *colors++, cover); - } - while(--len); - } - } - } - - //-------------------------------------------------------------------- - template void for_each_pixel(Function f) - { - unsigned y; - for(y = 0; y < height(); ++y) - { - row_data r = m_rbuf->row(y); - if(r.ptr) - { - unsigned len = r.x2 - r.x1 + 1; - - value_type* p = (value_type*) - m_rbuf->row_ptr(r.x1, y, len) + r.x1 * Step + Offset; - - do - { - f(p); - p += Step; - } - while(--len); - } - } - } - - //-------------------------------------------------------------------- - template void apply_gamma_dir(const GammaLut& g) - { - for_each_pixel(apply_gamma_dir_gray(g)); - } - - //-------------------------------------------------------------------- - template void apply_gamma_inv(const GammaLut& g) - { - for_each_pixel(apply_gamma_inv_gray(g)); - } - - //-------------------------------------------------------------------- - template - void copy_from(const RenBuf2& from, - int xdst, int ydst, - int xsrc, int ysrc, - unsigned len) - { - const int8u* p = from.row_ptr(ysrc); - if(p) - { - memmove(m_rbuf->row_ptr(xdst, ydst, len) + xdst * pix_width, - p + xsrc * pix_width, - len * pix_width); - } - } - - //-------------------------------------------------------------------- - template - void blend_from_color(const SrcPixelFormatRenderer& from, - const color_type& color, - int xdst, int ydst, - int xsrc, int ysrc, - unsigned len, - int8u cover) - { - typedef typename SrcPixelFormatRenderer::value_type src_value_type; - const src_value_type* psrc = (src_value_type*)from.row_ptr(ysrc); - if(psrc) - { - value_type* pdst = - (value_type*)m_rbuf->row_ptr(xdst, ydst, len) + xdst; - do - { - copy_or_blend_pix(pdst, - color, - (*psrc * cover + base_mask) >> base_shift); - ++psrc; - ++pdst; - } - while(--len); - } - } - - //-------------------------------------------------------------------- - template - void blend_from_lut(const SrcPixelFormatRenderer& from, - const color_type* color_lut, - int xdst, int ydst, - int xsrc, int ysrc, - unsigned len, - int8u cover) - { - typedef typename SrcPixelFormatRenderer::value_type src_value_type; - const src_value_type* psrc = (src_value_type*)from.row_ptr(ysrc); - if(psrc) - { - value_type* pdst = - (value_type*)m_rbuf->row_ptr(xdst, ydst, len) + xdst; - do - { - copy_or_blend_pix(pdst, color_lut[*psrc], cover); - ++psrc; - ++pdst; - } - while(--len); - } - } - - private: - rbuf_type* m_rbuf; - }; - - typedef blender_gray blender_gray8; - typedef blender_gray_pre blender_gray8_pre; - typedef blender_gray blender_gray16; - typedef blender_gray_pre blender_gray16_pre; - - typedef pixfmt_alpha_blend_gray pixfmt_gray8; //----pixfmt_gray8 - typedef pixfmt_alpha_blend_gray pixfmt_gray8_pre; //----pixfmt_gray8_pre - typedef pixfmt_alpha_blend_gray pixfmt_gray16; //----pixfmt_gray16 - typedef pixfmt_alpha_blend_gray pixfmt_gray16_pre; //----pixfmt_gray16_pre -} - -#endif - diff --git a/desmume/src/windows/agg/include/agg_pixfmt_rgb.h b/desmume/src/windows/agg/include/agg_pixfmt_rgb.h deleted file mode 100644 index 7f0ed184f..000000000 --- a/desmume/src/windows/agg/include/agg_pixfmt_rgb.h +++ /dev/null @@ -1,869 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- -// -// Adaptation for high precision colors has been sponsored by -// Liberty Technology Systems, Inc., visit http://lib-sys.com -// -// Liberty Technology Systems, Inc. is the provider of -// PostScript and PDF technology for software developers. -// -//---------------------------------------------------------------------------- - -#ifndef AGG_PIXFMT_RGB_INCLUDED -#define AGG_PIXFMT_RGB_INCLUDED - -#include -#include "agg_basics.h" -#include "agg_color_rgba.h" -#include "agg_rendering_buffer.h" - -namespace agg -{ - - //=====================================================apply_gamma_dir_rgb - template class apply_gamma_dir_rgb - { - public: - typedef typename ColorT::value_type value_type; - - apply_gamma_dir_rgb(const GammaLut& gamma) : m_gamma(gamma) {} - - AGG_INLINE void operator () (value_type* p) - { - p[Order::R] = m_gamma.dir(p[Order::R]); - p[Order::G] = m_gamma.dir(p[Order::G]); - p[Order::B] = m_gamma.dir(p[Order::B]); - } - - private: - const GammaLut& m_gamma; - }; - - - - //=====================================================apply_gamma_inv_rgb - template class apply_gamma_inv_rgb - { - public: - typedef typename ColorT::value_type value_type; - - apply_gamma_inv_rgb(const GammaLut& gamma) : m_gamma(gamma) {} - - AGG_INLINE void operator () (value_type* p) - { - p[Order::R] = m_gamma.inv(p[Order::R]); - p[Order::G] = m_gamma.inv(p[Order::G]); - p[Order::B] = m_gamma.inv(p[Order::B]); - } - - private: - const GammaLut& m_gamma; - }; - - - //=========================================================blender_rgb - template struct blender_rgb - { - typedef ColorT color_type; - typedef Order order_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - enum base_scale_e { base_shift = color_type::base_shift }; - - //-------------------------------------------------------------------- - static AGG_INLINE void blend_pix(value_type* p, - unsigned cr, unsigned cg, unsigned cb, - unsigned alpha, - unsigned cover=0) - { - p[Order::R] += (value_type)(((cr - p[Order::R]) * alpha) >> base_shift); - p[Order::G] += (value_type)(((cg - p[Order::G]) * alpha) >> base_shift); - p[Order::B] += (value_type)(((cb - p[Order::B]) * alpha) >> base_shift); - } - }; - - - //======================================================blender_rgb_pre - template struct blender_rgb_pre - { - typedef ColorT color_type; - typedef Order order_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - enum base_scale_e { base_shift = color_type::base_shift }; - - //-------------------------------------------------------------------- - static AGG_INLINE void blend_pix(value_type* p, - unsigned cr, unsigned cg, unsigned cb, - unsigned alpha, - unsigned cover) - { - alpha = color_type::base_mask - alpha; - cover = (cover + 1) << (base_shift - 8); - p[Order::R] = (value_type)((p[Order::R] * alpha + cr * cover) >> base_shift); - p[Order::G] = (value_type)((p[Order::G] * alpha + cg * cover) >> base_shift); - p[Order::B] = (value_type)((p[Order::B] * alpha + cb * cover) >> base_shift); - } - - //-------------------------------------------------------------------- - static AGG_INLINE void blend_pix(value_type* p, - unsigned cr, unsigned cg, unsigned cb, - unsigned alpha) - { - alpha = color_type::base_mask - alpha; - p[Order::R] = (value_type)(((p[Order::R] * alpha) >> base_shift) + cr); - p[Order::G] = (value_type)(((p[Order::G] * alpha) >> base_shift) + cg); - p[Order::B] = (value_type)(((p[Order::B] * alpha) >> base_shift) + cb); - } - - }; - - - - //===================================================blender_rgb_gamma - template class blender_rgb_gamma - { - public: - typedef ColorT color_type; - typedef Order order_type; - typedef Gamma gamma_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - enum base_scale_e { base_shift = color_type::base_shift }; - - //-------------------------------------------------------------------- - blender_rgb_gamma() : m_gamma(0) {} - void gamma(const gamma_type& g) { m_gamma = &g; } - - //-------------------------------------------------------------------- - AGG_INLINE void blend_pix(value_type* p, - unsigned cr, unsigned cg, unsigned cb, - unsigned alpha, - unsigned cover=0) - { - calc_type r = m_gamma->dir(p[Order::R]); - calc_type g = m_gamma->dir(p[Order::G]); - calc_type b = m_gamma->dir(p[Order::B]); - p[Order::R] = m_gamma->inv((((m_gamma->dir(cr) - r) * alpha) >> base_shift) + r); - p[Order::G] = m_gamma->inv((((m_gamma->dir(cg) - g) * alpha) >> base_shift) + g); - p[Order::B] = m_gamma->inv((((m_gamma->dir(cb) - b) * alpha) >> base_shift) + b); - } - - private: - const gamma_type* m_gamma; - }; - - - - - //==================================================pixfmt_alpha_blend_rgb - template class pixfmt_alpha_blend_rgb - { - public: - typedef RenBuf rbuf_type; - typedef Blender blender_type; - typedef typename rbuf_type::row_data row_data; - typedef typename blender_type::color_type color_type; - typedef typename blender_type::order_type order_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_scale = color_type::base_scale, - base_mask = color_type::base_mask, - pix_width = sizeof(value_type) * 3 - }; - - private: - //-------------------------------------------------------------------- - AGG_INLINE void copy_or_blend_pix(value_type* p, - const color_type& c, - unsigned cover) - { - if (c.a) - { - calc_type alpha = (calc_type(c.a) * (cover + 1)) >> 8; - if(alpha == base_mask) - { - p[order_type::R] = c.r; - p[order_type::G] = c.g; - p[order_type::B] = c.b; - } - else - { - m_blender.blend_pix(p, c.r, c.g, c.b, alpha, cover); - } - } - } - - //-------------------------------------------------------------------- - AGG_INLINE void copy_or_blend_pix(value_type* p, - const color_type& c) - { - if (c.a) - { - if(c.a == base_mask) - { - p[order_type::R] = c.r; - p[order_type::G] = c.g; - p[order_type::B] = c.b; - } - else - { - m_blender.blend_pix(p, c.r, c.g, c.b, c.a); - } - } - } - - - public: - //-------------------------------------------------------------------- - explicit pixfmt_alpha_blend_rgb(rbuf_type& rb) : - m_rbuf(&rb) - {} - void attach(rbuf_type& rb) { m_rbuf = &rb; } - - //-------------------------------------------------------------------- - template - bool attach(PixFmt& pixf, int x1, int y1, int x2, int y2) - { - rect_i r(x1, y1, x2, y2); - if(r.clip(rect_i(0, 0, pixf.width()-1, pixf.height()-1))) - { - int stride = pixf.stride(); - m_rbuf->attach(pixf.pix_ptr(r.x1, stride < 0 ? r.y2 : r.y1), - (r.x2 - r.x1) + 1, - (r.y2 - r.y1) + 1, - stride); - return true; - } - return false; - } - - //-------------------------------------------------------------------- - Blender& blender() { return m_blender; } - - //-------------------------------------------------------------------- - AGG_INLINE unsigned width() const { return m_rbuf->width(); } - AGG_INLINE unsigned height() const { return m_rbuf->height(); } - AGG_INLINE int stride() const { return m_rbuf->stride(); } - - //-------------------------------------------------------------------- - AGG_INLINE int8u* row_ptr(int y) { return m_rbuf->row_ptr(y); } - AGG_INLINE const int8u* row_ptr(int y) const { return m_rbuf->row_ptr(y); } - AGG_INLINE row_data row(int y) const { return m_rbuf->row(y); } - - //-------------------------------------------------------------------- - AGG_INLINE int8u* pix_ptr(int x, int y) - { - return m_rbuf->row_ptr(y) + x * pix_width; - } - - AGG_INLINE const int8u* pix_ptr(int x, int y) const - { - return m_rbuf->row_ptr(y) + x * pix_width; - } - - //-------------------------------------------------------------------- - AGG_INLINE static void make_pix(int8u* p, const color_type& c) - { - ((value_type*)p)[order_type::R] = c.r; - ((value_type*)p)[order_type::G] = c.g; - ((value_type*)p)[order_type::B] = c.b; - } - - //-------------------------------------------------------------------- - AGG_INLINE color_type pixel(int x, int y) const - { - value_type* p = (value_type*)m_rbuf->row_ptr(y) + x + x + x; - return color_type(p[order_type::R], - p[order_type::G], - p[order_type::B]); - } - - //-------------------------------------------------------------------- - AGG_INLINE void copy_pixel(int x, int y, const color_type& c) - { - value_type* p = (value_type*)m_rbuf->row_ptr(x, y, 1) + x + x + x; - p[order_type::R] = c.r; - p[order_type::G] = c.g; - p[order_type::B] = c.b; - } - - //-------------------------------------------------------------------- - AGG_INLINE void blend_pixel(int x, int y, const color_type& c, int8u cover) - { - copy_or_blend_pix((value_type*)m_rbuf->row_ptr(x, y, 1) + x + x + x, c, cover); - } - - - //-------------------------------------------------------------------- - AGG_INLINE void copy_hline(int x, int y, - unsigned len, - const color_type& c) - { - value_type* p = (value_type*)m_rbuf->row_ptr(x, y, len) + x + x + x; - do - { - p[order_type::R] = c.r; - p[order_type::G] = c.g; - p[order_type::B] = c.b; - p += 3; - } - while(--len); - } - - - //-------------------------------------------------------------------- - AGG_INLINE void copy_vline(int x, int y, - unsigned len, - const color_type& c) - { - do - { - value_type* p = (value_type*) - m_rbuf->row_ptr(x, y++, 1) + x + x + x; - p[order_type::R] = c.r; - p[order_type::G] = c.g; - p[order_type::B] = c.b; - } - while(--len); - } - - - //-------------------------------------------------------------------- - void blend_hline(int x, int y, - unsigned len, - const color_type& c, - int8u cover) - { - if (c.a) - { - value_type* p = (value_type*) - m_rbuf->row_ptr(x, y, len) + x + x + x; - - calc_type alpha = (calc_type(c.a) * (calc_type(cover) + 1)) >> 8; - if(alpha == base_mask) - { - do - { - p[order_type::R] = c.r; - p[order_type::G] = c.g; - p[order_type::B] = c.b; - p += 3; - } - while(--len); - } - else - { - do - { - m_blender.blend_pix(p, c.r, c.g, c.b, alpha, cover); - p += 3; - } - while(--len); - } - } - } - - - //-------------------------------------------------------------------- - void blend_vline(int x, int y, - unsigned len, - const color_type& c, - int8u cover) - { - if (c.a) - { - value_type* p; - calc_type alpha = (calc_type(c.a) * (cover + 1)) >> 8; - if(alpha == base_mask) - { - do - { - p = (value_type*) - m_rbuf->row_ptr(x, y++, 1) + x + x + x; - - p[order_type::R] = c.r; - p[order_type::G] = c.g; - p[order_type::B] = c.b; - } - while(--len); - } - else - { - do - { - p = (value_type*) - m_rbuf->row_ptr(x, y++, 1) + x + x + x; - - m_blender.blend_pix(p, c.r, c.g, c.b, alpha, cover); - } - while(--len); - } - } - } - - - //-------------------------------------------------------------------- - void blend_solid_hspan(int x, int y, - unsigned len, - const color_type& c, - const int8u* covers) - { - if (c.a) - { - value_type* p = (value_type*) - m_rbuf->row_ptr(x, y, len) + x + x + x; - - do - { - calc_type alpha = (calc_type(c.a) * (calc_type(*covers) + 1)) >> 8; - if(alpha == base_mask) - { - p[order_type::R] = c.r; - p[order_type::G] = c.g; - p[order_type::B] = c.b; - } - else - { - m_blender.blend_pix(p, c.r, c.g, c.b, alpha, *covers); - } - p += 3; - ++covers; - } - while(--len); - } - } - - - //-------------------------------------------------------------------- - void blend_solid_vspan(int x, int y, - unsigned len, - const color_type& c, - const int8u* covers) - { - if (c.a) - { - do - { - value_type* p = (value_type*) - m_rbuf->row_ptr(x, y++, 1) + x + x + x; - - calc_type alpha = (calc_type(c.a) * (calc_type(*covers) + 1)) >> 8; - if(alpha == base_mask) - { - p[order_type::R] = c.r; - p[order_type::G] = c.g; - p[order_type::B] = c.b; - } - else - { - m_blender.blend_pix(p, c.r, c.g, c.b, alpha, *covers); - } - ++covers; - } - while(--len); - } - } - - - //-------------------------------------------------------------------- - void copy_color_hspan(int x, int y, - unsigned len, - const color_type* colors) - { - value_type* p = (value_type*) - m_rbuf->row_ptr(x, y, len) + x + x + x; - - do - { - p[order_type::R] = colors->r; - p[order_type::G] = colors->g; - p[order_type::B] = colors->b; - ++colors; - p += 3; - } - while(--len); - } - - - //-------------------------------------------------------------------- - void copy_color_vspan(int x, int y, - unsigned len, - const color_type* colors) - { - do - { - value_type* p = (value_type*) - m_rbuf->row_ptr(x, y++, 1) + x + x + x; - p[order_type::R] = colors->r; - p[order_type::G] = colors->g; - p[order_type::B] = colors->b; - ++colors; - } - while(--len); - } - - - //-------------------------------------------------------------------- - void blend_color_hspan(int x, int y, - unsigned len, - const color_type* colors, - const int8u* covers, - int8u cover) - { - value_type* p = (value_type*) - m_rbuf->row_ptr(x, y, len) + x + x + x; - - if(covers) - { - do - { - copy_or_blend_pix(p, *colors++, *covers++); - p += 3; - } - while(--len); - } - else - { - if(cover == 255) - { - do - { - copy_or_blend_pix(p, *colors++); - p += 3; - } - while(--len); - } - else - { - do - { - copy_or_blend_pix(p, *colors++, cover); - p += 3; - } - while(--len); - } - } - } - - - - //-------------------------------------------------------------------- - void blend_color_vspan(int x, int y, - unsigned len, - const color_type* colors, - const int8u* covers, - int8u cover) - { - value_type* p; - if(covers) - { - do - { - p = (value_type*) - m_rbuf->row_ptr(x, y++, 1) + x + x + x; - - copy_or_blend_pix(p, *colors++, *covers++); - } - while(--len); - } - else - { - if(cover == 255) - { - do - { - p = (value_type*) - m_rbuf->row_ptr(x, y++, 1) + x + x + x; - - copy_or_blend_pix(p, *colors++); - } - while(--len); - } - else - { - do - { - p = (value_type*) - m_rbuf->row_ptr(x, y++, 1) + x + x + x; - - copy_or_blend_pix(p, *colors++, cover); - } - while(--len); - } - } - } - - //-------------------------------------------------------------------- - template void for_each_pixel(Function f) - { - unsigned y; - for(y = 0; y < height(); ++y) - { - row_data r = m_rbuf->row(y); - if(r.ptr) - { - unsigned len = r.x2 - r.x1 + 1; - value_type* p = (value_type*) - m_rbuf->row_ptr(r.x1, y, len) + r.x1 * 3; - do - { - f(p); - p += 3; - } - while(--len); - } - } - } - - //-------------------------------------------------------------------- - template void apply_gamma_dir(const GammaLut& g) - { - for_each_pixel(apply_gamma_dir_rgb(g)); - } - - //-------------------------------------------------------------------- - template void apply_gamma_inv(const GammaLut& g) - { - for_each_pixel(apply_gamma_inv_rgb(g)); - } - - //-------------------------------------------------------------------- - template - void copy_from(const RenBuf2& from, - int xdst, int ydst, - int xsrc, int ysrc, - unsigned len) - { - const int8u* p = from.row_ptr(ysrc); - if(p) - { - memmove(m_rbuf->row_ptr(xdst, ydst, len) + xdst * pix_width, - p + xsrc * pix_width, - len * pix_width); - } - } - - - //-------------------------------------------------------------------- - template - void blend_from(const SrcPixelFormatRenderer& from, - int xdst, int ydst, - int xsrc, int ysrc, - unsigned len, - int8u cover) - { - typedef typename SrcPixelFormatRenderer::order_type src_order; - - const value_type* psrc = (const value_type*)from.row_ptr(ysrc); - if(psrc) - { - psrc += xsrc * 4; - value_type* pdst = - (value_type*)m_rbuf->row_ptr(xdst, ydst, len) + xdst * 3; - - if(cover == 255) - { - do - { - value_type alpha = psrc[src_order::A]; - if(alpha) - { - if(alpha == base_mask) - { - pdst[order_type::R] = psrc[src_order::R]; - pdst[order_type::G] = psrc[src_order::G]; - pdst[order_type::B] = psrc[src_order::B]; - } - else - { - m_blender.blend_pix(pdst, - psrc[src_order::R], - psrc[src_order::G], - psrc[src_order::B], - alpha); - } - } - psrc += 4; - pdst += 3; - } - while(--len); - } - else - { - color_type color; - do - { - color.r = psrc[src_order::R]; - color.g = psrc[src_order::G]; - color.b = psrc[src_order::B]; - color.a = psrc[src_order::A]; - copy_or_blend_pix(pdst, color, cover); - psrc += 4; - pdst += 3; - } - while(--len); - } - } - } - - //-------------------------------------------------------------------- - template - void blend_from_color(const SrcPixelFormatRenderer& from, - const color_type& color, - int xdst, int ydst, - int xsrc, int ysrc, - unsigned len, - int8u cover) - { - typedef typename SrcPixelFormatRenderer::value_type src_value_type; - const src_value_type* psrc = (src_value_type*)from.row_ptr(ysrc); - if(psrc) - { - value_type* pdst = - (value_type*)m_rbuf->row_ptr(xdst, ydst, len) + xdst * 3; - do - { - copy_or_blend_pix(pdst, - color, - (*psrc * cover + base_mask) >> base_shift); - ++psrc; - pdst += 3; - } - while(--len); - } - } - - //-------------------------------------------------------------------- - template - void blend_from_lut(const SrcPixelFormatRenderer& from, - const color_type* color_lut, - int xdst, int ydst, - int xsrc, int ysrc, - unsigned len, - int8u cover) - { - typedef typename SrcPixelFormatRenderer::value_type src_value_type; - const src_value_type* psrc = (src_value_type*)from.row_ptr(ysrc); - if(psrc) - { - value_type* pdst = - (value_type*)m_rbuf->row_ptr(xdst, ydst, len) + xdst * 3; - - if(cover == 255) - { - do - { - const color_type& color = color_lut[*psrc]; - m_blender.blend_pix(pdst, - color.r, color.g, color.b, color.a); - ++psrc; - pdst += 3; - } - while(--len); - } - else - { - do - { - copy_or_blend_pix(pdst, color_lut[*psrc], cover); - ++psrc; - pdst += 3; - } - while(--len); - } - } - } - - private: - rbuf_type* m_rbuf; - Blender m_blender; - }; - - typedef pixfmt_alpha_blend_rgb, rendering_buffer> pixfmt_rgb24; //----pixfmt_rgb24 - typedef pixfmt_alpha_blend_rgb, rendering_buffer> pixfmt_bgr24; //----pixfmt_bgr24 - typedef pixfmt_alpha_blend_rgb, rendering_buffer> pixfmt_rgb48; //----pixfmt_rgb48 - typedef pixfmt_alpha_blend_rgb, rendering_buffer> pixfmt_bgr48; //----pixfmt_bgr48 - - typedef pixfmt_alpha_blend_rgb, rendering_buffer> pixfmt_rgb24_pre; //----pixfmt_rgb24_pre - typedef pixfmt_alpha_blend_rgb, rendering_buffer> pixfmt_bgr24_pre; //----pixfmt_bgr24_pre - typedef pixfmt_alpha_blend_rgb, rendering_buffer> pixfmt_rgb48_pre; //----pixfmt_rgb48_pre - typedef pixfmt_alpha_blend_rgb, rendering_buffer> pixfmt_bgr48_pre; //----pixfmt_bgr48_pre - - //-----------------------------------------------------pixfmt_rgb24_gamma - template class pixfmt_rgb24_gamma : - public pixfmt_alpha_blend_rgb, rendering_buffer> - { - public: - pixfmt_rgb24_gamma(rendering_buffer& rb, const Gamma& g) : - pixfmt_alpha_blend_rgb, rendering_buffer>(rb) - { - this->blender().gamma(g); - } - }; - - //-----------------------------------------------------pixfmt_bgr24_gamma - template class pixfmt_bgr24_gamma : - public pixfmt_alpha_blend_rgb, rendering_buffer> - { - public: - pixfmt_bgr24_gamma(rendering_buffer& rb, const Gamma& g) : - pixfmt_alpha_blend_rgb, rendering_buffer>(rb) - { - this->blender().gamma(g); - } - }; - - //-----------------------------------------------------pixfmt_rgb48_gamma - template class pixfmt_rgb48_gamma : - public pixfmt_alpha_blend_rgb, rendering_buffer> - { - public: - pixfmt_rgb48_gamma(rendering_buffer& rb, const Gamma& g) : - pixfmt_alpha_blend_rgb, rendering_buffer>(rb) - { - this->blender().gamma(g); - } - }; - - //-----------------------------------------------------pixfmt_bgr48_gamma - template class pixfmt_bgr48_gamma : - public pixfmt_alpha_blend_rgb, rendering_buffer> - { - public: - pixfmt_bgr48_gamma(rendering_buffer& rb, const Gamma& g) : - pixfmt_alpha_blend_rgb, rendering_buffer>(rb) - { - this->blender().gamma(g); - } - }; - - -} - -#endif - diff --git a/desmume/src/windows/agg/include/agg_pixfmt_rgb_packed.h b/desmume/src/windows/agg/include/agg_pixfmt_rgb_packed.h deleted file mode 100644 index 28bb79d4f..000000000 --- a/desmume/src/windows/agg/include/agg_pixfmt_rgb_packed.h +++ /dev/null @@ -1,1318 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- -// -// Adaptation for high precision colors has been sponsored by -// Liberty Technology Systems, Inc., visit http://lib-sys.com -// -// Liberty Technology Systems, Inc. is the provider of -// PostScript and PDF technology for software developers. -// -//---------------------------------------------------------------------------- - -#ifndef AGG_PIXFMT_RGB_PACKED_INCLUDED -#define AGG_PIXFMT_RGB_PACKED_INCLUDED - -#include -#include "agg_basics.h" -#include "agg_color_rgba.h" -#include "agg_rendering_buffer.h" - -namespace agg -{ - //=========================================================blender_rgb555 - struct blender_rgb555 - { - typedef rgba8 color_type; - typedef color_type::value_type value_type; - typedef color_type::calc_type calc_type; - typedef int16u pixel_type; - - static AGG_INLINE void blend_pix(pixel_type* p, - unsigned cr, unsigned cg, unsigned cb, - unsigned alpha, - unsigned) - { - pixel_type rgb = *p; - calc_type r = (rgb >> 7) & 0xF8; - calc_type g = (rgb >> 2) & 0xF8; - calc_type b = (rgb << 3) & 0xF8; - *p = (pixel_type) - (((((cr - r) * alpha + (r << 8)) >> 1) & 0x7C00) | - ((((cg - g) * alpha + (g << 8)) >> 6) & 0x03E0) | - (((cb - b) * alpha + (b << 8)) >> 11) | 0x8000); - } - - static AGG_INLINE pixel_type make_pix(unsigned r, unsigned g, unsigned b) - { - return (pixel_type)(((r & 0xF8) << 7) | - ((g & 0xF8) << 2) | - (b >> 3) | 0x8000); - } - - static AGG_INLINE color_type make_color(pixel_type p) - { - return color_type((p >> 7) & 0xF8, - (p >> 2) & 0xF8, - (p << 3) & 0xF8); - } - }; - - - //=====================================================blender_rgb555_pre - struct blender_rgb555_pre - { - typedef rgba8 color_type; - typedef color_type::value_type value_type; - typedef color_type::calc_type calc_type; - typedef int16u pixel_type; - - static AGG_INLINE void blend_pix(pixel_type* p, - unsigned cr, unsigned cg, unsigned cb, - unsigned alpha, - unsigned cover) - { - alpha = color_type::base_mask - alpha; - pixel_type rgb = *p; - calc_type r = (rgb >> 7) & 0xF8; - calc_type g = (rgb >> 2) & 0xF8; - calc_type b = (rgb << 3) & 0xF8; - *p = (pixel_type) - ((((r * alpha + cr * cover) >> 1) & 0x7C00) | - (((g * alpha + cg * cover) >> 6) & 0x03E0) | - ((b * alpha + cb * cover) >> 11) | 0x8000); - } - - static AGG_INLINE pixel_type make_pix(unsigned r, unsigned g, unsigned b) - { - return (pixel_type)(((r & 0xF8) << 7) | - ((g & 0xF8) << 2) | - (b >> 3) | 0x8000); - } - - static AGG_INLINE color_type make_color(pixel_type p) - { - return color_type((p >> 7) & 0xF8, - (p >> 2) & 0xF8, - (p << 3) & 0xF8); - } - }; - - - - - //=====================================================blender_rgb555_gamma - template class blender_rgb555_gamma - { - public: - typedef rgba8 color_type; - typedef color_type::value_type value_type; - typedef color_type::calc_type calc_type; - typedef int16u pixel_type; - typedef Gamma gamma_type; - - blender_rgb555_gamma() : m_gamma(0) {} - void gamma(const gamma_type& g) { m_gamma = &g; } - - AGG_INLINE void blend_pix(pixel_type* p, - unsigned cr, unsigned cg, unsigned cb, - unsigned alpha, - unsigned) - { - pixel_type rgb = *p; - calc_type r = m_gamma->dir((rgb >> 7) & 0xF8); - calc_type g = m_gamma->dir((rgb >> 2) & 0xF8); - calc_type b = m_gamma->dir((rgb << 3) & 0xF8); - *p = (pixel_type) - (((m_gamma->inv(((m_gamma->dir(cr) - r) * alpha + (r << 8)) >> 8) << 7) & 0x7C00) | - ((m_gamma->inv(((m_gamma->dir(cg) - g) * alpha + (g << 8)) >> 8) << 2) & 0x03E0) | - (m_gamma->inv(((m_gamma->dir(cb) - b) * alpha + (b << 8)) >> 8) >> 3) | 0x8000); - } - - static AGG_INLINE pixel_type make_pix(unsigned r, unsigned g, unsigned b) - { - return (pixel_type)(((r & 0xF8) << 7) | - ((g & 0xF8) << 2) | - (b >> 3) | 0x8000); - } - - static AGG_INLINE color_type make_color(pixel_type p) - { - return color_type((p >> 7) & 0xF8, - (p >> 2) & 0xF8, - (p << 3) & 0xF8); - } - - private: - const Gamma* m_gamma; - }; - - - - - - //=========================================================blender_rgb565 - struct blender_rgb565 - { - typedef rgba8 color_type; - typedef color_type::value_type value_type; - typedef color_type::calc_type calc_type; - typedef int16u pixel_type; - - static AGG_INLINE void blend_pix(pixel_type* p, - unsigned cr, unsigned cg, unsigned cb, - unsigned alpha, - unsigned) - { - pixel_type rgb = *p; - calc_type r = (rgb >> 8) & 0xF8; - calc_type g = (rgb >> 3) & 0xFC; - calc_type b = (rgb << 3) & 0xF8; - *p = (pixel_type) - (((((cr - r) * alpha + (r << 8)) ) & 0xF800) | - ((((cg - g) * alpha + (g << 8)) >> 5) & 0x07E0) | - (((cb - b) * alpha + (b << 8)) >> 11)); - } - - static AGG_INLINE pixel_type make_pix(unsigned r, unsigned g, unsigned b) - { - return (pixel_type)(((r & 0xF8) << 8) | ((g & 0xFC) << 3) | (b >> 3)); - } - - static AGG_INLINE color_type make_color(pixel_type p) - { - return color_type((p >> 8) & 0xF8, - (p >> 3) & 0xFC, - (p << 3) & 0xF8); - } - }; - - - - //=====================================================blender_rgb565_pre - struct blender_rgb565_pre - { - typedef rgba8 color_type; - typedef color_type::value_type value_type; - typedef color_type::calc_type calc_type; - typedef int16u pixel_type; - - static AGG_INLINE void blend_pix(pixel_type* p, - unsigned cr, unsigned cg, unsigned cb, - unsigned alpha, - unsigned cover) - { - alpha = color_type::base_mask - alpha; - pixel_type rgb = *p; - calc_type r = (rgb >> 8) & 0xF8; - calc_type g = (rgb >> 3) & 0xFC; - calc_type b = (rgb << 3) & 0xF8; - *p = (pixel_type) - ((((r * alpha + cr * cover) ) & 0xF800) | - (((g * alpha + cg * cover) >> 5 ) & 0x07E0) | - ((b * alpha + cb * cover) >> 11)); - } - - static AGG_INLINE pixel_type make_pix(unsigned r, unsigned g, unsigned b) - { - return (pixel_type)(((r & 0xF8) << 8) | ((g & 0xFC) << 3) | (b >> 3)); - } - - static AGG_INLINE color_type make_color(pixel_type p) - { - return color_type((p >> 8) & 0xF8, - (p >> 3) & 0xFC, - (p << 3) & 0xF8); - } - }; - - - - //=====================================================blender_rgb565_gamma - template class blender_rgb565_gamma - { - public: - typedef rgba8 color_type; - typedef color_type::value_type value_type; - typedef color_type::calc_type calc_type; - typedef int16u pixel_type; - typedef Gamma gamma_type; - - blender_rgb565_gamma() : m_gamma(0) {} - void gamma(const gamma_type& g) { m_gamma = &g; } - - AGG_INLINE void blend_pix(pixel_type* p, - unsigned cr, unsigned cg, unsigned cb, - unsigned alpha, - unsigned) - { - pixel_type rgb = *p; - calc_type r = m_gamma->dir((rgb >> 8) & 0xF8); - calc_type g = m_gamma->dir((rgb >> 3) & 0xFC); - calc_type b = m_gamma->dir((rgb << 3) & 0xF8); - *p = (pixel_type) - (((m_gamma->inv(((m_gamma->dir(cr) - r) * alpha + (r << 8)) >> 8) << 8) & 0xF800) | - ((m_gamma->inv(((m_gamma->dir(cg) - g) * alpha + (g << 8)) >> 8) << 3) & 0x07E0) | - (m_gamma->inv(((m_gamma->dir(cb) - b) * alpha + (b << 8)) >> 8) >> 3)); - } - - static AGG_INLINE pixel_type make_pix(unsigned r, unsigned g, unsigned b) - { - return (pixel_type)(((r & 0xF8) << 8) | ((g & 0xFC) << 3) | (b >> 3)); - } - - static AGG_INLINE color_type make_color(pixel_type p) - { - return color_type((p >> 8) & 0xF8, - (p >> 3) & 0xFC, - (p << 3) & 0xF8); - } - - private: - const Gamma* m_gamma; - }; - - - - //=====================================================blender_rgbAAA - struct blender_rgbAAA - { - typedef rgba16 color_type; - typedef color_type::value_type value_type; - typedef color_type::calc_type calc_type; - typedef int32u pixel_type; - - static AGG_INLINE void blend_pix(pixel_type* p, - unsigned cr, unsigned cg, unsigned cb, - unsigned alpha, - unsigned) - { - pixel_type rgb = *p; - calc_type r = (rgb >> 14) & 0xFFC0; - calc_type g = (rgb >> 4) & 0xFFC0; - calc_type b = (rgb << 6) & 0xFFC0; - *p = (pixel_type) - (((((cr - r) * alpha + (r << 16)) >> 2) & 0x3FF00000) | - ((((cg - g) * alpha + (g << 16)) >> 12) & 0x000FFC00) | - (((cb - b) * alpha + (b << 16)) >> 22) | 0xC0000000); - } - - static AGG_INLINE pixel_type make_pix(unsigned r, unsigned g, unsigned b) - { - return (pixel_type)(((r & 0xFFC0) << 14) | - ((g & 0xFFC0) << 4) | - (b >> 6) | 0xC0000000); - } - - static AGG_INLINE color_type make_color(pixel_type p) - { - return color_type((p >> 14) & 0xFFC0, - (p >> 4) & 0xFFC0, - (p << 6) & 0xFFC0); - } - }; - - - - //==================================================blender_rgbAAA_pre - struct blender_rgbAAA_pre - { - typedef rgba16 color_type; - typedef color_type::value_type value_type; - typedef color_type::calc_type calc_type; - typedef int32u pixel_type; - - static AGG_INLINE void blend_pix(pixel_type* p, - unsigned cr, unsigned cg, unsigned cb, - unsigned alpha, - unsigned cover) - { - alpha = color_type::base_mask - alpha; - cover = (cover + 1) << (color_type::base_shift - 8); - pixel_type rgb = *p; - calc_type r = (rgb >> 14) & 0xFFC0; - calc_type g = (rgb >> 4) & 0xFFC0; - calc_type b = (rgb << 6) & 0xFFC0; - *p = (pixel_type) - ((((r * alpha + cr * cover) >> 2) & 0x3FF00000) | - (((g * alpha + cg * cover) >> 12) & 0x000FFC00) | - ((b * alpha + cb * cover) >> 22) | 0xC0000000); - } - - static AGG_INLINE pixel_type make_pix(unsigned r, unsigned g, unsigned b) - { - return (pixel_type)(((r & 0xFFC0) << 14) | - ((g & 0xFFC0) << 4) | - (b >> 6) | 0xC0000000); - } - - static AGG_INLINE color_type make_color(pixel_type p) - { - return color_type((p >> 14) & 0xFFC0, - (p >> 4) & 0xFFC0, - (p << 6) & 0xFFC0); - } - }; - - - - //=================================================blender_rgbAAA_gamma - template class blender_rgbAAA_gamma - { - public: - typedef rgba16 color_type; - typedef color_type::value_type value_type; - typedef color_type::calc_type calc_type; - typedef int32u pixel_type; - typedef Gamma gamma_type; - - blender_rgbAAA_gamma() : m_gamma(0) {} - void gamma(const gamma_type& g) { m_gamma = &g; } - - AGG_INLINE void blend_pix(pixel_type* p, - unsigned cr, unsigned cg, unsigned cb, - unsigned alpha, - unsigned) - { - pixel_type rgb = *p; - calc_type r = m_gamma->dir((rgb >> 14) & 0xFFC0); - calc_type g = m_gamma->dir((rgb >> 4) & 0xFFC0); - calc_type b = m_gamma->dir((rgb << 6) & 0xFFC0); - *p = (pixel_type) - (((m_gamma->inv(((m_gamma->dir(cr) - r) * alpha + (r << 16)) >> 16) << 14) & 0x3FF00000) | - ((m_gamma->inv(((m_gamma->dir(cg) - g) * alpha + (g << 16)) >> 16) << 4 ) & 0x000FFC00) | - (m_gamma->inv(((m_gamma->dir(cb) - b) * alpha + (b << 16)) >> 16) >> 6 ) | 0xC0000000); - } - - static AGG_INLINE pixel_type make_pix(unsigned r, unsigned g, unsigned b) - { - return (pixel_type)(((r & 0xFFC0) << 14) | - ((g & 0xFFC0) << 4) | - (b >> 6) | 0xC0000000); - } - - static AGG_INLINE color_type make_color(pixel_type p) - { - return color_type((p >> 14) & 0xFFC0, - (p >> 4) & 0xFFC0, - (p << 6) & 0xFFC0); - } - private: - const Gamma* m_gamma; - }; - - - //=====================================================blender_bgrAAA - struct blender_bgrAAA - { - typedef rgba16 color_type; - typedef color_type::value_type value_type; - typedef color_type::calc_type calc_type; - typedef int32u pixel_type; - - static AGG_INLINE void blend_pix(pixel_type* p, - unsigned cr, unsigned cg, unsigned cb, - unsigned alpha, - unsigned) - { - pixel_type bgr = *p; - calc_type b = (bgr >> 14) & 0xFFC0; - calc_type g = (bgr >> 4) & 0xFFC0; - calc_type r = (bgr << 6) & 0xFFC0; - *p = (pixel_type) - (((((cb - b) * alpha + (b << 16)) >> 2) & 0x3FF00000) | - ((((cg - g) * alpha + (g << 16)) >> 12) & 0x000FFC00) | - (((cr - r) * alpha + (r << 16)) >> 22) | 0xC0000000); - } - - static AGG_INLINE pixel_type make_pix(unsigned r, unsigned g, unsigned b) - { - return (pixel_type)(((b & 0xFFC0) << 14) | - ((g & 0xFFC0) << 4) | - (r >> 6) | 0xC0000000); - } - - static AGG_INLINE color_type make_color(pixel_type p) - { - return color_type((p << 6) & 0xFFC0, - (p >> 4) & 0xFFC0, - (p >> 14) & 0xFFC0); - } - }; - - - - //=================================================blender_bgrAAA_pre - struct blender_bgrAAA_pre - { - typedef rgba16 color_type; - typedef color_type::value_type value_type; - typedef color_type::calc_type calc_type; - typedef int32u pixel_type; - - static AGG_INLINE void blend_pix(pixel_type* p, - unsigned cr, unsigned cg, unsigned cb, - unsigned alpha, - unsigned cover) - { - alpha = color_type::base_mask - alpha; - cover = (cover + 1) << (color_type::base_shift - 8); - pixel_type bgr = *p; - calc_type b = (bgr >> 14) & 0xFFC0; - calc_type g = (bgr >> 4) & 0xFFC0; - calc_type r = (bgr << 6) & 0xFFC0; - *p = (pixel_type) - ((((b * alpha + cb * cover) >> 2) & 0x3FF00000) | - (((g * alpha + cg * cover) >> 12) & 0x000FFC00) | - ((r * alpha + cr * cover) >> 22) | 0xC0000000); - } - - static AGG_INLINE pixel_type make_pix(unsigned r, unsigned g, unsigned b) - { - return (pixel_type)(((b & 0xFFC0) << 14) | - ((g & 0xFFC0) << 4) | - (r >> 6) | 0xC0000000); - } - - static AGG_INLINE color_type make_color(pixel_type p) - { - return color_type((p << 6) & 0xFFC0, - (p >> 4) & 0xFFC0, - (p >> 14) & 0xFFC0); - } - }; - - - - //=================================================blender_bgrAAA_gamma - template class blender_bgrAAA_gamma - { - public: - typedef rgba16 color_type; - typedef color_type::value_type value_type; - typedef color_type::calc_type calc_type; - typedef int32u pixel_type; - typedef Gamma gamma_type; - - blender_bgrAAA_gamma() : m_gamma(0) {} - void gamma(const gamma_type& g) { m_gamma = &g; } - - AGG_INLINE void blend_pix(pixel_type* p, - unsigned cr, unsigned cg, unsigned cb, - unsigned alpha, - unsigned) - { - pixel_type bgr = *p; - calc_type b = m_gamma->dir((bgr >> 14) & 0xFFC0); - calc_type g = m_gamma->dir((bgr >> 4) & 0xFFC0); - calc_type r = m_gamma->dir((bgr << 6) & 0xFFC0); - *p = (pixel_type) - (((m_gamma->inv(((m_gamma->dir(cb) - b) * alpha + (b << 16)) >> 16) << 14) & 0x3FF00000) | - ((m_gamma->inv(((m_gamma->dir(cg) - g) * alpha + (g << 16)) >> 16) << 4 ) & 0x000FFC00) | - (m_gamma->inv(((m_gamma->dir(cr) - r) * alpha + (r << 16)) >> 16) >> 6 ) | 0xC0000000); - } - - static AGG_INLINE pixel_type make_pix(unsigned r, unsigned g, unsigned b) - { - return (pixel_type)(((b & 0xFFC0) << 14) | - ((g & 0xFFC0) << 4) | - (r >> 6) | 0xC0000000); - } - - static AGG_INLINE color_type make_color(pixel_type p) - { - return color_type((p << 6) & 0xFFC0, - (p >> 4) & 0xFFC0, - (p >> 14) & 0xFFC0); - } - - private: - const Gamma* m_gamma; - }; - - - - //=====================================================blender_rgbBBA - struct blender_rgbBBA - { - typedef rgba16 color_type; - typedef color_type::value_type value_type; - typedef color_type::calc_type calc_type; - typedef int32u pixel_type; - - static AGG_INLINE void blend_pix(pixel_type* p, - unsigned cr, unsigned cg, unsigned cb, - unsigned alpha, - unsigned) - { - pixel_type rgb = *p; - calc_type r = (rgb >> 16) & 0xFFE0; - calc_type g = (rgb >> 5) & 0xFFE0; - calc_type b = (rgb << 6) & 0xFFC0; - *p = (pixel_type) - (((((cr - r) * alpha + (r << 16)) ) & 0xFFE00000) | - ((((cg - g) * alpha + (g << 16)) >> 11) & 0x001FFC00) | - (((cb - b) * alpha + (b << 16)) >> 22)); - } - - static AGG_INLINE pixel_type make_pix(unsigned r, unsigned g, unsigned b) - { - return (pixel_type)(((r & 0xFFE0) << 16) | ((g & 0xFFE0) << 5) | (b >> 6)); - } - - static AGG_INLINE color_type make_color(pixel_type p) - { - return color_type((p >> 16) & 0xFFE0, - (p >> 5) & 0xFFE0, - (p << 6) & 0xFFC0); - } - }; - - - //=================================================blender_rgbBBA_pre - struct blender_rgbBBA_pre - { - typedef rgba16 color_type; - typedef color_type::value_type value_type; - typedef color_type::calc_type calc_type; - typedef int32u pixel_type; - - static AGG_INLINE void blend_pix(pixel_type* p, - unsigned cr, unsigned cg, unsigned cb, - unsigned alpha, - unsigned cover) - { - alpha = color_type::base_mask - alpha; - cover = (cover + 1) << (color_type::base_shift - 8); - pixel_type rgb = *p; - calc_type r = (rgb >> 16) & 0xFFE0; - calc_type g = (rgb >> 5) & 0xFFE0; - calc_type b = (rgb << 6) & 0xFFC0; - *p = (pixel_type) - ((((r * alpha + cr * cover) ) & 0xFFE00000) | - (((g * alpha + cg * cover) >> 11) & 0x001FFC00) | - ((b * alpha + cb * cover) >> 22)); - } - - static AGG_INLINE pixel_type make_pix(unsigned r, unsigned g, unsigned b) - { - return (pixel_type)(((r & 0xFFE0) << 16) | ((g & 0xFFE0) << 5) | (b >> 6)); - } - - static AGG_INLINE color_type make_color(pixel_type p) - { - return color_type((p >> 16) & 0xFFE0, - (p >> 5) & 0xFFE0, - (p << 6) & 0xFFC0); - } - }; - - - - //=================================================blender_rgbBBA_gamma - template class blender_rgbBBA_gamma - { - public: - typedef rgba16 color_type; - typedef color_type::value_type value_type; - typedef color_type::calc_type calc_type; - typedef int32u pixel_type; - typedef Gamma gamma_type; - - blender_rgbBBA_gamma() : m_gamma(0) {} - void gamma(const gamma_type& g) { m_gamma = &g; } - - AGG_INLINE void blend_pix(pixel_type* p, - unsigned cr, unsigned cg, unsigned cb, - unsigned alpha, - unsigned) - { - pixel_type rgb = *p; - calc_type r = m_gamma->dir((rgb >> 16) & 0xFFE0); - calc_type g = m_gamma->dir((rgb >> 5) & 0xFFE0); - calc_type b = m_gamma->dir((rgb << 6) & 0xFFC0); - *p = (pixel_type) - (((m_gamma->inv(((m_gamma->dir(cr) - r) * alpha + (r << 16)) >> 16) << 16) & 0xFFE00000) | - ((m_gamma->inv(((m_gamma->dir(cg) - g) * alpha + (g << 16)) >> 16) << 5 ) & 0x001FFC00) | - (m_gamma->inv(((m_gamma->dir(cb) - b) * alpha + (b << 16)) >> 16) >> 6 )); - } - - static AGG_INLINE pixel_type make_pix(unsigned r, unsigned g, unsigned b) - { - return (pixel_type)(((r & 0xFFE0) << 16) | ((g & 0xFFE0) << 5) | (b >> 6)); - } - - static AGG_INLINE color_type make_color(pixel_type p) - { - return color_type((p >> 16) & 0xFFE0, - (p >> 5) & 0xFFE0, - (p << 6) & 0xFFC0); - } - - private: - const Gamma* m_gamma; - }; - - - //=====================================================blender_bgrABB - struct blender_bgrABB - { - typedef rgba16 color_type; - typedef color_type::value_type value_type; - typedef color_type::calc_type calc_type; - typedef int32u pixel_type; - - static AGG_INLINE void blend_pix(pixel_type* p, - unsigned cr, unsigned cg, unsigned cb, - unsigned alpha, - unsigned) - { - pixel_type bgr = *p; - calc_type b = (bgr >> 16) & 0xFFC0; - calc_type g = (bgr >> 6) & 0xFFE0; - calc_type r = (bgr << 5) & 0xFFE0; - *p = (pixel_type) - (((((cb - b) * alpha + (b << 16)) ) & 0xFFC00000) | - ((((cg - g) * alpha + (g << 16)) >> 10) & 0x003FF800) | - (((cr - r) * alpha + (r << 16)) >> 21)); - } - - static AGG_INLINE pixel_type make_pix(unsigned r, unsigned g, unsigned b) - { - return (pixel_type)(((b & 0xFFC0) << 16) | ((g & 0xFFE0) << 6) | (r >> 5)); - } - - static AGG_INLINE color_type make_color(pixel_type p) - { - return color_type((p << 5) & 0xFFE0, - (p >> 6) & 0xFFE0, - (p >> 16) & 0xFFC0); - } - }; - - - //=================================================blender_bgrABB_pre - struct blender_bgrABB_pre - { - typedef rgba16 color_type; - typedef color_type::value_type value_type; - typedef color_type::calc_type calc_type; - typedef int32u pixel_type; - - static AGG_INLINE void blend_pix(pixel_type* p, - unsigned cr, unsigned cg, unsigned cb, - unsigned alpha, - unsigned cover) - { - alpha = color_type::base_mask - alpha; - cover = (cover + 1) << (color_type::base_shift - 8); - pixel_type bgr = *p; - calc_type b = (bgr >> 16) & 0xFFC0; - calc_type g = (bgr >> 6) & 0xFFE0; - calc_type r = (bgr << 5) & 0xFFE0; - *p = (pixel_type) - ((((b * alpha + cb * cover) ) & 0xFFC00000) | - (((g * alpha + cg * cover) >> 10) & 0x003FF800) | - ((r * alpha + cr * cover) >> 21)); - } - - static AGG_INLINE pixel_type make_pix(unsigned r, unsigned g, unsigned b) - { - return (pixel_type)(((b & 0xFFC0) << 16) | ((g & 0xFFE0) << 6) | (r >> 5)); - } - - static AGG_INLINE color_type make_color(pixel_type p) - { - return color_type((p << 5) & 0xFFE0, - (p >> 6) & 0xFFE0, - (p >> 16) & 0xFFC0); - } - }; - - - - //=================================================blender_bgrABB_gamma - template class blender_bgrABB_gamma - { - public: - typedef rgba16 color_type; - typedef color_type::value_type value_type; - typedef color_type::calc_type calc_type; - typedef int32u pixel_type; - typedef Gamma gamma_type; - - blender_bgrABB_gamma() : m_gamma(0) {} - void gamma(const gamma_type& g) { m_gamma = &g; } - - AGG_INLINE void blend_pix(pixel_type* p, - unsigned cr, unsigned cg, unsigned cb, - unsigned alpha, - unsigned) - { - pixel_type bgr = *p; - calc_type b = m_gamma->dir((bgr >> 16) & 0xFFC0); - calc_type g = m_gamma->dir((bgr >> 6) & 0xFFE0); - calc_type r = m_gamma->dir((bgr << 5) & 0xFFE0); - *p = (pixel_type) - (((m_gamma->inv(((m_gamma->dir(cb) - b) * alpha + (b << 16)) >> 16) << 16) & 0xFFC00000) | - ((m_gamma->inv(((m_gamma->dir(cg) - g) * alpha + (g << 16)) >> 16) << 6 ) & 0x003FF800) | - (m_gamma->inv(((m_gamma->dir(cr) - r) * alpha + (r << 16)) >> 16) >> 5 )); - } - - static AGG_INLINE pixel_type make_pix(unsigned r, unsigned g, unsigned b) - { - return (pixel_type)(((b & 0xFFC0) << 16) | ((g & 0xFFE0) << 6) | (r >> 5)); - } - - static AGG_INLINE color_type make_color(pixel_type p) - { - return color_type((p << 5) & 0xFFE0, - (p >> 6) & 0xFFE0, - (p >> 16) & 0xFFC0); - } - - private: - const Gamma* m_gamma; - }; - - - - //===========================================pixfmt_alpha_blend_rgb_packed - template class pixfmt_alpha_blend_rgb_packed - { - public: - typedef RenBuf rbuf_type; - typedef typename rbuf_type::row_data row_data; - typedef Blender blender_type; - typedef typename blender_type::color_type color_type; - typedef typename blender_type::pixel_type pixel_type; - typedef int order_type; // A fake one - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_scale = color_type::base_scale, - base_mask = color_type::base_mask, - pix_width = sizeof(pixel_type) - }; - - private: - //-------------------------------------------------------------------- - AGG_INLINE void copy_or_blend_pix(pixel_type* p, const color_type& c, unsigned cover) - { - if (c.a) - { - calc_type alpha = (calc_type(c.a) * (cover + 1)) >> 8; - if(alpha == base_mask) - { - *p = m_blender.make_pix(c.r, c.g, c.b); - } - else - { - m_blender.blend_pix(p, c.r, c.g, c.b, alpha, cover); - } - } - } - - public: - //-------------------------------------------------------------------- - explicit pixfmt_alpha_blend_rgb_packed(rbuf_type& rb) : m_rbuf(&rb) {} - void attach(rbuf_type& rb) { m_rbuf = &rb; } - - //-------------------------------------------------------------------- - template - bool attach(PixFmt& pixf, int x1, int y1, int x2, int y2) - { - rect_i r(x1, y1, x2, y2); - if(r.clip(rect_i(0, 0, pixf.width()-1, pixf.height()-1))) - { - int stride = pixf.stride(); - m_rbuf->attach(pixf.pix_ptr(r.x1, stride < 0 ? r.y2 : r.y1), - (r.x2 - r.x1) + 1, - (r.y2 - r.y1) + 1, - stride); - return true; - } - return false; - } - - Blender& blender() { return m_blender; } - - //-------------------------------------------------------------------- - AGG_INLINE unsigned width() const { return m_rbuf->width(); } - AGG_INLINE unsigned height() const { return m_rbuf->height(); } - AGG_INLINE int stride() const { return m_rbuf->stride(); } - - //-------------------------------------------------------------------- - AGG_INLINE int8u* row_ptr(int y) { return m_rbuf->row_ptr(y); } - AGG_INLINE const int8u* row_ptr(int y) const { return m_rbuf->row_ptr(y); } - AGG_INLINE row_data row(int y) const { return m_rbuf->row(y); } - - //-------------------------------------------------------------------- - AGG_INLINE int8u* pix_ptr(int x, int y) - { - return m_rbuf->row_ptr(y) + x * pix_width; - } - - AGG_INLINE const int8u* pix_ptr(int x, int y) const - { - return m_rbuf->row_ptr(y) + x * pix_width; - } - - //-------------------------------------------------------------------- - AGG_INLINE void make_pix(int8u* p, const color_type& c) - { - *(pixel_type*)p = m_blender.make_pix(c.r, c.g, c.b); - } - - //-------------------------------------------------------------------- - AGG_INLINE color_type pixel(int x, int y) const - { - return m_blender.make_color(((pixel_type*)m_rbuf->row_ptr(y))[x]); - } - - //-------------------------------------------------------------------- - AGG_INLINE void copy_pixel(int x, int y, const color_type& c) - { - ((pixel_type*) - m_rbuf->row_ptr(x, y, 1))[x] = - m_blender.make_pix(c.r, c.g, c.b); - } - - //-------------------------------------------------------------------- - AGG_INLINE void blend_pixel(int x, int y, const color_type& c, int8u cover) - { - copy_or_blend_pix((pixel_type*)m_rbuf->row_ptr(x, y, 1) + x, c, cover); - } - - //-------------------------------------------------------------------- - AGG_INLINE void copy_hline(int x, int y, - unsigned len, - const color_type& c) - { - pixel_type* p = (pixel_type*)m_rbuf->row_ptr(x, y, len) + x; - pixel_type v = m_blender.make_pix(c.r, c.g, c.b); - do - { - *p++ = v; - } - while(--len); - } - - //-------------------------------------------------------------------- - AGG_INLINE void copy_vline(int x, int y, - unsigned len, - const color_type& c) - { - pixel_type v = m_blender.make_pix(c.r, c.g, c.b); - do - { - pixel_type* p = (pixel_type*)m_rbuf->row_ptr(x, y++, 1) + x; - *p = v; - } - while(--len); - } - - //-------------------------------------------------------------------- - void blend_hline(int x, int y, - unsigned len, - const color_type& c, - int8u cover) - { - if (c.a) - { - pixel_type* p = (pixel_type*)m_rbuf->row_ptr(x, y, len) + x; - calc_type alpha = (calc_type(c.a) * (cover + 1)) >> 8; - if(alpha == base_mask) - { - pixel_type v = m_blender.make_pix(c.r, c.g, c.b); - do - { - *p++ = v; - } - while(--len); - } - else - { - do - { - m_blender.blend_pix(p, c.r, c.g, c.b, alpha, cover); - ++p; - } - while(--len); - } - } - } - - //-------------------------------------------------------------------- - void blend_vline(int x, int y, - unsigned len, - const color_type& c, - int8u cover) - { - if (c.a) - { - calc_type alpha = (calc_type(c.a) * (cover + 1)) >> 8; - if(alpha == base_mask) - { - pixel_type v = m_blender.make_pix(c.r, c.g, c.b); - do - { - ((pixel_type*)m_rbuf->row_ptr(x, y++, 1))[x] = v; - } - while(--len); - } - else - { - do - { - m_blender.blend_pix( - (pixel_type*)m_rbuf->row_ptr(x, y++, 1), - c.r, c.g, c.b, alpha, cover); - } - while(--len); - } - } - } - - //-------------------------------------------------------------------- - void blend_solid_hspan(int x, int y, - unsigned len, - const color_type& c, - const int8u* covers) - { - pixel_type* p = (pixel_type*)m_rbuf->row_ptr(x, y, len) + x; - do - { - copy_or_blend_pix(p, c, *covers++); - ++p; - } - while(--len); - } - - //-------------------------------------------------------------------- - void blend_solid_vspan(int x, int y, - unsigned len, - const color_type& c, - const int8u* covers) - { - do - { - copy_or_blend_pix((pixel_type*)m_rbuf->row_ptr(x, y++, 1) + x, - c, *covers++); - } - while(--len); - } - - //-------------------------------------------------------------------- - void copy_color_hspan(int x, int y, - unsigned len, - const color_type* colors) - { - pixel_type* p = (pixel_type*)m_rbuf->row_ptr(x, y, len) + x; - do - { - *p++ = m_blender.make_pix(colors->r, colors->g, colors->b); - ++colors; - } - while(--len); - } - - //-------------------------------------------------------------------- - void copy_color_vspan(int x, int y, - unsigned len, - const color_type* colors) - { - do - { - pixel_type* p = (pixel_type*)m_rbuf->row_ptr(x, y++, 1) + x; - *p = m_blender.make_pix(colors->r, colors->g, colors->b); - ++colors; - } - while(--len); - } - - //-------------------------------------------------------------------- - void blend_color_hspan(int x, int y, - unsigned len, - const color_type* colors, - const int8u* covers, - int8u cover) - { - pixel_type* p = (pixel_type*)m_rbuf->row_ptr(x, y, len) + x; - do - { - copy_or_blend_pix(p++, *colors++, covers ? *covers++ : cover); - } - while(--len); - } - - //-------------------------------------------------------------------- - void blend_color_vspan(int x, int y, - unsigned len, - const color_type* colors, - const int8u* covers, - int8u cover) - { - do - { - copy_or_blend_pix((pixel_type*)m_rbuf->row_ptr(x, y++, 1) + x, - *colors++, covers ? *covers++ : cover); - } - while(--len); - } - - //-------------------------------------------------------------------- - template - void copy_from(const RenBuf2& from, - int xdst, int ydst, - int xsrc, int ysrc, - unsigned len) - { - const int8u* p = from.row_ptr(ysrc); - if(p) - { - memmove(m_rbuf->row_ptr(xdst, ydst, len) + xdst * pix_width, - p + xsrc * pix_width, - len * pix_width); - } - } - - //-------------------------------------------------------------------- - template - void blend_from(const SrcPixelFormatRenderer& from, - int xdst, int ydst, - int xsrc, int ysrc, - unsigned len, - int8u cover) - { - typedef typename SrcPixelFormatRenderer::order_type src_order; - - const value_type* psrc = (const value_type*)from.row_ptr(ysrc); - if(psrc) - { - psrc += xsrc * 4; - pixel_type* pdst = - (pixel_type*)m_rbuf->row_ptr(xdst, ydst, len) + xdst; - do - { - value_type alpha = psrc[src_order::A]; - if(alpha) - { - if(alpha == base_mask && cover == 255) - { - *pdst = m_blender.make_pix(psrc[src_order::R], - psrc[src_order::G], - psrc[src_order::B]); - } - else - { - m_blender.blend_pix(pdst, - psrc[src_order::R], - psrc[src_order::G], - psrc[src_order::B], - alpha, - cover); - } - } - psrc += 4; - ++pdst; - } - while(--len); - } - } - - //-------------------------------------------------------------------- - template - void blend_from_color(const SrcPixelFormatRenderer& from, - const color_type& color, - int xdst, int ydst, - int xsrc, int ysrc, - unsigned len, - int8u cover) - { - typedef typename SrcPixelFormatRenderer::value_type src_value_type; - const src_value_type* psrc = (src_value_type*)from.row_ptr(ysrc); - if(psrc) - { - pixel_type* pdst = - (pixel_type*)m_rbuf->row_ptr(xdst, ydst, len) + xdst; - - do - { - m_blender.blend_pix(pdst, - color.r, color.g, color.b, color.a, - cover); - ++psrc; - ++pdst; - } - while(--len); - } - } - - //-------------------------------------------------------------------- - template - void blend_from_lut(const SrcPixelFormatRenderer& from, - const color_type* color_lut, - int xdst, int ydst, - int xsrc, int ysrc, - unsigned len, - int8u cover) - { - typedef typename SrcPixelFormatRenderer::value_type src_value_type; - const src_value_type* psrc = (src_value_type*)from.row_ptr(ysrc); - if(psrc) - { - pixel_type* pdst = - (pixel_type*)m_rbuf->row_ptr(xdst, ydst, len) + xdst; - - do - { - const color_type& color = color_lut[*psrc]; - m_blender.blend_pix(pdst, - color.r, color.g, color.b, color.a, - cover); - ++psrc; - ++pdst; - } - while(--len); - } - } - - - - private: - rbuf_type* m_rbuf; - Blender m_blender; - }; - - typedef pixfmt_alpha_blend_rgb_packed pixfmt_rgb555; //----pixfmt_rgb555 - typedef pixfmt_alpha_blend_rgb_packed pixfmt_rgb565; //----pixfmt_rgb565 - - typedef pixfmt_alpha_blend_rgb_packed pixfmt_rgb555_pre; //----pixfmt_rgb555_pre - typedef pixfmt_alpha_blend_rgb_packed pixfmt_rgb565_pre; //----pixfmt_rgb565_pre - - typedef pixfmt_alpha_blend_rgb_packed pixfmt_rgbAAA; //----pixfmt_rgbAAA - typedef pixfmt_alpha_blend_rgb_packed pixfmt_bgrAAA; //----pixfmt_bgrAAA - typedef pixfmt_alpha_blend_rgb_packed pixfmt_rgbBBA; //----pixfmt_rgbBBA - typedef pixfmt_alpha_blend_rgb_packed pixfmt_bgrABB; //----pixfmt_bgrABB - - typedef pixfmt_alpha_blend_rgb_packed pixfmt_rgbAAA_pre; //----pixfmt_rgbAAA_pre - typedef pixfmt_alpha_blend_rgb_packed pixfmt_bgrAAA_pre; //----pixfmt_bgrAAA_pre - typedef pixfmt_alpha_blend_rgb_packed pixfmt_rgbBBA_pre; //----pixfmt_rgbBBA_pre - typedef pixfmt_alpha_blend_rgb_packed pixfmt_bgrABB_pre; //----pixfmt_bgrABB_pre - - - //-----------------------------------------------------pixfmt_rgb555_gamma - template class pixfmt_rgb555_gamma : - public pixfmt_alpha_blend_rgb_packed, - rendering_buffer> - { - public: - pixfmt_rgb555_gamma(rendering_buffer& rb, const Gamma& g) : - pixfmt_alpha_blend_rgb_packed, - rendering_buffer>(rb) - { - this->blender().gamma(g); - } - }; - - - //-----------------------------------------------------pixfmt_rgb565_gamma - template class pixfmt_rgb565_gamma : - public pixfmt_alpha_blend_rgb_packed, rendering_buffer> - { - public: - pixfmt_rgb565_gamma(rendering_buffer& rb, const Gamma& g) : - pixfmt_alpha_blend_rgb_packed, rendering_buffer>(rb) - { - this->blender().gamma(g); - } - }; - - - //-----------------------------------------------------pixfmt_rgbAAA_gamma - template class pixfmt_rgbAAA_gamma : - public pixfmt_alpha_blend_rgb_packed, - rendering_buffer> - { - public: - pixfmt_rgbAAA_gamma(rendering_buffer& rb, const Gamma& g) : - pixfmt_alpha_blend_rgb_packed, - rendering_buffer>(rb) - { - this->blender().gamma(g); - } - }; - - - //-----------------------------------------------------pixfmt_bgrAAA_gamma - template class pixfmt_bgrAAA_gamma : - public pixfmt_alpha_blend_rgb_packed, - rendering_buffer> - { - public: - pixfmt_bgrAAA_gamma(rendering_buffer& rb, const Gamma& g) : - pixfmt_alpha_blend_rgb_packed, - rendering_buffer>(rb) - { - this->blender().gamma(g); - } - }; - - - //-----------------------------------------------------pixfmt_rgbBBA_gamma - template class pixfmt_rgbBBA_gamma : - public pixfmt_alpha_blend_rgb_packed, - rendering_buffer> - { - public: - pixfmt_rgbBBA_gamma(rendering_buffer& rb, const Gamma& g) : - pixfmt_alpha_blend_rgb_packed, - rendering_buffer>(rb) - { - this->blender().gamma(g); - } - }; - - - //-----------------------------------------------------pixfmt_bgrABB_gamma - template class pixfmt_bgrABB_gamma : - public pixfmt_alpha_blend_rgb_packed, - rendering_buffer> - { - public: - pixfmt_bgrABB_gamma(rendering_buffer& rb, const Gamma& g) : - pixfmt_alpha_blend_rgb_packed, - rendering_buffer>(rb) - { - this->blender().gamma(g); - } - }; - - -} - -#endif - diff --git a/desmume/src/windows/agg/include/agg_pixfmt_rgba.h b/desmume/src/windows/agg/include/agg_pixfmt_rgba.h deleted file mode 100644 index a6424c918..000000000 --- a/desmume/src/windows/agg/include/agg_pixfmt_rgba.h +++ /dev/null @@ -1,2911 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- -// -// Adaptation for high precision colors has been sponsored by -// Liberty Technology Systems, Inc., visit http://lib-sys.com -// -// Liberty Technology Systems, Inc. is the provider of -// PostScript and PDF technology for software developers. -// -//---------------------------------------------------------------------------- - -#ifndef AGG_PIXFMT_RGBA_INCLUDED -#define AGG_PIXFMT_RGBA_INCLUDED - -#include -#include -#include "agg_basics.h" -#include "agg_color_rgba.h" -#include "agg_rendering_buffer.h" - -namespace agg -{ - - //=========================================================multiplier_rgba - template struct multiplier_rgba - { - typedef typename ColorT::value_type value_type; - typedef typename ColorT::calc_type calc_type; - - //-------------------------------------------------------------------- - static AGG_INLINE void premultiply(value_type* p) - { - calc_type a = p[Order::A]; - if(a < ColorT::base_mask) - { - if(a == 0) - { - p[Order::R] = p[Order::G] = p[Order::B] = 0; - return; - } - p[Order::R] = value_type((p[Order::R] * a + ColorT::base_mask) >> ColorT::base_shift); - p[Order::G] = value_type((p[Order::G] * a + ColorT::base_mask) >> ColorT::base_shift); - p[Order::B] = value_type((p[Order::B] * a + ColorT::base_mask) >> ColorT::base_shift); - } - } - - - //-------------------------------------------------------------------- - static AGG_INLINE void demultiply(value_type* p) - { - calc_type a = p[Order::A]; - if(a < ColorT::base_mask) - { - if(a == 0) - { - p[Order::R] = p[Order::G] = p[Order::B] = 0; - return; - } - calc_type r = (calc_type(p[Order::R]) * ColorT::base_mask) / a; - calc_type g = (calc_type(p[Order::G]) * ColorT::base_mask) / a; - calc_type b = (calc_type(p[Order::B]) * ColorT::base_mask) / a; - p[Order::R] = value_type((r > ColorT::base_mask) ? ColorT::base_mask : r); - p[Order::G] = value_type((g > ColorT::base_mask) ? ColorT::base_mask : g); - p[Order::B] = value_type((b > ColorT::base_mask) ? ColorT::base_mask : b); - } - } - }; - - //=====================================================apply_gamma_dir_rgba - template class apply_gamma_dir_rgba - { - public: - typedef typename ColorT::value_type value_type; - - apply_gamma_dir_rgba(const GammaLut& gamma) : m_gamma(gamma) {} - - AGG_INLINE void operator () (value_type* p) - { - p[Order::R] = m_gamma.dir(p[Order::R]); - p[Order::G] = m_gamma.dir(p[Order::G]); - p[Order::B] = m_gamma.dir(p[Order::B]); - } - - private: - const GammaLut& m_gamma; - }; - - //=====================================================apply_gamma_inv_rgba - template class apply_gamma_inv_rgba - { - public: - typedef typename ColorT::value_type value_type; - - apply_gamma_inv_rgba(const GammaLut& gamma) : m_gamma(gamma) {} - - AGG_INLINE void operator () (value_type* p) - { - p[Order::R] = m_gamma.inv(p[Order::R]); - p[Order::G] = m_gamma.inv(p[Order::G]); - p[Order::B] = m_gamma.inv(p[Order::B]); - } - - private: - const GammaLut& m_gamma; - }; - - - - - - - - - - - //=============================================================blender_rgba - template struct blender_rgba - { - typedef ColorT color_type; - typedef Order order_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - //-------------------------------------------------------------------- - static AGG_INLINE void blend_pix(value_type* p, - unsigned cr, unsigned cg, unsigned cb, - unsigned alpha, - unsigned cover=0) - { - calc_type r = p[Order::R]; - calc_type g = p[Order::G]; - calc_type b = p[Order::B]; - calc_type a = p[Order::A]; - p[Order::R] = (value_type)(((cr - r) * alpha + (r << base_shift)) >> base_shift); - p[Order::G] = (value_type)(((cg - g) * alpha + (g << base_shift)) >> base_shift); - p[Order::B] = (value_type)(((cb - b) * alpha + (b << base_shift)) >> base_shift); - p[Order::A] = (value_type)((alpha + a) - ((alpha * a + base_mask) >> base_shift)); - } - }; - - //=========================================================blender_rgba_pre - template struct blender_rgba_pre - { - typedef ColorT color_type; - typedef Order order_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - //-------------------------------------------------------------------- - static AGG_INLINE void blend_pix(value_type* p, - unsigned cr, unsigned cg, unsigned cb, - unsigned alpha, - unsigned cover) - { - alpha = color_type::base_mask - alpha; - cover = (cover + 1) << (base_shift - 8); - p[Order::R] = (value_type)((p[Order::R] * alpha + cr * cover) >> base_shift); - p[Order::G] = (value_type)((p[Order::G] * alpha + cg * cover) >> base_shift); - p[Order::B] = (value_type)((p[Order::B] * alpha + cb * cover) >> base_shift); - p[Order::A] = (value_type)(base_mask - ((alpha * (base_mask - p[Order::A])) >> base_shift)); - } - - //-------------------------------------------------------------------- - static AGG_INLINE void blend_pix(value_type* p, - unsigned cr, unsigned cg, unsigned cb, - unsigned alpha) - { - alpha = color_type::base_mask - alpha; - p[Order::R] = (value_type)(((p[Order::R] * alpha) >> base_shift) + cr); - p[Order::G] = (value_type)(((p[Order::G] * alpha) >> base_shift) + cg); - p[Order::B] = (value_type)(((p[Order::B] * alpha) >> base_shift) + cb); - p[Order::A] = (value_type)(base_mask - ((alpha * (base_mask - p[Order::A])) >> base_shift)); - } - }; - - //======================================================blender_rgba_plain - template struct blender_rgba_plain - { - typedef ColorT color_type; - typedef Order order_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - enum base_scale_e { base_shift = color_type::base_shift }; - - //-------------------------------------------------------------------- - static AGG_INLINE void blend_pix(value_type* p, - unsigned cr, unsigned cg, unsigned cb, - unsigned alpha, - unsigned cover=0) - { - if(alpha == 0) return; - calc_type a = p[Order::A]; - calc_type r = p[Order::R] * a; - calc_type g = p[Order::G] * a; - calc_type b = p[Order::B] * a; - a = ((alpha + a) << base_shift) - alpha * a; - p[Order::A] = (value_type)(a >> base_shift); - p[Order::R] = (value_type)((((cr << base_shift) - r) * alpha + (r << base_shift)) / a); - p[Order::G] = (value_type)((((cg << base_shift) - g) * alpha + (g << base_shift)) / a); - p[Order::B] = (value_type)((((cb << base_shift) - b) * alpha + (b << base_shift)) / a); - } - }; - - - - - - - - - - - - //=========================================================comp_op_rgba_clear - template struct comp_op_rgba_clear - { - typedef ColorT color_type; - typedef Order order_type; - typedef typename color_type::value_type value_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - static AGG_INLINE void blend_pix(value_type* p, - unsigned, unsigned, unsigned, unsigned, - unsigned cover) - { - if(cover < 255) - { - cover = 255 - cover; - p[Order::R] = (value_type)((p[Order::R] * cover + 255) >> 8); - p[Order::G] = (value_type)((p[Order::G] * cover + 255) >> 8); - p[Order::B] = (value_type)((p[Order::B] * cover + 255) >> 8); - p[Order::A] = (value_type)((p[Order::A] * cover + 255) >> 8); - } - else - { - p[0] = p[1] = p[2] = p[3] = 0; - } - } - }; - - //===========================================================comp_op_rgba_src - template struct comp_op_rgba_src - { - typedef ColorT color_type; - typedef Order order_type; - typedef typename color_type::value_type value_type; - - static AGG_INLINE void blend_pix(value_type* p, - unsigned sr, unsigned sg, unsigned sb, - unsigned sa, unsigned cover) - { - if(cover < 255) - { - unsigned alpha = 255 - cover; - p[Order::R] = (value_type)(((p[Order::R] * alpha + 255) >> 8) + ((sr * cover + 255) >> 8)); - p[Order::G] = (value_type)(((p[Order::G] * alpha + 255) >> 8) + ((sg * cover + 255) >> 8)); - p[Order::B] = (value_type)(((p[Order::B] * alpha + 255) >> 8) + ((sb * cover + 255) >> 8)); - p[Order::A] = (value_type)(((p[Order::A] * alpha + 255) >> 8) + ((sa * cover + 255) >> 8)); - } - else - { - p[Order::R] = sr; - p[Order::G] = sg; - p[Order::B] = sb; - p[Order::A] = sa; - } - } - }; - - //===========================================================comp_op_rgba_dst - template struct comp_op_rgba_dst - { - typedef ColorT color_type; - typedef Order order_type; - typedef typename color_type::value_type value_type; - - static AGG_INLINE void blend_pix(value_type*, - unsigned, unsigned, unsigned, - unsigned, unsigned) - { - } - }; - - //======================================================comp_op_rgba_src_over - template struct comp_op_rgba_src_over - { - typedef ColorT color_type; - typedef Order order_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - // Dca' = Sca + Dca.(1 - Sa) - // Da' = Sa + Da - Sa.Da - static AGG_INLINE void blend_pix(value_type* p, - unsigned sr, unsigned sg, unsigned sb, - unsigned sa, unsigned cover) - { - if(cover < 255) - { - sr = (sr * cover + 255) >> 8; - sg = (sg * cover + 255) >> 8; - sb = (sb * cover + 255) >> 8; - sa = (sa * cover + 255) >> 8; - } - calc_type s1a = base_mask - sa; - p[Order::R] = (value_type)(sr + ((p[Order::R] * s1a + base_mask) >> base_shift)); - p[Order::G] = (value_type)(sg + ((p[Order::G] * s1a + base_mask) >> base_shift)); - p[Order::B] = (value_type)(sb + ((p[Order::B] * s1a + base_mask) >> base_shift)); - p[Order::A] = (value_type)(sa + p[Order::A] - ((sa * p[Order::A] + base_mask) >> base_shift)); - } - }; - - //======================================================comp_op_rgba_dst_over - template struct comp_op_rgba_dst_over - { - typedef ColorT color_type; - typedef Order order_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - // Dca' = Dca + Sca.(1 - Da) - // Da' = Sa + Da - Sa.Da - static AGG_INLINE void blend_pix(value_type* p, - unsigned sr, unsigned sg, unsigned sb, - unsigned sa, unsigned cover) - { - if(cover < 255) - { - sr = (sr * cover + 255) >> 8; - sg = (sg * cover + 255) >> 8; - sb = (sb * cover + 255) >> 8; - sa = (sa * cover + 255) >> 8; - } - calc_type d1a = base_mask - p[Order::A]; - p[Order::R] = (value_type)(p[Order::R] + ((sr * d1a + base_mask) >> base_shift)); - p[Order::G] = (value_type)(p[Order::G] + ((sg * d1a + base_mask) >> base_shift)); - p[Order::B] = (value_type)(p[Order::B] + ((sb * d1a + base_mask) >> base_shift)); - p[Order::A] = (value_type)(sa + p[Order::A] - ((sa * p[Order::A] + base_mask) >> base_shift)); - } - }; - - //======================================================comp_op_rgba_src_in - template struct comp_op_rgba_src_in - { - typedef ColorT color_type; - typedef Order order_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - // Dca' = Sca.Da - // Da' = Sa.Da - static AGG_INLINE void blend_pix(value_type* p, - unsigned sr, unsigned sg, unsigned sb, - unsigned sa, unsigned cover) - { - calc_type da = p[Order::A]; - if(cover < 255) - { - unsigned alpha = 255 - cover; - p[Order::R] = (value_type)(((p[Order::R] * alpha + 255) >> 8) + ((((sr * da + base_mask) >> base_shift) * cover + 255) >> 8)); - p[Order::G] = (value_type)(((p[Order::G] * alpha + 255) >> 8) + ((((sg * da + base_mask) >> base_shift) * cover + 255) >> 8)); - p[Order::B] = (value_type)(((p[Order::B] * alpha + 255) >> 8) + ((((sb * da + base_mask) >> base_shift) * cover + 255) >> 8)); - p[Order::A] = (value_type)(((p[Order::A] * alpha + 255) >> 8) + ((((sa * da + base_mask) >> base_shift) * cover + 255) >> 8)); - } - else - { - p[Order::R] = (value_type)((sr * da + base_mask) >> base_shift); - p[Order::G] = (value_type)((sg * da + base_mask) >> base_shift); - p[Order::B] = (value_type)((sb * da + base_mask) >> base_shift); - p[Order::A] = (value_type)((sa * da + base_mask) >> base_shift); - } - } - }; - - //======================================================comp_op_rgba_dst_in - template struct comp_op_rgba_dst_in - { - typedef ColorT color_type; - typedef Order order_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - // Dca' = Dca.Sa - // Da' = Sa.Da - static AGG_INLINE void blend_pix(value_type* p, - unsigned, unsigned, unsigned, - unsigned sa, unsigned cover) - { - if(cover < 255) - { - sa = base_mask - ((cover * (base_mask - sa) + 255) >> 8); - } - p[Order::R] = (value_type)((p[Order::R] * sa + base_mask) >> base_shift); - p[Order::G] = (value_type)((p[Order::G] * sa + base_mask) >> base_shift); - p[Order::B] = (value_type)((p[Order::B] * sa + base_mask) >> base_shift); - p[Order::A] = (value_type)((p[Order::A] * sa + base_mask) >> base_shift); - } - }; - - //======================================================comp_op_rgba_src_out - template struct comp_op_rgba_src_out - { - typedef ColorT color_type; - typedef Order order_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - // Dca' = Sca.(1 - Da) - // Da' = Sa.(1 - Da) - static AGG_INLINE void blend_pix(value_type* p, - unsigned sr, unsigned sg, unsigned sb, - unsigned sa, unsigned cover) - { - calc_type da = base_mask - p[Order::A]; - if(cover < 255) - { - unsigned alpha = 255 - cover; - p[Order::R] = (value_type)(((p[Order::R] * alpha + 255) >> 8) + ((((sr * da + base_mask) >> base_shift) * cover + 255) >> 8)); - p[Order::G] = (value_type)(((p[Order::G] * alpha + 255) >> 8) + ((((sg * da + base_mask) >> base_shift) * cover + 255) >> 8)); - p[Order::B] = (value_type)(((p[Order::B] * alpha + 255) >> 8) + ((((sb * da + base_mask) >> base_shift) * cover + 255) >> 8)); - p[Order::A] = (value_type)(((p[Order::A] * alpha + 255) >> 8) + ((((sa * da + base_mask) >> base_shift) * cover + 255) >> 8)); - } - else - { - p[Order::R] = (value_type)((sr * da + base_mask) >> base_shift); - p[Order::G] = (value_type)((sg * da + base_mask) >> base_shift); - p[Order::B] = (value_type)((sb * da + base_mask) >> base_shift); - p[Order::A] = (value_type)((sa * da + base_mask) >> base_shift); - } - } - }; - - //======================================================comp_op_rgba_dst_out - template struct comp_op_rgba_dst_out - { - typedef ColorT color_type; - typedef Order order_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - // Dca' = Dca.(1 - Sa) - // Da' = Da.(1 - Sa) - static AGG_INLINE void blend_pix(value_type* p, - unsigned, unsigned, unsigned, - unsigned sa, unsigned cover) - { - if(cover < 255) - { - sa = (sa * cover + 255) >> 8; - } - sa = base_mask - sa; - p[Order::R] = (value_type)((p[Order::R] * sa + base_shift) >> base_shift); - p[Order::G] = (value_type)((p[Order::G] * sa + base_shift) >> base_shift); - p[Order::B] = (value_type)((p[Order::B] * sa + base_shift) >> base_shift); - p[Order::A] = (value_type)((p[Order::A] * sa + base_shift) >> base_shift); - } - }; - - //=====================================================comp_op_rgba_src_atop - template struct comp_op_rgba_src_atop - { - typedef ColorT color_type; - typedef Order order_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - // Dca' = Sca.Da + Dca.(1 - Sa) - // Da' = Da - static AGG_INLINE void blend_pix(value_type* p, - unsigned sr, unsigned sg, unsigned sb, - unsigned sa, unsigned cover) - { - if(cover < 255) - { - sr = (sr * cover + 255) >> 8; - sg = (sg * cover + 255) >> 8; - sb = (sb * cover + 255) >> 8; - sa = (sa * cover + 255) >> 8; - } - calc_type da = p[Order::A]; - sa = base_mask - sa; - p[Order::R] = (value_type)((sr * da + p[Order::R] * sa + base_mask) >> base_shift); - p[Order::G] = (value_type)((sg * da + p[Order::G] * sa + base_mask) >> base_shift); - p[Order::B] = (value_type)((sb * da + p[Order::B] * sa + base_mask) >> base_shift); - } - }; - - //=====================================================comp_op_rgba_dst_atop - template struct comp_op_rgba_dst_atop - { - typedef ColorT color_type; - typedef Order order_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - // Dca' = Dca.Sa + Sca.(1 - Da) - // Da' = Sa - static AGG_INLINE void blend_pix(value_type* p, - unsigned sr, unsigned sg, unsigned sb, - unsigned sa, unsigned cover) - { - calc_type da = base_mask - p[Order::A]; - if(cover < 255) - { - unsigned alpha = 255 - cover; - sr = (p[Order::R] * sa + sr * da + base_mask) >> base_shift; - sg = (p[Order::G] * sa + sg * da + base_mask) >> base_shift; - sb = (p[Order::B] * sa + sb * da + base_mask) >> base_shift; - p[Order::R] = (value_type)(((p[Order::R] * alpha + 255) >> 8) + ((sr * cover + 255) >> 8)); - p[Order::G] = (value_type)(((p[Order::G] * alpha + 255) >> 8) + ((sg * cover + 255) >> 8)); - p[Order::B] = (value_type)(((p[Order::B] * alpha + 255) >> 8) + ((sb * cover + 255) >> 8)); - p[Order::A] = (value_type)(((p[Order::A] * alpha + 255) >> 8) + ((sa * cover + 255) >> 8)); - - } - else - { - p[Order::R] = (value_type)((p[Order::R] * sa + sr * da + base_mask) >> base_shift); - p[Order::G] = (value_type)((p[Order::G] * sa + sg * da + base_mask) >> base_shift); - p[Order::B] = (value_type)((p[Order::B] * sa + sb * da + base_mask) >> base_shift); - p[Order::A] = (value_type)sa; - } - } - }; - - //=========================================================comp_op_rgba_xor - template struct comp_op_rgba_xor - { - typedef ColorT color_type; - typedef Order order_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - // Dca' = Sca.(1 - Da) + Dca.(1 - Sa) - // Da' = Sa + Da - 2.Sa.Da - static AGG_INLINE void blend_pix(value_type* p, - unsigned sr, unsigned sg, unsigned sb, - unsigned sa, unsigned cover) - { - if(cover < 255) - { - sr = (sr * cover + 255) >> 8; - sg = (sg * cover + 255) >> 8; - sb = (sb * cover + 255) >> 8; - sa = (sa * cover + 255) >> 8; - } - if(sa) - { - calc_type s1a = base_mask - sa; - calc_type d1a = base_mask - p[Order::A]; - p[Order::R] = (value_type)((p[Order::R] * s1a + sr * d1a + base_mask) >> base_shift); - p[Order::G] = (value_type)((p[Order::G] * s1a + sg * d1a + base_mask) >> base_shift); - p[Order::B] = (value_type)((p[Order::B] * s1a + sb * d1a + base_mask) >> base_shift); - p[Order::A] = (value_type)(sa + p[Order::A] - ((sa * p[Order::A] + base_mask/2) >> (base_shift - 1))); - } - } - }; - - //=========================================================comp_op_rgba_plus - template struct comp_op_rgba_plus - { - typedef ColorT color_type; - typedef Order order_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - // Dca' = Sca + Dca - // Da' = Sa + Da - static AGG_INLINE void blend_pix(value_type* p, - unsigned sr, unsigned sg, unsigned sb, - unsigned sa, unsigned cover) - { - if(cover < 255) - { - sr = (sr * cover + 255) >> 8; - sg = (sg * cover + 255) >> 8; - sb = (sb * cover + 255) >> 8; - sa = (sa * cover + 255) >> 8; - } - if(sa) - { - calc_type dr = p[Order::R] + sr; - calc_type dg = p[Order::G] + sg; - calc_type db = p[Order::B] + sb; - calc_type da = p[Order::A] + sa; - p[Order::R] = (dr > base_mask) ? (value_type)base_mask : dr; - p[Order::G] = (dg > base_mask) ? (value_type)base_mask : dg; - p[Order::B] = (db > base_mask) ? (value_type)base_mask : db; - p[Order::A] = (da > base_mask) ? (value_type)base_mask : da; - } - } - }; - - //========================================================comp_op_rgba_minus - template struct comp_op_rgba_minus - { - typedef ColorT color_type; - typedef Order order_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - // Dca' = Dca - Sca - // Da' = 1 - (1 - Sa).(1 - Da) - static AGG_INLINE void blend_pix(value_type* p, - unsigned sr, unsigned sg, unsigned sb, - unsigned sa, unsigned cover) - { - if(cover < 255) - { - sr = (sr * cover + 255) >> 8; - sg = (sg * cover + 255) >> 8; - sb = (sb * cover + 255) >> 8; - sa = (sa * cover + 255) >> 8; - } - if(sa) - { - calc_type dr = p[Order::R] - sr; - calc_type dg = p[Order::G] - sg; - calc_type db = p[Order::B] - sb; - p[Order::R] = (dr > base_mask) ? 0 : dr; - p[Order::G] = (dg > base_mask) ? 0 : dg; - p[Order::B] = (db > base_mask) ? 0 : db; - p[Order::A] = (value_type)(sa + p[Order::A] - ((sa * p[Order::A] + base_mask) >> base_shift)); - //p[Order::A] = (value_type)(base_mask - (((base_mask - sa) * (base_mask - p[Order::A]) + base_mask) >> base_shift)); - } - } - }; - - //=====================================================comp_op_rgba_multiply - template struct comp_op_rgba_multiply - { - typedef ColorT color_type; - typedef Order order_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - // Dca' = Sca.Dca + Sca.(1 - Da) + Dca.(1 - Sa) - // Da' = Sa + Da - Sa.Da - static AGG_INLINE void blend_pix(value_type* p, - unsigned sr, unsigned sg, unsigned sb, - unsigned sa, unsigned cover) - { - if(cover < 255) - { - sr = (sr * cover + 255) >> 8; - sg = (sg * cover + 255) >> 8; - sb = (sb * cover + 255) >> 8; - sa = (sa * cover + 255) >> 8; - } - if(sa) - { - calc_type s1a = base_mask - sa; - calc_type d1a = base_mask - p[Order::A]; - calc_type dr = p[Order::R]; - calc_type dg = p[Order::G]; - calc_type db = p[Order::B]; - p[Order::R] = (value_type)((sr * dr + sr * d1a + dr * s1a + base_mask) >> base_shift); - p[Order::G] = (value_type)((sg * dg + sg * d1a + dg * s1a + base_mask) >> base_shift); - p[Order::B] = (value_type)((sb * db + sb * d1a + db * s1a + base_mask) >> base_shift); - p[Order::A] = (value_type)(sa + p[Order::A] - ((sa * p[Order::A] + base_mask) >> base_shift)); - } - } - }; - - //=====================================================comp_op_rgba_screen - template struct comp_op_rgba_screen - { - typedef ColorT color_type; - typedef Order order_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - // Dca' = Sca + Dca - Sca.Dca - // Da' = Sa + Da - Sa.Da - static AGG_INLINE void blend_pix(value_type* p, - unsigned sr, unsigned sg, unsigned sb, - unsigned sa, unsigned cover) - { - if(cover < 255) - { - sr = (sr * cover + 255) >> 8; - sg = (sg * cover + 255) >> 8; - sb = (sb * cover + 255) >> 8; - sa = (sa * cover + 255) >> 8; - } - if(sa) - { - calc_type dr = p[Order::R]; - calc_type dg = p[Order::G]; - calc_type db = p[Order::B]; - calc_type da = p[Order::A]; - p[Order::R] = (value_type)(sr + dr - ((sr * dr + base_mask) >> base_shift)); - p[Order::G] = (value_type)(sg + dg - ((sg * dg + base_mask) >> base_shift)); - p[Order::B] = (value_type)(sb + db - ((sb * db + base_mask) >> base_shift)); - p[Order::A] = (value_type)(sa + da - ((sa * da + base_mask) >> base_shift)); - } - } - }; - - //=====================================================comp_op_rgba_overlay - template struct comp_op_rgba_overlay - { - typedef ColorT color_type; - typedef Order order_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - // if 2.Dca < Da - // Dca' = 2.Sca.Dca + Sca.(1 - Da) + Dca.(1 - Sa) - // otherwise - // Dca' = Sa.Da - 2.(Da - Dca).(Sa - Sca) + Sca.(1 - Da) + Dca.(1 - Sa) - // - // Da' = Sa + Da - Sa.Da - static AGG_INLINE void blend_pix(value_type* p, - unsigned sr, unsigned sg, unsigned sb, - unsigned sa, unsigned cover) - { - if(cover < 255) - { - sr = (sr * cover + 255) >> 8; - sg = (sg * cover + 255) >> 8; - sb = (sb * cover + 255) >> 8; - sa = (sa * cover + 255) >> 8; - } - if(sa) - { - calc_type d1a = base_mask - p[Order::A]; - calc_type s1a = base_mask - sa; - calc_type dr = p[Order::R]; - calc_type dg = p[Order::G]; - calc_type db = p[Order::B]; - calc_type da = p[Order::A]; - calc_type sada = sa * p[Order::A]; - - p[Order::R] = (value_type)(((2*dr < da) ? - 2*sr*dr + sr*d1a + dr*s1a : - sada - 2*(da - dr)*(sa - sr) + sr*d1a + dr*s1a + base_mask) >> base_shift); - - p[Order::G] = (value_type)(((2*dg < da) ? - 2*sg*dg + sg*d1a + dg*s1a : - sada - 2*(da - dg)*(sa - sg) + sg*d1a + dg*s1a + base_mask) >> base_shift); - - p[Order::B] = (value_type)(((2*db < da) ? - 2*sb*db + sb*d1a + db*s1a : - sada - 2*(da - db)*(sa - sb) + sb*d1a + db*s1a + base_mask) >> base_shift); - - p[Order::A] = (value_type)(sa + da - ((sa * da + base_mask) >> base_shift)); - } - } - }; - - - template inline T sd_min(T a, T b) { return (a < b) ? a : b; } - template inline T sd_max(T a, T b) { return (a > b) ? a : b; } - - //=====================================================comp_op_rgba_darken - template struct comp_op_rgba_darken - { - typedef ColorT color_type; - typedef Order order_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - // Dca' = min(Sca.Da, Dca.Sa) + Sca.(1 - Da) + Dca.(1 - Sa) - // Da' = Sa + Da - Sa.Da - static AGG_INLINE void blend_pix(value_type* p, - unsigned sr, unsigned sg, unsigned sb, - unsigned sa, unsigned cover) - { - if(cover < 255) - { - sr = (sr * cover + 255) >> 8; - sg = (sg * cover + 255) >> 8; - sb = (sb * cover + 255) >> 8; - sa = (sa * cover + 255) >> 8; - } - if(sa) - { - calc_type d1a = base_mask - p[Order::A]; - calc_type s1a = base_mask - sa; - calc_type dr = p[Order::R]; - calc_type dg = p[Order::G]; - calc_type db = p[Order::B]; - calc_type da = p[Order::A]; - - p[Order::R] = (value_type)((sd_min(sr * da, dr * sa) + sr * d1a + dr * s1a + base_mask) >> base_shift); - p[Order::G] = (value_type)((sd_min(sg * da, dg * sa) + sg * d1a + dg * s1a + base_mask) >> base_shift); - p[Order::B] = (value_type)((sd_min(sb * da, db * sa) + sb * d1a + db * s1a + base_mask) >> base_shift); - p[Order::A] = (value_type)(sa + da - ((sa * da + base_mask) >> base_shift)); - } - } - }; - - //=====================================================comp_op_rgba_lighten - template struct comp_op_rgba_lighten - { - typedef ColorT color_type; - typedef Order order_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - // Dca' = max(Sca.Da, Dca.Sa) + Sca.(1 - Da) + Dca.(1 - Sa) - // Da' = Sa + Da - Sa.Da - static AGG_INLINE void blend_pix(value_type* p, - unsigned sr, unsigned sg, unsigned sb, - unsigned sa, unsigned cover) - { - if(cover < 255) - { - sr = (sr * cover + 255) >> 8; - sg = (sg * cover + 255) >> 8; - sb = (sb * cover + 255) >> 8; - sa = (sa * cover + 255) >> 8; - } - if(sa) - { - calc_type d1a = base_mask - p[Order::A]; - calc_type s1a = base_mask - sa; - calc_type dr = p[Order::R]; - calc_type dg = p[Order::G]; - calc_type db = p[Order::B]; - calc_type da = p[Order::A]; - - p[Order::R] = (value_type)((sd_max(sr * da, dr * sa) + sr * d1a + dr * s1a + base_mask) >> base_shift); - p[Order::G] = (value_type)((sd_max(sg * da, dg * sa) + sg * d1a + dg * s1a + base_mask) >> base_shift); - p[Order::B] = (value_type)((sd_max(sb * da, db * sa) + sb * d1a + db * s1a + base_mask) >> base_shift); - p[Order::A] = (value_type)(sa + da - ((sa * da + base_mask) >> base_shift)); - } - } - }; - - //=====================================================comp_op_rgba_color_dodge - template struct comp_op_rgba_color_dodge - { - typedef ColorT color_type; - typedef Order order_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - typedef typename color_type::long_type long_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - // if Sca.Da + Dca.Sa >= Sa.Da - // Dca' = Sa.Da + Sca.(1 - Da) + Dca.(1 - Sa) - // otherwise - // Dca' = Dca.Sa/(1-Sca/Sa) + Sca.(1 - Da) + Dca.(1 - Sa) - // - // Da' = Sa + Da - Sa.Da - static AGG_INLINE void blend_pix(value_type* p, - unsigned sr, unsigned sg, unsigned sb, - unsigned sa, unsigned cover) - { - if(cover < 255) - { - sr = (sr * cover + 255) >> 8; - sg = (sg * cover + 255) >> 8; - sb = (sb * cover + 255) >> 8; - sa = (sa * cover + 255) >> 8; - } - if(sa) - { - calc_type d1a = base_mask - p[Order::A]; - calc_type s1a = base_mask - sa; - calc_type dr = p[Order::R]; - calc_type dg = p[Order::G]; - calc_type db = p[Order::B]; - calc_type da = p[Order::A]; - long_type drsa = dr * sa; - long_type dgsa = dg * sa; - long_type dbsa = db * sa; - long_type srda = sr * da; - long_type sgda = sg * da; - long_type sbda = sb * da; - long_type sada = sa * da; - - p[Order::R] = (value_type)((srda + drsa >= sada) ? - (sada + sr * d1a + dr * s1a + base_mask) >> base_shift : - drsa / (base_mask - (sr << base_shift) / sa) + ((sr * d1a + dr * s1a + base_mask) >> base_shift)); - - p[Order::G] = (value_type)((sgda + dgsa >= sada) ? - (sada + sg * d1a + dg * s1a + base_mask) >> base_shift : - dgsa / (base_mask - (sg << base_shift) / sa) + ((sg * d1a + dg * s1a + base_mask) >> base_shift)); - - p[Order::B] = (value_type)((sbda + dbsa >= sada) ? - (sada + sb * d1a + db * s1a + base_mask) >> base_shift : - dbsa / (base_mask - (sb << base_shift) / sa) + ((sb * d1a + db * s1a + base_mask) >> base_shift)); - - p[Order::A] = (value_type)(sa + da - ((sa * da + base_mask) >> base_shift)); - } - } - }; - - //=====================================================comp_op_rgba_color_burn - template struct comp_op_rgba_color_burn - { - typedef ColorT color_type; - typedef Order order_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - typedef typename color_type::long_type long_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - // if Sca.Da + Dca.Sa <= Sa.Da - // Dca' = Sca.(1 - Da) + Dca.(1 - Sa) - // otherwise - // Dca' = Sa.(Sca.Da + Dca.Sa - Sa.Da)/Sca + Sca.(1 - Da) + Dca.(1 - Sa) - // - // Da' = Sa + Da - Sa.Da - static AGG_INLINE void blend_pix(value_type* p, - unsigned sr, unsigned sg, unsigned sb, - unsigned sa, unsigned cover) - { - if(cover < 255) - { - sr = (sr * cover + 255) >> 8; - sg = (sg * cover + 255) >> 8; - sb = (sb * cover + 255) >> 8; - sa = (sa * cover + 255) >> 8; - } - if(sa) - { - calc_type d1a = base_mask - p[Order::A]; - calc_type s1a = base_mask - sa; - calc_type dr = p[Order::R]; - calc_type dg = p[Order::G]; - calc_type db = p[Order::B]; - calc_type da = p[Order::A]; - long_type drsa = dr * sa; - long_type dgsa = dg * sa; - long_type dbsa = db * sa; - long_type srda = sr * da; - long_type sgda = sg * da; - long_type sbda = sb * da; - long_type sada = sa * da; - - p[Order::R] = (value_type)(((srda + drsa <= sada) ? - sr * d1a + dr * s1a : - sa * (srda + drsa - sada) / sr + sr * d1a + dr * s1a + base_mask) >> base_shift); - - p[Order::G] = (value_type)(((sgda + dgsa <= sada) ? - sg * d1a + dg * s1a : - sa * (sgda + dgsa - sada) / sg + sg * d1a + dg * s1a + base_mask) >> base_shift); - - p[Order::B] = (value_type)(((sbda + dbsa <= sada) ? - sb * d1a + db * s1a : - sa * (sbda + dbsa - sada) / sb + sb * d1a + db * s1a + base_mask) >> base_shift); - - p[Order::A] = (value_type)(sa + da - ((sa * da + base_mask) >> base_shift)); - } - } - }; - - //=====================================================comp_op_rgba_hard_light - template struct comp_op_rgba_hard_light - { - typedef ColorT color_type; - typedef Order order_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - typedef typename color_type::long_type long_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - // if 2.Sca < Sa - // Dca' = 2.Sca.Dca + Sca.(1 - Da) + Dca.(1 - Sa) - // otherwise - // Dca' = Sa.Da - 2.(Da - Dca).(Sa - Sca) + Sca.(1 - Da) + Dca.(1 - Sa) - // - // Da' = Sa + Da - Sa.Da - static AGG_INLINE void blend_pix(value_type* p, - unsigned sr, unsigned sg, unsigned sb, - unsigned sa, unsigned cover) - { - if(cover < 255) - { - sr = (sr * cover + 255) >> 8; - sg = (sg * cover + 255) >> 8; - sb = (sb * cover + 255) >> 8; - sa = (sa * cover + 255) >> 8; - } - if(sa) - { - calc_type d1a = base_mask - p[Order::A]; - calc_type s1a = base_mask - sa; - calc_type dr = p[Order::R]; - calc_type dg = p[Order::G]; - calc_type db = p[Order::B]; - calc_type da = p[Order::A]; - calc_type sada = sa * da; - - p[Order::R] = (value_type)(((2*sr < sa) ? - 2*sr*dr + sr*d1a + dr*s1a : - sada - 2*(da - dr)*(sa - sr) + sr*d1a + dr*s1a + base_mask) >> base_shift); - - p[Order::G] = (value_type)(((2*sg < sa) ? - 2*sg*dg + sg*d1a + dg*s1a : - sada - 2*(da - dg)*(sa - sg) + sg*d1a + dg*s1a + base_mask) >> base_shift); - - p[Order::B] = (value_type)(((2*sb < sa) ? - 2*sb*db + sb*d1a + db*s1a : - sada - 2*(da - db)*(sa - sb) + sb*d1a + db*s1a + base_mask) >> base_shift); - - p[Order::A] = (value_type)(sa + da - ((sa * da + base_mask) >> base_shift)); - } - } - }; - - //=====================================================comp_op_rgba_soft_light - template struct comp_op_rgba_soft_light - { - typedef ColorT color_type; - typedef Order order_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - typedef typename color_type::long_type long_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - // if 2.Sca < Sa - // Dca' = Dca.(Sa + (1 - Dca/Da).(2.Sca - Sa)) + Sca.(1 - Da) + Dca.(1 - Sa) - // otherwise if 8.Dca <= Da - // Dca' = Dca.(Sa + (1 - Dca/Da).(2.Sca - Sa).(3 - 8.Dca/Da)) + Sca.(1 - Da) + Dca.(1 - Sa) - // otherwise - // Dca' = (Dca.Sa + ((Dca/Da)^(0.5).Da - Dca).(2.Sca - Sa)) + Sca.(1 - Da) + Dca.(1 - Sa) - // - // Da' = Sa + Da - Sa.Da - - static AGG_INLINE void blend_pix(value_type* p, - unsigned r, unsigned g, unsigned b, - unsigned a, unsigned cover) - { - double sr = double(r * cover) / (base_mask * 255); - double sg = double(g * cover) / (base_mask * 255); - double sb = double(b * cover) / (base_mask * 255); - double sa = double(a * cover) / (base_mask * 255); - if(sa > 0) - { - double dr = double(p[Order::R]) / base_mask; - double dg = double(p[Order::G]) / base_mask; - double db = double(p[Order::B]) / base_mask; - double da = double(p[Order::A] ? p[Order::A] : 1) / base_mask; - if(cover < 255) - { - a = (a * cover + 255) >> 8; - } - - if(2*sr < sa) dr = dr*(sa + (1 - dr/da)*(2*sr - sa)) + sr*(1 - da) + dr*(1 - sa); - else if(8*dr <= da) dr = dr*(sa + (1 - dr/da)*(2*sr - sa)*(3 - 8*dr/da)) + sr*(1 - da) + dr*(1 - sa); - else dr = (dr*sa + (sqrt(dr/da)*da - dr)*(2*sr - sa)) + sr*(1 - da) + dr*(1 - sa); - - if(2*sg < sa) dg = dg*(sa + (1 - dg/da)*(2*sg - sa)) + sg*(1 - da) + dg*(1 - sa); - else if(8*dg <= da) dg = dg*(sa + (1 - dg/da)*(2*sg - sa)*(3 - 8*dg/da)) + sg*(1 - da) + dg*(1 - sa); - else dg = (dg*sa + (sqrt(dg/da)*da - dg)*(2*sg - sa)) + sg*(1 - da) + dg*(1 - sa); - - if(2*sb < sa) db = db*(sa + (1 - db/da)*(2*sb - sa)) + sb*(1 - da) + db*(1 - sa); - else if(8*db <= da) db = db*(sa + (1 - db/da)*(2*sb - sa)*(3 - 8*db/da)) + sb*(1 - da) + db*(1 - sa); - else db = (db*sa + (sqrt(db/da)*da - db)*(2*sb - sa)) + sb*(1 - da) + db*(1 - sa); - - p[Order::R] = (value_type)uround(dr * base_mask); - p[Order::G] = (value_type)uround(dg * base_mask); - p[Order::B] = (value_type)uround(db * base_mask); - p[Order::A] = (value_type)(a + p[Order::A] - ((a * p[Order::A] + base_mask) >> base_shift)); - } - } - }; - - //=====================================================comp_op_rgba_difference - template struct comp_op_rgba_difference - { - typedef ColorT color_type; - typedef Order order_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - typedef typename color_type::long_type long_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_scale = color_type::base_scale, - base_mask = color_type::base_mask - }; - - // Dca' = Sca + Dca - 2.min(Sca.Da, Dca.Sa) - // Da' = Sa + Da - Sa.Da - static AGG_INLINE void blend_pix(value_type* p, - unsigned sr, unsigned sg, unsigned sb, - unsigned sa, unsigned cover) - { - if(cover < 255) - { - sr = (sr * cover + 255) >> 8; - sg = (sg * cover + 255) >> 8; - sb = (sb * cover + 255) >> 8; - sa = (sa * cover + 255) >> 8; - } - if(sa) - { - calc_type dr = p[Order::R]; - calc_type dg = p[Order::G]; - calc_type db = p[Order::B]; - calc_type da = p[Order::A]; - p[Order::R] = (value_type)(sr + dr - ((2 * sd_min(sr*da, dr*sa) + base_mask) >> base_shift)); - p[Order::G] = (value_type)(sg + dg - ((2 * sd_min(sg*da, dg*sa) + base_mask) >> base_shift)); - p[Order::B] = (value_type)(sb + db - ((2 * sd_min(sb*da, db*sa) + base_mask) >> base_shift)); - p[Order::A] = (value_type)(sa + da - ((sa * da + base_mask) >> base_shift)); - } - } - }; - - //=====================================================comp_op_rgba_exclusion - template struct comp_op_rgba_exclusion - { - typedef ColorT color_type; - typedef Order order_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - typedef typename color_type::long_type long_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - // Dca' = (Sca.Da + Dca.Sa - 2.Sca.Dca) + Sca.(1 - Da) + Dca.(1 - Sa) - // Da' = Sa + Da - Sa.Da - static AGG_INLINE void blend_pix(value_type* p, - unsigned sr, unsigned sg, unsigned sb, - unsigned sa, unsigned cover) - { - if(cover < 255) - { - sr = (sr * cover + 255) >> 8; - sg = (sg * cover + 255) >> 8; - sb = (sb * cover + 255) >> 8; - sa = (sa * cover + 255) >> 8; - } - if(sa) - { - calc_type d1a = base_mask - p[Order::A]; - calc_type s1a = base_mask - sa; - calc_type dr = p[Order::R]; - calc_type dg = p[Order::G]; - calc_type db = p[Order::B]; - calc_type da = p[Order::A]; - p[Order::R] = (value_type)((sr*da + dr*sa - 2*sr*dr + sr*d1a + dr*s1a + base_mask) >> base_shift); - p[Order::G] = (value_type)((sg*da + dg*sa - 2*sg*dg + sg*d1a + dg*s1a + base_mask) >> base_shift); - p[Order::B] = (value_type)((sb*da + db*sa - 2*sb*db + sb*d1a + db*s1a + base_mask) >> base_shift); - p[Order::A] = (value_type)(sa + da - ((sa * da + base_mask) >> base_shift)); - } - } - }; - - //=====================================================comp_op_rgba_contrast - template struct comp_op_rgba_contrast - { - typedef ColorT color_type; - typedef Order order_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - typedef typename color_type::long_type long_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - - static AGG_INLINE void blend_pix(value_type* p, - unsigned sr, unsigned sg, unsigned sb, - unsigned sa, unsigned cover) - { - if(cover < 255) - { - sr = (sr * cover + 255) >> 8; - sg = (sg * cover + 255) >> 8; - sb = (sb * cover + 255) >> 8; - sa = (sa * cover + 255) >> 8; - } - long_type dr = p[Order::R]; - long_type dg = p[Order::G]; - long_type db = p[Order::B]; - int da = p[Order::A]; - long_type d2a = da >> 1; - unsigned s2a = sa >> 1; - - int r = (int)((((dr - d2a) * int((sr - s2a)*2 + base_mask)) >> base_shift) + d2a); - int g = (int)((((dg - d2a) * int((sg - s2a)*2 + base_mask)) >> base_shift) + d2a); - int b = (int)((((db - d2a) * int((sb - s2a)*2 + base_mask)) >> base_shift) + d2a); - - r = (r < 0) ? 0 : r; - g = (g < 0) ? 0 : g; - b = (b < 0) ? 0 : b; - - p[Order::R] = (value_type)((r > da) ? da : r); - p[Order::G] = (value_type)((g > da) ? da : g); - p[Order::B] = (value_type)((b > da) ? da : b); - } - }; - - //=====================================================comp_op_rgba_invert - template struct comp_op_rgba_invert - { - typedef ColorT color_type; - typedef Order order_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - typedef typename color_type::long_type long_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - // Dca' = (Da - Dca) * Sa + Dca.(1 - Sa) - // Da' = Sa + Da - Sa.Da - static AGG_INLINE void blend_pix(value_type* p, - unsigned sr, unsigned sg, unsigned sb, - unsigned sa, unsigned cover) - { - sa = (sa * cover + 255) >> 8; - if(sa) - { - calc_type da = p[Order::A]; - calc_type dr = ((da - p[Order::R]) * sa + base_mask) >> base_shift; - calc_type dg = ((da - p[Order::G]) * sa + base_mask) >> base_shift; - calc_type db = ((da - p[Order::B]) * sa + base_mask) >> base_shift; - calc_type s1a = base_mask - sa; - p[Order::R] = (value_type)(dr + ((p[Order::R] * s1a + base_mask) >> base_shift)); - p[Order::G] = (value_type)(dg + ((p[Order::G] * s1a + base_mask) >> base_shift)); - p[Order::B] = (value_type)(db + ((p[Order::B] * s1a + base_mask) >> base_shift)); - p[Order::A] = (value_type)(sa + da - ((sa * da + base_mask) >> base_shift)); - } - } - }; - - //=================================================comp_op_rgba_invert_rgb - template struct comp_op_rgba_invert_rgb - { - typedef ColorT color_type; - typedef Order order_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - typedef typename color_type::long_type long_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - // Dca' = (Da - Dca) * Sca + Dca.(1 - Sa) - // Da' = Sa + Da - Sa.Da - static AGG_INLINE void blend_pix(value_type* p, - unsigned sr, unsigned sg, unsigned sb, - unsigned sa, unsigned cover) - { - if(cover < 255) - { - sr = (sr * cover + 255) >> 8; - sg = (sg * cover + 255) >> 8; - sb = (sb * cover + 255) >> 8; - sa = (sa * cover + 255) >> 8; - } - if(sa) - { - calc_type da = p[Order::A]; - calc_type dr = ((da - p[Order::R]) * sr + base_mask) >> base_shift; - calc_type dg = ((da - p[Order::G]) * sg + base_mask) >> base_shift; - calc_type db = ((da - p[Order::B]) * sb + base_mask) >> base_shift; - calc_type s1a = base_mask - sa; - p[Order::R] = (value_type)(dr + ((p[Order::R] * s1a + base_mask) >> base_shift)); - p[Order::G] = (value_type)(dg + ((p[Order::G] * s1a + base_mask) >> base_shift)); - p[Order::B] = (value_type)(db + ((p[Order::B] * s1a + base_mask) >> base_shift)); - p[Order::A] = (value_type)(sa + da - ((sa * da + base_mask) >> base_shift)); - } - } - }; - - - - - - //======================================================comp_op_table_rgba - template struct comp_op_table_rgba - { - typedef typename ColorT::value_type value_type; - typedef void (*comp_op_func_type)(value_type* p, - unsigned cr, - unsigned cg, - unsigned cb, - unsigned ca, - unsigned cover); - static comp_op_func_type g_comp_op_func[]; - }; - - //==========================================================g_comp_op_func - template - typename comp_op_table_rgba::comp_op_func_type - comp_op_table_rgba::g_comp_op_func[] = - { - comp_op_rgba_clear ::blend_pix, - comp_op_rgba_src ::blend_pix, - comp_op_rgba_dst ::blend_pix, - comp_op_rgba_src_over ::blend_pix, - comp_op_rgba_dst_over ::blend_pix, - comp_op_rgba_src_in ::blend_pix, - comp_op_rgba_dst_in ::blend_pix, - comp_op_rgba_src_out ::blend_pix, - comp_op_rgba_dst_out ::blend_pix, - comp_op_rgba_src_atop ::blend_pix, - comp_op_rgba_dst_atop ::blend_pix, - comp_op_rgba_xor ::blend_pix, - comp_op_rgba_plus ::blend_pix, - comp_op_rgba_minus ::blend_pix, - comp_op_rgba_multiply ::blend_pix, - comp_op_rgba_screen ::blend_pix, - comp_op_rgba_overlay ::blend_pix, - comp_op_rgba_darken ::blend_pix, - comp_op_rgba_lighten ::blend_pix, - comp_op_rgba_color_dodge::blend_pix, - comp_op_rgba_color_burn ::blend_pix, - comp_op_rgba_hard_light ::blend_pix, - comp_op_rgba_soft_light ::blend_pix, - comp_op_rgba_difference ::blend_pix, - comp_op_rgba_exclusion ::blend_pix, - comp_op_rgba_contrast ::blend_pix, - comp_op_rgba_invert ::blend_pix, - comp_op_rgba_invert_rgb ::blend_pix, - 0 - }; - - - //==============================================================comp_op_e - enum comp_op_e - { - comp_op_clear, //----comp_op_clear - comp_op_src, //----comp_op_src - comp_op_dst, //----comp_op_dst - comp_op_src_over, //----comp_op_src_over - comp_op_dst_over, //----comp_op_dst_over - comp_op_src_in, //----comp_op_src_in - comp_op_dst_in, //----comp_op_dst_in - comp_op_src_out, //----comp_op_src_out - comp_op_dst_out, //----comp_op_dst_out - comp_op_src_atop, //----comp_op_src_atop - comp_op_dst_atop, //----comp_op_dst_atop - comp_op_xor, //----comp_op_xor - comp_op_plus, //----comp_op_plus - comp_op_minus, //----comp_op_minus - comp_op_multiply, //----comp_op_multiply - comp_op_screen, //----comp_op_screen - comp_op_overlay, //----comp_op_overlay - comp_op_darken, //----comp_op_darken - comp_op_lighten, //----comp_op_lighten - comp_op_color_dodge, //----comp_op_color_dodge - comp_op_color_burn, //----comp_op_color_burn - comp_op_hard_light, //----comp_op_hard_light - comp_op_soft_light, //----comp_op_soft_light - comp_op_difference, //----comp_op_difference - comp_op_exclusion, //----comp_op_exclusion - comp_op_contrast, //----comp_op_contrast - comp_op_invert, //----comp_op_invert - comp_op_invert_rgb, //----comp_op_invert_rgb - - end_of_comp_op_e - }; - - - - - - - - //====================================================comp_op_adaptor_rgba - template struct comp_op_adaptor_rgba - { - typedef Order order_type; - typedef ColorT color_type; - typedef typename color_type::value_type value_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - static AGG_INLINE void blend_pix(unsigned op, value_type* p, - unsigned cr, unsigned cg, unsigned cb, - unsigned ca, - unsigned cover) - { - comp_op_table_rgba::g_comp_op_func[op] - (p, (cr * ca + base_mask) >> base_shift, - (cg * ca + base_mask) >> base_shift, - (cb * ca + base_mask) >> base_shift, - ca, cover); - } - }; - - //=========================================comp_op_adaptor_clip_to_dst_rgba - template struct comp_op_adaptor_clip_to_dst_rgba - { - typedef Order order_type; - typedef ColorT color_type; - typedef typename color_type::value_type value_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - static AGG_INLINE void blend_pix(unsigned op, value_type* p, - unsigned cr, unsigned cg, unsigned cb, - unsigned ca, - unsigned cover) - { - cr = (cr * ca + base_mask) >> base_shift; - cg = (cg * ca + base_mask) >> base_shift; - cb = (cb * ca + base_mask) >> base_shift; - unsigned da = p[Order::A]; - comp_op_table_rgba::g_comp_op_func[op] - (p, (cr * da + base_mask) >> base_shift, - (cg * da + base_mask) >> base_shift, - (cb * da + base_mask) >> base_shift, - (ca * da + base_mask) >> base_shift, - cover); - } - }; - - //================================================comp_op_adaptor_rgba_pre - template struct comp_op_adaptor_rgba_pre - { - typedef Order order_type; - typedef ColorT color_type; - typedef typename color_type::value_type value_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - static AGG_INLINE void blend_pix(unsigned op, value_type* p, - unsigned cr, unsigned cg, unsigned cb, - unsigned ca, - unsigned cover) - { - comp_op_table_rgba::g_comp_op_func[op](p, cr, cg, cb, ca, cover); - } - }; - - //=====================================comp_op_adaptor_clip_to_dst_rgba_pre - template struct comp_op_adaptor_clip_to_dst_rgba_pre - { - typedef Order order_type; - typedef ColorT color_type; - typedef typename color_type::value_type value_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - static AGG_INLINE void blend_pix(unsigned op, value_type* p, - unsigned cr, unsigned cg, unsigned cb, - unsigned ca, - unsigned cover) - { - unsigned da = p[Order::A]; - comp_op_table_rgba::g_comp_op_func[op] - (p, (cr * da + base_mask) >> base_shift, - (cg * da + base_mask) >> base_shift, - (cb * da + base_mask) >> base_shift, - (ca * da + base_mask) >> base_shift, - cover); - } - }; - - //=======================================================comp_adaptor_rgba - template struct comp_adaptor_rgba - { - typedef typename BlenderPre::order_type order_type; - typedef typename BlenderPre::color_type color_type; - typedef typename color_type::value_type value_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - static AGG_INLINE void blend_pix(unsigned op, value_type* p, - unsigned cr, unsigned cg, unsigned cb, - unsigned ca, - unsigned cover) - { - BlenderPre::blend_pix(p, - (cr * ca + base_mask) >> base_shift, - (cg * ca + base_mask) >> base_shift, - (cb * ca + base_mask) >> base_shift, - ca, cover); - } - }; - - //==========================================comp_adaptor_clip_to_dst_rgba - template struct comp_adaptor_clip_to_dst_rgba - { - typedef typename BlenderPre::order_type order_type; - typedef typename BlenderPre::color_type color_type; - typedef typename color_type::value_type value_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - static AGG_INLINE void blend_pix(unsigned op, value_type* p, - unsigned cr, unsigned cg, unsigned cb, - unsigned ca, - unsigned cover) - { - cr = (cr * ca + base_mask) >> base_shift; - cg = (cg * ca + base_mask) >> base_shift; - cb = (cb * ca + base_mask) >> base_shift; - unsigned da = p[order_type::A]; - BlenderPre::blend_pix(p, - (cr * da + base_mask) >> base_shift, - (cg * da + base_mask) >> base_shift, - (cb * da + base_mask) >> base_shift, - (ca * da + base_mask) >> base_shift, - cover); - } - }; - - //======================================comp_adaptor_clip_to_dst_rgba_pre - template struct comp_adaptor_clip_to_dst_rgba_pre - { - typedef typename BlenderPre::order_type order_type; - typedef typename BlenderPre::color_type color_type; - typedef typename color_type::value_type value_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - static AGG_INLINE void blend_pix(unsigned op, value_type* p, - unsigned cr, unsigned cg, unsigned cb, - unsigned ca, - unsigned cover) - { - unsigned da = p[order_type::A]; - BlenderPre::blend_pix(p, - (cr * da + base_mask) >> base_shift, - (cg * da + base_mask) >> base_shift, - (cb * da + base_mask) >> base_shift, - (ca * da + base_mask) >> base_shift, - cover); - } - }; - - - - - - - //===============================================copy_or_blend_rgba_wrapper - template struct copy_or_blend_rgba_wrapper - { - typedef typename Blender::color_type color_type; - typedef typename Blender::order_type order_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_scale = color_type::base_scale, - base_mask = color_type::base_mask - }; - - //-------------------------------------------------------------------- - static AGG_INLINE void copy_or_blend_pix(value_type* p, - unsigned cr, unsigned cg, unsigned cb, - unsigned alpha) - { - if(alpha) - { - if(alpha == base_mask) - { - p[order_type::R] = cr; - p[order_type::G] = cg; - p[order_type::B] = cb; - p[order_type::A] = base_mask; - } - else - { - Blender::blend_pix(p, cr, cg, cb, alpha); - } - } - } - - //-------------------------------------------------------------------- - static AGG_INLINE void copy_or_blend_pix(value_type* p, - unsigned cr, unsigned cg, unsigned cb, - unsigned alpha, - unsigned cover) - { - if(cover == 255) - { - copy_or_blend_pix(p, cr, cg, cb, alpha); - } - else - { - if(alpha) - { - alpha = (alpha * (cover + 1)) >> 8; - if(alpha == base_mask) - { - p[order_type::R] = cr; - p[order_type::G] = cg; - p[order_type::B] = cb; - p[order_type::A] = base_mask; - } - else - { - Blender::blend_pix(p, cr, cg, cb, alpha, cover); - } - } - } - } - }; - - - - - - - //=================================================pixfmt_alpha_blend_rgba - template - class pixfmt_alpha_blend_rgba - { - public: - typedef RenBuf rbuf_type; - typedef typename rbuf_type::row_data row_data; - typedef PixelT pixel_type; - typedef Blender blender_type; - typedef typename blender_type::color_type color_type; - typedef typename blender_type::order_type order_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - typedef copy_or_blend_rgba_wrapper cob_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_scale = color_type::base_scale, - base_mask = color_type::base_mask, - pix_width = sizeof(pixel_type) - }; - - //-------------------------------------------------------------------- - pixfmt_alpha_blend_rgba() : m_rbuf(0) {} - explicit pixfmt_alpha_blend_rgba(rbuf_type& rb) : m_rbuf(&rb) {} - void attach(rbuf_type& rb) { m_rbuf = &rb; } - - //-------------------------------------------------------------------- - template - bool attach(PixFmt& pixf, int x1, int y1, int x2, int y2) - { - rect_i r(x1, y1, x2, y2); - if(r.clip(rect_i(0, 0, pixf.width()-1, pixf.height()-1))) - { - int stride = pixf.stride(); - m_rbuf->attach(pixf.pix_ptr(r.x1, stride < 0 ? r.y2 : r.y1), - (r.x2 - r.x1) + 1, - (r.y2 - r.y1) + 1, - stride); - return true; - } - return false; - } - - //-------------------------------------------------------------------- - AGG_INLINE unsigned width() const { return m_rbuf->width(); } - AGG_INLINE unsigned height() const { return m_rbuf->height(); } - AGG_INLINE int stride() const { return m_rbuf->stride(); } - - //-------------------------------------------------------------------- - AGG_INLINE int8u* row_ptr(int y) { return m_rbuf->row_ptr(y); } - AGG_INLINE const int8u* row_ptr(int y) const { return m_rbuf->row_ptr(y); } - AGG_INLINE row_data row(int y) const { return m_rbuf->row(y); } - - //-------------------------------------------------------------------- - AGG_INLINE int8u* pix_ptr(int x, int y) - { - return m_rbuf->row_ptr(y) + x * pix_width; - } - - AGG_INLINE const int8u* pix_ptr(int x, int y) const - { - return m_rbuf->row_ptr(y) + x * pix_width; - } - - - //-------------------------------------------------------------------- - AGG_INLINE static void make_pix(int8u* p, const color_type& c) - { - ((value_type*)p)[order_type::R] = c.r; - ((value_type*)p)[order_type::G] = c.g; - ((value_type*)p)[order_type::B] = c.b; - ((value_type*)p)[order_type::A] = c.a; - } - - //-------------------------------------------------------------------- - AGG_INLINE color_type pixel(int x, int y) const - { - const value_type* p = (const value_type*)m_rbuf->row_ptr(y); - if(p) - { - p += x << 2; - return color_type(p[order_type::R], - p[order_type::G], - p[order_type::B], - p[order_type::A]); - } - return color_type::no_color(); - } - - //-------------------------------------------------------------------- - AGG_INLINE void copy_pixel(int x, int y, const color_type& c) - { - value_type* p = (value_type*)m_rbuf->row_ptr(x, y, 1) + (x << 2); - p[order_type::R] = c.r; - p[order_type::G] = c.g; - p[order_type::B] = c.b; - p[order_type::A] = c.a; - } - - //-------------------------------------------------------------------- - AGG_INLINE void blend_pixel(int x, int y, const color_type& c, int8u cover) - { - cob_type::copy_or_blend_pix( - (value_type*)m_rbuf->row_ptr(x, y, 1) + (x << 2), - c.r, c.g, c.b, c.a, - cover); - } - - - //-------------------------------------------------------------------- - AGG_INLINE void copy_hline(int x, int y, - unsigned len, - const color_type& c) - { - value_type* p = (value_type*)m_rbuf->row_ptr(x, y, len) + (x << 2); - pixel_type v; - ((value_type*)&v)[order_type::R] = c.r; - ((value_type*)&v)[order_type::G] = c.g; - ((value_type*)&v)[order_type::B] = c.b; - ((value_type*)&v)[order_type::A] = c.a; - do - { - *(pixel_type*)p = v; - p += 4; - } - while(--len); - } - - - //-------------------------------------------------------------------- - AGG_INLINE void copy_vline(int x, int y, - unsigned len, - const color_type& c) - { - pixel_type v; - ((value_type*)&v)[order_type::R] = c.r; - ((value_type*)&v)[order_type::G] = c.g; - ((value_type*)&v)[order_type::B] = c.b; - ((value_type*)&v)[order_type::A] = c.a; - do - { - value_type* p = (value_type*)m_rbuf->row_ptr(x, y++, 1) + (x << 2); - *(pixel_type*)p = v; - } - while(--len); - } - - - //-------------------------------------------------------------------- - void blend_hline(int x, int y, - unsigned len, - const color_type& c, - int8u cover) - { - if (c.a) - { - value_type* p = (value_type*)m_rbuf->row_ptr(x, y, len) + (x << 2); - calc_type alpha = (calc_type(c.a) * (cover + 1)) >> 8; - if(alpha == base_mask) - { - pixel_type v; - ((value_type*)&v)[order_type::R] = c.r; - ((value_type*)&v)[order_type::G] = c.g; - ((value_type*)&v)[order_type::B] = c.b; - ((value_type*)&v)[order_type::A] = c.a; - do - { - *(pixel_type*)p = v; - p += 4; - } - while(--len); - } - else - { - if(cover == 255) - { - do - { - blender_type::blend_pix(p, c.r, c.g, c.b, alpha); - p += 4; - } - while(--len); - } - else - { - do - { - blender_type::blend_pix(p, c.r, c.g, c.b, alpha, cover); - p += 4; - } - while(--len); - } - } - } - } - - - //-------------------------------------------------------------------- - void blend_vline(int x, int y, - unsigned len, - const color_type& c, - int8u cover) - { - if (c.a) - { - value_type* p; - calc_type alpha = (calc_type(c.a) * (cover + 1)) >> 8; - if(alpha == base_mask) - { - pixel_type v; - ((value_type*)&v)[order_type::R] = c.r; - ((value_type*)&v)[order_type::G] = c.g; - ((value_type*)&v)[order_type::B] = c.b; - ((value_type*)&v)[order_type::A] = c.a; - do - { - p = (value_type*)m_rbuf->row_ptr(x, y++, 1) + (x << 2); - *(pixel_type*)p = v; - } - while(--len); - } - else - { - if(cover == 255) - { - do - { - p = (value_type*)m_rbuf->row_ptr(x, y++, 1) + (x << 2); - blender_type::blend_pix(p, c.r, c.g, c.b, alpha); - } - while(--len); - } - else - { - do - { - p = (value_type*)m_rbuf->row_ptr(x, y++, 1) + (x << 2); - blender_type::blend_pix(p, c.r, c.g, c.b, alpha, cover); - } - while(--len); - } - } - } - } - - - //-------------------------------------------------------------------- - void blend_solid_hspan(int x, int y, - unsigned len, - const color_type& c, - const int8u* covers) - { - if (c.a) - { - value_type* p = (value_type*)m_rbuf->row_ptr(x, y, len) + (x << 2); - do - { - calc_type alpha = (calc_type(c.a) * (calc_type(*covers) + 1)) >> 8; - if(alpha == base_mask) - { - p[order_type::R] = c.r; - p[order_type::G] = c.g; - p[order_type::B] = c.b; - p[order_type::A] = base_mask; - } - else - { - blender_type::blend_pix(p, c.r, c.g, c.b, alpha, *covers); - } - p += 4; - ++covers; - } - while(--len); - } - } - - - //-------------------------------------------------------------------- - void blend_solid_vspan(int x, int y, - unsigned len, - const color_type& c, - const int8u* covers) - { - if (c.a) - { - do - { - value_type* p = (value_type*)m_rbuf->row_ptr(x, y++, 1) + (x << 2); - calc_type alpha = (calc_type(c.a) * (calc_type(*covers) + 1)) >> 8; - if(alpha == base_mask) - { - p[order_type::R] = c.r; - p[order_type::G] = c.g; - p[order_type::B] = c.b; - p[order_type::A] = base_mask; - } - else - { - blender_type::blend_pix(p, c.r, c.g, c.b, alpha, *covers); - } - ++covers; - } - while(--len); - } - } - - - //-------------------------------------------------------------------- - void copy_color_hspan(int x, int y, - unsigned len, - const color_type* colors) - { - value_type* p = (value_type*)m_rbuf->row_ptr(x, y, len) + (x << 2); - do - { - p[order_type::R] = colors->r; - p[order_type::G] = colors->g; - p[order_type::B] = colors->b; - p[order_type::A] = colors->a; - ++colors; - p += 4; - } - while(--len); - } - - - //-------------------------------------------------------------------- - void copy_color_vspan(int x, int y, - unsigned len, - const color_type* colors) - { - do - { - value_type* p = (value_type*)m_rbuf->row_ptr(x, y++, 1) + (x << 2); - p[order_type::R] = colors->r; - p[order_type::G] = colors->g; - p[order_type::B] = colors->b; - p[order_type::A] = colors->a; - ++colors; - } - while(--len); - } - - - //-------------------------------------------------------------------- - void blend_color_hspan(int x, int y, - unsigned len, - const color_type* colors, - const int8u* covers, - int8u cover) - { - value_type* p = (value_type*)m_rbuf->row_ptr(x, y, len) + (x << 2); - if(covers) - { - do - { - cob_type::copy_or_blend_pix(p, - colors->r, - colors->g, - colors->b, - colors->a, - *covers++); - p += 4; - ++colors; - } - while(--len); - } - else - { - if(cover == 255) - { - do - { - cob_type::copy_or_blend_pix(p, - colors->r, - colors->g, - colors->b, - colors->a); - p += 4; - ++colors; - } - while(--len); - } - else - { - do - { - cob_type::copy_or_blend_pix(p, - colors->r, - colors->g, - colors->b, - colors->a, - cover); - p += 4; - ++colors; - } - while(--len); - } - } - } - - - - //-------------------------------------------------------------------- - void blend_color_vspan(int x, int y, - unsigned len, - const color_type* colors, - const int8u* covers, - int8u cover) - { - value_type* p; - if(covers) - { - do - { - p = (value_type*)m_rbuf->row_ptr(x, y++, 1) + (x << 2); - cob_type::copy_or_blend_pix(p, - colors->r, - colors->g, - colors->b, - colors->a, - *covers++); - ++colors; - } - while(--len); - } - else - { - if(cover == 255) - { - do - { - p = (value_type*)m_rbuf->row_ptr(x, y++, 1) + (x << 2); - cob_type::copy_or_blend_pix(p, - colors->r, - colors->g, - colors->b, - colors->a); - ++colors; - } - while(--len); - } - else - { - do - { - p = (value_type*)m_rbuf->row_ptr(x, y++, 1) + (x << 2); - cob_type::copy_or_blend_pix(p, - colors->r, - colors->g, - colors->b, - colors->a, - cover); - ++colors; - } - while(--len); - } - } - } - - //-------------------------------------------------------------------- - template void for_each_pixel(Function f) - { - unsigned y; - for(y = 0; y < height(); ++y) - { - row_data r = m_rbuf->row(y); - if(r.ptr) - { - unsigned len = r.x2 - r.x1 + 1; - value_type* p = - (value_type*)m_rbuf->row_ptr(r.x1, y, len) + (r.x1 << 2); - do - { - f(p); - p += 4; - } - while(--len); - } - } - } - - //-------------------------------------------------------------------- - void premultiply() - { - for_each_pixel(multiplier_rgba::premultiply); - } - - //-------------------------------------------------------------------- - void demultiply() - { - for_each_pixel(multiplier_rgba::demultiply); - } - - //-------------------------------------------------------------------- - template void apply_gamma_dir(const GammaLut& g) - { - for_each_pixel(apply_gamma_dir_rgba(g)); - } - - //-------------------------------------------------------------------- - template void apply_gamma_inv(const GammaLut& g) - { - for_each_pixel(apply_gamma_inv_rgba(g)); - } - - //-------------------------------------------------------------------- - template void copy_from(const RenBuf2& from, - int xdst, int ydst, - int xsrc, int ysrc, - unsigned len) - { - const int8u* p = from.row_ptr(ysrc); - if(p) - { - memmove(m_rbuf->row_ptr(xdst, ydst, len) + xdst * pix_width, - p + xsrc * pix_width, - len * pix_width); - } - } - - //-------------------------------------------------------------------- - template - void blend_from(const SrcPixelFormatRenderer& from, - int xdst, int ydst, - int xsrc, int ysrc, - unsigned len, - int8u cover) - { - typedef typename SrcPixelFormatRenderer::order_type src_order; - const value_type* psrc = (value_type*)from.row_ptr(ysrc); - if(psrc) - { - psrc += xsrc << 2; - value_type* pdst = - (value_type*)m_rbuf->row_ptr(xdst, ydst, len) + (xdst << 2); - int incp = 4; - if(xdst > xsrc) - { - psrc += (len-1) << 2; - pdst += (len-1) << 2; - incp = -4; - } - - if(cover == 255) - { - do - { - cob_type::copy_or_blend_pix(pdst, - psrc[src_order::R], - psrc[src_order::G], - psrc[src_order::B], - psrc[src_order::A]); - psrc += incp; - pdst += incp; - } - while(--len); - } - else - { - do - { - cob_type::copy_or_blend_pix(pdst, - psrc[src_order::R], - psrc[src_order::G], - psrc[src_order::B], - psrc[src_order::A], - cover); - psrc += incp; - pdst += incp; - } - while(--len); - } - } - } - - //-------------------------------------------------------------------- - template - void blend_from_color(const SrcPixelFormatRenderer& from, - const color_type& color, - int xdst, int ydst, - int xsrc, int ysrc, - unsigned len, - int8u cover) - { - typedef typename SrcPixelFormatRenderer::value_type src_value_type; - const src_value_type* psrc = (src_value_type*)from.row_ptr(ysrc); - if(psrc) - { - value_type* pdst = - (value_type*)m_rbuf->row_ptr(xdst, ydst, len) + (xdst << 2); - do - { - cob_type::copy_or_blend_pix(pdst, - color.r, color.g, color.b, color.a, - (*psrc * cover + base_mask) >> base_shift); - ++psrc; - pdst += 4; - } - while(--len); - } - } - - //-------------------------------------------------------------------- - template - void blend_from_lut(const SrcPixelFormatRenderer& from, - const color_type* color_lut, - int xdst, int ydst, - int xsrc, int ysrc, - unsigned len, - int8u cover) - { - typedef typename SrcPixelFormatRenderer::value_type src_value_type; - const src_value_type* psrc = (src_value_type*)from.row_ptr(ysrc); - if(psrc) - { - value_type* pdst = - (value_type*)m_rbuf->row_ptr(xdst, ydst, len) + (xdst << 2); - - if(cover == 255) - { - do - { - const color_type& color = color_lut[*psrc]; - cob_type::copy_or_blend_pix(pdst, - color.r, color.g, color.b, color.a); - ++psrc; - pdst += 4; - } - while(--len); - } - else - { - do - { - const color_type& color = color_lut[*psrc]; - cob_type::copy_or_blend_pix(pdst, - color.r, color.g, color.b, color.a, - cover); - ++psrc; - pdst += 4; - } - while(--len); - } - } - } - - private: - rbuf_type* m_rbuf; - }; - - - - - //================================================pixfmt_custom_blend_rgba - template class pixfmt_custom_blend_rgba - { - public: - typedef RenBuf rbuf_type; - typedef typename rbuf_type::row_data row_data; - typedef Blender blender_type; - typedef typename blender_type::color_type color_type; - typedef typename blender_type::order_type order_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_scale = color_type::base_scale, - base_mask = color_type::base_mask, - pix_width = sizeof(value_type) * 4 - }; - - - //-------------------------------------------------------------------- - pixfmt_custom_blend_rgba() : m_rbuf(0), m_comp_op(3) {} - explicit pixfmt_custom_blend_rgba(rbuf_type& rb, unsigned comp_op=3) : - m_rbuf(&rb), - m_comp_op(comp_op) - {} - void attach(rbuf_type& rb) { m_rbuf = &rb; } - - //-------------------------------------------------------------------- - template - bool attach(PixFmt& pixf, int x1, int y1, int x2, int y2) - { - rect_i r(x1, y1, x2, y2); - if(r.clip(rect_i(0, 0, pixf.width()-1, pixf.height()-1))) - { - int stride = pixf.stride(); - m_rbuf->attach(pixf.pix_ptr(r.x1, stride < 0 ? r.y2 : r.y1), - (r.x2 - r.x1) + 1, - (r.y2 - r.y1) + 1, - stride); - return true; - } - return false; - } - - //-------------------------------------------------------------------- - AGG_INLINE unsigned width() const { return m_rbuf->width(); } - AGG_INLINE unsigned height() const { return m_rbuf->height(); } - AGG_INLINE int stride() const { return m_rbuf->stride(); } - - //-------------------------------------------------------------------- - AGG_INLINE int8u* row_ptr(int y) { return m_rbuf->row_ptr(y); } - AGG_INLINE const int8u* row_ptr(int y) const { return m_rbuf->row_ptr(y); } - AGG_INLINE row_data row(int y) const { return m_rbuf->row(y); } - - //-------------------------------------------------------------------- - AGG_INLINE int8u* pix_ptr(int x, int y) - { - return m_rbuf->row_ptr(y) + x * pix_width; - } - - AGG_INLINE const int8u* pix_ptr(int x, int y) const - { - return m_rbuf->row_ptr(y) + x * pix_width; - } - - //-------------------------------------------------------------------- - void comp_op(unsigned op) { m_comp_op = op; } - unsigned comp_op() const { return m_comp_op; } - - //-------------------------------------------------------------------- - AGG_INLINE static void make_pix(int8u* p, const color_type& c) - { - ((value_type*)p)[order_type::R] = c.r; - ((value_type*)p)[order_type::G] = c.g; - ((value_type*)p)[order_type::B] = c.b; - ((value_type*)p)[order_type::A] = c.a; - } - - //-------------------------------------------------------------------- - color_type pixel(int x, int y) const - { - const value_type* p = (value_type*)m_rbuf->row_ptr(y) + (x << 2); - return color_type(p[order_type::R], - p[order_type::G], - p[order_type::B], - p[order_type::A]); - } - - //-------------------------------------------------------------------- - void copy_pixel(int x, int y, const color_type& c) - { - blender_type::blend_pix( - m_comp_op, - (value_type*)m_rbuf->row_ptr(x, y, 1) + (x << 2), - c.r, c.g, c.b, c.a, 255); - } - - //-------------------------------------------------------------------- - void blend_pixel(int x, int y, const color_type& c, int8u cover) - { - blender_type::blend_pix( - m_comp_op, - (value_type*)m_rbuf->row_ptr(x, y, 1) + (x << 2), - c.r, c.g, c.b, c.a, - cover); - } - - //-------------------------------------------------------------------- - void copy_hline(int x, int y, unsigned len, const color_type& c) - { - value_type* p = (value_type*)m_rbuf->row_ptr(x, y, len) + (x << 2);; - do - { - blender_type::blend_pix(m_comp_op, p, c.r, c.g, c.b, c.a, 255); - p += 4; - } - while(--len); - } - - //-------------------------------------------------------------------- - void copy_vline(int x, int y, unsigned len, const color_type& c) - { - do - { - blender_type::blend_pix( - m_comp_op, - (value_type*)m_rbuf->row_ptr(x, y++, 1) + (x << 2), - c.r, c.g, c.b, c.a, 255); - } - while(--len); - } - - //-------------------------------------------------------------------- - void blend_hline(int x, int y, unsigned len, - const color_type& c, int8u cover) - { - - value_type* p = (value_type*)m_rbuf->row_ptr(x, y, len) + (x << 2); - do - { - blender_type::blend_pix(m_comp_op, p, c.r, c.g, c.b, c.a, cover); - p += 4; - } - while(--len); - } - - //-------------------------------------------------------------------- - void blend_vline(int x, int y, unsigned len, - const color_type& c, int8u cover) - { - - do - { - blender_type::blend_pix( - m_comp_op, - (value_type*)m_rbuf->row_ptr(x, y++, 1) + (x << 2), - c.r, c.g, c.b, c.a, - cover); - } - while(--len); - } - - //-------------------------------------------------------------------- - void blend_solid_hspan(int x, int y, unsigned len, - const color_type& c, const int8u* covers) - { - value_type* p = (value_type*)m_rbuf->row_ptr(x, y, len) + (x << 2); - do - { - blender_type::blend_pix(m_comp_op, - p, c.r, c.g, c.b, c.a, - *covers++); - p += 4; - } - while(--len); - } - - //-------------------------------------------------------------------- - void blend_solid_vspan(int x, int y, unsigned len, - const color_type& c, const int8u* covers) - { - do - { - blender_type::blend_pix( - m_comp_op, - (value_type*)m_rbuf->row_ptr(x, y++, 1) + (x << 2), - c.r, c.g, c.b, c.a, - *covers++); - } - while(--len); - } - - //-------------------------------------------------------------------- - void copy_color_hspan(int x, int y, - unsigned len, - const color_type* colors) - { - - value_type* p = (value_type*)m_rbuf->row_ptr(x, y, len) + (x << 2); - do - { - p[order_type::R] = colors->r; - p[order_type::G] = colors->g; - p[order_type::B] = colors->b; - p[order_type::A] = colors->a; - ++colors; - p += 4; - } - while(--len); - } - - //-------------------------------------------------------------------- - void copy_color_vspan(int x, int y, - unsigned len, - const color_type* colors) - { - do - { - value_type* p = (value_type*)m_rbuf->row_ptr(x, y++, 1) + (x << 2); - p[order_type::R] = colors->r; - p[order_type::G] = colors->g; - p[order_type::B] = colors->b; - p[order_type::A] = colors->a; - ++colors; - } - while(--len); - } - - //-------------------------------------------------------------------- - void blend_color_hspan(int x, int y, unsigned len, - const color_type* colors, - const int8u* covers, - int8u cover) - { - value_type* p = (value_type*)m_rbuf->row_ptr(x, y, len) + (x << 2); - do - { - blender_type::blend_pix(m_comp_op, - p, - colors->r, - colors->g, - colors->b, - colors->a, - covers ? *covers++ : cover); - p += 4; - ++colors; - } - while(--len); - } - - //-------------------------------------------------------------------- - void blend_color_vspan(int x, int y, unsigned len, - const color_type* colors, - const int8u* covers, - int8u cover) - { - do - { - blender_type::blend_pix( - m_comp_op, - (value_type*)m_rbuf->row_ptr(x, y++, 1) + (x << 2), - colors->r, - colors->g, - colors->b, - colors->a, - covers ? *covers++ : cover); - ++colors; - } - while(--len); - - } - - //-------------------------------------------------------------------- - template void for_each_pixel(Function f) - { - unsigned y; - for(y = 0; y < height(); ++y) - { - row_data r = m_rbuf->row(y); - if(r.ptr) - { - unsigned len = r.x2 - r.x1 + 1; - value_type* p = - (value_type*)m_rbuf->row_ptr(r.x1, y, len) + (r.x1 << 2); - do - { - f(p); - p += 4; - } - while(--len); - } - } - } - - //-------------------------------------------------------------------- - void premultiply() - { - for_each_pixel(multiplier_rgba::premultiply); - } - - //-------------------------------------------------------------------- - void demultiply() - { - for_each_pixel(multiplier_rgba::demultiply); - } - - //-------------------------------------------------------------------- - template void apply_gamma_dir(const GammaLut& g) - { - for_each_pixel(apply_gamma_dir_rgba(g)); - } - - //-------------------------------------------------------------------- - template void apply_gamma_inv(const GammaLut& g) - { - for_each_pixel(apply_gamma_inv_rgba(g)); - } - - //-------------------------------------------------------------------- - template void copy_from(const RenBuf2& from, - int xdst, int ydst, - int xsrc, int ysrc, - unsigned len) - { - const int8u* p = from.row_ptr(ysrc); - if(p) - { - memmove(m_rbuf->row_ptr(xdst, ydst, len) + xdst * pix_width, - p + xsrc * pix_width, - len * pix_width); - } - } - - //-------------------------------------------------------------------- - template - void blend_from(const SrcPixelFormatRenderer& from, - int xdst, int ydst, - int xsrc, int ysrc, - unsigned len, - int8u cover) - { - typedef typename SrcPixelFormatRenderer::order_type src_order; - const value_type* psrc = (const value_type*)from.row_ptr(ysrc); - if(psrc) - { - psrc += xsrc << 2; - value_type* pdst = - (value_type*)m_rbuf->row_ptr(xdst, ydst, len) + (xdst << 2); - - int incp = 4; - if(xdst > xsrc) - { - psrc += (len-1) << 2; - pdst += (len-1) << 2; - incp = -4; - } - - do - { - blender_type::blend_pix(m_comp_op, - pdst, - psrc[src_order::R], - psrc[src_order::G], - psrc[src_order::B], - psrc[src_order::A], - cover); - psrc += incp; - pdst += incp; - } - while(--len); - } - } - - //-------------------------------------------------------------------- - template - void blend_from_color(const SrcPixelFormatRenderer& from, - const color_type& color, - int xdst, int ydst, - int xsrc, int ysrc, - unsigned len, - int8u cover) - { - typedef typename SrcPixelFormatRenderer::value_type src_value_type; - const src_value_type* psrc = (src_value_type*)from.row_ptr(ysrc); - if(psrc) - { - value_type* pdst = - (value_type*)m_rbuf->row_ptr(xdst, ydst, len) + (xdst << 2); - do - { - blender_type::blend_pix(m_comp_op, - pdst, - color.r, color.g, color.b, color.a, - (*psrc * cover + base_mask) >> base_shift); - ++psrc; - pdst += 4; - } - while(--len); - } - } - - //-------------------------------------------------------------------- - template - void blend_from_lut(const SrcPixelFormatRenderer& from, - const color_type* color_lut, - int xdst, int ydst, - int xsrc, int ysrc, - unsigned len, - int8u cover) - { - typedef typename SrcPixelFormatRenderer::value_type src_value_type; - const src_value_type* psrc = (src_value_type*)from.row_ptr(ysrc); - if(psrc) - { - value_type* pdst = - (value_type*)m_rbuf->row_ptr(xdst, ydst, len) + (xdst << 2); - do - { - const color_type& color = color_lut[*psrc]; - blender_type::blend_pix(m_comp_op, - pdst, - color.r, color.g, color.b, color.a, - cover); - ++psrc; - pdst += 4; - } - while(--len); - } - } - - private: - rbuf_type* m_rbuf; - unsigned m_comp_op; - }; - - - - - //----------------------------------------------------------------------- - typedef blender_rgba blender_rgba32; //----blender_rgba32 - typedef blender_rgba blender_argb32; //----blender_argb32 - typedef blender_rgba blender_abgr32; //----blender_abgr32 - typedef blender_rgba blender_bgra32; //----blender_bgra32 - - typedef blender_rgba_pre blender_rgba32_pre; //----blender_rgba32_pre - typedef blender_rgba_pre blender_argb32_pre; //----blender_argb32_pre - typedef blender_rgba_pre blender_abgr32_pre; //----blender_abgr32_pre - typedef blender_rgba_pre blender_bgra32_pre; //----blender_bgra32_pre - - typedef blender_rgba_plain blender_rgba32_plain; //----blender_rgba32_plain - typedef blender_rgba_plain blender_argb32_plain; //----blender_argb32_plain - typedef blender_rgba_plain blender_abgr32_plain; //----blender_abgr32_plain - typedef blender_rgba_plain blender_bgra32_plain; //----blender_bgra32_plain - - typedef blender_rgba blender_rgba64; //----blender_rgba64 - typedef blender_rgba blender_argb64; //----blender_argb64 - typedef blender_rgba blender_abgr64; //----blender_abgr64 - typedef blender_rgba blender_bgra64; //----blender_bgra64 - - typedef blender_rgba_pre blender_rgba64_pre; //----blender_rgba64_pre - typedef blender_rgba_pre blender_argb64_pre; //----blender_argb64_pre - typedef blender_rgba_pre blender_abgr64_pre; //----blender_abgr64_pre - typedef blender_rgba_pre blender_bgra64_pre; //----blender_bgra64_pre - - - //----------------------------------------------------------------------- - typedef int32u pixel32_type; - typedef pixfmt_alpha_blend_rgba pixfmt_rgba32; //----pixfmt_rgba32 - typedef pixfmt_alpha_blend_rgba pixfmt_argb32; //----pixfmt_argb32 - typedef pixfmt_alpha_blend_rgba pixfmt_abgr32; //----pixfmt_abgr32 - typedef pixfmt_alpha_blend_rgba pixfmt_bgra32; //----pixfmt_bgra32 - - typedef pixfmt_alpha_blend_rgba pixfmt_rgba32_pre; //----pixfmt_rgba32_pre - typedef pixfmt_alpha_blend_rgba pixfmt_argb32_pre; //----pixfmt_argb32_pre - typedef pixfmt_alpha_blend_rgba pixfmt_abgr32_pre; //----pixfmt_abgr32_pre - typedef pixfmt_alpha_blend_rgba pixfmt_bgra32_pre; //----pixfmt_bgra32_pre - - typedef pixfmt_alpha_blend_rgba pixfmt_rgba32_plain; //----pixfmt_rgba32_plain - typedef pixfmt_alpha_blend_rgba pixfmt_argb32_plain; //----pixfmt_argb32_plain - typedef pixfmt_alpha_blend_rgba pixfmt_abgr32_plain; //----pixfmt_abgr32_plain - typedef pixfmt_alpha_blend_rgba pixfmt_bgra32_plain; //----pixfmt_bgra32_plain - - struct pixel64_type { int16u c[4]; }; - typedef pixfmt_alpha_blend_rgba pixfmt_rgba64; //----pixfmt_rgba64 - typedef pixfmt_alpha_blend_rgba pixfmt_argb64; //----pixfmt_argb64 - typedef pixfmt_alpha_blend_rgba pixfmt_abgr64; //----pixfmt_abgr64 - typedef pixfmt_alpha_blend_rgba pixfmt_bgra64; //----pixfmt_bgra64 - - typedef pixfmt_alpha_blend_rgba pixfmt_rgba64_pre; //----pixfmt_rgba64_pre - typedef pixfmt_alpha_blend_rgba pixfmt_argb64_pre; //----pixfmt_argb64_pre - typedef pixfmt_alpha_blend_rgba pixfmt_abgr64_pre; //----pixfmt_abgr64_pre - typedef pixfmt_alpha_blend_rgba pixfmt_bgra64_pre; //----pixfmt_bgra64_pre -} - -#endif - diff --git a/desmume/src/windows/agg/include/agg_pixfmt_transposer.h b/desmume/src/windows/agg/include/agg_pixfmt_transposer.h deleted file mode 100644 index c5038d49f..000000000 --- a/desmume/src/windows/agg/include/agg_pixfmt_transposer.h +++ /dev/null @@ -1,166 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_PIXFMT_TRANSPOSER_INCLUDED -#define AGG_PIXFMT_TRANSPOSER_INCLUDED - -#include "agg_basics.h" - -namespace agg -{ - //=======================================================pixfmt_transposer - template class pixfmt_transposer - { - public: - typedef PixFmt pixfmt_type; - typedef typename pixfmt_type::color_type color_type; - typedef typename pixfmt_type::row_data row_data; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - - //-------------------------------------------------------------------- - pixfmt_transposer() : m_pixf(0) {} - explicit pixfmt_transposer(pixfmt_type& pixf) : m_pixf(&pixf) {} - void attach(pixfmt_type& pixf) { m_pixf = &pixf; } - - //-------------------------------------------------------------------- - AGG_INLINE unsigned width() const { return m_pixf->height(); } - AGG_INLINE unsigned height() const { return m_pixf->width(); } - - //-------------------------------------------------------------------- - AGG_INLINE color_type pixel(int x, int y) const - { - return m_pixf->pixel(y, x); - } - - //-------------------------------------------------------------------- - AGG_INLINE void copy_pixel(int x, int y, const color_type& c) - { - m_pixf->copy_pixel(y, x, c); - } - - //-------------------------------------------------------------------- - AGG_INLINE void blend_pixel(int x, int y, - const color_type& c, - int8u cover) - { - m_pixf->blend_pixel(y, x, c, cover); - } - - //-------------------------------------------------------------------- - AGG_INLINE void copy_hline(int x, int y, - unsigned len, - const color_type& c) - { - m_pixf->copy_vline(y, x, len, c); - } - - //-------------------------------------------------------------------- - AGG_INLINE void copy_vline(int x, int y, - unsigned len, - const color_type& c) - { - m_pixf->copy_hline(y, x, len, c); - } - - //-------------------------------------------------------------------- - AGG_INLINE void blend_hline(int x, int y, - unsigned len, - const color_type& c, - int8u cover) - { - m_pixf->blend_vline(y, x, len, c, cover); - } - - //-------------------------------------------------------------------- - AGG_INLINE void blend_vline(int x, int y, - unsigned len, - const color_type& c, - int8u cover) - { - m_pixf->blend_hline(y, x, len, c, cover); - } - - //-------------------------------------------------------------------- - AGG_INLINE void blend_solid_hspan(int x, int y, - unsigned len, - const color_type& c, - const int8u* covers) - { - m_pixf->blend_solid_vspan(y, x, len, c, covers); - } - - //-------------------------------------------------------------------- - AGG_INLINE void blend_solid_vspan(int x, int y, - unsigned len, - const color_type& c, - const int8u* covers) - { - m_pixf->blend_solid_hspan(y, x, len, c, covers); - } - - //-------------------------------------------------------------------- - AGG_INLINE void copy_color_hspan(int x, int y, - unsigned len, - const color_type* colors) - { - m_pixf->copy_color_vspan(y, x, len, colors); - } - - //-------------------------------------------------------------------- - AGG_INLINE void copy_color_vspan(int x, int y, - unsigned len, - const color_type* colors) - { - m_pixf->copy_color_hspan(y, x, len, colors); - } - - //-------------------------------------------------------------------- - AGG_INLINE void blend_color_hspan(int x, int y, - unsigned len, - const color_type* colors, - const int8u* covers, - int8u cover) - { - m_pixf->blend_color_vspan(y, x, len, colors, covers, cover); - } - - //-------------------------------------------------------------------- - AGG_INLINE void blend_color_vspan(int x, int y, - unsigned len, - const color_type* colors, - const int8u* covers, - int8u cover) - { - m_pixf->blend_color_hspan(y, x, len, colors, covers, cover); - } - - private: - pixfmt_type* m_pixf; - }; -} - -#endif - - diff --git a/desmume/src/windows/agg/include/agg_rasterizer_cells_aa.h b/desmume/src/windows/agg/include/agg_rasterizer_cells_aa.h deleted file mode 100644 index 789f2b787..000000000 --- a/desmume/src/windows/agg/include/agg_rasterizer_cells_aa.h +++ /dev/null @@ -1,764 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- -// -// The author gratefully acknowleges the support of David Turner, -// Robert Wilhelm, and Werner Lemberg - the authors of the FreeType -// libray - in producing this work. See http://www.freetype.org for details. -// -//---------------------------------------------------------------------------- -// -// Adaptation for 32-bit screen coordinates has been sponsored by -// Liberty Technology Systems, Inc., visit http://lib-sys.com -// -// Liberty Technology Systems, Inc. is the provider of -// PostScript and PDF technology for software developers. -// -//---------------------------------------------------------------------------- - -#ifndef AGG_RASTERIZER_CELLS_AA_INCLUDED -#define AGG_RASTERIZER_CELLS_AA_INCLUDED - -#include -#include -#include "agg_math.h" -#include "agg_array.h" - - -namespace agg -{ - - //-----------------------------------------------------rasterizer_cells_aa - // An internal class that implements the main rasterization algorithm. - // Used in the rasterizer. Should not be used direcly. - template class rasterizer_cells_aa - { - enum cell_block_scale_e - { - cell_block_shift = 12, - cell_block_size = 1 << cell_block_shift, - cell_block_mask = cell_block_size - 1, - cell_block_pool = 256, - cell_block_limit = 1024 - }; - - struct sorted_y - { - unsigned start; - unsigned num; - }; - - public: - typedef Cell cell_type; - typedef rasterizer_cells_aa self_type; - - ~rasterizer_cells_aa(); - rasterizer_cells_aa(); - - void reset(); - void style(const cell_type& style_cell); - void line(int x1, int y1, int x2, int y2); - - int min_x() const { return m_min_x; } - int min_y() const { return m_min_y; } - int max_x() const { return m_max_x; } - int max_y() const { return m_max_y; } - - void sort_cells(); - - unsigned total_cells() const - { - return m_num_cells; - } - - unsigned scanline_num_cells(unsigned y) const - { - return m_sorted_y[y - m_min_y].num; - } - - const cell_type* const* scanline_cells(unsigned y) const - { - return m_sorted_cells.data() + m_sorted_y[y - m_min_y].start; - } - - bool sorted() const { return m_sorted; } - - private: - rasterizer_cells_aa(const self_type&); - const self_type& operator = (const self_type&); - - void set_curr_cell(int x, int y); - void add_curr_cell(); - void render_hline(int ey, int x1, int y1, int x2, int y2); - void allocate_block(); - - private: - unsigned m_num_blocks; - unsigned m_max_blocks; - unsigned m_curr_block; - unsigned m_num_cells; - cell_type** m_cells; - cell_type* m_curr_cell_ptr; - pod_vector m_sorted_cells; - pod_vector m_sorted_y; - cell_type m_curr_cell; - cell_type m_style_cell; - int m_min_x; - int m_min_y; - int m_max_x; - int m_max_y; - bool m_sorted; - }; - - - - - //------------------------------------------------------------------------ - template - rasterizer_cells_aa::~rasterizer_cells_aa() - { - if(m_num_blocks) - { - cell_type** ptr = m_cells + m_num_blocks - 1; - while(m_num_blocks--) - { - pod_allocator::deallocate(*ptr, cell_block_size); - ptr--; - } - pod_allocator::deallocate(m_cells, m_max_blocks); - } - } - - //------------------------------------------------------------------------ - template - rasterizer_cells_aa::rasterizer_cells_aa() : - m_num_blocks(0), - m_max_blocks(0), - m_curr_block(0), - m_num_cells(0), - m_cells(0), - m_curr_cell_ptr(0), - m_sorted_cells(), - m_sorted_y(), - m_min_x(0x7FFFFFFF), - m_min_y(0x7FFFFFFF), - m_max_x(-0x7FFFFFFF), - m_max_y(-0x7FFFFFFF), - m_sorted(false) - { - m_style_cell.initial(); - m_curr_cell.initial(); - } - - //------------------------------------------------------------------------ - template - void rasterizer_cells_aa::reset() - { - m_num_cells = 0; - m_curr_block = 0; - m_curr_cell.initial(); - m_style_cell.initial(); - m_sorted = false; - m_min_x = 0x7FFFFFFF; - m_min_y = 0x7FFFFFFF; - m_max_x = -0x7FFFFFFF; - m_max_y = -0x7FFFFFFF; - } - - //------------------------------------------------------------------------ - template - AGG_INLINE void rasterizer_cells_aa::add_curr_cell() - { - if(m_curr_cell.area | m_curr_cell.cover) - { - if((m_num_cells & cell_block_mask) == 0) - { - if(m_num_blocks >= cell_block_limit) return; - allocate_block(); - } - *m_curr_cell_ptr++ = m_curr_cell; - ++m_num_cells; - } - } - - //------------------------------------------------------------------------ - template - AGG_INLINE void rasterizer_cells_aa::set_curr_cell(int x, int y) - { - if(m_curr_cell.not_equal(x, y, m_style_cell)) - { - add_curr_cell(); - m_curr_cell.style(m_style_cell); - m_curr_cell.x = x; - m_curr_cell.y = y; - m_curr_cell.cover = 0; - m_curr_cell.area = 0; - } - } - - //------------------------------------------------------------------------ - template - AGG_INLINE void rasterizer_cells_aa::render_hline(int ey, - int x1, int y1, - int x2, int y2) - { - int ex1 = x1 >> poly_subpixel_shift; - int ex2 = x2 >> poly_subpixel_shift; - int fx1 = x1 & poly_subpixel_mask; - int fx2 = x2 & poly_subpixel_mask; - - int delta, p, first, dx; - int incr, lift, mod, rem; - - //trivial case. Happens often - if(y1 == y2) - { - set_curr_cell(ex2, ey); - return; - } - - //everything is located in a single cell. That is easy! - if(ex1 == ex2) - { - delta = y2 - y1; - m_curr_cell.cover += delta; - m_curr_cell.area += (fx1 + fx2) * delta; - return; - } - - //ok, we'll have to render a run of adjacent cells on the same - //hline... - p = (poly_subpixel_scale - fx1) * (y2 - y1); - first = poly_subpixel_scale; - incr = 1; - - dx = x2 - x1; - - if(dx < 0) - { - p = fx1 * (y2 - y1); - first = 0; - incr = -1; - dx = -dx; - } - - delta = p / dx; - mod = p % dx; - - if(mod < 0) - { - delta--; - mod += dx; - } - - m_curr_cell.cover += delta; - m_curr_cell.area += (fx1 + first) * delta; - - ex1 += incr; - set_curr_cell(ex1, ey); - y1 += delta; - - if(ex1 != ex2) - { - p = poly_subpixel_scale * (y2 - y1 + delta); - lift = p / dx; - rem = p % dx; - - if (rem < 0) - { - lift--; - rem += dx; - } - - mod -= dx; - - while (ex1 != ex2) - { - delta = lift; - mod += rem; - if(mod >= 0) - { - mod -= dx; - delta++; - } - - m_curr_cell.cover += delta; - m_curr_cell.area += poly_subpixel_scale * delta; - y1 += delta; - ex1 += incr; - set_curr_cell(ex1, ey); - } - } - delta = y2 - y1; - m_curr_cell.cover += delta; - m_curr_cell.area += (fx2 + poly_subpixel_scale - first) * delta; - } - - //------------------------------------------------------------------------ - template - AGG_INLINE void rasterizer_cells_aa::style(const cell_type& style_cell) - { - m_style_cell.style(style_cell); - } - - //------------------------------------------------------------------------ - template - void rasterizer_cells_aa::line(int x1, int y1, int x2, int y2) - { - enum dx_limit_e { dx_limit = 16384 << poly_subpixel_shift }; - - int dx = x2 - x1; - - if(dx >= dx_limit || dx <= -dx_limit) - { - int cx = (x1 + x2) >> 1; - int cy = (y1 + y2) >> 1; - line(x1, y1, cx, cy); - line(cx, cy, x2, y2); - } - - int dy = y2 - y1; - int ex1 = x1 >> poly_subpixel_shift; - int ex2 = x2 >> poly_subpixel_shift; - int ey1 = y1 >> poly_subpixel_shift; - int ey2 = y2 >> poly_subpixel_shift; - int fy1 = y1 & poly_subpixel_mask; - int fy2 = y2 & poly_subpixel_mask; - - int x_from, x_to; - int p, rem, mod, lift, delta, first, incr; - - if(ex1 < m_min_x) m_min_x = ex1; - if(ex1 > m_max_x) m_max_x = ex1; - if(ey1 < m_min_y) m_min_y = ey1; - if(ey1 > m_max_y) m_max_y = ey1; - if(ex2 < m_min_x) m_min_x = ex2; - if(ex2 > m_max_x) m_max_x = ex2; - if(ey2 < m_min_y) m_min_y = ey2; - if(ey2 > m_max_y) m_max_y = ey2; - - set_curr_cell(ex1, ey1); - - //everything is on a single hline - if(ey1 == ey2) - { - render_hline(ey1, x1, fy1, x2, fy2); - return; - } - - //Vertical line - we have to calculate start and end cells, - //and then - the common values of the area and coverage for - //all cells of the line. We know exactly there's only one - //cell, so, we don't have to call render_hline(). - incr = 1; - if(dx == 0) - { - int ex = x1 >> poly_subpixel_shift; - int two_fx = (x1 - (ex << poly_subpixel_shift)) << 1; - int area; - - first = poly_subpixel_scale; - if(dy < 0) - { - first = 0; - incr = -1; - } - - x_from = x1; - - //render_hline(ey1, x_from, fy1, x_from, first); - delta = first - fy1; - m_curr_cell.cover += delta; - m_curr_cell.area += two_fx * delta; - - ey1 += incr; - set_curr_cell(ex, ey1); - - delta = first + first - poly_subpixel_scale; - area = two_fx * delta; - while(ey1 != ey2) - { - //render_hline(ey1, x_from, poly_subpixel_scale - first, x_from, first); - m_curr_cell.cover = delta; - m_curr_cell.area = area; - ey1 += incr; - set_curr_cell(ex, ey1); - } - //render_hline(ey1, x_from, poly_subpixel_scale - first, x_from, fy2); - delta = fy2 - poly_subpixel_scale + first; - m_curr_cell.cover += delta; - m_curr_cell.area += two_fx * delta; - return; - } - - //ok, we have to render several hlines - p = (poly_subpixel_scale - fy1) * dx; - first = poly_subpixel_scale; - - if(dy < 0) - { - p = fy1 * dx; - first = 0; - incr = -1; - dy = -dy; - } - - delta = p / dy; - mod = p % dy; - - if(mod < 0) - { - delta--; - mod += dy; - } - - x_from = x1 + delta; - render_hline(ey1, x1, fy1, x_from, first); - - ey1 += incr; - set_curr_cell(x_from >> poly_subpixel_shift, ey1); - - if(ey1 != ey2) - { - p = poly_subpixel_scale * dx; - lift = p / dy; - rem = p % dy; - - if(rem < 0) - { - lift--; - rem += dy; - } - mod -= dy; - - while(ey1 != ey2) - { - delta = lift; - mod += rem; - if (mod >= 0) - { - mod -= dy; - delta++; - } - - x_to = x_from + delta; - render_hline(ey1, x_from, poly_subpixel_scale - first, x_to, first); - x_from = x_to; - - ey1 += incr; - set_curr_cell(x_from >> poly_subpixel_shift, ey1); - } - } - render_hline(ey1, x_from, poly_subpixel_scale - first, x2, fy2); - } - - //------------------------------------------------------------------------ - template - void rasterizer_cells_aa::allocate_block() - { - if(m_curr_block >= m_num_blocks) - { - if(m_num_blocks >= m_max_blocks) - { - cell_type** new_cells = - pod_allocator::allocate(m_max_blocks + - cell_block_pool); - - if(m_cells) - { - memcpy(new_cells, m_cells, m_max_blocks * sizeof(cell_type*)); - pod_allocator::deallocate(m_cells, m_max_blocks); - } - m_cells = new_cells; - m_max_blocks += cell_block_pool; - } - - m_cells[m_num_blocks++] = - pod_allocator::allocate(cell_block_size); - - } - m_curr_cell_ptr = m_cells[m_curr_block++]; - } - - - - //------------------------------------------------------------------------ - template static AGG_INLINE void swap_cells(T* a, T* b) - { - T temp = *a; - *a = *b; - *b = temp; - } - - - //------------------------------------------------------------------------ - enum - { - qsort_threshold = 9 - }; - - - //------------------------------------------------------------------------ - template - void qsort_cells(Cell** start, unsigned num) - { - Cell** stack[80]; - Cell*** top; - Cell** limit; - Cell** base; - - limit = start + num; - base = start; - top = stack; - - for (;;) - { - int len = int(limit - base); - - Cell** i; - Cell** j; - Cell** pivot; - - if(len > qsort_threshold) - { - // we use base + len/2 as the pivot - pivot = base + len / 2; - swap_cells(base, pivot); - - i = base + 1; - j = limit - 1; - - // now ensure that *i <= *base <= *j - if((*j)->x < (*i)->x) - { - swap_cells(i, j); - } - - if((*base)->x < (*i)->x) - { - swap_cells(base, i); - } - - if((*j)->x < (*base)->x) - { - swap_cells(base, j); - } - - for(;;) - { - int x = (*base)->x; - do i++; while( (*i)->x < x ); - do j--; while( x < (*j)->x ); - - if(i > j) - { - break; - } - - swap_cells(i, j); - } - - swap_cells(base, j); - - // now, push the largest sub-array - if(j - base > limit - i) - { - top[0] = base; - top[1] = j; - base = i; - } - else - { - top[0] = i; - top[1] = limit; - limit = j; - } - top += 2; - } - else - { - // the sub-array is small, perform insertion sort - j = base; - i = j + 1; - - for(; i < limit; j = i, i++) - { - for(; j[1]->x < (*j)->x; j--) - { - swap_cells(j + 1, j); - if (j == base) - { - break; - } - } - } - - if(top > stack) - { - top -= 2; - base = top[0]; - limit = top[1]; - } - else - { - break; - } - } - } - } - - - //------------------------------------------------------------------------ - template - void rasterizer_cells_aa::sort_cells() - { - if(m_sorted) return; //Perform sort only the first time. - - add_curr_cell(); - m_curr_cell.x = 0x7FFFFFFF; - m_curr_cell.y = 0x7FFFFFFF; - m_curr_cell.cover = 0; - m_curr_cell.area = 0; - - if(m_num_cells == 0) return; - -// DBG: Check to see if min/max works well. -//for(unsigned nc = 0; nc < m_num_cells; nc++) -//{ -// cell_type* cell = m_cells[nc >> cell_block_shift] + (nc & cell_block_mask); -// if(cell->x < m_min_x || -// cell->y < m_min_y || -// cell->x > m_max_x || -// cell->y > m_max_y) -// { -// cell = cell; // Breakpoint here -// } -//} - // Allocate the array of cell pointers - m_sorted_cells.allocate(m_num_cells, 16); - - // Allocate and zero the Y array - m_sorted_y.allocate(m_max_y - m_min_y + 1, 16); - m_sorted_y.zero(); - - // Create the Y-histogram (count the numbers of cells for each Y) - cell_type** block_ptr = m_cells; - cell_type* cell_ptr; - unsigned nb = m_num_cells >> cell_block_shift; - unsigned i; - while(nb--) - { - cell_ptr = *block_ptr++; - i = cell_block_size; - while(i--) - { - m_sorted_y[cell_ptr->y - m_min_y].start++; - ++cell_ptr; - } - } - - cell_ptr = *block_ptr++; - i = m_num_cells & cell_block_mask; - while(i--) - { - m_sorted_y[cell_ptr->y - m_min_y].start++; - ++cell_ptr; - } - - // Convert the Y-histogram into the array of starting indexes - unsigned start = 0; - for(i = 0; i < m_sorted_y.size(); i++) - { - unsigned v = m_sorted_y[i].start; - m_sorted_y[i].start = start; - start += v; - } - - // Fill the cell pointer array sorted by Y - block_ptr = m_cells; - nb = m_num_cells >> cell_block_shift; - while(nb--) - { - cell_ptr = *block_ptr++; - i = cell_block_size; - while(i--) - { - sorted_y& curr_y = m_sorted_y[cell_ptr->y - m_min_y]; - m_sorted_cells[curr_y.start + curr_y.num] = cell_ptr; - ++curr_y.num; - ++cell_ptr; - } - } - - cell_ptr = *block_ptr++; - i = m_num_cells & cell_block_mask; - while(i--) - { - sorted_y& curr_y = m_sorted_y[cell_ptr->y - m_min_y]; - m_sorted_cells[curr_y.start + curr_y.num] = cell_ptr; - ++curr_y.num; - ++cell_ptr; - } - - // Finally arrange the X-arrays - for(i = 0; i < m_sorted_y.size(); i++) - { - const sorted_y& curr_y = m_sorted_y[i]; - if(curr_y.num) - { - qsort_cells(m_sorted_cells.data() + curr_y.start, curr_y.num); - } - } - m_sorted = true; - } - - - - //------------------------------------------------------scanline_hit_test - class scanline_hit_test - { - public: - scanline_hit_test(int x) : m_x(x), m_hit(false) {} - - void reset_spans() {} - void finalize(int) {} - void add_cell(int x, int) - { - if(m_x == x) m_hit = true; - } - void add_span(int x, int len, int) - { - if(m_x >= x && m_x < x+len) m_hit = true; - } - unsigned num_spans() const { return 1; } - bool hit() const { return m_hit; } - - private: - int m_x; - bool m_hit; - }; - - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_rasterizer_compound_aa.h b/desmume/src/windows/agg/include/agg_rasterizer_compound_aa.h deleted file mode 100644 index c37b031c5..000000000 --- a/desmume/src/windows/agg/include/agg_rasterizer_compound_aa.h +++ /dev/null @@ -1,698 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry - Version 2.3 -// Copyright (C) 2002-2005 Maxim Shemanarev (http://www.antigrain.com) -// -// Permission to copy, use, modify, sell and distribute this software -// is granted provided this copyright notice appears in all copies. -// This software is provided "as is" without express or implied -// warranty, and with no claim as to its suitability for any purpose. -// -//---------------------------------------------------------------------------- -// -// The author gratefully acknowleges the support of David Turner, -// Robert Wilhelm, and Werner Lemberg - the authors of the FreeType -// libray - in producing this work. See http://www.freetype.org for details. -// -//---------------------------------------------------------------------------- -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://www.antigrain.com -//---------------------------------------------------------------------------- -// -// Adaptation for 32-bit screen coordinates has been sponsored by -// Liberty Technology Systems, Inc., visit http://lib-sys.com -// -// Liberty Technology Systems, Inc. is the provider of -// PostScript and PDF technology for software developers. -// -//---------------------------------------------------------------------------- -#ifndef AGG_RASTERIZER_COMPOUND_AA_INCLUDED -#define AGG_RASTERIZER_COMPOUND_AA_INCLUDED - -#include "agg_rasterizer_cells_aa.h" -#include "agg_rasterizer_sl_clip.h" - -namespace agg -{ - - //-----------------------------------------------------------cell_style_aa - // A pixel cell. There're no constructors defined and it was done - // intentionally in order to avoid extra overhead when allocating an - // array of cells. - struct cell_style_aa - { - int x; - int y; - int cover; - int area; - int16 left, right; - - void initial() - { - x = 0x7FFFFFFF; - y = 0x7FFFFFFF; - cover = 0; - area = 0; - left = -1; - right = -1; - } - - void style(const cell_style_aa& c) - { - left = c.left; - right = c.right; - } - - int not_equal(int ex, int ey, const cell_style_aa& c) const - { - return (ex - x) | (ey - y) | (left - c.left) | (right - c.right); - } - }; - - - //===========================================================layer_order_e - enum layer_order_e - { - layer_unsorted, //------layer_unsorted - layer_direct, //------layer_direct - layer_inverse //------layer_inverse - }; - - - //==================================================rasterizer_compound_aa - template class rasterizer_compound_aa - { - struct style_info - { - unsigned start_cell; - unsigned num_cells; - int last_x; - }; - - struct cell_info - { - int x, area, cover; - }; - - public: - typedef Clip clip_type; - typedef typename Clip::conv_type conv_type; - typedef typename Clip::coord_type coord_type; - - enum aa_scale_e - { - aa_shift = 8, - aa_scale = 1 << aa_shift, - aa_mask = aa_scale - 1, - aa_scale2 = aa_scale * 2, - aa_mask2 = aa_scale2 - 1 - }; - - //-------------------------------------------------------------------- - rasterizer_compound_aa() : - m_outline(), - m_clipper(), - m_filling_rule(fill_non_zero), - m_layer_order(layer_direct), - m_styles(), // Active Styles - m_ast(), // Active Style Table (unique values) - m_asm(), // Active Style Mask - m_cells(), - m_cover_buf(), - m_master_alpha(), - m_min_style(0x7FFFFFFF), - m_max_style(-0x7FFFFFFF), - m_start_x(0), - m_start_y(0), - m_scan_y(0x7FFFFFFF), - m_sl_start(0), - m_sl_len(0) - {} - - //-------------------------------------------------------------------- - void reset(); - void reset_clipping(); - void clip_box(double x1, double y1, double x2, double y2); - void filling_rule(filling_rule_e filling_rule); - void layer_order(layer_order_e order); - void master_alpha(int style, double alpha); - - //-------------------------------------------------------------------- - void styles(int left, int right); - void move_to(int x, int y); - void line_to(int x, int y); - void move_to_d(double x, double y); - void line_to_d(double x, double y); - void add_vertex(double x, double y, unsigned cmd); - - void edge(int x1, int y1, int x2, int y2); - void edge_d(double x1, double y1, double x2, double y2); - - //------------------------------------------------------------------- - template - void add_path(VertexSource& vs, unsigned path_id=0) - { - double x; - double y; - - unsigned cmd; - vs.rewind(path_id); - if(m_outline.sorted()) reset(); - while(!is_stop(cmd = vs.vertex(&x, &y))) - { - add_vertex(x, y, cmd); - } - } - - - //-------------------------------------------------------------------- - int min_x() const { return m_outline.min_x(); } - int min_y() const { return m_outline.min_y(); } - int max_x() const { return m_outline.max_x(); } - int max_y() const { return m_outline.max_y(); } - int min_style() const { return m_min_style; } - int max_style() const { return m_max_style; } - - //-------------------------------------------------------------------- - void sort(); - bool rewind_scanlines(); - unsigned sweep_styles(); - int scanline_start() const { return m_sl_start; } - unsigned scanline_length() const { return m_sl_len; } - unsigned style(unsigned style_idx) const; - - cover_type* allocate_cover_buffer(unsigned len); - - //-------------------------------------------------------------------- - bool navigate_scanline(int y); - bool hit_test(int tx, int ty); - - //-------------------------------------------------------------------- - AGG_INLINE unsigned calculate_alpha(int area, unsigned master_alpha) const - { - int cover = area >> (poly_subpixel_shift*2 + 1 - aa_shift); - if(cover < 0) cover = -cover; - if(m_filling_rule == fill_even_odd) - { - cover &= aa_mask2; - if(cover > aa_scale) - { - cover = aa_scale2 - cover; - } - } - if(cover > aa_mask) cover = aa_mask; - return (cover * master_alpha + aa_mask) >> aa_shift; - } - - //-------------------------------------------------------------------- - // Sweeps one scanline with one style index. The style ID can be - // determined by calling style(). - template bool sweep_scanline(Scanline& sl, int style_idx) - { - int scan_y = m_scan_y - 1; - if(scan_y > m_outline.max_y()) return false; - - sl.reset_spans(); - - unsigned master_alpha = aa_mask; - - if(style_idx < 0) - { - style_idx = 0; - } - else - { - style_idx++; - master_alpha = m_master_alpha[m_ast[style_idx] + m_min_style - 1]; - } - - const style_info& st = m_styles[m_ast[style_idx]]; - - unsigned num_cells = st.num_cells; - cell_info* cell = &m_cells[st.start_cell]; - - int cover = 0; - while(num_cells--) - { - unsigned alpha; - int x = cell->x; - int area = cell->area; - - cover += cell->cover; - - ++cell; - - if(area) - { - alpha = calculate_alpha((cover << (poly_subpixel_shift + 1)) - area, - master_alpha); - sl.add_cell(x, alpha); - x++; - } - - if(num_cells && cell->x > x) - { - alpha = calculate_alpha(cover << (poly_subpixel_shift + 1), - master_alpha); - if(alpha) - { - sl.add_span(x, cell->x - x, alpha); - } - } - } - - if(sl.num_spans() == 0) return false; - sl.finalize(scan_y); - return true; - } - - private: - void add_style(int style_id); - void allocate_master_alpha(); - - //-------------------------------------------------------------------- - // Disable copying - rasterizer_compound_aa(const rasterizer_compound_aa&); - const rasterizer_compound_aa& - operator = (const rasterizer_compound_aa&); - - private: - rasterizer_cells_aa m_outline; - clip_type m_clipper; - filling_rule_e m_filling_rule; - layer_order_e m_layer_order; - pod_vector m_styles; // Active Styles - pod_vector m_ast; // Active Style Table (unique values) - pod_vector m_asm; // Active Style Mask - pod_vector m_cells; - pod_vector m_cover_buf; - pod_bvector m_master_alpha; - - int m_min_style; - int m_max_style; - coord_type m_start_x; - coord_type m_start_y; - int m_scan_y; - int m_sl_start; - unsigned m_sl_len; - }; - - - - - - - - - - - //------------------------------------------------------------------------ - template - void rasterizer_compound_aa::reset() - { - m_outline.reset(); - m_min_style = 0x7FFFFFFF; - m_max_style = -0x7FFFFFFF; - m_scan_y = 0x7FFFFFFF; - m_sl_start = 0; - m_sl_len = 0; - } - - //------------------------------------------------------------------------ - template - void rasterizer_compound_aa::filling_rule(filling_rule_e filling_rule) - { - m_filling_rule = filling_rule; - } - - //------------------------------------------------------------------------ - template - void rasterizer_compound_aa::layer_order(layer_order_e order) - { - m_layer_order = order; - } - - //------------------------------------------------------------------------ - template - void rasterizer_compound_aa::clip_box(double x1, double y1, - double x2, double y2) - { - reset(); - m_clipper.clip_box(conv_type::upscale(x1), conv_type::upscale(y1), - conv_type::upscale(x2), conv_type::upscale(y2)); - } - - //------------------------------------------------------------------------ - template - void rasterizer_compound_aa::reset_clipping() - { - reset(); - m_clipper.reset_clipping(); - } - - //------------------------------------------------------------------------ - template - void rasterizer_compound_aa::styles(int left, int right) - { - cell_style_aa cell; - cell.initial(); - cell.left = (int16)left; - cell.right = (int16)right; - m_outline.style(cell); - if(left >= 0 && left < m_min_style) m_min_style = left; - if(left >= 0 && left > m_max_style) m_max_style = left; - if(right >= 0 && right < m_min_style) m_min_style = right; - if(right >= 0 && right > m_max_style) m_max_style = right; - } - - //------------------------------------------------------------------------ - template - void rasterizer_compound_aa::move_to(int x, int y) - { - if(m_outline.sorted()) reset(); - m_clipper.move_to(m_start_x = conv_type::downscale(x), - m_start_y = conv_type::downscale(y)); - } - - //------------------------------------------------------------------------ - template - void rasterizer_compound_aa::line_to(int x, int y) - { - m_clipper.line_to(m_outline, - conv_type::downscale(x), - conv_type::downscale(y)); - } - - //------------------------------------------------------------------------ - template - void rasterizer_compound_aa::move_to_d(double x, double y) - { - if(m_outline.sorted()) reset(); - m_clipper.move_to(m_start_x = conv_type::upscale(x), - m_start_y = conv_type::upscale(y)); - } - - //------------------------------------------------------------------------ - template - void rasterizer_compound_aa::line_to_d(double x, double y) - { - m_clipper.line_to(m_outline, - conv_type::upscale(x), - conv_type::upscale(y)); - } - - //------------------------------------------------------------------------ - template - void rasterizer_compound_aa::add_vertex(double x, double y, unsigned cmd) - { - if(is_move_to(cmd)) - { - move_to_d(x, y); - } - else - if(is_vertex(cmd)) - { - line_to_d(x, y); - } - else - if(is_close(cmd)) - { - m_clipper.line_to(m_outline, m_start_x, m_start_y); - } - } - - //------------------------------------------------------------------------ - template - void rasterizer_compound_aa::edge(int x1, int y1, int x2, int y2) - { - if(m_outline.sorted()) reset(); - m_clipper.move_to(conv_type::downscale(x1), conv_type::downscale(y1)); - m_clipper.line_to(m_outline, - conv_type::downscale(x2), - conv_type::downscale(y2)); - } - - //------------------------------------------------------------------------ - template - void rasterizer_compound_aa::edge_d(double x1, double y1, - double x2, double y2) - { - if(m_outline.sorted()) reset(); - m_clipper.move_to(conv_type::upscale(x1), conv_type::upscale(y1)); - m_clipper.line_to(m_outline, - conv_type::upscale(x2), - conv_type::upscale(y2)); - } - - //------------------------------------------------------------------------ - template - AGG_INLINE void rasterizer_compound_aa::sort() - { - m_outline.sort_cells(); - } - - //------------------------------------------------------------------------ - template - AGG_INLINE bool rasterizer_compound_aa::rewind_scanlines() - { - m_outline.sort_cells(); - if(m_outline.total_cells() == 0) - { - return false; - } - if(m_max_style < m_min_style) - { - return false; - } - m_scan_y = m_outline.min_y(); - m_styles.allocate(m_max_style - m_min_style + 2, 128); - allocate_master_alpha(); - return true; - } - - //------------------------------------------------------------------------ - template - AGG_INLINE void rasterizer_compound_aa::add_style(int style_id) - { - if(style_id < 0) style_id = 0; - else style_id -= m_min_style - 1; - - unsigned nbyte = style_id >> 3; - unsigned mask = 1 << (style_id & 7); - - style_info* style = &m_styles[style_id]; - if((m_asm[nbyte] & mask) == 0) - { - m_ast.add(style_id); - m_asm[nbyte] |= mask; - style->start_cell = 0; - style->num_cells = 0; - style->last_x = -0x7FFFFFFF; - } - ++style->start_cell; - } - - //------------------------------------------------------------------------ - // Returns the number of styles - template - unsigned rasterizer_compound_aa::sweep_styles() - { - for(;;) - { - if(m_scan_y > m_outline.max_y()) return 0; - unsigned num_cells = m_outline.scanline_num_cells(m_scan_y); - const cell_style_aa* const* cells = m_outline.scanline_cells(m_scan_y); - unsigned num_styles = m_max_style - m_min_style + 2; - const cell_style_aa* curr_cell; - unsigned style_id; - style_info* style; - cell_info* cell; - - m_cells.allocate(num_cells * 2, 256); // Each cell can have two styles - m_ast.capacity(num_styles, 64); - m_asm.allocate((num_styles + 7) >> 3, 8); - m_asm.zero(); - - if(num_cells) - { - // Pre-add zero (for no-fill style, that is, -1). - // We need that to ensure that the "-1 style" would go first. - m_asm[0] |= 1; - m_ast.add(0); - style = &m_styles[0]; - style->start_cell = 0; - style->num_cells = 0; - style->last_x = -0x7FFFFFFF; - - m_sl_start = cells[0]->x; - m_sl_len = cells[num_cells-1]->x - m_sl_start + 1; - while(num_cells--) - { - curr_cell = *cells++; - add_style(curr_cell->left); - add_style(curr_cell->right); - } - - // Convert the Y-histogram into the array of starting indexes - unsigned i; - unsigned start_cell = 0; - for(i = 0; i < m_ast.size(); i++) - { - style_info& st = m_styles[m_ast[i]]; - unsigned v = st.start_cell; - st.start_cell = start_cell; - start_cell += v; - } - - cells = m_outline.scanline_cells(m_scan_y); - num_cells = m_outline.scanline_num_cells(m_scan_y); - - while(num_cells--) - { - curr_cell = *cells++; - style_id = (curr_cell->left < 0) ? 0 : - curr_cell->left - m_min_style + 1; - - style = &m_styles[style_id]; - if(curr_cell->x == style->last_x) - { - cell = &m_cells[style->start_cell + style->num_cells - 1]; - cell->area += curr_cell->area; - cell->cover += curr_cell->cover; - } - else - { - cell = &m_cells[style->start_cell + style->num_cells]; - cell->x = curr_cell->x; - cell->area = curr_cell->area; - cell->cover = curr_cell->cover; - style->last_x = curr_cell->x; - style->num_cells++; - } - - style_id = (curr_cell->right < 0) ? 0 : - curr_cell->right - m_min_style + 1; - - style = &m_styles[style_id]; - if(curr_cell->x == style->last_x) - { - cell = &m_cells[style->start_cell + style->num_cells - 1]; - cell->area -= curr_cell->area; - cell->cover -= curr_cell->cover; - } - else - { - cell = &m_cells[style->start_cell + style->num_cells]; - cell->x = curr_cell->x; - cell->area = -curr_cell->area; - cell->cover = -curr_cell->cover; - style->last_x = curr_cell->x; - style->num_cells++; - } - } - } - if(m_ast.size() > 1) break; - ++m_scan_y; - } - ++m_scan_y; - - if(m_layer_order != layer_unsorted) - { - range_adaptor > ra(m_ast, 1, m_ast.size() - 1); - if(m_layer_order == layer_direct) quick_sort(ra, unsigned_greater); - else quick_sort(ra, unsigned_less); - } - - return m_ast.size() - 1; - } - - //------------------------------------------------------------------------ - // Returns style ID depending of the existing style index - template - AGG_INLINE - unsigned rasterizer_compound_aa::style(unsigned style_idx) const - { - return m_ast[style_idx + 1] + m_min_style - 1; - } - - //------------------------------------------------------------------------ - template - AGG_INLINE bool rasterizer_compound_aa::navigate_scanline(int y) - { - m_outline.sort_cells(); - if(m_outline.total_cells() == 0) - { - return false; - } - if(m_max_style < m_min_style) - { - return false; - } - if(y < m_outline.min_y() || y > m_outline.max_y()) - { - return false; - } - m_scan_y = y; - m_styles.allocate(m_max_style - m_min_style + 2, 128); - allocate_master_alpha(); - return true; - } - - //------------------------------------------------------------------------ - template - bool rasterizer_compound_aa::hit_test(int tx, int ty) - { - if(!navigate_scanline(ty)) - { - return false; - } - - unsigned num_styles = sweep_styles(); - if(num_styles <= 0) - { - return false; - } - - scanline_hit_test sl(tx); - sweep_scanline(sl, -1); - return sl.hit(); - } - - //------------------------------------------------------------------------ - template - cover_type* rasterizer_compound_aa::allocate_cover_buffer(unsigned len) - { - m_cover_buf.allocate(len, 256); - return &m_cover_buf[0]; - } - - //------------------------------------------------------------------------ - template - void rasterizer_compound_aa::allocate_master_alpha() - { - while((int)m_master_alpha.size() <= m_max_style) - { - m_master_alpha.add(aa_mask); - } - } - - //------------------------------------------------------------------------ - template - void rasterizer_compound_aa::master_alpha(int style, double alpha) - { - if(style >= 0) - { - while((int)m_master_alpha.size() <= style) - { - m_master_alpha.add(aa_mask); - } - m_master_alpha[style] = uround(alpha * aa_mask); - } - } - -} - - - -#endif - diff --git a/desmume/src/windows/agg/include/agg_rasterizer_outline.h b/desmume/src/windows/agg/include/agg_rasterizer_outline.h deleted file mode 100644 index 57cb3e0a7..000000000 --- a/desmume/src/windows/agg/include/agg_rasterizer_outline.h +++ /dev/null @@ -1,157 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_RASTERIZER_OUTLINE_INCLUDED -#define AGG_RASTERIZER_OUTLINE_INCLUDED - -#include "agg_basics.h" - -namespace agg -{ - //======================================================rasterizer_outline - template class rasterizer_outline - { - public: - explicit rasterizer_outline(Renderer& ren) : - m_ren(&ren), - m_start_x(0), - m_start_y(0), - m_vertices(0) - {} - void attach(Renderer& ren) { m_ren = &ren; } - - - //-------------------------------------------------------------------- - void move_to(int x, int y) - { - m_vertices = 1; - m_ren->move_to(m_start_x = x, m_start_y = y); - } - - //-------------------------------------------------------------------- - void line_to(int x, int y) - { - ++m_vertices; - m_ren->line_to(x, y); - } - - //-------------------------------------------------------------------- - void move_to_d(double x, double y) - { - move_to(m_ren->coord(x), m_ren->coord(y)); - } - - //-------------------------------------------------------------------- - void line_to_d(double x, double y) - { - line_to(m_ren->coord(x), m_ren->coord(y)); - } - - //-------------------------------------------------------------------- - void close() - { - if(m_vertices > 2) - { - line_to(m_start_x, m_start_y); - } - m_vertices = 0; - } - - //-------------------------------------------------------------------- - void add_vertex(double x, double y, unsigned cmd) - { - if(is_move_to(cmd)) - { - move_to_d(x, y); - } - else - { - if(is_end_poly(cmd)) - { - if(is_closed(cmd)) close(); - } - else - { - line_to_d(x, y); - } - } - } - - - //-------------------------------------------------------------------- - template - void add_path(VertexSource& vs, unsigned path_id=0) - { - double x; - double y; - - unsigned cmd; - vs.rewind(path_id); - while(!is_stop(cmd = vs.vertex(&x, &y))) - { - add_vertex(x, y, cmd); - } - } - - - //-------------------------------------------------------------------- - template - void render_all_paths(VertexSource& vs, - const ColorStorage& colors, - const PathId& path_id, - unsigned num_paths) - { - for(unsigned i = 0; i < num_paths; i++) - { - m_ren->line_color(colors[i]); - add_path(vs, path_id[i]); - } - } - - - //-------------------------------------------------------------------- - template void render_ctrl(Ctrl& c) - { - unsigned i; - for(i = 0; i < c.num_paths(); i++) - { - m_ren->line_color(c.color(i)); - add_path(c, i); - } - } - - - private: - Renderer* m_ren; - int m_start_x; - int m_start_y; - unsigned m_vertices; - }; - - -} - - -#endif - diff --git a/desmume/src/windows/agg/include/agg_rasterizer_outline_aa.h b/desmume/src/windows/agg/include/agg_rasterizer_outline_aa.h deleted file mode 100644 index 6347cdfe8..000000000 --- a/desmume/src/windows/agg/include/agg_rasterizer_outline_aa.h +++ /dev/null @@ -1,609 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_RASTERIZER_OUTLINE_AA_INCLUDED -#define AGG_RASTERIZER_OUTLINE_AA_INCLUDED - -#include "agg_basics.h" -#include "agg_line_aa_basics.h" -#include "agg_vertex_sequence.h" - -namespace agg -{ - - //------------------------------------------------------------------------- - inline bool cmp_dist_start(int d) { return d > 0; } - inline bool cmp_dist_end(int d) { return d <= 0; } - - - - //-----------------------------------------------------------line_aa_vertex - // Vertex (x, y) with the distance to the next one. The last vertex has - // the distance between the last and the first points - struct line_aa_vertex - { - int x; - int y; - int len; - - line_aa_vertex() {} - line_aa_vertex(int x_, int y_) : - x(x_), - y(y_), - len(0) - { - } - - bool operator () (const line_aa_vertex& val) - { - double dx = val.x - x; - double dy = val.y - y; - return (len = uround(sqrt(dx * dx + dy * dy))) > - (line_subpixel_scale + line_subpixel_scale / 2); - } - }; - - - //----------------------------------------------------------outline_aa_join_e - enum outline_aa_join_e - { - outline_no_join, //-----outline_no_join - outline_miter_join, //-----outline_miter_join - outline_round_join, //-----outline_round_join - outline_miter_accurate_join //-----outline_accurate_join - }; - - //=======================================================rasterizer_outline_aa - template class rasterizer_outline_aa - { - private: - //------------------------------------------------------------------------ - struct draw_vars - { - unsigned idx; - int x1, y1, x2, y2; - line_parameters curr, next; - int lcurr, lnext; - int xb1, yb1, xb2, yb2; - unsigned flags; - }; - - void draw(draw_vars& dv, unsigned start, unsigned end); - - public: - typedef line_aa_vertex vertex_type; - typedef vertex_sequence vertex_storage_type; - - explicit rasterizer_outline_aa(Renderer& ren) : - m_ren(&ren), - m_line_join(ren.accurate_join_only() ? - outline_miter_accurate_join : - outline_round_join), - m_round_cap(false), - m_start_x(0), - m_start_y(0) - {} - void attach(Renderer& ren) { m_ren = &ren; } - - //------------------------------------------------------------------------ - void line_join(outline_aa_join_e join) - { - m_line_join = m_ren->accurate_join_only() ? - outline_miter_accurate_join : - join; - } - bool line_join() const { return m_line_join; } - - //------------------------------------------------------------------------ - void round_cap(bool v) { m_round_cap = v; } - bool round_cap() const { return m_round_cap; } - - //------------------------------------------------------------------------ - void move_to(int x, int y) - { - m_src_vertices.modify_last(vertex_type(m_start_x = x, m_start_y = y)); - } - - //------------------------------------------------------------------------ - void line_to(int x, int y) - { - m_src_vertices.add(vertex_type(x, y)); - } - - //------------------------------------------------------------------------ - void move_to_d(double x, double y) - { - move_to(Coord::conv(x), Coord::conv(y)); - } - - //------------------------------------------------------------------------ - void line_to_d(double x, double y) - { - line_to(Coord::conv(x), Coord::conv(y)); - } - - //------------------------------------------------------------------------ - void render(bool close_polygon); - - //------------------------------------------------------------------------ - void add_vertex(double x, double y, unsigned cmd) - { - if(is_move_to(cmd)) - { - render(false); - move_to_d(x, y); - } - else - { - if(is_end_poly(cmd)) - { - render(is_closed(cmd)); - if(is_closed(cmd)) - { - move_to(m_start_x, m_start_y); - } - } - else - { - line_to_d(x, y); - } - } - } - - //------------------------------------------------------------------------ - template - void add_path(VertexSource& vs, unsigned path_id=0) - { - double x; - double y; - - unsigned cmd; - vs.rewind(path_id); - while(!is_stop(cmd = vs.vertex(&x, &y))) - { - add_vertex(x, y, cmd); - } - render(false); - } - - - //------------------------------------------------------------------------ - template - void render_all_paths(VertexSource& vs, - const ColorStorage& colors, - const PathId& path_id, - unsigned num_paths) - { - for(unsigned i = 0; i < num_paths; i++) - { - m_ren->color(colors[i]); - add_path(vs, path_id[i]); - } - } - - - //------------------------------------------------------------------------ - template void render_ctrl(Ctrl& c) - { - unsigned i; - for(i = 0; i < c.num_paths(); i++) - { - m_ren->color(c.color(i)); - add_path(c, i); - } - } - - private: - rasterizer_outline_aa(const rasterizer_outline_aa&); - const rasterizer_outline_aa& operator = - (const rasterizer_outline_aa&); - - Renderer* m_ren; - vertex_storage_type m_src_vertices; - outline_aa_join_e m_line_join; - bool m_round_cap; - int m_start_x; - int m_start_y; - }; - - - - - - - - - //---------------------------------------------------------------------------- - template - void rasterizer_outline_aa::draw(draw_vars& dv, - unsigned start, - unsigned end) - { - unsigned i; - const vertex_storage_type::value_type* v; - - for(i = start; i < end; i++) - { - if(m_line_join == outline_round_join) - { - dv.xb1 = dv.curr.x1 + (dv.curr.y2 - dv.curr.y1); - dv.yb1 = dv.curr.y1 - (dv.curr.x2 - dv.curr.x1); - dv.xb2 = dv.curr.x2 + (dv.curr.y2 - dv.curr.y1); - dv.yb2 = dv.curr.y2 - (dv.curr.x2 - dv.curr.x1); - } - - switch(dv.flags) - { - case 0: m_ren->line3(dv.curr, dv.xb1, dv.yb1, dv.xb2, dv.yb2); break; - case 1: m_ren->line2(dv.curr, dv.xb2, dv.yb2); break; - case 2: m_ren->line1(dv.curr, dv.xb1, dv.yb1); break; - case 3: m_ren->line0(dv.curr); break; - } - - if(m_line_join == outline_round_join && (dv.flags & 2) == 0) - { - m_ren->pie(dv.curr.x2, dv.curr.y2, - dv.curr.x2 + (dv.curr.y2 - dv.curr.y1), - dv.curr.y2 - (dv.curr.x2 - dv.curr.x1), - dv.curr.x2 + (dv.next.y2 - dv.next.y1), - dv.curr.y2 - (dv.next.x2 - dv.next.x1)); - } - - dv.x1 = dv.x2; - dv.y1 = dv.y2; - dv.lcurr = dv.lnext; - dv.lnext = m_src_vertices[dv.idx].len; - - ++dv.idx; - if(dv.idx >= m_src_vertices.size()) dv.idx = 0; - - v = &m_src_vertices[dv.idx]; - dv.x2 = v->x; - dv.y2 = v->y; - - dv.curr = dv.next; - dv.next = line_parameters(dv.x1, dv.y1, dv.x2, dv.y2, dv.lnext); - dv.xb1 = dv.xb2; - dv.yb1 = dv.yb2; - - switch(m_line_join) - { - case outline_no_join: - dv.flags = 3; - break; - - case outline_miter_join: - dv.flags >>= 1; - dv.flags |= ((dv.curr.diagonal_quadrant() == - dv.next.diagonal_quadrant()) << 1); - if((dv.flags & 2) == 0) - { - bisectrix(dv.curr, dv.next, &dv.xb2, &dv.yb2); - } - break; - - case outline_round_join: - dv.flags >>= 1; - dv.flags |= ((dv.curr.diagonal_quadrant() == - dv.next.diagonal_quadrant()) << 1); - break; - - case outline_miter_accurate_join: - dv.flags = 0; - bisectrix(dv.curr, dv.next, &dv.xb2, &dv.yb2); - break; - } - } - } - - - - - //---------------------------------------------------------------------------- - template - void rasterizer_outline_aa::render(bool close_polygon) - { - m_src_vertices.close(close_polygon); - draw_vars dv; - const vertex_storage_type::value_type* v; - int x1; - int y1; - int x2; - int y2; - int lprev; - - if(close_polygon) - { - if(m_src_vertices.size() >= 3) - { - dv.idx = 2; - - v = &m_src_vertices[m_src_vertices.size() - 1]; - x1 = v->x; - y1 = v->y; - lprev = v->len; - - v = &m_src_vertices[0]; - x2 = v->x; - y2 = v->y; - dv.lcurr = v->len; - line_parameters prev(x1, y1, x2, y2, lprev); - - v = &m_src_vertices[1]; - dv.x1 = v->x; - dv.y1 = v->y; - dv.lnext = v->len; - dv.curr = line_parameters(x2, y2, dv.x1, dv.y1, dv.lcurr); - - v = &m_src_vertices[dv.idx]; - dv.x2 = v->x; - dv.y2 = v->y; - dv.next = line_parameters(dv.x1, dv.y1, dv.x2, dv.y2, dv.lnext); - - dv.xb1 = 0; - dv.yb1 = 0; - dv.xb2 = 0; - dv.yb2 = 0; - - switch(m_line_join) - { - case outline_no_join: - dv.flags = 3; - break; - - case outline_miter_join: - case outline_round_join: - dv.flags = - (prev.diagonal_quadrant() == dv.curr.diagonal_quadrant()) | - ((dv.curr.diagonal_quadrant() == dv.next.diagonal_quadrant()) << 1); - break; - - case outline_miter_accurate_join: - dv.flags = 0; - break; - } - - if((dv.flags & 1) == 0 && m_line_join != outline_round_join) - { - bisectrix(prev, dv.curr, &dv.xb1, &dv.yb1); - } - - if((dv.flags & 2) == 0 && m_line_join != outline_round_join) - { - bisectrix(dv.curr, dv.next, &dv.xb2, &dv.yb2); - } - draw(dv, 0, m_src_vertices.size()); - } - } - else - { - switch(m_src_vertices.size()) - { - case 0: - case 1: - break; - - case 2: - { - v = &m_src_vertices[0]; - x1 = v->x; - y1 = v->y; - lprev = v->len; - v = &m_src_vertices[1]; - x2 = v->x; - y2 = v->y; - line_parameters lp(x1, y1, x2, y2, lprev); - if(m_round_cap) - { - m_ren->semidot(cmp_dist_start, x1, y1, x1 + (y2 - y1), y1 - (x2 - x1)); - } - m_ren->line3(lp, - x1 + (y2 - y1), - y1 - (x2 - x1), - x2 + (y2 - y1), - y2 - (x2 - x1)); - if(m_round_cap) - { - m_ren->semidot(cmp_dist_end, x2, y2, x2 + (y2 - y1), y2 - (x2 - x1)); - } - } - break; - - case 3: - { - int x3, y3; - int lnext; - v = &m_src_vertices[0]; - x1 = v->x; - y1 = v->y; - lprev = v->len; - v = &m_src_vertices[1]; - x2 = v->x; - y2 = v->y; - lnext = v->len; - v = &m_src_vertices[2]; - x3 = v->x; - y3 = v->y; - line_parameters lp1(x1, y1, x2, y2, lprev); - line_parameters lp2(x2, y2, x3, y3, lnext); - - if(m_round_cap) - { - m_ren->semidot(cmp_dist_start, x1, y1, x1 + (y2 - y1), y1 - (x2 - x1)); - } - - if(m_line_join == outline_round_join) - { - m_ren->line3(lp1, x1 + (y2 - y1), y1 - (x2 - x1), - x2 + (y2 - y1), y2 - (x2 - x1)); - - m_ren->pie(x2, y2, x2 + (y2 - y1), y2 - (x2 - x1), - x2 + (y3 - y2), y2 - (x3 - x2)); - - m_ren->line3(lp2, x2 + (y3 - y2), y2 - (x3 - x2), - x3 + (y3 - y2), y3 - (x3 - x2)); - } - else - { - bisectrix(lp1, lp2, &dv.xb1, &dv.yb1); - m_ren->line3(lp1, x1 + (y2 - y1), y1 - (x2 - x1), - dv.xb1, dv.yb1); - - m_ren->line3(lp2, dv.xb1, dv.yb1, - x3 + (y3 - y2), y3 - (x3 - x2)); - } - if(m_round_cap) - { - m_ren->semidot(cmp_dist_end, x3, y3, x3 + (y3 - y2), y3 - (x3 - x2)); - } - } - break; - - default: - { - dv.idx = 3; - - v = &m_src_vertices[0]; - x1 = v->x; - y1 = v->y; - lprev = v->len; - - v = &m_src_vertices[1]; - x2 = v->x; - y2 = v->y; - dv.lcurr = v->len; - line_parameters prev(x1, y1, x2, y2, lprev); - - v = &m_src_vertices[2]; - dv.x1 = v->x; - dv.y1 = v->y; - dv.lnext = v->len; - dv.curr = line_parameters(x2, y2, dv.x1, dv.y1, dv.lcurr); - - v = &m_src_vertices[dv.idx]; - dv.x2 = v->x; - dv.y2 = v->y; - dv.next = line_parameters(dv.x1, dv.y1, dv.x2, dv.y2, dv.lnext); - - dv.xb1 = 0; - dv.yb1 = 0; - dv.xb2 = 0; - dv.yb2 = 0; - - switch(m_line_join) - { - case outline_no_join: - dv.flags = 3; - break; - - case outline_miter_join: - case outline_round_join: - dv.flags = - (prev.diagonal_quadrant() == dv.curr.diagonal_quadrant()) | - ((dv.curr.diagonal_quadrant() == dv.next.diagonal_quadrant()) << 1); - break; - - case outline_miter_accurate_join: - dv.flags = 0; - break; - } - - if(m_round_cap) - { - m_ren->semidot(cmp_dist_start, x1, y1, x1 + (y2 - y1), y1 - (x2 - x1)); - } - if((dv.flags & 1) == 0) - { - if(m_line_join == outline_round_join) - { - m_ren->line3(prev, x1 + (y2 - y1), y1 - (x2 - x1), - x2 + (y2 - y1), y2 - (x2 - x1)); - m_ren->pie(prev.x2, prev.y2, - x2 + (y2 - y1), y2 - (x2 - x1), - dv.curr.x1 + (dv.curr.y2 - dv.curr.y1), - dv.curr.y1 - (dv.curr.x2 - dv.curr.x1)); - } - else - { - bisectrix(prev, dv.curr, &dv.xb1, &dv.yb1); - m_ren->line3(prev, x1 + (y2 - y1), y1 - (x2 - x1), - dv.xb1, dv.yb1); - } - } - else - { - m_ren->line1(prev, - x1 + (y2 - y1), - y1 - (x2 - x1)); - } - if((dv.flags & 2) == 0 && m_line_join != outline_round_join) - { - bisectrix(dv.curr, dv.next, &dv.xb2, &dv.yb2); - } - - draw(dv, 1, m_src_vertices.size() - 2); - - if((dv.flags & 1) == 0) - { - if(m_line_join == outline_round_join) - { - m_ren->line3(dv.curr, - dv.curr.x1 + (dv.curr.y2 - dv.curr.y1), - dv.curr.y1 - (dv.curr.x2 - dv.curr.x1), - dv.curr.x2 + (dv.curr.y2 - dv.curr.y1), - dv.curr.y2 - (dv.curr.x2 - dv.curr.x1)); - } - else - { - m_ren->line3(dv.curr, dv.xb1, dv.yb1, - dv.curr.x2 + (dv.curr.y2 - dv.curr.y1), - dv.curr.y2 - (dv.curr.x2 - dv.curr.x1)); - } - } - else - { - m_ren->line2(dv.curr, - dv.curr.x2 + (dv.curr.y2 - dv.curr.y1), - dv.curr.y2 - (dv.curr.x2 - dv.curr.x1)); - } - if(m_round_cap) - { - m_ren->semidot(cmp_dist_end, dv.curr.x2, dv.curr.y2, - dv.curr.x2 + (dv.curr.y2 - dv.curr.y1), - dv.curr.y2 - (dv.curr.x2 - dv.curr.x1)); - } - - } - break; - } - } - m_src_vertices.remove_all(); - } - - -} - - -#endif - diff --git a/desmume/src/windows/agg/include/agg_rasterizer_scanline_aa.h b/desmume/src/windows/agg/include/agg_rasterizer_scanline_aa.h deleted file mode 100644 index b5d363add..000000000 --- a/desmume/src/windows/agg/include/agg_rasterizer_scanline_aa.h +++ /dev/null @@ -1,520 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- -// -// The author gratefully acknowleges the support of David Turner, -// Robert Wilhelm, and Werner Lemberg - the authors of the FreeType -// libray - in producing this work. See http://www.freetype.org for details. -// -//---------------------------------------------------------------------------- -// -// Adaptation for 32-bit screen coordinates has been sponsored by -// Liberty Technology Systems, Inc., visit http://lib-sys.com -// -// Liberty Technology Systems, Inc. is the provider of -// PostScript and PDF technology for software developers. -// -//---------------------------------------------------------------------------- - -#ifndef AGG_RASTERIZER_SCANLINE_AA_INCLUDED -#define AGG_RASTERIZER_SCANLINE_AA_INCLUDED - -#include "agg_rasterizer_cells_aa.h" -#include "agg_rasterizer_sl_clip.h" -#include "agg_gamma_functions.h" - - -namespace agg -{ - - - //-----------------------------------------------------------------cell_aa - // A pixel cell. There're no constructors defined and it was done - // intentionally in order to avoid extra overhead when allocating an - // array of cells. - struct cell_aa - { - int x; - int y; - int cover; - int area; - - void initial() - { - x = 0x7FFFFFFF; - y = 0x7FFFFFFF; - cover = 0; - area = 0; - } - - void style(const cell_aa&) {} - - int not_equal(int ex, int ey, const cell_aa&) const - { - return (ex - x) | (ey - y); - } - }; - - - //==================================================rasterizer_scanline_aa - // Polygon rasterizer that is used to render filled polygons with - // high-quality Anti-Aliasing. Internally, by default, the class uses - // integer coordinates in format 24.8, i.e. 24 bits for integer part - // and 8 bits for fractional - see poly_subpixel_shift. This class can be - // used in the following way: - // - // 1. filling_rule(filling_rule_e ft) - optional. - // - // 2. gamma() - optional. - // - // 3. reset() - // - // 4. move_to(x, y) / line_to(x, y) - make the polygon. One can create - // more than one contour, but each contour must consist of at least 3 - // vertices, i.e. move_to(x1, y1); line_to(x2, y2); line_to(x3, y3); - // is the absolute minimum of vertices that define a triangle. - // The algorithm does not check either the number of vertices nor - // coincidence of their coordinates, but in the worst case it just - // won't draw anything. - // The orger of the vertices (clockwise or counterclockwise) - // is important when using the non-zero filling rule (fill_non_zero). - // In this case the vertex order of all the contours must be the same - // if you want your intersecting polygons to be without "holes". - // You actually can use different vertices order. If the contours do not - // intersect each other the order is not important anyway. If they do, - // contours with the same vertex order will be rendered without "holes" - // while the intersecting contours with different orders will have "holes". - // - // filling_rule() and gamma() can be called anytime before "sweeping". - //------------------------------------------------------------------------ - template class rasterizer_scanline_aa - { - enum status - { - status_initial, - status_move_to, - status_line_to, - status_closed - }; - - public: - typedef Clip clip_type; - typedef typename Clip::conv_type conv_type; - typedef typename Clip::coord_type coord_type; - - enum aa_scale_e - { - aa_shift = 8, - aa_scale = 1 << aa_shift, - aa_mask = aa_scale - 1, - aa_scale2 = aa_scale * 2, - aa_mask2 = aa_scale2 - 1 - }; - - //-------------------------------------------------------------------- - rasterizer_scanline_aa() : - m_outline(), - m_clipper(), - m_filling_rule(fill_non_zero), - m_auto_close(true), - m_start_x(0), - m_start_y(0), - m_status(status_initial) - { - int i; - for(i = 0; i < aa_scale; i++) m_gamma[i] = i; - } - - //-------------------------------------------------------------------- - template - rasterizer_scanline_aa(const GammaF& gamma_function) : - m_outline(), - m_clipper(m_outline), - m_filling_rule(fill_non_zero), - m_auto_close(true), - m_start_x(0), - m_start_y(0), - m_status(status_initial) - { - gamma(gamma_function); - } - - //-------------------------------------------------------------------- - void reset(); - void reset_clipping(); - void clip_box(double x1, double y1, double x2, double y2); - void filling_rule(filling_rule_e filling_rule); - void auto_close(bool flag) { m_auto_close = flag; } - - //-------------------------------------------------------------------- - template void gamma(const GammaF& gamma_function) - { - int i; - for(i = 0; i < aa_scale; i++) - { - m_gamma[i] = uround(gamma_function(double(i) / aa_mask) * aa_mask); - } - } - - //-------------------------------------------------------------------- - unsigned apply_gamma(unsigned cover) const - { - return m_gamma[cover]; - } - - //-------------------------------------------------------------------- - void move_to(int x, int y); - void line_to(int x, int y); - void move_to_d(double x, double y); - void line_to_d(double x, double y); - void close_polygon(); - void add_vertex(double x, double y, unsigned cmd); - - void edge(int x1, int y1, int x2, int y2); - void edge_d(double x1, double y1, double x2, double y2); - - //------------------------------------------------------------------- - template - void add_path(VertexSource& vs, unsigned path_id=0) - { - double x; - double y; - - unsigned cmd; - vs.rewind(path_id); - if(m_outline.sorted()) reset(); - while(!is_stop(cmd = vs.vertex(&x, &y))) - { - add_vertex(x, y, cmd); - } - } - - //-------------------------------------------------------------------- - int min_x() const { return m_outline.min_x(); } - int min_y() const { return m_outline.min_y(); } - int max_x() const { return m_outline.max_x(); } - int max_y() const { return m_outline.max_y(); } - - //-------------------------------------------------------------------- - void sort(); - bool rewind_scanlines(); - bool navigate_scanline(int y); - - //-------------------------------------------------------------------- - AGG_INLINE unsigned calculate_alpha(int area) const - { - int cover = area >> (poly_subpixel_shift*2 + 1 - aa_shift); - - if(cover < 0) cover = -cover; - if(m_filling_rule == fill_even_odd) - { - cover &= aa_mask2; - if(cover > aa_scale) - { - cover = aa_scale2 - cover; - } - } - if(cover > aa_mask) cover = aa_mask; - return m_gamma[cover]; - } - - //-------------------------------------------------------------------- - template bool sweep_scanline(Scanline& sl) - { - for(;;) - { - if(m_scan_y > m_outline.max_y()) return false; - sl.reset_spans(); - unsigned num_cells = m_outline.scanline_num_cells(m_scan_y); - const cell_aa* const* cells = m_outline.scanline_cells(m_scan_y); - int cover = 0; - - while(num_cells) - { - const cell_aa* cur_cell = *cells; - int x = cur_cell->x; - int area = cur_cell->area; - unsigned alpha; - - cover += cur_cell->cover; - - //accumulate all cells with the same X - while(--num_cells) - { - cur_cell = *++cells; - if(cur_cell->x != x) break; - area += cur_cell->area; - cover += cur_cell->cover; - } - - if(area) - { - alpha = calculate_alpha((cover << (poly_subpixel_shift + 1)) - area); - if(alpha) - { - sl.add_cell(x, alpha); - } - x++; - } - - if(num_cells && cur_cell->x > x) - { - alpha = calculate_alpha(cover << (poly_subpixel_shift + 1)); - if(alpha) - { - sl.add_span(x, cur_cell->x - x, alpha); - } - } - } - - if(sl.num_spans()) break; - ++m_scan_y; - } - - sl.finalize(m_scan_y); - ++m_scan_y; - return true; - } - - //-------------------------------------------------------------------- - bool hit_test(int tx, int ty); - - - private: - //-------------------------------------------------------------------- - // Disable copying - rasterizer_scanline_aa(const rasterizer_scanline_aa&); - const rasterizer_scanline_aa& - operator = (const rasterizer_scanline_aa&); - - private: - rasterizer_cells_aa m_outline; - clip_type m_clipper; - int m_gamma[aa_scale]; - filling_rule_e m_filling_rule; - bool m_auto_close; - coord_type m_start_x; - coord_type m_start_y; - unsigned m_status; - int m_scan_y; - }; - - - - - - - - - - - - - //------------------------------------------------------------------------ - template - void rasterizer_scanline_aa::reset() - { - m_outline.reset(); - m_status = status_initial; - } - - //------------------------------------------------------------------------ - template - void rasterizer_scanline_aa::filling_rule(filling_rule_e filling_rule) - { - m_filling_rule = filling_rule; - } - - //------------------------------------------------------------------------ - template - void rasterizer_scanline_aa::clip_box(double x1, double y1, - double x2, double y2) - { - reset(); - m_clipper.clip_box(conv_type::upscale(x1), conv_type::upscale(y1), - conv_type::upscale(x2), conv_type::upscale(y2)); - } - - //------------------------------------------------------------------------ - template - void rasterizer_scanline_aa::reset_clipping() - { - reset(); - m_clipper.reset_clipping(); - } - - //------------------------------------------------------------------------ - template - void rasterizer_scanline_aa::close_polygon() - { - if(m_status == status_line_to) - { - m_clipper.line_to(m_outline, m_start_x, m_start_y); - m_status = status_closed; - } - } - - //------------------------------------------------------------------------ - template - void rasterizer_scanline_aa::move_to(int x, int y) - { - if(m_outline.sorted()) reset(); - if(m_auto_close) close_polygon(); - m_clipper.move_to(m_start_x = conv_type::downscale(x), - m_start_y = conv_type::downscale(y)); - m_status = status_move_to; - } - - //------------------------------------------------------------------------ - template - void rasterizer_scanline_aa::line_to(int x, int y) - { - m_clipper.line_to(m_outline, - conv_type::downscale(x), - conv_type::downscale(y)); - m_status = status_line_to; - } - - //------------------------------------------------------------------------ - template - void rasterizer_scanline_aa::move_to_d(double x, double y) - { - if(m_outline.sorted()) reset(); - if(m_auto_close) close_polygon(); - m_clipper.move_to(m_start_x = conv_type::upscale(x), - m_start_y = conv_type::upscale(y)); - m_status = status_move_to; - } - - //------------------------------------------------------------------------ - template - void rasterizer_scanline_aa::line_to_d(double x, double y) - { - m_clipper.line_to(m_outline, - conv_type::upscale(x), - conv_type::upscale(y)); - m_status = status_line_to; - } - - //------------------------------------------------------------------------ - template - void rasterizer_scanline_aa::add_vertex(double x, double y, unsigned cmd) - { - if(is_move_to(cmd)) - { - move_to_d(x, y); - } - else - if(is_vertex(cmd)) - { - line_to_d(x, y); - } - else - if(is_close(cmd)) - { - close_polygon(); - } - } - - //------------------------------------------------------------------------ - template - void rasterizer_scanline_aa::edge(int x1, int y1, int x2, int y2) - { - if(m_outline.sorted()) reset(); - m_clipper.move_to(conv_type::downscale(x1), conv_type::downscale(y1)); - m_clipper.line_to(m_outline, - conv_type::downscale(x2), - conv_type::downscale(y2)); - m_status = status_move_to; - } - - //------------------------------------------------------------------------ - template - void rasterizer_scanline_aa::edge_d(double x1, double y1, - double x2, double y2) - { - if(m_outline.sorted()) reset(); - m_clipper.move_to(conv_type::upscale(x1), conv_type::upscale(y1)); - m_clipper.line_to(m_outline, - conv_type::upscale(x2), - conv_type::upscale(y2)); - m_status = status_move_to; - } - - //------------------------------------------------------------------------ - template - void rasterizer_scanline_aa::sort() - { - if(m_auto_close) close_polygon(); - m_outline.sort_cells(); - } - - //------------------------------------------------------------------------ - template - AGG_INLINE bool rasterizer_scanline_aa::rewind_scanlines() - { - if(m_auto_close) close_polygon(); - m_outline.sort_cells(); - if(m_outline.total_cells() == 0) - { - return false; - } - m_scan_y = m_outline.min_y(); - return true; - } - - - //------------------------------------------------------------------------ - template - AGG_INLINE bool rasterizer_scanline_aa::navigate_scanline(int y) - { - if(m_auto_close) close_polygon(); - m_outline.sort_cells(); - if(m_outline.total_cells() == 0 || - y < m_outline.min_y() || - y > m_outline.max_y()) - { - return false; - } - m_scan_y = y; - return true; - } - - //------------------------------------------------------------------------ - template - bool rasterizer_scanline_aa::hit_test(int tx, int ty) - { - if(!navigate_scanline(ty)) return false; - scanline_hit_test sl(tx); - sweep_scanline(sl); - return sl.hit(); - } - - - -} - - - -#endif - diff --git a/desmume/src/windows/agg/include/agg_rasterizer_sl_clip.h b/desmume/src/windows/agg/include/agg_rasterizer_sl_clip.h deleted file mode 100644 index c11e6da76..000000000 --- a/desmume/src/windows/agg/include/agg_rasterizer_sl_clip.h +++ /dev/null @@ -1,361 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_RASTERIZER_SL_CLIP_INCLUDED -#define AGG_RASTERIZER_SL_CLIP_INCLUDED - -#include "agg_clip_liang_barsky.h" - -namespace agg -{ - //--------------------------------------------------------poly_max_coord_e - enum poly_max_coord_e - { - poly_max_coord = (1 << 30) - 1 //----poly_max_coord - }; - - //------------------------------------------------------------ras_conv_int - struct ras_conv_int - { - typedef int coord_type; - static AGG_INLINE int mul_div(double a, double b, double c) - { - return iround(a * b / c); - } - static int xi(int v) { return v; } - static int yi(int v) { return v; } - static int upscale(double v) { return iround(v * poly_subpixel_scale); } - static int downscale(int v) { return v; } - }; - - //--------------------------------------------------------ras_conv_int_sat - struct ras_conv_int_sat - { - typedef int coord_type; - static AGG_INLINE int mul_div(double a, double b, double c) - { - return saturation::iround(a * b / c); - } - static int xi(int v) { return v; } - static int yi(int v) { return v; } - static int upscale(double v) - { - return saturation::iround(v * poly_subpixel_scale); - } - static int downscale(int v) { return v; } - }; - - //---------------------------------------------------------ras_conv_int_3x - struct ras_conv_int_3x - { - typedef int coord_type; - static AGG_INLINE int mul_div(double a, double b, double c) - { - return iround(a * b / c); - } - static int xi(int v) { return v * 3; } - static int yi(int v) { return v; } - static int upscale(double v) { return iround(v * poly_subpixel_scale); } - static int downscale(int v) { return v; } - }; - - //-----------------------------------------------------------ras_conv_dbl - struct ras_conv_dbl - { - typedef double coord_type; - static AGG_INLINE double mul_div(double a, double b, double c) - { - return a * b / c; - } - static int xi(double v) { return iround(v * poly_subpixel_scale); } - static int yi(double v) { return iround(v * poly_subpixel_scale); } - static double upscale(double v) { return v; } - static double downscale(int v) { return v / double(poly_subpixel_scale); } - }; - - //--------------------------------------------------------ras_conv_dbl_3x - struct ras_conv_dbl_3x - { - typedef double coord_type; - static AGG_INLINE double mul_div(double a, double b, double c) - { - return a * b / c; - } - static int xi(double v) { return iround(v * poly_subpixel_scale * 3); } - static int yi(double v) { return iround(v * poly_subpixel_scale); } - static double upscale(double v) { return v; } - static double downscale(int v) { return v / double(poly_subpixel_scale); } - }; - - - - - - //------------------------------------------------------rasterizer_sl_clip - template class rasterizer_sl_clip - { - public: - typedef Conv conv_type; - typedef typename Conv::coord_type coord_type; - typedef rect_base rect_type; - - //-------------------------------------------------------------------- - rasterizer_sl_clip() : - m_clip_box(0,0,0,0), - m_x1(0), - m_y1(0), - m_f1(0), - m_clipping(false) - {} - - //-------------------------------------------------------------------- - void reset_clipping() - { - m_clipping = false; - } - - //-------------------------------------------------------------------- - void clip_box(coord_type x1, coord_type y1, coord_type x2, coord_type y2) - { - m_clip_box = rect_type(x1, y1, x2, y2); - m_clip_box.normalize(); - m_clipping = true; - } - - //-------------------------------------------------------------------- - void move_to(coord_type x1, coord_type y1) - { - m_x1 = x1; - m_y1 = y1; - if(m_clipping) m_f1 = clipping_flags(x1, y1, m_clip_box); - } - - private: - //------------------------------------------------------------------------ - template - AGG_INLINE void line_clip_y(Rasterizer& ras, - coord_type x1, coord_type y1, - coord_type x2, coord_type y2, - unsigned f1, unsigned f2) const - { - f1 &= 10; - f2 &= 10; - if((f1 | f2) == 0) - { - // Fully visible - ras.line(Conv::xi(x1), Conv::yi(y1), Conv::xi(x2), Conv::yi(y2)); - } - else - { - if(f1 == f2) - { - // Invisible by Y - return; - } - - coord_type tx1 = x1; - coord_type ty1 = y1; - coord_type tx2 = x2; - coord_type ty2 = y2; - - if(f1 & 8) // y1 < clip.y1 - { - tx1 = x1 + Conv::mul_div(m_clip_box.y1-y1, x2-x1, y2-y1); - ty1 = m_clip_box.y1; - } - - if(f1 & 2) // y1 > clip.y2 - { - tx1 = x1 + Conv::mul_div(m_clip_box.y2-y1, x2-x1, y2-y1); - ty1 = m_clip_box.y2; - } - - if(f2 & 8) // y2 < clip.y1 - { - tx2 = x1 + Conv::mul_div(m_clip_box.y1-y1, x2-x1, y2-y1); - ty2 = m_clip_box.y1; - } - - if(f2 & 2) // y2 > clip.y2 - { - tx2 = x1 + Conv::mul_div(m_clip_box.y2-y1, x2-x1, y2-y1); - ty2 = m_clip_box.y2; - } - ras.line(Conv::xi(tx1), Conv::yi(ty1), - Conv::xi(tx2), Conv::yi(ty2)); - } - } - - - public: - //-------------------------------------------------------------------- - template - void line_to(Rasterizer& ras, coord_type x2, coord_type y2) - { - if(m_clipping) - { - unsigned f2 = clipping_flags(x2, y2, m_clip_box); - - if((m_f1 & 10) == (f2 & 10) && (m_f1 & 10) != 0) - { - // Invisible by Y - m_x1 = x2; - m_y1 = y2; - m_f1 = f2; - return; - } - - coord_type x1 = m_x1; - coord_type y1 = m_y1; - unsigned f1 = m_f1; - coord_type y3, y4; - unsigned f3, f4; - - switch(((f1 & 5) << 1) | (f2 & 5)) - { - case 0: // Visible by X - line_clip_y(ras, x1, y1, x2, y2, f1, f2); - break; - - case 1: // x2 > clip.x2 - y3 = y1 + Conv::mul_div(m_clip_box.x2-x1, y2-y1, x2-x1); - f3 = clipping_flags_y(y3, m_clip_box); - line_clip_y(ras, x1, y1, m_clip_box.x2, y3, f1, f3); - line_clip_y(ras, m_clip_box.x2, y3, m_clip_box.x2, y2, f3, f2); - break; - - case 2: // x1 > clip.x2 - y3 = y1 + Conv::mul_div(m_clip_box.x2-x1, y2-y1, x2-x1); - f3 = clipping_flags_y(y3, m_clip_box); - line_clip_y(ras, m_clip_box.x2, y1, m_clip_box.x2, y3, f1, f3); - line_clip_y(ras, m_clip_box.x2, y3, x2, y2, f3, f2); - break; - - case 3: // x1 > clip.x2 && x2 > clip.x2 - line_clip_y(ras, m_clip_box.x2, y1, m_clip_box.x2, y2, f1, f2); - break; - - case 4: // x2 < clip.x1 - y3 = y1 + Conv::mul_div(m_clip_box.x1-x1, y2-y1, x2-x1); - f3 = clipping_flags_y(y3, m_clip_box); - line_clip_y(ras, x1, y1, m_clip_box.x1, y3, f1, f3); - line_clip_y(ras, m_clip_box.x1, y3, m_clip_box.x1, y2, f3, f2); - break; - - case 6: // x1 > clip.x2 && x2 < clip.x1 - y3 = y1 + Conv::mul_div(m_clip_box.x2-x1, y2-y1, x2-x1); - y4 = y1 + Conv::mul_div(m_clip_box.x1-x1, y2-y1, x2-x1); - f3 = clipping_flags_y(y3, m_clip_box); - f4 = clipping_flags_y(y4, m_clip_box); - line_clip_y(ras, m_clip_box.x2, y1, m_clip_box.x2, y3, f1, f3); - line_clip_y(ras, m_clip_box.x2, y3, m_clip_box.x1, y4, f3, f4); - line_clip_y(ras, m_clip_box.x1, y4, m_clip_box.x1, y2, f4, f2); - break; - - case 8: // x1 < clip.x1 - y3 = y1 + Conv::mul_div(m_clip_box.x1-x1, y2-y1, x2-x1); - f3 = clipping_flags_y(y3, m_clip_box); - line_clip_y(ras, m_clip_box.x1, y1, m_clip_box.x1, y3, f1, f3); - line_clip_y(ras, m_clip_box.x1, y3, x2, y2, f3, f2); - break; - - case 9: // x1 < clip.x1 && x2 > clip.x2 - y3 = y1 + Conv::mul_div(m_clip_box.x1-x1, y2-y1, x2-x1); - y4 = y1 + Conv::mul_div(m_clip_box.x2-x1, y2-y1, x2-x1); - f3 = clipping_flags_y(y3, m_clip_box); - f4 = clipping_flags_y(y4, m_clip_box); - line_clip_y(ras, m_clip_box.x1, y1, m_clip_box.x1, y3, f1, f3); - line_clip_y(ras, m_clip_box.x1, y3, m_clip_box.x2, y4, f3, f4); - line_clip_y(ras, m_clip_box.x2, y4, m_clip_box.x2, y2, f4, f2); - break; - - case 12: // x1 < clip.x1 && x2 < clip.x1 - line_clip_y(ras, m_clip_box.x1, y1, m_clip_box.x1, y2, f1, f2); - break; - } - m_f1 = f2; - } - else - { - ras.line(Conv::xi(m_x1), Conv::yi(m_y1), - Conv::xi(x2), Conv::yi(y2)); - } - m_x1 = x2; - m_y1 = y2; - } - - - private: - rect_type m_clip_box; - coord_type m_x1; - coord_type m_y1; - unsigned m_f1; - bool m_clipping; - }; - - - - - //---------------------------------------------------rasterizer_sl_no_clip - class rasterizer_sl_no_clip - { - public: - typedef ras_conv_int conv_type; - typedef int coord_type; - - rasterizer_sl_no_clip() : m_x1(0), m_y1(0) {} - - void reset_clipping() {} - void clip_box(coord_type x1, coord_type y1, coord_type x2, coord_type y2) {} - void move_to(coord_type x1, coord_type y1) { m_x1 = x1; m_y1 = y1; } - - template - void line_to(Rasterizer& ras, coord_type x2, coord_type y2) - { - ras.line(m_x1, m_y1, x2, y2); - m_x1 = x2; - m_y1 = y2; - } - - private: - int m_x1, m_y1; - }; - - - // -----rasterizer_sl_clip_int - // -----rasterizer_sl_clip_int_sat - // -----rasterizer_sl_clip_int_3x - // -----rasterizer_sl_clip_dbl - // -----rasterizer_sl_clip_dbl_3x - //------------------------------------------------------------------------ - typedef rasterizer_sl_clip rasterizer_sl_clip_int; - typedef rasterizer_sl_clip rasterizer_sl_clip_int_sat; - typedef rasterizer_sl_clip rasterizer_sl_clip_int_3x; - typedef rasterizer_sl_clip rasterizer_sl_clip_dbl; - typedef rasterizer_sl_clip rasterizer_sl_clip_dbl_3x; - - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_renderer_base.h b/desmume/src/windows/agg/include/agg_renderer_base.h deleted file mode 100644 index 9d9c1be96..000000000 --- a/desmume/src/windows/agg/include/agg_renderer_base.h +++ /dev/null @@ -1,723 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_RENDERER_BASE_INCLUDED -#define AGG_RENDERER_BASE_INCLUDED - -#include "agg_basics.h" -#include "agg_rendering_buffer.h" - -namespace agg -{ - - //-----------------------------------------------------------renderer_base - template class renderer_base - { - public: - typedef PixelFormat pixfmt_type; - typedef typename pixfmt_type::color_type color_type; - typedef typename pixfmt_type::row_data row_data; - - //-------------------------------------------------------------------- - renderer_base() : m_ren(0), m_clip_box(1, 1, 0, 0) {} - explicit renderer_base(pixfmt_type& ren) : - m_ren(&ren), - m_clip_box(0, 0, ren.width() - 1, ren.height() - 1) - {} - void attach(pixfmt_type& ren) - { - m_ren = &ren; - m_clip_box = rect_i(0, 0, ren.width() - 1, ren.height() - 1); - } - - //-------------------------------------------------------------------- - const pixfmt_type& ren() const { return *m_ren; } - pixfmt_type& ren() { return *m_ren; } - - //-------------------------------------------------------------------- - unsigned width() const { return m_ren->width(); } - unsigned height() const { return m_ren->height(); } - - //-------------------------------------------------------------------- - bool clip_box(int x1, int y1, int x2, int y2) - { - rect_i cb(x1, y1, x2, y2); - cb.normalize(); - if(cb.clip(rect_i(0, 0, width() - 1, height() - 1))) - { - m_clip_box = cb; - return true; - } - m_clip_box.x1 = 1; - m_clip_box.y1 = 1; - m_clip_box.x2 = 0; - m_clip_box.y2 = 0; - return false; - } - - //-------------------------------------------------------------------- - void reset_clipping(bool visibility) - { - if(visibility) - { - m_clip_box.x1 = 0; - m_clip_box.y1 = 0; - m_clip_box.x2 = width() - 1; - m_clip_box.y2 = height() - 1; - } - else - { - m_clip_box.x1 = 1; - m_clip_box.y1 = 1; - m_clip_box.x2 = 0; - m_clip_box.y2 = 0; - } - } - - //-------------------------------------------------------------------- - void clip_box_naked(int x1, int y1, int x2, int y2) - { - m_clip_box.x1 = x1; - m_clip_box.y1 = y1; - m_clip_box.x2 = x2; - m_clip_box.y2 = y2; - } - - //-------------------------------------------------------------------- - bool inbox(int x, int y) const - { - return x >= m_clip_box.x1 && y >= m_clip_box.y1 && - x <= m_clip_box.x2 && y <= m_clip_box.y2; - } - - //-------------------------------------------------------------------- - const rect_i& clip_box() const { return m_clip_box; } - int xmin() const { return m_clip_box.x1; } - int ymin() const { return m_clip_box.y1; } - int xmax() const { return m_clip_box.x2; } - int ymax() const { return m_clip_box.y2; } - - //-------------------------------------------------------------------- - const rect_i& bounding_clip_box() const { return m_clip_box; } - int bounding_xmin() const { return m_clip_box.x1; } - int bounding_ymin() const { return m_clip_box.y1; } - int bounding_xmax() const { return m_clip_box.x2; } - int bounding_ymax() const { return m_clip_box.y2; } - - //-------------------------------------------------------------------- - void clear(const color_type& c) - { - unsigned y; - if(width()) - { - for(y = 0; y < height(); y++) - { - m_ren->copy_hline(0, y, width(), c); - } - } - } - - - //-------------------------------------------------------------------- - void copy_pixel(int x, int y, const color_type& c) - { - if(inbox(x, y)) - { - m_ren->copy_pixel(x, y, c); - } - } - - //-------------------------------------------------------------------- - void blend_pixel(int x, int y, const color_type& c, cover_type cover) - { - if(inbox(x, y)) - { - m_ren->blend_pixel(x, y, c, cover); - } - } - - //-------------------------------------------------------------------- - color_type pixel(int x, int y) const - { - return inbox(x, y) ? - m_ren->pixel(x, y) : - color_type::no_color(); - } - - //-------------------------------------------------------------------- - void copy_hline(int x1, int y, int x2, const color_type& c) - { - if(x1 > x2) { int t = x2; x2 = x1; x1 = t; } - if(y > ymax()) return; - if(y < ymin()) return; - if(x1 > xmax()) return; - if(x2 < xmin()) return; - - if(x1 < xmin()) x1 = xmin(); - if(x2 > xmax()) x2 = xmax(); - - m_ren->copy_hline(x1, y, x2 - x1 + 1, c); - } - - //-------------------------------------------------------------------- - void copy_vline(int x, int y1, int y2, const color_type& c) - { - if(y1 > y2) { int t = y2; y2 = y1; y1 = t; } - if(x > xmax()) return; - if(x < xmin()) return; - if(y1 > ymax()) return; - if(y2 < ymin()) return; - - if(y1 < ymin()) y1 = ymin(); - if(y2 > ymax()) y2 = ymax(); - - m_ren->copy_vline(x, y1, y2 - y1 + 1, c); - } - - //-------------------------------------------------------------------- - void blend_hline(int x1, int y, int x2, - const color_type& c, cover_type cover) - { - if(x1 > x2) { int t = x2; x2 = x1; x1 = t; } - if(y > ymax()) return; - if(y < ymin()) return; - if(x1 > xmax()) return; - if(x2 < xmin()) return; - - if(x1 < xmin()) x1 = xmin(); - if(x2 > xmax()) x2 = xmax(); - - m_ren->blend_hline(x1, y, x2 - x1 + 1, c, cover); - } - - //-------------------------------------------------------------------- - void blend_vline(int x, int y1, int y2, - const color_type& c, cover_type cover) - { - if(y1 > y2) { int t = y2; y2 = y1; y1 = t; } - if(x > xmax()) return; - if(x < xmin()) return; - if(y1 > ymax()) return; - if(y2 < ymin()) return; - - if(y1 < ymin()) y1 = ymin(); - if(y2 > ymax()) y2 = ymax(); - - m_ren->blend_vline(x, y1, y2 - y1 + 1, c, cover); - } - - - //-------------------------------------------------------------------- - void copy_bar(int x1, int y1, int x2, int y2, const color_type& c) - { - rect_i rc(x1, y1, x2, y2); - rc.normalize(); - if(rc.clip(clip_box())) - { - int y; - for(y = rc.y1; y <= rc.y2; y++) - { - m_ren->copy_hline(rc.x1, y, unsigned(rc.x2 - rc.x1 + 1), c); - } - } - } - - //-------------------------------------------------------------------- - void blend_bar(int x1, int y1, int x2, int y2, - const color_type& c, cover_type cover) - { - rect_i rc(x1, y1, x2, y2); - rc.normalize(); - if(rc.clip(clip_box())) - { - int y; - for(y = rc.y1; y <= rc.y2; y++) - { - m_ren->blend_hline(rc.x1, - y, - unsigned(rc.x2 - rc.x1 + 1), - c, - cover); - } - } - } - - //-------------------------------------------------------------------- - void blend_solid_hspan(int x, int y, int len, - const color_type& c, - const cover_type* covers) - { - if(y > ymax()) return; - if(y < ymin()) return; - - if(x < xmin()) - { - len -= xmin() - x; - if(len <= 0) return; - covers += xmin() - x; - x = xmin(); - } - if(x + len > xmax()) - { - len = xmax() - x + 1; - if(len <= 0) return; - } - m_ren->blend_solid_hspan(x, y, len, c, covers); - } - - //-------------------------------------------------------------------- - void blend_solid_vspan(int x, int y, int len, - const color_type& c, - const cover_type* covers) - { - if(x > xmax()) return; - if(x < xmin()) return; - - if(y < ymin()) - { - len -= ymin() - y; - if(len <= 0) return; - covers += ymin() - y; - y = ymin(); - } - if(y + len > ymax()) - { - len = ymax() - y + 1; - if(len <= 0) return; - } - m_ren->blend_solid_vspan(x, y, len, c, covers); - } - - - //-------------------------------------------------------------------- - void copy_color_hspan(int x, int y, int len, const color_type* colors) - { - if(y > ymax()) return; - if(y < ymin()) return; - - if(x < xmin()) - { - int d = xmin() - x; - len -= d; - if(len <= 0) return; - colors += d; - x = xmin(); - } - if(x + len > xmax()) - { - len = xmax() - x + 1; - if(len <= 0) return; - } - m_ren->copy_color_hspan(x, y, len, colors); - } - - - //-------------------------------------------------------------------- - void copy_color_vspan(int x, int y, int len, const color_type* colors) - { - if(x > xmax()) return; - if(x < xmin()) return; - - if(y < ymin()) - { - int d = ymin() - y; - len -= d; - if(len <= 0) return; - colors += d; - y = ymin(); - } - if(y + len > ymax()) - { - len = ymax() - y + 1; - if(len <= 0) return; - } - m_ren->copy_color_vspan(x, y, len, colors); - } - - - //-------------------------------------------------------------------- - void blend_color_hspan(int x, int y, int len, - const color_type* colors, - const cover_type* covers, - cover_type cover = agg::cover_full) - { - if(y > ymax()) return; - if(y < ymin()) return; - - if(x < xmin()) - { - int d = xmin() - x; - len -= d; - if(len <= 0) return; - if(covers) covers += d; - colors += d; - x = xmin(); - } - if(x + len > xmax()) - { - len = xmax() - x + 1; - if(len <= 0) return; - } - m_ren->blend_color_hspan(x, y, len, colors, covers, cover); - } - - //-------------------------------------------------------------------- - void blend_color_vspan(int x, int y, int len, - const color_type* colors, - const cover_type* covers, - cover_type cover = agg::cover_full) - { - if(x > xmax()) return; - if(x < xmin()) return; - - if(y < ymin()) - { - int d = ymin() - y; - len -= d; - if(len <= 0) return; - if(covers) covers += d; - colors += d; - y = ymin(); - } - if(y + len > ymax()) - { - len = ymax() - y + 1; - if(len <= 0) return; - } - m_ren->blend_color_vspan(x, y, len, colors, covers, cover); - } - - //-------------------------------------------------------------------- - rect_i clip_rect_area(rect_i& dst, rect_i& src, int wsrc, int hsrc) const - { - rect_i rc(0,0,0,0); - rect_i cb = clip_box(); - ++cb.x2; - ++cb.y2; - - if(src.x1 < 0) - { - dst.x1 -= src.x1; - src.x1 = 0; - } - if(src.y1 < 0) - { - dst.y1 -= src.y1; - src.y1 = 0; - } - - if(src.x2 > wsrc) src.x2 = wsrc; - if(src.y2 > hsrc) src.y2 = hsrc; - - if(dst.x1 < cb.x1) - { - src.x1 += cb.x1 - dst.x1; - dst.x1 = cb.x1; - } - if(dst.y1 < cb.y1) - { - src.y1 += cb.y1 - dst.y1; - dst.y1 = cb.y1; - } - - if(dst.x2 > cb.x2) dst.x2 = cb.x2; - if(dst.y2 > cb.y2) dst.y2 = cb.y2; - - rc.x2 = dst.x2 - dst.x1; - rc.y2 = dst.y2 - dst.y1; - - if(rc.x2 > src.x2 - src.x1) rc.x2 = src.x2 - src.x1; - if(rc.y2 > src.y2 - src.y1) rc.y2 = src.y2 - src.y1; - return rc; - } - - //-------------------------------------------------------------------- - template - void copy_from(const RenBuf& src, - const rect_i* rect_src_ptr = 0, - int dx = 0, - int dy = 0) - { - rect_i rsrc(0, 0, src.width(), src.height()); - if(rect_src_ptr) - { - rsrc.x1 = rect_src_ptr->x1; - rsrc.y1 = rect_src_ptr->y1; - rsrc.x2 = rect_src_ptr->x2 + 1; - rsrc.y2 = rect_src_ptr->y2 + 1; - } - - // Version with xdst, ydst (absolute positioning) - //rect_i rdst(xdst, ydst, xdst + rsrc.x2 - rsrc.x1, ydst + rsrc.y2 - rsrc.y1); - - // Version with dx, dy (relative positioning) - rect_i rdst(rsrc.x1 + dx, rsrc.y1 + dy, rsrc.x2 + dx, rsrc.y2 + dy); - - rect_i rc = clip_rect_area(rdst, rsrc, src.width(), src.height()); - - if(rc.x2 > 0) - { - int incy = 1; - if(rdst.y1 > rsrc.y1) - { - rsrc.y1 += rc.y2 - 1; - rdst.y1 += rc.y2 - 1; - incy = -1; - } - while(rc.y2 > 0) - { - m_ren->copy_from(src, - rdst.x1, rdst.y1, - rsrc.x1, rsrc.y1, - rc.x2); - rdst.y1 += incy; - rsrc.y1 += incy; - --rc.y2; - } - } - } - - //-------------------------------------------------------------------- - template - void blend_from(const SrcPixelFormatRenderer& src, - const rect_i* rect_src_ptr = 0, - int dx = 0, - int dy = 0, - cover_type cover = agg::cover_full) - { - rect_i rsrc(0, 0, src.width(), src.height()); - if(rect_src_ptr) - { - rsrc.x1 = rect_src_ptr->x1; - rsrc.y1 = rect_src_ptr->y1; - rsrc.x2 = rect_src_ptr->x2 + 1; - rsrc.y2 = rect_src_ptr->y2 + 1; - } - - // Version with xdst, ydst (absolute positioning) - //rect_i rdst(xdst, ydst, xdst + rsrc.x2 - rsrc.x1, ydst + rsrc.y2 - rsrc.y1); - - // Version with dx, dy (relative positioning) - rect_i rdst(rsrc.x1 + dx, rsrc.y1 + dy, rsrc.x2 + dx, rsrc.y2 + dy); - rect_i rc = clip_rect_area(rdst, rsrc, src.width(), src.height()); - - if(rc.x2 > 0) - { - int incy = 1; - if(rdst.y1 > rsrc.y1) - { - rsrc.y1 += rc.y2 - 1; - rdst.y1 += rc.y2 - 1; - incy = -1; - } - while(rc.y2 > 0) - { - typename SrcPixelFormatRenderer::row_data rw = src.row(rsrc.y1); - if(rw.ptr) - { - int x1src = rsrc.x1; - int x1dst = rdst.x1; - int len = rc.x2; - if(rw.x1 > x1src) - { - x1dst += rw.x1 - x1src; - len -= rw.x1 - x1src; - x1src = rw.x1; - } - if(len > 0) - { - if(x1src + len-1 > rw.x2) - { - len -= x1src + len - rw.x2 - 1; - } - if(len > 0) - { - m_ren->blend_from(src, - x1dst, rdst.y1, - x1src, rsrc.y1, - len, - cover); - } - } - } - rdst.y1 += incy; - rsrc.y1 += incy; - --rc.y2; - } - } - } - - //-------------------------------------------------------------------- - template - void blend_from_color(const SrcPixelFormatRenderer& src, - const color_type& color, - const rect_i* rect_src_ptr = 0, - int dx = 0, - int dy = 0, - cover_type cover = agg::cover_full) - { - rect_i rsrc(0, 0, src.width(), src.height()); - if(rect_src_ptr) - { - rsrc.x1 = rect_src_ptr->x1; - rsrc.y1 = rect_src_ptr->y1; - rsrc.x2 = rect_src_ptr->x2 + 1; - rsrc.y2 = rect_src_ptr->y2 + 1; - } - - // Version with xdst, ydst (absolute positioning) - //rect_i rdst(xdst, ydst, xdst + rsrc.x2 - rsrc.x1, ydst + rsrc.y2 - rsrc.y1); - - // Version with dx, dy (relative positioning) - rect_i rdst(rsrc.x1 + dx, rsrc.y1 + dy, rsrc.x2 + dx, rsrc.y2 + dy); - rect_i rc = clip_rect_area(rdst, rsrc, src.width(), src.height()); - - if(rc.x2 > 0) - { - int incy = 1; - if(rdst.y1 > rsrc.y1) - { - rsrc.y1 += rc.y2 - 1; - rdst.y1 += rc.y2 - 1; - incy = -1; - } - while(rc.y2 > 0) - { - typename SrcPixelFormatRenderer::row_data rw = src.row(rsrc.y1); - if(rw.ptr) - { - int x1src = rsrc.x1; - int x1dst = rdst.x1; - int len = rc.x2; - if(rw.x1 > x1src) - { - x1dst += rw.x1 - x1src; - len -= rw.x1 - x1src; - x1src = rw.x1; - } - if(len > 0) - { - if(x1src + len-1 > rw.x2) - { - len -= x1src + len - rw.x2 - 1; - } - if(len > 0) - { - m_ren->blend_from_color(src, - color, - x1dst, rdst.y1, - x1src, rsrc.y1, - len, - cover); - } - } - } - rdst.y1 += incy; - rsrc.y1 += incy; - --rc.y2; - } - } - } - - //-------------------------------------------------------------------- - template - void blend_from_lut(const SrcPixelFormatRenderer& src, - const color_type* color_lut, - const rect_i* rect_src_ptr = 0, - int dx = 0, - int dy = 0, - cover_type cover = agg::cover_full) - { - rect_i rsrc(0, 0, src.width(), src.height()); - if(rect_src_ptr) - { - rsrc.x1 = rect_src_ptr->x1; - rsrc.y1 = rect_src_ptr->y1; - rsrc.x2 = rect_src_ptr->x2 + 1; - rsrc.y2 = rect_src_ptr->y2 + 1; - } - - // Version with xdst, ydst (absolute positioning) - //rect_i rdst(xdst, ydst, xdst + rsrc.x2 - rsrc.x1, ydst + rsrc.y2 - rsrc.y1); - - // Version with dx, dy (relative positioning) - rect_i rdst(rsrc.x1 + dx, rsrc.y1 + dy, rsrc.x2 + dx, rsrc.y2 + dy); - rect_i rc = clip_rect_area(rdst, rsrc, src.width(), src.height()); - - if(rc.x2 > 0) - { - int incy = 1; - if(rdst.y1 > rsrc.y1) - { - rsrc.y1 += rc.y2 - 1; - rdst.y1 += rc.y2 - 1; - incy = -1; - } - while(rc.y2 > 0) - { - typename SrcPixelFormatRenderer::row_data rw = src.row(rsrc.y1); - if(rw.ptr) - { - int x1src = rsrc.x1; - int x1dst = rdst.x1; - int len = rc.x2; - if(rw.x1 > x1src) - { - x1dst += rw.x1 - x1src; - len -= rw.x1 - x1src; - x1src = rw.x1; - } - if(len > 0) - { - if(x1src + len-1 > rw.x2) - { - len -= x1src + len - rw.x2 - 1; - } - if(len > 0) - { - m_ren->blend_from_lut(src, - color_lut, - x1dst, rdst.y1, - x1src, rsrc.y1, - len, - cover); - } - } - } - rdst.y1 += incy; - rsrc.y1 += incy; - --rc.y2; - } - } - } - - private: - pixfmt_type* m_ren; - rect_i m_clip_box; - }; - - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_renderer_markers.h b/desmume/src/windows/agg/include/agg_renderer_markers.h deleted file mode 100644 index 40d34da4f..000000000 --- a/desmume/src/windows/agg/include/agg_renderer_markers.h +++ /dev/null @@ -1,711 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_RENDERER_MARKERS_INCLUDED -#define AGG_RENDERER_MARKERS_INCLUDED - -#include "agg_basics.h" -#include "agg_renderer_primitives.h" - -namespace agg -{ - - //---------------------------------------------------------------marker_e - enum marker_e - { - marker_square, - marker_diamond, - marker_circle, - marker_crossed_circle, - marker_semiellipse_left, - marker_semiellipse_right, - marker_semiellipse_up, - marker_semiellipse_down, - marker_triangle_left, - marker_triangle_right, - marker_triangle_up, - marker_triangle_down, - marker_four_rays, - marker_cross, - marker_x, - marker_dash, - marker_dot, - marker_pixel, - - end_of_markers - }; - - - - //--------------------------------------------------------renderer_markers - template class renderer_markers : - public renderer_primitives - { - public: - typedef renderer_primitives base_type; - typedef BaseRenderer base_ren_type; - typedef typename base_ren_type::color_type color_type; - - //-------------------------------------------------------------------- - renderer_markers(base_ren_type& rbuf) : - base_type(rbuf) - {} - - //-------------------------------------------------------------------- - bool visible(int x, int y, int r) const - { - rect_i rc(x-r, y-r, x+y, y+r); - return rc.clip(base_type::ren().bounding_clip_box()); - } - - //-------------------------------------------------------------------- - void square(int x, int y, int r) - { - if(visible(x, y, r)) - { - if(r) base_type::outlined_rectangle(x-r, y-r, x+r, y+r); - else base_type::ren().blend_pixel(x, y, base_type::fill_color(), cover_full); - } - } - - //-------------------------------------------------------------------- - void diamond(int x, int y, int r) - { - if(visible(x, y, r)) - { - if(r) - { - int dy = -r; - int dx = 0; - do - { - base_type::ren().blend_pixel(x - dx, y + dy, base_type::line_color(), cover_full); - base_type::ren().blend_pixel(x + dx, y + dy, base_type::line_color(), cover_full); - base_type::ren().blend_pixel(x - dx, y - dy, base_type::line_color(), cover_full); - base_type::ren().blend_pixel(x + dx, y - dy, base_type::line_color(), cover_full); - - if(dx) - { - base_type::ren().blend_hline(x-dx+1, y+dy, x+dx-1, base_type::fill_color(), cover_full); - base_type::ren().blend_hline(x-dx+1, y-dy, x+dx-1, base_type::fill_color(), cover_full); - } - ++dy; - ++dx; - } - while(dy <= 0); - } - else - { - base_type::ren().blend_pixel(x, y, base_type::fill_color(), cover_full); - } - } - } - - //-------------------------------------------------------------------- - void circle(int x, int y, int r) - { - if(visible(x, y, r)) - { - if(r) base_type::outlined_ellipse(x, y, r, r); - else base_type::ren().blend_pixel(x, y, base_type::fill_color(), cover_full); - } - } - - - - //-------------------------------------------------------------------- - void crossed_circle(int x, int y, int r) - { - if(visible(x, y, r)) - { - if(r) - { - base_type::outlined_ellipse(x, y, r, r); - int r6 = r + (r >> 1); - if(r <= 2) r6++; - r >>= 1; - base_type::ren().blend_hline(x-r6, y, x-r, base_type::line_color(), cover_full); - base_type::ren().blend_hline(x+r, y, x+r6, base_type::line_color(), cover_full); - base_type::ren().blend_vline(x, y-r6, y-r, base_type::line_color(), cover_full); - base_type::ren().blend_vline(x, y+r, y+r6, base_type::line_color(), cover_full); - } - else - { - base_type::ren().blend_pixel(x, y, base_type::fill_color(), cover_full); - } - } - } - - - //------------------------------------------------------------------------ - void semiellipse_left(int x, int y, int r) - { - if(visible(x, y, r)) - { - if(r) - { - int r8 = r * 4 / 5; - int dy = -r; - int dx = 0; - ellipse_bresenham_interpolator ei(r * 3 / 5, r+r8); - do - { - dx += ei.dx(); - dy += ei.dy(); - - base_type::ren().blend_pixel(x + dy, y + dx, base_type::line_color(), cover_full); - base_type::ren().blend_pixel(x + dy, y - dx, base_type::line_color(), cover_full); - - if(ei.dy() && dx) - { - base_type::ren().blend_vline(x+dy, y-dx+1, y+dx-1, base_type::fill_color(), cover_full); - } - ++ei; - } - while(dy < r8); - base_type::ren().blend_vline(x+dy, y-dx, y+dx, base_type::line_color(), cover_full); - } - else - { - base_type::ren().blend_pixel(x, y, base_type::fill_color(), cover_full); - } - } - } - - - //-------------------------------------------------------------------- - void semiellipse_right(int x, int y, int r) - { - if(visible(x, y, r)) - { - if(r) - { - int r8 = r * 4 / 5; - int dy = -r; - int dx = 0; - ellipse_bresenham_interpolator ei(r * 3 / 5, r+r8); - do - { - dx += ei.dx(); - dy += ei.dy(); - - base_type::ren().blend_pixel(x - dy, y + dx, base_type::line_color(), cover_full); - base_type::ren().blend_pixel(x - dy, y - dx, base_type::line_color(), cover_full); - - if(ei.dy() && dx) - { - base_type::ren().blend_vline(x-dy, y-dx+1, y+dx-1, base_type::fill_color(), cover_full); - } - ++ei; - } - while(dy < r8); - base_type::ren().blend_vline(x-dy, y-dx, y+dx, base_type::line_color(), cover_full); - } - else - { - base_type::ren().blend_pixel(x, y, base_type::fill_color(), cover_full); - } - } - } - - - //-------------------------------------------------------------------- - void semiellipse_up(int x, int y, int r) - { - if(visible(x, y, r)) - { - if(r) - { - int r8 = r * 4 / 5; - int dy = -r; - int dx = 0; - ellipse_bresenham_interpolator ei(r * 3 / 5, r+r8); - do - { - dx += ei.dx(); - dy += ei.dy(); - - base_type::ren().blend_pixel(x + dx, y - dy, base_type::line_color(), cover_full); - base_type::ren().blend_pixel(x - dx, y - dy, base_type::line_color(), cover_full); - - if(ei.dy() && dx) - { - base_type::ren().blend_hline(x-dx+1, y-dy, x+dx-1, base_type::fill_color(), cover_full); - } - ++ei; - } - while(dy < r8); - base_type::ren().blend_hline(x-dx, y-dy-1, x+dx, base_type::line_color(), cover_full); - } - else - { - base_type::ren().blend_pixel(x, y, base_type::fill_color(), cover_full); - } - } - } - - - //-------------------------------------------------------------------- - void semiellipse_down(int x, int y, int r) - { - if(visible(x, y, r)) - { - if(r) - { - int r8 = r * 4 / 5; - int dy = -r; - int dx = 0; - ellipse_bresenham_interpolator ei(r * 3 / 5, r+r8); - do - { - dx += ei.dx(); - dy += ei.dy(); - - base_type::ren().blend_pixel(x + dx, y + dy, base_type::line_color(), cover_full); - base_type::ren().blend_pixel(x - dx, y + dy, base_type::line_color(), cover_full); - - if(ei.dy() && dx) - { - base_type::ren().blend_hline(x-dx+1, y+dy, x+dx-1, base_type::fill_color(), cover_full); - } - ++ei; - } - while(dy < r8); - base_type::ren().blend_hline(x-dx, y+dy+1, x+dx, base_type::line_color(), cover_full); - } - else - { - base_type::ren().blend_pixel(x, y, base_type::fill_color(), cover_full); - } - } - } - - - //-------------------------------------------------------------------- - void triangle_left(int x, int y, int r) - { - if(visible(x, y, r)) - { - if(r) - { - int dy = -r; - int dx = 0; - int flip = 0; - int r6 = r * 3 / 5; - do - { - base_type::ren().blend_pixel(x + dy, y - dx, base_type::line_color(), cover_full); - base_type::ren().blend_pixel(x + dy, y + dx, base_type::line_color(), cover_full); - - if(dx) - { - base_type::ren().blend_vline(x+dy, y-dx+1, y+dx-1, base_type::fill_color(), cover_full); - } - ++dy; - dx += flip; - flip ^= 1; - } - while(dy < r6); - base_type::ren().blend_vline(x+dy, y-dx, y+dx, base_type::line_color(), cover_full); - } - else - { - base_type::ren().blend_pixel(x, y, base_type::fill_color(), cover_full); - } - } - } - - - //-------------------------------------------------------------------- - void triangle_right(int x, int y, int r) - { - if(visible(x, y, r)) - { - if(r) - { - int dy = -r; - int dx = 0; - int flip = 0; - int r6 = r * 3 / 5; - do - { - base_type::ren().blend_pixel(x - dy, y - dx, base_type::line_color(), cover_full); - base_type::ren().blend_pixel(x - dy, y + dx, base_type::line_color(), cover_full); - - if(dx) - { - base_type::ren().blend_vline(x-dy, y-dx+1, y+dx-1, base_type::fill_color(), cover_full); - } - ++dy; - dx += flip; - flip ^= 1; - } - while(dy < r6); - base_type::ren().blend_vline(x-dy, y-dx, y+dx, base_type::line_color(), cover_full); - } - else - { - base_type::ren().blend_pixel(x, y, base_type::fill_color(), cover_full); - } - } - } - - - //-------------------------------------------------------------------- - void triangle_up(int x, int y, int r) - { - if(visible(x, y, r)) - { - if(r) - { - int dy = -r; - int dx = 0; - int flip = 0; - int r6 = r * 3 / 5; - do - { - base_type::ren().blend_pixel(x - dx, y - dy, base_type::line_color(), cover_full); - base_type::ren().blend_pixel(x + dx, y - dy, base_type::line_color(), cover_full); - - if(dx) - { - base_type::ren().blend_hline(x-dx+1, y-dy, x+dx-1, base_type::fill_color(), cover_full); - } - ++dy; - dx += flip; - flip ^= 1; - } - while(dy < r6); - base_type::ren().blend_hline(x-dx, y-dy, x+dx, base_type::line_color(), cover_full); - } - else - { - base_type::ren().blend_pixel(x, y, base_type::fill_color(), cover_full); - } - } - } - - - //-------------------------------------------------------------------- - void triangle_down(int x, int y, int r) - { - if(visible(x, y, r)) - { - if(r) - { - int dy = -r; - int dx = 0; - int flip = 0; - int r6 = r * 3 / 5; - do - { - base_type::ren().blend_pixel(x - dx, y + dy, base_type::line_color(), cover_full); - base_type::ren().blend_pixel(x + dx, y + dy, base_type::line_color(), cover_full); - - if(dx) - { - base_type::ren().blend_hline(x-dx+1, y+dy, x+dx-1, base_type::fill_color(), cover_full); - } - ++dy; - dx += flip; - flip ^= 1; - } - while(dy < r6); - base_type::ren().blend_hline(x-dx, y+dy, x+dx, base_type::line_color(), cover_full); - } - else - { - base_type::ren().blend_pixel(x, y, base_type::fill_color(), cover_full); - } - } - } - - - //-------------------------------------------------------------------- - void four_rays(int x, int y, int r) - { - if(visible(x, y, r)) - { - if(r) - { - int dy = -r; - int dx = 0; - int flip = 0; - int r3 = -(r / 3); - do - { - base_type::ren().blend_pixel(x - dx, y + dy, base_type::line_color(), cover_full); - base_type::ren().blend_pixel(x + dx, y + dy, base_type::line_color(), cover_full); - base_type::ren().blend_pixel(x - dx, y - dy, base_type::line_color(), cover_full); - base_type::ren().blend_pixel(x + dx, y - dy, base_type::line_color(), cover_full); - base_type::ren().blend_pixel(x + dy, y - dx, base_type::line_color(), cover_full); - base_type::ren().blend_pixel(x + dy, y + dx, base_type::line_color(), cover_full); - base_type::ren().blend_pixel(x - dy, y - dx, base_type::line_color(), cover_full); - base_type::ren().blend_pixel(x - dy, y + dx, base_type::line_color(), cover_full); - - if(dx) - { - base_type::ren().blend_hline(x-dx+1, y+dy, x+dx-1, base_type::fill_color(), cover_full); - base_type::ren().blend_hline(x-dx+1, y-dy, x+dx-1, base_type::fill_color(), cover_full); - base_type::ren().blend_vline(x+dy, y-dx+1, y+dx-1, base_type::fill_color(), cover_full); - base_type::ren().blend_vline(x-dy, y-dx+1, y+dx-1, base_type::fill_color(), cover_full); - } - ++dy; - dx += flip; - flip ^= 1; - } - while(dy <= r3); - base_type::solid_rectangle(x+r3+1, y+r3+1, x-r3-1, y-r3-1); - } - else - { - base_type::ren().blend_pixel(x, y, base_type::fill_color(), cover_full); - } - } - } - - - //-------------------------------------------------------------------- - void cross(int x, int y, int r) - { - if(visible(x, y, r)) - { - if(r) - { - base_type::ren().blend_vline(x, y-r, y+r, base_type::line_color(), cover_full); - base_type::ren().blend_hline(x-r, y, x+r, base_type::line_color(), cover_full); - } - else - { - base_type::ren().blend_pixel(x, y, base_type::fill_color(), cover_full); - } - } - } - - - //-------------------------------------------------------------------- - void xing(int x, int y, int r) - { - if(visible(x, y, r)) - { - if(r) - { - int dy = -r * 7 / 10; - do - { - base_type::ren().blend_pixel(x + dy, y + dy, base_type::line_color(), cover_full); - base_type::ren().blend_pixel(x - dy, y + dy, base_type::line_color(), cover_full); - base_type::ren().blend_pixel(x + dy, y - dy, base_type::line_color(), cover_full); - base_type::ren().blend_pixel(x - dy, y - dy, base_type::line_color(), cover_full); - ++dy; - } - while(dy < 0); - } - base_type::ren().blend_pixel(x, y, base_type::fill_color(), cover_full); - } - } - - - //-------------------------------------------------------------------- - void dash(int x, int y, int r) - { - if(visible(x, y, r)) - { - if(r) base_type::ren().blend_hline(x-r, y, x+r, base_type::line_color(), cover_full); - else base_type::ren().blend_pixel(x, y, base_type::fill_color(), cover_full); - } - } - - - //-------------------------------------------------------------------- - void dot(int x, int y, int r) - { - if(visible(x, y, r)) - { - if(r) base_type::solid_ellipse(x, y, r, r); - else base_type::ren().blend_pixel(x, y, base_type::fill_color(), cover_full); - } - } - - //-------------------------------------------------------------------- - void pixel(int x, int y, int) - { - base_type::ren().blend_pixel(x, y, base_type::fill_color(), cover_full); - } - - //-------------------------------------------------------------------- - void marker(int x, int y, int r, marker_e type) - { - switch(type) - { - case marker_square: square(x, y, r); break; - case marker_diamond: diamond(x, y, r); break; - case marker_circle: circle(x, y, r); break; - case marker_crossed_circle: crossed_circle(x, y, r); break; - case marker_semiellipse_left: semiellipse_left(x, y, r); break; - case marker_semiellipse_right: semiellipse_right(x, y, r); break; - case marker_semiellipse_up: semiellipse_up(x, y, r); break; - case marker_semiellipse_down: semiellipse_down(x, y, r); break; - case marker_triangle_left: triangle_left(x, y, r); break; - case marker_triangle_right: triangle_right(x, y, r); break; - case marker_triangle_up: triangle_up(x, y, r); break; - case marker_triangle_down: triangle_down(x, y, r); break; - case marker_four_rays: four_rays(x, y, r); break; - case marker_cross: cross(x, y, r); break; - case marker_x: xing(x, y, r); break; - case marker_dash: dash(x, y, r); break; - case marker_dot: dot(x, y, r); break; - case marker_pixel: pixel(x, y, r); break; - } - } - - - //-------------------------------------------------------------------- - template - void markers(int n, const T* x, const T* y, T r, marker_e type) - { - if(n <= 0) return; - if(r == 0) - { - do - { - base_type::ren().blend_pixel(int(*x), int(*y), base_type::fill_color(), cover_full); - ++x; - ++y; - } - while(--n); - return; - } - - switch(type) - { - case marker_square: do { square (int(*x), int(*y), int(r)); ++x; ++y; } while(--n); break; - case marker_diamond: do { diamond (int(*x), int(*y), int(r)); ++x; ++y; } while(--n); break; - case marker_circle: do { circle (int(*x), int(*y), int(r)); ++x; ++y; } while(--n); break; - case marker_crossed_circle: do { crossed_circle (int(*x), int(*y), int(r)); ++x; ++y; } while(--n); break; - case marker_semiellipse_left: do { semiellipse_left (int(*x), int(*y), int(r)); ++x; ++y; } while(--n); break; - case marker_semiellipse_right: do { semiellipse_right(int(*x), int(*y), int(r)); ++x; ++y; } while(--n); break; - case marker_semiellipse_up: do { semiellipse_up (int(*x), int(*y), int(r)); ++x; ++y; } while(--n); break; - case marker_semiellipse_down: do { semiellipse_down (int(*x), int(*y), int(r)); ++x; ++y; } while(--n); break; - case marker_triangle_left: do { triangle_left (int(*x), int(*y), int(r)); ++x; ++y; } while(--n); break; - case marker_triangle_right: do { triangle_right (int(*x), int(*y), int(r)); ++x; ++y; } while(--n); break; - case marker_triangle_up: do { triangle_up (int(*x), int(*y), int(r)); ++x; ++y; } while(--n); break; - case marker_triangle_down: do { triangle_down (int(*x), int(*y), int(r)); ++x; ++y; } while(--n); break; - case marker_four_rays: do { four_rays (int(*x), int(*y), int(r)); ++x; ++y; } while(--n); break; - case marker_cross: do { cross (int(*x), int(*y), int(r)); ++x; ++y; } while(--n); break; - case marker_x: do { xing (int(*x), int(*y), int(r)); ++x; ++y; } while(--n); break; - case marker_dash: do { dash (int(*x), int(*y), int(r)); ++x; ++y; } while(--n); break; - case marker_dot: do { dot (int(*x), int(*y), int(r)); ++x; ++y; } while(--n); break; - case marker_pixel: do { pixel (int(*x), int(*y), int(r)); ++x; ++y; } while(--n); break; - } - } - - //-------------------------------------------------------------------- - template - void markers(int n, const T* x, const T* y, const T* r, marker_e type) - { - if(n <= 0) return; - switch(type) - { - case marker_square: do { square (int(*x), int(*y), int(*r)); ++x; ++y; ++r; } while(--n); break; - case marker_diamond: do { diamond (int(*x), int(*y), int(*r)); ++x; ++y; ++r; } while(--n); break; - case marker_circle: do { circle (int(*x), int(*y), int(*r)); ++x; ++y; ++r; } while(--n); break; - case marker_crossed_circle: do { crossed_circle (int(*x), int(*y), int(*r)); ++x; ++y; ++r; } while(--n); break; - case marker_semiellipse_left: do { semiellipse_left (int(*x), int(*y), int(*r)); ++x; ++y; ++r; } while(--n); break; - case marker_semiellipse_right: do { semiellipse_right(int(*x), int(*y), int(*r)); ++x; ++y; ++r; } while(--n); break; - case marker_semiellipse_up: do { semiellipse_up (int(*x), int(*y), int(*r)); ++x; ++y; ++r; } while(--n); break; - case marker_semiellipse_down: do { semiellipse_down (int(*x), int(*y), int(*r)); ++x; ++y; ++r; } while(--n); break; - case marker_triangle_left: do { triangle_left (int(*x), int(*y), int(*r)); ++x; ++y; ++r; } while(--n); break; - case marker_triangle_right: do { triangle_right (int(*x), int(*y), int(*r)); ++x; ++y; ++r; } while(--n); break; - case marker_triangle_up: do { triangle_up (int(*x), int(*y), int(*r)); ++x; ++y; ++r; } while(--n); break; - case marker_triangle_down: do { triangle_down (int(*x), int(*y), int(*r)); ++x; ++y; ++r; } while(--n); break; - case marker_four_rays: do { four_rays (int(*x), int(*y), int(*r)); ++x; ++y; ++r; } while(--n); break; - case marker_cross: do { cross (int(*x), int(*y), int(*r)); ++x; ++y; ++r; } while(--n); break; - case marker_x: do { xing (int(*x), int(*y), int(*r)); ++x; ++y; ++r; } while(--n); break; - case marker_dash: do { dash (int(*x), int(*y), int(*r)); ++x; ++y; ++r; } while(--n); break; - case marker_dot: do { dot (int(*x), int(*y), int(*r)); ++x; ++y; ++r; } while(--n); break; - case marker_pixel: do { pixel (int(*x), int(*y), int(*r)); ++x; ++y; ++r; } while(--n); break; - } - } - - //-------------------------------------------------------------------- - template - void markers(int n, const T* x, const T* y, const T* r, const color_type* fc, marker_e type) - { - if(n <= 0) return; - switch(type) - { - case marker_square: do { base_type::fill_color(*fc); square (int(*x), int(*y), int(*r)); ++x; ++y; ++r; ++fc; } while(--n); break; - case marker_diamond: do { base_type::fill_color(*fc); diamond (int(*x), int(*y), int(*r)); ++x; ++y; ++r; ++fc; } while(--n); break; - case marker_circle: do { base_type::fill_color(*fc); circle (int(*x), int(*y), int(*r)); ++x; ++y; ++r; ++fc; } while(--n); break; - case marker_crossed_circle: do { base_type::fill_color(*fc); crossed_circle (int(*x), int(*y), int(*r)); ++x; ++y; ++r; ++fc; } while(--n); break; - case marker_semiellipse_left: do { base_type::fill_color(*fc); semiellipse_left (int(*x), int(*y), int(*r)); ++x; ++y; ++r; ++fc; } while(--n); break; - case marker_semiellipse_right: do { base_type::fill_color(*fc); semiellipse_right(int(*x), int(*y), int(*r)); ++x; ++y; ++r; ++fc; } while(--n); break; - case marker_semiellipse_up: do { base_type::fill_color(*fc); semiellipse_up (int(*x), int(*y), int(*r)); ++x; ++y; ++r; ++fc; } while(--n); break; - case marker_semiellipse_down: do { base_type::fill_color(*fc); semiellipse_down (int(*x), int(*y), int(*r)); ++x; ++y; ++r; ++fc; } while(--n); break; - case marker_triangle_left: do { base_type::fill_color(*fc); triangle_left (int(*x), int(*y), int(*r)); ++x; ++y; ++r; ++fc; } while(--n); break; - case marker_triangle_right: do { base_type::fill_color(*fc); triangle_right (int(*x), int(*y), int(*r)); ++x; ++y; ++r; ++fc; } while(--n); break; - case marker_triangle_up: do { base_type::fill_color(*fc); triangle_up (int(*x), int(*y), int(*r)); ++x; ++y; ++r; ++fc; } while(--n); break; - case marker_triangle_down: do { base_type::fill_color(*fc); triangle_down (int(*x), int(*y), int(*r)); ++x; ++y; ++r; ++fc; } while(--n); break; - case marker_four_rays: do { base_type::fill_color(*fc); four_rays (int(*x), int(*y), int(*r)); ++x; ++y; ++r; ++fc; } while(--n); break; - case marker_cross: do { base_type::fill_color(*fc); cross (int(*x), int(*y), int(*r)); ++x; ++y; ++r; ++fc; } while(--n); break; - case marker_x: do { base_type::fill_color(*fc); xing (int(*x), int(*y), int(*r)); ++x; ++y; ++r; ++fc; } while(--n); break; - case marker_dash: do { base_type::fill_color(*fc); dash (int(*x), int(*y), int(*r)); ++x; ++y; ++r; ++fc; } while(--n); break; - case marker_dot: do { base_type::fill_color(*fc); dot (int(*x), int(*y), int(*r)); ++x; ++y; ++r; ++fc; } while(--n); break; - case marker_pixel: do { base_type::fill_color(*fc); pixel (int(*x), int(*y), int(*r)); ++x; ++y; ++r; ++fc; } while(--n); break; - } - } - - //-------------------------------------------------------------------- - template - void markers(int n, const T* x, const T* y, const T* r, const color_type* fc, const color_type* lc, marker_e type) - { - if(n <= 0) return; - switch(type) - { - case marker_square: do { base_type::fill_color(*fc); base_type::line_color(*lc); square (int(*x), int(*y), int(*r)); ++x; ++y; ++r; ++fc; ++lc; } while(--n); break; - case marker_diamond: do { base_type::fill_color(*fc); base_type::line_color(*lc); diamond (int(*x), int(*y), int(*r)); ++x; ++y; ++r; ++fc; ++lc; } while(--n); break; - case marker_circle: do { base_type::fill_color(*fc); base_type::line_color(*lc); circle (int(*x), int(*y), int(*r)); ++x; ++y; ++r; ++fc; ++lc; } while(--n); break; - case marker_crossed_circle: do { base_type::fill_color(*fc); base_type::line_color(*lc); crossed_circle (int(*x), int(*y), int(*r)); ++x; ++y; ++r; ++fc; ++lc; } while(--n); break; - case marker_semiellipse_left: do { base_type::fill_color(*fc); base_type::line_color(*lc); semiellipse_left (int(*x), int(*y), int(*r)); ++x; ++y; ++r; ++fc; ++lc; } while(--n); break; - case marker_semiellipse_right: do { base_type::fill_color(*fc); base_type::line_color(*lc); semiellipse_right(int(*x), int(*y), int(*r)); ++x; ++y; ++r; ++fc; ++lc; } while(--n); break; - case marker_semiellipse_up: do { base_type::fill_color(*fc); base_type::line_color(*lc); semiellipse_up (int(*x), int(*y), int(*r)); ++x; ++y; ++r; ++fc; ++lc; } while(--n); break; - case marker_semiellipse_down: do { base_type::fill_color(*fc); base_type::line_color(*lc); semiellipse_down (int(*x), int(*y), int(*r)); ++x; ++y; ++r; ++fc; ++lc; } while(--n); break; - case marker_triangle_left: do { base_type::fill_color(*fc); base_type::line_color(*lc); triangle_left (int(*x), int(*y), int(*r)); ++x; ++y; ++r; ++fc; ++lc; } while(--n); break; - case marker_triangle_right: do { base_type::fill_color(*fc); base_type::line_color(*lc); triangle_right (int(*x), int(*y), int(*r)); ++x; ++y; ++r; ++fc; ++lc; } while(--n); break; - case marker_triangle_up: do { base_type::fill_color(*fc); base_type::line_color(*lc); triangle_up (int(*x), int(*y), int(*r)); ++x; ++y; ++r; ++fc; ++lc; } while(--n); break; - case marker_triangle_down: do { base_type::fill_color(*fc); base_type::line_color(*lc); triangle_down (int(*x), int(*y), int(*r)); ++x; ++y; ++r; ++fc; ++lc; } while(--n); break; - case marker_four_rays: do { base_type::fill_color(*fc); base_type::line_color(*lc); four_rays (int(*x), int(*y), int(*r)); ++x; ++y; ++r; ++fc; ++lc; } while(--n); break; - case marker_cross: do { base_type::fill_color(*fc); base_type::line_color(*lc); cross (int(*x), int(*y), int(*r)); ++x; ++y; ++r; ++fc; ++lc; } while(--n); break; - case marker_x: do { base_type::fill_color(*fc); base_type::line_color(*lc); xing (int(*x), int(*y), int(*r)); ++x; ++y; ++r; ++fc; ++lc; } while(--n); break; - case marker_dash: do { base_type::fill_color(*fc); base_type::line_color(*lc); dash (int(*x), int(*y), int(*r)); ++x; ++y; ++r; ++fc; ++lc; } while(--n); break; - case marker_dot: do { base_type::fill_color(*fc); base_type::line_color(*lc); dot (int(*x), int(*y), int(*r)); ++x; ++y; ++r; ++fc; ++lc; } while(--n); break; - case marker_pixel: do { base_type::fill_color(*fc); base_type::line_color(*lc); pixel (int(*x), int(*y), int(*r)); ++x; ++y; ++r; ++fc; ++lc; } while(--n); break; - } - } - }; - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_renderer_mclip.h b/desmume/src/windows/agg/include/agg_renderer_mclip.h deleted file mode 100644 index a2a5b6569..000000000 --- a/desmume/src/windows/agg/include/agg_renderer_mclip.h +++ /dev/null @@ -1,349 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_RENDERER_MCLIP_INCLUDED -#define AGG_RENDERER_MCLIP_INCLUDED - -#include "agg_basics.h" -#include "agg_array.h" -#include "agg_renderer_base.h" - -namespace agg -{ - - //----------------------------------------------------------renderer_mclip - template class renderer_mclip - { - public: - typedef PixelFormat pixfmt_type; - typedef typename pixfmt_type::color_type color_type; - typedef typename pixfmt_type::row_data row_data; - typedef renderer_base base_ren_type; - - //-------------------------------------------------------------------- - explicit renderer_mclip(pixfmt_type& pixf) : - m_ren(pixf), - m_curr_cb(0), - m_bounds(m_ren.xmin(), m_ren.ymin(), m_ren.xmax(), m_ren.ymax()) - {} - void attach(pixfmt_type& pixf) - { - m_ren.attach(pixf); - reset_clipping(true); - } - - //-------------------------------------------------------------------- - const pixfmt_type& ren() const { return m_ren.ren(); } - pixfmt_type& ren() { return m_ren.ren(); } - - //-------------------------------------------------------------------- - unsigned width() const { return m_ren.width(); } - unsigned height() const { return m_ren.height(); } - - //-------------------------------------------------------------------- - const rect_i& clip_box() const { return m_ren.clip_box(); } - int xmin() const { return m_ren.xmin(); } - int ymin() const { return m_ren.ymin(); } - int xmax() const { return m_ren.xmax(); } - int ymax() const { return m_ren.ymax(); } - - //-------------------------------------------------------------------- - const rect_i& bounding_clip_box() const { return m_bounds; } - int bounding_xmin() const { return m_bounds.x1; } - int bounding_ymin() const { return m_bounds.y1; } - int bounding_xmax() const { return m_bounds.x2; } - int bounding_ymax() const { return m_bounds.y2; } - - //-------------------------------------------------------------------- - void first_clip_box() - { - m_curr_cb = 0; - if(m_clip.size()) - { - const rect_i& cb = m_clip[0]; - m_ren.clip_box_naked(cb.x1, cb.y1, cb.x2, cb.y2); - } - } - - //-------------------------------------------------------------------- - bool next_clip_box() - { - if(++m_curr_cb < m_clip.size()) - { - const rect_i& cb = m_clip[m_curr_cb]; - m_ren.clip_box_naked(cb.x1, cb.y1, cb.x2, cb.y2); - return true; - } - return false; - } - - //-------------------------------------------------------------------- - void reset_clipping(bool visibility) - { - m_ren.reset_clipping(visibility); - m_clip.remove_all(); - m_curr_cb = 0; - m_bounds = m_ren.clip_box(); - } - - //-------------------------------------------------------------------- - void add_clip_box(int x1, int y1, int x2, int y2) - { - rect_i cb(x1, y1, x2, y2); - cb.normalize(); - if(cb.clip(rect_i(0, 0, width() - 1, height() - 1))) - { - m_clip.add(cb); - if(cb.x1 < m_bounds.x1) m_bounds.x1 = cb.x1; - if(cb.y1 < m_bounds.y1) m_bounds.y1 = cb.y1; - if(cb.x2 > m_bounds.x2) m_bounds.x2 = cb.x2; - if(cb.y2 > m_bounds.y2) m_bounds.y2 = cb.y2; - } - } - - //-------------------------------------------------------------------- - void clear(const color_type& c) - { - m_ren.clear(c); - } - - //-------------------------------------------------------------------- - void copy_pixel(int x, int y, const color_type& c) - { - first_clip_box(); - do - { - if(m_ren.inbox(x, y)) - { - m_ren.ren().copy_pixel(x, y, c); - break; - } - } - while(next_clip_box()); - } - - //-------------------------------------------------------------------- - void blend_pixel(int x, int y, const color_type& c, cover_type cover) - { - first_clip_box(); - do - { - if(m_ren.inbox(x, y)) - { - m_ren.ren().blend_pixel(x, y, c, cover); - break; - } - } - while(next_clip_box()); - } - - //-------------------------------------------------------------------- - color_type pixel(int x, int y) const - { - if(m_ren.inbox(x, y)) - { - return m_ren.ren().pixel(x, y); - } - return color_type::no_color(); - } - - //-------------------------------------------------------------------- - void copy_hline(int x1, int y, int x2, const color_type& c) - { - first_clip_box(); - do - { - m_ren.copy_hline(x1, y, x2, c); - } - while(next_clip_box()); - } - - //-------------------------------------------------------------------- - void copy_vline(int x, int y1, int y2, const color_type& c) - { - first_clip_box(); - do - { - m_ren.copy_vline(x, y1, y2, c); - } - while(next_clip_box()); - } - - //-------------------------------------------------------------------- - void blend_hline(int x1, int y, int x2, - const color_type& c, cover_type cover) - { - first_clip_box(); - do - { - m_ren.blend_hline(x1, y, x2, c, cover); - } - while(next_clip_box()); - } - - //-------------------------------------------------------------------- - void blend_vline(int x, int y1, int y2, - const color_type& c, cover_type cover) - { - first_clip_box(); - do - { - m_ren.blend_vline(x, y1, y2, c, cover); - } - while(next_clip_box()); - } - - //-------------------------------------------------------------------- - void copy_bar(int x1, int y1, int x2, int y2, const color_type& c) - { - first_clip_box(); - do - { - m_ren.copy_bar(x1, y1, x2, y2, c); - } - while(next_clip_box()); - } - - //-------------------------------------------------------------------- - void blend_bar(int x1, int y1, int x2, int y2, - const color_type& c, cover_type cover) - { - first_clip_box(); - do - { - m_ren.blend_bar(x1, y1, x2, y2, c, cover); - } - while(next_clip_box()); - } - - //-------------------------------------------------------------------- - void blend_solid_hspan(int x, int y, int len, - const color_type& c, const cover_type* covers) - { - first_clip_box(); - do - { - m_ren.blend_solid_hspan(x, y, len, c, covers); - } - while(next_clip_box()); - } - - //-------------------------------------------------------------------- - void blend_solid_vspan(int x, int y, int len, - const color_type& c, const cover_type* covers) - { - first_clip_box(); - do - { - m_ren.blend_solid_vspan(x, y, len, c, covers); - } - while(next_clip_box()); - } - - - //-------------------------------------------------------------------- - void copy_color_hspan(int x, int y, int len, const color_type* colors) - { - first_clip_box(); - do - { - m_ren.copy_color_hspan(x, y, len, colors); - } - while(next_clip_box()); - } - - //-------------------------------------------------------------------- - void blend_color_hspan(int x, int y, int len, - const color_type* colors, - const cover_type* covers, - cover_type cover = cover_full) - { - first_clip_box(); - do - { - m_ren.blend_color_hspan(x, y, len, colors, covers, cover); - } - while(next_clip_box()); - } - - //-------------------------------------------------------------------- - void blend_color_vspan(int x, int y, int len, - const color_type* colors, - const cover_type* covers, - cover_type cover = cover_full) - { - first_clip_box(); - do - { - m_ren.blend_color_vspan(x, y, len, colors, covers, cover); - } - while(next_clip_box()); - } - - //-------------------------------------------------------------------- - void copy_from(const rendering_buffer& from, - const rect_i* rc=0, - int x_to=0, - int y_to=0) - { - first_clip_box(); - do - { - m_ren.copy_from(from, rc, x_to, y_to); - } - while(next_clip_box()); - } - - //-------------------------------------------------------------------- - template - void blend_from(const SrcPixelFormatRenderer& src, - const rect_i* rect_src_ptr = 0, - int dx = 0, - int dy = 0, - cover_type cover = cover_full) - { - first_clip_box(); - do - { - m_ren.blend_from(src, rect_src_ptr, dx, dy, cover); - } - while(next_clip_box()); - } - - - private: - renderer_mclip(const renderer_mclip&); - const renderer_mclip& - operator = (const renderer_mclip&); - - base_ren_type m_ren; - pod_bvector m_clip; - unsigned m_curr_cb; - rect_i m_bounds; - }; - - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_renderer_outline_aa.h b/desmume/src/windows/agg/include/agg_renderer_outline_aa.h deleted file mode 100644 index 70b4c9b7e..000000000 --- a/desmume/src/windows/agg/include/agg_renderer_outline_aa.h +++ /dev/null @@ -1,1847 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_RENDERER_OUTLINE_AA_INCLUDED -#define AGG_RENDERER_OUTLINE_AA_INCLUDED - -#include "agg_array.h" -#include "agg_math.h" -#include "agg_line_aa_basics.h" -#include "agg_dda_line.h" -#include "agg_ellipse_bresenham.h" -#include "agg_renderer_base.h" -#include "agg_gamma_functions.h" -#include "agg_clip_liang_barsky.h" - -namespace agg -{ - - //===================================================distance_interpolator0 - class distance_interpolator0 - { - public: - //--------------------------------------------------------------------- - distance_interpolator0() {} - distance_interpolator0(int x1, int y1, int x2, int y2, int x, int y) : - m_dx(line_mr(x2) - line_mr(x1)), - m_dy(line_mr(y2) - line_mr(y1)), - m_dist((line_mr(x + line_subpixel_scale/2) - line_mr(x2)) * m_dy - - (line_mr(y + line_subpixel_scale/2) - line_mr(y2)) * m_dx) - { - m_dx <<= line_mr_subpixel_shift; - m_dy <<= line_mr_subpixel_shift; - } - - //--------------------------------------------------------------------- - void inc_x() { m_dist += m_dy; } - int dist() const { return m_dist; } - - private: - //--------------------------------------------------------------------- - int m_dx; - int m_dy; - int m_dist; - }; - - //==================================================distance_interpolator00 - class distance_interpolator00 - { - public: - //--------------------------------------------------------------------- - distance_interpolator00() {} - distance_interpolator00(int xc, int yc, - int x1, int y1, int x2, int y2, - int x, int y) : - m_dx1(line_mr(x1) - line_mr(xc)), - m_dy1(line_mr(y1) - line_mr(yc)), - m_dx2(line_mr(x2) - line_mr(xc)), - m_dy2(line_mr(y2) - line_mr(yc)), - m_dist1((line_mr(x + line_subpixel_scale/2) - line_mr(x1)) * m_dy1 - - (line_mr(y + line_subpixel_scale/2) - line_mr(y1)) * m_dx1), - m_dist2((line_mr(x + line_subpixel_scale/2) - line_mr(x2)) * m_dy2 - - (line_mr(y + line_subpixel_scale/2) - line_mr(y2)) * m_dx2) - { - m_dx1 <<= line_mr_subpixel_shift; - m_dy1 <<= line_mr_subpixel_shift; - m_dx2 <<= line_mr_subpixel_shift; - m_dy2 <<= line_mr_subpixel_shift; - } - - //--------------------------------------------------------------------- - void inc_x() { m_dist1 += m_dy1; m_dist2 += m_dy2; } - int dist1() const { return m_dist1; } - int dist2() const { return m_dist2; } - - private: - //--------------------------------------------------------------------- - int m_dx1; - int m_dy1; - int m_dx2; - int m_dy2; - int m_dist1; - int m_dist2; - }; - - //===================================================distance_interpolator1 - class distance_interpolator1 - { - public: - //--------------------------------------------------------------------- - distance_interpolator1() {} - distance_interpolator1(int x1, int y1, int x2, int y2, int x, int y) : - m_dx(x2 - x1), - m_dy(y2 - y1), - m_dist(iround(double(x + line_subpixel_scale/2 - x2) * double(m_dy) - - double(y + line_subpixel_scale/2 - y2) * double(m_dx))) - { - m_dx <<= line_subpixel_shift; - m_dy <<= line_subpixel_shift; - } - - //--------------------------------------------------------------------- - void inc_x() { m_dist += m_dy; } - void dec_x() { m_dist -= m_dy; } - void inc_y() { m_dist -= m_dx; } - void dec_y() { m_dist += m_dx; } - - //--------------------------------------------------------------------- - void inc_x(int dy) - { - m_dist += m_dy; - if(dy > 0) m_dist -= m_dx; - if(dy < 0) m_dist += m_dx; - } - - //--------------------------------------------------------------------- - void dec_x(int dy) - { - m_dist -= m_dy; - if(dy > 0) m_dist -= m_dx; - if(dy < 0) m_dist += m_dx; - } - - //--------------------------------------------------------------------- - void inc_y(int dx) - { - m_dist -= m_dx; - if(dx > 0) m_dist += m_dy; - if(dx < 0) m_dist -= m_dy; - } - - void dec_y(int dx) - //--------------------------------------------------------------------- - { - m_dist += m_dx; - if(dx > 0) m_dist += m_dy; - if(dx < 0) m_dist -= m_dy; - } - - //--------------------------------------------------------------------- - int dist() const { return m_dist; } - int dx() const { return m_dx; } - int dy() const { return m_dy; } - - private: - //--------------------------------------------------------------------- - int m_dx; - int m_dy; - int m_dist; - }; - - - - - - //===================================================distance_interpolator2 - class distance_interpolator2 - { - public: - //--------------------------------------------------------------------- - distance_interpolator2() {} - distance_interpolator2(int x1, int y1, int x2, int y2, - int sx, int sy, int x, int y) : - m_dx(x2 - x1), - m_dy(y2 - y1), - m_dx_start(line_mr(sx) - line_mr(x1)), - m_dy_start(line_mr(sy) - line_mr(y1)), - - m_dist(iround(double(x + line_subpixel_scale/2 - x2) * double(m_dy) - - double(y + line_subpixel_scale/2 - y2) * double(m_dx))), - - m_dist_start((line_mr(x + line_subpixel_scale/2) - line_mr(sx)) * m_dy_start - - (line_mr(y + line_subpixel_scale/2) - line_mr(sy)) * m_dx_start) - { - m_dx <<= line_subpixel_shift; - m_dy <<= line_subpixel_shift; - m_dx_start <<= line_mr_subpixel_shift; - m_dy_start <<= line_mr_subpixel_shift; - } - - distance_interpolator2(int x1, int y1, int x2, int y2, - int ex, int ey, int x, int y, int) : - m_dx(x2 - x1), - m_dy(y2 - y1), - m_dx_start(line_mr(ex) - line_mr(x2)), - m_dy_start(line_mr(ey) - line_mr(y2)), - - m_dist(iround(double(x + line_subpixel_scale/2 - x2) * double(m_dy) - - double(y + line_subpixel_scale/2 - y2) * double(m_dx))), - - m_dist_start((line_mr(x + line_subpixel_scale/2) - line_mr(ex)) * m_dy_start - - (line_mr(y + line_subpixel_scale/2) - line_mr(ey)) * m_dx_start) - { - m_dx <<= line_subpixel_shift; - m_dy <<= line_subpixel_shift; - m_dx_start <<= line_mr_subpixel_shift; - m_dy_start <<= line_mr_subpixel_shift; - } - - - //--------------------------------------------------------------------- - void inc_x() { m_dist += m_dy; m_dist_start += m_dy_start; } - void dec_x() { m_dist -= m_dy; m_dist_start -= m_dy_start; } - void inc_y() { m_dist -= m_dx; m_dist_start -= m_dx_start; } - void dec_y() { m_dist += m_dx; m_dist_start += m_dx_start; } - - //--------------------------------------------------------------------- - void inc_x(int dy) - { - m_dist += m_dy; - m_dist_start += m_dy_start; - if(dy > 0) - { - m_dist -= m_dx; - m_dist_start -= m_dx_start; - } - if(dy < 0) - { - m_dist += m_dx; - m_dist_start += m_dx_start; - } - } - - //--------------------------------------------------------------------- - void dec_x(int dy) - { - m_dist -= m_dy; - m_dist_start -= m_dy_start; - if(dy > 0) - { - m_dist -= m_dx; - m_dist_start -= m_dx_start; - } - if(dy < 0) - { - m_dist += m_dx; - m_dist_start += m_dx_start; - } - } - - //--------------------------------------------------------------------- - void inc_y(int dx) - { - m_dist -= m_dx; - m_dist_start -= m_dx_start; - if(dx > 0) - { - m_dist += m_dy; - m_dist_start += m_dy_start; - } - if(dx < 0) - { - m_dist -= m_dy; - m_dist_start -= m_dy_start; - } - } - - //--------------------------------------------------------------------- - void dec_y(int dx) - { - m_dist += m_dx; - m_dist_start += m_dx_start; - if(dx > 0) - { - m_dist += m_dy; - m_dist_start += m_dy_start; - } - if(dx < 0) - { - m_dist -= m_dy; - m_dist_start -= m_dy_start; - } - } - - //--------------------------------------------------------------------- - int dist() const { return m_dist; } - int dist_start() const { return m_dist_start; } - int dist_end() const { return m_dist_start; } - - //--------------------------------------------------------------------- - int dx() const { return m_dx; } - int dy() const { return m_dy; } - int dx_start() const { return m_dx_start; } - int dy_start() const { return m_dy_start; } - int dx_end() const { return m_dx_start; } - int dy_end() const { return m_dy_start; } - - private: - //--------------------------------------------------------------------- - int m_dx; - int m_dy; - int m_dx_start; - int m_dy_start; - - int m_dist; - int m_dist_start; - }; - - - - - - //===================================================distance_interpolator3 - class distance_interpolator3 - { - public: - //--------------------------------------------------------------------- - distance_interpolator3() {} - distance_interpolator3(int x1, int y1, int x2, int y2, - int sx, int sy, int ex, int ey, - int x, int y) : - m_dx(x2 - x1), - m_dy(y2 - y1), - m_dx_start(line_mr(sx) - line_mr(x1)), - m_dy_start(line_mr(sy) - line_mr(y1)), - m_dx_end(line_mr(ex) - line_mr(x2)), - m_dy_end(line_mr(ey) - line_mr(y2)), - - m_dist(iround(double(x + line_subpixel_scale/2 - x2) * double(m_dy) - - double(y + line_subpixel_scale/2 - y2) * double(m_dx))), - - m_dist_start((line_mr(x + line_subpixel_scale/2) - line_mr(sx)) * m_dy_start - - (line_mr(y + line_subpixel_scale/2) - line_mr(sy)) * m_dx_start), - - m_dist_end((line_mr(x + line_subpixel_scale/2) - line_mr(ex)) * m_dy_end - - (line_mr(y + line_subpixel_scale/2) - line_mr(ey)) * m_dx_end) - { - m_dx <<= line_subpixel_shift; - m_dy <<= line_subpixel_shift; - m_dx_start <<= line_mr_subpixel_shift; - m_dy_start <<= line_mr_subpixel_shift; - m_dx_end <<= line_mr_subpixel_shift; - m_dy_end <<= line_mr_subpixel_shift; - } - - //--------------------------------------------------------------------- - void inc_x() { m_dist += m_dy; m_dist_start += m_dy_start; m_dist_end += m_dy_end; } - void dec_x() { m_dist -= m_dy; m_dist_start -= m_dy_start; m_dist_end -= m_dy_end; } - void inc_y() { m_dist -= m_dx; m_dist_start -= m_dx_start; m_dist_end -= m_dx_end; } - void dec_y() { m_dist += m_dx; m_dist_start += m_dx_start; m_dist_end += m_dx_end; } - - //--------------------------------------------------------------------- - void inc_x(int dy) - { - m_dist += m_dy; - m_dist_start += m_dy_start; - m_dist_end += m_dy_end; - if(dy > 0) - { - m_dist -= m_dx; - m_dist_start -= m_dx_start; - m_dist_end -= m_dx_end; - } - if(dy < 0) - { - m_dist += m_dx; - m_dist_start += m_dx_start; - m_dist_end += m_dx_end; - } - } - - //--------------------------------------------------------------------- - void dec_x(int dy) - { - m_dist -= m_dy; - m_dist_start -= m_dy_start; - m_dist_end -= m_dy_end; - if(dy > 0) - { - m_dist -= m_dx; - m_dist_start -= m_dx_start; - m_dist_end -= m_dx_end; - } - if(dy < 0) - { - m_dist += m_dx; - m_dist_start += m_dx_start; - m_dist_end += m_dx_end; - } - } - - //--------------------------------------------------------------------- - void inc_y(int dx) - { - m_dist -= m_dx; - m_dist_start -= m_dx_start; - m_dist_end -= m_dx_end; - if(dx > 0) - { - m_dist += m_dy; - m_dist_start += m_dy_start; - m_dist_end += m_dy_end; - } - if(dx < 0) - { - m_dist -= m_dy; - m_dist_start -= m_dy_start; - m_dist_end -= m_dy_end; - } - } - - //--------------------------------------------------------------------- - void dec_y(int dx) - { - m_dist += m_dx; - m_dist_start += m_dx_start; - m_dist_end += m_dx_end; - if(dx > 0) - { - m_dist += m_dy; - m_dist_start += m_dy_start; - m_dist_end += m_dy_end; - } - if(dx < 0) - { - m_dist -= m_dy; - m_dist_start -= m_dy_start; - m_dist_end -= m_dy_end; - } - } - - //--------------------------------------------------------------------- - int dist() const { return m_dist; } - int dist_start() const { return m_dist_start; } - int dist_end() const { return m_dist_end; } - - //--------------------------------------------------------------------- - int dx() const { return m_dx; } - int dy() const { return m_dy; } - int dx_start() const { return m_dx_start; } - int dy_start() const { return m_dy_start; } - int dx_end() const { return m_dx_end; } - int dy_end() const { return m_dy_end; } - - private: - //--------------------------------------------------------------------- - int m_dx; - int m_dy; - int m_dx_start; - int m_dy_start; - int m_dx_end; - int m_dy_end; - - int m_dist; - int m_dist_start; - int m_dist_end; - }; - - - - - - //================================================line_interpolator_aa_base - template class line_interpolator_aa_base - { - public: - typedef Renderer renderer_type; - typedef typename Renderer::color_type color_type; - - //--------------------------------------------------------------------- - enum max_half_width_e - { - max_half_width = 64 - }; - - //--------------------------------------------------------------------- - line_interpolator_aa_base(renderer_type& ren, const line_parameters& lp) : - m_lp(&lp), - m_li(lp.vertical ? line_dbl_hr(lp.x2 - lp.x1) : - line_dbl_hr(lp.y2 - lp.y1), - lp.vertical ? abs(lp.y2 - lp.y1) : - abs(lp.x2 - lp.x1) + 1), - m_ren(ren), - m_len((lp.vertical == (lp.inc > 0)) ? -lp.len : lp.len), - m_x(lp.x1 >> line_subpixel_shift), - m_y(lp.y1 >> line_subpixel_shift), - m_old_x(m_x), - m_old_y(m_y), - m_count((lp.vertical ? abs((lp.y2 >> line_subpixel_shift) - m_y) : - abs((lp.x2 >> line_subpixel_shift) - m_x))), - m_width(ren.subpixel_width()), - //m_max_extent(m_width >> (line_subpixel_shift - 2)), - m_max_extent((m_width + line_subpixel_mask) >> line_subpixel_shift), - m_step(0) - { - agg::dda2_line_interpolator li(0, lp.vertical ? - (lp.dy << agg::line_subpixel_shift) : - (lp.dx << agg::line_subpixel_shift), - lp.len); - - unsigned i; - int stop = m_width + line_subpixel_scale * 2; - for(i = 0; i < max_half_width; ++i) - { - m_dist[i] = li.y(); - if(m_dist[i] >= stop) break; - ++li; - } - m_dist[i++] = 0x7FFF0000; - } - - //--------------------------------------------------------------------- - template int step_hor_base(DI& di) - { - ++m_li; - m_x += m_lp->inc; - m_y = (m_lp->y1 + m_li.y()) >> line_subpixel_shift; - - if(m_lp->inc > 0) di.inc_x(m_y - m_old_y); - else di.dec_x(m_y - m_old_y); - - m_old_y = m_y; - - return di.dist() / m_len; - } - - //--------------------------------------------------------------------- - template int step_ver_base(DI& di) - { - ++m_li; - m_y += m_lp->inc; - m_x = (m_lp->x1 + m_li.y()) >> line_subpixel_shift; - - if(m_lp->inc > 0) di.inc_y(m_x - m_old_x); - else di.dec_y(m_x - m_old_x); - - m_old_x = m_x; - - return di.dist() / m_len; - } - - //--------------------------------------------------------------------- - bool vertical() const { return m_lp->vertical; } - int width() const { return m_width; } - int count() const { return m_count; } - - private: - line_interpolator_aa_base(const line_interpolator_aa_base&); - const line_interpolator_aa_base& - operator = (const line_interpolator_aa_base&); - - protected: - const line_parameters* m_lp; - dda2_line_interpolator m_li; - renderer_type& m_ren; - int m_len; - int m_x; - int m_y; - int m_old_x; - int m_old_y; - int m_count; - int m_width; - int m_max_extent; - int m_step; - int m_dist[max_half_width + 1]; - cover_type m_covers[max_half_width * 2 + 4]; - }; - - - - - - - - //====================================================line_interpolator_aa0 - template class line_interpolator_aa0 : - public line_interpolator_aa_base - { - public: - typedef Renderer renderer_type; - typedef typename Renderer::color_type color_type; - typedef line_interpolator_aa_base base_type; - - //--------------------------------------------------------------------- - line_interpolator_aa0(renderer_type& ren, const line_parameters& lp) : - line_interpolator_aa_base(ren, lp), - m_di(lp.x1, lp.y1, lp.x2, lp.y2, - lp.x1 & ~line_subpixel_mask, lp.y1 & ~line_subpixel_mask) - { - base_type::m_li.adjust_forward(); - } - - //--------------------------------------------------------------------- - bool step_hor() - { - int dist; - int dy; - int s1 = base_type::step_hor_base(m_di); - cover_type* p0 = base_type::m_covers + base_type::max_half_width + 2; - cover_type* p1 = p0; - - *p1++ = (cover_type)base_type::m_ren.cover(s1); - - dy = 1; - while((dist = base_type::m_dist[dy] - s1) <= base_type::m_width) - { - *p1++ = (cover_type)base_type::m_ren.cover(dist); - ++dy; - } - - dy = 1; - while((dist = base_type::m_dist[dy] + s1) <= base_type::m_width) - { - *--p0 = (cover_type)base_type::m_ren.cover(dist); - ++dy; - } - base_type::m_ren.blend_solid_vspan(base_type::m_x, - base_type::m_y - dy + 1, - unsigned(p1 - p0), - p0); - return ++base_type::m_step < base_type::m_count; - } - - //--------------------------------------------------------------------- - bool step_ver() - { - int dist; - int dx; - int s1 = base_type::step_ver_base(m_di); - cover_type* p0 = base_type::m_covers + base_type::max_half_width + 2; - cover_type* p1 = p0; - - *p1++ = (cover_type)base_type::m_ren.cover(s1); - - dx = 1; - while((dist = base_type::m_dist[dx] - s1) <= base_type::m_width) - { - *p1++ = (cover_type)base_type::m_ren.cover(dist); - ++dx; - } - - dx = 1; - while((dist = base_type::m_dist[dx] + s1) <= base_type::m_width) - { - *--p0 = (cover_type)base_type::m_ren.cover(dist); - ++dx; - } - base_type::m_ren.blend_solid_hspan(base_type::m_x - dx + 1, - base_type::m_y, - unsigned(p1 - p0), - p0); - return ++base_type::m_step < base_type::m_count; - } - - private: - line_interpolator_aa0(const line_interpolator_aa0&); - const line_interpolator_aa0& - operator = (const line_interpolator_aa0&); - - //--------------------------------------------------------------------- - distance_interpolator1 m_di; - }; - - - - - - - //====================================================line_interpolator_aa1 - template class line_interpolator_aa1 : - public line_interpolator_aa_base - { - public: - typedef Renderer renderer_type; - typedef typename Renderer::color_type color_type; - typedef line_interpolator_aa_base base_type; - - //--------------------------------------------------------------------- - line_interpolator_aa1(renderer_type& ren, const line_parameters& lp, - int sx, int sy) : - line_interpolator_aa_base(ren, lp), - m_di(lp.x1, lp.y1, lp.x2, lp.y2, sx, sy, - lp.x1 & ~line_subpixel_mask, lp.y1 & ~line_subpixel_mask) - { - int dist1_start; - int dist2_start; - - int npix = 1; - - if(lp.vertical) - { - do - { - --base_type::m_li; - base_type::m_y -= lp.inc; - base_type::m_x = (base_type::m_lp->x1 + base_type::m_li.y()) >> line_subpixel_shift; - - if(lp.inc > 0) m_di.dec_y(base_type::m_x - base_type::m_old_x); - else m_di.inc_y(base_type::m_x - base_type::m_old_x); - - base_type::m_old_x = base_type::m_x; - - dist1_start = dist2_start = m_di.dist_start(); - - int dx = 0; - if(dist1_start < 0) ++npix; - do - { - dist1_start += m_di.dy_start(); - dist2_start -= m_di.dy_start(); - if(dist1_start < 0) ++npix; - if(dist2_start < 0) ++npix; - ++dx; - } - while(base_type::m_dist[dx] <= base_type::m_width); - --base_type::m_step; - if(npix == 0) break; - npix = 0; - } - while(base_type::m_step >= -base_type::m_max_extent); - } - else - { - do - { - --base_type::m_li; - base_type::m_x -= lp.inc; - base_type::m_y = (base_type::m_lp->y1 + base_type::m_li.y()) >> line_subpixel_shift; - - if(lp.inc > 0) m_di.dec_x(base_type::m_y - base_type::m_old_y); - else m_di.inc_x(base_type::m_y - base_type::m_old_y); - - base_type::m_old_y = base_type::m_y; - - dist1_start = dist2_start = m_di.dist_start(); - - int dy = 0; - if(dist1_start < 0) ++npix; - do - { - dist1_start -= m_di.dx_start(); - dist2_start += m_di.dx_start(); - if(dist1_start < 0) ++npix; - if(dist2_start < 0) ++npix; - ++dy; - } - while(base_type::m_dist[dy] <= base_type::m_width); - --base_type::m_step; - if(npix == 0) break; - npix = 0; - } - while(base_type::m_step >= -base_type::m_max_extent); - } - base_type::m_li.adjust_forward(); - } - - //--------------------------------------------------------------------- - bool step_hor() - { - int dist_start; - int dist; - int dy; - int s1 = base_type::step_hor_base(m_di); - - dist_start = m_di.dist_start(); - cover_type* p0 = base_type::m_covers + base_type::max_half_width + 2; - cover_type* p1 = p0; - - *p1 = 0; - if(dist_start <= 0) - { - *p1 = (cover_type)base_type::m_ren.cover(s1); - } - ++p1; - - dy = 1; - while((dist = base_type::m_dist[dy] - s1) <= base_type::m_width) - { - dist_start -= m_di.dx_start(); - *p1 = 0; - if(dist_start <= 0) - { - *p1 = (cover_type)base_type::m_ren.cover(dist); - } - ++p1; - ++dy; - } - - dy = 1; - dist_start = m_di.dist_start(); - while((dist = base_type::m_dist[dy] + s1) <= base_type::m_width) - { - dist_start += m_di.dx_start(); - *--p0 = 0; - if(dist_start <= 0) - { - *p0 = (cover_type)base_type::m_ren.cover(dist); - } - ++dy; - } - - base_type::m_ren.blend_solid_vspan(base_type::m_x, - base_type::m_y - dy + 1, - unsigned(p1 - p0), - p0); - return ++base_type::m_step < base_type::m_count; - } - - //--------------------------------------------------------------------- - bool step_ver() - { - int dist_start; - int dist; - int dx; - int s1 = base_type::step_ver_base(m_di); - cover_type* p0 = base_type::m_covers + base_type::max_half_width + 2; - cover_type* p1 = p0; - - dist_start = m_di.dist_start(); - - *p1 = 0; - if(dist_start <= 0) - { - *p1 = (cover_type)base_type::m_ren.cover(s1); - } - ++p1; - - dx = 1; - while((dist = base_type::m_dist[dx] - s1) <= base_type::m_width) - { - dist_start += m_di.dy_start(); - *p1 = 0; - if(dist_start <= 0) - { - *p1 = (cover_type)base_type::m_ren.cover(dist); - } - ++p1; - ++dx; - } - - dx = 1; - dist_start = m_di.dist_start(); - while((dist = base_type::m_dist[dx] + s1) <= base_type::m_width) - { - dist_start -= m_di.dy_start(); - *--p0 = 0; - if(dist_start <= 0) - { - *p0 = (cover_type)base_type::m_ren.cover(dist); - } - ++dx; - } - base_type::m_ren.blend_solid_hspan(base_type::m_x - dx + 1, - base_type::m_y, - unsigned(p1 - p0), - p0); - return ++base_type::m_step < base_type::m_count; - } - - private: - line_interpolator_aa1(const line_interpolator_aa1&); - const line_interpolator_aa1& - operator = (const line_interpolator_aa1&); - - //--------------------------------------------------------------------- - distance_interpolator2 m_di; - }; - - - - - - - - - - - - - //====================================================line_interpolator_aa2 - template class line_interpolator_aa2 : - public line_interpolator_aa_base - { - public: - typedef Renderer renderer_type; - typedef typename Renderer::color_type color_type; - typedef line_interpolator_aa_base base_type; - - //--------------------------------------------------------------------- - line_interpolator_aa2(renderer_type& ren, const line_parameters& lp, - int ex, int ey) : - line_interpolator_aa_base(ren, lp), - m_di(lp.x1, lp.y1, lp.x2, lp.y2, ex, ey, - lp.x1 & ~line_subpixel_mask, lp.y1 & ~line_subpixel_mask, - 0) - { - base_type::m_li.adjust_forward(); - base_type::m_step -= base_type::m_max_extent; - } - - //--------------------------------------------------------------------- - bool step_hor() - { - int dist_end; - int dist; - int dy; - int s1 = base_type::step_hor_base(m_di); - cover_type* p0 = base_type::m_covers + base_type::max_half_width + 2; - cover_type* p1 = p0; - - dist_end = m_di.dist_end(); - - int npix = 0; - *p1 = 0; - if(dist_end > 0) - { - *p1 = (cover_type)base_type::m_ren.cover(s1); - ++npix; - } - ++p1; - - dy = 1; - while((dist = base_type::m_dist[dy] - s1) <= base_type::m_width) - { - dist_end -= m_di.dx_end(); - *p1 = 0; - if(dist_end > 0) - { - *p1 = (cover_type)base_type::m_ren.cover(dist); - ++npix; - } - ++p1; - ++dy; - } - - dy = 1; - dist_end = m_di.dist_end(); - while((dist = base_type::m_dist[dy] + s1) <= base_type::m_width) - { - dist_end += m_di.dx_end(); - *--p0 = 0; - if(dist_end > 0) - { - *p0 = (cover_type)base_type::m_ren.cover(dist); - ++npix; - } - ++dy; - } - base_type::m_ren.blend_solid_vspan(base_type::m_x, - base_type::m_y - dy + 1, - unsigned(p1 - p0), - p0); - return npix && ++base_type::m_step < base_type::m_count; - } - - //--------------------------------------------------------------------- - bool step_ver() - { - int dist_end; - int dist; - int dx; - int s1 = base_type::step_ver_base(m_di); - cover_type* p0 = base_type::m_covers + base_type::max_half_width + 2; - cover_type* p1 = p0; - - dist_end = m_di.dist_end(); - - int npix = 0; - *p1 = 0; - if(dist_end > 0) - { - *p1 = (cover_type)base_type::m_ren.cover(s1); - ++npix; - } - ++p1; - - dx = 1; - while((dist = base_type::m_dist[dx] - s1) <= base_type::m_width) - { - dist_end += m_di.dy_end(); - *p1 = 0; - if(dist_end > 0) - { - *p1 = (cover_type)base_type::m_ren.cover(dist); - ++npix; - } - ++p1; - ++dx; - } - - dx = 1; - dist_end = m_di.dist_end(); - while((dist = base_type::m_dist[dx] + s1) <= base_type::m_width) - { - dist_end -= m_di.dy_end(); - *--p0 = 0; - if(dist_end > 0) - { - *p0 = (cover_type)base_type::m_ren.cover(dist); - ++npix; - } - ++dx; - } - base_type::m_ren.blend_solid_hspan(base_type::m_x - dx + 1, - base_type::m_y, - unsigned(p1 - p0), - p0); - return npix && ++base_type::m_step < base_type::m_count; - } - - private: - line_interpolator_aa2(const line_interpolator_aa2&); - const line_interpolator_aa2& - operator = (const line_interpolator_aa2&); - - //--------------------------------------------------------------------- - distance_interpolator2 m_di; - }; - - - - - - - - - - - //====================================================line_interpolator_aa3 - template class line_interpolator_aa3 : - public line_interpolator_aa_base - { - public: - typedef Renderer renderer_type; - typedef typename Renderer::color_type color_type; - typedef line_interpolator_aa_base base_type; - - //--------------------------------------------------------------------- - line_interpolator_aa3(renderer_type& ren, const line_parameters& lp, - int sx, int sy, int ex, int ey) : - line_interpolator_aa_base(ren, lp), - m_di(lp.x1, lp.y1, lp.x2, lp.y2, sx, sy, ex, ey, - lp.x1 & ~line_subpixel_mask, lp.y1 & ~line_subpixel_mask) - { - int dist1_start; - int dist2_start; - int npix = 1; - if(lp.vertical) - { - do - { - --base_type::m_li; - base_type::m_y -= lp.inc; - base_type::m_x = (base_type::m_lp->x1 + base_type::m_li.y()) >> line_subpixel_shift; - - if(lp.inc > 0) m_di.dec_y(base_type::m_x - base_type::m_old_x); - else m_di.inc_y(base_type::m_x - base_type::m_old_x); - - base_type::m_old_x = base_type::m_x; - - dist1_start = dist2_start = m_di.dist_start(); - - int dx = 0; - if(dist1_start < 0) ++npix; - do - { - dist1_start += m_di.dy_start(); - dist2_start -= m_di.dy_start(); - if(dist1_start < 0) ++npix; - if(dist2_start < 0) ++npix; - ++dx; - } - while(base_type::m_dist[dx] <= base_type::m_width); - if(npix == 0) break; - npix = 0; - } - while(--base_type::m_step >= -base_type::m_max_extent); - } - else - { - do - { - --base_type::m_li; - base_type::m_x -= lp.inc; - base_type::m_y = (base_type::m_lp->y1 + base_type::m_li.y()) >> line_subpixel_shift; - - if(lp.inc > 0) m_di.dec_x(base_type::m_y - base_type::m_old_y); - else m_di.inc_x(base_type::m_y - base_type::m_old_y); - - base_type::m_old_y = base_type::m_y; - - dist1_start = dist2_start = m_di.dist_start(); - - int dy = 0; - if(dist1_start < 0) ++npix; - do - { - dist1_start -= m_di.dx_start(); - dist2_start += m_di.dx_start(); - if(dist1_start < 0) ++npix; - if(dist2_start < 0) ++npix; - ++dy; - } - while(base_type::m_dist[dy] <= base_type::m_width); - if(npix == 0) break; - npix = 0; - } - while(--base_type::m_step >= -base_type::m_max_extent); - } - base_type::m_li.adjust_forward(); - base_type::m_step -= base_type::m_max_extent; - } - - - //--------------------------------------------------------------------- - bool step_hor() - { - int dist_start; - int dist_end; - int dist; - int dy; - int s1 = base_type::step_hor_base(m_di); - cover_type* p0 = base_type::m_covers + base_type::max_half_width + 2; - cover_type* p1 = p0; - - dist_start = m_di.dist_start(); - dist_end = m_di.dist_end(); - - int npix = 0; - *p1 = 0; - if(dist_end > 0) - { - if(dist_start <= 0) - { - *p1 = (cover_type)base_type::m_ren.cover(s1); - } - ++npix; - } - ++p1; - - dy = 1; - while((dist = base_type::m_dist[dy] - s1) <= base_type::m_width) - { - dist_start -= m_di.dx_start(); - dist_end -= m_di.dx_end(); - *p1 = 0; - if(dist_end > 0 && dist_start <= 0) - { - *p1 = (cover_type)base_type::m_ren.cover(dist); - ++npix; - } - ++p1; - ++dy; - } - - dy = 1; - dist_start = m_di.dist_start(); - dist_end = m_di.dist_end(); - while((dist = base_type::m_dist[dy] + s1) <= base_type::m_width) - { - dist_start += m_di.dx_start(); - dist_end += m_di.dx_end(); - *--p0 = 0; - if(dist_end > 0 && dist_start <= 0) - { - *p0 = (cover_type)base_type::m_ren.cover(dist); - ++npix; - } - ++dy; - } - base_type::m_ren.blend_solid_vspan(base_type::m_x, - base_type::m_y - dy + 1, - unsigned(p1 - p0), - p0); - return npix && ++base_type::m_step < base_type::m_count; - } - - //--------------------------------------------------------------------- - bool step_ver() - { - int dist_start; - int dist_end; - int dist; - int dx; - int s1 = base_type::step_ver_base(m_di); - cover_type* p0 = base_type::m_covers + base_type::max_half_width + 2; - cover_type* p1 = p0; - - dist_start = m_di.dist_start(); - dist_end = m_di.dist_end(); - - int npix = 0; - *p1 = 0; - if(dist_end > 0) - { - if(dist_start <= 0) - { - *p1 = (cover_type)base_type::m_ren.cover(s1); - } - ++npix; - } - ++p1; - - dx = 1; - while((dist = base_type::m_dist[dx] - s1) <= base_type::m_width) - { - dist_start += m_di.dy_start(); - dist_end += m_di.dy_end(); - *p1 = 0; - if(dist_end > 0 && dist_start <= 0) - { - *p1 = (cover_type)base_type::m_ren.cover(dist); - ++npix; - } - ++p1; - ++dx; - } - - dx = 1; - dist_start = m_di.dist_start(); - dist_end = m_di.dist_end(); - while((dist = base_type::m_dist[dx] + s1) <= base_type::m_width) - { - dist_start -= m_di.dy_start(); - dist_end -= m_di.dy_end(); - *--p0 = 0; - if(dist_end > 0 && dist_start <= 0) - { - *p0 = (cover_type)base_type::m_ren.cover(dist); - ++npix; - } - ++dx; - } - base_type::m_ren.blend_solid_hspan(base_type::m_x - dx + 1, - base_type::m_y, - unsigned(p1 - p0), - p0); - return npix && ++base_type::m_step < base_type::m_count; - } - - private: - line_interpolator_aa3(const line_interpolator_aa3&); - const line_interpolator_aa3& - operator = (const line_interpolator_aa3&); - - //--------------------------------------------------------------------- - distance_interpolator3 m_di; - }; - - - - - //==========================================================line_profile_aa - // - // See Implementation agg_line_profile_aa.cpp - // - class line_profile_aa - { - public: - //--------------------------------------------------------------------- - typedef int8u value_type; - enum subpixel_scale_e - { - subpixel_shift = line_subpixel_shift, - subpixel_scale = 1 << subpixel_shift, - subpixel_mask = subpixel_scale - 1 - }; - - enum aa_scale_e - { - aa_shift = 8, - aa_scale = 1 << aa_shift, - aa_mask = aa_scale - 1 - }; - - //--------------------------------------------------------------------- - line_profile_aa() : - m_subpixel_width(0), - m_min_width(1.0), - m_smoother_width(1.0) - { - int i; - for(i = 0; i < aa_scale; i++) m_gamma[i] = (value_type)i; - } - - //--------------------------------------------------------------------- - template - line_profile_aa(double w, const GammaF& gamma_function) : - m_subpixel_width(0), - m_min_width(1.0), - m_smoother_width(1.0) - { - gamma(gamma_function); - width(w); - } - - //--------------------------------------------------------------------- - void min_width(double w) { m_min_width = w; } - void smoother_width(double w) { m_smoother_width = w; } - - //--------------------------------------------------------------------- - template void gamma(const GammaF& gamma_function) - { - int i; - for(i = 0; i < aa_scale; i++) - { - m_gamma[i] = value_type( - uround(gamma_function(double(i) / aa_mask) * aa_mask)); - } - } - - void width(double w); - - unsigned profile_size() const { return m_profile.size(); } - int subpixel_width() const { return m_subpixel_width; } - - //--------------------------------------------------------------------- - double min_width() const { return m_min_width; } - double smoother_width() const { return m_smoother_width; } - - //--------------------------------------------------------------------- - value_type value(int dist) const - { - return m_profile[dist + subpixel_scale*2]; - } - - private: - line_profile_aa(const line_profile_aa&); - const line_profile_aa& operator = (const line_profile_aa&); - - value_type* profile(double w); - void set(double center_width, double smoother_width); - - //--------------------------------------------------------------------- - pod_array m_profile; - value_type m_gamma[aa_scale]; - int m_subpixel_width; - double m_min_width; - double m_smoother_width; - }; - - - //======================================================renderer_outline_aa - template class renderer_outline_aa - { - public: - //--------------------------------------------------------------------- - typedef BaseRenderer base_ren_type; - typedef renderer_outline_aa self_type; - typedef typename base_ren_type::color_type color_type; - - //--------------------------------------------------------------------- - renderer_outline_aa(base_ren_type& ren, const line_profile_aa& prof) : - m_ren(&ren), - m_profile(&prof), - m_clip_box(0,0,0,0), - m_clipping(false) - {} - void attach(base_ren_type& ren) { m_ren = &ren; } - - //--------------------------------------------------------------------- - void color(const color_type& c) { m_color = c; } - const color_type& color() const { return m_color; } - - //--------------------------------------------------------------------- - void profile(const line_profile_aa& prof) { m_profile = &prof; } - const line_profile_aa& profile() const { return *m_profile; } - line_profile_aa& profile() { return *m_profile; } - - //--------------------------------------------------------------------- - int subpixel_width() const { return m_profile->subpixel_width(); } - - //--------------------------------------------------------------------- - void reset_clipping() { m_clipping = false; } - void clip_box(double x1, double y1, double x2, double y2) - { - m_clip_box.x1 = line_coord_sat::conv(x1); - m_clip_box.y1 = line_coord_sat::conv(y1); - m_clip_box.x2 = line_coord_sat::conv(x2); - m_clip_box.y2 = line_coord_sat::conv(y2); - m_clipping = true; - } - - //--------------------------------------------------------------------- - int cover(int d) const - { - return m_profile->value(d); - } - - //------------------------------------------------------------------------- - void blend_solid_hspan(int x, int y, unsigned len, const cover_type* covers) - { - m_ren->blend_solid_hspan(x, y, len, m_color, covers); - } - - //------------------------------------------------------------------------- - void blend_solid_vspan(int x, int y, unsigned len, const cover_type* covers) - { - m_ren->blend_solid_vspan(x, y, len, m_color, covers); - } - - //------------------------------------------------------------------------- - static bool accurate_join_only() { return false; } - - //------------------------------------------------------------------------- - template - void semidot_hline(Cmp cmp, - int xc1, int yc1, int xc2, int yc2, - int x1, int y1, int x2) - { - cover_type covers[line_interpolator_aa_base::max_half_width * 2 + 4]; - cover_type* p0 = covers; - cover_type* p1 = covers; - int x = x1 << line_subpixel_shift; - int y = y1 << line_subpixel_shift; - int w = subpixel_width(); - distance_interpolator0 di(xc1, yc1, xc2, yc2, x, y); - x += line_subpixel_scale/2; - y += line_subpixel_scale/2; - - int x0 = x1; - int dx = x - xc1; - int dy = y - yc1; - do - { - int d = int(fast_sqrt(dx*dx + dy*dy)); - *p1 = 0; - if(cmp(di.dist()) && d <= w) - { - *p1 = (cover_type)cover(d); - } - ++p1; - dx += line_subpixel_scale; - di.inc_x(); - } - while(++x1 <= x2); - m_ren->blend_solid_hspan(x0, y1, - unsigned(p1 - p0), - color(), - p0); - } - - //------------------------------------------------------------------------- - template - void semidot(Cmp cmp, int xc1, int yc1, int xc2, int yc2) - { - if(m_clipping && clipping_flags(xc1, yc1, m_clip_box)) return; - - int r = ((subpixel_width() + line_subpixel_mask) >> line_subpixel_shift); - if(r < 1) r = 1; - ellipse_bresenham_interpolator ei(r, r); - int dx = 0; - int dy = -r; - int dy0 = dy; - int dx0 = dx; - int x = xc1 >> line_subpixel_shift; - int y = yc1 >> line_subpixel_shift; - - do - { - dx += ei.dx(); - dy += ei.dy(); - - if(dy != dy0) - { - semidot_hline(cmp, xc1, yc1, xc2, yc2, x-dx0, y+dy0, x+dx0); - semidot_hline(cmp, xc1, yc1, xc2, yc2, x-dx0, y-dy0, x+dx0); - } - dx0 = dx; - dy0 = dy; - ++ei; - } - while(dy < 0); - semidot_hline(cmp, xc1, yc1, xc2, yc2, x-dx0, y+dy0, x+dx0); - } - - //------------------------------------------------------------------------- - void pie_hline(int xc, int yc, int xp1, int yp1, int xp2, int yp2, - int xh1, int yh1, int xh2) - { - if(m_clipping && clipping_flags(xc, yc, m_clip_box)) return; - - cover_type covers[line_interpolator_aa_base::max_half_width * 2 + 4]; - cover_type* p0 = covers; - cover_type* p1 = covers; - int x = xh1 << line_subpixel_shift; - int y = yh1 << line_subpixel_shift; - int w = subpixel_width(); - - distance_interpolator00 di(xc, yc, xp1, yp1, xp2, yp2, x, y); - x += line_subpixel_scale/2; - y += line_subpixel_scale/2; - - int xh0 = xh1; - int dx = x - xc; - int dy = y - yc; - do - { - int d = int(fast_sqrt(dx*dx + dy*dy)); - *p1 = 0; - if(di.dist1() <= 0 && di.dist2() > 0 && d <= w) - { - *p1 = (cover_type)cover(d); - } - ++p1; - dx += line_subpixel_scale; - di.inc_x(); - } - while(++xh1 <= xh2); - m_ren->blend_solid_hspan(xh0, yh1, - unsigned(p1 - p0), - color(), - p0); - } - - - //------------------------------------------------------------------------- - void pie(int xc, int yc, int x1, int y1, int x2, int y2) - { - int r = ((subpixel_width() + line_subpixel_mask) >> line_subpixel_shift); - if(r < 1) r = 1; - ellipse_bresenham_interpolator ei(r, r); - int dx = 0; - int dy = -r; - int dy0 = dy; - int dx0 = dx; - int x = xc >> line_subpixel_shift; - int y = yc >> line_subpixel_shift; - - do - { - dx += ei.dx(); - dy += ei.dy(); - - if(dy != dy0) - { - pie_hline(xc, yc, x1, y1, x2, y2, x-dx0, y+dy0, x+dx0); - pie_hline(xc, yc, x1, y1, x2, y2, x-dx0, y-dy0, x+dx0); - } - dx0 = dx; - dy0 = dy; - ++ei; - } - while(dy < 0); - pie_hline(xc, yc, x1, y1, x2, y2, x-dx0, y+dy0, x+dx0); - } - - //------------------------------------------------------------------------- - void line0_no_clip(const line_parameters& lp) - { - if(lp.len > line_max_length) - { - line_parameters lp1, lp2; - lp.divide(lp1, lp2); - line0_no_clip(lp1); - line0_no_clip(lp2); - return; - } - - line_interpolator_aa0 li(*this, lp); - if(li.count()) - { - if(li.vertical()) - { - while(li.step_ver()); - } - else - { - while(li.step_hor()); - } - } - } - - //------------------------------------------------------------------------- - void line0(const line_parameters& lp) - { - if(m_clipping) - { - int x1 = lp.x1; - int y1 = lp.y1; - int x2 = lp.x2; - int y2 = lp.y2; - unsigned flags = clip_line_segment(&x1, &y1, &x2, &y2, m_clip_box); - if((flags & 4) == 0) - { - if(flags) - { - line_parameters lp2(x1, y1, x2, y2, - uround(calc_distance(x1, y1, x2, y2))); - line0_no_clip(lp2); - } - else - { - line0_no_clip(lp); - } - } - } - else - { - line0_no_clip(lp); - } - } - - //------------------------------------------------------------------------- - void line1_no_clip(const line_parameters& lp, int sx, int sy) - { - if(lp.len > line_max_length) - { - line_parameters lp1, lp2; - lp.divide(lp1, lp2); - line1_no_clip(lp1, (lp.x1 + sx) >> 1, (lp.y1 + sy) >> 1); - line1_no_clip(lp2, lp1.x2 + (lp1.y2 - lp1.y1), lp1.y2 - (lp1.x2 - lp1.x1)); - return; - } - - fix_degenerate_bisectrix_start(lp, &sx, &sy); - line_interpolator_aa1 li(*this, lp, sx, sy); - if(li.vertical()) - { - while(li.step_ver()); - } - else - { - while(li.step_hor()); - } - } - - - //------------------------------------------------------------------------- - void line1(const line_parameters& lp, int sx, int sy) - { - if(m_clipping) - { - int x1 = lp.x1; - int y1 = lp.y1; - int x2 = lp.x2; - int y2 = lp.y2; - unsigned flags = clip_line_segment(&x1, &y1, &x2, &y2, m_clip_box); - if((flags & 4) == 0) - { - if(flags) - { - line_parameters lp2(x1, y1, x2, y2, - uround(calc_distance(x1, y1, x2, y2))); - if(flags & 1) - { - sx = x1 + (y2 - y1); - sy = y1 - (x2 - x1); - } - else - { - while(abs(sx - lp.x1) + abs(sy - lp.y1) > lp2.len) - { - sx = (lp.x1 + sx) >> 1; - sy = (lp.y1 + sy) >> 1; - } - } - line1_no_clip(lp2, sx, sy); - } - else - { - line1_no_clip(lp, sx, sy); - } - } - } - else - { - line1_no_clip(lp, sx, sy); - } - } - - //------------------------------------------------------------------------- - void line2_no_clip(const line_parameters& lp, int ex, int ey) - { - if(lp.len > line_max_length) - { - line_parameters lp1, lp2; - lp.divide(lp1, lp2); - line2_no_clip(lp1, lp1.x2 + (lp1.y2 - lp1.y1), lp1.y2 - (lp1.x2 - lp1.x1)); - line2_no_clip(lp2, (lp.x2 + ex) >> 1, (lp.y2 + ey) >> 1); - return; - } - - fix_degenerate_bisectrix_end(lp, &ex, &ey); - line_interpolator_aa2 li(*this, lp, ex, ey); - if(li.vertical()) - { - while(li.step_ver()); - } - else - { - while(li.step_hor()); - } - } - - //------------------------------------------------------------------------- - void line2(const line_parameters& lp, int ex, int ey) - { - if(m_clipping) - { - int x1 = lp.x1; - int y1 = lp.y1; - int x2 = lp.x2; - int y2 = lp.y2; - unsigned flags = clip_line_segment(&x1, &y1, &x2, &y2, m_clip_box); - if((flags & 4) == 0) - { - if(flags) - { - line_parameters lp2(x1, y1, x2, y2, - uround(calc_distance(x1, y1, x2, y2))); - if(flags & 2) - { - ex = x2 + (y2 - y1); - ey = y2 - (x2 - x1); - } - else - { - while(abs(ex - lp.x2) + abs(ey - lp.y2) > lp2.len) - { - ex = (lp.x2 + ex) >> 1; - ey = (lp.y2 + ey) >> 1; - } - } - line2_no_clip(lp2, ex, ey); - } - else - { - line2_no_clip(lp, ex, ey); - } - } - } - else - { - line2_no_clip(lp, ex, ey); - } - } - - //------------------------------------------------------------------------- - void line3_no_clip(const line_parameters& lp, - int sx, int sy, int ex, int ey) - { - if(lp.len > line_max_length) - { - line_parameters lp1, lp2; - lp.divide(lp1, lp2); - int mx = lp1.x2 + (lp1.y2 - lp1.y1); - int my = lp1.y2 - (lp1.x2 - lp1.x1); - line3_no_clip(lp1, (lp.x1 + sx) >> 1, (lp.y1 + sy) >> 1, mx, my); - line3_no_clip(lp2, mx, my, (lp.x2 + ex) >> 1, (lp.y2 + ey) >> 1); - return; - } - - fix_degenerate_bisectrix_start(lp, &sx, &sy); - fix_degenerate_bisectrix_end(lp, &ex, &ey); - line_interpolator_aa3 li(*this, lp, sx, sy, ex, ey); - if(li.vertical()) - { - while(li.step_ver()); - } - else - { - while(li.step_hor()); - } - } - - //------------------------------------------------------------------------- - void line3(const line_parameters& lp, - int sx, int sy, int ex, int ey) - { - if(m_clipping) - { - int x1 = lp.x1; - int y1 = lp.y1; - int x2 = lp.x2; - int y2 = lp.y2; - unsigned flags = clip_line_segment(&x1, &y1, &x2, &y2, m_clip_box); - if((flags & 4) == 0) - { - if(flags) - { - line_parameters lp2(x1, y1, x2, y2, - uround(calc_distance(x1, y1, x2, y2))); - if(flags & 1) - { - sx = x1 + (y2 - y1); - sy = y1 - (x2 - x1); - } - else - { - while(abs(sx - lp.x1) + abs(sy - lp.y1) > lp2.len) - { - sx = (lp.x1 + sx) >> 1; - sy = (lp.y1 + sy) >> 1; - } - } - if(flags & 2) - { - ex = x2 + (y2 - y1); - ey = y2 - (x2 - x1); - } - else - { - while(abs(ex - lp.x2) + abs(ey - lp.y2) > lp2.len) - { - ex = (lp.x2 + ex) >> 1; - ey = (lp.y2 + ey) >> 1; - } - } - line3_no_clip(lp2, sx, sy, ex, ey); - } - else - { - line3_no_clip(lp, sx, sy, ex, ey); - } - } - } - else - { - line3_no_clip(lp, sx, sy, ex, ey); - } - } - - - private: - base_ren_type* m_ren; - const line_profile_aa* m_profile; - color_type m_color; - rect_i m_clip_box; - bool m_clipping; - }; - - - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_renderer_outline_image.h b/desmume/src/windows/agg/include/agg_renderer_outline_image.h deleted file mode 100644 index cedf6e83f..000000000 --- a/desmume/src/windows/agg/include/agg_renderer_outline_image.h +++ /dev/null @@ -1,1023 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_RENDERER_OUTLINE_IMAGE_INCLUDED -#define AGG_RENDERER_OUTLINE_IMAGE_INCLUDED - -#include "agg_array.h" -#include "agg_math.h" -#include "agg_line_aa_basics.h" -#include "agg_dda_line.h" -#include "agg_rendering_buffer.h" -#include "agg_clip_liang_barsky.h" - - -namespace agg -{ - //========================================================line_image_scale - template class line_image_scale - { - public: - typedef typename Source::color_type color_type; - - line_image_scale(const Source& src, double height) : - m_source(src), - m_height(height), - m_scale(src.height() / height) - { - } - - double width() const { return m_source.width(); } - double height() const { return m_height; } - - color_type pixel(int x, int y) const - { - double src_y = (y + 0.5) * m_scale - 0.5; - int h = m_source.height() - 1; - int y1 = ufloor(src_y); - int y2 = y1 + 1; - color_type pix1 = (y1 < 0) ? color_type::no_color() : m_source.pixel(x, y1); - color_type pix2 = (y2 > h) ? color_type::no_color() : m_source.pixel(x, y2); - return pix1.gradient(pix2, src_y - y1); - } - - private: - line_image_scale(const line_image_scale&); - const line_image_scale& operator = (const line_image_scale&); - - const Source& m_source; - double m_height; - double m_scale; - }; - - - - //======================================================line_image_pattern - template class line_image_pattern - { - public: - typedef Filter filter_type; - typedef typename filter_type::color_type color_type; - - //-------------------------------------------------------------------- - line_image_pattern(const Filter& filter) : - m_filter(&filter), - m_dilation(filter.dilation() + 1), - m_dilation_hr(m_dilation << line_subpixel_shift), - m_data(), - m_width(0), - m_height(0), - m_width_hr(0), - m_half_height_hr(0), - m_offset_y_hr(0) - { - } - - // Create - //-------------------------------------------------------------------- - template - line_image_pattern(const Filter& filter, const Source& src) : - m_filter(&filter), - m_dilation(filter.dilation() + 1), - m_dilation_hr(m_dilation << line_subpixel_shift), - m_data(), - m_width(0), - m_height(0), - m_width_hr(0), - m_half_height_hr(0), - m_offset_y_hr(0) - { - create(src); - } - - // Create - //-------------------------------------------------------------------- - template void create(const Source& src) - { - m_height = uceil(src.height()); - m_width = uceil(src.width()); - m_width_hr = uround(src.width() * line_subpixel_scale); - m_half_height_hr = uround(src.height() * line_subpixel_scale/2); - m_offset_y_hr = m_dilation_hr + m_half_height_hr - line_subpixel_scale/2; - m_half_height_hr += line_subpixel_scale/2; - - m_data.resize((m_width + m_dilation * 2) * (m_height + m_dilation * 2)); - - m_buf.attach(&m_data[0], m_width + m_dilation * 2, - m_height + m_dilation * 2, - m_width + m_dilation * 2); - unsigned x, y; - color_type* d1; - color_type* d2; - for(y = 0; y < m_height; y++) - { - d1 = m_buf.row_ptr(y + m_dilation) + m_dilation; - for(x = 0; x < m_width; x++) - { - *d1++ = src.pixel(x, y); - } - } - - const color_type* s1; - const color_type* s2; - for(y = 0; y < m_dilation; y++) - { - //s1 = m_buf.row_ptr(m_height + m_dilation - 1) + m_dilation; - //s2 = m_buf.row_ptr(m_dilation) + m_dilation; - d1 = m_buf.row_ptr(m_dilation + m_height + y) + m_dilation; - d2 = m_buf.row_ptr(m_dilation - y - 1) + m_dilation; - for(x = 0; x < m_width; x++) - { - //*d1++ = color_type(*s1++, 0); - //*d2++ = color_type(*s2++, 0); - *d1++ = color_type::no_color(); - *d2++ = color_type::no_color(); - } - } - - unsigned h = m_height + m_dilation * 2; - for(y = 0; y < h; y++) - { - s1 = m_buf.row_ptr(y) + m_dilation; - s2 = m_buf.row_ptr(y) + m_dilation + m_width; - d1 = m_buf.row_ptr(y) + m_dilation + m_width; - d2 = m_buf.row_ptr(y) + m_dilation; - - for(x = 0; x < m_dilation; x++) - { - *d1++ = *s1++; - *--d2 = *--s2; - } - } - } - - //-------------------------------------------------------------------- - int pattern_width() const { return m_width_hr; } - int line_width() const { return m_half_height_hr; } - double width() const { return m_height; } - - //-------------------------------------------------------------------- - void pixel(color_type* p, int x, int y) const - { - m_filter->pixel_high_res(m_buf.rows(), - p, - x % m_width_hr + m_dilation_hr, - y + m_offset_y_hr); - } - - //-------------------------------------------------------------------- - const filter_type& filter() const { return *m_filter; } - - private: - line_image_pattern(const line_image_pattern&); - const line_image_pattern& - operator = (const line_image_pattern&); - - protected: - row_ptr_cache m_buf; - const filter_type* m_filter; - unsigned m_dilation; - int m_dilation_hr; - pod_array m_data; - unsigned m_width; - unsigned m_height; - int m_width_hr; - int m_half_height_hr; - int m_offset_y_hr; - }; - - - - - - - //=================================================line_image_pattern_pow2 - template class line_image_pattern_pow2 : - public line_image_pattern - { - public: - typedef Filter filter_type; - typedef typename filter_type::color_type color_type; - typedef line_image_pattern base_type; - - //-------------------------------------------------------------------- - line_image_pattern_pow2(const Filter& filter) : - line_image_pattern(filter), m_mask(line_subpixel_mask) {} - - //-------------------------------------------------------------------- - template - line_image_pattern_pow2(const Filter& filter, const Source& src) : - line_image_pattern(filter), m_mask(line_subpixel_mask) - { - create(src); - } - - //-------------------------------------------------------------------- - template void create(const Source& src) - { - line_image_pattern::create(src); - m_mask = 1; - while(m_mask < base_type::m_width) - { - m_mask <<= 1; - m_mask |= 1; - } - m_mask <<= line_subpixel_shift - 1; - m_mask |= line_subpixel_mask; - base_type::m_width_hr = m_mask + 1; - } - - //-------------------------------------------------------------------- - void pixel(color_type* p, int x, int y) const - { - base_type::m_filter->pixel_high_res( - base_type::m_buf.rows(), - p, - (x & m_mask) + base_type::m_dilation_hr, - y + base_type::m_offset_y_hr); - } - private: - unsigned m_mask; - }; - - - - - - - - //===================================================distance_interpolator4 - class distance_interpolator4 - { - public: - //--------------------------------------------------------------------- - distance_interpolator4() {} - distance_interpolator4(int x1, int y1, int x2, int y2, - int sx, int sy, int ex, int ey, - int len, double scale, int x, int y) : - m_dx(x2 - x1), - m_dy(y2 - y1), - m_dx_start(line_mr(sx) - line_mr(x1)), - m_dy_start(line_mr(sy) - line_mr(y1)), - m_dx_end(line_mr(ex) - line_mr(x2)), - m_dy_end(line_mr(ey) - line_mr(y2)), - - m_dist(iround(double(x + line_subpixel_scale/2 - x2) * double(m_dy) - - double(y + line_subpixel_scale/2 - y2) * double(m_dx))), - - m_dist_start((line_mr(x + line_subpixel_scale/2) - line_mr(sx)) * m_dy_start - - (line_mr(y + line_subpixel_scale/2) - line_mr(sy)) * m_dx_start), - - m_dist_end((line_mr(x + line_subpixel_scale/2) - line_mr(ex)) * m_dy_end - - (line_mr(y + line_subpixel_scale/2) - line_mr(ey)) * m_dx_end), - m_len(uround(len / scale)) - { - double d = len * scale; - int dx = iround(((x2 - x1) << line_subpixel_shift) / d); - int dy = iround(((y2 - y1) << line_subpixel_shift) / d); - m_dx_pict = -dy; - m_dy_pict = dx; - m_dist_pict = ((x + line_subpixel_scale/2 - (x1 - dy)) * m_dy_pict - - (y + line_subpixel_scale/2 - (y1 + dx)) * m_dx_pict) >> - line_subpixel_shift; - - m_dx <<= line_subpixel_shift; - m_dy <<= line_subpixel_shift; - m_dx_start <<= line_mr_subpixel_shift; - m_dy_start <<= line_mr_subpixel_shift; - m_dx_end <<= line_mr_subpixel_shift; - m_dy_end <<= line_mr_subpixel_shift; - } - - //--------------------------------------------------------------------- - void inc_x() - { - m_dist += m_dy; - m_dist_start += m_dy_start; - m_dist_pict += m_dy_pict; - m_dist_end += m_dy_end; - } - - //--------------------------------------------------------------------- - void dec_x() - { - m_dist -= m_dy; - m_dist_start -= m_dy_start; - m_dist_pict -= m_dy_pict; - m_dist_end -= m_dy_end; - } - - //--------------------------------------------------------------------- - void inc_y() - { - m_dist -= m_dx; - m_dist_start -= m_dx_start; - m_dist_pict -= m_dx_pict; - m_dist_end -= m_dx_end; - } - - //--------------------------------------------------------------------- - void dec_y() - { - m_dist += m_dx; - m_dist_start += m_dx_start; - m_dist_pict += m_dx_pict; - m_dist_end += m_dx_end; - } - - //--------------------------------------------------------------------- - void inc_x(int dy) - { - m_dist += m_dy; - m_dist_start += m_dy_start; - m_dist_pict += m_dy_pict; - m_dist_end += m_dy_end; - if(dy > 0) - { - m_dist -= m_dx; - m_dist_start -= m_dx_start; - m_dist_pict -= m_dx_pict; - m_dist_end -= m_dx_end; - } - if(dy < 0) - { - m_dist += m_dx; - m_dist_start += m_dx_start; - m_dist_pict += m_dx_pict; - m_dist_end += m_dx_end; - } - } - - //--------------------------------------------------------------------- - void dec_x(int dy) - { - m_dist -= m_dy; - m_dist_start -= m_dy_start; - m_dist_pict -= m_dy_pict; - m_dist_end -= m_dy_end; - if(dy > 0) - { - m_dist -= m_dx; - m_dist_start -= m_dx_start; - m_dist_pict -= m_dx_pict; - m_dist_end -= m_dx_end; - } - if(dy < 0) - { - m_dist += m_dx; - m_dist_start += m_dx_start; - m_dist_pict += m_dx_pict; - m_dist_end += m_dx_end; - } - } - - //--------------------------------------------------------------------- - void inc_y(int dx) - { - m_dist -= m_dx; - m_dist_start -= m_dx_start; - m_dist_pict -= m_dx_pict; - m_dist_end -= m_dx_end; - if(dx > 0) - { - m_dist += m_dy; - m_dist_start += m_dy_start; - m_dist_pict += m_dy_pict; - m_dist_end += m_dy_end; - } - if(dx < 0) - { - m_dist -= m_dy; - m_dist_start -= m_dy_start; - m_dist_pict -= m_dy_pict; - m_dist_end -= m_dy_end; - } - } - - //--------------------------------------------------------------------- - void dec_y(int dx) - { - m_dist += m_dx; - m_dist_start += m_dx_start; - m_dist_pict += m_dx_pict; - m_dist_end += m_dx_end; - if(dx > 0) - { - m_dist += m_dy; - m_dist_start += m_dy_start; - m_dist_pict += m_dy_pict; - m_dist_end += m_dy_end; - } - if(dx < 0) - { - m_dist -= m_dy; - m_dist_start -= m_dy_start; - m_dist_pict -= m_dy_pict; - m_dist_end -= m_dy_end; - } - } - - //--------------------------------------------------------------------- - int dist() const { return m_dist; } - int dist_start() const { return m_dist_start; } - int dist_pict() const { return m_dist_pict; } - int dist_end() const { return m_dist_end; } - - //--------------------------------------------------------------------- - int dx() const { return m_dx; } - int dy() const { return m_dy; } - int dx_start() const { return m_dx_start; } - int dy_start() const { return m_dy_start; } - int dx_pict() const { return m_dx_pict; } - int dy_pict() const { return m_dy_pict; } - int dx_end() const { return m_dx_end; } - int dy_end() const { return m_dy_end; } - int len() const { return m_len; } - - private: - //--------------------------------------------------------------------- - int m_dx; - int m_dy; - int m_dx_start; - int m_dy_start; - int m_dx_pict; - int m_dy_pict; - int m_dx_end; - int m_dy_end; - - int m_dist; - int m_dist_start; - int m_dist_pict; - int m_dist_end; - int m_len; - }; - - - - - - //==================================================line_interpolator_image - template class line_interpolator_image - { - public: - typedef Renderer renderer_type; - typedef typename Renderer::color_type color_type; - - //--------------------------------------------------------------------- - enum max_half_width_e - { - max_half_width = 64 - }; - - //--------------------------------------------------------------------- - line_interpolator_image(renderer_type& ren, const line_parameters& lp, - int sx, int sy, int ex, int ey, - int pattern_start, - double scale_x) : - m_lp(lp), - m_li(lp.vertical ? line_dbl_hr(lp.x2 - lp.x1) : - line_dbl_hr(lp.y2 - lp.y1), - lp.vertical ? abs(lp.y2 - lp.y1) : - abs(lp.x2 - lp.x1) + 1), - m_di(lp.x1, lp.y1, lp.x2, lp.y2, sx, sy, ex, ey, lp.len, scale_x, - lp.x1 & ~line_subpixel_mask, lp.y1 & ~line_subpixel_mask), - m_ren(ren), - m_x(lp.x1 >> line_subpixel_shift), - m_y(lp.y1 >> line_subpixel_shift), - m_old_x(m_x), - m_old_y(m_y), - m_count((lp.vertical ? abs((lp.y2 >> line_subpixel_shift) - m_y) : - abs((lp.x2 >> line_subpixel_shift) - m_x))), - m_width(ren.subpixel_width()), - //m_max_extent(m_width >> (line_subpixel_shift - 2)), - m_max_extent((m_width + line_subpixel_scale) >> line_subpixel_shift), - m_start(pattern_start + (m_max_extent + 2) * ren.pattern_width()), - m_step(0) - { - agg::dda2_line_interpolator li(0, lp.vertical ? - (lp.dy << agg::line_subpixel_shift) : - (lp.dx << agg::line_subpixel_shift), - lp.len); - - unsigned i; - int stop = m_width + line_subpixel_scale * 2; - for(i = 0; i < max_half_width; ++i) - { - m_dist_pos[i] = li.y(); - if(m_dist_pos[i] >= stop) break; - ++li; - } - m_dist_pos[i] = 0x7FFF0000; - - int dist1_start; - int dist2_start; - int npix = 1; - - if(lp.vertical) - { - do - { - --m_li; - m_y -= lp.inc; - m_x = (m_lp.x1 + m_li.y()) >> line_subpixel_shift; - - if(lp.inc > 0) m_di.dec_y(m_x - m_old_x); - else m_di.inc_y(m_x - m_old_x); - - m_old_x = m_x; - - dist1_start = dist2_start = m_di.dist_start(); - - int dx = 0; - if(dist1_start < 0) ++npix; - do - { - dist1_start += m_di.dy_start(); - dist2_start -= m_di.dy_start(); - if(dist1_start < 0) ++npix; - if(dist2_start < 0) ++npix; - ++dx; - } - while(m_dist_pos[dx] <= m_width); - if(npix == 0) break; - - npix = 0; - } - while(--m_step >= -m_max_extent); - } - else - { - do - { - --m_li; - - m_x -= lp.inc; - m_y = (m_lp.y1 + m_li.y()) >> line_subpixel_shift; - - if(lp.inc > 0) m_di.dec_x(m_y - m_old_y); - else m_di.inc_x(m_y - m_old_y); - - m_old_y = m_y; - - dist1_start = dist2_start = m_di.dist_start(); - - int dy = 0; - if(dist1_start < 0) ++npix; - do - { - dist1_start -= m_di.dx_start(); - dist2_start += m_di.dx_start(); - if(dist1_start < 0) ++npix; - if(dist2_start < 0) ++npix; - ++dy; - } - while(m_dist_pos[dy] <= m_width); - if(npix == 0) break; - - npix = 0; - } - while(--m_step >= -m_max_extent); - } - m_li.adjust_forward(); - m_step -= m_max_extent; - } - - //--------------------------------------------------------------------- - bool step_hor() - { - ++m_li; - m_x += m_lp.inc; - m_y = (m_lp.y1 + m_li.y()) >> line_subpixel_shift; - - if(m_lp.inc > 0) m_di.inc_x(m_y - m_old_y); - else m_di.dec_x(m_y - m_old_y); - - m_old_y = m_y; - - int s1 = m_di.dist() / m_lp.len; - int s2 = -s1; - - if(m_lp.inc < 0) s1 = -s1; - - int dist_start; - int dist_pict; - int dist_end; - int dy; - int dist; - - dist_start = m_di.dist_start(); - dist_pict = m_di.dist_pict() + m_start; - dist_end = m_di.dist_end(); - color_type* p0 = m_colors + max_half_width + 2; - color_type* p1 = p0; - - int npix = 0; - p1->clear(); - if(dist_end > 0) - { - if(dist_start <= 0) - { - m_ren.pixel(p1, dist_pict, s2); - } - ++npix; - } - ++p1; - - dy = 1; - while((dist = m_dist_pos[dy]) - s1 <= m_width) - { - dist_start -= m_di.dx_start(); - dist_pict -= m_di.dx_pict(); - dist_end -= m_di.dx_end(); - p1->clear(); - if(dist_end > 0 && dist_start <= 0) - { - if(m_lp.inc > 0) dist = -dist; - m_ren.pixel(p1, dist_pict, s2 - dist); - ++npix; - } - ++p1; - ++dy; - } - - dy = 1; - dist_start = m_di.dist_start(); - dist_pict = m_di.dist_pict() + m_start; - dist_end = m_di.dist_end(); - while((dist = m_dist_pos[dy]) + s1 <= m_width) - { - dist_start += m_di.dx_start(); - dist_pict += m_di.dx_pict(); - dist_end += m_di.dx_end(); - --p0; - p0->clear(); - if(dist_end > 0 && dist_start <= 0) - { - if(m_lp.inc > 0) dist = -dist; - m_ren.pixel(p0, dist_pict, s2 + dist); - ++npix; - } - ++dy; - } - m_ren.blend_color_vspan(m_x, - m_y - dy + 1, - unsigned(p1 - p0), - p0); - return npix && ++m_step < m_count; - } - - - - //--------------------------------------------------------------------- - bool step_ver() - { - ++m_li; - m_y += m_lp.inc; - m_x = (m_lp.x1 + m_li.y()) >> line_subpixel_shift; - - if(m_lp.inc > 0) m_di.inc_y(m_x - m_old_x); - else m_di.dec_y(m_x - m_old_x); - - m_old_x = m_x; - - int s1 = m_di.dist() / m_lp.len; - int s2 = -s1; - - if(m_lp.inc > 0) s1 = -s1; - - int dist_start; - int dist_pict; - int dist_end; - int dist; - int dx; - - dist_start = m_di.dist_start(); - dist_pict = m_di.dist_pict() + m_start; - dist_end = m_di.dist_end(); - color_type* p0 = m_colors + max_half_width + 2; - color_type* p1 = p0; - - int npix = 0; - p1->clear(); - if(dist_end > 0) - { - if(dist_start <= 0) - { - m_ren.pixel(p1, dist_pict, s2); - } - ++npix; - } - ++p1; - - dx = 1; - while((dist = m_dist_pos[dx]) - s1 <= m_width) - { - dist_start += m_di.dy_start(); - dist_pict += m_di.dy_pict(); - dist_end += m_di.dy_end(); - p1->clear(); - if(dist_end > 0 && dist_start <= 0) - { - if(m_lp.inc > 0) dist = -dist; - m_ren.pixel(p1, dist_pict, s2 + dist); - ++npix; - } - ++p1; - ++dx; - } - - dx = 1; - dist_start = m_di.dist_start(); - dist_pict = m_di.dist_pict() + m_start; - dist_end = m_di.dist_end(); - while((dist = m_dist_pos[dx]) + s1 <= m_width) - { - dist_start -= m_di.dy_start(); - dist_pict -= m_di.dy_pict(); - dist_end -= m_di.dy_end(); - --p0; - p0->clear(); - if(dist_end > 0 && dist_start <= 0) - { - if(m_lp.inc > 0) dist = -dist; - m_ren.pixel(p0, dist_pict, s2 - dist); - ++npix; - } - ++dx; - } - m_ren.blend_color_hspan(m_x - dx + 1, - m_y, - unsigned(p1 - p0), - p0); - return npix && ++m_step < m_count; - } - - - //--------------------------------------------------------------------- - int pattern_end() const { return m_start + m_di.len(); } - - //--------------------------------------------------------------------- - bool vertical() const { return m_lp.vertical; } - int width() const { return m_width; } - int count() const { return m_count; } - - private: - line_interpolator_image(const line_interpolator_image&); - const line_interpolator_image& - operator = (const line_interpolator_image&); - - protected: - const line_parameters& m_lp; - dda2_line_interpolator m_li; - distance_interpolator4 m_di; - renderer_type& m_ren; - int m_plen; - int m_x; - int m_y; - int m_old_x; - int m_old_y; - int m_count; - int m_width; - int m_max_extent; - int m_start; - int m_step; - int m_dist_pos[max_half_width + 1]; - color_type m_colors[max_half_width * 2 + 4]; - }; - - - - - - - - - //===================================================renderer_outline_image - template - class renderer_outline_image - { - public: - //--------------------------------------------------------------------- - typedef BaseRenderer base_ren_type; - typedef renderer_outline_image self_type; - typedef typename base_ren_type::color_type color_type; - typedef ImagePattern pattern_type; - - - //--------------------------------------------------------------------- - renderer_outline_image(base_ren_type& ren, const pattern_type& patt) : - m_ren(&ren), - m_pattern(&patt), - m_start(0), - m_scale_x(1.0), - m_clip_box(0,0,0,0), - m_clipping(false) - {} - void attach(base_ren_type& ren) { m_ren = &ren; } - - //--------------------------------------------------------------------- - void pattern(const pattern_type& p) { m_pattern = &p; } - const pattern_type& pattern() const { return *m_pattern; } - - //--------------------------------------------------------------------- - void reset_clipping() { m_clipping = false; } - void clip_box(double x1, double y1, double x2, double y2) - { - m_clip_box.x1 = line_coord_sat::conv(x1); - m_clip_box.y1 = line_coord_sat::conv(y1); - m_clip_box.x2 = line_coord_sat::conv(x2); - m_clip_box.y2 = line_coord_sat::conv(y2); - m_clipping = true; - } - - //--------------------------------------------------------------------- - void scale_x(double s) { m_scale_x = s; } - double scale_x() const { return m_scale_x; } - - //--------------------------------------------------------------------- - void start_x(double s) { m_start = iround(s * line_subpixel_scale); } - double start_x() const { return double(m_start) / line_subpixel_scale; } - - //--------------------------------------------------------------------- - int subpixel_width() const { return m_pattern->line_width(); } - int pattern_width() const { return m_pattern->pattern_width(); } - double width() const { return double(subpixel_width()) / line_subpixel_scale; } - - //------------------------------------------------------------------------- - void pixel(color_type* p, int x, int y) const - { - m_pattern->pixel(p, x, y); - } - - //------------------------------------------------------------------------- - void blend_color_hspan(int x, int y, unsigned len, const color_type* colors) - { - m_ren->blend_color_hspan(x, y, len, colors, 0); - } - - //------------------------------------------------------------------------- - void blend_color_vspan(int x, int y, unsigned len, const color_type* colors) - { - m_ren->blend_color_vspan(x, y, len, colors, 0); - } - - //------------------------------------------------------------------------- - static bool accurate_join_only() { return true; } - - //------------------------------------------------------------------------- - template - void semidot(Cmp, int, int, int, int) - { - } - - //------------------------------------------------------------------------- - void pie(int, int, int, int, int, int) - { - } - - //------------------------------------------------------------------------- - void line0(const line_parameters&) - { - } - - //------------------------------------------------------------------------- - void line1(const line_parameters&, int, int) - { - } - - //------------------------------------------------------------------------- - void line2(const line_parameters&, int, int) - { - } - - //------------------------------------------------------------------------- - void line3_no_clip(const line_parameters& lp, - int sx, int sy, int ex, int ey) - { - if(lp.len > line_max_length) - { - line_parameters lp1, lp2; - lp.divide(lp1, lp2); - int mx = lp1.x2 + (lp1.y2 - lp1.y1); - int my = lp1.y2 - (lp1.x2 - lp1.x1); - line3_no_clip(lp1, (lp.x1 + sx) >> 1, (lp.y1 + sy) >> 1, mx, my); - line3_no_clip(lp2, mx, my, (lp.x2 + ex) >> 1, (lp.y2 + ey) >> 1); - return; - } - - fix_degenerate_bisectrix_start(lp, &sx, &sy); - fix_degenerate_bisectrix_end(lp, &ex, &ey); - line_interpolator_image li(*this, lp, - sx, sy, - ex, ey, - m_start, m_scale_x); - if(li.vertical()) - { - while(li.step_ver()); - } - else - { - while(li.step_hor()); - } - m_start += uround(lp.len / m_scale_x); - } - - //------------------------------------------------------------------------- - void line3(const line_parameters& lp, - int sx, int sy, int ex, int ey) - { - if(m_clipping) - { - int x1 = lp.x1; - int y1 = lp.y1; - int x2 = lp.x2; - int y2 = lp.y2; - unsigned flags = clip_line_segment(&x1, &y1, &x2, &y2, m_clip_box); - int start = m_start; - if((flags & 4) == 0) - { - if(flags) - { - line_parameters lp2(x1, y1, x2, y2, - uround(calc_distance(x1, y1, x2, y2))); - if(flags & 1) - { - m_start += uround(calc_distance(lp.x1, lp.y1, x1, y1) / m_scale_x); - sx = x1 + (y2 - y1); - sy = y1 - (x2 - x1); - } - else - { - while(abs(sx - lp.x1) + abs(sy - lp.y1) > lp2.len) - { - sx = (lp.x1 + sx) >> 1; - sy = (lp.y1 + sy) >> 1; - } - } - if(flags & 2) - { - ex = x2 + (y2 - y1); - ey = y2 - (x2 - x1); - } - else - { - while(abs(ex - lp.x2) + abs(ey - lp.y2) > lp2.len) - { - ex = (lp.x2 + ex) >> 1; - ey = (lp.y2 + ey) >> 1; - } - } - line3_no_clip(lp2, sx, sy, ex, ey); - } - else - { - line3_no_clip(lp, sx, sy, ex, ey); - } - } - m_start = start + uround(lp.len / m_scale_x); - } - else - { - line3_no_clip(lp, sx, sy, ex, ey); - } - } - - private: - base_ren_type* m_ren; - const pattern_type* m_pattern; - int m_start; - double m_scale_x; - rect_i m_clip_box; - bool m_clipping; - }; - - - - - -} - - - -#endif diff --git a/desmume/src/windows/agg/include/agg_renderer_primitives.h b/desmume/src/windows/agg/include/agg_renderer_primitives.h deleted file mode 100644 index d999f8b56..000000000 --- a/desmume/src/windows/agg/include/agg_renderer_primitives.h +++ /dev/null @@ -1,229 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_RENDERER_PRIMITIVES_INCLUDED -#define AGG_RENDERER_PRIMITIVES_INCLUDED - -#include "agg_basics.h" -#include "agg_renderer_base.h" -#include "agg_dda_line.h" -#include "agg_ellipse_bresenham.h" - -namespace agg -{ - //-----------------------------------------------------renderer_primitives - template class renderer_primitives - { - public: - typedef BaseRenderer base_ren_type; - typedef typename base_ren_type::color_type color_type; - - //-------------------------------------------------------------------- - explicit renderer_primitives(base_ren_type& ren) : - m_ren(&ren), - m_fill_color(), - m_line_color(), - m_curr_x(0), - m_curr_y(0) - {} - void attach(base_ren_type& ren) { m_ren = &ren; } - - //-------------------------------------------------------------------- - static int coord(double c) - { - return iround(c * line_bresenham_interpolator::subpixel_scale); - } - - //-------------------------------------------------------------------- - void fill_color(const color_type& c) { m_fill_color = c; } - void line_color(const color_type& c) { m_line_color = c; } - const color_type& fill_color() const { return m_fill_color; } - const color_type& line_color() const { return m_line_color; } - - //-------------------------------------------------------------------- - void rectangle(int x1, int y1, int x2, int y2) - { - m_ren->blend_hline(x1, y1, x2-1, m_line_color, cover_full); - m_ren->blend_vline(x2, y1, y2-1, m_line_color, cover_full); - m_ren->blend_hline(x1+1, y2, x2, m_line_color, cover_full); - m_ren->blend_vline(x1, y1+1, y2, m_line_color, cover_full); - } - - //-------------------------------------------------------------------- - void solid_rectangle(int x1, int y1, int x2, int y2) - { - m_ren->blend_bar(x1, y1, x2, y2, m_fill_color, cover_full); - } - - //-------------------------------------------------------------------- - void outlined_rectangle(int x1, int y1, int x2, int y2) - { - rectangle(x1, y1, x2, y2); - m_ren->blend_bar(x1+1, y1+1, x2-1, y2-1, m_fill_color, cover_full); - } - - //-------------------------------------------------------------------- - void ellipse(int x, int y, int rx, int ry) - { - ellipse_bresenham_interpolator ei(rx, ry); - int dx = 0; - int dy = -ry; - do - { - dx += ei.dx(); - dy += ei.dy(); - m_ren->blend_pixel(x + dx, y + dy, m_line_color, cover_full); - m_ren->blend_pixel(x + dx, y - dy, m_line_color, cover_full); - m_ren->blend_pixel(x - dx, y - dy, m_line_color, cover_full); - m_ren->blend_pixel(x - dx, y + dy, m_line_color, cover_full); - ++ei; - } - while(dy < 0); - } - - //-------------------------------------------------------------------- - void solid_ellipse(int x, int y, int rx, int ry) - { - ellipse_bresenham_interpolator ei(rx, ry); - int dx = 0; - int dy = -ry; - int dy0 = dy; - int dx0 = dx; - - do - { - dx += ei.dx(); - dy += ei.dy(); - - if(dy != dy0) - { - m_ren->blend_hline(x-dx0, y+dy0, x+dx0, m_fill_color, cover_full); - m_ren->blend_hline(x-dx0, y-dy0, x+dx0, m_fill_color, cover_full); - } - dx0 = dx; - dy0 = dy; - ++ei; - } - while(dy < 0); - m_ren->blend_hline(x-dx0, y+dy0, x+dx0, m_fill_color, cover_full); - } - - //-------------------------------------------------------------------- - void outlined_ellipse(int x, int y, int rx, int ry) - { - ellipse_bresenham_interpolator ei(rx, ry); - int dx = 0; - int dy = -ry; - - do - { - dx += ei.dx(); - dy += ei.dy(); - - m_ren->blend_pixel(x + dx, y + dy, m_line_color, cover_full); - m_ren->blend_pixel(x + dx, y - dy, m_line_color, cover_full); - m_ren->blend_pixel(x - dx, y - dy, m_line_color, cover_full); - m_ren->blend_pixel(x - dx, y + dy, m_line_color, cover_full); - - if(ei.dy() && dx) - { - m_ren->blend_hline(x-dx+1, y+dy, x+dx-1, m_fill_color, cover_full); - m_ren->blend_hline(x-dx+1, y-dy, x+dx-1, m_fill_color, cover_full); - } - ++ei; - } - while(dy < 0); - } - - //-------------------------------------------------------------------- - void line(int x1, int y1, int x2, int y2, bool last=false) - { - line_bresenham_interpolator li(x1, y1, x2, y2); - - unsigned len = li.len(); - if(len == 0) - { - if(last) - { - m_ren->blend_pixel(li.line_lr(x1), li.line_lr(y1), m_line_color, cover_full); - } - return; - } - - if(last) ++len; - - if(li.is_ver()) - { - do - { - m_ren->blend_pixel(li.x2(), li.y1(), m_line_color, cover_full); - li.vstep(); - } - while(--len); - } - else - { - do - { - m_ren->blend_pixel(li.x1(), li.y2(), m_line_color, cover_full); - li.hstep(); - } - while(--len); - } - } - - //-------------------------------------------------------------------- - void move_to(int x, int y) - { - m_curr_x = x; - m_curr_y = y; - } - - //-------------------------------------------------------------------- - void line_to(int x, int y, bool last=false) - { - line(m_curr_x, m_curr_y, x, y, last); - m_curr_x = x; - m_curr_y = y; - } - - //-------------------------------------------------------------------- - const base_ren_type& ren() const { return *m_ren; } - base_ren_type& ren() { return *m_ren; } - - //-------------------------------------------------------------------- - const rendering_buffer& rbuf() const { return m_ren->rbuf(); } - rendering_buffer& rbuf() { return m_ren->rbuf(); } - - private: - base_ren_type* m_ren; - color_type m_fill_color; - color_type m_line_color; - int m_curr_x; - int m_curr_y; - }; - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_renderer_raster_text.h b/desmume/src/windows/agg/include/agg_renderer_raster_text.h deleted file mode 100644 index 304554250..000000000 --- a/desmume/src/windows/agg/include/agg_renderer_raster_text.h +++ /dev/null @@ -1,273 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_RENDERER_RASTER_TEXT_INCLUDED -#define AGG_RENDERER_RASTER_TEXT_INCLUDED - -#include "agg_basics.h" - -namespace agg -{ - - //==============================================renderer_raster_htext_solid - template - class renderer_raster_htext_solid - { - public: - typedef BaseRenderer ren_type; - typedef GlyphGenerator glyph_gen_type; - typedef typename glyph_gen_type::glyph_rect glyph_rect; - typedef typename ren_type::color_type color_type; - - renderer_raster_htext_solid(ren_type& ren, glyph_gen_type& glyph) : - m_ren(&ren), - m_glyph(&glyph) - {} - void attach(ren_type& ren) { m_ren = &ren; } - - //-------------------------------------------------------------------- - void color(const color_type& c) { m_color = c; } - const color_type& color() const { return m_color; } - - //-------------------------------------------------------------------- - template - void render_text(double x, double y, const CharT* str, bool flip=false) - { - glyph_rect r; - while(*str) - { - m_glyph->prepare(&r, x, y, *str, flip); - if(r.x2 >= r.x1) - { - int i; - if(flip) - { - for(i = r.y1; i <= r.y2; i++) - { - m_ren->blend_solid_hspan(r.x1, i, (r.x2 - r.x1 + 1), - m_color, - m_glyph->span(r.y2 - i)); - } - } - else - { - for(i = r.y1; i <= r.y2; i++) - { - m_ren->blend_solid_hspan(r.x1, i, (r.x2 - r.x1 + 1), - m_color, - m_glyph->span(i - r.y1)); - } - } - } - x += r.dx; - y += r.dy; - ++str; - } - } - - private: - ren_type* m_ren; - glyph_gen_type* m_glyph; - color_type m_color; - }; - - - - //=============================================renderer_raster_vtext_solid - template - class renderer_raster_vtext_solid - { - public: - typedef BaseRenderer ren_type; - typedef GlyphGenerator glyph_gen_type; - typedef typename glyph_gen_type::glyph_rect glyph_rect; - typedef typename ren_type::color_type color_type; - - renderer_raster_vtext_solid(ren_type& ren, glyph_gen_type& glyph) : - m_ren(&ren), - m_glyph(&glyph) - { - } - - //-------------------------------------------------------------------- - void color(const color_type& c) { m_color = c; } - const color_type& color() const { return m_color; } - - //-------------------------------------------------------------------- - template - void render_text(double x, double y, const CharT* str, bool flip=false) - { - glyph_rect r; - while(*str) - { - m_glyph->prepare(&r, x, y, *str, !flip); - if(r.x2 >= r.x1) - { - int i; - if(flip) - { - for(i = r.y1; i <= r.y2; i++) - { - m_ren->blend_solid_vspan(i, r.x1, (r.x2 - r.x1 + 1), - m_color, - m_glyph->span(i - r.y1)); - } - } - else - { - for(i = r.y1; i <= r.y2; i++) - { - m_ren->blend_solid_vspan(i, r.x1, (r.x2 - r.x1 + 1), - m_color, - m_glyph->span(r.y2 - i)); - } - } - } - x += r.dx; - y += r.dy; - ++str; - } - } - - private: - ren_type* m_ren; - glyph_gen_type* m_glyph; - color_type m_color; - }; - - - - - - - //===================================================renderer_raster_htext - template - class renderer_raster_htext - { - public: - typedef ScanlineRenderer ren_type; - typedef GlyphGenerator glyph_gen_type; - typedef typename glyph_gen_type::glyph_rect glyph_rect; - - class scanline_single_span - { - public: - typedef agg::cover_type cover_type; - - //---------------------------------------------------------------- - struct const_span - { - int x; - unsigned len; - const cover_type* covers; - - const_span() {} - const_span(int x_, unsigned len_, const cover_type* covers_) : - x(x_), len(len_), covers(covers_) - {} - }; - - typedef const const_span* const_iterator; - - //---------------------------------------------------------------- - scanline_single_span(int x, int y, unsigned len, - const cover_type* covers) : - m_y(y), - m_span(x, len, covers) - {} - - //---------------------------------------------------------------- - int y() const { return m_y; } - unsigned num_spans() const { return 1; } - const_iterator begin() const { return &m_span; } - - private: - //---------------------------------------------------------------- - int m_y; - const_span m_span; - }; - - - - //-------------------------------------------------------------------- - renderer_raster_htext(ren_type& ren, glyph_gen_type& glyph) : - m_ren(&ren), - m_glyph(&glyph) - { - } - - - //-------------------------------------------------------------------- - template - void render_text(double x, double y, const CharT* str, bool flip=false) - { - glyph_rect r; - while(*str) - { - m_glyph->prepare(&r, x, y, *str, flip); - if(r.x2 >= r.x1) - { - m_ren->prepare(); - int i; - if(flip) - { - for(i = r.y1; i <= r.y2; i++) - { - m_ren->render( - scanline_single_span(r.x1, - i, - (r.x2 - r.x1 + 1), - m_glyph->span(r.y2 - i))); - } - } - else - { - for(i = r.y1; i <= r.y2; i++) - { - m_ren->render( - scanline_single_span(r.x1, - i, - (r.x2 - r.x1 + 1), - m_glyph->span(i - r.y1))); - } - } - } - x += r.dx; - y += r.dy; - ++str; - } - } - - private: - ren_type* m_ren; - glyph_gen_type* m_glyph; - }; - - - - -} - -#endif - diff --git a/desmume/src/windows/agg/include/agg_renderer_scanline.h b/desmume/src/windows/agg/include/agg_renderer_scanline.h deleted file mode 100644 index c0b6df6f8..000000000 --- a/desmume/src/windows/agg/include/agg_renderer_scanline.h +++ /dev/null @@ -1,861 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_RENDERER_SCANLINE_INCLUDED -#define AGG_RENDERER_SCANLINE_INCLUDED - -#include "agg_basics.h" -#include "agg_renderer_base.h" - -namespace agg -{ - - //================================================render_scanline_aa_solid - template - void render_scanline_aa_solid(const Scanline& sl, - BaseRenderer& ren, - const ColorT& color) - { - int y = sl.y(); - unsigned num_spans = sl.num_spans(); - typename Scanline::const_iterator span = sl.begin(); - - for(;;) - { - int x = span->x; - if(span->len > 0) - { - ren.blend_solid_hspan(x, y, (unsigned)span->len, - color, - span->covers); - } - else - { - ren.blend_hline(x, y, (unsigned)(x - span->len - 1), - color, - *(span->covers)); - } - if(--num_spans == 0) break; - ++span; - } - } - - //===============================================render_scanlines_aa_solid - template - void render_scanlines_aa_solid(Rasterizer& ras, Scanline& sl, - BaseRenderer& ren, const ColorT& color) - { - if(ras.rewind_scanlines()) - { - // Explicitly convert "color" to the BaseRenderer color type. - // For example, it can be called with color type "rgba", while - // "rgba8" is needed. Otherwise it will be implicitly - // converted in the loop many times. - //---------------------- - typename BaseRenderer::color_type ren_color(color); - - sl.reset(ras.min_x(), ras.max_x()); - while(ras.sweep_scanline(sl)) - { - //render_scanline_aa_solid(sl, ren, ren_color); - - // This code is equivalent to the above call (copy/paste). - // It's just a "manual" optimization for old compilers, - // like Microsoft Visual C++ v6.0 - //------------------------------- - int y = sl.y(); - unsigned num_spans = sl.num_spans(); - typename Scanline::const_iterator span = sl.begin(); - - for(;;) - { - int x = span->x; - if(span->len > 0) - { - ren.blend_solid_hspan(x, y, (unsigned)span->len, - ren_color, - span->covers); - } - else - { - ren.blend_hline(x, y, (unsigned)(x - span->len - 1), - ren_color, - *(span->covers)); - } - if(--num_spans == 0) break; - ++span; - } - } - } - } - - //==============================================renderer_scanline_aa_solid - template class renderer_scanline_aa_solid - { - public: - typedef BaseRenderer base_ren_type; - typedef typename base_ren_type::color_type color_type; - - //-------------------------------------------------------------------- - renderer_scanline_aa_solid() : m_ren(0) {} - explicit renderer_scanline_aa_solid(base_ren_type& ren) : m_ren(&ren) {} - void attach(base_ren_type& ren) - { - m_ren = &ren; - } - - //-------------------------------------------------------------------- - void color(const color_type& c) { m_color = c; } - const color_type& color() const { return m_color; } - - //-------------------------------------------------------------------- - void prepare() {} - - //-------------------------------------------------------------------- - template void render(const Scanline& sl) - { - render_scanline_aa_solid(sl, *m_ren, m_color); - } - - private: - base_ren_type* m_ren; - color_type m_color; - }; - - - - - - - - - - - - - - //======================================================render_scanline_aa - template - void render_scanline_aa(const Scanline& sl, BaseRenderer& ren, - SpanAllocator& alloc, SpanGenerator& span_gen) - { - int y = sl.y(); - - unsigned num_spans = sl.num_spans(); - typename Scanline::const_iterator span = sl.begin(); - for(;;) - { - int x = span->x; - int len = span->len; - const typename Scanline::cover_type* covers = span->covers; - - if(len < 0) len = -len; - typename BaseRenderer::color_type* colors = alloc.allocate(len); - span_gen.generate(colors, x, y, len); - ren.blend_color_hspan(x, y, len, colors, - (span->len < 0) ? 0 : covers, *covers); - - if(--num_spans == 0) break; - ++span; - } - } - - //=====================================================render_scanlines_aa - template - void render_scanlines_aa(Rasterizer& ras, Scanline& sl, BaseRenderer& ren, - SpanAllocator& alloc, SpanGenerator& span_gen) - { - if(ras.rewind_scanlines()) - { - sl.reset(ras.min_x(), ras.max_x()); - span_gen.prepare(); - while(ras.sweep_scanline(sl)) - { - render_scanline_aa(sl, ren, alloc, span_gen); - } - } - } - - //====================================================renderer_scanline_aa - template - class renderer_scanline_aa - { - public: - typedef BaseRenderer base_ren_type; - typedef SpanAllocator alloc_type; - typedef SpanGenerator span_gen_type; - - //-------------------------------------------------------------------- - renderer_scanline_aa() : m_ren(0), m_alloc(0), m_span_gen(0) {} - renderer_scanline_aa(base_ren_type& ren, - alloc_type& alloc, - span_gen_type& span_gen) : - m_ren(&ren), - m_alloc(&alloc), - m_span_gen(&span_gen) - {} - void attach(base_ren_type& ren, - alloc_type& alloc, - span_gen_type& span_gen) - { - m_ren = &ren; - m_alloc = &alloc; - m_span_gen = &span_gen; - } - - //-------------------------------------------------------------------- - void prepare() { m_span_gen->prepare(); } - - //-------------------------------------------------------------------- - template void render(const Scanline& sl) - { - render_scanline_aa(sl, *m_ren, *m_alloc, *m_span_gen); - } - - private: - base_ren_type* m_ren; - alloc_type* m_alloc; - span_gen_type* m_span_gen; - }; - - - - - - - //===============================================render_scanline_bin_solid - template - void render_scanline_bin_solid(const Scanline& sl, - BaseRenderer& ren, - const ColorT& color) - { - unsigned num_spans = sl.num_spans(); - typename Scanline::const_iterator span = sl.begin(); - for(;;) - { - ren.blend_hline(span->x, - sl.y(), - span->x - 1 + ((span->len < 0) ? - -span->len : - span->len), - color, - cover_full); - if(--num_spans == 0) break; - ++span; - } - } - - //==============================================render_scanlines_bin_solid - template - void render_scanlines_bin_solid(Rasterizer& ras, Scanline& sl, - BaseRenderer& ren, const ColorT& color) - { - if(ras.rewind_scanlines()) - { - // Explicitly convert "color" to the BaseRenderer color type. - // For example, it can be called with color type "rgba", while - // "rgba8" is needed. Otherwise it will be implicitly - // converted in the loop many times. - //---------------------- - typename BaseRenderer::color_type ren_color(color); - - sl.reset(ras.min_x(), ras.max_x()); - while(ras.sweep_scanline(sl)) - { - //render_scanline_bin_solid(sl, ren, ren_color); - - // This code is equivalent to the above call (copy/paste). - // It's just a "manual" optimization for old compilers, - // like Microsoft Visual C++ v6.0 - //------------------------------- - unsigned num_spans = sl.num_spans(); - typename Scanline::const_iterator span = sl.begin(); - for(;;) - { - ren.blend_hline(span->x, - sl.y(), - span->x - 1 + ((span->len < 0) ? - -span->len : - span->len), - ren_color, - cover_full); - if(--num_spans == 0) break; - ++span; - } - } - } - } - - //=============================================renderer_scanline_bin_solid - template class renderer_scanline_bin_solid - { - public: - typedef BaseRenderer base_ren_type; - typedef typename base_ren_type::color_type color_type; - - //-------------------------------------------------------------------- - renderer_scanline_bin_solid() : m_ren(0) {} - explicit renderer_scanline_bin_solid(base_ren_type& ren) : m_ren(&ren) {} - void attach(base_ren_type& ren) - { - m_ren = &ren; - } - - //-------------------------------------------------------------------- - void color(const color_type& c) { m_color = c; } - const color_type& color() const { return m_color; } - - //-------------------------------------------------------------------- - void prepare() {} - - //-------------------------------------------------------------------- - template void render(const Scanline& sl) - { - render_scanline_bin_solid(sl, *m_ren, m_color); - } - - private: - base_ren_type* m_ren; - color_type m_color; - }; - - - - - - - - - //======================================================render_scanline_bin - template - void render_scanline_bin(const Scanline& sl, BaseRenderer& ren, - SpanAllocator& alloc, SpanGenerator& span_gen) - { - int y = sl.y(); - - unsigned num_spans = sl.num_spans(); - typename Scanline::const_iterator span = sl.begin(); - for(;;) - { - int x = span->x; - int len = span->len; - if(len < 0) len = -len; - typename BaseRenderer::color_type* colors = alloc.allocate(len); - span_gen.generate(colors, x, y, len); - ren.blend_color_hspan(x, y, len, colors, 0, cover_full); - if(--num_spans == 0) break; - ++span; - } - } - - //=====================================================render_scanlines_bin - template - void render_scanlines_bin(Rasterizer& ras, Scanline& sl, BaseRenderer& ren, - SpanAllocator& alloc, SpanGenerator& span_gen) - { - if(ras.rewind_scanlines()) - { - sl.reset(ras.min_x(), ras.max_x()); - span_gen.prepare(); - while(ras.sweep_scanline(sl)) - { - render_scanline_bin(sl, ren, alloc, span_gen); - } - } - } - - //====================================================renderer_scanline_bin - template - class renderer_scanline_bin - { - public: - typedef BaseRenderer base_ren_type; - typedef SpanAllocator alloc_type; - typedef SpanGenerator span_gen_type; - - //-------------------------------------------------------------------- - renderer_scanline_bin() : m_ren(0), m_alloc(0), m_span_gen(0) {} - renderer_scanline_bin(base_ren_type& ren, - alloc_type& alloc, - span_gen_type& span_gen) : - m_ren(&ren), - m_alloc(&alloc), - m_span_gen(&span_gen) - {} - void attach(base_ren_type& ren, - alloc_type& alloc, - span_gen_type& span_gen) - { - m_ren = &ren; - m_alloc = &alloc; - m_span_gen = &span_gen; - } - - //-------------------------------------------------------------------- - void prepare() { m_span_gen->prepare(); } - - //-------------------------------------------------------------------- - template void render(const Scanline& sl) - { - render_scanline_bin(sl, *m_ren, *m_alloc, *m_span_gen); - } - - private: - base_ren_type* m_ren; - alloc_type* m_alloc; - span_gen_type* m_span_gen; - }; - - - - - - - - - - - //========================================================render_scanlines - template - void render_scanlines(Rasterizer& ras, Scanline& sl, Renderer& ren) - { - if(ras.rewind_scanlines()) - { - sl.reset(ras.min_x(), ras.max_x()); - ren.prepare(); - while(ras.sweep_scanline(sl)) - { - ren.render(sl); - } - } - } - - //========================================================render_all_paths - template - void render_all_paths(Rasterizer& ras, - Scanline& sl, - Renderer& r, - VertexSource& vs, - const ColorStorage& as, - const PathId& path_id, - unsigned num_paths) - { - for(unsigned i = 0; i < num_paths; i++) - { - ras.reset(); - ras.add_path(vs, path_id[i]); - r.color(as[i]); - render_scanlines(ras, sl, r); - } - } - - - - - - - //=============================================render_scanlines_compound - template - void render_scanlines_compound(Rasterizer& ras, - ScanlineAA& sl_aa, - ScanlineBin& sl_bin, - BaseRenderer& ren, - SpanAllocator& alloc, - StyleHandler& sh) - { - if(ras.rewind_scanlines()) - { - int min_x = ras.min_x(); - int len = ras.max_x() - min_x + 2; - sl_aa.reset(min_x, ras.max_x()); - sl_bin.reset(min_x, ras.max_x()); - - typedef typename BaseRenderer::color_type color_type; - color_type* color_span = alloc.allocate(len * 2); - color_type* mix_buffer = color_span + len; - unsigned num_spans; - - unsigned num_styles; - unsigned style; - bool solid; - while((num_styles = ras.sweep_styles()) > 0) - { - typename ScanlineAA::const_iterator span_aa; - if(num_styles == 1) - { - // Optimization for a single style. Happens often - //------------------------- - if(ras.sweep_scanline(sl_aa, 0)) - { - style = ras.style(0); - if(sh.is_solid(style)) - { - // Just solid fill - //----------------------- - render_scanline_aa_solid(sl_aa, ren, sh.color(style)); - } - else - { - // Arbitrary span generator - //----------------------- - span_aa = sl_aa.begin(); - num_spans = sl_aa.num_spans(); - for(;;) - { - len = span_aa->len; - sh.generate_span(color_span, - span_aa->x, - sl_aa.y(), - len, - style); - - ren.blend_color_hspan(span_aa->x, - sl_aa.y(), - span_aa->len, - color_span, - span_aa->covers); - if(--num_spans == 0) break; - ++span_aa; - } - } - } - } - else - { - if(ras.sweep_scanline(sl_bin, -1)) - { - // Clear the spans of the mix_buffer - //-------------------- - typename ScanlineBin::const_iterator span_bin = sl_bin.begin(); - num_spans = sl_bin.num_spans(); - for(;;) - { - memset(mix_buffer + span_bin->x - min_x, - 0, - span_bin->len * sizeof(color_type)); - - if(--num_spans == 0) break; - ++span_bin; - } - - unsigned i; - for(i = 0; i < num_styles; i++) - { - style = ras.style(i); - solid = sh.is_solid(style); - - if(ras.sweep_scanline(sl_aa, i)) - { - color_type* colors; - color_type* cspan; - typename ScanlineAA::cover_type* covers; - span_aa = sl_aa.begin(); - num_spans = sl_aa.num_spans(); - if(solid) - { - // Just solid fill - //----------------------- - for(;;) - { - color_type c = sh.color(style); - len = span_aa->len; - colors = mix_buffer + span_aa->x - min_x; - covers = span_aa->covers; - do - { - if(*covers == cover_full) - { - *colors = c; - } - else - { - colors->add(c, *covers); - } - ++colors; - ++covers; - } - while(--len); - if(--num_spans == 0) break; - ++span_aa; - } - } - else - { - // Arbitrary span generator - //----------------------- - for(;;) - { - len = span_aa->len; - colors = mix_buffer + span_aa->x - min_x; - cspan = color_span; - sh.generate_span(cspan, - span_aa->x, - sl_aa.y(), - len, - style); - covers = span_aa->covers; - do - { - if(*covers == cover_full) - { - *colors = *cspan; - } - else - { - colors->add(*cspan, *covers); - } - ++cspan; - ++colors; - ++covers; - } - while(--len); - if(--num_spans == 0) break; - ++span_aa; - } - } - } - } - - // Emit the blended result as a color hspan - //------------------------- - span_bin = sl_bin.begin(); - num_spans = sl_bin.num_spans(); - for(;;) - { - ren.blend_color_hspan(span_bin->x, - sl_bin.y(), - span_bin->len, - mix_buffer + span_bin->x - min_x, - 0, - cover_full); - if(--num_spans == 0) break; - ++span_bin; - } - } // if(ras.sweep_scanline(sl_bin, -1)) - } // if(num_styles == 1) ... else - } // while((num_styles = ras.sweep_styles()) > 0) - } // if(ras.rewind_scanlines()) - } - - //=======================================render_scanlines_compound_layered - template - void render_scanlines_compound_layered(Rasterizer& ras, - ScanlineAA& sl_aa, - BaseRenderer& ren, - SpanAllocator& alloc, - StyleHandler& sh) - { - if(ras.rewind_scanlines()) - { - int min_x = ras.min_x(); - int len = ras.max_x() - min_x + 2; - sl_aa.reset(min_x, ras.max_x()); - - typedef typename BaseRenderer::color_type color_type; - color_type* color_span = alloc.allocate(len * 2); - color_type* mix_buffer = color_span + len; - cover_type* cover_buffer = ras.allocate_cover_buffer(len); - unsigned num_spans; - - unsigned num_styles; - unsigned style; - bool solid; - while((num_styles = ras.sweep_styles()) > 0) - { - typename ScanlineAA::const_iterator span_aa; - if(num_styles == 1) - { - // Optimization for a single style. Happens often - //------------------------- - if(ras.sweep_scanline(sl_aa, 0)) - { - style = ras.style(0); - if(sh.is_solid(style)) - { - // Just solid fill - //----------------------- - render_scanline_aa_solid(sl_aa, ren, sh.color(style)); - } - else - { - // Arbitrary span generator - //----------------------- - span_aa = sl_aa.begin(); - num_spans = sl_aa.num_spans(); - for(;;) - { - len = span_aa->len; - sh.generate_span(color_span, - span_aa->x, - sl_aa.y(), - len, - style); - - ren.blend_color_hspan(span_aa->x, - sl_aa.y(), - span_aa->len, - color_span, - span_aa->covers); - if(--num_spans == 0) break; - ++span_aa; - } - } - } - } - else - { - int sl_start = ras.scanline_start(); - unsigned sl_len = ras.scanline_length(); - - if(sl_len) - { - memset(mix_buffer + sl_start - min_x, - 0, - sl_len * sizeof(color_type)); - - memset(cover_buffer + sl_start - min_x, - 0, - sl_len * sizeof(cover_type)); - - int sl_y = 0x7FFFFFFF; - unsigned i; - for(i = 0; i < num_styles; i++) - { - style = ras.style(i); - solid = sh.is_solid(style); - - if(ras.sweep_scanline(sl_aa, i)) - { - unsigned cover; - color_type* colors; - color_type* cspan; - cover_type* src_covers; - cover_type* dst_covers; - span_aa = sl_aa.begin(); - num_spans = sl_aa.num_spans(); - sl_y = sl_aa.y(); - if(solid) - { - // Just solid fill - //----------------------- - for(;;) - { - color_type c = sh.color(style); - len = span_aa->len; - colors = mix_buffer + span_aa->x - min_x; - src_covers = span_aa->covers; - dst_covers = cover_buffer + span_aa->x - min_x; - do - { - cover = *src_covers; - if(*dst_covers + cover > cover_full) - { - cover = cover_full - *dst_covers; - } - if(cover) - { - colors->add(c, cover); - *dst_covers += cover; - } - ++colors; - ++src_covers; - ++dst_covers; - } - while(--len); - if(--num_spans == 0) break; - ++span_aa; - } - } - else - { - // Arbitrary span generator - //----------------------- - for(;;) - { - len = span_aa->len; - colors = mix_buffer + span_aa->x - min_x; - cspan = color_span; - sh.generate_span(cspan, - span_aa->x, - sl_aa.y(), - len, - style); - src_covers = span_aa->covers; - dst_covers = cover_buffer + span_aa->x - min_x; - do - { - cover = *src_covers; - if(*dst_covers + cover > cover_full) - { - cover = cover_full - *dst_covers; - } - if(cover) - { - colors->add(*cspan, cover); - *dst_covers += cover; - } - ++cspan; - ++colors; - ++src_covers; - ++dst_covers; - } - while(--len); - if(--num_spans == 0) break; - ++span_aa; - } - } - } - } - ren.blend_color_hspan(sl_start, - sl_y, - sl_len, - mix_buffer + sl_start - min_x, - 0, - cover_full); - } //if(sl_len) - } //if(num_styles == 1) ... else - } //while((num_styles = ras.sweep_styles()) > 0) - } //if(ras.rewind_scanlines()) - } - - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_rendering_buffer.h b/desmume/src/windows/agg/include/agg_rendering_buffer.h deleted file mode 100644 index 5a06c8a00..000000000 --- a/desmume/src/windows/agg/include/agg_rendering_buffer.h +++ /dev/null @@ -1,305 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_RENDERING_BUFFER_INCLUDED -#define AGG_RENDERING_BUFFER_INCLUDED - -#include "agg_array.h" - -namespace agg -{ - - //===========================================================row_accessor - template class row_accessor - { - public: - typedef const_row_info row_data; - - //------------------------------------------------------------------- - row_accessor() : - m_buf(0), - m_start(0), - m_width(0), - m_height(0), - m_stride(0) - { - } - - //-------------------------------------------------------------------- - row_accessor(T* buf, unsigned width, unsigned height, int stride) : - m_buf(0), - m_start(0), - m_width(0), - m_height(0), - m_stride(0) - { - attach(buf, width, height, stride); - } - - - //-------------------------------------------------------------------- - void attach(T* buf, unsigned width, unsigned height, int stride) - { - m_buf = m_start = buf; - m_width = width; - m_height = height; - m_stride = stride; - if(stride < 0) - { - m_start = m_buf - int(height - 1) * stride; - } - } - - //-------------------------------------------------------------------- - AGG_INLINE T* buf() { return m_buf; } - AGG_INLINE const T* buf() const { return m_buf; } - AGG_INLINE unsigned width() const { return m_width; } - AGG_INLINE unsigned height() const { return m_height; } - AGG_INLINE int stride() const { return m_stride; } - AGG_INLINE unsigned stride_abs() const - { - return (m_stride < 0) ? unsigned(-m_stride) : unsigned(m_stride); - } - - //-------------------------------------------------------------------- - AGG_INLINE T* row_ptr(int, int y, unsigned) - { - return m_start + y * m_stride; - } - AGG_INLINE T* row_ptr(int y) { return m_start + y * m_stride; } - AGG_INLINE const T* row_ptr(int y) const { return m_start + y * m_stride; } - AGG_INLINE row_data row (int y) const - { - return row_data(0, m_width-1, row_ptr(y)); - } - - //-------------------------------------------------------------------- - template - void copy_from(const RenBuf& src) - { - unsigned h = height(); - if(src.height() < h) h = src.height(); - - unsigned l = stride_abs(); - if(src.stride_abs() < l) l = src.stride_abs(); - - l *= sizeof(T); - - unsigned y; - unsigned w = width(); - for (y = 0; y < h; y++) - { - memcpy(row_ptr(0, y, w), src.row_ptr(y), l); - } - } - - //-------------------------------------------------------------------- - void clear(T value) - { - unsigned y; - unsigned w = width(); - unsigned stride = stride_abs(); - for(y = 0; y < height(); y++) - { - T* p = row_ptr(0, y, w); - unsigned x; - for(x = 0; x < stride; x++) - { - *p++ = value; - } - } - } - - private: - //-------------------------------------------------------------------- - T* m_buf; // Pointer to renrdering buffer - T* m_start; // Pointer to first pixel depending on stride - unsigned m_width; // Width in pixels - unsigned m_height; // Height in pixels - int m_stride; // Number of bytes per row. Can be < 0 - }; - - - - - //==========================================================row_ptr_cache - template class row_ptr_cache - { - public: - typedef const_row_info row_data; - - //------------------------------------------------------------------- - row_ptr_cache() : - m_buf(0), - m_rows(), - m_width(0), - m_height(0), - m_stride(0) - { - } - - //-------------------------------------------------------------------- - row_ptr_cache(T* buf, unsigned width, unsigned height, int stride) : - m_buf(0), - m_rows(), - m_width(0), - m_height(0), - m_stride(0) - { - attach(buf, width, height, stride); - } - - //-------------------------------------------------------------------- - void attach(T* buf, unsigned width, unsigned height, int stride) - { - m_buf = buf; - m_width = width; - m_height = height; - m_stride = stride; - if(height > m_rows.size()) - { - m_rows.resize(height); - } - - T* row_ptr = m_buf; - - if(stride < 0) - { - row_ptr = m_buf - int(height - 1) * stride; - } - - T** rows = &m_rows[0]; - - while(height--) - { - *rows++ = row_ptr; - row_ptr += stride; - } - } - - //-------------------------------------------------------------------- - AGG_INLINE T* buf() { return m_buf; } - AGG_INLINE const T* buf() const { return m_buf; } - AGG_INLINE unsigned width() const { return m_width; } - AGG_INLINE unsigned height() const { return m_height; } - AGG_INLINE int stride() const { return m_stride; } - AGG_INLINE unsigned stride_abs() const - { - return (m_stride < 0) ? unsigned(-m_stride) : unsigned(m_stride); - } - - //-------------------------------------------------------------------- - AGG_INLINE T* row_ptr(int, int y, unsigned) - { - return m_rows[y]; - } - AGG_INLINE T* row_ptr(int y) { return m_rows[y]; } - AGG_INLINE const T* row_ptr(int y) const { return m_rows[y]; } - AGG_INLINE row_data row (int y) const - { - return row_data(0, m_width-1, m_rows[y]); - } - - //-------------------------------------------------------------------- - T const* const* rows() const { return &m_rows[0]; } - - //-------------------------------------------------------------------- - template - void copy_from(const RenBuf& src) - { - unsigned h = height(); - if(src.height() < h) h = src.height(); - - unsigned l = stride_abs(); - if(src.stride_abs() < l) l = src.stride_abs(); - - l *= sizeof(T); - - unsigned y; - unsigned w = width(); - for (y = 0; y < h; y++) - { - memcpy(row_ptr(0, y, w), src.row_ptr(y), l); - } - } - - //-------------------------------------------------------------------- - void clear(T value) - { - unsigned y; - unsigned w = width(); - unsigned stride = stride_abs(); - for(y = 0; y < height(); y++) - { - T* p = row_ptr(0, y, w); - unsigned x; - for(x = 0; x < stride; x++) - { - *p++ = value; - } - } - } - - private: - //-------------------------------------------------------------------- - T* m_buf; // Pointer to renrdering buffer - pod_array m_rows; // Pointers to each row of the buffer - unsigned m_width; // Width in pixels - unsigned m_height; // Height in pixels - int m_stride; // Number of bytes per row. Can be < 0 - }; - - - - - //========================================================rendering_buffer - // - // The definition of the main type for accessing the rows in the frame - // buffer. It provides functionality to navigate to the rows in a - // rectangular matrix, from top to bottom or from bottom to top depending - // on stride. - // - // row_accessor is cheap to create/destroy, but performs one multiplication - // when calling row_ptr(). - // - // row_ptr_cache creates an array of pointers to rows, so, the access - // via row_ptr() may be faster. But it requires memory allocation - // when creating. For example, on typical Intel Pentium hardware - // row_ptr_cache speeds span_image_filter_rgb_nn up to 10% - // - // It's used only in short hand typedefs like pixfmt_rgba32 and can be - // redefined in agg_config.h - // In real applications you can use both, depending on your needs - //------------------------------------------------------------------------ -#ifdef AGG_RENDERING_BUFFER - typedef AGG_RENDERING_BUFFER rendering_buffer; -#else -// typedef row_ptr_cache rendering_buffer; - typedef row_accessor rendering_buffer; -#endif - -} - - -#endif diff --git a/desmume/src/windows/agg/include/agg_rendering_buffer_dynarow.h b/desmume/src/windows/agg/include/agg_rendering_buffer_dynarow.h deleted file mode 100644 index bc0ad4d21..000000000 --- a/desmume/src/windows/agg/include/agg_rendering_buffer_dynarow.h +++ /dev/null @@ -1,142 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_RENDERING_BUFFER_DYNAROW_INCLUDED -#define AGG_RENDERING_BUFFER_DYNAROW_INCLUDED - -#include "agg_array.h" - -namespace agg -{ - - //===============================================rendering_buffer_dynarow - // Rendering buffer class with dynamic allocation of the rows. - // The rows are allocated as needed when requesting for span_ptr(). - // The class automatically calculates min_x and max_x for each row. - // Generally it's more efficient to use this class as a temporary buffer - // for rendering a few lines and then to blend it with another buffer. - // - class rendering_buffer_dynarow - { - public: - typedef row_info row_data; - - //------------------------------------------------------------------- - ~rendering_buffer_dynarow() - { - init(0,0,0); - } - - //------------------------------------------------------------------- - rendering_buffer_dynarow() : - m_rows(), - m_width(0), - m_height(0), - m_byte_width(0) - { - } - - // Allocate and clear the buffer - //-------------------------------------------------------------------- - rendering_buffer_dynarow(unsigned width, unsigned height, - unsigned byte_width) : - m_rows(height), - m_width(width), - m_height(height), - m_byte_width(byte_width) - { - memset(&m_rows[0], 0, sizeof(row_data) * height); - } - - // Allocate and clear the buffer - //-------------------------------------------------------------------- - void init(unsigned width, unsigned height, unsigned byte_width) - { - unsigned i; - for(i = 0; i < m_height; ++i) - { - pod_allocator::deallocate((int8u*)m_rows[i].ptr, m_byte_width); - } - if(width && height) - { - m_width = width; - m_height = height; - m_byte_width = byte_width; - m_rows.resize(height); - memset(&m_rows[0], 0, sizeof(row_data) * height); - } - } - - //-------------------------------------------------------------------- - unsigned width() const { return m_width; } - unsigned height() const { return m_height; } - unsigned byte_width() const { return m_byte_width; } - - // The main function used for rendering. Returns pointer to the - // pre-allocated span. Memory for the row is allocated as needed. - //-------------------------------------------------------------------- - int8u* row_ptr(int x, int y, unsigned len) - { - row_data* r = &m_rows[y]; - int x2 = x + len - 1; - if(r->ptr) - { - if(x < r->x1) { r->x1 = x; } - if(x2 > r->x2) { r->x2 = x2; } - } - else - { - int8u* p = pod_allocator::allocate(m_byte_width); - r->ptr = p; - r->x1 = x; - r->x2 = x2; - memset(p, 0, m_byte_width); - } - return (int8u*)r->ptr; - } - - //-------------------------------------------------------------------- - const int8u* row_ptr(int y) const { return m_rows[y].ptr; } - int8u* row_ptr(int y) { return row_ptr(0, y, m_width); } - row_data row (int y) const { return m_rows[y]; } - - private: - //-------------------------------------------------------------------- - // Prohibit copying - rendering_buffer_dynarow(const rendering_buffer_dynarow&); - const rendering_buffer_dynarow& operator = (const rendering_buffer_dynarow&); - - private: - //-------------------------------------------------------------------- - pod_array m_rows; // Pointers to each row of the buffer - unsigned m_width; // Width in pixels - unsigned m_height; // Height in pixels - unsigned m_byte_width; // Width in bytes - }; - - -} - - -#endif diff --git a/desmume/src/windows/agg/include/agg_rounded_rect.h b/desmume/src/windows/agg/include/agg_rounded_rect.h deleted file mode 100644 index ecaa370ea..000000000 --- a/desmume/src/windows/agg/include/agg_rounded_rect.h +++ /dev/null @@ -1,77 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_ROUNDED_RECT_INCLUDED -#define AGG_ROUNDED_RECT_INCLUDED - -#include "agg_basics.h" -#include "agg_arc.h" - -namespace agg -{ - //------------------------------------------------------------rounded_rect - // - // See Implemantation agg_rounded_rect.cpp - // - class rounded_rect - { - public: - rounded_rect() {} - rounded_rect(double x1, double y1, double x2, double y2, double r); - - void rect(double x1, double y1, double x2, double y2); - void radius(double r); - void radius(double rx, double ry); - void radius(double rx_bottom, double ry_bottom, double rx_top, double ry_top); - void radius(double rx1, double ry1, double rx2, double ry2, - double rx3, double ry3, double rx4, double ry4); - void normalize_radius(); - - void approximation_scale(double s) { m_arc.approximation_scale(s); } - double approximation_scale() const { return m_arc.approximation_scale(); } - - void rewind(unsigned); - unsigned vertex(double* x, double* y); - - private: - double m_x1; - double m_y1; - double m_x2; - double m_y2; - double m_rx1; - double m_ry1; - double m_rx2; - double m_ry2; - double m_rx3; - double m_ry3; - double m_rx4; - double m_ry4; - unsigned m_status; - arc m_arc; - }; - -} - -#endif - diff --git a/desmume/src/windows/agg/include/agg_scanline_bin.h b/desmume/src/windows/agg/include/agg_scanline_bin.h deleted file mode 100644 index dd4cdf694..000000000 --- a/desmume/src/windows/agg/include/agg_scanline_bin.h +++ /dev/null @@ -1,269 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- -// -// Adaptation for 32-bit screen coordinates (scanline32_bin) has been sponsored by -// Liberty Technology Systems, Inc., visit http://lib-sys.com -// -// Liberty Technology Systems, Inc. is the provider of -// PostScript and PDF technology for software developers. -// -//---------------------------------------------------------------------------- - -#ifndef AGG_SCANLINE_BIN_INCLUDED -#define AGG_SCANLINE_BIN_INCLUDED - -#include "agg_array.h" - -namespace agg -{ - - //=============================================================scanline_bin - // - // This is binary scaline container which supports the interface - // used in the rasterizer::render(). See description of agg_scanline_u8 - // for details. - // - //------------------------------------------------------------------------ - class scanline_bin - { - public: - typedef int32 coord_type; - - struct span - { - int16 x; - int16 len; - }; - - typedef const span* const_iterator; - - //-------------------------------------------------------------------- - scanline_bin() : - m_last_x(0x7FFFFFF0), - m_spans(), - m_cur_span(0) - { - } - - //-------------------------------------------------------------------- - void reset(int min_x, int max_x) - { - unsigned max_len = max_x - min_x + 3; - if(max_len > m_spans.size()) - { - m_spans.resize(max_len); - } - m_last_x = 0x7FFFFFF0; - m_cur_span = &m_spans[0]; - } - - //-------------------------------------------------------------------- - void add_cell(int x, unsigned) - { - if(x == m_last_x+1) - { - m_cur_span->len++; - } - else - { - ++m_cur_span; - m_cur_span->x = (int16)x; - m_cur_span->len = 1; - } - m_last_x = x; - } - - //-------------------------------------------------------------------- - void add_span(int x, unsigned len, unsigned) - { - if(x == m_last_x+1) - { - m_cur_span->len = (int16)(m_cur_span->len + len); - } - else - { - ++m_cur_span; - m_cur_span->x = (int16)x; - m_cur_span->len = (int16)len; - } - m_last_x = x + len - 1; - } - - //-------------------------------------------------------------------- - void add_cells(int x, unsigned len, const void*) - { - add_span(x, len, 0); - } - - //-------------------------------------------------------------------- - void finalize(int y) - { - m_y = y; - } - - //-------------------------------------------------------------------- - void reset_spans() - { - m_last_x = 0x7FFFFFF0; - m_cur_span = &m_spans[0]; - } - - //-------------------------------------------------------------------- - int y() const { return m_y; } - unsigned num_spans() const { return unsigned(m_cur_span - &m_spans[0]); } - const_iterator begin() const { return &m_spans[1]; } - - private: - scanline_bin(const scanline_bin&); - const scanline_bin operator = (const scanline_bin&); - - int m_last_x; - int m_y; - pod_array m_spans; - span* m_cur_span; - }; - - - - - - - //===========================================================scanline32_bin - class scanline32_bin - { - public: - typedef int32 coord_type; - - //-------------------------------------------------------------------- - struct span - { - span() {} - span(coord_type x_, coord_type len_) : x(x_), len(len_) {} - - coord_type x; - coord_type len; - }; - typedef pod_bvector span_array_type; - - - //-------------------------------------------------------------------- - class const_iterator - { - public: - const_iterator(const span_array_type& spans) : - m_spans(spans), - m_span_idx(0) - {} - - const span& operator*() const { return m_spans[m_span_idx]; } - const span* operator->() const { return &m_spans[m_span_idx]; } - - void operator ++ () { ++m_span_idx; } - - private: - const span_array_type& m_spans; - unsigned m_span_idx; - }; - - - //-------------------------------------------------------------------- - scanline32_bin() : m_max_len(0), m_last_x(0x7FFFFFF0) {} - - //-------------------------------------------------------------------- - void reset(int min_x, int max_x) - { - m_last_x = 0x7FFFFFF0; - m_spans.remove_all(); - } - - //-------------------------------------------------------------------- - void add_cell(int x, unsigned) - { - if(x == m_last_x+1) - { - m_spans.last().len++; - } - else - { - m_spans.add(span(coord_type(x), 1)); - } - m_last_x = x; - } - - //-------------------------------------------------------------------- - void add_span(int x, unsigned len, unsigned) - { - if(x == m_last_x+1) - { - m_spans.last().len += coord_type(len); - } - else - { - m_spans.add(span(coord_type(x), coord_type(len))); - } - m_last_x = x + len - 1; - } - - //-------------------------------------------------------------------- - void add_cells(int x, unsigned len, const void*) - { - add_span(x, len, 0); - } - - //-------------------------------------------------------------------- - void finalize(int y) - { - m_y = y; - } - - //-------------------------------------------------------------------- - void reset_spans() - { - m_last_x = 0x7FFFFFF0; - m_spans.remove_all(); - } - - //-------------------------------------------------------------------- - int y() const { return m_y; } - unsigned num_spans() const { return m_spans.size(); } - const_iterator begin() const { return const_iterator(m_spans); } - - private: - scanline32_bin(const scanline32_bin&); - const scanline32_bin operator = (const scanline32_bin&); - - unsigned m_max_len; - int m_last_x; - int m_y; - span_array_type m_spans; - }; - - - - - -} - - -#endif diff --git a/desmume/src/windows/agg/include/agg_scanline_boolean_algebra.h b/desmume/src/windows/agg/include/agg_scanline_boolean_algebra.h deleted file mode 100644 index 7e0970bc5..000000000 --- a/desmume/src/windows/agg/include/agg_scanline_boolean_algebra.h +++ /dev/null @@ -1,1576 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_SCANLINE_BOOLEAN_ALGEBRA_INCLUDED -#define AGG_SCANLINE_BOOLEAN_ALGEBRA_INCLUDED - -#include -#include -#include "agg_basics.h" - - -namespace agg -{ - - //-----------------------------------------------sbool_combine_spans_bin - // Functor. - // Combine two binary encoded spans, i.e., when we don't have any - // anti-aliasing information, but only X and Length. The function - // is compatible with any type of scanlines. - //---------------- - template - struct sbool_combine_spans_bin - { - void operator () (const typename Scanline1::const_iterator&, - const typename Scanline2::const_iterator&, - int x, unsigned len, - Scanline& sl) const - { - sl.add_span(x, len, cover_full); - } - }; - - - - //---------------------------------------------sbool_combine_spans_empty - // Functor. - // Combine two spans as empty ones. The functor does nothing - // and is used to XOR binary spans. - //---------------- - template - struct sbool_combine_spans_empty - { - void operator () (const typename Scanline1::const_iterator&, - const typename Scanline2::const_iterator&, - int, unsigned, - Scanline&) const - {} - }; - - - - //--------------------------------------------------sbool_add_span_empty - // Functor. - // Add nothing. Used in conbine_shapes_sub - //---------------- - template - struct sbool_add_span_empty - { - void operator () (const typename Scanline1::const_iterator&, - int, unsigned, - Scanline&) const - {} - }; - - - //----------------------------------------------------sbool_add_span_bin - // Functor. - // Add a binary span - //---------------- - template - struct sbool_add_span_bin - { - void operator () (const typename Scanline1::const_iterator&, - int x, unsigned len, - Scanline& sl) const - { - sl.add_span(x, len, cover_full); - } - }; - - - - - //-----------------------------------------------------sbool_add_span_aa - // Functor. - // Add an anti-aliased span - // anti-aliasing information, but only X and Length. The function - // is compatible with any type of scanlines. - //---------------- - template - struct sbool_add_span_aa - { - void operator () (const typename Scanline1::const_iterator& span, - int x, unsigned len, - Scanline& sl) const - { - if(span->len < 0) - { - sl.add_span(x, len, *span->covers); - } - else - if(span->len > 0) - { - const typename Scanline1::cover_type* covers = span->covers; - if(span->x < x) covers += x - span->x; - sl.add_cells(x, len, covers); - } - } - }; - - - - - //----------------------------------------------sbool_intersect_spans_aa - // Functor. - // Intersect two spans preserving the anti-aliasing information. - // The result is added to the "sl" scanline. - //------------------ - template - struct sbool_intersect_spans_aa - { - enum cover_scale_e - { - cover_shift = CoverShift, - cover_size = 1 << cover_shift, - cover_mask = cover_size - 1, - cover_full = cover_mask - }; - - - void operator () (const typename Scanline1::const_iterator& span1, - const typename Scanline2::const_iterator& span2, - int x, unsigned len, - Scanline& sl) const - { - unsigned cover; - const typename Scanline1::cover_type* covers1; - const typename Scanline2::cover_type* covers2; - - // Calculate the operation code and choose the - // proper combination algorithm. - // 0 = Both spans are of AA type - // 1 = span1 is solid, span2 is AA - // 2 = span1 is AA, span2 is solid - // 3 = Both spans are of solid type - //----------------- - switch((span1->len < 0) | ((span2->len < 0) << 1)) - { - case 0: // Both are AA spans - covers1 = span1->covers; - covers2 = span2->covers; - if(span1->x < x) covers1 += x - span1->x; - if(span2->x < x) covers2 += x - span2->x; - do - { - cover = *covers1++ * *covers2++; - sl.add_cell(x++, - (cover == cover_full * cover_full) ? - cover_full : - (cover >> cover_shift)); - } - while(--len); - break; - - case 1: // span1 is solid, span2 is AA - covers2 = span2->covers; - if(span2->x < x) covers2 += x - span2->x; - if(*(span1->covers) == cover_full) - { - sl.add_cells(x, len, covers2); - } - else - { - do - { - cover = *(span1->covers) * *covers2++; - sl.add_cell(x++, - (cover == cover_full * cover_full) ? - cover_full : - (cover >> cover_shift)); - } - while(--len); - } - break; - - case 2: // span1 is AA, span2 is solid - covers1 = span1->covers; - if(span1->x < x) covers1 += x - span1->x; - if(*(span2->covers) == cover_full) - { - sl.add_cells(x, len, covers1); - } - else - { - do - { - cover = *covers1++ * *(span2->covers); - sl.add_cell(x++, - (cover == cover_full * cover_full) ? - cover_full : - (cover >> cover_shift)); - } - while(--len); - } - break; - - case 3: // Both are solid spans - cover = *(span1->covers) * *(span2->covers); - sl.add_span(x, len, - (cover == cover_full * cover_full) ? - cover_full : - (cover >> cover_shift)); - break; - } - } - }; - - - - - - - //--------------------------------------------------sbool_unite_spans_aa - // Functor. - // Unite two spans preserving the anti-aliasing information. - // The result is added to the "sl" scanline. - //------------------ - template - struct sbool_unite_spans_aa - { - enum cover_scale_e - { - cover_shift = CoverShift, - cover_size = 1 << cover_shift, - cover_mask = cover_size - 1, - cover_full = cover_mask - }; - - - void operator () (const typename Scanline1::const_iterator& span1, - const typename Scanline2::const_iterator& span2, - int x, unsigned len, - Scanline& sl) const - { - unsigned cover; - const typename Scanline1::cover_type* covers1; - const typename Scanline2::cover_type* covers2; - - // Calculate the operation code and choose the - // proper combination algorithm. - // 0 = Both spans are of AA type - // 1 = span1 is solid, span2 is AA - // 2 = span1 is AA, span2 is solid - // 3 = Both spans are of solid type - //----------------- - switch((span1->len < 0) | ((span2->len < 0) << 1)) - { - case 0: // Both are AA spans - covers1 = span1->covers; - covers2 = span2->covers; - if(span1->x < x) covers1 += x - span1->x; - if(span2->x < x) covers2 += x - span2->x; - do - { - cover = cover_mask * cover_mask - - (cover_mask - *covers1++) * - (cover_mask - *covers2++); - sl.add_cell(x++, - (cover == cover_full * cover_full) ? - cover_full : - (cover >> cover_shift)); - } - while(--len); - break; - - case 1: // span1 is solid, span2 is AA - covers2 = span2->covers; - if(span2->x < x) covers2 += x - span2->x; - if(*(span1->covers) == cover_full) - { - sl.add_span(x, len, cover_full); - } - else - { - do - { - cover = cover_mask * cover_mask - - (cover_mask - *(span1->covers)) * - (cover_mask - *covers2++); - sl.add_cell(x++, - (cover == cover_full * cover_full) ? - cover_full : - (cover >> cover_shift)); - } - while(--len); - } - break; - - case 2: // span1 is AA, span2 is solid - covers1 = span1->covers; - if(span1->x < x) covers1 += x - span1->x; - if(*(span2->covers) == cover_full) - { - sl.add_span(x, len, cover_full); - } - else - { - do - { - cover = cover_mask * cover_mask - - (cover_mask - *covers1++) * - (cover_mask - *(span2->covers)); - sl.add_cell(x++, - (cover == cover_full * cover_full) ? - cover_full : - (cover >> cover_shift)); - } - while(--len); - } - break; - - case 3: // Both are solid spans - cover = cover_mask * cover_mask - - (cover_mask - *(span1->covers)) * - (cover_mask - *(span2->covers)); - sl.add_span(x, len, - (cover == cover_full * cover_full) ? - cover_full : - (cover >> cover_shift)); - break; - } - } - }; - - - //---------------------------------------------sbool_xor_formula_linear - template - struct sbool_xor_formula_linear - { - enum cover_scale_e - { - cover_shift = CoverShift, - cover_size = 1 << cover_shift, - cover_mask = cover_size - 1 - }; - - static AGG_INLINE unsigned calculate(unsigned a, unsigned b) - { - unsigned cover = a + b; - if(cover > cover_mask) cover = cover_mask + cover_mask - cover; - return cover; - } - }; - - - //---------------------------------------------sbool_xor_formula_saddle - template - struct sbool_xor_formula_saddle - { - enum cover_scale_e - { - cover_shift = CoverShift, - cover_size = 1 << cover_shift, - cover_mask = cover_size - 1 - }; - - static AGG_INLINE unsigned calculate(unsigned a, unsigned b) - { - unsigned k = a * b; - if(k == cover_mask * cover_mask) return 0; - - a = (cover_mask * cover_mask - (a << cover_shift) + k) >> cover_shift; - b = (cover_mask * cover_mask - (b << cover_shift) + k) >> cover_shift; - return cover_mask - ((a * b) >> cover_shift); - } - }; - - - //-------------------------------------------sbool_xor_formula_abs_diff - struct sbool_xor_formula_abs_diff - { - static AGG_INLINE unsigned calculate(unsigned a, unsigned b) - { - return unsigned(abs(int(a) - int(b))); - } - }; - - - - //----------------------------------------------------sbool_xor_spans_aa - // Functor. - // XOR two spans preserving the anti-aliasing information. - // The result is added to the "sl" scanline. - //------------------ - template - struct sbool_xor_spans_aa - { - enum cover_scale_e - { - cover_shift = CoverShift, - cover_size = 1 << cover_shift, - cover_mask = cover_size - 1, - cover_full = cover_mask - }; - - - void operator () (const typename Scanline1::const_iterator& span1, - const typename Scanline2::const_iterator& span2, - int x, unsigned len, - Scanline& sl) const - { - unsigned cover; - const typename Scanline1::cover_type* covers1; - const typename Scanline2::cover_type* covers2; - - // Calculate the operation code and choose the - // proper combination algorithm. - // 0 = Both spans are of AA type - // 1 = span1 is solid, span2 is AA - // 2 = span1 is AA, span2 is solid - // 3 = Both spans are of solid type - //----------------- - switch((span1->len < 0) | ((span2->len < 0) << 1)) - { - case 0: // Both are AA spans - covers1 = span1->covers; - covers2 = span2->covers; - if(span1->x < x) covers1 += x - span1->x; - if(span2->x < x) covers2 += x - span2->x; - do - { - cover = XorFormula::calculate(*covers1++, *covers2++); - if(cover) sl.add_cell(x, cover); - ++x; - } - while(--len); - break; - - case 1: // span1 is solid, span2 is AA - covers2 = span2->covers; - if(span2->x < x) covers2 += x - span2->x; - do - { - cover = XorFormula::calculate(*(span1->covers), *covers2++); - if(cover) sl.add_cell(x, cover); - ++x; - } - while(--len); - break; - - case 2: // span1 is AA, span2 is solid - covers1 = span1->covers; - if(span1->x < x) covers1 += x - span1->x; - do - { - cover = XorFormula::calculate(*covers1++, *(span2->covers)); - if(cover) sl.add_cell(x, cover); - ++x; - } - while(--len); - break; - - case 3: // Both are solid spans - cover = XorFormula::calculate(*(span1->covers), *(span2->covers)); - if(cover) sl.add_span(x, len, cover); - break; - - } - } - }; - - - - - - //-----------------------------------------------sbool_subtract_spans_aa - // Functor. - // Unite two spans preserving the anti-aliasing information. - // The result is added to the "sl" scanline. - //------------------ - template - struct sbool_subtract_spans_aa - { - enum cover_scale_e - { - cover_shift = CoverShift, - cover_size = 1 << cover_shift, - cover_mask = cover_size - 1, - cover_full = cover_mask - }; - - - void operator () (const typename Scanline1::const_iterator& span1, - const typename Scanline2::const_iterator& span2, - int x, unsigned len, - Scanline& sl) const - { - unsigned cover; - const typename Scanline1::cover_type* covers1; - const typename Scanline2::cover_type* covers2; - - // Calculate the operation code and choose the - // proper combination algorithm. - // 0 = Both spans are of AA type - // 1 = span1 is solid, span2 is AA - // 2 = span1 is AA, span2 is solid - // 3 = Both spans are of solid type - //----------------- - switch((span1->len < 0) | ((span2->len < 0) << 1)) - { - case 0: // Both are AA spans - covers1 = span1->covers; - covers2 = span2->covers; - if(span1->x < x) covers1 += x - span1->x; - if(span2->x < x) covers2 += x - span2->x; - do - { - cover = *covers1++ * (cover_mask - *covers2++); - if(cover) - { - sl.add_cell(x, - (cover == cover_full * cover_full) ? - cover_full : - (cover >> cover_shift)); - } - ++x; - } - while(--len); - break; - - case 1: // span1 is solid, span2 is AA - covers2 = span2->covers; - if(span2->x < x) covers2 += x - span2->x; - do - { - cover = *(span1->covers) * (cover_mask - *covers2++); - if(cover) - { - sl.add_cell(x, - (cover == cover_full * cover_full) ? - cover_full : - (cover >> cover_shift)); - } - ++x; - } - while(--len); - break; - - case 2: // span1 is AA, span2 is solid - covers1 = span1->covers; - if(span1->x < x) covers1 += x - span1->x; - if(*(span2->covers) != cover_full) - { - do - { - cover = *covers1++ * (cover_mask - *(span2->covers)); - if(cover) - { - sl.add_cell(x, - (cover == cover_full * cover_full) ? - cover_full : - (cover >> cover_shift)); - } - ++x; - } - while(--len); - } - break; - - case 3: // Both are solid spans - cover = *(span1->covers) * (cover_mask - *(span2->covers)); - if(cover) - { - sl.add_span(x, len, - (cover == cover_full * cover_full) ? - cover_full : - (cover >> cover_shift)); - } - break; - } - } - }; - - - - - - - //--------------------------------------------sbool_add_spans_and_render - template - void sbool_add_spans_and_render(const Scanline1& sl1, - Scanline& sl, - Renderer& ren, - AddSpanFunctor add_span) - { - sl.reset_spans(); - typename Scanline1::const_iterator span = sl1.begin(); - unsigned num_spans = sl1.num_spans(); - for(;;) - { - add_span(span, span->x, abs((int)span->len), sl); - if(--num_spans == 0) break; - ++span; - } - sl.finalize(sl1.y()); - ren.render(sl); - } - - - - - - - - //---------------------------------------------sbool_intersect_scanlines - // Intersect two scanlines, "sl1" and "sl2" and generate a new "sl" one. - // The combine_spans functor can be of type sbool_combine_spans_bin or - // sbool_intersect_spans_aa. First is a general functor to combine - // two spans without Anti-Aliasing, the second preserves the AA - // information, but works slower - // - template - void sbool_intersect_scanlines(const Scanline1& sl1, - const Scanline2& sl2, - Scanline& sl, - CombineSpansFunctor combine_spans) - { - sl.reset_spans(); - - unsigned num1 = sl1.num_spans(); - if(num1 == 0) return; - - unsigned num2 = sl2.num_spans(); - if(num2 == 0) return; - - typename Scanline1::const_iterator span1 = sl1.begin(); - typename Scanline2::const_iterator span2 = sl2.begin(); - - while(num1 && num2) - { - int xb1 = span1->x; - int xb2 = span2->x; - int xe1 = xb1 + abs((int)span1->len) - 1; - int xe2 = xb2 + abs((int)span2->len) - 1; - - // Determine what spans we should advance in the next step - // The span with the least ending X should be advanced - // advance_both is just an optimization when we ending - // coordinates are the same and we can advance both - //-------------- - bool advance_span1 = xe1 < xe2; - bool advance_both = xe1 == xe2; - - // Find the intersection of the spans - // and check if they intersect - //-------------- - if(xb1 < xb2) xb1 = xb2; - if(xe1 > xe2) xe1 = xe2; - if(xb1 <= xe1) - { - combine_spans(span1, span2, xb1, xe1 - xb1 + 1, sl); - } - - // Advance the spans - //-------------- - if(advance_both) - { - --num1; - --num2; - if(num1) ++span1; - if(num2) ++span2; - } - else - { - if(advance_span1) - { - --num1; - if(num1) ++span1; - } - else - { - --num2; - if(num2) ++span2; - } - } - } - } - - - - - - - - - //------------------------------------------------sbool_intersect_shapes - // Intersect the scanline shapes. Here the "Scanline Generator" - // abstraction is used. ScanlineGen1 and ScanlineGen2 are - // the generators, and can be of type rasterizer_scanline_aa<>. - // There function requires three scanline containers that can be of - // different types. - // "sl1" and "sl2" are used to retrieve scanlines from the generators, - // "sl" is ised as the resulting scanline to render it. - // The external "sl1" and "sl2" are used only for the sake of - // optimization and reusing of the scanline objects. - // the function calls sbool_intersect_scanlines with CombineSpansFunctor - // as the last argument. See sbool_intersect_scanlines for details. - //---------- - template - void sbool_intersect_shapes(ScanlineGen1& sg1, ScanlineGen2& sg2, - Scanline1& sl1, Scanline2& sl2, - Scanline& sl, Renderer& ren, - CombineSpansFunctor combine_spans) - { - // Prepare the scanline generators. - // If anyone of them doesn't contain - // any scanlines, then return. - //----------------- - if(!sg1.rewind_scanlines()) return; - if(!sg2.rewind_scanlines()) return; - - // Get the bounding boxes - //---------------- - rect_i r1(sg1.min_x(), sg1.min_y(), sg1.max_x(), sg1.max_y()); - rect_i r2(sg2.min_x(), sg2.min_y(), sg2.max_x(), sg2.max_y()); - - // Calculate the intersection of the bounding - // boxes and return if they don't intersect. - //----------------- - rect_i ir = intersect_rectangles(r1, r2); - if(!ir.is_valid()) return; - - // Reset the scanlines and get two first ones - //----------------- - sl.reset(ir.x1, ir.x2); - sl1.reset(sg1.min_x(), sg1.max_x()); - sl2.reset(sg2.min_x(), sg2.max_x()); - if(!sg1.sweep_scanline(sl1)) return; - if(!sg2.sweep_scanline(sl2)) return; - - ren.prepare(); - - // The main loop - // Here we synchronize the scanlines with - // the same Y coordinate, ignoring all other ones. - // Only scanlines having the same Y-coordinate - // are to be combined. - //----------------- - for(;;) - { - while(sl1.y() < sl2.y()) - { - if(!sg1.sweep_scanline(sl1)) return; - } - while(sl2.y() < sl1.y()) - { - if(!sg2.sweep_scanline(sl2)) return; - } - - if(sl1.y() == sl2.y()) - { - // The Y coordinates are the same. - // Combine the scanlines, render if they contain any spans, - // and advance both generators to the next scanlines - //---------------------- - sbool_intersect_scanlines(sl1, sl2, sl, combine_spans); - if(sl.num_spans()) - { - sl.finalize(sl1.y()); - ren.render(sl); - } - if(!sg1.sweep_scanline(sl1)) return; - if(!sg2.sweep_scanline(sl2)) return; - } - } - } - - - - - - - - //-------------------------------------------------sbool_unite_scanlines - // Unite two scanlines, "sl1" and "sl2" and generate a new "sl" one. - // The combine_spans functor can be of type sbool_combine_spans_bin or - // sbool_intersect_spans_aa. First is a general functor to combine - // two spans without Anti-Aliasing, the second preserves the AA - // information, but works slower - // - template - void sbool_unite_scanlines(const Scanline1& sl1, - const Scanline2& sl2, - Scanline& sl, - AddSpanFunctor1 add_span1, - AddSpanFunctor2 add_span2, - CombineSpansFunctor combine_spans) - { - sl.reset_spans(); - - unsigned num1 = sl1.num_spans(); - unsigned num2 = sl2.num_spans(); - - typename Scanline1::const_iterator span1;// = sl1.begin(); - typename Scanline2::const_iterator span2;// = sl2.begin(); - - enum invalidation_e - { - invalid_b = 0xFFFFFFF, - invalid_e = invalid_b - 1 - }; - - // Initialize the spans as invalid - //--------------- - int xb1 = invalid_b; - int xb2 = invalid_b; - int xe1 = invalid_e; - int xe2 = invalid_e; - - // Initialize span1 if there are spans - //--------------- - if(num1) - { - span1 = sl1.begin(); - xb1 = span1->x; - xe1 = xb1 + abs((int)span1->len) - 1; - --num1; - } - - // Initialize span2 if there are spans - //--------------- - if(num2) - { - span2 = sl2.begin(); - xb2 = span2->x; - xe2 = xb2 + abs((int)span2->len) - 1; - --num2; - } - - - for(;;) - { - // Retrieve a new span1 if it's invalid - //---------------- - if(num1 && xb1 > xe1) - { - --num1; - ++span1; - xb1 = span1->x; - xe1 = xb1 + abs((int)span1->len) - 1; - } - - // Retrieve a new span2 if it's invalid - //---------------- - if(num2 && xb2 > xe2) - { - --num2; - ++span2; - xb2 = span2->x; - xe2 = xb2 + abs((int)span2->len) - 1; - } - - if(xb1 > xe1 && xb2 > xe2) break; - - // Calculate the intersection - //---------------- - int xb = xb1; - int xe = xe1; - if(xb < xb2) xb = xb2; - if(xe > xe2) xe = xe2; - int len = xe - xb + 1; // The length of the intersection - if(len > 0) - { - // The spans intersect, - // add the beginning of the span - //---------------- - if(xb1 < xb2) - { - add_span1(span1, xb1, xb2 - xb1, sl); - xb1 = xb2; - } - else - if(xb2 < xb1) - { - add_span2(span2, xb2, xb1 - xb2, sl); - xb2 = xb1; - } - - // Add the combination part of the spans - //---------------- - combine_spans(span1, span2, xb, len, sl); - - - // Invalidate the fully processed span or both - //---------------- - if(xe1 < xe2) - { - // Invalidate span1 and eat - // the processed part of span2 - //-------------- - xb1 = invalid_b; - xe1 = invalid_e; - xb2 += len; - } - else - if(xe2 < xe1) - { - // Invalidate span2 and eat - // the processed part of span1 - //-------------- - xb2 = invalid_b; - xe2 = invalid_e; - xb1 += len; - } - else - { - xb1 = invalid_b; // Invalidate both - xb2 = invalid_b; - xe1 = invalid_e; - xe2 = invalid_e; - } - } - else - { - // The spans do not intersect - //-------------- - if(xb1 < xb2) - { - // Advance span1 - //--------------- - if(xb1 <= xe1) - { - add_span1(span1, xb1, xe1 - xb1 + 1, sl); - } - xb1 = invalid_b; // Invalidate - xe1 = invalid_e; - } - else - { - // Advance span2 - //--------------- - if(xb2 <= xe2) - { - add_span2(span2, xb2, xe2 - xb2 + 1, sl); - } - xb2 = invalid_b; // Invalidate - xe2 = invalid_e; - } - } - } - } - - - - - //----------------------------------------------------sbool_unite_shapes - // Unite the scanline shapes. Here the "Scanline Generator" - // abstraction is used. ScanlineGen1 and ScanlineGen2 are - // the generators, and can be of type rasterizer_scanline_aa<>. - // There function requires three scanline containers that can be - // of different type. - // "sl1" and "sl2" are used to retrieve scanlines from the generators, - // "sl" is ised as the resulting scanline to render it. - // The external "sl1" and "sl2" are used only for the sake of - // optimization and reusing of the scanline objects. - // the function calls sbool_unite_scanlines with CombineSpansFunctor - // as the last argument. See sbool_unite_scanlines for details. - //---------- - template - void sbool_unite_shapes(ScanlineGen1& sg1, ScanlineGen2& sg2, - Scanline1& sl1, Scanline2& sl2, - Scanline& sl, Renderer& ren, - AddSpanFunctor1 add_span1, - AddSpanFunctor2 add_span2, - CombineSpansFunctor combine_spans) - { - // Prepare the scanline generators. - // If anyone of them doesn't contain - // any scanlines, then return. - //----------------- - bool flag1 = sg1.rewind_scanlines(); - bool flag2 = sg2.rewind_scanlines(); - if(!flag1 && !flag2) return; - - // Get the bounding boxes - //---------------- - rect_i r1(sg1.min_x(), sg1.min_y(), sg1.max_x(), sg1.max_y()); - rect_i r2(sg2.min_x(), sg2.min_y(), sg2.max_x(), sg2.max_y()); - - // Calculate the union of the bounding boxes - //----------------- - rect_i ur(1,1,0,0); - if(flag1 && flag2) ur = unite_rectangles(r1, r2); - else if(flag1) ur = r1; - else if(flag2) ur = r2; - - if(!ur.is_valid()) return; - - ren.prepare(); - - // Reset the scanlines and get two first ones - //----------------- - sl.reset(ur.x1, ur.x2); - if(flag1) - { - sl1.reset(sg1.min_x(), sg1.max_x()); - flag1 = sg1.sweep_scanline(sl1); - } - - if(flag2) - { - sl2.reset(sg2.min_x(), sg2.max_x()); - flag2 = sg2.sweep_scanline(sl2); - } - - // The main loop - // Here we synchronize the scanlines with - // the same Y coordinate. - //----------------- - while(flag1 || flag2) - { - if(flag1 && flag2) - { - if(sl1.y() == sl2.y()) - { - // The Y coordinates are the same. - // Combine the scanlines, render if they contain any spans, - // and advance both generators to the next scanlines - //---------------------- - sbool_unite_scanlines(sl1, sl2, sl, - add_span1, add_span2, combine_spans); - if(sl.num_spans()) - { - sl.finalize(sl1.y()); - ren.render(sl); - } - flag1 = sg1.sweep_scanline(sl1); - flag2 = sg2.sweep_scanline(sl2); - } - else - { - if(sl1.y() < sl2.y()) - { - sbool_add_spans_and_render(sl1, sl, ren, add_span1); - flag1 = sg1.sweep_scanline(sl1); - } - else - { - sbool_add_spans_and_render(sl2, sl, ren, add_span2); - flag2 = sg2.sweep_scanline(sl2); - } - } - } - else - { - if(flag1) - { - sbool_add_spans_and_render(sl1, sl, ren, add_span1); - flag1 = sg1.sweep_scanline(sl1); - } - if(flag2) - { - sbool_add_spans_and_render(sl2, sl, ren, add_span2); - flag2 = sg2.sweep_scanline(sl2); - } - } - } - } - - - - - - - - - //-------------------------------------------------sbool_subtract_shapes - // Subtract the scanline shapes, "sg1-sg2". Here the "Scanline Generator" - // abstraction is used. ScanlineGen1 and ScanlineGen2 are - // the generators, and can be of type rasterizer_scanline_aa<>. - // There function requires three scanline containers that can be of - // different types. - // "sl1" and "sl2" are used to retrieve scanlines from the generators, - // "sl" is ised as the resulting scanline to render it. - // The external "sl1" and "sl2" are used only for the sake of - // optimization and reusing of the scanline objects. - // the function calls sbool_intersect_scanlines with CombineSpansFunctor - // as the last argument. See combine_scanlines_sub for details. - //---------- - template - void sbool_subtract_shapes(ScanlineGen1& sg1, ScanlineGen2& sg2, - Scanline1& sl1, Scanline2& sl2, - Scanline& sl, Renderer& ren, - AddSpanFunctor1 add_span1, - CombineSpansFunctor combine_spans) - { - // Prepare the scanline generators. - // Here "sg1" is master, "sg2" is slave. - //----------------- - if(!sg1.rewind_scanlines()) return; - bool flag2 = sg2.rewind_scanlines(); - - // Get the bounding box - //---------------- - rect_i r1(sg1.min_x(), sg1.min_y(), sg1.max_x(), sg1.max_y()); - - // Reset the scanlines and get two first ones - //----------------- - sl.reset(sg1.min_x(), sg1.max_x()); - sl1.reset(sg1.min_x(), sg1.max_x()); - sl2.reset(sg2.min_x(), sg2.max_x()); - if(!sg1.sweep_scanline(sl1)) return; - - if(flag2) flag2 = sg2.sweep_scanline(sl2); - - ren.prepare(); - - // A fake span2 processor - sbool_add_span_empty add_span2; - - // The main loop - // Here we synchronize the scanlines with - // the same Y coordinate, ignoring all other ones. - // Only scanlines having the same Y-coordinate - // are to be combined. - //----------------- - bool flag1 = true; - do - { - // Synchronize "slave" with "master" - //----------------- - while(flag2 && sl2.y() < sl1.y()) - { - flag2 = sg2.sweep_scanline(sl2); - } - - - if(flag2 && sl2.y() == sl1.y()) - { - // The Y coordinates are the same. - // Combine the scanlines and render if they contain any spans. - //---------------------- - sbool_unite_scanlines(sl1, sl2, sl, add_span1, add_span2, combine_spans); - if(sl.num_spans()) - { - sl.finalize(sl1.y()); - ren.render(sl); - } - } - else - { - sbool_add_spans_and_render(sl1, sl, ren, add_span1); - } - - // Advance the "master" - flag1 = sg1.sweep_scanline(sl1); - } - while(flag1); - } - - - - - - - - //---------------------------------------------sbool_intersect_shapes_aa - // Intersect two anti-aliased scanline shapes. - // Here the "Scanline Generator" abstraction is used. - // ScanlineGen1 and ScanlineGen2 are the generators, and can be of - // type rasterizer_scanline_aa<>. There function requires three - // scanline containers that can be of different types. - // "sl1" and "sl2" are used to retrieve scanlines from the generators, - // "sl" is ised as the resulting scanline to render it. - // The external "sl1" and "sl2" are used only for the sake of - // optimization and reusing of the scanline objects. - //---------- - template - void sbool_intersect_shapes_aa(ScanlineGen1& sg1, ScanlineGen2& sg2, - Scanline1& sl1, Scanline2& sl2, - Scanline& sl, Renderer& ren) - { - sbool_intersect_spans_aa combine_functor; - sbool_intersect_shapes(sg1, sg2, sl1, sl2, sl, ren, combine_functor); - } - - - - - - //--------------------------------------------sbool_intersect_shapes_bin - // Intersect two binary scanline shapes (without anti-aliasing). - // See intersect_shapes_aa for more comments - //---------- - template - void sbool_intersect_shapes_bin(ScanlineGen1& sg1, ScanlineGen2& sg2, - Scanline1& sl1, Scanline2& sl2, - Scanline& sl, Renderer& ren) - { - sbool_combine_spans_bin combine_functor; - sbool_intersect_shapes(sg1, sg2, sl1, sl2, sl, ren, combine_functor); - } - - - - - - //-------------------------------------------------sbool_unite_shapes_aa - // Unite two anti-aliased scanline shapes - // See intersect_shapes_aa for more comments - //---------- - template - void sbool_unite_shapes_aa(ScanlineGen1& sg1, ScanlineGen2& sg2, - Scanline1& sl1, Scanline2& sl2, - Scanline& sl, Renderer& ren) - { - sbool_add_span_aa add_functor1; - sbool_add_span_aa add_functor2; - sbool_unite_spans_aa combine_functor; - sbool_unite_shapes(sg1, sg2, sl1, sl2, sl, ren, - add_functor1, add_functor2, combine_functor); - } - - - - - - //------------------------------------------------sbool_unite_shapes_bin - // Unite two binary scanline shapes (without anti-aliasing). - // See intersect_shapes_aa for more comments - //---------- - template - void sbool_unite_shapes_bin(ScanlineGen1& sg1, ScanlineGen2& sg2, - Scanline1& sl1, Scanline2& sl2, - Scanline& sl, Renderer& ren) - { - sbool_add_span_bin add_functor1; - sbool_add_span_bin add_functor2; - sbool_combine_spans_bin combine_functor; - sbool_unite_shapes(sg1, sg2, sl1, sl2, sl, ren, - add_functor1, add_functor2, combine_functor); - } - - - - - - - - - - //---------------------------------------------------sbool_xor_shapes_aa - // Apply eXclusive OR to two anti-aliased scanline shapes. There's - // a modified "Linear" XOR used instead of classical "Saddle" one. - // The reason is to have the result absolutely conststent with what - // the scanline rasterizer produces. - // See intersect_shapes_aa for more comments - //---------- - template - void sbool_xor_shapes_aa(ScanlineGen1& sg1, ScanlineGen2& sg2, - Scanline1& sl1, Scanline2& sl2, - Scanline& sl, Renderer& ren) - { - sbool_add_span_aa add_functor1; - sbool_add_span_aa add_functor2; - sbool_xor_spans_aa > combine_functor; - sbool_unite_shapes(sg1, sg2, sl1, sl2, sl, ren, - add_functor1, add_functor2, combine_functor); - } - - - - //------------------------------------------sbool_xor_shapes_saddle_aa - // Apply eXclusive OR to two anti-aliased scanline shapes. - // There's the classical "Saddle" used to calculate the - // Anti-Aliasing values, that is: - // a XOR b : 1-((1-a+a*b)*(1-b+a*b)) - // See intersect_shapes_aa for more comments - //---------- - template - void sbool_xor_shapes_saddle_aa(ScanlineGen1& sg1, ScanlineGen2& sg2, - Scanline1& sl1, Scanline2& sl2, - Scanline& sl, Renderer& ren) - { - sbool_add_span_aa add_functor1; - sbool_add_span_aa add_functor2; - sbool_xor_spans_aa > combine_functor; - sbool_unite_shapes(sg1, sg2, sl1, sl2, sl, ren, - add_functor1, add_functor2, combine_functor); - } - - - //--------------------------------------sbool_xor_shapes_abs_diff_aa - // Apply eXclusive OR to two anti-aliased scanline shapes. - // There's the absolute difference used to calculate - // Anti-Aliasing values, that is: - // a XOR b : abs(a-b) - // See intersect_shapes_aa for more comments - //---------- - template - void sbool_xor_shapes_abs_diff_aa(ScanlineGen1& sg1, ScanlineGen2& sg2, - Scanline1& sl1, Scanline2& sl2, - Scanline& sl, Renderer& ren) - { - sbool_add_span_aa add_functor1; - sbool_add_span_aa add_functor2; - sbool_xor_spans_aa combine_functor; - sbool_unite_shapes(sg1, sg2, sl1, sl2, sl, ren, - add_functor1, add_functor2, combine_functor); - } - - - - //--------------------------------------------------sbool_xor_shapes_bin - // Apply eXclusive OR to two binary scanline shapes (without anti-aliasing). - // See intersect_shapes_aa for more comments - //---------- - template - void sbool_xor_shapes_bin(ScanlineGen1& sg1, ScanlineGen2& sg2, - Scanline1& sl1, Scanline2& sl2, - Scanline& sl, Renderer& ren) - { - sbool_add_span_bin add_functor1; - sbool_add_span_bin add_functor2; - sbool_combine_spans_empty combine_functor; - sbool_unite_shapes(sg1, sg2, sl1, sl2, sl, ren, - add_functor1, add_functor2, combine_functor); - } - - - - - - - //----------------------------------------------sbool_subtract_shapes_aa - // Subtract shapes "sg1-sg2" with anti-aliasing - // See intersect_shapes_aa for more comments - //---------- - template - void sbool_subtract_shapes_aa(ScanlineGen1& sg1, ScanlineGen2& sg2, - Scanline1& sl1, Scanline2& sl2, - Scanline& sl, Renderer& ren) - { - sbool_add_span_aa add_functor; - sbool_subtract_spans_aa combine_functor; - sbool_subtract_shapes(sg1, sg2, sl1, sl2, sl, ren, - add_functor, combine_functor); - } - - - - - - //---------------------------------------------sbool_subtract_shapes_bin - // Subtract binary shapes "sg1-sg2" without anti-aliasing - // See intersect_shapes_aa for more comments - //---------- - template - void sbool_subtract_shapes_bin(ScanlineGen1& sg1, ScanlineGen2& sg2, - Scanline1& sl1, Scanline2& sl2, - Scanline& sl, Renderer& ren) - { - sbool_add_span_bin add_functor; - sbool_combine_spans_empty combine_functor; - sbool_subtract_shapes(sg1, sg2, sl1, sl2, sl, ren, - add_functor, combine_functor); - } - - - - - - - //------------------------------------------------------------sbool_op_e - enum sbool_op_e - { - sbool_or, //----sbool_or - sbool_and, //----sbool_and - sbool_xor, //----sbool_xor - sbool_xor_saddle, //----sbool_xor_saddle - sbool_xor_abs_diff, //----sbool_xor_abs_diff - sbool_a_minus_b, //----sbool_a_minus_b - sbool_b_minus_a //----sbool_b_minus_a - }; - - - - - - - //----------------------------------------------sbool_combine_shapes_bin - template - void sbool_combine_shapes_bin(sbool_op_e op, - ScanlineGen1& sg1, ScanlineGen2& sg2, - Scanline1& sl1, Scanline2& sl2, - Scanline& sl, Renderer& ren) - { - switch(op) - { - case sbool_or : sbool_unite_shapes_bin (sg1, sg2, sl1, sl2, sl, ren); break; - case sbool_and : sbool_intersect_shapes_bin(sg1, sg2, sl1, sl2, sl, ren); break; - case sbool_xor : - case sbool_xor_saddle : - case sbool_xor_abs_diff: sbool_xor_shapes_bin (sg1, sg2, sl1, sl2, sl, ren); break; - case sbool_a_minus_b : sbool_subtract_shapes_bin (sg1, sg2, sl1, sl2, sl, ren); break; - case sbool_b_minus_a : sbool_subtract_shapes_bin (sg2, sg1, sl2, sl1, sl, ren); break; - } - } - - - - - //-----------------------------------------------sbool_combine_shapes_aa - template - void sbool_combine_shapes_aa(sbool_op_e op, - ScanlineGen1& sg1, ScanlineGen2& sg2, - Scanline1& sl1, Scanline2& sl2, - Scanline& sl, Renderer& ren) - { - switch(op) - { - case sbool_or : sbool_unite_shapes_aa (sg1, sg2, sl1, sl2, sl, ren); break; - case sbool_and : sbool_intersect_shapes_aa (sg1, sg2, sl1, sl2, sl, ren); break; - case sbool_xor : sbool_xor_shapes_aa (sg1, sg2, sl1, sl2, sl, ren); break; - case sbool_xor_saddle : sbool_xor_shapes_saddle_aa (sg1, sg2, sl1, sl2, sl, ren); break; - case sbool_xor_abs_diff: sbool_xor_shapes_abs_diff_aa(sg1, sg2, sl1, sl2, sl, ren); break; - case sbool_a_minus_b : sbool_subtract_shapes_aa (sg1, sg2, sl1, sl2, sl, ren); break; - case sbool_b_minus_a : sbool_subtract_shapes_aa (sg2, sg1, sl2, sl1, sl, ren); break; - } - } - -} - - -#endif - diff --git a/desmume/src/windows/agg/include/agg_scanline_p.h b/desmume/src/windows/agg/include/agg_scanline_p.h deleted file mode 100644 index 2380bcefb..000000000 --- a/desmume/src/windows/agg/include/agg_scanline_p.h +++ /dev/null @@ -1,334 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- -// -// Adaptation for 32-bit screen coordinates (scanline32_p) has been sponsored by -// Liberty Technology Systems, Inc., visit http://lib-sys.com -// -// Liberty Technology Systems, Inc. is the provider of -// PostScript and PDF technology for software developers. -// -//---------------------------------------------------------------------------- -#ifndef AGG_SCANLINE_P_INCLUDED -#define AGG_SCANLINE_P_INCLUDED - -#include "agg_array.h" - -namespace agg -{ - - //=============================================================scanline_p8 - // - // This is a general purpose scaline container which supports the interface - // used in the rasterizer::render(). See description of scanline_u8 - // for details. - // - //------------------------------------------------------------------------ - class scanline_p8 - { - public: - typedef scanline_p8 self_type; - typedef int8u cover_type; - typedef int16 coord_type; - - //-------------------------------------------------------------------- - struct span - { - coord_type x; - coord_type len; // If negative, it's a solid span, covers is valid - const cover_type* covers; - }; - - typedef span* iterator; - typedef const span* const_iterator; - - scanline_p8() : - m_last_x(0x7FFFFFF0), - m_covers(), - m_cover_ptr(0), - m_spans(), - m_cur_span(0) - { - } - - //-------------------------------------------------------------------- - void reset(int min_x, int max_x) - { - unsigned max_len = max_x - min_x + 3; - if(max_len > m_spans.size()) - { - m_spans.resize(max_len); - m_covers.resize(max_len); - } - m_last_x = 0x7FFFFFF0; - m_cover_ptr = &m_covers[0]; - m_cur_span = &m_spans[0]; - m_cur_span->len = 0; - } - - //-------------------------------------------------------------------- - void add_cell(int x, unsigned cover) - { - *m_cover_ptr = (cover_type)cover; - if(x == m_last_x+1 && m_cur_span->len > 0) - { - m_cur_span->len++; - } - else - { - m_cur_span++; - m_cur_span->covers = m_cover_ptr; - m_cur_span->x = (int16)x; - m_cur_span->len = 1; - } - m_last_x = x; - m_cover_ptr++; - } - - //-------------------------------------------------------------------- - void add_cells(int x, unsigned len, const cover_type* covers) - { - memcpy(m_cover_ptr, covers, len * sizeof(cover_type)); - if(x == m_last_x+1 && m_cur_span->len > 0) - { - m_cur_span->len += (int16)len; - } - else - { - m_cur_span++; - m_cur_span->covers = m_cover_ptr; - m_cur_span->x = (int16)x; - m_cur_span->len = (int16)len; - } - m_cover_ptr += len; - m_last_x = x + len - 1; - } - - //-------------------------------------------------------------------- - void add_span(int x, unsigned len, unsigned cover) - { - if(x == m_last_x+1 && - m_cur_span->len < 0 && - cover == *m_cur_span->covers) - { - m_cur_span->len -= (int16)len; - } - else - { - *m_cover_ptr = (cover_type)cover; - m_cur_span++; - m_cur_span->covers = m_cover_ptr++; - m_cur_span->x = (int16)x; - m_cur_span->len = (int16)(-int(len)); - } - m_last_x = x + len - 1; - } - - //-------------------------------------------------------------------- - void finalize(int y) - { - m_y = y; - } - - //-------------------------------------------------------------------- - void reset_spans() - { - m_last_x = 0x7FFFFFF0; - m_cover_ptr = &m_covers[0]; - m_cur_span = &m_spans[0]; - m_cur_span->len = 0; - } - - //-------------------------------------------------------------------- - int y() const { return m_y; } - unsigned num_spans() const { return unsigned(m_cur_span - &m_spans[0]); } - const_iterator begin() const { return &m_spans[1]; } - - private: - scanline_p8(const self_type&); - const self_type& operator = (const self_type&); - - int m_last_x; - int m_y; - pod_array m_covers; - cover_type* m_cover_ptr; - pod_array m_spans; - span* m_cur_span; - }; - - - - - - - - - //==========================================================scanline32_p8 - class scanline32_p8 - { - public: - typedef scanline32_p8 self_type; - typedef int8u cover_type; - typedef int32 coord_type; - - struct span - { - span() {} - span(coord_type x_, coord_type len_, const cover_type* covers_) : - x(x_), len(len_), covers(covers_) {} - - coord_type x; - coord_type len; // If negative, it's a solid span, covers is valid - const cover_type* covers; - }; - typedef pod_bvector span_array_type; - - - //-------------------------------------------------------------------- - class const_iterator - { - public: - const_iterator(const span_array_type& spans) : - m_spans(spans), - m_span_idx(0) - {} - - const span& operator*() const { return m_spans[m_span_idx]; } - const span* operator->() const { return &m_spans[m_span_idx]; } - - void operator ++ () { ++m_span_idx; } - - private: - const span_array_type& m_spans; - unsigned m_span_idx; - }; - - //-------------------------------------------------------------------- - scanline32_p8() : - m_max_len(0), - m_last_x(0x7FFFFFF0), - m_covers(), - m_cover_ptr(0) - { - } - - //-------------------------------------------------------------------- - void reset(int min_x, int max_x) - { - unsigned max_len = max_x - min_x + 3; - if(max_len > m_covers.size()) - { - m_covers.resize(max_len); - } - m_last_x = 0x7FFFFFF0; - m_cover_ptr = &m_covers[0]; - m_spans.remove_all(); - } - - //-------------------------------------------------------------------- - void add_cell(int x, unsigned cover) - { - *m_cover_ptr = cover_type(cover); - if(x == m_last_x+1 && m_spans.size() && m_spans.last().len > 0) - { - m_spans.last().len++; - } - else - { - m_spans.add(span(coord_type(x), 1, m_cover_ptr)); - } - m_last_x = x; - m_cover_ptr++; - } - - //-------------------------------------------------------------------- - void add_cells(int x, unsigned len, const cover_type* covers) - { - memcpy(m_cover_ptr, covers, len * sizeof(cover_type)); - if(x == m_last_x+1 && m_spans.size() && m_spans.last().len > 0) - { - m_spans.last().len += coord_type(len); - } - else - { - m_spans.add(span(coord_type(x), coord_type(len), m_cover_ptr)); - } - m_cover_ptr += len; - m_last_x = x + len - 1; - } - - //-------------------------------------------------------------------- - void add_span(int x, unsigned len, unsigned cover) - { - if(x == m_last_x+1 && - m_spans.size() && - m_spans.last().len < 0 && - cover == *m_spans.last().covers) - { - m_spans.last().len -= coord_type(len); - } - else - { - *m_cover_ptr = cover_type(cover); - m_spans.add(span(coord_type(x), -coord_type(len), m_cover_ptr++)); - } - m_last_x = x + len - 1; - } - - //-------------------------------------------------------------------- - void finalize(int y) - { - m_y = y; - } - - //-------------------------------------------------------------------- - void reset_spans() - { - m_last_x = 0x7FFFFFF0; - m_cover_ptr = &m_covers[0]; - m_spans.remove_all(); - } - - //-------------------------------------------------------------------- - int y() const { return m_y; } - unsigned num_spans() const { return m_spans.size(); } - const_iterator begin() const { return const_iterator(m_spans); } - - private: - scanline32_p8(const self_type&); - const self_type& operator = (const self_type&); - - unsigned m_max_len; - int m_last_x; - int m_y; - pod_array m_covers; - cover_type* m_cover_ptr; - span_array_type m_spans; - }; - - -} - - -#endif - diff --git a/desmume/src/windows/agg/include/agg_scanline_storage_aa.h b/desmume/src/windows/agg/include/agg_scanline_storage_aa.h deleted file mode 100644 index 09e3434e1..000000000 --- a/desmume/src/windows/agg/include/agg_scanline_storage_aa.h +++ /dev/null @@ -1,824 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- -// -// Adaptation for 32-bit screen coordinates has been sponsored by -// Liberty Technology Systems, Inc., visit http://lib-sys.com -// -// Liberty Technology Systems, Inc. is the provider of -// PostScript and PDF technology for software developers. -// -//---------------------------------------------------------------------------- - -#ifndef AGG_SCANLINE_STORAGE_AA_INCLUDED -#define AGG_SCANLINE_STORAGE_AA_INCLUDED - -#include -#include -#include -#include "agg_array.h" - - -namespace agg -{ - - //----------------------------------------------scanline_cell_storage - template class scanline_cell_storage - { - struct extra_span - { - unsigned len; - T* ptr; - }; - - public: - typedef T value_type; - - //--------------------------------------------------------------- - ~scanline_cell_storage() - { - remove_all(); - } - - //--------------------------------------------------------------- - scanline_cell_storage() : - m_cells(128-2), - m_extra_storage() - {} - - - // Copying - //--------------------------------------------------------------- - scanline_cell_storage(const scanline_cell_storage& v) : - m_cells(v.m_cells), - m_extra_storage() - { - copy_extra_storage(v); - } - - //--------------------------------------------------------------- - const scanline_cell_storage& - operator = (const scanline_cell_storage& v) - { - remove_all(); - m_cells = v.m_cells; - copy_extra_storage(v); - return *this; - } - - //--------------------------------------------------------------- - void remove_all() - { - int i; - for(i = m_extra_storage.size()-1; i >= 0; --i) - { - pod_allocator::deallocate(m_extra_storage[i].ptr, - m_extra_storage[i].len); - } - m_extra_storage.remove_all(); - m_cells.remove_all(); - } - - //--------------------------------------------------------------- - int add_cells(const T* cells, unsigned num_cells) - { - int idx = m_cells.allocate_continuous_block(num_cells); - if(idx >= 0) - { - T* ptr = &m_cells[idx]; - memcpy(ptr, cells, sizeof(T) * num_cells); - return idx; - } - extra_span s; - s.len = num_cells; - s.ptr = pod_allocator::allocate(num_cells); - memcpy(s.ptr, cells, sizeof(T) * num_cells); - m_extra_storage.add(s); - return -int(m_extra_storage.size()); - } - - //--------------------------------------------------------------- - const T* operator [] (int idx) const - { - if(idx >= 0) - { - if((unsigned)idx >= m_cells.size()) return 0; - return &m_cells[(unsigned)idx]; - } - unsigned i = unsigned(-idx - 1); - if(i >= m_extra_storage.size()) return 0; - return m_extra_storage[i].ptr; - } - - //--------------------------------------------------------------- - T* operator [] (int idx) - { - if(idx >= 0) - { - if((unsigned)idx >= m_cells.size()) return 0; - return &m_cells[(unsigned)idx]; - } - unsigned i = unsigned(-idx - 1); - if(i >= m_extra_storage.size()) return 0; - return m_extra_storage[i].ptr; - } - - private: - void copy_extra_storage(const scanline_cell_storage& v) - { - unsigned i; - for(i = 0; i < v.m_extra_storage.size(); ++i) - { - const extra_span& src = v.m_extra_storage[i]; - extra_span dst; - dst.len = src.len; - dst.ptr = pod_allocator::allocate(dst.len); - memcpy(dst.ptr, src.ptr, dst.len * sizeof(T)); - m_extra_storage.add(dst); - } - } - - pod_bvector m_cells; - pod_bvector m_extra_storage; - }; - - - - - - - //-----------------------------------------------scanline_storage_aa - template class scanline_storage_aa - { - public: - typedef T cover_type; - - //--------------------------------------------------------------- - struct span_data - { - int32 x; - int32 len; // If negative, it's a solid span, covers is valid - int covers_id; // The index of the cells in the scanline_cell_storage - }; - - //--------------------------------------------------------------- - struct scanline_data - { - int y; - unsigned num_spans; - unsigned start_span; - }; - - - //--------------------------------------------------------------- - class embedded_scanline - { - public: - - //----------------------------------------------------------- - class const_iterator - { - public: - struct span - { - int32 x; - int32 len; // If negative, it's a solid span, covers is valid - const T* covers; - }; - - const_iterator() : m_storage(0) {} - const_iterator(const embedded_scanline& sl) : - m_storage(sl.m_storage), - m_span_idx(sl.m_scanline.start_span) - { - init_span(); - } - - const span& operator*() const { return m_span; } - const span* operator->() const { return &m_span; } - - void operator ++ () - { - ++m_span_idx; - init_span(); - } - - private: - void init_span() - { - const span_data& s = m_storage->span_by_index(m_span_idx); - m_span.x = s.x; - m_span.len = s.len; - m_span.covers = m_storage->covers_by_index(s.covers_id); - } - - const scanline_storage_aa* m_storage; - unsigned m_span_idx; - span m_span; - }; - - friend class const_iterator; - - - //----------------------------------------------------------- - embedded_scanline(const scanline_storage_aa& storage) : - m_storage(&storage) - { - init(0); - } - - //----------------------------------------------------------- - void reset(int, int) {} - unsigned num_spans() const { return m_scanline.num_spans; } - int y() const { return m_scanline.y; } - const_iterator begin() const { return const_iterator(*this); } - - //----------------------------------------------------------- - void init(unsigned scanline_idx) - { - m_scanline_idx = scanline_idx; - m_scanline = m_storage->scanline_by_index(m_scanline_idx); - } - - private: - const scanline_storage_aa* m_storage; - scanline_data m_scanline; - unsigned m_scanline_idx; - }; - - - //--------------------------------------------------------------- - scanline_storage_aa() : - m_covers(), - m_spans(256-2), // Block increment size - m_scanlines(), - m_min_x( 0x7FFFFFFF), - m_min_y( 0x7FFFFFFF), - m_max_x(-0x7FFFFFFF), - m_max_y(-0x7FFFFFFF), - m_cur_scanline(0) - { - m_fake_scanline.y = 0; - m_fake_scanline.num_spans = 0; - m_fake_scanline.start_span = 0; - m_fake_span.x = 0; - m_fake_span.len = 0; - m_fake_span.covers_id = 0; - } - - // Renderer Interface - //--------------------------------------------------------------- - void prepare() - { - m_covers.remove_all(); - m_scanlines.remove_all(); - m_spans.remove_all(); - m_min_x = 0x7FFFFFFF; - m_min_y = 0x7FFFFFFF; - m_max_x = -0x7FFFFFFF; - m_max_y = -0x7FFFFFFF; - m_cur_scanline = 0; - } - - //--------------------------------------------------------------- - template void render(const Scanline& sl) - { - scanline_data sl_this; - - int y = sl.y(); - if(y < m_min_y) m_min_y = y; - if(y > m_max_y) m_max_y = y; - - sl_this.y = y; - sl_this.num_spans = sl.num_spans(); - sl_this.start_span = m_spans.size(); - typename Scanline::const_iterator span_iterator = sl.begin(); - - unsigned num_spans = sl_this.num_spans; - for(;;) - { - span_data sp; - - sp.x = span_iterator->x; - sp.len = span_iterator->len; - int len = abs(int(sp.len)); - sp.covers_id = - m_covers.add_cells(span_iterator->covers, - unsigned(len)); - m_spans.add(sp); - int x1 = sp.x; - int x2 = sp.x + len - 1; - if(x1 < m_min_x) m_min_x = x1; - if(x2 > m_max_x) m_max_x = x2; - if(--num_spans == 0) break; - ++span_iterator; - } - m_scanlines.add(sl_this); - } - - - //--------------------------------------------------------------- - // Iterate scanlines interface - int min_x() const { return m_min_x; } - int min_y() const { return m_min_y; } - int max_x() const { return m_max_x; } - int max_y() const { return m_max_y; } - - //--------------------------------------------------------------- - bool rewind_scanlines() - { - m_cur_scanline = 0; - return m_scanlines.size() > 0; - } - - - //--------------------------------------------------------------- - template bool sweep_scanline(Scanline& sl) - { - sl.reset_spans(); - for(;;) - { - if(m_cur_scanline >= m_scanlines.size()) return false; - const scanline_data& sl_this = m_scanlines[m_cur_scanline]; - - unsigned num_spans = sl_this.num_spans; - unsigned span_idx = sl_this.start_span; - do - { - const span_data& sp = m_spans[span_idx++]; - const T* covers = covers_by_index(sp.covers_id); - if(sp.len < 0) - { - sl.add_span(sp.x, unsigned(-sp.len), *covers); - } - else - { - sl.add_cells(sp.x, sp.len, covers); - } - } - while(--num_spans); - ++m_cur_scanline; - if(sl.num_spans()) - { - sl.finalize(sl_this.y); - break; - } - } - return true; - } - - - //--------------------------------------------------------------- - // Specialization for embedded_scanline - bool sweep_scanline(embedded_scanline& sl) - { - do - { - if(m_cur_scanline >= m_scanlines.size()) return false; - sl.init(m_cur_scanline); - ++m_cur_scanline; - } - while(sl.num_spans() == 0); - return true; - } - - //--------------------------------------------------------------- - unsigned byte_size() const - { - unsigned i; - unsigned size = sizeof(int32) * 4; // min_x, min_y, max_x, max_y - - for(i = 0; i < m_scanlines.size(); ++i) - { - size += sizeof(int32) * 3; // scanline size in bytes, Y, num_spans - - const scanline_data& sl_this = m_scanlines[i]; - - unsigned num_spans = sl_this.num_spans; - unsigned span_idx = sl_this.start_span; - do - { - const span_data& sp = m_spans[span_idx++]; - - size += sizeof(int32) * 2; // X, span_len - if(sp.len < 0) - { - size += sizeof(T); // cover - } - else - { - size += sizeof(T) * unsigned(sp.len); // covers - } - } - while(--num_spans); - } - return size; - } - - - //--------------------------------------------------------------- - static void write_int32(int8u* dst, int32 val) - { - dst[0] = ((const int8u*)&val)[0]; - dst[1] = ((const int8u*)&val)[1]; - dst[2] = ((const int8u*)&val)[2]; - dst[3] = ((const int8u*)&val)[3]; - } - - - //--------------------------------------------------------------- - void serialize(int8u* data) const - { - unsigned i; - - write_int32(data, min_x()); // min_x - data += sizeof(int32); - write_int32(data, min_y()); // min_y - data += sizeof(int32); - write_int32(data, max_x()); // max_x - data += sizeof(int32); - write_int32(data, max_y()); // max_y - data += sizeof(int32); - - for(i = 0; i < m_scanlines.size(); ++i) - { - const scanline_data& sl_this = m_scanlines[i]; - - int8u* size_ptr = data; - data += sizeof(int32); // Reserve space for scanline size in bytes - - write_int32(data, sl_this.y); // Y - data += sizeof(int32); - - write_int32(data, sl_this.num_spans); // num_spans - data += sizeof(int32); - - unsigned num_spans = sl_this.num_spans; - unsigned span_idx = sl_this.start_span; - do - { - const span_data& sp = m_spans[span_idx++]; - const T* covers = covers_by_index(sp.covers_id); - - write_int32(data, sp.x); // X - data += sizeof(int32); - - write_int32(data, sp.len); // span_len - data += sizeof(int32); - - if(sp.len < 0) - { - memcpy(data, covers, sizeof(T)); - data += sizeof(T); - } - else - { - memcpy(data, covers, unsigned(sp.len) * sizeof(T)); - data += sizeof(T) * unsigned(sp.len); - } - } - while(--num_spans); - write_int32(size_ptr, int32(unsigned(data - size_ptr))); - } - } - - - //--------------------------------------------------------------- - const scanline_data& scanline_by_index(unsigned i) const - { - return (i < m_scanlines.size()) ? m_scanlines[i] : m_fake_scanline; - } - - //--------------------------------------------------------------- - const span_data& span_by_index(unsigned i) const - { - return (i < m_spans.size()) ? m_spans[i] : m_fake_span; - } - - //--------------------------------------------------------------- - const T* covers_by_index(int i) const - { - return m_covers[i]; - } - - private: - scanline_cell_storage m_covers; - pod_bvector m_spans; - pod_bvector m_scanlines; - span_data m_fake_span; - scanline_data m_fake_scanline; - int m_min_x; - int m_min_y; - int m_max_x; - int m_max_y; - unsigned m_cur_scanline; - }; - - - typedef scanline_storage_aa scanline_storage_aa8; //--------scanline_storage_aa8 - typedef scanline_storage_aa scanline_storage_aa16; //--------scanline_storage_aa16 - typedef scanline_storage_aa scanline_storage_aa32; //--------scanline_storage_aa32 - - - - - //------------------------------------------serialized_scanlines_adaptor_aa - template class serialized_scanlines_adaptor_aa - { - public: - typedef T cover_type; - - //--------------------------------------------------------------------- - class embedded_scanline - { - public: - typedef T cover_type; - - //----------------------------------------------------------------- - class const_iterator - { - public: - struct span - { - int32 x; - int32 len; // If negative, it's a solid span, "covers" is valid - const T* covers; - }; - - const_iterator() : m_ptr(0) {} - const_iterator(const embedded_scanline& sl) : - m_ptr(sl.m_ptr), - m_dx(sl.m_dx) - { - init_span(); - } - - const span& operator*() const { return m_span; } - const span* operator->() const { return &m_span; } - - void operator ++ () - { - if(m_span.len < 0) - { - m_ptr += sizeof(T); - } - else - { - m_ptr += m_span.len * sizeof(T); - } - init_span(); - } - - private: - int read_int32() - { - int32 val; - ((int8u*)&val)[0] = *m_ptr++; - ((int8u*)&val)[1] = *m_ptr++; - ((int8u*)&val)[2] = *m_ptr++; - ((int8u*)&val)[3] = *m_ptr++; - return val; - } - - void init_span() - { - m_span.x = read_int32() + m_dx; - m_span.len = read_int32(); - m_span.covers = m_ptr; - } - - const int8u* m_ptr; - span m_span; - int m_dx; - }; - - friend class const_iterator; - - - //----------------------------------------------------------------- - embedded_scanline() : m_ptr(0), m_y(0), m_num_spans(0) {} - - //----------------------------------------------------------------- - void reset(int, int) {} - unsigned num_spans() const { return m_num_spans; } - int y() const { return m_y; } - const_iterator begin() const { return const_iterator(*this); } - - - private: - //----------------------------------------------------------------- - int read_int32() - { - int32 val; - ((int8u*)&val)[0] = *m_ptr++; - ((int8u*)&val)[1] = *m_ptr++; - ((int8u*)&val)[2] = *m_ptr++; - ((int8u*)&val)[3] = *m_ptr++; - return val; - } - - public: - //----------------------------------------------------------------- - void init(const int8u* ptr, int dx, int dy) - { - m_ptr = ptr; - m_y = read_int32() + dy; - m_num_spans = unsigned(read_int32()); - m_dx = dx; - } - - private: - const int8u* m_ptr; - int m_y; - unsigned m_num_spans; - int m_dx; - }; - - - - public: - //-------------------------------------------------------------------- - serialized_scanlines_adaptor_aa() : - m_data(0), - m_end(0), - m_ptr(0), - m_dx(0), - m_dy(0), - m_min_x(0x7FFFFFFF), - m_min_y(0x7FFFFFFF), - m_max_x(-0x7FFFFFFF), - m_max_y(-0x7FFFFFFF) - {} - - //-------------------------------------------------------------------- - serialized_scanlines_adaptor_aa(const int8u* data, unsigned size, - double dx, double dy) : - m_data(data), - m_end(data + size), - m_ptr(data), - m_dx(iround(dx)), - m_dy(iround(dy)), - m_min_x(0x7FFFFFFF), - m_min_y(0x7FFFFFFF), - m_max_x(-0x7FFFFFFF), - m_max_y(-0x7FFFFFFF) - {} - - //-------------------------------------------------------------------- - void init(const int8u* data, unsigned size, double dx, double dy) - { - m_data = data; - m_end = data + size; - m_ptr = data; - m_dx = iround(dx); - m_dy = iround(dy); - m_min_x = 0x7FFFFFFF; - m_min_y = 0x7FFFFFFF; - m_max_x = -0x7FFFFFFF; - m_max_y = -0x7FFFFFFF; - } - - private: - //-------------------------------------------------------------------- - int read_int32() - { - int32 val; - ((int8u*)&val)[0] = *m_ptr++; - ((int8u*)&val)[1] = *m_ptr++; - ((int8u*)&val)[2] = *m_ptr++; - ((int8u*)&val)[3] = *m_ptr++; - return val; - } - - //-------------------------------------------------------------------- - unsigned read_int32u() - { - int32u val; - ((int8u*)&val)[0] = *m_ptr++; - ((int8u*)&val)[1] = *m_ptr++; - ((int8u*)&val)[2] = *m_ptr++; - ((int8u*)&val)[3] = *m_ptr++; - return val; - } - - public: - // Iterate scanlines interface - //-------------------------------------------------------------------- - bool rewind_scanlines() - { - m_ptr = m_data; - if(m_ptr < m_end) - { - m_min_x = read_int32() + m_dx; - m_min_y = read_int32() + m_dy; - m_max_x = read_int32() + m_dx; - m_max_y = read_int32() + m_dy; - } - return m_ptr < m_end; - } - - //-------------------------------------------------------------------- - int min_x() const { return m_min_x; } - int min_y() const { return m_min_y; } - int max_x() const { return m_max_x; } - int max_y() const { return m_max_y; } - - //-------------------------------------------------------------------- - template bool sweep_scanline(Scanline& sl) - { - sl.reset_spans(); - for(;;) - { - if(m_ptr >= m_end) return false; - - read_int32(); // Skip scanline size in bytes - int y = read_int32() + m_dy; - unsigned num_spans = read_int32(); - - do - { - int x = read_int32() + m_dx; - int len = read_int32(); - - if(len < 0) - { - sl.add_span(x, unsigned(-len), *m_ptr); - m_ptr += sizeof(T); - } - else - { - sl.add_cells(x, len, m_ptr); - m_ptr += len * sizeof(T); - } - } - while(--num_spans); - - if(sl.num_spans()) - { - sl.finalize(y); - break; - } - } - return true; - } - - - //-------------------------------------------------------------------- - // Specialization for embedded_scanline - bool sweep_scanline(embedded_scanline& sl) - { - do - { - if(m_ptr >= m_end) return false; - - unsigned byte_size = read_int32u(); - sl.init(m_ptr, m_dx, m_dy); - m_ptr += byte_size - sizeof(int32); - } - while(sl.num_spans() == 0); - return true; - } - - private: - const int8u* m_data; - const int8u* m_end; - const int8u* m_ptr; - int m_dx; - int m_dy; - int m_min_x; - int m_min_y; - int m_max_x; - int m_max_y; - }; - - - - typedef serialized_scanlines_adaptor_aa serialized_scanlines_adaptor_aa8; //----serialized_scanlines_adaptor_aa8 - typedef serialized_scanlines_adaptor_aa serialized_scanlines_adaptor_aa16; //----serialized_scanlines_adaptor_aa16 - typedef serialized_scanlines_adaptor_aa serialized_scanlines_adaptor_aa32; //----serialized_scanlines_adaptor_aa32 - -} - - -#endif - diff --git a/desmume/src/windows/agg/include/agg_scanline_storage_bin.h b/desmume/src/windows/agg/include/agg_scanline_storage_bin.h deleted file mode 100644 index bdbbfa47e..000000000 --- a/desmume/src/windows/agg/include/agg_scanline_storage_bin.h +++ /dev/null @@ -1,595 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- -// -// Adaptation for 32-bit screen coordinates has been sponsored by -// Liberty Technology Systems, Inc., visit http://lib-sys.com -// -// Liberty Technology Systems, Inc. is the provider of -// PostScript and PDF technology for software developers. -// -//---------------------------------------------------------------------------- - - -#ifndef AGG_SCANLINE_STORAGE_BIN_INCLUDED -#define AGG_SCANLINE_STORAGE_BIN_INCLUDED - -#include -#include -#include -#include "agg_array.h" - - -namespace agg -{ - - //-----------------------------------------------scanline_storage_bin - class scanline_storage_bin - { - public: - //--------------------------------------------------------------- - struct span_data - { - int32 x; - int32 len; - }; - - //--------------------------------------------------------------- - struct scanline_data - { - int y; - unsigned num_spans; - unsigned start_span; - }; - - - //--------------------------------------------------------------- - class embedded_scanline - { - public: - - //----------------------------------------------------------- - class const_iterator - { - public: - const_iterator() : m_storage(0) {} - const_iterator(const embedded_scanline& sl) : - m_storage(sl.m_storage), - m_span_idx(sl.m_scanline.start_span) - { - m_span = m_storage->span_by_index(m_span_idx); - } - - const span_data& operator*() const { return m_span; } - const span_data* operator->() const { return &m_span; } - - void operator ++ () - { - ++m_span_idx; - m_span = m_storage->span_by_index(m_span_idx); - } - - private: - const scanline_storage_bin* m_storage; - unsigned m_span_idx; - span_data m_span; - }; - - friend class const_iterator; - - - //----------------------------------------------------------- - embedded_scanline(const scanline_storage_bin& storage) : - m_storage(&storage) - { - setup(0); - } - - //----------------------------------------------------------- - void reset(int, int) {} - unsigned num_spans() const { return m_scanline.num_spans; } - int y() const { return m_scanline.y; } - const_iterator begin() const { return const_iterator(*this); } - - //----------------------------------------------------------- - void setup(unsigned scanline_idx) - { - m_scanline_idx = scanline_idx; - m_scanline = m_storage->scanline_by_index(m_scanline_idx); - } - - private: - const scanline_storage_bin* m_storage; - scanline_data m_scanline; - unsigned m_scanline_idx; - }; - - - //--------------------------------------------------------------- - scanline_storage_bin() : - m_spans(256-2), // Block increment size - m_scanlines(), - m_min_x( 0x7FFFFFFF), - m_min_y( 0x7FFFFFFF), - m_max_x(-0x7FFFFFFF), - m_max_y(-0x7FFFFFFF), - m_cur_scanline(0) - { - m_fake_scanline.y = 0; - m_fake_scanline.num_spans = 0; - m_fake_scanline.start_span = 0; - m_fake_span.x = 0; - m_fake_span.len = 0; - } - - // Renderer Interface - //--------------------------------------------------------------- - void prepare() - { - m_scanlines.remove_all(); - m_spans.remove_all(); - m_min_x = 0x7FFFFFFF; - m_min_y = 0x7FFFFFFF; - m_max_x = -0x7FFFFFFF; - m_max_y = -0x7FFFFFFF; - m_cur_scanline = 0; - } - - //--------------------------------------------------------------- - template void render(const Scanline& sl) - { - scanline_data sl_this; - - int y = sl.y(); - if(y < m_min_y) m_min_y = y; - if(y > m_max_y) m_max_y = y; - - sl_this.y = y; - sl_this.num_spans = sl.num_spans(); - sl_this.start_span = m_spans.size(); - typename Scanline::const_iterator span_iterator = sl.begin(); - - unsigned num_spans = sl_this.num_spans; - for(;;) - { - span_data sp; - sp.x = span_iterator->x; - sp.len = (int32)abs((int)(span_iterator->len)); - m_spans.add(sp); - int x1 = sp.x; - int x2 = sp.x + sp.len - 1; - if(x1 < m_min_x) m_min_x = x1; - if(x2 > m_max_x) m_max_x = x2; - if(--num_spans == 0) break; - ++span_iterator; - } - m_scanlines.add(sl_this); - } - - - //--------------------------------------------------------------- - // Iterate scanlines interface - int min_x() const { return m_min_x; } - int min_y() const { return m_min_y; } - int max_x() const { return m_max_x; } - int max_y() const { return m_max_y; } - - //--------------------------------------------------------------- - bool rewind_scanlines() - { - m_cur_scanline = 0; - return m_scanlines.size() > 0; - } - - - //--------------------------------------------------------------- - template bool sweep_scanline(Scanline& sl) - { - sl.reset_spans(); - for(;;) - { - if(m_cur_scanline >= m_scanlines.size()) return false; - const scanline_data& sl_this = m_scanlines[m_cur_scanline]; - - unsigned num_spans = sl_this.num_spans; - unsigned span_idx = sl_this.start_span; - do - { - const span_data& sp = m_spans[span_idx++]; - sl.add_span(sp.x, sp.len, cover_full); - } - while(--num_spans); - - ++m_cur_scanline; - if(sl.num_spans()) - { - sl.finalize(sl_this.y); - break; - } - } - return true; - } - - - //--------------------------------------------------------------- - // Specialization for embedded_scanline - bool sweep_scanline(embedded_scanline& sl) - { - do - { - if(m_cur_scanline >= m_scanlines.size()) return false; - sl.setup(m_cur_scanline); - ++m_cur_scanline; - } - while(sl.num_spans() == 0); - return true; - } - - - //--------------------------------------------------------------- - unsigned byte_size() const - { - unsigned i; - unsigned size = sizeof(int32) * 4; // min_x, min_y, max_x, max_y - - for(i = 0; i < m_scanlines.size(); ++i) - { - size += sizeof(int32) * 2 + // Y, num_spans - unsigned(m_scanlines[i].num_spans) * sizeof(int32) * 2; // X, span_len - } - return size; - } - - - //--------------------------------------------------------------- - static void write_int32(int8u* dst, int32 val) - { - dst[0] = ((const int8u*)&val)[0]; - dst[1] = ((const int8u*)&val)[1]; - dst[2] = ((const int8u*)&val)[2]; - dst[3] = ((const int8u*)&val)[3]; - } - - - //--------------------------------------------------------------- - void serialize(int8u* data) const - { - unsigned i; - - write_int32(data, min_x()); // min_x - data += sizeof(int32); - write_int32(data, min_y()); // min_y - data += sizeof(int32); - write_int32(data, max_x()); // max_x - data += sizeof(int32); - write_int32(data, max_y()); // max_y - data += sizeof(int32); - - for(i = 0; i < m_scanlines.size(); ++i) - { - const scanline_data& sl_this = m_scanlines[i]; - - write_int32(data, sl_this.y); // Y - data += sizeof(int32); - - write_int32(data, sl_this.num_spans); // num_spans - data += sizeof(int32); - - unsigned num_spans = sl_this.num_spans; - unsigned span_idx = sl_this.start_span; - do - { - const span_data& sp = m_spans[span_idx++]; - - write_int32(data, sp.x); // X - data += sizeof(int32); - - write_int32(data, sp.len); // len - data += sizeof(int32); - } - while(--num_spans); - } - } - - - //--------------------------------------------------------------- - const scanline_data& scanline_by_index(unsigned i) const - { - return (i < m_scanlines.size()) ? m_scanlines[i] : m_fake_scanline; - } - - //--------------------------------------------------------------- - const span_data& span_by_index(unsigned i) const - { - return (i < m_spans.size()) ? m_spans[i] : m_fake_span; - } - - - private: - pod_bvector m_spans; - pod_bvector m_scanlines; - span_data m_fake_span; - scanline_data m_fake_scanline; - int m_min_x; - int m_min_y; - int m_max_x; - int m_max_y; - unsigned m_cur_scanline; - }; - - - - - - - - - - - - - - //---------------------------------------serialized_scanlines_adaptor_bin - class serialized_scanlines_adaptor_bin - { - public: - typedef bool cover_type; - - //-------------------------------------------------------------------- - class embedded_scanline - { - public: - - //---------------------------------------------------------------- - class const_iterator - { - public: - struct span - { - int32 x; - int32 len; - }; - - const_iterator() : m_ptr(0) {} - const_iterator(const embedded_scanline& sl) : - m_ptr(sl.m_ptr), - m_dx(sl.m_dx) - { - m_span.x = read_int32() + m_dx; - m_span.len = read_int32(); - } - - const span& operator*() const { return m_span; } - const span* operator->() const { return &m_span; } - - void operator ++ () - { - m_span.x = read_int32() + m_dx; - m_span.len = read_int32(); - } - - private: - int read_int32() - { - int32 val; - ((int8u*)&val)[0] = *m_ptr++; - ((int8u*)&val)[1] = *m_ptr++; - ((int8u*)&val)[2] = *m_ptr++; - ((int8u*)&val)[3] = *m_ptr++; - return val; - } - - const int8u* m_ptr; - span m_span; - int m_dx; - }; - - friend class const_iterator; - - - //---------------------------------------------------------------- - embedded_scanline() : m_ptr(0), m_y(0), m_num_spans(0) {} - - //---------------------------------------------------------------- - void reset(int, int) {} - unsigned num_spans() const { return m_num_spans; } - int y() const { return m_y; } - const_iterator begin() const { return const_iterator(*this); } - - - private: - //---------------------------------------------------------------- - int read_int32() - { - int32 val; - ((int8u*)&val)[0] = *m_ptr++; - ((int8u*)&val)[1] = *m_ptr++; - ((int8u*)&val)[2] = *m_ptr++; - ((int8u*)&val)[3] = *m_ptr++; - return val; - } - - public: - //---------------------------------------------------------------- - void init(const int8u* ptr, int dx, int dy) - { - m_ptr = ptr; - m_y = read_int32() + dy; - m_num_spans = unsigned(read_int32()); - m_dx = dx; - } - - private: - const int8u* m_ptr; - int m_y; - unsigned m_num_spans; - int m_dx; - }; - - - - public: - //-------------------------------------------------------------------- - serialized_scanlines_adaptor_bin() : - m_data(0), - m_end(0), - m_ptr(0), - m_dx(0), - m_dy(0), - m_min_x(0x7FFFFFFF), - m_min_y(0x7FFFFFFF), - m_max_x(-0x7FFFFFFF), - m_max_y(-0x7FFFFFFF) - {} - - //-------------------------------------------------------------------- - serialized_scanlines_adaptor_bin(const int8u* data, unsigned size, - double dx, double dy) : - m_data(data), - m_end(data + size), - m_ptr(data), - m_dx(iround(dx)), - m_dy(iround(dy)), - m_min_x(0x7FFFFFFF), - m_min_y(0x7FFFFFFF), - m_max_x(-0x7FFFFFFF), - m_max_y(-0x7FFFFFFF) - {} - - //-------------------------------------------------------------------- - void init(const int8u* data, unsigned size, double dx, double dy) - { - m_data = data; - m_end = data + size; - m_ptr = data; - m_dx = iround(dx); - m_dy = iround(dy); - m_min_x = 0x7FFFFFFF; - m_min_y = 0x7FFFFFFF; - m_max_x = -0x7FFFFFFF; - m_max_y = -0x7FFFFFFF; - } - - private: - //-------------------------------------------------------------------- - int read_int32() - { - int32 val; - ((int8u*)&val)[0] = *m_ptr++; - ((int8u*)&val)[1] = *m_ptr++; - ((int8u*)&val)[2] = *m_ptr++; - ((int8u*)&val)[3] = *m_ptr++; - return val; - } - - public: - // Iterate scanlines interface - //-------------------------------------------------------------------- - bool rewind_scanlines() - { - m_ptr = m_data; - if(m_ptr < m_end) - { - m_min_x = read_int32() + m_dx; - m_min_y = read_int32() + m_dy; - m_max_x = read_int32() + m_dx; - m_max_y = read_int32() + m_dy; - } - return m_ptr < m_end; - } - - //-------------------------------------------------------------------- - int min_x() const { return m_min_x; } - int min_y() const { return m_min_y; } - int max_x() const { return m_max_x; } - int max_y() const { return m_max_y; } - - //-------------------------------------------------------------------- - template bool sweep_scanline(Scanline& sl) - { - sl.reset_spans(); - for(;;) - { - if(m_ptr >= m_end) return false; - - int y = read_int32() + m_dy; - unsigned num_spans = read_int32(); - - do - { - int x = read_int32() + m_dx; - int len = read_int32(); - - if(len < 0) len = -len; - sl.add_span(x, unsigned(len), cover_full); - } - while(--num_spans); - - if(sl.num_spans()) - { - sl.finalize(y); - break; - } - } - return true; - } - - - //-------------------------------------------------------------------- - // Specialization for embedded_scanline - bool sweep_scanline(embedded_scanline& sl) - { - do - { - if(m_ptr >= m_end) return false; - - sl.init(m_ptr, m_dx, m_dy); - - // Jump to the next scanline - //-------------------------- - read_int32(); // Y - int num_spans = read_int32(); // num_spans - m_ptr += num_spans * sizeof(int32) * 2; - } - while(sl.num_spans() == 0); - return true; - } - - private: - const int8u* m_data; - const int8u* m_end; - const int8u* m_ptr; - int m_dx; - int m_dy; - int m_min_x; - int m_min_y; - int m_max_x; - int m_max_y; - }; - - - -} - -#endif - diff --git a/desmume/src/windows/agg/include/agg_scanline_u.h b/desmume/src/windows/agg/include/agg_scanline_u.h deleted file mode 100644 index c3443b5f2..000000000 --- a/desmume/src/windows/agg/include/agg_scanline_u.h +++ /dev/null @@ -1,508 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- -// -// Adaptation for 32-bit screen coordinates (scanline32_u) has been sponsored by -// Liberty Technology Systems, Inc., visit http://lib-sys.com -// -// Liberty Technology Systems, Inc. is the provider of -// PostScript and PDF technology for software developers. -// -//---------------------------------------------------------------------------- - -#ifndef AGG_SCANLINE_U_INCLUDED -#define AGG_SCANLINE_U_INCLUDED - -#include "agg_array.h" - -namespace agg -{ - //=============================================================scanline_u8 - // - // Unpacked scanline container class - // - // This class is used to transfer data from a scanline rasterizer - // to the rendering buffer. It's organized very simple. The class stores - // information of horizontal spans to render it into a pixel-map buffer. - // Each span has staring X, length, and an array of bytes that determine the - // cover-values for each pixel. - // Before using this class you should know the minimal and maximal pixel - // coordinates of your scanline. The protocol of using is: - // 1. reset(min_x, max_x) - // 2. add_cell() / add_span() - accumulate scanline. - // When forming one scanline the next X coordinate must be always greater - // than the last stored one, i.e. it works only with ordered coordinates. - // 3. Call finalize(y) and render the scanline. - // 3. Call reset_spans() to prepare for the new scanline. - // - // 4. Rendering: - // - // Scanline provides an iterator class that allows you to extract - // the spans and the cover values for each pixel. Be aware that clipping - // has not been done yet, so you should perform it yourself. - // Use scanline_u8::iterator to render spans: - //------------------------------------------------------------------------- - // - // int y = sl.y(); // Y-coordinate of the scanline - // - // ************************************ - // ...Perform vertical clipping here... - // ************************************ - // - // scanline_u8::const_iterator span = sl.begin(); - // - // unsigned char* row = m_rbuf->row(y); // The the address of the beginning - // // of the current row - // - // unsigned num_spans = sl.num_spans(); // Number of spans. It's guaranteed that - // // num_spans is always greater than 0. - // - // do - // { - // const scanline_u8::cover_type* covers = - // span->covers; // The array of the cover values - // - // int num_pix = span->len; // Number of pixels of the span. - // // Always greater than 0, still it's - // // better to use "int" instead of - // // "unsigned" because it's more - // // convenient for clipping - // int x = span->x; - // - // ************************************** - // ...Perform horizontal clipping here... - // ...you have x, covers, and pix_count.. - // ************************************** - // - // unsigned char* dst = row + x; // Calculate the start address of the row. - // // In this case we assume a simple - // // grayscale image 1-byte per pixel. - // do - // { - // *dst++ = *covers++; // Hypotetical rendering. - // } - // while(--num_pix); - // - // ++span; - // } - // while(--num_spans); // num_spans cannot be 0, so this loop is quite safe - //------------------------------------------------------------------------ - // - // The question is: why should we accumulate the whole scanline when we - // could render just separate spans when they're ready? - // That's because using the scanline is generally faster. When is consists - // of more than one span the conditions for the processor cash system - // are better, because switching between two different areas of memory - // (that can be very large) occurs less frequently. - //------------------------------------------------------------------------ - class scanline_u8 - { - public: - typedef scanline_u8 self_type; - typedef int8u cover_type; - typedef int16 coord_type; - - //-------------------------------------------------------------------- - struct span - { - coord_type x; - coord_type len; - cover_type* covers; - }; - - typedef span* iterator; - typedef const span* const_iterator; - - //-------------------------------------------------------------------- - scanline_u8() : - m_min_x(0), - m_last_x(0x7FFFFFF0), - m_cur_span(0) - {} - - //-------------------------------------------------------------------- - void reset(int min_x, int max_x) - { - unsigned max_len = max_x - min_x + 2; - if(max_len > m_spans.size()) - { - m_spans.resize(max_len); - m_covers.resize(max_len); - } - m_last_x = 0x7FFFFFF0; - m_min_x = min_x; - m_cur_span = &m_spans[0]; - } - - //-------------------------------------------------------------------- - void add_cell(int x, unsigned cover) - { - x -= m_min_x; - m_covers[x] = (cover_type)cover; - if(x == m_last_x+1) - { - m_cur_span->len++; - } - else - { - m_cur_span++; - m_cur_span->x = (coord_type)(x + m_min_x); - m_cur_span->len = 1; - m_cur_span->covers = &m_covers[x]; - } - m_last_x = x; - } - - //-------------------------------------------------------------------- - void add_cells(int x, unsigned len, const cover_type* covers) - { - x -= m_min_x; - memcpy(&m_covers[x], covers, len * sizeof(cover_type)); - if(x == m_last_x+1) - { - m_cur_span->len += (coord_type)len; - } - else - { - m_cur_span++; - m_cur_span->x = (coord_type)(x + m_min_x); - m_cur_span->len = (coord_type)len; - m_cur_span->covers = &m_covers[x]; - } - m_last_x = x + len - 1; - } - - //-------------------------------------------------------------------- - void add_span(int x, unsigned len, unsigned cover) - { - x -= m_min_x; - memset(&m_covers[x], cover, len); - if(x == m_last_x+1) - { - m_cur_span->len += (coord_type)len; - } - else - { - m_cur_span++; - m_cur_span->x = (coord_type)(x + m_min_x); - m_cur_span->len = (coord_type)len; - m_cur_span->covers = &m_covers[x]; - } - m_last_x = x + len - 1; - } - - //-------------------------------------------------------------------- - void finalize(int y) - { - m_y = y; - } - - //-------------------------------------------------------------------- - void reset_spans() - { - m_last_x = 0x7FFFFFF0; - m_cur_span = &m_spans[0]; - } - - //-------------------------------------------------------------------- - int y() const { return m_y; } - unsigned num_spans() const { return unsigned(m_cur_span - &m_spans[0]); } - const_iterator begin() const { return &m_spans[1]; } - iterator begin() { return &m_spans[1]; } - - private: - scanline_u8(const self_type&); - const self_type& operator = (const self_type&); - - private: - int m_min_x; - int m_last_x; - int m_y; - pod_array m_covers; - pod_array m_spans; - span* m_cur_span; - }; - - - - - //==========================================================scanline_u8_am - // - // The scanline container with alpha-masking - // - //------------------------------------------------------------------------ - template - class scanline_u8_am : public scanline_u8 - { - public: - typedef scanline_u8 base_type; - typedef AlphaMask alpha_mask_type; - typedef base_type::cover_type cover_type; - typedef base_type::coord_type coord_type; - - scanline_u8_am() : base_type(), m_alpha_mask(0) {} - scanline_u8_am(const AlphaMask& am) : base_type(), m_alpha_mask(&am) {} - - //-------------------------------------------------------------------- - void finalize(int span_y) - { - base_type::finalize(span_y); - if(m_alpha_mask) - { - typename base_type::iterator span = base_type::begin(); - unsigned count = base_type::num_spans(); - do - { - m_alpha_mask->combine_hspan(span->x, - base_type::y(), - span->covers, - span->len); - ++span; - } - while(--count); - } - } - - private: - const AlphaMask* m_alpha_mask; - }; - - - - - //===========================================================scanline32_u8 - class scanline32_u8 - { - public: - typedef scanline32_u8 self_type; - typedef int8u cover_type; - typedef int32 coord_type; - - //-------------------------------------------------------------------- - struct span - { - span() {} - span(coord_type x_, coord_type len_, cover_type* covers_) : - x(x_), len(len_), covers(covers_) {} - - coord_type x; - coord_type len; - cover_type* covers; - }; - - typedef pod_bvector span_array_type; - - //-------------------------------------------------------------------- - class const_iterator - { - public: - const_iterator(const span_array_type& spans) : - m_spans(spans), - m_span_idx(0) - {} - - const span& operator*() const { return m_spans[m_span_idx]; } - const span* operator->() const { return &m_spans[m_span_idx]; } - - void operator ++ () { ++m_span_idx; } - - private: - const span_array_type& m_spans; - unsigned m_span_idx; - }; - - //-------------------------------------------------------------------- - class iterator - { - public: - iterator(span_array_type& spans) : - m_spans(spans), - m_span_idx(0) - {} - - span& operator*() { return m_spans[m_span_idx]; } - span* operator->() { return &m_spans[m_span_idx]; } - - void operator ++ () { ++m_span_idx; } - - private: - span_array_type& m_spans; - unsigned m_span_idx; - }; - - - - //-------------------------------------------------------------------- - scanline32_u8() : - m_min_x(0), - m_last_x(0x7FFFFFF0), - m_covers() - {} - - //-------------------------------------------------------------------- - void reset(int min_x, int max_x) - { - unsigned max_len = max_x - min_x + 2; - if(max_len > m_covers.size()) - { - m_covers.resize(max_len); - } - m_last_x = 0x7FFFFFF0; - m_min_x = min_x; - m_spans.remove_all(); - } - - //-------------------------------------------------------------------- - void add_cell(int x, unsigned cover) - { - x -= m_min_x; - m_covers[x] = cover_type(cover); - if(x == m_last_x+1) - { - m_spans.last().len++; - } - else - { - m_spans.add(span(coord_type(x + m_min_x), 1, &m_covers[x])); - } - m_last_x = x; - } - - //-------------------------------------------------------------------- - void add_cells(int x, unsigned len, const cover_type* covers) - { - x -= m_min_x; - memcpy(&m_covers[x], covers, len * sizeof(cover_type)); - if(x == m_last_x+1) - { - m_spans.last().len += coord_type(len); - } - else - { - m_spans.add(span(coord_type(x + m_min_x), - coord_type(len), - &m_covers[x])); - } - m_last_x = x + len - 1; - } - - //-------------------------------------------------------------------- - void add_span(int x, unsigned len, unsigned cover) - { - x -= m_min_x; - memset(&m_covers[x], cover, len); - if(x == m_last_x+1) - { - m_spans.last().len += coord_type(len); - } - else - { - m_spans.add(span(coord_type(x + m_min_x), - coord_type(len), - &m_covers[x])); - } - m_last_x = x + len - 1; - } - - //-------------------------------------------------------------------- - void finalize(int y) - { - m_y = y; - } - - //-------------------------------------------------------------------- - void reset_spans() - { - m_last_x = 0x7FFFFFF0; - m_spans.remove_all(); - } - - //-------------------------------------------------------------------- - int y() const { return m_y; } - unsigned num_spans() const { return m_spans.size(); } - const_iterator begin() const { return const_iterator(m_spans); } - iterator begin() { return iterator(m_spans); } - - private: - scanline32_u8(const self_type&); - const self_type& operator = (const self_type&); - - private: - int m_min_x; - int m_last_x; - int m_y; - pod_array m_covers; - span_array_type m_spans; - }; - - - - - //========================================================scanline32_u8_am - // - // The scanline container with alpha-masking - // - //------------------------------------------------------------------------ - template - class scanline32_u8_am : public scanline32_u8 - { - public: - typedef scanline32_u8 base_type; - typedef AlphaMask alpha_mask_type; - typedef base_type::cover_type cover_type; - typedef base_type::coord_type coord_type; - - - scanline32_u8_am() : base_type(), m_alpha_mask(0) {} - scanline32_u8_am(const AlphaMask& am) : base_type(), m_alpha_mask(&am) {} - - //-------------------------------------------------------------------- - void finalize(int span_y) - { - base_type::finalize(span_y); - if(m_alpha_mask) - { - typename base_type::iterator span = base_type::begin(); - unsigned count = base_type::num_spans(); - do - { - m_alpha_mask->combine_hspan(span->x, - base_type::y(), - span->covers, - span->len); - ++span; - } - while(--count); - } - } - - private: - const AlphaMask* m_alpha_mask; - }; - - - -} - -#endif - diff --git a/desmume/src/windows/agg/include/agg_shorten_path.h b/desmume/src/windows/agg/include/agg_shorten_path.h deleted file mode 100644 index c914c42b7..000000000 --- a/desmume/src/windows/agg/include/agg_shorten_path.h +++ /dev/null @@ -1,75 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_SHORTEN_PATH_INCLUDED -#define AGG_SHORTEN_PATH_INCLUDED - -#include "agg_basics.h" -#include "agg_vertex_sequence.h" - -namespace agg -{ - - //===========================================================shorten_path - template - void shorten_path(VertexSequence& vs, double s, unsigned closed = 0) - { - typedef typename VertexSequence::value_type vertex_type; - - if(s > 0.0 && vs.size() > 1) - { - double d; - int n = int(vs.size() - 2); - while(n) - { - d = vs[n].dist; - if(d > s) break; - vs.remove_last(); - s -= d; - --n; - } - if(vs.size() < 2) - { - vs.remove_all(); - } - else - { - n = vs.size() - 1; - vertex_type& prev = vs[n-1]; - vertex_type& last = vs[n]; - d = (prev.dist - s) / prev.dist; - double x = prev.x + (last.x - prev.x) * d; - double y = prev.y + (last.y - prev.y) * d; - last.x = x; - last.y = y; - if(!prev(last)) vs.remove_last(); - vs.close(closed != 0); - } - } - } - - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_simul_eq.h b/desmume/src/windows/agg/include/agg_simul_eq.h deleted file mode 100644 index c45f5ca33..000000000 --- a/desmume/src/windows/agg/include/agg_simul_eq.h +++ /dev/null @@ -1,153 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_SIMUL_EQ_INCLUDED -#define AGG_SIMUL_EQ_INCLUDED - -#include -#include "agg_basics.h" - -namespace agg -{ - - //=============================================================swap_arrays - template void swap_arrays(T* a1, T* a2, unsigned n) - { - unsigned i; - for(i = 0; i < n; i++) - { - T tmp = *a1; - *a1++ = *a2; - *a2++ = tmp; - } - } - - - //============================================================matrix_pivot - template - struct matrix_pivot - { - static int pivot(double m[Rows][Cols], unsigned row) - { - int k = int(row); - double max_val, tmp; - - max_val = -1.0; - unsigned i; - for(i = row; i < Rows; i++) - { - if((tmp = fabs(m[i][row])) > max_val && tmp != 0.0) - { - max_val = tmp; - k = i; - } - } - - if(m[k][row] == 0.0) - { - return -1; - } - - if(k != int(row)) - { - swap_arrays(m[k], m[row], Cols); - return k; - } - return 0; - } - }; - - - - //===============================================================simul_eq - template - struct simul_eq - { - static bool solve(const double left[Size][Size], - const double right[Size][RightCols], - double result[Size][RightCols]) - { - unsigned i, j, k; - double a1; - - double tmp[Size][Size + RightCols]; - - for(i = 0; i < Size; i++) - { - for(j = 0; j < Size; j++) - { - tmp[i][j] = left[i][j]; - } - for(j = 0; j < RightCols; j++) - { - tmp[i][Size + j] = right[i][j]; - } - } - - for(k = 0; k < Size; k++) - { - if(matrix_pivot::pivot(tmp, k) < 0) - { - return false; // Singularity.... - } - - a1 = tmp[k][k]; - - for(j = k; j < Size + RightCols; j++) - { - tmp[k][j] /= a1; - } - - for(i = k + 1; i < Size; i++) - { - a1 = tmp[i][k]; - for (j = k; j < Size + RightCols; j++) - { - tmp[i][j] -= a1 * tmp[k][j]; - } - } - } - - - for(k = 0; k < RightCols; k++) - { - int m; - for(m = int(Size - 1); m >= 0; m--) - { - result[m][k] = tmp[m][Size + k]; - for(j = m + 1; j < Size; j++) - { - result[m][k] -= tmp[m][j] * result[j][k]; - } - } - } - return true; - } - - }; - - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_span_allocator.h b/desmume/src/windows/agg/include/agg_span_allocator.h deleted file mode 100644 index 6a9c3835a..000000000 --- a/desmume/src/windows/agg/include/agg_span_allocator.h +++ /dev/null @@ -1,63 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_SPAN_ALLOCATOR_INCLUDED -#define AGG_SPAN_ALLOCATOR_INCLUDED - -#include "agg_array.h" - -namespace agg -{ - //----------------------------------------------------------span_allocator - template class span_allocator - { - public: - typedef ColorT color_type; - - //-------------------------------------------------------------------- - AGG_INLINE color_type* allocate(unsigned span_len) - { - if(span_len > m_span.size()) - { - // To reduce the number of reallocs we align the - // span_len to 256 color elements. - // Well, I just like this number and it looks reasonable. - //----------------------- - m_span.resize(((span_len + 255) >> 8) << 8); - } - return &m_span[0]; - } - - AGG_INLINE color_type* span() { return &m_span[0]; } - AGG_INLINE unsigned max_span_len() const { return m_span.size(); } - - private: - pod_array m_span; - }; -} - - -#endif - - diff --git a/desmume/src/windows/agg/include/agg_span_converter.h b/desmume/src/windows/agg/include/agg_span_converter.h deleted file mode 100644 index 99f1a2398..000000000 --- a/desmume/src/windows/agg/include/agg_span_converter.h +++ /dev/null @@ -1,65 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_SPAN_CONVERTER_INCLUDED -#define AGG_SPAN_CONVERTER_INCLUDED - -#include "agg_basics.h" - -namespace agg -{ - //----------------------------------------------------------span_converter - template class span_converter - { - public: - typedef typename SpanGenerator::color_type color_type; - - span_converter(SpanGenerator& span_gen, SpanConverter& span_cnv) : - m_span_gen(&span_gen), m_span_cnv(&span_cnv) {} - - void attach_generator(SpanGenerator& span_gen) { m_span_gen = &span_gen; } - void attach_converter(SpanConverter& span_cnv) { m_span_cnv = &span_cnv; } - - //-------------------------------------------------------------------- - void prepare() - { - m_span_gen->prepare(); - m_span_cnv->prepare(); - } - - //-------------------------------------------------------------------- - void generate(color_type* span, int x, int y, unsigned len) - { - m_span_gen->generate(span, x, y, len); - m_span_cnv->generate(span, x, y, len); - } - - private: - SpanGenerator* m_span_gen; - SpanConverter* m_span_cnv; - }; - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_span_gouraud.h b/desmume/src/windows/agg/include/agg_span_gouraud.h deleted file mode 100644 index 9af2ab001..000000000 --- a/desmume/src/windows/agg/include/agg_span_gouraud.h +++ /dev/null @@ -1,181 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_SPAN_GOURAUD_INCLUDED -#define AGG_SPAN_GOURAUD_INCLUDED - -#include "agg_basics.h" -#include "agg_math.h" - -namespace agg -{ - - //============================================================span_gouraud - template class span_gouraud - { - public: - typedef ColorT color_type; - - struct coord_type - { - double x; - double y; - color_type color; - }; - - //-------------------------------------------------------------------- - span_gouraud() : - m_vertex(0) - { - m_cmd[0] = path_cmd_stop; - } - - //-------------------------------------------------------------------- - span_gouraud(const color_type& c1, - const color_type& c2, - const color_type& c3, - double x1, double y1, - double x2, double y2, - double x3, double y3, - double d) : - m_vertex(0) - { - colors(c1, c2, c3); - triangle(x1, y1, x2, y2, x3, y3, d); - } - - //-------------------------------------------------------------------- - void colors(ColorT c1, ColorT c2, ColorT c3) - { - m_coord[0].color = c1; - m_coord[1].color = c2; - m_coord[2].color = c3; - } - - //-------------------------------------------------------------------- - // Sets the triangle and dilates it if needed. - // The trick here is to calculate beveled joins in the vertices of the - // triangle and render it as a 6-vertex polygon. - // It's necessary to achieve numerical stability. - // However, the coordinates to interpolate colors are calculated - // as miter joins (calc_intersection). - void triangle(double x1, double y1, - double x2, double y2, - double x3, double y3, - double d) - { - m_coord[0].x = m_x[0] = x1; - m_coord[0].y = m_y[0] = y1; - m_coord[1].x = m_x[1] = x2; - m_coord[1].y = m_y[1] = y2; - m_coord[2].x = m_x[2] = x3; - m_coord[2].y = m_y[2] = y3; - m_cmd[0] = path_cmd_move_to; - m_cmd[1] = path_cmd_line_to; - m_cmd[2] = path_cmd_line_to; - m_cmd[3] = path_cmd_stop; - - if(d != 0.0) - { - dilate_triangle(m_coord[0].x, m_coord[0].y, - m_coord[1].x, m_coord[1].y, - m_coord[2].x, m_coord[2].y, - m_x, m_y, d); - - calc_intersection(m_x[4], m_y[4], m_x[5], m_y[5], - m_x[0], m_y[0], m_x[1], m_y[1], - &m_coord[0].x, &m_coord[0].y); - - calc_intersection(m_x[0], m_y[0], m_x[1], m_y[1], - m_x[2], m_y[2], m_x[3], m_y[3], - &m_coord[1].x, &m_coord[1].y); - - calc_intersection(m_x[2], m_y[2], m_x[3], m_y[3], - m_x[4], m_y[4], m_x[5], m_y[5], - &m_coord[2].x, &m_coord[2].y); - m_cmd[3] = path_cmd_line_to; - m_cmd[4] = path_cmd_line_to; - m_cmd[5] = path_cmd_line_to; - m_cmd[6] = path_cmd_stop; - } - } - - //-------------------------------------------------------------------- - // Vertex Source Interface to feed the coordinates to the rasterizer - void rewind(unsigned) - { - m_vertex = 0; - } - - //-------------------------------------------------------------------- - unsigned vertex(double* x, double* y) - { - *x = m_x[m_vertex]; - *y = m_y[m_vertex]; - return m_cmd[m_vertex++]; - } - - protected: - //-------------------------------------------------------------------- - void arrange_vertices(coord_type* coord) const - { - coord[0] = m_coord[0]; - coord[1] = m_coord[1]; - coord[2] = m_coord[2]; - - if(m_coord[0].y > m_coord[2].y) - { - coord[0] = m_coord[2]; - coord[2] = m_coord[0]; - } - - coord_type tmp; - if(coord[0].y > coord[1].y) - { - tmp = coord[1]; - coord[1] = coord[0]; - coord[0] = tmp; - } - - if(coord[1].y > coord[2].y) - { - tmp = coord[2]; - coord[2] = coord[1]; - coord[1] = tmp; - } - } - - private: - //-------------------------------------------------------------------- - coord_type m_coord[3]; - double m_x[8]; - double m_y[8]; - unsigned m_cmd[8]; - unsigned m_vertex; - }; - -} - -#endif - diff --git a/desmume/src/windows/agg/include/agg_span_gouraud_gray.h b/desmume/src/windows/agg/include/agg_span_gouraud_gray.h deleted file mode 100644 index 46a446ce0..000000000 --- a/desmume/src/windows/agg/include/agg_span_gouraud_gray.h +++ /dev/null @@ -1,250 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- -// -// Adaptation for high precision colors has been sponsored by -// Liberty Technology Systems, Inc., visit http://lib-sys.com -// -// Liberty Technology Systems, Inc. is the provider of -// PostScript and PDF technology for software developers. -// -//---------------------------------------------------------------------------- - -#ifndef AGG_SPAN_GOURAUD_GRAY_INCLUDED -#define AGG_SPAN_GOURAUD_GRAY_INCLUDED - -#include "agg_basics.h" -#include "agg_color_gray.h" -#include "agg_dda_line.h" -#include "agg_span_gouraud.h" - -namespace agg -{ - - //=======================================================span_gouraud_gray - template class span_gouraud_gray : public span_gouraud - { - public: - typedef ColorT color_type; - typedef typename color_type::value_type value_type; - typedef span_gouraud base_type; - typedef typename base_type::coord_type coord_type; - enum subpixel_scale_e - { - subpixel_shift = 4, - subpixel_scale = 1 << subpixel_shift - }; - - private: - //-------------------------------------------------------------------- - struct gray_calc - { - void init(const coord_type& c1, const coord_type& c2) - { - m_x1 = c1.x - 0.5; - m_y1 = c1.y - 0.5; - m_dx = c2.x - c1.x; - double dy = c2.y - c1.y; - m_1dy = (fabs(dy) < 1e-10) ? 1e10 : 1.0 / dy; - m_v1 = c1.color.v; - m_a1 = c1.color.a; - m_dv = c2.color.v - m_v1; - m_da = c2.color.a - m_a1; - } - - void calc(double y) - { - double k = (y - m_y1) * m_1dy; - if(k < 0.0) k = 0.0; - if(k > 1.0) k = 1.0; - m_v = m_v1 + iround(m_dv * k); - m_a = m_a1 + iround(m_da * k); - m_x = iround((m_x1 + m_dx * k) * subpixel_scale); - } - - double m_x1; - double m_y1; - double m_dx; - double m_1dy; - int m_v1; - int m_a1; - int m_dv; - int m_da; - int m_v; - int m_a; - int m_x; - }; - - - public: - //-------------------------------------------------------------------- - span_gouraud_gray() {} - span_gouraud_gray(const color_type& c1, - const color_type& c2, - const color_type& c3, - double x1, double y1, - double x2, double y2, - double x3, double y3, - double d = 0) : - base_type(c1, c2, c3, x1, y1, x2, y2, x3, y3, d) - {} - - //-------------------------------------------------------------------- - void prepare() - { - coord_type coord[3]; - base_type::arrange_vertices(coord); - - m_y2 = int(coord[1].y); - - m_swap = cross_product(coord[0].x, coord[0].y, - coord[2].x, coord[2].y, - coord[1].x, coord[1].y) < 0.0; - - m_c1.init(coord[0], coord[2]); - m_c2.init(coord[0], coord[1]); - m_c3.init(coord[1], coord[2]); - } - - //-------------------------------------------------------------------- - void generate(color_type* span, int x, int y, unsigned len) - { - m_c1.calc(y); - const gray_calc* pc1 = &m_c1; - const gray_calc* pc2 = &m_c2; - - if(y < m_y2) - { - // Bottom part of the triangle (first subtriangle) - //------------------------- - m_c2.calc(y + m_c2.m_1dy); - } - else - { - // Upper part (second subtriangle) - //------------------------- - m_c3.calc(y - m_c3.m_1dy); - pc2 = &m_c3; - } - - if(m_swap) - { - // It means that the triangle is oriented clockwise, - // so that we need to swap the controlling structures - //------------------------- - const gray_calc* t = pc2; - pc2 = pc1; - pc1 = t; - } - - // Get the horizontal length with subpixel accuracy - // and protect it from division by zero - //------------------------- - int nlen = abs(pc2->m_x - pc1->m_x); - if(nlen <= 0) nlen = 1; - - dda_line_interpolator<14> v(pc1->m_v, pc2->m_v, nlen); - dda_line_interpolator<14> a(pc1->m_a, pc2->m_a, nlen); - - // Calculate the starting point of the gradient with subpixel - // accuracy and correct (roll back) the interpolators. - // This operation will also clip the beginning of the span - // if necessary. - //------------------------- - int start = pc1->m_x - (x << subpixel_shift); - v -= start; - a -= start; - nlen += start; - - int vv, va; - enum lim_e { lim = color_type::base_mask }; - - // Beginning part of the span. Since we rolled back the - // interpolators, the color values may have overflow. - // So that, we render the beginning part with checking - // for overflow. It lasts until "start" is positive; - // typically it's 1-2 pixels, but may be more in some cases. - //------------------------- - while(len && start > 0) - { - vv = v.y(); - va = a.y(); - if(vv < 0) vv = 0; if(vv > lim) vv = lim; - if(va < 0) va = 0; if(va > lim) va = lim; - span->v = (value_type)vv; - span->a = (value_type)va; - v += subpixel_scale; - a += subpixel_scale; - nlen -= subpixel_scale; - start -= subpixel_scale; - ++span; - --len; - } - - // Middle part, no checking for overflow. - // Actual spans can be longer than the calculated length - // because of anti-aliasing, thus, the interpolators can - // overflow. But while "nlen" is positive we are safe. - //------------------------- - while(len && nlen > 0) - { - span->v = (value_type)v.y(); - span->a = (value_type)a.y(); - v += subpixel_scale; - a += subpixel_scale; - nlen -= subpixel_scale; - ++span; - --len; - } - - // Ending part; checking for overflow. - // Typically it's 1-2 pixels, but may be more in some cases. - //------------------------- - while(len) - { - vv = v.y(); - va = a.y(); - if(vv < 0) vv = 0; if(vv > lim) vv = lim; - if(va < 0) va = 0; if(va > lim) va = lim; - span->v = (value_type)vv; - span->a = (value_type)va; - v += subpixel_scale; - a += subpixel_scale; - ++span; - --len; - } - } - - - private: - bool m_swap; - int m_y2; - gray_calc m_c1; - gray_calc m_c2; - gray_calc m_c3; - }; - - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_span_gouraud_rgba.h b/desmume/src/windows/agg/include/agg_span_gouraud_rgba.h deleted file mode 100644 index a379ddd95..000000000 --- a/desmume/src/windows/agg/include/agg_span_gouraud_rgba.h +++ /dev/null @@ -1,286 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- -// -// Adaptation for high precision colors has been sponsored by -// Liberty Technology Systems, Inc., visit http://lib-sys.com -// -// Liberty Technology Systems, Inc. is the provider of -// PostScript and PDF technology for software developers. -// -//---------------------------------------------------------------------------- - -#ifndef AGG_SPAN_GOURAUD_RGBA_INCLUDED -#define AGG_SPAN_GOURAUD_RGBA_INCLUDED - -#include "agg_basics.h" -#include "agg_color_rgba.h" -#include "agg_dda_line.h" -#include "agg_span_gouraud.h" - -namespace agg -{ - - //=======================================================span_gouraud_rgba - template class span_gouraud_rgba : public span_gouraud - { - public: - typedef ColorT color_type; - typedef typename ColorT::value_type value_type; - typedef span_gouraud base_type; - typedef typename base_type::coord_type coord_type; - enum subpixel_scale_e - { - subpixel_shift = 4, - subpixel_scale = 1 << subpixel_shift - }; - - private: - //-------------------------------------------------------------------- - struct rgba_calc - { - void init(const coord_type& c1, const coord_type& c2) - { - m_x1 = c1.x - 0.5; - m_y1 = c1.y - 0.5; - m_dx = c2.x - c1.x; - double dy = c2.y - c1.y; - m_1dy = (dy < 1e-5) ? 1e5 : 1.0 / dy; - m_r1 = c1.color.r; - m_g1 = c1.color.g; - m_b1 = c1.color.b; - m_a1 = c1.color.a; - m_dr = c2.color.r - m_r1; - m_dg = c2.color.g - m_g1; - m_db = c2.color.b - m_b1; - m_da = c2.color.a - m_a1; - } - - void calc(double y) - { - double k = (y - m_y1) * m_1dy; - if(k < 0.0) k = 0.0; - if(k > 1.0) k = 1.0; - m_r = m_r1 + iround(m_dr * k); - m_g = m_g1 + iround(m_dg * k); - m_b = m_b1 + iround(m_db * k); - m_a = m_a1 + iround(m_da * k); - m_x = iround((m_x1 + m_dx * k) * subpixel_scale); - } - - double m_x1; - double m_y1; - double m_dx; - double m_1dy; - int m_r1; - int m_g1; - int m_b1; - int m_a1; - int m_dr; - int m_dg; - int m_db; - int m_da; - int m_r; - int m_g; - int m_b; - int m_a; - int m_x; - }; - - public: - - //-------------------------------------------------------------------- - span_gouraud_rgba() {} - span_gouraud_rgba(const color_type& c1, - const color_type& c2, - const color_type& c3, - double x1, double y1, - double x2, double y2, - double x3, double y3, - double d = 0) : - base_type(c1, c2, c3, x1, y1, x2, y2, x3, y3, d) - {} - - //-------------------------------------------------------------------- - void prepare() - { - coord_type coord[3]; - base_type::arrange_vertices(coord); - - m_y2 = int(coord[1].y); - - m_swap = cross_product(coord[0].x, coord[0].y, - coord[2].x, coord[2].y, - coord[1].x, coord[1].y) < 0.0; - - m_rgba1.init(coord[0], coord[2]); - m_rgba2.init(coord[0], coord[1]); - m_rgba3.init(coord[1], coord[2]); - } - - //-------------------------------------------------------------------- - void generate(color_type* span, int x, int y, unsigned len) - { - m_rgba1.calc(y);//(m_rgba1.m_1dy > 2) ? m_rgba1.m_y1 : y); - const rgba_calc* pc1 = &m_rgba1; - const rgba_calc* pc2 = &m_rgba2; - - if(y <= m_y2) - { - // Bottom part of the triangle (first subtriangle) - //------------------------- - m_rgba2.calc(y + m_rgba2.m_1dy); - } - else - { - // Upper part (second subtriangle) - m_rgba3.calc(y - m_rgba3.m_1dy); - //------------------------- - pc2 = &m_rgba3; - } - - if(m_swap) - { - // It means that the triangle is oriented clockwise, - // so that we need to swap the controlling structures - //------------------------- - const rgba_calc* t = pc2; - pc2 = pc1; - pc1 = t; - } - - // Get the horizontal length with subpixel accuracy - // and protect it from division by zero - //------------------------- - int nlen = abs(pc2->m_x - pc1->m_x); - if(nlen <= 0) nlen = 1; - - dda_line_interpolator<14> r(pc1->m_r, pc2->m_r, nlen); - dda_line_interpolator<14> g(pc1->m_g, pc2->m_g, nlen); - dda_line_interpolator<14> b(pc1->m_b, pc2->m_b, nlen); - dda_line_interpolator<14> a(pc1->m_a, pc2->m_a, nlen); - - // Calculate the starting point of the gradient with subpixel - // accuracy and correct (roll back) the interpolators. - // This operation will also clip the beginning of the span - // if necessary. - //------------------------- - int start = pc1->m_x - (x << subpixel_shift); - r -= start; - g -= start; - b -= start; - a -= start; - nlen += start; - - int vr, vg, vb, va; - enum lim_e { lim = color_type::base_mask }; - - // Beginning part of the span. Since we rolled back the - // interpolators, the color values may have overflow. - // So that, we render the beginning part with checking - // for overflow. It lasts until "start" is positive; - // typically it's 1-2 pixels, but may be more in some cases. - //------------------------- - while(len && start > 0) - { - vr = r.y(); - vg = g.y(); - vb = b.y(); - va = a.y(); - if(vr < 0) vr = 0; if(vr > lim) vr = lim; - if(vg < 0) vg = 0; if(vg > lim) vg = lim; - if(vb < 0) vb = 0; if(vb > lim) vb = lim; - if(va < 0) va = 0; if(va > lim) va = lim; - span->r = (value_type)vr; - span->g = (value_type)vg; - span->b = (value_type)vb; - span->a = (value_type)va; - r += subpixel_scale; - g += subpixel_scale; - b += subpixel_scale; - a += subpixel_scale; - nlen -= subpixel_scale; - start -= subpixel_scale; - ++span; - --len; - } - - // Middle part, no checking for overflow. - // Actual spans can be longer than the calculated length - // because of anti-aliasing, thus, the interpolators can - // overflow. But while "nlen" is positive we are safe. - //------------------------- - while(len && nlen > 0) - { - span->r = (value_type)r.y(); - span->g = (value_type)g.y(); - span->b = (value_type)b.y(); - span->a = (value_type)a.y(); - r += subpixel_scale; - g += subpixel_scale; - b += subpixel_scale; - a += subpixel_scale; - nlen -= subpixel_scale; - ++span; - --len; - } - - // Ending part; checking for overflow. - // Typically it's 1-2 pixels, but may be more in some cases. - //------------------------- - while(len) - { - vr = r.y(); - vg = g.y(); - vb = b.y(); - va = a.y(); - if(vr < 0) vr = 0; if(vr > lim) vr = lim; - if(vg < 0) vg = 0; if(vg > lim) vg = lim; - if(vb < 0) vb = 0; if(vb > lim) vb = lim; - if(va < 0) va = 0; if(va > lim) va = lim; - span->r = (value_type)vr; - span->g = (value_type)vg; - span->b = (value_type)vb; - span->a = (value_type)va; - r += subpixel_scale; - g += subpixel_scale; - b += subpixel_scale; - a += subpixel_scale; - ++span; - --len; - } - } - - private: - bool m_swap; - int m_y2; - rgba_calc m_rgba1; - rgba_calc m_rgba2; - rgba_calc m_rgba3; - }; - - - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_span_gradient.h b/desmume/src/windows/agg/include/agg_span_gradient.h deleted file mode 100644 index 382d1d979..000000000 --- a/desmume/src/windows/agg/include/agg_span_gradient.h +++ /dev/null @@ -1,373 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_SPAN_GRADIENT_INCLUDED -#define AGG_SPAN_GRADIENT_INCLUDED - -#include -#include -#include -#include "agg_basics.h" -#include "agg_math.h" -#include "agg_array.h" - - -namespace agg -{ - - enum gradient_subpixel_scale_e - { - gradient_subpixel_shift = 4, //-----gradient_subpixel_shift - gradient_subpixel_scale = 1 << gradient_subpixel_shift, //-----gradient_subpixel_scale - gradient_subpixel_mask = gradient_subpixel_scale - 1 //-----gradient_subpixel_mask - }; - - - - //==========================================================span_gradient - template - class span_gradient - { - public: - typedef Interpolator interpolator_type; - typedef ColorT color_type; - - enum downscale_shift_e - { - downscale_shift = interpolator_type::subpixel_shift - - gradient_subpixel_shift - }; - - //-------------------------------------------------------------------- - span_gradient() {} - - //-------------------------------------------------------------------- - span_gradient(interpolator_type& inter, - const GradientF& gradient_function, - const ColorF& color_function, - double d1, double d2) : - m_interpolator(&inter), - m_gradient_function(&gradient_function), - m_color_function(&color_function), - m_d1(iround(d1 * gradient_subpixel_scale)), - m_d2(iround(d2 * gradient_subpixel_scale)) - {} - - //-------------------------------------------------------------------- - interpolator_type& interpolator() { return *m_interpolator; } - const GradientF& gradient_function() const { return *m_gradient_function; } - const ColorF& color_function() const { return *m_color_function; } - double d1() const { return double(m_d1) / gradient_subpixel_scale; } - double d2() const { return double(m_d2) / gradient_subpixel_scale; } - - //-------------------------------------------------------------------- - void interpolator(interpolator_type& i) { m_interpolator = &i; } - void gradient_function(const GradientF& gf) { m_gradient_function = &gf; } - void color_function(const ColorF& cf) { m_color_function = &cf; } - void d1(double v) { m_d1 = iround(v * gradient_subpixel_scale); } - void d2(double v) { m_d2 = iround(v * gradient_subpixel_scale); } - - //-------------------------------------------------------------------- - void prepare() {} - - //-------------------------------------------------------------------- - void generate(color_type* span, int x, int y, unsigned len) - { - int dd = m_d2 - m_d1; - if(dd < 1) dd = 1; - m_interpolator->begin(x+0.5, y+0.5, len); - do - { - m_interpolator->coordinates(&x, &y); - int d = m_gradient_function->calculate(x >> downscale_shift, - y >> downscale_shift, m_d2); - d = ((d - m_d1) * (int)m_color_function->size()) / dd; - if(d < 0) d = 0; - if(d >= (int)m_color_function->size()) d = m_color_function->size() - 1; - *span++ = (*m_color_function)[d]; - ++(*m_interpolator); - } - while(--len); - } - - private: - interpolator_type* m_interpolator; - const GradientF* m_gradient_function; - const ColorF* m_color_function; - int m_d1; - int m_d2; - }; - - - - - //=====================================================gradient_linear_color - template - struct gradient_linear_color - { - typedef ColorT color_type; - - gradient_linear_color() {} - gradient_linear_color(const color_type& c1, const color_type& c2, - unsigned size = 256) : - m_c1(c1), m_c2(c2), m_size(size) {} - - unsigned size() const { return m_size; } - color_type operator [] (unsigned v) const - { - return m_c1.gradient(m_c2, double(v) / double(m_size - 1)); - } - - void colors(const color_type& c1, const color_type& c2, unsigned size = 256) - { - m_c1 = c1; - m_c2 = c2; - m_size = size; - } - - color_type m_c1; - color_type m_c2; - unsigned m_size; - }; - - - - - - - //==========================================================gradient_circle - class gradient_circle - { - // Actually the same as radial. Just for compatibility - public: - static AGG_INLINE int calculate(int x, int y, int) - { - return int(fast_sqrt(x*x + y*y)); - } - }; - - - //==========================================================gradient_radial - class gradient_radial - { - public: - static AGG_INLINE int calculate(int x, int y, int) - { - return int(fast_sqrt(x*x + y*y)); - } - }; - - //========================================================gradient_radial_d - class gradient_radial_d - { - public: - static AGG_INLINE int calculate(int x, int y, int) - { - return uround(sqrt(double(x)*double(x) + double(y)*double(y))); - } - }; - - //====================================================gradient_radial_focus - class gradient_radial_focus - { - public: - //--------------------------------------------------------------------- - gradient_radial_focus() : - m_r(100 * gradient_subpixel_scale), - m_fx(0), - m_fy(0) - { - update_values(); - } - - //--------------------------------------------------------------------- - gradient_radial_focus(double r, double fx, double fy) : - m_r (iround(r * gradient_subpixel_scale)), - m_fx(iround(fx * gradient_subpixel_scale)), - m_fy(iround(fy * gradient_subpixel_scale)) - { - update_values(); - } - - //--------------------------------------------------------------------- - void init(double r, double fx, double fy) - { - m_r = iround(r * gradient_subpixel_scale); - m_fx = iround(fx * gradient_subpixel_scale); - m_fy = iround(fy * gradient_subpixel_scale); - update_values(); - } - - //--------------------------------------------------------------------- - double radius() const { return double(m_r) / gradient_subpixel_scale; } - double focus_x() const { return double(m_fx) / gradient_subpixel_scale; } - double focus_y() const { return double(m_fy) / gradient_subpixel_scale; } - - //--------------------------------------------------------------------- - int calculate(int x, int y, int) const - { - double dx = x - m_fx; - double dy = y - m_fy; - double d2 = dx * m_fy - dy * m_fx; - double d3 = m_r2 * (dx * dx + dy * dy) - d2 * d2; - return iround((dx * m_fx + dy * m_fy + sqrt(fabs(d3))) * m_mul); - } - - private: - //--------------------------------------------------------------------- - void update_values() - { - // Calculate the invariant values. In case the focal center - // lies exactly on the gradient circle the divisor degenerates - // into zero. In this case we just move the focal center by - // one subpixel unit possibly in the direction to the origin (0,0) - // and calculate the values again. - //------------------------- - m_r2 = double(m_r) * double(m_r); - m_fx2 = double(m_fx) * double(m_fx); - m_fy2 = double(m_fy) * double(m_fy); - double d = (m_r2 - (m_fx2 + m_fy2)); - if(d == 0) - { - if(m_fx) { if(m_fx < 0) ++m_fx; else --m_fx; } - if(m_fy) { if(m_fy < 0) ++m_fy; else --m_fy; } - m_fx2 = double(m_fx) * double(m_fx); - m_fy2 = double(m_fy) * double(m_fy); - d = (m_r2 - (m_fx2 + m_fy2)); - } - m_mul = m_r / d; - } - - int m_r; - int m_fx; - int m_fy; - double m_r2; - double m_fx2; - double m_fy2; - double m_mul; - }; - - - //==============================================================gradient_x - class gradient_x - { - public: - static int calculate(int x, int, int) { return x; } - }; - - - //==============================================================gradient_y - class gradient_y - { - public: - static int calculate(int, int y, int) { return y; } - }; - - //========================================================gradient_diamond - class gradient_diamond - { - public: - static AGG_INLINE int calculate(int x, int y, int) - { - int ax = abs(x); - int ay = abs(y); - return ax > ay ? ax : ay; - } - }; - - //=============================================================gradient_xy - class gradient_xy - { - public: - static AGG_INLINE int calculate(int x, int y, int d) - { - return abs(x) * abs(y) / d; - } - }; - - //========================================================gradient_sqrt_xy - class gradient_sqrt_xy - { - public: - static AGG_INLINE int calculate(int x, int y, int) - { - return fast_sqrt(abs(x) * abs(y)); - } - }; - - //==========================================================gradient_conic - class gradient_conic - { - public: - static AGG_INLINE int calculate(int x, int y, int d) - { - return uround(fabs(atan2(double(y), double(x))) * double(d) / pi); - } - }; - - //=================================================gradient_repeat_adaptor - template class gradient_repeat_adaptor - { - public: - gradient_repeat_adaptor(const GradientF& gradient) : - m_gradient(&gradient) {} - - AGG_INLINE int calculate(int x, int y, int d) const - { - int ret = m_gradient->calculate(x, y, d) % d; - if(ret < 0) ret += d; - return ret; - } - - private: - const GradientF* m_gradient; - }; - - //================================================gradient_reflect_adaptor - template class gradient_reflect_adaptor - { - public: - gradient_reflect_adaptor(const GradientF& gradient) : - m_gradient(&gradient) {} - - AGG_INLINE int calculate(int x, int y, int d) const - { - int d2 = d << 1; - int ret = m_gradient->calculate(x, y, d) % d2; - if(ret < 0) ret += d2; - if(ret >= d) ret = d2 - ret; - return ret; - } - - private: - const GradientF* m_gradient; - }; - - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_span_gradient_alpha.h b/desmume/src/windows/agg/include/agg_span_gradient_alpha.h deleted file mode 100644 index 862957686..000000000 --- a/desmume/src/windows/agg/include/agg_span_gradient_alpha.h +++ /dev/null @@ -1,135 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_SPAN_GRADIENT_ALPHA_INCLUDED -#define AGG_SPAN_GRADIENT_ALPHA_INCLUDED - -#include "agg_span_gradient.h" - -namespace agg -{ - //======================================================span_gradient_alpha - template - class span_gradient_alpha - { - public: - typedef Interpolator interpolator_type; - typedef ColorT color_type; - typedef typename color_type::value_type alpha_type; - - enum downscale_shift_e - { - downscale_shift = interpolator_type::subpixel_shift - gradient_subpixel_shift - }; - - - //-------------------------------------------------------------------- - span_gradient_alpha() {} - - //-------------------------------------------------------------------- - span_gradient_alpha(interpolator_type& inter, - const GradientF& gradient_function, - const AlphaF& alpha_function, - double d1, double d2) : - m_interpolator(&inter), - m_gradient_function(&gradient_function), - m_alpha_function(&alpha_function), - m_d1(iround(d1 * gradient_subpixel_scale)), - m_d2(iround(d2 * gradient_subpixel_scale)) - {} - - //-------------------------------------------------------------------- - interpolator_type& interpolator() { return *m_interpolator; } - const GradientF& gradient_function() const { return *m_gradient_function; } - const AlphaF& alpha_function() const { return *m_alpha_function; } - double d1() const { return double(m_d1) / gradient_subpixel_scale; } - double d2() const { return double(m_d2) / gradient_subpixel_scale; } - - //-------------------------------------------------------------------- - void interpolator(interpolator_type& i) { m_interpolator = &i; } - void gradient_function(const GradientF& gf) { m_gradient_function = &gf; } - void alpha_function(const AlphaF& af) { m_alpha_function = ⁡ } - void d1(double v) { m_d1 = iround(v * gradient_subpixel_scale); } - void d2(double v) { m_d2 = iround(v * gradient_subpixel_scale); } - - //-------------------------------------------------------------------- - void prepare() {} - - //-------------------------------------------------------------------- - void generate(color_type* span, int x, int y, unsigned len) - { - int dd = m_d2 - m_d1; - if(dd < 1) dd = 1; - m_interpolator->begin(x+0.5, y+0.5, len); - do - { - m_interpolator->coordinates(&x, &y); - int d = m_gradient_function->calculate(x >> downscale_shift, - y >> downscale_shift, m_d2); - d = ((d - m_d1) * (int)m_alpha_function->size()) / dd; - if(d < 0) d = 0; - if(d >= (int)m_alpha_function->size()) d = m_alpha_function->size() - 1; - span->a = (*m_alpha_function)[d]; - ++span; - ++(*m_interpolator); - } - while(--len); - } - - private: - interpolator_type* m_interpolator; - const GradientF* m_gradient_function; - const AlphaF* m_alpha_function; - int m_d1; - int m_d2; - }; - - - //=======================================================gradient_alpha_x - template struct gradient_alpha_x - { - typedef typename ColorT::value_type alpha_type; - alpha_type operator [] (alpha_type x) const { return x; } - }; - - //====================================================gradient_alpha_x_u8 - struct gradient_alpha_x_u8 - { - typedef int8u alpha_type; - alpha_type operator [] (alpha_type x) const { return x; } - }; - - //==========================================gradient_alpha_one_munus_x_u8 - struct gradient_alpha_one_munus_x_u8 - { - typedef int8u alpha_type; - alpha_type operator [] (alpha_type x) const { return 255-x; } - }; - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_span_image_filter.h b/desmume/src/windows/agg/include/agg_span_image_filter.h deleted file mode 100644 index d0b1b9048..000000000 --- a/desmume/src/windows/agg/include/agg_span_image_filter.h +++ /dev/null @@ -1,252 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_SPAN_IMAGE_FILTER_INCLUDED -#define AGG_SPAN_IMAGE_FILTER_INCLUDED - -#include "agg_basics.h" -#include "agg_image_filters.h" -#include "agg_span_interpolator_linear.h" - -namespace agg -{ - - //-------------------------------------------------------span_image_filter - template class span_image_filter - { - public: - typedef Source source_type; - typedef Interpolator interpolator_type; - - //-------------------------------------------------------------------- - span_image_filter() {} - span_image_filter(source_type& src, - interpolator_type& interpolator, - const image_filter_lut* filter) : - m_src(&src), - m_interpolator(&interpolator), - m_filter(filter), - m_dx_dbl(0.5), - m_dy_dbl(0.5), - m_dx_int(image_subpixel_scale / 2), - m_dy_int(image_subpixel_scale / 2) - {} - void attach(source_type& v) { m_src = &v; } - - //-------------------------------------------------------------------- - source_type& source() { return *m_src; } - const source_type& source() const { return *m_src; } - const image_filter_lut& filter() const { return *m_filter; } - int filter_dx_int() const { return m_dx_int; } - int filter_dy_int() const { return m_dy_int; } - double filter_dx_dbl() const { return m_dx_dbl; } - double filter_dy_dbl() const { return m_dy_dbl; } - - //-------------------------------------------------------------------- - void interpolator(interpolator_type& v) { m_interpolator = &v; } - void filter(const image_filter_lut& v) { m_filter = &v; } - void filter_offset(double dx, double dy) - { - m_dx_dbl = dx; - m_dy_dbl = dy; - m_dx_int = iround(dx * image_subpixel_scale); - m_dy_int = iround(dy * image_subpixel_scale); - } - void filter_offset(double d) { filter_offset(d, d); } - - //-------------------------------------------------------------------- - interpolator_type& interpolator() { return *m_interpolator; } - - //-------------------------------------------------------------------- - void prepare() {} - - //-------------------------------------------------------------------- - private: - source_type* m_src; - interpolator_type* m_interpolator; - const image_filter_lut* m_filter; - double m_dx_dbl; - double m_dy_dbl; - unsigned m_dx_int; - unsigned m_dy_int; - }; - - - - - //==============================================span_image_resample_affine - template - class span_image_resample_affine : - public span_image_filter > - { - public: - typedef Source source_type; - typedef span_interpolator_linear interpolator_type; - typedef span_image_filter base_type; - - //-------------------------------------------------------------------- - span_image_resample_affine() : - m_scale_limit(200.0), - m_blur_x(1.0), - m_blur_y(1.0) - {} - - //-------------------------------------------------------------------- - span_image_resample_affine(source_type& src, - interpolator_type& inter, - const image_filter_lut& filter) : - base_type(src, inter, &filter), - m_scale_limit(200.0), - m_blur_x(1.0), - m_blur_y(1.0) - {} - - - //-------------------------------------------------------------------- - int scale_limit() const { return uround(m_scale_limit); } - void scale_limit(int v) { m_scale_limit = v; } - - //-------------------------------------------------------------------- - double blur_x() const { return m_blur_x; } - double blur_y() const { return m_blur_y; } - void blur_x(double v) { m_blur_x = v; } - void blur_y(double v) { m_blur_y = v; } - void blur(double v) { m_blur_x = m_blur_y = v; } - - //-------------------------------------------------------------------- - void prepare() - { - double scale_x; - double scale_y; - - base_type::interpolator().transformer().scaling_abs(&scale_x, &scale_y); - - if(scale_x * scale_y > m_scale_limit) - { - scale_x = scale_x * m_scale_limit / (scale_x * scale_y); - scale_y = scale_y * m_scale_limit / (scale_x * scale_y); - } - - if(scale_x < 1) scale_x = 1; - if(scale_y < 1) scale_y = 1; - - if(scale_x > m_scale_limit) scale_x = m_scale_limit; - if(scale_y > m_scale_limit) scale_y = m_scale_limit; - - scale_x *= m_blur_x; - scale_y *= m_blur_y; - - if(scale_x < 1) scale_x = 1; - if(scale_y < 1) scale_y = 1; - - m_rx = uround( scale_x * double(image_subpixel_scale)); - m_rx_inv = uround(1.0/scale_x * double(image_subpixel_scale)); - - m_ry = uround( scale_y * double(image_subpixel_scale)); - m_ry_inv = uround(1.0/scale_y * double(image_subpixel_scale)); - } - - protected: - int m_rx; - int m_ry; - int m_rx_inv; - int m_ry_inv; - - private: - double m_scale_limit; - double m_blur_x; - double m_blur_y; - }; - - - - //=====================================================span_image_resample - template - class span_image_resample : - public span_image_filter - { - public: - typedef Source source_type; - typedef Interpolator interpolator_type; - typedef span_image_filter base_type; - - //-------------------------------------------------------------------- - span_image_resample() : - m_scale_limit(20), - m_blur_x(image_subpixel_scale), - m_blur_y(image_subpixel_scale) - {} - - //-------------------------------------------------------------------- - span_image_resample(source_type& src, - interpolator_type& inter, - const image_filter_lut& filter) : - base_type(src, inter, &filter), - m_scale_limit(20), - m_blur_x(image_subpixel_scale), - m_blur_y(image_subpixel_scale) - {} - - //-------------------------------------------------------------------- - int scale_limit() const { return m_scale_limit; } - void scale_limit(int v) { m_scale_limit = v; } - - //-------------------------------------------------------------------- - double blur_x() const { return double(m_blur_x) / double(image_subpixel_scale); } - double blur_y() const { return double(m_blur_y) / double(image_subpixel_scale); } - void blur_x(double v) { m_blur_x = uround(v * double(image_subpixel_scale)); } - void blur_y(double v) { m_blur_y = uround(v * double(image_subpixel_scale)); } - void blur(double v) { m_blur_x = - m_blur_y = uround(v * double(image_subpixel_scale)); } - - protected: - AGG_INLINE void adjust_scale(int* rx, int* ry) - { - if(*rx < image_subpixel_scale) *rx = image_subpixel_scale; - if(*ry < image_subpixel_scale) *ry = image_subpixel_scale; - if(*rx > image_subpixel_scale * m_scale_limit) - { - *rx = image_subpixel_scale * m_scale_limit; - } - if(*ry > image_subpixel_scale * m_scale_limit) - { - *ry = image_subpixel_scale * m_scale_limit; - } - *rx = (*rx * m_blur_x) >> image_subpixel_shift; - *ry = (*ry * m_blur_y) >> image_subpixel_shift; - if(*rx < image_subpixel_scale) *rx = image_subpixel_scale; - if(*ry < image_subpixel_scale) *ry = image_subpixel_scale; - } - - int m_scale_limit; - int m_blur_x; - int m_blur_y; - }; - - - - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_span_image_filter_gray.h b/desmume/src/windows/agg/include/agg_span_image_filter_gray.h deleted file mode 100644 index e5293e1e3..000000000 --- a/desmume/src/windows/agg/include/agg_span_image_filter_gray.h +++ /dev/null @@ -1,757 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- -// -// Adaptation for high precision colors has been sponsored by -// Liberty Technology Systems, Inc., visit http://lib-sys.com -// -// Liberty Technology Systems, Inc. is the provider of -// PostScript and PDF technology for software developers. -// -//---------------------------------------------------------------------------- -#ifndef AGG_SPAN_IMAGE_FILTER_GRAY_INCLUDED -#define AGG_SPAN_IMAGE_FILTER_GRAY_INCLUDED - -#include "agg_basics.h" -#include "agg_color_gray.h" -#include "agg_span_image_filter.h" - - -namespace agg -{ - - //==============================================span_image_filter_gray_nn - template - class span_image_filter_gray_nn : - public span_image_filter - { - public: - typedef Source source_type; - typedef typename source_type::color_type color_type; - typedef Interpolator interpolator_type; - typedef span_image_filter base_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - //-------------------------------------------------------------------- - span_image_filter_gray_nn() {} - span_image_filter_gray_nn(source_type& src, - interpolator_type& inter) : - base_type(src, inter, 0) - {} - - //-------------------------------------------------------------------- - void generate(color_type* span, int x, int y, unsigned len) - { - base_type::interpolator().begin(x + base_type::filter_dx_dbl(), - y + base_type::filter_dy_dbl(), len); - do - { - base_type::interpolator().coordinates(&x, &y); - span->v = *(const value_type*) - base_type::source().span(x >> image_subpixel_shift, - y >> image_subpixel_shift, - 1); - span->a = base_mask; - ++span; - ++base_type::interpolator(); - } while(--len); - } - }; - - - - //=========================================span_image_filter_gray_bilinear - template - class span_image_filter_gray_bilinear : - public span_image_filter - { - public: - typedef Source source_type; - typedef typename source_type::color_type color_type; - typedef Interpolator interpolator_type; - typedef span_image_filter base_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - //-------------------------------------------------------------------- - span_image_filter_gray_bilinear() {} - span_image_filter_gray_bilinear(source_type& src, - interpolator_type& inter) : - base_type(src, inter, 0) - {} - - - //-------------------------------------------------------------------- - void generate(color_type* span, int x, int y, unsigned len) - { - base_type::interpolator().begin(x + base_type::filter_dx_dbl(), - y + base_type::filter_dy_dbl(), len); - calc_type fg; - const value_type *fg_ptr; - do - { - int x_hr; - int y_hr; - - base_type::interpolator().coordinates(&x_hr, &y_hr); - - x_hr -= base_type::filter_dx_int(); - y_hr -= base_type::filter_dy_int(); - - int x_lr = x_hr >> image_subpixel_shift; - int y_lr = y_hr >> image_subpixel_shift; - - fg = image_subpixel_scale * image_subpixel_scale / 2; - - x_hr &= image_subpixel_mask; - y_hr &= image_subpixel_mask; - - fg_ptr = (const value_type*)base_type::source().span(x_lr, y_lr, 2); - fg += *fg_ptr * (image_subpixel_scale - x_hr) * (image_subpixel_scale - y_hr); - - fg_ptr = (const value_type*)base_type::source().next_x(); - fg += *fg_ptr * x_hr * (image_subpixel_scale - y_hr); - - fg_ptr = (const value_type*)base_type::source().next_y(); - fg += *fg_ptr * (image_subpixel_scale - x_hr) * y_hr; - - fg_ptr = (const value_type*)base_type::source().next_x(); - fg += *fg_ptr * x_hr * y_hr; - - span->v = value_type(fg >> (image_subpixel_shift * 2)); - span->a = base_mask; - ++span; - ++base_type::interpolator(); - - } while(--len); - } - }; - - - //====================================span_image_filter_gray_bilinear_clip - template - class span_image_filter_gray_bilinear_clip : - public span_image_filter - { - public: - typedef Source source_type; - typedef typename source_type::color_type color_type; - typedef Interpolator interpolator_type; - typedef span_image_filter base_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - //-------------------------------------------------------------------- - span_image_filter_gray_bilinear_clip() {} - span_image_filter_gray_bilinear_clip(source_type& src, - const color_type& back_color, - interpolator_type& inter) : - base_type(src, inter, 0), - m_back_color(back_color) - {} - const color_type& background_color() const { return m_back_color; } - void background_color(const color_type& v) { m_back_color = v; } - - //-------------------------------------------------------------------- - void generate(color_type* span, int x, int y, unsigned len) - { - base_type::interpolator().begin(x + base_type::filter_dx_dbl(), - y + base_type::filter_dy_dbl(), len); - calc_type fg; - calc_type src_alpha; - value_type back_v = m_back_color.v; - value_type back_a = m_back_color.a; - - const value_type *fg_ptr; - - int maxx = base_type::source().width() - 1; - int maxy = base_type::source().height() - 1; - - do - { - int x_hr; - int y_hr; - - base_type::interpolator().coordinates(&x_hr, &y_hr); - - x_hr -= base_type::filter_dx_int(); - y_hr -= base_type::filter_dy_int(); - - int x_lr = x_hr >> image_subpixel_shift; - int y_lr = y_hr >> image_subpixel_shift; - - if(x_lr >= 0 && y_lr >= 0 && - x_lr < maxx && y_lr < maxy) - { - fg = image_subpixel_scale * image_subpixel_scale / 2; - - x_hr &= image_subpixel_mask; - y_hr &= image_subpixel_mask; - fg_ptr = (const value_type*)base_type::source().row_ptr(y_lr) + x_lr; - - fg += *fg_ptr++ * (image_subpixel_scale - x_hr) * (image_subpixel_scale - y_hr); - fg += *fg_ptr++ * (image_subpixel_scale - y_hr) * x_hr; - - ++y_lr; - fg_ptr = (const value_type*)base_type::source().row_ptr(y_lr) + x_lr; - - fg += *fg_ptr++ * (image_subpixel_scale - x_hr) * y_hr; - fg += *fg_ptr++ * x_hr * y_hr; - - fg >>= image_subpixel_shift * 2; - src_alpha = base_mask; - } - else - { - unsigned weight; - if(x_lr < -1 || y_lr < -1 || - x_lr > maxx || y_lr > maxy) - { - fg = back_v; - src_alpha = back_a; - } - else - { - fg = - src_alpha = image_subpixel_scale * image_subpixel_scale / 2; - - x_hr &= image_subpixel_mask; - y_hr &= image_subpixel_mask; - - weight = (image_subpixel_scale - x_hr) * - (image_subpixel_scale - y_hr); - if(x_lr >= 0 && y_lr >= 0 && - x_lr <= maxx && y_lr <= maxy) - { - fg += weight * - *((const value_type*)base_type::source().row_ptr(y_lr) + x_lr); - src_alpha += weight * base_mask; - } - else - { - fg += back_v * weight; - src_alpha += back_a * weight; - } - - x_lr++; - - weight = x_hr * (image_subpixel_scale - y_hr); - if(x_lr >= 0 && y_lr >= 0 && - x_lr <= maxx && y_lr <= maxy) - { - fg += weight * - *((const value_type*)base_type::source().row_ptr(y_lr) + x_lr); - src_alpha += weight * base_mask; - } - else - { - fg += back_v * weight; - src_alpha += back_a * weight; - } - - x_lr--; - y_lr++; - - weight = (image_subpixel_scale - x_hr) * y_hr; - if(x_lr >= 0 && y_lr >= 0 && - x_lr <= maxx && y_lr <= maxy) - { - fg += weight * - *((const value_type*)base_type::source().row_ptr(y_lr) + x_lr); - src_alpha += weight * base_mask; - } - else - { - fg += back_v * weight; - src_alpha += back_a * weight; - } - - x_lr++; - - weight = x_hr * y_hr; - if(x_lr >= 0 && y_lr >= 0 && - x_lr <= maxx && y_lr <= maxy) - { - fg += weight * - *((const value_type*)base_type::source().row_ptr(y_lr) + x_lr); - src_alpha += weight * base_mask; - } - else - { - fg += back_v * weight; - src_alpha += back_a * weight; - } - - fg >>= image_subpixel_shift * 2; - src_alpha >>= image_subpixel_shift * 2; - } - } - - span->v = (value_type)fg; - span->a = (value_type)src_alpha; - ++span; - ++base_type::interpolator(); - - } while(--len); - } - private: - color_type m_back_color; - }; - - - - //==============================================span_image_filter_gray_2x2 - template - class span_image_filter_gray_2x2 : - public span_image_filter - { - public: - typedef Source source_type; - typedef typename source_type::color_type color_type; - typedef Interpolator interpolator_type; - typedef span_image_filter base_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - //-------------------------------------------------------------------- - span_image_filter_gray_2x2() {} - span_image_filter_gray_2x2(source_type& src, - interpolator_type& inter, - const image_filter_lut& filter) : - base_type(src, inter, &filter) - {} - - - //-------------------------------------------------------------------- - void generate(color_type* span, int x, int y, unsigned len) - { - base_type::interpolator().begin(x + base_type::filter_dx_dbl(), - y + base_type::filter_dy_dbl(), len); - - calc_type fg; - - const value_type *fg_ptr; - const int16* weight_array = base_type::filter().weight_array() + - ((base_type::filter().diameter()/2 - 1) << - image_subpixel_shift); - do - { - int x_hr; - int y_hr; - - base_type::interpolator().coordinates(&x_hr, &y_hr); - - x_hr -= base_type::filter_dx_int(); - y_hr -= base_type::filter_dy_int(); - - int x_lr = x_hr >> image_subpixel_shift; - int y_lr = y_hr >> image_subpixel_shift; - - unsigned weight; - fg = image_filter_scale / 2; - - x_hr &= image_subpixel_mask; - y_hr &= image_subpixel_mask; - - fg_ptr = (const value_type*)base_type::source().span(x_lr, y_lr, 2); - weight = (weight_array[x_hr + image_subpixel_scale] * - weight_array[y_hr + image_subpixel_scale] + - image_filter_scale / 2) >> - image_filter_shift; - fg += weight * *fg_ptr; - - fg_ptr = (const value_type*)base_type::source().next_x(); - weight = (weight_array[x_hr] * - weight_array[y_hr + image_subpixel_scale] + - image_filter_scale / 2) >> - image_filter_shift; - fg += weight * *fg_ptr; - - fg_ptr = (const value_type*)base_type::source().next_y(); - weight = (weight_array[x_hr + image_subpixel_scale] * - weight_array[y_hr] + - image_filter_scale / 2) >> - image_filter_shift; - fg += weight * *fg_ptr; - - fg_ptr = (const value_type*)base_type::source().next_x(); - weight = (weight_array[x_hr] * - weight_array[y_hr] + - image_filter_scale / 2) >> - image_filter_shift; - fg += weight * *fg_ptr; - - fg >>= image_filter_shift; - if(fg > base_mask) fg = base_mask; - - span->v = (value_type)fg; - span->a = base_mask; - ++span; - ++base_type::interpolator(); - } while(--len); - } - }; - - - - //==================================================span_image_filter_gray - template - class span_image_filter_gray : - public span_image_filter - { - public: - typedef Source source_type; - typedef typename source_type::color_type color_type; - typedef Interpolator interpolator_type; - typedef span_image_filter base_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - //-------------------------------------------------------------------- - span_image_filter_gray() {} - span_image_filter_gray(source_type& src, - interpolator_type& inter, - const image_filter_lut& filter) : - base_type(src, inter, &filter) - {} - - //-------------------------------------------------------------------- - void generate(color_type* span, int x, int y, unsigned len) - { - base_type::interpolator().begin(x + base_type::filter_dx_dbl(), - y + base_type::filter_dy_dbl(), len); - - int fg; - const value_type *fg_ptr; - - unsigned diameter = base_type::filter().diameter(); - int start = base_type::filter().start(); - const int16* weight_array = base_type::filter().weight_array(); - - int x_count; - int weight_y; - - do - { - base_type::interpolator().coordinates(&x, &y); - - x -= base_type::filter_dx_int(); - y -= base_type::filter_dy_int(); - - int x_hr = x; - int y_hr = y; - - int x_lr = x_hr >> image_subpixel_shift; - int y_lr = y_hr >> image_subpixel_shift; - - fg = image_filter_scale / 2; - - int x_fract = x_hr & image_subpixel_mask; - unsigned y_count = diameter; - - y_hr = image_subpixel_mask - (y_hr & image_subpixel_mask); - fg_ptr = (const value_type*)base_type::source().span(x_lr + start, - y_lr + start, - diameter); - for(;;) - { - x_count = diameter; - weight_y = weight_array[y_hr]; - x_hr = image_subpixel_mask - x_fract; - for(;;) - { - fg += *fg_ptr * - ((weight_y * weight_array[x_hr] + - image_filter_scale / 2) >> - image_filter_shift); - if(--x_count == 0) break; - x_hr += image_subpixel_scale; - fg_ptr = (const value_type*)base_type::source().next_x(); - } - - if(--y_count == 0) break; - y_hr += image_subpixel_scale; - fg_ptr = (const value_type*)base_type::source().next_y(); - } - - fg >>= image_filter_shift; - if(fg < 0) fg = 0; - if(fg > base_mask) fg = base_mask; - span->v = (value_type)fg; - span->a = base_mask; - - ++span; - ++base_type::interpolator(); - - } while(--len); - } - }; - - - - //=========================================span_image_resample_gray_affine - template - class span_image_resample_gray_affine : - public span_image_resample_affine - { - public: - typedef Source source_type; - typedef typename source_type::color_type color_type; - typedef span_image_resample_affine base_type; - typedef typename base_type::interpolator_type interpolator_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::long_type long_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask, - downscale_shift = image_filter_shift - }; - - //-------------------------------------------------------------------- - span_image_resample_gray_affine() {} - span_image_resample_gray_affine(source_type& src, - interpolator_type& inter, - const image_filter_lut& filter) : - base_type(src, inter, filter) - {} - - - //-------------------------------------------------------------------- - void generate(color_type* span, int x, int y, unsigned len) - { - base_type::interpolator().begin(x + base_type::filter_dx_dbl(), - y + base_type::filter_dy_dbl(), len); - - long_type fg; - - int diameter = base_type::filter().diameter(); - int filter_scale = diameter << image_subpixel_shift; - int radius_x = (diameter * base_type::m_rx) >> 1; - int radius_y = (diameter * base_type::m_ry) >> 1; - int len_x_lr = - (diameter * base_type::m_rx + image_subpixel_mask) >> - image_subpixel_shift; - - const int16* weight_array = base_type::filter().weight_array(); - - do - { - base_type::interpolator().coordinates(&x, &y); - - x += base_type::filter_dx_int() - radius_x; - y += base_type::filter_dy_int() - radius_y; - - fg = image_filter_scale / 2; - - int y_lr = y >> image_subpixel_shift; - int y_hr = ((image_subpixel_mask - (y & image_subpixel_mask)) * - base_type::m_ry_inv) >> - image_subpixel_shift; - int total_weight = 0; - int x_lr = x >> image_subpixel_shift; - int x_hr = ((image_subpixel_mask - (x & image_subpixel_mask)) * - base_type::m_rx_inv) >> - image_subpixel_shift; - - int x_hr2 = x_hr; - const value_type* fg_ptr = - (const value_type*)base_type::source().span(x_lr, y_lr, len_x_lr); - for(;;) - { - int weight_y = weight_array[y_hr]; - x_hr = x_hr2; - for(;;) - { - int weight = (weight_y * weight_array[x_hr] + - image_filter_scale / 2) >> - downscale_shift; - - fg += *fg_ptr * weight; - total_weight += weight; - x_hr += base_type::m_rx_inv; - if(x_hr >= filter_scale) break; - fg_ptr = (const value_type*)base_type::source().next_x(); - } - y_hr += base_type::m_ry_inv; - if(y_hr >= filter_scale) break; - fg_ptr = (const value_type*)base_type::source().next_y(); - } - - fg /= total_weight; - if(fg < 0) fg = 0; - if(fg > base_mask) fg = base_mask; - - span->v = (value_type)fg; - span->a = base_mask; - - ++span; - ++base_type::interpolator(); - } while(--len); - } - }; - - - - //================================================span_image_resample_gray - template - class span_image_resample_gray : - public span_image_resample - { - public: - typedef Source source_type; - typedef typename source_type::color_type color_type; - typedef Interpolator interpolator_type; - typedef span_image_resample base_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::long_type long_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask, - downscale_shift = image_filter_shift - }; - - //-------------------------------------------------------------------- - span_image_resample_gray() {} - span_image_resample_gray(source_type& src, - interpolator_type& inter, - const image_filter_lut& filter) : - base_type(src, inter, filter) - {} - - //-------------------------------------------------------------------- - void generate(color_type* span, int x, int y, unsigned len) - { - base_type::interpolator().begin(x + base_type::filter_dx_dbl(), - y + base_type::filter_dy_dbl(), len); - long_type fg; - - int diameter = base_type::filter().diameter(); - int filter_scale = diameter << image_subpixel_shift; - - const int16* weight_array = base_type::filter().weight_array(); - do - { - int rx; - int ry; - int rx_inv = image_subpixel_scale; - int ry_inv = image_subpixel_scale; - base_type::interpolator().coordinates(&x, &y); - base_type::interpolator().local_scale(&rx, &ry); - base_type::adjust_scale(&rx, &ry); - - rx_inv = image_subpixel_scale * image_subpixel_scale / rx; - ry_inv = image_subpixel_scale * image_subpixel_scale / ry; - - int radius_x = (diameter * rx) >> 1; - int radius_y = (diameter * ry) >> 1; - int len_x_lr = - (diameter * rx + image_subpixel_mask) >> - image_subpixel_shift; - - x += base_type::filter_dx_int() - radius_x; - y += base_type::filter_dy_int() - radius_y; - - fg = image_filter_scale / 2; - - int y_lr = y >> image_subpixel_shift; - int y_hr = ((image_subpixel_mask - (y & image_subpixel_mask)) * - ry_inv) >> - image_subpixel_shift; - int total_weight = 0; - int x_lr = x >> image_subpixel_shift; - int x_hr = ((image_subpixel_mask - (x & image_subpixel_mask)) * - rx_inv) >> - image_subpixel_shift; - int x_hr2 = x_hr; - const value_type* fg_ptr = - (const value_type*)base_type::source().span(x_lr, y_lr, len_x_lr); - - for(;;) - { - int weight_y = weight_array[y_hr]; - x_hr = x_hr2; - for(;;) - { - int weight = (weight_y * weight_array[x_hr] + - image_filter_scale / 2) >> - downscale_shift; - fg += *fg_ptr * weight; - total_weight += weight; - x_hr += rx_inv; - if(x_hr >= filter_scale) break; - fg_ptr = (const value_type*)base_type::source().next_x(); - } - y_hr += ry_inv; - if(y_hr >= filter_scale) break; - fg_ptr = (const value_type*)base_type::source().next_y(); - } - - fg /= total_weight; - if(fg < 0) fg = 0; - if(fg > base_mask) fg = base_mask; - - span->v = (value_type)fg; - span->a = base_mask; - - ++span; - ++base_type::interpolator(); - } while(--len); - } - }; - - -} - - -#endif - - - diff --git a/desmume/src/windows/agg/include/agg_span_image_filter_rgb.h b/desmume/src/windows/agg/include/agg_span_image_filter_rgb.h deleted file mode 100644 index 870b5c36c..000000000 --- a/desmume/src/windows/agg/include/agg_span_image_filter_rgb.h +++ /dev/null @@ -1,901 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- -// -// Adaptation for high precision colors has been sponsored by -// Liberty Technology Systems, Inc., visit http://lib-sys.com -// -// Liberty Technology Systems, Inc. is the provider of -// PostScript and PDF technology for software developers. -// -//---------------------------------------------------------------------------- -#ifndef AGG_SPAN_IMAGE_FILTER_RGB_INCLUDED -#define AGG_SPAN_IMAGE_FILTER_RGB_INCLUDED - -#include "agg_basics.h" -#include "agg_color_rgba.h" -#include "agg_span_image_filter.h" - - -namespace agg -{ - - //===============================================span_image_filter_rgb_nn - template - class span_image_filter_rgb_nn : - public span_image_filter - { - public: - typedef Source source_type; - typedef typename source_type::color_type color_type; - typedef typename source_type::order_type order_type; - typedef Interpolator interpolator_type; - typedef span_image_filter base_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - //-------------------------------------------------------------------- - span_image_filter_rgb_nn() {} - span_image_filter_rgb_nn(source_type& src, - interpolator_type& inter) : - base_type(src, inter, 0) - {} - - //-------------------------------------------------------------------- - void generate(color_type* span, int x, int y, unsigned len) - { - base_type::interpolator().begin(x + base_type::filter_dx_dbl(), - y + base_type::filter_dy_dbl(), len); - do - { - base_type::interpolator().coordinates(&x, &y); - const value_type* fg_ptr = (const value_type*) - base_type::source().span(x >> image_subpixel_shift, - y >> image_subpixel_shift, - 1); - span->r = fg_ptr[order_type::R]; - span->g = fg_ptr[order_type::G]; - span->b = fg_ptr[order_type::B]; - span->a = base_mask; - ++span; - ++base_type::interpolator(); - - } while(--len); - } - }; - - - - //==========================================span_image_filter_rgb_bilinear - template - class span_image_filter_rgb_bilinear : - public span_image_filter - { - public: - typedef Source source_type; - typedef typename source_type::color_type color_type; - typedef typename source_type::order_type order_type; - typedef Interpolator interpolator_type; - typedef span_image_filter base_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - //-------------------------------------------------------------------- - span_image_filter_rgb_bilinear() {} - span_image_filter_rgb_bilinear(source_type& src, - interpolator_type& inter) : - base_type(src, inter, 0) - {} - - - //-------------------------------------------------------------------- - void generate(color_type* span, int x, int y, unsigned len) - { - base_type::interpolator().begin(x + base_type::filter_dx_dbl(), - y + base_type::filter_dy_dbl(), len); - calc_type fg[3]; - const value_type *fg_ptr; - do - { - int x_hr; - int y_hr; - - base_type::interpolator().coordinates(&x_hr, &y_hr); - - x_hr -= base_type::filter_dx_int(); - y_hr -= base_type::filter_dy_int(); - - int x_lr = x_hr >> image_subpixel_shift; - int y_lr = y_hr >> image_subpixel_shift; - - unsigned weight; - - fg[0] = - fg[1] = - fg[2] = image_subpixel_scale * image_subpixel_scale / 2; - - x_hr &= image_subpixel_mask; - y_hr &= image_subpixel_mask; - - fg_ptr = (const value_type*)base_type::source().span(x_lr, y_lr, 2); - weight = (image_subpixel_scale - x_hr) * - (image_subpixel_scale - y_hr); - fg[0] += weight * *fg_ptr++; - fg[1] += weight * *fg_ptr++; - fg[2] += weight * *fg_ptr; - - fg_ptr = (const value_type*)base_type::source().next_x(); - weight = x_hr * (image_subpixel_scale - y_hr); - fg[0] += weight * *fg_ptr++; - fg[1] += weight * *fg_ptr++; - fg[2] += weight * *fg_ptr; - - fg_ptr = (const value_type*)base_type::source().next_y(); - weight = (image_subpixel_scale - x_hr) * y_hr; - fg[0] += weight * *fg_ptr++; - fg[1] += weight * *fg_ptr++; - fg[2] += weight * *fg_ptr; - - fg_ptr = (const value_type*)base_type::source().next_x(); - weight = x_hr * y_hr; - fg[0] += weight * *fg_ptr++; - fg[1] += weight * *fg_ptr++; - fg[2] += weight * *fg_ptr; - - span->r = value_type(fg[order_type::R] >> (image_subpixel_shift * 2)); - span->g = value_type(fg[order_type::G] >> (image_subpixel_shift * 2)); - span->b = value_type(fg[order_type::B] >> (image_subpixel_shift * 2)); - span->a = base_mask; - - ++span; - ++base_type::interpolator(); - - } while(--len); - } - }; - - - - //=====================================span_image_filter_rgb_bilinear_clip - template - class span_image_filter_rgb_bilinear_clip : - public span_image_filter - { - public: - typedef Source source_type; - typedef typename source_type::color_type color_type; - typedef typename source_type::order_type order_type; - typedef Interpolator interpolator_type; - typedef span_image_filter base_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - //-------------------------------------------------------------------- - span_image_filter_rgb_bilinear_clip() {} - span_image_filter_rgb_bilinear_clip(source_type& src, - const color_type& back_color, - interpolator_type& inter) : - base_type(src, inter, 0), - m_back_color(back_color) - {} - const color_type& background_color() const { return m_back_color; } - void background_color(const color_type& v) { m_back_color = v; } - - //-------------------------------------------------------------------- - void generate(color_type* span, int x, int y, unsigned len) - { - base_type::interpolator().begin(x + base_type::filter_dx_dbl(), - y + base_type::filter_dy_dbl(), len); - calc_type fg[3]; - calc_type src_alpha; - value_type back_r = m_back_color.r; - value_type back_g = m_back_color.g; - value_type back_b = m_back_color.b; - value_type back_a = m_back_color.a; - - const value_type *fg_ptr; - - int maxx = base_type::source().width() - 1; - int maxy = base_type::source().height() - 1; - - do - { - int x_hr; - int y_hr; - - base_type::interpolator().coordinates(&x_hr, &y_hr); - - x_hr -= base_type::filter_dx_int(); - y_hr -= base_type::filter_dy_int(); - - int x_lr = x_hr >> image_subpixel_shift; - int y_lr = y_hr >> image_subpixel_shift; - unsigned weight; - - if(x_lr >= 0 && y_lr >= 0 && - x_lr < maxx && y_lr < maxy) - { - fg[0] = - fg[1] = - fg[2] = image_subpixel_scale * image_subpixel_scale / 2; - - x_hr &= image_subpixel_mask; - y_hr &= image_subpixel_mask; - - fg_ptr = (const value_type*) - base_type::source().row_ptr(y_lr) + x_lr + x_lr + x_lr; - - weight = (image_subpixel_scale - x_hr) * - (image_subpixel_scale - y_hr); - fg[0] += weight * *fg_ptr++; - fg[1] += weight * *fg_ptr++; - fg[2] += weight * *fg_ptr++; - - weight = x_hr * (image_subpixel_scale - y_hr); - fg[0] += weight * *fg_ptr++; - fg[1] += weight * *fg_ptr++; - fg[2] += weight * *fg_ptr++; - - ++y_lr; - fg_ptr = (const value_type*) - base_type::source().row_ptr(y_lr) + x_lr + x_lr + x_lr; - - weight = (image_subpixel_scale - x_hr) * y_hr; - fg[0] += weight * *fg_ptr++; - fg[1] += weight * *fg_ptr++; - fg[2] += weight * *fg_ptr++; - - weight = x_hr * y_hr; - fg[0] += weight * *fg_ptr++; - fg[1] += weight * *fg_ptr++; - fg[2] += weight * *fg_ptr++; - - fg[0] >>= image_subpixel_shift * 2; - fg[1] >>= image_subpixel_shift * 2; - fg[2] >>= image_subpixel_shift * 2; - src_alpha = base_mask; - } - else - { - if(x_lr < -1 || y_lr < -1 || - x_lr > maxx || y_lr > maxy) - { - fg[order_type::R] = back_r; - fg[order_type::G] = back_g; - fg[order_type::B] = back_b; - src_alpha = back_a; - } - else - { - fg[0] = - fg[1] = - fg[2] = - src_alpha = image_subpixel_scale * image_subpixel_scale / 2; - - x_hr &= image_subpixel_mask; - y_hr &= image_subpixel_mask; - - weight = (image_subpixel_scale - x_hr) * - (image_subpixel_scale - y_hr); - if(x_lr >= 0 && y_lr >= 0 && - x_lr <= maxx && y_lr <= maxy) - { - fg_ptr = (const value_type*) - base_type::source().row_ptr(y_lr) + x_lr + x_lr + x_lr; - - fg[0] += weight * *fg_ptr++; - fg[1] += weight * *fg_ptr++; - fg[2] += weight * *fg_ptr++; - src_alpha += weight * base_mask; - } - else - { - fg[order_type::R] += back_r * weight; - fg[order_type::G] += back_g * weight; - fg[order_type::B] += back_b * weight; - src_alpha += back_a * weight; - } - - x_lr++; - - weight = x_hr * (image_subpixel_scale - y_hr); - if(x_lr >= 0 && y_lr >= 0 && - x_lr <= maxx && y_lr <= maxy) - { - fg_ptr = (const value_type*) - base_type::source().row_ptr(y_lr) + x_lr + x_lr + x_lr; - - fg[0] += weight * *fg_ptr++; - fg[1] += weight * *fg_ptr++; - fg[2] += weight * *fg_ptr++; - src_alpha += weight * base_mask; - } - else - { - fg[order_type::R] += back_r * weight; - fg[order_type::G] += back_g * weight; - fg[order_type::B] += back_b * weight; - src_alpha += back_a * weight; - } - - x_lr--; - y_lr++; - - weight = (image_subpixel_scale - x_hr) * y_hr; - if(x_lr >= 0 && y_lr >= 0 && - x_lr <= maxx && y_lr <= maxy) - { - fg_ptr = (const value_type*) - base_type::source().row_ptr(y_lr) + x_lr + x_lr + x_lr; - - fg[0] += weight * *fg_ptr++; - fg[1] += weight * *fg_ptr++; - fg[2] += weight * *fg_ptr++; - src_alpha += weight * base_mask; - } - else - { - fg[order_type::R] += back_r * weight; - fg[order_type::G] += back_g * weight; - fg[order_type::B] += back_b * weight; - src_alpha += back_a * weight; - } - - x_lr++; - - weight = x_hr * y_hr; - if(x_lr >= 0 && y_lr >= 0 && - x_lr <= maxx && y_lr <= maxy) - { - fg_ptr = (const value_type*) - base_type::source().row_ptr(y_lr) + x_lr + x_lr + x_lr; - - fg[0] += weight * *fg_ptr++; - fg[1] += weight * *fg_ptr++; - fg[2] += weight * *fg_ptr++; - src_alpha += weight * base_mask; - } - else - { - fg[order_type::R] += back_r * weight; - fg[order_type::G] += back_g * weight; - fg[order_type::B] += back_b * weight; - src_alpha += back_a * weight; - } - - fg[0] >>= image_subpixel_shift * 2; - fg[1] >>= image_subpixel_shift * 2; - fg[2] >>= image_subpixel_shift * 2; - src_alpha >>= image_subpixel_shift * 2; - } - } - - span->r = (value_type)fg[order_type::R]; - span->g = (value_type)fg[order_type::G]; - span->b = (value_type)fg[order_type::B]; - span->a = (value_type)src_alpha; - ++span; - ++base_type::interpolator(); - - } while(--len); - } - private: - color_type m_back_color; - }; - - - - //===============================================span_image_filter_rgb_2x2 - template - class span_image_filter_rgb_2x2 : - public span_image_filter - { - public: - typedef Source source_type; - typedef typename source_type::color_type color_type; - typedef typename source_type::order_type order_type; - typedef Interpolator interpolator_type; - typedef span_image_filter base_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - //-------------------------------------------------------------------- - span_image_filter_rgb_2x2() {} - span_image_filter_rgb_2x2(source_type& src, - interpolator_type& inter, - const image_filter_lut& filter) : - base_type(src, inter, &filter) - {} - - - //-------------------------------------------------------------------- - void generate(color_type* span, int x, int y, unsigned len) - { - base_type::interpolator().begin(x + base_type::filter_dx_dbl(), - y + base_type::filter_dy_dbl(), len); - - calc_type fg[3]; - - const value_type *fg_ptr; - const int16* weight_array = base_type::filter().weight_array() + - ((base_type::filter().diameter()/2 - 1) << - image_subpixel_shift); - do - { - int x_hr; - int y_hr; - - base_type::interpolator().coordinates(&x_hr, &y_hr); - - x_hr -= base_type::filter_dx_int(); - y_hr -= base_type::filter_dy_int(); - - int x_lr = x_hr >> image_subpixel_shift; - int y_lr = y_hr >> image_subpixel_shift; - - unsigned weight; - fg[0] = fg[1] = fg[2] = image_filter_scale / 2; - - x_hr &= image_subpixel_mask; - y_hr &= image_subpixel_mask; - - fg_ptr = (const value_type*)base_type::source().span(x_lr, y_lr, 2); - weight = (weight_array[x_hr + image_subpixel_scale] * - weight_array[y_hr + image_subpixel_scale] + - image_filter_scale / 2) >> - image_filter_shift; - fg[0] += weight * *fg_ptr++; - fg[1] += weight * *fg_ptr++; - fg[2] += weight * *fg_ptr; - - fg_ptr = (const value_type*)base_type::source().next_x(); - weight = (weight_array[x_hr] * - weight_array[y_hr + image_subpixel_scale] + - image_filter_scale / 2) >> - image_filter_shift; - fg[0] += weight * *fg_ptr++; - fg[1] += weight * *fg_ptr++; - fg[2] += weight * *fg_ptr; - - fg_ptr = (const value_type*)base_type::source().next_y(); - weight = (weight_array[x_hr + image_subpixel_scale] * - weight_array[y_hr] + - image_filter_scale / 2) >> - image_filter_shift; - fg[0] += weight * *fg_ptr++; - fg[1] += weight * *fg_ptr++; - fg[2] += weight * *fg_ptr; - - fg_ptr = (const value_type*)base_type::source().next_x(); - weight = (weight_array[x_hr] * - weight_array[y_hr] + - image_filter_scale / 2) >> - image_filter_shift; - fg[0] += weight * *fg_ptr++; - fg[1] += weight * *fg_ptr++; - fg[2] += weight * *fg_ptr; - - fg[0] >>= image_filter_shift; - fg[1] >>= image_filter_shift; - fg[2] >>= image_filter_shift; - - if(fg[order_type::R] > base_mask) fg[order_type::R] = base_mask; - if(fg[order_type::G] > base_mask) fg[order_type::G] = base_mask; - if(fg[order_type::B] > base_mask) fg[order_type::B] = base_mask; - - span->r = (value_type)fg[order_type::R]; - span->g = (value_type)fg[order_type::G]; - span->b = (value_type)fg[order_type::B]; - span->a = base_mask; - - ++span; - ++base_type::interpolator(); - - } while(--len); - } - }; - - - - //===================================================span_image_filter_rgb - template - class span_image_filter_rgb : - public span_image_filter - { - public: - typedef Source source_type; - typedef typename source_type::color_type color_type; - typedef typename source_type::order_type order_type; - typedef Interpolator interpolator_type; - typedef span_image_filter base_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - //-------------------------------------------------------------------- - span_image_filter_rgb() {} - span_image_filter_rgb(source_type& src, - interpolator_type& inter, - const image_filter_lut& filter) : - base_type(src, inter, &filter) - {} - - //-------------------------------------------------------------------- - void generate(color_type* span, int x, int y, unsigned len) - { - base_type::interpolator().begin(x + base_type::filter_dx_dbl(), - y + base_type::filter_dy_dbl(), len); - - int fg[3]; - const value_type *fg_ptr; - - unsigned diameter = base_type::filter().diameter(); - int start = base_type::filter().start(); - const int16* weight_array = base_type::filter().weight_array(); - - int x_count; - int weight_y; - - do - { - base_type::interpolator().coordinates(&x, &y); - - x -= base_type::filter_dx_int(); - y -= base_type::filter_dy_int(); - - int x_hr = x; - int y_hr = y; - - int x_lr = x_hr >> image_subpixel_shift; - int y_lr = y_hr >> image_subpixel_shift; - - fg[0] = fg[1] = fg[2] = image_filter_scale / 2; - - int x_fract = x_hr & image_subpixel_mask; - unsigned y_count = diameter; - - y_hr = image_subpixel_mask - (y_hr & image_subpixel_mask); - fg_ptr = (const value_type*)base_type::source().span(x_lr + start, - y_lr + start, - diameter); - for(;;) - { - x_count = diameter; - weight_y = weight_array[y_hr]; - x_hr = image_subpixel_mask - x_fract; - for(;;) - { - int weight = (weight_y * weight_array[x_hr] + - image_filter_scale / 2) >> - image_filter_shift; - - fg[0] += weight * *fg_ptr++; - fg[1] += weight * *fg_ptr++; - fg[2] += weight * *fg_ptr; - - if(--x_count == 0) break; - x_hr += image_subpixel_scale; - fg_ptr = (const value_type*)base_type::source().next_x(); - } - - if(--y_count == 0) break; - y_hr += image_subpixel_scale; - fg_ptr = (const value_type*)base_type::source().next_y(); - } - - fg[0] >>= image_filter_shift; - fg[1] >>= image_filter_shift; - fg[2] >>= image_filter_shift; - - if(fg[0] < 0) fg[0] = 0; - if(fg[1] < 0) fg[1] = 0; - if(fg[2] < 0) fg[2] = 0; - - if(fg[order_type::R] > base_mask) fg[order_type::R] = base_mask; - if(fg[order_type::G] > base_mask) fg[order_type::G] = base_mask; - if(fg[order_type::B] > base_mask) fg[order_type::B] = base_mask; - - span->r = (value_type)fg[order_type::R]; - span->g = (value_type)fg[order_type::G]; - span->b = (value_type)fg[order_type::B]; - span->a = base_mask; - - ++span; - ++base_type::interpolator(); - - } while(--len); - } - }; - - - - //==========================================span_image_resample_rgb_affine - template - class span_image_resample_rgb_affine : - public span_image_resample_affine - { - public: - typedef Source source_type; - typedef typename source_type::color_type color_type; - typedef typename source_type::order_type order_type; - typedef span_image_resample_affine base_type; - typedef typename base_type::interpolator_type interpolator_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::long_type long_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask, - downscale_shift = image_filter_shift - }; - - //-------------------------------------------------------------------- - span_image_resample_rgb_affine() {} - span_image_resample_rgb_affine(source_type& src, - interpolator_type& inter, - const image_filter_lut& filter) : - base_type(src, inter, filter) - {} - - - //-------------------------------------------------------------------- - void generate(color_type* span, int x, int y, unsigned len) - { - base_type::interpolator().begin(x + base_type::filter_dx_dbl(), - y + base_type::filter_dy_dbl(), len); - - long_type fg[3]; - - int diameter = base_type::filter().diameter(); - int filter_scale = diameter << image_subpixel_shift; - int radius_x = (diameter * base_type::m_rx) >> 1; - int radius_y = (diameter * base_type::m_ry) >> 1; - int len_x_lr = - (diameter * base_type::m_rx + image_subpixel_mask) >> - image_subpixel_shift; - - const int16* weight_array = base_type::filter().weight_array(); - - do - { - base_type::interpolator().coordinates(&x, &y); - - x += base_type::filter_dx_int() - radius_x; - y += base_type::filter_dy_int() - radius_y; - - fg[0] = fg[1] = fg[2] = image_filter_scale / 2; - - int y_lr = y >> image_subpixel_shift; - int y_hr = ((image_subpixel_mask - (y & image_subpixel_mask)) * - base_type::m_ry_inv) >> - image_subpixel_shift; - int total_weight = 0; - int x_lr = x >> image_subpixel_shift; - int x_hr = ((image_subpixel_mask - (x & image_subpixel_mask)) * - base_type::m_rx_inv) >> - image_subpixel_shift; - - int x_hr2 = x_hr; - const value_type* fg_ptr = - (const value_type*)base_type::source().span(x_lr, y_lr, len_x_lr); - for(;;) - { - int weight_y = weight_array[y_hr]; - x_hr = x_hr2; - for(;;) - { - int weight = (weight_y * weight_array[x_hr] + - image_filter_scale / 2) >> - downscale_shift; - - fg[0] += *fg_ptr++ * weight; - fg[1] += *fg_ptr++ * weight; - fg[2] += *fg_ptr * weight; - total_weight += weight; - x_hr += base_type::m_rx_inv; - if(x_hr >= filter_scale) break; - fg_ptr = (const value_type*)base_type::source().next_x(); - } - y_hr += base_type::m_ry_inv; - if(y_hr >= filter_scale) break; - fg_ptr = (const value_type*)base_type::source().next_y(); - } - - fg[0] /= total_weight; - fg[1] /= total_weight; - fg[2] /= total_weight; - - if(fg[0] < 0) fg[0] = 0; - if(fg[1] < 0) fg[1] = 0; - if(fg[2] < 0) fg[2] = 0; - - if(fg[order_type::R] > base_mask) fg[order_type::R] = base_mask; - if(fg[order_type::G] > base_mask) fg[order_type::G] = base_mask; - if(fg[order_type::B] > base_mask) fg[order_type::B] = base_mask; - - span->r = (value_type)fg[order_type::R]; - span->g = (value_type)fg[order_type::G]; - span->b = (value_type)fg[order_type::B]; - span->a = base_mask; - - ++span; - ++base_type::interpolator(); - } while(--len); - } - }; - - - - //=================================================span_image_resample_rgb - template - class span_image_resample_rgb : - public span_image_resample - { - public: - typedef Source source_type; - typedef typename source_type::color_type color_type; - typedef typename source_type::order_type order_type; - typedef Interpolator interpolator_type; - typedef span_image_resample base_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::long_type long_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask, - downscale_shift = image_filter_shift - }; - - //-------------------------------------------------------------------- - span_image_resample_rgb() {} - span_image_resample_rgb(source_type& src, - interpolator_type& inter, - const image_filter_lut& filter) : - base_type(src, inter, filter) - {} - - //-------------------------------------------------------------------- - void generate(color_type* span, int x, int y, unsigned len) - { - base_type::interpolator().begin(x + base_type::filter_dx_dbl(), - y + base_type::filter_dy_dbl(), len); - long_type fg[3]; - - int diameter = base_type::filter().diameter(); - int filter_scale = diameter << image_subpixel_shift; - - const int16* weight_array = base_type::filter().weight_array(); - do - { - int rx; - int ry; - int rx_inv = image_subpixel_scale; - int ry_inv = image_subpixel_scale; - base_type::interpolator().coordinates(&x, &y); - base_type::interpolator().local_scale(&rx, &ry); - base_type::adjust_scale(&rx, &ry); - - rx_inv = image_subpixel_scale * image_subpixel_scale / rx; - ry_inv = image_subpixel_scale * image_subpixel_scale / ry; - - int radius_x = (diameter * rx) >> 1; - int radius_y = (diameter * ry) >> 1; - int len_x_lr = - (diameter * rx + image_subpixel_mask) >> - image_subpixel_shift; - - x += base_type::filter_dx_int() - radius_x; - y += base_type::filter_dy_int() - radius_y; - - fg[0] = fg[1] = fg[2] = image_filter_scale / 2; - - int y_lr = y >> image_subpixel_shift; - int y_hr = ((image_subpixel_mask - (y & image_subpixel_mask)) * - ry_inv) >> - image_subpixel_shift; - int total_weight = 0; - int x_lr = x >> image_subpixel_shift; - int x_hr = ((image_subpixel_mask - (x & image_subpixel_mask)) * - rx_inv) >> - image_subpixel_shift; - int x_hr2 = x_hr; - const value_type* fg_ptr = - (const value_type*)base_type::source().span(x_lr, y_lr, len_x_lr); - - for(;;) - { - int weight_y = weight_array[y_hr]; - x_hr = x_hr2; - for(;;) - { - int weight = (weight_y * weight_array[x_hr] + - image_filter_scale / 2) >> - downscale_shift; - fg[0] += *fg_ptr++ * weight; - fg[1] += *fg_ptr++ * weight; - fg[2] += *fg_ptr * weight; - total_weight += weight; - x_hr += rx_inv; - if(x_hr >= filter_scale) break; - fg_ptr = (const value_type*)base_type::source().next_x(); - } - y_hr += ry_inv; - if(y_hr >= filter_scale) break; - fg_ptr = (const value_type*)base_type::source().next_y(); - } - - fg[0] /= total_weight; - fg[1] /= total_weight; - fg[2] /= total_weight; - - if(fg[0] < 0) fg[0] = 0; - if(fg[1] < 0) fg[1] = 0; - if(fg[2] < 0) fg[2] = 0; - - if(fg[order_type::R] > base_mask) fg[order_type::R] = base_mask; - if(fg[order_type::G] > base_mask) fg[order_type::G] = base_mask; - if(fg[order_type::B] > base_mask) fg[order_type::B] = base_mask; - - span->r = (value_type)fg[order_type::R]; - span->g = (value_type)fg[order_type::G]; - span->b = (value_type)fg[order_type::B]; - span->a = base_mask; - - ++span; - ++base_type::interpolator(); - } while(--len); - } - }; - - -} - - -#endif - - - diff --git a/desmume/src/windows/agg/include/agg_span_image_filter_rgba.h b/desmume/src/windows/agg/include/agg_span_image_filter_rgba.h deleted file mode 100644 index 598ca3780..000000000 --- a/desmume/src/windows/agg/include/agg_span_image_filter_rgba.h +++ /dev/null @@ -1,929 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- -// -// Adaptation for high precision colors has been sponsored by -// Liberty Technology Systems, Inc., visit http://lib-sys.com -// -// Liberty Technology Systems, Inc. is the provider of -// PostScript and PDF technology for software developers. -// -//---------------------------------------------------------------------------- -#ifndef AGG_SPAN_IMAGE_FILTER_RGBA_INCLUDED -#define AGG_SPAN_IMAGE_FILTER_RGBA_INCLUDED - -#include "agg_basics.h" -#include "agg_color_rgba.h" -#include "agg_span_image_filter.h" - - -namespace agg -{ - - //==============================================span_image_filter_rgba_nn - template - class span_image_filter_rgba_nn : - public span_image_filter - { - public: - typedef Source source_type; - typedef typename source_type::color_type color_type; - typedef typename source_type::order_type order_type; - typedef Interpolator interpolator_type; - typedef span_image_filter base_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - //-------------------------------------------------------------------- - span_image_filter_rgba_nn() {} - span_image_filter_rgba_nn(source_type& src, - interpolator_type& inter) : - base_type(src, inter, 0) - {} - - //-------------------------------------------------------------------- - void generate(color_type* span, int x, int y, unsigned len) - { - base_type::interpolator().begin(x + base_type::filter_dx_dbl(), - y + base_type::filter_dy_dbl(), len); - do - { - base_type::interpolator().coordinates(&x, &y); - const value_type* fg_ptr = (const value_type*) - base_type::source().span(x >> image_subpixel_shift, - y >> image_subpixel_shift, - 1); - span->r = fg_ptr[order_type::R]; - span->g = fg_ptr[order_type::G]; - span->b = fg_ptr[order_type::B]; - span->a = fg_ptr[order_type::A]; - ++span; - ++base_type::interpolator(); - - } while(--len); - } - }; - - - - //=========================================span_image_filter_rgba_bilinear - template - class span_image_filter_rgba_bilinear : - public span_image_filter - { - public: - typedef Source source_type; - typedef typename source_type::color_type color_type; - typedef typename source_type::order_type order_type; - typedef Interpolator interpolator_type; - typedef span_image_filter base_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - //-------------------------------------------------------------------- - span_image_filter_rgba_bilinear() {} - span_image_filter_rgba_bilinear(source_type& src, - interpolator_type& inter) : - base_type(src, inter, 0) - {} - - - //-------------------------------------------------------------------- - void generate(color_type* span, int x, int y, unsigned len) - { - base_type::interpolator().begin(x + base_type::filter_dx_dbl(), - y + base_type::filter_dy_dbl(), len); - - calc_type fg[4]; - const value_type *fg_ptr; - - do - { - int x_hr; - int y_hr; - - base_type::interpolator().coordinates(&x_hr, &y_hr); - - x_hr -= base_type::filter_dx_int(); - y_hr -= base_type::filter_dy_int(); - - int x_lr = x_hr >> image_subpixel_shift; - int y_lr = y_hr >> image_subpixel_shift; - - unsigned weight; - - fg[0] = - fg[1] = - fg[2] = - fg[3] = image_subpixel_scale * image_subpixel_scale / 2; - - x_hr &= image_subpixel_mask; - y_hr &= image_subpixel_mask; - - fg_ptr = (const value_type*)base_type::source().span(x_lr, y_lr, 2); - weight = (image_subpixel_scale - x_hr) * - (image_subpixel_scale - y_hr); - fg[0] += weight * *fg_ptr++; - fg[1] += weight * *fg_ptr++; - fg[2] += weight * *fg_ptr++; - fg[3] += weight * *fg_ptr; - - fg_ptr = (const value_type*)base_type::source().next_x(); - weight = x_hr * (image_subpixel_scale - y_hr); - fg[0] += weight * *fg_ptr++; - fg[1] += weight * *fg_ptr++; - fg[2] += weight * *fg_ptr++; - fg[3] += weight * *fg_ptr; - - fg_ptr = (const value_type*)base_type::source().next_y(); - weight = (image_subpixel_scale - x_hr) * y_hr; - fg[0] += weight * *fg_ptr++; - fg[1] += weight * *fg_ptr++; - fg[2] += weight * *fg_ptr++; - fg[3] += weight * *fg_ptr; - - fg_ptr = (const value_type*)base_type::source().next_x(); - weight = x_hr * y_hr; - fg[0] += weight * *fg_ptr++; - fg[1] += weight * *fg_ptr++; - fg[2] += weight * *fg_ptr++; - fg[3] += weight * *fg_ptr; - - span->r = value_type(fg[order_type::R] >> (image_subpixel_shift * 2)); - span->g = value_type(fg[order_type::G] >> (image_subpixel_shift * 2)); - span->b = value_type(fg[order_type::B] >> (image_subpixel_shift * 2)); - span->a = value_type(fg[order_type::A] >> (image_subpixel_shift * 2)); - - ++span; - ++base_type::interpolator(); - - } while(--len); - } - }; - - - //====================================span_image_filter_rgba_bilinear_clip - template - class span_image_filter_rgba_bilinear_clip : - public span_image_filter - { - public: - typedef Source source_type; - typedef typename source_type::color_type color_type; - typedef typename source_type::order_type order_type; - typedef Interpolator interpolator_type; - typedef span_image_filter base_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - //-------------------------------------------------------------------- - span_image_filter_rgba_bilinear_clip() {} - span_image_filter_rgba_bilinear_clip(source_type& src, - const color_type& back_color, - interpolator_type& inter) : - base_type(src, inter, 0), - m_back_color(back_color) - {} - const color_type& background_color() const { return m_back_color; } - void background_color(const color_type& v) { m_back_color = v; } - - - //-------------------------------------------------------------------- - void generate(color_type* span, int x, int y, unsigned len) - { - base_type::interpolator().begin(x + base_type::filter_dx_dbl(), - y + base_type::filter_dy_dbl(), len); - - calc_type fg[4]; - value_type back_r = m_back_color.r; - value_type back_g = m_back_color.g; - value_type back_b = m_back_color.b; - value_type back_a = m_back_color.a; - - const value_type *fg_ptr; - int maxx = base_type::source().width() - 1; - int maxy = base_type::source().height() - 1; - - do - { - int x_hr; - int y_hr; - - base_type::interpolator().coordinates(&x_hr, &y_hr); - - x_hr -= base_type::filter_dx_int(); - y_hr -= base_type::filter_dy_int(); - - int x_lr = x_hr >> image_subpixel_shift; - int y_lr = y_hr >> image_subpixel_shift; - - unsigned weight; - - if(x_lr >= 0 && y_lr >= 0 && - x_lr < maxx && y_lr < maxy) - { - fg[0] = - fg[1] = - fg[2] = - fg[3] = image_subpixel_scale * image_subpixel_scale / 2; - - x_hr &= image_subpixel_mask; - y_hr &= image_subpixel_mask; - - fg_ptr = (const value_type*) - base_type::source().row_ptr(y_lr) + (x_lr << 2); - - weight = (image_subpixel_scale - x_hr) * - (image_subpixel_scale - y_hr); - fg[0] += weight * *fg_ptr++; - fg[1] += weight * *fg_ptr++; - fg[2] += weight * *fg_ptr++; - fg[3] += weight * *fg_ptr++; - - weight = x_hr * (image_subpixel_scale - y_hr); - fg[0] += weight * *fg_ptr++; - fg[1] += weight * *fg_ptr++; - fg[2] += weight * *fg_ptr++; - fg[3] += weight * *fg_ptr++; - - ++y_lr; - fg_ptr = (const value_type*) - base_type::source().row_ptr(y_lr) + (x_lr << 2); - - weight = (image_subpixel_scale - x_hr) * y_hr; - fg[0] += weight * *fg_ptr++; - fg[1] += weight * *fg_ptr++; - fg[2] += weight * *fg_ptr++; - fg[3] += weight * *fg_ptr++; - - weight = x_hr * y_hr; - fg[0] += weight * *fg_ptr++; - fg[1] += weight * *fg_ptr++; - fg[2] += weight * *fg_ptr++; - fg[3] += weight * *fg_ptr++; - - fg[0] >>= image_subpixel_shift * 2; - fg[1] >>= image_subpixel_shift * 2; - fg[2] >>= image_subpixel_shift * 2; - fg[3] >>= image_subpixel_shift * 2; - } - else - { - if(x_lr < -1 || y_lr < -1 || - x_lr > maxx || y_lr > maxy) - { - fg[order_type::R] = back_r; - fg[order_type::G] = back_g; - fg[order_type::B] = back_b; - fg[order_type::A] = back_a; - } - else - { - fg[0] = - fg[1] = - fg[2] = - fg[3] = image_subpixel_scale * image_subpixel_scale / 2; - - x_hr &= image_subpixel_mask; - y_hr &= image_subpixel_mask; - - weight = (image_subpixel_scale - x_hr) * - (image_subpixel_scale - y_hr); - if(x_lr >= 0 && y_lr >= 0 && - x_lr <= maxx && y_lr <= maxy) - { - fg_ptr = (const value_type*) - base_type::source().row_ptr(y_lr) + (x_lr << 2); - - fg[0] += weight * *fg_ptr++; - fg[1] += weight * *fg_ptr++; - fg[2] += weight * *fg_ptr++; - fg[3] += weight * *fg_ptr++; - } - else - { - fg[order_type::R] += back_r * weight; - fg[order_type::G] += back_g * weight; - fg[order_type::B] += back_b * weight; - fg[order_type::A] += back_a * weight; - } - - x_lr++; - - weight = x_hr * (image_subpixel_scale - y_hr); - if(x_lr >= 0 && y_lr >= 0 && - x_lr <= maxx && y_lr <= maxy) - { - fg_ptr = (const value_type*) - base_type::source().row_ptr(y_lr) + (x_lr << 2); - - fg[0] += weight * *fg_ptr++; - fg[1] += weight * *fg_ptr++; - fg[2] += weight * *fg_ptr++; - fg[3] += weight * *fg_ptr++; - } - else - { - fg[order_type::R] += back_r * weight; - fg[order_type::G] += back_g * weight; - fg[order_type::B] += back_b * weight; - fg[order_type::A] += back_a * weight; - } - - x_lr--; - y_lr++; - - weight = (image_subpixel_scale - x_hr) * y_hr; - if(x_lr >= 0 && y_lr >= 0 && - x_lr <= maxx && y_lr <= maxy) - { - fg_ptr = (const value_type*) - base_type::source().row_ptr(y_lr) + (x_lr << 2); - - fg[0] += weight * *fg_ptr++; - fg[1] += weight * *fg_ptr++; - fg[2] += weight * *fg_ptr++; - fg[3] += weight * *fg_ptr++; - } - else - { - fg[order_type::R] += back_r * weight; - fg[order_type::G] += back_g * weight; - fg[order_type::B] += back_b * weight; - fg[order_type::A] += back_a * weight; - } - - x_lr++; - - weight = x_hr * y_hr; - if(x_lr >= 0 && y_lr >= 0 && - x_lr <= maxx && y_lr <= maxy) - { - fg_ptr = (const value_type*) - base_type::source().row_ptr(y_lr) + (x_lr << 2); - - fg[0] += weight * *fg_ptr++; - fg[1] += weight * *fg_ptr++; - fg[2] += weight * *fg_ptr++; - fg[3] += weight * *fg_ptr++; - } - else - { - fg[order_type::R] += back_r * weight; - fg[order_type::G] += back_g * weight; - fg[order_type::B] += back_b * weight; - fg[order_type::A] += back_a * weight; - } - - fg[0] >>= image_subpixel_shift * 2; - fg[1] >>= image_subpixel_shift * 2; - fg[2] >>= image_subpixel_shift * 2; - fg[3] >>= image_subpixel_shift * 2; - } - } - - span->r = (value_type)fg[order_type::R]; - span->g = (value_type)fg[order_type::G]; - span->b = (value_type)fg[order_type::B]; - span->a = (value_type)fg[order_type::A]; - ++span; - ++base_type::interpolator(); - - } while(--len); - } - private: - color_type m_back_color; - }; - - - //==============================================span_image_filter_rgba_2x2 - template - class span_image_filter_rgba_2x2 : - public span_image_filter - { - public: - typedef Source source_type; - typedef typename source_type::color_type color_type; - typedef typename source_type::order_type order_type; - typedef Interpolator interpolator_type; - typedef span_image_filter base_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - //-------------------------------------------------------------------- - span_image_filter_rgba_2x2() {} - span_image_filter_rgba_2x2(source_type& src, - interpolator_type& inter, - const image_filter_lut& filter) : - base_type(src, inter, &filter) - {} - - - //-------------------------------------------------------------------- - void generate(color_type* span, int x, int y, unsigned len) - { - base_type::interpolator().begin(x + base_type::filter_dx_dbl(), - y + base_type::filter_dy_dbl(), len); - - calc_type fg[4]; - - const value_type *fg_ptr; - const int16* weight_array = base_type::filter().weight_array() + - ((base_type::filter().diameter()/2 - 1) << - image_subpixel_shift); - - do - { - int x_hr; - int y_hr; - - base_type::interpolator().coordinates(&x_hr, &y_hr); - - x_hr -= base_type::filter_dx_int(); - y_hr -= base_type::filter_dy_int(); - - int x_lr = x_hr >> image_subpixel_shift; - int y_lr = y_hr >> image_subpixel_shift; - - unsigned weight; - fg[0] = fg[1] = fg[2] = fg[3] = image_filter_scale / 2; - - x_hr &= image_subpixel_mask; - y_hr &= image_subpixel_mask; - - fg_ptr = (const value_type*)base_type::source().span(x_lr, y_lr, 2); - weight = (weight_array[x_hr + image_subpixel_scale] * - weight_array[y_hr + image_subpixel_scale] + - image_filter_scale / 2) >> - image_filter_shift; - fg[0] += weight * *fg_ptr++; - fg[1] += weight * *fg_ptr++; - fg[2] += weight * *fg_ptr++; - fg[3] += weight * *fg_ptr; - - fg_ptr = (const value_type*)base_type::source().next_x(); - weight = (weight_array[x_hr] * - weight_array[y_hr + image_subpixel_scale] + - image_filter_scale / 2) >> - image_filter_shift; - fg[0] += weight * *fg_ptr++; - fg[1] += weight * *fg_ptr++; - fg[2] += weight * *fg_ptr++; - fg[3] += weight * *fg_ptr; - - fg_ptr = (const value_type*)base_type::source().next_y(); - weight = (weight_array[x_hr + image_subpixel_scale] * - weight_array[y_hr] + - image_filter_scale / 2) >> - image_filter_shift; - fg[0] += weight * *fg_ptr++; - fg[1] += weight * *fg_ptr++; - fg[2] += weight * *fg_ptr++; - fg[3] += weight * *fg_ptr; - - fg_ptr = (const value_type*)base_type::source().next_x(); - weight = (weight_array[x_hr] * - weight_array[y_hr] + - image_filter_scale / 2) >> - image_filter_shift; - fg[0] += weight * *fg_ptr++; - fg[1] += weight * *fg_ptr++; - fg[2] += weight * *fg_ptr++; - fg[3] += weight * *fg_ptr; - - fg[0] >>= image_filter_shift; - fg[1] >>= image_filter_shift; - fg[2] >>= image_filter_shift; - fg[3] >>= image_filter_shift; - - if(fg[order_type::A] > base_mask) fg[order_type::A] = base_mask; - if(fg[order_type::R] > fg[order_type::A]) fg[order_type::R] = fg[order_type::A]; - if(fg[order_type::G] > fg[order_type::A]) fg[order_type::G] = fg[order_type::A]; - if(fg[order_type::B] > fg[order_type::A]) fg[order_type::B] = fg[order_type::A]; - - span->r = (value_type)fg[order_type::R]; - span->g = (value_type)fg[order_type::G]; - span->b = (value_type)fg[order_type::B]; - span->a = (value_type)fg[order_type::A]; - ++span; - ++base_type::interpolator(); - - } while(--len); - } - }; - - - - //==================================================span_image_filter_rgba - template - class span_image_filter_rgba : - public span_image_filter - { - public: - typedef Source source_type; - typedef typename source_type::color_type color_type; - typedef typename source_type::order_type order_type; - typedef Interpolator interpolator_type; - typedef span_image_filter base_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask - }; - - //-------------------------------------------------------------------- - span_image_filter_rgba() {} - span_image_filter_rgba(source_type& src, - interpolator_type& inter, - const image_filter_lut& filter) : - base_type(src, inter, &filter) - {} - - //-------------------------------------------------------------------- - void generate(color_type* span, int x, int y, unsigned len) - { - base_type::interpolator().begin(x + base_type::filter_dx_dbl(), - y + base_type::filter_dy_dbl(), len); - - int fg[4]; - const value_type *fg_ptr; - - unsigned diameter = base_type::filter().diameter(); - int start = base_type::filter().start(); - const int16* weight_array = base_type::filter().weight_array(); - - int x_count; - int weight_y; - - do - { - base_type::interpolator().coordinates(&x, &y); - - x -= base_type::filter_dx_int(); - y -= base_type::filter_dy_int(); - - int x_hr = x; - int y_hr = y; - - int x_lr = x_hr >> image_subpixel_shift; - int y_lr = y_hr >> image_subpixel_shift; - - fg[0] = fg[1] = fg[2] = fg[3] = image_filter_scale / 2; - - int x_fract = x_hr & image_subpixel_mask; - unsigned y_count = diameter; - - y_hr = image_subpixel_mask - (y_hr & image_subpixel_mask); - fg_ptr = (const value_type*)base_type::source().span(x_lr + start, - y_lr + start, - diameter); - for(;;) - { - x_count = diameter; - weight_y = weight_array[y_hr]; - x_hr = image_subpixel_mask - x_fract; - for(;;) - { - int weight = (weight_y * weight_array[x_hr] + - image_filter_scale / 2) >> - image_filter_shift; - - fg[0] += weight * *fg_ptr++; - fg[1] += weight * *fg_ptr++; - fg[2] += weight * *fg_ptr++; - fg[3] += weight * *fg_ptr; - - if(--x_count == 0) break; - x_hr += image_subpixel_scale; - fg_ptr = (const value_type*)base_type::source().next_x(); - } - - if(--y_count == 0) break; - y_hr += image_subpixel_scale; - fg_ptr = (const value_type*)base_type::source().next_y(); - } - - fg[0] >>= image_filter_shift; - fg[1] >>= image_filter_shift; - fg[2] >>= image_filter_shift; - fg[3] >>= image_filter_shift; - - if(fg[0] < 0) fg[0] = 0; - if(fg[1] < 0) fg[1] = 0; - if(fg[2] < 0) fg[2] = 0; - if(fg[3] < 0) fg[3] = 0; - - if(fg[order_type::A] > base_mask) fg[order_type::A] = base_mask; - if(fg[order_type::R] > fg[order_type::A]) fg[order_type::R] = fg[order_type::A]; - if(fg[order_type::G] > fg[order_type::A]) fg[order_type::G] = fg[order_type::A]; - if(fg[order_type::B] > fg[order_type::A]) fg[order_type::B] = fg[order_type::A]; - - span->r = (value_type)fg[order_type::R]; - span->g = (value_type)fg[order_type::G]; - span->b = (value_type)fg[order_type::B]; - span->a = (value_type)fg[order_type::A]; - ++span; - ++base_type::interpolator(); - - } while(--len); - } - }; - - - - //========================================span_image_resample_rgba_affine - template - class span_image_resample_rgba_affine : - public span_image_resample_affine - { - public: - typedef Source source_type; - typedef typename source_type::color_type color_type; - typedef typename source_type::order_type order_type; - typedef span_image_resample_affine base_type; - typedef typename base_type::interpolator_type interpolator_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::long_type long_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask, - downscale_shift = image_filter_shift - }; - - //-------------------------------------------------------------------- - span_image_resample_rgba_affine() {} - span_image_resample_rgba_affine(source_type& src, - interpolator_type& inter, - const image_filter_lut& filter) : - base_type(src, inter, filter) - {} - - - //-------------------------------------------------------------------- - void generate(color_type* span, int x, int y, unsigned len) - { - base_type::interpolator().begin(x + base_type::filter_dx_dbl(), - y + base_type::filter_dy_dbl(), len); - - long_type fg[4]; - - int diameter = base_type::filter().diameter(); - int filter_scale = diameter << image_subpixel_shift; - int radius_x = (diameter * base_type::m_rx) >> 1; - int radius_y = (diameter * base_type::m_ry) >> 1; - int len_x_lr = - (diameter * base_type::m_rx + image_subpixel_mask) >> - image_subpixel_shift; - - const int16* weight_array = base_type::filter().weight_array(); - - do - { - base_type::interpolator().coordinates(&x, &y); - - x += base_type::filter_dx_int() - radius_x; - y += base_type::filter_dy_int() - radius_y; - - fg[0] = fg[1] = fg[2] = fg[3] = image_filter_scale / 2; - - int y_lr = y >> image_subpixel_shift; - int y_hr = ((image_subpixel_mask - (y & image_subpixel_mask)) * - base_type::m_ry_inv) >> - image_subpixel_shift; - int total_weight = 0; - int x_lr = x >> image_subpixel_shift; - int x_hr = ((image_subpixel_mask - (x & image_subpixel_mask)) * - base_type::m_rx_inv) >> - image_subpixel_shift; - - int x_hr2 = x_hr; - const value_type* fg_ptr = - (const value_type*)base_type::source().span(x_lr, y_lr, len_x_lr); - for(;;) - { - int weight_y = weight_array[y_hr]; - x_hr = x_hr2; - for(;;) - { - int weight = (weight_y * weight_array[x_hr] + - image_filter_scale / 2) >> - downscale_shift; - - fg[0] += *fg_ptr++ * weight; - fg[1] += *fg_ptr++ * weight; - fg[2] += *fg_ptr++ * weight; - fg[3] += *fg_ptr++ * weight; - total_weight += weight; - x_hr += base_type::m_rx_inv; - if(x_hr >= filter_scale) break; - fg_ptr = (const value_type*)base_type::source().next_x(); - } - y_hr += base_type::m_ry_inv; - if(y_hr >= filter_scale) break; - fg_ptr = (const value_type*)base_type::source().next_y(); - } - - fg[0] /= total_weight; - fg[1] /= total_weight; - fg[2] /= total_weight; - fg[3] /= total_weight; - - if(fg[0] < 0) fg[0] = 0; - if(fg[1] < 0) fg[1] = 0; - if(fg[2] < 0) fg[2] = 0; - if(fg[3] < 0) fg[3] = 0; - - if(fg[order_type::A] > base_mask) fg[order_type::A] = base_mask; - if(fg[order_type::R] > fg[order_type::A]) fg[order_type::R] = fg[order_type::A]; - if(fg[order_type::G] > fg[order_type::A]) fg[order_type::G] = fg[order_type::A]; - if(fg[order_type::B] > fg[order_type::A]) fg[order_type::B] = fg[order_type::A]; - - span->r = (value_type)fg[order_type::R]; - span->g = (value_type)fg[order_type::G]; - span->b = (value_type)fg[order_type::B]; - span->a = (value_type)fg[order_type::A]; - - ++span; - ++base_type::interpolator(); - } while(--len); - } - }; - - - - //==============================================span_image_resample_rgba - template - class span_image_resample_rgba : - public span_image_resample - { - public: - typedef Source source_type; - typedef typename source_type::color_type color_type; - typedef typename source_type::order_type order_type; - typedef Interpolator interpolator_type; - typedef span_image_resample base_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::long_type long_type; - enum base_scale_e - { - base_shift = color_type::base_shift, - base_mask = color_type::base_mask, - downscale_shift = image_filter_shift - }; - - //-------------------------------------------------------------------- - span_image_resample_rgba() {} - span_image_resample_rgba(source_type& src, - interpolator_type& inter, - const image_filter_lut& filter) : - base_type(src, inter, filter) - {} - - //-------------------------------------------------------------------- - void generate(color_type* span, int x, int y, unsigned len) - { - base_type::interpolator().begin(x + base_type::filter_dx_dbl(), - y + base_type::filter_dy_dbl(), len); - long_type fg[4]; - - int diameter = base_type::filter().diameter(); - int filter_scale = diameter << image_subpixel_shift; - - const int16* weight_array = base_type::filter().weight_array(); - do - { - int rx; - int ry; - int rx_inv = image_subpixel_scale; - int ry_inv = image_subpixel_scale; - base_type::interpolator().coordinates(&x, &y); - base_type::interpolator().local_scale(&rx, &ry); - base_type::adjust_scale(&rx, &ry); - - rx_inv = image_subpixel_scale * image_subpixel_scale / rx; - ry_inv = image_subpixel_scale * image_subpixel_scale / ry; - - int radius_x = (diameter * rx) >> 1; - int radius_y = (diameter * ry) >> 1; - int len_x_lr = - (diameter * rx + image_subpixel_mask) >> - image_subpixel_shift; - - x += base_type::filter_dx_int() - radius_x; - y += base_type::filter_dy_int() - radius_y; - - fg[0] = fg[1] = fg[2] = fg[3] = image_filter_scale / 2; - - int y_lr = y >> image_subpixel_shift; - int y_hr = ((image_subpixel_mask - (y & image_subpixel_mask)) * - ry_inv) >> - image_subpixel_shift; - int total_weight = 0; - int x_lr = x >> image_subpixel_shift; - int x_hr = ((image_subpixel_mask - (x & image_subpixel_mask)) * - rx_inv) >> - image_subpixel_shift; - int x_hr2 = x_hr; - const value_type* fg_ptr = - (const value_type*)base_type::source().span(x_lr, y_lr, len_x_lr); - - for(;;) - { - int weight_y = weight_array[y_hr]; - x_hr = x_hr2; - for(;;) - { - int weight = (weight_y * weight_array[x_hr] + - image_filter_scale / 2) >> - downscale_shift; - fg[0] += *fg_ptr++ * weight; - fg[1] += *fg_ptr++ * weight; - fg[2] += *fg_ptr++ * weight; - fg[3] += *fg_ptr++ * weight; - total_weight += weight; - x_hr += rx_inv; - if(x_hr >= filter_scale) break; - fg_ptr = (const value_type*)base_type::source().next_x(); - } - y_hr += ry_inv; - if(y_hr >= filter_scale) break; - fg_ptr = (const value_type*)base_type::source().next_y(); - } - - fg[0] /= total_weight; - fg[1] /= total_weight; - fg[2] /= total_weight; - fg[3] /= total_weight; - - if(fg[0] < 0) fg[0] = 0; - if(fg[1] < 0) fg[1] = 0; - if(fg[2] < 0) fg[2] = 0; - if(fg[3] < 0) fg[3] = 0; - - if(fg[order_type::A] > base_mask) fg[order_type::A] = base_mask; - if(fg[order_type::R] > fg[order_type::R]) fg[order_type::R] = fg[order_type::R]; - if(fg[order_type::G] > fg[order_type::G]) fg[order_type::G] = fg[order_type::G]; - if(fg[order_type::B] > fg[order_type::B]) fg[order_type::B] = fg[order_type::B]; - - span->r = (value_type)fg[order_type::R]; - span->g = (value_type)fg[order_type::G]; - span->b = (value_type)fg[order_type::B]; - span->a = (value_type)fg[order_type::A]; - - ++span; - ++base_type::interpolator(); - } while(--len); - } - }; - - -} - - -#endif - - - diff --git a/desmume/src/windows/agg/include/agg_span_interpolator_adaptor.h b/desmume/src/windows/agg/include/agg_span_interpolator_adaptor.h deleted file mode 100644 index b3ff22e23..000000000 --- a/desmume/src/windows/agg/include/agg_span_interpolator_adaptor.h +++ /dev/null @@ -1,86 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_SPAN_INTERPOLATOR_ADAPTOR_INCLUDED -#define AGG_SPAN_INTERPOLATOR_ADAPTOR_INCLUDED - -#include "agg_basics.h" - -namespace agg -{ - - //===============================================span_interpolator_adaptor - template - class span_interpolator_adaptor : public Interpolator - { - public: - typedef Interpolator base_type; - typedef typename base_type::trans_type trans_type; - typedef Distortion distortion_type; - - //-------------------------------------------------------------------- - span_interpolator_adaptor() {} - span_interpolator_adaptor(const trans_type& trans, - const distortion_type& dist) : - base_type(trans), - m_distortion(&dist) - { - } - - //-------------------------------------------------------------------- - span_interpolator_adaptor(const trans_type& trans, - const distortion_type& dist, - double x, double y, unsigned len) : - base_type(trans, x, y, len), - m_distortion(&dist) - { - } - - //-------------------------------------------------------------------- - const distortion_type& distortion() const - { - return *m_distortion; - } - - //-------------------------------------------------------------------- - void distortion(const distortion_type& dist) - { - m_distortion = dist; - } - - //-------------------------------------------------------------------- - void coordinates(int* x, int* y) const - { - base_type::coordinates(x, y); - m_distortion->calculate(x, y); - } - - private: - //-------------------------------------------------------------------- - const distortion_type* m_distortion; - }; -} - - -#endif diff --git a/desmume/src/windows/agg/include/agg_span_interpolator_linear.h b/desmume/src/windows/agg/include/agg_span_interpolator_linear.h deleted file mode 100644 index c9bfafdd3..000000000 --- a/desmume/src/windows/agg/include/agg_span_interpolator_linear.h +++ /dev/null @@ -1,241 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_SPAN_INTERPOLATOR_LINEAR_INCLUDED -#define AGG_SPAN_INTERPOLATOR_LINEAR_INCLUDED - -#include "agg_basics.h" -#include "agg_dda_line.h" -#include "agg_trans_affine.h" - -namespace agg -{ - - //================================================span_interpolator_linear - template - class span_interpolator_linear - { - public: - typedef Transformer trans_type; - - enum subpixel_scale_e - { - subpixel_shift = SubpixelShift, - subpixel_scale = 1 << subpixel_shift - }; - - //-------------------------------------------------------------------- - span_interpolator_linear() {} - span_interpolator_linear(const trans_type& trans) : m_trans(&trans) {} - span_interpolator_linear(const trans_type& trans, - double x, double y, unsigned len) : - m_trans(&trans) - { - begin(x, y, len); - } - - //---------------------------------------------------------------- - const trans_type& transformer() const { return *m_trans; } - void transformer(const trans_type& trans) { m_trans = &trans; } - - //---------------------------------------------------------------- - void begin(double x, double y, unsigned len) - { - double tx; - double ty; - - tx = x; - ty = y; - m_trans->transform(&tx, &ty); - int x1 = iround(tx * subpixel_scale); - int y1 = iround(ty * subpixel_scale); - - tx = x + len; - ty = y; - m_trans->transform(&tx, &ty); - int x2 = iround(tx * subpixel_scale); - int y2 = iround(ty * subpixel_scale); - - m_li_x = dda2_line_interpolator(x1, x2, len); - m_li_y = dda2_line_interpolator(y1, y2, len); - } - - //---------------------------------------------------------------- - void resynchronize(double xe, double ye, unsigned len) - { - m_trans->transform(&xe, &ye); - m_li_x = dda2_line_interpolator(m_li_x.y(), iround(xe * subpixel_scale), len); - m_li_y = dda2_line_interpolator(m_li_y.y(), iround(ye * subpixel_scale), len); - } - - //---------------------------------------------------------------- - void operator++() - { - ++m_li_x; - ++m_li_y; - } - - //---------------------------------------------------------------- - void coordinates(int* x, int* y) const - { - *x = m_li_x.y(); - *y = m_li_y.y(); - } - - private: - const trans_type* m_trans; - dda2_line_interpolator m_li_x; - dda2_line_interpolator m_li_y; - }; - - - - - - - //=====================================span_interpolator_linear_subdiv - template - class span_interpolator_linear_subdiv - { - public: - typedef Transformer trans_type; - - enum subpixel_scale_e - { - subpixel_shift = SubpixelShift, - subpixel_scale = 1 << subpixel_shift - }; - - - //---------------------------------------------------------------- - span_interpolator_linear_subdiv() : - m_subdiv_shift(4), - m_subdiv_size(1 << m_subdiv_shift), - m_subdiv_mask(m_subdiv_size - 1) {} - - span_interpolator_linear_subdiv(const trans_type& trans, - unsigned subdiv_shift = 4) : - m_subdiv_shift(subdiv_shift), - m_subdiv_size(1 << m_subdiv_shift), - m_subdiv_mask(m_subdiv_size - 1), - m_trans(&trans) {} - - span_interpolator_linear_subdiv(const trans_type& trans, - double x, double y, unsigned len, - unsigned subdiv_shift = 4) : - m_subdiv_shift(subdiv_shift), - m_subdiv_size(1 << m_subdiv_shift), - m_subdiv_mask(m_subdiv_size - 1), - m_trans(&trans) - { - begin(x, y, len); - } - - //---------------------------------------------------------------- - const trans_type& transformer() const { return *m_trans; } - void transformer(const trans_type& trans) { m_trans = &trans; } - - //---------------------------------------------------------------- - unsigned subdiv_shift() const { return m_subdiv_shift; } - void subdiv_shift(unsigned shift) - { - m_subdiv_shift = shift; - m_subdiv_size = 1 << m_subdiv_shift; - m_subdiv_mask = m_subdiv_size - 1; - } - - //---------------------------------------------------------------- - void begin(double x, double y, unsigned len) - { - double tx; - double ty; - m_pos = 1; - m_src_x = iround(x * subpixel_scale) + subpixel_scale; - m_src_y = y; - m_len = len; - - if(len > m_subdiv_size) len = m_subdiv_size; - tx = x; - ty = y; - m_trans->transform(&tx, &ty); - int x1 = iround(tx * subpixel_scale); - int y1 = iround(ty * subpixel_scale); - - tx = x + len; - ty = y; - m_trans->transform(&tx, &ty); - - m_li_x = dda2_line_interpolator(x1, iround(tx * subpixel_scale), len); - m_li_y = dda2_line_interpolator(y1, iround(ty * subpixel_scale), len); - } - - //---------------------------------------------------------------- - void operator++() - { - ++m_li_x; - ++m_li_y; - if(m_pos >= m_subdiv_size) - { - unsigned len = m_len; - if(len > m_subdiv_size) len = m_subdiv_size; - double tx = double(m_src_x) / double(subpixel_scale) + len; - double ty = m_src_y; - m_trans->transform(&tx, &ty); - m_li_x = dda2_line_interpolator(m_li_x.y(), iround(tx * subpixel_scale), len); - m_li_y = dda2_line_interpolator(m_li_y.y(), iround(ty * subpixel_scale), len); - m_pos = 0; - } - m_src_x += subpixel_scale; - ++m_pos; - --m_len; - } - - //---------------------------------------------------------------- - void coordinates(int* x, int* y) const - { - *x = m_li_x.y(); - *y = m_li_y.y(); - } - - private: - unsigned m_subdiv_shift; - unsigned m_subdiv_size; - unsigned m_subdiv_mask; - const trans_type* m_trans; - dda2_line_interpolator m_li_x; - dda2_line_interpolator m_li_y; - int m_src_x; - double m_src_y; - unsigned m_pos; - unsigned m_len; - }; - - -} - - - -#endif - - diff --git a/desmume/src/windows/agg/include/agg_span_interpolator_persp.h b/desmume/src/windows/agg/include/agg_span_interpolator_persp.h deleted file mode 100644 index 1d9863a43..000000000 --- a/desmume/src/windows/agg/include/agg_span_interpolator_persp.h +++ /dev/null @@ -1,472 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_SPAN_INTERPOLATOR_PERSP_INCLUDED -#define AGG_SPAN_INTERPOLATOR_PERSP_INCLUDED - -#include "agg_trans_perspective.h" -#include "agg_dda_line.h" - -namespace agg -{ - - - - //===========================================span_interpolator_persp_exact - template - class span_interpolator_persp_exact - { - public: - typedef trans_perspective trans_type; - typedef trans_perspective::iterator_x iterator_type; - enum subpixel_scale_e - { - subpixel_shift = SubpixelShift, - subpixel_scale = 1 << subpixel_shift - }; - - //-------------------------------------------------------------------- - span_interpolator_persp_exact() {} - - //-------------------------------------------------------------------- - // Arbitrary quadrangle transformations - span_interpolator_persp_exact(const double* src, const double* dst) - { - quad_to_quad(src, dst); - } - - //-------------------------------------------------------------------- - // Direct transformations - span_interpolator_persp_exact(double x1, double y1, - double x2, double y2, - const double* quad) - { - rect_to_quad(x1, y1, x2, y2, quad); - } - - //-------------------------------------------------------------------- - // Reverse transformations - span_interpolator_persp_exact(const double* quad, - double x1, double y1, - double x2, double y2) - { - quad_to_rect(quad, x1, y1, x2, y2); - } - - //-------------------------------------------------------------------- - // Set the transformations using two arbitrary quadrangles. - void quad_to_quad(const double* src, const double* dst) - { - m_trans_dir.quad_to_quad(src, dst); - m_trans_inv.quad_to_quad(dst, src); - } - - //-------------------------------------------------------------------- - // Set the direct transformations, i.e., rectangle -> quadrangle - void rect_to_quad(double x1, double y1, double x2, double y2, - const double* quad) - { - double src[8]; - src[0] = src[6] = x1; - src[2] = src[4] = x2; - src[1] = src[3] = y1; - src[5] = src[7] = y2; - quad_to_quad(src, quad); - } - - - //-------------------------------------------------------------------- - // Set the reverse transformations, i.e., quadrangle -> rectangle - void quad_to_rect(const double* quad, - double x1, double y1, double x2, double y2) - { - double dst[8]; - dst[0] = dst[6] = x1; - dst[2] = dst[4] = x2; - dst[1] = dst[3] = y1; - dst[5] = dst[7] = y2; - quad_to_quad(quad, dst); - } - - //-------------------------------------------------------------------- - // Check if the equations were solved successfully - bool is_valid() const { return m_trans_dir.is_valid(); } - - //---------------------------------------------------------------- - void begin(double x, double y, unsigned len) - { - m_iterator = m_trans_dir.begin(x, y, 1.0); - double xt = m_iterator.x; - double yt = m_iterator.y; - - double dx; - double dy; - const double delta = 1/double(subpixel_scale); - dx = xt + delta; - dy = yt; - m_trans_inv.transform(&dx, &dy); - dx -= x; - dy -= y; - int sx1 = uround(subpixel_scale/sqrt(dx*dx + dy*dy)) >> subpixel_shift; - dx = xt; - dy = yt + delta; - m_trans_inv.transform(&dx, &dy); - dx -= x; - dy -= y; - int sy1 = uround(subpixel_scale/sqrt(dx*dx + dy*dy)) >> subpixel_shift; - - x += len; - xt = x; - yt = y; - m_trans_dir.transform(&xt, &yt); - - dx = xt + delta; - dy = yt; - m_trans_inv.transform(&dx, &dy); - dx -= x; - dy -= y; - int sx2 = uround(subpixel_scale/sqrt(dx*dx + dy*dy)) >> subpixel_shift; - dx = xt; - dy = yt + delta; - m_trans_inv.transform(&dx, &dy); - dx -= x; - dy -= y; - int sy2 = uround(subpixel_scale/sqrt(dx*dx + dy*dy)) >> subpixel_shift; - - m_scale_x = dda2_line_interpolator(sx1, sx2, len); - m_scale_y = dda2_line_interpolator(sy1, sy2, len); - } - - - //---------------------------------------------------------------- - void resynchronize(double xe, double ye, unsigned len) - { - // Assume x1,y1 are equal to the ones at the previous end point - int sx1 = m_scale_x.y(); - int sy1 = m_scale_y.y(); - - // Calculate transformed coordinates at x2,y2 - double xt = xe; - double yt = ye; - m_trans_dir.transform(&xt, &yt); - - const double delta = 1/double(subpixel_scale); - double dx; - double dy; - - // Calculate scale by X at x2,y2 - dx = xt + delta; - dy = yt; - m_trans_inv.transform(&dx, &dy); - dx -= xe; - dy -= ye; - int sx2 = uround(subpixel_scale/sqrt(dx*dx + dy*dy)) >> subpixel_shift; - - // Calculate scale by Y at x2,y2 - dx = xt; - dy = yt + delta; - m_trans_inv.transform(&dx, &dy); - dx -= xe; - dy -= ye; - int sy2 = uround(subpixel_scale/sqrt(dx*dx + dy*dy)) >> subpixel_shift; - - // Initialize the interpolators - m_scale_x = dda2_line_interpolator(sx1, sx2, len); - m_scale_y = dda2_line_interpolator(sy1, sy2, len); - } - - - - //---------------------------------------------------------------- - void operator++() - { - ++m_iterator; - ++m_scale_x; - ++m_scale_y; - } - - //---------------------------------------------------------------- - void coordinates(int* x, int* y) const - { - *x = iround(m_iterator.x * subpixel_scale); - *y = iround(m_iterator.y * subpixel_scale); - } - - //---------------------------------------------------------------- - void local_scale(int* x, int* y) - { - *x = m_scale_x.y(); - *y = m_scale_y.y(); - } - - //---------------------------------------------------------------- - void transform(double* x, double* y) const - { - m_trans_dir.transform(x, y); - } - - private: - trans_type m_trans_dir; - trans_type m_trans_inv; - iterator_type m_iterator; - dda2_line_interpolator m_scale_x; - dda2_line_interpolator m_scale_y; - }; - - - - - - - - - - - - //============================================span_interpolator_persp_lerp - template - class span_interpolator_persp_lerp - { - public: - typedef trans_perspective trans_type; - enum subpixel_scale_e - { - subpixel_shift = SubpixelShift, - subpixel_scale = 1 << subpixel_shift - }; - - //-------------------------------------------------------------------- - span_interpolator_persp_lerp() {} - - //-------------------------------------------------------------------- - // Arbitrary quadrangle transformations - span_interpolator_persp_lerp(const double* src, const double* dst) - { - quad_to_quad(src, dst); - } - - //-------------------------------------------------------------------- - // Direct transformations - span_interpolator_persp_lerp(double x1, double y1, - double x2, double y2, - const double* quad) - { - rect_to_quad(x1, y1, x2, y2, quad); - } - - //-------------------------------------------------------------------- - // Reverse transformations - span_interpolator_persp_lerp(const double* quad, - double x1, double y1, - double x2, double y2) - { - quad_to_rect(quad, x1, y1, x2, y2); - } - - //-------------------------------------------------------------------- - // Set the transformations using two arbitrary quadrangles. - void quad_to_quad(const double* src, const double* dst) - { - m_trans_dir.quad_to_quad(src, dst); - m_trans_inv.quad_to_quad(dst, src); - } - - //-------------------------------------------------------------------- - // Set the direct transformations, i.e., rectangle -> quadrangle - void rect_to_quad(double x1, double y1, double x2, double y2, - const double* quad) - { - double src[8]; - src[0] = src[6] = x1; - src[2] = src[4] = x2; - src[1] = src[3] = y1; - src[5] = src[7] = y2; - quad_to_quad(src, quad); - } - - - //-------------------------------------------------------------------- - // Set the reverse transformations, i.e., quadrangle -> rectangle - void quad_to_rect(const double* quad, - double x1, double y1, double x2, double y2) - { - double dst[8]; - dst[0] = dst[6] = x1; - dst[2] = dst[4] = x2; - dst[1] = dst[3] = y1; - dst[5] = dst[7] = y2; - quad_to_quad(quad, dst); - } - - //-------------------------------------------------------------------- - // Check if the equations were solved successfully - bool is_valid() const { return m_trans_dir.is_valid(); } - - //---------------------------------------------------------------- - void begin(double x, double y, unsigned len) - { - // Calculate transformed coordinates at x1,y1 - double xt = x; - double yt = y; - m_trans_dir.transform(&xt, &yt); - int x1 = iround(xt * subpixel_scale); - int y1 = iround(yt * subpixel_scale); - - double dx; - double dy; - const double delta = 1/double(subpixel_scale); - - // Calculate scale by X at x1,y1 - dx = xt + delta; - dy = yt; - m_trans_inv.transform(&dx, &dy); - dx -= x; - dy -= y; - int sx1 = uround(subpixel_scale/sqrt(dx*dx + dy*dy)) >> subpixel_shift; - - // Calculate scale by Y at x1,y1 - dx = xt; - dy = yt + delta; - m_trans_inv.transform(&dx, &dy); - dx -= x; - dy -= y; - int sy1 = uround(subpixel_scale/sqrt(dx*dx + dy*dy)) >> subpixel_shift; - - // Calculate transformed coordinates at x2,y2 - x += len; - xt = x; - yt = y; - m_trans_dir.transform(&xt, &yt); - int x2 = iround(xt * subpixel_scale); - int y2 = iround(yt * subpixel_scale); - - // Calculate scale by X at x2,y2 - dx = xt + delta; - dy = yt; - m_trans_inv.transform(&dx, &dy); - dx -= x; - dy -= y; - int sx2 = uround(subpixel_scale/sqrt(dx*dx + dy*dy)) >> subpixel_shift; - - // Calculate scale by Y at x2,y2 - dx = xt; - dy = yt + delta; - m_trans_inv.transform(&dx, &dy); - dx -= x; - dy -= y; - int sy2 = uround(subpixel_scale/sqrt(dx*dx + dy*dy)) >> subpixel_shift; - - // Initialize the interpolators - m_coord_x = dda2_line_interpolator(x1, x2, len); - m_coord_y = dda2_line_interpolator(y1, y2, len); - m_scale_x = dda2_line_interpolator(sx1, sx2, len); - m_scale_y = dda2_line_interpolator(sy1, sy2, len); - } - - - //---------------------------------------------------------------- - void resynchronize(double xe, double ye, unsigned len) - { - // Assume x1,y1 are equal to the ones at the previous end point - int x1 = m_coord_x.y(); - int y1 = m_coord_y.y(); - int sx1 = m_scale_x.y(); - int sy1 = m_scale_y.y(); - - // Calculate transformed coordinates at x2,y2 - double xt = xe; - double yt = ye; - m_trans_dir.transform(&xt, &yt); - int x2 = iround(xt * subpixel_scale); - int y2 = iround(yt * subpixel_scale); - - const double delta = 1/double(subpixel_scale); - double dx; - double dy; - - // Calculate scale by X at x2,y2 - dx = xt + delta; - dy = yt; - m_trans_inv.transform(&dx, &dy); - dx -= xe; - dy -= ye; - int sx2 = uround(subpixel_scale/sqrt(dx*dx + dy*dy)) >> subpixel_shift; - - // Calculate scale by Y at x2,y2 - dx = xt; - dy = yt + delta; - m_trans_inv.transform(&dx, &dy); - dx -= xe; - dy -= ye; - int sy2 = uround(subpixel_scale/sqrt(dx*dx + dy*dy)) >> subpixel_shift; - - // Initialize the interpolators - m_coord_x = dda2_line_interpolator(x1, x2, len); - m_coord_y = dda2_line_interpolator(y1, y2, len); - m_scale_x = dda2_line_interpolator(sx1, sx2, len); - m_scale_y = dda2_line_interpolator(sy1, sy2, len); - } - - - //---------------------------------------------------------------- - void operator++() - { - ++m_coord_x; - ++m_coord_y; - ++m_scale_x; - ++m_scale_y; - } - - //---------------------------------------------------------------- - void coordinates(int* x, int* y) const - { - *x = m_coord_x.y(); - *y = m_coord_y.y(); - } - - //---------------------------------------------------------------- - void local_scale(int* x, int* y) - { - *x = m_scale_x.y(); - *y = m_scale_y.y(); - } - - //---------------------------------------------------------------- - void transform(double* x, double* y) const - { - m_trans_dir.transform(x, y); - } - - private: - trans_type m_trans_dir; - trans_type m_trans_inv; - dda2_line_interpolator m_coord_x; - dda2_line_interpolator m_coord_y; - dda2_line_interpolator m_scale_x; - dda2_line_interpolator m_scale_y; - }; - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_span_interpolator_trans.h b/desmume/src/windows/agg/include/agg_span_interpolator_trans.h deleted file mode 100644 index 0de1c19dc..000000000 --- a/desmume/src/windows/agg/include/agg_span_interpolator_trans.h +++ /dev/null @@ -1,101 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- -// -// Horizontal span interpolator for use with an arbitrary transformer -// The efficiency highly depends on the operations done in the transformer -// -//---------------------------------------------------------------------------- - -#ifndef AGG_SPAN_INTERPOLATOR_TRANS_INCLUDED -#define AGG_SPAN_INTERPOLATOR_TRANS_INCLUDED - -#include "agg_basics.h" - -namespace agg -{ - //=================================================span_interpolator_trans - template - class span_interpolator_trans - { - public: - typedef Transformer trans_type; - enum subpixel_scale_e - { - subpixel_shift = SubpixelShift, - subpixel_scale = 1 << subpixel_shift - }; - - //-------------------------------------------------------------------- - span_interpolator_trans() {} - span_interpolator_trans(const trans_type& trans) : m_trans(&trans) {} - span_interpolator_trans(const trans_type& trans, - double x, double y, unsigned) : - m_trans(&trans) - { - begin(x, y, 0); - } - - //---------------------------------------------------------------- - const trans_type& transformer() const { return *m_trans; } - void transformer(const trans_type& trans) { m_trans = &trans; } - - //---------------------------------------------------------------- - void begin(double x, double y, unsigned) - { - m_x = x; - m_y = y; - m_trans->transform(&x, &y); - m_ix = iround(x * subpixel_scale); - m_iy = iround(y * subpixel_scale); - } - - //---------------------------------------------------------------- - void operator++() - { - m_x += 1.0; - double x = m_x; - double y = m_y; - m_trans->transform(&x, &y); - m_ix = iround(x * subpixel_scale); - m_iy = iround(y * subpixel_scale); - } - - //---------------------------------------------------------------- - void coordinates(int* x, int* y) const - { - *x = m_ix; - *y = m_iy; - } - - private: - const trans_type* m_trans; - double m_x; - double m_y; - int m_ix; - int m_iy; - }; - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_span_pattern_gray.h b/desmume/src/windows/agg/include/agg_span_pattern_gray.h deleted file mode 100644 index 72d2c2708..000000000 --- a/desmume/src/windows/agg/include/agg_span_pattern_gray.h +++ /dev/null @@ -1,102 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- -// -// Adaptation for high precision colors has been sponsored by -// Liberty Technology Systems, Inc., visit http://lib-sys.com -// -// Liberty Technology Systems, Inc. is the provider of -// PostScript and PDF technology for software developers. -// -//---------------------------------------------------------------------------- - - -#ifndef AGG_SPAN_PATTERN_GRAY_INCLUDED -#define AGG_SPAN_PATTERN_GRAY_INCLUDED - -#include "agg_basics.h" - -namespace agg -{ - - //=======================================================span_pattern_gray - template class span_pattern_gray - { - public: - typedef Source source_type; - typedef typename source_type::color_type color_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - - //-------------------------------------------------------------------- - span_pattern_gray() {} - span_pattern_gray(source_type& src, - unsigned offset_x, unsigned offset_y) : - m_src(&src), - m_offset_x(offset_x), - m_offset_y(offset_y), - m_alpha(color_type::base_mask) - {} - - //-------------------------------------------------------------------- - void attach(source_type& v) { m_src = &v; } - source_type& source() { return *m_src; } - const source_type& source() const { return *m_src; } - - //-------------------------------------------------------------------- - void offset_x(unsigned v) { m_offset_x = v; } - void offset_y(unsigned v) { m_offset_y = v; } - unsigned offset_x() const { return m_offset_x; } - unsigned offset_y() const { return m_offset_y; } - void alpha(value_type v) { m_alpha = v; } - value_type alpha() const { return m_alpha; } - - //-------------------------------------------------------------------- - void prepare() {} - void generate(color_type* span, int x, int y, unsigned len) - { - x += m_offset_x; - y += m_offset_y; - const value_type* p = (const value_type*)m_src->span(x, y, len); - do - { - span->v = *p; - span->a = m_alpha; - p = m_src->next_x(); - ++span; - } - while(--len); - } - - private: - source_type* m_src; - unsigned m_offset_x; - unsigned m_offset_y; - value_type m_alpha; - - }; - -} - -#endif - diff --git a/desmume/src/windows/agg/include/agg_span_pattern_rgb.h b/desmume/src/windows/agg/include/agg_span_pattern_rgb.h deleted file mode 100644 index a2e272f0b..000000000 --- a/desmume/src/windows/agg/include/agg_span_pattern_rgb.h +++ /dev/null @@ -1,105 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- -// -// Adaptation for high precision colors has been sponsored by -// Liberty Technology Systems, Inc., visit http://lib-sys.com -// -// Liberty Technology Systems, Inc. is the provider of -// PostScript and PDF technology for software developers. -// -//---------------------------------------------------------------------------- - - -#ifndef AGG_SPAN_PATTERN_RGB_INCLUDED -#define AGG_SPAN_PATTERN_RGB_INCLUDED - -#include "agg_basics.h" - -namespace agg -{ - - //========================================================span_pattern_rgb - template class span_pattern_rgb - { - public: - typedef Source source_type; - typedef typename source_type::color_type color_type; - typedef typename source_type::order_type order_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - - //-------------------------------------------------------------------- - span_pattern_rgb() {} - span_pattern_rgb(source_type& src, - unsigned offset_x, unsigned offset_y) : - m_src(&src), - m_offset_x(offset_x), - m_offset_y(offset_y), - m_alpha(color_type::base_mask) - {} - - //-------------------------------------------------------------------- - void attach(source_type& v) { m_src = &v; } - source_type& source() { return *m_src; } - const source_type& source() const { return *m_src; } - - //-------------------------------------------------------------------- - void offset_x(unsigned v) { m_offset_x = v; } - void offset_y(unsigned v) { m_offset_y = v; } - unsigned offset_x() const { return m_offset_x; } - unsigned offset_y() const { return m_offset_y; } - void alpha(value_type v) { m_alpha = v; } - value_type alpha() const { return m_alpha; } - - //-------------------------------------------------------------------- - void prepare() {} - void generate(color_type* span, int x, int y, unsigned len) - { - x += m_offset_x; - y += m_offset_y; - const value_type* p = (const value_type*)m_src->span(x, y, len); - do - { - span->r = p[order_type::R]; - span->g = p[order_type::G]; - span->b = p[order_type::B]; - span->a = m_alpha; - p = m_src->next_x(); - ++span; - } - while(--len); - } - - private: - source_type* m_src; - unsigned m_offset_x; - unsigned m_offset_y; - value_type m_alpha; - - }; - -} - -#endif - diff --git a/desmume/src/windows/agg/include/agg_span_pattern_rgba.h b/desmume/src/windows/agg/include/agg_span_pattern_rgba.h deleted file mode 100644 index 248ae265c..000000000 --- a/desmume/src/windows/agg/include/agg_span_pattern_rgba.h +++ /dev/null @@ -1,103 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- -// -// Adaptation for high precision colors has been sponsored by -// Liberty Technology Systems, Inc., visit http://lib-sys.com -// -// Liberty Technology Systems, Inc. is the provider of -// PostScript and PDF technology for software developers. -// -//---------------------------------------------------------------------------- - - -#ifndef AGG_SPAN_PATTERN_RGBA_INCLUDED -#define AGG_SPAN_PATTERN_RGBA_INCLUDED - -#include "agg_basics.h" - -namespace agg -{ - - //======================================================span_pattern_rgba - template class span_pattern_rgba - { - public: - typedef Source source_type; - typedef typename source_type::color_type color_type; - typedef typename source_type::order_type order_type; - typedef typename color_type::value_type value_type; - typedef typename color_type::calc_type calc_type; - - //-------------------------------------------------------------------- - span_pattern_rgba() {} - span_pattern_rgba(source_type& src, - unsigned offset_x, unsigned offset_y) : - m_src(&src), - m_offset_x(offset_x), - m_offset_y(offset_y) - {} - - //-------------------------------------------------------------------- - void attach(source_type& v) { m_src = &v; } - source_type& source() { return *m_src; } - const source_type& source() const { return *m_src; } - - //-------------------------------------------------------------------- - void offset_x(unsigned v) { m_offset_x = v; } - void offset_y(unsigned v) { m_offset_y = v; } - unsigned offset_x() const { return m_offset_x; } - unsigned offset_y() const { return m_offset_y; } - void alpha(value_type) {} - value_type alpha() const { return 0; } - - //-------------------------------------------------------------------- - void prepare() {} - void generate(color_type* span, int x, int y, unsigned len) - { - x += m_offset_x; - y += m_offset_y; - const value_type* p = (const value_type*)m_src->span(x, y, len); - do - { - span->r = p[order_type::R]; - span->g = p[order_type::G]; - span->b = p[order_type::B]; - span->a = p[order_type::A]; - p = (const value_type*)m_src->next_x(); - ++span; - } - while(--len); - } - - private: - source_type* m_src; - unsigned m_offset_x; - unsigned m_offset_y; - - }; - -} - -#endif - diff --git a/desmume/src/windows/agg/include/agg_span_solid.h b/desmume/src/windows/agg/include/agg_span_solid.h deleted file mode 100644 index f82f5dc2c..000000000 --- a/desmume/src/windows/agg/include/agg_span_solid.h +++ /dev/null @@ -1,58 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_SPAN_SOLID_INCLUDED -#define AGG_SPAN_SOLID_INCLUDED - -#include "agg_basics.h" - -namespace agg -{ - //--------------------------------------------------------------span_solid - template class span_solid - { - public: - typedef ColorT color_type; - - //-------------------------------------------------------------------- - void color(const color_type& c) { m_color = c; } - const color_type& color() const { return m_color; } - - //-------------------------------------------------------------------- - void prepare() {} - - //-------------------------------------------------------------------- - void generate(color_type* span, int x, int y, unsigned len) - { - do { *span++ = m_color; } while(--len); - } - - private: - color_type m_color; - }; - - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_span_subdiv_adaptor.h b/desmume/src/windows/agg/include/agg_span_subdiv_adaptor.h deleted file mode 100644 index 5edab67b6..000000000 --- a/desmume/src/windows/agg/include/agg_span_subdiv_adaptor.h +++ /dev/null @@ -1,151 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_SPAN_SUBDIV_ADAPTOR_INCLUDED -#define AGG_SPAN_SUBDIV_ADAPTOR_INCLUDED - -#include "agg_basics.h" - -namespace agg -{ - - //=================================================span_subdiv_adaptor - template - class span_subdiv_adaptor - { - public: - typedef Interpolator interpolator_type; - typedef typename interpolator_type::trans_type trans_type; - - enum sublixel_scale_e - { - subpixel_shift = SubpixelShift, - subpixel_scale = 1 << subpixel_shift - }; - - - //---------------------------------------------------------------- - span_subdiv_adaptor() : - m_subdiv_shift(4), - m_subdiv_size(1 << m_subdiv_shift), - m_subdiv_mask(m_subdiv_size - 1) {} - - span_subdiv_adaptor(interpolator_type& interpolator, - unsigned subdiv_shift = 4) : - m_subdiv_shift(subdiv_shift), - m_subdiv_size(1 << m_subdiv_shift), - m_subdiv_mask(m_subdiv_size - 1), - m_interpolator(&interpolator) {} - - span_subdiv_adaptor(interpolator_type& interpolator, - double x, double y, unsigned len, - unsigned subdiv_shift = 4) : - m_subdiv_shift(subdiv_shift), - m_subdiv_size(1 << m_subdiv_shift), - m_subdiv_mask(m_subdiv_size - 1), - m_interpolator(&interpolator) - { - begin(x, y, len); - } - - - //---------------------------------------------------------------- - const interpolator_type& interpolator() const { return *m_interpolator; } - void interpolator(interpolator_type& intr) { m_interpolator = &intr; } - - //---------------------------------------------------------------- - const trans_type& transformer() const - { - return *m_interpolator->transformer(); - } - void transformer(const trans_type& trans) - { - m_interpolator->transformer(trans); - } - - //---------------------------------------------------------------- - unsigned subdiv_shift() const { return m_subdiv_shift; } - void subdiv_shift(unsigned shift) - { - m_subdiv_shift = shift; - m_subdiv_size = 1 << m_subdiv_shift; - m_subdiv_mask = m_subdiv_size - 1; - } - - //---------------------------------------------------------------- - void begin(double x, double y, unsigned len) - { - m_pos = 1; - m_src_x = iround(x * subpixel_scale) + subpixel_scale; - m_src_y = y; - m_len = len; - if(len > m_subdiv_size) len = m_subdiv_size; - m_interpolator->begin(x, y, len); - } - - //---------------------------------------------------------------- - void operator++() - { - ++(*m_interpolator); - if(m_pos >= m_subdiv_size) - { - unsigned len = m_len; - if(len > m_subdiv_size) len = m_subdiv_size; - m_interpolator->resynchronize(double(m_src_x) / double(subpixel_scale) + len, - m_src_y, - len); - m_pos = 0; - } - m_src_x += subpixel_scale; - ++m_pos; - --m_len; - } - - //---------------------------------------------------------------- - void coordinates(int* x, int* y) const - { - m_interpolator->coordinates(x, y); - } - - //---------------------------------------------------------------- - void local_scale(int* x, int* y) const - { - m_interpolator->local_scale(x, y); - } - - - private: - unsigned m_subdiv_shift; - unsigned m_subdiv_size; - unsigned m_subdiv_mask; - interpolator_type* m_interpolator; - int m_src_x; - double m_src_y; - unsigned m_pos; - unsigned m_len; - }; - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_trans_affine.h b/desmume/src/windows/agg/include/agg_trans_affine.h deleted file mode 100644 index a9d2bd0a3..000000000 --- a/desmume/src/windows/agg/include/agg_trans_affine.h +++ /dev/null @@ -1,524 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_TRANS_AFFINE_INCLUDED -#define AGG_TRANS_AFFINE_INCLUDED - -#include -#include "agg_basics.h" - -namespace agg -{ - const double affine_epsilon = 1e-14; - - //============================================================trans_affine - // - // See Implementation agg_trans_affine.cpp - // - // Affine transformation are linear transformations in Cartesian coordinates - // (strictly speaking not only in Cartesian, but for the beginning we will - // think so). They are rotation, scaling, translation and skewing. - // After any affine transformation a line segment remains a line segment - // and it will never become a curve. - // - // There will be no math about matrix calculations, since it has been - // described many times. Ask yourself a very simple question: - // "why do we need to understand and use some matrix stuff instead of just - // rotating, scaling and so on". The answers are: - // - // 1. Any combination of transformations can be done by only 4 multiplications - // and 4 additions in floating point. - // 2. One matrix transformation is equivalent to the number of consecutive - // discrete transformations, i.e. the matrix "accumulates" all transformations - // in the order of their settings. Suppose we have 4 transformations: - // * rotate by 30 degrees, - // * scale X to 2.0, - // * scale Y to 1.5, - // * move to (100, 100). - // The result will depend on the order of these transformations, - // and the advantage of matrix is that the sequence of discret calls: - // rotate(30), scaleX(2.0), scaleY(1.5), move(100,100) - // will have exactly the same result as the following matrix transformations: - // - // affine_matrix m; - // m *= rotate_matrix(30); - // m *= scaleX_matrix(2.0); - // m *= scaleY_matrix(1.5); - // m *= move_matrix(100,100); - // - // m.transform_my_point_at_last(x, y); - // - // What is the good of it? In real life we will set-up the matrix only once - // and then transform many points, let alone the convenience to set any - // combination of transformations. - // - // So, how to use it? Very easy - literally as it's shown above. Not quite, - // let us write a correct example: - // - // agg::trans_affine m; - // m *= agg::trans_affine_rotation(30.0 * 3.1415926 / 180.0); - // m *= agg::trans_affine_scaling(2.0, 1.5); - // m *= agg::trans_affine_translation(100.0, 100.0); - // m.transform(&x, &y); - // - // The affine matrix is all you need to perform any linear transformation, - // but all transformations have origin point (0,0). It means that we need to - // use 2 translations if we want to rotate someting around (100,100): - // - // m *= agg::trans_affine_translation(-100.0, -100.0); // move to (0,0) - // m *= agg::trans_affine_rotation(30.0 * 3.1415926 / 180.0); // rotate - // m *= agg::trans_affine_translation(100.0, 100.0); // move back to (100,100) - //---------------------------------------------------------------------- - struct trans_affine - { - double sx, shy, shx, sy, tx, ty; - - //------------------------------------------ Construction - // Identity matrix - trans_affine() : - sx(1.0), shy(0.0), shx(0.0), sy(1.0), tx(0.0), ty(0.0) - {} - - // Custom matrix. Usually used in derived classes - trans_affine(double v0, double v1, double v2, - double v3, double v4, double v5) : - sx(v0), shy(v1), shx(v2), sy(v3), tx(v4), ty(v5) - {} - - // Custom matrix from m[6] - explicit trans_affine(const double* m) : - sx(m[0]), shy(m[1]), shx(m[2]), sy(m[3]), tx(m[4]), ty(m[5]) - {} - - // Rectangle to a parallelogram. - trans_affine(double x1, double y1, double x2, double y2, - const double* parl) - { - rect_to_parl(x1, y1, x2, y2, parl); - } - - // Parallelogram to a rectangle. - trans_affine(const double* parl, - double x1, double y1, double x2, double y2) - { - parl_to_rect(parl, x1, y1, x2, y2); - } - - // Arbitrary parallelogram transformation. - trans_affine(const double* src, const double* dst) - { - parl_to_parl(src, dst); - } - - //---------------------------------- Parellelogram transformations - // transform a parallelogram to another one. Src and dst are - // pointers to arrays of three points (double[6], x1,y1,...) that - // identify three corners of the parallelograms assuming implicit - // fourth point. The arguments are arrays of double[6] mapped - // to x1,y1, x2,y2, x3,y3 where the coordinates are: - // *-----------------* - // / (x3,y3)/ - // / / - // /(x1,y1) (x2,y2)/ - // *-----------------* - const trans_affine& parl_to_parl(const double* src, - const double* dst); - - const trans_affine& rect_to_parl(double x1, double y1, - double x2, double y2, - const double* parl); - - const trans_affine& parl_to_rect(const double* parl, - double x1, double y1, - double x2, double y2); - - - //------------------------------------------ Operations - // Reset - load an identity matrix - const trans_affine& reset(); - - // Direct transformations operations - const trans_affine& translate(double x, double y); - const trans_affine& rotate(double a); - const trans_affine& scale(double s); - const trans_affine& scale(double x, double y); - - // Multiply matrix to another one - const trans_affine& multiply(const trans_affine& m); - - // Multiply "m" to "this" and assign the result to "this" - const trans_affine& premultiply(const trans_affine& m); - - // Multiply matrix to inverse of another one - const trans_affine& multiply_inv(const trans_affine& m); - - // Multiply inverse of "m" to "this" and assign the result to "this" - const trans_affine& premultiply_inv(const trans_affine& m); - - // Invert matrix. Do not try to invert degenerate matrices, - // there's no check for validity. If you set scale to 0 and - // then try to invert matrix, expect unpredictable result. - const trans_affine& invert(); - - // Mirroring around X - const trans_affine& flip_x(); - - // Mirroring around Y - const trans_affine& flip_y(); - - //------------------------------------------- Load/Store - // Store matrix to an array [6] of double - void store_to(double* m) const - { - *m++ = sx; *m++ = shy; *m++ = shx; *m++ = sy; *m++ = tx; *m++ = ty; - } - - // Load matrix from an array [6] of double - const trans_affine& load_from(const double* m) - { - sx = *m++; shy = *m++; shx = *m++; sy = *m++; tx = *m++; ty = *m++; - return *this; - } - - //------------------------------------------- Operators - - // Multiply the matrix by another one - const trans_affine& operator *= (const trans_affine& m) - { - return multiply(m); - } - - // Multiply the matrix by inverse of another one - const trans_affine& operator /= (const trans_affine& m) - { - return multiply_inv(m); - } - - // Multiply the matrix by another one and return - // the result in a separete matrix. - trans_affine operator * (const trans_affine& m) - { - return trans_affine(*this).multiply(m); - } - - // Multiply the matrix by inverse of another one - // and return the result in a separete matrix. - trans_affine operator / (const trans_affine& m) - { - return trans_affine(*this).multiply_inv(m); - } - - // Calculate and return the inverse matrix - trans_affine operator ~ () const - { - trans_affine ret = *this; - return ret.invert(); - } - - // Equal operator with default epsilon - bool operator == (const trans_affine& m) const - { - return is_equal(m, affine_epsilon); - } - - // Not Equal operator with default epsilon - bool operator != (const trans_affine& m) const - { - return !is_equal(m, affine_epsilon); - } - - //-------------------------------------------- Transformations - // Direct transformation of x and y - void transform(double* x, double* y) const; - - // Direct transformation of x and y, 2x2 matrix only, no translation - void transform_2x2(double* x, double* y) const; - - // Inverse transformation of x and y. It works slower than the - // direct transformation. For massive operations it's better to - // invert() the matrix and then use direct transformations. - void inverse_transform(double* x, double* y) const; - - //-------------------------------------------- Auxiliary - // Calculate the determinant of matrix - double determinant() const - { - return sx * sy - shy * shx; - } - - // Calculate the reciprocal of the determinant - double determinant_reciprocal() const - { - return 1.0 / (sx * sy - shy * shx); - } - - // Get the average scale (by X and Y). - // Basically used to calculate the approximation_scale when - // decomposinting curves into line segments. - double scale() const; - - // Check to see if the matrix is not degenerate - bool is_valid(double epsilon = affine_epsilon) const; - - // Check to see if it's an identity matrix - bool is_identity(double epsilon = affine_epsilon) const; - - // Check to see if two matrices are equal - bool is_equal(const trans_affine& m, double epsilon = affine_epsilon) const; - - // Determine the major parameters. Use with caution considering - // possible degenerate cases. - double rotation() const; - void translation(double* dx, double* dy) const; - void scaling(double* x, double* y) const; - void scaling_abs(double* x, double* y) const; - }; - - //------------------------------------------------------------------------ - inline void trans_affine::transform(double* x, double* y) const - { - register double tmp = *x; - *x = tmp * sx + *y * shx + tx; - *y = tmp * shy + *y * sy + ty; - } - - //------------------------------------------------------------------------ - inline void trans_affine::transform_2x2(double* x, double* y) const - { - register double tmp = *x; - *x = tmp * sx + *y * shx; - *y = tmp * shy + *y * sy; - } - - //------------------------------------------------------------------------ - inline void trans_affine::inverse_transform(double* x, double* y) const - { - register double d = determinant_reciprocal(); - register double a = (*x - tx) * d; - register double b = (*y - ty) * d; - *x = a * sy - b * shx; - *y = b * sx - a * shy; - } - - //------------------------------------------------------------------------ - inline double trans_affine::scale() const - { - double x = 0.707106781 * sx + 0.707106781 * shx; - double y = 0.707106781 * shy + 0.707106781 * sy; - return sqrt(x*x + y*y); - } - - //------------------------------------------------------------------------ - inline const trans_affine& trans_affine::translate(double x, double y) - { - tx += x; - ty += y; - return *this; - } - - //------------------------------------------------------------------------ - inline const trans_affine& trans_affine::rotate(double a) - { - double ca = cos(a); - double sa = sin(a); - double t0 = sx * ca - shy * sa; - double t2 = shx * ca - sy * sa; - double t4 = tx * ca - ty * sa; - shy = sx * sa + shy * ca; - sy = shx * sa + sy * ca; - ty = tx * sa + ty * ca; - sx = t0; - shx = t2; - tx = t4; - return *this; - } - - //------------------------------------------------------------------------ - inline const trans_affine& trans_affine::scale(double x, double y) - { - double mm0 = x; // Possible hint for the optimizer - double mm3 = y; - sx *= mm0; - shx *= mm0; - tx *= mm0; - shy *= mm3; - sy *= mm3; - ty *= mm3; - return *this; - } - - //------------------------------------------------------------------------ - inline const trans_affine& trans_affine::scale(double s) - { - double m = s; // Possible hint for the optimizer - sx *= m; - shx *= m; - tx *= m; - shy *= m; - sy *= m; - ty *= m; - return *this; - } - - //------------------------------------------------------------------------ - inline const trans_affine& trans_affine::premultiply(const trans_affine& m) - { - trans_affine t = m; - return *this = t.multiply(*this); - } - - //------------------------------------------------------------------------ - inline const trans_affine& trans_affine::multiply_inv(const trans_affine& m) - { - trans_affine t = m; - t.invert(); - return multiply(t); - } - - //------------------------------------------------------------------------ - inline const trans_affine& trans_affine::premultiply_inv(const trans_affine& m) - { - trans_affine t = m; - t.invert(); - return *this = t.multiply(*this); - } - - //------------------------------------------------------------------------ - inline void trans_affine::scaling_abs(double* x, double* y) const - { - // Used to calculate scaling coefficients in image resampling. - // When there is considerable shear this method gives us much - // better estimation than just sx, sy. - *x = sqrt(sx * sx + shx * shx); - *y = sqrt(shy * shy + sy * sy); - } - - //====================================================trans_affine_rotation - // Rotation matrix. sin() and cos() are calculated twice for the same angle. - // There's no harm because the performance of sin()/cos() is very good on all - // modern processors. Besides, this operation is not going to be invoked too - // often. - class trans_affine_rotation : public trans_affine - { - public: - trans_affine_rotation(double a) : - trans_affine(cos(a), sin(a), -sin(a), cos(a), 0.0, 0.0) - {} - }; - - //====================================================trans_affine_scaling - // Scaling matrix. x, y - scale coefficients by X and Y respectively - class trans_affine_scaling : public trans_affine - { - public: - trans_affine_scaling(double x, double y) : - trans_affine(x, 0.0, 0.0, y, 0.0, 0.0) - {} - - trans_affine_scaling(double s) : - trans_affine(s, 0.0, 0.0, s, 0.0, 0.0) - {} - }; - - //================================================trans_affine_translation - // Translation matrix - class trans_affine_translation : public trans_affine - { - public: - trans_affine_translation(double x, double y) : - trans_affine(1.0, 0.0, 0.0, 1.0, x, y) - {} - }; - - //====================================================trans_affine_skewing - // Sckewing (shear) matrix - class trans_affine_skewing : public trans_affine - { - public: - trans_affine_skewing(double x, double y) : - trans_affine(1.0, tan(y), tan(x), 1.0, 0.0, 0.0) - {} - }; - - - //===============================================trans_affine_line_segment - // Rotate, Scale and Translate, associating 0...dist with line segment - // x1,y1,x2,y2 - class trans_affine_line_segment : public trans_affine - { - public: - trans_affine_line_segment(double x1, double y1, double x2, double y2, - double dist) - { - double dx = x2 - x1; - double dy = y2 - y1; - if(dist > 0.0) - { - multiply(trans_affine_scaling(sqrt(dx * dx + dy * dy) / dist)); - } - multiply(trans_affine_rotation(atan2(dy, dx))); - multiply(trans_affine_translation(x1, y1)); - } - }; - - - //============================================trans_affine_reflection_unit - // Reflection matrix. Reflect coordinates across the line through - // the origin containing the unit vector (ux, uy). - // Contributed by John Horigan - class trans_affine_reflection_unit : public trans_affine - { - public: - trans_affine_reflection_unit(double ux, double uy) : - trans_affine(2.0 * ux * ux - 1.0, - 2.0 * ux * uy, - 2.0 * ux * uy, - 2.0 * uy * uy - 1.0, - 0.0, 0.0) - {} - }; - - - //=================================================trans_affine_reflection - // Reflection matrix. Reflect coordinates across the line through - // the origin at the angle a or containing the non-unit vector (x, y). - // Contributed by John Horigan - class trans_affine_reflection : public trans_affine_reflection_unit - { - public: - trans_affine_reflection(double a) : - trans_affine_reflection_unit(cos(a), sin(a)) - {} - - - trans_affine_reflection(double x, double y) : - trans_affine_reflection_unit(x / sqrt(x * x + y * y), y / sqrt(x * x + y * y)) - {} - }; - -} - - -#endif - diff --git a/desmume/src/windows/agg/include/agg_trans_bilinear.h b/desmume/src/windows/agg/include/agg_trans_bilinear.h deleted file mode 100644 index 215026224..000000000 --- a/desmume/src/windows/agg/include/agg_trans_bilinear.h +++ /dev/null @@ -1,172 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_TRANS_BILINEAR_INCLUDED -#define AGG_TRANS_BILINEAR_INCLUDED - -#include "agg_basics.h" -#include "agg_simul_eq.h" - -namespace agg -{ - - //==========================================================trans_bilinear - class trans_bilinear - { - public: - //-------------------------------------------------------------------- - trans_bilinear() : m_valid(false) {} - - //-------------------------------------------------------------------- - // Arbitrary quadrangle transformations - trans_bilinear(const double* src, const double* dst) - { - quad_to_quad(src, dst); - } - - - //-------------------------------------------------------------------- - // Direct transformations - trans_bilinear(double x1, double y1, double x2, double y2, - const double* quad) - { - rect_to_quad(x1, y1, x2, y2, quad); - } - - - //-------------------------------------------------------------------- - // Reverse transformations - trans_bilinear(const double* quad, - double x1, double y1, double x2, double y2) - { - quad_to_rect(quad, x1, y1, x2, y2); - } - - - //-------------------------------------------------------------------- - // Set the transformations using two arbitrary quadrangles. - void quad_to_quad(const double* src, const double* dst) - { - double left[4][4]; - double right[4][2]; - - unsigned i; - for(i = 0; i < 4; i++) - { - unsigned ix = i * 2; - unsigned iy = ix + 1; - left[i][0] = 1.0; - left[i][1] = src[ix] * src[iy]; - left[i][2] = src[ix]; - left[i][3] = src[iy]; - - right[i][0] = dst[ix]; - right[i][1] = dst[iy]; - } - m_valid = simul_eq<4, 2>::solve(left, right, m_mtx); - } - - - //-------------------------------------------------------------------- - // Set the direct transformations, i.e., rectangle -> quadrangle - void rect_to_quad(double x1, double y1, double x2, double y2, - const double* quad) - { - double src[8]; - src[0] = src[6] = x1; - src[2] = src[4] = x2; - src[1] = src[3] = y1; - src[5] = src[7] = y2; - quad_to_quad(src, quad); - } - - - //-------------------------------------------------------------------- - // Set the reverse transformations, i.e., quadrangle -> rectangle - void quad_to_rect(const double* quad, - double x1, double y1, double x2, double y2) - { - double dst[8]; - dst[0] = dst[6] = x1; - dst[2] = dst[4] = x2; - dst[1] = dst[3] = y1; - dst[5] = dst[7] = y2; - quad_to_quad(quad, dst); - } - - //-------------------------------------------------------------------- - // Check if the equations were solved successfully - bool is_valid() const { return m_valid; } - - //-------------------------------------------------------------------- - // Transform a point (x, y) - void transform(double* x, double* y) const - { - double tx = *x; - double ty = *y; - double xy = tx * ty; - *x = m_mtx[0][0] + m_mtx[1][0] * xy + m_mtx[2][0] * tx + m_mtx[3][0] * ty; - *y = m_mtx[0][1] + m_mtx[1][1] * xy + m_mtx[2][1] * tx + m_mtx[3][1] * ty; - } - - - //-------------------------------------------------------------------- - class iterator_x - { - double inc_x; - double inc_y; - - public: - double x; - double y; - - iterator_x() {} - iterator_x(double tx, double ty, double step, const double m[4][2]) : - inc_x(m[1][0] * step * ty + m[2][0] * step), - inc_y(m[1][1] * step * ty + m[2][1] * step), - x(m[0][0] + m[1][0] * tx * ty + m[2][0] * tx + m[3][0] * ty), - y(m[0][1] + m[1][1] * tx * ty + m[2][1] * tx + m[3][1] * ty) - { - } - - void operator ++ () - { - x += inc_x; - y += inc_y; - } - }; - - iterator_x begin(double x, double y, double step) const - { - return iterator_x(x, y, step, m_mtx); - } - - private: - double m_mtx[4][2]; - bool m_valid; - }; - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_trans_double_path.h b/desmume/src/windows/agg/include/agg_trans_double_path.h deleted file mode 100644 index 736e921b7..000000000 --- a/desmume/src/windows/agg/include/agg_trans_double_path.h +++ /dev/null @@ -1,140 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_TRANS_DOUBLE_PATH_INCLUDED -#define AGG_TRANS_DOUBLE_PATH_INCLUDED - -#include "agg_basics.h" -#include "agg_vertex_sequence.h" - -namespace agg -{ - - // See also: agg_trans_double_path.cpp - // - //-------------------------------------------------------trans_double_path - class trans_double_path - { - enum status_e - { - initial, - making_path, - ready - }; - - public: - typedef vertex_sequence vertex_storage; - - trans_double_path(); - - //-------------------------------------------------------------------- - void base_length(double v) { m_base_length = v; } - double base_length() const { return m_base_length; } - - //-------------------------------------------------------------------- - void base_height(double v) { m_base_height = v; } - double base_height() const { return m_base_height; } - - //-------------------------------------------------------------------- - void preserve_x_scale(bool f) { m_preserve_x_scale = f; } - bool preserve_x_scale() const { return m_preserve_x_scale; } - - //-------------------------------------------------------------------- - void reset(); - void move_to1(double x, double y); - void line_to1(double x, double y); - void move_to2(double x, double y); - void line_to2(double x, double y); - void finalize_paths(); - - //-------------------------------------------------------------------- - template - void add_paths(VertexSource1& vs1, VertexSource2& vs2, - unsigned path1_id=0, unsigned path2_id=0) - { - double x; - double y; - - unsigned cmd; - - vs1.rewind(path1_id); - while(!is_stop(cmd = vs1.vertex(&x, &y))) - { - if(is_move_to(cmd)) - { - move_to1(x, y); - } - else - { - if(is_vertex(cmd)) - { - line_to1(x, y); - } - } - } - - vs2.rewind(path2_id); - while(!is_stop(cmd = vs2.vertex(&x, &y))) - { - if(is_move_to(cmd)) - { - move_to2(x, y); - } - else - { - if(is_vertex(cmd)) - { - line_to2(x, y); - } - } - } - finalize_paths(); - } - - //-------------------------------------------------------------------- - double total_length1() const; - double total_length2() const; - void transform(double *x, double *y) const; - - private: - double finalize_path(vertex_storage& vertices); - void transform1(const vertex_storage& vertices, - double kindex, double kx, - double *x, double* y) const; - - vertex_storage m_src_vertices1; - vertex_storage m_src_vertices2; - double m_base_length; - double m_base_height; - double m_kindex1; - double m_kindex2; - status_e m_status1; - status_e m_status2; - bool m_preserve_x_scale; - }; - -} - - -#endif diff --git a/desmume/src/windows/agg/include/agg_trans_perspective.h b/desmume/src/windows/agg/include/agg_trans_perspective.h deleted file mode 100644 index 48b9ac8af..000000000 --- a/desmume/src/windows/agg/include/agg_trans_perspective.h +++ /dev/null @@ -1,737 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_TRANS_PERSPECTIVE_INCLUDED -#define AGG_TRANS_PERSPECTIVE_INCLUDED - -#include "agg_trans_affine.h" - -namespace agg -{ - //=======================================================trans_perspective - struct trans_perspective - { - double sx, shy, w0, shx, sy, w1, tx, ty, w2; - - //------------------------------------------------------- Construction - // Identity matrix - trans_perspective() : - sx (1), shy(0), w0(0), - shx(0), sy (1), w1(0), - tx (0), ty (0), w2(1) {} - - // Custom matrix - trans_perspective(double v0, double v1, double v2, - double v3, double v4, double v5, - double v6, double v7, double v8) : - sx (v0), shy(v1), w0(v2), - shx(v3), sy (v4), w1(v5), - tx (v6), ty (v7), w2(v8) {} - - // Custom matrix from m[9] - explicit trans_perspective(const double* m) : - sx (m[0]), shy(m[1]), w0(m[2]), - shx(m[3]), sy (m[4]), w1(m[5]), - tx (m[6]), ty (m[7]), w2(m[8]) {} - - // From affine - explicit trans_perspective(const trans_affine& a) : - sx (a.sx ), shy(a.shy), w0(0), - shx(a.shx), sy (a.sy ), w1(0), - tx (a.tx ), ty (a.ty ), w2(1) {} - - // Rectangle to quadrilateral - trans_perspective(double x1, double y1, double x2, double y2, - const double* quad); - - // Quadrilateral to rectangle - trans_perspective(const double* quad, - double x1, double y1, double x2, double y2); - - // Arbitrary quadrilateral transformations - trans_perspective(const double* src, const double* dst); - - //-------------------------------------- Quadrilateral transformations - // The arguments are double[8] that are mapped to quadrilaterals: - // x1,y1, x2,y2, x3,y3, x4,y4 - bool quad_to_quad(const double* qs, const double* qd); - - bool rect_to_quad(double x1, double y1, - double x2, double y2, - const double* q); - - bool quad_to_rect(const double* q, - double x1, double y1, - double x2, double y2); - - // Map square (0,0,1,1) to the quadrilateral and vice versa - bool square_to_quad(const double* q); - bool quad_to_square(const double* q); - - - //--------------------------------------------------------- Operations - // Reset - load an identity matrix - const trans_perspective& reset(); - - // Invert matrix. Returns false in degenerate case - bool invert(); - - // Direct transformations operations - const trans_perspective& translate(double x, double y); - const trans_perspective& rotate(double a); - const trans_perspective& scale(double s); - const trans_perspective& scale(double x, double y); - - // Multiply the matrix by another one - const trans_perspective& multiply(const trans_perspective& m); - - // Multiply "m" by "this" and assign the result to "this" - const trans_perspective& premultiply(const trans_perspective& m); - - // Multiply matrix to inverse of another one - const trans_perspective& multiply_inv(const trans_perspective& m); - - // Multiply inverse of "m" by "this" and assign the result to "this" - const trans_perspective& premultiply_inv(const trans_perspective& m); - - // Multiply the matrix by another one - const trans_perspective& multiply(const trans_affine& m); - - // Multiply "m" by "this" and assign the result to "this" - const trans_perspective& premultiply(const trans_affine& m); - - // Multiply the matrix by inverse of another one - const trans_perspective& multiply_inv(const trans_affine& m); - - // Multiply inverse of "m" by "this" and assign the result to "this" - const trans_perspective& premultiply_inv(const trans_affine& m); - - //--------------------------------------------------------- Load/Store - void store_to(double* m) const; - const trans_perspective& load_from(const double* m); - - //---------------------------------------------------------- Operators - // Multiply the matrix by another one - const trans_perspective& operator *= (const trans_perspective& m) - { - return multiply(m); - } - const trans_perspective& operator *= (const trans_affine& m) - { - return multiply(m); - } - - // Multiply the matrix by inverse of another one - const trans_perspective& operator /= (const trans_perspective& m) - { - return multiply_inv(m); - } - const trans_perspective& operator /= (const trans_affine& m) - { - return multiply_inv(m); - } - - // Multiply the matrix by another one and return - // the result in a separete matrix. - trans_perspective operator * (const trans_perspective& m) - { - return trans_perspective(*this).multiply(m); - } - trans_perspective operator * (const trans_affine& m) - { - return trans_perspective(*this).multiply(m); - } - - // Multiply the matrix by inverse of another one - // and return the result in a separete matrix. - trans_perspective operator / (const trans_perspective& m) - { - return trans_perspective(*this).multiply_inv(m); - } - trans_perspective operator / (const trans_affine& m) - { - return trans_perspective(*this).multiply_inv(m); - } - - // Calculate and return the inverse matrix - trans_perspective operator ~ () const - { - trans_perspective ret = *this; - ret.invert(); - return ret; - } - - // Equal operator with default epsilon - bool operator == (const trans_perspective& m) const - { - return is_equal(m, affine_epsilon); - } - - // Not Equal operator with default epsilon - bool operator != (const trans_perspective& m) const - { - return !is_equal(m, affine_epsilon); - } - - //---------------------------------------------------- Transformations - // Direct transformation of x and y - void transform(double* x, double* y) const; - - // Direct transformation of x and y, affine part only - void transform_affine(double* x, double* y) const; - - // Direct transformation of x and y, 2x2 matrix only, no translation - void transform_2x2(double* x, double* y) const; - - // Inverse transformation of x and y. It works slow because - // it explicitly inverts the matrix on every call. For massive - // operations it's better to invert() the matrix and then use - // direct transformations. - void inverse_transform(double* x, double* y) const; - - - //---------------------------------------------------------- Auxiliary - const trans_perspective& from_affine(const trans_affine& a); - double determinant() const; - double determinant_reciprocal() const; - - bool is_valid(double epsilon = affine_epsilon) const; - bool is_identity(double epsilon = affine_epsilon) const; - bool is_equal(const trans_perspective& m, - double epsilon = affine_epsilon) const; - - // Determine the major affine parameters. Use with caution - // considering possible degenerate cases. - double scale() const; - double rotation() const; - void translation(double* dx, double* dy) const; - void scaling(double* x, double* y) const; - void scaling_abs(double* x, double* y) const; - - - - //-------------------------------------------------------------------- - class iterator_x - { - double den; - double den_step; - double nom_x; - double nom_x_step; - double nom_y; - double nom_y_step; - - public: - double x; - double y; - - iterator_x() {} - iterator_x(double px, double py, double step, const trans_perspective& m) : - den(px * m.w0 + py * m.w1 + m.w2), - den_step(m.w0 * step), - nom_x(px * m.sx + py * m.shx + m.tx), - nom_x_step(step * m.sx), - nom_y(px * m.shy + py * m.sy + m.ty), - nom_y_step(step * m.shy), - x(nom_x / den), - y(nom_y / den) - {} - - void operator ++ () - { - den += den_step; - nom_x += nom_x_step; - nom_y += nom_y_step; - double d = 1.0 / den; - x = nom_x * d; - y = nom_y * d; - } - }; - - //-------------------------------------------------------------------- - iterator_x begin(double x, double y, double step) const - { - return iterator_x(x, y, step, *this); - } - }; - - - - - - - - - - - - - - - //------------------------------------------------------------------------ - inline bool trans_perspective::square_to_quad(const double* q) - { - double dx = q[0] - q[2] + q[4] - q[6]; - double dy = q[1] - q[3] + q[5] - q[7]; - if(dx == 0.0 && dy == 0.0) - { - // Affine case (parallelogram) - //--------------- - sx = q[2] - q[0]; - shy = q[3] - q[1]; - w0 = 0.0; - shx = q[4] - q[2]; - sy = q[5] - q[3]; - w1 = 0.0; - tx = q[0]; - ty = q[1]; - w2 = 1.0; - } - else - { - double dx1 = q[2] - q[4]; - double dy1 = q[3] - q[5]; - double dx2 = q[6] - q[4]; - double dy2 = q[7] - q[5]; - double den = dx1 * dy2 - dx2 * dy1; - if(den == 0.0) - { - // Singular case - //--------------- - sx = shy = w0 = shx = sy = w1 = tx = ty = w2 = 0.0; - return false; - } - // General case - //--------------- - double u = (dx * dy2 - dy * dx2) / den; - double v = (dy * dx1 - dx * dy1) / den; - sx = q[2] - q[0] + u * q[2]; - shy = q[3] - q[1] + u * q[3]; - w0 = u; - shx = q[6] - q[0] + v * q[6]; - sy = q[7] - q[1] + v * q[7]; - w1 = v; - tx = q[0]; - ty = q[1]; - w2 = 1.0; - } - return true; - } - - //------------------------------------------------------------------------ - inline bool trans_perspective::invert() - { - double d0 = sy * w2 - w1 * ty; - double d1 = w0 * ty - shy * w2; - double d2 = shy * w1 - w0 * sy; - double d = sx * d0 + shx * d1 + tx * d2; - if(d == 0.0) - { - sx = shy = w0 = shx = sy = w1 = tx = ty = w2 = 0.0; - return false; - } - d = 1.0 / d; - trans_perspective a = *this; - sx = d * d0; - shy = d * d1; - w0 = d * d2; - shx = d * (a.w1 *a.tx - a.shx*a.w2); - sy = d * (a.sx *a.w2 - a.w0 *a.tx); - w1 = d * (a.w0 *a.shx - a.sx *a.w1); - tx = d * (a.shx*a.ty - a.sy *a.tx); - ty = d * (a.shy*a.tx - a.sx *a.ty); - w2 = d * (a.sx *a.sy - a.shy*a.shx); - return true; - } - - //------------------------------------------------------------------------ - inline bool trans_perspective::quad_to_square(const double* q) - { - if(!square_to_quad(q)) return false; - invert(); - return true; - } - - //------------------------------------------------------------------------ - inline bool trans_perspective::quad_to_quad(const double* qs, - const double* qd) - { - trans_perspective p; - if(! quad_to_square(qs)) return false; - if(!p.square_to_quad(qd)) return false; - multiply(p); - return true; - } - - //------------------------------------------------------------------------ - inline bool trans_perspective::rect_to_quad(double x1, double y1, - double x2, double y2, - const double* q) - { - double r[8]; - r[0] = r[6] = x1; - r[2] = r[4] = x2; - r[1] = r[3] = y1; - r[5] = r[7] = y2; - return quad_to_quad(r, q); - } - - //------------------------------------------------------------------------ - inline bool trans_perspective::quad_to_rect(const double* q, - double x1, double y1, - double x2, double y2) - { - double r[8]; - r[0] = r[6] = x1; - r[2] = r[4] = x2; - r[1] = r[3] = y1; - r[5] = r[7] = y2; - return quad_to_quad(q, r); - } - - //------------------------------------------------------------------------ - inline trans_perspective::trans_perspective(double x1, double y1, - double x2, double y2, - const double* quad) - { - rect_to_quad(x1, y1, x2, y2, quad); - } - - //------------------------------------------------------------------------ - inline trans_perspective::trans_perspective(const double* quad, - double x1, double y1, - double x2, double y2) - { - quad_to_rect(quad, x1, y1, x2, y2); - } - - //------------------------------------------------------------------------ - inline trans_perspective::trans_perspective(const double* src, - const double* dst) - { - quad_to_quad(src, dst); - } - - //------------------------------------------------------------------------ - inline const trans_perspective& trans_perspective::reset() - { - sx = 1; shy = 0; w0 = 0; - shx = 0; sy = 1; w1 = 0; - tx = 0; ty = 0; w2 = 1; - return *this; - } - - //------------------------------------------------------------------------ - inline const trans_perspective& - trans_perspective::multiply(const trans_perspective& a) - { - trans_perspective b = *this; - sx = a.sx *b.sx + a.shx*b.shy + a.tx*b.w0; - shx = a.sx *b.shx + a.shx*b.sy + a.tx*b.w1; - tx = a.sx *b.tx + a.shx*b.ty + a.tx*b.w2; - shy = a.shy*b.sx + a.sy *b.shy + a.ty*b.w0; - sy = a.shy*b.shx + a.sy *b.sy + a.ty*b.w1; - ty = a.shy*b.tx + a.sy *b.ty + a.ty*b.w2; - w0 = a.w0 *b.sx + a.w1 *b.shy + a.w2*b.w0; - w1 = a.w0 *b.shx + a.w1 *b.sy + a.w2*b.w1; - w2 = a.w0 *b.tx + a.w1 *b.ty + a.w2*b.w2; - return *this; - } - - //------------------------------------------------------------------------ - inline const trans_perspective& - trans_perspective::multiply(const trans_affine& a) - { - trans_perspective b = *this; - sx = a.sx *b.sx + a.shx*b.shy + a.tx*b.w0; - shx = a.sx *b.shx + a.shx*b.sy + a.tx*b.w1; - tx = a.sx *b.tx + a.shx*b.ty + a.tx*b.w2; - shy = a.shy*b.sx + a.sy *b.shy + a.ty*b.w0; - sy = a.shy*b.shx + a.sy *b.sy + a.ty*b.w1; - ty = a.shy*b.tx + a.sy *b.ty + a.ty*b.w2; - return *this; - } - - //------------------------------------------------------------------------ - inline const trans_perspective& - trans_perspective::premultiply(const trans_perspective& b) - { - trans_perspective a = *this; - sx = a.sx *b.sx + a.shx*b.shy + a.tx*b.w0; - shx = a.sx *b.shx + a.shx*b.sy + a.tx*b.w1; - tx = a.sx *b.tx + a.shx*b.ty + a.tx*b.w2; - shy = a.shy*b.sx + a.sy *b.shy + a.ty*b.w0; - sy = a.shy*b.shx + a.sy *b.sy + a.ty*b.w1; - ty = a.shy*b.tx + a.sy *b.ty + a.ty*b.w2; - w0 = a.w0 *b.sx + a.w1 *b.shy + a.w2*b.w0; - w1 = a.w0 *b.shx + a.w1 *b.sy + a.w2*b.w1; - w2 = a.w0 *b.tx + a.w1 *b.ty + a.w2*b.w2; - return *this; - } - - //------------------------------------------------------------------------ - inline const trans_perspective& - trans_perspective::premultiply(const trans_affine& b) - { - trans_perspective a = *this; - sx = a.sx *b.sx + a.shx*b.shy; - shx = a.sx *b.shx + a.shx*b.sy; - tx = a.sx *b.tx + a.shx*b.ty + a.tx; - shy = a.shy*b.sx + a.sy *b.shy; - sy = a.shy*b.shx + a.sy *b.sy; - ty = a.shy*b.tx + a.sy *b.ty + a.ty; - w0 = a.w0 *b.sx + a.w1 *b.shy; - w1 = a.w0 *b.shx + a.w1 *b.sy; - w2 = a.w0 *b.tx + a.w1 *b.ty + a.w2; - return *this; - } - - //------------------------------------------------------------------------ - const trans_perspective& - trans_perspective::multiply_inv(const trans_perspective& m) - { - trans_perspective t = m; - t.invert(); - return multiply(t); - } - - //------------------------------------------------------------------------ - const trans_perspective& - trans_perspective::multiply_inv(const trans_affine& m) - { - trans_affine t = m; - t.invert(); - return multiply(t); - } - - //------------------------------------------------------------------------ - const trans_perspective& - trans_perspective::premultiply_inv(const trans_perspective& m) - { - trans_perspective t = m; - t.invert(); - return *this = t.multiply(*this); - } - - //------------------------------------------------------------------------ - const trans_perspective& - trans_perspective::premultiply_inv(const trans_affine& m) - { - trans_perspective t(m); - t.invert(); - return *this = t.multiply(*this); - } - - //------------------------------------------------------------------------ - inline const trans_perspective& - trans_perspective::translate(double x, double y) - { - tx += x; - ty += y; - return *this; - } - - //------------------------------------------------------------------------ - inline const trans_perspective& trans_perspective::rotate(double a) - { - multiply(trans_affine_rotation(a)); - return *this; - } - - //------------------------------------------------------------------------ - inline const trans_perspective& trans_perspective::scale(double s) - { - multiply(trans_affine_scaling(s)); - return *this; - } - - //------------------------------------------------------------------------ - inline const trans_perspective& trans_perspective::scale(double x, double y) - { - multiply(trans_affine_scaling(x, y)); - return *this; - } - - //------------------------------------------------------------------------ - inline void trans_perspective::transform(double* px, double* py) const - { - double x = *px; - double y = *py; - double m = 1.0 / (x*w0 + y*w1 + w2); - *px = m * (x*sx + y*shx + tx); - *py = m * (x*shy + y*sy + ty); - } - - //------------------------------------------------------------------------ - inline void trans_perspective::transform_affine(double* x, double* y) const - { - double tmp = *x; - *x = tmp * sx + *y * shx + tx; - *y = tmp * shy + *y * sy + ty; - } - - //------------------------------------------------------------------------ - inline void trans_perspective::transform_2x2(double* x, double* y) const - { - double tmp = *x; - *x = tmp * sx + *y * shx; - *y = tmp * shy + *y * sy; - } - - //------------------------------------------------------------------------ - inline void trans_perspective::inverse_transform(double* x, double* y) const - { - trans_perspective t(*this); - if(t.invert()) t.transform(x, y); - } - - //------------------------------------------------------------------------ - inline void trans_perspective::store_to(double* m) const - { - *m++ = sx; *m++ = shy; *m++ = w0; - *m++ = shx; *m++ = sy; *m++ = w1; - *m++ = tx; *m++ = ty; *m++ = w2; - } - - //------------------------------------------------------------------------ - inline const trans_perspective& trans_perspective::load_from(const double* m) - { - sx = *m++; shy = *m++; w0 = *m++; - shx = *m++; sy = *m++; w1 = *m++; - tx = *m++; ty = *m++; w2 = *m++; - return *this; - } - - //------------------------------------------------------------------------ - inline const trans_perspective& - trans_perspective::from_affine(const trans_affine& a) - { - sx = a.sx; shy = a.shy; w0 = 0; - shx = a.shx; sy = a.sy; w1 = 0; - tx = a.tx; ty = a.ty; w2 = 1; - return *this; - } - - //------------------------------------------------------------------------ - inline double trans_perspective::determinant() const - { - return sx * (sy * w2 - ty * w1) + - shx * (ty * w0 - shy * w2) + - tx * (shy * w1 - sy * w0); - } - - //------------------------------------------------------------------------ - inline double trans_perspective::determinant_reciprocal() const - { - return 1.0 / determinant(); - } - - //------------------------------------------------------------------------ - inline bool trans_perspective::is_valid(double epsilon) const - { - return fabs(sx) > epsilon && fabs(sy) > epsilon && fabs(w2) > epsilon; - } - - //------------------------------------------------------------------------ - inline bool trans_perspective::is_identity(double epsilon) const - { - return is_equal_eps(sx, 1.0, epsilon) && - is_equal_eps(shy, 0.0, epsilon) && - is_equal_eps(w0, 0.0, epsilon) && - is_equal_eps(shx, 0.0, epsilon) && - is_equal_eps(sy, 1.0, epsilon) && - is_equal_eps(w1, 0.0, epsilon) && - is_equal_eps(tx, 0.0, epsilon) && - is_equal_eps(ty, 0.0, epsilon) && - is_equal_eps(w2, 1.0, epsilon); - } - - //------------------------------------------------------------------------ - inline bool trans_perspective::is_equal(const trans_perspective& m, - double epsilon) const - { - return is_equal_eps(sx, m.sx, epsilon) && - is_equal_eps(shy, m.shy, epsilon) && - is_equal_eps(w0, m.w0, epsilon) && - is_equal_eps(shx, m.shx, epsilon) && - is_equal_eps(sy, m.sy, epsilon) && - is_equal_eps(w1, m.w1, epsilon) && - is_equal_eps(tx, m.tx, epsilon) && - is_equal_eps(ty, m.ty, epsilon) && - is_equal_eps(w2, m.w2, epsilon); - } - - //------------------------------------------------------------------------ - inline double trans_perspective::scale() const - { - double x = 0.707106781 * sx + 0.707106781 * shx; - double y = 0.707106781 * shy + 0.707106781 * sy; - return sqrt(x*x + y*y); - } - - //------------------------------------------------------------------------ - inline double trans_perspective::rotation() const - { - double x1 = 0.0; - double y1 = 0.0; - double x2 = 1.0; - double y2 = 0.0; - transform(&x1, &y1); - transform(&x2, &y2); - return atan2(y2-y1, x2-x1); - } - - //------------------------------------------------------------------------ - void trans_perspective::translation(double* dx, double* dy) const - { - *dx = tx; - *dy = ty; - } - - //------------------------------------------------------------------------ - void trans_perspective::scaling(double* x, double* y) const - { - double x1 = 0.0; - double y1 = 0.0; - double x2 = 1.0; - double y2 = 1.0; - trans_perspective t(*this); - t *= trans_affine_rotation(-rotation()); - t.transform(&x1, &y1); - t.transform(&x2, &y2); - *x = x2 - x1; - *y = y2 - y1; - } - - //------------------------------------------------------------------------ - void trans_perspective::scaling_abs(double* x, double* y) const - { - *x = sqrt(sx * sx + shx * shx); - *y = sqrt(shy * shy + sy * sy); - } - - -} - -#endif - diff --git a/desmume/src/windows/agg/include/agg_trans_single_path.h b/desmume/src/windows/agg/include/agg_trans_single_path.h deleted file mode 100644 index 479a1f1cf..000000000 --- a/desmume/src/windows/agg/include/agg_trans_single_path.h +++ /dev/null @@ -1,106 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_TRANS_SINGLE_PATH_INCLUDED -#define AGG_TRANS_SINGLE_PATH_INCLUDED - -#include "agg_basics.h" -#include "agg_vertex_sequence.h" - -namespace agg -{ - - // See also: agg_trans_single_path.cpp - // - //-------------------------------------------------------trans_single_path - class trans_single_path - { - enum status_e - { - initial, - making_path, - ready - }; - - public: - typedef vertex_sequence vertex_storage; - - trans_single_path(); - - //-------------------------------------------------------------------- - void base_length(double v) { m_base_length = v; } - double base_length() const { return m_base_length; } - - //-------------------------------------------------------------------- - void preserve_x_scale(bool f) { m_preserve_x_scale = f; } - bool preserve_x_scale() const { return m_preserve_x_scale; } - - //-------------------------------------------------------------------- - void reset(); - void move_to(double x, double y); - void line_to(double x, double y); - void finalize_path(); - - //-------------------------------------------------------------------- - template - void add_path(VertexSource& vs, unsigned path_id=0) - { - double x; - double y; - - unsigned cmd; - vs.rewind(path_id); - while(!is_stop(cmd = vs.vertex(&x, &y))) - { - if(is_move_to(cmd)) - { - move_to(x, y); - } - else - { - if(is_vertex(cmd)) - { - line_to(x, y); - } - } - } - finalize_path(); - } - - //-------------------------------------------------------------------- - double total_length() const; - void transform(double *x, double *y) const; - - private: - vertex_storage m_src_vertices; - double m_base_length; - double m_kindex; - status_e m_status; - bool m_preserve_x_scale; - }; - - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_trans_viewport.h b/desmume/src/windows/agg/include/agg_trans_viewport.h deleted file mode 100644 index a9d18b540..000000000 --- a/desmume/src/windows/agg/include/agg_trans_viewport.h +++ /dev/null @@ -1,312 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- -// -// Viewport transformer - simple orthogonal conversions from world coordinates -// to screen (device) ones. -// -//---------------------------------------------------------------------------- - -#ifndef AGG_TRANS_VIEWPORT_INCLUDED -#define AGG_TRANS_VIEWPORT_INCLUDED - -#include -#include "agg_trans_affine.h" - - -namespace agg -{ - - enum aspect_ratio_e - { - aspect_ratio_stretch, - aspect_ratio_meet, - aspect_ratio_slice - }; - - - //----------------------------------------------------------trans_viewport - class trans_viewport - { - public: - //------------------------------------------------------------------- - trans_viewport() : - m_world_x1(0.0), - m_world_y1(0.0), - m_world_x2(1.0), - m_world_y2(1.0), - m_device_x1(0.0), - m_device_y1(0.0), - m_device_x2(1.0), - m_device_y2(1.0), - m_aspect(aspect_ratio_stretch), - m_is_valid(true), - m_align_x(0.5), - m_align_y(0.5), - m_wx1(0.0), - m_wy1(0.0), - m_wx2(1.0), - m_wy2(1.0), - m_dx1(0.0), - m_dy1(0.0), - m_kx(1.0), - m_ky(1.0) - {} - - //------------------------------------------------------------------- - void preserve_aspect_ratio(double alignx, - double aligny, - aspect_ratio_e aspect) - { - m_align_x = alignx; - m_align_y = aligny; - m_aspect = aspect; - update(); - } - - //------------------------------------------------------------------- - void device_viewport(double x1, double y1, double x2, double y2) - { - m_device_x1 = x1; - m_device_y1 = y1; - m_device_x2 = x2; - m_device_y2 = y2; - update(); - } - - //------------------------------------------------------------------- - void world_viewport(double x1, double y1, double x2, double y2) - { - m_world_x1 = x1; - m_world_y1 = y1; - m_world_x2 = x2; - m_world_y2 = y2; - update(); - } - - //------------------------------------------------------------------- - void device_viewport(double* x1, double* y1, double* x2, double* y2) const - { - *x1 = m_device_x1; - *y1 = m_device_y1; - *x2 = m_device_x2; - *y2 = m_device_y2; - } - - //------------------------------------------------------------------- - void world_viewport(double* x1, double* y1, double* x2, double* y2) const - { - *x1 = m_world_x1; - *y1 = m_world_y1; - *x2 = m_world_x2; - *y2 = m_world_y2; - } - - //------------------------------------------------------------------- - void world_viewport_actual(double* x1, double* y1, - double* x2, double* y2) const - { - *x1 = m_wx1; - *y1 = m_wy1; - *x2 = m_wx2; - *y2 = m_wy2; - } - - //------------------------------------------------------------------- - bool is_valid() const { return m_is_valid; } - double align_x() const { return m_align_x; } - double align_y() const { return m_align_y; } - aspect_ratio_e aspect_ratio() const { return m_aspect; } - - //------------------------------------------------------------------- - void transform(double* x, double* y) const - { - *x = (*x - m_wx1) * m_kx + m_dx1; - *y = (*y - m_wy1) * m_ky + m_dy1; - } - - //------------------------------------------------------------------- - void transform_scale_only(double* x, double* y) const - { - *x *= m_kx; - *y *= m_ky; - } - - //------------------------------------------------------------------- - void inverse_transform(double* x, double* y) const - { - *x = (*x - m_dx1) / m_kx + m_wx1; - *y = (*y - m_dy1) / m_ky + m_wy1; - } - - //------------------------------------------------------------------- - void inverse_transform_scale_only(double* x, double* y) const - { - *x /= m_kx; - *y /= m_ky; - } - - //------------------------------------------------------------------- - double device_dx() const { return m_dx1 - m_wx1 * m_kx; } - double device_dy() const { return m_dy1 - m_wy1 * m_ky; } - - //------------------------------------------------------------------- - double scale_x() const - { - return m_kx; - } - - //------------------------------------------------------------------- - double scale_y() const - { - return m_ky; - } - - //------------------------------------------------------------------- - double scale() const - { - return (m_kx + m_ky) * 0.5; - } - - //------------------------------------------------------------------- - trans_affine to_affine() const - { - trans_affine mtx = trans_affine_translation(-m_wx1, -m_wy1); - mtx *= trans_affine_scaling(m_kx, m_ky); - mtx *= trans_affine_translation(m_dx1, m_dy1); - return mtx; - } - - //------------------------------------------------------------------- - trans_affine to_affine_scale_only() const - { - return trans_affine_scaling(m_kx, m_ky); - } - - //------------------------------------------------------------------- - unsigned byte_size() const - { - return sizeof(*this); - } - - void serialize(int8u* ptr) const - { - memcpy(ptr, this, sizeof(*this)); - } - - void deserialize(const int8u* ptr) - { - memcpy(this, ptr, sizeof(*this)); - } - - private: - void update(); - - double m_world_x1; - double m_world_y1; - double m_world_x2; - double m_world_y2; - double m_device_x1; - double m_device_y1; - double m_device_x2; - double m_device_y2; - aspect_ratio_e m_aspect; - bool m_is_valid; - double m_align_x; - double m_align_y; - double m_wx1; - double m_wy1; - double m_wx2; - double m_wy2; - double m_dx1; - double m_dy1; - double m_kx; - double m_ky; - }; - - - - //----------------------------------------------------------------------- - inline void trans_viewport::update() - { - const double epsilon = 1e-30; - if(fabs(m_world_x1 - m_world_x2) < epsilon || - fabs(m_world_y1 - m_world_y2) < epsilon || - fabs(m_device_x1 - m_device_x2) < epsilon || - fabs(m_device_y1 - m_device_y2) < epsilon) - { - m_wx1 = m_world_x1; - m_wy1 = m_world_y1; - m_wx2 = m_world_x1 + 1.0; - m_wy2 = m_world_y2 + 1.0; - m_dx1 = m_device_x1; - m_dy1 = m_device_y1; - m_kx = 1.0; - m_ky = 1.0; - m_is_valid = false; - return; - } - - double world_x1 = m_world_x1; - double world_y1 = m_world_y1; - double world_x2 = m_world_x2; - double world_y2 = m_world_y2; - double device_x1 = m_device_x1; - double device_y1 = m_device_y1; - double device_x2 = m_device_x2; - double device_y2 = m_device_y2; - if(m_aspect != aspect_ratio_stretch) - { - double d; - m_kx = (device_x2 - device_x1) / (world_x2 - world_x1); - m_ky = (device_y2 - device_y1) / (world_y2 - world_y1); - - if((m_aspect == aspect_ratio_meet) == (m_kx < m_ky)) - { - d = (world_y2 - world_y1) * m_ky / m_kx; - world_y1 += (world_y2 - world_y1 - d) * m_align_y; - world_y2 = world_y1 + d; - } - else - { - d = (world_x2 - world_x1) * m_kx / m_ky; - world_x1 += (world_x2 - world_x1 - d) * m_align_x; - world_x2 = world_x1 + d; - } - } - m_wx1 = world_x1; - m_wy1 = world_y1; - m_wx2 = world_x2; - m_wy2 = world_y2; - m_dx1 = device_x1; - m_dy1 = device_y1; - m_kx = (device_x2 - device_x1) / (world_x2 - world_x1); - m_ky = (device_y2 - device_y1) / (world_y2 - world_y1); - m_is_valid = true; - } - - -} - - -#endif diff --git a/desmume/src/windows/agg/include/agg_trans_warp_magnifier.h b/desmume/src/windows/agg/include/agg_trans_warp_magnifier.h deleted file mode 100644 index d80f71152..000000000 --- a/desmume/src/windows/agg/include/agg_trans_warp_magnifier.h +++ /dev/null @@ -1,65 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_WARP_MAGNIFIER_INCLUDED -#define AGG_WARP_MAGNIFIER_INCLUDED - - -namespace agg -{ - - //----------------------------------------------------trans_warp_magnifier - // - // See Inmplementation agg_trans_warp_magnifier.cpp - // - class trans_warp_magnifier - { - public: - trans_warp_magnifier() : m_xc(0.0), m_yc(0.0), m_magn(1.0), m_radius(1.0) {} - - void center(double x, double y) { m_xc = x; m_yc = y; } - void magnification(double m) { m_magn = m; } - void radius(double r) { m_radius = r; } - - double xc() const { return m_xc; } - double yc() const { return m_yc; } - double magnification() const { return m_magn; } - double radius() const { return m_radius; } - - void transform(double* x, double* y) const; - void inverse_transform(double* x, double* y) const; - - private: - double m_xc; - double m_yc; - double m_magn; - double m_radius; - }; - - -} - - -#endif - diff --git a/desmume/src/windows/agg/include/agg_vcgen_bspline.h b/desmume/src/windows/agg/include/agg_vcgen_bspline.h deleted file mode 100644 index d55dd0657..000000000 --- a/desmume/src/windows/agg/include/agg_vcgen_bspline.h +++ /dev/null @@ -1,83 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_VCGEN_BSPLINE_INCLUDED -#define AGG_VCGEN_BSPLINE_INCLUDED - -#include "agg_basics.h" -#include "agg_array.h" -#include "agg_bspline.h" - - -namespace agg -{ - - //==========================================================vcgen_bspline - class vcgen_bspline - { - enum status_e - { - initial, - ready, - polygon, - end_poly, - stop - }; - - public: - typedef pod_bvector vertex_storage; - - vcgen_bspline(); - - void interpolation_step(double v) { m_interpolation_step = v; } - double interpolation_step() const { return m_interpolation_step; } - - // Vertex Generator Interface - void remove_all(); - void add_vertex(double x, double y, unsigned cmd); - - // Vertex Source Interface - void rewind(unsigned path_id); - unsigned vertex(double* x, double* y); - - private: - vcgen_bspline(const vcgen_bspline&); - const vcgen_bspline& operator = (const vcgen_bspline&); - - vertex_storage m_src_vertices; - bspline m_spline_x; - bspline m_spline_y; - double m_interpolation_step; - unsigned m_closed; - status_e m_status; - unsigned m_src_vertex; - double m_cur_abscissa; - double m_max_abscissa; - }; - -} - - -#endif - diff --git a/desmume/src/windows/agg/include/agg_vcgen_contour.h b/desmume/src/windows/agg/include/agg_vcgen_contour.h deleted file mode 100644 index 85ca00e3c..000000000 --- a/desmume/src/windows/agg/include/agg_vcgen_contour.h +++ /dev/null @@ -1,103 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_VCGEN_CONTOUR_INCLUDED -#define AGG_VCGEN_CONTOUR_INCLUDED - -#include "agg_math_stroke.h" - -namespace agg -{ - - //----------------------------------------------------------vcgen_contour - // - // See Implementation agg_vcgen_contour.cpp - // - class vcgen_contour - { - enum status_e - { - initial, - ready, - outline, - out_vertices, - end_poly, - stop - }; - - public: - typedef vertex_sequence vertex_storage; - typedef pod_bvector coord_storage; - - vcgen_contour(); - - void line_cap(line_cap_e lc) { m_stroker.line_cap(lc); } - void line_join(line_join_e lj) { m_stroker.line_join(lj); } - void inner_join(inner_join_e ij) { m_stroker.inner_join(ij); } - - line_cap_e line_cap() const { return m_stroker.line_cap(); } - line_join_e line_join() const { return m_stroker.line_join(); } - inner_join_e inner_join() const { return m_stroker.inner_join(); } - - void width(double w) { m_stroker.width(m_width = w); } - void miter_limit(double ml) { m_stroker.miter_limit(ml); } - void miter_limit_theta(double t) { m_stroker.miter_limit_theta(t); } - void inner_miter_limit(double ml) { m_stroker.inner_miter_limit(ml); } - void approximation_scale(double as) { m_stroker.approximation_scale(as); } - - double width() const { return m_width; } - double miter_limit() const { return m_stroker.miter_limit(); } - double inner_miter_limit() const { return m_stroker.inner_miter_limit(); } - double approximation_scale() const { return m_stroker.approximation_scale(); } - - void auto_detect_orientation(bool v) { m_auto_detect = v; } - bool auto_detect_orientation() const { return m_auto_detect; } - - // Generator interface - void remove_all(); - void add_vertex(double x, double y, unsigned cmd); - - // Vertex Source Interface - void rewind(unsigned path_id); - unsigned vertex(double* x, double* y); - - private: - vcgen_contour(const vcgen_contour&); - const vcgen_contour& operator = (const vcgen_contour&); - - math_stroke m_stroker; - double m_width; - vertex_storage m_src_vertices; - coord_storage m_out_vertices; - status_e m_status; - unsigned m_src_vertex; - unsigned m_out_vertex; - unsigned m_closed; - unsigned m_orientation; - bool m_auto_detect; - }; - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_vcgen_dash.h b/desmume/src/windows/agg/include/agg_vcgen_dash.h deleted file mode 100644 index 8f195a230..000000000 --- a/desmume/src/windows/agg/include/agg_vcgen_dash.h +++ /dev/null @@ -1,99 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_VCGEN_DASH_INCLUDED -#define AGG_VCGEN_DASH_INCLUDED - -#include "agg_basics.h" -#include "agg_vertex_sequence.h" - -namespace agg -{ - - //---------------------------------------------------------------vcgen_dash - // - // See Implementation agg_vcgen_dash.cpp - // - class vcgen_dash - { - enum max_dashes_e - { - max_dashes = 32 - }; - - enum status_e - { - initial, - ready, - polyline, - stop - }; - - public: - typedef vertex_sequence vertex_storage; - - vcgen_dash(); - - void remove_all_dashes(); - void add_dash(double dash_len, double gap_len); - void dash_start(double ds); - - void shorten(double s) { m_shorten = s; } - double shorten() const { return m_shorten; } - - // Vertex Generator Interface - void remove_all(); - void add_vertex(double x, double y, unsigned cmd); - - // Vertex Source Interface - void rewind(unsigned path_id); - unsigned vertex(double* x, double* y); - - private: - vcgen_dash(const vcgen_dash&); - const vcgen_dash& operator = (const vcgen_dash&); - - void calc_dash_start(double ds); - - double m_dashes[max_dashes]; - double m_total_dash_len; - unsigned m_num_dashes; - double m_dash_start; - double m_shorten; - double m_curr_dash_start; - unsigned m_curr_dash; - double m_curr_rest; - const vertex_dist* m_v1; - const vertex_dist* m_v2; - - vertex_storage m_src_vertices; - unsigned m_closed; - status_e m_status; - unsigned m_src_vertex; - }; - - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_vcgen_markers_term.h b/desmume/src/windows/agg/include/agg_vcgen_markers_term.h deleted file mode 100644 index b4abc22ca..000000000 --- a/desmume/src/windows/agg/include/agg_vcgen_markers_term.h +++ /dev/null @@ -1,75 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_VCGEN_MARKERS_TERM_INCLUDED -#define AGG_VCGEN_MARKERS_TERM_INCLUDED - -#include "agg_basics.h" -#include "agg_vertex_sequence.h" - -namespace agg -{ - - //======================================================vcgen_markers_term - // - // See Implemantation agg_vcgen_markers_term.cpp - // Terminal markers generator (arrowhead/arrowtail) - // - //------------------------------------------------------------------------ - class vcgen_markers_term - { - public: - vcgen_markers_term() : m_curr_id(0), m_curr_idx(0) {} - - // Vertex Generator Interface - void remove_all(); - void add_vertex(double x, double y, unsigned cmd); - - // Vertex Source Interface - void rewind(unsigned path_id); - unsigned vertex(double* x, double* y); - - private: - vcgen_markers_term(const vcgen_markers_term&); - const vcgen_markers_term& operator = (const vcgen_markers_term&); - - struct coord_type - { - double x, y; - - coord_type() {} - coord_type(double x_, double y_) : x(x_), y(y_) {} - }; - - typedef pod_bvector coord_storage; - - coord_storage m_markers; - unsigned m_curr_id; - unsigned m_curr_idx; - }; - - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_vcgen_smooth_poly1.h b/desmume/src/windows/agg/include/agg_vcgen_smooth_poly1.h deleted file mode 100644 index 8e10823a5..000000000 --- a/desmume/src/windows/agg/include/agg_vcgen_smooth_poly1.h +++ /dev/null @@ -1,96 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_VCGEN_SMOOTH_POLY1_INCLUDED -#define AGG_VCGEN_SMOOTH_POLY1_INCLUDED - -#include "agg_basics.h" -#include "agg_vertex_sequence.h" - - -namespace agg -{ - - //======================================================vcgen_smooth_poly1 - // - // See Implementation agg_vcgen_smooth_poly1.cpp - // Smooth polygon generator - // - //------------------------------------------------------------------------ - class vcgen_smooth_poly1 - { - enum status_e - { - initial, - ready, - polygon, - ctrl_b, - ctrl_e, - ctrl1, - ctrl2, - end_poly, - stop - }; - - public: - typedef vertex_sequence vertex_storage; - - vcgen_smooth_poly1(); - - void smooth_value(double v) { m_smooth_value = v * 0.5; } - double smooth_value() const { return m_smooth_value * 2.0; } - - // Vertex Generator Interface - void remove_all(); - void add_vertex(double x, double y, unsigned cmd); - - // Vertex Source Interface - void rewind(unsigned path_id); - unsigned vertex(double* x, double* y); - - private: - vcgen_smooth_poly1(const vcgen_smooth_poly1&); - const vcgen_smooth_poly1& operator = (const vcgen_smooth_poly1&); - - void calculate(const vertex_dist& v0, - const vertex_dist& v1, - const vertex_dist& v2, - const vertex_dist& v3); - - vertex_storage m_src_vertices; - double m_smooth_value; - unsigned m_closed; - status_e m_status; - unsigned m_src_vertex; - double m_ctrl1_x; - double m_ctrl1_y; - double m_ctrl2_x; - double m_ctrl2_y; - }; - -} - - -#endif - diff --git a/desmume/src/windows/agg/include/agg_vcgen_stroke.h b/desmume/src/windows/agg/include/agg_vcgen_stroke.h deleted file mode 100644 index e39afb8d5..000000000 --- a/desmume/src/windows/agg/include/agg_vcgen_stroke.h +++ /dev/null @@ -1,111 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_VCGEN_STROKE_INCLUDED -#define AGG_VCGEN_STROKE_INCLUDED - -#include "agg_math_stroke.h" - - -namespace agg -{ - - //============================================================vcgen_stroke - // - // See Implementation agg_vcgen_stroke.cpp - // Stroke generator - // - //------------------------------------------------------------------------ - class vcgen_stroke - { - enum status_e - { - initial, - ready, - cap1, - cap2, - outline1, - close_first, - outline2, - out_vertices, - end_poly1, - end_poly2, - stop - }; - - public: - typedef vertex_sequence vertex_storage; - typedef pod_bvector coord_storage; - - vcgen_stroke(); - - void line_cap(line_cap_e lc) { m_stroker.line_cap(lc); } - void line_join(line_join_e lj) { m_stroker.line_join(lj); } - void inner_join(inner_join_e ij) { m_stroker.inner_join(ij); } - - line_cap_e line_cap() const { return m_stroker.line_cap(); } - line_join_e line_join() const { return m_stroker.line_join(); } - inner_join_e inner_join() const { return m_stroker.inner_join(); } - - void width(double w) { m_stroker.width(w); } - void miter_limit(double ml) { m_stroker.miter_limit(ml); } - void miter_limit_theta(double t) { m_stroker.miter_limit_theta(t); } - void inner_miter_limit(double ml) { m_stroker.inner_miter_limit(ml); } - void approximation_scale(double as) { m_stroker.approximation_scale(as); } - - double width() const { return m_stroker.width(); } - double miter_limit() const { return m_stroker.miter_limit(); } - double inner_miter_limit() const { return m_stroker.inner_miter_limit(); } - double approximation_scale() const { return m_stroker.approximation_scale(); } - - void shorten(double s) { m_shorten = s; } - double shorten() const { return m_shorten; } - - // Vertex Generator Interface - void remove_all(); - void add_vertex(double x, double y, unsigned cmd); - - // Vertex Source Interface - void rewind(unsigned path_id); - unsigned vertex(double* x, double* y); - - private: - vcgen_stroke(const vcgen_stroke&); - const vcgen_stroke& operator = (const vcgen_stroke&); - - math_stroke m_stroker; - vertex_storage m_src_vertices; - coord_storage m_out_vertices; - double m_shorten; - unsigned m_closed; - status_e m_status; - status_e m_prev_status; - unsigned m_src_vertex; - unsigned m_out_vertex; - }; - - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_vcgen_vertex_sequence.h b/desmume/src/windows/agg/include/agg_vcgen_vertex_sequence.h deleted file mode 100644 index af94f046b..000000000 --- a/desmume/src/windows/agg/include/agg_vcgen_vertex_sequence.h +++ /dev/null @@ -1,144 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_VCGEN_VERTEX_SEQUENCE_INCLUDED -#define AGG_VCGEN_VERTEX_SEQUENCE_INCLUDED - -#include "agg_basics.h" -#include "agg_vertex_sequence.h" -#include "agg_shorten_path.h" - -namespace agg -{ - - //===================================================vcgen_vertex_sequence - class vcgen_vertex_sequence - { - public: - typedef vertex_dist_cmd vertex_type; - typedef vertex_sequence vertex_storage; - - vcgen_vertex_sequence() : - m_flags(0), - m_cur_vertex(0), - m_shorten(0.0), - m_ready(false) - { - } - - // Vertex Generator Interface - void remove_all(); - void add_vertex(double x, double y, unsigned cmd); - - // Vertex Source Interface - void rewind(unsigned path_id); - unsigned vertex(double* x, double* y); - - void shorten(double s) { m_shorten = s; } - double shorten() const { return m_shorten; } - - private: - vcgen_vertex_sequence(const vcgen_vertex_sequence&); - const vcgen_vertex_sequence& operator = (const vcgen_vertex_sequence&); - - vertex_storage m_src_vertices; - unsigned m_flags; - unsigned m_cur_vertex; - double m_shorten; - bool m_ready; - }; - - - //------------------------------------------------------------------------ - inline void vcgen_vertex_sequence::remove_all() - { - m_ready = false; - m_src_vertices.remove_all(); - m_cur_vertex = 0; - m_flags = 0; - } - - //------------------------------------------------------------------------ - inline void vcgen_vertex_sequence::add_vertex(double x, double y, unsigned cmd) - { - m_ready = false; - if(is_move_to(cmd)) - { - m_src_vertices.modify_last(vertex_dist_cmd(x, y, cmd)); - } - else - { - if(is_vertex(cmd)) - { - m_src_vertices.add(vertex_dist_cmd(x, y, cmd)); - } - else - { - m_flags = cmd & path_flags_mask; - } - } - } - - - //------------------------------------------------------------------------ - inline void vcgen_vertex_sequence::rewind(unsigned) - { - if(!m_ready) - { - m_src_vertices.close(is_closed(m_flags)); - shorten_path(m_src_vertices, m_shorten, get_close_flag(m_flags)); - } - m_ready = true; - m_cur_vertex = 0; - } - - //------------------------------------------------------------------------ - inline unsigned vcgen_vertex_sequence::vertex(double* x, double* y) - { - if(!m_ready) - { - rewind(0); - } - - if(m_cur_vertex == m_src_vertices.size()) - { - ++m_cur_vertex; - return path_cmd_end_poly | m_flags; - } - - if(m_cur_vertex > m_src_vertices.size()) - { - return path_cmd_stop; - } - - vertex_type& v = m_src_vertices[m_cur_vertex++]; - *x = v.x; - *y = v.y; - return v.cmd; - } - - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_vertex_sequence.h b/desmume/src/windows/agg/include/agg_vertex_sequence.h deleted file mode 100644 index 9125577de..000000000 --- a/desmume/src/windows/agg/include/agg_vertex_sequence.h +++ /dev/null @@ -1,178 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_VERTEX_SEQUENCE_INCLUDED -#define AGG_VERTEX_SEQUENCE_INCLUDED - -#include "agg_basics.h" -#include "agg_array.h" -#include "agg_math.h" - -namespace agg -{ - - //----------------------------------------------------------vertex_sequence - // Modified agg::pod_bvector. The data is interpreted as a sequence - // of vertices. It means that the type T must expose: - // - // bool T::operator() (const T& val) - // - // that is called every time new vertex is being added. The main purpose - // of this operator is the possibility to calculate some values during - // adding and to return true if the vertex fits some criteria or false if - // it doesn't. In the last case the new vertex is not added. - // - // The simple example is filtering coinciding vertices with calculation - // of the distance between the current and previous ones: - // - // struct vertex_dist - // { - // double x; - // double y; - // double dist; - // - // vertex_dist() {} - // vertex_dist(double x_, double y_) : - // x(x_), - // y(y_), - // dist(0.0) - // { - // } - // - // bool operator () (const vertex_dist& val) - // { - // return (dist = calc_distance(x, y, val.x, val.y)) > EPSILON; - // } - // }; - // - // Function close() calls this operator and removes the last vertex if - // necessary. - //------------------------------------------------------------------------ - template - class vertex_sequence : public pod_bvector - { - public: - typedef pod_bvector base_type; - - void add(const T& val); - void modify_last(const T& val); - void close(bool remove_flag); - }; - - - - //------------------------------------------------------------------------ - template - void vertex_sequence::add(const T& val) - { - if(base_type::size() > 1) - { - if(!(*this)[base_type::size() - 2]((*this)[base_type::size() - 1])) - { - base_type::remove_last(); - } - } - base_type::add(val); - } - - - //------------------------------------------------------------------------ - template - void vertex_sequence::modify_last(const T& val) - { - base_type::remove_last(); - add(val); - } - - - - //------------------------------------------------------------------------ - template - void vertex_sequence::close(bool closed) - { - while(base_type::size() > 1) - { - if((*this)[base_type::size() - 2]((*this)[base_type::size() - 1])) break; - T t = (*this)[base_type::size() - 1]; - base_type::remove_last(); - modify_last(t); - } - - if(closed) - { - while(base_type::size() > 1) - { - if((*this)[base_type::size() - 1]((*this)[0])) break; - base_type::remove_last(); - } - } - } - - - //-------------------------------------------------------------vertex_dist - // Vertex (x, y) with the distance to the next one. The last vertex has - // distance between the last and the first points if the polygon is closed - // and 0.0 if it's a polyline. - struct vertex_dist - { - double x; - double y; - double dist; - - vertex_dist() {} - vertex_dist(double x_, double y_) : - x(x_), - y(y_), - dist(0.0) - { - } - - bool operator () (const vertex_dist& val) - { - bool ret = (dist = calc_distance(x, y, val.x, val.y)) > vertex_dist_epsilon; - if(!ret) dist = 1.0 / vertex_dist_epsilon; - return ret; - } - }; - - - - //--------------------------------------------------------vertex_dist_cmd - // Save as the above but with additional "command" value - struct vertex_dist_cmd : public vertex_dist - { - unsigned cmd; - - vertex_dist_cmd() {} - vertex_dist_cmd(double x_, double y_, unsigned cmd_) : - vertex_dist(x_, y_), - cmd(cmd_) - { - } - }; - - -} - -#endif diff --git a/desmume/src/windows/agg/include/agg_vpgen_clip_polygon.h b/desmume/src/windows/agg/include/agg_vpgen_clip_polygon.h deleted file mode 100644 index f5e791ebc..000000000 --- a/desmume/src/windows/agg/include/agg_vpgen_clip_polygon.h +++ /dev/null @@ -1,92 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_VPGEN_CLIP_POLYGON_INCLUDED -#define AGG_VPGEN_CLIP_POLYGON_INCLUDED - -#include "agg_basics.h" - -namespace agg -{ - - //======================================================vpgen_clip_polygon - // - // See Implementation agg_vpgen_clip_polygon.cpp - // - class vpgen_clip_polygon - { - public: - vpgen_clip_polygon() : - m_clip_box(0, 0, 1, 1), - m_x1(0), - m_y1(0), - m_clip_flags(0), - m_num_vertices(0), - m_vertex(0), - m_cmd(path_cmd_move_to) - { - } - - void clip_box(double x1, double y1, double x2, double y2) - { - m_clip_box.x1 = x1; - m_clip_box.y1 = y1; - m_clip_box.x2 = x2; - m_clip_box.y2 = y2; - m_clip_box.normalize(); - } - - - double x1() const { return m_clip_box.x1; } - double y1() const { return m_clip_box.y1; } - double x2() const { return m_clip_box.x2; } - double y2() const { return m_clip_box.y2; } - - static bool auto_close() { return true; } - static bool auto_unclose() { return false; } - - void reset(); - void move_to(double x, double y); - void line_to(double x, double y); - unsigned vertex(double* x, double* y); - - private: - unsigned clipping_flags(double x, double y); - - private: - rect_d m_clip_box; - double m_x1; - double m_y1; - unsigned m_clip_flags; - double m_x[4]; - double m_y[4]; - unsigned m_num_vertices; - unsigned m_vertex; - unsigned m_cmd; - }; - -} - - -#endif diff --git a/desmume/src/windows/agg/include/agg_vpgen_clip_polyline.h b/desmume/src/windows/agg/include/agg_vpgen_clip_polyline.h deleted file mode 100644 index 31ab16e10..000000000 --- a/desmume/src/windows/agg/include/agg_vpgen_clip_polyline.h +++ /dev/null @@ -1,87 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_VPGEN_CLIP_POLYLINE_INCLUDED -#define AGG_VPGEN_CLIP_POLYLINE_INCLUDED - -#include "agg_basics.h" - -namespace agg -{ - - //======================================================vpgen_clip_polyline - // - // See Implementation agg_vpgen_clip_polyline.cpp - // - class vpgen_clip_polyline - { - public: - vpgen_clip_polyline() : - m_clip_box(0, 0, 1, 1), - m_x1(0), - m_y1(0), - m_num_vertices(0), - m_vertex(0), - m_move_to(false) - { - } - - void clip_box(double x1, double y1, double x2, double y2) - { - m_clip_box.x1 = x1; - m_clip_box.y1 = y1; - m_clip_box.x2 = x2; - m_clip_box.y2 = y2; - m_clip_box.normalize(); - } - - double x1() const { return m_clip_box.x1; } - double y1() const { return m_clip_box.y1; } - double x2() const { return m_clip_box.x2; } - double y2() const { return m_clip_box.y2; } - - static bool auto_close() { return false; } - static bool auto_unclose() { return true; } - - void reset(); - void move_to(double x, double y); - void line_to(double x, double y); - unsigned vertex(double* x, double* y); - - private: - rect_d m_clip_box; - double m_x1; - double m_y1; - double m_x[2]; - double m_y[2]; - unsigned m_cmd[2]; - unsigned m_num_vertices; - unsigned m_vertex; - bool m_move_to; - }; - -} - - -#endif diff --git a/desmume/src/windows/agg/include/agg_vpgen_segmentator.h b/desmume/src/windows/agg/include/agg_vpgen_segmentator.h deleted file mode 100644 index eba6052a6..000000000 --- a/desmume/src/windows/agg/include/agg_vpgen_segmentator.h +++ /dev/null @@ -1,70 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_VPGEN_SEGMENTATOR_INCLUDED -#define AGG_VPGEN_SEGMENTATOR_INCLUDED - -#include -#include "agg_basics.h" - -namespace agg -{ - - //=======================================================vpgen_segmentator - // - // See Implementation agg_vpgen_segmentator.cpp - // - class vpgen_segmentator - { - public: - vpgen_segmentator() : m_approximation_scale(1.0) {} - - void approximation_scale(double s) { m_approximation_scale = s; } - double approximation_scale() const { return m_approximation_scale; } - - static bool auto_close() { return false; } - static bool auto_unclose() { return false; } - - void reset() { m_cmd = path_cmd_stop; } - void move_to(double x, double y); - void line_to(double x, double y); - unsigned vertex(double* x, double* y); - - private: - double m_approximation_scale; - double m_x1; - double m_y1; - double m_dx; - double m_dy; - double m_dl; - double m_ddl; - unsigned m_cmd; - }; - - - -} - -#endif - diff --git a/desmume/src/windows/agg/include/ctrl/agg_bezier_ctrl.h b/desmume/src/windows/agg/include/ctrl/agg_bezier_ctrl.h deleted file mode 100644 index f4598e571..000000000 --- a/desmume/src/windows/agg/include/ctrl/agg_bezier_ctrl.h +++ /dev/null @@ -1,201 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_BEZIER_CTRL_INCLUDED -#define AGG_BEZIER_CTRL_INCLUDED - -#include "agg_math.h" -#include "agg_ellipse.h" -#include "agg_trans_affine.h" -#include "agg_color_rgba.h" -#include "agg_conv_stroke.h" -#include "agg_conv_curve.h" -#include "agg_polygon_ctrl.h" - - -namespace agg -{ - - //--------------------------------------------------------bezier_ctrl_impl - class bezier_ctrl_impl : public ctrl - { - public: - bezier_ctrl_impl(); - - void curve(double x1, double y1, - double x2, double y2, - double x3, double y3, - double x4, double y4); - curve4& curve(); - - double x1() const { return m_poly.xn(0); } - double y1() const { return m_poly.yn(0); } - double x2() const { return m_poly.xn(1); } - double y2() const { return m_poly.yn(1); } - double x3() const { return m_poly.xn(2); } - double y3() const { return m_poly.yn(2); } - double x4() const { return m_poly.xn(3); } - double y4() const { return m_poly.yn(3); } - - void x1(double x) { m_poly.xn(0) = x; } - void y1(double y) { m_poly.yn(0) = y; } - void x2(double x) { m_poly.xn(1) = x; } - void y2(double y) { m_poly.yn(1) = y; } - void x3(double x) { m_poly.xn(2) = x; } - void y3(double y) { m_poly.yn(2) = y; } - void x4(double x) { m_poly.xn(3) = x; } - void y4(double y) { m_poly.yn(3) = y; } - - void line_width(double w) { m_stroke.width(w); } - double line_width() const { return m_stroke.width(); } - - void point_radius(double r) { m_poly.point_radius(r); } - double point_radius() const { return m_poly.point_radius(); } - - virtual bool in_rect(double x, double y) const; - virtual bool on_mouse_button_down(double x, double y); - virtual bool on_mouse_button_up(double x, double y); - virtual bool on_mouse_move(double x, double y, bool button_flag); - virtual bool on_arrow_keys(bool left, bool right, bool down, bool up); - - // Vertex source interface - unsigned num_paths() { return 7; }; - void rewind(unsigned path_id); - unsigned vertex(double* x, double* y); - - - private: - curve4 m_curve; - ellipse m_ellipse; - conv_stroke m_stroke; - polygon_ctrl_impl m_poly; - unsigned m_idx; - }; - - - - //----------------------------------------------------------bezier_ctrl - template class bezier_ctrl : public bezier_ctrl_impl - { - public: - bezier_ctrl() : - m_color(rgba(0.0, 0.0, 0.0)) - { - } - - void line_color(const ColorT& c) { m_color = c; } - const ColorT& color(unsigned i) const { return m_color; } - - private: - bezier_ctrl(const bezier_ctrl&); - const bezier_ctrl& operator = (const bezier_ctrl&); - - ColorT m_color; - }; - - - - - - //--------------------------------------------------------curve3_ctrl_impl - class curve3_ctrl_impl : public ctrl - { - public: - curve3_ctrl_impl(); - - void curve(double x1, double y1, - double x2, double y2, - double x3, double y3); - curve3& curve(); - - double x1() const { return m_poly.xn(0); } - double y1() const { return m_poly.yn(0); } - double x2() const { return m_poly.xn(1); } - double y2() const { return m_poly.yn(1); } - double x3() const { return m_poly.xn(2); } - double y3() const { return m_poly.yn(2); } - - void x1(double x) { m_poly.xn(0) = x; } - void y1(double y) { m_poly.yn(0) = y; } - void x2(double x) { m_poly.xn(1) = x; } - void y2(double y) { m_poly.yn(1) = y; } - void x3(double x) { m_poly.xn(2) = x; } - void y3(double y) { m_poly.yn(2) = y; } - - void line_width(double w) { m_stroke.width(w); } - double line_width() const { return m_stroke.width(); } - - void point_radius(double r) { m_poly.point_radius(r); } - double point_radius() const { return m_poly.point_radius(); } - - virtual bool in_rect(double x, double y) const; - virtual bool on_mouse_button_down(double x, double y); - virtual bool on_mouse_button_up(double x, double y); - virtual bool on_mouse_move(double x, double y, bool button_flag); - virtual bool on_arrow_keys(bool left, bool right, bool down, bool up); - - // Vertex source interface - unsigned num_paths() { return 6; }; - void rewind(unsigned path_id); - unsigned vertex(double* x, double* y); - - - private: - curve3 m_curve; - ellipse m_ellipse; - conv_stroke m_stroke; - polygon_ctrl_impl m_poly; - unsigned m_idx; - }; - - - - //----------------------------------------------------------curve3_ctrl - template class curve3_ctrl : public curve3_ctrl_impl - { - public: - curve3_ctrl() : - m_color(rgba(0.0, 0.0, 0.0)) - { - } - - void line_color(const ColorT& c) { m_color = c; } - const ColorT& color(unsigned i) const { return m_color; } - - private: - curve3_ctrl(const curve3_ctrl&); - const curve3_ctrl& operator = (const curve3_ctrl&); - - ColorT m_color; - }; - - - - -} - - - -#endif - diff --git a/desmume/src/windows/agg/include/ctrl/agg_cbox_ctrl.h b/desmume/src/windows/agg/include/ctrl/agg_cbox_ctrl.h deleted file mode 100644 index 67b1228dd..000000000 --- a/desmume/src/windows/agg/include/ctrl/agg_cbox_ctrl.h +++ /dev/null @@ -1,117 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_CBOX_CTRL_INCLUDED -#define AGG_CBOX_CTRL_INCLUDED - -#include "agg_basics.h" -#include "agg_conv_stroke.h" -#include "agg_gsv_text.h" -#include "agg_trans_affine.h" -#include "agg_color_rgba.h" -#include "agg_ctrl.h" - - - -namespace agg -{ - - //----------------------------------------------------------cbox_ctrl_impl - class cbox_ctrl_impl : public ctrl - { - public: - cbox_ctrl_impl(double x, double y, const char* label, bool flip_y=false); - - void text_thickness(double t) { m_text_thickness = t; } - void text_size(double h, double w=0.0); - - const char* label() { return m_label; } - void label(const char* l); - - bool status() const { return m_status; } - void status(bool st) { m_status = st; } - - virtual bool in_rect(double x, double y) const; - virtual bool on_mouse_button_down(double x, double y); - virtual bool on_mouse_button_up(double x, double y); - virtual bool on_mouse_move(double x, double y, bool button_flag); - virtual bool on_arrow_keys(bool left, bool right, bool down, bool up); - - // Vertex soutce interface - unsigned num_paths() { return 3; }; - void rewind(unsigned path_id); - unsigned vertex(double* x, double* y); - - private: - double m_text_thickness; - double m_text_height; - double m_text_width; - char m_label[128]; - bool m_status; - double m_vx[32]; - double m_vy[32]; - - gsv_text m_text; - conv_stroke m_text_poly; - - unsigned m_idx; - unsigned m_vertex; - }; - - - //----------------------------------------------------------cbox_ctrl_impl - template class cbox_ctrl : public cbox_ctrl_impl - { - public: - cbox_ctrl(double x, double y, const char* label, bool flip_y=false) : - cbox_ctrl_impl(x, y, label, flip_y), - m_text_color(rgba(0.0, 0.0, 0.0)), - m_inactive_color(rgba(0.0, 0.0, 0.0)), - m_active_color(rgba(0.4, 0.0, 0.0)) - { - m_colors[0] = &m_inactive_color; - m_colors[1] = &m_text_color; - m_colors[2] = &m_active_color; - } - - void text_color(const ColorT& c) { m_text_color = c; } - void inactive_color(const ColorT& c) { m_inactive_color = c; } - void active_color(const ColorT& c) { m_active_color = c; } - - const ColorT& color(unsigned i) const { return *m_colors[i]; } - - private: - cbox_ctrl(const cbox_ctrl&); - const cbox_ctrl& operator = (const cbox_ctrl&); - - ColorT m_text_color; - ColorT m_inactive_color; - ColorT m_active_color; - ColorT* m_colors[3]; - }; - - -} - -#endif diff --git a/desmume/src/windows/agg/include/ctrl/agg_ctrl.h b/desmume/src/windows/agg/include/ctrl/agg_ctrl.h deleted file mode 100644 index fff2cb021..000000000 --- a/desmume/src/windows/agg/include/ctrl/agg_ctrl.h +++ /dev/null @@ -1,123 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_CTRL_INCLUDED -#define AGG_CTRL_INCLUDED - -#include "agg_trans_affine.h" -#include "agg_renderer_scanline.h" - -namespace agg -{ - - //--------------------------------------------------------------------ctrl - class ctrl - { - public: - //-------------------------------------------------------------------- - virtual ~ctrl() {} - ctrl(double x1, double y1, double x2, double y2, bool flip_y) : - m_x1(x1), m_y1(y1), m_x2(x2), m_y2(y2), - m_flip_y(flip_y), - m_mtx(0) - { - } - - //-------------------------------------------------------------------- - virtual bool in_rect(double x, double y) const = 0; - virtual bool on_mouse_button_down(double x, double y) = 0; - virtual bool on_mouse_button_up(double x, double y) = 0; - virtual bool on_mouse_move(double x, double y, bool button_flag) = 0; - virtual bool on_arrow_keys(bool left, bool right, bool down, bool up) = 0; - - //-------------------------------------------------------------------- - void transform(const trans_affine& mtx) { m_mtx = &mtx; } - void no_transform() { m_mtx = 0; } - - //-------------------------------------------------------------------- - void transform_xy(double* x, double* y) const - { - if(m_flip_y) *y = m_y1 + m_y2 - *y; - if(m_mtx) m_mtx->transform(x, y); - } - - //-------------------------------------------------------------------- - void inverse_transform_xy(double* x, double* y) const - { - if(m_mtx) m_mtx->inverse_transform(x, y); - if(m_flip_y) *y = m_y1 + m_y2 - *y; - } - - //-------------------------------------------------------------------- - double scale() const { return m_mtx ? m_mtx->scale() : 1.0; } - - private: - ctrl(const ctrl&); - const ctrl& operator = (const ctrl&); - - protected: - double m_x1; - double m_y1; - double m_x2; - double m_y2; - - private: - bool m_flip_y; - const trans_affine* m_mtx; - }; - - - //-------------------------------------------------------------------- - template - void render_ctrl(Rasterizer& ras, Scanline& sl, Renderer& r, Ctrl& c) - { - unsigned i; - for(i = 0; i < c.num_paths(); i++) - { - ras.reset(); - ras.add_path(c, i); - render_scanlines_aa_solid(ras, sl, r, c.color(i)); - } - } - - - //-------------------------------------------------------------------- - template - void render_ctrl_rs(Rasterizer& ras, Scanline& sl, Renderer& r, Ctrl& c) - { - unsigned i; - for(i = 0; i < c.num_paths(); i++) - { - ras.reset(); - ras.add_path(c, i); - r.color(c.color(i)); - render_scanlines(ras, sl, r); - } - } - - -} - - -#endif diff --git a/desmume/src/windows/agg/include/ctrl/agg_gamma_ctrl.h b/desmume/src/windows/agg/include/ctrl/agg_gamma_ctrl.h deleted file mode 100644 index 58b2130ac..000000000 --- a/desmume/src/windows/agg/include/ctrl/agg_gamma_ctrl.h +++ /dev/null @@ -1,175 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_GAMMA_CTRL_INCLUDED -#define AGG_GAMMA_CTRL_INCLUDED - -#include "agg_basics.h" -#include "agg_gamma_spline.h" -#include "agg_ellipse.h" -#include "agg_conv_stroke.h" -#include "agg_gsv_text.h" -#include "agg_trans_affine.h" -#include "agg_color_rgba.h" -#include "agg_ctrl.h" - -namespace agg -{ - //------------------------------------------------------------------------ - // Class that can be used to create an interactive control to set up - // gamma arrays. - //------------------------------------------------------------------------ - class gamma_ctrl_impl : public ctrl - { - public: - gamma_ctrl_impl(double x1, double y1, double x2, double y2, bool flip_y=false); - - // Set other parameters - void border_width(double t, double extra=0.0); - void curve_width(double t) { m_curve_width = t; } - void grid_width(double t) { m_grid_width = t; } - void text_thickness(double t) { m_text_thickness = t; } - void text_size(double h, double w=0.0); - void point_size(double s) { m_point_size = s; } - - // Event handlers. Just call them if the respective events - // in your system occure. The functions return true if redrawing - // is required. - virtual bool in_rect(double x, double y) const; - virtual bool on_mouse_button_down(double x, double y); - virtual bool on_mouse_button_up(double x, double y); - virtual bool on_mouse_move(double x, double y, bool button_flag); - virtual bool on_arrow_keys(bool left, bool right, bool down, bool up); - - void change_active_point(); - - // A copy of agg::gamma_spline interface - void values(double kx1, double ky1, double kx2, double ky2); - void values(double* kx1, double* ky1, double* kx2, double* ky2) const; - const unsigned char* gamma() const { return m_gamma_spline.gamma(); } - double y(double x) const { return m_gamma_spline.y(x); } - double operator() (double x) const { return m_gamma_spline.y(x); } - const gamma_spline& get_gamma_spline() const { return m_gamma_spline; } - - // Vertex soutce interface - unsigned num_paths() { return 7; } - void rewind(unsigned idx); - unsigned vertex(double* x, double* y); - - private: - void calc_spline_box(); - void calc_points(); - void calc_values(); - - gamma_spline m_gamma_spline; - double m_border_width; - double m_border_extra; - double m_curve_width; - double m_grid_width; - double m_text_thickness; - double m_point_size; - double m_text_height; - double m_text_width; - double m_xc1; - double m_yc1; - double m_xc2; - double m_yc2; - double m_xs1; - double m_ys1; - double m_xs2; - double m_ys2; - double m_xt1; - double m_yt1; - double m_xt2; - double m_yt2; - conv_stroke m_curve_poly; - ellipse m_ellipse; - gsv_text m_text; - conv_stroke m_text_poly; - unsigned m_idx; - unsigned m_vertex; - double m_vx[32]; - double m_vy[32]; - double m_xp1; - double m_yp1; - double m_xp2; - double m_yp2; - bool m_p1_active; - unsigned m_mouse_point; - double m_pdx; - double m_pdy; - }; - - - - template class gamma_ctrl : public gamma_ctrl_impl - { - public: - gamma_ctrl(double x1, double y1, double x2, double y2, bool flip_y=false) : - gamma_ctrl_impl(x1, y1, x2, y2, flip_y), - m_background_color(rgba(1.0, 1.0, 0.9)), - m_border_color(rgba(0.0, 0.0, 0.0)), - m_curve_color(rgba(0.0, 0.0, 0.0)), - m_grid_color(rgba(0.2, 0.2, 0.0)), - m_inactive_pnt_color(rgba(0.0, 0.0, 0.0)), - m_active_pnt_color(rgba(1.0, 0.0, 0.0)), - m_text_color(rgba(0.0, 0.0, 0.0)) - { - m_colors[0] = &m_background_color; - m_colors[1] = &m_border_color; - m_colors[2] = &m_curve_color; - m_colors[3] = &m_grid_color; - m_colors[4] = &m_inactive_pnt_color; - m_colors[5] = &m_active_pnt_color; - m_colors[6] = &m_text_color; - } - - // Set colors - void background_color(const ColorT& c) { m_background_color = c; } - void border_color(const ColorT& c) { m_border_color = c; } - void curve_color(const ColorT& c) { m_curve_color = c; } - void grid_color(const ColorT& c) { m_grid_color = c; } - void inactive_pnt_color(const ColorT& c) { m_inactive_pnt_color = c; } - void active_pnt_color(const ColorT& c) { m_active_pnt_color = c; } - void text_color(const ColorT& c) { m_text_color = c; } - const ColorT& color(unsigned i) const { return *m_colors[i]; } - - private: - gamma_ctrl(const gamma_ctrl&); - const gamma_ctrl& operator = (const gamma_ctrl&); - - ColorT m_background_color; - ColorT m_border_color; - ColorT m_curve_color; - ColorT m_grid_color; - ColorT m_inactive_pnt_color; - ColorT m_active_pnt_color; - ColorT m_text_color; - ColorT* m_colors[7]; - }; - - -} - -#endif diff --git a/desmume/src/windows/agg/include/ctrl/agg_gamma_spline.h b/desmume/src/windows/agg/include/ctrl/agg_gamma_spline.h deleted file mode 100644 index db5d8ee02..000000000 --- a/desmume/src/windows/agg/include/ctrl/agg_gamma_spline.h +++ /dev/null @@ -1,100 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_GAMMA_SPLINE_INCLUDED -#define AGG_GAMMA_SPLINE_INCLUDED - -#include "agg_basics.h" -#include "agg_bspline.h" - -namespace agg -{ - - //------------------------------------------------------------------------ - // Class-helper for calculation gamma-correction arrays. A gamma-correction - // array is an array of 256 unsigned chars that determine the actual values - // of Anti-Aliasing for each pixel coverage value from 0 to 255. If all the - // values in the array are equal to its index, i.e. 0,1,2,3,... there's - // no gamma-correction. Class agg::polyfill allows you to use custom - // gamma-correction arrays. You can calculate it using any approach, and - // class gamma_spline allows you to calculate almost any reasonable shape - // of the gamma-curve with using only 4 values - kx1, ky1, kx2, ky2. - // - // kx2 - // +----------------------------------+ - // | | | . | - // | | | . | ky2 - // | | . ------| - // | | . | - // | | . | - // |----------------.|----------------| - // | . | | - // | . | | - // |-------. | | - // ky1 | . | | | - // | . | | | - // +----------------------------------+ - // kx1 - // - // Each value can be in range [0...2]. Value 1.0 means one quarter of the - // bounding rectangle. Function values() calculates the curve by these - // 4 values. After calling it one can get the gamma-array with call gamma(). - // Class also supports the vertex source interface, i.e rewind() and - // vertex(). It's made for convinience and used in class gamma_ctrl. - // Before calling rewind/vertex one must set the bounding box - // box() using pixel coordinates. - //------------------------------------------------------------------------ - - class gamma_spline - { - public: - gamma_spline(); - - void values(double kx1, double ky1, double kx2, double ky2); - const unsigned char* gamma() const { return m_gamma; } - double y(double x) const; - void values(double* kx1, double* ky1, double* kx2, double* ky2) const; - void box(double x1, double y1, double x2, double y2); - - void rewind(unsigned); - unsigned vertex(double* x, double* y); - - private: - unsigned char m_gamma[256]; - double m_x[4]; - double m_y[4]; - bspline m_spline; - double m_x1; - double m_y1; - double m_x2; - double m_y2; - double m_cur_x; - }; - - - - -} - -#endif diff --git a/desmume/src/windows/agg/include/ctrl/agg_polygon_ctrl.h b/desmume/src/windows/agg/include/ctrl/agg_polygon_ctrl.h deleted file mode 100644 index f23e09452..000000000 --- a/desmume/src/windows/agg/include/ctrl/agg_polygon_ctrl.h +++ /dev/null @@ -1,171 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef POLYGON_CTRL_INCLUDED -#define POLYGON_CTRL_INCLUDED - -#include "agg_array.h" -#include "agg_conv_stroke.h" -#include "agg_ellipse.h" -#include "agg_color_rgba.h" -#include "agg_ctrl.h" - -namespace agg -{ - class simple_polygon_vertex_source - { - public: - simple_polygon_vertex_source(const double* polygon, unsigned np, - bool roundoff = false, - bool close = true) : - m_polygon(polygon), - m_num_points(np), - m_vertex(0), - m_roundoff(roundoff), - m_close(close) - { - } - - void close(bool f) { m_close = f; } - bool close() const { return m_close; } - - void rewind(unsigned) - { - m_vertex = 0; - } - - unsigned vertex(double* x, double* y) - { - if(m_vertex > m_num_points) return path_cmd_stop; - if(m_vertex == m_num_points) - { - ++m_vertex; - return path_cmd_end_poly | (m_close ? path_flags_close : 0); - } - *x = m_polygon[m_vertex * 2]; - *y = m_polygon[m_vertex * 2 + 1]; - if(m_roundoff) - { - *x = floor(*x) + 0.5; - *y = floor(*y) + 0.5; - } - ++m_vertex; - return (m_vertex == 1) ? path_cmd_move_to : path_cmd_line_to; - } - - private: - const double* m_polygon; - unsigned m_num_points; - unsigned m_vertex; - bool m_roundoff; - bool m_close; - }; - - - - - class polygon_ctrl_impl : public ctrl - { - public: - polygon_ctrl_impl(unsigned np, double point_radius=5); - - unsigned num_points() const { return m_num_points; } - double xn(unsigned n) const { return m_polygon[n * 2]; } - double yn(unsigned n) const { return m_polygon[n * 2 + 1]; } - double& xn(unsigned n) { return m_polygon[n * 2]; } - double& yn(unsigned n) { return m_polygon[n * 2 + 1]; } - - const double* polygon() const { return &m_polygon[0]; } - - void line_width(double w) { m_stroke.width(w); } - double line_width() const { return m_stroke.width(); } - - void point_radius(double r) { m_point_radius = r; } - double point_radius() const { return m_point_radius; } - - void in_polygon_check(bool f) { m_in_polygon_check = f; } - bool in_polygon_check() const { return m_in_polygon_check; } - - void close(bool f) { m_vs.close(f); } - bool close() const { return m_vs.close(); } - - // Vertex source interface - unsigned num_paths() { return 1; } - void rewind(unsigned path_id); - unsigned vertex(double* x, double* y); - - virtual bool in_rect(double x, double y) const; - virtual bool on_mouse_button_down(double x, double y); - virtual bool on_mouse_button_up(double x, double y); - virtual bool on_mouse_move(double x, double y, bool button_flag); - virtual bool on_arrow_keys(bool left, bool right, bool down, bool up); - - - private: - bool check_edge(unsigned i, double x, double y) const; - bool point_in_polygon(double x, double y) const; - - pod_array m_polygon; - unsigned m_num_points; - int m_node; - int m_edge; - simple_polygon_vertex_source m_vs; - conv_stroke m_stroke; - ellipse m_ellipse; - double m_point_radius; - unsigned m_status; - double m_dx; - double m_dy; - bool m_in_polygon_check; - }; - - - - //----------------------------------------------------------polygon_ctrl - template class polygon_ctrl : public polygon_ctrl_impl - { - public: - polygon_ctrl(unsigned np, double point_radius=5) : - polygon_ctrl_impl(np, point_radius), - m_color(rgba(0.0, 0.0, 0.0)) - { - } - - void line_color(const ColorT& c) { m_color = c; } - const ColorT& color(unsigned i) const { return m_color; } - - private: - polygon_ctrl(const polygon_ctrl&); - const polygon_ctrl& operator = (const polygon_ctrl&); - - ColorT m_color; - }; - - - - -} - -#endif - diff --git a/desmume/src/windows/agg/include/ctrl/agg_rbox_ctrl.h b/desmume/src/windows/agg/include/ctrl/agg_rbox_ctrl.h deleted file mode 100644 index c1c406613..000000000 --- a/desmume/src/windows/agg/include/ctrl/agg_rbox_ctrl.h +++ /dev/null @@ -1,146 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_RBOX_CTRL_INCLUDED -#define AGG_RBOX_CTRL_INCLUDED - -#include "agg_array.h" -#include "agg_ellipse.h" -#include "agg_conv_stroke.h" -#include "agg_gsv_text.h" -#include "agg_trans_affine.h" -#include "agg_color_rgba.h" -#include "agg_ctrl.h" - - - -namespace agg -{ - - //------------------------------------------------------------------------ - class rbox_ctrl_impl : public ctrl - { - public: - rbox_ctrl_impl(double x1, double y1, double x2, double y2, bool flip_y=false); - - void border_width(double t, double extra=0.0); - void text_thickness(double t) { m_text_thickness = t; } - void text_size(double h, double w=0.0); - - void add_item(const char* text); - int cur_item() const { return m_cur_item; } - void cur_item(int i) { m_cur_item = i; } - - virtual bool in_rect(double x, double y) const; - virtual bool on_mouse_button_down(double x, double y); - virtual bool on_mouse_button_up(double x, double y); - virtual bool on_mouse_move(double x, double y, bool button_flag); - virtual bool on_arrow_keys(bool left, bool right, bool down, bool up); - - // Vertex soutce interface - unsigned num_paths() { return 5; }; - void rewind(unsigned path_id); - unsigned vertex(double* x, double* y); - - private: - void calc_rbox(); - - double m_border_width; - double m_border_extra; - double m_text_thickness; - double m_text_height; - double m_text_width; - pod_array m_items[32]; - unsigned m_num_items; - int m_cur_item; - - double m_xs1; - double m_ys1; - double m_xs2; - double m_ys2; - - double m_vx[32]; - double m_vy[32]; - unsigned m_draw_item; - double m_dy; - - ellipse m_ellipse; - conv_stroke m_ellipse_poly; - gsv_text m_text; - conv_stroke m_text_poly; - - unsigned m_idx; - unsigned m_vertex; - }; - - - - //------------------------------------------------------------------------ - template class rbox_ctrl : public rbox_ctrl_impl - { - public: - rbox_ctrl(double x1, double y1, double x2, double y2, bool flip_y=false) : - rbox_ctrl_impl(x1, y1, x2, y2, flip_y), - m_background_color(rgba(1.0, 1.0, 0.9)), - m_border_color(rgba(0.0, 0.0, 0.0)), - m_text_color(rgba(0.0, 0.0, 0.0)), - m_inactive_color(rgba(0.0, 0.0, 0.0)), - m_active_color(rgba(0.4, 0.0, 0.0)) - { - m_colors[0] = &m_background_color; - m_colors[1] = &m_border_color; - m_colors[2] = &m_text_color; - m_colors[3] = &m_inactive_color; - m_colors[4] = &m_active_color; - } - - - void background_color(const ColorT& c) { m_background_color = c; } - void border_color(const ColorT& c) { m_border_color = c; } - void text_color(const ColorT& c) { m_text_color = c; } - void inactive_color(const ColorT& c) { m_inactive_color = c; } - void active_color(const ColorT& c) { m_active_color = c; } - - const ColorT& color(unsigned i) const { return *m_colors[i]; } - - private: - rbox_ctrl(const rbox_ctrl&); - const rbox_ctrl& operator = (const rbox_ctrl&); - - ColorT m_background_color; - ColorT m_border_color; - ColorT m_text_color; - ColorT m_inactive_color; - ColorT m_active_color; - ColorT* m_colors[5]; - }; - - - -} - - - -#endif - diff --git a/desmume/src/windows/agg/include/ctrl/agg_scale_ctrl.h b/desmume/src/windows/agg/include/ctrl/agg_scale_ctrl.h deleted file mode 100644 index 40f95f998..000000000 --- a/desmume/src/windows/agg/include/ctrl/agg_scale_ctrl.h +++ /dev/null @@ -1,151 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_SCALE_CTRL_INCLUDED -#define AGG_SCALE_CTRL_INCLUDED - -#include "agg_basics.h" -#include "agg_math.h" -#include "agg_ellipse.h" -#include "agg_trans_affine.h" -#include "agg_color_rgba.h" -#include "agg_ctrl.h" - - -namespace agg -{ - - //------------------------------------------------------------------------ - class scale_ctrl_impl : public ctrl - { - enum move_e - { - move_nothing, - move_value1, - move_value2, - move_slider - }; - - public: - scale_ctrl_impl(double x1, double y1, double x2, double y2, bool flip_y=false); - - void border_thickness(double t, double extra=0.0); - void resize(double x1, double y1, double x2, double y2); - - double min_delta() const { return m_min_d; } - void min_delta(double d) { m_min_d = d; } - - double value1() const { return m_value1; } - void value1(double value); - - double value2() const { return m_value2; } - void value2(double value); - - void move(double d); - - virtual bool in_rect(double x, double y) const; - virtual bool on_mouse_button_down(double x, double y); - virtual bool on_mouse_button_up(double x, double y); - virtual bool on_mouse_move(double x, double y, bool button_flag); - virtual bool on_arrow_keys(bool left, bool right, bool down, bool up); - - // Vertex soutce interface - unsigned num_paths() { return 5; }; - void rewind(unsigned path_id); - unsigned vertex(double* x, double* y); - - private: - void calc_box(); - - double m_border_thickness; - double m_border_extra; - double m_value1; - double m_value2; - double m_min_d; - double m_xs1; - double m_ys1; - double m_xs2; - double m_ys2; - double m_pdx; - double m_pdy; - move_e m_move_what; - double m_vx[32]; - double m_vy[32]; - - ellipse m_ellipse; - - unsigned m_idx; - unsigned m_vertex; - - }; - - - - //------------------------------------------------------------------------ - template class scale_ctrl : public scale_ctrl_impl - { - public: - scale_ctrl(double x1, double y1, double x2, double y2, bool flip_y=false) : - scale_ctrl_impl(x1, y1, x2, y2, flip_y), - m_background_color(rgba(1.0, 0.9, 0.8)), - m_border_color(rgba(0.0, 0.0, 0.0)), - m_pointers_color(rgba(0.8, 0.0, 0.0, 0.8)), - m_slider_color(rgba(0.2, 0.1, 0.0, 0.6)) - { - m_colors[0] = &m_background_color; - m_colors[1] = &m_border_color; - m_colors[2] = &m_pointers_color; - m_colors[3] = &m_pointers_color; - m_colors[4] = &m_slider_color; - } - - - void background_color(const ColorT& c) { m_background_color = c; } - void border_color(const ColorT& c) { m_border_color = c; } - void pointers_color(const ColorT& c) { m_pointers_color = c; } - void slider_color(const ColorT& c) { m_slider_color = c; } - - const ColorT& color(unsigned i) const { return *m_colors[i]; } - - private: - scale_ctrl(const scale_ctrl&); - const scale_ctrl& operator = (const scale_ctrl&); - - ColorT m_background_color; - ColorT m_border_color; - ColorT m_pointers_color; - ColorT m_slider_color; - ColorT* m_colors[5]; - }; - - - - - -} - - - -#endif - diff --git a/desmume/src/windows/agg/include/ctrl/agg_slider_ctrl.h b/desmume/src/windows/agg/include/ctrl/agg_slider_ctrl.h deleted file mode 100644 index 54f45caa2..000000000 --- a/desmume/src/windows/agg/include/ctrl/agg_slider_ctrl.h +++ /dev/null @@ -1,155 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_SLIDER_CTRL_INCLUDED -#define AGG_SLIDER_CTRL_INCLUDED - -#include "agg_basics.h" -#include "agg_math.h" -#include "agg_ellipse.h" -#include "agg_trans_affine.h" -#include "agg_color_rgba.h" -#include "agg_gsv_text.h" -#include "agg_conv_stroke.h" -#include "agg_path_storage.h" -#include "agg_ctrl.h" - - -namespace agg -{ - - //--------------------------------------------------------slider_ctrl_impl - class slider_ctrl_impl : public ctrl - { - public: - slider_ctrl_impl(double x1, double y1, double x2, double y2, bool flip_y=false); - - void border_width(double t, double extra=0.0); - - void range(double min, double max) { m_min = min; m_max = max; } - void num_steps(unsigned num) { m_num_steps = num; } - void label(const char* fmt); - void text_thickness(double t) { m_text_thickness = t; } - - bool descending() const { return m_descending; } - void descending(bool v) { m_descending = v; } - - double value() const { return m_value * (m_max - m_min) + m_min; } - void value(double value); - - virtual bool in_rect(double x, double y) const; - virtual bool on_mouse_button_down(double x, double y); - virtual bool on_mouse_button_up(double x, double y); - virtual bool on_mouse_move(double x, double y, bool button_flag); - virtual bool on_arrow_keys(bool left, bool right, bool down, bool up); - - // Vertex source interface - unsigned num_paths() { return 6; }; - void rewind(unsigned path_id); - unsigned vertex(double* x, double* y); - - private: - void calc_box(); - bool normalize_value(bool preview_value_flag); - - double m_border_width; - double m_border_extra; - double m_text_thickness; - double m_value; - double m_preview_value; - double m_min; - double m_max; - unsigned m_num_steps; - bool m_descending; - char m_label[64]; - double m_xs1; - double m_ys1; - double m_xs2; - double m_ys2; - double m_pdx; - bool m_mouse_move; - double m_vx[32]; - double m_vy[32]; - - ellipse m_ellipse; - - unsigned m_idx; - unsigned m_vertex; - - gsv_text m_text; - conv_stroke m_text_poly; - path_storage m_storage; - - }; - - - - //----------------------------------------------------------slider_ctrl - template class slider_ctrl : public slider_ctrl_impl - { - public: - slider_ctrl(double x1, double y1, double x2, double y2, bool flip_y=false) : - slider_ctrl_impl(x1, y1, x2, y2, flip_y), - m_background_color(rgba(1.0, 0.9, 0.8)), - m_triangle_color(rgba(0.7, 0.6, 0.6)), - m_text_color(rgba(0.0, 0.0, 0.0)), - m_pointer_preview_color(rgba(0.6, 0.4, 0.4, 0.4)), - m_pointer_color(rgba(0.8, 0.0, 0.0, 0.6)) - { - m_colors[0] = &m_background_color; - m_colors[1] = &m_triangle_color; - m_colors[2] = &m_text_color; - m_colors[3] = &m_pointer_preview_color; - m_colors[4] = &m_pointer_color; - m_colors[5] = &m_text_color; - } - - - void background_color(const ColorT& c) { m_background_color = c; } - void pointer_color(const ColorT& c) { m_pointer_color = c; } - - const ColorT& color(unsigned i) const { return *m_colors[i]; } - - private: - slider_ctrl(const slider_ctrl&); - const slider_ctrl& operator = (const slider_ctrl&); - - ColorT m_background_color; - ColorT m_triangle_color; - ColorT m_text_color; - ColorT m_pointer_preview_color; - ColorT m_pointer_color; - ColorT* m_colors[6]; - }; - - - - - -} - - - -#endif - diff --git a/desmume/src/windows/agg/include/ctrl/agg_spline_ctrl.h b/desmume/src/windows/agg/include/ctrl/agg_spline_ctrl.h deleted file mode 100644 index 31591fd29..000000000 --- a/desmume/src/windows/agg/include/ctrl/agg_spline_ctrl.h +++ /dev/null @@ -1,164 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_SPLINE_CTRL_INCLUDED -#define AGG_SPLINE_CTRL_INCLUDED - -#include "agg_basics.h" -#include "agg_ellipse.h" -#include "agg_bspline.h" -#include "agg_conv_stroke.h" -#include "agg_path_storage.h" -#include "agg_trans_affine.h" -#include "agg_color_rgba.h" -#include "agg_ctrl.h" - -namespace agg -{ - - //------------------------------------------------------------------------ - // Class that can be used to create an interactive control to set up - // gamma arrays. - //------------------------------------------------------------------------ - class spline_ctrl_impl : public ctrl - { - public: - spline_ctrl_impl(double x1, double y1, double x2, double y2, - unsigned num_pnt, bool flip_y=false); - - // Set other parameters - void border_width(double t, double extra=0.0); - void curve_width(double t) { m_curve_width = t; } - void point_size(double s) { m_point_size = s; } - - // Event handlers. Just call them if the respective events - // in your system occure. The functions return true if redrawing - // is required. - virtual bool in_rect(double x, double y) const; - virtual bool on_mouse_button_down(double x, double y); - virtual bool on_mouse_button_up(double x, double y); - virtual bool on_mouse_move(double x, double y, bool button_flag); - virtual bool on_arrow_keys(bool left, bool right, bool down, bool up); - - void active_point(int i); - - const double* spline() const { return m_spline_values; } - const int8u* spline8() const { return m_spline_values8; } - double value(double x) const; - void value(unsigned idx, double y); - void point(unsigned idx, double x, double y); - void x(unsigned idx, double x) { m_xp[idx] = x; } - void y(unsigned idx, double y) { m_yp[idx] = y; } - double x(unsigned idx) const { return m_xp[idx]; } - double y(unsigned idx) const { return m_yp[idx]; } - void update_spline(); - - // Vertex soutce interface - unsigned num_paths() { return 5; } - void rewind(unsigned path_id); - unsigned vertex(double* x, double* y); - - private: - void calc_spline_box(); - void calc_curve(); - double calc_xp(unsigned idx); - double calc_yp(unsigned idx); - void set_xp(unsigned idx, double val); - void set_yp(unsigned idx, double val); - - unsigned m_num_pnt; - double m_xp[32]; - double m_yp[32]; - bspline m_spline; - double m_spline_values[256]; - int8u m_spline_values8[256]; - double m_border_width; - double m_border_extra; - double m_curve_width; - double m_point_size; - double m_xs1; - double m_ys1; - double m_xs2; - double m_ys2; - path_storage m_curve_pnt; - conv_stroke m_curve_poly; - ellipse m_ellipse; - unsigned m_idx; - unsigned m_vertex; - double m_vx[32]; - double m_vy[32]; - int m_active_pnt; - int m_move_pnt; - double m_pdx; - double m_pdy; - const trans_affine* m_mtx; - }; - - - template class spline_ctrl : public spline_ctrl_impl - { - public: - spline_ctrl(double x1, double y1, double x2, double y2, - unsigned num_pnt, bool flip_y=false) : - spline_ctrl_impl(x1, y1, x2, y2, num_pnt, flip_y), - m_background_color(rgba(1.0, 1.0, 0.9)), - m_border_color(rgba(0.0, 0.0, 0.0)), - m_curve_color(rgba(0.0, 0.0, 0.0)), - m_inactive_pnt_color(rgba(0.0, 0.0, 0.0)), - m_active_pnt_color(rgba(1.0, 0.0, 0.0)) - { - m_colors[0] = &m_background_color; - m_colors[1] = &m_border_color; - m_colors[2] = &m_curve_color; - m_colors[3] = &m_inactive_pnt_color; - m_colors[4] = &m_active_pnt_color; - } - - // Set colors - void background_color(const ColorT& c) { m_background_color = c; } - void border_color(const ColorT& c) { m_border_color = c; } - void curve_color(const ColorT& c) { m_curve_color = c; } - void inactive_pnt_color(const ColorT& c) { m_inactive_pnt_color = c; } - void active_pnt_color(const ColorT& c) { m_active_pnt_color = c; } - const ColorT& color(unsigned i) const { return *m_colors[i]; } - - private: - spline_ctrl(const spline_ctrl&); - const spline_ctrl& operator = (const spline_ctrl&); - - ColorT m_background_color; - ColorT m_border_color; - ColorT m_curve_color; - ColorT m_inactive_pnt_color; - ColorT m_active_pnt_color; - ColorT* m_colors[5]; - }; - - - - -} - - -#endif diff --git a/desmume/src/windows/agg/include/platform/agg_platform_support.h b/desmume/src/windows/agg/include/platform/agg_platform_support.h deleted file mode 100644 index a2b18e84a..000000000 --- a/desmume/src/windows/agg/include/platform/agg_platform_support.h +++ /dev/null @@ -1,680 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- -// -// class platform_support -// -// It's not a part of the AGG library, it's just a helper class to create -// interactive demo examples. Since the examples should not be too complex -// this class is provided to support some very basic interactive graphical -// funtionality, such as putting the rendered image to the window, simple -// keyboard and mouse input, window resizing, setting the window title, -// and catching the "idle" events. -// -// The idea is to have a single header file that does not depend on any -// platform (I hate these endless #ifdef/#elif/#elif.../#endif) and a number -// of different implementations depending on the concrete platform. -// The most popular platforms are: -// -// Windows-32 API -// X-Window API -// SDL library (see http://www.libsdl.org/) -// MacOS C/C++ API -// -// This file does not include any system dependent .h files such as -// windows.h or X11.h, so, your demo applications do not depend on the -// platform. The only file that can #include system dependend headers -// is the implementation file agg_platform_support.cpp. Different -// implementations are placed in different directories, such as -// ~/agg/src/platform/win32 -// ~/agg/src/platform/sdl -// ~/agg/src/platform/X11 -// and so on. -// -// All the system dependent stuff sits in the platform_specific -// class which is forward-declared here but not defined. -// The platform_support class has just a pointer to it and it's -// the responsibility of the implementation to create/delete it. -// This class being defined in the implementation file can have -// any platform dependent stuff such as HWND, X11 Window and so on. -// -//---------------------------------------------------------------------------- - - -#ifndef AGG_PLATFORM_SUPPORT_INCLUDED -#define AGG_PLATFORM_SUPPORT_INCLUDED - - -#include "agg_basics.h" -#include "agg_rendering_buffer.h" -#include "agg_trans_viewport.h" -#include "ctrl/agg_ctrl.h" - -namespace agg -{ - - //----------------------------------------------------------window_flag_e - // These are flags used in method init(). Not all of them are - // applicable on different platforms, for example the win32_api - // cannot use a hardware buffer (window_hw_buffer). - // The implementation should simply ignore unsupported flags. - enum window_flag_e - { - window_resize = 1, - window_hw_buffer = 2, - window_keep_aspect_ratio = 4, - window_process_all_keys = 8 - }; - - //-----------------------------------------------------------pix_format_e - // Possible formats of the rendering buffer. Initially I thought that it's - // reasonable to create the buffer and the rendering functions in - // accordance with the native pixel format of the system because it - // would have no overhead for pixel format conersion. - // But eventually I came to a conclusion that having a possibility to - // convert pixel formats on demand is a good idea. First, it was X11 where - // there lots of different formats and visuals and it would be great to - // render everything in, say, RGB-24 and display it automatically without - // any additional efforts. The second reason is to have a possibility to - // debug renderers for different pixel formats and colorspaces having only - // one computer and one system. - // - // This stuff is not included into the basic AGG functionality because the - // number of supported pixel formats (and/or colorspaces) can be great and - // if one needs to add new format it would be good only to add new - // rendering files without having to modify any existing ones (a general - // principle of incapsulation and isolation). - // - // Using a particular pixel format doesn't obligatory mean the necessity - // of software conversion. For example, win32 API can natively display - // gray8, 15-bit RGB, 24-bit BGR, and 32-bit BGRA formats. - // This list can be (and will be!) extended in future. - enum pix_format_e - { - pix_format_undefined = 0, // By default. No conversions are applied - pix_format_bw, // 1 bit per color B/W - pix_format_gray8, // Simple 256 level grayscale - pix_format_gray16, // Simple 65535 level grayscale - pix_format_rgb555, // 15 bit rgb. Depends on the byte ordering! - pix_format_rgb565, // 16 bit rgb. Depends on the byte ordering! - pix_format_rgbAAA, // 30 bit rgb. Depends on the byte ordering! - pix_format_rgbBBA, // 32 bit rgb. Depends on the byte ordering! - pix_format_bgrAAA, // 30 bit bgr. Depends on the byte ordering! - pix_format_bgrABB, // 32 bit bgr. Depends on the byte ordering! - pix_format_rgb24, // R-G-B, one byte per color component - pix_format_bgr24, // B-G-R, native win32 BMP format. - pix_format_rgba32, // R-G-B-A, one byte per color component - pix_format_argb32, // A-R-G-B, native MAC format - pix_format_abgr32, // A-B-G-R, one byte per color component - pix_format_bgra32, // B-G-R-A, native win32 BMP format - pix_format_rgb48, // R-G-B, 16 bits per color component - pix_format_bgr48, // B-G-R, native win32 BMP format. - pix_format_rgba64, // R-G-B-A, 16 bits byte per color component - pix_format_argb64, // A-R-G-B, native MAC format - pix_format_abgr64, // A-B-G-R, one byte per color component - pix_format_bgra64, // B-G-R-A, native win32 BMP format - - end_of_pix_formats - }; - - //-------------------------------------------------------------input_flag_e - // Mouse and keyboard flags. They can be different on different platforms - // and the ways they are obtained are also different. But in any case - // the system dependent flags should be mapped into these ones. The meaning - // of that is as follows. For example, if kbd_ctrl is set it means that the - // ctrl key is pressed and being held at the moment. They are also used in - // the overridden methods such as on_mouse_move(), on_mouse_button_down(), - // on_mouse_button_dbl_click(), on_mouse_button_up(), on_key(). - // In the method on_mouse_button_up() the mouse flags have different - // meaning. They mean that the respective button is being released, but - // the meaning of the keyboard flags remains the same. - // There's absolut minimal set of flags is used because they'll be most - // probably supported on different platforms. Even the mouse_right flag - // is restricted because Mac's mice have only one button, but AFAIK - // it can be simulated with holding a special key on the keydoard. - enum input_flag_e - { - mouse_left = 1, - mouse_right = 2, - kbd_shift = 4, - kbd_ctrl = 8 - }; - - //--------------------------------------------------------------key_code_e - // Keyboard codes. There's also a restricted set of codes that are most - // probably supported on different platforms. Any platform dependent codes - // should be converted into these ones. There're only those codes are - // defined that cannot be represented as printable ASCII-characters. - // All printable ASCII-set can be used in a regular C/C++ manner: - // ' ', 'A', '0' '+' and so on. - // Since the class is used for creating very simple demo-applications - // we don't need very rich possibilities here, just basic ones. - // Actually the numeric key codes are taken from the SDL library, so, - // the implementation of the SDL support does not require any mapping. - enum key_code_e - { - // ASCII set. Should be supported everywhere - key_backspace = 8, - key_tab = 9, - key_clear = 12, - key_return = 13, - key_pause = 19, - key_escape = 27, - - // Keypad - key_delete = 127, - key_kp0 = 256, - key_kp1 = 257, - key_kp2 = 258, - key_kp3 = 259, - key_kp4 = 260, - key_kp5 = 261, - key_kp6 = 262, - key_kp7 = 263, - key_kp8 = 264, - key_kp9 = 265, - key_kp_period = 266, - key_kp_divide = 267, - key_kp_multiply = 268, - key_kp_minus = 269, - key_kp_plus = 270, - key_kp_enter = 271, - key_kp_equals = 272, - - // Arrow-keys and stuff - key_up = 273, - key_down = 274, - key_right = 275, - key_left = 276, - key_insert = 277, - key_home = 278, - key_end = 279, - key_page_up = 280, - key_page_down = 281, - - // Functional keys. You'd better avoid using - // f11...f15 in your applications if you want - // the applications to be portable - key_f1 = 282, - key_f2 = 283, - key_f3 = 284, - key_f4 = 285, - key_f5 = 286, - key_f6 = 287, - key_f7 = 288, - key_f8 = 289, - key_f9 = 290, - key_f10 = 291, - key_f11 = 292, - key_f12 = 293, - key_f13 = 294, - key_f14 = 295, - key_f15 = 296, - - // The possibility of using these keys is - // very restricted. Actually it's guaranteed - // only in win32_api and win32_sdl implementations - key_numlock = 300, - key_capslock = 301, - key_scrollock = 302, - - // Phew! - end_of_key_codes - }; - - - //------------------------------------------------------------------------ - // A predeclaration of the platform dependent class. Since we do not - // know anything here the only we can have is just a pointer to this - // class as a data member. It should be created and destroyed explicitly - // in the constructor/destructor of the platform_support class. - // Although the pointer to platform_specific is public the application - // cannot have access to its members or methods since it does not know - // anything about them and it's a perfect incapsulation :-) - class platform_specific; - - - //----------------------------------------------------------ctrl_container - // A helper class that contains pointers to a number of controls. - // This class is used to ease the event handling with controls. - // The implementation should simply call the appropriate methods - // of this class when appropriate events occur. - class ctrl_container - { - enum max_ctrl_e { max_ctrl = 64 }; - - public: - //-------------------------------------------------------------------- - ctrl_container() : m_num_ctrl(0), m_cur_ctrl(-1) {} - - //-------------------------------------------------------------------- - void add(ctrl& c) - { - if(m_num_ctrl < max_ctrl) - { - m_ctrl[m_num_ctrl++] = &c; - } - } - - //-------------------------------------------------------------------- - bool in_rect(double x, double y) - { - unsigned i; - for(i = 0; i < m_num_ctrl; i++) - { - if(m_ctrl[i]->in_rect(x, y)) return true; - } - return false; - } - - //-------------------------------------------------------------------- - bool on_mouse_button_down(double x, double y) - { - unsigned i; - for(i = 0; i < m_num_ctrl; i++) - { - if(m_ctrl[i]->on_mouse_button_down(x, y)) return true; - } - return false; - } - - //-------------------------------------------------------------------- - bool on_mouse_button_up(double x, double y) - { - unsigned i; - bool flag = false; - for(i = 0; i < m_num_ctrl; i++) - { - if(m_ctrl[i]->on_mouse_button_up(x, y)) flag = true; - } - return flag; - } - - //-------------------------------------------------------------------- - bool on_mouse_move(double x, double y, bool button_flag) - { - unsigned i; - for(i = 0; i < m_num_ctrl; i++) - { - if(m_ctrl[i]->on_mouse_move(x, y, button_flag)) return true; - } - return false; - } - - //-------------------------------------------------------------------- - bool on_arrow_keys(bool left, bool right, bool down, bool up) - { - if(m_cur_ctrl >= 0) - { - return m_ctrl[m_cur_ctrl]->on_arrow_keys(left, right, down, up); - } - return false; - } - - //-------------------------------------------------------------------- - bool set_cur(double x, double y) - { - unsigned i; - for(i = 0; i < m_num_ctrl; i++) - { - if(m_ctrl[i]->in_rect(x, y)) - { - if(m_cur_ctrl != int(i)) - { - m_cur_ctrl = i; - return true; - } - return false; - } - } - if(m_cur_ctrl != -1) - { - m_cur_ctrl = -1; - return true; - } - return false; - } - - private: - ctrl* m_ctrl[max_ctrl]; - unsigned m_num_ctrl; - int m_cur_ctrl; - }; - - - - //---------------------------------------------------------platform_support - // This class is a base one to the apllication classes. It can be used - // as follows: - // - // class the_application : public agg::platform_support - // { - // public: - // the_application(unsigned bpp, bool flip_y) : - // platform_support(bpp, flip_y) - // . . . - // - // //override stuff . . . - // virtual void on_init() - // { - // . . . - // } - // - // virtual void on_draw() - // { - // . . . - // } - // - // virtual void on_resize(int sx, int sy) - // { - // . . . - // } - // // . . . and so on, see virtual functions - // - // - // //any your own stuff . . . - // }; - // - // - // int agg_main(int argc, char* argv[]) - // { - // the_application app(pix_format_rgb24, true); - // app.caption("AGG Example. Lion"); - // - // if(app.init(500, 400, agg::window_resize)) - // { - // return app.run(); - // } - // return 1; - // } - // - // The reason to have agg_main() instead of just main() is that SDL - // for Windows requires including SDL.h if you define main(). Since - // the demo applications cannot rely on any platform/library specific - // stuff it's impossible to include SDL.h into the application files. - // The demo applications are simple and their use is restricted, so, - // this approach is quite reasonable. - // - class platform_support - { - public: - enum max_images_e { max_images = 16 }; - - // format - see enum pix_format_e {}; - // flip_y - true if you want to have the Y-axis flipped vertically. - platform_support(pix_format_e format, bool flip_y); - virtual ~platform_support(); - - // Setting the windows caption (title). Should be able - // to be called at least before calling init(). - // It's perfect if they can be called anytime. - void caption(const char* cap); - const char* caption() const { return m_caption; } - - //-------------------------------------------------------------------- - // These 3 methods handle working with images. The image - // formats are the simplest ones, such as .BMP in Windows or - // .ppm in Linux. In the applications the names of the files - // should not have any file extensions. Method load_img() can - // be called before init(), so, the application could be able - // to determine the initial size of the window depending on - // the size of the loaded image. - // The argument "idx" is the number of the image 0...max_images-1 - bool load_img(unsigned idx, const char* file); - bool save_img(unsigned idx, const char* file); - bool create_img(unsigned idx, unsigned width=0, unsigned height=0); - - //-------------------------------------------------------------------- - // init() and run(). See description before the class for details. - // The necessity of calling init() after creation is that it's - // impossible to call the overridden virtual function (on_init()) - // from the constructor. On the other hand it's very useful to have - // some on_init() event handler when the window is created but - // not yet displayed. The rbuf_window() method (see below) is - // accessible from on_init(). - bool init(unsigned width, unsigned height, unsigned flags); - int run(); - - //-------------------------------------------------------------------- - // The very same parameters that were used in the constructor - pix_format_e format() const { return m_format; } - bool flip_y() const { return m_flip_y; } - unsigned bpp() const { return m_bpp; } - - //-------------------------------------------------------------------- - // The following provides a very simple mechanism of doing someting - // in background. It's not multithreading. When wait_mode is true - // the class waits for the events and it does not ever call on_idle(). - // When it's false it calls on_idle() when the event queue is empty. - // The mode can be changed anytime. This mechanism is satisfactory - // to create very simple animations. - bool wait_mode() const { return m_wait_mode; } - void wait_mode(bool wait_mode) { m_wait_mode = wait_mode; } - - //-------------------------------------------------------------------- - // These two functions control updating of the window. - // force_redraw() is an analog of the Win32 InvalidateRect() function. - // Being called it sets a flag (or sends a message) which results - // in calling on_draw() and updating the content of the window - // when the next event cycle comes. - // update_window() results in just putting immediately the content - // of the currently rendered buffer to the window without calling - // on_draw(). - void force_redraw(); - void update_window(); - - //-------------------------------------------------------------------- - // So, finally, how to draw anythig with AGG? Very simple. - // rbuf_window() returns a reference to the main rendering - // buffer which can be attached to any rendering class. - // rbuf_img() returns a reference to the previously created - // or loaded image buffer (see load_img()). The image buffers - // are not displayed directly, they should be copied to or - // combined somehow with the rbuf_window(). rbuf_window() is - // the only buffer that can be actually displayed. - rendering_buffer& rbuf_window() { return m_rbuf_window; } - rendering_buffer& rbuf_img(unsigned idx) { return m_rbuf_img[idx]; } - - - //-------------------------------------------------------------------- - // Returns file extension used in the implementation for the particular - // system. - const char* img_ext() const; - - //-------------------------------------------------------------------- - void copy_img_to_window(unsigned idx) - { - if(idx < max_images && rbuf_img(idx).buf()) - { - rbuf_window().copy_from(rbuf_img(idx)); - } - } - - //-------------------------------------------------------------------- - void copy_window_to_img(unsigned idx) - { - if(idx < max_images) - { - create_img(idx, rbuf_window().width(), rbuf_window().height()); - rbuf_img(idx).copy_from(rbuf_window()); - } - } - - //-------------------------------------------------------------------- - void copy_img_to_img(unsigned idx_to, unsigned idx_from) - { - if(idx_from < max_images && - idx_to < max_images && - rbuf_img(idx_from).buf()) - { - create_img(idx_to, - rbuf_img(idx_from).width(), - rbuf_img(idx_from).height()); - rbuf_img(idx_to).copy_from(rbuf_img(idx_from)); - } - } - - //-------------------------------------------------------------------- - // Event handlers. They are not pure functions, so you don't have - // to override them all. - // In my demo applications these functions are defined inside - // the the_application class (implicit inlining) which is in general - // very bad practice, I mean vitual inline methods. At least it does - // not make sense. - // But in this case it's quite appropriate bacause we have the only - // instance of the the_application class and it is in the same file - // where this class is defined. - virtual void on_init(); - virtual void on_resize(int sx, int sy); - virtual void on_idle(); - virtual void on_mouse_move(int x, int y, unsigned flags); - virtual void on_mouse_button_down(int x, int y, unsigned flags); - virtual void on_mouse_button_up(int x, int y, unsigned flags); - virtual void on_key(int x, int y, unsigned key, unsigned flags); - virtual void on_ctrl_change(); - virtual void on_draw(); - virtual void on_post_draw(void* raw_handler); - - //-------------------------------------------------------------------- - // Adding control elements. A control element once added will be - // working and reacting to the mouse and keyboard events. Still, you - // will have to render them in the on_draw() using function - // render_ctrl() because platform_support doesn't know anything about - // renderers you use. The controls will be also scaled automatically - // if they provide a proper scaling mechanism (all the controls - // included into the basic AGG package do). - // If you don't need a particular control to be scaled automatically - // call ctrl::no_transform() after adding. - void add_ctrl(ctrl& c) { m_ctrls.add(c); c.transform(m_resize_mtx); } - - //-------------------------------------------------------------------- - // Auxiliary functions. trans_affine_resizing() modifier sets up the resizing - // matrix on the basis of the given width and height and the initial - // width and height of the window. The implementation should simply - // call this function every time when it catches the resizing event - // passing in the new values of width and height of the window. - // Nothing prevents you from "cheating" the scaling matrix if you - // call this function from somewhere with wrong arguments. - // trans_affine_resizing() accessor simply returns current resizing matrix - // which can be used to apply additional scaling of any of your - // stuff when the window is being resized. - // width(), height(), initial_width(), and initial_height() must be - // clear to understand with no comments :-) - void trans_affine_resizing(int width, int height) - { - if(m_window_flags & window_keep_aspect_ratio) - { - //double sx = double(width) / double(m_initial_width); - //double sy = double(height) / double(m_initial_height); - //if(sy < sx) sx = sy; - //m_resize_mtx = trans_affine_scaling(sx, sx); - trans_viewport vp; - vp.preserve_aspect_ratio(0.5, 0.5, aspect_ratio_meet); - vp.device_viewport(0, 0, width, height); - vp.world_viewport(0, 0, m_initial_width, m_initial_height); - m_resize_mtx = vp.to_affine(); - } - else - { - m_resize_mtx = trans_affine_scaling( - double(width) / double(m_initial_width), - double(height) / double(m_initial_height)); - } - } - const trans_affine& trans_affine_resizing() const { return m_resize_mtx; } - double width() const { return m_rbuf_window.width(); } - double height() const { return m_rbuf_window.height(); } - double initial_width() const { return m_initial_width; } - double initial_height() const { return m_initial_height; } - unsigned window_flags() const { return m_window_flags; } - - //-------------------------------------------------------------------- - // Get raw display handler depending on the system. - // For win32 its an HDC, for other systems it can be a pointer to some - // structure. See the implementation files for detals. - // It's provided "as is", so, first you should check if it's not null. - // If it's null the raw_display_handler is not supported. Also, there's - // no guarantee that this function is implemented, so, in some - // implementations you may have simply an unresolved symbol when linking. - void* raw_display_handler(); - - //-------------------------------------------------------------------- - // display message box or print the message to the console - // (depending on implementation) - void message(const char* msg); - - //-------------------------------------------------------------------- - // Stopwatch functions. Function elapsed_time() returns time elapsed - // since the latest start_timer() invocation in millisecods. - // The resolutoin depends on the implementation. - // In Win32 it uses QueryPerformanceFrequency() / QueryPerformanceCounter(). - void start_timer(); - double elapsed_time() const; - - //-------------------------------------------------------------------- - // Get the full file name. In most cases it simply returns - // file_name. As it's appropriate in many systems if you open - // a file by its name without specifying the path, it tries to - // open it in the current directory. The demos usually expect - // all the supplementary files to be placed in the current - // directory, that is usually coincides with the directory where - // the the executable is. However, in some systems (BeOS) it's not so. - // For those kinds of systems full_file_name() can help access files - // preserving commonly used policy. - // So, it's a good idea to use in the demos the following: - // FILE* fd = fopen(full_file_name("some.file"), "r"); - // instead of - // FILE* fd = fopen("some.file", "r"); - const char* full_file_name(const char* file_name); - - public: - platform_specific* m_specific; - ctrl_container m_ctrls; - - // Sorry, I'm too tired to describe the private - // data membders. See the implementations for different - // platforms for details. - private: - platform_support(const platform_support&); - const platform_support& operator = (const platform_support&); - - pix_format_e m_format; - unsigned m_bpp; - rendering_buffer m_rbuf_window; - rendering_buffer m_rbuf_img[max_images]; - unsigned m_window_flags; - bool m_wait_mode; - bool m_flip_y; - char m_caption[256]; - int m_initial_width; - int m_initial_height; - trans_affine m_resize_mtx; - }; - - -} - - - -#endif - diff --git a/desmume/src/windows/agg/include/platform/mac/agg_mac_pmap.h b/desmume/src/windows/agg/include/platform/mac/agg_mac_pmap.h deleted file mode 100644 index e7633b800..000000000 --- a/desmume/src/windows/agg/include/platform/mac/agg_mac_pmap.h +++ /dev/null @@ -1,92 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Copyright (C) 2002 Hansruedi Baer (MacOS support) -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_MAC_PMAP_INCLUDED -#define AGG_MAC_PMAP_INCLUDED - - -#include -#include - - -namespace agg -{ - enum org_e - { - org_mono8 = 8, - org_color16 = 16, - org_color24 = 24, - org_color32 = 32 - }; - - class pixel_map - { - public: - ~pixel_map(); - pixel_map(); - - public: - void destroy(); - void create(unsigned width, - unsigned height, - org_e org, - unsigned clear_val=255); - - void clear(unsigned clear_val=255); - bool load_from_qt(const char* filename); - bool save_as_qt(const char* filename) const; - - void draw(WindowRef window, - const Rect* device_rect=0, - const Rect* bmp_rect=0) const; - void draw(WindowRef window, int x, int y, double scale=1.0) const; - void blend(WindowRef window, - const Rect* device_rect=0, - const Rect* bmp_rect=0) const; - void blend(WindowRef window, int x, int y, double scale=1.0) const; - - unsigned char* buf(); - unsigned width() const; - unsigned height() const; - int row_bytes() const; - unsigned bpp() const { return m_bpp; } - - //Auxiliary static functions - static unsigned calc_row_len(unsigned width, unsigned bits_per_pixel); - private: - pixel_map(const pixel_map&); - const pixel_map& operator = (const pixel_map&); - - private: - GWorldPtr m_pmap; - unsigned char* m_buf; - unsigned m_bpp; - unsigned m_img_size; - }; - -} - - -#endif diff --git a/desmume/src/windows/agg/include/platform/win32/agg_win32_bmp.h b/desmume/src/windows/agg/include/platform/win32/agg_win32_bmp.h deleted file mode 100644 index e8b3dad1e..000000000 --- a/desmume/src/windows/agg/include/platform/win32/agg_win32_bmp.h +++ /dev/null @@ -1,123 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_WIN32_BMP_INCLUDED -#define AGG_WIN32_BMP_INCLUDED - - -#include -#include - - -namespace agg -{ - enum org_e - { - org_mono8 = 8, - org_color16 = 16, - org_color24 = 24, - org_color32 = 32, - org_color48 = 48, - org_color64 = 64 - }; - - class pixel_map - { - public: - ~pixel_map(); - pixel_map(); - - public: - void destroy(); - void create(unsigned width, - unsigned height, - org_e org, - unsigned clear_val=256); - HBITMAP create_dib_section(HDC h_dc, - unsigned width, - unsigned height, - org_e org, - unsigned clear_val=256); - - void clear(unsigned clear_val=256); - void attach_to_bmp(BITMAPINFO* bmp); - BITMAPINFO* bitmap_info() { return m_bmp; } - bool load_from_bmp(FILE* fd); - bool save_as_bmp(FILE* fd) const; - bool load_from_bmp(const char* filename); - bool save_as_bmp(const char* filename) const; - - void draw(HDC h_dc, - const RECT* device_rect=0, - const RECT* bmp_rect=0) const; - void draw(HDC h_dc, int x, int y, double scale=1.0) const; - - void blend(HDC h_dc, - const RECT* device_rect=0, - const RECT* bmp_rect=0) const; - void blend(HDC h_dc, int x, int y, double scale=1.0) const; - - - unsigned char* buf(); - unsigned width() const; - unsigned height() const; - int stride() const; - unsigned bpp() const { return m_bpp; } - - //Auxiliary static functions - static unsigned calc_full_size(BITMAPINFO *bmp); - static unsigned calc_header_size(BITMAPINFO *bmp); - static unsigned calc_palette_size(unsigned clr_used, - unsigned bits_per_pixel); - static unsigned calc_palette_size(BITMAPINFO *bmp); - static unsigned char* calc_img_ptr(BITMAPINFO *bmp); - static BITMAPINFO* create_bitmap_info(unsigned width, - unsigned height, - unsigned bits_per_pixel); - static void create_gray_scale_palette(BITMAPINFO *bmp); - static unsigned calc_row_len(unsigned width, unsigned bits_per_pixel); - - private: - pixel_map(const pixel_map&); - const pixel_map& operator = (const pixel_map&); - void create_from_bmp(BITMAPINFO *bmp); - - HBITMAP create_dib_section_from_args(HDC h_dc, - unsigned width, - unsigned height, - unsigned bits_per_pixel); - - private: - BITMAPINFO* m_bmp; - unsigned char* m_buf; - unsigned m_bpp; - bool m_is_internal; - unsigned m_img_size; - unsigned m_full_size; - }; - -} - - -#endif diff --git a/desmume/src/windows/agg/include/util/agg_color_conv.h b/desmume/src/windows/agg/include/util/agg_color_conv.h deleted file mode 100644 index 940d7d155..000000000 --- a/desmume/src/windows/agg/include/util/agg_color_conv.h +++ /dev/null @@ -1,89 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#ifndef AGG_COLOR_CONV_INCLUDED -#define AGG_COLOR_CONV_INCLUDED - -#include -#include "agg_basics.h" -#include "agg_rendering_buffer.h" - - - - -namespace agg -{ - - //--------------------------------------------------------------color_conv - template - void color_conv(RenBuf* dst, const RenBuf* src, CopyRow copy_row_functor) - { - unsigned width = src->width(); - unsigned height = src->height(); - - if(dst->width() < width) width = dst->width(); - if(dst->height() < height) height = dst->height(); - - if(width) - { - unsigned y; - for(y = 0; y < height; y++) - { - copy_row_functor(dst->row_ptr(0, y, width), - src->row_ptr(y), - width); - } - } - } - - - //---------------------------------------------------------color_conv_row - template - void color_conv_row(int8u* dst, - const int8u* src, - unsigned width, - CopyRow copy_row_functor) - { - copy_row_functor(dst, src, width); - } - - - //---------------------------------------------------------color_conv_same - template class color_conv_same - { - public: - void operator () (int8u* dst, - const int8u* src, - unsigned width) const - { - memmove(dst, src, width*BPP); - } - }; - - -} - - - -#endif diff --git a/desmume/src/windows/agg/include/util/agg_color_conv_rgb16.h b/desmume/src/windows/agg/include/util/agg_color_conv_rgb16.h deleted file mode 100644 index 4b780a382..000000000 --- a/desmume/src/windows/agg/include/util/agg_color_conv_rgb16.h +++ /dev/null @@ -1,294 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- -// -// This part of the library has been sponsored by -// Liberty Technology Systems, Inc., visit http://lib-sys.com -// -// Liberty Technology Systems, Inc. is the provider of -// PostScript and PDF technology for software developers. -// -//---------------------------------------------------------------------------- -// -// A set of functors used with color_conv(). See file agg_color_conv.h -// These functors can convert images with up to 8 bits per component. -// Use convertors in the following way: -// -// agg::color_conv(dst, src, agg::color_conv_XXXX_to_YYYY()); -//---------------------------------------------------------------------------- - -#ifndef AGG_COLOR_CONV_RGB16_INCLUDED -#define AGG_COLOR_CONV_RGB16_INCLUDED - -#include "agg_basics.h" -#include "agg_color_conv.h" - -namespace agg -{ - - //-------------------------------------------------color_conv_gray16_to_gray8 - class color_conv_gray16_to_gray8 - { - public: - void operator () (int8u* dst, - const int8u* src, - unsigned width) const - { - int16u* s = (int16u*)src; - do - { - *dst++ = *s++ >> 8; - } - while(--width); - } - }; - - - //-----------------------------------------------------color_conv_rgb24_rgb48 - template class color_conv_rgb24_rgb48 - { - public: - void operator () (int8u* dst, - const int8u* src, - unsigned width) const - { - int16u* d = (int16u*)dst; - do - { - *d++ = (src[I1] << 8) | src[I1]; - *d++ = (src[1] << 8) | src[1] ; - *d++ = (src[I3] << 8) | src[I3]; - src += 3; - } - while(--width); - } - }; - - typedef color_conv_rgb24_rgb48<0,2> color_conv_rgb24_to_rgb48; - typedef color_conv_rgb24_rgb48<0,2> color_conv_bgr24_to_bgr48; - typedef color_conv_rgb24_rgb48<2,0> color_conv_rgb24_to_bgr48; - typedef color_conv_rgb24_rgb48<2,0> color_conv_bgr24_to_rgb48; - - - //-----------------------------------------------------color_conv_rgb24_rgb48 - template class color_conv_rgb48_rgb24 - { - public: - void operator () (int8u* dst, - const int8u* src, - unsigned width) const - { - const int16u* s = (const int16u*)src; - do - { - *dst++ = s[I1] >> 8; - *dst++ = s[1] >> 8; - *dst++ = s[I3] >> 8; - s += 3; - } - while(--width); - } - }; - - typedef color_conv_rgb48_rgb24<0,2> color_conv_rgb48_to_rgb24; - typedef color_conv_rgb48_rgb24<0,2> color_conv_bgr48_to_bgr24; - typedef color_conv_rgb48_rgb24<2,0> color_conv_rgb48_to_bgr24; - typedef color_conv_rgb48_rgb24<2,0> color_conv_bgr48_to_rgb24; - - - //----------------------------------------------color_conv_rgbAAA_rgb24 - template class color_conv_rgbAAA_rgb24 - { - public: - void operator () (int8u* dst, - const int8u* src, - unsigned width) const - { - do - { - int32u rgb = *(int32u*)src; - dst[R] = int8u(rgb >> 22); - dst[1] = int8u(rgb >> 12); - dst[B] = int8u(rgb >> 2); - src += 4; - dst += 3; - } - while(--width); - } - }; - - typedef color_conv_rgbAAA_rgb24<0,2> color_conv_rgbAAA_to_rgb24; - typedef color_conv_rgbAAA_rgb24<2,0> color_conv_rgbAAA_to_bgr24; - typedef color_conv_rgbAAA_rgb24<2,0> color_conv_bgrAAA_to_rgb24; - typedef color_conv_rgbAAA_rgb24<0,2> color_conv_bgrAAA_to_bgr24; - - - //----------------------------------------------color_conv_rgbBBA_rgb24 - template class color_conv_rgbBBA_rgb24 - { - public: - void operator () (int8u* dst, - const int8u* src, - unsigned width) const - { - do - { - int32u rgb = *(int32u*)src; - dst[R] = int8u(rgb >> 24); - dst[1] = int8u(rgb >> 13); - dst[B] = int8u(rgb >> 2); - src += 4; - dst += 3; - } - while(--width); - } - }; - - typedef color_conv_rgbBBA_rgb24<0,2> color_conv_rgbBBA_to_rgb24; - typedef color_conv_rgbBBA_rgb24<2,0> color_conv_rgbBBA_to_bgr24; - - - //----------------------------------------------color_conv_bgrABB_rgb24 - template class color_conv_bgrABB_rgb24 - { - public: - void operator () (int8u* dst, - const int8u* src, - unsigned width) const - { - do - { - int32u bgr = *(int32u*)src; - dst[R] = int8u(bgr >> 3); - dst[1] = int8u(bgr >> 14); - dst[B] = int8u(bgr >> 24); - src += 4; - dst += 3; - } - while(--width); - } - }; - - typedef color_conv_bgrABB_rgb24<2,0> color_conv_bgrABB_to_rgb24; - typedef color_conv_bgrABB_rgb24<0,2> color_conv_bgrABB_to_bgr24; - - - //-------------------------------------------------color_conv_rgba64_rgba32 - template class color_conv_rgba64_rgba32 - { - public: - void operator () (int8u* dst, - const int8u* src, - unsigned width) const - { - do - { - *dst++ = int8u(((int16u*)src)[I1] >> 8); - *dst++ = int8u(((int16u*)src)[I2] >> 8); - *dst++ = int8u(((int16u*)src)[I3] >> 8); - *dst++ = int8u(((int16u*)src)[I4] >> 8); - src += 8; - } - while(--width); - } - }; - - //------------------------------------------------------------------------ - typedef color_conv_rgba64_rgba32<0,1,2,3> color_conv_rgba64_to_rgba32; //----color_conv_rgba64_to_rgba32 - typedef color_conv_rgba64_rgba32<0,1,2,3> color_conv_argb64_to_argb32; //----color_conv_argb64_to_argb32 - typedef color_conv_rgba64_rgba32<0,1,2,3> color_conv_bgra64_to_bgra32; //----color_conv_bgra64_to_bgra32 - typedef color_conv_rgba64_rgba32<0,1,2,3> color_conv_abgr64_to_abgr32; //----color_conv_abgr64_to_abgr32 - typedef color_conv_rgba64_rgba32<0,3,2,1> color_conv_argb64_to_abgr32; //----color_conv_argb64_to_abgr32 - typedef color_conv_rgba64_rgba32<3,2,1,0> color_conv_argb64_to_bgra32; //----color_conv_argb64_to_bgra32 - typedef color_conv_rgba64_rgba32<1,2,3,0> color_conv_argb64_to_rgba32; //----color_conv_argb64_to_rgba32 - typedef color_conv_rgba64_rgba32<3,0,1,2> color_conv_bgra64_to_abgr32; //----color_conv_bgra64_to_abgr32 - typedef color_conv_rgba64_rgba32<3,2,1,0> color_conv_bgra64_to_argb32; //----color_conv_bgra64_to_argb32 - typedef color_conv_rgba64_rgba32<2,1,0,3> color_conv_bgra64_to_rgba32; //----color_conv_bgra64_to_rgba32 - typedef color_conv_rgba64_rgba32<3,2,1,0> color_conv_rgba64_to_abgr32; //----color_conv_rgba64_to_abgr32 - typedef color_conv_rgba64_rgba32<3,0,1,2> color_conv_rgba64_to_argb32; //----color_conv_rgba64_to_argb32 - typedef color_conv_rgba64_rgba32<2,1,0,3> color_conv_rgba64_to_bgra32; //----color_conv_rgba64_to_bgra32 - typedef color_conv_rgba64_rgba32<0,3,2,1> color_conv_abgr64_to_argb32; //----color_conv_abgr64_to_argb32 - typedef color_conv_rgba64_rgba32<1,2,3,0> color_conv_abgr64_to_bgra32; //----color_conv_abgr64_to_bgra32 - typedef color_conv_rgba64_rgba32<3,2,1,0> color_conv_abgr64_to_rgba32; //----color_conv_abgr64_to_rgba32 - - - - //--------------------------------------------color_conv_rgb24_rgba64 - template class color_conv_rgb24_rgba64 - { - public: - void operator () (int8u* dst, - const int8u* src, - unsigned width) const - { - int16u* d = (int16u*)dst; - do - { - d[I1] = (src[0] << 8) | src[0]; - d[I2] = (src[1] << 8) | src[1]; - d[I3] = (src[2] << 8) | src[2]; - d[A] = 65535; - d += 4; - src += 3; - } - while(--width); - } - }; - - - //------------------------------------------------------------------------ - typedef color_conv_rgb24_rgba64<1,2,3,0> color_conv_rgb24_to_argb64; //----color_conv_rgb24_to_argb64 - typedef color_conv_rgb24_rgba64<3,2,1,0> color_conv_rgb24_to_abgr64; //----color_conv_rgb24_to_abgr64 - typedef color_conv_rgb24_rgba64<2,1,0,3> color_conv_rgb24_to_bgra64; //----color_conv_rgb24_to_bgra64 - typedef color_conv_rgb24_rgba64<0,1,2,3> color_conv_rgb24_to_rgba64; //----color_conv_rgb24_to_rgba64 - typedef color_conv_rgb24_rgba64<3,2,1,0> color_conv_bgr24_to_argb64; //----color_conv_bgr24_to_argb64 - typedef color_conv_rgb24_rgba64<1,2,3,0> color_conv_bgr24_to_abgr64; //----color_conv_bgr24_to_abgr64 - typedef color_conv_rgb24_rgba64<0,1,2,3> color_conv_bgr24_to_bgra64; //----color_conv_bgr24_to_bgra64 - typedef color_conv_rgb24_rgba64<2,1,0,3> color_conv_bgr24_to_rgba64; //----color_conv_bgr24_to_rgba64 - - - template class color_conv_rgb24_gray16 - { - public: - void operator () (int8u* dst, - const int8u* src, - unsigned width) const - { - int16u* d = (int16u*)dst; - do - { - *d++ = src[R]*77 + src[1]*150 + src[B]*29; - src += 3; - } - while(--width); - } - }; - - typedef color_conv_rgb24_gray16<0,2> color_conv_rgb24_to_gray16; - typedef color_conv_rgb24_gray16<2,0> color_conv_bgr24_to_gray16; - - -} - - -#endif diff --git a/desmume/src/windows/agg/include/util/agg_color_conv_rgb8.h b/desmume/src/windows/agg/include/util/agg_color_conv_rgb8.h deleted file mode 100644 index 6a7525cf5..000000000 --- a/desmume/src/windows/agg/include/util/agg_color_conv_rgb8.h +++ /dev/null @@ -1,478 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- -// -// A set of functors used with color_conv(). See file agg_color_conv.h -// These functors can convert images with up to 8 bits per component. -// Use convertors in the following way: -// -// agg::color_conv(dst, src, agg::color_conv_XXXX_to_YYYY()); -// whare XXXX and YYYY can be any of: -// rgb24 -// bgr24 -// rgba32 -// abgr32 -// argb32 -// bgra32 -// rgb555 -// rgb565 -//---------------------------------------------------------------------------- - -#ifndef AGG_COLOR_CONV_RGB8_INCLUDED -#define AGG_COLOR_CONV_RGB8_INCLUDED - -#include "agg_basics.h" -#include "agg_color_conv.h" - -namespace agg -{ - - //-----------------------------------------------------color_conv_rgb24 - class color_conv_rgb24 - { - public: - void operator () (int8u* dst, - const int8u* src, - unsigned width) const - { - do - { - *dst++ = src[2]; - *dst++ = src[1]; - *dst++ = src[0]; - src += 3; - } - while(--width); - } - }; - - typedef color_conv_rgb24 color_conv_rgb24_to_bgr24; - typedef color_conv_rgb24 color_conv_bgr24_to_rgb24; - - typedef color_conv_same<3> color_conv_bgr24_to_bgr24; - typedef color_conv_same<3> color_conv_rgb24_to_rgb24; - - - - //------------------------------------------------------color_conv_rgba32 - template class color_conv_rgba32 - { - public: - void operator () (int8u* dst, - const int8u* src, - unsigned width) const - { - do - { - *dst++ = src[I1]; - *dst++ = src[I2]; - *dst++ = src[I3]; - *dst++ = src[I4]; - src += 4; - } - while(--width); - } - }; - - - //------------------------------------------------------------------------ - typedef color_conv_rgba32<0,3,2,1> color_conv_argb32_to_abgr32; //----color_conv_argb32_to_abgr32 - typedef color_conv_rgba32<3,2,1,0> color_conv_argb32_to_bgra32; //----color_conv_argb32_to_bgra32 - typedef color_conv_rgba32<1,2,3,0> color_conv_argb32_to_rgba32; //----color_conv_argb32_to_rgba32 - typedef color_conv_rgba32<3,0,1,2> color_conv_bgra32_to_abgr32; //----color_conv_bgra32_to_abgr32 - typedef color_conv_rgba32<3,2,1,0> color_conv_bgra32_to_argb32; //----color_conv_bgra32_to_argb32 - typedef color_conv_rgba32<2,1,0,3> color_conv_bgra32_to_rgba32; //----color_conv_bgra32_to_rgba32 - typedef color_conv_rgba32<3,2,1,0> color_conv_rgba32_to_abgr32; //----color_conv_rgba32_to_abgr32 - typedef color_conv_rgba32<3,0,1,2> color_conv_rgba32_to_argb32; //----color_conv_rgba32_to_argb32 - typedef color_conv_rgba32<2,1,0,3> color_conv_rgba32_to_bgra32; //----color_conv_rgba32_to_bgra32 - typedef color_conv_rgba32<0,3,2,1> color_conv_abgr32_to_argb32; //----color_conv_abgr32_to_argb32 - typedef color_conv_rgba32<1,2,3,0> color_conv_abgr32_to_bgra32; //----color_conv_abgr32_to_bgra32 - typedef color_conv_rgba32<3,2,1,0> color_conv_abgr32_to_rgba32; //----color_conv_abgr32_to_rgba32 - - //------------------------------------------------------------------------ - typedef color_conv_same<4> color_conv_rgba32_to_rgba32; //----color_conv_rgba32_to_rgba32 - typedef color_conv_same<4> color_conv_argb32_to_argb32; //----color_conv_argb32_to_argb32 - typedef color_conv_same<4> color_conv_bgra32_to_bgra32; //----color_conv_bgra32_to_bgra32 - typedef color_conv_same<4> color_conv_abgr32_to_abgr32; //----color_conv_abgr32_to_abgr32 - - - //--------------------------------------------color_conv_rgb24_rgba32 - template class color_conv_rgb24_rgba32 - { - public: - void operator () (int8u* dst, - const int8u* src, - unsigned width) const - { - do - { - dst[I1] = *src++; - dst[I2] = *src++; - dst[I3] = *src++; - dst[A] = 255; - dst += 4; - } - while(--width); - } - }; - - - //------------------------------------------------------------------------ - typedef color_conv_rgb24_rgba32<1,2,3,0> color_conv_rgb24_to_argb32; //----color_conv_rgb24_to_argb32 - typedef color_conv_rgb24_rgba32<3,2,1,0> color_conv_rgb24_to_abgr32; //----color_conv_rgb24_to_abgr32 - typedef color_conv_rgb24_rgba32<2,1,0,3> color_conv_rgb24_to_bgra32; //----color_conv_rgb24_to_bgra32 - typedef color_conv_rgb24_rgba32<0,1,2,3> color_conv_rgb24_to_rgba32; //----color_conv_rgb24_to_rgba32 - typedef color_conv_rgb24_rgba32<3,2,1,0> color_conv_bgr24_to_argb32; //----color_conv_bgr24_to_argb32 - typedef color_conv_rgb24_rgba32<1,2,3,0> color_conv_bgr24_to_abgr32; //----color_conv_bgr24_to_abgr32 - typedef color_conv_rgb24_rgba32<0,1,2,3> color_conv_bgr24_to_bgra32; //----color_conv_bgr24_to_bgra32 - typedef color_conv_rgb24_rgba32<2,1,0,3> color_conv_bgr24_to_rgba32; //----color_conv_bgr24_to_rgba32 - - - - //-------------------------------------------------color_conv_rgba32_rgb24 - template class color_conv_rgba32_rgb24 - { - public: - void operator () (int8u* dst, - const int8u* src, - unsigned width) const - { - do - { - *dst++ = src[I1]; - *dst++ = src[I2]; - *dst++ = src[I3]; - src += 4; - } - while(--width); - } - }; - - - - //------------------------------------------------------------------------ - typedef color_conv_rgba32_rgb24<1,2,3> color_conv_argb32_to_rgb24; //----color_conv_argb32_to_rgb24 - typedef color_conv_rgba32_rgb24<3,2,1> color_conv_abgr32_to_rgb24; //----color_conv_abgr32_to_rgb24 - typedef color_conv_rgba32_rgb24<2,1,0> color_conv_bgra32_to_rgb24; //----color_conv_bgra32_to_rgb24 - typedef color_conv_rgba32_rgb24<0,1,2> color_conv_rgba32_to_rgb24; //----color_conv_rgba32_to_rgb24 - typedef color_conv_rgba32_rgb24<3,2,1> color_conv_argb32_to_bgr24; //----color_conv_argb32_to_bgr24 - typedef color_conv_rgba32_rgb24<1,2,3> color_conv_abgr32_to_bgr24; //----color_conv_abgr32_to_bgr24 - typedef color_conv_rgba32_rgb24<0,1,2> color_conv_bgra32_to_bgr24; //----color_conv_bgra32_to_bgr24 - typedef color_conv_rgba32_rgb24<2,1,0> color_conv_rgba32_to_bgr24; //----color_conv_rgba32_to_bgr24 - - - //------------------------------------------------color_conv_rgb555_rgb24 - template class color_conv_rgb555_rgb24 - { - public: - void operator () (int8u* dst, - const int8u* src, - unsigned width) const - { - do - { - unsigned rgb = *(int16u*)src; - dst[R] = (int8u)((rgb >> 7) & 0xF8); - dst[1] = (int8u)((rgb >> 2) & 0xF8); - dst[B] = (int8u)((rgb << 3) & 0xF8); - src += 2; - dst += 3; - } - while(--width); - } - }; - - - //------------------------------------------------------------------------ - typedef color_conv_rgb555_rgb24<2,0> color_conv_rgb555_to_bgr24; //----color_conv_rgb555_to_bgr24 - typedef color_conv_rgb555_rgb24<0,2> color_conv_rgb555_to_rgb24; //----color_conv_rgb555_to_rgb24 - - - //-------------------------------------------------color_conv_rgb24_rgb555 - template class color_conv_rgb24_rgb555 - { - public: - void operator () (int8u* dst, - const int8u* src, - unsigned width) const - { - do - { - *(int16u*)dst = (int16u)(((unsigned(src[R]) << 7) & 0x7C00) | - ((unsigned(src[1]) << 2) & 0x3E0) | - ((unsigned(src[B]) >> 3))); - src += 3; - dst += 2; - } - while(--width); - } - }; - - - //------------------------------------------------------------------------ - typedef color_conv_rgb24_rgb555<2,0> color_conv_bgr24_to_rgb555; //----color_conv_bgr24_to_rgb555 - typedef color_conv_rgb24_rgb555<0,2> color_conv_rgb24_to_rgb555; //----color_conv_rgb24_to_rgb555 - - - //-------------------------------------------------color_conv_rgb565_rgb24 - template class color_conv_rgb565_rgb24 - { - public: - void operator () (int8u* dst, - const int8u* src, - unsigned width) const - { - do - { - unsigned rgb = *(int16u*)src; - dst[R] = (rgb >> 8) & 0xF8; - dst[1] = (rgb >> 3) & 0xFC; - dst[B] = (rgb << 3) & 0xF8; - src += 2; - dst += 3; - } - while(--width); - } - }; - - - //------------------------------------------------------------------------ - typedef color_conv_rgb565_rgb24<2,0> color_conv_rgb565_to_bgr24; //----color_conv_rgb565_to_bgr24 - typedef color_conv_rgb565_rgb24<0,2> color_conv_rgb565_to_rgb24; //----color_conv_rgb565_to_rgb24 - - - //-------------------------------------------------color_conv_rgb24_rgb565 - template class color_conv_rgb24_rgb565 - { - public: - void operator () (int8u* dst, - const int8u* src, - unsigned width) const - { - do - { - *(int16u*)dst = (int16u)(((unsigned(src[R]) << 8) & 0xF800) | - ((unsigned(src[1]) << 3) & 0x7E0) | - ((unsigned(src[B]) >> 3))); - src += 3; - dst += 2; - } - while(--width); - } - }; - - - //------------------------------------------------------------------------ - typedef color_conv_rgb24_rgb565<2,0> color_conv_bgr24_to_rgb565; //----color_conv_bgr24_to_rgb565 - typedef color_conv_rgb24_rgb565<0,2> color_conv_rgb24_to_rgb565; //----color_conv_rgb24_to_rgb565 - - - - //-------------------------------------------------color_conv_rgb555_rgba32 - template class color_conv_rgb555_rgba32 - { - public: - void operator () (int8u* dst, - const int8u* src, - unsigned width) const - { - do - { - int rgb = *(int16*)src; - dst[R] = (int8u)((rgb >> 7) & 0xF8); - dst[G] = (int8u)((rgb >> 2) & 0xF8); - dst[B] = (int8u)((rgb << 3) & 0xF8); - dst[A] = (int8u)(rgb >> 15); - src += 2; - dst += 4; - } - while(--width); - } - }; - - - //------------------------------------------------------------------------ - typedef color_conv_rgb555_rgba32<1,2,3,0> color_conv_rgb555_to_argb32; //----color_conv_rgb555_to_argb32 - typedef color_conv_rgb555_rgba32<3,2,1,0> color_conv_rgb555_to_abgr32; //----color_conv_rgb555_to_abgr32 - typedef color_conv_rgb555_rgba32<2,1,0,3> color_conv_rgb555_to_bgra32; //----color_conv_rgb555_to_bgra32 - typedef color_conv_rgb555_rgba32<0,1,2,3> color_conv_rgb555_to_rgba32; //----color_conv_rgb555_to_rgba32 - - - //------------------------------------------------color_conv_rgba32_rgb555 - template class color_conv_rgba32_rgb555 - { - public: - void operator () (int8u* dst, - const int8u* src, - unsigned width) const - { - do - { - *(int16u*)dst = (int16u)(((unsigned(src[R]) << 7) & 0x7C00) | - ((unsigned(src[G]) << 2) & 0x3E0) | - ((unsigned(src[B]) >> 3)) | - ((unsigned(src[A]) << 8) & 0x8000)); - src += 4; - dst += 2; - } - while(--width); - } - }; - - - //------------------------------------------------------------------------ - typedef color_conv_rgba32_rgb555<1,2,3,0> color_conv_argb32_to_rgb555; //----color_conv_argb32_to_rgb555 - typedef color_conv_rgba32_rgb555<3,2,1,0> color_conv_abgr32_to_rgb555; //----color_conv_abgr32_to_rgb555 - typedef color_conv_rgba32_rgb555<2,1,0,3> color_conv_bgra32_to_rgb555; //----color_conv_bgra32_to_rgb555 - typedef color_conv_rgba32_rgb555<0,1,2,3> color_conv_rgba32_to_rgb555; //----color_conv_rgba32_to_rgb555 - - - - //------------------------------------------------color_conv_rgb565_rgba32 - template class color_conv_rgb565_rgba32 - { - public: - void operator () (int8u* dst, - const int8u* src, - unsigned width) const - { - do - { - int rgb = *(int16*)src; - dst[R] = (rgb >> 8) & 0xF8; - dst[G] = (rgb >> 3) & 0xFC; - dst[B] = (rgb << 3) & 0xF8; - dst[A] = 255; - src += 2; - dst += 4; - } - while(--width); - } - }; - - - //------------------------------------------------------------------------ - typedef color_conv_rgb565_rgba32<1,2,3,0> color_conv_rgb565_to_argb32; //----color_conv_rgb565_to_argb32 - typedef color_conv_rgb565_rgba32<3,2,1,0> color_conv_rgb565_to_abgr32; //----color_conv_rgb565_to_abgr32 - typedef color_conv_rgb565_rgba32<2,1,0,3> color_conv_rgb565_to_bgra32; //----color_conv_rgb565_to_bgra32 - typedef color_conv_rgb565_rgba32<0,1,2,3> color_conv_rgb565_to_rgba32; //----color_conv_rgb565_to_rgba32 - - - //------------------------------------------------color_conv_rgba32_rgb565 - template class color_conv_rgba32_rgb565 - { - public: - void operator () (int8u* dst, - const int8u* src, - unsigned width) const - { - do - { - *(int16u*)dst = (int16u)(((unsigned(src[R]) << 8) & 0xF800) | - ((unsigned(src[G]) << 3) & 0x7E0) | - ((unsigned(src[B]) >> 3))); - src += 4; - dst += 2; - } - while(--width); - } - }; - - - //------------------------------------------------------------------------ - typedef color_conv_rgba32_rgb565<1,2,3> color_conv_argb32_to_rgb565; //----color_conv_argb32_to_rgb565 - typedef color_conv_rgba32_rgb565<3,2,1> color_conv_abgr32_to_rgb565; //----color_conv_abgr32_to_rgb565 - typedef color_conv_rgba32_rgb565<2,1,0> color_conv_bgra32_to_rgb565; //----color_conv_bgra32_to_rgb565 - typedef color_conv_rgba32_rgb565<0,1,2> color_conv_rgba32_to_rgb565; //----color_conv_rgba32_to_rgb565 - - - //---------------------------------------------color_conv_rgb555_to_rgb565 - class color_conv_rgb555_to_rgb565 - { - public: - void operator () (int8u* dst, - const int8u* src, - unsigned width) const - { - do - { - unsigned rgb = *(int16u*)src; - *(int16u*)dst = (int16u)(((rgb << 1) & 0xFFC0) | (rgb & 0x1F)); - src += 2; - dst += 2; - } - while(--width); - } - }; - - - //----------------------------------------------color_conv_rgb565_to_rgb555 - class color_conv_rgb565_to_rgb555 - { - public: - void operator () (int8u* dst, - const int8u* src, - unsigned width) const - { - do - { - unsigned rgb = *(int16u*)src; - *(int16u*)dst = (int16u)(((rgb >> 1) & 0x7FE0) | (rgb & 0x1F)); - src += 2; - dst += 2; - } - while(--width); - } - }; - - - //------------------------------------------------------------------------ - typedef color_conv_same<2> color_conv_rgb555_to_rgb555; //----color_conv_rgb555_to_rgb555 - typedef color_conv_same<2> color_conv_rgb565_to_rgb565; //----color_conv_rgb565_to_rgb565 - - - template class color_conv_rgb24_gray8 - { - public: - void operator () (int8u* dst, - const int8u* src, - unsigned width) const - { - do - { - *dst++ = (src[R]*77 + src[1]*150 + src[B]*29) >> 8; - src += 3; - } - while(--width); - } - }; - - typedef color_conv_rgb24_gray8<0,2> color_conv_rgb24_to_gray8; //----color_conv_rgb24_to_gray8 - typedef color_conv_rgb24_gray8<2,0> color_conv_bgr24_to_gray8; //----color_conv_bgr24_to_gray8 - - -} - - - -#endif diff --git a/desmume/src/windows/agg/src/ChangeLog b/desmume/src/windows/agg/src/ChangeLog deleted file mode 100644 index e69de29bb..000000000 diff --git a/desmume/src/windows/agg/src/Makefile b/desmume/src/windows/agg/src/Makefile deleted file mode 100644 index 429f66ab8..000000000 --- a/desmume/src/windows/agg/src/Makefile +++ /dev/null @@ -1,59 +0,0 @@ -include ../Makefile.in.$(shell uname) - -CXXFLAGS= $(AGGCXXFLAGS) -I../include -L./ - -SRC_CXX=\ -agg_arc.cpp \ -agg_arrowhead.cpp \ -agg_bezier_arc.cpp \ -agg_bspline.cpp \ -agg_curves.cpp \ -agg_vcgen_contour.cpp \ -agg_vcgen_dash.cpp \ -agg_vcgen_markers_term.cpp \ -agg_vcgen_smooth_poly1.cpp \ -agg_vcgen_stroke.cpp \ -agg_vcgen_bspline.cpp \ -agg_gsv_text.cpp \ -agg_image_filters.cpp \ -agg_line_aa_basics.cpp \ -agg_line_profile_aa.cpp \ -agg_rounded_rect.cpp \ -agg_sqrt_tables.cpp \ -agg_embedded_raster_fonts.cpp \ -agg_trans_affine.cpp \ -agg_trans_warp_magnifier.cpp \ -agg_trans_single_path.cpp \ -agg_trans_double_path.cpp \ -agg_vpgen_clip_polygon.cpp \ -agg_vpgen_clip_polyline.cpp \ -agg_vpgen_segmentator.cpp \ -ctrl/agg_cbox_ctrl.cpp \ -ctrl/agg_gamma_ctrl.cpp \ -ctrl/agg_gamma_spline.cpp \ -ctrl/agg_rbox_ctrl.cpp \ -ctrl/agg_slider_ctrl.cpp \ -ctrl/agg_spline_ctrl.cpp \ -ctrl/agg_scale_ctrl.cpp \ -ctrl/agg_polygon_ctrl.cpp \ -ctrl/agg_bezier_ctrl.cpp - -SRC_C=\ -../gpc/gpc.c - - -OBJ=$(SRC_CXX:.cpp=.o) $(SRC_C:.c=.o) - -all: $(OBJ) - $(LIB) libagg.a $(OBJ) - -clean: - rm -f *.o *.a ctrl/*.o ../gpc/*.o - rm -rf SunWS_cache - rm -rf ctrl/SunWS_cache - -%.o: %.cpp - $(CXX) -c $(CXXFLAGS) $*.cpp -o $@ - -%.o: %.c - $(C) -c $(CXXFLAGS) $*.c -o $@ diff --git a/desmume/src/windows/agg/src/agg_arc.cpp b/desmume/src/windows/agg/src/agg_arc.cpp deleted file mode 100644 index f97717f58..000000000 --- a/desmume/src/windows/agg/src/agg_arc.cpp +++ /dev/null @@ -1,111 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#include -#include "agg_arc.h" - - -namespace agg -{ - //------------------------------------------------------------------------ - arc::arc(double x, double y, - double rx, double ry, - double a1, double a2, - bool ccw) : - m_x(x), m_y(y), m_rx(rx), m_ry(ry), m_scale(1.0) - { - normalize(a1, a2, ccw); - } - - //------------------------------------------------------------------------ - void arc::init(double x, double y, - double rx, double ry, - double a1, double a2, - bool ccw) - { - m_x = x; m_y = y; - m_rx = rx; m_ry = ry; - normalize(a1, a2, ccw); - } - - //------------------------------------------------------------------------ - void arc::approximation_scale(double s) - { - m_scale = s; - if(m_initialized) - { - normalize(m_start, m_end, m_ccw); - } - } - - //------------------------------------------------------------------------ - void arc::rewind(unsigned) - { - m_path_cmd = path_cmd_move_to; - m_angle = m_start; - } - - //------------------------------------------------------------------------ - unsigned arc::vertex(double* x, double* y) - { - if(is_stop(m_path_cmd)) return path_cmd_stop; - if((m_angle < m_end - m_da/4) != m_ccw) - { - *x = m_x + cos(m_end) * m_rx; - *y = m_y + sin(m_end) * m_ry; - m_path_cmd = path_cmd_stop; - return path_cmd_line_to; - } - - *x = m_x + cos(m_angle) * m_rx; - *y = m_y + sin(m_angle) * m_ry; - - m_angle += m_da; - - unsigned pf = m_path_cmd; - m_path_cmd = path_cmd_line_to; - return pf; - } - - //------------------------------------------------------------------------ - void arc::normalize(double a1, double a2, bool ccw) - { - double ra = (fabs(m_rx) + fabs(m_ry)) / 2; - m_da = acos(ra / (ra + 0.125 / m_scale)) * 2; - if(ccw) - { - while(a2 < a1) a2 += pi * 2.0; - } - else - { - while(a1 < a2) a1 += pi * 2.0; - m_da = -m_da; - } - m_ccw = ccw; - m_start = a1; - m_end = a2; - m_initialized = true; - } - -} diff --git a/desmume/src/windows/agg/src/agg_arrowhead.cpp b/desmume/src/windows/agg/src/agg_arrowhead.cpp deleted file mode 100644 index 47a6572a8..000000000 --- a/desmume/src/windows/agg/src/agg_arrowhead.cpp +++ /dev/null @@ -1,115 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#include "agg_arrowhead.h" - -namespace agg -{ - - //------------------------------------------------------------------------ - arrowhead::arrowhead() : - m_head_d1(1.0), - m_head_d2(1.0), - m_head_d3(1.0), - m_head_d4(0.0), - m_tail_d1(1.0), - m_tail_d2(1.0), - m_tail_d3(1.0), - m_tail_d4(0.0), - m_head_flag(false), - m_tail_flag(false), - m_curr_id(0), - m_curr_coord(0) - { - } - - - - //------------------------------------------------------------------------ - void arrowhead::rewind(unsigned path_id) - { - m_curr_id = path_id; - m_curr_coord = 0; - if(path_id == 0) - { - if(!m_tail_flag) - { - m_cmd[0] = path_cmd_stop; - return; - } - m_coord[0] = m_tail_d1; m_coord[1] = 0.0; - m_coord[2] = m_tail_d1 - m_tail_d4; m_coord[3] = m_tail_d3; - m_coord[4] = -m_tail_d2 - m_tail_d4; m_coord[5] = m_tail_d3; - m_coord[6] = -m_tail_d2; m_coord[7] = 0.0; - m_coord[8] = -m_tail_d2 - m_tail_d4; m_coord[9] = -m_tail_d3; - m_coord[10] = m_tail_d1 - m_tail_d4; m_coord[11] = -m_tail_d3; - - m_cmd[0] = path_cmd_move_to; - m_cmd[1] = path_cmd_line_to; - m_cmd[2] = path_cmd_line_to; - m_cmd[3] = path_cmd_line_to; - m_cmd[4] = path_cmd_line_to; - m_cmd[5] = path_cmd_line_to; - m_cmd[7] = path_cmd_end_poly | path_flags_close | path_flags_ccw; - m_cmd[6] = path_cmd_stop; - return; - } - - if(path_id == 1) - { - if(!m_head_flag) - { - m_cmd[0] = path_cmd_stop; - return; - } - m_coord[0] = -m_head_d1; m_coord[1] = 0.0; - m_coord[2] = m_head_d2 + m_head_d4; m_coord[3] = -m_head_d3; - m_coord[4] = m_head_d2; m_coord[5] = 0.0; - m_coord[6] = m_head_d2 + m_head_d4; m_coord[7] = m_head_d3; - - m_cmd[0] = path_cmd_move_to; - m_cmd[1] = path_cmd_line_to; - m_cmd[2] = path_cmd_line_to; - m_cmd[3] = path_cmd_line_to; - m_cmd[4] = path_cmd_end_poly | path_flags_close | path_flags_ccw; - m_cmd[5] = path_cmd_stop; - return; - } - } - - - //------------------------------------------------------------------------ - unsigned arrowhead::vertex(double* x, double* y) - { - if(m_curr_id < 2) - { - unsigned curr_idx = m_curr_coord * 2; - *x = m_coord[curr_idx]; - *y = m_coord[curr_idx + 1]; - return m_cmd[m_curr_coord++]; - } - return path_cmd_stop; - } - -} diff --git a/desmume/src/windows/agg/src/agg_bezier_arc.cpp b/desmume/src/windows/agg/src/agg_bezier_arc.cpp deleted file mode 100644 index 2140783ac..000000000 --- a/desmume/src/windows/agg/src/agg_bezier_arc.cpp +++ /dev/null @@ -1,261 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#include -#include "agg_bezier_arc.h" - - -namespace agg -{ - - // This epsilon is used to prevent us from adding degenerate curves - // (converging to a single point). - // The value isn't very critical. Function arc_to_bezier() has a limit - // of the sweep_angle. If fabs(sweep_angle) exceeds pi/2 the curve - // becomes inaccurate. But slight exceeding is quite appropriate. - //-------------------------------------------------bezier_arc_angle_epsilon - const double bezier_arc_angle_epsilon = 0.01; - - //------------------------------------------------------------arc_to_bezier - void arc_to_bezier(double cx, double cy, double rx, double ry, - double start_angle, double sweep_angle, - double* curve) - { - double x0 = cos(sweep_angle / 2.0); - double y0 = sin(sweep_angle / 2.0); - double tx = (1.0 - x0) * 4.0 / 3.0; - double ty = y0 - tx * x0 / y0; - double px[4]; - double py[4]; - px[0] = x0; - py[0] = -y0; - px[1] = x0 + tx; - py[1] = -ty; - px[2] = x0 + tx; - py[2] = ty; - px[3] = x0; - py[3] = y0; - - double sn = sin(start_angle + sweep_angle / 2.0); - double cs = cos(start_angle + sweep_angle / 2.0); - - unsigned i; - for(i = 0; i < 4; i++) - { - curve[i * 2] = cx + rx * (px[i] * cs - py[i] * sn); - curve[i * 2 + 1] = cy + ry * (px[i] * sn + py[i] * cs); - } - } - - - - //------------------------------------------------------------------------ - void bezier_arc::init(double x, double y, - double rx, double ry, - double start_angle, - double sweep_angle) - { - start_angle = fmod(start_angle, 2.0 * pi); - if(sweep_angle >= 2.0 * pi) sweep_angle = 2.0 * pi; - if(sweep_angle <= -2.0 * pi) sweep_angle = -2.0 * pi; - - if(fabs(sweep_angle) < 1e-10) - { - m_num_vertices = 4; - m_cmd = path_cmd_line_to; - m_vertices[0] = x + rx * cos(start_angle); - m_vertices[1] = y + ry * sin(start_angle); - m_vertices[2] = x + rx * cos(start_angle + sweep_angle); - m_vertices[3] = y + ry * sin(start_angle + sweep_angle); - return; - } - - double total_sweep = 0.0; - double local_sweep = 0.0; - double prev_sweep; - m_num_vertices = 2; - m_cmd = path_cmd_curve4; - bool done = false; - do - { - if(sweep_angle < 0.0) - { - prev_sweep = total_sweep; - local_sweep = -pi * 0.5; - total_sweep -= pi * 0.5; - if(total_sweep <= sweep_angle + bezier_arc_angle_epsilon) - { - local_sweep = sweep_angle - prev_sweep; - done = true; - } - } - else - { - prev_sweep = total_sweep; - local_sweep = pi * 0.5; - total_sweep += pi * 0.5; - if(total_sweep >= sweep_angle - bezier_arc_angle_epsilon) - { - local_sweep = sweep_angle - prev_sweep; - done = true; - } - } - - arc_to_bezier(x, y, rx, ry, - start_angle, - local_sweep, - m_vertices + m_num_vertices - 2); - - m_num_vertices += 6; - start_angle += local_sweep; - } - while(!done && m_num_vertices < 26); - } - - - - - //-------------------------------------------------------------------- - void bezier_arc_svg::init(double x0, double y0, - double rx, double ry, - double angle, - bool large_arc_flag, - bool sweep_flag, - double x2, double y2) - { - m_radii_ok = true; - - if(rx < 0.0) rx = -rx; - if(ry < 0.0) ry = -rx; - - // Calculate the middle point between - // the current and the final points - //------------------------ - double dx2 = (x0 - x2) / 2.0; - double dy2 = (y0 - y2) / 2.0; - - double cos_a = cos(angle); - double sin_a = sin(angle); - - // Calculate (x1, y1) - //------------------------ - double x1 = cos_a * dx2 + sin_a * dy2; - double y1 = -sin_a * dx2 + cos_a * dy2; - - // Ensure radii are large enough - //------------------------ - double prx = rx * rx; - double pry = ry * ry; - double px1 = x1 * x1; - double py1 = y1 * y1; - - // Check that radii are large enough - //------------------------ - double radii_check = px1/prx + py1/pry; - if(radii_check > 1.0) - { - rx = sqrt(radii_check) * rx; - ry = sqrt(radii_check) * ry; - prx = rx * rx; - pry = ry * ry; - if(radii_check > 10.0) m_radii_ok = false; - } - - // Calculate (cx1, cy1) - //------------------------ - double sign = (large_arc_flag == sweep_flag) ? -1.0 : 1.0; - double sq = (prx*pry - prx*py1 - pry*px1) / (prx*py1 + pry*px1); - double coef = sign * sqrt((sq < 0) ? 0 : sq); - double cx1 = coef * ((rx * y1) / ry); - double cy1 = coef * -((ry * x1) / rx); - - // - // Calculate (cx, cy) from (cx1, cy1) - //------------------------ - double sx2 = (x0 + x2) / 2.0; - double sy2 = (y0 + y2) / 2.0; - double cx = sx2 + (cos_a * cx1 - sin_a * cy1); - double cy = sy2 + (sin_a * cx1 + cos_a * cy1); - - // Calculate the start_angle (angle1) and the sweep_angle (dangle) - //------------------------ - double ux = (x1 - cx1) / rx; - double uy = (y1 - cy1) / ry; - double vx = (-x1 - cx1) / rx; - double vy = (-y1 - cy1) / ry; - double p, n; - - // Calculate the angle start - //------------------------ - n = sqrt(ux*ux + uy*uy); - p = ux; // (1 * ux) + (0 * uy) - sign = (uy < 0) ? -1.0 : 1.0; - double v = p / n; - if(v < -1.0) v = -1.0; - if(v > 1.0) v = 1.0; - double start_angle = sign * acos(v); - - // Calculate the sweep angle - //------------------------ - n = sqrt((ux*ux + uy*uy) * (vx*vx + vy*vy)); - p = ux * vx + uy * vy; - sign = (ux * vy - uy * vx < 0) ? -1.0 : 1.0; - v = p / n; - if(v < -1.0) v = -1.0; - if(v > 1.0) v = 1.0; - double sweep_angle = sign * acos(v); - if(!sweep_flag && sweep_angle > 0) - { - sweep_angle -= pi * 2.0; - } - else - if (sweep_flag && sweep_angle < 0) - { - sweep_angle += pi * 2.0; - } - - // We can now build and transform the resulting arc - //------------------------ - m_arc.init(0.0, 0.0, rx, ry, start_angle, sweep_angle); - trans_affine mtx = trans_affine_rotation(angle); - mtx *= trans_affine_translation(cx, cy); - - for(unsigned i = 2; i < m_arc.num_vertices()-2; i += 2) - { - mtx.transform(m_arc.vertices() + i, m_arc.vertices() + i + 1); - } - - // We must make sure that the starting and ending points - // exactly coincide with the initial (x0,y0) and (x2,y2) - m_arc.vertices()[0] = x0; - m_arc.vertices()[1] = y0; - if(m_arc.num_vertices() > 2) - { - m_arc.vertices()[m_arc.num_vertices() - 2] = x2; - m_arc.vertices()[m_arc.num_vertices() - 1] = y2; - } - } - - -} diff --git a/desmume/src/windows/agg/src/agg_bspline.cpp b/desmume/src/windows/agg/src/agg_bspline.cpp deleted file mode 100644 index 85bdfa969..000000000 --- a/desmume/src/windows/agg/src/agg_bspline.cpp +++ /dev/null @@ -1,289 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#include "agg_bspline.h" - -namespace agg -{ - //------------------------------------------------------------------------ - bspline::bspline() : - m_max(0), - m_num(0), - m_x(0), - m_y(0), - m_last_idx(-1) - { - } - - //------------------------------------------------------------------------ - bspline::bspline(int num) : - m_max(0), - m_num(0), - m_x(0), - m_y(0), - m_last_idx(-1) - { - init(num); - } - - //------------------------------------------------------------------------ - bspline::bspline(int num, const double* x, const double* y) : - m_max(0), - m_num(0), - m_x(0), - m_y(0), - m_last_idx(-1) - { - init(num, x, y); - } - - - //------------------------------------------------------------------------ - void bspline::init(int max) - { - if(max > 2 && max > m_max) - { - m_am.resize(max * 3); - m_max = max; - m_x = &m_am[m_max]; - m_y = &m_am[m_max * 2]; - } - m_num = 0; - m_last_idx = -1; - } - - - //------------------------------------------------------------------------ - void bspline::add_point(double x, double y) - { - if(m_num < m_max) - { - m_x[m_num] = x; - m_y[m_num] = y; - ++m_num; - } - } - - - //------------------------------------------------------------------------ - void bspline::prepare() - { - if(m_num > 2) - { - int i, k, n1; - double* temp; - double* r; - double* s; - double h, p, d, f, e; - - for(k = 0; k < m_num; k++) - { - m_am[k] = 0.0; - } - - n1 = 3 * m_num; - - pod_array al(n1); - temp = &al[0]; - - for(k = 0; k < n1; k++) - { - temp[k] = 0.0; - } - - r = temp + m_num; - s = temp + m_num * 2; - - n1 = m_num - 1; - d = m_x[1] - m_x[0]; - e = (m_y[1] - m_y[0]) / d; - - for(k = 1; k < n1; k++) - { - h = d; - d = m_x[k + 1] - m_x[k]; - f = e; - e = (m_y[k + 1] - m_y[k]) / d; - al[k] = d / (d + h); - r[k] = 1.0 - al[k]; - s[k] = 6.0 * (e - f) / (h + d); - } - - for(k = 1; k < n1; k++) - { - p = 1.0 / (r[k] * al[k - 1] + 2.0); - al[k] *= -p; - s[k] = (s[k] - r[k] * s[k - 1]) * p; - } - - m_am[n1] = 0.0; - al[n1 - 1] = s[n1 - 1]; - m_am[n1 - 1] = al[n1 - 1]; - - for(k = n1 - 2, i = 0; i < m_num - 2; i++, k--) - { - al[k] = al[k] * al[k + 1] + s[k]; - m_am[k] = al[k]; - } - } - m_last_idx = -1; - } - - - - //------------------------------------------------------------------------ - void bspline::init(int num, const double* x, const double* y) - { - if(num > 2) - { - init(num); - int i; - for(i = 0; i < num; i++) - { - add_point(*x++, *y++); - } - prepare(); - } - m_last_idx = -1; - } - - - //------------------------------------------------------------------------ - void bspline::bsearch(int n, const double *x, double x0, int *i) - { - int j = n - 1; - int k; - - for(*i = 0; (j - *i) > 1; ) - { - if(x0 < x[k = (*i + j) >> 1]) j = k; - else *i = k; - } - } - - - - //------------------------------------------------------------------------ - double bspline::interpolation(double x, int i) const - { - int j = i + 1; - double d = m_x[i] - m_x[j]; - double h = x - m_x[j]; - double r = m_x[i] - x; - double p = d * d / 6.0; - return (m_am[j] * r * r * r + m_am[i] * h * h * h) / 6.0 / d + - ((m_y[j] - m_am[j] * p) * r + (m_y[i] - m_am[i] * p) * h) / d; - } - - - //------------------------------------------------------------------------ - double bspline::extrapolation_left(double x) const - { - double d = m_x[1] - m_x[0]; - return (-d * m_am[1] / 6 + (m_y[1] - m_y[0]) / d) * - (x - m_x[0]) + - m_y[0]; - } - - //------------------------------------------------------------------------ - double bspline::extrapolation_right(double x) const - { - double d = m_x[m_num - 1] - m_x[m_num - 2]; - return (d * m_am[m_num - 2] / 6 + (m_y[m_num - 1] - m_y[m_num - 2]) / d) * - (x - m_x[m_num - 1]) + - m_y[m_num - 1]; - } - - //------------------------------------------------------------------------ - double bspline::get(double x) const - { - if(m_num > 2) - { - int i; - - // Extrapolation on the left - if(x < m_x[0]) return extrapolation_left(x); - - // Extrapolation on the right - if(x >= m_x[m_num - 1]) return extrapolation_right(x); - - // Interpolation - bsearch(m_num, m_x, x, &i); - return interpolation(x, i); - } - return 0.0; - } - - - //------------------------------------------------------------------------ - double bspline::get_stateful(double x) const - { - if(m_num > 2) - { - // Extrapolation on the left - if(x < m_x[0]) return extrapolation_left(x); - - // Extrapolation on the right - if(x >= m_x[m_num - 1]) return extrapolation_right(x); - - if(m_last_idx >= 0) - { - // Check if x is not in current range - if(x < m_x[m_last_idx] || x > m_x[m_last_idx + 1]) - { - // Check if x between next points (most probably) - if(m_last_idx < m_num - 2 && - x >= m_x[m_last_idx + 1] && - x <= m_x[m_last_idx + 2]) - { - ++m_last_idx; - } - else - if(m_last_idx > 0 && - x >= m_x[m_last_idx - 1] && - x <= m_x[m_last_idx]) - { - // x is between pevious points - --m_last_idx; - } - else - { - // Else perform full search - bsearch(m_num, m_x, x, &m_last_idx); - } - } - return interpolation(x, m_last_idx); - } - else - { - // Interpolation - bsearch(m_num, m_x, x, &m_last_idx); - return interpolation(x, m_last_idx); - } - } - return 0.0; - } - -} - diff --git a/desmume/src/windows/agg/src/agg_curves.cpp b/desmume/src/windows/agg/src/agg_curves.cpp deleted file mode 100644 index eec67d21f..000000000 --- a/desmume/src/windows/agg/src/agg_curves.cpp +++ /dev/null @@ -1,620 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#include -#include "agg_curves.h" -#include "agg_math.h" - -namespace agg -{ - - //------------------------------------------------------------------------ - const double curve_distance_epsilon = 1e-30; - const double curve_collinearity_epsilon = 1e-30; - const double curve_angle_tolerance_epsilon = 0.01; - enum curve_recursion_limit_e { curve_recursion_limit = 32 }; - - - - //------------------------------------------------------------------------ - void curve3_inc::approximation_scale(double s) - { - m_scale = s; - } - - //------------------------------------------------------------------------ - double curve3_inc::approximation_scale() const - { - return m_scale; - } - - //------------------------------------------------------------------------ - void curve3_inc::init(double x1, double y1, - double x2, double y2, - double x3, double y3) - { - m_start_x = x1; - m_start_y = y1; - m_end_x = x3; - m_end_y = y3; - - double dx1 = x2 - x1; - double dy1 = y2 - y1; - double dx2 = x3 - x2; - double dy2 = y3 - y2; - - double len = sqrt(dx1 * dx1 + dy1 * dy1) + sqrt(dx2 * dx2 + dy2 * dy2); - - m_num_steps = uround(len * 0.25 * m_scale); - - if(m_num_steps < 4) - { - m_num_steps = 4; - } - - double subdivide_step = 1.0 / m_num_steps; - double subdivide_step2 = subdivide_step * subdivide_step; - - double tmpx = (x1 - x2 * 2.0 + x3) * subdivide_step2; - double tmpy = (y1 - y2 * 2.0 + y3) * subdivide_step2; - - m_saved_fx = m_fx = x1; - m_saved_fy = m_fy = y1; - - m_saved_dfx = m_dfx = tmpx + (x2 - x1) * (2.0 * subdivide_step); - m_saved_dfy = m_dfy = tmpy + (y2 - y1) * (2.0 * subdivide_step); - - m_ddfx = tmpx * 2.0; - m_ddfy = tmpy * 2.0; - - m_step = m_num_steps; - } - - //------------------------------------------------------------------------ - void curve3_inc::rewind(unsigned) - { - if(m_num_steps == 0) - { - m_step = -1; - return; - } - m_step = m_num_steps; - m_fx = m_saved_fx; - m_fy = m_saved_fy; - m_dfx = m_saved_dfx; - m_dfy = m_saved_dfy; - } - - //------------------------------------------------------------------------ - unsigned curve3_inc::vertex(double* x, double* y) - { - if(m_step < 0) return path_cmd_stop; - if(m_step == m_num_steps) - { - *x = m_start_x; - *y = m_start_y; - --m_step; - return path_cmd_move_to; - } - if(m_step == 0) - { - *x = m_end_x; - *y = m_end_y; - --m_step; - return path_cmd_line_to; - } - m_fx += m_dfx; - m_fy += m_dfy; - m_dfx += m_ddfx; - m_dfy += m_ddfy; - *x = m_fx; - *y = m_fy; - --m_step; - return path_cmd_line_to; - } - - //------------------------------------------------------------------------ - void curve3_div::init(double x1, double y1, - double x2, double y2, - double x3, double y3) - { - m_points.remove_all(); - m_distance_tolerance_square = 0.5 / m_approximation_scale; - m_distance_tolerance_square *= m_distance_tolerance_square; - bezier(x1, y1, x2, y2, x3, y3); - m_count = 0; - } - - //------------------------------------------------------------------------ - void curve3_div::recursive_bezier(double x1, double y1, - double x2, double y2, - double x3, double y3, - unsigned level) - { - if(level > curve_recursion_limit) - { - return; - } - - // Calculate all the mid-points of the line segments - //---------------------- - double x12 = (x1 + x2) / 2; - double y12 = (y1 + y2) / 2; - double x23 = (x2 + x3) / 2; - double y23 = (y2 + y3) / 2; - double x123 = (x12 + x23) / 2; - double y123 = (y12 + y23) / 2; - - double dx = x3-x1; - double dy = y3-y1; - double d = fabs(((x2 - x3) * dy - (y2 - y3) * dx)); - double da; - - if(d > curve_collinearity_epsilon) - { - // Regular case - //----------------- - if(d * d <= m_distance_tolerance_square * (dx*dx + dy*dy)) - { - // If the curvature doesn't exceed the distance_tolerance value - // we tend to finish subdivisions. - //---------------------- - if(m_angle_tolerance < curve_angle_tolerance_epsilon) - { - m_points.add(point_d(x123, y123)); - return; - } - - // Angle & Cusp Condition - //---------------------- - da = fabs(atan2(y3 - y2, x3 - x2) - atan2(y2 - y1, x2 - x1)); - if(da >= pi) da = 2*pi - da; - - if(da < m_angle_tolerance) - { - // Finally we can stop the recursion - //---------------------- - m_points.add(point_d(x123, y123)); - return; - } - } - } - else - { - // Collinear case - //------------------ - da = dx*dx + dy*dy; - if(da == 0) - { - d = calc_sq_distance(x1, y1, x2, y2); - } - else - { - d = ((x2 - x1)*dx + (y2 - y1)*dy) / da; - if(d > 0 && d < 1) - { - // Simple collinear case, 1---2---3 - // We can leave just two endpoints - return; - } - if(d <= 0) d = calc_sq_distance(x2, y2, x1, y1); - else if(d >= 1) d = calc_sq_distance(x2, y2, x3, y3); - else d = calc_sq_distance(x2, y2, x1 + d*dx, y1 + d*dy); - } - if(d < m_distance_tolerance_square) - { - m_points.add(point_d(x2, y2)); - return; - } - } - - // Continue subdivision - //---------------------- - recursive_bezier(x1, y1, x12, y12, x123, y123, level + 1); - recursive_bezier(x123, y123, x23, y23, x3, y3, level + 1); - } - - //------------------------------------------------------------------------ - void curve3_div::bezier(double x1, double y1, - double x2, double y2, - double x3, double y3) - { - m_points.add(point_d(x1, y1)); - recursive_bezier(x1, y1, x2, y2, x3, y3, 0); - m_points.add(point_d(x3, y3)); - } - - - - - - //------------------------------------------------------------------------ - void curve4_inc::approximation_scale(double s) - { - m_scale = s; - } - - //------------------------------------------------------------------------ - double curve4_inc::approximation_scale() const - { - return m_scale; - } - - //------------------------------------------------------------------------ - static double MSC60_fix_ICE(double v) { return v; } - - //------------------------------------------------------------------------ - void curve4_inc::init(double x1, double y1, - double x2, double y2, - double x3, double y3, - double x4, double y4) - { - m_start_x = x1; - m_start_y = y1; - m_end_x = x4; - m_end_y = y4; - - double dx1 = x2 - x1; - double dy1 = y2 - y1; - double dx2 = x3 - x2; - double dy2 = y3 - y2; - double dx3 = x4 - x3; - double dy3 = y4 - y3; - - double len = (sqrt(dx1 * dx1 + dy1 * dy1) + - sqrt(dx2 * dx2 + dy2 * dy2) + - sqrt(dx3 * dx3 + dy3 * dy3)) * 0.25 * m_scale; - -#if defined(_MSC_VER) && _MSC_VER <= 1200 - m_num_steps = uround(MSC60_fix_ICE(len)); -#else - m_num_steps = uround(len); -#endif - - if(m_num_steps < 4) - { - m_num_steps = 4; - } - - double subdivide_step = 1.0 / m_num_steps; - double subdivide_step2 = subdivide_step * subdivide_step; - double subdivide_step3 = subdivide_step * subdivide_step * subdivide_step; - - double pre1 = 3.0 * subdivide_step; - double pre2 = 3.0 * subdivide_step2; - double pre4 = 6.0 * subdivide_step2; - double pre5 = 6.0 * subdivide_step3; - - double tmp1x = x1 - x2 * 2.0 + x3; - double tmp1y = y1 - y2 * 2.0 + y3; - - double tmp2x = (x2 - x3) * 3.0 - x1 + x4; - double tmp2y = (y2 - y3) * 3.0 - y1 + y4; - - m_saved_fx = m_fx = x1; - m_saved_fy = m_fy = y1; - - m_saved_dfx = m_dfx = (x2 - x1) * pre1 + tmp1x * pre2 + tmp2x * subdivide_step3; - m_saved_dfy = m_dfy = (y2 - y1) * pre1 + tmp1y * pre2 + tmp2y * subdivide_step3; - - m_saved_ddfx = m_ddfx = tmp1x * pre4 + tmp2x * pre5; - m_saved_ddfy = m_ddfy = tmp1y * pre4 + tmp2y * pre5; - - m_dddfx = tmp2x * pre5; - m_dddfy = tmp2y * pre5; - - m_step = m_num_steps; - } - - //------------------------------------------------------------------------ - void curve4_inc::rewind(unsigned) - { - if(m_num_steps == 0) - { - m_step = -1; - return; - } - m_step = m_num_steps; - m_fx = m_saved_fx; - m_fy = m_saved_fy; - m_dfx = m_saved_dfx; - m_dfy = m_saved_dfy; - m_ddfx = m_saved_ddfx; - m_ddfy = m_saved_ddfy; - } - - //------------------------------------------------------------------------ - unsigned curve4_inc::vertex(double* x, double* y) - { - if(m_step < 0) return path_cmd_stop; - if(m_step == m_num_steps) - { - *x = m_start_x; - *y = m_start_y; - --m_step; - return path_cmd_move_to; - } - - if(m_step == 0) - { - *x = m_end_x; - *y = m_end_y; - --m_step; - return path_cmd_line_to; - } - - m_fx += m_dfx; - m_fy += m_dfy; - m_dfx += m_ddfx; - m_dfy += m_ddfy; - m_ddfx += m_dddfx; - m_ddfy += m_dddfy; - - *x = m_fx; - *y = m_fy; - --m_step; - return path_cmd_line_to; - } - - - - - //------------------------------------------------------------------------ - void curve4_div::init(double x1, double y1, - double x2, double y2, - double x3, double y3, - double x4, double y4) - { - m_points.remove_all(); - m_distance_tolerance_square = 0.5 / m_approximation_scale; - m_distance_tolerance_square *= m_distance_tolerance_square; - bezier(x1, y1, x2, y2, x3, y3, x4, y4); - m_count = 0; - } - - //------------------------------------------------------------------------ - void curve4_div::recursive_bezier(double x1, double y1, - double x2, double y2, - double x3, double y3, - double x4, double y4, - unsigned level) - { - if(level > curve_recursion_limit) - { - return; - } - - // Calculate all the mid-points of the line segments - //---------------------- - double x12 = (x1 + x2) / 2; - double y12 = (y1 + y2) / 2; - double x23 = (x2 + x3) / 2; - double y23 = (y2 + y3) / 2; - double x34 = (x3 + x4) / 2; - double y34 = (y3 + y4) / 2; - double x123 = (x12 + x23) / 2; - double y123 = (y12 + y23) / 2; - double x234 = (x23 + x34) / 2; - double y234 = (y23 + y34) / 2; - double x1234 = (x123 + x234) / 2; - double y1234 = (y123 + y234) / 2; - - - // Try to approximate the full cubic curve by a single straight line - //------------------ - double dx = x4-x1; - double dy = y4-y1; - - double d2 = fabs(((x2 - x4) * dy - (y2 - y4) * dx)); - double d3 = fabs(((x3 - x4) * dy - (y3 - y4) * dx)); - double da1, da2, k; - - switch((int(d2 > curve_collinearity_epsilon) << 1) + - int(d3 > curve_collinearity_epsilon)) - { - case 0: - // All collinear OR p1==p4 - //---------------------- - k = dx*dx + dy*dy; - if(k == 0) - { - d2 = calc_sq_distance(x1, y1, x2, y2); - d3 = calc_sq_distance(x4, y4, x3, y3); - } - else - { - k = 1 / k; - da1 = x2 - x1; - da2 = y2 - y1; - d2 = k * (da1*dx + da2*dy); - da1 = x3 - x1; - da2 = y3 - y1; - d3 = k * (da1*dx + da2*dy); - if(d2 > 0 && d2 < 1 && d3 > 0 && d3 < 1) - { - // Simple collinear case, 1---2---3---4 - // We can leave just two endpoints - return; - } - if(d2 <= 0) d2 = calc_sq_distance(x2, y2, x1, y1); - else if(d2 >= 1) d2 = calc_sq_distance(x2, y2, x4, y4); - else d2 = calc_sq_distance(x2, y2, x1 + d2*dx, y1 + d2*dy); - - if(d3 <= 0) d3 = calc_sq_distance(x3, y3, x1, y1); - else if(d3 >= 1) d3 = calc_sq_distance(x3, y3, x4, y4); - else d3 = calc_sq_distance(x3, y3, x1 + d3*dx, y1 + d3*dy); - } - if(d2 > d3) - { - if(d2 < m_distance_tolerance_square) - { - m_points.add(point_d(x2, y2)); - return; - } - } - else - { - if(d3 < m_distance_tolerance_square) - { - m_points.add(point_d(x3, y3)); - return; - } - } - break; - - case 1: - // p1,p2,p4 are collinear, p3 is significant - //---------------------- - if(d3 * d3 <= m_distance_tolerance_square * (dx*dx + dy*dy)) - { - if(m_angle_tolerance < curve_angle_tolerance_epsilon) - { - m_points.add(point_d(x23, y23)); - return; - } - - // Angle Condition - //---------------------- - da1 = fabs(atan2(y4 - y3, x4 - x3) - atan2(y3 - y2, x3 - x2)); - if(da1 >= pi) da1 = 2*pi - da1; - - if(da1 < m_angle_tolerance) - { - m_points.add(point_d(x2, y2)); - m_points.add(point_d(x3, y3)); - return; - } - - if(m_cusp_limit != 0.0) - { - if(da1 > m_cusp_limit) - { - m_points.add(point_d(x3, y3)); - return; - } - } - } - break; - - case 2: - // p1,p3,p4 are collinear, p2 is significant - //---------------------- - if(d2 * d2 <= m_distance_tolerance_square * (dx*dx + dy*dy)) - { - if(m_angle_tolerance < curve_angle_tolerance_epsilon) - { - m_points.add(point_d(x23, y23)); - return; - } - - // Angle Condition - //---------------------- - da1 = fabs(atan2(y3 - y2, x3 - x2) - atan2(y2 - y1, x2 - x1)); - if(da1 >= pi) da1 = 2*pi - da1; - - if(da1 < m_angle_tolerance) - { - m_points.add(point_d(x2, y2)); - m_points.add(point_d(x3, y3)); - return; - } - - if(m_cusp_limit != 0.0) - { - if(da1 > m_cusp_limit) - { - m_points.add(point_d(x2, y2)); - return; - } - } - } - break; - - case 3: - // Regular case - //----------------- - if((d2 + d3)*(d2 + d3) <= m_distance_tolerance_square * (dx*dx + dy*dy)) - { - // If the curvature doesn't exceed the distance_tolerance value - // we tend to finish subdivisions. - //---------------------- - if(m_angle_tolerance < curve_angle_tolerance_epsilon) - { - m_points.add(point_d(x23, y23)); - return; - } - - // Angle & Cusp Condition - //---------------------- - k = atan2(y3 - y2, x3 - x2); - da1 = fabs(k - atan2(y2 - y1, x2 - x1)); - da2 = fabs(atan2(y4 - y3, x4 - x3) - k); - if(da1 >= pi) da1 = 2*pi - da1; - if(da2 >= pi) da2 = 2*pi - da2; - - if(da1 + da2 < m_angle_tolerance) - { - // Finally we can stop the recursion - //---------------------- - m_points.add(point_d(x23, y23)); - return; - } - - if(m_cusp_limit != 0.0) - { - if(da1 > m_cusp_limit) - { - m_points.add(point_d(x2, y2)); - return; - } - - if(da2 > m_cusp_limit) - { - m_points.add(point_d(x3, y3)); - return; - } - } - } - break; - } - - // Continue subdivision - //---------------------- - recursive_bezier(x1, y1, x12, y12, x123, y123, x1234, y1234, level + 1); - recursive_bezier(x1234, y1234, x234, y234, x34, y34, x4, y4, level + 1); - } - - //------------------------------------------------------------------------ - void curve4_div::bezier(double x1, double y1, - double x2, double y2, - double x3, double y3, - double x4, double y4) - { - m_points.add(point_d(x1, y1)); - recursive_bezier(x1, y1, x2, y2, x3, y3, x4, y4, 0); - m_points.add(point_d(x4, y4)); - } - -} - diff --git a/desmume/src/windows/agg/src/agg_embedded_raster_fonts.cpp b/desmume/src/windows/agg/src/agg_embedded_raster_fonts.cpp deleted file mode 100644 index 9320fd86a..000000000 --- a/desmume/src/windows/agg/src/agg_embedded_raster_fonts.cpp +++ /dev/null @@ -1,10435 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#include "agg_embedded_raster_fonts.h" - -namespace agg -{ - - const int8u gse4x6[] = - { - 6, 0, 32, 128-32, - - 0x00,0x00,0x07,0x00,0x0e,0x00,0x15,0x00,0x1c,0x00,0x23,0x00,0x2a,0x00,0x31,0x00,0x38,0x00, - 0x3f,0x00,0x46,0x00,0x4d,0x00,0x54,0x00,0x5b,0x00,0x62,0x00,0x69,0x00,0x70,0x00,0x77,0x00, - 0x7e,0x00,0x85,0x00,0x8c,0x00,0x93,0x00,0x9a,0x00,0xa1,0x00,0xa8,0x00,0xaf,0x00,0xb6,0x00, - 0xbd,0x00,0xc4,0x00,0xcb,0x00,0xd2,0x00,0xd9,0x00,0xe0,0x00,0xe7,0x00,0xee,0x00,0xf5,0x00, - 0xfc,0x00,0x03,0x01,0x0a,0x01,0x11,0x01,0x18,0x01,0x1f,0x01,0x26,0x01,0x2d,0x01,0x34,0x01, - 0x3b,0x01,0x42,0x01,0x49,0x01,0x50,0x01,0x57,0x01,0x5e,0x01,0x65,0x01,0x6c,0x01,0x73,0x01, - 0x7a,0x01,0x81,0x01,0x88,0x01,0x8f,0x01,0x96,0x01,0x9d,0x01,0xa4,0x01,0xab,0x01,0xb2,0x01, - 0xb9,0x01,0xc0,0x01,0xc7,0x01,0xce,0x01,0xd5,0x01,0xdc,0x01,0xe3,0x01,0xea,0x01,0xf1,0x01, - 0xf8,0x01,0xff,0x01,0x06,0x02,0x0d,0x02,0x14,0x02,0x1b,0x02,0x22,0x02,0x29,0x02,0x30,0x02, - 0x37,0x02,0x3e,0x02,0x45,0x02,0x4c,0x02,0x53,0x02,0x5a,0x02,0x61,0x02,0x68,0x02,0x6f,0x02, - 0x76,0x02,0x7d,0x02,0x84,0x02,0x8b,0x02,0x92,0x02,0x99,0x02, - - 4, // 0x20 ' ' - 0x00,0x00,0x00,0x00,0x00,0x00, - - 4, // 0x21 '!' - 0x40,0x40,0x40,0x00,0x40,0x00, - - 4, // 0x22 '"' - 0xa0,0xa0,0x00,0x00,0x00,0x00, - - 4, // 0x23 '#' - 0x60,0xf0,0x60,0xf0,0x60,0x00, - - 4, // 0x24 '$' - 0x40,0x60,0xc0,0x60,0xc0,0x40, - - 4, // 0x25 '%' - 0xa0,0x20,0x40,0x80,0xa0,0x00, - - 4, // 0x26 '&' - 0xe0,0xa0,0x50,0xa0,0xd0,0x00, - - 4, // 0x27 ''' - 0x40,0x40,0x00,0x00,0x00,0x00, - - 4, // 0x28 '(' - 0x20,0x40,0x40,0x40,0x20,0x00, - - 4, // 0x29 ')' - 0x40,0x20,0x20,0x20,0x40,0x00, - - 4, // 0x2a '*' - 0xa0,0x40,0xe0,0x40,0xa0,0x00, - - 4, // 0x2b '+' - 0x40,0x40,0xe0,0x40,0x40,0x00, - - 4, // 0x2c ',' - 0x00,0x00,0x00,0x40,0x40,0x80, - - 4, // 0x2d '-' - 0x00,0x00,0xe0,0x00,0x00,0x00, - - 4, // 0x2e '.' - 0x00,0x00,0x00,0x00,0x40,0x00, - - 4, // 0x2f '/' - 0x10,0x20,0x20,0x40,0x40,0x80, - - 4, // 0x30 '0' - 0xe0,0xa0,0xa0,0xa0,0xe0,0x00, - - 4, // 0x31 '1' - 0x40,0xc0,0x40,0x40,0xe0,0x00, - - 4, // 0x32 '2' - 0xe0,0xa0,0x20,0x40,0xe0,0x00, - - 4, // 0x33 '3' - 0xe0,0x20,0x40,0x20,0xe0,0x00, - - 4, // 0x34 '4' - 0xa0,0xa0,0xe0,0x20,0x20,0x00, - - 4, // 0x35 '5' - 0xe0,0x80,0xc0,0x20,0xc0,0x00, - - 4, // 0x36 '6' - 0x40,0x80,0xe0,0xa0,0xe0,0x00, - - 4, // 0x37 '7' - 0xe0,0xa0,0x20,0x40,0x40,0x00, - - 4, // 0x38 '8' - 0xe0,0xa0,0x40,0xa0,0xe0,0x00, - - 4, // 0x39 '9' - 0xe0,0xa0,0xe0,0x20,0xc0,0x00, - - 4, // 0x3a ':' - 0x00,0x40,0x00,0x40,0x00,0x00, - - 4, // 0x3b ';' - 0x00,0x40,0x00,0x40,0x40,0x80, - - 4, // 0x3c '<' - 0x20,0x40,0x80,0x40,0x20,0x00, - - 4, // 0x3d '=' - 0x00,0xe0,0x00,0xe0,0x00,0x00, - - 4, // 0x3e '>' - 0x80,0x40,0x20,0x40,0x80,0x00, - - 4, // 0x3f '?' - 0xc0,0x20,0x40,0x00,0x40,0x00, - - 4, // 0x40 '@' - 0x40,0xa0,0xe0,0xe0,0x80,0x60, - - 4, // 0x41 'A' - 0x40,0xa0,0xe0,0xa0,0xa0,0x00, - - 4, // 0x42 'B' - 0xc0,0xa0,0xc0,0xa0,0xc0,0x00, - - 4, // 0x43 'C' - 0x60,0x80,0x80,0x80,0x60,0x00, - - 4, // 0x44 'D' - 0xc0,0xa0,0xa0,0xa0,0xc0,0x00, - - 4, // 0x45 'E' - 0xe0,0x80,0xc0,0x80,0xe0,0x00, - - 4, // 0x46 'F' - 0xe0,0x80,0xc0,0x80,0x80,0x00, - - 4, // 0x47 'G' - 0x60,0x80,0xa0,0xa0,0x40,0x00, - - 4, // 0x48 'H' - 0xa0,0xa0,0xe0,0xa0,0xa0,0x00, - - 4, // 0x49 'I' - 0xe0,0x40,0x40,0x40,0xe0,0x00, - - 4, // 0x4a 'J' - 0x20,0x20,0x20,0x20,0xa0,0x40, - - 4, // 0x4b 'K' - 0xa0,0xa0,0xc0,0xc0,0xa0,0x00, - - 4, // 0x4c 'L' - 0x80,0x80,0x80,0x80,0xe0,0x00, - - 4, // 0x4d 'M' - 0xa0,0xe0,0xa0,0xa0,0xa0,0x00, - - 4, // 0x4e 'N' - 0x90,0xd0,0xb0,0x90,0x90,0x00, - - 4, // 0x4f 'O' - 0x40,0xa0,0xa0,0xa0,0x40,0x00, - - 4, // 0x50 'P' - 0xc0,0xa0,0xa0,0xc0,0x80,0x00, - - 4, // 0x51 'Q' - 0x40,0xa0,0xa0,0xa0,0x60,0x00, - - 4, // 0x52 'R' - 0xc0,0xa0,0xa0,0xc0,0xa0,0x00, - - 4, // 0x53 'S' - 0x60,0x80,0x40,0x20,0xc0,0x00, - - 4, // 0x54 'T' - 0xe0,0x40,0x40,0x40,0x40,0x00, - - 4, // 0x55 'U' - 0xa0,0xa0,0xa0,0xa0,0xe0,0x00, - - 4, // 0x56 'V' - 0xa0,0xa0,0xa0,0xa0,0x40,0x00, - - 4, // 0x57 'W' - 0xa0,0xa0,0xa0,0xe0,0xa0,0x00, - - 4, // 0x58 'X' - 0xa0,0xa0,0x40,0xa0,0xa0,0x00, - - 4, // 0x59 'Y' - 0xa0,0xa0,0x40,0x40,0x40,0x00, - - 4, // 0x5a 'Z' - 0xe0,0x20,0x40,0x80,0xe0,0x00, - - 4, // 0x5b '[' - 0xc0,0x80,0x80,0x80,0xc0,0x00, - - 4, // 0x5c '\' - 0x80,0x40,0x40,0x20,0x20,0x10, - - 4, // 0x5d ']' - 0xc0,0x40,0x40,0x40,0xc0,0x00, - - 4, // 0x5e '^' - 0x40,0xa0,0x00,0x00,0x00,0x00, - - 4, // 0x5f '_' - 0x00,0x00,0x00,0x00,0x00,0xf0, - - 4, // 0x60 '`' - 0x40,0x20,0x00,0x00,0x00,0x00, - - 4, // 0x61 'a' - 0x00,0x60,0xa0,0xa0,0x70,0x00, - - 4, // 0x62 'b' - 0x80,0x80,0xc0,0xa0,0xc0,0x00, - - 4, // 0x63 'c' - 0x00,0x60,0x80,0x80,0x60,0x00, - - 4, // 0x64 'd' - 0x20,0x20,0x60,0xa0,0x60,0x00, - - 4, // 0x65 'e' - 0x00,0x40,0xe0,0x80,0x60,0x00, - - 4, // 0x66 'f' - 0x20,0x40,0xe0,0x40,0x40,0x00, - - 4, // 0x67 'g' - 0x00,0x60,0xa0,0x60,0x20,0xc0, - - 4, // 0x68 'h' - 0x80,0x80,0xc0,0xa0,0xa0,0x00, - - 4, // 0x69 'i' - 0x40,0x00,0xc0,0x40,0xe0,0x00, - - 4, // 0x6a 'j' - 0x40,0x00,0xc0,0x40,0x40,0x80, - - 4, // 0x6b 'k' - 0x80,0x80,0xa0,0xc0,0xa0,0x00, - - 4, // 0x6c 'l' - 0xc0,0x40,0x40,0x40,0xe0,0x00, - - 4, // 0x6d 'm' - 0x00,0xa0,0xf0,0xf0,0x90,0x00, - - 4, // 0x6e 'n' - 0x00,0xc0,0xa0,0xa0,0xa0,0x00, - - 4, // 0x6f 'o' - 0x00,0x40,0xa0,0xa0,0x40,0x00, - - 4, // 0x70 'p' - 0x00,0xc0,0xa0,0xc0,0x80,0x80, - - 4, // 0x71 'q' - 0x00,0x60,0xa0,0x60,0x20,0x20, - - 4, // 0x72 'r' - 0x00,0xa0,0x50,0x40,0x40,0x00, - - 4, // 0x73 's' - 0x00,0x60,0xc0,0x20,0xc0,0x00, - - 4, // 0x74 't' - 0x40,0x40,0xe0,0x40,0x60,0x00, - - 4, // 0x75 'u' - 0x00,0xa0,0xa0,0xa0,0x60,0x00, - - 4, // 0x76 'v' - 0x00,0xa0,0xa0,0xa0,0x40,0x00, - - 4, // 0x77 'w' - 0x00,0xa0,0xa0,0xe0,0xa0,0x00, - - 4, // 0x78 'x' - 0x00,0xa0,0x40,0xa0,0xa0,0x00, - - 4, // 0x79 'y' - 0x00,0xa0,0xa0,0x60,0x20,0xc0, - - 4, // 0x7a 'z' - 0x00,0xe0,0x40,0x80,0xe0,0x00, - - 4, // 0x7b '{' - 0x30,0x20,0xc0,0x20,0x30,0x00, - - 4, // 0x7c '|' - 0x40,0x40,0x00,0x40,0x40,0x40, - - 4, // 0x7d '}' - 0xc0,0x40,0x30,0x40,0xc0,0x00, - - 4, // 0x7e '~' - 0x50,0xa0,0x00,0x00,0x00,0x00, - - 4, // 0x7f '' - 0x00,0x60,0x90,0xf0,0x00,0x00, - 0 - }; - - const int8u gse4x8[] = - { - 8, 0, 32, 128-32, - - 0x00,0x00,0x09,0x00,0x12,0x00,0x1b,0x00,0x24,0x00,0x2d,0x00,0x36,0x00,0x3f,0x00,0x48,0x00, - 0x51,0x00,0x5a,0x00,0x63,0x00,0x6c,0x00,0x75,0x00,0x7e,0x00,0x87,0x00,0x90,0x00,0x99,0x00, - 0xa2,0x00,0xab,0x00,0xb4,0x00,0xbd,0x00,0xc6,0x00,0xcf,0x00,0xd8,0x00,0xe1,0x00,0xea,0x00, - 0xf3,0x00,0xfc,0x00,0x05,0x01,0x0e,0x01,0x17,0x01,0x20,0x01,0x29,0x01,0x32,0x01,0x3b,0x01, - 0x44,0x01,0x4d,0x01,0x56,0x01,0x5f,0x01,0x68,0x01,0x71,0x01,0x7a,0x01,0x83,0x01,0x8c,0x01, - 0x95,0x01,0x9e,0x01,0xa7,0x01,0xb0,0x01,0xb9,0x01,0xc2,0x01,0xcb,0x01,0xd4,0x01,0xdd,0x01, - 0xe6,0x01,0xef,0x01,0xf8,0x01,0x01,0x02,0x0a,0x02,0x13,0x02,0x1c,0x02,0x25,0x02,0x2e,0x02, - 0x37,0x02,0x40,0x02,0x49,0x02,0x52,0x02,0x5b,0x02,0x64,0x02,0x6d,0x02,0x76,0x02,0x7f,0x02, - 0x88,0x02,0x91,0x02,0x9a,0x02,0xa3,0x02,0xac,0x02,0xb5,0x02,0xbe,0x02,0xc7,0x02,0xd0,0x02, - 0xd9,0x02,0xe2,0x02,0xeb,0x02,0xf4,0x02,0xfd,0x02,0x06,0x03,0x0f,0x03,0x18,0x03,0x21,0x03, - 0x2a,0x03,0x33,0x03,0x3c,0x03,0x45,0x03,0x4e,0x03,0x57,0x03, - - 4, // 0x20 ' ' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 4, // 0x21 '!' - 0x00,0x40,0x40,0x40,0x40,0x00,0x40,0x00, - - 4, // 0x22 '"' - 0x00,0xa0,0xa0,0x00,0x00,0x00,0x00,0x00, - - 4, // 0x23 '#' - 0x60,0x60,0xf0,0x60,0x60,0xf0,0x60,0x60, - - 4, // 0x24 '$' - 0x40,0x60,0xc0,0xc0,0x60,0x60,0xc0,0x40, - - 4, // 0x25 '%' - 0x00,0xa0,0x20,0x40,0x40,0x80,0xa0,0x00, - - 4, // 0x26 '&' - 0x00,0x40,0xa0,0xa0,0x40,0xb0,0xa0,0x70, - - 4, // 0x27 ''' - 0x00,0x40,0x40,0x00,0x00,0x00,0x00,0x00, - - 4, // 0x28 '(' - 0x20,0x40,0x80,0x80,0x80,0x80,0x40,0x20, - - 4, // 0x29 ')' - 0x80,0x40,0x20,0x20,0x20,0x20,0x40,0x80, - - 4, // 0x2a '*' - 0x00,0xa0,0x40,0xe0,0x40,0xa0,0x00,0x00, - - 4, // 0x2b '+' - 0x00,0x40,0x40,0xe0,0x40,0x40,0x00,0x00, - - 4, // 0x2c ',' - 0x00,0x00,0x00,0x00,0x00,0x40,0x40,0x80, - - 4, // 0x2d '-' - 0x00,0x00,0x00,0xe0,0x00,0x00,0x00,0x00, - - 4, // 0x2e '.' - 0x00,0x00,0x00,0x00,0x00,0x00,0x40,0x00, - - 4, // 0x2f '/' - 0x10,0x10,0x20,0x20,0x40,0x40,0x80,0x80, - - 4, // 0x30 '0' - 0x00,0xe0,0xa0,0xa0,0xa0,0xa0,0xe0,0x00, - - 4, // 0x31 '1' - 0x00,0x40,0xc0,0x40,0x40,0x40,0xe0,0x00, - - 4, // 0x32 '2' - 0x00,0xe0,0xa0,0x20,0x40,0x80,0xe0,0x00, - - 4, // 0x33 '3' - 0x00,0xe0,0x20,0x40,0x20,0x20,0xe0,0x00, - - 4, // 0x34 '4' - 0x00,0x60,0xa0,0xa0,0xf0,0x20,0x20,0x00, - - 4, // 0x35 '5' - 0x00,0xe0,0x80,0xc0,0x20,0x20,0xc0,0x00, - - 4, // 0x36 '6' - 0x00,0x40,0x80,0xe0,0xa0,0xa0,0xe0,0x00, - - 4, // 0x37 '7' - 0x00,0xe0,0xa0,0x20,0x40,0x40,0x40,0x00, - - 4, // 0x38 '8' - 0x00,0xe0,0xa0,0x40,0xa0,0xa0,0xe0,0x00, - - 4, // 0x39 '9' - 0x00,0xe0,0xa0,0xe0,0x20,0x20,0x40,0x00, - - 4, // 0x3a ':' - 0x00,0x00,0x40,0x00,0x00,0x40,0x00,0x00, - - 4, // 0x3b ';' - 0x00,0x00,0x40,0x00,0x00,0x40,0x40,0x80, - - 4, // 0x3c '<' - 0x00,0x20,0x40,0x80,0x40,0x20,0x00,0x00, - - 4, // 0x3d '=' - 0x00,0x00,0xe0,0x00,0xe0,0x00,0x00,0x00, - - 4, // 0x3e '>' - 0x00,0x80,0x40,0x20,0x40,0x80,0x00,0x00, - - 4, // 0x3f '?' - 0x00,0x40,0xa0,0x20,0x40,0x00,0x40,0x00, - - 4, // 0x40 '@' - 0x00,0x40,0xa0,0xe0,0xe0,0x80,0x60,0x00, - - 4, // 0x41 'A' - 0x00,0x40,0xa0,0xa0,0xe0,0xa0,0xa0,0x00, - - 4, // 0x42 'B' - 0x00,0xc0,0xa0,0xc0,0xa0,0xa0,0xc0,0x00, - - 4, // 0x43 'C' - 0x00,0x40,0xa0,0x80,0x80,0xa0,0x40,0x00, - - 4, // 0x44 'D' - 0x00,0xc0,0xa0,0xa0,0xa0,0xa0,0xc0,0x00, - - 4, // 0x45 'E' - 0x00,0xe0,0x80,0xc0,0x80,0x80,0xe0,0x00, - - 4, // 0x46 'F' - 0x00,0xe0,0x80,0xc0,0x80,0x80,0x80,0x00, - - 4, // 0x47 'G' - 0x00,0x60,0x80,0xa0,0xa0,0xa0,0x40,0x00, - - 4, // 0x48 'H' - 0x00,0xa0,0xa0,0xe0,0xa0,0xa0,0xa0,0x00, - - 4, // 0x49 'I' - 0x00,0xe0,0x40,0x40,0x40,0x40,0xe0,0x00, - - 4, // 0x4a 'J' - 0x00,0x20,0x20,0x20,0x20,0xa0,0x40,0x00, - - 4, // 0x4b 'K' - 0x00,0xa0,0xa0,0xc0,0xc0,0xa0,0xa0,0x00, - - 4, // 0x4c 'L' - 0x00,0x80,0x80,0x80,0x80,0x80,0xe0,0x00, - - 4, // 0x4d 'M' - 0x00,0xa0,0xe0,0xa0,0xa0,0xa0,0xa0,0x00, - - 4, // 0x4e 'N' - 0x00,0x90,0x90,0xd0,0xb0,0x90,0x90,0x00, - - 4, // 0x4f 'O' - 0x00,0x40,0xa0,0xa0,0xa0,0xa0,0x40,0x00, - - 4, // 0x50 'P' - 0x00,0xc0,0xa0,0xa0,0xc0,0x80,0x80,0x00, - - 4, // 0x51 'Q' - 0x00,0x40,0xa0,0xa0,0xa0,0xa0,0x60,0x00, - - 4, // 0x52 'R' - 0x00,0xc0,0xa0,0xa0,0xc0,0xc0,0xa0,0x00, - - 4, // 0x53 'S' - 0x00,0x60,0x80,0x40,0x20,0x20,0xc0,0x00, - - 4, // 0x54 'T' - 0x00,0xe0,0x40,0x40,0x40,0x40,0x40,0x00, - - 4, // 0x55 'U' - 0x00,0xa0,0xa0,0xa0,0xa0,0xa0,0x40,0x00, - - 4, // 0x56 'V' - 0x00,0xa0,0xa0,0xa0,0xa0,0x40,0x40,0x00, - - 4, // 0x57 'W' - 0x00,0xa0,0xa0,0xa0,0xa0,0xe0,0xa0,0x00, - - 4, // 0x58 'X' - 0x00,0xa0,0xa0,0x40,0xa0,0xa0,0xa0,0x00, - - 4, // 0x59 'Y' - 0x00,0xa0,0xa0,0x40,0x40,0x40,0x40,0x00, - - 4, // 0x5a 'Z' - 0x00,0xe0,0x20,0x40,0x40,0x80,0xe0,0x00, - - 4, // 0x5b '[' - 0xc0,0x80,0x80,0x80,0x80,0x80,0x80,0xc0, - - 4, // 0x5c '\' - 0x80,0x80,0x40,0x40,0x20,0x20,0x10,0x10, - - 4, // 0x5d ']' - 0xc0,0x40,0x40,0x40,0x40,0x40,0x40,0xc0, - - 4, // 0x5e '^' - 0x00,0x40,0xa0,0x00,0x00,0x00,0x00,0x00, - - 4, // 0x5f '_' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0, - - 4, // 0x60 '`' - 0x00,0x40,0x20,0x00,0x00,0x00,0x00,0x00, - - 4, // 0x61 'a' - 0x00,0x00,0x60,0xa0,0xa0,0xa0,0x70,0x00, - - 4, // 0x62 'b' - 0x00,0x80,0x80,0xc0,0xa0,0xa0,0xc0,0x00, - - 4, // 0x63 'c' - 0x00,0x00,0x40,0xa0,0x80,0xa0,0x40,0x00, - - 4, // 0x64 'd' - 0x00,0x20,0x20,0x60,0xa0,0xa0,0x60,0x00, - - 4, // 0x65 'e' - 0x00,0x00,0x40,0xa0,0xe0,0x80,0x60,0x00, - - 4, // 0x66 'f' - 0x00,0x20,0x40,0x40,0xe0,0x40,0x40,0x00, - - 4, // 0x67 'g' - 0x00,0x00,0x60,0xa0,0xa0,0x60,0x20,0xc0, - - 4, // 0x68 'h' - 0x00,0x80,0x80,0xc0,0xa0,0xa0,0xa0,0x00, - - 4, // 0x69 'i' - 0x00,0x40,0x00,0xc0,0x40,0x40,0xe0,0x00, - - 4, // 0x6a 'j' - 0x00,0x40,0x00,0xc0,0x40,0x40,0x40,0x80, - - 4, // 0x6b 'k' - 0x00,0x80,0x80,0xa0,0xc0,0xc0,0xa0,0x00, - - 4, // 0x6c 'l' - 0x00,0xc0,0x40,0x40,0x40,0x40,0xe0,0x00, - - 4, // 0x6d 'm' - 0x00,0x00,0xa0,0xf0,0xf0,0xf0,0x90,0x00, - - 4, // 0x6e 'n' - 0x00,0x00,0xc0,0xa0,0xa0,0xa0,0xa0,0x00, - - 4, // 0x6f 'o' - 0x00,0x00,0x40,0xa0,0xa0,0xa0,0x40,0x00, - - 4, // 0x70 'p' - 0x00,0x00,0xc0,0xa0,0xa0,0xc0,0x80,0x80, - - 4, // 0x71 'q' - 0x00,0x00,0x60,0xa0,0xa0,0x60,0x20,0x20, - - 4, // 0x72 'r' - 0x00,0x00,0xa0,0x50,0x40,0x40,0x40,0x00, - - 4, // 0x73 's' - 0x00,0x00,0x60,0x80,0x40,0x20,0xc0,0x00, - - 4, // 0x74 't' - 0x00,0x40,0x40,0xe0,0x40,0x40,0x20,0x00, - - 4, // 0x75 'u' - 0x00,0x00,0xa0,0xa0,0xa0,0xa0,0x60,0x00, - - 4, // 0x76 'v' - 0x00,0x00,0xa0,0xa0,0xa0,0x40,0x40,0x00, - - 4, // 0x77 'w' - 0x00,0x00,0xa0,0xa0,0xa0,0xe0,0xa0,0x00, - - 4, // 0x78 'x' - 0x00,0x00,0xa0,0xa0,0x40,0xa0,0xa0,0x00, - - 4, // 0x79 'y' - 0x00,0x00,0xa0,0xa0,0xa0,0x60,0x20,0xc0, - - 4, // 0x7a 'z' - 0x00,0x00,0xe0,0x20,0x40,0x80,0xe0,0x00, - - 4, // 0x7b '{' - 0x10,0x20,0x20,0xc0,0x20,0x20,0x10,0x00, - - 4, // 0x7c '|' - 0x00,0x40,0x40,0x40,0x00,0x40,0x40,0x40, - - 4, // 0x7d '}' - 0x80,0x40,0x40,0x30,0x40,0x40,0x80,0x00, - - 4, // 0x7e '~' - 0x00,0x50,0xa0,0x00,0x00,0x00,0x00,0x00, - - 4, // 0x7f '' - 0x00,0x00,0x00,0x60,0x90,0xf0,0x00,0x00, - 0 - }; - - const int8u gse5x7[] = - { - 7, 0, 32, 128-32, - - 0x00,0x00,0x08,0x00,0x10,0x00,0x18,0x00,0x20,0x00,0x28,0x00,0x30,0x00,0x38,0x00,0x40,0x00, - 0x48,0x00,0x50,0x00,0x58,0x00,0x60,0x00,0x68,0x00,0x70,0x00,0x78,0x00,0x80,0x00,0x88,0x00, - 0x90,0x00,0x98,0x00,0xa0,0x00,0xa8,0x00,0xb0,0x00,0xb8,0x00,0xc0,0x00,0xc8,0x00,0xd0,0x00, - 0xd8,0x00,0xe0,0x00,0xe8,0x00,0xf0,0x00,0xf8,0x00,0x00,0x01,0x08,0x01,0x10,0x01,0x18,0x01, - 0x20,0x01,0x28,0x01,0x30,0x01,0x38,0x01,0x40,0x01,0x48,0x01,0x50,0x01,0x58,0x01,0x60,0x01, - 0x68,0x01,0x70,0x01,0x78,0x01,0x80,0x01,0x88,0x01,0x90,0x01,0x98,0x01,0xa0,0x01,0xa8,0x01, - 0xb0,0x01,0xb8,0x01,0xc0,0x01,0xc8,0x01,0xd0,0x01,0xd8,0x01,0xe0,0x01,0xe8,0x01,0xf0,0x01, - 0xf8,0x01,0x00,0x02,0x08,0x02,0x10,0x02,0x18,0x02,0x20,0x02,0x28,0x02,0x30,0x02,0x38,0x02, - 0x40,0x02,0x48,0x02,0x50,0x02,0x58,0x02,0x60,0x02,0x68,0x02,0x70,0x02,0x78,0x02,0x80,0x02, - 0x88,0x02,0x90,0x02,0x98,0x02,0xa0,0x02,0xa8,0x02,0xb0,0x02,0xb8,0x02,0xc0,0x02,0xc8,0x02, - 0xd0,0x02,0xd8,0x02,0xe0,0x02,0xe8,0x02,0xf0,0x02,0xf8,0x02, - - 5, // 0x20 ' ' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x21 '!' - 0x00,0x20,0x20,0x20,0x00,0x20,0x00, - - 5, // 0x22 '"' - 0x00,0x50,0x50,0x00,0x00,0x00,0x00, - - 5, // 0x23 '#' - 0x00,0x50,0xf8,0x50,0xf8,0x50,0x00, - - 5, // 0x24 '$' - 0x20,0x78,0xa0,0x70,0x28,0xf0,0x20, - - 5, // 0x25 '%' - 0x00,0x88,0x10,0x20,0x40,0x88,0x00, - - 5, // 0x26 '&' - 0x00,0x40,0xa0,0x68,0x90,0x68,0x00, - - 5, // 0x27 ''' - 0x00,0x20,0x20,0x00,0x00,0x00,0x00, - - 5, // 0x28 '(' - 0x10,0x20,0x40,0x40,0x40,0x20,0x10, - - 5, // 0x29 ')' - 0x80,0x40,0x20,0x20,0x20,0x40,0x80, - - 5, // 0x2a '*' - 0x00,0x20,0xa8,0x70,0xa8,0x20,0x00, - - 5, // 0x2b '+' - 0x00,0x20,0x20,0xf8,0x20,0x20,0x00, - - 5, // 0x2c ',' - 0x00,0x00,0x00,0x00,0x20,0x20,0x40, - - 5, // 0x2d '-' - 0x00,0x00,0x00,0xf0,0x00,0x00,0x00, - - 5, // 0x2e '.' - 0x00,0x00,0x00,0x00,0x00,0x40,0x00, - - 5, // 0x2f '/' - 0x00,0x08,0x10,0x20,0x40,0x80,0x00, - - 5, // 0x30 '0' - 0x00,0x60,0x90,0x90,0x90,0x60,0x00, - - 5, // 0x31 '1' - 0x00,0x20,0x60,0x20,0x20,0x70,0x00, - - 5, // 0x32 '2' - 0x00,0x60,0x90,0x20,0x40,0xf0,0x00, - - 5, // 0x33 '3' - 0x00,0xf0,0x20,0x60,0x10,0xe0,0x00, - - 5, // 0x34 '4' - 0x00,0x30,0x50,0x90,0xf0,0x10,0x00, - - 5, // 0x35 '5' - 0x00,0xf0,0x80,0xe0,0x10,0xe0,0x00, - - 5, // 0x36 '6' - 0x00,0x60,0x80,0xe0,0x90,0x60,0x00, - - 5, // 0x37 '7' - 0x00,0xf0,0x90,0x20,0x40,0x40,0x00, - - 5, // 0x38 '8' - 0x00,0x60,0x90,0x60,0x90,0x60,0x00, - - 5, // 0x39 '9' - 0x00,0x60,0x90,0x70,0x10,0x60,0x00, - - 5, // 0x3a ':' - 0x00,0x00,0x20,0x00,0x20,0x00,0x00, - - 5, // 0x3b ';' - 0x00,0x00,0x20,0x00,0x20,0x20,0x40, - - 5, // 0x3c '<' - 0x00,0x10,0x20,0x40,0x20,0x10,0x00, - - 5, // 0x3d '=' - 0x00,0x00,0xf0,0x00,0xf0,0x00,0x00, - - 5, // 0x3e '>' - 0x00,0x80,0x40,0x20,0x40,0x80,0x00, - - 5, // 0x3f '?' - 0x00,0x60,0x90,0x20,0x00,0x20,0x00, - - 5, // 0x40 '@' - 0x00,0x60,0x90,0xb0,0x80,0x70,0x00, - - 5, // 0x41 'A' - 0x00,0x60,0x90,0xf0,0x90,0x90,0x00, - - 5, // 0x42 'B' - 0x00,0xe0,0x90,0xe0,0x90,0xe0,0x00, - - 5, // 0x43 'C' - 0x00,0x60,0x90,0x80,0x90,0x60,0x00, - - 5, // 0x44 'D' - 0x00,0xe0,0x90,0x90,0x90,0xe0,0x00, - - 5, // 0x45 'E' - 0x00,0xf0,0x80,0xe0,0x80,0xf0,0x00, - - 5, // 0x46 'F' - 0x00,0xf0,0x80,0xe0,0x80,0x80,0x00, - - 5, // 0x47 'G' - 0x00,0x70,0x80,0xb0,0x90,0x60,0x00, - - 5, // 0x48 'H' - 0x00,0x90,0x90,0xf0,0x90,0x90,0x00, - - 5, // 0x49 'I' - 0x00,0x70,0x20,0x20,0x20,0x70,0x00, - - 5, // 0x4a 'J' - 0x00,0x70,0x20,0x20,0xa0,0x40,0x00, - - 5, // 0x4b 'K' - 0x00,0x90,0xa0,0xc0,0xa0,0x90,0x00, - - 5, // 0x4c 'L' - 0x00,0x80,0x80,0x80,0x80,0xf0,0x00, - - 5, // 0x4d 'M' - 0x00,0x90,0xf0,0x90,0x90,0x90,0x00, - - 5, // 0x4e 'N' - 0x00,0x90,0xd0,0xb0,0x90,0x90,0x00, - - 5, // 0x4f 'O' - 0x00,0x60,0x90,0x90,0x90,0x60,0x00, - - 5, // 0x50 'P' - 0x00,0xe0,0x90,0xe0,0x80,0x80,0x00, - - 5, // 0x51 'Q' - 0x00,0x60,0x90,0x90,0xa0,0x50,0x00, - - 5, // 0x52 'R' - 0x00,0xe0,0x90,0xe0,0xa0,0x90,0x00, - - 5, // 0x53 'S' - 0x00,0x70,0x80,0x60,0x10,0xe0,0x00, - - 5, // 0x54 'T' - 0x00,0x70,0x20,0x20,0x20,0x20,0x00, - - 5, // 0x55 'U' - 0x00,0x90,0x90,0x90,0x90,0x60,0x00, - - 5, // 0x56 'V' - 0x00,0x50,0x50,0x50,0x20,0x20,0x00, - - 5, // 0x57 'W' - 0x00,0x90,0x90,0x90,0xf0,0x90,0x00, - - 5, // 0x58 'X' - 0x00,0x90,0x90,0x60,0x90,0x90,0x00, - - 5, // 0x59 'Y' - 0x00,0x50,0x50,0x20,0x20,0x20,0x00, - - 5, // 0x5a 'Z' - 0x00,0xf0,0x10,0x20,0x40,0xf0,0x00, - - 5, // 0x5b '[' - 0x70,0x40,0x40,0x40,0x40,0x40,0x70, - - 5, // 0x5c '\' - 0x00,0x80,0x40,0x20,0x10,0x08,0x00, - - 5, // 0x5d ']' - 0xe0,0x20,0x20,0x20,0x20,0x20,0xe0, - - 5, // 0x5e '^' - 0x00,0x20,0x50,0x00,0x00,0x00,0x00, - - 5, // 0x5f '_' - 0x00,0x00,0x00,0x00,0x00,0xf8,0x00, - - 5, // 0x60 '`' - 0x00,0x40,0x20,0x00,0x00,0x00,0x00, - - 5, // 0x61 'a' - 0x00,0x00,0x60,0xa0,0xa0,0x50,0x00, - - 5, // 0x62 'b' - 0x00,0x80,0x80,0xe0,0x90,0xe0,0x00, - - 5, // 0x63 'c' - 0x00,0x00,0x70,0x80,0x80,0x70,0x00, - - 5, // 0x64 'd' - 0x00,0x10,0x10,0x70,0x90,0x70,0x00, - - 5, // 0x65 'e' - 0x00,0x00,0x60,0xf0,0x80,0x70,0x00, - - 5, // 0x66 'f' - 0x00,0x30,0x40,0xe0,0x40,0x40,0x00, - - 5, // 0x67 'g' - 0x00,0x00,0x70,0x90,0x70,0x10,0x60, - - 5, // 0x68 'h' - 0x00,0x80,0x80,0xe0,0x90,0x90,0x00, - - 5, // 0x69 'i' - 0x20,0x00,0x60,0x20,0x20,0x70,0x00, - - 5, // 0x6a 'j' - 0x20,0x00,0x60,0x20,0x20,0xa0,0x40, - - 5, // 0x6b 'k' - 0x80,0x80,0x90,0xa0,0xe0,0x90,0x00, - - 5, // 0x6c 'l' - 0x00,0x60,0x20,0x20,0x20,0x70,0x00, - - 5, // 0x6d 'm' - 0x00,0x00,0xa0,0xf0,0xf0,0x90,0x00, - - 5, // 0x6e 'n' - 0x00,0x00,0xa0,0xd0,0x90,0x90,0x00, - - 5, // 0x6f 'o' - 0x00,0x00,0x60,0x90,0x90,0x60,0x00, - - 5, // 0x70 'p' - 0x00,0x00,0xe0,0x90,0xe0,0x80,0x80, - - 5, // 0x71 'q' - 0x00,0x00,0x70,0x90,0x70,0x10,0x10, - - 5, // 0x72 'r' - 0x00,0x00,0xe0,0x90,0x80,0x80,0x00, - - 5, // 0x73 's' - 0x00,0x00,0x70,0xe0,0x10,0xe0,0x00, - - 5, // 0x74 't' - 0x40,0x40,0xe0,0x40,0x40,0x70,0x00, - - 5, // 0x75 'u' - 0x00,0x00,0x90,0x90,0x90,0x70,0x00, - - 5, // 0x76 'v' - 0x00,0x00,0x50,0x50,0x50,0x20,0x00, - - 5, // 0x77 'w' - 0x00,0x00,0x90,0x90,0xf0,0x90,0x00, - - 5, // 0x78 'x' - 0x00,0x00,0x90,0x60,0x60,0x90,0x00, - - 5, // 0x79 'y' - 0x00,0x00,0x90,0x90,0x70,0x10,0x60, - - 5, // 0x7a 'z' - 0x00,0x00,0xf0,0x20,0x40,0xf0,0x00, - - 5, // 0x7b '{' - 0x10,0x20,0x20,0xc0,0x20,0x20,0x10, - - 5, // 0x7c '|' - 0x20,0x20,0x20,0x00,0x20,0x20,0x20, - - 5, // 0x7d '}' - 0x40,0x20,0x20,0x18,0x20,0x20,0x40, - - 5, // 0x7e '~' - 0x00,0x40,0xa8,0x10,0x00,0x00,0x00, - - 5, // 0x7f '' - 0x00,0x00,0x20,0x50,0x88,0xf8,0x00, - 0 - }; - - const int8u gse5x9[] = - { - 9, 0, 32, 128-32, - - 0x00,0x00,0x0a,0x00,0x14,0x00,0x1e,0x00,0x28,0x00,0x32,0x00,0x3c,0x00,0x46,0x00,0x50,0x00, - 0x5a,0x00,0x64,0x00,0x6e,0x00,0x78,0x00,0x82,0x00,0x8c,0x00,0x96,0x00,0xa0,0x00,0xaa,0x00, - 0xb4,0x00,0xbe,0x00,0xc8,0x00,0xd2,0x00,0xdc,0x00,0xe6,0x00,0xf0,0x00,0xfa,0x00,0x04,0x01, - 0x0e,0x01,0x18,0x01,0x22,0x01,0x2c,0x01,0x36,0x01,0x40,0x01,0x4a,0x01,0x54,0x01,0x5e,0x01, - 0x68,0x01,0x72,0x01,0x7c,0x01,0x86,0x01,0x90,0x01,0x9a,0x01,0xa4,0x01,0xae,0x01,0xb8,0x01, - 0xc2,0x01,0xcc,0x01,0xd6,0x01,0xe0,0x01,0xea,0x01,0xf4,0x01,0xfe,0x01,0x08,0x02,0x12,0x02, - 0x1c,0x02,0x26,0x02,0x30,0x02,0x3a,0x02,0x44,0x02,0x4e,0x02,0x58,0x02,0x62,0x02,0x6c,0x02, - 0x76,0x02,0x80,0x02,0x8a,0x02,0x94,0x02,0x9e,0x02,0xa8,0x02,0xb2,0x02,0xbc,0x02,0xc6,0x02, - 0xd0,0x02,0xda,0x02,0xe4,0x02,0xee,0x02,0xf8,0x02,0x02,0x03,0x0c,0x03,0x16,0x03,0x20,0x03, - 0x2a,0x03,0x34,0x03,0x3e,0x03,0x48,0x03,0x52,0x03,0x5c,0x03,0x66,0x03,0x70,0x03,0x7a,0x03, - 0x84,0x03,0x8e,0x03,0x98,0x03,0xa2,0x03,0xac,0x03,0xb6,0x03, - - 5, // 0x20 ' ' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x21 '!' - 0x00,0x20,0x20,0x20,0x20,0x20,0x00,0x20,0x00, - - 5, // 0x22 '"' - 0x00,0x50,0x50,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x23 '#' - 0x00,0x50,0x50,0xf8,0x50,0xf8,0x50,0x50,0x00, - - 5, // 0x24 '$' - 0x00,0x20,0x78,0xa0,0x70,0x28,0xf0,0x20,0x00, - - 5, // 0x25 '%' - 0x00,0xc8,0xc8,0x10,0x20,0x40,0x98,0x98,0x00, - - 5, // 0x26 '&' - 0x00,0x40,0xa0,0xa0,0x40,0xa8,0x90,0x68,0x00, - - 5, // 0x27 ''' - 0x00,0x20,0x20,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x28 '(' - 0x10,0x20,0x40,0x40,0x40,0x40,0x40,0x20,0x10, - - 5, // 0x29 ')' - 0x80,0x40,0x20,0x20,0x20,0x20,0x20,0x40,0x80, - - 5, // 0x2a '*' - 0x00,0x00,0x20,0xa8,0x70,0xa8,0x20,0x00,0x00, - - 5, // 0x2b '+' - 0x00,0x00,0x20,0x20,0xf8,0x20,0x20,0x00,0x00, - - 5, // 0x2c ',' - 0x00,0x00,0x00,0x00,0x00,0x00,0x20,0x20,0x40, - - 5, // 0x2d '-' - 0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00, - - 5, // 0x2e '.' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x40,0x00, - - 5, // 0x2f '/' - 0x00,0x10,0x10,0x20,0x20,0x40,0x40,0x80,0x80, - - 5, // 0x30 '0' - 0x00,0x60,0x90,0xb0,0xd0,0x90,0x90,0x60,0x00, - - 5, // 0x31 '1' - 0x00,0x20,0x60,0x20,0x20,0x20,0x20,0x70,0x00, - - 5, // 0x32 '2' - 0x00,0x60,0x90,0x10,0x20,0x40,0x80,0xf0,0x00, - - 5, // 0x33 '3' - 0x00,0xf0,0x10,0x20,0x60,0x10,0x90,0x60,0x00, - - 5, // 0x34 '4' - 0x00,0x30,0x50,0x90,0x90,0xf8,0x10,0x10,0x00, - - 5, // 0x35 '5' - 0x00,0xf0,0x80,0xe0,0x10,0x10,0x10,0xe0,0x00, - - 5, // 0x36 '6' - 0x00,0x60,0x80,0xe0,0x90,0x90,0x90,0x60,0x00, - - 5, // 0x37 '7' - 0x00,0xf0,0x90,0x10,0x20,0x40,0x40,0x40,0x00, - - 5, // 0x38 '8' - 0x00,0x60,0x90,0x90,0x60,0x90,0x90,0x60,0x00, - - 5, // 0x39 '9' - 0x00,0x60,0x90,0x90,0x70,0x10,0x90,0x60,0x00, - - 5, // 0x3a ':' - 0x00,0x00,0x00,0x20,0x00,0x00,0x20,0x00,0x00, - - 5, // 0x3b ';' - 0x00,0x00,0x00,0x20,0x00,0x00,0x20,0x20,0x40, - - 5, // 0x3c '<' - 0x00,0x10,0x20,0x40,0x80,0x40,0x20,0x10,0x00, - - 5, // 0x3d '=' - 0x00,0x00,0x00,0xf0,0x00,0xf0,0x00,0x00,0x00, - - 5, // 0x3e '>' - 0x00,0x80,0x40,0x20,0x10,0x20,0x40,0x80,0x00, - - 5, // 0x3f '?' - 0x00,0x60,0x90,0x10,0x20,0x20,0x00,0x20,0x00, - - 5, // 0x40 '@' - 0x00,0x60,0x90,0xb0,0xb0,0xb0,0x80,0x70,0x00, - - 5, // 0x41 'A' - 0x00,0x60,0x90,0x90,0xf0,0x90,0x90,0x90,0x00, - - 5, // 0x42 'B' - 0x00,0xe0,0x90,0x90,0xe0,0x90,0x90,0xe0,0x00, - - 5, // 0x43 'C' - 0x00,0x60,0x90,0x80,0x80,0x80,0x90,0x60,0x00, - - 5, // 0x44 'D' - 0x00,0xe0,0x90,0x90,0x90,0x90,0x90,0xe0,0x00, - - 5, // 0x45 'E' - 0x00,0xf0,0x80,0x80,0xe0,0x80,0x80,0xf0,0x00, - - 5, // 0x46 'F' - 0x00,0xf0,0x80,0x80,0xe0,0x80,0x80,0x80,0x00, - - 5, // 0x47 'G' - 0x00,0x60,0x90,0x80,0xb0,0x90,0x90,0x60,0x00, - - 5, // 0x48 'H' - 0x00,0x90,0x90,0x90,0xf0,0x90,0x90,0x90,0x00, - - 5, // 0x49 'I' - 0x00,0x70,0x20,0x20,0x20,0x20,0x20,0x70,0x00, - - 5, // 0x4a 'J' - 0x00,0x70,0x20,0x20,0x20,0x20,0xa0,0x40,0x00, - - 5, // 0x4b 'K' - 0x00,0x90,0x90,0xa0,0xc0,0xa0,0x90,0x90,0x00, - - 5, // 0x4c 'L' - 0x00,0x80,0x80,0x80,0x80,0x80,0x80,0xf0,0x00, - - 5, // 0x4d 'M' - 0x00,0x90,0xf0,0x90,0x90,0x90,0x90,0x90,0x00, - - 5, // 0x4e 'N' - 0x00,0x90,0x90,0xd0,0xb0,0x90,0x90,0x90,0x00, - - 5, // 0x4f 'O' - 0x00,0x60,0x90,0x90,0x90,0x90,0x90,0x60,0x00, - - 5, // 0x50 'P' - 0x00,0xe0,0x90,0x90,0xe0,0x80,0x80,0x80,0x00, - - 5, // 0x51 'Q' - 0x00,0x60,0x90,0x90,0x90,0x90,0xa0,0x50,0x00, - - 5, // 0x52 'R' - 0x00,0xe0,0x90,0x90,0xe0,0xa0,0x90,0x90,0x00, - - 5, // 0x53 'S' - 0x00,0x60,0x90,0x80,0x60,0x10,0x90,0x60,0x00, - - 5, // 0x54 'T' - 0x00,0x70,0x20,0x20,0x20,0x20,0x20,0x20,0x00, - - 5, // 0x55 'U' - 0x00,0x90,0x90,0x90,0x90,0x90,0x90,0x60,0x00, - - 5, // 0x56 'V' - 0x00,0x50,0x50,0x50,0x50,0x50,0x20,0x20,0x00, - - 5, // 0x57 'W' - 0x00,0x90,0x90,0x90,0x90,0x90,0xf0,0x90,0x00, - - 5, // 0x58 'X' - 0x00,0x90,0x90,0x60,0x60,0x90,0x90,0x90,0x00, - - 5, // 0x59 'Y' - 0x00,0x50,0x50,0x50,0x20,0x20,0x20,0x20,0x00, - - 5, // 0x5a 'Z' - 0x00,0xf0,0x10,0x10,0x20,0x40,0x80,0xf0,0x00, - - 5, // 0x5b '[' - 0x70,0x40,0x40,0x40,0x40,0x40,0x40,0x70,0x00, - - 5, // 0x5c '\' - 0x80,0x80,0x40,0x40,0x20,0x20,0x10,0x10,0x00, - - 5, // 0x5d ']' - 0xe0,0x20,0x20,0x20,0x20,0x20,0x20,0xe0,0x00, - - 5, // 0x5e '^' - 0x00,0x20,0x50,0x88,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x5f '_' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8,0x00, - - 5, // 0x60 '`' - 0x00,0x40,0x20,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x61 'a' - 0x00,0x00,0x60,0x10,0x70,0x90,0x90,0x70,0x00, - - 5, // 0x62 'b' - 0x00,0x80,0x80,0xe0,0x90,0x90,0x90,0xe0,0x00, - - 5, // 0x63 'c' - 0x00,0x00,0x60,0x90,0x80,0x80,0x90,0x60,0x00, - - 5, // 0x64 'd' - 0x00,0x10,0x10,0x70,0x90,0x90,0x90,0x70,0x00, - - 5, // 0x65 'e' - 0x00,0x00,0x60,0x90,0xf0,0x80,0x80,0x70,0x00, - - 5, // 0x66 'f' - 0x00,0x30,0x40,0x40,0xe0,0x40,0x40,0x40,0x00, - - 5, // 0x67 'g' - 0x00,0x00,0x70,0x90,0x90,0x70,0x10,0x90,0x60, - - 5, // 0x68 'h' - 0x00,0x80,0x80,0xe0,0x90,0x90,0x90,0x90,0x00, - - 5, // 0x69 'i' - 0x00,0x20,0x00,0x60,0x20,0x20,0x20,0x70,0x00, - - 5, // 0x6a 'j' - 0x00,0x20,0x00,0x60,0x20,0x20,0x20,0xa0,0x40, - - 5, // 0x6b 'k' - 0x00,0x80,0x80,0x90,0xa0,0xc0,0xa0,0x90,0x00, - - 5, // 0x6c 'l' - 0x00,0x60,0x20,0x20,0x20,0x20,0x20,0x70,0x00, - - 5, // 0x6d 'm' - 0x00,0x00,0xa0,0xf0,0xf0,0xf0,0x90,0x90,0x00, - - 5, // 0x6e 'n' - 0x00,0x00,0xa0,0xd0,0x90,0x90,0x90,0x90,0x00, - - 5, // 0x6f 'o' - 0x00,0x00,0x60,0x90,0x90,0x90,0x90,0x60,0x00, - - 5, // 0x70 'p' - 0x00,0x00,0xe0,0x90,0x90,0x90,0xe0,0x80,0x80, - - 5, // 0x71 'q' - 0x00,0x00,0x70,0x90,0x90,0x90,0x70,0x10,0x10, - - 5, // 0x72 'r' - 0x00,0x00,0xe0,0x90,0x80,0x80,0x80,0x80,0x00, - - 5, // 0x73 's' - 0x00,0x00,0x60,0x90,0x40,0x20,0x90,0x60,0x00, - - 5, // 0x74 't' - 0x00,0x40,0x40,0xe0,0x40,0x40,0x50,0x20,0x00, - - 5, // 0x75 'u' - 0x00,0x00,0x90,0x90,0x90,0x90,0x90,0x70,0x00, - - 5, // 0x76 'v' - 0x00,0x00,0x50,0x50,0x50,0x50,0x20,0x20,0x00, - - 5, // 0x77 'w' - 0x00,0x00,0x90,0x90,0x90,0x90,0xf0,0x90,0x00, - - 5, // 0x78 'x' - 0x00,0x00,0x90,0x90,0x60,0x60,0x90,0x90,0x00, - - 5, // 0x79 'y' - 0x00,0x00,0x90,0x90,0x90,0x90,0x70,0x10,0xe0, - - 5, // 0x7a 'z' - 0x00,0x00,0xf0,0x10,0x20,0x40,0x80,0xf0,0x00, - - 5, // 0x7b '{' - 0x10,0x20,0x20,0x20,0xc0,0x20,0x20,0x20,0x10, - - 5, // 0x7c '|' - 0x00,0x20,0x20,0x20,0x00,0x20,0x20,0x20,0x00, - - 5, // 0x7d '}' - 0x80,0x40,0x40,0x40,0x30,0x40,0x40,0x40,0x80, - - 5, // 0x7e '~' - 0x00,0x40,0xa8,0x10,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x7f '' - 0x00,0x00,0x00,0x20,0x50,0x88,0xf8,0x00,0x00, - 0 - }; - - const int8u gse6x12[] = - { - 12, 0, 32, 128-32, - - 0x00,0x00,0x0d,0x00,0x1a,0x00,0x27,0x00,0x34,0x00,0x41,0x00,0x4e,0x00,0x5b,0x00,0x68,0x00, - 0x75,0x00,0x82,0x00,0x8f,0x00,0x9c,0x00,0xa9,0x00,0xb6,0x00,0xc3,0x00,0xd0,0x00,0xdd,0x00, - 0xea,0x00,0xf7,0x00,0x04,0x01,0x11,0x01,0x1e,0x01,0x2b,0x01,0x38,0x01,0x45,0x01,0x52,0x01, - 0x5f,0x01,0x6c,0x01,0x79,0x01,0x86,0x01,0x93,0x01,0xa0,0x01,0xad,0x01,0xba,0x01,0xc7,0x01, - 0xd4,0x01,0xe1,0x01,0xee,0x01,0xfb,0x01,0x08,0x02,0x15,0x02,0x22,0x02,0x2f,0x02,0x3c,0x02, - 0x49,0x02,0x56,0x02,0x63,0x02,0x70,0x02,0x7d,0x02,0x8a,0x02,0x97,0x02,0xa4,0x02,0xb1,0x02, - 0xbe,0x02,0xcb,0x02,0xd8,0x02,0xe5,0x02,0xf2,0x02,0xff,0x02,0x0c,0x03,0x19,0x03,0x26,0x03, - 0x33,0x03,0x40,0x03,0x4d,0x03,0x5a,0x03,0x67,0x03,0x74,0x03,0x81,0x03,0x8e,0x03,0x9b,0x03, - 0xa8,0x03,0xb5,0x03,0xc2,0x03,0xcf,0x03,0xdc,0x03,0xe9,0x03,0xf6,0x03,0x03,0x04,0x10,0x04, - 0x1d,0x04,0x2a,0x04,0x37,0x04,0x44,0x04,0x51,0x04,0x5e,0x04,0x6b,0x04,0x78,0x04,0x85,0x04, - 0x92,0x04,0x9f,0x04,0xac,0x04,0xb9,0x04,0xc6,0x04,0xd3,0x04, - - 6, // 0x20 ' ' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x21 '!' - 0x00,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x00,0x20,0x00,0x00, - - 6, // 0x22 '"' - 0x00,0x50,0x50,0x50,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x23 '#' - 0x00,0x50,0x50,0xf8,0x50,0x50,0x50,0xf8,0x50,0x50,0x00,0x00, - - 6, // 0x24 '$' - 0x00,0x20,0x70,0xa8,0xa0,0x70,0x28,0xa8,0x70,0x20,0x00,0x00, - - 6, // 0x25 '%' - 0x00,0xc8,0xd8,0x10,0x30,0x20,0x60,0x40,0xd8,0x98,0x00,0x00, - - 6, // 0x26 '&' - 0x00,0x60,0x90,0x90,0x90,0x60,0xa8,0x90,0x90,0x68,0x00,0x00, - - 6, // 0x27 ''' - 0x00,0x20,0x20,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x28 '(' - 0x00,0x10,0x20,0x40,0x40,0x40,0x40,0x40,0x20,0x10,0x00,0x00, - - 6, // 0x29 ')' - 0x00,0x40,0x20,0x10,0x10,0x10,0x10,0x10,0x20,0x40,0x00,0x00, - - 6, // 0x2a '*' - 0x00,0x00,0x00,0x50,0x20,0xf8,0x20,0x50,0x00,0x00,0x00,0x00, - - 6, // 0x2b '+' - 0x00,0x00,0x20,0x20,0x20,0xf8,0x20,0x20,0x20,0x00,0x00,0x00, - - 6, // 0x2c ',' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,0x20,0x20,0x40, - - 6, // 0x2d '-' - 0x00,0x00,0x00,0x00,0x00,0xf8,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x2e '.' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,0x00,0x00, - - 6, // 0x2f '/' - 0x08,0x08,0x10,0x10,0x20,0x20,0x40,0x40,0x80,0x80,0x00,0x00, - - 6, // 0x30 '0' - 0x00,0x70,0x88,0x88,0x98,0xa8,0xc8,0x88,0x88,0x70,0x00,0x00, - - 6, // 0x31 '1' - 0x00,0x20,0x20,0x60,0x20,0x20,0x20,0x20,0x20,0x70,0x00,0x00, - - 6, // 0x32 '2' - 0x00,0x70,0x88,0x88,0x08,0x10,0x20,0x40,0x80,0xf8,0x00,0x00, - - 6, // 0x33 '3' - 0x00,0xf8,0x10,0x20,0x70,0x08,0x08,0x08,0x88,0x70,0x00,0x00, - - 6, // 0x34 '4' - 0x00,0x10,0x20,0x40,0x90,0x90,0xf8,0x10,0x10,0x10,0x00,0x00, - - 6, // 0x35 '5' - 0x00,0xf8,0x80,0x80,0xf0,0x08,0x08,0x08,0x88,0x70,0x00,0x00, - - 6, // 0x36 '6' - 0x00,0x70,0x88,0x80,0x80,0xf0,0x88,0x88,0x88,0x70,0x00,0x00, - - 6, // 0x37 '7' - 0x00,0xf8,0x88,0x08,0x08,0x10,0x20,0x20,0x20,0x20,0x00,0x00, - - 6, // 0x38 '8' - 0x00,0x70,0x88,0x88,0x88,0x70,0x88,0x88,0x88,0x70,0x00,0x00, - - 6, // 0x39 '9' - 0x00,0x70,0x88,0x88,0x88,0x78,0x08,0x08,0x88,0x70,0x00,0x00, - - 6, // 0x3a ':' - 0x00,0x00,0x00,0x00,0x20,0x00,0x00,0x00,0x20,0x00,0x00,0x00, - - 6, // 0x3b ';' - 0x00,0x00,0x00,0x00,0x20,0x00,0x00,0x00,0x20,0x20,0x20,0x40, - - 6, // 0x3c '<' - 0x00,0x08,0x10,0x20,0x40,0x80,0x40,0x20,0x10,0x08,0x00,0x00, - - 6, // 0x3d '=' - 0x00,0x00,0x00,0x00,0xf8,0x00,0xf8,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x3e '>' - 0x00,0x80,0x40,0x20,0x10,0x08,0x10,0x20,0x40,0x80,0x00,0x00, - - 6, // 0x3f '?' - 0x00,0x70,0x88,0x88,0x08,0x10,0x20,0x20,0x00,0x20,0x00,0x00, - - 6, // 0x40 '@' - 0x00,0x70,0x88,0x88,0xb8,0xb8,0xb0,0x80,0x88,0x70,0x00,0x00, - - 6, // 0x41 'A' - 0x00,0x20,0x50,0x88,0x88,0x88,0xf8,0x88,0x88,0x88,0x00,0x00, - - 6, // 0x42 'B' - 0x00,0xf0,0x88,0x88,0x88,0xf0,0x88,0x88,0x88,0xf0,0x00,0x00, - - 6, // 0x43 'C' - 0x00,0x70,0x88,0x88,0x80,0x80,0x80,0x88,0x88,0x70,0x00,0x00, - - 6, // 0x44 'D' - 0x00,0xe0,0x90,0x88,0x88,0x88,0x88,0x88,0x90,0xe0,0x00,0x00, - - 6, // 0x45 'E' - 0x00,0xf8,0x80,0x80,0x80,0xf0,0x80,0x80,0x80,0xf8,0x00,0x00, - - 6, // 0x46 'F' - 0x00,0xf8,0x80,0x80,0x80,0xf0,0x80,0x80,0x80,0x80,0x00,0x00, - - 6, // 0x47 'G' - 0x00,0x70,0x88,0x80,0x80,0xb8,0x88,0x88,0x88,0x70,0x00,0x00, - - 6, // 0x48 'H' - 0x00,0x88,0x88,0x88,0x88,0xf8,0x88,0x88,0x88,0x88,0x00,0x00, - - 6, // 0x49 'I' - 0x00,0x70,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x70,0x00,0x00, - - 6, // 0x4a 'J' - 0x00,0x38,0x10,0x10,0x10,0x10,0x10,0x10,0x90,0x60,0x00,0x00, - - 6, // 0x4b 'K' - 0x00,0x88,0x88,0x90,0xa0,0xc0,0xa0,0x90,0x88,0x88,0x00,0x00, - - 6, // 0x4c 'L' - 0x00,0x80,0x80,0x80,0x80,0x80,0x80,0x80,0x80,0xf8,0x00,0x00, - - 6, // 0x4d 'M' - 0x00,0x88,0x88,0xd8,0xa8,0x88,0x88,0x88,0x88,0x88,0x00,0x00, - - 6, // 0x4e 'N' - 0x00,0x88,0x88,0xc8,0xa8,0x98,0x88,0x88,0x88,0x88,0x00,0x00, - - 6, // 0x4f 'O' - 0x00,0x70,0x88,0x88,0x88,0x88,0x88,0x88,0x88,0x70,0x00,0x00, - - 6, // 0x50 'P' - 0x00,0xf0,0x88,0x88,0x88,0xf0,0x80,0x80,0x80,0x80,0x00,0x00, - - 6, // 0x51 'Q' - 0x00,0x70,0x88,0x88,0x88,0x88,0x88,0xa8,0x90,0x68,0x00,0x00, - - 6, // 0x52 'R' - 0x00,0xf0,0x88,0x88,0x88,0x88,0xf0,0xa0,0x90,0x88,0x00,0x00, - - 6, // 0x53 'S' - 0x00,0x70,0x88,0x80,0x80,0x70,0x08,0x08,0x88,0x70,0x00,0x00, - - 6, // 0x54 'T' - 0x00,0xf8,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x00,0x00, - - 6, // 0x55 'U' - 0x00,0x88,0x88,0x88,0x88,0x88,0x88,0x88,0x88,0x70,0x00,0x00, - - 6, // 0x56 'V' - 0x00,0x88,0x88,0x88,0x88,0x88,0x50,0x50,0x20,0x20,0x00,0x00, - - 6, // 0x57 'W' - 0x00,0x88,0x88,0x88,0x88,0x88,0xa8,0xa8,0xd8,0x88,0x00,0x00, - - 6, // 0x58 'X' - 0x00,0x88,0x88,0x88,0x50,0x20,0x50,0x88,0x88,0x88,0x00,0x00, - - 6, // 0x59 'Y' - 0x00,0x88,0x88,0x88,0x50,0x20,0x20,0x20,0x20,0x20,0x00,0x00, - - 6, // 0x5a 'Z' - 0x00,0xf8,0x08,0x08,0x10,0x20,0x40,0x80,0x80,0xf8,0x00,0x00, - - 6, // 0x5b '[' - 0x70,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x70,0x00, - - 6, // 0x5c '\' - 0x80,0x80,0x40,0x40,0x20,0x20,0x10,0x10,0x08,0x08,0x00,0x00, - - 6, // 0x5d ']' - 0x70,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x70,0x00, - - 6, // 0x5e '^' - 0x00,0x00,0x20,0x50,0x88,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x5f '_' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8,0x00,0x00, - - 6, // 0x60 '`' - 0x00,0x40,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x61 'a' - 0x00,0x00,0x00,0x70,0x88,0x08,0x78,0x88,0x88,0x78,0x00,0x00, - - 6, // 0x62 'b' - 0x00,0x80,0x80,0x80,0xf0,0x88,0x88,0x88,0x88,0xf0,0x00,0x00, - - 6, // 0x63 'c' - 0x00,0x00,0x00,0x70,0x88,0x80,0x80,0x80,0x88,0x70,0x00,0x00, - - 6, // 0x64 'd' - 0x00,0x08,0x08,0x08,0x78,0x88,0x88,0x88,0x88,0x78,0x00,0x00, - - 6, // 0x65 'e' - 0x00,0x00,0x00,0x70,0x88,0x88,0xf8,0x80,0x80,0x78,0x00,0x00, - - 6, // 0x66 'f' - 0x00,0x18,0x20,0x20,0xf8,0x20,0x20,0x20,0x20,0x20,0x00,0x00, - - 6, // 0x67 'g' - 0x00,0x00,0x00,0x78,0x88,0x88,0x88,0x88,0x78,0x08,0x08,0xf0, - - 6, // 0x68 'h' - 0x00,0x80,0x80,0x80,0xf0,0x88,0x88,0x88,0x88,0x88,0x00,0x00, - - 6, // 0x69 'i' - 0x00,0x20,0x00,0x00,0x60,0x20,0x20,0x20,0x20,0x70,0x00,0x00, - - 6, // 0x6a 'j' - 0x00,0x10,0x00,0x00,0x30,0x10,0x10,0x10,0x10,0x10,0x90,0x60, - - 6, // 0x6b 'k' - 0x00,0x80,0x80,0x80,0x88,0x90,0xa0,0xd0,0x88,0x88,0x00,0x00, - - 6, // 0x6c 'l' - 0x00,0x60,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x70,0x00,0x00, - - 6, // 0x6d 'm' - 0x00,0x00,0x00,0xd0,0xa8,0xa8,0xa8,0xa8,0xa8,0xa8,0x00,0x00, - - 6, // 0x6e 'n' - 0x00,0x00,0x00,0xb0,0xc8,0x88,0x88,0x88,0x88,0x88,0x00,0x00, - - 6, // 0x6f 'o' - 0x00,0x00,0x00,0x70,0x88,0x88,0x88,0x88,0x88,0x70,0x00,0x00, - - 6, // 0x70 'p' - 0x00,0x00,0x00,0xf0,0x88,0x88,0x88,0x88,0xf0,0x80,0x80,0x80, - - 6, // 0x71 'q' - 0x00,0x00,0x00,0x78,0x88,0x88,0x88,0x88,0x78,0x08,0x08,0x08, - - 6, // 0x72 'r' - 0x00,0x00,0x00,0xb0,0xc8,0x88,0x80,0x80,0x80,0x80,0x00,0x00, - - 6, // 0x73 's' - 0x00,0x00,0x00,0x70,0x88,0x80,0x70,0x08,0x88,0x70,0x00,0x00, - - 6, // 0x74 't' - 0x00,0x40,0x40,0x40,0xe0,0x40,0x40,0x40,0x48,0x30,0x00,0x00, - - 6, // 0x75 'u' - 0x00,0x00,0x00,0x88,0x88,0x88,0x88,0x88,0x88,0x78,0x00,0x00, - - 6, // 0x76 'v' - 0x00,0x00,0x00,0x88,0x88,0x88,0x50,0x50,0x20,0x20,0x00,0x00, - - 6, // 0x77 'w' - 0x00,0x00,0x00,0x88,0x88,0x88,0xa8,0xa8,0xd8,0x88,0x00,0x00, - - 6, // 0x78 'x' - 0x00,0x00,0x00,0x88,0x88,0x50,0x20,0x50,0x88,0x88,0x00,0x00, - - 6, // 0x79 'y' - 0x00,0x00,0x00,0x88,0x88,0x88,0x88,0x88,0x78,0x08,0x10,0xe0, - - 6, // 0x7a 'z' - 0x00,0x00,0x00,0xf8,0x08,0x10,0x20,0x40,0x80,0xf8,0x00,0x00, - - 6, // 0x7b '{' - 0x18,0x20,0x20,0x20,0x20,0xc0,0x20,0x20,0x20,0x20,0x18,0x00, - - 6, // 0x7c '|' - 0x00,0x20,0x20,0x20,0x20,0x00,0x20,0x20,0x20,0x20,0x00,0x00, - - 6, // 0x7d '}' - 0xc0,0x20,0x20,0x20,0x20,0x18,0x20,0x20,0x20,0x20,0xc0,0x00, - - 6, // 0x7e '~' - 0x00,0x00,0x40,0xa8,0x10,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x7f '' - 0x00,0x00,0x00,0x00,0x20,0x50,0x88,0xf8,0x00,0x00,0x00,0x00, - 0 - }; - - const int8u gse6x9[] = - { - 9, 0, 32, 128-32, - - 0x00,0x00,0x0a,0x00,0x14,0x00,0x1e,0x00,0x28,0x00,0x32,0x00,0x3c,0x00,0x46,0x00,0x50,0x00, - 0x5a,0x00,0x64,0x00,0x6e,0x00,0x78,0x00,0x82,0x00,0x8c,0x00,0x96,0x00,0xa0,0x00,0xaa,0x00, - 0xb4,0x00,0xbe,0x00,0xc8,0x00,0xd2,0x00,0xdc,0x00,0xe6,0x00,0xf0,0x00,0xfa,0x00,0x04,0x01, - 0x0e,0x01,0x18,0x01,0x22,0x01,0x2c,0x01,0x36,0x01,0x40,0x01,0x4a,0x01,0x54,0x01,0x5e,0x01, - 0x68,0x01,0x72,0x01,0x7c,0x01,0x86,0x01,0x90,0x01,0x9a,0x01,0xa4,0x01,0xae,0x01,0xb8,0x01, - 0xc2,0x01,0xcc,0x01,0xd6,0x01,0xe0,0x01,0xea,0x01,0xf4,0x01,0xfe,0x01,0x08,0x02,0x12,0x02, - 0x1c,0x02,0x26,0x02,0x30,0x02,0x3a,0x02,0x44,0x02,0x4e,0x02,0x58,0x02,0x62,0x02,0x6c,0x02, - 0x76,0x02,0x80,0x02,0x8a,0x02,0x94,0x02,0x9e,0x02,0xa8,0x02,0xb2,0x02,0xbc,0x02,0xc6,0x02, - 0xd0,0x02,0xda,0x02,0xe4,0x02,0xee,0x02,0xf8,0x02,0x02,0x03,0x0c,0x03,0x16,0x03,0x20,0x03, - 0x2a,0x03,0x34,0x03,0x3e,0x03,0x48,0x03,0x52,0x03,0x5c,0x03,0x66,0x03,0x70,0x03,0x7a,0x03, - 0x84,0x03,0x8e,0x03,0x98,0x03,0xa2,0x03,0xac,0x03,0xb6,0x03, - - 6, // 0x20 ' ' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x21 '!' - 0x00,0x20,0x20,0x20,0x20,0x20,0x00,0x20,0x00, - - 6, // 0x22 '"' - 0x00,0x50,0x50,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x23 '#' - 0x00,0x50,0x50,0xf8,0x50,0xf8,0x50,0x50,0x00, - - 6, // 0x24 '$' - 0x00,0x70,0xa8,0xa0,0x70,0x28,0xa8,0x70,0x00, - - 6, // 0x25 '%' - 0x00,0xc8,0xc8,0x10,0x20,0x40,0x98,0x98,0x00, - - 6, // 0x26 '&' - 0x00,0x60,0x90,0x90,0x60,0xa8,0x90,0x68,0x00, - - 6, // 0x27 ''' - 0x00,0x20,0x20,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x28 '(' - 0x10,0x20,0x40,0x40,0x40,0x40,0x40,0x20,0x10, - - 6, // 0x29 ')' - 0x40,0x20,0x10,0x10,0x10,0x10,0x10,0x20,0x40, - - 6, // 0x2a '*' - 0x00,0x00,0x20,0xa8,0x70,0xa8,0x20,0x00,0x00, - - 6, // 0x2b '+' - 0x00,0x00,0x20,0x20,0xf8,0x20,0x20,0x00,0x00, - - 6, // 0x2c ',' - 0x00,0x00,0x00,0x00,0x00,0x00,0x20,0x20,0x40, - - 6, // 0x2d '-' - 0x00,0x00,0x00,0x00,0xf8,0x00,0x00,0x00,0x00, - - 6, // 0x2e '.' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x40,0x00, - - 6, // 0x2f '/' - 0x00,0x08,0x08,0x10,0x20,0x40,0x80,0x80,0x00, - - 6, // 0x30 '0' - 0x00,0x70,0x88,0x98,0xa8,0xc8,0x88,0x70,0x00, - - 6, // 0x31 '1' - 0x00,0x20,0x60,0x20,0x20,0x20,0x20,0x70,0x00, - - 6, // 0x32 '2' - 0x00,0x70,0x88,0x08,0x10,0x20,0x40,0xf8,0x00, - - 6, // 0x33 '3' - 0x00,0xf8,0x10,0x20,0x70,0x08,0x88,0x70,0x00, - - 6, // 0x34 '4' - 0x00,0x10,0x20,0x40,0x90,0xf8,0x10,0x10,0x00, - - 6, // 0x35 '5' - 0x00,0xf8,0x80,0xf0,0x08,0x08,0x88,0x70,0x00, - - 6, // 0x36 '6' - 0x00,0x70,0x88,0x80,0xf0,0x88,0x88,0x70,0x00, - - 6, // 0x37 '7' - 0x00,0xf8,0x08,0x08,0x10,0x20,0x40,0x40,0x00, - - 6, // 0x38 '8' - 0x00,0x70,0x88,0x88,0x70,0x88,0x88,0x70,0x00, - - 6, // 0x39 '9' - 0x00,0x70,0x88,0x88,0x78,0x08,0x88,0x70,0x00, - - 6, // 0x3a ':' - 0x00,0x00,0x00,0x20,0x00,0x00,0x20,0x00,0x00, - - 6, // 0x3b ';' - 0x00,0x00,0x00,0x20,0x00,0x00,0x20,0x20,0x40, - - 6, // 0x3c '<' - 0x00,0x08,0x10,0x20,0x40,0x20,0x10,0x08,0x00, - - 6, // 0x3d '=' - 0x00,0x00,0x00,0xf8,0x00,0xf8,0x00,0x00,0x00, - - 6, // 0x3e '>' - 0x00,0x80,0x40,0x20,0x10,0x20,0x40,0x80,0x00, - - 6, // 0x3f '?' - 0x00,0x70,0x88,0x08,0x10,0x20,0x00,0x20,0x00, - - 6, // 0x40 '@' - 0x00,0x70,0x88,0x88,0xb8,0xb8,0x80,0x70,0x00, - - 6, // 0x41 'A' - 0x00,0x20,0x50,0x88,0x88,0xf8,0x88,0x88,0x00, - - 6, // 0x42 'B' - 0x00,0xf0,0x88,0x88,0xf0,0x88,0x88,0xf0,0x00, - - 6, // 0x43 'C' - 0x00,0x70,0x88,0x80,0x80,0x80,0x88,0x70,0x00, - - 6, // 0x44 'D' - 0x00,0xe0,0x90,0x88,0x88,0x88,0x90,0xe0,0x00, - - 6, // 0x45 'E' - 0x00,0xf8,0x80,0x80,0xf0,0x80,0x80,0xf8,0x00, - - 6, // 0x46 'F' - 0x00,0xf8,0x80,0x80,0xf0,0x80,0x80,0x80,0x00, - - 6, // 0x47 'G' - 0x00,0x70,0x88,0x80,0xb8,0x88,0x88,0x70,0x00, - - 6, // 0x48 'H' - 0x00,0x88,0x88,0x88,0xf8,0x88,0x88,0x88,0x00, - - 6, // 0x49 'I' - 0x00,0x70,0x20,0x20,0x20,0x20,0x20,0x70,0x00, - - 6, // 0x4a 'J' - 0x00,0x38,0x10,0x10,0x10,0x10,0x90,0x60,0x00, - - 6, // 0x4b 'K' - 0x00,0x88,0x90,0xa0,0xc0,0xa0,0x90,0x88,0x00, - - 6, // 0x4c 'L' - 0x00,0x80,0x80,0x80,0x80,0x80,0x80,0xf8,0x00, - - 6, // 0x4d 'M' - 0x00,0x88,0xd8,0xa8,0x88,0x88,0x88,0x88,0x00, - - 6, // 0x4e 'N' - 0x00,0x88,0x88,0xc8,0xa8,0x98,0x88,0x88,0x00, - - 6, // 0x4f 'O' - 0x00,0x70,0x88,0x88,0x88,0x88,0x88,0x70,0x00, - - 6, // 0x50 'P' - 0x00,0xf0,0x88,0x88,0xf0,0x80,0x80,0x80,0x00, - - 6, // 0x51 'Q' - 0x00,0x70,0x88,0x88,0x88,0xa8,0x90,0x68,0x00, - - 6, // 0x52 'R' - 0x00,0xf0,0x88,0x88,0x88,0xf0,0x90,0x88,0x00, - - 6, // 0x53 'S' - 0x00,0x70,0x88,0x80,0x70,0x08,0x88,0x70,0x00, - - 6, // 0x54 'T' - 0x00,0xf8,0x20,0x20,0x20,0x20,0x20,0x20,0x00, - - 6, // 0x55 'U' - 0x00,0x88,0x88,0x88,0x88,0x88,0x88,0x70,0x00, - - 6, // 0x56 'V' - 0x00,0x88,0x88,0x88,0x50,0x50,0x20,0x20,0x00, - - 6, // 0x57 'W' - 0x00,0x88,0x88,0x88,0xa8,0xa8,0xd8,0x88,0x00, - - 6, // 0x58 'X' - 0x00,0x88,0x88,0x50,0x20,0x50,0x88,0x88,0x00, - - 6, // 0x59 'Y' - 0x00,0x88,0x88,0x50,0x20,0x20,0x20,0x20,0x00, - - 6, // 0x5a 'Z' - 0x00,0xf8,0x08,0x10,0x20,0x40,0x80,0xf8,0x00, - - 6, // 0x5b '[' - 0x70,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x70, - - 6, // 0x5c '\' - 0x00,0x80,0x80,0x40,0x20,0x10,0x08,0x08,0x00, - - 6, // 0x5d ']' - 0x70,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x70, - - 6, // 0x5e '^' - 0x00,0x00,0x20,0x50,0x88,0x00,0x00,0x00,0x00, - - 6, // 0x5f '_' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8,0x00, - - 6, // 0x60 '`' - 0x00,0x40,0x20,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x61 'a' - 0x00,0x00,0x00,0x70,0x08,0x78,0x88,0x78,0x00, - - 6, // 0x62 'b' - 0x00,0x80,0x80,0xf0,0x88,0x88,0x88,0xf0,0x00, - - 6, // 0x63 'c' - 0x00,0x00,0x00,0x70,0x88,0x80,0x88,0x70,0x00, - - 6, // 0x64 'd' - 0x00,0x08,0x08,0x78,0x88,0x88,0x88,0x78,0x00, - - 6, // 0x65 'e' - 0x00,0x00,0x00,0x70,0x88,0xf8,0x80,0x78,0x00, - - 6, // 0x66 'f' - 0x00,0x18,0x20,0x20,0xf8,0x20,0x20,0x20,0x00, - - 6, // 0x67 'g' - 0x00,0x00,0x00,0x78,0x88,0x88,0x78,0x08,0x70, - - 6, // 0x68 'h' - 0x00,0x80,0x80,0xf0,0x88,0x88,0x88,0x88,0x00, - - 6, // 0x69 'i' - 0x00,0x20,0x00,0x60,0x20,0x20,0x20,0x70,0x00, - - 6, // 0x6a 'j' - 0x00,0x10,0x00,0x30,0x10,0x10,0x10,0x90,0x60, - - 6, // 0x6b 'k' - 0x00,0x00,0x80,0x88,0x90,0xa0,0xd0,0x88,0x00, - - 6, // 0x6c 'l' - 0x00,0x60,0x20,0x20,0x20,0x20,0x20,0x70,0x00, - - 6, // 0x6d 'm' - 0x00,0x00,0x00,0xd0,0xa8,0xa8,0xa8,0xa8,0x00, - - 6, // 0x6e 'n' - 0x00,0x00,0x00,0xb0,0xc8,0x88,0x88,0x88,0x00, - - 6, // 0x6f 'o' - 0x00,0x00,0x00,0x70,0x88,0x88,0x88,0x70,0x00, - - 6, // 0x70 'p' - 0x00,0x00,0x00,0xf0,0x88,0x88,0xf0,0x80,0x80, - - 6, // 0x71 'q' - 0x00,0x00,0x00,0x78,0x88,0x88,0x78,0x08,0x08, - - 6, // 0x72 'r' - 0x00,0x00,0x00,0xb8,0xc0,0x80,0x80,0x80,0x00, - - 6, // 0x73 's' - 0x00,0x00,0x00,0x78,0x80,0x70,0x08,0xf0,0x00, - - 6, // 0x74 't' - 0x00,0x40,0x40,0xe0,0x40,0x40,0x48,0x30,0x00, - - 6, // 0x75 'u' - 0x00,0x00,0x00,0x88,0x88,0x88,0x88,0x78,0x00, - - 6, // 0x76 'v' - 0x00,0x00,0x00,0x88,0x88,0x88,0x50,0x20,0x00, - - 6, // 0x77 'w' - 0x00,0x00,0x00,0x88,0x88,0xa8,0xd8,0x88,0x00, - - 6, // 0x78 'x' - 0x00,0x00,0x00,0x88,0x50,0x20,0x50,0x88,0x00, - - 6, // 0x79 'y' - 0x00,0x00,0x00,0x88,0x88,0x88,0x78,0x08,0x70, - - 6, // 0x7a 'z' - 0x00,0x00,0x00,0xf8,0x10,0x20,0x40,0xf8,0x00, - - 6, // 0x7b '{' - 0x18,0x20,0x20,0x20,0xc0,0x20,0x20,0x20,0x18, - - 6, // 0x7c '|' - 0x00,0x20,0x20,0x20,0x00,0x20,0x20,0x20,0x00, - - 6, // 0x7d '}' - 0xc0,0x20,0x20,0x20,0x18,0x20,0x20,0x20,0xc0, - - 6, // 0x7e '~' - 0x00,0x40,0xa8,0x10,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x7f '' - 0x00,0x00,0x00,0x20,0x50,0x88,0xf8,0x00,0x00, - 0 - }; - - const int8u gse7x11[] = - { - 11, 0, 32, 128-32, - - 0x00,0x00,0x0c,0x00,0x18,0x00,0x24,0x00,0x30,0x00,0x3c,0x00,0x48,0x00,0x54,0x00,0x60,0x00, - 0x6c,0x00,0x78,0x00,0x84,0x00,0x90,0x00,0x9c,0x00,0xa8,0x00,0xb4,0x00,0xc0,0x00,0xcc,0x00, - 0xd8,0x00,0xe4,0x00,0xf0,0x00,0xfc,0x00,0x08,0x01,0x14,0x01,0x20,0x01,0x2c,0x01,0x38,0x01, - 0x44,0x01,0x50,0x01,0x5c,0x01,0x68,0x01,0x74,0x01,0x80,0x01,0x8c,0x01,0x98,0x01,0xa4,0x01, - 0xb0,0x01,0xbc,0x01,0xc8,0x01,0xd4,0x01,0xe0,0x01,0xec,0x01,0xf8,0x01,0x04,0x02,0x10,0x02, - 0x1c,0x02,0x28,0x02,0x34,0x02,0x40,0x02,0x4c,0x02,0x58,0x02,0x64,0x02,0x70,0x02,0x7c,0x02, - 0x88,0x02,0x94,0x02,0xa0,0x02,0xac,0x02,0xb8,0x02,0xc4,0x02,0xd0,0x02,0xdc,0x02,0xe8,0x02, - 0xf4,0x02,0x00,0x03,0x0c,0x03,0x18,0x03,0x24,0x03,0x30,0x03,0x3c,0x03,0x48,0x03,0x54,0x03, - 0x60,0x03,0x6c,0x03,0x78,0x03,0x84,0x03,0x90,0x03,0x9c,0x03,0xa8,0x03,0xb4,0x03,0xc0,0x03, - 0xcc,0x03,0xd8,0x03,0xe4,0x03,0xf0,0x03,0xfc,0x03,0x08,0x04,0x14,0x04,0x20,0x04,0x2c,0x04, - 0x38,0x04,0x44,0x04,0x50,0x04,0x5c,0x04,0x68,0x04,0x74,0x04, - - 7, // 0x20 ' ' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x21 '!' - 0x00,0x10,0x38,0x38,0x38,0x10,0x10,0x00,0x10,0x00,0x00, - - 7, // 0x22 '"' - 0x00,0x00,0x24,0x24,0x24,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x23 '#' - 0x00,0x48,0x48,0xfc,0x48,0x48,0xfc,0x48,0x48,0x00,0x00, - - 7, // 0x24 '$' - 0x00,0x10,0x38,0x54,0x50,0x38,0x14,0x54,0x38,0x10,0x00, - - 7, // 0x25 '%' - 0x00,0x00,0x42,0xa4,0x48,0x10,0x24,0x4a,0x84,0x00,0x00, - - 7, // 0x26 '&' - 0x00,0x30,0x48,0x48,0x30,0x60,0x94,0x98,0x6c,0x00,0x00, - - 7, // 0x27 ''' - 0x00,0x20,0x20,0x40,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x28 '(' - 0x00,0x04,0x08,0x10,0x10,0x10,0x10,0x08,0x04,0x00,0x00, - - 7, // 0x29 ')' - 0x00,0x40,0x20,0x10,0x10,0x10,0x10,0x20,0x40,0x00,0x00, - - 7, // 0x2a '*' - 0x00,0x00,0x00,0x20,0xa8,0x70,0xa8,0x20,0x00,0x00,0x00, - - 7, // 0x2b '+' - 0x00,0x00,0x00,0x10,0x10,0x7c,0x10,0x10,0x00,0x00,0x00, - - 7, // 0x2c ',' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x30,0x30,0x30,0x60, - - 7, // 0x2d '-' - 0x00,0x00,0x00,0x00,0x00,0xfc,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x2e '.' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x30,0x30,0x00,0x00, - - 7, // 0x2f '/' - 0x00,0x08,0x08,0x10,0x10,0x20,0x20,0x40,0x40,0x00,0x00, - - 7, // 0x30 '0' - 0x00,0x38,0x44,0x4c,0x54,0x64,0x44,0x44,0x38,0x00,0x00, - - 7, // 0x31 '1' - 0x00,0x10,0x30,0x10,0x10,0x10,0x10,0x10,0x7c,0x00,0x00, - - 7, // 0x32 '2' - 0x00,0x38,0x44,0x04,0x08,0x10,0x20,0x44,0x7c,0x00,0x00, - - 7, // 0x33 '3' - 0x00,0x7c,0x48,0x10,0x38,0x04,0x04,0x44,0x38,0x00,0x00, - - 7, // 0x34 '4' - 0x00,0x08,0x10,0x20,0x48,0x48,0x7c,0x08,0x1c,0x00,0x00, - - 7, // 0x35 '5' - 0x00,0x7c,0x40,0x40,0x78,0x04,0x04,0x44,0x38,0x00,0x00, - - 7, // 0x36 '6' - 0x00,0x18,0x20,0x40,0x78,0x44,0x44,0x44,0x38,0x00,0x00, - - 7, // 0x37 '7' - 0x00,0x7c,0x44,0x04,0x08,0x10,0x10,0x10,0x10,0x00,0x00, - - 7, // 0x38 '8' - 0x00,0x38,0x44,0x44,0x38,0x44,0x44,0x44,0x38,0x00,0x00, - - 7, // 0x39 '9' - 0x00,0x38,0x44,0x44,0x44,0x3c,0x04,0x08,0x30,0x00,0x00, - - 7, // 0x3a ':' - 0x00,0x00,0x00,0x30,0x00,0x00,0x00,0x30,0x00,0x00,0x00, - - 7, // 0x3b ';' - 0x00,0x00,0x00,0x30,0x00,0x00,0x00,0x30,0x30,0x60,0x00, - - 7, // 0x3c '<' - 0x00,0x00,0x04,0x08,0x10,0x20,0x10,0x08,0x04,0x00,0x00, - - 7, // 0x3d '=' - 0x00,0x00,0x00,0x00,0xfc,0x00,0xfc,0x00,0x00,0x00,0x00, - - 7, // 0x3e '>' - 0x00,0x00,0x40,0x20,0x10,0x08,0x10,0x20,0x40,0x00,0x00, - - 7, // 0x3f '?' - 0x00,0x70,0x88,0x88,0x10,0x20,0x20,0x00,0x20,0x00,0x00, - - 7, // 0x40 '@' - 0x00,0x30,0x48,0x04,0x34,0x54,0x54,0x54,0x28,0x00,0x00, - - 7, // 0x41 'A' - 0x00,0x10,0x28,0x44,0x44,0x7c,0x44,0x44,0x44,0x00,0x00, - - 7, // 0x42 'B' - 0x00,0x78,0x44,0x44,0x78,0x44,0x44,0x44,0x78,0x00,0x00, - - 7, // 0x43 'C' - 0x00,0x38,0x44,0x40,0x40,0x40,0x40,0x44,0x38,0x00,0x00, - - 7, // 0x44 'D' - 0x00,0x70,0x48,0x44,0x44,0x44,0x44,0x48,0x70,0x00,0x00, - - 7, // 0x45 'E' - 0x00,0x7c,0x40,0x40,0x70,0x40,0x40,0x40,0x7c,0x00,0x00, - - 7, // 0x46 'F' - 0x00,0x7c,0x40,0x40,0x70,0x40,0x40,0x40,0x40,0x00,0x00, - - 7, // 0x47 'G' - 0x00,0x38,0x44,0x40,0x40,0x5c,0x44,0x44,0x38,0x00,0x00, - - 7, // 0x48 'H' - 0x00,0x44,0x44,0x44,0x7c,0x44,0x44,0x44,0x44,0x00,0x00, - - 7, // 0x49 'I' - 0x00,0x38,0x10,0x10,0x10,0x10,0x10,0x10,0x38,0x00,0x00, - - 7, // 0x4a 'J' - 0x00,0x1c,0x08,0x08,0x08,0x08,0x08,0x48,0x30,0x00,0x00, - - 7, // 0x4b 'K' - 0x00,0x44,0x48,0x50,0x60,0x50,0x48,0x44,0x44,0x00,0x00, - - 7, // 0x4c 'L' - 0x00,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x7c,0x00,0x00, - - 7, // 0x4d 'M' - 0x00,0x44,0x6c,0x54,0x54,0x44,0x44,0x44,0x44,0x00,0x00, - - 7, // 0x4e 'N' - 0x00,0x44,0x44,0x64,0x54,0x4c,0x44,0x44,0x44,0x00,0x00, - - 7, // 0x4f 'O' - 0x00,0x38,0x44,0x44,0x44,0x44,0x44,0x44,0x38,0x00,0x00, - - 7, // 0x50 'P' - 0x00,0x78,0x44,0x44,0x44,0x78,0x40,0x40,0x40,0x00,0x00, - - 7, // 0x51 'Q' - 0x00,0x38,0x44,0x44,0x44,0x44,0x54,0x48,0x34,0x00,0x00, - - 7, // 0x52 'R' - 0x00,0x78,0x44,0x44,0x44,0x78,0x50,0x48,0x44,0x00,0x00, - - 7, // 0x53 'S' - 0x00,0x38,0x44,0x40,0x38,0x04,0x44,0x44,0x38,0x00,0x00, - - 7, // 0x54 'T' - 0x00,0x7c,0x54,0x10,0x10,0x10,0x10,0x10,0x10,0x00,0x00, - - 7, // 0x55 'U' - 0x00,0x44,0x44,0x44,0x44,0x44,0x44,0x44,0x38,0x00,0x00, - - 7, // 0x56 'V' - 0x00,0x44,0x44,0x44,0x44,0x28,0x28,0x10,0x10,0x00,0x00, - - 7, // 0x57 'W' - 0x00,0x44,0x44,0x44,0x44,0x54,0x54,0x6c,0x44,0x00,0x00, - - 7, // 0x58 'X' - 0x00,0x44,0x44,0x28,0x10,0x28,0x44,0x44,0x44,0x00,0x00, - - 7, // 0x59 'Y' - 0x00,0x44,0x44,0x44,0x28,0x10,0x10,0x10,0x38,0x00,0x00, - - 7, // 0x5a 'Z' - 0x00,0x7c,0x04,0x08,0x10,0x20,0x40,0x44,0x7c,0x00,0x00, - - 7, // 0x5b '[' - 0x00,0x38,0x20,0x20,0x20,0x20,0x20,0x20,0x38,0x00,0x00, - - 7, // 0x5c '\' - 0x00,0x40,0x40,0x20,0x20,0x10,0x10,0x08,0x08,0x00,0x00, - - 7, // 0x5d ']' - 0x00,0x38,0x08,0x08,0x08,0x08,0x08,0x08,0x38,0x00,0x00, - - 7, // 0x5e '^' - 0x00,0x10,0x28,0x44,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x5f '_' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfc,0x00,0x00, - - 7, // 0x60 '`' - 0x00,0x20,0x20,0x10,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x61 'a' - 0x00,0x00,0x00,0x38,0x04,0x3c,0x44,0x44,0x3c,0x00,0x00, - - 7, // 0x62 'b' - 0x00,0x40,0x40,0x78,0x44,0x44,0x44,0x44,0x78,0x00,0x00, - - 7, // 0x63 'c' - 0x00,0x00,0x00,0x38,0x44,0x40,0x40,0x44,0x38,0x00,0x00, - - 7, // 0x64 'd' - 0x00,0x04,0x04,0x3c,0x44,0x44,0x44,0x44,0x3c,0x00,0x00, - - 7, // 0x65 'e' - 0x00,0x00,0x00,0x38,0x44,0x7c,0x40,0x44,0x38,0x00,0x00, - - 7, // 0x66 'f' - 0x00,0x18,0x24,0x20,0x70,0x20,0x20,0x20,0x70,0x00,0x00, - - 7, // 0x67 'g' - 0x00,0x00,0x00,0x3c,0x44,0x44,0x44,0x3c,0x04,0x44,0x38, - - 7, // 0x68 'h' - 0x00,0x40,0x40,0x40,0x58,0x64,0x44,0x44,0x44,0x00,0x00, - - 7, // 0x69 'i' - 0x00,0x10,0x00,0x30,0x10,0x10,0x10,0x10,0x38,0x00,0x00, - - 7, // 0x6a 'j' - 0x00,0x08,0x00,0x18,0x08,0x08,0x08,0x08,0x48,0x30,0x00, - - 7, // 0x6b 'k' - 0x00,0x40,0x40,0x44,0x48,0x50,0x68,0x44,0x44,0x00,0x00, - - 7, // 0x6c 'l' - 0x00,0x30,0x10,0x10,0x10,0x10,0x10,0x10,0x38,0x00,0x00, - - 7, // 0x6d 'm' - 0x00,0x00,0x00,0xa8,0x54,0x54,0x54,0x54,0x54,0x00,0x00, - - 7, // 0x6e 'n' - 0x00,0x00,0x00,0xb8,0x44,0x44,0x44,0x44,0x44,0x00,0x00, - - 7, // 0x6f 'o' - 0x00,0x00,0x00,0x38,0x44,0x44,0x44,0x44,0x38,0x00,0x00, - - 7, // 0x70 'p' - 0x00,0x00,0x00,0x78,0x44,0x44,0x44,0x44,0x78,0x40,0x40, - - 7, // 0x71 'q' - 0x00,0x00,0x00,0x3c,0x44,0x44,0x44,0x44,0x3c,0x04,0x04, - - 7, // 0x72 'r' - 0x00,0x00,0x00,0x58,0x64,0x44,0x40,0x40,0x40,0x00,0x00, - - 7, // 0x73 's' - 0x00,0x00,0x00,0x3c,0x40,0x38,0x04,0x04,0x78,0x00,0x00, - - 7, // 0x74 't' - 0x00,0x20,0x20,0x70,0x20,0x20,0x20,0x24,0x18,0x00,0x00, - - 7, // 0x75 'u' - 0x00,0x00,0x00,0x44,0x44,0x44,0x44,0x44,0x3a,0x00,0x00, - - 7, // 0x76 'v' - 0x00,0x00,0x00,0x44,0x44,0x44,0x44,0x28,0x10,0x00,0x00, - - 7, // 0x77 'w' - 0x00,0x00,0x00,0x44,0x44,0x54,0x54,0x6c,0x44,0x00,0x00, - - 7, // 0x78 'x' - 0x00,0x00,0x00,0x44,0x28,0x10,0x28,0x44,0x44,0x00,0x00, - - 7, // 0x79 'y' - 0x00,0x00,0x00,0x44,0x44,0x44,0x3c,0x04,0x08,0x30,0x00, - - 7, // 0x7a 'z' - 0x00,0x00,0x00,0x7c,0x08,0x10,0x20,0x44,0x7c,0x00,0x00, - - 7, // 0x7b '{' - 0x00,0x0c,0x10,0x10,0x10,0x60,0x10,0x10,0x0c,0x00,0x00, - - 7, // 0x7c '|' - 0x00,0x20,0x20,0x20,0x00,0x20,0x20,0x20,0x20,0x00,0x00, - - 7, // 0x7d '}' - 0x00,0x60,0x10,0x10,0x10,0x0c,0x10,0x10,0x60,0x00,0x00, - - 7, // 0x7e '~' - 0x00,0x00,0x64,0x98,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x7f '' - 0x00,0x00,0x00,0x10,0x28,0x44,0x44,0x7c,0x00,0x00,0x00, - 0 - }; - - const int8u gse7x11_bold[] = - { - 11, 0, 32, 128-32, - - 0x00,0x00,0x0c,0x00,0x18,0x00,0x24,0x00,0x30,0x00,0x3c,0x00,0x48,0x00,0x54,0x00,0x60,0x00, - 0x6c,0x00,0x78,0x00,0x84,0x00,0x90,0x00,0x9c,0x00,0xa8,0x00,0xb4,0x00,0xc0,0x00,0xcc,0x00, - 0xd8,0x00,0xe4,0x00,0xf0,0x00,0xfc,0x00,0x08,0x01,0x14,0x01,0x20,0x01,0x2c,0x01,0x38,0x01, - 0x44,0x01,0x50,0x01,0x5c,0x01,0x68,0x01,0x74,0x01,0x80,0x01,0x8c,0x01,0x98,0x01,0xa4,0x01, - 0xb0,0x01,0xbc,0x01,0xc8,0x01,0xd4,0x01,0xe0,0x01,0xec,0x01,0xf8,0x01,0x04,0x02,0x10,0x02, - 0x1c,0x02,0x28,0x02,0x34,0x02,0x40,0x02,0x4c,0x02,0x58,0x02,0x64,0x02,0x70,0x02,0x7c,0x02, - 0x88,0x02,0x94,0x02,0xa0,0x02,0xac,0x02,0xb8,0x02,0xc4,0x02,0xd0,0x02,0xdc,0x02,0xe8,0x02, - 0xf4,0x02,0x00,0x03,0x0c,0x03,0x18,0x03,0x24,0x03,0x30,0x03,0x3c,0x03,0x48,0x03,0x54,0x03, - 0x60,0x03,0x6c,0x03,0x78,0x03,0x84,0x03,0x90,0x03,0x9c,0x03,0xa8,0x03,0xb4,0x03,0xc0,0x03, - 0xcc,0x03,0xd8,0x03,0xe4,0x03,0xf0,0x03,0xfc,0x03,0x08,0x04,0x14,0x04,0x20,0x04,0x2c,0x04, - 0x38,0x04,0x44,0x04,0x50,0x04,0x5c,0x04,0x68,0x04,0x74,0x04, - - 7, // 0x20 ' ' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x21 '!' - 0x00,0x30,0x30,0x30,0x30,0x30,0x00,0x30,0x30,0x00,0x00, - - 7, // 0x22 '"' - 0x00,0x6c,0x6c,0x28,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x23 '#' - 0x00,0x48,0x48,0xfc,0x48,0x48,0xfc,0x48,0x48,0x00,0x00, - - 7, // 0x24 '$' - 0x30,0x30,0x78,0xcc,0xc0,0x78,0x0c,0xcc,0x78,0x30,0x30, - - 7, // 0x25 '%' - 0x00,0x00,0xc4,0x0c,0x18,0x30,0x60,0xc0,0x8c,0x00,0x00, - - 7, // 0x26 '&' - 0x00,0x30,0x58,0x58,0x30,0x74,0xdc,0xd8,0x6c,0x00,0x00, - - 7, // 0x27 ''' - 0x00,0x30,0x30,0x60,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x28 '(' - 0x00,0x0c,0x18,0x30,0x30,0x30,0x30,0x18,0x0c,0x00,0x00, - - 7, // 0x29 ')' - 0x00,0xc0,0x60,0x30,0x30,0x30,0x30,0x60,0xc0,0x00,0x00, - - 7, // 0x2a '*' - 0x00,0x00,0x00,0x20,0xa8,0x70,0xa8,0x20,0x00,0x00,0x00, - - 7, // 0x2b '+' - 0x00,0x00,0x00,0x30,0x30,0xfc,0x30,0x30,0x00,0x00,0x00, - - 7, // 0x2c ',' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x30,0x30,0x60,0x00, - - 7, // 0x2d '-' - 0x00,0x00,0x00,0x00,0x00,0xfc,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x2e '.' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x30,0x30,0x00,0x00, - - 7, // 0x2f '/' - 0x00,0x0c,0x0c,0x18,0x18,0x30,0x30,0x60,0x60,0x00,0x00, - - 7, // 0x30 '0' - 0x00,0x78,0xcc,0xcc,0xdc,0xec,0xcc,0xcc,0x78,0x00,0x00, - - 7, // 0x31 '1' - 0x00,0x30,0x70,0xf0,0x30,0x30,0x30,0x30,0xfc,0x00,0x00, - - 7, // 0x32 '2' - 0x00,0x78,0xcc,0xcc,0x18,0x30,0x60,0xcc,0xfc,0x00,0x00, - - 7, // 0x33 '3' - 0x00,0xfc,0x98,0x30,0x78,0x0c,0x0c,0xcc,0x78,0x00,0x00, - - 7, // 0x34 '4' - 0x00,0x18,0x30,0x68,0xd8,0xd8,0xfc,0x18,0x3c,0x00,0x00, - - 7, // 0x35 '5' - 0x00,0xfc,0xc0,0xc0,0xf8,0x0c,0x0c,0xcc,0x78,0x00,0x00, - - 7, // 0x36 '6' - 0x00,0x38,0x60,0xc0,0xf8,0xcc,0xcc,0xcc,0x78,0x00,0x00, - - 7, // 0x37 '7' - 0x00,0xfc,0x8c,0x0c,0x18,0x30,0x30,0x30,0x30,0x00,0x00, - - 7, // 0x38 '8' - 0x00,0x78,0xcc,0xcc,0x78,0xcc,0xcc,0xcc,0x78,0x00,0x00, - - 7, // 0x39 '9' - 0x00,0x78,0xcc,0xcc,0xcc,0x7c,0x0c,0x18,0x70,0x00,0x00, - - 7, // 0x3a ':' - 0x00,0x00,0x30,0x30,0x00,0x00,0x30,0x30,0x00,0x00,0x00, - - 7, // 0x3b ';' - 0x00,0x00,0x30,0x30,0x00,0x00,0x30,0x30,0x30,0x60,0x00, - - 7, // 0x3c '<' - 0x00,0x00,0x0c,0x18,0x30,0x60,0x30,0x18,0x0c,0x00,0x00, - - 7, // 0x3d '=' - 0x00,0x00,0x00,0x00,0xfc,0x00,0xfc,0x00,0x00,0x00,0x00, - - 7, // 0x3e '>' - 0x00,0x00,0x60,0x30,0x18,0x0c,0x18,0x30,0x60,0x00,0x00, - - 7, // 0x3f '?' - 0x00,0x78,0xcc,0xcc,0x18,0x30,0x30,0x00,0x30,0x00,0x00, - - 7, // 0x40 '@' - 0x00,0x70,0x88,0x04,0x74,0xb4,0xb4,0xb4,0x68,0x00,0x00, - - 7, // 0x41 'A' - 0x00,0x30,0x78,0xcc,0xcc,0xfc,0xcc,0xcc,0xcc,0x00,0x00, - - 7, // 0x42 'B' - 0x00,0xf8,0xcc,0xcc,0xf8,0xcc,0xcc,0xcc,0xf8,0x00,0x00, - - 7, // 0x43 'C' - 0x00,0x78,0xcc,0xc0,0xc0,0xc0,0xc0,0xcc,0x78,0x00,0x00, - - 7, // 0x44 'D' - 0x00,0xf0,0xd8,0xcc,0xcc,0xcc,0xcc,0xd8,0xf0,0x00,0x00, - - 7, // 0x45 'E' - 0x00,0xfc,0xc4,0xd0,0xf0,0xd0,0xc0,0xc4,0xfc,0x00,0x00, - - 7, // 0x46 'F' - 0x00,0xfc,0xc4,0xd0,0xf0,0xd0,0xc0,0xc0,0xc0,0x00,0x00, - - 7, // 0x47 'G' - 0x00,0x78,0xcc,0xc0,0xc0,0xdc,0xcc,0xcc,0x78,0x00,0x00, - - 7, // 0x48 'H' - 0x00,0xcc,0xcc,0xcc,0xfc,0xcc,0xcc,0xcc,0xcc,0x00,0x00, - - 7, // 0x49 'I' - 0x00,0x78,0x30,0x30,0x30,0x30,0x30,0x30,0x78,0x00,0x00, - - 7, // 0x4a 'J' - 0x00,0x3c,0x18,0x18,0x18,0x18,0xd8,0xd8,0x70,0x00,0x00, - - 7, // 0x4b 'K' - 0x00,0xcc,0xcc,0xd8,0xf0,0xd8,0xcc,0xcc,0xcc,0x00,0x00, - - 7, // 0x4c 'L' - 0x00,0xc0,0xc0,0xc0,0xc0,0xc0,0xc0,0xc4,0xfc,0x00,0x00, - - 7, // 0x4d 'M' - 0x00,0x84,0xcc,0xfc,0xb4,0xcc,0xcc,0xcc,0xcc,0x00,0x00, - - 7, // 0x4e 'N' - 0x00,0xcc,0xcc,0xec,0xfc,0xdc,0xcc,0xcc,0xcc,0x00,0x00, - - 7, // 0x4f 'O' - 0x00,0x78,0xcc,0xcc,0xcc,0xcc,0xcc,0xcc,0x78,0x00,0x00, - - 7, // 0x50 'P' - 0x00,0xf8,0xcc,0xcc,0xcc,0xf8,0xc0,0xc0,0xc0,0x00,0x00, - - 7, // 0x51 'Q' - 0x00,0x78,0xcc,0xcc,0xcc,0xcc,0xdc,0x78,0x18,0x0c,0x00, - - 7, // 0x52 'R' - 0x00,0xf8,0xcc,0xcc,0xcc,0xf8,0xd8,0xcc,0xcc,0x00,0x00, - - 7, // 0x53 'S' - 0x00,0x78,0xcc,0xe0,0x70,0x38,0x1c,0xcc,0x78,0x00,0x00, - - 7, // 0x54 'T' - 0x00,0xfc,0xb4,0x30,0x30,0x30,0x30,0x30,0x30,0x00,0x00, - - 7, // 0x55 'U' - 0x00,0xcc,0xcc,0xcc,0xcc,0xcc,0xcc,0xcc,0x78,0x00,0x00, - - 7, // 0x56 'V' - 0x00,0xcc,0xcc,0xcc,0xcc,0xcc,0xcc,0x78,0x30,0x00,0x00, - - 7, // 0x57 'W' - 0x00,0xcc,0xcc,0xcc,0xcc,0xb4,0xfc,0xcc,0x84,0x00,0x00, - - 7, // 0x58 'X' - 0x00,0xcc,0xcc,0x78,0x30,0x78,0xcc,0xcc,0xcc,0x00,0x00, - - 7, // 0x59 'Y' - 0x00,0xcc,0xcc,0xcc,0x78,0x30,0x30,0x30,0x78,0x00,0x00, - - 7, // 0x5a 'Z' - 0x00,0xfc,0x8c,0x18,0x30,0x60,0xc0,0xc4,0xfc,0x00,0x00, - - 7, // 0x5b '[' - 0x00,0x78,0x60,0x60,0x60,0x60,0x60,0x60,0x78,0x00,0x00, - - 7, // 0x5c '\' - 0x00,0x60,0x60,0x30,0x30,0x18,0x18,0x0c,0x0c,0x00,0x00, - - 7, // 0x5d ']' - 0x00,0x78,0x18,0x18,0x18,0x18,0x18,0x18,0x78,0x00,0x00, - - 7, // 0x5e '^' - 0x00,0x10,0x38,0x6c,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x5f '_' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfc,0x00,0x00, - - 7, // 0x60 '`' - 0x00,0x30,0x30,0x18,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x61 'a' - 0x00,0x00,0x00,0x70,0x18,0x78,0xd8,0xd8,0x6c,0x00,0x00, - - 7, // 0x62 'b' - 0x00,0x60,0x60,0x60,0x78,0x6c,0x6c,0x6c,0x78,0x00,0x00, - - 7, // 0x63 'c' - 0x00,0x00,0x00,0x78,0xcc,0xc0,0xc0,0xcc,0x78,0x00,0x00, - - 7, // 0x64 'd' - 0x00,0x18,0x18,0x18,0x78,0xd8,0xd8,0xd8,0x6c,0x00,0x00, - - 7, // 0x65 'e' - 0x00,0x00,0x00,0x78,0xcc,0xfc,0xc0,0xcc,0x78,0x00,0x00, - - 7, // 0x66 'f' - 0x00,0x18,0x34,0x30,0x78,0x30,0x30,0x30,0x78,0x00,0x00, - - 7, // 0x67 'g' - 0x00,0x00,0x00,0x6c,0xd8,0xd8,0xd8,0x78,0x18,0xd8,0x70, - - 7, // 0x68 'h' - 0x00,0xc0,0xc0,0xd8,0xec,0xcc,0xcc,0xcc,0xcc,0x00,0x00, - - 7, // 0x69 'i' - 0x00,0x30,0x00,0x70,0x30,0x30,0x30,0x30,0x78,0x00,0x00, - - 7, // 0x6a 'j' - 0x00,0x0c,0x00,0x1c,0x0c,0x0c,0x0c,0x0c,0x6c,0x6c,0x38, - - 7, // 0x6b 'k' - 0x00,0xc0,0xc0,0xcc,0xcc,0xd8,0xf0,0xd8,0xcc,0x00,0x00, - - 7, // 0x6c 'l' - 0x00,0x70,0x30,0x30,0x30,0x30,0x30,0x30,0x78,0x00,0x00, - - 7, // 0x6d 'm' - 0x00,0x00,0x00,0xe8,0xfc,0xd4,0xd4,0xc4,0xc4,0x00,0x00, - - 7, // 0x6e 'n' - 0x00,0x00,0x00,0xd8,0x6c,0x6c,0x6c,0x6c,0x6c,0x00,0x00, - - 7, // 0x6f 'o' - 0x00,0x00,0x00,0x78,0xcc,0xcc,0xcc,0xcc,0x78,0x00,0x00, - - 7, // 0x70 'p' - 0x00,0x00,0x00,0xf8,0xcc,0xcc,0xcc,0xf8,0xc0,0xc0,0xc0, - - 7, // 0x71 'q' - 0x00,0x00,0x00,0x7c,0xcc,0xcc,0xcc,0x7c,0x0c,0x0c,0x0c, - - 7, // 0x72 'r' - 0x00,0x00,0x00,0xd8,0xec,0xcc,0xc0,0xc0,0xc0,0x00,0x00, - - 7, // 0x73 's' - 0x00,0x00,0x00,0x78,0xcc,0x60,0x18,0xcc,0x78,0x00,0x00, - - 7, // 0x74 't' - 0x00,0x20,0x60,0x60,0xf0,0x60,0x60,0x68,0x30,0x00,0x00, - - 7, // 0x75 'u' - 0x00,0x00,0x00,0xd8,0xd8,0xd8,0xd8,0xd8,0x6c,0x00,0x00, - - 7, // 0x76 'v' - 0x00,0x00,0x00,0xcc,0xcc,0xcc,0xcc,0x78,0x30,0x00,0x00, - - 7, // 0x77 'w' - 0x00,0x00,0x00,0xcc,0xcc,0xb4,0xfc,0xcc,0x84,0x00,0x00, - - 7, // 0x78 'x' - 0x00,0x00,0x00,0xcc,0x78,0x30,0x78,0xcc,0xcc,0x00,0x00, - - 7, // 0x79 'y' - 0x00,0x00,0x00,0xcc,0xcc,0xcc,0xcc,0x7c,0x0c,0x18,0xf0, - - 7, // 0x7a 'z' - 0x00,0x00,0x00,0xfc,0x98,0x30,0x60,0xc4,0xfc,0x00,0x00, - - 7, // 0x7b '{' - 0x1c,0x30,0x30,0x30,0xe0,0x30,0x30,0x30,0x1c,0x00,0x00, - - 7, // 0x7c '|' - 0x30,0x30,0x30,0x30,0x00,0x30,0x30,0x30,0x30,0x00,0x00, - - 7, // 0x7d '}' - 0xe0,0x30,0x30,0x30,0x1c,0x30,0x30,0x30,0xe0,0x00,0x00, - - 7, // 0x7e '~' - 0x00,0x34,0x58,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x7f '' - 0x00,0x00,0x00,0x30,0x78,0xcc,0xcc,0xfc,0x00,0x00,0x00, - 0 - }; - - const int8u gse7x15[] = - { - 15, 0, 32, 128-32, - - 0x00,0x00,0x10,0x00,0x20,0x00,0x30,0x00,0x40,0x00,0x50,0x00,0x60,0x00,0x70,0x00,0x80,0x00, - 0x90,0x00,0xa0,0x00,0xb0,0x00,0xc0,0x00,0xd0,0x00,0xe0,0x00,0xf0,0x00,0x00,0x01,0x10,0x01, - 0x20,0x01,0x30,0x01,0x40,0x01,0x50,0x01,0x60,0x01,0x70,0x01,0x80,0x01,0x90,0x01,0xa0,0x01, - 0xb0,0x01,0xc0,0x01,0xd0,0x01,0xe0,0x01,0xf0,0x01,0x00,0x02,0x10,0x02,0x20,0x02,0x30,0x02, - 0x40,0x02,0x50,0x02,0x60,0x02,0x70,0x02,0x80,0x02,0x90,0x02,0xa0,0x02,0xb0,0x02,0xc0,0x02, - 0xd0,0x02,0xe0,0x02,0xf0,0x02,0x00,0x03,0x10,0x03,0x20,0x03,0x30,0x03,0x40,0x03,0x50,0x03, - 0x60,0x03,0x70,0x03,0x80,0x03,0x90,0x03,0xa0,0x03,0xb0,0x03,0xc0,0x03,0xd0,0x03,0xe0,0x03, - 0xf0,0x03,0x00,0x04,0x10,0x04,0x20,0x04,0x30,0x04,0x40,0x04,0x50,0x04,0x60,0x04,0x70,0x04, - 0x80,0x04,0x90,0x04,0xa0,0x04,0xb0,0x04,0xc0,0x04,0xd0,0x04,0xe0,0x04,0xf0,0x04,0x00,0x05, - 0x10,0x05,0x20,0x05,0x30,0x05,0x40,0x05,0x50,0x05,0x60,0x05,0x70,0x05,0x80,0x05,0x90,0x05, - 0xa0,0x05,0xb0,0x05,0xc0,0x05,0xd0,0x05,0xe0,0x05,0xf0,0x05, - - 7, // 0x20 ' ' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x21 '!' - 0x00,0x00,0x10,0x38,0x38,0x38,0x38,0x10,0x10,0x00,0x10,0x10,0x00,0x00,0x00, - - 7, // 0x22 '"' - 0x00,0x00,0x24,0x24,0x24,0x24,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x23 '#' - 0x00,0x00,0x48,0x48,0x48,0xfc,0x48,0x48,0xfc,0x48,0x48,0x48,0x00,0x00,0x00, - - 7, // 0x24 '$' - 0x00,0x00,0x10,0x38,0x54,0x50,0x38,0x14,0x54,0x54,0x38,0x10,0x00,0x00,0x00, - - 7, // 0x25 '%' - 0x00,0x00,0x44,0x44,0x08,0x08,0x10,0x10,0x20,0x20,0x44,0x44,0x00,0x00,0x00, - - 7, // 0x26 '&' - 0x00,0x00,0x00,0x30,0x48,0x48,0x30,0x60,0x94,0x98,0x90,0x6c,0x00,0x00,0x00, - - 7, // 0x27 ''' - 0x00,0x00,0x20,0x20,0x20,0x40,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x28 '(' - 0x00,0x04,0x08,0x10,0x20,0x20,0x20,0x20,0x20,0x10,0x08,0x04,0x00,0x00,0x00, - - 7, // 0x29 ')' - 0x00,0x40,0x20,0x10,0x08,0x08,0x08,0x08,0x08,0x10,0x20,0x40,0x00,0x00,0x00, - - 7, // 0x2a '*' - 0x00,0x00,0x00,0x00,0x00,0x20,0xa8,0x70,0xa8,0x20,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x2b '+' - 0x00,0x00,0x00,0x00,0x10,0x10,0x10,0x7c,0x10,0x10,0x10,0x00,0x00,0x00,0x00, - - 7, // 0x2c ',' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x30,0x30,0x30,0x60,0x00, - - 7, // 0x2d '-' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfc,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x2e '.' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x30,0x30,0x00,0x00,0x00, - - 7, // 0x2f '/' - 0x00,0x00,0x04,0x04,0x08,0x08,0x10,0x10,0x20,0x20,0x40,0x40,0x00,0x00,0x00, - - 7, // 0x30 '0' - 0x00,0x00,0x38,0x44,0x44,0x4c,0x54,0x64,0x44,0x44,0x44,0x38,0x00,0x00,0x00, - - 7, // 0x31 '1' - 0x00,0x00,0x10,0x10,0x30,0x10,0x10,0x10,0x10,0x10,0x10,0x7c,0x00,0x00,0x00, - - 7, // 0x32 '2' - 0x00,0x00,0x38,0x44,0x44,0x04,0x08,0x10,0x20,0x40,0x44,0x7c,0x00,0x00,0x00, - - 7, // 0x33 '3' - 0x00,0x00,0x7c,0x44,0x08,0x10,0x38,0x04,0x04,0x04,0x44,0x38,0x00,0x00,0x00, - - 7, // 0x34 '4' - 0x00,0x00,0x08,0x10,0x20,0x40,0x48,0x48,0x7c,0x08,0x08,0x1c,0x00,0x00,0x00, - - 7, // 0x35 '5' - 0x00,0x00,0x7c,0x40,0x40,0x40,0x78,0x04,0x04,0x04,0x44,0x38,0x00,0x00,0x00, - - 7, // 0x36 '6' - 0x00,0x00,0x18,0x20,0x40,0x40,0x78,0x44,0x44,0x44,0x44,0x38,0x00,0x00,0x00, - - 7, // 0x37 '7' - 0x00,0x00,0x7c,0x44,0x04,0x04,0x08,0x08,0x10,0x10,0x10,0x10,0x00,0x00,0x00, - - 7, // 0x38 '8' - 0x00,0x00,0x38,0x44,0x44,0x44,0x38,0x44,0x44,0x44,0x44,0x38,0x00,0x00,0x00, - - 7, // 0x39 '9' - 0x00,0x00,0x38,0x44,0x44,0x44,0x44,0x3c,0x04,0x04,0x08,0x30,0x00,0x00,0x00, - - 7, // 0x3a ':' - 0x00,0x00,0x00,0x00,0x00,0x30,0x00,0x00,0x00,0x00,0x30,0x00,0x00,0x00,0x00, - - 7, // 0x3b ';' - 0x00,0x00,0x00,0x00,0x00,0x30,0x00,0x00,0x00,0x00,0x30,0x30,0x60,0x00,0x00, - - 7, // 0x3c '<' - 0x00,0x00,0x00,0x04,0x08,0x10,0x20,0x40,0x20,0x10,0x08,0x04,0x00,0x00,0x00, - - 7, // 0x3d '=' - 0x00,0x00,0x00,0x00,0x00,0xfc,0x00,0xfc,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x3e '>' - 0x00,0x00,0x00,0x40,0x20,0x10,0x08,0x04,0x08,0x10,0x20,0x40,0x00,0x00,0x00, - - 7, // 0x3f '?' - 0x00,0x00,0x78,0x84,0x84,0x84,0x08,0x10,0x20,0x20,0x00,0x20,0x00,0x00,0x00, - - 7, // 0x40 '@' - 0x00,0x00,0x00,0x30,0x48,0x04,0x34,0x54,0x54,0x54,0x54,0x28,0x00,0x00,0x00, - - 7, // 0x41 'A' - 0x00,0x00,0x10,0x28,0x44,0x44,0x44,0x7c,0x44,0x44,0x44,0x44,0x00,0x00,0x00, - - 7, // 0x42 'B' - 0x00,0x00,0x78,0x44,0x44,0x44,0x78,0x44,0x44,0x44,0x44,0x78,0x00,0x00,0x00, - - 7, // 0x43 'C' - 0x00,0x00,0x38,0x44,0x44,0x40,0x40,0x40,0x40,0x44,0x44,0x38,0x00,0x00,0x00, - - 7, // 0x44 'D' - 0x00,0x00,0x70,0x48,0x44,0x44,0x44,0x44,0x44,0x44,0x48,0x70,0x00,0x00,0x00, - - 7, // 0x45 'E' - 0x00,0x00,0x7c,0x40,0x40,0x40,0x70,0x40,0x40,0x40,0x40,0x7c,0x00,0x00,0x00, - - 7, // 0x46 'F' - 0x00,0x00,0x7c,0x40,0x40,0x40,0x70,0x40,0x40,0x40,0x40,0x40,0x00,0x00,0x00, - - 7, // 0x47 'G' - 0x00,0x00,0x38,0x44,0x40,0x40,0x40,0x5c,0x44,0x44,0x44,0x38,0x00,0x00,0x00, - - 7, // 0x48 'H' - 0x00,0x00,0x44,0x44,0x44,0x44,0x7c,0x44,0x44,0x44,0x44,0x44,0x00,0x00,0x00, - - 7, // 0x49 'I' - 0x00,0x00,0x38,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x38,0x00,0x00,0x00, - - 7, // 0x4a 'J' - 0x00,0x00,0x1c,0x08,0x08,0x08,0x08,0x08,0x08,0x48,0x48,0x30,0x00,0x00,0x00, - - 7, // 0x4b 'K' - 0x00,0x00,0x44,0x44,0x48,0x50,0x60,0x50,0x48,0x44,0x44,0x44,0x00,0x00,0x00, - - 7, // 0x4c 'L' - 0x00,0x00,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x7c,0x00,0x00,0x00, - - 7, // 0x4d 'M' - 0x00,0x00,0x44,0x6c,0x54,0x54,0x44,0x44,0x44,0x44,0x44,0x44,0x00,0x00,0x00, - - 7, // 0x4e 'N' - 0x00,0x00,0x44,0x44,0x44,0x64,0x54,0x4c,0x44,0x44,0x44,0x44,0x00,0x00,0x00, - - 7, // 0x4f 'O' - 0x00,0x00,0x38,0x44,0x44,0x44,0x44,0x44,0x44,0x44,0x44,0x38,0x00,0x00,0x00, - - 7, // 0x50 'P' - 0x00,0x00,0x78,0x44,0x44,0x44,0x44,0x78,0x40,0x40,0x40,0x40,0x00,0x00,0x00, - - 7, // 0x51 'Q' - 0x00,0x00,0x38,0x44,0x44,0x44,0x44,0x44,0x44,0x54,0x48,0x34,0x00,0x00,0x00, - - 7, // 0x52 'R' - 0x00,0x00,0x78,0x44,0x44,0x44,0x44,0x78,0x50,0x48,0x44,0x44,0x00,0x00,0x00, - - 7, // 0x53 'S' - 0x00,0x00,0x38,0x44,0x44,0x40,0x38,0x04,0x04,0x44,0x44,0x38,0x00,0x00,0x00, - - 7, // 0x54 'T' - 0x00,0x00,0x7c,0x54,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x00,0x00,0x00, - - 7, // 0x55 'U' - 0x00,0x00,0x44,0x44,0x44,0x44,0x44,0x44,0x44,0x44,0x44,0x38,0x00,0x00,0x00, - - 7, // 0x56 'V' - 0x00,0x00,0x44,0x44,0x44,0x44,0x44,0x44,0x28,0x28,0x10,0x10,0x00,0x00,0x00, - - 7, // 0x57 'W' - 0x00,0x00,0x44,0x44,0x44,0x44,0x44,0x44,0x54,0x54,0x6c,0x44,0x00,0x00,0x00, - - 7, // 0x58 'X' - 0x00,0x00,0x44,0x44,0x44,0x28,0x10,0x28,0x44,0x44,0x44,0x44,0x00,0x00,0x00, - - 7, // 0x59 'Y' - 0x00,0x00,0x44,0x44,0x44,0x44,0x28,0x10,0x10,0x10,0x10,0x38,0x00,0x00,0x00, - - 7, // 0x5a 'Z' - 0x00,0x00,0x7c,0x04,0x04,0x08,0x10,0x20,0x40,0x40,0x40,0x7c,0x00,0x00,0x00, - - 7, // 0x5b '[' - 0x00,0x38,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x38,0x00,0x00, - - 7, // 0x5c '\' - 0x00,0x00,0x40,0x40,0x20,0x20,0x10,0x10,0x08,0x08,0x04,0x04,0x00,0x00,0x00, - - 7, // 0x5d ']' - 0x00,0x38,0x08,0x08,0x08,0x08,0x08,0x08,0x08,0x08,0x08,0x08,0x38,0x00,0x00, - - 7, // 0x5e '^' - 0x00,0x10,0x28,0x44,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x5f '_' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfc,0x00,0x00,0x00, - - 7, // 0x60 '`' - 0x00,0x20,0x20,0x20,0x10,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x61 'a' - 0x00,0x00,0x00,0x00,0x38,0x44,0x04,0x3c,0x44,0x44,0x44,0x3a,0x00,0x00,0x00, - - 7, // 0x62 'b' - 0x00,0x00,0x40,0x40,0x40,0x78,0x44,0x44,0x44,0x44,0x44,0x78,0x00,0x00,0x00, - - 7, // 0x63 'c' - 0x00,0x00,0x00,0x00,0x38,0x44,0x40,0x40,0x40,0x40,0x44,0x38,0x00,0x00,0x00, - - 7, // 0x64 'd' - 0x00,0x00,0x04,0x04,0x04,0x3c,0x44,0x44,0x44,0x44,0x44,0x3a,0x00,0x00,0x00, - - 7, // 0x65 'e' - 0x00,0x00,0x00,0x00,0x38,0x44,0x44,0x7c,0x40,0x40,0x44,0x38,0x00,0x00,0x00, - - 7, // 0x66 'f' - 0x00,0x00,0x18,0x24,0x20,0x70,0x20,0x20,0x20,0x20,0x20,0x70,0x00,0x00,0x00, - - 7, // 0x67 'g' - 0x00,0x00,0x00,0x00,0x3a,0x44,0x44,0x44,0x44,0x44,0x3c,0x04,0x44,0x38,0x00, - - 7, // 0x68 'h' - 0x00,0x00,0x40,0x40,0x40,0x58,0x64,0x44,0x44,0x44,0x44,0x44,0x00,0x00,0x00, - - 7, // 0x69 'i' - 0x00,0x00,0x10,0x10,0x00,0x30,0x10,0x10,0x10,0x10,0x10,0x38,0x00,0x00,0x00, - - 7, // 0x6a 'j' - 0x00,0x00,0x08,0x08,0x00,0x18,0x08,0x08,0x08,0x08,0x08,0x48,0x48,0x30,0x00, - - 7, // 0x6b 'k' - 0x00,0x00,0x40,0x40,0x44,0x44,0x48,0x50,0x60,0x50,0x48,0x44,0x00,0x00,0x00, - - 7, // 0x6c 'l' - 0x00,0x00,0x30,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x38,0x00,0x00,0x00, - - 7, // 0x6d 'm' - 0x00,0x00,0x00,0x00,0xa8,0x54,0x54,0x54,0x54,0x54,0x54,0x54,0x00,0x00,0x00, - - 7, // 0x6e 'n' - 0x00,0x00,0x00,0x00,0xb8,0x44,0x44,0x44,0x44,0x44,0x44,0x44,0x00,0x00,0x00, - - 7, // 0x6f 'o' - 0x00,0x00,0x00,0x00,0x38,0x44,0x44,0x44,0x44,0x44,0x44,0x38,0x00,0x00,0x00, - - 7, // 0x70 'p' - 0x00,0x00,0x00,0x00,0x78,0x44,0x44,0x44,0x44,0x44,0x78,0x40,0x40,0x40,0x00, - - 7, // 0x71 'q' - 0x00,0x00,0x00,0x00,0x3c,0x44,0x44,0x44,0x44,0x44,0x3c,0x04,0x04,0x04,0x00, - - 7, // 0x72 'r' - 0x00,0x00,0x00,0x00,0x58,0x64,0x44,0x40,0x40,0x40,0x40,0x40,0x00,0x00,0x00, - - 7, // 0x73 's' - 0x00,0x00,0x00,0x00,0x38,0x44,0x40,0x38,0x04,0x44,0x44,0x38,0x00,0x00,0x00, - - 7, // 0x74 't' - 0x00,0x00,0x20,0x20,0x20,0x70,0x20,0x20,0x20,0x20,0x24,0x18,0x00,0x00,0x00, - - 7, // 0x75 'u' - 0x00,0x00,0x00,0x00,0x44,0x44,0x44,0x44,0x44,0x44,0x44,0x3a,0x00,0x00,0x00, - - 7, // 0x76 'v' - 0x00,0x00,0x00,0x00,0x44,0x44,0x44,0x44,0x28,0x28,0x10,0x10,0x00,0x00,0x00, - - 7, // 0x77 'w' - 0x00,0x00,0x00,0x00,0x44,0x44,0x44,0x44,0x54,0x54,0x6c,0x44,0x00,0x00,0x00, - - 7, // 0x78 'x' - 0x00,0x00,0x00,0x00,0x44,0x44,0x28,0x10,0x28,0x44,0x44,0x44,0x00,0x00,0x00, - - 7, // 0x79 'y' - 0x00,0x00,0x00,0x00,0x44,0x44,0x44,0x44,0x44,0x44,0x3c,0x04,0x08,0x70,0x00, - - 7, // 0x7a 'z' - 0x00,0x00,0x00,0x00,0x7c,0x04,0x08,0x10,0x20,0x40,0x40,0x7c,0x00,0x00,0x00, - - 7, // 0x7b '{' - 0x00,0x0c,0x10,0x10,0x10,0x10,0x10,0x60,0x10,0x10,0x10,0x10,0x0c,0x00,0x00, - - 7, // 0x7c '|' - 0x00,0x20,0x20,0x20,0x20,0x20,0x00,0x00,0x20,0x20,0x20,0x20,0x20,0x00,0x00, - - 7, // 0x7d '}' - 0x00,0x60,0x10,0x10,0x10,0x10,0x10,0x0c,0x10,0x10,0x10,0x10,0x60,0x00,0x00, - - 7, // 0x7e '~' - 0x00,0x00,0x64,0x98,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x7f '' - 0x00,0x00,0x00,0x00,0x00,0x10,0x28,0x44,0x44,0x7c,0x00,0x00,0x00,0x00,0x00, - 0 - }; - - const int8u gse7x15_bold[] = - { - 15, 0, 32, 128-32, - - 0x00,0x00,0x10,0x00,0x20,0x00,0x30,0x00,0x40,0x00,0x50,0x00,0x60,0x00,0x70,0x00,0x80,0x00, - 0x90,0x00,0xa0,0x00,0xb0,0x00,0xc0,0x00,0xd0,0x00,0xe0,0x00,0xf0,0x00,0x00,0x01,0x10,0x01, - 0x20,0x01,0x30,0x01,0x40,0x01,0x50,0x01,0x60,0x01,0x70,0x01,0x80,0x01,0x90,0x01,0xa0,0x01, - 0xb0,0x01,0xc0,0x01,0xd0,0x01,0xe0,0x01,0xf0,0x01,0x00,0x02,0x10,0x02,0x20,0x02,0x30,0x02, - 0x40,0x02,0x50,0x02,0x60,0x02,0x70,0x02,0x80,0x02,0x90,0x02,0xa0,0x02,0xb0,0x02,0xc0,0x02, - 0xd0,0x02,0xe0,0x02,0xf0,0x02,0x00,0x03,0x10,0x03,0x20,0x03,0x30,0x03,0x40,0x03,0x50,0x03, - 0x60,0x03,0x70,0x03,0x80,0x03,0x90,0x03,0xa0,0x03,0xb0,0x03,0xc0,0x03,0xd0,0x03,0xe0,0x03, - 0xf0,0x03,0x00,0x04,0x10,0x04,0x20,0x04,0x30,0x04,0x40,0x04,0x50,0x04,0x60,0x04,0x70,0x04, - 0x80,0x04,0x90,0x04,0xa0,0x04,0xb0,0x04,0xc0,0x04,0xd0,0x04,0xe0,0x04,0xf0,0x04,0x00,0x05, - 0x10,0x05,0x20,0x05,0x30,0x05,0x40,0x05,0x50,0x05,0x60,0x05,0x70,0x05,0x80,0x05,0x90,0x05, - 0xa0,0x05,0xb0,0x05,0xc0,0x05,0xd0,0x05,0xe0,0x05,0xf0,0x05, - - 7, // 0x20 ' ' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x21 '!' - 0x00,0x00,0x00,0x30,0x78,0x78,0x78,0x30,0x30,0x00,0x30,0x30,0x00,0x00,0x00, - - 7, // 0x22 '"' - 0x00,0x00,0x6c,0x6c,0x6c,0x28,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x23 '#' - 0x00,0x00,0x48,0x48,0x48,0xfc,0x48,0x48,0xfc,0x48,0x48,0x48,0x00,0x00,0x00, - - 7, // 0x24 '$' - 0x00,0x30,0x30,0x78,0xcc,0xe0,0x70,0x38,0x1c,0xcc,0x78,0x30,0x30,0x00,0x00, - - 7, // 0x25 '%' - 0x00,0x00,0x00,0x64,0x6c,0x08,0x18,0x10,0x30,0x20,0x6c,0x4c,0x00,0x00,0x00, - - 7, // 0x26 '&' - 0x00,0x00,0x00,0x30,0x58,0x58,0x30,0x74,0xdc,0xd8,0xd8,0x6c,0x00,0x00,0x00, - - 7, // 0x27 ''' - 0x00,0x00,0x30,0x30,0x30,0x60,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x28 '(' - 0x00,0x0c,0x18,0x30,0x60,0x60,0x60,0x60,0x60,0x30,0x18,0x0c,0x00,0x00,0x00, - - 7, // 0x29 ')' - 0x00,0xc0,0x60,0x30,0x18,0x18,0x18,0x18,0x18,0x30,0x60,0xc0,0x00,0x00,0x00, - - 7, // 0x2a '*' - 0x00,0x00,0x00,0x00,0x00,0x20,0xa8,0x70,0xa8,0x20,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x2b '+' - 0x00,0x00,0x00,0x00,0x00,0x30,0x30,0xfc,0x30,0x30,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x2c ',' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x30,0x30,0x30,0x60,0x00, - - 7, // 0x2d '-' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfc,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x2e '.' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x30,0x30,0x00,0x00,0x00, - - 7, // 0x2f '/' - 0x00,0x00,0x0c,0x0c,0x18,0x18,0x30,0x30,0x60,0x60,0xc0,0xc0,0x00,0x00,0x00, - - 7, // 0x30 '0' - 0x00,0x00,0x78,0xcc,0xcc,0xcc,0xdc,0xec,0xcc,0xcc,0xcc,0x78,0x00,0x00,0x00, - - 7, // 0x31 '1' - 0x00,0x00,0x30,0x30,0x70,0xf0,0x30,0x30,0x30,0x30,0x30,0xfc,0x00,0x00,0x00, - - 7, // 0x32 '2' - 0x00,0x00,0x78,0xcc,0xcc,0x0c,0x18,0x30,0x60,0xc0,0xcc,0xfc,0x00,0x00,0x00, - - 7, // 0x33 '3' - 0x00,0x00,0xfc,0x8c,0x18,0x30,0x78,0x0c,0x0c,0x0c,0xcc,0x78,0x00,0x00,0x00, - - 7, // 0x34 '4' - 0x00,0x00,0x18,0x30,0x60,0xc8,0xd8,0xd8,0xfc,0x18,0x18,0x3c,0x00,0x00,0x00, - - 7, // 0x35 '5' - 0x00,0x00,0xfc,0xc0,0xc0,0xc0,0xf8,0x0c,0x0c,0x0c,0xcc,0x78,0x00,0x00,0x00, - - 7, // 0x36 '6' - 0x00,0x00,0x38,0x60,0xc0,0xc0,0xf8,0xcc,0xcc,0xcc,0xcc,0x78,0x00,0x00,0x00, - - 7, // 0x37 '7' - 0x00,0x00,0xfc,0x8c,0x0c,0x0c,0x18,0x18,0x30,0x30,0x30,0x30,0x00,0x00,0x00, - - 7, // 0x38 '8' - 0x00,0x00,0x78,0xcc,0xcc,0xcc,0x78,0xcc,0xcc,0xcc,0xcc,0x78,0x00,0x00,0x00, - - 7, // 0x39 '9' - 0x00,0x00,0x78,0xcc,0xcc,0xcc,0xcc,0x7c,0x0c,0x0c,0x18,0x70,0x00,0x00,0x00, - - 7, // 0x3a ':' - 0x00,0x00,0x00,0x00,0x30,0x30,0x00,0x00,0x00,0x30,0x30,0x00,0x00,0x00,0x00, - - 7, // 0x3b ';' - 0x00,0x00,0x00,0x00,0x30,0x30,0x00,0x00,0x00,0x00,0x30,0x30,0x30,0x60,0x00, - - 7, // 0x3c '<' - 0x00,0x00,0x00,0x0c,0x18,0x30,0x60,0xc0,0x60,0x30,0x18,0x0c,0x00,0x00,0x00, - - 7, // 0x3d '=' - 0x00,0x00,0x00,0x00,0x00,0x00,0xfc,0x00,0xfc,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x3e '>' - 0x00,0x00,0x00,0xc0,0x60,0x30,0x18,0x0c,0x18,0x30,0x60,0xc0,0x00,0x00,0x00, - - 7, // 0x3f '?' - 0x00,0x00,0x78,0xcc,0xcc,0x18,0x30,0x30,0x30,0x00,0x30,0x30,0x00,0x00,0x00, - - 7, // 0x40 '@' - 0x00,0x00,0x00,0x70,0x88,0x04,0x74,0xb4,0xb4,0xb4,0xb4,0x68,0x00,0x00,0x00, - - 7, // 0x41 'A' - 0x00,0x00,0x30,0x78,0xcc,0xcc,0xcc,0xfc,0xcc,0xcc,0xcc,0xcc,0x00,0x00,0x00, - - 7, // 0x42 'B' - 0x00,0x00,0xf8,0xcc,0xcc,0xcc,0xf8,0xcc,0xcc,0xcc,0xcc,0xf8,0x00,0x00,0x00, - - 7, // 0x43 'C' - 0x00,0x00,0x78,0xcc,0xc4,0xc0,0xc0,0xc0,0xc0,0xc4,0xcc,0x78,0x00,0x00,0x00, - - 7, // 0x44 'D' - 0x00,0x00,0xf0,0xd8,0xcc,0xcc,0xcc,0xcc,0xcc,0xcc,0xd8,0xf0,0x00,0x00,0x00, - - 7, // 0x45 'E' - 0x00,0x00,0xfc,0xc4,0xc0,0xd0,0xf0,0xd0,0xc0,0xc0,0xc4,0xfc,0x00,0x00,0x00, - - 7, // 0x46 'F' - 0x00,0x00,0xfc,0xc4,0xc0,0xd0,0xf0,0xd0,0xc0,0xc0,0xc0,0xc0,0x00,0x00,0x00, - - 7, // 0x47 'G' - 0x00,0x00,0x78,0xcc,0xc0,0xc0,0xc0,0xdc,0xcc,0xcc,0xcc,0x78,0x00,0x00,0x00, - - 7, // 0x48 'H' - 0x00,0x00,0xcc,0xcc,0xcc,0xcc,0xfc,0xcc,0xcc,0xcc,0xcc,0xcc,0x00,0x00,0x00, - - 7, // 0x49 'I' - 0x00,0x00,0x78,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x78,0x00,0x00,0x00, - - 7, // 0x4a 'J' - 0x00,0x00,0x3c,0x18,0x18,0x18,0x18,0x18,0x18,0xd8,0xd8,0x70,0x00,0x00,0x00, - - 7, // 0x4b 'K' - 0x00,0x00,0xcc,0xcc,0xd8,0xd8,0xf0,0xd8,0xd8,0xcc,0xcc,0xcc,0x00,0x00,0x00, - - 7, // 0x4c 'L' - 0x00,0x00,0xc0,0xc0,0xc0,0xc0,0xc0,0xc0,0xc0,0xc0,0xc4,0xfc,0x00,0x00,0x00, - - 7, // 0x4d 'M' - 0x00,0x00,0x84,0xcc,0xfc,0xb4,0xcc,0xcc,0xcc,0xcc,0xcc,0xcc,0x00,0x00,0x00, - - 7, // 0x4e 'N' - 0x00,0x00,0xcc,0xcc,0xcc,0xec,0xfc,0xdc,0xcc,0xcc,0xcc,0xcc,0x00,0x00,0x00, - - 7, // 0x4f 'O' - 0x00,0x00,0x78,0xcc,0xcc,0xcc,0xcc,0xcc,0xcc,0xcc,0xcc,0x78,0x00,0x00,0x00, - - 7, // 0x50 'P' - 0x00,0x00,0xf8,0xcc,0xcc,0xcc,0xcc,0xf8,0xc0,0xc0,0xc0,0xc0,0x00,0x00,0x00, - - 7, // 0x51 'Q' - 0x00,0x00,0x78,0xcc,0xcc,0xcc,0xcc,0xcc,0xcc,0xdc,0x78,0x18,0x0c,0x00,0x00, - - 7, // 0x52 'R' - 0x00,0x00,0xf8,0xcc,0xcc,0xcc,0xcc,0xf8,0xd8,0xcc,0xcc,0xcc,0x00,0x00,0x00, - - 7, // 0x53 'S' - 0x00,0x00,0x78,0xcc,0xcc,0xe0,0x70,0x38,0x1c,0xcc,0xcc,0x78,0x00,0x00,0x00, - - 7, // 0x54 'T' - 0x00,0x00,0xfc,0xb4,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x00,0x00,0x00, - - 7, // 0x55 'U' - 0x00,0x00,0xcc,0xcc,0xcc,0xcc,0xcc,0xcc,0xcc,0xcc,0xcc,0x78,0x00,0x00,0x00, - - 7, // 0x56 'V' - 0x00,0x00,0xcc,0xcc,0xcc,0xcc,0xcc,0xcc,0xcc,0xcc,0x78,0x30,0x00,0x00,0x00, - - 7, // 0x57 'W' - 0x00,0x00,0xcc,0xcc,0xcc,0xcc,0xcc,0xcc,0xb4,0xfc,0xcc,0x84,0x00,0x00,0x00, - - 7, // 0x58 'X' - 0x00,0x00,0xcc,0xcc,0xcc,0x78,0x30,0x78,0xcc,0xcc,0xcc,0xcc,0x00,0x00,0x00, - - 7, // 0x59 'Y' - 0x00,0x00,0xcc,0xcc,0xcc,0xcc,0x78,0x30,0x30,0x30,0x30,0x78,0x00,0x00,0x00, - - 7, // 0x5a 'Z' - 0x00,0x00,0xfc,0x8c,0x0c,0x18,0x30,0x60,0xc0,0xc0,0xc4,0xfc,0x00,0x00,0x00, - - 7, // 0x5b '[' - 0x00,0x78,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x78,0x00,0x00, - - 7, // 0x5c '\' - 0x00,0x00,0xc0,0xc0,0x60,0x60,0x30,0x30,0x18,0x18,0x0c,0x0c,0x00,0x00,0x00, - - 7, // 0x5d ']' - 0x00,0x78,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x78,0x00,0x00, - - 7, // 0x5e '^' - 0x00,0x10,0x38,0x6c,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x5f '_' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfc,0x00,0x00,0x00, - - 7, // 0x60 '`' - 0x00,0x30,0x30,0x30,0x18,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x61 'a' - 0x00,0x00,0x00,0x00,0x70,0xd8,0x18,0x78,0xd8,0xd8,0xd8,0x6c,0x00,0x00,0x00, - - 7, // 0x62 'b' - 0x00,0x00,0x60,0x60,0x60,0x78,0x6c,0x6c,0x6c,0x6c,0x6c,0x78,0x00,0x00,0x00, - - 7, // 0x63 'c' - 0x00,0x00,0x00,0x00,0x78,0xcc,0xc0,0xc0,0xc0,0xc0,0xcc,0x78,0x00,0x00,0x00, - - 7, // 0x64 'd' - 0x00,0x00,0x18,0x18,0x18,0x78,0xd8,0xd8,0xd8,0xd8,0xd8,0x6c,0x00,0x00,0x00, - - 7, // 0x65 'e' - 0x00,0x00,0x00,0x00,0x78,0xcc,0xcc,0xfc,0xc0,0xc0,0xcc,0x78,0x00,0x00,0x00, - - 7, // 0x66 'f' - 0x00,0x00,0x30,0x68,0x60,0x60,0xf0,0x60,0x60,0x60,0x60,0xf0,0x00,0x00,0x00, - - 7, // 0x67 'g' - 0x00,0x00,0x00,0x00,0x6c,0xd8,0xd8,0xd8,0xd8,0xd8,0x78,0x18,0xd8,0x70,0x00, - - 7, // 0x68 'h' - 0x00,0x00,0xc0,0xc0,0xc0,0xd8,0xec,0xcc,0xcc,0xcc,0xcc,0xcc,0x00,0x00,0x00, - - 7, // 0x69 'i' - 0x00,0x00,0x30,0x30,0x00,0x70,0x30,0x30,0x30,0x30,0x30,0x78,0x00,0x00,0x00, - - 7, // 0x6a 'j' - 0x00,0x00,0x18,0x18,0x00,0x38,0x18,0x18,0x18,0x18,0x18,0xd8,0xd8,0x70,0x00, - - 7, // 0x6b 'k' - 0x00,0x00,0xc0,0xc0,0xcc,0xcc,0xcc,0xd8,0xf0,0xd8,0xcc,0xcc,0x00,0x00,0x00, - - 7, // 0x6c 'l' - 0x00,0x00,0x70,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x78,0x00,0x00,0x00, - - 7, // 0x6d 'm' - 0x00,0x00,0x00,0x00,0xe8,0xfc,0xd4,0xd4,0xd4,0xc4,0xc4,0xc4,0x00,0x00,0x00, - - 7, // 0x6e 'n' - 0x00,0x00,0x00,0x00,0xd8,0x6c,0x6c,0x6c,0x6c,0x6c,0x6c,0x6c,0x00,0x00,0x00, - - 7, // 0x6f 'o' - 0x00,0x00,0x00,0x00,0x78,0xcc,0xcc,0xcc,0xcc,0xcc,0xcc,0x78,0x00,0x00,0x00, - - 7, // 0x70 'p' - 0x00,0x00,0x00,0x00,0xf8,0xcc,0xcc,0xcc,0xcc,0xcc,0xf8,0xc0,0xc0,0xc0,0x00, - - 7, // 0x71 'q' - 0x00,0x00,0x00,0x00,0x7c,0xcc,0xcc,0xcc,0xcc,0xcc,0x7c,0x0c,0x0c,0x0c,0x00, - - 7, // 0x72 'r' - 0x00,0x00,0x00,0x00,0xd8,0xec,0xcc,0xc0,0xc0,0xc0,0xc0,0xc0,0x00,0x00,0x00, - - 7, // 0x73 's' - 0x00,0x00,0x00,0x00,0x78,0xcc,0xe0,0x70,0x38,0x1c,0xcc,0x78,0x00,0x00,0x00, - - 7, // 0x74 't' - 0x00,0x00,0x20,0x60,0x60,0xf0,0x60,0x60,0x60,0x60,0x6c,0x38,0x00,0x00,0x00, - - 7, // 0x75 'u' - 0x00,0x00,0x00,0x00,0xd8,0xd8,0xd8,0xd8,0xd8,0xd8,0xd8,0x6c,0x00,0x00,0x00, - - 7, // 0x76 'v' - 0x00,0x00,0x00,0x00,0xcc,0xcc,0xcc,0xcc,0xcc,0xcc,0x78,0x30,0x00,0x00,0x00, - - 7, // 0x77 'w' - 0x00,0x00,0x00,0x00,0xcc,0xcc,0xcc,0xcc,0xb4,0xfc,0xcc,0x84,0x00,0x00,0x00, - - 7, // 0x78 'x' - 0x00,0x00,0x00,0x00,0xcc,0xcc,0x78,0x30,0x78,0xcc,0xcc,0xcc,0x00,0x00,0x00, - - 7, // 0x79 'y' - 0x00,0x00,0x00,0x00,0xcc,0xcc,0xcc,0xcc,0xcc,0xcc,0x7c,0x0c,0x18,0xf0,0x00, - - 7, // 0x7a 'z' - 0x00,0x00,0x00,0x00,0xfc,0x8c,0x18,0x30,0x60,0xc0,0xc4,0xfc,0x00,0x00,0x00, - - 7, // 0x7b '{' - 0x00,0x1c,0x30,0x30,0x30,0x30,0x30,0xe0,0x30,0x30,0x30,0x30,0x1c,0x00,0x00, - - 7, // 0x7c '|' - 0x00,0x30,0x30,0x30,0x30,0x30,0x00,0x00,0x30,0x30,0x30,0x30,0x30,0x00,0x00, - - 7, // 0x7d '}' - 0x00,0xe0,0x30,0x30,0x30,0x30,0x30,0x1c,0x30,0x30,0x30,0x30,0xe0,0x00,0x00, - - 7, // 0x7e '~' - 0x00,0x00,0x34,0x58,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x7f '' - 0x00,0x00,0x00,0x00,0x00,0x30,0x78,0xcc,0xcc,0xfc,0x00,0x00,0x00,0x00,0x00, - 0 - }; - - const int8u gse8x16[] = - { - 16, 0, 32, 128-32, - - 0x00,0x00,0x11,0x00,0x22,0x00,0x33,0x00,0x44,0x00,0x55,0x00,0x66,0x00,0x77,0x00,0x88,0x00, - 0x99,0x00,0xaa,0x00,0xbb,0x00,0xcc,0x00,0xdd,0x00,0xee,0x00,0xff,0x00,0x10,0x01,0x21,0x01, - 0x32,0x01,0x43,0x01,0x54,0x01,0x65,0x01,0x76,0x01,0x87,0x01,0x98,0x01,0xa9,0x01,0xba,0x01, - 0xcb,0x01,0xdc,0x01,0xed,0x01,0xfe,0x01,0x0f,0x02,0x20,0x02,0x31,0x02,0x42,0x02,0x53,0x02, - 0x64,0x02,0x75,0x02,0x86,0x02,0x97,0x02,0xa8,0x02,0xb9,0x02,0xca,0x02,0xdb,0x02,0xec,0x02, - 0xfd,0x02,0x0e,0x03,0x1f,0x03,0x30,0x03,0x41,0x03,0x52,0x03,0x63,0x03,0x74,0x03,0x85,0x03, - 0x96,0x03,0xa7,0x03,0xb8,0x03,0xc9,0x03,0xda,0x03,0xeb,0x03,0xfc,0x03,0x0d,0x04,0x1e,0x04, - 0x2f,0x04,0x40,0x04,0x51,0x04,0x62,0x04,0x73,0x04,0x84,0x04,0x95,0x04,0xa6,0x04,0xb7,0x04, - 0xc8,0x04,0xd9,0x04,0xea,0x04,0xfb,0x04,0x0c,0x05,0x1d,0x05,0x2e,0x05,0x3f,0x05,0x50,0x05, - 0x61,0x05,0x72,0x05,0x83,0x05,0x94,0x05,0xa5,0x05,0xb6,0x05,0xc7,0x05,0xd8,0x05,0xe9,0x05, - 0xfa,0x05,0x0b,0x06,0x1c,0x06,0x2d,0x06,0x3e,0x06,0x4f,0x06, - - 8, // 0x20 ' ' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x21 '!' - 0x00,0x00,0x10,0x38,0x38,0x38,0x38,0x10,0x10,0x00,0x10,0x10,0x00,0x00,0x00,0x00, - - 8, // 0x22 '"' - 0x00,0x24,0x24,0x24,0x24,0x48,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x23 '#' - 0x00,0x00,0x24,0x24,0x24,0x7e,0x24,0x24,0x7e,0x24,0x24,0x24,0x00,0x00,0x00,0x00, - - 8, // 0x24 '$' - 0x00,0x14,0x14,0x3e,0x55,0x54,0x54,0x3e,0x15,0x15,0x55,0x3e,0x14,0x14,0x00,0x00, - - 8, // 0x25 '%' - 0x00,0x00,0x32,0x56,0x6c,0x04,0x08,0x08,0x10,0x13,0x25,0x26,0x00,0x00,0x00,0x00, - - 8, // 0x26 '&' - 0x00,0x00,0x18,0x24,0x24,0x24,0x18,0x28,0x45,0x46,0x44,0x3b,0x00,0x00,0x00,0x00, - - 8, // 0x27 ''' - 0x00,0x00,0x08,0x08,0x08,0x10,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x28 '(' - 0x00,0x04,0x08,0x10,0x10,0x20,0x20,0x20,0x20,0x10,0x10,0x08,0x04,0x00,0x00,0x00, - - 8, // 0x29 ')' - 0x00,0x10,0x08,0x04,0x04,0x02,0x02,0x02,0x02,0x04,0x04,0x08,0x10,0x00,0x00,0x00, - - 8, // 0x2a '*' - 0x00,0x00,0x00,0x00,0x66,0x24,0x18,0xff,0x18,0x24,0x66,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x2b '+' - 0x00,0x00,0x00,0x00,0x08,0x08,0x08,0x7f,0x08,0x08,0x08,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x2c ',' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x18,0x18,0x18,0x30,0x20,0x00, - - 8, // 0x2d '-' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x2e '.' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x18,0x18,0x00,0x00,0x00,0x00, - - 8, // 0x2f '/' - 0x00,0x02,0x02,0x04,0x04,0x08,0x08,0x10,0x10,0x20,0x20,0x40,0x40,0x00,0x00,0x00, - - 8, // 0x30 '0' - 0x00,0x00,0x3c,0x42,0x42,0x46,0x4a,0x52,0x62,0x42,0x42,0x3c,0x00,0x00,0x00,0x00, - - 8, // 0x31 '1' - 0x00,0x00,0x08,0x08,0x18,0x38,0x08,0x08,0x08,0x08,0x08,0x3e,0x00,0x00,0x00,0x00, - - 8, // 0x32 '2' - 0x00,0x00,0x3c,0x42,0x42,0x02,0x04,0x08,0x10,0x20,0x42,0x7e,0x00,0x00,0x00,0x00, - - 8, // 0x33 '3' - 0x00,0x00,0x7e,0x42,0x04,0x08,0x1c,0x02,0x02,0x02,0x42,0x3c,0x00,0x00,0x00,0x00, - - 8, // 0x34 '4' - 0x00,0x00,0x04,0x08,0x10,0x24,0x44,0x44,0x7e,0x04,0x04,0x0e,0x00,0x00,0x00,0x00, - - 8, // 0x35 '5' - 0x00,0x00,0x7e,0x42,0x40,0x40,0x7c,0x02,0x02,0x02,0x42,0x3c,0x00,0x00,0x00,0x00, - - 8, // 0x36 '6' - 0x00,0x00,0x1c,0x20,0x40,0x40,0x7c,0x42,0x42,0x42,0x42,0x3c,0x00,0x00,0x00,0x00, - - 8, // 0x37 '7' - 0x00,0x00,0x7e,0x42,0x42,0x02,0x04,0x08,0x10,0x10,0x10,0x10,0x00,0x00,0x00,0x00, - - 8, // 0x38 '8' - 0x00,0x00,0x3c,0x42,0x42,0x42,0x3c,0x42,0x42,0x42,0x42,0x3c,0x00,0x00,0x00,0x00, - - 8, // 0x39 '9' - 0x00,0x00,0x3c,0x42,0x42,0x42,0x42,0x3e,0x02,0x02,0x04,0x38,0x00,0x00,0x00,0x00, - - 8, // 0x3a ':' - 0x00,0x00,0x00,0x00,0x18,0x00,0x00,0x00,0x00,0x18,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x3b ';' - 0x00,0x00,0x00,0x00,0x30,0x00,0x00,0x00,0x00,0x00,0x30,0x30,0x30,0x60,0x40,0x00, - - 8, // 0x3c '<' - 0x00,0x00,0x00,0x02,0x04,0x08,0x10,0x20,0x10,0x08,0x04,0x02,0x00,0x00,0x00,0x00, - - 8, // 0x3d '=' - 0x00,0x00,0x00,0x00,0x00,0x00,0x7f,0x00,0x7f,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x3e '>' - 0x00,0x00,0x00,0x20,0x10,0x08,0x04,0x02,0x04,0x08,0x10,0x20,0x00,0x00,0x00,0x00, - - 8, // 0x3f '?' - 0x00,0x00,0x3c,0x42,0x42,0x42,0x04,0x08,0x08,0x00,0x08,0x08,0x00,0x00,0x00,0x00, - - 8, // 0x40 '@' - 0x00,0x00,0x3c,0x42,0x01,0x39,0x49,0x49,0x49,0x49,0x49,0x36,0x00,0x00,0x00,0x00, - - 8, // 0x41 'A' - 0x00,0x00,0x18,0x24,0x42,0x42,0x42,0x7e,0x42,0x42,0x42,0x42,0x00,0x00,0x00,0x00, - - 8, // 0x42 'B' - 0x00,0x00,0x7c,0x22,0x22,0x22,0x3c,0x22,0x22,0x22,0x22,0x7c,0x00,0x00,0x00,0x00, - - 8, // 0x43 'C' - 0x00,0x00,0x3c,0x42,0x42,0x40,0x40,0x40,0x40,0x42,0x42,0x3c,0x00,0x00,0x00,0x00, - - 8, // 0x44 'D' - 0x00,0x00,0x7c,0x22,0x22,0x22,0x22,0x22,0x22,0x22,0x22,0x7c,0x00,0x00,0x00,0x00, - - 8, // 0x45 'E' - 0x00,0x00,0x7e,0x22,0x20,0x28,0x38,0x28,0x20,0x20,0x22,0x7e,0x00,0x00,0x00,0x00, - - 8, // 0x46 'F' - 0x00,0x00,0x7e,0x22,0x20,0x28,0x38,0x28,0x20,0x20,0x20,0x70,0x00,0x00,0x00,0x00, - - 8, // 0x47 'G' - 0x00,0x00,0x3c,0x42,0x42,0x40,0x40,0x4e,0x42,0x42,0x42,0x3c,0x00,0x00,0x00,0x00, - - 8, // 0x48 'H' - 0x00,0x00,0x42,0x42,0x42,0x42,0x7e,0x42,0x42,0x42,0x42,0x42,0x00,0x00,0x00,0x00, - - 8, // 0x49 'I' - 0x00,0x00,0x1c,0x08,0x08,0x08,0x08,0x08,0x08,0x08,0x08,0x1c,0x00,0x00,0x00,0x00, - - 8, // 0x4a 'J' - 0x00,0x00,0x0e,0x04,0x04,0x04,0x04,0x04,0x04,0x44,0x44,0x38,0x00,0x00,0x00,0x00, - - 8, // 0x4b 'K' - 0x00,0x00,0x62,0x22,0x24,0x28,0x30,0x28,0x24,0x22,0x22,0x62,0x00,0x00,0x00,0x00, - - 8, // 0x4c 'L' - 0x00,0x00,0x70,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x22,0x7e,0x00,0x00,0x00,0x00, - - 8, // 0x4d 'M' - 0x00,0x00,0x41,0x63,0x55,0x49,0x41,0x41,0x41,0x41,0x41,0x41,0x00,0x00,0x00,0x00, - - 8, // 0x4e 'N' - 0x00,0x00,0x42,0x42,0x62,0x52,0x4a,0x46,0x42,0x42,0x42,0x42,0x00,0x00,0x00,0x00, - - 8, // 0x4f 'O' - 0x00,0x00,0x3c,0x42,0x42,0x42,0x42,0x42,0x42,0x42,0x42,0x3c,0x00,0x00,0x00,0x00, - - 8, // 0x50 'P' - 0x00,0x00,0x7c,0x22,0x22,0x22,0x22,0x3c,0x20,0x20,0x20,0x70,0x00,0x00,0x00,0x00, - - 8, // 0x51 'Q' - 0x00,0x00,0x3c,0x42,0x42,0x42,0x42,0x42,0x42,0x4a,0x44,0x3a,0x02,0x00,0x00,0x00, - - 8, // 0x52 'R' - 0x00,0x00,0x7c,0x22,0x22,0x22,0x22,0x3c,0x28,0x24,0x22,0x62,0x00,0x00,0x00,0x00, - - 8, // 0x53 'S' - 0x00,0x00,0x3c,0x42,0x42,0x40,0x30,0x0c,0x02,0x42,0x42,0x3c,0x00,0x00,0x00,0x00, - - 8, // 0x54 'T' - 0x00,0x00,0x7f,0x49,0x08,0x08,0x08,0x08,0x08,0x08,0x08,0x1c,0x00,0x00,0x00,0x00, - - 8, // 0x55 'U' - 0x00,0x00,0x42,0x42,0x42,0x42,0x42,0x42,0x42,0x42,0x42,0x3c,0x00,0x00,0x00,0x00, - - 8, // 0x56 'V' - 0x00,0x00,0x41,0x41,0x41,0x41,0x22,0x22,0x14,0x14,0x08,0x08,0x00,0x00,0x00,0x00, - - 8, // 0x57 'W' - 0x00,0x00,0x41,0x41,0x41,0x41,0x41,0x49,0x49,0x55,0x63,0x41,0x00,0x00,0x00,0x00, - - 8, // 0x58 'X' - 0x00,0x00,0x42,0x42,0x42,0x24,0x18,0x18,0x24,0x42,0x42,0x42,0x00,0x00,0x00,0x00, - - 8, // 0x59 'Y' - 0x00,0x00,0x22,0x22,0x22,0x22,0x14,0x08,0x08,0x08,0x08,0x1c,0x00,0x00,0x00,0x00, - - 8, // 0x5a 'Z' - 0x00,0x00,0x7e,0x42,0x02,0x04,0x08,0x10,0x20,0x40,0x42,0x7e,0x00,0x00,0x00,0x00, - - 8, // 0x5b '[' - 0x00,0x1e,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x1e,0x00,0x00,0x00, - - 8, // 0x5c '\' - 0x00,0x40,0x40,0x20,0x20,0x10,0x10,0x08,0x08,0x04,0x04,0x02,0x02,0x00,0x00,0x00, - - 8, // 0x5d ']' - 0x00,0x3c,0x04,0x04,0x04,0x04,0x04,0x04,0x04,0x04,0x04,0x04,0x3c,0x00,0x00,0x00, - - 8, // 0x5e '^' - 0x00,0x00,0x08,0x14,0x22,0x41,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x5f '_' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xff,0x00,0x00,0x00,0x00, - - 8, // 0x60 '`' - 0x00,0x00,0x08,0x08,0x08,0x04,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x61 'a' - 0x00,0x00,0x00,0x00,0x00,0x38,0x44,0x04,0x3c,0x44,0x44,0x3e,0x00,0x00,0x00,0x00, - - 8, // 0x62 'b' - 0x00,0x00,0x60,0x20,0x20,0x38,0x24,0x22,0x22,0x22,0x22,0x3c,0x00,0x00,0x00,0x00, - - 8, // 0x63 'c' - 0x00,0x00,0x00,0x00,0x00,0x3c,0x42,0x40,0x40,0x40,0x42,0x3c,0x00,0x00,0x00,0x00, - - 8, // 0x64 'd' - 0x00,0x00,0x0c,0x04,0x04,0x1c,0x24,0x44,0x44,0x44,0x44,0x3e,0x00,0x00,0x00,0x00, - - 8, // 0x65 'e' - 0x00,0x00,0x00,0x00,0x00,0x3c,0x42,0x42,0x7e,0x40,0x42,0x3c,0x00,0x00,0x00,0x00, - - 8, // 0x66 'f' - 0x00,0x00,0x0c,0x12,0x10,0x10,0x38,0x10,0x10,0x10,0x10,0x38,0x00,0x00,0x00,0x00, - - 8, // 0x67 'g' - 0x00,0x00,0x00,0x00,0x00,0x3e,0x44,0x44,0x44,0x44,0x44,0x3c,0x04,0x44,0x38,0x00, - - 8, // 0x68 'h' - 0x00,0x00,0x60,0x20,0x20,0x2c,0x32,0x22,0x22,0x22,0x22,0x62,0x00,0x00,0x00,0x00, - - 8, // 0x69 'i' - 0x00,0x00,0x08,0x08,0x00,0x18,0x08,0x08,0x08,0x08,0x08,0x1c,0x00,0x00,0x00,0x00, - - 8, // 0x6a 'j' - 0x00,0x00,0x04,0x04,0x00,0x0c,0x04,0x04,0x04,0x04,0x04,0x44,0x44,0x38,0x00,0x00, - - 8, // 0x6b 'k' - 0x00,0x00,0x60,0x20,0x20,0x22,0x24,0x28,0x38,0x24,0x22,0x62,0x00,0x00,0x00,0x00, - - 8, // 0x6c 'l' - 0x00,0x00,0x18,0x08,0x08,0x08,0x08,0x08,0x08,0x08,0x08,0x1c,0x00,0x00,0x00,0x00, - - 8, // 0x6d 'm' - 0x00,0x00,0x00,0x00,0x00,0x76,0x49,0x49,0x49,0x49,0x41,0x41,0x00,0x00,0x00,0x00, - - 8, // 0x6e 'n' - 0x00,0x00,0x00,0x00,0x00,0x5c,0x22,0x22,0x22,0x22,0x22,0x22,0x00,0x00,0x00,0x00, - - 8, // 0x6f 'o' - 0x00,0x00,0x00,0x00,0x00,0x3c,0x42,0x42,0x42,0x42,0x42,0x3c,0x00,0x00,0x00,0x00, - - 8, // 0x70 'p' - 0x00,0x00,0x00,0x00,0x00,0x7c,0x22,0x22,0x22,0x22,0x22,0x3c,0x20,0x20,0x70,0x00, - - 8, // 0x71 'q' - 0x00,0x00,0x00,0x00,0x00,0x3e,0x44,0x44,0x44,0x44,0x44,0x3c,0x04,0x04,0x0e,0x00, - - 8, // 0x72 'r' - 0x00,0x00,0x00,0x00,0x00,0x7c,0x22,0x22,0x20,0x20,0x20,0x70,0x00,0x00,0x00,0x00, - - 8, // 0x73 's' - 0x00,0x00,0x00,0x00,0x00,0x3c,0x42,0x40,0x3c,0x02,0x42,0x3c,0x00,0x00,0x00,0x00, - - 8, // 0x74 't' - 0x00,0x00,0x10,0x10,0x10,0x7c,0x10,0x10,0x10,0x10,0x12,0x0c,0x00,0x00,0x00,0x00, - - 8, // 0x75 'u' - 0x00,0x00,0x00,0x00,0x00,0x44,0x44,0x44,0x44,0x44,0x44,0x3e,0x00,0x00,0x00,0x00, - - 8, // 0x76 'v' - 0x00,0x00,0x00,0x00,0x00,0x41,0x41,0x41,0x41,0x22,0x14,0x08,0x00,0x00,0x00,0x00, - - 8, // 0x77 'w' - 0x00,0x00,0x00,0x00,0x00,0x41,0x41,0x41,0x49,0x49,0x55,0x22,0x00,0x00,0x00,0x00, - - 8, // 0x78 'x' - 0x00,0x00,0x00,0x00,0x00,0x42,0x42,0x24,0x18,0x24,0x42,0x42,0x00,0x00,0x00,0x00, - - 8, // 0x79 'y' - 0x00,0x00,0x00,0x00,0x00,0x42,0x42,0x42,0x42,0x42,0x42,0x3e,0x02,0x04,0x78,0x00, - - 8, // 0x7a 'z' - 0x00,0x00,0x00,0x00,0x00,0x7e,0x44,0x08,0x10,0x20,0x42,0x7e,0x00,0x00,0x00,0x00, - - 8, // 0x7b '{' - 0x00,0x06,0x08,0x08,0x08,0x08,0x08,0x30,0x08,0x08,0x08,0x08,0x08,0x06,0x00,0x00, - - 8, // 0x7c '|' - 0x00,0x00,0x08,0x08,0x08,0x08,0x08,0x00,0x08,0x08,0x08,0x08,0x08,0x00,0x00,0x00, - - 8, // 0x7d '}' - 0x00,0x30,0x08,0x08,0x08,0x08,0x08,0x06,0x08,0x08,0x08,0x08,0x08,0x30,0x00,0x00, - - 8, // 0x7e '~' - 0x00,0x00,0x39,0x4e,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x7f '' - 0x00,0x00,0x00,0x00,0x00,0x08,0x14,0x22,0x41,0x41,0x7f,0x00,0x00,0x00,0x00,0x00, - 0 - }; - - const int8u gse8x16_bold[] = - { - 16, 0, 32, 128-32, - - 0x00,0x00,0x11,0x00,0x22,0x00,0x33,0x00,0x44,0x00,0x55,0x00,0x66,0x00,0x77,0x00,0x88,0x00, - 0x99,0x00,0xaa,0x00,0xbb,0x00,0xcc,0x00,0xdd,0x00,0xee,0x00,0xff,0x00,0x10,0x01,0x21,0x01, - 0x32,0x01,0x43,0x01,0x54,0x01,0x65,0x01,0x76,0x01,0x87,0x01,0x98,0x01,0xa9,0x01,0xba,0x01, - 0xcb,0x01,0xdc,0x01,0xed,0x01,0xfe,0x01,0x0f,0x02,0x20,0x02,0x31,0x02,0x42,0x02,0x53,0x02, - 0x64,0x02,0x75,0x02,0x86,0x02,0x97,0x02,0xa8,0x02,0xb9,0x02,0xca,0x02,0xdb,0x02,0xec,0x02, - 0xfd,0x02,0x0e,0x03,0x1f,0x03,0x30,0x03,0x41,0x03,0x52,0x03,0x63,0x03,0x74,0x03,0x85,0x03, - 0x96,0x03,0xa7,0x03,0xb8,0x03,0xc9,0x03,0xda,0x03,0xeb,0x03,0xfc,0x03,0x0d,0x04,0x1e,0x04, - 0x2f,0x04,0x40,0x04,0x51,0x04,0x62,0x04,0x73,0x04,0x84,0x04,0x95,0x04,0xa6,0x04,0xb7,0x04, - 0xc8,0x04,0xd9,0x04,0xea,0x04,0xfb,0x04,0x0c,0x05,0x1d,0x05,0x2e,0x05,0x3f,0x05,0x50,0x05, - 0x61,0x05,0x72,0x05,0x83,0x05,0x94,0x05,0xa5,0x05,0xb6,0x05,0xc7,0x05,0xd8,0x05,0xe9,0x05, - 0xfa,0x05,0x0b,0x06,0x1c,0x06,0x2d,0x06,0x3e,0x06,0x4f,0x06, - - 8, // 0x20 ' ' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x21 '!' - 0x00,0x00,0x18,0x3c,0x3c,0x3c,0x3c,0x18,0x18,0x00,0x18,0x18,0x00,0x00,0x00,0x00, - - 8, // 0x22 '"' - 0x00,0x66,0x66,0x66,0x66,0x24,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x23 '#' - 0x00,0x00,0x66,0x66,0x66,0xff,0x66,0x66,0xff,0x66,0x66,0x66,0x00,0x00,0x00,0x00, - - 8, // 0x24 '$' - 0x00,0x08,0x08,0x3e,0x6b,0x6b,0x68,0x3e,0x0b,0x6b,0x6b,0x3e,0x08,0x08,0x00,0x00, - - 8, // 0x25 '%' - 0x00,0x00,0x66,0xbe,0xcc,0x0c,0x18,0x18,0x30,0x33,0x65,0x66,0x00,0x00,0x00,0x00, - - 8, // 0x26 '&' - 0x00,0x00,0x1c,0x36,0x36,0x36,0x1c,0x3b,0x6e,0x66,0x66,0x3b,0x00,0x00,0x00,0x00, - - 8, // 0x27 ''' - 0x00,0x00,0x18,0x18,0x18,0x30,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x28 '(' - 0x00,0x06,0x0c,0x18,0x18,0x30,0x30,0x30,0x30,0x18,0x18,0x0c,0x06,0x00,0x00,0x00, - - 8, // 0x29 ')' - 0x00,0x30,0x18,0x0c,0x0c,0x06,0x06,0x06,0x06,0x0c,0x0c,0x18,0x30,0x00,0x00,0x00, - - 8, // 0x2a '*' - 0x00,0x00,0x00,0x00,0x66,0x24,0x18,0xff,0x18,0x24,0x66,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x2b '+' - 0x00,0x00,0x00,0x00,0x18,0x18,0x18,0xff,0x18,0x18,0x18,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x2c ',' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x18,0x18,0x18,0x30,0x20,0x00, - - 8, // 0x2d '-' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x2e '.' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x18,0x18,0x00,0x00,0x00,0x00, - - 8, // 0x2f '/' - 0x00,0x03,0x03,0x06,0x06,0x0c,0x0c,0x18,0x18,0x30,0x30,0x60,0x60,0x00,0x00,0x00, - - 8, // 0x30 '0' - 0x00,0x00,0x3e,0x63,0x63,0x67,0x6b,0x73,0x63,0x63,0x63,0x3e,0x00,0x00,0x00,0x00, - - 8, // 0x31 '1' - 0x00,0x00,0x0c,0x0c,0x1c,0x3c,0x0c,0x0c,0x0c,0x0c,0x0c,0x3f,0x00,0x00,0x00,0x00, - - 8, // 0x32 '2' - 0x00,0x00,0x3e,0x63,0x63,0x03,0x06,0x0c,0x18,0x30,0x61,0x7f,0x00,0x00,0x00,0x00, - - 8, // 0x33 '3' - 0x00,0x00,0x7f,0x43,0x06,0x0c,0x1e,0x03,0x03,0x03,0x63,0x3e,0x00,0x00,0x00,0x00, - - 8, // 0x34 '4' - 0x00,0x00,0x06,0x0c,0x18,0x32,0x66,0x66,0x7f,0x06,0x06,0x0f,0x00,0x00,0x00,0x00, - - 8, // 0x35 '5' - 0x00,0x00,0x7f,0x61,0x60,0x60,0x7e,0x03,0x03,0x03,0x63,0x3e,0x00,0x00,0x00,0x00, - - 8, // 0x36 '6' - 0x00,0x00,0x1e,0x30,0x60,0x60,0x7e,0x63,0x63,0x63,0x63,0x3e,0x00,0x00,0x00,0x00, - - 8, // 0x37 '7' - 0x00,0x00,0x7f,0x63,0x63,0x03,0x06,0x0c,0x18,0x18,0x18,0x18,0x00,0x00,0x00,0x00, - - 8, // 0x38 '8' - 0x00,0x00,0x3e,0x63,0x63,0x63,0x3e,0x63,0x63,0x63,0x63,0x3e,0x00,0x00,0x00,0x00, - - 8, // 0x39 '9' - 0x00,0x00,0x3e,0x63,0x63,0x63,0x63,0x3f,0x03,0x03,0x06,0x3c,0x00,0x00,0x00,0x00, - - 8, // 0x3a ':' - 0x00,0x00,0x00,0x00,0x18,0x18,0x00,0x00,0x00,0x18,0x18,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x3b ';' - 0x00,0x00,0x00,0x00,0x30,0x30,0x00,0x00,0x00,0x00,0x30,0x30,0x30,0x60,0x40,0x00, - - 8, // 0x3c '<' - 0x00,0x00,0x00,0x06,0x0c,0x18,0x30,0x60,0x30,0x18,0x0c,0x06,0x00,0x00,0x00,0x00, - - 8, // 0x3d '=' - 0x00,0x00,0x00,0x00,0x00,0x00,0x7f,0x00,0x7f,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x3e '>' - 0x00,0x00,0x00,0x30,0x18,0x0c,0x06,0x03,0x06,0x0c,0x18,0x30,0x00,0x00,0x00,0x00, - - 8, // 0x3f '?' - 0x00,0x00,0x3e,0x63,0x63,0x63,0x06,0x0c,0x0c,0x00,0x0c,0x0c,0x00,0x00,0x00,0x00, - - 8, // 0x40 '@' - 0x00,0x00,0x7c,0x86,0x03,0x73,0xdb,0xdb,0xdb,0xdb,0xdb,0x6e,0x00,0x00,0x00,0x00, - - 8, // 0x41 'A' - 0x00,0x00,0x08,0x1c,0x36,0x63,0x63,0x63,0x7f,0x63,0x63,0x63,0x00,0x00,0x00,0x00, - - 8, // 0x42 'B' - 0x00,0x00,0x7e,0x33,0x33,0x33,0x3e,0x33,0x33,0x33,0x33,0x7e,0x00,0x00,0x00,0x00, - - 8, // 0x43 'C' - 0x00,0x00,0x1e,0x33,0x61,0x60,0x60,0x60,0x60,0x61,0x33,0x1e,0x00,0x00,0x00,0x00, - - 8, // 0x44 'D' - 0x00,0x00,0x7c,0x36,0x33,0x33,0x33,0x33,0x33,0x33,0x36,0x7c,0x00,0x00,0x00,0x00, - - 8, // 0x45 'E' - 0x00,0x00,0x7f,0x33,0x31,0x34,0x3c,0x34,0x30,0x31,0x33,0x7f,0x00,0x00,0x00,0x00, - - 8, // 0x46 'F' - 0x00,0x00,0x7f,0x33,0x31,0x34,0x3c,0x34,0x30,0x30,0x30,0x78,0x00,0x00,0x00,0x00, - - 8, // 0x47 'G' - 0x00,0x00,0x1f,0x33,0x61,0x60,0x60,0x6f,0x63,0x63,0x33,0x1e,0x00,0x00,0x00,0x00, - - 8, // 0x48 'H' - 0x00,0x00,0x63,0x63,0x63,0x63,0x7f,0x63,0x63,0x63,0x63,0x63,0x00,0x00,0x00,0x00, - - 8, // 0x49 'I' - 0x00,0x00,0x1e,0x0c,0x0c,0x0c,0x0c,0x0c,0x0c,0x0c,0x0c,0x1e,0x00,0x00,0x00,0x00, - - 8, // 0x4a 'J' - 0x00,0x00,0x0f,0x06,0x06,0x06,0x06,0x06,0x06,0x66,0x66,0x3c,0x00,0x00,0x00,0x00, - - 8, // 0x4b 'K' - 0x00,0x00,0x73,0x33,0x36,0x36,0x3c,0x36,0x36,0x33,0x33,0x73,0x00,0x00,0x00,0x00, - - 8, // 0x4c 'L' - 0x00,0x00,0x78,0x30,0x30,0x30,0x30,0x30,0x30,0x31,0x33,0x7f,0x00,0x00,0x00,0x00, - - 8, // 0x4d 'M' - 0x00,0x00,0x63,0x63,0x77,0x77,0x7f,0x6b,0x6b,0x63,0x63,0x63,0x00,0x00,0x00,0x00, - - 8, // 0x4e 'N' - 0x00,0x00,0x63,0x63,0x73,0x7b,0x6f,0x67,0x63,0x63,0x63,0x63,0x00,0x00,0x00,0x00, - - 8, // 0x4f 'O' - 0x00,0x00,0x1c,0x36,0x63,0x63,0x63,0x63,0x63,0x63,0x36,0x1c,0x00,0x00,0x00,0x00, - - 8, // 0x50 'P' - 0x00,0x00,0x7e,0x33,0x33,0x33,0x33,0x3e,0x30,0x30,0x30,0x78,0x00,0x00,0x00,0x00, - - 8, // 0x51 'Q' - 0x00,0x00,0x1c,0x36,0x63,0x63,0x63,0x63,0x63,0x6f,0x36,0x1e,0x03,0x00,0x00,0x00, - - 8, // 0x52 'R' - 0x00,0x00,0x7e,0x33,0x33,0x33,0x33,0x3e,0x36,0x33,0x33,0x73,0x00,0x00,0x00,0x00, - - 8, // 0x53 'S' - 0x00,0x00,0x3e,0x63,0x63,0x30,0x18,0x0c,0x06,0x63,0x63,0x3e,0x00,0x00,0x00,0x00, - - 8, // 0x54 'T' - 0x00,0x00,0x3f,0x3f,0x2d,0x0c,0x0c,0x0c,0x0c,0x0c,0x0c,0x1e,0x00,0x00,0x00,0x00, - - 8, // 0x55 'U' - 0x00,0x00,0x63,0x63,0x63,0x63,0x63,0x63,0x63,0x63,0x63,0x3e,0x00,0x00,0x00,0x00, - - 8, // 0x56 'V' - 0x00,0x00,0x63,0x63,0x63,0x63,0x63,0x63,0x63,0x36,0x1c,0x08,0x00,0x00,0x00,0x00, - - 8, // 0x57 'W' - 0x00,0x00,0x63,0x63,0x63,0x6b,0x6b,0x7f,0x77,0x77,0x63,0x63,0x00,0x00,0x00,0x00, - - 8, // 0x58 'X' - 0x00,0x00,0x63,0x63,0x63,0x36,0x1c,0x1c,0x36,0x63,0x63,0x63,0x00,0x00,0x00,0x00, - - 8, // 0x59 'Y' - 0x00,0x00,0x33,0x33,0x33,0x33,0x1e,0x0c,0x0c,0x0c,0x0c,0x1e,0x00,0x00,0x00,0x00, - - 8, // 0x5a 'Z' - 0x00,0x00,0x7f,0x63,0x43,0x06,0x0c,0x18,0x30,0x61,0x63,0x7f,0x00,0x00,0x00,0x00, - - 8, // 0x5b '[' - 0x00,0x1f,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x1f,0x00,0x00,0x00, - - 8, // 0x5c '\' - 0x00,0x60,0x60,0x30,0x30,0x18,0x18,0x0c,0x0c,0x06,0x06,0x03,0x03,0x00,0x00,0x00, - - 8, // 0x5d ']' - 0x00,0x7c,0x0c,0x0c,0x0c,0x0c,0x0c,0x0c,0x0c,0x0c,0x0c,0x0c,0x7c,0x00,0x00,0x00, - - 8, // 0x5e '^' - 0x00,0x00,0x08,0x1c,0x36,0x63,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x5f '_' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xff,0x00,0x00,0x00,0x00, - - 8, // 0x60 '`' - 0x00,0x00,0x18,0x18,0x18,0x0c,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x61 'a' - 0x00,0x00,0x00,0x00,0x00,0x3c,0x66,0x06,0x3e,0x66,0x66,0x3b,0x00,0x00,0x00,0x00, - - 8, // 0x62 'b' - 0x00,0x00,0x70,0x30,0x30,0x3c,0x36,0x33,0x33,0x33,0x33,0x3e,0x00,0x00,0x00,0x00, - - 8, // 0x63 'c' - 0x00,0x00,0x00,0x00,0x00,0x3e,0x63,0x63,0x60,0x60,0x63,0x3e,0x00,0x00,0x00,0x00, - - 8, // 0x64 'd' - 0x00,0x00,0x0e,0x06,0x06,0x1e,0x36,0x66,0x66,0x66,0x66,0x3b,0x00,0x00,0x00,0x00, - - 8, // 0x65 'e' - 0x00,0x00,0x00,0x00,0x00,0x3e,0x63,0x63,0x7f,0x60,0x63,0x3e,0x00,0x00,0x00,0x00, - - 8, // 0x66 'f' - 0x00,0x00,0x0e,0x1b,0x1b,0x18,0x3c,0x18,0x18,0x18,0x18,0x3c,0x00,0x00,0x00,0x00, - - 8, // 0x67 'g' - 0x00,0x00,0x00,0x00,0x00,0x3b,0x66,0x66,0x66,0x66,0x66,0x3e,0x06,0x66,0x3c,0x00, - - 8, // 0x68 'h' - 0x00,0x00,0x70,0x30,0x30,0x36,0x3b,0x33,0x33,0x33,0x33,0x73,0x00,0x00,0x00,0x00, - - 8, // 0x69 'i' - 0x00,0x00,0x0c,0x0c,0x00,0x1c,0x0c,0x0c,0x0c,0x0c,0x0c,0x1e,0x00,0x00,0x00,0x00, - - 8, // 0x6a 'j' - 0x00,0x00,0x06,0x06,0x00,0x0e,0x06,0x06,0x06,0x06,0x06,0x66,0x66,0x3c,0x00,0x00, - - 8, // 0x6b 'k' - 0x00,0x00,0x70,0x30,0x30,0x33,0x33,0x36,0x3c,0x36,0x33,0x73,0x00,0x00,0x00,0x00, - - 8, // 0x6c 'l' - 0x00,0x00,0x1c,0x0c,0x0c,0x0c,0x0c,0x0c,0x0c,0x0c,0x0c,0x1e,0x00,0x00,0x00,0x00, - - 8, // 0x6d 'm' - 0x00,0x00,0x00,0x00,0x00,0x76,0x7f,0x6b,0x6b,0x6b,0x63,0x63,0x00,0x00,0x00,0x00, - - 8, // 0x6e 'n' - 0x00,0x00,0x00,0x00,0x00,0x6e,0x33,0x33,0x33,0x33,0x33,0x33,0x00,0x00,0x00,0x00, - - 8, // 0x6f 'o' - 0x00,0x00,0x00,0x00,0x00,0x3e,0x63,0x63,0x63,0x63,0x63,0x3e,0x00,0x00,0x00,0x00, - - 8, // 0x70 'p' - 0x00,0x00,0x00,0x00,0x00,0x6e,0x33,0x33,0x33,0x33,0x33,0x3e,0x30,0x30,0x78,0x00, - - 8, // 0x71 'q' - 0x00,0x00,0x00,0x00,0x00,0x3b,0x66,0x66,0x66,0x66,0x66,0x3e,0x06,0x06,0x0f,0x00, - - 8, // 0x72 'r' - 0x00,0x00,0x00,0x00,0x00,0x6e,0x3b,0x33,0x30,0x30,0x30,0x78,0x00,0x00,0x00,0x00, - - 8, // 0x73 's' - 0x00,0x00,0x00,0x00,0x00,0x3e,0x63,0x60,0x3e,0x03,0x63,0x3e,0x00,0x00,0x00,0x00, - - 8, // 0x74 't' - 0x00,0x00,0x08,0x18,0x18,0x7e,0x18,0x18,0x18,0x18,0x1b,0x0e,0x00,0x00,0x00,0x00, - - 8, // 0x75 'u' - 0x00,0x00,0x00,0x00,0x00,0x66,0x66,0x66,0x66,0x66,0x66,0x3b,0x00,0x00,0x00,0x00, - - 8, // 0x76 'v' - 0x00,0x00,0x00,0x00,0x00,0x63,0x63,0x63,0x63,0x36,0x1c,0x08,0x00,0x00,0x00,0x00, - - 8, // 0x77 'w' - 0x00,0x00,0x00,0x00,0x00,0x63,0x63,0x6b,0x6b,0x7f,0x36,0x36,0x00,0x00,0x00,0x00, - - 8, // 0x78 'x' - 0x00,0x00,0x00,0x00,0x00,0x63,0x63,0x36,0x1c,0x36,0x63,0x63,0x00,0x00,0x00,0x00, - - 8, // 0x79 'y' - 0x00,0x00,0x00,0x00,0x00,0x63,0x63,0x63,0x63,0x63,0x63,0x3f,0x03,0x06,0x7c,0x00, - - 8, // 0x7a 'z' - 0x00,0x00,0x00,0x00,0x00,0x7f,0x63,0x06,0x0c,0x18,0x31,0x7f,0x00,0x00,0x00,0x00, - - 8, // 0x7b '{' - 0x00,0x03,0x04,0x0c,0x0c,0x0c,0x08,0x30,0x08,0x0c,0x0c,0x0c,0x04,0x03,0x00,0x00, - - 8, // 0x7c '|' - 0x00,0x00,0x0c,0x0c,0x0c,0x0c,0x0c,0x00,0x0c,0x0c,0x0c,0x0c,0x0c,0x00,0x00,0x00, - - 8, // 0x7d '}' - 0x00,0x60,0x10,0x18,0x18,0x18,0x08,0x06,0x08,0x18,0x18,0x18,0x10,0x60,0x00,0x00, - - 8, // 0x7e '~' - 0x00,0x00,0x3b,0x6e,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x7f '' - 0x00,0x00,0x00,0x00,0x00,0x08,0x1c,0x36,0x63,0x63,0x7f,0x00,0x00,0x00,0x00,0x00, - 0 - }; - - const int8u mcs11_prop[] = - { - 11, 2, 32, 128-32, - 0x00,0x00,0x0C,0x00,0x18,0x00,0x24,0x00,0x30,0x00,0x3C,0x00,0x48,0x00,0x54,0x00,0x60,0x00, - 0x6C,0x00,0x78,0x00,0x84,0x00,0x90,0x00,0x9C,0x00,0xA8,0x00,0xB4,0x00,0xC0,0x00,0xCC,0x00, - 0xD8,0x00,0xE4,0x00,0xF0,0x00,0xFC,0x00,0x08,0x01,0x14,0x01,0x20,0x01,0x2C,0x01,0x38,0x01, - 0x44,0x01,0x50,0x01,0x5C,0x01,0x68,0x01,0x74,0x01,0x80,0x01,0x8C,0x01,0x98,0x01,0xA4,0x01, - 0xB0,0x01,0xBC,0x01,0xC8,0x01,0xD4,0x01,0xE0,0x01,0xEC,0x01,0xF8,0x01,0x04,0x02,0x10,0x02, - 0x1C,0x02,0x28,0x02,0x34,0x02,0x40,0x02,0x4C,0x02,0x58,0x02,0x64,0x02,0x70,0x02,0x7C,0x02, - 0x88,0x02,0x94,0x02,0xA0,0x02,0xAC,0x02,0xB8,0x02,0xC4,0x02,0xD0,0x02,0xDC,0x02,0xE8,0x02, - 0xF4,0x02,0x00,0x03,0x0C,0x03,0x18,0x03,0x24,0x03,0x30,0x03,0x3C,0x03,0x48,0x03,0x54,0x03, - 0x60,0x03,0x6C,0x03,0x78,0x03,0x84,0x03,0x90,0x03,0x9C,0x03,0xA8,0x03,0xB4,0x03,0xC0,0x03, - 0xCC,0x03,0xD8,0x03,0xE4,0x03,0xF0,0x03,0xFC,0x03,0x08,0x04,0x14,0x04,0x20,0x04,0x2C,0x04, - 0x38,0x04,0x44,0x04,0x50,0x04,0x5C,0x04,0x68,0x04,0x74,0x04, - - 5, // 0x20 ' ' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 4, // 0x21 '!' - 0x00,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x00,0x20,0x00, - - 4, // 0x22 '"' - 0x50,0x50,0xA0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x23 '#' - 0x00,0x28,0x28,0x7C,0x28,0x28,0x28,0x7C,0x28,0x28,0x00, - - 6, // 0x24 '$' - 0x10,0x10,0x38,0x54,0x50,0x38,0x14,0x54,0x38,0x10,0x10, - - 6, // 0x25 '%' - 0x00,0x00,0x68,0xA8,0xD0,0x10,0x20,0x2C,0x54,0x58,0x00, - - 6, // 0x26 '&' - 0x00,0x20,0x50,0x50,0x50,0x20,0x54,0x54,0x48,0x34,0x00, - - 3, // 0x27 ''' - 0x40,0x40,0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 4, // 0x28 '(' - 0x10,0x20,0x20,0x40,0x40,0x40,0x40,0x40,0x20,0x20,0x10, - - 5, // 0x29 ')' - 0x40,0x20,0x20,0x10,0x10,0x10,0x10,0x10,0x20,0x20,0x40, - - 6, // 0x2A '*' - 0x00,0x00,0x28,0x7C,0x38,0x7C,0x28,0x00,0x00,0x00,0x00, - - 6, // 0x2B '+' - 0x00,0x00,0x00,0x10,0x10,0x7C,0x10,0x10,0x00,0x00,0x00, - - 4, // 0x2C ',' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x60,0x60,0xC0, - - 6, // 0x2D '-' - 0x00,0x00,0x00,0x00,0x00,0x7C,0x00,0x00,0x00,0x00,0x00, - - 4, // 0x2E '.' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x60,0x60,0x00, - - 7, // 0x2F '/' - 0x00,0x04,0x04,0x08,0x08,0x10,0x10,0x20,0x20,0x40,0x40, - - 6, // 0x30 '0' - 0x00,0x38,0x44,0x44,0x54,0x54,0x54,0x44,0x44,0x38,0x00, - - 4, // 0x31 '1' - 0x00,0x20,0x60,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x00, - - 6, // 0x32 '2' - 0x00,0x38,0x44,0x44,0x04,0x08,0x10,0x20,0x40,0x7C,0x00, - - 6, // 0x33 '3' - 0x00,0x38,0x44,0x04,0x04,0x38,0x04,0x04,0x44,0x38,0x00, - - 6, // 0x34 '4' - 0x00,0x08,0x18,0x18,0x28,0x28,0x48,0x7C,0x08,0x08,0x00, - - 6, // 0x35 '5' - 0x00,0x7C,0x40,0x40,0x78,0x44,0x04,0x04,0x44,0x38,0x00, - - 6, // 0x36 '6' - 0x00,0x38,0x44,0x40,0x40,0x78,0x44,0x44,0x44,0x38,0x00, - - 6, // 0x37 '7' - 0x00,0x7C,0x04,0x08,0x08,0x10,0x10,0x20,0x20,0x20,0x00, - - 6, // 0x38 '8' - 0x00,0x38,0x44,0x44,0x44,0x38,0x44,0x44,0x44,0x38,0x00, - - 6, // 0x39 '9' - 0x00,0x38,0x44,0x44,0x44,0x3C,0x04,0x04,0x44,0x38,0x00, - - 4, // 0x3A ':' - 0x00,0x00,0x00,0x60,0x60,0x00,0x00,0x00,0x60,0x60,0x00, - - 4, // 0x3B ';' - 0x00,0x00,0x00,0x60,0x60,0x00,0x00,0x00,0x60,0x60,0xC0, - - 6, // 0x3C '<' - 0x00,0x04,0x08,0x10,0x20,0x40,0x20,0x10,0x08,0x04,0x00, - - 6, // 0x3D '=' - 0x00,0x00,0x00,0x00,0x7C,0x00,0x00,0x7C,0x00,0x00,0x00, - - 6, // 0x3E '>' - 0x00,0x40,0x20,0x10,0x08,0x04,0x08,0x10,0x20,0x40,0x00, - - 6, // 0x3F '?' - 0x00,0x38,0x44,0x04,0x04,0x08,0x10,0x10,0x00,0x10,0x00, - - 6, // 0x40 '@' - 0x00,0x38,0x44,0x44,0x5C,0x54,0x54,0x4C,0x40,0x38,0x00, - - 6, // 0x41 'A' - 0x00,0x38,0x44,0x44,0x44,0x44,0x7C,0x44,0x44,0x44,0x00, - - 6, // 0x42 'B' - 0x00,0x78,0x44,0x44,0x44,0x78,0x44,0x44,0x44,0x78,0x00, - - 6, // 0x43 'C' - 0x00,0x38,0x44,0x40,0x40,0x40,0x40,0x40,0x44,0x38,0x00, - - 6, // 0x44 'D' - 0x00,0x70,0x48,0x44,0x44,0x44,0x44,0x44,0x48,0x70,0x00, - - 6, // 0x45 'E' - 0x00,0x7C,0x40,0x40,0x40,0x78,0x40,0x40,0x40,0x7C,0x00, - - 6, // 0x46 'F' - 0x00,0x7C,0x40,0x40,0x40,0x78,0x40,0x40,0x40,0x40,0x00, - - 6, // 0x47 'G' - 0x00,0x38,0x44,0x40,0x40,0x5C,0x44,0x44,0x4C,0x34,0x00, - - 6, // 0x48 'H' - 0x00,0x44,0x44,0x44,0x44,0x7C,0x44,0x44,0x44,0x44,0x00, - - 4, // 0x49 'I' - 0x00,0x70,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x70,0x00, - - 6, // 0x4A 'J' - 0x00,0x1C,0x08,0x08,0x08,0x08,0x08,0x08,0x48,0x30,0x00, - - 6, // 0x4B 'K' - 0x00,0x44,0x48,0x50,0x60,0x60,0x50,0x48,0x44,0x44,0x00, - - 6, // 0x4C 'L' - 0x00,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x7C,0x00, - - 8, // 0x4D 'M' - 0x00,0x41,0x63,0x55,0x49,0x49,0x41,0x41,0x41,0x41,0x00, - - 7, // 0x4E 'N' - 0x00,0x42,0x42,0x62,0x52,0x4A,0x46,0x42,0x42,0x42,0x00, - - 6, // 0x4F 'O' - 0x00,0x38,0x44,0x44,0x44,0x44,0x44,0x44,0x44,0x38,0x00, - - 6, // 0x50 'P' - 0x00,0x78,0x44,0x44,0x44,0x78,0x40,0x40,0x40,0x40,0x00, - - 6, // 0x51 'Q' - 0x00,0x38,0x44,0x44,0x44,0x44,0x44,0x54,0x48,0x34,0x00, - - 6, // 0x52 'R' - 0x00,0x78,0x44,0x44,0x44,0x78,0x44,0x44,0x44,0x44,0x00, - - 6, // 0x53 'S' - 0x00,0x38,0x44,0x40,0x40,0x38,0x04,0x04,0x44,0x38,0x00, - - 6, // 0x54 'T' - 0x00,0x7C,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x00, - - 6, // 0x55 'U' - 0x00,0x44,0x44,0x44,0x44,0x44,0x44,0x44,0x44,0x38,0x00, - - 6, // 0x56 'V' - 0x00,0x44,0x44,0x44,0x44,0x28,0x28,0x28,0x10,0x10,0x00, - - 8, // 0x57 'W' - 0x00,0x41,0x41,0x41,0x41,0x49,0x49,0x49,0x55,0x22,0x00, - - 6, // 0x58 'X' - 0x00,0x44,0x44,0x44,0x28,0x10,0x28,0x44,0x44,0x44,0x00, - - 6, // 0x59 'Y' - 0x00,0x44,0x44,0x44,0x28,0x10,0x10,0x10,0x10,0x10,0x00, - - 6, // 0x5A 'Z' - 0x00,0x7C,0x04,0x04,0x08,0x10,0x20,0x40,0x40,0x7C,0x00, - - 5, // 0x5B '[' - 0x30,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x30, - - 7, // 0x5C '\' - 0x40,0x40,0x20,0x20,0x10,0x10,0x08,0x08,0x04,0x04,0x00, - - 4, // 0x5D ']' - 0x60,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x60, - - 6, // 0x5E '^' - 0x00,0x10,0x28,0x44,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x5F '_' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7C,0x00, - - 4, // 0x60 '`' - 0x00,0x40,0x40,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x61 'a' - 0x00,0x00,0x00,0x38,0x04,0x3C,0x44,0x44,0x44,0x3C,0x00, - - 6, // 0x62 'b' - 0x00,0x40,0x40,0x78,0x44,0x44,0x44,0x44,0x44,0x78,0x00, - - 6, // 0x63 'c' - 0x00,0x00,0x00,0x38,0x44,0x40,0x40,0x40,0x44,0x38,0x00, - - 6, // 0x64 'd' - 0x00,0x04,0x04,0x3C,0x44,0x44,0x44,0x44,0x44,0x3C,0x00, - - 6, // 0x65 'e' - 0x00,0x00,0x00,0x38,0x44,0x44,0x7C,0x40,0x44,0x38,0x00, - - 4, // 0x66 'f' - 0x00,0x10,0x20,0x70,0x20,0x20,0x20,0x20,0x20,0x20,0x00, - - 6, // 0x67 'g' - 0x00,0x00,0x00,0x3C,0x44,0x44,0x44,0x3C,0x04,0x44,0x38, - - 6, // 0x68 'h' - 0x00,0x40,0x40,0x78,0x44,0x44,0x44,0x44,0x44,0x44,0x00, - - 2, // 0x69 'i' - 0x00,0x40,0x00,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x00, - - 3, // 0x6A 'j' - 0x00,0x20,0x00,0x20,0x20,0x20,0x20,0x20,0x20,0xA0,0x40, - - 5, // 0x6B 'k' - 0x00,0x40,0x40,0x48,0x50,0x60,0x60,0x50,0x48,0x48,0x00, - - 2, // 0x6C 'l' - 0x00,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x00, - - 8, // 0x6D 'm' - 0x00,0x00,0x00,0x76,0x49,0x49,0x49,0x49,0x41,0x41,0x00, - - 6, // 0x6E 'n' - 0x00,0x00,0x00,0x78,0x44,0x44,0x44,0x44,0x44,0x44,0x00, - - 6, // 0x6F 'o' - 0x00,0x00,0x00,0x38,0x44,0x44,0x44,0x44,0x44,0x38,0x00, - - 6, // 0x70 'p' - 0x00,0x00,0x00,0x78,0x44,0x44,0x44,0x44,0x78,0x40,0x40, - - 6, // 0x71 'q' - 0x00,0x00,0x00,0x3C,0x44,0x44,0x44,0x44,0x3C,0x04,0x04, - - 6, // 0x72 'r' - 0x00,0x00,0x00,0x58,0x24,0x20,0x20,0x20,0x20,0x20,0x00, - - 6, // 0x73 's' - 0x00,0x00,0x00,0x38,0x44,0x40,0x38,0x04,0x44,0x38,0x00, - - 5, // 0x74 't' - 0x00,0x20,0x20,0x70,0x20,0x20,0x20,0x20,0x28,0x10,0x00, - - 6, // 0x75 'u' - 0x00,0x00,0x00,0x44,0x44,0x44,0x44,0x44,0x4C,0x34,0x00, - - 6, // 0x76 'v' - 0x00,0x00,0x00,0x44,0x44,0x44,0x28,0x28,0x10,0x10,0x00, - - 8, // 0x77 'w' - 0x00,0x00,0x00,0x41,0x41,0x41,0x41,0x49,0x49,0x36,0x00, - - 6, // 0x78 'x' - 0x00,0x00,0x00,0x44,0x44,0x28,0x10,0x28,0x44,0x44,0x00, - - 6, // 0x79 'y' - 0x00,0x00,0x00,0x44,0x44,0x44,0x44,0x3C,0x04,0x08,0x70, - - 6, // 0x7A 'z' - 0x00,0x00,0x00,0x7C,0x04,0x08,0x10,0x20,0x40,0x7C,0x00, - - 5, // 0x7B '{' - 0x18,0x20,0x20,0x20,0x20,0xC0,0x20,0x20,0x20,0x20,0x18, - - 3, // 0x7C '|' - 0x00,0x40,0x40,0x40,0x40,0x00,0x40,0x40,0x40,0x40,0x00, - - 5, // 0x7D '}' - 0xC0,0x20,0x20,0x20,0x20,0x18,0x20,0x20,0x20,0x20,0xC0, - - 6, // 0x7E '~' - 0x00,0x24,0x54,0x48,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x7F '' - 0x00,0x10,0x38,0x6C,0x44,0x44,0x7C,0x00,0x00,0x00,0x00, - - 0 - }; - - const int8u mcs11_prop_condensed[] = - { - 11, 2, 32, 128-32, - 0x00,0x00,0x0C,0x00,0x18,0x00,0x24,0x00,0x30,0x00,0x3C,0x00,0x48,0x00,0x54,0x00,0x60,0x00, - 0x6C,0x00,0x78,0x00,0x84,0x00,0x90,0x00,0x9C,0x00,0xA8,0x00,0xB4,0x00,0xC0,0x00,0xCC,0x00, - 0xD8,0x00,0xE4,0x00,0xF0,0x00,0xFC,0x00,0x08,0x01,0x14,0x01,0x20,0x01,0x2C,0x01,0x38,0x01, - 0x44,0x01,0x50,0x01,0x5C,0x01,0x68,0x01,0x74,0x01,0x80,0x01,0x8C,0x01,0x98,0x01,0xA4,0x01, - 0xB0,0x01,0xBC,0x01,0xC8,0x01,0xD4,0x01,0xE0,0x01,0xEC,0x01,0xF8,0x01,0x04,0x02,0x10,0x02, - 0x1C,0x02,0x28,0x02,0x34,0x02,0x40,0x02,0x4C,0x02,0x58,0x02,0x64,0x02,0x70,0x02,0x7C,0x02, - 0x88,0x02,0x94,0x02,0xA0,0x02,0xAC,0x02,0xB8,0x02,0xC4,0x02,0xD0,0x02,0xDC,0x02,0xE8,0x02, - 0xF4,0x02,0x00,0x03,0x0C,0x03,0x18,0x03,0x24,0x03,0x30,0x03,0x3C,0x03,0x48,0x03,0x54,0x03, - 0x60,0x03,0x6C,0x03,0x78,0x03,0x84,0x03,0x90,0x03,0x9C,0x03,0xA8,0x03,0xB4,0x03,0xC0,0x03, - 0xCC,0x03,0xD8,0x03,0xE4,0x03,0xF0,0x03,0xFC,0x03,0x08,0x04,0x14,0x04,0x20,0x04,0x2C,0x04, - 0x38,0x04,0x44,0x04,0x50,0x04,0x5C,0x04,0x68,0x04,0x74,0x04, - - 3, // 0x20 ' ' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 3, // 0x21 '!' - 0x00,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x00,0x40,0x00, - - 4, // 0x22 '"' - 0x50,0x50,0xA0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x23 '#' - 0x00,0x50,0x50,0xF8,0x50,0x50,0x50,0xF8,0x50,0x50,0x00, - - 5, // 0x24 '$' - 0x00,0x40,0x60,0x90,0x80,0x60,0x10,0x90,0x60,0x20,0x00, - - 5, // 0x25 '%' - 0x00,0x00,0x90,0x90,0x20,0x20,0x40,0x40,0x90,0x90,0x00, - - 5, // 0x26 '&' - 0x00,0x40,0xA0,0xA0,0xA0,0x40,0xA8,0x90,0x90,0x68,0x00, - - 5, // 0x27 ''' - 0x00,0x00,0x20,0x40,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x28 '(' - 0x10,0x20,0x20,0x40,0x40,0x40,0x40,0x40,0x20,0x20,0x10, - - 4, // 0x29 ')' - 0x80,0x40,0x40,0x20,0x20,0x20,0x20,0x20,0x40,0x40,0x80, - - 5, // 0x2A '*' - 0x00,0x00,0x90,0x60,0xF0,0x60,0x90,0x00,0x00,0x00,0x00, - - 5, // 0x2B '+' - 0x00,0x00,0x00,0x20,0x20,0xF8,0x20,0x20,0x00,0x00,0x00, - - 4, // 0x2C ',' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x60,0x60,0xC0, - - 5, // 0x2D '-' - 0x00,0x00,0x00,0x00,0x00,0xF0,0x00,0x00,0x00,0x00,0x00, - - 4, // 0x2E '.' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xC0,0xC0,0x00, - - 6, // 0x2F '/' - 0x08,0x08,0x10,0x10,0x20,0x20,0x40,0x40,0x80,0x80,0x00, - - 5, // 0x30 '0' - 0x00,0x70,0x90,0x90,0x90,0x90,0x90,0x90,0x90,0xE0,0x00, - - 3, // 0x31 '1' - 0x00,0x40,0xC0,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x00, - - 5, // 0x32 '2' - 0x00,0x60,0x90,0x90,0x10,0x10,0x20,0x40,0x80,0xF0,0x00, - - 5, // 0x33 '3' - 0x00,0x60,0x90,0x10,0x10,0x60,0x10,0x10,0x90,0x60,0x00, - - 5, // 0x34 '4' - 0x00,0x10,0x30,0x30,0x50,0x50,0x90,0xF0,0x10,0x10,0x00, - - 5, // 0x35 '5' - 0x00,0xF0,0x80,0x80,0xE0,0x90,0x10,0x10,0x90,0x60,0x00, - - 5, // 0x36 '6' - 0x00,0x60,0x90,0x80,0x80,0xE0,0x90,0x90,0x90,0x60,0x00, - - 5, // 0x37 '7' - 0x00,0xF0,0x10,0x10,0x10,0x20,0x20,0x40,0x40,0x40,0x00, - - 5, // 0x38 '8' - 0x00,0x60,0x90,0x90,0x90,0x60,0x90,0x90,0x90,0x60,0x00, - - 5, // 0x39 '9' - 0x00,0x60,0x90,0x90,0x90,0x70,0x10,0x10,0x90,0x60,0x00, - - 4, // 0x3A ':' - 0x00,0x00,0x00,0x60,0x60,0x00,0x00,0x00,0x60,0x60,0x00, - - 4, // 0x3B ';' - 0x00,0x00,0x00,0x60,0x60,0x00,0x00,0x00,0x60,0x60,0xC0, - - 6, // 0x3C '<' - 0x00,0x08,0x10,0x20,0x40,0x80,0x40,0x20,0x10,0x08,0x00, - - 5, // 0x3D '=' - 0x00,0x00,0x00,0x00,0xF0,0x00,0x00,0xF0,0x00,0x00,0x00, - - 6, // 0x3E '>' - 0x00,0x80,0x40,0x20,0x10,0x08,0x10,0x20,0x40,0x80,0x00, - - 5, // 0x3F '?' - 0x00,0x60,0x90,0x10,0x10,0x20,0x40,0x00,0x40,0x00,0x00, - - 5, // 0x40 '@' - 0x00,0x60,0x90,0x90,0xB0,0xB0,0xB0,0x80,0x80,0x70,0x00, - - 5, // 0x41 'A' - 0x00,0x60,0x90,0x90,0x90,0xF0,0x90,0x90,0x90,0x90,0x00, - - 5, // 0x42 'B' - 0x00,0xE0,0x90,0x90,0x90,0xE0,0x90,0x90,0x90,0xE0,0x00, - - 5, // 0x43 'C' - 0x00,0x60,0x90,0x80,0x80,0x80,0x80,0x80,0x90,0x60,0x00, - - 5, // 0x44 'D' - 0x00,0xE0,0x90,0x90,0x90,0x90,0x90,0x90,0x90,0xE0,0x00, - - 5, // 0x45 'E' - 0x00,0xF0,0x80,0x80,0x80,0xF0,0x80,0x80,0x80,0xF0,0x00, - - 5, // 0x46 'F' - 0x00,0xF0,0x80,0x80,0x80,0xF0,0x80,0x80,0x80,0x80,0x00, - - 5, // 0x47 'G' - 0x00,0x70,0x80,0x80,0x80,0xB0,0x90,0x90,0x90,0x60,0x00, - - 5, // 0x48 'H' - 0x00,0x90,0x90,0x90,0x90,0xF0,0x90,0x90,0x90,0x90,0x00, - - 4, // 0x49 'I' - 0x00,0xE0,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0xE0,0x00, - - 5, // 0x4A 'J' - 0x00,0x70,0x20,0x20,0x20,0x20,0x20,0xA0,0xA0,0x40,0x00, - - 5, // 0x4B 'K' - 0x00,0x90,0x90,0xA0,0xA0,0xC0,0xA0,0xA0,0x90,0x90,0x00, - - 5, // 0x4C 'L' - 0x00,0x80,0x80,0x80,0x80,0x80,0x80,0x80,0x80,0xF0,0x00, - - 6, // 0x4D 'M' - 0x00,0x88,0xD8,0xA8,0xA8,0xA8,0x88,0x88,0x88,0x88,0x00, - - 5, // 0x4E 'N' - 0x00,0x90,0x90,0xD0,0xD0,0xB0,0xB0,0x90,0x90,0x90,0x00, - - 5, // 0x4F 'O' - 0x00,0x60,0x90,0x90,0x90,0x90,0x90,0x90,0x90,0x60,0x00, - - 5, // 0x50 'P' - 0x00,0xE0,0x90,0x90,0x90,0x90,0xE0,0x80,0x80,0x80,0x00, - - 5, // 0x51 'Q' - 0x00,0x60,0x90,0x90,0x90,0x90,0x90,0x90,0x90,0x60,0x30, - - 5, // 0x52 'R' - 0x00,0xE0,0x90,0x90,0x90,0x90,0xE0,0xA0,0x90,0x90,0x00, - - 5, // 0x53 'S' - 0x00,0x60,0x90,0x80,0x80,0x60,0x10,0x10,0x90,0x60,0x00, - - 6, // 0x54 'T' - 0x00,0xF8,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x00, - - 5, // 0x55 'U' - 0x00,0x90,0x90,0x90,0x90,0x90,0x90,0x90,0x90,0x60,0x00, - - 6, // 0x56 'V' - 0x00,0x88,0x88,0x88,0x88,0x50,0x50,0x50,0x20,0x20,0x00, - - 6, // 0x57 'W' - 0x00,0x88,0x88,0x88,0xA8,0xA8,0xA8,0xA8,0xA8,0x50,0x00, - - 5, // 0x58 'X' - 0x00,0x90,0x90,0x90,0x60,0x60,0x90,0x90,0x90,0x90,0x00, - - 6, // 0x59 'Y' - 0x00,0x88,0x88,0x88,0x50,0x20,0x20,0x20,0x20,0x20,0x00, - - 5, // 0x5A 'Z' - 0x00,0xF0,0x10,0x20,0x20,0x40,0x40,0x80,0x80,0xF0,0x00, - - 4, // 0x5B '[' - 0x60,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x60,0x00, - - 6, // 0x5C '\' - 0x80,0x80,0x40,0x40,0x20,0x20,0x10,0x10,0x08,0x08,0x00, - - 4, // 0x5D ']' - 0x60,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x60,0x00, - - 5, // 0x5E '^' - 0x00,0x20,0x50,0x88,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x5F '_' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xF0,0x00, - - 5, // 0x60 '`' - 0x00,0x40,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x61 'a' - 0x00,0x00,0x00,0x60,0x90,0x10,0x70,0x90,0x90,0x70,0x00, - - 5, // 0x62 'b' - 0x00,0x80,0x80,0x80,0xE0,0x90,0x90,0x90,0x90,0xE0,0x00, - - 5, // 0x63 'c' - 0x00,0x00,0x00,0x60,0x90,0x80,0x80,0x80,0x90,0x60,0x00, - - 5, // 0x64 'd' - 0x00,0x10,0x10,0x10,0x70,0x90,0x90,0x90,0x90,0x70,0x00, - - 5, // 0x65 'e' - 0x00,0x00,0x00,0x60,0x90,0x90,0xF0,0x80,0x90,0x60,0x00, - - 4, // 0x66 'f' - 0x00,0x20,0x40,0x40,0xE0,0x40,0x40,0x40,0x40,0x40,0x00, - - 5, // 0x67 'g' - 0x00,0x00,0x00,0x70,0x90,0x90,0x90,0x70,0x10,0x90,0x60, - - 5, // 0x68 'h' - 0x00,0x80,0x80,0x80,0xE0,0x90,0x90,0x90,0x90,0x90,0x00, - - 2, // 0x69 'i' - 0x00,0x80,0x00,0x80,0x80,0x80,0x80,0x80,0x80,0x80,0x00, - - 4, // 0x6A 'j' - 0x00,0x20,0x00,0x20,0x20,0x20,0x20,0x20,0x20,0xA0,0x40, - - 5, // 0x6B 'k' - 0x00,0x80,0x80,0x90,0x90,0xA0,0xC0,0xA0,0x90,0x90,0x00, - - 2, // 0x6C 'l' - 0x00,0x80,0x80,0x80,0x80,0x80,0x80,0x80,0x80,0x80,0x00, - - 6, // 0x6D 'm' - 0x00,0x00,0x00,0xD0,0xA8,0xA8,0xA8,0x88,0x88,0x88,0x00, - - 5, // 0x6E 'n' - 0x00,0x00,0x00,0xA0,0xD0,0x90,0x90,0x90,0x90,0x90,0x00, - - 5, // 0x6F 'o' - 0x00,0x00,0x00,0x60,0x90,0x90,0x90,0x90,0x90,0x60,0x00, - - 5, // 0x70 'p' - 0x00,0x00,0x00,0xE0,0x90,0x90,0x90,0x90,0xE0,0x80,0x80, - - 5, // 0x71 'q' - 0x00,0x00,0x00,0x70,0x90,0x90,0x90,0x90,0x70,0x10,0x10, - - 6, // 0x72 'r' - 0x00,0x00,0x00,0xB8,0x48,0x40,0x40,0x40,0x40,0x40,0x00, - - 5, // 0x73 's' - 0x00,0x00,0x00,0x60,0x90,0x40,0x20,0x10,0x90,0x60,0x00, - - 4, // 0x74 't' - 0x00,0x40,0x40,0xE0,0x40,0x40,0x40,0x40,0x40,0x20,0x00, - - 5, // 0x75 'u' - 0x00,0x00,0x00,0x90,0x90,0x90,0x90,0x90,0x90,0x70,0x00, - - 6, // 0x76 'v' - 0x00,0x00,0x00,0x88,0x88,0x88,0x50,0x50,0x20,0x20,0x00, - - 6, // 0x77 'w' - 0x00,0x00,0x00,0x88,0x88,0x88,0xA8,0xA8,0xA8,0x50,0x00, - - 5, // 0x78 'x' - 0x00,0x00,0x00,0x90,0x90,0x60,0x60,0x90,0x90,0x90,0x00, - - 5, // 0x79 'y' - 0x00,0x00,0x00,0x90,0x90,0x90,0x90,0x70,0x10,0x20,0xC0, - - 5, // 0x7A 'z' - 0x00,0x00,0x00,0xF0,0x10,0x20,0x40,0x80,0x80,0xF0,0x00, - - 5, // 0x7B '{' - 0x30,0x40,0x40,0x40,0x40,0x80,0x40,0x40,0x40,0x40,0x30, - - 3, // 0x7C '|' - 0x00,0x40,0x40,0x40,0x40,0x00,0x40,0x40,0x40,0x40,0x00, - - 5, // 0x7D '}' - 0xC0,0x20,0x20,0x20,0x20,0x10,0x20,0x20,0x20,0x20,0xC0, - - 5, // 0x7E '~' - 0x00,0x40,0xA8,0x10,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x7F '' - 0x00,0x20,0x70,0xD8,0x88,0x88,0xF8,0x00,0x00,0x00,0x00, - - 0 - }; - - const int8u mcs12_prop[] = - { - 12, 3, 32, 128-32, - 0x00,0x00,0x0D,0x00,0x1A,0x00,0x27,0x00,0x34,0x00,0x41,0x00,0x4E,0x00,0x5B,0x00,0x68,0x00, - 0x75,0x00,0x82,0x00,0x8F,0x00,0x9C,0x00,0xA9,0x00,0xB6,0x00,0xC3,0x00,0xD0,0x00,0xDD,0x00, - 0xEA,0x00,0xF7,0x00,0x04,0x01,0x11,0x01,0x1E,0x01,0x2B,0x01,0x38,0x01,0x45,0x01,0x52,0x01, - 0x5F,0x01,0x6C,0x01,0x79,0x01,0x86,0x01,0x93,0x01,0xA0,0x01,0xAD,0x01,0xBA,0x01,0xC7,0x01, - 0xD4,0x01,0xE1,0x01,0xEE,0x01,0xFB,0x01,0x08,0x02,0x15,0x02,0x22,0x02,0x2F,0x02,0x3C,0x02, - 0x49,0x02,0x62,0x02,0x6F,0x02,0x7C,0x02,0x89,0x02,0x96,0x02,0xA3,0x02,0xB0,0x02,0xBD,0x02, - 0xCA,0x02,0xD7,0x02,0xF0,0x02,0xFD,0x02,0x0A,0x03,0x17,0x03,0x24,0x03,0x31,0x03,0x3E,0x03, - 0x4B,0x03,0x58,0x03,0x65,0x03,0x72,0x03,0x7F,0x03,0x8C,0x03,0x99,0x03,0xA6,0x03,0xB3,0x03, - 0xC0,0x03,0xCD,0x03,0xDA,0x03,0xE7,0x03,0xF4,0x03,0x01,0x04,0x1A,0x04,0x27,0x04,0x34,0x04, - 0x41,0x04,0x4E,0x04,0x5B,0x04,0x68,0x04,0x75,0x04,0x82,0x04,0x8F,0x04,0xA8,0x04,0xB5,0x04, - 0xC2,0x04,0xCF,0x04,0xDC,0x04,0xE9,0x04,0xF6,0x04,0x03,0x05, - - 5, // 0x20 ' ' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 4, // 0x21 '!' - 0x00,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x00,0x20,0x00,0x00, - - 4, // 0x22 '"' - 0x50,0x50,0xA0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x23 '#' - 0x28,0x28,0x28,0x7C,0x28,0x28,0x28,0x7C,0x28,0x28,0x28,0x00, - - 6, // 0x24 '$' - 0x10,0x10,0x38,0x54,0x50,0x38,0x14,0x54,0x38,0x10,0x10,0x00, - - 7, // 0x25 '%' - 0x32,0x54,0x64,0x08,0x08,0x10,0x10,0x26,0x2A,0x4C,0x00,0x00, - - 7, // 0x26 '&' - 0x00,0x30,0x48,0x48,0x48,0x30,0x4A,0x4A,0x44,0x3A,0x00,0x00, - - 3, // 0x27 ''' - 0x40,0x40,0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x28 '(' - 0x10,0x20,0x20,0x40,0x40,0x40,0x40,0x40,0x20,0x20,0x10,0x00, - - 5, // 0x29 ')' - 0x40,0x20,0x20,0x10,0x10,0x10,0x10,0x10,0x20,0x20,0x40,0x00, - - 6, // 0x2A '*' - 0x00,0x00,0x10,0x54,0x38,0x7C,0x38,0x54,0x10,0x00,0x00,0x00, - - 6, // 0x2B '+' - 0x00,0x00,0x00,0x00,0x10,0x10,0x7C,0x10,0x10,0x00,0x00,0x00, - - 4, // 0x2C ',' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x60,0x60,0x40,0x80, - - 6, // 0x2D '-' - 0x00,0x00,0x00,0x00,0x00,0x00,0x7C,0x00,0x00,0x00,0x00,0x00, - - 4, // 0x2E '.' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x60,0x60,0x00,0x00, - - 7, // 0x2F '/' - 0x00,0x04,0x04,0x08,0x08,0x10,0x10,0x20,0x20,0x40,0x40,0x00, - - 7, // 0x30 '0' - 0x00,0x38,0x44,0x44,0x54,0x54,0x54,0x44,0x44,0x38,0x00,0x00, - - 4, // 0x31 '1' - 0x00,0x20,0x60,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x00,0x00, - - 7, // 0x32 '2' - 0x00,0x38,0x44,0x04,0x04,0x08,0x10,0x20,0x40,0x7C,0x00,0x00, - - 7, // 0x33 '3' - 0x00,0x38,0x44,0x04,0x04,0x38,0x04,0x04,0x44,0x38,0x00,0x00, - - 6, // 0x34 '4' - 0x00,0x08,0x18,0x28,0x28,0x48,0x48,0x7C,0x08,0x08,0x00,0x00, - - 7, // 0x35 '5' - 0x00,0x7C,0x40,0x40,0x78,0x44,0x04,0x04,0x44,0x38,0x00,0x00, - - 7, // 0x36 '6' - 0x00,0x38,0x44,0x40,0x78,0x44,0x44,0x44,0x44,0x38,0x00,0x00, - - 6, // 0x37 '7' - 0x00,0x7C,0x04,0x08,0x08,0x10,0x10,0x20,0x20,0x20,0x00,0x00, - - 7, // 0x38 '8' - 0x00,0x38,0x44,0x44,0x44,0x38,0x44,0x44,0x44,0x38,0x00,0x00, - - 7, // 0x39 '9' - 0x00,0x38,0x44,0x44,0x44,0x3C,0x04,0x04,0x44,0x38,0x00,0x00, - - 4, // 0x3A ':' - 0x00,0x00,0x00,0x60,0x60,0x00,0x00,0x00,0x60,0x60,0x00,0x00, - - 4, // 0x3B ';' - 0x00,0x00,0x00,0x60,0x60,0x00,0x00,0x00,0x60,0x60,0x40,0x80, - - 6, // 0x3C '<' - 0x00,0x00,0x04,0x08,0x10,0x20,0x40,0x20,0x10,0x08,0x04,0x00, - - 6, // 0x3D '=' - 0x00,0x00,0x00,0x00,0x7C,0x00,0x00,0x7C,0x00,0x00,0x00,0x00, - - 6, // 0x3E '>' - 0x00,0x00,0x40,0x20,0x10,0x08,0x04,0x08,0x10,0x20,0x40,0x00, - - 6, // 0x3F '?' - 0x00,0x38,0x44,0x04,0x04,0x08,0x10,0x10,0x00,0x10,0x00,0x00, - - 7, // 0x40 '@' - 0x00,0x38,0x44,0x44,0x5C,0x54,0x54,0x4C,0x40,0x38,0x00,0x00, - - 7, // 0x41 'A' - 0x00,0x38,0x44,0x44,0x44,0x7C,0x44,0x44,0x44,0x44,0x00,0x00, - - 7, // 0x42 'B' - 0x00,0x78,0x44,0x44,0x44,0x78,0x44,0x44,0x44,0x78,0x00,0x00, - - 6, // 0x43 'C' - 0x00,0x38,0x44,0x40,0x40,0x40,0x40,0x40,0x44,0x38,0x00,0x00, - - 7, // 0x44 'D' - 0x00,0x70,0x48,0x44,0x44,0x44,0x44,0x44,0x48,0x70,0x00,0x00, - - 6, // 0x45 'E' - 0x00,0x7C,0x40,0x40,0x40,0x78,0x40,0x40,0x40,0x7C,0x00,0x00, - - 6, // 0x46 'F' - 0x00,0x7C,0x40,0x40,0x40,0x78,0x40,0x40,0x40,0x40,0x00,0x00, - - 7, // 0x47 'G' - 0x00,0x38,0x44,0x40,0x40,0x5C,0x44,0x44,0x4C,0x34,0x00,0x00, - - 7, // 0x48 'H' - 0x00,0x44,0x44,0x44,0x44,0x7C,0x44,0x44,0x44,0x44,0x00,0x00, - - 5, // 0x49 'I' - 0x00,0x70,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x70,0x00,0x00, - - 6, // 0x4A 'J' - 0x00,0x1C,0x08,0x08,0x08,0x08,0x08,0x48,0x48,0x30,0x00,0x00, - - 6, // 0x4B 'K' - 0x00,0x44,0x48,0x50,0x60,0x60,0x50,0x48,0x44,0x44,0x00,0x00, - - 6, // 0x4C 'L' - 0x00,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x7C,0x00,0x00, - - 9, // 0x4D 'M' - 0x00,0x00,0x41,0x00,0x63,0x00,0x55,0x00,0x49,0x00,0x49,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x4E 'N' - 0x00,0x44,0x64,0x64,0x54,0x54,0x4C,0x4C,0x44,0x44,0x00,0x00, - - 7, // 0x4F 'O' - 0x00,0x38,0x44,0x44,0x44,0x44,0x44,0x44,0x44,0x38,0x00,0x00, - - 7, // 0x50 'P' - 0x00,0x78,0x44,0x44,0x44,0x44,0x78,0x40,0x40,0x40,0x00,0x00, - - 7, // 0x51 'Q' - 0x00,0x38,0x44,0x44,0x44,0x44,0x44,0x54,0x48,0x34,0x00,0x00, - - 7, // 0x52 'R' - 0x00,0x78,0x44,0x44,0x44,0x44,0x78,0x48,0x44,0x44,0x00,0x00, - - 7, // 0x53 'S' - 0x00,0x38,0x44,0x40,0x40,0x38,0x04,0x04,0x44,0x38,0x00,0x00, - - 6, // 0x54 'T' - 0x00,0x7C,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x00,0x00, - - 7, // 0x55 'U' - 0x00,0x44,0x44,0x44,0x44,0x44,0x44,0x44,0x44,0x38,0x00,0x00, - - 6, // 0x56 'V' - 0x00,0x44,0x44,0x44,0x44,0x28,0x28,0x28,0x10,0x10,0x00,0x00, - - 9, // 0x57 'W' - 0x00,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x49,0x00,0x49,0x00,0x55,0x00,0x22,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x58 'X' - 0x00,0x44,0x44,0x44,0x28,0x10,0x28,0x44,0x44,0x44,0x00,0x00, - - 7, // 0x59 'Y' - 0x00,0x44,0x44,0x44,0x44,0x28,0x10,0x10,0x10,0x10,0x00,0x00, - - 6, // 0x5A 'Z' - 0x00,0x7C,0x04,0x04,0x08,0x10,0x20,0x40,0x40,0x7C,0x00,0x00, - - 4, // 0x5B '[' - 0x70,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x70,0x00, - - 7, // 0x5C '\' - 0x00,0x40,0x40,0x20,0x20,0x10,0x10,0x08,0x08,0x04,0x04,0x00, - - 4, // 0x5D ']' - 0xE0,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0xE0,0x00, - - 6, // 0x5E '^' - 0x00,0x10,0x28,0x44,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x5F '_' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7C,0x00,0x00, - - 4, // 0x60 '`' - 0x00,0x40,0x40,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x61 'a' - 0x00,0x00,0x00,0x38,0x04,0x3C,0x44,0x44,0x44,0x3C,0x00,0x00, - - 7, // 0x62 'b' - 0x00,0x40,0x40,0x78,0x44,0x44,0x44,0x44,0x44,0x78,0x00,0x00, - - 6, // 0x63 'c' - 0x00,0x00,0x00,0x38,0x44,0x40,0x40,0x40,0x44,0x38,0x00,0x00, - - 7, // 0x64 'd' - 0x00,0x04,0x04,0x3C,0x44,0x44,0x44,0x44,0x44,0x3C,0x00,0x00, - - 7, // 0x65 'e' - 0x00,0x00,0x00,0x38,0x44,0x44,0x7C,0x40,0x44,0x38,0x00,0x00, - - 4, // 0x66 'f' - 0x00,0x30,0x40,0xE0,0x40,0x40,0x40,0x40,0x40,0x40,0x00,0x00, - - 7, // 0x67 'g' - 0x00,0x00,0x00,0x3C,0x44,0x44,0x44,0x44,0x44,0x3C,0x04,0x78, - - 7, // 0x68 'h' - 0x00,0x40,0x40,0x78,0x44,0x44,0x44,0x44,0x44,0x44,0x00,0x00, - - 3, // 0x69 'i' - 0x00,0x40,0x00,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x00,0x00, - - 5, // 0x6A 'j' - 0x00,0x10,0x00,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x90,0x60, - - 6, // 0x6B 'k' - 0x00,0x40,0x40,0x44,0x48,0x50,0x60,0x50,0x48,0x44,0x00,0x00, - - 3, // 0x6C 'l' - 0x00,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x00,0x00, - - 9, // 0x6D 'm' - 0x00,0x00,0x00,0x00,0x00,0x00,0x76,0x00,0x49,0x00,0x49,0x00,0x49,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x6E 'n' - 0x00,0x00,0x00,0x58,0x64,0x44,0x44,0x44,0x44,0x44,0x00,0x00, - - 7, // 0x6F 'o' - 0x00,0x00,0x00,0x38,0x44,0x44,0x44,0x44,0x44,0x38,0x00,0x00, - - 7, // 0x70 'p' - 0x00,0x00,0x00,0x78,0x44,0x44,0x44,0x44,0x44,0x78,0x40,0x40, - - 7, // 0x71 'q' - 0x00,0x00,0x00,0x3C,0x44,0x44,0x44,0x44,0x44,0x3C,0x04,0x04, - - 6, // 0x72 'r' - 0x00,0x00,0x00,0x58,0x24,0x20,0x20,0x20,0x20,0x70,0x00,0x00, - - 7, // 0x73 's' - 0x00,0x00,0x00,0x38,0x44,0x40,0x38,0x04,0x44,0x38,0x00,0x00, - - 5, // 0x74 't' - 0x00,0x20,0x20,0x70,0x20,0x20,0x20,0x20,0x20,0x18,0x00,0x00, - - 7, // 0x75 'u' - 0x00,0x00,0x00,0x44,0x44,0x44,0x44,0x44,0x4C,0x34,0x00,0x00, - - 6, // 0x76 'v' - 0x00,0x00,0x00,0x44,0x44,0x44,0x28,0x28,0x10,0x10,0x00,0x00, - - 9, // 0x77 'w' - 0x00,0x00,0x00,0x00,0x00,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x49,0x00,0x49,0x00,0x49,0x00,0x36,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x78 'x' - 0x00,0x00,0x00,0x44,0x44,0x28,0x10,0x28,0x44,0x44,0x00,0x00, - - 7, // 0x79 'y' - 0x00,0x00,0x00,0x44,0x44,0x44,0x44,0x44,0x44,0x3C,0x08,0x70, - - 6, // 0x7A 'z' - 0x00,0x00,0x00,0x7C,0x04,0x08,0x10,0x20,0x40,0x7C,0x00,0x00, - - 5, // 0x7B '{' - 0x18,0x20,0x20,0x20,0x20,0xC0,0x20,0x20,0x20,0x20,0x18,0x00, - - 3, // 0x7C '|' - 0x00,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x00, - - 5, // 0x7D '}' - 0xC0,0x20,0x20,0x20,0x20,0x18,0x20,0x20,0x20,0x20,0xC0,0x00, - - 7, // 0x7E '~' - 0x00,0x60,0x92,0x92,0x0C,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x7F '' - 0x00,0x10,0x38,0x6C,0x44,0x44,0x7C,0x00,0x00,0x00,0x00,0x00, - - 0 - }; - - const int8u mcs13_prop[] = - { - 13, 4, 32, 128-32, - 0x00,0x00,0x0E,0x00,0x1C,0x00,0x2A,0x00,0x38,0x00,0x46,0x00,0x54,0x00,0x62,0x00,0x70,0x00, - 0x7E,0x00,0x8C,0x00,0x9A,0x00,0xA8,0x00,0xB6,0x00,0xC4,0x00,0xD2,0x00,0xE0,0x00,0xEE,0x00, - 0xFC,0x00,0x0A,0x01,0x18,0x01,0x26,0x01,0x34,0x01,0x42,0x01,0x50,0x01,0x5E,0x01,0x6C,0x01, - 0x7A,0x01,0x88,0x01,0x96,0x01,0xA4,0x01,0xB2,0x01,0xC0,0x01,0xCE,0x01,0xDC,0x01,0xEA,0x01, - 0xF8,0x01,0x06,0x02,0x14,0x02,0x22,0x02,0x30,0x02,0x3E,0x02,0x4C,0x02,0x5A,0x02,0x68,0x02, - 0x76,0x02,0x91,0x02,0x9F,0x02,0xAD,0x02,0xBB,0x02,0xC9,0x02,0xD7,0x02,0xE5,0x02,0xF3,0x02, - 0x01,0x03,0x0F,0x03,0x2A,0x03,0x38,0x03,0x46,0x03,0x54,0x03,0x62,0x03,0x70,0x03,0x7E,0x03, - 0x8C,0x03,0x9A,0x03,0xA8,0x03,0xB6,0x03,0xC4,0x03,0xD2,0x03,0xE0,0x03,0xEE,0x03,0xFC,0x03, - 0x0A,0x04,0x18,0x04,0x26,0x04,0x34,0x04,0x42,0x04,0x50,0x04,0x6B,0x04,0x79,0x04,0x87,0x04, - 0x95,0x04,0xA3,0x04,0xB1,0x04,0xBF,0x04,0xCD,0x04,0xDB,0x04,0xE9,0x04,0x04,0x05,0x12,0x05, - 0x20,0x05,0x2E,0x05,0x3C,0x05,0x4A,0x05,0x58,0x05,0x66,0x05, - - 5, // 0x20 ' ' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 4, // 0x21 '!' - 0x00,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x00,0x20,0x00,0x00, - - 4, // 0x22 '"' - 0x00,0x50,0x50,0xA0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x23 '#' - 0x00,0x28,0x28,0x28,0x7C,0x28,0x28,0x28,0x7C,0x28,0x28,0x28,0x00, - - 6, // 0x24 '$' - 0x00,0x10,0x10,0x38,0x54,0x50,0x38,0x14,0x54,0x38,0x10,0x10,0x00, - - 7, // 0x25 '%' - 0x00,0x32,0x54,0x64,0x08,0x08,0x10,0x10,0x26,0x2A,0x4C,0x00,0x00, - - 7, // 0x26 '&' - 0x00,0x30,0x48,0x48,0x48,0x30,0x4A,0x4A,0x44,0x3A,0x00,0x00,0x00, - - 3, // 0x27 ''' - 0x00,0x40,0x40,0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x28 '(' - 0x10,0x20,0x20,0x40,0x40,0x40,0x40,0x40,0x20,0x20,0x10,0x00,0x00, - - 5, // 0x29 ')' - 0x40,0x20,0x20,0x10,0x10,0x10,0x10,0x10,0x20,0x20,0x40,0x00,0x00, - - 6, // 0x2A '*' - 0x00,0x00,0x10,0x54,0x38,0x7C,0x38,0x54,0x10,0x00,0x00,0x00,0x00, - - 6, // 0x2B '+' - 0x00,0x00,0x00,0x00,0x10,0x10,0x7C,0x10,0x10,0x00,0x00,0x00,0x00, - - 4, // 0x2C ',' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x60,0x60,0x20,0x40,0x80, - - 6, // 0x2D '-' - 0x00,0x00,0x00,0x00,0x00,0x00,0x7C,0x00,0x00,0x00,0x00,0x00,0x00, - - 4, // 0x2E '.' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x60,0x60,0x00,0x00,0x00, - - 7, // 0x2F '/' - 0x00,0x04,0x04,0x08,0x08,0x10,0x10,0x20,0x20,0x40,0x40,0x00,0x00, - - 7, // 0x30 '0' - 0x00,0x38,0x44,0x44,0x54,0x54,0x54,0x44,0x44,0x38,0x00,0x00,0x00, - - 4, // 0x31 '1' - 0x00,0x20,0x60,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x00,0x00,0x00, - - 7, // 0x32 '2' - 0x00,0x38,0x44,0x04,0x04,0x08,0x10,0x20,0x40,0x7C,0x00,0x00,0x00, - - 7, // 0x33 '3' - 0x00,0x38,0x44,0x04,0x04,0x38,0x04,0x04,0x44,0x38,0x00,0x00,0x00, - - 6, // 0x34 '4' - 0x00,0x08,0x18,0x28,0x28,0x48,0x48,0x7C,0x08,0x08,0x00,0x00,0x00, - - 7, // 0x35 '5' - 0x00,0x7C,0x40,0x40,0x78,0x44,0x04,0x04,0x44,0x38,0x00,0x00,0x00, - - 7, // 0x36 '6' - 0x00,0x38,0x44,0x40,0x78,0x44,0x44,0x44,0x44,0x38,0x00,0x00,0x00, - - 6, // 0x37 '7' - 0x00,0x7C,0x04,0x08,0x08,0x10,0x10,0x20,0x20,0x20,0x00,0x00,0x00, - - 7, // 0x38 '8' - 0x00,0x38,0x44,0x44,0x44,0x38,0x44,0x44,0x44,0x38,0x00,0x00,0x00, - - 7, // 0x39 '9' - 0x00,0x38,0x44,0x44,0x44,0x3C,0x04,0x04,0x44,0x38,0x00,0x00,0x00, - - 4, // 0x3A ':' - 0x00,0x00,0x00,0x60,0x60,0x00,0x00,0x00,0x60,0x60,0x00,0x00,0x00, - - 4, // 0x3B ';' - 0x00,0x00,0x00,0x60,0x60,0x00,0x00,0x00,0x60,0x60,0x20,0x40,0x80, - - 6, // 0x3C '<' - 0x00,0x00,0x04,0x08,0x10,0x20,0x40,0x20,0x10,0x08,0x04,0x00,0x00, - - 6, // 0x3D '=' - 0x00,0x00,0x00,0x00,0x7C,0x00,0x00,0x7C,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x3E '>' - 0x00,0x00,0x40,0x20,0x10,0x08,0x04,0x08,0x10,0x20,0x40,0x00,0x00, - - 6, // 0x3F '?' - 0x00,0x38,0x44,0x04,0x04,0x08,0x10,0x10,0x00,0x10,0x00,0x00,0x00, - - 7, // 0x40 '@' - 0x00,0x38,0x44,0x44,0x5C,0x54,0x54,0x4C,0x40,0x38,0x00,0x00,0x00, - - 7, // 0x41 'A' - 0x00,0x38,0x44,0x44,0x44,0x7C,0x44,0x44,0x44,0x44,0x00,0x00,0x00, - - 7, // 0x42 'B' - 0x00,0x78,0x44,0x44,0x44,0x78,0x44,0x44,0x44,0x78,0x00,0x00,0x00, - - 6, // 0x43 'C' - 0x00,0x38,0x44,0x40,0x40,0x40,0x40,0x40,0x44,0x38,0x00,0x00,0x00, - - 7, // 0x44 'D' - 0x00,0x70,0x48,0x44,0x44,0x44,0x44,0x44,0x48,0x70,0x00,0x00,0x00, - - 6, // 0x45 'E' - 0x00,0x7C,0x40,0x40,0x40,0x78,0x40,0x40,0x40,0x7C,0x00,0x00,0x00, - - 6, // 0x46 'F' - 0x00,0x7C,0x40,0x40,0x40,0x78,0x40,0x40,0x40,0x40,0x00,0x00,0x00, - - 7, // 0x47 'G' - 0x00,0x38,0x44,0x40,0x40,0x5C,0x44,0x44,0x4C,0x34,0x00,0x00,0x00, - - 7, // 0x48 'H' - 0x00,0x44,0x44,0x44,0x44,0x7C,0x44,0x44,0x44,0x44,0x00,0x00,0x00, - - 5, // 0x49 'I' - 0x00,0x70,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x70,0x00,0x00,0x00, - - 6, // 0x4A 'J' - 0x00,0x1C,0x08,0x08,0x08,0x08,0x08,0x48,0x48,0x30,0x00,0x00,0x00, - - 6, // 0x4B 'K' - 0x00,0x44,0x48,0x50,0x60,0x60,0x50,0x48,0x44,0x44,0x00,0x00,0x00, - - 6, // 0x4C 'L' - 0x00,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x7C,0x00,0x00,0x00, - - 9, // 0x4D 'M' - 0x00,0x00,0x41,0x00,0x63,0x00,0x55,0x00,0x49,0x00,0x49,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x4E 'N' - 0x00,0x44,0x64,0x64,0x54,0x54,0x4C,0x4C,0x44,0x44,0x00,0x00,0x00, - - 7, // 0x4F 'O' - 0x00,0x38,0x44,0x44,0x44,0x44,0x44,0x44,0x44,0x38,0x00,0x00,0x00, - - 7, // 0x50 'P' - 0x00,0x78,0x44,0x44,0x44,0x44,0x78,0x40,0x40,0x40,0x00,0x00,0x00, - - 7, // 0x51 'Q' - 0x00,0x38,0x44,0x44,0x44,0x44,0x44,0x54,0x48,0x34,0x00,0x00,0x00, - - 7, // 0x52 'R' - 0x00,0x78,0x44,0x44,0x44,0x44,0x78,0x48,0x44,0x44,0x00,0x00,0x00, - - 7, // 0x53 'S' - 0x00,0x38,0x44,0x40,0x40,0x38,0x04,0x04,0x44,0x38,0x00,0x00,0x00, - - 6, // 0x54 'T' - 0x00,0x7C,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x00,0x00,0x00, - - 7, // 0x55 'U' - 0x00,0x44,0x44,0x44,0x44,0x44,0x44,0x44,0x44,0x38,0x00,0x00,0x00, - - 6, // 0x56 'V' - 0x00,0x44,0x44,0x44,0x44,0x28,0x28,0x28,0x10,0x10,0x00,0x00,0x00, - - 9, // 0x57 'W' - 0x00,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x49,0x00,0x49,0x00,0x55,0x00,0x22,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x58 'X' - 0x00,0x44,0x44,0x44,0x28,0x10,0x28,0x44,0x44,0x44,0x00,0x00,0x00, - - 7, // 0x59 'Y' - 0x00,0x44,0x44,0x44,0x44,0x28,0x10,0x10,0x10,0x10,0x00,0x00,0x00, - - 6, // 0x5A 'Z' - 0x00,0x7C,0x04,0x04,0x08,0x10,0x20,0x40,0x40,0x7C,0x00,0x00,0x00, - - 4, // 0x5B '[' - 0x70,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x70,0x00,0x00, - - 7, // 0x5C '\' - 0x00,0x40,0x40,0x20,0x20,0x10,0x10,0x08,0x08,0x04,0x04,0x00,0x00, - - 4, // 0x5D ']' - 0xE0,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0xE0,0x00,0x00, - - 6, // 0x5E '^' - 0x00,0x10,0x28,0x44,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x5F '_' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7C,0x00,0x00,0x00, - - 4, // 0x60 '`' - 0x00,0x40,0x40,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x61 'a' - 0x00,0x00,0x00,0x38,0x04,0x3C,0x44,0x44,0x44,0x3C,0x00,0x00,0x00, - - 7, // 0x62 'b' - 0x00,0x40,0x40,0x78,0x44,0x44,0x44,0x44,0x44,0x78,0x00,0x00,0x00, - - 6, // 0x63 'c' - 0x00,0x00,0x00,0x38,0x44,0x40,0x40,0x40,0x44,0x38,0x00,0x00,0x00, - - 7, // 0x64 'd' - 0x00,0x04,0x04,0x3C,0x44,0x44,0x44,0x44,0x44,0x3C,0x00,0x00,0x00, - - 7, // 0x65 'e' - 0x00,0x00,0x00,0x38,0x44,0x44,0x7C,0x40,0x44,0x38,0x00,0x00,0x00, - - 4, // 0x66 'f' - 0x00,0x30,0x40,0xE0,0x40,0x40,0x40,0x40,0x40,0x40,0x00,0x00,0x00, - - 7, // 0x67 'g' - 0x00,0x00,0x00,0x3C,0x44,0x44,0x44,0x44,0x44,0x3C,0x04,0x44,0x38, - - 7, // 0x68 'h' - 0x00,0x40,0x40,0x78,0x44,0x44,0x44,0x44,0x44,0x44,0x00,0x00,0x00, - - 3, // 0x69 'i' - 0x00,0x40,0x00,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x00,0x00,0x00, - - 5, // 0x6A 'j' - 0x00,0x10,0x00,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x90,0x60,0x00, - - 6, // 0x6B 'k' - 0x00,0x40,0x40,0x44,0x48,0x50,0x60,0x50,0x48,0x44,0x00,0x00,0x00, - - 3, // 0x6C 'l' - 0x00,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x00,0x00,0x00, - - 9, // 0x6D 'm' - 0x00,0x00,0x00,0x00,0x00,0x00,0x76,0x00,0x49,0x00,0x49,0x00,0x49,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x6E 'n' - 0x00,0x00,0x00,0x58,0x64,0x44,0x44,0x44,0x44,0x44,0x00,0x00,0x00, - - 7, // 0x6F 'o' - 0x00,0x00,0x00,0x38,0x44,0x44,0x44,0x44,0x44,0x38,0x00,0x00,0x00, - - 7, // 0x70 'p' - 0x00,0x00,0x00,0x78,0x44,0x44,0x44,0x44,0x44,0x78,0x40,0x40,0x40, - - 7, // 0x71 'q' - 0x00,0x00,0x00,0x3C,0x44,0x44,0x44,0x44,0x44,0x3C,0x04,0x04,0x04, - - 6, // 0x72 'r' - 0x00,0x00,0x00,0x58,0x24,0x20,0x20,0x20,0x20,0x70,0x00,0x00,0x00, - - 7, // 0x73 's' - 0x00,0x00,0x00,0x38,0x44,0x40,0x38,0x04,0x44,0x38,0x00,0x00,0x00, - - 5, // 0x74 't' - 0x00,0x20,0x20,0x70,0x20,0x20,0x20,0x20,0x20,0x18,0x00,0x00,0x00, - - 7, // 0x75 'u' - 0x00,0x00,0x00,0x44,0x44,0x44,0x44,0x44,0x4C,0x34,0x00,0x00,0x00, - - 6, // 0x76 'v' - 0x00,0x00,0x00,0x44,0x44,0x44,0x28,0x28,0x10,0x10,0x00,0x00,0x00, - - 9, // 0x77 'w' - 0x00,0x00,0x00,0x00,0x00,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x49,0x00,0x49,0x00,0x49,0x00,0x36,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x78 'x' - 0x00,0x00,0x00,0x44,0x44,0x28,0x10,0x28,0x44,0x44,0x00,0x00,0x00, - - 7, // 0x79 'y' - 0x00,0x00,0x00,0x44,0x44,0x44,0x44,0x44,0x44,0x3C,0x04,0x08,0x70, - - 6, // 0x7A 'z' - 0x00,0x00,0x00,0x7C,0x04,0x08,0x10,0x20,0x40,0x7C,0x00,0x00,0x00, - - 5, // 0x7B '{' - 0x18,0x20,0x20,0x20,0x20,0xC0,0x20,0x20,0x20,0x20,0x18,0x00,0x00, - - 3, // 0x7C '|' - 0x00,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x00,0x00, - - 5, // 0x7D '}' - 0xC0,0x20,0x20,0x20,0x20,0x18,0x20,0x20,0x20,0x20,0xC0,0x00,0x00, - - 7, // 0x7E '~' - 0x00,0x60,0x92,0x92,0x0C,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x7F '' - 0x00,0x10,0x38,0x6C,0x44,0x44,0x7C,0x00,0x00,0x00,0x00,0x00,0x00, - - 0 - }; - - const int8u mcs5x10_mono[] = - { - 10, 2, 32, 128-32, - 0x00,0x00,0x0B,0x00,0x16,0x00,0x21,0x00,0x2C,0x00,0x37,0x00,0x42,0x00,0x4D,0x00,0x58,0x00, - 0x63,0x00,0x6E,0x00,0x79,0x00,0x84,0x00,0x8F,0x00,0x9A,0x00,0xA5,0x00,0xB0,0x00,0xBB,0x00, - 0xC6,0x00,0xD1,0x00,0xDC,0x00,0xE7,0x00,0xF2,0x00,0xFD,0x00,0x08,0x01,0x13,0x01,0x1E,0x01, - 0x29,0x01,0x34,0x01,0x3F,0x01,0x4A,0x01,0x55,0x01,0x60,0x01,0x6B,0x01,0x76,0x01,0x81,0x01, - 0x8C,0x01,0x97,0x01,0xA2,0x01,0xAD,0x01,0xB8,0x01,0xC3,0x01,0xCE,0x01,0xD9,0x01,0xE4,0x01, - 0xEF,0x01,0xFA,0x01,0x05,0x02,0x10,0x02,0x1B,0x02,0x26,0x02,0x31,0x02,0x3C,0x02,0x47,0x02, - 0x52,0x02,0x5D,0x02,0x68,0x02,0x73,0x02,0x7E,0x02,0x89,0x02,0x94,0x02,0x9F,0x02,0xAA,0x02, - 0xB5,0x02,0xC0,0x02,0xCB,0x02,0xD6,0x02,0xE1,0x02,0xEC,0x02,0xF7,0x02,0x02,0x03,0x0D,0x03, - 0x18,0x03,0x23,0x03,0x2E,0x03,0x39,0x03,0x44,0x03,0x4F,0x03,0x5A,0x03,0x65,0x03,0x70,0x03, - 0x7B,0x03,0x86,0x03,0x91,0x03,0x9C,0x03,0xA7,0x03,0xB2,0x03,0xBD,0x03,0xC8,0x03,0xD3,0x03, - 0xDE,0x03,0xE9,0x03,0xF4,0x03,0xFF,0x03,0x0A,0x04,0x15,0x04, - - 5, // 0x20 ' ' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x21 '!' - 0x00,0x20,0x20,0x20,0x20,0x20,0x20,0x00,0x20,0x00, - - 5, // 0x22 '"' - 0x00,0x50,0x50,0xA0,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x23 '#' - 0x00,0x50,0x50,0xF8,0x50,0x50,0x50,0xF8,0x50,0x50, - - 5, // 0x24 '$' - 0x00,0x40,0x60,0x90,0x80,0x60,0x10,0x90,0x60,0x20, - - 5, // 0x25 '%' - 0x00,0x00,0x90,0x90,0x20,0x20,0x40,0x40,0x90,0x90, - - 5, // 0x26 '&' - 0x00,0x40,0xA0,0xA0,0xA0,0x40,0xA8,0x90,0x90,0x68, - - 5, // 0x27 ''' - 0x00,0x20,0x20,0x40,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x28 '(' - 0x10,0x20,0x20,0x40,0x40,0x40,0x40,0x20,0x20,0x10, - - 5, // 0x29 ')' - 0x40,0x20,0x20,0x10,0x10,0x10,0x10,0x20,0x20,0x40, - - 5, // 0x2A '*' - 0x00,0x00,0x90,0x60,0xF0,0x60,0x90,0x00,0x00,0x00, - - 5, // 0x2B '+' - 0x00,0x00,0x00,0x20,0x20,0xF8,0x20,0x20,0x00,0x00, - - 5, // 0x2C ',' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x60,0x60,0xC0, - - 5, // 0x2D '-' - 0x00,0x00,0x00,0x00,0x00,0xF0,0x00,0x00,0x00,0x00, - - 5, // 0x2E '.' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x60,0x60,0x00, - - 5, // 0x2F '/' - 0x00,0x08,0x10,0x10,0x20,0x20,0x40,0x40,0x80,0x00, - - 5, // 0x30 '0' - 0x00,0x70,0x90,0x90,0x90,0x90,0x90,0x90,0xE0,0x00, - - 5, // 0x31 '1' - 0x00,0x20,0x60,0x20,0x20,0x20,0x20,0x20,0x70,0x00, - - 5, // 0x32 '2' - 0x00,0x60,0x90,0x90,0x10,0x20,0x40,0x80,0xF0,0x00, - - 5, // 0x33 '3' - 0x00,0x60,0x90,0x10,0x60,0x10,0x10,0x90,0x60,0x00, - - 5, // 0x34 '4' - 0x00,0x10,0x30,0x50,0x50,0x90,0xF0,0x10,0x10,0x00, - - 5, // 0x35 '5' - 0x00,0xF0,0x80,0x80,0xE0,0x10,0x10,0x90,0x60,0x00, - - 5, // 0x36 '6' - 0x00,0x60,0x80,0x80,0xE0,0x90,0x90,0x90,0x60,0x00, - - 5, // 0x37 '7' - 0x00,0xF0,0x10,0x10,0x20,0x20,0x40,0x40,0x40,0x00, - - 5, // 0x38 '8' - 0x00,0x60,0x90,0x90,0x60,0x90,0x90,0x90,0x60,0x00, - - 5, // 0x39 '9' - 0x00,0x60,0x90,0x90,0x90,0x70,0x10,0x10,0x60,0x00, - - 5, // 0x3A ':' - 0x00,0x00,0x00,0x60,0x60,0x00,0x00,0x60,0x60,0x00, - - 5, // 0x3B ';' - 0x00,0x00,0x00,0x60,0x60,0x00,0x00,0x60,0x60,0xC0, - - 5, // 0x3C '<' - 0x00,0x08,0x10,0x20,0x40,0x80,0x40,0x20,0x10,0x08, - - 5, // 0x3D '=' - 0x00,0x00,0x00,0x00,0xF0,0x00,0xF0,0x00,0x00,0x00, - - 5, // 0x3E '>' - 0x00,0x80,0x40,0x20,0x10,0x08,0x10,0x20,0x40,0x80, - - 5, // 0x3F '?' - 0x00,0x60,0x90,0x10,0x10,0x20,0x40,0x00,0x40,0x00, - - 5, // 0x40 '@' - 0x00,0x60,0x90,0x90,0xB0,0xB0,0x80,0x80,0x70,0x00, - - 5, // 0x41 'A' - 0x00,0x60,0x90,0x90,0x90,0xF0,0x90,0x90,0x90,0x00, - - 5, // 0x42 'B' - 0x00,0xE0,0x90,0x90,0xE0,0x90,0x90,0x90,0xE0,0x00, - - 5, // 0x43 'C' - 0x00,0x60,0x90,0x80,0x80,0x80,0x80,0x90,0x60,0x00, - - 5, // 0x44 'D' - 0x00,0xE0,0x90,0x90,0x90,0x90,0x90,0x90,0xE0,0x00, - - 5, // 0x45 'E' - 0x00,0xF0,0x80,0x80,0xF0,0x80,0x80,0x80,0xF0,0x00, - - 5, // 0x46 'F' - 0x00,0xF0,0x80,0x80,0xF0,0x80,0x80,0x80,0x80,0x00, - - 5, // 0x47 'G' - 0x00,0x60,0x90,0x80,0x80,0xB0,0x90,0x90,0x60,0x00, - - 5, // 0x48 'H' - 0x00,0x90,0x90,0x90,0x90,0xF0,0x90,0x90,0x90,0x00, - - 5, // 0x49 'I' - 0x00,0x70,0x20,0x20,0x20,0x20,0x20,0x20,0x70,0x00, - - 5, // 0x4A 'J' - 0x00,0x70,0x20,0x20,0x20,0x20,0x20,0xA0,0x40,0x00, - - 5, // 0x4B 'K' - 0x00,0x90,0xA0,0xA0,0xC0,0xC0,0xA0,0xA0,0x90,0x00, - - 5, // 0x4C 'L' - 0x00,0x80,0x80,0x80,0x80,0x80,0x80,0x80,0xF0,0x00, - - 5, // 0x4D 'M' - 0x00,0x90,0x90,0xF0,0xF0,0x90,0x90,0x90,0x90,0x00, - - 5, // 0x4E 'N' - 0x00,0x90,0x90,0xD0,0xD0,0xB0,0xB0,0x90,0x90,0x00, - - 5, // 0x4F 'O' - 0x00,0x60,0x90,0x90,0x90,0x90,0x90,0x90,0x60,0x00, - - 5, // 0x50 'P' - 0x00,0xE0,0x90,0x90,0x90,0xE0,0x80,0x80,0x80,0x00, - - 5, // 0x51 'Q' - 0x00,0x60,0x90,0x90,0x90,0x90,0x90,0x90,0x60,0x30, - - 5, // 0x52 'R' - 0x00,0xE0,0x90,0x90,0x90,0xE0,0xA0,0x90,0x90,0x00, - - 5, // 0x53 'S' - 0x00,0x60,0x90,0x80,0x60,0x10,0x90,0x90,0x60,0x00, - - 5, // 0x54 'T' - 0x00,0xF8,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x00, - - 5, // 0x55 'U' - 0x00,0x90,0x90,0x90,0x90,0x90,0x90,0x90,0x60,0x00, - - 5, // 0x56 'V' - 0x00,0x90,0x90,0x90,0x50,0x50,0x50,0x20,0x20,0x00, - - 5, // 0x57 'W' - 0x00,0x90,0x90,0x90,0x90,0x90,0xF0,0xF0,0x90,0x00, - - 5, // 0x58 'X' - 0x00,0x90,0x90,0x90,0x60,0x60,0x90,0x90,0x90,0x00, - - 5, // 0x59 'Y' - 0x00,0x88,0x88,0x88,0x50,0x20,0x20,0x20,0x20,0x00, - - 5, // 0x5A 'Z' - 0x00,0xF0,0x10,0x20,0x20,0x40,0x40,0x80,0xF0,0x00, - - 5, // 0x5B '[' - 0x60,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x60, - - 5, // 0x5C '\' - 0x80,0x80,0x40,0x40,0x20,0x20,0x10,0x10,0x08,0x08, - - 5, // 0x5D ']' - 0x60,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x60, - - 5, // 0x5E '^' - 0x00,0x20,0x50,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x5F '_' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xF0,0x00, - - 5, // 0x60 '`' - 0x00,0x40,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x61 'a' - 0x00,0x00,0x00,0x60,0x10,0x70,0x90,0x90,0x70,0x00, - - 5, // 0x62 'b' - 0x00,0x80,0x80,0xE0,0x90,0x90,0x90,0x90,0xE0,0x00, - - 5, // 0x63 'c' - 0x00,0x00,0x00,0x60,0x90,0x80,0x80,0x90,0x60,0x00, - - 5, // 0x64 'd' - 0x00,0x10,0x10,0x70,0x90,0x90,0x90,0x90,0x70,0x00, - - 5, // 0x65 'e' - 0x00,0x00,0x00,0x60,0x90,0x90,0xF0,0x80,0x70,0x00, - - 5, // 0x66 'f' - 0x00,0x30,0x40,0xE0,0x40,0x40,0x40,0x40,0x40,0x00, - - 5, // 0x67 'g' - 0x00,0x00,0x00,0x70,0x90,0x90,0x90,0x70,0x10,0xE0, - - 5, // 0x68 'h' - 0x00,0x80,0x80,0xE0,0x90,0x90,0x90,0x90,0x90,0x00, - - 5, // 0x69 'i' - 0x00,0x20,0x00,0x60,0x20,0x20,0x20,0x20,0x70,0x00, - - 5, // 0x6A 'j' - 0x00,0x20,0x00,0x60,0x20,0x20,0x20,0x20,0x20,0xC0, - - 5, // 0x6B 'k' - 0x00,0x80,0x80,0x90,0xA0,0xC0,0xA0,0x90,0x90,0x00, - - 5, // 0x6C 'l' - 0x00,0x60,0x20,0x20,0x20,0x20,0x20,0x20,0x70,0x00, - - 5, // 0x6D 'm' - 0x00,0x00,0x00,0x90,0xF0,0x90,0x90,0x90,0x90,0x00, - - 5, // 0x6E 'n' - 0x00,0x00,0x00,0xE0,0x90,0x90,0x90,0x90,0x90,0x00, - - 5, // 0x6F 'o' - 0x00,0x00,0x00,0x60,0x90,0x90,0x90,0x90,0x60,0x00, - - 5, // 0x70 'p' - 0x00,0x00,0x00,0xE0,0x90,0x90,0x90,0xE0,0x80,0x80, - - 5, // 0x71 'q' - 0x00,0x00,0x00,0x70,0x90,0x90,0x90,0x70,0x10,0x10, - - 5, // 0x72 'r' - 0x00,0x00,0x00,0xB0,0x50,0x40,0x40,0x40,0xE0,0x00, - - 5, // 0x73 's' - 0x00,0x00,0x00,0x60,0x90,0x40,0x20,0x90,0x60,0x00, - - 5, // 0x74 't' - 0x00,0x40,0x40,0xE0,0x40,0x40,0x40,0x50,0x20,0x00, - - 5, // 0x75 'u' - 0x00,0x00,0x00,0x90,0x90,0x90,0x90,0x90,0x70,0x00, - - 5, // 0x76 'v' - 0x00,0x00,0x00,0x90,0x90,0x50,0x50,0x20,0x20,0x00, - - 5, // 0x77 'w' - 0x00,0x00,0x00,0x90,0x90,0x90,0x90,0xF0,0x90,0x00, - - 5, // 0x78 'x' - 0x00,0x00,0x00,0x90,0x90,0x60,0x60,0x90,0x90,0x00, - - 5, // 0x79 'y' - 0x00,0x00,0x00,0x90,0x90,0x90,0x90,0x70,0x10,0xE0, - - 5, // 0x7A 'z' - 0x00,0x00,0x00,0xF0,0x10,0x20,0x40,0x80,0xF0,0x00, - - 5, // 0x7B '{' - 0x30,0x40,0x40,0x40,0x80,0x40,0x40,0x40,0x40,0x30, - - 5, // 0x7C '|' - 0x00,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20, - - 5, // 0x7D '}' - 0xC0,0x20,0x20,0x20,0x10,0x20,0x20,0x20,0x20,0xC0, - - 5, // 0x7E '~' - 0x00,0x40,0xA8,0x10,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x7F '' - 0x00,0x20,0x70,0xD8,0x88,0x88,0xF8,0x00,0x00,0x00, - - 0 - }; - - const int8u mcs5x11_mono[] = - { - 11, 3, 32, 128-32, - 0x00,0x00,0x0C,0x00,0x18,0x00,0x24,0x00,0x30,0x00,0x3C,0x00,0x48,0x00,0x54,0x00,0x60,0x00, - 0x6C,0x00,0x78,0x00,0x84,0x00,0x90,0x00,0x9C,0x00,0xA8,0x00,0xB4,0x00,0xC0,0x00,0xCC,0x00, - 0xD8,0x00,0xE4,0x00,0xF0,0x00,0xFC,0x00,0x08,0x01,0x14,0x01,0x20,0x01,0x2C,0x01,0x38,0x01, - 0x44,0x01,0x50,0x01,0x5C,0x01,0x68,0x01,0x74,0x01,0x80,0x01,0x8C,0x01,0x98,0x01,0xA4,0x01, - 0xB0,0x01,0xBC,0x01,0xC8,0x01,0xD4,0x01,0xE0,0x01,0xEC,0x01,0xF8,0x01,0x04,0x02,0x10,0x02, - 0x1C,0x02,0x28,0x02,0x34,0x02,0x40,0x02,0x4C,0x02,0x58,0x02,0x64,0x02,0x70,0x02,0x7C,0x02, - 0x88,0x02,0x94,0x02,0xA0,0x02,0xAC,0x02,0xB8,0x02,0xC4,0x02,0xD0,0x02,0xDC,0x02,0xE8,0x02, - 0xF4,0x02,0x00,0x03,0x0C,0x03,0x18,0x03,0x24,0x03,0x30,0x03,0x3C,0x03,0x48,0x03,0x54,0x03, - 0x60,0x03,0x6C,0x03,0x78,0x03,0x84,0x03,0x90,0x03,0x9C,0x03,0xA8,0x03,0xB4,0x03,0xC0,0x03, - 0xCC,0x03,0xD8,0x03,0xE4,0x03,0xF0,0x03,0xFC,0x03,0x08,0x04,0x14,0x04,0x20,0x04,0x2C,0x04, - 0x38,0x04,0x44,0x04,0x50,0x04,0x5C,0x04,0x68,0x04,0x74,0x04, - - 5, // 0x20 ' ' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x21 '!' - 0x00,0x20,0x20,0x20,0x20,0x20,0x20,0x00,0x20,0x00,0x00, - - 5, // 0x22 '"' - 0x00,0x50,0x50,0xA0,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x23 '#' - 0x00,0x50,0x50,0xF8,0x50,0x50,0x50,0xF8,0x50,0x50,0x00, - - 5, // 0x24 '$' - 0x00,0x40,0x60,0x90,0x80,0x60,0x10,0x90,0x60,0x20,0x00, - - 5, // 0x25 '%' - 0x00,0x00,0x90,0x90,0x20,0x20,0x40,0x40,0x90,0x90,0x00, - - 5, // 0x26 '&' - 0x00,0x40,0xA0,0xA0,0x40,0xA8,0x90,0x90,0x68,0x00,0x00, - - 5, // 0x27 ''' - 0x00,0x20,0x20,0x40,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x28 '(' - 0x00,0x10,0x20,0x20,0x40,0x40,0x40,0x40,0x20,0x20,0x10, - - 5, // 0x29 ')' - 0x00,0x40,0x20,0x20,0x10,0x10,0x10,0x10,0x20,0x20,0x40, - - 5, // 0x2A '*' - 0x00,0x00,0x90,0x60,0xF0,0x60,0x90,0x00,0x00,0x00,0x00, - - 5, // 0x2B '+' - 0x00,0x00,0x00,0x20,0x20,0xF8,0x20,0x20,0x00,0x00,0x00, - - 5, // 0x2C ',' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x60,0x60,0x40,0x80, - - 5, // 0x2D '-' - 0x00,0x00,0x00,0x00,0x00,0xF0,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x2E '.' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x60,0x60,0x00,0x00, - - 5, // 0x2F '/' - 0x08,0x08,0x10,0x10,0x20,0x20,0x40,0x40,0x80,0x80,0x00, - - 5, // 0x30 '0' - 0x00,0x70,0x90,0x90,0x90,0x90,0x90,0x90,0xE0,0x00,0x00, - - 5, // 0x31 '1' - 0x00,0x20,0x60,0x20,0x20,0x20,0x20,0x20,0x70,0x00,0x00, - - 5, // 0x32 '2' - 0x00,0x60,0x90,0x90,0x10,0x20,0x40,0x80,0xF0,0x00,0x00, - - 5, // 0x33 '3' - 0x00,0x60,0x90,0x10,0x60,0x10,0x10,0x90,0x60,0x00,0x00, - - 5, // 0x34 '4' - 0x00,0x10,0x30,0x50,0x50,0x90,0xF8,0x10,0x10,0x00,0x00, - - 5, // 0x35 '5' - 0x00,0xF0,0x80,0xE0,0x90,0x10,0x10,0x90,0x60,0x00,0x00, - - 5, // 0x36 '6' - 0x00,0x60,0x90,0x80,0xE0,0x90,0x90,0x90,0x60,0x00,0x00, - - 5, // 0x37 '7' - 0x00,0xF0,0x10,0x10,0x20,0x20,0x40,0x40,0x40,0x00,0x00, - - 5, // 0x38 '8' - 0x00,0x60,0x90,0x90,0x60,0x90,0x90,0x90,0x60,0x00,0x00, - - 5, // 0x39 '9' - 0x00,0x60,0x90,0x90,0x90,0x70,0x10,0x90,0x60,0x00,0x00, - - 5, // 0x3A ':' - 0x00,0x00,0x00,0x60,0x60,0x00,0x00,0x60,0x60,0x00,0x00, - - 5, // 0x3B ';' - 0x00,0x00,0x00,0x60,0x60,0x00,0x00,0x60,0x60,0x40,0x80, - - 5, // 0x3C '<' - 0x00,0x08,0x10,0x20,0x40,0x80,0x40,0x20,0x10,0x08,0x00, - - 5, // 0x3D '=' - 0x00,0x00,0x00,0x00,0xF0,0x00,0x00,0xF0,0x00,0x00,0x00, - - 5, // 0x3E '>' - 0x00,0x80,0x40,0x20,0x10,0x08,0x10,0x20,0x40,0x80,0x00, - - 5, // 0x3F '?' - 0x00,0x60,0x90,0x10,0x10,0x20,0x40,0x00,0x40,0x00,0x00, - - 5, // 0x40 '@' - 0x00,0x60,0x90,0x90,0xB0,0xB0,0x80,0x80,0x70,0x00,0x00, - - 5, // 0x41 'A' - 0x00,0x60,0x90,0x90,0x90,0xF0,0x90,0x90,0x90,0x00,0x00, - - 5, // 0x42 'B' - 0x00,0xE0,0x90,0x90,0xE0,0x90,0x90,0x90,0xE0,0x00,0x00, - - 5, // 0x43 'C' - 0x00,0x60,0x90,0x80,0x80,0x80,0x80,0x90,0x60,0x00,0x00, - - 5, // 0x44 'D' - 0x00,0xE0,0x90,0x90,0x90,0x90,0x90,0x90,0xE0,0x00,0x00, - - 5, // 0x45 'E' - 0x00,0xF0,0x80,0x80,0xE0,0x80,0x80,0x80,0xF0,0x00,0x00, - - 5, // 0x46 'F' - 0x00,0xF0,0x80,0x80,0xE0,0x80,0x80,0x80,0x80,0x00,0x00, - - 5, // 0x47 'G' - 0x00,0x60,0x90,0x80,0x80,0xB0,0x90,0x90,0x60,0x00,0x00, - - 5, // 0x48 'H' - 0x00,0x90,0x90,0x90,0xF0,0x90,0x90,0x90,0x90,0x00,0x00, - - 5, // 0x49 'I' - 0x00,0x70,0x20,0x20,0x20,0x20,0x20,0x20,0x70,0x00,0x00, - - 5, // 0x4A 'J' - 0x00,0x70,0x20,0x20,0x20,0x20,0xA0,0xA0,0x40,0x00,0x00, - - 5, // 0x4B 'K' - 0x00,0x90,0xA0,0xA0,0xC0,0xA0,0xA0,0x90,0x90,0x00,0x00, - - 5, // 0x4C 'L' - 0x00,0x80,0x80,0x80,0x80,0x80,0x80,0x80,0xF0,0x00,0x00, - - 5, // 0x4D 'M' - 0x00,0x90,0xF0,0xF0,0x90,0x90,0x90,0x90,0x90,0x00,0x00, - - 5, // 0x4E 'N' - 0x00,0x90,0x90,0xD0,0xD0,0xB0,0xB0,0x90,0x90,0x00,0x00, - - 5, // 0x4F 'O' - 0x00,0x60,0x90,0x90,0x90,0x90,0x90,0x90,0x60,0x00,0x00, - - 5, // 0x50 'P' - 0x00,0xE0,0x90,0x90,0x90,0xE0,0x80,0x80,0x80,0x00,0x00, - - 5, // 0x51 'Q' - 0x00,0x60,0x90,0x90,0x90,0x90,0x90,0x90,0x60,0x30,0x00, - - 5, // 0x52 'R' - 0x00,0xE0,0x90,0x90,0x90,0xE0,0xA0,0x90,0x90,0x00,0x00, - - 5, // 0x53 'S' - 0x00,0x60,0x90,0x80,0x60,0x10,0x90,0x90,0x60,0x00,0x00, - - 5, // 0x54 'T' - 0x00,0xF8,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x00,0x00, - - 5, // 0x55 'U' - 0x00,0x90,0x90,0x90,0x90,0x90,0x90,0x90,0x60,0x00,0x00, - - 5, // 0x56 'V' - 0x00,0x90,0x90,0x90,0x50,0x50,0x50,0x20,0x20,0x00,0x00, - - 5, // 0x57 'W' - 0x00,0x90,0x90,0x90,0x90,0x90,0xF0,0xF0,0x90,0x00,0x00, - - 5, // 0x58 'X' - 0x00,0x90,0x90,0x90,0x60,0x60,0x90,0x90,0x90,0x00,0x00, - - 5, // 0x59 'Y' - 0x00,0x88,0x88,0x88,0x50,0x20,0x20,0x20,0x20,0x00,0x00, - - 5, // 0x5A 'Z' - 0x00,0xF0,0x10,0x20,0x20,0x40,0x40,0x80,0xF0,0x00,0x00, - - 5, // 0x5B '[' - 0x00,0x60,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x60, - - 5, // 0x5C '\' - 0x80,0x80,0x40,0x40,0x20,0x20,0x10,0x10,0x08,0x08,0x00, - - 5, // 0x5D ']' - 0x00,0x60,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x60, - - 5, // 0x5E '^' - 0x00,0x20,0x50,0x88,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x5F '_' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xF0,0x00,0x00, - - 5, // 0x60 '`' - 0x00,0x40,0x40,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x61 'a' - 0x00,0x00,0x00,0x60,0x10,0x70,0x90,0x90,0x70,0x00,0x00, - - 5, // 0x62 'b' - 0x00,0x80,0x80,0xE0,0x90,0x90,0x90,0x90,0xE0,0x00,0x00, - - 5, // 0x63 'c' - 0x00,0x00,0x00,0x60,0x90,0x80,0x80,0x90,0x60,0x00,0x00, - - 5, // 0x64 'd' - 0x00,0x10,0x10,0x70,0x90,0x90,0x90,0x90,0x70,0x00,0x00, - - 5, // 0x65 'e' - 0x00,0x00,0x00,0x60,0x90,0x90,0xF0,0x80,0x70,0x00,0x00, - - 5, // 0x66 'f' - 0x00,0x30,0x40,0xE0,0x40,0x40,0x40,0x40,0x40,0x00,0x00, - - 5, // 0x67 'g' - 0x00,0x00,0x00,0x70,0x90,0x90,0x90,0x90,0x70,0x10,0xE0, - - 5, // 0x68 'h' - 0x00,0x80,0x80,0xE0,0x90,0x90,0x90,0x90,0x90,0x00,0x00, - - 5, // 0x69 'i' - 0x00,0x20,0x00,0x60,0x20,0x20,0x20,0x20,0x70,0x00,0x00, - - 5, // 0x6A 'j' - 0x00,0x20,0x00,0x60,0x20,0x20,0x20,0x20,0x20,0xA0,0x40, - - 5, // 0x6B 'k' - 0x00,0x80,0x80,0x90,0xA0,0xC0,0xA0,0x90,0x90,0x00,0x00, - - 5, // 0x6C 'l' - 0x00,0x60,0x20,0x20,0x20,0x20,0x20,0x20,0x70,0x00,0x00, - - 5, // 0x6D 'm' - 0x00,0x00,0x00,0x90,0xF0,0x90,0x90,0x90,0x90,0x00,0x00, - - 5, // 0x6E 'n' - 0x00,0x00,0x00,0xE0,0x90,0x90,0x90,0x90,0x90,0x00,0x00, - - 5, // 0x6F 'o' - 0x00,0x00,0x00,0x60,0x90,0x90,0x90,0x90,0x60,0x00,0x00, - - 5, // 0x70 'p' - 0x00,0x00,0x00,0xE0,0x90,0x90,0x90,0x90,0xE0,0x80,0x80, - - 5, // 0x71 'q' - 0x00,0x00,0x00,0x70,0x90,0x90,0x90,0x90,0x70,0x10,0x10, - - 5, // 0x72 'r' - 0x00,0x00,0x00,0xA0,0x50,0x40,0x40,0x40,0xE0,0x00,0x00, - - 5, // 0x73 's' - 0x00,0x00,0x00,0x60,0x90,0x40,0x20,0x90,0x60,0x00,0x00, - - 5, // 0x74 't' - 0x00,0x40,0x40,0xE0,0x40,0x40,0x40,0x40,0x30,0x00,0x00, - - 5, // 0x75 'u' - 0x00,0x00,0x00,0x90,0x90,0x90,0x90,0x90,0x70,0x00,0x00, - - 5, // 0x76 'v' - 0x00,0x00,0x00,0x90,0x90,0x50,0x50,0x20,0x20,0x00,0x00, - - 5, // 0x77 'w' - 0x00,0x00,0x00,0x90,0x90,0x90,0x90,0xF0,0x90,0x00,0x00, - - 5, // 0x78 'x' - 0x00,0x00,0x00,0x90,0x90,0x60,0x60,0x90,0x90,0x00,0x00, - - 5, // 0x79 'y' - 0x00,0x00,0x00,0x90,0x90,0x90,0x90,0x90,0x70,0x10,0xE0, - - 5, // 0x7A 'z' - 0x00,0x00,0x00,0xF0,0x10,0x20,0x40,0x80,0xF0,0x00,0x00, - - 5, // 0x7B '{' - 0x30,0x40,0x40,0x40,0x40,0x80,0x40,0x40,0x40,0x40,0x30, - - 5, // 0x7C '|' - 0x00,0x20,0x20,0x20,0x20,0x00,0x20,0x20,0x20,0x20,0x00, - - 5, // 0x7D '}' - 0xC0,0x20,0x20,0x20,0x20,0x10,0x20,0x20,0x20,0x20,0xC0, - - 5, // 0x7E '~' - 0x00,0x40,0xA8,0x10,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x7F '' - 0x00,0x20,0x70,0xD8,0x88,0x88,0xF8,0x00,0x00,0x00,0x00, - - 0 - }; - - const int8u mcs6x10_mono[] = - { - 10, 3, 32, 128-32, - 0x00,0x00,0x0B,0x00,0x16,0x00,0x21,0x00,0x2C,0x00,0x37,0x00,0x42,0x00,0x4D,0x00,0x58,0x00, - 0x63,0x00,0x6E,0x00,0x79,0x00,0x84,0x00,0x8F,0x00,0x9A,0x00,0xA5,0x00,0xB0,0x00,0xBB,0x00, - 0xC6,0x00,0xD1,0x00,0xDC,0x00,0xE7,0x00,0xF2,0x00,0xFD,0x00,0x08,0x01,0x13,0x01,0x1E,0x01, - 0x29,0x01,0x34,0x01,0x3F,0x01,0x4A,0x01,0x55,0x01,0x60,0x01,0x6B,0x01,0x76,0x01,0x81,0x01, - 0x8C,0x01,0x97,0x01,0xA2,0x01,0xAD,0x01,0xB8,0x01,0xC3,0x01,0xCE,0x01,0xD9,0x01,0xE4,0x01, - 0xEF,0x01,0xFA,0x01,0x05,0x02,0x10,0x02,0x1B,0x02,0x26,0x02,0x31,0x02,0x3C,0x02,0x47,0x02, - 0x52,0x02,0x5D,0x02,0x68,0x02,0x73,0x02,0x7E,0x02,0x89,0x02,0x94,0x02,0x9F,0x02,0xAA,0x02, - 0xB5,0x02,0xC0,0x02,0xCB,0x02,0xD6,0x02,0xE1,0x02,0xEC,0x02,0xF7,0x02,0x02,0x03,0x0D,0x03, - 0x18,0x03,0x23,0x03,0x2E,0x03,0x39,0x03,0x44,0x03,0x4F,0x03,0x5A,0x03,0x65,0x03,0x70,0x03, - 0x7B,0x03,0x86,0x03,0x91,0x03,0x9C,0x03,0xA7,0x03,0xB2,0x03,0xBD,0x03,0xC8,0x03,0xD3,0x03, - 0xDE,0x03,0xE9,0x03,0xF4,0x03,0xFF,0x03,0x0A,0x04,0x15,0x04, - - 6, // 0x20 ' ' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x21 '!' - 0x00,0x10,0x10,0x10,0x10,0x10,0x00,0x10,0x00,0x00, - - 6, // 0x22 '"' - 0x00,0x28,0x28,0x50,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x23 '#' - 0x00,0x28,0x28,0x7C,0x28,0x28,0x7C,0x28,0x28,0x00, - - 6, // 0x24 '$' - 0x10,0x38,0x54,0x50,0x38,0x14,0x54,0x38,0x10,0x00, - - 6, // 0x25 '%' - 0x00,0x08,0xC8,0xD0,0x10,0x20,0x2C,0x4C,0x40,0x00, - - 6, // 0x26 '&' - 0x00,0x20,0x50,0x50,0x24,0x54,0x48,0x34,0x00,0x00, - - 6, // 0x27 ''' - 0x00,0x10,0x10,0x20,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x28 '(' - 0x08,0x10,0x10,0x20,0x20,0x20,0x10,0x10,0x08,0x00, - - 6, // 0x29 ')' - 0x20,0x10,0x10,0x08,0x08,0x08,0x10,0x10,0x20,0x00, - - 6, // 0x2A '*' - 0x00,0x00,0x28,0x7C,0x38,0x7C,0x28,0x00,0x00,0x00, - - 6, // 0x2B '+' - 0x00,0x00,0x10,0x10,0x7C,0x10,0x10,0x00,0x00,0x00, - - 6, // 0x2C ',' - 0x00,0x00,0x00,0x00,0x00,0x00,0x30,0x30,0x20,0x40, - - 6, // 0x2D '-' - 0x00,0x00,0x00,0x00,0x7C,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x2E '.' - 0x00,0x00,0x00,0x00,0x00,0x00,0x30,0x30,0x00,0x00, - - 6, // 0x2F '/' - 0x00,0x08,0x08,0x10,0x10,0x20,0x20,0x40,0x40,0x00, - - 6, // 0x30 '0' - 0x00,0x38,0x44,0x4C,0x54,0x64,0x44,0x38,0x00,0x00, - - 6, // 0x31 '1' - 0x00,0x10,0x30,0x10,0x10,0x10,0x10,0x38,0x00,0x00, - - 6, // 0x32 '2' - 0x00,0x38,0x44,0x04,0x18,0x20,0x40,0x7C,0x00,0x00, - - 6, // 0x33 '3' - 0x00,0x38,0x44,0x04,0x38,0x04,0x44,0x38,0x00,0x00, - - 6, // 0x34 '4' - 0x00,0x08,0x18,0x28,0x48,0x7C,0x08,0x08,0x00,0x00, - - 6, // 0x35 '5' - 0x00,0x7C,0x40,0x40,0x78,0x04,0x44,0x38,0x00,0x00, - - 6, // 0x36 '6' - 0x00,0x38,0x40,0x40,0x78,0x44,0x44,0x38,0x00,0x00, - - 6, // 0x37 '7' - 0x00,0x7C,0x04,0x08,0x10,0x20,0x20,0x20,0x00,0x00, - - 6, // 0x38 '8' - 0x00,0x38,0x44,0x44,0x38,0x44,0x44,0x38,0x00,0x00, - - 6, // 0x39 '9' - 0x00,0x38,0x44,0x44,0x3C,0x04,0x04,0x38,0x00,0x00, - - 6, // 0x3A ':' - 0x00,0x00,0x30,0x30,0x00,0x00,0x30,0x30,0x00,0x00, - - 6, // 0x3B ';' - 0x00,0x00,0x30,0x30,0x00,0x00,0x30,0x30,0x20,0x40, - - 6, // 0x3C '<' - 0x04,0x08,0x10,0x20,0x40,0x20,0x10,0x08,0x04,0x00, - - 6, // 0x3D '=' - 0x00,0x00,0x00,0x7C,0x00,0x00,0x7C,0x00,0x00,0x00, - - 6, // 0x3E '>' - 0x40,0x20,0x10,0x08,0x04,0x08,0x10,0x20,0x40,0x00, - - 6, // 0x3F '?' - 0x00,0x38,0x44,0x04,0x18,0x10,0x00,0x10,0x00,0x00, - - 6, // 0x40 '@' - 0x00,0x38,0x44,0x5C,0x54,0x5C,0x40,0x38,0x00,0x00, - - 6, // 0x41 'A' - 0x00,0x38,0x44,0x44,0x44,0x7C,0x44,0x44,0x00,0x00, - - 6, // 0x42 'B' - 0x00,0x78,0x44,0x44,0x78,0x44,0x44,0x78,0x00,0x00, - - 6, // 0x43 'C' - 0x00,0x38,0x44,0x40,0x40,0x40,0x44,0x38,0x00,0x00, - - 6, // 0x44 'D' - 0x00,0x78,0x44,0x44,0x44,0x44,0x44,0x78,0x00,0x00, - - 6, // 0x45 'E' - 0x00,0x7C,0x40,0x40,0x78,0x40,0x40,0x7C,0x00,0x00, - - 6, // 0x46 'F' - 0x00,0x7C,0x40,0x40,0x78,0x40,0x40,0x40,0x00,0x00, - - 6, // 0x47 'G' - 0x00,0x38,0x44,0x40,0x4C,0x44,0x44,0x3C,0x00,0x00, - - 6, // 0x48 'H' - 0x00,0x44,0x44,0x44,0x7C,0x44,0x44,0x44,0x00,0x00, - - 6, // 0x49 'I' - 0x00,0x38,0x10,0x10,0x10,0x10,0x10,0x38,0x00,0x00, - - 6, // 0x4A 'J' - 0x00,0x1C,0x08,0x08,0x08,0x48,0x48,0x30,0x00,0x00, - - 6, // 0x4B 'K' - 0x00,0x44,0x48,0x50,0x60,0x50,0x48,0x44,0x00,0x00, - - 6, // 0x4C 'L' - 0x00,0x40,0x40,0x40,0x40,0x40,0x40,0x7C,0x00,0x00, - - 6, // 0x4D 'M' - 0x00,0x44,0x6C,0x54,0x54,0x44,0x44,0x44,0x00,0x00, - - 6, // 0x4E 'N' - 0x00,0x44,0x44,0x64,0x54,0x4C,0x44,0x44,0x00,0x00, - - 6, // 0x4F 'O' - 0x00,0x38,0x44,0x44,0x44,0x44,0x44,0x38,0x00,0x00, - - 6, // 0x50 'P' - 0x00,0x78,0x44,0x44,0x78,0x40,0x40,0x40,0x00,0x00, - - 6, // 0x51 'Q' - 0x00,0x38,0x44,0x44,0x44,0x54,0x48,0x34,0x00,0x00, - - 6, // 0x52 'R' - 0x00,0x78,0x44,0x44,0x78,0x48,0x44,0x44,0x00,0x00, - - 6, // 0x53 'S' - 0x00,0x38,0x44,0x40,0x38,0x04,0x44,0x38,0x00,0x00, - - 6, // 0x54 'T' - 0x00,0x7C,0x10,0x10,0x10,0x10,0x10,0x10,0x00,0x00, - - 6, // 0x55 'U' - 0x00,0x44,0x44,0x44,0x44,0x44,0x44,0x38,0x00,0x00, - - 6, // 0x56 'V' - 0x00,0x44,0x44,0x44,0x44,0x28,0x28,0x10,0x00,0x00, - - 6, // 0x57 'W' - 0x00,0x44,0x44,0x54,0x54,0x54,0x54,0x28,0x00,0x00, - - 6, // 0x58 'X' - 0x00,0x44,0x44,0x28,0x10,0x28,0x44,0x44,0x00,0x00, - - 6, // 0x59 'Y' - 0x00,0x44,0x44,0x44,0x28,0x10,0x10,0x10,0x00,0x00, - - 6, // 0x5A 'Z' - 0x00,0x78,0x08,0x10,0x20,0x40,0x40,0x78,0x00,0x00, - - 6, // 0x5B '[' - 0x38,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x38,0x00, - - 6, // 0x5C '\' - 0x00,0x40,0x40,0x20,0x20,0x10,0x10,0x08,0x08,0x00, - - 6, // 0x5D ']' - 0x38,0x08,0x08,0x08,0x08,0x08,0x08,0x08,0x38,0x00, - - 6, // 0x5E '^' - 0x10,0x28,0x44,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x5F '_' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7C,0x00,0x00, - - 6, // 0x60 '`' - 0x00,0x10,0x10,0x20,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x61 'a' - 0x00,0x00,0x00,0x38,0x04,0x3C,0x44,0x3C,0x00,0x00, - - 6, // 0x62 'b' - 0x00,0x40,0x40,0x78,0x44,0x44,0x44,0x78,0x00,0x00, - - 6, // 0x63 'c' - 0x00,0x00,0x00,0x38,0x44,0x40,0x40,0x3C,0x00,0x00, - - 6, // 0x64 'd' - 0x00,0x04,0x04,0x3C,0x44,0x44,0x44,0x3C,0x00,0x00, - - 6, // 0x65 'e' - 0x00,0x00,0x00,0x38,0x44,0x78,0x40,0x3C,0x00,0x00, - - 6, // 0x66 'f' - 0x00,0x0C,0x10,0x10,0x38,0x10,0x10,0x10,0x00,0x00, - - 6, // 0x67 'g' - 0x00,0x00,0x00,0x3C,0x44,0x44,0x44,0x3C,0x04,0x38, - - 6, // 0x68 'h' - 0x00,0x40,0x40,0x78,0x44,0x44,0x44,0x44,0x00,0x00, - - 6, // 0x69 'i' - 0x00,0x10,0x00,0x30,0x10,0x10,0x10,0x38,0x00,0x00, - - 6, // 0x6A 'j' - 0x00,0x08,0x00,0x18,0x08,0x08,0x08,0x08,0x48,0x30, - - 6, // 0x6B 'k' - 0x00,0x40,0x40,0x48,0x50,0x60,0x50,0x48,0x00,0x00, - - 6, // 0x6C 'l' - 0x00,0x30,0x10,0x10,0x10,0x10,0x10,0x38,0x00,0x00, - - 6, // 0x6D 'm' - 0x00,0x00,0x00,0x68,0x54,0x54,0x44,0x44,0x00,0x00, - - 6, // 0x6E 'n' - 0x00,0x00,0x00,0x58,0x64,0x44,0x44,0x44,0x00,0x00, - - 6, // 0x6F 'o' - 0x00,0x00,0x00,0x38,0x44,0x44,0x44,0x38,0x00,0x00, - - 6, // 0x70 'p' - 0x00,0x00,0x00,0x78,0x44,0x44,0x44,0x78,0x40,0x40, - - 6, // 0x71 'q' - 0x00,0x00,0x00,0x3C,0x44,0x44,0x44,0x3C,0x04,0x04, - - 6, // 0x72 'r' - 0x00,0x00,0x00,0x58,0x24,0x20,0x20,0x70,0x00,0x00, - - 6, // 0x73 's' - 0x00,0x00,0x00,0x38,0x40,0x38,0x04,0x78,0x00,0x00, - - 6, // 0x74 't' - 0x00,0x10,0x10,0x38,0x10,0x10,0x14,0x08,0x00,0x00, - - 6, // 0x75 'u' - 0x00,0x00,0x00,0x44,0x44,0x44,0x4C,0x34,0x00,0x00, - - 6, // 0x76 'v' - 0x00,0x00,0x00,0x44,0x44,0x44,0x28,0x10,0x00,0x00, - - 6, // 0x77 'w' - 0x00,0x00,0x00,0x44,0x44,0x54,0x7C,0x28,0x00,0x00, - - 6, // 0x78 'x' - 0x00,0x00,0x00,0x48,0x48,0x30,0x48,0x48,0x00,0x00, - - 6, // 0x79 'y' - 0x00,0x00,0x00,0x44,0x44,0x44,0x44,0x3C,0x04,0x38, - - 6, // 0x7A 'z' - 0x00,0x00,0x00,0x78,0x08,0x30,0x40,0x78,0x00,0x00, - - 6, // 0x7B '{' - 0x18,0x20,0x20,0x20,0xC0,0x20,0x20,0x20,0x18,0x00, - - 6, // 0x7C '|' - 0x10,0x10,0x10,0x10,0x00,0x10,0x10,0x10,0x10,0x00, - - 6, // 0x7D '}' - 0x60,0x10,0x10,0x10,0x0C,0x10,0x10,0x10,0x60,0x00, - - 6, // 0x7E '~' - 0x00,0x48,0xA8,0x90,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x7F '' - 0x00,0x10,0x38,0x6C,0x44,0x44,0x7C,0x00,0x00,0x00, - - 0 - }; - - const int8u mcs6x11_mono[] = - { - 11, 3, 32, 128-32, - 0x00,0x00,0x0C,0x00,0x18,0x00,0x24,0x00,0x30,0x00,0x3C,0x00,0x48,0x00,0x54,0x00,0x60,0x00, - 0x6C,0x00,0x78,0x00,0x84,0x00,0x90,0x00,0x9C,0x00,0xA8,0x00,0xB4,0x00,0xC0,0x00,0xCC,0x00, - 0xD8,0x00,0xE4,0x00,0xF0,0x00,0xFC,0x00,0x08,0x01,0x14,0x01,0x20,0x01,0x2C,0x01,0x38,0x01, - 0x44,0x01,0x50,0x01,0x5C,0x01,0x68,0x01,0x74,0x01,0x80,0x01,0x8C,0x01,0x98,0x01,0xA4,0x01, - 0xB0,0x01,0xBC,0x01,0xC8,0x01,0xD4,0x01,0xE0,0x01,0xEC,0x01,0xF8,0x01,0x04,0x02,0x10,0x02, - 0x1C,0x02,0x28,0x02,0x34,0x02,0x40,0x02,0x4C,0x02,0x58,0x02,0x64,0x02,0x70,0x02,0x7C,0x02, - 0x88,0x02,0x94,0x02,0xA0,0x02,0xAC,0x02,0xB8,0x02,0xC4,0x02,0xD0,0x02,0xDC,0x02,0xE8,0x02, - 0xF4,0x02,0x00,0x03,0x0C,0x03,0x18,0x03,0x24,0x03,0x30,0x03,0x3C,0x03,0x48,0x03,0x54,0x03, - 0x60,0x03,0x6C,0x03,0x78,0x03,0x84,0x03,0x90,0x03,0x9C,0x03,0xA8,0x03,0xB4,0x03,0xC0,0x03, - 0xCC,0x03,0xD8,0x03,0xE4,0x03,0xF0,0x03,0xFC,0x03,0x08,0x04,0x14,0x04,0x20,0x04,0x2C,0x04, - 0x38,0x04,0x44,0x04,0x50,0x04,0x5C,0x04,0x68,0x04,0x74,0x04, - - 6, // 0x20 ' ' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x21 '!' - 0x00,0x20,0x20,0x20,0x20,0x20,0x20,0x00,0x20,0x00,0x00, - - 6, // 0x22 '"' - 0x00,0x28,0x28,0x50,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x23 '#' - 0x00,0x28,0x28,0x7C,0x28,0x28,0x7C,0x28,0x28,0x00,0x00, - - 6, // 0x24 '$' - 0x00,0x10,0x38,0x54,0x50,0x38,0x14,0x54,0x38,0x10,0x00, - - 6, // 0x25 '%' - 0x00,0x68,0xA8,0xD0,0x10,0x20,0x2C,0x54,0x58,0x00,0x00, - - 6, // 0x26 '&' - 0x00,0x20,0x50,0x50,0x20,0x54,0x54,0x48,0x34,0x00,0x00, - - 6, // 0x27 ''' - 0x00,0x10,0x10,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x28 '(' - 0x08,0x10,0x10,0x20,0x20,0x20,0x20,0x10,0x10,0x08,0x00, - - 6, // 0x29 ')' - 0x20,0x10,0x10,0x08,0x08,0x08,0x08,0x10,0x10,0x20,0x00, - - 6, // 0x2A '*' - 0x00,0x00,0x28,0x7C,0x38,0x7C,0x28,0x00,0x00,0x00,0x00, - - 6, // 0x2B '+' - 0x00,0x00,0x00,0x10,0x10,0x7C,0x10,0x10,0x00,0x00,0x00, - - 6, // 0x2C ',' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x30,0x30,0x20,0x40, - - 6, // 0x2D '-' - 0x00,0x00,0x00,0x00,0x00,0x7C,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x2E '.' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x30,0x30,0x00,0x00, - - 6, // 0x2F '/' - 0x04,0x04,0x08,0x08,0x10,0x10,0x20,0x20,0x40,0x40,0x00, - - 6, // 0x30 '0' - 0x00,0x38,0x44,0x44,0x54,0x54,0x44,0x44,0x38,0x00,0x00, - - 6, // 0x31 '1' - 0x00,0x10,0x30,0x10,0x10,0x10,0x10,0x10,0x38,0x00,0x00, - - 6, // 0x32 '2' - 0x00,0x38,0x44,0x44,0x08,0x10,0x20,0x40,0x7C,0x00,0x00, - - 6, // 0x33 '3' - 0x00,0x38,0x44,0x04,0x38,0x04,0x04,0x44,0x38,0x00,0x00, - - 6, // 0x34 '4' - 0x00,0x08,0x18,0x28,0x28,0x48,0x7C,0x08,0x08,0x00,0x00, - - 6, // 0x35 '5' - 0x00,0x7C,0x40,0x78,0x44,0x04,0x04,0x44,0x38,0x00,0x00, - - 6, // 0x36 '6' - 0x00,0x38,0x44,0x40,0x78,0x44,0x44,0x44,0x38,0x00,0x00, - - 6, // 0x37 '7' - 0x00,0x7C,0x04,0x08,0x08,0x10,0x10,0x20,0x20,0x00,0x00, - - 6, // 0x38 '8' - 0x00,0x38,0x44,0x44,0x38,0x44,0x44,0x44,0x38,0x00,0x00, - - 6, // 0x39 '9' - 0x00,0x38,0x44,0x44,0x3C,0x04,0x04,0x44,0x38,0x00,0x00, - - 6, // 0x3A ':' - 0x00,0x00,0x00,0x30,0x30,0x00,0x00,0x30,0x30,0x00,0x00, - - 6, // 0x3B ';' - 0x00,0x00,0x00,0x30,0x30,0x00,0x00,0x30,0x30,0x20,0x40, - - 6, // 0x3C '<' - 0x00,0x04,0x08,0x10,0x20,0x40,0x20,0x10,0x08,0x04,0x00, - - 6, // 0x3D '=' - 0x00,0x00,0x00,0x00,0x7C,0x00,0x00,0x7C,0x00,0x00,0x00, - - 6, // 0x3E '>' - 0x00,0x40,0x20,0x10,0x08,0x04,0x08,0x10,0x20,0x40,0x00, - - 6, // 0x3F '?' - 0x00,0x38,0x44,0x04,0x08,0x10,0x10,0x00,0x10,0x00,0x00, - - 6, // 0x40 '@' - 0x00,0x38,0x44,0x5C,0x54,0x54,0x4C,0x40,0x38,0x00,0x00, - - 6, // 0x41 'A' - 0x00,0x38,0x44,0x44,0x44,0x7C,0x44,0x44,0x44,0x00,0x00, - - 6, // 0x42 'B' - 0x00,0x78,0x44,0x44,0x78,0x44,0x44,0x44,0x78,0x00,0x00, - - 6, // 0x43 'C' - 0x00,0x38,0x44,0x40,0x40,0x40,0x40,0x44,0x38,0x00,0x00, - - 6, // 0x44 'D' - 0x00,0x70,0x48,0x44,0x44,0x44,0x44,0x48,0x70,0x00,0x00, - - 6, // 0x45 'E' - 0x00,0x7C,0x40,0x40,0x78,0x40,0x40,0x40,0x7C,0x00,0x00, - - 6, // 0x46 'F' - 0x00,0x7C,0x40,0x40,0x78,0x40,0x40,0x40,0x40,0x00,0x00, - - 6, // 0x47 'G' - 0x00,0x38,0x44,0x40,0x40,0x5C,0x44,0x4C,0x34,0x00,0x00, - - 6, // 0x48 'H' - 0x00,0x44,0x44,0x44,0x7C,0x44,0x44,0x44,0x44,0x00,0x00, - - 6, // 0x49 'I' - 0x00,0x38,0x10,0x10,0x10,0x10,0x10,0x10,0x38,0x00,0x00, - - 6, // 0x4A 'J' - 0x00,0x1C,0x08,0x08,0x08,0x08,0x48,0x48,0x30,0x00,0x00, - - 6, // 0x4B 'K' - 0x00,0x44,0x48,0x50,0x60,0x50,0x48,0x44,0x44,0x00,0x00, - - 6, // 0x4C 'L' - 0x00,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x7C,0x00,0x00, - - 6, // 0x4D 'M' - 0x00,0x44,0x6C,0x54,0x54,0x54,0x44,0x44,0x44,0x00,0x00, - - 6, // 0x4E 'N' - 0x00,0x44,0x64,0x64,0x54,0x54,0x4C,0x4C,0x44,0x00,0x00, - - 6, // 0x4F 'O' - 0x00,0x38,0x44,0x44,0x44,0x44,0x44,0x44,0x38,0x00,0x00, - - 6, // 0x50 'P' - 0x00,0x78,0x44,0x44,0x44,0x78,0x40,0x40,0x40,0x00,0x00, - - 6, // 0x51 'Q' - 0x00,0x38,0x44,0x44,0x44,0x44,0x54,0x48,0x34,0x00,0x00, - - 6, // 0x52 'R' - 0x00,0x78,0x44,0x44,0x44,0x78,0x48,0x44,0x44,0x00,0x00, - - 6, // 0x53 'S' - 0x00,0x38,0x44,0x40,0x38,0x04,0x04,0x44,0x38,0x00,0x00, - - 6, // 0x54 'T' - 0x00,0x7C,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x00,0x00, - - 6, // 0x55 'U' - 0x00,0x44,0x44,0x44,0x44,0x44,0x44,0x44,0x38,0x00,0x00, - - 6, // 0x56 'V' - 0x00,0x44,0x44,0x44,0x28,0x28,0x28,0x10,0x10,0x00,0x00, - - 6, // 0x57 'W' - 0x00,0x44,0x44,0x54,0x54,0x54,0x54,0x54,0x28,0x00,0x00, - - 6, // 0x58 'X' - 0x00,0x44,0x44,0x28,0x10,0x28,0x44,0x44,0x44,0x00,0x00, - - 6, // 0x59 'Y' - 0x00,0x44,0x44,0x44,0x28,0x10,0x10,0x10,0x10,0x00,0x00, - - 6, // 0x5A 'Z' - 0x00,0x7C,0x04,0x08,0x10,0x20,0x40,0x40,0x7C,0x00,0x00, - - 6, // 0x5B '[' - 0x38,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x38,0x00, - - 6, // 0x5C '\' - 0x80,0x80,0x40,0x40,0x20,0x20,0x10,0x10,0x08,0x08,0x00, - - 6, // 0x5D ']' - 0x38,0x08,0x08,0x08,0x08,0x08,0x08,0x08,0x08,0x38,0x00, - - 6, // 0x5E '^' - 0x00,0x10,0x28,0x44,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x5F '_' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7C,0x00,0x00, - - 6, // 0x60 '`' - 0x00,0x20,0x20,0x10,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x61 'a' - 0x00,0x00,0x00,0x38,0x04,0x3C,0x44,0x44,0x3C,0x00,0x00, - - 6, // 0x62 'b' - 0x00,0x40,0x40,0x78,0x44,0x44,0x44,0x44,0x78,0x00,0x00, - - 6, // 0x63 'c' - 0x00,0x00,0x00,0x38,0x44,0x40,0x40,0x44,0x38,0x00,0x00, - - 6, // 0x64 'd' - 0x00,0x04,0x04,0x3C,0x44,0x44,0x44,0x44,0x3C,0x00,0x00, - - 6, // 0x65 'e' - 0x00,0x00,0x00,0x38,0x44,0x7C,0x40,0x44,0x38,0x00,0x00, - - 6, // 0x66 'f' - 0x00,0x0C,0x10,0x38,0x10,0x10,0x10,0x10,0x10,0x00,0x00, - - 6, // 0x67 'g' - 0x00,0x00,0x00,0x3C,0x44,0x44,0x44,0x44,0x3C,0x04,0x78, - - 6, // 0x68 'h' - 0x00,0x40,0x40,0x78,0x44,0x44,0x44,0x44,0x44,0x00,0x00, - - 6, // 0x69 'i' - 0x00,0x10,0x00,0x30,0x10,0x10,0x10,0x10,0x38,0x00,0x00, - - 6, // 0x6A 'j' - 0x00,0x10,0x00,0x30,0x10,0x10,0x10,0x10,0x10,0x50,0x20, - - 6, // 0x6B 'k' - 0x00,0x40,0x40,0x4C,0x50,0x60,0x50,0x48,0x44,0x00,0x00, - - 6, // 0x6C 'l' - 0x00,0x30,0x10,0x10,0x10,0x10,0x10,0x10,0x38,0x00,0x00, - - 6, // 0x6D 'm' - 0x00,0x00,0x00,0x68,0x54,0x54,0x54,0x44,0x44,0x00,0x00, - - 6, // 0x6E 'n' - 0x00,0x00,0x00,0x78,0x44,0x44,0x44,0x44,0x44,0x00,0x00, - - 6, // 0x6F 'o' - 0x00,0x00,0x00,0x38,0x44,0x44,0x44,0x44,0x38,0x00,0x00, - - 6, // 0x70 'p' - 0x00,0x00,0x00,0x78,0x44,0x44,0x44,0x44,0x78,0x40,0x40, - - 6, // 0x71 'q' - 0x00,0x00,0x00,0x3C,0x44,0x44,0x44,0x44,0x3C,0x04,0x04, - - 6, // 0x72 'r' - 0x00,0x00,0x00,0x58,0x24,0x20,0x20,0x20,0x70,0x00,0x00, - - 6, // 0x73 's' - 0x00,0x00,0x00,0x38,0x44,0x30,0x08,0x44,0x38,0x00,0x00, - - 6, // 0x74 't' - 0x00,0x20,0x20,0x70,0x20,0x20,0x20,0x20,0x18,0x00,0x00, - - 6, // 0x75 'u' - 0x00,0x00,0x00,0x44,0x44,0x44,0x44,0x4C,0x34,0x00,0x00, - - 6, // 0x76 'v' - 0x00,0x00,0x00,0x44,0x44,0x28,0x28,0x10,0x10,0x00,0x00, - - 6, // 0x77 'w' - 0x00,0x00,0x00,0x44,0x44,0x44,0x54,0x7C,0x28,0x00,0x00, - - 6, // 0x78 'x' - 0x00,0x00,0x00,0x44,0x28,0x10,0x28,0x44,0x44,0x00,0x00, - - 6, // 0x79 'y' - 0x00,0x00,0x00,0x44,0x44,0x44,0x44,0x44,0x3C,0x08,0x70, - - 6, // 0x7A 'z' - 0x00,0x00,0x00,0x7C,0x08,0x10,0x20,0x40,0x7C,0x00,0x00, - - 6, // 0x7B '{' - 0x18,0x20,0x20,0x20,0xC0,0xC0,0x20,0x20,0x20,0x18,0x00, - - 6, // 0x7C '|' - 0x00,0x10,0x10,0x10,0x10,0x00,0x10,0x10,0x10,0x10,0x00, - - 6, // 0x7D '}' - 0x60,0x10,0x10,0x10,0x0C,0x0C,0x10,0x10,0x10,0x60,0x00, - - 6, // 0x7E '~' - 0x00,0x24,0x54,0x48,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x7F '' - 0x00,0x10,0x38,0x6C,0x44,0x44,0x7C,0x00,0x00,0x00,0x00, - - 0 - }; - - const int8u mcs7x12_mono_high[] = - { - 12, 3, 32, 128-32, - 0x00,0x00,0x0D,0x00,0x1A,0x00,0x27,0x00,0x34,0x00,0x41,0x00,0x4E,0x00,0x5B,0x00,0x68,0x00, - 0x75,0x00,0x82,0x00,0x8F,0x00,0x9C,0x00,0xA9,0x00,0xB6,0x00,0xC3,0x00,0xD0,0x00,0xDD,0x00, - 0xEA,0x00,0xF7,0x00,0x04,0x01,0x11,0x01,0x1E,0x01,0x2B,0x01,0x38,0x01,0x45,0x01,0x52,0x01, - 0x5F,0x01,0x6C,0x01,0x79,0x01,0x86,0x01,0x93,0x01,0xA0,0x01,0xAD,0x01,0xBA,0x01,0xC7,0x01, - 0xD4,0x01,0xE1,0x01,0xEE,0x01,0xFB,0x01,0x08,0x02,0x15,0x02,0x22,0x02,0x2F,0x02,0x3C,0x02, - 0x49,0x02,0x56,0x02,0x63,0x02,0x70,0x02,0x7D,0x02,0x8A,0x02,0x97,0x02,0xA4,0x02,0xB1,0x02, - 0xBE,0x02,0xCB,0x02,0xD8,0x02,0xE5,0x02,0xF2,0x02,0xFF,0x02,0x0C,0x03,0x19,0x03,0x26,0x03, - 0x33,0x03,0x40,0x03,0x4D,0x03,0x5A,0x03,0x67,0x03,0x74,0x03,0x81,0x03,0x8E,0x03,0x9B,0x03, - 0xA8,0x03,0xB5,0x03,0xC2,0x03,0xCF,0x03,0xDC,0x03,0xE9,0x03,0xF6,0x03,0x03,0x04,0x10,0x04, - 0x1D,0x04,0x2A,0x04,0x37,0x04,0x44,0x04,0x51,0x04,0x5E,0x04,0x6B,0x04,0x78,0x04,0x85,0x04, - 0x92,0x04,0x9F,0x04,0xAC,0x04,0xB9,0x04,0xC6,0x04,0xD3,0x04, - - 7, // 0x20 ' ' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x21 '!' - 0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x00,0x10,0x00,0x00, - - 7, // 0x22 '"' - 0x28,0x28,0x50,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x23 '#' - 0x24,0x24,0x24,0x7E,0x24,0x24,0x24,0x7E,0x24,0x24,0x24,0x00, - - 7, // 0x24 '$' - 0x10,0x10,0x38,0x54,0x50,0x38,0x14,0x54,0x38,0x10,0x10,0x00, - - 7, // 0x25 '%' - 0x32,0x54,0x64,0x08,0x08,0x10,0x10,0x26,0x2A,0x4C,0x00,0x00, - - 7, // 0x26 '&' - 0x00,0x20,0x50,0x50,0x50,0x20,0x54,0x54,0x48,0x34,0x00,0x00, - - 7, // 0x27 ''' - 0x10,0x10,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x28 '(' - 0x08,0x10,0x10,0x20,0x20,0x20,0x20,0x20,0x10,0x10,0x08,0x00, - - 7, // 0x29 ')' - 0x20,0x10,0x10,0x08,0x08,0x08,0x08,0x08,0x10,0x10,0x20,0x00, - - 7, // 0x2A '*' - 0x00,0x00,0x10,0x54,0x38,0x7C,0x38,0x54,0x10,0x00,0x00,0x00, - - 7, // 0x2B '+' - 0x00,0x00,0x00,0x00,0x10,0x10,0x7C,0x10,0x10,0x00,0x00,0x00, - - 7, // 0x2C ',' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x30,0x30,0x20,0x40, - - 7, // 0x2D '-' - 0x00,0x00,0x00,0x00,0x00,0x00,0x7C,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x2E '.' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x30,0x30,0x00,0x00, - - 7, // 0x2F '/' - 0x04,0x04,0x08,0x08,0x10,0x10,0x20,0x20,0x40,0x40,0x00,0x00, - - 7, // 0x30 '0' - 0x00,0x38,0x44,0x44,0x54,0x54,0x54,0x44,0x44,0x38,0x00,0x00, - - 7, // 0x31 '1' - 0x00,0x10,0x30,0x10,0x10,0x10,0x10,0x10,0x10,0x38,0x00,0x00, - - 7, // 0x32 '2' - 0x00,0x38,0x44,0x04,0x04,0x08,0x10,0x20,0x40,0x7C,0x00,0x00, - - 7, // 0x33 '3' - 0x00,0x38,0x44,0x04,0x04,0x38,0x04,0x04,0x44,0x38,0x00,0x00, - - 7, // 0x34 '4' - 0x00,0x08,0x18,0x28,0x28,0x48,0x48,0x7C,0x08,0x08,0x00,0x00, - - 7, // 0x35 '5' - 0x00,0x7C,0x40,0x40,0x78,0x44,0x04,0x04,0x44,0x38,0x00,0x00, - - 7, // 0x36 '6' - 0x00,0x38,0x44,0x40,0x78,0x44,0x44,0x44,0x44,0x38,0x00,0x00, - - 7, // 0x37 '7' - 0x00,0x7C,0x04,0x08,0x08,0x10,0x10,0x20,0x20,0x20,0x00,0x00, - - 7, // 0x38 '8' - 0x00,0x38,0x44,0x44,0x44,0x38,0x44,0x44,0x44,0x38,0x00,0x00, - - 7, // 0x39 '9' - 0x00,0x38,0x44,0x44,0x44,0x3C,0x04,0x04,0x44,0x38,0x00,0x00, - - 7, // 0x3A ':' - 0x00,0x00,0x00,0x30,0x30,0x00,0x00,0x00,0x30,0x30,0x00,0x00, - - 7, // 0x3B ';' - 0x00,0x00,0x00,0x30,0x30,0x00,0x00,0x00,0x30,0x30,0x20,0x40, - - 7, // 0x3C '<' - 0x00,0x04,0x08,0x10,0x20,0x40,0x20,0x10,0x08,0x04,0x00,0x00, - - 7, // 0x3D '=' - 0x00,0x00,0x00,0x00,0x7C,0x00,0x00,0x7C,0x00,0x00,0x00,0x00, - - 7, // 0x3E '>' - 0x00,0x40,0x20,0x10,0x08,0x04,0x08,0x10,0x20,0x40,0x00,0x00, - - 7, // 0x3F '?' - 0x00,0x38,0x44,0x04,0x04,0x08,0x10,0x10,0x00,0x10,0x00,0x00, - - 7, // 0x40 '@' - 0x00,0x38,0x44,0x44,0x5C,0x54,0x54,0x4C,0x40,0x38,0x00,0x00, - - 7, // 0x41 'A' - 0x00,0x38,0x44,0x44,0x44,0x7C,0x44,0x44,0x44,0x44,0x00,0x00, - - 7, // 0x42 'B' - 0x00,0x78,0x44,0x44,0x44,0x78,0x44,0x44,0x44,0x78,0x00,0x00, - - 7, // 0x43 'C' - 0x00,0x38,0x44,0x40,0x40,0x40,0x40,0x40,0x44,0x38,0x00,0x00, - - 7, // 0x44 'D' - 0x00,0x70,0x48,0x44,0x44,0x44,0x44,0x44,0x48,0x70,0x00,0x00, - - 7, // 0x45 'E' - 0x00,0x7C,0x40,0x40,0x40,0x78,0x40,0x40,0x40,0x7C,0x00,0x00, - - 7, // 0x46 'F' - 0x00,0x7C,0x40,0x40,0x40,0x78,0x40,0x40,0x40,0x40,0x00,0x00, - - 7, // 0x47 'G' - 0x00,0x38,0x44,0x40,0x40,0x5C,0x44,0x44,0x4C,0x34,0x00,0x00, - - 7, // 0x48 'H' - 0x00,0x44,0x44,0x44,0x44,0x7C,0x44,0x44,0x44,0x44,0x00,0x00, - - 7, // 0x49 'I' - 0x00,0x38,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x38,0x00,0x00, - - 7, // 0x4A 'J' - 0x00,0x1C,0x08,0x08,0x08,0x08,0x08,0x48,0x48,0x30,0x00,0x00, - - 7, // 0x4B 'K' - 0x00,0x44,0x48,0x50,0x60,0x60,0x50,0x48,0x44,0x44,0x00,0x00, - - 7, // 0x4C 'L' - 0x00,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x7C,0x00,0x00, - - 7, // 0x4D 'M' - 0x00,0x44,0x6C,0x6C,0x54,0x54,0x44,0x44,0x44,0x44,0x00,0x00, - - 7, // 0x4E 'N' - 0x00,0x44,0x64,0x64,0x54,0x54,0x4C,0x4C,0x44,0x44,0x00,0x00, - - 7, // 0x4F 'O' - 0x00,0x38,0x44,0x44,0x44,0x44,0x44,0x44,0x44,0x38,0x00,0x00, - - 7, // 0x50 'P' - 0x00,0x78,0x44,0x44,0x44,0x44,0x78,0x40,0x40,0x40,0x00,0x00, - - 7, // 0x51 'Q' - 0x00,0x38,0x44,0x44,0x44,0x44,0x44,0x54,0x48,0x34,0x00,0x00, - - 7, // 0x52 'R' - 0x00,0x78,0x44,0x44,0x44,0x44,0x78,0x48,0x44,0x44,0x00,0x00, - - 7, // 0x53 'S' - 0x00,0x38,0x44,0x40,0x40,0x38,0x04,0x04,0x44,0x38,0x00,0x00, - - 7, // 0x54 'T' - 0x00,0x7C,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x00,0x00, - - 7, // 0x55 'U' - 0x00,0x44,0x44,0x44,0x44,0x44,0x44,0x44,0x44,0x38,0x00,0x00, - - 7, // 0x56 'V' - 0x00,0x44,0x44,0x44,0x44,0x28,0x28,0x28,0x10,0x10,0x00,0x00, - - 7, // 0x57 'W' - 0x00,0x44,0x44,0x44,0x44,0x44,0x44,0x54,0x54,0x28,0x00,0x00, - - 7, // 0x58 'X' - 0x00,0x44,0x44,0x44,0x28,0x10,0x28,0x44,0x44,0x44,0x00,0x00, - - 7, // 0x59 'Y' - 0x00,0x44,0x44,0x44,0x44,0x28,0x10,0x10,0x10,0x10,0x00,0x00, - - 7, // 0x5A 'Z' - 0x00,0x7C,0x04,0x04,0x08,0x10,0x20,0x40,0x40,0x7C,0x00,0x00, - - 7, // 0x5B '[' - 0x38,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x38,0x00, - - 7, // 0x5C '\' - 0x00,0x40,0x40,0x20,0x20,0x10,0x10,0x08,0x08,0x04,0x04,0x00, - - 7, // 0x5D ']' - 0x38,0x08,0x08,0x08,0x08,0x08,0x08,0x08,0x08,0x08,0x38,0x00, - - 7, // 0x5E '^' - 0x00,0x10,0x28,0x44,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x5F '_' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7C,0x00,0x00, - - 7, // 0x60 '`' - 0x00,0x20,0x20,0x10,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x61 'a' - 0x00,0x00,0x00,0x38,0x04,0x3C,0x44,0x44,0x44,0x3C,0x00,0x00, - - 7, // 0x62 'b' - 0x00,0x40,0x40,0x78,0x44,0x44,0x44,0x44,0x44,0x78,0x00,0x00, - - 7, // 0x63 'c' - 0x00,0x00,0x00,0x38,0x44,0x40,0x40,0x40,0x44,0x38,0x00,0x00, - - 7, // 0x64 'd' - 0x00,0x04,0x04,0x3C,0x44,0x44,0x44,0x44,0x44,0x3C,0x00,0x00, - - 7, // 0x65 'e' - 0x00,0x00,0x00,0x38,0x44,0x44,0x7C,0x40,0x44,0x38,0x00,0x00, - - 7, // 0x66 'f' - 0x00,0x0C,0x10,0x38,0x10,0x10,0x10,0x10,0x10,0x10,0x00,0x00, - - 7, // 0x67 'g' - 0x00,0x00,0x00,0x3C,0x44,0x44,0x44,0x44,0x44,0x3C,0x04,0x78, - - 7, // 0x68 'h' - 0x00,0x40,0x40,0x78,0x44,0x44,0x44,0x44,0x44,0x44,0x00,0x00, - - 7, // 0x69 'i' - 0x00,0x10,0x00,0x30,0x10,0x10,0x10,0x10,0x10,0x38,0x00,0x00, - - 7, // 0x6A 'j' - 0x00,0x08,0x00,0x18,0x08,0x08,0x08,0x08,0x08,0x08,0x48,0x30, - - 7, // 0x6B 'k' - 0x00,0x40,0x40,0x44,0x48,0x50,0x60,0x50,0x48,0x44,0x00,0x00, - - 7, // 0x6C 'l' - 0x00,0x30,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x38,0x00,0x00, - - 7, // 0x6D 'm' - 0x00,0x00,0x00,0x68,0x54,0x54,0x44,0x44,0x44,0x44,0x00,0x00, - - 7, // 0x6E 'n' - 0x00,0x00,0x00,0x58,0x64,0x44,0x44,0x44,0x44,0x44,0x00,0x00, - - 7, // 0x6F 'o' - 0x00,0x00,0x00,0x38,0x44,0x44,0x44,0x44,0x44,0x38,0x00,0x00, - - 7, // 0x70 'p' - 0x00,0x00,0x00,0x78,0x44,0x44,0x44,0x44,0x44,0x78,0x40,0x40, - - 7, // 0x71 'q' - 0x00,0x00,0x00,0x3C,0x44,0x44,0x44,0x44,0x44,0x3C,0x04,0x04, - - 7, // 0x72 'r' - 0x00,0x00,0x00,0x58,0x24,0x20,0x20,0x20,0x20,0x70,0x00,0x00, - - 7, // 0x73 's' - 0x00,0x00,0x00,0x38,0x44,0x40,0x38,0x04,0x44,0x38,0x00,0x00, - - 7, // 0x74 't' - 0x00,0x20,0x20,0x70,0x20,0x20,0x20,0x20,0x24,0x18,0x00,0x00, - - 7, // 0x75 'u' - 0x00,0x00,0x00,0x44,0x44,0x44,0x44,0x44,0x4C,0x34,0x00,0x00, - - 7, // 0x76 'v' - 0x00,0x00,0x00,0x44,0x44,0x44,0x28,0x28,0x10,0x10,0x00,0x00, - - 7, // 0x77 'w' - 0x00,0x00,0x00,0x44,0x44,0x44,0x44,0x54,0x54,0x28,0x00,0x00, - - 7, // 0x78 'x' - 0x00,0x00,0x00,0x44,0x44,0x28,0x10,0x28,0x44,0x44,0x00,0x00, - - 7, // 0x79 'y' - 0x00,0x00,0x00,0x44,0x44,0x44,0x44,0x44,0x44,0x3C,0x08,0x70, - - 7, // 0x7A 'z' - 0x00,0x00,0x00,0x7C,0x04,0x08,0x10,0x20,0x40,0x7C,0x00,0x00, - - 7, // 0x7B '{' - 0x18,0x20,0x20,0x20,0x20,0xC0,0x20,0x20,0x20,0x20,0x18,0x00, - - 7, // 0x7C '|' - 0x00,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x00, - - 7, // 0x7D '}' - 0x60,0x10,0x10,0x10,0x10,0x0C,0x10,0x10,0x10,0x10,0x60,0x00, - - 7, // 0x7E '~' - 0x00,0x60,0x92,0x92,0x0C,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x7F '' - 0x00,0x10,0x38,0x6C,0x44,0x44,0x7C,0x00,0x00,0x00,0x00,0x00, - - 0 - }; - - const int8u mcs7x12_mono_low[] = - { - 12, 4, 32, 128-32, - 0x00,0x00,0x0D,0x00,0x1A,0x00,0x27,0x00,0x34,0x00,0x41,0x00,0x4E,0x00,0x5B,0x00,0x68,0x00, - 0x75,0x00,0x82,0x00,0x8F,0x00,0x9C,0x00,0xA9,0x00,0xB6,0x00,0xC3,0x00,0xD0,0x00,0xDD,0x00, - 0xEA,0x00,0xF7,0x00,0x04,0x01,0x11,0x01,0x1E,0x01,0x2B,0x01,0x38,0x01,0x45,0x01,0x52,0x01, - 0x5F,0x01,0x6C,0x01,0x79,0x01,0x86,0x01,0x93,0x01,0xA0,0x01,0xAD,0x01,0xBA,0x01,0xC7,0x01, - 0xD4,0x01,0xE1,0x01,0xEE,0x01,0xFB,0x01,0x08,0x02,0x15,0x02,0x22,0x02,0x2F,0x02,0x3C,0x02, - 0x49,0x02,0x56,0x02,0x63,0x02,0x70,0x02,0x7D,0x02,0x8A,0x02,0x97,0x02,0xA4,0x02,0xB1,0x02, - 0xBE,0x02,0xCB,0x02,0xD8,0x02,0xE5,0x02,0xF2,0x02,0xFF,0x02,0x0C,0x03,0x19,0x03,0x26,0x03, - 0x33,0x03,0x40,0x03,0x4D,0x03,0x5A,0x03,0x67,0x03,0x74,0x03,0x81,0x03,0x8E,0x03,0x9B,0x03, - 0xA8,0x03,0xB5,0x03,0xC2,0x03,0xCF,0x03,0xDC,0x03,0xE9,0x03,0xF6,0x03,0x03,0x04,0x10,0x04, - 0x1D,0x04,0x2A,0x04,0x37,0x04,0x44,0x04,0x51,0x04,0x5E,0x04,0x6B,0x04,0x78,0x04,0x85,0x04, - 0x92,0x04,0x9F,0x04,0xAC,0x04,0xB9,0x04,0xC6,0x04,0xD3,0x04, - - 7, // 0x20 ' ' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x21 '!' - 0x00,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x00,0x10,0x00,0x00, - - 7, // 0x22 '"' - 0x28,0x28,0x50,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x23 '#' - 0x00,0x28,0x28,0x7C,0x28,0x28,0x28,0x7C,0x28,0x28,0x00,0x00, - - 7, // 0x24 '$' - 0x00,0x10,0x38,0x54,0x50,0x38,0x14,0x54,0x38,0x10,0x00,0x00, - - 7, // 0x25 '%' - 0x34,0x54,0x68,0x08,0x10,0x10,0x20,0x2C,0x54,0x58,0x00,0x00, - - 7, // 0x26 '&' - 0x00,0x20,0x50,0x50,0x20,0x54,0x54,0x48,0x34,0x00,0x00,0x00, - - 7, // 0x27 ''' - 0x00,0x10,0x10,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x28 '(' - 0x08,0x10,0x10,0x20,0x20,0x20,0x20,0x20,0x10,0x10,0x08,0x00, - - 7, // 0x29 ')' - 0x20,0x10,0x10,0x08,0x08,0x08,0x08,0x08,0x10,0x10,0x20,0x00, - - 7, // 0x2A '*' - 0x00,0x00,0x10,0x54,0x38,0x7C,0x38,0x54,0x10,0x00,0x00,0x00, - - 7, // 0x2B '+' - 0x00,0x00,0x00,0x10,0x10,0x7C,0x10,0x10,0x00,0x00,0x00,0x00, - - 7, // 0x2C ',' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x30,0x30,0x20,0x40,0x00, - - 7, // 0x2D '-' - 0x00,0x00,0x00,0x00,0x00,0x7C,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x2E '.' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x30,0x30,0x00,0x00,0x00, - - 7, // 0x2F '/' - 0x04,0x04,0x08,0x08,0x10,0x10,0x20,0x20,0x40,0x40,0x00,0x00, - - 7, // 0x30 '0' - 0x00,0x38,0x44,0x44,0x54,0x54,0x44,0x44,0x38,0x00,0x00,0x00, - - 7, // 0x31 '1' - 0x00,0x10,0x30,0x10,0x10,0x10,0x10,0x10,0x38,0x00,0x00,0x00, - - 7, // 0x32 '2' - 0x00,0x38,0x44,0x44,0x08,0x10,0x20,0x40,0x7C,0x00,0x00,0x00, - - 7, // 0x33 '3' - 0x00,0x38,0x44,0x04,0x38,0x04,0x04,0x44,0x38,0x00,0x00,0x00, - - 7, // 0x34 '4' - 0x00,0x08,0x18,0x28,0x28,0x48,0x7C,0x08,0x08,0x00,0x00,0x00, - - 7, // 0x35 '5' - 0x00,0x7C,0x40,0x78,0x44,0x04,0x04,0x44,0x38,0x00,0x00,0x00, - - 7, // 0x36 '6' - 0x00,0x38,0x44,0x40,0x78,0x44,0x44,0x44,0x38,0x00,0x00,0x00, - - 7, // 0x37 '7' - 0x00,0x7C,0x04,0x08,0x08,0x10,0x10,0x20,0x20,0x00,0x00,0x00, - - 7, // 0x38 '8' - 0x00,0x38,0x44,0x44,0x38,0x44,0x44,0x44,0x38,0x00,0x00,0x00, - - 7, // 0x39 '9' - 0x00,0x38,0x44,0x44,0x44,0x3C,0x04,0x44,0x38,0x00,0x00,0x00, - - 7, // 0x3A ':' - 0x00,0x00,0x00,0x30,0x30,0x00,0x00,0x30,0x30,0x00,0x00,0x00, - - 7, // 0x3B ';' - 0x00,0x00,0x00,0x30,0x30,0x00,0x00,0x30,0x30,0x20,0x40,0x00, - - 7, // 0x3C '<' - 0x00,0x04,0x08,0x10,0x20,0x40,0x20,0x10,0x08,0x04,0x00,0x00, - - 7, // 0x3D '=' - 0x00,0x00,0x00,0x00,0x7C,0x00,0x00,0x7C,0x00,0x00,0x00,0x00, - - 7, // 0x3E '>' - 0x00,0x40,0x20,0x10,0x08,0x04,0x08,0x10,0x20,0x40,0x00,0x00, - - 7, // 0x3F '?' - 0x00,0x38,0x44,0x04,0x04,0x08,0x10,0x10,0x00,0x10,0x00,0x00, - - 7, // 0x40 '@' - 0x00,0x38,0x44,0x44,0x5C,0x54,0x4C,0x40,0x38,0x00,0x00,0x00, - - 7, // 0x41 'A' - 0x00,0x38,0x44,0x44,0x44,0x7C,0x44,0x44,0x44,0x00,0x00,0x00, - - 7, // 0x42 'B' - 0x00,0x78,0x44,0x44,0x78,0x44,0x44,0x44,0x78,0x00,0x00,0x00, - - 7, // 0x43 'C' - 0x00,0x38,0x44,0x40,0x40,0x40,0x40,0x44,0x38,0x00,0x00,0x00, - - 7, // 0x44 'D' - 0x00,0x70,0x48,0x44,0x44,0x44,0x44,0x48,0x70,0x00,0x00,0x00, - - 7, // 0x45 'E' - 0x00,0x7C,0x40,0x40,0x78,0x40,0x40,0x40,0x7C,0x00,0x00,0x00, - - 7, // 0x46 'F' - 0x00,0x7C,0x40,0x40,0x78,0x40,0x40,0x40,0x40,0x00,0x00,0x00, - - 7, // 0x47 'G' - 0x00,0x38,0x44,0x40,0x40,0x4C,0x44,0x4C,0x34,0x00,0x00,0x00, - - 7, // 0x48 'H' - 0x00,0x44,0x44,0x44,0x7C,0x44,0x44,0x44,0x44,0x00,0x00,0x00, - - 7, // 0x49 'I' - 0x00,0x38,0x10,0x10,0x10,0x10,0x10,0x10,0x38,0x00,0x00,0x00, - - 7, // 0x4A 'J' - 0x00,0x1C,0x08,0x08,0x08,0x08,0x48,0x48,0x30,0x00,0x00,0x00, - - 7, // 0x4B 'K' - 0x00,0x44,0x48,0x50,0x60,0x60,0x50,0x48,0x44,0x00,0x00,0x00, - - 7, // 0x4C 'L' - 0x00,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x7C,0x00,0x00,0x00, - - 7, // 0x4D 'M' - 0x00,0x44,0x6C,0x54,0x54,0x44,0x44,0x44,0x44,0x00,0x00,0x00, - - 7, // 0x4E 'N' - 0x00,0x44,0x64,0x64,0x54,0x54,0x4C,0x4C,0x44,0x00,0x00,0x00, - - 7, // 0x4F 'O' - 0x00,0x38,0x44,0x44,0x44,0x44,0x44,0x44,0x38,0x00,0x00,0x00, - - 7, // 0x50 'P' - 0x00,0x78,0x44,0x44,0x44,0x78,0x40,0x40,0x40,0x00,0x00,0x00, - - 7, // 0x51 'Q' - 0x00,0x38,0x44,0x44,0x44,0x44,0x54,0x48,0x34,0x00,0x00,0x00, - - 7, // 0x52 'R' - 0x00,0x78,0x44,0x44,0x44,0x78,0x48,0x44,0x44,0x00,0x00,0x00, - - 7, // 0x53 'S' - 0x00,0x38,0x44,0x40,0x38,0x04,0x44,0x44,0x38,0x00,0x00,0x00, - - 7, // 0x54 'T' - 0x00,0x7C,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x00,0x00,0x00, - - 7, // 0x55 'U' - 0x00,0x44,0x44,0x44,0x44,0x44,0x44,0x44,0x38,0x00,0x00,0x00, - - 7, // 0x56 'V' - 0x00,0x44,0x44,0x44,0x28,0x28,0x28,0x10,0x10,0x00,0x00,0x00, - - 7, // 0x57 'W' - 0x00,0x44,0x44,0x44,0x44,0x44,0x54,0x54,0x28,0x00,0x00,0x00, - - 7, // 0x58 'X' - 0x00,0x44,0x44,0x28,0x10,0x28,0x44,0x44,0x44,0x00,0x00,0x00, - - 7, // 0x59 'Y' - 0x00,0x44,0x44,0x44,0x28,0x10,0x10,0x10,0x10,0x00,0x00,0x00, - - 7, // 0x5A 'Z' - 0x00,0x7C,0x04,0x08,0x10,0x20,0x40,0x40,0x7C,0x00,0x00,0x00, - - 7, // 0x5B '[' - 0x38,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x38,0x00, - - 7, // 0x5C '\' - 0x00,0x40,0x40,0x20,0x20,0x10,0x10,0x08,0x08,0x04,0x04,0x00, - - 7, // 0x5D ']' - 0x38,0x08,0x08,0x08,0x08,0x08,0x08,0x08,0x08,0x08,0x38,0x00, - - 7, // 0x5E '^' - 0x00,0x10,0x28,0x44,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x5F '_' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7C,0x00,0x00,0x00, - - 7, // 0x60 '`' - 0x00,0x20,0x20,0x10,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x61 'a' - 0x00,0x00,0x00,0x38,0x04,0x3C,0x44,0x44,0x3C,0x00,0x00,0x00, - - 7, // 0x62 'b' - 0x00,0x40,0x40,0x78,0x44,0x44,0x44,0x44,0x78,0x00,0x00,0x00, - - 7, // 0x63 'c' - 0x00,0x00,0x00,0x38,0x44,0x40,0x40,0x44,0x38,0x00,0x00,0x00, - - 7, // 0x64 'd' - 0x00,0x04,0x04,0x3C,0x44,0x44,0x44,0x44,0x3C,0x00,0x00,0x00, - - 7, // 0x65 'e' - 0x00,0x00,0x00,0x38,0x44,0x7C,0x40,0x44,0x38,0x00,0x00,0x00, - - 7, // 0x66 'f' - 0x00,0x0C,0x10,0x38,0x10,0x10,0x10,0x10,0x10,0x00,0x00,0x00, - - 7, // 0x67 'g' - 0x00,0x00,0x00,0x3C,0x44,0x44,0x44,0x44,0x3C,0x04,0x44,0x38, - - 7, // 0x68 'h' - 0x00,0x40,0x40,0x78,0x44,0x44,0x44,0x44,0x44,0x00,0x00,0x00, - - 7, // 0x69 'i' - 0x00,0x10,0x00,0x30,0x10,0x10,0x10,0x10,0x38,0x00,0x00,0x00, - - 7, // 0x6A 'j' - 0x00,0x08,0x00,0x18,0x08,0x08,0x08,0x08,0x08,0x48,0x48,0x30, - - 7, // 0x6B 'k' - 0x00,0x40,0x40,0x4C,0x50,0x60,0x50,0x48,0x44,0x00,0x00,0x00, - - 7, // 0x6C 'l' - 0x00,0x30,0x10,0x10,0x10,0x10,0x10,0x10,0x38,0x00,0x00,0x00, - - 7, // 0x6D 'm' - 0x00,0x00,0x00,0x68,0x54,0x54,0x44,0x44,0x44,0x00,0x00,0x00, - - 7, // 0x6E 'n' - 0x00,0x00,0x00,0x58,0x64,0x44,0x44,0x44,0x44,0x00,0x00,0x00, - - 7, // 0x6F 'o' - 0x00,0x00,0x00,0x38,0x44,0x44,0x44,0x44,0x38,0x00,0x00,0x00, - - 7, // 0x70 'p' - 0x00,0x00,0x00,0x78,0x44,0x44,0x44,0x44,0x78,0x40,0x40,0x40, - - 7, // 0x71 'q' - 0x00,0x00,0x00,0x3C,0x44,0x44,0x44,0x44,0x3C,0x04,0x04,0x04, - - 7, // 0x72 'r' - 0x00,0x00,0x00,0x58,0x24,0x20,0x20,0x20,0x70,0x00,0x00,0x00, - - 7, // 0x73 's' - 0x00,0x00,0x00,0x38,0x44,0x30,0x08,0x44,0x38,0x00,0x00,0x00, - - 7, // 0x74 't' - 0x00,0x20,0x20,0x70,0x20,0x20,0x20,0x24,0x18,0x00,0x00,0x00, - - 7, // 0x75 'u' - 0x00,0x00,0x00,0x44,0x44,0x44,0x44,0x4C,0x34,0x00,0x00,0x00, - - 7, // 0x76 'v' - 0x00,0x00,0x00,0x44,0x44,0x28,0x28,0x10,0x10,0x00,0x00,0x00, - - 7, // 0x77 'w' - 0x00,0x00,0x00,0x44,0x44,0x44,0x54,0x54,0x28,0x00,0x00,0x00, - - 7, // 0x78 'x' - 0x00,0x00,0x00,0x44,0x28,0x10,0x28,0x44,0x44,0x00,0x00,0x00, - - 7, // 0x79 'y' - 0x00,0x00,0x00,0x44,0x44,0x44,0x44,0x44,0x3C,0x04,0x08,0x70, - - 7, // 0x7A 'z' - 0x00,0x00,0x00,0x7C,0x08,0x10,0x20,0x40,0x7C,0x00,0x00,0x00, - - 7, // 0x7B '{' - 0x18,0x20,0x20,0x20,0x20,0xC0,0x20,0x20,0x20,0x20,0x18,0x00, - - 7, // 0x7C '|' - 0x00,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x00, - - 7, // 0x7D '}' - 0x60,0x10,0x10,0x10,0x10,0x0C,0x10,0x10,0x10,0x10,0x60,0x00, - - 7, // 0x7E '~' - 0x00,0x24,0x54,0x48,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x7F '' - 0x00,0x10,0x38,0x6C,0x44,0x44,0x7C,0x00,0x00,0x00,0x00,0x00, - - 0 - }; - - const int8u verdana12[] = - { - 12, 3, 32, 128-32, - 0x00,0x00,0x0D,0x00,0x1A,0x00,0x27,0x00,0x34,0x00,0x41,0x00,0x5A,0x00,0x67,0x00,0x74,0x00, - 0x81,0x00,0x8E,0x00,0x9B,0x00,0xA8,0x00,0xB5,0x00,0xC2,0x00,0xCF,0x00,0xDC,0x00,0xE9,0x00, - 0xF6,0x00,0x03,0x01,0x10,0x01,0x1D,0x01,0x2A,0x01,0x37,0x01,0x44,0x01,0x51,0x01,0x5E,0x01, - 0x6B,0x01,0x78,0x01,0x85,0x01,0x92,0x01,0x9F,0x01,0xAC,0x01,0xC5,0x01,0xD2,0x01,0xDF,0x01, - 0xEC,0x01,0xF9,0x01,0x06,0x02,0x13,0x02,0x20,0x02,0x2D,0x02,0x3A,0x02,0x47,0x02,0x54,0x02, - 0x61,0x02,0x7A,0x02,0x87,0x02,0xA0,0x02,0xAD,0x02,0xC6,0x02,0xD3,0x02,0xE0,0x02,0xED,0x02, - 0xFA,0x02,0x07,0x03,0x20,0x03,0x2D,0x03,0x3A,0x03,0x47,0x03,0x54,0x03,0x61,0x03,0x6E,0x03, - 0x7B,0x03,0x88,0x03,0x95,0x03,0xA2,0x03,0xAF,0x03,0xBC,0x03,0xC9,0x03,0xD6,0x03,0xE3,0x03, - 0xF0,0x03,0xFD,0x03,0x0A,0x04,0x17,0x04,0x24,0x04,0x31,0x04,0x4A,0x04,0x57,0x04,0x64,0x04, - 0x71,0x04,0x7E,0x04,0x8B,0x04,0x98,0x04,0xA5,0x04,0xB2,0x04,0xBF,0x04,0xCC,0x04,0xD9,0x04, - 0xE6,0x04,0xF3,0x04,0x00,0x05,0x0D,0x05,0x1A,0x05,0x27,0x05, - - 3, // 0x20 ' ' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x21 '!' - 0x00,0x00,0x00,0x20,0x20,0x20,0x20,0x20,0x00,0x20,0x00,0x00, - - 5, // 0x22 '"' - 0x00,0x00,0x50,0x50,0x50,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x23 '#' - 0x00,0x00,0x00,0x00,0x28,0x7C,0x28,0x7C,0x28,0x00,0x00,0x00, - - 7, // 0x24 '$' - 0x00,0x00,0x10,0x10,0x3C,0x50,0x30,0x18,0x14,0x78,0x10,0x10, - - 11, // 0x25 '%' - 0x00,0x00,0x00,0x00,0x00,0x00,0x31,0x00,0x4A,0x00,0x4A,0x00,0x35,0x80,0x0A,0x40,0x0A,0x40,0x11,0x80,0x00,0x00,0x00,0x00, - - 7, // 0x26 '&' - 0x00,0x00,0x00,0x30,0x48,0x48,0x32,0x4A,0x44,0x3A,0x00,0x00, - - 3, // 0x27 ''' - 0x00,0x00,0x40,0x40,0x40,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 4, // 0x28 '(' - 0x00,0x00,0x10,0x20,0x40,0x40,0x40,0x40,0x40,0x40,0x20,0x10, - - 4, // 0x29 ')' - 0x00,0x00,0x80,0x40,0x20,0x20,0x20,0x20,0x20,0x20,0x40,0x80, - - 7, // 0x2A '*' - 0x00,0x10,0x54,0x38,0x54,0x10,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x2B '+' - 0x00,0x00,0x00,0x00,0x10,0x10,0x7C,0x10,0x10,0x00,0x00,0x00, - - 3, // 0x2C ',' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x40,0x40,0x80,0x00, - - 5, // 0x2D '-' - 0x00,0x00,0x00,0x00,0x00,0x00,0x70,0x00,0x00,0x00,0x00,0x00, - - 3, // 0x2E '.' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x40,0x40,0x00,0x00, - - 4, // 0x2F '/' - 0x00,0x00,0x10,0x10,0x20,0x20,0x40,0x40,0x40,0x80,0x80,0x00, - - 7, // 0x30 '0' - 0x00,0x00,0x00,0x38,0x44,0x44,0x44,0x44,0x44,0x38,0x00,0x00, - - 7, // 0x31 '1' - 0x00,0x00,0x00,0x10,0x30,0x10,0x10,0x10,0x10,0x38,0x00,0x00, - - 7, // 0x32 '2' - 0x00,0x00,0x00,0x38,0x44,0x04,0x08,0x10,0x20,0x7C,0x00,0x00, - - 7, // 0x33 '3' - 0x00,0x00,0x00,0x38,0x44,0x04,0x18,0x04,0x44,0x38,0x00,0x00, - - 7, // 0x34 '4' - 0x00,0x00,0x00,0x08,0x18,0x28,0x48,0x7C,0x08,0x08,0x00,0x00, - - 7, // 0x35 '5' - 0x00,0x00,0x00,0x7C,0x40,0x78,0x04,0x04,0x44,0x38,0x00,0x00, - - 7, // 0x36 '6' - 0x00,0x00,0x00,0x18,0x20,0x40,0x78,0x44,0x44,0x38,0x00,0x00, - - 7, // 0x37 '7' - 0x00,0x00,0x00,0x7C,0x04,0x08,0x08,0x10,0x10,0x10,0x00,0x00, - - 7, // 0x38 '8' - 0x00,0x00,0x00,0x38,0x44,0x44,0x38,0x44,0x44,0x38,0x00,0x00, - - 7, // 0x39 '9' - 0x00,0x00,0x00,0x38,0x44,0x44,0x3C,0x04,0x08,0x30,0x00,0x00, - - 4, // 0x3A ':' - 0x00,0x00,0x00,0x00,0x00,0x40,0x40,0x00,0x40,0x40,0x00,0x00, - - 4, // 0x3B ';' - 0x00,0x00,0x00,0x00,0x00,0x40,0x40,0x00,0x40,0x40,0x80,0x00, - - 7, // 0x3C '<' - 0x00,0x00,0x00,0x00,0x04,0x18,0x60,0x18,0x04,0x00,0x00,0x00, - - 7, // 0x3D '=' - 0x00,0x00,0x00,0x00,0x00,0x7C,0x00,0x7C,0x00,0x00,0x00,0x00, - - 7, // 0x3E '>' - 0x00,0x00,0x00,0x00,0x40,0x30,0x0C,0x30,0x40,0x00,0x00,0x00, - - 6, // 0x3F '?' - 0x00,0x00,0x00,0x70,0x08,0x08,0x10,0x20,0x00,0x20,0x00,0x00, - - 10, // 0x40 '@' - 0x00,0x00,0x00,0x00,0x00,0x00,0x1F,0x00,0x20,0x80,0x4E,0x80,0x52,0x80,0x52,0x80,0x4D,0x00,0x20,0x00,0x1F,0x00,0x00,0x00, - - 8, // 0x41 'A' - 0x00,0x00,0x00,0x18,0x18,0x24,0x24,0x7E,0x42,0x42,0x00,0x00, - - 7, // 0x42 'B' - 0x00,0x00,0x00,0x70,0x48,0x48,0x78,0x44,0x44,0x78,0x00,0x00, - - 8, // 0x43 'C' - 0x00,0x00,0x00,0x1C,0x22,0x40,0x40,0x40,0x22,0x1C,0x00,0x00, - - 8, // 0x44 'D' - 0x00,0x00,0x00,0x78,0x44,0x42,0x42,0x42,0x44,0x78,0x00,0x00, - - 7, // 0x45 'E' - 0x00,0x00,0x00,0x7C,0x40,0x40,0x78,0x40,0x40,0x7C,0x00,0x00, - - 6, // 0x46 'F' - 0x00,0x00,0x00,0x7C,0x40,0x40,0x78,0x40,0x40,0x40,0x00,0x00, - - 8, // 0x47 'G' - 0x00,0x00,0x00,0x1C,0x22,0x40,0x4E,0x42,0x22,0x1C,0x00,0x00, - - 8, // 0x48 'H' - 0x00,0x00,0x00,0x42,0x42,0x42,0x7E,0x42,0x42,0x42,0x00,0x00, - - 5, // 0x49 'I' - 0x00,0x00,0x00,0x70,0x20,0x20,0x20,0x20,0x20,0x70,0x00,0x00, - - 5, // 0x4A 'J' - 0x00,0x00,0x00,0x30,0x10,0x10,0x10,0x10,0x10,0xE0,0x00,0x00, - - 7, // 0x4B 'K' - 0x00,0x00,0x00,0x44,0x48,0x50,0x60,0x50,0x48,0x44,0x00,0x00, - - 6, // 0x4C 'L' - 0x00,0x00,0x00,0x40,0x40,0x40,0x40,0x40,0x40,0x7C,0x00,0x00, - - 9, // 0x4D 'M' - 0x00,0x00,0x00,0x00,0x00,0x00,0x63,0x00,0x63,0x00,0x55,0x00,0x55,0x00,0x49,0x00,0x49,0x00,0x41,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x4E 'N' - 0x00,0x00,0x00,0x42,0x62,0x52,0x4A,0x46,0x42,0x42,0x00,0x00, - - 9, // 0x4F 'O' - 0x00,0x00,0x00,0x00,0x00,0x00,0x1C,0x00,0x22,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x22,0x00,0x1C,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x50 'P' - 0x00,0x00,0x00,0x78,0x44,0x44,0x44,0x78,0x40,0x40,0x00,0x00, - - 9, // 0x51 'Q' - 0x00,0x00,0x00,0x00,0x00,0x00,0x1C,0x00,0x22,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x22,0x00,0x1C,0x00,0x04,0x00,0x03,0x00, - - 7, // 0x52 'R' - 0x00,0x00,0x00,0x78,0x44,0x44,0x78,0x50,0x48,0x44,0x00,0x00, - - 7, // 0x53 'S' - 0x00,0x00,0x00,0x38,0x44,0x40,0x38,0x04,0x44,0x38,0x00,0x00, - - 7, // 0x54 'T' - 0x00,0x00,0x00,0xFE,0x10,0x10,0x10,0x10,0x10,0x10,0x00,0x00, - - 8, // 0x55 'U' - 0x00,0x00,0x00,0x42,0x42,0x42,0x42,0x42,0x42,0x3C,0x00,0x00, - - 8, // 0x56 'V' - 0x00,0x00,0x00,0x42,0x42,0x42,0x24,0x24,0x18,0x18,0x00,0x00, - - 9, // 0x57 'W' - 0x00,0x00,0x00,0x00,0x00,0x00,0x41,0x00,0x49,0x00,0x49,0x00,0x55,0x00,0x55,0x00,0x22,0x00,0x22,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x58 'X' - 0x00,0x00,0x00,0x44,0x44,0x28,0x10,0x28,0x44,0x44,0x00,0x00, - - 7, // 0x59 'Y' - 0x00,0x00,0x00,0x44,0x44,0x28,0x28,0x10,0x10,0x10,0x00,0x00, - - 7, // 0x5A 'Z' - 0x00,0x00,0x00,0x7C,0x04,0x08,0x10,0x20,0x40,0x7C,0x00,0x00, - - 4, // 0x5B '[' - 0x00,0x00,0x60,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x60, - - 4, // 0x5C '\' - 0x00,0x00,0x80,0x80,0x40,0x40,0x40,0x20,0x20,0x10,0x10,0x00, - - 4, // 0x5D ']' - 0x00,0x00,0x60,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x60, - - 7, // 0x5E '^' - 0x00,0x00,0x00,0x10,0x28,0x44,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x5F '_' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xFC, - - 6, // 0x60 '`' - 0x00,0x00,0x20,0x10,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x61 'a' - 0x00,0x00,0x00,0x00,0x00,0x30,0x08,0x38,0x48,0x38,0x00,0x00, - - 6, // 0x62 'b' - 0x00,0x00,0x40,0x40,0x40,0x70,0x48,0x48,0x48,0x70,0x00,0x00, - - 6, // 0x63 'c' - 0x00,0x00,0x00,0x00,0x00,0x38,0x40,0x40,0x40,0x38,0x00,0x00, - - 6, // 0x64 'd' - 0x00,0x00,0x08,0x08,0x08,0x38,0x48,0x48,0x48,0x38,0x00,0x00, - - 6, // 0x65 'e' - 0x00,0x00,0x00,0x00,0x00,0x30,0x48,0x78,0x40,0x38,0x00,0x00, - - 4, // 0x66 'f' - 0x00,0x00,0x30,0x40,0x40,0xE0,0x40,0x40,0x40,0x40,0x00,0x00, - - 6, // 0x67 'g' - 0x00,0x00,0x00,0x00,0x00,0x38,0x48,0x48,0x48,0x38,0x08,0x30, - - 6, // 0x68 'h' - 0x00,0x00,0x40,0x40,0x40,0x70,0x48,0x48,0x48,0x48,0x00,0x00, - - 3, // 0x69 'i' - 0x00,0x00,0x00,0x40,0x00,0x40,0x40,0x40,0x40,0x40,0x00,0x00, - - 3, // 0x6A 'j' - 0x00,0x00,0x00,0x40,0x00,0xC0,0x40,0x40,0x40,0x40,0x40,0x80, - - 6, // 0x6B 'k' - 0x00,0x00,0x40,0x40,0x40,0x48,0x50,0x60,0x50,0x48,0x00,0x00, - - 3, // 0x6C 'l' - 0x00,0x00,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x00,0x00, - - 9, // 0x6D 'm' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x76,0x00,0x49,0x00,0x49,0x00,0x49,0x00,0x49,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x6E 'n' - 0x00,0x00,0x00,0x00,0x00,0x70,0x48,0x48,0x48,0x48,0x00,0x00, - - 6, // 0x6F 'o' - 0x00,0x00,0x00,0x00,0x00,0x30,0x48,0x48,0x48,0x30,0x00,0x00, - - 6, // 0x70 'p' - 0x00,0x00,0x00,0x00,0x00,0x70,0x48,0x48,0x48,0x70,0x40,0x40, - - 6, // 0x71 'q' - 0x00,0x00,0x00,0x00,0x00,0x38,0x48,0x48,0x48,0x38,0x08,0x08, - - 4, // 0x72 'r' - 0x00,0x00,0x00,0x00,0x00,0x50,0x60,0x40,0x40,0x40,0x00,0x00, - - 6, // 0x73 's' - 0x00,0x00,0x00,0x00,0x00,0x38,0x40,0x30,0x08,0x70,0x00,0x00, - - 4, // 0x74 't' - 0x00,0x00,0x00,0x00,0x40,0xF0,0x40,0x40,0x40,0x30,0x00,0x00, - - 6, // 0x75 'u' - 0x00,0x00,0x00,0x00,0x00,0x48,0x48,0x48,0x48,0x38,0x00,0x00, - - 6, // 0x76 'v' - 0x00,0x00,0x00,0x00,0x00,0x48,0x48,0x48,0x30,0x30,0x00,0x00, - - 7, // 0x77 'w' - 0x00,0x00,0x00,0x00,0x00,0x44,0x54,0x54,0x28,0x28,0x00,0x00, - - 6, // 0x78 'x' - 0x00,0x00,0x00,0x00,0x00,0x48,0x48,0x30,0x48,0x48,0x00,0x00, - - 6, // 0x79 'y' - 0x00,0x00,0x00,0x00,0x00,0x48,0x48,0x48,0x30,0x10,0x20,0x20, - - 5, // 0x7A 'z' - 0x00,0x00,0x00,0x00,0x00,0x70,0x10,0x20,0x40,0x70,0x00,0x00, - - 6, // 0x7B '{' - 0x00,0x00,0x18,0x20,0x20,0x20,0x20,0xC0,0x20,0x20,0x20,0x18, - - 5, // 0x7C '|' - 0x00,0x00,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20, - - 6, // 0x7D '}' - 0x00,0x00,0x60,0x10,0x10,0x10,0x10,0x0C,0x10,0x10,0x10,0x60, - - 7, // 0x7E '~' - 0x00,0x00,0x00,0x00,0x00,0x00,0x34,0x58,0x00,0x00,0x00,0x00, - - 9, // 0x7F '' - 0x00,0x00,0x00,0x00,0x00,0x00,0x7F,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x7F,0x00,0x00,0x00,0x00,0x00, - - 0 - }; - - const int8u verdana12_bold[] = - { - 12, 3, 32, 128-32, - 0x00,0x00,0x0D,0x00,0x1A,0x00,0x27,0x00,0x34,0x00,0x41,0x00,0x5A,0x00,0x67,0x00,0x74,0x00, - 0x81,0x00,0x8E,0x00,0x9B,0x00,0xA8,0x00,0xB5,0x00,0xC2,0x00,0xCF,0x00,0xDC,0x00,0xE9,0x00, - 0xF6,0x00,0x03,0x01,0x10,0x01,0x1D,0x01,0x2A,0x01,0x37,0x01,0x44,0x01,0x51,0x01,0x5E,0x01, - 0x6B,0x01,0x78,0x01,0x85,0x01,0x92,0x01,0x9F,0x01,0xAC,0x01,0xC5,0x01,0xD2,0x01,0xDF,0x01, - 0xEC,0x01,0xF9,0x01,0x06,0x02,0x13,0x02,0x20,0x02,0x2D,0x02,0x3A,0x02,0x47,0x02,0x54,0x02, - 0x61,0x02,0x6E,0x02,0x7B,0x02,0x88,0x02,0x95,0x02,0xA2,0x02,0xAF,0x02,0xBC,0x02,0xC9,0x02, - 0xD6,0x02,0xE3,0x02,0xFC,0x02,0x09,0x03,0x16,0x03,0x23,0x03,0x30,0x03,0x3D,0x03,0x4A,0x03, - 0x57,0x03,0x64,0x03,0x71,0x03,0x7E,0x03,0x8B,0x03,0x98,0x03,0xA5,0x03,0xB2,0x03,0xBF,0x03, - 0xCC,0x03,0xD9,0x03,0xE6,0x03,0xF3,0x03,0x00,0x04,0x0D,0x04,0x26,0x04,0x33,0x04,0x40,0x04, - 0x4D,0x04,0x5A,0x04,0x67,0x04,0x74,0x04,0x81,0x04,0x8E,0x04,0x9B,0x04,0xB4,0x04,0xC1,0x04, - 0xCE,0x04,0xDB,0x04,0xE8,0x04,0xF5,0x04,0x02,0x05,0x0F,0x05, - - 3, // 0x20 ' ' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 4, // 0x21 '!' - 0x00,0x00,0x00,0x60,0x60,0x60,0x60,0x60,0x00,0x60,0x00,0x00, - - 5, // 0x22 '"' - 0x00,0x00,0xD8,0xD8,0xD8,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x23 '#' - 0x00,0x00,0x00,0x14,0x14,0x7E,0x28,0xFC,0x50,0x50,0x00,0x00, - - 6, // 0x24 '$' - 0x00,0x00,0x20,0x20,0x70,0xE8,0xE0,0x38,0xB8,0x70,0x20,0x20, - - 11, // 0x25 '%' - 0x00,0x00,0x00,0x00,0x00,0x00,0x62,0x00,0x94,0x00,0x94,0x00,0x69,0x80,0x0A,0x40,0x0A,0x40,0x11,0x80,0x00,0x00,0x00,0x00, - - 8, // 0x26 '&' - 0x00,0x00,0x00,0x70,0xD8,0xD8,0x76,0xDC,0xCC,0x76,0x00,0x00, - - 3, // 0x27 ''' - 0x00,0x00,0xC0,0xC0,0xC0,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x28 '(' - 0x00,0x00,0x30,0x60,0xC0,0xC0,0xC0,0xC0,0xC0,0xC0,0x60,0x30, - - 5, // 0x29 ')' - 0x00,0x00,0xC0,0x60,0x30,0x30,0x30,0x30,0x30,0x30,0x60,0xC0, - - 6, // 0x2A '*' - 0x00,0x00,0x20,0xA8,0x70,0xA8,0x20,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x2B '+' - 0x00,0x00,0x00,0x00,0x10,0x10,0x7C,0x10,0x10,0x00,0x00,0x00, - - 3, // 0x2C ',' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xC0,0xC0,0x80,0x00, - - 4, // 0x2D '-' - 0x00,0x00,0x00,0x00,0x00,0x00,0xE0,0x00,0x00,0x00,0x00,0x00, - - 3, // 0x2E '.' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xC0,0xC0,0x00,0x00, - - 6, // 0x2F '/' - 0x00,0x00,0x08,0x08,0x10,0x10,0x20,0x40,0x40,0x80,0x80,0x00, - - 6, // 0x30 '0' - 0x00,0x00,0x00,0x70,0xD8,0xD8,0xD8,0xD8,0xD8,0x70,0x00,0x00, - - 6, // 0x31 '1' - 0x00,0x00,0x00,0x30,0x70,0x30,0x30,0x30,0x30,0x78,0x00,0x00, - - 6, // 0x32 '2' - 0x00,0x00,0x00,0x70,0x98,0x18,0x30,0x60,0xC0,0xF8,0x00,0x00, - - 6, // 0x33 '3' - 0x00,0x00,0x00,0x70,0x98,0x18,0x70,0x18,0x98,0x70,0x00,0x00, - - 6, // 0x34 '4' - 0x00,0x00,0x00,0x18,0x38,0x58,0x98,0xFC,0x18,0x18,0x00,0x00, - - 6, // 0x35 '5' - 0x00,0x00,0x00,0xF8,0xC0,0xF0,0x18,0x18,0x98,0x70,0x00,0x00, - - 6, // 0x36 '6' - 0x00,0x00,0x00,0x70,0xC0,0xF0,0xD8,0xD8,0xD8,0x70,0x00,0x00, - - 6, // 0x37 '7' - 0x00,0x00,0x00,0xF8,0x18,0x30,0x30,0x60,0x60,0xC0,0x00,0x00, - - 6, // 0x38 '8' - 0x00,0x00,0x00,0x70,0xD8,0xD8,0x70,0xD8,0xD8,0x70,0x00,0x00, - - 6, // 0x39 '9' - 0x00,0x00,0x00,0x70,0xD8,0xD8,0xD8,0x78,0x18,0x70,0x00,0x00, - - 4, // 0x3A ':' - 0x00,0x00,0x00,0x00,0x00,0x60,0x60,0x00,0x60,0x60,0x00,0x00, - - 4, // 0x3B ';' - 0x00,0x00,0x00,0x00,0x00,0x60,0x60,0x00,0x60,0x60,0x40,0x00, - - 8, // 0x3C '<' - 0x00,0x00,0x00,0x00,0x04,0x18,0x60,0x60,0x18,0x04,0x00,0x00, - - 8, // 0x3D '=' - 0x00,0x00,0x00,0x00,0x00,0x7C,0x00,0x7C,0x00,0x00,0x00,0x00, - - 8, // 0x3E '>' - 0x00,0x00,0x00,0x00,0x40,0x30,0x0C,0x0C,0x30,0x40,0x00,0x00, - - 6, // 0x3F '?' - 0x00,0x00,0x00,0xF0,0x18,0x18,0x30,0x60,0x00,0x60,0x00,0x00, - - 9, // 0x40 '@' - 0x00,0x00,0x00,0x00,0x00,0x00,0x3C,0x00,0x42,0x00,0x9D,0x00,0xA5,0x00,0xA5,0x00,0x9E,0x00,0x40,0x00,0x3C,0x00,0x00,0x00, - - 8, // 0x41 'A' - 0x00,0x00,0x00,0x38,0x38,0x6C,0x6C,0x7C,0xC6,0xC6,0x00,0x00, - - 7, // 0x42 'B' - 0x00,0x00,0x00,0xF8,0xCC,0xCC,0xF8,0xCC,0xCC,0xF8,0x00,0x00, - - 6, // 0x43 'C' - 0x00,0x00,0x00,0x70,0xC8,0xC0,0xC0,0xC0,0xC8,0x70,0x00,0x00, - - 7, // 0x44 'D' - 0x00,0x00,0x00,0xF8,0xCC,0xCC,0xCC,0xCC,0xCC,0xF8,0x00,0x00, - - 6, // 0x45 'E' - 0x00,0x00,0x00,0xF8,0xC0,0xC0,0xF8,0xC0,0xC0,0xF8,0x00,0x00, - - 6, // 0x46 'F' - 0x00,0x00,0x00,0xF8,0xC0,0xC0,0xF8,0xC0,0xC0,0xC0,0x00,0x00, - - 7, // 0x47 'G' - 0x00,0x00,0x00,0x78,0xC4,0xC0,0xC0,0xDC,0xCC,0x7C,0x00,0x00, - - 7, // 0x48 'H' - 0x00,0x00,0x00,0xCC,0xCC,0xCC,0xFC,0xCC,0xCC,0xCC,0x00,0x00, - - 5, // 0x49 'I' - 0x00,0x00,0x00,0xF0,0x60,0x60,0x60,0x60,0x60,0xF0,0x00,0x00, - - 5, // 0x4A 'J' - 0x00,0x00,0x00,0x70,0x30,0x30,0x30,0x30,0x30,0xE0,0x00,0x00, - - 7, // 0x4B 'K' - 0x00,0x00,0x00,0xCC,0xD8,0xF0,0xE0,0xF0,0xD8,0xCC,0x00,0x00, - - 6, // 0x4C 'L' - 0x00,0x00,0x00,0xC0,0xC0,0xC0,0xC0,0xC0,0xC0,0xF8,0x00,0x00, - - 8, // 0x4D 'M' - 0x00,0x00,0x00,0x82,0xC6,0xEE,0xB6,0xB6,0x86,0x86,0x00,0x00, - - 7, // 0x4E 'N' - 0x00,0x00,0x00,0x84,0xC4,0xE4,0xB4,0x9C,0x8C,0x84,0x00,0x00, - - 8, // 0x4F 'O' - 0x00,0x00,0x00,0x7C,0xC6,0xC6,0xC6,0xC6,0xC6,0x7C,0x00,0x00, - - 7, // 0x50 'P' - 0x00,0x00,0x00,0xF8,0xCC,0xCC,0xCC,0xF8,0xC0,0xC0,0x00,0x00, - - 8, // 0x51 'Q' - 0x00,0x00,0x00,0x7C,0xC6,0xC6,0xC6,0xC6,0xC6,0x7C,0x18,0x0E, - - 7, // 0x52 'R' - 0x00,0x00,0x00,0xF8,0xCC,0xCC,0xF8,0xD8,0xCC,0xC6,0x00,0x00, - - 6, // 0x53 'S' - 0x00,0x00,0x00,0x70,0xC8,0xC0,0x70,0x18,0x98,0x70,0x00,0x00, - - 6, // 0x54 'T' - 0x00,0x00,0x00,0xFC,0x30,0x30,0x30,0x30,0x30,0x30,0x00,0x00, - - 7, // 0x55 'U' - 0x00,0x00,0x00,0xCC,0xCC,0xCC,0xCC,0xCC,0xCC,0x78,0x00,0x00, - - 7, // 0x56 'V' - 0x00,0x00,0x00,0xCC,0xCC,0x78,0x78,0x78,0x30,0x30,0x00,0x00, - - 11, // 0x57 'W' - 0x00,0x00,0x00,0x00,0x00,0x00,0xCC,0xC0,0xCC,0xC0,0x6D,0x80,0x6D,0x80,0x73,0x80,0x33,0x00,0x33,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x58 'X' - 0x00,0x00,0x00,0xCC,0xCC,0x78,0x30,0x78,0xCC,0xCC,0x00,0x00, - - 7, // 0x59 'Y' - 0x00,0x00,0x00,0xCC,0xCC,0x78,0x30,0x30,0x30,0x30,0x00,0x00, - - 6, // 0x5A 'Z' - 0x00,0x00,0x00,0xF8,0x18,0x30,0x60,0xC0,0xC0,0xF8,0x00,0x00, - - 5, // 0x5B '[' - 0x00,0x00,0x70,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x70, - - 6, // 0x5C '\' - 0x00,0x00,0x80,0x80,0x40,0x40,0x20,0x10,0x10,0x08,0x08,0x00, - - 5, // 0x5D ']' - 0x00,0x00,0x70,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x70, - - 8, // 0x5E '^' - 0x00,0x00,0x00,0x18,0x3C,0x66,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x5F '_' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xFC, - - 6, // 0x60 '`' - 0x00,0x00,0x30,0x18,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x61 'a' - 0x00,0x00,0x00,0x00,0x00,0x70,0x18,0x78,0xD8,0x78,0x00,0x00, - - 6, // 0x62 'b' - 0x00,0x00,0xC0,0xC0,0xC0,0xF0,0xD8,0xD8,0xD8,0xF0,0x00,0x00, - - 5, // 0x63 'c' - 0x00,0x00,0x00,0x00,0x00,0x70,0xC0,0xC0,0xC0,0x70,0x00,0x00, - - 6, // 0x64 'd' - 0x00,0x00,0x18,0x18,0x18,0x78,0xD8,0xD8,0xD8,0x78,0x00,0x00, - - 6, // 0x65 'e' - 0x00,0x00,0x00,0x00,0x00,0x70,0xD8,0xF8,0xC0,0x78,0x00,0x00, - - 5, // 0x66 'f' - 0x00,0x00,0x38,0x60,0x60,0xF8,0x60,0x60,0x60,0x60,0x00,0x00, - - 6, // 0x67 'g' - 0x00,0x00,0x00,0x00,0x00,0x78,0xD8,0xD8,0xD8,0x78,0x18,0x70, - - 6, // 0x68 'h' - 0x00,0x00,0xC0,0xC0,0xC0,0xF0,0xD8,0xD8,0xD8,0xD8,0x00,0x00, - - 3, // 0x69 'i' - 0x00,0x00,0x00,0xC0,0x00,0xC0,0xC0,0xC0,0xC0,0xC0,0x00,0x00, - - 4, // 0x6A 'j' - 0x00,0x00,0x00,0x60,0x00,0xE0,0x60,0x60,0x60,0x60,0x60,0xC0, - - 6, // 0x6B 'k' - 0x00,0x00,0xC0,0xC0,0xC0,0xD8,0xD8,0xF0,0xD8,0xD8,0x00,0x00, - - 3, // 0x6C 'l' - 0x00,0x00,0xC0,0xC0,0xC0,0xC0,0xC0,0xC0,0xC0,0xC0,0x00,0x00, - - 9, // 0x6D 'm' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xF6,0x00,0xDB,0x00,0xDB,0x00,0xDB,0x00,0xDB,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x6E 'n' - 0x00,0x00,0x00,0x00,0x00,0xF0,0xD8,0xD8,0xD8,0xD8,0x00,0x00, - - 6, // 0x6F 'o' - 0x00,0x00,0x00,0x00,0x00,0x70,0xD8,0xD8,0xD8,0x70,0x00,0x00, - - 6, // 0x70 'p' - 0x00,0x00,0x00,0x00,0x00,0xF0,0xD8,0xD8,0xD8,0xF0,0xC0,0xC0, - - 6, // 0x71 'q' - 0x00,0x00,0x00,0x00,0x00,0x78,0xD8,0xD8,0xD8,0x78,0x18,0x18, - - 4, // 0x72 'r' - 0x00,0x00,0x00,0x00,0x00,0xD0,0xE0,0xC0,0xC0,0xC0,0x00,0x00, - - 5, // 0x73 's' - 0x00,0x00,0x00,0x00,0x00,0x70,0xC0,0xF0,0x30,0xE0,0x00,0x00, - - 5, // 0x74 't' - 0x00,0x00,0x00,0x60,0x60,0xF8,0x60,0x60,0x60,0x38,0x00,0x00, - - 6, // 0x75 'u' - 0x00,0x00,0x00,0x00,0x00,0xD8,0xD8,0xD8,0xD8,0x78,0x00,0x00, - - 6, // 0x76 'v' - 0x00,0x00,0x00,0x00,0x00,0xD8,0xD8,0xD8,0x70,0x70,0x00,0x00, - - 9, // 0x77 'w' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xDB,0x00,0xDB,0x00,0xDB,0x00,0x66,0x00,0x66,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x78 'x' - 0x00,0x00,0x00,0x00,0x00,0xD8,0xD8,0x70,0xD8,0xD8,0x00,0x00, - - 6, // 0x79 'y' - 0x00,0x00,0x00,0x00,0x00,0xD8,0xD8,0xD8,0x70,0x70,0x30,0x60, - - 5, // 0x7A 'z' - 0x00,0x00,0x00,0x00,0x00,0xF0,0x30,0x60,0xC0,0xF0,0x00,0x00, - - 6, // 0x7B '{' - 0x00,0x00,0x18,0x30,0x30,0x30,0xE0,0x30,0x30,0x30,0x30,0x18, - - 5, // 0x7C '|' - 0x00,0x00,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20, - - 6, // 0x7D '}' - 0x00,0x00,0xC0,0x60,0x60,0x60,0x38,0x60,0x60,0x60,0x60,0xC0, - - 8, // 0x7E '~' - 0x00,0x00,0x00,0x00,0x00,0x00,0x62,0x92,0x8C,0x00,0x00,0x00, - - 9, // 0x7F '' - 0x00,0x00,0x00,0x00,0x00,0x00,0x7F,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x7F,0x00,0x00,0x00,0x00,0x00, - - 0 - }; - - const int8u verdana13[] = - { - 13, 3, 32, 128-32, - 0x00,0x00,0x0E,0x00,0x1C,0x00,0x2A,0x00,0x45,0x00,0x53,0x00,0x6E,0x00,0x7C,0x00,0x8A,0x00, - 0x98,0x00,0xA6,0x00,0xB4,0x00,0xCF,0x00,0xDD,0x00,0xEB,0x00,0xF9,0x00,0x07,0x01,0x15,0x01, - 0x23,0x01,0x31,0x01,0x3F,0x01,0x4D,0x01,0x5B,0x01,0x69,0x01,0x77,0x01,0x85,0x01,0x93,0x01, - 0xA1,0x01,0xAF,0x01,0xCA,0x01,0xE5,0x01,0x00,0x02,0x0E,0x02,0x29,0x02,0x37,0x02,0x45,0x02, - 0x60,0x02,0x7B,0x02,0x89,0x02,0x97,0x02,0xB2,0x02,0xC0,0x02,0xCE,0x02,0xDC,0x02,0xEA,0x02, - 0xF8,0x02,0x13,0x03,0x21,0x03,0x3C,0x03,0x4A,0x03,0x65,0x03,0x73,0x03,0x81,0x03,0x8F,0x03, - 0x9D,0x03,0xAB,0x03,0xC6,0x03,0xD4,0x03,0xE2,0x03,0xF0,0x03,0xFE,0x03,0x0C,0x04,0x1A,0x04, - 0x35,0x04,0x43,0x04,0x51,0x04,0x5F,0x04,0x6D,0x04,0x7B,0x04,0x89,0x04,0x97,0x04,0xA5,0x04, - 0xB3,0x04,0xC1,0x04,0xCF,0x04,0xDD,0x04,0xEB,0x04,0xF9,0x04,0x14,0x05,0x22,0x05,0x30,0x05, - 0x3E,0x05,0x4C,0x05,0x5A,0x05,0x68,0x05,0x76,0x05,0x84,0x05,0x92,0x05,0xAD,0x05,0xBB,0x05, - 0xC9,0x05,0xD7,0x05,0xE5,0x05,0xF3,0x05,0x01,0x06,0x1C,0x06, - - 4, // 0x20 ' ' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 4, // 0x21 '!' - 0x00,0x00,0x00,0x20,0x20,0x20,0x20,0x20,0x20,0x00,0x20,0x00,0x00, - - 5, // 0x22 '"' - 0x00,0x00,0x50,0x50,0x50,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x23 '#' - 0x00,0x00,0x00,0x00,0x00,0x00,0x0A,0x00,0x0A,0x00,0x3F,0x00,0x14,0x00,0x14,0x00,0x7E,0x00,0x28,0x00,0x28,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x24 '$' - 0x00,0x00,0x10,0x10,0x3C,0x50,0x50,0x38,0x14,0x14,0x78,0x10,0x10, - - 12, // 0x25 '%' - 0x00,0x00,0x00,0x00,0x00,0x00,0x31,0x00,0x49,0x00,0x4A,0x00,0x32,0x00,0x04,0xC0,0x05,0x20,0x09,0x20,0x08,0xC0,0x00,0x00,0x00,0x00, - - 8, // 0x26 '&' - 0x00,0x00,0x00,0x30,0x48,0x48,0x32,0x4A,0x44,0x46,0x39,0x00,0x00, - - 3, // 0x27 ''' - 0x00,0x00,0x40,0x40,0x40,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x28 '(' - 0x00,0x00,0x10,0x20,0x20,0x40,0x40,0x40,0x40,0x40,0x20,0x20,0x10, - - 5, // 0x29 ')' - 0x00,0x00,0x40,0x20,0x20,0x10,0x10,0x10,0x10,0x10,0x20,0x20,0x40, - - 7, // 0x2A '*' - 0x00,0x00,0x10,0x54,0x38,0x54,0x10,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x2B '+' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x7F,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x00,0x00,0x00,0x00, - - 4, // 0x2C ',' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,0x20,0x20,0x40, - - 5, // 0x2D '-' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x70,0x00,0x00,0x00,0x00,0x00, - - 4, // 0x2E '.' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,0x20,0x00,0x00, - - 5, // 0x2F '/' - 0x00,0x00,0x08,0x08,0x10,0x10,0x20,0x20,0x40,0x40,0x80,0x80,0x00, - - 7, // 0x30 '0' - 0x00,0x00,0x00,0x38,0x44,0x44,0x44,0x44,0x44,0x44,0x38,0x00,0x00, - - 7, // 0x31 '1' - 0x00,0x00,0x00,0x10,0x70,0x10,0x10,0x10,0x10,0x10,0x7C,0x00,0x00, - - 7, // 0x32 '2' - 0x00,0x00,0x00,0x38,0x44,0x04,0x08,0x10,0x20,0x40,0x7C,0x00,0x00, - - 7, // 0x33 '3' - 0x00,0x00,0x00,0x38,0x44,0x04,0x18,0x04,0x04,0x44,0x38,0x00,0x00, - - 7, // 0x34 '4' - 0x00,0x00,0x00,0x08,0x18,0x28,0x48,0x88,0xFC,0x08,0x08,0x00,0x00, - - 7, // 0x35 '5' - 0x00,0x00,0x00,0x7C,0x40,0x40,0x78,0x04,0x04,0x44,0x38,0x00,0x00, - - 7, // 0x36 '6' - 0x00,0x00,0x00,0x18,0x20,0x40,0x78,0x44,0x44,0x44,0x38,0x00,0x00, - - 7, // 0x37 '7' - 0x00,0x00,0x00,0x7C,0x04,0x08,0x08,0x10,0x10,0x20,0x20,0x00,0x00, - - 7, // 0x38 '8' - 0x00,0x00,0x00,0x38,0x44,0x44,0x38,0x44,0x44,0x44,0x38,0x00,0x00, - - 7, // 0x39 '9' - 0x00,0x00,0x00,0x38,0x44,0x44,0x44,0x3C,0x04,0x08,0x30,0x00,0x00, - - 5, // 0x3A ':' - 0x00,0x00,0x00,0x00,0x00,0x20,0x20,0x00,0x00,0x20,0x20,0x00,0x00, - - 5, // 0x3B ';' - 0x00,0x00,0x00,0x00,0x00,0x20,0x20,0x00,0x00,0x20,0x20,0x20,0x40, - - 9, // 0x3C '<' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x06,0x00,0x18,0x00,0x60,0x00,0x18,0x00,0x06,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x3D '=' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7F,0x00,0x00,0x00,0x7F,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x3E '>' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x30,0x00,0x0C,0x00,0x03,0x00,0x0C,0x00,0x30,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x3F '?' - 0x00,0x00,0x00,0x70,0x08,0x08,0x10,0x20,0x20,0x00,0x20,0x00,0x00, - - 10, // 0x40 '@' - 0x00,0x00,0x00,0x00,0x00,0x00,0x1F,0x00,0x20,0x80,0x4E,0x80,0x52,0x80,0x52,0x80,0x52,0x80,0x4D,0x00,0x20,0x00,0x1E,0x00,0x00,0x00, - - 8, // 0x41 'A' - 0x00,0x00,0x00,0x18,0x18,0x24,0x24,0x24,0x7E,0x42,0x42,0x00,0x00, - - 8, // 0x42 'B' - 0x00,0x00,0x00,0x78,0x44,0x44,0x7C,0x42,0x42,0x42,0x7C,0x00,0x00, - - 9, // 0x43 'C' - 0x00,0x00,0x00,0x00,0x00,0x00,0x1E,0x00,0x21,0x00,0x40,0x00,0x40,0x00,0x40,0x00,0x40,0x00,0x21,0x00,0x1E,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x44 'D' - 0x00,0x00,0x00,0x00,0x00,0x00,0x7C,0x00,0x42,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x42,0x00,0x7C,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x45 'E' - 0x00,0x00,0x00,0x7C,0x40,0x40,0x7C,0x40,0x40,0x40,0x7C,0x00,0x00, - - 6, // 0x46 'F' - 0x00,0x00,0x00,0x7C,0x40,0x40,0x78,0x40,0x40,0x40,0x40,0x00,0x00, - - 9, // 0x47 'G' - 0x00,0x00,0x00,0x00,0x00,0x00,0x1E,0x00,0x21,0x00,0x40,0x00,0x40,0x00,0x47,0x00,0x41,0x00,0x21,0x00,0x1E,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x48 'H' - 0x00,0x00,0x00,0x42,0x42,0x42,0x7E,0x42,0x42,0x42,0x42,0x00,0x00, - - 5, // 0x49 'I' - 0x00,0x00,0x00,0x70,0x20,0x20,0x20,0x20,0x20,0x20,0x70,0x00,0x00, - - 5, // 0x4A 'J' - 0x00,0x00,0x00,0x70,0x10,0x10,0x10,0x10,0x10,0x10,0xE0,0x00,0x00, - - 8, // 0x4B 'K' - 0x00,0x00,0x00,0x42,0x44,0x48,0x50,0x70,0x48,0x44,0x42,0x00,0x00, - - 6, // 0x4C 'L' - 0x00,0x00,0x00,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x7C,0x00,0x00, - - 9, // 0x4D 'M' - 0x00,0x00,0x00,0x00,0x00,0x00,0x63,0x00,0x63,0x00,0x55,0x00,0x55,0x00,0x49,0x00,0x49,0x00,0x41,0x00,0x41,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x4E 'N' - 0x00,0x00,0x00,0x62,0x62,0x52,0x52,0x4A,0x4A,0x46,0x46,0x00,0x00, - - 9, // 0x4F 'O' - 0x00,0x00,0x00,0x00,0x00,0x00,0x1C,0x00,0x22,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x22,0x00,0x1C,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x50 'P' - 0x00,0x00,0x00,0x78,0x44,0x44,0x44,0x78,0x40,0x40,0x40,0x00,0x00, - - 9, // 0x51 'Q' - 0x00,0x00,0x00,0x00,0x00,0x00,0x1C,0x00,0x22,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x22,0x00,0x1C,0x00,0x04,0x00,0x03,0x00, - - 8, // 0x52 'R' - 0x00,0x00,0x00,0x78,0x44,0x44,0x44,0x78,0x48,0x44,0x42,0x00,0x00, - - 8, // 0x53 'S' - 0x00,0x00,0x00,0x3C,0x42,0x40,0x30,0x0C,0x02,0x42,0x3C,0x00,0x00, - - 7, // 0x54 'T' - 0x00,0x00,0x00,0xFE,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x00,0x00, - - 8, // 0x55 'U' - 0x00,0x00,0x00,0x42,0x42,0x42,0x42,0x42,0x42,0x42,0x3C,0x00,0x00, - - 8, // 0x56 'V' - 0x00,0x00,0x00,0x42,0x42,0x42,0x24,0x24,0x24,0x18,0x18,0x00,0x00, - - 11, // 0x57 'W' - 0x00,0x00,0x00,0x00,0x00,0x00,0x44,0x40,0x44,0x40,0x2A,0x80,0x2A,0x80,0x2A,0x80,0x2A,0x80,0x11,0x00,0x11,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x58 'X' - 0x00,0x00,0x00,0x42,0x42,0x24,0x18,0x18,0x24,0x42,0x42,0x00,0x00, - - 7, // 0x59 'Y' - 0x00,0x00,0x00,0x82,0x44,0x28,0x10,0x10,0x10,0x10,0x10,0x00,0x00, - - 8, // 0x5A 'Z' - 0x00,0x00,0x00,0x7E,0x02,0x04,0x08,0x10,0x20,0x40,0x7E,0x00,0x00, - - 5, // 0x5B '[' - 0x00,0x00,0x70,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x70, - - 5, // 0x5C '\' - 0x00,0x00,0x80,0x80,0x40,0x40,0x20,0x20,0x10,0x10,0x08,0x08,0x00, - - 5, // 0x5D ']' - 0x00,0x00,0x70,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x70, - - 9, // 0x5E '^' - 0x00,0x00,0x00,0x00,0x00,0x00,0x08,0x00,0x14,0x00,0x22,0x00,0x41,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x5F '_' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xFE, - - 7, // 0x60 '`' - 0x00,0x00,0x20,0x10,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x61 'a' - 0x00,0x00,0x00,0x00,0x00,0x38,0x04,0x3C,0x44,0x44,0x3C,0x00,0x00, - - 7, // 0x62 'b' - 0x00,0x00,0x40,0x40,0x40,0x78,0x44,0x44,0x44,0x44,0x78,0x00,0x00, - - 6, // 0x63 'c' - 0x00,0x00,0x00,0x00,0x00,0x38,0x44,0x40,0x40,0x44,0x38,0x00,0x00, - - 7, // 0x64 'd' - 0x00,0x00,0x04,0x04,0x04,0x3C,0x44,0x44,0x44,0x44,0x3C,0x00,0x00, - - 7, // 0x65 'e' - 0x00,0x00,0x00,0x00,0x00,0x38,0x44,0x7C,0x40,0x44,0x38,0x00,0x00, - - 4, // 0x66 'f' - 0x00,0x00,0x30,0x40,0x40,0xF0,0x40,0x40,0x40,0x40,0x40,0x00,0x00, - - 7, // 0x67 'g' - 0x00,0x00,0x00,0x00,0x00,0x3C,0x44,0x44,0x44,0x44,0x3C,0x04,0x38, - - 7, // 0x68 'h' - 0x00,0x00,0x40,0x40,0x40,0x78,0x44,0x44,0x44,0x44,0x44,0x00,0x00, - - 3, // 0x69 'i' - 0x00,0x00,0x40,0x00,0x00,0x40,0x40,0x40,0x40,0x40,0x40,0x00,0x00, - - 4, // 0x6A 'j' - 0x00,0x00,0x20,0x00,0x00,0x60,0x20,0x20,0x20,0x20,0x20,0x20,0xC0, - - 7, // 0x6B 'k' - 0x00,0x00,0x40,0x40,0x40,0x44,0x48,0x50,0x70,0x48,0x44,0x00,0x00, - - 3, // 0x6C 'l' - 0x00,0x00,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x00,0x00, - - 11, // 0x6D 'm' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7B,0x80,0x44,0x40,0x44,0x40,0x44,0x40,0x44,0x40,0x44,0x40,0x00,0x00,0x00,0x00, - - 7, // 0x6E 'n' - 0x00,0x00,0x00,0x00,0x00,0x78,0x44,0x44,0x44,0x44,0x44,0x00,0x00, - - 7, // 0x6F 'o' - 0x00,0x00,0x00,0x00,0x00,0x38,0x44,0x44,0x44,0x44,0x38,0x00,0x00, - - 7, // 0x70 'p' - 0x00,0x00,0x00,0x00,0x00,0x78,0x44,0x44,0x44,0x44,0x78,0x40,0x40, - - 7, // 0x71 'q' - 0x00,0x00,0x00,0x00,0x00,0x3C,0x44,0x44,0x44,0x44,0x3C,0x04,0x04, - - 5, // 0x72 'r' - 0x00,0x00,0x00,0x00,0x00,0x58,0x60,0x40,0x40,0x40,0x40,0x00,0x00, - - 6, // 0x73 's' - 0x00,0x00,0x00,0x00,0x00,0x38,0x40,0x60,0x18,0x08,0x70,0x00,0x00, - - 4, // 0x74 't' - 0x00,0x00,0x00,0x40,0x40,0xF0,0x40,0x40,0x40,0x40,0x30,0x00,0x00, - - 7, // 0x75 'u' - 0x00,0x00,0x00,0x00,0x00,0x44,0x44,0x44,0x44,0x44,0x3C,0x00,0x00, - - 7, // 0x76 'v' - 0x00,0x00,0x00,0x00,0x00,0x44,0x44,0x28,0x28,0x10,0x10,0x00,0x00, - - 9, // 0x77 'w' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x49,0x00,0x49,0x00,0x55,0x00,0x55,0x00,0x22,0x00,0x22,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x78 'x' - 0x00,0x00,0x00,0x00,0x00,0x44,0x28,0x10,0x10,0x28,0x44,0x00,0x00, - - 7, // 0x79 'y' - 0x00,0x00,0x00,0x00,0x00,0x44,0x28,0x28,0x28,0x10,0x10,0x10,0x20, - - 6, // 0x7A 'z' - 0x00,0x00,0x00,0x00,0x00,0x78,0x08,0x10,0x20,0x40,0x78,0x00,0x00, - - 7, // 0x7B '{' - 0x00,0x00,0x0C,0x10,0x10,0x10,0x10,0x60,0x10,0x10,0x10,0x10,0x0C, - - 5, // 0x7C '|' - 0x00,0x00,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20, - - 7, // 0x7D '}' - 0x00,0x00,0x60,0x10,0x10,0x10,0x10,0x0C,0x10,0x10,0x10,0x10,0x60, - - 9, // 0x7E '~' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x31,0x00,0x49,0x00,0x46,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x7F '' - 0x00,0x00,0x00,0x00,0x00,0x00,0x7F,0x80,0x40,0x80,0x40,0x80,0x40,0x80,0x40,0x80,0x40,0x80,0x40,0x80,0x7F,0x80,0x00,0x00,0x00,0x00, - - 0 - }; - - const int8u verdana13_bold[] = - { - 13, 3, 32, 128-32, - 0x00,0x00,0x0E,0x00,0x1C,0x00,0x2A,0x00,0x45,0x00,0x53,0x00,0x6E,0x00,0x89,0x00,0x97,0x00, - 0xA5,0x00,0xB3,0x00,0xC1,0x00,0xDC,0x00,0xEA,0x00,0xF8,0x00,0x06,0x01,0x14,0x01,0x22,0x01, - 0x30,0x01,0x3E,0x01,0x4C,0x01,0x5A,0x01,0x68,0x01,0x76,0x01,0x84,0x01,0x92,0x01,0xA0,0x01, - 0xAE,0x01,0xBC,0x01,0xD7,0x01,0xF2,0x01,0x0D,0x02,0x1B,0x02,0x36,0x02,0x51,0x02,0x5F,0x02, - 0x6D,0x02,0x88,0x02,0x96,0x02,0xA4,0x02,0xBF,0x02,0xDA,0x02,0xE8,0x02,0xF6,0x02,0x04,0x03, - 0x12,0x03,0x2D,0x03,0x48,0x03,0x63,0x03,0x71,0x03,0x8C,0x03,0x9A,0x03,0xA8,0x03,0xB6,0x03, - 0xD1,0x03,0xDF,0x03,0xFA,0x03,0x08,0x04,0x16,0x04,0x24,0x04,0x32,0x04,0x40,0x04,0x4E,0x04, - 0x69,0x04,0x77,0x04,0x85,0x04,0x93,0x04,0xA1,0x04,0xAF,0x04,0xBD,0x04,0xCB,0x04,0xD9,0x04, - 0xE7,0x04,0xF5,0x04,0x03,0x05,0x11,0x05,0x1F,0x05,0x2D,0x05,0x48,0x05,0x56,0x05,0x64,0x05, - 0x72,0x05,0x80,0x05,0x8E,0x05,0x9C,0x05,0xAA,0x05,0xB8,0x05,0xC6,0x05,0xE1,0x05,0xEF,0x05, - 0xFD,0x05,0x0B,0x06,0x19,0x06,0x27,0x06,0x35,0x06,0x50,0x06, - - 4, // 0x20 ' ' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 4, // 0x21 '!' - 0x00,0x00,0x00,0x60,0x60,0x60,0x60,0x60,0x60,0x00,0x60,0x00,0x00, - - 7, // 0x22 '"' - 0x00,0x00,0x6C,0x6C,0x6C,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x23 '#' - 0x00,0x00,0x00,0x00,0x00,0x00,0x0A,0x00,0x0A,0x00,0x3F,0x00,0x14,0x00,0x14,0x00,0x7E,0x00,0x28,0x00,0x28,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x24 '$' - 0x00,0x00,0x08,0x08,0x3C,0x6A,0x68,0x3C,0x16,0x56,0x3C,0x10,0x10, - - 14, // 0x25 '%' - 0x00,0x00,0x00,0x00,0x00,0x00,0x38,0x80,0x6C,0x80,0x6D,0x00,0x6D,0x70,0x3A,0xD8,0x02,0xD8,0x04,0xD8,0x04,0x70,0x00,0x00,0x00,0x00, - - 10, // 0x26 '&' - 0x00,0x00,0x00,0x00,0x00,0x00,0x38,0x00,0x6C,0x00,0x6C,0x00,0x39,0x80,0x6D,0x00,0x66,0x00,0x63,0x00,0x3D,0x80,0x00,0x00,0x00,0x00, - - 4, // 0x27 ''' - 0x00,0x00,0x60,0x60,0x60,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x28 '(' - 0x00,0x00,0x18,0x30,0x30,0x60,0x60,0x60,0x60,0x60,0x30,0x30,0x18, - - 6, // 0x29 ')' - 0x00,0x00,0x60,0x30,0x30,0x18,0x18,0x18,0x18,0x18,0x30,0x30,0x60, - - 8, // 0x2A '*' - 0x00,0x00,0x10,0x54,0x38,0x54,0x10,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x2B '+' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x7F,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x00,0x00,0x00,0x00, - - 4, // 0x2C ',' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x60,0x60,0x60,0x40, - - 6, // 0x2D '-' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x78,0x00,0x00,0x00,0x00,0x00, - - 4, // 0x2E '.' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x60,0x60,0x00,0x00, - - 8, // 0x2F '/' - 0x00,0x00,0x06,0x06,0x0C,0x0C,0x18,0x18,0x18,0x30,0x30,0x60,0x60, - - 8, // 0x30 '0' - 0x00,0x00,0x00,0x3C,0x66,0x66,0x66,0x66,0x66,0x66,0x3C,0x00,0x00, - - 8, // 0x31 '1' - 0x00,0x00,0x00,0x18,0x38,0x18,0x18,0x18,0x18,0x18,0x3C,0x00,0x00, - - 8, // 0x32 '2' - 0x00,0x00,0x00,0x3C,0x66,0x06,0x0C,0x18,0x30,0x60,0x7E,0x00,0x00, - - 8, // 0x33 '3' - 0x00,0x00,0x00,0x3C,0x66,0x06,0x1C,0x06,0x06,0x66,0x3C,0x00,0x00, - - 8, // 0x34 '4' - 0x00,0x00,0x00,0x04,0x0C,0x1C,0x2C,0x4C,0x7E,0x0C,0x0C,0x00,0x00, - - 8, // 0x35 '5' - 0x00,0x00,0x00,0x3E,0x30,0x30,0x3C,0x06,0x06,0x66,0x3C,0x00,0x00, - - 8, // 0x36 '6' - 0x00,0x00,0x00,0x1C,0x30,0x60,0x7C,0x66,0x66,0x66,0x3C,0x00,0x00, - - 8, // 0x37 '7' - 0x00,0x00,0x00,0x7E,0x06,0x0C,0x0C,0x18,0x18,0x30,0x30,0x00,0x00, - - 8, // 0x38 '8' - 0x00,0x00,0x00,0x3C,0x66,0x66,0x3C,0x66,0x66,0x66,0x3C,0x00,0x00, - - 8, // 0x39 '9' - 0x00,0x00,0x00,0x3C,0x66,0x66,0x66,0x3E,0x06,0x0C,0x38,0x00,0x00, - - 4, // 0x3A ':' - 0x00,0x00,0x00,0x00,0x00,0x60,0x60,0x00,0x00,0x60,0x60,0x00,0x00, - - 4, // 0x3B ';' - 0x00,0x00,0x00,0x00,0x00,0x60,0x60,0x00,0x00,0x60,0x60,0x60,0x40, - - 9, // 0x3C '<' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x03,0x00,0x0C,0x00,0x30,0x00,0x40,0x00,0x30,0x00,0x0C,0x00,0x03,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x3D '=' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7F,0x00,0x00,0x00,0x00,0x00,0x7F,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x3E '>' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x60,0x00,0x18,0x00,0x06,0x00,0x01,0x00,0x06,0x00,0x18,0x00,0x60,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x3F '?' - 0x00,0x00,0x00,0x38,0x4C,0x0C,0x18,0x30,0x30,0x00,0x30,0x00,0x00, - - 11, // 0x40 '@' - 0x00,0x00,0x00,0x00,0x00,0x00,0x1F,0x80,0x20,0x40,0x4F,0x40,0x5B,0x40,0x5B,0x40,0x5B,0x40,0x4F,0x80,0x20,0x00,0x1F,0x00,0x00,0x00, - - 9, // 0x41 'A' - 0x00,0x00,0x00,0x00,0x00,0x00,0x1C,0x00,0x1C,0x00,0x36,0x00,0x36,0x00,0x36,0x00,0x7F,0x00,0x63,0x00,0x63,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x42 'B' - 0x00,0x00,0x00,0x7C,0x66,0x66,0x7C,0x66,0x66,0x66,0x7C,0x00,0x00, - - 8, // 0x43 'C' - 0x00,0x00,0x00,0x3C,0x62,0x60,0x60,0x60,0x60,0x62,0x3C,0x00,0x00, - - 9, // 0x44 'D' - 0x00,0x00,0x00,0x00,0x00,0x00,0x7C,0x00,0x66,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x66,0x00,0x7C,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x45 'E' - 0x00,0x00,0x00,0x7E,0x60,0x60,0x7E,0x60,0x60,0x60,0x7E,0x00,0x00, - - 8, // 0x46 'F' - 0x00,0x00,0x00,0x7E,0x60,0x60,0x7E,0x60,0x60,0x60,0x60,0x00,0x00, - - 9, // 0x47 'G' - 0x00,0x00,0x00,0x00,0x00,0x00,0x3E,0x00,0x61,0x00,0x60,0x00,0x60,0x00,0x67,0x00,0x63,0x00,0x63,0x00,0x3F,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x48 'H' - 0x00,0x00,0x00,0x00,0x00,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x7F,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x49 'I' - 0x00,0x00,0x00,0x78,0x30,0x30,0x30,0x30,0x30,0x30,0x78,0x00,0x00, - - 6, // 0x4A 'J' - 0x00,0x00,0x00,0x78,0x18,0x18,0x18,0x18,0x18,0x18,0xF0,0x00,0x00, - - 8, // 0x4B 'K' - 0x00,0x00,0x00,0x66,0x6C,0x78,0x70,0x70,0x78,0x6C,0x66,0x00,0x00, - - 7, // 0x4C 'L' - 0x00,0x00,0x00,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x7E,0x00,0x00, - - 10, // 0x4D 'M' - 0x00,0x00,0x00,0x00,0x00,0x00,0x60,0x80,0x71,0x80,0x7B,0x80,0x5D,0x80,0x49,0x80,0x41,0x80,0x41,0x80,0x41,0x80,0x00,0x00,0x00,0x00, - - 9, // 0x4E 'N' - 0x00,0x00,0x00,0x00,0x00,0x00,0x41,0x00,0x61,0x00,0x71,0x00,0x59,0x00,0x4D,0x00,0x47,0x00,0x43,0x00,0x41,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x4F 'O' - 0x00,0x00,0x00,0x00,0x00,0x00,0x3E,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x3E,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x50 'P' - 0x00,0x00,0x00,0x7C,0x66,0x66,0x66,0x7C,0x60,0x60,0x60,0x00,0x00, - - 9, // 0x51 'Q' - 0x00,0x00,0x00,0x00,0x00,0x00,0x3E,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x3E,0x00,0x0C,0x00,0x07,0x00, - - 8, // 0x52 'R' - 0x00,0x00,0x00,0x7C,0x66,0x66,0x66,0x7C,0x6C,0x66,0x63,0x00,0x00, - - 8, // 0x53 'S' - 0x00,0x00,0x00,0x3C,0x62,0x60,0x7C,0x3E,0x06,0x46,0x3C,0x00,0x00, - - 8, // 0x54 'T' - 0x00,0x00,0x00,0xFF,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x00,0x00, - - 9, // 0x55 'U' - 0x00,0x00,0x00,0x00,0x00,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x3E,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x56 'V' - 0x00,0x00,0x00,0x66,0x66,0x66,0x3C,0x3C,0x3C,0x18,0x18,0x00,0x00, - - 12, // 0x57 'W' - 0x00,0x00,0x00,0x00,0x00,0x00,0x66,0x60,0x66,0x60,0x66,0x60,0x36,0xC0,0x3F,0xC0,0x39,0xC0,0x19,0x80,0x19,0x80,0x00,0x00,0x00,0x00, - - 8, // 0x58 'X' - 0x00,0x00,0x00,0x66,0x66,0x3C,0x18,0x18,0x3C,0x66,0x66,0x00,0x00, - - 8, // 0x59 'Y' - 0x00,0x00,0x00,0x66,0x66,0x3C,0x3C,0x18,0x18,0x18,0x18,0x00,0x00, - - 8, // 0x5A 'Z' - 0x00,0x00,0x00,0x7E,0x06,0x0E,0x1C,0x38,0x70,0x60,0x7E,0x00,0x00, - - 6, // 0x5B '[' - 0x00,0x00,0x78,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x78, - - 8, // 0x5C '\' - 0x00,0x00,0x60,0x60,0x30,0x30,0x18,0x18,0x18,0x0C,0x0C,0x06,0x06, - - 6, // 0x5D ']' - 0x00,0x00,0x78,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x78, - - 10, // 0x5E '^' - 0x00,0x00,0x00,0x00,0x00,0x00,0x0C,0x00,0x1E,0x00,0x33,0x00,0x61,0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x5F '_' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xFF, - - 8, // 0x60 '`' - 0x00,0x00,0x30,0x18,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x61 'a' - 0x00,0x00,0x00,0x00,0x00,0x3C,0x06,0x3E,0x66,0x66,0x3E,0x00,0x00, - - 8, // 0x62 'b' - 0x00,0x00,0x60,0x60,0x60,0x7C,0x66,0x66,0x66,0x66,0x7C,0x00,0x00, - - 7, // 0x63 'c' - 0x00,0x00,0x00,0x00,0x00,0x3C,0x60,0x60,0x60,0x60,0x3C,0x00,0x00, - - 8, // 0x64 'd' - 0x00,0x00,0x06,0x06,0x06,0x3E,0x66,0x66,0x66,0x66,0x3E,0x00,0x00, - - 8, // 0x65 'e' - 0x00,0x00,0x00,0x00,0x00,0x3C,0x66,0x7E,0x60,0x62,0x3C,0x00,0x00, - - 5, // 0x66 'f' - 0x00,0x00,0x38,0x60,0x60,0xF8,0x60,0x60,0x60,0x60,0x60,0x00,0x00, - - 8, // 0x67 'g' - 0x00,0x00,0x00,0x00,0x00,0x3E,0x66,0x66,0x66,0x66,0x3E,0x06,0x3C, - - 8, // 0x68 'h' - 0x00,0x00,0x60,0x60,0x60,0x7C,0x66,0x66,0x66,0x66,0x66,0x00,0x00, - - 4, // 0x69 'i' - 0x00,0x00,0x00,0x60,0x00,0x60,0x60,0x60,0x60,0x60,0x60,0x00,0x00, - - 5, // 0x6A 'j' - 0x00,0x00,0x00,0x30,0x00,0x70,0x30,0x30,0x30,0x30,0x30,0x30,0xE0, - - 8, // 0x6B 'k' - 0x00,0x00,0x60,0x60,0x60,0x66,0x6C,0x78,0x78,0x6C,0x66,0x00,0x00, - - 4, // 0x6C 'l' - 0x00,0x00,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x00,0x00, - - 12, // 0x6D 'm' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7D,0xC0,0x66,0x60,0x66,0x60,0x66,0x60,0x66,0x60,0x66,0x60,0x00,0x00,0x00,0x00, - - 8, // 0x6E 'n' - 0x00,0x00,0x00,0x00,0x00,0x7C,0x66,0x66,0x66,0x66,0x66,0x00,0x00, - - 8, // 0x6F 'o' - 0x00,0x00,0x00,0x00,0x00,0x3C,0x66,0x66,0x66,0x66,0x3C,0x00,0x00, - - 8, // 0x70 'p' - 0x00,0x00,0x00,0x00,0x00,0x7C,0x66,0x66,0x66,0x66,0x7C,0x60,0x60, - - 8, // 0x71 'q' - 0x00,0x00,0x00,0x00,0x00,0x3E,0x66,0x66,0x66,0x66,0x3E,0x06,0x06, - - 6, // 0x72 'r' - 0x00,0x00,0x00,0x00,0x00,0x6C,0x7C,0x60,0x60,0x60,0x60,0x00,0x00, - - 7, // 0x73 's' - 0x00,0x00,0x00,0x00,0x00,0x3C,0x60,0x78,0x3C,0x0C,0x78,0x00,0x00, - - 5, // 0x74 't' - 0x00,0x00,0x00,0x60,0x60,0xF8,0x60,0x60,0x60,0x60,0x38,0x00,0x00, - - 8, // 0x75 'u' - 0x00,0x00,0x00,0x00,0x00,0x66,0x66,0x66,0x66,0x66,0x3E,0x00,0x00, - - 8, // 0x76 'v' - 0x00,0x00,0x00,0x00,0x00,0x66,0x66,0x66,0x3C,0x3C,0x18,0x00,0x00, - - 10, // 0x77 'w' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x6D,0x80,0x6D,0x80,0x6D,0x80,0x6D,0x80,0x33,0x00,0x33,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x78 'x' - 0x00,0x00,0x00,0x00,0x00,0x66,0x66,0x3C,0x3C,0x66,0x66,0x00,0x00, - - 8, // 0x79 'y' - 0x00,0x00,0x00,0x00,0x00,0x66,0x66,0x3C,0x3C,0x18,0x18,0x30,0x30, - - 7, // 0x7A 'z' - 0x00,0x00,0x00,0x00,0x00,0x7C,0x0C,0x18,0x30,0x60,0x7C,0x00,0x00, - - 8, // 0x7B '{' - 0x00,0x00,0x0E,0x18,0x18,0x18,0x18,0x70,0x18,0x18,0x18,0x18,0x0E, - - 6, // 0x7C '|' - 0x00,0x00,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x30, - - 8, // 0x7D '}' - 0x00,0x00,0x70,0x18,0x18,0x18,0x18,0x0E,0x18,0x18,0x18,0x18,0x70, - - 9, // 0x7E '~' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x31,0x00,0x49,0x00,0x49,0x00,0x46,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x7F '' - 0x00,0x00,0x00,0x00,0x00,0x00,0x7F,0x80,0x40,0x80,0x40,0x80,0x40,0x80,0x40,0x80,0x40,0x80,0x40,0x80,0x7F,0x80,0x00,0x00,0x00,0x00, - - 0 - }; - - const int8u verdana14[] = - { - 14, 3, 32, 128-32, - 0x00,0x00,0x0F,0x00,0x1E,0x00,0x2D,0x00,0x4A,0x00,0x59,0x00,0x76,0x00,0x93,0x00,0xA2,0x00, - 0xB1,0x00,0xC0,0x00,0xCF,0x00,0xEC,0x00,0xFB,0x00,0x0A,0x01,0x19,0x01,0x28,0x01,0x37,0x01, - 0x46,0x01,0x55,0x01,0x64,0x01,0x73,0x01,0x82,0x01,0x91,0x01,0xA0,0x01,0xAF,0x01,0xBE,0x01, - 0xCD,0x01,0xDC,0x01,0xF9,0x01,0x16,0x02,0x33,0x02,0x42,0x02,0x5F,0x02,0x6E,0x02,0x7D,0x02, - 0x9A,0x02,0xB7,0x02,0xC6,0x02,0xD5,0x02,0xF2,0x02,0x0F,0x03,0x1E,0x03,0x2D,0x03,0x3C,0x03, - 0x4B,0x03,0x68,0x03,0x85,0x03,0xA2,0x03,0xB1,0x03,0xCE,0x03,0xDD,0x03,0xEC,0x03,0xFB,0x03, - 0x18,0x04,0x27,0x04,0x44,0x04,0x53,0x04,0x62,0x04,0x71,0x04,0x80,0x04,0x8F,0x04,0x9E,0x04, - 0xBB,0x04,0xCA,0x04,0xD9,0x04,0xE8,0x04,0xF7,0x04,0x06,0x05,0x15,0x05,0x24,0x05,0x33,0x05, - 0x42,0x05,0x51,0x05,0x60,0x05,0x6F,0x05,0x7E,0x05,0x8D,0x05,0xAA,0x05,0xB9,0x05,0xC8,0x05, - 0xD7,0x05,0xE6,0x05,0xF5,0x05,0x04,0x06,0x13,0x06,0x22,0x06,0x31,0x06,0x4E,0x06,0x5D,0x06, - 0x6C,0x06,0x7B,0x06,0x8A,0x06,0x99,0x06,0xA8,0x06,0xC5,0x06, - - 4, // 0x20 ' ' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x21 '!' - 0x00,0x00,0x00,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x00,0x20,0x00,0x00, - - 6, // 0x22 '"' - 0x00,0x00,0x48,0x48,0x48,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x23 '#' - 0x00,0x00,0x00,0x00,0x00,0x00,0x09,0x00,0x09,0x00,0x12,0x00,0x3F,0x80,0x12,0x00,0x12,0x00,0x7F,0x00,0x24,0x00,0x24,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x24 '$' - 0x00,0x00,0x10,0x10,0x3E,0x50,0x50,0x30,0x1C,0x12,0x12,0x7C,0x10,0x10, - - 13, // 0x25 '%' - 0x00,0x00,0x00,0x00,0x00,0x00,0x30,0x80,0x49,0x00,0x49,0x00,0x4A,0x00,0x32,0x60,0x02,0x90,0x04,0x90,0x04,0x90,0x08,0x60,0x00,0x00,0x00,0x00, - - 10, // 0x26 '&' - 0x00,0x00,0x00,0x00,0x00,0x00,0x38,0x00,0x44,0x00,0x44,0x00,0x44,0x00,0x39,0x00,0x45,0x00,0x42,0x00,0x43,0x00,0x3C,0x80,0x00,0x00,0x00,0x00, - - 3, // 0x27 ''' - 0x00,0x00,0x40,0x40,0x40,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x28 '(' - 0x00,0x00,0x10,0x20,0x20,0x40,0x40,0x40,0x40,0x40,0x40,0x20,0x20,0x10, - - 5, // 0x29 ')' - 0x00,0x00,0x40,0x20,0x20,0x10,0x10,0x10,0x10,0x10,0x10,0x20,0x20,0x40, - - 8, // 0x2A '*' - 0x00,0x00,0x10,0x54,0x38,0x54,0x10,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x2B '+' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x7F,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x00,0x00,0x00,0x00, - - 4, // 0x2C ',' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,0x20,0x20,0x40, - - 5, // 0x2D '-' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x78,0x00,0x00,0x00,0x00,0x00, - - 4, // 0x2E '.' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,0x20,0x00,0x00, - - 5, // 0x2F '/' - 0x00,0x00,0x08,0x08,0x10,0x10,0x10,0x20,0x20,0x20,0x40,0x40,0x40,0x80, - - 8, // 0x30 '0' - 0x00,0x00,0x00,0x3C,0x42,0x42,0x42,0x42,0x42,0x42,0x42,0x3C,0x00,0x00, - - 8, // 0x31 '1' - 0x00,0x00,0x00,0x08,0x38,0x08,0x08,0x08,0x08,0x08,0x08,0x3E,0x00,0x00, - - 8, // 0x32 '2' - 0x00,0x00,0x00,0x3C,0x42,0x42,0x02,0x04,0x18,0x20,0x40,0x7E,0x00,0x00, - - 8, // 0x33 '3' - 0x00,0x00,0x00,0x3C,0x42,0x02,0x02,0x1C,0x02,0x02,0x42,0x3C,0x00,0x00, - - 8, // 0x34 '4' - 0x00,0x00,0x00,0x04,0x0C,0x14,0x24,0x44,0x7F,0x04,0x04,0x04,0x00,0x00, - - 8, // 0x35 '5' - 0x00,0x00,0x00,0x7E,0x40,0x40,0x7C,0x02,0x02,0x02,0x42,0x3C,0x00,0x00, - - 8, // 0x36 '6' - 0x00,0x00,0x00,0x1C,0x20,0x40,0x7C,0x42,0x42,0x42,0x42,0x3C,0x00,0x00, - - 8, // 0x37 '7' - 0x00,0x00,0x00,0x7E,0x02,0x04,0x04,0x08,0x08,0x10,0x10,0x20,0x00,0x00, - - 8, // 0x38 '8' - 0x00,0x00,0x00,0x3C,0x42,0x42,0x42,0x3C,0x42,0x42,0x42,0x3C,0x00,0x00, - - 8, // 0x39 '9' - 0x00,0x00,0x00,0x3C,0x42,0x42,0x42,0x42,0x3E,0x02,0x04,0x38,0x00,0x00, - - 5, // 0x3A ':' - 0x00,0x00,0x00,0x00,0x00,0x20,0x20,0x00,0x00,0x00,0x20,0x20,0x00,0x00, - - 5, // 0x3B ';' - 0x00,0x00,0x00,0x00,0x00,0x20,0x20,0x00,0x00,0x00,0x20,0x20,0x20,0x40, - - 9, // 0x3C '<' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x03,0x00,0x0C,0x00,0x30,0x00,0x40,0x00,0x30,0x00,0x0C,0x00,0x03,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x3D '=' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7F,0x00,0x00,0x00,0x7F,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x3E '>' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x60,0x00,0x18,0x00,0x06,0x00,0x01,0x00,0x06,0x00,0x18,0x00,0x60,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x3F '?' - 0x00,0x00,0x00,0x38,0x44,0x04,0x04,0x08,0x10,0x10,0x00,0x10,0x00,0x00, - - 12, // 0x40 '@' - 0x00,0x00,0x00,0x00,0x00,0x00,0x0F,0x00,0x30,0xC0,0x27,0x40,0x49,0x20,0x49,0x20,0x49,0x20,0x49,0x20,0x27,0xC0,0x30,0x00,0x0F,0x00,0x00,0x00, - - 8, // 0x41 'A' - 0x00,0x00,0x00,0x18,0x18,0x24,0x24,0x42,0x42,0x7E,0x81,0x81,0x00,0x00, - - 8, // 0x42 'B' - 0x00,0x00,0x00,0x78,0x44,0x44,0x44,0x7C,0x42,0x42,0x42,0x7C,0x00,0x00, - - 9, // 0x43 'C' - 0x00,0x00,0x00,0x00,0x00,0x00,0x1E,0x00,0x21,0x00,0x40,0x00,0x40,0x00,0x40,0x00,0x40,0x00,0x40,0x00,0x21,0x00,0x1E,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x44 'D' - 0x00,0x00,0x00,0x00,0x00,0x00,0x7C,0x00,0x42,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x42,0x00,0x7C,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x45 'E' - 0x00,0x00,0x00,0x7E,0x40,0x40,0x40,0x7E,0x40,0x40,0x40,0x7E,0x00,0x00, - - 7, // 0x46 'F' - 0x00,0x00,0x00,0x7E,0x40,0x40,0x40,0x7C,0x40,0x40,0x40,0x40,0x00,0x00, - - 9, // 0x47 'G' - 0x00,0x00,0x00,0x00,0x00,0x00,0x1E,0x00,0x21,0x00,0x40,0x00,0x40,0x00,0x47,0x00,0x41,0x00,0x41,0x00,0x21,0x00,0x1E,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x48 'H' - 0x00,0x00,0x00,0x00,0x00,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x7F,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x49 'I' - 0x00,0x00,0x00,0x70,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x70,0x00,0x00, - - 5, // 0x4A 'J' - 0x00,0x00,0x00,0x70,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0xE0,0x00,0x00, - - 8, // 0x4B 'K' - 0x00,0x00,0x00,0x42,0x44,0x48,0x50,0x60,0x50,0x48,0x44,0x42,0x00,0x00, - - 7, // 0x4C 'L' - 0x00,0x00,0x00,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x7E,0x00,0x00, - - 10, // 0x4D 'M' - 0x00,0x00,0x00,0x00,0x00,0x00,0x61,0x80,0x61,0x80,0x52,0x80,0x52,0x80,0x52,0x80,0x4C,0x80,0x4C,0x80,0x40,0x80,0x40,0x80,0x00,0x00,0x00,0x00, - - 9, // 0x4E 'N' - 0x00,0x00,0x00,0x00,0x00,0x00,0x61,0x00,0x61,0x00,0x51,0x00,0x51,0x00,0x49,0x00,0x45,0x00,0x45,0x00,0x43,0x00,0x43,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x4F 'O' - 0x00,0x00,0x00,0x00,0x00,0x00,0x1E,0x00,0x21,0x00,0x40,0x80,0x40,0x80,0x40,0x80,0x40,0x80,0x40,0x80,0x21,0x00,0x1E,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x50 'P' - 0x00,0x00,0x00,0x7C,0x42,0x42,0x42,0x42,0x7C,0x40,0x40,0x40,0x00,0x00, - - 10, // 0x51 'Q' - 0x00,0x00,0x00,0x00,0x00,0x00,0x1E,0x00,0x21,0x00,0x40,0x80,0x40,0x80,0x40,0x80,0x40,0x80,0x40,0x80,0x21,0x00,0x1E,0x00,0x02,0x00,0x01,0x80, - - 8, // 0x52 'R' - 0x00,0x00,0x00,0x7C,0x42,0x42,0x42,0x7C,0x48,0x44,0x42,0x41,0x00,0x00, - - 8, // 0x53 'S' - 0x00,0x00,0x00,0x3C,0x42,0x40,0x40,0x3C,0x02,0x02,0x42,0x3C,0x00,0x00, - - 7, // 0x54 'T' - 0x00,0x00,0x00,0xFE,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x00,0x00, - - 9, // 0x55 'U' - 0x00,0x00,0x00,0x00,0x00,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x22,0x00,0x1C,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x56 'V' - 0x00,0x00,0x00,0x81,0x81,0x42,0x42,0x42,0x24,0x24,0x18,0x18,0x00,0x00, - - 13, // 0x57 'W' - 0x00,0x00,0x00,0x00,0x00,0x00,0x42,0x10,0x42,0x10,0x45,0x10,0x45,0x10,0x25,0x20,0x28,0xA0,0x28,0xA0,0x10,0x40,0x10,0x40,0x00,0x00,0x00,0x00, - - 8, // 0x58 'X' - 0x00,0x00,0x00,0x42,0x42,0x24,0x18,0x18,0x18,0x24,0x42,0x42,0x00,0x00, - - 7, // 0x59 'Y' - 0x00,0x00,0x00,0x82,0x44,0x44,0x28,0x10,0x10,0x10,0x10,0x10,0x00,0x00, - - 8, // 0x5A 'Z' - 0x00,0x00,0x00,0x7E,0x02,0x04,0x08,0x10,0x10,0x20,0x40,0x7E,0x00,0x00, - - 5, // 0x5B '[' - 0x00,0x00,0x70,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x70, - - 5, // 0x5C '\' - 0x00,0x00,0x80,0x80,0x40,0x40,0x40,0x20,0x20,0x10,0x10,0x10,0x08,0x08, - - 5, // 0x5D ']' - 0x00,0x00,0x70,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x70, - - 10, // 0x5E '^' - 0x00,0x00,0x00,0x00,0x00,0x00,0x0C,0x00,0x12,0x00,0x21,0x00,0x40,0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x5F '_' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xFF, - - 8, // 0x60 '`' - 0x00,0x00,0x20,0x10,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x61 'a' - 0x00,0x00,0x00,0x00,0x00,0x3C,0x02,0x02,0x3E,0x42,0x42,0x3E,0x00,0x00, - - 8, // 0x62 'b' - 0x00,0x00,0x40,0x40,0x40,0x5C,0x62,0x42,0x42,0x42,0x42,0x7C,0x00,0x00, - - 6, // 0x63 'c' - 0x00,0x00,0x00,0x00,0x00,0x38,0x44,0x40,0x40,0x40,0x44,0x38,0x00,0x00, - - 8, // 0x64 'd' - 0x00,0x00,0x02,0x02,0x02,0x3E,0x42,0x42,0x42,0x42,0x46,0x3A,0x00,0x00, - - 8, // 0x65 'e' - 0x00,0x00,0x00,0x00,0x00,0x3C,0x42,0x42,0x7E,0x40,0x42,0x3C,0x00,0x00, - - 4, // 0x66 'f' - 0x00,0x00,0x30,0x40,0x40,0xF0,0x40,0x40,0x40,0x40,0x40,0x40,0x00,0x00, - - 8, // 0x67 'g' - 0x00,0x00,0x00,0x00,0x00,0x3E,0x42,0x42,0x42,0x42,0x46,0x3A,0x02,0x3C, - - 8, // 0x68 'h' - 0x00,0x00,0x40,0x40,0x40,0x5C,0x62,0x42,0x42,0x42,0x42,0x42,0x00,0x00, - - 3, // 0x69 'i' - 0x00,0x00,0x40,0x00,0x00,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x00,0x00, - - 4, // 0x6A 'j' - 0x00,0x00,0x20,0x00,0x00,0x60,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0xC0, - - 7, // 0x6B 'k' - 0x00,0x00,0x40,0x40,0x40,0x44,0x48,0x50,0x60,0x50,0x48,0x44,0x00,0x00, - - 3, // 0x6C 'l' - 0x00,0x00,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x00,0x00, - - 11, // 0x6D 'm' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7B,0x80,0x44,0x40,0x44,0x40,0x44,0x40,0x44,0x40,0x44,0x40,0x44,0x40,0x00,0x00,0x00,0x00, - - 8, // 0x6E 'n' - 0x00,0x00,0x00,0x00,0x00,0x5C,0x62,0x42,0x42,0x42,0x42,0x42,0x00,0x00, - - 8, // 0x6F 'o' - 0x00,0x00,0x00,0x00,0x00,0x3C,0x42,0x42,0x42,0x42,0x42,0x3C,0x00,0x00, - - 8, // 0x70 'p' - 0x00,0x00,0x00,0x00,0x00,0x5C,0x62,0x42,0x42,0x42,0x42,0x7C,0x40,0x40, - - 8, // 0x71 'q' - 0x00,0x00,0x00,0x00,0x00,0x3E,0x42,0x42,0x42,0x42,0x46,0x3A,0x02,0x02, - - 5, // 0x72 'r' - 0x00,0x00,0x00,0x00,0x00,0x58,0x60,0x40,0x40,0x40,0x40,0x40,0x00,0x00, - - 7, // 0x73 's' - 0x00,0x00,0x00,0x00,0x00,0x3C,0x40,0x40,0x38,0x04,0x04,0x78,0x00,0x00, - - 5, // 0x74 't' - 0x00,0x00,0x00,0x40,0x40,0xF8,0x40,0x40,0x40,0x40,0x40,0x38,0x00,0x00, - - 8, // 0x75 'u' - 0x00,0x00,0x00,0x00,0x00,0x42,0x42,0x42,0x42,0x42,0x46,0x3A,0x00,0x00, - - 7, // 0x76 'v' - 0x00,0x00,0x00,0x00,0x00,0x44,0x44,0x28,0x28,0x28,0x10,0x10,0x00,0x00, - - 11, // 0x77 'w' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x44,0x40,0x44,0x40,0x2A,0x80,0x2A,0x80,0x2A,0x80,0x11,0x00,0x11,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x78 'x' - 0x00,0x00,0x00,0x00,0x00,0x44,0x44,0x28,0x10,0x28,0x44,0x44,0x00,0x00, - - 7, // 0x79 'y' - 0x00,0x00,0x00,0x00,0x00,0x44,0x44,0x28,0x28,0x28,0x10,0x10,0x10,0x20, - - 7, // 0x7A 'z' - 0x00,0x00,0x00,0x00,0x00,0x7C,0x04,0x08,0x10,0x20,0x40,0x7C,0x00,0x00, - - 8, // 0x7B '{' - 0x00,0x00,0x0C,0x10,0x10,0x10,0x10,0x60,0x10,0x10,0x10,0x10,0x10,0x0C, - - 5, // 0x7C '|' - 0x00,0x00,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20, - - 8, // 0x7D '}' - 0x00,0x00,0x30,0x08,0x08,0x08,0x08,0x06,0x08,0x08,0x08,0x08,0x08,0x30, - - 10, // 0x7E '~' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x30,0x80,0x4C,0x80,0x43,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 12, // 0x7F '' - 0x00,0x00,0x00,0x00,0x00,0x00,0x3F,0xE0,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x3F,0xE0,0x00,0x00,0x00,0x00, - - 0 - }; - - const int8u verdana14_bold[] = - { - 14, 3, 32, 128-32, - 0x00,0x00,0x0F,0x00,0x1E,0x00,0x2D,0x00,0x4A,0x00,0x67,0x00,0x84,0x00,0xA1,0x00,0xB0,0x00, - 0xBF,0x00,0xCE,0x00,0xEB,0x00,0x08,0x01,0x17,0x01,0x26,0x01,0x35,0x01,0x44,0x01,0x61,0x01, - 0x7E,0x01,0x9B,0x01,0xB8,0x01,0xD5,0x01,0xF2,0x01,0x0F,0x02,0x2C,0x02,0x49,0x02,0x66,0x02, - 0x75,0x02,0x84,0x02,0xA1,0x02,0xBE,0x02,0xDB,0x02,0xEA,0x02,0x07,0x03,0x24,0x03,0x41,0x03, - 0x5E,0x03,0x7B,0x03,0x8A,0x03,0x99,0x03,0xB6,0x03,0xD3,0x03,0xE2,0x03,0xF1,0x03,0x0E,0x04, - 0x1D,0x04,0x3A,0x04,0x57,0x04,0x74,0x04,0x91,0x04,0xAE,0x04,0xCB,0x04,0xE8,0x04,0xF7,0x04, - 0x14,0x05,0x31,0x05,0x4E,0x05,0x6B,0x05,0x88,0x05,0x97,0x05,0xA6,0x05,0xB5,0x05,0xC4,0x05, - 0xE1,0x05,0xFE,0x05,0x1B,0x06,0x2A,0x06,0x39,0x06,0x48,0x06,0x57,0x06,0x66,0x06,0x75,0x06, - 0x84,0x06,0x93,0x06,0xA2,0x06,0xB1,0x06,0xC0,0x06,0xCF,0x06,0xEC,0x06,0xFB,0x06,0x0A,0x07, - 0x19,0x07,0x28,0x07,0x37,0x07,0x46,0x07,0x55,0x07,0x64,0x07,0x73,0x07,0x90,0x07,0x9F,0x07, - 0xAE,0x07,0xBD,0x07,0xDA,0x07,0xE9,0x07,0x06,0x08,0x23,0x08, - - 4, // 0x20 ' ' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x21 '!' - 0x00,0x00,0x00,0x60,0x60,0x60,0x60,0x60,0x60,0x00,0x60,0x60,0x00,0x00, - - 7, // 0x22 '"' - 0x00,0x00,0x6C,0x6C,0x6C,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x23 '#' - 0x00,0x00,0x00,0x00,0x00,0x00,0x09,0x00,0x09,0x00,0x3F,0x80,0x3F,0x80,0x12,0x00,0x7F,0x00,0x7F,0x00,0x24,0x00,0x24,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x24 '$' - 0x00,0x00,0x00,0x00,0x08,0x00,0x08,0x00,0x3E,0x00,0x69,0x00,0x68,0x00,0x7E,0x00,0x3F,0x00,0x0B,0x00,0x4B,0x00,0x3E,0x00,0x08,0x00,0x08,0x00, - - 15, // 0x25 '%' - 0x00,0x00,0x00,0x00,0x00,0x00,0x38,0x40,0x6C,0x40,0x6C,0x80,0x6C,0xB8,0x6D,0x6C,0x3A,0x6C,0x02,0x6C,0x04,0x6C,0x04,0x38,0x00,0x00,0x00,0x00, - - 10, // 0x26 '&' - 0x00,0x00,0x00,0x00,0x00,0x00,0x38,0x00,0x6C,0x00,0x6C,0x00,0x6C,0x00,0x39,0x80,0x6D,0x00,0x66,0x00,0x63,0x00,0x3D,0x80,0x00,0x00,0x00,0x00, - - 4, // 0x27 ''' - 0x00,0x00,0x60,0x60,0x60,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x28 '(' - 0x00,0x00,0x18,0x30,0x30,0x60,0x60,0x60,0x60,0x60,0x60,0x30,0x30,0x18, - - 7, // 0x29 ')' - 0x00,0x00,0x30,0x18,0x18,0x0C,0x0C,0x0C,0x0C,0x0C,0x0C,0x18,0x18,0x30, - - 9, // 0x2A '*' - 0x00,0x00,0x00,0x00,0x08,0x00,0x2A,0x00,0x1C,0x00,0x1C,0x00,0x2A,0x00,0x08,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x2B '+' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x7F,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 4, // 0x2C ',' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x60,0x60,0x60,0x40, - - 6, // 0x2D '-' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x78,0x00,0x00,0x00,0x00,0x00,0x00, - - 4, // 0x2E '.' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x60,0x60,0x00,0x00, - - 8, // 0x2F '/' - 0x00,0x00,0x06,0x06,0x0C,0x0C,0x0C,0x18,0x18,0x30,0x30,0x30,0x60,0x60, - - 9, // 0x30 '0' - 0x00,0x00,0x00,0x00,0x00,0x00,0x3E,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x3E,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x31 '1' - 0x00,0x00,0x00,0x00,0x00,0x00,0x0C,0x00,0x3C,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x3F,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x32 '2' - 0x00,0x00,0x00,0x00,0x00,0x00,0x3E,0x00,0x63,0x00,0x03,0x00,0x03,0x00,0x06,0x00,0x0C,0x00,0x18,0x00,0x30,0x00,0x7F,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x33 '3' - 0x00,0x00,0x00,0x00,0x00,0x00,0x3E,0x00,0x63,0x00,0x03,0x00,0x03,0x00,0x1E,0x00,0x03,0x00,0x03,0x00,0x63,0x00,0x3E,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x34 '4' - 0x00,0x00,0x00,0x00,0x00,0x00,0x06,0x00,0x0E,0x00,0x16,0x00,0x16,0x00,0x26,0x00,0x46,0x00,0x7F,0x00,0x06,0x00,0x06,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x35 '5' - 0x00,0x00,0x00,0x00,0x00,0x00,0x3F,0x00,0x30,0x00,0x30,0x00,0x3E,0x00,0x03,0x00,0x03,0x00,0x03,0x00,0x63,0x00,0x3E,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x36 '6' - 0x00,0x00,0x00,0x00,0x00,0x00,0x1E,0x00,0x30,0x00,0x60,0x00,0x7E,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x3E,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x37 '7' - 0x00,0x00,0x00,0x00,0x00,0x00,0x7F,0x00,0x03,0x00,0x06,0x00,0x06,0x00,0x0C,0x00,0x0C,0x00,0x18,0x00,0x18,0x00,0x30,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x38 '8' - 0x00,0x00,0x00,0x00,0x00,0x00,0x3E,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x3E,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x3E,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x39 '9' - 0x00,0x00,0x00,0x00,0x00,0x00,0x3E,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x3F,0x00,0x03,0x00,0x06,0x00,0x3C,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x3A ':' - 0x00,0x00,0x00,0x00,0x00,0x60,0x60,0x00,0x00,0x00,0x60,0x60,0x00,0x00, - - 5, // 0x3B ';' - 0x00,0x00,0x00,0x00,0x00,0x60,0x60,0x00,0x00,0x00,0x60,0x60,0x60,0x40, - - 10, // 0x3C '<' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x06,0x00,0x18,0x00,0x60,0x00,0x60,0x00,0x18,0x00,0x06,0x00,0x01,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x3D '=' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7F,0x00,0x00,0x00,0x00,0x00,0x7F,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x3E '>' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x40,0x00,0x30,0x00,0x0C,0x00,0x03,0x00,0x03,0x00,0x0C,0x00,0x30,0x00,0x40,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x3F '?' - 0x00,0x00,0x00,0x38,0x4C,0x0C,0x18,0x30,0x30,0x00,0x30,0x30,0x00,0x00, - - 12, // 0x40 '@' - 0x00,0x00,0x00,0x00,0x00,0x00,0x0F,0x00,0x30,0xC0,0x2F,0x40,0x5B,0x20,0x5B,0x20,0x5B,0x20,0x5B,0x20,0x2F,0xC0,0x30,0x00,0x0F,0x00,0x00,0x00, - - 9, // 0x41 'A' - 0x00,0x00,0x00,0x00,0x00,0x00,0x1C,0x00,0x1C,0x00,0x36,0x00,0x36,0x00,0x36,0x00,0x36,0x00,0x7F,0x00,0x63,0x00,0x63,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x42 'B' - 0x00,0x00,0x00,0x00,0x00,0x00,0x7C,0x00,0x66,0x00,0x66,0x00,0x66,0x00,0x7E,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x7E,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x43 'C' - 0x00,0x00,0x00,0x00,0x00,0x00,0x1E,0x00,0x31,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x31,0x00,0x1E,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x44 'D' - 0x00,0x00,0x00,0x00,0x00,0x00,0x7E,0x00,0x63,0x00,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x63,0x00,0x7E,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x45 'E' - 0x00,0x00,0x00,0x7E,0x60,0x60,0x60,0x7E,0x60,0x60,0x60,0x7E,0x00,0x00, - - 8, // 0x46 'F' - 0x00,0x00,0x00,0x7E,0x60,0x60,0x60,0x7E,0x60,0x60,0x60,0x60,0x00,0x00, - - 10, // 0x47 'G' - 0x00,0x00,0x00,0x00,0x00,0x00,0x1F,0x00,0x30,0x80,0x60,0x00,0x60,0x00,0x60,0x00,0x67,0x80,0x61,0x80,0x31,0x80,0x1F,0x80,0x00,0x00,0x00,0x00, - - 10, // 0x48 'H' - 0x00,0x00,0x00,0x00,0x00,0x00,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x7F,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x00,0x00,0x00,0x00, - - 6, // 0x49 'I' - 0x00,0x00,0x00,0x78,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x78,0x00,0x00, - - 7, // 0x4A 'J' - 0x00,0x00,0x00,0x7C,0x0C,0x0C,0x0C,0x0C,0x0C,0x0C,0x0C,0xF8,0x00,0x00, - - 9, // 0x4B 'K' - 0x00,0x00,0x00,0x00,0x00,0x00,0x63,0x00,0x66,0x00,0x6C,0x00,0x78,0x00,0x70,0x00,0x78,0x00,0x6C,0x00,0x66,0x00,0x63,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x4C 'L' - 0x00,0x00,0x00,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x7F,0x00,0x00, - - 11, // 0x4D 'M' - 0x00,0x00,0x00,0x00,0x00,0x00,0x60,0xC0,0x71,0xC0,0x71,0xC0,0x5A,0xC0,0x5A,0xC0,0x4C,0xC0,0x4C,0xC0,0x40,0xC0,0x40,0xC0,0x00,0x00,0x00,0x00, - - 10, // 0x4E 'N' - 0x00,0x00,0x00,0x00,0x00,0x00,0x60,0x80,0x70,0x80,0x58,0x80,0x58,0x80,0x4C,0x80,0x46,0x80,0x46,0x80,0x43,0x80,0x41,0x80,0x00,0x00,0x00,0x00, - - 11, // 0x4F 'O' - 0x00,0x00,0x00,0x00,0x00,0x00,0x1F,0x00,0x31,0x80,0x60,0xC0,0x60,0xC0,0x60,0xC0,0x60,0xC0,0x60,0xC0,0x31,0x80,0x1F,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x50 'P' - 0x00,0x00,0x00,0x00,0x00,0x00,0x7E,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x7E,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x51 'Q' - 0x00,0x00,0x00,0x00,0x00,0x00,0x1F,0x00,0x31,0x80,0x60,0xC0,0x60,0xC0,0x60,0xC0,0x60,0xC0,0x60,0xC0,0x31,0x80,0x1F,0x00,0x06,0x00,0x03,0xC0, - - 9, // 0x52 'R' - 0x00,0x00,0x00,0x00,0x00,0x00,0x7E,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x7E,0x00,0x6C,0x00,0x66,0x00,0x63,0x00,0x61,0x80,0x00,0x00,0x00,0x00, - - 9, // 0x53 'S' - 0x00,0x00,0x00,0x00,0x00,0x00,0x3E,0x00,0x61,0x00,0x60,0x00,0x70,0x00,0x3E,0x00,0x07,0x00,0x03,0x00,0x43,0x00,0x3E,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x54 'T' - 0x00,0x00,0x00,0xFF,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x00,0x00, - - 10, // 0x55 'U' - 0x00,0x00,0x00,0x00,0x00,0x00,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x3F,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x56 'V' - 0x00,0x00,0x00,0x00,0x00,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x36,0x00,0x36,0x00,0x36,0x00,0x1C,0x00,0x1C,0x00,0x1C,0x00,0x00,0x00,0x00,0x00, - - 14, // 0x57 'W' - 0x00,0x00,0x00,0x00,0x00,0x00,0x63,0x18,0x63,0x18,0x63,0x18,0x33,0x30,0x37,0xB0,0x34,0xB0,0x1C,0xE0,0x18,0x60,0x18,0x60,0x00,0x00,0x00,0x00, - - 9, // 0x58 'X' - 0x00,0x00,0x00,0x00,0x00,0x00,0x63,0x00,0x63,0x00,0x36,0x00,0x1C,0x00,0x1C,0x00,0x1C,0x00,0x36,0x00,0x63,0x00,0x63,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x59 'Y' - 0x00,0x00,0x00,0x00,0x00,0x00,0x61,0x80,0x61,0x80,0x33,0x00,0x1E,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x5A 'Z' - 0x00,0x00,0x00,0x7E,0x0C,0x0C,0x18,0x18,0x30,0x30,0x60,0x7E,0x00,0x00, - - 6, // 0x5B '[' - 0x00,0x00,0x78,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x78, - - 8, // 0x5C '\' - 0x00,0x00,0x60,0x60,0x30,0x30,0x30,0x18,0x18,0x0C,0x0C,0x0C,0x06,0x06, - - 6, // 0x5D ']' - 0x00,0x00,0x78,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x78, - - 10, // 0x5E '^' - 0x00,0x00,0x00,0x00,0x00,0x00,0x0C,0x00,0x1E,0x00,0x33,0x00,0x61,0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x5F '_' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xFF,0x80, - - 9, // 0x60 '`' - 0x00,0x00,0x00,0x00,0x30,0x00,0x18,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x61 'a' - 0x00,0x00,0x00,0x00,0x00,0x3C,0x06,0x3E,0x66,0x66,0x66,0x3E,0x00,0x00, - - 8, // 0x62 'b' - 0x00,0x00,0x60,0x60,0x60,0x7C,0x66,0x66,0x66,0x66,0x66,0x7C,0x00,0x00, - - 7, // 0x63 'c' - 0x00,0x00,0x00,0x00,0x00,0x3C,0x62,0x60,0x60,0x60,0x62,0x3C,0x00,0x00, - - 8, // 0x64 'd' - 0x00,0x00,0x06,0x06,0x06,0x3E,0x66,0x66,0x66,0x66,0x66,0x3E,0x00,0x00, - - 8, // 0x65 'e' - 0x00,0x00,0x00,0x00,0x00,0x3C,0x66,0x66,0x7E,0x60,0x62,0x3C,0x00,0x00, - - 5, // 0x66 'f' - 0x00,0x00,0x38,0x60,0x60,0xF8,0x60,0x60,0x60,0x60,0x60,0x60,0x00,0x00, - - 8, // 0x67 'g' - 0x00,0x00,0x00,0x00,0x00,0x3E,0x66,0x66,0x66,0x66,0x66,0x3E,0x06,0x3C, - - 8, // 0x68 'h' - 0x00,0x00,0x60,0x60,0x60,0x7C,0x66,0x66,0x66,0x66,0x66,0x66,0x00,0x00, - - 4, // 0x69 'i' - 0x00,0x00,0x60,0x60,0x00,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x00,0x00, - - 5, // 0x6A 'j' - 0x00,0x00,0x30,0x30,0x00,0x70,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0xE0, - - 8, // 0x6B 'k' - 0x00,0x00,0x60,0x60,0x60,0x66,0x6C,0x78,0x78,0x6C,0x66,0x63,0x00,0x00, - - 4, // 0x6C 'l' - 0x00,0x00,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x00,0x00, - - 12, // 0x6D 'm' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x6C,0xC0,0x77,0x60,0x66,0x60,0x66,0x60,0x66,0x60,0x66,0x60,0x66,0x60,0x00,0x00,0x00,0x00, - - 8, // 0x6E 'n' - 0x00,0x00,0x00,0x00,0x00,0x7C,0x66,0x66,0x66,0x66,0x66,0x66,0x00,0x00, - - 8, // 0x6F 'o' - 0x00,0x00,0x00,0x00,0x00,0x3C,0x66,0x66,0x66,0x66,0x66,0x3C,0x00,0x00, - - 8, // 0x70 'p' - 0x00,0x00,0x00,0x00,0x00,0x7C,0x66,0x66,0x66,0x66,0x66,0x7C,0x60,0x60, - - 8, // 0x71 'q' - 0x00,0x00,0x00,0x00,0x00,0x3E,0x66,0x66,0x66,0x66,0x66,0x3E,0x06,0x06, - - 6, // 0x72 'r' - 0x00,0x00,0x00,0x00,0x00,0x6C,0x7C,0x60,0x60,0x60,0x60,0x60,0x00,0x00, - - 7, // 0x73 's' - 0x00,0x00,0x00,0x00,0x00,0x3C,0x60,0x60,0x38,0x0C,0x0C,0x78,0x00,0x00, - - 5, // 0x74 't' - 0x00,0x00,0x00,0x60,0x60,0xF8,0x60,0x60,0x60,0x60,0x60,0x38,0x00,0x00, - - 8, // 0x75 'u' - 0x00,0x00,0x00,0x00,0x00,0x66,0x66,0x66,0x66,0x66,0x66,0x3E,0x00,0x00, - - 8, // 0x76 'v' - 0x00,0x00,0x00,0x00,0x00,0x66,0x66,0x66,0x3C,0x3C,0x3C,0x18,0x00,0x00, - - 12, // 0x77 'w' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x66,0x60,0x66,0x60,0x66,0x60,0x69,0x60,0x39,0xC0,0x30,0xC0,0x30,0xC0,0x00,0x00,0x00,0x00, - - 8, // 0x78 'x' - 0x00,0x00,0x00,0x00,0x00,0x66,0x66,0x3C,0x18,0x3C,0x66,0x66,0x00,0x00, - - 8, // 0x79 'y' - 0x00,0x00,0x00,0x00,0x00,0x66,0x66,0x66,0x3C,0x3C,0x3C,0x18,0x18,0x30, - - 7, // 0x7A 'z' - 0x00,0x00,0x00,0x00,0x00,0x7C,0x0C,0x18,0x38,0x30,0x60,0x7C,0x00,0x00, - - 9, // 0x7B '{' - 0x00,0x00,0x00,0x00,0x0E,0x00,0x18,0x00,0x18,0x00,0x18,0x00,0x18,0x00,0x70,0x00,0x18,0x00,0x18,0x00,0x18,0x00,0x18,0x00,0x18,0x00,0x0E,0x00, - - 6, // 0x7C '|' - 0x00,0x00,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x30, - - 9, // 0x7D '}' - 0x00,0x00,0x00,0x00,0x38,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x07,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x38,0x00, - - 10, // 0x7E '~' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x30,0x80,0x48,0x80,0x44,0x80,0x43,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 12, // 0x7F '' - 0x00,0x00,0x00,0x00,0x00,0x00,0x3F,0xE0,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x3F,0xE0,0x00,0x00,0x00,0x00, - - 0 - }; - - const int8u verdana16[] = - { - 16, 4, 32, 128-32, - 0x00,0x00,0x11,0x00,0x22,0x00,0x33,0x00,0x54,0x00,0x65,0x00,0x86,0x00,0xA7,0x00,0xB8,0x00, - 0xC9,0x00,0xDA,0x00,0xFB,0x00,0x1C,0x01,0x2D,0x01,0x3E,0x01,0x4F,0x01,0x60,0x01,0x71,0x01, - 0x82,0x01,0x93,0x01,0xA4,0x01,0xB5,0x01,0xC6,0x01,0xD7,0x01,0xE8,0x01,0xF9,0x01,0x0A,0x02, - 0x1B,0x02,0x2C,0x02,0x4D,0x02,0x6E,0x02,0x8F,0x02,0xA0,0x02,0xC1,0x02,0xE2,0x02,0xF3,0x02, - 0x14,0x03,0x35,0x03,0x46,0x03,0x57,0x03,0x78,0x03,0x99,0x03,0xAA,0x03,0xBB,0x03,0xCC,0x03, - 0xDD,0x03,0xFE,0x03,0x1F,0x04,0x40,0x04,0x51,0x04,0x72,0x04,0x93,0x04,0xB4,0x04,0xD5,0x04, - 0xF6,0x04,0x17,0x05,0x38,0x05,0x59,0x05,0x7A,0x05,0x9B,0x05,0xAC,0x05,0xBD,0x05,0xCE,0x05, - 0xEF,0x05,0x00,0x06,0x11,0x06,0x22,0x06,0x33,0x06,0x44,0x06,0x55,0x06,0x66,0x06,0x77,0x06, - 0x88,0x06,0x99,0x06,0xAA,0x06,0xBB,0x06,0xCC,0x06,0xDD,0x06,0xFE,0x06,0x0F,0x07,0x20,0x07, - 0x31,0x07,0x42,0x07,0x53,0x07,0x64,0x07,0x75,0x07,0x86,0x07,0x97,0x07,0xB8,0x07,0xC9,0x07, - 0xDA,0x07,0xEB,0x07,0xFC,0x07,0x0D,0x08,0x1E,0x08,0x3F,0x08, - - 5, // 0x20 ' ' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x21 '!' - 0x00,0x00,0x00,0x00,0x20,0x20,0x20,0x20,0x20,0x20,0x00,0x20,0x20,0x00,0x00,0x00, - - 5, // 0x22 '"' - 0x00,0x00,0x00,0x50,0x50,0x50,0x50,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x23 '#' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x09,0x00,0x09,0x00,0x3F,0x80,0x12,0x00,0x12,0x00,0x7F,0x00,0x24,0x00,0x24,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x24 '$' - 0x00,0x00,0x00,0x10,0x10,0x3E,0x50,0x50,0x30,0x1C,0x12,0x12,0x7C,0x10,0x10,0x00, - - 13, // 0x25 '%' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x38,0x40,0x44,0x80,0x45,0x00,0x45,0x00,0x3A,0xE0,0x05,0x10,0x05,0x10,0x09,0x10,0x10,0xE0,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x26 '&' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x38,0x00,0x44,0x00,0x44,0x00,0x44,0x00,0x38,0x80,0x45,0x00,0x42,0x00,0x46,0x00,0x39,0x80,0x00,0x00,0x00,0x00,0x00,0x00, - - 3, // 0x27 ''' - 0x00,0x00,0x00,0x40,0x40,0x40,0x40,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x28 '(' - 0x00,0x00,0x00,0x08,0x10,0x20,0x20,0x40,0x40,0x40,0x40,0x40,0x20,0x20,0x10,0x08, - - 6, // 0x29 ')' - 0x00,0x00,0x00,0x40,0x20,0x10,0x10,0x08,0x08,0x08,0x08,0x08,0x10,0x10,0x20,0x40, - - 9, // 0x2A '*' - 0x00,0x00,0x00,0x00,0x00,0x00,0x08,0x00,0x2A,0x00,0x1C,0x00,0x2A,0x00,0x08,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x2B '+' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x7F,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x2C ',' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,0x20,0x20,0x40,0x00, - - 7, // 0x2D '-' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7C,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x2E '.' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,0x20,0x00,0x00,0x00, - - 6, // 0x2F '/' - 0x00,0x00,0x00,0x04,0x04,0x08,0x08,0x10,0x10,0x20,0x20,0x40,0x40,0x80,0x80,0x00, - - 8, // 0x30 '0' - 0x00,0x00,0x00,0x00,0x3C,0x42,0x42,0x42,0x42,0x42,0x42,0x42,0x3C,0x00,0x00,0x00, - - 8, // 0x31 '1' - 0x00,0x00,0x00,0x00,0x08,0x38,0x08,0x08,0x08,0x08,0x08,0x08,0x3E,0x00,0x00,0x00, - - 8, // 0x32 '2' - 0x00,0x00,0x00,0x00,0x3C,0x42,0x42,0x02,0x04,0x18,0x20,0x40,0x7E,0x00,0x00,0x00, - - 8, // 0x33 '3' - 0x00,0x00,0x00,0x00,0x3C,0x42,0x02,0x02,0x1C,0x02,0x02,0x42,0x3C,0x00,0x00,0x00, - - 8, // 0x34 '4' - 0x00,0x00,0x00,0x00,0x04,0x0C,0x14,0x24,0x44,0x7F,0x04,0x04,0x04,0x00,0x00,0x00, - - 8, // 0x35 '5' - 0x00,0x00,0x00,0x00,0x3E,0x20,0x20,0x20,0x3C,0x02,0x02,0x42,0x3C,0x00,0x00,0x00, - - 8, // 0x36 '6' - 0x00,0x00,0x00,0x00,0x1C,0x20,0x40,0x7C,0x42,0x42,0x42,0x42,0x3C,0x00,0x00,0x00, - - 8, // 0x37 '7' - 0x00,0x00,0x00,0x00,0x7E,0x02,0x04,0x04,0x08,0x08,0x10,0x10,0x10,0x00,0x00,0x00, - - 8, // 0x38 '8' - 0x00,0x00,0x00,0x00,0x3C,0x42,0x42,0x42,0x3C,0x42,0x42,0x42,0x3C,0x00,0x00,0x00, - - 8, // 0x39 '9' - 0x00,0x00,0x00,0x00,0x3C,0x42,0x42,0x42,0x42,0x3E,0x02,0x04,0x38,0x00,0x00,0x00, - - 6, // 0x3A ':' - 0x00,0x00,0x00,0x00,0x00,0x00,0x20,0x20,0x00,0x00,0x00,0x20,0x20,0x00,0x00,0x00, - - 6, // 0x3B ';' - 0x00,0x00,0x00,0x00,0x00,0x00,0x20,0x20,0x00,0x00,0x00,0x20,0x20,0x20,0x40,0x00, - - 9, // 0x3C '<' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x03,0x00,0x0C,0x00,0x30,0x00,0x40,0x00,0x30,0x00,0x0C,0x00,0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x3D '=' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7F,0x00,0x00,0x00,0x00,0x00,0x7F,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x3E '>' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x60,0x00,0x18,0x00,0x06,0x00,0x01,0x00,0x06,0x00,0x18,0x00,0x60,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x3F '?' - 0x00,0x00,0x00,0x00,0x38,0x44,0x04,0x08,0x10,0x10,0x00,0x10,0x10,0x00,0x00,0x00, - - 13, // 0x40 '@' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0F,0x80,0x10,0x40,0x27,0xA0,0x48,0x90,0x48,0x90,0x48,0x90,0x48,0x90,0x48,0x90,0x27,0xE0,0x10,0x00,0x0F,0x80,0x00,0x00, - - 9, // 0x41 'A' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x08,0x00,0x08,0x00,0x14,0x00,0x14,0x00,0x22,0x00,0x22,0x00,0x3E,0x00,0x41,0x00,0x41,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x42 'B' - 0x00,0x00,0x00,0x00,0x78,0x44,0x44,0x44,0x7C,0x42,0x42,0x42,0x7C,0x00,0x00,0x00, - - 9, // 0x43 'C' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1E,0x00,0x21,0x00,0x40,0x00,0x40,0x00,0x40,0x00,0x40,0x00,0x40,0x00,0x21,0x00,0x1E,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x44 'D' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7C,0x00,0x42,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x42,0x00,0x7C,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x45 'E' - 0x00,0x00,0x00,0x00,0x7E,0x40,0x40,0x40,0x7E,0x40,0x40,0x40,0x7E,0x00,0x00,0x00, - - 8, // 0x46 'F' - 0x00,0x00,0x00,0x00,0x7E,0x40,0x40,0x40,0x7C,0x40,0x40,0x40,0x40,0x00,0x00,0x00, - - 9, // 0x47 'G' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1E,0x00,0x21,0x00,0x40,0x00,0x40,0x00,0x40,0x00,0x47,0x00,0x41,0x00,0x21,0x00,0x1F,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x48 'H' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x7F,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x49 'I' - 0x00,0x00,0x00,0x00,0x70,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x70,0x00,0x00,0x00, - - 6, // 0x4A 'J' - 0x00,0x00,0x00,0x00,0x38,0x08,0x08,0x08,0x08,0x08,0x08,0x08,0xF0,0x00,0x00,0x00, - - 8, // 0x4B 'K' - 0x00,0x00,0x00,0x00,0x42,0x44,0x48,0x50,0x60,0x50,0x48,0x44,0x42,0x00,0x00,0x00, - - 7, // 0x4C 'L' - 0x00,0x00,0x00,0x00,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x7E,0x00,0x00,0x00, - - 11, // 0x4D 'M' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x60,0xC0,0x60,0xC0,0x51,0x40,0x51,0x40,0x4A,0x40,0x4A,0x40,0x44,0x40,0x44,0x40,0x40,0x40,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x4E 'N' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x61,0x00,0x61,0x00,0x51,0x00,0x51,0x00,0x49,0x00,0x45,0x00,0x45,0x00,0x43,0x00,0x43,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x4F 'O' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1E,0x00,0x21,0x00,0x40,0x80,0x40,0x80,0x40,0x80,0x40,0x80,0x40,0x80,0x21,0x00,0x1E,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x50 'P' - 0x00,0x00,0x00,0x00,0x7C,0x42,0x42,0x42,0x42,0x7C,0x40,0x40,0x40,0x00,0x00,0x00, - - 10, // 0x51 'Q' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1E,0x00,0x21,0x00,0x40,0x80,0x40,0x80,0x40,0x80,0x40,0x80,0x40,0x80,0x21,0x00,0x1E,0x00,0x02,0x00,0x01,0x80,0x00,0x00, - - 9, // 0x52 'R' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7C,0x00,0x42,0x00,0x42,0x00,0x42,0x00,0x44,0x00,0x78,0x00,0x44,0x00,0x42,0x00,0x41,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x53 'S' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3E,0x00,0x41,0x00,0x40,0x00,0x40,0x00,0x3E,0x00,0x01,0x00,0x01,0x00,0x41,0x00,0x3E,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x54 'T' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7F,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x55 'U' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x22,0x00,0x1C,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x56 'V' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x22,0x00,0x22,0x00,0x14,0x00,0x14,0x00,0x08,0x00,0x08,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 13, // 0x57 'W' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x42,0x10,0x42,0x10,0x45,0x10,0x45,0x10,0x25,0x20,0x28,0xA0,0x28,0xA0,0x10,0x40,0x10,0x40,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x58 'X' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x41,0x00,0x41,0x00,0x22,0x00,0x14,0x00,0x08,0x00,0x14,0x00,0x22,0x00,0x41,0x00,0x41,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x59 'Y' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x41,0x00,0x22,0x00,0x22,0x00,0x14,0x00,0x14,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x5A 'Z' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7F,0x00,0x01,0x00,0x02,0x00,0x04,0x00,0x08,0x00,0x10,0x00,0x20,0x00,0x40,0x00,0x7F,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x5B '[' - 0x00,0x00,0x00,0x38,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x38,0x00, - - 6, // 0x5C '\' - 0x00,0x00,0x00,0x80,0x80,0x40,0x40,0x20,0x20,0x10,0x10,0x08,0x08,0x04,0x04,0x00, - - 6, // 0x5D ']' - 0x00,0x00,0x00,0x70,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x70,0x00, - - 11, // 0x5E '^' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x04,0x00,0x0A,0x00,0x11,0x00,0x20,0x80,0x40,0x40,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x5F '_' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xFF,0x00, - - 8, // 0x60 '`' - 0x00,0x00,0x00,0x10,0x08,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x61 'a' - 0x00,0x00,0x00,0x00,0x00,0x00,0x3C,0x02,0x02,0x3E,0x42,0x42,0x3E,0x00,0x00,0x00, - - 8, // 0x62 'b' - 0x00,0x00,0x00,0x40,0x40,0x40,0x5C,0x62,0x42,0x42,0x42,0x42,0x7C,0x00,0x00,0x00, - - 8, // 0x63 'c' - 0x00,0x00,0x00,0x00,0x00,0x00,0x3C,0x42,0x40,0x40,0x40,0x42,0x3C,0x00,0x00,0x00, - - 8, // 0x64 'd' - 0x00,0x00,0x00,0x02,0x02,0x02,0x3E,0x42,0x42,0x42,0x42,0x46,0x3A,0x00,0x00,0x00, - - 8, // 0x65 'e' - 0x00,0x00,0x00,0x00,0x00,0x00,0x3C,0x42,0x42,0x7E,0x40,0x42,0x3C,0x00,0x00,0x00, - - 6, // 0x66 'f' - 0x00,0x00,0x00,0x1C,0x20,0x20,0x78,0x20,0x20,0x20,0x20,0x20,0x20,0x00,0x00,0x00, - - 8, // 0x67 'g' - 0x00,0x00,0x00,0x00,0x00,0x00,0x3E,0x42,0x42,0x42,0x42,0x46,0x3A,0x02,0x02,0x3C, - - 8, // 0x68 'h' - 0x00,0x00,0x00,0x40,0x40,0x40,0x5C,0x62,0x42,0x42,0x42,0x42,0x42,0x00,0x00,0x00, - - 3, // 0x69 'i' - 0x00,0x00,0x00,0x40,0x00,0x00,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x00,0x00,0x00, - - 4, // 0x6A 'j' - 0x00,0x00,0x00,0x20,0x00,0x00,0x60,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0xC0, - - 7, // 0x6B 'k' - 0x00,0x00,0x00,0x40,0x40,0x40,0x44,0x48,0x50,0x60,0x50,0x48,0x44,0x00,0x00,0x00, - - 3, // 0x6C 'l' - 0x00,0x00,0x00,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x00,0x00,0x00, - - 11, // 0x6D 'm' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x59,0x80,0x66,0x40,0x44,0x40,0x44,0x40,0x44,0x40,0x44,0x40,0x44,0x40,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x6E 'n' - 0x00,0x00,0x00,0x00,0x00,0x00,0x5C,0x62,0x42,0x42,0x42,0x42,0x42,0x00,0x00,0x00, - - 8, // 0x6F 'o' - 0x00,0x00,0x00,0x00,0x00,0x00,0x3C,0x42,0x42,0x42,0x42,0x42,0x3C,0x00,0x00,0x00, - - 8, // 0x70 'p' - 0x00,0x00,0x00,0x00,0x00,0x00,0x5C,0x62,0x42,0x42,0x42,0x42,0x7C,0x40,0x40,0x40, - - 8, // 0x71 'q' - 0x00,0x00,0x00,0x00,0x00,0x00,0x3E,0x42,0x42,0x42,0x42,0x46,0x3A,0x02,0x02,0x02, - - 5, // 0x72 'r' - 0x00,0x00,0x00,0x00,0x00,0x00,0x58,0x60,0x40,0x40,0x40,0x40,0x40,0x00,0x00,0x00, - - 7, // 0x73 's' - 0x00,0x00,0x00,0x00,0x00,0x00,0x3C,0x40,0x40,0x38,0x04,0x04,0x78,0x00,0x00,0x00, - - 6, // 0x74 't' - 0x00,0x00,0x00,0x00,0x20,0x20,0x78,0x20,0x20,0x20,0x20,0x20,0x18,0x00,0x00,0x00, - - 8, // 0x75 'u' - 0x00,0x00,0x00,0x00,0x00,0x00,0x42,0x42,0x42,0x42,0x42,0x46,0x3A,0x00,0x00,0x00, - - 8, // 0x76 'v' - 0x00,0x00,0x00,0x00,0x00,0x00,0x42,0x42,0x24,0x24,0x24,0x18,0x18,0x00,0x00,0x00, - - 11, // 0x77 'w' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x44,0x40,0x44,0x40,0x2A,0x80,0x2A,0x80,0x2A,0x80,0x11,0x00,0x11,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x78 'x' - 0x00,0x00,0x00,0x00,0x00,0x00,0x44,0x44,0x28,0x10,0x28,0x44,0x44,0x00,0x00,0x00, - - 8, // 0x79 'y' - 0x00,0x00,0x00,0x00,0x00,0x00,0x42,0x42,0x24,0x24,0x24,0x18,0x18,0x10,0x10,0x20, - - 7, // 0x7A 'z' - 0x00,0x00,0x00,0x00,0x00,0x00,0x7C,0x04,0x08,0x10,0x20,0x40,0x7C,0x00,0x00,0x00, - - 8, // 0x7B '{' - 0x00,0x00,0x00,0x0C,0x10,0x10,0x10,0x10,0x60,0x10,0x10,0x10,0x10,0x10,0x0C,0x00, - - 7, // 0x7C '|' - 0x00,0x00,0x00,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x00, - - 8, // 0x7D '}' - 0x00,0x00,0x00,0x30,0x08,0x08,0x08,0x08,0x06,0x08,0x08,0x08,0x08,0x08,0x30,0x00, - - 11, // 0x7E '~' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x30,0x80,0x4C,0x80,0x43,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 13, // 0x7F '' - 0x00,0x00,0x00,0x00,0x00,0x00,0x3F,0xF0,0x20,0x10,0x20,0x10,0x20,0x10,0x20,0x10,0x20,0x10,0x20,0x10,0x20,0x10,0x20,0x10,0x3F,0xF0,0x00,0x00,0x00,0x00,0x00,0x00, - - 0 - }; - - const int8u verdana16_bold[] = - { - 16, 4, 32, 128-32, - 0x00,0x00,0x11,0x00,0x22,0x00,0x33,0x00,0x54,0x00,0x75,0x00,0xA6,0x00,0xC7,0x00,0xD8,0x00, - 0xE9,0x00,0xFA,0x00,0x1B,0x01,0x3C,0x01,0x4D,0x01,0x5E,0x01,0x6F,0x01,0x90,0x01,0xB1,0x01, - 0xD2,0x01,0xF3,0x01,0x14,0x02,0x35,0x02,0x56,0x02,0x77,0x02,0x98,0x02,0xB9,0x02,0xDA,0x02, - 0xEB,0x02,0xFC,0x02,0x1D,0x03,0x3E,0x03,0x5F,0x03,0x70,0x03,0x91,0x03,0xB2,0x03,0xD3,0x03, - 0xF4,0x03,0x15,0x04,0x36,0x04,0x57,0x04,0x78,0x04,0x99,0x04,0xAA,0x04,0xBB,0x04,0xDC,0x04, - 0xED,0x04,0x0E,0x05,0x2F,0x05,0x50,0x05,0x71,0x05,0x92,0x05,0xB3,0x05,0xD4,0x05,0xE5,0x05, - 0x06,0x06,0x27,0x06,0x48,0x06,0x69,0x06,0x8A,0x06,0xAB,0x06,0xBC,0x06,0xDD,0x06,0xEE,0x06, - 0x0F,0x07,0x30,0x07,0x51,0x07,0x72,0x07,0x93,0x07,0xA4,0x07,0xC5,0x07,0xE6,0x07,0xF7,0x07, - 0x18,0x08,0x39,0x08,0x4A,0x08,0x5B,0x08,0x6C,0x08,0x7D,0x08,0x9E,0x08,0xBF,0x08,0xE0,0x08, - 0x01,0x09,0x22,0x09,0x33,0x09,0x44,0x09,0x55,0x09,0x76,0x09,0x97,0x09,0xB8,0x09,0xD9,0x09, - 0xFA,0x09,0x0B,0x0A,0x2C,0x0A,0x3D,0x0A,0x5E,0x0A,0x7F,0x0A, - - 4, // 0x20 ' ' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x21 '!' - 0x00,0x00,0x00,0x00,0x30,0x30,0x30,0x30,0x30,0x30,0x00,0x30,0x30,0x00,0x00,0x00, - - 7, // 0x22 '"' - 0x00,0x00,0x00,0x6C,0x6C,0x6C,0x6C,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x23 '#' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x09,0x00,0x09,0x00,0x3F,0x80,0x3F,0x80,0x12,0x00,0x7F,0x00,0x7F,0x00,0x24,0x00,0x24,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x24 '$' - 0x00,0x00,0x00,0x00,0x08,0x00,0x08,0x00,0x3E,0x00,0x69,0x00,0x68,0x00,0x78,0x00,0x3E,0x00,0x0F,0x00,0x0B,0x00,0x4B,0x00,0x3E,0x00,0x08,0x00,0x08,0x00,0x00,0x00, - - 17, // 0x25 '%' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3C,0x20,0x00,0x66,0x20,0x00,0x66,0x40,0x00,0x66,0x5E,0x00,0x66,0xB3,0x00,0x3D,0x33,0x00,0x01,0x33,0x00,0x02,0x33,0x00,0x02,0x1E,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x26 '&' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3C,0x00,0x66,0x00,0x66,0x00,0x66,0xC0,0x3C,0xC0,0x66,0x80,0x63,0x00,0x63,0x80,0x3C,0xC0,0x00,0x00,0x00,0x00,0x00,0x00, - - 4, // 0x27 ''' - 0x00,0x00,0x00,0x60,0x60,0x60,0x60,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x28 '(' - 0x00,0x00,0x00,0x0C,0x18,0x30,0x30,0x60,0x60,0x60,0x60,0x60,0x30,0x30,0x18,0x0C, - - 7, // 0x29 ')' - 0x00,0x00,0x00,0x60,0x30,0x18,0x18,0x0C,0x0C,0x0C,0x0C,0x0C,0x18,0x18,0x30,0x60, - - 9, // 0x2A '*' - 0x00,0x00,0x00,0x00,0x00,0x00,0x08,0x00,0x49,0x00,0x2A,0x00,0x1C,0x00,0x2A,0x00,0x49,0x00,0x08,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x2B '+' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x04,0x00,0x04,0x00,0x04,0x00,0x3F,0x80,0x04,0x00,0x04,0x00,0x04,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x2C ',' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x70,0x60,0x60,0xC0,0xC0, - - 7, // 0x2D '-' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7C,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x2E '.' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x30,0x30,0x00,0x00,0x00, - - 9, // 0x2F '/' - 0x00,0x00,0x00,0x00,0x00,0x00,0x03,0x00,0x03,0x00,0x06,0x00,0x06,0x00,0x0C,0x00,0x0C,0x00,0x18,0x00,0x18,0x00,0x30,0x00,0x30,0x00,0x60,0x00,0x60,0x00,0x00,0x00, - - 9, // 0x30 '0' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3E,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x3E,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x31 '1' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0C,0x00,0x3C,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x3F,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x32 '2' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3E,0x00,0x63,0x00,0x63,0x00,0x03,0x00,0x06,0x00,0x0C,0x00,0x18,0x00,0x30,0x00,0x7F,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x33 '3' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3E,0x00,0x63,0x00,0x63,0x00,0x03,0x00,0x0E,0x00,0x03,0x00,0x63,0x00,0x63,0x00,0x3E,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x34 '4' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x06,0x00,0x0E,0x00,0x16,0x00,0x26,0x00,0x46,0x00,0x7F,0x80,0x06,0x00,0x06,0x00,0x06,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x35 '5' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3F,0x00,0x30,0x00,0x30,0x00,0x3E,0x00,0x03,0x00,0x03,0x00,0x63,0x00,0x63,0x00,0x3E,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x36 '6' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1E,0x00,0x30,0x00,0x60,0x00,0x7E,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x3E,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x37 '7' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7F,0x00,0x03,0x00,0x03,0x00,0x06,0x00,0x06,0x00,0x0C,0x00,0x0C,0x00,0x18,0x00,0x18,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x38 '8' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3E,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x3E,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x3E,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x39 '9' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3E,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x3F,0x00,0x03,0x00,0x06,0x00,0x3C,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x3A ':' - 0x00,0x00,0x00,0x00,0x00,0x00,0x30,0x30,0x00,0x00,0x00,0x30,0x30,0x00,0x00,0x00, - - 5, // 0x3B ';' - 0x00,0x00,0x00,0x00,0x00,0x00,0x30,0x30,0x00,0x00,0x00,0x38,0x30,0x30,0x60,0x60, - - 11, // 0x3C '<' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0x03,0x00,0x0C,0x00,0x30,0x00,0x40,0x00,0x30,0x00,0x0C,0x00,0x03,0x00,0x00,0x80,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x3D '=' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3F,0x80,0x00,0x00,0x00,0x00,0x3F,0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x3E '>' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,0x00,0x18,0x00,0x06,0x00,0x01,0x80,0x00,0x40,0x01,0x80,0x06,0x00,0x18,0x00,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x3F '?' - 0x00,0x00,0x00,0x00,0x3C,0x66,0x06,0x0C,0x18,0x18,0x00,0x18,0x18,0x00,0x00,0x00, - - 13, // 0x40 '@' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0F,0x80,0x30,0x60,0x27,0xA0,0x4D,0x90,0x4D,0x90,0x4D,0x90,0x4D,0x90,0x27,0xE0,0x30,0x00,0x0F,0x80,0x00,0x00,0x00,0x00, - - 10, // 0x41 'A' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0C,0x00,0x0C,0x00,0x1E,0x00,0x1E,0x00,0x33,0x00,0x33,0x00,0x7F,0x80,0x61,0x80,0x61,0x80,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x42 'B' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7E,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x7F,0x00,0x61,0x80,0x61,0x80,0x61,0x80,0x7F,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x43 'C' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1F,0x00,0x31,0x80,0x61,0x80,0x60,0x00,0x60,0x00,0x60,0x00,0x61,0x80,0x31,0x80,0x1F,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x44 'D' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7E,0x00,0x63,0x00,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x63,0x00,0x7E,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x45 'E' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7F,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x7F,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x7F,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x46 'F' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7F,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x7F,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x47 'G' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1F,0x00,0x31,0x80,0x61,0x80,0x60,0x00,0x60,0x00,0x63,0x80,0x61,0x80,0x31,0x80,0x1F,0x80,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x48 'H' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x60,0xC0,0x60,0xC0,0x60,0xC0,0x60,0xC0,0x7F,0xC0,0x60,0xC0,0x60,0xC0,0x60,0xC0,0x60,0xC0,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x49 'I' - 0x00,0x00,0x00,0x00,0x78,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x78,0x00,0x00,0x00, - - 7, // 0x4A 'J' - 0x00,0x00,0x00,0x00,0x7C,0x0C,0x0C,0x0C,0x0C,0x0C,0x0C,0x0C,0xF8,0x00,0x00,0x00, - - 9, // 0x4B 'K' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x63,0x00,0x66,0x00,0x6C,0x00,0x78,0x00,0x78,0x00,0x6C,0x00,0x66,0x00,0x63,0x00,0x61,0x80,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x4C 'L' - 0x00,0x00,0x00,0x00,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x7F,0x00,0x00,0x00, - - 12, // 0x4D 'M' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x70,0xE0,0x70,0xE0,0x59,0x60,0x59,0x60,0x4E,0x60,0x4E,0x60,0x44,0x60,0x44,0x60,0x40,0x60,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x4E 'N' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x70,0x80,0x70,0x80,0x58,0x80,0x58,0x80,0x4C,0x80,0x46,0x80,0x46,0x80,0x43,0x80,0x43,0x80,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x4F 'O' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1F,0x00,0x31,0x80,0x60,0xC0,0x60,0xC0,0x60,0xC0,0x60,0xC0,0x60,0xC0,0x31,0x80,0x1F,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x50 'P' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7E,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x7E,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x51 'Q' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1F,0x00,0x31,0x80,0x60,0xC0,0x60,0xC0,0x60,0xC0,0x60,0xC0,0x60,0xC0,0x31,0x80,0x1F,0x00,0x03,0x00,0x01,0xC0,0x00,0x00, - - 9, // 0x52 'R' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7E,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x7E,0x00,0x6C,0x00,0x66,0x00,0x63,0x00,0x61,0x80,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x53 'S' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3E,0x00,0x63,0x00,0x63,0x00,0x70,0x00,0x3E,0x00,0x07,0x00,0x63,0x00,0x63,0x00,0x3E,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x54 'T' - 0x00,0x00,0x00,0x00,0xFF,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x00,0x00,0x00, - - 10, // 0x55 'U' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x3F,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x56 'V' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x61,0x80,0x61,0x80,0x61,0x80,0x33,0x00,0x33,0x00,0x1E,0x00,0x1E,0x00,0x0C,0x00,0x0C,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 14, // 0x57 'W' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x63,0x18,0x63,0x18,0x63,0x18,0x33,0x30,0x37,0xB0,0x34,0xB0,0x1C,0xE0,0x18,0x60,0x18,0x60,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x58 'X' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x61,0x80,0x33,0x00,0x33,0x00,0x1E,0x00,0x0C,0x00,0x1E,0x00,0x33,0x00,0x33,0x00,0x61,0x80,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x59 'Y' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x61,0x80,0x61,0x80,0x33,0x00,0x1E,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x5A 'Z' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7F,0x00,0x06,0x00,0x0C,0x00,0x0C,0x00,0x18,0x00,0x18,0x00,0x30,0x00,0x30,0x00,0x7F,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x5B '[' - 0x00,0x00,0x00,0x78,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x78,0x00, - - 9, // 0x5C '\' - 0x00,0x00,0x00,0x00,0x00,0x00,0x60,0x00,0x60,0x00,0x30,0x00,0x30,0x00,0x18,0x00,0x18,0x00,0x0C,0x00,0x0C,0x00,0x06,0x00,0x06,0x00,0x03,0x00,0x03,0x00,0x00,0x00, - - 6, // 0x5D ']' - 0x00,0x00,0x00,0x78,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x78,0x00, - - 10, // 0x5E '^' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0C,0x00,0x1E,0x00,0x33,0x00,0x61,0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x5F '_' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xFF,0x80,0x00,0x00, - - 9, // 0x60 '`' - 0x00,0x00,0x00,0x00,0x00,0x00,0x30,0x00,0x18,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x61 'a' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3E,0x00,0x03,0x00,0x3F,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x3F,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x62 'b' - 0x00,0x00,0x00,0x00,0x00,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x6E,0x00,0x73,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x7E,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x63 'c' - 0x00,0x00,0x00,0x00,0x00,0x00,0x3E,0x63,0x60,0x60,0x60,0x63,0x3E,0x00,0x00,0x00, - - 9, // 0x64 'd' - 0x00,0x00,0x00,0x00,0x00,0x00,0x03,0x00,0x03,0x00,0x03,0x00,0x3F,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x67,0x00,0x3B,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x65 'e' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3E,0x00,0x63,0x00,0x63,0x00,0x7F,0x00,0x60,0x00,0x63,0x00,0x3E,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x66 'f' - 0x00,0x00,0x00,0x38,0x60,0x60,0xF8,0x60,0x60,0x60,0x60,0x60,0x60,0x00,0x00,0x00, - - 9, // 0x67 'g' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3F,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x67,0x00,0x3B,0x00,0x03,0x00,0x03,0x00,0x3E,0x00, - - 9, // 0x68 'h' - 0x00,0x00,0x00,0x00,0x00,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x6E,0x00,0x73,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 4, // 0x69 'i' - 0x00,0x00,0x00,0x60,0x60,0x00,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x00,0x00,0x00, - - 5, // 0x6A 'j' - 0x00,0x00,0x00,0x30,0x30,0x00,0x70,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0xE0, - - 8, // 0x6B 'k' - 0x00,0x00,0x00,0x60,0x60,0x60,0x66,0x6C,0x78,0x78,0x6C,0x66,0x63,0x00,0x00,0x00, - - 4, // 0x6C 'l' - 0x00,0x00,0x00,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x00,0x00,0x00, - - 14, // 0x6D 'm' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x6E,0x70,0x73,0x98,0x63,0x18,0x63,0x18,0x63,0x18,0x63,0x18,0x63,0x18,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x6E 'n' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x6E,0x00,0x73,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x6F 'o' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3E,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x3E,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x70 'p' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x6E,0x00,0x73,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x7E,0x00,0x60,0x00,0x60,0x00,0x60,0x00, - - 9, // 0x71 'q' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3F,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x67,0x00,0x3B,0x00,0x03,0x00,0x03,0x00,0x03,0x00, - - 6, // 0x72 'r' - 0x00,0x00,0x00,0x00,0x00,0x00,0x6C,0x7C,0x60,0x60,0x60,0x60,0x60,0x00,0x00,0x00, - - 8, // 0x73 's' - 0x00,0x00,0x00,0x00,0x00,0x00,0x3E,0x60,0x70,0x3C,0x0E,0x06,0x7C,0x00,0x00,0x00, - - 6, // 0x74 't' - 0x00,0x00,0x00,0x00,0x60,0x60,0xF8,0x60,0x60,0x60,0x60,0x60,0x38,0x00,0x00,0x00, - - 9, // 0x75 'u' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x67,0x00,0x3B,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x76 'v' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x36,0x00,0x36,0x00,0x1C,0x00,0x1C,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 12, // 0x77 'w' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x66,0x60,0x66,0x60,0x66,0x60,0x69,0x60,0x39,0xC0,0x30,0xC0,0x30,0xC0,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x78 'x' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x63,0x00,0x63,0x00,0x36,0x00,0x1C,0x00,0x36,0x00,0x63,0x00,0x63,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x79 'y' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x36,0x00,0x36,0x00,0x1C,0x00,0x1C,0x00,0x0C,0x00,0x18,0x00,0x18,0x00, - - 8, // 0x7A 'z' - 0x00,0x00,0x00,0x00,0x00,0x00,0x7E,0x06,0x0C,0x18,0x30,0x60,0x7E,0x00,0x00,0x00, - - 9, // 0x7B '{' - 0x00,0x00,0x00,0x00,0x00,0x00,0x07,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x18,0x00,0x70,0x00,0x18,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x07,0x00,0x00,0x00, - - 8, // 0x7C '|' - 0x00,0x00,0x00,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x00, - - 9, // 0x7D '}' - 0x00,0x00,0x00,0x00,0x00,0x00,0x70,0x00,0x18,0x00,0x18,0x00,0x18,0x00,0x0C,0x00,0x07,0x00,0x0C,0x00,0x18,0x00,0x18,0x00,0x18,0x00,0x18,0x00,0x70,0x00,0x00,0x00, - - 11, // 0x7E '~' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x38,0x40,0x44,0x40,0x44,0x40,0x43,0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 13, // 0x7F '' - 0x00,0x00,0x00,0x00,0x00,0x00,0x3F,0xF0,0x20,0x10,0x20,0x10,0x20,0x10,0x20,0x10,0x20,0x10,0x20,0x10,0x20,0x10,0x20,0x10,0x3F,0xF0,0x00,0x00,0x00,0x00,0x00,0x00, - - 0 - }; - - const int8u verdana17[] = - { - 17, 4, 32, 128-32, - 0x00,0x00,0x12,0x00,0x24,0x00,0x36,0x00,0x59,0x00,0x7C,0x00,0x9F,0x00,0xC2,0x00,0xD4,0x00, - 0xE6,0x00,0xF8,0x00,0x1B,0x01,0x3E,0x01,0x50,0x01,0x62,0x01,0x74,0x01,0x86,0x01,0xA9,0x01, - 0xCC,0x01,0xEF,0x01,0x12,0x02,0x35,0x02,0x58,0x02,0x7B,0x02,0x9E,0x02,0xC1,0x02,0xE4,0x02, - 0xF6,0x02,0x08,0x03,0x2B,0x03,0x4E,0x03,0x71,0x03,0x83,0x03,0xA6,0x03,0xC9,0x03,0xEC,0x03, - 0x0F,0x04,0x32,0x04,0x55,0x04,0x67,0x04,0x8A,0x04,0xAD,0x04,0xBF,0x04,0xD1,0x04,0xF4,0x04, - 0x06,0x05,0x29,0x05,0x4C,0x05,0x6F,0x05,0x81,0x05,0xA4,0x05,0xC7,0x05,0xEA,0x05,0x0D,0x06, - 0x30,0x06,0x53,0x06,0x76,0x06,0x99,0x06,0xBC,0x06,0xDF,0x06,0xF1,0x06,0x03,0x07,0x15,0x07, - 0x38,0x07,0x5B,0x07,0x7E,0x07,0x90,0x07,0xB3,0x07,0xC5,0x07,0xE8,0x07,0xFA,0x07,0x0C,0x08, - 0x2F,0x08,0x52,0x08,0x64,0x08,0x76,0x08,0x88,0x08,0x9A,0x08,0xBD,0x08,0xE0,0x08,0x03,0x09, - 0x26,0x09,0x49,0x09,0x5B,0x09,0x6D,0x09,0x7F,0x09,0xA2,0x09,0xB4,0x09,0xD7,0x09,0xFA,0x09, - 0x0C,0x0A,0x1E,0x0A,0x41,0x0A,0x53,0x0A,0x76,0x0A,0x99,0x0A, - - 5, // 0x20 ' ' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x21 '!' - 0x00,0x00,0x00,0x00,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x00,0x20,0x20,0x00,0x00,0x00, - - 6, // 0x22 '"' - 0x00,0x00,0x00,0x48,0x48,0x48,0x48,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x23 '#' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x04,0x80,0x04,0x80,0x09,0x00,0x3F,0xC0,0x09,0x00,0x12,0x00,0x7F,0x80,0x12,0x00,0x24,0x00,0x24,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x24 '$' - 0x00,0x00,0x00,0x00,0x00,0x00,0x08,0x00,0x08,0x00,0x3E,0x00,0x49,0x00,0x48,0x00,0x48,0x00,0x3E,0x00,0x09,0x00,0x09,0x00,0x49,0x00,0x3E,0x00,0x08,0x00,0x08,0x00,0x00,0x00, - - 15, // 0x25 '%' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x38,0x20,0x44,0x40,0x44,0x80,0x44,0x80,0x45,0x38,0x39,0x44,0x02,0x44,0x04,0x44,0x04,0x44,0x08,0x38,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x26 '&' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3C,0x00,0x42,0x00,0x42,0x00,0x44,0x00,0x38,0x80,0x44,0x80,0x42,0x80,0x41,0x00,0x22,0x80,0x1C,0x40,0x00,0x00,0x00,0x00,0x00,0x00, - - 4, // 0x27 ''' - 0x00,0x00,0x00,0x40,0x40,0x40,0x40,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x28 '(' - 0x00,0x00,0x00,0x08,0x10,0x20,0x20,0x40,0x40,0x40,0x40,0x40,0x40,0x20,0x20,0x10,0x08, - - 6, // 0x29 ')' - 0x00,0x00,0x00,0x40,0x20,0x10,0x10,0x08,0x08,0x08,0x08,0x08,0x08,0x10,0x10,0x20,0x40, - - 9, // 0x2A '*' - 0x00,0x00,0x00,0x00,0x00,0x00,0x08,0x00,0x49,0x00,0x2A,0x00,0x1C,0x00,0x2A,0x00,0x49,0x00,0x08,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x2B '+' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x04,0x00,0x04,0x00,0x04,0x00,0x04,0x00,0x7F,0xC0,0x04,0x00,0x04,0x00,0x04,0x00,0x04,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x2C ',' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,0x20,0x20,0x40,0x00, - - 7, // 0x2D '-' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7C,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x2E '.' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,0x20,0x00,0x00,0x00, - - 6, // 0x2F '/' - 0x00,0x00,0x00,0x04,0x08,0x08,0x08,0x10,0x10,0x20,0x20,0x20,0x40,0x40,0x80,0x80,0x00, - - 9, // 0x30 '0' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1C,0x00,0x22,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x22,0x00,0x1C,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x31 '1' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x08,0x00,0x38,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x3E,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x32 '2' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3E,0x00,0x41,0x00,0x01,0x00,0x01,0x00,0x02,0x00,0x0C,0x00,0x10,0x00,0x20,0x00,0x40,0x00,0x7F,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x33 '3' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3E,0x00,0x41,0x00,0x01,0x00,0x02,0x00,0x1C,0x00,0x02,0x00,0x01,0x00,0x01,0x00,0x42,0x00,0x3C,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x34 '4' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x02,0x00,0x06,0x00,0x0A,0x00,0x12,0x00,0x22,0x00,0x42,0x00,0x7F,0x80,0x02,0x00,0x02,0x00,0x02,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x35 '5' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7F,0x00,0x40,0x00,0x40,0x00,0x40,0x00,0x7C,0x00,0x02,0x00,0x01,0x00,0x01,0x00,0x42,0x00,0x3C,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x36 '6' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0E,0x00,0x30,0x00,0x20,0x00,0x40,0x00,0x7C,0x00,0x42,0x00,0x41,0x00,0x41,0x00,0x22,0x00,0x1C,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x37 '7' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7F,0x00,0x01,0x00,0x02,0x00,0x02,0x00,0x04,0x00,0x04,0x00,0x08,0x00,0x10,0x00,0x10,0x00,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x38 '8' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3E,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x3E,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x3E,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x39 '9' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1C,0x00,0x22,0x00,0x41,0x00,0x41,0x00,0x21,0x00,0x1F,0x00,0x01,0x00,0x02,0x00,0x06,0x00,0x38,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x3A ':' - 0x00,0x00,0x00,0x00,0x00,0x00,0x20,0x20,0x00,0x00,0x00,0x00,0x20,0x20,0x00,0x00,0x00, - - 6, // 0x3B ';' - 0x00,0x00,0x00,0x00,0x00,0x00,0x20,0x20,0x00,0x00,0x00,0x00,0x20,0x20,0x20,0x40,0x00, - - 11, // 0x3C '<' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x80,0x06,0x00,0x18,0x00,0x60,0x00,0x60,0x00,0x18,0x00,0x06,0x00,0x01,0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x3D '=' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3F,0xC0,0x00,0x00,0x00,0x00,0x3F,0xC0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x3E '>' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x30,0x00,0x0C,0x00,0x03,0x00,0x00,0xC0,0x00,0xC0,0x03,0x00,0x0C,0x00,0x30,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x3F '?' - 0x00,0x00,0x00,0x00,0x3C,0x42,0x02,0x02,0x0C,0x10,0x10,0x00,0x10,0x10,0x00,0x00,0x00, - - 14, // 0x40 '@' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x07,0xC0,0x18,0x20,0x20,0x10,0x27,0xC8,0x48,0x48,0x48,0x48,0x48,0x48,0x48,0x48,0x27,0xF0,0x20,0x00,0x18,0x00,0x07,0xC0,0x00,0x00, - - 10, // 0x41 'A' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0C,0x00,0x12,0x00,0x12,0x00,0x21,0x00,0x21,0x00,0x21,0x00,0x7F,0x80,0x40,0x80,0x80,0x40,0x80,0x40,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x42 'B' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7E,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x7E,0x00,0x41,0x00,0x40,0x80,0x40,0x80,0x41,0x00,0x7E,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x43 'C' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0F,0x00,0x30,0x80,0x20,0x00,0x40,0x00,0x40,0x00,0x40,0x00,0x40,0x00,0x20,0x00,0x30,0x80,0x0F,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x44 'D' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7E,0x00,0x41,0x80,0x40,0x80,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x80,0x41,0x80,0x7E,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x45 'E' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7F,0x00,0x40,0x00,0x40,0x00,0x40,0x00,0x7F,0x00,0x40,0x00,0x40,0x00,0x40,0x00,0x40,0x00,0x7F,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x46 'F' - 0x00,0x00,0x00,0x00,0x7F,0x40,0x40,0x40,0x7E,0x40,0x40,0x40,0x40,0x40,0x00,0x00,0x00, - - 11, // 0x47 'G' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0F,0x00,0x30,0xC0,0x20,0x40,0x40,0x00,0x40,0x00,0x43,0xC0,0x40,0x40,0x20,0x40,0x30,0x40,0x0F,0x80,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x48 'H' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x40,0x80,0x40,0x80,0x40,0x80,0x40,0x80,0x7F,0x80,0x40,0x80,0x40,0x80,0x40,0x80,0x40,0x80,0x40,0x80,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x49 'I' - 0x00,0x00,0x00,0x00,0x70,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x70,0x00,0x00,0x00, - - 6, // 0x4A 'J' - 0x00,0x00,0x00,0x00,0x38,0x08,0x08,0x08,0x08,0x08,0x08,0x08,0x08,0xF0,0x00,0x00,0x00, - - 10, // 0x4B 'K' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x41,0x00,0x42,0x00,0x44,0x00,0x48,0x00,0x50,0x00,0x68,0x00,0x44,0x00,0x42,0x00,0x41,0x00,0x40,0x80,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x4C 'L' - 0x00,0x00,0x00,0x00,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x7F,0x00,0x00,0x00, - - 11, // 0x4D 'M' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x60,0xC0,0x60,0xC0,0x51,0x40,0x51,0x40,0x4A,0x40,0x4A,0x40,0x44,0x40,0x44,0x40,0x40,0x40,0x40,0x40,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x4E 'N' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x60,0x80,0x60,0x80,0x50,0x80,0x48,0x80,0x48,0x80,0x44,0x80,0x44,0x80,0x42,0x80,0x41,0x80,0x41,0x80,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x4F 'O' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0E,0x00,0x31,0x80,0x20,0x80,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x20,0x80,0x31,0x80,0x0E,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x50 'P' - 0x00,0x00,0x00,0x00,0x7C,0x42,0x41,0x41,0x42,0x7C,0x40,0x40,0x40,0x40,0x00,0x00,0x00, - - 11, // 0x51 'Q' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0E,0x00,0x31,0x80,0x20,0x80,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x20,0x80,0x31,0x80,0x0E,0x00,0x02,0x00,0x02,0x00,0x01,0xC0, - - 10, // 0x52 'R' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7C,0x00,0x42,0x00,0x42,0x00,0x42,0x00,0x44,0x00,0x78,0x00,0x44,0x00,0x42,0x00,0x41,0x00,0x40,0x80,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x53 'S' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1F,0x00,0x20,0x80,0x40,0x00,0x40,0x00,0x38,0x00,0x07,0x00,0x00,0x80,0x40,0x80,0x21,0x00,0x1E,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x54 'T' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xFF,0x80,0x08,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x55 'U' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x40,0x80,0x40,0x80,0x40,0x80,0x40,0x80,0x40,0x80,0x40,0x80,0x40,0x80,0x40,0x80,0x21,0x00,0x1E,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x56 'V' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0x40,0x80,0x40,0x40,0x80,0x40,0x80,0x21,0x00,0x21,0x00,0x21,0x00,0x12,0x00,0x12,0x00,0x0C,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 15, // 0x57 'W' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x41,0x04,0x41,0x04,0x22,0x88,0x22,0x88,0x22,0x88,0x14,0x50,0x14,0x50,0x14,0x50,0x08,0x20,0x08,0x20,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x58 'X' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x40,0x80,0x21,0x00,0x12,0x00,0x12,0x00,0x0C,0x00,0x0C,0x00,0x12,0x00,0x12,0x00,0x21,0x00,0x40,0x80,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x59 'Y' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0x80,0x41,0x00,0x22,0x00,0x22,0x00,0x14,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x5A 'Z' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7F,0x80,0x00,0x80,0x01,0x00,0x02,0x00,0x04,0x00,0x08,0x00,0x10,0x00,0x20,0x00,0x40,0x00,0x7F,0x80,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x5B '[' - 0x00,0x00,0x00,0x3C,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x3C, - - 6, // 0x5C '\' - 0x00,0x00,0x00,0x80,0x40,0x40,0x40,0x20,0x20,0x10,0x10,0x10,0x08,0x08,0x08,0x04,0x00, - - 6, // 0x5D ']' - 0x00,0x00,0x00,0x78,0x08,0x08,0x08,0x08,0x08,0x08,0x08,0x08,0x08,0x08,0x08,0x08,0x78, - - 11, // 0x5E '^' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x04,0x00,0x0A,0x00,0x11,0x00,0x20,0x80,0x40,0x40,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x5F '_' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xFF,0x80,0x00,0x00, - - 9, // 0x60 '`' - 0x00,0x00,0x00,0x00,0x00,0x00,0x10,0x00,0x08,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x61 'a' - 0x00,0x00,0x00,0x00,0x00,0x00,0x1C,0x22,0x02,0x3E,0x42,0x42,0x46,0x3A,0x00,0x00,0x00, - - 9, // 0x62 'b' - 0x00,0x00,0x00,0x00,0x00,0x00,0x40,0x00,0x40,0x00,0x40,0x00,0x5C,0x00,0x62,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x42,0x00,0x7C,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x63 'c' - 0x00,0x00,0x00,0x00,0x00,0x00,0x1C,0x22,0x40,0x40,0x40,0x40,0x22,0x1C,0x00,0x00,0x00, - - 9, // 0x64 'd' - 0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x01,0x00,0x01,0x00,0x1F,0x00,0x21,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x23,0x00,0x1D,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x65 'e' - 0x00,0x00,0x00,0x00,0x00,0x00,0x18,0x24,0x42,0x7E,0x40,0x40,0x22,0x1C,0x00,0x00,0x00, - - 6, // 0x66 'f' - 0x00,0x00,0x00,0x1C,0x20,0x20,0x7C,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x00,0x00,0x00, - - 9, // 0x67 'g' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1F,0x00,0x21,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x23,0x00,0x1D,0x00,0x01,0x00,0x22,0x00,0x1C,0x00, - - 9, // 0x68 'h' - 0x00,0x00,0x00,0x00,0x00,0x00,0x40,0x00,0x40,0x00,0x40,0x00,0x5E,0x00,0x61,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 3, // 0x69 'i' - 0x00,0x00,0x00,0x00,0x40,0x00,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x00,0x00,0x00, - - 5, // 0x6A 'j' - 0x00,0x00,0x00,0x00,0x10,0x00,0x70,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0xE0, - - 8, // 0x6B 'k' - 0x00,0x00,0x00,0x40,0x40,0x40,0x42,0x44,0x48,0x50,0x70,0x48,0x44,0x42,0x00,0x00,0x00, - - 3, // 0x6C 'l' - 0x00,0x00,0x00,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x00,0x00,0x00, - - 13, // 0x6D 'm' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x5C,0xE0,0x63,0x10,0x42,0x10,0x42,0x10,0x42,0x10,0x42,0x10,0x42,0x10,0x42,0x10,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x6E 'n' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x5E,0x00,0x61,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x6F 'o' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1C,0x00,0x22,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x22,0x00,0x1C,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x70 'p' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x5C,0x00,0x62,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x42,0x00,0x7C,0x00,0x40,0x00,0x40,0x00,0x40,0x00, - - 9, // 0x71 'q' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1F,0x00,0x21,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x23,0x00,0x1D,0x00,0x01,0x00,0x01,0x00,0x01,0x00, - - 6, // 0x72 'r' - 0x00,0x00,0x00,0x00,0x00,0x00,0x5C,0x60,0x40,0x40,0x40,0x40,0x40,0x40,0x00,0x00,0x00, - - 8, // 0x73 's' - 0x00,0x00,0x00,0x00,0x00,0x00,0x3C,0x42,0x40,0x30,0x0C,0x02,0x42,0x3C,0x00,0x00,0x00, - - 6, // 0x74 't' - 0x00,0x00,0x00,0x00,0x20,0x20,0x7C,0x20,0x20,0x20,0x20,0x20,0x20,0x1C,0x00,0x00,0x00, - - 9, // 0x75 'u' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x43,0x00,0x3D,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x76 'v' - 0x00,0x00,0x00,0x00,0x00,0x00,0x42,0x42,0x24,0x24,0x24,0x18,0x18,0x18,0x00,0x00,0x00, - - 11, // 0x77 'w' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x44,0x40,0x44,0x40,0x2A,0x80,0x2A,0x80,0x2A,0x80,0x2A,0x80,0x11,0x00,0x11,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x78 'x' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x41,0x00,0x22,0x00,0x14,0x00,0x08,0x00,0x08,0x00,0x14,0x00,0x22,0x00,0x41,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x79 'y' - 0x00,0x00,0x00,0x00,0x00,0x00,0x42,0x42,0x24,0x24,0x24,0x18,0x18,0x18,0x10,0x10,0x20, - - 8, // 0x7A 'z' - 0x00,0x00,0x00,0x00,0x00,0x00,0x7E,0x02,0x04,0x08,0x10,0x20,0x40,0x7E,0x00,0x00,0x00, - - 9, // 0x7B '{' - 0x00,0x00,0x00,0x00,0x00,0x00,0x07,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x10,0x00,0x60,0x00,0x10,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x07,0x00, - - 6, // 0x7C '|' - 0x00,0x00,0x00,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10, - - 9, // 0x7D '}' - 0x00,0x00,0x00,0x00,0x00,0x00,0x70,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x04,0x00,0x03,0x00,0x04,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x70,0x00, - - 11, // 0x7E '~' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x38,0x40,0x44,0x40,0x44,0x40,0x43,0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 14, // 0x7F '' - 0x00,0x00,0x00,0x00,0x00,0x00,0x3F,0xF8,0x20,0x08,0x20,0x08,0x20,0x08,0x20,0x08,0x20,0x08,0x20,0x08,0x20,0x08,0x20,0x08,0x20,0x08,0x3F,0xF8,0x00,0x00,0x00,0x00,0x00,0x00, - - 0 - }; - - const int8u verdana17_bold[] = - { - 17, 4, 32, 128-32, - 0x00,0x00,0x12,0x00,0x24,0x00,0x36,0x00,0x59,0x00,0x7C,0x00,0xB0,0x00,0xD3,0x00,0xE5,0x00, - 0xF7,0x00,0x09,0x01,0x2C,0x01,0x4F,0x01,0x61,0x01,0x73,0x01,0x85,0x01,0xA8,0x01,0xCB,0x01, - 0xEE,0x01,0x11,0x02,0x34,0x02,0x57,0x02,0x7A,0x02,0x9D,0x02,0xC0,0x02,0xE3,0x02,0x06,0x03, - 0x18,0x03,0x2A,0x03,0x4D,0x03,0x70,0x03,0x93,0x03,0xB6,0x03,0xD9,0x03,0xFC,0x03,0x1F,0x04, - 0x42,0x04,0x65,0x04,0x88,0x04,0xAB,0x04,0xCE,0x04,0xF1,0x04,0x03,0x05,0x15,0x05,0x38,0x05, - 0x5B,0x05,0x7E,0x05,0xA1,0x05,0xC4,0x05,0xE7,0x05,0x0A,0x06,0x2D,0x06,0x50,0x06,0x73,0x06, - 0x96,0x06,0xB9,0x06,0xDC,0x06,0xFF,0x06,0x22,0x07,0x45,0x07,0x57,0x07,0x7A,0x07,0x8C,0x07, - 0xAF,0x07,0xD2,0x07,0xF5,0x07,0x18,0x08,0x3B,0x08,0x4D,0x08,0x70,0x08,0x93,0x08,0xA5,0x08, - 0xC8,0x08,0xEB,0x08,0xFD,0x08,0x0F,0x09,0x32,0x09,0x44,0x09,0x67,0x09,0x8A,0x09,0xAD,0x09, - 0xD0,0x09,0xF3,0x09,0x05,0x0A,0x17,0x0A,0x29,0x0A,0x4C,0x0A,0x6F,0x0A,0x92,0x0A,0xB5,0x0A, - 0xD8,0x0A,0xEA,0x0A,0x0D,0x0B,0x1F,0x0B,0x42,0x0B,0x65,0x0B, - - 5, // 0x20 ' ' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x21 '!' - 0x00,0x00,0x00,0x00,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x00,0x30,0x30,0x00,0x00,0x00, - - 8, // 0x22 '"' - 0x00,0x00,0x00,0x66,0x66,0x66,0x66,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 12, // 0x23 '#' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x04,0x40,0x04,0x40,0x3F,0xE0,0x3F,0xE0,0x08,0x80,0x11,0x00,0x7F,0xC0,0x7F,0xC0,0x22,0x00,0x22,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x24 '$' - 0x00,0x00,0x00,0x00,0x04,0x00,0x04,0x00,0x1F,0x00,0x34,0x80,0x64,0x00,0x74,0x00,0x3C,0x00,0x0F,0x00,0x0B,0x80,0x09,0x80,0x4B,0x00,0x3E,0x00,0x08,0x00,0x08,0x00,0x00,0x00, - - 18, // 0x25 '%' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3C,0x08,0x00,0x66,0x10,0x00,0x66,0x20,0x00,0x66,0x2F,0x00,0x66,0x59,0x80,0x66,0x99,0x80,0x3D,0x19,0x80,0x01,0x19,0x80,0x02,0x19,0x80,0x04,0x0F,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 12, // 0x26 '&' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1E,0x00,0x33,0x00,0x33,0x00,0x36,0x00,0x1C,0x60,0x36,0x60,0x63,0x60,0x61,0xC0,0x31,0xC0,0x1F,0x60,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x27 ''' - 0x00,0x00,0x00,0x60,0x60,0x60,0x60,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x28 '(' - 0x00,0x00,0x00,0x0C,0x18,0x30,0x30,0x60,0x60,0x60,0x60,0x60,0x60,0x30,0x30,0x18,0x0C, - - 8, // 0x29 ')' - 0x00,0x00,0x00,0x30,0x18,0x0C,0x0C,0x06,0x06,0x06,0x06,0x06,0x06,0x0C,0x0C,0x18,0x30, - - 10, // 0x2A '*' - 0x00,0x00,0x00,0x00,0x00,0x00,0x08,0x00,0x49,0x00,0x2A,0x00,0x1C,0x00,0x2A,0x00,0x49,0x00,0x08,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 12, // 0x2B '+' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x04,0x00,0x04,0x00,0x04,0x00,0x04,0x00,0x7F,0xC0,0x04,0x00,0x04,0x00,0x04,0x00,0x04,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x2C ',' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x70,0x60,0x60,0xC0,0xC0,0x00, - - 7, // 0x2D '-' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7C,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x2E '.' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x30,0x30,0x30,0x00,0x00,0x00, - - 10, // 0x2F '/' - 0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x80,0x01,0x80,0x03,0x00,0x03,0x00,0x06,0x00,0x06,0x00,0x0C,0x00,0x18,0x00,0x18,0x00,0x30,0x00,0x30,0x00,0x60,0x00,0x60,0x00,0x00,0x00, - - 10, // 0x30 '0' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1E,0x00,0x33,0x00,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x33,0x00,0x1E,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x31 '1' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0C,0x00,0x3C,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x3F,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x32 '2' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3F,0x00,0x61,0x80,0x61,0x80,0x01,0x80,0x03,0x00,0x06,0x00,0x0C,0x00,0x18,0x00,0x30,0x00,0x7F,0x80,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x33 '3' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3F,0x00,0x61,0x80,0x61,0x80,0x01,0x80,0x0F,0x00,0x03,0x00,0x01,0x80,0x61,0x80,0x63,0x00,0x3E,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x34 '4' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x03,0x00,0x07,0x00,0x0B,0x00,0x13,0x00,0x23,0x00,0x43,0x00,0x7F,0xC0,0x03,0x00,0x03,0x00,0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x35 '5' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3F,0x80,0x30,0x00,0x30,0x00,0x3E,0x00,0x03,0x00,0x01,0x80,0x01,0x80,0x61,0x80,0x63,0x00,0x3E,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x36 '6' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0F,0x00,0x38,0x00,0x30,0x00,0x6E,0x00,0x73,0x00,0x61,0x80,0x61,0x80,0x61,0x80,0x33,0x00,0x1E,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x37 '7' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7F,0x80,0x01,0x80,0x03,0x00,0x03,0x00,0x06,0x00,0x06,0x00,0x0C,0x00,0x0C,0x00,0x18,0x00,0x18,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x38 '8' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3F,0x00,0x61,0x80,0x61,0x80,0x61,0x80,0x3F,0x00,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x3F,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x39 '9' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1E,0x00,0x33,0x00,0x61,0x80,0x61,0x80,0x61,0x80,0x33,0x80,0x1D,0x80,0x03,0x00,0x07,0x00,0x3C,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x3A ':' - 0x00,0x00,0x00,0x00,0x00,0x00,0x30,0x30,0x30,0x00,0x00,0x30,0x30,0x30,0x00,0x00,0x00, - - 6, // 0x3B ';' - 0x00,0x00,0x00,0x00,0x00,0x00,0x30,0x30,0x30,0x00,0x00,0x38,0x30,0x30,0x60,0x60,0x00, - - 12, // 0x3C '<' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xC0,0x03,0x00,0x0C,0x00,0x30,0x00,0x40,0x00,0x30,0x00,0x0C,0x00,0x03,0x00,0x00,0xC0,0x00,0x00,0x00,0x00,0x00,0x00, - - 12, // 0x3D '=' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7F,0xC0,0x00,0x00,0x00,0x00,0x00,0x00,0x7F,0xC0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 12, // 0x3E '>' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x60,0x00,0x18,0x00,0x06,0x00,0x01,0x80,0x00,0x40,0x01,0x80,0x06,0x00,0x18,0x00,0x60,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x3F '?' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3E,0x00,0x63,0x00,0x03,0x00,0x06,0x00,0x0C,0x00,0x18,0x00,0x18,0x00,0x00,0x00,0x18,0x00,0x18,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 14, // 0x40 '@' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x07,0xC0,0x18,0x20,0x20,0x10,0x27,0xC8,0x4C,0xC8,0x4C,0xC8,0x4C,0xC8,0x4C,0xC8,0x27,0xF0,0x20,0x00,0x18,0x00,0x07,0xC0,0x00,0x00, - - 11, // 0x41 'A' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0E,0x00,0x0E,0x00,0x0E,0x00,0x1B,0x00,0x1B,0x00,0x31,0x80,0x3F,0x80,0x31,0x80,0x60,0xC0,0x60,0xC0,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x42 'B' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7F,0x00,0x61,0x80,0x61,0x80,0x61,0x80,0x7F,0x00,0x61,0x80,0x60,0xC0,0x60,0xC0,0x61,0x80,0x7F,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x43 'C' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0F,0x80,0x30,0xC0,0x30,0xC0,0x60,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x30,0xC0,0x30,0xC0,0x0F,0x80,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x44 'D' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7E,0x00,0x61,0x80,0x61,0x80,0x60,0xC0,0x60,0xC0,0x60,0xC0,0x60,0xC0,0x61,0x80,0x61,0x80,0x7E,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x45 'E' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7F,0x80,0x60,0x00,0x60,0x00,0x60,0x00,0x7F,0x80,0x60,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x7F,0x80,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x46 'F' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7F,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x7F,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x47 'G' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0F,0x80,0x30,0xC0,0x30,0xC0,0x60,0x00,0x60,0x00,0x63,0xC0,0x60,0xC0,0x30,0xC0,0x30,0xC0,0x0F,0x80,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x48 'H' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x60,0xC0,0x60,0xC0,0x60,0xC0,0x60,0xC0,0x7F,0xC0,0x60,0xC0,0x60,0xC0,0x60,0xC0,0x60,0xC0,0x60,0xC0,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x49 'I' - 0x00,0x00,0x00,0x00,0x7E,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x7E,0x00,0x00,0x00, - - 8, // 0x4A 'J' - 0x00,0x00,0x00,0x00,0x3E,0x06,0x06,0x06,0x06,0x06,0x06,0x06,0x0C,0xF8,0x00,0x00,0x00, - - 11, // 0x4B 'K' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x60,0xC0,0x61,0x80,0x63,0x00,0x66,0x00,0x6C,0x00,0x7C,0x00,0x76,0x00,0x63,0x00,0x61,0x80,0x60,0xC0,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x4C 'L' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x7F,0x80,0x00,0x00,0x00,0x00,0x00,0x00, - - 13, // 0x4D 'M' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x60,0x70,0x70,0x70,0x70,0xF0,0x58,0xB0,0x59,0xB0,0x4D,0x30,0x4F,0x30,0x46,0x30,0x46,0x30,0x40,0x30,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x4E 'N' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x60,0x40,0x70,0x40,0x58,0x40,0x4C,0x40,0x4C,0x40,0x46,0x40,0x43,0x40,0x43,0x40,0x41,0xC0,0x40,0xC0,0x00,0x00,0x00,0x00,0x00,0x00, - - 12, // 0x4F 'O' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0F,0x00,0x30,0xC0,0x30,0xC0,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x30,0xC0,0x30,0xC0,0x0F,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x50 'P' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7E,0x00,0x63,0x00,0x61,0x80,0x61,0x80,0x61,0x80,0x63,0x00,0x7E,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 12, // 0x51 'Q' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0F,0x00,0x30,0xC0,0x30,0xC0,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x30,0xC0,0x30,0xC0,0x0F,0x80,0x03,0x00,0x03,0x00,0x01,0xE0, - - 11, // 0x52 'R' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7F,0x00,0x61,0x80,0x60,0xC0,0x60,0xC0,0x61,0x80,0x7F,0x00,0x63,0x00,0x61,0x80,0x60,0xC0,0x60,0x60,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x53 'S' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1F,0x00,0x31,0x80,0x61,0x80,0x60,0x00,0x3E,0x00,0x1F,0x00,0x01,0x80,0x61,0x80,0x63,0x00,0x3E,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x54 'T' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7F,0x80,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x55 'U' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x60,0xC0,0x60,0xC0,0x60,0xC0,0x60,0xC0,0x60,0xC0,0x60,0xC0,0x60,0xC0,0x60,0xC0,0x31,0x80,0x1F,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x56 'V' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x60,0xC0,0x60,0xC0,0x60,0xC0,0x31,0x80,0x31,0x80,0x31,0x80,0x1B,0x00,0x1B,0x00,0x0E,0x00,0x0E,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 16, // 0x57 'W' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x61,0x86,0x61,0x86,0x63,0xC6,0x32,0x4C,0x36,0x6C,0x36,0x6C,0x34,0x2C,0x1C,0x38,0x18,0x18,0x18,0x18,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x58 'X' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x60,0xC0,0x31,0x80,0x31,0x80,0x1B,0x00,0x0E,0x00,0x0E,0x00,0x1B,0x00,0x31,0x80,0x31,0x80,0x60,0xC0,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x59 'Y' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xC0,0xC0,0x61,0x80,0x61,0x80,0x33,0x00,0x1E,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x5A 'Z' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7F,0x80,0x01,0x80,0x03,0x00,0x06,0x00,0x0C,0x00,0x0C,0x00,0x18,0x00,0x30,0x00,0x60,0x00,0x7F,0x80,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x5B '[' - 0x00,0x00,0x00,0x3E,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x3E, - - 10, // 0x5C '\' - 0x00,0x00,0x00,0x00,0x00,0x00,0x60,0x00,0x60,0x00,0x30,0x00,0x30,0x00,0x18,0x00,0x18,0x00,0x0C,0x00,0x06,0x00,0x06,0x00,0x03,0x00,0x03,0x00,0x01,0x80,0x01,0x80,0x00,0x00, - - 8, // 0x5D ']' - 0x00,0x00,0x00,0x7C,0x0C,0x0C,0x0C,0x0C,0x0C,0x0C,0x0C,0x0C,0x0C,0x0C,0x0C,0x0C,0x7C, - - 12, // 0x5E '^' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x04,0x00,0x0E,0x00,0x1B,0x00,0x31,0x80,0x60,0xC0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x5F '_' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xFF,0xC0,0x00,0x00, - - 10, // 0x60 '`' - 0x00,0x00,0x00,0x00,0x00,0x00,0x18,0x00,0x0C,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x61 'a' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3E,0x00,0x03,0x00,0x03,0x00,0x3F,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x3F,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x62 'b' - 0x00,0x00,0x00,0x00,0x00,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x6E,0x00,0x73,0x00,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x63,0x00,0x7E,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x63 'c' - 0x00,0x00,0x00,0x00,0x00,0x00,0x1E,0x33,0x60,0x60,0x60,0x60,0x33,0x1E,0x00,0x00,0x00, - - 10, // 0x64 'd' - 0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x80,0x01,0x80,0x01,0x80,0x1F,0x80,0x31,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x33,0x80,0x1D,0x80,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x65 'e' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1E,0x00,0x33,0x00,0x63,0x00,0x7F,0x00,0x60,0x00,0x60,0x00,0x33,0x00,0x1E,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x66 'f' - 0x00,0x00,0x00,0x1C,0x30,0x30,0x7C,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x00,0x00,0x00, - - 10, // 0x67 'g' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1F,0x80,0x31,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x33,0x80,0x1D,0x80,0x01,0x80,0x03,0x00,0x3E,0x00, - - 10, // 0x68 'h' - 0x00,0x00,0x00,0x00,0x00,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x6F,0x00,0x71,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x00,0x00,0x00,0x00,0x00,0x00, - - 4, // 0x69 'i' - 0x00,0x00,0x00,0x60,0x60,0x00,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x00,0x00,0x00, - - 6, // 0x6A 'j' - 0x00,0x00,0x00,0x18,0x18,0x00,0x38,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0xF0, - - 9, // 0x6B 'k' - 0x00,0x00,0x00,0x00,0x00,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x63,0x00,0x66,0x00,0x6C,0x00,0x78,0x00,0x7C,0x00,0x66,0x00,0x63,0x00,0x61,0x80,0x00,0x00,0x00,0x00,0x00,0x00, - - 4, // 0x6C 'l' - 0x00,0x00,0x00,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x00,0x00,0x00, - - 14, // 0x6D 'm' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x6E,0x70,0x73,0x98,0x63,0x18,0x63,0x18,0x63,0x18,0x63,0x18,0x63,0x18,0x63,0x18,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x6E 'n' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x6F,0x00,0x71,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x6F 'o' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1E,0x00,0x33,0x00,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x33,0x00,0x1E,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x70 'p' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x6E,0x00,0x73,0x00,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x63,0x00,0x7E,0x00,0x60,0x00,0x60,0x00,0x60,0x00, - - 10, // 0x71 'q' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1F,0x80,0x31,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x33,0x80,0x1D,0x80,0x01,0x80,0x01,0x80,0x01,0x80, - - 7, // 0x72 'r' - 0x00,0x00,0x00,0x00,0x00,0x00,0x6E,0x7E,0x60,0x60,0x60,0x60,0x60,0x60,0x00,0x00,0x00, - - 8, // 0x73 's' - 0x00,0x00,0x00,0x00,0x00,0x00,0x3C,0x62,0x60,0x7C,0x3E,0x06,0x46,0x3C,0x00,0x00,0x00, - - 6, // 0x74 't' - 0x00,0x00,0x00,0x00,0x60,0x60,0xFC,0x60,0x60,0x60,0x60,0x60,0x60,0x3C,0x00,0x00,0x00, - - 10, // 0x75 'u' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x63,0x80,0x3D,0x80,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x76 'v' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x36,0x00,0x36,0x00,0x36,0x00,0x1C,0x00,0x1C,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 14, // 0x77 'w' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x63,0x18,0x63,0x18,0x33,0x30,0x37,0xB0,0x34,0xB0,0x1C,0xE0,0x1C,0xE0,0x0C,0xC0,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x78 'x' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x63,0x00,0x63,0x00,0x36,0x00,0x1C,0x00,0x1C,0x00,0x36,0x00,0x63,0x00,0x63,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x79 'y' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x63,0x00,0x63,0x00,0x63,0x00,0x36,0x00,0x36,0x00,0x36,0x00,0x1C,0x00,0x1C,0x00,0x0C,0x00,0x18,0x00,0x18,0x00, - - 8, // 0x7A 'z' - 0x00,0x00,0x00,0x00,0x00,0x00,0x7E,0x06,0x0C,0x18,0x18,0x30,0x60,0x7E,0x00,0x00,0x00, - - 10, // 0x7B '{' - 0x00,0x00,0x00,0x00,0x00,0x00,0x07,0x80,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x18,0x00,0x70,0x00,0x18,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x07,0x80, - - 8, // 0x7C '|' - 0x00,0x00,0x00,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18, - - 10, // 0x7D '}' - 0x00,0x00,0x00,0x00,0x00,0x00,0x78,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x06,0x00,0x03,0x80,0x06,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x78,0x00, - - 12, // 0x7E '~' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x18,0x20,0x24,0x20,0x46,0x20,0x42,0x40,0x41,0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 14, // 0x7F '' - 0x00,0x00,0x00,0x00,0x00,0x00,0x3F,0xF8,0x20,0x08,0x20,0x08,0x20,0x08,0x20,0x08,0x20,0x08,0x20,0x08,0x20,0x08,0x20,0x08,0x20,0x08,0x3F,0xF8,0x00,0x00,0x00,0x00,0x00,0x00, - - 0 - }; - - const int8u verdana18[] = - { - 18, 4, 32, 128-32, - 0x00,0x00,0x13,0x00,0x26,0x00,0x39,0x00,0x5E,0x00,0x83,0x00,0xA8,0x00,0xCD,0x00,0xE0,0x00, - 0xF3,0x00,0x06,0x01,0x2B,0x01,0x50,0x01,0x63,0x01,0x76,0x01,0x89,0x01,0x9C,0x01,0xC1,0x01, - 0xE6,0x01,0x0B,0x02,0x30,0x02,0x55,0x02,0x7A,0x02,0x9F,0x02,0xC4,0x02,0xE9,0x02,0x0E,0x03, - 0x21,0x03,0x34,0x03,0x59,0x03,0x7E,0x03,0xA3,0x03,0xB6,0x03,0xDB,0x03,0x00,0x04,0x25,0x04, - 0x4A,0x04,0x6F,0x04,0x94,0x04,0xB9,0x04,0xDE,0x04,0x03,0x05,0x16,0x05,0x29,0x05,0x4E,0x05, - 0x61,0x05,0x86,0x05,0xAB,0x05,0xD0,0x05,0xF5,0x05,0x1A,0x06,0x3F,0x06,0x64,0x06,0x89,0x06, - 0xAE,0x06,0xD3,0x06,0xF8,0x06,0x1D,0x07,0x42,0x07,0x67,0x07,0x7A,0x07,0x8D,0x07,0xA0,0x07, - 0xC5,0x07,0xEA,0x07,0x0F,0x08,0x34,0x08,0x59,0x08,0x6C,0x08,0x91,0x08,0xB6,0x08,0xC9,0x08, - 0xEE,0x08,0x13,0x09,0x26,0x09,0x39,0x09,0x5E,0x09,0x71,0x09,0x96,0x09,0xBB,0x09,0xE0,0x09, - 0x05,0x0A,0x2A,0x0A,0x3D,0x0A,0x50,0x0A,0x63,0x0A,0x88,0x0A,0xAD,0x0A,0xD2,0x0A,0xF7,0x0A, - 0x1C,0x0B,0x41,0x0B,0x66,0x0B,0x79,0x0B,0x9E,0x0B,0xC3,0x0B, - - 5, // 0x20 ' ' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x21 '!' - 0x00,0x00,0x00,0x00,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x00,0x20,0x20,0x00,0x00,0x00, - - 7, // 0x22 '"' - 0x00,0x00,0x00,0x48,0x48,0x48,0x48,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 12, // 0x23 '#' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x04,0x80,0x04,0x80,0x09,0x00,0x3F,0xC0,0x09,0x00,0x11,0x00,0x12,0x00,0x7F,0x80,0x12,0x00,0x24,0x00,0x24,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x24 '$' - 0x00,0x00,0x00,0x00,0x00,0x00,0x08,0x00,0x08,0x00,0x3E,0x00,0x49,0x00,0x48,0x00,0x48,0x00,0x38,0x00,0x0E,0x00,0x09,0x00,0x09,0x00,0x49,0x00,0x3E,0x00,0x08,0x00,0x08,0x00,0x08,0x00, - - 16, // 0x25 '%' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x38,0x20,0x44,0x40,0x44,0x40,0x44,0x80,0x44,0x80,0x38,0x9C,0x01,0x22,0x01,0x22,0x02,0x22,0x02,0x22,0x04,0x1C,0x00,0x00,0x00,0x00,0x00,0x00, - - 12, // 0x26 '&' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1E,0x00,0x21,0x00,0x21,0x00,0x21,0x00,0x1E,0x40,0x24,0x40,0x42,0x40,0x41,0x40,0x40,0x80,0x21,0x40,0x1E,0x20,0x00,0x00,0x00,0x00,0x00,0x00, - - 4, // 0x27 ''' - 0x00,0x00,0x00,0x40,0x40,0x40,0x40,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x28 '(' - 0x00,0x00,0x00,0x08,0x10,0x20,0x20,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x20,0x20,0x10,0x08, - - 7, // 0x29 ')' - 0x00,0x00,0x00,0x20,0x10,0x08,0x08,0x04,0x04,0x04,0x04,0x04,0x04,0x04,0x08,0x08,0x10,0x20, - - 10, // 0x2A '*' - 0x00,0x00,0x00,0x00,0x00,0x00,0x08,0x00,0x49,0x00,0x2A,0x00,0x1C,0x00,0x2A,0x00,0x49,0x00,0x08,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 12, // 0x2B '+' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x02,0x00,0x02,0x00,0x02,0x00,0x02,0x00,0x3F,0xE0,0x02,0x00,0x02,0x00,0x02,0x00,0x02,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x2C ',' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,0x20,0x20,0x40,0x40, - - 7, // 0x2D '-' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7C,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x2E '.' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,0x20,0x00,0x00,0x00, - - 7, // 0x2F '/' - 0x00,0x00,0x00,0x02,0x04,0x04,0x04,0x08,0x08,0x10,0x10,0x20,0x20,0x40,0x40,0x40,0x80,0x00, - - 10, // 0x30 '0' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1E,0x00,0x21,0x00,0x40,0x80,0x40,0x80,0x40,0x80,0x40,0x80,0x40,0x80,0x40,0x80,0x40,0x80,0x21,0x00,0x1E,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x31 '1' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x04,0x00,0x04,0x00,0x1C,0x00,0x04,0x00,0x04,0x00,0x04,0x00,0x04,0x00,0x04,0x00,0x04,0x00,0x04,0x00,0x1F,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x32 '2' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3E,0x00,0x41,0x00,0x00,0x80,0x00,0x80,0x00,0x80,0x01,0x00,0x02,0x00,0x0C,0x00,0x30,0x00,0x40,0x00,0x7F,0x80,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x33 '3' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3F,0x00,0x40,0x80,0x00,0x80,0x01,0x00,0x0E,0x00,0x01,0x00,0x00,0x80,0x00,0x80,0x00,0x80,0x41,0x00,0x3E,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x34 '4' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x03,0x00,0x05,0x00,0x09,0x00,0x11,0x00,0x21,0x00,0x41,0x00,0x7F,0xC0,0x01,0x00,0x01,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x35 '5' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3F,0x80,0x20,0x00,0x20,0x00,0x20,0x00,0x3E,0x00,0x01,0x00,0x00,0x80,0x00,0x80,0x00,0x80,0x41,0x00,0x3E,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x36 '6' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0F,0x00,0x10,0x00,0x20,0x00,0x40,0x00,0x5E,0x00,0x61,0x00,0x40,0x80,0x40,0x80,0x40,0x80,0x21,0x00,0x1E,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x37 '7' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7F,0x00,0x01,0x00,0x02,0x00,0x02,0x00,0x04,0x00,0x04,0x00,0x08,0x00,0x08,0x00,0x10,0x00,0x10,0x00,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x38 '8' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1E,0x00,0x21,0x00,0x40,0x80,0x40,0x80,0x21,0x00,0x1E,0x00,0x21,0x00,0x40,0x80,0x40,0x80,0x21,0x00,0x1E,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x39 '9' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1E,0x00,0x21,0x00,0x40,0x80,0x40,0x80,0x40,0x80,0x20,0x80,0x1F,0x80,0x00,0x80,0x01,0x00,0x02,0x00,0x3C,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x3A ':' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x10,0x10,0x00,0x00,0x00,0x00,0x10,0x10,0x00,0x00,0x00, - - 7, // 0x3B ';' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x10,0x10,0x00,0x00,0x00,0x00,0x10,0x10,0x10,0x20,0x20, - - 12, // 0x3C '<' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xC0,0x03,0x00,0x0C,0x00,0x30,0x00,0x30,0x00,0x0C,0x00,0x03,0x00,0x00,0xC0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 12, // 0x3D '=' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3F,0xE0,0x00,0x00,0x00,0x00,0x3F,0xE0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 12, // 0x3E '>' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x30,0x00,0x0C,0x00,0x03,0x00,0x00,0xC0,0x00,0xC0,0x03,0x00,0x0C,0x00,0x30,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x3F '?' - 0x00,0x00,0x00,0x00,0x3C,0x42,0x02,0x02,0x04,0x08,0x10,0x10,0x00,0x10,0x10,0x00,0x00,0x00, - - 15, // 0x40 '@' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x07,0x80,0x18,0x60,0x20,0x10,0x23,0xD0,0x44,0x48,0x48,0x48,0x48,0x48,0x48,0x48,0x44,0x48,0x23,0xF0,0x20,0x00,0x18,0x00,0x07,0xC0,0x00,0x00, - - 10, // 0x41 'A' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0C,0x00,0x12,0x00,0x12,0x00,0x12,0x00,0x21,0x00,0x21,0x00,0x40,0x80,0x7F,0x80,0x40,0x80,0x80,0x40,0x80,0x40,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x42 'B' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7E,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x7E,0x00,0x41,0x00,0x40,0x80,0x40,0x80,0x40,0x80,0x41,0x00,0x7E,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x43 'C' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0F,0x00,0x30,0xC0,0x20,0x40,0x40,0x00,0x40,0x00,0x40,0x00,0x40,0x00,0x40,0x00,0x20,0x40,0x30,0xC0,0x0F,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x44 'D' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7E,0x00,0x41,0x80,0x40,0x80,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x80,0x41,0x80,0x7E,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x45 'E' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7F,0x00,0x40,0x00,0x40,0x00,0x40,0x00,0x7F,0x00,0x40,0x00,0x40,0x00,0x40,0x00,0x40,0x00,0x40,0x00,0x7F,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x46 'F' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7F,0x80,0x40,0x00,0x40,0x00,0x40,0x00,0x7F,0x00,0x40,0x00,0x40,0x00,0x40,0x00,0x40,0x00,0x40,0x00,0x40,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 12, // 0x47 'G' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0F,0x80,0x30,0x60,0x20,0x20,0x40,0x00,0x40,0x00,0x41,0xE0,0x40,0x20,0x40,0x20,0x20,0x20,0x30,0x20,0x0F,0xC0,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x48 'H' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x7F,0xC0,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x49 'I' - 0x00,0x00,0x00,0x00,0x70,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x70,0x00,0x00,0x00, - - 7, // 0x4A 'J' - 0x00,0x00,0x00,0x00,0x3C,0x04,0x04,0x04,0x04,0x04,0x04,0x04,0x04,0x08,0xF0,0x00,0x00,0x00, - - 10, // 0x4B 'K' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x40,0x80,0x41,0x00,0x42,0x00,0x44,0x00,0x48,0x00,0x50,0x00,0x68,0x00,0x44,0x00,0x42,0x00,0x41,0x00,0x40,0x80,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x4C 'L' - 0x00,0x00,0x00,0x00,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x7F,0x00,0x00,0x00, - - 13, // 0x4D 'M' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x60,0x30,0x50,0x50,0x50,0x50,0x48,0x90,0x48,0x90,0x45,0x10,0x45,0x10,0x42,0x10,0x42,0x10,0x40,0x10,0x40,0x10,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x4E 'N' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x40,0x40,0x60,0x40,0x50,0x40,0x48,0x40,0x48,0x40,0x44,0x40,0x42,0x40,0x42,0x40,0x41,0x40,0x40,0xC0,0x40,0x40,0x00,0x00,0x00,0x00,0x00,0x00, - - 12, // 0x4F 'O' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0F,0x00,0x30,0xC0,0x20,0x40,0x40,0x20,0x40,0x20,0x40,0x20,0x40,0x20,0x40,0x20,0x20,0x40,0x30,0xC0,0x0F,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x50 'P' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7E,0x00,0x41,0x00,0x40,0x80,0x40,0x80,0x40,0x80,0x41,0x00,0x7E,0x00,0x40,0x00,0x40,0x00,0x40,0x00,0x40,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 12, // 0x51 'Q' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0F,0x00,0x30,0xC0,0x20,0x40,0x40,0x20,0x40,0x20,0x40,0x20,0x40,0x20,0x40,0x20,0x20,0x40,0x30,0xC0,0x0F,0x00,0x01,0x00,0x01,0x00,0x00,0xE0, - - 10, // 0x52 'R' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7C,0x00,0x42,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x42,0x00,0x7C,0x00,0x42,0x00,0x41,0x00,0x40,0x80,0x40,0x40,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x53 'S' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1F,0x00,0x20,0x80,0x40,0x00,0x40,0x00,0x20,0x00,0x1E,0x00,0x01,0x00,0x00,0x80,0x40,0x80,0x21,0x00,0x1E,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x54 'T' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xFF,0x80,0x08,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x55 'U' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x20,0x80,0x1F,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x56 'V' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0x40,0x80,0x40,0x40,0x80,0x40,0x80,0x40,0x80,0x21,0x00,0x21,0x00,0x12,0x00,0x12,0x00,0x12,0x00,0x0C,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 15, // 0x57 'W' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x41,0x04,0x41,0x04,0x22,0x88,0x22,0x88,0x22,0x88,0x12,0x90,0x14,0x50,0x14,0x50,0x14,0x50,0x08,0x20,0x08,0x20,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x58 'X' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x40,0x80,0x21,0x00,0x21,0x00,0x12,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x12,0x00,0x21,0x00,0x21,0x00,0x40,0x80,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x59 'Y' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0x80,0x41,0x00,0x22,0x00,0x22,0x00,0x14,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x5A 'Z' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7F,0x80,0x00,0x80,0x01,0x00,0x02,0x00,0x04,0x00,0x08,0x00,0x08,0x00,0x10,0x00,0x20,0x00,0x40,0x00,0x7F,0x80,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x5B '[' - 0x00,0x00,0x00,0x3C,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x3C, - - 7, // 0x5C '\' - 0x00,0x00,0x00,0x80,0x40,0x40,0x40,0x20,0x20,0x10,0x10,0x08,0x08,0x04,0x04,0x04,0x02,0x00, - - 7, // 0x5D ']' - 0x00,0x00,0x00,0x78,0x08,0x08,0x08,0x08,0x08,0x08,0x08,0x08,0x08,0x08,0x08,0x08,0x08,0x78, - - 12, // 0x5E '^' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x06,0x00,0x09,0x00,0x10,0x80,0x20,0x40,0x40,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x5F '_' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xFF,0xC0,0x00,0x00, - - 10, // 0x60 '`' - 0x00,0x00,0x00,0x00,0x00,0x00,0x10,0x00,0x08,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x61 'a' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1E,0x00,0x21,0x00,0x01,0x00,0x3F,0x00,0x41,0x00,0x41,0x00,0x43,0x00,0x3D,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x62 'b' - 0x00,0x00,0x00,0x00,0x00,0x00,0x40,0x00,0x40,0x00,0x40,0x00,0x40,0x00,0x5C,0x00,0x62,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x42,0x00,0x7C,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x63 'c' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1E,0x21,0x40,0x40,0x40,0x40,0x21,0x1E,0x00,0x00,0x00, - - 9, // 0x64 'd' - 0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x01,0x00,0x01,0x00,0x01,0x00,0x1F,0x00,0x21,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x23,0x00,0x1D,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x65 'e' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1C,0x00,0x22,0x00,0x41,0x00,0x7F,0x00,0x40,0x00,0x40,0x00,0x21,0x00,0x1E,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x66 'f' - 0x00,0x00,0x00,0x1C,0x20,0x20,0x20,0x7C,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x00,0x00,0x00, - - 9, // 0x67 'g' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1F,0x00,0x21,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x23,0x00,0x1D,0x00,0x01,0x00,0x22,0x00,0x1C,0x00, - - 9, // 0x68 'h' - 0x00,0x00,0x00,0x00,0x00,0x00,0x40,0x00,0x40,0x00,0x40,0x00,0x40,0x00,0x5E,0x00,0x61,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 3, // 0x69 'i' - 0x00,0x00,0x00,0x00,0x40,0x00,0x00,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x00,0x00,0x00, - - 5, // 0x6A 'j' - 0x00,0x00,0x00,0x00,0x10,0x00,0x00,0x70,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0xE0, - - 9, // 0x6B 'k' - 0x00,0x00,0x00,0x00,0x00,0x00,0x40,0x00,0x40,0x00,0x40,0x00,0x40,0x00,0x42,0x00,0x44,0x00,0x48,0x00,0x50,0x00,0x68,0x00,0x44,0x00,0x42,0x00,0x41,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 3, // 0x6C 'l' - 0x00,0x00,0x00,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x00,0x00,0x00, - - 15, // 0x6D 'm' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x2E,0x70,0x31,0x88,0x21,0x08,0x21,0x08,0x21,0x08,0x21,0x08,0x21,0x08,0x21,0x08,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x6E 'n' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x5E,0x00,0x61,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x6F 'o' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1E,0x00,0x21,0x00,0x40,0x80,0x40,0x80,0x40,0x80,0x40,0x80,0x21,0x00,0x1E,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x70 'p' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x5C,0x00,0x62,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x42,0x00,0x7C,0x00,0x40,0x00,0x40,0x00,0x40,0x00, - - 9, // 0x71 'q' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1F,0x00,0x21,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x23,0x00,0x1D,0x00,0x01,0x00,0x01,0x00,0x01,0x00, - - 6, // 0x72 'r' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x5C,0x60,0x40,0x40,0x40,0x40,0x40,0x40,0x00,0x00,0x00, - - 8, // 0x73 's' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3C,0x42,0x40,0x30,0x0C,0x02,0x42,0x3C,0x00,0x00,0x00, - - 6, // 0x74 't' - 0x00,0x00,0x00,0x00,0x00,0x20,0x20,0x7C,0x20,0x20,0x20,0x20,0x20,0x20,0x1C,0x00,0x00,0x00, - - 9, // 0x75 'u' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x41,0x00,0x43,0x00,0x3D,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x76 'v' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x41,0x00,0x41,0x00,0x22,0x00,0x22,0x00,0x22,0x00,0x14,0x00,0x14,0x00,0x08,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 13, // 0x77 'w' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x42,0x10,0x42,0x10,0x25,0x20,0x25,0x20,0x28,0xA0,0x28,0xA0,0x10,0x40,0x10,0x40,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x78 'x' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x41,0x00,0x22,0x00,0x14,0x00,0x08,0x00,0x08,0x00,0x14,0x00,0x22,0x00,0x41,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x79 'y' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x41,0x00,0x41,0x00,0x22,0x00,0x22,0x00,0x22,0x00,0x14,0x00,0x14,0x00,0x08,0x00,0x08,0x00,0x10,0x00,0x10,0x00, - - 9, // 0x7A 'z' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7F,0x00,0x02,0x00,0x04,0x00,0x08,0x00,0x10,0x00,0x20,0x00,0x40,0x00,0x7F,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x7B '{' - 0x00,0x00,0x00,0x00,0x00,0x00,0x07,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x10,0x00,0x60,0x00,0x10,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x08,0x00,0x07,0x00, - - 7, // 0x7C '|' - 0x00,0x00,0x00,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10, - - 10, // 0x7D '}' - 0x00,0x00,0x00,0x00,0x00,0x00,0x38,0x00,0x04,0x00,0x04,0x00,0x04,0x00,0x04,0x00,0x04,0x00,0x02,0x00,0x01,0x80,0x02,0x00,0x04,0x00,0x04,0x00,0x04,0x00,0x04,0x00,0x04,0x00,0x38,0x00, - - 12, // 0x7E '~' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x18,0x20,0x24,0x20,0x42,0x40,0x41,0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 15, // 0x7F '' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3F,0xF8,0x20,0x08,0x20,0x08,0x20,0x08,0x20,0x08,0x20,0x08,0x20,0x08,0x20,0x08,0x20,0x08,0x20,0x08,0x3F,0xF8,0x00,0x00,0x00,0x00,0x00,0x00, - - 0 - }; - - const int8u verdana18_bold[] = - { - 18, 4, 32, 128-32, - 0x00,0x00,0x13,0x00,0x26,0x00,0x4B,0x00,0x70,0x00,0x95,0x00,0xCC,0x00,0xF1,0x00,0x04,0x01, - 0x17,0x01,0x2A,0x01,0x4F,0x01,0x74,0x01,0x87,0x01,0x9A,0x01,0xAD,0x01,0xD2,0x01,0xF7,0x01, - 0x1C,0x02,0x41,0x02,0x66,0x02,0x8B,0x02,0xB0,0x02,0xD5,0x02,0xFA,0x02,0x1F,0x03,0x44,0x03, - 0x57,0x03,0x6A,0x03,0x8F,0x03,0xB4,0x03,0xD9,0x03,0xFE,0x03,0x23,0x04,0x48,0x04,0x6D,0x04, - 0x92,0x04,0xB7,0x04,0xDC,0x04,0x01,0x05,0x26,0x05,0x4B,0x05,0x5E,0x05,0x71,0x05,0x96,0x05, - 0xBB,0x05,0xE0,0x05,0x05,0x06,0x2A,0x06,0x4F,0x06,0x74,0x06,0x99,0x06,0xBE,0x06,0xE3,0x06, - 0x08,0x07,0x2D,0x07,0x52,0x07,0x77,0x07,0x9C,0x07,0xC1,0x07,0xD4,0x07,0xF9,0x07,0x0C,0x08, - 0x31,0x08,0x56,0x08,0x7B,0x08,0xA0,0x08,0xC5,0x08,0xD8,0x08,0xFD,0x08,0x22,0x09,0x35,0x09, - 0x5A,0x09,0x7F,0x09,0x92,0x09,0xA5,0x09,0xCA,0x09,0xDD,0x09,0x02,0x0A,0x27,0x0A,0x4C,0x0A, - 0x71,0x0A,0x96,0x0A,0xA9,0x0A,0xCE,0x0A,0xE1,0x0A,0x06,0x0B,0x2B,0x0B,0x50,0x0B,0x75,0x0B, - 0x9A,0x0B,0xBF,0x0B,0xE4,0x0B,0xF7,0x0B,0x1C,0x0C,0x41,0x0C, - - 5, // 0x20 ' ' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x21 '!' - 0x00,0x00,0x00,0x00,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x00,0x30,0x30,0x00,0x00,0x00, - - 9, // 0x22 '"' - 0x00,0x00,0x00,0x00,0x00,0x00,0x36,0x00,0x36,0x00,0x36,0x00,0x36,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 13, // 0x23 '#' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x04,0x20,0x04,0x20,0x08,0x40,0x3F,0xF0,0x3F,0xF0,0x08,0x40,0x10,0x80,0x7F,0xE0,0x7F,0xE0,0x21,0x00,0x21,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x24 '$' - 0x00,0x00,0x00,0x00,0x00,0x00,0x04,0x00,0x04,0x00,0x1F,0x80,0x34,0xC0,0x64,0xC0,0x64,0x00,0x3C,0x00,0x07,0x80,0x04,0xC0,0x64,0xC0,0x65,0x80,0x3F,0x00,0x04,0x00,0x04,0x00,0x00,0x00, - - 19, // 0x25 '%' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3E,0x08,0x00,0x63,0x10,0x00,0x63,0x10,0x00,0x63,0x20,0x00,0x63,0x2F,0x80,0x63,0x58,0xC0,0x3E,0x98,0xC0,0x00,0x98,0xC0,0x01,0x18,0xC0,0x01,0x18,0xC0,0x02,0x0F,0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 13, // 0x26 '&' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1E,0x00,0x33,0x00,0x33,0x00,0x33,0x00,0x1E,0x60,0x36,0x60,0x63,0x60,0x61,0xC0,0x60,0xC0,0x30,0xE0,0x1F,0x30,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x27 ''' - 0x00,0x00,0x00,0x60,0x60,0x60,0x60,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x28 '(' - 0x00,0x00,0x00,0x06,0x0C,0x18,0x30,0x30,0x60,0x60,0x60,0x60,0x60,0x30,0x30,0x18,0x0C,0x06, - - 8, // 0x29 ')' - 0x00,0x00,0x00,0x60,0x30,0x18,0x0C,0x0C,0x06,0x06,0x06,0x06,0x06,0x0C,0x0C,0x18,0x30,0x60, - - 11, // 0x2A '*' - 0x00,0x00,0x00,0x00,0x00,0x00,0x04,0x00,0x24,0x80,0x15,0x00,0x0E,0x00,0x15,0x00,0x24,0x80,0x04,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 13, // 0x2B '+' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x02,0x00,0x02,0x00,0x02,0x00,0x02,0x00,0x3F,0xE0,0x02,0x00,0x02,0x00,0x02,0x00,0x02,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x2C ',' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x70,0x60,0x60,0x60,0xC0,0xC0, - - 7, // 0x2D '-' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7C,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 5, // 0x2E '.' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x30,0x30,0x30,0x00,0x00,0x00, - - 10, // 0x2F '/' - 0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x80,0x01,0x80,0x03,0x00,0x03,0x00,0x06,0x00,0x06,0x00,0x0C,0x00,0x0C,0x00,0x18,0x00,0x18,0x00,0x30,0x00,0x30,0x00,0x60,0x00,0x60,0x00,0x00,0x00, - - 11, // 0x30 '0' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1F,0x00,0x31,0x80,0x60,0xC0,0x60,0xC0,0x60,0xC0,0x60,0xC0,0x60,0xC0,0x60,0xC0,0x60,0xC0,0x31,0x80,0x1F,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x31 '1' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x06,0x00,0x1E,0x00,0x06,0x00,0x06,0x00,0x06,0x00,0x06,0x00,0x06,0x00,0x06,0x00,0x06,0x00,0x06,0x00,0x1F,0x80,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x32 '2' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3F,0x00,0x61,0x80,0x60,0xC0,0x00,0xC0,0x01,0x80,0x03,0x00,0x06,0x00,0x0C,0x00,0x18,0x00,0x30,0x00,0x7F,0xC0,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x33 '3' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3F,0x00,0x61,0x80,0x60,0xC0,0x00,0xC0,0x01,0x80,0x0F,0x00,0x01,0x80,0x00,0xC0,0x60,0xC0,0x61,0x80,0x3F,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x34 '4' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x80,0x03,0x80,0x05,0x80,0x09,0x80,0x11,0x80,0x21,0x80,0x41,0x80,0x7F,0xE0,0x01,0x80,0x01,0x80,0x01,0x80,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x35 '5' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3F,0xC0,0x30,0x00,0x30,0x00,0x30,0x00,0x3F,0x00,0x01,0x80,0x00,0xC0,0x00,0xC0,0x60,0xC0,0x61,0x80,0x3F,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x36 '6' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0F,0x80,0x18,0x00,0x30,0x00,0x60,0x00,0x6F,0x00,0x71,0x80,0x60,0xC0,0x60,0xC0,0x60,0xC0,0x31,0x80,0x1F,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x37 '7' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7F,0xC0,0x00,0xC0,0x01,0x80,0x01,0x80,0x03,0x00,0x03,0x00,0x06,0x00,0x06,0x00,0x0C,0x00,0x0C,0x00,0x18,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x38 '8' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1F,0x00,0x31,0x80,0x60,0xC0,0x60,0xC0,0x31,0x80,0x1F,0x00,0x31,0x80,0x60,0xC0,0x60,0xC0,0x31,0x80,0x1F,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x39 '9' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1F,0x00,0x31,0x80,0x60,0xC0,0x60,0xC0,0x60,0xC0,0x31,0xC0,0x1E,0xC0,0x00,0xC0,0x01,0x80,0x03,0x00,0x3E,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x3A ':' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x30,0x30,0x30,0x00,0x00,0x30,0x30,0x30,0x00,0x00,0x00, - - 6, // 0x3B ';' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x30,0x30,0x30,0x00,0x00,0x38,0x30,0x30,0x30,0x60,0x60, - - 13, // 0x3C '<' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,0x00,0xC0,0x03,0x00,0x0C,0x00,0x30,0x00,0x30,0x00,0x0C,0x00,0x03,0x00,0x00,0xC0,0x00,0x20,0x00,0x00,0x00,0x00,0x00,0x00, - - 13, // 0x3D '=' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3F,0xE0,0x00,0x00,0x00,0x00,0x00,0x00,0x3F,0xE0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 13, // 0x3E '>' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,0x00,0x18,0x00,0x06,0x00,0x01,0x80,0x00,0x60,0x00,0x60,0x01,0x80,0x06,0x00,0x18,0x00,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 9, // 0x3F '?' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3E,0x00,0x63,0x00,0x03,0x00,0x03,0x00,0x06,0x00,0x0C,0x00,0x18,0x00,0x18,0x00,0x00,0x00,0x18,0x00,0x18,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 14, // 0x40 '@' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x07,0x80,0x18,0x60,0x20,0x10,0x27,0xD0,0x4C,0xC8,0x4C,0xC8,0x4C,0xC8,0x4C,0xC8,0x4C,0xC8,0x27,0xF0,0x20,0x00,0x18,0x00,0x07,0xC0,0x00,0x00, - - 12, // 0x41 'A' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x06,0x00,0x06,0x00,0x0F,0x00,0x0F,0x00,0x19,0x80,0x19,0x80,0x30,0xC0,0x3F,0xC0,0x30,0xC0,0x60,0x60,0x60,0x60,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x42 'B' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7F,0x00,0x61,0x80,0x61,0x80,0x61,0x80,0x63,0x00,0x7F,0x00,0x61,0x80,0x60,0xC0,0x60,0xC0,0x61,0x80,0x7F,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x43 'C' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0F,0x80,0x38,0xC0,0x30,0xC0,0x60,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x30,0xC0,0x38,0xC0,0x0F,0x80,0x00,0x00,0x00,0x00,0x00,0x00, - - 12, // 0x44 'D' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7F,0x00,0x61,0xC0,0x60,0xC0,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0xC0,0x61,0xC0,0x7F,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x45 'E' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7F,0x80,0x60,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x7F,0x80,0x60,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x7F,0x80,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x46 'F' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7F,0x80,0x60,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x7F,0x80,0x60,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 12, // 0x47 'G' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0F,0xC0,0x38,0x60,0x30,0x60,0x60,0x00,0x60,0x00,0x63,0xE0,0x60,0x60,0x60,0x60,0x30,0x60,0x38,0x60,0x0F,0xC0,0x00,0x00,0x00,0x00,0x00,0x00, - - 12, // 0x48 'H' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x7F,0xE0,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x49 'I' - 0x00,0x00,0x00,0x00,0x7E,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x7E,0x00,0x00,0x00, - - 8, // 0x4A 'J' - 0x00,0x00,0x00,0x00,0x3E,0x06,0x06,0x06,0x06,0x06,0x06,0x06,0x06,0x0C,0xF8,0x00,0x00,0x00, - - 12, // 0x4B 'K' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x60,0x60,0x60,0xC0,0x61,0x80,0x63,0x00,0x66,0x00,0x6C,0x00,0x7E,0x00,0x73,0x00,0x61,0x80,0x60,0xC0,0x60,0x60,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x4C 'L' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x7F,0x80,0x00,0x00,0x00,0x00,0x00,0x00, - - 14, // 0x4D 'M' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x60,0x38,0x70,0x38,0x70,0x78,0x58,0x58,0x58,0xD8,0x4C,0x98,0x4D,0x98,0x47,0x18,0x47,0x18,0x42,0x18,0x40,0x18,0x00,0x00,0x00,0x00,0x00,0x00, - - 12, // 0x4E 'N' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x70,0x20,0x70,0x20,0x58,0x20,0x4C,0x20,0x4C,0x20,0x46,0x20,0x43,0x20,0x43,0x20,0x41,0xA0,0x40,0xE0,0x40,0xE0,0x00,0x00,0x00,0x00,0x00,0x00, - - 13, // 0x4F 'O' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0F,0x80,0x38,0xE0,0x30,0x60,0x60,0x30,0x60,0x30,0x60,0x30,0x60,0x30,0x60,0x30,0x30,0x60,0x38,0xE0,0x0F,0x80,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x50 'P' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7F,0x00,0x61,0x80,0x60,0xC0,0x60,0xC0,0x60,0xC0,0x61,0x80,0x7F,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 13, // 0x51 'Q' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0F,0x80,0x38,0xE0,0x30,0x60,0x60,0x30,0x60,0x30,0x60,0x30,0x60,0x30,0x60,0x30,0x30,0x60,0x38,0xE0,0x0F,0x80,0x03,0x00,0x03,0x80,0x01,0xF0, - - 12, // 0x52 'R' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7F,0x00,0x61,0x80,0x60,0xC0,0x60,0xC0,0x60,0xC0,0x61,0x80,0x7F,0x00,0x61,0x80,0x60,0xC0,0x60,0x60,0x60,0x30,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x53 'S' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1F,0x80,0x30,0xC0,0x60,0xC0,0x60,0x00,0x7C,0x00,0x3F,0x80,0x03,0xC0,0x00,0xC0,0x60,0xC0,0x61,0x80,0x3F,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x54 'T' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7F,0x80,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 12, // 0x55 'U' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x30,0xC0,0x1F,0x80,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x56 'V' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x60,0xC0,0x60,0xC0,0x60,0xC0,0x31,0x80,0x31,0x80,0x31,0x80,0x1B,0x00,0x1B,0x00,0x1B,0x00,0x0E,0x00,0x0E,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 16, // 0x57 'W' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x61,0x86,0x61,0x86,0x63,0xC6,0x33,0xCC,0x32,0x4C,0x32,0x4C,0x1E,0x78,0x1C,0x38,0x1C,0x38,0x0C,0x30,0x0C,0x30,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x58 'X' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x60,0xC0,0x31,0x80,0x31,0x80,0x1B,0x00,0x0E,0x00,0x0E,0x00,0x0E,0x00,0x1B,0x00,0x31,0x80,0x31,0x80,0x60,0xC0,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x59 'Y' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xC0,0xC0,0x61,0x80,0x61,0x80,0x33,0x00,0x1E,0x00,0x1E,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x5A 'Z' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7F,0x80,0x01,0x80,0x03,0x00,0x06,0x00,0x06,0x00,0x0C,0x00,0x18,0x00,0x18,0x00,0x30,0x00,0x60,0x00,0x7F,0x80,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x5B '[' - 0x00,0x00,0x00,0x3E,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x3E, - - 10, // 0x5C '\' - 0x00,0x00,0x00,0x00,0x00,0x00,0x60,0x00,0x60,0x00,0x30,0x00,0x30,0x00,0x18,0x00,0x18,0x00,0x0C,0x00,0x0C,0x00,0x06,0x00,0x06,0x00,0x03,0x00,0x03,0x00,0x01,0x80,0x01,0x80,0x00,0x00, - - 8, // 0x5D ']' - 0x00,0x00,0x00,0x7C,0x0C,0x0C,0x0C,0x0C,0x0C,0x0C,0x0C,0x0C,0x0C,0x0C,0x0C,0x0C,0x0C,0x7C, - - 13, // 0x5E '^' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x06,0x00,0x0F,0x00,0x19,0x80,0x30,0xC0,0x60,0x60,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x5F '_' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xFF,0xE0,0x00,0x00, - - 11, // 0x60 '`' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x18,0x00,0x0C,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x61 'a' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3F,0x00,0x01,0x80,0x01,0x80,0x3F,0x80,0x61,0x80,0x61,0x80,0x63,0x80,0x3D,0x80,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x62 'b' - 0x00,0x00,0x00,0x00,0x00,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x6E,0x00,0x73,0x00,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x63,0x00,0x7E,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 8, // 0x63 'c' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1E,0x33,0x60,0x60,0x60,0x60,0x33,0x1E,0x00,0x00,0x00, - - 10, // 0x64 'd' - 0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x80,0x01,0x80,0x01,0x80,0x01,0x80,0x1F,0x80,0x31,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x33,0x80,0x1D,0x80,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x65 'e' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1E,0x00,0x33,0x00,0x61,0x80,0x7F,0x80,0x60,0x00,0x60,0x00,0x31,0x80,0x1F,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 6, // 0x66 'f' - 0x00,0x00,0x00,0x1C,0x30,0x30,0x30,0x7C,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x00,0x00,0x00, - - 10, // 0x67 'g' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1F,0x80,0x31,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x33,0x80,0x1D,0x80,0x01,0x80,0x03,0x00,0x3E,0x00, - - 10, // 0x68 'h' - 0x00,0x00,0x00,0x00,0x00,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x6F,0x00,0x71,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x00,0x00,0x00,0x00,0x00,0x00, - - 4, // 0x69 'i' - 0x00,0x00,0x00,0x60,0x60,0x00,0x00,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x00,0x00,0x00, - - 6, // 0x6A 'j' - 0x00,0x00,0x00,0x18,0x18,0x00,0x00,0x78,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0xF0, - - 10, // 0x6B 'k' - 0x00,0x00,0x00,0x00,0x00,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x60,0x00,0x61,0x80,0x63,0x00,0x66,0x00,0x6C,0x00,0x7E,0x00,0x73,0x00,0x61,0x80,0x60,0xC0,0x00,0x00,0x00,0x00,0x00,0x00, - - 4, // 0x6C 'l' - 0x00,0x00,0x00,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x00,0x00,0x00, - - 16, // 0x6D 'm' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x6F,0x3C,0x71,0xC6,0x61,0x86,0x61,0x86,0x61,0x86,0x61,0x86,0x61,0x86,0x61,0x86,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x6E 'n' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x6F,0x00,0x71,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x6F 'o' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1E,0x00,0x33,0x00,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x33,0x00,0x1E,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x70 'p' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x6E,0x00,0x73,0x00,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x63,0x00,0x7E,0x00,0x60,0x00,0x60,0x00,0x60,0x00, - - 10, // 0x71 'q' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1F,0x80,0x31,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x33,0x80,0x1D,0x80,0x01,0x80,0x01,0x80,0x01,0x80, - - 7, // 0x72 'r' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x6E,0x7E,0x60,0x60,0x60,0x60,0x60,0x60,0x00,0x00,0x00, - - 9, // 0x73 's' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3E,0x00,0x61,0x00,0x60,0x00,0x7E,0x00,0x3F,0x00,0x03,0x00,0x43,0x00,0x3E,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 7, // 0x74 't' - 0x00,0x00,0x00,0x00,0x00,0x30,0x30,0x7E,0x30,0x30,0x30,0x30,0x30,0x30,0x1E,0x00,0x00,0x00, - - 10, // 0x75 'u' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x61,0x80,0x63,0x80,0x3D,0x80,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x76 'v' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x61,0x80,0x61,0x80,0x33,0x00,0x33,0x00,0x33,0x00,0x1E,0x00,0x1E,0x00,0x0C,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 14, // 0x77 'w' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x63,0x18,0x63,0x18,0x63,0x18,0x37,0xB0,0x34,0xB0,0x3C,0xF0,0x18,0x60,0x18,0x60,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x78 'x' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x61,0x80,0x33,0x00,0x33,0x00,0x1E,0x00,0x1E,0x00,0x33,0x00,0x33,0x00,0x61,0x80,0x00,0x00,0x00,0x00,0x00,0x00, - - 10, // 0x79 'y' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x61,0x80,0x61,0x80,0x33,0x00,0x33,0x00,0x33,0x00,0x1E,0x00,0x1E,0x00,0x0C,0x00,0x0C,0x00,0x18,0x00,0x18,0x00, - - 9, // 0x7A 'z' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7F,0x00,0x03,0x00,0x06,0x00,0x0C,0x00,0x18,0x00,0x30,0x00,0x60,0x00,0x7F,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 11, // 0x7B '{' - 0x00,0x00,0x00,0x00,0x00,0x00,0x07,0x80,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x18,0x00,0x70,0x00,0x18,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x0C,0x00,0x07,0x80, - - 8, // 0x7C '|' - 0x00,0x00,0x00,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18, - - 11, // 0x7D '}' - 0x00,0x00,0x00,0x00,0x00,0x00,0x3C,0x00,0x06,0x00,0x06,0x00,0x06,0x00,0x06,0x00,0x06,0x00,0x03,0x00,0x01,0xC0,0x03,0x00,0x06,0x00,0x06,0x00,0x06,0x00,0x06,0x00,0x06,0x00,0x3C,0x00, - - 13, // 0x7E '~' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x18,0x10,0x24,0x10,0x42,0x10,0x41,0x20,0x40,0xC0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - - 15, // 0x7F '' - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3F,0xF8,0x20,0x08,0x20,0x08,0x20,0x08,0x20,0x08,0x20,0x08,0x20,0x08,0x20,0x08,0x20,0x08,0x20,0x08,0x3F,0xF8,0x00,0x00,0x00,0x00,0x00,0x00, - - 0 - }; - -} - diff --git a/desmume/src/windows/agg/src/agg_gsv_text.cpp b/desmume/src/windows/agg/src/agg_gsv_text.cpp deleted file mode 100644 index bc54ef7cb..000000000 --- a/desmume/src/windows/agg/src/agg_gsv_text.cpp +++ /dev/null @@ -1,681 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#include -#include -#include "agg_gsv_text.h" -#include "agg_bounding_rect.h" - - - -namespace agg -{ - int8u gsv_default_font[] = - { - 0x40,0x00,0x6c,0x0f,0x15,0x00,0x0e,0x00,0xf9,0xff, - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - 0x0d,0x0a,0x0d,0x0a,0x46,0x6f,0x6e,0x74,0x20,0x28, - 0x63,0x29,0x20,0x4d,0x69,0x63,0x72,0x6f,0x50,0x72, - 0x6f,0x66,0x20,0x32,0x37,0x20,0x53,0x65,0x70,0x74, - 0x65,0x6d,0x62,0x2e,0x31,0x39,0x38,0x39,0x00,0x0d, - 0x0a,0x0d,0x0a,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, - 0x02,0x00,0x12,0x00,0x34,0x00,0x46,0x00,0x94,0x00, - 0xd0,0x00,0x2e,0x01,0x3e,0x01,0x64,0x01,0x8a,0x01, - 0x98,0x01,0xa2,0x01,0xb4,0x01,0xba,0x01,0xc6,0x01, - 0xcc,0x01,0xf0,0x01,0xfa,0x01,0x18,0x02,0x38,0x02, - 0x44,0x02,0x68,0x02,0x98,0x02,0xa2,0x02,0xde,0x02, - 0x0e,0x03,0x24,0x03,0x40,0x03,0x48,0x03,0x52,0x03, - 0x5a,0x03,0x82,0x03,0xec,0x03,0xfa,0x03,0x26,0x04, - 0x4c,0x04,0x6a,0x04,0x7c,0x04,0x8a,0x04,0xb6,0x04, - 0xc4,0x04,0xca,0x04,0xe0,0x04,0xee,0x04,0xf8,0x04, - 0x0a,0x05,0x18,0x05,0x44,0x05,0x5e,0x05,0x8e,0x05, - 0xac,0x05,0xd6,0x05,0xe0,0x05,0xf6,0x05,0x00,0x06, - 0x12,0x06,0x1c,0x06,0x28,0x06,0x36,0x06,0x48,0x06, - 0x4e,0x06,0x60,0x06,0x6e,0x06,0x74,0x06,0x84,0x06, - 0xa6,0x06,0xc8,0x06,0xe6,0x06,0x08,0x07,0x2c,0x07, - 0x3c,0x07,0x68,0x07,0x7c,0x07,0x8c,0x07,0xa2,0x07, - 0xb0,0x07,0xb6,0x07,0xd8,0x07,0xec,0x07,0x10,0x08, - 0x32,0x08,0x54,0x08,0x64,0x08,0x88,0x08,0x98,0x08, - 0xac,0x08,0xb6,0x08,0xc8,0x08,0xd2,0x08,0xe4,0x08, - 0xf2,0x08,0x3e,0x09,0x48,0x09,0x94,0x09,0xc2,0x09, - 0xc4,0x09,0xd0,0x09,0xe2,0x09,0x04,0x0a,0x0e,0x0a, - 0x26,0x0a,0x34,0x0a,0x4a,0x0a,0x66,0x0a,0x70,0x0a, - 0x7e,0x0a,0x8e,0x0a,0x9a,0x0a,0xa6,0x0a,0xb4,0x0a, - 0xd8,0x0a,0xe2,0x0a,0xf6,0x0a,0x18,0x0b,0x22,0x0b, - 0x32,0x0b,0x56,0x0b,0x60,0x0b,0x6e,0x0b,0x7c,0x0b, - 0x8a,0x0b,0x9c,0x0b,0x9e,0x0b,0xb2,0x0b,0xc2,0x0b, - 0xd8,0x0b,0xf4,0x0b,0x08,0x0c,0x30,0x0c,0x56,0x0c, - 0x72,0x0c,0x90,0x0c,0xb2,0x0c,0xce,0x0c,0xe2,0x0c, - 0xfe,0x0c,0x10,0x0d,0x26,0x0d,0x36,0x0d,0x42,0x0d, - 0x4e,0x0d,0x5c,0x0d,0x78,0x0d,0x8c,0x0d,0x8e,0x0d, - 0x90,0x0d,0x92,0x0d,0x94,0x0d,0x96,0x0d,0x98,0x0d, - 0x9a,0x0d,0x9c,0x0d,0x9e,0x0d,0xa0,0x0d,0xa2,0x0d, - 0xa4,0x0d,0xa6,0x0d,0xa8,0x0d,0xaa,0x0d,0xac,0x0d, - 0xae,0x0d,0xb0,0x0d,0xb2,0x0d,0xb4,0x0d,0xb6,0x0d, - 0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,0xfd,0x7f,0xfe,0x7e,0x00,0x7e,0x01,0x7e, - 0x01,0x7f,0x02,0x7f,0x06,0x7e,0x02,0x7f,0x02,0x7e, - 0xf2,0x89,0x02,0x7e,0x02,0x7f,0x06,0x7e,0x02,0x7f, - 0x01,0x7f,0x01,0x7e,0x00,0x7c,0xfe,0x7e,0xfd,0x7f, - 0xfc,0x00,0xfd,0x01,0xfe,0x02,0x00,0x01,0x01,0x01, - 0x01,0x7f,0xff,0x7f,0x10,0xfd,0x15,0x95,0xee,0x6b, - 0x05,0x95,0x02,0x7e,0x00,0x7e,0xff,0x7e,0xfe,0x7f, - 0xfe,0x00,0xfe,0x02,0x00,0x02,0x01,0x02,0x02,0x01, - 0x02,0x00,0x02,0x7f,0x03,0x7f,0x03,0x00,0x03,0x01, - 0x02,0x01,0xfc,0xf2,0xfe,0x7f,0xff,0x7e,0x00,0x7e, - 0x02,0x7e,0x02,0x00,0x02,0x01,0x01,0x02,0x00,0x02, - 0xfe,0x02,0xfe,0x00,0x07,0xf9,0x15,0x8d,0xff,0x7f, - 0x01,0x7f,0x01,0x01,0x00,0x01,0xff,0x01,0xff,0x00, - 0xff,0x7f,0xff,0x7e,0xfe,0x7b,0xfe,0x7d,0xfe,0x7e, - 0xfe,0x7f,0xfd,0x00,0xfd,0x01,0xff,0x02,0x00,0x03, - 0x01,0x02,0x06,0x04,0x02,0x02,0x01,0x02,0x00,0x02, - 0xff,0x02,0xfe,0x01,0xfe,0x7f,0xff,0x7e,0x00,0x7e, - 0x01,0x7d,0x02,0x7d,0x05,0x79,0x02,0x7e,0x03,0x7f, - 0x01,0x00,0x01,0x01,0x00,0x01,0xf1,0xfe,0xfe,0x01, - 0xff,0x02,0x00,0x03,0x01,0x02,0x02,0x02,0x00,0x86, - 0x01,0x7e,0x08,0x75,0x02,0x7e,0x02,0x7f,0x05,0x80, - 0x05,0x93,0xff,0x01,0x01,0x01,0x01,0x7f,0x00,0x7e, - 0xff,0x7e,0xff,0x7f,0x06,0xf1,0x0b,0x99,0xfe,0x7e, - 0xfe,0x7d,0xfe,0x7c,0xff,0x7b,0x00,0x7c,0x01,0x7b, - 0x02,0x7c,0x02,0x7d,0x02,0x7e,0xfe,0x9e,0xfe,0x7c, - 0xff,0x7d,0xff,0x7b,0x00,0x7c,0x01,0x7b,0x01,0x7d, - 0x02,0x7c,0x05,0x85,0x03,0x99,0x02,0x7e,0x02,0x7d, - 0x02,0x7c,0x01,0x7b,0x00,0x7c,0xff,0x7b,0xfe,0x7c, - 0xfe,0x7d,0xfe,0x7e,0x02,0x9e,0x02,0x7c,0x01,0x7d, - 0x01,0x7b,0x00,0x7c,0xff,0x7b,0xff,0x7d,0xfe,0x7c, - 0x09,0x85,0x08,0x95,0x00,0x74,0xfb,0x89,0x0a,0x7a, - 0x00,0x86,0xf6,0x7a,0x0d,0xf4,0x0d,0x92,0x00,0x6e, - 0xf7,0x89,0x12,0x00,0x04,0xf7,0x06,0x81,0xff,0x7f, - 0xff,0x01,0x01,0x01,0x01,0x7f,0x00,0x7e,0xff,0x7e, - 0xff,0x7f,0x06,0x84,0x04,0x89,0x12,0x00,0x04,0xf7, - 0x05,0x82,0xff,0x7f,0x01,0x7f,0x01,0x01,0xff,0x01, - 0x05,0xfe,0x00,0xfd,0x0e,0x18,0x00,0xeb,0x09,0x95, - 0xfd,0x7f,0xfe,0x7d,0xff,0x7b,0x00,0x7d,0x01,0x7b, - 0x02,0x7d,0x03,0x7f,0x02,0x00,0x03,0x01,0x02,0x03, - 0x01,0x05,0x00,0x03,0xff,0x05,0xfe,0x03,0xfd,0x01, - 0xfe,0x00,0x0b,0xeb,0x06,0x91,0x02,0x01,0x03,0x03, - 0x00,0x6b,0x09,0x80,0x04,0x90,0x00,0x01,0x01,0x02, - 0x01,0x01,0x02,0x01,0x04,0x00,0x02,0x7f,0x01,0x7f, - 0x01,0x7e,0x00,0x7e,0xff,0x7e,0xfe,0x7d,0xf6,0x76, - 0x0e,0x00,0x03,0x80,0x05,0x95,0x0b,0x00,0xfa,0x78, - 0x03,0x00,0x02,0x7f,0x01,0x7f,0x01,0x7d,0x00,0x7e, - 0xff,0x7d,0xfe,0x7e,0xfd,0x7f,0xfd,0x00,0xfd,0x01, - 0xff,0x01,0xff,0x02,0x11,0xfc,0x0d,0x95,0xf6,0x72, - 0x0f,0x00,0xfb,0x8e,0x00,0x6b,0x07,0x80,0x0f,0x95, - 0xf6,0x00,0xff,0x77,0x01,0x01,0x03,0x01,0x03,0x00, - 0x03,0x7f,0x02,0x7e,0x01,0x7d,0x00,0x7e,0xff,0x7d, - 0xfe,0x7e,0xfd,0x7f,0xfd,0x00,0xfd,0x01,0xff,0x01, - 0xff,0x02,0x11,0xfc,0x10,0x92,0xff,0x02,0xfd,0x01, - 0xfe,0x00,0xfd,0x7f,0xfe,0x7d,0xff,0x7b,0x00,0x7b, - 0x01,0x7c,0x02,0x7e,0x03,0x7f,0x01,0x00,0x03,0x01, - 0x02,0x02,0x01,0x03,0x00,0x01,0xff,0x03,0xfe,0x02, - 0xfd,0x01,0xff,0x00,0xfd,0x7f,0xfe,0x7e,0xff,0x7d, - 0x10,0xf9,0x11,0x95,0xf6,0x6b,0xfc,0x95,0x0e,0x00, - 0x03,0xeb,0x08,0x95,0xfd,0x7f,0xff,0x7e,0x00,0x7e, - 0x01,0x7e,0x02,0x7f,0x04,0x7f,0x03,0x7f,0x02,0x7e, - 0x01,0x7e,0x00,0x7d,0xff,0x7e,0xff,0x7f,0xfd,0x7f, - 0xfc,0x00,0xfd,0x01,0xff,0x01,0xff,0x02,0x00,0x03, - 0x01,0x02,0x02,0x02,0x03,0x01,0x04,0x01,0x02,0x01, - 0x01,0x02,0x00,0x02,0xff,0x02,0xfd,0x01,0xfc,0x00, - 0x0c,0xeb,0x10,0x8e,0xff,0x7d,0xfe,0x7e,0xfd,0x7f, - 0xff,0x00,0xfd,0x01,0xfe,0x02,0xff,0x03,0x00,0x01, - 0x01,0x03,0x02,0x02,0x03,0x01,0x01,0x00,0x03,0x7f, - 0x02,0x7e,0x01,0x7c,0x00,0x7b,0xff,0x7b,0xfe,0x7d, - 0xfd,0x7f,0xfe,0x00,0xfd,0x01,0xff,0x02,0x10,0xfd, - 0x05,0x8e,0xff,0x7f,0x01,0x7f,0x01,0x01,0xff,0x01, - 0x00,0xf4,0xff,0x7f,0x01,0x7f,0x01,0x01,0xff,0x01, - 0x05,0xfe,0x05,0x8e,0xff,0x7f,0x01,0x7f,0x01,0x01, - 0xff,0x01,0x01,0xf3,0xff,0x7f,0xff,0x01,0x01,0x01, - 0x01,0x7f,0x00,0x7e,0xff,0x7e,0xff,0x7f,0x06,0x84, - 0x14,0x92,0xf0,0x77,0x10,0x77,0x04,0x80,0x04,0x8c, - 0x12,0x00,0xee,0xfa,0x12,0x00,0x04,0xfa,0x04,0x92, - 0x10,0x77,0xf0,0x77,0x14,0x80,0x03,0x90,0x00,0x01, - 0x01,0x02,0x01,0x01,0x02,0x01,0x04,0x00,0x02,0x7f, - 0x01,0x7f,0x01,0x7e,0x00,0x7e,0xff,0x7e,0xff,0x7f, - 0xfc,0x7e,0x00,0x7d,0x00,0xfb,0xff,0x7f,0x01,0x7f, - 0x01,0x01,0xff,0x01,0x09,0xfe,0x12,0x8d,0xff,0x02, - 0xfe,0x01,0xfd,0x00,0xfe,0x7f,0xff,0x7f,0xff,0x7d, - 0x00,0x7d,0x01,0x7e,0x02,0x7f,0x03,0x00,0x02,0x01, - 0x01,0x02,0xfb,0x88,0xfe,0x7e,0xff,0x7d,0x00,0x7d, - 0x01,0x7e,0x01,0x7f,0x07,0x8b,0xff,0x78,0x00,0x7e, - 0x02,0x7f,0x02,0x00,0x02,0x02,0x01,0x03,0x00,0x02, - 0xff,0x03,0xff,0x02,0xfe,0x02,0xfe,0x01,0xfd,0x01, - 0xfd,0x00,0xfd,0x7f,0xfe,0x7f,0xfe,0x7e,0xff,0x7e, - 0xff,0x7d,0x00,0x7d,0x01,0x7d,0x01,0x7e,0x02,0x7e, - 0x02,0x7f,0x03,0x7f,0x03,0x00,0x03,0x01,0x02,0x01, - 0x01,0x01,0xfe,0x8d,0xff,0x78,0x00,0x7e,0x01,0x7f, - 0x08,0xfb,0x09,0x95,0xf8,0x6b,0x08,0x95,0x08,0x6b, - 0xf3,0x87,0x0a,0x00,0x04,0xf9,0x04,0x95,0x00,0x6b, - 0x00,0x95,0x09,0x00,0x03,0x7f,0x01,0x7f,0x01,0x7e, - 0x00,0x7e,0xff,0x7e,0xff,0x7f,0xfd,0x7f,0xf7,0x80, - 0x09,0x00,0x03,0x7f,0x01,0x7f,0x01,0x7e,0x00,0x7d, - 0xff,0x7e,0xff,0x7f,0xfd,0x7f,0xf7,0x00,0x11,0x80, - 0x12,0x90,0xff,0x02,0xfe,0x02,0xfe,0x01,0xfc,0x00, - 0xfe,0x7f,0xfe,0x7e,0xff,0x7e,0xff,0x7d,0x00,0x7b, - 0x01,0x7d,0x01,0x7e,0x02,0x7e,0x02,0x7f,0x04,0x00, - 0x02,0x01,0x02,0x02,0x01,0x02,0x03,0xfb,0x04,0x95, - 0x00,0x6b,0x00,0x95,0x07,0x00,0x03,0x7f,0x02,0x7e, - 0x01,0x7e,0x01,0x7d,0x00,0x7b,0xff,0x7d,0xff,0x7e, - 0xfe,0x7e,0xfd,0x7f,0xf9,0x00,0x11,0x80,0x04,0x95, - 0x00,0x6b,0x00,0x95,0x0d,0x00,0xf3,0xf6,0x08,0x00, - 0xf8,0xf5,0x0d,0x00,0x02,0x80,0x04,0x95,0x00,0x6b, - 0x00,0x95,0x0d,0x00,0xf3,0xf6,0x08,0x00,0x06,0xf5, - 0x12,0x90,0xff,0x02,0xfe,0x02,0xfe,0x01,0xfc,0x00, - 0xfe,0x7f,0xfe,0x7e,0xff,0x7e,0xff,0x7d,0x00,0x7b, - 0x01,0x7d,0x01,0x7e,0x02,0x7e,0x02,0x7f,0x04,0x00, - 0x02,0x01,0x02,0x02,0x01,0x02,0x00,0x03,0xfb,0x80, - 0x05,0x00,0x03,0xf8,0x04,0x95,0x00,0x6b,0x0e,0x95, - 0x00,0x6b,0xf2,0x8b,0x0e,0x00,0x04,0xf5,0x04,0x95, - 0x00,0x6b,0x04,0x80,0x0c,0x95,0x00,0x70,0xff,0x7d, - 0xff,0x7f,0xfe,0x7f,0xfe,0x00,0xfe,0x01,0xff,0x01, - 0xff,0x03,0x00,0x02,0x0e,0xf9,0x04,0x95,0x00,0x6b, - 0x0e,0x95,0xf2,0x72,0x05,0x85,0x09,0x74,0x03,0x80, - 0x04,0x95,0x00,0x6b,0x00,0x80,0x0c,0x00,0x01,0x80, - 0x04,0x95,0x00,0x6b,0x00,0x95,0x08,0x6b,0x08,0x95, - 0xf8,0x6b,0x08,0x95,0x00,0x6b,0x04,0x80,0x04,0x95, - 0x00,0x6b,0x00,0x95,0x0e,0x6b,0x00,0x95,0x00,0x6b, - 0x04,0x80,0x09,0x95,0xfe,0x7f,0xfe,0x7e,0xff,0x7e, - 0xff,0x7d,0x00,0x7b,0x01,0x7d,0x01,0x7e,0x02,0x7e, - 0x02,0x7f,0x04,0x00,0x02,0x01,0x02,0x02,0x01,0x02, - 0x01,0x03,0x00,0x05,0xff,0x03,0xff,0x02,0xfe,0x02, - 0xfe,0x01,0xfc,0x00,0x0d,0xeb,0x04,0x95,0x00,0x6b, - 0x00,0x95,0x09,0x00,0x03,0x7f,0x01,0x7f,0x01,0x7e, - 0x00,0x7d,0xff,0x7e,0xff,0x7f,0xfd,0x7f,0xf7,0x00, - 0x11,0xf6,0x09,0x95,0xfe,0x7f,0xfe,0x7e,0xff,0x7e, - 0xff,0x7d,0x00,0x7b,0x01,0x7d,0x01,0x7e,0x02,0x7e, - 0x02,0x7f,0x04,0x00,0x02,0x01,0x02,0x02,0x01,0x02, - 0x01,0x03,0x00,0x05,0xff,0x03,0xff,0x02,0xfe,0x02, - 0xfe,0x01,0xfc,0x00,0x03,0xef,0x06,0x7a,0x04,0x82, - 0x04,0x95,0x00,0x6b,0x00,0x95,0x09,0x00,0x03,0x7f, - 0x01,0x7f,0x01,0x7e,0x00,0x7e,0xff,0x7e,0xff,0x7f, - 0xfd,0x7f,0xf7,0x00,0x07,0x80,0x07,0x75,0x03,0x80, - 0x11,0x92,0xfe,0x02,0xfd,0x01,0xfc,0x00,0xfd,0x7f, - 0xfe,0x7e,0x00,0x7e,0x01,0x7e,0x01,0x7f,0x02,0x7f, - 0x06,0x7e,0x02,0x7f,0x01,0x7f,0x01,0x7e,0x00,0x7d, - 0xfe,0x7e,0xfd,0x7f,0xfc,0x00,0xfd,0x01,0xfe,0x02, - 0x11,0xfd,0x08,0x95,0x00,0x6b,0xf9,0x95,0x0e,0x00, - 0x01,0xeb,0x04,0x95,0x00,0x71,0x01,0x7d,0x02,0x7e, - 0x03,0x7f,0x02,0x00,0x03,0x01,0x02,0x02,0x01,0x03, - 0x00,0x0f,0x04,0xeb,0x01,0x95,0x08,0x6b,0x08,0x95, - 0xf8,0x6b,0x09,0x80,0x02,0x95,0x05,0x6b,0x05,0x95, - 0xfb,0x6b,0x05,0x95,0x05,0x6b,0x05,0x95,0xfb,0x6b, - 0x07,0x80,0x03,0x95,0x0e,0x6b,0x00,0x95,0xf2,0x6b, - 0x11,0x80,0x01,0x95,0x08,0x76,0x00,0x75,0x08,0x95, - 0xf8,0x76,0x09,0xf5,0x11,0x95,0xf2,0x6b,0x00,0x95, - 0x0e,0x00,0xf2,0xeb,0x0e,0x00,0x03,0x80,0x03,0x93, - 0x00,0x6c,0x01,0x94,0x00,0x6c,0xff,0x94,0x05,0x00, - 0xfb,0xec,0x05,0x00,0x02,0x81,0x00,0x95,0x0e,0x68, - 0x00,0x83,0x06,0x93,0x00,0x6c,0x01,0x94,0x00,0x6c, - 0xfb,0x94,0x05,0x00,0xfb,0xec,0x05,0x00,0x03,0x81, - 0x03,0x87,0x08,0x05,0x08,0x7b,0xf0,0x80,0x08,0x04, - 0x08,0x7c,0x03,0xf9,0x01,0x80,0x10,0x00,0x01,0x80, - 0x06,0x95,0xff,0x7f,0xff,0x7e,0x00,0x7e,0x01,0x7f, - 0x01,0x01,0xff,0x01,0x05,0xef,0x0f,0x8e,0x00,0x72, - 0x00,0x8b,0xfe,0x02,0xfe,0x01,0xfd,0x00,0xfe,0x7f, - 0xfe,0x7e,0xff,0x7d,0x00,0x7e,0x01,0x7d,0x02,0x7e, - 0x02,0x7f,0x03,0x00,0x02,0x01,0x02,0x02,0x04,0xfd, - 0x04,0x95,0x00,0x6b,0x00,0x8b,0x02,0x02,0x02,0x01, - 0x03,0x00,0x02,0x7f,0x02,0x7e,0x01,0x7d,0x00,0x7e, - 0xff,0x7d,0xfe,0x7e,0xfe,0x7f,0xfd,0x00,0xfe,0x01, - 0xfe,0x02,0x0f,0xfd,0x0f,0x8b,0xfe,0x02,0xfe,0x01, - 0xfd,0x00,0xfe,0x7f,0xfe,0x7e,0xff,0x7d,0x00,0x7e, - 0x01,0x7d,0x02,0x7e,0x02,0x7f,0x03,0x00,0x02,0x01, - 0x02,0x02,0x03,0xfd,0x0f,0x95,0x00,0x6b,0x00,0x8b, - 0xfe,0x02,0xfe,0x01,0xfd,0x00,0xfe,0x7f,0xfe,0x7e, - 0xff,0x7d,0x00,0x7e,0x01,0x7d,0x02,0x7e,0x02,0x7f, - 0x03,0x00,0x02,0x01,0x02,0x02,0x04,0xfd,0x03,0x88, - 0x0c,0x00,0x00,0x02,0xff,0x02,0xff,0x01,0xfe,0x01, - 0xfd,0x00,0xfe,0x7f,0xfe,0x7e,0xff,0x7d,0x00,0x7e, - 0x01,0x7d,0x02,0x7e,0x02,0x7f,0x03,0x00,0x02,0x01, - 0x02,0x02,0x03,0xfd,0x0a,0x95,0xfe,0x00,0xfe,0x7f, - 0xff,0x7d,0x00,0x6f,0xfd,0x8e,0x07,0x00,0x03,0xf2, - 0x0f,0x8e,0x00,0x70,0xff,0x7d,0xff,0x7f,0xfe,0x7f, - 0xfd,0x00,0xfe,0x01,0x09,0x91,0xfe,0x02,0xfe,0x01, - 0xfd,0x00,0xfe,0x7f,0xfe,0x7e,0xff,0x7d,0x00,0x7e, - 0x01,0x7d,0x02,0x7e,0x02,0x7f,0x03,0x00,0x02,0x01, - 0x02,0x02,0x04,0xfd,0x04,0x95,0x00,0x6b,0x00,0x8a, - 0x03,0x03,0x02,0x01,0x03,0x00,0x02,0x7f,0x01,0x7d, - 0x00,0x76,0x04,0x80,0x03,0x95,0x01,0x7f,0x01,0x01, - 0xff,0x01,0xff,0x7f,0x01,0xf9,0x00,0x72,0x04,0x80, - 0x05,0x95,0x01,0x7f,0x01,0x01,0xff,0x01,0xff,0x7f, - 0x01,0xf9,0x00,0x6f,0xff,0x7d,0xfe,0x7f,0xfe,0x00, - 0x09,0x87,0x04,0x95,0x00,0x6b,0x0a,0x8e,0xf6,0x76, - 0x04,0x84,0x07,0x78,0x02,0x80,0x04,0x95,0x00,0x6b, - 0x04,0x80,0x04,0x8e,0x00,0x72,0x00,0x8a,0x03,0x03, - 0x02,0x01,0x03,0x00,0x02,0x7f,0x01,0x7d,0x00,0x76, - 0x00,0x8a,0x03,0x03,0x02,0x01,0x03,0x00,0x02,0x7f, - 0x01,0x7d,0x00,0x76,0x04,0x80,0x04,0x8e,0x00,0x72, - 0x00,0x8a,0x03,0x03,0x02,0x01,0x03,0x00,0x02,0x7f, - 0x01,0x7d,0x00,0x76,0x04,0x80,0x08,0x8e,0xfe,0x7f, - 0xfe,0x7e,0xff,0x7d,0x00,0x7e,0x01,0x7d,0x02,0x7e, - 0x02,0x7f,0x03,0x00,0x02,0x01,0x02,0x02,0x01,0x03, - 0x00,0x02,0xff,0x03,0xfe,0x02,0xfe,0x01,0xfd,0x00, - 0x0b,0xf2,0x04,0x8e,0x00,0x6b,0x00,0x92,0x02,0x02, - 0x02,0x01,0x03,0x00,0x02,0x7f,0x02,0x7e,0x01,0x7d, - 0x00,0x7e,0xff,0x7d,0xfe,0x7e,0xfe,0x7f,0xfd,0x00, - 0xfe,0x01,0xfe,0x02,0x0f,0xfd,0x0f,0x8e,0x00,0x6b, - 0x00,0x92,0xfe,0x02,0xfe,0x01,0xfd,0x00,0xfe,0x7f, - 0xfe,0x7e,0xff,0x7d,0x00,0x7e,0x01,0x7d,0x02,0x7e, - 0x02,0x7f,0x03,0x00,0x02,0x01,0x02,0x02,0x04,0xfd, - 0x04,0x8e,0x00,0x72,0x00,0x88,0x01,0x03,0x02,0x02, - 0x02,0x01,0x03,0x00,0x01,0xf2,0x0e,0x8b,0xff,0x02, - 0xfd,0x01,0xfd,0x00,0xfd,0x7f,0xff,0x7e,0x01,0x7e, - 0x02,0x7f,0x05,0x7f,0x02,0x7f,0x01,0x7e,0x00,0x7f, - 0xff,0x7e,0xfd,0x7f,0xfd,0x00,0xfd,0x01,0xff,0x02, - 0x0e,0xfd,0x05,0x95,0x00,0x6f,0x01,0x7d,0x02,0x7f, - 0x02,0x00,0xf8,0x8e,0x07,0x00,0x03,0xf2,0x04,0x8e, - 0x00,0x76,0x01,0x7d,0x02,0x7f,0x03,0x00,0x02,0x01, - 0x03,0x03,0x00,0x8a,0x00,0x72,0x04,0x80,0x02,0x8e, - 0x06,0x72,0x06,0x8e,0xfa,0x72,0x08,0x80,0x03,0x8e, - 0x04,0x72,0x04,0x8e,0xfc,0x72,0x04,0x8e,0x04,0x72, - 0x04,0x8e,0xfc,0x72,0x07,0x80,0x03,0x8e,0x0b,0x72, - 0x00,0x8e,0xf5,0x72,0x0e,0x80,0x02,0x8e,0x06,0x72, - 0x06,0x8e,0xfa,0x72,0xfe,0x7c,0xfe,0x7e,0xfe,0x7f, - 0xff,0x00,0x0f,0x87,0x0e,0x8e,0xf5,0x72,0x00,0x8e, - 0x0b,0x00,0xf5,0xf2,0x0b,0x00,0x03,0x80,0x09,0x99, - 0xfe,0x7f,0xff,0x7f,0xff,0x7e,0x00,0x7e,0x01,0x7e, - 0x01,0x7f,0x01,0x7e,0x00,0x7e,0xfe,0x7e,0x01,0x8e, - 0xff,0x7e,0x00,0x7e,0x01,0x7e,0x01,0x7f,0x01,0x7e, - 0x00,0x7e,0xff,0x7e,0xfc,0x7e,0x04,0x7e,0x01,0x7e, - 0x00,0x7e,0xff,0x7e,0xff,0x7f,0xff,0x7e,0x00,0x7e, - 0x01,0x7e,0xff,0x8e,0x02,0x7e,0x00,0x7e,0xff,0x7e, - 0xff,0x7f,0xff,0x7e,0x00,0x7e,0x01,0x7e,0x01,0x7f, - 0x02,0x7f,0x05,0x87,0x04,0x95,0x00,0x77,0x00,0xfd, - 0x00,0x77,0x04,0x80,0x05,0x99,0x02,0x7f,0x01,0x7f, - 0x01,0x7e,0x00,0x7e,0xff,0x7e,0xff,0x7f,0xff,0x7e, - 0x00,0x7e,0x02,0x7e,0xff,0x8e,0x01,0x7e,0x00,0x7e, - 0xff,0x7e,0xff,0x7f,0xff,0x7e,0x00,0x7e,0x01,0x7e, - 0x04,0x7e,0xfc,0x7e,0xff,0x7e,0x00,0x7e,0x01,0x7e, - 0x01,0x7f,0x01,0x7e,0x00,0x7e,0xff,0x7e,0x01,0x8e, - 0xfe,0x7e,0x00,0x7e,0x01,0x7e,0x01,0x7f,0x01,0x7e, - 0x00,0x7e,0xff,0x7e,0xff,0x7f,0xfe,0x7f,0x09,0x87, - 0x03,0x86,0x00,0x02,0x01,0x03,0x02,0x01,0x02,0x00, - 0x02,0x7f,0x04,0x7d,0x02,0x7f,0x02,0x00,0x02,0x01, - 0x01,0x02,0xee,0xfe,0x01,0x02,0x02,0x01,0x02,0x00, - 0x02,0x7f,0x04,0x7d,0x02,0x7f,0x02,0x00,0x02,0x01, - 0x01,0x03,0x00,0x02,0x03,0xf4,0x10,0x80,0x03,0x80, - 0x07,0x15,0x08,0x6b,0xfe,0x85,0xf5,0x00,0x10,0xfb, - 0x0d,0x95,0xf6,0x00,0x00,0x6b,0x0a,0x00,0x02,0x02, - 0x00,0x08,0xfe,0x02,0xf6,0x00,0x0e,0xf4,0x03,0x80, - 0x00,0x15,0x0a,0x00,0x02,0x7e,0x00,0x7e,0x00,0x7d, - 0x00,0x7e,0xfe,0x7f,0xf6,0x00,0x0a,0x80,0x02,0x7e, - 0x01,0x7e,0x00,0x7d,0xff,0x7d,0xfe,0x7f,0xf6,0x00, - 0x10,0x80,0x03,0x80,0x00,0x15,0x0c,0x00,0xff,0x7e, - 0x03,0xed,0x03,0xfd,0x00,0x03,0x02,0x00,0x00,0x12, - 0x02,0x03,0x0a,0x00,0x00,0x6b,0x02,0x00,0x00,0x7d, - 0xfe,0x83,0xf4,0x00,0x11,0x80,0x0f,0x80,0xf4,0x00, - 0x00,0x15,0x0c,0x00,0xff,0xf6,0xf5,0x00,0x0f,0xf5, - 0x04,0x95,0x07,0x76,0x00,0x0a,0x07,0x80,0xf9,0x76, - 0x00,0x75,0xf8,0x80,0x07,0x0c,0x09,0xf4,0xf9,0x0c, - 0x09,0xf4,0x03,0x92,0x02,0x03,0x07,0x00,0x03,0x7d, - 0x00,0x7b,0xfc,0x7e,0x04,0x7d,0x00,0x7a,0xfd,0x7e, - 0xf9,0x00,0xfe,0x02,0x06,0x89,0x02,0x00,0x06,0xf5, - 0x03,0x95,0x00,0x6b,0x0c,0x15,0x00,0x6b,0x02,0x80, - 0x03,0x95,0x00,0x6b,0x0c,0x15,0x00,0x6b,0xf8,0x96, - 0x03,0x00,0x07,0xea,0x03,0x80,0x00,0x15,0x0c,0x80, - 0xf7,0x76,0xfd,0x00,0x03,0x80,0x0a,0x75,0x03,0x80, - 0x03,0x80,0x07,0x13,0x02,0x02,0x03,0x00,0x00,0x6b, - 0x02,0x80,0x03,0x80,0x00,0x15,0x09,0x6b,0x09,0x15, - 0x00,0x6b,0x03,0x80,0x03,0x80,0x00,0x15,0x00,0xf6, - 0x0d,0x00,0x00,0x8a,0x00,0x6b,0x03,0x80,0x07,0x80, - 0xfd,0x00,0xff,0x03,0x00,0x04,0x00,0x07,0x00,0x04, - 0x01,0x02,0x03,0x01,0x06,0x00,0x03,0x7f,0x01,0x7e, - 0x01,0x7c,0x00,0x79,0xff,0x7c,0xff,0x7d,0xfd,0x00, - 0xfa,0x00,0x0e,0x80,0x03,0x80,0x00,0x15,0x0c,0x00, - 0x00,0x6b,0x02,0x80,0x03,0x80,0x00,0x15,0x0a,0x00, - 0x02,0x7f,0x01,0x7d,0x00,0x7b,0xff,0x7e,0xfe,0x7f, - 0xf6,0x00,0x10,0xf7,0x11,0x8f,0xff,0x03,0xff,0x02, - 0xfe,0x01,0xfa,0x00,0xfd,0x7f,0xff,0x7e,0x00,0x7c, - 0x00,0x79,0x00,0x7b,0x01,0x7e,0x03,0x00,0x06,0x00, - 0x02,0x00,0x01,0x03,0x01,0x02,0x03,0xfb,0x03,0x95, - 0x0c,0x00,0xfa,0x80,0x00,0x6b,0x09,0x80,0x03,0x95, - 0x00,0x77,0x06,0x7a,0x06,0x06,0x00,0x09,0xfa,0xf1, - 0xfa,0x7a,0x0e,0x80,0x03,0x87,0x00,0x0b,0x02,0x02, - 0x03,0x00,0x02,0x7e,0x01,0x02,0x04,0x00,0x02,0x7e, - 0x00,0x75,0xfe,0x7e,0xfc,0x00,0xff,0x01,0xfe,0x7f, - 0xfd,0x00,0xfe,0x02,0x07,0x8e,0x00,0x6b,0x09,0x80, - 0x03,0x80,0x0e,0x15,0xf2,0x80,0x0e,0x6b,0x03,0x80, - 0x03,0x95,0x00,0x6b,0x0e,0x00,0x00,0x7d,0xfe,0x98, - 0x00,0x6b,0x05,0x80,0x03,0x95,0x00,0x75,0x02,0x7d, - 0x0a,0x00,0x00,0x8e,0x00,0x6b,0x02,0x80,0x03,0x95, - 0x00,0x6b,0x10,0x00,0x00,0x15,0xf8,0x80,0x00,0x6b, - 0x0a,0x80,0x03,0x95,0x00,0x6b,0x10,0x00,0x00,0x15, - 0xf8,0x80,0x00,0x6b,0x0a,0x00,0x00,0x7d,0x02,0x83, - 0x10,0x80,0x03,0x95,0x00,0x6b,0x09,0x00,0x03,0x02, - 0x00,0x08,0xfd,0x02,0xf7,0x00,0x0e,0x89,0x00,0x6b, - 0x03,0x80,0x03,0x95,0x00,0x6b,0x09,0x00,0x03,0x02, - 0x00,0x08,0xfd,0x02,0xf7,0x00,0x0e,0xf4,0x03,0x92, - 0x02,0x03,0x07,0x00,0x03,0x7d,0x00,0x70,0xfd,0x7e, - 0xf9,0x00,0xfe,0x02,0x03,0x89,0x09,0x00,0x02,0xf5, - 0x03,0x80,0x00,0x15,0x00,0xf5,0x07,0x00,0x00,0x08, - 0x02,0x03,0x06,0x00,0x02,0x7d,0x00,0x70,0xfe,0x7e, - 0xfa,0x00,0xfe,0x02,0x00,0x08,0x0c,0xf6,0x0f,0x80, - 0x00,0x15,0xf6,0x00,0xfe,0x7d,0x00,0x79,0x02,0x7e, - 0x0a,0x00,0xf4,0xf7,0x07,0x09,0x07,0xf7,0x03,0x8c, - 0x01,0x02,0x01,0x01,0x05,0x00,0x02,0x7f,0x01,0x7e, - 0x00,0x74,0x00,0x86,0xff,0x01,0xfe,0x01,0xfb,0x00, - 0xff,0x7f,0xff,0x7f,0x00,0x7c,0x01,0x7e,0x01,0x00, - 0x05,0x00,0x02,0x00,0x01,0x02,0x03,0xfe,0x04,0x8e, - 0x02,0x01,0x04,0x00,0x02,0x7f,0x01,0x7e,0x00,0x77, - 0xff,0x7e,0xfe,0x7f,0xfc,0x00,0xfe,0x01,0xff,0x02, - 0x00,0x09,0x01,0x02,0x02,0x02,0x03,0x01,0x02,0x01, - 0x01,0x01,0x01,0x02,0x02,0xeb,0x03,0x80,0x00,0x15, - 0x03,0x00,0x02,0x7e,0x00,0x7b,0xfe,0x7e,0xfd,0x00, - 0x03,0x80,0x04,0x00,0x03,0x7e,0x00,0x78,0xfd,0x7e, - 0xf9,0x00,0x0c,0x80,0x03,0x8c,0x02,0x02,0x02,0x01, - 0x03,0x00,0x02,0x7f,0x01,0x7d,0xfe,0x7e,0xf9,0x7d, - 0xff,0x7e,0x00,0x7d,0x03,0x7f,0x02,0x00,0x03,0x01, - 0x02,0x01,0x02,0xfe,0x0d,0x8c,0xff,0x02,0xfe,0x01, - 0xfc,0x00,0xfe,0x7f,0xff,0x7e,0x00,0x77,0x01,0x7e, - 0x02,0x7f,0x04,0x00,0x02,0x01,0x01,0x02,0x00,0x0f, - 0xff,0x02,0xfe,0x01,0xf9,0x00,0x0c,0xeb,0x03,0x88, - 0x0a,0x00,0x00,0x02,0x00,0x03,0xfe,0x02,0xfa,0x00, - 0xff,0x7e,0xff,0x7d,0x00,0x7b,0x01,0x7c,0x01,0x7f, - 0x06,0x00,0x02,0x02,0x03,0xfe,0x03,0x8f,0x06,0x77, - 0x06,0x09,0xfa,0x80,0x00,0x71,0xff,0x87,0xfb,0x79, - 0x07,0x87,0x05,0x79,0x02,0x80,0x03,0x8d,0x02,0x02, - 0x06,0x00,0x02,0x7e,0x00,0x7d,0xfc,0x7d,0x04,0x7e, - 0x00,0x7d,0xfe,0x7e,0xfa,0x00,0xfe,0x02,0x04,0x85, - 0x02,0x00,0x06,0xf9,0x03,0x8f,0x00,0x73,0x01,0x7e, - 0x07,0x00,0x02,0x02,0x00,0x0d,0x00,0xf3,0x01,0x7e, - 0x03,0x80,0x03,0x8f,0x00,0x73,0x01,0x7e,0x07,0x00, - 0x02,0x02,0x00,0x0d,0x00,0xf3,0x01,0x7e,0xf8,0x90, - 0x03,0x00,0x08,0xf0,0x03,0x80,0x00,0x15,0x00,0xf3, - 0x02,0x00,0x06,0x07,0xfa,0xf9,0x07,0x78,0x03,0x80, - 0x03,0x80,0x04,0x0c,0x02,0x03,0x04,0x00,0x00,0x71, - 0x02,0x80,0x03,0x80,0x00,0x0f,0x06,0x77,0x06,0x09, - 0x00,0x71,0x02,0x80,0x03,0x80,0x00,0x0f,0x0a,0xf1, - 0x00,0x0f,0xf6,0xf8,0x0a,0x00,0x02,0xf9,0x05,0x80, - 0xff,0x01,0xff,0x04,0x00,0x05,0x01,0x03,0x01,0x02, - 0x06,0x00,0x02,0x7e,0x00,0x7d,0x00,0x7b,0x00,0x7c, - 0xfe,0x7f,0xfa,0x00,0x0b,0x80,0x03,0x80,0x00,0x0f, - 0x00,0xfb,0x01,0x03,0x01,0x02,0x05,0x00,0x02,0x7e, - 0x01,0x7d,0x00,0x76,0x03,0x80,0x10,0x80,0x10,0x80, - 0x10,0x80,0x10,0x80,0x10,0x80,0x10,0x80,0x10,0x80, - 0x10,0x80,0x10,0x80,0x10,0x80,0x10,0x80,0x10,0x80, - 0x10,0x80,0x10,0x80,0x10,0x80,0x10,0x80,0x10,0x80, - 0x10,0x80,0x10,0x80,0x10,0x80,0x10,0x80,0x10,0x80, - 0x10,0x80,0x10,0x80,0x10,0x80,0x10,0x80,0x10,0x80, - 0x10,0x80,0x10,0x80,0x10,0x80,0x10,0x80,0x10,0x80, - 0x10,0x80,0x10,0x80,0x10,0x80,0x10,0x80,0x10,0x80, - 0x10,0x80,0x10,0x80,0x10,0x80,0x10,0x80,0x10,0x80, - 0x10,0x80,0x10,0x80,0x10,0x80,0x10,0x80,0x10,0x80, - 0x10,0x80,0x0a,0x8f,0x02,0x7f,0x01,0x7e,0x00,0x76, - 0xff,0x7f,0xfe,0x7f,0xfb,0x00,0xff,0x01,0xff,0x01, - 0x00,0x0a,0x01,0x02,0x01,0x01,0x05,0x00,0xf9,0x80, - 0x00,0x6b,0x0c,0x86,0x0d,0x8a,0xff,0x03,0xfe,0x02, - 0xfb,0x00,0xff,0x7e,0xff,0x7d,0x00,0x7b,0x01,0x7c, - 0x01,0x7f,0x05,0x00,0x02,0x01,0x01,0x03,0x03,0xfc, - 0x03,0x80,0x00,0x0f,0x00,0xfb,0x01,0x03,0x01,0x02, - 0x04,0x00,0x01,0x7e,0x01,0x7d,0x00,0x76,0x00,0x8a, - 0x01,0x03,0x02,0x02,0x03,0x00,0x02,0x7e,0x01,0x7d, - 0x00,0x76,0x03,0x80,0x03,0x8f,0x00,0x74,0x01,0x7e, - 0x02,0x7f,0x04,0x00,0x02,0x01,0x01,0x01,0x00,0x8d, - 0x00,0x6e,0xff,0x7e,0xfe,0x7f,0xfb,0x00,0xfe,0x01, - 0x0c,0x85,0x03,0x8d,0x01,0x02,0x03,0x00,0x02,0x7e, - 0x01,0x02,0x03,0x00,0x02,0x7e,0x00,0x74,0xfe,0x7f, - 0xfd,0x00,0xff,0x01,0xfe,0x7f,0xfd,0x00,0xff,0x01, - 0x00,0x0c,0x06,0x82,0x00,0x6b,0x08,0x86,0x03,0x80, - 0x0a,0x0f,0xf6,0x80,0x0a,0x71,0x03,0x80,0x03,0x8f, - 0x00,0x73,0x01,0x7e,0x07,0x00,0x02,0x02,0x00,0x0d, - 0x00,0xf3,0x01,0x7e,0x00,0x7e,0x03,0x82,0x03,0x8f, - 0x00,0x79,0x02,0x7e,0x08,0x00,0x00,0x89,0x00,0x71, - 0x02,0x80,0x03,0x8f,0x00,0x73,0x01,0x7e,0x03,0x00, - 0x02,0x02,0x00,0x0d,0x00,0xf3,0x01,0x7e,0x03,0x00, - 0x02,0x02,0x00,0x0d,0x00,0xf3,0x01,0x7e,0x03,0x80, - 0x03,0x8f,0x00,0x73,0x01,0x7e,0x03,0x00,0x02,0x02, - 0x00,0x0d,0x00,0xf3,0x01,0x7e,0x03,0x00,0x02,0x02, - 0x00,0x0d,0x00,0xf3,0x01,0x7e,0x00,0x7e,0x03,0x82, - 0x03,0x8d,0x00,0x02,0x02,0x00,0x00,0x71,0x08,0x00, - 0x02,0x02,0x00,0x06,0xfe,0x02,0xf8,0x00,0x0c,0xf6, - 0x03,0x8f,0x00,0x71,0x07,0x00,0x02,0x02,0x00,0x06, - 0xfe,0x02,0xf9,0x00,0x0c,0x85,0x00,0x71,0x02,0x80, - 0x03,0x8f,0x00,0x71,0x07,0x00,0x03,0x02,0x00,0x06, - 0xfd,0x02,0xf9,0x00,0x0c,0xf6,0x03,0x8d,0x02,0x02, - 0x06,0x00,0x02,0x7e,0x00,0x75,0xfe,0x7e,0xfa,0x00, - 0xfe,0x02,0x04,0x85,0x06,0x00,0x02,0xf9,0x03,0x80, - 0x00,0x0f,0x00,0xf8,0x04,0x00,0x00,0x06,0x02,0x02, - 0x04,0x00,0x02,0x7e,0x00,0x75,0xfe,0x7e,0xfc,0x00, - 0xfe,0x02,0x00,0x05,0x0a,0xf9,0x0d,0x80,0x00,0x0f, - 0xf7,0x00,0xff,0x7e,0x00,0x7b,0x01,0x7e,0x09,0x00, - 0xf6,0xfa,0x04,0x06,0x08,0xfa - }; - - //------------------------------------------------------------------------- - gsv_text::gsv_text() : - m_x(0.0), - m_y(0.0), - m_start_x(0.0), - m_width(10.0), - m_height(0.0), - m_space(0.0), - m_line_space(0.0), - m_text(m_chr), - m_text_buf(), - m_cur_chr(m_chr), - m_font(gsv_default_font), - m_loaded_font(), - m_status(initial), - m_big_endian(false), - m_flip(false) - { - m_chr[0] = m_chr[1] = 0; - - int t = 1; - if(*(char*)&t == 0) m_big_endian = true; - } - - //------------------------------------------------------------------------- - void gsv_text::font(const void* font) - { - m_font = font; - if(m_font == 0) m_font = &m_loaded_font[0]; - } - - //------------------------------------------------------------------------- - void gsv_text::size(double height, double width) - { - m_height = height; - m_width = width; - } - - //------------------------------------------------------------------------- - void gsv_text::space(double space) - { - m_space = space; - } - - //------------------------------------------------------------------------- - void gsv_text::line_space(double line_space) - { - m_line_space = line_space; - } - - //------------------------------------------------------------------------- - void gsv_text::start_point(double x, double y) - { - m_x = m_start_x = x; - m_y = y; - //if(m_flip) m_y += m_height; - } - - //------------------------------------------------------------------------- - void gsv_text::load_font(const char* file) - { - m_loaded_font.resize(0); - FILE* fd = fopen(file, "rb"); - if(fd) - { - unsigned len; - - fseek(fd, 0l, SEEK_END); - len = ftell(fd); - fseek(fd, 0l, SEEK_SET); - if(len > 0) - { - m_loaded_font.resize(len); - fread(&m_loaded_font[0], 1, len, fd); - m_font = &m_loaded_font[0]; - } - fclose(fd); - } - } - - //------------------------------------------------------------------------- - void gsv_text::text(const char* text) - { - if(text == 0) - { - m_chr[0] = 0; - m_text = m_chr; - return; - } - unsigned new_size = strlen(text) + 1; - if(new_size > m_text_buf.size()) - { - m_text_buf.resize(new_size); - } - memcpy(&m_text_buf[0], text, new_size); - m_text = &m_text_buf[0]; - } - - //------------------------------------------------------------------------- - void gsv_text::rewind(unsigned) - { - m_status = initial; - if(m_font == 0) return; - - m_indices = (int8u*)m_font; - double base_height = value(m_indices + 4); - m_indices += value(m_indices); - m_glyphs = (int8*)(m_indices + 257*2); - m_h = m_height / base_height; - m_w = (m_width == 0.0) ? m_h : m_width / base_height; - if(m_flip) m_h = -m_h; - m_cur_chr = m_text; - } - - //------------------------------------------------------------------------- - unsigned gsv_text::vertex(double* x, double* y) - { - unsigned idx; - int8 yc, yf; - int dx, dy; - bool quit = false; - - while(!quit) - { - switch(m_status) - { - case initial: - if(m_font == 0) - { - quit = true; - break; - } - m_status = next_char; - - case next_char: - if(*m_cur_chr == 0) - { - quit = true; - break; - } - idx = (*m_cur_chr++) & 0xFF; - if(idx == '\n') - { - m_x = m_start_x; - m_y -= m_flip ? -m_height - m_line_space : m_height + m_line_space; - break; - } - idx <<= 1; - m_bglyph = m_glyphs + value(m_indices + idx); - m_eglyph = m_glyphs + value(m_indices + idx + 2); - m_status = start_glyph; - - case start_glyph: - *x = m_x; - *y = m_y; - m_status = glyph; - return path_cmd_move_to; - - case glyph: - if(m_bglyph >= m_eglyph) - { - m_status = next_char; - m_x += m_space; - break; - } - dx = int(*m_bglyph++); - yf = (yc = *m_bglyph++) & 0x80; - yc <<= 1; - yc >>= 1; - dy = int(yc); - m_x += double(dx) * m_w; - m_y += double(dy) * m_h; - *x = m_x; - *y = m_y; - return yf ? path_cmd_move_to : path_cmd_line_to; - } - - } - return path_cmd_stop; - } - - //------------------------------------------------------------------------- - double gsv_text::text_width() - { - double x1, y1, x2, y2; - bounding_rect_single(*this, 0, &x1, &y1, &x2, &y2); - return x2 - x1; - } - - -} diff --git a/desmume/src/windows/agg/src/agg_image_filters.cpp b/desmume/src/windows/agg/src/agg_image_filters.cpp deleted file mode 100644 index fb508f61d..000000000 --- a/desmume/src/windows/agg/src/agg_image_filters.cpp +++ /dev/null @@ -1,107 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#include "agg_image_filters.h" - - -namespace agg -{ - //-------------------------------------------------------------------- - void image_filter_lut::realloc_lut(double radius) - { - m_radius = radius; - m_diameter = uceil(radius) * 2; - m_start = -int(m_diameter / 2 - 1); - unsigned size = m_diameter << image_subpixel_shift; - if(size > m_weight_array.size()) - { - m_weight_array.resize(size); - } - } - - - - //-------------------------------------------------------------------- - // This function normalizes integer values and corrects the rounding - // errors. It doesn't do anything with the source floating point values - // (m_weight_array_dbl), it corrects only integers according to the rule - // of 1.0 which means that any sum of pixel weights must be equal to 1.0. - // So, the filter function must produce a graph of the proper shape. - //-------------------------------------------------------------------- - void image_filter_lut::normalize() - { - unsigned i; - int flip = 1; - - for(i = 0; i < image_subpixel_scale; i++) - { - for(;;) - { - int sum = 0; - unsigned j; - for(j = 0; j < m_diameter; j++) - { - sum += m_weight_array[j * image_subpixel_scale + i]; - } - - if(sum == image_filter_scale) break; - - double k = double(image_filter_scale) / double(sum); - sum = 0; - for(j = 0; j < m_diameter; j++) - { - sum += m_weight_array[j * image_subpixel_scale + i] = - iround(m_weight_array[j * image_subpixel_scale + i] * k); - } - - sum -= image_filter_scale; - int inc = (sum > 0) ? -1 : 1; - - for(j = 0; j < m_diameter && sum; j++) - { - flip ^= 1; - unsigned idx = flip ? m_diameter/2 + j/2 : m_diameter/2 - j/2; - int v = m_weight_array[idx * image_subpixel_scale + i]; - if(v < image_filter_scale) - { - m_weight_array[idx * image_subpixel_scale + i] += inc; - sum += inc; - } - } - } - } - - unsigned pivot = m_diameter << (image_subpixel_shift - 1); - - for(i = 0; i < pivot; i++) - { - m_weight_array[pivot + i] = m_weight_array[pivot - i]; - } - unsigned end = (diameter() << image_subpixel_shift) - 1; - m_weight_array[0] = m_weight_array[end]; - } - - -} - diff --git a/desmume/src/windows/agg/src/agg_line_aa_basics.cpp b/desmume/src/windows/agg/src/agg_line_aa_basics.cpp deleted file mode 100644 index 8570e5c71..000000000 --- a/desmume/src/windows/agg/src/agg_line_aa_basics.cpp +++ /dev/null @@ -1,91 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#include -#include "agg_line_aa_basics.h" - -namespace agg -{ - //------------------------------------------------------------------------- - // The number of the octant is determined as a 3-bit value as follows: - // bit 0 = vertical flag - // bit 1 = sx < 0 - // bit 2 = sy < 0 - // - // [N] shows the number of the orthogonal quadrant - // shows the number of the diagonal quadrant - // <1> - // [1] | [0] - // . (3)011 | 001(1) . - // . | . - // . | . - // . | . - // (2)010 .|. 000(0) - // <2> ----------.+.----------- <0> - // (6)110 . | . 100(4) - // . | . - // . | . - // . | . - // (7)111 | 101(5) - // [2] | [3] - // <3> - // 0,1,2,3,4,5,6,7 - const int8u line_parameters::s_orthogonal_quadrant[8] = { 0,0,1,1,3,3,2,2 }; - const int8u line_parameters::s_diagonal_quadrant[8] = { 0,1,2,1,0,3,2,3 }; - - - - //------------------------------------------------------------------------- - void bisectrix(const line_parameters& l1, - const line_parameters& l2, - int* x, int* y) - { - double k = double(l2.len) / double(l1.len); - double tx = l2.x2 - (l2.x1 - l1.x1) * k; - double ty = l2.y2 - (l2.y1 - l1.y1) * k; - - //All bisectrices must be on the right of the line - //If the next point is on the left (l1 => l2.2) - //then the bisectix should be rotated by 180 degrees. - if(double(l2.x2 - l2.x1) * double(l2.y1 - l1.y1) < - double(l2.y2 - l2.y1) * double(l2.x1 - l1.x1) + 100.0) - { - tx -= (tx - l2.x1) * 2.0; - ty -= (ty - l2.y1) * 2.0; - } - - // Check if the bisectrix is too short - double dx = tx - l2.x1; - double dy = ty - l2.y1; - if((int)sqrt(dx * dx + dy * dy) < line_subpixel_scale) - { - *x = (l2.x1 + l2.x1 + (l2.y1 - l1.y1) + (l2.y2 - l2.y1)) >> 1; - *y = (l2.y1 + l2.y1 - (l2.x1 - l1.x1) - (l2.x2 - l2.x1)) >> 1; - return; - } - *x = iround(tx); - *y = iround(ty); - } - -} diff --git a/desmume/src/windows/agg/src/agg_line_profile_aa.cpp b/desmume/src/windows/agg/src/agg_line_profile_aa.cpp deleted file mode 100644 index 1df9e2cb8..000000000 --- a/desmume/src/windows/agg/src/agg_line_profile_aa.cpp +++ /dev/null @@ -1,125 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#include "agg_renderer_outline_aa.h" - -namespace agg -{ - - //--------------------------------------------------------------------- - void line_profile_aa::width(double w) - { - if(w < 0.0) w = 0.0; - - if(w < m_smoother_width) w += w; - else w += m_smoother_width; - - w *= 0.5; - - w -= m_smoother_width; - double s = m_smoother_width; - if(w < 0.0) - { - s += w; - w = 0.0; - } - set(w, s); - } - - - //--------------------------------------------------------------------- - line_profile_aa::value_type* line_profile_aa::profile(double w) - { - m_subpixel_width = uround(w * subpixel_scale); - unsigned size = m_subpixel_width + subpixel_scale * 6; - if(size > m_profile.size()) - { - m_profile.resize(size); - } - return &m_profile[0]; - } - - - //--------------------------------------------------------------------- - void line_profile_aa::set(double center_width, double smoother_width) - { - double base_val = 1.0; - if(center_width == 0.0) center_width = 1.0 / subpixel_scale; - if(smoother_width == 0.0) smoother_width = 1.0 / subpixel_scale; - - double width = center_width + smoother_width; - if(width < m_min_width) - { - double k = width / m_min_width; - base_val *= k; - center_width /= k; - smoother_width /= k; - } - - value_type* ch = profile(center_width + smoother_width); - - unsigned subpixel_center_width = unsigned(center_width * subpixel_scale); - unsigned subpixel_smoother_width = unsigned(smoother_width * subpixel_scale); - - value_type* ch_center = ch + subpixel_scale*2; - value_type* ch_smoother = ch_center + subpixel_center_width; - - unsigned i; - - unsigned val = m_gamma[unsigned(base_val * aa_mask)]; - ch = ch_center; - for(i = 0; i < subpixel_center_width; i++) - { - *ch++ = (value_type)val; - } - - for(i = 0; i < subpixel_smoother_width; i++) - { - *ch_smoother++ = - m_gamma[unsigned((base_val - - base_val * - (double(i) / subpixel_smoother_width)) * aa_mask)]; - } - - unsigned n_smoother = profile_size() - - subpixel_smoother_width - - subpixel_center_width - - subpixel_scale*2; - - val = m_gamma[0]; - for(i = 0; i < n_smoother; i++) - { - *ch_smoother++ = (value_type)val; - } - - ch = ch_center; - for(i = 0; i < subpixel_scale*2; i++) - { - *--ch = *ch_center++; - } - } - - -} - diff --git a/desmume/src/windows/agg/src/agg_rounded_rect.cpp b/desmume/src/windows/agg/src/agg_rounded_rect.cpp deleted file mode 100644 index a480043a3..000000000 --- a/desmume/src/windows/agg/src/agg_rounded_rect.cpp +++ /dev/null @@ -1,169 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#include -#include "agg_rounded_rect.h" - - -namespace agg -{ - //------------------------------------------------------------------------ - rounded_rect::rounded_rect(double x1, double y1, double x2, double y2, double r) : - m_x1(x1), m_y1(y1), m_x2(x2), m_y2(y2), - m_rx1(r), m_ry1(r), m_rx2(r), m_ry2(r), - m_rx3(r), m_ry3(r), m_rx4(r), m_ry4(r) - { - if(x1 > x2) { m_x1 = x2; m_x2 = x1; } - if(y1 > y2) { m_y1 = y2; m_y2 = y1; } - } - - //-------------------------------------------------------------------- - void rounded_rect::rect(double x1, double y1, double x2, double y2) - { - m_x1 = x1; - m_y1 = y1; - m_x2 = x2; - m_y2 = y2; - if(x1 > x2) { m_x1 = x2; m_x2 = x1; } - if(y1 > y2) { m_y1 = y2; m_y2 = y1; } - } - - //-------------------------------------------------------------------- - void rounded_rect::radius(double r) - { - m_rx1 = m_ry1 = m_rx2 = m_ry2 = m_rx3 = m_ry3 = m_rx4 = m_ry4 = r; - } - - //-------------------------------------------------------------------- - void rounded_rect::radius(double rx, double ry) - { - m_rx1 = m_rx2 = m_rx3 = m_rx4 = rx; - m_ry1 = m_ry2 = m_ry3 = m_ry4 = ry; - } - - //-------------------------------------------------------------------- - void rounded_rect::radius(double rx_bottom, double ry_bottom, - double rx_top, double ry_top) - { - m_rx1 = m_rx2 = rx_bottom; - m_rx3 = m_rx4 = rx_top; - m_ry1 = m_ry2 = ry_bottom; - m_ry3 = m_ry4 = ry_top; - } - - //-------------------------------------------------------------------- - void rounded_rect::radius(double rx1, double ry1, double rx2, double ry2, - double rx3, double ry3, double rx4, double ry4) - { - m_rx1 = rx1; m_ry1 = ry1; m_rx2 = rx2; m_ry2 = ry2; - m_rx3 = rx3; m_ry3 = ry3; m_rx4 = rx4; m_ry4 = ry4; - } - - //-------------------------------------------------------------------- - void rounded_rect::normalize_radius() - { - double dx = fabs(m_x2 - m_x1); - double dy = fabs(m_y2 - m_y1); - - double k = 1.0; - double t; - t = dx / (m_rx1 + m_rx2); if(t < k) k = t; - t = dx / (m_rx3 + m_rx4); if(t < k) k = t; - t = dy / (m_ry1 + m_ry2); if(t < k) k = t; - t = dy / (m_ry3 + m_ry4); if(t < k) k = t; - - if(k < 1.0) - { - m_rx1 *= k; m_ry1 *= k; m_rx2 *= k; m_ry2 *= k; - m_rx3 *= k; m_ry3 *= k; m_rx4 *= k; m_ry4 *= k; - } - } - - //-------------------------------------------------------------------- - void rounded_rect::rewind(unsigned) - { - m_status = 0; - } - - //-------------------------------------------------------------------- - unsigned rounded_rect::vertex(double* x, double* y) - { - unsigned cmd = path_cmd_stop; - switch(m_status) - { - case 0: - m_arc.init(m_x1 + m_rx1, m_y1 + m_ry1, m_rx1, m_ry1, - pi, pi+pi*0.5); - m_arc.rewind(0); - m_status++; - - case 1: - cmd = m_arc.vertex(x, y); - if(is_stop(cmd)) m_status++; - else return cmd; - - case 2: - m_arc.init(m_x2 - m_rx2, m_y1 + m_ry2, m_rx2, m_ry2, - pi+pi*0.5, 0.0); - m_arc.rewind(0); - m_status++; - - case 3: - cmd = m_arc.vertex(x, y); - if(is_stop(cmd)) m_status++; - else return path_cmd_line_to; - - case 4: - m_arc.init(m_x2 - m_rx3, m_y2 - m_ry3, m_rx3, m_ry3, - 0.0, pi*0.5); - m_arc.rewind(0); - m_status++; - - case 5: - cmd = m_arc.vertex(x, y); - if(is_stop(cmd)) m_status++; - else return path_cmd_line_to; - - case 6: - m_arc.init(m_x1 + m_rx4, m_y2 - m_ry4, m_rx4, m_ry4, - pi*0.5, pi); - m_arc.rewind(0); - m_status++; - - case 7: - cmd = m_arc.vertex(x, y); - if(is_stop(cmd)) m_status++; - else return path_cmd_line_to; - - case 8: - cmd = path_cmd_end_poly | path_flags_close | path_flags_ccw; - m_status++; - break; - } - return cmd; - } - - -} - diff --git a/desmume/src/windows/agg/src/agg_sqrt_tables.cpp b/desmume/src/windows/agg/src/agg_sqrt_tables.cpp deleted file mode 100644 index 52c311c5f..000000000 --- a/desmume/src/windows/agg/src/agg_sqrt_tables.cpp +++ /dev/null @@ -1,120 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#include "agg_basics.h" - -namespace agg -{ - int16u g_sqrt_table[1024] = //----------g_sqrt_table - { - 0, - 2048,2896,3547,4096,4579,5017,5418,5793,6144,6476,6792,7094,7384,7663,7932,8192,8444, - 8689,8927,9159,9385,9606,9822,10033,10240,10443,10642,10837,11029,11217,11403,11585, - 11765,11942,12116,12288,12457,12625,12790,12953,13114,13273,13430,13585,13738,13890, - 14040,14189,14336,14482,14626,14768,14910,15050,15188,15326,15462,15597,15731,15864, - 15995,16126,16255,16384,16512,16638,16764,16888,17012,17135,17257,17378,17498,17618, - 17736,17854,17971,18087,18203,18318,18432,18545,18658,18770,18882,18992,19102,19212, - 19321,19429,19537,19644,19750,19856,19961,20066,20170,20274,20377,20480,20582,20684, - 20785,20886,20986,21085,21185,21283,21382,21480,21577,21674,21771,21867,21962,22058, - 22153,22247,22341,22435,22528,22621,22713,22806,22897,22989,23080,23170,23261,23351, - 23440,23530,23619,23707,23796,23884,23971,24059,24146,24232,24319,24405,24491,24576, - 24661,24746,24831,24915,24999,25083,25166,25249,25332,25415,25497,25580,25661,25743, - 25824,25905,25986,26067,26147,26227,26307,26387,26466,26545,26624,26703,26781,26859, - 26937,27015,27092,27170,27247,27324,27400,27477,27553,27629,27705,27780,27856,27931, - 28006,28081,28155,28230,28304,28378,28452,28525,28599,28672,28745,28818,28891,28963, - 29035,29108,29180,29251,29323,29394,29466,29537,29608,29678,29749,29819,29890,29960, - 30030,30099,30169,30238,30308,30377,30446,30515,30583,30652,30720,30788,30856,30924, - 30992,31059,31127,31194,31261,31328,31395,31462,31529,31595,31661,31727,31794,31859, - 31925,31991,32056,32122,32187,32252,32317,32382,32446,32511,32575,32640,32704,32768, - 32832,32896,32959,33023,33086,33150,33213,33276,33339,33402,33465,33527,33590,33652, - 33714,33776,33839,33900,33962,34024,34086,34147,34208,34270,34331,34392,34453,34514, - 34574,34635,34695,34756,34816,34876,34936,34996,35056,35116,35176,35235,35295,35354, - 35413,35472,35531,35590,35649,35708,35767,35825,35884,35942,36001,36059,36117,36175, - 36233,36291,36348,36406,36464,36521,36578,36636,36693,36750,36807,36864,36921,36978, - 37034,37091,37147,37204,37260,37316,37372,37429,37485,37540,37596,37652,37708,37763, - 37819,37874,37929,37985,38040,38095,38150,38205,38260,38315,38369,38424,38478,38533, - 38587,38642,38696,38750,38804,38858,38912,38966,39020,39073,39127,39181,39234,39287, - 39341,39394,39447,39500,39553,39606,39659,39712,39765,39818,39870,39923,39975,40028, - 40080,40132,40185,40237,40289,40341,40393,40445,40497,40548,40600,40652,40703,40755, - 40806,40857,40909,40960,41011,41062,41113,41164,41215,41266,41317,41368,41418,41469, - 41519,41570,41620,41671,41721,41771,41821,41871,41922,41972,42021,42071,42121,42171, - 42221,42270,42320,42369,42419,42468,42518,42567,42616,42665,42714,42763,42813,42861, - 42910,42959,43008,43057,43105,43154,43203,43251,43300,43348,43396,43445,43493,43541, - 43589,43637,43685,43733,43781,43829,43877,43925,43972,44020,44068,44115,44163,44210, - 44258,44305,44352,44400,44447,44494,44541,44588,44635,44682,44729,44776,44823,44869, - 44916,44963,45009,45056,45103,45149,45195,45242,45288,45334,45381,45427,45473,45519, - 45565,45611,45657,45703,45749,45795,45840,45886,45932,45977,46023,46069,46114,46160, - 46205,46250,46296,46341,46386,46431,46477,46522,46567,46612,46657,46702,46746,46791, - 46836,46881,46926,46970,47015,47059,47104,47149,47193,47237,47282,47326,47370,47415, - 47459,47503,47547,47591,47635,47679,47723,47767,47811,47855,47899,47942,47986,48030, - 48074,48117,48161,48204,48248,48291,48335,48378,48421,48465,48508,48551,48594,48637, - 48680,48723,48766,48809,48852,48895,48938,48981,49024,49067,49109,49152,49195,49237, - 49280,49322,49365,49407,49450,49492,49535,49577,49619,49661,49704,49746,49788,49830, - 49872,49914,49956,49998,50040,50082,50124,50166,50207,50249,50291,50332,50374,50416, - 50457,50499,50540,50582,50623,50665,50706,50747,50789,50830,50871,50912,50954,50995, - 51036,51077,51118,51159,51200,51241,51282,51323,51364,51404,51445,51486,51527,51567, - 51608,51649,51689,51730,51770,51811,51851,51892,51932,51972,52013,52053,52093,52134, - 52174,52214,52254,52294,52334,52374,52414,52454,52494,52534,52574,52614,52654,52694, - 52734,52773,52813,52853,52892,52932,52972,53011,53051,53090,53130,53169,53209,53248, - 53287,53327,53366,53405,53445,53484,53523,53562,53601,53640,53679,53719,53758,53797, - 53836,53874,53913,53952,53991,54030,54069,54108,54146,54185,54224,54262,54301,54340, - 54378,54417,54455,54494,54532,54571,54609,54647,54686,54724,54762,54801,54839,54877, - 54915,54954,54992,55030,55068,55106,55144,55182,55220,55258,55296,55334,55372,55410, - 55447,55485,55523,55561,55599,55636,55674,55712,55749,55787,55824,55862,55900,55937, - 55975,56012,56049,56087,56124,56162,56199,56236,56273,56311,56348,56385,56422,56459, - 56497,56534,56571,56608,56645,56682,56719,56756,56793,56830,56867,56903,56940,56977, - 57014,57051,57087,57124,57161,57198,57234,57271,57307,57344,57381,57417,57454,57490, - 57527,57563,57599,57636,57672,57709,57745,57781,57817,57854,57890,57926,57962,57999, - 58035,58071,58107,58143,58179,58215,58251,58287,58323,58359,58395,58431,58467,58503, - 58538,58574,58610,58646,58682,58717,58753,58789,58824,58860,58896,58931,58967,59002, - 59038,59073,59109,59144,59180,59215,59251,59286,59321,59357,59392,59427,59463,59498, - 59533,59568,59603,59639,59674,59709,59744,59779,59814,59849,59884,59919,59954,59989, - 60024,60059,60094,60129,60164,60199,60233,60268,60303,60338,60373,60407,60442,60477, - 60511,60546,60581,60615,60650,60684,60719,60753,60788,60822,60857,60891,60926,60960, - 60995,61029,61063,61098,61132,61166,61201,61235,61269,61303,61338,61372,61406,61440, - 61474,61508,61542,61576,61610,61644,61678,61712,61746,61780,61814,61848,61882,61916, - 61950,61984,62018,62051,62085,62119,62153,62186,62220,62254,62287,62321,62355,62388, - 62422,62456,62489,62523,62556,62590,62623,62657,62690,62724,62757,62790,62824,62857, - 62891,62924,62957,62991,63024,63057,63090,63124,63157,63190,63223,63256,63289,63323, - 63356,63389,63422,63455,63488,63521,63554,63587,63620,63653,63686,63719,63752,63785, - 63817,63850,63883,63916,63949,63982,64014,64047,64080,64113,64145,64178,64211,64243, - 64276,64309,64341,64374,64406,64439,64471,64504,64536,64569,64601,64634,64666,64699, - 64731,64763,64796,64828,64861,64893,64925,64957,64990,65022,65054,65086,65119,65151, - 65183,65215,65247,65279,65312,65344,65376,65408,65440,65472,65504 - }; - - - int8 g_elder_bit_table[256] = //---------g_elder_bit_table - { - 0,0,1,1,2,2,2,2,3,3,3,3,3,3,3,3,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4, - 5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5, - 6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6, - 6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6, - 7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7, - 7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7, - 7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7, - 7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7 - }; - -} diff --git a/desmume/src/windows/agg/src/agg_trans_affine.cpp b/desmume/src/windows/agg/src/agg_trans_affine.cpp deleted file mode 100644 index 489c056cc..000000000 --- a/desmume/src/windows/agg/src/agg_trans_affine.cpp +++ /dev/null @@ -1,200 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#include "agg_trans_affine.h" - - - -namespace agg -{ - - //------------------------------------------------------------------------ - const trans_affine& trans_affine::parl_to_parl(const double* src, - const double* dst) - { - sx = src[2] - src[0]; - shy = src[3] - src[1]; - shx = src[4] - src[0]; - sy = src[5] - src[1]; - tx = src[0]; - ty = src[1]; - invert(); - multiply(trans_affine(dst[2] - dst[0], dst[3] - dst[1], - dst[4] - dst[0], dst[5] - dst[1], - dst[0], dst[1])); - return *this; - } - - //------------------------------------------------------------------------ - const trans_affine& trans_affine::rect_to_parl(double x1, double y1, - double x2, double y2, - const double* parl) - { - double src[6]; - src[0] = x1; src[1] = y1; - src[2] = x2; src[3] = y1; - src[4] = x2; src[5] = y2; - parl_to_parl(src, parl); - return *this; - } - - //------------------------------------------------------------------------ - const trans_affine& trans_affine::parl_to_rect(const double* parl, - double x1, double y1, - double x2, double y2) - { - double dst[6]; - dst[0] = x1; dst[1] = y1; - dst[2] = x2; dst[3] = y1; - dst[4] = x2; dst[5] = y2; - parl_to_parl(parl, dst); - return *this; - } - - //------------------------------------------------------------------------ - const trans_affine& trans_affine::multiply(const trans_affine& m) - { - double t0 = sx * m.sx + shy * m.shx; - double t2 = shx * m.sx + sy * m.shx; - double t4 = tx * m.sx + ty * m.shx + m.tx; - shy = sx * m.shy + shy * m.sy; - sy = shx * m.shy + sy * m.sy; - ty = tx * m.shy + ty * m.sy + m.ty; - sx = t0; - shx = t2; - tx = t4; - return *this; - } - - - //------------------------------------------------------------------------ - const trans_affine& trans_affine::invert() - { - double d = determinant_reciprocal(); - - double t0 = sy * d; - sy = sx * d; - shy = -shy * d; - shx = -shx * d; - - double t4 = -tx * t0 - ty * shx; - ty = -tx * shy - ty * sy; - - sx = t0; - tx = t4; - return *this; - } - - - //------------------------------------------------------------------------ - const trans_affine& trans_affine::flip_x() - { - sx = -sx; - shy = -shy; - tx = -tx; - return *this; - } - - //------------------------------------------------------------------------ - const trans_affine& trans_affine::flip_y() - { - shx = -shx; - sy = -sy; - ty = -ty; - return *this; - } - - //------------------------------------------------------------------------ - const trans_affine& trans_affine::reset() - { - sx = sy = 1.0; - shy = shx = tx = ty = 0.0; - return *this; - } - - //------------------------------------------------------------------------ - bool trans_affine::is_identity(double epsilon) const - { - return is_equal_eps(sx, 1.0, epsilon) && - is_equal_eps(shy, 0.0, epsilon) && - is_equal_eps(shx, 0.0, epsilon) && - is_equal_eps(sy, 1.0, epsilon) && - is_equal_eps(tx, 0.0, epsilon) && - is_equal_eps(ty, 0.0, epsilon); - } - - //------------------------------------------------------------------------ - bool trans_affine::is_valid(double epsilon) const - { - return fabs(sx) > epsilon && fabs(sy) > epsilon; - } - - //------------------------------------------------------------------------ - bool trans_affine::is_equal(const trans_affine& m, double epsilon) const - { - return is_equal_eps(sx, m.sx, epsilon) && - is_equal_eps(shy, m.shy, epsilon) && - is_equal_eps(shx, m.shx, epsilon) && - is_equal_eps(sy, m.sy, epsilon) && - is_equal_eps(tx, m.tx, epsilon) && - is_equal_eps(ty, m.ty, epsilon); - } - - //------------------------------------------------------------------------ - double trans_affine::rotation() const - { - double x1 = 0.0; - double y1 = 0.0; - double x2 = 1.0; - double y2 = 0.0; - transform(&x1, &y1); - transform(&x2, &y2); - return atan2(y2-y1, x2-x1); - } - - //------------------------------------------------------------------------ - void trans_affine::translation(double* dx, double* dy) const - { - *dx = tx; - *dy = ty; - } - - //------------------------------------------------------------------------ - void trans_affine::scaling(double* x, double* y) const - { - double x1 = 0.0; - double y1 = 0.0; - double x2 = 1.0; - double y2 = 1.0; - trans_affine t(*this); - t *= trans_affine_rotation(-rotation()); - t.transform(&x1, &y1); - t.transform(&x2, &y2); - *x = x2 - x1; - *y = y2 - y1; - } - - -} - diff --git a/desmume/src/windows/agg/src/agg_trans_double_path.cpp b/desmume/src/windows/agg/src/agg_trans_double_path.cpp deleted file mode 100644 index fc3d184e5..000000000 --- a/desmume/src/windows/agg/src/agg_trans_double_path.cpp +++ /dev/null @@ -1,282 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#include "agg_math.h" -#include "agg_trans_double_path.h" - -namespace agg -{ - - //------------------------------------------------------------------------ - trans_double_path::trans_double_path() : - m_kindex1(0.0), - m_kindex2(0.0), - m_base_length(0.0), - m_base_height(1.0), - m_status1(initial), - m_status2(initial), - m_preserve_x_scale(true) - { - } - - - //------------------------------------------------------------------------ - void trans_double_path::reset() - { - m_src_vertices1.remove_all(); - m_src_vertices2.remove_all(); - m_kindex1 = 0.0; - m_kindex1 = 0.0; - m_status1 = initial; - m_status2 = initial; - } - - - //------------------------------------------------------------------------ - void trans_double_path::move_to1(double x, double y) - { - if(m_status1 == initial) - { - m_src_vertices1.modify_last(vertex_dist(x, y)); - m_status1 = making_path; - } - else - { - line_to1(x, y); - } - } - - - //------------------------------------------------------------------------ - void trans_double_path::line_to1(double x, double y) - { - if(m_status1 == making_path) - { - m_src_vertices1.add(vertex_dist(x, y)); - } - } - - - //------------------------------------------------------------------------ - void trans_double_path::move_to2(double x, double y) - { - if(m_status2 == initial) - { - m_src_vertices2.modify_last(vertex_dist(x, y)); - m_status2 = making_path; - } - else - { - line_to2(x, y); - } - } - - - //------------------------------------------------------------------------ - void trans_double_path::line_to2(double x, double y) - { - if(m_status2 == making_path) - { - m_src_vertices2.add(vertex_dist(x, y)); - } - } - - - //------------------------------------------------------------------------ - double trans_double_path::finalize_path(vertex_storage& vertices) - { - unsigned i; - double dist; - double d; - - vertices.close(false); - if(vertices.size() > 2) - { - if(vertices[vertices.size() - 2].dist * 10.0 < - vertices[vertices.size() - 3].dist) - { - d = vertices[vertices.size() - 3].dist + - vertices[vertices.size() - 2].dist; - - vertices[vertices.size() - 2] = - vertices[vertices.size() - 1]; - - vertices.remove_last(); - vertices[vertices.size() - 2].dist = d; - } - } - - dist = 0; - for(i = 0; i < vertices.size(); i++) - { - vertex_dist& v = vertices[i]; - d = v.dist; - v.dist = dist; - dist += d; - } - - return (vertices.size() - 1) / dist; - } - - - //------------------------------------------------------------------------ - void trans_double_path::finalize_paths() - { - if(m_status1 == making_path && m_src_vertices1.size() > 1 && - m_status2 == making_path && m_src_vertices2.size() > 1) - { - m_kindex1 = finalize_path(m_src_vertices1); - m_kindex2 = finalize_path(m_src_vertices2); - m_status1 = ready; - m_status2 = ready; - } - } - - - //------------------------------------------------------------------------ - double trans_double_path::total_length1() const - { - if(m_base_length >= 1e-10) return m_base_length; - return (m_status1 == ready) ? - m_src_vertices1[m_src_vertices1.size() - 1].dist : - 0.0; - } - - - //------------------------------------------------------------------------ - double trans_double_path::total_length2() const - { - if(m_base_length >= 1e-10) return m_base_length; - return (m_status2 == ready) ? - m_src_vertices2[m_src_vertices2.size() - 1].dist : - 0.0; - } - - - //------------------------------------------------------------------------ - void trans_double_path::transform1(const vertex_storage& vertices, - double kindex, double kx, - double *x, double* y) const - { - double x1 = 0.0; - double y1 = 0.0; - double dx = 1.0; - double dy = 1.0; - double d = 0.0; - double dd = 1.0; - *x *= kx; - if(*x < 0.0) - { - // Extrapolation on the left - //-------------------------- - x1 = vertices[0].x; - y1 = vertices[0].y; - dx = vertices[1].x - x1; - dy = vertices[1].y - y1; - dd = vertices[1].dist - vertices[0].dist; - d = *x; - } - else - if(*x > vertices[vertices.size() - 1].dist) - { - // Extrapolation on the right - //-------------------------- - unsigned i = vertices.size() - 2; - unsigned j = vertices.size() - 1; - x1 = vertices[j].x; - y1 = vertices[j].y; - dx = x1 - vertices[i].x; - dy = y1 - vertices[i].y; - dd = vertices[j].dist - vertices[i].dist; - d = *x - vertices[j].dist; - } - else - { - // Interpolation - //-------------------------- - unsigned i = 0; - unsigned j = vertices.size() - 1; - if(m_preserve_x_scale) - { - unsigned k; - for(i = 0; (j - i) > 1; ) - { - if(*x < vertices[k = (i + j) >> 1].dist) - { - j = k; - } - else - { - i = k; - } - } - d = vertices[i].dist; - dd = vertices[j].dist - d; - d = *x - d; - } - else - { - i = unsigned(*x * kindex); - j = i + 1; - dd = vertices[j].dist - vertices[i].dist; - d = ((*x * kindex) - i) * dd; - } - x1 = vertices[i].x; - y1 = vertices[i].y; - dx = vertices[j].x - x1; - dy = vertices[j].y - y1; - } - *x = x1 + dx * d / dd; - *y = y1 + dy * d / dd; - } - - - //------------------------------------------------------------------------ - void trans_double_path::transform(double *x, double *y) const - { - if(m_status1 == ready && m_status2 == ready) - { - if(m_base_length > 1e-10) - { - *x *= m_src_vertices1[m_src_vertices1.size() - 1].dist / - m_base_length; - } - - double x1 = *x; - double y1 = *y; - double x2 = *x; - double y2 = *y; - double dd = m_src_vertices2[m_src_vertices2.size() - 1].dist / - m_src_vertices1[m_src_vertices1.size() - 1].dist; - - transform1(m_src_vertices1, m_kindex1, 1.0, &x1, &y1); - transform1(m_src_vertices2, m_kindex2, dd, &x2, &y2); - - *x = x1 + *y * (x2 - x1) / m_base_height; - *y = y1 + *y * (y2 - y1) / m_base_height; - } - } - -} - diff --git a/desmume/src/windows/agg/src/agg_trans_single_path.cpp b/desmume/src/windows/agg/src/agg_trans_single_path.cpp deleted file mode 100644 index 368ab883a..000000000 --- a/desmume/src/windows/agg/src/agg_trans_single_path.cpp +++ /dev/null @@ -1,211 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#include "agg_math.h" -#include "agg_vertex_sequence.h" -#include "agg_trans_single_path.h" - -namespace agg -{ - - //------------------------------------------------------------------------ - trans_single_path::trans_single_path() : - m_base_length(0.0), - m_kindex(0.0), - m_status(initial), - m_preserve_x_scale(true) - { - } - - //------------------------------------------------------------------------ - void trans_single_path::reset() - { - m_src_vertices.remove_all(); - m_kindex = 0.0; - m_status = initial; - } - - //------------------------------------------------------------------------ - void trans_single_path::move_to(double x, double y) - { - if(m_status == initial) - { - m_src_vertices.modify_last(vertex_dist(x, y)); - m_status = making_path; - } - else - { - line_to(x, y); - } - } - - //------------------------------------------------------------------------ - void trans_single_path::line_to(double x, double y) - { - if(m_status == making_path) - { - m_src_vertices.add(vertex_dist(x, y)); - } - } - - - //------------------------------------------------------------------------ - void trans_single_path::finalize_path() - { - if(m_status == making_path && m_src_vertices.size() > 1) - { - unsigned i; - double dist; - double d; - - m_src_vertices.close(false); - if(m_src_vertices.size() > 2) - { - if(m_src_vertices[m_src_vertices.size() - 2].dist * 10.0 < - m_src_vertices[m_src_vertices.size() - 3].dist) - { - d = m_src_vertices[m_src_vertices.size() - 3].dist + - m_src_vertices[m_src_vertices.size() - 2].dist; - - m_src_vertices[m_src_vertices.size() - 2] = - m_src_vertices[m_src_vertices.size() - 1]; - - m_src_vertices.remove_last(); - m_src_vertices[m_src_vertices.size() - 2].dist = d; - } - } - - dist = 0.0; - for(i = 0; i < m_src_vertices.size(); i++) - { - vertex_dist& v = m_src_vertices[i]; - double d = v.dist; - v.dist = dist; - dist += d; - } - m_kindex = (m_src_vertices.size() - 1) / dist; - m_status = ready; - } - } - - - - //------------------------------------------------------------------------ - double trans_single_path::total_length() const - { - if(m_base_length >= 1e-10) return m_base_length; - return (m_status == ready) ? - m_src_vertices[m_src_vertices.size() - 1].dist : - 0.0; - } - - - //------------------------------------------------------------------------ - void trans_single_path::transform(double *x, double *y) const - { - if(m_status == ready) - { - if(m_base_length > 1e-10) - { - *x *= m_src_vertices[m_src_vertices.size() - 1].dist / - m_base_length; - } - - double x1 = 0.0; - double y1 = 0.0; - double dx = 1.0; - double dy = 1.0; - double d = 0.0; - double dd = 1.0; - if(*x < 0.0) - { - // Extrapolation on the left - //-------------------------- - x1 = m_src_vertices[0].x; - y1 = m_src_vertices[0].y; - dx = m_src_vertices[1].x - x1; - dy = m_src_vertices[1].y - y1; - dd = m_src_vertices[1].dist - m_src_vertices[0].dist; - d = *x; - } - else - if(*x > m_src_vertices[m_src_vertices.size() - 1].dist) - { - // Extrapolation on the right - //-------------------------- - unsigned i = m_src_vertices.size() - 2; - unsigned j = m_src_vertices.size() - 1; - x1 = m_src_vertices[j].x; - y1 = m_src_vertices[j].y; - dx = x1 - m_src_vertices[i].x; - dy = y1 - m_src_vertices[i].y; - dd = m_src_vertices[j].dist - m_src_vertices[i].dist; - d = *x - m_src_vertices[j].dist; - } - else - { - // Interpolation - //-------------------------- - unsigned i = 0; - unsigned j = m_src_vertices.size() - 1; - if(m_preserve_x_scale) - { - unsigned k; - for(i = 0; (j - i) > 1; ) - { - if(*x < m_src_vertices[k = (i + j) >> 1].dist) - { - j = k; - } - else - { - i = k; - } - } - d = m_src_vertices[i].dist; - dd = m_src_vertices[j].dist - d; - d = *x - d; - } - else - { - i = unsigned(*x * m_kindex); - j = i + 1; - dd = m_src_vertices[j].dist - m_src_vertices[i].dist; - d = ((*x * m_kindex) - i) * dd; - } - x1 = m_src_vertices[i].x; - y1 = m_src_vertices[i].y; - dx = m_src_vertices[j].x - x1; - dy = m_src_vertices[j].y - y1; - } - double x2 = x1 + dx * d / dd; - double y2 = y1 + dy * d / dd; - *x = x2 - *y * dy / dd; - *y = y2 + *y * dx / dd; - } - } - - -} - diff --git a/desmume/src/windows/agg/src/agg_trans_warp_magnifier.cpp b/desmume/src/windows/agg/src/agg_trans_warp_magnifier.cpp deleted file mode 100644 index 0854d06ce..000000000 --- a/desmume/src/windows/agg/src/agg_trans_warp_magnifier.cpp +++ /dev/null @@ -1,79 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#include -#include "agg_trans_warp_magnifier.h" - -namespace agg -{ - - //------------------------------------------------------------------------ - void trans_warp_magnifier::transform(double* x, double* y) const - { - double dx = *x - m_xc; - double dy = *y - m_yc; - double r = sqrt(dx * dx + dy * dy); - if(r < m_radius) - { - *x = m_xc + dx * m_magn; - *y = m_yc + dy * m_magn; - return; - } - - double m = (r + m_radius * (m_magn - 1.0)) / r; - *x = m_xc + dx * m; - *y = m_yc + dy * m; - } - - //------------------------------------------------------------------------ - void trans_warp_magnifier::inverse_transform(double* x, double* y) const - { - // New version by Andrew Skalkin - //----------------- - double dx = *x - m_xc; - double dy = *y - m_yc; - double r = sqrt(dx * dx + dy * dy); - - if(r < m_radius * m_magn) - { - *x = m_xc + dx / m_magn; - *y = m_yc + dy / m_magn; - } - else - { - double rnew = r - m_radius * (m_magn - 1.0); - *x = m_xc + rnew * dx / r; - *y = m_yc + rnew * dy / r; - } - - // Old version - //----------------- - //trans_warp_magnifier t(*this); - //t.magnification(1.0 / m_magn); - //t.radius(m_radius * m_magn); - //t.transform(x, y); - } - - -} diff --git a/desmume/src/windows/agg/src/agg_vcgen_bspline.cpp b/desmume/src/windows/agg/src/agg_vcgen_bspline.cpp deleted file mode 100644 index 4483f612e..000000000 --- a/desmume/src/windows/agg/src/agg_vcgen_bspline.cpp +++ /dev/null @@ -1,203 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#include "agg_vcgen_bspline.h" - -namespace agg -{ - - //------------------------------------------------------------------------ - vcgen_bspline::vcgen_bspline() : - m_src_vertices(), - m_spline_x(), - m_spline_y(), - m_interpolation_step(1.0/50.0), - m_closed(0), - m_status(initial), - m_src_vertex(0) - { - } - - - //------------------------------------------------------------------------ - void vcgen_bspline::remove_all() - { - m_src_vertices.remove_all(); - m_closed = 0; - m_status = initial; - m_src_vertex = 0; - } - - - //------------------------------------------------------------------------ - void vcgen_bspline::add_vertex(double x, double y, unsigned cmd) - { - m_status = initial; - if(is_move_to(cmd)) - { - m_src_vertices.modify_last(point_d(x, y)); - } - else - { - if(is_vertex(cmd)) - { - m_src_vertices.add(point_d(x, y)); - } - else - { - m_closed = get_close_flag(cmd); - } - } - } - - - //------------------------------------------------------------------------ - void vcgen_bspline::rewind(unsigned) - { - m_cur_abscissa = 0.0; - m_max_abscissa = 0.0; - m_src_vertex = 0; - if(m_status == initial && m_src_vertices.size() > 2) - { - if(m_closed) - { - m_spline_x.init(m_src_vertices.size() + 8); - m_spline_y.init(m_src_vertices.size() + 8); - m_spline_x.add_point(0.0, m_src_vertices.prev(m_src_vertices.size() - 3).x); - m_spline_y.add_point(0.0, m_src_vertices.prev(m_src_vertices.size() - 3).y); - m_spline_x.add_point(1.0, m_src_vertices[m_src_vertices.size() - 3].x); - m_spline_y.add_point(1.0, m_src_vertices[m_src_vertices.size() - 3].y); - m_spline_x.add_point(2.0, m_src_vertices[m_src_vertices.size() - 2].x); - m_spline_y.add_point(2.0, m_src_vertices[m_src_vertices.size() - 2].y); - m_spline_x.add_point(3.0, m_src_vertices[m_src_vertices.size() - 1].x); - m_spline_y.add_point(3.0, m_src_vertices[m_src_vertices.size() - 1].y); - } - else - { - m_spline_x.init(m_src_vertices.size()); - m_spline_y.init(m_src_vertices.size()); - } - unsigned i; - for(i = 0; i < m_src_vertices.size(); i++) - { - double x = m_closed ? i + 4 : i; - m_spline_x.add_point(x, m_src_vertices[i].x); - m_spline_y.add_point(x, m_src_vertices[i].y); - } - m_cur_abscissa = 0.0; - m_max_abscissa = m_src_vertices.size() - 1; - if(m_closed) - { - m_cur_abscissa = 4.0; - m_max_abscissa += 5.0; - m_spline_x.add_point(m_src_vertices.size() + 4, m_src_vertices[0].x); - m_spline_y.add_point(m_src_vertices.size() + 4, m_src_vertices[0].y); - m_spline_x.add_point(m_src_vertices.size() + 5, m_src_vertices[1].x); - m_spline_y.add_point(m_src_vertices.size() + 5, m_src_vertices[1].y); - m_spline_x.add_point(m_src_vertices.size() + 6, m_src_vertices[2].x); - m_spline_y.add_point(m_src_vertices.size() + 6, m_src_vertices[2].y); - m_spline_x.add_point(m_src_vertices.size() + 7, m_src_vertices.next(2).x); - m_spline_y.add_point(m_src_vertices.size() + 7, m_src_vertices.next(2).y); - } - m_spline_x.prepare(); - m_spline_y.prepare(); - } - m_status = ready; - } - - - - - - - //------------------------------------------------------------------------ - unsigned vcgen_bspline::vertex(double* x, double* y) - { - unsigned cmd = path_cmd_line_to; - while(!is_stop(cmd)) - { - switch(m_status) - { - case initial: - rewind(0); - - case ready: - if(m_src_vertices.size() < 2) - { - cmd = path_cmd_stop; - break; - } - - if(m_src_vertices.size() == 2) - { - *x = m_src_vertices[m_src_vertex].x; - *y = m_src_vertices[m_src_vertex].y; - m_src_vertex++; - if(m_src_vertex == 1) return path_cmd_move_to; - if(m_src_vertex == 2) return path_cmd_line_to; - cmd = path_cmd_stop; - break; - } - - cmd = path_cmd_move_to; - m_status = polygon; - m_src_vertex = 0; - - case polygon: - if(m_cur_abscissa >= m_max_abscissa) - { - if(m_closed) - { - m_status = end_poly; - break; - } - else - { - *x = m_src_vertices[m_src_vertices.size() - 1].x; - *y = m_src_vertices[m_src_vertices.size() - 1].y; - m_status = end_poly; - return path_cmd_line_to; - } - } - - *x = m_spline_x.get_stateful(m_cur_abscissa); - *y = m_spline_y.get_stateful(m_cur_abscissa); - m_src_vertex++; - m_cur_abscissa += m_interpolation_step; - return (m_src_vertex == 1) ? path_cmd_move_to : path_cmd_line_to; - - case end_poly: - m_status = stop; - return path_cmd_end_poly | m_closed; - - case stop: - return path_cmd_stop; - } - } - return cmd; - } - - -} - diff --git a/desmume/src/windows/agg/src/agg_vcgen_contour.cpp b/desmume/src/windows/agg/src/agg_vcgen_contour.cpp deleted file mode 100644 index 02c8b73ff..000000000 --- a/desmume/src/windows/agg/src/agg_vcgen_contour.cpp +++ /dev/null @@ -1,170 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#include -#include "agg_vcgen_contour.h" - -namespace agg -{ - - //------------------------------------------------------------------------ - vcgen_contour::vcgen_contour() : - m_stroker(), - m_width(1), - m_src_vertices(), - m_out_vertices(), - m_status(initial), - m_src_vertex(0), - m_closed(0), - m_orientation(0), - m_auto_detect(false) - { - } - - //------------------------------------------------------------------------ - void vcgen_contour::remove_all() - { - m_src_vertices.remove_all(); - m_closed = 0; - m_orientation = 0; - m_status = initial; - } - - //------------------------------------------------------------------------ - void vcgen_contour::add_vertex(double x, double y, unsigned cmd) - { - m_status = initial; - if(is_move_to(cmd)) - { - m_src_vertices.modify_last(vertex_dist(x, y)); - } - else - { - if(is_vertex(cmd)) - { - m_src_vertices.add(vertex_dist(x, y)); - } - else - { - if(is_end_poly(cmd)) - { - m_closed = get_close_flag(cmd); - if(m_orientation == path_flags_none) - { - m_orientation = get_orientation(cmd); - } - } - } - } - } - - //------------------------------------------------------------------------ - void vcgen_contour::rewind(unsigned) - { - if(m_status == initial) - { - m_src_vertices.close(true); - if(m_auto_detect) - { - if(!is_oriented(m_orientation)) - { - m_orientation = (calc_polygon_area(m_src_vertices) > 0.0) ? - path_flags_ccw : - path_flags_cw; - } - } - if(is_oriented(m_orientation)) - { - m_stroker.width(is_ccw(m_orientation) ? m_width : -m_width); - } - } - m_status = ready; - m_src_vertex = 0; - } - - //------------------------------------------------------------------------ - unsigned vcgen_contour::vertex(double* x, double* y) - { - unsigned cmd = path_cmd_line_to; - while(!is_stop(cmd)) - { - switch(m_status) - { - case initial: - rewind(0); - - case ready: - if(m_src_vertices.size() < 2 + unsigned(m_closed != 0)) - { - cmd = path_cmd_stop; - break; - } - m_status = outline; - cmd = path_cmd_move_to; - m_src_vertex = 0; - m_out_vertex = 0; - - case outline: - if(m_src_vertex >= m_src_vertices.size()) - { - m_status = end_poly; - break; - } - m_stroker.calc_join(m_out_vertices, - m_src_vertices.prev(m_src_vertex), - m_src_vertices.curr(m_src_vertex), - m_src_vertices.next(m_src_vertex), - m_src_vertices.prev(m_src_vertex).dist, - m_src_vertices.curr(m_src_vertex).dist); - ++m_src_vertex; - m_status = out_vertices; - m_out_vertex = 0; - - case out_vertices: - if(m_out_vertex >= m_out_vertices.size()) - { - m_status = outline; - } - else - { - const point_d& c = m_out_vertices[m_out_vertex++]; - *x = c.x; - *y = c.y; - return cmd; - } - break; - - case end_poly: - if(!m_closed) return path_cmd_stop; - m_status = stop; - return path_cmd_end_poly | path_flags_close | path_flags_ccw; - - case stop: - return path_cmd_stop; - } - } - return cmd; - } - -} diff --git a/desmume/src/windows/agg/src/agg_vcgen_dash.cpp b/desmume/src/windows/agg/src/agg_vcgen_dash.cpp deleted file mode 100644 index 60d2f9ac9..000000000 --- a/desmume/src/windows/agg/src/agg_vcgen_dash.cpp +++ /dev/null @@ -1,240 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#include -#include "agg_vcgen_dash.h" -#include "agg_shorten_path.h" - -namespace agg -{ - - //------------------------------------------------------------------------ - vcgen_dash::vcgen_dash() : - m_total_dash_len(0.0), - m_num_dashes(0), - m_dash_start(0.0), - m_shorten(0.0), - m_curr_dash_start(0.0), - m_curr_dash(0), - m_src_vertices(), - m_closed(0), - m_status(initial), - m_src_vertex(0) - { - } - - - - //------------------------------------------------------------------------ - void vcgen_dash::remove_all_dashes() - { - m_total_dash_len = 0.0; - m_num_dashes = 0; - m_curr_dash_start = 0.0; - m_curr_dash = 0; - } - - - //------------------------------------------------------------------------ - void vcgen_dash::add_dash(double dash_len, double gap_len) - { - if(m_num_dashes < max_dashes) - { - m_total_dash_len += dash_len + gap_len; - m_dashes[m_num_dashes++] = dash_len; - m_dashes[m_num_dashes++] = gap_len; - } - } - - - //------------------------------------------------------------------------ - void vcgen_dash::dash_start(double ds) - { - m_dash_start = ds; - calc_dash_start(fabs(ds)); - } - - - //------------------------------------------------------------------------ - void vcgen_dash::calc_dash_start(double ds) - { - m_curr_dash = 0; - m_curr_dash_start = 0.0; - while(ds > 0.0) - { - if(ds > m_dashes[m_curr_dash]) - { - ds -= m_dashes[m_curr_dash]; - ++m_curr_dash; - m_curr_dash_start = 0.0; - if(m_curr_dash >= m_num_dashes) m_curr_dash = 0; - } - else - { - m_curr_dash_start = ds; - ds = 0.0; - } - } - } - - - //------------------------------------------------------------------------ - void vcgen_dash::remove_all() - { - m_status = initial; - m_src_vertices.remove_all(); - m_closed = 0; - } - - - //------------------------------------------------------------------------ - void vcgen_dash::add_vertex(double x, double y, unsigned cmd) - { - m_status = initial; - if(is_move_to(cmd)) - { - m_src_vertices.modify_last(vertex_dist(x, y)); - } - else - { - if(is_vertex(cmd)) - { - m_src_vertices.add(vertex_dist(x, y)); - } - else - { - m_closed = get_close_flag(cmd); - } - } - } - - - //------------------------------------------------------------------------ - void vcgen_dash::rewind(unsigned) - { - if(m_status == initial) - { - m_src_vertices.close(m_closed != 0); - shorten_path(m_src_vertices, m_shorten, m_closed); - } - m_status = ready; - m_src_vertex = 0; - } - - - //------------------------------------------------------------------------ - unsigned vcgen_dash::vertex(double* x, double* y) - { - unsigned cmd = path_cmd_move_to; - while(!is_stop(cmd)) - { - switch(m_status) - { - case initial: - rewind(0); - - case ready: - if(m_num_dashes < 2 || m_src_vertices.size() < 2) - { - cmd = path_cmd_stop; - break; - } - m_status = polyline; - m_src_vertex = 1; - m_v1 = &m_src_vertices[0]; - m_v2 = &m_src_vertices[1]; - m_curr_rest = m_v1->dist; - *x = m_v1->x; - *y = m_v1->y; - if(m_dash_start >= 0.0) calc_dash_start(m_dash_start); - return path_cmd_move_to; - - case polyline: - { - double dash_rest = m_dashes[m_curr_dash] - m_curr_dash_start; - - unsigned cmd = (m_curr_dash & 1) ? - path_cmd_move_to : - path_cmd_line_to; - - if(m_curr_rest > dash_rest) - { - m_curr_rest -= dash_rest; - ++m_curr_dash; - if(m_curr_dash >= m_num_dashes) m_curr_dash = 0; - m_curr_dash_start = 0.0; - *x = m_v2->x - (m_v2->x - m_v1->x) * m_curr_rest / m_v1->dist; - *y = m_v2->y - (m_v2->y - m_v1->y) * m_curr_rest / m_v1->dist; - } - else - { - m_curr_dash_start += m_curr_rest; - *x = m_v2->x; - *y = m_v2->y; - ++m_src_vertex; - m_v1 = m_v2; - m_curr_rest = m_v1->dist; - if(m_closed) - { - if(m_src_vertex > m_src_vertices.size()) - { - m_status = stop; - } - else - { - m_v2 = &m_src_vertices - [ - (m_src_vertex >= m_src_vertices.size()) ? 0 : - m_src_vertex - ]; - } - } - else - { - if(m_src_vertex >= m_src_vertices.size()) - { - m_status = stop; - } - else - { - m_v2 = &m_src_vertices[m_src_vertex]; - } - } - } - return cmd; - } - break; - - case stop: - cmd = path_cmd_stop; - break; - } - - } - return path_cmd_stop; - } - - -} - diff --git a/desmume/src/windows/agg/src/agg_vcgen_markers_term.cpp b/desmume/src/windows/agg/src/agg_vcgen_markers_term.cpp deleted file mode 100644 index 5863691f6..000000000 --- a/desmume/src/windows/agg/src/agg_vcgen_markers_term.cpp +++ /dev/null @@ -1,108 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#include "agg_vcgen_markers_term.h" - -namespace agg -{ - - //------------------------------------------------------------------------ - void vcgen_markers_term::remove_all() - { - m_markers.remove_all(); - } - - - //------------------------------------------------------------------------ - void vcgen_markers_term::add_vertex(double x, double y, unsigned cmd) - { - if(is_move_to(cmd)) - { - if(m_markers.size() & 1) - { - // Initial state, the first coordinate was added. - // If two of more calls of start_vertex() occures - // we just modify the last one. - m_markers.modify_last(coord_type(x, y)); - } - else - { - m_markers.add(coord_type(x, y)); - } - } - else - { - if(is_vertex(cmd)) - { - if(m_markers.size() & 1) - { - // Initial state, the first coordinate was added. - // Add three more points, 0,1,1,0 - m_markers.add(coord_type(x, y)); - m_markers.add(m_markers[m_markers.size() - 1]); - m_markers.add(m_markers[m_markers.size() - 3]); - } - else - { - if(m_markers.size()) - { - // Replace two last points: 0,1,1,0 -> 0,1,2,1 - m_markers[m_markers.size() - 1] = m_markers[m_markers.size() - 2]; - m_markers[m_markers.size() - 2] = coord_type(x, y); - } - } - } - } - } - - - //------------------------------------------------------------------------ - void vcgen_markers_term::rewind(unsigned path_id) - { - m_curr_id = path_id * 2; - m_curr_idx = m_curr_id; - } - - - //------------------------------------------------------------------------ - unsigned vcgen_markers_term::vertex(double* x, double* y) - { - if(m_curr_id > 2 || m_curr_idx >= m_markers.size()) - { - return path_cmd_stop; - } - const coord_type& c = m_markers[m_curr_idx]; - *x = c.x; - *y = c.y; - if(m_curr_idx & 1) - { - m_curr_idx += 3; - return path_cmd_line_to; - } - ++m_curr_idx; - return path_cmd_move_to; - } - - -} diff --git a/desmume/src/windows/agg/src/agg_vcgen_smooth_poly1.cpp b/desmume/src/windows/agg/src/agg_vcgen_smooth_poly1.cpp deleted file mode 100644 index 359768aa7..000000000 --- a/desmume/src/windows/agg/src/agg_vcgen_smooth_poly1.cpp +++ /dev/null @@ -1,230 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#include "agg_vcgen_smooth_poly1.h" - -namespace agg -{ - - //------------------------------------------------------------------------ - vcgen_smooth_poly1::vcgen_smooth_poly1() : - m_src_vertices(), - m_smooth_value(0.5), - m_closed(0), - m_status(initial), - m_src_vertex(0) - { - } - - - //------------------------------------------------------------------------ - void vcgen_smooth_poly1::remove_all() - { - m_src_vertices.remove_all(); - m_closed = 0; - m_status = initial; - } - - - //------------------------------------------------------------------------ - void vcgen_smooth_poly1::add_vertex(double x, double y, unsigned cmd) - { - m_status = initial; - if(is_move_to(cmd)) - { - m_src_vertices.modify_last(vertex_dist(x, y)); - } - else - { - if(is_vertex(cmd)) - { - m_src_vertices.add(vertex_dist(x, y)); - } - else - { - m_closed = get_close_flag(cmd); - } - } - } - - - //------------------------------------------------------------------------ - void vcgen_smooth_poly1::rewind(unsigned) - { - if(m_status == initial) - { - m_src_vertices.close(m_closed != 0); - } - m_status = ready; - m_src_vertex = 0; - } - - - //------------------------------------------------------------------------ - void vcgen_smooth_poly1::calculate(const vertex_dist& v0, - const vertex_dist& v1, - const vertex_dist& v2, - const vertex_dist& v3) - { - - double k1 = v0.dist / (v0.dist + v1.dist); - double k2 = v1.dist / (v1.dist + v2.dist); - - double xm1 = v0.x + (v2.x - v0.x) * k1; - double ym1 = v0.y + (v2.y - v0.y) * k1; - double xm2 = v1.x + (v3.x - v1.x) * k2; - double ym2 = v1.y + (v3.y - v1.y) * k2; - - m_ctrl1_x = v1.x + m_smooth_value * (v2.x - xm1); - m_ctrl1_y = v1.y + m_smooth_value * (v2.y - ym1); - m_ctrl2_x = v2.x + m_smooth_value * (v1.x - xm2); - m_ctrl2_y = v2.y + m_smooth_value * (v1.y - ym2); - } - - - //------------------------------------------------------------------------ - unsigned vcgen_smooth_poly1::vertex(double* x, double* y) - { - unsigned cmd = path_cmd_line_to; - while(!is_stop(cmd)) - { - switch(m_status) - { - case initial: - rewind(0); - - case ready: - if(m_src_vertices.size() < 2) - { - cmd = path_cmd_stop; - break; - } - - if(m_src_vertices.size() == 2) - { - *x = m_src_vertices[m_src_vertex].x; - *y = m_src_vertices[m_src_vertex].y; - m_src_vertex++; - if(m_src_vertex == 1) return path_cmd_move_to; - if(m_src_vertex == 2) return path_cmd_line_to; - cmd = path_cmd_stop; - break; - } - - cmd = path_cmd_move_to; - m_status = polygon; - m_src_vertex = 0; - - case polygon: - if(m_closed) - { - if(m_src_vertex >= m_src_vertices.size()) - { - *x = m_src_vertices[0].x; - *y = m_src_vertices[0].y; - m_status = end_poly; - return path_cmd_curve4; - } - } - else - { - if(m_src_vertex >= m_src_vertices.size() - 1) - { - *x = m_src_vertices[m_src_vertices.size() - 1].x; - *y = m_src_vertices[m_src_vertices.size() - 1].y; - m_status = end_poly; - return path_cmd_curve3; - } - } - - calculate(m_src_vertices.prev(m_src_vertex), - m_src_vertices.curr(m_src_vertex), - m_src_vertices.next(m_src_vertex), - m_src_vertices.next(m_src_vertex + 1)); - - *x = m_src_vertices[m_src_vertex].x; - *y = m_src_vertices[m_src_vertex].y; - m_src_vertex++; - - if(m_closed) - { - m_status = ctrl1; - return ((m_src_vertex == 1) ? - path_cmd_move_to : - path_cmd_curve4); - } - else - { - if(m_src_vertex == 1) - { - m_status = ctrl_b; - return path_cmd_move_to; - } - if(m_src_vertex >= m_src_vertices.size() - 1) - { - m_status = ctrl_e; - return path_cmd_curve3; - } - m_status = ctrl1; - return path_cmd_curve4; - } - break; - - case ctrl_b: - *x = m_ctrl2_x; - *y = m_ctrl2_y; - m_status = polygon; - return path_cmd_curve3; - - case ctrl_e: - *x = m_ctrl1_x; - *y = m_ctrl1_y; - m_status = polygon; - return path_cmd_curve3; - - case ctrl1: - *x = m_ctrl1_x; - *y = m_ctrl1_y; - m_status = ctrl2; - return path_cmd_curve4; - - case ctrl2: - *x = m_ctrl2_x; - *y = m_ctrl2_y; - m_status = polygon; - return path_cmd_curve4; - - case end_poly: - m_status = stop; - return path_cmd_end_poly | m_closed; - - case stop: - return path_cmd_stop; - } - } - return cmd; - } - -} - diff --git a/desmume/src/windows/agg/src/agg_vcgen_stroke.cpp b/desmume/src/windows/agg/src/agg_vcgen_stroke.cpp deleted file mode 100644 index b36927bf3..000000000 --- a/desmume/src/windows/agg/src/agg_vcgen_stroke.cpp +++ /dev/null @@ -1,219 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#include -#include "agg_vcgen_stroke.h" -#include "agg_shorten_path.h" - -namespace agg -{ - - //------------------------------------------------------------------------ - vcgen_stroke::vcgen_stroke() : - m_stroker(), - m_src_vertices(), - m_out_vertices(), - m_shorten(0.0), - m_closed(0), - m_status(initial), - m_src_vertex(0), - m_out_vertex(0) - { - } - - //------------------------------------------------------------------------ - void vcgen_stroke::remove_all() - { - m_src_vertices.remove_all(); - m_closed = 0; - m_status = initial; - } - - - //------------------------------------------------------------------------ - void vcgen_stroke::add_vertex(double x, double y, unsigned cmd) - { - m_status = initial; - if(is_move_to(cmd)) - { - m_src_vertices.modify_last(vertex_dist(x, y)); - } - else - { - if(is_vertex(cmd)) - { - m_src_vertices.add(vertex_dist(x, y)); - } - else - { - m_closed = get_close_flag(cmd); - } - } - } - - //------------------------------------------------------------------------ - void vcgen_stroke::rewind(unsigned) - { - if(m_status == initial) - { - m_src_vertices.close(m_closed != 0); - shorten_path(m_src_vertices, m_shorten, m_closed); - if(m_src_vertices.size() < 3) m_closed = 0; - } - m_status = ready; - m_src_vertex = 0; - m_out_vertex = 0; - } - - - //------------------------------------------------------------------------ - unsigned vcgen_stroke::vertex(double* x, double* y) - { - unsigned cmd = path_cmd_line_to; - while(!is_stop(cmd)) - { - switch(m_status) - { - case initial: - rewind(0); - - case ready: - if(m_src_vertices.size() < 2 + unsigned(m_closed != 0)) - { - cmd = path_cmd_stop; - break; - } - m_status = m_closed ? outline1 : cap1; - cmd = path_cmd_move_to; - m_src_vertex = 0; - m_out_vertex = 0; - break; - - case cap1: - m_stroker.calc_cap(m_out_vertices, - m_src_vertices[0], - m_src_vertices[1], - m_src_vertices[0].dist); - m_src_vertex = 1; - m_prev_status = outline1; - m_status = out_vertices; - m_out_vertex = 0; - break; - - case cap2: - m_stroker.calc_cap(m_out_vertices, - m_src_vertices[m_src_vertices.size() - 1], - m_src_vertices[m_src_vertices.size() - 2], - m_src_vertices[m_src_vertices.size() - 2].dist); - m_prev_status = outline2; - m_status = out_vertices; - m_out_vertex = 0; - break; - - case outline1: - if(m_closed) - { - if(m_src_vertex >= m_src_vertices.size()) - { - m_prev_status = close_first; - m_status = end_poly1; - break; - } - } - else - { - if(m_src_vertex >= m_src_vertices.size() - 1) - { - m_status = cap2; - break; - } - } - m_stroker.calc_join(m_out_vertices, - m_src_vertices.prev(m_src_vertex), - m_src_vertices.curr(m_src_vertex), - m_src_vertices.next(m_src_vertex), - m_src_vertices.prev(m_src_vertex).dist, - m_src_vertices.curr(m_src_vertex).dist); - ++m_src_vertex; - m_prev_status = m_status; - m_status = out_vertices; - m_out_vertex = 0; - break; - - case close_first: - m_status = outline2; - cmd = path_cmd_move_to; - - case outline2: - if(m_src_vertex <= unsigned(m_closed == 0)) - { - m_status = end_poly2; - m_prev_status = stop; - break; - } - - --m_src_vertex; - m_stroker.calc_join(m_out_vertices, - m_src_vertices.next(m_src_vertex), - m_src_vertices.curr(m_src_vertex), - m_src_vertices.prev(m_src_vertex), - m_src_vertices.curr(m_src_vertex).dist, - m_src_vertices.prev(m_src_vertex).dist); - - m_prev_status = m_status; - m_status = out_vertices; - m_out_vertex = 0; - break; - - case out_vertices: - if(m_out_vertex >= m_out_vertices.size()) - { - m_status = m_prev_status; - } - else - { - const point_d& c = m_out_vertices[m_out_vertex++]; - *x = c.x; - *y = c.y; - return cmd; - } - break; - - case end_poly1: - m_status = m_prev_status; - return path_cmd_end_poly | path_flags_close | path_flags_ccw; - - case end_poly2: - m_status = m_prev_status; - return path_cmd_end_poly | path_flags_close | path_flags_cw; - - case stop: - cmd = path_cmd_stop; - break; - } - } - return cmd; - } - -} diff --git a/desmume/src/windows/agg/src/agg_vpgen_clip_polygon.cpp b/desmume/src/windows/agg/src/agg_vpgen_clip_polygon.cpp deleted file mode 100644 index 2e9502ce0..000000000 --- a/desmume/src/windows/agg/src/agg_vpgen_clip_polygon.cpp +++ /dev/null @@ -1,142 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#include "agg_vpgen_clip_polygon.h" -#include "agg_clip_liang_barsky.h" - -namespace agg -{ - - //------------------------------------------------------------------------ - // Determine the clipping code of the vertex according to the - // Cyrus-Beck line clipping algorithm - // - // | | - // 0110 | 0010 | 0011 - // | | - // -------+--------+-------- clip_box.y2 - // | | - // 0100 | 0000 | 0001 - // | | - // -------+--------+-------- clip_box.y1 - // | | - // 1100 | 1000 | 1001 - // | | - // clip_box.x1 clip_box.x2 - // - // - unsigned vpgen_clip_polygon::clipping_flags(double x, double y) - { - if(x < m_clip_box.x1) - { - if(y > m_clip_box.y2) return 6; - if(y < m_clip_box.y1) return 12; - return 4; - } - - if(x > m_clip_box.x2) - { - if(y > m_clip_box.y2) return 3; - if(y < m_clip_box.y1) return 9; - return 1; - } - - if(y > m_clip_box.y2) return 2; - if(y < m_clip_box.y1) return 8; - - return 0; - } - - //---------------------------------------------------------------------------- - void vpgen_clip_polygon::reset() - { - m_vertex = 0; - m_num_vertices = 0; - } - - //---------------------------------------------------------------------------- - void vpgen_clip_polygon::move_to(double x, double y) - { - m_vertex = 0; - m_num_vertices = 0; - m_clip_flags = clipping_flags(x, y); - if(m_clip_flags == 0) - { - m_x[0] = x; - m_y[0] = y; - m_num_vertices = 1; - } - m_x1 = x; - m_y1 = y; - m_cmd = path_cmd_move_to; - } - - - //---------------------------------------------------------------------------- - void vpgen_clip_polygon::line_to(double x, double y) - { - m_vertex = 0; - m_num_vertices = 0; - unsigned flags = clipping_flags(x, y); - - if(m_clip_flags == flags) - { - if(flags == 0) - { - m_x[0] = x; - m_y[0] = y; - m_num_vertices = 1; - } - } - else - { - m_num_vertices = clip_liang_barsky(m_x1, m_y1, - x, y, - m_clip_box, - m_x, m_y); - } - - m_clip_flags = flags; - m_x1 = x; - m_y1 = y; - } - - - //---------------------------------------------------------------------------- - unsigned vpgen_clip_polygon::vertex(double* x, double* y) - { - if(m_vertex < m_num_vertices) - { - *x = m_x[m_vertex]; - *y = m_y[m_vertex]; - ++m_vertex; - unsigned cmd = m_cmd; - m_cmd = path_cmd_line_to; - return cmd; - } - return path_cmd_stop; - } - - -} diff --git a/desmume/src/windows/agg/src/agg_vpgen_clip_polyline.cpp b/desmume/src/windows/agg/src/agg_vpgen_clip_polyline.cpp deleted file mode 100644 index 9b2f72680..000000000 --- a/desmume/src/windows/agg/src/agg_vpgen_clip_polyline.cpp +++ /dev/null @@ -1,86 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#include "agg_vpgen_clip_polyline.h" -#include "agg_clip_liang_barsky.h" - -namespace agg -{ - //---------------------------------------------------------------------------- - void vpgen_clip_polyline::reset() - { - m_vertex = 0; - m_num_vertices = 0; - m_move_to = false; - } - - //---------------------------------------------------------------------------- - void vpgen_clip_polyline::move_to(double x, double y) - { - m_vertex = 0; - m_num_vertices = 0; - m_x1 = x; - m_y1 = y; - m_move_to = true; - } - - //---------------------------------------------------------------------------- - void vpgen_clip_polyline::line_to(double x, double y) - { - double x2 = x; - double y2 = y; - unsigned flags = clip_line_segment(&m_x1, &m_y1, &x2, &y2, m_clip_box); - - m_vertex = 0; - m_num_vertices = 0; - if((flags & 4) == 0) - { - if((flags & 1) != 0 || m_move_to) - { - m_x[0] = m_x1; - m_y[0] = m_y1; - m_cmd[0] = path_cmd_move_to; - m_num_vertices = 1; - } - m_x[m_num_vertices] = x2; - m_y[m_num_vertices] = y2; - m_cmd[m_num_vertices++] = path_cmd_line_to; - m_move_to = (flags & 2) != 0; - } - m_x1 = x; - m_y1 = y; - } - - //---------------------------------------------------------------------------- - unsigned vpgen_clip_polyline::vertex(double* x, double* y) - { - if(m_vertex < m_num_vertices) - { - *x = m_x[m_vertex]; - *y = m_y[m_vertex]; - return m_cmd[m_vertex++]; - } - return path_cmd_stop; - } -} diff --git a/desmume/src/windows/agg/src/agg_vpgen_segmentator.cpp b/desmume/src/windows/agg/src/agg_vpgen_segmentator.cpp deleted file mode 100644 index eb5df3f34..000000000 --- a/desmume/src/windows/agg/src/agg_vpgen_segmentator.cpp +++ /dev/null @@ -1,76 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#include -#include "agg_vpgen_segmentator.h" - -namespace agg -{ - - void vpgen_segmentator::move_to(double x, double y) - { - m_x1 = x; - m_y1 = y; - m_dx = 0.0; - m_dy = 0.0; - m_dl = 2.0; - m_ddl = 2.0; - m_cmd = path_cmd_move_to; - } - - void vpgen_segmentator::line_to(double x, double y) - { - m_x1 += m_dx; - m_y1 += m_dy; - m_dx = x - m_x1; - m_dy = y - m_y1; - double len = sqrt(m_dx * m_dx + m_dy * m_dy) * m_approximation_scale; - if(len < 1e-30) len = 1e-30; - m_ddl = 1.0 / len; - m_dl = (m_cmd == path_cmd_move_to) ? 0.0 : m_ddl; - if(m_cmd == path_cmd_stop) m_cmd = path_cmd_line_to; - } - - unsigned vpgen_segmentator::vertex(double* x, double* y) - { - if(m_cmd == path_cmd_stop) return path_cmd_stop; - - unsigned cmd = m_cmd; - m_cmd = path_cmd_line_to; - if(m_dl >= 1.0 - m_ddl) - { - m_dl = 1.0; - m_cmd = path_cmd_stop; - *x = m_x1 + m_dx; - *y = m_y1 + m_dy; - return cmd; - } - *x = m_x1 + m_dx * m_dl; - *y = m_y1 + m_dy * m_dl; - m_dl += m_ddl; - return cmd; - } - -} - diff --git a/desmume/src/windows/agg/src/authors b/desmume/src/windows/agg/src/authors deleted file mode 100644 index e69de29bb..000000000 diff --git a/desmume/src/windows/agg/src/autogen.sh b/desmume/src/windows/agg/src/autogen.sh deleted file mode 100644 index d37d8e2b9..000000000 --- a/desmume/src/windows/agg/src/autogen.sh +++ /dev/null @@ -1,20 +0,0 @@ -# autogen.sh -# -# invoke the auto* tools to create the configureation system - -# build aclocal.m4 -aclocal - -# build the configure script -autoconf - -# set up libtool -libtoolize --force - -# invoke automake -automake --foreign --add-missing - -# and finally invoke our new configure -./configure $* - -# end diff --git a/desmume/src/windows/agg/src/configure.in b/desmume/src/windows/agg/src/configure.in deleted file mode 100644 index fe58b4290..000000000 --- a/desmume/src/windows/agg/src/configure.in +++ /dev/null @@ -1,15 +0,0 @@ -AC_INIT(src/agg_arc.cpp) # give me a source file, any source file... -AM_INIT_AUTOMAKE(agg, 2.0.0) - -AC_PROG_LN_S -AC_PROG_CC -AC_PROG_CPP -AC_PROG_CXX -AC_PROG_LIBTOOL - -AC_OUTPUT( - Makefile - gpc/Makefile - src/Makefile - src/ctrl/Makefile -) diff --git a/desmume/src/windows/agg/src/copying b/desmume/src/windows/agg/src/copying deleted file mode 100644 index a88fd34d7..000000000 --- a/desmume/src/windows/agg/src/copying +++ /dev/null @@ -1,21 +0,0 @@ -Anti-Grain Geometry (AGG) - Version 2.5 -A high quality rendering engine for C++ -Copyright (C) 2002-2006 Maxim Shemanarev -Contact: mcseem@antigrain.com - mcseemagg@yahoo.com - http://antigrain.com - -AGG is free software; you can redistribute it and/or -modify it under the terms of the GNU General Public License -as published by the Free Software Foundation; either version 2 -of the License, or (at your option) any later version. - -AGG is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License -along with AGG; if not, write to the Free Software -Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -MA 02110-1301, USA. diff --git a/desmume/src/windows/agg/src/ctrl/agg_bezier_ctrl.cpp b/desmume/src/windows/agg/src/ctrl/agg_bezier_ctrl.cpp deleted file mode 100644 index ff278bd49..000000000 --- a/desmume/src/windows/agg/src/ctrl/agg_bezier_ctrl.cpp +++ /dev/null @@ -1,375 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#include -#include -#include "ctrl/agg_bezier_ctrl.h" - -namespace agg -{ - - //------------------------------------------------------------------------ - bezier_ctrl_impl::bezier_ctrl_impl() : - ctrl(0,0,1,1,false), - m_stroke(m_curve), - m_poly(4, 5.0), - m_idx(0) - { - m_poly.in_polygon_check(false); - m_poly.xn(0) = 100.0; - m_poly.yn(0) = 0.0; - m_poly.xn(1) = 100.0; - m_poly.yn(1) = 50.0; - m_poly.xn(2) = 50.0; - m_poly.yn(2) = 100.0; - m_poly.xn(3) = 0.0; - m_poly.yn(3) = 100.0; - } - - - //------------------------------------------------------------------------ - void bezier_ctrl_impl::curve(double x1, double y1, - double x2, double y2, - double x3, double y3, - double x4, double y4) - { - m_poly.xn(0) = x1; - m_poly.yn(0) = y1; - m_poly.xn(1) = x2; - m_poly.yn(1) = y2; - m_poly.xn(2) = x3; - m_poly.yn(2) = y3; - m_poly.xn(3) = x4; - m_poly.yn(3) = y4; - curve(); - } - - //------------------------------------------------------------------------ - curve4& bezier_ctrl_impl::curve() - { - m_curve.init(m_poly.xn(0), m_poly.yn(0), - m_poly.xn(1), m_poly.yn(1), - m_poly.xn(2), m_poly.yn(2), - m_poly.xn(3), m_poly.yn(3)); - return m_curve; - } - - //------------------------------------------------------------------------ - void bezier_ctrl_impl::rewind(unsigned idx) - { - m_idx = idx; - - m_curve.approximation_scale(scale()); - switch(idx) - { - default: - case 0: // Control line 1 - m_curve.init(m_poly.xn(0), m_poly.yn(0), - (m_poly.xn(0) + m_poly.xn(1)) * 0.5, - (m_poly.yn(0) + m_poly.yn(1)) * 0.5, - (m_poly.xn(0) + m_poly.xn(1)) * 0.5, - (m_poly.yn(0) + m_poly.yn(1)) * 0.5, - m_poly.xn(1), m_poly.yn(1)); - m_stroke.rewind(0); - break; - - case 1: // Control line 2 - m_curve.init(m_poly.xn(2), m_poly.yn(2), - (m_poly.xn(2) + m_poly.xn(3)) * 0.5, - (m_poly.yn(2) + m_poly.yn(3)) * 0.5, - (m_poly.xn(2) + m_poly.xn(3)) * 0.5, - (m_poly.yn(2) + m_poly.yn(3)) * 0.5, - m_poly.xn(3), m_poly.yn(3)); - m_stroke.rewind(0); - break; - - case 2: // Curve itself - m_curve.init(m_poly.xn(0), m_poly.yn(0), - m_poly.xn(1), m_poly.yn(1), - m_poly.xn(2), m_poly.yn(2), - m_poly.xn(3), m_poly.yn(3)); - m_stroke.rewind(0); - break; - - case 3: // Point 1 - m_ellipse.init(m_poly.xn(0), m_poly.yn(0), point_radius(), point_radius(), 20); - m_ellipse.rewind(0); - break; - - case 4: // Point 2 - m_ellipse.init(m_poly.xn(1), m_poly.yn(1), point_radius(), point_radius(), 20); - m_ellipse.rewind(0); - break; - - case 5: // Point 3 - m_ellipse.init(m_poly.xn(2), m_poly.yn(2), point_radius(), point_radius(), 20); - m_ellipse.rewind(0); - break; - - case 6: // Point 4 - m_ellipse.init(m_poly.xn(3), m_poly.yn(3), point_radius(), point_radius(), 20); - m_ellipse.rewind(0); - break; - } - } - - - //------------------------------------------------------------------------ - unsigned bezier_ctrl_impl::vertex(double* x, double* y) - { - unsigned cmd = path_cmd_stop; - switch(m_idx) - { - case 0: - case 1: - case 2: - cmd = m_stroke.vertex(x, y); - break; - - case 3: - case 4: - case 5: - case 6: - case 7: - cmd = m_ellipse.vertex(x, y); - break; - } - - if(!is_stop(cmd)) - { - transform_xy(x, y); - } - return cmd; - } - - - - //------------------------------------------------------------------------ - bool bezier_ctrl_impl::in_rect(double x, double y) const - { - return false; - } - - - //------------------------------------------------------------------------ - bool bezier_ctrl_impl::on_mouse_button_down(double x, double y) - { - inverse_transform_xy(&x, &y); - return m_poly.on_mouse_button_down(x, y); - } - - - //------------------------------------------------------------------------ - bool bezier_ctrl_impl::on_mouse_move(double x, double y, bool button_flag) - { - inverse_transform_xy(&x, &y); - return m_poly.on_mouse_move(x, y, button_flag); - } - - - //------------------------------------------------------------------------ - bool bezier_ctrl_impl::on_mouse_button_up(double x, double y) - { - return m_poly.on_mouse_button_up(x, y); - } - - - //------------------------------------------------------------------------ - bool bezier_ctrl_impl::on_arrow_keys(bool left, bool right, bool down, bool up) - { - return m_poly.on_arrow_keys(left, right, down, up); - } - - - - - - - //------------------------------------------------------------------------ - curve3_ctrl_impl::curve3_ctrl_impl() : - ctrl(0,0,1,1,false), - m_stroke(m_curve), - m_poly(3, 5.0), - m_idx(0) - { - m_poly.in_polygon_check(false); - m_poly.xn(0) = 100.0; - m_poly.yn(0) = 0.0; - m_poly.xn(1) = 100.0; - m_poly.yn(1) = 50.0; - m_poly.xn(2) = 50.0; - m_poly.yn(2) = 100.0; - } - - - //------------------------------------------------------------------------ - void curve3_ctrl_impl::curve(double x1, double y1, - double x2, double y2, - double x3, double y3) - { - m_poly.xn(0) = x1; - m_poly.yn(0) = y1; - m_poly.xn(1) = x2; - m_poly.yn(1) = y2; - m_poly.xn(2) = x3; - m_poly.yn(2) = y3; - curve(); - } - - //------------------------------------------------------------------------ - curve3& curve3_ctrl_impl::curve() - { - m_curve.init(m_poly.xn(0), m_poly.yn(0), - m_poly.xn(1), m_poly.yn(1), - m_poly.xn(2), m_poly.yn(2)); - return m_curve; - } - - //------------------------------------------------------------------------ - void curve3_ctrl_impl::rewind(unsigned idx) - { - m_idx = idx; - - switch(idx) - { - default: - case 0: // Control line - m_curve.init(m_poly.xn(0), m_poly.yn(0), - (m_poly.xn(0) + m_poly.xn(1)) * 0.5, - (m_poly.yn(0) + m_poly.yn(1)) * 0.5, - m_poly.xn(1), m_poly.yn(1)); - m_stroke.rewind(0); - break; - - case 1: // Control line 2 - m_curve.init(m_poly.xn(1), m_poly.yn(1), - (m_poly.xn(1) + m_poly.xn(2)) * 0.5, - (m_poly.yn(1) + m_poly.yn(2)) * 0.5, - m_poly.xn(2), m_poly.yn(2)); - m_stroke.rewind(0); - break; - - case 2: // Curve itself - m_curve.init(m_poly.xn(0), m_poly.yn(0), - m_poly.xn(1), m_poly.yn(1), - m_poly.xn(2), m_poly.yn(2)); - m_stroke.rewind(0); - break; - - case 3: // Point 1 - m_ellipse.init(m_poly.xn(0), m_poly.yn(0), point_radius(), point_radius(), 20); - m_ellipse.rewind(0); - break; - - case 4: // Point 2 - m_ellipse.init(m_poly.xn(1), m_poly.yn(1), point_radius(), point_radius(), 20); - m_ellipse.rewind(0); - break; - - case 5: // Point 3 - m_ellipse.init(m_poly.xn(2), m_poly.yn(2), point_radius(), point_radius(), 20); - m_ellipse.rewind(0); - break; - } - } - - - //------------------------------------------------------------------------ - unsigned curve3_ctrl_impl::vertex(double* x, double* y) - { - unsigned cmd = path_cmd_stop; - switch(m_idx) - { - case 0: - case 1: - case 2: - cmd = m_stroke.vertex(x, y); - break; - - case 3: - case 4: - case 5: - case 6: - cmd = m_ellipse.vertex(x, y); - break; - } - - if(!is_stop(cmd)) - { - transform_xy(x, y); - } - return cmd; - } - - - - //------------------------------------------------------------------------ - bool curve3_ctrl_impl::in_rect(double x, double y) const - { - return false; - } - - - //------------------------------------------------------------------------ - bool curve3_ctrl_impl::on_mouse_button_down(double x, double y) - { - inverse_transform_xy(&x, &y); - return m_poly.on_mouse_button_down(x, y); - } - - - //------------------------------------------------------------------------ - bool curve3_ctrl_impl::on_mouse_move(double x, double y, bool button_flag) - { - inverse_transform_xy(&x, &y); - return m_poly.on_mouse_move(x, y, button_flag); - } - - - //------------------------------------------------------------------------ - bool curve3_ctrl_impl::on_mouse_button_up(double x, double y) - { - return m_poly.on_mouse_button_up(x, y); - } - - - //------------------------------------------------------------------------ - bool curve3_ctrl_impl::on_arrow_keys(bool left, bool right, bool down, bool up) - { - return m_poly.on_arrow_keys(left, right, down, up); - } - - - - - - - - - - - - -} - diff --git a/desmume/src/windows/agg/src/ctrl/agg_cbox_ctrl.cpp b/desmume/src/windows/agg/src/ctrl/agg_cbox_ctrl.cpp deleted file mode 100644 index 3753475ca..000000000 --- a/desmume/src/windows/agg/src/ctrl/agg_cbox_ctrl.cpp +++ /dev/null @@ -1,219 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#include -#include "ctrl/agg_cbox_ctrl.h" - - -namespace agg -{ - - //------------------------------------------------------------------------ - cbox_ctrl_impl::cbox_ctrl_impl(double x, double y, - const char* l, - bool flip_y) : - ctrl(x, y, x + 9.0 * 1.5, y + 9.0 * 1.5, flip_y), - m_text_thickness(1.5), - m_text_height(9.0), - m_text_width(0.0), - m_status(false), - m_text_poly(m_text) - { - label(l); - } - - - //------------------------------------------------------------------------ - void cbox_ctrl_impl::text_size(double h, double w) - { - m_text_width = w; - m_text_height = h; - } - - //------------------------------------------------------------------------ - void cbox_ctrl_impl::label(const char* l) - { - unsigned len = strlen(l); - if(len > 127) len = 127; - memcpy(m_label, l, len); - m_label[len] = 0; - } - - - //------------------------------------------------------------------------ - bool cbox_ctrl_impl::on_mouse_button_down(double x, double y) - { - inverse_transform_xy(&x, &y); - if(x >= m_x1 && y >= m_y1 && x <= m_x2 && y <= m_y2) - { - m_status = !m_status; - return true; - } - return false; - } - - - //------------------------------------------------------------------------ - bool cbox_ctrl_impl::on_mouse_move(double, double, bool) - { - return false; - } - - //------------------------------------------------------------------------ - bool cbox_ctrl_impl::in_rect(double x, double y) const - { - inverse_transform_xy(&x, &y); - return x >= m_x1 && y >= m_y1 && x <= m_x2 && y <= m_y2; - } - - //------------------------------------------------------------------------ - bool cbox_ctrl_impl::on_mouse_button_up(double, double) - { - return false; - } - - //------------------------------------------------------------------------ - bool cbox_ctrl_impl::on_arrow_keys(bool, bool, bool, bool) - { - return false; - } - - - //------------------------------------------------------------------------ - void cbox_ctrl_impl::rewind(unsigned idx) - { - m_idx = idx; - - double d2; - double t; - - switch(idx) - { - default: - case 0: // Border - m_vertex = 0; - m_vx[0] = m_x1; - m_vy[0] = m_y1; - m_vx[1] = m_x2; - m_vy[1] = m_y1; - m_vx[2] = m_x2; - m_vy[2] = m_y2; - m_vx[3] = m_x1; - m_vy[3] = m_y2; - m_vx[4] = m_x1 + m_text_thickness; - m_vy[4] = m_y1 + m_text_thickness; - m_vx[5] = m_x1 + m_text_thickness; - m_vy[5] = m_y2 - m_text_thickness; - m_vx[6] = m_x2 - m_text_thickness; - m_vy[6] = m_y2 - m_text_thickness; - m_vx[7] = m_x2 - m_text_thickness; - m_vy[7] = m_y1 + m_text_thickness; - break; - - case 1: // Text - m_text.text(m_label); - m_text.start_point(m_x1 + m_text_height * 2.0, m_y1 + m_text_height / 5.0); - m_text.size(m_text_height, m_text_width); - m_text_poly.width(m_text_thickness); - m_text_poly.line_join(round_join); - m_text_poly.line_cap(round_cap); - m_text_poly.rewind(0); - break; - - case 2: // Active item - m_vertex = 0; - d2 = (m_y2 - m_y1) / 2.0; - t = m_text_thickness * 1.5; - m_vx[0] = m_x1 + m_text_thickness; - m_vy[0] = m_y1 + m_text_thickness; - m_vx[1] = m_x1 + d2; - m_vy[1] = m_y1 + d2 - t; - m_vx[2] = m_x2 - m_text_thickness; - m_vy[2] = m_y1 + m_text_thickness; - m_vx[3] = m_x1 + d2 + t; - m_vy[3] = m_y1 + d2; - m_vx[4] = m_x2 - m_text_thickness; - m_vy[4] = m_y2 - m_text_thickness; - m_vx[5] = m_x1 + d2; - m_vy[5] = m_y1 + d2 + t; - m_vx[6] = m_x1 + m_text_thickness; - m_vy[6] = m_y2 - m_text_thickness; - m_vx[7] = m_x1 + d2 - t; - m_vy[7] = m_y1 + d2; - break; - - } - } - - - - - //------------------------------------------------------------------------ - unsigned cbox_ctrl_impl::vertex(double* x, double* y) - { - unsigned cmd = path_cmd_line_to; - switch(m_idx) - { - case 0: - if(m_vertex == 0 || m_vertex == 4) cmd = path_cmd_move_to; - if(m_vertex >= 8) cmd = path_cmd_stop; - *x = m_vx[m_vertex]; - *y = m_vy[m_vertex]; - m_vertex++; - break; - - case 1: - cmd = m_text_poly.vertex(x, y); - break; - - case 2: - if(m_status) - { - if(m_vertex == 0) cmd = path_cmd_move_to; - if(m_vertex >= 8) cmd = path_cmd_stop; - *x = m_vx[m_vertex]; - *y = m_vy[m_vertex]; - m_vertex++; - } - else - { - cmd = path_cmd_stop; - } - break; - - default: - cmd = path_cmd_stop; - break; - } - - if(!is_stop(cmd)) - { - transform_xy(x, y); - } - return cmd; - } -} - - - diff --git a/desmume/src/windows/agg/src/ctrl/agg_gamma_ctrl.cpp b/desmume/src/windows/agg/src/ctrl/agg_gamma_ctrl.cpp deleted file mode 100644 index 9521bab9f..000000000 --- a/desmume/src/windows/agg/src/ctrl/agg_gamma_ctrl.cpp +++ /dev/null @@ -1,438 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#include -#include "agg_math.h" -#include "ctrl/agg_gamma_ctrl.h" - -namespace agg -{ - - //------------------------------------------------------------------------ - gamma_ctrl_impl::gamma_ctrl_impl(double x1, double y1, double x2, double y2, bool flip_y) : - ctrl(x1, y1, x2, y2, flip_y), - m_border_width(2.0), - m_border_extra(0.0), - m_curve_width(2.0), - m_grid_width(0.2), - m_text_thickness(1.5), - m_point_size(5.0), - m_text_height(9.0), - m_text_width(0.0), - m_xc1(x1), - m_yc1(y1), - m_xc2(x2), - m_yc2(y2 - m_text_height * 2.0), - m_xt1(x1), - m_yt1(y2 - m_text_height * 2.0), - m_xt2(x2), - m_yt2(y2), - m_curve_poly(m_gamma_spline), - m_text_poly(m_text), - m_idx(0), - m_vertex(0), - m_p1_active(true), - m_mouse_point(0), - m_pdx(0.0), - m_pdy(0.0) - { - calc_spline_box(); - } - - - //------------------------------------------------------------------------ - void gamma_ctrl_impl::calc_spline_box() - { - m_xs1 = m_xc1 + m_border_width; - m_ys1 = m_yc1 + m_border_width; - m_xs2 = m_xc2 - m_border_width; - m_ys2 = m_yc2 - m_border_width * 0.5; - } - - - //------------------------------------------------------------------------ - void gamma_ctrl_impl::calc_points() - { - double kx1, ky1, kx2, ky2; - m_gamma_spline.values(&kx1, &ky1, &kx2, &ky2); - m_xp1 = m_xs1 + (m_xs2 - m_xs1) * kx1 * 0.25; - m_yp1 = m_ys1 + (m_ys2 - m_ys1) * ky1 * 0.25; - m_xp2 = m_xs2 - (m_xs2 - m_xs1) * kx2 * 0.25; - m_yp2 = m_ys2 - (m_ys2 - m_ys1) * ky2 * 0.25; - } - - - //------------------------------------------------------------------------ - void gamma_ctrl_impl::calc_values() - { - double kx1, ky1, kx2, ky2; - - kx1 = (m_xp1 - m_xs1) * 4.0 / (m_xs2 - m_xs1); - ky1 = (m_yp1 - m_ys1) * 4.0 / (m_ys2 - m_ys1); - kx2 = (m_xs2 - m_xp2) * 4.0 / (m_xs2 - m_xs1); - ky2 = (m_ys2 - m_yp2) * 4.0 / (m_ys2 - m_ys1); - m_gamma_spline.values(kx1, ky1, kx2, ky2); - } - - - //------------------------------------------------------------------------ - void gamma_ctrl_impl::text_size(double h, double w) - { - m_text_width = w; - m_text_height = h; - m_yc2 = m_y2 - m_text_height * 2.0; - m_yt1 = m_y2 - m_text_height * 2.0; - calc_spline_box(); - } - - - //------------------------------------------------------------------------ - void gamma_ctrl_impl::border_width(double t, double extra) - { - m_border_width = t; - m_border_extra = extra; - calc_spline_box(); - } - - //------------------------------------------------------------------------ - void gamma_ctrl_impl::values(double kx1, double ky1, double kx2, double ky2) - { - m_gamma_spline.values(kx1, ky1, kx2, ky2); - } - - - //------------------------------------------------------------------------ - void gamma_ctrl_impl::values(double* kx1, double* ky1, double* kx2, double* ky2) const - { - m_gamma_spline.values(kx1, ky1, kx2, ky2); - } - - //------------------------------------------------------------------------ - void gamma_ctrl_impl::rewind(unsigned idx) - { - double kx1, ky1, kx2, ky2; - char tbuf[32]; - - m_idx = idx; - - switch(idx) - { - default: - - case 0: // Background - m_vertex = 0; - m_vx[0] = m_x1 - m_border_extra; - m_vy[0] = m_y1 - m_border_extra; - m_vx[1] = m_x2 + m_border_extra; - m_vy[1] = m_y1 - m_border_extra; - m_vx[2] = m_x2 + m_border_extra; - m_vy[2] = m_y2 + m_border_extra; - m_vx[3] = m_x1 - m_border_extra; - m_vy[3] = m_y2 + m_border_extra; - break; - - case 1: // Border - m_vertex = 0; - m_vx[0] = m_x1; - m_vy[0] = m_y1; - m_vx[1] = m_x2; - m_vy[1] = m_y1; - m_vx[2] = m_x2; - m_vy[2] = m_y2; - m_vx[3] = m_x1; - m_vy[3] = m_y2; - m_vx[4] = m_x1 + m_border_width; - m_vy[4] = m_y1 + m_border_width; - m_vx[5] = m_x1 + m_border_width; - m_vy[5] = m_y2 - m_border_width; - m_vx[6] = m_x2 - m_border_width; - m_vy[6] = m_y2 - m_border_width; - m_vx[7] = m_x2 - m_border_width; - m_vy[7] = m_y1 + m_border_width; - m_vx[8] = m_xc1 + m_border_width; - m_vy[8] = m_yc2 - m_border_width * 0.5; - m_vx[9] = m_xc2 - m_border_width; - m_vy[9] = m_yc2 - m_border_width * 0.5; - m_vx[10] = m_xc2 - m_border_width; - m_vy[10] = m_yc2 + m_border_width * 0.5; - m_vx[11] = m_xc1 + m_border_width; - m_vy[11] = m_yc2 + m_border_width * 0.5; - break; - - case 2: // Curve - m_gamma_spline.box(m_xs1, m_ys1, m_xs2, m_ys2); - m_curve_poly.width(m_curve_width); - m_curve_poly.rewind(0); - break; - - case 3: // Grid - m_vertex = 0; - m_vx[0] = m_xs1; - m_vy[0] = (m_ys1 + m_ys2) * 0.5 - m_grid_width * 0.5; - m_vx[1] = m_xs2; - m_vy[1] = (m_ys1 + m_ys2) * 0.5 - m_grid_width * 0.5; - m_vx[2] = m_xs2; - m_vy[2] = (m_ys1 + m_ys2) * 0.5 + m_grid_width * 0.5; - m_vx[3] = m_xs1; - m_vy[3] = (m_ys1 + m_ys2) * 0.5 + m_grid_width * 0.5; - m_vx[4] = (m_xs1 + m_xs2) * 0.5 - m_grid_width * 0.5; - m_vy[4] = m_ys1; - m_vx[5] = (m_xs1 + m_xs2) * 0.5 - m_grid_width * 0.5; - m_vy[5] = m_ys2; - m_vx[6] = (m_xs1 + m_xs2) * 0.5 + m_grid_width * 0.5; - m_vy[6] = m_ys2; - m_vx[7] = (m_xs1 + m_xs2) * 0.5 + m_grid_width * 0.5; - m_vy[7] = m_ys1; - calc_points(); - m_vx[8] = m_xs1; - m_vy[8] = m_yp1 - m_grid_width * 0.5; - m_vx[9] = m_xp1 - m_grid_width * 0.5; - m_vy[9] = m_yp1 - m_grid_width * 0.5; - m_vx[10] = m_xp1 - m_grid_width * 0.5; - m_vy[10] = m_ys1; - m_vx[11] = m_xp1 + m_grid_width * 0.5; - m_vy[11] = m_ys1; - m_vx[12] = m_xp1 + m_grid_width * 0.5; - m_vy[12] = m_yp1 + m_grid_width * 0.5; - m_vx[13] = m_xs1; - m_vy[13] = m_yp1 + m_grid_width * 0.5; - m_vx[14] = m_xs2; - m_vy[14] = m_yp2 + m_grid_width * 0.5; - m_vx[15] = m_xp2 + m_grid_width * 0.5; - m_vy[15] = m_yp2 + m_grid_width * 0.5; - m_vx[16] = m_xp2 + m_grid_width * 0.5; - m_vy[16] = m_ys2; - m_vx[17] = m_xp2 - m_grid_width * 0.5; - m_vy[17] = m_ys2; - m_vx[18] = m_xp2 - m_grid_width * 0.5; - m_vy[18] = m_yp2 - m_grid_width * 0.5; - m_vx[19] = m_xs2; - m_vy[19] = m_yp2 - m_grid_width * 0.5; - break; - - case 4: // Point1 - calc_points(); - if(m_p1_active) m_ellipse.init(m_xp2, m_yp2, m_point_size, m_point_size, 32); - else m_ellipse.init(m_xp1, m_yp1, m_point_size, m_point_size, 32); - break; - - case 5: // Point2 - calc_points(); - if(m_p1_active) m_ellipse.init(m_xp1, m_yp1, m_point_size, m_point_size, 32); - else m_ellipse.init(m_xp2, m_yp2, m_point_size, m_point_size, 32); - break; - - case 6: // Text - m_gamma_spline.values(&kx1, &ky1, &kx2, &ky2); - sprintf(tbuf, "%5.3f %5.3f %5.3f %5.3f", kx1, ky1, kx2, ky2); - m_text.text(tbuf); - m_text.size(m_text_height, m_text_width); - m_text.start_point(m_xt1 + m_border_width * 2.0, (m_yt1 + m_yt2) * 0.5 - m_text_height * 0.5); - m_text_poly.width(m_text_thickness); - m_text_poly.line_join(round_join); - m_text_poly.line_cap(round_cap); - m_text_poly.rewind(0); - break; - } - } - - - //------------------------------------------------------------------------ - unsigned gamma_ctrl_impl::vertex(double* x, double* y) - { - unsigned cmd = path_cmd_line_to; - switch(m_idx) - { - case 0: - if(m_vertex == 0) cmd = path_cmd_move_to; - if(m_vertex >= 4) cmd = path_cmd_stop; - *x = m_vx[m_vertex]; - *y = m_vy[m_vertex]; - m_vertex++; - break; - - case 1: - if(m_vertex == 0 || m_vertex == 4 || m_vertex == 8) cmd = path_cmd_move_to; - if(m_vertex >= 12) cmd = path_cmd_stop; - *x = m_vx[m_vertex]; - *y = m_vy[m_vertex]; - m_vertex++; - break; - - case 2: - cmd = m_curve_poly.vertex(x, y); - break; - - case 3: - if(m_vertex == 0 || - m_vertex == 4 || - m_vertex == 8 || - m_vertex == 14) cmd = path_cmd_move_to; - - if(m_vertex >= 20) cmd = path_cmd_stop; - *x = m_vx[m_vertex]; - *y = m_vy[m_vertex]; - m_vertex++; - break; - - case 4: // Point1 - case 5: // Point2 - cmd = m_ellipse.vertex(x, y); - break; - - case 6: - cmd = m_text_poly.vertex(x, y); - break; - - default: - cmd = path_cmd_stop; - break; - } - - if(!is_stop(cmd)) - { - transform_xy(x, y); - } - - return cmd; - } - - - - //------------------------------------------------------------------------ - bool gamma_ctrl_impl::on_arrow_keys(bool left, bool right, bool down, bool up) - { - double kx1, ky1, kx2, ky2; - bool ret = false; - m_gamma_spline.values(&kx1, &ky1, &kx2, &ky2); - if(m_p1_active) - { - if(left) { kx1 -= 0.005; ret = true; } - if(right) { kx1 += 0.005; ret = true; } - if(down) { ky1 -= 0.005; ret = true; } - if(up) { ky1 += 0.005; ret = true; } - } - else - { - if(left) { kx2 += 0.005; ret = true; } - if(right) { kx2 -= 0.005; ret = true; } - if(down) { ky2 += 0.005; ret = true; } - if(up) { ky2 -= 0.005; ret = true; } - } - if(ret) - { - m_gamma_spline.values(kx1, ky1, kx2, ky2); - } - return ret; - } - - - - //------------------------------------------------------------------------ - void gamma_ctrl_impl::change_active_point() - { - m_p1_active = m_p1_active ? false : true; - } - - - - - //------------------------------------------------------------------------ - bool gamma_ctrl_impl::in_rect(double x, double y) const - { - inverse_transform_xy(&x, &y); - return x >= m_x1 && x <= m_x2 && y >= m_y1 && y <= m_y2; - } - - - //------------------------------------------------------------------------ - bool gamma_ctrl_impl::on_mouse_button_down(double x, double y) - { - inverse_transform_xy(&x, &y); - calc_points(); - - if(calc_distance(x, y, m_xp1, m_yp1) <= m_point_size + 1) - { - m_mouse_point = 1; - m_pdx = m_xp1 - x; - m_pdy = m_yp1 - y; - m_p1_active = true; - return true; - } - - if(calc_distance(x, y, m_xp2, m_yp2) <= m_point_size + 1) - { - m_mouse_point = 2; - m_pdx = m_xp2 - x; - m_pdy = m_yp2 - y; - m_p1_active = false; - return true; - } - - return false; - } - - - //------------------------------------------------------------------------ - bool gamma_ctrl_impl::on_mouse_button_up(double, double) - { - if(m_mouse_point) - { - m_mouse_point = 0; - return true; - } - return false; - } - - - //------------------------------------------------------------------------ - bool gamma_ctrl_impl::on_mouse_move(double x, double y, bool button_flag) - { - inverse_transform_xy(&x, &y); - if(!button_flag) - { - return on_mouse_button_up(x, y); - } - - if(m_mouse_point == 1) - { - m_xp1 = x + m_pdx; - m_yp1 = y + m_pdy; - calc_values(); - return true; - } - if(m_mouse_point == 2) - { - m_xp2 = x + m_pdx; - m_yp2 = y + m_pdy; - calc_values(); - return true; - } - return false; - } - - - -} - diff --git a/desmume/src/windows/agg/src/ctrl/agg_gamma_spline.cpp b/desmume/src/windows/agg/src/ctrl/agg_gamma_spline.cpp deleted file mode 100644 index 10de9c397..000000000 --- a/desmume/src/windows/agg/src/ctrl/agg_gamma_spline.cpp +++ /dev/null @@ -1,135 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#include "ctrl/agg_gamma_spline.h" - -namespace agg -{ - - //------------------------------------------------------------------------ - gamma_spline::gamma_spline() : - m_x1(0), m_y1(0), m_x2(10), m_y2(10), m_cur_x(0.0) - { - values(1.0, 1.0, 1.0, 1.0); - } - - - //------------------------------------------------------------------------ - double gamma_spline::y(double x) const - { - if(x < 0.0) x = 0.0; - if(x > 1.0) x = 1.0; - double val = m_spline.get(x); - if(val < 0.0) val = 0.0; - if(val > 1.0) val = 1.0; - return val; - } - - - - //------------------------------------------------------------------------ - void gamma_spline::values(double kx1, double ky1, double kx2, double ky2) - { - if(kx1 < 0.001) kx1 = 0.001; - if(kx1 > 1.999) kx1 = 1.999; - if(ky1 < 0.001) ky1 = 0.001; - if(ky1 > 1.999) ky1 = 1.999; - if(kx2 < 0.001) kx2 = 0.001; - if(kx2 > 1.999) kx2 = 1.999; - if(ky2 < 0.001) ky2 = 0.001; - if(ky2 > 1.999) ky2 = 1.999; - - m_x[0] = 0.0; - m_y[0] = 0.0; - m_x[1] = kx1 * 0.25; - m_y[1] = ky1 * 0.25; - m_x[2] = 1.0 - kx2 * 0.25; - m_y[2] = 1.0 - ky2 * 0.25; - m_x[3] = 1.0; - m_y[3] = 1.0; - - m_spline.init(4, m_x, m_y); - - int i; - for(i = 0; i < 256; i++) - { - m_gamma[i] = (unsigned char)(y(double(i) / 255.0) * 255.0); - } - } - - - //------------------------------------------------------------------------ - void gamma_spline::values(double* kx1, double* ky1, double* kx2, double* ky2) const - { - *kx1 = m_x[1] * 4.0; - *ky1 = m_y[1] * 4.0; - *kx2 = (1.0 - m_x[2]) * 4.0; - *ky2 = (1.0 - m_y[2]) * 4.0; - } - - - //------------------------------------------------------------------------ - void gamma_spline::box(double x1, double y1, double x2, double y2) - { - m_x1 = x1; - m_y1 = y1; - m_x2 = x2; - m_y2 = y2; - } - - - //------------------------------------------------------------------------ - void gamma_spline::rewind(unsigned) - { - m_cur_x = 0.0; - } - - - //------------------------------------------------------------------------ - unsigned gamma_spline::vertex(double* vx, double* vy) - { - if(m_cur_x == 0.0) - { - *vx = m_x1; - *vy = m_y1; - m_cur_x += 1.0 / (m_x2 - m_x1); - return path_cmd_move_to; - } - - if(m_cur_x > 1.0) - { - return path_cmd_stop; - } - - *vx = m_x1 + m_cur_x * (m_x2 - m_x1); - *vy = m_y1 + y(m_cur_x) * (m_y2 - m_y1); - - m_cur_x += 1.0 / (m_x2 - m_x1); - return path_cmd_line_to; - } - - - -} - diff --git a/desmume/src/windows/agg/src/ctrl/agg_polygon_ctrl.cpp b/desmume/src/windows/agg/src/ctrl/agg_polygon_ctrl.cpp deleted file mode 100644 index 4dde1b7f8..000000000 --- a/desmume/src/windows/agg/src/ctrl/agg_polygon_ctrl.cpp +++ /dev/null @@ -1,337 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#include "ctrl/agg_polygon_ctrl.h" - -namespace agg -{ - - polygon_ctrl_impl::polygon_ctrl_impl(unsigned np, double point_radius) : - ctrl(0, 0, 1, 1, false), - m_polygon(np * 2), - m_num_points(np), - m_node(-1), - m_edge(-1), - m_vs(&m_polygon[0], m_num_points, false), - m_stroke(m_vs), - m_point_radius(point_radius), - m_status(0), - m_dx(0.0), - m_dy(0.0), - m_in_polygon_check(true) - { - m_stroke.width(1.0); - } - - - void polygon_ctrl_impl::rewind(unsigned) - { - m_status = 0; - m_stroke.rewind(0); - } - - unsigned polygon_ctrl_impl::vertex(double* x, double* y) - { - unsigned cmd = path_cmd_stop; - double r = m_point_radius; - if(m_status == 0) - { - cmd = m_stroke.vertex(x, y); - if(!is_stop(cmd)) - { - transform_xy(x, y); - return cmd; - } - if(m_node >= 0 && m_node == int(m_status)) r *= 1.2; - m_ellipse.init(xn(m_status), yn(m_status), r, r, 32); - ++m_status; - } - cmd = m_ellipse.vertex(x, y); - if(!is_stop(cmd)) - { - transform_xy(x, y); - return cmd; - } - if(m_status >= m_num_points) return path_cmd_stop; - if(m_node >= 0 && m_node == int(m_status)) r *= 1.2; - m_ellipse.init(xn(m_status), yn(m_status), r, r, 32); - ++m_status; - cmd = m_ellipse.vertex(x, y); - if(!is_stop(cmd)) - { - transform_xy(x, y); - } - return cmd; - } - - - bool polygon_ctrl_impl::check_edge(unsigned i, double x, double y) const - { - bool ret = false; - - unsigned n1 = i; - unsigned n2 = (i + m_num_points - 1) % m_num_points; - double x1 = xn(n1); - double y1 = yn(n1); - double x2 = xn(n2); - double y2 = yn(n2); - - double dx = x2 - x1; - double dy = y2 - y1; - - if(sqrt(dx*dx + dy*dy) > 0.0000001) - { - double x3 = x; - double y3 = y; - double x4 = x3 - dy; - double y4 = y3 + dx; - - double den = (y4-y3) * (x2-x1) - (x4-x3) * (y2-y1); - double u1 = ((x4-x3) * (y1-y3) - (y4-y3) * (x1-x3)) / den; - - double xi = x1 + u1 * (x2 - x1); - double yi = y1 + u1 * (y2 - y1); - - dx = xi - x; - dy = yi - y; - - if (u1 > 0.0 && u1 < 1.0 && sqrt(dx*dx + dy*dy) <= m_point_radius) - { - ret = true; - } - } - return ret; - } - - - - bool polygon_ctrl_impl::in_rect(double x, double y) const - { - return false; - } - - - bool polygon_ctrl_impl::on_mouse_button_down(double x, double y) - { - unsigned i; - bool ret = false; - m_node = -1; - m_edge = -1; - inverse_transform_xy(&x, &y); - for (i = 0; i < m_num_points; i++) - { - if(sqrt( (x-xn(i)) * (x-xn(i)) + (y-yn(i)) * (y-yn(i)) ) < m_point_radius) - { - m_dx = x - xn(i); - m_dy = y - yn(i); - m_node = int(i); - ret = true; - break; - } - } - - if(!ret) - { - for (i = 0; i < m_num_points; i++) - { - if(check_edge(i, x, y)) - { - m_dx = x; - m_dy = y; - m_edge = int(i); - ret = true; - break; - } - } - } - - if(!ret) - { - if(point_in_polygon(x, y)) - { - m_dx = x; - m_dy = y; - m_node = int(m_num_points); - ret = true; - } - } - return ret; - } - - - bool polygon_ctrl_impl::on_mouse_move(double x, double y, bool button_flag) - { - bool ret = false; - double dx; - double dy; - inverse_transform_xy(&x, &y); - if(m_node == int(m_num_points)) - { - dx = x - m_dx; - dy = y - m_dy; - unsigned i; - for(i = 0; i < m_num_points; i++) - { - xn(i) += dx; - yn(i) += dy; - } - m_dx = x; - m_dy = y; - ret = true; - } - else - { - if(m_edge >= 0) - { - unsigned n1 = m_edge; - unsigned n2 = (n1 + m_num_points - 1) % m_num_points; - dx = x - m_dx; - dy = y - m_dy; - xn(n1) += dx; - yn(n1) += dy; - xn(n2) += dx; - yn(n2) += dy; - m_dx = x; - m_dy = y; - ret = true; - } - else - { - if(m_node >= 0) - { - xn(m_node) = x - m_dx; - yn(m_node) = y - m_dy; - ret = true; - } - } - } - return ret; - } - - bool polygon_ctrl_impl::on_mouse_button_up(double x, double y) - { - bool ret = (m_node >= 0) || (m_edge >= 0); - m_node = -1; - m_edge = -1; - return ret; - } - - - bool polygon_ctrl_impl::on_arrow_keys(bool left, bool right, bool down, bool up) - { - return false; - } - - - //======= Crossings Multiply algorithm of InsideTest ======================== - // - // By Eric Haines, 3D/Eye Inc, erich@eye.com - // - // This version is usually somewhat faster than the original published in - // Graphics Gems IV; by turning the division for testing the X axis crossing - // into a tricky multiplication test this part of the test became faster, - // which had the additional effect of making the test for "both to left or - // both to right" a bit slower for triangles than simply computing the - // intersection each time. The main increase is in triangle testing speed, - // which was about 15% faster; all other polygon complexities were pretty much - // the same as before. On machines where division is very expensive (not the - // case on the HP 9000 series on which I tested) this test should be much - // faster overall than the old code. Your mileage may (in fact, will) vary, - // depending on the machine and the test data, but in general I believe this - // code is both shorter and faster. This test was inspired by unpublished - // Graphics Gems submitted by Joseph Samosky and Mark Haigh-Hutchinson. - // Related work by Samosky is in: - // - // Samosky, Joseph, "SectionView: A system for interactively specifying and - // visualizing sections through three-dimensional medical image data", - // M.S. Thesis, Department of Electrical Engineering and Computer Science, - // Massachusetts Institute of Technology, 1993. - // - // Shoot a test ray along +X axis. The strategy is to compare vertex Y values - // to the testing point's Y and quickly discard edges which are entirely to one - // side of the test ray. Note that CONVEX and WINDING code can be added as - // for the CrossingsTest() code; it is left out here for clarity. - // - // Input 2D polygon _pgon_ with _numverts_ number of vertices and test point - // _point_, returns 1 if inside, 0 if outside. - bool polygon_ctrl_impl::point_in_polygon(double tx, double ty) const - { - if(m_num_points < 3) return false; - if(!m_in_polygon_check) return false; - - unsigned j; - int yflag0, yflag1, inside_flag; - double vtx0, vty0, vtx1, vty1; - - vtx0 = xn(m_num_points - 1); - vty0 = yn(m_num_points - 1); - - // get test bit for above/below X axis - yflag0 = (vty0 >= ty); - - vtx1 = xn(0); - vty1 = yn(0); - - inside_flag = 0; - for (j = 1; j <= m_num_points; ++j) - { - yflag1 = (vty1 >= ty); - // Check if endpoints straddle (are on opposite sides) of X axis - // (i.e. the Y's differ); if so, +X ray could intersect this edge. - // The old test also checked whether the endpoints are both to the - // right or to the left of the test point. However, given the faster - // intersection point computation used below, this test was found to - // be a break-even proposition for most polygons and a loser for - // triangles (where 50% or more of the edges which survive this test - // will cross quadrants and so have to have the X intersection computed - // anyway). I credit Joseph Samosky with inspiring me to try dropping - // the "both left or both right" part of my code. - if (yflag0 != yflag1) - { - // Check intersection of pgon segment with +X ray. - // Note if >= point's X; if so, the ray hits it. - // The division operation is avoided for the ">=" test by checking - // the sign of the first vertex wrto the test point; idea inspired - // by Joseph Samosky's and Mark Haigh-Hutchinson's different - // polygon inclusion tests. - if ( ((vty1-ty) * (vtx0-vtx1) >= - (vtx1-tx) * (vty0-vty1)) == yflag1 ) - { - inside_flag ^= 1; - } - } - - // Move to the next pair of vertices, retaining info as possible. - yflag0 = yflag1; - vtx0 = vtx1; - vty0 = vty1; - - unsigned k = (j >= m_num_points) ? j - m_num_points : j; - vtx1 = xn(k); - vty1 = yn(k); - } - return inside_flag != 0; - } -} - diff --git a/desmume/src/windows/agg/src/ctrl/agg_rbox_ctrl.cpp b/desmume/src/windows/agg/src/ctrl/agg_rbox_ctrl.cpp deleted file mode 100644 index c643fec38..000000000 --- a/desmume/src/windows/agg/src/ctrl/agg_rbox_ctrl.cpp +++ /dev/null @@ -1,330 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#include -#include "ctrl/agg_rbox_ctrl.h" - -namespace agg -{ - - //------------------------------------------------------------------------ - rbox_ctrl_impl::rbox_ctrl_impl(double x1, double y1, - double x2, double y2, bool flip_y) : - ctrl(x1, y1, x2, y2, flip_y), - m_border_width(1.0), - m_border_extra(0.0), - m_text_thickness(1.5), - m_text_height(9.0), - m_text_width(0.0), - m_num_items(0), - m_cur_item(-1), - m_ellipse_poly(m_ellipse), - m_text_poly(m_text), - m_idx(0), - m_vertex(0) - { - calc_rbox(); - } - - - //------------------------------------------------------------------------ - void rbox_ctrl_impl::calc_rbox() - { - m_xs1 = m_x1 + m_border_width; - m_ys1 = m_y1 + m_border_width; - m_xs2 = m_x2 - m_border_width; - m_ys2 = m_y2 - m_border_width; - } - - - //------------------------------------------------------------------------ - void rbox_ctrl_impl::add_item(const char* text) - { - if(m_num_items < 32) - { - m_items[m_num_items].resize(strlen(text) + 1); - strcpy(&m_items[m_num_items][0], text); - m_num_items++; - } - } - - - //------------------------------------------------------------------------ - void rbox_ctrl_impl::border_width(double t, double extra) - { - m_border_width = t; - m_border_extra = extra; - calc_rbox(); - } - - - //------------------------------------------------------------------------ - void rbox_ctrl_impl::text_size(double h, double w) - { - m_text_width = w; - m_text_height = h; - } - - - - //------------------------------------------------------------------------ - void rbox_ctrl_impl::rewind(unsigned idx) - { - m_idx = idx; - m_dy = m_text_height * 2.0; - m_draw_item = 0; - - switch(idx) - { - default: - - case 0: // Background - m_vertex = 0; - m_vx[0] = m_x1 - m_border_extra; - m_vy[0] = m_y1 - m_border_extra; - m_vx[1] = m_x2 + m_border_extra; - m_vy[1] = m_y1 - m_border_extra; - m_vx[2] = m_x2 + m_border_extra; - m_vy[2] = m_y2 + m_border_extra; - m_vx[3] = m_x1 - m_border_extra; - m_vy[3] = m_y2 + m_border_extra; - break; - - case 1: // Border - m_vertex = 0; - m_vx[0] = m_x1; - m_vy[0] = m_y1; - m_vx[1] = m_x2; - m_vy[1] = m_y1; - m_vx[2] = m_x2; - m_vy[2] = m_y2; - m_vx[3] = m_x1; - m_vy[3] = m_y2; - m_vx[4] = m_x1 + m_border_width; - m_vy[4] = m_y1 + m_border_width; - m_vx[5] = m_x1 + m_border_width; - m_vy[5] = m_y2 - m_border_width; - m_vx[6] = m_x2 - m_border_width; - m_vy[6] = m_y2 - m_border_width; - m_vx[7] = m_x2 - m_border_width; - m_vy[7] = m_y1 + m_border_width; - break; - - case 2: // Text - m_text.text(&m_items[0][0]); - m_text.start_point(m_xs1 + m_dy * 1.5, m_ys1 + m_dy / 2.0); - m_text.size(m_text_height, m_text_width); - m_text_poly.width(m_text_thickness); - m_text_poly.line_join(round_join); - m_text_poly.line_cap(round_cap); - m_text_poly.rewind(0); - break; - - case 3: // Inactive items - m_ellipse.init(m_xs1 + m_dy / 1.3, - m_ys1 + m_dy / 1.3, - m_text_height / 1.5, - m_text_height / 1.5, 32); - m_ellipse_poly.width(m_text_thickness); - m_ellipse_poly.rewind(0); - break; - - - case 4: // Active Item - if(m_cur_item >= 0) - { - m_ellipse.init(m_xs1 + m_dy / 1.3, - m_ys1 + m_dy * m_cur_item + m_dy / 1.3, - m_text_height / 2.0, - m_text_height / 2.0, 32); - m_ellipse.rewind(0); - } - break; - - } - } - - - //------------------------------------------------------------------------ - unsigned rbox_ctrl_impl::vertex(double* x, double* y) - { - unsigned cmd = path_cmd_line_to; - switch(m_idx) - { - case 0: - if(m_vertex == 0) cmd = path_cmd_move_to; - if(m_vertex >= 4) cmd = path_cmd_stop; - *x = m_vx[m_vertex]; - *y = m_vy[m_vertex]; - m_vertex++; - break; - - case 1: - if(m_vertex == 0 || m_vertex == 4) cmd = path_cmd_move_to; - if(m_vertex >= 8) cmd = path_cmd_stop; - *x = m_vx[m_vertex]; - *y = m_vy[m_vertex]; - m_vertex++; - break; - - case 2: - cmd = m_text_poly.vertex(x, y); - if(is_stop(cmd)) - { - m_draw_item++; - if(m_draw_item >= m_num_items) - { - break; - } - else - { - m_text.text(&m_items[m_draw_item][0]); - m_text.start_point(m_xs1 + m_dy * 1.5, - m_ys1 + m_dy * (m_draw_item + 1) - m_dy / 2.0); - - m_text_poly.rewind(0); - cmd = m_text_poly.vertex(x, y); - } - } - break; - - case 3: - cmd = m_ellipse_poly.vertex(x, y); - if(is_stop(cmd)) - { - m_draw_item++; - if(m_draw_item >= m_num_items) - { - break; - } - else - { - m_ellipse.init(m_xs1 + m_dy / 1.3, - m_ys1 + m_dy * m_draw_item + m_dy / 1.3, - m_text_height / 1.5, - m_text_height / 1.5, 32); - m_ellipse_poly.rewind(0); - cmd = m_ellipse_poly.vertex(x, y); - } - } - break; - - - case 4: - if(m_cur_item >= 0) - { - cmd = m_ellipse.vertex(x, y); - } - else - { - cmd = path_cmd_stop; - } - break; - - default: - cmd = path_cmd_stop; - break; - } - - if(!is_stop(cmd)) - { - transform_xy(x, y); - } - - return cmd; - } - - - //------------------------------------------------------------------------ - bool rbox_ctrl_impl::in_rect(double x, double y) const - { - inverse_transform_xy(&x, &y); - return x >= m_x1 && x <= m_x2 && y >= m_y1 && y <= m_y2; - } - - - - //------------------------------------------------------------------------ - bool rbox_ctrl_impl::on_mouse_button_down(double x, double y) - { - inverse_transform_xy(&x, &y); - unsigned i; - for(i = 0; i < m_num_items; i++) - { - double xp = m_xs1 + m_dy / 1.3; - double yp = m_ys1 + m_dy * i + m_dy / 1.3; - if(calc_distance(x, y, xp, yp) <= m_text_height / 1.5) - { - m_cur_item = int(i); - return true; - } - } - return false; - } - - - //------------------------------------------------------------------------ - bool rbox_ctrl_impl::on_mouse_move(double, double, bool) - { - return false; - } - - //------------------------------------------------------------------------ - bool rbox_ctrl_impl::on_mouse_button_up(double, double) - { - return false; - } - - //------------------------------------------------------------------------ - bool rbox_ctrl_impl::on_arrow_keys(bool left, bool right, bool down, bool up) - { - if(m_cur_item >= 0) - { - if(up || right) - { - m_cur_item++; - if(m_cur_item >= int(m_num_items)) - { - m_cur_item = 0; - } - return true; - } - - if(down || left) - { - m_cur_item--; - if(m_cur_item < 0) - { - m_cur_item = m_num_items - 1; - } - return true; - } - } - return false; - } - - -} - - diff --git a/desmume/src/windows/agg/src/ctrl/agg_scale_ctrl.cpp b/desmume/src/windows/agg/src/ctrl/agg_scale_ctrl.cpp deleted file mode 100644 index 974a4fc72..000000000 --- a/desmume/src/windows/agg/src/ctrl/agg_scale_ctrl.cpp +++ /dev/null @@ -1,459 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#include "ctrl/agg_scale_ctrl.h" - -namespace agg -{ - - //------------------------------------------------------------------------ - scale_ctrl_impl::scale_ctrl_impl(double x1, double y1, - double x2, double y2, bool flip_y) : - ctrl(x1, y1, x2, y2, flip_y), - m_border_thickness(1.0), - m_border_extra((fabs(x2 - x1) > fabs(y2 - y1)) ? (y2 - y1) / 2 : (x2 - x1) / 2), - m_pdx(0.0), - m_pdy(0.0), - m_move_what(move_nothing), - m_value1(0.3), - m_value2(0.7), - m_min_d(0.01) - { - calc_box(); - } - - - //------------------------------------------------------------------------ - void scale_ctrl_impl::calc_box() - { - m_xs1 = m_x1 + m_border_thickness; - m_ys1 = m_y1 + m_border_thickness; - m_xs2 = m_x2 - m_border_thickness; - m_ys2 = m_y2 - m_border_thickness; - } - - - //------------------------------------------------------------------------ - void scale_ctrl_impl::border_thickness(double t, double extra) - { - m_border_thickness = t; - m_border_extra = extra; - calc_box(); - } - - - //------------------------------------------------------------------------ - void scale_ctrl_impl::resize(double x1, double y1, double x2, double y2) - { - m_x1 = x1; - m_y1 = y1; - m_x2 = x2; - m_y2 = y2; - calc_box(); - m_border_extra = (fabs(x2 - x1) > fabs(y2 - y1)) ? - (y2 - y1) / 2 : - (x2 - x1) / 2; - } - - - //------------------------------------------------------------------------ - void scale_ctrl_impl::value1(double value) - { - if(value < 0.0) value = 0.0; - if(value > 1.0) value = 1.0; - if(m_value2 - value < m_min_d) value = m_value2 - m_min_d; - m_value1 = value; - } - - - //------------------------------------------------------------------------ - void scale_ctrl_impl::value2(double value) - { - if(value < 0.0) value = 0.0; - if(value > 1.0) value = 1.0; - if(m_value1 + value < m_min_d) value = m_value1 + m_min_d; - m_value2 = value; - } - - - //------------------------------------------------------------------------ - void scale_ctrl_impl::move(double d) - { - m_value1 += d; - m_value2 += d; - if(m_value1 < 0.0) - { - m_value2 -= m_value1; - m_value1 = 0.0; - } - if(m_value2 > 1.0) - { - m_value1 -= m_value2 - 1.0; - m_value2 = 1.0; - } - } - - - //------------------------------------------------------------------------ - void scale_ctrl_impl::rewind(unsigned idx) - { - m_idx = idx; - - switch(idx) - { - default: - - case 0: // Background - m_vertex = 0; - m_vx[0] = m_x1 - m_border_extra; - m_vy[0] = m_y1 - m_border_extra; - m_vx[1] = m_x2 + m_border_extra; - m_vy[1] = m_y1 - m_border_extra; - m_vx[2] = m_x2 + m_border_extra; - m_vy[2] = m_y2 + m_border_extra; - m_vx[3] = m_x1 - m_border_extra; - m_vy[3] = m_y2 + m_border_extra; - break; - - case 1: // Border - m_vertex = 0; - m_vx[0] = m_x1; - m_vy[0] = m_y1; - m_vx[1] = m_x2; - m_vy[1] = m_y1; - m_vx[2] = m_x2; - m_vy[2] = m_y2; - m_vx[3] = m_x1; - m_vy[3] = m_y2; - m_vx[4] = m_x1 + m_border_thickness; - m_vy[4] = m_y1 + m_border_thickness; - m_vx[5] = m_x1 + m_border_thickness; - m_vy[5] = m_y2 - m_border_thickness; - m_vx[6] = m_x2 - m_border_thickness; - m_vy[6] = m_y2 - m_border_thickness; - m_vx[7] = m_x2 - m_border_thickness; - m_vy[7] = m_y1 + m_border_thickness; - break; - - case 2: // pointer1 - if(fabs(m_x2 - m_x1) > fabs(m_y2 - m_y1)) - { - m_ellipse.init(m_xs1 + (m_xs2 - m_xs1) * m_value1, - (m_ys1 + m_ys2) / 2.0, - m_y2 - m_y1, - m_y2 - m_y1, - 32); - } - else - { - m_ellipse.init((m_xs1 + m_xs2) / 2.0, - m_ys1 + (m_ys2 - m_ys1) * m_value1, - m_x2 - m_x1, - m_x2 - m_x1, - 32); - } - m_ellipse.rewind(0); - break; - - case 3: // pointer2 - if(fabs(m_x2 - m_x1) > fabs(m_y2 - m_y1)) - { - m_ellipse.init(m_xs1 + (m_xs2 - m_xs1) * m_value2, - (m_ys1 + m_ys2) / 2.0, - m_y2 - m_y1, - m_y2 - m_y1, - 32); - } - else - { - m_ellipse.init((m_xs1 + m_xs2) / 2.0, - m_ys1 + (m_ys2 - m_ys1) * m_value2, - m_x2 - m_x1, - m_x2 - m_x1, - 32); - } - m_ellipse.rewind(0); - break; - - case 4: // slider - m_vertex = 0; - if(fabs(m_x2 - m_x1) > fabs(m_y2 - m_y1)) - { - m_vx[0] = m_xs1 + (m_xs2 - m_xs1) * m_value1; - m_vy[0] = m_y1 - m_border_extra / 2.0; - m_vx[1] = m_xs1 + (m_xs2 - m_xs1) * m_value2; - m_vy[1] = m_vy[0]; - m_vx[2] = m_vx[1]; - m_vy[2] = m_y2 + m_border_extra / 2.0; - m_vx[3] = m_vx[0]; - m_vy[3] = m_vy[2]; - } - else - { - m_vx[0] = m_x1 - m_border_extra / 2.0; - m_vy[0] = m_ys1 + (m_ys2 - m_ys1) * m_value1; - m_vx[1] = m_vx[0]; - m_vy[1] = m_ys1 + (m_ys2 - m_ys1) * m_value2; - m_vx[2] = m_x2 + m_border_extra / 2.0; - m_vy[2] = m_vy[1]; - m_vx[3] = m_vx[2]; - m_vy[3] = m_vy[0]; - } - break; - } - } - - - //------------------------------------------------------------------------ - unsigned scale_ctrl_impl::vertex(double* x, double* y) - { - unsigned cmd = path_cmd_line_to; - switch(m_idx) - { - case 0: - case 4: - if(m_vertex == 0) cmd = path_cmd_move_to; - if(m_vertex >= 4) cmd = path_cmd_stop; - *x = m_vx[m_vertex]; - *y = m_vy[m_vertex]; - m_vertex++; - break; - - case 1: - if(m_vertex == 0 || m_vertex == 4) cmd = path_cmd_move_to; - if(m_vertex >= 8) cmd = path_cmd_stop; - *x = m_vx[m_vertex]; - *y = m_vy[m_vertex]; - m_vertex++; - break; - - case 2: - case 3: - cmd = m_ellipse.vertex(x, y); - break; - - default: - cmd = path_cmd_stop; - break; - } - - if(!is_stop(cmd)) - { - transform_xy(x, y); - } - - return cmd; - } - - - - //------------------------------------------------------------------------ - bool scale_ctrl_impl::in_rect(double x, double y) const - { - inverse_transform_xy(&x, &y); - return x >= m_x1 && x <= m_x2 && y >= m_y1 && y <= m_y2; - } - - - //------------------------------------------------------------------------ - bool scale_ctrl_impl::on_mouse_button_down(double x, double y) - { - inverse_transform_xy(&x, &y); - - double xp1; - double xp2; - double ys1; - double ys2; - double xp; - double yp; - - if(fabs(m_x2 - m_x1) > fabs(m_y2 - m_y1)) - { - xp1 = m_xs1 + (m_xs2 - m_xs1) * m_value1; - xp2 = m_xs1 + (m_xs2 - m_xs1) * m_value2; - ys1 = m_y1 - m_border_extra / 2.0; - ys2 = m_y2 + m_border_extra / 2.0; - yp = (m_ys1 + m_ys2) / 2.0; - - if(x > xp1 && y > ys1 && x < xp2 && y < ys2) - { - m_pdx = xp1 - x; - m_move_what = move_slider; - return true; - } - - //if(x < xp1 && calc_distance(x, y, xp1, yp) <= m_y2 - m_y1) - if(calc_distance(x, y, xp1, yp) <= m_y2 - m_y1) - { - m_pdx = xp1 - x; - m_move_what = move_value1; - return true; - } - - //if(x > xp2 && calc_distance(x, y, xp2, yp) <= m_y2 - m_y1) - if(calc_distance(x, y, xp2, yp) <= m_y2 - m_y1) - { - m_pdx = xp2 - x; - m_move_what = move_value2; - return true; - } - } - else - { - xp1 = m_x1 - m_border_extra / 2.0; - xp2 = m_x2 + m_border_extra / 2.0; - ys1 = m_ys1 + (m_ys2 - m_ys1) * m_value1; - ys2 = m_ys1 + (m_ys2 - m_ys1) * m_value2; - xp = (m_xs1 + m_xs2) / 2.0; - - if(x > xp1 && y > ys1 && x < xp2 && y < ys2) - { - m_pdy = ys1 - y; - m_move_what = move_slider; - return true; - } - - //if(y < ys1 && calc_distance(x, y, xp, ys1) <= m_x2 - m_x1) - if(calc_distance(x, y, xp, ys1) <= m_x2 - m_x1) - { - m_pdy = ys1 - y; - m_move_what = move_value1; - return true; - } - - //if(y > ys2 && calc_distance(x, y, xp, ys2) <= m_x2 - m_x1) - if(calc_distance(x, y, xp, ys2) <= m_x2 - m_x1) - { - m_pdy = ys2 - y; - m_move_what = move_value2; - return true; - } - } - - return false; - } - - - //------------------------------------------------------------------------ - bool scale_ctrl_impl::on_mouse_move(double x, double y, bool button_flag) - { - inverse_transform_xy(&x, &y); - if(!button_flag) - { - return on_mouse_button_up(x, y); - } - - double xp = x + m_pdx; - double yp = y + m_pdy; - double dv; - - switch(m_move_what) - { - case move_value1: - if(fabs(m_x2 - m_x1) > fabs(m_y2 - m_y1)) - { - m_value1 = (xp - m_xs1) / (m_xs2 - m_xs1); - } - else - { - m_value1 = (yp - m_ys1) / (m_ys2 - m_ys1); - } - if(m_value1 < 0.0) m_value1 = 0.0; - if(m_value1 > m_value2 - m_min_d) m_value1 = m_value2 - m_min_d; - return true; - - case move_value2: - if(fabs(m_x2 - m_x1) > fabs(m_y2 - m_y1)) - { - m_value2 = (xp - m_xs1) / (m_xs2 - m_xs1); - } - else - { - m_value2 = (yp - m_ys1) / (m_ys2 - m_ys1); - } - if(m_value2 > 1.0) m_value2 = 1.0; - if(m_value2 < m_value1 + m_min_d) m_value2 = m_value1 + m_min_d; - return true; - - case move_slider: - dv = m_value2 - m_value1; - if(fabs(m_x2 - m_x1) > fabs(m_y2 - m_y1)) - { - m_value1 = (xp - m_xs1) / (m_xs2 - m_xs1); - } - else - { - m_value1 = (yp - m_ys1) / (m_ys2 - m_ys1); - } - m_value2 = m_value1 + dv; - if(m_value1 < 0.0) - { - dv = m_value2 - m_value1; - m_value1 = 0.0; - m_value2 = m_value1 + dv; - } - if(m_value2 > 1.0) - { - dv = m_value2 - m_value1; - m_value2 = 1.0; - m_value1 = m_value2 - dv; - } - return true; - } - - return false; - } - - - //------------------------------------------------------------------------ - bool scale_ctrl_impl::on_mouse_button_up(double, double) - { - m_move_what = move_nothing; - return false; - } - - - //------------------------------------------------------------------------ - bool scale_ctrl_impl::on_arrow_keys(bool left, bool right, bool down, bool up) - { -/* - if(right || up) - { - m_value += 0.005; - if(m_value > 1.0) m_value = 1.0; - return true; - } - - if(left || down) - { - m_value -= 0.005; - if(m_value < 0.0) m_value = 0.0; - return true; - } -*/ - return false; - } - -} - diff --git a/desmume/src/windows/agg/src/ctrl/agg_slider_ctrl.cpp b/desmume/src/windows/agg/src/ctrl/agg_slider_ctrl.cpp deleted file mode 100644 index 113b7ac08..000000000 --- a/desmume/src/windows/agg/src/ctrl/agg_slider_ctrl.cpp +++ /dev/null @@ -1,354 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#include -#include -#include "ctrl/agg_slider_ctrl.h" - -namespace agg -{ - - //------------------------------------------------------------------------ - slider_ctrl_impl::slider_ctrl_impl(double x1, double y1, - double x2, double y2, bool flip_y) : - ctrl(x1, y1, x2, y2, flip_y), - m_border_width(1.0), - m_border_extra((y2 - y1) / 2), - m_text_thickness(1.0), - m_pdx(0.0), - m_mouse_move(false), - m_value(0.5), - m_preview_value(0.5), - m_min(0.0), - m_max(1.0), - m_num_steps(0), - m_descending(false), - m_text_poly(m_text) - { - m_label[0] = 0; - calc_box(); - } - - - //------------------------------------------------------------------------ - void slider_ctrl_impl::calc_box() - { - m_xs1 = m_x1 + m_border_width; - m_ys1 = m_y1 + m_border_width; - m_xs2 = m_x2 - m_border_width; - m_ys2 = m_y2 - m_border_width; - } - - - //------------------------------------------------------------------------ - bool slider_ctrl_impl::normalize_value(bool preview_value_flag) - { - bool ret = true; - if(m_num_steps) - { - int step = int(m_preview_value * m_num_steps + 0.5); - ret = m_value != step / double(m_num_steps); - m_value = step / double(m_num_steps); - } - else - { - m_value = m_preview_value; - } - - if(preview_value_flag) - { - m_preview_value = m_value; - } - return ret; - } - - - //------------------------------------------------------------------------ - void slider_ctrl_impl::border_width(double t, double extra) - { - m_border_width = t; - m_border_extra = extra; - calc_box(); - } - - - //------------------------------------------------------------------------ - void slider_ctrl_impl::value(double value) - { - m_preview_value = (value - m_min) / (m_max - m_min); - if(m_preview_value > 1.0) m_preview_value = 1.0; - if(m_preview_value < 0.0) m_preview_value = 0.0; - normalize_value(true); - } - - //------------------------------------------------------------------------ - void slider_ctrl_impl::label(const char* fmt) - { - m_label[0] = 0; - if(fmt) - { - unsigned len = strlen(fmt); - if(len > 63) len = 63; - memcpy(m_label, fmt, len); - m_label[len] = 0; - } - } - - //------------------------------------------------------------------------ - void slider_ctrl_impl::rewind(unsigned idx) - { - m_idx = idx; - - switch(idx) - { - default: - - case 0: // Background - m_vertex = 0; - m_vx[0] = m_x1 - m_border_extra; - m_vy[0] = m_y1 - m_border_extra; - m_vx[1] = m_x2 + m_border_extra; - m_vy[1] = m_y1 - m_border_extra; - m_vx[2] = m_x2 + m_border_extra; - m_vy[2] = m_y2 + m_border_extra; - m_vx[3] = m_x1 - m_border_extra; - m_vy[3] = m_y2 + m_border_extra; - break; - - case 1: // Triangle - m_vertex = 0; - if(m_descending) - { - m_vx[0] = m_x1; - m_vy[0] = m_y1; - m_vx[1] = m_x2; - m_vy[1] = m_y1; - m_vx[2] = m_x1; - m_vy[2] = m_y2; - m_vx[3] = m_x1; - m_vy[3] = m_y1; - } - else - { - m_vx[0] = m_x1; - m_vy[0] = m_y1; - m_vx[1] = m_x2; - m_vy[1] = m_y1; - m_vx[2] = m_x2; - m_vy[2] = m_y2; - m_vx[3] = m_x1; - m_vy[3] = m_y1; - } - break; - - case 2: - m_text.text(m_label); - if(m_label[0]) - { - char buf[256]; - sprintf(buf, m_label, value()); - m_text.text(buf); - } - m_text.start_point(m_x1, m_y1); - m_text.size((m_y2 - m_y1) * 1.2, m_y2 - m_y1); - m_text_poly.width(m_text_thickness); - m_text_poly.line_join(round_join); - m_text_poly.line_cap(round_cap); - m_text_poly.rewind(0); - break; - - case 3: // pointer preview - m_ellipse.init(m_xs1 + (m_xs2 - m_xs1) * m_preview_value, - (m_ys1 + m_ys2) / 2.0, - m_y2 - m_y1, - m_y2 - m_y1, - 32); - break; - - - case 4: // pointer - normalize_value(false); - m_ellipse.init(m_xs1 + (m_xs2 - m_xs1) * m_value, - (m_ys1 + m_ys2) / 2.0, - m_y2 - m_y1, - m_y2 - m_y1, - 32); - m_ellipse.rewind(0); - break; - - case 5: - m_storage.remove_all(); - if(m_num_steps) - { - unsigned i; - double d = (m_xs2 - m_xs1) / m_num_steps; - if(d > 0.004) d = 0.004; - for(i = 0; i < m_num_steps + 1; i++) - { - double x = m_xs1 + (m_xs2 - m_xs1) * i / m_num_steps; - m_storage.move_to(x, m_y1); - m_storage.line_to(x - d * (m_x2 - m_x1), m_y1 - m_border_extra); - m_storage.line_to(x + d * (m_x2 - m_x1), m_y1 - m_border_extra); - } - } - } - } - - - //------------------------------------------------------------------------ - unsigned slider_ctrl_impl::vertex(double* x, double* y) - { - unsigned cmd = path_cmd_line_to; - switch(m_idx) - { - case 0: - if(m_vertex == 0) cmd = path_cmd_move_to; - if(m_vertex >= 4) cmd = path_cmd_stop; - *x = m_vx[m_vertex]; - *y = m_vy[m_vertex]; - m_vertex++; - break; - - case 1: - if(m_vertex == 0) cmd = path_cmd_move_to; - if(m_vertex >= 4) cmd = path_cmd_stop; - *x = m_vx[m_vertex]; - *y = m_vy[m_vertex]; - m_vertex++; - break; - - case 2: - cmd = m_text_poly.vertex(x, y); - break; - - case 3: - case 4: - cmd = m_ellipse.vertex(x, y); - break; - - case 5: - cmd = m_storage.vertex(x, y); - break; - - default: - cmd = path_cmd_stop; - break; - } - - if(!is_stop(cmd)) - { - transform_xy(x, y); - } - - return cmd; - } - - - - //------------------------------------------------------------------------ - bool slider_ctrl_impl::in_rect(double x, double y) const - { - inverse_transform_xy(&x, &y); - return x >= m_x1 && x <= m_x2 && y >= m_y1 && y <= m_y2; - } - - - //------------------------------------------------------------------------ - bool slider_ctrl_impl::on_mouse_button_down(double x, double y) - { - inverse_transform_xy(&x, &y); - - double xp = m_xs1 + (m_xs2 - m_xs1) * m_value; - double yp = (m_ys1 + m_ys2) / 2.0; - - if(calc_distance(x, y, xp, yp) <= m_y2 - m_y1) - { - m_pdx = xp - x; - m_mouse_move = true; - return true; - } - return false; - } - - - //------------------------------------------------------------------------ - bool slider_ctrl_impl::on_mouse_move(double x, double y, bool button_flag) - { - inverse_transform_xy(&x, &y); - if(!button_flag) - { - on_mouse_button_up(x, y); - return false; - } - - if(m_mouse_move) - { - double xp = x + m_pdx; - m_preview_value = (xp - m_xs1) / (m_xs2 - m_xs1); - if(m_preview_value < 0.0) m_preview_value = 0.0; - if(m_preview_value > 1.0) m_preview_value = 1.0; - return true; - } - return false; - } - - - //------------------------------------------------------------------------ - bool slider_ctrl_impl::on_mouse_button_up(double, double) - { - m_mouse_move = false; - normalize_value(true); - return true; - } - - - //------------------------------------------------------------------------ - bool slider_ctrl_impl::on_arrow_keys(bool left, bool right, bool down, bool up) - { - double d = 0.005; - if(m_num_steps) - { - d = 1.0 / m_num_steps; - } - - if(right || up) - { - m_preview_value += d; - if(m_preview_value > 1.0) m_preview_value = 1.0; - normalize_value(true); - return true; - } - - if(left || down) - { - m_preview_value -= d; - if(m_preview_value < 0.0) m_preview_value = 0.0; - normalize_value(true); - return true; - } - return false; - } - -} - diff --git a/desmume/src/windows/agg/src/ctrl/agg_spline_ctrl.cpp b/desmume/src/windows/agg/src/ctrl/agg_spline_ctrl.cpp deleted file mode 100644 index 6716607c6..000000000 --- a/desmume/src/windows/agg/src/ctrl/agg_spline_ctrl.cpp +++ /dev/null @@ -1,412 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#include "ctrl/agg_spline_ctrl.h" - - -namespace agg -{ - - //------------------------------------------------------------------------ - spline_ctrl_impl::spline_ctrl_impl(double x1, double y1, double x2, double y2, - unsigned num_pnt, bool flip_y) : - ctrl(x1, y1, x2, y2, flip_y), - m_num_pnt(num_pnt), - m_border_width(1.0), - m_border_extra(0.0), - m_curve_width(1.0), - m_point_size(3.0), - m_curve_poly(m_curve_pnt), - m_idx(0), - m_vertex(0), - m_active_pnt(-1), - m_move_pnt(-1), - m_pdx(0.0), - m_pdy(0.0) - { - if(m_num_pnt < 4) m_num_pnt = 4; - if(m_num_pnt > 32) m_num_pnt = 32; - - unsigned i; - for(i = 0; i < m_num_pnt; i++) - { - m_xp[i] = double(i) / double(m_num_pnt - 1); - m_yp[i] = 0.5; - } - calc_spline_box(); - update_spline(); - } - - - //------------------------------------------------------------------------ - void spline_ctrl_impl::border_width(double t, double extra) - { - m_border_width = t; - m_border_extra = extra; - calc_spline_box(); - } - - - //------------------------------------------------------------------------ - void spline_ctrl_impl::calc_spline_box() - { - m_xs1 = m_x1 + m_border_width; - m_ys1 = m_y1 + m_border_width; - m_xs2 = m_x2 - m_border_width; - m_ys2 = m_y2 - m_border_width; - } - - - //------------------------------------------------------------------------ - void spline_ctrl_impl::update_spline() - { - int i; - m_spline.init(m_num_pnt, m_xp, m_yp); - for(i = 0; i < 256; i++) - { - m_spline_values[i] = m_spline.get(double(i) / 255.0); - if(m_spline_values[i] < 0.0) m_spline_values[i] = 0.0; - if(m_spline_values[i] > 1.0) m_spline_values[i] = 1.0; - m_spline_values8[i] = (int8u)(m_spline_values[i] * 255.0); - } - } - - - //------------------------------------------------------------------------ - void spline_ctrl_impl::calc_curve() - { - int i; - m_curve_pnt.remove_all(); - m_curve_pnt.move_to(m_xs1, m_ys1 + (m_ys2 - m_ys1) * m_spline_values[0]); - for(i = 1; i < 256; i++) - { - m_curve_pnt.line_to(m_xs1 + (m_xs2 - m_xs1) * double(i) / 255.0, - m_ys1 + (m_ys2 - m_ys1) * m_spline_values[i]); - } - } - - - //------------------------------------------------------------------------ - double spline_ctrl_impl::calc_xp(unsigned idx) - { - return m_xs1 + (m_xs2 - m_xs1) * m_xp[idx]; - } - - - //------------------------------------------------------------------------ - double spline_ctrl_impl::calc_yp(unsigned idx) - { - return m_ys1 + (m_ys2 - m_ys1) * m_yp[idx]; - } - - - //------------------------------------------------------------------------ - void spline_ctrl_impl::set_xp(unsigned idx, double val) - { - if(val < 0.0) val = 0.0; - if(val > 1.0) val = 1.0; - - if(idx == 0) - { - val = 0.0; - } - else if(idx == m_num_pnt - 1) - { - val = 1.0; - } - else - { - if(val < m_xp[idx - 1] + 0.001) val = m_xp[idx - 1] + 0.001; - if(val > m_xp[idx + 1] - 0.001) val = m_xp[idx + 1] - 0.001; - } - m_xp[idx] = val; - } - - //------------------------------------------------------------------------ - void spline_ctrl_impl::set_yp(unsigned idx, double val) - { - if(val < 0.0) val = 0.0; - if(val > 1.0) val = 1.0; - m_yp[idx] = val; - } - - - //------------------------------------------------------------------------ - void spline_ctrl_impl::point(unsigned idx, double x, double y) - { - if(idx < m_num_pnt) - { - set_xp(idx, x); - set_yp(idx, y); - } - } - - - //------------------------------------------------------------------------ - void spline_ctrl_impl::value(unsigned idx, double y) - { - if(idx < m_num_pnt) - { - set_yp(idx, y); - } - } - - //------------------------------------------------------------------------ - double spline_ctrl_impl::value(double x) const - { - x = m_spline.get(x); - if(x < 0.0) x = 0.0; - if(x > 1.0) x = 1.0; - return x; - } - - - //------------------------------------------------------------------------ - void spline_ctrl_impl::rewind(unsigned idx) - { - unsigned i; - - m_idx = idx; - - switch(idx) - { - default: - - case 0: // Background - m_vertex = 0; - m_vx[0] = m_x1 - m_border_extra; - m_vy[0] = m_y1 - m_border_extra; - m_vx[1] = m_x2 + m_border_extra; - m_vy[1] = m_y1 - m_border_extra; - m_vx[2] = m_x2 + m_border_extra; - m_vy[2] = m_y2 + m_border_extra; - m_vx[3] = m_x1 - m_border_extra; - m_vy[3] = m_y2 + m_border_extra; - break; - - case 1: // Border - m_vertex = 0; - m_vx[0] = m_x1; - m_vy[0] = m_y1; - m_vx[1] = m_x2; - m_vy[1] = m_y1; - m_vx[2] = m_x2; - m_vy[2] = m_y2; - m_vx[3] = m_x1; - m_vy[3] = m_y2; - m_vx[4] = m_x1 + m_border_width; - m_vy[4] = m_y1 + m_border_width; - m_vx[5] = m_x1 + m_border_width; - m_vy[5] = m_y2 - m_border_width; - m_vx[6] = m_x2 - m_border_width; - m_vy[6] = m_y2 - m_border_width; - m_vx[7] = m_x2 - m_border_width; - m_vy[7] = m_y1 + m_border_width; - break; - - case 2: // Curve - calc_curve(); - m_curve_poly.width(m_curve_width); - m_curve_poly.rewind(0); - break; - - - case 3: // Inactive points - m_curve_pnt.remove_all(); - for(i = 0; i < m_num_pnt; i++) - { - if(int(i) != m_active_pnt) - { - m_ellipse.init(calc_xp(i), calc_yp(i), - m_point_size, m_point_size, 32); - m_curve_pnt.concat_path(m_ellipse); - } - } - m_curve_poly.rewind(0); - break; - - - case 4: // Active point - m_curve_pnt.remove_all(); - if(m_active_pnt >= 0) - { - m_ellipse.init(calc_xp(m_active_pnt), calc_yp(m_active_pnt), - m_point_size, m_point_size, 32); - - m_curve_pnt.concat_path(m_ellipse); - } - m_curve_poly.rewind(0); - break; - - } - } - - - //------------------------------------------------------------------------ - unsigned spline_ctrl_impl::vertex(double* x, double* y) - { - unsigned cmd = path_cmd_line_to; - switch(m_idx) - { - case 0: - if(m_vertex == 0) cmd = path_cmd_move_to; - if(m_vertex >= 4) cmd = path_cmd_stop; - *x = m_vx[m_vertex]; - *y = m_vy[m_vertex]; - m_vertex++; - break; - - case 1: - if(m_vertex == 0 || m_vertex == 4) cmd = path_cmd_move_to; - if(m_vertex >= 8) cmd = path_cmd_stop; - *x = m_vx[m_vertex]; - *y = m_vy[m_vertex]; - m_vertex++; - break; - - case 2: - cmd = m_curve_poly.vertex(x, y); - break; - - case 3: - case 4: - cmd = m_curve_pnt.vertex(x, y); - break; - - default: - cmd = path_cmd_stop; - break; - } - - if(!is_stop(cmd)) - { - transform_xy(x, y); - } - - return cmd; - } - - - - //------------------------------------------------------------------------ - void spline_ctrl_impl::active_point(int i) - { - m_active_pnt = i; - } - - - //------------------------------------------------------------------------ - bool spline_ctrl_impl::in_rect(double x, double y) const - { - inverse_transform_xy(&x, &y); - return x >= m_x1 && x <= m_x2 && y >= m_y1 && y <= m_y2; - } - - - //------------------------------------------------------------------------ - bool spline_ctrl_impl::on_mouse_button_down(double x, double y) - { - inverse_transform_xy(&x, &y); - unsigned i; - for(i = 0; i < m_num_pnt; i++) - { - double xp = calc_xp(i); - double yp = calc_yp(i); - if(calc_distance(x, y, xp, yp) <= m_point_size + 1) - { - m_pdx = xp - x; - m_pdy = yp - y; - m_active_pnt = m_move_pnt = int(i); - return true; - } - } - return false; - } - - - //------------------------------------------------------------------------ - bool spline_ctrl_impl::on_mouse_button_up(double, double) - { - if(m_move_pnt >= 0) - { - m_move_pnt = -1; - return true; - } - return false; - } - - - //------------------------------------------------------------------------ - bool spline_ctrl_impl::on_mouse_move(double x, double y, bool button_flag) - { - inverse_transform_xy(&x, &y); - if(!button_flag) - { - return on_mouse_button_up(x, y); - } - - if(m_move_pnt >= 0) - { - double xp = x + m_pdx; - double yp = y + m_pdy; - - set_xp(m_move_pnt, (xp - m_xs1) / (m_xs2 - m_xs1)); - set_yp(m_move_pnt, (yp - m_ys1) / (m_ys2 - m_ys1)); - - update_spline(); - return true; - } - return false; - } - - - //------------------------------------------------------------------------ - bool spline_ctrl_impl::on_arrow_keys(bool left, bool right, bool down, bool up) - { - double kx = 0.0; - double ky = 0.0; - bool ret = false; - if(m_active_pnt >= 0) - { - kx = m_xp[m_active_pnt]; - ky = m_yp[m_active_pnt]; - if(left) { kx -= 0.001; ret = true; } - if(right) { kx += 0.001; ret = true; } - if(down) { ky -= 0.001; ret = true; } - if(up) { ky += 0.001; ret = true; } - } - if(ret) - { - set_xp(m_active_pnt, kx); - set_yp(m_active_pnt, ky); - update_spline(); - } - return ret; - } - - - - -} - diff --git a/desmume/src/windows/agg/src/install b/desmume/src/windows/agg/src/install deleted file mode 100644 index e69de29bb..000000000 diff --git a/desmume/src/windows/agg/src/news b/desmume/src/windows/agg/src/news deleted file mode 100644 index e69de29bb..000000000 diff --git a/desmume/src/windows/agg/src/platform/win32/agg_platform_support.cpp b/desmume/src/windows/agg/src/platform/win32/agg_platform_support.cpp deleted file mode 100644 index ffcc6d197..000000000 --- a/desmume/src/windows/agg/src/platform/win32/agg_platform_support.cpp +++ /dev/null @@ -1,1478 +0,0 @@ -//---------------------------------------------------------------------------- -// Anti-Grain Geometry (AGG) - Version 2.5 -// A high quality rendering engine for C++ -// Copyright (C) 2002-2006 Maxim Shemanarev -// Contact: mcseem@antigrain.com -// mcseemagg@yahoo.com -// http://antigrain.com -// -// AGG is free software; you can redistribute it and/or -// modify it under the terms of the GNU General Public License -// as published by the Free Software Foundation; either version 2 -// of the License, or (at your option) any later version. -// -// AGG is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with AGG; if not, write to the Free Software -// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -// MA 02110-1301, USA. -//---------------------------------------------------------------------------- - -#include -#include -#include "platform/agg_platform_support.h" -#include "platform/win32/agg_win32_bmp.h" -#include "util/agg_color_conv_rgb8.h" -#include "util/agg_color_conv_rgb16.h" - - -namespace agg -{ - - //------------------------------------------------------------------------ - HINSTANCE g_windows_instance = 0; - int g_windows_cmd_show = 0; - - - //------------------------------------------------------------------------ - class platform_specific - { - public: - platform_specific(pix_format_e format, bool flip_y); - - void create_pmap(unsigned width, unsigned height, - rendering_buffer* wnd); - - void display_pmap(HDC dc, const rendering_buffer* src); - bool load_pmap(const char* fn, unsigned idx, - rendering_buffer* dst); - - bool save_pmap(const char* fn, unsigned idx, - const rendering_buffer* src); - - unsigned translate(unsigned keycode); - - pix_format_e m_format; - pix_format_e m_sys_format; - bool m_flip_y; - unsigned m_bpp; - unsigned m_sys_bpp; - HWND m_hwnd; - pixel_map m_pmap_window; - pixel_map m_pmap_img[platform_support::max_images]; - unsigned m_keymap[256]; - unsigned m_last_translated_key; - int m_cur_x; - int m_cur_y; - unsigned m_input_flags; - bool m_redraw_flag; - HDC m_current_dc; - LARGE_INTEGER m_sw_freq; - LARGE_INTEGER m_sw_start; - }; - - - //------------------------------------------------------------------------ - platform_specific::platform_specific(pix_format_e format, bool flip_y) : - m_format(format), - m_sys_format(pix_format_undefined), - m_flip_y(flip_y), - m_bpp(0), - m_sys_bpp(0), - m_hwnd(0), - m_last_translated_key(0), - m_cur_x(0), - m_cur_y(0), - m_input_flags(0), - m_redraw_flag(true), - m_current_dc(0) - { - memset(m_keymap, 0, sizeof(m_keymap)); - - m_keymap[VK_PAUSE] = key_pause; - m_keymap[VK_CLEAR] = key_clear; - - m_keymap[VK_NUMPAD0] = key_kp0; - m_keymap[VK_NUMPAD1] = key_kp1; - m_keymap[VK_NUMPAD2] = key_kp2; - m_keymap[VK_NUMPAD3] = key_kp3; - m_keymap[VK_NUMPAD4] = key_kp4; - m_keymap[VK_NUMPAD5] = key_kp5; - m_keymap[VK_NUMPAD6] = key_kp6; - m_keymap[VK_NUMPAD7] = key_kp7; - m_keymap[VK_NUMPAD8] = key_kp8; - m_keymap[VK_NUMPAD9] = key_kp9; - m_keymap[VK_DECIMAL] = key_kp_period; - m_keymap[VK_DIVIDE] = key_kp_divide; - m_keymap[VK_MULTIPLY] = key_kp_multiply; - m_keymap[VK_SUBTRACT] = key_kp_minus; - m_keymap[VK_ADD] = key_kp_plus; - - m_keymap[VK_UP] = key_up; - m_keymap[VK_DOWN] = key_down; - m_keymap[VK_RIGHT] = key_right; - m_keymap[VK_LEFT] = key_left; - m_keymap[VK_INSERT] = key_insert; - m_keymap[VK_DELETE] = key_delete; - m_keymap[VK_HOME] = key_home; - m_keymap[VK_END] = key_end; - m_keymap[VK_PRIOR] = key_page_up; - m_keymap[VK_NEXT] = key_page_down; - - m_keymap[VK_F1] = key_f1; - m_keymap[VK_F2] = key_f2; - m_keymap[VK_F3] = key_f3; - m_keymap[VK_F4] = key_f4; - m_keymap[VK_F5] = key_f5; - m_keymap[VK_F6] = key_f6; - m_keymap[VK_F7] = key_f7; - m_keymap[VK_F8] = key_f8; - m_keymap[VK_F9] = key_f9; - m_keymap[VK_F10] = key_f10; - m_keymap[VK_F11] = key_f11; - m_keymap[VK_F12] = key_f12; - m_keymap[VK_F13] = key_f13; - m_keymap[VK_F14] = key_f14; - m_keymap[VK_F15] = key_f15; - - m_keymap[VK_NUMLOCK] = key_numlock; - m_keymap[VK_CAPITAL] = key_capslock; - m_keymap[VK_SCROLL] = key_scrollock; - - - switch(m_format) - { - case pix_format_bw: - m_sys_format = pix_format_bw; - m_bpp = 1; - m_sys_bpp = 1; - break; - - case pix_format_gray8: - m_sys_format = pix_format_gray8; - m_bpp = 8; - m_sys_bpp = 8; - break; - - case pix_format_gray16: - m_sys_format = pix_format_gray8; - m_bpp = 16; - m_sys_bpp = 8; - break; - - case pix_format_rgb565: - case pix_format_rgb555: - m_sys_format = pix_format_rgb555; - m_bpp = 16; - m_sys_bpp = 16; - break; - - case pix_format_rgbAAA: - case pix_format_bgrAAA: - case pix_format_rgbBBA: - case pix_format_bgrABB: - m_sys_format = pix_format_bgr24; - m_bpp = 32; - m_sys_bpp = 24; - break; - - case pix_format_rgb24: - case pix_format_bgr24: - m_sys_format = pix_format_bgr24; - m_bpp = 24; - m_sys_bpp = 24; - break; - - case pix_format_rgb48: - case pix_format_bgr48: - m_sys_format = pix_format_bgr24; - m_bpp = 48; - m_sys_bpp = 24; - break; - - case pix_format_bgra32: - case pix_format_abgr32: - case pix_format_argb32: - case pix_format_rgba32: - m_sys_format = pix_format_bgra32; - m_bpp = 32; - m_sys_bpp = 32; - break; - - case pix_format_bgra64: - case pix_format_abgr64: - case pix_format_argb64: - case pix_format_rgba64: - m_sys_format = pix_format_bgra32; - m_bpp = 64; - m_sys_bpp = 32; - break; - } - ::QueryPerformanceFrequency(&m_sw_freq); - ::QueryPerformanceCounter(&m_sw_start); - } - - - //------------------------------------------------------------------------ - void platform_specific::create_pmap(unsigned width, - unsigned height, - rendering_buffer* wnd) - { - m_pmap_window.create(width, height, org_e(m_bpp)); - wnd->attach(m_pmap_window.buf(), - m_pmap_window.width(), - m_pmap_window.height(), - m_flip_y ? - m_pmap_window.stride() : - -m_pmap_window.stride()); - } - - - //------------------------------------------------------------------------ - static void convert_pmap(rendering_buffer* dst, - const rendering_buffer* src, - pix_format_e format) - { - switch(format) - { - case pix_format_gray8: - break; - - case pix_format_gray16: - color_conv(dst, src, color_conv_gray16_to_gray8()); - break; - - case pix_format_rgb565: - color_conv(dst, src, color_conv_rgb565_to_rgb555()); - break; - - case pix_format_rgbAAA: - color_conv(dst, src, color_conv_rgbAAA_to_bgr24()); - break; - - case pix_format_bgrAAA: - color_conv(dst, src, color_conv_bgrAAA_to_bgr24()); - break; - - case pix_format_rgbBBA: - color_conv(dst, src, color_conv_rgbBBA_to_bgr24()); - break; - - case pix_format_bgrABB: - color_conv(dst, src, color_conv_bgrABB_to_bgr24()); - break; - - case pix_format_rgb24: - color_conv(dst, src, color_conv_rgb24_to_bgr24()); - break; - - case pix_format_rgb48: - color_conv(dst, src, color_conv_rgb48_to_bgr24()); - break; - - case pix_format_bgr48: - color_conv(dst, src, color_conv_bgr48_to_bgr24()); - break; - - case pix_format_abgr32: - color_conv(dst, src, color_conv_abgr32_to_bgra32()); - break; - - case pix_format_argb32: - color_conv(dst, src, color_conv_argb32_to_bgra32()); - break; - - case pix_format_rgba32: - color_conv(dst, src, color_conv_rgba32_to_bgra32()); - break; - - case pix_format_bgra64: - color_conv(dst, src, color_conv_bgra64_to_bgra32()); - break; - - case pix_format_abgr64: - color_conv(dst, src, color_conv_abgr64_to_bgra32()); - break; - - case pix_format_argb64: - color_conv(dst, src, color_conv_argb64_to_bgra32()); - break; - - case pix_format_rgba64: - color_conv(dst, src, color_conv_rgba64_to_bgra32()); - break; - } - } - - - //------------------------------------------------------------------------ - void platform_specific::display_pmap(HDC dc, const rendering_buffer* src) - { - if(m_sys_format == m_format) - { - m_pmap_window.draw(dc); - } - else - { - pixel_map pmap_tmp; - pmap_tmp.create(m_pmap_window.width(), - m_pmap_window.height(), - org_e(m_sys_bpp)); - - rendering_buffer rbuf_tmp; - rbuf_tmp.attach(pmap_tmp.buf(), - pmap_tmp.width(), - pmap_tmp.height(), - m_flip_y ? - pmap_tmp.stride() : - -pmap_tmp.stride()); - - convert_pmap(&rbuf_tmp, src, m_format); - pmap_tmp.draw(dc); - } - } - - - - //------------------------------------------------------------------------ - bool platform_specific::save_pmap(const char* fn, unsigned idx, - const rendering_buffer* src) - { - if(m_sys_format == m_format) - { - return m_pmap_img[idx].save_as_bmp(fn); - } - - pixel_map pmap_tmp; - pmap_tmp.create(m_pmap_img[idx].width(), - m_pmap_img[idx].height(), - org_e(m_sys_bpp)); - - rendering_buffer rbuf_tmp; - rbuf_tmp.attach(pmap_tmp.buf(), - pmap_tmp.width(), - pmap_tmp.height(), - m_flip_y ? - pmap_tmp.stride() : - -pmap_tmp.stride()); - - convert_pmap(&rbuf_tmp, src, m_format); - return pmap_tmp.save_as_bmp(fn); - } - - - - //------------------------------------------------------------------------ - bool platform_specific::load_pmap(const char* fn, unsigned idx, - rendering_buffer* dst) - { - pixel_map pmap_tmp; - if(!pmap_tmp.load_from_bmp(fn)) return false; - - rendering_buffer rbuf_tmp; - rbuf_tmp.attach(pmap_tmp.buf(), - pmap_tmp.width(), - pmap_tmp.height(), - m_flip_y ? - pmap_tmp.stride() : - -pmap_tmp.stride()); - - m_pmap_img[idx].create(pmap_tmp.width(), - pmap_tmp.height(), - org_e(m_bpp), - 0); - - dst->attach(m_pmap_img[idx].buf(), - m_pmap_img[idx].width(), - m_pmap_img[idx].height(), - m_flip_y ? - m_pmap_img[idx].stride() : - -m_pmap_img[idx].stride()); - - switch(m_format) - { - case pix_format_gray8: - switch(pmap_tmp.bpp()) - { - //case 16: color_conv(dst, &rbuf_tmp, color_conv_rgb555_to_gray8()); break; - case 24: color_conv(dst, &rbuf_tmp, color_conv_bgr24_to_gray8()); break; - //case 32: color_conv(dst, &rbuf_tmp, color_conv_bgra32_to_gray8()); break; - } - break; - - case pix_format_gray16: - switch(pmap_tmp.bpp()) - { - //case 16: color_conv(dst, &rbuf_tmp, color_conv_rgb555_to_gray16()); break; - case 24: color_conv(dst, &rbuf_tmp, color_conv_bgr24_to_gray16()); break; - //case 32: color_conv(dst, &rbuf_tmp, color_conv_bgra32_to_gray16()); break; - } - break; - - case pix_format_rgb555: - switch(pmap_tmp.bpp()) - { - case 16: color_conv(dst, &rbuf_tmp, color_conv_rgb555_to_rgb555()); break; - case 24: color_conv(dst, &rbuf_tmp, color_conv_bgr24_to_rgb555()); break; - case 32: color_conv(dst, &rbuf_tmp, color_conv_bgra32_to_rgb555()); break; - } - break; - - case pix_format_rgb565: - switch(pmap_tmp.bpp()) - { - case 16: color_conv(dst, &rbuf_tmp, color_conv_rgb555_to_rgb565()); break; - case 24: color_conv(dst, &rbuf_tmp, color_conv_bgr24_to_rgb565()); break; - case 32: color_conv(dst, &rbuf_tmp, color_conv_bgra32_to_rgb565()); break; - } - break; - - case pix_format_rgb24: - switch(pmap_tmp.bpp()) - { - case 16: color_conv(dst, &rbuf_tmp, color_conv_rgb555_to_rgb24()); break; - case 24: color_conv(dst, &rbuf_tmp, color_conv_bgr24_to_rgb24()); break; - case 32: color_conv(dst, &rbuf_tmp, color_conv_bgra32_to_rgb24()); break; - } - break; - - case pix_format_bgr24: - switch(pmap_tmp.bpp()) - { - case 16: color_conv(dst, &rbuf_tmp, color_conv_rgb555_to_bgr24()); break; - case 24: color_conv(dst, &rbuf_tmp, color_conv_bgr24_to_bgr24()); break; - case 32: color_conv(dst, &rbuf_tmp, color_conv_bgra32_to_bgr24()); break; - } - break; - - case pix_format_rgb48: - switch(pmap_tmp.bpp()) - { - //case 16: color_conv(dst, &rbuf_tmp, color_conv_rgb555_to_rgb48()); break; - case 24: color_conv(dst, &rbuf_tmp, color_conv_bgr24_to_rgb48()); break; - //case 32: color_conv(dst, &rbuf_tmp, color_conv_bgra32_to_rgb48()); break; - } - break; - - case pix_format_bgr48: - switch(pmap_tmp.bpp()) - { - //case 16: color_conv(dst, &rbuf_tmp, color_conv_rgb555_to_bgr48()); break; - case 24: color_conv(dst, &rbuf_tmp, color_conv_bgr24_to_bgr48()); break; - //case 32: color_conv(dst, &rbuf_tmp, color_conv_bgra32_to_bgr48()); break; - } - break; - - case pix_format_abgr32: - switch(pmap_tmp.bpp()) - { - case 16: color_conv(dst, &rbuf_tmp, color_conv_rgb555_to_abgr32()); break; - case 24: color_conv(dst, &rbuf_tmp, color_conv_bgr24_to_abgr32()); break; - case 32: color_conv(dst, &rbuf_tmp, color_conv_bgra32_to_abgr32()); break; - } - break; - - case pix_format_argb32: - switch(pmap_tmp.bpp()) - { - case 16: color_conv(dst, &rbuf_tmp, color_conv_rgb555_to_argb32()); break; - case 24: color_conv(dst, &rbuf_tmp, color_conv_bgr24_to_argb32()); break; - case 32: color_conv(dst, &rbuf_tmp, color_conv_bgra32_to_argb32()); break; - } - break; - - case pix_format_bgra32: - switch(pmap_tmp.bpp()) - { - case 16: color_conv(dst, &rbuf_tmp, color_conv_rgb555_to_bgra32()); break; - case 24: color_conv(dst, &rbuf_tmp, color_conv_bgr24_to_bgra32()); break; - case 32: color_conv(dst, &rbuf_tmp, color_conv_bgra32_to_bgra32()); break; - } - break; - - case pix_format_rgba32: - switch(pmap_tmp.bpp()) - { - case 16: color_conv(dst, &rbuf_tmp, color_conv_rgb555_to_rgba32()); break; - case 24: color_conv(dst, &rbuf_tmp, color_conv_bgr24_to_rgba32()); break; - case 32: color_conv(dst, &rbuf_tmp, color_conv_bgra32_to_rgba32()); break; - } - break; - - case pix_format_abgr64: - switch(pmap_tmp.bpp()) - { - //case 16: color_conv(dst, &rbuf_tmp, color_conv_rgb555_to_abgr64()); break; - case 24: color_conv(dst, &rbuf_tmp, color_conv_bgr24_to_abgr64()); break; - //case 32: color_conv(dst, &rbuf_tmp, color_conv_bgra32_to_abgr64()); break; - } - break; - - case pix_format_argb64: - switch(pmap_tmp.bpp()) - { - //case 16: color_conv(dst, &rbuf_tmp, color_conv_rgb555_to_argb64()); break; - case 24: color_conv(dst, &rbuf_tmp, color_conv_bgr24_to_argb64()); break; - //case 32: color_conv(dst, &rbuf_tmp, color_conv_bgra32_to_argb64()); break; - } - break; - - case pix_format_bgra64: - switch(pmap_tmp.bpp()) - { - //case 16: color_conv(dst, &rbuf_tmp, color_conv_rgb555_to_bgra64()); break; - case 24: color_conv(dst, &rbuf_tmp, color_conv_bgr24_to_bgra64()); break; - //case 32: color_conv(dst, &rbuf_tmp, color_conv_bgra32_to_bgra64()); break; - } - break; - - case pix_format_rgba64: - switch(pmap_tmp.bpp()) - { - //case 16: color_conv(dst, &rbuf_tmp, color_conv_rgb555_to_rgba64()); break; - case 24: color_conv(dst, &rbuf_tmp, color_conv_bgr24_to_rgba64()); break; - //case 32: color_conv(dst, &rbuf_tmp, color_conv_bgra32_to_rgba64()); break; - } - break; - - } - - return true; - } - - - - - - - - - //------------------------------------------------------------------------ - unsigned platform_specific::translate(unsigned keycode) - { - return m_last_translated_key = (keycode > 255) ? 0 : m_keymap[keycode]; - } - - - - //------------------------------------------------------------------------ - platform_support::platform_support(pix_format_e format, bool flip_y) : - m_specific(new platform_specific(format, flip_y)), - m_format(format), - m_bpp(m_specific->m_bpp), - m_window_flags(0), - m_wait_mode(true), - m_flip_y(flip_y), - m_initial_width(10), - m_initial_height(10) - { - strcpy(m_caption, "Anti-Grain Geometry Application"); - } - - - //------------------------------------------------------------------------ - platform_support::~platform_support() - { - delete m_specific; - } - - - - //------------------------------------------------------------------------ - void platform_support::caption(const char* cap) - { - strcpy(m_caption, cap); - if(m_specific->m_hwnd) - { - SetWindowText(m_specific->m_hwnd, m_caption); - } - } - - //------------------------------------------------------------------------ - void platform_support::start_timer() - { - ::QueryPerformanceCounter(&(m_specific->m_sw_start)); - } - - //------------------------------------------------------------------------ - double platform_support::elapsed_time() const - { - LARGE_INTEGER stop; - ::QueryPerformanceCounter(&stop); - return double(stop.QuadPart - - m_specific->m_sw_start.QuadPart) * 1000.0 / - double(m_specific->m_sw_freq.QuadPart); - } - - - - //------------------------------------------------------------------------ - static unsigned get_key_flags(int wflags) - { - unsigned flags = 0; - if(wflags & MK_LBUTTON) flags |= mouse_left; - if(wflags & MK_RBUTTON) flags |= mouse_right; - if(wflags & MK_SHIFT) flags |= kbd_shift; - if(wflags & MK_CONTROL) flags |= kbd_ctrl; - return flags; - } - - - void* platform_support::raw_display_handler() - { - return m_specific->m_current_dc; - } - - - //------------------------------------------------------------------------ - LRESULT CALLBACK window_proc(HWND hWnd, UINT msg, WPARAM wParam, LPARAM lParam) - { - PAINTSTRUCT ps; - HDC paintDC; - - - void* user_data = reinterpret_cast(::GetWindowLong(hWnd, GWL_USERDATA)); - platform_support* app = 0; - - if(user_data) - { - app = reinterpret_cast(user_data); - } - - if(app == 0) - { - if(msg == WM_DESTROY) - { - ::PostQuitMessage(0); - return 0; - } - return ::DefWindowProc(hWnd, msg, wParam, lParam); - } - - HDC dc = ::GetDC(app->m_specific->m_hwnd); - app->m_specific->m_current_dc = dc; - LRESULT ret = 0; - - switch(msg) - { - //-------------------------------------------------------------------- - case WM_CREATE: - break; - - //-------------------------------------------------------------------- - case WM_SIZE: - app->m_specific->create_pmap(LOWORD(lParam), - HIWORD(lParam), - &app->rbuf_window()); - - app->trans_affine_resizing(LOWORD(lParam), HIWORD(lParam)); - app->on_resize(LOWORD(lParam), HIWORD(lParam)); - app->force_redraw(); - break; - - //-------------------------------------------------------------------- - case WM_ERASEBKGND: - break; - - //-------------------------------------------------------------------- - case WM_LBUTTONDOWN: - ::SetCapture(app->m_specific->m_hwnd); - app->m_specific->m_cur_x = int16(LOWORD(lParam)); - if(app->flip_y()) - { - app->m_specific->m_cur_y = app->rbuf_window().height() - int16(HIWORD(lParam)); - } - else - { - app->m_specific->m_cur_y = int16(HIWORD(lParam)); - } - app->m_specific->m_input_flags = mouse_left | get_key_flags(wParam); - - app->m_ctrls.set_cur(app->m_specific->m_cur_x, - app->m_specific->m_cur_y); - if(app->m_ctrls.on_mouse_button_down(app->m_specific->m_cur_x, - app->m_specific->m_cur_y)) - { - app->on_ctrl_change(); - app->force_redraw(); - } - else - { - if(app->m_ctrls.in_rect(app->m_specific->m_cur_x, - app->m_specific->m_cur_y)) - { - if(app->m_ctrls.set_cur(app->m_specific->m_cur_x, - app->m_specific->m_cur_y)) - { - app->on_ctrl_change(); - app->force_redraw(); - } - } - else - { - app->on_mouse_button_down(app->m_specific->m_cur_x, - app->m_specific->m_cur_y, - app->m_specific->m_input_flags); - } - } -/* - if(!app->wait_mode()) - { - app->on_idle(); - } -*/ - break; - - //-------------------------------------------------------------------- - case WM_LBUTTONUP: - ::ReleaseCapture(); - app->m_specific->m_cur_x = int16(LOWORD(lParam)); - if(app->flip_y()) - { - app->m_specific->m_cur_y = app->rbuf_window().height() - int16(HIWORD(lParam)); - } - else - { - app->m_specific->m_cur_y = int16(HIWORD(lParam)); - } - app->m_specific->m_input_flags = mouse_left | get_key_flags(wParam); - - if(app->m_ctrls.on_mouse_button_up(app->m_specific->m_cur_x, - app->m_specific->m_cur_y)) - { - app->on_ctrl_change(); - app->force_redraw(); - } - app->on_mouse_button_up(app->m_specific->m_cur_x, - app->m_specific->m_cur_y, - app->m_specific->m_input_flags); -/* - if(!app->wait_mode()) - { - app->on_idle(); - } -*/ - break; - - - //-------------------------------------------------------------------- - case WM_RBUTTONDOWN: - ::SetCapture(app->m_specific->m_hwnd); - app->m_specific->m_cur_x = int16(LOWORD(lParam)); - if(app->flip_y()) - { - app->m_specific->m_cur_y = app->rbuf_window().height() - int16(HIWORD(lParam)); - } - else - { - app->m_specific->m_cur_y = int16(HIWORD(lParam)); - } - app->m_specific->m_input_flags = mouse_right | get_key_flags(wParam); - app->on_mouse_button_down(app->m_specific->m_cur_x, - app->m_specific->m_cur_y, - app->m_specific->m_input_flags); -/* - if(!app->wait_mode()) - { - app->on_idle(); - } -*/ - break; - - //-------------------------------------------------------------------- - case WM_RBUTTONUP: - ::ReleaseCapture(); - app->m_specific->m_cur_x = int16(LOWORD(lParam)); - if(app->flip_y()) - { - app->m_specific->m_cur_y = app->rbuf_window().height() - int16(HIWORD(lParam)); - } - else - { - app->m_specific->m_cur_y = int16(HIWORD(lParam)); - } - app->m_specific->m_input_flags = mouse_right | get_key_flags(wParam); - app->on_mouse_button_up(app->m_specific->m_cur_x, - app->m_specific->m_cur_y, - app->m_specific->m_input_flags); -/* - if(!app->wait_mode()) - { - app->on_idle(); - } -*/ - break; - - //-------------------------------------------------------------------- - case WM_MOUSEMOVE: - app->m_specific->m_cur_x = int16(LOWORD(lParam)); - if(app->flip_y()) - { - app->m_specific->m_cur_y = app->rbuf_window().height() - int16(HIWORD(lParam)); - } - else - { - app->m_specific->m_cur_y = int16(HIWORD(lParam)); - } - app->m_specific->m_input_flags = get_key_flags(wParam); - - - if(app->m_ctrls.on_mouse_move( - app->m_specific->m_cur_x, - app->m_specific->m_cur_y, - (app->m_specific->m_input_flags & mouse_left) != 0)) - { - app->on_ctrl_change(); - app->force_redraw(); - } - else - { - if(!app->m_ctrls.in_rect(app->m_specific->m_cur_x, - app->m_specific->m_cur_y)) - { - app->on_mouse_move(app->m_specific->m_cur_x, - app->m_specific->m_cur_y, - app->m_specific->m_input_flags); - } - } -/* - if(!app->wait_mode()) - { - app->on_idle(); - } -*/ - break; - - //-------------------------------------------------------------------- - case WM_SYSKEYDOWN: - case WM_KEYDOWN: - app->m_specific->m_last_translated_key = 0; - switch(wParam) - { - case VK_CONTROL: - app->m_specific->m_input_flags |= kbd_ctrl; - break; - - case VK_SHIFT: - app->m_specific->m_input_flags |= kbd_shift; - break; - - default: - app->m_specific->translate(wParam); - break; - } - - if(app->m_specific->m_last_translated_key) - { - bool left = false; - bool up = false; - bool right = false; - bool down = false; - - switch(app->m_specific->m_last_translated_key) - { - case key_left: - left = true; - break; - - case key_up: - up = true; - break; - - case key_right: - right = true; - break; - - case key_down: - down = true; - break; - - case key_f2: - app->copy_window_to_img(agg::platform_support::max_images - 1); - app->save_img(agg::platform_support::max_images - 1, "screenshot"); - break; - } - - if(app->window_flags() & window_process_all_keys) - { - app->on_key(app->m_specific->m_cur_x, - app->m_specific->m_cur_y, - app->m_specific->m_last_translated_key, - app->m_specific->m_input_flags); - } - else - { - if(app->m_ctrls.on_arrow_keys(left, right, down, up)) - { - app->on_ctrl_change(); - app->force_redraw(); - } - else - { - app->on_key(app->m_specific->m_cur_x, - app->m_specific->m_cur_y, - app->m_specific->m_last_translated_key, - app->m_specific->m_input_flags); - } - } - } -/* - if(!app->wait_mode()) - { - app->on_idle(); - } -*/ - break; - - //-------------------------------------------------------------------- - case WM_SYSKEYUP: - case WM_KEYUP: - app->m_specific->m_last_translated_key = 0; - switch(wParam) - { - case VK_CONTROL: - app->m_specific->m_input_flags &= ~kbd_ctrl; - break; - - case VK_SHIFT: - app->m_specific->m_input_flags &= ~kbd_shift; - break; - } - break; - - //-------------------------------------------------------------------- - case WM_CHAR: - case WM_SYSCHAR: - if(app->m_specific->m_last_translated_key == 0) - { - app->on_key(app->m_specific->m_cur_x, - app->m_specific->m_cur_y, - wParam, - app->m_specific->m_input_flags); - } - break; - - //-------------------------------------------------------------------- - case WM_PAINT: - paintDC = ::BeginPaint(hWnd, &ps); - app->m_specific->m_current_dc = paintDC; - if(app->m_specific->m_redraw_flag) - { - app->on_draw(); - app->m_specific->m_redraw_flag = false; - } - app->m_specific->display_pmap(paintDC, &app->rbuf_window()); - app->on_post_draw(paintDC); - app->m_specific->m_current_dc = 0; - ::EndPaint(hWnd, &ps); - break; - - //-------------------------------------------------------------------- - case WM_COMMAND: - break; - - //-------------------------------------------------------------------- - case WM_DESTROY: - ::PostQuitMessage(0); - break; - - //-------------------------------------------------------------------- - default: - ret = ::DefWindowProc(hWnd, msg, wParam, lParam); - break; - } - app->m_specific->m_current_dc = 0; - ::ReleaseDC(app->m_specific->m_hwnd, dc); - return ret; - } - - - //------------------------------------------------------------------------ - void platform_support::message(const char* msg) - { - ::MessageBox(m_specific->m_hwnd, msg, "AGG Message", MB_OK); - } - - - //------------------------------------------------------------------------ - bool platform_support::init(unsigned width, unsigned height, unsigned flags) - { - if(m_specific->m_sys_format == pix_format_undefined) - { - return false; - } - - m_window_flags = flags; - - int wflags = CS_OWNDC | CS_VREDRAW | CS_HREDRAW; - - WNDCLASS wc; - wc.lpszClassName = "AGGAppClass"; - wc.lpfnWndProc = window_proc; - wc.style = wflags; - wc.hInstance = g_windows_instance; - wc.hIcon = LoadIcon(0, IDI_APPLICATION); - wc.hCursor = LoadCursor(0, IDC_ARROW); - wc.hbrBackground = (HBRUSH)(COLOR_WINDOW+1); - wc.lpszMenuName = "AGGAppMenu"; - wc.cbClsExtra = 0; - wc.cbWndExtra = 0; - ::RegisterClass(&wc); - - wflags = WS_OVERLAPPED | WS_CAPTION | WS_SYSMENU | WS_MINIMIZEBOX; - - if(m_window_flags & window_resize) - { - wflags |= WS_THICKFRAME | WS_MAXIMIZEBOX; - } - - m_specific->m_hwnd = ::CreateWindow("AGGAppClass", - m_caption, - wflags, - 100, - 100, - width, - height, - 0, - 0, - g_windows_instance, - 0); - - if(m_specific->m_hwnd == 0) - { - return false; - } - - - RECT rct; - ::GetClientRect(m_specific->m_hwnd, &rct); - - ::MoveWindow(m_specific->m_hwnd, // handle to window - 100, // horizontal position - 100, // vertical position - width + (width - (rct.right - rct.left)), - height + (height - (rct.bottom - rct.top)), - FALSE); - - ::SetWindowLong(m_specific->m_hwnd, GWL_USERDATA, (LONG)this); - m_specific->create_pmap(width, height, &m_rbuf_window); - m_initial_width = width; - m_initial_height = height; - on_init(); - m_specific->m_redraw_flag = true; - ::ShowWindow(m_specific->m_hwnd, g_windows_cmd_show); - return true; - } - - - - //------------------------------------------------------------------------ - int platform_support::run() - { - MSG msg; - - for(;;) - { - if(m_wait_mode) - { - if(!::GetMessage(&msg, 0, 0, 0)) - { - break; - } - ::TranslateMessage(&msg); - ::DispatchMessage(&msg); - } - else - { - if(::PeekMessage(&msg, 0, 0, 0, PM_REMOVE)) - { - ::TranslateMessage(&msg); - if(msg.message == WM_QUIT) - { - break; - } - ::DispatchMessage(&msg); - } - else - { - on_idle(); - } - } - } - return (int)msg.wParam; - } - - - //------------------------------------------------------------------------ - const char* platform_support::img_ext() const { return ".bmp"; } - - - //------------------------------------------------------------------------ - const char* platform_support::full_file_name(const char* file_name) - { - return file_name; - } - - //------------------------------------------------------------------------ - bool platform_support::load_img(unsigned idx, const char* file) - { - if(idx < max_images) - { - char fn[1024]; - strcpy(fn, file); - int len = strlen(fn); - if(len < 4 || stricmp(fn + len - 4, ".BMP") != 0) - { - strcat(fn, ".bmp"); - } - return m_specific->load_pmap(fn, idx, &m_rbuf_img[idx]); - } - return true; - } - - - - //------------------------------------------------------------------------ - bool platform_support::save_img(unsigned idx, const char* file) - { - if(idx < max_images) - { - char fn[1024]; - strcpy(fn, file); - int len = strlen(fn); - if(len < 4 || stricmp(fn + len - 4, ".BMP") != 0) - { - strcat(fn, ".bmp"); - } - return m_specific->save_pmap(fn, idx, &m_rbuf_img[idx]); - } - return true; - } - - - - //------------------------------------------------------------------------ - bool platform_support::create_img(unsigned idx, unsigned width, unsigned height) - { - if(idx < max_images) - { - if(width == 0) width = m_specific->m_pmap_window.width(); - if(height == 0) height = m_specific->m_pmap_window.height(); - m_specific->m_pmap_img[idx].create(width, height, org_e(m_specific->m_bpp)); - m_rbuf_img[idx].attach(m_specific->m_pmap_img[idx].buf(), - m_specific->m_pmap_img[idx].width(), - m_specific->m_pmap_img[idx].height(), - m_flip_y ? - m_specific->m_pmap_img[idx].stride() : - -m_specific->m_pmap_img[idx].stride()); - return true; - } - return false; - } - - - //------------------------------------------------------------------------ - void platform_support::force_redraw() - { - m_specific->m_redraw_flag = true; - ::InvalidateRect(m_specific->m_hwnd, 0, FALSE); - } - - - - //------------------------------------------------------------------------ - void platform_support::update_window() - { - HDC dc = ::GetDC(m_specific->m_hwnd); - m_specific->display_pmap(dc, &m_rbuf_window); - ::ReleaseDC(m_specific->m_hwnd, dc); - } - - - //------------------------------------------------------------------------ - void platform_support::on_init() {} - void platform_support::on_resize(int sx, int sy) {} - void platform_support::on_idle() {} - void platform_support::on_mouse_move(int x, int y, unsigned flags) {} - void platform_support::on_mouse_button_down(int x, int y, unsigned flags) {} - void platform_support::on_mouse_button_up(int x, int y, unsigned flags) {} - void platform_support::on_key(int x, int y, unsigned key, unsigned flags) {} - void platform_support::on_ctrl_change() {} - void platform_support::on_draw() {} - void platform_support::on_post_draw(void* raw_handler) {} -} - - - - -namespace agg -{ - // That's ridiculous. I have to parse the command line by myself - // because Windows doesn't provide a method of getting the command - // line arguments in a form of argc, argv. Of course, there's - // CommandLineToArgv() but first, it returns Unicode that I don't - // need to deal with, but most of all, it's not compatible with Win98. - //----------------------------------------------------------------------- - class tokenizer - { - public: - enum sep_flag - { - single, - multiple, - whole_str - }; - - struct token - { - const char* ptr; - unsigned len; - }; - - public: - tokenizer(const char* sep, - const char* trim=0, - const char* quote="\"", - char mask_chr='\\', - sep_flag sf=multiple); - - void set_str(const char* str); - token next_token(); - - private: - int check_chr(const char *str, char chr); - - private: - const char* m_src_string; - int m_start; - const char* m_sep; - const char* m_trim; - const char* m_quote; - char m_mask_chr; - unsigned m_sep_len; - sep_flag m_sep_flag; - }; - - - - //----------------------------------------------------------------------- - inline void tokenizer::set_str(const char* str) - { - m_src_string = str; - m_start = 0; - } - - - //----------------------------------------------------------------------- - inline int tokenizer::check_chr(const char *str, char chr) - { - return int(strchr(str, chr)); - } - - - //----------------------------------------------------------------------- - tokenizer::tokenizer(const char* sep, - const char* trim, - const char* quote, - char mask_chr, - sep_flag sf) : - m_src_string(0), - m_start(0), - m_sep(sep), - m_trim(trim), - m_quote(quote), - m_mask_chr(mask_chr), - m_sep_len(sep ? strlen(sep) : 0), - m_sep_flag(sep ? sf : single) - { - } - - - //----------------------------------------------------------------------- - tokenizer::token tokenizer::next_token() - { - unsigned count = 0; - char quote_chr = 0; - token tok; - - tok.ptr = 0; - tok.len = 0; - if(m_src_string == 0 || m_start == -1) return tok; - - register const char *pstr = m_src_string + m_start; - - if(*pstr == 0) - { - m_start = -1; - return tok; - } - - int sep_len = 1; - if(m_sep_flag == whole_str) sep_len = m_sep_len; - - if(m_sep_flag == multiple) - { - //Pass all the separator symbols at the begin of the string - while(*pstr && check_chr(m_sep, *pstr)) - { - ++pstr; - ++m_start; - } - } - - if(*pstr == 0) - { - m_start = -1; - return tok; - } - - for(count = 0;; ++count) - { - char c = *pstr; - int found = 0; - - //We are outside of qotation: find one of separator symbols - if(quote_chr == 0) - { - if(sep_len == 1) - { - found = check_chr(m_sep, c); - } - else - { - found = strncmp(m_sep, pstr, m_sep_len) == 0; - } - } - - ++pstr; - - if(c == 0 || found) - { - if(m_trim) - { - while(count && - check_chr(m_trim, m_src_string[m_start])) - { - ++m_start; - --count; - } - - while(count && - check_chr(m_trim, m_src_string[m_start + count - 1])) - { - --count; - } - } - - tok.ptr = m_src_string + m_start; - tok.len = count; - - //Next time it will be the next separator character - //But we must check, whether it is NOT the end of the string. - m_start += count; - if(c) - { - m_start += sep_len; - if(m_sep_flag == multiple) - { - //Pass all the separator symbols - //after the end of the string - while(check_chr(m_sep, m_src_string[m_start])) - { - ++m_start; - } - } - } - break; - } - - //Switch quote. If it is not a quote yet, try to check any of - //quote symbols. Otherwise quote must be finished with quote_symb - if(quote_chr == 0) - { - if(check_chr(m_quote, c)) - { - quote_chr = c; - continue; - } - } - else - { - //We are inside quote: pass all the mask symbols - if(m_mask_chr && c == m_mask_chr) - { - if(*pstr) - { - ++count; - ++pstr; - } - continue; - } - if(c == quote_chr) - { - quote_chr = 0; - continue; - } - } - } - return tok; - } - - -} - - - -//---------------------------------------------------------------------------- -int agg_main(int argc, char* argv[]); - - - -//---------------------------------------------------------------------------- -/*int PASCAL WinMain(HINSTANCE hInstance, - HINSTANCE hPrevInstance, - LPSTR lpszCmdLine, - int nCmdShow) -{ - agg::g_windows_instance = hInstance; - agg::g_windows_cmd_show = nCmdShow; - - char* argv_str = new char [strlen(lpszCmdLine) + 3]; - char* argv_ptr = argv_str; - - char* argv[64]; - memset(argv, 0, sizeof(argv)); - - agg::tokenizer cmd_line(" ", "\"' ", "\"'", '\\', agg::tokenizer::multiple); - cmd_line.set_str(lpszCmdLine); - - int argc = 0; - argv[argc++] = argv_ptr; - *argv_ptr++ = 0; - - while(argc < 64) - { - agg::tokenizer::token tok = cmd_line.next_token(); - if(tok.ptr == 0) break; - if(tok.len) - { - memcpy(argv_ptr, tok.ptr, tok.len); - argv[argc++] = argv_ptr; - argv_ptr += tok.len; - *argv_ptr++ = 0; - } - } - - int ret = agg_main(argc, argv); - delete [] argv_str; - - return ret; -}*/ - - - - diff --git a/desmume/src/windows/agg/src/platform/win32/agg_win32_bmp.cpp b/desmume/src/windows/agg/src/platform/win32/agg_win32_bmp.cpp deleted file mode 100644 index 249eac947..000000000 --- a/desmume/src/windows/agg/src/platform/win32/agg_win32_bmp.cpp +++ /dev/null @@ -1,625 +0,0 @@ -//---------------------------------------------------------------------------- -// -//---------------------------------------------------------------------------- -// Contact: mcseemagg@yahoo.com -//---------------------------------------------------------------------------- -// -// class pixel_map -// -//---------------------------------------------------------------------------- - -#include "platform/win32/agg_win32_bmp.h" -#include "agg_basics.h" - -namespace agg -{ - - //------------------------------------------------------------------------ - pixel_map::~pixel_map() - { - destroy(); - } - - - //------------------------------------------------------------------------ - pixel_map::pixel_map() : - m_bmp(0), - m_buf(0), - m_bpp(0), - m_is_internal(false), - m_img_size(0), - m_full_size(0) - - { - } - - - //------------------------------------------------------------------------ - void pixel_map::destroy() - { - if(m_bmp && m_is_internal) delete [] (unsigned char*)m_bmp; - m_bmp = 0; - m_is_internal = false; - m_buf = 0; - } - - - //------------------------------------------------------------------------ - void pixel_map::create(unsigned width, - unsigned height, - org_e org, - unsigned clear_val) - { - destroy(); - if(width == 0) width = 1; - if(height == 0) height = 1; - m_bpp = org; - create_from_bmp(create_bitmap_info(width, height, m_bpp)); - create_gray_scale_palette(m_bmp); - m_is_internal = true; - if(clear_val <= 255) - { - memset(m_buf, clear_val, m_img_size); - } - } - - - //------------------------------------------------------------------------ - HBITMAP pixel_map::create_dib_section(HDC h_dc, - unsigned width, - unsigned height, - org_e org, - unsigned clear_val) - { - destroy(); - if(width == 0) width = 1; - if(height == 0) height = 1; - m_bpp = org; - HBITMAP h_bitmap = create_dib_section_from_args(h_dc, width, height, m_bpp); - create_gray_scale_palette(m_bmp); - m_is_internal = true; - if(clear_val <= 255) - { - memset(m_buf, clear_val, m_img_size); - } - return h_bitmap; - } - - - - //------------------------------------------------------------------------ - void pixel_map::clear(unsigned clear_val) - { - if(m_buf) memset(m_buf, clear_val, m_img_size); - } - - - //------------------------------------------------------------------------ - void pixel_map::attach_to_bmp(BITMAPINFO *bmp) - { - if(bmp) - { - destroy(); - create_from_bmp(bmp); - m_is_internal = false; - } - } - - - - //static - //------------------------------------------------------------------------ - unsigned pixel_map::calc_full_size(BITMAPINFO *bmp) - { - if(bmp == 0) return 0; - - return sizeof(BITMAPINFOHEADER) + - sizeof(RGBQUAD) * calc_palette_size(bmp) + - bmp->bmiHeader.biSizeImage; - } - - //static - //------------------------------------------------------------------------ - unsigned pixel_map::calc_header_size(BITMAPINFO *bmp) - { - if(bmp == 0) return 0; - return sizeof(BITMAPINFOHEADER) + sizeof(RGBQUAD) * calc_palette_size(bmp); - } - - - //static - //------------------------------------------------------------------------ - unsigned pixel_map::calc_palette_size(unsigned clr_used, unsigned bits_per_pixel) - { - int palette_size = 0; - - if(bits_per_pixel <= 8) - { - palette_size = clr_used; - if(palette_size == 0) - { - palette_size = 1 << bits_per_pixel; - } - } - return palette_size; - } - - //static - //------------------------------------------------------------------------ - unsigned pixel_map::calc_palette_size(BITMAPINFO *bmp) - { - if(bmp == 0) return 0; - return calc_palette_size(bmp->bmiHeader.biClrUsed, bmp->bmiHeader.biBitCount); - } - - - //static - //------------------------------------------------------------------------ - unsigned char * pixel_map::calc_img_ptr(BITMAPINFO *bmp) - { - if(bmp == 0) return 0; - return ((unsigned char*)bmp) + calc_header_size(bmp); - } - - //static - //------------------------------------------------------------------------ - BITMAPINFO* pixel_map::create_bitmap_info(unsigned width, - unsigned height, - unsigned bits_per_pixel) - { - unsigned line_len = calc_row_len(width, bits_per_pixel); - unsigned img_size = line_len * height; - unsigned rgb_size = calc_palette_size(0, bits_per_pixel) * sizeof(RGBQUAD); - unsigned full_size = sizeof(BITMAPINFOHEADER) + rgb_size + img_size; - - BITMAPINFO *bmp = (BITMAPINFO *) new unsigned char[full_size]; - - bmp->bmiHeader.biSize = sizeof(BITMAPINFOHEADER); - bmp->bmiHeader.biWidth = width; - bmp->bmiHeader.biHeight = height; - bmp->bmiHeader.biPlanes = 1; - bmp->bmiHeader.biBitCount = (unsigned short)bits_per_pixel; - bmp->bmiHeader.biCompression = 0; - bmp->bmiHeader.biSizeImage = img_size; - bmp->bmiHeader.biXPelsPerMeter = 0; - bmp->bmiHeader.biYPelsPerMeter = 0; - bmp->bmiHeader.biClrUsed = 0; - bmp->bmiHeader.biClrImportant = 0; - - return bmp; - } - - - //static - //------------------------------------------------------------------------ - void pixel_map::create_gray_scale_palette(BITMAPINFO *bmp) - { - if(bmp == 0) return; - - unsigned rgb_size = calc_palette_size(bmp); - RGBQUAD *rgb = (RGBQUAD*)(((unsigned char*)bmp) + sizeof(BITMAPINFOHEADER)); - unsigned brightness; - unsigned i; - - for(i = 0; i < rgb_size; i++) - { - brightness = (255 * i) / (rgb_size - 1); - rgb->rgbBlue = - rgb->rgbGreen = - rgb->rgbRed = (unsigned char)brightness; - rgb->rgbReserved = 0; - rgb++; - } - } - - - - //static - //------------------------------------------------------------------------ - unsigned pixel_map::calc_row_len(unsigned width, unsigned bits_per_pixel) - { - unsigned n = width; - unsigned k; - - switch(bits_per_pixel) - { - case 1: k = n; - n = n >> 3; - if(k & 7) n++; - break; - - case 4: k = n; - n = n >> 1; - if(k & 3) n++; - break; - - case 8: - break; - - case 16: n *= 2; - break; - - case 24: n *= 3; - break; - - case 32: n *= 4; - break; - - case 48: n *= 6; - break; - - case 64: n *= 8; - break; - - default: n = 0; - break; - } - return ((n + 3) >> 2) << 2; - } - - - - - - //------------------------------------------------------------------------ - void pixel_map::draw(HDC h_dc, const RECT *device_rect, const RECT *bmp_rect) const - { - if(m_bmp == 0 || m_buf == 0) return; - - unsigned bmp_x = 0; - unsigned bmp_y = 0; - unsigned bmp_width = m_bmp->bmiHeader.biWidth; - unsigned bmp_height = m_bmp->bmiHeader.biHeight; - unsigned dvc_x = 0; - unsigned dvc_y = 0; - unsigned dvc_width = m_bmp->bmiHeader.biWidth; - unsigned dvc_height = m_bmp->bmiHeader.biHeight; - - if(bmp_rect) - { - bmp_x = bmp_rect->left; - bmp_y = bmp_rect->top; - bmp_width = bmp_rect->right - bmp_rect->left; - bmp_height = bmp_rect->bottom - bmp_rect->top; - } - - dvc_x = bmp_x; - dvc_y = bmp_y; - dvc_width = bmp_width; - dvc_height = bmp_height; - - if(device_rect) - { - dvc_x = device_rect->left; - dvc_y = device_rect->top; - dvc_width = device_rect->right - device_rect->left; - dvc_height = device_rect->bottom - device_rect->top; - } - - if(dvc_width != bmp_width || dvc_height != bmp_height) - { - ::SetStretchBltMode(h_dc, COLORONCOLOR); - ::StretchDIBits( - h_dc, // handle of device context - dvc_x, // x-coordinate of upper-left corner of source rect. - dvc_y, // y-coordinate of upper-left corner of source rect. - dvc_width, // width of source rectangle - dvc_height, // height of source rectangle - bmp_x, - bmp_y, // x, y -coordinates of upper-left corner of dest. rect. - bmp_width, // width of destination rectangle - bmp_height, // height of destination rectangle - m_buf, // address of bitmap bits - m_bmp, // address of bitmap data - DIB_RGB_COLORS, // usage - SRCCOPY // raster operation code - ); - } - else - { - ::SetDIBitsToDevice( - h_dc, // handle to device context - dvc_x, // x-coordinate of upper-left corner of - dvc_y, // y-coordinate of upper-left corner of - dvc_width, // source rectangle width - dvc_height, // source rectangle height - bmp_x, // x-coordinate of lower-left corner of - bmp_y, // y-coordinate of lower-left corner of - 0, // first scan line in array - bmp_height, // number of scan lines - m_buf, // address of array with DIB bits - m_bmp, // address of structure with bitmap info. - DIB_RGB_COLORS // RGB or palette indexes - ); - } - } - - - //------------------------------------------------------------------------ - void pixel_map::draw(HDC h_dc, int x, int y, double scale) const - { - if(m_bmp == 0 || m_buf == 0) return; - - unsigned width = unsigned(m_bmp->bmiHeader.biWidth * scale); - unsigned height = unsigned(m_bmp->bmiHeader.biHeight * scale); - RECT rect; - rect.left = x; - rect.top = y; - rect.right = x + width; - rect.bottom = y + height; - draw(h_dc, &rect); - } - - - - - //------------------------------------------------------------------------ - void pixel_map::blend(HDC h_dc, const RECT *device_rect, const RECT *bmp_rect) const - { -#if !defined(AGG_BMP_ALPHA_BLEND) - draw(h_dc, device_rect, bmp_rect); - return; -#else - if(m_bpp != 32) - { - draw(h_dc, device_rect, bmp_rect); - return; - } - - if(m_bmp == 0 || m_buf == 0) return; - - unsigned bmp_x = 0; - unsigned bmp_y = 0; - unsigned bmp_width = m_bmp->bmiHeader.biWidth; - unsigned bmp_height = m_bmp->bmiHeader.biHeight; - unsigned dvc_x = 0; - unsigned dvc_y = 0; - unsigned dvc_width = m_bmp->bmiHeader.biWidth; - unsigned dvc_height = m_bmp->bmiHeader.biHeight; - - if(bmp_rect) - { - bmp_x = bmp_rect->left; - bmp_y = bmp_rect->top; - bmp_width = bmp_rect->right - bmp_rect->left; - bmp_height = bmp_rect->bottom - bmp_rect->top; - } - - dvc_x = bmp_x; - dvc_y = bmp_y; - dvc_width = bmp_width; - dvc_height = bmp_height; - - if(device_rect) - { - dvc_x = device_rect->left; - dvc_y = device_rect->top; - dvc_width = device_rect->right - device_rect->left; - dvc_height = device_rect->bottom - device_rect->top; - } - - HDC mem_dc = ::CreateCompatibleDC(h_dc); - void* buf = 0; - HBITMAP bmp = ::CreateDIBSection( - mem_dc, - m_bmp, - DIB_RGB_COLORS, - &buf, - 0, - 0 - ); - memcpy(buf, m_buf, m_bmp->bmiHeader.biSizeImage); - - HBITMAP temp = (HBITMAP)::SelectObject(mem_dc, bmp); - - BLENDFUNCTION blend; - blend.BlendOp = AC_SRC_OVER; - blend.BlendFlags = 0; - -#if defined(AC_SRC_ALPHA) - blend.AlphaFormat = AC_SRC_ALPHA; -//#elif defined(AC_SRC_NO_PREMULT_ALPHA) -// blend.AlphaFormat = AC_SRC_NO_PREMULT_ALPHA; -#else -#error "No appropriate constant for alpha format. Check version of wingdi.h, There must be AC_SRC_ALPHA or AC_SRC_NO_PREMULT_ALPHA" -#endif - - blend.SourceConstantAlpha = 255; - ::AlphaBlend( - h_dc, - dvc_x, - dvc_y, - dvc_width, - dvc_height, - mem_dc, - bmp_x, - bmp_y, - bmp_width, - bmp_height, - blend - ); - - ::SelectObject(mem_dc, temp); - ::DeleteObject(bmp); - ::DeleteObject(mem_dc); -#endif //defined(AGG_BMP_ALPHA_BLEND) - } - - - //------------------------------------------------------------------------ - void pixel_map::blend(HDC h_dc, int x, int y, double scale) const - { - if(m_bmp == 0 || m_buf == 0) return; - unsigned width = unsigned(m_bmp->bmiHeader.biWidth * scale); - unsigned height = unsigned(m_bmp->bmiHeader.biHeight * scale); - RECT rect; - rect.left = x; - rect.top = y; - rect.right = x + width; - rect.bottom = y + height; - blend(h_dc, &rect); - } - - - //------------------------------------------------------------------------ - bool pixel_map::load_from_bmp(FILE *fd) - { - BITMAPFILEHEADER bmf; - BITMAPINFO *bmi = 0; - unsigned bmp_size; - - fread(&bmf, sizeof(bmf), 1, fd); - if(bmf.bfType != 0x4D42) goto bmperr; - - bmp_size = bmf.bfSize - sizeof(BITMAPFILEHEADER); - - bmi = (BITMAPINFO*) new unsigned char [bmp_size]; - if(fread(bmi, 1, bmp_size, fd) != bmp_size) goto bmperr; - destroy(); - m_bpp = bmi->bmiHeader.biBitCount; - create_from_bmp(bmi); - m_is_internal = 1; - return true; - - bmperr: - if(bmi) delete [] (unsigned char*) bmi; - return false; - } - - - - //------------------------------------------------------------------------ - bool pixel_map::load_from_bmp(const char *filename) - { - FILE *fd = fopen(filename, "rb"); - bool ret = false; - if(fd) - { - ret = load_from_bmp(fd); - fclose(fd); - } - return ret; - } - - - - //------------------------------------------------------------------------ - bool pixel_map::save_as_bmp(FILE *fd) const - { - if(m_bmp == 0) return 0; - - BITMAPFILEHEADER bmf; - - bmf.bfType = 0x4D42; - bmf.bfOffBits = calc_header_size(m_bmp) + sizeof(bmf); - bmf.bfSize = bmf.bfOffBits + m_img_size; - bmf.bfReserved1 = 0; - bmf.bfReserved2 = 0; - - fwrite(&bmf, sizeof(bmf), 1, fd); - fwrite(m_bmp, m_full_size, 1, fd); - return true; - } - - - - //------------------------------------------------------------------------ - bool pixel_map::save_as_bmp(const char *filename) const - { - FILE *fd = fopen(filename, "wb"); - bool ret = false; - if(fd) - { - ret = save_as_bmp(fd); - fclose(fd); - } - return ret; - } - - - //------------------------------------------------------------------------ - unsigned char* pixel_map::buf() - { - return m_buf; - } - - //------------------------------------------------------------------------ - unsigned pixel_map::width() const - { - return m_bmp->bmiHeader.biWidth; - } - - //------------------------------------------------------------------------ - unsigned pixel_map::height() const - { - return m_bmp->bmiHeader.biHeight; - } - - //------------------------------------------------------------------------ - int pixel_map::stride() const - { - return calc_row_len(m_bmp->bmiHeader.biWidth, - m_bmp->bmiHeader.biBitCount); - } - - - //private - //------------------------------------------------------------------------ - void pixel_map::create_from_bmp(BITMAPINFO *bmp) - { - if(bmp) - { - m_img_size = calc_row_len(bmp->bmiHeader.biWidth, - bmp->bmiHeader.biBitCount) * - bmp->bmiHeader.biHeight; - - m_full_size = calc_full_size(bmp); - m_bmp = bmp; - m_buf = calc_img_ptr(bmp); - } - } - - - //private - //------------------------------------------------------------------------ - HBITMAP pixel_map::create_dib_section_from_args(HDC h_dc, - unsigned width, - unsigned height, - unsigned bits_per_pixel) - { - unsigned line_len = calc_row_len(width, bits_per_pixel); - unsigned img_size = line_len * height; - unsigned rgb_size = calc_palette_size(0, bits_per_pixel) * sizeof(RGBQUAD); - unsigned full_size = sizeof(BITMAPINFOHEADER) + rgb_size; - - BITMAPINFO *bmp = (BITMAPINFO *) new unsigned char[full_size]; - - bmp->bmiHeader.biSize = sizeof(BITMAPINFOHEADER); - bmp->bmiHeader.biWidth = width; - bmp->bmiHeader.biHeight = height; - bmp->bmiHeader.biPlanes = 1; - bmp->bmiHeader.biBitCount = (unsigned short)bits_per_pixel; - bmp->bmiHeader.biCompression = 0; - bmp->bmiHeader.biSizeImage = img_size; - bmp->bmiHeader.biXPelsPerMeter = 0; - bmp->bmiHeader.biYPelsPerMeter = 0; - bmp->bmiHeader.biClrUsed = 0; - bmp->bmiHeader.biClrImportant = 0; - - void* img_ptr = 0; - HBITMAP h_bitmap = ::CreateDIBSection(h_dc, bmp, DIB_RGB_COLORS, &img_ptr, NULL, 0); - - if(img_ptr) - { - m_img_size = calc_row_len(width, bits_per_pixel) * height; - m_full_size = 0; - m_bmp = bmp; - m_buf = (unsigned char *) img_ptr; - } - - return h_bitmap; - } -} - - - diff --git a/desmume/src/windows/agg/src/readme b/desmume/src/windows/agg/src/readme deleted file mode 100644 index d565c28a6..000000000 --- a/desmume/src/windows/agg/src/readme +++ /dev/null @@ -1,5 +0,0 @@ -Use automake to build the library. - -If automake is not available you still can use the old make. -There is a very simple Makefile that can be used. Note that -if you use automake it will overwrite Makefile. diff --git a/desmume/src/windows/aviout.h b/desmume/src/windows/aviout.h deleted file mode 100644 index 4f6d8a2be..000000000 --- a/desmume/src/windows/aviout.h +++ /dev/null @@ -1,31 +0,0 @@ -/* aviout.h - - Copyright (C) 2006-2009 DeSmuME team - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -*/ - -#ifndef _AVIOUT_H_ -#define _AVIOUT_H_ - -bool DRV_AviBegin(const char* fname); -void DRV_AviEnd(); -void DRV_AviSoundUpdate(void* soundData, int soundLen); -bool AVI_IsRecording(); -void DRV_AviVideoUpdate(const u16* buffer); - -#endif diff --git a/desmume/src/windows/defaultconfig/SubWCRev.bat b/desmume/src/windows/defaultconfig/SubWCRev.bat deleted file mode 100644 index ac7fe7278..000000000 --- a/desmume/src/windows/defaultconfig/SubWCRev.bat +++ /dev/null @@ -1,2 +0,0 @@ -defaultconfig\SubWCRev.exe ..\..\.. ".\defaultconfig\svnrev_template.h" ".\userconfig\svnrev.h" -exit 0 \ No newline at end of file diff --git a/desmume/src/windows/defaultconfig/SubWCRev.exe b/desmume/src/windows/defaultconfig/SubWCRev.exe deleted file mode 100644 index 1c8c5f38110fd27e0633ab230a5a56581d6840b6..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 294400 zcmeFXdoQ~);>pBOd)1D+U$aFQ}{=^1HTGvc=6 zHpiu=rg3rcTW}e?R9sRj&NG;S+n$!N#adYzf&V{Dn>jG*QbL{k|EE0Dy40Wcm*0Xr z-yirN-t7y=huil3LMF0BY-}!I)i~lZ?|Ai=j^{g{8GdBM# z``2Ip`siN_`m6iD5Cs5e`(N1q|MCAD57<}}Yyf}bXsE0RSKL%9Blf8qovvtx1I)eu z#wQ&PFjWC0$&a4>!xYcTd1wd<37=Ad#FUG@;6gd>+(IWRN@5?Y*bNLB_6B@et(i;1 z$9-gpzjwoQrxrZ%a3EKKm76F37Lgbx?uzb!0GjMSc{xH~cG5ycJZWB1>o)fZnXwWI!^||GvD{0L~Xbjs7LviAQBX#BL}_1uW!- z0=&f$a16?lbIn}oRmbe&s#4ZhrV!%ayiLim5v>}aS8&2vWa_-RRNw*-18N-;CAQlJ~b+eNiV;f`!1Sq_MZ=>h_xdynPMLP(4!1s0H9XW2yy zS#2P3?r_b*9(a))eM_OJP3@A9k6Yx(m00V9xe#TZu`my!si%+)m+whmS5OV&^Ul{z;>at-KB&_1@YnO zsKAjW*nNvFdG}U|EFEon^W^p;PVJ|f0S>+#Zm3v`RAz~+3UUa-Q?Gs);rf}vxt?N5 zRs}#Re|yg<2LW7n|0|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|RW(rj_&t&>1iX*bLRvQF=OAPp9c=f}SqWQ*`G#jyJ|`!Z5nc%@3vN}HU9N3`*0=qL3S}JIkFs4 zVow)U0Q_yjW5f6Yr(mmyP{2py5UPq$Db%VsrCp2!K9R4zMjfCGcUD9Mxl0lgd$e1m Xsg2OWL$V1{gu7~-lp*Z+|6u+fI~M1C diff --git a/desmume/src/windows/defaultconfig/svnrev.h b/desmume/src/windows/defaultconfig/svnrev.h deleted file mode 100644 index e2669fba1..000000000 --- a/desmume/src/windows/defaultconfig/svnrev.h +++ /dev/null @@ -1,5 +0,0 @@ -//this should be overridden with one generated in userconfig -//but it is here just in case to prevent compiler errors - -#define SVN_REV 0 -#define SVN_REV_STR "0" \ No newline at end of file diff --git a/desmume/src/windows/defaultconfig/svnrev_template.h b/desmume/src/windows/defaultconfig/svnrev_template.h deleted file mode 100644 index d7a944d4b..000000000 --- a/desmume/src/windows/defaultconfig/svnrev_template.h +++ /dev/null @@ -1,2 +0,0 @@ -#define SVN_REV $WCREV$ -#define SVN_REV_STR "$WCREV$" \ No newline at end of file diff --git a/desmume/src/windows/filter/2xsai.cpp b/desmume/src/windows/filter/2xsai.cpp deleted file mode 100644 index 610e3efab..000000000 --- a/desmume/src/windows/filter/2xsai.cpp +++ /dev/null @@ -1,735 +0,0 @@ -#include "filter.h" -#include "types.h" - -static uint32 colorMask = 0x7BDE7BDE; -static uint32 lowPixelMask = 0x04210421; -static uint32 qcolorMask = 0x739C739C; -static uint32 qlowpixelMask = 0x0C630C63; - -static inline int GetResult1(uint32 A, uint32 B, uint32 C, uint32 D, uint32 E) -{ - int x = 0; - int y = 0; - int r = 0; - if (A == C) x+=1; else if (B == C) y+=1; - if (A == D) x+=1; else if (B == D) y+=1; - if (x <= 1) r+=1; - if (y <= 1) r-=1; - return r; -} - -static inline int GetResult2(uint32 A, uint32 B, uint32 C, uint32 D, uint32 E) -{ - int x = 0; - int y = 0; - int r = 0; - if (A == C) x+=1; else if (B == C) y+=1; - if (A == D) x+=1; else if (B == D) y+=1; - if (x <= 1) r-=1; - if (y <= 1) r+=1; - return r; -} - - -static inline int GetResult(uint32 A, uint32 B, uint32 C, uint32 D) -{ - int x = 0; - int y = 0; - int r = 0; - if (A == C) x+=1; else if (B == C) y+=1; - if (A == D) x+=1; else if (B == D) y+=1; - if (x <= 1) r+=1; - if (y <= 1) r-=1; - return r; -} - - -static inline uint32 INTERPOLATE(uint32 A, uint32 B) -{ - if (A !=B) - { - return ( ((A & colorMask) >> 1) + ((B & colorMask) >> 1) + (A & B & lowPixelMask) ); - } - else return A; -} - - -static inline uint32 Q_INTERPOLATE(uint32 A, uint32 B, uint32 C, uint32 D) -{ - register uint32 x = ((A & qcolorMask) >> 2) + - ((B & qcolorMask) >> 2) + - ((C & qcolorMask) >> 2) + - ((D & qcolorMask) >> 2); - register uint32 y = (A & qlowpixelMask) + - (B & qlowpixelMask) + - (C & qlowpixelMask) + - (D & qlowpixelMask); - y = (y>>2) & qlowpixelMask; - return x+y; -} - -#define HOR -#define VER -void Super2xSaI(uint8 *srcPtr, uint32 srcPitch, - uint8 *deltaPtr, - uint8 *dstPtr, uint32 dstPitch, int width, int height) -{ - uint32 *dP; - uint16 *bP; - -#ifdef MMX_BLA //no MMX version yet - if (cpu_mmx && width != 512) - { - for (height; height; height-=1) - { - bP = (uint16 *) srcPtr; - xP = (uint16 *) deltaPtr; - dP = (uint32 *) dstPtr; - _2xSaISuperEagleLine ((uint8 *) bP, (uint8 *) xP, srcPitch, width, (uint8 *) dP, dstPitch); - dstPtr += dstPitch << 1; - srcPtr += srcPitch; - deltaPtr += srcPitch; - } - } - else - { -#endif - uint32 Nextline = srcPitch >> 1; - - for (height; height; height-=1) - { - bP = (uint16 *) srcPtr; - dP = (uint32 *) dstPtr; - for (uint32 finish = width; finish; finish -= 1 ) - { - uint32 color4, color5, color6; - uint32 color1, color2, color3; - uint32 colorA0, colorA1, colorA2, colorA3, - colorB0, colorB1, colorB2, colorB3, - colorS1, colorS2; - uint32 product1a, product1b, - product2a, product2b; - -//--------------------------------------- B1 B2 -// 4 5 6 S2 -// 1 2 3 S1 -// A1 A2 - - colorB0 = *(bP- Nextline - 1); - colorB1 = *(bP- Nextline); - colorB2 = *(bP- Nextline + 1); - colorB3 = *(bP- Nextline + 2); - - color4 = *(bP - 1); - color5 = *(bP); - color6 = *(bP + 1); - colorS2 = *(bP + 2); - - color1 = *(bP + Nextline - 1); - color2 = *(bP + Nextline); - color3 = *(bP + Nextline + 1); - colorS1 = *(bP + Nextline + 2); - - colorA0 = *(bP + Nextline + Nextline - 1); - colorA1 = *(bP + Nextline + Nextline); - colorA2 = *(bP + Nextline + Nextline + 1); - colorA3 = *(bP + Nextline + Nextline + 2); - - -//-------------------------------------- - if (color2 == color6 && color5 != color3) - { - product2b = product1b = color2; - } - else - if (color5 == color3 && color2 != color6) - { - product2b = product1b = color5; - } - else - if (color5 == color3 && color2 == color6 && color5 != color6) - { - register int r = 0; - - r += GetResult (color6, color5, color1, colorA1); - r += GetResult (color6, color5, color4, colorB1); - r += GetResult (color6, color5, colorA2, colorS1); - r += GetResult (color6, color5, colorB2, colorS2); - - if (r > 0) - product2b = product1b = color6; - else - if (r < 0) - product2b = product1b = color5; - else - { - product2b = product1b = INTERPOLATE (color5, color6); - } - - } - else - { - -#ifdef VER - if (color6 == color3 && color3 == colorA1 && color2 != colorA2 && color3 != colorA0) - product2b = Q_INTERPOLATE (color3, color3, color3, color2); - else - if (color5 == color2 && color2 == colorA2 && colorA1 != color3 && color2 != colorA3) - product2b = Q_INTERPOLATE (color2, color2, color2, color3); - else -#endif - product2b = INTERPOLATE (color2, color3); - -#ifdef VER - if (color6 == color3 && color6 == colorB1 && color5 != colorB2 && color6 != colorB0) - product1b = Q_INTERPOLATE (color6, color6, color6, color5); - else - if (color5 == color2 && color5 == colorB2 && colorB1 != color6 && color5 != colorB3) - product1b = Q_INTERPOLATE (color6, color5, color5, color5); - else -#endif - product1b = INTERPOLATE (color5, color6); - } - -#ifdef HOR - if (color5 == color3 && color2 != color6 && color4 == color5 && color5 != colorA2) - product2a = INTERPOLATE (color2, color5); - else - if (color5 == color1 && color6 == color5 && color4 != color2 && color5 != colorA0) - product2a = INTERPOLATE(color2, color5); - else -#endif - product2a = color2; - -#ifdef HOR - if (color2 == color6 && color5 != color3 && color1 == color2 && color2 != colorB2) - product1a = INTERPOLATE (color2, color5); - else - if (color4 == color2 && color3 == color2 && color1 != color5 && color2 != colorB0) - product1a = INTERPOLATE(color2, color5); - else -#endif - product1a = color5; - - - product1a = product1a | (product1b << 16); - product2a = product2a | (product2b << 16); - - *(dP) = product1a; - *(dP+(dstPitch>>2)) = product2a; - - bP += 1; - dP += 1; - }//end of for ( finish= width etc..) - - dstPtr += dstPitch << 1; - srcPtr += srcPitch; - deltaPtr += srcPitch; - }; //endof: for (height; height; height--) -#ifdef MMX_BLA - } -#endif -} - -/*ONLY use with 640x480x16 or higher resolutions*/ -/*Only use this if 2*width * 2*height fits on the current screen*/ -void SuperEagle(uint8 *srcPtr, uint32 srcPitch, - uint8 *deltaPtr, - uint8 *dstPtr, uint32 dstPitch, int width, int height) -{ - uint32 *dP; - uint16 *bP; - uint16 *xP; - -#ifdef MMX - if (mmx_cpu && width != 512) - { - for (height; height; height-=1) - { - bP = (uint16 *) srcPtr; - xP = (uint16 *) deltaPtr; - dP = (uint32 *) dstPtr; - _2xSaISuperEagleLine ((uint8 *) bP, (uint8 *) xP, srcPitch, width, (uint8 *)dP, dstPitch); - dstPtr += dstPitch << 1; - srcPtr += srcPitch; - deltaPtr += srcPitch; - } - } - else - { -#endif - uint32 Nextline = srcPitch >> 1; - - for (height; height; height-=1) - { - bP = (uint16 *) srcPtr; - dP = (uint32 *) dstPtr; - for (uint32 finish = width; finish; finish -= 1 ) - { - - uint32 color4, color5, color6; - uint32 color1, color2, color3; - uint32 colorA0, colorA1, colorA2, colorA3, - colorB0, colorB1, colorB2, colorB3, - colorS1, colorS2; - uint32 product1a, product1b, - product2a, product2b; - - colorB0 = *(bP- Nextline - 1); - colorB1 = *(bP- Nextline); - colorB2 = *(bP- Nextline + 1); - colorB3 = *(bP- Nextline + 2); - - color4 = *(bP - 1); - color5 = *(bP); - color6 = *(bP + 1); - colorS2 = *(bP + 2); - - color1 = *(bP + Nextline - 1); - color2 = *(bP + Nextline); - color3 = *(bP + Nextline + 1); - colorS1 = *(bP + Nextline + 2); - - colorA0 = *(bP + Nextline + Nextline - 1); - colorA1 = *(bP + Nextline + Nextline); - colorA2 = *(bP + Nextline + Nextline + 1); - colorA3 = *(bP + Nextline + Nextline + 2); - - - //-------------------------------------- - if (color2 == color6 && color5 != color3) - { - product1b = product2a = color2; - if ((color1 == color2 && color6 == colorS2) || - (color2 == colorA1 && color6 == colorB2)) - { - product1a = INTERPOLATE (color2, color5); - product1a = INTERPOLATE (color2, product1a); - product2b = INTERPOLATE (color2, color3); - product2b = INTERPOLATE (color2, product2b); -// product1a = color2; -// product2b = color2; - } - else - { - product1a = INTERPOLATE (color5, color6); - product2b = INTERPOLATE (color2, color3); - } - } - else - if (color5 == color3 && color2 != color6) - { - product2b = product1a = color5; - if ((colorB1 == color5 && color3 == colorA2) || - (color4 == color5 && color3 == colorS1)) - { - product1b = INTERPOLATE (color5, color6); - product1b = INTERPOLATE (color5, product1b); - product2a = INTERPOLATE (color5, color2); - product2a = INTERPOLATE (color5, product2a); -// product1b = color5; -// product2a = color5; - } - else - { - product1b = INTERPOLATE (color5, color6); - product2a = INTERPOLATE (color2, color3); - } - } - else - if (color5 == color3 && color2 == color6 && color5 != color6) - { - register int r = 0; - - r += GetResult (color6, color5, color1, colorA1); - r += GetResult (color6, color5, color4, colorB1); - r += GetResult (color6, color5, colorA2, colorS1); - r += GetResult (color6, color5, colorB2, colorS2); - - if (r > 0) - { - product1b = product2a = color2; - product1a = product2b = INTERPOLATE (color5, color6); - } - else - if (r < 0) - { - product2b = product1a = color5; - product1b = product2a = INTERPOLATE (color5, color6); - } - else - { - product2b = product1a = color5; - product1b = product2a = color2; - } - } - else - { - - if ((color2 == color5) || (color3 == color6)) - { - product1a = color5; - product2a = color2; - product1b = color6; - product2b = color3; - - } - else - { - product1b = product1a = INTERPOLATE (color5, color6); - product1a = INTERPOLATE (color5, product1a); - product1b = INTERPOLATE (color6, product1b); - - product2a = product2b = INTERPOLATE (color2, color3); - product2a = INTERPOLATE (color2, product2a); - product2b = INTERPOLATE (color3, product2b); - } - } - - - product1a = product1a | (product1b << 16); - product2a = product2a | (product2b << 16); - - *(dP) = product1a; - *(dP+(dstPitch>>2)) = product2a; - - bP += 1; - dP += 1; - }//end of for ( finish= width etc..) - - dstPtr += dstPitch << 1; - srcPtr += srcPitch; - deltaPtr += srcPitch; - }; //endof: for (height; height; height--) -#ifdef MMX - } -#endif -} - -/*ONLY use with 640x480x16 or higher resolutions*/ -/*Only use this if 2*width * 2*height fits on the current screen*/ -void _2xSaI(uint8 *srcPtr, uint32 srcPitch, - uint8 *deltaPtr, - uint8 *dstPtr, uint32 dstPitch, int width, int height) -{ - uint32 *dP; - uint16 *bP; - uint16 *xP; - -#ifdef MMX - if (mmx_cpu && width != 512) - { - for (height; height; height-=1) - { - - bP = (uint16 *) srcPtr; - xP = (uint16 *) deltaPtr; - dP = (uint32 *) dstPtr; - _2xSaILine ((uint8 *) bP, (uint8 *) xP, srcPitch, width, (uint8 *)dP, dstPitch); - dstPtr += dstPitch << 1; - srcPtr += srcPitch; - deltaPtr += srcPitch; - } - } - else - { -#endif - uint32 Nextline = srcPitch >> 1; - - for (height; height; height-=1) - { - bP = (uint16 *) srcPtr; - dP = (uint32 *) dstPtr; - for (uint32 finish = width; finish; finish -= 1 ) - { - - - register uint32 colorA, colorB; - uint32 colorC, colorD, - colorE, colorF, colorG, colorH, - colorI, colorJ, colorK, colorL, - colorM, colorN, colorO, colorP; - uint32 product, product1, product2; - - -//--------------------------------------- -// Map of the pixels: I|E F|J -// G|A B|K -// H|C D|L -// M|N O|P - colorI = *(bP- Nextline - 1); - colorE = *(bP- Nextline); - colorF = *(bP- Nextline + 1); - colorJ = *(bP- Nextline + 2); - - colorG = *(bP - 1); - colorA = *(bP); - colorB = *(bP + 1); - colorK = *(bP + 2); - - colorH = *(bP + Nextline - 1); - colorC = *(bP + Nextline); - colorD = *(bP + Nextline + 1); - colorL = *(bP + Nextline + 2); - - colorM = *(bP + Nextline + Nextline - 1); - colorN = *(bP + Nextline + Nextline); - colorO = *(bP + Nextline + Nextline + 1); - colorP = *(bP + Nextline + Nextline + 2); - - if ((colorA == colorD) && (colorB != colorC)) - { - if ( ((colorA == colorE) && (colorB == colorL)) || - ((colorA == colorC) && (colorA == colorF) && (colorB != colorE) && (colorB == colorJ)) ) - { - product = colorA; - } - else - { - product = INTERPOLATE(colorA, colorB); - } - - if (((colorA == colorG) && (colorC == colorO)) || - ((colorA == colorB) && (colorA == colorH) && (colorG != colorC) && (colorC == colorM)) ) - { - product1 = colorA; - } - else - { - product1 = INTERPOLATE(colorA, colorC); - } - product2 = colorA; - } - else - if ((colorB == colorC) && (colorA != colorD)) - { - if (((colorB == colorF) && (colorA == colorH)) || - ((colorB == colorE) && (colorB == colorD) && (colorA != colorF) && (colorA == colorI)) ) - { - product = colorB; - } - else - { - product = INTERPOLATE(colorA, colorB); - } - - if (((colorC == colorH) && (colorA == colorF)) || - ((colorC == colorG) && (colorC == colorD) && (colorA != colorH) && (colorA == colorI)) ) - { - product1 = colorC; - } - else - { - product1 = INTERPOLATE(colorA, colorC); - } - product2 = colorB; - } - else - if ((colorA == colorD) && (colorB == colorC)) - { - if (colorA == colorB) - { - product = colorA; - product1 = colorA; - product2 = colorA; - } - else - { - register int r = 0; - product1 = INTERPOLATE(colorA, colorC); - product = INTERPOLATE(colorA, colorB); - - r += GetResult1 (colorA, colorB, colorG, colorE, colorI); - r += GetResult2 (colorB, colorA, colorK, colorF, colorJ); - r += GetResult2 (colorB, colorA, colorH, colorN, colorM); - r += GetResult1 (colorA, colorB, colorL, colorO, colorP); - - if (r > 0) - product2 = colorA; - else - if (r < 0) - product2 = colorB; - else - { - product2 = Q_INTERPOLATE(colorA, colorB, colorC, colorD); - } - } - } - else - { - product2 = Q_INTERPOLATE(colorA, colorB, colorC, colorD); - - if ((colorA == colorC) && (colorA == colorF) && (colorB != colorE) && (colorB == colorJ)) - { - product = colorA; - } - else - if ((colorB == colorE) && (colorB == colorD) && (colorA != colorF) && (colorA == colorI)) - { - product = colorB; - } - else - { - product = INTERPOLATE(colorA, colorB); - } - - if ((colorA == colorB) && (colorA == colorH) && (colorG != colorC) && (colorC == colorM)) - { - product1 = colorA; - } - else - if ((colorC == colorG) && (colorC == colorD) && (colorA != colorH) && (colorA == colorI)) - { - product1 = colorC; - } - else - { - product1 = INTERPOLATE(colorA, colorC); - } - } - product = colorA | (product << 16); - product1 = product1 | (product2 << 16); - *(dP) = product; - *(dP+(dstPitch>>2)) = product1; - - bP += 1; - dP += 1; - }//end of for ( finish= width etc..) - - dstPtr += dstPitch << 1; - srcPtr += srcPitch; - deltaPtr += srcPitch; - }; //endof: for (height; height; height--) -#ifdef MMX - } -#endif -} - -void Render2xSaI (SSurface Src, SSurface Dst) -{ - unsigned char *lpSrc, *lpDst; - - lpSrc = Src.Surface; - lpDst = Dst.Surface; - - _2xSaI (lpSrc, Src.Pitch, lpSrc, - lpDst, Dst.Pitch, Src.Width, Src.Height); - -} - -void RenderSuper2xSaI (SSurface Src, SSurface Dst) -{ - - unsigned char *lpSrc, *lpDst; - - lpSrc = Src.Surface; - lpDst = Dst.Surface; - - Super2xSaI (lpSrc, Src.Pitch, - lpSrc, - lpDst, Dst.Pitch, Src.Width, Src.Height); - -} - -void RenderSuperEagle (SSurface Src, SSurface Dst) -{ - - unsigned char *lpSrc, *lpDst; - - lpSrc = Src.Surface; - lpDst = Dst.Surface; - - SuperEagle (lpSrc, Src.Pitch, - lpSrc, - lpDst, Dst.Pitch, Src.Width, Src.Height); - -} - -/******************************************************************************* - Snes9x - Portable Super Nintendo Entertainment System (TM) emulator. - - (c) Copyright 1996 - 2002 Gary Henderson (gary.henderson@ntlworld.com) and - Jerremy Koot (jkoot@snes9x.com) - - (c) Copyright 2001 - 2004 John Weidman (jweidman@slip.net) - - (c) Copyright 2002 - 2004 Brad Jorsch (anomie@users.sourceforge.net), - funkyass (funkyass@spam.shaw.ca), - Joel Yliluoma (http://iki.fi/bisqwit/) - Kris Bleakley (codeviolation@hotmail.com), - Matthew Kendora, - Nach (n-a-c-h@users.sourceforge.net), - Peter Bortas (peter@bortas.org) and - zones (kasumitokoduck@yahoo.com) - - C4 x86 assembler and some C emulation code - (c) Copyright 2000 - 2003 zsKnight (zsknight@zsnes.com), - _Demo_ (_demo_@zsnes.com), and Nach - - C4 C++ code - (c) Copyright 2003 Brad Jorsch - - DSP-1 emulator code - (c) Copyright 1998 - 2004 Ivar (ivar@snes9x.com), _Demo_, Gary Henderson, - John Weidman, neviksti (neviksti@hotmail.com), - Kris Bleakley, Andreas Naive - - DSP-2 emulator code - (c) Copyright 2003 Kris Bleakley, John Weidman, neviksti, Matthew Kendora, and - Lord Nightmare (lord_nightmare@users.sourceforge.net - - OBC1 emulator code - (c) Copyright 2001 - 2004 zsKnight, pagefault (pagefault@zsnes.com) and - Kris Bleakley - Ported from x86 assembler to C by sanmaiwashi - - SPC7110 and RTC C++ emulator code - (c) Copyright 2002 Matthew Kendora with research by - zsKnight, John Weidman, and Dark Force - - S-DD1 C emulator code - (c) Copyright 2003 Brad Jorsch with research by - Andreas Naive and John Weidman - - S-RTC C emulator code - (c) Copyright 2001 John Weidman - - ST010 C++ emulator code - (c) Copyright 2003 Feather, Kris Bleakley, John Weidman and Matthew Kendora - - Super FX x86 assembler emulator code - (c) Copyright 1998 - 2003 zsKnight, _Demo_, and pagefault - - Super FX C emulator code - (c) Copyright 1997 - 1999 Ivar, Gary Henderson and John Weidman - - - SH assembler code partly based on x86 assembler code - (c) Copyright 2002 - 2004 Marcus Comstedt (marcus@mc.pp.se) - - - Specific ports contains the works of other authors. See headers in - individual files. - - Snes9x homepage: http://www.snes9x.com - - Permission to use, copy, modify and distribute Snes9x in both binary and - source form, for non-commercial purposes, is hereby granted without fee, - providing that this license information and copyright notice appear with - all copies and any derived work. - - This software is provided 'as-is', without any express or implied - warranty. In no event shall the authors be held liable for any damages - arising from the use of this software. - - Snes9x is freeware for PERSONAL USE only. Commercial users should - seek permission of the copyright holders first. Commercial use includes - charging money for Snes9x or software derived from Snes9x. - - The copyright holders request that bug fixes and improvements to the code - should be forwarded to them so everyone can benefit from the modifications - in future versions. - - Super NES and Super Nintendo Entertainment System are trademarks of - Nintendo Co., Limited and its subsidiary companies. -*******************************************************************************/ \ No newline at end of file diff --git a/desmume/src/windows/filter/bilinear.cpp b/desmume/src/windows/filter/bilinear.cpp deleted file mode 100644 index fc477f7c7..000000000 --- a/desmume/src/windows/filter/bilinear.cpp +++ /dev/null @@ -1,236 +0,0 @@ -/** Code adapted from Exult source code by Forgotten - ** Scale.cc - Trying to scale with bilinear interpolation. - ** - ** Written: 6/14/00 - JSF - **/ - -#include "types.h" - -int systemRedShift = 10; -int systemGreenShift = 0; -int systemBlueShift = 5; - -#define RGB1(r,g,b) ((r)>>3) << systemRedShift |\ - ((g) >> 3) << systemGreenShift |\ - ((b) >> 3) << systemBlueShift\ - -static void fill_rgb_row_16(u16 *from, int src_width, u8 *row, int width) -{ - u8 *copy_start = row + src_width*3; - u8 *all_stop = row + width*3; - while (row < copy_start) { - u16 color = *from++; - *row++ = ((color >> systemRedShift) & 0x1f) << 3; - *row++ = ((color >> systemGreenShift) & 0x1f) << 3; - *row++ = ((color >> systemBlueShift) & 0x1f) << 3; - } - // any remaining elements to be written to 'row' are a replica of the - // preceding pixel - u8 *p = row-3; - while (row < all_stop) { - // we're guaranteed three elements per pixel; could unroll the loop - // further, especially with a Duff's Device, but the gains would be - // probably limited (judging by profiler output) - *row++ = *p++; - *row++ = *p++; - *row++ = *p++; - } -} - -void Bilinear(u8 *srcPtr, u32 srcPitch, u8 * /* deltaPtr */, - u8 *dstPtr, u32 dstPitch, int width, int height) -{ - u8 row_cur[3*322]; - u8 row_next[3*322]; - u8 *rgb_row_cur = row_cur; - u8 *rgb_row_next = row_next; - - u16 *to = (u16 *)dstPtr; - u16 *to_odd = (u16 *)(dstPtr + dstPitch); - - int from_width = width; - u16 *from = (u16 *)srcPtr; - fill_rgb_row_16(from, from_width, rgb_row_cur, width+1); - - for(int y = 0; y < height; y++) { - u16 *from_orig = from; - u16 *to_orig = to; - - if (y+1 < height) - fill_rgb_row_16(from+width, from_width, rgb_row_next, - width+1); - else - fill_rgb_row_16(from, from_width, rgb_row_next, width+1); - - // every pixel in the src region, is extended to 4 pixels in the - // destination, arranged in a square 'quad'; if the current src - // pixel is 'a', then in what follows 'b' is the src pixel to the - // right, 'c' is the src pixel below, and 'd' is the src pixel to - // the right and down - u8 *cur_row = rgb_row_cur; - u8 *next_row = rgb_row_next; - u8 *ar = cur_row++; - u8 *ag = cur_row++; - u8 *ab = cur_row++; - u8 *cr = next_row++; - u8 *cg = next_row++; - u8 *cb = next_row++; - for(int x=0; x < width; x++) { - u8 *br = cur_row++; - u8 *bg = cur_row++; - u8 *bb = cur_row++; - u8 *dr = next_row++; - u8 *dg = next_row++; - u8 *db = next_row++; - - // upper left pixel in quad: just copy it in - *to++ = RGB1(*ar, *ag, *ab); - - // upper right - *to++ = RGB1((*ar+*br)>>1, (*ag+*bg)>>1, (*ab+*bb)>>1); - - // lower left - *to_odd++ = RGB1((*ar+*cr)>>1, (*ag+*cg)>>1, (*ab+*cb)>>1); - - // lower right - *to_odd++ = RGB1((*ar+*br+*cr+*dr)>>2, - (*ag+*bg+*cg+*dg)>>2, - (*ab+*bb+*cb+*db)>>2); - - // 'b' becomes 'a', 'd' becomes 'c' - ar = br; - ag = bg; - ab = bb; - cr = dr; - cg = dg; - cb = db; - } - - // the "next" rgb row becomes the current; the old current rgb row is - // recycled and serves as the new "next" row - u8 *temp; - temp = rgb_row_cur; - rgb_row_cur = rgb_row_next; - rgb_row_next = temp; - - // update the pointers for start of next pair of lines - from = (u16 *)((u8 *)from_orig + srcPitch); - to = (u16 *)((u8 *)to_orig + (dstPitch << 1)); - to_odd = (u16 *)((u8 *)to + dstPitch); - } -} - -struct SSurface { - unsigned char *Surface; - - unsigned int Pitch; - unsigned int Width, Height; -}; - -void BilinearPlus(u8 *srcPtr, u32 srcPitch, u8 * /* deltaPtr */, - u8 *dstPtr, u32 dstPitch, int width, int height) -{ - u8 row_cur[3*322]; - u8 row_next[3*322]; - u8 *rgb_row_cur = row_cur; - u8 *rgb_row_next = row_next; - - u16 *to = (u16 *)dstPtr; - u16 *to_odd = (u16 *)(dstPtr + dstPitch); - - int from_width = width; - u16 *from = (u16 *)srcPtr; - fill_rgb_row_16(from, from_width, rgb_row_cur, width+1); - - for(int y = 0; y < height; y++) { - u16 *from_orig = from; - u16 *to_orig = to; - - if (y+1 < height) - fill_rgb_row_16(from+width, from_width, rgb_row_next, - width+1); - else - fill_rgb_row_16(from, from_width, rgb_row_next, width+1); - - // every pixel in the src region, is extended to 4 pixels in the - // destination, arranged in a square 'quad'; if the current src - // pixel is 'a', then in what follows 'b' is the src pixel to the - // right, 'c' is the src pixel below, and 'd' is the src pixel to - // the right and down - u8 *cur_row = rgb_row_cur; - u8 *next_row = rgb_row_next; - u8 *ar = cur_row++; - u8 *ag = cur_row++; - u8 *ab = cur_row++; - u8 *cr = next_row++; - u8 *cg = next_row++; - u8 *cb = next_row++; - for(int x=0; x < width; x++) { - u8 *br = cur_row++; - u8 *bg = cur_row++; - u8 *bb = cur_row++; - u8 *dr = next_row++; - u8 *dg = next_row++; - u8 *db = next_row++; - - // upper left pixel in quad: just copy it in - //*to++ = manip.rgb(*ar, *ag, *ab); -#ifdef USE_ORIGINAL_BILINEAR_PLUS - *to++ = RGB( - (((*ar)<<2) +((*ar)) + (*cr+*br+*br) )>> 3, - (((*ag)<<2) +((*ag)) + (*cg+*bg+*bg) )>> 3, - (((*ab)<<2) +((*ab)) + (*cb+*bb+*bb) )>> 3); -#else - *to++ = RGB1( - (((*ar)<<3) +((*ar)<<1) + (*cr+*br+*br+*cr) )>> 4, - (((*ag)<<3) +((*ag)<<1) + (*cg+*bg+*bg+*cg) )>> 4, - (((*ab)<<3) +((*ab)<<1) + (*cb+*bb+*bb+*cb) )>> 4); -#endif - - // upper right - *to++ = RGB1((*ar+*br)>>1, (*ag+*bg)>>1, (*ab+*bb)>>1); - - // lower left - *to_odd++ = RGB1((*ar+*cr)>>1, (*ag+*cg)>>1, (*ab+*cb)>>1); - - // lower right - *to_odd++ = RGB1((*ar+*br+*cr+*dr)>>2, - (*ag+*bg+*cg+*dg)>>2, - (*ab+*bb+*cb+*db)>>2); - - // 'b' becomes 'a', 'd' becomes 'c' - ar = br; - ag = bg; - ab = bb; - cr = dr; - cg = dg; - cb = db; - } - - // the "next" rgb row becomes the current; the old current rgb row is - // recycled and serves as the new "next" row - u8 *temp; - temp = rgb_row_cur; - rgb_row_cur = rgb_row_next; - rgb_row_next = temp; - - // update the pointers for start of next pair of lines - from = (u16 *)((u8 *)from_orig + srcPitch); - to = (u16 *)((u8 *)to_orig + (dstPitch << 1)); - to_odd = (u16 *)((u8 *)to + dstPitch); - } -} - -void RenderBilinear (SSurface Src, SSurface Dst) -{ - - unsigned char *lpSrc, *lpDst; - - lpSrc = Src.Surface; - lpDst = Dst.Surface; - - Bilinear (lpSrc, Src.Pitch, - lpSrc, - lpDst, Dst.Pitch, Src.Width, Src.Height); - -} \ No newline at end of file diff --git a/desmume/src/windows/filter/filter.h b/desmume/src/windows/filter/filter.h deleted file mode 100644 index 3dbc99d9a..000000000 --- a/desmume/src/windows/filter/filter.h +++ /dev/null @@ -1,13 +0,0 @@ -struct SSurface { - unsigned char *Surface; - - unsigned int Pitch; - unsigned int Width, Height; -}; - -void RenderHQ2X (SSurface Src, SSurface Dst); -void Render2xSaI (SSurface Src, SSurface Dst); -void RenderSuper2xSaI (SSurface Src, SSurface Dst); -void RenderSuperEagle (SSurface Src, SSurface Dst); -void RenderScanline( SSurface Src, SSurface Dst); -void RenderBilinear( SSurface Src, SSurface Dst); \ No newline at end of file diff --git a/desmume/src/windows/filter/hq2x.cpp b/desmume/src/windows/filter/hq2x.cpp deleted file mode 100644 index 97fab5f24..000000000 --- a/desmume/src/windows/filter/hq2x.cpp +++ /dev/null @@ -1,462 +0,0 @@ -//hq2x filter demo program -//---------------------------------------------------------- -//Copyright (C) 2003 MaxSt ( maxst@hiend3d.com ) - -//This program is free software; you can redistribute it and/or -//modify it under the terms of the GNU Lesser General Public -//License as published by the Free Software Foundation; either -//version 2.1 of the License, or (at your option) any later version. -// -//This program is distributed in the hope that it will be useful, -//but WITHOUT ANY WARRANTY; without even the implied warranty of -//MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -//Lesser General Public License for more details. -// -//You should have received a copy of the GNU Lesser General Public -//License along with this program; if not, write to the Free Software -//Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - - -#include -#include -#include -#include -#include -#include "types.h" -#include "filter.h" - -#define Mask_2 0x03E0 // 00000 11111 00000 -#define Mask13 0x7C1F // 11111 00000 11111 -#define Mask_1 0x001F // 00000 00000 11111 -#define Mask_3 0x7C00 // 11111 00000 00000 -#define CONVERT_16_TO_32(pixel) \ - (((((pixel) >> 10) ) << /*RedShift+3*/ 19) | \ - ((((pixel) >> 5) & 0x1f) << /*GreenShift+3*/11) | \ - (((pixel) & 0x1f) << /*BlueShift+3*/ 3)) -#define NUMBITS (15) - -static int RGBtoYUV[1<> 1) & Mask_2) + \ - (((((c1) & Mask13) + ((c2) & Mask13)) >> 1) & Mask13))) -#define Interp01(c1, c2) \ - ((((c1) == (c2)) ? (c1) : \ - (((((((c1) & Mask_2) * 3) + ((c2) & Mask_2)) >> 2) & Mask_2) + \ - ((((((c1) & Mask13) * 3) + ((c2) & Mask13)) >> 2) & Mask13)))) - - -#define Ymask 0xFF0000 -#define Umask 0x00FF00 -#define Vmask 0x0000FF -#define trY 0x300000 -#define trU 0x000700 -#define trV 0x000006 - - -#define Interp02(c1, c2, c3) \ - ((((((c1) & Mask_2) * 2 + ((c2) & Mask_2) + ((c3) & Mask_2) ) >> 2) & Mask_2) + \ - (((((c1) & Mask13) * 2 + ((c2) & Mask13) + ((c3) & Mask13) ) >> 2) & Mask13)) - -#define Interp06(c1, c2, c3) \ - ((((((c1) & Mask_2) * 5 + ((c2) & Mask_2) * 2 + ((c3) & Mask_2) ) >> 3) & Mask_2) + \ - (((((c1) & Mask13) * 5 + ((c2) & Mask13) * 2 + ((c3) & Mask13) ) >> 3) & Mask13)) - -#define Interp07(c1, c2, c3) \ - ((((((c1) & Mask_2) * 6 + ((c2) & Mask_2) + ((c3) & Mask_2) ) >> 3) & Mask_2) + \ - (((((c1) & Mask13) * 6 + ((c2) & Mask13) + ((c3) & Mask13) ) >> 3) & Mask13)) - -#define Interp09(c1, c2, c3) \ - ((((((c1) & Mask_2) * 2 + ((c2) & Mask_2) * 3 + ((c3) & Mask_2) * 3) >> 3) & Mask_2) + \ - (((((c1) & Mask13) * 2 + ((c2) & Mask13) * 3 + ((c3) & Mask13) * 3) >> 3) & Mask13)) - -#define Interp10(c1, c2, c3) \ - ((((((c1) & Mask_2) * 14 + ((c2) & Mask_2) + ((c3) & Mask_2) ) >> 4) & Mask_2) + \ - (((((c1) & Mask13) * 14 + ((c2) & Mask13) + ((c3) & Mask13) ) >> 4) & Mask13)) - -#define PIXEL00_0 *(dp) = w5 -#define PIXEL00_10 *(dp) = Interp01(w5, w1) -#define PIXEL00_11 *(dp) = Interp01(w5, w4) -#define PIXEL00_12 *(dp) = Interp01(w5, w2) -#define PIXEL00_20 *(dp) = Interp02(w5, w4, w2) -#define PIXEL00_21 *(dp) = Interp02(w5, w1, w2) -#define PIXEL00_22 *(dp) = Interp02(w5, w1, w4) -#define PIXEL00_60 *(dp) = Interp06(w5, w2, w4) -#define PIXEL00_61 *(dp) = Interp06(w5, w4, w2) -#define PIXEL00_70 *(dp) = Interp07(w5, w4, w2) -#define PIXEL00_90 *(dp) = Interp09(w5, w4, w2) -#define PIXEL00_100 *(dp) = Interp10(w5, w4, w2) - -#define PIXEL01_0 *(dp + 1) = w5 -#define PIXEL01_10 *(dp + 1) = Interp01(w5, w3) -#define PIXEL01_11 *(dp + 1) = Interp01(w5, w2) -#define PIXEL01_12 *(dp + 1) = Interp01(w5, w6) -#define PIXEL01_20 *(dp + 1) = Interp02(w5, w2, w6) -#define PIXEL01_21 *(dp + 1) = Interp02(w5, w3, w6) -#define PIXEL01_22 *(dp + 1) = Interp02(w5, w3, w2) -#define PIXEL01_60 *(dp + 1) = Interp06(w5, w6, w2) -#define PIXEL01_61 *(dp + 1) = Interp06(w5, w2, w6) -#define PIXEL01_70 *(dp + 1) = Interp07(w5, w2, w6) -#define PIXEL01_90 *(dp + 1) = Interp09(w5, w2, w6) -#define PIXEL01_100 *(dp + 1) = Interp10(w5, w2, w6) - -#define PIXEL10_0 *(dp + dst1line) = w5 -#define PIXEL10_10 *(dp + dst1line) = Interp01(w5, w7) -#define PIXEL10_11 *(dp + dst1line) = Interp01(w5, w8) -#define PIXEL10_12 *(dp + dst1line) = Interp01(w5, w4) -#define PIXEL10_20 *(dp + dst1line) = Interp02(w5, w8, w4) -#define PIXEL10_21 *(dp + dst1line) = Interp02(w5, w7, w4) -#define PIXEL10_22 *(dp + dst1line) = Interp02(w5, w7, w8) -#define PIXEL10_60 *(dp + dst1line) = Interp06(w5, w4, w8) -#define PIXEL10_61 *(dp + dst1line) = Interp06(w5, w8, w4) -#define PIXEL10_70 *(dp + dst1line) = Interp07(w5, w8, w4) -#define PIXEL10_90 *(dp + dst1line) = Interp09(w5, w8, w4) -#define PIXEL10_100 *(dp + dst1line) = Interp10(w5, w8, w4) - -#define PIXEL11_0 *(dp + dst1line + 1) = w5 -#define PIXEL11_10 *(dp + dst1line + 1) = Interp01(w5, w9) -#define PIXEL11_11 *(dp + dst1line + 1) = Interp01(w5, w6) -#define PIXEL11_12 *(dp + dst1line + 1) = Interp01(w5, w8) -#define PIXEL11_20 *(dp + dst1line + 1) = Interp02(w5, w6, w8) -#define PIXEL11_21 *(dp + dst1line + 1) = Interp02(w5, w9, w8) -#define PIXEL11_22 *(dp + dst1line + 1) = Interp02(w5, w9, w6) -#define PIXEL11_60 *(dp + dst1line + 1) = Interp06(w5, w8, w6) -#define PIXEL11_61 *(dp + dst1line + 1) = Interp06(w5, w6, w8) -#define PIXEL11_70 *(dp + dst1line + 1) = Interp07(w5, w6, w8) -#define PIXEL11_90 *(dp + dst1line + 1) = Interp09(w5, w6, w8) -#define PIXEL11_100 *(dp + dst1line + 1) = Interp10(w5, w6, w8) - -#define Absolute(c) \ -(!((c) & (1 << 31)) ? (c) : (~(c) + 1)) - - -static inline bool Diff(int c1, int c2) -{ - int c1y = (c1 & Ymask) - (c2 & Ymask); - if (Absolute(c1y) > trY) return true; - int c1u = (c1 & Umask) - (c2 & Umask); - if (Absolute(c1u) > trU) return true; - int c1v = (c1 & Vmask) - (c2 & Vmask); - if (Absolute(c1v) > trV) return true; - - return false; -} - -void InitLUTs(void) -{ - int c, r, g, b, y, u, v; - - for (c = 0 ; c < (1<> 3; - r = (int)((c & 0xF800)) >> 8; -#else - b = (int)((c & 0x1F)) << 3; - g = (int)((c & 0x3E0)) >> 2; - r = (int)((c & 0x7C00)) >> 7; -#endif - RGBtoBright[c] = r+r+r + g+g+g + b+b; - - y = (int)( 0.256788f*r + 0.504129f*g + 0.097906f*b + 0.5f) + 16; - u = (int)(-0.148223f*r - 0.290993f*g + 0.439216f*b + 0.5f) + 128; - v = (int)( 0.439216f*r - 0.367788f*g - 0.071427f*b + 0.5f) + 128; - - RGBtoYUV[c] = (y << 16) + (u << 8) + v; - -// y = (r + g + b) >> 2; -// u = 128 + ((r - b) >> 2); -// v = 128 + ((-r + 2 * g - b) >> 3); -// -// RGBtoYUVLQ[c] = (y << 16) + (u << 8) + v; - } -} - -#define HQ2XCASES \ - case 0: case 1: case 4: case 32: case 128: case 5: case 132: case 160: case 33: case 129: case 36: case 133: case 164: case 161: case 37: case 165: PIXEL00_20; PIXEL01_20; PIXEL10_20; PIXEL11_20; break; \ - case 2: case 34: case 130: case 162: PIXEL00_22; PIXEL01_21; PIXEL10_20; PIXEL11_20; break; \ - case 16: case 17: case 48: case 49: PIXEL00_20; PIXEL01_22; PIXEL10_20; PIXEL11_21; break; \ - case 64: case 65: case 68: case 69: PIXEL00_20; PIXEL01_20; PIXEL10_21; PIXEL11_22; break; \ - case 8: case 12: case 136: case 140: PIXEL00_21; PIXEL01_20; PIXEL10_22; PIXEL11_20; break; \ - case 3: case 35: case 131: case 163: PIXEL00_11; PIXEL01_21; PIXEL10_20; PIXEL11_20; break; \ - case 6: case 38: case 134: case 166: PIXEL00_22; PIXEL01_12; PIXEL10_20; PIXEL11_20; break; \ - case 20: case 21: case 52: case 53: PIXEL00_20; PIXEL01_11; PIXEL10_20; PIXEL11_21; break; \ - case 144: case 145: case 176: case 177: PIXEL00_20; PIXEL01_22; PIXEL10_20; PIXEL11_12; break; \ - case 192: case 193: case 196: case 197: PIXEL00_20; PIXEL01_20; PIXEL10_21; PIXEL11_11; break; \ - case 96: case 97: case 100: case 101: PIXEL00_20; PIXEL01_20; PIXEL10_12; PIXEL11_22; break; \ - case 40: case 44: case 168: case 172: PIXEL00_21; PIXEL01_20; PIXEL10_11; PIXEL11_20; break; \ - case 9: case 13: case 137: case 141: PIXEL00_12; PIXEL01_20; PIXEL10_22; PIXEL11_20; break; \ - case 18: case 50: PIXEL00_22; if (Diff(RGBtoYUVtable[w2], RGBtoYUVtable[w6])) PIXEL01_10; else PIXEL01_20; PIXEL10_20; PIXEL11_21; break; \ - case 80: case 81: PIXEL00_20; PIXEL01_22; PIXEL10_21; if (Diff(RGBtoYUVtable[w6], RGBtoYUVtable[w8])) PIXEL11_10; else PIXEL11_20; break; \ - case 72: case 76: PIXEL00_21; PIXEL01_20; if (Diff(RGBtoYUVtable[w8], RGBtoYUVtable[w4])) PIXEL10_10; else PIXEL10_20; PIXEL11_22; break; \ - case 10: case 138: if (Diff(RGBtoYUVtable[w4], RGBtoYUVtable[w2])) PIXEL00_10; else PIXEL00_20; PIXEL01_21; PIXEL10_22; PIXEL11_20; break; \ - case 66: PIXEL00_22; PIXEL01_21; PIXEL10_21; PIXEL11_22; break; \ - case 24: PIXEL00_21; PIXEL01_22; PIXEL10_22; PIXEL11_21; break; \ - case 7: case 39: case 135: PIXEL00_11; PIXEL01_12; PIXEL10_20; PIXEL11_20; break; \ - case 148: case 149: case 180: PIXEL00_20; PIXEL01_11; PIXEL10_20; PIXEL11_12; break; \ - case 224: case 228: case 225: PIXEL00_20; PIXEL01_20; PIXEL10_12; PIXEL11_11; break; \ - case 41: case 169: case 45: PIXEL00_12; PIXEL01_20; PIXEL10_11; PIXEL11_20; break; \ - case 22: case 54: PIXEL00_22; if (Diff(RGBtoYUVtable[w2], RGBtoYUVtable[w6])) PIXEL01_0; else PIXEL01_20; PIXEL10_20; PIXEL11_21; break; \ - case 208: case 209: PIXEL00_20; PIXEL01_22; PIXEL10_21; if (Diff(RGBtoYUVtable[w6], RGBtoYUVtable[w8])) PIXEL11_0; else PIXEL11_20; break; \ - case 104: case 108: PIXEL00_21; PIXEL01_20; if (Diff(RGBtoYUVtable[w8], RGBtoYUVtable[w4])) PIXEL10_0; else PIXEL10_20; PIXEL11_22; break; \ - case 11: case 139: if (Diff(RGBtoYUVtable[w4], RGBtoYUVtable[w2])) PIXEL00_0; else PIXEL00_20; PIXEL01_21; PIXEL10_22; PIXEL11_20; break; \ - case 19: case 51: if (Diff(RGBtoYUVtable[w2], RGBtoYUVtable[w6])) PIXEL00_11, PIXEL01_10; else PIXEL00_60, PIXEL01_90; PIXEL10_20; PIXEL11_21; break; \ - case 146: case 178: PIXEL00_22; if (Diff(RGBtoYUVtable[w2], RGBtoYUVtable[w6])) PIXEL01_10, PIXEL11_12; else PIXEL01_90, PIXEL11_61; PIXEL10_20; break; \ - case 84: case 85: PIXEL00_20; if (Diff(RGBtoYUVtable[w6], RGBtoYUVtable[w8])) PIXEL01_11, PIXEL11_10; else PIXEL01_60, PIXEL11_90; PIXEL10_21; break; \ - case 112: case 113: PIXEL00_20; PIXEL01_22; if (Diff(RGBtoYUVtable[w6], RGBtoYUVtable[w8])) PIXEL10_12, PIXEL11_10; else PIXEL10_61, PIXEL11_90; break; \ - case 200: case 204: PIXEL00_21; PIXEL01_20; if (Diff(RGBtoYUVtable[w8], RGBtoYUVtable[w4])) PIXEL10_10, PIXEL11_11; else PIXEL10_90, PIXEL11_60; break; \ - case 73: case 77: if (Diff(RGBtoYUVtable[w8], RGBtoYUVtable[w4])) PIXEL00_12, PIXEL10_10; else PIXEL00_61, PIXEL10_90; PIXEL01_20; PIXEL11_22; break; \ - case 42: case 170: if (Diff(RGBtoYUVtable[w4], RGBtoYUVtable[w2])) PIXEL00_10, PIXEL10_11; else PIXEL00_90, PIXEL10_60; PIXEL01_21; PIXEL11_20; break; \ - case 14: case 142: if (Diff(RGBtoYUVtable[w4], RGBtoYUVtable[w2])) PIXEL00_10, PIXEL01_12; else PIXEL00_90, PIXEL01_61; PIXEL10_22; PIXEL11_20; break; \ - case 67: PIXEL00_11; PIXEL01_21; PIXEL10_21; PIXEL11_22; break; \ - case 70: PIXEL00_22; PIXEL01_12; PIXEL10_21; PIXEL11_22; break; \ - case 28: PIXEL00_21; PIXEL01_11; PIXEL10_22; PIXEL11_21; break; \ - case 152: PIXEL00_21; PIXEL01_22; PIXEL10_22; PIXEL11_12; break; \ - case 194: PIXEL00_22; PIXEL01_21; PIXEL10_21; PIXEL11_11; break; \ - case 98: PIXEL00_22; PIXEL01_21; PIXEL10_12; PIXEL11_22; break; \ - case 56: PIXEL00_21; PIXEL01_22; PIXEL10_11; PIXEL11_21; break; \ - case 25: PIXEL00_12; PIXEL01_22; PIXEL10_22; PIXEL11_21; break; \ - case 26: case 31: if (Diff(RGBtoYUVtable[w4], RGBtoYUVtable[w2])) PIXEL00_0; else PIXEL00_20; if (Diff(RGBtoYUVtable[w2], RGBtoYUVtable[w6])) PIXEL01_0; else PIXEL01_20; PIXEL10_22; PIXEL11_21; break; \ - case 82: case 214: PIXEL00_22; if (Diff(RGBtoYUVtable[w2], RGBtoYUVtable[w6])) PIXEL01_0; else PIXEL01_20; PIXEL10_21; if (Diff(RGBtoYUVtable[w6], RGBtoYUVtable[w8])) PIXEL11_0; else PIXEL11_20; break; \ - case 88: case 248: PIXEL00_21; PIXEL01_22; if (Diff(RGBtoYUVtable[w8], RGBtoYUVtable[w4])) PIXEL10_0; else PIXEL10_20; if (Diff(RGBtoYUVtable[w6], RGBtoYUVtable[w8])) PIXEL11_0; else PIXEL11_20; break; \ - case 74: case 107: if (Diff(RGBtoYUVtable[w4], RGBtoYUVtable[w2])) PIXEL00_0; else PIXEL00_20; PIXEL01_21; if (Diff(RGBtoYUVtable[w8], RGBtoYUVtable[w4])) PIXEL10_0; else PIXEL10_20; PIXEL11_22; break; \ - case 27: if (Diff(RGBtoYUVtable[w4], RGBtoYUVtable[w2])) PIXEL00_0; else PIXEL00_20; PIXEL01_10; PIXEL10_22; PIXEL11_21; break; \ - case 86: PIXEL00_22; if (Diff(RGBtoYUVtable[w2], RGBtoYUVtable[w6])) PIXEL01_0; else PIXEL01_20; PIXEL10_21; PIXEL11_10; break; \ - case 216: PIXEL00_21; PIXEL01_22; PIXEL10_10; if (Diff(RGBtoYUVtable[w6], RGBtoYUVtable[w8])) PIXEL11_0; else PIXEL11_20; break; \ - case 106: PIXEL00_10; PIXEL01_21; if (Diff(RGBtoYUVtable[w8], RGBtoYUVtable[w4])) PIXEL10_0; else PIXEL10_20; PIXEL11_22; break; \ - case 30: PIXEL00_10; if (Diff(RGBtoYUVtable[w2], RGBtoYUVtable[w6])) PIXEL01_0; else PIXEL01_20; PIXEL10_22; PIXEL11_21; break; \ - case 210: PIXEL00_22; PIXEL01_10; PIXEL10_21; if (Diff(RGBtoYUVtable[w6], RGBtoYUVtable[w8])) PIXEL11_0; else PIXEL11_20; break; \ - case 120: PIXEL00_21; PIXEL01_22; if (Diff(RGBtoYUVtable[w8], RGBtoYUVtable[w4])) PIXEL10_0; else PIXEL10_20; PIXEL11_10; break; \ - case 75: if (Diff(RGBtoYUVtable[w4], RGBtoYUVtable[w2])) PIXEL00_0; else PIXEL00_20; PIXEL01_21; PIXEL10_10; PIXEL11_22; break; \ - case 29: PIXEL00_12; PIXEL01_11; PIXEL10_22; PIXEL11_21; break; \ - case 198: PIXEL00_22; PIXEL01_12; PIXEL10_21; PIXEL11_11; break; \ - case 184: PIXEL00_21; PIXEL01_22; PIXEL10_11; PIXEL11_12; break; \ - case 99: PIXEL00_11; PIXEL01_21; PIXEL10_12; PIXEL11_22; break; \ - case 57: PIXEL00_12; PIXEL01_22; PIXEL10_11; PIXEL11_21; break; \ - case 71: PIXEL00_11; PIXEL01_12; PIXEL10_21; PIXEL11_22; break; \ - case 156: PIXEL00_21; PIXEL01_11; PIXEL10_22; PIXEL11_12; break; \ - case 226: PIXEL00_22; PIXEL01_21; PIXEL10_12; PIXEL11_11; break; \ - case 60: PIXEL00_21; PIXEL01_11; PIXEL10_11; PIXEL11_21; break; \ - case 195: PIXEL00_11; PIXEL01_21; PIXEL10_21; PIXEL11_11; break; \ - case 102: PIXEL00_22; PIXEL01_12; PIXEL10_12; PIXEL11_22; break; \ - case 153: PIXEL00_12; PIXEL01_22; PIXEL10_22; PIXEL11_12; break; \ - case 58: if (Diff(RGBtoYUVtable[w4], RGBtoYUVtable[w2])) PIXEL00_10; else PIXEL00_70; if (Diff(RGBtoYUVtable[w2], RGBtoYUVtable[w6])) PIXEL01_10; else PIXEL01_70; PIXEL10_11; PIXEL11_21; break; \ - case 83: PIXEL00_11; if (Diff(RGBtoYUVtable[w2], RGBtoYUVtable[w6])) PIXEL01_10; else PIXEL01_70; PIXEL10_21; if (Diff(RGBtoYUVtable[w6], RGBtoYUVtable[w8])) PIXEL11_10; else PIXEL11_70; break; \ - case 92: PIXEL00_21; PIXEL01_11; if (Diff(RGBtoYUVtable[w8], RGBtoYUVtable[w4])) PIXEL10_10; else PIXEL10_70; if (Diff(RGBtoYUVtable[w6], RGBtoYUVtable[w8])) PIXEL11_10; else PIXEL11_70; break; \ - case 202: if (Diff(RGBtoYUVtable[w4], RGBtoYUVtable[w2])) PIXEL00_10; else PIXEL00_70; PIXEL01_21; if (Diff(RGBtoYUVtable[w8], RGBtoYUVtable[w4])) PIXEL10_10; else PIXEL10_70; PIXEL11_11; break; \ - case 78: if (Diff(RGBtoYUVtable[w4], RGBtoYUVtable[w2])) PIXEL00_10; else PIXEL00_70; PIXEL01_12; if (Diff(RGBtoYUVtable[w8], RGBtoYUVtable[w4])) PIXEL10_10; else PIXEL10_70; PIXEL11_22; break; \ - case 154: if (Diff(RGBtoYUVtable[w4], RGBtoYUVtable[w2])) PIXEL00_10; else PIXEL00_70; if (Diff(RGBtoYUVtable[w2], RGBtoYUVtable[w6])) PIXEL01_10; else PIXEL01_70; PIXEL10_22; PIXEL11_12; break; \ - case 114: PIXEL00_22; if (Diff(RGBtoYUVtable[w2], RGBtoYUVtable[w6])) PIXEL01_10; else PIXEL01_70; PIXEL10_12; if (Diff(RGBtoYUVtable[w6], RGBtoYUVtable[w8])) PIXEL11_10; else PIXEL11_70; break; \ - case 89: PIXEL00_12; PIXEL01_22; if (Diff(RGBtoYUVtable[w8], RGBtoYUVtable[w4])) PIXEL10_10; else PIXEL10_70; if (Diff(RGBtoYUVtable[w6], RGBtoYUVtable[w8])) PIXEL11_10; else PIXEL11_70; break; \ - case 90: if (Diff(RGBtoYUVtable[w4], RGBtoYUVtable[w2])) PIXEL00_10; else PIXEL00_70; if (Diff(RGBtoYUVtable[w2], RGBtoYUVtable[w6])) PIXEL01_10; else PIXEL01_70; if (Diff(RGBtoYUVtable[w8], RGBtoYUVtable[w4])) PIXEL10_10; else PIXEL10_70; if (Diff(RGBtoYUVtable[w6], RGBtoYUVtable[w8])) PIXEL11_10; else PIXEL11_70; break; \ - case 55: case 23: if (Diff(RGBtoYUVtable[w2], RGBtoYUVtable[w6])) PIXEL00_11, PIXEL01_0; else PIXEL00_60, PIXEL01_90; PIXEL10_20; PIXEL11_21; break; \ - case 182: case 150: PIXEL00_22; if (Diff(RGBtoYUVtable[w2], RGBtoYUVtable[w6])) PIXEL01_0, PIXEL11_12; else PIXEL01_90, PIXEL11_61; PIXEL10_20; break; \ - case 213: case 212: PIXEL00_20; if (Diff(RGBtoYUVtable[w6], RGBtoYUVtable[w8])) PIXEL01_11, PIXEL11_0; else PIXEL01_60, PIXEL11_90; PIXEL10_21; break; \ - case 241: case 240: PIXEL00_20; PIXEL01_22; if (Diff(RGBtoYUVtable[w6], RGBtoYUVtable[w8])) PIXEL10_12, PIXEL11_0; else PIXEL10_61, PIXEL11_90; break; \ - case 236: case 232: PIXEL00_21; PIXEL01_20; if (Diff(RGBtoYUVtable[w8], RGBtoYUVtable[w4])) PIXEL10_0, PIXEL11_11; else PIXEL10_90, PIXEL11_60; break; \ - case 109: case 105: if (Diff(RGBtoYUVtable[w8], RGBtoYUVtable[w4])) PIXEL00_12, PIXEL10_0; else PIXEL00_61, PIXEL10_90; PIXEL01_20; PIXEL11_22; break; \ - case 171: case 43: if (Diff(RGBtoYUVtable[w4], RGBtoYUVtable[w2])) PIXEL00_0, PIXEL10_11; else PIXEL00_90, PIXEL10_60; PIXEL01_21; PIXEL11_20; break; \ - case 143: case 15: if (Diff(RGBtoYUVtable[w4], RGBtoYUVtable[w2])) PIXEL00_0, PIXEL01_12; else PIXEL00_90, PIXEL01_61; PIXEL10_22; PIXEL11_20; break; \ - case 124: PIXEL00_21; PIXEL01_11; if (Diff(RGBtoYUVtable[w8], RGBtoYUVtable[w4])) PIXEL10_0; else PIXEL10_20; PIXEL11_10; break; \ - case 203: if (Diff(RGBtoYUVtable[w4], RGBtoYUVtable[w2])) PIXEL00_0; else PIXEL00_20; PIXEL01_21; PIXEL10_10; PIXEL11_11; break; \ - case 62: PIXEL00_10; if (Diff(RGBtoYUVtable[w2], RGBtoYUVtable[w6])) PIXEL01_0; else PIXEL01_20; PIXEL10_11; PIXEL11_21; break; \ - case 211: PIXEL00_11; PIXEL01_10; PIXEL10_21; if (Diff(RGBtoYUVtable[w6], RGBtoYUVtable[w8])) PIXEL11_0; else PIXEL11_20; break; \ - case 118: PIXEL00_22; if (Diff(RGBtoYUVtable[w2], RGBtoYUVtable[w6])) PIXEL01_0; else PIXEL01_20; PIXEL10_12; PIXEL11_10; break; \ - case 217: PIXEL00_12; PIXEL01_22; PIXEL10_10; if (Diff(RGBtoYUVtable[w6], RGBtoYUVtable[w8])) PIXEL11_0; else PIXEL11_20; break; \ - case 110: PIXEL00_10; PIXEL01_12; if (Diff(RGBtoYUVtable[w8], RGBtoYUVtable[w4])) PIXEL10_0; else PIXEL10_20; PIXEL11_22; break; \ - case 155: if (Diff(RGBtoYUVtable[w4], RGBtoYUVtable[w2])) PIXEL00_0; else PIXEL00_20; PIXEL01_10; PIXEL10_22; PIXEL11_12; break; \ - case 188: PIXEL00_21; PIXEL01_11; PIXEL10_11; PIXEL11_12; break; \ - case 185: PIXEL00_12; PIXEL01_22; PIXEL10_11; PIXEL11_12; break; \ - case 61: PIXEL00_12; PIXEL01_11; PIXEL10_11; PIXEL11_21; break; \ - case 157: PIXEL00_12; PIXEL01_11; PIXEL10_22; PIXEL11_12; break; \ - case 103: PIXEL00_11; PIXEL01_12; PIXEL10_12; PIXEL11_22; break; \ - case 227: PIXEL00_11; PIXEL01_21; PIXEL10_12; PIXEL11_11; break; \ - case 230: PIXEL00_22; PIXEL01_12; PIXEL10_12; PIXEL11_11; break; \ - case 199: PIXEL00_11; PIXEL01_12; PIXEL10_21; PIXEL11_11; break; \ - case 220: PIXEL00_21; PIXEL01_11; if (Diff(RGBtoYUVtable[w8], RGBtoYUVtable[w4])) PIXEL10_10; else PIXEL10_70; if (Diff(RGBtoYUVtable[w6], RGBtoYUVtable[w8])) PIXEL11_0; else PIXEL11_20; break; \ - case 158: if (Diff(RGBtoYUVtable[w4], RGBtoYUVtable[w2])) PIXEL00_10; else PIXEL00_70; if (Diff(RGBtoYUVtable[w2], RGBtoYUVtable[w6])) PIXEL01_0; else PIXEL01_20; PIXEL10_22; PIXEL11_12; break; \ - case 234: if (Diff(RGBtoYUVtable[w4], RGBtoYUVtable[w2])) PIXEL00_10; else PIXEL00_70; PIXEL01_21; if (Diff(RGBtoYUVtable[w8], RGBtoYUVtable[w4])) PIXEL10_0; else PIXEL10_20; PIXEL11_11; break; \ - case 242: PIXEL00_22; if (Diff(RGBtoYUVtable[w2], RGBtoYUVtable[w6])) PIXEL01_10; else PIXEL01_70; PIXEL10_12; if (Diff(RGBtoYUVtable[w6], RGBtoYUVtable[w8])) PIXEL11_0; else PIXEL11_20; break; \ - case 59: if (Diff(RGBtoYUVtable[w4], RGBtoYUVtable[w2])) PIXEL00_0; else PIXEL00_20; if (Diff(RGBtoYUVtable[w2], RGBtoYUVtable[w6])) PIXEL01_10; else PIXEL01_70; PIXEL10_11; PIXEL11_21; break; \ - case 121: PIXEL00_12; PIXEL01_22; if (Diff(RGBtoYUVtable[w8], RGBtoYUVtable[w4])) PIXEL10_0; else PIXEL10_20; if (Diff(RGBtoYUVtable[w6], RGBtoYUVtable[w8])) PIXEL11_10; else PIXEL11_70; break; \ - case 87: PIXEL00_11; if (Diff(RGBtoYUVtable[w2], RGBtoYUVtable[w6])) PIXEL01_0; else PIXEL01_20; PIXEL10_21; if (Diff(RGBtoYUVtable[w6], RGBtoYUVtable[w8])) PIXEL11_10; else PIXEL11_70; break; \ - case 79: if (Diff(RGBtoYUVtable[w4], RGBtoYUVtable[w2])) PIXEL00_0; else PIXEL00_20; PIXEL01_12; if (Diff(RGBtoYUVtable[w8], RGBtoYUVtable[w4])) PIXEL10_10; else PIXEL10_70; PIXEL11_22; break; \ - case 122: if (Diff(RGBtoYUVtable[w4], RGBtoYUVtable[w2])) PIXEL00_10; else PIXEL00_70; if (Diff(RGBtoYUVtable[w2], RGBtoYUVtable[w6])) PIXEL01_10; else PIXEL01_70; if (Diff(RGBtoYUVtable[w8], RGBtoYUVtable[w4])) PIXEL10_0; else PIXEL10_20; if (Diff(RGBtoYUVtable[w6], RGBtoYUVtable[w8])) PIXEL11_10; else PIXEL11_70; break; \ - case 94: if (Diff(RGBtoYUVtable[w4], RGBtoYUVtable[w2])) PIXEL00_10; else PIXEL00_70; if (Diff(RGBtoYUVtable[w2], RGBtoYUVtable[w6])) PIXEL01_0; else PIXEL01_20; if (Diff(RGBtoYUVtable[w8], RGBtoYUVtable[w4])) PIXEL10_10; else PIXEL10_70; if (Diff(RGBtoYUVtable[w6], RGBtoYUVtable[w8])) PIXEL11_10; else PIXEL11_70; break; \ - case 218: if (Diff(RGBtoYUVtable[w4], RGBtoYUVtable[w2])) PIXEL00_10; else PIXEL00_70; if (Diff(RGBtoYUVtable[w2], RGBtoYUVtable[w6])) PIXEL01_10; else PIXEL01_70; if (Diff(RGBtoYUVtable[w8], RGBtoYUVtable[w4])) PIXEL10_10; else PIXEL10_70; if (Diff(RGBtoYUVtable[w6], RGBtoYUVtable[w8])) PIXEL11_0; else PIXEL11_20; break; \ - case 91: if (Diff(RGBtoYUVtable[w4], RGBtoYUVtable[w2])) PIXEL00_0; else PIXEL00_20; if (Diff(RGBtoYUVtable[w2], RGBtoYUVtable[w6])) PIXEL01_10; else PIXEL01_70; if (Diff(RGBtoYUVtable[w8], RGBtoYUVtable[w4])) PIXEL10_10; else PIXEL10_70; if (Diff(RGBtoYUVtable[w6], RGBtoYUVtable[w8])) PIXEL11_10; else PIXEL11_70; break; \ - case 229: PIXEL00_20; PIXEL01_20; PIXEL10_12; PIXEL11_11; break; \ - case 167: PIXEL00_11; PIXEL01_12; PIXEL10_20; PIXEL11_20; break; \ - case 173: PIXEL00_12; PIXEL01_20; PIXEL10_11; PIXEL11_20; break; \ - case 181: PIXEL00_20; PIXEL01_11; PIXEL10_20; PIXEL11_12; break; \ - case 186: if (Diff(RGBtoYUVtable[w4], RGBtoYUVtable[w2])) PIXEL00_10; else PIXEL00_70; if (Diff(RGBtoYUVtable[w2], RGBtoYUVtable[w6])) PIXEL01_10; else PIXEL01_70; PIXEL10_11; PIXEL11_12; break; \ - case 115: PIXEL00_11; if (Diff(RGBtoYUVtable[w2], RGBtoYUVtable[w6])) PIXEL01_10; else PIXEL01_70; PIXEL10_12; if (Diff(RGBtoYUVtable[w6], RGBtoYUVtable[w8])) PIXEL11_10; else PIXEL11_70; break; \ - case 93: PIXEL00_12; PIXEL01_11; if (Diff(RGBtoYUVtable[w8], RGBtoYUVtable[w4])) PIXEL10_10; else PIXEL10_70; if (Diff(RGBtoYUVtable[w6], RGBtoYUVtable[w8])) PIXEL11_10; else PIXEL11_70; break; \ - case 206: if (Diff(RGBtoYUVtable[w4], RGBtoYUVtable[w2])) PIXEL00_10; else PIXEL00_70; PIXEL01_12; if (Diff(RGBtoYUVtable[w8], RGBtoYUVtable[w4])) PIXEL10_10; else PIXEL10_70; PIXEL11_11; break; \ - case 205: case 201: PIXEL00_12; PIXEL01_20; if (Diff(RGBtoYUVtable[w8], RGBtoYUVtable[w4])) PIXEL10_10; else PIXEL10_70; PIXEL11_11; break; \ - case 174: case 46: if (Diff(RGBtoYUVtable[w4], RGBtoYUVtable[w2])) PIXEL00_10; else PIXEL00_70; PIXEL01_12; PIXEL10_11; PIXEL11_20; break; \ - case 179: case 147: PIXEL00_11; if (Diff(RGBtoYUVtable[w2], RGBtoYUVtable[w6])) PIXEL01_10; else PIXEL01_70; PIXEL10_20; PIXEL11_12; break; \ - case 117: case 116: PIXEL00_20; PIXEL01_11; PIXEL10_12; if (Diff(RGBtoYUVtable[w6], RGBtoYUVtable[w8])) PIXEL11_10; else PIXEL11_70; break; \ - case 189: PIXEL00_12; PIXEL01_11; PIXEL10_11; PIXEL11_12; break; \ - case 231: PIXEL00_11; PIXEL01_12; PIXEL10_12; PIXEL11_11; break; \ - case 126: PIXEL00_10; if (Diff(RGBtoYUVtable[w2], RGBtoYUVtable[w6])) PIXEL01_0; else PIXEL01_20; if (Diff(RGBtoYUVtable[w8], RGBtoYUVtable[w4])) PIXEL10_0; else PIXEL10_20; PIXEL11_10; break; \ - case 219: if (Diff(RGBtoYUVtable[w4], RGBtoYUVtable[w2])) PIXEL00_0; else PIXEL00_20; PIXEL01_10; PIXEL10_10; if (Diff(RGBtoYUVtable[w6], RGBtoYUVtable[w8])) PIXEL11_0; else PIXEL11_20; break; \ - case 125: if (Diff(RGBtoYUVtable[w8], RGBtoYUVtable[w4])) PIXEL00_12, PIXEL10_0; else PIXEL00_61, PIXEL10_90; PIXEL01_11; PIXEL11_10; break; \ - case 221: PIXEL00_12; if (Diff(RGBtoYUVtable[w6], RGBtoYUVtable[w8])) PIXEL01_11, PIXEL11_0; else PIXEL01_60, PIXEL11_90; PIXEL10_10; break; \ - case 207: if (Diff(RGBtoYUVtable[w4], RGBtoYUVtable[w2])) PIXEL00_0, PIXEL01_12; else PIXEL00_90, PIXEL01_61; PIXEL10_10; PIXEL11_11; break; \ - case 238: PIXEL00_10; PIXEL01_12; if (Diff(RGBtoYUVtable[w8], RGBtoYUVtable[w4])) PIXEL10_0, PIXEL11_11; else PIXEL10_90, PIXEL11_60; break; \ - case 190: PIXEL00_10; if (Diff(RGBtoYUVtable[w2], RGBtoYUVtable[w6])) PIXEL01_0, PIXEL11_12; else PIXEL01_90, PIXEL11_61; PIXEL10_11; break; \ - case 187: if (Diff(RGBtoYUVtable[w4], RGBtoYUVtable[w2])) PIXEL00_0, PIXEL10_11; else PIXEL00_90, PIXEL10_60; PIXEL01_10; PIXEL11_12; break; \ - case 243: PIXEL00_11; PIXEL01_10; if (Diff(RGBtoYUVtable[w6], RGBtoYUVtable[w8])) PIXEL10_12, PIXEL11_0; else PIXEL10_61, PIXEL11_90; break; \ - case 119: if (Diff(RGBtoYUVtable[w2], RGBtoYUVtable[w6])) PIXEL00_11, PIXEL01_0; else PIXEL00_60, PIXEL01_90; PIXEL10_12; PIXEL11_10; break; \ - case 237: case 233: PIXEL00_12; PIXEL01_20; if (Diff(RGBtoYUVtable[w8], RGBtoYUVtable[w4])) PIXEL10_0; else PIXEL10_100; PIXEL11_11; break; \ - case 175: case 47: if (Diff(RGBtoYUVtable[w4], RGBtoYUVtable[w2])) PIXEL00_0; else PIXEL00_100; PIXEL01_12; PIXEL10_11; PIXEL11_20; break; \ - case 183: case 151: PIXEL00_11; if (Diff(RGBtoYUVtable[w2], RGBtoYUVtable[w6])) PIXEL01_0; else PIXEL01_100; PIXEL10_20; PIXEL11_12; break; \ - case 245: case 244: PIXEL00_20; PIXEL01_11; PIXEL10_12; if (Diff(RGBtoYUVtable[w6], RGBtoYUVtable[w8])) PIXEL11_0; else PIXEL11_100; break; \ - case 250: PIXEL00_10; PIXEL01_10; if (Diff(RGBtoYUVtable[w8], RGBtoYUVtable[w4])) PIXEL10_0; else PIXEL10_20; if (Diff(RGBtoYUVtable[w6], RGBtoYUVtable[w8])) PIXEL11_0; else PIXEL11_20; break; \ - case 123: if (Diff(RGBtoYUVtable[w4], RGBtoYUVtable[w2])) PIXEL00_0; else PIXEL00_20; PIXEL01_10; if (Diff(RGBtoYUVtable[w8], RGBtoYUVtable[w4])) PIXEL10_0; else PIXEL10_20; PIXEL11_10; break; \ - case 95: if (Diff(RGBtoYUVtable[w4], RGBtoYUVtable[w2])) PIXEL00_0; else PIXEL00_20; if (Diff(RGBtoYUVtable[w2], RGBtoYUVtable[w6])) PIXEL01_0; else PIXEL01_20; PIXEL10_10; PIXEL11_10; break; \ - case 222: PIXEL00_10; if (Diff(RGBtoYUVtable[w2], RGBtoYUVtable[w6])) PIXEL01_0; else PIXEL01_20; PIXEL10_10; if (Diff(RGBtoYUVtable[w6], RGBtoYUVtable[w8])) PIXEL11_0; else PIXEL11_20; break; \ - case 252: PIXEL00_21; PIXEL01_11; if (Diff(RGBtoYUVtable[w8], RGBtoYUVtable[w4])) PIXEL10_0; else PIXEL10_20; if (Diff(RGBtoYUVtable[w6], RGBtoYUVtable[w8])) PIXEL11_0; else PIXEL11_100; break; \ - case 249: PIXEL00_12; PIXEL01_22; if (Diff(RGBtoYUVtable[w8], RGBtoYUVtable[w4])) PIXEL10_0; else PIXEL10_100; if (Diff(RGBtoYUVtable[w6], RGBtoYUVtable[w8])) PIXEL11_0; else PIXEL11_20; break; \ - case 235: if (Diff(RGBtoYUVtable[w4], RGBtoYUVtable[w2])) PIXEL00_0; else PIXEL00_20; PIXEL01_21; if (Diff(RGBtoYUVtable[w8], RGBtoYUVtable[w4])) PIXEL10_0; else PIXEL10_100; PIXEL11_11; break; \ - case 111: if (Diff(RGBtoYUVtable[w4], RGBtoYUVtable[w2])) PIXEL00_0; else PIXEL00_100; PIXEL01_12; if (Diff(RGBtoYUVtable[w8], RGBtoYUVtable[w4])) PIXEL10_0; else PIXEL10_20; PIXEL11_22; break; \ - case 63: if (Diff(RGBtoYUVtable[w4], RGBtoYUVtable[w2])) PIXEL00_0; else PIXEL00_100; if (Diff(RGBtoYUVtable[w2], RGBtoYUVtable[w6])) PIXEL01_0; else PIXEL01_20; PIXEL10_11; PIXEL11_21; break; \ - case 159: if (Diff(RGBtoYUVtable[w4], RGBtoYUVtable[w2])) PIXEL00_0; else PIXEL00_20; if (Diff(RGBtoYUVtable[w2], RGBtoYUVtable[w6])) PIXEL01_0; else PIXEL01_100; PIXEL10_22; PIXEL11_12; break; \ - case 215: PIXEL00_11; if (Diff(RGBtoYUVtable[w2], RGBtoYUVtable[w6])) PIXEL01_0; else PIXEL01_100; PIXEL10_21; if (Diff(RGBtoYUVtable[w6], RGBtoYUVtable[w8])) PIXEL11_0; else PIXEL11_20; break; \ - case 246: PIXEL00_22; if (Diff(RGBtoYUVtable[w2], RGBtoYUVtable[w6])) PIXEL01_0; else PIXEL01_20; PIXEL10_12; if (Diff(RGBtoYUVtable[w6], RGBtoYUVtable[w8])) PIXEL11_0; else PIXEL11_100; break; \ - case 254: PIXEL00_10; if (Diff(RGBtoYUVtable[w2], RGBtoYUVtable[w6])) PIXEL01_0; else PIXEL01_20; if (Diff(RGBtoYUVtable[w8], RGBtoYUVtable[w4])) PIXEL10_0; else PIXEL10_20; if (Diff(RGBtoYUVtable[w6], RGBtoYUVtable[w8])) PIXEL11_0; else PIXEL11_100; break; \ - case 253: PIXEL00_12; PIXEL01_11; if (Diff(RGBtoYUVtable[w8], RGBtoYUVtable[w4])) PIXEL10_0; else PIXEL10_100; if (Diff(RGBtoYUVtable[w6], RGBtoYUVtable[w8])) PIXEL11_0; else PIXEL11_100; break; \ - case 251: if (Diff(RGBtoYUVtable[w4], RGBtoYUVtable[w2])) PIXEL00_0; else PIXEL00_20; PIXEL01_10; if (Diff(RGBtoYUVtable[w8], RGBtoYUVtable[w4])) PIXEL10_0; else PIXEL10_100; if (Diff(RGBtoYUVtable[w6], RGBtoYUVtable[w8])) PIXEL11_0; else PIXEL11_20; break; \ - case 239: if (Diff(RGBtoYUVtable[w4], RGBtoYUVtable[w2])) PIXEL00_0; else PIXEL00_100; PIXEL01_12; if (Diff(RGBtoYUVtable[w8], RGBtoYUVtable[w4])) PIXEL10_0; else PIXEL10_100; PIXEL11_11; break; \ - case 127: if (Diff(RGBtoYUVtable[w4], RGBtoYUVtable[w2])) PIXEL00_0; else PIXEL00_100; if (Diff(RGBtoYUVtable[w2], RGBtoYUVtable[w6])) PIXEL01_0; else PIXEL01_20; if (Diff(RGBtoYUVtable[w8], RGBtoYUVtable[w4])) PIXEL10_0; else PIXEL10_20; PIXEL11_10; break; \ - case 191: if (Diff(RGBtoYUVtable[w4], RGBtoYUVtable[w2])) PIXEL00_0; else PIXEL00_100; if (Diff(RGBtoYUVtable[w2], RGBtoYUVtable[w6])) PIXEL01_0; else PIXEL01_100; PIXEL10_11; PIXEL11_12; break; \ - case 223: if (Diff(RGBtoYUVtable[w4], RGBtoYUVtable[w2])) PIXEL00_0; else PIXEL00_20; if (Diff(RGBtoYUVtable[w2], RGBtoYUVtable[w6])) PIXEL01_0; else PIXEL01_100; PIXEL10_10; if (Diff(RGBtoYUVtable[w6], RGBtoYUVtable[w8])) PIXEL11_0; else PIXEL11_20; break; \ - case 247: PIXEL00_11; if (Diff(RGBtoYUVtable[w2], RGBtoYUVtable[w6])) PIXEL01_0; else PIXEL01_100; PIXEL10_12; if (Diff(RGBtoYUVtable[w6], RGBtoYUVtable[w8])) PIXEL11_0; else PIXEL11_100; break; \ - case 255: if (Diff(RGBtoYUVtable[w4], RGBtoYUVtable[w2])) PIXEL00_0; else PIXEL00_100; if (Diff(RGBtoYUVtable[w2], RGBtoYUVtable[w6])) PIXEL01_0; else PIXEL01_100; if (Diff(RGBtoYUVtable[w8], RGBtoYUVtable[w4])) PIXEL10_0; else PIXEL10_100; if (Diff(RGBtoYUVtable[w6], RGBtoYUVtable[w8])) PIXEL11_0; else PIXEL11_100; break; - -//template -void RenderHQ2X (SSurface Src, SSurface Dst) -{ - - u8 *srcPtr = Src.Surface; - u8 *dstPtr = Dst.Surface; - u32 srcPitch = Src.Pitch; - u32 dstPitch = Dst.Pitch; - int width = Src.Width; - int height = Src.Height; - - int w1, w2, w3, w4, w5, w6, w7, w8, w9; - - u32 src1line = srcPitch >> 1; - u32 dst1line = dstPitch >> 1; - u16 *sp = (u16 *) srcPtr; - u16 *dp = (u16 *) dstPtr; - - const int* RGBtoYUVtable = RGBtoYUV; - - u32 pattern; - int l, y; - - while (height--) - { - sp--; - - w1 = *(sp - src1line); - w4 = *(sp); - w7 = *(sp + src1line); - - sp++; - - w2 = *(sp - src1line); - w5 = *(sp); - w8 = *(sp + src1line); - - for (l = width; l; l--) - { - sp++; - - w3 = *(sp - src1line); - w6 = *(sp); - w9 = *(sp + src1line); - - pattern = 0; - -/* switch(GuiScale) - { - case FILTER_HQ2XBOLD: { - const u16 avg = (RGBtoBright[w1] + RGBtoBright[w2] + RGBtoBright[w3] + RGBtoBright[w4] + RGBtoBright[w5] + RGBtoBright[w6] + RGBtoBright[w7] + RGBtoBright[w8] + RGBtoBright[w9]) / 9; - const bool diff5 = RGBtoBright[w5] > avg; - if ((w1 != w5) && ((RGBtoBright[w1] > avg) != diff5)) pattern |= (1 << 0); - if ((w2 != w5) && ((RGBtoBright[w2] > avg) != diff5)) pattern |= (1 << 1); - if ((w3 != w5) && ((RGBtoBright[w3] > avg) != diff5)) pattern |= (1 << 2); - if ((w4 != w5) && ((RGBtoBright[w4] > avg) != diff5)) pattern |= (1 << 3); - if ((w6 != w5) && ((RGBtoBright[w6] > avg) != diff5)) pattern |= (1 << 4); - if ((w7 != w5) && ((RGBtoBright[w7] > avg) != diff5)) pattern |= (1 << 5); - if ((w8 != w5) && ((RGBtoBright[w8] > avg) != diff5)) pattern |= (1 << 6); - if ((w9 != w5) && ((RGBtoBright[w9] > avg) != diff5)) pattern |= (1 << 7); - } break; - - case FILTER_HQ2XS: { - bool nosame = true; - if(w1 == w5 || w3 == w5 || w7 == w5 || w9 == w5) - nosame = false; - - if(nosame) - { - const u16 avg = (RGBtoBright[w1] + RGBtoBright[w2] + RGBtoBright[w3] + RGBtoBright[w4] + RGBtoBright[w5] + RGBtoBright[w6] + RGBtoBright[w7] + RGBtoBright[w8] + RGBtoBright[w9]) / 9; - const bool diff5 = RGBtoBright[w5] > avg; - if((RGBtoBright[w1] > avg) != diff5) pattern |= (1 << 0); - if((RGBtoBright[w2] > avg) != diff5) pattern |= (1 << 1); - if((RGBtoBright[w3] > avg) != diff5) pattern |= (1 << 2); - if((RGBtoBright[w4] > avg) != diff5) pattern |= (1 << 3); - if((RGBtoBright[w6] > avg) != diff5) pattern |= (1 << 4); - if((RGBtoBright[w7] > avg) != diff5) pattern |= (1 << 5); - if((RGBtoBright[w8] > avg) != diff5) pattern |= (1 << 6); - if((RGBtoBright[w9] > avg) != diff5) pattern |= (1 << 7); - } - else - { - y = RGBtoYUV[w5]; - if ((w1 != w5) && (Diff(y, RGBtoYUV[w1]))) pattern |= (1 << 0); - if ((w2 != w5) && (Diff(y, RGBtoYUV[w2]))) pattern |= (1 << 1); - if ((w3 != w5) && (Diff(y, RGBtoYUV[w3]))) pattern |= (1 << 2); - if ((w4 != w5) && (Diff(y, RGBtoYUV[w4]))) pattern |= (1 << 3); - if ((w6 != w5) && (Diff(y, RGBtoYUV[w6]))) pattern |= (1 << 4); - if ((w7 != w5) && (Diff(y, RGBtoYUV[w7]))) pattern |= (1 << 5); - if ((w8 != w5) && (Diff(y, RGBtoYUV[w8]))) pattern |= (1 << 6); - if ((w9 != w5) && (Diff(y, RGBtoYUV[w9]))) pattern |= (1 << 7); - } - } break; - default: - case FILTER_HQ2X:*/ - y = RGBtoYUVtable[w5]; - if ((w1 != w5) && (Diff(y, RGBtoYUVtable[w1]))) pattern |= (1 << 0); - if ((w2 != w5) && (Diff(y, RGBtoYUVtable[w2]))) pattern |= (1 << 1); - if ((w3 != w5) && (Diff(y, RGBtoYUVtable[w3]))) pattern |= (1 << 2); - if ((w4 != w5) && (Diff(y, RGBtoYUVtable[w4]))) pattern |= (1 << 3); - if ((w6 != w5) && (Diff(y, RGBtoYUVtable[w6]))) pattern |= (1 << 4); - if ((w7 != w5) && (Diff(y, RGBtoYUVtable[w7]))) pattern |= (1 << 5); - if ((w8 != w5) && (Diff(y, RGBtoYUVtable[w8]))) pattern |= (1 << 6); - if ((w9 != w5) && (Diff(y, RGBtoYUVtable[w9]))) pattern |= (1 << 7); - /* break; - } -*/ - switch (pattern) - { - HQ2XCASES - } - - w1 = w2; w4 = w5; w7 = w8; - w2 = w3; w5 = w6; w8 = w9; - - dp += 2; - } - - dp += ((dst1line - width) << 1); - sp += (src1line - width); - } -} \ No newline at end of file diff --git a/desmume/src/windows/filter/scanline.cpp b/desmume/src/windows/filter/scanline.cpp deleted file mode 100644 index 96ffdd5fb..000000000 --- a/desmume/src/windows/filter/scanline.cpp +++ /dev/null @@ -1,48 +0,0 @@ -#include "filter.h" -#include "types.h" -#include -#include - -typedef u64 uint64; - -extern CACHE_ALIGN u16 fadeOutColors[17][0x8000]; - -extern int scanline_filter_a, scanline_filter_b; - -// stretches a single line -inline void DoubleLine16( uint16 *lpDst, uint16 *lpSrc, unsigned int Width){ - while(Width--){ - *lpDst++ = *lpSrc; - *lpDst++ = fadeOutColors[scanline_filter_a][(*lpSrc++)]; - } -} - -inline void DoubleLine16_2( uint16 *lpDst, uint16 *lpSrc, unsigned int Width){ - while(Width--){ - *lpDst++ = fadeOutColors[scanline_filter_a][(*lpSrc)]; - *lpDst++ = fadeOutColors[scanline_filter_b][(*lpSrc++)]; - } -} - -void RenderScanline( SSurface Src, SSurface Dst) -{ - uint16 *lpSrc; - unsigned int H; - - const uint32 srcHeight = Src.Height; - - const unsigned int srcPitch = Src.Pitch >> 1; - lpSrc = reinterpret_cast(Src.Surface); - - const unsigned int dstPitch = Dst.Pitch >> 1; - uint16 *lpDst = (uint16*)Dst.Surface; - if(Src.Width != 512) - for (H = 0; H < srcHeight; H++, lpSrc += srcPitch) - DoubleLine16 (lpDst, lpSrc, Src.Width), lpDst += dstPitch, - DoubleLine16_2 (lpDst, lpSrc, Src.Width), lpDst += dstPitch; - //memset (lpDst, 0, 512*2), lpDst += dstPitch; - else - for (H = 0; H < srcHeight; H++, lpSrc += srcPitch) - memcpy (lpDst, lpSrc, Src.Width << 1), lpDst += dstPitch, - memset (lpDst, 0, 512*2), lpDst += dstPitch; -} \ No newline at end of file diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gthread/gthread-impl.c b/desmume/src/windows/glib-2.20.1/build/glib/gthread/gthread-impl.c deleted file mode 100644 index 24eb3c48e..000000000 --- a/desmume/src/windows/glib-2.20.1/build/glib/gthread/gthread-impl.c +++ /dev/null @@ -1,372 +0,0 @@ -/* GLIB - Library of useful routines for C programming - * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald - * - * gthread.c: thread related functions - * Copyright 1998 Sebastian Wilhelmi; University of Karlsruhe - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the - * Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -/* - * Modified by the GLib Team and others 1997-2000. See the AUTHORS - * file for a list of people on the GLib Team. See the ChangeLog - * files for a list of changes. These files are distributed with - * GLib at ftp://ftp.gtk.org/pub/gtk/. - */ - -/* - * MT safe - */ - -#include "config.h" - -#include "glib.h" -#include "gthreadprivate.h" - -#ifdef G_THREADS_ENABLED - -static GSystemThread zero_thread; /* This is initialized to all zero */ -static gboolean thread_system_already_initialized = FALSE; -static gint g_thread_priority_map [G_THREAD_PRIORITY_URGENT + 1]; - -#include G_THREAD_SOURCE - -#ifndef PRIORITY_LOW_VALUE -# define PRIORITY_LOW_VALUE 0 -#endif - -#ifndef PRIORITY_URGENT_VALUE -# define PRIORITY_URGENT_VALUE 0 -#endif - -#ifndef PRIORITY_NORMAL_VALUE -# define PRIORITY_NORMAL_VALUE \ - ((PRIORITY_LOW_VALUE * 6 + PRIORITY_URGENT_VALUE * 4) / 10) -#endif /* PRIORITY_NORMAL_VALUE */ - -#ifndef PRIORITY_HIGH_VALUE -# define PRIORITY_HIGH_VALUE \ - ((PRIORITY_NORMAL_VALUE + PRIORITY_URGENT_VALUE * 2) / 3) -#endif /* PRIORITY_HIGH_VALUE */ - -void g_mutex_init (void); -void g_mem_init (void); -void g_messages_init (void); -void g_convert_init (void); -void g_rand_init (void); -void g_main_thread_init (void); - -typedef struct _GMutexDebugInfo GMutexDebugInfo; -struct _GMutexDebugInfo -{ - gchar *location; - GSystemThread owner; -}; - -#define G_MUTEX_DEBUG_INFO(mutex) \ - (((GMutexDebugInfo*)(((char*)mutex)+G_MUTEX_SIZE))) - -static GMutex * -g_mutex_new_errorcheck_impl (void) -{ - GMutex *retval = g_thread_functions_for_glib_use_default.mutex_new (); - GMutexDebugInfo *info; - retval = g_realloc (retval, G_MUTEX_SIZE + sizeof (GMutexDebugInfo)); - - info = G_MUTEX_DEBUG_INFO (retval); - g_system_thread_assign (info->owner, zero_thread); - info->location = "invalid"; - - return retval; -} - -static void -g_mutex_lock_errorcheck_impl (GMutex *mutex, - const gulong magic, - gchar * const location) -{ - GMutexDebugInfo *info = G_MUTEX_DEBUG_INFO (mutex); - gchar *loc = (magic == G_MUTEX_DEBUG_MAGIC) ? location : "unknown"; - - GSystemThread self; - g_thread_functions_for_glib_use.thread_self (&self); - - if (g_system_thread_equal (info->owner, self)) - g_error ("Trying to recursivly lock a mutex at '%s', " - "previously locked at '%s'", - loc, info->location); - - g_thread_functions_for_glib_use_default.mutex_lock (mutex); - - g_system_thread_assign (info->owner, self); - info->location = loc; -} - -static gboolean -g_mutex_trylock_errorcheck_impl (GMutex *mutex, - const gulong magic, - gchar * const location) -{ - GMutexDebugInfo *info = G_MUTEX_DEBUG_INFO (mutex); - gchar *loc = (magic == G_MUTEX_DEBUG_MAGIC) ? location : "unknown"; - - GSystemThread self; - g_thread_functions_for_glib_use.thread_self (&self); - - if (g_system_thread_equal (info->owner, self)) - g_error ("Trying to recursivly lock a mutex at '%s', " - "previously locked at '%s'", - loc, info->location); - - if (!g_thread_functions_for_glib_use_default.mutex_trylock (mutex)) - return FALSE; - - g_system_thread_assign (info->owner, self); - info->location = loc; - - return TRUE; -} - -static void -g_mutex_unlock_errorcheck_impl (GMutex *mutex, - const gulong magic, - gchar * const location) -{ - GMutexDebugInfo *info = G_MUTEX_DEBUG_INFO (mutex); - gchar *loc = (magic == G_MUTEX_DEBUG_MAGIC) ? location : "unknown"; - - GSystemThread self; - g_thread_functions_for_glib_use.thread_self (&self); - - if (g_system_thread_equal (info->owner, zero_thread)) - g_error ("Trying to unlock an unlocked mutex at '%s'", loc); - - if (!g_system_thread_equal (info->owner, self)) - g_warning ("Trying to unlock a mutex at '%s', " - "previously locked by a different thread at '%s'", - loc, info->location); - - g_system_thread_assign (info->owner, zero_thread); - info->location = NULL; - - g_thread_functions_for_glib_use_default.mutex_unlock (mutex); -} - -static void -g_mutex_free_errorcheck_impl (GMutex *mutex, - const gulong magic, - gchar * const location) -{ - GMutexDebugInfo *info = G_MUTEX_DEBUG_INFO (mutex); - gchar *loc = (magic == G_MUTEX_DEBUG_MAGIC) ? location : "unknown"; - - if (info && !g_system_thread_equal (info->owner, zero_thread)) - g_error ("Trying to free a locked mutex at '%s', " - "which was previously locked at '%s'", - loc, info->location); - - g_thread_functions_for_glib_use_default.mutex_free (mutex); -} - -static void -g_cond_wait_errorcheck_impl (GCond *cond, - GMutex *mutex, - const gulong magic, - gchar * const location) -{ - GMutexDebugInfo *info = G_MUTEX_DEBUG_INFO (mutex); - gchar *loc = (magic == G_MUTEX_DEBUG_MAGIC) ? location : "unknown"; - - GSystemThread self; - g_thread_functions_for_glib_use.thread_self (&self); - - if (g_system_thread_equal (info->owner, zero_thread)) - g_error ("Trying to use an unlocked mutex in g_cond_wait() at '%s'", loc); - - if (!g_system_thread_equal (info->owner, self)) - g_error ("Trying to use a mutex locked by another thread in " - "g_cond_wait() at '%s'", loc); - - g_system_thread_assign (info->owner, zero_thread); - loc = info->location; - - g_thread_functions_for_glib_use_default.cond_wait (cond, mutex); - - g_system_thread_assign (info->owner, self); - info->location = loc; -} - - -static gboolean -g_cond_timed_wait_errorcheck_impl (GCond *cond, - GMutex *mutex, - GTimeVal *end_time, - const gulong magic, - gchar * const location) -{ - GMutexDebugInfo *info = G_MUTEX_DEBUG_INFO (mutex); - gchar *loc = (magic == G_MUTEX_DEBUG_MAGIC) ? location : "unknown"; - gboolean retval; - - GSystemThread self; - g_thread_functions_for_glib_use.thread_self (&self); - - if (g_system_thread_equal (info->owner, zero_thread)) - g_error ("Trying to use an unlocked mutex in g_cond_timed_wait() at '%s'", - loc); - - if (!g_system_thread_equal (info->owner, self)) - g_error ("Trying to use a mutex locked by another thread in " - "g_cond_timed_wait() at '%s'", loc); - - g_system_thread_assign (info->owner, zero_thread); - loc = info->location; - - retval = g_thread_functions_for_glib_use_default.cond_timed_wait (cond, - mutex, - end_time); - - g_system_thread_assign (info->owner, self); - info->location = loc; - - return retval; -} - - -/* unshadow function declaration. See gthread.h */ -#undef g_thread_init - -void -g_thread_init_with_errorcheck_mutexes (GThreadFunctions* init) -{ - GThreadFunctions errorcheck_functions; - if (init) - g_error ("Errorcheck mutexes can only be used for native " - "thread implementations. Sorry." ); - -#ifdef HAVE_G_THREAD_IMPL_INIT - /* This isn't called in g_thread_init, as it doesn't think to get - * the default implementation, so we have to call it on our own. - * - * We must call this before copying - * g_thread_functions_for_glib_use_default as the - * implementation-specific init function might modify the contents - * of g_thread_functions_for_glib_use_default based on operating - * system version, C library version, or whatever. */ - g_thread_impl_init(); -#endif /* HAVE_G_THREAD_IMPL_INIT */ - - errorcheck_functions = g_thread_functions_for_glib_use_default; - errorcheck_functions.mutex_new = g_mutex_new_errorcheck_impl; - errorcheck_functions.mutex_lock = - (void (*)(GMutex *)) g_mutex_lock_errorcheck_impl; - errorcheck_functions.mutex_trylock = - (gboolean (*)(GMutex *)) g_mutex_trylock_errorcheck_impl; - errorcheck_functions.mutex_unlock = - (void (*)(GMutex *)) g_mutex_unlock_errorcheck_impl; - errorcheck_functions.mutex_free = - (void (*)(GMutex *)) g_mutex_free_errorcheck_impl; - errorcheck_functions.cond_wait = - (void (*)(GCond *, GMutex *)) g_cond_wait_errorcheck_impl; - errorcheck_functions.cond_timed_wait = - (gboolean (*)(GCond *, GMutex *, GTimeVal *)) - g_cond_timed_wait_errorcheck_impl; - - g_thread_init (&errorcheck_functions); -} - -void -g_thread_init (GThreadFunctions* init) -{ - gboolean supported; - - if (thread_system_already_initialized) - g_error ("GThread system may only be initialized once."); - - thread_system_already_initialized = TRUE; - - if (init == NULL) - { -#ifdef HAVE_G_THREAD_IMPL_INIT - /* now do any initialization stuff required by the - * implementation, but only if called with a NULL argument, of - * course. Otherwise it's up to the user to do so. */ - g_thread_impl_init(); -#endif /* HAVE_G_THREAD_IMPL_INIT */ - init = &g_thread_functions_for_glib_use_default; - } - else - g_thread_use_default_impl = FALSE; - - g_thread_functions_for_glib_use = *init; - if (g_thread_gettime_impl) - g_thread_gettime = g_thread_gettime_impl; - - supported = (init->mutex_new && - init->mutex_lock && - init->mutex_trylock && - init->mutex_unlock && - init->mutex_free && - init->cond_new && - init->cond_signal && - init->cond_broadcast && - init->cond_wait && - init->cond_timed_wait && - init->cond_free && - init->private_new && - init->private_get && - init->private_set && - init->thread_create && - init->thread_yield && - init->thread_join && - init->thread_exit && - init->thread_set_priority && - init->thread_self); - - /* if somebody is calling g_thread_init (), it means that he wants to - * have thread support, so check this - */ - if (!supported) - { - if (g_thread_use_default_impl) - g_error ("Threads are not supported on this platform."); - else - g_error ("The supplied thread function vector is invalid."); - } - - g_thread_priority_map [G_THREAD_PRIORITY_LOW] = PRIORITY_LOW_VALUE; - g_thread_priority_map [G_THREAD_PRIORITY_NORMAL] = PRIORITY_NORMAL_VALUE; - g_thread_priority_map [G_THREAD_PRIORITY_HIGH] = PRIORITY_HIGH_VALUE; - g_thread_priority_map [G_THREAD_PRIORITY_URGENT] = PRIORITY_URGENT_VALUE; - - g_thread_init_glib (); -} - -#else /* !G_THREADS_ENABLED */ - -void -g_thread_init (GThreadFunctions* init) -{ - g_error ("GLib thread support is disabled."); -} - -void -g_thread_init_with_errorcheck_mutexes (GThreadFunctions* init) -{ - g_error ("GLib thread support is disabled."); -} - -#endif /* !G_THREADS_ENABLED */ diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gthread/gthread-none.c b/desmume/src/windows/glib-2.20.1/build/glib/gthread/gthread-none.c deleted file mode 100644 index 6fbeff160..000000000 --- a/desmume/src/windows/glib-2.20.1/build/glib/gthread/gthread-none.c +++ /dev/null @@ -1,39 +0,0 @@ -/* GLIB - Library of useful routines for C programming - * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald - * - * gthread.c: fallback thread system implementation - * Copyright 1998 Sebastian Wilhelmi; University of Karlsruhe - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the - * Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -/* - * Modified by the GLib Team and others 1997-2000. See the AUTHORS - * file for a list of people on the GLib Team. See the ChangeLog - * files for a list of changes. These files are distributed with - * GLib at ftp://ftp.gtk.org/pub/gtk/. - */ - -/* - * MT safe - */ - -static GThreadFunctions -g_thread_functions_for_glib_use_default; /* is NULLified */ - -static guint64 (*g_thread_gettime_impl) (void) = NULL; - -#define G_MUTEX_SIZE 0 diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gthread/gthread-posix.c b/desmume/src/windows/glib-2.20.1/build/glib/gthread/gthread-posix.c deleted file mode 100644 index 9188f843e..000000000 --- a/desmume/src/windows/glib-2.20.1/build/glib/gthread/gthread-posix.c +++ /dev/null @@ -1,467 +0,0 @@ -/* GLIB - Library of useful routines for C programming - * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald - * - * gthread.c: posix thread system implementation - * Copyright 1998 Sebastian Wilhelmi; University of Karlsruhe - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the - * Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -/* - * Modified by the GLib Team and others 1997-2000. See the AUTHORS - * file for a list of people on the GLib Team. See the ChangeLog - * files for a list of changes. These files are distributed with - * GLib at ftp://ftp.gtk.org/pub/gtk/. - */ - -/* - * MT safe - */ - -#include "config.h" - -#include -#include -#include -#ifdef HAVE_SYS_TIME_H -# include -#endif -#ifdef HAVE_UNISTD_H -# include -#endif - -#ifdef HAVE_SCHED_H -#include -#endif - -#define posix_check_err(err, name) G_STMT_START{ \ - int error = (err); \ - if (error) \ - g_error ("file %s: line %d (%s): error '%s' during '%s'", \ - __FILE__, __LINE__, G_STRFUNC, \ - g_strerror (error), name); \ - }G_STMT_END - -#define posix_check_cmd(cmd) posix_check_err (posix_error (cmd), #cmd) - -#ifdef G_ENABLE_DEBUG -static gboolean posix_check_cmd_prio_warned = FALSE; -# define posix_check_cmd_prio(cmd) G_STMT_START{ \ - int err = posix_error (cmd); \ - if (err == EPERM) \ - { \ - if (!posix_check_cmd_prio_warned) \ - { \ - posix_check_cmd_prio_warned = TRUE; \ - g_warning ("Priorities can only be changed " \ - "(resp. increased) by root."); \ - } \ - } \ - else \ - posix_check_err (err, #cmd); \ - }G_STMT_END -#else /* G_ENABLE_DEBUG */ -# define posix_check_cmd_prio(cmd) G_STMT_START{ \ - int err = posix_error (cmd); \ - if (err != EPERM) \ - posix_check_err (err, #cmd); \ - }G_STMT_END -#endif /* G_ENABLE_DEBUG */ - -#if defined(G_THREADS_IMPL_POSIX) -# define posix_error(what) (what) -# define mutexattr_default NULL -# define condattr_default NULL -#elif defined(G_THREADS_IMPL_DCE) -# define posix_error(what) ((what) == -1 ? errno : 0) -# define pthread_key_create(a, b) pthread_keycreate (a, b) -# define pthread_attr_init(a) pthread_attr_create (a) -# define pthread_attr_destroy(a) pthread_attr_delete (a) -# define pthread_create(a, b, c, d) pthread_create (a, *b, c, d) -# define mutexattr_default (pthread_mutexattr_default) -# define condattr_default (pthread_condattr_default) -#else /* neither G_THREADS_IMPL_POSIX nor G_THREADS_IMPL_DCE are defined */ -# error This should not happen. Contact the GLib team. -#endif - -#if defined (POSIX_MIN_PRIORITY) && defined (POSIX_MAX_PRIORITY) -# define HAVE_PRIORITIES 1 -static gint priority_normal_value; -# ifdef __FreeBSD__ - /* FreeBSD threads use different priority values from the POSIX_ - * defines so we just set them here. The corresponding macros - * PTHREAD_MIN_PRIORITY and PTHREAD_MAX_PRIORITY are implied to be - * exported by the docs, but they aren't. - */ -# define PRIORITY_LOW_VALUE 0 -# define PRIORITY_URGENT_VALUE 31 -# else /* !__FreeBSD__ */ -# define PRIORITY_LOW_VALUE POSIX_MIN_PRIORITY -# define PRIORITY_URGENT_VALUE POSIX_MAX_PRIORITY -# endif /* !__FreeBSD__ */ -# define PRIORITY_NORMAL_VALUE priority_normal_value -#endif /* POSIX_MIN_PRIORITY && POSIX_MAX_PRIORITY */ - -static gulong g_thread_min_stack_size = 0; - -#define G_MUTEX_SIZE (sizeof (pthread_mutex_t)) - -#if defined(HAVE_CLOCK_GETTIME) && defined(HAVE_MONOTONIC_CLOCK) -#define USE_CLOCK_GETTIME 1 -static gint posix_clock = 0; -#endif - -#if defined(_SC_THREAD_STACK_MIN) || defined (HAVE_PRIORITIES) || defined (USE_CLOCK_GETTIME) -#define HAVE_G_THREAD_IMPL_INIT -static void -g_thread_impl_init(void) -{ -#ifdef _SC_THREAD_STACK_MIN - g_thread_min_stack_size = MAX (sysconf (_SC_THREAD_STACK_MIN), 0); -#endif /* _SC_THREAD_STACK_MIN */ -#ifdef HAVE_PRIORITIES -# ifdef G_THREADS_IMPL_POSIX - { - struct sched_param sched; - int policy; - posix_check_cmd (pthread_getschedparam (pthread_self(), &policy, &sched)); - priority_normal_value = sched.sched_priority; - } -# else /* G_THREADS_IMPL_DCE */ - posix_check_cmd (priority_normal_value = - pthread_getprio (*(pthread_t*)thread, - g_thread_priority_map [priority])); -# endif -#endif /* HAVE_PRIORITIES */ - -#ifdef USE_CLOCK_GETTIME - if (sysconf (_SC_MONOTONIC_CLOCK) >= 0) - posix_clock = CLOCK_MONOTONIC; - else - posix_clock = CLOCK_REALTIME; -#endif -} -#endif /* _SC_THREAD_STACK_MIN || HAVE_PRIORITIES */ - -static GMutex * -g_mutex_new_posix_impl (void) -{ - GMutex *result = (GMutex *) g_new (pthread_mutex_t, 1); - posix_check_cmd (pthread_mutex_init ((pthread_mutex_t *) result, - mutexattr_default)); - return result; -} - -static void -g_mutex_free_posix_impl (GMutex * mutex) -{ - posix_check_cmd (pthread_mutex_destroy ((pthread_mutex_t *) mutex)); - g_free (mutex); -} - -/* NOTE: the functions g_mutex_lock and g_mutex_unlock may not use - functions from gmem.c and gmessages.c; */ - -/* pthread_mutex_lock, pthread_mutex_unlock can be taken directly, as - signature and semantic are right, but without error check then!!!!, - we might want to change this therefore. */ - -static gboolean -g_mutex_trylock_posix_impl (GMutex * mutex) -{ - int result; - - result = pthread_mutex_trylock ((pthread_mutex_t *) mutex); - -#ifdef G_THREADS_IMPL_POSIX - if (result == EBUSY) - return FALSE; -#else /* G_THREADS_IMPL_DCE */ - if (result == 0) - return FALSE; -#endif - - posix_check_err (posix_error (result), "pthread_mutex_trylock"); - return TRUE; -} - -static GCond * -g_cond_new_posix_impl (void) -{ - GCond *result = (GCond *) g_new (pthread_cond_t, 1); - posix_check_cmd (pthread_cond_init ((pthread_cond_t *) result, - condattr_default)); - return result; -} - -/* pthread_cond_signal, pthread_cond_broadcast and pthread_cond_wait - can be taken directly, as signature and semantic are right, but - without error check then!!!!, we might want to change this - therefore. */ - -#define G_NSEC_PER_SEC 1000000000 - -static gboolean -g_cond_timed_wait_posix_impl (GCond * cond, - GMutex * entered_mutex, - GTimeVal * abs_time) -{ - int result; - struct timespec end_time; - gboolean timed_out; - - g_return_val_if_fail (cond != NULL, FALSE); - g_return_val_if_fail (entered_mutex != NULL, FALSE); - - if (!abs_time) - { - result = pthread_cond_wait ((pthread_cond_t *)cond, - (pthread_mutex_t *) entered_mutex); - timed_out = FALSE; - } - else - { - end_time.tv_sec = abs_time->tv_sec; - end_time.tv_nsec = abs_time->tv_usec * (G_NSEC_PER_SEC / G_USEC_PER_SEC); - - g_return_val_if_fail (end_time.tv_nsec < G_NSEC_PER_SEC, TRUE); - - result = pthread_cond_timedwait ((pthread_cond_t *) cond, - (pthread_mutex_t *) entered_mutex, - &end_time); -#ifdef G_THREADS_IMPL_POSIX - timed_out = (result == ETIMEDOUT); -#else /* G_THREADS_IMPL_DCE */ - timed_out = (result == -1) && (errno == EAGAIN); -#endif - } - - if (!timed_out) - posix_check_err (posix_error (result), "pthread_cond_timedwait"); - - return !timed_out; -} - -static void -g_cond_free_posix_impl (GCond * cond) -{ - posix_check_cmd (pthread_cond_destroy ((pthread_cond_t *) cond)); - g_free (cond); -} - -static GPrivate * -g_private_new_posix_impl (GDestroyNotify destructor) -{ - GPrivate *result = (GPrivate *) g_new (pthread_key_t, 1); - posix_check_cmd (pthread_key_create ((pthread_key_t *) result, destructor)); - return result; -} - -/* NOTE: the functions g_private_get and g_private_set may not use - functions from gmem.c and gmessages.c */ - -static void -g_private_set_posix_impl (GPrivate * private_key, gpointer value) -{ - if (!private_key) - return; - pthread_setspecific (*(pthread_key_t *) private_key, value); -} - -static gpointer -g_private_get_posix_impl (GPrivate * private_key) -{ - if (!private_key) - return NULL; -#ifdef G_THREADS_IMPL_POSIX - return pthread_getspecific (*(pthread_key_t *) private_key); -#else /* G_THREADS_IMPL_DCE */ - { - void* data; - posix_check_cmd (pthread_getspecific (*(pthread_key_t *) private_key, - &data)); - return data; - } -#endif -} - -static void -g_thread_create_posix_impl (GThreadFunc thread_func, - gpointer arg, - gulong stack_size, - gboolean joinable, - gboolean bound, - GThreadPriority priority, - gpointer thread, - GError **error) -{ - pthread_attr_t attr; - gint ret; - - g_return_if_fail (thread_func); - g_return_if_fail (priority >= G_THREAD_PRIORITY_LOW); - g_return_if_fail (priority <= G_THREAD_PRIORITY_URGENT); - - posix_check_cmd (pthread_attr_init (&attr)); - -#ifdef HAVE_PTHREAD_ATTR_SETSTACKSIZE - if (stack_size) - { - stack_size = MAX (g_thread_min_stack_size, stack_size); - /* No error check here, because some systems can't do it and - * we simply don't want threads to fail because of that. */ - pthread_attr_setstacksize (&attr, stack_size); - } -#endif /* HAVE_PTHREAD_ATTR_SETSTACKSIZE */ - -#ifdef PTHREAD_SCOPE_SYSTEM - if (bound) - /* No error check here, because some systems can't do it and we - * simply don't want threads to fail because of that. */ - pthread_attr_setscope (&attr, PTHREAD_SCOPE_SYSTEM); -#endif /* PTHREAD_SCOPE_SYSTEM */ - -#ifdef G_THREADS_IMPL_POSIX - posix_check_cmd (pthread_attr_setdetachstate (&attr, - joinable ? PTHREAD_CREATE_JOINABLE : PTHREAD_CREATE_DETACHED)); -#endif /* G_THREADS_IMPL_POSIX */ - -#ifdef HAVE_PRIORITIES -# ifdef G_THREADS_IMPL_POSIX - { - struct sched_param sched; - posix_check_cmd (pthread_attr_getschedparam (&attr, &sched)); - sched.sched_priority = g_thread_priority_map [priority]; - posix_check_cmd_prio (pthread_attr_setschedparam (&attr, &sched)); - } -# else /* G_THREADS_IMPL_DCE */ - posix_check_cmd_prio - (pthread_attr_setprio (&attr, g_thread_priority_map [priority])); -# endif /* G_THREADS_IMPL_DCE */ -#endif /* HAVE_PRIORITIES */ - ret = posix_error (pthread_create (thread, &attr, - (void* (*)(void*))thread_func, arg)); - - posix_check_cmd (pthread_attr_destroy (&attr)); - - if (ret == EAGAIN) - { - g_set_error (error, G_THREAD_ERROR, G_THREAD_ERROR_AGAIN, - "Error creating thread: %s", g_strerror (ret)); - return; - } - - posix_check_err (ret, "pthread_create"); - -#ifdef G_THREADS_IMPL_DCE - if (!joinable) - posix_check_cmd (pthread_detach (thread)); -#endif /* G_THREADS_IMPL_DCE */ -} - -static void -g_thread_yield_posix_impl (void) -{ - POSIX_YIELD_FUNC; -} - -static void -g_thread_join_posix_impl (gpointer thread) -{ - gpointer ignore; - posix_check_cmd (pthread_join (*(pthread_t*)thread, &ignore)); -} - -static void -g_thread_exit_posix_impl (void) -{ - pthread_exit (NULL); -} - -static void -g_thread_set_priority_posix_impl (gpointer thread, GThreadPriority priority) -{ - g_return_if_fail (priority >= G_THREAD_PRIORITY_LOW); - g_return_if_fail (priority <= G_THREAD_PRIORITY_URGENT); -#ifdef HAVE_PRIORITIES -# ifdef G_THREADS_IMPL_POSIX - { - struct sched_param sched; - int policy; - posix_check_cmd (pthread_getschedparam (*(pthread_t*)thread, &policy, - &sched)); - sched.sched_priority = g_thread_priority_map [priority]; - posix_check_cmd_prio (pthread_setschedparam (*(pthread_t*)thread, policy, - &sched)); - } -# else /* G_THREADS_IMPL_DCE */ - posix_check_cmd_prio (pthread_setprio (*(pthread_t*)thread, - g_thread_priority_map [priority])); -# endif -#endif /* HAVE_PRIORITIES */ -} - -static void -g_thread_self_posix_impl (gpointer thread) -{ - *(pthread_t*)thread = pthread_self(); -} - -static gboolean -g_thread_equal_posix_impl (gpointer thread1, gpointer thread2) -{ - return (pthread_equal (*(pthread_t*)thread1, *(pthread_t*)thread2) != 0); -} - -#ifdef USE_CLOCK_GETTIME -static guint64 -gettime (void) -{ - struct timespec tv; - - clock_gettime (posix_clock, &tv); - - return (guint64) tv.tv_sec * G_NSEC_PER_SEC + tv.tv_nsec; -} -static guint64 (*g_thread_gettime_impl)(void) = gettime; -#else -static guint64 (*g_thread_gettime_impl)(void) = 0; -#endif - -static GThreadFunctions g_thread_functions_for_glib_use_default = -{ - g_mutex_new_posix_impl, - (void (*)(GMutex *)) pthread_mutex_lock, - g_mutex_trylock_posix_impl, - (void (*)(GMutex *)) pthread_mutex_unlock, - g_mutex_free_posix_impl, - g_cond_new_posix_impl, - (void (*)(GCond *)) pthread_cond_signal, - (void (*)(GCond *)) pthread_cond_broadcast, - (void (*)(GCond *, GMutex *)) pthread_cond_wait, - g_cond_timed_wait_posix_impl, - g_cond_free_posix_impl, - g_private_new_posix_impl, - g_private_get_posix_impl, - g_private_set_posix_impl, - g_thread_create_posix_impl, - g_thread_yield_posix_impl, - g_thread_join_posix_impl, - g_thread_exit_posix_impl, - g_thread_set_priority_posix_impl, - g_thread_self_posix_impl, - g_thread_equal_posix_impl -}; diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gthread/gthread-win32.c b/desmume/src/windows/glib-2.20.1/build/glib/gthread/gthread-win32.c deleted file mode 100644 index 465b20550..000000000 --- a/desmume/src/windows/glib-2.20.1/build/glib/gthread/gthread-win32.c +++ /dev/null @@ -1,639 +0,0 @@ -/* GLIB - Library of useful routines for C programming - * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald - * - * gthread.c: solaris thread system implementation - * Copyright 1998-2001 Sebastian Wilhelmi; University of Karlsruhe - * Copyright 2001 Hans Breuer - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the - * Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -/* - * Modified by the GLib Team and others 1997-2000. See the AUTHORS - * file for a list of people on the GLib Team. See the ChangeLog - * files for a list of changes. These files are distributed with - * GLib at ftp://ftp.gtk.org/pub/gtk/. - */ - -/* - * MT safe - */ - -#include "config.h" - -#include "glib.h" - -#define STRICT -#define _WIN32_WINDOWS 0x0401 /* to get IsDebuggerPresent */ -#include -#undef STRICT - -#include -#include -#include - -#define win32_check_for_error(what) G_STMT_START{ \ - if (!(what)) \ - g_error ("file %s: line %d (%s): error %s during %s", \ - __FILE__, __LINE__, G_STRFUNC, \ - g_win32_error_message (GetLastError ()), #what); \ - }G_STMT_END - -#define G_MUTEX_SIZE (sizeof (gpointer)) - -#define PRIORITY_LOW_VALUE THREAD_PRIORITY_BELOW_NORMAL -#define PRIORITY_NORMAL_VALUE THREAD_PRIORITY_NORMAL -#define PRIORITY_HIGH_VALUE THREAD_PRIORITY_ABOVE_NORMAL -#define PRIORITY_URGENT_VALUE THREAD_PRIORITY_HIGHEST - -static DWORD g_thread_self_tls; -static DWORD g_private_tls; -static DWORD g_cond_event_tls; -static CRITICAL_SECTION g_thread_global_spinlock; - -typedef BOOL (__stdcall *GTryEnterCriticalSectionFunc) (CRITICAL_SECTION *); - -static GTryEnterCriticalSectionFunc try_enter_critical_section = NULL; - -/* As noted in the docs, GPrivate is a limited resource, here we take - * a rather low maximum to save memory, use GStaticPrivate instead. */ -#define G_PRIVATE_MAX 100 - -static GDestroyNotify g_private_destructors[G_PRIVATE_MAX]; - -static guint g_private_next = 0; - -/* A "forward" declaration of this structure */ -static GThreadFunctions g_thread_functions_for_glib_use_default; - -typedef struct _GThreadData GThreadData; -struct _GThreadData -{ - GThreadFunc func; - gpointer data; - HANDLE thread; - gboolean joinable; -}; - -struct _GCond -{ - GPtrArray *array; - CRITICAL_SECTION lock; -}; - -static GMutex * -g_mutex_new_win32_cs_impl (void) -{ - CRITICAL_SECTION *cs = g_new (CRITICAL_SECTION, 1); - gpointer *retval = g_new (gpointer, 1); - - InitializeCriticalSection (cs); - *retval = cs; - return (GMutex *) retval; -} - -static void -g_mutex_free_win32_cs_impl (GMutex *mutex) -{ - gpointer *ptr = (gpointer *) mutex; - CRITICAL_SECTION *cs = (CRITICAL_SECTION *) *ptr; - - DeleteCriticalSection (cs); - g_free (cs); - g_free (mutex); -} - -/* NOTE: the functions g_mutex_lock and g_mutex_unlock may not use - functions from gmem.c and gmessages.c; */ - -static void -g_mutex_lock_win32_cs_impl (GMutex *mutex) -{ - EnterCriticalSection (*(CRITICAL_SECTION **)mutex); -} - -static gboolean -g_mutex_trylock_win32_cs_impl (GMutex * mutex) -{ - return try_enter_critical_section (*(CRITICAL_SECTION **)mutex); -} - -static void -g_mutex_unlock_win32_cs_impl (GMutex *mutex) -{ - LeaveCriticalSection (*(CRITICAL_SECTION **)mutex); -} - -static GMutex * -g_mutex_new_win32_impl (void) -{ - HANDLE handle; - HANDLE *retval; - win32_check_for_error (handle = CreateMutex (NULL, FALSE, NULL)); - retval = g_new (HANDLE, 1); - *retval = handle; - return (GMutex *) retval; -} - -static void -g_mutex_free_win32_impl (GMutex *mutex) -{ - win32_check_for_error (CloseHandle (*(HANDLE *) mutex)); - g_free (mutex); -} - -/* NOTE: the functions g_mutex_lock and g_mutex_unlock may not use - functions from gmem.c and gmessages.c; */ - -static void -g_mutex_lock_win32_impl (GMutex *mutex) -{ - WaitForSingleObject (*(HANDLE *) mutex, INFINITE); -} - -static gboolean -g_mutex_trylock_win32_impl (GMutex * mutex) -{ - DWORD result; - win32_check_for_error (WAIT_FAILED != - (result = WaitForSingleObject (*(HANDLE *)mutex, 0))); - return result != WAIT_TIMEOUT; -} - -static void -g_mutex_unlock_win32_impl (GMutex *mutex) -{ - ReleaseMutex (*(HANDLE *) mutex); -} - -static GCond * -g_cond_new_win32_impl (void) -{ - GCond *retval = g_new (GCond, 1); - - retval->array = g_ptr_array_new (); - InitializeCriticalSection (&retval->lock); - - return retval; -} - -static void -g_cond_signal_win32_impl (GCond * cond) -{ - EnterCriticalSection (&cond->lock); - - if (cond->array->len > 0) - { - SetEvent (g_ptr_array_index (cond->array, 0)); - g_ptr_array_remove_index (cond->array, 0); - } - - LeaveCriticalSection (&cond->lock); -} - -static void -g_cond_broadcast_win32_impl (GCond * cond) -{ - guint i; - EnterCriticalSection (&cond->lock); - - for (i = 0; i < cond->array->len; i++) - SetEvent (g_ptr_array_index (cond->array, i)); - - g_ptr_array_set_size (cond->array, 0); - LeaveCriticalSection (&cond->lock); -} - -static gboolean -g_cond_wait_internal (GCond *cond, - GMutex *entered_mutex, - gulong milliseconds) -{ - gulong retval; - HANDLE event = TlsGetValue (g_cond_event_tls); - - if (!event) - { - win32_check_for_error (event = CreateEvent (0, FALSE, FALSE, NULL)); - TlsSetValue (g_cond_event_tls, event); - } - - EnterCriticalSection (&cond->lock); - - /* The event must not be signaled. Check this */ - g_assert (WaitForSingleObject (event, 0) == WAIT_TIMEOUT); - - g_ptr_array_add (cond->array, event); - LeaveCriticalSection (&cond->lock); - - g_thread_functions_for_glib_use_default.mutex_unlock (entered_mutex); - - win32_check_for_error (WAIT_FAILED != - (retval = WaitForSingleObject (event, milliseconds))); - - g_thread_functions_for_glib_use_default.mutex_lock (entered_mutex); - - if (retval == WAIT_TIMEOUT) - { - EnterCriticalSection (&cond->lock); - g_ptr_array_remove (cond->array, event); - - /* In the meantime we could have been signaled, so we must again - * wait for the signal, this time with no timeout, to reset - * it. retval is set again to honour the late arrival of the - * signal */ - win32_check_for_error (WAIT_FAILED != - (retval = WaitForSingleObject (event, 0))); - - LeaveCriticalSection (&cond->lock); - } - -#ifndef G_DISABLE_ASSERT - EnterCriticalSection (&cond->lock); - - /* Now event must not be inside the array, check this */ - g_assert (g_ptr_array_remove (cond->array, event) == FALSE); - - LeaveCriticalSection (&cond->lock); -#endif /* !G_DISABLE_ASSERT */ - - return retval != WAIT_TIMEOUT; -} - -static void -g_cond_wait_win32_impl (GCond *cond, - GMutex *entered_mutex) -{ - g_return_if_fail (cond != NULL); - g_return_if_fail (entered_mutex != NULL); - - g_cond_wait_internal (cond, entered_mutex, INFINITE); -} - -static gboolean -g_cond_timed_wait_win32_impl (GCond *cond, - GMutex *entered_mutex, - GTimeVal *abs_time) -{ - GTimeVal current_time; - gulong to_wait; - - g_return_val_if_fail (cond != NULL, FALSE); - g_return_val_if_fail (entered_mutex != NULL, FALSE); - - if (!abs_time) - to_wait = INFINITE; - else - { - g_get_current_time (¤t_time); - if (abs_time->tv_sec < current_time.tv_sec || - (abs_time->tv_sec == current_time.tv_sec && - abs_time->tv_usec <= current_time.tv_usec)) - to_wait = 0; - else - to_wait = (abs_time->tv_sec - current_time.tv_sec) * 1000 + - (abs_time->tv_usec - current_time.tv_usec) / 1000; - } - - return g_cond_wait_internal (cond, entered_mutex, to_wait); -} - -static void -g_cond_free_win32_impl (GCond * cond) -{ - DeleteCriticalSection (&cond->lock); - g_ptr_array_free (cond->array, TRUE); - g_free (cond); -} - -static GPrivate * -g_private_new_win32_impl (GDestroyNotify destructor) -{ - GPrivate *result; - EnterCriticalSection (&g_thread_global_spinlock); - if (g_private_next >= G_PRIVATE_MAX) - { - char buf[100]; - sprintf (buf, - "Too many GPrivate allocated. Their number is limited to %d.", - G_PRIVATE_MAX); - MessageBox (NULL, buf, NULL, MB_ICONERROR|MB_SETFOREGROUND); - if (IsDebuggerPresent ()) - G_BREAKPOINT (); - abort (); - } - g_private_destructors[g_private_next] = destructor; - result = GUINT_TO_POINTER (g_private_next); - g_private_next++; - LeaveCriticalSection (&g_thread_global_spinlock); - - return result; -} - -/* NOTE: the functions g_private_get and g_private_set may not use - functions from gmem.c and gmessages.c */ - -static void -g_private_set_win32_impl (GPrivate * private_key, gpointer value) -{ - gpointer* array = TlsGetValue (g_private_tls); - guint index = GPOINTER_TO_UINT (private_key); - - if (index >= G_PRIVATE_MAX) - return; - - if (!array) - { - array = (gpointer*) calloc (G_PRIVATE_MAX, sizeof (gpointer)); - TlsSetValue (g_private_tls, array); - } - - array[index] = value; -} - -static gpointer -g_private_get_win32_impl (GPrivate * private_key) -{ - gpointer* array = TlsGetValue (g_private_tls); - guint index = GPOINTER_TO_UINT (private_key); - - if (index >= G_PRIVATE_MAX || !array) - return NULL; - - return array[index]; -} - -static void -g_thread_set_priority_win32_impl (gpointer thread, GThreadPriority priority) -{ - GThreadData *target = *(GThreadData **)thread; - - g_return_if_fail (priority >= G_THREAD_PRIORITY_LOW); - g_return_if_fail (priority <= G_THREAD_PRIORITY_URGENT); - - win32_check_for_error (SetThreadPriority (target->thread, - g_thread_priority_map [priority])); -} - -static void -g_thread_self_win32_impl (gpointer thread) -{ - GThreadData *self = TlsGetValue (g_thread_self_tls); - - if (!self) - { - /* This should only happen for the main thread! */ - HANDLE handle = GetCurrentThread (); - HANDLE process = GetCurrentProcess (); - self = g_new (GThreadData, 1); - win32_check_for_error (DuplicateHandle (process, handle, process, - &self->thread, 0, FALSE, - DUPLICATE_SAME_ACCESS)); - win32_check_for_error (TlsSetValue (g_thread_self_tls, self)); - self->func = NULL; - self->data = NULL; - self->joinable = FALSE; - } - - *(GThreadData **)thread = self; -} - -static void -g_thread_exit_win32_impl (void) -{ - GThreadData *self = TlsGetValue (g_thread_self_tls); - guint i, private_max; - gpointer *array = TlsGetValue (g_private_tls); - HANDLE event = TlsGetValue (g_cond_event_tls); - - EnterCriticalSection (&g_thread_global_spinlock); - private_max = g_private_next; - LeaveCriticalSection (&g_thread_global_spinlock); - - if (array) - { - gboolean some_data_non_null; - - do { - some_data_non_null = FALSE; - for (i = 0; i < private_max; i++) - { - GDestroyNotify destructor = g_private_destructors[i]; - GDestroyNotify data = array[i]; - - if (data) - some_data_non_null = TRUE; - - array[i] = NULL; - - if (destructor && data) - destructor (data); - } - } while (some_data_non_null); - - free (array); - - win32_check_for_error (TlsSetValue (g_private_tls, NULL)); - } - - if (self) - { - if (!self->joinable) - { - win32_check_for_error (CloseHandle (self->thread)); - g_free (self); - } - win32_check_for_error (TlsSetValue (g_thread_self_tls, NULL)); - } - - if (event) - { - CloseHandle (event); - win32_check_for_error (TlsSetValue (g_cond_event_tls, NULL)); - } - - _endthreadex (0); -} - -static guint __stdcall -g_thread_proxy (gpointer data) -{ - GThreadData *self = (GThreadData*) data; - - win32_check_for_error (TlsSetValue (g_thread_self_tls, self)); - - self->func (self->data); - - g_thread_exit_win32_impl (); - - g_assert_not_reached (); - - return 0; -} - -static void -g_thread_create_win32_impl (GThreadFunc func, - gpointer data, - gulong stack_size, - gboolean joinable, - gboolean bound, - GThreadPriority priority, - gpointer thread, - GError **error) -{ - guint ignore; - GThreadData *retval; - - g_return_if_fail (func); - g_return_if_fail (priority >= G_THREAD_PRIORITY_LOW); - g_return_if_fail (priority <= G_THREAD_PRIORITY_URGENT); - - retval = g_new(GThreadData, 1); - retval->func = func; - retval->data = data; - - retval->joinable = joinable; - - retval->thread = (HANDLE) _beginthreadex (NULL, stack_size, g_thread_proxy, - retval, 0, &ignore); - - if (retval->thread == NULL) - { - gchar *win_error = g_win32_error_message (GetLastError ()); - g_set_error (error, G_THREAD_ERROR, G_THREAD_ERROR_AGAIN, - "Error creating thread: %s", win_error); - g_free (retval); - g_free (win_error); - return; - } - - *(GThreadData **)thread = retval; - - g_thread_set_priority_win32_impl (thread, priority); -} - -static void -g_thread_yield_win32_impl (void) -{ - Sleep(0); -} - -static void -g_thread_join_win32_impl (gpointer thread) -{ - GThreadData *target = *(GThreadData **)thread; - - g_return_if_fail (target->joinable); - - win32_check_for_error (WAIT_FAILED != - WaitForSingleObject (target->thread, INFINITE)); - - win32_check_for_error (CloseHandle (target->thread)); - g_free (target); -} - -static guint64 -g_thread_gettime_impl (void) -{ - guint64 v; - - /* Returns 100s of nanoseconds since start of 1601 */ - GetSystemTimeAsFileTime ((FILETIME *)&v); - - /* Offset to Unix epoch */ - v -= G_GINT64_CONSTANT (116444736000000000); - /* Convert to nanoseconds */ - v *= 100; - - return v; -} - -static GThreadFunctions g_thread_functions_for_glib_use_default = -{ - g_mutex_new_win32_impl, /* mutex */ - g_mutex_lock_win32_impl, - g_mutex_trylock_win32_impl, - g_mutex_unlock_win32_impl, - g_mutex_free_win32_impl, - g_cond_new_win32_impl, /* condition */ - g_cond_signal_win32_impl, - g_cond_broadcast_win32_impl, - g_cond_wait_win32_impl, - g_cond_timed_wait_win32_impl, - g_cond_free_win32_impl, - g_private_new_win32_impl, /* private thread data */ - g_private_get_win32_impl, - g_private_set_win32_impl, - g_thread_create_win32_impl, /* thread */ - g_thread_yield_win32_impl, - g_thread_join_win32_impl, - g_thread_exit_win32_impl, - g_thread_set_priority_win32_impl, - g_thread_self_win32_impl, - NULL /* no equal function necessary */ -}; - -#define HAVE_G_THREAD_IMPL_INIT -static void -g_thread_impl_init () -{ - static gboolean beenhere = FALSE; - HMODULE kernel32; - - if (beenhere) - return; - - beenhere = TRUE; - - win32_check_for_error (TLS_OUT_OF_INDEXES != - (g_thread_self_tls = TlsAlloc ())); - win32_check_for_error (TLS_OUT_OF_INDEXES != - (g_private_tls = TlsAlloc ())); - win32_check_for_error (TLS_OUT_OF_INDEXES != - (g_cond_event_tls = TlsAlloc ())); - InitializeCriticalSection (&g_thread_global_spinlock); - - /* Here we are looking for TryEnterCriticalSection in KERNEL32.DLL, - * if it is found, we can use the in general faster critical - * sections instead of mutexes. See - * http://world.std.com/~jmhart/csmutx.htm for some discussion. - */ - kernel32 = GetModuleHandle ("KERNEL32.DLL"); - if (kernel32) - { - try_enter_critical_section = (GTryEnterCriticalSectionFunc) - GetProcAddress(kernel32, "TryEnterCriticalSection"); - - /* Even if TryEnterCriticalSection is found, it is not - * necessarily working..., we have to check it */ - if (try_enter_critical_section && - try_enter_critical_section (&g_thread_global_spinlock)) - { - LeaveCriticalSection (&g_thread_global_spinlock); - - g_thread_functions_for_glib_use_default.mutex_new = - g_mutex_new_win32_cs_impl; - g_thread_functions_for_glib_use_default.mutex_lock = - g_mutex_lock_win32_cs_impl; - g_thread_functions_for_glib_use_default.mutex_trylock = - g_mutex_trylock_win32_cs_impl; - g_thread_functions_for_glib_use_default.mutex_unlock = - g_mutex_unlock_win32_cs_impl; - g_thread_functions_for_glib_use_default.mutex_free = - g_mutex_free_win32_cs_impl; - } - } -} diff --git a/desmume/src/windows/glib-2.20.1/lib/glib-2.20.1-x86.lib b/desmume/src/windows/glib-2.20.1/lib/glib-2.20.1-x86.lib deleted file mode 100644 index e8ff5b00d9f73b9a5dd3bbf2c5d104b738a739b0..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1750574 zcmeFaON?b(nwS;HEoiFBWxLyts{n;ztw#?yj*K{w zdFn>QiH;MId2cfSEKA51Vqn1t227YC55Qv3LfC^ISO!@LA>_{K}%C`;#(ce7y)tifdKEMAWIr!Dz@893~&cUz# zqJID6@ZeW}Nq_(9%Y%b&e&4LY9~Kz+*0=wUgI|i@Pk!y-Ti^Wt`K`g<|0@UI`gwo< z`#(MS)-T!b+sRK3{y=}Lf8*fWe-OXF_jeDz{rmO%$A9VI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U_EXT; - -struct mapview_struct -{ - u32 autoup_secs; - bool autoup; - - u16 map; - u16 lcd; - u16 bitmap[1024*1024]; - bool clear; - - void render() - { - //we're going to make a copy of the gpu so that we don't wreck affine scroll params - //hopefully we won't mess up anything else - GPU *realGpu; - if(lcd) realGpu = SubScreen.gpu; - else realGpu = MainScreen.gpu; - GPU &gpu = *realGpu; - - //forgive the gyrations, some of this junk in here is to remind us of gyrations we might have to go - //through to avoid breaking the gpu struct - - gpu.currBgNum = map; - gpu.debug = true; - - for(u32 i = 0; i < gpu.BGSize[map][1]; ++i) - { - gpu.currDst = (u8 *)bitmap + i*gpu.BGSize[map][0]*2; - gpu.currLine = i; - gpu.modeRender(map); - } - gpu.debug = false; - - } -}; - -mapview_struct *MapView = NULL; - - -LRESULT MapView_OnPaint(mapview_struct * win, HWND hwnd, WPARAM wParam, LPARAM lParam) -{ - Lock lock; - - HDC hdc; - PAINTSTRUCT ps; - char text[80]; - u32 dispcnt = ((volatile u32 *)ARM9Mem.ARM9_REG)[(win->lcd*0x400)]; - u32 bgcnt = ((volatile u16 *)ARM9Mem.ARM9_REG)[(8 + (win->map<<1) + (win->lcd*0x1000))>>1]; - BITMAPV4HEADER bmi; - u16 lg; - u16 ht; - BGxPARMS * parms; - - //CreateBitmapIndirect(&bmi); - memset(&bmi, 0, sizeof(bmi)); - bmi.bV4Size = sizeof(bmi); - bmi.bV4Planes = 1; - bmi.bV4BitCount = 16; - bmi.bV4V4Compression = BI_RGB|BI_BITFIELDS; - bmi.bV4RedMask = 0x001F; - bmi.bV4GreenMask = 0x03E0; - bmi.bV4BlueMask = 0x7C00; - - if(win->lcd) - { - lg = SubScreen.gpu->BGSize[win->map][0]; - ht = SubScreen.gpu->BGSize[win->map][1]; - } - else - { - lg = MainScreen.gpu->BGSize[win->map][0]; - ht = MainScreen.gpu->BGSize[win->map][1]; - } - bmi.bV4Width = lg; - bmi.bV4Height = -ht; - - hdc = BeginPaint(hwnd, &ps); - - sprintf(text, "%d %08X, %08X", (int)(dispcnt&7), (int)dispcnt, (int)bgcnt); - SetWindowText(GetDlgItem(hwnd, IDC_MODE), text); - - if(!(bgcnt&(1<<7))) - sprintf(text, "normal 16"); - else - { - if(!(dispcnt&(1<<30))) - sprintf(text, "normal 256"); - else - { - switch(win->map) - { - case 0 : - sprintf(text, "extended slot %d", (bgcnt&(1<<13))?2:0); - break; - case 1 : - sprintf(text, "extended slot %d", (bgcnt&(1<<13))?3:1); - break; - default : - sprintf(text, "extended slot %d", MainScreen.gpu->BGExtPalSlot[win->map]); - break; - } - } - } - SetWindowText(GetDlgItem(hwnd, IDC_PAL), text); - - sprintf(text, "%d", (int)(bgcnt&3)); - SetWindowText(GetDlgItem(hwnd, IDC_PRIO), text); - - - if((dispcnt>>8>>win->map)&1) - SetWindowText(GetDlgItem(hwnd, IDC_VISIBLE), "true"); - else - SetWindowText(GetDlgItem(hwnd, IDC_VISIBLE), "false"); - - sprintf(text, "0x%08X", (int)(0x6000000 + ((bgcnt>>2)&0xF)*0x4000 + win->lcd*0x200000 +((dispcnt>>24)&7)*0x10000)); - SetWindowText(GetDlgItem(hwnd, IDC_CHAR), text); - - sprintf(text, "0x%08X", (int)(0x6000000 + 0x800*((bgcnt>>8)&0x1F) + win->lcd*0x200000 + ((dispcnt>>27)&7)*0x10000)); - SetWindowText(GetDlgItem(hwnd, IDC_SCR), text); - - //sprintf(text, "%d x %d", MainScreen.gpu->BGPA[win->map], MainScreen.gpu->BGPB[win->map]); - sprintf(text, "%d x %d", (int)MainScreen.gpu->BGSize[win->map][0], (int)MainScreen.gpu->BGSize[win->map][1]); - SetWindowText(GetDlgItem(hwnd, IDC_MSIZE), text); - - if (win->map==2) { - parms = &(MainScreen.gpu->dispx_st)->dispx_BG2PARMS; - } else { - parms = &(MainScreen.gpu->dispx_st)->dispx_BG3PARMS; - } - sprintf(text, "%d x %d", parms->BGxPC, parms->BGxPD); - SetWindowText(GetDlgItem(hwnd, IDC_SCROLL), text); - - for(int i = 0; i < ARRAY_SIZE(win->bitmap); i++) - win->bitmap[i] = 0x7C1F; - - win->render(); - - if(win->clear) - { - RECT r; - r.left = 200; - r.top = 4; - r.right = 200 + 1024; - r.bottom = 200 + 1024; - HBRUSH brush = CreateSolidBrush(GetSysColor(COLOR_3DFACE)); - FillRect(hdc, &r, brush); - DeleteObject(brush); - win->clear = false; - } - - SetDIBitsToDevice(hdc, 200, 4, lg, ht, 0, 0, 0, ht, win->bitmap, (BITMAPINFO*)&bmi, DIB_RGB_COLORS); - - EndPaint(hwnd, &ps); - - return 0; -} - -BOOL CALLBACK ViewMapsProc (HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam) -{ - //bail out early if the dialog isnt initialized - if(!MapView && message != WM_INITDIALOG) - return false; - - switch (message) - { - case WM_INITDIALOG : - { - MapView = new mapview_struct; - memset(MapView, 0, sizeof(MapView)); - MapView->clear = true; - MapView->autoup_secs = 1; - SendMessage(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SPIN), - UDM_SETRANGE, 0, MAKELONG(99, 1)); - SendMessage(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SPIN), - UDM_SETPOS32, 0, MapView->autoup_secs); - HWND combo = GetDlgItem(hwnd, IDC_BG_SELECT); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Main BackGround 0"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Main BackGround 1"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Main BackGround 2"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Main BackGround 3"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Sub BackGround 0"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Sub BackGround 1"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Sub BackGround 2"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Sub BackGround 3"); - SendMessage(combo, CB_SETCURSEL, 0, 0); - } - return 1; - case WM_CLOSE : - { - if(MapView->autoup) - { - KillTimer(hwnd, IDT_VIEW_MAP); - MapView->autoup = false; - } - if (MapView!=NULL) - { - delete MapView; - MapView = NULL; - } - //INFO("Close Map view dialog\n"); - PostQuitMessage(0); - return 0; - } - case WM_PAINT: - MapView_OnPaint(MapView, hwnd, wParam, lParam); - return 1; - case WM_TIMER: - SendMessage(hwnd, WM_COMMAND, IDC_REFRESH, 0); - return 1; - case WM_COMMAND : - switch (LOWORD (wParam)) - { - case IDC_FERMER : - SendMessage(hwnd, WM_CLOSE, 0, 0); - return 1; - case IDC_AUTO_UPDATE : - if(MapView->autoup) - { - EnableWindow(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SECS), false); - EnableWindow(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SPIN), false); - KillTimer(hwnd, IDT_VIEW_MAP); - MapView->autoup = FALSE; - return 1; - } - EnableWindow(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SECS), true); - EnableWindow(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SPIN), true); - MapView->autoup = TRUE; - SetTimer(hwnd, IDT_VIEW_MAP, MapView->autoup_secs*20, (TIMERPROC) NULL); - return 1; - case IDC_AUTO_UPDATE_SECS: - { - int t = GetDlgItemInt(hwnd, IDC_AUTO_UPDATE_SECS, FALSE, TRUE); - if (!MapView) - { - SendMessage(hwnd, WM_INITDIALOG, 0, 0); - } - if (t != MapView->autoup_secs) - { - MapView->autoup_secs = t; - if (MapView->autoup) - SetTimer(hwnd, IDT_VIEW_MAP, - MapView->autoup_secs*20, (TIMERPROC) NULL); - } - } - return 1; - case IDC_REFRESH: - InvalidateRect(hwnd, NULL, FALSE); - return 1; - case IDC_BG_SELECT : - switch(HIWORD(wParam)) - { - case CBN_SELCHANGE : - case CBN_CLOSEUP : - { - u32 sel= SendMessage(GetDlgItem(hwnd, IDC_BG_SELECT), CB_GETCURSEL, 0, 0); - switch(sel) - { - case 0 : - case 1 : - case 2 : - case 3 : - MapView->map = sel; - MapView->lcd = 0; - break; - case 4 : - case 5 : - case 6 : - case 7 : - MapView->map = sel-4; - MapView->lcd = 1; - break; - } - } - MapView->clear = true; - InvalidateRect(hwnd, NULL, FALSE); - return 1; - }//switch et case - }//switch - return 1; - } - return false; -} diff --git a/desmume/src/windows/pathsettings.cpp b/desmume/src/windows/pathsettings.cpp deleted file mode 100644 index be6250282..000000000 --- a/desmume/src/windows/pathsettings.cpp +++ /dev/null @@ -1,262 +0,0 @@ -/* - Copyright (C) 2007 Hicoder - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#include "common.h" -#include -#include -#include -#include -#include -#include "main.h" -#include "path.h" -#include "pathsettings.h" - -#define HANDLE_DLGMSG(hwnd, message, fn) \ - case (message): return (SetDlgMsgResult(hDlg, uMsg, \ - HANDLE_##message( (hwnd), (wParam), (lParam), (fn) ) ) ) - - -void WritePathSettings() -{ - WritePrivateProfileString(SECTION, ROMKEY, path.pathToRoms, IniName); - WritePrivateProfileString(SECTION, BATTERYKEY, path.pathToBattery, IniName); - WritePrivateProfileString(SECTION, STATEKEY, path.pathToStates, IniName); - WritePrivateProfileString(SECTION, SCREENSHOTKEY, path.pathToScreenshots, IniName); - WritePrivateProfileString(SECTION, AVIKEY, path.pathToAviFiles, IniName); - WritePrivateProfileString(SECTION, CHEATKEY, path.pathToCheats, IniName); - WritePrivateProfileString(SECTION, SOUNDKEY, path.pathToSounds, IniName); - WritePrivateProfileString(SECTION, FIRMWAREKEY, path.pathToFirmware, IniName); - WritePrivateProfileString(SECTION, LUAKEY, path.pathToLua, IniName); - - WritePrivateProfileString(SECTION, FORMATKEY, path.screenshotFormat, IniName); - - WritePrivateProfileInt(SECTION, LASTVISITKEY, path.savelastromvisit, IniName); -// WritePrivateProfileInt(SECTION, DEFAULTFORMATKEY, defaultFormat, IniName); -// WritePrivateProfileInt(SECTION, NEEDSSAVINGKEY, needsSaving, IniName); -} - -BOOL PathSettings_OnInitDialog(HWND hDlg, HWND hwndFocus, LPARAM lParam) -{ - HWND hwnd = GetDlgItem(hDlg, IDC_PATHLIST); -/* ComboBox_AddString(hwnd, ROMKEY); - ComboBox_AddString(hwnd, BATTERYKEY); - ComboBox_AddString(hwnd, STATEKEY); - ComboBox_AddString(hwnd, SCREENSHOTKEY); - ComboBox_AddString(hwnd, AVIKEY); - ComboBox_AddString(hwnd, CHEATKEY); - ComboBox_AddString(hwnd, SOUNDKEY); - ComboBox_AddString(hwnd, FIRMWAREKEY); - - ComboBox_SetCurSel(hwnd, 0);*/ -// PathSettings_OnSelChange(hDlg, NULL); - - CheckDlgButton(hDlg, IDC_USELASTVISIT, (path.savelastromvisit) ? BST_CHECKED : BST_UNCHECKED); - CheckRadioButton(hDlg, IDC_PNG, IDC_BMP, (int)path.imageformat()); - -// IDC_FORMATEDIT setup - SetDlgItemText(hDlg, IDC_FORMATEDIT, path.screenshotFormat); - - hwnd = GetDlgItem(hDlg, IDC_FORMATEDIT); - Edit_LimitText(hwnd, MAX_FORMAT); - - HWND toolTip = CreateWindowEx(NULL, - TOOLTIPS_CLASS, NULL, - TTS_ALWAYSTIP, - CW_USEDEFAULT, CW_USEDEFAULT, - CW_USEDEFAULT, CW_USEDEFAULT, - hDlg, NULL, - hAppInst, NULL); - SendMessage(toolTip, TTM_SETMAXTIPWIDTH, NULL, (LPARAM)330); - - SetWindowPos(toolTip, HWND_TOPMOST, 0,0,0,0, SWP_NOMOVE | SWP_NOSIZE | SWP_NOACTIVATE); - - SetDlgItemText(hDlg, IDC_ROMPATHEDIT, path.pathToRoms); - SetDlgItemText(hDlg, IDC_SAVERAMPATHEDIT, path.pathToBattery); - SetDlgItemText(hDlg, IDC_STATEPATHEDIT, path.pathToStates); - SetDlgItemText(hDlg, IDC_SCREENSHOTPATHEDIT, path.pathToScreenshots); - SetDlgItemText(hDlg, IDC_AVIPATHEDIT, path.pathToAviFiles); - SetDlgItemText(hDlg, IDC_CHEATPATHEDIT, path.pathToCheats); - SetDlgItemText(hDlg, IDC_LUAPATHEDIT, path.pathToLua); - - TOOLINFO ti; - ZeroMemory(&ti, sizeof(ti)); - ti.cbSize = sizeof(ti); - ti.hwnd = hDlg; - ti.hinst = hAppInst; - ti.uFlags = TTF_SUBCLASS | TTF_IDISHWND; - ti.uId = (UINT_PTR)hwnd; - ti.lpszText = "The format a screenshot should be saved in.\r\n%f\t\t\tFilename\r\n%D\t\t\tDay:Two Digit\r\n%M\t\t\tMonth:Two Digit\r\n%Y\t\t\tYear:Four Digit\r\n%h\t\t\tHour:Two Digit\r\n%m\t\t\tMinute: Two Digit\r\n%s\t\t\tSecond: Two Digit\r\n%r\t\tRandom: Min:0 Max:RAND_MAX"; - GetClientRect(hwnd, &ti.rect); - SendMessage(toolTip, TTM_ADDTOOL, NULL, (LPARAM)&ti); - - return TRUE; -} - -BOOL BrowseForPath(char *pathToBrowse) -{ - LPMALLOC shMalloc; - BOOL changed = false; - LPITEMIDLIST idList; - BROWSEINFO bi; - - //stupid shell - if(SHGetMalloc( &shMalloc) != S_OK) - return FALSE; - - ZeroMemory(&idList, sizeof(idList)); - ZeroMemory(&bi, sizeof(bi)); - - char tmp[MAX_PATH]; - strncpy(tmp, pathToBrowse, MAX_PATH); - - bi.hwndOwner = MainWindow->getHWnd(); - bi.lpszTitle = "Choose a Folder"; - bi.ulFlags = BIF_NONEWFOLDERBUTTON; - - /*wanted to add a callback function for the folder initialization but it crashes everytime i do - bi.lpfn = (BFFCALLBACK)InitialFolder; - bi.lParam = (LPARAM)pathToBrowse; - */ - - if( (idList = SHBrowseForFolder(&bi)) ) - { - changed = true; - SHGetPathFromIDList(idList, pathToBrowse); -// shMalloc->Free(&idList); - } - - return changed; -} - - -void PathSettings_OnCommand(HWND hDlg, int id, HWND hwndCtl, UINT codeNotify) -{ - switch(id) - { - case IDC_BROWSEROMS: - { - if(BrowseForPath(path.pathToRoms)) - SetDlgItemText(hDlg, IDC_ROMPATHEDIT, path.pathToRoms); - } - break; - case IDC_BROWSESRAM: - { - if(BrowseForPath(path.pathToBattery)) - SetDlgItemText(hDlg, IDC_SAVERAMPATHEDIT, path.pathToBattery); - } - break; - case IDC_BROWSESTATES: - { - if(BrowseForPath(path.pathToStates)) - SetDlgItemText(hDlg, IDC_STATEPATHEDIT, path.pathToStates); - } - break; - case IDC_BROWSESCREENSHOTS: - { - if(BrowseForPath(path.pathToScreenshots)) - SetDlgItemText(hDlg, IDC_SCREENSHOTPATHEDIT, path.pathToScreenshots); - } - break; - case IDC_BROWSEAVI: - { - if(BrowseForPath(path.pathToAviFiles)) - SetDlgItemText(hDlg, IDC_AVIPATHEDIT, path.pathToAviFiles); - } - break; - case IDC_BROWSECHEATS: - { - if(BrowseForPath(path.pathToCheats)) - SetDlgItemText(hDlg, IDC_CHEATPATHEDIT, path.pathToCheats); - } - break; - case IDC_BROWSELUA: - { - if(BrowseForPath(path.pathToLua)) - SetDlgItemText(hDlg, IDC_LUAPATHEDIT, path.pathToLua); - } - break; - case IDC_PATHDEFAULTS: - { - /* GetDefaultPath(currentSelection, currentKey, MAX_PATH); - SetDlgItemText(hDlg, IDC_PATHEDIT, currentSelection);*/ - } - break; - case IDC_PNG: - CheckRadioButton(hDlg, IDC_PNG, IDC_BMP, IDC_PNG); - path.currentimageformat = path.PNG; - break; - case IDC_BMP: - CheckRadioButton(hDlg, IDC_PNG, IDC_BMP, IDC_BMP); - path.currentimageformat = path.BMP; - break; - case IDC_USELASTVISIT: - { - path.savelastromvisit = !path.savelastromvisit; - CheckDlgButton(hDlg, IDC_USELASTVISIT, (path.savelastromvisit) ? BST_CHECKED : BST_UNCHECKED); - } - break; - case IDC_PATHLIST: - { - if(codeNotify == CBN_SELCHANGE) - { -// PathSettings_OnSelChange(hDlg, hwndCtl); - return; - } - } - break; - case IDC_FORMATEDIT: - { - if(codeNotify == EN_KILLFOCUS) - { - char buffer[MAX_FORMAT]; - GetDlgItemText(hDlg, IDC_FORMATEDIT, buffer, MAX_FORMAT); - strncpy(path.screenshotFormat, buffer, MAX_FORMAT); - } - } - break; - case IDOK: - - GetDlgItemText(hDlg, IDC_ROMPATHEDIT, path.pathToRoms, MAX_PATH); - GetDlgItemText(hDlg, IDC_SAVERAMPATHEDIT, path.pathToBattery, MAX_PATH); - GetDlgItemText(hDlg, IDC_STATEPATHEDIT, path.pathToStates, MAX_PATH); - GetDlgItemText(hDlg, IDC_SCREENSHOTPATHEDIT, path.pathToScreenshots, MAX_PATH); - GetDlgItemText(hDlg, IDC_AVIPATHEDIT, path.pathToAviFiles, MAX_PATH); - GetDlgItemText(hDlg, IDC_CHEATPATHEDIT, path.pathToCheats, MAX_PATH); - GetDlgItemText(hDlg, IDC_LUAPATHEDIT, path.pathToLua, MAX_PATH); - - WritePathSettings(); - EndDialog(hDlg, 0); - break; - case IDCANCEL: - path.ReadPathSettings(); - EndDialog(hDlg, 0); - break; - } -} - -LRESULT CALLBACK PathSettingsDlgProc(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam) -{ - switch(uMsg) - { - HANDLE_DLGMSG(hDlg, WM_INITDIALOG, PathSettings_OnInitDialog); - HANDLE_DLGMSG(hDlg, WM_COMMAND, PathSettings_OnCommand); - } - return FALSE; -} \ No newline at end of file diff --git a/desmume/src/windows/pathsettings.h b/desmume/src/windows/pathsettings.h deleted file mode 100644 index b3eb57fbf..000000000 --- a/desmume/src/windows/pathsettings.h +++ /dev/null @@ -1,29 +0,0 @@ -/* - Copyright (C) 2007 Hicoder - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#ifndef _PATHSETTINGS_H_ -#define _PATHSETTINGS_H_ - -void WritePathSettings(); -void ReadPathSettings(); - -LRESULT CALLBACK PathSettingsDlgProc(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam); - -#endif diff --git a/desmume/src/windows/snddx.cpp b/desmume/src/windows/snddx.cpp deleted file mode 100755 index adcae11b8..000000000 --- a/desmume/src/windows/snddx.cpp +++ /dev/null @@ -1,322 +0,0 @@ -/* snddx.cpp - - Copyright (C) 2005-2007 Theo Berkau - Copyright (C) 2008-2009 DeSmuME team - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -*/ - -#include -#include -#include "directx/dsound.h" -#ifdef __MINGW32__ -// I have to do this because for some reason because the dxerr8.h header is fubared -const char* __stdcall DXGetErrorString8A(HRESULT hr); -#define DXGetErrorString8 DXGetErrorString8A -const char* __stdcall DXGetErrorDescription8A(HRESULT hr); -#define DXGetErrorDescription8 DXGetErrorDescription8A -#else -#include "directx/dxerr8.h" -#endif -#include "SPU.h" -#include "snddx.h" -#include "CWindow.h" -#include "windriver.h" - -int SNDDXInit(int buffersize); -void SNDDXDeInit(); -void SNDDXUpdateAudio(s16 *buffer, u32 num_samples); -u32 SNDDXGetAudioSpace(); -void SNDDXMuteAudio(); -void SNDDXUnMuteAudio(); -void SNDDXSetVolume(int volume); - -SoundInterface_struct SNDDIRECTX = { - SNDCORE_DIRECTX, - "Direct Sound Interface", - SNDDXInit, - SNDDXDeInit, - SNDDXUpdateAudio, - SNDDXGetAudioSpace, - SNDDXMuteAudio, - SNDDXUnMuteAudio, - SNDDXSetVolume -}; - -LPDIRECTSOUND8 lpDS8; -LPDIRECTSOUNDBUFFER lpDSB, lpDSB2; - -extern WINCLASS *MainWindow; - -static s16 *stereodata16; -static u32 soundoffset=0; -static u32 soundbufsize; -static LONG soundvolume; -static int issoundmuted; - -////////////////////////////////////////////////////////////////////////////// - -static volatile bool doterminate; -static volatile bool terminated; - -extern CRITICAL_SECTION win_sync; -extern volatile int win_sound_samplecounter; - -DWORD WINAPI SNDDXThread( LPVOID ) -{ - for(;;) { - if(doterminate) break; - { - Lock lock; - SPU_Emulate_user(); - } - Sleep(10); - } - terminated = true; - return 0; -} - -int SNDDXInit(int buffersize) -{ - DSBUFFERDESC dsbdesc; - WAVEFORMATEX wfx; - HRESULT ret; - char tempstr[512]; - - if ((ret = DirectSoundCreate8(NULL, &lpDS8, NULL)) != DS_OK) - { - sprintf(tempstr, "DirectSound8Create error: %s - %s", DXGetErrorString8(ret), DXGetErrorDescription8(ret)); - MessageBox (NULL, tempstr, "Error", MB_OK | MB_ICONINFORMATION); - return -1; - } - - if ((ret = IDirectSound8_SetCooperativeLevel(lpDS8, MainWindow->getHWnd(), DSSCL_PRIORITY)) != DS_OK) - { - sprintf(tempstr, "IDirectSound8_SetCooperativeLevel error: %s - %s", DXGetErrorString8(ret), DXGetErrorDescription8(ret)); - MessageBox (NULL, tempstr, "Error", MB_OK | MB_ICONINFORMATION); - return -1; - } - - memset(&dsbdesc, 0, sizeof(dsbdesc)); - dsbdesc.dwSize = sizeof(DSBUFFERDESC); - dsbdesc.dwFlags = DSBCAPS_PRIMARYBUFFER; - dsbdesc.dwBufferBytes = 0; - dsbdesc.lpwfxFormat = NULL; - - if ((ret = IDirectSound8_CreateSoundBuffer(lpDS8, &dsbdesc, &lpDSB, NULL)) != DS_OK) - { - sprintf(tempstr, "Error when creating primary sound buffer: %s - %s", DXGetErrorString8(ret), DXGetErrorDescription8(ret)); - MessageBox (NULL, tempstr, "Error", MB_OK | MB_ICONINFORMATION); - return -1; - } - - soundbufsize = buffersize * 2 * 2; - - memset(&wfx, 0, sizeof(wfx)); - wfx.wFormatTag = WAVE_FORMAT_PCM; - wfx.nChannels = 2; - wfx.nSamplesPerSec = 44100; - wfx.wBitsPerSample = 16; - wfx.nBlockAlign = (wfx.wBitsPerSample / 8) * wfx.nChannels; - wfx.nAvgBytesPerSec = wfx.nSamplesPerSec * wfx.nBlockAlign; - - if ((ret = IDirectSoundBuffer8_SetFormat(lpDSB, &wfx)) != DS_OK) - { - sprintf(tempstr, "IDirectSoundBuffer8_SetFormat error: %s - %s", DXGetErrorString8(ret), DXGetErrorDescription8(ret)); - MessageBox (NULL, tempstr, "Error", MB_OK | MB_ICONINFORMATION); - return -1; - } - - memset(&dsbdesc, 0, sizeof(dsbdesc)); - dsbdesc.dwSize = sizeof(DSBUFFERDESC); - dsbdesc.dwFlags = DSBCAPS_GLOBALFOCUS | DSBCAPS_STICKYFOCUS | - DSBCAPS_CTRLVOLUME | DSBCAPS_GETCURRENTPOSITION2 | - DSBCAPS_LOCHARDWARE; - dsbdesc.dwBufferBytes = soundbufsize; - dsbdesc.lpwfxFormat = &wfx; - - if ((ret = IDirectSound8_CreateSoundBuffer(lpDS8, &dsbdesc, &lpDSB2, NULL)) != DS_OK) - { - if (ret == DSERR_CONTROLUNAVAIL || - ret == DSERR_INVALIDCALL || - ret == E_FAIL || - ret == E_NOTIMPL) - { - // Try using a software buffer instead - dsbdesc.dwFlags = DSBCAPS_GLOBALFOCUS | DSBCAPS_STICKYFOCUS | - DSBCAPS_CTRLVOLUME | DSBCAPS_GETCURRENTPOSITION2 | - DSBCAPS_LOCSOFTWARE; - - if ((ret = IDirectSound8_CreateSoundBuffer(lpDS8, &dsbdesc, &lpDSB2, NULL)) != DS_OK) - { - sprintf(tempstr, "Error when creating secondary sound buffer: %s - %s", DXGetErrorString8(ret), DXGetErrorDescription8(ret)); - MessageBox (NULL, tempstr, "Error", MB_OK | MB_ICONINFORMATION); - return -1; - } - } - else - { - sprintf(tempstr, "Error when creating secondary sound buffer: %s - %s", DXGetErrorString8(ret), DXGetErrorDescription8(ret)); - MessageBox (NULL, tempstr, "Error", MB_OK | MB_ICONINFORMATION); - return -1; - } - } - - IDirectSoundBuffer8_Play(lpDSB2, 0, 0, DSBPLAY_LOOPING); - - if ((stereodata16 = (s16 *)malloc(soundbufsize)) == NULL) - return -1; - - memset(stereodata16, 0, soundbufsize); - - soundvolume = DSBVOLUME_MAX; - issoundmuted = 0; - - doterminate = false; - terminated = false; - CreateThread(0,0,SNDDXThread,0,0,0); - - return 0; -} - -////////////////////////////////////////////////////////////////////////////// - -void SNDDXDeInit() -{ - DWORD status=0; - - doterminate = true; - while(!terminated) { - Sleep(1); - } - - if (lpDSB2) - { - IDirectSoundBuffer8_GetStatus(lpDSB2, &status); - - if(status == DSBSTATUS_PLAYING) - IDirectSoundBuffer8_Stop(lpDSB2); - - IDirectSoundBuffer8_Release(lpDSB2); - lpDSB2 = NULL; - } - - if (lpDSB) - { - IDirectSoundBuffer8_Release(lpDSB); - lpDSB = NULL; - } - - if (lpDS8) - { - IDirectSound8_Release(lpDS8); - lpDS8 = NULL; - } -} - -////////////////////////////////////////////////////////////////////////////// - -void SNDDXUpdateAudio(s16 *buffer, u32 num_samples) -{ - LPVOID buffer1; - LPVOID buffer2; - DWORD buffer1_size, buffer2_size; - DWORD status; - - int samplecounter; - { - Lock lock; - samplecounter = win_sound_samplecounter -= num_samples; - } - - bool silence = (samplecounter<-44100*15/60); //behind by more than a quarter second -> silence - - IDirectSoundBuffer8_GetStatus(lpDSB2, &status); - - if (status & DSBSTATUS_BUFFERLOST) - return; // fix me - - IDirectSoundBuffer8_Lock(lpDSB2, soundoffset, num_samples * sizeof(s16) * 2, &buffer1, &buffer1_size, &buffer2, &buffer2_size, 0); - - if(silence) { - memset(buffer1, 0, buffer1_size); - if(buffer2) - memset(buffer2, 0, buffer2_size); - } - else - { - memcpy(buffer1, buffer, buffer1_size); - if (buffer2) - memcpy(buffer2, ((u8 *)buffer)+buffer1_size, buffer2_size); - } - - soundoffset += buffer1_size + buffer2_size; - soundoffset %= soundbufsize; - - IDirectSoundBuffer8_Unlock(lpDSB2, buffer1, buffer1_size, buffer2, buffer2_size); -} - -////////////////////////////////////////////////////////////////////////////// - -u32 SNDDXGetAudioSpace() -{ - DWORD playcursor, writecursor; - u32 freespace=0; - - if (IDirectSoundBuffer8_GetCurrentPosition (lpDSB2, &playcursor, &writecursor) != DS_OK) - return 0; - - if (soundoffset > playcursor) - freespace = soundbufsize - soundoffset + playcursor; - else - freespace = playcursor - soundoffset; - - // if (freespace > 512) - return (freespace / 2 / 2); - // else - // return 0; -} - -////////////////////////////////////////////////////////////////////////////// - -void SNDDXMuteAudio() -{ - issoundmuted = 1; - IDirectSoundBuffer8_SetVolume (lpDSB2, DSBVOLUME_MIN); -} - -////////////////////////////////////////////////////////////////////////////// - -void SNDDXUnMuteAudio() -{ - issoundmuted = 0; - IDirectSoundBuffer8_SetVolume (lpDSB2, soundvolume); -} - -////////////////////////////////////////////////////////////////////////////// - -void SNDDXSetVolume(int volume) -{ - if (!lpDSB2) return ; /* might happen when changing sounddevice on the fly, caused a gpf */ - soundvolume = (((LONG)volume) - 100) * 100; - if (!issoundmuted) - IDirectSoundBuffer8_SetVolume (lpDSB2, soundvolume); -} - -////////////////////////////////////////////////////////////////////////////// - - diff --git a/desmume/src/windows/userconfig/readme.txt b/desmume/src/windows/userconfig/readme.txt deleted file mode 100644 index 39031a774..000000000 --- a/desmume/src/windows/userconfig/readme.txt +++ /dev/null @@ -1 +0,0 @@ -see the defaultconfig directory for more information on what this is all about \ No newline at end of file diff --git a/desmume/src/windows/video.h b/desmume/src/windows/video.h deleted file mode 100644 index 6ede5c105..000000000 --- a/desmume/src/windows/video.h +++ /dev/null @@ -1,165 +0,0 @@ -#include "filter/filter.h" - -class VideoInfo -{ -public: - - int width; - int height; - - int rotation; - int screengap; - - int currentfilter; - - u8* srcBuffer; - CACHE_ALIGN u8 filteredbuffer[4*256*192*4]; - - enum { - NONE, - HQ2X, - _2XSAI, - SUPER2XSAI, - SUPEREAGLE, - SCANLINE, - BILINEAR - }; - - - void reset() { - width = 256; - height = 384; - } - - void setfilter(int filter) { - - currentfilter = filter; - - switch(filter) { - - case NONE: - width = 256; - height = 384; - break; - default: - width = 512; - height = 768; - break; - } - } - - SSurface src; - SSurface dst; - - u16* finalBuffer() const - { - if(currentfilter == NONE) - return (u16*)srcBuffer; - else return (u16*)filteredbuffer; - } - - void filter() { - - src.Height = 384; - src.Width = 256; - src.Pitch = 512; - src.Surface = (u8*)srcBuffer; - - dst.Height = 768; - dst.Width = 512; - dst.Pitch = 1024; - dst.Surface = (u8*)filteredbuffer; - - switch(currentfilter) - { - case NONE: - break; - case HQ2X: - RenderHQ2X(src, dst); - break; - case _2XSAI: - Render2xSaI (src, dst); - break; - case SUPER2XSAI: - RenderSuper2xSaI (src, dst); - break; - case SUPEREAGLE: - RenderSuperEagle (src, dst); - break; - case SCANLINE: - RenderScanline(src, dst); - break; - case BILINEAR: - RenderBilinear(src, dst); - break; - } - } - - int size() { - return width*height; - } - - int ratio() { - return width / 256; - } - - int rotatedwidth() { - switch(rotation) { - case 0: - return width; - case 90: - return height; - case 180: - return width; - case 270: - return height; - default: - return 0; - } - } - - int rotatedheight() { - switch(rotation) { - case 0: - return height; - case 90: - return width; - case 180: - return height; - case 270: - return width; - default: - return 0; - } - } - - int rotatedwidthgap() { - switch(rotation) { - case 0: - return width; - case 90: - return height + screengap; - case 180: - return width; - case 270: - return height + screengap; - default: - return 0; - } - } - - int rotatedheightgap() { - switch(rotation) { - case 0: - return height + screengap; - case 90: - return width; - case 180: - return height + screengap; - case 270: - return width; - default: - return 0; - } - } -}; diff --git a/desmume/dsm.txt b/dsm.txt similarity index 80% rename from desmume/dsm.txt rename to dsm.txt index 2942abb04..b7ac03918 100644 --- a/desmume/dsm.txt +++ b/dsm.txt @@ -13,12 +13,6 @@ Integer keys (also used for booleans, with a 1 or 0) will have a value that is a - version (required) - the version of the movie file format; for now it is always 3 - emuVersion (required) - the version of the emulator used to produce the movie - rerecordCount (optional) - the rerecord count - - romChecksum (optional) - the CRC32 of the rom used to make the movie. should match values specified on advanscene.com - - romSerial (optional) - a concatenation of other uniquely identifying information about the rom (name,gamecode,makercode) - - useExtBios (optional) - were bios files was used? defaults to false. - - swiFromBios (optional) - were swi emulated by ExtBios? (alternative is internal HLE bios). defaults to false. - -The rom identification information may be used at a later point to warn about mismatches between movies and roms, but is not right now. String keys have values that consist of the remainder of the key-value pair line. As a consequence, string values cannot contain newlines. - romFilename (required) - the name of the file used to record the movie @@ -40,12 +34,7 @@ The fields are as follows, except as noted in note C. 'R','L','D','U','T','S','B','A','Y','X','W','E','G' field c is a variable length decimal integer which is a bitfield corresponding to miscellaneous input states which are valid at the start of the frame. -Therefore, no miscellaneous commands is represented by a value of 0. -Here are the currently defined bit values: -0x01 - Microphone Noise (hardcoded noise sample; to be held through duration of frame) -0x02 - Reset -0x04 - Lid - +There are currently no valid values and so this should always be 0. the format of the main section is as follows: diff --git a/desmume/faq.htm b/faq.htm similarity index 100% rename from desmume/faq.htm rename to faq.htm diff --git a/desmume/po/ChangeLog b/po/ChangeLog similarity index 100% rename from desmume/po/ChangeLog rename to po/ChangeLog diff --git a/desmume/po/LINGUAS b/po/LINGUAS similarity index 66% rename from desmume/po/LINGUAS rename to po/LINGUAS index 553671ffb..4f62ef98a 100644 --- a/desmume/po/LINGUAS +++ b/po/LINGUAS @@ -1,4 +1,3 @@ fr pt_BR sv -zh_CN diff --git a/desmume/po/PACKAGE b/po/PACKAGE similarity index 82% rename from desmume/po/PACKAGE rename to po/PACKAGE index 7d3dd2131..26555512a 100644 --- a/desmume/po/PACKAGE +++ b/po/PACKAGE @@ -2,7 +2,7 @@ # Add more languages here! Beware that this is a makefile snippet and # you have to adhere to make syntax. -LINGUAS = fr pt_BR sv zh_CN +LINGUAS = fr pt_BR sv # Textdomain for our package. @@ -13,5 +13,5 @@ COPYRIGHT_HOLDER = Pascal Giard #COPYRIGHT_HOLDER = Edit the file PACKAGE to change this. # Where to send msgid bugs? -MSGID_BUGS_ADDRESS = Desmume Team +MSGID_BUGS_ADDRESS = Pascal Giard #MSGID_BUGS_ADDRESS = Edit the file PACAKGE to change this. diff --git a/desmume/po/POTFILES.in b/po/POTFILES.in similarity index 100% rename from desmume/po/POTFILES.in rename to po/POTFILES.in diff --git a/desmume/po/desmume.pot b/po/desmume.pot similarity index 100% rename from desmume/po/desmume.pot rename to po/desmume.pot diff --git a/desmume/po/fr.po b/po/fr.po similarity index 100% rename from desmume/po/fr.po rename to po/fr.po diff --git a/desmume/po/pt_BR.po b/po/pt_BR.po similarity index 100% rename from desmume/po/pt_BR.po rename to po/pt_BR.po diff --git a/desmume/po/sv.po b/po/sv.po similarity index 100% rename from desmume/po/sv.po rename to po/sv.po diff --git a/desmume/po/windows/en_US.po b/po/windows/en_US.po similarity index 100% rename from desmume/po/windows/en_US.po rename to po/windows/en_US.po diff --git a/desmume/po/windows/fr_FR.po b/po/windows/fr_FR.po similarity index 100% rename from desmume/po/windows/fr_FR.po rename to po/windows/fr_FR.po diff --git a/desmume/src/ARM9.h b/src/ARM9.h similarity index 100% rename from desmume/src/ARM9.h rename to src/ARM9.h diff --git a/desmume/src/Disassembler.cpp b/src/Disassembler.cpp similarity index 100% rename from desmume/src/Disassembler.cpp rename to src/Disassembler.cpp diff --git a/desmume/src/Disassembler.h b/src/Disassembler.h similarity index 97% rename from desmume/src/Disassembler.h rename to src/Disassembler.h index 63fa2b818..4fe49b1fd 100644 --- a/desmume/src/Disassembler.h +++ b/src/Disassembler.h @@ -1,32 +1,32 @@ -/* Copyright (C) 2006 yopyop - yopyop156@ifrance.com - yopyop156.ifrance.com - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#ifndef DISASSEMBLER_H -#define DISASSEMBLER_H - -#include "types.h" - -extern char * (* des_arm_instructions_set[4096])(u32 adr, u32 i, char * txt); -extern char * (* des_thumb_instructions_set[1024])(u32 adr, u32 i, char * txt); - -#endif - - +/* Copyright (C) 2006 yopyop + yopyop156@ifrance.com + yopyop156.ifrance.com + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#ifndef DISASSEMBLER_H +#define DISASSEMBLER_H + +#include "types.h" + +extern char * (* des_arm_instructions_set[4096])(u32 adr, u32 i, char * txt); +extern char * (* des_thumb_instructions_set[1024])(u32 adr, u32 i, char * txt); + +#endif + + diff --git a/desmume/src/FIFO.cpp b/src/FIFO.cpp similarity index 75% rename from desmume/src/FIFO.cpp rename to src/FIFO.cpp index a886d89de..c6ece7aad 100644 --- a/desmume/src/FIFO.cpp +++ b/src/FIFO.cpp @@ -28,7 +28,6 @@ #include "debug.h" #include "mem.h" #include "MMU.h" -#include "NDSSystem.h" // ========================================================= IPC FIFO IPC_FIFO ipc_fifo[2]; // 0 - ARM9 @@ -137,14 +136,8 @@ void IPC_FIFOcnt(u8 proc, u16 val) } // ========================================================= GFX FIFO -GFX_PIPE gxPIPE; GFX_FIFO gxFIFO; -void GFX_PIPEclear() -{ - gxPIPE.tail = 0; -} - void GFX_FIFOclear() { u32 gxstat = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x600); @@ -157,30 +150,9 @@ void GFX_FIFOclear() void GFX_FIFOsend(u8 cmd, u32 param) { - u32 gxstat = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x600); - - if (gxFIFO.tail == 0) // FIFO empty - { - if (gxPIPE.tail < 4) // pipe not full - { - gxPIPE.cmd[gxPIPE.tail] = cmd; - gxPIPE.param[gxPIPE.tail] = param; - gxPIPE.tail++; -#ifdef USE_GEOMETRY_FIFO_EMULATION - gxstat |= 0x08000000; // set busy flag - T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x600, gxstat); -#endif - NDS_RescheduleGXFIFO(); - return; - } - } - //INFO("GFX FIFO: Send GFX 3D cmd 0x%02X to FIFO - 0x%08X (%03i/%02X)\n", cmd, param, gxFIFO.tail, gxFIFO.tail); - if (gxstat & 0x01000000) - { - //INFO("ERROR: gxFIFO is full\n"); - return; // full - } + u32 gxstat = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x600); + if (gxstat & 0x01000000) return; // full gxstat &= 0xF000FFFF; @@ -202,32 +174,24 @@ void GFX_FIFOsend(u8 cmd, u32 param) #endif T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x600, gxstat); - - NDS_RescheduleGXFIFO(); } -static BOOL GFX_FIFOrecv(u8 *cmd, u32 *param) +BOOL GFX_FIFOrecv(u8 *cmd, u32 *param) { u32 gxstat = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x600); - - if (gxFIFO.tail == 0) // empty + if (gxstat & 0xC0000000) { - gxstat &= 0xF000FFFF; + setIF(0, (1<<21)); + } + gxstat &= 0xF000FFFF; + if (gxFIFO.tail == 0) // empty + { + //gxstat |= (0x01FF << 16); gxstat |= 0x06000000; T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x600, gxstat); - if ((gxstat & 0x80000000)) // IRQ: empty - { - setIF(0, (1<<21)); - } return FALSE; } - if (gxstat & 0x40000000) // IRQ: less half - { - if (gxstat & 0x02000000) setIF(0, (1<<21)); - } - - gxstat &= 0xF000FFFF; *cmd = gxFIFO.cmd[0]; *param = gxFIFO.param[0]; gxFIFO.tail--; @@ -237,92 +201,35 @@ static BOOL GFX_FIFOrecv(u8 *cmd, u32 *param) gxFIFO.param[i] = gxFIFO.param[i+1]; } +#ifdef USE_GEOMETRY_FIFO_EMULATION + gxstat |= 0x08000000; // set busy flag +#endif + gxstat |= (gxFIFO.tail << 16); if (gxFIFO.tail < 128) gxstat |= 0x02000000; - if (gxFIFO.tail == 0) // empty - gxstat |= 0x04000000; - else - gxstat |= 0x08000000; // set busy flag - T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x600, gxstat); return TRUE; } -BOOL GFX_PIPErecv(u8 *cmd, u32 *param) -{ - u8 tmp_cmd = 0; - u32 tmp_param = 0; - u32 gxstat = 0; - - if (gxPIPE.tail > 0) - { - *cmd = gxPIPE.cmd[0]; - *param = gxPIPE.param[0]; - gxPIPE.tail--; - for (int i=0; i < gxPIPE.tail; i++) - { - gxPIPE.cmd[i] = gxPIPE.cmd[i+1]; - gxPIPE.param[i] = gxPIPE.param[i+1]; - } - - if (gxPIPE.tail < 2) - { - if (GFX_FIFOrecv(&tmp_cmd, &tmp_param)) - { - gxPIPE.cmd[gxPIPE.tail] = tmp_cmd; - gxPIPE.param[gxPIPE.tail] = tmp_param; - gxPIPE.tail++; - - - if (GFX_FIFOrecv(&tmp_cmd, &tmp_param)) - { - gxPIPE.cmd[gxPIPE.tail] = tmp_cmd; - gxPIPE.param[gxPIPE.tail] = tmp_param; - gxPIPE.tail++; - } - } - } - - if (gxPIPE.tail == 0) - { - gxstat = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x600); - gxstat &= 0xF7FFFFFF; // clear busy flag - T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x600, gxstat); - } - return (TRUE); - } - gxstat = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x600); - gxstat &= 0xF7FFFFFF; // clear busy flag - if ((gxstat & 0x80000000)) // IRQ: empty - { - if (gxFIFO.tail == 0) setIF(0, (1<<21)); - } - T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x600, gxstat); - return FALSE; -} - void GFX_FIFOcnt(u32 val) { u32 gxstat = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x600); //INFO("GFX FIFO: write context 0x%08X (prev 0x%08X) tail %i\n", val, gxstat, gxFIFO.tail); if (val & (1<<29)) // clear? (homebrew) { - GFX_PIPEclear(); GFX_FIFOclear(); return; } T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x600, gxstat); - - NDS_RescheduleGXFIFO(); - /*if (gxstat & 0xC0000000) + if (gxstat & 0xC0000000) { setIF(0, (1<<21)); - }*/ + } } // ========================================================= DISP FIFO diff --git a/desmume/src/FIFO.h b/src/FIFO.h similarity index 87% rename from desmume/src/FIFO.h rename to src/FIFO.h index b7d8aebf4..d98db4df9 100644 --- a/desmume/src/FIFO.h +++ b/src/FIFO.h @@ -26,7 +26,7 @@ #ifndef FIFO_H #define FIFO_H -//#define USE_GEOMETRY_FIFO_EMULATION //enable gxFIFO emulation +//#define USE_GEOMETRY_FIFO_EMULATION //enables new experimental gxFIFO #include "types.h" @@ -47,26 +47,16 @@ extern void IPC_FIFOcnt(u8 proc, u16 val); //=================================================== GFX FIFO typedef struct { - u8 cmd[257]; - u32 param[257]; + u8 cmd[261]; + u32 param[261]; u16 tail; // tail } GFX_FIFO; -typedef struct -{ - u8 cmd[5]; - u32 param[5]; - - u8 tail; -} GFX_PIPE; - -extern GFX_PIPE gxPIPE; extern GFX_FIFO gxFIFO; -extern void GFX_PIPEclear(); extern void GFX_FIFOclear(); extern void GFX_FIFOsend(u8 cmd, u32 param); -extern BOOL GFX_PIPErecv(u8 *cmd, u32 *param); +extern BOOL GFX_FIFOrecv(u8 *cmd, u32 *param); extern void GFX_FIFOcnt(u32 val); //=================================================== Display memory FIFO diff --git a/desmume/src/GPU.cpp b/src/GPU.cpp similarity index 84% rename from desmume/src/GPU.cpp rename to src/GPU.cpp index 29ac64138..b3a9aa0e1 100644 --- a/desmume/src/GPU.cpp +++ b/src/GPU.cpp @@ -32,14 +32,13 @@ #include "debug.h" #include "render3D.h" #include "gfx3d.h" -#include "debug.h" #include "GPU_osd.h" +#include "debug.h" #include "NDSSystem.h" #include "readwrite.h" //#undef FORCEINLINE //#define FORCEINLINE -//#define SSE2_NOINTRIN ARM9_struct ARM9Mem; @@ -53,10 +52,12 @@ GPU::MosaicLookup GPU::mosaicLookup; //#define DEBUG_TRI CACHE_ALIGN u8 GPU_screen[4*256*192]; +CACHE_ALIGN u8 GPU_tempScreen[4*256*192]; CACHE_ALIGN u8 *GPU_tempScanline; CACHE_ALIGN u8 sprWin[256]; +OSDCLASS *osd = NULL; u16 gpu_angle = 0; @@ -108,7 +109,7 @@ static const CACHE_ALIGN u8 win_empty[256] = { 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0}; static CACHE_ALIGN u16 fadeInColors[17][0x8000]; -CACHE_ALIGN u16 fadeOutColors[17][0x8000]; +static CACHE_ALIGN u16 fadeOutColors[17][0x8000]; //this should be public, because it gets used somewhere else CACHE_ALIGN u8 gpuBlendTable555[17][17][32][32]; @@ -492,6 +493,29 @@ FORCEINLINE void GPU::setFinal3DColorSpecialDecreaseWnd(int dstX, int srcX) } } + +enum OBJFunc +{ + None, Blend, Increase, Decrease +}; +template +static void _master_setFinalOBJColor(GPU *gpu, u32 passing, u8 *dst, u16 color, u8 alpha, u8 type, u16 x); + +static void setFinalOBJColorSpecialNoneWnd (GPU *gpu, u32 passing, u8 *dst, u16 color, u8 alpha, u8 type, u16 x); +static void setFinalOBJColorSpecialBlendWnd (GPU *gpu, u32 passing, u8 *dst, u16 color, u8 alpha, u8 type, u16 x); +static void setFinalOBJColorSpecialIncreaseWnd (GPU *gpu, u32 passing, u8 *dst, u16 color, u8 alpha, u8 type, u16 x); +static void setFinalOBJColorSpecialDecreaseWnd (GPU *gpu, u32 passing, u8 *dst, u16 color, u8 alpha, u8 type, u16 x); + +const GPU::FinalOBJColFunct pixelBlittersOBJ[8] = { + _master_setFinalOBJColor, + _master_setFinalOBJColor, + _master_setFinalOBJColor, + _master_setFinalOBJColor, + _master_setFinalOBJColor, + _master_setFinalOBJColor, + _master_setFinalOBJColor, + _master_setFinalOBJColor }; + /*****************************************************************************/ // INITIALIZATION /*****************************************************************************/ @@ -551,14 +575,12 @@ static void GPU_InitFadeColors() } } -static CACHE_ALIGN GPU GPU_main, GPU_sub; - GPU * GPU_Init(u8 l) { GPU * g; - if(l==0) g = &GPU_main; - else g = &GPU_sub; + if ((g = (GPU *) malloc(sizeof(GPU))) == NULL) + return NULL; GPU_Reset(g, l); GPU_InitFadeColors(); @@ -569,7 +591,9 @@ GPU * GPU_Init(u8 l) g->need_update_winh[1] = true; g->setFinalColorBck_funcNum = 0; g->setFinalColor3d_funcNum = 0; - g->setFinalColorSpr_funcNum = 0; + g->setFinalColorSpr = _master_setFinalOBJColor; + + return g; } @@ -580,7 +604,7 @@ void GPU_Reset(GPU *g, u8 l) g->setFinalColorBck_funcNum = 0; g->setFinalColor3d_funcNum = 0; - g->setFinalColorSpr_funcNum = 0; + g->setFinalColorSpr = _master_setFinalOBJColor; g->core = l; g->BGSize[0][0] = g->BGSize[1][0] = g->BGSize[2][0] = g->BGSize[3][0] = 256; g->BGSize[0][1] = g->BGSize[1][1] = g->BGSize[2][1] = g->BGSize[3][1] = 256; @@ -610,7 +634,6 @@ void GPU_Reset(GPU *g, u8 l) void GPU_DeInit(GPU * gpu) { - if(gpu==&GPU_main || gpu==&GPU_sub) return; free(gpu); } @@ -698,8 +721,6 @@ void GPU_setMasterBrightness (GPU *gpu, u16 val) } gpu->MasterBrightFactor = (val & 0x1F); gpu->MasterBrightMode = (val>>14); - //printf("MASTER BRIGHTNESS %d to %d at %d\n",gpu->core,gpu->MasterBrightFactor,nds.VCount); - } void SetupFinalPixelBlitter (GPU *gpu) @@ -707,7 +728,7 @@ void SetupFinalPixelBlitter (GPU *gpu) u8 windowUsed = (gpu->WIN0_ENABLED | gpu->WIN1_ENABLED | gpu->WINOBJ_ENABLED); u8 blendMode = (gpu->BLDCNT >> 6)&3; - gpu->setFinalColorSpr_funcNum = windowUsed*4 + blendMode; + gpu->setFinalColorSpr = pixelBlittersOBJ[windowUsed*4 + blendMode]; gpu->setFinalColorBck_funcNum = windowUsed*4 + blendMode; gpu->setFinalColor3d_funcNum = windowUsed*4 + blendMode; @@ -748,18 +769,19 @@ void GPU_setVideoProp(GPU * gpu, u32 p) if(cnt->OBJ_Tile_mapping) { - //1-d sprite mapping boundaries: - //32k, 64k, 128k, 256k + // 1-d sprite mapping + // boundary : + // core A : 32k, 64k, 128k, 256k + // core B : 32k, 64k, 128k, 128k gpu->sprBoundary = 5 + cnt->OBJ_Tile_1D_Bound ; - //do not be deceived: even though a sprBoundary==8 (256KB region) is impossible to fully address - //in GPU_SUB, it is still fully legal to address it with that granularity. - //so don't do this: //if((gpu->core == GPU_SUB) && (cnt->OBJ_Tile_1D_Bound == 3)) gpu->sprBoundary = 7; + //zero 10-apr-09 - not sure whether this is right... + if((gpu->core == GPU_SUB) && (cnt->OBJ_Tile_1D_Bound == 3)) gpu->sprBoundary = 7; gpu->spriteRenderMode = GPU::SPRITE_1D; } else { - //2d sprite mapping - //boundary : 32k + // 2d sprite mapping + // boundary : 32k gpu->sprBoundary = 5; gpu->spriteRenderMode = GPU::SPRITE_2D; } @@ -895,6 +917,7 @@ FORCEINLINE void GPU::renderline_checkWindows(u16 x, bool &draw, bool &effect) c { //INFO("bg%i passed win0 : (%i %i) was within (%i %i)(%i %i)\n", bgnum, x, gpu->currLine, gpu->WIN0H0, gpu->WIN0V0, gpu->WIN0H1, gpu->WIN0V1); draw = (WININ0 >> currBgNum)&1; + if(currBgNum==5) draw = true; //backdrop must always be drawn. windows only control color effects. effect = (WININ0_SPECIAL); return; } @@ -910,6 +933,7 @@ FORCEINLINE void GPU::renderline_checkWindows(u16 x, bool &draw, bool &effect) c { //INFO("bg%i passed win1 : (%i %i) was within (%i %i)(%i %i)\n", bgnum, x, gpu->currLine, gpu->WIN1H0, gpu->WIN1V0, gpu->WIN1H1, gpu->WIN1V1); draw = (WININ1 >> currBgNum)&1; + if(currBgNum==5) draw = true; //backdrop must always be drawn. windows only control color effects. effect = (WININ1_SPECIAL); return; } @@ -923,6 +947,7 @@ FORCEINLINE void GPU::renderline_checkWindows(u16 x, bool &draw, bool &effect) c if (sprWin[x]) { draw = (WINOBJ >> currBgNum)&1; + if(currBgNum==5) draw = true; //backdrop must always be drawn. windows only control color effects. effect = (WINOBJ_SPECIAL); return; } @@ -931,6 +956,7 @@ FORCEINLINE void GPU::renderline_checkWindows(u16 x, bool &draw, bool &effect) c if (WINOBJ_ENABLED | WIN1_ENABLED | WIN0_ENABLED) { draw = (WINOUT >> currBgNum) & 1; + if(currBgNum==5) draw = true; //backdrop must always be drawn. windows only control color effects. effect = (WINOUT_SPECIAL); } } @@ -939,48 +965,118 @@ FORCEINLINE void GPU::renderline_checkWindows(u16 x, bool &draw, bool &effect) c // PIXEL RENDERING - BGS /*****************************************************************************/ - -template -FORCEINLINE FASTCALL bool GPU::_master_setFinalBGColor(u16 &color, const u32 x) +FORCEINLINE void GPU::setFinalBGColorSpecialNone(u16 &color, const u8 x) { - //no further analysis for no special effects. on backdrops. just draw it. - if(FUNC==None && BACKDROP) return true; - - //blend backdrop with what?? this doesn't make sense - if(FUNC==Blend && BACKDROP) return true; - - bool windowEffect = true; - - if(WINDOW) - { - bool windowDraw; - renderline_checkWindows(x, windowDraw, windowEffect); - - //backdrop must always be drawn - if(BACKDROP) windowDraw = true; - - //we never have anything more to do if the window rejected us - if(!windowDraw) return false; - } - - //special effects rejected. just draw it. - if(!(blend1 && windowEffect)) - return true; - - const u8 bg_under = bgPixels[x]; - - //perform the special effect - switch(FUNC) { - case Blend: if(blend2[bg_under]) color = blend(color,T2ReadWord(currDst, x<<1)); break; - case Increase: color = currentFadeInColors[color]; break; - case Decrease: color = currentFadeOutColors[color]; break; - case None: break; - } - return true; } -template -static FORCEINLINE void _master_setFinalOBJColor(GPU *gpu, u8 *dst, u16 color, u8 alpha, u8 type, u16 x) +FORCEINLINE void GPU::setFinalBGColorSpecialBlend(u16 &color, const u8 x) +{ + if(blend1) + { + //If the layer we are drawing on is selected as 2nd source, we can blend + int bg_under = bgPixels[x]; + if(blend2[bg_under]) + color = blend(color,T2ReadWord(currDst, x<<1)); + } +} + +FORCEINLINE void GPU::setFinalBGColorSpecialIncrease (u16 &color, const u8 x) +{ + if(blend1) // the bg to draw has a special color effect + { + color = (currentFadeInColors[color&0x7FFF]); + } +} + +FORCEINLINE void GPU::setFinalBGColorSpecialDecrease(u16 &color, const u8 x) +{ + if(blend1) // the bg to draw has a special color effect + { + color = (currentFadeOutColors[color&0x7FFF]); + } +} + +FORCEINLINE bool GPU::setFinalBGColorSpecialNoneWnd(u16 &color, const u8 x) +{ + bool windowDraw = true, windowEffect = true; + + renderline_checkWindows(x, windowDraw, windowEffect); + + if (blend1 && windowEffect) // the bg to draw has a special color effect + { + return true; + } + else + { + if ((windowEffect && (BLDCNT & (0x100 << currBgNum))) || windowDraw) + { + return true; + } + } + return false; +} + +FORCEINLINE bool GPU::setFinalBGColorSpecialBlendWnd(u16 &color, const u8 x) +{ + bool windowDraw = true, windowEffect = true; + + renderline_checkWindows(x, windowDraw, windowEffect); + + if(windowDraw) + { + if(blend1 && windowEffect) + { + int bg_under = bgPixels[x]; + + // If the layer we are drawing on is selected as 2nd source, we can blend + if(blend2[bg_under]) + color = blend(color,T2ReadWord(currDst, x<<1)); + } + return true; + } + return false; +} + +FORCEINLINE bool GPU::setFinalBGColorSpecialIncreaseWnd(u16 &color, const u8 x) +{ + bool windowDraw = true, windowEffect = true; + + renderline_checkWindows(x, windowDraw, windowEffect); + + if(windowDraw) + { + if(blend1 && windowEffect) + { + color = currentFadeInColors[color&0x7FFF]; + } + return true; + } + return false; +} + +FORCEINLINE bool GPU::setFinalBGColorSpecialDecreaseWnd(u16 &color, const u8 x) +{ + bool windowDraw = true, windowEffect = true; + + renderline_checkWindows(x, windowDraw, windowEffect); + + if(windowDraw) + { + if(blend1 && windowEffect) + { + color = currentFadeOutColors[color&0x7FFF]; + } + return true; + } + return false; +} + +/*****************************************************************************/ +// PIXEL RENDERING - OBJS +/*****************************************************************************/ + +template +static void _master_setFinalOBJColor(GPU *gpu, u32 passing, u8 *dst, u16 color, u8 alpha, u8 type, u16 x) { bool windowDraw = true, windowEffect = true; @@ -992,29 +1088,28 @@ static FORCEINLINE void _master_setFinalOBJColor(GPU *gpu, u8 *dst, u16 color, u } //this inspects the layer beneath the sprite to see if the current blend flags make it a candidate for blending - const int bg_under = gpu->bgPixels[x]; - const bool allowBlend = (bg_under != 4) && gpu->blend2[bg_under]; + int bg_under = gpu->bgPixels[x]; + bool allowBlend = ((bg_under != 4) && (gpu->BLDCNT & (0x100 << bg_under))); - const bool sourceEffectSelected = gpu->blend1; + bool sourceEffectSelected = (gpu->BLDCNT & 0x10)!=0; //note that the fadein and fadeout is done here before blending, - //so that a fade and blending can be applied at the same time (actually, I don't think that is legal..) + //so that a fade and blending can be applied at the same time bool forceBlendingForNormal = false; if(windowEffect && sourceEffectSelected) switch(FUNC) { - case Increase: if(!allowBlend) color = gpu->currentFadeInColors[color&0x7FFF]; break; - case Decrease: if(!allowBlend) color = gpu->currentFadeOutColors[color&0x7FFF]; break; + case Increase: if(!allowBlend) color = fadeInColors[gpu->BLDY_EVY][color&0x7FFF]; break; + case Decrease: if(!allowBlend) color = fadeOutColors[gpu->BLDY_EVY][color&0x7FFF]; break; //only when blend color effect is selected, ordinarily opaque sprites are blended with the color effect params case Blend: forceBlendingForNormal = true; break; - case None: break; } if(allowBlend) { - u16 backColor = T2ReadWord(dst,x<<1); + u16 backColor = T2ReadWord(dst,passing); //this hasn't been tested: this blending occurs without regard to the color effect, //but rather purely from the sprite's alpha if(type == GPU_OBJ_MODE_Bitmap) @@ -1023,45 +1118,43 @@ static FORCEINLINE void _master_setFinalOBJColor(GPU *gpu, u8 *dst, u16 color, u color = gpu->blend(color,backColor); } - T2WriteWord(dst, x<<1, (color | 0x8000)); + T2WriteWord(dst, passing, (color | 0x8000)); gpu->bgPixels[x] = 4; } -//FUNCNUM is only set for backdrop, for an optimization of looking it up early -template -FORCEINLINE void GPU::setFinalColorBG(u16 color, const u32 x) +FORCEINLINE void GPU::setFinalColorBG(u16 color, u8 x) { //It is not safe to assert this here. //This is probably the best place to enforce it, since almost every single color that comes in here //will be pulled from a palette that needs the top bit stripped off anyway. //assert((color&0x8000)==0); - if(!BACKDROP) color &= 0x7FFF; //but for the backdrop we can easily guarantee earlier that theres no bit here + color &= 0x7FFF; - bool draw; - - const int test = BACKDROP?FUNCNUM:setFinalColorBck_funcNum; - switch(test) + //if someone disagrees with these, they could be reimplemented as a function pointer easily + bool draw=true; + switch(setFinalColorBck_funcNum) { - case 0: draw = _master_setFinalBGColor(color,x); break; - case 1: draw = _master_setFinalBGColor(color,x); break; - case 2: draw = _master_setFinalBGColor(color,x); break; - case 3: draw = _master_setFinalBGColor(color,x); break; - case 4: draw = _master_setFinalBGColor(color,x); break; - case 5: draw = _master_setFinalBGColor(color,x); break; - case 6: draw = _master_setFinalBGColor(color,x); break; - case 7: draw = _master_setFinalBGColor(color,x); break; + case 0x0: setFinalBGColorSpecialNone(color,x); break; + case 0x1: setFinalBGColorSpecialBlend(color,x); break; + case 0x2: setFinalBGColorSpecialIncrease(color,x); break; + case 0x3: setFinalBGColorSpecialDecrease(color,x); break; + case 0x4: draw=setFinalBGColorSpecialNoneWnd(color,x); break; + case 0x5: draw=setFinalBGColorSpecialBlendWnd(color,x); break; + case 0x6: draw=setFinalBGColorSpecialIncreaseWnd(color,x); break; + case 0x7: draw=setFinalBGColorSpecialDecreaseWnd(color,x); break; }; - if(BACKDROP || draw) //backdrop must always be drawn + if(draw) { T2WriteWord(currDst, x<<1, color | 0x8000); - if(!BACKDROP) bgPixels[x] = currBgNum; //lets do this in the backdrop drawing loop, should be faster + bgPixels[x] = currBgNum; } } FORCEINLINE void GPU::setFinalColor3d(int dstX, int srcX) { + //if someone disagrees with these, they could be reimplemented as a function pointer easily switch(setFinalColor3d_funcNum) { case 0x0: setFinal3DColorSpecialNone(dstX,srcX); break; @@ -1075,36 +1168,15 @@ FORCEINLINE void GPU::setFinalColor3d(int dstX, int srcX) }; } -FORCEINLINE void setFinalColorSpr(GPU* gpu, u8 *dst, u16 color, u8 alpha, u8 type, u16 x) -{ - switch(gpu->setFinalColorSpr_funcNum) - { - case 0x0: _master_setFinalOBJColor(gpu, dst, color, alpha, type, x); break; - case 0x1: _master_setFinalOBJColor(gpu, dst, color, alpha, type, x); break; - case 0x2: _master_setFinalOBJColor(gpu, dst, color, alpha, type, x); break; - case 0x3: _master_setFinalOBJColor(gpu, dst, color, alpha, type, x); break; - case 0x4: _master_setFinalOBJColor(gpu, dst, color, alpha, type, x); break; - case 0x5: _master_setFinalOBJColor(gpu, dst, color, alpha, type, x); break; - case 0x6: _master_setFinalOBJColor(gpu, dst, color, alpha, type, x); break; - case 0x7: _master_setFinalOBJColor(gpu, dst, color, alpha, type, x); break; - }; -} - -template -FORCEINLINE void GPU::__setFinalColorBck(u16 color, const u32 x, const int opaque) -{ - return ___setFinalColorBck(color,x,opaque); -} - //this was forced inline because most of the time it just falls through to setFinalColorBck() and the function call //overhead was ridiculous and terrible -template -FORCEINLINE void GPU::___setFinalColorBck(u16 color, const u32 x, const int opaque) +template FORCEINLINE void GPU::__setFinalColorBck(u16 color, const u8 x, const bool opaque) { //I commented out this line to make a point. - //under ordinary circumstances, nobody should pass in something >=256 + //indeed, since x is a u8 we cannot pass in anything >=256 //but in fact, someone is going to try. specifically, that is the map viewer debug tools //which try to render the enter BG. in cases where that is large, it could be up to 1024 wide. + //I think it survives this truncation to 8bits. //assert(x<256); int x_int; @@ -1130,7 +1202,7 @@ FORCEINLINE void GPU::___setFinalColorBck(u16 color, const u32 x, const int opaq if(color != 0xFFFF) { finish: - setFinalColorBG(color,x); + setFinalColorBG(color,x); } } @@ -1168,7 +1240,7 @@ static void mosaicSpriteLinePixel(GPU * gpu, int x, u16 l, u8 * dst, u8 * dst_al if(!objColor.opaque) prioTab[x] = 0xFF; } -FORCEINLINE static void mosaicSpriteLine(GPU * gpu, u16 l, u8 * dst, u8 * dst_alpha, u8 * typeTab, u8 * prioTab) +static void mosaicSpriteLine(GPU * gpu, u16 l, u8 * dst, u8 * dst_alpha, u8 * typeTab, u8 * prioTab) { //don't even try this unless the mosaic is effective if(gpu->mosaicLookup.widthValue != 0 || gpu->mosaicLookup.heightValue != 0) @@ -1196,7 +1268,7 @@ template void lineLarge8bpp(GPU * gpu) //TODO - handle wrapping / out of bounds correctly from rot_scale_op? u32 tmp_map = gpu->BG_bmp_large_ram[num] + lg * YBG; - u8* map = MMU_gpu_map(tmp_map); + u8* map = MMU_RenderMapToLCD(tmp_map); u8* pal = ARM9Mem.ARM9_VMEM + gpu->core * ADDRESS_STEP_1KB; @@ -1205,7 +1277,7 @@ template void lineLarge8bpp(GPU * gpu) XBG &= wmask; u8 pixel = map[XBG]; u16 color = T1ReadWord(pal, pixel<<1); - gpu->__setFinalColorBck(color,x,color); + gpu->__setFinalColorBck(color,x,color!=0); } } @@ -1241,8 +1313,12 @@ template INLINE void renderline_textBG(GPU * gpu, u16 XBG, u16 YBG, if(tmp>31) tmp_map+= ADDRESS_STEP_512B << bgCnt->ScreenSize ; + //map = (u8*)MMU_RenderMapToLCD(tmp_map); map = tmp_map; + //if(!map) return; // no map + tile = gpu->BG_tile_ram[num]; + //if(!tile) return; // no tiles xoff = XBG; pal = ARM9Mem.ARM9_VMEM + gpu->core * ADDRESS_STEP_1KB; @@ -1273,12 +1349,12 @@ template INLINE void renderline_textBG(GPU * gpu, u16 XBG, u16 YBG, if(!(xoff&1)) { color = T1ReadWord(pal, ((currLine>>4) + tilePalette) << 1); - gpu->__setFinalColorBck(color,x,currLine>>4); + gpu->__setFinalColorBck(color,x,currLine>>4); x++; xoff++; } color = T1ReadWord(pal, ((currLine&0xF) + tilePalette) << 1); - gpu->__setFinalColorBck(color,x,currLine&0xF); + gpu->__setFinalColorBck(color,x,currLine&0xF); x++; xoff++; } } else { @@ -1290,12 +1366,12 @@ template INLINE void renderline_textBG(GPU * gpu, u16 XBG, u16 YBG, if(!(xoff&1)) { color = T1ReadWord(pal, ((currLine&0xF) + tilePalette) << 1); - gpu->__setFinalColorBck(color,x,currLine&0xF); + gpu->__setFinalColorBck(color,x,currLine&0xF); x++; xoff++; } color = T1ReadWord(pal, ((currLine>>4) + tilePalette) << 1); - gpu->__setFinalColorBck(color,x,currLine>>4); + gpu->__setFinalColorBck(color,x,currLine>>4); x++; xoff++; } } @@ -1338,7 +1414,7 @@ template INLINE void renderline_textBG(GPU * gpu, u16 XBG, u16 YBG, else color = T1ReadWord(pal, (*line) << 1); - gpu->__setFinalColorBck(color,x,*line); + gpu->__setFinalColorBck(color,x,*line); x++; xoff++; @@ -1362,7 +1438,7 @@ template FORCEINLINE void rot_tiled_8bit_entry(GPU * gpu, s32 auxX, palette_entry = *(u8*)MMU_gpu_map(tile + ((tileindex<<6)+(y<<3)+x)); color = T1ReadWord(pal, palette_entry << 1); - gpu->__setFinalColorBck(color,i,palette_entry); + gpu->__setFinalColorBck(color,i,palette_entry); } template FORCEINLINE void rot_tiled_16bit_entry(GPU * gpu, s32 auxX, s32 auxY, int lg, u32 map, u32 tile, u8 * pal, int i, u8 extPal) { @@ -1379,7 +1455,7 @@ template FORCEINLINE void rot_tiled_16bit_entry(GPU * gpu, s32 auxX palette_entry = *(u8*)MMU_gpu_map(tile + ((tileentry.bits.TileNum<<6)+(y<<3)+x)); color = T1ReadWord(pal, (palette_entry + (extPal ? (tileentry.bits.Palette<<8) : 0)) << 1); - gpu->__setFinalColorBck(color, i, palette_entry); + gpu->__setFinalColorBck(color, i, palette_entry); } template FORCEINLINE void rot_256_map(GPU * gpu, s32 auxX, s32 auxY, int lg, u32 map, u32 tile, u8 * pal, int i, u8 extPal) { @@ -1390,14 +1466,14 @@ template FORCEINLINE void rot_256_map(GPU * gpu, s32 auxX, s32 auxY palette_entry = *adr; color = T1ReadWord(pal, palette_entry << 1); - gpu->__setFinalColorBck(color, i, palette_entry); + gpu->__setFinalColorBck(color, i, palette_entry); } template FORCEINLINE void rot_BMP_map(GPU * gpu, s32 auxX, s32 auxY, int lg, u32 map, u32 tile, u8 * pal, int i, u8 extPal) { u16 color; void* adr = MMU_gpu_map((map) + ((auxX + auxY * lg) << 1)); color = T1ReadWord(adr, 0); - gpu->__setFinalColorBck(color, i, color&0x8000); + gpu->__setFinalColorBck(color, i, color&0x8000); } typedef void (*rot_fun)(GPU * gpu, s32 auxX, s32 auxY, int lg, u32 map, u32 tile, u8 * pal , int i, u8 extPal); @@ -1457,6 +1533,7 @@ template FORCEINLINE void rotBG2(GPU * gpu, s32 X, s32 Y, s16 PA, s template FORCEINLINE void extRotBG2(GPU * gpu, s32 X, s32 Y, s16 PA, s16 PB, s16 PC, s16 PD, s16 LG) { u8 num = gpu->currBgNum; + struct _BGxCNT * bgCnt = &(gpu->dispx_st)->dispx_BGxCNT[num].bits; struct _DISPCNT * dispCnt = &(gpu->dispx_st)->dispx_DISPCNT.bits; u8 *map, *tile, *pal; @@ -1494,29 +1571,14 @@ template FORCEINLINE void extRotBG2(GPU * gpu, s32 X, s32 Y, s16 PA // BACKGROUND RENDERING -HELPER FUNCTIONS- /*****************************************************************************/ -#if 0 -static void lineNull(GPU * gpu) +void lineNull(GPU * gpu) { } -#endif template void lineText(GPU * gpu) { BGxOFS * ofs = &gpu->dispx_st->dispx_BGxOFS[gpu->currBgNum]; - - - - if(gpu->debug) - { - const s32 wh = gpu->BGSize[gpu->currBgNum][0]; - renderline_textBG(gpu, 0, gpu->currLine, wh); - } - else - { - const u16 vofs = T1ReadWord((u8 *)&ofs->BGxVOFS,0); - const u16 hofs = T1ReadWord((u8 *)&ofs->BGxHOFS,0); - renderline_textBG(gpu, hofs, gpu->currLine + vofs, 256); - } + renderline_textBG(gpu, T1ReadWord((u8 *)&ofs->BGxHOFS, 0), gpu->currLine + T1ReadWord((u8 *)&ofs->BGxVOFS, 0), 256); } template void lineRot(GPU * gpu) @@ -1527,12 +1589,8 @@ template void lineRot(GPU * gpu) } else { parms = &(gpu->dispx_st)->dispx_BG3PARMS; } - if(gpu->debug) - { - s32 wh = gpu->BGSize[gpu->currBgNum][0]; - rotBG2(gpu, 0, (s16)gpu->currLine*256, 256,0, 0,-77, wh); - } + rotBG2(gpu, 0, (s16)gpu->currLine*256, 256,0, -1,-1, 256); else { rotBG2(gpu, @@ -1558,10 +1616,7 @@ template void lineExtRot(GPU * gpu) } if(gpu->debug) - { - s32 wh = gpu->BGSize[gpu->currBgNum][0]; - extRotBG2(gpu, 0, (s16)gpu->currLine*256, 256,0, 0,-77, wh); - } + extRotBG2(gpu, 0, (s16)gpu->currLine*256, 256,0, -1,-1, 256); else { extRotBG2(gpu, @@ -1745,36 +1800,15 @@ FORCEINLINE BOOL compute_sprite_vars(_OAM_ * spriteInfo, u16 l, // SPRITE RENDERING /*****************************************************************************/ - -//TODO - refactor this so there isnt as much duped code between rotozoomed and non-rotozoomed versions - -static u8* bmp_sprite_address(GPU* gpu, _OAM_ * spriteInfo, size sprSize, s32 y) +void GPU::spriteRender(u8 * dst, u8 * dst_alpha, u8 * typeTab, u8 * prioTab) { - u8* src; - if (spriteInfo->Mode == 3) //sprite is in BMP format - { - if (gpu->dispCnt().OBJ_BMP_mapping) - { - //tested by buffy sacrifice damage blood splatters in corner - src = (u8 *)MMU_gpu_map(gpu->sprMem + (spriteInfo->TileIndex<sprBMPBoundary) + (y*sprSize.x*2)); - } - else - { - //2d mapping: - //verified in rotozoomed mode by knights in the nightmare intro - - if (gpu->dispCnt().OBJ_BMP_2D_dim) - //256*256, verified by heroes of mana FMV intro - src = (u8 *)MMU_gpu_map(gpu->sprMem + (((spriteInfo->TileIndex&0x3E0) * 64 + (spriteInfo->TileIndex&0x1F) *8 + ( y << 8)) << 1)); - else - //128*512, verified by harry potter and the order of the phoenix conversation portraits - src = (u8 *)MMU_gpu_map(gpu->sprMem + (((spriteInfo->TileIndex&0x3F0) * 64 + (spriteInfo->TileIndex&0x0F) *8 + ( y << 7)) << 1)); - } - } - - return src; + if(spriteRenderMode == SPRITE_1D) + _spriteRender(dst,dst_alpha,typeTab, prioTab); + else + _spriteRender(dst,dst_alpha,typeTab, prioTab); } +//TODO - refactor this so there isnt as much duped code between rotozoomed and non-rotozoomed versions template void GPU::_spriteRender(u8 * dst, u8 * dst_alpha, u8 * typeTab, u8 * prioTab) @@ -1815,7 +1849,6 @@ void GPU::_spriteRender(u8 * dst, u8 * dst_alpha, u8 * typeTab, u8 * prioTab) prio = spriteInfo->Priority; - if (spriteInfo->RotScale & 1) { s32 fieldX, fieldY, auxX, auxY, realX, realY, offset; @@ -1893,7 +1926,11 @@ void GPU::_spriteRender(u8 * dst, u8 * dst_alpha, u8 * typeTab, u8 * prioTab) // If we are using 1 palette of 256 colours if(spriteInfo->Depth) { - src = (u8 *)MMU_gpu_map(gpu->sprMem + (spriteInfo->TileIndex << block)); + //2d: src = (u8 *)MMU_RenderMapToLCD(gpu->sprMem + ((spriteInfo->TileIndex) << 5)); + src = (u8 *)MMU_RenderMapToLCD(gpu->sprMem + (spriteInfo->TileIndex << block)); + if (!src) { + continue; + } // If extended palettes are set, use them if (dispCnt->ExOBJPalette_Enable) @@ -1936,7 +1973,15 @@ void GPU::_spriteRender(u8 * dst, u8 * dst_alpha, u8 * typeTab, u8 * prioTab) // Rotozoomed direct color else if(spriteInfo->Mode == 3) { - src = bmp_sprite_address(this,spriteInfo,sprSize,0); + if (dispCnt->OBJ_BMP_mapping) + src = (u8 *)MMU_RenderMapToLCD(gpu->sprMem + (spriteInfo->TileIndex<sprMem + (((spriteInfo->TileIndex&0x03E0) * 8) + (spriteInfo->TileIndex&0x001F))*16); + + if (!src) { + continue; + } for(j = 0; j < lg; ++j, ++sprX) { @@ -1944,18 +1989,11 @@ void GPU::_spriteRender(u8 * dst, u8 * dst_alpha, u8 * typeTab, u8 * prioTab) auxX = (realX>>8); auxY = (realY>>8); - //this is all very slow, and so much dup code with other rotozoomed modes. - //dont bother fixing speed until this whole thing gets reworked - if (auxX >= 0 && auxY >= 0 && auxX < sprSize.x && auxY < sprSize.y) { - if(dispCnt->OBJ_BMP_2D_dim) - //tested by knights in the nightmare - offset = (bmp_sprite_address(this,spriteInfo,sprSize,auxY)-src)/2+auxX; - else //tested by lego indiana jones (somehow?) - //tested by buffy sacrifice damage blood splatters in corner - offset = auxX + (auxY*sprSize.x); - + //if(MODE == SPRITE_2D) //tested by buffy sacrifice damage blood splatters in corner + //else //tested by lego indiana jones + offset = auxX + (auxY*sprSize.x); colour = T1ReadWord (src, offset<<1); @@ -1981,15 +2019,19 @@ void GPU::_spriteRender(u8 * dst, u8 * dst_alpha, u8 * typeTab, u8 * prioTab) { if(MODE == SPRITE_2D) { - src = (u8 *)MMU_gpu_map(gpu->sprMem + (spriteInfo->TileIndex<<5)); + src = (u8 *)MMU_RenderMapToLCD(gpu->sprMem + (spriteInfo->TileIndex<<5)); pal = ARM9Mem.ARM9_VMEM + 0x200 + (gpu->core*0x400 + (spriteInfo->PaletteIndex*32)); } else { - src = (u8 *)MMU_gpu_map(gpu->sprMem + (spriteInfo->TileIndex<sprBoundary)); + src = (u8 *)MMU_RenderMapToLCD(gpu->sprMem + (spriteInfo->TileIndex<sprBoundary)); pal = ARM9Mem.ARM9_VMEM + 0x200 + gpu->core*0x400 + (spriteInfo->PaletteIndex*32); } + if (!src) { + continue; + } + for(j = 0; j < lg; ++j, ++sprX) { // Get the integer part of the fixed point 8.8, and check if it lies inside the sprite data @@ -2040,30 +2082,53 @@ void GPU::_spriteRender(u8 * dst, u8 * dst_alpha, u8 * typeTab, u8 * prioTab) if(MODE == SPRITE_2D) { if (spriteInfo->Depth) - src = (u8 *)MMU_gpu_map(gpu->sprMem + ((spriteInfo->TileIndex)<<5) + ((y>>3)<<10) + ((y&0x7)*8)); + src = (u8 *)MMU_RenderMapToLCD(gpu->sprMem + ((spriteInfo->TileIndex)<<5) + ((y>>3)<<10) + ((y&0x7)*8)); else - src = (u8 *)MMU_gpu_map(gpu->sprMem + ((spriteInfo->TileIndex)<<5) + ((y>>3)<<10) + ((y&0x7)*4)); + src = (u8 *)MMU_RenderMapToLCD(gpu->sprMem + ((spriteInfo->TileIndex)<<5) + ((y>>3)<<10) + ((y&0x7)*4)); } else { if (spriteInfo->Depth) - src = (u8 *)MMU_gpu_map(gpu->sprMem + (spriteInfo->TileIndex<>3)*sprSize.x*8) + ((y&0x7)*8)); + src = (u8 *)MMU_RenderMapToLCD(gpu->sprMem + (spriteInfo->TileIndex<>3)*sprSize.x*8) + ((y&0x7)*8)); else - src = (u8 *)MMU_gpu_map(gpu->sprMem + (spriteInfo->TileIndex<>3)*sprSize.x*4) + ((y&0x7)*4)); + src = (u8 *)MMU_RenderMapToLCD(gpu->sprMem + (spriteInfo->TileIndex<>3)*sprSize.x*4) + ((y&0x7)*4)); + } + if (!src) { + continue; } render_sprite_Win (gpu, l, src, spriteInfo->Depth, lg, sprX, x, xdir); continue; } - if (spriteInfo->Mode == 3) //sprite is in BMP format + if (spriteInfo->Mode == 3) /* sprite is in BMP format */ { - src = bmp_sprite_address(this,spriteInfo,sprSize, y); //transparent (i think, dont bother to render?) if alpha is 0 if(spriteInfo->PaletteIndex == 0) continue; + + if (dispCnt->OBJ_BMP_mapping) + { + //tested by buffy sacrifice damage blood splatters in corner + src = (u8 *)MMU_RenderMapToLCD(gpu->sprMem + (spriteInfo->TileIndex<OBJ_BMP_2D_dim) + //256*256, verified by heroes of mana FMV intro + src = (u8 *)MMU_RenderMapToLCD(gpu->sprMem + (((spriteInfo->TileIndex&0x3E0) * 64 + (spriteInfo->TileIndex&0x1F) *8 + ( y << 8)) << 1)); + else + //128*512, verified by harry potter and the order of the phoenix conversation portraits + src = (u8 *)MMU_RenderMapToLCD(gpu->sprMem + (((spriteInfo->TileIndex&0x3F0) * 64 + (spriteInfo->TileIndex&0x0F) *8 + ( y << 7)) << 1)); + } + if (!src) { + continue; + } + render_sprite_BMP (gpu, i, l, dst, (u16*)src, dst_alpha, typeTab, prioTab, prio, lg, sprX, x, xdir, spriteInfo->PaletteIndex); continue; } @@ -2071,10 +2136,14 @@ void GPU::_spriteRender(u8 * dst, u8 * dst_alpha, u8 * typeTab, u8 * prioTab) if(spriteInfo->Depth) /* 256 colors */ { if(MODE == SPRITE_2D) - src = (u8 *)MMU_gpu_map(gpu->sprMem + ((spriteInfo->TileIndex)<<5) + ((y>>3)<<10) + ((y&0x7)*8)); + src = (u8 *)MMU_RenderMapToLCD(gpu->sprMem + ((spriteInfo->TileIndex)<<5) + ((y>>3)<<10) + ((y&0x7)*8)); else - src = (u8 *)MMU_gpu_map(gpu->sprMem + (spriteInfo->TileIndex<>3)*sprSize.x*8) + ((y&0x7)*8)); + src = (u8 *)MMU_RenderMapToLCD(gpu->sprMem + (spriteInfo->TileIndex<>3)*sprSize.x*8) + ((y&0x7)*8)); + if (!src) { + continue; + } + if (dispCnt->ExOBJPalette_Enable) pal = (u16*)(ARM9Mem.ObjExtPal[gpu->core][0]+(spriteInfo->PaletteIndex*0x200)); else @@ -2088,13 +2157,17 @@ void GPU::_spriteRender(u8 * dst, u8 * dst_alpha, u8 * typeTab, u8 * prioTab) // 16 colors if(MODE == SPRITE_2D) { - src = (u8 *)MMU_gpu_map(gpu->sprMem + ((spriteInfo->TileIndex)<<5) + ((y>>3)<<10) + ((y&0x7)*4)); + src = (u8 *)MMU_RenderMapToLCD(gpu->sprMem + ((spriteInfo->TileIndex)<<5) + ((y>>3)<<10) + ((y&0x7)*4)); } else { - src = (u8 *)MMU_gpu_map(gpu->sprMem + (spriteInfo->TileIndex<>3)*sprSize.x*4) + ((y&0x7)*4)); + src = (u8 *)MMU_RenderMapToLCD(gpu->sprMem + (spriteInfo->TileIndex<>3)*sprSize.x*4) + ((y&0x7)*4)); } - + + if (!src) { + continue; + } + pal = (u16*)(ARM9Mem.ARM9_VMEM + 0x200 + gpu->core * 0x400); pal += (spriteInfo->PaletteIndex<<4); @@ -2119,7 +2192,7 @@ int Screen_Init(int coreid) MainScreen.gpu = GPU_Init(0); SubScreen.gpu = GPU_Init(1); - memset(GPU_screen, 0, sizeof(GPU_screen)); + memset(GPU_tempScreen, 0, sizeof(GPU_tempScreen)); for(int i = 0; i < (256*192*2); i++) ((u16*)GPU_screen)[i] = 0x7FFF; disp_fifo.head = disp_fifo.tail = 0; @@ -2135,7 +2208,7 @@ void Screen_Reset(void) GPU_Reset(MainScreen.gpu, 0); GPU_Reset(SubScreen.gpu, 1); - memset(GPU_screen, 0, sizeof(GPU_screen)); + memset(GPU_tempScreen, 0, sizeof(GPU_tempScreen)); for(int i = 0; i < (256*192*2); i++) ((u16*)GPU_screen)[i] = 0x7FFF; @@ -2257,6 +2330,15 @@ void GPU_set_DISPCAPCNT(u32 val) gpu->dispCapCnt.srcB = (val >> 25) & 0x01; gpu->dispCapCnt.capSrc = (val >> 29) & 0x03; + gpu->dispCapCnt.dst = (ARM9Mem.ARM9_LCD + + (gpu->dispCapCnt.writeBlock * 0x20000) + + (gpu->dispCapCnt.writeOffset * 0x8000) + ); + gpu->dispCapCnt.src = (ARM9Mem.ARM9_LCD + + (gpu->dispCapCnt.readBlock * 0x20000) + + (gpu->dispCapCnt.readOffset * 0x8000) + ); + switch((val >> 20) & 0x03) { case 0: @@ -2283,49 +2365,33 @@ void GPU_set_DISPCAPCNT(u32 val) gpu->dispCapCnt.capSrc, gpu->dispCapCnt.dst - ARM9Mem.ARM9_LCD, gpu->dispCapCnt.src - ARM9Mem.ARM9_LCD, gpu->dispCapCnt.srcA, gpu->dispCapCnt.srcB);*/ } +// #define BRIGHT_TABLES + static void GPU_ligne_layer(NDS_Screen * screen, u16 l) { - CACHE_ALIGN u8 spr[512]; - CACHE_ALIGN u8 sprAlpha[256]; - CACHE_ALIGN u8 sprType[256]; - CACHE_ALIGN u8 sprPrio[256]; - GPU * gpu = screen->gpu; struct _DISPCNT * dispCnt = &(gpu->dispx_st)->dispx_DISPCNT.bits; itemsForPriority_t * item; + u8 spr[512]; + u8 sprAlpha[256]; + u8 sprType[256]; + u8 sprPrio[256]; + u8 prio; u16 i16; BOOL BG_enabled = TRUE; - gpu->currentFadeInColors = &fadeInColors[gpu->BLDY_EVY][0]; - gpu->currentFadeOutColors = &fadeOutColors[gpu->BLDY_EVY][0]; - u16 backdrop_color = T1ReadWord(ARM9Mem.ARM9_VMEM, gpu->core * 0x400) & 0x7FFF; //we need to write backdrop colors in the same way as we do BG pixels in order to do correct window processing //this is currently eating up 2fps or so. it is a reasonable candidate for optimization. gpu->currBgNum = 5; - switch(gpu->setFinalColorBck_funcNum) { - case 0: case 1: //for backdrops, (even with window enabled) none and blend are both the same: just copy the color - memset_u16_le<256>(gpu->currDst,backdrop_color); - break; - case 2: - //for non-windowed fade, we can just fade the color and fill - memset_u16_le<256>(gpu->currDst,gpu->currentFadeInColors[backdrop_color]); - break; - case 3: - //likewise for non-windowed fadeout - memset_u16_le<256>(gpu->currDst,gpu->currentFadeOutColors[backdrop_color]); - break; - - //windowed fades need special treatment - case 4: for(int x=0;x<256;x++) gpu->___setFinalColorBck(backdrop_color,x,1); break; - case 5: for(int x=0;x<256;x++) gpu->___setFinalColorBck(backdrop_color,x,1); break; - case 6: for(int x=0;x<256;x++) gpu->___setFinalColorBck(backdrop_color,x,1); break; - case 7: for(int x=0;x<256;x++) gpu->___setFinalColorBck(backdrop_color,x,1); break; + for(int x=0;x<256;x++) { + gpu->__setFinalColorBck(backdrop_color,x,1); } - - memset(gpu->bgPixels,5,256); + + //this check isnt really helpful. it just slows us down in the cases where we need the most speed + //if (!gpu->LayersEnable[0] && !gpu->LayersEnable[1] && !gpu->LayersEnable[2] && !gpu->LayersEnable[3] && !gpu->LayersEnable[4]) return; // init background color & priorities memset(sprAlpha, 0, 256); @@ -2334,12 +2400,10 @@ static void GPU_ligne_layer(NDS_Screen * screen, u16 l) memset(sprWin, 0, 256); // init pixels priorities - assert(NB_PRIORITIES==4); - gpu->itemsForPriority[0].nbPixelsX = 0; - gpu->itemsForPriority[1].nbPixelsX = 0; - gpu->itemsForPriority[2].nbPixelsX = 0; - gpu->itemsForPriority[3].nbPixelsX = 0; - + for (int i=0; iitemsForPriority[i].nbPixelsX = 0; + } + // for all the pixels in the line if (gpu->LayersEnable[4]) { @@ -2349,6 +2413,7 @@ static void GPU_ligne_layer(NDS_Screen * screen, u16 l) //zero 06-may-09: I properly supported window color effects for backdrop, but I am not sure //how it interacts with this. I wish we knew why we needed this + gpu->spriteRender(spr, sprAlpha, sprType, sprPrio); mosaicSpriteLine(gpu, l, spr, sprAlpha, sprType, sprPrio); @@ -2356,7 +2421,7 @@ static void GPU_ligne_layer(NDS_Screen * screen, u16 l) for(int i = 0; i<256; i++) { // assign them to the good priority item - int prio = sprPrio[i]; + prio = sprPrio[i]; if (prio >=4) continue; item = &(gpu->itemsForPriority[prio]); @@ -2369,12 +2434,9 @@ static void GPU_ligne_layer(NDS_Screen * screen, u16 l) if (!gpu->LayersEnable[0] && !gpu->LayersEnable[1] && !gpu->LayersEnable[2] && !gpu->LayersEnable[3]) BG_enabled = FALSE; - for(int j=0;j<8;j++) - gpu->blend2[j] = (gpu->BLDCNT & (0x100 << j)); - // paint lower priorities fist // then higher priorities on top - for(int prio=NB_PRIORITIES; prio > 0; ) + for(prio=NB_PRIORITIES; prio > 0; ) { prio--; item = &(gpu->itemsForPriority[prio]); @@ -2388,10 +2450,18 @@ static void GPU_ligne_layer(NDS_Screen * screen, u16 l) { gpu->currBgNum = i16; gpu->blend1 = gpu->BLDCNT & (1 << gpu->currBgNum); + for(int i=0;i<8;i++) + gpu->blend2[i] = (gpu->BLDCNT & (0x100 << i)); + gpu->currentFadeInColors = &fadeInColors[gpu->BLDY_EVY][0]; + gpu->currentFadeOutColors = &fadeOutColors[gpu->BLDY_EVY][0]; + //gpu->bgFunc = gpu->setFinalColorBck_funcNum; struct _BGxCNT *bgCnt = &(gpu->dispx_st)->dispx_BGxCNT[i16].bits; gpu->curr_mosaic_enabled = bgCnt->Mosaic_Enable; + //mosaic test hacks + //gpu->curr_mosaic_enabled = true; + if (gpu->core == GPU_MAIN) { if (i16 == 0 && dispCnt->BG0_3D) @@ -2420,7 +2490,7 @@ static void GPU_ligne_layer(NDS_Screen * screen, u16 l) } //useful for debugging individual layers - //if(gpu->core == 1 || i16 != 2) continue; + //if(gpu->core == 0 && i16 != 1) continue; if(gpu->curr_mosaic_enabled) gpu->modeRender(i16); @@ -2433,18 +2503,23 @@ static void GPU_ligne_layer(NDS_Screen * screen, u16 l) if (gpu->LayersEnable[4]) { gpu->currBgNum = 4; - gpu->blend1 = gpu->BLDCNT & (1 << gpu->currBgNum); - + ////analyze mosaic configuration + //u16 mosaic_control = T1ReadWord((u8 *)&gpu->dispx_st->dispx_MISC.MOSAIC, 0); + //gpu->curr_mosaic_enabled + for (int i=0; i < item->nbPixelsX; i++) { i16=item->PixelsX[i]; - setFinalColorSpr(gpu, gpu->currDst, T2ReadWord(spr, (i16<<1)), sprAlpha[i16], sprType[i16], i16); + // T2WriteWord(dst, i16 << 1, T2ReadWord(spr, i16 << 1)); + // gpu->bgPixels[i16] = 4; + gpu->setFinalColorSpr(gpu, (i16<<1), gpu->currDst, T2ReadWord(spr, (i16<<1)), sprAlpha[i16], sprType[i16], i16); } } } } -template static void GPU_ligne_DispCapture(u16 l) +// TODO: capture emulated not fully +static void GPU_ligne_DispCapture(u16 l) { //this macro takes advantage of the fact that there are only two possible values for capx #define CAPCOPY(SRC,DST) \ @@ -2471,38 +2546,14 @@ template static void GPU_ligne_DispCapture(u16 l) } } - bool skip = SKIP; - if (gpu->dispCapCnt.enabled) { - //128-wide captures should write linearly into memory, with no gaps - //this is tested by hotel dusk - u32 ofsmul = gpu->dispCapCnt.capx==DISPCAPCNT::_128?256:512; - u32 cap_src_adr = gpu->dispCapCnt.readOffset * 0x8000 + (l * 512); - u32 cap_dst_adr = gpu->dispCapCnt.writeOffset * 0x8000 + (l * ofsmul); + u8 *cap_dst = (u8 *)(gpu->dispCapCnt.dst) + (l * 512); - //Read/Write block wrap to 00000h when exceeding 1FFFFh (128k) - //this has not been tested yet (I thought I needed it for hotel dusk, but it was fixed by the above) - cap_src_adr &= 0x1FFFF; - cap_dst_adr &= 0x1FFFF; - - cap_src_adr += gpu->dispCapCnt.readBlock * 0x20000; - cap_dst_adr += gpu->dispCapCnt.writeBlock * 0x20000; - - u8* cap_src = ARM9Mem.ARM9_LCD + cap_src_adr; - u8* cap_dst = ARM9Mem.ARM9_LCD + cap_dst_adr; - - //we must block captures when the capture dest is not mapped to LCDC - if(vramConfiguration.banks[gpu->dispCapCnt.writeBlock].purpose != VramConfiguration::LCDC) - skip = true; - - //we must return zero from reads from memory not mapped to lcdc - if(vramConfiguration.banks[gpu->dispCapCnt.readBlock].purpose != VramConfiguration::LCDC) - cap_src = ARM9Mem.blank_memory; - - if(!skip) if (l < gpu->dispCapCnt.capy) { + // TODO: Read/Write block wrap to 00000h when exceeding 1FFFFh (128k) + switch (gpu->dispCapCnt.capSrc) { case 0: // Capture source is SourceA @@ -2538,7 +2589,8 @@ template static void GPU_ligne_DispCapture(u16 l) case 0: // Capture VRAM { //INFO("Capture VRAM\n"); - CAPCOPY(cap_src,cap_dst); + u8 *src = (u8 *)(gpu->dispCapCnt.src) + (l * 512); + CAPCOPY(src,cap_dst); } break; case 1: // Capture Main Memory Display FIFO @@ -2566,31 +2618,27 @@ template static void GPU_ligne_DispCapture(u16 l) } if (gpu->dispCapCnt.srcB == 0) // VRAM screen - srcB = (u16 *)cap_src; + srcB = (u16 *)((gpu->dispCapCnt.src) + (l * 512)); else srcB = NULL; // DISP FIFOS if ((srcA) && (srcB)) { + u16 a, r, g, b; const int todo = (gpu->dispCapCnt.capx==DISPCAPCNT::_128?128:256); for(u16 i = 0; i < todo; i++) { - u16 a,r,g,b; + a = r = g = b =0; - u16 a_alpha = srcA[i] & 0x8000; - u16 b_alpha = srcB[i] & 0x8000; - - if (gpu->dispCapCnt.EVA && a_alpha) + if (gpu->dispCapCnt.EVA && (srcA[i] & 0x8000)) { a = 0x8000; r = ((srcA[i] & 0x1F) * gpu->dispCapCnt.EVA); g = (((srcA[i] >> 5) & 0x1F) * gpu->dispCapCnt.EVA); b = (((srcA[i] >> 10) & 0x1F) * gpu->dispCapCnt.EVA); - } - else - a = r = g = b = 0; + } - if (gpu->dispCapCnt.EVB && b_alpha) + if (gpu->dispCapCnt.EVB && (srcB[i] & 0x8000)) { a = 0x8000; r += ((srcB[i] & 0x1F) * gpu->dispCapCnt.EVB); @@ -2602,7 +2650,7 @@ template static void GPU_ligne_DispCapture(u16 l) g >>= 4; b >>= 4; - T2WriteWord(cap_dst, i << 1, a | (b << 10) | (g << 5) | r); + T2WriteWord(cap_dst, i << 1, (u16)(a | (b << 10) | (g << 5) | r)); } } } @@ -2624,7 +2672,7 @@ static INLINE void GPU_ligne_MasterBrightness(NDS_Screen * screen, u16 l) { GPU * gpu = screen->gpu; - u8 * dst = GPU_screen + (screen->offset + l) * 512; + u8 * dst = GPU_tempScreen + (screen->offset + l) * 512; u16 i16; //isn't it odd that we can set uselessly high factors here? @@ -2634,8 +2682,10 @@ static INLINE void GPU_ligne_MasterBrightness(NDS_Screen * screen, u16 l) if(factor>16) factor=16; - //Apply final brightness adjust (MASTER_BRIGHT) - //http://nocash.emubase.de/gbatek.htm#dsvideo (Under MASTER_BRIGHTNESS) +// Apply final brightness adjust (MASTER_BRIGHT) +// Reference: http://nocash.emubase.de/gbatek.htm#dsvideo (Under MASTER_BRIGHTNESS) +/* Mightymax> it should be more effective if the windowmanager applies brightness when drawing */ +/* it will most likly take acceleration, while we are stuck here with CPU power */ switch (gpu->MasterBrightMode) { @@ -2756,7 +2806,7 @@ void GPU::update_winh(int WIN_NUM) } } -void GPU_ligne(NDS_Screen * screen, u16 l, bool skip) +void GPU_ligne(NDS_Screen * screen, u16 l) { GPU * gpu = screen->gpu; @@ -2776,27 +2826,16 @@ void GPU_ligne(NDS_Screen * screen, u16 l, bool skip) gpu->refreshAffineStartRegs(-1,-1); } - if(skip) - { - gpu->currLine = l; - if (gpu->core == GPU_MAIN) - { - GPU_ligne_DispCapture(l); - if (l == 191) { disp_fifo.head = disp_fifo.tail = 0; } - } - return; - } - //blacken the screen if it is turned off by the user if(!CommonSettings.showGpu.screens[gpu->core]) { - u8 * dst = GPU_screen + (screen->offset + l) * 512; + u8 * dst = GPU_tempScreen + (screen->offset + l) * 512; memset(dst,0,512); return; } //cache some parameters which are assumed to be stable throughout the rendering of the entire line - gpu->currLine = l; + gpu->currLine = (u8)l; u16 mosaic_control = T1ReadWord((u8 *)&gpu->dispx_st->dispx_MISC.MOSAIC, 0); u16 mosaic_width = (mosaic_control & 0xF); u16 mosaic_height = ((mosaic_control>>4) & 0xF); @@ -2817,12 +2856,12 @@ void GPU_ligne(NDS_Screen * screen, u16 l, bool skip) //always generate the 2d+3d, no matter what we're displaying, since we may need to capture it //(if this seems inefficient in some cases, consider that the speed in those cases is not really a problem) - GPU_tempScanline = screen->gpu->currDst = (u8 *)(GPU_screen) + (screen->offset + l) * 512; + GPU_tempScanline = screen->gpu->currDst = (u8 *)(GPU_tempScreen) + (screen->offset + l) * 512; GPU_ligne_layer(screen, l); if (gpu->core == GPU_MAIN) { - GPU_ligne_DispCapture(l); + GPU_ligne_DispCapture(l); if (l == 191) { disp_fifo.head = disp_fifo.tail = 0; } } @@ -2830,7 +2869,7 @@ void GPU_ligne(NDS_Screen * screen, u16 l, bool skip) { case 0: // Display Off(Display white) { - u8 * dst = GPU_screen + (screen->offset + l) * 512; + u8 * dst = GPU_tempScreen + (screen->offset + l) * 512; for (int i=0; i<256; i++) T2WriteWord(dst, i << 1, 0x7FFF); @@ -2843,20 +2882,21 @@ void GPU_ligne(NDS_Screen * screen, u16 l, bool skip) case 2: // Display framebuffer { - u8 * dst = GPU_screen + (screen->offset + l) * 512; + u8 * dst = GPU_tempScreen + (screen->offset + l) * 512; u8 * src = gpu->VRAMaddr + (l*512); memcpy (dst, src, 512); } break; case 3: // Display memory FIFO { - u8 * dst = GPU_screen + (screen->offset + l) * 512; + u8 * dst = GPU_tempScreen + (screen->offset + l) * 512; for (int i=0; i < 128; i++) T1WriteLong(dst, i << 2, DISP_FIFOrecv() & 0x7FFF7FFF); } break; } + GPU_ligne_MasterBrightness(screen, l); } @@ -2984,8 +3024,8 @@ template void GPU::modeRender(int layer) void gpu_UpdateRender() { - /*int x = 0, y = 0; - u16 *src = (u16*)GPU_screen; + int x = 0, y = 0; + u16 *src = (u16*)GPU_tempScreen; u16 *dst = (u16*)GPU_screen; switch (gpu_angle) @@ -3022,7 +3062,7 @@ void gpu_UpdateRender() } default: break; - }*/ + } } void gpu_SetRotateScreen(u16 angle) diff --git a/desmume/src/GPU.h b/src/GPU.h similarity index 92% rename from desmume/src/GPU.h rename to src/GPU.h index 4ba9f2788..b535a27c7 100644 --- a/desmume/src/GPU.h +++ b/src/GPU.h @@ -32,6 +32,7 @@ #include "registers.h" #include "FIFO.h" #include "MMU.h" +#include "GPU_osd.h" #include //#undef FORCEINLINE @@ -123,10 +124,6 @@ typedef union #define BGxENABLED(cnt,num) ((num<8)? ((cnt.val>>8) & num):0) -enum BlendFunc -{ - None, Blend, Increase, Decrease -}; /******************************************************************************* @@ -353,18 +350,20 @@ struct DISPCAPCNT enum CAPX { _128, _256 } capx; - u32 val; - BOOL enabled; - u8 EVA; - u8 EVB; - u8 writeBlock; - u8 writeOffset; - u16 capy; - u8 srcA; - u8 srcB; - u8 readBlock; - u8 readOffset; - u8 capSrc; + u32 val; + BOOL enabled; + u8 EVA; + u8 EVB; + u8 writeBlock; + u8 writeOffset; + u16 capy; + u8 srcA; + u8 srcB; + u8 readBlock; + u8 readOffset; + u8 capSrc; + u8 *dst; + u8 *src; } ; /******************************************************************************* @@ -605,19 +604,10 @@ typedef struct #define NB_BG 4 typedef struct { - u8 PixelsX[256]; u8 BGs[NB_BG], nbBGs; - u8 pad[1]; + u8 PixelsX[256]; + // doh ! yoda says : 256 pixels we can have... u16 nbPixelsX; - //256+8: - u8 pad2[248]; - - //things were slower when i organized this struct this way. whatever. - //u8 PixelsX[256]; - //int BGs[NB_BG], nbBGs; - //int nbPixelsX; - ////<-- 256 + 24 - //u8 pad2[256-24]; } itemsForPriority_t; #define ARM9MEM_ABG 0x06000000 #define ARM9MEM_BBG 0x06200000 @@ -739,9 +729,9 @@ struct GPU u8 MasterBrightMode; u32 MasterBrightFactor; - CACHE_ALIGN u8 bgPixels[1024]; //yes indeed, this is oversized. map debug tools try to write to it + u8 bgPixels[256]; - u32 currLine; + u8 currLine; u8 currBgNum; bool blend1; u8* currDst; @@ -774,13 +764,13 @@ struct GPU u16 blend(u16 colA, u16 colB); - template - FORCEINLINE FASTCALL bool _master_setFinalBGColor(u16 &color, const u32 x); + typedef void (*FinalOBJColFunct)(GPU *gpu, u32 passing, u8 *dst, u16 color, u8 alpha, u8 type, u16 x); + typedef void (*Final3DColFunct)(GPU *gpu, int dstX, int srcX); int setFinalColorBck_funcNum; int bgFunc; int setFinalColor3d_funcNum; - int setFinalColorSpr_funcNum; + FinalOBJColFunct setFinalColorSpr; //Final3DColFunct setFinalColor3D; enum SpriteRenderMode { SPRITE_1D, SPRITE_2D @@ -788,27 +778,19 @@ struct GPU template void _spriteRender(u8 * dst, u8 * dst_alpha, u8 * typeTab, u8 * prioTab); - - inline void spriteRender(u8 * dst, u8 * dst_alpha, u8 * typeTab, u8 * prioTab) - { - if(spriteRenderMode == SPRITE_1D) - _spriteRender(dst,dst_alpha,typeTab, prioTab); - else - _spriteRender(dst,dst_alpha,typeTab, prioTab); - } + void spriteRender(u8 * dst, u8 * dst_alpha, u8 * typeTab, u8 * prioTab); - - template void setFinalColorBG(u16 color, const u32 x); + void setFinalColorBG(u16 color, u8 x); void setFinalColor3d(int dstX, int srcX); - template FORCEINLINE void setFinalBGColorSpecialNone(u16 &color, const u32 x); - template FORCEINLINE void setFinalBGColorSpecialBlend(u16 &color, const u32 x); - template FORCEINLINE void setFinalBGColorSpecialIncrease(u16 &color, const u32 x); - template FORCEINLINE void setFinalBGColorSpecialDecrease(u16 &color, const u32 x); - template FORCEINLINE bool setFinalBGColorSpecialNoneWnd(u16 &color, const u32 x); - template FORCEINLINE bool setFinalBGColorSpecialBlendWnd(u16 &color, const u32 x); - template FORCEINLINE bool setFinalBGColorSpecialIncreaseWnd(u16 &color, const u32 x); - template FORCEINLINE bool setFinalBGColorSpecialDecreaseWnd(u16 &color, const u32 x); + FORCEINLINE void setFinalBGColorSpecialNone(u16 &color, u8 x); + FORCEINLINE void setFinalBGColorSpecialBlend(u16 &color, u8 x); + FORCEINLINE void setFinalBGColorSpecialIncrease(u16 &color, u8 x); + FORCEINLINE void setFinalBGColorSpecialDecrease(u16 &color, u8 x); + FORCEINLINE bool setFinalBGColorSpecialNoneWnd(u16 &color, u8 x); + FORCEINLINE bool setFinalBGColorSpecialBlendWnd(u16 &color, u8 x); + FORCEINLINE bool setFinalBGColorSpecialIncreaseWnd(u16 &color, u8 x); + FORCEINLINE bool setFinalBGColorSpecialDecreaseWnd(u16 &color, u8 x); FORCEINLINE void setFinal3DColorSpecialNone(int dstX, int srcX); FORCEINLINE void setFinal3DColorSpecialBlend(int dstX, int srcX); @@ -820,8 +802,7 @@ struct GPU FORCEINLINE void setFinal3DColorSpecialDecreaseWnd(int dstX, int srcX); - template FORCEINLINE void __setFinalColorBck(u16 color, const u32 x, const int opaque); - template FORCEINLINE void ___setFinalColorBck(u16 color, const u32 x, const int opaque); + template void __setFinalColorBck(u16 color, const u8 x, const bool opaque); void setAffineStart(int layer, int xy, u32 val); void setAffineStartWord(int layer, int xy, u16 val, int word); u32 getAffineStart(int layer, int xy); @@ -887,6 +868,7 @@ static void REG_DISPx_pack_test(GPU * gpu) #endif CACHE_ALIGN extern u8 GPU_screen[4*256*192]; +CACHE_ALIGN extern u8 GPU_tempScreen[4*256*192]; GPU * GPU_Init(u8 l); @@ -953,7 +935,7 @@ void GPU_addBack(GPU *, u8 num); int GPU_ChangeGraphicsCore(int coreid); void GPU_set_DISPCAPCNT(u32 val) ; -void GPU_ligne(NDS_Screen * screen, u16 l, bool skip = false) ; +void GPU_ligne(NDS_Screen * screen, u16 l) ; void GPU_setMasterBrightness (GPU *gpu, u16 val); inline void GPU_setWIN0_H(GPU* gpu, u16 val) { gpu->WIN0H0 = val >> 8; gpu->WIN0H1 = val&0xFF; gpu->need_update_winh[0] = true; } @@ -1011,5 +993,7 @@ void gpu_SetRotateScreen(u16 angle); //#undef FORCEINLINE //#define FORCEINLINE __forceinline +extern OSDCLASS *osd; + #endif diff --git a/src/GPU_osd.cpp b/src/GPU_osd.cpp new file mode 100644 index 000000000..3696e3c1d --- /dev/null +++ b/src/GPU_osd.cpp @@ -0,0 +1,267 @@ +/* Copyright (C) 2006 yopyop + yopyop156@ifrance.com + yopyop156.ifrance.com + + Copyright (C) 2006-2008 DeSmuME team + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#include "GPU_osd.h" +#include "GPU.h" +#include "mem.h" +#include //mem funcs +#include //va_start, etc +#include +#include "debug.h" + +#include "softrender.h" + +#include "softrender_v3sysfont.h" +#include "softrender_desmumefont.h" + +using namespace softrender; + +image screenshell; + +OSDCLASS::OSDCLASS(u8 core) +{ + memset(screen, 0, sizeof(screen)); + memset(name,0,7); + + mode=core; + offset=0; + + lastLineText=0; + lineText_x = 5; + lineText_y = 120; + lineText_color = render51.MakeColor(255, 255, 255); + for (int i=0; i < OSD_MAX_LINES+1; i++) + { + lineText[i] = new char[1024]; + memset(lineText[i], 0, 1024); + lineTimer[i] = 0; + lineColor[i] = lineText_color; + } + + rotAngle = 0; + + needUpdate = false; + + if (core==0) + strcpy(name,"Core A"); + else + if (core==1) + strcpy(name,"Core B"); + else + { + strcpy(name,"Main"); + mode=255; + } + + screenshell.shell = true; + screenshell.data = screen; + screenshell.bpp = 15; + screenshell.width = 256; + screenshell.height = 384; + screenshell.pitch = 256; + screenshell.cx1 = 0; + screenshell.cx2 = 256-1; + screenshell.cy1 = 0; + screenshell.cy2 = 384-1; + + border(false); + + LOG("OSD_Init (%s)\n",name); +} + +OSDCLASS::~OSDCLASS() +{ + LOG("OSD_Deinit (%s)\n",name); + + for (int i=0; i < OSD_MAX_LINES+1; i++) + { + if (lineText[i]) + delete [] lineText[i]; + lineText[i] = NULL; + } +} + +void OSDCLASS::setOffset(u16 ofs) +{ + offset=ofs; +} + +void OSDCLASS::setRotate(u16 angle) +{ + rotAngle = angle; + + switch(rotAngle) + { + case 0: + case 180: + { + screenshell.width = 256; + screenshell.height = 384; + screenshell.pitch = 256; + screenshell.cx1 = 0; + screenshell.cx2 = 255; + screenshell.cy1 = 0; + screenshell.cy2 = 383; + } + break; + case 90: + case 270: + { + screenshell.width = 384; + screenshell.height = 256; + screenshell.pitch = 384; + screenshell.cx1 = 0; + screenshell.cx2 = 383; + screenshell.cy1 = 0; + screenshell.cy2 = 255; + } + break; + } +} + +void OSDCLASS::clear() +{ + memset(screen, 0, sizeof(screen)); + needUpdate=false; +} + +bool OSDCLASS::checkTimers() +{ + if (lastLineText == 0) return false; + + time_t tmp_time = time(NULL); + + for (int i=0; i < lastLineText; i++) + { + if (tmp_time > (lineTimer[i] + OSD_TIMER_SECS) ) + { + if (i < lastLineText) + { + for (int j=i; j < lastLineText; j++) + { + strcpy(lineText[j], lineText[j+1]); + lineTimer[j] = lineTimer[j+1]; + lineColor[j] = lineColor[j+1]; + } + } + lineTimer[lastLineText] = 0; + lastLineText--; + if (lastLineText == 0) return false; + } + } + return true; +} + +void OSDCLASS::update() +{ + if ( (!needUpdate) && (!lastLineText) ) return; // don't update if buffer empty (speed up) + if (lastLineText) + { + if (checkTimers()) + { + for (int i=0; i < lastLineText; i++) + { + render51.PrintString(1,lineText_x,lineText_y+(i*16),lineColor[i],lineText[i],&screenshell); + } + } + else + { + if (!needUpdate) return; + } + } + + u16 *dst = (u16*)GPU_screen; + + if (mode!=255) + dst+=offset*512; + + for (int i=0; i<256*192*2; i++) + { + if(screen[i]&0x8000) + T2WriteWord((u8*)dst,(i << 1), screen[i] ); + } +} + +void OSDCLASS::setListCoord(u16 x, u16 y) +{ + lineText_x = x; + lineText_y = y; +} + +void OSDCLASS::setLineColor(u8 r=255, u8 b=255, u8 g=255) +{ + lineText_color = render51.MakeColor(r, g, b); +} + +void OSDCLASS::addLine(const char *fmt, ...) +{ + va_list list; + + if (lastLineText > OSD_MAX_LINES) lastLineText = OSD_MAX_LINES; + if (lastLineText == OSD_MAX_LINES) // full + { + lastLineText--; + for (int j=0; j < lastLineText; j++) + { + strcpy(lineText[j], lineText[j+1]); + lineTimer[j] = lineTimer[j+1]; + lineColor[j] = lineColor[j+1]; + } + } + + va_start(list,fmt); +#if defined(_MSC_VER) || defined(__INTEL_COMPILER) + _vsnprintf(lineText[lastLineText],1023,fmt,list); +#else + vsnprintf(lineText[lastLineText],1023,fmt,list); +#endif + va_end(list); + lineColor[lastLineText] = lineText_color; + lineTimer[lastLineText] = time(NULL); + needUpdate = true; + + lastLineText++; +} + +void OSDCLASS::addFixed(u16 x, u16 y, const char *fmt, ...) +{ + va_list list; + char msg[1024]; + + va_start(list,fmt); +#if defined(_MSC_VER) || defined(__INTEL_COMPILER) + _vsnprintf(msg,1023,fmt,list); +#else + vsnprintf(msg,1023,fmt,list); +#endif + va_end(list); + + render51.PrintString(1,x,y,render51.MakeColor(255,255,255),msg,&screenshell); + + needUpdate = true; +} + +void OSDCLASS::border(bool enabled) +{ + render51.setTextBoxBorder(enabled); +} diff --git a/desmume/src/GPU_osd.h b/src/GPU_osd.h similarity index 69% rename from desmume/src/GPU_osd.h rename to src/GPU_osd.h index fb0dc9cb0..84e7d7ec5 100644 --- a/desmume/src/GPU_osd.h +++ b/src/GPU_osd.h @@ -28,53 +28,13 @@ #include #include "types.h" -#include "aggdraw.h" - #define OSD_MAX_LINES 4 #define OSD_TIMER_SECS 2 - -struct HudCoordinates{ - int x; - int y; - int xsize; - int ysize; - int storedx; - int storedy; - int clicked; -}; - -struct HudStruct -{ -public: - HudStruct() - : fps(0) - , fps3d(0) - {} - - HudCoordinates FpsDisplay; - HudCoordinates FrameCounter; - HudCoordinates InputDisplay; - HudCoordinates LagFrameCounter; - HudCoordinates Microphone; - HudCoordinates Dummy; - - HudCoordinates &hud(int i) { return ((HudCoordinates*)this)[i]; } - - int fps, fps3d; -}; - -void ResetHud(HudStruct *hudstruct); -void EditHud(s32 x, s32 y, HudStruct *hudstruct); -void HudClickRelease(HudStruct *hudstruct); - -void DrawHUD(); - -extern HudStruct Hud; - class OSDCLASS { private: + u16 screen[256*192*2]; u64 offset; u8 mode; @@ -82,11 +42,11 @@ private: u16 lineText_x; u16 lineText_y; - AggColor lineText_color; + u32 lineText_color; u8 lastLineText; char *lineText[OSD_MAX_LINES+1]; time_t lineTimer[OSD_MAX_LINES+1]; - AggColor lineColor[OSD_MAX_LINES+1]; + u32 lineColor[OSD_MAX_LINES+1]; bool needUpdate; diff --git a/desmume/src/MMU.cpp b/src/MMU.cpp similarity index 80% rename from desmume/src/MMU.cpp rename to src/MMU.cpp index 285087d8d..4c5efa204 100644 --- a/desmume/src/MMU.cpp +++ b/src/MMU.cpp @@ -33,6 +33,9 @@ #include "common.h" #include "debug.h" #include "NDSSystem.h" +#ifndef EXPERIMENTAL_GBASLOT +#include "cflash.h" +#endif #include "cp15.h" #include "wifi.h" #include "registers.h" @@ -83,6 +86,17 @@ static u64 isqrt (u64 x) { return root; } + +static const int save_types[7][2] = { + {MC_TYPE_AUTODETECT,1}, + {MC_TYPE_EEPROM1,MC_SIZE_4KBITS}, + {MC_TYPE_EEPROM2,MC_SIZE_64KBITS}, + {MC_TYPE_EEPROM2,MC_SIZE_512KBITS}, + {MC_TYPE_FRAM,MC_SIZE_256KBITS}, + {MC_TYPE_FLASH,MC_SIZE_2MBITS}, + {MC_TYPE_FLASH,MC_SIZE_4MBITS} +}; + u16 partie = 1; u32 _MMU_MAIN_MEM_MASK = 0x3FFFFF; @@ -160,7 +174,6 @@ void mmu_log_debug_ARM7(u32 adr, const char *fmt, ...) #define DUP16(x) x, x, x, x, x, x, x, x, x, x, x, x, x, x, x, x MMU_struct MMU; -MMU_struct_new MMU_new; u8 * MMU_struct::MMU_MEM[2][256] = { //arm9 @@ -295,6 +308,21 @@ u8 vram_arm7_map[2]; //<--------- +#define VRAM_BANKS 9 +#define VRAM_BANK_A 0 +#define VRAM_BANK_B 1 +#define VRAM_BANK_C 2 +#define VRAM_BANK_D 3 +#define VRAM_BANK_E 4 +#define VRAM_BANK_F 5 +#define VRAM_BANK_G 6 +#define VRAM_BANK_H 7 +#define VRAM_BANK_I 8 + +#define VRAM_PAGE_ABG 0 +#define VRAM_PAGE_BBG 128 +#define VRAM_PAGE_AOBJ 256 +#define VRAM_PAGE_BOBJ 384 void MMU_VRAM_unmap_all(); @@ -333,9 +361,6 @@ static FORCEINLINE u32 MMU_LCDmap(u32 addr, bool& unmapped) //shared wram mapping for arm7 if(PROCNUM==ARMCPU_ARM7) { - //necessary? not sure - //addr &= 0x3FFFF; - //addr += 0x06000000; u32 ofs = addr & 0x1FFFF; u32 bank = (addr >> 17)&1; if(vram_arm7_map[bank] == VRAM_PAGE_UNMAPPED) @@ -381,37 +406,84 @@ static FORCEINLINE u32 MMU_LCDmap(u32 addr, bool& unmapped) } +u8 *MMU_RenderMapToLCD(u32 vram_addr) +{ + //THIS FUNCTION IS DANGEROUS! + //the very idea is heinous, since people are + //certainly reading several bytes which probably overrun a page or something + //this needs to go through a system like what is used for textures for mapping into chunks + + bool unmapped; + vram_addr = MMU_LCDmap<0>(vram_addr,unmapped); + if(unmapped) return 0; + else return ARM9Mem.ARM9_LCD + (vram_addr - LCDC_HACKY_LOCATION); +} + + +template +void DMAtoVRAMmapping() +{ + //THIS IS ALSO DANGEROUS!!!!!! + //but i dont think it needs to be done + + /*u32 dst = DMADst[ARMCPU_ARM9][DMA_CHANNEL]; + + bool unmapped; + dst = MMU_LCDmap(dst,unmapped); + + DMADst[ARMCPU_ARM9][DMA_CHANNEL] = dst;*/ +} + #define LOG_VRAM_ERROR() LOG("No data for block %i MST %i\n", block, VRAMBankCnt & 0x07); -VramConfiguration vramConfiguration; -std::string VramConfiguration::describePurpose(Purpose p) { - switch(p) { - case OFF: return "OFF"; - case INVALID: return "INVALID"; - case ABG: return "ABG"; - case BBG: return "BBG"; - case AOBJ: return "AOBJ"; - case BOBJ: return "BOBJ"; - case LCDC: return "LCDC"; - case ARM7: return "ARM7"; - case TEX: return "TEX"; - case TEXPAL: return "TEXPAL"; - case ABGEXTPAL: return "ABGEXTPAL"; - case BBGEXTPAL: return "BBGEXTPAL"; - case AOBJEXTPAL: return "AOBJEXTPAL"; - case BOBJEXTPAL: return "BOBJEXTPAL"; - default: return "UNHANDLED CASE"; - } -} +struct VramConfiguration { -std::string VramConfiguration::describe() { - std::stringstream ret; - for(int i=0;i @@ -1090,21 +1165,19 @@ void FASTCALL MMU_doDMA(u32 num) taille = (MMU.DMACrt[PROCNUM][num]&0x1FFFFF); if(taille == 0) taille = 0x200000; //according to gbatek.. - //THIS IS A BIG HACK // If we are in "Main memory display" mode just copy an entire // screen (256x192 pixels). // Reference: http://nocash.emubase.de/gbatek.htm#dsvideocaptureandmainmemorydisplaymode // (under DISP_MMEM_FIFO) - if ((MMU.DMAStartTime[PROCNUM][num]==EDMAMode_MemDisplay) && // Must be in main memory display mode + if ((MMU.DMAStartTime[PROCNUM][num]==4) && // Must be in main memory display mode (taille==4) && // Word must be 4 (((MMU.DMACrt[PROCNUM][num]>>26)&1) == 1)) // Transfer mode must be 32bit wide taille = 24576; //256*192/2; - if(MMU.DMAStartTime[PROCNUM][num] == EDMAMode_Card) + if(MMU.DMAStartTime[PROCNUM][num] == 5) taille *= 0x80; - MMU.DMACycle[PROCNUM][num] = taille + nds_timer; //TODO - surely this is a gross simplification - + MMU.DMACycle[PROCNUM][num] = taille + nds.cycles; MMU.DMAing[PROCNUM][num] = TRUE; MMU.CheckDMAs |= (1<<(num+(PROCNUM<<2))); @@ -1114,8 +1187,6 @@ void FASTCALL MMU_doDMA(u32 num) if(!(MMU.DMACrt[PROCNUM][num]&(1<<25))) MMU.DMAStartTime[PROCNUM][num] = 0; - - NDS_RescheduleDMA(); // transfer { @@ -1142,34 +1213,28 @@ void FASTCALL MMU_doDMA(u32 num) return; } - //if these do not use MMU_AT_DMA and the corresponding code in the read/write routines, - //then danny phantom title screen will be filled with a garbage char which is made by - //dmaing from 0x00000000 to 0x06000000 if ((MMU.DMACrt[PROCNUM][num]>>26)&1) for(; i < taille; ++i) { - _MMU_write32(dst, _MMU_read32(src)); + _MMU_write32(dst, _MMU_read32(src)); dst += dstinc; src += srcinc; } else for(; i < taille; ++i) { - _MMU_write16(dst, _MMU_read16(src)); + _MMU_write16(dst, _MMU_read16(src)); dst += dstinc; src += srcinc; } + //this is necessary for repeating DMA such as to scroll registers for NSMB level backdrop scrolling effect +//#if 0 //write back the addresses DMASrc[PROCNUM][num] = src; if((u & 0x3)!=3) //but dont write back dst if we were supposed to reload DMADst[PROCNUM][num] = dst; - - //this is probably not the best place to do it, but the dma code in ndssystem is so bad i didnt want to touch it - //until it all gets rewritten. so this is here as a reminder, at least. - //(there is no proof for this code, but it is reasonable) - T1WriteLong(MMU.MMU_MEM[PROCNUM][0x40], 0xB0+12*num, DMASrc[PROCNUM][num]); - T1WriteLong(MMU.MMU_MEM[PROCNUM][0x40], 0xB4+12*num, DMADst[PROCNUM][num]); +//#endif } } @@ -1247,149 +1312,20 @@ static INLINE void MMU_IPCSync(u8 proc, u32 val) u32 sync_l = T1ReadLong(MMU.MMU_MEM[proc][0x40], 0x180) & 0xFFFF; u32 sync_r = T1ReadLong(MMU.MMU_MEM[proc^1][0x40], 0x180) & 0xFFFF; - sync_l = ( sync_l & 0x000F ) | ( val & 0x0F00 ); + sync_l = ( sync_l & 0x600F ) | ( val & 0x0F00 ); + //sync_l = ( sync_l & 0x000F ) | ( val & 0x0F00 ); // svn r2323 sync_r = ( sync_r & 0x6F00 ) | ( (val >> 8) & 0x000F ); - sync_l |= val & 0x6000; + //sync_l |= val & 0x6000; // svn r2323 T1WriteLong(MMU.MMU_MEM[proc][0x40], 0x180, sync_l); T1WriteLong(MMU.MMU_MEM[proc^1][0x40], 0x180, sync_r); - if ((sync_l & 0x2000) && (sync_r & 0x4000)) + if ((val & 0x2000) && (sync_r & 0x4000)) + //if ((sync_l & 0x2000) && (sync_r & 0x4000)) // svn r2323 setIF(proc^1, ( 1 << 16 )); } -static INLINE u16 read_timer(int proc, int timerIndex) -{ - //chained timers are always up to date - if(MMU.timerMODE[proc][timerIndex] == 0xFFFF) - return MMU.timer[proc][timerIndex]; - - //sometimes a timer will be read when it is not enabled. - //we should have the value cached - if(!MMU.timerON[proc][timerIndex]) - return MMU.timer[proc][timerIndex]; - - //for unchained timers, we do not keep the timer up to date. its value will need to be calculated here - s32 diff = (s32)(nds.timerCycle[proc][timerIndex] - nds_timer); - assert(diff>=0); - if(diff<0) - printf("NEW EMULOOP BAD NEWS PLEASE REPORT: TIME READ DIFF < 0 (%d) (%d) (%d)\n",diff,timerIndex,MMU.timerMODE[proc][timerIndex]); - - s32 units = diff / (1<65536) { - printf("NEW EMULOOP BAD NEWS PLEASE REPORT: UNITS %d:%d = %d\n",proc,timerIndex,units); - ret = 0; - } - else ret = 65535 - units; - - return ret; -} - -static INLINE void write_timer(int proc, int timerIndex, u16 val) -{ - int mask = ((val&0x80)>>7) << timerIndex; - //MMU.CheckTimers = (MMU.CheckTimers & (~mask)) | mask; - - if(val&0x80) - MMU.timer[proc][timerIndex] = MMU.timerReload[proc][timerIndex]; - else - { - if(MMU.timerON[proc][timerIndex]) - //read the timer value one last time - MMU.timer[proc][timerIndex] = read_timer(proc,timerIndex); - } - - MMU.timerON[proc][timerIndex] = val & 0x80; - - switch(val&7) - { - case 0 : - MMU.timerMODE[proc][timerIndex] = 0+1; - break; - case 1 : - MMU.timerMODE[proc][timerIndex] = 6+1; - break; - case 2 : - MMU.timerMODE[proc][timerIndex] = 8+1; - break; - case 3 : - MMU.timerMODE[proc][timerIndex] = 10+1; - break; - default : - MMU.timerMODE[proc][timerIndex] = 0xFFFF; - break; - } - - int remain = 65536 - MMU.timerReload[proc][timerIndex]; - nds.timerCycle[proc][timerIndex] = nds_timer + (remain< static INLINE void write_dma_hictrl(const int dmanum, const u16 val) -{ - u32 baseAddr = 0xB0 + dmanum*12; - - //write this control value - T1WriteWord(MMU.MMU_MEM[proc][0x40], baseAddr+10, val); - - //read back the src and dst addr - DMASrc[proc][dmanum] = T1ReadLong(MMU.MMU_MEM[proc][0x40], baseAddr); - DMADst[proc][dmanum] = T1ReadLong(MMU.MMU_MEM[proc][0x40], baseAddr+4); - - //analyze the control value - u32 v = T1ReadLong(MMU.MMU_MEM[proc][0x40], baseAddr+8); - if(proc==ARMCPU_ARM9) MMU.DMAStartTime[proc][dmanum] = (v>>27) & 0x7; - else { - static const EDMAMode lookup[] = {EDMAMode_Immediate,EDMAMode_VBlank,EDMAMode_Card,EDMAMode7_Wifi}; - MMU.DMAStartTime[proc][dmanum] = lookup[(v>>28) & 0x3]; - if(MMU.DMAStartTime[proc][dmanum] == EDMAMode7_Wifi && (dmanum==1 || dmanum==3)) - MMU.DMAStartTime[proc][dmanum] = EDMAMode7_GBASlot; - } - MMU.DMACrt[proc][dmanum] = v; - if(MMU.DMAStartTime[proc][dmanum] == EDMAMode_Immediate - //TODO HACK: I think this is a gxfifo hack: - || MMU.DMAStartTime[proc][dmanum] == EDMAMode_GXFifo) - { - MMU_doDMA(dmanum); - } - - //printf("dma ctrl %d %d\n",proc,dmanum); - - //LOG("ARMCPU_ARM9 %d, dma %d src %08X dst %08X %s\r\n", ARMCPU_ARM9, 0, DMASrc[ARMCPU_ARM9][0], DMADst[ARMCPU_ARM9][0], (val&(1<<25))?"ON":"OFF"); - - NDS_RescheduleDMA(); -} - -static INLINE void write_auxspicnt(const int proc, const int size, const int adr, const int val) -{ - //why val==0 to reset? is it a particular bit? its not bit 6... - switch(size) { - case 16: - MMU.AUX_SPI_CNT = val; - if (val == 0) MMU_new.backupDevice.reset_command(); - break; - case 8: - switch(adr) { - case 0: - T1WriteByte((u8*)&MMU.AUX_SPI_CNT,0,val); - if (val == 0) MMU_new.backupDevice.reset_command(); - break; - case 1: - T1WriteByte((u8*)&MMU.AUX_SPI_CNT,1,val); - break; - } - } -} - - //================================================================================================== ARM9 * //========================================================================================================= //========================================================================================================= @@ -1404,11 +1340,19 @@ void FASTCALL _MMU_ARM9_write08(u32 adr, u8 val) return; } +#ifdef EXPERIMENTAL_GBASLOT if ( (adr >= 0x08000000) && (adr < 0x0A010000) ) { addon.write08(adr, val); return; } +#else + // CFlash writing, Mic + if ((adr>=0x9000000)&&(adr<0x9900000)) { + cflash_write(adr,val); + return; + } +#endif adr &= 0x0FFFFFFF; @@ -1544,14 +1488,6 @@ void FASTCALL _MMU_ARM9_write08(u32 adr, u8 val) GPU_setBLDY_EVY(SubScreen.gpu,val) ; break; - case REG_AUXSPICNT: - write_auxspicnt(9,8,0,val); - return; - case REG_AUXSPICNT+1: - write_auxspicnt(9,8,1,val); - return; - - case 0x4000247: /* Update WRAMSTAT at the ARM7 side */ T1WriteByte(MMU.MMU_MEM[ARMCPU_ARM7][0x40], 0x241, val); @@ -1612,11 +1548,20 @@ void FASTCALL _MMU_ARM9_write16(u32 adr, u16 val) return; } +#ifdef EXPERIMENTAL_GBASLOT if ( (adr >= 0x08000000) && (adr < 0x0A010000) ) { addon.write16(adr, val); return; } +#else + // CFlash writing, Mic + if ((adr>=0x08800000)&&(adr<0x09900000)) + { + cflash_write(adr,val); + return; + } +#endif adr &= 0x0FFFFFFF; @@ -1848,21 +1793,23 @@ void FASTCALL _MMU_ARM9_write16(u32 adr, u16 val) u16 oldval = T1ReadWord(MMU.MMU_MEM[ARMCPU_ARM7][0x40], 0x204); T1WriteWord(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x204, val); T1WriteWord(MMU.MMU_MEM[ARMCPU_ARM7][0x40], 0x204, (val & 0xFF80) | (oldval & 0x7F)); - return; } + return; case REG_AUXSPICNT: - write_auxspicnt(9,16,0,val); - return; + T1WriteWord(MMU.MMU_MEM[ARMCPU_ARM9][(REG_AUXSPICNT >> 20) & 0xff], REG_AUXSPICNT & 0xfff, val); + AUX_SPI_CNT = val; + if (val == 0) + mc_reset_com(&MMU.bupmem); /* reset backup memory device communication */ + return; + case REG_AUXSPIDATA: if(val!=0) - MMU.AUX_SPI_CMD = val & 0xFF; + AUX_SPI_CMD = val & 0xFF; - //T1WriteWord(MMU.MMU_MEM[ARMCPU_ARM7][(REG_AUXSPIDATA >> 20) & 0xff], REG_AUXSPIDATA & 0xfff, bm_transfer(&MMU.bupmem, val)); - T1WriteWord(MMU.MMU_MEM[ARMCPU_ARM7][(REG_AUXSPIDATA >> 20) & 0xff], REG_AUXSPIDATA & 0xfff, MMU_new.backupDevice.data_command(val)); + T1WriteWord(MMU.MMU_MEM[ARMCPU_ARM9][(REG_AUXSPIDATA >> 20) & 0xff], REG_AUXSPIDATA & 0xfff, bm_transfer(&MMU.bupmem, val)); return; - case REG_DISPA_BG0CNT : //GPULOG("MAIN BG0 SETPROP 16B %08X\r\n", val); GPU_setBGProp(MainScreen.gpu, 0, val); @@ -1922,7 +1869,6 @@ void FASTCALL _MMU_ARM9_write16(u32 adr, u16 val) case REG_IME: { - NDS_Reschedule(); u32 old_val = MMU.reg_IME[ARMCPU_ARM9]; u32 new_val = val & 0x01; MMU.reg_IME[ARMCPU_ARM9] = new_val; @@ -1941,7 +1887,6 @@ void FASTCALL _MMU_ARM9_write16(u32 adr, u16 val) return; } case REG_IE : - NDS_Reschedule(); MMU.reg_IE[ARMCPU_ARM9] = (MMU.reg_IE[ARMCPU_ARM9]&0xFFFF0000) | val; #ifndef NEW_IRQ if ( MMU.reg_IME[ARMCPU_ARM9]) @@ -1956,7 +1901,6 @@ void FASTCALL _MMU_ARM9_write16(u32 adr, u16 val) #endif return; case REG_IE + 2 : - NDS_Reschedule(); MMU.reg_IE[ARMCPU_ARM9] = (MMU.reg_IE[ARMCPU_ARM9]&0xFFFF) | (((u32)val)<<16); #ifndef NEW_IRQ if ( MMU.reg_IME[ARMCPU_ARM9]) @@ -1972,11 +1916,9 @@ void FASTCALL _MMU_ARM9_write16(u32 adr, u16 val) return; case REG_IF : - NDS_Reschedule(); MMU.reg_IF[ARMCPU_ARM9] &= (~((u32)val)); return; case REG_IF + 2 : - NDS_Reschedule(); MMU.reg_IF[ARMCPU_ARM9] &= (~(((u32)val)<<16)); return; @@ -1999,7 +1941,37 @@ void FASTCALL _MMU_ARM9_write16(u32 adr, u16 val) case REG_TM3CNTH : { int timerIndex = ((adr-2)>>2)&0x3; - write_timer(ARMCPU_ARM9, timerIndex, val); + int mask = ((val&0x80)>>7) << timerIndex; + MMU.CheckTimers = (MMU.CheckTimers & (~mask)) | mask; + + if(val&0x80) + MMU.timer[ARMCPU_ARM9][timerIndex] = MMU.timerReload[ARMCPU_ARM9][((adr-2)>>2)&0x3]; + + MMU.timerON[ARMCPU_ARM9][((adr-2)>>2)&0x3] = val & 0x80; + + switch(val&7) + { + case 0 : + MMU.timerMODE[ARMCPU_ARM9][timerIndex] = 0+1;//ARMCPU_ARM9; + break; + case 1 : + MMU.timerMODE[ARMCPU_ARM9][timerIndex] = 6+1;//ARMCPU_ARM9; + break; + case 2 : + MMU.timerMODE[ARMCPU_ARM9][timerIndex] = 8+1;//ARMCPU_ARM9; + break; + case 3 : + MMU.timerMODE[ARMCPU_ARM9][timerIndex] = 10+1;//ARMCPU_ARM9; + break; + default : + MMU.timerMODE[ARMCPU_ARM9][timerIndex] = 0xFFFF; + break; + } + + if(!(val & 0x80)) + MMU.timerRUN[ARMCPU_ARM9][timerIndex] = FALSE; + + T1WriteWord(MMU.MMU_MEM[ARMCPU_ARM9][0x40], adr & 0xFFF, val); return; } @@ -2049,17 +2021,95 @@ void FASTCALL _MMU_ARM9_write16(u32 adr, u16 val) } case REG_DMA0CNTH : - write_dma_hictrl(0,val); + { + u32 v; + //if(val&0x8000) emu_halt(); + //LOG("16 bit dma0 %04X\r\n", val); + T1WriteWord(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0xBA, val); + DMASrc[ARMCPU_ARM9][0] = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0xB0); + DMADst[ARMCPU_ARM9][0] = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0xB4); + DMAtoVRAMmapping<0>(); + v = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0xB8); + MMU.DMAStartTime[ARMCPU_ARM9][0] = (v>>27) & 0x7; + MMU.DMACrt[ARMCPU_ARM9][0] = v; + if(MMU.DMAStartTime[ARMCPU_ARM9][0] == 0) + MMU_doDMA(0); + #ifdef LOG_DMA2 + //else + { + LOG("ARMCPU_ARM9 %d, dma %d src %08X dst %08X %s\r\n", ARMCPU_ARM9, 0, DMASrc[ARMCPU_ARM9][0], DMADst[ARMCPU_ARM9][0], (val&(1<<25))?"ON":"OFF"); + } + #endif + } return; case REG_DMA1CNTH : - write_dma_hictrl(1,val); + { + u32 v; + //if(val&0x8000) emu_halt(); + //LOG("16 bit dma1 %04X\r\n", val); + T1WriteWord(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0xC6, val); + DMASrc[ARMCPU_ARM9][1] = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0xBC); + DMADst[ARMCPU_ARM9][1] = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0xC0); + DMAtoVRAMmapping<1>(); + v = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0xC4); + MMU.DMAStartTime[ARMCPU_ARM9][1] = (v>>27) & 0x7; + MMU.DMACrt[ARMCPU_ARM9][1] = v; + if(MMU.DMAStartTime[ARMCPU_ARM9][1] == 0) + MMU_doDMA(1); + #ifdef LOG_DMA2 + //else + { + LOG("ARMCPU_ARM9 %d, dma %d src %08X dst %08X %s\r\n", ARMCPU_ARM9, 1, DMASrc[ARMCPU_ARM9][1], DMADst[ARMCPU_ARM9][1], (val&(1<<25))?"ON":"OFF"); + } + #endif + } return; case REG_DMA2CNTH : - write_dma_hictrl(2,val); + { + u32 v; + //if(val&0x8000) emu_halt(); + //LOG("16 bit dma2 %04X\r\n", val); + T1WriteWord(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0xD2, val); + DMASrc[ARMCPU_ARM9][2] = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0xC8); + DMADst[ARMCPU_ARM9][2] = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0xCC); + DMAtoVRAMmapping<2>(); + v = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0xD0); + MMU.DMAStartTime[ARMCPU_ARM9][2] = (v>>27) & 0x7; + MMU.DMACrt[ARMCPU_ARM9][2] = v; + if(MMU.DMAStartTime[ARMCPU_ARM9][2] == 0) + MMU_doDMA(2); + #ifdef LOG_DMA2 + //else + { + LOG("ARMCPU_ARM9 %d, dma %d src %08X dst %08X %s\r\n", ARMCPU_ARM9, 2, DMASrc[ARMCPU_ARM9][2], DMADst[ARMCPU_ARM9][2], (val&(1<<25))?"ON":"OFF"); + } + #endif + } return; case REG_DMA3CNTH : - write_dma_hictrl(3,val); + { + u32 v; + //if(val&0x8000) emu_halt(); + //LOG("16 bit dma3 %04X\r\n", val); + T1WriteWord(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0xDE, val); + DMASrc[ARMCPU_ARM9][3] = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0xD4); + DMADst[ARMCPU_ARM9][3] = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0xD8); + DMAtoVRAMmapping<3>(); + v = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0xDC); + MMU.DMAStartTime[ARMCPU_ARM9][3] = (v>>27) & 0x7; + MMU.DMACrt[ARMCPU_ARM9][3] = v; + + if(MMU.DMAStartTime[ARMCPU_ARM9][3] == 0) + MMU_doDMA(3); + #ifdef LOG_DMA2 + //else + { + LOG("ARMCPU_ARM9 %d, dma %d src %08X dst %08X %s\r\n", ARMCPU_ARM9, 3, DMASrc[ARMCPU_ARM9][3], DMADst[ARMCPU_ARM9][3], (val&(1<<25))?"ON":"OFF"); + } + #endif + } return; + //case REG_AUXSPICNT : emu_halt(); case REG_DISPA_DISPMMEMFIFO: { DISP_FIFOsend(val); @@ -2090,11 +2140,23 @@ void FASTCALL _MMU_ARM9_write32(u32 adr, u32 val) return ; } + if(adr>=0x02400000 && adr<0x03000000) { + //int zzz=9; + } + +#ifdef EXPERIMENTAL_GBASLOT if ( (adr >= 0x08000000) && (adr < 0x0A010000) ) { addon.write32(adr, val); return; } +#else + // CFlash writing, Mic + if ((adr>=0x9000000) && (adr<0x9900000)) { + cflash_write(adr,val); + return; + } +#endif adr &= 0x0FFFFFFF; @@ -2328,7 +2390,6 @@ void FASTCALL _MMU_ARM9_write32(u32 adr, u32 val) case REG_IME : { - NDS_Reschedule(); u32 old_val = MMU.reg_IME[ARMCPU_ARM9]; u32 new_val = val & 0x01; MMU.reg_IME[ARMCPU_ARM9] = new_val; @@ -2348,7 +2409,6 @@ void FASTCALL _MMU_ARM9_write32(u32 adr, u32 val) return; case REG_IE : - NDS_Reschedule(); MMU.reg_IE[ARMCPU_ARM9] = val; #ifndef NEW_IRQ if ( MMU.reg_IME[ARMCPU_ARM9]) @@ -2364,7 +2424,6 @@ void FASTCALL _MMU_ARM9_write32(u32 adr, u32 val) return; case REG_IF : - NDS_Reschedule(); MMU.reg_IF[ARMCPU_ARM9] &= (~val); return; @@ -2374,9 +2433,36 @@ void FASTCALL _MMU_ARM9_write32(u32 adr, u32 val) case REG_TM3CNTL: { int timerIndex = (adr>>2)&0x3; + int mask = ((val & 0x800000)>>(16+7)) << timerIndex; + MMU.CheckTimers = (MMU.CheckTimers & (~mask)) | mask; + MMU.timerReload[ARMCPU_ARM9][timerIndex] = (u16)val; - T1WriteWord(MMU.MMU_MEM[ARMCPU_ARM9][0x40], adr & 0xFFF, val); - write_timer(ARMCPU_ARM9, timerIndex, val>>16); + if(val&0x800000) + MMU.timer[ARMCPU_ARM9][timerIndex] = MMU.timerReload[ARMCPU_ARM9][(adr>>2)&0x3]; + + MMU.timerON[ARMCPU_ARM9][timerIndex] = val & 0x800000; + switch((val>>16)&7) + { + case 0 : + MMU.timerMODE[ARMCPU_ARM9][timerIndex] = 0+1;//ARMCPU_ARM9; + break; + case 1 : + MMU.timerMODE[ARMCPU_ARM9][timerIndex] = 6+1;//ARMCPU_ARM9; + break; + case 2 : + MMU.timerMODE[ARMCPU_ARM9][timerIndex] = 8+1;//ARMCPU_ARM9; + break; + case 3 : + MMU.timerMODE[ARMCPU_ARM9][timerIndex] = 10+1;//ARMCPU_ARM9; + break; + default : + MMU.timerMODE[ARMCPU_ARM9][timerIndex] = 0xFFFF; + break; + } + if(!(val & 0x800000)) + MMU.timerRUN[ARMCPU_ARM9][timerIndex] = FALSE; + + T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], adr & 0xFFF, val); return; } @@ -2414,20 +2500,77 @@ void FASTCALL _MMU_ARM9_write32(u32 adr, u32 val) return; case REG_DMA0CNTL : - T1WriteWord(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0xB8, val); //write the low word - write_dma_hictrl(0,val>>16); + //LOG("32 bit dma0 %04X\r\n", val); + DMASrc[ARMCPU_ARM9][0] = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0xB0); + DMADst[ARMCPU_ARM9][0] = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0xB4); + DMAtoVRAMmapping<0>(); + MMU.DMAStartTime[ARMCPU_ARM9][0] = (val>>27) & 0x7; + MMU.DMACrt[ARMCPU_ARM9][0] = val; + T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0xB8, val); + if( MMU.DMAStartTime[ARMCPU_ARM9][0] == 0 || + MMU.DMAStartTime[ARMCPU_ARM9][0] == 7) // Start Immediately + MMU_doDMA(0); + #ifdef LOG_DMA2 + else + { + LOG("ARMCPU_ARM9 %d, dma %d src %08X dst %08X start taille %d %d\r\n", ARMCPU_ARM9, 0, DMASrc[ARMCPU_ARM9][0], DMADst[ARMCPU_ARM9][0], 0, ((MMU.DMACrt[ARMCPU_ARM9][0]>>27)&7)); + } + #endif + //emu_halt(); return; case REG_DMA1CNTL: - T1WriteWord(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0xC4, val); //write the low word - write_dma_hictrl(1,val>>16); + //LOG("32 bit dma1 %04X\r\n", val); + DMASrc[ARMCPU_ARM9][1] = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0xBC); + DMADst[ARMCPU_ARM9][1] = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0xC0); + DMAtoVRAMmapping<1>(); + MMU.DMAStartTime[ARMCPU_ARM9][1] = (val>>27) & 0x7; + MMU.DMACrt[ARMCPU_ARM9][1] = val; + T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0xC4, val); + if(MMU.DMAStartTime[ARMCPU_ARM9][1] == 0 || + MMU.DMAStartTime[ARMCPU_ARM9][1] == 7) // Start Immediately + MMU_doDMA(1); + #ifdef LOG_DMA2 + else + { + LOG("ARMCPU_ARM9 %d, dma %d src %08X dst %08X start taille %d %d\r\n", ARMCPU_ARM9, 1, DMASrc[ARMCPU_ARM9][1], DMADst[ARMCPU_ARM9][1], 0, ((MMU.DMACrt[ARMCPU_ARM9][1]>>27)&7)); + } + #endif return; case REG_DMA2CNTL : - T1WriteWord(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0xD0, val); //write the low word - write_dma_hictrl(2,val>>16); + //LOG("32 bit dma2 %04X\r\n", val); + DMASrc[ARMCPU_ARM9][2] = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0xC8); + DMADst[ARMCPU_ARM9][2] = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0xCC); + DMAtoVRAMmapping<2>(); + MMU.DMAStartTime[ARMCPU_ARM9][2] = (val>>27) & 0x7; + MMU.DMACrt[ARMCPU_ARM9][2] = val; + T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0xD0, val); + if(MMU.DMAStartTime[ARMCPU_ARM9][2] == 0 || + MMU.DMAStartTime[ARMCPU_ARM9][2] == 7) // Start Immediately + MMU_doDMA(2); + #ifdef LOG_DMA2 + else + { + LOG("ARMCPU_ARM9 %d, dma %d src %08X dst %08X start taille %d %d\r\n", ARMCPU_ARM9, 2, DMASrc[ARMCPU_ARM9][2], DMADst[ARMCPU_ARM9][2], 0, ((MMU.DMACrt[ARMCPU_ARM9][2]>>27)&7)); + } + #endif return; case REG_DMA3CNTL : - T1WriteWord(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0xDC, val); //write the low word - write_dma_hictrl(3,val>>16); + //LOG("32 bit dma3 %04X\r\n", val); + DMASrc[ARMCPU_ARM9][3] = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0xD4); + DMADst[ARMCPU_ARM9][3] = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0xD8); + DMAtoVRAMmapping<3>(); + MMU.DMAStartTime[ARMCPU_ARM9][3] = (val>>27) & 0x7; + MMU.DMACrt[ARMCPU_ARM9][3] = val; + T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0xDC, val); + if( MMU.DMAStartTime[ARMCPU_ARM9][3] == 0 || + MMU.DMAStartTime[ARMCPU_ARM9][3] == 7) // Start Immediately + MMU_doDMA(3); + #ifdef LOG_DMA2 + else + { + LOG("ARMCPU_ARM9 %d, dma %d src %08X dst %08X start taille %d %d\r\n", ARMCPU_ARM9, 3, DMASrc[ARMCPU_ARM9][3], DMADst[ARMCPU_ARM9][3], 0, ((MMU.DMACrt[ARMCPU_ARM9][3]>>27)&7)); + } + #endif return; case REG_GCROMCTRL : { @@ -2505,11 +2648,23 @@ void FASTCALL _MMU_ARM9_write32(u32 adr, u32 val) val |= 0x00800000; T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x1A4, val); - //launch DMA if start flag was set to "DS Cart" - if(MMU.DMAStartTime[ARMCPU_ARM9][0] == EDMAMode_Card) MMU_doDMA(0); - if(MMU.DMAStartTime[ARMCPU_ARM9][1] == EDMAMode_Card) MMU_doDMA(1); - if(MMU.DMAStartTime[ARMCPU_ARM9][2] == EDMAMode_Card) MMU_doDMA(2); - if(MMU.DMAStartTime[ARMCPU_ARM9][3] == EDMAMode_Card) MMU_doDMA(3); + /* launch DMA if start flag was set to "DS Cart" */ + if(MMU.DMAStartTime[ARMCPU_ARM9][0] == 5) + { + MMU_doDMA(0); + } + if(MMU.DMAStartTime[ARMCPU_ARM9][1] == 5) + { + MMU_doDMA(1); + } + if(MMU.DMAStartTime[ARMCPU_ARM9][2] == 5) + { + MMU_doDMA(2); + } + if(MMU.DMAStartTime[ARMCPU_ARM9][3] == 5) + { + MMU_doDMA(3); + } } return; case REG_DISPA_DISPCAPCNT : @@ -2566,8 +2721,14 @@ u8 FASTCALL _MMU_ARM9_read08(u32 adr) if(adr<0x02000000) return T1ReadByte(ARM9Mem.ARM9_ITCM, adr&0x7FFF); +#ifdef EXPERIMENTAL_GBASLOT if ( (adr >= 0x08000000) && (adr < 0x0A010000) ) return addon.read08(adr); +#else + // CFlash reading, Mic + if ((adr>=0x9000000)&&(adr<0x9900000)) + return (unsigned char)cflash_read(adr); +#endif bool unmapped; adr = MMU_LCDmap(adr, unmapped); @@ -2584,8 +2745,14 @@ u16 FASTCALL _MMU_ARM9_read16(u32 adr) if(adr<0x02000000) return T1ReadWord(ARM9Mem.ARM9_ITCM, adr & 0x7FFF); +#ifdef EXPERIMENTAL_GBASLOT if ( (adr >= 0x08000000) && (adr < 0x0A010000) ) return addon.read16(adr); +#else + // CFlash reading, Mic + if ((adr>=0x08800000) && (adr<0x09900000)) + return (unsigned short)cflash_read(adr); +#endif adr &= 0x0FFFFFFF; @@ -2621,10 +2788,7 @@ u16 FASTCALL _MMU_ARM9_read16(u32 adr) case REG_TM1CNTL : case REG_TM2CNTL : case REG_TM3CNTL : - return read_timer(ARMCPU_ARM9,(adr&0xF)>>2); - - case REG_AUXSPICNT: - return MMU.AUX_SPI_CNT; + return MMU.timer[ARMCPU_ARM9][(adr&0xF)>>2]; case 0x04000130: case 0x04000136: @@ -2654,8 +2818,14 @@ u32 FASTCALL _MMU_ARM9_read32(u32 adr) if(adr<0x02000000) return T1ReadLong(ARM9Mem.ARM9_ITCM, adr&0x7FFF); +#ifdef EXPERIMENTAL_GBASLOT if ( (adr >= 0x08000000) && (adr < 0x0A010000) ) return addon.read32(adr); +#else + // CFlash reading, Mic + if ((adr>=0x9000000) && (adr<0x9900000)) + return (u32)cflash_read(adr); +#endif adr &= 0x0FFFFFFF; @@ -2759,7 +2929,7 @@ u32 FASTCALL _MMU_ARM9_read32(u32 adr) /* Nand Init? */ case 0x94: { - val = 0; //Unsure what to return here so return 0 for now + val = 0; //Unsure what to return here to return 0 for now } break; /* Nand Error? */ @@ -2796,7 +2966,6 @@ u32 FASTCALL _MMU_ARM9_read32(u32 adr) LOG("READ CARD command: %08X %08X\t", ((MEM_8(MMU.MMU_MEM[ARMCPU_ARM9], REG_GCCMDOUT) << 24) | (MEM_8(MMU.MMU_MEM[ARMCPU_ARM9], REG_GCCMDOUT+1) << 16) | (MEM_8(MMU.MMU_MEM[ARMCPU_ARM9], REG_GCCMDOUT+2) << 8) | (MEM_8(MMU.MMU_MEM[ARMCPU_ARM9], REG_GCCMDOUT+3))),((MEM_8(MMU.MMU_MEM[ARMCPU_ARM9], REG_GCCMDOUT+4) << 24) | (MEM_8(MMU.MMU_MEM[ARMCPU_ARM9], REG_GCCMDOUT+5) << 16) | (MEM_8(MMU.MMU_MEM[ARMCPU_ARM9], REG_GCCMDOUT+6) << 8) | (MEM_8(MMU.MMU_MEM[ARMCPU_ARM9], REG_GCCMDOUT+7)))); LOG("FROM: %08X\n", NDS_ARM9.instruct_adr); break; - } MMU.dscard[ARMCPU_ARM9].address += 4; // increment address @@ -2810,7 +2979,7 @@ u32 FASTCALL _MMU_ARM9_read32(u32 adr) T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x1A4) & 0x7F7FFFFF); // if needed, throw irq for the end of transfer - if(MMU.AUX_SPI_CNT & 0x4000) + if(T1ReadWord(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x1A0) & 0x4000) NDS_makeInt(ARMCPU_ARM9, 19); return val; @@ -2834,11 +3003,20 @@ void FASTCALL _MMU_ARM7_write08(u32 adr, u8 val) { mmu_log_debug_ARM7(adr, "(write08) %0x%X", val); +#ifdef EXPERIMENTAL_GBASLOT if ( (adr >= 0x08000000) && (adr < 0x0A010000) ) { addon.write08(adr, val); return; } +#else + // CFlash writing, Mic + if ((adr>=0x9000000)&&(adr<0x9900000)) + { + cflash_write(adr,val); + return; + } +#endif adr &= 0x0FFFFFFF; // This is bad, remove it @@ -2848,8 +3026,6 @@ void FASTCALL _MMU_ARM7_write08(u32 adr, u8 val) return; } - adr &= 0x0FFFFFFF; - if(adr == 0x04000301) { switch(val) @@ -2868,22 +3044,7 @@ void FASTCALL _MMU_ARM7_write08(u32 adr, u8 val) } #endif - if (adr >> 24 == 4) - { - switch(adr) - { - case REG_RTC: - rtcWrite(val); - return; - - case REG_AUXSPICNT: - write_auxspicnt(9,8,0,val); - return; - case REG_AUXSPICNT+1: - write_auxspicnt(9,8,1,val); - return; - } - } + if ( adr == REG_RTC ) rtcWrite(val); bool unmapped; adr = MMU_LCDmap(adr,unmapped); @@ -2898,11 +3059,20 @@ void FASTCALL _MMU_ARM7_write16(u32 adr, u16 val) { mmu_log_debug_ARM7(adr, "(write16) %0x%X", val); +#ifdef EXPERIMENTAL_GBASLOT if ( (adr >= 0x08000000) && (adr < 0x0A010000) ) { addon.write16(adr, val); return; } +#else + // CFlash writing, Mic + if ((adr>=0x08800000)&&(adr<0x09900000)) + { + cflash_write(adr,val); + return; + } +#endif #ifdef EXPERIMENTAL_WIFI @@ -2943,26 +3113,29 @@ void FASTCALL _MMU_ARM7_write16(u32 adr, u16 val) return; case REG_AUXSPICNT: - write_auxspicnt(7,16,0,val); + T1WriteWord(MMU.MMU_MEM[ARMCPU_ARM7][(REG_AUXSPICNT >> 20) & 0xff], REG_AUXSPICNT & 0xfff, val); + AUX_SPI_CNT = val; + + if (val == 0) + mc_reset_com(&MMU.bupmem); // reset backup memory device communication return; case REG_AUXSPIDATA: if(val!=0) - MMU.AUX_SPI_CMD = val & 0xFF; + AUX_SPI_CMD = val & 0xFF; - //T1WriteWord(MMU.MMU_MEM[ARMCPU_ARM7][(REG_AUXSPIDATA >> 20) & 0xff], REG_AUXSPIDATA & 0xfff, bm_transfer(&MMU.bupmem, val)); - T1WriteWord(MMU.MMU_MEM[ARMCPU_ARM7][(REG_AUXSPIDATA >> 20) & 0xff], REG_AUXSPIDATA & 0xfff, MMU_new.backupDevice.data_command(val)); + T1WriteWord(MMU.MMU_MEM[ARMCPU_ARM7][(REG_AUXSPIDATA >> 20) & 0xff], REG_AUXSPIDATA & 0xfff, bm_transfer(&MMU.bupmem, val)); return; case REG_SPICNT : { int reset_firmware = 1; - if ( ((MMU.SPI_CNT >> 8) & 0x3) == 1) + if ( ((SPI_CNT >> 8) & 0x3) == 1) { if ( ((val >> 8) & 0x3) == 1) { - if ( BIT11(MMU.SPI_CNT)) + if ( BIT11(SPI_CNT)) { // select held reset_firmware = 0; @@ -2974,9 +3147,9 @@ void FASTCALL _MMU_ARM7_write16(u32 adr, u16 val) if ( reset_firmware) { // reset fw device communication - fw_reset_com(&MMU.fw); + mc_reset_com(&MMU.fw); } - MMU.SPI_CNT = val; + SPI_CNT = val; T1WriteWord(MMU.MMU_MEM[ARMCPU_ARM7][(REG_SPICNT >> 20) & 0xff], REG_SPICNT & 0xfff, val); } @@ -2987,7 +3160,7 @@ void FASTCALL _MMU_ARM7_write16(u32 adr, u16 val) u16 spicnt; if(val!=0) - MMU.SPI_CMD = val; + SPI_CMD = val; spicnt = T1ReadWord(MMU.MMU_MEM[ARMCPU_ARM7][(REG_SPICNT >> 20) & 0xff], REG_SPICNT & 0xfff); @@ -3026,14 +3199,14 @@ void FASTCALL _MMU_ARM7_write16(u32 adr, u16 val) return; case 2 : - switch(MMU.SPI_CMD & 0x70) + switch(SPI_CMD & 0x70) { case 0x00 : val = 0; break; case 0x10 : //emu_halt(); - if(MMU.SPI_CNT&(1<<11)) + if(SPI_CNT&(1<<11)) { if(partie) { @@ -3099,7 +3272,6 @@ void FASTCALL _MMU_ARM7_write16(u32 adr, u16 val) case REG_IME : { - NDS_Reschedule(); u32 old_val = MMU.reg_IME[ARMCPU_ARM7]; u32 new_val = val & 1; MMU.reg_IME[ARMCPU_ARM7] = new_val; @@ -3118,7 +3290,6 @@ void FASTCALL _MMU_ARM7_write16(u32 adr, u16 val) return; } case REG_IE : - NDS_Reschedule(); MMU.reg_IE[ARMCPU_ARM7] = (MMU.reg_IE[ARMCPU_ARM7]&0xFFFF0000) | val; #ifndef NEW_IRQ if ( MMU.reg_IME[ARMCPU_ARM7]) @@ -3133,7 +3304,6 @@ void FASTCALL _MMU_ARM7_write16(u32 adr, u16 val) #endif return; case REG_IE + 2 : - NDS_Reschedule(); //emu_halt(); MMU.reg_IE[ARMCPU_ARM7] = (MMU.reg_IE[ARMCPU_ARM7]&0xFFFF) | (((u32)val)<<16); #ifndef NEW_IRQ @@ -3150,12 +3320,10 @@ void FASTCALL _MMU_ARM7_write16(u32 adr, u16 val) return; case REG_IF : - NDS_Reschedule(); //emu_halt(); MMU.reg_IF[ARMCPU_ARM7] &= (~((u32)val)); return; case REG_IF + 2 : - NDS_Reschedule(); //emu_halt(); MMU.reg_IF[ARMCPU_ARM7] &= (~(((u32)val)<<16)); return; @@ -3179,22 +3347,127 @@ void FASTCALL _MMU_ARM7_write16(u32 adr, u16 val) case REG_TM3CNTH : { int timerIndex = ((adr-2)>>2)&0x3; - write_timer(ARMCPU_ARM7, timerIndex, val); + int mask = ((val&0x80)>>7) << (timerIndex+(ARMCPU_ARM7<<2)); + MMU.CheckTimers = (MMU.CheckTimers & (~mask)) | mask; + + if(val&0x80) + MMU.timer[ARMCPU_ARM7][timerIndex] = MMU.timerReload[ARMCPU_ARM7][((adr-2)>>2)&0x3]; + + MMU.timerON[ARMCPU_ARM7][((adr-2)>>2)&0x3] = val & 0x80; + + switch(val&7) + { + case 0 : + MMU.timerMODE[ARMCPU_ARM7][timerIndex] = 0+1;//ARMCPU_ARM7; + break; + case 1 : + MMU.timerMODE[ARMCPU_ARM7][timerIndex] = 6+1;//ARMCPU_ARM7; + break; + case 2 : + MMU.timerMODE[ARMCPU_ARM7][timerIndex] = 8+1;//ARMCPU_ARM7; + break; + case 3 : + MMU.timerMODE[ARMCPU_ARM7][timerIndex] = 10+1;//ARMCPU_ARM7; + break; + default : + MMU.timerMODE[ARMCPU_ARM7][timerIndex] = 0xFFFF; + break; + } + + if(!(val & 0x80)) + MMU.timerRUN[ARMCPU_ARM7][timerIndex] = FALSE; + + T1WriteWord(MMU.MMU_MEM[ARMCPU_ARM7][0x40], adr & 0xFFF, val); return; } case REG_DMA0CNTH : - write_dma_hictrl(0,val); + { + u32 v; + + //if(val&0x8000) emu_halt(); + //LOG("16 bit dma0 %04X\r\n", val); + T1WriteWord(MMU.MMU_MEM[ARMCPU_ARM7][0x40], 0xBA, val); + DMASrc[ARMCPU_ARM7][0] = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM7][0x40], 0xB0); + DMADst[ARMCPU_ARM7][0] = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM7][0x40], 0xB4); + v = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM7][0x40], 0xB8); + MMU.DMAStartTime[ARMCPU_ARM7][0] = (v>>28) & 0x3; + MMU.DMACrt[ARMCPU_ARM7][0] = v; + if(MMU.DMAStartTime[ARMCPU_ARM7][0] == 0) + MMU_doDMA(0); + #ifdef LOG_DMA2 + //else + { + LOG("ARMCPU_ARM7 %d, dma %d src %08X dst %08X %s\r\n", ARMCPU_ARM7, 0, DMASrc[ARMCPU_ARM7][0], DMADst[ARMCPU_ARM7][0], (val&(1<<25))?"ON":"OFF"); + } + #endif + } return; case REG_DMA1CNTH : - write_dma_hictrl(1,val); + { + u32 v; + //if(val&0x8000) emu_halt(); + //LOG("16 bit dma1 %04X\r\n", val); + T1WriteWord(MMU.MMU_MEM[ARMCPU_ARM7][0x40], 0xC6, val); + DMASrc[ARMCPU_ARM7][1] = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM7][0x40], 0xBC); + DMADst[ARMCPU_ARM7][1] = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM7][0x40], 0xC0); + v = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM7][0x40], 0xC4); + MMU.DMAStartTime[ARMCPU_ARM7][1] = (v>>28) & 0x3; + MMU.DMACrt[ARMCPU_ARM7][1] = v; + if(MMU.DMAStartTime[ARMCPU_ARM7][1] == 0) + MMU_doDMA(1); + #ifdef LOG_DMA2 + //else + { + LOG("ARMCPU_ARM7 %d, dma %d src %08X dst %08X %s\r\n", ARMCPU_ARM7, 1, DMASrc[ARMCPU_ARM7][1], DMADst[ARMCPU_ARM7][1], (val&(1<<25))?"ON":"OFF"); + } + #endif + } return; case REG_DMA2CNTH : - write_dma_hictrl(2,val); + { + u32 v; + //if(val&0x8000) emu_halt(); + //LOG("16 bit dma2 %04X\r\n", val); + T1WriteWord(MMU.MMU_MEM[ARMCPU_ARM7][0x40], 0xD2, val); + DMASrc[ARMCPU_ARM7][2] = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM7][0x40], 0xC8); + DMADst[ARMCPU_ARM7][2] = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM7][0x40], 0xCC); + v = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM7][0x40], 0xD0); + MMU.DMAStartTime[ARMCPU_ARM7][2] = (v>>28) & 0x3; + MMU.DMACrt[ARMCPU_ARM7][2] = v; + if(MMU.DMAStartTime[ARMCPU_ARM7][2] == 0) + MMU_doDMA(2); + #ifdef LOG_DMA2 + //else + { + LOG("ARMCPU_ARM7 %d, dma %d src %08X dst %08X %s\r\n", ARMCPU_ARM7, 2, DMASrc[ARMCPU_ARM7][2], DMADst[ARMCPU_ARM7][2], (val&(1<<25))?"ON":"OFF"); + } + #endif + } return; case REG_DMA3CNTH : - write_dma_hictrl(3,val); + { + u32 v; + //if(val&0x8000) emu_halt(); + //LOG("16 bit dma3 %04X\r\n", val); + T1WriteWord(MMU.MMU_MEM[ARMCPU_ARM7][0x40], 0xDE, val); + DMASrc[ARMCPU_ARM7][3] = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM7][0x40], 0xD4); + DMADst[ARMCPU_ARM7][3] = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM7][0x40], 0xD8); + v = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM7][0x40], 0xDC); + MMU.DMAStartTime[ARMCPU_ARM7][3] = (v>>28) & 0x3; + MMU.DMACrt[ARMCPU_ARM7][3] = v; + + if(MMU.DMAStartTime[ARMCPU_ARM7][3] == 0) + MMU_doDMA(3); + #ifdef LOG_DMA2 + //else + { + LOG("ARMCPU_ARM7 %d, dma %d src %08X dst %08X %s\r\n", ARMCPU_ARM7, 3, DMASrc[ARMCPU_ARM7][3], DMADst[ARMCPU_ARM7][3], (val&(1<<25))?"ON":"OFF"); + } + #endif + } return; + //case REG_AUXSPICNT : emu_halt(); } T1WriteWord(MMU.MMU_MEM[ARMCPU_ARM7][0x40], adr&MMU.MMU_MASK[ARMCPU_ARM7][adr>>20], val); @@ -3213,11 +3486,21 @@ void FASTCALL _MMU_ARM7_write32(u32 adr, u32 val) { mmu_log_debug_ARM7(adr, "(write32) %0x%X", val); +#ifdef EXPERIMENTAL_GBASLOT if ( (adr >= 0x08000000) && (adr < 0x0A010000) ) { addon.write32(adr, val); return; } +#else + // CFlash writing, Mic + if ((adr>=0x9000000)&&(adr<0x9900000)) { + cflash_write(adr,val); + return; + } +#endif + + #ifdef EXPERIMENTAL_WIFI if ((adr & 0xFF800000) == 0x04800000) @@ -3250,7 +3533,6 @@ void FASTCALL _MMU_ARM7_write32(u32 adr, u32 val) case REG_IME : { - NDS_Reschedule(); u32 old_val = MMU.reg_IME[ARMCPU_ARM7]; u32 new_val = val & 1; MMU.reg_IME[ARMCPU_ARM7] = new_val; @@ -3270,7 +3552,6 @@ void FASTCALL _MMU_ARM7_write32(u32 adr, u32 val) } case REG_IE : - NDS_Reschedule(); MMU.reg_IE[ARMCPU_ARM7] = val; #ifndef NEW_IRQ if ( MMU.reg_IME[ARMCPU_ARM7]) @@ -3286,7 +3567,6 @@ void FASTCALL _MMU_ARM7_write32(u32 adr, u32 val) return; case REG_IF : - NDS_Reschedule(); MMU.reg_IF[ARMCPU_ARM7] &= (~val); return; @@ -3296,13 +3576,38 @@ void FASTCALL _MMU_ARM7_write32(u32 adr, u32 val) case REG_TM3CNTL: { int timerIndex = (adr>>2)&0x3; + int mask = ((val & 0x800000)>>(16+7)) << (timerIndex+(ARMCPU_ARM7<<2)); + MMU.CheckTimers = (MMU.CheckTimers & (~mask)) | mask; + MMU.timerReload[ARMCPU_ARM7][timerIndex] = (u16)val; - T1WriteWord(MMU.MMU_MEM[ARMCPU_ARM7][0x40], adr & 0xFFF, val); - write_timer(ARMCPU_ARM7, timerIndex, val>>16); + if(val&0x800000) + MMU.timer[ARMCPU_ARM7][timerIndex] = MMU.timerReload[ARMCPU_ARM7][(adr>>2)&0x3]; + + MMU.timerON[ARMCPU_ARM7][timerIndex] = val & 0x800000; + switch((val>>16)&7) + { + case 0 : + MMU.timerMODE[ARMCPU_ARM7][timerIndex] = 0+1;//ARMCPU_ARM7; + break; + case 1 : + MMU.timerMODE[ARMCPU_ARM7][timerIndex] = 6+1;//ARMCPU_ARM7; + break; + case 2 : + MMU.timerMODE[ARMCPU_ARM7][timerIndex] = 8+1;//ARMCPU_ARM7; + break; + case 3 : + MMU.timerMODE[ARMCPU_ARM7][timerIndex] = 10+1;//ARMCPU_ARM7; + break; + default : + MMU.timerMODE[ARMCPU_ARM7][timerIndex] = 0xFFFF; + break; + } + if(!(val & 0x800000)) + MMU.timerRUN[ARMCPU_ARM7][timerIndex] = FALSE; + T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM7][0x40], adr & 0xFFF, val); return; } - case REG_IPCSYNC : MMU_IPCSync(ARMCPU_ARM7, val); return; @@ -3310,24 +3615,75 @@ void FASTCALL _MMU_ARM7_write32(u32 adr, u32 val) case REG_IPCFIFOSEND : IPC_FIFOsend(ARMCPU_ARM7, val); return; - case REG_DMA0CNTL : - T1WriteWord(MMU.MMU_MEM[ARMCPU_ARM7][0x40], 0xB8, val); //write the low word - write_dma_hictrl(0,val>>16); + //LOG("32 bit dma0 %04X\r\n", val); + DMASrc[ARMCPU_ARM7][0] = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM7][0x40], 0xB0); + DMADst[ARMCPU_ARM7][0] = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM7][0x40], 0xB4); + MMU.DMAStartTime[ARMCPU_ARM7][0] = (val>>28) & 0x3; + MMU.DMACrt[ARMCPU_ARM7][0] = val; + T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM7][0x40], 0xB8, val); + if( MMU.DMAStartTime[ARMCPU_ARM7][0] == 0 || + MMU.DMAStartTime[ARMCPU_ARM7][0] == 7) // Start Immediately + MMU_doDMA(0); + #ifdef LOG_DMA2 + else + { + LOG("ARMCPU_ARM7 %d, dma %d src %08X dst %08X start taille %d %d\r\n", ARMCPU_ARM7, 0, DMASrc[ARMCPU_ARM7][0], DMADst[ARMCPU_ARM7][0], 0, ((MMU.DMACrt[ARMCPU_ARM7][0]>>27)&7)); + } + #endif + //emu_halt(); return; case REG_DMA1CNTL: - T1WriteWord(MMU.MMU_MEM[ARMCPU_ARM7][0x40], 0xC4, val); //write the low word - write_dma_hictrl(1,val>>16); + //LOG("32 bit dma1 %04X\r\n", val); + DMASrc[ARMCPU_ARM7][1] = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM7][0x40], 0xBC); + DMADst[ARMCPU_ARM7][1] = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM7][0x40], 0xC0); + MMU.DMAStartTime[ARMCPU_ARM7][1] = (val>>28) & 0x3; + MMU.DMACrt[ARMCPU_ARM7][1] = val; + T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM7][0x40], 0xC4, val); + if(MMU.DMAStartTime[ARMCPU_ARM7][1] == 0 || + MMU.DMAStartTime[ARMCPU_ARM7][1] == 7) // Start Immediately + MMU_doDMA(1); + #ifdef LOG_DMA2 + else + { + LOG("ARMCPU_ARM7 %d, dma %d src %08X dst %08X start taille %d %d\r\n", ARMCPU_ARM7, 1, DMASrc[ARMCPU_ARM7][1], DMADst[ARMCPU_ARM7][1], 0, ((MMU.DMACrt[ARMCPU_ARM7][1]>>27)&7)); + } + #endif return; case REG_DMA2CNTL : - T1WriteWord(MMU.MMU_MEM[ARMCPU_ARM7][0x40], 0xD0, val); //write the low word - write_dma_hictrl(2,val>>16); + //LOG("32 bit dma2 %04X\r\n", val); + DMASrc[ARMCPU_ARM7][2] = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM7][0x40], 0xC8); + DMADst[ARMCPU_ARM7][2] = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM7][0x40], 0xCC); + MMU.DMAStartTime[ARMCPU_ARM7][2] = (val>>28) & 0x3; + MMU.DMACrt[ARMCPU_ARM7][2] = val; + T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM7][0x40], 0xD0, val); + if(MMU.DMAStartTime[ARMCPU_ARM7][2] == 0 || + MMU.DMAStartTime[ARMCPU_ARM7][2] == 7) // Start Immediately + MMU_doDMA(2); + #ifdef LOG_DMA2 + else + { + LOG("ARMCPU_ARM7 %d, dma %d src %08X dst %08X start taille %d %d\r\n", ARMCPU_ARM7, 2, DMASrc[ARMCPU_ARM7][2], DMADst[ARMCPU_ARM7][2], 0, ((MMU.DMACrt[ARMCPU_ARM7][2]>>27)&7)); + } + #endif return; case REG_DMA3CNTL : - T1WriteWord(MMU.MMU_MEM[ARMCPU_ARM7][0x40], 0xDC, val); //write the low word - write_dma_hictrl(3,val>>16); + //LOG("32 bit dma3 %04X\r\n", val); + DMASrc[ARMCPU_ARM7][3] = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM7][0x40], 0xD4); + DMADst[ARMCPU_ARM7][3] = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM7][0x40], 0xD8); + MMU.DMAStartTime[ARMCPU_ARM7][3] = (val>>28) & 0x3; + MMU.DMACrt[ARMCPU_ARM7][3] = val; + T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM7][0x40], 0xDC, val); + if( MMU.DMAStartTime[ARMCPU_ARM7][3] == 0 || + MMU.DMAStartTime[ARMCPU_ARM7][3] == 7) // Start Immediately + MMU_doDMA(3); + #ifdef LOG_DMA2 + else + { + LOG("ARMCPU_ARM7 %d, dma %d src %08X dst %08X start taille %d %d\r\n", ARMCPU_ARM7, 3, DMASrc[ARMCPU_ARM7][3], DMADst[ARMCPU_ARM7][3], 0, ((MMU.DMACrt[ARMCPU_ARM7][3]>>27)&7)); + } + #endif return; - case REG_GCROMCTRL : { if(!(val & 0x80000000)) @@ -3387,11 +3743,16 @@ void FASTCALL _MMU_ARM7_write32(u32 adr, u32 val) val |= 0x00800000; T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM7][0x40], 0x1A4, val); - //launch DMA if start flag was set to "DS Cart" - if(MMU.DMAStartTime[ARMCPU_ARM7][0] == EDMAMode_Card) MMU_doDMA(0); - if(MMU.DMAStartTime[ARMCPU_ARM7][1] == EDMAMode_Card) MMU_doDMA(1); - if(MMU.DMAStartTime[ARMCPU_ARM7][2] == EDMAMode_Card) MMU_doDMA(2); - if(MMU.DMAStartTime[ARMCPU_ARM7][3] == EDMAMode_Card) MMU_doDMA(3); + /* launch DMA if start flag was set to "DS Cart" */ + + if(MMU.DMAStartTime[ARMCPU_ARM7][2] == 2) + { + MMU_doDMA(2); + } + if(MMU.DMAStartTime[ARMCPU_ARM7][3] == 2) + { + MMU_doDMA(3); + } return; @@ -3426,8 +3787,14 @@ u8 FASTCALL _MMU_ARM7_read08(u32 adr) } #endif +#ifdef EXPERIMENTAL_GBASLOT if ( (adr >= 0x08000000) && (adr < 0x0A010000) ) return addon.read08(adr); +#else + // CFlash reading, Mic + if ((adr>=0x9000000)&&(adr<0x9900000)) + return (unsigned char)cflash_read(adr); +#endif if (adr == REG_RTC) return (u8)rtcRead(); @@ -3448,8 +3815,14 @@ u16 FASTCALL _MMU_ARM7_read16(u32 adr) return WIFI_read16(&wifiMac,adr) ; #endif +#ifdef EXPERIMENTAL_GBASLOT if ( (adr >= 0x08000000) && (adr < 0x0A010000) ) return addon.read16(adr); +#else + // CFlash reading, Mic + if ((adr>=0x08800000)&&(adr<0x09900000)) + return (unsigned short)cflash_read(adr); +#endif adr &= 0x0FFFFFFF; @@ -3478,10 +3851,8 @@ u16 FASTCALL _MMU_ARM7_read16(u32 adr) case REG_TM1CNTL : case REG_TM2CNTL : case REG_TM3CNTL : - return read_timer(ARMCPU_ARM7,(adr&0xF)>>2); + return MMU.timer[ARMCPU_ARM7][(adr&0xF)>>2]; - case REG_AUXSPICNT: - return MMU.AUX_SPI_CNT; case 0x04000130: case 0x04000136: @@ -3514,8 +3885,14 @@ u32 FASTCALL _MMU_ARM7_read32(u32 adr) return (WIFI_read16(&wifiMac,adr) | (WIFI_read16(&wifiMac,adr+2) << 16)); #endif +#ifdef EXPERIMENTAL_GBASLOT if ( (adr >= 0x08000000) && (adr < 0x0A010000) ) return addon.read32(adr); +#else + // CFlash reading, Mic + if ((adr>=0x9000000)&&(adr<0x9900000)) + return (u32)cflash_read(adr); +#endif adr &= 0x0FFFFFFF; @@ -3599,7 +3976,7 @@ u32 FASTCALL _MMU_ARM7_read32(u32 adr) T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM7][0x40], 0x1A4) & 0x7F7FFFFF); // if needed, throw irq for the end of transfer - if(MMU.AUX_SPI_CNT & 0x4000) + if(T1ReadWord(MMU.MMU_MEM[ARMCPU_ARM7][0x40], 0x1A0) & 0x4000) NDS_makeInt(ARMCPU_ARM7, 19); return val; @@ -3681,10 +4058,17 @@ void FASTCALL MMU_DumpMemBlock(u8 proc, u32 address, u32 size, u8 *buffer) for(i = 0, curaddr = address; i < size; i++, curaddr++) { - buffer[i] = _MMU_read08(proc,MMU_AT_GPU,curaddr); + buffer[i] = T1ReadByte(MMU.MMU_MEM[proc][(curaddr >> 20) & 0xFF], (curaddr & MMU.MMU_MASK[proc][(curaddr >> 20) & 0xFF])); } } +void mmu_select_savetype(int type, int *bmemtype, u32 *bmemsize) { + if (type<0 || type > 6) return; + *bmemtype=save_types[type][0]; + *bmemsize=save_types[type][1]; + mc_realloc(&MMU.bupmem, *bmemtype, *bmemsize); +} + //////////////////////////////////////////////////////////// //function pointer handlers for gdb stub stuff diff --git a/desmume/src/MMU.h b/src/MMU.h similarity index 80% rename from desmume/src/MMU.h rename to src/MMU.h index dc2ef1649..ffc29ed21 100644 --- a/desmume/src/MMU.h +++ b/src/MMU.h @@ -97,7 +97,7 @@ struct MMU_struct { u32 reg_IF[2]; u32 DMAStartTime[2][4]; - u64 DMACycle[2][4]; + s32 DMACycle[2][4]; u32 DMACrt[2][4]; BOOL DMAing[2][4]; @@ -105,19 +105,16 @@ struct MMU_struct { s64 divResult; s64 divMod; u32 divCnt; - u64 divCycles; + s32 divCycles; BOOL sqrtRunning; u32 sqrtResult; u32 sqrtCnt; - u64 sqrtCycles; + s32 sqrtCycles; - u16 SPI_CNT; - u16 SPI_CMD; - u16 AUX_SPI_CNT; - u16 AUX_SPI_CMD; - - u64 gfx3dCycles; +#ifdef USE_GEOMETRY_FIFO_EMULATION + s32 gfx3dCycles; +#endif u8 powerMan_CntReg; BOOL powerMan_CntRegWritten; @@ -131,13 +128,7 @@ struct MMU_struct { u32 CheckDMAs; }; -struct MMU_struct_new -{ - BackupDevice backupDevice; -}; - extern MMU_struct MMU; -extern MMU_struct_new MMU_new; struct armcpu_memory_iface { @@ -165,6 +156,8 @@ struct armcpu_memory_iface { }; +void mmu_select_savetype(int type, int *bmemtype, u32 *bmemsize); + void MMU_Init(void); void MMU_DeInit(void); @@ -190,52 +183,15 @@ extern struct armcpu_memory_iface arm9_base_memory_iface; extern struct armcpu_memory_iface arm7_base_memory_iface; extern struct armcpu_memory_iface arm9_direct_memory_iface; -#define VRAM_BANKS 9 -#define VRAM_BANK_A 0 -#define VRAM_BANK_B 1 -#define VRAM_BANK_C 2 -#define VRAM_BANK_D 3 -#define VRAM_BANK_E 4 -#define VRAM_BANK_F 5 -#define VRAM_BANK_G 6 -#define VRAM_BANK_H 7 -#define VRAM_BANK_I 8 - -#define VRAM_PAGE_ABG 0 -#define VRAM_PAGE_BBG 128 -#define VRAM_PAGE_AOBJ 256 -#define VRAM_PAGE_BOBJ 384 - - -struct VramConfiguration { - - enum Purpose { - OFF, INVALID, ABG, BBG, AOBJ, BOBJ, LCDC, ARM7, TEX, TEXPAL, ABGEXTPAL, BBGEXTPAL, AOBJEXTPAL, BOBJEXTPAL - }; - - struct BankInfo { - Purpose purpose; - int ofs; - } banks[VRAM_BANKS]; - - inline void clear() { - for(int i=0;i u8 _MMU_read08(u32 addr); @@ -300,29 +256,7 @@ inline void SetupMMU(bool debugConsole) { //T1ReadWord(MMU.MMU_MEM[ARMCPU_ARM7][(adr >> 20) & 0xFF], // adr & MMU.MMU_MASK[ARMCPU_ARM7][(adr >> 20) & 0xFF]); -enum EDMAMode -{ - EDMAMode_Immediate = 0, - EDMAMode_VBlank = 1, - EDMAMode_HBlank = 2, - EDMAMode_HStart = 3, - EDMAMode_MemDisplay = 4, - EDMAMode_Card = 5, - EDMAMode_GBASlot = 6, - EDMAMode_GXFifo = 7, - EDMAMode7_Wifi = 8, - EDMAMode7_GBASlot = 9, -}; - -FORCEINLINE u8 _MMU_read08(const int PROCNUM, const MMU_ACCESS_TYPE AT, const u32 addr) -{ - //special handling for DMA: read 0 from TCM - if(PROCNUM==ARMCPU_ARM9 && AT == MMU_AT_DMA) - { - if(addr<0x02000000) return 0; //itcm - if((addr&(~0x3FFF)) == MMU.DTCMRegion) return 0; //dtcm - } - +FORCEINLINE u8 _MMU_read08(const int PROCNUM, const MMU_ACCESS_TYPE AT, const u32 addr) { if(PROCNUM==ARMCPU_ARM9) if((addr&(~0x3FFF)) == MMU.DTCMRegion) { @@ -337,15 +271,7 @@ FORCEINLINE u8 _MMU_read08(const int PROCNUM, const MMU_ACCESS_TYPE AT, const u3 else return _MMU_ARM7_read08(addr); } -FORCEINLINE u16 _MMU_read16(const int PROCNUM, const MMU_ACCESS_TYPE AT, const u32 addr) -{ - //special handling for DMA: read 0 from TCM - if(PROCNUM==ARMCPU_ARM9 && AT == MMU_AT_DMA) - { - if(addr<0x02000000) return 0; //itcm - if((addr&(~0x3FFF)) == MMU.DTCMRegion) return 0; //dtcm - } - +FORCEINLINE u16 _MMU_read16(const int PROCNUM, const MMU_ACCESS_TYPE AT, const u32 addr) { //special handling for execution from arm9, since we spend so much time in there if(PROCNUM==ARMCPU_ARM9 && AT == MMU_AT_CODE) { @@ -373,15 +299,7 @@ dunno: else return _MMU_ARM7_read16(addr); } -FORCEINLINE u32 _MMU_read32(const int PROCNUM, const MMU_ACCESS_TYPE AT, const u32 addr) -{ - //special handling for DMA: read 0 from TCM - if(PROCNUM==ARMCPU_ARM9 && AT == MMU_AT_DMA) - { - if(addr<0x02000000) return 0; //itcm - if((addr&(~0x3FFF)) == MMU.DTCMRegion) return 0; //dtcm - } - +FORCEINLINE u32 _MMU_read32(const int PROCNUM, const MMU_ACCESS_TYPE AT, const u32 addr) { //special handling for execution from arm9, since we spend so much time in there if(PROCNUM==ARMCPU_ARM9 && AT == MMU_AT_CODE) { @@ -424,15 +342,7 @@ dunno: else return _MMU_ARM7_read32(addr); } -FORCEINLINE void _MMU_write08(const int PROCNUM, const MMU_ACCESS_TYPE AT, const u32 addr, u8 val) -{ - //special handling for DMA: discard writes to TCM - if(PROCNUM==ARMCPU_ARM9 && AT == MMU_AT_DMA) - { - if(addr<0x02000000) return; //itcm - if((addr&(~0x3FFF)) == MMU.DTCMRegion) return; //dtcm - } - +FORCEINLINE void _MMU_write08(const int PROCNUM, const MMU_ACCESS_TYPE AT, const u32 addr, u8 val) { if(PROCNUM==ARMCPU_ARM9) if((addr&(~0x3FFF)) == MMU.DTCMRegion) { @@ -449,15 +359,7 @@ FORCEINLINE void _MMU_write08(const int PROCNUM, const MMU_ACCESS_TYPE AT, const else _MMU_ARM7_write08(addr,val); } -FORCEINLINE void _MMU_write16(const int PROCNUM, const MMU_ACCESS_TYPE AT, const u32 addr, u16 val) -{ - //special handling for DMA: discard writes to TCM - if(PROCNUM==ARMCPU_ARM9 && AT == MMU_AT_DMA) - { - if(addr<0x02000000) return; //itcm - if((addr&(~0x3FFF)) == MMU.DTCMRegion) return; //dtcm - } - +FORCEINLINE void _MMU_write16(const int PROCNUM, const MMU_ACCESS_TYPE AT, const u32 addr, u16 val) { if(PROCNUM==ARMCPU_ARM9) if((addr&(~0x3FFF)) == MMU.DTCMRegion) { @@ -474,15 +376,7 @@ FORCEINLINE void _MMU_write16(const int PROCNUM, const MMU_ACCESS_TYPE AT, const else _MMU_ARM7_write16(addr,val); } -FORCEINLINE void _MMU_write32(const int PROCNUM, const MMU_ACCESS_TYPE AT, const u32 addr, u32 val) -{ - //special handling for DMA: discard writes to TCM - if(PROCNUM==ARMCPU_ARM9 && AT == MMU_AT_DMA) - { - if(addr<0x02000000) return; //itcm - if((addr&(~0x3FFF)) == MMU.DTCMRegion) return; //dtcm - } - +FORCEINLINE void _MMU_write32(const int PROCNUM, const MMU_ACCESS_TYPE AT, const u32 addr, u32 val) { if(PROCNUM==ARMCPU_ARM9) if((addr&(~0x3FFF)) == MMU.DTCMRegion) { @@ -534,22 +428,22 @@ FORCEINLINE void _MMU_write32(const int PROCNUM, const MMU_ACCESS_TYPE AT, const #endif template -FORCEINLINE u8 _MMU_read08(u32 addr) { return _MMU_read08(PROCNUM, AT, addr); } +u8 _MMU_read08(u32 addr) { return _MMU_read08(PROCNUM, AT, addr); } template -FORCEINLINE u16 _MMU_read16(u32 addr) { return _MMU_read16(PROCNUM, AT, addr); } +u16 _MMU_read16(u32 addr) { return _MMU_read16(PROCNUM, AT, addr); } template -FORCEINLINE u32 _MMU_read32(u32 addr) { return _MMU_read32(PROCNUM, AT, addr); } +u32 _MMU_read32(u32 addr) { return _MMU_read32(PROCNUM, AT, addr); } template -FORCEINLINE void _MMU_write08(u32 addr, u8 val) { _MMU_write08(PROCNUM, AT, addr, val); } +void _MMU_write08(u32 addr, u8 val) { _MMU_write08(PROCNUM, AT, addr, val); } template -FORCEINLINE void _MMU_write16(u32 addr, u16 val) { _MMU_write16(PROCNUM, AT, addr, val); } +void _MMU_write16(u32 addr, u16 val) { _MMU_write16(PROCNUM, AT, addr, val); } template -FORCEINLINE void _MMU_write32(u32 addr, u32 val) { _MMU_write32(PROCNUM, AT, addr, val); } +void _MMU_write32(u32 addr, u32 val) { _MMU_write32(PROCNUM, AT, addr, val); } void FASTCALL MMU_DumpMemBlock(u8 proc, u32 address, u32 size, u8 *buffer); diff --git a/desmume/src/Makefile.am b/src/Makefile.am similarity index 76% rename from desmume/src/Makefile.am rename to src/Makefile.am index 755b08edb..876d227ba 100644 --- a/desmume/src/Makefile.am +++ b/src/Makefile.am @@ -1,8 +1,9 @@ include $(top_srcdir)/src/desmume.mk -AM_CPPFLAGS += $(SDL_CFLAGS) $(GTK_CFLAGS) $(GTHREAD_CFLAGS) $(X_CFLAGS) $(LUA_CFLAGS) $(ALSA_CFLAGS) $(LIBAGG_CFLAGS) +AM_CPPFLAGS += $(SDL_CFLAGS) $(GTK_CFLAGS) $(GTHREAD_CFLAGS) $(LUA_CFLAGS) -EXTRA_DIST = build.bat instruction_tabdef.inc thumb_tabdef.inc fs-linux.cpp fs-windows.cpp +EXTRA_DIST = build.bat instruction_tabdef.inc thumb_tabdef.inc fs-linux.cpp fs-windows.cpp \ + matrix_sse2-x64.asm matrix_sse2-x86.asm if HAVE_GDB_STUB SUBDIRS = . gdbstub $(UI_DIR) else @@ -14,15 +15,16 @@ libdesmume_a_SOURCES = \ armcpu.cpp armcpu.h ARM9.h \ arm_instructions.cpp arm_instructions.h \ bios.cpp bios.h bits.h cp15.cpp cp15.h \ - common.cpp common.h \ + cflash.cpp cflash.h fs.h \ + common.cpp common.h commandline.h commandline.cpp \ debug.cpp debug.h driver.h \ Disassembler.cpp Disassembler.h \ dscard.h fat.h FIFO.cpp FIFO.h \ + GPU_osd.cpp GPU_osd.h \ GPU.cpp GPU.h \ GPU_osd.cpp GPU_osd.h \ mem.h mc.cpp mc.h \ memorystream.h \ - path.h \ readwrite.cpp readwrite.h \ wifi.cpp wifi.h \ MMU.cpp MMU.h NDSSystem.cpp NDSSystem.h registers.h \ @@ -32,6 +34,8 @@ libdesmume_a_SOURCES = \ rtc.cpp rtc.h \ saves.cpp saves.h \ SPU.cpp SPU.h \ + softrender.cpp softrender.h softrender_config.h \ + softrender_v3sysfont.h softrender_desmumefont.h \ matrix.cpp matrix.h \ gfx3d.cpp gfx3d.h \ texcache.cpp texcache.h \ @@ -44,22 +48,10 @@ libdesmume_a_SOURCES = \ utils/decrypt/crc.cpp utils/decrypt/crc.h utils/decrypt/decrypt.cpp \ utils/decrypt/decrypt.h utils/decrypt/header.cpp utils/decrypt/header.h \ addons.cpp addons.h \ - addons/compactFlash.cpp addons/gbagame.cpp addons/none.cpp addons/rumblepak.cpp addons/guitarGrip.cpp fs.h \ + addons/compactFlash.cpp addons/gbagame.cpp addons/none.cpp addons/rumblepak.cpp \ + mic.cpp mic.h \ cheatSystem.cpp cheatSystem.h \ - texcache.cpp texcache.h rasterize.cpp rasterize.h \ - version.h - -if HAVE_GLIB -libdesmume_a_SOURCES += commandline.h commandline.cpp -endif -if HAVE_ALSA -libdesmume_a_SOURCES += mic_alsa.cpp -else -libdesmume_a_SOURCES += mic.cpp -endif -if HAVE_LIBAGG -libdesmume_a_SOURCES += aggdraw.cpp -endif + texcache.cpp texcache.h rasterize.cpp rasterize.h if HAVE_LUA libdesmume_a_SOURCES += lua-engine.cpp endif diff --git a/desmume/src/NDSSystem.cpp b/src/NDSSystem.cpp similarity index 57% rename from desmume/src/NDSSystem.cpp rename to src/NDSSystem.cpp index 6039cdf70..da436ffc5 100644 --- a/desmume/src/NDSSystem.cpp +++ b/src/NDSSystem.cpp @@ -31,6 +31,9 @@ #include "NDSSystem.h" #include "render3D.h" #include "MMU.h" +#ifndef EXPERIMENTAL_GBASLOT +#include "cflash.h" +#endif #include "ROMReader.h" #include "gfx3d.h" #include "utils/decrypt/decrypt.h" @@ -39,28 +42,14 @@ #include "debug.h" #include "cheatSystem.h" #include "movie.h" -#include "Disassembler.h" -#include "readwrite.h" #ifdef _WIN32 #include "./windows/disView.h" +#include "./windows/aviout.h" +#include "./windows/wavout.h" #endif -#include "path.h" - -PathInfo path; - -//this doesnt work anyway. why take a speed hit for public releases? -// Luigi__: I don't agree. We should start include wifi emulation in public releases -// because it already allows games to not hang during wifi operations -// and thus games that perform wifi checks upon boot shouldn't hang with wifi -// emulation turned on. -// zeromus: which games are these? I would like to see what happens. -// this is a substantial framerate hit. we should consider an emulation option -// to indicate whether this whole system should be enabled -#ifndef PUBLIC_RELEASE -#undef EXPERIMENTAL_WIFI -#endif +//#define USE_REAL_BIOS TCommonSettings CommonSettings; static BaseDriver _stub_driver; @@ -69,20 +58,18 @@ std::string InputDisplayString; static BOOL LidClosed = FALSE; static u8 countLid = 0; - +char pathToROM[MAX_PATH]; +char pathFilenameToROMwithoutExt[MAX_PATH]; GameInfo gameInfo; -// the count of bytes copied from the firmware into memory +/* the count of bytes copied from the firmware into memory */ #define NDS_FW_USER_SETTINGS_MEM_BYTE_COUNT 0x70 BOOL fw_success = FALSE; NDSSystem nds; -using std::min; -using std::max; - int lagframecounter; int LagFrameFlag; int lastLag; @@ -497,15 +484,6 @@ copy_firmware_user_data( u8 *dest_buffer, const u8 *fw_data) { return copy_good; } -void Desmume_InitOnce() -{ - static bool initOnce = false; - if(initOnce) return; - initOnce = true; - - extern void Agg_init(); //no need to include just for this - Agg_init(); -} #ifdef GDB_STUB int NDS_Init( struct armcpu_memory_iface *arm9_mem_if, @@ -515,10 +493,15 @@ struct armcpu_ctrl_iface **arm7_ctrl_iface) { #else int NDS_Init( void) { #endif + nds.ARM9Cycle = 0; + nds.ARM7Cycle = 0; + nds.cycles = 0; nds.idleFrameCounter = 0; memset(nds.runCycleCollector,0,sizeof(nds.runCycleCollector)); MMU_Init(); + nds.nextHBlank = 3168; nds.VCount = 0; + nds.lignerendu = FALSE; nds.sleeping = FALSE; @@ -553,6 +536,7 @@ void NDS_DeInit(void) { if(MMU.CART_ROM != MMU.UNUSED_RAM) NDS_FreeROM(); + nds.nextHBlank = 3168; SPU_DeInit(); Screen_DeInit(); MMU_DeInit(); @@ -730,121 +714,13 @@ void GameInfo::populate() memset(ROMserial+19, '\0', 1); } } -#ifdef WIN32 -#include "memorystream.h" -#include -static std::vector buffer; -static std::vector v; - -static void loadrom(std::vector* buf, std::string fname) { - - FILE* inf = fopen(fname.c_str(),"rb"); - if(!inf) return; - - fseek(inf,0,SEEK_END); - int size = ftell(inf); - fseek(inf,0,SEEK_SET); - - gameInfo.resize(size); - fread(gameInfo.romdata,1,size,inf); - - fclose(inf); -} - -int NDS_LoadROM(const char *filename, const char *logicalFilename) -{ - int type; - u32 mask; - char buf[MAX_PATH]; - - if (filename == NULL) - return -1; - - path.init(filename); - - if ( path.isdsgba(path.path)) { - type = ROM_DSGBA; - loadrom(&buffer, path.path); - gameInfo.romsize = buffer.size(); - } - else if ( !strcasecmp(path.extension().c_str(), "nds")) { - loadrom(NULL, path.path); //n.b. this does nothing if the file can't be found (i.e. if it was an extracted tempfile)... - //...but since the data was extracted to gameInfo then it is ok - type = ROM_NDS; - } - //ds.gba in archives, it's already been loaded into memory at this point - else if (path.isdsgba(std::string(logicalFilename))) { - - std::vector v(gameInfo.romdata, gameInfo.romdata + gameInfo.romsize); - v.erase(v.begin(),v.begin()+DSGBA_LOADER_SIZE); - buffer.assign( v.begin(), v.end() ); - gameInfo.romdata = &buffer[0]; - gameInfo.romsize = buffer.size(); - } - - if(type == ROM_DSGBA) - { - buffer.erase(buffer.begin(),buffer.begin()+DSGBA_LOADER_SIZE); - gameInfo.romdata = &buffer[0]; - gameInfo.romsize = buffer.size(); - } - - //check that size is at least the size of the header - if (gameInfo.romsize < 352+160) { - return -1; - } - - //zero 25-dec-08 - this used to yield a mask which was 2x large - //mask = size; - mask = gameInfo.romsize-1; - mask |= (mask >>1); - mask |= (mask >>2); - mask |= (mask >>4); - mask |= (mask >>8); - mask |= (mask >>16); - - //decrypt if necessary.. - //but this is untested and suspected to fail on big endian, so lets not support this on big endian - -#ifndef WORDS_BIGENDIAN - bool okRom = DecryptSecureArea((u8*)gameInfo.romdata,gameInfo.romsize); - - if(!okRom) { - printf("Specified file is not a valid rom\n"); - return -1; - } -#endif - - cheatsSearchClose(); - MMU_unsetRom(); - NDS_SetROM((u8*)gameInfo.romdata, mask); - NDS_Reset(); - - memset(buf, 0, MAX_PATH); - - path.getpathnoext(path.BATTERY, buf); - - strcat(buf, ".dsv"); // DeSmuME memory card :) - - MMU_new.backupDevice.load_rom(buf); - - memset(buf, 0, MAX_PATH); - - path.getpathnoext(path.CHEATS, buf); - - strcat(buf, ".dct"); // DeSmuME cheat :) - cheatsInit(buf); - - gameInfo.populate(); - gameInfo.crc = crc32(0,(u8*)gameInfo.romdata,gameInfo.romsize); - INFO("\nROM crc: %08X\n\n", gameInfo.crc); - INFO("\nROM serial: %s\n", gameInfo.ROMserial); - - return 1; -} +#ifdef EXPERIMENTAL_GBASLOT +int NDS_LoadROM( const char *filename, int bmtype, u32 bmsize, const char* logicalFilename) #else -int NDS_LoadROM(const char *filename, const char *logicalFilename) +int NDS_LoadROM( const char *filename, int bmtype, u32 bmsize, + const char *cflash_disk_image_file, const char* logicalFilename) +#endif { int ret; int type; @@ -854,19 +730,55 @@ int NDS_LoadROM(const char *filename, const char *logicalFilename) u8 *data; char *noext; char buf[MAX_PATH]; + char extROM[MAX_PATH]; + char extROM2[5]; if (filename == NULL) return -1; + memset(pathToROM, 0, MAX_PATH); + memset(pathFilenameToROMwithoutExt, 0, MAX_PATH); + memset(extROM, 0, MAX_PATH); + memset(extROM2, 0, 5); + noext = strdup(filename); reader = ROMReaderInit(&noext); - if(logicalFilename) path.init(logicalFilename); - else path.init(filename); - if(!strcasecmp(path.extension().c_str(), "zip")) type = ROM_NDS; - else if ( !strcasecmp(path.extension().c_str(), "nds")) + if(logicalFilename) + { + for (int t = strlen(logicalFilename); t>0; t--) + if ( (logicalFilename[t] == '\\') || (logicalFilename[t] == '/') ) + { + strncpy(pathToROM, logicalFilename, t+1); + break; + } + } + else + { + for (int t = strlen(filename); t>0; t--) + if ( (filename[t] == '\\') || (filename[t] == '/') ) + { + strncpy(pathToROM, filename, t+1); + break; + } + } + + for (int t = strlen(filename); t>0; t--) + if ( (filename[t] == '\\') || (filename[t] == '/') || (filename[t] == '.') ) + { + if (filename[t] != '.') return -1; + strncpy(pathFilenameToROMwithoutExt, filename, t); + strncpy(extROM, filename+t, strlen(filename) - t); + if (t>4) + strncpy(extROM2, filename+(t-3), 3); + break; + } + + if(!strcasecmp(extROM, ".zip")) type = ROM_NDS; - else if ( path.isdsgba(path.path)) + else if ( !strcasecmp(extROM, ".nds")) + type = ROM_NDS; + else if ( !strcasecmp(extROM, ".gba") && !strcasecmp(extROM2, ".ds")) type = ROM_DSGBA; else type = ROM_NDS; @@ -936,20 +848,33 @@ int NDS_LoadROM(const char *filename, const char *logicalFilename) NDS_SetROM(data, mask); NDS_Reset(); +#ifndef EXPERIMENTAL_GBASLOT + cflash_close(); + cflash_init(cflash_disk_image_file); +#endif free(noext); memset(buf, 0, MAX_PATH); - path.getpathnoext(path.BATTERY, buf); - - strcat(buf, ".dsv"); // DeSmuME memory card :) + #ifdef WIN32 + GetFullPathNoExt(BATTERY, buf, MAX_PATH); + #else + strcpy(buf, pathFilenameToROMwithoutExt); + #endif - MMU_new.backupDevice.load_rom(buf); + strcat(buf, ".sav"); // DeSmuME memory card :) + + mc_realloc(&MMU.bupmem, bmtype, bmsize); + mc_load_file(&MMU.bupmem, buf); memset(buf, 0, MAX_PATH); - path.getpathnoext(path.CHEATS, buf); - + #ifdef WIN32 + GetFullPathNoExt(CHEATS, buf, MAX_PATH); + #else + strcpy(buf, pathFilenameToROMwithoutExt); + #endif + strcat(buf, ".dct"); // DeSmuME cheat :) cheatsInit(buf); @@ -960,7 +885,33 @@ int NDS_LoadROM(const char *filename, const char *logicalFilename) return ret; } -#endif + +void MovieSRAM() +{ + int bmtype = MMU.bupmem.type; + u32 bmsize = MMU.bupmem.size; + + char buf[MAX_PATH]; + + memset(buf, 0, MAX_PATH); + strcpy(buf, pathFilenameToROMwithoutExt); + strcat(buf, ".sav"); // DeSmuME memory card :) + + if(movieMode != MOVIEMODE_INACTIVE) { + strcat(buf, "movie"); + } + + if (MMU.bupmem.fp) + { + fclose(MMU.bupmem.fp); + MMU.bupmem.fp = NULL; + } + + + mc_realloc(&MMU.bupmem, bmtype, bmsize); + mc_load_file(&MMU.bupmem, buf); +} + void NDS_FreeROM(void) { if (MMU.CART_ROM != MMU.UNUSED_RAM) @@ -971,7 +922,202 @@ void NDS_FreeROM(void) MMU.bupmem.fp = NULL; } +bool _HACK_DONT_STOPMOVIE = false; +void NDS_Reset() +{ + unsigned int i; + u32 src; + u32 dst; + FILE* inf = 0; + NDS_header * header = NDS_getROMHeader(); + if (!header) return ; + + if(movieMode != MOVIEMODE_INACTIVE && !_HACK_DONT_STOPMOVIE) + movie_reset_command = true; + + if(movieMode == MOVIEMODE_INACTIVE) { + currFrameCounter = 0; + lagframecounter = 0; + LagFrameFlag = 0; + lastLag = 0; + TotalLagFrames = 0; + } + + MMU_clearMem(); + + //ARM7 BIOS IRQ HANDLER + if(CommonSettings.UseExtBIOS == true) + inf = fopen(CommonSettings.ARM7BIOS,"rb"); + else + inf = NULL; + + if(inf) { + fread(MMU.ARM7_BIOS,1,16384,inf); + fclose(inf); + if(CommonSettings.SWIFromBIOS == true) NDS_ARM7.swi_tab = 0; + else NDS_ARM7.swi_tab = ARM7_swi_tab; + INFO("ARM7 BIOS is loaded.\n"); + } else { + NDS_ARM7.swi_tab = ARM7_swi_tab; + _MMU_write32(0x00, 0xE25EF002); + _MMU_write32(0x04, 0xEAFFFFFE); + _MMU_write32(0x18, 0xEA000000); + _MMU_write32(0x20, 0xE92D500F); + _MMU_write32(0x24, 0xE3A00301); + _MMU_write32(0x28, 0xE28FE000); + _MMU_write32(0x2C, 0xE510F004); + _MMU_write32(0x30, 0xE8BD500F); + _MMU_write32(0x34, 0xE25EF004); + } + + //ARM9 BIOS IRQ HANDLER + if(CommonSettings.UseExtBIOS == true) + inf = fopen(CommonSettings.ARM9BIOS,"rb"); + else + inf = NULL; + //memcpy(ARM9Mem.ARM9_BIOS + 0x20, gba_header_data_0x04, 156); + + if(inf) { + fread(ARM9Mem.ARM9_BIOS,1,4096,inf); + fclose(inf); + if(CommonSettings.SWIFromBIOS == true) NDS_ARM9.swi_tab = 0; + else NDS_ARM9.swi_tab = ARM9_swi_tab; + INFO("ARM9 BIOS is loaded.\n"); + } else { + NDS_ARM9.swi_tab = ARM9_swi_tab; + _MMU_write32(0xFFFF0018, 0xEA000000); + _MMU_write32(0xFFFF0020, 0xE92D500F); + _MMU_write32(0xFFFF0024, 0xEE190F11); + _MMU_write32(0xFFFF0028, 0xE1A00620); + _MMU_write32(0xFFFF002C, 0xE1A00600); + _MMU_write32(0xFFFF0030, 0xE2800C40); + _MMU_write32(0xFFFF0034, 0xE28FE000); + _MMU_write32(0xFFFF0038, 0xE510F004); + _MMU_write32(0xFFFF003C, 0xE8BD500F); + _MMU_write32(0xFFFF0040, 0xE25EF004); + } + + /* Is it really needed ??? */ + _MMU_write32(0x0000004, 0xE3A0010E); + _MMU_write32(0x0000008, 0xE3A01020); + // _MMU_write32(0x000000C, 0xE1B02110); + _MMU_write32(0x000000C, 0xE1B02040); + _MMU_write32(0x0000010, 0xE3B02020); + // _MMU_write32(0x0000010, 0xE2100202); + + if(CommonSettings.UseExtFirmware == true) + NDS_LoadFirmware(CommonSettings.Firmware); + + if((CommonSettings.UseExtBIOS == true) && (CommonSettings.UseExtFirmware == true) && (CommonSettings.BootFromFirmware == true) && (fw_success == TRUE)) + { + for(i = 0; i < nds.FW_ARM9BootCodeSize; i += 4) + { + _MMU_write32((nds.FW_ARM9BootCodeAddr + i), T1ReadLong(nds.FW_ARM9BootCode, i)); + } + + for(i = 0; i < nds.FW_ARM7BootCodeSize; i += 4) + { + _MMU_write32((nds.FW_ARM7BootCodeAddr + i), T1ReadLong(nds.FW_ARM7BootCode, i)); + } + + armcpu_init(&NDS_ARM9, nds.FW_ARM9BootCodeAddr); + armcpu_init(&NDS_ARM7, nds.FW_ARM7BootCodeAddr); + //armcpu_init(&NDS_ARM9, 0xFFFF0000); + //armcpu_init(&NDS_ARM7, 0x00000000); + } + else + { + src = header->ARM9src; + dst = header->ARM9cpy; + + for(i = 0; i < (header->ARM9binSize>>2); ++i) + { + _MMU_write32(dst, T1ReadLong(MMU.CART_ROM, src)); + dst += 4; + src += 4; + } + + src = header->ARM7src; + dst = header->ARM7cpy; + + for(i = 0; i < (header->ARM7binSize>>2); ++i) + { + _MMU_write32(dst, T1ReadLong(MMU.CART_ROM, src)); + dst += 4; + src += 4; + } + + armcpu_init(&NDS_ARM7, header->ARM7exe); + armcpu_init(&NDS_ARM9, header->ARM9exe); + } + + nds.ARM9Cycle = 0; + nds.ARM7Cycle = 0; + nds.cycles = 0; + memset(nds.timerCycle, 0, sizeof(s32) * 2 * 4); + memset(nds.timerOver, 0, sizeof(BOOL) * 2 * 4); + nds.nextHBlank = 3168; + nds.VCount = 0; + nds.old = 0; + nds.diff = 0; + nds.lignerendu = FALSE; + nds.touchX = nds.touchY = 0; + nds.isTouch = 0; + nds.debugConsole = CommonSettings.DebugConsole; + SetupMMU(nds.debugConsole); + + _MMU_write16(0x04000130, 0x3FF); + _MMU_write16(0x04000130, 0x3FF); + _MMU_write08(0x04000136, 0x43); + + LidClosed = FALSE; + countLid = 0; + + /* + * Setup a copy of the firmware user settings in memory. + * (this is what the DS firmware would do). + */ + { + u8 temp_buffer[NDS_FW_USER_SETTINGS_MEM_BYTE_COUNT]; + int fw_index; + + if ( copy_firmware_user_data( temp_buffer, MMU.fw.data)) { + for ( fw_index = 0; fw_index < NDS_FW_USER_SETTINGS_MEM_BYTE_COUNT; fw_index++) + _MMU_write08(0x027FFC80 + fw_index, temp_buffer[fw_index]); + } + } + + // Copy the whole header to Main RAM 0x27FFE00 on startup. + // Reference: http://nocash.emubase.de/gbatek.htm#dscartridgeheader + for (i = 0; i < ((0x170+0x90)/4); i++) { + _MMU_write32(0x027FFE00+i*4, LE_TO_LOCAL_32(((u32*)MMU.CART_ROM)[i])); + } + + // Write the header checksum to memory (the firmware needs it to see the cart) + _MMU_write16(0x027FF808, T1ReadWord(MMU.CART_ROM, 0x15E)); + + MainScreen.offset = 0; + SubScreen.offset = 192; + + //_MMU_write32[ARMCPU_ARM9](0x02007FFC, 0xE92D4030); + + delete header; + + Screen_Reset(); + gfx3d_reset(); + gpu3D->NDS_3D_Reset(); + SPU_Reset(); + +#ifdef EXPERIMENTAL_WIFI + WIFI_Init(&wifiMac); + + WIFI_SoftAP_Shutdown(&wifiMac); + WIFI_SoftAP_Init(&wifiMac); +#endif + + memcpy(FW_Mac, (MMU.fw.data + 0x36), 6); +} int NDS_ImportSave(const char *filename) { @@ -979,9 +1125,7 @@ int NDS_ImportSave(const char *filename) return 0; if (memcmp(filename+strlen(filename)-4, ".duc", 4) == 0) - return MMU_new.backupDevice.load_duc(filename); - else - return MMU_new.backupDevice.load_raw(filename); + return mc_load_duc(&MMU.bupmem, filename); return 0; } @@ -991,8 +1135,14 @@ bool NDS_ExportSave(const char *filename) if (strlen(filename) < 4) return false; - if (memcmp(filename+strlen(filename)-4, ".sav", 4) == 0) - return MMU_new.backupDevice.save_raw(filename); + if (memcmp(filename+strlen(filename)-4, ".sav", 4) == 0) { + FILE* outf = fopen(filename,"wb"); + if(!outf) return false; + if(MMU.bupmem.size>0) + fwrite((char*)MMU.bupmem.data,1,MMU.bupmem.size,outf); + fclose(outf); + return true; + } return false; } @@ -1035,7 +1185,7 @@ int NDS_WritePNG(const char *fname) int x, y; int width=256; int height=192*2; - u16 * bmp = (u16 *)GPU_screen; + u16 * bmp = (u16 *)GPU_tempScreen; FILE *pp=NULL; uint8 *compmem = NULL; uLongf compmemsize = (uLongf)( (height * (width + 1) * 3 * 1.001 + 1) + 12 ); @@ -1161,7 +1311,7 @@ int NDS_WriteBMP(const char *filename) bmpimgheader_struct imageheader; FILE *file; int i,j; - u16 * bmp = (u16 *)GPU_screen; + u16 * bmp = (u16 *)GPU_tempScreen; size_t elems_written = 0; memset(&fileheader, 0, sizeof(fileheader)); @@ -1250,140 +1400,145 @@ int NDS_WriteBMP_32bppBuffer(int width, int height, const void* buf, const char } -static void fill_user_data_area( struct NDS_fw_config_data *user_settings,u8 *data, int count) -{ - u32 crc; - int i; - u8 *ts_cal_data_area; +static void +fill_user_data_area( struct NDS_fw_config_data *user_settings, + u8 *data, int count) { + u32 crc; + int i; + u8 *ts_cal_data_area; - memset( data, 0, 0x100); + memset( data, 0, 0x100); - // version - data[0x00] = 5; - data[0x01] = 0; + /* version */ + data[0x00] = 5; + data[0x01] = 0; - // colour - data[0x02] = user_settings->fav_colour; + /* colour */ + data[0x02] = user_settings->fav_colour; - // birthday month and day - data[0x03] = user_settings->birth_month; - data[0x04] = user_settings->birth_day; + /* birthday month and day */ + data[0x03] = user_settings->birth_month; + data[0x04] = user_settings->birth_day; - //nickname and length - for ( i = 0; i < MAX_FW_NICKNAME_LENGTH; i++) { - data[0x06 + (i * 2)] = user_settings->nickname[i] & 0xff; - data[0x06 + (i * 2) + 1] = (user_settings->nickname[i] >> 8) & 0xff; - } + /* nickname and length */ + for ( i = 0; i < MAX_FW_NICKNAME_LENGTH; i++) { + data[0x06 + (i * 2)] = user_settings->nickname[i] & 0xff; + data[0x06 + (i * 2) + 1] = (user_settings->nickname[i] >> 8) & 0xff; + } - data[0x1a] = user_settings->nickname_len; + data[0x1a] = user_settings->nickname_len; - //Message - for ( i = 0; i < MAX_FW_MESSAGE_LENGTH; i++) { - data[0x1c + (i * 2)] = user_settings->message[i] & 0xff; - data[0x1c + (i * 2) + 1] = (user_settings->message[i] >> 8) & 0xff; - } + /* Message */ + for ( i = 0; i < MAX_FW_MESSAGE_LENGTH; i++) { + data[0x1c + (i * 2)] = user_settings->message[i] & 0xff; + data[0x1c + (i * 2) + 1] = (user_settings->message[i] >> 8) & 0xff; + } - data[0x50] = user_settings->message_len; + data[0x50] = user_settings->message_len; - //touch screen calibration - ts_cal_data_area = &data[0x58]; - for ( i = 0; i < 2; i++) { - // ADC x y - *ts_cal_data_area++ = user_settings->touch_cal[i].adc_x & 0xff; - *ts_cal_data_area++ = (user_settings->touch_cal[i].adc_x >> 8) & 0xff; - *ts_cal_data_area++ = user_settings->touch_cal[i].adc_y & 0xff; - *ts_cal_data_area++ = (user_settings->touch_cal[i].adc_y >> 8) & 0xff; + /* + * touch screen calibration + */ + ts_cal_data_area = &data[0x58]; + for ( i = 0; i < 2; i++) { + /* ADC x y */ + *ts_cal_data_area++ = user_settings->touch_cal[i].adc_x & 0xff; + *ts_cal_data_area++ = (user_settings->touch_cal[i].adc_x >> 8) & 0xff; + *ts_cal_data_area++ = user_settings->touch_cal[i].adc_y & 0xff; + *ts_cal_data_area++ = (user_settings->touch_cal[i].adc_y >> 8) & 0xff; - //screen x y - *ts_cal_data_area++ = user_settings->touch_cal[i].screen_x; - *ts_cal_data_area++ = user_settings->touch_cal[i].screen_y; - } + /* screen x y */ + *ts_cal_data_area++ = user_settings->touch_cal[i].screen_x; + *ts_cal_data_area++ = user_settings->touch_cal[i].screen_y; + } - //language and flags - data[0x64] = user_settings->language; - data[0x65] = 0xfc; + /* language and flags */ + data[0x64] = user_settings->language; + data[0x65] = 0xfc; - //update count and crc - data[0x70] = count & 0xff; - data[0x71] = (count >> 8) & 0xff; + /* update count and crc */ + data[0x70] = count & 0xff; + data[0x71] = (count >> 8) & 0xff; - crc = calc_CRC16( 0xffff, data, 0x70); - data[0x72] = crc & 0xff; - data[0x73] = (crc >> 8) & 0xff; + crc = calc_CRC16( 0xffff, data, 0x70); + data[0x72] = crc & 0xff; + data[0x73] = (crc >> 8) & 0xff; - memset( &data[0x74], 0xff, 0x100 - 0x74); + memset( &data[0x74], 0xff, 0x100 - 0x74); } -// creates an firmware flash image, which contains all needed info to initiate a wifi connection +/* creates an firmware flash image, which contains all needed info to initiate a wifi connection */ int NDS_CreateDummyFirmware( struct NDS_fw_config_data *user_settings) { - //Create the firmware header - + /* + * Create the firmware header + */ memset( MMU.fw.data, 0, 0x40000); - //firmware identifier + /* firmware identifier */ MMU.fw.data[0x8] = 'M'; MMU.fw.data[0x8 + 1] = 'A'; MMU.fw.data[0x8 + 2] = 'C'; MMU.fw.data[0x8 + 3] = 'P'; - // DS type + /* DS type */ if ( user_settings->ds_type == NDS_FW_DS_TYPE_LITE) MMU.fw.data[0x1d] = 0x20; else MMU.fw.data[0x1d] = 0xff; - //User Settings offset 0x3fe00 / 8 + /* User Settings offset 0x3fe00 / 8 */ MMU.fw.data[0x20] = 0xc0; MMU.fw.data[0x21] = 0x7f; - //User settings (at 0x3FE00 and 0x3FF00) - + /* + * User settings (at 0x3FE00 and 0x3FF00) + */ fill_user_data_area( user_settings, &MMU.fw.data[ 0x3FE00], 0); fill_user_data_area( user_settings, &MMU.fw.data[ 0x3FF00], 1); - // Wifi config length + /* Wifi config length */ MMU.fw.data[0x2C] = 0x38; MMU.fw.data[0x2D] = 0x01; MMU.fw.data[0x2E] = 0x00; - //Wifi version + /* Wifi version */ MMU.fw.data[0x2F] = 0x00; - //MAC address + /* MAC address */ memcpy((MMU.fw.data + 0x36), FW_Mac, sizeof(FW_Mac)); - //Enabled channels + /* Enabled channels */ MMU.fw.data[0x3C] = 0xFE; MMU.fw.data[0x3D] = 0x3F; MMU.fw.data[0x3E] = 0xFF; MMU.fw.data[0x3F] = 0xFF; - //RF related + /* RF related */ MMU.fw.data[0x40] = 0x02; MMU.fw.data[0x41] = 0x18; MMU.fw.data[0x42] = 0x0C; MMU.fw.data[0x43] = 0x01; - //Wifi I/O init values + /* Wifi I/O init values */ memcpy((MMU.fw.data + 0x44), FW_WIFIInit, sizeof(FW_WIFIInit)); - //Wifi BB init values + /* Wifi BB init values */ memcpy((MMU.fw.data + 0x64), FW_BBInit, sizeof(FW_BBInit)); - //Wifi RF init values + /* Wifi RF init values */ memcpy((MMU.fw.data + 0xCE), FW_RFInit, sizeof(FW_RFInit)); - //Wifi channel-related init values + /* Wifi channel-related init values */ memcpy((MMU.fw.data + 0xF2), FW_RFChannel, sizeof(FW_RFChannel)); memcpy((MMU.fw.data + 0x146), FW_BBChannel, sizeof(FW_BBChannel)); memset((MMU.fw.data + 0x154), 0x10, 0xE); - //WFC profiles + /* WFC profiles */ memcpy((MMU.fw.data + 0x3FA40), &FW_WFCProfile1, sizeof(FW_WFCProfile)); memcpy((MMU.fw.data + 0x3FB40), &FW_WFCProfile2, sizeof(FW_WFCProfile)); memcpy((MMU.fw.data + 0x3FC40), &FW_WFCProfile3, sizeof(FW_WFCProfile)); @@ -1395,13 +1550,14 @@ int NDS_CreateDummyFirmware( struct NDS_fw_config_data *user_settings) MMU.fw.data[0x162] = 0x19; memset((MMU.fw.data + 0x163), 0xFF, 0x9D); - //Wifi settings CRC16 + /* Wifi settings CRC16 */ (*(u16*)(MMU.fw.data + 0x2A)) = calc_CRC16(0, (MMU.fw.data + 0x2C), 0x138); return TRUE ; } -void NDS_FillDefaultFirmwareConfigData( struct NDS_fw_config_data *fw_config) { +void +NDS_FillDefaultFirmwareConfigData( struct NDS_fw_config_data *fw_config) { const char *default_nickname = "yopyop"; const char *default_message = "DeSmuME makes you happy!"; int i; @@ -1490,728 +1646,845 @@ void NDS_SkipNextFrame() { SkipNext2DFrame = true; SkipCur3DFrame = true; } #define INDEX(i) ((((i)>>16)&0xFF0)|(((i)>>4)&0xF)) -static void execHardware_doDma(int procnum, int chan, EDMAMode modeNum) -{ - if(MMU.DMAStartTime[procnum][chan] == modeNum) - { - if(procnum == ARMCPU_ARM9) MMU_doDMA(chan); - else MMU_doDMA(chan); - //MMU.DMAStartTime[procnum][chan] = 0; //this was here for main mem dma - } -} - -static void execHardware_doAllDma(EDMAMode modeNum) -{ - for(int i=0;i<2;i++) - for(int j=0;j<4;j++) - execHardware_doDma(i,j,modeNum); -} - -enum ESI_DISPCNT -{ - ESI_DISPCNT_HStart, ESI_DISPCNT_HBlank -}; - -u64 nds_timer; -u64 nds_arm9_timer, nds_arm7_timer; - -static const u64 kNever = 0xFFFFFFFFFFFFFFFFULL; - -struct TSequenceItem -{ - u64 timestamp; - u32 param; - bool enabled; - - virtual void save(std::ostream* os) - { - write64le(timestamp,os); - write32le(param,os); - writebool(enabled,os); - } - - virtual bool load(std::istream* is) - { - if(read64le(×tamp,is) != 1) return false; - if(read32le(¶m,is) != 1) return false; - if(readbool(&enabled,is) != 1) return false; - return true; - } - - FORCEINLINE bool isTriggered() - { - return enabled && nds_timer >= timestamp; - } - - FORCEINLINE u64 next() - { - if(enabled) return timestamp; - else return kNever; - } -}; - -struct TSequenceItem_GXFIFO : public TSequenceItem -{ - FORCEINLINE bool isTriggered() - { - #ifndef USE_GEOMETRY_FIFO_EMULATION - return false; - #else - return enabled && nds_timer >= MMU.gfx3dCycles; - #endif - } - - FORCEINLINE void exec() - { - #ifdef USE_GEOMETRY_FIFO_EMULATION - enabled = false; //do this first, because gfx3d_execute3D() will cause more scheduled events if necessary - gfx3d_execute3D(); - MMU.gfx3dCycles = max(MMU.gfx3dCycles,nds_timer); //uhh i dont entirely understand why this was necessary - //i need to learn more about how the new gxfifo works, but I am leaving that to you for now crazymax ^_^ - #endif - } - - FORCEINLINE u64 next() - { - if(enabled) return MMU.gfx3dCycles; - else return kNever; - } -}; - -template struct TSequenceItem_Timer : public TSequenceItem -{ - FORCEINLINE bool isTriggered() - { - return enabled && nds_timer >= nds.timerCycle[procnum][num]; - } - - FORCEINLINE void schedule() - { - enabled = MMU.timerON[procnum][num] && MMU.timerMODE[procnum][num] != 0xFFFF; - } - - FORCEINLINE u64 next() - { - //todo - change this to go through an entire overflow cycle instead of a single increment - //however, in order to do this, we need to change the counter read emulation to calculate its value - //instead of just plucking the uptodate value (which would no longer be kept uptodate) - return nds.timerCycle[procnum][num]; - } - - FORCEINLINE void exec() - { - u64 timer = nds_timer; - u8* regs = procnum==0?ARM9Mem.ARM9_REG:MMU.ARM7_REG; - bool first = true, over; - //we'll need to check chained timers.. - for(int i=num;i<4;i++) - { - //maybe too many checks if this is here, but we need it here for now - if(!MMU.timerON[procnum][i]) return; - - if(MMU.timerMODE[procnum][i] == 0xFFFF) - { - ++(MMU.timer[procnum][i]); - over = !MMU.timer[procnum][i]; - } - else - { - if(!first) break; //this timer isn't chained. break the chain - first = false; - - over = true; - int remain = 65536 - MMU.timerReload[procnum][i]; - int ctr=0; - while(nds.timerCycle[procnum][i] <= nds_timer) { - nds.timerCycle[procnum][i] += (remain << MMU.timerMODE[procnum][i]); - ctr++; - } - if(ctr>1) { - printf("yikes!!!!! please report!\n"); - } - } - - if(over) - { - MMU.timer[procnum][i] = MMU.timerReload[procnum][i]; - if(T1ReadWord(regs, 0x102 + i*4) & 0x40) - { - if(procnum==0) NDS_makeARM9Int(3 + i); - else NDS_makeARM7Int(3 + i); - } - } - else - break; //no more chained timers to trigger. we're done here - } - } -}; - -template struct TSequenceItem_DMA : public TSequenceItem -{ - FORCEINLINE bool isTriggered() - { - return (MMU.DMAing[procnum][chan])&&nds_timer>=(MMU.DMACycle[procnum][chan]); - } - - FORCEINLINE u64 next() - { - if(!MMU.DMAing[procnum][chan]) return kNever; - return MMU.DMACycle[procnum][chan]; - } - - FORCEINLINE void exec() - { - u8* regs = procnum==0?ARM9Mem.ARM9_REG:MMU.ARM7_REG; - T1WriteLong(regs, 0xB8 + (0xC*chan), T1ReadLong(regs, 0xB8 + (0xC*chan)) & 0x7FFFFFFF); - if((MMU.DMACrt[procnum][chan])&(1<<30)) { - if(procnum==0) NDS_makeARM9Int(8+chan); - else NDS_makeARM7Int(8+chan); - } - MMU.DMAing[procnum][chan] = FALSE; - } -}; - -struct TSequenceItem_divider : public TSequenceItem -{ - FORCEINLINE bool isTriggered() - { - return MMU.divRunning && nds_timer >= MMU.divCycles; - } - - FORCEINLINE u64 next() - { - if(!MMU.divRunning) return kNever; - return MMU.divCycles; - } - - void exec() - { - T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x2A0, (u32)MMU.divResult); - T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x2A4, (u32)(MMU.divResult >> 32)); - T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x2A8, (u32)MMU.divMod); - T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x2AC, (u32)(MMU.divMod >> 32)); - T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x280, MMU.divCnt); - MMU.divRunning = FALSE; - } - -}; - -struct TSequenceItem_sqrtunit : public TSequenceItem -{ - FORCEINLINE bool isTriggered() - { - return MMU.sqrtRunning && nds_timer >= MMU.sqrtCycles; - } - - FORCEINLINE u64 next() - { - if(!MMU.sqrtRunning) return kNever; - return MMU.sqrtCycles; - } - - FORCEINLINE void exec() - { - T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x2B4, MMU.sqrtResult); - T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x2B0, MMU.sqrtCnt); - MMU.sqrtRunning = FALSE; - } - -}; - -struct Sequencer -{ - bool nds_vblankEnded; - bool reschedule; - TSequenceItem dispcnt; - TSequenceItem wifi; - TSequenceItem_divider divider; - TSequenceItem_sqrtunit sqrtunit; - TSequenceItem_GXFIFO gxfifo; - TSequenceItem_DMA<0,0> dma_0_0; TSequenceItem_DMA<0,1> dma_0_1; - TSequenceItem_DMA<0,2> dma_0_2; TSequenceItem_DMA<0,3> dma_0_3; - TSequenceItem_DMA<1,0> dma_1_0; TSequenceItem_DMA<1,1> dma_1_1; - TSequenceItem_DMA<1,2> dma_1_2; TSequenceItem_DMA<1,3> dma_1_3; - TSequenceItem_Timer<0,0> timer_0_0; TSequenceItem_Timer<0,1> timer_0_1; - TSequenceItem_Timer<0,2> timer_0_2; TSequenceItem_Timer<0,3> timer_0_3; - TSequenceItem_Timer<1,0> timer_1_0; TSequenceItem_Timer<1,1> timer_1_1; - TSequenceItem_Timer<1,2> timer_1_2; TSequenceItem_Timer<1,3> timer_1_3; - - void init(); - - void execHardware(); - u64 findNext(); - - void save(std::ostream* os) - { - write64le(nds_timer,os); - write64le(nds_arm9_timer,os); - write64le(nds_arm7_timer,os); - dispcnt.save(os); - divider.save(os); - sqrtunit.save(os); - gxfifo.save(os); -#define SAVE(I,X,Y) I##_##X##_##Y .save(os); - SAVE(timer,0,0); SAVE(timer,0,1); SAVE(timer,0,2); SAVE(timer,0,3); - SAVE(timer,1,0); SAVE(timer,1,1); SAVE(timer,1,2); SAVE(timer,1,3); - SAVE(dma,0,0); SAVE(dma,0,1); SAVE(dma,0,2); SAVE(dma,0,3); - SAVE(dma,1,0); SAVE(dma,1,1); SAVE(dma,1,2); SAVE(dma,1,3); -#undef SAVE - } - - bool load(std::istream* is) - { - if(read64le(&nds_timer,is) != 1) return false; - if(read64le(&nds_arm9_timer,is) != 1) return false; - if(read64le(&nds_arm7_timer,is) != 1) return false; - if(!dispcnt.load(is)) return false; - if(!divider.load(is)) return false; - if(!sqrtunit.load(is)) return false; - if(!gxfifo.load(is)) return false; -#define LOAD(I,X,Y) if(!I##_##X##_##Y .load(is)) return false; - LOAD(timer,0,0); LOAD(timer,0,1); LOAD(timer,0,2); LOAD(timer,0,3); - LOAD(timer,1,0); LOAD(timer,1,1); LOAD(timer,1,2); LOAD(timer,1,3); - LOAD(dma,0,0); LOAD(dma,0,1); LOAD(dma,0,2); LOAD(dma,0,3); - LOAD(dma,1,0); LOAD(dma,1,1); LOAD(dma,1,2); LOAD(dma,1,3); -#undef LOAD - - return true; - } - -} sequencer; - -void NDS_RescheduleGXFIFO() -{ -#ifdef USE_GEOMETRY_FIFO_EMULATION - sequencer.gxfifo.enabled = true; - NDS_Reschedule(); -#endif -} - -void NDS_RescheduleTimers() -{ -#define check(X,Y) sequencer.timer_##X##_##Y .schedule(); - check(0,0); check(0,1); check(0,2); check(0,3); - check(1,0); check(1,1); check(1,2); check(1,3); -#undef check - - NDS_Reschedule(); -} - -void NDS_RescheduleDMA() -{ - //TBD - NDS_Reschedule(); -} - -static void initSchedule() -{ - sequencer.init(); - - //begin at the very end of the last scanline - //so that at t=0 we can increment to scanline=0 - nds.VCount = 262; - - sequencer.nds_vblankEnded = false; -} - - -// 2196372 ~= (ARM7_CLOCK << 16) / 1000000 -// This value makes more sense to me, because: -// ARM7_CLOCK = 33.51 mhz -// = 33513982 cycles per second -// = 33.513982 cycles per microsecond -const u64 kWifiCycles = 34*2; -//(this isn't very precise. I don't think it needs to be) - -void Sequencer::init() -{ - NDS_RescheduleTimers(); - NDS_RescheduleDMA(); - - reschedule = false; - nds_timer = 0; - nds_arm9_timer = 0; - nds_arm7_timer = 0; - - dispcnt.enabled = true; - dispcnt.param = ESI_DISPCNT_HStart; - dispcnt.timestamp = 0; - - gxfifo.enabled = false; - - - #ifdef EXPERIMENTAL_WIFI - wifi.enabled = true; - wifi.timestamp = kWifiCycles; - #else - wifi.enabled = false; - #endif -} - - -static void execHardware_hblank() -{ - //turn on hblank status bit - T1WriteWord(ARM9Mem.ARM9_REG, 4, T1ReadWord(ARM9Mem.ARM9_REG, 4) | 2); - T1WriteWord(MMU.ARM7_REG, 4, T1ReadWord(MMU.ARM7_REG, 4) | 2); - - //fire hblank interrupts if necessary - NDS_ARM9HBlankInt(); - NDS_ARM7HBlankInt(); - - //emulation housekeeping. for some reason we always do this at hblank, - //even though it sounds more reasonable to do it at hstart - SPU_Emulate_core(); - driver->AVI_SoundUpdate(SPU_core->outbuf,spu_core_samples); - WAV_WavSoundUpdate(SPU_core->outbuf,spu_core_samples); - - //this logic was formerly at hblank time. it was moved to the beginning of the scanline on a whim - if(nds.VCount<192) - { - //so, we have chosen to do the line drawing at hblank time. - //this is the traditional time for it in desmume. - //while it may seem more ruthlessly accurate to do it at hstart, - //in practice we need to be more forgiving, in case things have overrun the scanline start. - //this should be safe since games cannot do anything timing dependent until this next - //scanline begins, anyway (as this scanline was in the middle of drawing) - GPU_ligne(&MainScreen, nds.VCount, SkipCur2DFrame); - GPU_ligne(&SubScreen, nds.VCount, SkipCur2DFrame); - - //trigger hblank dmas - //but notice, we do that just after we finished drawing the line - //(values copied by this hdma should not be used until the next scanline) - execHardware_doAllDma(EDMAMode_HBlank); - } -} - -static void execHardware_hstart_vblankEnd() -{ - nds.VCount = 0; - sequencer.nds_vblankEnded = true; - sequencer.reschedule = true; - - //turn off vblank status bit - T1WriteWord(ARM9Mem.ARM9_REG, 4, T1ReadWord(ARM9Mem.ARM9_REG, 4) & 0xFFFE); - T1WriteWord(MMU.ARM7_REG, 4, T1ReadWord(MMU.ARM7_REG, 4) & 0xFFFE); -} - -static void execHardware_hstart_vblankStart() -{ - //turn on vblank status bit - T1WriteWord(ARM9Mem.ARM9_REG, 4, T1ReadWord(ARM9Mem.ARM9_REG, 4) | 1); - T1WriteWord(MMU.ARM7_REG, 4, T1ReadWord(MMU.ARM7_REG, 4) | 1); - - //fire vblank interrupts if necessary - NDS_ARM9VBlankInt(); - NDS_ARM7VBlankInt(); - - //some emulation housekeeping - gfx3d_VBlankSignal(); - if(SkipNext2DFrame) - { - SkipCur2DFrame = true; - SkipNext2DFrame = false; - } - else - SkipCur2DFrame = false; - - //trigger vblank dmas - execHardware_doAllDma(EDMAMode_VBlank); -} - -void execHardware_hstart_vcount() -{ - u16 vmatch = T1ReadWord(ARM9Mem.ARM9_REG, 4); - if(nds.VCount==((vmatch>>8)|((vmatch<<1)&(1<<8)))) - { - T1WriteWord(ARM9Mem.ARM9_REG, 4, T1ReadWord(ARM9Mem.ARM9_REG, 4) | 4); - if(T1ReadWord(ARM9Mem.ARM9_REG, 4) & 32) - NDS_makeARM9Int(2); - } - else - T1WriteWord(ARM9Mem.ARM9_REG, 4, T1ReadWord(ARM9Mem.ARM9_REG, 4) & 0xFFFB); - - vmatch = T1ReadWord(MMU.ARM7_REG, 4); - if(nds.VCount==((vmatch>>8)|((vmatch<<1)&(1<<8)))) - { - T1WriteWord(MMU.ARM7_REG, 4, T1ReadWord(MMU.ARM7_REG, 4) | 4); - if(T1ReadWord(MMU.ARM7_REG, 4) & 32) - NDS_makeARM7Int(2); - } - else - T1WriteWord(MMU.ARM7_REG, 4, T1ReadWord(MMU.ARM7_REG, 4) & 0xFFFB); -} - -static void execHardware_hstart() -{ - nds.VCount++; - - if(nds.VCount==263) - { - execHardware_hstart_vblankEnd(); - } else if(nds.VCount==192) - { - execHardware_hstart_vblankStart(); - } - - //write the new vcount - T1WriteWord(ARM9Mem.ARM9_REG, 6, nds.VCount); - T1WriteWord(ARM9Mem.ARM9_REG, 0x1006, nds.VCount); - T1WriteWord(MMU.ARM7_REG, 6, nds.VCount); - T1WriteWord(MMU.ARM7_REG, 0x1006, nds.VCount); - - //turn off hblank status bit - T1WriteWord(ARM9Mem.ARM9_REG, 4, T1ReadWord(ARM9Mem.ARM9_REG, 4) & 0xFFFD); - T1WriteWord(MMU.ARM7_REG, 4, T1ReadWord(MMU.ARM7_REG, 4) & 0xFFFD); - - //handle vcount status - execHardware_hstart_vcount(); - - //trigger hstart dmas - execHardware_doAllDma(EDMAMode_HStart); - - if(nds.VCount<192) - { - //this is hacky. - //there is a corresponding hack in doDMA - execHardware_doAllDma(EDMAMode_MemDisplay); - } - - //end of 3d vblank - if(nds.VCount==214) - { - gfx3d_VBlankEndSignal(SkipCur3DFrame); - SkipCur3DFrame = false; - } -} - -void NDS_Reschedule() -{ - sequencer.reschedule = true; -} - -u64 Sequencer::findNext() -{ - u64 next = kNever; - next = min(next,dispcnt.next()); - next = min(next,divider.next()); - next = min(next,sqrtunit.next()); - next = min(next,gxfifo.next()); - -#ifdef EXPERIMENTAL_WIFI - next = min(next,wifi.next()); -#endif - -#define test(X,Y) next = min(next,dma_##X##_##Y .next()); - test(0,0); test(0,1); test(0,2); test(0,3); - test(1,0); test(1,1); test(1,2); test(1,3); -#undef test -#define test(X,Y) if(timer_##X##_##Y .enabled) next = min(next,timer_##X##_##Y .next()); - test(0,0); test(0,1); test(0,2); test(0,3); - test(1,0); test(1,1); test(1,2); test(1,3); -#undef test - - return next; -} - -void Sequencer::execHardware() -{ - if(dispcnt.isTriggered()) - { - switch(dispcnt.param) - { - case ESI_DISPCNT_HStart: - execHardware_hstart(); - dispcnt.timestamp += 3168; - dispcnt.param = ESI_DISPCNT_HBlank; - break; - case ESI_DISPCNT_HBlank: - execHardware_hblank(); - dispcnt.timestamp += 1092; - dispcnt.param = ESI_DISPCNT_HStart; - break; - } - } - -#ifdef EXPERIMENTAL_WIFI - if(wifi.isTriggered()) - { - WIFI_usTrigger(&wifiMac); - WIFI_SoftAP_usTrigger(&wifiMac); - wifi.timestamp += kWifiCycles; - } -#endif - - if(divider.isTriggered()) divider.exec(); - if(sqrtunit.isTriggered()) sqrtunit.exec(); - if(gxfifo.isTriggered()) gxfifo.exec(); - - -#define test(X,Y) if(dma_##X##_##Y .isTriggered()) dma_##X##_##Y .exec(); - test(0,0); test(0,1); test(0,2); test(0,3); - test(1,0); test(1,1); test(1,2); test(1,3); -#undef test -#define test(X,Y) if(timer_##X##_##Y .enabled) if(timer_##X##_##Y .isTriggered()) timer_##X##_##Y .exec(); - test(0,0); test(0,1); test(0,2); test(0,3); - test(1,0); test(1,1); test(1,2); test(1,3); -#undef test -} - -void execHardware_interrupts(); - -void nds_savestate(std::ostream* os) -{ - //version - write32le(0,os); - - sequencer.save(os); -} - -bool nds_loadstate(std::istream* is, int size) -{ - //read version - int version; - if(read32le(&version,is) != 1) return false; - - if(version != 0) return false; - - return sequencer.load(is); -} - -//#define LOG_ARM9 -//#define LOG_ARM7 -//static bool dolog = false; - -FORCEINLINE void arm9log() -{ -#ifdef LOG_ARM9 - if(dolog) - { - char dasmbuf[4096]; - if(NDS_ARM9.CPSR.bits.T) - des_thumb_instructions_set[((NDS_ARM9.instruction)>>6)&1023](NDS_ARM9.instruct_adr, NDS_ARM9.instruction, dasmbuf); - else - des_arm_instructions_set[INDEX(NDS_ARM9.instruction)](NDS_ARM9.instruct_adr, NDS_ARM9.instruction, dasmbuf); - - printf("%05d %12lld 9:%08X %08X %-30s R00:%08X R01:%08X R02:%08X R03:%08X R04:%08X R05:%08X R06:%08X R07:%08X R08:%08X R09:%08X R10:%08X R11:%08X R12:%08X R13:%08X R14:%08X R15:%08X\n", - currFrameCounter, nds_timer, - NDS_ARM9.instruct_adr,NDS_ARM9.instruction, dasmbuf, - NDS_ARM9.R[0], NDS_ARM9.R[1], NDS_ARM9.R[2], NDS_ARM9.R[3], NDS_ARM9.R[4], NDS_ARM9.R[5], NDS_ARM9.R[6], NDS_ARM9.R[7], - NDS_ARM9.R[8], NDS_ARM9.R[9], NDS_ARM9.R[10], NDS_ARM9.R[11], NDS_ARM9.R[12], NDS_ARM9.R[13], NDS_ARM9.R[14], NDS_ARM9.R[15]); - } -#endif -} - -FORCEINLINE void arm7log() -{ - #ifdef LOG_ARM7 - if(dolog) - { - char dasmbuf[4096]; - if(NDS_ARM7.CPSR.bits.T) - des_thumb_instructions_set[((NDS_ARM7.instruction)>>6)&1023](NDS_ARM7.instruct_adr, NDS_ARM7.instruction, dasmbuf); - else - des_arm_instructions_set[INDEX(NDS_ARM7.instruction)](NDS_ARM7.instruct_adr, NDS_ARM7.instruction, dasmbuf); - - printf("%05d %12lld 7:%08X %08X %-30s R00:%08X R01:%08X R02:%08X R03:%08X R04:%08X R05:%08X R06:%08X R07:%08X R08:%08X R09:%08X R10:%08X R11:%08X R12:%08X R13:%08X R14:%08X R15:%08X\n", - currFrameCounter, nds_timer, - NDS_ARM7.instruct_adr,NDS_ARM7.instruction, dasmbuf, - NDS_ARM7.R[0], NDS_ARM7.R[1], NDS_ARM7.R[2], NDS_ARM7.R[3], NDS_ARM7.R[4], NDS_ARM7.R[5], NDS_ARM7.R[6], NDS_ARM7.R[7], - NDS_ARM7.R[8], NDS_ARM7.R[9], NDS_ARM7.R[10], NDS_ARM7.R[11], NDS_ARM7.R[12], NDS_ARM7.R[13], NDS_ARM7.R[14], NDS_ARM7.R[15]); - } - #endif -} template -void NDS_exec(s32 nb) +u32 NDS_exec(s32 nb) { - //TODO - singlestep is broken + int i, j; + + nb = 560190<<1; LagFrameFlag=1; - if((currFrameCounter&63) == 0) - MMU_new.backupDevice.lazy_flush(); + //increase this to execute more instructions in each batch (reducing overhead) + //the value of 4 seems to optimize speed.. do lower values increase precision? + const int INSTRUCTIONS_PER_BATCH = 4; - sequencer.nds_vblankEnded = false; + //decreasing this should increase precision at the cost of speed + //the traditional value was somewhere between 100 and 400 depending on circumstances + const int CYCLES_TO_WAIT_FOR_IRQ = 400; - //these have not been tuned very well yet. - const int kMaxWork = 4000; - const int kIrqWait = 4000; - - if(nds.sleeping) + for(; (nb >= nds.cycles) && ((FORCE)||(execute)); ) { - gpu_UpdateRender(); - if((MMU.reg_IE[1] & MMU.reg_IF[1]) & (1<<22)) + for (j = 0; j < INSTRUCTIONS_PER_BATCH && (!FORCE) && (execute); j++) { - nds.sleeping = FALSE; - } - } - else - { - for(;;) - { - sequencer.execHardware(); - - //break out once per frame - if(sequencer.nds_vblankEnded) break; - //it should be benign to execute execHardware in the next frame, - //since there won't be anything for it to do (everything should be scheduled in the future) - - execHardware_interrupts(); - - //find next work unit: - u64 next = sequencer.findNext(); - next = min(next,nds_timer+kMaxWork); //lets set an upper limit for now - - //printf("%d\n",(next-nds_timer)); - - sequencer.reschedule = false; - - u64 nds_timer_base = nds_timer; - s32 arm9 = (s32)(nds_arm9_timer-nds_timer); - s32 arm7 = (s32)(nds_arm7_timer-nds_timer); - s32 timer = 0; - s32 s32next = (s32)(next-nds_timer); - while(timer(); - } - +#ifdef LOG_ARM9 + if(logcount==3){ + if(NDS_ARM9.CPSR.bits.T) + des_thumb_instructions_set[(NDS_ARM9.instruction)>>6](NDS_ARM9.instruct_adr, NDS_ARM9.instruction, logbuf); + else + des_arm_instructions_set[INDEX(NDS_ARM9.instruction)](NDS_ARM9.instruct_adr, NDS_ARM9.instruction, logbuf); + sprintf(logbuf + strlen(logbuf), "%s\t%08X\n\t R00: %08X, R01: %08X, R02: %08X, R03: %08X, R04: %08X, R05: %08X, R06: %08X, R07: %08X,\n\t R08: %08X, R09: %08X, R10: %08X, R11: %08X, R12: %08X, R13: %08X, R14: %08X, R15: %08X,\n\t CPSR: %08X , SPSR: %08X", + NDS_ARM9.instruction, NDS_ARM9.R[0], NDS_ARM9.R[1], NDS_ARM9.R[2], NDS_ARM9.R[3], NDS_ARM9.R[4], NDS_ARM9.R[5], NDS_ARM9.R[6], NDS_ARM9.R[7], + NDS_ARM9.R[8], NDS_ARM9.R[9], NDS_ARM9.R[10], NDS_ARM9.R[11], NDS_ARM9.R[12], NDS_ARM9.R[13], NDS_ARM9.R[14], NDS_ARM9.R[15], + NDS_ARM9.CPSR, NDS_ARM9.SPSR); + LOG(logbuf); } - if(arm7<=timer) +#endif + for (i = 0; i < INSTRUCTIONS_PER_BATCH && (!FORCE) && (execute); i++) { - if(NDS_ARM7.waitIRQ) - arm7 = min(s32next,arm7 + kIrqWait); - else { - arm7log(); - arm7 += (armcpu_exec()<<1); - } + if(nds.sleeping) { + break; + } else + if(NDS_ARM9.waitIRQ) { + nds.ARM9Cycle += CYCLES_TO_WAIT_FOR_IRQ; + nds.idleCycles += CYCLES_TO_WAIT_FOR_IRQ; + break; //it is rather pointless to do this more than once + } else + nds.ARM9Cycle += armcpu_exec(); } - - timer = min(arm7,arm9); - nds_timer = nds_timer_base+timer; +#ifdef _WIN32 +#ifdef DEVELOPER + DisassemblerTools_Refresh(); +#endif +#endif } - nds_arm7_timer = nds_timer_base+arm7; - nds_arm9_timer = nds_timer_base+arm9; +#ifdef EXPERIMENTAL_WIFI +#if 0 - //what we find here is dependent on the timing constants above - if(nds_timer>next && (nds_timer-next)>22) - printf("curious. please report: over by %d\n",(int)(nds_timer-next)); + if((nds.ARM7Cycle % 0x3F03) == 0) + { + /* 3F03 arm7 cycles = ~1usec */ + WIFI_usTrigger(&wifiMac) ; + } +#endif - //if we were waiting for an irq, don't wait too long: - //let's re-analyze it after this hardware event - if(NDS_ARM9.waitIRQ) nds_arm9_timer = nds_timer; - if(NDS_ARM7.waitIRQ) nds_arm7_timer = nds_timer; + int nds7old = nds.ARM7Cycle; +#endif + + if(nds.ARM7Cycle<=nds.cycles) + { +#ifdef LOG_ARM7 + if(logcount==1){ + if(NDS_ARM7.CPSR.bits.T) + des_thumb_instructions_set[(NDS_ARM7.instruction)>>6](NDS_ARM7.instruct_adr, NDS_ARM7.instruction, logbuf); + else + des_arm_instructions_set[INDEX(NDS_ARM7.instruction)](NDS_ARM7.instruct_adr, NDS_ARM7.instruction, logbuf); + sprintf(logbuf + strlen(logbuf), "%s\n\t R00: %08X, R01: %08X, R02: %08X, R03: %08X, R04: %08X, R05: %08X, R06: %08X, R07: %08X,\n\t R08: %08X, R09: %08X, R10: %08X, R11: %08X, R12: %08X, R13: %08X, R14: %08X, R15: %08X,\n\t CPSR: %08X , SPSR: %08X", + NDS_ARM7.R[0], NDS_ARM7.R[1], NDS_ARM7.R[2], NDS_ARM7.R[3], NDS_ARM7.R[4], NDS_ARM7.R[5], NDS_ARM7.R[6], NDS_ARM7.R[7], + NDS_ARM7.R[8], NDS_ARM7.R[9], NDS_ARM7.R[10], NDS_ARM7.R[11], NDS_ARM7.R[12], NDS_ARM7.R[13], NDS_ARM7.R[14], NDS_ARM7.R[15], + NDS_ARM7.CPSR, NDS_ARM7.SPSR); + LOG(logbuf); + } +#endif + for (i = 0; i < INSTRUCTIONS_PER_BATCH && (!FORCE) && (execute); i++) + { + if(nds.sleeping) { + break; + } else + if(NDS_ARM7.waitIRQ) + { + nds.ARM7Cycle += CYCLES_TO_WAIT_FOR_IRQ; + break; //it is rather pointless to do this more than once + } + else + nds.ARM7Cycle += (armcpu_exec()<<1); + } +#ifdef _WIN32 +#ifdef DEVELOPER + DisassemblerTools_Refresh(); +#endif +#endif + } + +//this doesnt work anyway. why take a speed hit for public releases? +#ifndef PUBLIC_RELEASE +#ifdef EXPERIMENTAL_WIFI + /* FIXME: the wifi stuff isn't actually clocked by the ARM7 clock, */ + /* but by a 22 mhz oscillator. */ + if(nds7old < nds.ARM7Cycle) + { + nds7old %= 67; + int nds7new = (nds.ARM7Cycle % 67); + + if(nds7old > nds7new) + { + WIFI_usTrigger(&wifiMac); + WIFI_SoftAP_usTrigger(&wifiMac); + } + } +#endif +#endif + } // for (j = 0; j < INSTRUCTIONS_PER_BATCH && (!FORCE) && (execute); j++) + + if(!nds.sleeping) + { + + // for(i = 0; i < INSTRUCTIONS_PER_BATCH && (!FORCE) && (execute); i++) + // { + + nds.cycles = std::min(nds.ARM9Cycle,nds.ARM7Cycle); + + //debug(); + + if(nds.cycles>=nds.nextHBlank) + { + if(!nds.lignerendu) + { + T1WriteWord(ARM9Mem.ARM9_REG, 4, T1ReadWord(ARM9Mem.ARM9_REG, 4) | 2); + T1WriteWord(MMU.ARM7_REG, 4, T1ReadWord(MMU.ARM7_REG, 4) | 2); + NDS_ARM9HBlankInt(); + NDS_ARM7HBlankInt(); +#if defined(WIN32) && defined(G_NEW_SPU_TIMING) + SPU_Emulate_core(); + + //avi writing + DRV_AviSoundUpdate(SPU_core->outbuf,spu_core_samples); + //wav writing + DRV_WavSoundUpdate(SPU_core->outbuf,spu_core_samples); +#endif + if(nds.VCount<192) + { + if(!SkipCur2DFrame) + { + GPU_ligne(&MainScreen, nds.VCount); + GPU_ligne(&SubScreen, nds.VCount); + } + + if(MMU.DMAStartTime[0][0] == 2) + MMU_doDMA(0); + if(MMU.DMAStartTime[0][1] == 2) + MMU_doDMA(1); + if(MMU.DMAStartTime[0][2] == 2) + MMU_doDMA(2); + if(MMU.DMAStartTime[0][3] == 2) + MMU_doDMA(3); + } + nds.lignerendu = TRUE; + } + if(nds.cycles>=nds.nextHBlank+1092) + { + u32 vmatch; + + ++nds.VCount; + nds.nextHBlank += 4260; + T1WriteWord(ARM9Mem.ARM9_REG, 4, T1ReadWord(ARM9Mem.ARM9_REG, 4) & 0xFFFD); + T1WriteWord(MMU.ARM7_REG, 4, T1ReadWord(MMU.ARM7_REG, 4) & 0xFFFD); + + if(MMU.DMAStartTime[0][0] == 3) + MMU_doDMA(0); + if(MMU.DMAStartTime[0][1] == 3) + MMU_doDMA(1); + if(MMU.DMAStartTime[0][2] == 3) + MMU_doDMA(2); + if(MMU.DMAStartTime[0][3] == 3) + MMU_doDMA(3); + + // Main memory display + if(MMU.DMAStartTime[0][0] == 4) + { + MMU_doDMA(0); + MMU.DMAStartTime[0][0] = 0; + } + if(MMU.DMAStartTime[0][1] == 4) + { + MMU_doDMA(1); + MMU.DMAStartTime[0][1] = 0; + } + if(MMU.DMAStartTime[0][2] == 4) + { + MMU_doDMA(2); + MMU.DMAStartTime[0][2] = 0; + } + if(MMU.DMAStartTime[0][3] == 4) + { + MMU_doDMA(3); + MMU.DMAStartTime[0][3] = 0; + } + + if(MMU.DMAStartTime[1][0] == 4) + { + MMU_doDMA(0); + MMU.DMAStartTime[1][0] = 0; + } + if(MMU.DMAStartTime[1][1] == 4) + { + MMU_doDMA(1); + MMU.DMAStartTime[0][1] = 0; + } + if(MMU.DMAStartTime[1][2] == 4) + { + MMU_doDMA(2); + MMU.DMAStartTime[1][2] = 0; + } + if(MMU.DMAStartTime[1][3] == 4) + { + MMU_doDMA(3); + MMU.DMAStartTime[1][3] = 0; + } + + nds.lignerendu = FALSE; + if(nds.VCount==192) + { + //osdA->update(); + gfx3d_VBlankSignal(); + + if(SkipNext2DFrame) + { + SkipCur2DFrame = true; + SkipNext2DFrame = false; + } + else + SkipCur2DFrame = false; + + T1WriteWord(ARM9Mem.ARM9_REG, 4, T1ReadWord(ARM9Mem.ARM9_REG, 4) | 1); + T1WriteWord(MMU.ARM7_REG, 4, T1ReadWord(MMU.ARM7_REG, 4) | 1); + NDS_ARM9VBlankInt(); + NDS_ARM7VBlankInt(); + + nds.runCycleCollector[nds.idleFrameCounter] = 1120380-nds.idleCycles; + nds.idleFrameCounter++; + nds.idleFrameCounter &= 15; + nds.idleCycles = 0; + + + if(MMU.DMAStartTime[0][0] == 1) + MMU_doDMA(0); + if(MMU.DMAStartTime[0][1] == 1) + MMU_doDMA(1); + if(MMU.DMAStartTime[0][2] == 1) + MMU_doDMA(2); + if(MMU.DMAStartTime[0][3] == 1) + MMU_doDMA(3); + + if(MMU.DMAStartTime[1][0] == 1) + MMU_doDMA(0); + if(MMU.DMAStartTime[1][1] == 1) + MMU_doDMA(1); + if(MMU.DMAStartTime[1][2] == 1) + MMU_doDMA(2); + if(MMU.DMAStartTime[1][3] == 1) + MMU_doDMA(3); + } + else if(nds.VCount==214) + { + gfx3d_VBlankEndSignal(SkipCur3DFrame); + SkipCur3DFrame = false; + } + else if(nds.VCount==263) + { + //osd->update(); + //osdB->update(); + gpu_UpdateRender(); + + nds.nextHBlank = 3168; + nds.VCount = 0; + T1WriteWord(ARM9Mem.ARM9_REG, 4, T1ReadWord(ARM9Mem.ARM9_REG, 4) & 0xFFFE); + T1WriteWord(MMU.ARM7_REG, 4, T1ReadWord(MMU.ARM7_REG, 4) & 0xFFFE); + + nds.cycles -= (560190<<1); + nds.ARM9Cycle -= (560190<<1); + nds.ARM7Cycle -= (560190<<1); + nb -= (560190<<1); + +#ifdef USE_GEOMETRY_FIFO_EMULATION + MMU.gfx3dCycles -= (560190 << 1); +#endif + + if(MMU.divRunning) + { + MMU.divCycles -= (560190 << 1); + } + + if(MMU.sqrtRunning) + { + MMU.sqrtCycles -= (560190 << 1); + } + + if (MMU.CheckTimers) + { + if(MMU.timerON[0][0]) nds.timerCycle[0][0] -= (560190<<1); + if(MMU.timerON[0][1]) nds.timerCycle[0][1] -= (560190<<1); + if(MMU.timerON[0][2]) nds.timerCycle[0][2] -= (560190<<1); + if(MMU.timerON[0][3]) nds.timerCycle[0][3] -= (560190<<1); + + if(MMU.timerON[1][0]) nds.timerCycle[1][0] -= (560190<<1); + if(MMU.timerON[1][1]) nds.timerCycle[1][1] -= (560190<<1); + if(MMU.timerON[1][2]) nds.timerCycle[1][2] -= (560190<<1); + if(MMU.timerON[1][3]) nds.timerCycle[1][3] -= (560190<<1); + } + + if (MMU.CheckDMAs) + { + if(MMU.DMAing[0][0]) MMU.DMACycle[0][0] -= (560190<<1); + if(MMU.DMAing[0][1]) MMU.DMACycle[0][1] -= (560190<<1); + if(MMU.DMAing[0][2]) MMU.DMACycle[0][2] -= (560190<<1); + if(MMU.DMAing[0][3]) MMU.DMACycle[0][3] -= (560190<<1); + + if(MMU.DMAing[1][0]) MMU.DMACycle[1][0] -= (560190<<1); + if(MMU.DMAing[1][1]) MMU.DMACycle[1][1] -= (560190<<1); + if(MMU.DMAing[1][2]) MMU.DMACycle[1][2] -= (560190<<1); + if(MMU.DMAing[1][3]) MMU.DMACycle[1][3] -= (560190<<1); + } + } + + T1WriteWord(ARM9Mem.ARM9_REG, 6, nds.VCount); + //T1WriteWord(ARM9Mem.ARM9_REG, 0x1006, nds.VCount); // svn r2299 + T1WriteWord(MMU.ARM7_REG, 6, nds.VCount); + //T1WriteWord(MMU.ARM7_REG, 0x1006, nds.VCount); // svn r2299 + + vmatch = T1ReadWord(ARM9Mem.ARM9_REG, 4); + if(nds.VCount==((vmatch>>8)|((vmatch<<1)&(1<<8)))) + { + T1WriteWord(ARM9Mem.ARM9_REG, 4, T1ReadWord(ARM9Mem.ARM9_REG, 4) | 4); + if(T1ReadWord(ARM9Mem.ARM9_REG, 4) & 32) + NDS_makeARM9Int(2); + } + else + T1WriteWord(ARM9Mem.ARM9_REG, 4, T1ReadWord(ARM9Mem.ARM9_REG, 4) & 0xFFFB); + + vmatch = T1ReadWord(MMU.ARM7_REG, 4); + if(nds.VCount==((vmatch>>8)|((vmatch<<1)&(1<<8)))) + { + T1WriteWord(MMU.ARM7_REG, 4, T1ReadWord(MMU.ARM7_REG, 4) | 4); + if(T1ReadWord(MMU.ARM7_REG, 4) & 32) + NDS_makeARM7Int(2); + } + else + T1WriteWord(MMU.ARM7_REG, 4, T1ReadWord(MMU.ARM7_REG, 4) & 0xFFFB); + } + } // if(nds.cycles >= nds.nextHBlank) + + /* } // for(i = 0; i < INSTRUCTIONS_PER_BATCH && (!FORCE) && (execute); i++) + + } // if(!nds.sleeping) + + } // for (j = 0; j < INSTRUCTIONS_PER_BATCH && (!FORCE) && (execute); j++) + + if(!nds.sleeping) + {*/ + +#ifdef USE_GEOMETRY_FIFO_EMULATION + if (nds.cycles > MMU.gfx3dCycles) + gfx3d_execute3D(); +#endif + + if(MMU.divRunning) + { + if(nds.cycles > MMU.divCycles) + { + T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x2A0, (u32)MMU.divResult); + T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x2A4, (u32)(MMU.divResult >> 32)); + T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x2A8, (u32)MMU.divMod); + T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x2AC, (u32)(MMU.divMod >> 32)); + T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x280, MMU.divCnt); + + MMU.divRunning = FALSE; + } + } + + if(MMU.sqrtRunning) + { + if(nds.cycles > MMU.sqrtCycles) + { + T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x2B4, MMU.sqrtResult); + T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x2B0, MMU.sqrtCnt); + + MMU.sqrtRunning = FALSE; + } + } + + if (MMU.CheckTimers) + { + /* assume the timers have not expired */ + nds.timerOver[0][0] = 0; + nds.timerOver[0][1] = 0; + nds.timerOver[0][2] = 0; + nds.timerOver[0][3] = 0; + nds.timerOver[1][0] = 0; + nds.timerOver[1][1] = 0; + nds.timerOver[1][2] = 0; + nds.timerOver[1][3] = 0; + if(MMU.timerON[0][0]) + { + if(MMU.timerRUN[0][0]) + { + switch(MMU.timerMODE[0][0]) + { + case 0xFFFF : + break; + default : + { + nds.diff = (nds.cycles - nds.timerCycle[0][0])>>MMU.timerMODE[0][0]; + nds.old = MMU.timer[0][0]; + MMU.timer[0][0] += nds.diff; + nds.timerCycle[0][0] += (nds.diff << MMU.timerMODE[0][0]); + nds.timerOver[0][0] = nds.old>MMU.timer[0][0]; + if(nds.timerOver[0][0]) + { + if(T1ReadWord(ARM9Mem.ARM9_REG, 0x102) & 0x40) + NDS_makeARM9Int(3); + MMU.timer[0][0] = MMU.timerReload[0][0]; + } + } + break; + } + } + else + { + MMU.timerRUN[0][0] = TRUE; + nds.timerCycle[0][0] = nds.cycles; + } + } + if(MMU.timerON[0][1]) + { + if(MMU.timerRUN[0][1]) + { + switch(MMU.timerMODE[0][1]) + { + case 0xFFFF : + if(nds.timerOver[0][0]) + { + ++(MMU.timer[0][1]); + nds.timerOver[0][1] = !MMU.timer[0][1]; + if (nds.timerOver[0][1]) + { + if(T1ReadWord(ARM9Mem.ARM9_REG, 0x106) & 0x40) + NDS_makeARM9Int(4); + MMU.timer[0][1] = MMU.timerReload[0][1]; + } + } + break; + default : + { + nds.diff = (nds.cycles - nds.timerCycle[0][1])>>MMU.timerMODE[0][1]; + nds.old = MMU.timer[0][1]; + MMU.timer[0][1] += nds.diff; + nds.timerCycle[0][1] += nds.diff << MMU.timerMODE[0][1]; + nds.timerOver[0][1] = nds.old>MMU.timer[0][1]; + if(nds.timerOver[0][1]) + { + if(T1ReadWord(ARM9Mem.ARM9_REG, 0x106) & 0x40) + NDS_makeARM9Int(4); + MMU.timer[0][1] = MMU.timerReload[0][1]; + } + } + break; + + } + } + else + { + MMU.timerRUN[0][1] = TRUE; + nds.timerCycle[0][1] = nds.cycles; + } + } + if(MMU.timerON[0][2]) + { + if(MMU.timerRUN[0][2]) + { + switch(MMU.timerMODE[0][2]) + { + case 0xFFFF : + if(nds.timerOver[0][1]) + { + ++(MMU.timer[0][2]); + nds.timerOver[0][2] = !MMU.timer[0][2]; + if (nds.timerOver[0][2]) + { + if(T1ReadWord(ARM9Mem.ARM9_REG, 0x10A) & 0x40) + NDS_makeARM9Int(5); + MMU.timer[0][2] = MMU.timerReload[0][2]; + } + } + break; + default : + { + nds.diff = (nds.cycles - nds.timerCycle[0][2])>>MMU.timerMODE[0][2]; + nds.old = MMU.timer[0][2]; + MMU.timer[0][2] += nds.diff; + nds.timerCycle[0][2] += nds.diff << MMU.timerMODE[0][2]; + nds.timerOver[0][2] = nds.old>MMU.timer[0][2]; + if(nds.timerOver[0][2]) + { + if(T1ReadWord(ARM9Mem.ARM9_REG, 0x10A) & 0x40) + NDS_makeARM9Int(5); + MMU.timer[0][2] = MMU.timerReload[0][2]; + } + } + break; + } + } + else + { + MMU.timerRUN[0][2] = TRUE; + nds.timerCycle[0][2] = nds.cycles; + } + } + if(MMU.timerON[0][3]) + { + if(MMU.timerRUN[0][3]) + { + switch(MMU.timerMODE[0][3]) + { + case 0xFFFF : + if(nds.timerOver[0][2]) + { + ++(MMU.timer[0][3]); + nds.timerOver[0][3] = !MMU.timer[0][3]; + if (nds.timerOver[0][3]) + { + if(T1ReadWord(ARM9Mem.ARM9_REG, 0x10E) & 0x40) + NDS_makeARM9Int(6); + MMU.timer[0][3] = MMU.timerReload[0][3]; + } + } + break; + default : + { + nds.diff = (nds.cycles - nds.timerCycle[0][3])>>MMU.timerMODE[0][3]; + nds.old = MMU.timer[0][3]; + MMU.timer[0][3] += nds.diff; + nds.timerCycle[0][3] += nds.diff << MMU.timerMODE[0][3]; + nds.timerOver[0][3] = nds.old>MMU.timer[0][3]; + if(nds.timerOver[0][3]) + { + if(T1ReadWord(ARM9Mem.ARM9_REG, 0x10E) & 0x40) + NDS_makeARM9Int(6); + MMU.timer[0][3] = MMU.timerReload[0][3]; + } + } + break; + } + } + else + { + MMU.timerRUN[0][3] = TRUE; + nds.timerCycle[0][3] = nds.cycles; + } + } + + if(MMU.timerON[1][0]) + { + if(MMU.timerRUN[1][0]) + { + switch(MMU.timerMODE[1][0]) + { + case 0xFFFF : + break; + default : + { + nds.diff = (nds.cycles - nds.timerCycle[1][0])>>MMU.timerMODE[1][0]; + nds.old = MMU.timer[1][0]; + MMU.timer[1][0] += nds.diff; + nds.timerCycle[1][0] += nds.diff << MMU.timerMODE[1][0]; + nds.timerOver[1][0] = nds.old>MMU.timer[1][0]; + if(nds.timerOver[1][0]) + { + if(T1ReadWord(MMU.ARM7_REG, 0x102) & 0x40) + NDS_makeARM7Int(3); + MMU.timer[1][0] = MMU.timerReload[1][0]; + } + } + break; + } + } + else + { + MMU.timerRUN[1][0] = TRUE; + nds.timerCycle[1][0] = nds.cycles; + } + } + if(MMU.timerON[1][1]) + { + if(MMU.timerRUN[1][1]) + { + switch(MMU.timerMODE[1][1]) + { + case 0xFFFF : + if(nds.timerOver[1][0]) + { + ++(MMU.timer[1][1]); + nds.timerOver[1][1] = !MMU.timer[1][1]; + if (nds.timerOver[1][1]) + { + if(T1ReadWord(MMU.ARM7_REG, 0x106) & 0x40) + NDS_makeARM7Int(4); + MMU.timer[1][1] = MMU.timerReload[1][1]; + } + } + break; + default : + { + nds.diff = (nds.cycles - nds.timerCycle[1][1])>>MMU.timerMODE[1][1]; + nds.old = MMU.timer[1][1]; + MMU.timer[1][1] += nds.diff; + nds.timerCycle[1][1] += nds.diff << MMU.timerMODE[1][1]; + nds.timerOver[1][1] = nds.old>MMU.timer[1][1]; + if(nds.timerOver[1][1]) + { + if(T1ReadWord(MMU.ARM7_REG, 0x106) & 0x40) + NDS_makeARM7Int(4); + MMU.timer[1][1] = MMU.timerReload[1][1]; + } + } + break; + } + } + else + { + MMU.timerRUN[1][1] = TRUE; + nds.timerCycle[1][1] = nds.cycles; + } + } + if(MMU.timerON[1][2]) + { + if(MMU.timerRUN[1][2]) + { + switch(MMU.timerMODE[1][2]) + { + case 0xFFFF : + if(nds.timerOver[1][1]) + { + ++(MMU.timer[1][2]); + nds.timerOver[1][2] = !MMU.timer[1][2]; + if (nds.timerOver[1][2]) + { + if(T1ReadWord(MMU.ARM7_REG, 0x10A) & 0x40) + NDS_makeARM7Int(5); + MMU.timer[1][2] = MMU.timerReload[1][2]; + } + } + break; + default : + { + nds.diff = (nds.cycles - nds.timerCycle[1][2])>>MMU.timerMODE[1][2]; + nds.old = MMU.timer[1][2]; + MMU.timer[1][2] += nds.diff; + nds.timerCycle[1][2] += nds.diff << MMU.timerMODE[1][2]; + nds.timerOver[1][2] = nds.old>MMU.timer[1][2]; + if(nds.timerOver[1][2]) + { + if(T1ReadWord(MMU.ARM7_REG, 0x10A) & 0x40) + NDS_makeARM7Int(5); + MMU.timer[1][2] = MMU.timerReload[1][2]; + } + } + break; + } + } + else + { + MMU.timerRUN[1][2] = TRUE; + nds.timerCycle[1][2] = nds.cycles; + } + } + if(MMU.timerON[1][3]) + { + if(MMU.timerRUN[1][3]) + { + switch(MMU.timerMODE[1][3]) + { + case 0xFFFF : + if(nds.timerOver[1][2]) + { + ++(MMU.timer[1][3]); + nds.timerOver[1][3] = !MMU.timer[1][3]; + if (nds.timerOver[1][3]) + { + if(T1ReadWord(MMU.ARM7_REG, 0x10E) & 0x40) + NDS_makeARM7Int(6); + MMU.timer[1][3] += MMU.timerReload[1][3]; + } + } + break; + default : + { + nds.diff = (nds.cycles - nds.timerCycle[1][3])>>MMU.timerMODE[1][3]; + nds.old = MMU.timer[1][3]; + MMU.timer[1][3] += nds.diff; + nds.timerCycle[1][3] += nds.diff << MMU.timerMODE[1][3]; + nds.timerOver[1][3] = nds.old>MMU.timer[1][3]; + if(nds.timerOver[1][3]) + { + if(T1ReadWord(MMU.ARM7_REG, 0x10E) & 0x40) + NDS_makeARM7Int(6); + MMU.timer[1][3] += MMU.timerReload[1][3]; + } + } + break; + } + } + else + { + MMU.timerRUN[1][3] = TRUE; + nds.timerCycle[1][3] = nds.cycles; + } + } + } + + if (MMU.CheckDMAs) + { + + if((MMU.DMAing[0][0])&&(MMU.DMACycle[0][0]<=nds.cycles)) + { + T1WriteLong(ARM9Mem.ARM9_REG, 0xB8 + (0xC*0), T1ReadLong(ARM9Mem.ARM9_REG, 0xB8 + (0xC*0)) & 0x7FFFFFFF); + if((MMU.DMACrt[0][0])&(1<<30)) NDS_makeARM9Int(8); + MMU.DMAing[0][0] = FALSE; + MMU.CheckDMAs &= ~(1<<(0+(0<<2))); + } + + if((MMU.DMAing[0][1])&&(MMU.DMACycle[0][1]<=nds.cycles)) + { + T1WriteLong(ARM9Mem.ARM9_REG, 0xB8 + (0xC*1), T1ReadLong(ARM9Mem.ARM9_REG, 0xB8 + (0xC*1)) & 0x7FFFFFFF); + if((MMU.DMACrt[0][1])&(1<<30)) NDS_makeARM9Int(9); + MMU.DMAing[0][1] = FALSE; + MMU.CheckDMAs &= ~(1<<(1+(0<<2))); + } + + if((MMU.DMAing[0][2])&&(MMU.DMACycle[0][2]<=nds.cycles)) + { + T1WriteLong(ARM9Mem.ARM9_REG, 0xB8 + (0xC*2), T1ReadLong(ARM9Mem.ARM9_REG, 0xB8 + (0xC*2)) & 0x7FFFFFFF); + if((MMU.DMACrt[0][2])&(1<<30)) NDS_makeARM9Int(10); + MMU.DMAing[0][2] = FALSE; + MMU.CheckDMAs &= ~(1<<(2+(0<<2))); + } + + if((MMU.DMAing[0][3])&&(MMU.DMACycle[0][3]<=nds.cycles)) + { + T1WriteLong(ARM9Mem.ARM9_REG, 0xB8 + (0xC*3), T1ReadLong(ARM9Mem.ARM9_REG, 0xB8 + (0xC*3)) & 0x7FFFFFFF); + if((MMU.DMACrt[0][3])&(1<<30)) NDS_makeARM9Int(11); + MMU.DMAing[0][3] = FALSE; + MMU.CheckDMAs &= ~(1<<(3+(0<<2))); + } + + if((MMU.DMAing[1][0])&&(MMU.DMACycle[1][0]<=nds.cycles)) + { + T1WriteLong(MMU.ARM7_REG, 0xB8 + (0xC*0), T1ReadLong(MMU.ARM7_REG, 0xB8 + (0xC*0)) & 0x7FFFFFFF); + if((MMU.DMACrt[1][0])&(1<<30)) NDS_makeARM7Int(8); + MMU.DMAing[1][0] = FALSE; + MMU.CheckDMAs &= ~(1<<(0+(1<<2))); + } + + if((MMU.DMAing[1][1])&&(MMU.DMACycle[1][1]<=nds.cycles)) + { + T1WriteLong(MMU.ARM7_REG, 0xB8 + (0xC*1), T1ReadLong(MMU.ARM7_REG, 0xB8 + (0xC*1)) & 0x7FFFFFFF); + if((MMU.DMACrt[1][1])&(1<<30)) NDS_makeARM7Int(9); + MMU.DMAing[1][1] = FALSE; + MMU.CheckDMAs &= ~(1<<(1+(1<<2))); + } + + if((MMU.DMAing[1][2])&&(MMU.DMACycle[1][2]<=nds.cycles)) + { + T1WriteLong(MMU.ARM7_REG, 0xB8 + (0xC*2), T1ReadLong(MMU.ARM7_REG, 0xB8 + (0xC*2)) & 0x7FFFFFFF); + if((MMU.DMACrt[1][2])&(1<<30)) NDS_makeARM7Int(10); + MMU.DMAing[1][2] = FALSE; + MMU.CheckDMAs &= ~(1<<(2+(1<<2))); + } + + if((MMU.DMAing[1][3])&&(MMU.DMACycle[1][3]<=nds.cycles)) + { + T1WriteLong(MMU.ARM7_REG, 0xB8 + (0xC*3), T1ReadLong(MMU.ARM7_REG, 0xB8 + (0xC*3)) & 0x7FFFFFFF); + if((MMU.DMACrt[1][3])&(1<<30)) NDS_makeARM7Int(11); + MMU.DMAing[1][3] = FALSE; + MMU.CheckDMAs &= ~(1<<(3+(1<<2))); + } + } + +#ifndef USE_GEOMETRY_FIFO_EMULATION + if(MMU.reg_IE[ARMCPU_ARM9]&(1<<21)) + NDS_makeARM9Int(21); // GX geometry +#endif + + if((MMU.reg_IF[0]&MMU.reg_IE[0]) && (MMU.reg_IME[0])) + { +#ifdef GDB_STUB + if ( armcpu_flagIrq( &NDS_ARM9)) +#else + if ( armcpu_irqException(&NDS_ARM9)) +#endif + { + nds.ARM9Cycle = nds.cycles; + } + } + + if((MMU.reg_IF[1]&MMU.reg_IE[1]) && (MMU.reg_IME[1])) + { +#ifdef GDB_STUB + if ( armcpu_flagIrq( &NDS_ARM7)) +#else + if ( armcpu_irqException(&NDS_ARM7)) +#endif + { + nds.ARM7Cycle = nds.cycles; + } + } + + } // if(!nds.sleeping) + else + { + gpu_UpdateRender(); + if((MMU.reg_IE[1] & MMU.reg_IF[1]) & (1<<22)) + { + nds.sleeping = FALSE; + } + break; } } - //end of frame emulation housekeeping if(LagFrameFlag) { lagframecounter++; @@ -2222,240 +2495,8 @@ void NDS_exec(s32 nb) lastLag = lagframecounter; lagframecounter = 0; } - currFrameCounter++; - cheatsProcess(); -} -void execHardware_interrupts() -{ - //THIS IS A HACK but it is necessary until we have gxfifo emulation - #ifndef USE_GEOMETRY_FIFO_EMULATION - if(MMU.reg_IE[ARMCPU_ARM9]&(1<<21)) - NDS_makeARM9Int(21); // GX geometry - #endif - - if((MMU.reg_IF[0]&MMU.reg_IE[0]) && (MMU.reg_IME[0])) - { -#ifdef GDB_STUB - if ( armcpu_flagIrq( &NDS_ARM9)) -#else - if ( armcpu_irqException(&NDS_ARM9)) -#endif - { - //nds.ARM9Cycle = nds.cycles; - } - } - - if((MMU.reg_IF[1]&MMU.reg_IE[1]) && (MMU.reg_IME[1])) - { -#ifdef GDB_STUB - if ( armcpu_flagIrq( &NDS_ARM7)) -#else - if ( armcpu_irqException(&NDS_ARM7)) -#endif - { - //nds.ARM7Cycle = nds.cycles; - } - } -} - -bool _HACK_DONT_STOPMOVIE = false; -void NDS_Reset() -{ - u32 src; - u32 dst; - FILE* inf = 0; - NDS_header * header = NDS_getROMHeader(); - - if (!header) return ; - - nds_timer = 0; - nds_arm9_timer = 0; - nds_arm7_timer = 0; - - if(movieMode != MOVIEMODE_INACTIVE && !_HACK_DONT_STOPMOVIE) - movie_reset_command = true; - - if(movieMode == MOVIEMODE_INACTIVE) { - currFrameCounter = 0; - lagframecounter = 0; - LagFrameFlag = 0; - lastLag = 0; - TotalLagFrames = 0; - } - - MMU_clearMem(); - MMU_new.backupDevice.reset(); - - //ARM7 BIOS IRQ HANDLER - if(CommonSettings.UseExtBIOS == true) - inf = fopen(CommonSettings.ARM7BIOS,"rb"); - else - inf = NULL; - - if(inf) { - fread(MMU.ARM7_BIOS,1,16384,inf); - fclose(inf); - if(CommonSettings.SWIFromBIOS == true) NDS_ARM7.swi_tab = 0; - else NDS_ARM7.swi_tab = ARM7_swi_tab; - INFO("ARM7 BIOS is loaded.\n"); - } else { - NDS_ARM7.swi_tab = ARM7_swi_tab; - _MMU_write32(0x00, 0xE25EF002); - _MMU_write32(0x04, 0xEAFFFFFE); - _MMU_write32(0x18, 0xEA000000); - _MMU_write32(0x20, 0xE92D500F); - _MMU_write32(0x24, 0xE3A00301); - _MMU_write32(0x28, 0xE28FE000); - _MMU_write32(0x2C, 0xE510F004); - _MMU_write32(0x30, 0xE8BD500F); - _MMU_write32(0x34, 0xE25EF004); - } - - //ARM9 BIOS IRQ HANDLER - if(CommonSettings.UseExtBIOS == true) - inf = fopen(CommonSettings.ARM9BIOS,"rb"); - else - inf = NULL; - //memcpy(ARM9Mem.ARM9_BIOS + 0x20, gba_header_data_0x04, 156); - - if(inf) { - fread(ARM9Mem.ARM9_BIOS,1,4096,inf); - fclose(inf); - if(CommonSettings.SWIFromBIOS == true) NDS_ARM9.swi_tab = 0; - else NDS_ARM9.swi_tab = ARM9_swi_tab; - INFO("ARM9 BIOS is loaded.\n"); - } else { - NDS_ARM9.swi_tab = ARM9_swi_tab; - _MMU_write32(0xFFFF0018, 0xEA000000); - _MMU_write32(0xFFFF0020, 0xE92D500F); - _MMU_write32(0xFFFF0024, 0xEE190F11); - _MMU_write32(0xFFFF0028, 0xE1A00620); - _MMU_write32(0xFFFF002C, 0xE1A00600); - _MMU_write32(0xFFFF0030, 0xE2800C40); - _MMU_write32(0xFFFF0034, 0xE28FE000); - _MMU_write32(0xFFFF0038, 0xE510F004); - _MMU_write32(0xFFFF003C, 0xE8BD500F); - _MMU_write32(0xFFFF0040, 0xE25EF004); - } - - /* Is it really needed ??? */ - _MMU_write32(0x0000004, 0xE3A0010E); - _MMU_write32(0x0000008, 0xE3A01020); - // _MMU_write32(0x000000C, 0xE1B02110); - _MMU_write32(0x000000C, 0xE1B02040); - _MMU_write32(0x0000010, 0xE3B02020); - // _MMU_write32(0x0000010, 0xE2100202); - - if(CommonSettings.UseExtFirmware == true) - NDS_LoadFirmware(CommonSettings.Firmware); - - if((CommonSettings.UseExtBIOS == true) && (CommonSettings.UseExtFirmware == true) && (CommonSettings.BootFromFirmware == true) && (fw_success == TRUE)) - { - for(int i = 0; i < nds.FW_ARM9BootCodeSize; i += 4) - { - _MMU_write32((nds.FW_ARM9BootCodeAddr + i), T1ReadLong(nds.FW_ARM9BootCode, i)); - } - - for(int i = 0; i < nds.FW_ARM7BootCodeSize; i += 4) - { - _MMU_write32((nds.FW_ARM7BootCodeAddr + i), T1ReadLong(nds.FW_ARM7BootCode, i)); - } - - armcpu_init(&NDS_ARM9, nds.FW_ARM9BootCodeAddr); - armcpu_init(&NDS_ARM7, nds.FW_ARM7BootCodeAddr); - //armcpu_init(&NDS_ARM9, 0xFFFF0000); - //armcpu_init(&NDS_ARM7, 0x00000000); - } - else - { - src = header->ARM9src; - dst = header->ARM9cpy; - - for(int i = 0; i < (header->ARM9binSize>>2); ++i) - { - _MMU_write32(dst, T1ReadLong(MMU.CART_ROM, src)); - dst += 4; - src += 4; - } - - src = header->ARM7src; - dst = header->ARM7cpy; - - for(int i = 0; i < (header->ARM7binSize>>2); ++i) - { - _MMU_write32(dst, T1ReadLong(MMU.CART_ROM, src)); - dst += 4; - src += 4; - } - - armcpu_init(&NDS_ARM7, header->ARM7exe); - armcpu_init(&NDS_ARM9, header->ARM9exe); - } - - nds.wifiCycle = 0; - memset(nds.timerCycle, 0, sizeof(u64) * 2 * 4); - nds.VCount = 0; - nds.old = 0; - nds.touchX = nds.touchY = 0; - nds.isTouch = 0; - nds.debugConsole = CommonSettings.DebugConsole; - SetupMMU(nds.debugConsole); - - _MMU_write16(0x04000130, 0x3FF); - _MMU_write16(0x04000130, 0x3FF); - _MMU_write08(0x04000136, 0x43); - - LidClosed = FALSE; - countLid = 0; - - /* - * Setup a copy of the firmware user settings in memory. - * (this is what the DS firmware would do). - */ - { - u8 temp_buffer[NDS_FW_USER_SETTINGS_MEM_BYTE_COUNT]; - int fw_index; - - if ( copy_firmware_user_data( temp_buffer, MMU.fw.data)) { - for ( fw_index = 0; fw_index < NDS_FW_USER_SETTINGS_MEM_BYTE_COUNT; fw_index++) - _MMU_write08(0x027FFC80 + fw_index, temp_buffer[fw_index]); - } - } - - // Copy the whole header to Main RAM 0x27FFE00 on startup. - // Reference: http://nocash.emubase.de/gbatek.htm#dscartridgeheader - //zero 27-jun-09 : why did this copy 0x90 more? gbatek says its not stored in ram. - //for (i = 0; i < ((0x170+0x90)/4); i++) { - for (int i = 0; i < ((0x170)/4); i++) { - _MMU_write32(0x027FFE00+i*4, LE_TO_LOCAL_32(((u32*)MMU.CART_ROM)[i])); - } - - // Write the header checksum to memory (the firmware needs it to see the cart) - _MMU_write16(0x027FF808, T1ReadWord(MMU.CART_ROM, 0x15E)); - - MainScreen.offset = 0; - SubScreen.offset = 192; - - //_MMU_write32[ARMCPU_ARM9](0x02007FFC, 0xE92D4030); - - delete header; - - Screen_Reset(); - gfx3d_reset(); - gpu3D->NDS_3D_Reset(); - SPU_Reset(); - -#ifdef EXPERIMENTAL_WIFI - WIFI_Init(&wifiMac); - - WIFI_SoftAP_Shutdown(&wifiMac); - WIFI_SoftAP_Init(&wifiMac); -#endif - - memcpy(FW_Mac, (MMU.fw.data + 0x36), 6); - - initSchedule(); + return nds.cycles; } static std::string MakeInputDisplayString(u16 pad, const std::string* Buttons, int count) { @@ -2506,7 +2547,6 @@ void NDS_setPadFromMovie(u16 pad) movie_lid ); #undef FIX - } turbo Turbo; @@ -2669,7 +2709,8 @@ void NDS_setPad(bool R,bool L,bool D,bool U,bool T,bool S,bool B,bool A,bool Y,b (FIX(y)<<4)| (FIX(x)<<3)| (FIX(w)<<2)| - (FIX(e)<<1); + (FIX(e)<<1)| + (FIX(f)<<0); // TODO: low power IRQ } @@ -2680,5 +2721,5 @@ void emu_halt() { } //these templates needed to be instantiated manually -template void NDS_exec(s32 nb); -template void NDS_exec(s32 nb); +template u32 NDS_exec(s32 nb); +template u32 NDS_exec(s32 nb); diff --git a/desmume/src/NDSSystem.h b/src/NDSSystem.h similarity index 74% rename from desmume/src/NDSSystem.h rename to src/NDSSystem.h index 9101b55ed..84865607c 100644 --- a/desmume/src/NDSSystem.h +++ b/src/NDSSystem.h @@ -2,8 +2,6 @@ yopyop156@ifrance.com yopyop156.ifrance.com - Copyright (C) 2008-2009 DeSmuME team - This file is part of DeSmuME DeSmuME is free software; you can redistribute it and/or modify @@ -18,12 +16,17 @@ You should have received a copy of the GNU General Public License along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ #ifndef NDSSYSTEM_H #define NDSSYSTEM_H +// NOTE: DEFINING G_NEW_SPU_TIMING CHANGES THE MOVIE SYNC +//#ifndef G_NEW_SPU_TIMING +//#define G_NEW_SPU_TIMING +//#endif + #include #include "armcpu.h" #include "MMU.h" @@ -100,6 +103,8 @@ int NDS_WritePNG(const char *fname); extern volatile BOOL execute; extern BOOL click; +extern char pathToROM[MAX_PATH]; +extern char pathFilenameToROMwithoutExt[MAX_PATH]; /* * The firmware language values @@ -171,19 +176,18 @@ struct NDS_header extern void debug(); void emu_halt(); -extern u64 nds_timer; -void NDS_Reschedule(); -void NDS_RescheduleGXFIFO(); -void NDS_RescheduleDMA(); -void NDS_RescheduleTimers(); - typedef struct { - s32 wifiCycle; + s32 ARM9Cycle; + s32 ARM7Cycle; s32 cycles; - u64 timerCycle[2][4]; + s32 timerCycle[2][4]; + BOOL timerOver[2][4]; + s32 nextHBlank; u32 VCount; u32 old; + s32 diff; + BOOL lignerendu; u16 touchX; u16 touchY; @@ -265,8 +269,6 @@ int NDS_Init( struct armcpu_memory_iface *arm9_mem_if, int NDS_Init ( void); #endif -void Desmume_InitOnce(); - void NDS_DeInit(void); void NDS_FillDefaultFirmwareConfigData( struct NDS_fw_config_data *fw_config); @@ -276,38 +278,30 @@ NDS_header * NDS_getROMHeader(void); struct GameInfo { - GameInfo() - : romdata(NULL) - {} - - void resize(int size) { - if(romdata != NULL) delete[] romdata; - romdata = new char[size]; - romsize = size; - } u32 crc; NDS_header header; char ROMserial[20]; void populate(); - char* romdata; - int romsize; }; extern GameInfo gameInfo; + void NDS_setTouchPos(u16 x, u16 y); void NDS_releaseTouch(void); void NDS_setPad(bool R,bool L,bool D,bool U,bool T,bool S,bool B,bool A,bool Y,bool X,bool W,bool E,bool G, bool F); void NDS_setPadFromMovie(u16 pad); -int NDS_LoadROM(const char *filename, const char* logicalFilename=0); +#ifdef EXPERIMENTAL_GBASLOT +int NDS_LoadROM(const char *filename, int bmtype, u32 bmsize, const char* logicalFilename=0); +#else +int NDS_LoadROM(const char *filename, int bmtype, u32 bmsize, + const char *cflash_disk_image_file, const char* logicalFilename=0); +#endif void NDS_FreeROM(void); void NDS_Reset(); int NDS_ImportSave(const char *filename); bool NDS_ExportSave(const char *filename); -void nds_savestate(std::ostream* os); -bool nds_loadstate(std::istream* is, int size); - int NDS_WriteBMP(const char *filename); int NDS_LoadFirmware(const char *filename); int NDS_CreateDummyFirmware( struct NDS_fw_config_data *user_settings); @@ -317,61 +311,62 @@ void NDS_Sleep(); void NDS_SkipNextFrame(); #define NDS_SkipFrame(s) if(s) NDS_SkipNext2DFrame(); -template void NDS_exec(s32 nb = 560190<<1); +template +u32 NDS_exec(s32 nb); extern int lagframecounter; -static INLINE void NDS_ARM9HBlankInt(void) -{ - if(T1ReadWord(ARM9Mem.ARM9_REG, 4) & 0x10) - { - //MMU.reg_IF[0] |= 2;// & (MMU.reg_IME[0] << 1);// (MMU.reg_IE[0] & (1<<1)); - setIF(0, 2); - NDS_ARM9.wIRQ = TRUE; - } -} - -static INLINE void NDS_ARM7HBlankInt(void) -{ - if(T1ReadWord(MMU.ARM7_REG, 4) & 0x10) - { - // MMU.reg_IF[1] |= 2;// & (MMU.reg_IME[1] << 1);// (MMU.reg_IE[1] & (1<<1)); - setIF(1, 2); - NDS_ARM7.wIRQ = TRUE; - } -} - -static INLINE void NDS_ARM9VBlankInt(void) -{ - if(T1ReadWord(ARM9Mem.ARM9_REG, 4) & 0x8) - { - // MMU.reg_IF[0] |= 1;// & (MMU.reg_IME[0]);// (MMU.reg_IE[0] & 1); - setIF(0, 1); - NDS_ARM9.wIRQ = TRUE; - //emu_halt(); - /*logcount++;*/ - } -} - -static INLINE void NDS_ARM7VBlankInt(void) -{ - if(T1ReadWord(MMU.ARM7_REG, 4) & 0x8) - // MMU.reg_IF[1] |= 1;// & (MMU.reg_IME[1]);// (MMU.reg_IE[1] & 1); - setIF(1, 1); - NDS_ARM7.wIRQ = TRUE; - //emu_halt(); -} - -static INLINE void NDS_swapScreen(void) -{ - u16 tmp = MainScreen.offset; - MainScreen.offset = SubScreen.offset; - SubScreen.offset = tmp; -} - -int NDS_WriteBMP_32bppBuffer(int width, int height, const void* buf, const char *filename); +inline u32 NDS_exec(s32 nb) { return NDS_exec(nb); } + static INLINE void NDS_ARM9HBlankInt(void) + { + if(T1ReadWord(ARM9Mem.ARM9_REG, 4) & 0x10) + { + //MMU.reg_IF[0] |= 2;// & (MMU.reg_IME[0] << 1);// (MMU.reg_IE[0] & (1<<1)); + setIF(0, 2); + NDS_ARM9.wIRQ = TRUE; + } + } + + static INLINE void NDS_ARM7HBlankInt(void) + { + if(T1ReadWord(MMU.ARM7_REG, 4) & 0x10) + { + // MMU.reg_IF[1] |= 2;// & (MMU.reg_IME[1] << 1);// (MMU.reg_IE[1] & (1<<1)); + setIF(1, 2); + NDS_ARM7.wIRQ = TRUE; + } + } + + static INLINE void NDS_ARM9VBlankInt(void) + { + if(T1ReadWord(ARM9Mem.ARM9_REG, 4) & 0x8) + { + // MMU.reg_IF[0] |= 1;// & (MMU.reg_IME[0]);// (MMU.reg_IE[0] & 1); + setIF(0, 1); + NDS_ARM9.wIRQ = TRUE; + //emu_halt(); + /*logcount++;*/ + } + } + + static INLINE void NDS_ARM7VBlankInt(void) + { + if(T1ReadWord(MMU.ARM7_REG, 4) & 0x8) + // MMU.reg_IF[1] |= 1;// & (MMU.reg_IME[1]);// (MMU.reg_IE[1] & 1); + setIF(1, 1); + NDS_ARM7.wIRQ = TRUE; + //emu_halt(); + } + + static INLINE void NDS_swapScreen(void) + { + u16 tmp = MainScreen.offset; + MainScreen.offset = SubScreen.offset; + SubScreen.offset = tmp; + } + int NDS_WriteBMP_32bppBuffer(int width, int height, const void* buf, const char *filename); extern struct TCommonSettings { TCommonSettings() @@ -385,13 +380,10 @@ extern struct TCommonSettings { , spuInterpolationMode(SPUInterpolation_Linear) , spuAdpcmCache(false) , gfx3d_flushMode(0) - , manualBackupType(0) { strcpy(ARM9BIOS, "biosnds9.bin"); strcpy(ARM7BIOS, "biosnds7.bin"); strcpy(Firmware, "firmware.bin"); - for(int i=0;i<16;i++) - spu_muteChannels[i] = false; } bool HighResolutionInterpolateColor; @@ -414,11 +406,6 @@ extern struct TCommonSettings { //this is a temporary hack until we straighten out the flushing logic and/or gxfifo int gfx3d_flushMode; - //this is the user's choice of manual backup type, for cases when the autodetection can't be trusted - int manualBackupType; - - bool spu_muteChannels[16]; - struct _ShowGpu { _ShowGpu() : main(true), sub(true) {} union { @@ -427,17 +414,6 @@ extern struct TCommonSettings { }; } showGpu; - struct _Hud { - _Hud() - : ShowInputDisplay(false) - , FpsDisplay(false) - , FrameCounterDisplay(false) - , ShowLagFrameCounter(false) - , ShowMicrophone(false) - {} - bool ShowInputDisplay, FpsDisplay, FrameCounterDisplay, ShowLagFrameCounter, ShowMicrophone; - } hud; - } CommonSettings; diff --git a/desmume/src/OGLRender.cpp b/src/OGLRender.cpp similarity index 97% rename from desmume/src/OGLRender.cpp rename to src/OGLRender.cpp index 5c9e6ddef..8b0ae5b94 100644 --- a/desmume/src/OGLRender.cpp +++ b/src/OGLRender.cpp @@ -54,10 +54,6 @@ static void ENDGL() { #else #include #include - /* This is a workaround needed to compile against nvidia GL headers */ - #ifndef GL_ALPHA_BLEND_EQUATION_ATI - #undef GL_VERSION_1_3 - #endif #endif #endif @@ -73,8 +69,15 @@ static void ENDGL() { #include "shaders.h" #include "texcache.h" + + +#ifndef CTASSERT +#define CTASSERT(x) typedef char __assert ## y[(x) ? 1 : -1] +#endif + static ALIGN(16) u8 GPU_screen3D [256*192*4]; + static const unsigned short map3d_cull[4] = {GL_FRONT_AND_BACK, GL_FRONT, GL_BACK, 0}; static const int texEnv[4] = { GL_MODULATE, GL_DECAL, GL_MODULATE, GL_MODULATE }; static const int depthFunc[2] = { GL_LESS, GL_EQUAL }; @@ -696,15 +699,14 @@ static void GL_ReadFramebuffer() u16* dst = gfx3d_convertedScreen + (y<<8); u8* dstAlpha = gfx3d_convertedAlpha + (y<<8); + #ifndef NOSSE2 //I dont know much about this kind of stuff, but this seems to help //for some reason I couldnt make the intrinsics work - //u8* u8screen3D = (u8*)&((u32*)GPU_screen3D)[i]; - /*#define PREFETCH32(X,Y) __asm { prefetchnta [u8screen3D+32*0x##X##Y] } - #define PREFETCH128(X) PREFETCH32(X,0) PREFETCH32(X,1) PREFETCH32(X,2) PREFETCH32(X,3) \ - PREFETCH32(X,4) PREFETCH32(X,5) PREFETCH32(X,6) PREFETCH32(X,7) \ - PREFETCH32(X,8) PREFETCH32(X,9) PREFETCH32(X,A) PREFETCH32(X,B) \ - PREFETCH32(X,C) PREFETCH32(X,D) PREFETCH32(X,E) PREFETCH32(X,F) - PREFETCH128(0); PREFETCH128(1);*/ + u8* wanx = (u8*)&((u32*)GPU_screen3D)[i]; + #define ASS(X,Y) __asm { prefetchnta [wanx+32*0x##X##Y] } + #define PUNK(X) ASS(X,0) ASS(X,1) ASS(X,2) ASS(X,3) ASS(X,4) ASS(X,5) ASS(X,6) ASS(X,7) ASS(X,8) ASS(X,9) ASS(X,A) ASS(X,B) ASS(X,C) ASS(X,D) ASS(X,E) ASS(X,F) + PUNK(0); PUNK(1); + #endif for(int x=0;x<256;x++,i++) { diff --git a/desmume/src/OGLRender.h b/src/OGLRender.h similarity index 96% rename from desmume/src/OGLRender.h rename to src/OGLRender.h index 940b108a9..25cc93af4 100644 --- a/desmume/src/OGLRender.h +++ b/src/OGLRender.h @@ -1,48 +1,48 @@ -/* - Copyright (C) 2006 yopyop - Copyright (C) 2006-2007 shash - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#ifndef OGLRENDER_H -#define OGLRENDER_H - -#include "common.h" -#include -#include -#include -#include -#include -#include "debug.h" -#include "render3D.h" - -extern GPU3DInterface gpu3Dgl; - -//This is called by OGLRender whenever it initializes. -//Platforms, please be sure to set this up. -//return true if you successfully init. -extern bool (*oglrender_init)(); - -//This is called by OGLRender before it uses opengl. -//return true if youre OK with using opengl -extern bool (*oglrender_beginOpenGL)(); - -//This is called by OGLRender after it is done using opengl. -extern void (*oglrender_endOpenGL)(); - -#endif +/* + Copyright (C) 2006 yopyop + Copyright (C) 2006-2007 shash + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#ifndef OGLRENDER_H +#define OGLRENDER_H + +#include "common.h" +#include +#include +#include +#include +#include +#include "debug.h" +#include "render3D.h" + +extern GPU3DInterface gpu3Dgl; + +//This is called by OGLRender whenever it initializes. +//Platforms, please be sure to set this up. +//return true if you successfully init. +extern bool (*oglrender_init)(); + +//This is called by OGLRender before it uses opengl. +//return true if youre OK with using opengl +extern bool (*oglrender_beginOpenGL)(); + +//This is called by OGLRender after it is done using opengl. +extern void (*oglrender_endOpenGL)(); + +#endif diff --git a/desmume/src/PACKED.h b/src/PACKED.h similarity index 94% rename from desmume/src/PACKED.h rename to src/PACKED.h index dabd31ce7..eaef0c7a4 100644 --- a/desmume/src/PACKED.h +++ b/src/PACKED.h @@ -1,12 +1,12 @@ -#ifndef __GNUC__ -#pragma pack(push, 1) -#pragma warning(disable : 4103) -#endif - -#ifndef __PACKED - #ifdef __GNUC__ - #define __PACKED __attribute__((__packed__)) - #else - #define __PACKED - #endif -#endif +#ifndef __GNUC__ +#pragma pack(push, 1) +#pragma warning(disable : 4103) +#endif + +#ifndef __PACKED + #ifdef __GNUC__ + #define __PACKED __attribute__((__packed__)) + #else + #define __PACKED + #endif +#endif diff --git a/src/PACKED_END.h b/src/PACKED_END.h new file mode 100644 index 000000000..d605b7df1 --- /dev/null +++ b/src/PACKED_END.h @@ -0,0 +1,3 @@ +#if defined(_MSC_VER) || defined(__INTEL_COMPILER) +#pragma pack(pop) +#endif diff --git a/desmume/src/ROMReader.cpp b/src/ROMReader.cpp similarity index 95% rename from desmume/src/ROMReader.cpp rename to src/ROMReader.cpp index 66b8d8900..91bc02a61 100644 --- a/desmume/src/ROMReader.cpp +++ b/src/ROMReader.cpp @@ -1,236 +1,236 @@ -/* Copyright 2007 Guillaume Duhamel - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#include "ROMReader.h" - -#include -#include -#include -#ifdef HAVE_LIBZZIP -#include -#endif - -#ifdef WIN32 -#define stat(...) _stat(__VA_ARGS__) -#define S_IFMT _S_IFMT -#define S_IFREG _S_IFREG -#endif - -ROMReader_struct * ROMReaderInit(char ** filename) -{ -#ifdef HAVE_LIBZ - if(!strcasecmp(".gz", *filename + (strlen(*filename) - 3))) - { - (*filename)[strlen(*filename) - 3] = '\0'; - return &GZIPROMReader; - } -#endif -#ifdef HAVE_LIBZZIP - if (!strcasecmp(".zip", *filename + (strlen(*filename) - 4))) - { - (*filename)[strlen(*filename) - 4] = '\0'; - return &ZIPROMReader; - } -#endif - return &STDROMReader; -} - -void * STDROMReaderInit(const char * filename); -void STDROMReaderDeInit(void *); -u32 STDROMReaderSize(void *); -int STDROMReaderSeek(void *, int, int); -int STDROMReaderRead(void *, void *, u32); - -ROMReader_struct STDROMReader = -{ - ROMREADER_STD, - "Standard ROM Reader", - STDROMReaderInit, - STDROMReaderDeInit, - STDROMReaderSize, - STDROMReaderSeek, - STDROMReaderRead -}; - -void * STDROMReaderInit(const char * filename) -{ -#ifdef WIN32 - struct _stat sb; -#else - struct stat sb; -#endif - if (stat(filename, &sb) == -1) - return 0; - - if ((sb.st_mode & S_IFMT) != S_IFREG) - return 0; - - return (void *) fopen(filename, "rb"); -} - -void STDROMReaderDeInit(void * file) -{ - if (!file) return ; - fclose((FILE*)file); -} - -u32 STDROMReaderSize(void * file) -{ - u32 size; - - if (!file) return 0 ; - - fseek((FILE*)file, 0, SEEK_END); - size = ftell((FILE*)file); - fseek((FILE*)file, 0, SEEK_SET); - - return size; -} - -int STDROMReaderSeek(void * file, int offset, int whence) -{ - if (!file) return 0 ; - return fseek((FILE*)file, offset, whence); -} - -int STDROMReaderRead(void * file, void * buffer, u32 size) -{ - if (!file) return 0 ; - return fread(buffer, 1, size, (FILE*)file); -} - -#ifdef HAVE_LIBZ -void * GZIPROMReaderInit(const char * filename); -void GZIPROMReaderDeInit(void *); -u32 GZIPROMReaderSize(void *); -int GZIPROMReaderSeek(void *, int, int); -int GZIPROMReaderRead(void *, void *, u32); - -ROMReader_struct GZIPROMReader = -{ - ROMREADER_GZIP, - "Gzip ROM Reader", - GZIPROMReaderInit, - GZIPROMReaderDeInit, - GZIPROMReaderSize, - GZIPROMReaderSeek, - GZIPROMReaderRead -}; - -void * GZIPROMReaderInit(const char * filename) -{ - return (void*)gzopen(filename, "rb"); -} - -void GZIPROMReaderDeInit(void * file) -{ - gzclose(file); -} - -u32 GZIPROMReaderSize(void * file) -{ - char useless[1024]; - u32 size = 0; - - /* FIXME this function should first save the current - * position and restore it after size calculation */ - gzrewind(file); - while (gzeof (file) == 0) - size += gzread(file, useless, 1024); - gzrewind(file); - - return size; -} - -int GZIPROMReaderSeek(void * file, int offset, int whence) -{ - return gzseek(file, offset, whence); -} - -int GZIPROMReaderRead(void * file, void * buffer, u32 size) -{ - return gzread(file, buffer, size); -} -#endif - -#ifdef HAVE_LIBZZIP -void * ZIPROMReaderInit(const char * filename); -void ZIPROMReaderDeInit(void *); -u32 ZIPROMReaderSize(void *); -int ZIPROMReaderSeek(void *, int, int); -int ZIPROMReaderRead(void *, void *, u32); - -ROMReader_struct ZIPROMReader = -{ - ROMREADER_ZIP, - "Zip ROM Reader", - ZIPROMReaderInit, - ZIPROMReaderDeInit, - ZIPROMReaderSize, - ZIPROMReaderSeek, - ZIPROMReaderRead -}; - -void * ZIPROMReaderInit(const char * filename) -{ - ZZIP_DIR * dir = zzip_opendir(filename); - ZZIP_DIRENT * dirent = zzip_readdir(dir); - if (dir != NULL) - { - char tmp1[1024]; - char tmp2[1024]; - memset(tmp1,0,sizeof(tmp1)); - memset(tmp2,0,sizeof(tmp2)); - strncpy(tmp1, filename, strlen(filename) - 4); - sprintf(tmp2, "%s/%s", tmp1, dirent->d_name); - return zzip_fopen(tmp2, "rb"); - } - return NULL; -} - -void ZIPROMReaderDeInit(void * file) -{ - zzip_close((ZZIP_FILE*)file); -} - -u32 ZIPROMReaderSize(void * file) -{ - u32 size; - - zzip_seek((ZZIP_FILE*)file, 0, SEEK_END); - size = zzip_tell((ZZIP_FILE*)file); - zzip_seek((ZZIP_FILE*)file, 0, SEEK_SET); - - return size; -} - -int ZIPROMReaderSeek(void * file, int offset, int whence) -{ - return zzip_seek((ZZIP_FILE*)file, offset, whence); -} - -int ZIPROMReaderRead(void * file, void * buffer, u32 size) -{ -#ifdef ZZIP_OLD_READ - return zzip_read((ZZIP_FILE*)file, (char *) buffer, size); -#else - return zzip_read((ZZIP_FILE*)file, buffer, size); -#endif -} -#endif +/* Copyright 2007 Guillaume Duhamel + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#include "ROMReader.h" + +#include +#include +#include +#ifdef HAVE_LIBZZIP +#include +#endif + +#ifdef WIN32 +#define stat(...) _stat(__VA_ARGS__) +#define S_IFMT _S_IFMT +#define S_IFREG _S_IFREG +#endif + +ROMReader_struct * ROMReaderInit(char ** filename) +{ +#ifdef HAVE_LIBZ + if(!strcasecmp(".gz", *filename + (strlen(*filename) - 3))) + { + (*filename)[strlen(*filename) - 3] = '\0'; + return &GZIPROMReader; + } +#endif +#ifdef HAVE_LIBZZIP + if (!strcasecmp(".zip", *filename + (strlen(*filename) - 4))) + { + (*filename)[strlen(*filename) - 4] = '\0'; + return &ZIPROMReader; + } +#endif + return &STDROMReader; +} + +void * STDROMReaderInit(const char * filename); +void STDROMReaderDeInit(void *); +u32 STDROMReaderSize(void *); +int STDROMReaderSeek(void *, int, int); +int STDROMReaderRead(void *, void *, u32); + +ROMReader_struct STDROMReader = +{ + ROMREADER_STD, + "Standard ROM Reader", + STDROMReaderInit, + STDROMReaderDeInit, + STDROMReaderSize, + STDROMReaderSeek, + STDROMReaderRead +}; + +void * STDROMReaderInit(const char * filename) +{ +#ifdef WIN32 + struct _stat sb; +#else + struct stat sb; +#endif + if (stat(filename, &sb) == -1) + return 0; + + if ((sb.st_mode & S_IFMT) != S_IFREG) + return 0; + + return (void *) fopen(filename, "rb"); +} + +void STDROMReaderDeInit(void * file) +{ + if (!file) return ; + fclose((FILE*)file); +} + +u32 STDROMReaderSize(void * file) +{ + u32 size; + + if (!file) return 0 ; + + fseek((FILE*)file, 0, SEEK_END); + size = ftell((FILE*)file); + fseek((FILE*)file, 0, SEEK_SET); + + return size; +} + +int STDROMReaderSeek(void * file, int offset, int whence) +{ + if (!file) return 0 ; + return fseek((FILE*)file, offset, whence); +} + +int STDROMReaderRead(void * file, void * buffer, u32 size) +{ + if (!file) return 0 ; + return fread(buffer, 1, size, (FILE*)file); +} + +#ifdef HAVE_LIBZ +void * GZIPROMReaderInit(const char * filename); +void GZIPROMReaderDeInit(void *); +u32 GZIPROMReaderSize(void *); +int GZIPROMReaderSeek(void *, int, int); +int GZIPROMReaderRead(void *, void *, u32); + +ROMReader_struct GZIPROMReader = +{ + ROMREADER_GZIP, + "Gzip ROM Reader", + GZIPROMReaderInit, + GZIPROMReaderDeInit, + GZIPROMReaderSize, + GZIPROMReaderSeek, + GZIPROMReaderRead +}; + +void * GZIPROMReaderInit(const char * filename) +{ + return (void*)gzopen(filename, "rb"); +} + +void GZIPROMReaderDeInit(void * file) +{ + gzclose(file); +} + +u32 GZIPROMReaderSize(void * file) +{ + char useless[1024]; + u32 size = 0; + + /* FIXME this function should first save the current + * position and restore it after size calculation */ + gzrewind(file); + while (gzeof (file) == 0) + size += gzread(file, useless, 1024); + gzrewind(file); + + return size; +} + +int GZIPROMReaderSeek(void * file, int offset, int whence) +{ + return gzseek(file, offset, whence); +} + +int GZIPROMReaderRead(void * file, void * buffer, u32 size) +{ + return gzread(file, buffer, size); +} +#endif + +#ifdef HAVE_LIBZZIP +void * ZIPROMReaderInit(const char * filename); +void ZIPROMReaderDeInit(void *); +u32 ZIPROMReaderSize(void *); +int ZIPROMReaderSeek(void *, int, int); +int ZIPROMReaderRead(void *, void *, u32); + +ROMReader_struct ZIPROMReader = +{ + ROMREADER_ZIP, + "Zip ROM Reader", + ZIPROMReaderInit, + ZIPROMReaderDeInit, + ZIPROMReaderSize, + ZIPROMReaderSeek, + ZIPROMReaderRead +}; + +void * ZIPROMReaderInit(const char * filename) +{ + ZZIP_DIR * dir = zzip_opendir(filename); + ZZIP_DIRENT * dirent = zzip_readdir(dir); + if (dir != NULL) + { + char tmp1[1024]; + char tmp2[1024]; + memset(tmp1,0,sizeof(tmp1)); + memset(tmp2,0,sizeof(tmp2)); + strncpy(tmp1, filename, strlen(filename) - 4); + sprintf(tmp2, "%s/%s", tmp1, dirent->d_name); + return zzip_fopen(tmp2, "rb"); + } + return NULL; +} + +void ZIPROMReaderDeInit(void * file) +{ + zzip_close((ZZIP_FILE*)file); +} + +u32 ZIPROMReaderSize(void * file) +{ + u32 size; + + zzip_seek((ZZIP_FILE*)file, 0, SEEK_END); + size = zzip_tell((ZZIP_FILE*)file); + zzip_seek((ZZIP_FILE*)file, 0, SEEK_SET); + + return size; +} + +int ZIPROMReaderSeek(void * file, int offset, int whence) +{ + return zzip_seek((ZZIP_FILE*)file, offset, whence); +} + +int ZIPROMReaderRead(void * file, void * buffer, u32 size) +{ +#ifdef ZZIP_OLD_READ + return zzip_read((ZZIP_FILE*)file, (char *) buffer, size); +#else + return zzip_read((ZZIP_FILE*)file, buffer, size); +#endif +} +#endif diff --git a/desmume/src/ROMReader.h b/src/ROMReader.h similarity index 96% rename from desmume/src/ROMReader.h rename to src/ROMReader.h index a606a5cbf..ab2e2314d 100644 --- a/desmume/src/ROMReader.h +++ b/src/ROMReader.h @@ -1,51 +1,51 @@ -/* Copyright 2007 Guillaume Duhamel - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#ifdef HAVE_LIBZ -#include -#endif -#include - -#include "types.h" - -#define ROMREADER_DEFAULT -1 -#define ROMREADER_STD 0 -#define ROMREADER_GZIP 1 -#define ROMREADER_ZIP 2 - -typedef struct -{ - int id; - const char * Name; - void * (*Init)(const char * filename); - void (*DeInit)(void * file); - u32 (*Size)(void * file); - int (*Seek)(void * file, int offset, int whence); - int (*Read)(void * file, void * buffer, u32 size); -} ROMReader_struct; - -extern ROMReader_struct STDROMReader; -#ifdef HAVE_LIBZ -extern ROMReader_struct GZIPROMReader; -#endif -#ifdef HAVE_LIBZZIP -extern ROMReader_struct ZIPROMReader; -#endif - -ROMReader_struct * ROMReaderInit(char ** filename); +/* Copyright 2007 Guillaume Duhamel + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#ifdef HAVE_LIBZ +#include +#endif +#include + +#include "types.h" + +#define ROMREADER_DEFAULT -1 +#define ROMREADER_STD 0 +#define ROMREADER_GZIP 1 +#define ROMREADER_ZIP 2 + +typedef struct +{ + int id; + const char * Name; + void * (*Init)(const char * filename); + void (*DeInit)(void * file); + u32 (*Size)(void * file); + int (*Seek)(void * file, int offset, int whence); + int (*Read)(void * file, void * buffer, u32 size); +} ROMReader_struct; + +extern ROMReader_struct STDROMReader; +#ifdef HAVE_LIBZ +extern ROMReader_struct GZIPROMReader; +#endif +#ifdef HAVE_LIBZZIP +extern ROMReader_struct ZIPROMReader; +#endif + +ROMReader_struct * ROMReaderInit(char ** filename); diff --git a/desmume/src/SPU.cpp b/src/SPU.cpp similarity index 89% rename from desmume/src/SPU.cpp rename to src/SPU.cpp index 7333dbf77..8764815f6 100644 --- a/desmume/src/SPU.cpp +++ b/src/SPU.cpp @@ -1,26 +1,22 @@ -/* Copyright (C) 2006 yopyop - yopyop156@ifrance.com - yopyop156.ifrance.com - Copyright (C) 2006 Theo Berkau - Copyright (C) 2008-2009 DeSmuME team +/* Copyright (C) 2006 Theo Berkau - Ideas borrowed from Stephane Dallongeville's SCSP core +Ideas borrowed from Stephane Dallongeville's SCSP core - This file is part of DeSmuME +This file is part of DeSmuME - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. +DeSmuME is free software; you can redistribute it and/or modify +it under the terms of the GNU General Public License as published by +the Free Software Foundation; either version 2 of the License, or +(at your option) any later version. - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. +DeSmuME is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA +You should have received a copy of the GNU General Public License +along with DeSmuME; if not, write to the Free Software +Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ #include @@ -42,6 +38,8 @@ #include "NDSSystem.h" #include "matrix.h" +#include + //#undef FORCEINLINE //#define FORCEINLINE @@ -88,6 +86,8 @@ static const s16 wavedutytbl[8][8] = { static s32 precalcdifftbl[89][16]; static u8 precalcindextbl[89][8]; +static FILE *spufp=NULL; + static const double ARM7_CLOCK = 33513982; ////////////////////////////////////////////////////////////////////////////// @@ -449,7 +449,11 @@ void SPU_struct::ShutUp() static FORCEINLINE void adjust_channel_timer(channel_struct *chan) { +#if defined(WIN32) && defined(G_NEW_SPU_TIMING) chan->sampinc = (((double)ARM7_CLOCK) / (44100 * 2)) / (double)(0x10000 - chan->timer); +#else + chan->sampinc = (((double)33554432) / (44100 * 2)) / (double)(0x10000 - chan->timer); +#endif } void SPU_struct::KeyOn(int channel) @@ -596,10 +600,10 @@ void SPU_struct::WriteWord(u32 addr, u16 val) thischan.totlength = thischan.length + thischan.loopstart; thischan.double_totlength_shifted = (double)(thischan.totlength << format_shift[thischan.format]); break; - case 0xC: + case 0xC: // svn r2324 WriteLong(addr,((u32)T1ReadWord(MMU.ARM7_REG, addr+2) << 16) | val); break; - case 0xE: + case 0xE: // svn r2324 WriteLong(addr,((u32)T1ReadWord(MMU.ARM7_REG, addr-2)) | ((u32)val<<16)); break; } @@ -679,7 +683,7 @@ template static FORCEINLINE s32 Interpola ratio = ratio - (int)ratio; double ratio2 = ((1.0 - cos(ratio * M_PI)) * 0.5); //double ratio2 = (1.0f - cos_lut[((int)(ratio*256.0))&0xFF]) / 2.0f; - return (s32)(((1-ratio2)*a) + (ratio2*b)); + return (((1-ratio2)*a) + (ratio2*b)); } else { @@ -831,9 +835,12 @@ template static FORCEINLINE void TestForLoop(SPU_struct *SPU, channe // Do we loop? Or are we done? if (chan->repeat == 1) { +#if defined(WIN32) && defined(G_NEW_SPU_TIMING) while (chan->sampcnt > chan->double_totlength_shifted) chan->sampcnt -= chan->double_totlength_shifted - (double)(chan->loopstart << shift); - //chan->sampcnt = (double)(chan->loopstart << shift); +#else + chan->sampcnt = (double)(chan->loopstart << shift); +#endif } else { @@ -855,9 +862,12 @@ static FORCEINLINE void TestForLoop2(SPU_struct *SPU, channel_struct *chan) // Do we loop? Or are we done? if (chan->repeat == 1) { +#if defined(WIN32) && defined(G_NEW_SPU_TIMING) while (chan->sampcnt > chan->double_totlength_shifted) chan->sampcnt -= chan->double_totlength_shifted - (double)(chan->loopstart << 3); - //chan->sampcnt = (double)(chan->loopstart << 3); +#else + chan->sampcnt = (double)(chan->loopstart << 3); +#endif chan->pcm16b = (s16)((chan->buf8[1] << 8) | chan->buf8[0]); chan->index = chan->buf8[2] & 0x7F; chan->lastsampcnt = 7; @@ -956,6 +966,7 @@ FORCEINLINE static void _SPU_ChanUpdate(const bool actuallyMix, SPU_struct* cons template static void SPU_MixAudio(SPU_struct *SPU, int length) { + int i; u8 vol; if(actuallyMix) @@ -974,7 +985,7 @@ static void SPU_MixAudio(SPU_struct *SPU, int length) vol = T1ReadByte(MMU.ARM7_REG, 0x500) & 0x7F; - for(int i=0;i<16;i++) + for(i=0;i<16;i++) { channel_struct *chan = &SPU->channels[i]; @@ -985,12 +996,12 @@ static void SPU_MixAudio(SPU_struct *SPU, int length) SPU->buflength = length; // Mix audio - _SPU_ChanUpdate(!CommonSettings.spu_muteChannels[i] && actuallyMix, SPU, chan); + _SPU_ChanUpdate(actuallyMix, SPU, chan); } // convert from 32-bit->16-bit if(actuallyMix) - for (int i = 0; i < length*2; i++) + for (i = 0; i < length*2; i++) { // Apply Master Volume SPU->sndbuf[i] = spumuldiv7(SPU->sndbuf[i], vol); @@ -1011,7 +1022,11 @@ static void SPU_MixAudio(SPU_struct *SPU, int length) //this will produce a variable number of samples, calculated to keep a 44100hz output //in sync with the emulator framerate static double samples = 0; +#if defined(WIN32) && defined(G_NEW_SPU_TIMING) static const double time_per_frame = (double)1.0/((double)ARM7_CLOCK/6/355); //(double)1.0/(double)59.8261; // ((double)ARM7_CLOCK/6/355/263) +#else +static const double time_per_frame = (double)1.0/(double)59.8261; // ((double)ARM7_CLOCK/6/355/263) +#endif static const double samples_per_frame = time_per_frame * 44100; int spu_core_samples = 0; void SPU_Emulate_core() @@ -1114,6 +1129,30 @@ void SNDDummySetVolume(int volume) { } +////////////////////////////////////////////////////////////////////////////// +// WAV Write Interface +////////////////////////////////////////////////////////////////////////////// + +int SNDFileInit(int buffersize); +void SNDFileDeInit(); +void SNDFileUpdateAudio(s16 *buffer, u32 num_samples); +u32 SNDFileGetAudioSpace(); +void SNDFileMuteAudio(); +void SNDFileUnMuteAudio(); +void SNDFileSetVolume(int volume); + +SoundInterface_struct SNDFile = { + SNDCORE_FILEWRITE, + "WAV Write Sound Interface", + SNDFileInit, + SNDFileDeInit, + SNDFileUpdateAudio, + SNDFileGetAudioSpace, + SNDFileMuteAudio, + SNDFileUnMuteAudio, + SNDFileSetVolume +}; + ////////////////////////////////////////////////////////////////////////////// typedef struct { @@ -1136,19 +1175,17 @@ typedef struct { u16 bitspersample; } fmt_struct; -WavWriter::WavWriter() -: spufp(NULL) -{ -} -bool WavWriter::open(const std::string & fname) +////////////////////////////////////////////////////////////////////////////// + +int SNDFileInit(int buffersize) { waveheader_struct waveheader; fmt_struct fmt; chunk_struct data; size_t elems_written = 0; - if ((spufp = fopen(fname.c_str(), "wb")) == NULL) - return false; + if ((spufp = fopen("ndsaudio.wav", "wb")) == NULL) + return -1; // Do wave header memcpy(waveheader.riff.id, "RIFF", 4); @@ -1172,71 +1209,66 @@ bool WavWriter::open(const std::string & fname) data.size = 0; // we'll fix this at the end elems_written += fwrite((void *)&data, 1, sizeof(chunk_struct), spufp); - return true; + return 0; } -void WavWriter::close() +////////////////////////////////////////////////////////////////////////////// + +void SNDFileDeInit() { - if(!spufp) return; size_t elems_written = 0; - long length = ftell(spufp); + if (spufp) + { + long length = ftell(spufp); - // Let's fix the riff chunk size and the data chunk size - fseek(spufp, sizeof(waveheader_struct)-0x8, SEEK_SET); - length -= 0x8; - elems_written += fwrite((void *)&length, 1, 4, spufp); + // Let's fix the riff chunk size and the data chunk size + fseek(spufp, sizeof(waveheader_struct)-0x8, SEEK_SET); + length -= 0x8; + elems_written += fwrite((void *)&length, 1, 4, spufp); - fseek(spufp, sizeof(waveheader_struct)+sizeof(fmt_struct)+0x4, SEEK_SET); - length -= sizeof(waveheader_struct)+sizeof(fmt_struct); - elems_written += fwrite((void *)&length, 1, 4, spufp); - fclose(spufp); - spufp = NULL; + fseek(spufp, sizeof(waveheader_struct)+sizeof(fmt_struct)+0x4, SEEK_SET); + length -= sizeof(waveheader_struct)+sizeof(fmt_struct); + elems_written += fwrite((void *)&length, 1, 4, spufp); + fclose(spufp); + } } -void WavWriter::update(void* soundData, int numSamples) +////////////////////////////////////////////////////////////////////////////// + +void SNDFileUpdateAudio(s16 *buffer, u32 num_samples) { - if(!spufp) return; - //TODO - big endian for the s16 samples?? - size_t elems_written = fwrite(soundData, numSamples*2, 2, spufp); + size_t elems_written; + if (spufp) { + elems_written = fwrite((void *)buffer, num_samples*2, 2, spufp); + //INFO("%i written\n", elems_written); + } } -bool WavWriter::isRecording() const +////////////////////////////////////////////////////////////////////////////// + +u32 SNDFileGetAudioSpace() { - return spufp != NULL; + return 740; } +////////////////////////////////////////////////////////////////////////////// -static WavWriter wavWriter; - -void WAV_End() +void SNDFileMuteAudio() { - wavWriter.close(); } -bool WAV_Begin(const char* fname) +////////////////////////////////////////////////////////////////////////////// + +void SNDFileUnMuteAudio() { - WAV_End(); - - if(!wavWriter.open(fname)) - return false; - - driver->USR_InfoMessage("WAV recording started."); - - return true; } -bool WAV_IsRecording() +////////////////////////////////////////////////////////////////////////////// + +void SNDFileSetVolume(int volume) { - return wavWriter.isRecording(); } -void WAV_WavSoundUpdate(void* soundData, int numSamples) -{ - wavWriter.update(soundData, numSamples); -} - - - ////////////////////////////////////////////////////////////////////////////// void spu_savestate(std::ostream* os) diff --git a/desmume/src/SPU.h b/src/SPU.h similarity index 87% rename from desmume/src/SPU.h rename to src/SPU.h index 493f62bfd..cc8c754f5 100644 --- a/desmume/src/SPU.h +++ b/src/SPU.h @@ -1,7 +1,4 @@ -/* SPU.h - - Copyright 2006 Theo Berkau - Copyright (C) 2006-2009 DeSmuME team +/* Copyright (C) 2006 Theo Berkau This file is part of DeSmuME @@ -17,7 +14,7 @@ You should have received a copy of the GNU General Public License along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ #ifndef SPU_H @@ -31,6 +28,7 @@ #define SNDCORE_DEFAULT -1 #define SNDCORE_DUMMY 0 +#define SNDCORE_FILEWRITE 1 #define CHANSTAT_STOPPED 0 #define CHANSTAT_PLAY 1 @@ -147,22 +145,4 @@ extern int spu_core_samples; void spu_savestate(std::ostream* os); bool spu_loadstate(std::istream* is, int size); -class WavWriter -{ -public: - WavWriter(); - bool open(const std::string & fname); - void close(); - void update(void* soundData, int numSamples); - bool isRecording() const; -private: - FILE *spufp; -}; - - -void WAV_End(); -bool WAV_Begin(const char* fname); -bool WAV_IsRecording(); -void WAV_WavSoundUpdate(void* soundData, int numSamples); - #endif diff --git a/desmume/src/addons.cpp b/src/addons.cpp similarity index 84% rename from desmume/src/addons.cpp rename to src/addons.cpp index 41100a168..bbb2a1991 100644 --- a/desmume/src/addons.cpp +++ b/src/addons.cpp @@ -1,81 +1,72 @@ -/* Copyright (C) 2006 yopyop - yopyop156@ifrance.com - yopyop156.ifrance.com - - Copyright (C) 2009 CrazyMax - Copyright (C) 2009 DeSmuME team - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -*/ - -#include "addons.h" -#include - -std::string CFlash_Path; -ADDON_CFLASH_MODE CFlash_Mode; - - -//char CFlashName[MAX_PATH]; -//char CFlashPath[MAX_PATH]; -//u8 CFlashUseRomPath = TRUE; -//u8 CFlashUsePath = TRUE; - -char GBAgameName[MAX_PATH]; - -extern ADDONINTERFACE addonNone; -extern ADDONINTERFACE addonCFlash; -extern ADDONINTERFACE addonRumblePak; -extern ADDONINTERFACE addonGBAgame; -extern ADDONINTERFACE addonGuitarGrip; -//extern ADDONINTERFACE addonExternalMic; - -ADDONINTERFACE addonList[NDS_ADDON_COUNT] = { - addonNone, - addonCFlash, - addonRumblePak, - addonGBAgame, - addonGuitarGrip -}; - -ADDONINTERFACE addon = addonCFlash; // default none pak -u8 addon_type = NDS_ADDON_CFLASH; - -BOOL addonsInit() -{ - return addon.init(); -} - -void addonsClose() -{ - addon.close(); -} - -void addonsReset() -{ - addon.reset(); -} - -BOOL addonsChangePak(u8 type) -{ - printf("addonsChangePak\n"); - if (type > NDS_ADDON_COUNT) return FALSE; - addon.close(); - addon = addonList[type]; - addon_type = type; - return addon.init(); -} - +/* Copyright (C) 2006 yopyop + yopyop156@ifrance.com + yopyop156.ifrance.com + + Copyright (C) 2009 CrazyMax + Copyright (C) 2009 DeSmuME team + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA +*/ + +#include "addons.h" + +char CFlashName[MAX_PATH]; +char CFlashPath[MAX_PATH]; +u8 CFlashUseRomPath = TRUE; +u8 CFlashUsePath = TRUE; + +char GBAgameName[MAX_PATH]; + +extern ADDONINTERFACE addonNone; +extern ADDONINTERFACE addonCFlash; +extern ADDONINTERFACE addonRumblePak; +extern ADDONINTERFACE addonGBAgame; +//extern ADDONINTERFACE addonExternalMic; + +ADDONINTERFACE addonList[NDS_ADDON_COUNT] = { + addonNone, + addonCFlash, + addonRumblePak, + addonGBAgame}; + +ADDONINTERFACE addon = addonCFlash; // default none pak +u8 addon_type = NDS_ADDON_CFLASH; + +BOOL addonsInit() +{ + return addon.init(); +} + +void addonsClose() +{ + addon.close(); +} + +void addonsReset() +{ + addon.reset(); +} + +BOOL addonsChangePak(u8 type) +{ + if (type > NDS_ADDON_COUNT) return FALSE; + addon.close(); + addon = addonList[type]; + addon_type = type; + return addon.init(); +} + diff --git a/desmume/src/addons.h b/src/addons.h similarity index 85% rename from desmume/src/addons.h rename to src/addons.h index 4b6a7b2ff..dbec198b9 100644 --- a/desmume/src/addons.h +++ b/src/addons.h @@ -1,96 +1,88 @@ -/* Copyright (C) 2006 yopyop - yopyop156@ifrance.com - yopyop156.ifrance.com - - Copyright (C) 2009 CrazyMax - Copyright (C) 2009 DeSmuME team - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -*/ - -#ifndef __ADDONS_H__ -#define __ADDONS_H__ - -#include "common.h" -#include "types.h" -#include "debug.h" - -typedef struct -{ - // The name of the plugin, this name will appear in the plugins list - const char * name; - - //called once when the plugin starts up - BOOL (*init)(void); - - //called when the emulator resets - void (*reset)(void); - - //called when the plugin shuts down - void (*close)(void); - - //called when the user configurating plugin - void (*config)(void); - - //called when the emulator write to addon - void (*write08)(u32 adr, u8 val); - void (*write16)(u32 adr, u16 val); - void (*write32)(u32 adr, u32 val); - - //called when the emulator read from addon - u8 (*read08)(u32 adr); - u16 (*read16)(u32 adr); - u32 (*read32)(u32 adr); - - //called when the user get info about addon pak (description) - void (*info)(char *info); -} ADDONINTERFACE; - -enum { - NDS_ADDON_NONE, - NDS_ADDON_CFLASH, // compact flash - NDS_ADDON_RUMBLEPAK, // rumble pack - NDS_ADDON_GBAGAME, // gba game in slot - NDS_ADDON_GUITARGRIP, // Guitar Grip - //NDS_ADDON_EXTERNALMIC, - NDS_ADDON_COUNT // use for counter addons - MUST TO BE LAST!!! -}; - -enum ADDON_CFLASH_MODE -{ - ADDON_CFLASH_MODE_Path, ADDON_CFLASH_MODE_File, ADDON_CFLASH_MODE_RomPath -}; - -extern ADDON_CFLASH_MODE CFlash_Mode; -extern std::string CFlash_Path; -inline bool CFlash_IsUsingPath() { return CFlash_Mode==ADDON_CFLASH_MODE_Path || CFlash_Mode==ADDON_CFLASH_MODE_RomPath; } - -extern ADDONINTERFACE addon; // current pak -extern ADDONINTERFACE addonList[NDS_ADDON_COUNT]; // lists pointer on paks -extern u8 addon_type; // current type pak - -extern char GBAgameName[MAX_PATH]; // file name for GBA game (rom) -extern void (*FeedbackON)(BOOL enable); // feedback on/off - -extern BOOL addonsInit(); // Init addons -extern void addonsClose(); // Shutdown addons -extern void addonsReset(); // Reset addon -extern BOOL addonsChangePak(u8 type); // change current adddon - -extern void guitarGrip_setKey(bool green, bool red, bool yellow, bool blue); // Guitar grip keys - -#endif +/* Copyright (C) 2006 yopyop + yopyop156@ifrance.com + yopyop156.ifrance.com + + Copyright (C) 2009 CrazyMax + Copyright (C) 2009 DeSmuME team + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA +*/ + +#ifndef __ADDONS_H__ +#define __ADDONS_H__ + +#include "common.h" +#include "types.h" +#include "debug.h" + +typedef struct +{ + // The name of the plugin, this name will appear in the plugins list + const char * name; + + //called once when the plugin starts up + BOOL (*init)(void); + + //called when the emulator resets + void (*reset)(void); + + //called when the plugin shuts down + void (*close)(void); + + //called when the user configurating plugin + void (*config)(void); + + //called when the emulator write to addon + void (*write08)(u32 adr, u8 val); + void (*write16)(u32 adr, u16 val); + void (*write32)(u32 adr, u32 val); + + //called when the emulator read from addon + u8 (*read08)(u32 adr); + u16 (*read16)(u32 adr); + u32 (*read32)(u32 adr); + + //called when the user get info about addon pak (description) + void (*info)(char *info); +} ADDONINTERFACE; + +enum { + NDS_ADDON_NONE, + NDS_ADDON_CFLASH, // compact flash + NDS_ADDON_RUMBLEPAK, // rumble pack + NDS_ADDON_GBAGAME, // gba game in slot + //NDS_ADDON_EXTERNALMIC, + NDS_ADDON_COUNT // use for counter addons - MUST TO BE LAST!!! +}; + +extern ADDONINTERFACE addon; // current pak +extern ADDONINTERFACE addonList[NDS_ADDON_COUNT]; // lists pointer on paks +extern u8 addon_type; // current type pak + +extern char CFlashName[MAX_PATH]; // path to compact flash img file +extern char CFlashPath[MAX_PATH]; // path to compact flash directory +extern u8 CFlashUsePath; // true is used path from CFlashPath for cflash folder +extern u8 CFlashUseRomPath; // true is used path to rom file for cflash folder +extern char GBAgameName[MAX_PATH]; // file name for GBA game (rom) +extern void (*FeedbackON)(BOOL enable); // feedback on/off + +extern BOOL addonsInit(); // Init addons +extern void addonsClose(); // Shutdown addons +extern void addonsReset(); // Reset addon +extern BOOL addonsChangePak(u8 type); // change current adddon + +#endif diff --git a/desmume/src/addons/compactFlash.cpp b/src/addons/compactFlash.cpp similarity index 93% rename from desmume/src/addons/compactFlash.cpp rename to src/addons/compactFlash.cpp index 37f0341ed..094f8a170 100644 --- a/desmume/src/addons/compactFlash.cpp +++ b/src/addons/compactFlash.cpp @@ -24,8 +24,9 @@ */ #include "../addons.h" -#include #include +#ifdef EXPERIMENTAL_GBASLOT + #include "debug.h" #include #include @@ -58,7 +59,6 @@ #include "../fs.h" #include "MMU.h" #include "NDSSystem.h" -#include "../path.h" typedef struct { int level,parent,filesInDir; @@ -102,7 +102,7 @@ static const int lfnPos[13] = {1,3,5,7,9,14,16,18,20,22,24,28,30}; #define BYTESPERCLUS (512*SECPERCLUS) #define DIRENTSPERCLUS ((BYTESPERCLUS)/32) -BOOT_RECORD MBR; +static BOOT_RECORD MBR; static DIR_ENT *files,*dirEntries,**dirEntryPtr; static FILE_INFO *fileLink,*dirEntryLink; static u32 filesysFAT,filesysRootDir,filesysData; @@ -112,6 +112,7 @@ static DIR_ENT *extraDirEntries[SECPERFAT*256]; static int numFiles,maxLevel,numRootFiles; static int *dirEntriesInCluster, clusterNum, firstDirEntCluster, lastDirEntCluster, lastFileDataCluster; +static char *sRomPath; static int activeDirEnt=-1; static u32 bufferStart; static u32 fileStartLBA,fileEndLBA; @@ -120,8 +121,6 @@ static FILE * hFile; static char fpath[255+1]; static BOOL cflashDeviceEnabled = FALSE; -static std::string sFlashPath; - // =========================== BOOL inited; @@ -274,7 +273,6 @@ static void list_files(const char *filepath) { fname = (strlen(entry.cAlternateFileName)>0) ? entry.cAlternateFileName : entry.cFileName; add_file(fname, &entry, fileLevel); - CFLASHLOG("cflash added %s\n",fname); if (numFiles==MAXFILES-1) break; @@ -283,7 +281,7 @@ static void list_files(const char *filepath) if (strlen(fname)+strlen(filepath)+2 < 256) { sprintf(SubDir, "%s%c%s", filepath, FS_SEPARATOR, fname); - list_files(SubDir); + list_files(SubDir); } } } @@ -300,7 +298,7 @@ static void list_files(const char *filepath) } // Set up the MBR, FAT and DIR_ENTs -static BOOL cflash_build_fat() +static BOOL cflash_build_fat( void) { int i,j,k,l, clust,numClusters, @@ -311,6 +309,12 @@ static BOOL cflash_build_fat() fileLevel = -1; maxLevel = -1; + if (CFlashUseRomPath) + sRomPath = pathToROM; + else + sRomPath = CFlashPath; + + files = (DIR_ENT *) malloc(MAXFILES*sizeof(DIR_ENT)); if (files == NULL) return FALSE; fileLink = (FILE_INFO *) malloc(MAXFILES*sizeof(FILE_INFO)); @@ -332,7 +336,8 @@ static BOOL cflash_build_fat() numExtraEntries[i] = 0; } - list_files(sFlashPath.c_str()); + //COMMENT OUT THIS LINE TO STOP THE IRRITATING FILESYSTEM SCANNING BEHAVIOR + list_files(sRomPath); k = 0; clusterNum = rootCluster = (SECRESV + SECPERFAT)/SECPERCLUS; @@ -507,21 +512,11 @@ static BOOL cflash_init() if (inited) return FALSE; BOOL init_good = FALSE; - CFLASHLOG("CFlash_Mode: %d\n",CFlash_Mode); - - if (CFlash_Mode == ADDON_CFLASH_MODE_RomPath) - { - sFlashPath = path.pathToRoms; - INFO("Using CFlash directory of rom: %s\n", sFlashPath.c_str()); - } - else if(CFlash_Mode == ADDON_CFLASH_MODE_Path) - { - sFlashPath = CFlash_Path; - INFO("Using CFlash directory: %s\n", sFlashPath.c_str()); - } - - if(CFlash_IsUsingPath()) + if (CFlashUsePath) { + if (!strlen(CFlashPath)) CFlashUseRomPath = TRUE; + if (CFlashUseRomPath) + CFLASHLOG("Using CFlash directory of rom: %s\n", pathToROM); cflashDeviceEnabled = FALSE; currLBA = 0; @@ -529,10 +524,8 @@ static BOOL cflash_init() fclose(hFile); activeDirEnt = -1; fileStartLBA = fileEndLBA = 0xFFFFFFFF; - if (!cflash_build_fat()) { - CFLASHLOG("FAILED cflash_build_fat\n"); + if (!cflash_build_fat()) return FALSE; - } cf_reg_sts = 0x58; // READY cflashDeviceEnabled = TRUE; @@ -540,9 +533,9 @@ static BOOL cflash_init() } else { - sFlashPath = CFlash_Path; - INFO("Using CFlash disk image file %s\n", sFlashPath.c_str()); - disk_image = OPEN_FN( sFlashPath.c_str(), OPEN_MODE); + if (!strlen(CFlashName)) return FALSE; + CFLASHLOG("Using CFlash disk image file %s\n", CFlashName); + disk_image = OPEN_FN( CFlashName, OPEN_MODE); if ( disk_image != -1) { @@ -560,7 +553,7 @@ static BOOL cflash_init() } else // TODO: create image if not exist - CFLASHLOG("Failed to open file %s: \"%s\"\n", sFlashPath.c_str(), strerror( errno)); + CFLASHLOG("Failed to open file %s: \"%s\"\n", CFlashName, strerror( errno)); } // READY @@ -652,7 +645,7 @@ static u16 fread_buffered(int dirent,u32 cluster,u32 offset) if (activeDirEnt != -1) fclose(hFile); - strncpy(fpath,sFlashPath.c_str(),ARRAY_SIZE(fpath)); + strncpy(fpath,sRomPath,ARRAY_SIZE(fpath)); strncat(fpath,DIR_SEP,ARRAY_SIZE(fpath)-strlen(fpath)); resolve_path(dirent); @@ -660,7 +653,6 @@ static u16 fread_buffered(int dirent,u32 cluster,u32 offset) fatstring_to_asciiz(dirent,fname,NULL); strncat(fpath,fname,ARRAY_SIZE(fpath)-strlen(fpath)); - CFLASHLOG("CFLASH Opening %s\n",fpath); hFile = fopen(fpath, "rb"); if (!hFile) return 0; bufferStart = offset; @@ -694,7 +686,7 @@ static unsigned int cflash_read(unsigned int address) case CF_REG_DATA: if (cf_reg_cmd == CF_CMD_READ) { - if (!CFlash_IsUsingPath()) + if (!CFlashUsePath) { if ( disk_image != -1) { @@ -840,7 +832,7 @@ static void cflash_write(unsigned int address,unsigned int data) case CF_REG_DATA: if (cf_reg_cmd == CF_CMD_WRITE) { - if (!CFlash_IsUsingPath()) + if (!CFlashUsePath) { sector_data[sector_write_index] = (data >> 0) & 0xff; sector_data[sector_write_index + 1] = (data >> 8) & 0xff; @@ -916,11 +908,11 @@ static void cflash_write(unsigned int address,unsigned int data) static void cflash_close( void) { if (!inited) return; - if (!CFlash_IsUsingPath()) + if (!CFlashUsePath) { - if (disk_image != -1) + if ( disk_image != -1) { - CLOSE_FN(disk_image); + CLOSE_FN( disk_image); disk_image = -1; } } @@ -955,6 +947,8 @@ static void cflash_close( void) static BOOL CFlash_init(void) { + CFlashUseRomPath = TRUE; + CFlashUsePath = TRUE; return TRUE; } @@ -1007,6 +1001,23 @@ static void CFlash_info(char *info) { strcpy(info, "Compact Flash memory in slot"); } +#else +static BOOL CFlash_init(void) { return TRUE; } +static void CFlash_reset(void) {} +static void CFlash_close(void) {} +static void CFlash_config(void){} +static void CFlash_write08(u32 adr, u8 val){} +static void CFlash_write16(u32 adr, u16 val){} +static void CFlash_write32(u32 adr, u32 val){} +static u8 CFlash_read08(u32 adr){return (0);} +static u16 CFlash_read16(u32 adr){return (0);} +static u32 CFlash_read32(u32 adr){return (0);} + +static void CFlash_info(char *info) +{ + strcpy(info, "Compact Flash memory in slot"); +} +#endif ADDONINTERFACE addonCFlash = { "Compact Flash", diff --git a/desmume/src/addons/gbagame.cpp b/src/addons/gbagame.cpp similarity index 96% rename from desmume/src/addons/gbagame.cpp rename to src/addons/gbagame.cpp index 1cec71e58..aed91db0c 100644 --- a/desmume/src/addons/gbagame.cpp +++ b/src/addons/gbagame.cpp @@ -1,133 +1,133 @@ -/* Copyright (C) 2006 yopyop - yopyop156@ifrance.com - yopyop156.ifrance.com - - Copyright (C) 2009 CrazyMax - Copyright (C) 2009 DeSmuME team - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -*/ - -#include "../addons.h" -#include "../mem.h" -#include -#include "../MMU.h" - -//SRAM is going to be stored just above the rom. -//that is convenient for us, since it mirrors the nds memory map - -static u8 *GBArom = NULL; - -#define GBA_ROMSIZE (32 * 1024 * 1024) -#define GBA_RAMSIZE (64 * 1024) -#define GBA_SIZE (GBA_ROMSIZE+GBA_RAMSIZE) - -static BOOL GBAgame_init(void) -{ - GBArom = new u8 [GBA_SIZE]; - return (TRUE); -} - -static void GBAgame_reset(void) -{ - memset(GBArom, 0, GBA_SIZE); - - if (!strlen(GBAgameName)) return; - FILE *fgame = 0; - - fgame = fopen(GBAgameName,"rb"); - if (!fgame) return; - INFO("Loaded \"%s\" in GBA slot\n", GBAgameName); - fseek(fgame, 0, SEEK_END); - u32 size = ftell(fgame); - rewind(fgame); - - if (!fread(GBArom, 1, size, fgame)) - { - fclose(fgame); - return; - } - - fclose(fgame); - - //try loading the sram - char * dot = strrchr(GBAgameName,'.'); - if(!dot) return; - std::string sram_fname = GBAgameName; - sram_fname.resize(dot-GBAgameName); - sram_fname += ".sav"; - fgame = fopen(sram_fname.c_str(),"rb"); - if(fgame) - { - fread(GBArom+GBA_ROMSIZE,1,GBA_RAMSIZE,fgame); - fclose(fgame); - } -} - -static void GBAgame_close(void) -{ - delete[] GBArom; - GBArom = NULL; -} - -static void GBAgame_config(void) {} -static void GBAgame_write08(u32 adr, u8 val){} -static void GBAgame_write16(u32 adr, u16 val) {} -static void GBAgame_write32(u32 adr, u32 val) {} - -static u8 GBAgame_read08(u32 adr) -{ - //INFO("Read08 at 0x%08X value 0x%02X\n", adr, (u8)T1ReadByte(GBArom, (adr - 0x08000000))); - if ( (adr >= 0x08000004) && (adr < 0x080000A0) ) - return MMU.MMU_MEM[0][0xFF][(adr +0x1C) & MMU.MMU_MASK[0][0xFF]]; - return (u8)T1ReadByte(GBArom, (adr - 0x08000000)); -} - -static u16 GBAgame_read16(u32 adr) -{ - //INFO("Read16 at 0x%08X value 0x%04X\n", adr, (u16)T1ReadWord(GBArom, (adr - 0x08000000))); - if ( (adr >= 0x08000004) && (adr < 0x080000A0) ) - return T1ReadWord(MMU.MMU_MEM[0][0xFF], (adr +0x1C) & MMU.MMU_MASK[0][0xFF]); - return (u16)T1ReadWord(GBArom, (adr - 0x08000000)); -} - -static u32 GBAgame_read32(u32 adr) -{ - //INFO("Read32 at 0x%08X value 0x%08X\n", adr, (u32)T1ReadLong(GBArom, (adr - 0x08000000))); - if ( (adr >= 0x08000004) && (adr < 0x080000A0) ) - return T1ReadLong(MMU.MMU_MEM[0][0xFF], (adr +0x1C) & MMU.MMU_MASK[0][0xFF]); - return (u32)T1ReadLong(GBArom, (adr - 0x08000000)); -} - -static void GBAgame_info(char *info) -{ - strcpy(info, "GBA game in slot"); -} - -ADDONINTERFACE addonGBAgame = { - "GBA game", - GBAgame_init, - GBAgame_reset, - GBAgame_close, - GBAgame_config, - GBAgame_write08, - GBAgame_write16, - GBAgame_write32, - GBAgame_read08, - GBAgame_read16, - GBAgame_read32, - GBAgame_info}; +/* Copyright (C) 2006 yopyop + yopyop156@ifrance.com + yopyop156.ifrance.com + + Copyright (C) 2009 CrazyMax + Copyright (C) 2009 DeSmuME team + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA +*/ + +#include "../addons.h" +#include "../mem.h" +#include +#include "../MMU.h" + +//SRAM is going to be stored just above the rom. +//that is convenient for us, since it mirrors the nds memory map + +static u8 *GBArom = NULL; + +#define GBA_ROMSIZE (32 * 1024 * 1024) +#define GBA_RAMSIZE (64 * 1024) +#define GBA_SIZE (GBA_ROMSIZE+GBA_RAMSIZE) + +static BOOL GBAgame_init(void) +{ + GBArom = new u8 [GBA_SIZE]; + return (TRUE); +} + +static void GBAgame_reset(void) +{ + memset(GBArom, 0, GBA_SIZE); + + if (!strlen(GBAgameName)) return; + FILE *fgame = 0; + + fgame = fopen(GBAgameName,"rb"); + if (!fgame) return; + INFO("Loaded \"%s\" in GBA slot\n", GBAgameName); + fseek(fgame, 0, SEEK_END); + u32 size = ftell(fgame); + rewind(fgame); + + if (!fread(GBArom, 1, size, fgame)) + { + fclose(fgame); + return; + } + + fclose(fgame); + + //try loading the sram + char * dot = strrchr(GBAgameName,'.'); + if(!dot) return; + std::string sram_fname = GBAgameName; + sram_fname.resize(dot-GBAgameName); + sram_fname += ".sav"; + fgame = fopen(sram_fname.c_str(),"rb"); + if(fgame) + { + fread(GBArom+GBA_ROMSIZE,1,GBA_RAMSIZE,fgame); + fclose(fgame); + } +} + +static void GBAgame_close(void) +{ + delete[] GBArom; + GBArom = NULL; +} + +static void GBAgame_config(void) {} +static void GBAgame_write08(u32 adr, u8 val){} +static void GBAgame_write16(u32 adr, u16 val) {} +static void GBAgame_write32(u32 adr, u32 val) {} + +static u8 GBAgame_read08(u32 adr) +{ + //INFO("Read08 at 0x%08X value 0x%02X\n", adr, (u8)T1ReadByte(GBArom, (adr - 0x08000000))); + if ( (adr >= 0x08000004) && (adr < 0x080000A0) ) + return MMU.MMU_MEM[0][0xFF][(adr +0x1C) & MMU.MMU_MASK[0][0xFF]]; + return (u8)T1ReadByte(GBArom, (adr - 0x08000000)); +} + +static u16 GBAgame_read16(u32 adr) +{ + //INFO("Read16 at 0x%08X value 0x%04X\n", adr, (u16)T1ReadWord(GBArom, (adr - 0x08000000))); + if ( (adr >= 0x08000004) && (adr < 0x080000A0) ) + return T1ReadWord(MMU.MMU_MEM[0][0xFF], (adr +0x1C) & MMU.MMU_MASK[0][0xFF]); + return (u16)T1ReadWord(GBArom, (adr - 0x08000000)); +} + +static u32 GBAgame_read32(u32 adr) +{ + //INFO("Read32 at 0x%08X value 0x%08X\n", adr, (u32)T1ReadLong(GBArom, (adr - 0x08000000))); + if ( (adr >= 0x08000004) && (adr < 0x080000A0) ) + return T1ReadLong(MMU.MMU_MEM[0][0xFF], (adr +0x1C) & MMU.MMU_MASK[0][0xFF]); + return (u32)T1ReadLong(GBArom, (adr - 0x08000000)); +} + +static void GBAgame_info(char *info) +{ + strcpy(info, "GBA game in slot"); +} + +ADDONINTERFACE addonGBAgame = { + "GBA game", + GBAgame_init, + GBAgame_reset, + GBAgame_close, + GBAgame_config, + GBAgame_write08, + GBAgame_write16, + GBAgame_write32, + GBAgame_read08, + GBAgame_read16, + GBAgame_read32, + GBAgame_info}; diff --git a/desmume/src/addons/none.cpp b/src/addons/none.cpp similarity index 96% rename from desmume/src/addons/none.cpp rename to src/addons/none.cpp index 1393fbe7e..b2f320762 100644 --- a/desmume/src/addons/none.cpp +++ b/src/addons/none.cpp @@ -1,52 +1,52 @@ -/* Copyright (C) 2006 yopyop - yopyop156@ifrance.com - yopyop156.ifrance.com - - Copyright (C) 2009 CrazyMax - Copyright (C) 2009 DeSmuME team - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -*/ - -#include "../addons.h" -#include - -static BOOL None_init(void) { return (TRUE); } -static void None_reset(void) {} -static void None_close(void) {} -static void None_config(void) {} -static void None_write08(u32 adr, u8 val) {} -static void None_write16(u32 adr, u16 val) {} -static void None_write32(u32 adr, u32 val) {} -static u8 None_read08(u32 adr){ return (0); } -static u16 None_read16(u32 adr){ return (0); } -static u32 None_read32(u32 adr){ return (0); } -static void None_info(char *info) { strcpy(info, "Nothing in GBA slot"); } - -ADDONINTERFACE addonNone = { - "NONE", - None_init, - None_reset, - None_close, - None_config, - None_write08, - None_write16, - None_write32, - None_read08, - None_read16, - None_read32, - None_info}; +/* Copyright (C) 2006 yopyop + yopyop156@ifrance.com + yopyop156.ifrance.com + + Copyright (C) 2009 CrazyMax + Copyright (C) 2009 DeSmuME team + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA +*/ + +#include "../addons.h" +#include + +static BOOL None_init(void) { return (TRUE); } +static void None_reset(void) {} +static void None_close(void) {} +static void None_config(void) {} +static void None_write08(u32 adr, u8 val) {} +static void None_write16(u32 adr, u16 val) {} +static void None_write32(u32 adr, u32 val) {} +static u8 None_read08(u32 adr){ return (0); } +static u16 None_read16(u32 adr){ return (0); } +static u32 None_read32(u32 adr){ return (0); } +static void None_info(char *info) { strcpy(info, "Nothing in GBA slot"); } + +ADDONINTERFACE addonNone = { + "NONE", + None_init, + None_reset, + None_close, + None_config, + None_write08, + None_write16, + None_write32, + None_read08, + None_read16, + None_read32, + None_info}; diff --git a/desmume/src/addons/rumblepak.cpp b/src/addons/rumblepak.cpp similarity index 95% rename from desmume/src/addons/rumblepak.cpp rename to src/addons/rumblepak.cpp index 6c31fb19c..7a0654ed4 100644 --- a/desmume/src/addons/rumblepak.cpp +++ b/src/addons/rumblepak.cpp @@ -1,97 +1,97 @@ -/* Copyright (C) 2006 yopyop - yopyop156@ifrance.com - yopyop156.ifrance.com - - Copyright (C) 2009 CrazyMax - Copyright (C) 2009 DeSmuME team - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -*/ - -#include "../addons.h" -#include "../mem.h" -#include "../MMU.h" -#include - -void (*FeedbackON)(BOOL enable) = NULL; - -static BOOL RumblePak_init(void) { return (TRUE); } - -static void RumblePak_reset(void) -{ -} - -static void RumblePak_close(void) {} - -static void RumblePak_config(void) {} - -static void RumblePak_write08(u32 adr, u8 val) -{ -} - -static void RumblePak_write16(u32 adr, u16 val) -{ - if (!FeedbackON) return; - - // CrazyMax 17/01/2009 - // i don't know how send to feedback (PC) impulse with small latency. - if (adr == 0x08000000) - FeedbackON(val); - if (adr == 0x08001000) - FeedbackON(val); -} - -static void RumblePak_write32(u32 adr, u32 val) -{ -} - -static u8 RumblePak_read08(u32 adr) -{ - return (0); -} - -static u16 RumblePak_read16(u32 adr) -{ - u16 val = ( (adr & 0x1FFFF) >> 1 ) & 0xFFFD; - if (adr == 0x0801FFFE) val = 0x005D; // hack!!! anybody have docs for RumblePak? - - return ((u16)val); -} - -static u32 RumblePak_read32(u32 adr) -{ - return (0); -} - -static void RumblePak_info(char *info) -{ - strcpy(info, "NDS Rumble Pak (need joystick with Feedback)"); -} - -ADDONINTERFACE addonRumblePak = { - "Rumble Pak", - RumblePak_init, - RumblePak_reset, - RumblePak_close, - RumblePak_config, - RumblePak_write08, - RumblePak_write16, - RumblePak_write32, - RumblePak_read08, - RumblePak_read16, - RumblePak_read32, - RumblePak_info}; +/* Copyright (C) 2006 yopyop + yopyop156@ifrance.com + yopyop156.ifrance.com + + Copyright (C) 2009 CrazyMax + Copyright (C) 2009 DeSmuME team + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA +*/ + +#include "../addons.h" +#include "../mem.h" +#include "../MMU.h" +#include + +void (*FeedbackON)(BOOL enable) = NULL; + +static BOOL RumblePak_init(void) { return (TRUE); } + +static void RumblePak_reset(void) +{ +} + +static void RumblePak_close(void) {} + +static void RumblePak_config(void) {} + +static void RumblePak_write08(u32 adr, u8 val) +{ +} + +static void RumblePak_write16(u32 adr, u16 val) +{ + if (!FeedbackON) return; + + // CrazyMax 17/01/2009 + // i don't know how send to feedback (PC) impulse with small latency. + if (adr == 0x08000000) + FeedbackON(val); + if (adr == 0x08001000) + FeedbackON(val); +} + +static void RumblePak_write32(u32 adr, u32 val) +{ +} + +static u8 RumblePak_read08(u32 adr) +{ + return (0); +} + +static u16 RumblePak_read16(u32 adr) +{ + u16 val = ( (adr & 0x1FFFF) >> 1 ) & 0xFFFD; + if (adr == 0x0801FFFE) val = 0x005D; // hack!!! anybody have docs for RumblePak? + + return ((u16)val); +} + +static u32 RumblePak_read32(u32 adr) +{ + return (0); +} + +static void RumblePak_info(char *info) +{ + strcpy(info, "NDS Rumble Pak (need joystick with Feedback)"); +} + +ADDONINTERFACE addonRumblePak = { + "Rumble Pak", + RumblePak_init, + RumblePak_reset, + RumblePak_close, + RumblePak_config, + RumblePak_write08, + RumblePak_write16, + RumblePak_write32, + RumblePak_read08, + RumblePak_read16, + RumblePak_read32, + RumblePak_info}; diff --git a/desmume/src/arm_instructions.cpp b/src/arm_instructions.cpp similarity index 100% rename from desmume/src/arm_instructions.cpp rename to src/arm_instructions.cpp diff --git a/desmume/src/arm_instructions.h b/src/arm_instructions.h similarity index 97% rename from desmume/src/arm_instructions.h rename to src/arm_instructions.h index fab719263..cb8ef20a6 100644 --- a/desmume/src/arm_instructions.h +++ b/src/arm_instructions.h @@ -1,32 +1,32 @@ -/* Copyright (C) 2006 yopyop - yopyop156@ifrance.com - yopyop156.ifrance.com - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#ifndef ARMINSTRUCTION_H -#define ARMINSTRUCTION_H - -#include "types.h" -#include "armcpu.h" - -extern u32 (FASTCALL* arm_instructions_set_0[4096])(); -extern u32 (FASTCALL* arm_instructions_set_1[4096])(); - -#endif - +/* Copyright (C) 2006 yopyop + yopyop156@ifrance.com + yopyop156.ifrance.com + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#ifndef ARMINSTRUCTION_H +#define ARMINSTRUCTION_H + +#include "types.h" +#include "armcpu.h" + +extern u32 (FASTCALL* arm_instructions_set_0[4096])(); +extern u32 (FASTCALL* arm_instructions_set_1[4096])(); + +#endif + diff --git a/desmume/src/armcpu.cpp b/src/armcpu.cpp similarity index 97% rename from desmume/src/armcpu.cpp rename to src/armcpu.cpp index c2aeba1bb..59b70f98a 100644 --- a/desmume/src/armcpu.cpp +++ b/src/armcpu.cpp @@ -33,7 +33,7 @@ template static u32 armcpu_prefetch(); -FORCEINLINE u32 armcpu_prefetch(armcpu_t *armcpu) { +inline u32 armcpu_prefetch(armcpu_t *armcpu) { if(armcpu->proc_ID==0) return armcpu_prefetch<0>(); else return armcpu_prefetch<1>(); } @@ -318,7 +318,7 @@ u32 armcpu_switchMode(armcpu_t *armcpu, u8 mode) case FIQ : { - u32 tmp; + u32 tmp; SWAP(armcpu->R[8], armcpu->R8_fiq, tmp); SWAP(armcpu->R[9], armcpu->R9_fiq, tmp); SWAP(armcpu->R[10], armcpu->R10_fiq, tmp); @@ -363,7 +363,8 @@ u32 armcpu_switchMode(armcpu_t *armcpu, u8 mode) } template -FORCEINLINE static u32 armcpu_prefetch() +static u32 +armcpu_prefetch() { armcpu_t* const armcpu = &ARMPROC; #ifdef GDB_STUB @@ -520,10 +521,7 @@ u32 armcpu_exec() if(ARMPROC.CPSR.bits.T == 0) { - if( - CONDITION(ARMPROC.instruction) == 0x0E //fast path for unconditional instructions - || (TEST_COND(CONDITION(ARMPROC.instruction), CODE(ARMPROC.instruction), ARMPROC.CPSR)) //handles any condition - ) + if((TEST_COND(CONDITION(ARMPROC.instruction), CODE(ARMPROC.instruction), ARMPROC.CPSR))) { if(PROCNUM==0) { #ifdef WANTASMLISTING diff --git a/desmume/src/armcpu.h b/src/armcpu.h similarity index 95% rename from desmume/src/armcpu.h rename to src/armcpu.h index 8770c12aa..39390a8aa 100644 --- a/desmume/src/armcpu.h +++ b/src/armcpu.h @@ -1,282 +1,280 @@ -/* Copyright (C) 2006 yopyop - yopyop156@ifrance.com - yopyop156.ifrance.com - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#ifndef ARM_CPU -#define ARM_CPU - -#define ARMCPU_ARM7 1 -#define ARMCPU_ARM9 0 -#define ARMPROC (PROCNUM?NDS_ARM7:NDS_ARM9) - -#include "types.h" -#include "bits.h" -#include "MMU.h" - -#define CODE(i) (((i)>>25)&0x7) -#define OPCODE(i) (((i)>>21)&0xF) -#define SIGNEBIT(i) BIT_N(i,20) - -#define INSTRUCTION_INDEX(i) ((((i)>>16)&0xFF0)|(((i)>>4)&0xF)) - -inline u32 ROR(u32 i, u32 j) { return ((((u32)(i))>>(j)) | (((u32)(i))<<(32-(j)))); } - -template -inline T UNSIGNED_OVERFLOW(T a,T b,T c) { return ((BIT31(a)&BIT31(b)) | - ((BIT31(a)|BIT31(b))&BIT31(~c))); } - -template -inline T UNSIGNED_UNDERFLOW(T a,T b,T c) { return ((BIT31(~a)&BIT31(b)) | - ((BIT31(~a)|BIT31(b))&BIT31(c))); } - -template -inline T SIGNED_OVERFLOW(T a,T b,T c) { return ((BIT31(a)&BIT31(b)&BIT31(~c))| - (BIT31(~a)&BIT31(~(b))&BIT31(c))); } - -template -inline T SIGNED_UNDERFLOW(T a,T b,T c) { return ((BIT31(a)&BIT31(~(b))&BIT31(~c))| - (BIT31(~a)&BIT31(b)&BIT31(c))); } - -//zero 15-feb-2009 - these werent getting used and they were getting in my way -//#define EQ 0x0 -//#define NE 0x1 -//#define CS 0x2 -//#define CC 0x3 -//#define MI 0x4 -//#define PL 0x5 -//#define VS 0x6 -//#define VC 0x7 -//#define HI 0x8 -//#define LS 0x9 -//#define GE 0xA -//#define LT 0xB -//#define GT 0xC -//#define LE 0xD -//#define AL 0xE - -extern const unsigned char arm_cond_table[16*16]; - -#define TEST_COND(cond, inst, CPSR) ((arm_cond_table[((CPSR.val >> 24) & 0xf0)+(cond)] >> (inst)) & 1) - - -enum Mode -{ - USR = 0x10, - FIQ = 0x11, - IRQ = 0x12, - SVC = 0x13, - ABT = 0x17, - UND = 0x1B, - SYS = 0x1F -}; - -#ifdef WORDS_BIGENDIAN -typedef union -{ - struct - { - u32 N : 1, - Z : 1, - C : 1, - V : 1, - Q : 1, - RAZ : 19, - I : 1, - F : 1, - T : 1, - mode : 5; - } bits; - u32 val; -} Status_Reg; -#else -typedef union -{ - struct - { - u32 mode : 5, - T : 1, - F : 1, - I : 1, - RAZ : 19, - Q : 1, - V : 1, - C : 1, - Z : 1, - N : 1; - } bits; - u32 val; -} Status_Reg; -#endif - -/** - * The control interface to a CPU - */ -struct armcpu_ctrl_iface { - /** stall the processor */ - void (*stall)( void *instance); - - /** unstall the processor */ - void (*unstall)( void *instance); - - /** read a register value */ - u32 (*read_reg)( void *instance, u32 reg_num); - - /** set a register value */ - void (*set_reg)( void *instance, u32 reg_num, u32 value); - - /** install the post execute function */ - void (*install_post_ex_fn)( void *instance, - void (*fn)( void *, u32 adr, int thumb), - void *fn_data); - - /** remove the post execute function */ - void (*remove_post_ex_fn)( void *instance); - - /** the private data passed to all interface functions */ - void *data; -}; - - -typedef void* armcp_t; - -typedef struct armcpu_t -{ - u32 proc_ID; - u32 instruction; //4 - u32 instruct_adr; //8 - u32 next_instruction; //12 - - u32 R[16]; //16 - Status_Reg CPSR; //80 - Status_Reg SPSR; - - u32 R13_usr, R14_usr; - u32 R13_svc, R14_svc; - u32 R13_abt, R14_abt; - u32 R13_und, R14_und; - u32 R13_irq, R14_irq; - u32 R8_fiq, R9_fiq, R10_fiq, R11_fiq, R12_fiq, R13_fiq, R14_fiq; - Status_Reg SPSR_svc, SPSR_abt, SPSR_und, SPSR_irq, SPSR_fiq; - - armcp_t *coproc[16]; - - u32 intVector; - u8 LDTBit; //1 : ARMv5 style 0 : non ARMv5 - BOOL waitIRQ; - BOOL wIRQ; - BOOL wirq; - - u32 newIrqFlags; - - u32 (* *swi_tab)(); - -#ifdef GDB_STUB - /** there is a pending irq for the cpu */ - int irq_flag; - - /** the post executed function (if installed) */ - void (*post_ex_fn)( void *, u32 adr, int thumb); - - /** data for the post executed function */ - void *post_ex_fn_data; - - - /** flag indicating if the processor is stalled */ - int stalled; - - /** the memory interface */ - struct armcpu_memory_iface *mem_if; - - /** the ctrl interface */ - struct armcpu_ctrl_iface ctrl_iface; -#endif -} armcpu_t; - -#ifdef GDB_STUB -int armcpu_new( armcpu_t *armcpu, u32 id, struct armcpu_memory_iface *mem_if, - struct armcpu_ctrl_iface **ctrl_iface_ret); -#else -int armcpu_new( armcpu_t *armcpu, u32 id); -#endif -void armcpu_init(armcpu_t *armcpu, u32 adr); -u32 armcpu_switchMode(armcpu_t *armcpu, u8 mode); - - -template u32 armcpu_exec(); - -BOOL armcpu_irqException(armcpu_t *armcpu); -BOOL armcpu_flagIrq( armcpu_t *armcpu); - -extern armcpu_t NDS_ARM7; -extern armcpu_t NDS_ARM9; - - -static INLINE void setIF(int PROCNUM, u32 flag) -{ - MMU.reg_IF[PROCNUM] |= flag; - - if(ARMPROC.waitIRQ) - ARMPROC.newIrqFlags |= flag; - extern void NDS_Reschedule(); - NDS_Reschedule(); -} - -static INLINE void NDS_makeARM9Int(u32 num) -{ - /* flag the interrupt request source */ - // MMU.reg_IF[0] |= (1<>25)&0x7) +#define OPCODE(i) (((i)>>21)&0xF) +#define SIGNEBIT(i) BIT_N(i,20) + +#define INSTRUCTION_INDEX(i) ((((i)>>16)&0xFF0)|(((i)>>4)&0xF)) + +inline u32 ROR(u32 i, u32 j) { return ((((u32)(i))>>(j)) | (((u32)(i))<<(32-(j)))); } + +template +inline T UNSIGNED_OVERFLOW(T a,T b,T c) { return ((BIT31(a)&BIT31(b)) | + ((BIT31(a)|BIT31(b))&BIT31(~c))); } + +template +inline T UNSIGNED_UNDERFLOW(T a,T b,T c) { return ((BIT31(~a)&BIT31(b)) | + ((BIT31(~a)|BIT31(b))&BIT31(c))); } + +template +inline T SIGNED_OVERFLOW(T a,T b,T c) { return ((BIT31(a)&BIT31(b)&BIT31(~c))| + (BIT31(~a)&BIT31(~(b))&BIT31(c))); } + +template +inline T SIGNED_UNDERFLOW(T a,T b,T c) { return ((BIT31(a)&BIT31(~(b))&BIT31(~c))| + (BIT31(~a)&BIT31(b)&BIT31(c))); } + +//zero 15-feb-2009 - these werent getting used and they were getting in my way +//#define EQ 0x0 +//#define NE 0x1 +//#define CS 0x2 +//#define CC 0x3 +//#define MI 0x4 +//#define PL 0x5 +//#define VS 0x6 +//#define VC 0x7 +//#define HI 0x8 +//#define LS 0x9 +//#define GE 0xA +//#define LT 0xB +//#define GT 0xC +//#define LE 0xD +//#define AL 0xE + +extern const unsigned char arm_cond_table[16*16]; + +#define TEST_COND(cond, inst, CPSR) ((arm_cond_table[((CPSR.val >> 24) & 0xf0)+(cond)] >> (inst)) & 1) + + +enum Mode +{ + USR = 0x10, + FIQ = 0x11, + IRQ = 0x12, + SVC = 0x13, + ABT = 0x17, + UND = 0x1B, + SYS = 0x1F +}; + +#ifdef WORDS_BIGENDIAN +typedef union +{ + struct + { + u32 N : 1, + Z : 1, + C : 1, + V : 1, + Q : 1, + RAZ : 19, + I : 1, + F : 1, + T : 1, + mode : 5; + } bits; + u32 val; +} Status_Reg; +#else +typedef union +{ + struct + { + u32 mode : 5, + T : 1, + F : 1, + I : 1, + RAZ : 19, + Q : 1, + V : 1, + C : 1, + Z : 1, + N : 1; + } bits; + u32 val; +} Status_Reg; +#endif + +/** + * The control interface to a CPU + */ +struct armcpu_ctrl_iface { + /** stall the processor */ + void (*stall)( void *instance); + + /** unstall the processor */ + void (*unstall)( void *instance); + + /** read a register value */ + u32 (*read_reg)( void *instance, u32 reg_num); + + /** set a register value */ + void (*set_reg)( void *instance, u32 reg_num, u32 value); + + /** install the post execute function */ + void (*install_post_ex_fn)( void *instance, + void (*fn)( void *, u32 adr, int thumb), + void *fn_data); + + /** remove the post execute function */ + void (*remove_post_ex_fn)( void *instance); + + /** the private data passed to all interface functions */ + void *data; +}; + + +typedef void* armcp_t; + +typedef struct armcpu_t +{ + u32 proc_ID; + u32 instruction; //4 + u32 instruct_adr; //8 + u32 next_instruction; //12 + + u32 R[16]; //16 + Status_Reg CPSR; //80 + Status_Reg SPSR; + + u32 R13_usr, R14_usr; + u32 R13_svc, R14_svc; + u32 R13_abt, R14_abt; + u32 R13_und, R14_und; + u32 R13_irq, R14_irq; + u32 R8_fiq, R9_fiq, R10_fiq, R11_fiq, R12_fiq, R13_fiq, R14_fiq; + Status_Reg SPSR_svc, SPSR_abt, SPSR_und, SPSR_irq, SPSR_fiq; + + armcp_t *coproc[16]; + + u32 intVector; + u8 LDTBit; //1 : ARMv5 style 0 : non ARMv5 + BOOL waitIRQ; + BOOL wIRQ; + BOOL wirq; + + u32 newIrqFlags; + + u32 (* *swi_tab)(); + +#ifdef GDB_STUB + /** there is a pending irq for the cpu */ + int irq_flag; + + /** the post executed function (if installed) */ + void (*post_ex_fn)( void *, u32 adr, int thumb); + + /** data for the post executed function */ + void *post_ex_fn_data; + + + /** flag indicating if the processor is stalled */ + int stalled; + + /** the memory interface */ + struct armcpu_memory_iface *mem_if; + + /** the ctrl interface */ + struct armcpu_ctrl_iface ctrl_iface; +#endif +} armcpu_t; + +#ifdef GDB_STUB +int armcpu_new( armcpu_t *armcpu, u32 id, struct armcpu_memory_iface *mem_if, + struct armcpu_ctrl_iface **ctrl_iface_ret); +#else +int armcpu_new( armcpu_t *armcpu, u32 id); +#endif +void armcpu_init(armcpu_t *armcpu, u32 adr); +u32 armcpu_switchMode(armcpu_t *armcpu, u8 mode); + + +template u32 armcpu_exec(); + +BOOL armcpu_irqException(armcpu_t *armcpu); +BOOL armcpu_flagIrq( armcpu_t *armcpu); + +extern armcpu_t NDS_ARM7; +extern armcpu_t NDS_ARM9; + + +static INLINE void setIF(int PROCNUM, u32 flag) +{ + MMU.reg_IF[PROCNUM] |= flag; + + if(ARMPROC.waitIRQ) + ARMPROC.newIrqFlags |= flag; +} + +static INLINE void NDS_makeARM9Int(u32 num) +{ + /* flag the interrupt request source */ + // MMU.reg_IF[0] |= (1< -#include "MMU.h" -#include "SPU.h" -#include "debug.h" - -#define cpu (&ARMPROC) -#define TEMPLATE template - -extern BOOL execute; - -static const u16 getsinetbl[] = { -0x0000, 0x0324, 0x0648, 0x096A, 0x0C8C, 0x0FAB, 0x12C8, 0x15E2, -0x18F9, 0x1C0B, 0x1F1A, 0x2223, 0x2528, 0x2826, 0x2B1F, 0x2E11, -0x30FB, 0x33DF, 0x36BA, 0x398C, 0x3C56, 0x3F17, 0x41CE, 0x447A, -0x471C, 0x49B4, 0x4C3F, 0x4EBF, 0x5133, 0x539B, 0x55F5, 0x5842, -0x5A82, 0x5CB3, 0x5ED7, 0x60EB, 0x62F1, 0x64E8, 0x66CF, 0x68A6, -0x6A6D, 0x6C23, 0x6DC9, 0x6F5E, 0x70E2, 0x7254, 0x73B5, 0x7504, -0x7641, 0x776B, 0x7884, 0x7989, 0x7A7C, 0x7B5C, 0x7C29, 0x7CE3, -0x7D89, 0x7E1D, 0x7E9C, 0x7F09, 0x7F61, 0x7FA6, 0x7FD8, 0x7FF5 -}; - -static const u16 getpitchtbl[] = { -0x0000, 0x003B, 0x0076, 0x00B2, 0x00ED, 0x0128, 0x0164, 0x019F, -0x01DB, 0x0217, 0x0252, 0x028E, 0x02CA, 0x0305, 0x0341, 0x037D, -0x03B9, 0x03F5, 0x0431, 0x046E, 0x04AA, 0x04E6, 0x0522, 0x055F, -0x059B, 0x05D8, 0x0614, 0x0651, 0x068D, 0x06CA, 0x0707, 0x0743, -0x0780, 0x07BD, 0x07FA, 0x0837, 0x0874, 0x08B1, 0x08EF, 0x092C, -0x0969, 0x09A7, 0x09E4, 0x0A21, 0x0A5F, 0x0A9C, 0x0ADA, 0x0B18, -0x0B56, 0x0B93, 0x0BD1, 0x0C0F, 0x0C4D, 0x0C8B, 0x0CC9, 0x0D07, -0x0D45, 0x0D84, 0x0DC2, 0x0E00, 0x0E3F, 0x0E7D, 0x0EBC, 0x0EFA, -0x0F39, 0x0F78, 0x0FB6, 0x0FF5, 0x1034, 0x1073, 0x10B2, 0x10F1, -0x1130, 0x116F, 0x11AE, 0x11EE, 0x122D, 0x126C, 0x12AC, 0x12EB, -0x132B, 0x136B, 0x13AA, 0x13EA, 0x142A, 0x146A, 0x14A9, 0x14E9, -0x1529, 0x1569, 0x15AA, 0x15EA, 0x162A, 0x166A, 0x16AB, 0x16EB, -0x172C, 0x176C, 0x17AD, 0x17ED, 0x182E, 0x186F, 0x18B0, 0x18F0, -0x1931, 0x1972, 0x19B3, 0x19F5, 0x1A36, 0x1A77, 0x1AB8, 0x1AFA, -0x1B3B, 0x1B7D, 0x1BBE, 0x1C00, 0x1C41, 0x1C83, 0x1CC5, 0x1D07, -0x1D48, 0x1D8A, 0x1DCC, 0x1E0E, 0x1E51, 0x1E93, 0x1ED5, 0x1F17, -0x1F5A, 0x1F9C, 0x1FDF, 0x2021, 0x2064, 0x20A6, 0x20E9, 0x212C, -0x216F, 0x21B2, 0x21F5, 0x2238, 0x227B, 0x22BE, 0x2301, 0x2344, -0x2388, 0x23CB, 0x240E, 0x2452, 0x2496, 0x24D9, 0x251D, 0x2561, -0x25A4, 0x25E8, 0x262C, 0x2670, 0x26B4, 0x26F8, 0x273D, 0x2781, -0x27C5, 0x280A, 0x284E, 0x2892, 0x28D7, 0x291C, 0x2960, 0x29A5, -0x29EA, 0x2A2F, 0x2A74, 0x2AB9, 0x2AFE, 0x2B43, 0x2B88, 0x2BCD, -0x2C13, 0x2C58, 0x2C9D, 0x2CE3, 0x2D28, 0x2D6E, 0x2DB4, 0x2DF9, -0x2E3F, 0x2E85, 0x2ECB, 0x2F11, 0x2F57, 0x2F9D, 0x2FE3, 0x302A, -0x3070, 0x30B6, 0x30FD, 0x3143, 0x318A, 0x31D0, 0x3217, 0x325E, -0x32A5, 0x32EC, 0x3332, 0x3379, 0x33C1, 0x3408, 0x344F, 0x3496, -0x34DD, 0x3525, 0x356C, 0x35B4, 0x35FB, 0x3643, 0x368B, 0x36D3, -0x371A, 0x3762, 0x37AA, 0x37F2, 0x383A, 0x3883, 0x38CB, 0x3913, -0x395C, 0x39A4, 0x39ED, 0x3A35, 0x3A7E, 0x3AC6, 0x3B0F, 0x3B58, -0x3BA1, 0x3BEA, 0x3C33, 0x3C7C, 0x3CC5, 0x3D0E, 0x3D58, 0x3DA1, -0x3DEA, 0x3E34, 0x3E7D, 0x3EC7, 0x3F11, 0x3F5A, 0x3FA4, 0x3FEE, -0x4038, 0x4082, 0x40CC, 0x4116, 0x4161, 0x41AB, 0x41F5, 0x4240, -0x428A, 0x42D5, 0x431F, 0x436A, 0x43B5, 0x4400, 0x444B, 0x4495, -0x44E1, 0x452C, 0x4577, 0x45C2, 0x460D, 0x4659, 0x46A4, 0x46F0, -0x473B, 0x4787, 0x47D3, 0x481E, 0x486A, 0x48B6, 0x4902, 0x494E, -0x499A, 0x49E6, 0x4A33, 0x4A7F, 0x4ACB, 0x4B18, 0x4B64, 0x4BB1, -0x4BFE, 0x4C4A, 0x4C97, 0x4CE4, 0x4D31, 0x4D7E, 0x4DCB, 0x4E18, -0x4E66, 0x4EB3, 0x4F00, 0x4F4E, 0x4F9B, 0x4FE9, 0x5036, 0x5084, -0x50D2, 0x5120, 0x516E, 0x51BC, 0x520A, 0x5258, 0x52A6, 0x52F4, -0x5343, 0x5391, 0x53E0, 0x542E, 0x547D, 0x54CC, 0x551A, 0x5569, -0x55B8, 0x5607, 0x5656, 0x56A5, 0x56F4, 0x5744, 0x5793, 0x57E2, -0x5832, 0x5882, 0x58D1, 0x5921, 0x5971, 0x59C1, 0x5A10, 0x5A60, -0x5AB0, 0x5B01, 0x5B51, 0x5BA1, 0x5BF1, 0x5C42, 0x5C92, 0x5CE3, -0x5D34, 0x5D84, 0x5DD5, 0x5E26, 0x5E77, 0x5EC8, 0x5F19, 0x5F6A, -0x5FBB, 0x600D, 0x605E, 0x60B0, 0x6101, 0x6153, 0x61A4, 0x61F6, -0x6248, 0x629A, 0x62EC, 0x633E, 0x6390, 0x63E2, 0x6434, 0x6487, -0x64D9, 0x652C, 0x657E, 0x65D1, 0x6624, 0x6676, 0x66C9, 0x671C, -0x676F, 0x67C2, 0x6815, 0x6869, 0x68BC, 0x690F, 0x6963, 0x69B6, -0x6A0A, 0x6A5E, 0x6AB1, 0x6B05, 0x6B59, 0x6BAD, 0x6C01, 0x6C55, -0x6CAA, 0x6CFE, 0x6D52, 0x6DA7, 0x6DFB, 0x6E50, 0x6EA4, 0x6EF9, -0x6F4E, 0x6FA3, 0x6FF8, 0x704D, 0x70A2, 0x70F7, 0x714D, 0x71A2, -0x71F7, 0x724D, 0x72A2, 0x72F8, 0x734E, 0x73A4, 0x73FA, 0x7450, -0x74A6, 0x74FC, 0x7552, 0x75A8, 0x75FF, 0x7655, 0x76AC, 0x7702, -0x7759, 0x77B0, 0x7807, 0x785E, 0x78B4, 0x790C, 0x7963, 0x79BA, -0x7A11, 0x7A69, 0x7AC0, 0x7B18, 0x7B6F, 0x7BC7, 0x7C1F, 0x7C77, -0x7CCF, 0x7D27, 0x7D7F, 0x7DD7, 0x7E2F, 0x7E88, 0x7EE0, 0x7F38, -0x7F91, 0x7FEA, 0x8042, 0x809B, 0x80F4, 0x814D, 0x81A6, 0x81FF, -0x8259, 0x82B2, 0x830B, 0x8365, 0x83BE, 0x8418, 0x8472, 0x84CB, -0x8525, 0x857F, 0x85D9, 0x8633, 0x868E, 0x86E8, 0x8742, 0x879D, -0x87F7, 0x8852, 0x88AC, 0x8907, 0x8962, 0x89BD, 0x8A18, 0x8A73, -0x8ACE, 0x8B2A, 0x8B85, 0x8BE0, 0x8C3C, 0x8C97, 0x8CF3, 0x8D4F, -0x8DAB, 0x8E07, 0x8E63, 0x8EBF, 0x8F1B, 0x8F77, 0x8FD4, 0x9030, -0x908C, 0x90E9, 0x9146, 0x91A2, 0x91FF, 0x925C, 0x92B9, 0x9316, -0x9373, 0x93D1, 0x942E, 0x948C, 0x94E9, 0x9547, 0x95A4, 0x9602, -0x9660, 0x96BE, 0x971C, 0x977A, 0x97D8, 0x9836, 0x9895, 0x98F3, -0x9952, 0x99B0, 0x9A0F, 0x9A6E, 0x9ACD, 0x9B2C, 0x9B8B, 0x9BEA, -0x9C49, 0x9CA8, 0x9D08, 0x9D67, 0x9DC7, 0x9E26, 0x9E86, 0x9EE6, -0x9F46, 0x9FA6, 0xA006, 0xA066, 0xA0C6, 0xA127, 0xA187, 0xA1E8, -0xA248, 0xA2A9, 0xA30A, 0xA36B, 0xA3CC, 0xA42D, 0xA48E, 0xA4EF, -0xA550, 0xA5B2, 0xA613, 0xA675, 0xA6D6, 0xA738, 0xA79A, 0xA7FC, -0xA85E, 0xA8C0, 0xA922, 0xA984, 0xA9E7, 0xAA49, 0xAAAC, 0xAB0E, -0xAB71, 0xABD4, 0xAC37, 0xAC9A, 0xACFD, 0xAD60, 0xADC3, 0xAE27, -0xAE8A, 0xAEED, 0xAF51, 0xAFB5, 0xB019, 0xB07C, 0xB0E0, 0xB145, -0xB1A9, 0xB20D, 0xB271, 0xB2D6, 0xB33A, 0xB39F, 0xB403, 0xB468, -0xB4CD, 0xB532, 0xB597, 0xB5FC, 0xB662, 0xB6C7, 0xB72C, 0xB792, -0xB7F7, 0xB85D, 0xB8C3, 0xB929, 0xB98F, 0xB9F5, 0xBA5B, 0xBAC1, -0xBB28, 0xBB8E, 0xBBF5, 0xBC5B, 0xBCC2, 0xBD29, 0xBD90, 0xBDF7, -0xBE5E, 0xBEC5, 0xBF2C, 0xBF94, 0xBFFB, 0xC063, 0xC0CA, 0xC132, -0xC19A, 0xC202, 0xC26A, 0xC2D2, 0xC33A, 0xC3A2, 0xC40B, 0xC473, -0xC4DC, 0xC544, 0xC5AD, 0xC616, 0xC67F, 0xC6E8, 0xC751, 0xC7BB, -0xC824, 0xC88D, 0xC8F7, 0xC960, 0xC9CA, 0xCA34, 0xCA9E, 0xCB08, -0xCB72, 0xCBDC, 0xCC47, 0xCCB1, 0xCD1B, 0xCD86, 0xCDF1, 0xCE5B, -0xCEC6, 0xCF31, 0xCF9C, 0xD008, 0xD073, 0xD0DE, 0xD14A, 0xD1B5, -0xD221, 0xD28D, 0xD2F8, 0xD364, 0xD3D0, 0xD43D, 0xD4A9, 0xD515, -0xD582, 0xD5EE, 0xD65B, 0xD6C7, 0xD734, 0xD7A1, 0xD80E, 0xD87B, -0xD8E9, 0xD956, 0xD9C3, 0xDA31, 0xDA9E, 0xDB0C, 0xDB7A, 0xDBE8, -0xDC56, 0xDCC4, 0xDD32, 0xDDA0, 0xDE0F, 0xDE7D, 0xDEEC, 0xDF5B, -0xDFC9, 0xE038, 0xE0A7, 0xE116, 0xE186, 0xE1F5, 0xE264, 0xE2D4, -0xE343, 0xE3B3, 0xE423, 0xE493, 0xE503, 0xE573, 0xE5E3, 0xE654, -0xE6C4, 0xE735, 0xE7A5, 0xE816, 0xE887, 0xE8F8, 0xE969, 0xE9DA, -0xEA4B, 0xEABC, 0xEB2E, 0xEB9F, 0xEC11, 0xEC83, 0xECF5, 0xED66, -0xEDD9, 0xEE4B, 0xEEBD, 0xEF2F, 0xEFA2, 0xF014, 0xF087, 0xF0FA, -0xF16D, 0xF1E0, 0xF253, 0xF2C6, 0xF339, 0xF3AD, 0xF420, 0xF494, -0xF507, 0xF57B, 0xF5EF, 0xF663, 0xF6D7, 0xF74C, 0xF7C0, 0xF834, -0xF8A9, 0xF91E, 0xF992, 0xFA07, 0xFA7C, 0xFAF1, 0xFB66, 0xFBDC, -0xFC51, 0xFCC7, 0xFD3C, 0xFDB2, 0xFE28, 0xFE9E, 0xFF14, 0xFF8A -}; - -static const u8 getvoltbl[] = { -0x00, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, -0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, -0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, -0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, -0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, -0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, -0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, -0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, -0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x03, 0x03, 0x03, -0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, -0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x04, 0x04, 0x04, 0x04, 0x04, 0x04, -0x04, 0x04, 0x04, 0x04, 0x04, 0x04, 0x04, 0x04, 0x04, 0x04, 0x04, 0x04, 0x04, 0x04, 0x04, 0x04, -0x05, 0x05, 0x05, 0x05, 0x05, 0x05, 0x05, 0x05, 0x05, 0x05, 0x05, 0x05, 0x05, 0x05, 0x05, 0x05, -0x05, 0x06, 0x06, 0x06, 0x06, 0x06, 0x06, 0x06, 0x06, 0x06, 0x06, 0x06, 0x06, 0x06, 0x06, 0x06, -0x07, 0x07, 0x07, 0x07, 0x07, 0x07, 0x07, 0x07, 0x07, 0x07, 0x07, 0x07, 0x08, 0x08, 0x08, 0x08, -0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x09, 0x09, 0x09, 0x09, 0x09, 0x09, 0x09, 0x09, 0x09, -0x09, 0x0A, 0x0A, 0x0A, 0x0A, 0x0A, 0x0A, 0x0A, 0x0A, 0x0B, 0x0B, 0x0B, 0x0B, 0x0B, 0x0B, 0x0B, -0x0B, 0x0C, 0x0C, 0x0C, 0x0C, 0x0C, 0x0C, 0x0C, 0x0C, 0x0D, 0x0D, 0x0D, 0x0D, 0x0D, 0x0D, 0x0E, -0x0E, 0x0E, 0x0E, 0x0E, 0x0E, 0x0E, 0x0F, 0x0F, 0x0F, 0x0F, 0x0F, 0x10, 0x10, 0x10, 0x10, 0x10, -0x10, 0x11, 0x11, 0x11, 0x11, 0x11, 0x12, 0x12, 0x12, 0x12, 0x12, 0x13, 0x13, 0x13, 0x13, 0x14, -0x14, 0x14, 0x14, 0x14, 0x15, 0x15, 0x15, 0x15, 0x16, 0x16, 0x16, 0x16, 0x17, 0x17, 0x17, 0x18, -0x18, 0x18, 0x18, 0x19, 0x19, 0x19, 0x19, 0x1A, 0x1A, 0x1A, 0x1B, 0x1B, 0x1B, 0x1C, 0x1C, 0x1C, -0x1D, 0x1D, 0x1D, 0x1E, 0x1E, 0x1E, 0x1F, 0x1F, 0x1F, 0x20, 0x20, 0x20, 0x21, 0x21, 0x22, 0x22, -0x22, 0x23, 0x23, 0x24, 0x24, 0x24, 0x25, 0x25, 0x26, 0x26, 0x27, 0x27, 0x27, 0x28, 0x28, 0x29, -0x29, 0x2A, 0x2A, 0x2B, 0x2B, 0x2C, 0x2C, 0x2D, 0x2D, 0x2E, 0x2E, 0x2F, 0x2F, 0x30, 0x31, 0x31, -0x32, 0x32, 0x33, 0x33, 0x34, 0x35, 0x35, 0x36, 0x36, 0x37, 0x38, 0x38, 0x39, 0x3A, 0x3A, 0x3B, -0x3C, 0x3C, 0x3D, 0x3E, 0x3F, 0x3F, 0x40, 0x41, 0x42, 0x42, 0x43, 0x44, 0x45, 0x45, 0x46, 0x47, -0x48, 0x49, 0x4A, 0x4A, 0x4B, 0x4C, 0x4D, 0x4E, 0x4F, 0x50, 0x51, 0x52, 0x52, 0x53, 0x54, 0x55, -0x56, 0x57, 0x58, 0x59, 0x5A, 0x5B, 0x5D, 0x5E, 0x5F, 0x60, 0x61, 0x62, 0x63, 0x64, 0x65, 0x67, -0x68, 0x69, 0x6A, 0x6B, 0x6D, 0x6E, 0x6F, 0x71, 0x72, 0x73, 0x75, 0x76, 0x77, 0x79, 0x7A, 0x7B, -0x7D, 0x7E, 0x7F, 0x20, 0x21, 0x21, 0x21, 0x22, 0x22, 0x23, 0x23, 0x23, 0x24, 0x24, 0x25, 0x25, -0x26, 0x26, 0x26, 0x27, 0x27, 0x28, 0x28, 0x29, 0x29, 0x2A, 0x2A, 0x2B, 0x2B, 0x2C, 0x2C, 0x2D, -0x2D, 0x2E, 0x2E, 0x2F, 0x2F, 0x30, 0x30, 0x31, 0x31, 0x32, 0x33, 0x33, 0x34, 0x34, 0x35, 0x36, -0x36, 0x37, 0x37, 0x38, 0x39, 0x39, 0x3A, 0x3B, 0x3B, 0x3C, 0x3D, 0x3E, 0x3E, 0x3F, 0x40, 0x40, -0x41, 0x42, 0x43, 0x43, 0x44, 0x45, 0x46, 0x47, 0x47, 0x48, 0x49, 0x4A, 0x4B, 0x4C, 0x4D, 0x4D, -0x4E, 0x4F, 0x50, 0x51, 0x52, 0x53, 0x54, 0x55, 0x56, 0x57, 0x58, 0x59, 0x5A, 0x5B, 0x5C, 0x5D, -0x5E, 0x5F, 0x60, 0x62, 0x63, 0x64, 0x65, 0x66, 0x67, 0x69, 0x6A, 0x6B, 0x6C, 0x6D, 0x6F, 0x70, -0x71, 0x73, 0x74, 0x75, 0x77, 0x78, 0x79, 0x7B, 0x7C, 0x7E, 0x7E, 0x40, 0x41, 0x42, 0x43, 0x43, -0x44, 0x45, 0x46, 0x47, 0x47, 0x48, 0x49, 0x4A, 0x4B, 0x4C, 0x4C, 0x4D, 0x4E, 0x4F, 0x50, 0x51, -0x52, 0x53, 0x54, 0x55, 0x56, 0x57, 0x58, 0x59, 0x5A, 0x5B, 0x5C, 0x5D, 0x5E, 0x5F, 0x60, 0x61, -0x62, 0x64, 0x65, 0x66, 0x67, 0x68, 0x69, 0x6B, 0x6C, 0x6D, 0x6E, 0x70, 0x71, 0x72, 0x74, 0x75, -0x76, 0x78, 0x79, 0x7B, 0x7C, 0x7D, 0x7E, 0x40, 0x41, 0x42, 0x42, 0x43, 0x44, 0x45, 0x46, 0x46, -0x47, 0x48, 0x49, 0x4A, 0x4B, 0x4B, 0x4C, 0x4D, 0x4E, 0x4F, 0x50, 0x51, 0x52, 0x53, 0x54, 0x55, -0x56, 0x57, 0x58, 0x59, 0x5A, 0x5B, 0x5C, 0x5D, 0x5E, 0x5F, 0x60, 0x61, 0x62, 0x63, 0x65, 0x66, -0x67, 0x68, 0x69, 0x6A, 0x6C, 0x6D, 0x6E, 0x6F, 0x71, 0x72, 0x73, 0x75, 0x76, 0x77, 0x79, 0x7A, -0x7C, 0x7D, 0x7E, 0x7F -}; - -TEMPLATE static u32 bios_nop() -{ - if (cpu->proc_ID == ARMCPU_ARM9) - { - LOG("Unimplemented bios function %02X(ARM9) was used. R0:%08X\n", (cpu->instruction)&0x1F, cpu->R[0]); - } - else - { - LOG("Unimplemented bios function %02X(ARM7) was used. R0:%08X\n", (cpu->instruction)&0x1F, cpu->R[0]); - } - return 3; -} - -TEMPLATE static u32 delayLoop() -{ - return cpu->R[0] * 4; -} - -//u32 oldmode[2]; - -TEMPLATE u32 intrWaitARM() -{ - u32 intrFlagAdr;// = (((armcp15_t *)(cpu->coproc[15]))->DTCMRegion&0xFFFFF000)+0x3FF8; - u32 intr; - u32 intrFlag = 0; - - BOOL noDiscard = ((cpu->R[0] == 0) && (PROCNUM == 1)); - - //emu_halt(); - if(cpu->proc_ID) - { - intrFlagAdr = 0x380FFF8; - } else { - intrFlagAdr = (((armcp15_t *)(cpu->coproc[15]))->DTCMRegion&0xFFFFF000)+0x3FF8; - } - intr = _MMU_read32(intrFlagAdr); - intrFlag = (cpu->R[1] & intr); - - if(!noDiscard) - intrFlag &= ARMPROC.newIrqFlags; - - if(intrFlag) - { - // si une(ou plusieurs) des interruptions que l'on attend s'est(se sont) produite(s) - // on efface son(les) occurence(s). - intr ^= intrFlag; - cpu->newIrqFlags ^= intrFlag; - _MMU_write32(intrFlagAdr, intr); - //cpu->switchMode(oldmode[cpu->proc_ID]); - return 1; - } - - cpu->R[15] = cpu->instruct_adr; - cpu->next_instruction = cpu->R[15]; - cpu->waitIRQ = 1; - //oldmode[cpu->proc_ID] = cpu->switchMode(SVC); - - return 1; -} - -TEMPLATE static u32 waitVBlankARM() -{ - cpu->R[0] = 1; - cpu->R[1] = 1; - return intrWaitARM(); -#if 0 - u32 intrFlagAdr;// = (((armcp15_t *)(cpu->coproc[15]))->DTCMRegion&0xFFFFF000)+0x3FF8; - u32 intr; - u32 intrFlag = 0; - - //emu_halt(); - if(cpu->proc_ID) - { - intrFlagAdr = 0x380FFF8; - } else { - intrFlagAdr = (((armcp15_t *)(cpu->coproc[15]))->DTCMRegion&0xFFFFF000)+0x3FF8; - } - intr = _MMU_read32(intrFlagAdr); - intrFlag = 1 & intr; - - // if(intrFlag) - { - // si une(ou plusieurs) des interruptions que l'on attend s'est(se sont) produite(s) - // on efface son(les) occurence(s). - intr ^= intrFlag; - _MMU_write32(intrFlagAdr, intr); - //cpu->switchMode(oldmode[cpu->proc_ID]); - return 1; - } - - cpu->R[15] = cpu->instruct_adr; - cpu->next_instruction = cpu->R[15]; - cpu->waitIRQ = 1; - //oldmode[cpu->proc_ID] = cpu->switchMode(SVC); - - return 1; -#endif -} - -TEMPLATE static u32 wait4IRQ() -{ - //execute= FALSE; - if(cpu->wirq) - { - if(!cpu->waitIRQ) - { - cpu->waitIRQ = 0; - cpu->wirq = 0; - //cpu->switchMode(oldmode[cpu->proc_ID]); - return 1; - } - cpu->R[15] = cpu->instruct_adr; - cpu->next_instruction = cpu->R[15]; - return 1; - } - cpu->waitIRQ = 1; - cpu->wirq = 1; - cpu->R[15] = cpu->instruct_adr; - cpu->next_instruction = cpu->R[15]; - //oldmode[cpu->proc_ID] = cpu->switchMode(SVC); - return 1; -} - -TEMPLATE static u32 sleep() -{ - _MMU_write08(0x04000301, 0xC0); - return 1; -} - -TEMPLATE static u32 divide() -{ - s32 num = (s32)cpu->R[0]; - s32 dnum = (s32)cpu->R[1]; - - if(dnum==0) return 0; - - cpu->R[0] = (u32)(num / dnum); - cpu->R[1] = (u32)(num % dnum); - cpu->R[3] = (u32) (((s32)cpu->R[0])<0 ? -(s32)cpu->R[0] : cpu->R[0]); - - return 6; -} - -TEMPLATE static u32 copy() -{ - u32 src = cpu->R[0]; - u32 dst = cpu->R[1]; - u32 cnt = cpu->R[2]; - - //INFO("swi copy from %08X to %08X, cnt=%08X\n", src, dst, cnt); - - switch(BIT26(cnt)) - { - case 0: - src &= 0xFFFFFFFE; - dst &= 0xFFFFFFFE; - switch(BIT24(cnt)) - { - case 0: - cnt &= 0x1FFFFF; - while(cnt) - { - _MMU_write16(dst, _MMU_read16(src)); - cnt--; - dst+=2; - src+=2; - } - break; - case 1: - { - u32 val = _MMU_read16(src); - cnt &= 0x1FFFFF; - while(cnt) - { - _MMU_write16(dst, val); - cnt--; - dst+=2; - } - } - break; - } - break; - case 1: - src &= 0xFFFFFFFC; - dst &= 0xFFFFFFFC; - switch(BIT24(cnt)) - { - case 0: - cnt &= 0x1FFFFF; - while(cnt) - { - _MMU_write32(dst, _MMU_read32(src)); - cnt--; - dst+=4; - src+=4; - } - break; - case 1: - { - u32 val = _MMU_read32(src); - cnt &= 0x1FFFFF; - while(cnt) - { - _MMU_write32(dst, val); - cnt--; - dst+=4; - } - } - break; - } - break; - } - return 1; -} - -TEMPLATE static u32 fastCopy() -{ - u32 src = cpu->R[0] & 0xFFFFFFFC; - u32 dst = cpu->R[1] & 0xFFFFFFFC; - u32 cnt = cpu->R[2]; - - //INFO("swi fastcopy from %08X to %08X, cnt=%08X\n", src, dst, cnt); - - switch(BIT24(cnt)) - { - case 0: - cnt &= 0x1FFFFF; - while(cnt) - { - _MMU_write32(dst, _MMU_read32(src)); - cnt--; - dst+=4; - src+=4; - } - break; - case 1: - { - u32 val = _MMU_read32(src); - cnt &= 0x1FFFFF; - while(cnt) - { - _MMU_write32(dst, val); - cnt--; - dst+=4; - } - } - break; - } - return 1; -} - -TEMPLATE static u32 LZ77UnCompVram() -{ - int i1, i2; - int byteCount; - int byteShift; - u32 writeValue; - int len; - u32 source = cpu->R[0]; - u32 dest = cpu->R[1]; - u32 header = _MMU_read32(source); - source += 4; - - //INFO("swi lz77uncompvram\n"); - - if(((source & 0xe000000) == 0) || - ((source + ((header >> 8) & 0x1fffff)) & 0xe000000) == 0) - return 0; - - byteCount = 0; - byteShift = 0; - writeValue = 0; - - len = header >> 8; - - while(len > 0) { - u8 d = _MMU_read08(source++); - - if(d) { - for(i1 = 0; i1 < 8; i1++) { - if(d & 0x80) { - int length; - int offset; - u32 windowOffset; - u16 data = _MMU_read08(source++) << 8; - data |= _MMU_read08(source++); - length = (data >> 12) + 3; - offset = (data & 0x0FFF); - windowOffset = dest + byteCount - offset - 1; - for(i2 = 0; i2 < length; i2++) { - writeValue |= (_MMU_read08(windowOffset++) << byteShift); - byteShift += 8; - byteCount++; - - if(byteCount == 2) { - _MMU_write16(dest, writeValue); - dest += 2; - byteCount = 0; - byteShift = 0; - writeValue = 0; - } - len--; - if(len == 0) - return 0; - } - } else { - writeValue |= (_MMU_read08(source++) << byteShift); - byteShift += 8; - byteCount++; - if(byteCount == 2) { - _MMU_write16(dest, writeValue); - dest += 2; - byteCount = 0; - byteShift = 0; - writeValue = 0; - } - len--; - if(len == 0) - return 0; - } - d <<= 1; - } - } else { - for(i1 = 0; i1 < 8; i1++) { - writeValue |= (_MMU_read08(source++) << byteShift); - byteShift += 8; - byteCount++; - if(byteCount == 2) { - _MMU_write16(dest, writeValue); - dest += 2; - byteShift = 0; - byteCount = 0; - writeValue = 0; - } - len--; - if(len == 0) - return 0; - } - } - } - return 1; -} - -TEMPLATE static u32 LZ77UnCompWram() -{ - int i1, i2; - int len; - u32 source = cpu->R[0]; - u32 dest = cpu->R[1]; - - u32 header = _MMU_read32(source); - source += 4; - - //INFO("swi lz77uncompwram\n"); - - if(((source & 0xe000000) == 0) || - ((source + ((header >> 8) & 0x1fffff)) & 0xe000000) == 0) - return 0; - - len = header >> 8; - - while(len > 0) { - u8 d = _MMU_read08(source++); - - if(d) { - for(i1 = 0; i1 < 8; i1++) { - if(d & 0x80) { - int length; - int offset; - u32 windowOffset; - u16 data = _MMU_read08(source++) << 8; - data |= _MMU_read08(source++); - length = (data >> 12) + 3; - offset = (data & 0x0FFF); - windowOffset = dest - offset - 1; - for(i2 = 0; i2 < length; i2++) { - _MMU_write08(dest++, _MMU_read08(windowOffset++)); - len--; - if(len == 0) - return 0; - } - } else { - _MMU_write08(dest++, _MMU_read08(source++)); - len--; - if(len == 0) - return 0; - } - d <<= 1; - } - } else { - for(i1 = 0; i1 < 8; i1++) { - _MMU_write08(dest++, _MMU_read08(source++)); - len--; - if(len == 0) - return 0; - } - } - } - return 1; -} - -TEMPLATE static u32 RLUnCompVram() -{ - int i; - int len; - int byteCount; - int byteShift; - u32 writeValue; - u32 source = cpu->R[0]; - u32 dest = cpu->R[1]; - - u32 header = _MMU_read32(source); - source += 4; - - //INFO("swi rluncompvram\n"); - - if(((source & 0xe000000) == 0) || - ((source + ((header >> 8) & 0x1fffff)) & 0xe000000) == 0) - return 0; - - len = header >> 8; - byteCount = 0; - byteShift = 0; - writeValue = 0; - - while(len > 0) { - u8 d = _MMU_read08(source++); - int l = d & 0x7F; - if(d & 0x80) { - u8 data = _MMU_read08(source++); - l += 3; - for(i = 0;i < l; i++) { - writeValue |= (data << byteShift); - byteShift += 8; - byteCount++; - - if(byteCount == 2) { - _MMU_write16(dest, writeValue); - dest += 2; - byteCount = 0; - byteShift = 0; - writeValue = 0; - } - len--; - if(len == 0) - return 0; - } - } else { - l++; - for(i = 0; i < l; i++) { - writeValue |= (_MMU_read08(source++) << byteShift); - byteShift += 8; - byteCount++; - if(byteCount == 2) { - _MMU_write16(dest, writeValue); - dest += 2; - byteCount = 0; - byteShift = 0; - writeValue = 0; - } - len--; - if(len == 0) - return 0; - } - } - } - return 1; -} - -TEMPLATE static u32 RLUnCompWram() -{ - int i; - int len; - u32 source = cpu->R[0]; - u32 dest = cpu->R[1]; - - u32 header = _MMU_read32(source); - source += 4; - - //INFO("swi rluncompwram\n"); - - if(((source & 0xe000000) == 0) || - ((source + ((header >> 8) & 0x1fffff)) & 0xe000000) == 0) - return 0; - - len = header >> 8; - - while(len > 0) { - u8 d = _MMU_read08(source++); - int l = d & 0x7F; - if(d & 0x80) { - u8 data = _MMU_read08(source++); - l += 3; - for(i = 0;i < l; i++) { - _MMU_write08(dest++, data); - len--; - if(len == 0) - return 0; - } - } else { - l++; - for(i = 0; i < l; i++) { - _MMU_write08(dest++, _MMU_read08(source++)); - len--; - if(len == 0) - return 0; - } - } - } - return 1; -} - -TEMPLATE static u32 UnCompHuffman() -{ - u32 source, dest, writeValue, header, treeStart, mask; - u32 data; - u8 treeSize, currentNode, rootNode; - int byteCount, byteShift, len, pos; - int writeData; - - source = cpu->R[0]; - dest = cpu->R[1]; - - header = _MMU_read08(source); - source += 4; - - //INFO("swi uncomphuffman\n"); - - if(((source & 0xe000000) == 0) || - ((source + ((header >> 8) & 0x1fffff)) & 0xe000000) == 0) - return 0; - - treeSize = _MMU_read08(source++); - - treeStart = source; - - source += ((treeSize+1)<<1)-1; // minus because we already skipped one byte - - len = header >> 8; - - mask = 0x80000000; - data = _MMU_read08(source); - source += 4; - - pos = 0; - rootNode = _MMU_read08(treeStart); - currentNode = rootNode; - writeData = 0; - byteShift = 0; - byteCount = 0; - writeValue = 0; - - if((header & 0x0F) == 8) { - while(len > 0) { - // take left - if(pos == 0) - pos++; - else - pos += (((currentNode & 0x3F)+1)<<1); - - if(data & mask) { - // right - if(currentNode & 0x40) - writeData = 1; - currentNode = _MMU_read08(treeStart+pos+1); - } else { - // left - if(currentNode & 0x80) - writeData = 1; - currentNode = _MMU_read08(treeStart+pos); - } - - if(writeData) { - writeValue |= (currentNode << byteShift); - byteCount++; - byteShift += 8; - - pos = 0; - currentNode = rootNode; - writeData = 0; - - if(byteCount == 4) { - byteCount = 0; - byteShift = 0; - _MMU_write08(dest, writeValue); - writeValue = 0; - dest += 4; - len -= 4; - } - } - mask >>= 1; - if(mask == 0) { - mask = 0x80000000; - data = _MMU_read08(source); - source += 4; - } - } - } else { - int halfLen = 0; - int value = 0; - while(len > 0) { - // take left - if(pos == 0) - pos++; - else - pos += (((currentNode & 0x3F)+1)<<1); - - if((data & mask)) { - // right - if(currentNode & 0x40) - writeData = 1; - currentNode = _MMU_read08(treeStart+pos+1); - } else { - // left - if(currentNode & 0x80) - writeData = 1; - currentNode = _MMU_read08(treeStart+pos); - } - - if(writeData) { - if(halfLen == 0) - value |= currentNode; - else - value |= (currentNode<<4); - - halfLen += 4; - if(halfLen == 8) { - writeValue |= (value << byteShift); - byteCount++; - byteShift += 8; - - halfLen = 0; - value = 0; - - if(byteCount == 4) { - byteCount = 0; - byteShift = 0; - _MMU_write08(dest, writeValue); - dest += 4; - writeValue = 0; - len -= 4; - } - } - pos = 0; - currentNode = rootNode; - writeData = 0; - } - mask >>= 1; - if(mask == 0) { - mask = 0x80000000; - data = _MMU_read08(source); - source += 4; - } - } - } - return 1; -} - -TEMPLATE static u32 BitUnPack() -{ - u32 source,dest,header,base,d,temp; - int len,bits,revbits,dataSize,data,bitwritecount,mask,bitcount,addBase; - u8 b; - - source = cpu->R[0]; - dest = cpu->R[1]; - header = cpu->R[2]; - - //INFO("swi bitunpack\n"); - - len = _MMU_read16(header); - // check address - bits = _MMU_read08(header+2); - revbits = 8 - bits; - // u32 value = 0; - base = _MMU_read08(header+4); - addBase = (base & 0x80000000) ? 1 : 0; - base &= 0x7fffffff; - dataSize = _MMU_read08(header+3); - - data = 0; - bitwritecount = 0; - while(1) { - len -= 1; - if(len < 0) - break; - mask = 0xff >> revbits; - b = _MMU_read08(source); - source++; - bitcount = 0; - while(1) { - if(bitcount >= 8) - break; - d = b & mask; - temp = d >> bitcount; - if(!temp && addBase) { - temp += base; - } - data |= temp << bitwritecount; - bitwritecount += dataSize; - if(bitwritecount >= 32) { - _MMU_write08(dest, data); - dest += 4; - data = 0; - bitwritecount = 0; - } - mask <<= bits; - bitcount += bits; - } - } - return 1; -} - -TEMPLATE static u32 Diff8bitUnFilterWram() -{ - u32 source,dest,header; - u8 data,diff; - int len; - - source = cpu->R[0]; - dest = cpu->R[1]; - - header = _MMU_read08(source); - source += 4; - - //INFO("swi diff8bitunfilterwram\n"); - - if(((source & 0xe000000) == 0) || - (( (source + ((header >> 8) & 0x1fffff)) & 0xe000000) == 0)) - return 0; - - len = header >> 8; - - data = _MMU_read08(source++); - _MMU_write08(dest++, data); - len--; - - while(len > 0) { - diff = _MMU_read08(source++); - data += diff; - _MMU_write08(dest++, data); - len--; - } - return 1; -} - -TEMPLATE static u32 Diff16bitUnFilter() -{ - u32 source,dest,header; - u16 data; - int len; - - source = cpu->R[0]; - dest = cpu->R[1]; - - //INFO("swi diff16bitunfilter\n"); - - header = _MMU_read08(source); - source += 4; - - if(((source & 0xe000000) == 0) || - ((source + ((header >> 8) & 0x1fffff)) & 0xe000000) == 0) - return 0; - - len = header >> 8; - - data = _MMU_read16(source); - source += 2; - _MMU_write16(dest, data); - dest += 2; - len -= 2; - - while(len >= 2) { - u16 diff = _MMU_read16(source); - source += 2; - data += diff; - _MMU_write16(dest, data); - dest += 2; - len -= 2; - } - return 1; -} - -TEMPLATE static u32 bios_sqrt() -{ - cpu->R[0] = (u32)sqrt((double)(cpu->R[0])); - return 1; -} - -TEMPLATE static u32 setHaltCR() -{ - _MMU_write08(0x4000300+cpu->proc_ID, cpu->R[0]); - return 1; -} - -TEMPLATE static u32 getSineTab() -{ - cpu->R[0] = getsinetbl[cpu->R[0]]; - return 1; -} - -TEMPLATE static u32 getPitchTab() -{ - cpu->R[0] = getpitchtbl[cpu->R[0]]; - return 1; -} - -TEMPLATE static u32 getVolumeTab() -{ - cpu->R[0] = getvoltbl[cpu->R[0]]; - return 1; -} - -TEMPLATE static u32 getCRC16() -{ - unsigned int i,j; - - u32 crc = cpu->R[0]; - u32 datap = cpu->R[1]; - u32 size = cpu->R[2]; - - const u16 val[] = { 0xC0C1,0xC181,0xC301,0xC601,0xCC01,0xD801,0xF001,0xA001 }; - for(i = 0; i < size; i++) - { - crc = crc ^ _MMU_read08(datap + i); - - for(j = 0; j < 8; j++) { - int do_bit = 0; - - if ( crc & 0x1) - do_bit = 1; - - crc = crc >> 1; - - if ( do_bit) { - crc = crc ^ (val[j] << (7-j)); - } - } - } - cpu->R[0] = crc; - return 1; -} - -TEMPLATE static u32 isDebugger() -{ - //gbatek has additional specifications which are not emulated here -#ifdef DEVELOPER - cpu->R[0] = 1; -#else - cpu->R[0] = 0; -#endif - return 1; -} - -TEMPLATE static u32 SoundBias() -{ - u32 current = SPU_ReadLong(0x4000504); - if (cpu->R[0] > current) - SPU_WriteLong(0x4000504, current + 0x1); - else - SPU_WriteLong(0x4000504, current - 0x1); - return cpu->R[1]; -} - -TEMPLATE static u32 getBootProcs() -{ - cpu->R[0] = 0x00000A2E; - cpu->R[1] = 0x00002C3C; - cpu->R[3] = 0x000005FF; - return 1; -} - -u32 (* ARM9_swi_tab[32])()={ - bios_nop, // 0x00 - bios_nop, // 0x01 - bios_nop, // 0x02 - delayLoop, // 0x03 - intrWaitARM, // 0x04 - waitVBlankARM, // 0x05 - wait4IRQ, // 0x06 - bios_nop, // 0x07 - bios_nop, // 0x08 - divide, // 0x09 - bios_nop, // 0x0A - copy, // 0x0B - fastCopy, // 0x0C - bios_sqrt, // 0x0D - getCRC16, // 0x0E - isDebugger, // 0x0F - BitUnPack, // 0x10 - LZ77UnCompWram, // 0x11 - LZ77UnCompVram, // 0x12 - UnCompHuffman, // 0x13 - RLUnCompWram, // 0x14 - RLUnCompVram, // 0x15 - Diff8bitUnFilterWram, // 0x16 - bios_nop, // 0x17 - Diff16bitUnFilter, // 0x18 - bios_nop, // 0x19 - bios_nop, // 0x1A - bios_nop, // 0x1B - bios_nop, // 0x1C - bios_nop, // 0x1D - bios_nop, // 0x1E - setHaltCR, // 0x1F -}; - -u32 (* ARM7_swi_tab[32])()={ - bios_nop, // 0x00 - bios_nop, // 0x01 - bios_nop, // 0x02 - delayLoop, // 0x03 - intrWaitARM, // 0x04 - waitVBlankARM, // 0x05 - wait4IRQ, // 0x06 - sleep, // 0x07 - SoundBias, // 0x08 - divide, // 0x09 - bios_nop, // 0x0A - copy, // 0x0B - fastCopy, // 0x0C - bios_sqrt, // 0x0D - getCRC16, // 0x0E - isDebugger, // 0x0F - BitUnPack, // 0x10 - LZ77UnCompWram, // 0x11 - LZ77UnCompVram, // 0x12 - UnCompHuffman, // 0x13 - RLUnCompWram, // 0x14 - RLUnCompVram, // 0x15 - Diff8bitUnFilterWram, // 0x16 - bios_nop, // 0x17 - bios_nop, // 0x18 - bios_nop, // 0x19 - getSineTab, // 0x1A - getPitchTab, // 0x1B - getVolumeTab, // 0x1C - getBootProcs, // 0x1D - bios_nop, // 0x1E - setHaltCR, // 0x1F -}; +/* Copyright (C) 2006 yopyop + yopyop156@ifrance.com + yopyop156.ifrance.com + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#include "cp15.h" +#include +#include "MMU.h" +#include "SPU.h" +#include "debug.h" + +#define cpu (&ARMPROC) +#define TEMPLATE template + +extern BOOL execute; + +static const u16 getsinetbl[] = { +0x0000, 0x0324, 0x0648, 0x096A, 0x0C8C, 0x0FAB, 0x12C8, 0x15E2, +0x18F9, 0x1C0B, 0x1F1A, 0x2223, 0x2528, 0x2826, 0x2B1F, 0x2E11, +0x30FB, 0x33DF, 0x36BA, 0x398C, 0x3C56, 0x3F17, 0x41CE, 0x447A, +0x471C, 0x49B4, 0x4C3F, 0x4EBF, 0x5133, 0x539B, 0x55F5, 0x5842, +0x5A82, 0x5CB3, 0x5ED7, 0x60EB, 0x62F1, 0x64E8, 0x66CF, 0x68A6, +0x6A6D, 0x6C23, 0x6DC9, 0x6F5E, 0x70E2, 0x7254, 0x73B5, 0x7504, +0x7641, 0x776B, 0x7884, 0x7989, 0x7A7C, 0x7B5C, 0x7C29, 0x7CE3, +0x7D89, 0x7E1D, 0x7E9C, 0x7F09, 0x7F61, 0x7FA6, 0x7FD8, 0x7FF5 +}; + +static const u16 getpitchtbl[] = { +0x0000, 0x003B, 0x0076, 0x00B2, 0x00ED, 0x0128, 0x0164, 0x019F, +0x01DB, 0x0217, 0x0252, 0x028E, 0x02CA, 0x0305, 0x0341, 0x037D, +0x03B9, 0x03F5, 0x0431, 0x046E, 0x04AA, 0x04E6, 0x0522, 0x055F, +0x059B, 0x05D8, 0x0614, 0x0651, 0x068D, 0x06CA, 0x0707, 0x0743, +0x0780, 0x07BD, 0x07FA, 0x0837, 0x0874, 0x08B1, 0x08EF, 0x092C, +0x0969, 0x09A7, 0x09E4, 0x0A21, 0x0A5F, 0x0A9C, 0x0ADA, 0x0B18, +0x0B56, 0x0B93, 0x0BD1, 0x0C0F, 0x0C4D, 0x0C8B, 0x0CC9, 0x0D07, +0x0D45, 0x0D84, 0x0DC2, 0x0E00, 0x0E3F, 0x0E7D, 0x0EBC, 0x0EFA, +0x0F39, 0x0F78, 0x0FB6, 0x0FF5, 0x1034, 0x1073, 0x10B2, 0x10F1, +0x1130, 0x116F, 0x11AE, 0x11EE, 0x122D, 0x126C, 0x12AC, 0x12EB, +0x132B, 0x136B, 0x13AA, 0x13EA, 0x142A, 0x146A, 0x14A9, 0x14E9, +0x1529, 0x1569, 0x15AA, 0x15EA, 0x162A, 0x166A, 0x16AB, 0x16EB, +0x172C, 0x176C, 0x17AD, 0x17ED, 0x182E, 0x186F, 0x18B0, 0x18F0, +0x1931, 0x1972, 0x19B3, 0x19F5, 0x1A36, 0x1A77, 0x1AB8, 0x1AFA, +0x1B3B, 0x1B7D, 0x1BBE, 0x1C00, 0x1C41, 0x1C83, 0x1CC5, 0x1D07, +0x1D48, 0x1D8A, 0x1DCC, 0x1E0E, 0x1E51, 0x1E93, 0x1ED5, 0x1F17, +0x1F5A, 0x1F9C, 0x1FDF, 0x2021, 0x2064, 0x20A6, 0x20E9, 0x212C, +0x216F, 0x21B2, 0x21F5, 0x2238, 0x227B, 0x22BE, 0x2301, 0x2344, +0x2388, 0x23CB, 0x240E, 0x2452, 0x2496, 0x24D9, 0x251D, 0x2561, +0x25A4, 0x25E8, 0x262C, 0x2670, 0x26B4, 0x26F8, 0x273D, 0x2781, +0x27C5, 0x280A, 0x284E, 0x2892, 0x28D7, 0x291C, 0x2960, 0x29A5, +0x29EA, 0x2A2F, 0x2A74, 0x2AB9, 0x2AFE, 0x2B43, 0x2B88, 0x2BCD, +0x2C13, 0x2C58, 0x2C9D, 0x2CE3, 0x2D28, 0x2D6E, 0x2DB4, 0x2DF9, +0x2E3F, 0x2E85, 0x2ECB, 0x2F11, 0x2F57, 0x2F9D, 0x2FE3, 0x302A, +0x3070, 0x30B6, 0x30FD, 0x3143, 0x318A, 0x31D0, 0x3217, 0x325E, +0x32A5, 0x32EC, 0x3332, 0x3379, 0x33C1, 0x3408, 0x344F, 0x3496, +0x34DD, 0x3525, 0x356C, 0x35B4, 0x35FB, 0x3643, 0x368B, 0x36D3, +0x371A, 0x3762, 0x37AA, 0x37F2, 0x383A, 0x3883, 0x38CB, 0x3913, +0x395C, 0x39A4, 0x39ED, 0x3A35, 0x3A7E, 0x3AC6, 0x3B0F, 0x3B58, +0x3BA1, 0x3BEA, 0x3C33, 0x3C7C, 0x3CC5, 0x3D0E, 0x3D58, 0x3DA1, +0x3DEA, 0x3E34, 0x3E7D, 0x3EC7, 0x3F11, 0x3F5A, 0x3FA4, 0x3FEE, +0x4038, 0x4082, 0x40CC, 0x4116, 0x4161, 0x41AB, 0x41F5, 0x4240, +0x428A, 0x42D5, 0x431F, 0x436A, 0x43B5, 0x4400, 0x444B, 0x4495, +0x44E1, 0x452C, 0x4577, 0x45C2, 0x460D, 0x4659, 0x46A4, 0x46F0, +0x473B, 0x4787, 0x47D3, 0x481E, 0x486A, 0x48B6, 0x4902, 0x494E, +0x499A, 0x49E6, 0x4A33, 0x4A7F, 0x4ACB, 0x4B18, 0x4B64, 0x4BB1, +0x4BFE, 0x4C4A, 0x4C97, 0x4CE4, 0x4D31, 0x4D7E, 0x4DCB, 0x4E18, +0x4E66, 0x4EB3, 0x4F00, 0x4F4E, 0x4F9B, 0x4FE9, 0x5036, 0x5084, +0x50D2, 0x5120, 0x516E, 0x51BC, 0x520A, 0x5258, 0x52A6, 0x52F4, +0x5343, 0x5391, 0x53E0, 0x542E, 0x547D, 0x54CC, 0x551A, 0x5569, +0x55B8, 0x5607, 0x5656, 0x56A5, 0x56F4, 0x5744, 0x5793, 0x57E2, +0x5832, 0x5882, 0x58D1, 0x5921, 0x5971, 0x59C1, 0x5A10, 0x5A60, +0x5AB0, 0x5B01, 0x5B51, 0x5BA1, 0x5BF1, 0x5C42, 0x5C92, 0x5CE3, +0x5D34, 0x5D84, 0x5DD5, 0x5E26, 0x5E77, 0x5EC8, 0x5F19, 0x5F6A, +0x5FBB, 0x600D, 0x605E, 0x60B0, 0x6101, 0x6153, 0x61A4, 0x61F6, +0x6248, 0x629A, 0x62EC, 0x633E, 0x6390, 0x63E2, 0x6434, 0x6487, +0x64D9, 0x652C, 0x657E, 0x65D1, 0x6624, 0x6676, 0x66C9, 0x671C, +0x676F, 0x67C2, 0x6815, 0x6869, 0x68BC, 0x690F, 0x6963, 0x69B6, +0x6A0A, 0x6A5E, 0x6AB1, 0x6B05, 0x6B59, 0x6BAD, 0x6C01, 0x6C55, +0x6CAA, 0x6CFE, 0x6D52, 0x6DA7, 0x6DFB, 0x6E50, 0x6EA4, 0x6EF9, +0x6F4E, 0x6FA3, 0x6FF8, 0x704D, 0x70A2, 0x70F7, 0x714D, 0x71A2, +0x71F7, 0x724D, 0x72A2, 0x72F8, 0x734E, 0x73A4, 0x73FA, 0x7450, +0x74A6, 0x74FC, 0x7552, 0x75A8, 0x75FF, 0x7655, 0x76AC, 0x7702, +0x7759, 0x77B0, 0x7807, 0x785E, 0x78B4, 0x790C, 0x7963, 0x79BA, +0x7A11, 0x7A69, 0x7AC0, 0x7B18, 0x7B6F, 0x7BC7, 0x7C1F, 0x7C77, +0x7CCF, 0x7D27, 0x7D7F, 0x7DD7, 0x7E2F, 0x7E88, 0x7EE0, 0x7F38, +0x7F91, 0x7FEA, 0x8042, 0x809B, 0x80F4, 0x814D, 0x81A6, 0x81FF, +0x8259, 0x82B2, 0x830B, 0x8365, 0x83BE, 0x8418, 0x8472, 0x84CB, +0x8525, 0x857F, 0x85D9, 0x8633, 0x868E, 0x86E8, 0x8742, 0x879D, +0x87F7, 0x8852, 0x88AC, 0x8907, 0x8962, 0x89BD, 0x8A18, 0x8A73, +0x8ACE, 0x8B2A, 0x8B85, 0x8BE0, 0x8C3C, 0x8C97, 0x8CF3, 0x8D4F, +0x8DAB, 0x8E07, 0x8E63, 0x8EBF, 0x8F1B, 0x8F77, 0x8FD4, 0x9030, +0x908C, 0x90E9, 0x9146, 0x91A2, 0x91FF, 0x925C, 0x92B9, 0x9316, +0x9373, 0x93D1, 0x942E, 0x948C, 0x94E9, 0x9547, 0x95A4, 0x9602, +0x9660, 0x96BE, 0x971C, 0x977A, 0x97D8, 0x9836, 0x9895, 0x98F3, +0x9952, 0x99B0, 0x9A0F, 0x9A6E, 0x9ACD, 0x9B2C, 0x9B8B, 0x9BEA, +0x9C49, 0x9CA8, 0x9D08, 0x9D67, 0x9DC7, 0x9E26, 0x9E86, 0x9EE6, +0x9F46, 0x9FA6, 0xA006, 0xA066, 0xA0C6, 0xA127, 0xA187, 0xA1E8, +0xA248, 0xA2A9, 0xA30A, 0xA36B, 0xA3CC, 0xA42D, 0xA48E, 0xA4EF, +0xA550, 0xA5B2, 0xA613, 0xA675, 0xA6D6, 0xA738, 0xA79A, 0xA7FC, +0xA85E, 0xA8C0, 0xA922, 0xA984, 0xA9E7, 0xAA49, 0xAAAC, 0xAB0E, +0xAB71, 0xABD4, 0xAC37, 0xAC9A, 0xACFD, 0xAD60, 0xADC3, 0xAE27, +0xAE8A, 0xAEED, 0xAF51, 0xAFB5, 0xB019, 0xB07C, 0xB0E0, 0xB145, +0xB1A9, 0xB20D, 0xB271, 0xB2D6, 0xB33A, 0xB39F, 0xB403, 0xB468, +0xB4CD, 0xB532, 0xB597, 0xB5FC, 0xB662, 0xB6C7, 0xB72C, 0xB792, +0xB7F7, 0xB85D, 0xB8C3, 0xB929, 0xB98F, 0xB9F5, 0xBA5B, 0xBAC1, +0xBB28, 0xBB8E, 0xBBF5, 0xBC5B, 0xBCC2, 0xBD29, 0xBD90, 0xBDF7, +0xBE5E, 0xBEC5, 0xBF2C, 0xBF94, 0xBFFB, 0xC063, 0xC0CA, 0xC132, +0xC19A, 0xC202, 0xC26A, 0xC2D2, 0xC33A, 0xC3A2, 0xC40B, 0xC473, +0xC4DC, 0xC544, 0xC5AD, 0xC616, 0xC67F, 0xC6E8, 0xC751, 0xC7BB, +0xC824, 0xC88D, 0xC8F7, 0xC960, 0xC9CA, 0xCA34, 0xCA9E, 0xCB08, +0xCB72, 0xCBDC, 0xCC47, 0xCCB1, 0xCD1B, 0xCD86, 0xCDF1, 0xCE5B, +0xCEC6, 0xCF31, 0xCF9C, 0xD008, 0xD073, 0xD0DE, 0xD14A, 0xD1B5, +0xD221, 0xD28D, 0xD2F8, 0xD364, 0xD3D0, 0xD43D, 0xD4A9, 0xD515, +0xD582, 0xD5EE, 0xD65B, 0xD6C7, 0xD734, 0xD7A1, 0xD80E, 0xD87B, +0xD8E9, 0xD956, 0xD9C3, 0xDA31, 0xDA9E, 0xDB0C, 0xDB7A, 0xDBE8, +0xDC56, 0xDCC4, 0xDD32, 0xDDA0, 0xDE0F, 0xDE7D, 0xDEEC, 0xDF5B, +0xDFC9, 0xE038, 0xE0A7, 0xE116, 0xE186, 0xE1F5, 0xE264, 0xE2D4, +0xE343, 0xE3B3, 0xE423, 0xE493, 0xE503, 0xE573, 0xE5E3, 0xE654, +0xE6C4, 0xE735, 0xE7A5, 0xE816, 0xE887, 0xE8F8, 0xE969, 0xE9DA, +0xEA4B, 0xEABC, 0xEB2E, 0xEB9F, 0xEC11, 0xEC83, 0xECF5, 0xED66, +0xEDD9, 0xEE4B, 0xEEBD, 0xEF2F, 0xEFA2, 0xF014, 0xF087, 0xF0FA, +0xF16D, 0xF1E0, 0xF253, 0xF2C6, 0xF339, 0xF3AD, 0xF420, 0xF494, +0xF507, 0xF57B, 0xF5EF, 0xF663, 0xF6D7, 0xF74C, 0xF7C0, 0xF834, +0xF8A9, 0xF91E, 0xF992, 0xFA07, 0xFA7C, 0xFAF1, 0xFB66, 0xFBDC, +0xFC51, 0xFCC7, 0xFD3C, 0xFDB2, 0xFE28, 0xFE9E, 0xFF14, 0xFF8A +}; + +static const u8 getvoltbl[] = { +0x00, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, +0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, +0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, +0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, +0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, +0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, +0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, +0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, +0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x03, 0x03, 0x03, +0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, +0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x04, 0x04, 0x04, 0x04, 0x04, 0x04, +0x04, 0x04, 0x04, 0x04, 0x04, 0x04, 0x04, 0x04, 0x04, 0x04, 0x04, 0x04, 0x04, 0x04, 0x04, 0x04, +0x05, 0x05, 0x05, 0x05, 0x05, 0x05, 0x05, 0x05, 0x05, 0x05, 0x05, 0x05, 0x05, 0x05, 0x05, 0x05, +0x05, 0x06, 0x06, 0x06, 0x06, 0x06, 0x06, 0x06, 0x06, 0x06, 0x06, 0x06, 0x06, 0x06, 0x06, 0x06, +0x07, 0x07, 0x07, 0x07, 0x07, 0x07, 0x07, 0x07, 0x07, 0x07, 0x07, 0x07, 0x08, 0x08, 0x08, 0x08, +0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x09, 0x09, 0x09, 0x09, 0x09, 0x09, 0x09, 0x09, 0x09, +0x09, 0x0A, 0x0A, 0x0A, 0x0A, 0x0A, 0x0A, 0x0A, 0x0A, 0x0B, 0x0B, 0x0B, 0x0B, 0x0B, 0x0B, 0x0B, +0x0B, 0x0C, 0x0C, 0x0C, 0x0C, 0x0C, 0x0C, 0x0C, 0x0C, 0x0D, 0x0D, 0x0D, 0x0D, 0x0D, 0x0D, 0x0E, +0x0E, 0x0E, 0x0E, 0x0E, 0x0E, 0x0E, 0x0F, 0x0F, 0x0F, 0x0F, 0x0F, 0x10, 0x10, 0x10, 0x10, 0x10, +0x10, 0x11, 0x11, 0x11, 0x11, 0x11, 0x12, 0x12, 0x12, 0x12, 0x12, 0x13, 0x13, 0x13, 0x13, 0x14, +0x14, 0x14, 0x14, 0x14, 0x15, 0x15, 0x15, 0x15, 0x16, 0x16, 0x16, 0x16, 0x17, 0x17, 0x17, 0x18, +0x18, 0x18, 0x18, 0x19, 0x19, 0x19, 0x19, 0x1A, 0x1A, 0x1A, 0x1B, 0x1B, 0x1B, 0x1C, 0x1C, 0x1C, +0x1D, 0x1D, 0x1D, 0x1E, 0x1E, 0x1E, 0x1F, 0x1F, 0x1F, 0x20, 0x20, 0x20, 0x21, 0x21, 0x22, 0x22, +0x22, 0x23, 0x23, 0x24, 0x24, 0x24, 0x25, 0x25, 0x26, 0x26, 0x27, 0x27, 0x27, 0x28, 0x28, 0x29, +0x29, 0x2A, 0x2A, 0x2B, 0x2B, 0x2C, 0x2C, 0x2D, 0x2D, 0x2E, 0x2E, 0x2F, 0x2F, 0x30, 0x31, 0x31, +0x32, 0x32, 0x33, 0x33, 0x34, 0x35, 0x35, 0x36, 0x36, 0x37, 0x38, 0x38, 0x39, 0x3A, 0x3A, 0x3B, +0x3C, 0x3C, 0x3D, 0x3E, 0x3F, 0x3F, 0x40, 0x41, 0x42, 0x42, 0x43, 0x44, 0x45, 0x45, 0x46, 0x47, +0x48, 0x49, 0x4A, 0x4A, 0x4B, 0x4C, 0x4D, 0x4E, 0x4F, 0x50, 0x51, 0x52, 0x52, 0x53, 0x54, 0x55, +0x56, 0x57, 0x58, 0x59, 0x5A, 0x5B, 0x5D, 0x5E, 0x5F, 0x60, 0x61, 0x62, 0x63, 0x64, 0x65, 0x67, +0x68, 0x69, 0x6A, 0x6B, 0x6D, 0x6E, 0x6F, 0x71, 0x72, 0x73, 0x75, 0x76, 0x77, 0x79, 0x7A, 0x7B, +0x7D, 0x7E, 0x7F, 0x20, 0x21, 0x21, 0x21, 0x22, 0x22, 0x23, 0x23, 0x23, 0x24, 0x24, 0x25, 0x25, +0x26, 0x26, 0x26, 0x27, 0x27, 0x28, 0x28, 0x29, 0x29, 0x2A, 0x2A, 0x2B, 0x2B, 0x2C, 0x2C, 0x2D, +0x2D, 0x2E, 0x2E, 0x2F, 0x2F, 0x30, 0x30, 0x31, 0x31, 0x32, 0x33, 0x33, 0x34, 0x34, 0x35, 0x36, +0x36, 0x37, 0x37, 0x38, 0x39, 0x39, 0x3A, 0x3B, 0x3B, 0x3C, 0x3D, 0x3E, 0x3E, 0x3F, 0x40, 0x40, +0x41, 0x42, 0x43, 0x43, 0x44, 0x45, 0x46, 0x47, 0x47, 0x48, 0x49, 0x4A, 0x4B, 0x4C, 0x4D, 0x4D, +0x4E, 0x4F, 0x50, 0x51, 0x52, 0x53, 0x54, 0x55, 0x56, 0x57, 0x58, 0x59, 0x5A, 0x5B, 0x5C, 0x5D, +0x5E, 0x5F, 0x60, 0x62, 0x63, 0x64, 0x65, 0x66, 0x67, 0x69, 0x6A, 0x6B, 0x6C, 0x6D, 0x6F, 0x70, +0x71, 0x73, 0x74, 0x75, 0x77, 0x78, 0x79, 0x7B, 0x7C, 0x7E, 0x7E, 0x40, 0x41, 0x42, 0x43, 0x43, +0x44, 0x45, 0x46, 0x47, 0x47, 0x48, 0x49, 0x4A, 0x4B, 0x4C, 0x4C, 0x4D, 0x4E, 0x4F, 0x50, 0x51, +0x52, 0x53, 0x54, 0x55, 0x56, 0x57, 0x58, 0x59, 0x5A, 0x5B, 0x5C, 0x5D, 0x5E, 0x5F, 0x60, 0x61, +0x62, 0x64, 0x65, 0x66, 0x67, 0x68, 0x69, 0x6B, 0x6C, 0x6D, 0x6E, 0x70, 0x71, 0x72, 0x74, 0x75, +0x76, 0x78, 0x79, 0x7B, 0x7C, 0x7D, 0x7E, 0x40, 0x41, 0x42, 0x42, 0x43, 0x44, 0x45, 0x46, 0x46, +0x47, 0x48, 0x49, 0x4A, 0x4B, 0x4B, 0x4C, 0x4D, 0x4E, 0x4F, 0x50, 0x51, 0x52, 0x53, 0x54, 0x55, +0x56, 0x57, 0x58, 0x59, 0x5A, 0x5B, 0x5C, 0x5D, 0x5E, 0x5F, 0x60, 0x61, 0x62, 0x63, 0x65, 0x66, +0x67, 0x68, 0x69, 0x6A, 0x6C, 0x6D, 0x6E, 0x6F, 0x71, 0x72, 0x73, 0x75, 0x76, 0x77, 0x79, 0x7A, +0x7C, 0x7D, 0x7E, 0x7F +}; + +TEMPLATE static u32 bios_nop() +{ + if (cpu->proc_ID == ARMCPU_ARM9) + { + LOG("Unimplemented bios function %02X(ARM9) was used. R0:%08X\n", (cpu->instruction)&0x1F, cpu->R[0]); + } + else + { + LOG("Unimplemented bios function %02X(ARM7) was used. R0:%08X\n", (cpu->instruction)&0x1F, cpu->R[0]); + } + return 3; +} + +TEMPLATE static u32 delayLoop() +{ + return cpu->R[0] * 4; +} + +//u32 oldmode[2]; + +TEMPLATE u32 intrWaitARM() +{ + u32 intrFlagAdr;// = (((armcp15_t *)(cpu->coproc[15]))->DTCMRegion&0xFFFFF000)+0x3FF8; + u32 intr; + u32 intrFlag = 0; + + BOOL noDiscard = ((cpu->R[0] == 0) && (PROCNUM == 1)); + + //emu_halt(); + if(cpu->proc_ID) + { + intrFlagAdr = 0x380FFF8; + } else { + intrFlagAdr = (((armcp15_t *)(cpu->coproc[15]))->DTCMRegion&0xFFFFF000)+0x3FF8; + } + intr = _MMU_read32(intrFlagAdr); + intrFlag = (cpu->R[1] & intr); + + if(!noDiscard) + intrFlag &= ARMPROC.newIrqFlags; + + if(intrFlag) + { + // si une(ou plusieurs) des interruptions que l'on attend s'est(se sont) produite(s) + // on efface son(les) occurence(s). + intr ^= intrFlag; + cpu->newIrqFlags ^= intrFlag; + _MMU_write32(intrFlagAdr, intr); + //cpu->switchMode(oldmode[cpu->proc_ID]); + return 1; + } + + cpu->R[15] = cpu->instruct_adr; + cpu->next_instruction = cpu->R[15]; + cpu->waitIRQ = 1; + //oldmode[cpu->proc_ID] = cpu->switchMode(SVC); + + return 1; +} + +TEMPLATE static u32 waitVBlankARM() +{ + cpu->R[0] = 1; + cpu->R[1] = 1; + return intrWaitARM(); +#if 0 + u32 intrFlagAdr;// = (((armcp15_t *)(cpu->coproc[15]))->DTCMRegion&0xFFFFF000)+0x3FF8; + u32 intr; + u32 intrFlag = 0; + + //emu_halt(); + if(cpu->proc_ID) + { + intrFlagAdr = 0x380FFF8; + } else { + intrFlagAdr = (((armcp15_t *)(cpu->coproc[15]))->DTCMRegion&0xFFFFF000)+0x3FF8; + } + intr = _MMU_read32(intrFlagAdr); + intrFlag = 1 & intr; + + // if(intrFlag) + { + // si une(ou plusieurs) des interruptions que l'on attend s'est(se sont) produite(s) + // on efface son(les) occurence(s). + intr ^= intrFlag; + _MMU_write32(intrFlagAdr, intr); + //cpu->switchMode(oldmode[cpu->proc_ID]); + return 1; + } + + cpu->R[15] = cpu->instruct_adr; + cpu->next_instruction = cpu->R[15]; + cpu->waitIRQ = 1; + //oldmode[cpu->proc_ID] = cpu->switchMode(SVC); + + return 1; +#endif +} + +TEMPLATE static u32 wait4IRQ() +{ + //execute= FALSE; + if(cpu->wirq) + { + if(!cpu->waitIRQ) + { + cpu->waitIRQ = 0; + cpu->wirq = 0; + //cpu->switchMode(oldmode[cpu->proc_ID]); + return 1; + } + cpu->R[15] = cpu->instruct_adr; + cpu->next_instruction = cpu->R[15]; + return 1; + } + cpu->waitIRQ = 1; + cpu->wirq = 1; + cpu->R[15] = cpu->instruct_adr; + cpu->next_instruction = cpu->R[15]; + //oldmode[cpu->proc_ID] = cpu->switchMode(SVC); + return 1; +} + +TEMPLATE static u32 sleep() +{ + _MMU_write08(0x04000301, 0xC0); + return 1; +} + +TEMPLATE static u32 divide() +{ + s32 num = (s32)cpu->R[0]; + s32 dnum = (s32)cpu->R[1]; + + if(dnum==0) return 0; + + cpu->R[0] = (u32)(num / dnum); + cpu->R[1] = (u32)(num % dnum); + cpu->R[3] = (u32) (((s32)cpu->R[0])<0 ? -cpu->R[0] : cpu->R[0]); + + return 6; +} + +TEMPLATE static u32 copy() +{ + u32 src = cpu->R[0]; + u32 dst = cpu->R[1]; + u32 cnt = cpu->R[2]; + + //INFO("swi copy from %08X to %08X, cnt=%08X\n", src, dst, cnt); + + switch(BIT26(cnt)) + { + case 0: + src &= 0xFFFFFFFE; + dst &= 0xFFFFFFFE; + switch(BIT24(cnt)) + { + case 0: + cnt &= 0x1FFFFF; + while(cnt) + { + _MMU_write16(dst, _MMU_read16(src)); + cnt--; + dst+=2; + src+=2; + } + break; + case 1: + { + u32 val = _MMU_read16(src); + cnt &= 0x1FFFFF; + while(cnt) + { + _MMU_write16(dst, val); + cnt--; + dst+=2; + } + } + break; + } + break; + case 1: + src &= 0xFFFFFFFC; + dst &= 0xFFFFFFFC; + switch(BIT24(cnt)) + { + case 0: + cnt &= 0x1FFFFF; + while(cnt) + { + _MMU_write32(dst, _MMU_read32(src)); + cnt--; + dst+=4; + src+=4; + } + break; + case 1: + { + u32 val = _MMU_read32(src); + cnt &= 0x1FFFFF; + while(cnt) + { + _MMU_write32(dst, val); + cnt--; + dst+=4; + } + } + break; + } + break; + } + return 1; +} + +TEMPLATE static u32 fastCopy() +{ + u32 src = cpu->R[0] & 0xFFFFFFFC; + u32 dst = cpu->R[1] & 0xFFFFFFFC; + u32 cnt = cpu->R[2]; + + //INFO("swi fastcopy from %08X to %08X, cnt=%08X\n", src, dst, cnt); + + switch(BIT24(cnt)) + { + case 0: + cnt &= 0x1FFFFF; + while(cnt) + { + _MMU_write32(dst, _MMU_read32(src)); + cnt--; + dst+=4; + src+=4; + } + break; + case 1: + { + u32 val = _MMU_read32(src); + cnt &= 0x1FFFFF; + while(cnt) + { + _MMU_write32(dst, val); + cnt--; + dst+=4; + } + } + break; + } + return 1; +} + +TEMPLATE static u32 LZ77UnCompVram() +{ + int i1, i2; + int byteCount; + int byteShift; + u32 writeValue; + int len; + u32 source = cpu->R[0]; + u32 dest = cpu->R[1]; + u32 header = _MMU_read32(source); + source += 4; + + //INFO("swi lz77uncompvram\n"); + + if(((source & 0xe000000) == 0) || + ((source + ((header >> 8) & 0x1fffff)) & 0xe000000) == 0) + return 0; + + byteCount = 0; + byteShift = 0; + writeValue = 0; + + len = header >> 8; + + while(len > 0) { + u8 d = _MMU_read08(source++); + + if(d) { + for(i1 = 0; i1 < 8; i1++) { + if(d & 0x80) { + int length; + int offset; + u32 windowOffset; + u16 data = _MMU_read08(source++) << 8; + data |= _MMU_read08(source++); + length = (data >> 12) + 3; + offset = (data & 0x0FFF); + windowOffset = dest + byteCount - offset - 1; + for(i2 = 0; i2 < length; i2++) { + writeValue |= (_MMU_read08(windowOffset++) << byteShift); + byteShift += 8; + byteCount++; + + if(byteCount == 2) { + _MMU_write16(dest, writeValue); + dest += 2; + byteCount = 0; + byteShift = 0; + writeValue = 0; + } + len--; + if(len == 0) + return 0; + } + } else { + writeValue |= (_MMU_read08(source++) << byteShift); + byteShift += 8; + byteCount++; + if(byteCount == 2) { + _MMU_write16(dest, writeValue); + dest += 2; + byteCount = 0; + byteShift = 0; + writeValue = 0; + } + len--; + if(len == 0) + return 0; + } + d <<= 1; + } + } else { + for(i1 = 0; i1 < 8; i1++) { + writeValue |= (_MMU_read08(source++) << byteShift); + byteShift += 8; + byteCount++; + if(byteCount == 2) { + _MMU_write16(dest, writeValue); + dest += 2; + byteShift = 0; + byteCount = 0; + writeValue = 0; + } + len--; + if(len == 0) + return 0; + } + } + } + return 1; +} + +TEMPLATE static u32 LZ77UnCompWram() +{ + int i1, i2; + int len; + u32 source = cpu->R[0]; + u32 dest = cpu->R[1]; + + u32 header = _MMU_read32(source); + source += 4; + + //INFO("swi lz77uncompwram\n"); + + if(((source & 0xe000000) == 0) || + ((source + ((header >> 8) & 0x1fffff)) & 0xe000000) == 0) + return 0; + + len = header >> 8; + + while(len > 0) { + u8 d = _MMU_read08(source++); + + if(d) { + for(i1 = 0; i1 < 8; i1++) { + if(d & 0x80) { + int length; + int offset; + u32 windowOffset; + u16 data = _MMU_read08(source++) << 8; + data |= _MMU_read08(source++); + length = (data >> 12) + 3; + offset = (data & 0x0FFF); + windowOffset = dest - offset - 1; + for(i2 = 0; i2 < length; i2++) { + _MMU_write08(dest++, _MMU_read08(windowOffset++)); + len--; + if(len == 0) + return 0; + } + } else { + _MMU_write08(dest++, _MMU_read08(source++)); + len--; + if(len == 0) + return 0; + } + d <<= 1; + } + } else { + for(i1 = 0; i1 < 8; i1++) { + _MMU_write08(dest++, _MMU_read08(source++)); + len--; + if(len == 0) + return 0; + } + } + } + return 1; +} + +TEMPLATE static u32 RLUnCompVram() +{ + int i; + int len; + int byteCount; + int byteShift; + u32 writeValue; + u32 source = cpu->R[0]; + u32 dest = cpu->R[1]; + + u32 header = _MMU_read32(source); + source += 4; + + //INFO("swi rluncompvram\n"); + + if(((source & 0xe000000) == 0) || + ((source + ((header >> 8) & 0x1fffff)) & 0xe000000) == 0) + return 0; + + len = header >> 8; + byteCount = 0; + byteShift = 0; + writeValue = 0; + + while(len > 0) { + u8 d = _MMU_read08(source++); + int l = d & 0x7F; + if(d & 0x80) { + u8 data = _MMU_read08(source++); + l += 3; + for(i = 0;i < l; i++) { + writeValue |= (data << byteShift); + byteShift += 8; + byteCount++; + + if(byteCount == 2) { + _MMU_write16(dest, writeValue); + dest += 2; + byteCount = 0; + byteShift = 0; + writeValue = 0; + } + len--; + if(len == 0) + return 0; + } + } else { + l++; + for(i = 0; i < l; i++) { + writeValue |= (_MMU_read08(source++) << byteShift); + byteShift += 8; + byteCount++; + if(byteCount == 2) { + _MMU_write16(dest, writeValue); + dest += 2; + byteCount = 0; + byteShift = 0; + writeValue = 0; + } + len--; + if(len == 0) + return 0; + } + } + } + return 1; +} + +TEMPLATE static u32 RLUnCompWram() +{ + int i; + int len; + u32 source = cpu->R[0]; + u32 dest = cpu->R[1]; + + u32 header = _MMU_read32(source); + source += 4; + + //INFO("swi rluncompwram\n"); + + if(((source & 0xe000000) == 0) || + ((source + ((header >> 8) & 0x1fffff)) & 0xe000000) == 0) + return 0; + + len = header >> 8; + + while(len > 0) { + u8 d = _MMU_read08(source++); + int l = d & 0x7F; + if(d & 0x80) { + u8 data = _MMU_read08(source++); + l += 3; + for(i = 0;i < l; i++) { + _MMU_write08(dest++, data); + len--; + if(len == 0) + return 0; + } + } else { + l++; + for(i = 0; i < l; i++) { + _MMU_write08(dest++, _MMU_read08(source++)); + len--; + if(len == 0) + return 0; + } + } + } + return 1; +} + +TEMPLATE static u32 UnCompHuffman() +{ + u32 source, dest, writeValue, header, treeStart, mask; + u32 data; + u8 treeSize, currentNode, rootNode; + int byteCount, byteShift, len, pos; + int writeData; + + source = cpu->R[0]; + dest = cpu->R[1]; + + header = _MMU_read08(source); + source += 4; + + //INFO("swi uncomphuffman\n"); + + if(((source & 0xe000000) == 0) || + ((source + ((header >> 8) & 0x1fffff)) & 0xe000000) == 0) + return 0; + + treeSize = _MMU_read08(source++); + + treeStart = source; + + source += ((treeSize+1)<<1)-1; // minus because we already skipped one byte + + len = header >> 8; + + mask = 0x80000000; + data = _MMU_read08(source); + source += 4; + + pos = 0; + rootNode = _MMU_read08(treeStart); + currentNode = rootNode; + writeData = 0; + byteShift = 0; + byteCount = 0; + writeValue = 0; + + if((header & 0x0F) == 8) { + while(len > 0) { + // take left + if(pos == 0) + pos++; + else + pos += (((currentNode & 0x3F)+1)<<1); + + if(data & mask) { + // right + if(currentNode & 0x40) + writeData = 1; + currentNode = _MMU_read08(treeStart+pos+1); + } else { + // left + if(currentNode & 0x80) + writeData = 1; + currentNode = _MMU_read08(treeStart+pos); + } + + if(writeData) { + writeValue |= (currentNode << byteShift); + byteCount++; + byteShift += 8; + + pos = 0; + currentNode = rootNode; + writeData = 0; + + if(byteCount == 4) { + byteCount = 0; + byteShift = 0; + _MMU_write08(dest, writeValue); + writeValue = 0; + dest += 4; + len -= 4; + } + } + mask >>= 1; + if(mask == 0) { + mask = 0x80000000; + data = _MMU_read08(source); + source += 4; + } + } + } else { + int halfLen = 0; + int value = 0; + while(len > 0) { + // take left + if(pos == 0) + pos++; + else + pos += (((currentNode & 0x3F)+1)<<1); + + if((data & mask)) { + // right + if(currentNode & 0x40) + writeData = 1; + currentNode = _MMU_read08(treeStart+pos+1); + } else { + // left + if(currentNode & 0x80) + writeData = 1; + currentNode = _MMU_read08(treeStart+pos); + } + + if(writeData) { + if(halfLen == 0) + value |= currentNode; + else + value |= (currentNode<<4); + + halfLen += 4; + if(halfLen == 8) { + writeValue |= (value << byteShift); + byteCount++; + byteShift += 8; + + halfLen = 0; + value = 0; + + if(byteCount == 4) { + byteCount = 0; + byteShift = 0; + _MMU_write08(dest, writeValue); + dest += 4; + writeValue = 0; + len -= 4; + } + } + pos = 0; + currentNode = rootNode; + writeData = 0; + } + mask >>= 1; + if(mask == 0) { + mask = 0x80000000; + data = _MMU_read08(source); + source += 4; + } + } + } + return 1; +} + +TEMPLATE static u32 BitUnPack() +{ + u32 source,dest,header,base,d,temp; + int len,bits,revbits,dataSize,data,bitwritecount,mask,bitcount,addBase; + u8 b; + + source = cpu->R[0]; + dest = cpu->R[1]; + header = cpu->R[2]; + + //INFO("swi bitunpack\n"); + + len = _MMU_read16(header); + // check address + bits = _MMU_read08(header+2); + revbits = 8 - bits; + // u32 value = 0; + base = _MMU_read08(header+4); + addBase = (base & 0x80000000) ? 1 : 0; + base &= 0x7fffffff; + dataSize = _MMU_read08(header+3); + + data = 0; + bitwritecount = 0; + while(1) { + len -= 1; + if(len < 0) + break; + mask = 0xff >> revbits; + b = _MMU_read08(source); + source++; + bitcount = 0; + while(1) { + if(bitcount >= 8) + break; + d = b & mask; + temp = d >> bitcount; + if(!temp && addBase) { + temp += base; + } + data |= temp << bitwritecount; + bitwritecount += dataSize; + if(bitwritecount >= 32) { + _MMU_write08(dest, data); + dest += 4; + data = 0; + bitwritecount = 0; + } + mask <<= bits; + bitcount += bits; + } + } + return 1; +} + +TEMPLATE static u32 Diff8bitUnFilterWram() +{ + u32 source,dest,header; + u8 data,diff; + int len; + + source = cpu->R[0]; + dest = cpu->R[1]; + + header = _MMU_read08(source); + source += 4; + + //INFO("swi diff8bitunfilterwram\n"); + + if(((source & 0xe000000) == 0) || + (( (source + ((header >> 8) & 0x1fffff)) & 0xe000000) == 0)) + return 0; + + len = header >> 8; + + data = _MMU_read08(source++); + _MMU_write08(dest++, data); + len--; + + while(len > 0) { + diff = _MMU_read08(source++); + data += diff; + _MMU_write08(dest++, data); + len--; + } + return 1; +} + +TEMPLATE static u32 Diff16bitUnFilter() +{ + u32 source,dest,header; + u16 data; + int len; + + source = cpu->R[0]; + dest = cpu->R[1]; + + //INFO("swi diff16bitunfilter\n"); + + header = _MMU_read08(source); + source += 4; + + if(((source & 0xe000000) == 0) || + ((source + ((header >> 8) & 0x1fffff)) & 0xe000000) == 0) + return 0; + + len = header >> 8; + + data = _MMU_read16(source); + source += 2; + _MMU_write16(dest, data); + dest += 2; + len -= 2; + + while(len >= 2) { + u16 diff = _MMU_read16(source); + source += 2; + data += diff; + _MMU_write16(dest, data); + dest += 2; + len -= 2; + } + return 1; +} + +TEMPLATE static u32 bios_sqrt() +{ + cpu->R[0] = (u32)sqrt((double)(cpu->R[0])); + return 1; +} + +TEMPLATE static u32 setHaltCR() +{ + _MMU_write08(0x4000300+cpu->proc_ID, cpu->R[0]); + return 1; +} + +TEMPLATE static u32 getSineTab() +{ + cpu->R[0] = getsinetbl[cpu->R[0]]; + return 1; +} + +TEMPLATE static u32 getPitchTab() +{ + cpu->R[0] = getpitchtbl[cpu->R[0]]; + return 1; +} + +TEMPLATE static u32 getVolumeTab() +{ + cpu->R[0] = getvoltbl[cpu->R[0]]; + return 1; +} + +TEMPLATE static u32 getCRC16() +{ + unsigned int i,j; + + u32 crc = cpu->R[0]; + u32 datap = cpu->R[1]; + u32 size = cpu->R[2]; + + const u16 val[] = { 0xC0C1,0xC181,0xC301,0xC601,0xCC01,0xD801,0xF001,0xA001 }; + for(i = 0; i < size; i++) + { + crc = crc ^ _MMU_read08(datap + i); + + for(j = 0; j < 8; j++) { + int do_bit = 0; + + if ( crc & 0x1) + do_bit = 1; + + crc = crc >> 1; + + if ( do_bit) { + crc = crc ^ (val[j] << (7-j)); + } + } + } + cpu->R[0] = crc; + return 1; +} + +TEMPLATE static u32 isDebugger() +{ + //gbatek has additional specifications which are not emulated here +#ifdef DEVELOPER + cpu->R[0] = 1; +#else + cpu->R[0] = 0; +#endif + return 1; +} + +TEMPLATE static u32 SoundBias() +{ + u32 current = SPU_ReadLong(0x4000504); + if (cpu->R[0] > current) + SPU_WriteLong(0x4000504, current + 0x1); + else + SPU_WriteLong(0x4000504, current - 0x1); + return cpu->R[1]; +} + +TEMPLATE static u32 getBootProcs() +{ + cpu->R[0] = 0x00000A2E; + cpu->R[1] = 0x00002C3C; + cpu->R[3] = 0x000005FF; + return 1; +} + +u32 (* ARM9_swi_tab[32])()={ + bios_nop, // 0x00 + bios_nop, // 0x01 + bios_nop, // 0x02 + delayLoop, // 0x03 + intrWaitARM, // 0x04 + waitVBlankARM, // 0x05 + wait4IRQ, // 0x06 + bios_nop, // 0x07 + bios_nop, // 0x08 + divide, // 0x09 + bios_nop, // 0x0A + copy, // 0x0B + fastCopy, // 0x0C + bios_sqrt, // 0x0D + getCRC16, // 0x0E + isDebugger, // 0x0F + BitUnPack, // 0x10 + LZ77UnCompWram, // 0x11 + LZ77UnCompVram, // 0x12 + UnCompHuffman, // 0x13 + RLUnCompWram, // 0x14 + RLUnCompVram, // 0x15 + Diff8bitUnFilterWram, // 0x16 + bios_nop, // 0x17 + Diff16bitUnFilter, // 0x18 + bios_nop, // 0x19 + bios_nop, // 0x1A + bios_nop, // 0x1B + bios_nop, // 0x1C + bios_nop, // 0x1D + bios_nop, // 0x1E + setHaltCR, // 0x1F +}; + +u32 (* ARM7_swi_tab[32])()={ + bios_nop, // 0x00 + bios_nop, // 0x01 + bios_nop, // 0x02 + delayLoop, // 0x03 + intrWaitARM, // 0x04 + waitVBlankARM, // 0x05 + wait4IRQ, // 0x06 + sleep, // 0x07 + SoundBias, // 0x08 + divide, // 0x09 + bios_nop, // 0x0A + copy, // 0x0B + fastCopy, // 0x0C + bios_sqrt, // 0x0D + getCRC16, // 0x0E + isDebugger, // 0x0F + BitUnPack, // 0x10 + LZ77UnCompWram, // 0x11 + LZ77UnCompVram, // 0x12 + UnCompHuffman, // 0x13 + RLUnCompWram, // 0x14 + RLUnCompVram, // 0x15 + Diff8bitUnFilterWram, // 0x16 + bios_nop, // 0x17 + bios_nop, // 0x18 + bios_nop, // 0x19 + getSineTab, // 0x1A + getPitchTab, // 0x1B + getVolumeTab, // 0x1C + getBootProcs, // 0x1D + bios_nop, // 0x1E + setHaltCR, // 0x1F +}; diff --git a/desmume/src/bios.h b/src/bios.h similarity index 96% rename from desmume/src/bios.h rename to src/bios.h index f7107fa2c..35471448d 100644 --- a/desmume/src/bios.h +++ b/src/bios.h @@ -1,31 +1,31 @@ -/* Copyright (C) 2006 yopyop - yopyop156@ifrance.com - yopyop156.ifrance.com - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#ifndef BIOS_H -#define BIOS_H - -#include "armcpu.h" - -extern u32 (* ARM9_swi_tab[32])(); -extern u32 (* ARM7_swi_tab[32])(); - -#endif - +/* Copyright (C) 2006 yopyop + yopyop156@ifrance.com + yopyop156.ifrance.com + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#ifndef BIOS_H +#define BIOS_H + +#include "armcpu.h" + +extern u32 (* ARM9_swi_tab[32])(); +extern u32 (* ARM7_swi_tab[32])(); + +#endif + diff --git a/desmume/src/bits.h b/src/bits.h similarity index 96% rename from desmume/src/bits.h rename to src/bits.h index be64f65d7..9259573a0 100644 --- a/desmume/src/bits.h +++ b/src/bits.h @@ -1,44 +1,44 @@ -#ifndef BITS_H -#define BITS_H - -#define BIT(n) (1<<(n)) - -#define BIT_N(i,n) (((i)>>(n))&1) -#define BIT0(i) ((i)&1) -#define BIT1(i) BIT_N(i,1) -#define BIT2(i) BIT_N(i,2) -#define BIT3(i) BIT_N(i,3) -#define BIT4(i) BIT_N(i,4) -#define BIT5(i) BIT_N(i,5) -#define BIT6(i) BIT_N(i,6) -#define BIT7(i) BIT_N(i,7) -#define BIT8(i) BIT_N(i,8) -#define BIT9(i) BIT_N(i,9) -#define BIT10(i) BIT_N(i,10) -#define BIT11(i) BIT_N(i,11) -#define BIT12(i) BIT_N(i,12) -#define BIT13(i) BIT_N(i,13) -#define BIT14(i) BIT_N(i,14) -#define BIT15(i) BIT_N(i,15) -#define BIT16(i) BIT_N(i,16) -#define BIT17(i) BIT_N(i,17) -#define BIT18(i) BIT_N(i,18) -#define BIT19(i) BIT_N(i,19) -#define BIT20(i) BIT_N(i,20) -#define BIT21(i) BIT_N(i,21) -#define BIT22(i) BIT_N(i,22) -#define BIT23(i) BIT_N(i,23) -#define BIT24(i) BIT_N(i,24) -#define BIT25(i) BIT_N(i,25) -#define BIT26(i) BIT_N(i,26) -#define BIT27(i) BIT_N(i,27) -#define BIT28(i) BIT_N(i,28) -#define BIT29(i) BIT_N(i,29) -#define BIT30(i) BIT_N(i,30) -#define BIT31(i) ((i)>>31) - -#define CONDITION(i) (i)>>28 - -#define REG_POS(i,n) (((i)>>n)&0xF) - -#endif +#ifndef BITS_H +#define BITS_H + +#define BIT(n) (1<<(n)) + +#define BIT_N(i,n) (((i)>>(n))&1) +#define BIT0(i) ((i)&1) +#define BIT1(i) BIT_N(i,1) +#define BIT2(i) BIT_N(i,2) +#define BIT3(i) BIT_N(i,3) +#define BIT4(i) BIT_N(i,4) +#define BIT5(i) BIT_N(i,5) +#define BIT6(i) BIT_N(i,6) +#define BIT7(i) BIT_N(i,7) +#define BIT8(i) BIT_N(i,8) +#define BIT9(i) BIT_N(i,9) +#define BIT10(i) BIT_N(i,10) +#define BIT11(i) BIT_N(i,11) +#define BIT12(i) BIT_N(i,12) +#define BIT13(i) BIT_N(i,13) +#define BIT14(i) BIT_N(i,14) +#define BIT15(i) BIT_N(i,15) +#define BIT16(i) BIT_N(i,16) +#define BIT17(i) BIT_N(i,17) +#define BIT18(i) BIT_N(i,18) +#define BIT19(i) BIT_N(i,19) +#define BIT20(i) BIT_N(i,20) +#define BIT21(i) BIT_N(i,21) +#define BIT22(i) BIT_N(i,22) +#define BIT23(i) BIT_N(i,23) +#define BIT24(i) BIT_N(i,24) +#define BIT25(i) BIT_N(i,25) +#define BIT26(i) BIT_N(i,26) +#define BIT27(i) BIT_N(i,27) +#define BIT28(i) BIT_N(i,28) +#define BIT29(i) BIT_N(i,29) +#define BIT30(i) BIT_N(i,30) +#define BIT31(i) ((i)>>31) + +#define CONDITION(i) (i)>>28 + +#define REG_POS(i,n) (((i)>>n)&0xF) + +#endif diff --git a/desmume/src/build.bat b/src/build.bat similarity index 100% rename from desmume/src/build.bat rename to src/build.bat diff --git a/src/cflash.cpp b/src/cflash.cpp new file mode 100644 index 000000000..d3ceec0e5 --- /dev/null +++ b/src/cflash.cpp @@ -0,0 +1,880 @@ +/* Copyright (C) 2006 yopyop + yopyop156@ifrance.com + yopyop156.ifrance.com + + Copyright (C) 2006-2008 The DeSmuME Team + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +/* + CFLASH.C + CompactFlash/FAT emulation routines for DeSmuME + /Mic, 2006 + + Logical memory layout: + + ---------------------- + | MBR | + ---------------------- + | FAT | + ---------------------- + | Root entries | + ---------------------- + | Subdirectories | + ---------------------- + | File data | + ---------------------- + +*/ +#include "common.h" + +#ifndef EXPERIMENTAL_GBASLOT + +#include +#include +#include +#include + +#include +#include +#ifdef WIN32 +#include +#define OPEN_MODE _O_RDWR | _O_BINARY + +#define OPEN_FN _open +#define CLOSE_FN _close +#define LSEEK_FN _lseek +#define WRITE_FN _write +#define READ_FN _read +#else +#include +#define OPEN_MODE O_RDWR + +#define OPEN_FN open +#define CLOSE_FN close +#define LSEEK_FN lseek +#define WRITE_FN write +#define READ_FN read +#endif + +#include "types.h" +#include "fs.h" +#include "MMU.h" +#include "cflash.h" +#include "NDSSystem.h" +#include "debug.h" + +static int use_disk_image_file = 0; + +/* Set up addresses for GBAMP */ +#define CF_REG_DATA 0x9000000 +#define CF_REG_ERR 0x9020000 +#define CF_REG_SEC 0x9040000 +#define CF_REG_LBA1 0x9060000 +#define CF_REG_LBA2 0x9080000 +#define CF_REG_LBA3 0x90A0000 +#define CF_REG_LBA4 0x90C0000 +#define CF_REG_CMD 0x90E0000 +#define CF_REG_STS 0x98C0000 + +// CF Card commands +#define CF_CMD_LBA 0xE0 +#define CF_CMD_READ 0x20 +#define CF_CMD_WRITE 0x30 + + +static int disk_image = -1; +static off_t file_size; + +static u16 cf_reg_sts, cf_reg_lba1, cf_reg_lba2, + cf_reg_lba3, cf_reg_lba4, cf_reg_cmd; +static off_t currLBA; + +#define SECPERFAT 128 +#define SECPERCLUS 16 +#define MAXFILES 32768 +#define SECRESV 2 +#define NUMSECTORS 0x80000 +#define NUMCLUSTERS (NUMSECTORS/SECPERCLUS) +#define BYTESPERCLUS (512*SECPERCLUS) +#define DIRENTSPERCLUS ((BYTESPERCLUS)/32) + + +static BOOT_RECORD MBR; +static DIR_ENT *files,*dirEntries,**dirEntryPtr; +static FILE_INFO *fileLink,*dirEntryLink; +static u32 filesysFAT,filesysRootDir,filesysData; +static u16 FAT16[SECPERFAT*256]; +static u16 numExtraEntries[SECPERFAT*256]; +static DIR_ENT *extraDirEntries[SECPERFAT*256]; +static int numFiles,maxLevel,numRootFiles; +static int *dirEntriesInCluster, clusterNum, firstDirEntCluster, + lastDirEntCluster, lastFileDataCluster; +static char *sRomPath; +static int activeDirEnt=-1; +static u32 bufferStart; +static u32 fileStartLBA,fileEndLBA; +static u16 freadBuffer[256]; +static FILE * hFile; +static char fpath[255+1]; +static BOOL cflashDeviceEnabled = FALSE; + +static int lfn_checksum( void) { + int i; + u8 chk; + + chk = 0; + for (i=0; i < (NAME_LEN + EXT_LEN); i++) { + chk = ((chk & 1) ? 0x80 : 0) + (chk >> 1) + (i < NAME_LEN ? files[numFiles].name[i] : files[numFiles].ext[i - NAME_LEN]); + } + return chk; +} + + +static const int lfnPos[13] = {1,3,5,7,9,14,16,18,20,22,24,28,30}; + + +/* Add a DIR_ENT for the files */ +static void add_file(char *fname, FsEntry * entry, int fileLevel) { + int i,j,k,n; + u8 chk; + + if (numFiles < MAXFILES-1) { + if (strcmp(fname,"..") != 0) { + for (i=strlen(fname)-1; i>=0; i--) + if (fname[i]=='.') break; + if ((i==0)&&(strcmp(fname,".")==0)) i = 1; + if (i<0) i = strlen(fname); + for (j=0; j=strlen(fname)) break; + files[numFiles].ext[j] = fname[j+i+1]; + } + for (; j<3; j++) + files[numFiles].ext[j] = 0x20; + + fileLink[fileLevel].filesInDir += 1; + + // See if LFN entries need to be added + if (strlen(entry->cAlternateFileName)>0) { + char *p = NULL; + + chk = lfn_checksum(); + k = (strlen(entry->cFileName)/13) + (((strlen(entry->cFileName)%13)!=0)?1:0); + numFiles += k; + + fileLink[fileLevel].filesInDir += k; + + n = 0; + j = 13; + for (i=0; (size_t)icFileName); i++) { + if (j == 13) { + n++; + p = (char*)&files[numFiles-n].name[0]; + fileLink[numFiles-n].parent = fileLevel; + p[0] = n; + ((DIR_ENT*)p)->attrib = ATTRIB_LFN; + p[0xD] = chk; + j = 0; + } + *(p + lfnPos[j]) = entry->cFileName[i]; + *(p + lfnPos[j]+1) = 0; + j++; + } + for (; j<13; j++) { + *(p + lfnPos[j]) = entry->cFileName[i]; + *(p + lfnPos[j]+1) = 0; + } + if (p != NULL) + p[0] |= 0x40; // END + for (i=strlen(fname)-1; i>=0; i--) + if (fname[i]=='.') break; + if ((i==0)&&(strcmp(fname,".")==0)) i = 1; + if (i<0) i = strlen(fname); + for (j=0; j=strlen(fname)) break; + files[numFiles].ext[j] = fname[j+i+1]; + } + for (; j<3; j++) + files[numFiles].ext[j] = 0x20; + } + + files[numFiles].fileSize = entry->fileSize; + + if (entry->flags & FS_IS_DIR) { + if (strcmp(fname,".")==0) + fileLink[numFiles].level = maxLevel; + else + fileLink[numFiles].level = maxLevel+1; + files[numFiles].attrib = ATTRIB_DIR; + } else { + files[numFiles].attrib = 0; + } + + fileLink[numFiles].parent = fileLevel; + + numFiles++; + } else if (fileLevel > 0) { + fileLink[fileLevel].filesInDir += 1; + strncpy((char*)&files[numFiles].name[0],".. ",NAME_LEN); + strncpy((char*)&files[numFiles].ext[0]," ",EXT_LEN); + fileLink[numFiles].parent = fileLevel; + files[numFiles].attrib = 0x10; + numFiles++; + } + } +} + + +/* List all files and subdirectories recursively */ +static void list_files(const char *filepath) { + char DirSpec[255+1], SubDir[255+1]; + FsEntry entry; + void * hFind; + char *fname; + u32 dwError; + int fileLevel; + + maxLevel++; + fileLevel = maxLevel; + + strncpy(DirSpec, filepath, ARRAY_SIZE(DirSpec)); + DirSpec[255] = 0 ; /* hard limit the string here */ + + hFind = FsReadFirst(DirSpec, &entry); + if (hFind == NULL) + return; + + fname = (strlen(entry.cAlternateFileName)>0) ? entry.cAlternateFileName : entry.cFileName; + add_file(fname, &entry, fileLevel); + + while (FsReadNext(hFind, &entry) != 0) { + fname = (strlen(entry.cAlternateFileName)>0) ? entry.cAlternateFileName : entry.cFileName; + add_file(fname, &entry, fileLevel); + + if (numFiles==MAXFILES-1) + break; + + if ((entry.flags & FS_IS_DIR) && (strcmp(fname, ".")) && (strcmp(fname, ".."))) { + if (strlen(fname)+strlen(filepath)+2 < 256) { + sprintf(SubDir, "%s%c%s", filepath, FS_SEPARATOR, fname); + list_files(SubDir); + } + } + } + + dwError = FsError(); + FsClose(hFind); + if (dwError != FS_ERR_NO_MORE_FILES) + return; + + if (numFiles < MAXFILES) { + fileLink[numFiles].parent = fileLevel; + files[numFiles++].name[0] = 0; + } +} + + + +/* Set up the MBR, FAT and DIR_ENTs */ +static BOOL cflash_build_fat( void) { + int i,j,k,l, + clust,numClusters, + clusterNum2,rootCluster; + int fileLevel; + + numFiles = 0; + fileLevel = -1; + maxLevel = -1; + + sRomPath = pathToROM; + files = (DIR_ENT *) malloc(MAXFILES*sizeof(DIR_ENT)); + if (files == NULL) + return FALSE; + fileLink = (FILE_INFO *) malloc(MAXFILES*sizeof(FILE_INFO)); + if (fileLink == NULL) { + free(files); + return FALSE; + } + + for (i=0; i>8; + clust += l; + numClusters += l; + } + } else { + dirEntries[k-1].startCluster = clusterNum; + } + } + if (i==0) numRootFiles++; + dirEntriesInCluster[clusterNum]++; + if (dirEntriesInCluster[clusterNum]==256) { + clusterNum++; + } + } + } + clusterNum = clusterNum2 + ((fileLink[i].filesInDir)>>8) + 1; + numClusters++; + } + + // Free the file indexing buffer + free(files); + free(fileLink); + + // Set up the MBR + MBR.bytesPerSector = 512; + MBR.numFATs = 1; + /* replaced strcpy with strncpy. It doesnt matter here, as the strings are constant */ + /* but we should extingish all unrestricted strcpy,strcat from the project */ + strncpy((char*)&MBR.OEMName[0],"DESMUM",8); + strncpy((char*)&MBR.fat16.fileSysType[0],"FAT16 ",8); + MBR.reservedSectors = SECRESV; + MBR.numSectors = 524288; + MBR.numSectorsSmall = 0; + MBR.sectorsPerCluster = SECPERCLUS; + MBR.sectorsPerFAT = SECPERFAT; + MBR.rootEntries = 512; + MBR.fat16.signature = 0xAA55; + MBR.mediaDesc = 1; + + filesysFAT = 0 + MBR.reservedSectors; + filesysRootDir = filesysFAT + (MBR.numFATs * MBR.sectorsPerFAT); + filesysData = filesysRootDir + ((MBR.rootEntries * sizeof(DIR_ENT)) / 512); + + // Set up the cluster values for all subdirectories + clust = filesysData / SECPERCLUS; + firstDirEntCluster = clust; + for (i=1; i rootCluster) + dirEntries[i].startCluster += clust-rootCluster; + } + } + lastDirEntCluster = clust+numClusters-1; + + // Set up the cluster values for all files + clust += numClusters; //clusterNum; + for (i=0; i 0) { + if (dirEntries[i].startCluster+j < MAXFILES) + FAT16[dirEntries[i].startCluster+j] = dirEntries[i].startCluster+j+1; + j++; + l -= (512*16); + } + if ((dirEntries[i].attrib & ATTRIB_DIR)==0) { + if (dirEntries[i].startCluster+j < MAXFILES) + FAT16[dirEntries[i].startCluster+j] = 0xFFFF; + } + k = dirEntries[i].startCluster+j; + } + } + + for (i=(filesysData/SECPERCLUS); iname[i] == ' ') break; + out[i] = pd->name[i]; + } + if ((pd->attrib & 0x10)==0) { + out[i++] = '.'; + for (j=0; jext[j] == ' ') break; + out[i++] = pd->ext[j]; + } + } + out[i] = '\0'; +} + + + +/* Resolve the path of a files by working backwards through the directory entries */ +static void resolve_path(int dirent) { + int i; + char dirname[128]; + + while (dirEntryLink[dirent].parent > 0) { + for (i=0; i= bufferStart + 512)) { + if (!hFile) { + CFLASHLOG("fread_buffered with hFile null with" + "offset %lu and bufferStart %lu\n", + offset, bufferStart); + return 0; + } + fseek(hFile, offset, SEEK_SET); + elems_read += fread(&freadBuffer, 1, 512, hFile); + bufferStart = offset; + } + + return freadBuffer[(offset-bufferStart)>>1]; + } + if (activeDirEnt != -1) + fclose(hFile); + + strncpy(fpath,sRomPath,ARRAY_SIZE(fpath)); + strncat(fpath,DIR_SEP,ARRAY_SIZE(fpath)-strlen(fpath)); + + resolve_path(dirent); + + fatstring_to_asciiz(dirent,fname,NULL); + strncat(fpath,fname,ARRAY_SIZE(fpath)-strlen(fpath)); + + hFile = fopen(fpath, "rb"); + if (!hFile) return 0; + bufferStart = offset; + fseek(hFile, offset, SEEK_SET); + elems_read += fread(&freadBuffer, 1, 512, hFile); + + bufferStart = offset; + activeDirEnt = dirent; + fileStartLBA = (dirEntries[dirent].startCluster*512*SECPERCLUS); + fileEndLBA = fileStartLBA + dirEntries[dirent].fileSize; + + return freadBuffer[(offset-bufferStart)>>1]; +} + +unsigned int +cflash_read(unsigned int address) { + unsigned int ret_value = 0; + size_t elems_read = 0; +#if 0 /* used by next if 0 block */ +#define BUFFERED_BLOCK_SIZE 512 + static u8 block_buffer[BUFFERED_BLOCK_SIZE]; + static s32 buffered_start_index = -1; +#endif + + switch ( address) { + case CF_REG_STS: + ret_value = cf_reg_sts; + break; + + case CF_REG_DATA: + if (cf_reg_cmd == CF_CMD_READ) { + if ( use_disk_image_file) { + if ( disk_image != -1) { + u8 data[2]; +#if 0 + if ( currLBA < buffered_start_index || + currLBA >= (buffered_start_index + BUFFERED_BLOCK_SIZE)) { + size_t read_bytes = 0; + LSEEK_FN( disk_image, currLBA, SEEK_SET); + + while ( read_bytes < BUFFERED_BLOCK_SIZE) { + size_t cur_read = + READ_FN( disk_image, &block_buffer[read_bytes], + BUFFERED_BLOCK_SIZE - read_bytes); + + if ( cur_read == -1) { + CFLASHLOG( "Error during read: %s\n", strerror(errno) ); + break; + } + read_bytes += cur_read; + } + + CFLASHLOG( "Read %d bytes\n", read_bytes); + + buffered_start_index = currLBA; + } + data[0] = block_buffer[currLBA - buffered_start_index]; + data[1] = block_buffer[currLBA + 1 - buffered_start_index]; +#else + LSEEK_FN( disk_image, currLBA, SEEK_SET); + elems_read += READ_FN( disk_image, data, 2); +#endif + ret_value = data[1] << 8 | + data[0]; + } + currLBA += 2; + } + else { + unsigned char *p; + int i; + u32 cluster,cluster2,cluster3,fileLBA; + cluster = (currLBA / (512 * SECPERCLUS)); + cluster2 = (((currLBA/512) - filesysData) / SECPERCLUS) + 2; + + // Reading from the MBR + if (currLBA < 512) { + p = (unsigned char*)&MBR; + ret_value = T1ReadWord(p, currLBA); + + // Reading the FAT + } else if (((u32)currLBA >= filesysFAT*512) && ((u32)currLBA < filesysRootDir*512)) { + p = (unsigned char*)&FAT16[0]; + ret_value = T1ReadWord(p, currLBA - filesysFAT * 512); + + // Reading directory entries + } else if (((u32)currLBA >= filesysRootDir*512) && + (cluster <= (u32)lastDirEntCluster)) { + cluster3 = ((currLBA - (SECRESV * 512)) / (512 * SECPERCLUS)); + i = (currLBA-(((cluster3-(filesysRootDir/SECPERCLUS))*SECPERCLUS+filesysRootDir)*512)); //(currLBA - cluster*BYTESPERCLUS); + if (i < (dirEntriesInCluster[cluster3]*32)) { + + p = (unsigned char*)dirEntryPtr[cluster3]; + ret_value = T1ReadWord(p, i); + } else { + i /= 32; + i -= dirEntriesInCluster[cluster3]; + if ((i>=0)&&(i (u32)lastDirEntCluster) && (cluster2 <= (u32)lastFileDataCluster)) { //else if ((cluster>lastDirEntCluster)&&(cluster<=lastFileDataCluster)) { + fileLBA = currLBA - (filesysData-32)*512; // 32 = # sectors used for the root entries + + // Check if the read is from the currently opened file + if ((fileLBA >= fileStartLBA) && (fileLBA < fileEndLBA)) { + cluster = (fileLBA / (512 * SECPERCLUS)); + ret_value = fread_buffered(activeDirEnt,cluster-dirEntries[activeDirEnt].startCluster,(fileLBA-fileStartLBA)&(BYTESPERCLUS-1)); + } else { + for (i=0; i=(u32)(dirEntries[i].startCluster*512*SECPERCLUS)) && + (fileLBA <(dirEntries[i].startCluster*512*SECPERCLUS)+dirEntries[i].fileSize) && + ((dirEntries[i].attrib & (ATTRIB_DIR|ATTRIB_LFN))==0)) { + cluster = (fileLBA / (512 * SECPERCLUS)); + ret_value = fread_buffered(i,cluster-dirEntries[i].startCluster,fileLBA&(BYTESPERCLUS-1)); + break; + } + } + } + } + currLBA += 2; + } + } + break; + + case CF_REG_CMD: + break; + + case CF_REG_LBA1: + ret_value = cf_reg_lba1; + break; + } + + return ret_value; +} + +void +cflash_write(unsigned int address,unsigned int data) { + static u8 sector_data[512]; + static u32 sector_write_index = 0; + + switch ( address) { + case CF_REG_STS: + cf_reg_sts = data&0xFFFF; + break; + + case CF_REG_DATA: + if ( use_disk_image_file) { + if (cf_reg_cmd == CF_CMD_WRITE) { + sector_data[sector_write_index] = (data >> 0) & 0xff; + sector_data[sector_write_index + 1] = (data >> 8) & 0xff; + + sector_write_index += 2; + + if ( sector_write_index == 512) { + CFLASHLOG( "Write sector to %ld\n", currLBA); + + if ( currLBA + 512 < file_size) { + size_t written = 0; + + if ( disk_image != -1) { + LSEEK_FN( disk_image, currLBA, SEEK_SET); + + while( written < 512) { + size_t cur_write = + WRITE_FN( disk_image, §or_data[written], 512 - written); + written += cur_write; + + if ( cur_write == (size_t)-1) { + break; + } + } + } + + CFLASHLOG("Wrote %u bytes\n", written); + } + currLBA += 512; + sector_write_index = 0; + } + } + } + break; + + case CF_REG_CMD: + cf_reg_cmd = data&0xFF; + cf_reg_sts = 0x58; // READY + break; + + case CF_REG_LBA1: + cf_reg_lba1 = data&0xFF; + currLBA = (currLBA&0xFFFFFF00)| cf_reg_lba1; + break; + + case CF_REG_LBA2: + cf_reg_lba2 = data&0xFF; + currLBA = (currLBA&0xFFFF00FF)|(cf_reg_lba2<<8); + break; + + case CF_REG_LBA3: + cf_reg_lba3 = data&0xFF; + currLBA = (currLBA&0xFF00FFFF)|(cf_reg_lba3<<16); + break; + + case CF_REG_LBA4: + cf_reg_lba4 = data&0xFF; + + if ( (cf_reg_lba4 & 0xf0) == CF_CMD_LBA) { + currLBA = (currLBA&0x00FFFFFF)|((cf_reg_lba4&0x0F)<<24); + currLBA *= 512; + sector_write_index = 0; + } + break; + } +} + +void +cflash_close( void) { + if ( use_disk_image_file) { + if ( disk_image != -1) { + CLOSE_FN( disk_image); + disk_image = -1; + } + } + else { + int i; + + if (cflashDeviceEnabled) { + cflashDeviceEnabled = FALSE; + + for (i=0; i #include #include +#include #ifndef VERSION @@ -32,7 +33,7 @@ * FIXME: Not sure how to detect OpenGL in a platform portable way. */ #ifdef HAVE_GL_GL_H -#define INCLUDE_OPENGL_2D +#define INCLUDE_OPENGL_2D 1 #endif #ifdef INCLUDE_OPENGL_2D @@ -46,22 +47,25 @@ #include "../MMU.h" #include "../NDSSystem.h" +#include "../cflash.h" #include "../debug.h" #include "../sndsdl.h" #include "../ctrlssdl.h" #include "../render3D.h" #include "../rasterize.h" #include "../saves.h" -#include "../mic.h" #ifdef GDB_STUB #include "../gdbstub.h" #endif volatile BOOL execute = FALSE; +int backupmemorytype=MC_TYPE_AUTODETECT; +u32 backupmemorysize=1; + static float nds_screen_size_ratio = 1.0f; -#define DISPLAY_FPS +#define DISPLAY_FPS 1 #ifdef DISPLAY_FPS #define NUM_FRAMES_TO_TIME 60 @@ -73,11 +77,11 @@ static float nds_screen_size_ratio = 1.0f; static SDL_Surface * surface; /* Flags to pass to SDL_SetVideoMode */ -static int sdl_videoFlags; +static int sdl_videoFlags = 0; SoundInterface_struct *SNDCoreList[] = { &SNDDummy, - &SNDDummy, + &SNDFile, &SNDSDL, NULL }; @@ -101,7 +105,6 @@ const char * save_type_names[] = { /* Our keyboard config is different because of the directional keys */ -/* Please note that m is used for fake microphone */ const u16 cli_kb_cfg[NB_KEYS] = { SDLK_x, // A @@ -120,10 +123,6 @@ const u16 cli_kb_cfg[NB_KEYS] = SDLK_o // BOOST }; -#ifdef FAKE_MIC -static BOOL enable_fake_mic; -#endif - struct my_config { int load_slot; u16 arm9_gdb_port; @@ -138,7 +137,6 @@ struct my_config { int opengl_2d; int soft_colour_convert; #endif - int auto_pause; int disable_limiter; int frameskip; int fps_limiter_frame_period; @@ -158,7 +156,6 @@ init_config( struct my_config *config) { config->disable_sound = 0; - config->auto_pause = 0; config->disable_limiter = 0; config->frameskip = 0; config->fps_limiter_frame_period = FPS_LIMITER_FRAME_PERIOD; @@ -192,7 +189,6 @@ fill_config( struct my_config *config, printf( "USAGE: %s [options] \n", argv[0]); printf( "OPTIONS:\n"); printf( " --load-slot=NUM Loads savegame from slot NUM\n"); - printf( " --auto-pause Pause emulation of focus is lost.\n"); printf( " --disable-sound Disables the sound emulation\n"); printf( " --disable-limiter Disables the 60 fps limiter\n"); printf( " --frameskip=N Set frameskip to N\n"); @@ -256,35 +252,32 @@ fill_config( struct my_config *config, config->soft_colour_convert = 1; } #endif - else if ( strcmp( argv[i], "--auto-pause") == 0) { - config->auto_pause = 1; - } else if ( strcmp( argv[i], "--disable-limiter") == 0) { config->disable_limiter = 1; } else if ( strncmp( argv[i], "--frameskip=", 12) == 0) { - char *end_char; - int frameskip = strtoul(&argv[i][12], &end_char, 10); + char *end_char; + int frameskip = strtoul(&argv[i][12], &end_char, 10); - if ( frameskip >= 0 ) { - config->frameskip = frameskip; - } - else { - fprintf(stderr, "frameskip must be >=0\n"); - good_args = 0; - } + if ( frameskip >= 0 ) { + config->frameskip = frameskip; + } + else { + fprintf(stderr, "frameskip must be >=0\n"); + good_args = 0; + } } else if ( strncmp( argv[i], "--limiter-period=", 17) == 0) { - char *end_char; - int period = strtoul(&argv[i][17], &end_char, 10); + char *end_char; + int period = strtoul(&argv[i][17], &end_char, 10); - if ( period >= 0 && period <= 30 ) { - config->fps_limiter_frame_period = period; - } - else { - fprintf(stderr, "fps lmiter period must be >=0 and <= 30!\n"); - good_args = 0; - } + if ( period >= 0 && period <= 30 ) { + config->fps_limiter_frame_period = period; + } + else { + fprintf(stderr, "fps lmiter period must be >=0 and <= 30!\n"); + good_args = 0; + } } else if ( strncmp( argv[i], "--3d-engine=", 12) == 0) { char *end_char; @@ -433,9 +426,14 @@ fps_limiter_fn( Uint32 interval, void *param) { static int initGL( GLuint *screen_texture) { GLenum errCode; + int init_good = 1; + int i; u16 blank_texture[256 * 512]; - memset(blank_texture, 0x001f, sizeof(blank_texture)); + for ( i = 0; i < 256 * 512; i++) { + blank_texture[i] = 0x001f; + } + /* Enable Texture Mapping */ glEnable( GL_TEXTURE_2D ); @@ -473,10 +471,10 @@ initGL( GLuint *screen_texture) { errString = gluErrorString(errCode); fprintf( stderr, "Failed to init GL: %s\n", errString); - return 0; + init_good = 0; } - return 1; + return init_good; } static void @@ -541,6 +539,12 @@ resizeWindow( u16 width, u16 height) { right = 256.0 * ((double)width / other_dimen); } + /* + printf("%d,%d\n", width, height); + printf("l %lf, r %lf, t %lf, b %lf, other dimen %lf\n", + left, right, top, bottom, other_dimen); + */ + /* get the area (0,0) to (256,384) into the middle of the viewport */ gluOrtho2D( left, right, bottom, top); } @@ -640,87 +644,11 @@ Draw( void) { return; } -static void desmume_cycle(int *sdl_quit, int *boost, struct my_config * my_config) -{ - static unsigned short keypad; - static int focused = 1; - SDL_Event event; - - /* Look for queued events and update keypad status */ - /* IMPORTANT: Reenable joystick events iif needed. */ - if(SDL_JoystickEventState(SDL_QUERY) == SDL_IGNORE) - SDL_JoystickEventState(SDL_ENABLE); - - /* There's an event waiting to be processed? */ - while ( !*sdl_quit && - (SDL_PollEvent(&event) || (!focused && SDL_WaitEvent(&event)))) - { - process_ctrls_event( event, &keypad, nds_screen_size_ratio); - - switch (event.type) - { -#ifdef INCLUDE_OPENGL_2D - case SDL_VIDEORESIZE: - resizeWindow( event.resize.w, event.resize.h); - break; -#endif - case SDL_ACTIVEEVENT: - if (my_config->auto_pause && (event.active.state & SDL_APPINPUTFOCUS )) - { - if (event.active.gain) - { - focused = 1; - SPU_Pause(0); - } - else - { - focused = 0; - SPU_Pause(1); - } - } - break; - - case SDL_KEYUP: - switch (event.key.keysym.sym) - { - case SDLK_ESCAPE: - *sdl_quit = 1; - break; -#ifdef FAKE_MIC - case SDLK_m: - enable_fake_mic = !enable_fake_mic; - Mic_DoNoise(enable_fake_mic); - break; -#endif - case SDLK_o: - *boost = !(*boost); - break; - default: - break; - } - break; - - case SDL_QUIT: - *sdl_quit = 1; - break; - } - } - - /* Update mouse position and click */ - if(mouse.down) NDS_setTouchPos(mouse.x, mouse.y); - if(mouse.click) - { - NDS_releaseTouch(); - mouse.click = FALSE; - } - - update_keypad(keypad); /* Update keypad */ - NDS_exec(); - SPU_Emulate_user(); -} int main(int argc, char ** argv) { + static unsigned short keypad = 0; struct my_config my_config; + u32 last_cycle = 0; #ifdef GDB_STUB gdbstub_handle_t arm9_gdb_stub; gdbstub_handle_t arm7_gdb_stub; @@ -734,8 +662,6 @@ int main(int argc, char ** argv) { SDL_sem *fps_limiter_semaphore = NULL; SDL_TimerID limiter_timer = NULL; int sdl_quit = 0; - int boost = 0; - int error; #ifdef DISPLAY_FPS u32 fps_timing = 0; @@ -808,10 +734,9 @@ int main(int argc, char ** argv) { NDS_3D_ChangeCore(my_config.engine_3d); - backup_setManualBackupType(my_config.savetype); + mmu_select_savetype(my_config.savetype, &backupmemorytype, &backupmemorysize); - error = NDS_LoadROM( my_config.nds_file ); - if (error < 0) { + if (NDS_LoadROM( my_config.nds_file, backupmemorytype, backupmemorysize, my_config.cflash_disk_image_file) < 0) { fprintf(stderr, "error while loading %s\n", my_config.nds_file); exit(-1); } @@ -829,6 +754,12 @@ int main(int argc, char ** argv) { } #endif + /* // This has to get fixed yet + strncpy(szRomPath, dirname(argv[1]), ARRAY_SIZE(szRomPath)); + cflash_close(); + cflash_init(); + */ + execute = TRUE; if(SDL_Init(SDL_INIT_VIDEO | SDL_INIT_TIMER) == -1) @@ -936,7 +867,24 @@ int main(int argc, char ** argv) { } while(!sdl_quit) { - desmume_cycle(&sdl_quit, &boost, &my_config); + /* Look for queued events and update keypad status */ +#ifdef INCLUDE_OPENGL_2D + sdl_quit = process_ctrls_events( &keypad, resizeWindow, nds_screen_size_ratio); +#else + sdl_quit = process_ctrls_events( &keypad, NULL, nds_screen_size_ratio); +#endif + /* Update mouse position and click */ + if(mouse.down) NDS_setTouchPos(mouse.x, mouse.y); + if(mouse.click) + { + NDS_releaseTouch(); + mouse.click = FALSE; + } + + update_keypad(keypad); /* Update keypad */ + last_cycle = NDS_exec((560190 << 1) - last_cycle); + SPU_Emulate_user(); + SPU_Emulate_core(); #ifdef INCLUDE_OPENGL_2D if ( my_config.opengl_2d) { @@ -946,12 +894,14 @@ int main(int argc, char ** argv) { #endif Draw(); + /* FIXME: this may introduce some lag for input */ for ( int i = 0; i < my_config.frameskip; i++ ) { NDS_SkipNextFrame(); - desmume_cycle(&sdl_quit, &boost, &my_config); + NDS_exec(); + SPU_Emulate_user(); } - if ( !my_config.disable_limiter && !boost) { + if ( !my_config.disable_limiter) { limiter_frame_counter += 1 + my_config.frameskip; if ( limiter_frame_counter >= my_config.fps_limiter_frame_period) { limiter_frame_counter = 0; @@ -968,15 +918,16 @@ int main(int argc, char ** argv) { fps_previous_time = fps_temp_time; if ( fps_frame_counter == NUM_FRAMES_TO_TIME) { - char win_title[20]; + char win_title[100]; float fps = (float)fps_timing; fps /= NUM_FRAMES_TO_TIME * 1000.f; fps = 1.0f / fps; + //printf("fps %f\n", fps); fps_frame_counter = 0; fps_timing = 0; - snprintf( win_title, sizeof(win_title), "Desmume %f", fps); + sprintf( win_title, "Desmume %f", fps); SDL_WM_SetCaption( win_title, NULL); } diff --git a/desmume/src/cocoa/DeSmuME.cbp b/src/cocoa/DeSmuME.cbp similarity index 100% rename from desmume/src/cocoa/DeSmuME.cbp rename to src/cocoa/DeSmuME.cbp diff --git a/desmume/src/cocoa/DeSmuME.icns b/src/cocoa/DeSmuME.icns old mode 100755 new mode 100644 similarity index 100% rename from desmume/src/cocoa/DeSmuME.icns rename to src/cocoa/DeSmuME.icns diff --git a/desmume/src/cocoa/DeSmuME.xcodeproj/project.pbxproj b/src/cocoa/DeSmuME.xcodeproj/project.pbxproj similarity index 97% rename from desmume/src/cocoa/DeSmuME.xcodeproj/project.pbxproj rename to src/cocoa/DeSmuME.xcodeproj/project.pbxproj index a33ea07a5..6a0eef87a 100644 --- a/desmume/src/cocoa/DeSmuME.xcodeproj/project.pbxproj +++ b/src/cocoa/DeSmuME.xcodeproj/project.pbxproj @@ -23,6 +23,7 @@ 1EFD51870F892B1A00B029BB /* arm_instructions.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 7227644A0E78E18100AEDC8B /* arm_instructions.cpp */; }; 1EFD51880F892B1A00B029BB /* armcpu.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 7227644B0E78E18100AEDC8B /* armcpu.cpp */; }; 1EFD51890F892B1A00B029BB /* bios.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 7227644C0E78E18100AEDC8B /* bios.cpp */; }; + 1EFD518A0F892B1A00B029BB /* cflash.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 7227644D0E78E18100AEDC8B /* cflash.cpp */; }; 1EFD518B0F892B1A00B029BB /* cp15.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 7227644E0E78E18100AEDC8B /* cp15.cpp */; }; 1EFD518C0F892B1A00B029BB /* debug.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 7227644F0E78E18100AEDC8B /* debug.cpp */; }; 1EFD518D0F892B1A00B029BB /* Disassembler.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 722764500E78E18100AEDC8B /* Disassembler.cpp */; }; @@ -95,6 +96,7 @@ 722764620E78E18100AEDC8B /* arm_instructions.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 7227644A0E78E18100AEDC8B /* arm_instructions.cpp */; }; 722764630E78E18100AEDC8B /* armcpu.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 7227644B0E78E18100AEDC8B /* armcpu.cpp */; }; 722764640E78E18100AEDC8B /* bios.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 7227644C0E78E18100AEDC8B /* bios.cpp */; }; + 722764650E78E18100AEDC8B /* cflash.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 7227644D0E78E18100AEDC8B /* cflash.cpp */; }; 722764660E78E18100AEDC8B /* cp15.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 7227644E0E78E18100AEDC8B /* cp15.cpp */; }; 722764670E78E18100AEDC8B /* debug.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 7227644F0E78E18100AEDC8B /* debug.cpp */; }; 722764680E78E18100AEDC8B /* Disassembler.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 722764500E78E18100AEDC8B /* Disassembler.cpp */; }; @@ -130,9 +132,6 @@ 72D89DE50E83973A008D9B64 /* screen_state.m in Sources */ = {isa = PBXBuildFile; fileRef = 72D89DE40E83973A008D9B64 /* screen_state.m */; }; 72D89E370E845C7E008D9B64 /* readwrite.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 72D89E360E845C7E008D9B64 /* readwrite.cpp */; }; 8D11072F0486CEB800E47090 /* Cocoa.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 1058C7A1FEA54F0111CA2CBB /* Cocoa.framework */; }; - 95D5FE501007BC4500882BAE /* guitarGrip.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 95D5FE4F1007BC4500882BAE /* guitarGrip.cpp */; }; - 95D5FE751007EC0900882BAE /* guitarGrip.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 95D5FE4F1007BC4500882BAE /* guitarGrip.cpp */; }; - FC27E7FC100935F800A47A59 /* rasterize.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FC27E7FB100935F800A47A59 /* rasterize.cpp */; }; /* End PBXBuildFile section */ /* Begin PBXFileReference section */ @@ -199,6 +198,7 @@ 7227644A0E78E18100AEDC8B /* arm_instructions.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = arm_instructions.cpp; path = ../arm_instructions.cpp; sourceTree = SOURCE_ROOT; }; 7227644B0E78E18100AEDC8B /* armcpu.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = armcpu.cpp; path = ../armcpu.cpp; sourceTree = SOURCE_ROOT; }; 7227644C0E78E18100AEDC8B /* bios.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = bios.cpp; path = ../bios.cpp; sourceTree = SOURCE_ROOT; }; + 7227644D0E78E18100AEDC8B /* cflash.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = cflash.cpp; path = ../cflash.cpp; sourceTree = SOURCE_ROOT; }; 7227644E0E78E18100AEDC8B /* cp15.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = cp15.cpp; path = ../cp15.cpp; sourceTree = SOURCE_ROOT; }; 7227644F0E78E18100AEDC8B /* debug.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = debug.cpp; path = ../debug.cpp; sourceTree = SOURCE_ROOT; }; 722764500E78E18100AEDC8B /* Disassembler.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = Disassembler.cpp; path = ../Disassembler.cpp; sourceTree = SOURCE_ROOT; }; @@ -247,6 +247,7 @@ 729BEC9E0D9D57AF00ED561B /* armcpu.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = armcpu.h; path = ../armcpu.h; sourceTree = SOURCE_ROOT; }; 729BECA00D9D57AF00ED561B /* bios.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = bios.h; path = ../bios.h; sourceTree = SOURCE_ROOT; }; 729BECA10D9D57AF00ED561B /* bits.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = bits.h; path = ../bits.h; sourceTree = SOURCE_ROOT; }; + 729BECA30D9D57AF00ED561B /* cflash.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = cflash.h; path = ../cflash.h; sourceTree = SOURCE_ROOT; }; 729BECA60D9D57AF00ED561B /* cp15.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = cp15.h; path = ../cp15.h; sourceTree = SOURCE_ROOT; }; 729BECA80D9D57AF00ED561B /* debug.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = debug.h; path = ../debug.h; sourceTree = SOURCE_ROOT; }; 729BECAA0D9D57AF00ED561B /* Disassembler.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = Disassembler.h; path = ../Disassembler.h; sourceTree = SOURCE_ROOT; }; @@ -276,8 +277,6 @@ 72D89DE40E83973A008D9B64 /* screen_state.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = screen_state.m; sourceTree = ""; }; 72D89E360E845C7E008D9B64 /* readwrite.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = readwrite.cpp; path = ../readwrite.cpp; sourceTree = SOURCE_ROOT; }; 8D1107320486CEB800E47090 /* DeSmuME.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = DeSmuME.app; sourceTree = BUILT_PRODUCTS_DIR; }; - 95D5FE4F1007BC4500882BAE /* guitarGrip.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = guitarGrip.cpp; path = ../addons/guitarGrip.cpp; sourceTree = SOURCE_ROOT; }; - FC27E7FB100935F800A47A59 /* rasterize.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = rasterize.cpp; path = ../rasterize.cpp; sourceTree = SOURCE_ROOT; }; /* End PBXFileReference section */ /* Begin PBXFrameworksBuildPhase section */ @@ -410,7 +409,6 @@ 29B97315FDCFA39411CA2CEA /* Core */ = { isa = PBXGroup; children = ( - FC27E7FB100935F800A47A59 /* rasterize.cpp */, 1EFD50B80F891CAA00B029BB /* gdbstub */, 1FB372750F1CBAB200F75A43 /* addons */, 1FDD29400F080DBD004021C9 /* decrypt */, @@ -455,6 +453,7 @@ 7227644A0E78E18100AEDC8B /* arm_instructions.cpp */, 7227644B0E78E18100AEDC8B /* armcpu.cpp */, 7227644C0E78E18100AEDC8B /* bios.cpp */, + 7227644D0E78E18100AEDC8B /* cflash.cpp */, 7227644E0E78E18100AEDC8B /* cp15.cpp */, 7227644F0E78E18100AEDC8B /* debug.cpp */, 722764500E78E18100AEDC8B /* Disassembler.cpp */, @@ -479,6 +478,7 @@ 729BEC9E0D9D57AF00ED561B /* armcpu.h */, 729BECA00D9D57AF00ED561B /* bios.h */, 729BECA10D9D57AF00ED561B /* bits.h */, + 729BECA30D9D57AF00ED561B /* cflash.h */, 729BECA60D9D57AF00ED561B /* cp15.h */, 729BECA80D9D57AF00ED561B /* debug.h */, 729BECAA0D9D57AF00ED561B /* Disassembler.h */, @@ -492,7 +492,6 @@ 729BECB90D9D57AF00ED561B /* mem.h */, 729BECBB0D9D57AF00ED561B /* MMU.h */, 729BECBD0D9D57AF00ED561B /* NDSSystem.h */, - 95D5FE4F1007BC4500882BAE /* guitarGrip.cpp */, 729BECBE0D9D57AF00ED561B /* registers.h */, 729BECC00D9D57AF00ED561B /* render3D.h */, 729BECC20D9D57AF00ED561B /* ROMReader.h */, @@ -674,6 +673,7 @@ 1EFD51870F892B1A00B029BB /* arm_instructions.cpp in Sources */, 1EFD51880F892B1A00B029BB /* armcpu.cpp in Sources */, 1EFD51890F892B1A00B029BB /* bios.cpp in Sources */, + 1EFD518A0F892B1A00B029BB /* cflash.cpp in Sources */, 1EFD518B0F892B1A00B029BB /* cp15.cpp in Sources */, 1EFD518C0F892B1A00B029BB /* debug.cpp in Sources */, 1EFD518D0F892B1A00B029BB /* Disassembler.cpp in Sources */, @@ -717,7 +717,6 @@ 1EFD51B30F892B1A00B029BB /* cheatSystem.cpp in Sources */, 1EFD51B40F892B1A00B029BB /* texcache.cpp in Sources */, 1EFD51B50F892B1A00B029BB /* gdbstub.cpp in Sources */, - 95D5FE751007EC0900882BAE /* guitarGrip.cpp in Sources */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -738,6 +737,7 @@ 722764620E78E18100AEDC8B /* arm_instructions.cpp in Sources */, 722764630E78E18100AEDC8B /* armcpu.cpp in Sources */, 722764640E78E18100AEDC8B /* bios.cpp in Sources */, + 722764650E78E18100AEDC8B /* cflash.cpp in Sources */, 722764660E78E18100AEDC8B /* cp15.cpp in Sources */, 722764670E78E18100AEDC8B /* debug.cpp in Sources */, 722764680E78E18100AEDC8B /* Disassembler.cpp in Sources */, @@ -780,8 +780,6 @@ 1FB3727D0F1CBAB200F75A43 /* rumblepak.cpp in Sources */, 1F5577080F326E2000DCF447 /* cheatSystem.cpp in Sources */, 1F4B54D90F538DFE00C8B514 /* texcache.cpp in Sources */, - 95D5FE501007BC4500882BAE /* guitarGrip.cpp in Sources */, - FC27E7FC100935F800A47A59 /* rasterize.cpp in Sources */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -817,9 +815,8 @@ isa = XCBuildConfiguration; buildSettings = { ALWAYS_SEARCH_USER_PATHS = NO; - ARCHS = "$(ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1)"; - ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1 = "ppc i386"; - COPY_PHASE_STRIP = YES; + ARCHS = "$(ONLY_ACTIVE_ARCH_PRE_XCODE_3_1)"; + COPY_PHASE_STRIP = NO; GCC_AUTO_VECTORIZATION = YES; GCC_DYNAMIC_NO_PIC = NO; GCC_ENABLE_FIX_AND_CONTINUE = YES; @@ -838,9 +835,8 @@ GCC_UNROLL_LOOPS = YES; INFOPLIST_FILE = Info.plist; INSTALL_PATH = "$(HOME)/Applications"; - ONLY_ACTIVE_ARCH = NO; + ONLY_ACTIVE_ARCH_PRE_XCODE_3_1 = "$(NATIVE_ARCH)"; PRODUCT_NAME = DeSmuME; - STRIP_INSTALLED_PRODUCT = YES; VALID_ARCHS = "i386 ppc"; }; name = Debug; @@ -849,9 +845,7 @@ isa = XCBuildConfiguration; buildSettings = { ALWAYS_SEARCH_USER_PATHS = NO; - ARCHS = "$(ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1)"; - ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1 = "ppc i386"; - COPY_PHASE_STRIP = YES; + ARCHS = "$(ONLY_ACTIVE_ARCH_PRE_XCODE_3_1)"; DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; GCC_AUTO_VECTORIZATION = YES; GCC_MODEL_TUNING = G5; @@ -869,9 +863,8 @@ GCC_UNROLL_LOOPS = YES; INFOPLIST_FILE = Info.plist; INSTALL_PATH = "$(HOME)/Applications"; - ONLY_ACTIVE_ARCH = NO; + ONLY_ACTIVE_ARCH_PRE_XCODE_3_1 = "$(NATIVE_ARCH)"; PRODUCT_NAME = DeSmuME; - STRIP_INSTALLED_PRODUCT = YES; VALID_ARCHS = "i386 ppc"; }; name = Release; diff --git a/desmume/src/cocoa/Info.plist b/src/cocoa/Info.plist similarity index 100% rename from desmume/src/cocoa/Info.plist rename to src/cocoa/Info.plist diff --git a/desmume/src/cocoa/InfoPlist.strings b/src/cocoa/InfoPlist.strings similarity index 100% rename from desmume/src/cocoa/InfoPlist.strings rename to src/cocoa/InfoPlist.strings diff --git a/desmume/src/cocoa/Makefile.am b/src/cocoa/Makefile.am similarity index 100% rename from desmume/src/cocoa/Makefile.am rename to src/cocoa/Makefile.am diff --git a/desmume/src/cocoa/PkgInfo b/src/cocoa/PkgInfo similarity index 100% rename from desmume/src/cocoa/PkgInfo rename to src/cocoa/PkgInfo diff --git a/desmume/src/cocoa/Rakefile b/src/cocoa/Rakefile similarity index 100% rename from desmume/src/cocoa/Rakefile rename to src/cocoa/Rakefile diff --git a/desmume/src/cocoa/about.m b/src/cocoa/about.m similarity index 100% rename from desmume/src/cocoa/about.m rename to src/cocoa/about.m diff --git a/desmume/src/cocoa/build_dmg.sh b/src/cocoa/build_dmg.sh similarity index 100% rename from desmume/src/cocoa/build_dmg.sh rename to src/cocoa/build_dmg.sh diff --git a/desmume/src/cocoa/cocoa_util.m b/src/cocoa/cocoa_util.m similarity index 100% rename from desmume/src/cocoa/cocoa_util.m rename to src/cocoa/cocoa_util.m diff --git a/desmume/src/cocoa/dialogs/rom_info.h b/src/cocoa/dialogs/rom_info.h similarity index 96% rename from desmume/src/cocoa/dialogs/rom_info.h rename to src/cocoa/dialogs/rom_info.h index e0d576d85..a0365452f 100644 --- a/desmume/src/cocoa/dialogs/rom_info.h +++ b/src/cocoa/dialogs/rom_info.h @@ -1,32 +1,32 @@ -/* Copyright (C) 2007 Jeff Bland - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#import - -@class NintendoDS; - -//there is only one ROM Info window, so we have only class functions here - -@interface ROMInfo : NSObject -{ -} -+ (void)showROMInfo:(NintendoDS*)DS; -+ (void)changeDS:(NintendoDS*)DS; -+ (void)closeROMInfo; -@end +/* Copyright (C) 2007 Jeff Bland + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#import + +@class NintendoDS; + +//there is only one ROM Info window, so we have only class functions here + +@interface ROMInfo : NSObject +{ +} ++ (void)showROMInfo:(NintendoDS*)DS; ++ (void)changeDS:(NintendoDS*)DS; ++ (void)closeROMInfo; +@end diff --git a/desmume/src/cocoa/dialogs/rom_info.m b/src/cocoa/dialogs/rom_info.m similarity index 100% rename from desmume/src/cocoa/dialogs/rom_info.m rename to src/cocoa/dialogs/rom_info.m diff --git a/desmume/src/cocoa/dialogs/speed_limit_selection_window.h b/src/cocoa/dialogs/speed_limit_selection_window.h similarity index 96% rename from desmume/src/cocoa/dialogs/speed_limit_selection_window.h rename to src/cocoa/dialogs/speed_limit_selection_window.h index b41415551..da902faec 100644 --- a/desmume/src/cocoa/dialogs/speed_limit_selection_window.h +++ b/src/cocoa/dialogs/speed_limit_selection_window.h @@ -1,33 +1,33 @@ -/* Copyright (C) 2008 Jeff Bland - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#import -#import "../nds_control.h" - -@interface SpeedLimitSelectionWindow : NSWindow -{ - BOOL modal; - NintendoDS *target; - NSTextField *value; - int initial_value; -} -- (id)initWithDS:(NintendoDS*)ds; -- (void)runModal; -- (void)dealloc; -@end +/* Copyright (C) 2008 Jeff Bland + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#import +#import "../nds_control.h" + +@interface SpeedLimitSelectionWindow : NSWindow +{ + BOOL modal; + NintendoDS *target; + NSTextField *value; + int initial_value; +} +- (id)initWithDS:(NintendoDS*)ds; +- (void)runModal; +- (void)dealloc; +@end diff --git a/desmume/src/cocoa/dialogs/speed_limit_selection_window.mm b/src/cocoa/dialogs/speed_limit_selection_window.mm similarity index 100% rename from desmume/src/cocoa/dialogs/speed_limit_selection_window.mm rename to src/cocoa/dialogs/speed_limit_selection_window.mm diff --git a/desmume/src/cocoa/globals.h b/src/cocoa/globals.h similarity index 96% rename from desmume/src/cocoa/globals.h rename to src/cocoa/globals.h index 3bffd38c3..d67ccbaa1 100644 --- a/desmume/src/cocoa/globals.h +++ b/src/cocoa/globals.h @@ -1,41 +1,41 @@ -/* Copyright (C) 2007 Jeff Bland - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#import - -#ifdef __cplusplus -extern "C" -{ -#endif - -void messageDialog(NSString *title, NSString *text); -BOOL messageDialogYN(NSString *title, NSString *text); -NSString* openDialog(NSArray *file_types); - -// -#if !defined(__LP64__) && !defined(NS_BUILD_32_LIKE_64) -typedef int NSInteger; -typedef unsigned int NSUInteger; -#endif - -typedef float CGFloat; - -#ifdef __cplusplus -} +/* Copyright (C) 2007 Jeff Bland + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#import + +#ifdef __cplusplus +extern "C" +{ +#endif + +void messageDialog(NSString *title, NSString *text); +BOOL messageDialogYN(NSString *title, NSString *text); +NSString* openDialog(NSArray *file_types); + +// +#if !defined(__LP64__) && !defined(NS_BUILD_32_LIKE_64) +typedef int NSInteger; +typedef unsigned int NSUInteger; +#endif + +typedef float CGFloat; + +#ifdef __cplusplus +} #endif \ No newline at end of file diff --git a/desmume/src/cocoa/input.h b/src/cocoa/input.h similarity index 96% rename from desmume/src/cocoa/input.h rename to src/cocoa/input.h index 968934f16..effebc906 100644 --- a/desmume/src/cocoa/input.h +++ b/src/cocoa/input.h @@ -1,50 +1,50 @@ -/* Copyright (C) 2007 Jeff Bland - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#import - -/* The main window class instanciates an input object, - and places it after the window in the responder chain, so - any events not handled by a the window get sent here. - */ - -@class VideoOutputWindow; - -@interface InputHandler : NSResponder -{ -@private - VideoOutputWindow *my_ds; -} -//preferences -+ (NSView*)createPreferencesView:(float)width; -+ (NSDictionary*)appDefaults; - -//creation/deletion -- (id)initWithWindow:(VideoOutputWindow*)nds; -- (void)dealloc; - -//keyboard input -- (void)keyDown:(NSEvent*)event; -- (void)keyUp:(NSEvent*)event; - -//mouse input -- (void)mouseDown:(NSEvent*)event; -- (void)mouseDragged:(NSEvent*)event; -- (void)mouseUp:(NSEvent*)event; -@end +/* Copyright (C) 2007 Jeff Bland + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#import + +/* The main window class instanciates an input object, + and places it after the window in the responder chain, so + any events not handled by a the window get sent here. + */ + +@class VideoOutputWindow; + +@interface InputHandler : NSResponder +{ +@private + VideoOutputWindow *my_ds; +} +//preferences ++ (NSView*)createPreferencesView:(float)width; ++ (NSDictionary*)appDefaults; + +//creation/deletion +- (id)initWithWindow:(VideoOutputWindow*)nds; +- (void)dealloc; + +//keyboard input +- (void)keyDown:(NSEvent*)event; +- (void)keyUp:(NSEvent*)event; + +//mouse input +- (void)mouseDown:(NSEvent*)event; +- (void)mouseDragged:(NSEvent*)event; +- (void)mouseUp:(NSEvent*)event; +@end diff --git a/desmume/src/cocoa/input.mm b/src/cocoa/input.mm similarity index 100% rename from desmume/src/cocoa/input.mm rename to src/cocoa/input.mm diff --git a/desmume/src/cocoa/main.mm b/src/cocoa/main.mm similarity index 96% rename from desmume/src/cocoa/main.mm rename to src/cocoa/main.mm index f9a19f321..0d9d7f63e 100644 --- a/desmume/src/cocoa/main.mm +++ b/src/cocoa/main.mm @@ -74,9 +74,6 @@ extern NSMenuItem *reset_item; extern NSMenuItem *frame_skip_auto_item; extern NSMenuItem *frame_skip_item[]; -extern NSMenuItem *save_type_item[]; -extern NSString *save_types[]; - extern NSMenuItem *speed_limit_25_item; extern NSMenuItem *speed_limit_50_item; extern NSMenuItem *speed_limit_75_item; @@ -286,27 +283,7 @@ void CreateMenu(AppDelegate *delegate) [speed_limit_menu release]; } - // Backup media type - temp = [emulation_menu addItemWithTitle:NSLocalizedString(@"Backup Media Type", nil) action:nil keyEquivalent:@""]; - - NSMenu *save_type_menu = [[NSMenu alloc] initWithTitle:NSLocalizedString(@"Backup Media Type", nil)]; - if(save_type_menu != nil) - { - [temp setSubmenu:save_type_menu]; - - // Add autodetect apart from the others - save_type_item[0] = [save_type_menu addItemWithTitle:save_types[0] action:@selector(setSaveTypeFromMenuItem:) keyEquivalent:@""]; - [save_type_menu addItem:[NSMenuItem separatorItem]]; - - // Add the rest - for(i = 1; i < MAX_SAVE_TYPE; i++) - { - save_type_item[i] = [save_type_menu addItemWithTitle:save_types[i] action:@selector(setSaveTypeFromMenuItem:) keyEquivalent:@""]; - } - - [save_type_menu release]; - } - + // [emulation_menu addItem:[NSMenuItem separatorItem]]; diff --git a/desmume/src/cocoa/main_window.h b/src/cocoa/main_window.h similarity index 96% rename from desmume/src/cocoa/main_window.h rename to src/cocoa/main_window.h index 10b453e7d..f1777d424 100644 --- a/desmume/src/cocoa/main_window.h +++ b/src/cocoa/main_window.h @@ -1,116 +1,111 @@ -/* Copyright (C) 2007 Jeff Bland - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#import - -#import "nds_control.h" - -@class VideoOutputView; -@class InputHandler; -//this is used internally by VideoOutputWindow - -// Backup media type array length -#define MAX_SAVE_TYPE 7 - - -//This interface is to create and manaage the window -//that displays DS video output and takes keyboard/mouse input -//do not instanciate more than one of these -@interface VideoOutputWindow : NintendoDS -{ - @private - NSWindow *window; - NSWindowController *controller; - VideoOutputView *video_output_view; - NSTextField *status_view; - NSString *status_bar_text; - InputHandler *input; - - bool no_smaller_than_ds; - bool keep_proportions; -} - -//initialization -- (id)init; -- (void)dealloc; - -//overloaded from NintendoDS class -- (BOOL)loadROM:(NSString*)filename; -- (void)execute; -- (void)pause; -- (void)reset; -- (void)setFrameSkip:(int)frameskip; -- (void)setSaveType:(int)savetype; -- (void)closeROM; - -//save features overloaded from nds class -- (BOOL)saveState:(NSString*)file; -- (BOOL)loadState:(NSString*)file; -- (BOOL)saveStateToSlot:(int)slot; //0 to MAX_SLOTS-1, anything else is ignored -- (BOOL)loadStateFromSlot:(int)slot; - -//save functions for the program menu to callback to -- (BOOL)saveStateAs; -- (BOOL)loadStateFrom; - -//toggles between allowing tiny sizes and only being as small as DS -- (void)toggleMinSize; - -//this method will contrain the size as well -//this is screen size not window size -- (void)resizeScreen:(NSSize)size; - -//like resizeScreen but does a size in relation to DS pixels -- (void)resizeScreen1x; -- (void)resizeScreen2x; -- (void)resizeScreen3x; -- (void)resizeScreen4x; - -//converts window coords to DS coords (returns -1, -1 if invalid) -- (NSPoint)windowPointToDSCoords:(NSPoint)location; - -// -- (void)toggleConstrainProportions; -- (void)toggleStatusBar; - -//rotation -- (void)setRotation:(float)rotation; -- (void)setRotation0; -- (void)setRotation90; -- (void)setRotation180; -- (void)setRotation270; -- (float)rotation; - -//layers -- (void)toggleTopBackground0; -- (void)toggleTopBackground1; -- (void)toggleTopBackground2; -- (void)toggleTopBackground3; -- (void)toggleSubBackground0; -- (void)toggleSubBackground1; -- (void)toggleSubBackground2; -- (void)toggleSubBackground3; - -//screenshots -- (void)saveScreenshot; - -//delegate -- (void)windowDidBecomeMain:(NSNotification*)notification; - -@end +/* Copyright (C) 2007 Jeff Bland + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#import + +#import "nds_control.h" + +@class VideoOutputView; +@class InputHandler; +//this is used internally by VideoOutputWindow + +//This interface is to create and manaage the window +//that displays DS video output and takes keyboard/mouse input +//do not instanciate more than one of these +@interface VideoOutputWindow : NintendoDS +{ + @private + NSWindow *window; + NSWindowController *controller; + VideoOutputView *video_output_view; + NSTextField *status_view; + NSString *status_bar_text; + InputHandler *input; + + bool no_smaller_than_ds; + bool keep_proportions; +} + +//initialization +- (id)init; +- (void)dealloc; + +//overloaded from NintendoDS class +- (BOOL)loadROM:(NSString*)filename; +- (void)execute; +- (void)pause; +- (void)reset; +- (void)setFrameSkip:(int)frameskip; +- (void)closeROM; + +//save features overloaded from nds class +- (BOOL)saveState:(NSString*)file; +- (BOOL)loadState:(NSString*)file; +- (BOOL)saveStateToSlot:(int)slot; //0 to MAX_SLOTS-1, anything else is ignored +- (BOOL)loadStateFromSlot:(int)slot; + +//save functions for the program menu to callback to +- (BOOL)saveStateAs; +- (BOOL)loadStateFrom; + +//toggles between allowing tiny sizes and only being as small as DS +- (void)toggleMinSize; + +//this method will contrain the size as well +//this is screen size not window size +- (void)resizeScreen:(NSSize)size; + +//like resizeScreen but does a size in relation to DS pixels +- (void)resizeScreen1x; +- (void)resizeScreen2x; +- (void)resizeScreen3x; +- (void)resizeScreen4x; + +//converts window coords to DS coords (returns -1, -1 if invalid) +- (NSPoint)windowPointToDSCoords:(NSPoint)location; + +// +- (void)toggleConstrainProportions; +- (void)toggleStatusBar; + +//rotation +- (void)setRotation:(float)rotation; +- (void)setRotation0; +- (void)setRotation90; +- (void)setRotation180; +- (void)setRotation270; +- (float)rotation; + +//layers +- (void)toggleTopBackground0; +- (void)toggleTopBackground1; +- (void)toggleTopBackground2; +- (void)toggleTopBackground3; +- (void)toggleSubBackground0; +- (void)toggleSubBackground1; +- (void)toggleSubBackground2; +- (void)toggleSubBackground3; + +//screenshots +- (void)saveScreenshot; + +//delegate +- (void)windowDidBecomeMain:(NSNotification*)notification; + +@end diff --git a/desmume/src/cocoa/main_window.mm b/src/cocoa/main_window.mm similarity index 97% rename from desmume/src/cocoa/main_window.mm rename to src/cocoa/main_window.mm index 69d35e1b2..44eb554a7 100644 --- a/desmume/src/cocoa/main_window.mm +++ b/src/cocoa/main_window.mm @@ -32,18 +32,6 @@ #define MAX_FRAME_SKIP 10 -// Save types settings -NSString *save_types[MAX_SAVE_TYPE] = { - NSLocalizedString(@"Auto Detect", nil), // 0 - NSLocalizedString(@"EEPROM 4kbit", nil), // 1 - NSLocalizedString(@"EEPROM 64kbit", nil), // 2 - NSLocalizedString(@"EEPROM 512kbit", nil), // 3 - NSLocalizedString(@"FRAM 256knit", nil), // 4 - NSLocalizedString(@"FLASH 2mbit", nil), // 5 - NSLocalizedString(@"FLASH 4mbit", nil), // 6 -}; - - #define DS_SCREEN_HEIGHT_COMBINED (192*2) /*height of the two screens*/ #define DS_SCREEN_X_RATIO (256.0 / (192.0 * 2.0)) #define DS_SCREEN_Y_RATIO ((192.0 * 2.0) / 256.0) @@ -67,7 +55,6 @@ NSMenuItem *speed_limit_100_item = nil; NSMenuItem *speed_limit_200_item = nil; NSMenuItem *speed_limit_none_item = nil; NSMenuItem *speed_limit_custom_item = nil; -NSMenuItem *save_type_item[MAX_SAVE_TYPE] = { nil, nil, nil, nil, nil, nil, nil }; NSMenuItem *volume_item[10] = { nil, nil, nil, nil, nil, nil, nil, nil, nil, nil }; NSMenuItem *mute_item = nil; @@ -443,33 +430,6 @@ NSMenuItem *screenshot_to_file_item = nil; } } -- (void)setSaveType:(int)savetype -{ - [super setSaveType:savetype]; - savetype = [super saveType]; - - int i; - for(i = 0; i < MAX_SAVE_TYPE; i++) - if([save_type_item[i] target] == self) - if(i == savetype) - [save_type_item[i] setState:NSOnState]; - else - [save_type_item[i] setState:NSOffState]; -} - -- (void)setSaveTypeFromMenuItem:(id)sender -{ - // Find the culprit - int i; - for(i = 0; i < MAX_SAVE_TYPE; i++) - if(sender == save_type_item[i]) - { - [self setSaveType:i]; - return; - } -} - - - (void)closeROM { [super closeROM]; @@ -1177,11 +1137,6 @@ NSMenuItem *screenshot_to_file_item = nil; [frame_skip_auto_item setTarget:self]; for(i = 0; i < MAX_FRAME_SKIP; i++)[frame_skip_item[i] setTarget:self]; [self setFrameSkip:[self frameSkip]]; //set the menu checkmarks correctly - - // Backup media type - for(i = 0; i < MAX_SAVE_TYPE; i++)[save_type_item[i] setTarget:self]; - [self setSaveType:[self saveType]]; // initalize the menu - [speed_limit_25_item setTarget:self]; [speed_limit_50_item setTarget:self]; diff --git a/desmume/src/cocoa/makeapp.sh b/src/cocoa/makeapp.sh old mode 100755 new mode 100644 similarity index 100% rename from desmume/src/cocoa/makeapp.sh rename to src/cocoa/makeapp.sh diff --git a/desmume/src/cocoa/nds_control.h b/src/cocoa/nds_control.h similarity index 96% rename from desmume/src/cocoa/nds_control.h rename to src/cocoa/nds_control.h index 59eab8ec5..467899726 100644 --- a/desmume/src/cocoa/nds_control.h +++ b/src/cocoa/nds_control.h @@ -1,195 +1,192 @@ -/* Copyright (C) 2007 Jeff Bland - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#import "globals.h" - -@class ScreenState; - -#ifdef GDB_STUB -#define OBJ_C -#include "../gdbstub.h" -#endif - -#define MAX_SLOTS 10 -#define MAX_FRAME_SKIP 10 - -//This class is a compelte objective-c wrapper for -//the core emulation features, other objective-c code inherit -//upon or instanciate this to add interfaces for these features -//Please only instanciate once. -@interface NintendoDS : NSObject -{ - @private - - NSOpenGLContext* context; //context where the 3d gets renderered to - NSOpenGLPixelFormat* pixel_format; //pixel format for opengl 3d renderer - NSThread *gui_thread; - SEL display_func; //the function id that gets called when the screen is ready to update - id display_object; //the object that the above function is called on - SEL error_func; - id error_object; - - NSLock *execution_lock; - NSLock *sound_lock; - - ScreenState * volatile current_screen; - NSLock *video_update_lock; - - volatile bool finish; //set to true to make the other thread finish - volatile bool finished; //set to true by the other thread after it finishes - volatile bool run; //set to control execution in other thread - volatile bool paused; //sey by other thread to let us know if its executing - - bool muted; - int volume; - - volatile int frame_skip; - volatile int speed_limit; - volatile int save_type; - - NSString *current_file; - NSString *flash_file; - -#ifdef GDB_STUB - NSInteger arm9_gdb_port; - NSInteger arm7_gdb_port; - gdbstub_handle_t arm9_gdb_stub; - gdbstub_handle_t arm7_gdb_stub; -#endif - - unsigned char gpu_buff[256 * 256 * 5]; //this is where the 3D rendering of the NDS is stored -} - -//Instanciating, setup, and deconstruction -- (id)init; -- (void)setVideoUpdateCallback:(SEL)callback withObject:(id)object; //this callback should take one ScreenState(below) parameter -- (void)setErrorCallback:(SEL)callback withObject:(id)object; -- (void)dealloc; - -//Firmware control -- (void)setPlayerName:(NSString*)player_name; - -//ROM control -- (BOOL)loadROM:(NSString*)filename; -- (BOOL)ROMLoaded; -- (void)closeROM; - -//ROM Info -- (NSImage*)ROMIcon; -- (NSString*)ROMFile; -- (NSString*)ROMTitle; -- (NSInteger)ROMMaker; -- (NSInteger)ROMSize; -- (NSInteger)ROMARM9Size; -- (NSInteger)ROMARM7Size; -- (NSInteger)ROMDataSize; - -//Flash memory -- (NSString*)flashFile; -- (void)setFlashFile:(NSString*)filename; - -//execution control -- (BOOL)executing; -- (void)execute; -- (BOOL)paused; -- (void)pause; -- (void)reset; -- (void)setFrameSkip:(int)frameskip; //negative is auto, 0 is off, more than 0 is the amount of frames to skip before showing a frame -- (int)frameSkip; //defaults to -1 -- (void)setSpeedLimit:(int)percent; //0 is off, 1-1000 is the pertance speed it runs at, anything else does nothing -- (int)speedLimit; -- (void)setSaveType:(int)savetype; // see save_types in src/mmu.h -- (int)saveType; // default is 0, which is autodetect - -//touch screen -- (void)touch:(NSPoint)point; -- (void)releaseTouch; - -//button input -- (void)pressStart; -- (void)liftStart; -- (BOOL)start; -- (void)pressSelect; -- (void)liftSelect; -- (BOOL)select; -- (void)pressLeft; -- (void)liftLeft; -- (BOOL)left; -- (void)pressRight; -- (void)liftRight; -- (BOOL)right; -- (void)pressUp; -- (void)liftUp; -- (BOOL)up; -- (void)pressDown; -- (void)liftDown; -- (BOOL)down; -- (void)pressA; -- (void)liftA; -- (BOOL)A; -- (void)pressB; -- (void)liftB; -- (BOOL)B; -- (void)pressX; -- (void)liftX; -- (BOOL)X; -- (void)pressY; -- (void)liftY; -- (BOOL)Y; -- (void)pressL; -- (void)liftL; -- (BOOL)L; -- (void)pressR; -- (void)liftR; -- (BOOL)R; - -//save states -- (BOOL)saveState:(NSString*)file; -- (BOOL)loadState:(NSString*)file; -- (BOOL)saveStateToSlot:(int)slot; //0 to MAX_SLOTS-1, anything else is ignored -- (BOOL)loadStateFromSlot:(int)slot; -- (BOOL)saveStateExists:(int)slot; - -//layers -- (void)toggleTopBackground0; -- (BOOL)showingTopBackground0; -- (void)toggleTopBackground1; -- (BOOL)showingTopBackground1; -- (void)toggleTopBackground2; -- (BOOL)showingTopBackground2; -- (void)toggleTopBackground3; -- (BOOL)showingTopBackground3; -- (void)toggleSubBackground0; -- (BOOL)showingSubBackground0; -- (void)toggleSubBackground1; -- (BOOL)showingSubBackground1; -- (void)toggleSubBackground2; -- (BOOL)showingSubBackground2; -- (void)toggleSubBackground3; -- (BOOL)showingSubBackground3; - -//Sound -- (BOOL)hasSound; -- (void)setVolume:(int)volume; //clamped: 0 to 100 -- (int)volume; -- (void)enableMute; -- (void)disableMute; -- (void)toggleMute; -- (BOOL)muted; -@end +/* Copyright (C) 2007 Jeff Bland + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#import "globals.h" + +@class ScreenState; + +#ifdef GDB_STUB +#define OBJ_C +#include "../gdbstub.h" +#endif + +#define MAX_SLOTS 10 +#define MAX_FRAME_SKIP 10 + +//This class is a compelte objective-c wrapper for +//the core emulation features, other objective-c code inherit +//upon or instanciate this to add interfaces for these features +//Please only instanciate once. +@interface NintendoDS : NSObject +{ + @private + + NSOpenGLContext* context; //context where the 3d gets renderered to + NSOpenGLPixelFormat* pixel_format; //pixel format for opengl 3d renderer + NSThread *gui_thread; + SEL display_func; //the function id that gets called when the screen is ready to update + id display_object; //the object that the above function is called on + SEL error_func; + id error_object; + + NSLock *execution_lock; + NSLock *sound_lock; + + ScreenState * volatile current_screen; + NSLock *video_update_lock; + + volatile bool finish; //set to true to make the other thread finish + volatile bool finished; //set to true by the other thread after it finishes + volatile bool run; //set to control execution in other thread + volatile bool paused; //sey by other thread to let us know if its executing + + bool muted; + int volume; + + volatile int frame_skip; + volatile int speed_limit; + + NSString *current_file; + NSString *flash_file; + +#ifdef GDB_STUB + NSInteger arm9_gdb_port; + NSInteger arm7_gdb_port; + gdbstub_handle_t arm9_gdb_stub; + gdbstub_handle_t arm7_gdb_stub; +#endif + + unsigned char gpu_buff[256 * 256 * 5]; //this is where the 3D rendering of the NDS is stored +} + +//Instanciating, setup, and deconstruction +- (id)init; +- (void)setVideoUpdateCallback:(SEL)callback withObject:(id)object; //this callback should take one ScreenState(below) parameter +- (void)setErrorCallback:(SEL)callback withObject:(id)object; +- (void)dealloc; + +//Firmware control +- (void)setPlayerName:(NSString*)player_name; + +//ROM control +- (BOOL)loadROM:(NSString*)filename; +- (BOOL)ROMLoaded; +- (void)closeROM; + +//ROM Info +- (NSImage*)ROMIcon; +- (NSString*)ROMFile; +- (NSString*)ROMTitle; +- (NSInteger)ROMMaker; +- (NSInteger)ROMSize; +- (NSInteger)ROMARM9Size; +- (NSInteger)ROMARM7Size; +- (NSInteger)ROMDataSize; + +//Flash memory +- (NSString*)flashFile; +- (void)setFlashFile:(NSString*)filename; + +//execution control +- (BOOL)executing; +- (void)execute; +- (BOOL)paused; +- (void)pause; +- (void)reset; +- (void)setFrameSkip:(int)frameskip; //negative is auto, 0 is off, more than 0 is the amount of frames to skip before showing a frame +- (int)frameSkip; //defaults to -1 +- (void)setSpeedLimit:(int)percent; //0 is off, 1-1000 is the pertance speed it runs at, anything else does nothing +- (int)speedLimit; + +//touch screen +- (void)touch:(NSPoint)point; +- (void)releaseTouch; + +//button input +- (void)pressStart; +- (void)liftStart; +- (BOOL)start; +- (void)pressSelect; +- (void)liftSelect; +- (BOOL)select; +- (void)pressLeft; +- (void)liftLeft; +- (BOOL)left; +- (void)pressRight; +- (void)liftRight; +- (BOOL)right; +- (void)pressUp; +- (void)liftUp; +- (BOOL)up; +- (void)pressDown; +- (void)liftDown; +- (BOOL)down; +- (void)pressA; +- (void)liftA; +- (BOOL)A; +- (void)pressB; +- (void)liftB; +- (BOOL)B; +- (void)pressX; +- (void)liftX; +- (BOOL)X; +- (void)pressY; +- (void)liftY; +- (BOOL)Y; +- (void)pressL; +- (void)liftL; +- (BOOL)L; +- (void)pressR; +- (void)liftR; +- (BOOL)R; + +//save states +- (BOOL)saveState:(NSString*)file; +- (BOOL)loadState:(NSString*)file; +- (BOOL)saveStateToSlot:(int)slot; //0 to MAX_SLOTS-1, anything else is ignored +- (BOOL)loadStateFromSlot:(int)slot; +- (BOOL)saveStateExists:(int)slot; + +//layers +- (void)toggleTopBackground0; +- (BOOL)showingTopBackground0; +- (void)toggleTopBackground1; +- (BOOL)showingTopBackground1; +- (void)toggleTopBackground2; +- (BOOL)showingTopBackground2; +- (void)toggleTopBackground3; +- (BOOL)showingTopBackground3; +- (void)toggleSubBackground0; +- (BOOL)showingSubBackground0; +- (void)toggleSubBackground1; +- (BOOL)showingSubBackground1; +- (void)toggleSubBackground2; +- (BOOL)showingSubBackground2; +- (void)toggleSubBackground3; +- (BOOL)showingSubBackground3; + +//Sound +- (BOOL)hasSound; +- (void)setVolume:(int)volume; //clamped: 0 to 100 +- (int)volume; +- (void)enableMute; +- (void)disableMute; +- (void)toggleMute; +- (BOOL)muted; +@end diff --git a/desmume/src/cocoa/nds_control.mm b/src/cocoa/nds_control.mm similarity index 99% rename from desmume/src/cocoa/nds_control.mm rename to src/cocoa/nds_control.mm index 8e848d405..68107d599 100644 --- a/desmume/src/cocoa/nds_control.mm +++ b/src/cocoa/nds_control.mm @@ -37,7 +37,6 @@ #include "../render3D.h" #include "../GPU.h" #include "../OGLRender.h" -#include "../rasterize.h" #undef BOOL //this bool controls whether we will use a timer to constantly check for screen updates @@ -54,7 +53,6 @@ volatile desmume_BOOL execute = true; GPU3DInterface *core3DList[] = { &gpu3DNull, -&gpu3DRasterize, #ifdef HAVE_OPENGL &gpu3Dgl, #endif @@ -63,12 +61,16 @@ NULL SoundInterface_struct *SNDCoreList[] = { &SNDDummy, +&SNDFile, #ifdef DESMUME_COCOA &SNDOSX, #endif NULL }; +static int backupmemorytype=MC_TYPE_AUTODETECT; +static u32 backupmemorysize=1; + struct NDS_fw_config_data firmware; bool opengl_init() @@ -378,7 +380,7 @@ bool opengl_init() flash = NULL; //load the rom - if(!NDS_LoadROM([filename cStringUsingEncoding:NSUTF8StringEncoding], flash) > 0) + if(!NDS_LoadROM([filename cStringUsingEncoding:NSUTF8StringEncoding], backupmemorytype, backupmemorysize, flash) > 0) { //if it didn't work give an error and dont unpause messageDialog(NSLocalizedString(@"Error", nil), @"Could not open file"); @@ -626,20 +628,6 @@ bool opengl_init() return speed_limit; } -- (void)setSaveType:(int)savetype -{ - if(savetype < 0 || savetype > 6) savetype = 0; - - // Set the savetype - backup_setManualBackupType(savetype); -} - -- (int)saveType -{ - return CommonSettings.manualBackupType; -} - - - (void)touch:(NSPoint)point { NDS_setTouchPos((unsigned short)point.x, (unsigned short)point.y); @@ -1340,6 +1328,8 @@ bool opengl_init() CGLLockContext((CGLContextObj)[gl_context CGLContextObj]); #endif + u32 cycles = 0; + NSDate *frame_start_date, *frame_end_date, *ideal_frame_end_date; int frames_to_skip = 0; @@ -1362,7 +1352,7 @@ bool opengl_init() [execution_lock lock]; - NDS_exec(); + cycles = NDS_exec((560190<<1)-cycles); [sound_lock lock]; int x; diff --git a/desmume/src/cocoa/preferences.h b/src/cocoa/preferences.h similarity index 97% rename from desmume/src/cocoa/preferences.h rename to src/cocoa/preferences.h index 56780c194..d29198349 100644 --- a/desmume/src/cocoa/preferences.h +++ b/src/cocoa/preferences.h @@ -1,50 +1,50 @@ -/* Copyright (C) 2007 Jeff Bland - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#import - -#define PREF_EXECUTE_UPON_LOAD @"Execute Upon Load" - -#define PREF_AFTER_LAUNCHED @"When Launching, Load" -#define PREF_AFTER_LAUNCHED_OPTION_NOTHING @"Load Nothing" -#define PREF_AFTER_LAUNCHED_OPTION_LAST_ROM @"Load Last ROM" - -#define PREF_FLASH_FILE @"Flash File" - -#ifdef GDB_STUB -#define PREF_ARM9_GDB_PORT @"arm9gdb" -#define PREF_ARM7_GDB_PORT @"arm7gdb" -#endif - -#define PREF_KEY_A @"A Button" -#define PREF_KEY_B @"B Button" -#define PREF_KEY_X @"X Button" -#define PREF_KEY_Y @"Y Button" -#define PREF_KEY_L @"L Button" -#define PREF_KEY_R @"R Button" -#define PREF_KEY_UP @"Up Button" -#define PREF_KEY_DOWN @"Down Button" -#define PREF_KEY_LEFT @"Left Button" -#define PREF_KEY_RIGHT @"Right Button" -#define PREF_KEY_START @"Start Button" -#define PREF_KEY_SELECT @"Select Button" - -void setAppDefaults(); //this is defined in preferences.m and should be called at app launch - -NSView *createPreferencesView(NSString *helpinfo, NSDictionary *options, id delegate); //utility func for creating a preference panel with a set of options +/* Copyright (C) 2007 Jeff Bland + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#import + +#define PREF_EXECUTE_UPON_LOAD @"Execute Upon Load" + +#define PREF_AFTER_LAUNCHED @"When Launching, Load" +#define PREF_AFTER_LAUNCHED_OPTION_NOTHING @"Load Nothing" +#define PREF_AFTER_LAUNCHED_OPTION_LAST_ROM @"Load Last ROM" + +#define PREF_FLASH_FILE @"Flash File" + +#ifdef GDB_STUB +#define PREF_ARM9_GDB_PORT @"arm9gdb" +#define PREF_ARM7_GDB_PORT @"arm7gdb" +#endif + +#define PREF_KEY_A @"A Button" +#define PREF_KEY_B @"B Button" +#define PREF_KEY_X @"X Button" +#define PREF_KEY_Y @"Y Button" +#define PREF_KEY_L @"L Button" +#define PREF_KEY_R @"R Button" +#define PREF_KEY_UP @"Up Button" +#define PREF_KEY_DOWN @"Down Button" +#define PREF_KEY_LEFT @"Left Button" +#define PREF_KEY_RIGHT @"Right Button" +#define PREF_KEY_START @"Start Button" +#define PREF_KEY_SELECT @"Select Button" + +void setAppDefaults(); //this is defined in preferences.m and should be called at app launch + +NSView *createPreferencesView(NSString *helpinfo, NSDictionary *options, id delegate); //utility func for creating a preference panel with a set of options diff --git a/desmume/src/cocoa/preferences.mm b/src/cocoa/preferences.mm similarity index 100% rename from desmume/src/cocoa/preferences.mm rename to src/cocoa/preferences.mm diff --git a/desmume/src/cocoa/screen_state.h b/src/cocoa/screen_state.h similarity index 96% rename from desmume/src/cocoa/screen_state.h rename to src/cocoa/screen_state.h index 0544f15fa..4e080d1c1 100644 --- a/desmume/src/cocoa/screen_state.h +++ b/src/cocoa/screen_state.h @@ -1,48 +1,48 @@ -/* Copyright (C) 2007 Jeff Bland - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#import "globals.h" - -#define DS_BPP 2 //bytes per pixel -#define DS_SCREEN_X_RATIO (256.0 / (192.0 * 2.0)) -#define DS_SCREEN_Y_RATIO ((192.0 * 2.0) / 256.0) -#define DS_SCREEN_WIDTH 256 -#define DS_SCREEN_HEIGHT 192 - -//This class is used to return screen data at the end of a frame -//we wrap it in a obj-c class so it can be passed to a selector -//and so we get retain/release niftyness -@interface ScreenState : NSObject -{ - @private - unsigned char color_data[DS_SCREEN_WIDTH * DS_SCREEN_HEIGHT*2 * DS_BPP]; -} -+ (NSInteger)width; -+ (NSInteger)height; -+ (NSSize)size; -+ (ScreenState*)blackScreenState; -+ (ScreenState*)whiteScreenState; -- (id)initWithBlack; -- (id)initWithWhite; -- (id)initWithScreenState:(ScreenState*)state; -- (id)initWithColorData:(const unsigned char*)data; -- (const unsigned char*)colorData; -- (NSImage*)image; -- (NSBitmapImageRep*)imageRep; +/* Copyright (C) 2007 Jeff Bland + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#import "globals.h" + +#define DS_BPP 2 //bytes per pixel +#define DS_SCREEN_X_RATIO (256.0 / (192.0 * 2.0)) +#define DS_SCREEN_Y_RATIO ((192.0 * 2.0) / 256.0) +#define DS_SCREEN_WIDTH 256 +#define DS_SCREEN_HEIGHT 192 + +//This class is used to return screen data at the end of a frame +//we wrap it in a obj-c class so it can be passed to a selector +//and so we get retain/release niftyness +@interface ScreenState : NSObject +{ + @private + unsigned char color_data[DS_SCREEN_WIDTH * DS_SCREEN_HEIGHT*2 * DS_BPP]; +} ++ (NSInteger)width; ++ (NSInteger)height; ++ (NSSize)size; ++ (ScreenState*)blackScreenState; ++ (ScreenState*)whiteScreenState; +- (id)initWithBlack; +- (id)initWithWhite; +- (id)initWithScreenState:(ScreenState*)state; +- (id)initWithColorData:(const unsigned char*)data; +- (const unsigned char*)colorData; +- (NSImage*)image; +- (NSBitmapImageRep*)imageRep; @end \ No newline at end of file diff --git a/desmume/src/cocoa/screen_state.m b/src/cocoa/screen_state.m similarity index 100% rename from desmume/src/cocoa/screen_state.m rename to src/cocoa/screen_state.m diff --git a/desmume/src/cocoa/screenshot.h b/src/cocoa/screenshot.h similarity index 97% rename from desmume/src/cocoa/screenshot.h rename to src/cocoa/screenshot.h index 5642aa314..0e235167e 100644 --- a/desmume/src/cocoa/screenshot.h +++ b/src/cocoa/screenshot.h @@ -1,26 +1,26 @@ -/* Copyright (C) 2007 Jeff Bland - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#import - -@class ScreenState; - -@interface Screenshot : NSObject {} -+ (void)saveScreenshotAs:(const ScreenState*)screen; -@end +/* Copyright (C) 2007 Jeff Bland + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#import + +@class ScreenState; + +@interface Screenshot : NSObject {} ++ (void)saveScreenshotAs:(const ScreenState*)screen; +@end diff --git a/desmume/src/cocoa/screenshot.mm b/src/cocoa/screenshot.mm similarity index 100% rename from desmume/src/cocoa/screenshot.mm rename to src/cocoa/screenshot.mm diff --git a/desmume/src/cocoa/sndOSX.h b/src/cocoa/sndOSX.h similarity index 96% rename from desmume/src/cocoa/sndOSX.h rename to src/cocoa/sndOSX.h index 432175347..a252db751 100644 --- a/desmume/src/cocoa/sndOSX.h +++ b/src/cocoa/sndOSX.h @@ -1,50 +1,50 @@ -/* Copyright 2007 Jeff Bland - - This file is part of DeSmuME. - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#define OBJ_C -#include "../SPU.h" -#undef OBJ_C - -#ifdef __cplusplus -extern "C" -{ -#endif - -#define SNDCORE_OSX 58325 //hopefully this is unique number - -//This is the sound inerface so the emulator core can send us sound info and whatnot -extern SoundInterface_struct SNDOSX; - -//Beyond this point are sound interface extensions specific to the mac port - - -int SNDOSXReset(); -void SNDOSXMuteAudio(); -void SNDOSXUnMuteAudio(); -void SNDOSXSetVolume(int volume); - -//Recording -bool SNDOSXOpenFile(void *fname); //opens a file for recording (if filename is the currently opened one, it will restart the file), fname is an NSString -void SNDOSXStartRecording(); //begins recording to the currently open file if there is an open file -void SNDOSXStopRecording(); //pauses recording (you can continue recording later) -void SNDOSXCloseFile(); //closes the file, making sure it's saved - -#ifdef __cplusplus -} +/* Copyright 2007 Jeff Bland + + This file is part of DeSmuME. + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#define OBJ_C +#include "../SPU.h" +#undef OBJ_C + +#ifdef __cplusplus +extern "C" +{ +#endif + +#define SNDCORE_OSX 58325 //hopefully this is unique number + +//This is the sound inerface so the emulator core can send us sound info and whatnot +extern SoundInterface_struct SNDOSX; + +//Beyond this point are sound interface extensions specific to the mac port + + +int SNDOSXReset(); +void SNDOSXMuteAudio(); +void SNDOSXUnMuteAudio(); +void SNDOSXSetVolume(int volume); + +//Recording +bool SNDOSXOpenFile(void *fname); //opens a file for recording (if filename is the currently opened one, it will restart the file), fname is an NSString +void SNDOSXStartRecording(); //begins recording to the currently open file if there is an open file +void SNDOSXStopRecording(); //pauses recording (you can continue recording later) +void SNDOSXCloseFile(); //closes the file, making sure it's saved + +#ifdef __cplusplus +} #endif \ No newline at end of file diff --git a/desmume/src/cocoa/sndOSX.mm b/src/cocoa/sndOSX.mm similarity index 100% rename from desmume/src/cocoa/sndOSX.mm rename to src/cocoa/sndOSX.mm diff --git a/desmume/src/cocoa/translations/English.lproj/Localizable.strings b/src/cocoa/translations/English.lproj/Localizable.strings similarity index 100% rename from desmume/src/cocoa/translations/English.lproj/Localizable.strings rename to src/cocoa/translations/English.lproj/Localizable.strings diff --git a/desmume/src/cocoa/translations/English.lproj/MainMenu.nib/classes.nib b/src/cocoa/translations/English.lproj/MainMenu.nib/classes.nib old mode 100755 new mode 100644 similarity index 100% rename from desmume/src/cocoa/translations/English.lproj/MainMenu.nib/classes.nib rename to src/cocoa/translations/English.lproj/MainMenu.nib/classes.nib diff --git a/desmume/src/cocoa/translations/English.lproj/MainMenu.nib/info.nib b/src/cocoa/translations/English.lproj/MainMenu.nib/info.nib old mode 100755 new mode 100644 similarity index 100% rename from desmume/src/cocoa/translations/English.lproj/MainMenu.nib/info.nib rename to src/cocoa/translations/English.lproj/MainMenu.nib/info.nib diff --git a/desmume/src/cocoa/translations/English.lproj/MainMenu.nib/keyedobjects.nib b/src/cocoa/translations/English.lproj/MainMenu.nib/keyedobjects.nib old mode 100755 new mode 100644 similarity index 100% rename from desmume/src/cocoa/translations/English.lproj/MainMenu.nib/keyedobjects.nib rename to src/cocoa/translations/English.lproj/MainMenu.nib/keyedobjects.nib diff --git a/desmume/src/cocoa/translations/French.lproj/Localizable.strings b/src/cocoa/translations/French.lproj/Localizable.strings similarity index 100% rename from desmume/src/cocoa/translations/French.lproj/Localizable.strings rename to src/cocoa/translations/French.lproj/Localizable.strings diff --git a/desmume/src/cocoa/translations/French.lproj/MainMenu.nib/classes.nib b/src/cocoa/translations/French.lproj/MainMenu.nib/classes.nib similarity index 100% rename from desmume/src/cocoa/translations/French.lproj/MainMenu.nib/classes.nib rename to src/cocoa/translations/French.lproj/MainMenu.nib/classes.nib diff --git a/desmume/src/cocoa/translations/French.lproj/MainMenu.nib/info.nib b/src/cocoa/translations/French.lproj/MainMenu.nib/info.nib similarity index 100% rename from desmume/src/cocoa/translations/French.lproj/MainMenu.nib/info.nib rename to src/cocoa/translations/French.lproj/MainMenu.nib/info.nib diff --git a/desmume/src/cocoa/translations/French.lproj/MainMenu.nib/keyedobjects.nib b/src/cocoa/translations/French.lproj/MainMenu.nib/keyedobjects.nib similarity index 100% rename from desmume/src/cocoa/translations/French.lproj/MainMenu.nib/keyedobjects.nib rename to src/cocoa/translations/French.lproj/MainMenu.nib/keyedobjects.nib diff --git a/desmume/src/cocoa/translations/Italian.lproj/Localizable.strings b/src/cocoa/translations/Italian.lproj/Localizable.strings similarity index 100% rename from desmume/src/cocoa/translations/Italian.lproj/Localizable.strings rename to src/cocoa/translations/Italian.lproj/Localizable.strings diff --git a/desmume/src/cocoa/translations/Chinese.lproj/MainMenu.nib/classes.nib b/src/cocoa/translations/Italian.lproj/MainMenu.nib/classes.nib similarity index 100% rename from desmume/src/cocoa/translations/Chinese.lproj/MainMenu.nib/classes.nib rename to src/cocoa/translations/Italian.lproj/MainMenu.nib/classes.nib diff --git a/desmume/src/cocoa/translations/Italian.lproj/MainMenu.nib/info.nib b/src/cocoa/translations/Italian.lproj/MainMenu.nib/info.nib similarity index 100% rename from desmume/src/cocoa/translations/Italian.lproj/MainMenu.nib/info.nib rename to src/cocoa/translations/Italian.lproj/MainMenu.nib/info.nib diff --git a/desmume/src/cocoa/translations/Italian.lproj/MainMenu.nib/keyedobjects.nib b/src/cocoa/translations/Italian.lproj/MainMenu.nib/keyedobjects.nib similarity index 100% rename from desmume/src/cocoa/translations/Italian.lproj/MainMenu.nib/keyedobjects.nib rename to src/cocoa/translations/Italian.lproj/MainMenu.nib/keyedobjects.nib diff --git a/desmume/src/cocoa/translations/Japanese.lproj/Localizable.strings b/src/cocoa/translations/Japanese.lproj/Localizable.strings similarity index 100% rename from desmume/src/cocoa/translations/Japanese.lproj/Localizable.strings rename to src/cocoa/translations/Japanese.lproj/Localizable.strings diff --git a/desmume/src/cocoa/translations/Japanese.lproj/MainMenu.nib/classes.nib b/src/cocoa/translations/Japanese.lproj/MainMenu.nib/classes.nib old mode 100755 new mode 100644 similarity index 100% rename from desmume/src/cocoa/translations/Japanese.lproj/MainMenu.nib/classes.nib rename to src/cocoa/translations/Japanese.lproj/MainMenu.nib/classes.nib diff --git a/desmume/src/cocoa/translations/Japanese.lproj/MainMenu.nib/info.nib b/src/cocoa/translations/Japanese.lproj/MainMenu.nib/info.nib old mode 100755 new mode 100644 similarity index 100% rename from desmume/src/cocoa/translations/Japanese.lproj/MainMenu.nib/info.nib rename to src/cocoa/translations/Japanese.lproj/MainMenu.nib/info.nib diff --git a/desmume/src/cocoa/translations/Japanese.lproj/MainMenu.nib/keyedobjects.nib b/src/cocoa/translations/Japanese.lproj/MainMenu.nib/keyedobjects.nib old mode 100755 new mode 100644 similarity index 100% rename from desmume/src/cocoa/translations/Japanese.lproj/MainMenu.nib/keyedobjects.nib rename to src/cocoa/translations/Japanese.lproj/MainMenu.nib/keyedobjects.nib diff --git a/desmume/src/cocoa/video_output_view.h b/src/cocoa/video_output_view.h similarity index 96% rename from desmume/src/cocoa/video_output_view.h rename to src/cocoa/video_output_view.h index d8c52cace..8f28b8c70 100644 --- a/desmume/src/cocoa/video_output_view.h +++ b/src/cocoa/video_output_view.h @@ -1,50 +1,50 @@ -/* Copyright (C) 2007 Jeff Bland - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#import "nds_control.h" - -//This class uses OpenGL for drawing for speed -//if opengl is not available it uses NSImage - -@class ScreenState; - -@interface VideoOutputView : -#ifdef HAVE_OPENGL -NSView -#else -NSImageView -#endif -{ -#ifdef HAVE_OPENGL - NSOpenGLContext* context; -#endif - ScreenState *screen_buffer; -} -//init -- (id)initWithFrame:(NSRect)frame; - -//image to display -- (void)setScreenState:(ScreenState*)screen; -- (const ScreenState*)screenState; - -//size in pixels of screen display (disreguarding rotation of the view) -- (float)screenHeight; -- (float)screenWidth; -@end - +/* Copyright (C) 2007 Jeff Bland + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#import "nds_control.h" + +//This class uses OpenGL for drawing for speed +//if opengl is not available it uses NSImage + +@class ScreenState; + +@interface VideoOutputView : +#ifdef HAVE_OPENGL +NSView +#else +NSImageView +#endif +{ +#ifdef HAVE_OPENGL + NSOpenGLContext* context; +#endif + ScreenState *screen_buffer; +} +//init +- (id)initWithFrame:(NSRect)frame; + +//image to display +- (void)setScreenState:(ScreenState*)screen; +- (const ScreenState*)screenState; + +//size in pixels of screen display (disreguarding rotation of the view) +- (float)screenHeight; +- (float)screenWidth; +@end + diff --git a/desmume/src/cocoa/video_output_view.mm b/src/cocoa/video_output_view.mm similarity index 100% rename from desmume/src/cocoa/video_output_view.mm rename to src/cocoa/video_output_view.mm diff --git a/desmume/src/commandline.cpp b/src/commandline.cpp similarity index 62% rename from desmume/src/commandline.cpp rename to src/commandline.cpp index 2a7ed7735..ce7a9217a 100644 --- a/desmume/src/commandline.cpp +++ b/src/commandline.cpp @@ -1,167 +1,117 @@ -/* commandline.cpp - - Copyright (C) 2009 DeSmuME team - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -*/ - -//windows note: make sure this file gets compiled with _cdecl - -#include - -#include -#include "commandline.h" -#include "types.h" -#include "movie.h" -#include "addons.h" - -int scanline_filter_a = 2, scanline_filter_b = 4; - -CommandLine::CommandLine() -: error(NULL) -, ctx(g_option_context_new ("")) -, is_cflash_configured(false) -{ - load_slot = 0; - arm9_gdb_port = arm7_gdb_port = 0; - single_core = 0; - start_paused = FALSE; -} - -CommandLine::~CommandLine() -{ - if(error) g_error_free (error); - g_option_context_free (ctx); -} - -static const char* _play_movie_file; -static const char* _record_movie_file; -static const char* _cflash_image; -static const char* _cflash_path; - -void CommandLine::loadCommonOptions() -{ - //these options should be available in every port. - //my advice is, do not be afraid of using #ifdef here if it makes sense. - //but also see the gtk port for an example of how to combine this with other options - //(you may need to use ifdefs to cause options to be entered in the desired order) - static const GOptionEntry options[] = { - { "load-slot", 0, 0, G_OPTION_ARG_INT, &load_slot, "Loads savegame from slot NUM", "NUM"}, - { "play-movie", 0, 0, G_OPTION_ARG_FILENAME, &_play_movie_file, "Specifies a dsm format movie to play", "PATH_TO_PLAY_MOVIE"}, - { "record-movie", 0, 0, G_OPTION_ARG_FILENAME, &_record_movie_file, "Specifies a path to a new dsm format movie", "PATH_TO_RECORD_MOVIE"}, - { "start-paused", 0, 0, G_OPTION_ARG_NONE, &start_paused, "Indicates that emulation should start paused", "START_PAUSED"}, - { "cflash-image", 0, 0, G_OPTION_ARG_FILENAME, &_cflash_image, "Requests cflash in gbaslot with fat image at this path", "CFLASH_IMAGE"}, - { "cflash-path", 0, 0, G_OPTION_ARG_FILENAME, &_cflash_path, "Requests cflash in gbaslot with filesystem rooted at this path", "CFLASH_PATH"}, -#ifdef _MSC_VER - { "single-core", 0, 0, G_OPTION_ARG_NONE, &single_core, "Limit execution to use approximately only one core", "NUM_CORES"}, - { "scanline-filter-a", 0, 0, G_OPTION_ARG_INT, &scanline_filter_a, "Intensity of fadeout for scanlines filter (edge) (default 2)", "SCANLINE_FILTER_A"}, - { "scanline-filter-b", 0, 0, G_OPTION_ARG_INT, &scanline_filter_b, "Intensity of fadeout for scanlines filter (corner) (default 4)", "SCANLINE_FILTER_B"}, -#endif - #ifdef GDB_STUB - { "arm9gdb", 0, 0, G_OPTION_ARG_INT, &arm9_gdb_port, "Enable the ARM9 GDB stub on the given port", "PORT_NUM"}, - { "arm7gdb", 0, 0, G_OPTION_ARG_INT, &arm7_gdb_port, "Enable the ARM7 GDB stub on the given port", "PORT_NUM"}, - #endif - { NULL } - }; - - g_option_context_add_main_entries (ctx, options, "options"); -} - -bool CommandLine::parse(int argc,char **argv) -{ - g_option_context_parse (ctx, &argc, &argv, &error); - if (error) - { - g_printerr("Error parsing command line arguments: %s\n", error->message); - return false; - } - - if(_play_movie_file) play_movie_file = _play_movie_file; - if(_record_movie_file) record_movie_file = _record_movie_file; - if(_cflash_image) cflash_image = _cflash_image; - if(_cflash_path) cflash_path = _cflash_path; - - - if (argc == 2) - nds_file = argv[1]; - if (argc > 2) - return false; - - return true; -} - -bool CommandLine::validate() -{ - if (load_slot < 0 || load_slot > 10) { - g_printerr("I only know how to load from slots 1-10, 0 means 'do not load savegame' and is default\n"); - return false; - } - - if(play_movie_file != "" && record_movie_file != "") { - g_printerr("Cannot both play and record a movie.\n"); - return false; - } - - if(record_movie_file != "" && load_slot != 0) { - g_printerr("Cannot both record a movie and load a savestate.\n"); - return false; - } - - if(cflash_path != "" && cflash_image != "") { - g_printerr("Cannot specify both cflash-image and cflash-path.\n"); - return false; - } - - return true; -} - -void CommandLine::errorHelp(const char* binName) -{ - //TODO - strip this down to just the filename - g_printerr("USAGE: %s [options] [nds-file]\n", binName); - g_printerr("USAGE: %s --help - for help\n", binName); -} - -void CommandLine::process_movieCommands() -{ - if(play_movie_file != "") - { - FCEUI_LoadMovie(play_movie_file.c_str(),true,false,-1); - } - else if(record_movie_file != "") - { - FCEUI_SaveMovie(record_movie_file.c_str(), L"", 0, NULL); - } -} - -void CommandLine::process_addonCommands() -{ - if (cflash_image != "") - { - CFlash_Mode = ADDON_CFLASH_MODE_File; - CFlash_Path = cflash_image; - is_cflash_configured = true; - } - if (cflash_path != "") - { - CFlash_Mode = ADDON_CFLASH_MODE_Path; - CFlash_Path = cflash_path; - is_cflash_configured = true; - } - -} - +/* commandline.cpp + + Copyright (C) 2009 DeSmuME team + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA +*/ + +//windows note: make sure this file gets compiled with _cdecl + +#include + +#include +#include "commandline.h" +#include "types.h" + +CommandLine::CommandLine() +: error(NULL) +, ctx(g_option_context_new ("")) +{ + load_slot = 0; + arm9_gdb_port = arm7_gdb_port = 0; +} + +CommandLine::~CommandLine() +{ + if(error) g_error_free (error); + g_option_context_free (ctx); +} + +static const char* _play_movie_file; +static const char* _record_movie_file; + +void CommandLine::loadCommonOptions() +{ + //these options should be available in every port. + //my advice is, do not be afraid of using #ifdef here if it makes sense. + //but also see the gtk port for an example of how to combine this with other options + //(you may need to use ifdefs to cause options to be entered in the desired order) + static const GOptionEntry options[] = { + { "load-slot", 0, 0, G_OPTION_ARG_INT, &load_slot, "Loads savegame from slot NUM", "NUM"}, + { "play-movie", 0, 0, G_OPTION_ARG_FILENAME, &_play_movie_file, "Specifies a dsm format movie to play", "PATH_TO_PLAY_MOVIE"}, + { "record-movie", 0, 0, G_OPTION_ARG_FILENAME, &_record_movie_file, "Specifies a path to a new dsm format movie", "PATH_TO_RECORD_MOVIE"}, + #ifdef GDB_STUB + { "arm9gdb", 0, 0, G_OPTION_ARG_INT, &arm9_gdb_port, "Enable the ARM9 GDB stub on the given port", "PORT_NUM"}, + { "arm7gdb", 0, 0, G_OPTION_ARG_INT, &arm7_gdb_port, "Enable the ARM7 GDB stub on the given port", "PORT_NUM"}, + #endif + { NULL } + }; + + g_option_context_add_main_entries (ctx, options, "options"); +} + +bool CommandLine::parse(int argc,char **argv) +{ + g_option_context_parse (ctx, &argc, &argv, &error); + if (error) + { + g_printerr("Error parsing command line arguments: %s\n", error->message); + return false; + } + + if(_play_movie_file) play_movie_file = _play_movie_file; + if(_record_movie_file) record_movie_file = _record_movie_file; + + if (argc == 2) + nds_file = argv[1]; + if (argc > 2) + return false; + + return true; +} + +bool CommandLine::validate() +{ + if (load_slot < 0 || load_slot > 10) { + g_printerr("I only know how to load from slots 1-10, 0 means 'do not load savegame' and is default\n"); + return false; + } + + if(play_movie_file != "" && record_movie_file != "") { + g_printerr("Cannot both play and record a movie.\n"); + return false; + } + + if(record_movie_file != "" && load_slot != 0) { + g_printerr("Cannot both record a movie and load a savestate.\n"); + return false; + } + + return true; +} + +void CommandLine::errorHelp(const char* binName) +{ + //TODO - strip this down to just the filename + g_printerr("USAGE: %s [options] [nds-file]\n", binName); + g_printerr("USAGE: %s --help - for help\n", binName); +} + +//void foo() +//{ +// g_option_context_free(NULL); +//} diff --git a/desmume/src/commandline.h b/src/commandline.h similarity index 86% rename from desmume/src/commandline.h rename to src/commandline.h index b550be083..506763022 100644 --- a/desmume/src/commandline.h +++ b/src/commandline.h @@ -1,73 +1,63 @@ -/* commandline.h - - Copyright (C) 2009 DeSmuME team - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -*/ - -#ifndef _COMMANDLINE_H_ -#define _COMMANDLINE_H_ - -#include - -//I hate C. we have to forward declare these with more detail than I like -typedef struct _GOptionContext GOptionContext; -typedef struct _GError GError; - -//this class will also eventually try to take over the responsibility of using the args that it handles -//for example: preparing the emulator run by loading the rom, savestate, and/or movie in the correct pattern. -//it should also populate CommonSettings with its initial values - -class CommandLine -{ -public: - //actual options: these may move to another sturct - int load_slot; - std::string nds_file; - std::string play_movie_file; - std::string record_movie_file; - int arm9_gdb_port, arm7_gdb_port; - int single_core; - int start_paused; - std::string cflash_image; - std::string cflash_path; - - //load up the common commandline options - void loadCommonOptions(); - - bool parse(int argc,char **argv); - - //validate the common commandline options - bool validate(); - - //process movie play/record commands - void process_movieCommands(); - //etc. - void process_addonCommands(); - bool is_cflash_configured; - - //print a little help message for cases when erroneous commandlines are entered - void errorHelp(const char* binName); - - CommandLine(); - ~CommandLine(); - - GError *error; - GOptionContext *ctx; -}; - -#endif +/* commandline.h + + Copyright (C) 2009 DeSmuME team + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA +*/ + +#ifndef _COMMANDLINE_H_ +#define _COMMANDLINE_H_ + +#include + +//I hate C. we have to forward declare these with more detail than I like +typedef struct _GOptionContext GOptionContext; +typedef struct _GError GError; + +//this class will also eventually try to take over the responsibility of using the args that it handles +//for example: preparing the emulator run by loading the rom, savestate, and/or movie in the correct pattern. +//it should also populate CommonSettings with its initial values + +class CommandLine +{ +public: + //actual options: these may move to another sturct + int load_slot; + std::string nds_file; + std::string play_movie_file; + std::string record_movie_file; + int arm9_gdb_port, arm7_gdb_port; + + //load up the common commandline options + void loadCommonOptions(); + + bool parse(int argc,char **argv); + + //validate the common commandline options + bool validate(); + + //print a little help message for cases when erroneous commandlines are entered + void errorHelp(const char* binName); + + CommandLine(); + ~CommandLine(); + + GOptionContext *ctx; + GError *error; +}; + +#endif diff --git a/desmume/src/common.cpp b/src/common.cpp similarity index 79% rename from desmume/src/common.cpp rename to src/common.cpp index 1a8cb5f5a..3aaa1614d 100644 --- a/desmume/src/common.cpp +++ b/src/common.cpp @@ -66,18 +66,6 @@ void GetINIPath() } } -void WritePrivateProfileBool(char* appname, char* keyname, bool val, char* file) -{ - char temp[256] = ""; - sprintf(temp, "%d", val?1:0); - WritePrivateProfileString(appname, keyname, temp, file); -} - -bool GetPrivateProfileBool(const char* appname, const char* keyname, bool defval, const char* filename) -{ - return GetPrivateProfileInt(appname,keyname,defval?1:0,filename) != 0; -} - void WritePrivateProfileInt(char* appname, char* keyname, int val, char* file) { char temp[256] = ""; @@ -119,4 +107,46 @@ u32 strlen_ws(char *buf) // length without last spaces if (buf[i]!=32) return (i-1); // space } return 0; +} + +std::string RomName = ""; //Stores the name of the Rom currently loaded in memory + +/*** + * Author: adelikat + * Date Added: May 8, 2009 + * Description: Sets the Global variable RomName + * Known Usage: + * LoadRom + **/ +void SetRomName(const char *filename) +{ + std::string str = filename; + + //Truncate the path from filename + int x = str.find_last_of("/\\"); + if (x > 0) + str = str.substr(x+1); + RomName = str; +} + +/*** + * Author: adelikat + * Date Added: May 8, 2009 + * Description: Returns the Global variable RomName + * Known Usage: + * included in main.h + * ramwatch.cpp - SaveStrings + **/ + +const char *GetRomName() +{ + return RomName.c_str(); +} + +std::string GetRomNameWithoutExtension() +{ + int x = RomName.find_first_of("."); + if (x > 0) + return RomName.substr(0,x); + else return RomName; } \ No newline at end of file diff --git a/desmume/src/common.h b/src/common.h similarity index 93% rename from desmume/src/common.h rename to src/common.h index b142fbce4..16484adf1 100644 --- a/desmume/src/common.h +++ b/src/common.h @@ -29,6 +29,11 @@ #include extern u8 gba_header_data_0x04[156]; +const char* GetRomName(); //adelikat: return the name of the Rom currently loaded +std::string GetRomNameWithoutExtension(); +void SetRomName(const char *filename); + + #ifdef WIN32 #include @@ -72,9 +77,7 @@ extern u8 gba_header_data_0x04[156]; extern void GetINIPath(); extern void WritePrivateProfileInt(char* appname, char* keyname, int val, char* file); - bool GetPrivateProfileBool(const char* appname, const char* keyname, bool defval, const char* filename); - void WritePrivateProfileBool(char* appname, char* keyname, bool val, char* file); - + #define EXPERIMENTAL_GBASLOT 1 #else // non Windows #define sscanf_s sscanf diff --git a/desmume/src/cp15.cpp b/src/cp15.cpp similarity index 96% rename from desmume/src/cp15.cpp rename to src/cp15.cpp index 2b646c5c6..7f65f49e4 100644 --- a/desmume/src/cp15.cpp +++ b/src/cp15.cpp @@ -1,595 +1,595 @@ -/* Copyright (C) 2006 yopyop - yopyop156@ifrance.com - yopyop156.ifrance.com - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#include - -#include "cp15.h" -#include "debug.h" -#include "MMU.h" - -armcp15_t *armcp15_new(armcpu_t * c) -{ - int i; - armcp15_t *armcp15 = (armcp15_t*)malloc(sizeof(armcp15_t)); - if(!armcp15) return NULL; - - armcp15->cpu = c; - armcp15->IDCode = 0x41049460; - armcp15->cacheType = 0x0F0D2112; - armcp15->TCMSize = 0x00140140; - armcp15->ctrl = 0x00000000; - armcp15->DCConfig = 0x0; - armcp15->ICConfig = 0x0; - armcp15->writeBuffCtrl = 0x0; - armcp15->und = 0x0; - armcp15->DaccessPerm = 0x22222222; - armcp15->IaccessPerm = 0x22222222; - armcp15->protectBaseSize0 = 0x0; - armcp15->protectBaseSize1 = 0x0; - armcp15->protectBaseSize2 = 0x0; - armcp15->protectBaseSize3 = 0x0; - armcp15->protectBaseSize4 = 0x0; - armcp15->protectBaseSize5 = 0x0; - armcp15->protectBaseSize6 = 0x0; - armcp15->protectBaseSize7 = 0x0; - armcp15->cacheOp = 0x0; - armcp15->DcacheLock = 0x0; - armcp15->IcacheLock = 0x0; - armcp15->ITCMRegion = 0x0C; - armcp15->DTCMRegion = 0x0080000A; - armcp15->processID = 0; - - /* preset calculated regionmasks */ - for (i=0;i<8;i++) { - armcp15->regionWriteMask_USR[i] = 0 ; - armcp15->regionWriteMask_SYS[i] = 0 ; - armcp15->regionReadMask_USR[i] = 0 ; - armcp15->regionReadMask_SYS[i] = 0 ; - armcp15->regionExecuteMask_USR[i] = 0 ; - armcp15->regionExecuteMask_SYS[i] = 0 ; - armcp15->regionWriteSet_USR[i] = 0 ; - armcp15->regionWriteSet_SYS[i] = 0 ; - armcp15->regionReadSet_USR[i] = 0 ; - armcp15->regionReadSet_SYS[i] = 0 ; - armcp15->regionExecuteSet_USR[i] = 0 ; - armcp15->regionExecuteSet_SYS[i] = 0 ; - } ; - - return armcp15; -} - -#define ACCESSTYPE(val,n) (((val) >> (4*n)) & 0x0F) -#define SIZEIDENTIFIER(val) ((((val) >> 1) & 0x1F)) -#define SIZEBINARY(val) (1 << (SIZEIDENTIFIER(val)+1)) -#define MASKFROMREG(val) (~((SIZEBINARY(val)-1) | 0x3F)) -#define SETFROMREG(val) ((val) & MASKFROMREG(val)) -/* sets the precalculated regions to mask,set for the affected accesstypes */ -static void armcp15_setSingleRegionAccess(armcp15_t *armcp15,u32 dAccess,u32 iAccess,unsigned char num, u32 mask,u32 set) { - - switch (ACCESSTYPE(dAccess,num)) { - case 4: /* UNP */ - case 7: /* UNP */ - case 8: /* UNP */ - case 9: /* UNP */ - case 10: /* UNP */ - case 11: /* UNP */ - case 12: /* UNP */ - case 13: /* UNP */ - case 14: /* UNP */ - case 15: /* UNP */ - case 0: /* no access at all */ - armcp15->regionWriteMask_USR[num] = 0 ; - armcp15->regionWriteSet_USR[num] = 0xFFFFFFFF ; - armcp15->regionReadMask_USR[num] = 0 ; - armcp15->regionReadSet_USR[num] = 0xFFFFFFFF ; - armcp15->regionWriteMask_SYS[num] = 0 ; - armcp15->regionWriteSet_SYS[num] = 0xFFFFFFFF ; - armcp15->regionReadMask_SYS[num] = 0 ; - armcp15->regionReadSet_SYS[num] = 0xFFFFFFFF ; - break ; - case 1: /* no access at USR, all to sys */ - armcp15->regionWriteMask_USR[num] = 0 ; - armcp15->regionWriteSet_USR[num] = 0xFFFFFFFF ; - armcp15->regionReadMask_USR[num] = 0 ; - armcp15->regionReadSet_USR[num] = 0xFFFFFFFF ; - armcp15->regionWriteMask_SYS[num] = mask ; - armcp15->regionWriteSet_SYS[num] = set ; - armcp15->regionReadMask_SYS[num] = mask ; - armcp15->regionReadSet_SYS[num] = set ; - break ; - case 2: /* read at USR, all to sys */ - armcp15->regionWriteMask_USR[num] = 0 ; - armcp15->regionWriteSet_USR[num] = 0xFFFFFFFF ; - armcp15->regionReadMask_USR[num] = mask ; - armcp15->regionReadSet_USR[num] = set ; - armcp15->regionWriteMask_SYS[num] = mask ; - armcp15->regionWriteSet_SYS[num] = set ; - armcp15->regionReadMask_SYS[num] = mask ; - armcp15->regionReadSet_SYS[num] = set ; - break ; - case 3: /* all to USR, all to sys */ - armcp15->regionWriteMask_USR[num] = mask ; - armcp15->regionWriteSet_USR[num] = set ; - armcp15->regionReadMask_USR[num] = mask ; - armcp15->regionReadSet_USR[num] = set ; - armcp15->regionWriteMask_SYS[num] = mask ; - armcp15->regionWriteSet_SYS[num] = set ; - armcp15->regionReadMask_SYS[num] = mask ; - armcp15->regionReadSet_SYS[num] = set ; - break ; - case 5: /* no access at USR, read to sys */ - armcp15->regionWriteMask_USR[num] = 0 ; - armcp15->regionWriteSet_USR[num] = 0xFFFFFFFF ; - armcp15->regionReadMask_USR[num] = 0 ; - armcp15->regionReadSet_USR[num] = 0xFFFFFFFF ; - armcp15->regionWriteMask_SYS[num] = 0 ; - armcp15->regionWriteSet_SYS[num] = 0xFFFFFFFF ; - armcp15->regionReadMask_SYS[num] = mask ; - armcp15->regionReadSet_SYS[num] = set ; - break ; - case 6: /* read at USR, read to sys */ - armcp15->regionWriteMask_USR[num] = 0 ; - armcp15->regionWriteSet_USR[num] = 0xFFFFFFFF ; - armcp15->regionReadMask_USR[num] = mask ; - armcp15->regionReadSet_USR[num] = set ; - armcp15->regionWriteMask_SYS[num] = 0 ; - armcp15->regionWriteSet_SYS[num] = 0xFFFFFFFF ; - armcp15->regionReadMask_SYS[num] = mask ; - armcp15->regionReadSet_SYS[num] = set ; - break ; - } - switch (ACCESSTYPE(iAccess,num)) { - case 4: /* UNP */ - case 7: /* UNP */ - case 8: /* UNP */ - case 9: /* UNP */ - case 10: /* UNP */ - case 11: /* UNP */ - case 12: /* UNP */ - case 13: /* UNP */ - case 14: /* UNP */ - case 15: /* UNP */ - case 0: /* no access at all */ - armcp15->regionExecuteMask_USR[num] = 0 ; - armcp15->regionExecuteSet_USR[num] = 0xFFFFFFFF ; - armcp15->regionExecuteMask_SYS[num] = 0 ; - armcp15->regionExecuteSet_SYS[num] = 0xFFFFFFFF ; - break ; - case 1: - armcp15->regionExecuteMask_USR[num] = 0 ; - armcp15->regionExecuteSet_USR[num] = 0xFFFFFFFF ; - armcp15->regionExecuteMask_SYS[num] = mask ; - armcp15->regionExecuteSet_SYS[num] = set ; - break ; - case 2: - case 3: - case 6: - armcp15->regionExecuteMask_USR[num] = mask ; - armcp15->regionExecuteSet_USR[num] = set ; - armcp15->regionExecuteMask_SYS[num] = mask ; - armcp15->regionExecuteSet_SYS[num] = set ; - break ; - } -} ; - -/* precalculate region masks/sets from cp15 register */ -static void armcp15_maskPrecalc(armcp15_t *armcp15) -{ - #define precalc(num) { \ - u32 mask = 0, set = 0xFFFFFFFF ; /* (x & 0) == 0xFF..FF is allways false (disabled) */ \ - if (BIT_N(armcp15->protectBaseSize##num,0)) /* if region is enabled */ \ - { /* reason for this define: naming includes var */ \ - mask = MASKFROMREG(armcp15->protectBaseSize##num) ; \ - set = SETFROMREG(armcp15->protectBaseSize##num) ; \ - if (SIZEIDENTIFIER(armcp15->protectBaseSize##num)==0x1F) \ - { /* for the 4GB region, u32 suffers wraparound */ \ - mask = 0 ; set = 0 ; /* (x & 0) == 0 is allways true (enabled) */ \ - } \ - } \ - armcp15_setSingleRegionAccess(armcp15,armcp15->DaccessPerm,armcp15->IaccessPerm,num,mask,set) ; \ - } - precalc(0) ; - precalc(1) ; - precalc(2) ; - precalc(3) ; - precalc(4) ; - precalc(5) ; - precalc(6) ; - precalc(7) ; -} - -INLINE BOOL armcp15_isAccessAllowed(armcp15_t *armcp15,u32 address,u32 access) -{ - int i ; - if (!(armcp15->ctrl & 1)) return TRUE ; /* protection checking is not enabled */ - for (i=0;i<8;i++) { - switch (access) { - case CP15_ACCESS_WRITEUSR: - if ((address & armcp15->regionWriteMask_USR[i]) == armcp15->regionWriteSet_USR[i]) return TRUE ; - break ; - case CP15_ACCESS_WRITESYS: - if ((address & armcp15->regionWriteMask_SYS[i]) == armcp15->regionWriteSet_SYS[i]) return TRUE ; - break ; - case CP15_ACCESS_READUSR: - if ((address & armcp15->regionReadMask_USR[i]) == armcp15->regionReadSet_USR[i]) return TRUE ; - break ; - case CP15_ACCESS_READSYS: - if ((address & armcp15->regionReadMask_SYS[i]) == armcp15->regionReadSet_SYS[i]) return TRUE ; - break ; - case CP15_ACCESS_EXECUSR: - if ((address & armcp15->regionExecuteMask_USR[i]) == armcp15->regionExecuteSet_USR[i]) return TRUE ; - break ; - case CP15_ACCESS_EXECSYS: - if ((address & armcp15->regionExecuteMask_SYS[i]) == armcp15->regionExecuteSet_SYS[i]) return TRUE ; - break ; - } - } - /* when protections are enabled, but no region allows access, deny access */ - return FALSE ; -} - -BOOL armcp15_dataProcess(armcp15_t *armcp15, u8 CRd, u8 CRn, u8 CRm, u8 opcode1, u8 opcode2) -{ - LOG("Unsupported CP15 operation : DataProcess\n"); - return FALSE; -} - -BOOL armcp15_load(armcp15_t *armcp15, u8 CRd, u8 adr) -{ - LOG("Unsupported CP15 operation : Load\n"); - return FALSE; -} - -BOOL armcp15_store(armcp15_t *armcp15, u8 CRd, u8 adr) -{ - LOG("Unsupported CP15 operation : Store\n"); - return FALSE; -} - -BOOL armcp15_moveCP2ARM(armcp15_t *armcp15, u32 * R, u8 CRn, u8 CRm, u8 opcode1, u8 opcode2) -{ - if(armcp15->cpu->CPSR.bits.mode == USR) return FALSE; - - switch(CRn) - { - case 0 : - if((opcode1 == 0)&&(CRm==0)) - { - switch(opcode2) - { - case 1 : - *R = armcp15->cacheType; - return TRUE; - case 2 : - *R = armcp15->TCMSize; - return TRUE; - default : - *R = armcp15->IDCode; - return TRUE; - } - } - return FALSE; - case 1 : - if((opcode1==0) && (opcode2==0) && (CRm==0)) - { - *R = armcp15->ctrl; - return TRUE; - } - return FALSE; - - case 2 : - if((opcode1==0) && (CRm==0)) - { - switch(opcode2) - { - case 0 : - *R = armcp15->DCConfig; - return TRUE; - case 1 : - *R = armcp15->ICConfig; - return TRUE; - default : - return FALSE; - } - } - return FALSE; - case 3 : - if((opcode1==0) && (opcode2==0) && (CRm==0)) - { - *R = armcp15->writeBuffCtrl; - return TRUE; - } - return FALSE; - case 5 : - if((opcode1==0) && (CRm==0)) - { - switch(opcode2) - { - case 2 : - *R = armcp15->DaccessPerm; - return TRUE; - case 3 : - *R = armcp15->IaccessPerm; - return TRUE; - default : - return FALSE; - } - } - return FALSE; - case 6 : - if((opcode1==0) && (opcode2==0)) - { - switch(CRm) - { - case 0 : - *R = armcp15->protectBaseSize0; - return TRUE; - case 1 : - *R = armcp15->protectBaseSize1; - return TRUE; - case 2 : - *R = armcp15->protectBaseSize2; - return TRUE; - case 3 : - *R = armcp15->protectBaseSize3; - return TRUE; - case 4 : - *R = armcp15->protectBaseSize4; - return TRUE; - case 5 : - *R = armcp15->protectBaseSize5; - return TRUE; - case 6 : - *R = armcp15->protectBaseSize6; - return TRUE; - case 7 : - *R = armcp15->protectBaseSize7; - return TRUE; - default : - return FALSE; - } - } - return FALSE; - case 9 : - if((opcode1==0)) - { - switch(CRm) - { - case 0 : - switch(opcode2) - { - case 0 : - *R = armcp15->DcacheLock; - return TRUE; - case 1 : - *R = armcp15->IcacheLock; - return TRUE; - default : - return FALSE; - } - case 1 : - switch(opcode2) - { - case 0 : - *R = armcp15->DTCMRegion; - return TRUE; - case 1 : - *R = armcp15->ITCMRegion; - return TRUE; - default : - return FALSE; - } - } - } - return FALSE; - default : - LOG("Unsupported CP15 operation : MRC\n"); - return FALSE; - } -} - - -static u32 CP15wait4IRQ(armcpu_t *cpu) -{ - /* on the first call, wirq is not set */ - if(cpu->wirq) - { - /* check wether an irq was issued */ - if(!cpu->waitIRQ) - { - cpu->waitIRQ = 0; - cpu->wirq = 0; - return 1; /* return execution */ - } - /* otherwise, repeat this instruction */ - cpu->R[15] = cpu->instruct_adr; - cpu->next_instruction = cpu->R[15]; - return 1; - } - /* first run, set us into waiting state */ - cpu->waitIRQ = 1; - cpu->wirq = 1; - /* and set next instruction to repeat this */ - cpu->R[15] = cpu->instruct_adr; - cpu->next_instruction = cpu->R[15]; - /* CHECKME: IME shouldn't be modified (?) */ - MMU.reg_IME[0] = 1; - return 1; -} - -BOOL armcp15_moveARM2CP(armcp15_t *armcp15, u32 val, u8 CRn, u8 CRm, u8 opcode1, u8 opcode2) -{ - if(armcp15->cpu->CPSR.bits.mode == USR) return FALSE; - - switch(CRn) - { - case 1 : - if((opcode1==0) && (opcode2==0) && (CRm==0)) - { - armcp15->ctrl = val; - MMU.ARM9_RW_MODE = BIT7(val); - armcp15->cpu->intVector = 0x0FFF0000 * (BIT13(val)); - armcp15->cpu->LDTBit = !BIT15(val); //TBit - /*if(BIT17(val)) - { - log::ajouter("outch !!!!!!!"); - } - if(BIT19(val)) - { - log::ajouter("outch !!!!!!!"); - }*/ - return TRUE; - } - return FALSE; - case 2 : - if((opcode1==0) && (CRm==0)) - { - switch(opcode2) - { - case 0 : - armcp15->DCConfig = val; - return TRUE; - case 1 : - armcp15->ICConfig = val; - return TRUE; - default : - return FALSE; - } - } - return FALSE; - case 3 : - if((opcode1==0) && (opcode2==0) && (CRm==0)) - { - armcp15->writeBuffCtrl = val; - return TRUE; - } - return FALSE; - case 5 : - if((opcode1==0) && (CRm==0)) - { - switch(opcode2) - { - case 2 : - armcp15->DaccessPerm = val; - armcp15_maskPrecalc(armcp15); - return TRUE; - case 3 : - armcp15->IaccessPerm = val; - armcp15_maskPrecalc(armcp15); - return TRUE; - default : - return FALSE; - } - } - return FALSE; - case 6 : - if((opcode1==0) && (opcode2==0)) - { - switch(CRm) - { - case 0 : - armcp15->protectBaseSize0 = val; - armcp15_maskPrecalc(armcp15) ; - return TRUE; - case 1 : - armcp15->protectBaseSize1 = val; - armcp15_maskPrecalc(armcp15) ; - return TRUE; - case 2 : - armcp15->protectBaseSize2 = val; - armcp15_maskPrecalc(armcp15) ; - return TRUE; - case 3 : - armcp15->protectBaseSize3 = val; - armcp15_maskPrecalc(armcp15) ; - return TRUE; - case 4 : - armcp15->protectBaseSize4 = val; - armcp15_maskPrecalc(armcp15) ; - return TRUE; - case 5 : - armcp15->protectBaseSize5 = val; - armcp15_maskPrecalc(armcp15) ; - return TRUE; - case 6 : - armcp15->protectBaseSize6 = val; - armcp15_maskPrecalc(armcp15) ; - return TRUE; - case 7 : - armcp15->protectBaseSize7 = val; - armcp15_maskPrecalc(armcp15) ; - return TRUE; - default : - return FALSE; - } - } - return FALSE; - case 7 : - if((CRm==0)&&(opcode1==0)&&((opcode2==4))) - { - CP15wait4IRQ(armcp15->cpu); - return TRUE; - } - return FALSE; - case 9 : - if((opcode1==0)) - { - switch(CRm) - { - case 0 : - switch(opcode2) - { - case 0 : - armcp15->DcacheLock = val; - return TRUE; - case 1 : - armcp15->IcacheLock = val; - return TRUE; - default : - return FALSE; - } - case 1 : - switch(opcode2) - { - case 0 : - armcp15->DTCMRegion = val; - MMU.DTCMRegion = val & 0x0FFFFFFC0; - /*sprintf(logbuf, "%08X", val); - log::ajouter(logbuf);*/ - return TRUE; - case 1 : - armcp15->ITCMRegion = val; - /* ITCM base is not writeable! */ - MMU.ITCMRegion = 0; - return TRUE; - default : - return FALSE; - } - } - } - return FALSE; - default : - return FALSE; - } -} - - - +/* Copyright (C) 2006 yopyop + yopyop156@ifrance.com + yopyop156.ifrance.com + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#include + +#include "cp15.h" +#include "debug.h" +#include "MMU.h" + +armcp15_t *armcp15_new(armcpu_t * c) +{ + int i; + armcp15_t *armcp15 = (armcp15_t*)malloc(sizeof(armcp15_t)); + if(!armcp15) return NULL; + + armcp15->cpu = c; + armcp15->IDCode = 0x41049460; + armcp15->cacheType = 0x0F0D2112; + armcp15->TCMSize = 0x00140140; + armcp15->ctrl = 0x00000000; + armcp15->DCConfig = 0x0; + armcp15->ICConfig = 0x0; + armcp15->writeBuffCtrl = 0x0; + armcp15->und = 0x0; + armcp15->DaccessPerm = 0x22222222; + armcp15->IaccessPerm = 0x22222222; + armcp15->protectBaseSize0 = 0x0; + armcp15->protectBaseSize1 = 0x0; + armcp15->protectBaseSize2 = 0x0; + armcp15->protectBaseSize3 = 0x0; + armcp15->protectBaseSize4 = 0x0; + armcp15->protectBaseSize5 = 0x0; + armcp15->protectBaseSize6 = 0x0; + armcp15->protectBaseSize7 = 0x0; + armcp15->cacheOp = 0x0; + armcp15->DcacheLock = 0x0; + armcp15->IcacheLock = 0x0; + armcp15->ITCMRegion = 0x0C; + armcp15->DTCMRegion = 0x0080000A; + armcp15->processID = 0; + + /* preset calculated regionmasks */ + for (i=0;i<8;i++) { + armcp15->regionWriteMask_USR[i] = 0 ; + armcp15->regionWriteMask_SYS[i] = 0 ; + armcp15->regionReadMask_USR[i] = 0 ; + armcp15->regionReadMask_SYS[i] = 0 ; + armcp15->regionExecuteMask_USR[i] = 0 ; + armcp15->regionExecuteMask_SYS[i] = 0 ; + armcp15->regionWriteSet_USR[i] = 0 ; + armcp15->regionWriteSet_SYS[i] = 0 ; + armcp15->regionReadSet_USR[i] = 0 ; + armcp15->regionReadSet_SYS[i] = 0 ; + armcp15->regionExecuteSet_USR[i] = 0 ; + armcp15->regionExecuteSet_SYS[i] = 0 ; + } ; + + return armcp15; +} + +#define ACCESSTYPE(val,n) (((val) >> (4*n)) & 0x0F) +#define SIZEIDENTIFIER(val) ((((val) >> 1) & 0x1F)) +#define SIZEBINARY(val) (1 << (SIZEIDENTIFIER(val)+1)) +#define MASKFROMREG(val) (~((SIZEBINARY(val)-1) | 0x3F)) +#define SETFROMREG(val) ((val) & MASKFROMREG(val)) +/* sets the precalculated regions to mask,set for the affected accesstypes */ +static void armcp15_setSingleRegionAccess(armcp15_t *armcp15,u32 dAccess,u32 iAccess,unsigned char num, u32 mask,u32 set) { + + switch (ACCESSTYPE(dAccess,num)) { + case 4: /* UNP */ + case 7: /* UNP */ + case 8: /* UNP */ + case 9: /* UNP */ + case 10: /* UNP */ + case 11: /* UNP */ + case 12: /* UNP */ + case 13: /* UNP */ + case 14: /* UNP */ + case 15: /* UNP */ + case 0: /* no access at all */ + armcp15->regionWriteMask_USR[num] = 0 ; + armcp15->regionWriteSet_USR[num] = 0xFFFFFFFF ; + armcp15->regionReadMask_USR[num] = 0 ; + armcp15->regionReadSet_USR[num] = 0xFFFFFFFF ; + armcp15->regionWriteMask_SYS[num] = 0 ; + armcp15->regionWriteSet_SYS[num] = 0xFFFFFFFF ; + armcp15->regionReadMask_SYS[num] = 0 ; + armcp15->regionReadSet_SYS[num] = 0xFFFFFFFF ; + break ; + case 1: /* no access at USR, all to sys */ + armcp15->regionWriteMask_USR[num] = 0 ; + armcp15->regionWriteSet_USR[num] = 0xFFFFFFFF ; + armcp15->regionReadMask_USR[num] = 0 ; + armcp15->regionReadSet_USR[num] = 0xFFFFFFFF ; + armcp15->regionWriteMask_SYS[num] = mask ; + armcp15->regionWriteSet_SYS[num] = set ; + armcp15->regionReadMask_SYS[num] = mask ; + armcp15->regionReadSet_SYS[num] = set ; + break ; + case 2: /* read at USR, all to sys */ + armcp15->regionWriteMask_USR[num] = 0 ; + armcp15->regionWriteSet_USR[num] = 0xFFFFFFFF ; + armcp15->regionReadMask_USR[num] = mask ; + armcp15->regionReadSet_USR[num] = set ; + armcp15->regionWriteMask_SYS[num] = mask ; + armcp15->regionWriteSet_SYS[num] = set ; + armcp15->regionReadMask_SYS[num] = mask ; + armcp15->regionReadSet_SYS[num] = set ; + break ; + case 3: /* all to USR, all to sys */ + armcp15->regionWriteMask_USR[num] = mask ; + armcp15->regionWriteSet_USR[num] = set ; + armcp15->regionReadMask_USR[num] = mask ; + armcp15->regionReadSet_USR[num] = set ; + armcp15->regionWriteMask_SYS[num] = mask ; + armcp15->regionWriteSet_SYS[num] = set ; + armcp15->regionReadMask_SYS[num] = mask ; + armcp15->regionReadSet_SYS[num] = set ; + break ; + case 5: /* no access at USR, read to sys */ + armcp15->regionWriteMask_USR[num] = 0 ; + armcp15->regionWriteSet_USR[num] = 0xFFFFFFFF ; + armcp15->regionReadMask_USR[num] = 0 ; + armcp15->regionReadSet_USR[num] = 0xFFFFFFFF ; + armcp15->regionWriteMask_SYS[num] = 0 ; + armcp15->regionWriteSet_SYS[num] = 0xFFFFFFFF ; + armcp15->regionReadMask_SYS[num] = mask ; + armcp15->regionReadSet_SYS[num] = set ; + break ; + case 6: /* read at USR, read to sys */ + armcp15->regionWriteMask_USR[num] = 0 ; + armcp15->regionWriteSet_USR[num] = 0xFFFFFFFF ; + armcp15->regionReadMask_USR[num] = mask ; + armcp15->regionReadSet_USR[num] = set ; + armcp15->regionWriteMask_SYS[num] = 0 ; + armcp15->regionWriteSet_SYS[num] = 0xFFFFFFFF ; + armcp15->regionReadMask_SYS[num] = mask ; + armcp15->regionReadSet_SYS[num] = set ; + break ; + } + switch (ACCESSTYPE(iAccess,num)) { + case 4: /* UNP */ + case 7: /* UNP */ + case 8: /* UNP */ + case 9: /* UNP */ + case 10: /* UNP */ + case 11: /* UNP */ + case 12: /* UNP */ + case 13: /* UNP */ + case 14: /* UNP */ + case 15: /* UNP */ + case 0: /* no access at all */ + armcp15->regionExecuteMask_USR[num] = 0 ; + armcp15->regionExecuteSet_USR[num] = 0xFFFFFFFF ; + armcp15->regionExecuteMask_SYS[num] = 0 ; + armcp15->regionExecuteSet_SYS[num] = 0xFFFFFFFF ; + break ; + case 1: + armcp15->regionExecuteMask_USR[num] = 0 ; + armcp15->regionExecuteSet_USR[num] = 0xFFFFFFFF ; + armcp15->regionExecuteMask_SYS[num] = mask ; + armcp15->regionExecuteSet_SYS[num] = set ; + break ; + case 2: + case 3: + case 6: + armcp15->regionExecuteMask_USR[num] = mask ; + armcp15->regionExecuteSet_USR[num] = set ; + armcp15->regionExecuteMask_SYS[num] = mask ; + armcp15->regionExecuteSet_SYS[num] = set ; + break ; + } +} ; + +/* precalculate region masks/sets from cp15 register */ +static void armcp15_maskPrecalc(armcp15_t *armcp15) +{ + #define precalc(num) { \ + u32 mask = 0, set = 0xFFFFFFFF ; /* (x & 0) == 0xFF..FF is allways false (disabled) */ \ + if (BIT_N(armcp15->protectBaseSize##num,0)) /* if region is enabled */ \ + { /* reason for this define: naming includes var */ \ + mask = MASKFROMREG(armcp15->protectBaseSize##num) ; \ + set = SETFROMREG(armcp15->protectBaseSize##num) ; \ + if (SIZEIDENTIFIER(armcp15->protectBaseSize##num)==0x1F) \ + { /* for the 4GB region, u32 suffers wraparound */ \ + mask = 0 ; set = 0 ; /* (x & 0) == 0 is allways true (enabled) */ \ + } \ + } \ + armcp15_setSingleRegionAccess(armcp15,armcp15->DaccessPerm,armcp15->IaccessPerm,num,mask,set) ; \ + } + precalc(0) ; + precalc(1) ; + precalc(2) ; + precalc(3) ; + precalc(4) ; + precalc(5) ; + precalc(6) ; + precalc(7) ; +} + +INLINE BOOL armcp15_isAccessAllowed(armcp15_t *armcp15,u32 address,u32 access) +{ + int i ; + if (!(armcp15->ctrl & 1)) return TRUE ; /* protection checking is not enabled */ + for (i=0;i<8;i++) { + switch (access) { + case CP15_ACCESS_WRITEUSR: + if ((address & armcp15->regionWriteMask_USR[i]) == armcp15->regionWriteSet_USR[i]) return TRUE ; + break ; + case CP15_ACCESS_WRITESYS: + if ((address & armcp15->regionWriteMask_SYS[i]) == armcp15->regionWriteSet_SYS[i]) return TRUE ; + break ; + case CP15_ACCESS_READUSR: + if ((address & armcp15->regionReadMask_USR[i]) == armcp15->regionReadSet_USR[i]) return TRUE ; + break ; + case CP15_ACCESS_READSYS: + if ((address & armcp15->regionReadMask_SYS[i]) == armcp15->regionReadSet_SYS[i]) return TRUE ; + break ; + case CP15_ACCESS_EXECUSR: + if ((address & armcp15->regionExecuteMask_USR[i]) == armcp15->regionExecuteSet_USR[i]) return TRUE ; + break ; + case CP15_ACCESS_EXECSYS: + if ((address & armcp15->regionExecuteMask_SYS[i]) == armcp15->regionExecuteSet_SYS[i]) return TRUE ; + break ; + } + } + /* when protections are enabled, but no region allows access, deny access */ + return FALSE ; +} + +BOOL armcp15_dataProcess(armcp15_t *armcp15, u8 CRd, u8 CRn, u8 CRm, u8 opcode1, u8 opcode2) +{ + LOG("Unsupported CP15 operation : DataProcess\n"); + return FALSE; +} + +BOOL armcp15_load(armcp15_t *armcp15, u8 CRd, u8 adr) +{ + LOG("Unsupported CP15 operation : Load\n"); + return FALSE; +} + +BOOL armcp15_store(armcp15_t *armcp15, u8 CRd, u8 adr) +{ + LOG("Unsupported CP15 operation : Store\n"); + return FALSE; +} + +BOOL armcp15_moveCP2ARM(armcp15_t *armcp15, u32 * R, u8 CRn, u8 CRm, u8 opcode1, u8 opcode2) +{ + if(armcp15->cpu->CPSR.bits.mode == USR) return FALSE; + + switch(CRn) + { + case 0 : + if((opcode1 == 0)&&(CRm==0)) + { + switch(opcode2) + { + case 1 : + *R = armcp15->cacheType; + return TRUE; + case 2 : + *R = armcp15->TCMSize; + return TRUE; + default : + *R = armcp15->IDCode; + return TRUE; + } + } + return FALSE; + case 1 : + if((opcode1==0) && (opcode2==0) && (CRm==0)) + { + *R = armcp15->ctrl; + return TRUE; + } + return FALSE; + + case 2 : + if((opcode1==0) && (CRm==0)) + { + switch(opcode2) + { + case 0 : + *R = armcp15->DCConfig; + return TRUE; + case 1 : + *R = armcp15->ICConfig; + return TRUE; + default : + return FALSE; + } + } + return FALSE; + case 3 : + if((opcode1==0) && (opcode2==0) && (CRm==0)) + { + *R = armcp15->writeBuffCtrl; + return TRUE; + } + return FALSE; + case 5 : + if((opcode1==0) && (CRm==0)) + { + switch(opcode2) + { + case 2 : + *R = armcp15->DaccessPerm; + return TRUE; + case 3 : + *R = armcp15->IaccessPerm; + return TRUE; + default : + return FALSE; + } + } + return FALSE; + case 6 : + if((opcode1==0) && (opcode2==0)) + { + switch(CRm) + { + case 0 : + *R = armcp15->protectBaseSize0; + return TRUE; + case 1 : + *R = armcp15->protectBaseSize1; + return TRUE; + case 2 : + *R = armcp15->protectBaseSize2; + return TRUE; + case 3 : + *R = armcp15->protectBaseSize3; + return TRUE; + case 4 : + *R = armcp15->protectBaseSize4; + return TRUE; + case 5 : + *R = armcp15->protectBaseSize5; + return TRUE; + case 6 : + *R = armcp15->protectBaseSize6; + return TRUE; + case 7 : + *R = armcp15->protectBaseSize7; + return TRUE; + default : + return FALSE; + } + } + return FALSE; + case 9 : + if((opcode1==0)) + { + switch(CRm) + { + case 0 : + switch(opcode2) + { + case 0 : + *R = armcp15->DcacheLock; + return TRUE; + case 1 : + *R = armcp15->IcacheLock; + return TRUE; + default : + return FALSE; + } + case 1 : + switch(opcode2) + { + case 0 : + *R = armcp15->DTCMRegion; + return TRUE; + case 1 : + *R = armcp15->ITCMRegion; + return TRUE; + default : + return FALSE; + } + } + } + return FALSE; + default : + LOG("Unsupported CP15 operation : MRC\n"); + return FALSE; + } +} + + +static u32 CP15wait4IRQ(armcpu_t *cpu) +{ + /* on the first call, wirq is not set */ + if(cpu->wirq) + { + /* check wether an irq was issued */ + if(!cpu->waitIRQ) + { + cpu->waitIRQ = 0; + cpu->wirq = 0; + return 1; /* return execution */ + } + /* otherwise, repeat this instruction */ + cpu->R[15] = cpu->instruct_adr; + cpu->next_instruction = cpu->R[15]; + return 1; + } + /* first run, set us into waiting state */ + cpu->waitIRQ = 1; + cpu->wirq = 1; + /* and set next instruction to repeat this */ + cpu->R[15] = cpu->instruct_adr; + cpu->next_instruction = cpu->R[15]; + /* CHECKME: IME shouldn't be modified (?) */ + MMU.reg_IME[0] = 1; + return 1; +} + +BOOL armcp15_moveARM2CP(armcp15_t *armcp15, u32 val, u8 CRn, u8 CRm, u8 opcode1, u8 opcode2) +{ + if(armcp15->cpu->CPSR.bits.mode == USR) return FALSE; + + switch(CRn) + { + case 1 : + if((opcode1==0) && (opcode2==0) && (CRm==0)) + { + armcp15->ctrl = val; + MMU.ARM9_RW_MODE = BIT7(val); + armcp15->cpu->intVector = 0x0FFF0000 * (BIT13(val)); + armcp15->cpu->LDTBit = !BIT15(val); //TBit + /*if(BIT17(val)) + { + log::ajouter("outch !!!!!!!"); + } + if(BIT19(val)) + { + log::ajouter("outch !!!!!!!"); + }*/ + return TRUE; + } + return FALSE; + case 2 : + if((opcode1==0) && (CRm==0)) + { + switch(opcode2) + { + case 0 : + armcp15->DCConfig = val; + return TRUE; + case 1 : + armcp15->ICConfig = val; + return TRUE; + default : + return FALSE; + } + } + return FALSE; + case 3 : + if((opcode1==0) && (opcode2==0) && (CRm==0)) + { + armcp15->writeBuffCtrl = val; + return TRUE; + } + return FALSE; + case 5 : + if((opcode1==0) && (CRm==0)) + { + switch(opcode2) + { + case 2 : + armcp15->DaccessPerm = val; + armcp15_maskPrecalc(armcp15); + return TRUE; + case 3 : + armcp15->IaccessPerm = val; + armcp15_maskPrecalc(armcp15); + return TRUE; + default : + return FALSE; + } + } + return FALSE; + case 6 : + if((opcode1==0) && (opcode2==0)) + { + switch(CRm) + { + case 0 : + armcp15->protectBaseSize0 = val; + armcp15_maskPrecalc(armcp15) ; + return TRUE; + case 1 : + armcp15->protectBaseSize1 = val; + armcp15_maskPrecalc(armcp15) ; + return TRUE; + case 2 : + armcp15->protectBaseSize2 = val; + armcp15_maskPrecalc(armcp15) ; + return TRUE; + case 3 : + armcp15->protectBaseSize3 = val; + armcp15_maskPrecalc(armcp15) ; + return TRUE; + case 4 : + armcp15->protectBaseSize4 = val; + armcp15_maskPrecalc(armcp15) ; + return TRUE; + case 5 : + armcp15->protectBaseSize5 = val; + armcp15_maskPrecalc(armcp15) ; + return TRUE; + case 6 : + armcp15->protectBaseSize6 = val; + armcp15_maskPrecalc(armcp15) ; + return TRUE; + case 7 : + armcp15->protectBaseSize7 = val; + armcp15_maskPrecalc(armcp15) ; + return TRUE; + default : + return FALSE; + } + } + return FALSE; + case 7 : + if((CRm==0)&&(opcode1==0)&&((opcode2==4))) + { + CP15wait4IRQ(armcp15->cpu); + return TRUE; + } + return FALSE; + case 9 : + if((opcode1==0)) + { + switch(CRm) + { + case 0 : + switch(opcode2) + { + case 0 : + armcp15->DcacheLock = val; + return TRUE; + case 1 : + armcp15->IcacheLock = val; + return TRUE; + default : + return FALSE; + } + case 1 : + switch(opcode2) + { + case 0 : + armcp15->DTCMRegion = val; + MMU.DTCMRegion = val & 0x0FFFFFFC0; + /*sprintf(logbuf, "%08X", val); + log::ajouter(logbuf);*/ + return TRUE; + case 1 : + armcp15->ITCMRegion = val; + /* ITCM base is not writeable! */ + MMU.ITCMRegion = 0; + return TRUE; + default : + return FALSE; + } + } + } + return FALSE; + default : + return FALSE; + } +} + + + diff --git a/desmume/src/cp15.h b/src/cp15.h similarity index 97% rename from desmume/src/cp15.h rename to src/cp15.h index a6499ca30..aff86ba4e 100644 --- a/desmume/src/cp15.h +++ b/src/cp15.h @@ -1,94 +1,94 @@ -/* Copyright (C) 2006 yopyop - yopyop156@ifrance.com - yopyop156.ifrance.com - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#ifndef __CP15_H__ -#define __CP15_H__ - -#include "armcpu.h" - -struct armcp15_t -{ - u32 IDCode; - u32 cacheType; - u32 TCMSize; - u32 ctrl; - u32 DCConfig; - u32 ICConfig; - u32 writeBuffCtrl; - u32 und; - u32 DaccessPerm; - u32 IaccessPerm; - u32 protectBaseSize0; - u32 protectBaseSize1; - u32 protectBaseSize2; - u32 protectBaseSize3; - u32 protectBaseSize4; - u32 protectBaseSize5; - u32 protectBaseSize6; - u32 protectBaseSize7; - u32 cacheOp; - u32 DcacheLock; - u32 IcacheLock; - u32 ITCMRegion; - u32 DTCMRegion; - u32 processID; - u32 RAM_TAG; - u32 testState; - u32 cacheDbg; - /* calculated bitmasks for the regions to decide rights uppon */ - /* calculation is done in the MCR instead of on mem access for performance */ - u32 regionWriteMask_USR[8] ; - u32 regionWriteMask_SYS[8] ; - u32 regionReadMask_USR[8] ; - u32 regionReadMask_SYS[8] ; - u32 regionExecuteMask_USR[8] ; - u32 regionExecuteMask_SYS[8] ; - u32 regionWriteSet_USR[8] ; - u32 regionWriteSet_SYS[8] ; - u32 regionReadSet_USR[8] ; - u32 regionReadSet_SYS[8] ; - u32 regionExecuteSet_USR[8] ; - u32 regionExecuteSet_SYS[8] ; - - armcpu_t * cpu; - -}; - -armcp15_t *armcp15_new(armcpu_t *c); -BOOL armcp15_dataProcess(armcp15_t *armcp15, u8 CRd, u8 CRn, u8 CRm, u8 opcode1, u8 opcode2); -BOOL armcp15_load(armcp15_t *armcp15, u8 CRd, u8 adr); -BOOL armcp15_store(armcp15_t *armcp15, u8 CRd, u8 adr); -BOOL armcp15_moveCP2ARM(armcp15_t *armcp15, u32 * R, u8 CRn, u8 CRm, u8 opcode1, u8 opcode2); -BOOL armcp15_moveARM2CP(armcp15_t *armcp15, u32 val, u8 CRn, u8 CRm, u8 opcode1, u8 opcode2); -INLINE BOOL armcp15_isAccessAllowed(armcp15_t *armcp15,u32 address,u32 access) ; - - -#define CP15_ACCESS_WRITE 0 -#define CP15_ACCESS_READ 2 -#define CP15_ACCESS_EXECUTE 4 -#define CP15_ACCESS_WRITEUSR CP15_ACCESS_WRITE -#define CP15_ACCESS_WRITESYS 1 -#define CP15_ACCESS_READUSR CP15_ACCESS_READ -#define CP15_ACCESS_READSYS 3 -#define CP15_ACCESS_EXECUSR CP15_ACCESS_EXECUTE -#define CP15_ACCESS_EXECSYS 5 - -#endif /* __CP15_H__*/ +/* Copyright (C) 2006 yopyop + yopyop156@ifrance.com + yopyop156.ifrance.com + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#ifndef __CP15_H__ +#define __CP15_H__ + +#include "armcpu.h" + +struct armcp15_t +{ + u32 IDCode; + u32 cacheType; + u32 TCMSize; + u32 ctrl; + u32 DCConfig; + u32 ICConfig; + u32 writeBuffCtrl; + u32 und; + u32 DaccessPerm; + u32 IaccessPerm; + u32 protectBaseSize0; + u32 protectBaseSize1; + u32 protectBaseSize2; + u32 protectBaseSize3; + u32 protectBaseSize4; + u32 protectBaseSize5; + u32 protectBaseSize6; + u32 protectBaseSize7; + u32 cacheOp; + u32 DcacheLock; + u32 IcacheLock; + u32 ITCMRegion; + u32 DTCMRegion; + u32 processID; + u32 RAM_TAG; + u32 testState; + u32 cacheDbg; + /* calculated bitmasks for the regions to decide rights uppon */ + /* calculation is done in the MCR instead of on mem access for performance */ + u32 regionWriteMask_USR[8] ; + u32 regionWriteMask_SYS[8] ; + u32 regionReadMask_USR[8] ; + u32 regionReadMask_SYS[8] ; + u32 regionExecuteMask_USR[8] ; + u32 regionExecuteMask_SYS[8] ; + u32 regionWriteSet_USR[8] ; + u32 regionWriteSet_SYS[8] ; + u32 regionReadSet_USR[8] ; + u32 regionReadSet_SYS[8] ; + u32 regionExecuteSet_USR[8] ; + u32 regionExecuteSet_SYS[8] ; + + armcpu_t * cpu; + +}; + +armcp15_t *armcp15_new(armcpu_t *c); +BOOL armcp15_dataProcess(armcp15_t *armcp15, u8 CRd, u8 CRn, u8 CRm, u8 opcode1, u8 opcode2); +BOOL armcp15_load(armcp15_t *armcp15, u8 CRd, u8 adr); +BOOL armcp15_store(armcp15_t *armcp15, u8 CRd, u8 adr); +BOOL armcp15_moveCP2ARM(armcp15_t *armcp15, u32 * R, u8 CRn, u8 CRm, u8 opcode1, u8 opcode2); +BOOL armcp15_moveARM2CP(armcp15_t *armcp15, u32 val, u8 CRn, u8 CRm, u8 opcode1, u8 opcode2); +INLINE BOOL armcp15_isAccessAllowed(armcp15_t *armcp15,u32 address,u32 access) ; + + +#define CP15_ACCESS_WRITE 0 +#define CP15_ACCESS_READ 2 +#define CP15_ACCESS_EXECUTE 4 +#define CP15_ACCESS_WRITEUSR CP15_ACCESS_WRITE +#define CP15_ACCESS_WRITESYS 1 +#define CP15_ACCESS_READUSR CP15_ACCESS_READ +#define CP15_ACCESS_READSYS 3 +#define CP15_ACCESS_EXECUSR CP15_ACCESS_EXECUTE +#define CP15_ACCESS_EXECSYS 5 + +#endif /* __CP15_H__*/ diff --git a/desmume/src/ctrlssdl.cpp b/src/ctrlssdl.cpp similarity index 71% rename from desmume/src/ctrlssdl.cpp rename to src/ctrlssdl.cpp index 6da156352..da84925ab 100644 --- a/desmume/src/ctrlssdl.cpp +++ b/src/ctrlssdl.cpp @@ -1,488 +1,513 @@ -/* joysdl.c - this file is part of DeSmuME - * - * Copyright (C) 2007 Pascal Giard - * - * Author: Pascal Giard - * - * This file is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2, or (at your option) - * any later version. - * - * This file is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; see the file COPYING. If not, write to - * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -#include "ctrlssdl.h" -#include "saves.h" -#include "SPU.h" - -u16 keyboard_cfg[NB_KEYS]; -u16 joypad_cfg[NB_KEYS]; -u16 nbr_joy; -mouse_status mouse; - -extern volatile BOOL execute; - -static SDL_Joystick **open_joysticks = NULL; - -/* Keypad key names */ -const char *key_names[NB_KEYS] = -{ - "A", "B", "Select", "Start", - "Right", "Left", "Up", "Down", - "R", "L", "X", "Y", - "Debug", "Boost" -}; - -/* Default joypad configuration */ -const u16 default_joypad_cfg[NB_KEYS] = - { 1, // A - 0, // B - 5, // select - 8, // start - 256, // Right -- Start cheating abit... - 256, // Left - 512, // Up - 512, // Down -- End of cheating. - 7, // R - 6, // L - 4, // X - 3, // Y - -1, // DEBUG - -1 // BOOST - }; - -const u16 plain_keyboard_cfg[NB_KEYS] = -{ - 'x', // A - 'z', // B - 'y', // select - 'u', // start - 'l', // Right - 'j', // Left - 'i', // Up - 'k', // Down - 'w', // R - 'q', // L - 's', // X - 'a', // Y - 'p', // DEBUG - 'o' // BOOST -}; - -/* Load default joystick and keyboard configurations */ -void load_default_config(const u16 kbCfg[]) -{ - memcpy(keyboard_cfg, kbCfg, sizeof(keyboard_cfg)); - memcpy(joypad_cfg, default_joypad_cfg, sizeof(joypad_cfg)); -} - -/* Initialize joysticks */ -BOOL init_joy( void) { - int i; - BOOL joy_init_good = TRUE; - - set_joy_keys(default_joypad_cfg); - - if(SDL_InitSubSystem(SDL_INIT_JOYSTICK) == -1) - { - fprintf(stderr, "Error trying to initialize joystick support: %s\n", - SDL_GetError()); - return FALSE; - } - - nbr_joy = SDL_NumJoysticks(); - - if ( nbr_joy > 0) { - printf("Found %d joysticks\n", nbr_joy); - open_joysticks = - (SDL_Joystick**)calloc( sizeof ( SDL_Joystick *), nbr_joy); - - if ( open_joysticks != NULL) { - for (i = 0; i < nbr_joy; i++) - { - SDL_Joystick * joy = SDL_JoystickOpen(i); - printf("Joystick %d %s\n", i, SDL_JoystickName(i)); - printf("Axes: %d\n", SDL_JoystickNumAxes(joy)); - printf("Buttons: %d\n", SDL_JoystickNumButtons(joy)); - printf("Trackballs: %d\n", SDL_JoystickNumBalls(joy)); - printf("Hats: %d\n\n", SDL_JoystickNumHats(joy)); - } - } - else { - joy_init_good = FALSE; - } - } - - return joy_init_good; -} - -/* Set all buttons at once */ -void set_joy_keys(const u16 joyCfg[]) -{ - memcpy(joypad_cfg, joyCfg, sizeof(joypad_cfg)); -} - -/* Set all buttons at once */ -void set_kb_keys(const u16 kbCfg[]) -{ - memcpy(keyboard_cfg, kbCfg, sizeof(keyboard_cfg)); -} - -/* Unload joysticks */ -void uninit_joy( void) -{ - int i; - - if ( open_joysticks != NULL) { - for (i = 0; i < SDL_NumJoysticks(); i++) { - SDL_JoystickClose( open_joysticks[i]); - } - - free( open_joysticks); - } - - open_joysticks = NULL; - SDL_QuitSubSystem(SDL_INIT_JOYSTICK); -} - -/* Return keypad vector with given key set to 1 */ -u16 lookup_joy_key (u16 keyval) { - int i; - u16 Key = 0; - for(i = 0; i < NB_KEYS; i++) - if(keyval == joypad_cfg[i]) break; - if(i < NB_KEYS) Key = KEYMASK_(i); - return Key; -} - -/* Return keypad vector with given key set to 1 */ -u16 lookup_key (u16 keyval) { - int i; - u16 Key = 0; - for(i = 0; i < NB_KEYS; i++) - if(keyval == keyboard_cfg[i]) break; - if(i < NB_KEYS) Key = KEYMASK_(i); - return Key; -} - -/* Empty SDL Events' queue */ -static void clear_events( void) -{ - SDL_Event event; - /* IMPORTANT: Reenable joystick events iif needed. */ - if(SDL_JoystickEventState(SDL_QUERY) == SDL_IGNORE) - SDL_JoystickEventState(SDL_ENABLE); - - /* There's an event waiting to be processed? */ - while (SDL_PollEvent(&event)) - { - } - - return; -} - -/* Get and set a new joystick key */ -u16 get_set_joy_key(int index) { - BOOL done = FALSE; - SDL_Event event; - u16 key = joypad_cfg[index]; - - /* Enable joystick events if needed */ - if( SDL_JoystickEventState(SDL_QUERY) == SDL_IGNORE ) - SDL_JoystickEventState(SDL_ENABLE); - - while(SDL_WaitEvent(&event) && !done) - { - switch(event.type) - { - case SDL_JOYBUTTONDOWN: - printf( "Got joykey: %d\n", event.jbutton.button ); - key = event.jbutton.button; - done = TRUE; - break; - } - } - - if( SDL_JoystickEventState(SDL_QUERY) == SDL_ENABLE ) - SDL_JoystickEventState(SDL_IGNORE); - joypad_cfg[index] = key; - - return key; -} - -/* Reset corresponding key and its twin axis key */ -static u16 get_joy_axis_twin(u16 key) -{ - switch(key) - { - case KEYMASK_( KEY_RIGHT-1 ): - return KEYMASK_( KEY_LEFT-1 ); - case KEYMASK_( KEY_UP-1 ): - return KEYMASK_( KEY_DOWN-1 ); - default: - return 0; - } -} - -/* Get and set a new joystick axis */ -void get_set_joy_axis(int index, int index_o) { - BOOL done = FALSE; - SDL_Event event; - u16 key = joypad_cfg[index]; - - /* Clear events */ - clear_events(); - /* Enable joystick events if needed */ - if( SDL_JoystickEventState(SDL_QUERY) == SDL_IGNORE ) - SDL_JoystickEventState(SDL_ENABLE); - - while(SDL_WaitEvent(&event) && !done) - { - switch(event.type) - { - case SDL_JOYAXISMOTION: - /* Discriminate small movements */ - if( (event.jaxis.value >> 5) != 0 ) - { - key = JOY_AXIS_(event.jaxis.axis); - done = TRUE; - } - break; - } - } - if( SDL_JoystickEventState(SDL_QUERY) == SDL_ENABLE ) - SDL_JoystickEventState(SDL_IGNORE); - /* Update configuration */ - joypad_cfg[index] = key; - joypad_cfg[index_o] = joypad_cfg[index]; -} - -static signed long -screen_to_touch_range_x( signed long scr_x, float size_ratio) { - signed long touch_x = (signed long)((float)scr_x * size_ratio); - - return touch_x; -} - -static signed long -screen_to_touch_range_y( signed long scr_y, float size_ratio) { - signed long touch_y = (signed long)((float)scr_y * size_ratio); - - return touch_y; -} - -/* Set mouse coordinates */ -void set_mouse_coord(signed long x,signed long y) -{ - if(x<0) x = 0; else if(x>255) x = 255; - if(y<0) y = 0; else if(y>192) y = 192; - mouse.x = x; - mouse.y = y; -} - -/* Update NDS keypad */ -void update_keypad(u16 keys) -{ -#ifdef WORDS_BIGENDIAN - ARM9Mem.ARM9_REG[0x130] = ~keys & 0xFF; - ARM9Mem.ARM9_REG[0x131] = (~keys >> 8) & 0x3; - MMU.ARM7_REG[0x130] = ~keys & 0xFF; - MMU.ARM7_REG[0x131] = (~keys >> 8) & 0x3; -#else - ((u16 *)ARM9Mem.ARM9_REG)[0x130>>1] = ~keys & 0x3FF; - ((u16 *)MMU.ARM7_REG)[0x130>>1] = ~keys & 0x3FF; -#endif - /* Update X and Y buttons */ - MMU.ARM7_REG[0x136] = ( ~( keys >> 10) & 0x3 ) | (MMU.ARM7_REG[0x136] & ~0x3); -} - -/* Retrieve current NDS keypad */ -u16 get_keypad( void) -{ - u16 keypad; - keypad = ~MMU.ARM7_REG[0x136]; - keypad = (keypad & 0x3) << 10; -#ifdef WORDS_BIGENDIAN - keypad |= ~(ARM9Mem.ARM9_REG[0x130] | (ARM9Mem.ARM9_REG[0x131] << 8)) & 0x3FF; -#else - keypad |= ~((u16 *)ARM9Mem.ARM9_REG)[0x130>>1] & 0x3FF; -#endif - return keypad; -} - -/* - * The internal joystick events processing function - */ -static int -do_process_joystick_events( u16 *keypad, SDL_Event *event) { - int processed = 1; - u16 key; - - switch ( event->type) - { - /* Joystick axis motion - Note: button constants have a 1bit offset. */ - case SDL_JOYAXISMOTION: - key = lookup_joy_key( JOY_AXIS_(event->jaxis.axis) ); - if( key == 0 ) break; /* Not an axis of interest? */ - - /* Axis is back to initial position */ - if( event->jaxis.value == 0 ) - RM_KEY( *keypad, key | get_joy_axis_twin(key) ); - /* Key should have been down but its currently set to up? */ - else if( (event->jaxis.value > 0) && - (key == KEYMASK_( KEY_UP-1 )) ) - key = KEYMASK_( KEY_DOWN-1 ); - /* Key should have been left but its currently set to right? */ - else if( (event->jaxis.value < 0) && - (key == KEYMASK_( KEY_RIGHT-1 )) ) - key = KEYMASK_( KEY_LEFT-1 ); - - /* Remove some sensitivity before checking if different than zero... - Fixes some badly behaving joypads [like one of mine]. */ - if( (event->jaxis.value >> 5) != 0 ) - ADD_KEY( *keypad, key ); - break; - - /* Joystick button pressed */ - /* FIXME: Add support for BOOST */ - case SDL_JOYBUTTONDOWN: - key = lookup_joy_key( event->jbutton.button ); - ADD_KEY( *keypad, key ); - break; - - /* Joystick button released */ - case SDL_JOYBUTTONUP: - key = lookup_joy_key(event->jbutton.button); - RM_KEY( *keypad, key ); - break; - - default: - processed = 0; - break; - } - - return processed; -} - -/* - * Process only the joystick events - */ -void -process_joystick_events( u16 *keypad) { - SDL_Event event; - - /* IMPORTANT: Reenable joystick events iif needed. */ - if(SDL_JoystickEventState(SDL_QUERY) == SDL_IGNORE) - SDL_JoystickEventState(SDL_ENABLE); - - /* There's an event waiting to be processed? */ - while (SDL_PollEvent(&event)) - { - do_process_joystick_events( keypad, &event); - } -} - -u16 shift_pressed; - -void -process_ctrls_event( SDL_Event& event, u16 *keypad, - float nds_screen_size_ratio) -{ - u16 key; - if ( !do_process_joystick_events( keypad, &event)) { - switch (event.type) - { - case SDL_KEYDOWN: - switch(event.key.keysym.sym){ - case SDLK_LSHIFT: - shift_pressed |= 1; - break; - case SDLK_RSHIFT: - shift_pressed |= 2; - break; - default: - key = lookup_key(event.key.keysym.sym); - ADD_KEY( *keypad, key ); - break; - } - break; - - case SDL_KEYUP: - switch(event.key.keysym.sym){ - case SDLK_LSHIFT: - shift_pressed &= ~1; - break; - case SDLK_RSHIFT: - shift_pressed &= ~2; - break; - - case SDLK_F1: - case SDLK_F2: - case SDLK_F3: - case SDLK_F4: - case SDLK_F5: - case SDLK_F6: - case SDLK_F7: - case SDLK_F8: - case SDLK_F9: - case SDLK_F10: - int prevexec; - prevexec = execute; - execute = FALSE; - SPU_Pause(1); - if(!shift_pressed){ - loadstate_slot(event.key.keysym.sym - SDLK_F1 + 1); - }else{ - savestate_slot(event.key.keysym.sym - SDLK_F1 + 1); - } - execute = prevexec; - SPU_Pause(!execute); - break; - default: - key = lookup_key(event.key.keysym.sym); - RM_KEY( *keypad, key ); - break; - } - break; - - case SDL_MOUSEBUTTONDOWN: - if(event.button.button==1) - mouse.down = TRUE; - - case SDL_MOUSEMOTION: - if(!mouse.down) - break; - else { - signed long scaled_x = - screen_to_touch_range_x( event.button.x, - nds_screen_size_ratio); - signed long scaled_y = - screen_to_touch_range_y( event.button.y, - nds_screen_size_ratio); - - if( scaled_y >= 192) - set_mouse_coord( scaled_x, scaled_y - 192); - } - break; - - case SDL_MOUSEBUTTONUP: - if(mouse.down) mouse.click = TRUE; - mouse.down = FALSE; - break; - - default: - break; - } - } -} - +/* joysdl.c - this file is part of DeSmuME + * + * Copyright (C) 2007 Pascal Giard + * + * Author: Pascal Giard + * + * This file is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2, or (at your option) + * any later version. + * + * This file is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; see the file COPYING. If not, write to + * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#include "ctrlssdl.h" +#include "saves.h" +#include "SPU.h" + +u16 keyboard_cfg[NB_KEYS]; +u16 joypad_cfg[NB_KEYS]; +u16 nbr_joy; +mouse_status mouse; + +extern volatile BOOL execute; + +static SDL_Joystick **open_joysticks = NULL; + +/* Keypad key names */ +const char *key_names[NB_KEYS] = +{ + "A", "B", "Select", "Start", + "Right", "Left", "Up", "Down", + "R", "L", "X", "Y", + "Debug", "Boost" +}; + +/* Default joypad configuration */ +const u16 default_joypad_cfg[NB_KEYS] = + { 1, // A + 0, // B + 5, // select + 8, // start + 256, // Right -- Start cheating abit... + 256, // Left + 512, // Up + 512, // Down -- End of cheating. + 7, // R + 6, // L + 4, // X + 3, // Y + -1, // DEBUG + -1 // BOOST + }; + +const u16 plain_keyboard_cfg[NB_KEYS] = +{ + 'x', // A + 'z', // B + 'y', // select + 'u', // start + 'l', // Right + 'j', // Left + 'i', // Up + 'k', // Down + 'w', // R + 'q', // L + 's', // X + 'a', // Y + 'p', // DEBUG + 'o' // BOOST +}; + +/* Load default joystick and keyboard configurations */ +void load_default_config(const u16 kbCfg[]) +{ + memcpy(keyboard_cfg, kbCfg, sizeof(keyboard_cfg)); + memcpy(joypad_cfg, default_joypad_cfg, sizeof(joypad_cfg)); +} + +/* Initialize joysticks */ +BOOL init_joy( void) { + int i; + BOOL joy_init_good = TRUE; + + set_joy_keys(default_joypad_cfg); + + if(SDL_InitSubSystem(SDL_INIT_JOYSTICK) == -1) + { + fprintf(stderr, "Error trying to initialize joystick support: %s\n", + SDL_GetError()); + return FALSE; + } + + nbr_joy = SDL_NumJoysticks(); + + if ( nbr_joy > 0) { + printf("Found %d joysticks\n", nbr_joy); + open_joysticks = + (SDL_Joystick**)calloc( sizeof ( SDL_Joystick *), nbr_joy); + + if ( open_joysticks != NULL) { + for (i = 0; i < nbr_joy; i++) + { + SDL_Joystick * joy = SDL_JoystickOpen(i); + printf("Joystick %d %s\n", i, SDL_JoystickName(i)); + printf("Axes: %d\n", SDL_JoystickNumAxes(joy)); + printf("Buttons: %d\n", SDL_JoystickNumButtons(joy)); + printf("Trackballs: %d\n", SDL_JoystickNumBalls(joy)); + printf("Hats: %d\n\n", SDL_JoystickNumHats(joy)); + } + } + else { + joy_init_good = FALSE; + } + } + + return joy_init_good; +} + +/* Set all buttons at once */ +void set_joy_keys(const u16 joyCfg[]) +{ + memcpy(joypad_cfg, joyCfg, sizeof(joypad_cfg)); +} + +/* Set all buttons at once */ +void set_kb_keys(const u16 kbCfg[]) +{ + memcpy(keyboard_cfg, kbCfg, sizeof(keyboard_cfg)); +} + +/* Unload joysticks */ +void uninit_joy( void) +{ + int i; + + if ( open_joysticks != NULL) { + for (i = 0; i < SDL_NumJoysticks(); i++) { + SDL_JoystickClose( open_joysticks[i]); + } + + free( open_joysticks); + } + + open_joysticks = NULL; + SDL_QuitSubSystem(SDL_INIT_JOYSTICK); +} + +/* Return keypad vector with given key set to 1 */ +u16 lookup_joy_key (u16 keyval) { + int i; + u16 Key = 0; + for(i = 0; i < NB_KEYS; i++) + if(keyval == joypad_cfg[i]) break; + if(i < NB_KEYS) Key = KEYMASK_(i); + return Key; +} + +/* Return keypad vector with given key set to 1 */ +u16 lookup_key (u16 keyval) { + int i; + u16 Key = 0; + for(i = 0; i < NB_KEYS; i++) + if(keyval == keyboard_cfg[i]) break; + if(i < NB_KEYS) Key = KEYMASK_(i); + return Key; +} + +/* Empty SDL Events' queue */ +static void clear_events( void) +{ + SDL_Event event; + /* IMPORTANT: Reenable joystick events iif needed. */ + if(SDL_JoystickEventState(SDL_QUERY) == SDL_IGNORE) + SDL_JoystickEventState(SDL_ENABLE); + + /* There's an event waiting to be processed? */ + while (SDL_PollEvent(&event)) + { + } + + return; +} + +/* Get and set a new joystick key */ +u16 get_set_joy_key(int index) { + BOOL done = FALSE; + SDL_Event event; + u16 key = joypad_cfg[index]; + + /* Enable joystick events if needed */ + if( SDL_JoystickEventState(SDL_QUERY) == SDL_IGNORE ) + SDL_JoystickEventState(SDL_ENABLE); + + while(SDL_WaitEvent(&event) && !done) + { + switch(event.type) + { + case SDL_JOYBUTTONDOWN: + printf( "Got joykey: %d\n", event.jbutton.button ); + key = event.jbutton.button; + done = TRUE; + break; + } + } + + if( SDL_JoystickEventState(SDL_QUERY) == SDL_ENABLE ) + SDL_JoystickEventState(SDL_IGNORE); + joypad_cfg[index] = key; + + return key; +} + +/* Reset corresponding key and its twin axis key */ +static u16 get_joy_axis_twin(u16 key) +{ + switch(key) + { + case KEYMASK_( KEY_RIGHT-1 ): + return KEYMASK_( KEY_LEFT-1 ); + case KEYMASK_( KEY_UP-1 ): + return KEYMASK_( KEY_DOWN-1 ); + default: + return 0; + } +} + +/* Get and set a new joystick axis */ +void get_set_joy_axis(int index, int index_o) { + BOOL done = FALSE; + SDL_Event event; + u16 key = joypad_cfg[index]; + + /* Clear events */ + clear_events(); + /* Enable joystick events if needed */ + if( SDL_JoystickEventState(SDL_QUERY) == SDL_IGNORE ) + SDL_JoystickEventState(SDL_ENABLE); + + while(SDL_WaitEvent(&event) && !done) + { + switch(event.type) + { + case SDL_JOYAXISMOTION: + /* Discriminate small movements */ + if( (event.jaxis.value >> 5) != 0 ) + { + key = JOY_AXIS_(event.jaxis.axis); + done = TRUE; + } + break; + } + } + if( SDL_JoystickEventState(SDL_QUERY) == SDL_ENABLE ) + SDL_JoystickEventState(SDL_IGNORE); + /* Update configuration */ + joypad_cfg[index] = key; + joypad_cfg[index_o] = joypad_cfg[index]; +} + +static signed long +screen_to_touch_range_x( signed long scr_x, float size_ratio) { + signed long touch_x = (signed long)((float)scr_x * size_ratio); + + return touch_x; +} + +static signed long +screen_to_touch_range_y( signed long scr_y, float size_ratio) { + signed long touch_y = (signed long)((float)scr_y * size_ratio); + + return touch_y; +} + +/* Set mouse coordinates */ +void set_mouse_coord(signed long x,signed long y) +{ + if(x<0) x = 0; else if(x>255) x = 255; + if(y<0) y = 0; else if(y>192) y = 192; + mouse.x = x; + mouse.y = y; +} + +/* Update NDS keypad */ +void update_keypad(u16 keys) +{ +#ifdef WORDS_BIGENDIAN + ARM9Mem.ARM9_REG[0x130] = ~keys & 0xFF; + ARM9Mem.ARM9_REG[0x131] = (~keys >> 8) & 0x3; + MMU.ARM7_REG[0x130] = ~keys & 0xFF; + MMU.ARM7_REG[0x131] = (~keys >> 8) & 0x3; +#else + ((u16 *)ARM9Mem.ARM9_REG)[0x130>>1] = ~keys & 0x3FF; + ((u16 *)MMU.ARM7_REG)[0x130>>1] = ~keys & 0x3FF; +#endif + /* Update X and Y buttons */ + MMU.ARM7_REG[0x136] = ( ~( keys >> 10) & 0x3 ) | (MMU.ARM7_REG[0x136] & ~0x3); +} + +/* Retrieve current NDS keypad */ +u16 get_keypad( void) +{ + u16 keypad; + keypad = ~MMU.ARM7_REG[0x136]; + keypad = (keypad & 0x3) << 10; +#ifdef WORDS_BIGENDIAN + keypad |= ~(ARM9Mem.ARM9_REG[0x130] | (ARM9Mem.ARM9_REG[0x131] << 8)) & 0x3FF; +#else + keypad |= ~((u16 *)ARM9Mem.ARM9_REG)[0x130>>1] & 0x3FF; +#endif + return keypad; +} + +/* + * The internal joystick events processing function + */ +static int +do_process_joystick_events( u16 *keypad, SDL_Event *event) { + int processed = 1; + u16 key; + + switch ( event->type) + { + /* Joystick axis motion + Note: button constants have a 1bit offset. */ + case SDL_JOYAXISMOTION: + key = lookup_joy_key( JOY_AXIS_(event->jaxis.axis) ); + if( key == 0 ) break; /* Not an axis of interest? */ + + /* Axis is back to initial position */ + if( event->jaxis.value == 0 ) + RM_KEY( *keypad, key | get_joy_axis_twin(key) ); + /* Key should have been down but its currently set to up? */ + else if( (event->jaxis.value > 0) && + (key == KEYMASK_( KEY_UP-1 )) ) + key = KEYMASK_( KEY_DOWN-1 ); + /* Key should have been left but its currently set to right? */ + else if( (event->jaxis.value < 0) && + (key == KEYMASK_( KEY_RIGHT-1 )) ) + key = KEYMASK_( KEY_LEFT-1 ); + + /* Remove some sensitivity before checking if different than zero... + Fixes some badly behaving joypads [like one of mine]. */ + if( (event->jaxis.value >> 5) != 0 ) + ADD_KEY( *keypad, key ); + break; + + /* Joystick button pressed */ + /* FIXME: Add support for BOOST */ + case SDL_JOYBUTTONDOWN: + key = lookup_joy_key( event->jbutton.button ); + ADD_KEY( *keypad, key ); + break; + + /* Joystick button released */ + case SDL_JOYBUTTONUP: + key = lookup_joy_key(event->jbutton.button); + RM_KEY( *keypad, key ); + break; + + default: + processed = 0; + break; + } + + return processed; +} + +/* + * Process only the joystick events + */ +void +process_joystick_events( u16 *keypad) { + SDL_Event event; + + /* IMPORTANT: Reenable joystick events iif needed. */ + if(SDL_JoystickEventState(SDL_QUERY) == SDL_IGNORE) + SDL_JoystickEventState(SDL_ENABLE); + + /* There's an event waiting to be processed? */ + while (SDL_PollEvent(&event)) + { + do_process_joystick_events( keypad, &event); + } +} + +u16 shift_pressed; + +/* Manage input events */ +int +process_ctrls_events( u16 *keypad, + void (*external_videoResizeFn)( u16 width, u16 height), + float nds_screen_size_ratio) +{ + u16 key; + int cause_quit = 0; + SDL_Event event; + + /* IMPORTANT: Reenable joystick events iif needed. */ + if(SDL_JoystickEventState(SDL_QUERY) == SDL_IGNORE) + SDL_JoystickEventState(SDL_ENABLE); + + /* There's an event waiting to be processed? */ + while (SDL_PollEvent(&event)) + { + if ( !do_process_joystick_events( keypad, &event)) { + switch (event.type) + { + case SDL_VIDEORESIZE: + if ( external_videoResizeFn != NULL) { + external_videoResizeFn( event.resize.w, event.resize.h); + } + break; + + case SDL_KEYDOWN: + switch(event.key.keysym.sym){ + case SDLK_LSHIFT: + shift_pressed |= 1; + break; + case SDLK_RSHIFT: + shift_pressed |= 2; + break; + default: + key = lookup_key(event.key.keysym.sym); + ADD_KEY( *keypad, key ); + break; + } + break; + + case SDL_KEYUP: + switch(event.key.keysym.sym){ + case SDLK_LSHIFT: + shift_pressed &= ~1; + break; + case SDLK_RSHIFT: + shift_pressed &= ~2; + break; + + case SDLK_F1: + case SDLK_F2: + case SDLK_F3: + case SDLK_F4: + case SDLK_F5: + case SDLK_F6: + case SDLK_F7: + case SDLK_F8: + case SDLK_F9: + case SDLK_F10: + int prevexec; + prevexec = execute; + execute = FALSE; + SPU_Pause(1); + if(!shift_pressed){ + loadstate_slot(event.key.keysym.sym - SDLK_F1 + 1); + }else{ + savestate_slot(event.key.keysym.sym - SDLK_F1 + 1); + } + execute = prevexec; + SPU_Pause(!execute); + break; + default: + key = lookup_key(event.key.keysym.sym); + RM_KEY( *keypad, key ); + break; + } + break; + + case SDL_MOUSEBUTTONDOWN: + if(event.button.button==1) + mouse.down = TRUE; + + case SDL_MOUSEMOTION: + if(!mouse.down) + break; + else { + signed long scaled_x = + screen_to_touch_range_x( event.button.x, + nds_screen_size_ratio); + signed long scaled_y = + screen_to_touch_range_y( event.button.y, + nds_screen_size_ratio); + + if( scaled_y >= 192) + set_mouse_coord( scaled_x, scaled_y - 192); + } + break; + + case SDL_MOUSEBUTTONUP: + if(mouse.down) mouse.click = TRUE; + mouse.down = FALSE; + break; + + case SDL_QUIT: + cause_quit = 1; + break; + + default: + break; + } + } + } + + return cause_quit; +} + diff --git a/desmume/src/ctrlssdl.h b/src/ctrlssdl.h similarity index 91% rename from desmume/src/ctrlssdl.h rename to src/ctrlssdl.h index 279e44d55..21149ac37 100644 --- a/desmume/src/ctrlssdl.h +++ b/src/ctrlssdl.h @@ -1,98 +1,99 @@ -/* joysdl.h - this file is part of DeSmuME - * - * Copyright (C) 2007 Pascal Giard - * - * Author: Pascal Giard - * - * This file is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2, or (at your option) - * any later version. - * - * This file is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; see the file COPYING. If not, write to - * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -#ifndef CTRLSSDL_H -#define CTRLSSDL_H - -#include -#include -#include -//#include -#include -#include "MMU.h" - -#include "types.h" - -#define ADD_KEY(keypad,key) ( (keypad) |= (key) ) -#define RM_KEY(keypad,key) ( (keypad) &= ~(key) ) -#define KEYMASK_(k) (1 << (k)) -#define JOY_AXIS_(k) (((k)+1) << 8) - -#define NB_KEYS 14 -#define KEY_NONE 0 -#define KEY_A 1 -#define KEY_B 2 -#define KEY_SELECT 3 -#define KEY_START 4 -#define KEY_RIGHT 5 -#define KEY_LEFT 6 -#define KEY_UP 7 -#define KEY_DOWN 8 -#define KEY_R 9 -#define KEY_L 10 -#define KEY_X 11 -#define KEY_Y 12 -#define KEY_DEBUG 13 -#define KEY_BOOST 14 - -/* Keypad key names */ -extern const char *key_names[NB_KEYS]; -/* Current keyboard configuration */ -extern u16 keyboard_cfg[NB_KEYS]; -/* Current joypad configuration */ -extern u16 joypad_cfg[NB_KEYS]; -/* Number of detected joypads */ -extern u16 nbr_joy; - -#ifndef GTK_UI -struct mouse_status -{ - signed long x; - signed long y; - BOOL click; - BOOL down; -}; - -extern mouse_status mouse; - -void set_mouse_coord(signed long x,signed long y); -#endif // !GTK_UI - -void load_default_config(const u16 kbCfg[]); -BOOL init_joy( void); -void uninit_joy( void); -void set_joy_keys(const u16 joyCfg[]); -void set_kb_keys(const u16 kbCfg[]); -u16 get_set_joy_key(int index); -void get_set_joy_axis(int index, int index_opp); -void update_keypad(u16 keys); -u16 get_keypad( void); -u16 lookup_key (u16 keyval); -u16 lookup_joy_key (u16 keyval); -void -process_ctrls_event( SDL_Event& event, u16 *keypad, - float nds_screen_size_ratio); - -void -process_joystick_events( u16 *keypad); - -#endif /* CTRLSSDL_H */ +/* joysdl.h - this file is part of DeSmuME + * + * Copyright (C) 2007 Pascal Giard + * + * Author: Pascal Giard + * + * This file is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2, or (at your option) + * any later version. + * + * This file is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; see the file COPYING. If not, write to + * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#ifndef CTRLSSDL_H +#define CTRLSSDL_H + +#include +#include +#include +//#include +#include +#include "MMU.h" + +#include "types.h" + +#define ADD_KEY(keypad,key) ( (keypad) |= (key) ) +#define RM_KEY(keypad,key) ( (keypad) &= ~(key) ) +#define KEYMASK_(k) (1 << (k)) +#define JOY_AXIS_(k) (((k)+1) << 8) + +#define NB_KEYS 14 +#define KEY_NONE 0 +#define KEY_A 1 +#define KEY_B 2 +#define KEY_SELECT 3 +#define KEY_START 4 +#define KEY_RIGHT 5 +#define KEY_LEFT 6 +#define KEY_UP 7 +#define KEY_DOWN 8 +#define KEY_R 9 +#define KEY_L 10 +#define KEY_X 11 +#define KEY_Y 12 +#define KEY_DEBUG 13 +#define KEY_BOOST 14 + +/* Keypad key names */ +extern const char *key_names[NB_KEYS]; +/* Current keyboard configuration */ +extern u16 keyboard_cfg[NB_KEYS]; +/* Current joypad configuration */ +extern u16 joypad_cfg[NB_KEYS]; +/* Number of detected joypads */ +extern u16 nbr_joy; + +#ifndef GTK_UI +struct mouse_status +{ + signed long x; + signed long y; + BOOL click; + BOOL down; +}; + +extern mouse_status mouse; + +void set_mouse_coord(signed long x,signed long y); +#endif // !GTK_UI + +void load_default_config(const u16 kbCfg[]); +BOOL init_joy( void); +void uninit_joy( void); +void set_joy_keys(const u16 joyCfg[]); +void set_kb_keys(const u16 kbCfg[]); +u16 get_set_joy_key(int index); +void get_set_joy_axis(int index, int index_opp); +void update_keypad(u16 keys); +u16 get_keypad( void); +u16 lookup_key (u16 keyval); +u16 lookup_joy_key (u16 keyval); +int +process_ctrls_events( u16 *keypad, + void (*external_videoResizeFn)( u16 width, u16 height), + float nds_screen_size_ratio); + +void +process_joystick_events( u16 *keypad); + +#endif /* CTRLSSDL_H */ diff --git a/desmume/src/debug.cpp b/src/debug.cpp similarity index 100% rename from desmume/src/debug.cpp rename to src/debug.cpp diff --git a/desmume/src/debug.h b/src/debug.h similarity index 100% rename from desmume/src/debug.h rename to src/debug.h diff --git a/desmume/src/desmume.mk b/src/desmume.mk similarity index 100% rename from desmume/src/desmume.mk rename to src/desmume.mk diff --git a/desmume/src/driver.h b/src/driver.h similarity index 100% rename from desmume/src/driver.h rename to src/driver.h diff --git a/desmume/src/dscard.h b/src/dscard.h similarity index 96% rename from desmume/src/dscard.h rename to src/dscard.h index ae23efbac..d3a4d4132 100644 --- a/desmume/src/dscard.h +++ b/src/dscard.h @@ -1,34 +1,34 @@ -/* Copyright (C) 2006 thoduv - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#ifndef __DSCARD_H__ -#define __DSCARD_H__ - -typedef struct -{ - - u32 address; - u32 transfer_count; - -} nds_dscard; - -#endif /*__DSCARD_H__*/ - - - +/* Copyright (C) 2006 thoduv + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#ifndef __DSCARD_H__ +#define __DSCARD_H__ + +typedef struct +{ + + u32 address; + u32 transfer_count; + +} nds_dscard; + +#endif /*__DSCARD_H__*/ + + + diff --git a/src/fat.h b/src/fat.h new file mode 100644 index 000000000..f61185836 --- /dev/null +++ b/src/fat.h @@ -0,0 +1,131 @@ +/* + FAT.H + Mic, 2006 + Structures taken from Michael Chisholm's FAT library +*/ + +#ifndef __FAT_H__ +#define __FAT_H__ + +#include "types.h" +#include "PACKED.h" +#include "PACKED_END.h" + +#define ATTRIB_DIR 0x10 +#define ATTRIB_LFN 0x0F + +#define FILE_FREE 0xE5 +/* Name and extension maximum length */ +#define NAME_LEN 8 +#define EXT_LEN 3 + +// Boot Sector - must be packed +#if defined(_MSC_VER) || defined(__INTEL_COMPILER) +#pragma pack(push, 1) +#define DIR_SEP "\\" +typedef struct +{ + u8 jmpBoot[3]; + u8 OEMName[8]; + // BIOS Parameter Block + u16 bytesPerSector; + u8 sectorsPerCluster; + u16 reservedSectors; + u8 numFATs; + u16 rootEntries; + u16 numSectorsSmall; + u8 mediaDesc; + u16 sectorsPerFAT; + u16 sectorsPerTrk; + u16 numHeads; + u32 numHiddenSectors; + u32 numSectors; + struct + { + // Ext BIOS Parameter Block for FAT16 + u8 driveNumber; + u8 reserved1; + u8 extBootSig; + u32 volumeID; + u8 volumeLabel[11]; + u8 fileSysType[8]; + // Bootcode + u8 bootCode[448]; + u16 signature; + } fat16; +} __PACKED BOOT_RECORD; +#pragma pack(pop) + +// Directory entry - must be packed +#pragma pack(push, 1) +typedef struct +{ + u8 name[NAME_LEN] __PACKED; + u8 ext[EXT_LEN] __PACKED; + u8 attrib __PACKED; + u8 reserved __PACKED; + u8 cTime_ms __PACKED; + u16 cTime __PACKED; + u16 cDate __PACKED; + u16 aDate __PACKED; + u16 startClusterHigh __PACKED; + u16 mTime __PACKED; + u16 mDate __PACKED; + u16 startCluster __PACKED; + u32 fileSize __PACKED; +} __PACKED DIR_ENT; +#pragma pack(pop) +#else +#define DIR_SEP "/" +typedef struct +{ + u8 jmpBoot[3]; + u8 OEMName[8]; + // BIOS Parameter Block + u16 bytesPerSector; + u8 sectorsPerCluster; + u16 reservedSectors; + u8 numFATs; + u16 rootEntries; + u16 numSectorsSmall; + u8 mediaDesc; + u16 sectorsPerFAT; + u16 sectorsPerTrk; + u16 numHeads; + u32 numHiddenSectors; + u32 numSectors; + struct + { + // Ext BIOS Parameter Block for FAT16 + u8 driveNumber; + u8 reserved1; + u8 extBootSig; + u32 volumeID; + u8 volumeLabel[11]; + u8 fileSysType[8]; + // Bootcode + u8 bootCode[448]; + u16 signature; + } fat16; +} __PACKED BOOT_RECORD; + +// Directory entry - must be packed +typedef struct +{ + u8 name[NAME_LEN]; + u8 ext[EXT_LEN]; + u8 attrib; + u8 reserved; + u8 cTime_ms; + u16 cTime; + u16 cDate; + u16 aDate; + u16 startClusterHigh; + u16 mTime; + u16 mDate; + u16 startCluster; + u32 fileSize; +} __PACKED DIR_ENT; +#endif + +#endif diff --git a/desmume/src/fs-linux.cpp b/src/fs-linux.cpp similarity index 95% rename from desmume/src/fs-linux.cpp rename to src/fs-linux.cpp index 645cda0e0..5e8193bd5 100644 --- a/desmume/src/fs-linux.cpp +++ b/src/fs-linux.cpp @@ -1,115 +1,115 @@ -/* Copyright (C) 2006 Guillaume Duhamel - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#include "fs.h" - -#include -#include -#include -#include -#include -#include - -typedef struct { - DIR * dir; - char * path; -} FsLinuxDir; - -const char FS_SEPARATOR = '/'; - -void * FsReadFirst(const char * path, FsEntry * entry) { - FsLinuxDir * dir; - struct dirent * e; - struct stat s; - char buffer[512+1]; /* DirSpec[256] + '/' + dirent.d_name[256] */ - DIR * tmp; - - dir = (FsLinuxDir*)malloc(sizeof(FsLinuxDir)); - if (!dir) - return NULL; - - tmp = opendir(path); - if (!tmp) - return NULL; - dir->dir = tmp; - - e = readdir(tmp); - if (!e) { - closedir(tmp); - return NULL; - } - strcpy(entry->cFileName, e->d_name); - // there's no 8.3 file names support on linux :) - strcpy(entry->cAlternateFileName, ""); - entry->flags = 0; - - dir->path = strdup(path); - sprintf(buffer, "%s/%s", dir->path, e->d_name); - - stat(buffer, &s); - if (S_ISDIR(s.st_mode)) { - entry->flags = FS_IS_DIR; - entry->fileSize = 0; - } else { - entry->fileSize = s.st_size; - } - - return dir; -} - -int FsReadNext(void * search, FsEntry * entry) { - FsLinuxDir * dir = (FsLinuxDir*)search; - struct dirent * e; - struct stat s; - char buffer[1024]; - - e = readdir(dir->dir); - if (!e) - return 0; - - strcpy(entry->cFileName, e->d_name); - // there's no 8.3 file names support on linux :) - strcpy(entry->cAlternateFileName, ""); - entry->flags = 0; - - sprintf(buffer, "%s/%s", dir->path, e->d_name); - - stat(buffer, &s); - if (S_ISDIR(s.st_mode)) { - entry->flags = FS_IS_DIR; - entry->fileSize = 0; - } else { - entry->fileSize = s.st_size; - } - - return 1; -} - -void FsClose(void * search) { - FsLinuxDir *linuxdir = (FsLinuxDir *) search; - DIR * dir = linuxdir->dir; - - closedir(dir); - free(linuxdir->path); - free(search); -} - -int FsError(void) { - return 0; -} +/* Copyright (C) 2006 Guillaume Duhamel + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#include "fs.h" + +#include +#include +#include +#include +#include +#include + +typedef struct { + DIR * dir; + char * path; +} FsLinuxDir; + +const char FS_SEPARATOR = '/'; + +void * FsReadFirst(const char * path, FsEntry * entry) { + FsLinuxDir * dir; + struct dirent * e; + struct stat s; + char buffer[512+1]; /* DirSpec[256] + '/' + dirent.d_name[256] */ + DIR * tmp; + + dir = (FsLinuxDir*)malloc(sizeof(FsLinuxDir)); + if (!dir) + return NULL; + + tmp = opendir(path); + if (!tmp) + return NULL; + dir->dir = tmp; + + e = readdir(tmp); + if (!e) { + closedir(tmp); + return NULL; + } + strcpy(entry->cFileName, e->d_name); + // there's no 8.3 file names support on linux :) + strcpy(entry->cAlternateFileName, ""); + entry->flags = 0; + + dir->path = strdup(path); + sprintf(buffer, "%s/%s", dir->path, e->d_name); + + stat(buffer, &s); + if (S_ISDIR(s.st_mode)) { + entry->flags = FS_IS_DIR; + entry->fileSize = 0; + } else { + entry->fileSize = s.st_size; + } + + return dir; +} + +int FsReadNext(void * search, FsEntry * entry) { + FsLinuxDir * dir = (FsLinuxDir*)search; + struct dirent * e; + struct stat s; + char buffer[1024]; + + e = readdir(dir->dir); + if (!e) + return 0; + + strcpy(entry->cFileName, e->d_name); + // there's no 8.3 file names support on linux :) + strcpy(entry->cAlternateFileName, ""); + entry->flags = 0; + + sprintf(buffer, "%s/%s", dir->path, e->d_name); + + stat(buffer, &s); + if (S_ISDIR(s.st_mode)) { + entry->flags = FS_IS_DIR; + entry->fileSize = 0; + } else { + entry->fileSize = s.st_size; + } + + return 1; +} + +void FsClose(void * search) { + FsLinuxDir *linuxdir = (FsLinuxDir *) search; + DIR * dir = linuxdir->dir; + + closedir(dir); + free(linuxdir->path); + free(search); +} + +int FsError(void) { + return 0; +} diff --git a/desmume/src/fs-windows.cpp b/src/fs-windows.cpp similarity index 96% rename from desmume/src/fs-windows.cpp rename to src/fs-windows.cpp index 5f02031db..ea354330e 100644 --- a/desmume/src/fs-windows.cpp +++ b/src/fs-windows.cpp @@ -1,90 +1,90 @@ -/* Copyright (C) 2006 Guillaume Duhamel - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#include "fs.h" - -#include -#include -#include -#include - -const char FS_SEPARATOR = '\\'; - -void * FsReadFirst(const char * p, FsEntry * entry) { - WIN32_FIND_DATA FindFileData; - HANDLE hFind; - HANDLE * ret; - char path[1024]; - if (strlen(p)+3 >sizeof(path)) return NULL ; - - sprintf(path, "%s\\*", p); - - hFind = FindFirstFile(path, &FindFileData); - if (hFind == INVALID_HANDLE_VALUE) - return NULL; - - strncpy(entry->cFileName, FindFileData.cFileName,256); - entry->cFileName[255] = 0 ; - strncpy(entry->cAlternateFileName, FindFileData.cAlternateFileName,14); - entry->cAlternateFileName[13] = 0 ; - entry->flags = 0; - if (FindFileData.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY) { - entry->flags = FS_IS_DIR; - entry->fileSize = 0; - } else { - entry->fileSize = FindFileData.nFileSizeLow; - } - - ret = (void**)malloc(sizeof(HANDLE)); - *ret = hFind; - return ret; -} - -int FsReadNext(void * search, FsEntry * entry) { - WIN32_FIND_DATA FindFileData; - HANDLE * h = (HANDLE *) search; - int ret; - - ret = FindNextFile(*h, &FindFileData); - - strncpy(entry->cFileName, FindFileData.cFileName,256); - entry->cFileName[255] = 0 ; - strncpy(entry->cAlternateFileName, FindFileData.cAlternateFileName,14); - entry->cAlternateFileName[13] = 0 ; - entry->flags = 0; - if (FindFileData.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY) { - entry->flags = FS_IS_DIR; - entry->fileSize = 0; - } else { - entry->fileSize = FindFileData.nFileSizeLow; - } - - return ret; -} - -void FsClose(void * search) { - FindClose(*((HANDLE *) search)); -} - -int FsError(void) { - if (GetLastError() == ERROR_NO_MORE_FILES) - return FS_ERR_NO_MORE_FILES; - - return FS_ERR_UNKNOWN; -} +/* Copyright (C) 2006 Guillaume Duhamel + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#include "fs.h" + +#include +#include +#include +#include + +const char FS_SEPARATOR = '\\'; + +void * FsReadFirst(const char * p, FsEntry * entry) { + WIN32_FIND_DATA FindFileData; + HANDLE hFind; + HANDLE * ret; + char path[1024]; + if (strlen(p)+3 >sizeof(path)) return NULL ; + + sprintf(path, "%s\\*", p); + + hFind = FindFirstFile(path, &FindFileData); + if (hFind == INVALID_HANDLE_VALUE) + return NULL; + + strncpy(entry->cFileName, FindFileData.cFileName,256); + entry->cFileName[255] = 0 ; + strncpy(entry->cAlternateFileName, FindFileData.cAlternateFileName,14); + entry->cAlternateFileName[13] = 0 ; + entry->flags = 0; + if (FindFileData.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY) { + entry->flags = FS_IS_DIR; + entry->fileSize = 0; + } else { + entry->fileSize = FindFileData.nFileSizeLow; + } + + ret = (void**)malloc(sizeof(HANDLE)); + *ret = hFind; + return ret; +} + +int FsReadNext(void * search, FsEntry * entry) { + WIN32_FIND_DATA FindFileData; + HANDLE * h = (HANDLE *) search; + int ret; + + ret = FindNextFile(*h, &FindFileData); + + strncpy(entry->cFileName, FindFileData.cFileName,256); + entry->cFileName[255] = 0 ; + strncpy(entry->cAlternateFileName, FindFileData.cAlternateFileName,14); + entry->cAlternateFileName[13] = 0 ; + entry->flags = 0; + if (FindFileData.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY) { + entry->flags = FS_IS_DIR; + entry->fileSize = 0; + } else { + entry->fileSize = FindFileData.nFileSizeLow; + } + + return ret; +} + +void FsClose(void * search) { + FindClose(*((HANDLE *) search)); +} + +int FsError(void) { + if (GetLastError() == ERROR_NO_MORE_FILES) + return FS_ERR_NO_MORE_FILES; + + return FS_ERR_UNKNOWN; +} diff --git a/desmume/src/fs.h b/src/fs.h similarity index 96% rename from desmume/src/fs.h rename to src/fs.h index c48bb0da1..1721d9a91 100644 --- a/desmume/src/fs.h +++ b/src/fs.h @@ -1,44 +1,44 @@ -/* Copyright (C) 2006 Guillaume Duhamel - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#ifndef FS_H -#define FS_H - -#include "types.h" - -#define FS_IS_DIR 1 - -#define FS_ERR_UNKNOWN -1 -#define FS_ERR_NO_MORE_FILES 1 - -extern const char FS_SEPARATOR; - -typedef struct { - char cFileName[256]; - char cAlternateFileName[14]; - u32 flags; - u32 fileSize; -} FsEntry; - -void * FsReadFirst(const char * path, FsEntry * entry); -int FsReadNext(void * search, FsEntry * entry); -void FsClose(void * search); -int FsError(void); - -#endif +/* Copyright (C) 2006 Guillaume Duhamel + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#ifndef FS_H +#define FS_H + +#include "types.h" + +#define FS_IS_DIR 1 + +#define FS_ERR_UNKNOWN -1 +#define FS_ERR_NO_MORE_FILES 1 + +extern const char FS_SEPARATOR; + +typedef struct { + char cFileName[256]; + char cAlternateFileName[14]; + u32 flags; + u32 fileSize; +} FsEntry; + +void * FsReadFirst(const char * path, FsEntry * entry); +int FsReadNext(void * search, FsEntry * entry); +void FsClose(void * search); +int FsError(void); + +#endif diff --git a/desmume/src/gdbstub.h b/src/gdbstub.h similarity index 96% rename from desmume/src/gdbstub.h rename to src/gdbstub.h index 06544d6e7..3331c0f58 100644 --- a/desmume/src/gdbstub.h +++ b/src/gdbstub.h @@ -1,58 +1,58 @@ -/* $Id: gdbstub.h,v 1.1 2007-06-07 09:43:25 masscat Exp $ - */ -/* Copyright (C) 2006 Ben Jaques - * masscat@btinternet.com - * - * This file is part of DeSmuME - * - * DeSmuME is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * DeSmuME is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with DeSmuME; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - */ - -#ifndef _GDBSTUB_H_ -#define _GDBSTUB_H_ 1 - -#include "types.h" - -typedef void *gdbstub_handle_t; - -/* - * The function interface - */ - -gdbstub_handle_t -createStub_gdb( u16 port, - struct armcpu_memory_iface **cpu_memio, - struct armcpu_memory_iface *direct_memio); - -void -destroyStub_gdb( gdbstub_handle_t stub); - -void -activateStub_gdb( gdbstub_handle_t stub, - struct armcpu_ctrl_iface *cpu_ctrl); - - /* - * An implementation of the following functions is required - * for the GDB stub to function. - */ -void * -createThread_gdb( void (WINAPI *thread_function)( void *data), - void *thread_data); - -void -joinThread_gdb( void *thread_handle); - -#endif /* End of _GDBSTUB_H_ */ - +/* $Id: gdbstub.h,v 1.1 2007-06-07 09:43:25 masscat Exp $ + */ +/* Copyright (C) 2006 Ben Jaques + * masscat@btinternet.com + * + * This file is part of DeSmuME + * + * DeSmuME is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * DeSmuME is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with DeSmuME; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + */ + +#ifndef _GDBSTUB_H_ +#define _GDBSTUB_H_ 1 + +#include "types.h" + +typedef void *gdbstub_handle_t; + +/* + * The function interface + */ + +gdbstub_handle_t +createStub_gdb( u16 port, + struct armcpu_memory_iface **cpu_memio, + struct armcpu_memory_iface *direct_memio); + +void +destroyStub_gdb( gdbstub_handle_t stub); + +void +activateStub_gdb( gdbstub_handle_t stub, + struct armcpu_ctrl_iface *cpu_ctrl); + + /* + * An implementation of the following functions is required + * for the GDB stub to function. + */ +void * +createThread_gdb( void (WINAPI *thread_function)( void *data), + void *thread_data); + +void +joinThread_gdb( void *thread_handle); + +#endif /* End of _GDBSTUB_H_ */ + diff --git a/desmume/src/gdbstub/Makefile.am b/src/gdbstub/Makefile.am similarity index 100% rename from desmume/src/gdbstub/Makefile.am rename to src/gdbstub/Makefile.am diff --git a/desmume/src/gdbstub/gdbstub.cpp b/src/gdbstub/gdbstub.cpp similarity index 96% rename from desmume/src/gdbstub/gdbstub.cpp rename to src/gdbstub/gdbstub.cpp index 20f4c5800..b6d867460 100644 --- a/desmume/src/gdbstub/gdbstub.cpp +++ b/src/gdbstub/gdbstub.cpp @@ -1,1617 +1,1617 @@ -/* $Id: gdbstub.c,v 1.1 2007-06-07 09:43:25 masscat Exp $ - */ -/* - * THE SOFTWARE WITHIN THIS FILE IS NOT COPYRIGHTED - * - * Originally written by Ben Jaques. - * - * The software is offered for use in the public domain in the hope that - * it will be useful, but WITHOUT ANY WARRANTY; without even the implied - * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. - */ -#include -//#include -#include -#include - -#include - -#ifdef WIN32 -#include -#else -#include -#include -#include -#include -#include -#endif - -#include "armcpu.h" - -#define uint32_t u32 -#define uint16_t u16 -#define uint8_t u8 - -#include "gdbstub.h" -#include "gdbstub_internal.h" - -#ifdef __GNUC__ -#define UNUSED_PARM( parm) parm __attribute__((unused)) -#else -#define UNUSED_PARM( parm) parm -#endif - -#if 0 -#define DEBUG_LOG( fmt, ...) fprintf(stdout, fmt, ##__VA_ARGS__) -#else -#define DEBUG_LOG( fmt, ...) -#endif - -#if 0 -#define LOG_ERROR( fmt, ...) fprintf(stderr, fmt, ##__VA_ARGS__) -#else -#define LOG_ERROR( fmt, ...) -#endif - -#define LITTLE_ENDIAN_TO_UINT32_T( v) (\ - ((v)[3] << 24) | \ - ((v)[2] << 16) | \ - ((v)[1] << 8) | \ - ((v)[0] << 0)) - -/* - * The state of the packet reader - */ -#define IDLE_READ_STATE 0 -#define MID_PACKET_READ_STATE 1 -#define FIRST_CHECKSUM_READ_STATE 2 -#define SECOND_CHECKSUM_READ_STATE 3 - -/* - * The gdb stub thread control message types. - */ -enum stub_message_type { - /** The quit message type */ - QUIT_STUB_MESSAGE = 0, - /** The emulated CPU has stopped */ - CPU_STOPPED_STUB_MESSAGE = 1 -}; - - -/* - * The GDB signal values - */ -enum target_signal - { - /* Used some places (e.g. stop_signal) to record the concept that - there is no signal. */ - TARGET_SIGNAL_0 = 0, - TARGET_SIGNAL_FIRST = 0, - TARGET_SIGNAL_HUP = 1, - TARGET_SIGNAL_INT = 2, - TARGET_SIGNAL_QUIT = 3, - TARGET_SIGNAL_ILL = 4, - TARGET_SIGNAL_TRAP = 5, - TARGET_SIGNAL_ABRT = 6, - TARGET_SIGNAL_EMT = 7, - TARGET_SIGNAL_FPE = 8, - TARGET_SIGNAL_KILL = 9, - TARGET_SIGNAL_BUS = 10, - TARGET_SIGNAL_SEGV = 11, - TARGET_SIGNAL_SYS = 12, - TARGET_SIGNAL_PIPE = 13, - TARGET_SIGNAL_ALRM = 14, - TARGET_SIGNAL_TERM = 15, - TARGET_SIGNAL_URG = 16, - TARGET_SIGNAL_STOP = 17, - TARGET_SIGNAL_TSTP = 18, - TARGET_SIGNAL_CONT = 19, - TARGET_SIGNAL_CHLD = 20, - TARGET_SIGNAL_TTIN = 21, - TARGET_SIGNAL_TTOU = 22, - TARGET_SIGNAL_IO = 23, - TARGET_SIGNAL_XCPU = 24, - TARGET_SIGNAL_XFSZ = 25, - TARGET_SIGNAL_VTALRM = 26, - TARGET_SIGNAL_PROF = 27, - TARGET_SIGNAL_WINCH = 28, - TARGET_SIGNAL_LOST = 29, - TARGET_SIGNAL_USR1 = 30, - TARGET_SIGNAL_USR2 = 31, - TARGET_SIGNAL_PWR = 32, - /* Similar to SIGIO. Perhaps they should have the same number. */ - TARGET_SIGNAL_POLL = 33, - TARGET_SIGNAL_WIND = 34, - TARGET_SIGNAL_PHONE = 35, - TARGET_SIGNAL_WAITING = 36, - TARGET_SIGNAL_LWP = 37, - TARGET_SIGNAL_DANGER = 38, - TARGET_SIGNAL_GRANT = 39, - TARGET_SIGNAL_RETRACT = 40, - TARGET_SIGNAL_MSG = 41, - TARGET_SIGNAL_SOUND = 42, - TARGET_SIGNAL_SAK = 43, - TARGET_SIGNAL_PRIO = 44, - }; - - - - - -static void -causeQuit_gdb( struct gdb_stub_state *stub) { - uint8_t command = QUIT_STUB_MESSAGE; - -#ifdef WIN32 - send( stub->ctl_pipe[1], (char*)&command, 1, 0); -#else - write( stub->ctl_pipe[1], &command, 1); -#endif -} - -static void -indicateCPUStop_gdb( struct gdb_stub_state *stub) { - uint8_t command = CPU_STOPPED_STUB_MESSAGE; - -#ifdef WIN32 - send( stub->ctl_pipe[1], (char*)&command, 1, 0); -#else - write( stub->ctl_pipe[1], &command, 1); -#endif -} - - - - -/* - * - * - * - */ -static void -break_execution( void *data, UNUSED_PARM(uint32_t addr), UNUSED_PARM(int thunmb)) { - struct gdb_stub_state *stub = (struct gdb_stub_state *)data; - - /* stall the processor */ - stub->cpu_ctrl->stall( stub->cpu_ctrl->data); - - /* remove the post execution function */ - stub->cpu_ctrl->remove_post_ex_fn( stub->cpu_ctrl->data); - - /* indicate the halt */ - stub->stop_type = STOP_HOST_BREAK; - indicateCPUStop_gdb( stub); -} - - -static void -step_instruction_watch( void *data, uint32_t addr, UNUSED_PARM(int thunmb)) { - struct gdb_stub_state *stub = (struct gdb_stub_state *)data; - - DEBUG_LOG("Step watch: waiting for %08x at %08x\n", stub->step_instr_address, - addr); - - if ( addr == stub->step_instr_address) { - DEBUG_LOG("Step hit -> %08x\n", stub->cpu_ctrl->read_reg( stub->cpu_ctrl->data, 15)); - /* stall the processor */ - stub->cpu_ctrl->stall( stub->cpu_ctrl->data); - - /* remove the post execution function */ - stub->cpu_ctrl->remove_post_ex_fn( stub->cpu_ctrl->data); - - /* indicate the halt */ - stub->stop_type = STOP_STEP_BREAK; - indicateCPUStop_gdb( stub); - } -} - - - - - -/************************************************************************/ -/* BUFMAX defines the maximum number of characters in inbound/outbound buffers*/ -/* at least NUMREGBYTES*2 are needed for register packets */ -#define BUFMAX 2048 - - - -static const char hexchars[]="0123456789abcdef"; - -/* - * Convert ch from a hex digit to an int - */ -static int -hex (unsigned char ch) { - if (ch >= 'a' && ch <= 'f') - return ch-'a'+10; - if (ch >= '0' && ch <= '9') - return ch-'0'; - if (ch >= 'A' && ch <= 'F') - return ch-'A'+10; - return -1; -} - -static const unsigned char * -hex2mem ( const unsigned char *buf, uint8_t *mem, int count) { - int i; - unsigned char ch; - - for (i=0; i 0) - { - ch = memio->read8( memio->data, mem_addr++); - *buf++ = hexchars[ch >> 4]; - *buf++ = hexchars[ch & 0xf]; - } - - *buf = 0; - - return buf; -} - - - -static enum read_res_gdb -readPacket_gdb( SOCKET_TYPE sock, struct packet_reader_gdb *packet) { - uint8_t cur_byte; - enum read_res_gdb read_res = READ_NOT_FINISHED; - int sock_res; - - /* update the state */ - - while ( (sock_res = recv( sock, (char*)&cur_byte, 1, 0)) == 1) { - switch ( packet->state) { - case IDLE_READ_STATE: - /* wait for the '$' start of packet character - */ - if ( cur_byte == '$') { - //DEBUG_LOG( "Found packet\n"); - packet->state = MID_PACKET_READ_STATE; - packet->pos_index = 0; - packet->checksum = 0; - } - /* Is this the break command */ - else if ( cur_byte == 3) { - //DEBUG_LOG( "GDB has sent a break\n"); - packet->buffer[0] = cur_byte; - packet->buffer[1] = 0; - packet->pos_index = 1; - return READ_BREAK; - } - break; - - case MID_PACKET_READ_STATE: - if ( cur_byte == '#') { - //DEBUG_LOG( "\nAbout to get checksum\n"); - packet->buffer[packet->pos_index] = '\0'; - packet->state = FIRST_CHECKSUM_READ_STATE; - } - else if ( packet->pos_index >= BUFMAX - 1) { - //DEBUG_LOG( "read buffer exceeded\n"); - packet->state = IDLE_READ_STATE; - } - else { - //DEBUG_LOG( "%c", cur_byte); - packet->checksum = packet->checksum + cur_byte; - packet->buffer[packet->pos_index] = cur_byte; - packet->pos_index = packet->pos_index + 1; - } - break; - - case FIRST_CHECKSUM_READ_STATE: - packet->read_checksum = hex( cur_byte) << 4; - packet->state = SECOND_CHECKSUM_READ_STATE; - break; - - case SECOND_CHECKSUM_READ_STATE: { - packet->read_checksum += hex( cur_byte); - packet->state = IDLE_READ_STATE; - return READ_COMPLETE; - break; - } - } - } - - if ( sock_res == 0) { - read_res = READ_SOCKET_ERROR; - } - else if ( sock_res == -1) { - if ( errno != EAGAIN) { - read_res = READ_SOCKET_ERROR; - } - } - - return read_res; -} - - -struct hidden_debug_out_packet { - unsigned char *start_ptr; -}; -struct debug_out_packet { - unsigned char *const start_ptr; -}; - -static struct hidden_debug_out_packet the_out_packet; -static unsigned char hidden_buffer[BUFMAX]; - - -static struct debug_out_packet * -getOutPacket( void) { - the_out_packet.start_ptr = &hidden_buffer[1]; - return (struct debug_out_packet *)&the_out_packet; -} - -#define CHECKSUM_PART_SIZE 3 -/** - * send the packet in buffer. - */ -static int -putpacket ( SOCKET_TYPE sock, struct debug_out_packet *out_packet, uint32_t size) { - unsigned char checksum = 0; - uint32_t count; - unsigned char *ch_ptr = (unsigned char *)&out_packet->start_ptr[-1]; - uint8_t reply_ch; - - //DEBUG_LOG_START( "Putting packet size %d ", size); - /* add the '$' to the start of the packet */ - *ch_ptr++ = '$'; - - /* calculate and add the checksum to the packet */ - for ( count = 0; count < size; count += 1) { - checksum += ch_ptr[count]; - //DEBUG_LOG_PART("%c", ch_ptr[count]); - } - //DEBUG_LOG_PART("\n"); - - ch_ptr[count++] = '#'; - ch_ptr[count++] = hexchars[checksum >> 4]; - ch_ptr[count++] = hexchars[checksum & 0xf]; - ch_ptr[count] = '\0'; - //DEBUG_LOG("packet %s\n", &out_packet->start_ptr[-1]); - - /* add one for the '$' character */ - count += 1; - - do { - int reply_found = 0; - - send( sock, (char*)&out_packet->start_ptr[-1], count, 0); - - do { - int read_res = recv( sock, (char*)&reply_ch, 1, 0); - - if ( read_res == 0) { - return -1; - } - else if ( read_res == -1) { - if ( errno != EAGAIN) { - return -1; - } - } - else { - reply_found = 1; - } - } while ( !reply_found); - } while ( reply_ch != '+'); - - /* $#. */ - return count - 4; -} - - - -static uint32_t -make_stop_packet( uint8_t *ptr, enum stop_type type, uint32_t stop_address) { - uint32_t stop_size = 0; - int watch_index = 0; - const char watch_chars[] = { 'a', 'r' }; - - switch (type) { - case STOP_UNKNOWN: - case STOP_HOST_BREAK: - ptr[0] = 'S'; - ptr[1] = hexchars[TARGET_SIGNAL_INT >> 4]; - ptr[2] = hexchars[TARGET_SIGNAL_INT & 0xf]; - stop_size = 3; - break; - - case STOP_STEP_BREAK: - case STOP_BREAKPOINT: - ptr[0] = 'S'; - ptr[1] = hexchars[TARGET_SIGNAL_TRAP >> 4]; - ptr[2] = hexchars[TARGET_SIGNAL_TRAP & 0xf]; - stop_size = 3; - break; - - case STOP_WATCHPOINT: - watch_index = 1; - case STOP_RWATCHPOINT: - watch_index += 1; - case STOP_AWATCHPOINT: - { - int i; - int out_index = 0; - ptr[out_index++] = 'T'; - ptr[out_index++] = hexchars[TARGET_SIGNAL_ABRT >> 4]; - ptr[out_index++] = hexchars[TARGET_SIGNAL_ABRT & 0xf]; - - if ( watch_index < 2) { - ptr[out_index++] = watch_chars[watch_index]; - } - ptr[out_index++] = 'w'; - ptr[out_index++] = 'a'; - ptr[out_index++] = 't'; - ptr[out_index++] = 'c'; - ptr[out_index++] = 'h'; - ptr[out_index++] = ':'; - - for ( i = 0; i < 8; i++) { - ptr[out_index++] = hexchars[(stop_address >> (i * 4)) & 0xf]; - } - ptr[out_index++] = ';'; - - stop_size = out_index; - } - break; - } - - return stop_size; -} - -/** - * Returns -1 if there is a socket error. - */ -static int -processPacket_gdb( SOCKET_TYPE sock, const uint8_t *packet, - struct gdb_stub_state *stub) { - // uint8_t remcomOutBuffer[BUFMAX_GDB]; - struct debug_out_packet *out_packet = getOutPacket(); - uint8_t *out_ptr = out_packet->start_ptr; - int send_reply = 1; - uint32_t send_size = 0; - - DEBUG_LOG("Processing packet %c\n", packet[0]); - - switch( packet[0]) { - case 3: - /* The break command */ - //stub->running_state = gdb_stub_state::STOPPED_GDB_STATE; - //*ptr++ = 'S'; - //*ptr++ = hexchars[0x2 >> 4]; - //*ptr++ = hexchars[0x2 & 0xf]; - //*ptr++ = 0; - send_reply = 0; - break; - - case '?': - send_size = make_stop_packet( out_ptr, stub->stop_type, stub->stop_address); - /**ptr++ = 'S'; - *ptr++ = hexchars[stub->stop_reason >> 4]; - *ptr++ = hexchars[stub->stop_reason & 0xf]; - send_size = 3;*/ - break; - - case 'c': - stub->emu_stub_state = gdb_stub_state::RUNNING_EMU_GDB_STATE; - stub->ctl_stub_state = gdb_stub_state::START_RUN_GDB_STATE; - stub->main_stop_flag = 0; - send_reply = 0; - /* remove the cpu stall */ - stub->cpu_ctrl->unstall( stub->cpu_ctrl->data); - break; - - case 's': { - uint32_t instr_addr = stub->cpu_ctrl->read_reg( stub->cpu_ctrl->data, 15); - /* Determine where the next instruction will take the CPU. - * Execute the instruction using a copy of the CPU with a zero memory interface. - */ - DEBUG_LOG( "Stepping instruction at %08x\n", instr_addr); - - /* install the post execution function */ - stub->step_instr_address = instr_addr; - stub->cpu_ctrl->install_post_ex_fn( stub->cpu_ctrl->data, - step_instruction_watch, - stub); - - - stub->emu_stub_state = gdb_stub_state::RUNNING_EMU_GDB_STATE; - stub->ctl_stub_state = gdb_stub_state::START_RUN_GDB_STATE; - stub->main_stop_flag = 0; - send_reply = 0; - - /* remove the cpu stall */ - stub->cpu_ctrl->unstall( stub->cpu_ctrl->data); - break; - } - - /* - * Register set - */ - case 'P': { - uint32_t reg; - uint32_t value; - const uint8_t *rx_ptr = &packet[1]; - - DEBUG_LOG("Processing packet %s\n", packet); - if ( hexToInt( &rx_ptr, ®)) { - if ( *rx_ptr++ == '=') { - uint8_t tmp_mem[4]; - - rx_ptr = hex2mem( rx_ptr, tmp_mem, 4); - value = LITTLE_ENDIAN_TO_UINT32_T( tmp_mem); - DEBUG_LOG("Setting reg %d to %08x\n", reg, value); - if ( reg < 16) - stub->cpu_ctrl->set_reg( stub->cpu_ctrl->data, reg, value); - if ( reg == 25) { - stub->cpu_ctrl->set_reg( stub->cpu_ctrl->data, 16, value); - } - - strcpy( (char *)out_ptr, "OK"); - send_size = 2; - } - } - break; - } - - case 'm': { - uint32_t addr = 0; - uint32_t length = 0; - int error01 = 1; - const uint8_t *rx_ptr = &packet[1]; - - if ( hexToInt( &rx_ptr, &addr)) { - if ( *rx_ptr++ == ',') { - if ( hexToInt( &rx_ptr, &length)) { - //DEBUG_LOG("mem read from %08x (%d)\n", addr, length); - if ( !mem2hex( stub->direct_memio, addr, out_ptr, length)) { - strcpy ( (char *)out_ptr, "E03"); - send_size = 3; - } - else { - send_size = length * 2; - } - error01 = 0; - } - } - } - if ( error01) - strcpy( (char *)out_ptr,"E01"); - break; - } - - /* MAA..AA,LLLL: Write LLLL bytes at address AA.AA return OK */ - case 'M': { - /* Try to read '%x,%x:'. */ - const uint8_t *rx_ptr = &packet[1]; - uint32_t addr = 0; - uint32_t length = 0; - int error01 = 1; - DEBUG_LOG("Memory write %s\n", rx_ptr); - if ( hexToInt(&rx_ptr, &addr)) { - if ( *rx_ptr++ == ',') { - if ( hexToInt(&rx_ptr, &length)) { - if ( *rx_ptr++ == ':') { - uint8_t write_byte; - unsigned int i; - DEBUG_LOG("Memory write of %d bytes to %08x\n", - length, addr); - - for ( i = 0; i < length; i++) { - rx_ptr = hex2mem( rx_ptr, &write_byte, 1); - - stub->direct_memio->write8( stub->direct_memio->data, - addr++, write_byte); - } - - strcpy( (char *)out_ptr, "OK"); - error01 = 0; - } - } - else { - DEBUG_LOG("Failed to find length (addr %08x)\n", addr); - } - } - else { - DEBUG_LOG("expected ',' got '%c' (addr = %08x)\n", *rx_ptr, addr); - } - } - else { - DEBUG_LOG("Failed to find addr\n"); - } - - if ( error01) { - strcpy( (char *)out_ptr, "E02"); - } - break; - } - - case 'Z': - case 'z': { - const uint8_t *rx_ptr = &packet[2]; - int remove_flag = 0; - - if ( packet[0] == 'z') - remove_flag = 1; - - DEBUG_LOG( "%c%c packet %s (remove? %d)\n", packet[0], packet[1], - rx_ptr, remove_flag); - - switch ( packet[1]) { - - /* all instruction breakpoints are treated the same */ - case '0': - case '1': - case '2': - case '3': - case '4': - { - uint32_t addr = 0; - uint32_t length = 0; - int error01 = 1; - struct breakpoint_gdb **bpoint_list; - - switch ( packet[1]) { - case '0': - case '1': - bpoint_list = &stub->instr_breakpoints; - break; - - case '2': - bpoint_list = &stub->write_breakpoints; - break; - - case '3': - bpoint_list = &stub->read_breakpoints; - break; - - case '4': - bpoint_list = &stub->access_breakpoints; - break; - } - - if ( *rx_ptr++ == ',') { - DEBUG_LOG("%s\n", rx_ptr); - - if ( hexToInt( &rx_ptr, &addr)) { - if ( *rx_ptr++ == ',') { - DEBUG_LOG("addr %08x %s\n", addr, rx_ptr); - - if ( hexToInt( &rx_ptr, &length)) { - if ( remove_flag) { - int removed = 0; - struct breakpoint_gdb *last_bpoint = NULL; - struct breakpoint_gdb *bpoint = *bpoint_list; - - while ( bpoint != NULL && !removed) { - if ( bpoint->addr == addr) { - DEBUG_LOG("Breakpoint(%c) at %08x removed\n", packet[1], addr); - removed = 1; - - if ( last_bpoint == NULL) { - *bpoint_list = bpoint->next; - } - else { - last_bpoint->next = bpoint->next; - } - bpoint->next = stub->free_breakpoints; - stub->free_breakpoints = bpoint; - } - last_bpoint = bpoint; - bpoint = bpoint->next; - } - - strcpy( (char *)out_ptr, "OK"); - send_size = 2; - error01 = 0; - } - else { - /* get a breakpoint descriptor from the free pool and add it to - * the current stub instruction breakpoint list */ - struct breakpoint_gdb *bpoint = stub->free_breakpoints; - - if ( bpoint != NULL) { - DEBUG_LOG( "Breakpoint(%c) added at %08x length %d\n", - packet[1], addr, length); - stub->free_breakpoints = bpoint->next; - - bpoint->addr = addr; - bpoint->size = length; - - bpoint->next = *bpoint_list; - *bpoint_list = bpoint; - - strcpy( (char *)out_ptr, "OK"); - send_size = 2; - error01 = 0; - } - } - } - } - } - } - - if ( error01) { - strcpy( (char *)out_ptr, "E01"); - send_size = 3; - } - } - break; - - default: - break; - } - break; - } - - /* - * Set the register values - */ - case 'G': - { - int i; - const uint8_t *rx_ptr = &packet[1]; - uint32_t reg_values[16]; - uint32_t cpsr; - uint8_t tmp_mem[4]; - DEBUG_LOG("'G' command %s\n", rx_ptr); - - /* general purpose regs 0 to 15 */ - for ( i = 0; i < 16; i++) { - rx_ptr = hex2mem( rx_ptr, tmp_mem, 4); - - reg_values[i] = LITTLE_ENDIAN_TO_UINT32_T( tmp_mem); - DEBUG_LOG("Setting reg %d to %08x\n", i, reg_values[i]); - } - - /* skip the floaing point registers and floating point status register */ - rx_ptr += 8 * (96 / 8 * 2); - rx_ptr += 8; - - /* the CPSR register is last */ - rx_ptr = hex2mem( rx_ptr, tmp_mem, 4); - cpsr = LITTLE_ENDIAN_TO_UINT32_T( tmp_mem); - DEBUG_LOG("Setting cpsr to %08x\n", cpsr); - - strcpy( (char *)out_ptr, "OK"); - send_size = 2; - break; - } - - case 'g': /* return the value of the CPU registers */ - { - int i; - int out_index = 0; - uint32_t pc_value = stub->cpu_ctrl->read_reg( stub->cpu_ctrl->data, 15); - uint32_t cpsr_value = stub->cpu_ctrl->read_reg( stub->cpu_ctrl->data, 16); - - DEBUG_LOG("'g' command PC = %08x\n", pc_value); - - /* general purpose regs 0 to 14 */ - for ( i = 0; i < 15; i++) { - uint32_t reg = stub->cpu_ctrl->read_reg( stub->cpu_ctrl->data, i); - out_ptr[out_index++] = hexchars[(reg >> 4) & 0xf]; - out_ptr[out_index++] = hexchars[(reg >> 0) & 0xf]; - out_ptr[out_index++] = hexchars[(reg >> 12) & 0xf]; - out_ptr[out_index++] = hexchars[(reg >> 8) & 0xf]; - out_ptr[out_index++] = hexchars[(reg >> 20) & 0xf]; - out_ptr[out_index++] = hexchars[(reg >> 16) & 0xf]; - out_ptr[out_index++] = hexchars[(reg >> 28) & 0xf]; - out_ptr[out_index++] = hexchars[(reg >> 24) & 0xf]; - } - - out_ptr[out_index++] = hexchars[(pc_value >> 4) & 0xf]; - out_ptr[out_index++] = hexchars[(pc_value >> 0) & 0xf]; - out_ptr[out_index++] = hexchars[(pc_value >> 12) & 0xf]; - out_ptr[out_index++] = hexchars[(pc_value >> 8) & 0xf]; - out_ptr[out_index++] = hexchars[(pc_value >> 20) & 0xf]; - out_ptr[out_index++] = hexchars[(pc_value >> 16) & 0xf]; - out_ptr[out_index++] = hexchars[(pc_value >> 28) & 0xf]; - out_ptr[out_index++] = hexchars[(pc_value >> 24) & 0xf]; - - /* floating point registers (8 96bit) */ - for ( i = 0; i < 8; i++) { - int j; - for ( j = 0; j < (96/4); j++) { - out_ptr[out_index++] = '0'; - } - } - - /* floating point status register? */ - for ( i = 0; i < 1; i++) { - int j; - for ( j = 0; j < 8; j++) { - out_ptr[out_index++] = '0'; - } - } - - /* The CPSR */ - for ( i = 0; i < 1; i++) { - out_ptr[out_index++] = hexchars[(cpsr_value >> 4) & 0xf]; - out_ptr[out_index++] = hexchars[(cpsr_value >> 0) & 0xf]; - out_ptr[out_index++] = hexchars[(cpsr_value >> 12) & 0xf]; - out_ptr[out_index++] = hexchars[(cpsr_value >> 8) & 0xf]; - out_ptr[out_index++] = hexchars[(cpsr_value >> 20) & 0xf]; - out_ptr[out_index++] = hexchars[(cpsr_value >> 16) & 0xf]; - out_ptr[out_index++] = hexchars[(cpsr_value >> 28) & 0xf]; - out_ptr[out_index++] = hexchars[(cpsr_value >> 24) & 0xf]; - } - send_size = out_index; - } - break; - } - - if ( send_reply) { - return putpacket( sock, out_packet, send_size); - } - - return 0; -} - - - -/** - * create the listening socket - */ -static SOCKET_TYPE -createSocket ( int port) { - SOCKET_TYPE sock; - struct sockaddr_in bind_addr; - - memset (&bind_addr, 0, sizeof (bind_addr)); - bind_addr.sin_family = AF_INET; - bind_addr.sin_port = htons( port); - bind_addr.sin_addr.s_addr = htonl (INADDR_ANY); - - /* create the socket, bind the address */ - - sock = socket (PF_INET, SOCK_STREAM, 0); - -#ifdef WIN32 - if ( sock != INVALID_SOCKET) -#else - if (sock != -1) -#endif - { - if (bind (sock, (struct sockaddr *) &bind_addr, - sizeof (bind_addr)) == -1) { - LOG_ERROR("Bind failed \"%s\" port %d\n", strerror( errno), port); -#ifdef WIN32 - closesocket( sock); -#else - close (sock); -#endif - sock = -1; - } - else if (listen (sock, 5) == -1) { - LOG_ERROR("Listen failed \"%s\"\n", strerror( errno)); -#ifdef WIN32 - closesocket( sock); -#else - close (sock); -#endif - sock = -1; - } - } - else { -#ifdef WIN32 - char message[30]; - int error = WSAGetLastError(); - sprintf( message, "Error creating socket %d\n", error); - LOG_ERROR("Error creating socket %d\n", error); -#endif - } - - return sock; -} - - - - -/* - * Handle GDB stub connections. - */ - - -/** - */ -INLINE static int -check_breaks_gdb( struct gdb_stub_state *gdb_state, - struct breakpoint_gdb *bpoint_list, - uint32_t addr, - UNUSED_PARM(uint32_t size), - enum stop_type stop_type) { - int found_break = 0; - - if ( gdb_state->active) { - struct breakpoint_gdb *bpoint = bpoint_list; - - while ( bpoint != NULL && !found_break) { - if ( addr == bpoint->addr) { - DEBUG_LOG("Breakpoint hit at %08x\n", addr); - - /* stall the processor */ - gdb_state->cpu_ctrl->stall( gdb_state->cpu_ctrl->data); - - /* indicate the break to the GDB stub thread */ - gdb_state->stop_type = stop_type; - gdb_state->stop_address = addr; - indicateCPUStop_gdb( gdb_state); - } - bpoint = bpoint->next; - } - } - - return found_break; -} - -static void -WINAPI listenerThread_gdb( void *data) { - struct gdb_stub_state *state = (struct gdb_stub_state *)data; - fd_set read_sock_set; - fd_set main_set; - int quit = 0; - - FD_ZERO( &main_set); - - FD_SET( state->listen_fd, &main_set); - FD_SET( state->ctl_pipe[0], &main_set); - - while (!quit) { - int sel_res; - - read_sock_set = main_set; - - //DEBUG_LOG("Waiting on sockets\n"); - - sel_res = select( FD_SETSIZE, &read_sock_set, NULL, NULL, NULL); - //DEBUG_LOG("sockets ready %d\n", sel_res); - - if ( sel_res > 0) { - - /* Is this a control message */ - if ( FD_ISSET( state->ctl_pipe[0], &read_sock_set)) { - uint8_t ctl_command; - - //DEBUG_LOG("Control message\n"); -#ifdef WIN32 - recv( state->ctl_pipe[0], (char*)&ctl_command, 1, 0); -#else - read( state->ctl_pipe[0], (char*)&ctl_command, 1); -#endif - - switch ( ctl_command) { - - case CPU_STOPPED_STUB_MESSAGE: - if ( state->active && - state->ctl_stub_state != gdb_stub_state::STOPPED_GDB_STATE) { - struct debug_out_packet *out_packet = getOutPacket(); - uint8_t *ptr = out_packet->start_ptr; - uint32_t send_size; - - /* mark the stub as stopped and send the stop packet */ - state->ctl_stub_state = gdb_stub_state::STOPPED_GDB_STATE; - state->main_stop_flag = 1; - - send_size = make_stop_packet( ptr, state->stop_type, state->stop_address); - - /*ptr[0] = 'S'; - ptr[1] = hexchars[state->stop_reason >> 4]; - ptr[2] = hexchars[state->stop_reason & 0xf];*/ - - putpacket( state->sock_fd, out_packet, send_size); - DEBUG_LOG( "\nBreak from Emulation\n"); - } - else { - LOG_ERROR( "Asked to stop and already stopped\n"); - } - break; - - default: - /* quit out */ - quit = 1; - break; - } - } - - else { - //struct armcpu_t *cpu = twin_states->cpus[i]; - SOCKET_TYPE arm_listener = state->listen_fd; - - /* check for a connection request */ - if ( FD_ISSET( arm_listener, &read_sock_set)) { - SOCKET_TYPE new_conn; - struct sockaddr_in gdb_addr; -#ifdef WIN32 - int addr_size = sizeof( gdb_addr); -#else - socklen_t addr_size = sizeof( gdb_addr); -#endif - - //DEBUG_LOG("listener\n"); - - /* accept the connection if we do not already have one */ - new_conn = accept( arm_listener, (struct sockaddr *)&gdb_addr, - &addr_size); - - if ( new_conn != -1) { - int close_sock = 1; - - //DEBUG_LOG("got new socket\n"); - if ( state->sock_fd == -1 && state->active) { -#ifdef WIN32 - BOOL nodelay_opt = 1; -#else - int nodelay_opt = 1; -#endif - int set_res; - - //DEBUG_LOG("new connection\n"); - - close_sock = 0; - /* make the socket NODELAY */ -#ifdef WIN32 - set_res = setsockopt( new_conn, IPPROTO_TCP, TCP_NODELAY, - (char*)&nodelay_opt, sizeof( nodelay_opt)); -#else - set_res = setsockopt( new_conn, IPPROTO_TCP, TCP_NODELAY, - &nodelay_opt, sizeof( nodelay_opt)); -#endif - - if ( set_res != 0) { - LOG_ERROR( "Failed to set NODELAY socket option \"%s\"\n", strerror( errno)); - } - - FD_SET( new_conn, &main_set); - state->sock_fd = new_conn; - } - - if ( close_sock) { - //DEBUG_LOG("closing new socket\n"); -#ifdef WIN32 - closesocket( new_conn); -#else - close( new_conn); -#endif - } - } - } - - /* handle the gdb connection */ - if ( state->sock_fd != -1 && state->active) { - SOCKET_TYPE gdb_sock = state->sock_fd; - if ( FD_ISSET( gdb_sock, &read_sock_set)) { - enum read_res_gdb read_res = readPacket_gdb( gdb_sock, &state->rx_packet); - - //DEBUG_LOG("socket read %d\n", read_res); - - switch ( read_res) { - case READ_NOT_FINISHED: - /* do nothing here */ - break; - - case READ_SOCKET_ERROR: - /* close the socket */ -#ifdef WIN32 - closesocket( gdb_sock); -#else - close( gdb_sock); -#endif - state->sock_fd = -1; - FD_CLR( gdb_sock, &main_set); - break; - - case READ_BREAK: { - /* break the running of the cpu */ - if ( state->ctl_stub_state != gdb_stub_state::STOPPED_GDB_STATE) { - /* this will cause the emulation to break the execution */ - DEBUG_LOG( "Breaking execution\n"); - - /* install the post execution function */ - state->cpu_ctrl->install_post_ex_fn( state->cpu_ctrl->data, - break_execution, - state); - } - break; - } - - case READ_COMPLETE: { - uint8_t reply; - int write_res; - int process_packet = 0; - int close_socket = 0; - struct packet_reader_gdb *packet = &state->rx_packet; - - if ( state->ctl_stub_state != gdb_stub_state::STOPPED_GDB_STATE) { - /* not ready to process packet yet, send a bad reply */ - reply = '-'; - } - else { - /* send a reply based on the checksum and if okay process the packet */ - if ( packet->read_checksum == packet->checksum) { - reply = '+'; - process_packet = 1; - } - else { - reply = '-'; - } - } - - write_res = send( gdb_sock, (char*)&reply, 1, 0); - - if ( write_res != 1) { - close_socket = 1; - } - else { - if ( processPacket_gdb( gdb_sock, state->rx_packet.buffer, - state) == -1) { - close_socket = 1; - } - } - - if ( close_socket) { -#ifdef WIN32 - closesocket( gdb_sock); -#else - close( gdb_sock); -#endif - state->sock_fd = -1; - FD_CLR( gdb_sock, &main_set); - } - break; - } - } - } - } - } - } - } - - - /* tidy up and leave */ - if ( state->sock_fd != -1) { -#ifdef WIN32 - closesocket( state->sock_fd); -#else - close( state->sock_fd); -#endif - } - - /* close the listenering sockets */ -#ifdef WIN32 - closesocket( state->listen_fd); -#else - close( state->listen_fd); -#endif - - return; -} - - - - -/* - * - * The memory interface - * - */ -static uint32_t FASTCALL -gdb_prefetch32( void *data, uint32_t adr) { - struct gdb_stub_state *stub = (struct gdb_stub_state *)data; - uint32_t value = 0; - int breakpoint; - - breakpoint = check_breaks_gdb( stub, stub->instr_breakpoints, adr, 4, - STOP_BREAKPOINT); - - if ( !breakpoint) { - /* pass down to the real memory interace */ - value = stub->real_cpu_memio->prefetch32( stub->real_cpu_memio->data, - adr); - } - - return value; -} -static uint16_t FASTCALL -gdb_prefetch16( void *data, uint32_t adr) { - struct gdb_stub_state *stub = (struct gdb_stub_state *)data; - uint16_t value = 0; - int breakpoint; - - breakpoint = check_breaks_gdb( stub, stub->instr_breakpoints, adr, 2, - STOP_BREAKPOINT); - - if ( !breakpoint) { - /* pass down to the real memory interace */ - value = stub->real_cpu_memio->prefetch16( stub->real_cpu_memio->data, - adr); - } - - return value; -} - -/** read 8 bit data value */ -static uint8_t FASTCALL -gdb_read8( void *data, uint32_t adr) { - struct gdb_stub_state *stub = (struct gdb_stub_state *)data; - uint8_t value = 0; - int breakpoint; - - /* pass down to the real memory interace */ - value = stub->real_cpu_memio->read8( stub->real_cpu_memio->data, - adr); - - breakpoint = check_breaks_gdb( stub, stub->read_breakpoints, adr, 1, - STOP_RWATCHPOINT); - if ( !breakpoint) - check_breaks_gdb( stub, stub->access_breakpoints, adr, 1, - STOP_AWATCHPOINT); - - return value; -} - -/** read 16 bit data value */ -static uint16_t FASTCALL -gdb_read16( void *data, uint32_t adr) { - struct gdb_stub_state *stub = (struct gdb_stub_state *)data; - uint16_t value; - int breakpoint; - - /* pass down to the real memory interace */ - value = stub->real_cpu_memio->read16( stub->real_cpu_memio->data, - adr); - - breakpoint = check_breaks_gdb( stub, stub->read_breakpoints, adr, 2, - STOP_RWATCHPOINT); - if ( !breakpoint) - check_breaks_gdb( stub, stub->access_breakpoints, adr, 2, - STOP_AWATCHPOINT); - - return value; -} -/** read 32 bit data value */ -static uint32_t FASTCALL -gdb_read32( void *data, uint32_t adr) { - struct gdb_stub_state *stub = (struct gdb_stub_state *)data; - uint32_t value; - int breakpoint; - - /* pass down to the real memory interace */ - value = stub->real_cpu_memio->read32( stub->real_cpu_memio->data, - adr); - - breakpoint = check_breaks_gdb( stub, stub->read_breakpoints, adr, 4, - STOP_RWATCHPOINT); - if ( !breakpoint) - check_breaks_gdb( stub, stub->access_breakpoints, adr, 4, - STOP_AWATCHPOINT); - - return value; -} - -/** write 8 bit data value */ -static void FASTCALL -gdb_write8( void *data, uint32_t adr, uint8_t val) { - struct gdb_stub_state *stub = (struct gdb_stub_state *)data; - int breakpoint; - - /* pass down to the real memory interace */ - stub->real_cpu_memio->write8( stub->real_cpu_memio->data, - adr, val); - - breakpoint = check_breaks_gdb( stub, stub->write_breakpoints, adr, 1, - STOP_WATCHPOINT); - if ( !breakpoint) - check_breaks_gdb( stub, stub->access_breakpoints, adr, 1, - STOP_AWATCHPOINT); -} - -/** write 16 bit data value */ -static void FASTCALL -gdb_write16( void *data, uint32_t adr, uint16_t val) { - struct gdb_stub_state *stub = (struct gdb_stub_state *)data; - int breakpoint; - - /* pass down to the real memory interace */ - stub->real_cpu_memio->write16( stub->real_cpu_memio->data, - adr, val); - - breakpoint = check_breaks_gdb( stub, stub->write_breakpoints, adr, 2, - STOP_WATCHPOINT); - if ( !breakpoint) - check_breaks_gdb( stub, stub->access_breakpoints, adr, 2, - STOP_AWATCHPOINT); -} - -/** write 32 bit data value */ -static void FASTCALL -gdb_write32( void *data, uint32_t adr, uint32_t val) { - struct gdb_stub_state *stub = (struct gdb_stub_state *)data; - int breakpoint; - - /* pass down to the real memory interace */ - stub->real_cpu_memio->write32( stub->real_cpu_memio->data, - adr, val); - - breakpoint = check_breaks_gdb( stub, stub->write_breakpoints, adr, 4, - STOP_WATCHPOINT); - if ( !breakpoint) - check_breaks_gdb( stub, stub->access_breakpoints, adr, 4, - STOP_AWATCHPOINT); -} - - - - - - - -#ifdef WIN32 -struct socket_creator_data { - SOCKET_TYPE *sock; - int port_num; -}; -/** - */ -static DWORD WINAPI -control_creator( LPVOID lpParameter) -{ - struct socket_creator_data *my_data = (struct socket_creator_data *)lpParameter; - - *my_data->sock = socket( PF_INET, SOCK_STREAM, 0); - - if ( *my_data->sock != INVALID_SOCKET) { - int connect_res; - struct sockaddr_in clientService; - - clientService.sin_family = AF_INET; - clientService.sin_addr.s_addr = inet_addr( "127.0.0.1" ); - clientService.sin_port = htons( my_data->port_num); - - connect_res = connect( *my_data->sock, (SOCKADDR*) &clientService, sizeof(clientService)); - - if ( connect_res == SOCKET_ERROR) { - LOG_ERROR( "Failed to connect to socket\n"); - } - } - - return 0; -} - -#endif - - - -/** - */ -gdbstub_handle_t -createStub_gdb( uint16_t port, - struct armcpu_memory_iface **cpu_memio, - struct armcpu_memory_iface *direct_memio) { - struct gdb_stub_state *stub; - gdbstub_handle_t handle = NULL; - int i; - int res = 0; - - stub = (gdb_stub_state*)malloc( sizeof (struct gdb_stub_state)); - if ( stub == NULL) { - return NULL; - } - - stub->active = 0; - - /* keep the memory interfaces */ - stub->real_cpu_memio = *cpu_memio; - stub->direct_memio = direct_memio; - - *cpu_memio = &stub->cpu_memio; - - /* fill in the memory interface */ - stub->cpu_memio.data = stub; - stub->cpu_memio.prefetch32 = gdb_prefetch32; - stub->cpu_memio.prefetch16 = gdb_prefetch16; - - stub->cpu_memio.read8 = gdb_read8; - stub->cpu_memio.read16 = gdb_read16; - stub->cpu_memio.read32 = gdb_read32; - - stub->cpu_memio.write8 = gdb_write8; - stub->cpu_memio.write16 = gdb_write16; - stub->cpu_memio.write32 = gdb_write32; - - - - /* put the breakpoint descriptors onto the free list */ - for ( i = 0; i < BREAKPOINT_POOL_SIZE - 1; i++) { - stub->breakpoint_pool[i].next = &stub->breakpoint_pool[i+1]; - } - stub->breakpoint_pool[i].next = NULL; - stub->free_breakpoints = &stub->breakpoint_pool[0]; - stub->instr_breakpoints = NULL; - - stub->read_breakpoints = NULL; - stub->write_breakpoints = NULL; - stub->access_breakpoints = NULL; - -#ifdef WIN32 - /* initialise the winsock library */ - { - WORD wVersionRequested; - WSADATA wsaData; - int err; - - wVersionRequested = MAKEWORD( 2, 2 ); - - err = WSAStartup( wVersionRequested, &wsaData ); - if ( err != 0 ) { - return NULL; - } - } - - { - struct socket_creator_data temp_data = { - &stub->ctl_pipe[0], - 24689 - }; - SOCKET_TYPE temp_sock = createSocket ( temp_data.port_num); - HANDLE temp_thread = INVALID_HANDLE_VALUE; - DWORD temp_threadID; - - res = -1; - - if ( temp_sock != -1) { - /* create a thread to connect to this socket */ - temp_thread = CreateThread( NULL, 0, control_creator, &temp_data, 0, &temp_threadID); - if ( temp_thread != INVALID_HANDLE_VALUE) { - struct sockaddr_in ignore_addr; - int addr_size = sizeof( ignore_addr); - - stub->ctl_pipe[1] = accept( temp_sock, (struct sockaddr *)&ignore_addr, &addr_size); - - if ( stub->ctl_pipe[1] != INVALID_SOCKET) { - BOOL nodelay_opt = 1; - int set_res; - - /* make the socket NODELAY */ - set_res = setsockopt( stub->ctl_pipe[1], IPPROTO_TCP, TCP_NODELAY, - (char*)&nodelay_opt, sizeof( nodelay_opt)); - if ( set_res == 0) { - closesocket( temp_sock); - res = 0; - } - } - } - } - } - - if ( res != 0) { - LOG_ERROR( "Failed to create control socket\n"); - } -#else - /* create the control pipe */ - res = pipe( stub->ctl_pipe); - - if ( res != 0) { - LOG_ERROR( "Failed to create control pipe \"%s\"\n", strerror( errno)); - } -#endif - else { - stub->active = 1; - stub->emu_stub_state = gdb_stub_state::RUNNING_EMU_GDB_STATE; - stub->ctl_stub_state = gdb_stub_state::STOPPED_GDB_STATE; - stub->rx_packet.state = IDLE_READ_STATE; - - stub->main_stop_flag = 1; - - stub->port_num = port; - stub->sock_fd = -1; - stub->listen_fd = createSocket( port); - - stub->stop_type = STOP_UNKNOWN; - - if ( stub->listen_fd == -1) { - LOG_ERROR( "Failed to create listening socket \"%s\"\n", strerror( errno)); - res = -1; - } - } - - if ( res != -1) { - /* create the listenering thread */ - stub->thread = createThread_gdb( listenerThread_gdb, stub); - - if ( stub->thread == NULL) { - LOG_ERROR("Failed to create listener thread\n"); - free( stub); - } - else { - handle = stub; - - DEBUG_LOG("Created stub on port %d\n", port); - } - } - else { - free( stub); - } - - return handle; -} - - -void -destroyStub_gdb( gdbstub_handle_t instance) { - struct gdb_stub_state *stub = (struct gdb_stub_state *)instance; - - causeQuit_gdb( stub); - - joinThread_gdb( stub->thread); - - //stub->cpu_ctl->unstall( stub->cpu_ctl->data); - //stub->cpu_ctl->remove_post_ex_fn( stub->cpu_ctl->data); - - free( stub); -} - -void -activateStub_gdb( gdbstub_handle_t instance, - struct armcpu_ctrl_iface *cpu_ctrl) { - struct gdb_stub_state *stub = (struct gdb_stub_state *)instance; - - stub->cpu_ctrl = cpu_ctrl; - - /* stall the cpu */ - stub->cpu_ctrl->stall( stub->cpu_ctrl->data); - - stub->active = 1; -} +/* $Id: gdbstub.c,v 1.1 2007-06-07 09:43:25 masscat Exp $ + */ +/* + * THE SOFTWARE WITHIN THIS FILE IS NOT COPYRIGHTED + * + * Originally written by Ben Jaques. + * + * The software is offered for use in the public domain in the hope that + * it will be useful, but WITHOUT ANY WARRANTY; without even the implied + * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + */ +#include +//#include +#include +#include + +#include + +#ifdef WIN32 +#include +#else +#include +#include +#include +#include +#include +#endif + +#include "armcpu.h" + +#define uint32_t u32 +#define uint16_t u16 +#define uint8_t u8 + +#include "gdbstub.h" +#include "gdbstub_internal.h" + +#ifdef __GNUC__ +#define UNUSED_PARM( parm) parm __attribute__((unused)) +#else +#define UNUSED_PARM( parm) parm +#endif + +#if 0 +#define DEBUG_LOG( fmt, ...) fprintf(stdout, fmt, ##__VA_ARGS__) +#else +#define DEBUG_LOG( fmt, ...) +#endif + +#if 0 +#define LOG_ERROR( fmt, ...) fprintf(stderr, fmt, ##__VA_ARGS__) +#else +#define LOG_ERROR( fmt, ...) +#endif + +#define LITTLE_ENDIAN_TO_UINT32_T( v) (\ + ((v)[3] << 24) | \ + ((v)[2] << 16) | \ + ((v)[1] << 8) | \ + ((v)[0] << 0)) + +/* + * The state of the packet reader + */ +#define IDLE_READ_STATE 0 +#define MID_PACKET_READ_STATE 1 +#define FIRST_CHECKSUM_READ_STATE 2 +#define SECOND_CHECKSUM_READ_STATE 3 + +/* + * The gdb stub thread control message types. + */ +enum stub_message_type { + /** The quit message type */ + QUIT_STUB_MESSAGE = 0, + /** The emulated CPU has stopped */ + CPU_STOPPED_STUB_MESSAGE = 1 +}; + + +/* + * The GDB signal values + */ +enum target_signal + { + /* Used some places (e.g. stop_signal) to record the concept that + there is no signal. */ + TARGET_SIGNAL_0 = 0, + TARGET_SIGNAL_FIRST = 0, + TARGET_SIGNAL_HUP = 1, + TARGET_SIGNAL_INT = 2, + TARGET_SIGNAL_QUIT = 3, + TARGET_SIGNAL_ILL = 4, + TARGET_SIGNAL_TRAP = 5, + TARGET_SIGNAL_ABRT = 6, + TARGET_SIGNAL_EMT = 7, + TARGET_SIGNAL_FPE = 8, + TARGET_SIGNAL_KILL = 9, + TARGET_SIGNAL_BUS = 10, + TARGET_SIGNAL_SEGV = 11, + TARGET_SIGNAL_SYS = 12, + TARGET_SIGNAL_PIPE = 13, + TARGET_SIGNAL_ALRM = 14, + TARGET_SIGNAL_TERM = 15, + TARGET_SIGNAL_URG = 16, + TARGET_SIGNAL_STOP = 17, + TARGET_SIGNAL_TSTP = 18, + TARGET_SIGNAL_CONT = 19, + TARGET_SIGNAL_CHLD = 20, + TARGET_SIGNAL_TTIN = 21, + TARGET_SIGNAL_TTOU = 22, + TARGET_SIGNAL_IO = 23, + TARGET_SIGNAL_XCPU = 24, + TARGET_SIGNAL_XFSZ = 25, + TARGET_SIGNAL_VTALRM = 26, + TARGET_SIGNAL_PROF = 27, + TARGET_SIGNAL_WINCH = 28, + TARGET_SIGNAL_LOST = 29, + TARGET_SIGNAL_USR1 = 30, + TARGET_SIGNAL_USR2 = 31, + TARGET_SIGNAL_PWR = 32, + /* Similar to SIGIO. Perhaps they should have the same number. */ + TARGET_SIGNAL_POLL = 33, + TARGET_SIGNAL_WIND = 34, + TARGET_SIGNAL_PHONE = 35, + TARGET_SIGNAL_WAITING = 36, + TARGET_SIGNAL_LWP = 37, + TARGET_SIGNAL_DANGER = 38, + TARGET_SIGNAL_GRANT = 39, + TARGET_SIGNAL_RETRACT = 40, + TARGET_SIGNAL_MSG = 41, + TARGET_SIGNAL_SOUND = 42, + TARGET_SIGNAL_SAK = 43, + TARGET_SIGNAL_PRIO = 44, + }; + + + + + +static void +causeQuit_gdb( struct gdb_stub_state *stub) { + uint8_t command = QUIT_STUB_MESSAGE; + +#ifdef WIN32 + send( stub->ctl_pipe[1], (char*)&command, 1, 0); +#else + write( stub->ctl_pipe[1], &command, 1); +#endif +} + +static void +indicateCPUStop_gdb( struct gdb_stub_state *stub) { + uint8_t command = CPU_STOPPED_STUB_MESSAGE; + +#ifdef WIN32 + send( stub->ctl_pipe[1], (char*)&command, 1, 0); +#else + write( stub->ctl_pipe[1], &command, 1); +#endif +} + + + + +/* + * + * + * + */ +static void +break_execution( void *data, UNUSED_PARM(uint32_t addr), UNUSED_PARM(int thunmb)) { + struct gdb_stub_state *stub = (struct gdb_stub_state *)data; + + /* stall the processor */ + stub->cpu_ctrl->stall( stub->cpu_ctrl->data); + + /* remove the post execution function */ + stub->cpu_ctrl->remove_post_ex_fn( stub->cpu_ctrl->data); + + /* indicate the halt */ + stub->stop_type = STOP_HOST_BREAK; + indicateCPUStop_gdb( stub); +} + + +static void +step_instruction_watch( void *data, uint32_t addr, UNUSED_PARM(int thunmb)) { + struct gdb_stub_state *stub = (struct gdb_stub_state *)data; + + DEBUG_LOG("Step watch: waiting for %08x at %08x\n", stub->step_instr_address, + addr); + + if ( addr == stub->step_instr_address) { + DEBUG_LOG("Step hit -> %08x\n", stub->cpu_ctrl->read_reg( stub->cpu_ctrl->data, 15)); + /* stall the processor */ + stub->cpu_ctrl->stall( stub->cpu_ctrl->data); + + /* remove the post execution function */ + stub->cpu_ctrl->remove_post_ex_fn( stub->cpu_ctrl->data); + + /* indicate the halt */ + stub->stop_type = STOP_STEP_BREAK; + indicateCPUStop_gdb( stub); + } +} + + + + + +/************************************************************************/ +/* BUFMAX defines the maximum number of characters in inbound/outbound buffers*/ +/* at least NUMREGBYTES*2 are needed for register packets */ +#define BUFMAX 2048 + + + +static const char hexchars[]="0123456789abcdef"; + +/* + * Convert ch from a hex digit to an int + */ +static int +hex (unsigned char ch) { + if (ch >= 'a' && ch <= 'f') + return ch-'a'+10; + if (ch >= '0' && ch <= '9') + return ch-'0'; + if (ch >= 'A' && ch <= 'F') + return ch-'A'+10; + return -1; +} + +static const unsigned char * +hex2mem ( const unsigned char *buf, uint8_t *mem, int count) { + int i; + unsigned char ch; + + for (i=0; i 0) + { + ch = memio->read8( memio->data, mem_addr++); + *buf++ = hexchars[ch >> 4]; + *buf++ = hexchars[ch & 0xf]; + } + + *buf = 0; + + return buf; +} + + + +static enum read_res_gdb +readPacket_gdb( SOCKET_TYPE sock, struct packet_reader_gdb *packet) { + uint8_t cur_byte; + enum read_res_gdb read_res = READ_NOT_FINISHED; + int sock_res; + + /* update the state */ + + while ( (sock_res = recv( sock, (char*)&cur_byte, 1, 0)) == 1) { + switch ( packet->state) { + case IDLE_READ_STATE: + /* wait for the '$' start of packet character + */ + if ( cur_byte == '$') { + //DEBUG_LOG( "Found packet\n"); + packet->state = MID_PACKET_READ_STATE; + packet->pos_index = 0; + packet->checksum = 0; + } + /* Is this the break command */ + else if ( cur_byte == 3) { + //DEBUG_LOG( "GDB has sent a break\n"); + packet->buffer[0] = cur_byte; + packet->buffer[1] = 0; + packet->pos_index = 1; + return READ_BREAK; + } + break; + + case MID_PACKET_READ_STATE: + if ( cur_byte == '#') { + //DEBUG_LOG( "\nAbout to get checksum\n"); + packet->buffer[packet->pos_index] = '\0'; + packet->state = FIRST_CHECKSUM_READ_STATE; + } + else if ( packet->pos_index >= BUFMAX - 1) { + //DEBUG_LOG( "read buffer exceeded\n"); + packet->state = IDLE_READ_STATE; + } + else { + //DEBUG_LOG( "%c", cur_byte); + packet->checksum = packet->checksum + cur_byte; + packet->buffer[packet->pos_index] = cur_byte; + packet->pos_index = packet->pos_index + 1; + } + break; + + case FIRST_CHECKSUM_READ_STATE: + packet->read_checksum = hex( cur_byte) << 4; + packet->state = SECOND_CHECKSUM_READ_STATE; + break; + + case SECOND_CHECKSUM_READ_STATE: { + packet->read_checksum += hex( cur_byte); + packet->state = IDLE_READ_STATE; + return READ_COMPLETE; + break; + } + } + } + + if ( sock_res == 0) { + read_res = READ_SOCKET_ERROR; + } + else if ( sock_res == -1) { + if ( errno != EAGAIN) { + read_res = READ_SOCKET_ERROR; + } + } + + return read_res; +} + + +struct hidden_debug_out_packet { + unsigned char *start_ptr; +}; +struct debug_out_packet { + unsigned char *const start_ptr; +}; + +static struct hidden_debug_out_packet the_out_packet; +static unsigned char hidden_buffer[BUFMAX]; + + +static struct debug_out_packet * +getOutPacket( void) { + the_out_packet.start_ptr = &hidden_buffer[1]; + return (struct debug_out_packet *)&the_out_packet; +} + +#define CHECKSUM_PART_SIZE 3 +/** + * send the packet in buffer. + */ +static int +putpacket ( SOCKET_TYPE sock, struct debug_out_packet *out_packet, uint32_t size) { + unsigned char checksum = 0; + uint32_t count; + unsigned char *ch_ptr = (unsigned char *)&out_packet->start_ptr[-1]; + uint8_t reply_ch; + + //DEBUG_LOG_START( "Putting packet size %d ", size); + /* add the '$' to the start of the packet */ + *ch_ptr++ = '$'; + + /* calculate and add the checksum to the packet */ + for ( count = 0; count < size; count += 1) { + checksum += ch_ptr[count]; + //DEBUG_LOG_PART("%c", ch_ptr[count]); + } + //DEBUG_LOG_PART("\n"); + + ch_ptr[count++] = '#'; + ch_ptr[count++] = hexchars[checksum >> 4]; + ch_ptr[count++] = hexchars[checksum & 0xf]; + ch_ptr[count] = '\0'; + //DEBUG_LOG("packet %s\n", &out_packet->start_ptr[-1]); + + /* add one for the '$' character */ + count += 1; + + do { + int reply_found = 0; + + send( sock, (char*)&out_packet->start_ptr[-1], count, 0); + + do { + int read_res = recv( sock, (char*)&reply_ch, 1, 0); + + if ( read_res == 0) { + return -1; + } + else if ( read_res == -1) { + if ( errno != EAGAIN) { + return -1; + } + } + else { + reply_found = 1; + } + } while ( !reply_found); + } while ( reply_ch != '+'); + + /* $#. */ + return count - 4; +} + + + +static uint32_t +make_stop_packet( uint8_t *ptr, enum stop_type type, uint32_t stop_address) { + uint32_t stop_size = 0; + int watch_index = 0; + const char watch_chars[] = { 'a', 'r' }; + + switch (type) { + case STOP_UNKNOWN: + case STOP_HOST_BREAK: + ptr[0] = 'S'; + ptr[1] = hexchars[TARGET_SIGNAL_INT >> 4]; + ptr[2] = hexchars[TARGET_SIGNAL_INT & 0xf]; + stop_size = 3; + break; + + case STOP_STEP_BREAK: + case STOP_BREAKPOINT: + ptr[0] = 'S'; + ptr[1] = hexchars[TARGET_SIGNAL_TRAP >> 4]; + ptr[2] = hexchars[TARGET_SIGNAL_TRAP & 0xf]; + stop_size = 3; + break; + + case STOP_WATCHPOINT: + watch_index = 1; + case STOP_RWATCHPOINT: + watch_index += 1; + case STOP_AWATCHPOINT: + { + int i; + int out_index = 0; + ptr[out_index++] = 'T'; + ptr[out_index++] = hexchars[TARGET_SIGNAL_ABRT >> 4]; + ptr[out_index++] = hexchars[TARGET_SIGNAL_ABRT & 0xf]; + + if ( watch_index < 2) { + ptr[out_index++] = watch_chars[watch_index]; + } + ptr[out_index++] = 'w'; + ptr[out_index++] = 'a'; + ptr[out_index++] = 't'; + ptr[out_index++] = 'c'; + ptr[out_index++] = 'h'; + ptr[out_index++] = ':'; + + for ( i = 0; i < 8; i++) { + ptr[out_index++] = hexchars[(stop_address >> (i * 4)) & 0xf]; + } + ptr[out_index++] = ';'; + + stop_size = out_index; + } + break; + } + + return stop_size; +} + +/** + * Returns -1 if there is a socket error. + */ +static int +processPacket_gdb( SOCKET_TYPE sock, const uint8_t *packet, + struct gdb_stub_state *stub) { + // uint8_t remcomOutBuffer[BUFMAX_GDB]; + struct debug_out_packet *out_packet = getOutPacket(); + uint8_t *out_ptr = out_packet->start_ptr; + int send_reply = 1; + uint32_t send_size = 0; + + DEBUG_LOG("Processing packet %c\n", packet[0]); + + switch( packet[0]) { + case 3: + /* The break command */ + //stub->running_state = gdb_stub_state::STOPPED_GDB_STATE; + //*ptr++ = 'S'; + //*ptr++ = hexchars[0x2 >> 4]; + //*ptr++ = hexchars[0x2 & 0xf]; + //*ptr++ = 0; + send_reply = 0; + break; + + case '?': + send_size = make_stop_packet( out_ptr, stub->stop_type, stub->stop_address); + /**ptr++ = 'S'; + *ptr++ = hexchars[stub->stop_reason >> 4]; + *ptr++ = hexchars[stub->stop_reason & 0xf]; + send_size = 3;*/ + break; + + case 'c': + stub->emu_stub_state = gdb_stub_state::RUNNING_EMU_GDB_STATE; + stub->ctl_stub_state = gdb_stub_state::START_RUN_GDB_STATE; + stub->main_stop_flag = 0; + send_reply = 0; + /* remove the cpu stall */ + stub->cpu_ctrl->unstall( stub->cpu_ctrl->data); + break; + + case 's': { + uint32_t instr_addr = stub->cpu_ctrl->read_reg( stub->cpu_ctrl->data, 15); + /* Determine where the next instruction will take the CPU. + * Execute the instruction using a copy of the CPU with a zero memory interface. + */ + DEBUG_LOG( "Stepping instruction at %08x\n", instr_addr); + + /* install the post execution function */ + stub->step_instr_address = instr_addr; + stub->cpu_ctrl->install_post_ex_fn( stub->cpu_ctrl->data, + step_instruction_watch, + stub); + + + stub->emu_stub_state = gdb_stub_state::RUNNING_EMU_GDB_STATE; + stub->ctl_stub_state = gdb_stub_state::START_RUN_GDB_STATE; + stub->main_stop_flag = 0; + send_reply = 0; + + /* remove the cpu stall */ + stub->cpu_ctrl->unstall( stub->cpu_ctrl->data); + break; + } + + /* + * Register set + */ + case 'P': { + uint32_t reg; + uint32_t value; + const uint8_t *rx_ptr = &packet[1]; + + DEBUG_LOG("Processing packet %s\n", packet); + if ( hexToInt( &rx_ptr, ®)) { + if ( *rx_ptr++ == '=') { + uint8_t tmp_mem[4]; + + rx_ptr = hex2mem( rx_ptr, tmp_mem, 4); + value = LITTLE_ENDIAN_TO_UINT32_T( tmp_mem); + DEBUG_LOG("Setting reg %d to %08x\n", reg, value); + if ( reg < 16) + stub->cpu_ctrl->set_reg( stub->cpu_ctrl->data, reg, value); + if ( reg == 25) { + stub->cpu_ctrl->set_reg( stub->cpu_ctrl->data, 16, value); + } + + strcpy( (char *)out_ptr, "OK"); + send_size = 2; + } + } + break; + } + + case 'm': { + uint32_t addr = 0; + uint32_t length = 0; + int error01 = 1; + const uint8_t *rx_ptr = &packet[1]; + + if ( hexToInt( &rx_ptr, &addr)) { + if ( *rx_ptr++ == ',') { + if ( hexToInt( &rx_ptr, &length)) { + //DEBUG_LOG("mem read from %08x (%d)\n", addr, length); + if ( !mem2hex( stub->direct_memio, addr, out_ptr, length)) { + strcpy ( (char *)out_ptr, "E03"); + send_size = 3; + } + else { + send_size = length * 2; + } + error01 = 0; + } + } + } + if ( error01) + strcpy( (char *)out_ptr,"E01"); + break; + } + + /* MAA..AA,LLLL: Write LLLL bytes at address AA.AA return OK */ + case 'M': { + /* Try to read '%x,%x:'. */ + const uint8_t *rx_ptr = &packet[1]; + uint32_t addr = 0; + uint32_t length = 0; + int error01 = 1; + DEBUG_LOG("Memory write %s\n", rx_ptr); + if ( hexToInt(&rx_ptr, &addr)) { + if ( *rx_ptr++ == ',') { + if ( hexToInt(&rx_ptr, &length)) { + if ( *rx_ptr++ == ':') { + uint8_t write_byte; + unsigned int i; + DEBUG_LOG("Memory write of %d bytes to %08x\n", + length, addr); + + for ( i = 0; i < length; i++) { + rx_ptr = hex2mem( rx_ptr, &write_byte, 1); + + stub->direct_memio->write8( stub->direct_memio->data, + addr++, write_byte); + } + + strcpy( (char *)out_ptr, "OK"); + error01 = 0; + } + } + else { + DEBUG_LOG("Failed to find length (addr %08x)\n", addr); + } + } + else { + DEBUG_LOG("expected ',' got '%c' (addr = %08x)\n", *rx_ptr, addr); + } + } + else { + DEBUG_LOG("Failed to find addr\n"); + } + + if ( error01) { + strcpy( (char *)out_ptr, "E02"); + } + break; + } + + case 'Z': + case 'z': { + const uint8_t *rx_ptr = &packet[2]; + int remove_flag = 0; + + if ( packet[0] == 'z') + remove_flag = 1; + + DEBUG_LOG( "%c%c packet %s (remove? %d)\n", packet[0], packet[1], + rx_ptr, remove_flag); + + switch ( packet[1]) { + + /* all instruction breakpoints are treated the same */ + case '0': + case '1': + case '2': + case '3': + case '4': + { + uint32_t addr = 0; + uint32_t length = 0; + int error01 = 1; + struct breakpoint_gdb **bpoint_list; + + switch ( packet[1]) { + case '0': + case '1': + bpoint_list = &stub->instr_breakpoints; + break; + + case '2': + bpoint_list = &stub->write_breakpoints; + break; + + case '3': + bpoint_list = &stub->read_breakpoints; + break; + + case '4': + bpoint_list = &stub->access_breakpoints; + break; + } + + if ( *rx_ptr++ == ',') { + DEBUG_LOG("%s\n", rx_ptr); + + if ( hexToInt( &rx_ptr, &addr)) { + if ( *rx_ptr++ == ',') { + DEBUG_LOG("addr %08x %s\n", addr, rx_ptr); + + if ( hexToInt( &rx_ptr, &length)) { + if ( remove_flag) { + int removed = 0; + struct breakpoint_gdb *last_bpoint = NULL; + struct breakpoint_gdb *bpoint = *bpoint_list; + + while ( bpoint != NULL && !removed) { + if ( bpoint->addr == addr) { + DEBUG_LOG("Breakpoint(%c) at %08x removed\n", packet[1], addr); + removed = 1; + + if ( last_bpoint == NULL) { + *bpoint_list = bpoint->next; + } + else { + last_bpoint->next = bpoint->next; + } + bpoint->next = stub->free_breakpoints; + stub->free_breakpoints = bpoint; + } + last_bpoint = bpoint; + bpoint = bpoint->next; + } + + strcpy( (char *)out_ptr, "OK"); + send_size = 2; + error01 = 0; + } + else { + /* get a breakpoint descriptor from the free pool and add it to + * the current stub instruction breakpoint list */ + struct breakpoint_gdb *bpoint = stub->free_breakpoints; + + if ( bpoint != NULL) { + DEBUG_LOG( "Breakpoint(%c) added at %08x length %d\n", + packet[1], addr, length); + stub->free_breakpoints = bpoint->next; + + bpoint->addr = addr; + bpoint->size = length; + + bpoint->next = *bpoint_list; + *bpoint_list = bpoint; + + strcpy( (char *)out_ptr, "OK"); + send_size = 2; + error01 = 0; + } + } + } + } + } + } + + if ( error01) { + strcpy( (char *)out_ptr, "E01"); + send_size = 3; + } + } + break; + + default: + break; + } + break; + } + + /* + * Set the register values + */ + case 'G': + { + int i; + const uint8_t *rx_ptr = &packet[1]; + uint32_t reg_values[16]; + uint32_t cpsr; + uint8_t tmp_mem[4]; + DEBUG_LOG("'G' command %s\n", rx_ptr); + + /* general purpose regs 0 to 15 */ + for ( i = 0; i < 16; i++) { + rx_ptr = hex2mem( rx_ptr, tmp_mem, 4); + + reg_values[i] = LITTLE_ENDIAN_TO_UINT32_T( tmp_mem); + DEBUG_LOG("Setting reg %d to %08x\n", i, reg_values[i]); + } + + /* skip the floaing point registers and floating point status register */ + rx_ptr += 8 * (96 / 8 * 2); + rx_ptr += 8; + + /* the CPSR register is last */ + rx_ptr = hex2mem( rx_ptr, tmp_mem, 4); + cpsr = LITTLE_ENDIAN_TO_UINT32_T( tmp_mem); + DEBUG_LOG("Setting cpsr to %08x\n", cpsr); + + strcpy( (char *)out_ptr, "OK"); + send_size = 2; + break; + } + + case 'g': /* return the value of the CPU registers */ + { + int i; + int out_index = 0; + uint32_t pc_value = stub->cpu_ctrl->read_reg( stub->cpu_ctrl->data, 15); + uint32_t cpsr_value = stub->cpu_ctrl->read_reg( stub->cpu_ctrl->data, 16); + + DEBUG_LOG("'g' command PC = %08x\n", pc_value); + + /* general purpose regs 0 to 14 */ + for ( i = 0; i < 15; i++) { + uint32_t reg = stub->cpu_ctrl->read_reg( stub->cpu_ctrl->data, i); + out_ptr[out_index++] = hexchars[(reg >> 4) & 0xf]; + out_ptr[out_index++] = hexchars[(reg >> 0) & 0xf]; + out_ptr[out_index++] = hexchars[(reg >> 12) & 0xf]; + out_ptr[out_index++] = hexchars[(reg >> 8) & 0xf]; + out_ptr[out_index++] = hexchars[(reg >> 20) & 0xf]; + out_ptr[out_index++] = hexchars[(reg >> 16) & 0xf]; + out_ptr[out_index++] = hexchars[(reg >> 28) & 0xf]; + out_ptr[out_index++] = hexchars[(reg >> 24) & 0xf]; + } + + out_ptr[out_index++] = hexchars[(pc_value >> 4) & 0xf]; + out_ptr[out_index++] = hexchars[(pc_value >> 0) & 0xf]; + out_ptr[out_index++] = hexchars[(pc_value >> 12) & 0xf]; + out_ptr[out_index++] = hexchars[(pc_value >> 8) & 0xf]; + out_ptr[out_index++] = hexchars[(pc_value >> 20) & 0xf]; + out_ptr[out_index++] = hexchars[(pc_value >> 16) & 0xf]; + out_ptr[out_index++] = hexchars[(pc_value >> 28) & 0xf]; + out_ptr[out_index++] = hexchars[(pc_value >> 24) & 0xf]; + + /* floating point registers (8 96bit) */ + for ( i = 0; i < 8; i++) { + int j; + for ( j = 0; j < (96/4); j++) { + out_ptr[out_index++] = '0'; + } + } + + /* floating point status register? */ + for ( i = 0; i < 1; i++) { + int j; + for ( j = 0; j < 8; j++) { + out_ptr[out_index++] = '0'; + } + } + + /* The CPSR */ + for ( i = 0; i < 1; i++) { + out_ptr[out_index++] = hexchars[(cpsr_value >> 4) & 0xf]; + out_ptr[out_index++] = hexchars[(cpsr_value >> 0) & 0xf]; + out_ptr[out_index++] = hexchars[(cpsr_value >> 12) & 0xf]; + out_ptr[out_index++] = hexchars[(cpsr_value >> 8) & 0xf]; + out_ptr[out_index++] = hexchars[(cpsr_value >> 20) & 0xf]; + out_ptr[out_index++] = hexchars[(cpsr_value >> 16) & 0xf]; + out_ptr[out_index++] = hexchars[(cpsr_value >> 28) & 0xf]; + out_ptr[out_index++] = hexchars[(cpsr_value >> 24) & 0xf]; + } + send_size = out_index; + } + break; + } + + if ( send_reply) { + return putpacket( sock, out_packet, send_size); + } + + return 0; +} + + + +/** + * create the listening socket + */ +static SOCKET_TYPE +createSocket ( int port) { + SOCKET_TYPE sock; + struct sockaddr_in bind_addr; + + memset (&bind_addr, 0, sizeof (bind_addr)); + bind_addr.sin_family = AF_INET; + bind_addr.sin_port = htons( port); + bind_addr.sin_addr.s_addr = htonl (INADDR_ANY); + + /* create the socket, bind the address */ + + sock = socket (PF_INET, SOCK_STREAM, 0); + +#ifdef WIN32 + if ( sock != INVALID_SOCKET) +#else + if (sock != -1) +#endif + { + if (bind (sock, (struct sockaddr *) &bind_addr, + sizeof (bind_addr)) == -1) { + LOG_ERROR("Bind failed \"%s\" port %d\n", strerror( errno), port); +#ifdef WIN32 + closesocket( sock); +#else + close (sock); +#endif + sock = -1; + } + else if (listen (sock, 5) == -1) { + LOG_ERROR("Listen failed \"%s\"\n", strerror( errno)); +#ifdef WIN32 + closesocket( sock); +#else + close (sock); +#endif + sock = -1; + } + } + else { +#ifdef WIN32 + char message[30]; + int error = WSAGetLastError(); + sprintf( message, "Error creating socket %d\n", error); + LOG_ERROR("Error creating socket %d\n", error); +#endif + } + + return sock; +} + + + + +/* + * Handle GDB stub connections. + */ + + +/** + */ +INLINE static int +check_breaks_gdb( struct gdb_stub_state *gdb_state, + struct breakpoint_gdb *bpoint_list, + uint32_t addr, + UNUSED_PARM(uint32_t size), + enum stop_type stop_type) { + int found_break = 0; + + if ( gdb_state->active) { + struct breakpoint_gdb *bpoint = bpoint_list; + + while ( bpoint != NULL && !found_break) { + if ( addr == bpoint->addr) { + DEBUG_LOG("Breakpoint hit at %08x\n", addr); + + /* stall the processor */ + gdb_state->cpu_ctrl->stall( gdb_state->cpu_ctrl->data); + + /* indicate the break to the GDB stub thread */ + gdb_state->stop_type = stop_type; + gdb_state->stop_address = addr; + indicateCPUStop_gdb( gdb_state); + } + bpoint = bpoint->next; + } + } + + return found_break; +} + +static void +WINAPI listenerThread_gdb( void *data) { + struct gdb_stub_state *state = (struct gdb_stub_state *)data; + fd_set read_sock_set; + fd_set main_set; + int quit = 0; + + FD_ZERO( &main_set); + + FD_SET( state->listen_fd, &main_set); + FD_SET( state->ctl_pipe[0], &main_set); + + while (!quit) { + int sel_res; + + read_sock_set = main_set; + + //DEBUG_LOG("Waiting on sockets\n"); + + sel_res = select( FD_SETSIZE, &read_sock_set, NULL, NULL, NULL); + //DEBUG_LOG("sockets ready %d\n", sel_res); + + if ( sel_res > 0) { + + /* Is this a control message */ + if ( FD_ISSET( state->ctl_pipe[0], &read_sock_set)) { + uint8_t ctl_command; + + //DEBUG_LOG("Control message\n"); +#ifdef WIN32 + recv( state->ctl_pipe[0], (char*)&ctl_command, 1, 0); +#else + read( state->ctl_pipe[0], (char*)&ctl_command, 1); +#endif + + switch ( ctl_command) { + + case CPU_STOPPED_STUB_MESSAGE: + if ( state->active && + state->ctl_stub_state != gdb_stub_state::STOPPED_GDB_STATE) { + struct debug_out_packet *out_packet = getOutPacket(); + uint8_t *ptr = out_packet->start_ptr; + uint32_t send_size; + + /* mark the stub as stopped and send the stop packet */ + state->ctl_stub_state = gdb_stub_state::STOPPED_GDB_STATE; + state->main_stop_flag = 1; + + send_size = make_stop_packet( ptr, state->stop_type, state->stop_address); + + /*ptr[0] = 'S'; + ptr[1] = hexchars[state->stop_reason >> 4]; + ptr[2] = hexchars[state->stop_reason & 0xf];*/ + + putpacket( state->sock_fd, out_packet, send_size); + DEBUG_LOG( "\nBreak from Emulation\n"); + } + else { + LOG_ERROR( "Asked to stop and already stopped\n"); + } + break; + + default: + /* quit out */ + quit = 1; + break; + } + } + + else { + //struct armcpu_t *cpu = twin_states->cpus[i]; + SOCKET_TYPE arm_listener = state->listen_fd; + + /* check for a connection request */ + if ( FD_ISSET( arm_listener, &read_sock_set)) { + SOCKET_TYPE new_conn; + struct sockaddr_in gdb_addr; +#ifdef WIN32 + int addr_size = sizeof( gdb_addr); +#else + socklen_t addr_size = sizeof( gdb_addr); +#endif + + //DEBUG_LOG("listener\n"); + + /* accept the connection if we do not already have one */ + new_conn = accept( arm_listener, (struct sockaddr *)&gdb_addr, + &addr_size); + + if ( new_conn != -1) { + int close_sock = 1; + + //DEBUG_LOG("got new socket\n"); + if ( state->sock_fd == -1 && state->active) { +#ifdef WIN32 + BOOL nodelay_opt = 1; +#else + int nodelay_opt = 1; +#endif + int set_res; + + //DEBUG_LOG("new connection\n"); + + close_sock = 0; + /* make the socket NODELAY */ +#ifdef WIN32 + set_res = setsockopt( new_conn, IPPROTO_TCP, TCP_NODELAY, + (char*)&nodelay_opt, sizeof( nodelay_opt)); +#else + set_res = setsockopt( new_conn, IPPROTO_TCP, TCP_NODELAY, + &nodelay_opt, sizeof( nodelay_opt)); +#endif + + if ( set_res != 0) { + LOG_ERROR( "Failed to set NODELAY socket option \"%s\"\n", strerror( errno)); + } + + FD_SET( new_conn, &main_set); + state->sock_fd = new_conn; + } + + if ( close_sock) { + //DEBUG_LOG("closing new socket\n"); +#ifdef WIN32 + closesocket( new_conn); +#else + close( new_conn); +#endif + } + } + } + + /* handle the gdb connection */ + if ( state->sock_fd != -1 && state->active) { + SOCKET_TYPE gdb_sock = state->sock_fd; + if ( FD_ISSET( gdb_sock, &read_sock_set)) { + enum read_res_gdb read_res = readPacket_gdb( gdb_sock, &state->rx_packet); + + //DEBUG_LOG("socket read %d\n", read_res); + + switch ( read_res) { + case READ_NOT_FINISHED: + /* do nothing here */ + break; + + case READ_SOCKET_ERROR: + /* close the socket */ +#ifdef WIN32 + closesocket( gdb_sock); +#else + close( gdb_sock); +#endif + state->sock_fd = -1; + FD_CLR( gdb_sock, &main_set); + break; + + case READ_BREAK: { + /* break the running of the cpu */ + if ( state->ctl_stub_state != gdb_stub_state::STOPPED_GDB_STATE) { + /* this will cause the emulation to break the execution */ + DEBUG_LOG( "Breaking execution\n"); + + /* install the post execution function */ + state->cpu_ctrl->install_post_ex_fn( state->cpu_ctrl->data, + break_execution, + state); + } + break; + } + + case READ_COMPLETE: { + uint8_t reply; + int write_res; + int process_packet = 0; + int close_socket = 0; + struct packet_reader_gdb *packet = &state->rx_packet; + + if ( state->ctl_stub_state != gdb_stub_state::STOPPED_GDB_STATE) { + /* not ready to process packet yet, send a bad reply */ + reply = '-'; + } + else { + /* send a reply based on the checksum and if okay process the packet */ + if ( packet->read_checksum == packet->checksum) { + reply = '+'; + process_packet = 1; + } + else { + reply = '-'; + } + } + + write_res = send( gdb_sock, (char*)&reply, 1, 0); + + if ( write_res != 1) { + close_socket = 1; + } + else { + if ( processPacket_gdb( gdb_sock, state->rx_packet.buffer, + state) == -1) { + close_socket = 1; + } + } + + if ( close_socket) { +#ifdef WIN32 + closesocket( gdb_sock); +#else + close( gdb_sock); +#endif + state->sock_fd = -1; + FD_CLR( gdb_sock, &main_set); + } + break; + } + } + } + } + } + } + } + + + /* tidy up and leave */ + if ( state->sock_fd != -1) { +#ifdef WIN32 + closesocket( state->sock_fd); +#else + close( state->sock_fd); +#endif + } + + /* close the listenering sockets */ +#ifdef WIN32 + closesocket( state->listen_fd); +#else + close( state->listen_fd); +#endif + + return; +} + + + + +/* + * + * The memory interface + * + */ +static uint32_t FASTCALL +gdb_prefetch32( void *data, uint32_t adr) { + struct gdb_stub_state *stub = (struct gdb_stub_state *)data; + uint32_t value = 0; + int breakpoint; + + breakpoint = check_breaks_gdb( stub, stub->instr_breakpoints, adr, 4, + STOP_BREAKPOINT); + + if ( !breakpoint) { + /* pass down to the real memory interace */ + value = stub->real_cpu_memio->prefetch32( stub->real_cpu_memio->data, + adr); + } + + return value; +} +static uint16_t FASTCALL +gdb_prefetch16( void *data, uint32_t adr) { + struct gdb_stub_state *stub = (struct gdb_stub_state *)data; + uint16_t value = 0; + int breakpoint; + + breakpoint = check_breaks_gdb( stub, stub->instr_breakpoints, adr, 2, + STOP_BREAKPOINT); + + if ( !breakpoint) { + /* pass down to the real memory interace */ + value = stub->real_cpu_memio->prefetch16( stub->real_cpu_memio->data, + adr); + } + + return value; +} + +/** read 8 bit data value */ +static uint8_t FASTCALL +gdb_read8( void *data, uint32_t adr) { + struct gdb_stub_state *stub = (struct gdb_stub_state *)data; + uint8_t value = 0; + int breakpoint; + + /* pass down to the real memory interace */ + value = stub->real_cpu_memio->read8( stub->real_cpu_memio->data, + adr); + + breakpoint = check_breaks_gdb( stub, stub->read_breakpoints, adr, 1, + STOP_RWATCHPOINT); + if ( !breakpoint) + check_breaks_gdb( stub, stub->access_breakpoints, adr, 1, + STOP_AWATCHPOINT); + + return value; +} + +/** read 16 bit data value */ +static uint16_t FASTCALL +gdb_read16( void *data, uint32_t adr) { + struct gdb_stub_state *stub = (struct gdb_stub_state *)data; + uint16_t value; + int breakpoint; + + /* pass down to the real memory interace */ + value = stub->real_cpu_memio->read16( stub->real_cpu_memio->data, + adr); + + breakpoint = check_breaks_gdb( stub, stub->read_breakpoints, adr, 2, + STOP_RWATCHPOINT); + if ( !breakpoint) + check_breaks_gdb( stub, stub->access_breakpoints, adr, 2, + STOP_AWATCHPOINT); + + return value; +} +/** read 32 bit data value */ +static uint32_t FASTCALL +gdb_read32( void *data, uint32_t adr) { + struct gdb_stub_state *stub = (struct gdb_stub_state *)data; + uint32_t value; + int breakpoint; + + /* pass down to the real memory interace */ + value = stub->real_cpu_memio->read32( stub->real_cpu_memio->data, + adr); + + breakpoint = check_breaks_gdb( stub, stub->read_breakpoints, adr, 4, + STOP_RWATCHPOINT); + if ( !breakpoint) + check_breaks_gdb( stub, stub->access_breakpoints, adr, 4, + STOP_AWATCHPOINT); + + return value; +} + +/** write 8 bit data value */ +static void FASTCALL +gdb_write8( void *data, uint32_t adr, uint8_t val) { + struct gdb_stub_state *stub = (struct gdb_stub_state *)data; + int breakpoint; + + /* pass down to the real memory interace */ + stub->real_cpu_memio->write8( stub->real_cpu_memio->data, + adr, val); + + breakpoint = check_breaks_gdb( stub, stub->write_breakpoints, adr, 1, + STOP_WATCHPOINT); + if ( !breakpoint) + check_breaks_gdb( stub, stub->access_breakpoints, adr, 1, + STOP_AWATCHPOINT); +} + +/** write 16 bit data value */ +static void FASTCALL +gdb_write16( void *data, uint32_t adr, uint16_t val) { + struct gdb_stub_state *stub = (struct gdb_stub_state *)data; + int breakpoint; + + /* pass down to the real memory interace */ + stub->real_cpu_memio->write16( stub->real_cpu_memio->data, + adr, val); + + breakpoint = check_breaks_gdb( stub, stub->write_breakpoints, adr, 2, + STOP_WATCHPOINT); + if ( !breakpoint) + check_breaks_gdb( stub, stub->access_breakpoints, adr, 2, + STOP_AWATCHPOINT); +} + +/** write 32 bit data value */ +static void FASTCALL +gdb_write32( void *data, uint32_t adr, uint32_t val) { + struct gdb_stub_state *stub = (struct gdb_stub_state *)data; + int breakpoint; + + /* pass down to the real memory interace */ + stub->real_cpu_memio->write32( stub->real_cpu_memio->data, + adr, val); + + breakpoint = check_breaks_gdb( stub, stub->write_breakpoints, adr, 4, + STOP_WATCHPOINT); + if ( !breakpoint) + check_breaks_gdb( stub, stub->access_breakpoints, adr, 4, + STOP_AWATCHPOINT); +} + + + + + + + +#ifdef WIN32 +struct socket_creator_data { + SOCKET_TYPE *sock; + int port_num; +}; +/** + */ +static DWORD WINAPI +control_creator( LPVOID lpParameter) +{ + struct socket_creator_data *my_data = (struct socket_creator_data *)lpParameter; + + *my_data->sock = socket( PF_INET, SOCK_STREAM, 0); + + if ( *my_data->sock != INVALID_SOCKET) { + int connect_res; + struct sockaddr_in clientService; + + clientService.sin_family = AF_INET; + clientService.sin_addr.s_addr = inet_addr( "127.0.0.1" ); + clientService.sin_port = htons( my_data->port_num); + + connect_res = connect( *my_data->sock, (SOCKADDR*) &clientService, sizeof(clientService)); + + if ( connect_res == SOCKET_ERROR) { + LOG_ERROR( "Failed to connect to socket\n"); + } + } + + return 0; +} + +#endif + + + +/** + */ +gdbstub_handle_t +createStub_gdb( uint16_t port, + struct armcpu_memory_iface **cpu_memio, + struct armcpu_memory_iface *direct_memio) { + struct gdb_stub_state *stub; + gdbstub_handle_t handle = NULL; + int i; + int res = 0; + + stub = (gdb_stub_state*)malloc( sizeof (struct gdb_stub_state)); + if ( stub == NULL) { + return NULL; + } + + stub->active = 0; + + /* keep the memory interfaces */ + stub->real_cpu_memio = *cpu_memio; + stub->direct_memio = direct_memio; + + *cpu_memio = &stub->cpu_memio; + + /* fill in the memory interface */ + stub->cpu_memio.data = stub; + stub->cpu_memio.prefetch32 = gdb_prefetch32; + stub->cpu_memio.prefetch16 = gdb_prefetch16; + + stub->cpu_memio.read8 = gdb_read8; + stub->cpu_memio.read16 = gdb_read16; + stub->cpu_memio.read32 = gdb_read32; + + stub->cpu_memio.write8 = gdb_write8; + stub->cpu_memio.write16 = gdb_write16; + stub->cpu_memio.write32 = gdb_write32; + + + + /* put the breakpoint descriptors onto the free list */ + for ( i = 0; i < BREAKPOINT_POOL_SIZE - 1; i++) { + stub->breakpoint_pool[i].next = &stub->breakpoint_pool[i+1]; + } + stub->breakpoint_pool[i].next = NULL; + stub->free_breakpoints = &stub->breakpoint_pool[0]; + stub->instr_breakpoints = NULL; + + stub->read_breakpoints = NULL; + stub->write_breakpoints = NULL; + stub->access_breakpoints = NULL; + +#ifdef WIN32 + /* initialise the winsock library */ + { + WORD wVersionRequested; + WSADATA wsaData; + int err; + + wVersionRequested = MAKEWORD( 2, 2 ); + + err = WSAStartup( wVersionRequested, &wsaData ); + if ( err != 0 ) { + return NULL; + } + } + + { + struct socket_creator_data temp_data = { + &stub->ctl_pipe[0], + 24689 + }; + SOCKET_TYPE temp_sock = createSocket ( temp_data.port_num); + HANDLE temp_thread = INVALID_HANDLE_VALUE; + DWORD temp_threadID; + + res = -1; + + if ( temp_sock != -1) { + /* create a thread to connect to this socket */ + temp_thread = CreateThread( NULL, 0, control_creator, &temp_data, 0, &temp_threadID); + if ( temp_thread != INVALID_HANDLE_VALUE) { + struct sockaddr_in ignore_addr; + int addr_size = sizeof( ignore_addr); + + stub->ctl_pipe[1] = accept( temp_sock, (struct sockaddr *)&ignore_addr, &addr_size); + + if ( stub->ctl_pipe[1] != INVALID_SOCKET) { + BOOL nodelay_opt = 1; + int set_res; + + /* make the socket NODELAY */ + set_res = setsockopt( stub->ctl_pipe[1], IPPROTO_TCP, TCP_NODELAY, + (char*)&nodelay_opt, sizeof( nodelay_opt)); + if ( set_res == 0) { + closesocket( temp_sock); + res = 0; + } + } + } + } + } + + if ( res != 0) { + LOG_ERROR( "Failed to create control socket\n"); + } +#else + /* create the control pipe */ + res = pipe( stub->ctl_pipe); + + if ( res != 0) { + LOG_ERROR( "Failed to create control pipe \"%s\"\n", strerror( errno)); + } +#endif + else { + stub->active = 1; + stub->emu_stub_state = gdb_stub_state::RUNNING_EMU_GDB_STATE; + stub->ctl_stub_state = gdb_stub_state::STOPPED_GDB_STATE; + stub->rx_packet.state = IDLE_READ_STATE; + + stub->main_stop_flag = 1; + + stub->port_num = port; + stub->sock_fd = -1; + stub->listen_fd = createSocket( port); + + stub->stop_type = STOP_UNKNOWN; + + if ( stub->listen_fd == -1) { + LOG_ERROR( "Failed to create listening socket \"%s\"\n", strerror( errno)); + res = -1; + } + } + + if ( res != -1) { + /* create the listenering thread */ + stub->thread = createThread_gdb( listenerThread_gdb, stub); + + if ( stub->thread == NULL) { + LOG_ERROR("Failed to create listener thread\n"); + free( stub); + } + else { + handle = stub; + + DEBUG_LOG("Created stub on port %d\n", port); + } + } + else { + free( stub); + } + + return handle; +} + + +void +destroyStub_gdb( gdbstub_handle_t instance) { + struct gdb_stub_state *stub = (struct gdb_stub_state *)instance; + + causeQuit_gdb( stub); + + joinThread_gdb( stub->thread); + + //stub->cpu_ctl->unstall( stub->cpu_ctl->data); + //stub->cpu_ctl->remove_post_ex_fn( stub->cpu_ctl->data); + + free( stub); +} + +void +activateStub_gdb( gdbstub_handle_t instance, + struct armcpu_ctrl_iface *cpu_ctrl) { + struct gdb_stub_state *stub = (struct gdb_stub_state *)instance; + + stub->cpu_ctrl = cpu_ctrl; + + /* stall the cpu */ + stub->cpu_ctrl->stall( stub->cpu_ctrl->data); + + stub->active = 1; +} diff --git a/desmume/src/gdbstub/gdbstub_internal.h b/src/gdbstub/gdbstub_internal.h similarity index 96% rename from desmume/src/gdbstub/gdbstub_internal.h rename to src/gdbstub/gdbstub_internal.h index a9f180f3e..ceadc5720 100644 --- a/desmume/src/gdbstub/gdbstub_internal.h +++ b/src/gdbstub/gdbstub_internal.h @@ -1,160 +1,160 @@ -#ifndef _GDBSTUB_INTERNAL_H_ -#define _GDBSTUB_INTERNAL_H_ 1 -/* $Id: gdbstub_internal.h,v 1.1 2007-06-07 09:43:25 masscat Exp $ - */ -/* - * THE SOFTWARE WITHIN THIS FILE IS NOT COPYRIGHTED - * - * Originally written by Ben Jaques. - * - * The software is offered for use in the public domain in the hope that - * it will be useful, but WITHOUT ANY WARRANTY; without even the implied - * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. - */ - -#ifdef WIN32 -#define SOCKET_TYPE SOCKET -#else -#define SOCKET_TYPE int -#endif - - -enum stop_type { - STOP_UNKNOWN, - STOP_HOST_BREAK, - STOP_STEP_BREAK, - STOP_BREAKPOINT, - STOP_WATCHPOINT, - STOP_RWATCHPOINT, - STOP_AWATCHPOINT -}; - - -/** - * The structure describing a breakpoint. - */ -struct breakpoint_gdb { - /** link them in a list */ - struct breakpoint_gdb *next; - - /** The address of the breakpoint */ - uint32_t addr; - - /** The size of the breakpoint */ - uint32_t size; -}; - - -/* - */ -#define BUFMAX_GDB 2048 - -struct packet_reader_gdb { - int state; - - int pos_index; - - uint8_t checksum; - - uint8_t read_checksum; - - uint8_t buffer[BUFMAX_GDB]; -}; - -/** The maximum number of breakpoints (of all types) available to the stub */ -#define BREAKPOINT_POOL_SIZE 100 - - -struct gdb_stub_state { - /** flag indicating if the stub is active */ - int active; - - int main_stop_flag; - - /** the listener thread */ - void *thread; - - /** the id of the cpu the is under control */ - //u32 cpu_id; - - /** the interface used to control the CPU */ - struct armcpu_ctrl_iface *cpu_ctrl; - - /** the memory interface passed to the CPU */ - struct armcpu_memory_iface cpu_memio; - - /** the direct interface to the memory system */ - struct armcpu_memory_iface *direct_memio; - - /** the CPU memory interface to the real memory system */ - struct armcpu_memory_iface *real_cpu_memio; - - /** the list of active instruction breakpoints */ - struct breakpoint_gdb *instr_breakpoints; - - /** the list of active read breakpoints */ - struct breakpoint_gdb *read_breakpoints; - - /** the list of active write breakpoints */ - struct breakpoint_gdb *write_breakpoints; - - /** the list of active access breakpoints */ - struct breakpoint_gdb *access_breakpoints; - - /** the pointer to the step break point (not NULL if set) */ - //struct breakpoint_gdb *step_breakpoint; - - uint32_t step_instr_address; - - /** the state of the stub as seen by the emulator, the emulator side can - * set this to STOPPING_EMU_GDB_STATE to indicate that the a breakpoint has been hit, - * and STOPPED_EMU_GDB_STATE when it has informed the gdb thread that a breakpoint has - * been hit. - * When handled the stub side will set it back to RUNNING_EMU_GDB_STATE. - * - * The emulator should only run the corresponding ARM if this is set to - * RUNNING_EMU_GDB_STATE. - */ - enum EMU_STUB_STATE { STOPPED_EMU_GDB_STATE, STOPPING_EMU_GDB_STATE, RUNNING_EMU_GDB_STATE} emu_stub_state; - - /** the state of the stub as set by the stub control thread */ - enum CTL_STUB_STATE { STOPPED_GDB_STATE, RUNNING_GDB_STATE, - STEPPING_GDB_STATE, START_RUN_GDB_STATE} ctl_stub_state; - - struct packet_reader_gdb rx_packet; - - /** the socket information */ - uint16_t port_num; - SOCKET_TYPE sock_fd; - - /** The listening socket */ - SOCKET_TYPE listen_fd; - - /** the type of event that caused the stop */ - enum stop_type stop_type; - - /** the address of the stop */ - uint32_t stop_address; - - /** The step break point decsriptor */ - struct breakpoint_gdb step_breakpoint_descr; - - /** the breakpoint descriptor pool */ - struct breakpoint_gdb breakpoint_pool[BREAKPOINT_POOL_SIZE]; - - /** the free breakpoint descriptor list */ - struct breakpoint_gdb *free_breakpoints; - - /** the control pipe (or socket) to the gdb stub */ - SOCKET_TYPE ctl_pipe[2]; -}; - - -enum read_res_gdb { - READ_NOT_FINISHED, - READ_SOCKET_ERROR, - READ_COMPLETE, - READ_BREAK -}; - -#endif /* End of _GDBSTUB_INTERNAL_H_ */ +#ifndef _GDBSTUB_INTERNAL_H_ +#define _GDBSTUB_INTERNAL_H_ 1 +/* $Id: gdbstub_internal.h,v 1.1 2007-06-07 09:43:25 masscat Exp $ + */ +/* + * THE SOFTWARE WITHIN THIS FILE IS NOT COPYRIGHTED + * + * Originally written by Ben Jaques. + * + * The software is offered for use in the public domain in the hope that + * it will be useful, but WITHOUT ANY WARRANTY; without even the implied + * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + */ + +#ifdef WIN32 +#define SOCKET_TYPE SOCKET +#else +#define SOCKET_TYPE int +#endif + + +enum stop_type { + STOP_UNKNOWN, + STOP_HOST_BREAK, + STOP_STEP_BREAK, + STOP_BREAKPOINT, + STOP_WATCHPOINT, + STOP_RWATCHPOINT, + STOP_AWATCHPOINT +}; + + +/** + * The structure describing a breakpoint. + */ +struct breakpoint_gdb { + /** link them in a list */ + struct breakpoint_gdb *next; + + /** The address of the breakpoint */ + uint32_t addr; + + /** The size of the breakpoint */ + uint32_t size; +}; + + +/* + */ +#define BUFMAX_GDB 2048 + +struct packet_reader_gdb { + int state; + + int pos_index; + + uint8_t checksum; + + uint8_t read_checksum; + + uint8_t buffer[BUFMAX_GDB]; +}; + +/** The maximum number of breakpoints (of all types) available to the stub */ +#define BREAKPOINT_POOL_SIZE 100 + + +struct gdb_stub_state { + /** flag indicating if the stub is active */ + int active; + + int main_stop_flag; + + /** the listener thread */ + void *thread; + + /** the id of the cpu the is under control */ + //u32 cpu_id; + + /** the interface used to control the CPU */ + struct armcpu_ctrl_iface *cpu_ctrl; + + /** the memory interface passed to the CPU */ + struct armcpu_memory_iface cpu_memio; + + /** the direct interface to the memory system */ + struct armcpu_memory_iface *direct_memio; + + /** the CPU memory interface to the real memory system */ + struct armcpu_memory_iface *real_cpu_memio; + + /** the list of active instruction breakpoints */ + struct breakpoint_gdb *instr_breakpoints; + + /** the list of active read breakpoints */ + struct breakpoint_gdb *read_breakpoints; + + /** the list of active write breakpoints */ + struct breakpoint_gdb *write_breakpoints; + + /** the list of active access breakpoints */ + struct breakpoint_gdb *access_breakpoints; + + /** the pointer to the step break point (not NULL if set) */ + //struct breakpoint_gdb *step_breakpoint; + + uint32_t step_instr_address; + + /** the state of the stub as seen by the emulator, the emulator side can + * set this to STOPPING_EMU_GDB_STATE to indicate that the a breakpoint has been hit, + * and STOPPED_EMU_GDB_STATE when it has informed the gdb thread that a breakpoint has + * been hit. + * When handled the stub side will set it back to RUNNING_EMU_GDB_STATE. + * + * The emulator should only run the corresponding ARM if this is set to + * RUNNING_EMU_GDB_STATE. + */ + enum EMU_STUB_STATE { STOPPED_EMU_GDB_STATE, STOPPING_EMU_GDB_STATE, RUNNING_EMU_GDB_STATE} emu_stub_state; + + /** the state of the stub as set by the stub control thread */ + enum CTL_STUB_STATE { STOPPED_GDB_STATE, RUNNING_GDB_STATE, + STEPPING_GDB_STATE, START_RUN_GDB_STATE} ctl_stub_state; + + struct packet_reader_gdb rx_packet; + + /** the socket information */ + uint16_t port_num; + SOCKET_TYPE sock_fd; + + /** The listening socket */ + SOCKET_TYPE listen_fd; + + /** the type of event that caused the stop */ + enum stop_type stop_type; + + /** the address of the stop */ + uint32_t stop_address; + + /** The step break point decsriptor */ + struct breakpoint_gdb step_breakpoint_descr; + + /** the breakpoint descriptor pool */ + struct breakpoint_gdb breakpoint_pool[BREAKPOINT_POOL_SIZE]; + + /** the free breakpoint descriptor list */ + struct breakpoint_gdb *free_breakpoints; + + /** the control pipe (or socket) to the gdb stub */ + SOCKET_TYPE ctl_pipe[2]; +}; + + +enum read_res_gdb { + READ_NOT_FINISHED, + READ_SOCKET_ERROR, + READ_COMPLETE, + READ_BREAK +}; + +#endif /* End of _GDBSTUB_INTERNAL_H_ */ diff --git a/desmume/src/gfx3d.cpp b/src/gfx3d.cpp similarity index 75% rename from desmume/src/gfx3d.cpp rename to src/gfx3d.cpp index 53b90558e..b2508ae87 100644 --- a/desmume/src/gfx3d.cpp +++ b/src/gfx3d.cpp @@ -1,9 +1,8 @@ -//2 /* Copyright (C) 2006 yopyop yopyop156@ifrance.com - yopyop156.ifrance.com + yopyop156.ifrance.com - Copyright (C) 2008-2009 DeSmuME team + Copyright (C) 2008-2009 DeSmuME team This file is part of DeSmuME @@ -24,7 +23,7 @@ //This file implements the geometry engine hardware component. //This handles almost all of the work of 3d rendering, leaving the renderer -//plugin responsible only for drawing primitives. +// plugin responsible only for drawing primitives. #include #include @@ -62,8 +61,8 @@ in this function: */ static void gfx3d_doFlush(); #ifdef USE_GEOMETRY_FIFO_EMULATION -#define GFX_DELAY(x) MMU.gfx3dCycles = nds_timer + (1*x); -#define GFX_DELAY_M2(x) MMU.gfx3dCycles += (1*x); +#define GFX_DELAY(x) MMU.gfx3dCycles = nds.cycles + (2*x) +#define GFX_DELAY_M2(x) MMU.gfx3dCycles += (2*x) #else #define GFX_DELAY(x) #define GFX_DELAY_M2(x) @@ -147,6 +146,11 @@ static float float10Table[1024]; static float float10RelTable[1024]; static float normalTable[1024]; +#ifndef NOSSE2 +float ALIGN(16) _fix2float_divizor_mask[4] = { 4096.f, 4096.f, 4096.f, 4096.f }; +float ALIGN(16) _fix10_2float_divizor_mask[4] = { 512.f, 512.f, 512.f, 512.f }; +#endif + #define fix2float(v) (((float)((s32)(v))) / (float)(1<<12)) #define fix10_2float(v) (((float)((s32)(v))) / (float)(1<<9)) @@ -313,20 +317,6 @@ static void makeTables() { void gfx3d_init() { - //DWORD start = timeGetTime(); - //for(int i=0;i<1000000000;i++) - // MatrixMultVec4x4(mtxCurrent[0],mtxCurrent[1]); - //DWORD end = timeGetTime(); - //DWORD diff = end-start; - - //start = timeGetTime(); - //for(int i=0;i<1000000000;i++) - // MatrixMultVec4x4_b(mtxCurrent[0],mtxCurrent[1]); - //end = timeGetTime(); - //DWORD diff2 = end-start; - - //printf("SPEED TEST %d %d\n",diff,diff2); - if(polylists == NULL) { polylists = new POLYLIST[2]; polylist = &polylists[0]; } if(vertlists == NULL) { vertlists = new VERTLIST[2]; vertlist = &vertlists[0]; } makeTables(); @@ -339,8 +329,6 @@ void gfx3d_reset() drawPending = FALSE; flushPending = FALSE; - memset(polylists, 0, sizeof(polylists)); - memset(vertlists, 0, sizeof(vertlists)); listTwiddle = 1; twiddleLists(); @@ -350,13 +338,11 @@ void gfx3d_reset() MatrixInit (mtxCurrent[3]); MatrixInit (mtxTemporal); - MatrixStackInit(&mtxStack[0]); - MatrixStackInit(&mtxStack[1]); - MatrixStackInit(&mtxStack[2]); - MatrixStackInit(&mtxStack[3]); - clCmd = 0; clInd = 0; +#ifdef USE_GEOMETRY_FIFO_EMULATION + clInd2 = 0; +#endif ML4x4ind = 0; ML4x3ind = 0; @@ -378,23 +364,411 @@ void gfx3d_reset() gfx3d.clearDepth = gfx3d_extendDepth_15_to_24(0x7FFF); + GFX_FIFOclear(); + #ifdef USE_GEOMETRY_FIFO_EMULATION clInd2 = 0; isSwapBuffers = false; isVBlank = false; bWaitForPolys = false; #endif +} - GFX_PIPEclear(); - GFX_FIFOclear(); +void gfx3d_glViewPort(u32 v) +{ + viewport = v; + GFX_DELAY(1); +} + +void VIEWPORT::decode(u32 v) +{ + x = (v&0xFF); + y = std::min(191,(int)(((v>>8)&0xFF))); + width = (((v>>16)&0xFF)+1)-(v&0xFF); + height = ((v>>24)+1)-((v>>8)&0xFF); } -//================================================================================= Geometry Engine -//================================================================================= -//================================================================================= +void gfx3d_glClearColor(u32 v) +{ + gfx3d.clearColor = v; + +} + +void gfx3d_glFogColor(u32 v) +{ + gfx3d.fogColor[0] = ((float)((v )&0x1F))/31.0f; + gfx3d.fogColor[1] = ((float)((v>> 5)&0x1F))/31.0f; + gfx3d.fogColor[2] = ((float)((v>>10)&0x1F))/31.0f; + gfx3d.fogColor[3] = ((float)((v>>16)&0x1F))/31.0f; +} + +void gfx3d_glFogOffset (u32 v) +{ + gfx3d.fogOffset = (float)(v&0xffff); +} + +void gfx3d_glClearDepth(u32 v) +{ + v &= 0x7FFF; + gfx3d.clearDepth = gfx3d_extendDepth_15_to_24(v); +} + +void gfx3d_glMatrixMode(u32 v) +{ + mode = (v&3); + + GFX_DELAY(1); +} + + +void gfx3d_glLoadIdentity() +{ + MatrixIdentity (mtxCurrent[mode]); + + GFX_DELAY(19); + + if (mode == 2) + MatrixIdentity (mtxCurrent[1]); +} + +BOOL gfx3d_glLoadMatrix4x4(s32 v) +{ +#ifdef NOSSE2 + mtxCurrent[mode][ML4x4ind] = fix2float(v); +#else + mtxCurrent[mode][ML4x4ind] = v; +#endif + + ++ML4x4ind; + if(ML4x4ind<16) return FALSE; + ML4x4ind = 0; + + GFX_DELAY(19); + +#ifndef NOSSE2 + _sse2_fix2float_16(mtxCurrent[mode], _fix2float_divizor_mask); +#endif + + if (mode == 2) + MatrixCopy (mtxCurrent[1], mtxCurrent[2]); + return TRUE; +} + +BOOL gfx3d_glLoadMatrix4x3(s32 v) +{ +#ifdef NOSSE2 + mtxCurrent[mode][ML4x3ind] = fix2float(v); +#else + mtxCurrent[mode][ML4x3ind] = v; +#endif + + ML4x3ind++; + if((ML4x3ind & 0x03) == 3) ML4x3ind++; + if(ML4x3ind<16) return FALSE; + ML4x3ind = 0; + +#ifndef NOSSE2 + _sse2_fix2float_16(mtxCurrent[mode], _fix2float_divizor_mask); +#endif + + //fill in the unusued matrix values + mtxCurrent[mode][3] = mtxCurrent[mode][7] = mtxCurrent[mode][11] = 0.f; + mtxCurrent[mode][15] = 1.f; + + GFX_DELAY(30); + + if (mode == 2) + MatrixCopy (mtxCurrent[1], mtxCurrent[2]); + return TRUE; +} + +void gfx3d_glStoreMatrix(u32 v) +{ + //this command always works on both pos and vector when either pos or pos-vector are the current mtx mode + short mymode = (mode==1?2:mode); + + //limit height of these stacks. + //without the mymode==3 namco classics galaxian will try to use pos=1 and overrun the stack, corrupting emu + if(mymode==0 || mymode==3) + v = 0; + + if(v==31) v=30; //? what should happen in this case? + + MatrixStackLoadMatrix (&mtxStack[mymode], v&31, mtxCurrent[mymode]); + + GFX_DELAY(17); + + if(mymode==2) + MatrixStackLoadMatrix (&mtxStack[1], v&31, mtxCurrent[1]); +} + +void gfx3d_glRestoreMatrix(u32 v) +{ + //this command always works on both pos and vector when either pos or pos-vector are the current mtx mode + short mymode = (mode==1?2:mode); + + //limit height of these stacks + //without the mymode==3 namco classics galaxian will try to use pos=1 and overrun the stack, corrupting emu + if(mymode==0 || mymode==3) + v = 0; + + if(v==31) v=30; //? what should happen in this case? + + MatrixCopy (mtxCurrent[mymode], MatrixStackGetPos(&mtxStack[mymode], v&31)); + + GFX_DELAY(36); + + if (mymode == 2) + MatrixCopy (mtxCurrent[1], MatrixStackGetPos(&mtxStack[1], v&31)); +} + +void gfx3d_glPushMatrix() +{ + u32 gxstat = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x600); + //this command always works on both pos and vector when either pos or pos-vector are the current mtx mode + short mymode = (mode==1?2:mode); + + if (mtxStack[mymode].position > mtxStack[mymode].size) + { + gxstat |= (1<<15); + T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x600, gxstat); + return; + } + + gxstat &= 0xFFFF00FF; + + MatrixStackPushMatrix(&mtxStack[mymode], mtxCurrent[mymode]); + + GFX_DELAY(17); + + if(mymode==2) + MatrixStackPushMatrix (&mtxStack[1], mtxCurrent[1]); + + gxstat |= ((mtxStack[0].position << 13) | (mtxStack[1].position << 8)); + T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x600, gxstat); + + +} + +void gfx3d_glPopMatrix(s32 i) +{ + u32 gxstat = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x600); + + //this command always works on both pos and vector when either pos or pos-vector are the current mtx mode + short mymode = (mode==1?2:mode); + + /* + if (i > mtxStack[mymode].position) + { + gxstat |= (1<<15); + T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x600, gxstat); + return; + } + */ + gxstat &= 0xFFFF00FF; + + MatrixCopy(mtxCurrent[mymode], MatrixStackPopMatrix (&mtxStack[mymode], i)); + + GFX_DELAY(36); + + if (mymode == 2) + MatrixCopy(mtxCurrent[1], MatrixStackPopMatrix (&mtxStack[1], i)); + + gxstat |= ((mtxStack[0].position << 13) | (mtxStack[1].position << 8)); + T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x600, gxstat); + + +} + +BOOL gfx3d_glTranslate(s32 v) +{ + trans[transind] = fix2float(v); + + ++transind; + + if(transind<3) return FALSE; + transind = 0; + + MatrixTranslate (mtxCurrent[mode], trans); + + GFX_DELAY(22); + + if (mode == 2) + { + MatrixTranslate (mtxCurrent[1], trans); + GFX_DELAY_M2(30); + } + return TRUE; +} + +BOOL gfx3d_glScale(s32 v) +{ + scale[scaleind] = fix2float(v); + + ++scaleind; + + if(scaleind<3) return FALSE; + scaleind = 0; + + MatrixScale (mtxCurrent[(mode==2?1:mode)], scale); + + GFX_DELAY(22); + + //note: pos-vector mode should not cause both matrices to scale. + //the whole purpose is to keep the vector matrix orthogonal + //so, I am leaving this commented out as an example of what not to do. + //if (mode == 2) + // MatrixScale (mtxCurrent[1], scale); + return TRUE; +} + +BOOL gfx3d_glMultMatrix3x3(s32 v) +{ +#ifdef NOSSE2 + mtxTemporal[MM3x3ind] = fix2float(v); +#else + mtxTemporal[MM3x3ind] = v; +#endif + + + MM3x3ind++; + if((MM3x3ind & 0x03) == 3) MM3x3ind++; + if(MM3x3ind<12) return FALSE; + MM3x3ind = 0; + + GFX_DELAY(28); + +#ifndef NOSSE2 + _sse2_fix2float_12(mtxTemporal, _fix2float_divizor_mask); +#endif + + //fill in the unusued matrix values + mtxTemporal[3] = mtxTemporal[7] = mtxTemporal[11] = 0; + mtxTemporal[15] = 1; + mtxTemporal[12] = mtxTemporal[13] = mtxTemporal[14] = 0; + + MatrixMultiply (mtxCurrent[mode], mtxTemporal); + + if (mode == 2) + { + MatrixMultiply (mtxCurrent[1], mtxTemporal); + GFX_DELAY_M2(30); + } + + //does this really need to be done? + MatrixIdentity (mtxTemporal); + return TRUE; +} + +BOOL gfx3d_glMultMatrix4x3(s32 v) +{ +#ifdef NOSSE2 + mtxTemporal[MM4x3ind] = fix2float(v); +#else + mtxTemporal[MM4x3ind] = v; +#endif + + MM4x3ind++; + if((MM4x3ind & 0x03) == 3) MM4x3ind++; + if(MM4x3ind<16) return FALSE; + MM4x3ind = 0; + + GFX_DELAY(31); + +#ifndef NOSSE2 + _sse2_fix2float_16(mtxTemporal, _fix2float_divizor_mask); +#endif + + //fill in the unusued matrix values + mtxTemporal[3] = mtxTemporal[7] = mtxTemporal[11] = 0.f; + mtxTemporal[15] = 1.f; + + MatrixMultiply (mtxCurrent[mode], mtxTemporal); + + if (mode == 2) + { + MatrixMultiply (mtxCurrent[1], mtxTemporal); + GFX_DELAY_M2(30); + } + + //does this really need to be done? + MatrixIdentity (mtxTemporal); + return TRUE; +} + +BOOL gfx3d_glMultMatrix4x4(s32 v) +{ +#ifdef NOSSE2 + mtxTemporal[MM4x4ind] = fix2float(v); +#else + mtxTemporal[MM4x4ind] = v; +#endif + + MM4x4ind++; + if(MM4x4ind<16) return FALSE; + MM4x4ind = 0; + + GFX_DELAY(35); + +#ifndef NOSSE2 + _sse2_fix2float_16(mtxTemporal, _fix2float_divizor_mask); +#endif + + MatrixMultiply (mtxCurrent[mode], mtxTemporal); + + if (mode == 2) + { + MatrixMultiply (mtxCurrent[1], mtxTemporal); + GFX_DELAY_M2(30); + } + + MatrixIdentity (mtxTemporal); + return TRUE; +} + +static void gfx3d_glPolygonAttrib_cache() +{ + // Light enable/disable + lightMask = (polyAttr&0xF); + + // texture environment + envMode = (polyAttr&0x30)>>4; + + // back face culling + cullingMask = (polyAttr>>6)&3; + + // Alpha value, actually not well handled, 0 should be wireframe + colorRGB[3] = colorAlpha = ((polyAttr>>16)&0x1F); +} + +void gfx3d_glBegin(u32 v) +{ + inBegin = TRUE; + vtxFormat = v&0x03; + triStripToggle = 0; + tempVertInfo.count = 0; + tempVertInfo.first = true; + polyAttr = polyAttrPending; + gfx3d_glPolygonAttrib_cache(); + GFX_DELAY(1); +} + +void gfx3d_glEnd(void) +{ + inBegin = FALSE; + tempVertInfo.count = 0; + GFX_DELAY(1); +} + +void gfx3d_glColor3b(u32 v) +{ + colorRGB[0] = (v&0x1F); + colorRGB[1] = ((v>>5)&0x1F); + colorRGB[2] = ((v>>10)&0x1F); + GFX_DELAY(1); +} -#define vec3dot(a, b) (((a[0]) * (b[0])) + ((a[1]) * (b[1])) + ((a[2]) * (b[2]))) #define SUBMITVERTEX(ii, nn) polylist->list[polylist->count].vertIndexes[ii] = tempVertInfo.map[nn]; //Submit a vertex to the GE static void SetVertex() @@ -419,11 +793,15 @@ static void SetVertex() if(polylist->count >= POLYLIST_SIZE) return; - //TODO - think about keeping the clip matrix concatenated, - //so that we only have to multiply one matrix here - //(we could lazy cache the concatenated clip matrix and only generate it - //when we need to) - MatrixMultVec4x4_M2(mtxCurrent[0], coordTransformed); +#ifdef NOSSE2 + //apply modelview matrix + MatrixMultVec4x4 (mtxCurrent[1], coordTransformed); + + //apply projection matrix + MatrixMultVec4x4 (mtxCurrent[0], coordTransformed); +#else + _sse2_MatrixMultVec4x4_M2(mtxCurrent[0], coordTransformed); +#endif //TODO - culling should be done here. //TODO - viewport transform? @@ -536,473 +914,159 @@ static void SetVertex() } } -static void gfx3d_glPolygonAttrib_cache() +BOOL gfx3d_glVertex16b(unsigned int v) { - // Light enable/disable - lightMask = (polyAttr&0xF); + if(coordind==0) + { + coord[0] = float16table[v&0xFFFF]; + coord[1] = float16table[v>>16]; - // texture environment - envMode = (polyAttr&0x30)>>4; + ++coordind; + return FALSE; + } - // back face culling - cullingMask = (polyAttr>>6)&3; + coord[2] = float16table[v&0xFFFF]; - // Alpha value, actually not well handled, 0 should be wireframe - colorRGB[3] = colorAlpha = ((polyAttr>>16)&0x1F); + coordind = 0; + SetVertex (); + + GFX_DELAY(9); + return TRUE; +} + +void gfx3d_glVertex10b(u32 v) +{ + coord[0] = float10Table[v&1023]; + coord[1] = float10Table[(v>>10)&1023]; + coord[2] = float10Table[(v>>20)&1023]; + + GFX_DELAY(8); + SetVertex (); +} + +void gfx3d_glVertex3_cord(unsigned int one, unsigned int two, unsigned int v) +{ + coord[one] = float16table[v&0xffff]; + coord[two] = float16table[v>>16]; + + SetVertex (); + + GFX_DELAY(8); +} + +void gfx3d_glVertex_rel(u32 v) +{ + coord[0] += float10RelTable[v&1023]; + coord[1] += float10RelTable[(v>>10)&1023]; + coord[2] += float10RelTable[(v>>20)&1023]; + + SetVertex (); + + GFX_DELAY(8); +} + +// Ignored for now +void gfx3d_glSwapScreen(unsigned int screen) +{ +} + + +int gfx3d_GetNumPolys() +{ + //so is this in the currently-displayed or currently-built list? + return (polylists[listTwiddle].count); +} + +int gfx3d_GetNumVertex() +{ + //so is this in the currently-displayed or currently-built list? + return (vertlists[listTwiddle].count); +} + + + +void gfx3d_glPolygonAttrib (u32 val) +{ + if(inBegin) { + PROGINFO("Set polyattr in the middle of a begin/end pair.\n (This won't be activated until the next begin)\n"); + //TODO - we need some some similar checking for teximageparam etc. + } + polyAttrPending = val; + GFX_DELAY(1); +} + +/* + 0-4 Diffuse Reflection Red + 5-9 Diffuse Reflection Green + 10-14 Diffuse Reflection Blue + 15 Set Vertex Color (0=No, 1=Set Diffuse Reflection Color as Vertex Color) + 16-20 Ambient Reflection Red + 21-25 Ambient Reflection Green + 26-30 Ambient Reflection Blue +*/ +void gfx3d_glMaterial0(u32 val) +{ + dsDiffuse = val&0xFFFF; + dsAmbient = val>>16; + + if (BIT15(val)) + { + colorRGB[0] = (val)&0x1F; + colorRGB[1] = (val>>5)&0x1F; + colorRGB[2] = (val>>10)&0x1F; + } + GFX_DELAY(4); +} + +void gfx3d_glMaterial1(u32 val) +{ + dsSpecular = val&0xFFFF; + dsEmission = val>>16; + GFX_DELAY(4); +} + +BOOL gfx3d_glShininess (u32 val) +{ + shininessTable[shininessInd++] = ((val & 0xFF) / 256.0f); + shininessTable[shininessInd++] = (((val >> 8) & 0xFF) / 256.0f); + shininessTable[shininessInd++] = (((val >> 16) & 0xFF) / 256.0f); + shininessTable[shininessInd++] = (((val >> 24) & 0xFF) / 256.0f); + + if (shininessInd < 128) return FALSE; + shininessInd = 0; + GFX_DELAY(32); + return TRUE; +} + +void gfx3d_UpdateToonTable(u8 offset, u16 val) +{ + gfx3d.u16ToonTable[offset] = val; +} + +void gfx3d_UpdateToonTable(u8 offset, u32 val) +{ + gfx3d.u16ToonTable[offset] = val & 0xFFFF; + gfx3d.u16ToonTable[offset+1] = val >> 8; } static void gfx3d_glTexImage_cache() { texCoordinateTransform = (textureFormat>>30); } - -static void gfx3d_glLightDirection_cache(int index) +void gfx3d_glTexImage(u32 val) { - u32 v = lightDirection[index]; - - // Convert format into floating point value - cacheLightDirection[index][0] = normalTable[v&1023]; - cacheLightDirection[index][1] = normalTable[(v>>10)&1023]; - cacheLightDirection[index][2] = normalTable[(v>>20)&1023]; - cacheLightDirection[index][3] = 0; - - /* Multiply the vector by the directional matrix */ - MatrixMultVec3x3(mtxCurrent[2], cacheLightDirection[index]); - - /* Calculate the half vector */ - float lineOfSight[4] = {0.0f, 0.0f, -1.0f, 0.0f}; - for(int i = 0; i < 4; i++) - { - cacheHalfVector[index][i] = ((cacheLightDirection[index][i] + lineOfSight[i]) / 2.0f); - } -} - -//=============================================================================== -#ifdef USE_GEOMETRY_FIFO_EMULATION -#if 0 -#define dEXEC(cmdName, oldcmd, newcmd) if (oldcmd != newcmd)\ - INFO("ERROR %s: cmd old 0x%02X, new 0x%02X\n", cmdName, oldcmd, newcmd); -#else -#define dEXEC(cmdName, oldcmd, newcmd) -#endif - - -void FORCEINLINE gfx3d_glMatrixMode(u32 v) -{ - mode = (v&3); - + textureFormat = val; + gfx3d_glTexImage_cache(); GFX_DELAY(1); } -void FORCEINLINE gfx3d_glPushMatrix() +void gfx3d_glTexPalette(u32 val) { - u32 gxstat = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x600); - //this command always works on both pos and vector when either pos or pos-vector are the current mtx mode - short mymode = (mode==1?2:mode); - - if (mtxStack[mymode].position > mtxStack[mymode].size) - { - gxstat |= (1<<15); - T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x600, gxstat); - return; - } - - gxstat &= 0xFFFF00FF; - - MatrixStackPushMatrix(&mtxStack[mymode], mtxCurrent[mymode]); - - GFX_DELAY(17); - - if(mymode==2) - MatrixStackPushMatrix (&mtxStack[1], mtxCurrent[1]); - - gxstat |= ((mtxStack[0].position << 13) | (mtxStack[1].position << 8)); - T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x600, gxstat); -} - -void FORCEINLINE gfx3d_glPopMatrix(s32 i) -{ - u32 gxstat = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x600); - - //this command always works on both pos and vector when either pos or pos-vector are the current mtx mode - short mymode = (mode==1?2:mode); - - /* - if (i > mtxStack[mymode].position) - { - gxstat |= (1<<15); - T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x600, gxstat); - return; - } - */ - gxstat &= 0xFFFF00FF; - - MatrixCopy(mtxCurrent[mymode], MatrixStackPopMatrix (&mtxStack[mymode], i)); - - GFX_DELAY(36); - - if (mymode == 2) - MatrixCopy(mtxCurrent[1], MatrixStackPopMatrix (&mtxStack[1], i)); - - gxstat |= ((mtxStack[0].position << 13) | (mtxStack[1].position << 8)); - T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x600, gxstat); -} - -void FORCEINLINE gfx3d_glStoreMatrix(u32 v) -{ - //this command always works on both pos and vector when either pos or pos-vector are the current mtx mode - short mymode = (mode==1?2:mode); - - //limit height of these stacks. - //without the mymode==3 namco classics galaxian will try to use pos=1 and overrun the stack, corrupting emu - if(mymode==0 || mymode==3) - v = 0; - - if(v==31) v=30; //? what should happen in this case? - - MatrixStackLoadMatrix (&mtxStack[mymode], v&31, mtxCurrent[mymode]); - - GFX_DELAY(17); - - if(mymode==2) - MatrixStackLoadMatrix (&mtxStack[1], v&31, mtxCurrent[1]); -} - -void FORCEINLINE gfx3d_glRestoreMatrix(u32 v) -{ - //this command always works on both pos and vector when either pos or pos-vector are the current mtx mode - short mymode = (mode==1?2:mode); - - //limit height of these stacks - //without the mymode==3 namco classics galaxian will try to use pos=1 and overrun the stack, corrupting emu - if(mymode==0 || mymode==3) - v = 0; - - if(v==31) v=30; //? what should happen in this case? - - MatrixCopy (mtxCurrent[mymode], MatrixStackGetPos(&mtxStack[mymode], v&31)); - - GFX_DELAY(36); - - if (mymode == 2) - MatrixCopy (mtxCurrent[1], MatrixStackGetPos(&mtxStack[1], v&31)); -} - -void FORCEINLINE gfx3d_glLoadIdentity() -{ - MatrixIdentity (mtxCurrent[mode]); - - GFX_DELAY(19); - - if (mode == 2) - MatrixIdentity (mtxCurrent[1]); -} - -void FORCEINLINE gfx3d_glLoadMatrix4x4(s32 v) -{ - mtxCurrent[mode][0] = v; - - for (int i = 1; i < 16; i++) - { - u8 cmd = 0; - u32 param = 0; - - if (!GFX_PIPErecv(&cmd, ¶m)) break; - dEXEC("glLoadMatrix4x4", 0x16, cmd); - mtxCurrent[mode][i] = (s32)param; - } - - vector_fix2float<4>(mtxCurrent[mode], 4096.f); - - GFX_DELAY(19); - - if (mode == 2) - MatrixCopy (mtxCurrent[1], mtxCurrent[2]); -} - -void FORCEINLINE gfx3d_glLoadMatrix4x3(s32 v) -{ - mtxCurrent[mode][0] = v; - - for (int i = 1; i < 16; i++) - { - if ((i & 0x03) == 3) continue; - u8 cmd = 0; - u32 param = 0; - - if (!GFX_PIPErecv(&cmd, ¶m)) break; - dEXEC("glLoadMatrix4x3", 0x17, cmd); - mtxCurrent[mode][i] = (s32)param; - } - - vector_fix2float<4>(mtxCurrent[mode], 4096.f); - - //fill in the unusued matrix values - mtxCurrent[mode][3] = mtxCurrent[mode][7] = mtxCurrent[mode][11] = 0.f; - mtxCurrent[mode][15] = 1.f; - - GFX_DELAY(30); - - if (mode == 2) - MatrixCopy (mtxCurrent[1], mtxCurrent[2]); -} - -void FORCEINLINE gfx3d_glMultMatrix4x4(s32 v) -{ - mtxTemporal[0] = v; - - for (int i = 1; i < 16; i++) - { - u8 cmd = 0; - u32 param = 0; - - if (!GFX_PIPErecv(&cmd, ¶m)) break; - dEXEC("glMultMatrix4x4", 0x18, cmd); - mtxTemporal[i] = (s32)param; - } - - vector_fix2float<4>(mtxTemporal, 4096.f); - - MatrixMultiply (mtxCurrent[mode], mtxTemporal); - - GFX_DELAY(35); - - if (mode == 2) - { - MatrixMultiply (mtxCurrent[1], mtxTemporal); - GFX_DELAY_M2(30); - } - - MatrixIdentity (mtxTemporal); -} - -void FORCEINLINE gfx3d_glMultMatrix4x3(s32 v) -{ - mtxTemporal[0] = v; - - for (int i = 1; i < 16; i++) - { - if ((i & 0x03) == 3) continue; - u8 cmd = 0; - u32 param = 0; - - if (!GFX_PIPErecv(&cmd, ¶m)) break; - dEXEC("glMultMatrix4x3", 0x19, cmd); - mtxTemporal[i] = (s32)param; - } - - vector_fix2float<4>(mtxTemporal, 4096.f); - - //fill in the unusued matrix values - mtxTemporal[3] = mtxTemporal[7] = mtxTemporal[11] = 0.f; - mtxTemporal[15] = 1.f; - - MatrixMultiply (mtxCurrent[mode], mtxTemporal); - - GFX_DELAY(31); - - if (mode == 2) - { - MatrixMultiply (mtxCurrent[1], mtxTemporal); - GFX_DELAY_M2(30); - } - - //does this really need to be done? - MatrixIdentity (mtxTemporal); -} - -void FORCEINLINE gfx3d_glMultMatrix3x3(s32 v) -{ - mtxTemporal[0] = v; - - for (int i = 1; i < 12; i++) - { - if ((i & 0x03) == 3) continue; - u8 cmd = 0; - u32 param = 0; - - if (!GFX_PIPErecv(&cmd, ¶m)) break; - dEXEC("glMultMatrix3x3", 0x1A, cmd); - mtxTemporal[i] = (s32)param; - } - - vector_fix2float<3>(mtxTemporal, 4096.f); - - //fill in the unusued matrix values - mtxTemporal[3] = mtxTemporal[7] = mtxTemporal[11] = 0; - mtxTemporal[15] = 1; - mtxTemporal[12] = mtxTemporal[13] = mtxTemporal[14] = 0; - - MatrixMultiply (mtxCurrent[mode], mtxTemporal); - - GFX_DELAY(28); - - if (mode == 2) - { - MatrixMultiply (mtxCurrent[1], mtxTemporal); - GFX_DELAY_M2(30); - } - - //does this really need to be done? - MatrixIdentity (mtxTemporal); -} - -void FORCEINLINE gfx3d_glScale(s32 v) -{ - u8 cmd = 0; - u32 param = 0; - - scale[0] = fix2float(v); - - if (!GFX_PIPErecv(&cmd, ¶m)) return; - dEXEC("glScale", 0x1B, cmd); - scale[1] = fix2float((s32)param); - - if (!GFX_PIPErecv(&cmd, ¶m)) return; - dEXEC("glScale", 0x1B, cmd); - scale[2] = fix2float((s32)param); - - MatrixScale (mtxCurrent[(mode==2?1:mode)], scale); - - GFX_DELAY(22); - - //note: pos-vector mode should not cause both matrices to scale. - //the whole purpose is to keep the vector matrix orthogonal - //so, I am leaving this commented out as an example of what not to do. - //if (mode == 2) - // MatrixScale (mtxCurrent[1], scale); -} - -void FORCEINLINE gfx3d_glTranslate(s32 v) -{ - u8 cmd = 0; - u32 param = 0; - - trans[0] = fix2float(v); - - if (!GFX_PIPErecv(&cmd, ¶m)) return; - dEXEC("glTranslate", 0x1C, cmd); - trans[1] = fix2float((s32)param); - - if (!GFX_PIPErecv(&cmd, ¶m)) return; - dEXEC("glTranslate", 0x1C, cmd); - trans[2] = fix2float((s32)param); - - MatrixTranslate (mtxCurrent[mode], trans); - - GFX_DELAY(22); - - if (mode == 2) - { - MatrixTranslate (mtxCurrent[1], trans); - GFX_DELAY_M2(30); - } -} - -void FORCEINLINE gfx3d_glColor3b(u32 v) -{ - colorRGB[0] = (v&0x1F); - colorRGB[1] = ((v>>5)&0x1F); - colorRGB[2] = ((v>>10)&0x1F); + texturePalette = val; GFX_DELAY(1); } -void FORCEINLINE gfx3d_glNormal(u32 v) -{ - int i,c; - ALIGN(16) float normal[4] = { normalTable[v&1023], - normalTable[(v>>10)&1023], - normalTable[(v>>20)&1023], - 1}; - - if (texCoordinateTransform == 2) - { - last_s =( (normal[0] *mtxCurrent[3][0] + normal[1] *mtxCurrent[3][4] + - normal[2] *mtxCurrent[3][8]) + (_s*16.0f)) / 16.0f; - last_t =( (normal[0] *mtxCurrent[3][1] + normal[1] *mtxCurrent[3][5] + - normal[2] *mtxCurrent[3][9]) + (_t*16.0f)) / 16.0f; - } - - //use the current normal transform matrix - MatrixMultVec3x3 (mtxCurrent[2], normal); - - //apply lighting model - { - u8 diffuse[3] = { - (dsDiffuse)&0x1F, - (dsDiffuse>>5)&0x1F, - (dsDiffuse>>10)&0x1F }; - - u8 ambient[3] = { - (dsAmbient)&0x1F, - (dsAmbient>>5)&0x1F, - (dsAmbient>>10)&0x1F }; - - u8 emission[3] = { - (dsEmission)&0x1F, - (dsEmission>>5)&0x1F, - (dsEmission>>10)&0x1F }; - - u8 specular[3] = { - (dsSpecular)&0x1F, - (dsSpecular>>5)&0x1F, - (dsSpecular>>10)&0x1F }; - - int vertexColor[3] = { emission[0], emission[1], emission[2] }; - - for(i=0; i<4; i++) - { - if(!((lightMask>>i)&1)) continue; - - u8 _lightColor[3] = { - (lightColor[i])&0x1F, - (lightColor[i]>>5)&0x1F, - (lightColor[i]>>10)&0x1F }; - - /* This formula is the one used by the DS */ - /* Reference : http://nocash.emubase.de/gbatek.htm#ds3dpolygonlightparameters */ - - float diffuseLevel = std::max(0.0f, -vec3dot(cacheLightDirection[i], normal)); - float shininessLevel = pow(std::max(0.0f, vec3dot(-cacheHalfVector[i], normal)), 2); - - if(dsSpecular & 0x8000) - { - int shininessIndex = (int)(shininessLevel * 128); - if(shininessIndex >= (int)ARRAY_SIZE(shininessTable)) { - //we can't print this right now, because when a game triggers this it triggers it _A_LOT_ - //so wait until we have per-frame diagnostics. - //this was tested using Princess Debut (US) after proceeding through the intro and getting the tiara. - //After much research, I determined that this was caused by the game feeding in a totally jacked matrix - //to mult4x4 from 0x02129B80 (after feeding two other valid matrices) - //the game seems to internally index these as: ?, 0x37, 0x2B <-- error - //but, man... this is seriously messed up. there must be something going wrong. - //maybe it has something to do with what looks like a mirror room effect that is going on during this time? - //PROGINFO("ERROR: shininess table out of bounds.\n maybe an emulator error; maybe a non-unit normal; setting to 0\n"); - shininessIndex = 0; - } - shininessLevel = shininessTable[shininessIndex]; - } - - for(c = 0; c < 3; c++) - { - vertexColor[c] += (int)(((specular[c] * _lightColor[c] * shininessLevel) - + (diffuse[c] * _lightColor[c] * diffuseLevel) - + (ambient[c] * _lightColor[c])) / 31.0f); - } - } - - for(c=0;c<3;c++) - colorRGB[c] = std::min(31,vertexColor[c]); - } - - GFX_DELAY(9); - GFX_DELAY_M2((lightMask) & 0x01); - GFX_DELAY_M2((lightMask>>1) & 0x01); - GFX_DELAY_M2((lightMask>>2) & 0x01); - GFX_DELAY_M2((lightMask>>3) & 0x01); -} - -void FORCEINLINE gfx3d_glTexCoord(u32 val) +void gfx3d_glTexCoord(u32 val) { _t = (s16)(val>>16); _s = (s16)(val&0xFFFF); @@ -1025,516 +1089,7 @@ void FORCEINLINE gfx3d_glTexCoord(u32 val) GFX_DELAY(1); } -void FORCEINLINE gfx3d_glVertex16b(unsigned int v) -{ - u8 cmd = 0; - u32 param = 0; - - coord[0] = float16table[v&0xFFFF]; - coord[1] = float16table[v>>16]; - - //if (gxPIPE.cmd[0] != 0x23) return; - if (!GFX_PIPErecv(&cmd, ¶m)) return; - dEXEC("glVertex16b", 0x23, cmd); - coord[2] = float16table[param&0xFFFF]; - - SetVertex (); - - GFX_DELAY(9); -} - -void FORCEINLINE gfx3d_glVertex10b(u32 v) -{ - coord[0] = float10Table[v&1023]; - coord[1] = float10Table[(v>>10)&1023]; - coord[2] = float10Table[(v>>20)&1023]; - - GFX_DELAY(8); - SetVertex (); -} - -void FORCEINLINE gfx3d_glVertex3_cord(unsigned int one, unsigned int two, unsigned int v) -{ - coord[one] = float16table[v&0xffff]; - coord[two] = float16table[v>>16]; - - SetVertex (); - - GFX_DELAY(8); -} - -void FORCEINLINE gfx3d_glVertex_rel(u32 v) -{ - coord[0] += float10RelTable[v&1023]; - coord[1] += float10RelTable[(v>>10)&1023]; - coord[2] += float10RelTable[(v>>20)&1023]; - - SetVertex (); - - GFX_DELAY(8); -} - -void FORCEINLINE gfx3d_glPolygonAttrib (u32 val) -{ - if(inBegin) { - //PROGINFO("Set polyattr in the middle of a begin/end pair.\n (This won't be activated until the next begin)\n"); - //TODO - we need some some similar checking for teximageparam etc. - } - polyAttrPending = val; - GFX_DELAY(1); -} - -void FORCEINLINE gfx3d_glTexImage(u32 val) -{ - textureFormat = val; - gfx3d_glTexImage_cache(); - GFX_DELAY(1); -} - -void FORCEINLINE gfx3d_glTexPalette(u32 val) -{ - texturePalette = val; - GFX_DELAY(1); -} - -/* - 0-4 Diffuse Reflection Red - 5-9 Diffuse Reflection Green - 10-14 Diffuse Reflection Blue - 15 Set Vertex Color (0=No, 1=Set Diffuse Reflection Color as Vertex Color) - 16-20 Ambient Reflection Red - 21-25 Ambient Reflection Green - 26-30 Ambient Reflection Blue -*/ -void FORCEINLINE gfx3d_glMaterial0(u32 val) -{ - dsDiffuse = val&0xFFFF; - dsAmbient = val>>16; - - if (BIT15(val)) - { - colorRGB[0] = (val)&0x1F; - colorRGB[1] = (val>>5)&0x1F; - colorRGB[2] = (val>>10)&0x1F; - } - GFX_DELAY(4); -} - -void FORCEINLINE gfx3d_glMaterial1(u32 val) -{ - dsSpecular = val&0xFFFF; - dsEmission = val>>16; - GFX_DELAY(4); -} - -/* - 0-9 Directional Vector's X component (1bit sign + 9bit fractional part) - 10-19 Directional Vector's Y component (1bit sign + 9bit fractional part) - 20-29 Directional Vector's Z component (1bit sign + 9bit fractional part) - 30-31 Light Number (0..3) -*/ -void FORCEINLINE gfx3d_glLightDirection (u32 v) -{ - int index = v>>30; - - lightDirection[index] = v; - gfx3d_glLightDirection_cache(index); - GFX_DELAY(6); -} - -void FORCEINLINE gfx3d_glLightColor (u32 v) -{ - int index = v>>30; - lightColor[index] = v; - GFX_DELAY(1); -} - -void FORCEINLINE gfx3d_glShininess (u32 val) -{ - u8 cmd = 0; - u32 param = 0; - - shininessTable[0] = ((val & 0xFF) / 256.0f); - shininessTable[1] = (((val >> 8) & 0xFF) / 256.0f); - shininessTable[2] = (((val >> 16) & 0xFF) / 256.0f); - shininessTable[3] = (((val >> 24) & 0xFF) / 256.0f); - - for (int i = 4; i < 128; i+=4) - { - if (!GFX_PIPErecv(&cmd, ¶m)) return; - dEXEC("glShininess", 0x34, cmd); - shininessTable[i] = ((param & 0xFF) / 256.0f); - shininessTable[i+1] = (((param >> 8) & 0xFF) / 256.0f); - shininessTable[i+2] = (((param >> 16) & 0xFF) / 256.0f); - shininessTable[i+3] = (((param >> 24) & 0xFF) / 256.0f); - } - - GFX_DELAY(32); -} - -void FORCEINLINE gfx3d_glBegin(u32 v) -{ - inBegin = TRUE; - vtxFormat = v&0x03; - triStripToggle = 0; - tempVertInfo.count = 0; - tempVertInfo.first = true; - polyAttr = polyAttrPending; - gfx3d_glPolygonAttrib_cache(); - GFX_DELAY(1); -} - -void FORCEINLINE gfx3d_glEnd(void) -{ - inBegin = FALSE; - tempVertInfo.count = 0; - GFX_DELAY(1); -} - -// swap buffers - skipped - -void FORCEINLINE gfx3d_glViewPort(u32 v) -{ - viewport = v; - GFX_DELAY(1); -} - -void FORCEINLINE gfx3d_glBoxTest(u32 v) -{ - u8 cmd = 0; - u32 param = 0; - u32 gxstat = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x600); - - if (!GFX_PIPErecv(&cmd, ¶m)) return; - dEXEC("glBoxTest", 0x70, cmd); - if (!GFX_PIPErecv(&cmd, ¶m)) return; - dEXEC("glBoxTest", 0x70, cmd); - - GFX_DELAY(103); - - gxstat &= 0xFFFFFFFE; // clear busy bit - gxstat |= 0x00000002; // hack - T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x600, gxstat); -} - -void FORCEINLINE gfx3d_glPosTest(u32 v) -{ - u8 cmd = 0; - u32 param = 0; - u32 gxstat = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x600); - - PTcoords[0] = float16table[v & 0xFFFF]; - PTcoords[1] = float16table[v >> 16]; - - if (!GFX_PIPErecv(&cmd, ¶m)) return; - dEXEC("glPosTest", 0x71, cmd); - PTcoords[2] = float16table[param & 0xFFFF]; - PTcoords[3] = 1.0f; - - MatrixMultVec4x4_M2(mtxCurrent[0], PTcoords); - - gxstat &= 0xFFFFFFFE; // cleay busy bit - T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x600, gxstat); - - GFX_DELAY(9); -} - -void FORCEINLINE gfx3d_glVecTest(u32 v) -{ - u32 gxstat = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x600); - gxstat &= 0xFFFFFFFE; - T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x600, gxstat); - - GFX_DELAY(5); - //INFO("NDS_glVecTest\n"); -} -#else // else not USE_GEOMETRY_FIFO_EMULATION - -void gfx3d_glMatrixMode(u32 v) -{ - mode = (v&3); - - GFX_DELAY(1); -} - -void gfx3d_glPushMatrix() -{ - u32 gxstat = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x600); - //this command always works on both pos and vector when either pos or pos-vector are the current mtx mode - short mymode = (mode==1?2:mode); - - if (mtxStack[mymode].position > mtxStack[mymode].size) - { - gxstat |= (1<<15); - T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x600, gxstat); - return; - } - - gxstat &= 0xFFFF00FF; - - MatrixStackPushMatrix(&mtxStack[mymode], mtxCurrent[mymode]); - - GFX_DELAY(17); - - if(mymode==2) - MatrixStackPushMatrix (&mtxStack[1], mtxCurrent[1]); - - gxstat |= ((mtxStack[0].position << 13) | (mtxStack[1].position << 8)); - T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x600, gxstat); -} - -void gfx3d_glPopMatrix(s32 i) -{ - u32 gxstat = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x600); - - //this command always works on both pos and vector when either pos or pos-vector are the current mtx mode - short mymode = (mode==1?2:mode); - - /* - if (i > mtxStack[mymode].position) - { - gxstat |= (1<<15); - T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x600, gxstat); - return; - } - */ - gxstat &= 0xFFFF00FF; - - MatrixCopy(mtxCurrent[mymode], MatrixStackPopMatrix (&mtxStack[mymode], i)); - - GFX_DELAY(36); - - if (mymode == 2) - MatrixCopy(mtxCurrent[1], MatrixStackPopMatrix (&mtxStack[1], i)); - - gxstat |= ((mtxStack[0].position << 13) | (mtxStack[1].position << 8)); - T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x600, gxstat); -} - -void gfx3d_glStoreMatrix(u32 v) -{ - //this command always works on both pos and vector when either pos or pos-vector are the current mtx mode - short mymode = (mode==1?2:mode); - - //limit height of these stacks. - //without the mymode==3 namco classics galaxian will try to use pos=1 and overrun the stack, corrupting emu - if(mymode==0 || mymode==3) - v = 0; - - if(v==31) v=30; //? what should happen in this case? - - MatrixStackLoadMatrix (&mtxStack[mymode], v&31, mtxCurrent[mymode]); - - GFX_DELAY(17); - - if(mymode==2) - MatrixStackLoadMatrix (&mtxStack[1], v&31, mtxCurrent[1]); -} - -void gfx3d_glRestoreMatrix(u32 v) -{ - //this command always works on both pos and vector when either pos or pos-vector are the current mtx mode - short mymode = (mode==1?2:mode); - - //limit height of these stacks - //without the mymode==3 namco classics galaxian will try to use pos=1 and overrun the stack, corrupting emu - if(mymode==0 || mymode==3) - v = 0; - - if(v==31) v=30; //? what should happen in this case? - - MatrixCopy (mtxCurrent[mymode], MatrixStackGetPos(&mtxStack[mymode], v&31)); - - GFX_DELAY(36); - - if (mymode == 2) - MatrixCopy (mtxCurrent[1], MatrixStackGetPos(&mtxStack[1], v&31)); -} - -void gfx3d_glLoadIdentity() -{ - MatrixIdentity (mtxCurrent[mode]); - - GFX_DELAY(19); - - if (mode == 2) - MatrixIdentity (mtxCurrent[1]); -} - -BOOL gfx3d_glLoadMatrix4x4(s32 v) -{ - mtxCurrent[mode][ML4x4ind] = (float)v; - - ++ML4x4ind; - if(ML4x4ind<16) return FALSE; - ML4x4ind = 0; - - GFX_DELAY(19); - - vector_fix2float<4>(mtxCurrent[mode], 4096.f); - - if (mode == 2) - MatrixCopy (mtxCurrent[1], mtxCurrent[2]); - return TRUE; -} - -BOOL gfx3d_glLoadMatrix4x3(s32 v) -{ - mtxCurrent[mode][ML4x3ind] = (float)v; - - ML4x3ind++; - if((ML4x3ind & 0x03) == 3) ML4x3ind++; - if(ML4x3ind<16) return FALSE; - ML4x3ind = 0; - - vector_fix2float<4>(mtxCurrent[mode], 4096.f); - - //fill in the unusued matrix values - mtxCurrent[mode][3] = mtxCurrent[mode][7] = mtxCurrent[mode][11] = 0.f; - mtxCurrent[mode][15] = 1.f; - - GFX_DELAY(30); - - if (mode == 2) - MatrixCopy (mtxCurrent[1], mtxCurrent[2]); - return TRUE; -} - -BOOL gfx3d_glMultMatrix4x4(s32 v) -{ - mtxTemporal[MM4x4ind] = (float)v; - - MM4x4ind++; - if(MM4x4ind<16) return FALSE; - MM4x4ind = 0; - - GFX_DELAY(35); - - vector_fix2float<4>(mtxTemporal, 4096.f); - - MatrixMultiply (mtxCurrent[mode], mtxTemporal); - - if (mode == 2) - { - MatrixMultiply (mtxCurrent[1], mtxTemporal); - GFX_DELAY_M2(30); - } - - MatrixIdentity (mtxTemporal); - return TRUE; -} - -BOOL gfx3d_glMultMatrix4x3(s32 v) -{ - mtxTemporal[MM4x3ind] = (float)v; - - MM4x3ind++; - if((MM4x3ind & 0x03) == 3) MM4x3ind++; - if(MM4x3ind<16) return FALSE; - MM4x3ind = 0; - - GFX_DELAY(31); - - vector_fix2float<4>(mtxTemporal, 4096.f); - - //fill in the unusued matrix values - mtxTemporal[3] = mtxTemporal[7] = mtxTemporal[11] = 0.f; - mtxTemporal[15] = 1.f; - - MatrixMultiply (mtxCurrent[mode], mtxTemporal); - - if (mode == 2) - { - MatrixMultiply (mtxCurrent[1], mtxTemporal); - GFX_DELAY_M2(30); - } - - //does this really need to be done? - MatrixIdentity (mtxTemporal); - return TRUE; -} - -BOOL gfx3d_glMultMatrix3x3(s32 v) -{ - mtxTemporal[MM3x3ind] = (float)v; - - - MM3x3ind++; - if((MM3x3ind & 0x03) == 3) MM3x3ind++; - if(MM3x3ind<12) return FALSE; - MM3x3ind = 0; - - GFX_DELAY(28); - - vector_fix2float<3>(mtxTemporal, 4096.f); - - //fill in the unusued matrix values - mtxTemporal[3] = mtxTemporal[7] = mtxTemporal[11] = 0; - mtxTemporal[15] = 1; - mtxTemporal[12] = mtxTemporal[13] = mtxTemporal[14] = 0; - - MatrixMultiply (mtxCurrent[mode], mtxTemporal); - - if (mode == 2) - { - MatrixMultiply (mtxCurrent[1], mtxTemporal); - GFX_DELAY_M2(30); - } - - //does this really need to be done? - MatrixIdentity (mtxTemporal); - return TRUE; -} - -BOOL gfx3d_glScale(s32 v) -{ - scale[scaleind] = fix2float(v); - - ++scaleind; - - if(scaleind<3) return FALSE; - scaleind = 0; - - MatrixScale (mtxCurrent[(mode==2?1:mode)], scale); - - GFX_DELAY(22); - - //note: pos-vector mode should not cause both matrices to scale. - //the whole purpose is to keep the vector matrix orthogonal - //so, I am leaving this commented out as an example of what not to do. - //if (mode == 2) - // MatrixScale (mtxCurrent[1], scale); - return TRUE; -} - -BOOL gfx3d_glTranslate(s32 v) -{ - trans[transind] = fix2float(v); - - ++transind; - - if(transind<3) return FALSE; - transind = 0; - - MatrixTranslate (mtxCurrent[mode], trans); - - GFX_DELAY(22); - - if (mode == 2) - { - MatrixTranslate (mtxCurrent[1], trans); - GFX_DELAY_M2(30); - } - return TRUE; -} - -void gfx3d_glColor3b(u32 v) -{ - colorRGB[0] = (v&0x1F); - colorRGB[1] = ((v>>5)&0x1F); - colorRGB[2] = ((v>>10)&0x1F); - GFX_DELAY(1); -} +#define vec3dot(a, b) (((a[0]) * (b[0])) + ((a[1]) * (b[1])) + ((a[2]) * (b[2]))) void gfx3d_glNormal(u32 v) { @@ -1631,131 +1186,42 @@ void gfx3d_glNormal(u32 v) GFX_DELAY_M2((lightMask>>3) & 0x01); } -void gfx3d_glTexCoord(u32 val) + +s32 gfx3d_GetClipMatrix (unsigned int index) { - _t = (s16)(val>>16); - _s = (s16)(val&0xFFFF); + float val = MatrixGetMultipliedIndex (index, mtxCurrent[0], mtxCurrent[1]); - _s /= 16.0f; - _t /= 16.0f; + val *= (1<<12); - if (texCoordinateTransform == 1) + return (s32)val; +} + +s32 gfx3d_GetDirectionalMatrix (unsigned int index) +{ + int _index = (((index / 3) * 4) + (index % 3)); + + return (s32)(mtxCurrent[2][_index]*(1<<12)); +} + +static void gfx3d_glLightDirection_cache(int index) +{ + u32 v = lightDirection[index]; + + // Convert format into floating point value + cacheLightDirection[index][0] = normalTable[v&1023]; + cacheLightDirection[index][1] = normalTable[(v>>10)&1023]; + cacheLightDirection[index][2] = normalTable[(v>>20)&1023]; + cacheLightDirection[index][3] = 0; + + /* Multiply the vector by the directional matrix */ + MatrixMultVec3x3(mtxCurrent[2], cacheLightDirection[index]); + + /* Calculate the half vector */ + float lineOfSight[4] = {0.0f, 0.0f, -1.0f, 0.0f}; + for(int i = 0; i < 4; i++) { - last_s =_s*mtxCurrent[3][0] + _t*mtxCurrent[3][4] + - 0.0625f*mtxCurrent[3][8] + 0.0625f*mtxCurrent[3][12]; - last_t =_s*mtxCurrent[3][1] + _t*mtxCurrent[3][5] + - 0.0625f*mtxCurrent[3][9] + 0.0625f*mtxCurrent[3][13]; + cacheHalfVector[index][i] = ((cacheLightDirection[index][i] + lineOfSight[i]) / 2.0f); } - else - { - last_s=_s; - last_t=_t; - } - GFX_DELAY(1); -} - -BOOL gfx3d_glVertex16b(unsigned int v) -{ - if(coordind==0) - { - coord[0] = float16table[v&0xFFFF]; - coord[1] = float16table[v>>16]; - - ++coordind; - return FALSE; - } - - coord[2] = float16table[v&0xFFFF]; - - coordind = 0; - SetVertex (); - - GFX_DELAY(9); - return TRUE; -} - -void gfx3d_glVertex10b(u32 v) -{ - coord[0] = float10Table[v&1023]; - coord[1] = float10Table[(v>>10)&1023]; - coord[2] = float10Table[(v>>20)&1023]; - - GFX_DELAY(8); - SetVertex (); -} - -void gfx3d_glVertex3_cord(unsigned int one, unsigned int two, unsigned int v) -{ - coord[one] = float16table[v&0xffff]; - coord[two] = float16table[v>>16]; - - SetVertex (); - - GFX_DELAY(8); -} - -void gfx3d_glVertex_rel(u32 v) -{ - coord[0] += float10RelTable[v&1023]; - coord[1] += float10RelTable[(v>>10)&1023]; - coord[2] += float10RelTable[(v>>20)&1023]; - - SetVertex (); - - GFX_DELAY(8); -} - -void gfx3d_glPolygonAttrib (u32 val) -{ - if(inBegin) { - //PROGINFO("Set polyattr in the middle of a begin/end pair.\n (This won't be activated until the next begin)\n"); - //TODO - we need some some similar checking for teximageparam etc. - } - polyAttrPending = val; - GFX_DELAY(1); -} - -void gfx3d_glTexImage(u32 val) -{ - textureFormat = val; - gfx3d_glTexImage_cache(); - GFX_DELAY(1); -} - -void gfx3d_glTexPalette(u32 val) -{ - texturePalette = val; - GFX_DELAY(1); -} - -/* - 0-4 Diffuse Reflection Red - 5-9 Diffuse Reflection Green - 10-14 Diffuse Reflection Blue - 15 Set Vertex Color (0=No, 1=Set Diffuse Reflection Color as Vertex Color) - 16-20 Ambient Reflection Red - 21-25 Ambient Reflection Green - 26-30 Ambient Reflection Blue -*/ -void gfx3d_glMaterial0(u32 val) -{ - dsDiffuse = val&0xFFFF; - dsAmbient = val>>16; - - if (BIT15(val)) - { - colorRGB[0] = (val)&0x1F; - colorRGB[1] = (val>>5)&0x1F; - colorRGB[2] = (val>>10)&0x1F; - } - GFX_DELAY(4); -} - -void gfx3d_glMaterial1(u32 val) -{ - dsSpecular = val&0xFFFF; - dsEmission = val>>16; - GFX_DELAY(4); } /* @@ -1780,44 +1246,9 @@ void gfx3d_glLightColor (u32 v) GFX_DELAY(1); } -BOOL gfx3d_glShininess (u32 val) +void gfx3d_glAlphaFunc(u32 v) { - shininessTable[shininessInd++] = ((val & 0xFF) / 256.0f); - shininessTable[shininessInd++] = (((val >> 8) & 0xFF) / 256.0f); - shininessTable[shininessInd++] = (((val >> 16) & 0xFF) / 256.0f); - shininessTable[shininessInd++] = (((val >> 24) & 0xFF) / 256.0f); - - if (shininessInd < 128) return FALSE; - shininessInd = 0; - GFX_DELAY(32); - return TRUE; -} - -void gfx3d_glBegin(u32 v) -{ - inBegin = TRUE; - vtxFormat = v&0x03; - triStripToggle = 0; - tempVertInfo.count = 0; - tempVertInfo.first = true; - polyAttr = polyAttrPending; - gfx3d_glPolygonAttrib_cache(); - GFX_DELAY(1); -} - -void gfx3d_glEnd(void) -{ - inBegin = FALSE; - tempVertInfo.count = 0; - GFX_DELAY(1); -} - -// swap buffers - skipped - -void gfx3d_glViewPort(u32 v) -{ - viewport = v; - GFX_DELAY(1); + gfx3d.alphaTestRef = v&31; } BOOL gfx3d_glBoxTest(u32 v) @@ -1960,93 +1391,6 @@ void gfx3d_glVecTest(u32 v) //INFO("NDS_glVecTest\n"); } -#endif -//================================================================================= Geometry Engine -//================================================================================= (end) -//================================================================================= - -void VIEWPORT::decode(u32 v) -{ - x = (v&0xFF); - y = std::min(191,(int)(((v>>8)&0xFF))); - width = (((v>>16)&0xFF)+1)-(v&0xFF); - height = ((v>>24)+1)-((v>>8)&0xFF); -} - -void gfx3d_glClearColor(u32 v) -{ - gfx3d.clearColor = v; - -} - -void gfx3d_glFogColor(u32 v) -{ - gfx3d.fogColor[0] = ((float)((v )&0x1F))/31.0f; - gfx3d.fogColor[1] = ((float)((v>> 5)&0x1F))/31.0f; - gfx3d.fogColor[2] = ((float)((v>>10)&0x1F))/31.0f; - gfx3d.fogColor[3] = ((float)((v>>16)&0x1F))/31.0f; -} - -void gfx3d_glFogOffset (u32 v) -{ - gfx3d.fogOffset = (float)(v&0xffff); -} - -void gfx3d_glClearDepth(u32 v) -{ - v &= 0x7FFF; - gfx3d.clearDepth = gfx3d_extendDepth_15_to_24(v); -} - -// Ignored for now -void gfx3d_glSwapScreen(unsigned int screen) -{ -} - -int gfx3d_GetNumPolys() -{ - //so is this in the currently-displayed or currently-built list? - return (polylists[listTwiddle].count); -} - -int gfx3d_GetNumVertex() -{ - //so is this in the currently-displayed or currently-built list? - return (vertlists[listTwiddle].count); -} - -void gfx3d_UpdateToonTable(u8 offset, u16 val) -{ - gfx3d.u16ToonTable[offset] = val; -} - -void gfx3d_UpdateToonTable(u8 offset, u32 val) -{ - gfx3d.u16ToonTable[offset] = val & 0xFFFF; - gfx3d.u16ToonTable[offset+1] = val >> 8; -} - -s32 gfx3d_GetClipMatrix (unsigned int index) -{ - float val = MatrixGetMultipliedIndex (index, mtxCurrent[0], mtxCurrent[1]); - - val *= (1<<12); - - return (s32)val; -} - -s32 gfx3d_GetDirectionalMatrix (unsigned int index) -{ - int _index = (((index / 3) * 4) + (index % 3)); - - return (s32)(mtxCurrent[2][_index]*(1<<12)); -} - -void gfx3d_glAlphaFunc(u32 v) -{ - gfx3d.alphaTestRef = v&31; -} - unsigned int gfx3d_glGetPosRes(unsigned int index) { return (unsigned int)(PTcoords[index] * 4096.0f); @@ -2061,7 +1405,7 @@ unsigned short gfx3d_glGetVecRes(unsigned int index) #ifdef USE_GEOMETRY_FIFO_EMULATION //#define _3D_LOG_EXEC -void FORCEINLINE gfx3d_execute(u8 cmd, u32 param) +void gfx3d_execute(u8 cmd, u32 param) { #ifdef _3D_LOG_EXEC u32 gxstat2 = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x600); @@ -2182,9 +1526,8 @@ void FORCEINLINE gfx3d_execute(u8 cmd, u32 param) break; default: INFO("Unknown execute FIFO 3D command 0x%02X with param 0x%08X\n", cmd, param); - return; + break; } - NDS_RescheduleGXFIFO(); } void gfx3d_execute3D() @@ -2192,58 +1535,48 @@ void gfx3d_execute3D() u8 cmd = 0; u32 param = 0; - if (isSwapBuffers) return; + //if (isSwapBuffers) return; - u16 size = gxPIPE.tail + gxFIFO.tail; - //if (size == 0) return; - - switch (gxPIPE.cmd[0]) - { - case 0x34: // SHININESS - Specular Reflection Shininess Table (W) - if (size < 32) return; - break; - - case 0x16: // MTX_LOAD_4x4 - Load 4x4 Matrix to Current Matrix (W) - case 0x18: // MTX_MULT_4x4 - Multiply Current Matrix by 4x4 Matrix (W) - if (size < 16) return; - break; - - case 0x17: // MTX_LOAD_4x3 - Load 4x3 Matrix to Current Matrix (W) - case 0x19: // MTX_MULT_4x3 - Multiply Current Matrix by 4x3 Matrix (W) - if (size < 12) return; - break; - - case 0x1A: // MTX_MULT_3x3 - Multiply Current Matrix by 3x3 Matrix (W) - if (size < 9) return; - break; - - case 0x1B: // MTX_SCALE - Multiply Current Matrix by Scale Matrix (W) - case 0x1C: // MTX_TRANS - Mult. Curr. Matrix by Translation Matrix (W) - case 0x70: // BOX_TEST - Test if Cuboid Sits inside View Volume (W) - if (size < 3) return; - break; - - case 0x23: // VTX_16 - Set Vertex XYZ Coordinates (W) - case 0x71: // POS_TEST - Set Position Coordinates for Test (W) - if (size < 2) return; - break; - } - - if (GFX_PIPErecv(&cmd, ¶m)) + if (GFX_FIFOrecv(&cmd, ¶m)) { gfx3d_execute(cmd, param); +#if 0 + for ( ;;) + { + if ( (cmd == 0x11) || (cmd==0x15) || (cmd==41) ) + { + if (!GFX_FIFOrecv(&cmd, ¶m)) return; + gfx3d_execute(cmd, param); + continue; + } + break; + } +#endif +#if 0 + if (bWaitForPolys) + { + //INFO("Error: incompleted polylist\n"); + if (polygonListCompleted == 1) + { + gfx3d_doFlush(); + isSwapBuffers = true; + bWaitForPolys = false; + } + } +#endif } } #endif void gfx3d_glFlush(u32 v) { - -#ifdef USE_GEOMETRY_FIFO_EMULATION + flushPending = TRUE; gfx3d.sortmode = BIT0(v); gfx3d.wbuffer = BIT1(v); + +#ifdef USE_GEOMETRY_FIFO_EMULATION + #if 0 - if (polygonListCompleted == 2) { //u32 gxstat = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x600); @@ -2253,14 +1586,14 @@ void gfx3d_glFlush(u32 v) return; } #endif + + gfx3d_doFlush(); isSwapBuffers = true; + + //u32 gxstat = T1ReadLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x600); + //gxstat |= 0x08000000; // set busy flag + //T1WriteLong(MMU.MMU_MEM[ARMCPU_ARM9][0x40], 0x600, gxstat); #else - if(!flushPending) - { - gfx3d.sortmode = BIT0(v); - gfx3d.wbuffer = BIT1(v); - flushPending = TRUE; - } //see discussion at top of file if(CommonSettings.gfx3d_flushMode == 0) gfx3d_doFlush(); @@ -2291,46 +1624,29 @@ static void gfx3d_doFlush() gfx3d.frameCtr++; #ifndef USE_GEOMETRY_FIFO_EMULATION - GFX_PIPEclear(); GFX_FIFOclear(); // reset clInd = 0; clCmd = 0; #endif - //the renderer will get the lists we just built + //the renderer wil lget the lists we just built gfx3d.polylist = polylist; gfx3d.vertlist = vertlist; - //and also our current render state - if(BIT1(control)) gfx3d.shading = GFX3D::HIGHLIGHT; - else gfx3d.shading = GFX3D::TOON; - gfx3d.enableTexturing = BIT0(control); - gfx3d.enableAlphaTest = BIT2(control); - gfx3d.enableAlphaBlending = BIT3(control); - gfx3d.enableAntialiasing = BIT4(control); - gfx3d.enableEdgeMarking = BIT5(control); - gfx3d.enableClearImage = BIT14(control); - int polycount = polylist->count; //find the min and max y values for each poly. //TODO - this could be a small waste of time if we are manual sorting the translucent polys - //TODO - this _MUST_ be moved later in the pipeline, after clipping. - //the w-division here is just an approximation to fix the shop in harvest moon island of happiness for(int i=0; ilist[i]; - float verty = vertlist->list[poly.vertIndexes[0]].y; - float vertw = vertlist->list[poly.vertIndexes[0]].w; - verty = (verty+vertw)/(2*vertw); - poly.miny = poly.maxy = (verty+vertw)/(2*vertw); + float verty = 0.0f; + poly.miny = poly.maxy = vertlist->list[poly.vertIndexes[0]].y; for(int j=1; jlist[poly.vertIndexes[j]].y; - vertw = vertlist->list[poly.vertIndexes[j]].w; - verty = (verty+vertw)/(2*vertw); poly.miny = min(poly.miny, verty); poly.maxy = max(poly.maxy, verty); } @@ -2379,18 +1695,16 @@ void gfx3d_VBlankSignal() { #ifdef USE_GEOMETRY_FIFO_EMULATION isVBlank = true; - if (isSwapBuffers) + if (isSwapBuffers) { - //if (bWaitForPolys) return; - gfx3d_doFlush(); isSwapBuffers = false; + GFX_DELAY(392); } #else //the 3d buffers are swapped when a vblank begins. //so, if we have a redraw pending, now is a safe time to do it if(!flushPending) { - GFX_PIPEclear(); GFX_FIFOclear(); return; } @@ -2405,27 +1719,22 @@ void gfx3d_VBlankEndSignal(bool skipFrame) { #ifdef USE_GEOMETRY_FIFO_EMULATION isVBlank = false; - - if (!drawPending) return; - drawPending = FALSE; - if(skipFrame) + if (drawPending) { - GFX_DELAY(392); - NDS_RescheduleGXFIFO(); - return; - } - //if the null 3d core is chosen, then we need to clear out the 3d buffers to keep old data from being rendered - if(gpu3D == &gpu3DNull || !CommonSettings.showGpu.main) - { - memset(gfx3d_convertedScreen,0,sizeof(gfx3d_convertedScreen)); - memset(gfx3d_convertedScreen,0,sizeof(gfx3d_convertedAlpha)); - return; - } + drawPending = FALSE; - gpu3D->NDS_3D_Render(); - - GFX_DELAY(392); - NDS_RescheduleGXFIFO(); + //if the null 3d core is chosen, then we need to clear out the 3d buffers to keep old data from being rendered + if(gpu3D == &gpu3DNull || !CommonSettings.showGpu.main) + { + memset(gfx3d_convertedScreen,0,sizeof(gfx3d_convertedScreen)); + memset(gfx3d_convertedScreen,0,sizeof(gfx3d_convertedAlpha)); + } + else + { + if(CommonSettings.showGpu.main) + gpu3D->NDS_3D_Render(); + } + } #else //if we are skipping 3d frames then the 3d rendering will get held up here. //but, as soon as we quit skipping frames, the held-up 3d frame will render @@ -2482,7 +1791,7 @@ void gfx3d_sendCommandToFIFO(u32 val) return; } #ifdef _3D_LOG - INFO("gxFIFO: send 0x%02X: val=0x%08X, pipe %02i, fifo %03i\n", clCmd & 0xFF, val, gxPIPE.tail, gxFIFO.tail); + INFO("GFX FIFO: Send GFX 3D cmd 0x%02X to FIFO (0x%08X)\n", clCmd & 0xFF, val); #endif NOPARAMS(); @@ -2595,14 +1904,8 @@ void gfx3d_sendCommand(u32 cmd, u32 param) { cmd = (cmd & 0x01FF) >> 2; #ifdef _3D_LOG - INFO("gxFIFO: send 0x%02X: val=0x%08X, pipe %02i, fifo %03i (direct)\n", cmd, param, gxPIPE.tail, gxFIFO.tail); + INFO("GFX FIFO: Send GFX 3D cmd 0x%02X to FIFO (0x%08X) - DIRECT (%i)\n", cmd, param, nds.cycles); #endif -/* - if (gxFIFO.tail == 256) - { - INFO("gxFIFO: FIFO is full (0x%02X = 0x%08X)\n", cmd, param); - } -*/ switch (cmd) { @@ -2696,18 +1999,22 @@ static void NOPARAMS() void gfx3d_sendCommandToFIFO(u32 val) { - //friendly reminder: be careful to handle the case where several unpacked noparams commands get sent in a row! - if (clCmd == 0) { clCmd = val; - NOPARAMS(); return; } #ifdef _3D_LOG INFO("GFX FIFO: Send GFX 3D cmd 0x%02X to FIFO (0x%08X)\n", clCmd & 0xFF, val); #endif + NOPARAMS(); + if (clCmd == 0) + { + clCmd = val; + return; + } + switch (clCmd & 0xFF) { case 0x10: // MTX_MODE - Set Matrix Mode (W) @@ -3030,9 +2337,26 @@ void gfx3d_sendCommand(u32 cmd, u32 param) } #endif +static void gfx3d_Control_cache() +{ + u32 v = control; + + if(BIT1(v)) gfx3d.shading = GFX3D::HIGHLIGHT; + else gfx3d.shading = GFX3D::TOON; + + gfx3d.enableTexturing = BIT0(v); + gfx3d.enableAlphaTest = BIT2(v); + gfx3d.enableAlphaBlending = BIT3(v); + gfx3d.enableAntialiasing = BIT4(v); + gfx3d.enableEdgeMarking = BIT5(v); + gfx3d.enableClearImage = BIT14(v); +} + void gfx3d_Control(u32 v) { control = v; + gfx3d_Control_cache(); + } //-------------- @@ -3106,12 +2430,9 @@ SFORMAT SF_GFX3D[]={ { "GLBT", 4, 1, &BTind}, { "GLPT", 4, 1, &PTind}, { "GLPC", 4, 4, PTcoords}, - { "GFTA", 4, 1, &gxFIFO.tail}, - { "GFCM", 1, 257, &gxFIFO.cmd[0]}, - { "GFPM", 4, 257, &gxFIFO.param[0]}, - { "GPTA", 4, 1, &gxPIPE.tail}, - { "GPCM", 1, 5, &gxPIPE.cmd[0]}, - { "GPPM", 4, 5, &gxPIPE.param[0]}, + { "GLF9", 4, 1, &gxFIFO.tail}, + { "GLF9", 1, 261, &gxFIFO.cmd[0]}, + { "GLF9", 4, 261, &gxFIFO.param[0]}, { "GCOL", 1, 4, colorRGB}, { "GLCO", 4, 4, lightColor}, { "GLDI", 4, 4, lightDirection}, @@ -3179,6 +2500,7 @@ bool gfx3d_loadstate(std::istream* is, int size) gfx3d_glPolygonAttrib_cache(); gfx3d_glTexImage_cache(); + gfx3d_Control_cache(); gfx3d_glLightDirection_cache(0); gfx3d_glLightDirection_cache(1); gfx3d_glLightDirection_cache(2); diff --git a/desmume/src/gfx3d.h b/src/gfx3d.h similarity index 99% rename from desmume/src/gfx3d.h rename to src/gfx3d.h index b0711c745..09eb1c54a 100644 --- a/desmume/src/gfx3d.h +++ b/src/gfx3d.h @@ -245,63 +245,59 @@ extern CACHE_ALIGN u16 gfx3d_convertedScreen[256*192]; extern CACHE_ALIGN u8 gfx3d_convertedAlpha[256*192*2]; //see cpp for explanation of illogical *2 //GE commands: -#ifndef USE_GEOMETRY_FIFO_EMULATION -void gfx3d_glMatrixMode(u32 v); -void gfx3d_glPushMatrix(void); -void gfx3d_glPopMatrix(s32 i); -void gfx3d_glStoreMatrix(u32 v); -void gfx3d_glRestoreMatrix(u32 v); -void gfx3d_glLoadIdentity(); -BOOL gfx3d_glLoadMatrix4x4(s32 v); -BOOL gfx3d_glLoadMatrix4x3(s32 v); -BOOL gfx3d_glMultMatrix4x4(s32 v); -BOOL gfx3d_glMultMatrix3x3(s32 v); -BOOL gfx3d_glMultMatrix4x3(s32 v); -BOOL gfx3d_glScale(s32 v); -BOOL gfx3d_glTranslate(s32 v); -void gfx3d_glColor3b(u32 v); -void gfx3d_glNormal(u32 v); -void gfx3d_glTexCoord(u32 val); -BOOL gfx3d_glVertex16b(u32 v); -void gfx3d_glVertex10b(u32 v); -void gfx3d_glVertex3_cord(u32 one, u32 two, u32 v); -void gfx3d_glVertex_rel(u32 v); -void gfx3d_glPolygonAttrib (u32 val); -void gfx3d_glTexImage(u32 val); -void gfx3d_glTexPalette(u32 val); -void gfx3d_glMaterial0(u32 val); -void gfx3d_glMaterial1(u32 val); -void gfx3d_glLightDirection (u32 v); -void gfx3d_glLightColor (u32 v); -BOOL gfx3d_glShininess (u32 val); -void gfx3d_glBegin(u32 v); -void gfx3d_glEnd(void); -// SwapBuffers see follow void gfx3d_glViewPort(u32 v); -BOOL gfx3d_glBoxTest(u32 v); -BOOL gfx3d_glPosTest(u32 v); -void gfx3d_glVecTest(u32 v); -#endif -void gfx3d_glFlush(u32 v); -// end GE commands - void gfx3d_glClearColor(u32 v); void gfx3d_glFogColor(u32 v); void gfx3d_glFogOffset (u32 v); void gfx3d_glClearDepth(u32 v); +void gfx3d_glMatrixMode(u32 v); +void gfx3d_glLoadIdentity(); +BOOL gfx3d_glLoadMatrix4x4(s32 v); +BOOL gfx3d_glLoadMatrix4x3(s32 v); +void gfx3d_glStoreMatrix(u32 v); +void gfx3d_glRestoreMatrix(u32 v); +void gfx3d_glPushMatrix(void); +void gfx3d_glPopMatrix(s32 i); +BOOL gfx3d_glTranslate(s32 v); +BOOL gfx3d_glScale(s32 v); +BOOL gfx3d_glMultMatrix3x3(s32 v); +BOOL gfx3d_glMultMatrix4x3(s32 v); +BOOL gfx3d_glMultMatrix4x4(s32 v); +void gfx3d_glBegin(u32 v); +void gfx3d_glEnd(void); +void gfx3d_glColor3b(u32 v); +BOOL gfx3d_glVertex16b(u32 v); +void gfx3d_glVertex10b(u32 v); +void gfx3d_glVertex3_cord(u32 one, u32 two, u32 v); +void gfx3d_glVertex_rel(u32 v); void gfx3d_glSwapScreen(u32 screen); int gfx3d_GetNumPolys(); int gfx3d_GetNumVertex(); +void gfx3d_glPolygonAttrib (u32 val); +void gfx3d_glMaterial0(u32 val); +void gfx3d_glMaterial1(u32 val); +BOOL gfx3d_glShininess (u32 val); void gfx3d_UpdateToonTable(u8 offset, u16 val); void gfx3d_UpdateToonTable(u8 offset, u32 val); +void gfx3d_glTexImage(u32 val); +void gfx3d_glTexPalette(u32 val); +void gfx3d_glTexCoord(u32 val); +void gfx3d_glNormal(u32 v); s32 gfx3d_GetClipMatrix (u32 index); s32 gfx3d_GetDirectionalMatrix (u32 index); +void gfx3d_glLightDirection (u32 v); +void gfx3d_glLightColor (u32 v); void gfx3d_glAlphaFunc(u32 v); +BOOL gfx3d_glBoxTest(u32 v); +BOOL gfx3d_glPosTest(u32 v); +void gfx3d_glVecTest(u32 v); u32 gfx3d_glGetPosRes(u32 index); u16 gfx3d_glGetVecRes(u32 index); +void gfx3d_glFlush(u32 v); void gfx3d_VBlankSignal(); void gfx3d_VBlankEndSignal(bool skipFrame); void gfx3d_Control(u32 v); +u32 gfx3d_GetGXstatus(); #ifdef USE_GEOMETRY_FIFO_EMULATION void gfx3d_execute3D(); #endif diff --git a/desmume/src/gtk-glade/Makefile.am b/src/gtk-glade/Makefile.am similarity index 91% rename from desmume/src/gtk-glade/Makefile.am rename to src/gtk-glade/Makefile.am index 89ea3b516..877fa7f5b 100644 --- a/desmume/src/gtk-glade/Makefile.am +++ b/src/gtk-glade/Makefile.am @@ -2,7 +2,7 @@ SUBDIRS = doc include $(top_srcdir)/src/desmume.mk AM_CPPFLAGS += $(SDL_CFLAGS) $(GTKGLEXT_CFLAGS) $(LIBGLADE_CFLAGS) \ - $(GTHREAD_CFLAGS) $(ALSA_CFLAGS) -DDATADIR=\"$(gladedir)/\" \ + $(GTHREAD_CFLAGS) -DDATADIR=\"$(gladedir)/\" \ -DLOCALEDIR=\"$(localedir)\" AM_LDFLAGS += -rdynamic $(INTLLIBS) @@ -30,7 +30,7 @@ desmume_glade_SOURCES = \ desmume_glade_LDADD = ../libdesmume.a \ $(SDL_LIBS) $(GTKGLEXT_LIBS) $(LIBGLADE_LIBS) \ - $(GTHREAD_LIBS) $(ALSA_LIBS) $(LIBAGG_LIBS) + $(GTHREAD_LIBS) if HAVE_GDB_STUB desmume_glade_LDADD += ../gdbstub/libgdbstub.a endif diff --git a/desmume/src/gtk-glade/callbacks.cpp b/src/gtk-glade/callbacks.cpp old mode 100755 new mode 100644 similarity index 96% rename from desmume/src/gtk-glade/callbacks.cpp rename to src/gtk-glade/callbacks.cpp index bd5f5ee7a..f7eb5e269 --- a/desmume/src/gtk-glade/callbacks.cpp +++ b/src/gtk-glade/callbacks.cpp @@ -1,537 +1,531 @@ -/* callbacks.c - this file is part of DeSmuME - * - * Copyright (C) 2007 Damien Nozay (damdoum) - * Copyright (C) 2007 Pascal Giard (evilynux) - * Author: damdoum at users.sourceforge.net - * - * This file is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2, or (at your option) - * any later version. - * - * This file is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; see the file COPYING. If not, write to - * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -#include "callbacks.h" - -/* globals */ -int Frameskip = 0; -gboolean ScreenRightForce=FALSE; -gboolean ScreenRight=FALSE; -gboolean ScreenGap=FALSE; -gboolean ScreenNoGap=FALSE; -gboolean ScreenInvert=FALSE; - -/* ******** Savestate menu items handling ******** */ - -static void set_menuitem_label(GtkWidget * w, char * text ) -{ - GtkLabel * child; - - if ( GTK_BIN(w)->child ) - { - child = (GtkLabel*)GTK_BIN(w)->child; - gtk_label_set_text(child, text); - } -} - -static void clear_savestate_menu(const char * cb_name, u8 num) -{ - GtkWidget * w; - char cb[40]; - char text[40]; - - sprintf( cb, "%s%d", cb_name, num); - sprintf( text, _("State %d (empty)"), num); - w = glade_xml_get_widget(xml, cb); - set_menuitem_label( w, text ); -} - -static void update_savestate_menu(const char * cb_name, u8 num) -{ - GtkWidget * w; - char cb[40]; - - snprintf( cb, 39, "%s%d", cb_name, num); - w = glade_xml_get_widget(xml, cb); - set_menuitem_label( w, savestates[num-1].date ); -} - -static void update_savestates_menu() -{ - u8 i; - - for( i = 1; i <= NB_STATES; i++ ) - { - if( savestates[i-1].exists == TRUE ) - { - update_savestate_menu("loadstate", i); - update_savestate_menu("savestate", i); - } - else - { - clear_savestate_menu("loadstate", i); - clear_savestate_menu("savestate", i); - } - } -} - -static void update_savestate(u8 num) -{ - desmume_pause(); - savestate_slot(num); - update_savestate_menu("savestate", num); - update_savestate_menu("loadstate", num); - desmume_resume(); -} - -/* inline & protos */ - -inline void SET_SENSITIVE(const gchar *w, gboolean b) { - gtk_widget_set_sensitive( - glade_xml_get_widget(xml, w), TRUE); -} - -void enable_rom_features() { - scan_savestates(); - update_savestates_menu(); - SET_SENSITIVE("menu_exec", TRUE); - SET_SENSITIVE("menu_pause", TRUE); - SET_SENSITIVE("menu_reset", TRUE); - SET_SENSITIVE("wgt_Exec", TRUE); - SET_SENSITIVE("wgt_Reset", TRUE); -} - -static void MAINWINDOW_RESIZE() { - GtkWidget * spacer1 = glade_xml_get_widget(xml, "misc_sep3"); - GtkWidget * spacer2 = glade_xml_get_widget(xml, "misc_sep4"); - int dim1,dim2; - BOOL rotate = (ScreenRotate==90.0 || ScreenRotate==270.0 ); - - dim1 = dim2 = 66 * ScreenCoeff_Size[0]; - - /* sees whether we want a gap */ - if (!ScreenGap) dim1 = dim2 = -1; - - if (ScreenNoGap) { - gtk_widget_hide (spacer1); - gtk_widget_hide (spacer2); - } - else - { - gtk_widget_show (spacer1); - gtk_widget_show (spacer2); - } - - if (ScreenRight == rotate) { - if (ScreenRight) - dim2 = -1; - else - dim1 = -1; - } else { - dim1 = dim2 = -1; - } - gtk_widget_set_usize(spacer1, dim1, -1); - gtk_widget_set_usize(spacer2, -1, dim2); - gtk_window_resize ((GtkWindow*)pWindow,1,1); -} - -/* MENU FILE ***** ***** ***** ***** */ -void inline ADD_FILTER(GtkWidget * filech, const char * pattern, const char * name) { - GtkFileFilter *pFilter; - pFilter = gtk_file_filter_new(); - gtk_file_filter_add_pattern(pFilter, pattern); - gtk_file_filter_set_name(pFilter, name); - gtk_file_chooser_add_filter(GTK_FILE_CHOOSER(filech), pFilter); -} - -static void file_open() { - desmume_pause(); - - GtkWidget *pFileSelection; - GtkWidget *pParent; - gchar *sChemin; - - pParent = GTK_WIDGET(pWindow); - - /* Creating the selection window */ - pFileSelection = gtk_file_chooser_dialog_new(_("Open..."), - GTK_WINDOW(pParent), - GTK_FILE_CHOOSER_ACTION_OPEN, - GTK_STOCK_CANCEL, GTK_RESPONSE_CANCEL, - GTK_STOCK_OPEN, GTK_RESPONSE_OK, - NULL); - /* On limite les actions a cette fenetre */ - gtk_window_set_modal(GTK_WINDOW(pFileSelection), TRUE); - - ADD_FILTER(pFileSelection, "*.nds", _("Nds binary (.nds)")); - ADD_FILTER(pFileSelection, "*.ds.gba", _("Nds binary with loader (.ds.gba)")); - ADD_FILTER(pFileSelection, "*", _("All files")); - //ADD_FILTER(pFileSelection, "*.zip", "Nds zipped binary"); - - /* Affichage fenetre*/ - switch(gtk_dialog_run(GTK_DIALOG(pFileSelection))) - { - case GTK_RESPONSE_OK: - /* Recuperation du chemin */ - sChemin = gtk_file_chooser_get_filename(GTK_FILE_CHOOSER(pFileSelection)); - if(desmume_open((const char*)sChemin) < 0) - { - GtkWidget *pDialog = gtk_message_dialog_new(GTK_WINDOW(pFileSelection), - GTK_DIALOG_MODAL, - GTK_MESSAGE_ERROR, - GTK_BUTTONS_OK, - _("Unable to load :\n%s"), sChemin); - gtk_dialog_run(GTK_DIALOG(pDialog)); - gtk_widget_destroy(pDialog); - } else { - desmume_resume(); - enable_rom_features(); - } - - g_free(sChemin); - break; - default: - break; - } - gtk_widget_destroy(pFileSelection); -} - -void on_menu_open_activate (GtkMenuItem *menuitem, gpointer user_data) { file_open();} -void on_menu_quit_activate (GtkMenuItem *menuitem, gpointer user_data) { gtk_main_quit(); } - -#define SCREENS_PIXEL_SIZE 98304 - -static void Printscreen() -{ - GdkPixbuf *screenshot; - gchar *filename; - GError *error = NULL; - u8 *rgb; - static int seq = 0; - - rgb = (u8 *) malloc(SCREENS_PIXEL_SIZE*3); - if (!rgb) - return; - for (int i = 0; i < SCREENS_PIXEL_SIZE; i++) { - rgb[(i * 3) + 0] = ((*((u16 *)&GPU_screen[(i<<1)]) >> 0) & 0x1f) << 3; - rgb[(i * 3) + 1] = ((*((u16 *)&GPU_screen[(i<<1)]) >> 5) & 0x1f) << 3; - rgb[(i * 3) + 2] = ((*((u16 *)&GPU_screen[(i<<1)]) >> 10) & 0x1f) << 3; - } - - screenshot = gdk_pixbuf_new_from_data(rgb, - GDK_COLORSPACE_RGB, - FALSE, - 8, - 256, - 192*2, - 256*3, - NULL, - NULL); - - filename = g_strdup_printf("./desmume-screenshot-%d.png", seq); - gdk_pixbuf_save(screenshot, filename, "png", &error, NULL); - if (error) { - g_error_free (error); - g_printerr("Failed to save %s", filename); - } else { - seq++; - } - - free(rgb); - g_object_unref(screenshot); - g_free(filename); -} -void on_menu_pscreen_activate (GtkMenuItem *menuitem, gpointer user_data) { Printscreen(); } - - -/* MENU SAVES ***** ***** ***** ***** */ -void on_loadstateXX_activate (GtkMenuItem *m, gpointer d) { - int slot = dyn_CAST(int,d); - loadstate_slot(slot); -} -void on_savestateXX_activate (GtkMenuItem *m, gpointer d) { - int slot = dyn_CAST(int,d); - update_savestate(slot); -} -void on_savetypeXX_activate (GtkMenuItem *m, gpointer d) { - int type = dyn_CAST(int,d); - desmume_savetype(type); -} - - -/* MENU EMULATION ***** ***** ***** ***** */ -void on_menu_exec_activate (GtkMenuItem *menuitem, gpointer user_data) { desmume_resume(); } -void on_menu_pause_activate (GtkMenuItem *menuitem, gpointer user_data) { desmume_pause(); } -void on_menu_reset_activate (GtkMenuItem *menuitem, gpointer user_data) { desmume_reset(); } -void on_menu_layers_activate (GtkMenuItem *menuitem, gpointer user_data) { - /* we want to hide or show the checkbox for the layers */ - GtkWidget * w1 = glade_xml_get_widget(xml, "wvb_1_Main"); - GtkWidget * w2 = glade_xml_get_widget(xml, "wvb_2_Sub"); - if (gtk_check_menu_item_get_active((GtkCheckMenuItem*)menuitem)==TRUE) { - gtk_widget_show(w1); - gtk_widget_show(w2); - } else { - gtk_widget_hide(w1); - gtk_widget_hide(w2); - } - /* pack the window */ - MAINWINDOW_RESIZE(); -} - -/* SUBMENU FRAMESKIP ***** ***** ***** ***** */ -void on_fsXX_activate (GtkMenuItem *menuitem,gpointer user_data) { - Frameskip = dyn_CAST(int,user_data); -// printf ("setting FS %d %d\n", Frameskip, user_data); -} - - -/* SUBMENU SIZE ***** ***** ***** ***** */ - -static void gtk_table_reattach(GtkTable * table, GtkWidget * w, - guint left_attach, guint right_attach, guint top_attach, guint bottom_attach, - GtkAttachOptions xoptions, GtkAttachOptions yoptions, - guint xpadding, guint ypadding) { - GList *list; - for (list = table->children; list; list = list->next) - { - GtkTableChild *table_child; - table_child = (GtkTableChild *) list->data; - if (table_child->widget == w) { - table_child->left_attach = left_attach; - table_child->right_attach = right_attach; - table_child->top_attach = top_attach; - table_child->bottom_attach = bottom_attach; - table_child->xexpand = (xoptions & GTK_EXPAND) != 0; - table_child->xshrink = (xoptions & GTK_SHRINK) != 0; - table_child->xfill = (xoptions & GTK_FILL) != 0; - table_child->xpadding = xpadding; - table_child->yexpand = (yoptions & GTK_EXPAND) != 0; - table_child->yshrink = (yoptions & GTK_SHRINK) != 0; - table_child->yfill = (yoptions & GTK_FILL) != 0; - table_child->ypadding = ypadding; - break; - } - } -} - -static void rightscreen(BOOL apply) { - GtkWidget *chk = glade_xml_get_widget(xml, "wvb_2_Sub"); - GtkTable *table = (GtkTable *)glade_xml_get_widget(xml, "table_layout"); - - ScreenRight = apply || ScreenRightForce; - if (ScreenRight) { - /* we want to change the layout, lower screen goes right */ - gtk_table_reattach(table, pDrawingArea2, - 3,4, 0,1, (GtkAttachOptions) 0, (GtkAttachOptions) 0, 0,0); - gtk_table_reattach(table, chk, - 4,5, 0,1, (GtkAttachOptions) 0, (GtkAttachOptions) 0, 0,0); - } else { - /* we want to change the layout, lower screen goes down */ - gtk_table_reattach(table, pDrawingArea2, - 1,2, 2,3, (GtkAttachOptions) 0, (GtkAttachOptions) 0, 0,0); - gtk_table_reattach(table, chk, - 0,1, 2,3, (GtkAttachOptions) 0, (GtkAttachOptions) 0, 0,0); - ScreenRight = FALSE; - } - - gtk_widget_queue_resize (GTK_WIDGET (table)); - - /* pack the window */ - MAINWINDOW_RESIZE(); -} -int H=192, W=256; -void resize (float Size1, float Size2) { - // not ready yet to handle different zoom factors - Size2 = Size1; - /* we want to scale drawing areas by a factor (1x,2x or 3x) */ - gtk_widget_set_size_request (pDrawingArea, W * Size1, H * Size1); - gtk_widget_set_size_request (pDrawingArea2, W * Size2, H * Size2); - ScreenCoeff_Size[0] = Size1; - ScreenCoeff_Size[1] = Size2; - /* remove artifacts */ - black_screen(); - /* pack the window */ - MAINWINDOW_RESIZE(); -} -void rotate(float angle) { - BOOL rotated; - if (angle >= 360.0) angle -= 360.0; - ScreenRotate = angle; - rotated = (ScreenRotate==90.0 || ScreenRotate==270.0); - ScreenInvert = (ScreenRotate >= 180.0); - if (rotated) { - H=256; W=192; - } else { - W=256; H=192; - } - rightscreen(rotated); - resize(ScreenCoeff_Size[0],ScreenCoeff_Size[1]); -} - -void on_sizeXX_activate (GtkMenuItem *menuitem, gpointer user_data) { - float f = dyn_CAST(float,user_data); -// printf("setting ZOOM %f\n",f); - resize(f,f); -} - - - -/* MENU CONFIG ***** ***** ***** ***** */ - -void on_menu_controls_activate (GtkMenuItem *menuitem, gpointer user_data) { - edit_controls(); -} - -/* Show joystick controls configuration dialog - FIXME: sdl doesn't detect unplugged joysticks!! */ -void on_menu_joy_controls_activate (GtkMenuItem *menuitem, gpointer -user_data) -{ - GtkDialog * dlg; - GtkDialog * msgbox; - char * text; - - /* At least one joystick connected? - Can't configure joystick if SDL Event loop is already running. */ - if( (nbr_joy < 1) || desmume_running() ) - { - if( nbr_joy < 1 ) - text = _("You don't have any joystick!"); - else - text = _("Can't configure joystick while the game is running!"); - - dlg = (GtkDialog*)glade_xml_get_widget(xml, "wMainW"); - msgbox = (GtkDialog*) - gtk_message_dialog_new((GtkWindow*)dlg, - (GtkDialogFlags) (GTK_DIALOG_MODAL|GTK_DIALOG_DESTROY_WITH_PARENT), - GTK_MESSAGE_INFO, - GTK_BUTTONS_CLOSE, - "%s", - text); - g_signal_connect(G_OBJECT(msgbox), "response", G_CALLBACK(gtk_widget_destroy), NULL); - - gtk_dialog_run( msgbox ); - } - else - { - dlg = (GtkDialog*)glade_xml_get_widget(xml, "wJoyConfDlg"); - init_joy_labels(); - gtk_dialog_run(dlg); - } -} - -void on_menu_audio_on_activate (GtkMenuItem *menuitem, gpointer user_data) { - /* we want set audio emulation ON or OFF */ - if (gtk_check_menu_item_get_active((GtkCheckMenuItem*)menuitem)) { - SPU_Pause(0); - } else { - SPU_Pause(1); - } -} - -void on_menu_gapscreen_activate (GtkMenuItem *menuitem, gpointer user_data) { - /* we want to add a gap between screens */ - ScreenGap = gtk_check_menu_item_get_active((GtkCheckMenuItem*)menuitem); - - /* pack the window */ - MAINWINDOW_RESIZE(); -} - -void on_menu_nogap_activate (GtkMenuItem *menuitem, gpointer user_data) { - /* we'll make both gaps visibility false */ - ScreenNoGap = gtk_check_menu_item_get_active((GtkCheckMenuItem*)menuitem); - - /* pack the window */ - MAINWINDOW_RESIZE(); -} - -void on_menu_rightscreen_activate (GtkMenuItem *menuitem, gpointer user_data) { - ScreenRightForce=gtk_check_menu_item_get_active((GtkCheckMenuItem*)menuitem); - rightscreen(ScreenRightForce); -} - -void on_menu_rotatescreen_activate (GtkMenuItem *menuitem, gpointer user_data) { - /* we want to rotate the screen */ - float angle = dyn_CAST(float,user_data); - rotate(angle); -} - -/* MENU TOOLS ***** ***** ***** ***** */ -void on_menu_IO_regs_activate (GtkMenuItem *menuitem, gpointer user_data) { - GtkWidget * dlg = glade_xml_get_widget(xml_tools, "wtools_1_IOregs"); - gtk_widget_show(dlg); -} -void on_menu_memview_activate (GtkMenuItem *menuitem, gpointer user_data) { - GtkWidget * dlg = glade_xml_get_widget(xml_tools, "wtools_2_MemView"); - gtk_widget_show(dlg); -} -void on_menu_palview_activate (GtkMenuItem *menuitem, gpointer user_data) { - GtkWidget * dlg = glade_xml_get_widget(xml_tools, "wtools_3_PalView"); - gtk_widget_show(dlg); -} -#ifdef GTKGLEXT_AVAILABLE -void on_menu_tileview_activate (GtkMenuItem *menuitem, gpointer user_data) { - GtkWidget * dlg = glade_xml_get_widget(xml_tools, "wtools_4_TileView"); - gtk_widget_show(dlg); -} -#else -void on_menu_tileview_activate (GtkMenuItem *menuitem, gpointer user_data) { - g_printerr("You need gtkglext for the tile viewer\n"); -} -#endif -void on_menu_wtoolsXX_activate (GtkMenuItem *menuitem, gpointer user_data) { - GtkWidget * w = (GtkWidget *) user_data; - gtk_widget_show(w); -} - - -/* MENU ? ***** ***** ***** ***** */ -/* About dialog - FIXME: Add proper copyright */ -void on_menu_apropos_activate (GtkMenuItem *menuitem, gpointer user_data) { - GtkWidget * wAbout = glade_xml_get_widget(xml, "wAboutDlg"); - gtk_about_dialog_set_version((GtkAboutDialog *)wAbout, VERSION); - gtk_widget_show(wAbout); -} - - -/* TOOLBAR ***** ***** ***** ***** */ -void on_wgt_Open_clicked (GtkToolButton *toolbutton, gpointer user_data) { file_open(); } -void on_wgt_Reset_clicked (GtkToolButton *toolbutton, gpointer user_data) { desmume_reset(); } -void on_wgt_Quit_clicked (GtkToolButton *toolbutton, gpointer user_data) { gtk_main_quit(); } -void on_wgt_Exec_toggled (GtkToggleToolButton *toggletoolbutton, gpointer user_data) { - if (gtk_toggle_tool_button_get_active(toggletoolbutton)==TRUE) - desmume_resume(); - else - desmume_pause(); -} - - - -/* LAYERS ***** ***** ***** ***** */ -static void change_bgx_layer(int layer, gboolean state, NDS_Screen scr) { - //if(!desmume_running()) return; - if(state==TRUE) { - GPU_addBack(scr.gpu, layer); - } else { - GPU_remove(scr.gpu, layer); - } - //fprintf(stderr,"Changed Layer %s to %d\n",layer,state); -} -void on_wc_1_BGXX_toggled (GtkToggleButton *togglebutton, gpointer user_data) { - int layer = dyn_CAST(int,user_data); - change_bgx_layer(layer, gtk_toggle_button_get_active(togglebutton), MainScreen); -} -void on_wc_2_BGXX_toggled (GtkToggleButton *togglebutton, gpointer user_data) { - int layer = dyn_CAST(int,user_data); - change_bgx_layer(layer, gtk_toggle_button_get_active(togglebutton), SubScreen); -} +/* callbacks.c - this file is part of DeSmuME + * + * Copyright (C) 2007 Damien Nozay (damdoum) + * Copyright (C) 2007 Pascal Giard (evilynux) + * Author: damdoum at users.sourceforge.net + * + * This file is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2, or (at your option) + * any later version. + * + * This file is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; see the file COPYING. If not, write to + * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#include "callbacks.h" + +/* globals */ +int Frameskip = 0; +gboolean ScreenRightForce=FALSE; +gboolean ScreenRight=FALSE; +gboolean ScreenGap=FALSE; +gboolean ScreenNoGap=FALSE; +gboolean ScreenInvert=FALSE; + +/* ******** Savestate menu items handling ******** */ + +static void set_menuitem_label(GtkWidget * w, char * text ) +{ + GtkLabel * child; + + if ( GTK_BIN(w)->child ) + { + child = (GtkLabel*)GTK_BIN(w)->child; + gtk_label_set_text(child, text); + } +} + +static void clear_savestate_menu(const char * cb_name, u8 num) +{ + GtkWidget * w; + char cb[40]; + char text[40]; + + sprintf( cb, "%s%d", cb_name, num); + sprintf( text, _("State %d (empty)"), num); + w = glade_xml_get_widget(xml, cb); + set_menuitem_label( w, text ); +} + +static void update_savestate_menu(const char * cb_name, u8 num) +{ + GtkWidget * w; + char cb[40]; + + snprintf( cb, 39, "%s%d", cb_name, num); + w = glade_xml_get_widget(xml, cb); + set_menuitem_label( w, savestates[num-1].date ); +} + +static void update_savestates_menu() +{ + u8 i; + + for( i = 1; i <= NB_STATES; i++ ) + { + if( savestates[i-1].exists == TRUE ) + { + update_savestate_menu("loadstate", i); + update_savestate_menu("savestate", i); + } + else + { + clear_savestate_menu("loadstate", i); + clear_savestate_menu("savestate", i); + } + } +} + +static void update_savestate(u8 num) +{ + desmume_pause(); + savestate_slot(num); + update_savestate_menu("savestate", num); + update_savestate_menu("loadstate", num); + desmume_resume(); +} + +/* inline & protos */ + +inline void SET_SENSITIVE(const gchar *w, gboolean b) { + gtk_widget_set_sensitive( + glade_xml_get_widget(xml, w), TRUE); +} + +void enable_rom_features() { + scan_savestates(); + update_savestates_menu(); + SET_SENSITIVE("menu_exec", TRUE); + SET_SENSITIVE("menu_pause", TRUE); + SET_SENSITIVE("menu_reset", TRUE); + SET_SENSITIVE("wgt_Exec", TRUE); + SET_SENSITIVE("wgt_Reset", TRUE); +} + +static void MAINWINDOW_RESIZE() { + GtkWidget * spacer1 = glade_xml_get_widget(xml, "misc_sep3"); + GtkWidget * spacer2 = glade_xml_get_widget(xml, "misc_sep4"); + int dim1,dim2; + BOOL rotate = (ScreenRotate==90.0 || ScreenRotate==270.0 ); + + dim1 = dim2 = 66 * ScreenCoeff_Size[0]; + + /* sees whether we want a gap */ + if (!ScreenGap) dim1 = dim2 = -1; + + if (ScreenNoGap) { + gtk_widget_hide (spacer1); + gtk_widget_hide (spacer2); + } + else + { + gtk_widget_show (spacer1); + gtk_widget_show (spacer2); + } + + if (ScreenRight == rotate) { + if (ScreenRight) + dim2 = -1; + else + dim1 = -1; + } else { + dim1 = dim2 = -1; + } + gtk_widget_set_usize(spacer1, dim1, -1); + gtk_widget_set_usize(spacer2, -1, dim2); + gtk_window_resize ((GtkWindow*)pWindow,1,1); +} + +/* MENU FILE ***** ***** ***** ***** */ +void inline ADD_FILTER(GtkWidget * filech, const char * pattern, const char * name) { + GtkFileFilter *pFilter; + pFilter = gtk_file_filter_new(); + gtk_file_filter_add_pattern(pFilter, pattern); + gtk_file_filter_set_name(pFilter, name); + gtk_file_chooser_add_filter(GTK_FILE_CHOOSER(filech), pFilter); +} + +static void file_open() { + desmume_pause(); + + GtkWidget *pFileSelection; + GtkWidget *pParent; + gchar *sChemin; + + pParent = GTK_WIDGET(pWindow); + + /* Creating the selection window */ + pFileSelection = gtk_file_chooser_dialog_new(_("Open..."), + GTK_WINDOW(pParent), + GTK_FILE_CHOOSER_ACTION_OPEN, + GTK_STOCK_CANCEL, GTK_RESPONSE_CANCEL, + GTK_STOCK_OPEN, GTK_RESPONSE_OK, + NULL); + /* On limite les actions a cette fenetre */ + gtk_window_set_modal(GTK_WINDOW(pFileSelection), TRUE); + + ADD_FILTER(pFileSelection, "*.nds", _("Nds binary (.nds)")); + ADD_FILTER(pFileSelection, "*.ds.gba", _("Nds binary with loader (.ds.gba)")); + ADD_FILTER(pFileSelection, "*", _("All files")); + //ADD_FILTER(pFileSelection, "*.zip", "Nds zipped binary"); + + /* Affichage fenetre*/ + switch(gtk_dialog_run(GTK_DIALOG(pFileSelection))) + { + case GTK_RESPONSE_OK: + /* Recuperation du chemin */ + sChemin = gtk_file_chooser_get_filename(GTK_FILE_CHOOSER(pFileSelection)); + if(desmume_open((const char*)sChemin) < 0) + { + GtkWidget *pDialog = gtk_message_dialog_new(GTK_WINDOW(pFileSelection), + GTK_DIALOG_MODAL, + GTK_MESSAGE_ERROR, + GTK_BUTTONS_OK, + _("Unable to load :\n%s"), sChemin); + gtk_dialog_run(GTK_DIALOG(pDialog)); + gtk_widget_destroy(pDialog); + } else { + desmume_resume(); + enable_rom_features(); + } + + g_free(sChemin); + break; + default: + break; + } + gtk_widget_destroy(pFileSelection); +} + +void on_menu_open_activate (GtkMenuItem *menuitem, gpointer user_data) { file_open();} +void on_menu_quit_activate (GtkMenuItem *menuitem, gpointer user_data) { gtk_main_quit(); } + +#define SCREENS_PIXEL_SIZE 98304 + +static void Printscreen() +{ + GdkPixbuf *screenshot; + gchar *filename; + GError *error = NULL; + u8 *rgb; + static int seq = 0; + + rgb = (u8 *) malloc(SCREENS_PIXEL_SIZE*3); + if (!rgb) + return; + for (int i = 0; i < SCREENS_PIXEL_SIZE; i++) { + rgb[(i * 3) + 0] = ((*((u16 *)&GPU_screen[(i<<1)]) >> 0) & 0x1f) << 3; + rgb[(i * 3) + 1] = ((*((u16 *)&GPU_screen[(i<<1)]) >> 5) & 0x1f) << 3; + rgb[(i * 3) + 2] = ((*((u16 *)&GPU_screen[(i<<1)]) >> 10) & 0x1f) << 3; + } + + screenshot = gdk_pixbuf_new_from_data(rgb, + GDK_COLORSPACE_RGB, + FALSE, + 8, + 256, + 192*2, + 256*3, + NULL, + NULL); + + filename = g_strdup_printf("./desmume-screenshot-%d.png", seq); + gdk_pixbuf_save(screenshot, filename, "png", &error, NULL); + if (error) { + g_error_free (error); + g_printerr("Failed to save %s", filename); + } else { + seq++; + } + + free(rgb); + g_object_unref(screenshot); + g_free(filename); +} +void on_menu_pscreen_activate (GtkMenuItem *menuitem, gpointer user_data) { Printscreen(); } + + +/* MENU SAVES ***** ***** ***** ***** */ +void on_loadstateXX_activate (GtkMenuItem *m, gpointer d) { + int slot = dyn_CAST(int,d); + loadstate_slot(slot); +} +void on_savestateXX_activate (GtkMenuItem *m, gpointer d) { + int slot = dyn_CAST(int,d); + update_savestate(slot); +} +void on_savetypeXX_activate (GtkMenuItem *m, gpointer d) { + int type = dyn_CAST(int,d); + desmume_savetype(type); +} + + +/* MENU EMULATION ***** ***** ***** ***** */ +void on_menu_exec_activate (GtkMenuItem *menuitem, gpointer user_data) { desmume_resume(); } +void on_menu_pause_activate (GtkMenuItem *menuitem, gpointer user_data) { desmume_pause(); } +void on_menu_reset_activate (GtkMenuItem *menuitem, gpointer user_data) { desmume_reset(); } +void on_menu_layers_activate (GtkMenuItem *menuitem, gpointer user_data) { + /* we want to hide or show the checkbox for the layers */ + GtkWidget * w1 = glade_xml_get_widget(xml, "wvb_1_Main"); + GtkWidget * w2 = glade_xml_get_widget(xml, "wvb_2_Sub"); + if (gtk_check_menu_item_get_active((GtkCheckMenuItem*)menuitem)==TRUE) { + gtk_widget_show(w1); + gtk_widget_show(w2); + } else { + gtk_widget_hide(w1); + gtk_widget_hide(w2); + } + /* pack the window */ + MAINWINDOW_RESIZE(); +} + +/* SUBMENU FRAMESKIP ***** ***** ***** ***** */ +void on_fsXX_activate (GtkMenuItem *menuitem,gpointer user_data) { + Frameskip = dyn_CAST(int,user_data); +// printf ("setting FS %d %d\n", Frameskip, user_data); +} + + +/* SUBMENU SIZE ***** ***** ***** ***** */ + +static void gtk_table_reattach(GtkTable * table, GtkWidget * w, + guint left_attach, guint right_attach, guint top_attach, guint bottom_attach, + GtkAttachOptions xoptions, GtkAttachOptions yoptions, + guint xpadding, guint ypadding) { + GList *list; + for (list = table->children; list; list = list->next) + { + GtkTableChild *table_child; + table_child = (GtkTableChild *) list->data; + if (table_child->widget == w) { + table_child->left_attach = left_attach; + table_child->right_attach = right_attach; + table_child->top_attach = top_attach; + table_child->bottom_attach = bottom_attach; + table_child->xexpand = (xoptions & GTK_EXPAND) != 0; + table_child->xshrink = (xoptions & GTK_SHRINK) != 0; + table_child->xfill = (xoptions & GTK_FILL) != 0; + table_child->xpadding = xpadding; + table_child->yexpand = (yoptions & GTK_EXPAND) != 0; + table_child->yshrink = (yoptions & GTK_SHRINK) != 0; + table_child->yfill = (yoptions & GTK_FILL) != 0; + table_child->ypadding = ypadding; + break; + } + } +} + +static void rightscreen(BOOL apply) { + GtkWidget *chk = glade_xml_get_widget(xml, "wvb_2_Sub"); + GtkTable *table = (GtkTable *)glade_xml_get_widget(xml, "table_layout"); + + ScreenRight = apply || ScreenRightForce; + if (ScreenRight) { + /* we want to change the layout, lower screen goes right */ + gtk_table_reattach(table, pDrawingArea2, + 3,4, 0,1, (GtkAttachOptions) 0, (GtkAttachOptions) 0, 0,0); + gtk_table_reattach(table, chk, + 4,5, 0,1, (GtkAttachOptions) 0, (GtkAttachOptions) 0, 0,0); + } else { + /* we want to change the layout, lower screen goes down */ + gtk_table_reattach(table, pDrawingArea2, + 1,2, 2,3, (GtkAttachOptions) 0, (GtkAttachOptions) 0, 0,0); + gtk_table_reattach(table, chk, + 0,1, 2,3, (GtkAttachOptions) 0, (GtkAttachOptions) 0, 0,0); + ScreenRight = FALSE; + } + + gtk_widget_queue_resize (GTK_WIDGET (table)); + + /* pack the window */ + MAINWINDOW_RESIZE(); +} +int H=192, W=256; +void resize (float Size1, float Size2) { + // not ready yet to handle different zoom factors + Size2 = Size1; + /* we want to scale drawing areas by a factor (1x,2x or 3x) */ + gtk_widget_set_size_request (pDrawingArea, W * Size1, H * Size1); + gtk_widget_set_size_request (pDrawingArea2, W * Size2, H * Size2); + ScreenCoeff_Size[0] = Size1; + ScreenCoeff_Size[1] = Size2; + /* remove artifacts */ + black_screen(); + /* pack the window */ + MAINWINDOW_RESIZE(); +} +void rotate(float angle) { + BOOL rotated; + if (angle >= 360.0) angle -= 360.0; + ScreenRotate = angle; + rotated = (ScreenRotate==90.0 || ScreenRotate==270.0); + ScreenInvert = (ScreenRotate >= 180.0); + if (rotated) { + H=256; W=192; + } else { + W=256; H=192; + } + rightscreen(rotated); + resize(ScreenCoeff_Size[0],ScreenCoeff_Size[1]); +} + +void on_sizeXX_activate (GtkMenuItem *menuitem, gpointer user_data) { + float f = dyn_CAST(float,user_data); +// printf("setting ZOOM %f\n",f); + resize(f,f); +} + + + +/* MENU CONFIG ***** ***** ***** ***** */ + +void on_menu_controls_activate (GtkMenuItem *menuitem, gpointer user_data) { + edit_controls(); +} + +/* Show joystick controls configuration dialog + FIXME: sdl doesn't detect unplugged joysticks!! */ +void on_menu_joy_controls_activate (GtkMenuItem *menuitem, gpointer +user_data) +{ + GtkDialog * dlg; + GtkDialog * msgbox; + char * text; + + /* At least one joystick connected? + Can't configure joystick if SDL Event loop is already running. */ + if( (nbr_joy < 1) || desmume_running() ) + { + if( nbr_joy < 1 ) + text = _("You don't have any joystick!"); + else + text = _("Can't configure joystick while the game is running!"); + + dlg = (GtkDialog*)glade_xml_get_widget(xml, "wMainW"); + msgbox = (GtkDialog*) + gtk_message_dialog_new((GtkWindow*)dlg, + (GtkDialogFlags) (GTK_DIALOG_MODAL|GTK_DIALOG_DESTROY_WITH_PARENT), + GTK_MESSAGE_INFO, + GTK_BUTTONS_CLOSE, + "%s", + text); + g_signal_connect(G_OBJECT(msgbox), "response", G_CALLBACK(gtk_widget_destroy), NULL); + + gtk_dialog_run( msgbox ); + } + else + { + dlg = (GtkDialog*)glade_xml_get_widget(xml, "wJoyConfDlg"); + init_joy_labels(); + gtk_dialog_run(dlg); + } +} + +void on_menu_audio_on_activate (GtkMenuItem *menuitem, gpointer user_data) { + /* we want set audio emulation ON or OFF */ + if (gtk_check_menu_item_get_active((GtkCheckMenuItem*)menuitem)) { + SPU_Pause(0); + } else { + SPU_Pause(1); + } +} + +void on_menu_gapscreen_activate (GtkMenuItem *menuitem, gpointer user_data) { + /* we want to add a gap between screens */ + ScreenGap = gtk_check_menu_item_get_active((GtkCheckMenuItem*)menuitem); + + /* pack the window */ + MAINWINDOW_RESIZE(); +} + +void on_menu_nogap_activate (GtkMenuItem *menuitem, gpointer user_data) { + /* we'll make both gaps visibility false */ + ScreenNoGap = gtk_check_menu_item_get_active((GtkCheckMenuItem*)menuitem); + + /* pack the window */ + MAINWINDOW_RESIZE(); +} + +void on_menu_rightscreen_activate (GtkMenuItem *menuitem, gpointer user_data) { + ScreenRightForce=gtk_check_menu_item_get_active((GtkCheckMenuItem*)menuitem); + rightscreen(ScreenRightForce); +} + +void on_menu_rotatescreen_activate (GtkMenuItem *menuitem, gpointer user_data) { + /* we want to rotate the screen */ + float angle = dyn_CAST(float,user_data); + rotate(angle); +} + +/* MENU TOOLS ***** ***** ***** ***** */ +void on_menu_IO_regs_activate (GtkMenuItem *menuitem, gpointer user_data) { + GtkWidget * dlg = glade_xml_get_widget(xml_tools, "wtools_1_IOregs"); + gtk_widget_show(dlg); +} +void on_menu_memview_activate (GtkMenuItem *menuitem, gpointer user_data) { + GtkWidget * dlg = glade_xml_get_widget(xml_tools, "wtools_2_MemView"); + gtk_widget_show(dlg); +} +void on_menu_palview_activate (GtkMenuItem *menuitem, gpointer user_data) { + GtkWidget * dlg = glade_xml_get_widget(xml_tools, "wtools_3_PalView"); + gtk_widget_show(dlg); +} +void on_menu_tileview_activate (GtkMenuItem *menuitem, gpointer user_data) { + GtkWidget * dlg = glade_xml_get_widget(xml_tools, "wtools_4_TileView"); + gtk_widget_show(dlg); +} +void on_menu_wtoolsXX_activate (GtkMenuItem *menuitem, gpointer user_data) { + GtkWidget * w = (GtkWidget *) user_data; + gtk_widget_show(w); +} + + +/* MENU ? ***** ***** ***** ***** */ +/* About dialog + FIXME: Add proper copyright */ +void on_menu_apropos_activate (GtkMenuItem *menuitem, gpointer user_data) { + GtkWidget * wAbout = glade_xml_get_widget(xml, "wAboutDlg"); + gtk_about_dialog_set_version((GtkAboutDialog *)wAbout, VERSION); + gtk_widget_show(wAbout); +} + + +/* TOOLBAR ***** ***** ***** ***** */ +void on_wgt_Open_clicked (GtkToolButton *toolbutton, gpointer user_data) { file_open(); } +void on_wgt_Reset_clicked (GtkToolButton *toolbutton, gpointer user_data) { desmume_reset(); } +void on_wgt_Quit_clicked (GtkToolButton *toolbutton, gpointer user_data) { gtk_main_quit(); } +void on_wgt_Exec_toggled (GtkToggleToolButton *toggletoolbutton, gpointer user_data) { + if (gtk_toggle_tool_button_get_active(toggletoolbutton)==TRUE) + desmume_resume(); + else + desmume_pause(); +} + + + +/* LAYERS ***** ***** ***** ***** */ +static void change_bgx_layer(int layer, gboolean state, NDS_Screen scr) { + //if(!desmume_running()) return; + if(state==TRUE) { + GPU_addBack(scr.gpu, layer); + } else { + GPU_remove(scr.gpu, layer); + } + //fprintf(stderr,"Changed Layer %s to %d\n",layer,state); +} +void on_wc_1_BGXX_toggled (GtkToggleButton *togglebutton, gpointer user_data) { + int layer = dyn_CAST(int,user_data); + change_bgx_layer(layer, gtk_toggle_button_get_active(togglebutton), MainScreen); +} +void on_wc_2_BGXX_toggled (GtkToggleButton *togglebutton, gpointer user_data) { + int layer = dyn_CAST(int,user_data); + change_bgx_layer(layer, gtk_toggle_button_get_active(togglebutton), SubScreen); +} diff --git a/desmume/src/gtk-glade/callbacks.h b/src/gtk-glade/callbacks.h old mode 100755 new mode 100644 similarity index 98% rename from desmume/src/gtk-glade/callbacks.h rename to src/gtk-glade/callbacks.h index 7ba0a86f5..266a22c40 --- a/desmume/src/gtk-glade/callbacks.h +++ b/src/gtk-glade/callbacks.h @@ -1,75 +1,75 @@ -/* callbacks.h - this file is part of DeSmuME - * - * Copyright (C) 2007 Damien Nozay (damdoum) - * Author: damdoum at users.sourceforge.net - * - * This file is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2, or (at your option) - * any later version. - * - * This file is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; see the file COPYING. If not, write to - * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -#include "globals.h" - -extern "C" { - -/* MENU FILE */ -G_MODULE_EXPORT void on_menu_open_activate (GtkMenuItem *menuitem, gpointer user_data); -G_MODULE_EXPORT void on_menu_pscreen_activate (GtkMenuItem *menuitem, gpointer user_data); -G_MODULE_EXPORT void on_menu_quit_activate (GtkMenuItem *menuitem, gpointer user_data); - -/* MENU SAVES */ -G_MODULE_EXPORT void on_loadstateXX_activate (GtkMenuItem *, gpointer ); -G_MODULE_EXPORT void on_savestateXX_activate (GtkMenuItem *, gpointer ); -G_MODULE_EXPORT void on_savetypeXX_activate (GtkMenuItem *, gpointer ); - -/* MENU EMULATION */ -G_MODULE_EXPORT void on_menu_exec_activate (GtkMenuItem *menuitem, gpointer user_data); -G_MODULE_EXPORT void on_menu_pause_activate (GtkMenuItem *menuitem, gpointer user_data); -G_MODULE_EXPORT void on_menu_reset_activate (GtkMenuItem *menuitem, gpointer user_data); -G_MODULE_EXPORT void on_menu_layers_activate (GtkMenuItem *menuitem, gpointer user_data); -G_MODULE_EXPORT void on_fsXX_activate (GtkMenuItem *menuitem, gpointer user_data); -G_MODULE_EXPORT void on_sizeXX_activate (GtkMenuItem *menuitem, gpointer user_data); - -/* MENU CONFIG */ -G_MODULE_EXPORT void on_menu_controls_activate (GtkMenuItem *menuitem, gpointer user_data); -G_MODULE_EXPORT void on_menu_joy_controls_activate (GtkMenuItem *menuitem, gpointer user_data); -G_MODULE_EXPORT void on_menu_audio_on_activate (GtkMenuItem *menuitem, gpointer user_data); -G_MODULE_EXPORT void on_menu_gapscreen_activate (GtkMenuItem *menuitem, gpointer user_data); -G_MODULE_EXPORT void on_menu_nogap_activate (GtkMenuItem *menuitem, gpointer user_data); -G_MODULE_EXPORT void on_menu_rightscreen_activate (GtkMenuItem *menuitem, gpointer user_data); -G_MODULE_EXPORT void on_menu_rotatescreen_activate (GtkMenuItem *menuitem, gpointer user_data); - -/* MENU TOOLS */ -G_MODULE_EXPORT void on_menu_wtoolsXX_activate (GtkMenuItem *menuitem, gpointer user_data); -G_MODULE_EXPORT void on_menu_IO_regs_activate (GtkMenuItem *menuitem, gpointer user_data); -G_MODULE_EXPORT void on_menu_memview_activate (GtkMenuItem *menuitem, gpointer user_data); -G_MODULE_EXPORT void on_menu_palview_activate (GtkMenuItem *menuitem, gpointer user_data); -G_MODULE_EXPORT void on_menu_tileview_activate (GtkMenuItem *menuitem, gpointer user_data); - -/* MENU ? */ -G_MODULE_EXPORT void on_menu_apropos_activate (GtkMenuItem *menuitem, gpointer user_data); - - -/* TOOLBAR */ -G_MODULE_EXPORT void on_wgt_Open_clicked (GtkToolButton *toolbutton, gpointer user_data); -G_MODULE_EXPORT void on_wgt_Exec_toggled (GtkToggleToolButton *toggletoolbutton, - gpointer user_data); -G_MODULE_EXPORT void on_wgt_Reset_clicked (GtkToolButton *toolbutton, gpointer user_data); -G_MODULE_EXPORT void on_wgt_Quit_clicked (GtkToolButton *toolbutton, gpointer user_data); - -/* LAYERS TOGGLE */ -G_MODULE_EXPORT void on_wc_1_BGXX_toggled (GtkToggleButton *togglebutton, gpointer user_data); -G_MODULE_EXPORT void on_wc_2_BGXX_toggled (GtkToggleButton *togglebutton, gpointer user_data); - -} +/* callbacks.h - this file is part of DeSmuME + * + * Copyright (C) 2007 Damien Nozay (damdoum) + * Author: damdoum at users.sourceforge.net + * + * This file is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2, or (at your option) + * any later version. + * + * This file is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; see the file COPYING. If not, write to + * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#include "globals.h" + +extern "C" { + +/* MENU FILE */ +G_MODULE_EXPORT void on_menu_open_activate (GtkMenuItem *menuitem, gpointer user_data); +G_MODULE_EXPORT void on_menu_pscreen_activate (GtkMenuItem *menuitem, gpointer user_data); +G_MODULE_EXPORT void on_menu_quit_activate (GtkMenuItem *menuitem, gpointer user_data); + +/* MENU SAVES */ +G_MODULE_EXPORT void on_loadstateXX_activate (GtkMenuItem *, gpointer ); +G_MODULE_EXPORT void on_savestateXX_activate (GtkMenuItem *, gpointer ); +G_MODULE_EXPORT void on_savetypeXX_activate (GtkMenuItem *, gpointer ); + +/* MENU EMULATION */ +G_MODULE_EXPORT void on_menu_exec_activate (GtkMenuItem *menuitem, gpointer user_data); +G_MODULE_EXPORT void on_menu_pause_activate (GtkMenuItem *menuitem, gpointer user_data); +G_MODULE_EXPORT void on_menu_reset_activate (GtkMenuItem *menuitem, gpointer user_data); +G_MODULE_EXPORT void on_menu_layers_activate (GtkMenuItem *menuitem, gpointer user_data); +G_MODULE_EXPORT void on_fsXX_activate (GtkMenuItem *menuitem, gpointer user_data); +G_MODULE_EXPORT void on_sizeXX_activate (GtkMenuItem *menuitem, gpointer user_data); + +/* MENU CONFIG */ +G_MODULE_EXPORT void on_menu_controls_activate (GtkMenuItem *menuitem, gpointer user_data); +G_MODULE_EXPORT void on_menu_joy_controls_activate (GtkMenuItem *menuitem, gpointer user_data); +G_MODULE_EXPORT void on_menu_audio_on_activate (GtkMenuItem *menuitem, gpointer user_data); +G_MODULE_EXPORT void on_menu_gapscreen_activate (GtkMenuItem *menuitem, gpointer user_data); +G_MODULE_EXPORT void on_menu_nogap_activate (GtkMenuItem *menuitem, gpointer user_data); +G_MODULE_EXPORT void on_menu_rightscreen_activate (GtkMenuItem *menuitem, gpointer user_data); +G_MODULE_EXPORT void on_menu_rotatescreen_activate (GtkMenuItem *menuitem, gpointer user_data); + +/* MENU TOOLS */ +G_MODULE_EXPORT void on_menu_wtoolsXX_activate (GtkMenuItem *menuitem, gpointer user_data); +G_MODULE_EXPORT void on_menu_IO_regs_activate (GtkMenuItem *menuitem, gpointer user_data); +G_MODULE_EXPORT void on_menu_memview_activate (GtkMenuItem *menuitem, gpointer user_data); +G_MODULE_EXPORT void on_menu_palview_activate (GtkMenuItem *menuitem, gpointer user_data); +G_MODULE_EXPORT void on_menu_tileview_activate (GtkMenuItem *menuitem, gpointer user_data); + +/* MENU ? */ +G_MODULE_EXPORT void on_menu_apropos_activate (GtkMenuItem *menuitem, gpointer user_data); + + +/* TOOLBAR */ +G_MODULE_EXPORT void on_wgt_Open_clicked (GtkToolButton *toolbutton, gpointer user_data); +G_MODULE_EXPORT void on_wgt_Exec_toggled (GtkToggleToolButton *toggletoolbutton, + gpointer user_data); +G_MODULE_EXPORT void on_wgt_Reset_clicked (GtkToolButton *toolbutton, gpointer user_data); +G_MODULE_EXPORT void on_wgt_Quit_clicked (GtkToolButton *toolbutton, gpointer user_data); + +/* LAYERS TOGGLE */ +G_MODULE_EXPORT void on_wc_1_BGXX_toggled (GtkToggleButton *togglebutton, gpointer user_data); +G_MODULE_EXPORT void on_wc_2_BGXX_toggled (GtkToggleButton *togglebutton, gpointer user_data); + +} diff --git a/desmume/src/gtk-glade/callbacks_IO.cpp b/src/gtk-glade/callbacks_IO.cpp old mode 100755 new mode 100644 similarity index 96% rename from desmume/src/gtk-glade/callbacks_IO.cpp rename to src/gtk-glade/callbacks_IO.cpp index 9449229aa..1f20b2b8a --- a/desmume/src/gtk-glade/callbacks_IO.cpp +++ b/src/gtk-glade/callbacks_IO.cpp @@ -1,439 +1,439 @@ -/* callbacks_IO.c - this file is part of DeSmuME - * - * Copyright (C) 2007 Damien Nozay (damdoum) - * Copyright (C) 2007 Pascal Giard (evilynux) - * Author: damdoum at users.sourceforge.net - * - * This file is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2, or (at your option) - * any later version. - * - * This file is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; see the file COPYING. If not, write to - * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -#include "callbacks_IO.h" -#include "keyval_names.h" - -static u16 Cur_Keypad = 0; -float ScreenCoeff_Size[2]={1.0,1.0}; -float ScreenRotate=0.0; -gboolean Boost=FALSE; -int BoostFS=20; -int saveFS; - -/* ***** ***** INPUT BUTTONS / KEYBOARD ***** ***** */ -gboolean on_wMainW_key_press_event (GtkWidget *widget, GdkEventKey *event, gpointer user_data) { - u16 Key = lookup_key(event->keyval); - guint mask; - mask = GDK_SHIFT_MASK | GDK_CONTROL_MASK | GDK_MOD1_MASK | GDK_MOD5_MASK; // shift,ctrl, both alts - if( (event->state & mask) == 0){ - if (event->keyval == keyboard_cfg[KEY_BOOST-1]) { - Boost = !Boost; - if (Boost) { - saveFS = Frameskip; - Frameskip = BoostFS; - } else { - Frameskip = saveFS; - } - return 1; - } - if(Key){ - ADD_KEY( Cur_Keypad, Key ); - if(desmume_running()) update_keypad(Cur_Keypad); - return 1; - } - } - return 0; -} - -gboolean on_wMainW_key_release_event (GtkWidget *widget, GdkEventKey *event, gpointer user_data) { - u16 Key = lookup_key(event->keyval); - RM_KEY( Cur_Keypad, Key ); - if(desmume_running()) update_keypad(Cur_Keypad); - return 1; -} - - - -/* ***** ***** SCREEN DRAWING ***** ***** */ -#define RAW_W 256 -#define RAW_H 192 -#define RAW_OFFSET 256*192*sizeof(u16) -#define MAX_SIZE 3 -u32 on_screen_image32[RAW_W*RAW_H*2*MAX_SIZE*MAX_SIZE]; - -int inline screen_size() { - int sz = ScreenCoeff_Size[0]; - return RAW_W*RAW_H*2*sz*sz*sizeof(u32); -} -int inline offset_pixels_lower_screen() { - return screen_size()/2; -} - -void black_screen () { - /* removes artifacts when resizing with scanlines */ - memset(on_screen_image32,0,screen_size()); -} - -#ifndef GTKGLEXT_AVAILABLE -// they are empty if no opengl -// else see gdk_gl.c / gdk_gl.h -BOOL my_gl_Begin (int screen) { return FALSE; } -void my_gl_End (int screen) {} -void reshape (GtkWidget * widget, int screen) {} -void init_GL_capabilities( int use_software_convert) {} - -int has_pix_col_map=0; -u32 pix_col_map[0x8000]; - -static void init_pix_col_map() { - // precalc factors - int a,b,c,A,B,C,rA,rB,rC; - if (has_pix_col_map) return; - for (a=0; a<0x20; a++) { - A=a<<10; rA=A<<9; - for (b=0; b<0x20; b++) { - B=b<<5; rB=B<<6; - for (c=0; c<0x20; c++) { - C=c; rC=C<<3; - pix_col_map[A|B|C]=rA|rB|rC; - } - } - } - has_pix_col_map=1; -} - -static void decode_screen () { - - int x,y, m, W,H,L,BL; - u32 image[RAW_H*2][RAW_W], pix; - u16 * pixel = (u16*)&GPU_screen; - u32 * rgb32 = &on_screen_image32[0]; - - /* decode colors */ - init_pix_col_map(); - for (y=0; y= 0, x--, y=0, y < RAW_H, y++) - LOOP(x=RAW_W-1, x >= 0, x--, y=RAW_H, y < RAW_H*2, y++) - } else { - H=RAW_H*2; W=RAW_W; - LOOP(y=0, y < RAW_H*2, y++, x=0, x < RAW_W, x++) - } -} - -gboolean screen (GtkWidget * widget, int off) { - int H,W,L; - if (off==0) - decode_screen(); - - if (ScreenRotate) { - W=RAW_H; H=RAW_W; - } else { - H=RAW_H; W=RAW_W; - } - L=W*ScreenCoeff_Size[0]*sizeof(u32); - off*= offset_pixels_lower_screen(); - - gdk_draw_rgb_32_image (widget->window, - widget->style->fg_gc[widget->state],0,0, - W*ScreenCoeff_Size[0], H*ScreenCoeff_Size[0], - GDK_RGB_DITHER_NONE,((guchar*)on_screen_image32)+off,L); - return TRUE; -} -#endif /* if GTKGLEXT_AVAILABLE */ - - -/* OUTPUT SCREENS */ -gboolean on_wDrawScreen_expose_event (GtkWidget *widget, GdkEventExpose *event, gpointer user_data) { - int scr = dyn_CAST(int,user_data); - return screen(widget, scr); -} -gboolean on_wDrawScreen_configure_event(GtkWidget *widget, GdkEventConfigure *event, gpointer user_data) { - int scr = dyn_CAST(int,user_data); - reshape(widget, scr); return TRUE; -} - - - - - -/* ***** ***** INPUT STYLUS / MOUSE ***** ***** */ - -static void resize_incremental(int i, GdkEventScroll *event) { -#ifdef GTKGLEXT_AVAILABLE - float zoom_inc=.125, zoom_min=0.25, zoom_max=5.0; -#else - float zoom_inc=1.0, zoom_min=1.0, zoom_max=3.0; -#endif - switch (event->direction) { - case GDK_SCROLL_UP: - ScreenCoeff_Size[i]=MIN(ScreenCoeff_Size[i]+zoom_inc,zoom_max); break; - case GDK_SCROLL_DOWN: - ScreenCoeff_Size[i]=MAX(ScreenCoeff_Size[i]-zoom_inc,zoom_min); break; - case GDK_SCROLL_LEFT: - case GDK_SCROLL_RIGHT: - return; - } - resize(ScreenCoeff_Size[0],ScreenCoeff_Size[1]); -} - -gboolean on_wDrawScreen_scroll_event (GtkWidget *widget, GdkEvent *event, gpointer user_data) { - int scr = dyn_CAST(int,user_data); - // separate zoom factors not supported yet - scr = 0; - resize_incremental(scr,(GdkEventScroll*)event); - - return TRUE; -} - -static void set_touch_pos (int x, int y) { - s32 EmuX, EmuY; - x /= ScreenCoeff_Size[1]; - y /= ScreenCoeff_Size[1]; - EmuX = x; EmuY = y; - if (ScreenRotate==90.0 || ScreenRotate==270.0) { EmuX = 256-y; EmuY = x; } - if(EmuX<0) EmuX = 0; else if(EmuX>255) EmuX = 255; - if(EmuY<0) EmuY = 0; else if(EmuY>192) EmuY = 192; - if (ScreenInvert) { - EmuX = 255-EmuX; - EmuY = 192-EmuY; - } - NDS_setTouchPos(EmuX, EmuY); -} - -gboolean on_wDrawScreen_button_press_event (GtkWidget *widget, GdkEventButton *event, gpointer user_data) { - int scr = dyn_CAST(int,user_data); - GdkModifierType state; - gint x,y; - - switch (event->button) { - case 1: - if (((scr==1) ^ ScreenInvert) && desmume_running()) { - click = TRUE; - gdk_window_get_pointer(widget->window, &x, &y, &state); - if (state & GDK_BUTTON1_MASK) - set_touch_pos(x,y); - } - break; - case 3: break; - case 2: - // filter out 2x / 3x clicks - if (event->type==GDK_BUTTON_PRESS) - rotate(ScreenRotate + 90.0); break; - } - return TRUE; -} - -gboolean on_wDrawScreen_button_release_event (GtkWidget *widget, GdkEventButton *event, gpointer user_data) { - int scr = dyn_CAST(int,user_data); - if ((scr==1) ^ ScreenInvert) { - if (click) NDS_releaseTouch(); - click = FALSE; - } - return TRUE; -} - -gboolean on_wDrawScreen_motion_notify_event (GtkWidget *widget, GdkEventMotion *event, gpointer user_data) { - int scr = dyn_CAST(int,user_data); - GdkModifierType state; - gint x,y; - - if (((scr==1) ^ ScreenInvert) && click) - { - if(event->is_hint) - gdk_window_get_pointer(widget->window, &x, &y, &state); - else - { - x= (gint)event->x; - y= (gint)event->y; - state=(GdkModifierType)event->state; - } - // fprintf(stderr,"X=%d, Y=%d, S&1=%d\n", x,y,state&GDK_BUTTON1_MASK); - if(state & GDK_BUTTON1_MASK) - set_touch_pos(x,y); - } - return TRUE; -} - - - - - -/* ***** ***** KEYBOARD CONFIG / KEY DEFINITION ***** ***** */ -u16 Keypad_Temp[NB_KEYS]; -guint temp_Key=0; - -static void init_labels() { - int i; - char text[50], bname[20]; - GtkButton *b; - for (i=0; ikeyval; - current_key_label(); - return TRUE; -} - -static void ask(GtkButton*b, int key) { - char text[50]; - GtkDialog * dlg = (GtkDialog*)glade_xml_get_widget(xml, "wKeyDlg"); - key--; /* key = bit position, start with 1 */ - temp_Key = Keypad_Temp[key]; - current_key_label(); - switch (gtk_dialog_run(dlg)) - { - case GTK_RESPONSE_OK: - Keypad_Temp[key]=temp_Key; - snprintf(text, 50, "%s : %s",key_names[key],KEYNAME(temp_Key)); - gtk_button_set_label(b,text); - break; - case GTK_RESPONSE_CANCEL: - case GTK_RESPONSE_NONE: - break; - } - gtk_widget_hide((GtkWidget*)dlg); -} - -/* Joystick configuration / Key definition */ -static void ask_joy_key(GtkButton*b, int key) -{ - char text[50]; - u16 joykey; - - GtkWidget * dlg = (GtkWidget*)glade_xml_get_widget(xml, "wJoyDlg"); - - key--; /* remove 1 to get index */ - gtk_widget_show_now(dlg); - /* Need to force event processing. Otherwise, popup won't show up. */ - while ( gtk_events_pending() ) gtk_main_iteration(); - joykey = get_set_joy_key(key); - snprintf(text, 50, "%s : %d",key_names[key],joykey); - gtk_button_set_label(b,text); - gtk_widget_hide((GtkWidget*)dlg); -} - -/* Joystick configuration / Key definition */ -static void ask_joy_axis(u8 key, u8 opposite_key) -{ - char text[50]; - char current_button[50], opposite_button[50]; - GtkWidget * dlg; - GtkButton * btn; - - key--; /* remove 1 to get index */ - opposite_key--; - - snprintf(current_button, 50, "button_joy_%s",key_names[key]); - snprintf(opposite_button, 50, "button_joy_%s",key_names[opposite_key]); - dlg = (GtkWidget*)glade_xml_get_widget(xml, "wJoyDlg"); - - gtk_widget_show(dlg); - /* Need to force event processing. Otherwise, popup won't show up. */ - while ( gtk_events_pending() ) gtk_main_iteration(); - get_set_joy_axis(key, opposite_key); - - snprintf(text, 50, "%s : %d",key_names[key],joypad_cfg[key]); - btn = (GtkButton*)glade_xml_get_widget(xml, current_button); - gtk_button_set_label(btn,text); - - snprintf(text, 50, "%s : %d",key_names[opposite_key],joypad_cfg[opposite_key]); - btn = (GtkButton*)glade_xml_get_widget(xml, opposite_button); - gtk_button_set_label(btn,text); - - gtk_widget_hide((GtkWidget*)dlg); -} - -/* Bind a keyboard key to a keypad key */ -void on_button_kb_key_clicked (GtkButton *b, gpointer user_data) -{ - int key = dyn_CAST( int, user_data ); - ask( b, key ); -} - -/* Bind a joystick axis to a keypad directionnal pad */ -void on_button_joy_axis_clicked (GtkButton *b, gpointer user_data) -{ - int key = dyn_CAST( int, user_data ); - ask_joy_axis( key, key+1 ); -} - -/* Bind a joystick button to a keypad key */ -void on_button_joy_key_clicked (GtkButton *b, gpointer user_data) -{ - int key = dyn_CAST( int, user_data ); - ask_joy_key( b, key ); -} +/* callbacks_IO.c - this file is part of DeSmuME + * + * Copyright (C) 2007 Damien Nozay (damdoum) + * Copyright (C) 2007 Pascal Giard (evilynux) + * Author: damdoum at users.sourceforge.net + * + * This file is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2, or (at your option) + * any later version. + * + * This file is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; see the file COPYING. If not, write to + * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#include "callbacks_IO.h" +#include "keyval_names.h" + +static u16 Cur_Keypad = 0; +float ScreenCoeff_Size[2]={1.0,1.0}; +float ScreenRotate=0.0; +gboolean Boost=FALSE; +int BoostFS=20; +int saveFS; + +/* ***** ***** INPUT BUTTONS / KEYBOARD ***** ***** */ +gboolean on_wMainW_key_press_event (GtkWidget *widget, GdkEventKey *event, gpointer user_data) { + u16 Key = lookup_key(event->keyval); + guint mask; + mask = GDK_SHIFT_MASK | GDK_CONTROL_MASK | GDK_MOD1_MASK | GDK_MOD5_MASK; // shift,ctrl, both alts + if( (event->state & mask) == 0){ + if (event->keyval == keyboard_cfg[KEY_BOOST-1]) { + Boost = !Boost; + if (Boost) { + saveFS = Frameskip; + Frameskip = BoostFS; + } else { + Frameskip = saveFS; + } + return 1; + } + if(Key){ + ADD_KEY( Cur_Keypad, Key ); + if(desmume_running()) update_keypad(Cur_Keypad); + return 1; + } + } + return 0; +} + +gboolean on_wMainW_key_release_event (GtkWidget *widget, GdkEventKey *event, gpointer user_data) { + u16 Key = lookup_key(event->keyval); + RM_KEY( Cur_Keypad, Key ); + if(desmume_running()) update_keypad(Cur_Keypad); + return 1; +} + + + +/* ***** ***** SCREEN DRAWING ***** ***** */ +#define RAW_W 256 +#define RAW_H 192 +#define RAW_OFFSET 256*192*sizeof(u16) +#define MAX_SIZE 3 +u32 on_screen_image32[RAW_W*RAW_H*2*MAX_SIZE*MAX_SIZE]; + +int inline screen_size() { + int sz = ScreenCoeff_Size[0]; + return RAW_W*RAW_H*2*sz*sz*sizeof(u32); +} +int inline offset_pixels_lower_screen() { + return screen_size()/2; +} + +void black_screen () { + /* removes artifacts when resizing with scanlines */ + memset(on_screen_image32,0,screen_size()); +} + +#ifndef GTKGLEXT_AVAILABLE +// they are empty if no opengl +// else see gdk_gl.c / gdk_gl.h +BOOL my_gl_Begin (int screen) { return FALSE; } +void my_gl_End (int screen) {} +void reshape (GtkWidget * widget, int screen) {} +void init_GL_capabilities( int use_software_convert) {} + +int has_pix_col_map=0; +u32 pix_col_map[0x8000]; + +static void init_pix_col_map() { + // precalc factors + int a,b,c,A,B,C,rA,rB,rC; + if (has_pix_col_map) return; + for (a=0; a<0x20; a++) { + A=a<<10; rA=A<<9; + for (b=0; b<0x20; b++) { + B=b<<5; rB=B<<6; + for (c=0; c<0x20; c++) { + C=c; rC=C<<3; + pix_col_map[A|B|C]=rA|rB|rC; + } + } + } + has_pix_col_map=1; +} + +static void decode_screen () { + + int x,y, m, W,H,L,BL; + u32 image[RAW_H*2][RAW_W], pix; + u16 * pixel = (u16*)&GPU_screen; + u32 * rgb32 = &on_screen_image32[0]; + + /* decode colors */ + init_pix_col_map(); + for (y=0; y= 0, x--, y=0, y < RAW_H, y++) + LOOP(x=RAW_W-1, x >= 0, x--, y=RAW_H, y < RAW_H*2, y++) + } else { + H=RAW_H*2; W=RAW_W; + LOOP(y=0, y < RAW_H*2, y++, x=0, x < RAW_W, x++) + } +} + +gboolean screen (GtkWidget * widget, int off) { + int H,W,L; + if (off==0) + decode_screen(); + + if (ScreenRotate) { + W=RAW_H; H=RAW_W; + } else { + H=RAW_H; W=RAW_W; + } + L=W*ScreenCoeff_Size[0]*sizeof(u32); + off*= offset_pixels_lower_screen(); + + gdk_draw_rgb_32_image (widget->window, + widget->style->fg_gc[widget->state],0,0, + W*ScreenCoeff_Size[0], H*ScreenCoeff_Size[0], + GDK_RGB_DITHER_NONE,((guchar*)on_screen_image32)+off,L); + return TRUE; +} +#endif /* if GTKGLEXT_AVAILABLE */ + + +/* OUTPUT SCREENS */ +gboolean on_wDrawScreen_expose_event (GtkWidget *widget, GdkEventExpose *event, gpointer user_data) { + int scr = dyn_CAST(int,user_data); + return screen(widget, scr); +} +gboolean on_wDrawScreen_configure_event(GtkWidget *widget, GdkEventConfigure *event, gpointer user_data) { + int scr = dyn_CAST(int,user_data); + reshape(widget, scr); return TRUE; +} + + + + + +/* ***** ***** INPUT STYLUS / MOUSE ***** ***** */ + +static void resize_incremental(int i, GdkEventScroll *event) { +#ifdef GTKGLEXT_AVAILABLE + float zoom_inc=.125, zoom_min=0.25, zoom_max=5.0; +#else + float zoom_inc=1.0, zoom_min=1.0, zoom_max=3.0; +#endif + switch (event->direction) { + case GDK_SCROLL_UP: + ScreenCoeff_Size[i]=MIN(ScreenCoeff_Size[i]+zoom_inc,zoom_max); break; + case GDK_SCROLL_DOWN: + ScreenCoeff_Size[i]=MAX(ScreenCoeff_Size[i]-zoom_inc,zoom_min); break; + case GDK_SCROLL_LEFT: + case GDK_SCROLL_RIGHT: + return; + } + resize(ScreenCoeff_Size[0],ScreenCoeff_Size[1]); +} + +gboolean on_wDrawScreen_scroll_event (GtkWidget *widget, GdkEvent *event, gpointer user_data) { + int scr = dyn_CAST(int,user_data); + // separate zoom factors not supported yet + scr = 0; + resize_incremental(scr,(GdkEventScroll*)event); + + return TRUE; +} + +static void set_touch_pos (int x, int y) { + s32 EmuX, EmuY; + x /= ScreenCoeff_Size[1]; + y /= ScreenCoeff_Size[1]; + EmuX = x; EmuY = y; + if (ScreenRotate==90.0 || ScreenRotate==270.0) { EmuX = 256-y; EmuY = x; } + if(EmuX<0) EmuX = 0; else if(EmuX>255) EmuX = 255; + if(EmuY<0) EmuY = 0; else if(EmuY>192) EmuY = 192; + if (ScreenInvert) { + EmuX = 255-EmuX; + EmuY = 192-EmuY; + } + NDS_setTouchPos(EmuX, EmuY); +} + +gboolean on_wDrawScreen_button_press_event (GtkWidget *widget, GdkEventButton *event, gpointer user_data) { + int scr = dyn_CAST(int,user_data); + GdkModifierType state; + gint x,y; + + switch (event->button) { + case 1: + if (((scr==1) ^ ScreenInvert) && desmume_running()) { + click = TRUE; + gdk_window_get_pointer(widget->window, &x, &y, &state); + if (state & GDK_BUTTON1_MASK) + set_touch_pos(x,y); + } + break; + case 3: break; + case 2: + // filter out 2x / 3x clicks + if (event->type==GDK_BUTTON_PRESS) + rotate(ScreenRotate + 90.0); break; + } + return TRUE; +} + +gboolean on_wDrawScreen_button_release_event (GtkWidget *widget, GdkEventButton *event, gpointer user_data) { + int scr = dyn_CAST(int,user_data); + if ((scr==1) ^ ScreenInvert) { + if (click) NDS_releaseTouch(); + click = FALSE; + } + return TRUE; +} + +gboolean on_wDrawScreen_motion_notify_event (GtkWidget *widget, GdkEventMotion *event, gpointer user_data) { + int scr = dyn_CAST(int,user_data); + GdkModifierType state; + gint x,y; + + if (((scr==1) ^ ScreenInvert) && click) + { + if(event->is_hint) + gdk_window_get_pointer(widget->window, &x, &y, &state); + else + { + x= (gint)event->x; + y= (gint)event->y; + state=(GdkModifierType)event->state; + } + // fprintf(stderr,"X=%d, Y=%d, S&1=%d\n", x,y,state&GDK_BUTTON1_MASK); + if(state & GDK_BUTTON1_MASK) + set_touch_pos(x,y); + } + return TRUE; +} + + + + + +/* ***** ***** KEYBOARD CONFIG / KEY DEFINITION ***** ***** */ +u16 Keypad_Temp[NB_KEYS]; +guint temp_Key=0; + +static void init_labels() { + int i; + char text[50], bname[20]; + GtkButton *b; + for (i=0; ikeyval; + current_key_label(); + return TRUE; +} + +static void ask(GtkButton*b, int key) { + char text[50]; + GtkDialog * dlg = (GtkDialog*)glade_xml_get_widget(xml, "wKeyDlg"); + key--; /* key = bit position, start with 1 */ + temp_Key = Keypad_Temp[key]; + current_key_label(); + switch (gtk_dialog_run(dlg)) + { + case GTK_RESPONSE_OK: + Keypad_Temp[key]=temp_Key; + snprintf(text, 50, "%s : %s",key_names[key],KEYNAME(temp_Key)); + gtk_button_set_label(b,text); + break; + case GTK_RESPONSE_CANCEL: + case GTK_RESPONSE_NONE: + break; + } + gtk_widget_hide((GtkWidget*)dlg); +} + +/* Joystick configuration / Key definition */ +static void ask_joy_key(GtkButton*b, int key) +{ + char text[50]; + u16 joykey; + + GtkWidget * dlg = (GtkWidget*)glade_xml_get_widget(xml, "wJoyDlg"); + + key--; /* remove 1 to get index */ + gtk_widget_show_now(dlg); + /* Need to force event processing. Otherwise, popup won't show up. */ + while ( gtk_events_pending() ) gtk_main_iteration(); + joykey = get_set_joy_key(key); + snprintf(text, 50, "%s : %d",key_names[key],joykey); + gtk_button_set_label(b,text); + gtk_widget_hide((GtkWidget*)dlg); +} + +/* Joystick configuration / Key definition */ +static void ask_joy_axis(u8 key, u8 opposite_key) +{ + char text[50]; + char current_button[50], opposite_button[50]; + GtkWidget * dlg; + GtkButton * btn; + + key--; /* remove 1 to get index */ + opposite_key--; + + snprintf(current_button, 50, "button_joy_%s",key_names[key]); + snprintf(opposite_button, 50, "button_joy_%s",key_names[opposite_key]); + dlg = (GtkWidget*)glade_xml_get_widget(xml, "wJoyDlg"); + + gtk_widget_show(dlg); + /* Need to force event processing. Otherwise, popup won't show up. */ + while ( gtk_events_pending() ) gtk_main_iteration(); + get_set_joy_axis(key, opposite_key); + + snprintf(text, 50, "%s : %d",key_names[key],joypad_cfg[key]); + btn = (GtkButton*)glade_xml_get_widget(xml, current_button); + gtk_button_set_label(btn,text); + + snprintf(text, 50, "%s : %d",key_names[opposite_key],joypad_cfg[opposite_key]); + btn = (GtkButton*)glade_xml_get_widget(xml, opposite_button); + gtk_button_set_label(btn,text); + + gtk_widget_hide((GtkWidget*)dlg); +} + +/* Bind a keyboard key to a keypad key */ +void on_button_kb_key_clicked (GtkButton *b, gpointer user_data) +{ + int key = dyn_CAST( int, user_data ); + ask( b, key ); +} + +/* Bind a joystick axis to a keypad directionnal pad */ +void on_button_joy_axis_clicked (GtkButton *b, gpointer user_data) +{ + int key = dyn_CAST( int, user_data ); + ask_joy_axis( key, key+1 ); +} + +/* Bind a joystick button to a keypad key */ +void on_button_joy_key_clicked (GtkButton *b, gpointer user_data) +{ + int key = dyn_CAST( int, user_data ); + ask_joy_key( b, key ); +} diff --git a/desmume/src/gtk-glade/callbacks_IO.h b/src/gtk-glade/callbacks_IO.h old mode 100755 new mode 100644 similarity index 98% rename from desmume/src/gtk-glade/callbacks_IO.h rename to src/gtk-glade/callbacks_IO.h index a8530ff34..fd2c8ddda --- a/desmume/src/gtk-glade/callbacks_IO.h +++ b/src/gtk-glade/callbacks_IO.h @@ -1,52 +1,52 @@ -/* callbacks_IO.h - this file is part of DeSmuME - * - * Copyright (C) 2007 Damien Nozay (damdoum) - * Copyright (C) 2007 Pascal Giard (evilynux) - * Author: damdoum at users.sourceforge.net - * - * This file is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2, or (at your option) - * any later version. - * - * This file is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; see the file COPYING. If not, write to - * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -#include "globals.h" -#include "gdk_gl.h" - -extern "C" { - -/* INPUT BUTTONS / KEYBOARD */ -G_MODULE_EXPORT gboolean on_wMainW_key_press_event (GtkWidget *widget, GdkEventKey *event, gpointer user_data); -G_MODULE_EXPORT gboolean on_wMainW_key_release_event (GtkWidget *widget, GdkEventKey *event, gpointer user_data); - -/* OUTPUT SCREENS */ -G_MODULE_EXPORT gboolean on_wDrawScreen_expose_event (GtkWidget *widget, GdkEventExpose *event, gpointer user_data); -G_MODULE_EXPORT gboolean on_wDrawScreen_configure_event(GtkWidget *widget, GdkEventConfigure *event, gpointer data); - - -/* INPUT STYLUS / MOUSE */ -G_MODULE_EXPORT gboolean on_wDrawScreen_motion_notify_event (GtkWidget *widget, GdkEventMotion *event, gpointer user_data); -G_MODULE_EXPORT gboolean on_wDrawScreen_button_release_event(GtkWidget *widget, GdkEventButton *event, gpointer user_data); -G_MODULE_EXPORT gboolean on_wDrawScreen_button_press_event (GtkWidget *widget, GdkEventButton *event, gpointer user_data); -G_MODULE_EXPORT gboolean on_wDrawScreen_scroll_event (GtkWidget *widget, GdkEvent *event, gpointer user_data); - -/* KEYBOARD CONFIG / KEY DEFINITION */ -G_MODULE_EXPORT gboolean on_wKeyDlg_key_press_event (GtkWidget *widget, GdkEventKey *event, gpointer user_data); -G_MODULE_EXPORT void on_wKeybConfDlg_response (GtkDialog *dialog, gint arg1, gpointer user_data); -G_MODULE_EXPORT void on_button_kb_key_clicked (GtkButton *button, gpointer user_data); - -/* Joystick configuration / Key definition */ -G_MODULE_EXPORT void on_button_joy_axis_clicked (GtkButton *button, gpointer user_data); -G_MODULE_EXPORT void on_button_joy_key_clicked (GtkButton *button, gpointer user_data); - -} +/* callbacks_IO.h - this file is part of DeSmuME + * + * Copyright (C) 2007 Damien Nozay (damdoum) + * Copyright (C) 2007 Pascal Giard (evilynux) + * Author: damdoum at users.sourceforge.net + * + * This file is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2, or (at your option) + * any later version. + * + * This file is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; see the file COPYING. If not, write to + * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#include "globals.h" +#include "gdk_gl.h" + +extern "C" { + +/* INPUT BUTTONS / KEYBOARD */ +G_MODULE_EXPORT gboolean on_wMainW_key_press_event (GtkWidget *widget, GdkEventKey *event, gpointer user_data); +G_MODULE_EXPORT gboolean on_wMainW_key_release_event (GtkWidget *widget, GdkEventKey *event, gpointer user_data); + +/* OUTPUT SCREENS */ +G_MODULE_EXPORT gboolean on_wDrawScreen_expose_event (GtkWidget *widget, GdkEventExpose *event, gpointer user_data); +G_MODULE_EXPORT gboolean on_wDrawScreen_configure_event(GtkWidget *widget, GdkEventConfigure *event, gpointer data); + + +/* INPUT STYLUS / MOUSE */ +G_MODULE_EXPORT gboolean on_wDrawScreen_motion_notify_event (GtkWidget *widget, GdkEventMotion *event, gpointer user_data); +G_MODULE_EXPORT gboolean on_wDrawScreen_button_release_event(GtkWidget *widget, GdkEventButton *event, gpointer user_data); +G_MODULE_EXPORT gboolean on_wDrawScreen_button_press_event (GtkWidget *widget, GdkEventButton *event, gpointer user_data); +G_MODULE_EXPORT gboolean on_wDrawScreen_scroll_event (GtkWidget *widget, GdkEvent *event, gpointer user_data); + +/* KEYBOARD CONFIG / KEY DEFINITION */ +G_MODULE_EXPORT gboolean on_wKeyDlg_key_press_event (GtkWidget *widget, GdkEventKey *event, gpointer user_data); +G_MODULE_EXPORT void on_wKeybConfDlg_response (GtkDialog *dialog, gint arg1, gpointer user_data); +G_MODULE_EXPORT void on_button_kb_key_clicked (GtkButton *button, gpointer user_data); + +/* Joystick configuration / Key definition */ +G_MODULE_EXPORT void on_button_joy_axis_clicked (GtkButton *button, gpointer user_data); +G_MODULE_EXPORT void on_button_joy_key_clicked (GtkButton *button, gpointer user_data); + +} diff --git a/desmume/src/gtk-glade/dTools/callbacks_1_ioregs.cpp b/src/gtk-glade/dTools/callbacks_1_ioregs.cpp old mode 100755 new mode 100644 similarity index 96% rename from desmume/src/gtk-glade/dTools/callbacks_1_ioregs.cpp rename to src/gtk-glade/dTools/callbacks_1_ioregs.cpp index 96915839d..9c27ffb44 --- a/desmume/src/gtk-glade/dTools/callbacks_1_ioregs.cpp +++ b/src/gtk-glade/dTools/callbacks_1_ioregs.cpp @@ -1,163 +1,163 @@ -/* callbacks_1_ioregs.cpp - this file is part of DeSmuME - * - * Copyright (C) 2007 Damien Nozay (damdoum) - * Copyright (C) 2007 Pascal Giard (evilynux) - * Author: damdoum at users.sourceforge.net - * - * This file is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2, or (at your option) - * any later version. - * - * This file is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; see the file COPYING. If not, write to - * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -#include "callbacks_dtools.h" -#include "dTools_display.h" - -/* ***** ***** IO REGISTERS ***** ***** */ -static int cpu=0; -static BOOL init=FALSE; -static int size_=0; -static dTools_dsp dsp; - -static void update_regs_fast(); -static void update_regs(); - -/* Register name list */ -#define NBR_IO_REGS 7 - -typedef struct -{ - char name[20]; - u32 addr; - BOOL trunc; -} reg_name_addr; - -const reg_name_addr Reg_Names_Addr[NBR_IO_REGS] = - { - { "REG_IPCFIFOCNT", REG_IPCFIFOCNT, TRUE }, - { "REG_SPICNT", REG_SPICNT, TRUE }, - { "REG_IME", REG_IME, TRUE }, - { "REG_IE", REG_IE, FALSE }, - { "REG_IF", REG_IF, FALSE }, - { "REG_POWCNT1", REG_POWCNT1, TRUE }, - { "REG_DISPCAPCNT", REG_DISPA_DISPCAPCNT, FALSE } - }; - -/* update */ - -static void wtools_1_update () { - update_regs_fast(); -} - - - -/* Update register display */ - -static u32 mem[NBR_IO_REGS]; - -static void update_regs_fast(){ - char text[10]; - int i; u32 w, m; - for( i = 0; i < NBR_IO_REGS; i++ ) - { - w = MMU_read32(cpu,Reg_Names_Addr[i].addr); - m = mem[i]; - if ( Reg_Names_Addr[i].trunc ) { - w &= 0xFFFF; - m &= 0xFFFF; - } - mem[i] = w; - if (w == m) continue; - - if ( Reg_Names_Addr[i].trunc ) - sprintf(text, " 0x%04X", w); - else - sprintf(text, "0x%08X", w); - - dTools_display_select_attr(&dsp, 2); - dTools_display_clear_char(&dsp, size_+3, i, 10); - dTools_display_draw_text(&dsp, size_+3, i, text); - } -} - -static void update_regs() -{ - char text[80]; - int len, i; - - if (init==FALSE) { - GtkWidget * wPaint = glade_xml_get_widget(xml_tools, "wtools_1_draw"); - - for( i = 0; i < NBR_IO_REGS; i++ ) { - len = strlen(Reg_Names_Addr[i].name); - if (size_ "); - dTools_display_add_markup(&dsp, "0x00000000"); - dTools_display_add_markup(&dsp, "0x00000000"); - init=TRUE; - } - - dTools_display_clear(&dsp); - for( i = 0; i < NBR_IO_REGS; i++ ) - { - mem[i] = MMU_read32(cpu,Reg_Names_Addr[i].addr); - if ( Reg_Names_Addr[i].trunc ) - sprintf(text, " 0x%04X", mem[i]); - else - sprintf(text, "0x%08X", mem[i]); - - dTools_display_select_attr(&dsp, 0); - dTools_display_draw_text(&dsp, 0, i, Reg_Names_Addr[i].name); - dTools_display_draw_text(&dsp, size_, i, " : "); - dTools_display_select_attr(&dsp, 1); - dTools_display_draw_text(&dsp, size_+3, i, text); - } -} - -gboolean on_wtools_1_draw_button_release_event(GtkWidget *widget, GdkEventButton *event, gpointer user_data) { - // clear the red marks :) - if (event->button==1) - update_regs(); - return TRUE; -} -gboolean on_wtools_1_draw_expose_event (GtkWidget *widget, GdkEventExpose *event, gpointer user_data) { - update_regs(); - return TRUE; -} - - -void on_wtools_1_combo_cpu_changed (GtkComboBox *widget, gpointer user_data) { - /* c == 0 means ARM9 */ - cpu=gtk_combo_box_get_active(widget); - update_regs(); -} - -/* show, register, unregister */ -void on_wtools_1_IOregs_show (GtkWidget *widget, gpointer user_data) { - GtkWidget * combo = glade_xml_get_widget(xml_tools, "wtools_1_combo_cpu"); - - // do as if we had selected this button and ARM7 cpu - gtk_combo_box_set_active((GtkComboBox*)combo, 0); - register_Tool(wtools_1_update); -} - -gboolean on_wtools_1_IOregs_close (GtkWidget *widget, ...) { - unregister_Tool(wtools_1_update); - gtk_widget_hide(widget); - return TRUE; -} - +/* callbacks_1_ioregs.cpp - this file is part of DeSmuME + * + * Copyright (C) 2007 Damien Nozay (damdoum) + * Copyright (C) 2007 Pascal Giard (evilynux) + * Author: damdoum at users.sourceforge.net + * + * This file is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2, or (at your option) + * any later version. + * + * This file is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; see the file COPYING. If not, write to + * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#include "callbacks_dtools.h" +#include "dTools_display.h" + +/* ***** ***** IO REGISTERS ***** ***** */ +static int cpu=0; +static BOOL init=FALSE; +static int size_=0; +static dTools_dsp dsp; + +static void update_regs_fast(); +static void update_regs(); + +/* Register name list */ +#define NBR_IO_REGS 7 + +typedef struct +{ + char name[20]; + u32 addr; + BOOL trunc; +} reg_name_addr; + +const reg_name_addr Reg_Names_Addr[NBR_IO_REGS] = + { + { "REG_IPCFIFOCNT", REG_IPCFIFOCNT, TRUE }, + { "REG_SPICNT", REG_SPICNT, TRUE }, + { "REG_IME", REG_IME, TRUE }, + { "REG_IE", REG_IE, FALSE }, + { "REG_IF", REG_IF, FALSE }, + { "REG_POWCNT1", REG_POWCNT1, TRUE }, + { "REG_DISPCAPCNT", REG_DISPA_DISPCAPCNT, FALSE } + }; + +/* update */ + +static void wtools_1_update () { + update_regs_fast(); +} + + + +/* Update register display */ + +static u32 mem[NBR_IO_REGS]; + +static void update_regs_fast(){ + char text[10]; + int i; u32 w, m; + for( i = 0; i < NBR_IO_REGS; i++ ) + { + w = MMU_read32(cpu,Reg_Names_Addr[i].addr); + m = mem[i]; + if ( Reg_Names_Addr[i].trunc ) { + w &= 0xFFFF; + m &= 0xFFFF; + } + mem[i] = w; + if (w == m) continue; + + if ( Reg_Names_Addr[i].trunc ) + sprintf(text, " 0x%04X", w); + else + sprintf(text, "0x%08X", w); + + dTools_display_select_attr(&dsp, 2); + dTools_display_clear_char(&dsp, size_+3, i, 10); + dTools_display_draw_text(&dsp, size_+3, i, text); + } +} + +static void update_regs() +{ + char text[80]; + int len, i; + + if (init==FALSE) { + GtkWidget * wPaint = glade_xml_get_widget(xml_tools, "wtools_1_draw"); + + for( i = 0; i < NBR_IO_REGS; i++ ) { + len = strlen(Reg_Names_Addr[i].name); + if (size_ "); + dTools_display_add_markup(&dsp, "0x00000000"); + dTools_display_add_markup(&dsp, "0x00000000"); + init=TRUE; + } + + dTools_display_clear(&dsp); + for( i = 0; i < NBR_IO_REGS; i++ ) + { + mem[i] = MMU_read32(cpu,Reg_Names_Addr[i].addr); + if ( Reg_Names_Addr[i].trunc ) + sprintf(text, " 0x%04X", mem[i]); + else + sprintf(text, "0x%08X", mem[i]); + + dTools_display_select_attr(&dsp, 0); + dTools_display_draw_text(&dsp, 0, i, Reg_Names_Addr[i].name); + dTools_display_draw_text(&dsp, size_, i, " : "); + dTools_display_select_attr(&dsp, 1); + dTools_display_draw_text(&dsp, size_+3, i, text); + } +} + +gboolean on_wtools_1_draw_button_release_event(GtkWidget *widget, GdkEventButton *event, gpointer user_data) { + // clear the red marks :) + if (event->button==1) + update_regs(); + return TRUE; +} +gboolean on_wtools_1_draw_expose_event (GtkWidget *widget, GdkEventExpose *event, gpointer user_data) { + update_regs(); + return TRUE; +} + + +void on_wtools_1_combo_cpu_changed (GtkComboBox *widget, gpointer user_data) { + /* c == 0 means ARM9 */ + cpu=gtk_combo_box_get_active(widget); + update_regs(); +} + +/* show, register, unregister */ +void on_wtools_1_IOregs_show (GtkWidget *widget, gpointer user_data) { + GtkWidget * combo = glade_xml_get_widget(xml_tools, "wtools_1_combo_cpu"); + + // do as if we had selected this button and ARM7 cpu + gtk_combo_box_set_active((GtkComboBox*)combo, 0); + register_Tool(wtools_1_update); +} + +gboolean on_wtools_1_IOregs_close (GtkWidget *widget, ...) { + unregister_Tool(wtools_1_update); + gtk_widget_hide(widget); + return TRUE; +} + diff --git a/desmume/src/gtk-glade/dTools/callbacks_2_memview.cpp b/src/gtk-glade/dTools/callbacks_2_memview.cpp old mode 100755 new mode 100644 similarity index 96% rename from desmume/src/gtk-glade/dTools/callbacks_2_memview.cpp rename to src/gtk-glade/dTools/callbacks_2_memview.cpp index 3e5a18ecf..3f7faf3e8 --- a/desmume/src/gtk-glade/dTools/callbacks_2_memview.cpp +++ b/src/gtk-glade/dTools/callbacks_2_memview.cpp @@ -1,289 +1,289 @@ -/* callbacks_2_memview.cpp - this file is part of DeSmuME - * - * Copyright (C) 2007 Damien Nozay (damdoum) - * Author: damdoum at users.sourceforge.net - * - * This file is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2, or (at your option) - * any later version. - * - * This file is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; see the file COPYING. If not, write to - * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -#include "callbacks_dtools.h" -#include "dTools_display.h" - -/* ***** ***** MEMORY VIEWER ***** ***** */ - -enum SHOW { - Bit8, - Bit16, - Bit32 -}; - -static BOOL init=FALSE; -static enum SHOW packmode=Bit8; -static u32 address=0, tmpaddr=0; -int cpu=0; -static char patt[512]; -static u8 mem[0x100]; -static dTools_dsp dsp; - -static GtkEntry *wAddress; -static GtkRange *wRange; - -static void refresh(); -static void initialize(); - - -/* update */ - -static void wtools_2_update() { - int i,j; - u8 m8, *mem8 =mem; - u16 m16, *mem16=(u16*)mem; - u32 m32, *mem32=(u32*)mem; - u32 addr; - char txt[16]; - - // red - dTools_display_select_attr(&dsp, 3); - - addr = address; - switch (packmode) { - case Bit8: - for (i=0; i<0x10; i++) { - for (j=0; j<16; j++, addr++,mem8++) { - m8 = *mem8; *mem8 = MMU_read8(cpu, addr); - if (m8 != *mem8) { - sprintf(txt, "%02X", *mem8); - dTools_display_clear_char(&dsp, 12+3*j, i, 3); - dTools_display_draw_text(&dsp, 12+3*j, i, txt); - } - } - } - break; - case Bit16: - for (i=0; i<0x10; i++) { - for (j=0; j<16; j+=2, addr+=2,mem16++) { - m16 = *mem16; *mem16 = MMU_read16(cpu, addr); - if (m16 != *mem16) { - sprintf(txt, " %04X", *mem16); - dTools_display_clear_char(&dsp, 12+3*j, i, 6); - dTools_display_draw_text(&dsp, 12+3*j, i, txt); - } - } - } - break; - case Bit32: - for (i=0; i<0x10; i++) { - for (j=0; j<16; j+=4, addr+=4,mem32++) { - m32 = *mem32; *mem32 = MMU_read32(cpu, addr); - if (m32 != *mem32) { - sprintf(txt, " %08X", *mem32); - dTools_display_clear_char(&dsp, 12+3*j, i, 12); - dTools_display_draw_text(&dsp, 12+3*j, i, txt); - } - } - } - break; - } -} - -gboolean on_wtools_2_draw_button_release_event(GtkWidget *widget, GdkEventButton *event, gpointer user_data) { - // clear the red marks :) - if (event->button==1) - refresh(); - - return TRUE; -} - - - - -/* which cpu we look into */ - -void on_wtools_2_cpu_changed (GtkComboBox *widget, gpointer user_data) { - /* c == 0 means ARM9 */ - cpu=gtk_combo_box_get_active(widget); - refresh(); -} - - -/* how to pack bytes */ - -void on_wtools_2_r8_toggled (GtkToggleButton *togglebutton, gpointer user_data) { packmode=Bit8; refresh(); } -void on_wtools_2_r16_toggled (GtkToggleButton *togglebutton, gpointer user_data) { packmode=Bit16; refresh(); } -void on_wtools_2_r32_toggled (GtkToggleButton *togglebutton, gpointer user_data) { packmode=Bit32; refresh(); } - -/* which address */ -#define RANGE_MIN 0 -#define RANGE_MAX 0x10000000 -#define ADDR_MASK 0xFFFFFFF -#define STEP_ONE_LINE 0x1 -#define STEP_ONE_PAGE 0x10 -#define STEP_x10_PAGE 0x100 - -static void scroll_address(u32 addr) { - address = (addr & ADDR_MASK); - refresh(); -} -static void change_address(u32 addr) { - addr /= 0x10; - gtk_range_set_value(wRange, addr); -} -static void add_to_address(s32 inc) { - u32 addr = (address+inc) & ADDR_MASK; - gtk_range_set_value(wRange, addr); -} - -void on_wtools_2_GotoAddress_activate (GtkEntry *entry, gpointer user_data) { - change_address(strtol(gtk_entry_get_text(entry),NULL,0)); -} -void on_wtools_2_GotoAddress_changed (GtkEntry *entry, gpointer user_data) { - tmpaddr=strtol(gtk_entry_get_text(entry),NULL,0); -} -void on_wtools_2_GotoButton_clicked (GtkButton *button, gpointer user_data) { - change_address(tmpaddr); -} - - -/* show, register, unregister */ - -void on_wtools_2_MemView_show (GtkWidget *widget, gpointer user_data) { - initialize(); - register_Tool(wtools_2_update); -} -gboolean on_wtools_2_MemView_close (GtkWidget *widget, ...) { - unregister_Tool(wtools_2_update); - dTools_display_free(&dsp); - gtk_widget_hide(widget); - return TRUE; -} - - -/* scroll functions :D */ - -void on_wtools_2_scroll_value_changed (GtkRange *range, gpointer user_data) { - u32 addr=(u32)gtk_range_get_value(range); - scroll_address(addr); -} -gboolean on_wtools_2_draw_scroll_event (GtkWidget *widget, GdkEventScroll *event, gpointer user_data) { - switch (event->direction) { - case GDK_SCROLL_UP: - add_to_address(-STEP_ONE_PAGE); break; - case GDK_SCROLL_DOWN: - add_to_address(+STEP_ONE_PAGE); break; - case GDK_SCROLL_LEFT: - case GDK_SCROLL_RIGHT: - default: - break; - } - return TRUE; -} -gboolean on_wtools_2_draw_expose_event (GtkWidget *widget, GdkEventExpose *event, gpointer user_data) { refresh(); return TRUE; } - - - - - -/* initialise what we have to */ - -static void initialize() { - GtkWidget * combo; - GtkWidget * wPaint; - GtkAdjustment *adj; - - if (init) return; - combo = glade_xml_get_widget(xml_tools, "wtools_2_cpu"); - adj = (GtkAdjustment *)gtk_adjustment_new (RANGE_MIN, RANGE_MIN, RANGE_MAX, - STEP_ONE_LINE, STEP_x10_PAGE, STEP_ONE_PAGE); - - // get widget reference - wAddress = (GtkEntry*)glade_xml_get_widget(xml_tools, "wtools_2_GotoAddress"); - wRange = (GtkRange*)glade_xml_get_widget(xml_tools, "wtools_2_scroll"); - wPaint = glade_xml_get_widget(xml_tools, "wtools_2_draw"); - - dTools_display_init(&dsp, wPaint, 80, 16, 5); - -#define PATT(x) x"" x "" -#define DUP(x) x x - sprintf(patt, "0000:0000 | %s| 0123456789ABCDEF", DUP(DUP(DUP(PATT("00_")))) ); - dTools_display_add_markup(&dsp, patt); - sprintf(patt, "0000:0000 | %s| 0123456789ABCDEF", DUP(DUP(PATT("_0000_"))) ); - dTools_display_add_markup(&dsp, patt); - sprintf(patt, "0000:0000 | %s| 0123456789ABCDEF", DUP(PATT("__00000000__")) ); - dTools_display_add_markup(&dsp, patt); -#undef DUP -#undef PATT - strcpy(patt, "__00000000__"); - dTools_display_add_markup(&dsp, patt); - - init = TRUE; - gtk_combo_box_set_active((GtkComboBox*)combo, 0); - gtk_range_set_adjustment(wRange, adj); - change_address(RANGE_MIN); -} - -/* PAINT memory panel */ -static void refresh() { - int i,j,addr; - u8 c; - u8 *mem8=mem; - u16 *mem16=(u16*)mem; - u32 *mem32=(u32*)mem; - - char *ptxt, txt[]="0000:0000 | 00 11 22 33 44 55 66 77 88 99 AA BB CC DD EE FF | 0123456789ABCDEF\0"; - - if (!init) return; - - addr=address * 0x10; - for (i=0; i<0x100; i++) - mem[i] = MMU_read8(cpu, addr+i); - - dTools_display_clear(&dsp); - switch(packmode) { - case Bit8: dTools_display_select_attr(&dsp, 0); break; - case Bit16: dTools_display_select_attr(&dsp, 1); break; - case Bit32: dTools_display_select_attr(&dsp, 2); break; - } - - -// draw memory content here - for (i=0; i<0x10; i++) { - ptxt = txt; - sprintf(ptxt, "%04X:%04X | ", (addr>>16)&0xFFFF, addr&0xFFFF); ptxt+=12; - switch(packmode) { - case Bit8: - for (j=0; j<16; j++,ptxt+=3) - sprintf(ptxt, "%02X ", mem8[j]); - break; - case Bit16: - for (j=0; j<16; j+=2,ptxt+=6, mem16++) - sprintf(ptxt, " %04X ", *mem16); - break; - case Bit32: - for (j=0; j<16; j+=4,ptxt+=12, mem32++) - sprintf(ptxt, " %08X ", *mem32); - break; - } - sprintf(ptxt, "| "); ptxt +=2; - for (j=0; j<16; j++,ptxt++) - // only ASCII printable - sprintf(ptxt, "%c", ((c=mem8[j])<0x20)?'.':((c>=0x7F)?'.':c)); - addr += 16; - mem8 +=16; - *(ptxt)=0; - - dTools_display_draw_text(&dsp, 0, i, txt); - } -} +/* callbacks_2_memview.cpp - this file is part of DeSmuME + * + * Copyright (C) 2007 Damien Nozay (damdoum) + * Author: damdoum at users.sourceforge.net + * + * This file is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2, or (at your option) + * any later version. + * + * This file is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; see the file COPYING. If not, write to + * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#include "callbacks_dtools.h" +#include "dTools_display.h" + +/* ***** ***** MEMORY VIEWER ***** ***** */ + +enum SHOW { + Bit8, + Bit16, + Bit32 +}; + +static BOOL init=FALSE; +static enum SHOW packmode=Bit8; +static u32 address=0, tmpaddr=0; +int cpu=0; +static char patt[512]; +static u8 mem[0x100]; +static dTools_dsp dsp; + +static GtkEntry *wAddress; +static GtkRange *wRange; + +static void refresh(); +static void initialize(); + + +/* update */ + +static void wtools_2_update() { + int i,j; + u8 m8, *mem8 =mem; + u16 m16, *mem16=(u16*)mem; + u32 m32, *mem32=(u32*)mem; + u32 addr; + char txt[16]; + + // red + dTools_display_select_attr(&dsp, 3); + + addr = address; + switch (packmode) { + case Bit8: + for (i=0; i<0x10; i++) { + for (j=0; j<16; j++, addr++,mem8++) { + m8 = *mem8; *mem8 = MMU_read8(cpu, addr); + if (m8 != *mem8) { + sprintf(txt, "%02X", *mem8); + dTools_display_clear_char(&dsp, 12+3*j, i, 3); + dTools_display_draw_text(&dsp, 12+3*j, i, txt); + } + } + } + break; + case Bit16: + for (i=0; i<0x10; i++) { + for (j=0; j<16; j+=2, addr+=2,mem16++) { + m16 = *mem16; *mem16 = MMU_read16(cpu, addr); + if (m16 != *mem16) { + sprintf(txt, " %04X", *mem16); + dTools_display_clear_char(&dsp, 12+3*j, i, 6); + dTools_display_draw_text(&dsp, 12+3*j, i, txt); + } + } + } + break; + case Bit32: + for (i=0; i<0x10; i++) { + for (j=0; j<16; j+=4, addr+=4,mem32++) { + m32 = *mem32; *mem32 = MMU_read32(cpu, addr); + if (m32 != *mem32) { + sprintf(txt, " %08X", *mem32); + dTools_display_clear_char(&dsp, 12+3*j, i, 12); + dTools_display_draw_text(&dsp, 12+3*j, i, txt); + } + } + } + break; + } +} + +gboolean on_wtools_2_draw_button_release_event(GtkWidget *widget, GdkEventButton *event, gpointer user_data) { + // clear the red marks :) + if (event->button==1) + refresh(); + + return TRUE; +} + + + + +/* which cpu we look into */ + +void on_wtools_2_cpu_changed (GtkComboBox *widget, gpointer user_data) { + /* c == 0 means ARM9 */ + cpu=gtk_combo_box_get_active(widget); + refresh(); +} + + +/* how to pack bytes */ + +void on_wtools_2_r8_toggled (GtkToggleButton *togglebutton, gpointer user_data) { packmode=Bit8; refresh(); } +void on_wtools_2_r16_toggled (GtkToggleButton *togglebutton, gpointer user_data) { packmode=Bit16; refresh(); } +void on_wtools_2_r32_toggled (GtkToggleButton *togglebutton, gpointer user_data) { packmode=Bit32; refresh(); } + +/* which address */ +#define RANGE_MIN 0 +#define RANGE_MAX 0x10000000 +#define ADDR_MASK 0xFFFFFFF +#define STEP_ONE_LINE 0x1 +#define STEP_ONE_PAGE 0x10 +#define STEP_x10_PAGE 0x100 + +static void scroll_address(u32 addr) { + address = (addr & ADDR_MASK); + refresh(); +} +static void change_address(u32 addr) { + addr /= 0x10; + gtk_range_set_value(wRange, addr); +} +static void add_to_address(s32 inc) { + u32 addr = (address+inc) & ADDR_MASK; + gtk_range_set_value(wRange, addr); +} + +void on_wtools_2_GotoAddress_activate (GtkEntry *entry, gpointer user_data) { + change_address(strtol(gtk_entry_get_text(entry),NULL,0)); +} +void on_wtools_2_GotoAddress_changed (GtkEntry *entry, gpointer user_data) { + tmpaddr=strtol(gtk_entry_get_text(entry),NULL,0); +} +void on_wtools_2_GotoButton_clicked (GtkButton *button, gpointer user_data) { + change_address(tmpaddr); +} + + +/* show, register, unregister */ + +void on_wtools_2_MemView_show (GtkWidget *widget, gpointer user_data) { + initialize(); + register_Tool(wtools_2_update); +} +gboolean on_wtools_2_MemView_close (GtkWidget *widget, ...) { + unregister_Tool(wtools_2_update); + dTools_display_free(&dsp); + gtk_widget_hide(widget); + return TRUE; +} + + +/* scroll functions :D */ + +void on_wtools_2_scroll_value_changed (GtkRange *range, gpointer user_data) { + u32 addr=(u32)gtk_range_get_value(range); + scroll_address(addr); +} +gboolean on_wtools_2_draw_scroll_event (GtkWidget *widget, GdkEventScroll *event, gpointer user_data) { + switch (event->direction) { + case GDK_SCROLL_UP: + add_to_address(-STEP_ONE_PAGE); break; + case GDK_SCROLL_DOWN: + add_to_address(+STEP_ONE_PAGE); break; + case GDK_SCROLL_LEFT: + case GDK_SCROLL_RIGHT: + default: + break; + } + return TRUE; +} +gboolean on_wtools_2_draw_expose_event (GtkWidget *widget, GdkEventExpose *event, gpointer user_data) { refresh(); return TRUE; } + + + + + +/* initialise what we have to */ + +static void initialize() { + GtkWidget * combo; + GtkWidget * wPaint; + GtkAdjustment *adj; + + if (init) return; + combo = glade_xml_get_widget(xml_tools, "wtools_2_cpu"); + adj = (GtkAdjustment *)gtk_adjustment_new (RANGE_MIN, RANGE_MIN, RANGE_MAX, + STEP_ONE_LINE, STEP_x10_PAGE, STEP_ONE_PAGE); + + // get widget reference + wAddress = (GtkEntry*)glade_xml_get_widget(xml_tools, "wtools_2_GotoAddress"); + wRange = (GtkRange*)glade_xml_get_widget(xml_tools, "wtools_2_scroll"); + wPaint = glade_xml_get_widget(xml_tools, "wtools_2_draw"); + + dTools_display_init(&dsp, wPaint, 80, 16, 5); + +#define PATT(x) x"" x "" +#define DUP(x) x x + sprintf(patt, "0000:0000 | %s| 0123456789ABCDEF", DUP(DUP(DUP(PATT("00_")))) ); + dTools_display_add_markup(&dsp, patt); + sprintf(patt, "0000:0000 | %s| 0123456789ABCDEF", DUP(DUP(PATT("_0000_"))) ); + dTools_display_add_markup(&dsp, patt); + sprintf(patt, "0000:0000 | %s| 0123456789ABCDEF", DUP(PATT("__00000000__")) ); + dTools_display_add_markup(&dsp, patt); +#undef DUP +#undef PATT + strcpy(patt, "__00000000__"); + dTools_display_add_markup(&dsp, patt); + + init = TRUE; + gtk_combo_box_set_active((GtkComboBox*)combo, 0); + gtk_range_set_adjustment(wRange, adj); + change_address(RANGE_MIN); +} + +/* PAINT memory panel */ +static void refresh() { + int i,j,addr; + u8 c; + u8 *mem8=mem; + u16 *mem16=(u16*)mem; + u32 *mem32=(u32*)mem; + + char *ptxt, txt[]="0000:0000 | 00 11 22 33 44 55 66 77 88 99 AA BB CC DD EE FF | 0123456789ABCDEF\0"; + + if (!init) return; + + addr=address * 0x10; + for (i=0; i<0x100; i++) + mem[i] = MMU_read8(cpu, addr+i); + + dTools_display_clear(&dsp); + switch(packmode) { + case Bit8: dTools_display_select_attr(&dsp, 0); break; + case Bit16: dTools_display_select_attr(&dsp, 1); break; + case Bit32: dTools_display_select_attr(&dsp, 2); break; + } + + +// draw memory content here + for (i=0; i<0x10; i++) { + ptxt = txt; + sprintf(ptxt, "%04X:%04X | ", (addr>>16)&0xFFFF, addr&0xFFFF); ptxt+=12; + switch(packmode) { + case Bit8: + for (j=0; j<16; j++,ptxt+=3) + sprintf(ptxt, "%02X ", mem8[j]); + break; + case Bit16: + for (j=0; j<16; j+=2,ptxt+=6, mem16++) + sprintf(ptxt, " %04X ", *mem16); + break; + case Bit32: + for (j=0; j<16; j+=4,ptxt+=12, mem32++) + sprintf(ptxt, " %08X ", *mem32); + break; + } + sprintf(ptxt, "| "); ptxt +=2; + for (j=0; j<16; j++,ptxt++) + // only ASCII printable + sprintf(ptxt, "%c", ((c=mem8[j])<0x20)?'.':((c>=0x7F)?'.':c)); + addr += 16; + mem8 +=16; + *(ptxt)=0; + + dTools_display_draw_text(&dsp, 0, i, txt); + } +} diff --git a/desmume/src/gtk-glade/dTools/callbacks_3_palview.cpp b/src/gtk-glade/dTools/callbacks_3_palview.cpp old mode 100755 new mode 100644 similarity index 96% rename from desmume/src/gtk-glade/dTools/callbacks_3_palview.cpp rename to src/gtk-glade/dTools/callbacks_3_palview.cpp index 85dcba76d..de4872dc5 --- a/desmume/src/gtk-glade/dTools/callbacks_3_palview.cpp +++ b/src/gtk-glade/dTools/callbacks_3_palview.cpp @@ -1,167 +1,167 @@ -/* callbacks_3_palview.cpp - this file is part of DeSmuME - * - * Copyright (C) 2007 Damien Nozay (damdoum) - * Author: damdoum at users.sourceforge.net - * - * This file is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2, or (at your option) - * any later version. - * - * This file is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; see the file COPYING. If not, write to - * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -#include "callbacks_dtools.h" - -void init_combo_palette(GtkComboBox *combo, u16 ** addresses) { - GtkTreeIter iter; - GtkListStore* model = gtk_list_store_new(1, G_TYPE_STRING); - gtk_combo_box_set_model(combo, (GtkTreeModel*)model); - - int i=0; - -#define DO(str,addr,r) \ - gtk_list_store_append (model, &iter); \ - gtk_list_store_set (model, &iter, 0, str,-1); \ - addresses[i]=((u16*)(addr) r); i++; - - DO("Main screen BG PAL", ARM9Mem.ARM9_VMEM,) - DO("Main screen SPR PAL", ARM9Mem.ARM9_VMEM,+0x100) - DO("Sub screen BG PAL", ARM9Mem.ARM9_VMEM,+0x200) - DO("Sub screen SPR PAL", ARM9Mem.ARM9_VMEM,+0x300) - DO("Main screen ExtPAL 0", ARM9Mem.ExtPal[0][0],) - DO("Main screen ExtPAL 1", ARM9Mem.ExtPal[0][1],) - DO("Main screen ExtPAL 2", ARM9Mem.ExtPal[0][2],) - DO("Main screen ExtPAL 3", ARM9Mem.ExtPal[0][3],) - DO("Sub screen ExtPAL 0", ARM9Mem.ExtPal[1][0],) - DO("Sub screen ExtPAL 1", ARM9Mem.ExtPal[1][1],) - DO("Sub screen ExtPAL 2", ARM9Mem.ExtPal[1][2],) - DO("Sub screen ExtPAL 3", ARM9Mem.ExtPal[1][3],) - DO("Main screen SPR ExtPAL 0", ARM9Mem.ObjExtPal[0][0],) - DO("Main screen SPR ExtPAL 1", ARM9Mem.ObjExtPal[0][1],) - DO("Sub screen SPR ExtPAL 0", ARM9Mem.ObjExtPal[1][0],) - DO("Sub screen SPR ExtPAL 1", ARM9Mem.ObjExtPal[1][1],) - DO("Texture PAL 0", ARM9Mem.texInfo.texPalSlot[0],) - DO("Texture PAL 1", ARM9Mem.texInfo.texPalSlot[1],) - DO("Texture PAL 2", ARM9Mem.texInfo.texPalSlot[2],) - DO("Texture PAL 3", ARM9Mem.texInfo.texPalSlot[3],) -#undef DO - gtk_combo_box_set_active(combo,0); -} - -static u16* base_addr[20]; -static BOOL init=FALSE; -static int palnum=0; -static int palindex=0; -static void refresh(); -static GtkWidget * wPaint; -static GtkSpinButton * wSpin; -static u16 mem[0x100]; - - -static COLOR c; -static COLOR32 c32; -static GdkGC * gdkGC; - -static inline void paint_col(int x, int y, u16 col) { - c.val = col; - COLOR_16_32(c,c32) - gdk_rgb_gc_set_foreground(gdkGC, c32.val); - gdk_draw_rectangle(wPaint->window, gdkGC, TRUE, x, y, 15, 15); -} -static inline void paint_cross(int x, int y) { - gdk_rgb_gc_set_foreground(gdkGC, 0x808080); - gdk_draw_rectangle(wPaint->window, gdkGC, TRUE, x, y, 15, 15); - gdk_rgb_gc_set_foreground(gdkGC, 0xFF0000); - gdk_draw_line(wPaint->window, gdkGC, x+14, y+1, x+1, y+14); - gdk_draw_line(wPaint->window, gdkGC, x+1, y+1, x+14, y+14); -} - - -static void wtools_3_update() { - int i,x,y,X,Y; - u16 * addr = base_addr[palindex], tmp; - - gdkGC = gdk_gc_new(wPaint->window); - if (addr) { - memcpy(mem, addr, 0x100*sizeof(u16)); - i=0; - for(y=Y= 0; y < 16; y++,Y+=16) - for(x=X= 0; x < 16; x++,X+=16) { - tmp=mem[i]; - if (tmp != (mem[i]=*(addr+Y+x+0x100*palnum))) - paint_col(X,Y,mem[i]); - } - } else { - for(y=Y= 0; y < 16; y++,Y+=16) - for(x=X= 0; x < 16; x++,X+=16) - paint_cross(X,Y); - } - g_object_unref(gdkGC); -} - - -static void refresh() { - int x,y,X,Y; u16 * addr = base_addr[palindex]; - - gdkGC = gdk_gc_new(wPaint->window); - if (addr) { - memcpy(mem, addr, 0x100*sizeof(u16)); - for(y=Y= 0; y < 16; y++,Y+=16) - for(x=X= 0; x < 16; x++,X+=16) - paint_col(X,Y,*(addr+Y+x+0x100*palnum)); - } else { - for(y=Y= 0; y < 16; y++,Y+=16) - for(x=X= 0; x < 16; x++,X+=16) - paint_cross(X,Y); - } - g_object_unref(gdkGC); -} - -static void initialize() { - GtkComboBox * combo; - if (init) return; - - wPaint= glade_xml_get_widget(xml_tools, "wtools_3_draw"); - wSpin = (GtkSpinButton*)glade_xml_get_widget(xml_tools, "wtools_3_palnum"); - combo = (GtkComboBox*)glade_xml_get_widget(xml_tools, "wtools_3_palette"); - - init_combo_palette(combo, base_addr); - - init=TRUE; -} - - -void on_wtools_3_PalView_show (GtkWidget *widget, gpointer data) { - initialize(); - register_Tool(wtools_3_update); -} -gboolean on_wtools_3_PalView_close (GtkWidget *widget, ...) { - unregister_Tool(wtools_3_update); - gtk_widget_hide(widget); - return TRUE; -} - - -gboolean on_wtools_3_draw_expose_event (GtkWidget * widget, GdkEventExpose *event, gpointer user_data) { - refresh(); - return TRUE; -} -void on_wtools_3_palette_changed (GtkComboBox *combo, gpointer user_data) { - palindex = gtk_combo_box_get_active(combo); - gtk_widget_set_sensitive((GtkWidget*)wSpin,(palindex >=4)); - gtk_spin_button_set_value(wSpin,0); - refresh(); -} -void on_wtools_3_palnum_value_changed (GtkSpinButton *spin, gpointer user_data) { - palnum = gtk_spin_button_get_value_as_int(spin); - refresh(); -} +/* callbacks_3_palview.cpp - this file is part of DeSmuME + * + * Copyright (C) 2007 Damien Nozay (damdoum) + * Author: damdoum at users.sourceforge.net + * + * This file is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2, or (at your option) + * any later version. + * + * This file is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; see the file COPYING. If not, write to + * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#include "callbacks_dtools.h" + +void init_combo_palette(GtkComboBox *combo, u16 ** addresses) { + GtkTreeIter iter; + GtkListStore* model = gtk_list_store_new(1, G_TYPE_STRING); + gtk_combo_box_set_model(combo, (GtkTreeModel*)model); + + int i=0; + +#define DO(str,addr,r) \ + gtk_list_store_append (model, &iter); \ + gtk_list_store_set (model, &iter, 0, str,-1); \ + addresses[i]=((u16*)(addr) r); i++; + + DO("Main screen BG PAL", ARM9Mem.ARM9_VMEM,) + DO("Main screen SPR PAL", ARM9Mem.ARM9_VMEM,+0x100) + DO("Sub screen BG PAL", ARM9Mem.ARM9_VMEM,+0x200) + DO("Sub screen SPR PAL", ARM9Mem.ARM9_VMEM,+0x300) + DO("Main screen ExtPAL 0", ARM9Mem.ExtPal[0][0],) + DO("Main screen ExtPAL 1", ARM9Mem.ExtPal[0][1],) + DO("Main screen ExtPAL 2", ARM9Mem.ExtPal[0][2],) + DO("Main screen ExtPAL 3", ARM9Mem.ExtPal[0][3],) + DO("Sub screen ExtPAL 0", ARM9Mem.ExtPal[1][0],) + DO("Sub screen ExtPAL 1", ARM9Mem.ExtPal[1][1],) + DO("Sub screen ExtPAL 2", ARM9Mem.ExtPal[1][2],) + DO("Sub screen ExtPAL 3", ARM9Mem.ExtPal[1][3],) + DO("Main screen SPR ExtPAL 0", ARM9Mem.ObjExtPal[0][0],) + DO("Main screen SPR ExtPAL 1", ARM9Mem.ObjExtPal[0][1],) + DO("Sub screen SPR ExtPAL 0", ARM9Mem.ObjExtPal[1][0],) + DO("Sub screen SPR ExtPAL 1", ARM9Mem.ObjExtPal[1][1],) + DO("Texture PAL 0", ARM9Mem.texInfo.texPalSlot[0],) + DO("Texture PAL 1", ARM9Mem.texInfo.texPalSlot[1],) + DO("Texture PAL 2", ARM9Mem.texInfo.texPalSlot[2],) + DO("Texture PAL 3", ARM9Mem.texInfo.texPalSlot[3],) +#undef DO + gtk_combo_box_set_active(combo,0); +} + +static u16* base_addr[20]; +static BOOL init=FALSE; +static int palnum=0; +static int palindex=0; +static void refresh(); +static GtkWidget * wPaint; +static GtkSpinButton * wSpin; +static u16 mem[0x100]; + + +static COLOR c; +static COLOR32 c32; +static GdkGC * gdkGC; + +static inline void paint_col(int x, int y, u16 col) { + c.val = col; + COLOR_16_32(c,c32) + gdk_rgb_gc_set_foreground(gdkGC, c32.val); + gdk_draw_rectangle(wPaint->window, gdkGC, TRUE, x, y, 15, 15); +} +static inline void paint_cross(int x, int y) { + gdk_rgb_gc_set_foreground(gdkGC, 0x808080); + gdk_draw_rectangle(wPaint->window, gdkGC, TRUE, x, y, 15, 15); + gdk_rgb_gc_set_foreground(gdkGC, 0xFF0000); + gdk_draw_line(wPaint->window, gdkGC, x+14, y+1, x+1, y+14); + gdk_draw_line(wPaint->window, gdkGC, x+1, y+1, x+14, y+14); +} + + +static void wtools_3_update() { + int i,x,y,X,Y; + u16 * addr = base_addr[palindex], tmp; + + gdkGC = gdk_gc_new(wPaint->window); + if (addr) { + memcpy(mem, addr, 0x100*sizeof(u16)); + i=0; + for(y=Y= 0; y < 16; y++,Y+=16) + for(x=X= 0; x < 16; x++,X+=16) { + tmp=mem[i]; + if (tmp != (mem[i]=*(addr+Y+x+0x100*palnum))) + paint_col(X,Y,mem[i]); + } + } else { + for(y=Y= 0; y < 16; y++,Y+=16) + for(x=X= 0; x < 16; x++,X+=16) + paint_cross(X,Y); + } + g_object_unref(gdkGC); +} + + +static void refresh() { + int x,y,X,Y; u16 * addr = base_addr[palindex]; + + gdkGC = gdk_gc_new(wPaint->window); + if (addr) { + memcpy(mem, addr, 0x100*sizeof(u16)); + for(y=Y= 0; y < 16; y++,Y+=16) + for(x=X= 0; x < 16; x++,X+=16) + paint_col(X,Y,*(addr+Y+x+0x100*palnum)); + } else { + for(y=Y= 0; y < 16; y++,Y+=16) + for(x=X= 0; x < 16; x++,X+=16) + paint_cross(X,Y); + } + g_object_unref(gdkGC); +} + +static void initialize() { + GtkComboBox * combo; + if (init) return; + + wPaint= glade_xml_get_widget(xml_tools, "wtools_3_draw"); + wSpin = (GtkSpinButton*)glade_xml_get_widget(xml_tools, "wtools_3_palnum"); + combo = (GtkComboBox*)glade_xml_get_widget(xml_tools, "wtools_3_palette"); + + init_combo_palette(combo, base_addr); + + init=TRUE; +} + + +void on_wtools_3_PalView_show (GtkWidget *widget, gpointer data) { + initialize(); + register_Tool(wtools_3_update); +} +gboolean on_wtools_3_PalView_close (GtkWidget *widget, ...) { + unregister_Tool(wtools_3_update); + gtk_widget_hide(widget); + return TRUE; +} + + +gboolean on_wtools_3_draw_expose_event (GtkWidget * widget, GdkEventExpose *event, gpointer user_data) { + refresh(); + return TRUE; +} +void on_wtools_3_palette_changed (GtkComboBox *combo, gpointer user_data) { + palindex = gtk_combo_box_get_active(combo); + gtk_widget_set_sensitive((GtkWidget*)wSpin,(palindex >=4)); + gtk_spin_button_set_value(wSpin,0); + refresh(); +} +void on_wtools_3_palnum_value_changed (GtkSpinButton *spin, gpointer user_data) { + palnum = gtk_spin_button_get_value_as_int(spin); + refresh(); +} diff --git a/desmume/src/gtk-glade/dTools/callbacks_4_tileview.cpp b/src/gtk-glade/dTools/callbacks_4_tileview.cpp old mode 100755 new mode 100644 similarity index 66% rename from desmume/src/gtk-glade/dTools/callbacks_4_tileview.cpp rename to src/gtk-glade/dTools/callbacks_4_tileview.cpp index dbf979c09..9c955d052 --- a/desmume/src/gtk-glade/dTools/callbacks_4_tileview.cpp +++ b/src/gtk-glade/dTools/callbacks_4_tileview.cpp @@ -1,329 +1,465 @@ -/* callbacks_3_palview.cpp - this file is part of DeSmuME - * - * Copyright (C) 2007 Damien Nozay (damdoum) - * Author: damdoum at users.sourceforge.net - * - * This file is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2, or (at your option) - * any later version. - * - * This file is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; see the file COPYING. If not, write to - * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -#include "callbacks_dtools.h" -#ifdef GTKGLEXT_AVAILABLE -#include "../gdk_gl.h" - -void init_combo_memory(GtkComboBox *combo, u8 ** addresses) { - GtkTreeIter iter; - GtkListStore* model = gtk_list_store_new(1, G_TYPE_STRING); - gtk_combo_box_set_model(combo, (GtkTreeModel*)model); - int i=0; - -#define DO(str,addr,r) \ - gtk_list_store_append (model, &iter); \ - gtk_list_store_set (model, &iter, 0, str,-1); \ - addresses[i]=(addr r); i++; - -// FIXME: update tileview to actually work -// DO("A-BG - 0x6000000",ARM9Mem.ARM9_ABG,) -// DO("A-BG - 0x6010000",ARM9Mem.ARM9_ABG,+0x10000) -// DO("A-BG - 0x6020000",ARM9Mem.ARM9_ABG,+0x20000) -// DO("A-BG - 0x6030000",ARM9Mem.ARM9_ABG,+0x30000) -// DO("A-BG - 0x6040000",ARM9Mem.ARM9_ABG,+0x40000) -// DO("A-BG - 0x6050000",ARM9Mem.ARM9_ABG,+0x50000) -// DO("A-BG - 0x6060000",ARM9Mem.ARM9_ABG,+0x60000) -// DO("A-BG - 0x6070000",ARM9Mem.ARM9_ABG,+0x70000) - -// DO("B-BG - 0x6200000",ARM9Mem.ARM9_BBG,) -// DO("B-BG - 0x6210000",ARM9Mem.ARM9_BBG,+0x10000) - -// DO("A-OBJ- 0x6400000",ARM9Mem.ARM9_AOBJ,) -// DO("A-OBJ- 0x6410000",ARM9Mem.ARM9_AOBJ,+0x10000) -// DO("A-OBJ- 0x6420000",ARM9Mem.ARM9_AOBJ,+0x20000) -// DO("A-OBJ- 0x6430000",ARM9Mem.ARM9_AOBJ,+0x30000) - -// DO("B-OBJ- 0x6600000",ARM9Mem.ARM9_BOBJ,) -// DO("B-OBJ- 0x6610000",ARM9Mem.ARM9_BOBJ,+0x10000) - - DO("LCD - 0x6800000",ARM9Mem.ARM9_LCD,) - DO("LCD - 0x6810000",ARM9Mem.ARM9_LCD,+0x10000) - DO("LCD - 0x6820000",ARM9Mem.ARM9_LCD,+0x20000) - DO("LCD - 0x6830000",ARM9Mem.ARM9_LCD,+0x30000) - DO("LCD - 0x6840000",ARM9Mem.ARM9_LCD,+0x40000) - DO("LCD - 0x6850000",ARM9Mem.ARM9_LCD,+0x50000) - DO("LCD - 0x6860000",ARM9Mem.ARM9_LCD,+0x60000) - DO("LCD - 0x6870000",ARM9Mem.ARM9_LCD,+0x70000) - DO("LCD - 0x6880000",ARM9Mem.ARM9_LCD,+0x80000) - DO("LCD - 0x6890000",ARM9Mem.ARM9_LCD,+0x90000) -#undef DO - gtk_combo_box_set_active(combo,0); -} - -static u16* pal_addr[20]; -static u8* mem_addr[26]; -static BOOL init=FALSE; -static int palnum=0; -static int palindex=0; -static int memnum=0; -static int colnum=0; -static void refresh(); -static GtkWidget * wPaint; -static GtkSpinButton * wSpin; -static int gl_context_num=0; - -#define TILE_NUM_MAX 1024 -#define TILE_W_SZ 8 -#define TILE_H_SZ 8 - -static void wtools_4_update() { - -} - -typedef u16 tileBMP[8*8]; - -static void refresh() { - u16 palette_16[64]; - u16 palette_256[64]; - u8 * index16, * index256, * indexBMP; - u16 * pal; - int tile_n, index; - guint Textures; - if (!init) return; - - index16 = index256 = indexBMP = mem_addr[memnum]; - - // this little thing doesnt display properly - // nothing drawn... - // seems that is the context is not shared there is a pb switching context -/* - if (!my_gl_Begin(gl_context_num)) return; - glClear( GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT ); - my_gl_DrawBeautifulQuad(); - my_gl_End(gl_context_num); - return; - -*/ - if (!my_gl_Begin(gl_context_num)) return; - - glClear( GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT ); -#if 1 - glEnable(GL_TEXTURE_2D); - glGenTextures(1, &Textures); - - //proxy - glBindTexture(GL_TEXTURE_2D, Textures); - glTexImage2D(GL_TEXTURE_2D, 0, GL_RGBA, - 256, 256, 0, - GL_RGBA, GL_UNSIGNED_SHORT_1_5_5_5_REV, indexBMP); - - glBegin(GL_QUADS); - glTexCoord2f(0.0, 0.0); glVertex2d(-1.0, 1.0); - glTexCoord2f(1.0, 0.0); glVertex2d( 1.0, 1.0); - glTexCoord2f(1.0, 1.0); glVertex2d( 1.0,-1.0); - glTexCoord2f(0.0, 1.0); glVertex2d(-1.0,-1.0); - glEnd(); - - glDeleteTextures(1, &Textures); - - my_gl_End(gl_context_num); - return; - - glTexImage2D(GL_PROXY_TEXTURE_2D, 0, GL_RGBA, - 256, 256, 0, - GL_RGBA, GL_UNSIGNED_SHORT_1_5_5_5_REV, NULL); - - - switch(colnum) { - case 0: //BMP - for (tile_n=0; tile_n> 5)<<3, - 8, 8, GL_RGBA, - GL_UNSIGNED_SHORT_1_5_5_5_REV, indexBMP); - indexBMP +=64; - } - break; - case 1: //256c - pal = pal_addr[palindex]; - if (pal) { - pal += palnum*256; - for (tile_n=0; tile_n<1024; tile_n++) { - for (index=0; index<64; index++) { - palette_256[index]=pal[*index256]; - index256++; - } - glTexSubImage2D(GL_TEXTURE_2D, 0, - (tile_n & 0x1F)<<3, (tile_n >> 5)<<3, - 8, 8, GL_RGBA, - GL_UNSIGNED_SHORT_1_5_5_5_REV, palette_256); - } - } - break; - case 2: //16c - pal = pal_addr[palindex]; - if (pal) { - pal += palnum*16; - for (tile_n=0; tile_n<1024; tile_n++) { - for (index=0; index<64; index++) { - if (index & 1) continue; - palette_16[index] =pal[*index16 & 15]; - palette_16[index+1]=pal[*index16 >> 4]; - index16++; - } - glTexSubImage2D(GL_TEXTURE_2D, 0, - (tile_n & 0x1F)<<3, (tile_n >> 5)<<3, - 8, 8, GL_RGBA, - GL_UNSIGNED_SHORT_1_5_5_5_REV, palette_16); - } - } - break; - } - - glBegin(GL_QUADS); - glTexCoord2f(0.0, 0.0); glVertex2d(-0.5, 0.5); - glTexCoord2f(0.0, 1.0); glVertex2d(-0.5,-0.5); - glTexCoord2f(1.0, 1.0); glVertex2d( 0.5,-0.5); - glTexCoord2f(1.0, 0.0); glVertex2d( 0.5, 0.5); - glEnd(); - - glDeleteTextures(1, &Textures); -#else - glDisable(GL_LIGHTING); - glDisable(GL_BLEND); - glMatrixMode(GL_PROJECTION); - glLoadIdentity(); - glMatrixMode(GL_MODELVIEW); - glLoadIdentity(); - glColor4ub(255,255,255,255); - switch(colnum) { - case 0: //BMP - { - tileBMP tiles * = indexBMP; - - for (tile_n=0; tile_n<1024; tile_n++) { - i = (tile_n & 0x1F) << 4; - j = (tile_n >> 5) << 12; - memcpy(bmp + j + i, indexBMP, 16); indexBMP += 16; j+=512; - memcpy(bmp + j + i, indexBMP, 16); indexBMP += 16; j+=512; - memcpy(bmp + j + i, indexBMP, 16); indexBMP += 16; j+=512; - memcpy(bmp + j + i, indexBMP, 16); indexBMP += 16; j+=512; - memcpy(bmp + j + i, indexBMP, 16); indexBMP += 16; j+=512; - memcpy(bmp + j + i, indexBMP, 16); indexBMP += 16; j+=512; - memcpy(bmp + j + i, indexBMP, 16); indexBMP += 16; j+=512; - memcpy(bmp + j + i, indexBMP, 16); indexBMP += 16; - } - glRasterPos2i(0,0); - glDrawPixels(256,256,GL_RGBA,GL_UNSIGNED_SHORT_1_5_5_5_REV, bmp); - } - break; - case 1: //256c - if (pal = pal_addr[palindex]) { - pal += palnum*256; - for (tile_n=0; tile_n<1024; tile_n++) { - for (index=0; index<64; index++) { - palette_256[index]=pal[*index256]; - index256++; - } - glRasterPos2i((tile_n & 0x1F)<<3, (tile_n >> 5)<<3); - glDrawPixels(8,8,GL_RGBA,GL_UNSIGNED_SHORT_1_5_5_5_REV, palette_256); - } - } - break; - case 2: //16c - if (pal = pal_addr[palindex]) { - pal += palnum*16; - for (tile_n=0; tile_n<1024; tile_n++) { - for (index=0; index<64; index++) { - if (index & 1) continue; - palette_16[index] =pal[*index16 & 15]; - palette_16[index+1]=pal[*index16 >> 4]; - index16++; - } - glRasterPos2i((tile_n & 0x1F)<<3, (tile_n >> 5)<<3); - glDrawPixels(8,8,GL_RGBA,GL_UNSIGNED_SHORT_1_5_5_5_REV, palette_16); - } - } - break; - } -#endif - my_gl_End(gl_context_num); -} - -static void initialize() { - GtkComboBox * combo; - if (init) return; - - wPaint= glade_xml_get_widget(xml_tools, "wDraw_Tile"); - wSpin = (GtkSpinButton*)glade_xml_get_widget(xml_tools, "wtools_4_palnum"); - combo = (GtkComboBox*)glade_xml_get_widget(xml_tools, "wtools_4_palette"); - init_combo_palette(combo, pal_addr); - combo = (GtkComboBox*)glade_xml_get_widget(xml_tools, "wtools_4_memory"); - init_combo_memory(combo, mem_addr); - - gl_context_num = init_GL_free_s(wPaint,0); - reshape(wPaint, gl_context_num); - gtk_widget_show(wPaint); - init=TRUE; -} - - -void on_wtools_4_TileView_show (GtkWidget *widget, gpointer data) { - initialize(); - register_Tool(wtools_4_update); -} -gboolean on_wtools_4_TileView_close (GtkWidget *widget, ...) { - unregister_Tool(wtools_4_update); - gtk_widget_hide(widget); - return TRUE; -} - -void on_wtools_4_palette_changed (GtkComboBox *combo, gpointer user_data) { - palindex = gtk_combo_box_get_active(combo); - gtk_widget_set_sensitive((GtkWidget*)wSpin,(palindex >=4)); - gtk_spin_button_set_value(wSpin,0); - gtk_widget_queue_draw(wPaint); -} -void on_wtools_4_palnum_value_changed (GtkSpinButton *spin, gpointer user_data) { - palnum = gtk_spin_button_get_value_as_int(spin); - gtk_widget_queue_draw(wPaint); -} -void on_wtools_4_memory_changed (GtkComboBox *combo, gpointer user_data) { - memnum = gtk_combo_box_get_active(combo); - gtk_widget_queue_draw(wPaint); -} -void on_wtools_4_rXX_toggled (GtkToggleButton *togglebutton, gpointer user_data) { - colnum = dyn_CAST(int,user_data); - gtk_widget_queue_draw(wPaint); -} -gboolean on_wDraw_Tile_expose_event (GtkWidget * w, GdkEventExpose * e, gpointer user_data) { - refresh(); - return TRUE; -} -#else -void on_wtools_4_TileView_show (GtkWidget *widget, gpointer data) { -} -gboolean on_wtools_4_TileView_close (GtkWidget *widget, ...) { - return FALSE; -} -void on_wtools_4_palette_changed (GtkComboBox *combo, gpointer user_data) { -} -void on_wtools_4_palnum_value_changed (GtkSpinButton *spin, gpointer user_data) { -} -void on_wtools_4_memory_changed (GtkComboBox *combo, gpointer user_data) { -} -void on_wtools_4_rXX_toggled (GtkToggleButton *togglebutton, gpointer user_data) { -} -gboolean on_wDraw_Tile_expose_event (GtkWidget * w, GdkEventExpose * e, gpointer user_data) { - return FALSE; -} -#endif +/* callbacks_3_palview.cpp - this file is part of DeSmuME + * + * Copyright (C) 2007 Damien Nozay (damdoum) + * Author: damdoum at users.sourceforge.net + * + * This file is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2, or (at your option) + * any later version. + * + * This file is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; see the file COPYING. If not, write to + * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#ifdef GTKGLEXT_AVAILABLE +#include "callbacks_dtools.h" +#include "../gdk_gl.h" + +void init_combo_memory(GtkComboBox *combo, u8 ** addresses) { + GtkTreeIter iter; + GtkListStore* model = gtk_list_store_new(1, G_TYPE_STRING); + gtk_combo_box_set_model(combo, (GtkTreeModel*)model); + int i=0; + +#define DO(str,addr,r) \ + gtk_list_store_append (model, &iter); \ + gtk_list_store_set (model, &iter, 0, str,-1); \ + addresses[i]=(addr r); i++; + +// FIXME: update tileview to actually work +// DO("A-BG - 0x6000000",ARM9Mem.ARM9_ABG,) +// DO("A-BG - 0x6010000",ARM9Mem.ARM9_ABG,+0x10000) +// DO("A-BG - 0x6020000",ARM9Mem.ARM9_ABG,+0x20000) +// DO("A-BG - 0x6030000",ARM9Mem.ARM9_ABG,+0x30000) +// DO("A-BG - 0x6040000",ARM9Mem.ARM9_ABG,+0x40000) +// DO("A-BG - 0x6050000",ARM9Mem.ARM9_ABG,+0x50000) +// DO("A-BG - 0x6060000",ARM9Mem.ARM9_ABG,+0x60000) +// DO("A-BG - 0x6070000",ARM9Mem.ARM9_ABG,+0x70000) + +// DO("B-BG - 0x6200000",ARM9Mem.ARM9_BBG,) +// DO("B-BG - 0x6210000",ARM9Mem.ARM9_BBG,+0x10000) + +// DO("A-OBJ- 0x6400000",ARM9Mem.ARM9_AOBJ,) +// DO("A-OBJ- 0x6410000",ARM9Mem.ARM9_AOBJ,+0x10000) +// DO("A-OBJ- 0x6420000",ARM9Mem.ARM9_AOBJ,+0x20000) +// DO("A-OBJ- 0x6430000",ARM9Mem.ARM9_AOBJ,+0x30000) + +// DO("B-OBJ- 0x6600000",ARM9Mem.ARM9_BOBJ,) +// DO("B-OBJ- 0x6610000",ARM9Mem.ARM9_BOBJ,+0x10000) + + DO("LCD - 0x6800000",ARM9Mem.ARM9_LCD,) + DO("LCD - 0x6810000",ARM9Mem.ARM9_LCD,+0x10000) + DO("LCD - 0x6820000",ARM9Mem.ARM9_LCD,+0x20000) + DO("LCD - 0x6830000",ARM9Mem.ARM9_LCD,+0x30000) + DO("LCD - 0x6840000",ARM9Mem.ARM9_LCD,+0x40000) + DO("LCD - 0x6850000",ARM9Mem.ARM9_LCD,+0x50000) + DO("LCD - 0x6860000",ARM9Mem.ARM9_LCD,+0x60000) + DO("LCD - 0x6870000",ARM9Mem.ARM9_LCD,+0x70000) + DO("LCD - 0x6880000",ARM9Mem.ARM9_LCD,+0x80000) + DO("LCD - 0x6890000",ARM9Mem.ARM9_LCD,+0x90000) +#undef DO + gtk_combo_box_set_active(combo,0); +} + +static u16* pal_addr[20]; +static u8* mem_addr[26]; +static BOOL init=FALSE; +static int palnum=0; +static int palindex=0; +static int memnum=0; +static int colnum=0; +static void refresh(); +static GtkWidget * wPaint; +static GtkSpinButton * wSpin; +static int gl_context_num=0; + +#define TILE_NUM_MAX 1024 +#define TILE_W_SZ 8 +#define TILE_H_SZ 8 + +static void wtools_4_update() { + +} + +typedef u16 tileBMP[8*8]; + +static void refresh() { + u16 palette_16[64]; + u16 palette_256[64]; + u8 * index16, * index256, * indexBMP; + u16 * pal; + int tile_n, index; + guint Textures; + if (!init) return; + + index16 = index256 = indexBMP = mem_addr[memnum]; + + // this little thing doesnt display properly + // nothing drawn... + // seems that is the context is not shared there is a pb switching context +/* + if (!my_gl_Begin(gl_context_num)) return; + glClear( GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT ); + my_gl_DrawBeautifulQuad(); + my_gl_End(gl_context_num); + return; + +*/ + if (!my_gl_Begin(gl_context_num)) return; + + glClear( GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT ); +#if 1 + glEnable(GL_TEXTURE_2D); + glGenTextures(1, &Textures); + + //proxy + glBindTexture(GL_TEXTURE_2D, Textures); + glTexImage2D(GL_TEXTURE_2D, 0, GL_RGBA, + 256, 256, 0, + GL_RGBA, GL_UNSIGNED_SHORT_1_5_5_5_REV, indexBMP); + + glBegin(GL_QUADS); + glTexCoord2f(0.0, 0.0); glVertex2d(-1.0, 1.0); + glTexCoord2f(1.0, 0.0); glVertex2d( 1.0, 1.0); + glTexCoord2f(1.0, 1.0); glVertex2d( 1.0,-1.0); + glTexCoord2f(0.0, 1.0); glVertex2d(-1.0,-1.0); + glEnd(); + + glDeleteTextures(1, &Textures); + + my_gl_End(gl_context_num); + return; + + glTexImage2D(GL_PROXY_TEXTURE_2D, 0, GL_RGBA, + 256, 256, 0, + GL_RGBA, GL_UNSIGNED_SHORT_1_5_5_5_REV, NULL); + + + switch(colnum) { + case 0: //BMP + for (tile_n=0; tile_n> 5)<<3, + 8, 8, GL_RGBA, + GL_UNSIGNED_SHORT_1_5_5_5_REV, indexBMP); + indexBMP +=64; + } + break; + case 1: //256c + pal = pal_addr[palindex]; + if (pal) { + pal += palnum*256; + for (tile_n=0; tile_n<1024; tile_n++) { + for (index=0; index<64; index++) { + palette_256[index]=pal[*index256]; + index256++; + } + glTexSubImage2D(GL_TEXTURE_2D, 0, + (tile_n & 0x1F)<<3, (tile_n >> 5)<<3, + 8, 8, GL_RGBA, + GL_UNSIGNED_SHORT_1_5_5_5_REV, palette_256); + } + } + break; + case 2: //16c + pal = pal_addr[palindex]; + if (pal) { + pal += palnum*16; + for (tile_n=0; tile_n<1024; tile_n++) { + for (index=0; index<64; index++) { + if (index & 1) continue; + palette_16[index] =pal[*index16 & 15]; + palette_16[index+1]=pal[*index16 >> 4]; + index16++; + } + glTexSubImage2D(GL_TEXTURE_2D, 0, + (tile_n & 0x1F)<<3, (tile_n >> 5)<<3, + 8, 8, GL_RGBA, + GL_UNSIGNED_SHORT_1_5_5_5_REV, palette_16); + } + } + break; + } + + glBegin(GL_QUADS); + glTexCoord2f(0.0, 0.0); glVertex2d(-0.5, 0.5); + glTexCoord2f(0.0, 1.0); glVertex2d(-0.5,-0.5); + glTexCoord2f(1.0, 1.0); glVertex2d( 0.5,-0.5); + glTexCoord2f(1.0, 0.0); glVertex2d( 0.5, 0.5); + glEnd(); + + glDeleteTextures(1, &Textures); +#else + glDisable(GL_LIGHTING); + glDisable(GL_BLEND); + glMatrixMode(GL_PROJECTION); + glLoadIdentity(); + glMatrixMode(GL_MODELVIEW); + glLoadIdentity(); + glColor4ub(255,255,255,255); + switch(colnum) { + case 0: //BMP + { + tileBMP tiles * = indexBMP; + + for (tile_n=0; tile_n<1024; tile_n++) { + i = (tile_n & 0x1F) << 4; + j = (tile_n >> 5) << 12; + memcpy(bmp + j + i, indexBMP, 16); indexBMP += 16; j+=512; + memcpy(bmp + j + i, indexBMP, 16); indexBMP += 16; j+=512; + memcpy(bmp + j + i, indexBMP, 16); indexBMP += 16; j+=512; + memcpy(bmp + j + i, indexBMP, 16); indexBMP += 16; j+=512; + memcpy(bmp + j + i, indexBMP, 16); indexBMP += 16; j+=512; + memcpy(bmp + j + i, indexBMP, 16); indexBMP += 16; j+=512; + memcpy(bmp + j + i, indexBMP, 16); indexBMP += 16; j+=512; + memcpy(bmp + j + i, indexBMP, 16); indexBMP += 16; + } + glRasterPos2i(0,0); + glDrawPixels(256,256,GL_RGBA,GL_UNSIGNED_SHORT_1_5_5_5_REV, bmp); + } + break; + case 1: //256c + if (pal = pal_addr[palindex]) { + pal += palnum*256; + for (tile_n=0; tile_n<1024; tile_n++) { + for (index=0; index<64; index++) { + palette_256[index]=pal[*index256]; + index256++; + } + glRasterPos2i((tile_n & 0x1F)<<3, (tile_n >> 5)<<3); + glDrawPixels(8,8,GL_RGBA,GL_UNSIGNED_SHORT_1_5_5_5_REV, palette_256); + } + } + break; + case 2: //16c + if (pal = pal_addr[palindex]) { + pal += palnum*16; + for (tile_n=0; tile_n<1024; tile_n++) { + for (index=0; index<64; index++) { + if (index & 1) continue; + palette_16[index] =pal[*index16 & 15]; + palette_16[index+1]=pal[*index16 >> 4]; + index16++; + } + glRasterPos2i((tile_n & 0x1F)<<3, (tile_n >> 5)<<3); + glDrawPixels(8,8,GL_RGBA,GL_UNSIGNED_SHORT_1_5_5_5_REV, palette_16); + } + } + break; + } +#endif + my_gl_End(gl_context_num); +} + +static void initialize() { + GtkComboBox * combo; + if (init) return; + + wPaint= glade_xml_get_widget(xml_tools, "wDraw_Tile"); + wSpin = (GtkSpinButton*)glade_xml_get_widget(xml_tools, "wtools_4_palnum"); + combo = (GtkComboBox*)glade_xml_get_widget(xml_tools, "wtools_4_palette"); + init_combo_palette(combo, pal_addr); + combo = (GtkComboBox*)glade_xml_get_widget(xml_tools, "wtools_4_memory"); + init_combo_memory(combo, mem_addr); + + gl_context_num = init_GL_free_s(wPaint,0); + reshape(wPaint, gl_context_num); + gtk_widget_show(wPaint); + init=TRUE; +} + + +void on_wtools_4_TileView_show (GtkWidget *widget, gpointer data) { + initialize(); + register_Tool(wtools_4_update); +} +gboolean on_wtools_4_TileView_close (GtkWidget *widget, ...) { + unregister_Tool(wtools_4_update); + gtk_widget_hide(widget); + return TRUE; +} + +void on_wtools_4_palette_changed (GtkComboBox *combo, gpointer user_data) { + palindex = gtk_combo_box_get_active(combo); + gtk_widget_set_sensitive((GtkWidget*)wSpin,(palindex >=4)); + gtk_spin_button_set_value(wSpin,0); + gtk_widget_queue_draw(wPaint); +} +void on_wtools_4_palnum_value_changed (GtkSpinButton *spin, gpointer user_data) { + palnum = gtk_spin_button_get_value_as_int(spin); + gtk_widget_queue_draw(wPaint); +} +void on_wtools_4_memory_changed (GtkComboBox *combo, gpointer user_data) { + memnum = gtk_combo_box_get_active(combo); + gtk_widget_queue_draw(wPaint); +} +void on_wtools_4_rXX_toggled (GtkToggleButton *togglebutton, gpointer user_data) { + colnum = dyn_CAST(int,user_data); + gtk_widget_queue_draw(wPaint); +} +gboolean on_wDraw_Tile_expose_event (GtkWidget * w, GdkEventExpose * e, gpointer user_data) { + refresh(); + return TRUE; +} + + + +#if 0 + +void other_screen (GtkWidget * widget, int screen) { + if (!my_gl_Begin(screen)) return; + + my_gl_Identity(); + glClear( GL_COLOR_BUFFER_BIT ); + + GPU * gpu = &SubScreen; + struct _DISPCNT * dispCnt = &(gpu->dispx_st)->dispx_DISPCNT.bits; + _OAM_ * spriteInfo = (_OAM_*)(gpu->oam + 127);// + 127; + u16 i; int mode; + u8 prioTab[256]; + +#define MODE_IDX_16 1 +#define MODE_IDX_256 2 +#define MODE_BMP 3 + + for(i = 0; i<127; ++i, --spriteInfo) + { + size sprSize; + s32 sprX, sprY, x, y, lg; + int xdir; + u8 prio, * src; + u16 * pal; + u16 i,j; + u16 rotScaleA,rotScaleB,rotScaleC,rotScaleD; + int block; + + prio = spriteInfo->Priority; + + // get sprite location and size + sprX = (spriteInfo->X<<23)>>23; + sprY = spriteInfo->Y; + sprSize = sprSizeTab[spriteInfo->Size][spriteInfo->Shape]; + + lg = sprSize.x; + + if (spriteInfo->RotScale == 2) continue; +#if 0 + // switch TOP<-->BOTTOM + if (spriteInfo->VFlip); + // switch LEFT<-->RIGHT + if (spriteInfo->HFlip); + + { + u16 rotScaleIndex; + // index from 0 to 31 + rotScaleIndex = spriteInfo->RotScalIndex + (spriteInfo->HFlip<<1) + (spriteInfo->VFlip << 2); + rotScaleA = T1ReadWord((u8*)(gpu->oam + rotScaleIndex*0x20 + 0x06),0) ; + rotScaleB = T1ReadWord((u8*)(gpu->oam + rotScaleIndex*0x20 + 0x0E),0) ; + rotScaleC = T1ReadWord((u8*)(gpu->oam + rotScaleIndex*0x20 + 0x16),0) ; + rotScaleD = T1ReadWord((u8*)(gpu->oam + rotScaleIndex*0x20 + 0x1E),0) ; + } + + if (spriteInfo->Mode == 2) { + src = gpu->sprMem + ((spriteInfo->TileIndex)<<5) + ((y>>3)<<10); + continue; + } + + if (spriteInfo->Mode == 3) /* sprite is in BMP format */ + { + src = (gpu->sprMem) + (spriteInfo->TileIndex<<4) + (y<sprBMPBoundary); + + if (dispCnt->OBJ_BMP_2D_dim) // 256*256 + src = (gpu->sprMem) + (((spriteInfo->TileIndex&0x3F0) * 64 + (spriteInfo->TileIndex&0x0F) *8) << 1); + else // 128 * 512 + src = (gpu->sprMem) + (((spriteInfo->TileIndex&0x3E0) * 64 + (spriteInfo->TileIndex&0x1F) *8) << 1); + continue; + } + + + if(dispCnt->OBJ_Tile_mapping) + + if (spriteInfo->Depth) { + //256 colors + glColorTable(GL_TEXTURE_COLOR_TABLE_EXT, + GL_RGBA, 256, GL_RGBA, + GL_UNSIGNED_SHORT_1_5_5_5_REV, pal); + } else { + pal += (spriteInfo->PaletteIndex<<4); + glColorTable(GL_TEXTURE_COLOR_TABLE_EXT, + GL_RGBA, 16, GL_RGBA, + GL_UNSIGNED_SHORT_1_5_5_5_REV, pal); + } + glTexImage2D(GL_TEXTURE_2D, 0, COLOR_INDEX4_EXT, + 16, 16, 0, + GL_COLOR_INDEX, GL_UNSIGNED_BYTE, src); + src = gpu->sprMem + ((spriteInfo->TileIndex)<<5) + ((y>>3)<<10); + pal = (u16*)(ARM9Mem.ARM9_VMEM + 0x200 + gpu->core *0x400); +#endif + } + + int boundary = 32; + if (dispCnt->OBJ_Tile_mapping) + boundary <<= dispCnt->OBJ_Tile_mapping_Bound; + + int bmpboundary = 128; + bmpboundary <<= (dispCnt->OBJ_BMP_mapping & dispCnt->OBJ_BMP_1D_Bound); + + guint Textures[3]; + glGenTextures(3, Textures); + glBindTexture(GL_TEXTURE_2D, Textures[0]); + //proxy + glTexImage2D(GL_PROXY_TEXTURE_2D, 0, GL_RGBA, + 256, 256, 0, + GL_RGBA, GL_UNSIGNED_SHORT_1_5_5_5_REV, NULL); + + u16 * pal = (u16*)(ARM9Mem.ARM9_VMEM + 0x200 + gpu->core *0x400); + + u8 palette_16[1024][64]; + u8 palette_256[1024][64]; +// u16 tile_BMP[1024][64]; + u8 * index16 = gpu->sprMem; + u8 * index256 = gpu->sprMem; + u16 * indexBMP = gpu->sprMem; + int tile_n, index; + if (gpu->sprMem != NULL) + for (tile_n=0; tile_n<1024; tile_n++) { + for (index=0; index<64; index++) { +// tile_BMP[tile_n][index]=*indexBMP; +// indexBMP++; + palette_256[tile_n][index]=pal[*index256]; + index256++; + + if (index & 1) continue; + palette_16[tile_n][index] =pal[*index16 & 15]; + palette_16[tile_n][index+1]=pal[*index16 >> 4]; + index16++; + } + glBindTexture(GL_TEXTURE_2D, Textures[0]); + glTexSubImage2D(GL_TEXTURE_2D, 0, + (tile_n & 0x1F)<<3, (tile_n >> 5)<<3, + 8, 8, GL_RGBA, + GL_UNSIGNED_SHORT_1_5_5_5_REV, indexBMP); + } + + glBegin(GL_QUADS); + glTexCoord2f(0.0, 0.0); glVertex2d(-1.0, 1.0); + glTexCoord2f(0.0, 1.0); glVertex2d(-1.0,-1.0); + glTexCoord2f(1.0, 1.0); glVertex2d( 1.0,-1.0); + glTexCoord2f(1.0, 0.0); glVertex2d( 1.0, 1.0); + glEnd(); + + my_gl_End(screen); + glDeleteTextures(3, &Textures); +} + +#endif + +#endif diff --git a/desmume/src/gtk-glade/dTools/callbacks_dtools.h b/src/gtk-glade/dTools/callbacks_dtools.h old mode 100755 new mode 100644 similarity index 98% rename from desmume/src/gtk-glade/dTools/callbacks_dtools.h rename to src/gtk-glade/dTools/callbacks_dtools.h index 50a9a6257..b94dfe355 --- a/desmume/src/gtk-glade/dTools/callbacks_dtools.h +++ b/src/gtk-glade/dTools/callbacks_dtools.h @@ -1,79 +1,79 @@ -/* callbacks_dtools.h - this file is part of DeSmuME - * - * Copyright (C) 2007 Damien Nozay (damdoum) - * Author: damdoum at users.sourceforge.net - * - * This file is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2, or (at your option) - * any later version. - * - * This file is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; see the file COPYING. If not, write to - * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -#ifndef __CALLBACKS_DTOOLS_H__ -#define __CALLBACKS_DTOOLS_H__ - -#include "../globals.h" - -extern "C" { - -/* ***** ***** IO REGISTERS ***** ***** */ -G_MODULE_EXPORT void on_wtools_1_combo_cpu_changed (GtkComboBox *, gpointer ); -G_MODULE_EXPORT void on_wtools_1_IOregs_show (GtkWidget *, gpointer ); -G_MODULE_EXPORT gboolean on_wtools_1_IOregs_close (GtkWidget *, ...); -G_MODULE_EXPORT gboolean on_wtools_1_draw_button_release_event(GtkWidget *, GdkEventButton *, gpointer ); -G_MODULE_EXPORT gboolean on_wtools_1_draw_expose_event (GtkWidget *widget, GdkEventExpose *event, gpointer user_data); - -/* ***** ***** MEMORY VIEWER ***** ***** */ -G_MODULE_EXPORT void on_wtools_2_MemView_show (GtkWidget *, gpointer ); -G_MODULE_EXPORT gboolean on_wtools_2_MemView_close (GtkWidget *, ...); - -G_MODULE_EXPORT void on_wtools_2_cpu_changed (GtkComboBox *, gpointer ); -G_MODULE_EXPORT void on_wtools_2_r8_toggled (GtkToggleButton *, gpointer ); -G_MODULE_EXPORT void on_wtools_2_r16_toggled (GtkToggleButton *, gpointer ); -G_MODULE_EXPORT void on_wtools_2_r32_toggled (GtkToggleButton *, gpointer ); -G_MODULE_EXPORT void on_wtools_2_GotoAddress_activate (GtkEntry *, gpointer ); -G_MODULE_EXPORT void on_wtools_2_GotoAddress_changed (GtkEntry *, gpointer ); -G_MODULE_EXPORT void on_wtools_2_GotoButton_clicked (GtkButton *, gpointer ); -G_MODULE_EXPORT void on_wtools_2_scroll_value_changed (GtkRange *, gpointer ); -G_MODULE_EXPORT gboolean on_wtools_2_draw_button_release_event(GtkWidget *, GdkEventButton *, gpointer ); -G_MODULE_EXPORT gboolean on_wtools_2_draw_expose_event (GtkWidget *, GdkEventExpose *, gpointer ); -G_MODULE_EXPORT gboolean on_wtools_2_draw_scroll_event (GtkWidget *, GdkEventScroll *, gpointer ); - -/* ***** ***** PALETTE VIEWER ***** ***** */ -// initialise combo box for all palettes -void init_combo_palette(GtkComboBox *combo, u16 ** addresses); - -G_MODULE_EXPORT void on_wtools_3_PalView_show (GtkWidget *, gpointer ); -G_MODULE_EXPORT gboolean on_wtools_3_PalView_close (GtkWidget *, ...); -G_MODULE_EXPORT gboolean on_wtools_3_PalView_delete_event (GtkWidget *, GdkEvent *, gpointer ); -G_MODULE_EXPORT gboolean on_wtools_3_draw_expose_event (GtkWidget *, GdkEventExpose *, gpointer ); -G_MODULE_EXPORT void on_wtools_3_palette_changed (GtkComboBox *, gpointer ); -G_MODULE_EXPORT void on_wtools_3_palnum_value_changed (GtkSpinButton *, gpointer ); - - -/* ***** ***** TILE VIEWER ***** ***** */ -// initialise combo box for all palettes -void init_combo_memory(GtkComboBox *combo, u8 ** addresses); - -G_MODULE_EXPORT void on_wtools_4_TileView_show (GtkWidget *, gpointer ); -G_MODULE_EXPORT gboolean on_wtools_4_TileView_close (GtkWidget *, ...); -G_MODULE_EXPORT gboolean on_wtools_4_TileView_delete_event (GtkWidget *, GdkEvent *, gpointer ); -G_MODULE_EXPORT void on_wtools_4_memory_changed (GtkComboBox *, gpointer ); -G_MODULE_EXPORT void on_wtools_4_palette_changed (GtkComboBox *, gpointer ); -G_MODULE_EXPORT void on_wtools_4_palnum_value_changed (GtkSpinButton *, gpointer ); -G_MODULE_EXPORT void on_wtools_4_rXX_toggled (GtkToggleButton *togglebutton, gpointer user_data); -G_MODULE_EXPORT gboolean on_wDraw_Tile_expose_event (GtkWidget *, GdkEventExpose *, gpointer ); - -} - -#endif +/* callbacks_dtools.h - this file is part of DeSmuME + * + * Copyright (C) 2007 Damien Nozay (damdoum) + * Author: damdoum at users.sourceforge.net + * + * This file is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2, or (at your option) + * any later version. + * + * This file is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; see the file COPYING. If not, write to + * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#ifndef __CALLBACKS_DTOOLS_H__ +#define __CALLBACKS_DTOOLS_H__ + +#include "../globals.h" + +extern "C" { + +/* ***** ***** IO REGISTERS ***** ***** */ +G_MODULE_EXPORT void on_wtools_1_combo_cpu_changed (GtkComboBox *, gpointer ); +G_MODULE_EXPORT void on_wtools_1_IOregs_show (GtkWidget *, gpointer ); +G_MODULE_EXPORT gboolean on_wtools_1_IOregs_close (GtkWidget *, ...); +G_MODULE_EXPORT gboolean on_wtools_1_draw_button_release_event(GtkWidget *, GdkEventButton *, gpointer ); +G_MODULE_EXPORT gboolean on_wtools_1_draw_expose_event (GtkWidget *widget, GdkEventExpose *event, gpointer user_data); + +/* ***** ***** MEMORY VIEWER ***** ***** */ +G_MODULE_EXPORT void on_wtools_2_MemView_show (GtkWidget *, gpointer ); +G_MODULE_EXPORT gboolean on_wtools_2_MemView_close (GtkWidget *, ...); + +G_MODULE_EXPORT void on_wtools_2_cpu_changed (GtkComboBox *, gpointer ); +G_MODULE_EXPORT void on_wtools_2_r8_toggled (GtkToggleButton *, gpointer ); +G_MODULE_EXPORT void on_wtools_2_r16_toggled (GtkToggleButton *, gpointer ); +G_MODULE_EXPORT void on_wtools_2_r32_toggled (GtkToggleButton *, gpointer ); +G_MODULE_EXPORT void on_wtools_2_GotoAddress_activate (GtkEntry *, gpointer ); +G_MODULE_EXPORT void on_wtools_2_GotoAddress_changed (GtkEntry *, gpointer ); +G_MODULE_EXPORT void on_wtools_2_GotoButton_clicked (GtkButton *, gpointer ); +G_MODULE_EXPORT void on_wtools_2_scroll_value_changed (GtkRange *, gpointer ); +G_MODULE_EXPORT gboolean on_wtools_2_draw_button_release_event(GtkWidget *, GdkEventButton *, gpointer ); +G_MODULE_EXPORT gboolean on_wtools_2_draw_expose_event (GtkWidget *, GdkEventExpose *, gpointer ); +G_MODULE_EXPORT gboolean on_wtools_2_draw_scroll_event (GtkWidget *, GdkEventScroll *, gpointer ); + +/* ***** ***** PALETTE VIEWER ***** ***** */ +// initialise combo box for all palettes +void init_combo_palette(GtkComboBox *combo, u16 ** addresses); + +G_MODULE_EXPORT void on_wtools_3_PalView_show (GtkWidget *, gpointer ); +G_MODULE_EXPORT gboolean on_wtools_3_PalView_close (GtkWidget *, ...); +G_MODULE_EXPORT gboolean on_wtools_3_PalView_delete_event (GtkWidget *, GdkEvent *, gpointer ); +G_MODULE_EXPORT gboolean on_wtools_3_draw_expose_event (GtkWidget *, GdkEventExpose *, gpointer ); +G_MODULE_EXPORT void on_wtools_3_palette_changed (GtkComboBox *, gpointer ); +G_MODULE_EXPORT void on_wtools_3_palnum_value_changed (GtkSpinButton *, gpointer ); + + +/* ***** ***** TILE VIEWER ***** ***** */ +// initialise combo box for all palettes +void init_combo_memory(GtkComboBox *combo, u8 ** addresses); + +G_MODULE_EXPORT void on_wtools_4_TileView_show (GtkWidget *, gpointer ); +G_MODULE_EXPORT gboolean on_wtools_4_TileView_close (GtkWidget *, ...); +G_MODULE_EXPORT gboolean on_wtools_4_TileView_delete_event (GtkWidget *, GdkEvent *, gpointer ); +G_MODULE_EXPORT void on_wtools_4_memory_changed (GtkComboBox *, gpointer ); +G_MODULE_EXPORT void on_wtools_4_palette_changed (GtkComboBox *, gpointer ); +G_MODULE_EXPORT void on_wtools_4_palnum_value_changed (GtkSpinButton *, gpointer ); +G_MODULE_EXPORT void on_wtools_4_rXX_toggled (GtkToggleButton *togglebutton, gpointer user_data); +G_MODULE_EXPORT gboolean on_wDraw_Tile_expose_event (GtkWidget *, GdkEventExpose *, gpointer ); + +} + +#endif diff --git a/desmume/src/gtk-glade/dTools/dTools_display.h b/src/gtk-glade/dTools/dTools_display.h old mode 100755 new mode 100644 similarity index 96% rename from desmume/src/gtk-glade/dTools/dTools_display.h rename to src/gtk-glade/dTools/dTools_display.h index 2ed554962..0da3e5e33 --- a/desmume/src/gtk-glade/dTools/dTools_display.h +++ b/src/gtk-glade/dTools/dTools_display.h @@ -1,110 +1,110 @@ -/* dTools_display.c - * - * Copyright (C) 2007 Damien Nozay (damdoum) - * Author: damdoum at users.sourceforge.net - * - * This file is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2, or (at your option) - * any later version. - * - * This file is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; see the file COPYING. If not, write to - * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -#ifndef _DTOOLS_DISPLAY_H_ -#define _DTOOLS_DISPLAY_H_ - -#include - -typedef struct { - GtkWidget *widget; - GdkDrawable *draw; - GdkGC *gc_fg; - GdkGC *gc_bg; - PangoLayout* playout; - int size_w, size_h; - int char_w, char_h, padding; - GList * colors_rgb; - GList * attr_list; - PangoAttrList * curr_attr; -} dTools_dsp; - -static void inline dTools_display_set_size(dTools_dsp * dsp, int w, int h, int pad) { - dsp->size_w = w; - dsp->size_h = h; - dsp->padding = pad; -// gtk_widget_set_size_request(dsp->widget, -// dsp->char_w * w + pad * 2, dsp->char_h * h + pad * 2); - gtk_widget_set_usize(dsp->widget, - dsp->char_w * w + pad * 2, dsp->char_h * h + pad * 2); -} - -static void inline dTools_display_init(dTools_dsp * dsp, GtkWidget * widget, int w, int h, int pad) { - dsp->widget = widget; - dsp->draw = widget->window; - dsp->gc_fg = widget->style->fg_gc[widget->state]; - dsp->gc_bg = widget->style->white_gc; - dsp->playout = gtk_widget_create_pango_layout(widget, NULL); - - dsp->colors_rgb = NULL; - dsp->attr_list = NULL; - dsp->curr_attr = NULL; - - pango_layout_set_markup(dsp->playout, "X",-1); - pango_layout_get_pixel_size(dsp->playout, &dsp->char_w, &dsp->char_h); - dTools_display_set_size(dsp, w, h, pad); -} - -// void unref (gpointer data, ...) { -// pango_attr_list_unref(data); -// } - -static void inline dTools_display_free(dTools_dsp * dsp) { -// g_list_foreach(dsp->attr_list, (GFunc)unref, NULL); -// g_object_unref(dsp->playout); // not alloc -} - -static void inline dTools_display_add_markup(dTools_dsp * dsp, const char * markup) { - PangoAttrList *attr; - pango_parse_markup (markup, -1, 0, &attr, NULL, NULL, NULL); - dsp->attr_list = g_list_append(dsp->attr_list, attr); - dsp->curr_attr = attr; -} - -static void inline dTools_display_clear(dTools_dsp * dsp) { - gdk_draw_rectangle(dsp->draw, dsp->gc_bg, TRUE, 0, 0, - dsp->widget->allocation.width, dsp->widget->allocation.height); -} - -static void inline dTools_display_clear_char(dTools_dsp * dsp, int x, int y, int nb) { - gdk_draw_rectangle(dsp->draw, dsp->gc_bg, TRUE, - x * dsp->char_w + dsp->padding, y * dsp->char_h + dsp->padding, - nb * dsp->char_w, dsp->char_h); -} - -static void inline dTools_display_select_attr(dTools_dsp * dsp, int index) { - PangoAttrList *attr = NULL; - attr = (PangoAttrList*) g_list_nth_data(dsp->attr_list, index); - if (attr != NULL) { - dsp->curr_attr = attr; - } - pango_layout_set_attributes(dsp->playout, dsp->curr_attr); -} - -static void inline dTools_display_draw_text(dTools_dsp * dsp, int x, int y, const char * txt) { - pango_layout_set_text(dsp->playout, txt, -1); - gdk_draw_layout(dsp->draw, dsp->gc_fg, - x * dsp->char_w + dsp->padding, - y * dsp->char_h + dsp->padding, - dsp->playout); -} - -#endif +/* dTools_display.c + * + * Copyright (C) 2007 Damien Nozay (damdoum) + * Author: damdoum at users.sourceforge.net + * + * This file is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2, or (at your option) + * any later version. + * + * This file is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; see the file COPYING. If not, write to + * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#ifndef _DTOOLS_DISPLAY_H_ +#define _DTOOLS_DISPLAY_H_ + +#include + +typedef struct { + GtkWidget *widget; + GdkDrawable *draw; + GdkGC *gc_fg; + GdkGC *gc_bg; + PangoLayout* playout; + int size_w, size_h; + int char_w, char_h, padding; + GList * colors_rgb; + GList * attr_list; + PangoAttrList * curr_attr; +} dTools_dsp; + +static void inline dTools_display_set_size(dTools_dsp * dsp, int w, int h, int pad) { + dsp->size_w = w; + dsp->size_h = h; + dsp->padding = pad; +// gtk_widget_set_size_request(dsp->widget, +// dsp->char_w * w + pad * 2, dsp->char_h * h + pad * 2); + gtk_widget_set_usize(dsp->widget, + dsp->char_w * w + pad * 2, dsp->char_h * h + pad * 2); +} + +static void inline dTools_display_init(dTools_dsp * dsp, GtkWidget * widget, int w, int h, int pad) { + dsp->widget = widget; + dsp->draw = widget->window; + dsp->gc_fg = widget->style->fg_gc[widget->state]; + dsp->gc_bg = widget->style->white_gc; + dsp->playout = gtk_widget_create_pango_layout(widget, NULL); + + dsp->colors_rgb = NULL; + dsp->attr_list = NULL; + dsp->curr_attr = NULL; + + pango_layout_set_markup(dsp->playout, "X",-1); + pango_layout_get_pixel_size(dsp->playout, &dsp->char_w, &dsp->char_h); + dTools_display_set_size(dsp, w, h, pad); +} + +// void unref (gpointer data, ...) { +// pango_attr_list_unref(data); +// } + +static void inline dTools_display_free(dTools_dsp * dsp) { +// g_list_foreach(dsp->attr_list, (GFunc)unref, NULL); +// g_object_unref(dsp->playout); // not alloc +} + +static void inline dTools_display_add_markup(dTools_dsp * dsp, const char * markup) { + PangoAttrList *attr; + pango_parse_markup (markup, -1, 0, &attr, NULL, NULL, NULL); + dsp->attr_list = g_list_append(dsp->attr_list, attr); + dsp->curr_attr = attr; +} + +static void inline dTools_display_clear(dTools_dsp * dsp) { + gdk_draw_rectangle(dsp->draw, dsp->gc_bg, TRUE, 0, 0, + dsp->widget->allocation.width, dsp->widget->allocation.height); +} + +static void inline dTools_display_clear_char(dTools_dsp * dsp, int x, int y, int nb) { + gdk_draw_rectangle(dsp->draw, dsp->gc_bg, TRUE, + x * dsp->char_w + dsp->padding, y * dsp->char_h + dsp->padding, + nb * dsp->char_w, dsp->char_h); +} + +static void inline dTools_display_select_attr(dTools_dsp * dsp, int index) { + PangoAttrList *attr = NULL; + attr = (PangoAttrList*) g_list_nth_data(dsp->attr_list, index); + if (attr != NULL) { + dsp->curr_attr = attr; + } + pango_layout_set_attributes(dsp->playout, dsp->curr_attr); +} + +static void inline dTools_display_draw_text(dTools_dsp * dsp, int x, int y, const char * txt) { + pango_layout_set_text(dsp->playout, txt, -1); + gdk_draw_layout(dsp->draw, dsp->gc_fg, + x * dsp->char_w + dsp->padding, + y * dsp->char_h + dsp->padding, + dsp->playout); +} + +#endif diff --git a/desmume/src/gtk-glade/desmume-glade.desktop b/src/gtk-glade/desmume-glade.desktop similarity index 100% rename from desmume/src/gtk-glade/desmume-glade.desktop rename to src/gtk-glade/desmume-glade.desktop diff --git a/desmume/src/gtk-glade/desmume.cpp b/src/gtk-glade/desmume.cpp old mode 100755 new mode 100644 similarity index 89% rename from desmume/src/gtk-glade/desmume.cpp rename to src/gtk-glade/desmume.cpp index 3d692781d..7458e0110 --- a/desmume/src/gtk-glade/desmume.cpp +++ b/src/gtk-glade/desmume.cpp @@ -1,178 +1,181 @@ -/* desmume.c - this file is part of DeSmuME - * - * Copyright (C) 2006,2007 DeSmuME Team - * Copyright (C) 2007 Pascal Giard (evilynux) - * - * This file is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2, or (at your option) - * any later version. - * - * This file is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; see the file COPYING. If not, write to - * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -#include "desmume.h" - -#define EMULOOP_PRIO (G_PRIORITY_HIGH_IDLE + 20) -gboolean EmuLoop(gpointer data); -static BOOL regMainLoop = FALSE; - -#define TICKS_PER_FRAME 17 - - -static BOOL noticed_3D=FALSE; -volatile BOOL execute = FALSE; -BOOL click = FALSE; - -void desmume_mem_init(); - -u8 *desmume_rom_data = NULL; -u32 desmume_last_cycle; - -void desmume_init( struct armcpu_memory_iface *arm9_mem_if, - struct armcpu_ctrl_iface **arm9_ctrl_iface, //ticksPrevFrame = ticksCurFrame; - struct armcpu_memory_iface *arm7_mem_if, - struct armcpu_ctrl_iface **arm7_ctrl_iface) -{ -#ifdef GDB_STUB - NDS_Init( arm9_mem_if, arm9_ctrl_iface, - arm7_mem_if, arm7_ctrl_iface); -#else - NDS_Init(); -#endif - SPU_ChangeSoundCore(SNDCORE_SDL, 735 * 4); - execute = FALSE; -} - -void desmume_free() -{ - execute = FALSE; - NDS_DeInit(); -} - -int desmume_open(const char *filename) -{ - int i; - noticed_3D=FALSE; - clear_savestates(); - i = NDS_LoadROM(filename); - return i; -} - -void desmume_savetype(int type) { - backup_setManualBackupType(type); -} - - -void desmume_pause() -{ - execute = FALSE; - SPU_Pause(1); -} - -void desmume_resume() -{ - SPU_Pause(0); - execute = TRUE; - if(!regMainLoop) - g_idle_add_full(EMULOOP_PRIO, &EmuLoop, NULL, NULL); - regMainLoop = TRUE; -} - -void desmume_reset() -{ - noticed_3D=FALSE; - NDS_Reset(); - desmume_resume(); -} - -void desmume_toggle() -{ - execute = (execute) ? FALSE : TRUE; -} -/*INLINE BOOL desmume_running() -{ - return execute; -}*/ - -INLINE void desmume_cycle() -{ - u16 keypad; - /* Joystick events */ - /* Retrieve old value: can use joysticks w/ another device (from our side) */ - keypad = get_keypad(); - /* Process joystick events if any */ - process_joystick_events( &keypad); - /* Update keypad value */ - update_keypad(keypad); - - NDS_exec(); - SPU_Emulate_user(); -} - - -Uint32 fps, fps_SecStart, fps_FrameCount; -Uint32 fsFrameCount = 0; -Uint32 ticksPrevFrame = 0, ticksCurFrame = 0; -static void Draw() -{ -} - -gboolean EmuLoop(gpointer data) -{ - if(desmume_running()) /* Si on est en train d'executer le programme ... */ - { - if(Frameskip != 0 && (fsFrameCount % (Frameskip+1)) != 0) - NDS_SkipNextFrame(); - - fsFrameCount++; - - fps_FrameCount++; - if(!fps_SecStart) fps_SecStart = SDL_GetTicks(); - if(SDL_GetTicks() - fps_SecStart >= 1000) - { - fps_SecStart = SDL_GetTicks(); - fps = fps_FrameCount; - fps_FrameCount = 0; - - char Title[32]; - sprintf(Title, "Desmume - %dfps", fps); - gtk_window_set_title(GTK_WINDOW(pWindow), Title); - } - - desmume_cycle(); /* Emule ! */ - //for(i = 0; i < Frameskip; i++) desmume_cycle(); /* cycles supplémentaires pour le frameskip */ - - Draw(); - - notify_Tools(); - gtk_widget_queue_draw(pDrawingArea); - gtk_widget_queue_draw(pDrawingArea2); - - ticksCurFrame = SDL_GetTicks(); - - if(!glade_fps_limiter_disabled) - { - if((ticksCurFrame - ticksPrevFrame) < TICKS_PER_FRAME) - while((ticksCurFrame - ticksPrevFrame) < TICKS_PER_FRAME) - ticksCurFrame = SDL_GetTicks(); - } - - ticksPrevFrame = SDL_GetTicks(); - - return TRUE; - } - gtk_widget_queue_draw(pDrawingArea); - gtk_widget_queue_draw(pDrawingArea2); - regMainLoop = FALSE; - return FALSE; -} - +/* desmume.c - this file is part of DeSmuME + * + * Copyright (C) 2006,2007 DeSmuME Team + * Copyright (C) 2007 Pascal Giard (evilynux) + * + * This file is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2, or (at your option) + * any later version. + * + * This file is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; see the file COPYING. If not, write to + * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#include "desmume.h" + +#define EMULOOP_PRIO (G_PRIORITY_HIGH_IDLE + 20) +gboolean EmuLoop(gpointer data); +static BOOL regMainLoop = FALSE; + +#define TICKS_PER_FRAME 17 + + +static BOOL noticed_3D=FALSE; +volatile BOOL execute = FALSE; +BOOL click = FALSE; +int savetype=MC_TYPE_AUTODETECT; +u32 savesize=1; + +void desmume_mem_init(); + +u8 *desmume_rom_data = NULL; +u32 desmume_last_cycle; + +void desmume_init( struct armcpu_memory_iface *arm9_mem_if, + struct armcpu_ctrl_iface **arm9_ctrl_iface, //ticksPrevFrame = ticksCurFrame; + struct armcpu_memory_iface *arm7_mem_if, + struct armcpu_ctrl_iface **arm7_ctrl_iface) +{ +#ifdef GDB_STUB + NDS_Init( arm9_mem_if, arm9_ctrl_iface, + arm7_mem_if, arm7_ctrl_iface); +#else + NDS_Init(); +#endif + SPU_ChangeSoundCore(SNDCORE_SDL, 735 * 4); + execute = FALSE; +} + +void desmume_free() +{ + execute = FALSE; + NDS_DeInit(); +} + +int desmume_open(const char *filename) +{ + int i; + noticed_3D=FALSE; + clear_savestates(); + i = NDS_LoadROM(filename, savetype, savesize, NULL); + return i; +} + +void desmume_savetype(int type) { + mmu_select_savetype(type, &savetype, &savesize); +} + + +void desmume_pause() +{ + execute = FALSE; + SPU_Pause(1); +} + +void desmume_resume() +{ + SPU_Pause(0); + execute = TRUE; + if(!regMainLoop) + g_idle_add_full(EMULOOP_PRIO, &EmuLoop, NULL, NULL); + regMainLoop = TRUE; +} + +void desmume_reset() +{ + noticed_3D=FALSE; + NDS_Reset(); + desmume_resume(); +} + +void desmume_toggle() +{ + execute = (execute) ? FALSE : TRUE; +} +/*INLINE BOOL desmume_running() +{ + return execute; +}*/ + +INLINE void desmume_cycle() +{ + u16 keypad; + /* Joystick events */ + /* Retrieve old value: can use joysticks w/ another device (from our side) */ + keypad = get_keypad(); + /* Process joystick events if any */ + process_joystick_events( &keypad); + /* Update keypad value */ + update_keypad(keypad); + + desmume_last_cycle = NDS_exec((560190 << 1) - desmume_last_cycle); + SPU_Emulate_user(); + SPU_Emulate_core(); +} + + +Uint32 fps, fps_SecStart, fps_FrameCount; +Uint32 fsFrameCount = 0; +Uint32 ticksPrevFrame = 0, ticksCurFrame = 0; +static void Draw() +{ +} + +gboolean EmuLoop(gpointer data) +{ + if(desmume_running()) /* Si on est en train d'executer le programme ... */ + { + if(Frameskip != 0 && (fsFrameCount % (Frameskip+1)) != 0) + NDS_SkipNextFrame(); + + fsFrameCount++; + + fps_FrameCount++; + if(!fps_SecStart) fps_SecStart = SDL_GetTicks(); + if(SDL_GetTicks() - fps_SecStart >= 1000) + { + fps_SecStart = SDL_GetTicks(); + fps = fps_FrameCount; + fps_FrameCount = 0; + + char Title[32]; + sprintf(Title, "Desmume - %dfps", fps); + gtk_window_set_title(GTK_WINDOW(pWindow), Title); + } + + desmume_cycle(); /* Emule ! */ + //for(i = 0; i < Frameskip; i++) desmume_cycle(); /* cycles supplementaires pour le frameskip */ + + Draw(); + + notify_Tools(); + gtk_widget_queue_draw(pDrawingArea); + gtk_widget_queue_draw(pDrawingArea2); + + ticksCurFrame = SDL_GetTicks(); + + if(!glade_fps_limiter_disabled) + { + if((ticksCurFrame - ticksPrevFrame) < TICKS_PER_FRAME) + while((ticksCurFrame - ticksPrevFrame) < TICKS_PER_FRAME) + ticksCurFrame = SDL_GetTicks(); + } + + ticksPrevFrame = SDL_GetTicks(); + + return TRUE; + } + gtk_widget_queue_draw(pDrawingArea); + gtk_widget_queue_draw(pDrawingArea2); + regMainLoop = FALSE; + return FALSE; +} + diff --git a/desmume/src/gtk-glade/desmume.h b/src/gtk-glade/desmume.h old mode 100755 new mode 100644 similarity index 97% rename from desmume/src/gtk-glade/desmume.h rename to src/gtk-glade/desmume.h index 4a6dcc292..bef3116dd --- a/desmume/src/gtk-glade/desmume.h +++ b/src/gtk-glade/desmume.h @@ -1,49 +1,49 @@ -/* desmume.h - this file is part of DeSmuME - * - * - * This file is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2, or (at your option) - * any later version. - * - * This file is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; see the file COPYING. If not, write to - * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -#ifndef __DESMUME_H__ -#define __DESMUME_H__ - -#include "globals.h" - -#define FPS_LIMITER_FRAME_PERIOD 5 -extern SDL_sem *glade_fps_limiter_semaphore; -extern int glade_fps_limiter_disabled; - -extern void desmume_init( struct armcpu_memory_iface *arm9_mem_if, - struct armcpu_ctrl_iface **arm9_ctrl_iface, - struct armcpu_memory_iface *arm7_mem_if, - struct armcpu_ctrl_iface **arm7_ctrl_iface); -extern void desmume_free( void); - -extern int desmume_open(const char *filename); -extern void desmume_savetype(int type); -extern void desmume_pause( void); -extern void desmume_resume( void); -extern void desmume_reset( void); -extern void desmume_toggle( void); -//extern BOOL desmume_running( void); -INLINE BOOL desmume_running(void) -{ - return execute; -} - -extern INLINE void desmume_cycle( void); -#endif /*__DESMUME_H__*/ - +/* desmume.h - this file is part of DeSmuME + * + * + * This file is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2, or (at your option) + * any later version. + * + * This file is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; see the file COPYING. If not, write to + * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#ifndef __DESMUME_H__ +#define __DESMUME_H__ + +#include "globals.h" + +#define FPS_LIMITER_FRAME_PERIOD 5 +extern SDL_sem *glade_fps_limiter_semaphore; +extern int glade_fps_limiter_disabled; + +extern void desmume_init( struct armcpu_memory_iface *arm9_mem_if, + struct armcpu_ctrl_iface **arm9_ctrl_iface, + struct armcpu_memory_iface *arm7_mem_if, + struct armcpu_ctrl_iface **arm7_ctrl_iface); +extern void desmume_free( void); + +extern int desmume_open(const char *filename); +extern void desmume_savetype(int type); +extern void desmume_pause( void); +extern void desmume_resume( void); +extern void desmume_reset( void); +extern void desmume_toggle( void); +//extern BOOL desmume_running( void); +INLINE BOOL desmume_running(void) +{ + return execute; +} + +extern INLINE void desmume_cycle( void); +#endif /*__DESMUME_H__*/ + diff --git a/desmume/src/gtk-glade/doc/Makefile.am b/src/gtk-glade/doc/Makefile.am similarity index 100% rename from desmume/src/gtk-glade/doc/Makefile.am rename to src/gtk-glade/doc/Makefile.am diff --git a/desmume/src/gtk-glade/doc/desmume-glade.1 b/src/gtk-glade/doc/desmume-glade.1 similarity index 100% rename from desmume/src/gtk-glade/doc/desmume-glade.1 rename to src/gtk-glade/doc/desmume-glade.1 diff --git a/desmume/src/gtk-glade/gdk_3Demu.cpp b/src/gtk-glade/gdk_3Demu.cpp similarity index 97% rename from desmume/src/gtk-glade/gdk_3Demu.cpp rename to src/gtk-glade/gdk_3Demu.cpp index e979965f7..681dff8d5 100644 --- a/desmume/src/gtk-glade/gdk_3Demu.cpp +++ b/src/gtk-glade/gdk_3Demu.cpp @@ -1,208 +1,208 @@ -/* $Id: gdk_3Demu.c,v 1.4 2007-07-15 21:50:30 evilynux Exp $ - */ -/* - Copyright (C) 2006-2007 Ben Jaques - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ -#ifdef GTKGLEXT_AVAILABLE - -#include -#include - -// Localization -#include -#define _(String) gettext (String) - -#include "../types.h" -#include "../render3D.h" -#include "../OGLRender.h" -#include "gdk_3Demu.h" - -/* - * The GDK 3D emulation. - * This uses the OpenGL Collector plugin, using gdkGLext for the platform - * specific helper functions. - */ - - -static GdkPixmap *target_pixmap; -static GdkGLContext *glcontext = NULL; -static GdkGLDrawable *gldrawable; - - -#if 0 /* not used */ -static void -print_gl_config_attrib (GdkGLConfig *glconfig, - const gchar *attrib_str, - int attrib, - gboolean is_boolean) -{ - int value; - - g_print ("%s = ", attrib_str); - if (gdk_gl_config_get_attrib (glconfig, attrib, &value)) - { - if (is_boolean) - g_print ("%s\n", value == TRUE ? "TRUE" : "FALSE"); - else - g_print ("%d\n", value); - } - else - g_print (_("*** Cannot get %s attribute value\n"), attrib_str); -} - - -static void -examine_gl_config_attrib (GdkGLConfig *glconfig) -{ - g_print ("\nOpenGL visual configurations :\n\n"); - - g_print ("gdk_gl_config_is_rgba (glconfig) = %s\n", - gdk_gl_config_is_rgba (glconfig) ? "TRUE" : "FALSE"); - g_print ("gdk_gl_config_is_double_buffered (glconfig) = %s\n", - gdk_gl_config_is_double_buffered (glconfig) ? "TRUE" : "FALSE"); - g_print ("gdk_gl_config_is_stereo (glconfig) = %s\n", - gdk_gl_config_is_stereo (glconfig) ? "TRUE" : "FALSE"); - g_print ("gdk_gl_config_has_alpha (glconfig) = %s\n", - gdk_gl_config_has_alpha (glconfig) ? "TRUE" : "FALSE"); - g_print ("gdk_gl_config_has_depth_buffer (glconfig) = %s\n", - gdk_gl_config_has_depth_buffer (glconfig) ? "TRUE" : "FALSE"); - g_print ("gdk_gl_config_has_stencil_buffer (glconfig) = %s\n", - gdk_gl_config_has_stencil_buffer (glconfig) ? "TRUE" : "FALSE"); - g_print ("gdk_gl_config_has_accum_buffer (glconfig) = %s\n", - gdk_gl_config_has_accum_buffer (glconfig) ? "TRUE" : "FALSE"); - - g_print ("\n"); - - print_gl_config_attrib (glconfig, "GDK_GL_USE_GL", - GDK_GL_USE_GL, TRUE); - print_gl_config_attrib (glconfig, "GDK_GL_BUFFER_SIZE", - GDK_GL_BUFFER_SIZE, FALSE); - print_gl_config_attrib (glconfig, "GDK_GL_LEVEL", - GDK_GL_LEVEL, FALSE); - print_gl_config_attrib (glconfig, "GDK_GL_RGBA", - GDK_GL_RGBA, TRUE); - print_gl_config_attrib (glconfig, "GDK_GL_DOUBLEBUFFER", - GDK_GL_DOUBLEBUFFER, TRUE); - print_gl_config_attrib (glconfig, "GDK_GL_STEREO", - GDK_GL_STEREO, TRUE); - print_gl_config_attrib (glconfig, "GDK_GL_AUX_BUFFERS", - GDK_GL_AUX_BUFFERS, FALSE); - print_gl_config_attrib (glconfig, "GDK_GL_RED_SIZE", - GDK_GL_RED_SIZE, FALSE); - print_gl_config_attrib (glconfig, "GDK_GL_GREEN_SIZE", - GDK_GL_GREEN_SIZE, FALSE); - print_gl_config_attrib (glconfig, "GDK_GL_BLUE_SIZE", - GDK_GL_BLUE_SIZE, FALSE); - print_gl_config_attrib (glconfig, "GDK_GL_ALPHA_SIZE", - GDK_GL_ALPHA_SIZE, FALSE); - print_gl_config_attrib (glconfig, "GDK_GL_DEPTH_SIZE", - GDK_GL_DEPTH_SIZE, FALSE); - print_gl_config_attrib (glconfig, "GDK_GL_STENCIL_SIZE", - GDK_GL_STENCIL_SIZE, FALSE); - print_gl_config_attrib (glconfig, "GDK_GL_ACCUM_RED_SIZE", - GDK_GL_ACCUM_RED_SIZE, FALSE); - print_gl_config_attrib (glconfig, "GDK_GL_ACCUM_GREEN_SIZE", - GDK_GL_ACCUM_GREEN_SIZE, FALSE); - print_gl_config_attrib (glconfig, "GDK_GL_ACCUM_BLUE_SIZE", - GDK_GL_ACCUM_BLUE_SIZE, FALSE); - print_gl_config_attrib (glconfig, "GDK_GL_ACCUM_ALPHA_SIZE", - GDK_GL_ACCUM_ALPHA_SIZE, FALSE); - - g_print ("\n"); -} -#endif - -static bool -begin_opengl_region_gdk_3d( void) { - bool failed = false; - - gdk_error_trap_push(); - failed = !gdk_gl_drawable_gl_begin(gldrawable, glcontext); - gdk_flush(); - failed = failed | gdk_error_trap_pop(); - - if (failed) return false; - - return true; -} - -static void -end_opengl_region_gdk_3d( void) { - gdk_gl_drawable_gl_end (gldrawable); -} - -static bool -initialise_gdk_3d( void) { - /* this does nothing */ - return true; -} - -int -init_opengl_gdk_3Demu( GdkDrawable * drawable) { - GdkGLConfig *glconfig; - - /* create the off screen pixmap */ - target_pixmap = gdk_pixmap_new ( drawable, 256, 192, -1); - - if ( target_pixmap == NULL) { - g_print (_("*** Failed to create pixmap.\n")); - return 0; - } - - glconfig = gdk_gl_config_new_by_mode ((GdkGLConfigMode) (GDK_GL_MODE_RGBA | - GDK_GL_MODE_DEPTH | - GDK_GL_MODE_STENCIL | - GDK_GL_MODE_SINGLE)); - if (glconfig == NULL) - { - g_print (_("*** No appropriate OpenGL-capable visual found.\n")); - return 0; - } - - /* - * Set OpenGL-capability to the pixmap - */ - - gldrawable = GDK_GL_DRAWABLE (gdk_pixmap_set_gl_capability (target_pixmap, - glconfig, - NULL)); - - if ( gldrawable == NULL) { - g_print (_("Failed to create the GdkGLPixmap\n")); - return 0; - } - - glcontext = gdk_gl_context_new (gldrawable, - NULL, - FALSE, - GDK_GL_RGBA_TYPE); - if (glcontext == NULL) - { - g_print (_("Connot create the OpenGL rendering context\n")); - return 0; - } - - oglrender_init = initialise_gdk_3d; - oglrender_beginOpenGL = begin_opengl_region_gdk_3d; - oglrender_endOpenGL = end_opengl_region_gdk_3d; - - return 1; -} - -#endif +/* $Id: gdk_3Demu.c,v 1.4 2007-07-15 21:50:30 evilynux Exp $ + */ +/* + Copyright (C) 2006-2007 Ben Jaques + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ +#ifdef GTKGLEXT_AVAILABLE + +#include +#include + +// Localization +#include +#define _(String) gettext (String) + +#include "../types.h" +#include "../render3D.h" +#include "../OGLRender.h" +#include "gdk_3Demu.h" + +/* + * The GDK 3D emulation. + * This uses the OpenGL Collector plugin, using gdkGLext for the platform + * specific helper functions. + */ + + +static GdkPixmap *target_pixmap; +static GdkGLContext *glcontext = NULL; +static GdkGLDrawable *gldrawable; + + +#if 0 /* not used */ +static void +print_gl_config_attrib (GdkGLConfig *glconfig, + const gchar *attrib_str, + int attrib, + gboolean is_boolean) +{ + int value; + + g_print ("%s = ", attrib_str); + if (gdk_gl_config_get_attrib (glconfig, attrib, &value)) + { + if (is_boolean) + g_print ("%s\n", value == TRUE ? "TRUE" : "FALSE"); + else + g_print ("%d\n", value); + } + else + g_print (_("*** Cannot get %s attribute value\n"), attrib_str); +} + + +static void +examine_gl_config_attrib (GdkGLConfig *glconfig) +{ + g_print ("\nOpenGL visual configurations :\n\n"); + + g_print ("gdk_gl_config_is_rgba (glconfig) = %s\n", + gdk_gl_config_is_rgba (glconfig) ? "TRUE" : "FALSE"); + g_print ("gdk_gl_config_is_double_buffered (glconfig) = %s\n", + gdk_gl_config_is_double_buffered (glconfig) ? "TRUE" : "FALSE"); + g_print ("gdk_gl_config_is_stereo (glconfig) = %s\n", + gdk_gl_config_is_stereo (glconfig) ? "TRUE" : "FALSE"); + g_print ("gdk_gl_config_has_alpha (glconfig) = %s\n", + gdk_gl_config_has_alpha (glconfig) ? "TRUE" : "FALSE"); + g_print ("gdk_gl_config_has_depth_buffer (glconfig) = %s\n", + gdk_gl_config_has_depth_buffer (glconfig) ? "TRUE" : "FALSE"); + g_print ("gdk_gl_config_has_stencil_buffer (glconfig) = %s\n", + gdk_gl_config_has_stencil_buffer (glconfig) ? "TRUE" : "FALSE"); + g_print ("gdk_gl_config_has_accum_buffer (glconfig) = %s\n", + gdk_gl_config_has_accum_buffer (glconfig) ? "TRUE" : "FALSE"); + + g_print ("\n"); + + print_gl_config_attrib (glconfig, "GDK_GL_USE_GL", + GDK_GL_USE_GL, TRUE); + print_gl_config_attrib (glconfig, "GDK_GL_BUFFER_SIZE", + GDK_GL_BUFFER_SIZE, FALSE); + print_gl_config_attrib (glconfig, "GDK_GL_LEVEL", + GDK_GL_LEVEL, FALSE); + print_gl_config_attrib (glconfig, "GDK_GL_RGBA", + GDK_GL_RGBA, TRUE); + print_gl_config_attrib (glconfig, "GDK_GL_DOUBLEBUFFER", + GDK_GL_DOUBLEBUFFER, TRUE); + print_gl_config_attrib (glconfig, "GDK_GL_STEREO", + GDK_GL_STEREO, TRUE); + print_gl_config_attrib (glconfig, "GDK_GL_AUX_BUFFERS", + GDK_GL_AUX_BUFFERS, FALSE); + print_gl_config_attrib (glconfig, "GDK_GL_RED_SIZE", + GDK_GL_RED_SIZE, FALSE); + print_gl_config_attrib (glconfig, "GDK_GL_GREEN_SIZE", + GDK_GL_GREEN_SIZE, FALSE); + print_gl_config_attrib (glconfig, "GDK_GL_BLUE_SIZE", + GDK_GL_BLUE_SIZE, FALSE); + print_gl_config_attrib (glconfig, "GDK_GL_ALPHA_SIZE", + GDK_GL_ALPHA_SIZE, FALSE); + print_gl_config_attrib (glconfig, "GDK_GL_DEPTH_SIZE", + GDK_GL_DEPTH_SIZE, FALSE); + print_gl_config_attrib (glconfig, "GDK_GL_STENCIL_SIZE", + GDK_GL_STENCIL_SIZE, FALSE); + print_gl_config_attrib (glconfig, "GDK_GL_ACCUM_RED_SIZE", + GDK_GL_ACCUM_RED_SIZE, FALSE); + print_gl_config_attrib (glconfig, "GDK_GL_ACCUM_GREEN_SIZE", + GDK_GL_ACCUM_GREEN_SIZE, FALSE); + print_gl_config_attrib (glconfig, "GDK_GL_ACCUM_BLUE_SIZE", + GDK_GL_ACCUM_BLUE_SIZE, FALSE); + print_gl_config_attrib (glconfig, "GDK_GL_ACCUM_ALPHA_SIZE", + GDK_GL_ACCUM_ALPHA_SIZE, FALSE); + + g_print ("\n"); +} +#endif + +static bool +begin_opengl_region_gdk_3d( void) { + bool failed = false; + + gdk_error_trap_push(); + failed = !gdk_gl_drawable_gl_begin(gldrawable, glcontext); + gdk_flush(); + failed = failed | gdk_error_trap_pop(); + + if (failed) return false; + + return true; +} + +static void +end_opengl_region_gdk_3d( void) { + gdk_gl_drawable_gl_end (gldrawable); +} + +static bool +initialise_gdk_3d( void) { + /* this does nothing */ + return true; +} + +int +init_opengl_gdk_3Demu( GdkDrawable * drawable) { + GdkGLConfig *glconfig; + + /* create the off screen pixmap */ + target_pixmap = gdk_pixmap_new ( drawable, 256, 192, -1); + + if ( target_pixmap == NULL) { + g_print (_("*** Failed to create pixmap.\n")); + return 0; + } + + glconfig = gdk_gl_config_new_by_mode ((GdkGLConfigMode) (GDK_GL_MODE_RGBA | + GDK_GL_MODE_DEPTH | + GDK_GL_MODE_STENCIL | + GDK_GL_MODE_SINGLE)); + if (glconfig == NULL) + { + g_print (_("*** No appropriate OpenGL-capable visual found.\n")); + return 0; + } + + /* + * Set OpenGL-capability to the pixmap + */ + + gldrawable = GDK_GL_DRAWABLE (gdk_pixmap_set_gl_capability (target_pixmap, + glconfig, + NULL)); + + if ( gldrawable == NULL) { + g_print (_("Failed to create the GdkGLPixmap\n")); + return 0; + } + + glcontext = gdk_gl_context_new (gldrawable, + NULL, + FALSE, + GDK_GL_RGBA_TYPE); + if (glcontext == NULL) + { + g_print (_("Connot create the OpenGL rendering context\n")); + return 0; + } + + oglrender_init = initialise_gdk_3d; + oglrender_beginOpenGL = begin_opengl_region_gdk_3d; + oglrender_endOpenGL = end_opengl_region_gdk_3d; + + return 1; +} + +#endif diff --git a/desmume/src/gtk-glade/gdk_3Demu.h b/src/gtk-glade/gdk_3Demu.h similarity index 97% rename from desmume/src/gtk-glade/gdk_3Demu.h rename to src/gtk-glade/gdk_3Demu.h index 8a0a0686e..42cced988 100644 --- a/desmume/src/gtk-glade/gdk_3Demu.h +++ b/src/gtk-glade/gdk_3Demu.h @@ -1,32 +1,32 @@ -/* $Id: gdk_3Demu.h,v 1.1 2007-04-21 19:45:07 evilynux Exp $ - */ -/* - Copyright (C) 2006-2007 Ben Jaques - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ -#ifdef GTKGLEXT_AVAILABLE -/* - * The GDK 3D emulation. - * This uses the OpenGL Collector plugin, using gdkGLext for the platform - * specific helper functions. - */ - -int -init_opengl_gdk_3Demu( GdkDrawable * drawable); - -#endif +/* $Id: gdk_3Demu.h,v 1.1 2007-04-21 19:45:07 evilynux Exp $ + */ +/* + Copyright (C) 2006-2007 Ben Jaques + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ +#ifdef GTKGLEXT_AVAILABLE +/* + * The GDK 3D emulation. + * This uses the OpenGL Collector plugin, using gdkGLext for the platform + * specific helper functions. + */ + +int +init_opengl_gdk_3Demu( GdkDrawable * drawable); + +#endif diff --git a/desmume/src/gtk-glade/gdk_gl.cpp b/src/gtk-glade/gdk_gl.cpp old mode 100755 new mode 100644 similarity index 96% rename from desmume/src/gtk-glade/gdk_gl.cpp rename to src/gtk-glade/gdk_gl.cpp index 34803742e..b19b86995 --- a/desmume/src/gtk-glade/gdk_gl.cpp +++ b/src/gtk-glade/gdk_gl.cpp @@ -1,349 +1,349 @@ -/* gdk_gl.cpp - this file is part of DeSmuME - * - * Copyright (C) 2007 Damien Nozay (damdoum) - * Author: damdoum at users.sourceforge.net - * - * This file is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2, or (at your option) - * any later version. - * - * This file is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; see the file COPYING. If not, write to - * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -#include "gdk_gl.h" - -#ifdef GTKGLEXT_AVAILABLE - -#include -#include - -#define _DUP8(a) a,a,a,a, a,a,a,a -#define _DUP4(a) a,a,a,a -#define _DUP2(a) a,a - -GLuint Textures[2]; -// free number we can use in tools 0-1 reserved for screens -static int free_gl_drawable=2; -GdkGLConfig *my_glConfig=NULL; -GdkGLContext *my_glContext[8]={_DUP8(NULL)}; -GdkGLDrawable *my_glDrawable[8]={_DUP8(NULL)}; -GtkWidget *pDrawingTexArea; - -GLuint screen_texture[1]; - -/* enable software colour format conversion */ -static int gtk_glade_use_software_colour_convert; - -#undef _DUP8 -#undef _DUP4 -#undef _DUP2 - -/* FIXME: Purpose of this code? */ -static BOOL _fun_gl_Begin (int screen) { return FALSE; } -static void _fun_gl_End (int screen) { } - -fun_gl_Begin Open_GL_beg = _fun_gl_Begin; -fun_gl_End Open_GL_end = _fun_gl_End; - -void register_gl_fun(fun_gl_Begin beg,fun_gl_End end) { - Open_GL_beg = beg; - Open_GL_end = end; -} - -/************************************************/ -/* BEGIN & END */ -/************************************************/ - -BOOL my_gl_Begin (int screen) { - return gdk_gl_drawable_gl_begin(my_glDrawable[screen], my_glContext[screen]); -} - -void my_gl_End (int screen) { - if (gdk_gl_drawable_is_double_buffered (my_glDrawable[screen])) - gdk_gl_drawable_swap_buffers (my_glDrawable[screen]); - else - glFlush(); - gdk_gl_drawable_gl_end(my_glDrawable[screen]); -} - -/************************************************/ -/* OTHER GL COMMANDS */ -/************************************************/ - -void my_gl_Identity() { - glMatrixMode(GL_PROJECTION); - glLoadIdentity(); - glMatrixMode(GL_MODELVIEW); - glLoadIdentity(); -} - -void my_gl_DrawBeautifulQuad( void) { - // beautiful quad - glBegin(GL_QUADS); - glColor3ub(255,0,0); glVertex2d(-0.75,-0.75); - glColor3ub(128,255,0); glVertex2d(-0.75, 0.75); - glColor3ub(0,255,128); glVertex2d( 0.75, 0.75); - glColor3ub(0,0,255); glVertex2d( 0.75,-0.75); - glEnd(); - glColor3ub(255,255,255); -} - -#if 0 /* not used */ -static void my_gl_DrawLogo() { - - -} -#endif - - -void my_gl_Clear(int screen) { - if (!my_gl_Begin(screen)) return; - - /* Set the background black */ - glClearColor(1.0f, 1.0f, 1.0f, 1.0f); - glClearDepth(1.0); - glClear( GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT ); - - my_gl_DrawBeautifulQuad(); - - my_gl_End(screen); -} - -/************************************************/ -/* INITIALIZATION */ -/************************************************/ - -void init_GL(GtkWidget * widget, int screen, int share_num) { -// for (n=gtk_events_pending(); n>0; n--) -// gtk_main_iteration(); - // init GL capability - my_glContext[screen]=NULL; - my_glDrawable[screen]=NULL; - if (!gtk_widget_set_gl_capability( - widget, my_glConfig, - my_glContext[share_num], - //NULL, - TRUE, - GDK_GL_RGBA_TYPE)) { - printf ("gtk_widget_set_gl_capability\n"); - exit(1); - } - // realize so that we get a GdkWindow - gtk_widget_realize(widget); - // make sure we realize - gdk_flush(); - - my_glDrawable[screen] = gtk_widget_get_gl_drawable(widget); - - if (screen == share_num) { - my_glContext[screen] = gtk_widget_get_gl_context(widget); - } else { - my_glContext[screen] = my_glContext[share_num]; - return; - } - - reshape(widget, screen); -} - -int init_GL_free_s(GtkWidget * widget, int share_num) { - int r = free_gl_drawable; - my_glContext[r]=NULL; - my_glDrawable[r]=NULL; - init_GL(widget, r, share_num); - free_gl_drawable++; - return r; -} - -int init_GL_free(GtkWidget * widget) { - int r = free_gl_drawable; - my_glContext[r]=NULL; - my_glDrawable[r]=NULL; - init_GL(widget, r, r); - free_gl_drawable++; - return r; -} - -void init_GL_capabilities( int use_software_convert) { - - uint16_t blank_texture[256 * 512]; - my_glConfig = gdk_gl_config_new_by_mode ( - (GdkGLConfigMode) (GDK_GL_MODE_RGBA - | GDK_GL_MODE_DEPTH - | GDK_GL_MODE_DOUBLE) - ); - - gtk_glade_use_software_colour_convert = use_software_convert; - // initialize 1st drawing area - init_GL(pDrawingArea,0,0); - my_gl_Clear(0); - - if (!my_gl_Begin(0)) return; - // generate ONE texture (display) - glEnable(GL_TEXTURE_2D); - glGenTextures(2, Textures); - - /* Generate The Texture */ - glBindTexture( GL_TEXTURE_2D, Textures[0]); - memset(blank_texture, 0x001f, sizeof(blank_texture)); - glTexImage2D( GL_TEXTURE_2D, 0, GL_RGB, 256, 512, - 0, GL_RGBA, - GL_UNSIGNED_SHORT_1_5_5_5_REV, - blank_texture); - my_gl_End(0); - - // initialize 2nd drawing area (sharing context) - init_GL(pDrawingArea2,1,0); - my_gl_Clear(1); -} - -/************************************************/ -/* RESHAPE */ -/************************************************/ - -void reshape (GtkWidget * widget, int screen) { - if (my_glDrawable[screen] == NULL || - !my_gl_Begin(screen)) return; - - glViewport (0, 0, widget->allocation.width, widget->allocation.height); - glMatrixMode(GL_MODELVIEW); - glLoadIdentity(); - my_gl_End(screen); -} - -/************************************************/ -/* TEXTURING */ -/************************************************/ - -static void my_gl_Texture2D() { - glBindTexture(GL_TEXTURE_2D, Textures[0]); -#define MyFILTER GL_LINEAR -//#define MyFILTER GL_NEAREST - glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, MyFILTER); - glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, MyFILTER); -#undef MyFILTER -} - -static void -my_gl_ScreenTex( int software_convert) { - if ( software_convert) { - u8 converted[256 * 384 * 3]; - int i; - - for ( i = 0; i < (256 * 384); i++) { - converted[(i * 3) + 0] = ((*((u16 *)&GPU_screen[(i<<1)]) >> 0) & 0x1f) << 3; - converted[(i * 3) + 1] = ((*((u16 *)&GPU_screen[(i<<1)]) >> 5) & 0x1f) << 3; - converted[(i * 3) + 2] = ((*((u16 *)&GPU_screen[(i<<1)]) >> 10) & 0x1f) << 3; - } - - glTexSubImage2D( GL_TEXTURE_2D, 0, 0, 0, 256, 384, - GL_RGB, - GL_UNSIGNED_BYTE, - converted); - } - else { - glTexSubImage2D( GL_TEXTURE_2D, 0, 0, 0, 256, 384, - GL_RGBA, - GL_UNSIGNED_SHORT_1_5_5_5_REV, - &GPU_screen); - } -} - -static void my_gl_ScreenTexApply(int screen) { - float off = (screen)?0.375:0; - glBegin(GL_QUADS); - // texcoords 0.375 means 192, 1 means 256 - glTexCoord2f(0.0, off+0.000); glVertex2d(-1.0, 1.0); - glTexCoord2f(1.0, off+0.000); glVertex2d( 1.0, 1.0); - glTexCoord2f(1.0, off+0.375); glVertex2d( 1.0,-1.0); - glTexCoord2f(0.0, off+0.375); glVertex2d(-1.0,-1.0); - glEnd(); -} - -/************************************************/ -/* RENDERING */ -/************************************************/ - -gboolean screen (GtkWidget * widget, int viewportscreen) { - int screen; - GPU * gpu; - float bright_color = 0.0f; // blend with black - float bright_alpha = 0.0f; // don't blend - - // we take care to draw the right thing the right place - // we need to rearrange widgets not to use this trick - screen = (ScreenInvert)?1-viewportscreen:viewportscreen; -// screen = viewportscreen; - - if (!my_gl_Begin(viewportscreen)) return TRUE; - - glLoadIdentity(); - - // clear screen - glClearColor(0.0f,0.0f,0.0f,0.0f); - glClear( GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT ); - - glEnable(GL_TEXTURE_2D); - - if (desmume_running()) { - - // master bright - gpu = ((screen)?SubScreen:MainScreen).gpu; - - switch (gpu->MasterBrightMode) - { - case 1: // Bright up : blend with white - bright_color = 1.0f; - // no break; - case 2: // Bright down : blend with black - bright_alpha = 1.0f; // blending max - - bright_alpha = gpu->MasterBrightFactor / 16.0; - break; - // Disabled 0, Reserved 3 - default: break; - } - // rotate - glRotatef(ScreenRotate, 0.0, 0.0, 1.0); - // create the texture for both display - my_gl_Texture2D(); - if (viewportscreen==0) { - my_gl_ScreenTex( gtk_glade_use_software_colour_convert); - } - } else { - // pause - // fake master bright up 50% - bright_color = 0.0f; - bright_alpha = 0.5f; - } - // make sure current color is ok - glColor4ub(255,255,255,255); - // apply part of the texture - my_gl_ScreenTexApply(screen); - glDisable(GL_TEXTURE_2D); - - // master bright (bis) - glEnable(GL_BLEND); - glBlendFunc(GL_SRC_ALPHA,GL_ONE_MINUS_SRC_ALPHA); - glColor4f(bright_color,bright_color,bright_color,bright_alpha); - glBegin(GL_QUADS); - glVertex2d(-1.0, 1.0); - glVertex2d( 1.0, 1.0); - glVertex2d( 1.0,-1.0); - glVertex2d(-1.0,-1.0); - glEnd(); - glDisable(GL_BLEND); - - my_gl_End(viewportscreen); - return TRUE; -} - -#endif /* if GTKGLEXT_AVAILABLE */ +/* gdk_gl.cpp - this file is part of DeSmuME + * + * Copyright (C) 2007 Damien Nozay (damdoum) + * Author: damdoum at users.sourceforge.net + * + * This file is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2, or (at your option) + * any later version. + * + * This file is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; see the file COPYING. If not, write to + * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#include "gdk_gl.h" + +#ifdef GTKGLEXT_AVAILABLE + +#include +#include + +#define _DUP8(a) a,a,a,a, a,a,a,a +#define _DUP4(a) a,a,a,a +#define _DUP2(a) a,a + +GLuint Textures[2]; +// free number we can use in tools 0-1 reserved for screens +static int free_gl_drawable=2; +GdkGLConfig *my_glConfig=NULL; +GdkGLContext *my_glContext[8]={_DUP8(NULL)}; +GdkGLDrawable *my_glDrawable[8]={_DUP8(NULL)}; +GtkWidget *pDrawingTexArea; + +GLuint screen_texture[1]; + +/* enable software colour format conversion */ +static int gtk_glade_use_software_colour_convert; + +#undef _DUP8 +#undef _DUP4 +#undef _DUP2 + +/* FIXME: Purpose of this code? */ +static BOOL _fun_gl_Begin (int screen) { return FALSE; } +static void _fun_gl_End (int screen) { } + +fun_gl_Begin Open_GL_beg = _fun_gl_Begin; +fun_gl_End Open_GL_end = _fun_gl_End; + +void register_gl_fun(fun_gl_Begin beg,fun_gl_End end) { + Open_GL_beg = beg; + Open_GL_end = end; +} + +/************************************************/ +/* BEGIN & END */ +/************************************************/ + +BOOL my_gl_Begin (int screen) { + return gdk_gl_drawable_gl_begin(my_glDrawable[screen], my_glContext[screen]); +} + +void my_gl_End (int screen) { + if (gdk_gl_drawable_is_double_buffered (my_glDrawable[screen])) + gdk_gl_drawable_swap_buffers (my_glDrawable[screen]); + else + glFlush(); + gdk_gl_drawable_gl_end(my_glDrawable[screen]); +} + +/************************************************/ +/* OTHER GL COMMANDS */ +/************************************************/ + +void my_gl_Identity() { + glMatrixMode(GL_PROJECTION); + glLoadIdentity(); + glMatrixMode(GL_MODELVIEW); + glLoadIdentity(); +} + +void my_gl_DrawBeautifulQuad( void) { + // beautiful quad + glBegin(GL_QUADS); + glColor3ub(255,0,0); glVertex2d(-0.75,-0.75); + glColor3ub(128,255,0); glVertex2d(-0.75, 0.75); + glColor3ub(0,255,128); glVertex2d( 0.75, 0.75); + glColor3ub(0,0,255); glVertex2d( 0.75,-0.75); + glEnd(); + glColor3ub(255,255,255); +} + +#if 0 /* not used */ +static void my_gl_DrawLogo() { + + +} +#endif + + +void my_gl_Clear(int screen) { + if (!my_gl_Begin(screen)) return; + + /* Set the background black */ + glClearColor(1.0f, 1.0f, 1.0f, 1.0f); + glClearDepth(1.0); + glClear( GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT ); + + my_gl_DrawBeautifulQuad(); + + my_gl_End(screen); +} + +/************************************************/ +/* INITIALIZATION */ +/************************************************/ + +void init_GL(GtkWidget * widget, int screen, int share_num) { +// for (n=gtk_events_pending(); n>0; n--) +// gtk_main_iteration(); + // init GL capability + my_glContext[screen]=NULL; + my_glDrawable[screen]=NULL; + if (!gtk_widget_set_gl_capability( + widget, my_glConfig, + my_glContext[share_num], + //NULL, + TRUE, + GDK_GL_RGBA_TYPE)) { + printf ("gtk_widget_set_gl_capability\n"); + exit(1); + } + // realize so that we get a GdkWindow + gtk_widget_realize(widget); + // make sure we realize + gdk_flush(); + + my_glDrawable[screen] = gtk_widget_get_gl_drawable(widget); + + if (screen == share_num) { + my_glContext[screen] = gtk_widget_get_gl_context(widget); + } else { + my_glContext[screen] = my_glContext[share_num]; + return; + } + + reshape(widget, screen); +} + +int init_GL_free_s(GtkWidget * widget, int share_num) { + int r = free_gl_drawable; + my_glContext[r]=NULL; + my_glDrawable[r]=NULL; + init_GL(widget, r, share_num); + free_gl_drawable++; + return r; +} + +int init_GL_free(GtkWidget * widget) { + int r = free_gl_drawable; + my_glContext[r]=NULL; + my_glDrawable[r]=NULL; + init_GL(widget, r, r); + free_gl_drawable++; + return r; +} + +void init_GL_capabilities( int use_software_convert) { + + uint16_t blank_texture[256 * 512]; + my_glConfig = gdk_gl_config_new_by_mode ( + (GdkGLConfigMode) (GDK_GL_MODE_RGBA + | GDK_GL_MODE_DEPTH + | GDK_GL_MODE_DOUBLE) + ); + + gtk_glade_use_software_colour_convert = use_software_convert; + // initialize 1st drawing area + init_GL(pDrawingArea,0,0); + my_gl_Clear(0); + + if (!my_gl_Begin(0)) return; + // generate ONE texture (display) + glEnable(GL_TEXTURE_2D); + glGenTextures(2, Textures); + + /* Generate The Texture */ + glBindTexture( GL_TEXTURE_2D, Textures[0]); + memset(blank_texture, 0x001f, sizeof(blank_texture)); + glTexImage2D( GL_TEXTURE_2D, 0, GL_RGB, 256, 512, + 0, GL_RGBA, + GL_UNSIGNED_SHORT_1_5_5_5_REV, + blank_texture); + my_gl_End(0); + + // initialize 2nd drawing area (sharing context) + init_GL(pDrawingArea2,1,0); + my_gl_Clear(1); +} + +/************************************************/ +/* RESHAPE */ +/************************************************/ + +void reshape (GtkWidget * widget, int screen) { + if (my_glDrawable[screen] == NULL || + !my_gl_Begin(screen)) return; + + glViewport (0, 0, widget->allocation.width, widget->allocation.height); + glMatrixMode(GL_MODELVIEW); + glLoadIdentity(); + my_gl_End(screen); +} + +/************************************************/ +/* TEXTURING */ +/************************************************/ + +static void my_gl_Texture2D() { + glBindTexture(GL_TEXTURE_2D, Textures[0]); +#define MyFILTER GL_LINEAR +//#define MyFILTER GL_NEAREST + glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, MyFILTER); + glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, MyFILTER); +#undef MyFILTER +} + +static void +my_gl_ScreenTex( int software_convert) { + if ( software_convert) { + u8 converted[256 * 384 * 3]; + int i; + + for ( i = 0; i < (256 * 384); i++) { + converted[(i * 3) + 0] = ((*((u16 *)&GPU_screen[(i<<1)]) >> 0) & 0x1f) << 3; + converted[(i * 3) + 1] = ((*((u16 *)&GPU_screen[(i<<1)]) >> 5) & 0x1f) << 3; + converted[(i * 3) + 2] = ((*((u16 *)&GPU_screen[(i<<1)]) >> 10) & 0x1f) << 3; + } + + glTexSubImage2D( GL_TEXTURE_2D, 0, 0, 0, 256, 384, + GL_RGB, + GL_UNSIGNED_BYTE, + converted); + } + else { + glTexSubImage2D( GL_TEXTURE_2D, 0, 0, 0, 256, 384, + GL_RGBA, + GL_UNSIGNED_SHORT_1_5_5_5_REV, + &GPU_screen); + } +} + +static void my_gl_ScreenTexApply(int screen) { + float off = (screen)?0.375:0; + glBegin(GL_QUADS); + // texcoords 0.375 means 192, 1 means 256 + glTexCoord2f(0.0, off+0.000); glVertex2d(-1.0, 1.0); + glTexCoord2f(1.0, off+0.000); glVertex2d( 1.0, 1.0); + glTexCoord2f(1.0, off+0.375); glVertex2d( 1.0,-1.0); + glTexCoord2f(0.0, off+0.375); glVertex2d(-1.0,-1.0); + glEnd(); +} + +/************************************************/ +/* RENDERING */ +/************************************************/ + +gboolean screen (GtkWidget * widget, int viewportscreen) { + int screen; + GPU * gpu; + float bright_color = 0.0f; // blend with black + float bright_alpha = 0.0f; // don't blend + + // we take care to draw the right thing the right place + // we need to rearrange widgets not to use this trick + screen = (ScreenInvert)?1-viewportscreen:viewportscreen; +// screen = viewportscreen; + + if (!my_gl_Begin(viewportscreen)) return TRUE; + + glLoadIdentity(); + + // clear screen + glClearColor(0.0f,0.0f,0.0f,0.0f); + glClear( GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT ); + + glEnable(GL_TEXTURE_2D); + + if (desmume_running()) { + + // master bright + gpu = ((screen)?SubScreen:MainScreen).gpu; + + switch (gpu->MasterBrightMode) + { + case 1: // Bright up : blend with white + bright_color = 1.0f; + // no break; + case 2: // Bright down : blend with black + bright_alpha = 1.0f; // blending max + + bright_alpha = gpu->MasterBrightFactor / 16.0; + break; + // Disabled 0, Reserved 3 + default: break; + } + // rotate + glRotatef(ScreenRotate, 0.0, 0.0, 1.0); + // create the texture for both display + my_gl_Texture2D(); + if (viewportscreen==0) { + my_gl_ScreenTex( gtk_glade_use_software_colour_convert); + } + } else { + // pause + // fake master bright up 50% + bright_color = 0.0f; + bright_alpha = 0.5f; + } + // make sure current color is ok + glColor4ub(255,255,255,255); + // apply part of the texture + my_gl_ScreenTexApply(screen); + glDisable(GL_TEXTURE_2D); + + // master bright (bis) + glEnable(GL_BLEND); + glBlendFunc(GL_SRC_ALPHA,GL_ONE_MINUS_SRC_ALPHA); + glColor4f(bright_color,bright_color,bright_color,bright_alpha); + glBegin(GL_QUADS); + glVertex2d(-1.0, 1.0); + glVertex2d( 1.0, 1.0); + glVertex2d( 1.0,-1.0); + glVertex2d(-1.0,-1.0); + glEnd(); + glDisable(GL_BLEND); + + my_gl_End(viewportscreen); + return TRUE; +} + +#endif /* if GTKGLEXT_AVAILABLE */ diff --git a/desmume/src/gtk-glade/gdk_gl.h b/src/gtk-glade/gdk_gl.h old mode 100755 new mode 100644 similarity index 96% rename from desmume/src/gtk-glade/gdk_gl.h rename to src/gtk-glade/gdk_gl.h index b88aef93c..a086af566 --- a/desmume/src/gtk-glade/gdk_gl.h +++ b/src/gtk-glade/gdk_gl.h @@ -1,48 +1,48 @@ -/* gdk_gl.h - this file is part of DeSmuME - * - * Copyright (C) 2007 Damien Nozay (damdoum) - * Author: damdoum at users.sourceforge.net - * - * This file is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2, or (at your option) - * any later version. - * - * This file is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; see the file COPYING. If not, write to - * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -#ifndef __GDKGL_H__ -#define __GDKGL_H__ - -#include "globals.h" - -#ifdef GTKGLEXT_AVAILABLE - #include - #include - #include - #include -#endif - - -BOOL my_gl_Begin (int screen); -void my_gl_End (int screen); -void my_gl_Clear(int screen); -void my_gl_DrawBeautifulQuad( void); -void my_gl_Identity( void); - -void init_GL_capabilities( int use_software_convert); -void init_GL(GtkWidget * widget, int screen, int share_num); -int init_GL_free_s(GtkWidget * widget, int share_num); -int init_GL_free(GtkWidget * widget); -void reshape (GtkWidget * widget, int screen); -gboolean screen (GtkWidget * widget, int off); - -#endif +/* gdk_gl.h - this file is part of DeSmuME + * + * Copyright (C) 2007 Damien Nozay (damdoum) + * Author: damdoum at users.sourceforge.net + * + * This file is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2, or (at your option) + * any later version. + * + * This file is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; see the file COPYING. If not, write to + * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#ifndef __GDKGL_H__ +#define __GDKGL_H__ + +#include "globals.h" + +#ifdef GTKGLEXT_AVAILABLE + #include + #include + #include + #include +#endif + + +BOOL my_gl_Begin (int screen); +void my_gl_End (int screen); +void my_gl_Clear(int screen); +void my_gl_DrawBeautifulQuad( void); +void my_gl_Identity( void); + +void init_GL_capabilities( int use_software_convert); +void init_GL(GtkWidget * widget, int screen, int share_num); +int init_GL_free_s(GtkWidget * widget, int share_num); +int init_GL_free(GtkWidget * widget); +void reshape (GtkWidget * widget, int screen); +gboolean screen (GtkWidget * widget, int off); + +#endif diff --git a/desmume/src/gtk-glade/glade-xml.cpp b/src/gtk-glade/glade-xml.cpp old mode 100755 new mode 100644 similarity index 97% rename from desmume/src/gtk-glade/glade-xml.cpp rename to src/gtk-glade/glade-xml.cpp index c884fb041..b808cb944 --- a/desmume/src/gtk-glade/glade-xml.cpp +++ b/src/gtk-glade/glade-xml.cpp @@ -1,129 +1,129 @@ -/* -*- Mode: C; c-basic-offset: 4 -*- - * libglade - a library for building interfaces from XML files at runtime - * Copyright (C) 1998-2002 James Henstridge - * - * glade-xml.c: implementation of core public interface functions - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Library General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Library General Public License for more details. - * - * You should have received a copy of the GNU Library General Public - * License along with this library; if not, write to the - * Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -#include "globals.h" -#include -#include -#include -#include - -typedef struct _GladeXMLPrivate nopriv_GladeXMLPrivate; -struct _GladeXMLPrivate { - GladeInterface *tree; /* the tree for this GladeXML */ - GtkTooltips *tooltips; /* if not NULL, holds all tooltip info */ - GHashTable *name_hash; - GHashTable *signals; - GtkWindow *toplevel; - GtkAccelGroup *accel_group; - GtkWidget *focus_widget; - GtkWidget *default_widget; - GList *deferred_props; -}; - -typedef struct _GladeSignalData GladeSignalData; - -struct _GladeSignalData { - GObject *signal_object; - char *signal_name; - char *connect_object; /* or NULL if there is none */ - gboolean signal_after; -}; - -static void -autoconnect_foreach_StringObject(const char *signal_handler, - GList * signals, GModule * allsymbols) -{ - GCallback func; - - if (!g_module_symbol(allsymbols, signal_handler, (void **) &func)) - g_warning(_("could not find signal handler '%s'."), - signal_handler); - else - for (; signals != NULL; signals = signals->next) { - GladeSignalData *data = (GladeSignalData *) signals->data; - if (data->connect_object) { - GladeXML *self = - glade_get_widget_tree(GTK_WIDGET(data->signal_object)); - char format[] = "%_\0\0"; - if (sscanf(data->connect_object, "%%%c:", &format[1])) { - - // this should solve 64bit problems but now memory gets - // (it should get) deallocated when program is destroyed - gpointer argument = g_malloc(sizeof(callback_arg)); - sscanf(data->connect_object + 3, format, argument); - -// printf ("%f \n",obj); - if (data->signal_after) - g_signal_connect_after(data->signal_object, data->signal_name, func, argument); - else - g_signal_connect(data->signal_object, data->signal_name, func, argument); - } else { - - GObject *other = (GObject *) g_hash_table_lookup( - self->priv->name_hash, - data->connect_object); - g_signal_connect_object(data->signal_object, data->signal_name, func, other, - (GConnectFlags) ((data->signal_after ? G_CONNECT_AFTER : 0) | G_CONNECT_SWAPPED)); - } - - } else { - - /* the signal_data argument is just a string, but may - * be helpful for someone */ - if (data->signal_after) - g_signal_connect_after(data->signal_object, data->signal_name, func, NULL); - else - g_signal_connect(data->signal_object, data->signal_name, func, NULL); - } - } -} - -/** - * glade_xml_signal_autoconnect_StringObject: - * @self: the GladeXML object. - * - * This function is a variation of glade_xml_signal_connect. It uses - * gmodule's introspective features (by openning the module %NULL) to - * look at the application's symbol table. From here it tries to match - * the signal handler names given in the interface description with - * symbols in the application and connects the signals. - * - * Note that this function will not work correctly if gmodule is not - * supported on the platform. - */ - -void glade_xml_signal_autoconnect_StringObject(GladeXML * self) -{ - GModule *allsymbols; - nopriv_GladeXMLPrivate *priv; - - g_return_if_fail(self != NULL); - if (!g_module_supported()) - g_error("glade_xml_signal_autoconnect requires working gmodule"); - - /* get a handle on the main executable -- use this to find symbols */ - allsymbols = g_module_open(NULL, (GModuleFlags) 0); - priv = (nopriv_GladeXMLPrivate *) self->priv; - g_hash_table_foreach(priv->signals, - (GHFunc) autoconnect_foreach_StringObject, - allsymbols); -} +/* -*- Mode: C; c-basic-offset: 4 -*- + * libglade - a library for building interfaces from XML files at runtime + * Copyright (C) 1998-2002 James Henstridge + * + * glade-xml.c: implementation of core public interface functions + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#include "globals.h" +#include +#include +#include +#include + +typedef struct _GladeXMLPrivate nopriv_GladeXMLPrivate; +struct _GladeXMLPrivate { + GladeInterface *tree; /* the tree for this GladeXML */ + GtkTooltips *tooltips; /* if not NULL, holds all tooltip info */ + GHashTable *name_hash; + GHashTable *signals; + GtkWindow *toplevel; + GtkAccelGroup *accel_group; + GtkWidget *focus_widget; + GtkWidget *default_widget; + GList *deferred_props; +}; + +typedef struct _GladeSignalData GladeSignalData; + +struct _GladeSignalData { + GObject *signal_object; + char *signal_name; + char *connect_object; /* or NULL if there is none */ + gboolean signal_after; +}; + +static void +autoconnect_foreach_StringObject(const char *signal_handler, + GList * signals, GModule * allsymbols) +{ + GCallback func; + + if (!g_module_symbol(allsymbols, signal_handler, (void **) &func)) + g_warning(_("could not find signal handler '%s'."), + signal_handler); + else + for (; signals != NULL; signals = signals->next) { + GladeSignalData *data = (GladeSignalData *) signals->data; + if (data->connect_object) { + GladeXML *self = + glade_get_widget_tree(GTK_WIDGET(data->signal_object)); + char format[] = "%_\0\0"; + if (sscanf(data->connect_object, "%%%c:", &format[1])) { + + // this should solve 64bit problems but now memory gets + // (it should get) deallocated when program is destroyed + gpointer argument = g_malloc(sizeof(callback_arg)); + sscanf(data->connect_object + 3, format, argument); + +// printf ("%f \n",obj); + if (data->signal_after) + g_signal_connect_after(data->signal_object, data->signal_name, func, argument); + else + g_signal_connect(data->signal_object, data->signal_name, func, argument); + } else { + + GObject *other = (GObject *) g_hash_table_lookup( + self->priv->name_hash, + data->connect_object); + g_signal_connect_object(data->signal_object, data->signal_name, func, other, + (GConnectFlags) ((data->signal_after ? G_CONNECT_AFTER : 0) | G_CONNECT_SWAPPED)); + } + + } else { + + /* the signal_data argument is just a string, but may + * be helpful for someone */ + if (data->signal_after) + g_signal_connect_after(data->signal_object, data->signal_name, func, NULL); + else + g_signal_connect(data->signal_object, data->signal_name, func, NULL); + } + } +} + +/** + * glade_xml_signal_autoconnect_StringObject: + * @self: the GladeXML object. + * + * This function is a variation of glade_xml_signal_connect. It uses + * gmodule's introspective features (by openning the module %NULL) to + * look at the application's symbol table. From here it tries to match + * the signal handler names given in the interface description with + * symbols in the application and connects the signals. + * + * Note that this function will not work correctly if gmodule is not + * supported on the platform. + */ + +void glade_xml_signal_autoconnect_StringObject(GladeXML * self) +{ + GModule *allsymbols; + nopriv_GladeXMLPrivate *priv; + + g_return_if_fail(self != NULL); + if (!g_module_supported()) + g_error("glade_xml_signal_autoconnect requires working gmodule"); + + /* get a handle on the main executable -- use this to find symbols */ + allsymbols = g_module_open(NULL, (GModuleFlags) 0); + priv = (nopriv_GladeXMLPrivate *) self->priv; + g_hash_table_foreach(priv->signals, + (GHFunc) autoconnect_foreach_StringObject, + allsymbols); +} diff --git a/desmume/src/gtk-glade/glade/DeSmuME.xpm b/src/gtk-glade/glade/DeSmuME.xpm old mode 100755 new mode 100644 similarity index 100% rename from desmume/src/gtk-glade/glade/DeSmuME.xpm rename to src/gtk-glade/glade/DeSmuME.xpm diff --git a/desmume/src/gtk-glade/glade/DeSmuMe.glade b/src/gtk-glade/glade/DeSmuMe.glade old mode 100755 new mode 100644 similarity index 100% rename from desmume/src/gtk-glade/glade/DeSmuMe.glade rename to src/gtk-glade/glade/DeSmuMe.glade diff --git a/desmume/src/gtk-glade/glade/DeSmuMe_Dtools.glade b/src/gtk-glade/glade/DeSmuMe_Dtools.glade old mode 100755 new mode 100644 similarity index 100% rename from desmume/src/gtk-glade/glade/DeSmuMe_Dtools.glade rename to src/gtk-glade/glade/DeSmuMe_Dtools.glade diff --git a/desmume/src/gtk-glade/globals.h b/src/gtk-glade/globals.h old mode 100755 new mode 100644 similarity index 95% rename from desmume/src/gtk-glade/globals.h rename to src/gtk-glade/globals.h index fe6d3f7cd..3d6941767 --- a/desmume/src/gtk-glade/globals.h +++ b/src/gtk-glade/globals.h @@ -1,130 +1,131 @@ -/* globals.h - this file is part of DeSmuME - * - * Copyright (C) 2007 Damien Nozay (damdoum) - * Author: damdoum at users.sourceforge.net - * - * This file is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2, or (at your option) - * any later version. - * - * This file is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; see the file COPYING. If not, write to - * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -#ifndef __GLOBALS_H__ -#define __GLOBALS_H__ - -#ifndef GTK_UI -#define GTK_UI -#endif - -#include -#include -#include -#include - -// Localization -#include -#define _(String) gettext (String) - -#include "SDL.h" - -// fix gtk-glade on windows with no configure -#ifndef DATADIR -#define DATADIR " " -#endif -#ifndef GLADEUI_UNINSTALLED_DIR -#define GLADEUI_UNINSTALLED_DIR "glade/" -#endif - -#include -#include -#include -#include - - -typedef union _callback_arg{ - gpointer my_pointer; - gconstpointer my_constpointer; - - gfloat my_float; - gdouble my_double; - gsize my_size; - gssize my_ssize; - - gboolean my_boolean; - - guchar my_uchar; - guint my_uint; - guint8 my_uint8; - guint16 my_uint16; - guint32 my_uint32; - guint64 my_uint64; - gushort my_ushort; - gulong my_ulong; - - gchar my_char; - gint my_int; - gint8 my_int8; - gint16 my_int16; - gint32 my_int32; - gint64 my_int64; - gshort my_short; - glong my_long; -} callback_arg; -#define dyn_CAST(gtype,var) (((callback_arg*)var)->my_##gtype) - -#include "../MMU.h" -#include "../registers.h" -#include "../armcpu.h" -#include "../NDSSystem.h" -#include "../sndsdl.h" -#include "../ctrlssdl.h" -#include "../types.h" -#include "../saves.h" -#include "../render3D.h" -#include "desmume.h" - -// autoconnect with strings as user_data - -void -glade_xml_signal_autoconnect_StringObject (GladeXML *self); - -//--- - -extern int Frameskip; - -/* main.cpp */ -extern GtkWidget * pWindow; -extern GtkWidget * pDrawingArea, * pDrawingArea2; -extern GladeXML * xml, * xml_tools; - -typedef void (*VoidFunPtr)(); -void notify_Tools(); -void register_Tool(VoidFunPtr fun); -void unregister_Tool(VoidFunPtr fun); -gchar * get_ui_file (const char *filename); - -/* callbacks.cpp */ -void enable_rom_features(); -void resize (float Size1, float Size2); -void rotate(float angle); -extern gboolean ScreenInvert; - -/* callbacks_IO.cpp */ -extern float ScreenCoeff_Size[2]; -extern float ScreenRotate; - -void black_screen (); -void edit_controls(); -void init_joy_labels(); - -#endif /* __GLOBALS_H__ */ +/* globals.h - this file is part of DeSmuME + * + * Copyright (C) 2007 Damien Nozay (damdoum) + * Author: damdoum at users.sourceforge.net + * + * This file is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2, or (at your option) + * any later version. + * + * This file is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; see the file COPYING. If not, write to + * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#ifndef __GLOBALS_H__ +#define __GLOBALS_H__ + +#ifndef GTK_UI +#define GTK_UI +#endif + +#include +#include +#include +#include + +// Localization +#include +#define _(String) gettext (String) + +#include "SDL.h" + +// fix gtk-glade on windows with no configure +#ifndef DATADIR +#define DATADIR " " +#endif +#ifndef GLADEUI_UNINSTALLED_DIR +#define GLADEUI_UNINSTALLED_DIR "glade/" +#endif + +#include +#include +#include +#include + + +typedef union _callback_arg{ + gpointer my_pointer; + gconstpointer my_constpointer; + + gfloat my_float; + gdouble my_double; + gsize my_size; + gssize my_ssize; + + gboolean my_boolean; + + guchar my_uchar; + guint my_uint; + guint8 my_uint8; + guint16 my_uint16; + guint32 my_uint32; + guint64 my_uint64; + gushort my_ushort; + gulong my_ulong; + + gchar my_char; + gint my_int; + gint8 my_int8; + gint16 my_int16; + gint32 my_int32; + gint64 my_int64; + gshort my_short; + glong my_long; +} callback_arg; +#define dyn_CAST(gtype,var) (((callback_arg*)var)->my_##gtype) + +#include "../MMU.h" +#include "../registers.h" +#include "../armcpu.h" +#include "../NDSSystem.h" +#include "../cflash.h" +#include "../sndsdl.h" +#include "../ctrlssdl.h" +#include "../types.h" +#include "../saves.h" +#include "../render3D.h" +#include "desmume.h" + +// autoconnect with strings as user_data + +void +glade_xml_signal_autoconnect_StringObject (GladeXML *self); + +//--- + +extern int Frameskip; + +/* main.cpp */ +extern GtkWidget * pWindow; +extern GtkWidget * pDrawingArea, * pDrawingArea2; +extern GladeXML * xml, * xml_tools; + +typedef void (*VoidFunPtr)(); +void notify_Tools(); +void register_Tool(VoidFunPtr fun); +void unregister_Tool(VoidFunPtr fun); +gchar * get_ui_file (const char *filename); + +/* callbacks.cpp */ +void enable_rom_features(); +void resize (float Size1, float Size2); +void rotate(float angle); +extern gboolean ScreenInvert; + +/* callbacks_IO.cpp */ +extern float ScreenCoeff_Size[2]; +extern float ScreenRotate; + +void black_screen (); +void edit_controls(); +void init_joy_labels(); + +#endif /* __GLOBALS_H__ */ diff --git a/desmume/src/gtk-glade/keyval_names.cpp b/src/gtk-glade/keyval_names.cpp old mode 100755 new mode 100644 similarity index 97% rename from desmume/src/gtk-glade/keyval_names.cpp rename to src/gtk-glade/keyval_names.cpp index 65c94f12e..e15ed42e1 --- a/desmume/src/gtk-glade/keyval_names.cpp +++ b/src/gtk-glade/keyval_names.cpp @@ -1,1384 +1,1384 @@ -/* keyval_names.cpp - this file is part of DeSmuME - * - * Copyright (C) 2007 Damien Nozay (damdoum) - * Author: damdoum at users.sourceforge.net - * - * This file is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2, or (at your option) - * any later version. - * - * This file is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; see the file COPYING. If not, write to - * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -#include "keyval_names.h" -/* see */ - -const char * unknown="(unknown)"; -const char * KEYVAL_NAMES[0x10000]; - -const char * KEYNAME(int k) { - const char * s = unknown; - s = KEYVAL_NAMES[k & 0xFFFF]; - return s; -} - -static void KEYVAL(int k, const char * name) { - if (KEYVAL_NAMES[k] == unknown) - KEYVAL_NAMES[k] = name; -} - -void init_keyvals() { - int i; - for (i=0; i<0x10000; i++) - KEYVAL_NAMES[i]=unknown; - - KEYVAL ( 0x0020 , "space" ); - KEYVAL ( 0x0021 , "exclam" ); - KEYVAL ( 0x0022 , "quotedbl" ); - KEYVAL ( 0x0023 , "numbersign" ); - KEYVAL ( 0x0024 , "dollar" ); - KEYVAL ( 0x0025 , "percent" ); - KEYVAL ( 0x0026 , "ampersand" ); - KEYVAL ( 0x0027 , "apostrophe" ); - KEYVAL ( 0x0027 , "quoteright" ); - KEYVAL ( 0x0028 , "parenleft" ); - KEYVAL ( 0x0029 , "parenright" ); - KEYVAL ( 0x002a , "asterisk" ); - KEYVAL ( 0x002b , "plus" ); - KEYVAL ( 0x002c , "comma" ); - KEYVAL ( 0x002d , "minus" ); - KEYVAL ( 0x002e , "period" ); - KEYVAL ( 0x002f , "slash" ); - KEYVAL ( 0x0030 , "0" ); - KEYVAL ( 0x0031 , "1" ); - KEYVAL ( 0x0032 , "2" ); - KEYVAL ( 0x0033 , "3" ); - KEYVAL ( 0x0034 , "4" ); - KEYVAL ( 0x0035 , "5" ); - KEYVAL ( 0x0036 , "6" ); - KEYVAL ( 0x0037 , "7" ); - KEYVAL ( 0x0038 , "8" ); - KEYVAL ( 0x0039 , "9" ); - KEYVAL ( 0x003a , "colon" ); - KEYVAL ( 0x003b , "semicolon" ); - KEYVAL ( 0x003c , "less" ); - KEYVAL ( 0x003d , "equal" ); - KEYVAL ( 0x003e , "greater" ); - KEYVAL ( 0x003f , "question" ); - KEYVAL ( 0x0040 , "at" ); - KEYVAL ( 0x0041 , "A" ); - KEYVAL ( 0x0042 , "B" ); - KEYVAL ( 0x0043 , "C" ); - KEYVAL ( 0x0044 , "D" ); - KEYVAL ( 0x0045 , "E" ); - KEYVAL ( 0x0046 , "F" ); - KEYVAL ( 0x0047 , "G" ); - KEYVAL ( 0x0048 , "H" ); - KEYVAL ( 0x0049 , "I" ); - KEYVAL ( 0x004a , "J" ); - KEYVAL ( 0x004b , "K" ); - KEYVAL ( 0x004c , "L" ); - KEYVAL ( 0x004d , "M" ); - KEYVAL ( 0x004e , "N" ); - KEYVAL ( 0x004f , "O" ); - KEYVAL ( 0x0050 , "P" ); - KEYVAL ( 0x0051 , "Q" ); - KEYVAL ( 0x0052 , "R" ); - KEYVAL ( 0x0053 , "S" ); - KEYVAL ( 0x0054 , "T" ); - KEYVAL ( 0x0055 , "U" ); - KEYVAL ( 0x0056 , "V" ); - KEYVAL ( 0x0057 , "W" ); - KEYVAL ( 0x0058 , "X" ); - KEYVAL ( 0x0059 , "Y" ); - KEYVAL ( 0x005a , "Z" ); - KEYVAL ( 0x005b , "bracketleft" ); - KEYVAL ( 0x005c , "backslash" ); - KEYVAL ( 0x005d , "bracketright" ); - KEYVAL ( 0x005e , "asciicircum" ); - KEYVAL ( 0x005f , "underscore" ); - KEYVAL ( 0x0060 , "grave" ); - KEYVAL ( 0x0060 , "quoteleft" ); - KEYVAL ( 0x0061 , "a" ); - KEYVAL ( 0x0062 , "b" ); - KEYVAL ( 0x0063 , "c" ); - KEYVAL ( 0x0064 , "d" ); - KEYVAL ( 0x0065 , "e" ); - KEYVAL ( 0x0066 , "f" ); - KEYVAL ( 0x0067 , "g" ); - KEYVAL ( 0x0068 , "h" ); - KEYVAL ( 0x0069 , "i" ); - KEYVAL ( 0x006a , "j" ); - KEYVAL ( 0x006b , "k" ); - KEYVAL ( 0x006c , "l" ); - KEYVAL ( 0x006d , "m" ); - KEYVAL ( 0x006e , "n" ); - KEYVAL ( 0x006f , "o" ); - KEYVAL ( 0x0070 , "p" ); - KEYVAL ( 0x0071 , "q" ); - KEYVAL ( 0x0072 , "r" ); - KEYVAL ( 0x0073 , "s" ); - KEYVAL ( 0x0074 , "t" ); - KEYVAL ( 0x0075 , "u" ); - KEYVAL ( 0x0076 , "v" ); - KEYVAL ( 0x0077 , "w" ); - KEYVAL ( 0x0078 , "x" ); - KEYVAL ( 0x0079 , "y" ); - KEYVAL ( 0x007a , "z" ); - KEYVAL ( 0x007b , "braceleft" ); - KEYVAL ( 0x007c , "bar" ); - KEYVAL ( 0x007d , "braceright" ); - KEYVAL ( 0x007e , "asciitilde" ); - KEYVAL ( 0x00a0 , "nobreakspace" ); - KEYVAL ( 0x00a1 , "exclamdown" ); - KEYVAL ( 0x00a2 , "cent" ); - KEYVAL ( 0x00a3 , "sterling" ); - KEYVAL ( 0x00a4 , "currency" ); - KEYVAL ( 0x00a5 , "yen" ); - KEYVAL ( 0x00a6 , "brokenbar" ); - KEYVAL ( 0x00a7 , "section" ); - KEYVAL ( 0x00a8 , "diaeresis" ); - KEYVAL ( 0x00a9 , "copyright" ); - KEYVAL ( 0x00aa , "ordfeminine" ); - KEYVAL ( 0x00ab , "guillemotleft" ); - KEYVAL ( 0x00ac , "notsign" ); - KEYVAL ( 0x00ad , "hyphen" ); - KEYVAL ( 0x00ae , "registered" ); - KEYVAL ( 0x00af , "macron" ); - KEYVAL ( 0x00b0 , "degree" ); - KEYVAL ( 0x00b1 , "plusminus" ); - KEYVAL ( 0x00b2 , "twosuperior" ); - KEYVAL ( 0x00b3 , "threesuperior" ); - KEYVAL ( 0x00b4 , "acute" ); - KEYVAL ( 0x00b5 , "mu" ); - KEYVAL ( 0x00b6 , "paragraph" ); - KEYVAL ( 0x00b7 , "periodcentered" ); - KEYVAL ( 0x00b8 , "cedilla" ); - KEYVAL ( 0x00b9 , "onesuperior" ); - KEYVAL ( 0x00ba , "masculine" ); - KEYVAL ( 0x00bb , "guillemotright" ); - KEYVAL ( 0x00bc , "onequarter" ); - KEYVAL ( 0x00bd , "onehalf" ); - KEYVAL ( 0x00be , "threequarters" ); - KEYVAL ( 0x00bf , "questiondown" ); - KEYVAL ( 0x00c0 , "Agrave" ); - KEYVAL ( 0x00c1 , "Aacute" ); - KEYVAL ( 0x00c2 , "Acircumflex" ); - KEYVAL ( 0x00c3 , "Atilde" ); - KEYVAL ( 0x00c4 , "Adiaeresis" ); - KEYVAL ( 0x00c5 , "Aring" ); - KEYVAL ( 0x00c6 , "AE" ); - KEYVAL ( 0x00c7 , "Ccedilla" ); - KEYVAL ( 0x00c8 , "Egrave" ); - KEYVAL ( 0x00c9 , "Eacute" ); - KEYVAL ( 0x00ca , "Ecircumflex" ); - KEYVAL ( 0x00cb , "Ediaeresis" ); - KEYVAL ( 0x00cc , "Igrave" ); - KEYVAL ( 0x00cd , "Iacute" ); - KEYVAL ( 0x00ce , "Icircumflex" ); - KEYVAL ( 0x00cf , "Idiaeresis" ); - KEYVAL ( 0x00d0 , "ETH" ); - KEYVAL ( 0x00d0 , "Eth" ); - KEYVAL ( 0x00d1 , "Ntilde" ); - KEYVAL ( 0x00d2 , "Ograve" ); - KEYVAL ( 0x00d3 , "Oacute" ); - KEYVAL ( 0x00d4 , "Ocircumflex" ); - KEYVAL ( 0x00d5 , "Otilde" ); - KEYVAL ( 0x00d6 , "Odiaeresis" ); - KEYVAL ( 0x00d7 , "multiply" ); - KEYVAL ( 0x00d8 , "Ooblique" ); - KEYVAL ( 0x00d9 , "Ugrave" ); - KEYVAL ( 0x00da , "Uacute" ); - KEYVAL ( 0x00db , "Ucircumflex" ); - KEYVAL ( 0x00dc , "Udiaeresis" ); - KEYVAL ( 0x00dd , "Yacute" ); - KEYVAL ( 0x00de , "THORN" ); - KEYVAL ( 0x00de , "Thorn" ); - KEYVAL ( 0x00df , "ssharp" ); - KEYVAL ( 0x00e0 , "agrave" ); - KEYVAL ( 0x00e1 , "aacute" ); - KEYVAL ( 0x00e2 , "acircumflex" ); - KEYVAL ( 0x00e3 , "atilde" ); - KEYVAL ( 0x00e4 , "adiaeresis" ); - KEYVAL ( 0x00e5 , "aring" ); - KEYVAL ( 0x00e6 , "ae" ); - KEYVAL ( 0x00e7 , "ccedilla" ); - KEYVAL ( 0x00e8 , "egrave" ); - KEYVAL ( 0x00e9 , "eacute" ); - KEYVAL ( 0x00ea , "ecircumflex" ); - KEYVAL ( 0x00eb , "ediaeresis" ); - KEYVAL ( 0x00ec , "igrave" ); - KEYVAL ( 0x00ed , "iacute" ); - KEYVAL ( 0x00ee , "icircumflex" ); - KEYVAL ( 0x00ef , "idiaeresis" ); - KEYVAL ( 0x00f0 , "eth" ); - KEYVAL ( 0x00f1 , "ntilde" ); - KEYVAL ( 0x00f2 , "ograve" ); - KEYVAL ( 0x00f3 , "oacute" ); - KEYVAL ( 0x00f4 , "ocircumflex" ); - KEYVAL ( 0x00f5 , "otilde" ); - KEYVAL ( 0x00f6 , "odiaeresis" ); - KEYVAL ( 0x00f7 , "division" ); - KEYVAL ( 0x00f8 , "oslash" ); - KEYVAL ( 0x00f9 , "ugrave" ); - KEYVAL ( 0x00fa , "uacute" ); - KEYVAL ( 0x00fb , "ucircumflex" ); - KEYVAL ( 0x00fc , "udiaeresis" ); - KEYVAL ( 0x00fd , "yacute" ); - KEYVAL ( 0x00fe , "thorn" ); - KEYVAL ( 0x00ff , "ydiaeresis" ); - KEYVAL ( 0x01a1 , "Aogonek" ); - KEYVAL ( 0x01a2 , "breve" ); - KEYVAL ( 0x01a3 , "Lstroke" ); - KEYVAL ( 0x01a5 , "Lcaron" ); - KEYVAL ( 0x01a6 , "Sacute" ); - KEYVAL ( 0x01a9 , "Scaron" ); - KEYVAL ( 0x01aa , "Scedilla" ); - KEYVAL ( 0x01ab , "Tcaron" ); - KEYVAL ( 0x01ac , "Zacute" ); - KEYVAL ( 0x01ae , "Zcaron" ); - KEYVAL ( 0x01af , "Zabovedot" ); - KEYVAL ( 0x01b1 , "aogonek" ); - KEYVAL ( 0x01b2 , "ogonek" ); - KEYVAL ( 0x01b3 , "lstroke" ); - KEYVAL ( 0x01b5 , "lcaron" ); - KEYVAL ( 0x01b6 , "sacute" ); - KEYVAL ( 0x01b7 , "caron" ); - KEYVAL ( 0x01b9 , "scaron" ); - KEYVAL ( 0x01ba , "scedilla" ); - KEYVAL ( 0x01bb , "tcaron" ); - KEYVAL ( 0x01bc , "zacute" ); - KEYVAL ( 0x01bd , "doubleacute" ); - KEYVAL ( 0x01be , "zcaron" ); - KEYVAL ( 0x01bf , "zabovedot" ); - KEYVAL ( 0x01c0 , "Racute" ); - KEYVAL ( 0x01c3 , "Abreve" ); - KEYVAL ( 0x01c5 , "Lacute" ); - KEYVAL ( 0x01c6 , "Cacute" ); - KEYVAL ( 0x01c8 , "Ccaron" ); - KEYVAL ( 0x01ca , "Eogonek" ); - KEYVAL ( 0x01cc , "Ecaron" ); - KEYVAL ( 0x01cf , "Dcaron" ); - KEYVAL ( 0x01d0 , "Dstroke" ); - KEYVAL ( 0x01d1 , "Nacute" ); - KEYVAL ( 0x01d2 , "Ncaron" ); - KEYVAL ( 0x01d5 , "Odoubleacute" ); - KEYVAL ( 0x01d8 , "Rcaron" ); - KEYVAL ( 0x01d9 , "Uring" ); - KEYVAL ( 0x01db , "Udoubleacute" ); - KEYVAL ( 0x01de , "Tcedilla" ); - KEYVAL ( 0x01e0 , "racute" ); - KEYVAL ( 0x01e3 , "abreve" ); - KEYVAL ( 0x01e5 , "lacute" ); - KEYVAL ( 0x01e6 , "cacute" ); - KEYVAL ( 0x01e8 , "ccaron" ); - KEYVAL ( 0x01ea , "eogonek" ); - KEYVAL ( 0x01ec , "ecaron" ); - KEYVAL ( 0x01ef , "dcaron" ); - KEYVAL ( 0x01f0 , "dstroke" ); - KEYVAL ( 0x01f1 , "nacute" ); - KEYVAL ( 0x01f2 , "ncaron" ); - KEYVAL ( 0x01f5 , "odoubleacute" ); - KEYVAL ( 0x01f8 , "rcaron" ); - KEYVAL ( 0x01f9 , "uring" ); - KEYVAL ( 0x01fb , "udoubleacute" ); - KEYVAL ( 0x01fe , "tcedilla" ); - KEYVAL ( 0x01ff , "abovedot" ); - KEYVAL ( 0x02a1 , "Hstroke" ); - KEYVAL ( 0x02a6 , "Hcircumflex" ); - KEYVAL ( 0x02a9 , "Iabovedot" ); - KEYVAL ( 0x02ab , "Gbreve" ); - KEYVAL ( 0x02ac , "Jcircumflex" ); - KEYVAL ( 0x02b1 , "hstroke" ); - KEYVAL ( 0x02b6 , "hcircumflex" ); - KEYVAL ( 0x02b9 , "idotless" ); - KEYVAL ( 0x02bb , "gbreve" ); - KEYVAL ( 0x02bc , "jcircumflex" ); - KEYVAL ( 0x02c5 , "Cabovedot" ); - KEYVAL ( 0x02c6 , "Ccircumflex" ); - KEYVAL ( 0x02d5 , "Gabovedot" ); - KEYVAL ( 0x02d8 , "Gcircumflex" ); - KEYVAL ( 0x02dd , "Ubreve" ); - KEYVAL ( 0x02de , "Scircumflex" ); - KEYVAL ( 0x02e5 , "cabovedot" ); - KEYVAL ( 0x02e6 , "ccircumflex" ); - KEYVAL ( 0x02f5 , "gabovedot" ); - KEYVAL ( 0x02f8 , "gcircumflex" ); - KEYVAL ( 0x02fd , "ubreve" ); - KEYVAL ( 0x02fe , "scircumflex" ); - KEYVAL ( 0x03a2 , "kappa" ); - KEYVAL ( 0x03a2 , "kra" ); - KEYVAL ( 0x03a3 , "Rcedilla" ); - KEYVAL ( 0x03a5 , "Itilde" ); - KEYVAL ( 0x03a6 , "Lcedilla" ); - KEYVAL ( 0x03aa , "Emacron" ); - KEYVAL ( 0x03ab , "Gcedilla" ); - KEYVAL ( 0x03ac , "Tslash" ); - KEYVAL ( 0x03b3 , "rcedilla" ); - KEYVAL ( 0x03b5 , "itilde" ); - KEYVAL ( 0x03b6 , "lcedilla" ); - KEYVAL ( 0x03ba , "emacron" ); - KEYVAL ( 0x03bb , "gcedilla" ); - KEYVAL ( 0x03bc , "tslash" ); - KEYVAL ( 0x03bd , "ENG" ); - KEYVAL ( 0x03bf , "eng" ); - KEYVAL ( 0x03c0 , "Amacron" ); - KEYVAL ( 0x03c7 , "Iogonek" ); - KEYVAL ( 0x03cc , "Eabovedot" ); - KEYVAL ( 0x03cf , "Imacron" ); - KEYVAL ( 0x03d1 , "Ncedilla" ); - KEYVAL ( 0x03d2 , "Omacron" ); - KEYVAL ( 0x03d3 , "Kcedilla" ); - KEYVAL ( 0x03d9 , "Uogonek" ); - KEYVAL ( 0x03dd , "Utilde" ); - KEYVAL ( 0x03de , "Umacron" ); - KEYVAL ( 0x03e0 , "amacron" ); - KEYVAL ( 0x03e7 , "iogonek" ); - KEYVAL ( 0x03ec , "eabovedot" ); - KEYVAL ( 0x03ef , "imacron" ); - KEYVAL ( 0x03f1 , "ncedilla" ); - KEYVAL ( 0x03f2 , "omacron" ); - KEYVAL ( 0x03f3 , "kcedilla" ); - KEYVAL ( 0x03f9 , "uogonek" ); - KEYVAL ( 0x03fd , "utilde" ); - KEYVAL ( 0x03fe , "umacron" ); - KEYVAL ( 0x047e , "overline" ); - KEYVAL ( 0x04a1 , "kana_fullstop" ); - KEYVAL ( 0x04a2 , "kana_openingbracket" ); - KEYVAL ( 0x04a3 , "kana_closingbracket" ); - KEYVAL ( 0x04a4 , "kana_comma" ); - KEYVAL ( 0x04a5 , "kana_conjunctive" ); - KEYVAL ( 0x04a5 , "kana_middledot" ); - KEYVAL ( 0x04a6 , "kana_WO" ); - KEYVAL ( 0x04a7 , "kana_a" ); - KEYVAL ( 0x04a8 , "kana_i" ); - KEYVAL ( 0x04a9 , "kana_u" ); - KEYVAL ( 0x04aa , "kana_e" ); - KEYVAL ( 0x04ab , "kana_o" ); - KEYVAL ( 0x04ac , "kana_ya" ); - KEYVAL ( 0x04ad , "kana_yu" ); - KEYVAL ( 0x04ae , "kana_yo" ); - KEYVAL ( 0x04af , "kana_tsu" ); - KEYVAL ( 0x04af , "kana_tu" ); - KEYVAL ( 0x04b0 , "prolongedsound" ); - KEYVAL ( 0x04b1 , "kana_A" ); - KEYVAL ( 0x04b2 , "kana_I" ); - KEYVAL ( 0x04b3 , "kana_U" ); - KEYVAL ( 0x04b4 , "kana_E" ); - KEYVAL ( 0x04b5 , "kana_O" ); - KEYVAL ( 0x04b6 , "kana_KA" ); - KEYVAL ( 0x04b7 , "kana_KI" ); - KEYVAL ( 0x04b8 , "kana_KU" ); - KEYVAL ( 0x04b9 , "kana_KE" ); - KEYVAL ( 0x04ba , "kana_KO" ); - KEYVAL ( 0x04bb , "kana_SA" ); - KEYVAL ( 0x04bc , "kana_SHI" ); - KEYVAL ( 0x04bd , "kana_SU" ); - KEYVAL ( 0x04be , "kana_SE" ); - KEYVAL ( 0x04bf , "kana_SO" ); - KEYVAL ( 0x04c0 , "kana_TA" ); - KEYVAL ( 0x04c1 , "kana_CHI" ); - KEYVAL ( 0x04c1 , "kana_TI" ); - KEYVAL ( 0x04c2 , "kana_TSU" ); - KEYVAL ( 0x04c2 , "kana_TU" ); - KEYVAL ( 0x04c3 , "kana_TE" ); - KEYVAL ( 0x04c4 , "kana_TO" ); - KEYVAL ( 0x04c5 , "kana_NA" ); - KEYVAL ( 0x04c6 , "kana_NI" ); - KEYVAL ( 0x04c7 , "kana_NU" ); - KEYVAL ( 0x04c8 , "kana_NE" ); - KEYVAL ( 0x04c9 , "kana_NO" ); - KEYVAL ( 0x04ca , "kana_HA" ); - KEYVAL ( 0x04cb , "kana_HI" ); - KEYVAL ( 0x04cc , "kana_FU" ); - KEYVAL ( 0x04cc , "kana_HU" ); - KEYVAL ( 0x04cd , "kana_HE" ); - KEYVAL ( 0x04ce , "kana_HO" ); - KEYVAL ( 0x04cf , "kana_MA" ); - KEYVAL ( 0x04d0 , "kana_MI" ); - KEYVAL ( 0x04d1 , "kana_MU" ); - KEYVAL ( 0x04d2 , "kana_ME" ); - KEYVAL ( 0x04d3 , "kana_MO" ); - KEYVAL ( 0x04d4 , "kana_YA" ); - KEYVAL ( 0x04d5 , "kana_YU" ); - KEYVAL ( 0x04d6 , "kana_YO" ); - KEYVAL ( 0x04d7 , "kana_RA" ); - KEYVAL ( 0x04d8 , "kana_RI" ); - KEYVAL ( 0x04d9 , "kana_RU" ); - KEYVAL ( 0x04da , "kana_RE" ); - KEYVAL ( 0x04db , "kana_RO" ); - KEYVAL ( 0x04dc , "kana_WA" ); - KEYVAL ( 0x04dd , "kana_N" ); - KEYVAL ( 0x04de , "voicedsound" ); - KEYVAL ( 0x04df , "semivoicedsound" ); - KEYVAL ( 0x05ac , "Arabic_comma" ); - KEYVAL ( 0x05bb , "Arabic_semicolon" ); - KEYVAL ( 0x05bf , "Arabic_question_mark" ); - KEYVAL ( 0x05c1 , "Arabic_hamza" ); - KEYVAL ( 0x05c2 , "Arabic_maddaonalef" ); - KEYVAL ( 0x05c3 , "Arabic_hamzaonalef" ); - KEYVAL ( 0x05c4 , "Arabic_hamzaonwaw" ); - KEYVAL ( 0x05c5 , "Arabic_hamzaunderalef" ); - KEYVAL ( 0x05c6 , "Arabic_hamzaonyeh" ); - KEYVAL ( 0x05c7 , "Arabic_alef" ); - KEYVAL ( 0x05c8 , "Arabic_beh" ); - KEYVAL ( 0x05c9 , "Arabic_tehmarbuta" ); - KEYVAL ( 0x05ca , "Arabic_teh" ); - KEYVAL ( 0x05cb , "Arabic_theh" ); - KEYVAL ( 0x05cc , "Arabic_jeem" ); - KEYVAL ( 0x05cd , "Arabic_hah" ); - KEYVAL ( 0x05ce , "Arabic_khah" ); - KEYVAL ( 0x05cf , "Arabic_dal" ); - KEYVAL ( 0x05d0 , "Arabic_thal" ); - KEYVAL ( 0x05d1 , "Arabic_ra" ); - KEYVAL ( 0x05d2 , "Arabic_zain" ); - KEYVAL ( 0x05d3 , "Arabic_seen" ); - KEYVAL ( 0x05d4 , "Arabic_sheen" ); - KEYVAL ( 0x05d5 , "Arabic_sad" ); - KEYVAL ( 0x05d6 , "Arabic_dad" ); - KEYVAL ( 0x05d7 , "Arabic_tah" ); - KEYVAL ( 0x05d8 , "Arabic_zah" ); - KEYVAL ( 0x05d9 , "Arabic_ain" ); - KEYVAL ( 0x05da , "Arabic_ghain" ); - KEYVAL ( 0x05e0 , "Arabic_tatweel" ); - KEYVAL ( 0x05e1 , "Arabic_feh" ); - KEYVAL ( 0x05e2 , "Arabic_qaf" ); - KEYVAL ( 0x05e3 , "Arabic_kaf" ); - KEYVAL ( 0x05e4 , "Arabic_lam" ); - KEYVAL ( 0x05e5 , "Arabic_meem" ); - KEYVAL ( 0x05e6 , "Arabic_noon" ); - KEYVAL ( 0x05e7 , "Arabic_ha" ); - KEYVAL ( 0x05e7 , "Arabic_heh" ); - KEYVAL ( 0x05e8 , "Arabic_waw" ); - KEYVAL ( 0x05e9 , "Arabic_alefmaksura" ); - KEYVAL ( 0x05ea , "Arabic_yeh" ); - KEYVAL ( 0x05eb , "Arabic_fathatan" ); - KEYVAL ( 0x05ec , "Arabic_dammatan" ); - KEYVAL ( 0x05ed , "Arabic_kasratan" ); - KEYVAL ( 0x05ee , "Arabic_fatha" ); - KEYVAL ( 0x05ef , "Arabic_damma" ); - KEYVAL ( 0x05f0 , "Arabic_kasra" ); - KEYVAL ( 0x05f1 , "Arabic_shadda" ); - KEYVAL ( 0x05f2 , "Arabic_sukun" ); - KEYVAL ( 0x06a1 , "Serbian_dje" ); - KEYVAL ( 0x06a2 , "Macedonia_gje" ); - KEYVAL ( 0x06a3 , "Cyrillic_io" ); - KEYVAL ( 0x06a4 , "Ukrainian_ie" ); - KEYVAL ( 0x06a4 , "Ukranian_je" ); - KEYVAL ( 0x06a5 , "Macedonia_dse" ); - KEYVAL ( 0x06a6 , "Ukrainian_i" ); - KEYVAL ( 0x06a6 , "Ukranian_i" ); - KEYVAL ( 0x06a7 , "Ukrainian_yi" ); - KEYVAL ( 0x06a7 , "Ukranian_yi" ); - KEYVAL ( 0x06a8 , "Cyrillic_je" ); - KEYVAL ( 0x06a8 , "Serbian_je" ); - KEYVAL ( 0x06a9 , "Cyrillic_lje" ); - KEYVAL ( 0x06a9 , "Serbian_lje" ); - KEYVAL ( 0x06aa , "Cyrillic_nje" ); - KEYVAL ( 0x06aa , "Serbian_nje" ); - KEYVAL ( 0x06ab , "Serbian_tshe" ); - KEYVAL ( 0x06ac , "Macedonia_kje" ); - KEYVAL ( 0x06ad , "Ukrainian_ghe_with_upturn" ); - KEYVAL ( 0x06ae , "Byelorussian_shortu" ); - KEYVAL ( 0x06af , "Cyrillic_dzhe" ); - KEYVAL ( 0x06af , "Serbian_dze" ); - KEYVAL ( 0x06b0 , "numerosign" ); - KEYVAL ( 0x06b1 , "Serbian_DJE" ); - KEYVAL ( 0x06b2 , "Macedonia_GJE" ); - KEYVAL ( 0x06b3 , "Cyrillic_IO" ); - KEYVAL ( 0x06b4 , "Ukrainian_IE" ); - KEYVAL ( 0x06b4 , "Ukranian_JE" ); - KEYVAL ( 0x06b5 , "Macedonia_DSE" ); - KEYVAL ( 0x06b6 , "Ukrainian_I" ); - KEYVAL ( 0x06b6 , "Ukranian_I" ); - KEYVAL ( 0x06b7 , "Ukrainian_YI" ); - KEYVAL ( 0x06b7 , "Ukranian_YI" ); - KEYVAL ( 0x06b8 , "Cyrillic_JE" ); - KEYVAL ( 0x06b8 , "Serbian_JE" ); - KEYVAL ( 0x06b9 , "Cyrillic_LJE" ); - KEYVAL ( 0x06b9 , "Serbian_LJE" ); - KEYVAL ( 0x06ba , "Cyrillic_NJE" ); - KEYVAL ( 0x06ba , "Serbian_NJE" ); - KEYVAL ( 0x06bb , "Serbian_TSHE" ); - KEYVAL ( 0x06bc , "Macedonia_KJE" ); - KEYVAL ( 0x06bd , "Ukrainian_GHE_WITH_UPTURN" ); - KEYVAL ( 0x06be , "Byelorussian_SHORTU" ); - KEYVAL ( 0x06bf , "Cyrillic_DZHE" ); - KEYVAL ( 0x06bf , "Serbian_DZE" ); - KEYVAL ( 0x06c0 , "Cyrillic_yu" ); - KEYVAL ( 0x06c1 , "Cyrillic_a" ); - KEYVAL ( 0x06c2 , "Cyrillic_be" ); - KEYVAL ( 0x06c3 , "Cyrillic_tse" ); - KEYVAL ( 0x06c4 , "Cyrillic_de" ); - KEYVAL ( 0x06c5 , "Cyrillic_ie" ); - KEYVAL ( 0x06c6 , "Cyrillic_ef" ); - KEYVAL ( 0x06c7 , "Cyrillic_ghe" ); - KEYVAL ( 0x06c8 , "Cyrillic_ha" ); - KEYVAL ( 0x06c9 , "Cyrillic_i" ); - KEYVAL ( 0x06ca , "Cyrillic_shorti" ); - KEYVAL ( 0x06cb , "Cyrillic_ka" ); - KEYVAL ( 0x06cc , "Cyrillic_el" ); - KEYVAL ( 0x06cd , "Cyrillic_em" ); - KEYVAL ( 0x06ce , "Cyrillic_en" ); - KEYVAL ( 0x06cf , "Cyrillic_o" ); - KEYVAL ( 0x06d0 , "Cyrillic_pe" ); - KEYVAL ( 0x06d1 , "Cyrillic_ya" ); - KEYVAL ( 0x06d2 , "Cyrillic_er" ); - KEYVAL ( 0x06d3 , "Cyrillic_es" ); - KEYVAL ( 0x06d4 , "Cyrillic_te" ); - KEYVAL ( 0x06d5 , "Cyrillic_u" ); - KEYVAL ( 0x06d6 , "Cyrillic_zhe" ); - KEYVAL ( 0x06d7 , "Cyrillic_ve" ); - KEYVAL ( 0x06d8 , "Cyrillic_softsign" ); - KEYVAL ( 0x06d9 , "Cyrillic_yeru" ); - KEYVAL ( 0x06da , "Cyrillic_ze" ); - KEYVAL ( 0x06db , "Cyrillic_sha" ); - KEYVAL ( 0x06dc , "Cyrillic_e" ); - KEYVAL ( 0x06dd , "Cyrillic_shcha" ); - KEYVAL ( 0x06de , "Cyrillic_che" ); - KEYVAL ( 0x06df , "Cyrillic_hardsign" ); - KEYVAL ( 0x06e0 , "Cyrillic_YU" ); - KEYVAL ( 0x06e1 , "Cyrillic_A" ); - KEYVAL ( 0x06e2 , "Cyrillic_BE" ); - KEYVAL ( 0x06e3 , "Cyrillic_TSE" ); - KEYVAL ( 0x06e4 , "Cyrillic_DE" ); - KEYVAL ( 0x06e5 , "Cyrillic_IE" ); - KEYVAL ( 0x06e6 , "Cyrillic_EF" ); - KEYVAL ( 0x06e7 , "Cyrillic_GHE" ); - KEYVAL ( 0x06e8 , "Cyrillic_HA" ); - KEYVAL ( 0x06e9 , "Cyrillic_I" ); - KEYVAL ( 0x06ea , "Cyrillic_SHORTI" ); - KEYVAL ( 0x06eb , "Cyrillic_KA" ); - KEYVAL ( 0x06ec , "Cyrillic_EL" ); - KEYVAL ( 0x06ed , "Cyrillic_EM" ); - KEYVAL ( 0x06ee , "Cyrillic_EN" ); - KEYVAL ( 0x06ef , "Cyrillic_O" ); - KEYVAL ( 0x06f0 , "Cyrillic_PE" ); - KEYVAL ( 0x06f1 , "Cyrillic_YA" ); - KEYVAL ( 0x06f2 , "Cyrillic_ER" ); - KEYVAL ( 0x06f3 , "Cyrillic_ES" ); - KEYVAL ( 0x06f4 , "Cyrillic_TE" ); - KEYVAL ( 0x06f5 , "Cyrillic_U" ); - KEYVAL ( 0x06f6 , "Cyrillic_ZHE" ); - KEYVAL ( 0x06f7 , "Cyrillic_VE" ); - KEYVAL ( 0x06f8 , "Cyrillic_SOFTSIGN" ); - KEYVAL ( 0x06f9 , "Cyrillic_YERU" ); - KEYVAL ( 0x06fa , "Cyrillic_ZE" ); - KEYVAL ( 0x06fb , "Cyrillic_SHA" ); - KEYVAL ( 0x06fc , "Cyrillic_E" ); - KEYVAL ( 0x06fd , "Cyrillic_SHCHA" ); - KEYVAL ( 0x06fe , "Cyrillic_CHE" ); - KEYVAL ( 0x06ff , "Cyrillic_HARDSIGN" ); - KEYVAL ( 0x07a1 , "Greek_ALPHAaccent" ); - KEYVAL ( 0x07a2 , "Greek_EPSILONaccent" ); - KEYVAL ( 0x07a3 , "Greek_ETAaccent" ); - KEYVAL ( 0x07a4 , "Greek_IOTAaccent" ); - KEYVAL ( 0x07a5 , "Greek_IOTAdieresis" ); - KEYVAL ( 0x07a7 , "Greek_OMICRONaccent" ); - KEYVAL ( 0x07a8 , "Greek_UPSILONaccent" ); - KEYVAL ( 0x07a9 , "Greek_UPSILONdieresis" ); - KEYVAL ( 0x07ab , "Greek_OMEGAaccent" ); - KEYVAL ( 0x07ae , "Greek_accentdieresis" ); - KEYVAL ( 0x07af , "Greek_horizbar" ); - KEYVAL ( 0x07b1 , "Greek_alphaaccent" ); - KEYVAL ( 0x07b2 , "Greek_epsilonaccent" ); - KEYVAL ( 0x07b3 , "Greek_etaaccent" ); - KEYVAL ( 0x07b4 , "Greek_iotaaccent" ); - KEYVAL ( 0x07b5 , "Greek_iotadieresis" ); - KEYVAL ( 0x07b6 , "Greek_iotaaccentdieresis" ); - KEYVAL ( 0x07b7 , "Greek_omicronaccent" ); - KEYVAL ( 0x07b8 , "Greek_upsilonaccent" ); - KEYVAL ( 0x07b9 , "Greek_upsilondieresis" ); - KEYVAL ( 0x07ba , "Greek_upsilonaccentdieresis" ); - KEYVAL ( 0x07bb , "Greek_omegaaccent" ); - KEYVAL ( 0x07c1 , "Greek_ALPHA" ); - KEYVAL ( 0x07c2 , "Greek_BETA" ); - KEYVAL ( 0x07c3 , "Greek_GAMMA" ); - KEYVAL ( 0x07c4 , "Greek_DELTA" ); - KEYVAL ( 0x07c5 , "Greek_EPSILON" ); - KEYVAL ( 0x07c6 , "Greek_ZETA" ); - KEYVAL ( 0x07c7 , "Greek_ETA" ); - KEYVAL ( 0x07c8 , "Greek_THETA" ); - KEYVAL ( 0x07c9 , "Greek_IOTA" ); - KEYVAL ( 0x07ca , "Greek_KAPPA" ); - KEYVAL ( 0x07cb , "Greek_LAMBDA" ); - KEYVAL ( 0x07cb , "Greek_LAMDA" ); - KEYVAL ( 0x07cc , "Greek_MU" ); - KEYVAL ( 0x07cd , "Greek_NU" ); - KEYVAL ( 0x07ce , "Greek_XI" ); - KEYVAL ( 0x07cf , "Greek_OMICRON" ); - KEYVAL ( 0x07d0 , "Greek_PI" ); - KEYVAL ( 0x07d1 , "Greek_RHO" ); - KEYVAL ( 0x07d2 , "Greek_SIGMA" ); - KEYVAL ( 0x07d4 , "Greek_TAU" ); - KEYVAL ( 0x07d5 , "Greek_UPSILON" ); - KEYVAL ( 0x07d6 , "Greek_PHI" ); - KEYVAL ( 0x07d7 , "Greek_CHI" ); - KEYVAL ( 0x07d8 , "Greek_PSI" ); - KEYVAL ( 0x07d9 , "Greek_OMEGA" ); - KEYVAL ( 0x07e1 , "Greek_alpha" ); - KEYVAL ( 0x07e2 , "Greek_beta" ); - KEYVAL ( 0x07e3 , "Greek_gamma" ); - KEYVAL ( 0x07e4 , "Greek_delta" ); - KEYVAL ( 0x07e5 , "Greek_epsilon" ); - KEYVAL ( 0x07e6 , "Greek_zeta" ); - KEYVAL ( 0x07e7 , "Greek_eta" ); - KEYVAL ( 0x07e8 , "Greek_theta" ); - KEYVAL ( 0x07e9 , "Greek_iota" ); - KEYVAL ( 0x07ea , "Greek_kappa" ); - KEYVAL ( 0x07eb , "Greek_lambda" ); - KEYVAL ( 0x07eb , "Greek_lamda" ); - KEYVAL ( 0x07ec , "Greek_mu" ); - KEYVAL ( 0x07ed , "Greek_nu" ); - KEYVAL ( 0x07ee , "Greek_xi" ); - KEYVAL ( 0x07ef , "Greek_omicron" ); - KEYVAL ( 0x07f0 , "Greek_pi" ); - KEYVAL ( 0x07f1 , "Greek_rho" ); - KEYVAL ( 0x07f2 , "Greek_sigma" ); - KEYVAL ( 0x07f3 , "Greek_finalsmallsigma" ); - KEYVAL ( 0x07f4 , "Greek_tau" ); - KEYVAL ( 0x07f5 , "Greek_upsilon" ); - KEYVAL ( 0x07f6 , "Greek_phi" ); - KEYVAL ( 0x07f7 , "Greek_chi" ); - KEYVAL ( 0x07f8 , "Greek_psi" ); - KEYVAL ( 0x07f9 , "Greek_omega" ); - KEYVAL ( 0x08a1 , "leftradical" ); - KEYVAL ( 0x08a2 , "topleftradical" ); - KEYVAL ( 0x08a3 , "horizconnector" ); - KEYVAL ( 0x08a4 , "topintegral" ); - KEYVAL ( 0x08a5 , "botintegral" ); - KEYVAL ( 0x08a6 , "vertconnector" ); - KEYVAL ( 0x08a7 , "topleftsqbracket" ); - KEYVAL ( 0x08a8 , "botleftsqbracket" ); - KEYVAL ( 0x08a9 , "toprightsqbracket" ); - KEYVAL ( 0x08aa , "botrightsqbracket" ); - KEYVAL ( 0x08ab , "topleftparens" ); - KEYVAL ( 0x08ac , "botleftparens" ); - KEYVAL ( 0x08ad , "toprightparens" ); - KEYVAL ( 0x08ae , "botrightparens" ); - KEYVAL ( 0x08af , "leftmiddlecurlybrace" ); - KEYVAL ( 0x08b0 , "rightmiddlecurlybrace" ); - KEYVAL ( 0x08b1 , "topleftsummation" ); - KEYVAL ( 0x08b2 , "botleftsummation" ); - KEYVAL ( 0x08b3 , "topvertsummationconnector" ); - KEYVAL ( 0x08b4 , "botvertsummationconnector" ); - KEYVAL ( 0x08b5 , "toprightsummation" ); - KEYVAL ( 0x08b6 , "botrightsummation" ); - KEYVAL ( 0x08b7 , "rightmiddlesummation" ); - KEYVAL ( 0x08bc , "lessthanequal" ); - KEYVAL ( 0x08bd , "notequal" ); - KEYVAL ( 0x08be , "greaterthanequal" ); - KEYVAL ( 0x08bf , "integral" ); - KEYVAL ( 0x08c0 , "therefore" ); - KEYVAL ( 0x08c1 , "variation" ); - KEYVAL ( 0x08c2 , "infinity" ); - KEYVAL ( 0x08c5 , "nabla" ); - KEYVAL ( 0x08c8 , "approximate" ); - KEYVAL ( 0x08c9 , "similarequal" ); - KEYVAL ( 0x08cd , "ifonlyif" ); - KEYVAL ( 0x08ce , "implies" ); - KEYVAL ( 0x08cf , "identical" ); - KEYVAL ( 0x08d6 , "radical" ); - KEYVAL ( 0x08da , "includedin" ); - KEYVAL ( 0x08db , "includes" ); - KEYVAL ( 0x08dc , "intersection" ); - KEYVAL ( 0x08dd , "union" ); - KEYVAL ( 0x08de , "logicaland" ); - KEYVAL ( 0x08df , "logicalor" ); - KEYVAL ( 0x08ef , "partialderivative" ); - KEYVAL ( 0x08f6 , "function" ); - KEYVAL ( 0x08fb , "leftarrow" ); - KEYVAL ( 0x08fc , "uparrow" ); - KEYVAL ( 0x08fd , "rightarrow" ); - KEYVAL ( 0x08fe , "downarrow" ); - KEYVAL ( 0x09df , "blank" ); - KEYVAL ( 0x09e0 , "soliddiamond" ); - KEYVAL ( 0x09e1 , "checkerboard" ); - KEYVAL ( 0x09e2 , "ht" ); - KEYVAL ( 0x09e3 , "ff" ); - KEYVAL ( 0x09e4 , "cr" ); - KEYVAL ( 0x09e5 , "lf" ); - KEYVAL ( 0x09e8 , "nl" ); - KEYVAL ( 0x09e9 , "vt" ); - KEYVAL ( 0x09ea , "lowrightcorner" ); - KEYVAL ( 0x09eb , "uprightcorner" ); - KEYVAL ( 0x09ec , "upleftcorner" ); - KEYVAL ( 0x09ed , "lowleftcorner" ); - KEYVAL ( 0x09ee , "crossinglines" ); - KEYVAL ( 0x09ef , "horizlinescan1" ); - KEYVAL ( 0x09f0 , "horizlinescan3" ); - KEYVAL ( 0x09f1 , "horizlinescan5" ); - KEYVAL ( 0x09f2 , "horizlinescan7" ); - KEYVAL ( 0x09f3 , "horizlinescan9" ); - KEYVAL ( 0x09f4 , "leftt" ); - KEYVAL ( 0x09f5 , "rightt" ); - KEYVAL ( 0x09f6 , "bott" ); - KEYVAL ( 0x09f7 , "topt" ); - KEYVAL ( 0x09f8 , "vertbar" ); - KEYVAL ( 0x0aa1 , "emspace" ); - KEYVAL ( 0x0aa2 , "enspace" ); - KEYVAL ( 0x0aa3 , "em3space" ); - KEYVAL ( 0x0aa4 , "em4space" ); - KEYVAL ( 0x0aa5 , "digitspace" ); - KEYVAL ( 0x0aa6 , "punctspace" ); - KEYVAL ( 0x0aa7 , "thinspace" ); - KEYVAL ( 0x0aa8 , "hairspace" ); - KEYVAL ( 0x0aa9 , "emdash" ); - KEYVAL ( 0x0aaa , "endash" ); - KEYVAL ( 0x0aac , "signifblank" ); - KEYVAL ( 0x0aae , "ellipsis" ); - KEYVAL ( 0x0aaf , "doubbaselinedot" ); - KEYVAL ( 0x0ab0 , "onethird" ); - KEYVAL ( 0x0ab1 , "twothirds" ); - KEYVAL ( 0x0ab2 , "onefifth" ); - KEYVAL ( 0x0ab3 , "twofifths" ); - KEYVAL ( 0x0ab4 , "threefifths" ); - KEYVAL ( 0x0ab5 , "fourfifths" ); - KEYVAL ( 0x0ab6 , "onesixth" ); - KEYVAL ( 0x0ab7 , "fivesixths" ); - KEYVAL ( 0x0ab8 , "careof" ); - KEYVAL ( 0x0abb , "figdash" ); - KEYVAL ( 0x0abc , "leftanglebracket" ); - KEYVAL ( 0x0abd , "decimalpoint" ); - KEYVAL ( 0x0abe , "rightanglebracket" ); - KEYVAL ( 0x0abf , "marker" ); - KEYVAL ( 0x0ac3 , "oneeighth" ); - KEYVAL ( 0x0ac4 , "threeeighths" ); - KEYVAL ( 0x0ac5 , "fiveeighths" ); - KEYVAL ( 0x0ac6 , "seveneighths" ); - KEYVAL ( 0x0ac9 , "trademark" ); - KEYVAL ( 0x0aca , "signaturemark" ); - KEYVAL ( 0x0acb , "trademarkincircle" ); - KEYVAL ( 0x0acc , "leftopentriangle" ); - KEYVAL ( 0x0acd , "rightopentriangle" ); - KEYVAL ( 0x0ace , "emopencircle" ); - KEYVAL ( 0x0acf , "emopenrectangle" ); - KEYVAL ( 0x0ad0 , "leftsinglequotemark" ); - KEYVAL ( 0x0ad1 , "rightsinglequotemark" ); - KEYVAL ( 0x0ad2 , "leftdoublequotemark" ); - KEYVAL ( 0x0ad3 , "rightdoublequotemark" ); - KEYVAL ( 0x0ad4 , "prescription" ); - KEYVAL ( 0x0ad6 , "minutes" ); - KEYVAL ( 0x0ad7 , "seconds" ); - KEYVAL ( 0x0ad9 , "latincross" ); - KEYVAL ( 0x0ada , "hexagram" ); - KEYVAL ( 0x0adb , "filledrectbullet" ); - KEYVAL ( 0x0adc , "filledlefttribullet" ); - KEYVAL ( 0x0add , "filledrighttribullet" ); - KEYVAL ( 0x0ade , "emfilledcircle" ); - KEYVAL ( 0x0adf , "emfilledrect" ); - KEYVAL ( 0x0ae0 , "enopencircbullet" ); - KEYVAL ( 0x0ae1 , "enopensquarebullet" ); - KEYVAL ( 0x0ae2 , "openrectbullet" ); - KEYVAL ( 0x0ae3 , "opentribulletup" ); - KEYVAL ( 0x0ae4 , "opentribulletdown" ); - KEYVAL ( 0x0ae5 , "openstar" ); - KEYVAL ( 0x0ae6 , "enfilledcircbullet" ); - KEYVAL ( 0x0ae7 , "enfilledsqbullet" ); - KEYVAL ( 0x0ae8 , "filledtribulletup" ); - KEYVAL ( 0x0ae9 , "filledtribulletdown" ); - KEYVAL ( 0x0aea , "leftpointer" ); - KEYVAL ( 0x0aeb , "rightpointer" ); - KEYVAL ( 0x0aec , "club" ); - KEYVAL ( 0x0aed , "diamond" ); - KEYVAL ( 0x0aee , "heart" ); - KEYVAL ( 0x0af0 , "maltesecross" ); - KEYVAL ( 0x0af1 , "dagger" ); - KEYVAL ( 0x0af2 , "doubledagger" ); - KEYVAL ( 0x0af3 , "checkmark" ); - KEYVAL ( 0x0af4 , "ballotcross" ); - KEYVAL ( 0x0af5 , "musicalsharp" ); - KEYVAL ( 0x0af6 , "musicalflat" ); - KEYVAL ( 0x0af7 , "malesymbol" ); - KEYVAL ( 0x0af8 , "femalesymbol" ); - KEYVAL ( 0x0af9 , "telephone" ); - KEYVAL ( 0x0afa , "telephonerecorder" ); - KEYVAL ( 0x0afb , "phonographcopyright" ); - KEYVAL ( 0x0afc , "caret" ); - KEYVAL ( 0x0afd , "singlelowquotemark" ); - KEYVAL ( 0x0afe , "doublelowquotemark" ); - KEYVAL ( 0x0aff , "cursor" ); - KEYVAL ( 0x0ba3 , "leftcaret" ); - KEYVAL ( 0x0ba6 , "rightcaret" ); - KEYVAL ( 0x0ba8 , "downcaret" ); - KEYVAL ( 0x0ba9 , "upcaret" ); - KEYVAL ( 0x0bc0 , "overbar" ); - KEYVAL ( 0x0bc2 , "downtack" ); - KEYVAL ( 0x0bc3 , "upshoe" ); - KEYVAL ( 0x0bc4 , "downstile" ); - KEYVAL ( 0x0bc6 , "underbar" ); - KEYVAL ( 0x0bca , "jot" ); - KEYVAL ( 0x0bcc , "quad" ); - KEYVAL ( 0x0bce , "uptack" ); - KEYVAL ( 0x0bcf , "circle" ); - KEYVAL ( 0x0bd3 , "upstile" ); - KEYVAL ( 0x0bd6 , "downshoe" ); - KEYVAL ( 0x0bd8 , "rightshoe" ); - KEYVAL ( 0x0bda , "leftshoe" ); - KEYVAL ( 0x0bdc , "lefttack" ); - KEYVAL ( 0x0bfc , "righttack" ); - KEYVAL ( 0x0cdf , "hebrew_doublelowline" ); - KEYVAL ( 0x0ce0 , "hebrew_aleph" ); - KEYVAL ( 0x0ce1 , "hebrew_bet" ); - KEYVAL ( 0x0ce1 , "hebrew_beth" ); - KEYVAL ( 0x0ce2 , "hebrew_gimel" ); - KEYVAL ( 0x0ce2 , "hebrew_gimmel" ); - KEYVAL ( 0x0ce3 , "hebrew_dalet" ); - KEYVAL ( 0x0ce3 , "hebrew_daleth" ); - KEYVAL ( 0x0ce4 , "hebrew_he" ); - KEYVAL ( 0x0ce5 , "hebrew_waw" ); - KEYVAL ( 0x0ce6 , "hebrew_zain" ); - KEYVAL ( 0x0ce6 , "hebrew_zayin" ); - KEYVAL ( 0x0ce7 , "hebrew_chet" ); - KEYVAL ( 0x0ce7 , "hebrew_het" ); - KEYVAL ( 0x0ce8 , "hebrew_tet" ); - KEYVAL ( 0x0ce8 , "hebrew_teth" ); - KEYVAL ( 0x0ce9 , "hebrew_yod" ); - KEYVAL ( 0x0cea , "hebrew_finalkaph" ); - KEYVAL ( 0x0ceb , "hebrew_kaph" ); - KEYVAL ( 0x0cec , "hebrew_lamed" ); - KEYVAL ( 0x0ced , "hebrew_finalmem" ); - KEYVAL ( 0x0cee , "hebrew_mem" ); - KEYVAL ( 0x0cef , "hebrew_finalnun" ); - KEYVAL ( 0x0cf0 , "hebrew_nun" ); - KEYVAL ( 0x0cf1 , "hebrew_samech" ); - KEYVAL ( 0x0cf1 , "hebrew_samekh" ); - KEYVAL ( 0x0cf2 , "hebrew_ayin" ); - KEYVAL ( 0x0cf3 , "hebrew_finalpe" ); - KEYVAL ( 0x0cf4 , "hebrew_pe" ); - KEYVAL ( 0x0cf5 , "hebrew_finalzade" ); - KEYVAL ( 0x0cf5 , "hebrew_finalzadi" ); - KEYVAL ( 0x0cf6 , "hebrew_zade" ); - KEYVAL ( 0x0cf6 , "hebrew_zadi" ); - KEYVAL ( 0x0cf7 , "hebrew_kuf" ); - KEYVAL ( 0x0cf7 , "hebrew_qoph" ); - KEYVAL ( 0x0cf8 , "hebrew_resh" ); - KEYVAL ( 0x0cf9 , "hebrew_shin" ); - KEYVAL ( 0x0cfa , "hebrew_taf" ); - KEYVAL ( 0x0cfa , "hebrew_taw" ); - KEYVAL ( 0x0da1 , "Thai_kokai" ); - KEYVAL ( 0x0da2 , "Thai_khokhai" ); - KEYVAL ( 0x0da3 , "Thai_khokhuat" ); - KEYVAL ( 0x0da4 , "Thai_khokhwai" ); - KEYVAL ( 0x0da5 , "Thai_khokhon" ); - KEYVAL ( 0x0da6 , "Thai_khorakhang" ); - KEYVAL ( 0x0da7 , "Thai_ngongu" ); - KEYVAL ( 0x0da8 , "Thai_chochan" ); - KEYVAL ( 0x0da9 , "Thai_choching" ); - KEYVAL ( 0x0daa , "Thai_chochang" ); - KEYVAL ( 0x0dab , "Thai_soso" ); - KEYVAL ( 0x0dac , "Thai_chochoe" ); - KEYVAL ( 0x0dad , "Thai_yoying" ); - KEYVAL ( 0x0dae , "Thai_dochada" ); - KEYVAL ( 0x0daf , "Thai_topatak" ); - KEYVAL ( 0x0db0 , "Thai_thothan" ); - KEYVAL ( 0x0db1 , "Thai_thonangmontho" ); - KEYVAL ( 0x0db2 , "Thai_thophuthao" ); - KEYVAL ( 0x0db3 , "Thai_nonen" ); - KEYVAL ( 0x0db4 , "Thai_dodek" ); - KEYVAL ( 0x0db5 , "Thai_totao" ); - KEYVAL ( 0x0db6 , "Thai_thothung" ); - KEYVAL ( 0x0db7 , "Thai_thothahan" ); - KEYVAL ( 0x0db8 , "Thai_thothong" ); - KEYVAL ( 0x0db9 , "Thai_nonu" ); - KEYVAL ( 0x0dba , "Thai_bobaimai" ); - KEYVAL ( 0x0dbb , "Thai_popla" ); - KEYVAL ( 0x0dbc , "Thai_phophung" ); - KEYVAL ( 0x0dbd , "Thai_fofa" ); - KEYVAL ( 0x0dbe , "Thai_phophan" ); - KEYVAL ( 0x0dbf , "Thai_fofan" ); - KEYVAL ( 0x0dc0 , "Thai_phosamphao" ); - KEYVAL ( 0x0dc1 , "Thai_moma" ); - KEYVAL ( 0x0dc2 , "Thai_yoyak" ); - KEYVAL ( 0x0dc3 , "Thai_rorua" ); - KEYVAL ( 0x0dc4 , "Thai_ru" ); - KEYVAL ( 0x0dc5 , "Thai_loling" ); - KEYVAL ( 0x0dc6 , "Thai_lu" ); - KEYVAL ( 0x0dc7 , "Thai_wowaen" ); - KEYVAL ( 0x0dc8 , "Thai_sosala" ); - KEYVAL ( 0x0dc9 , "Thai_sorusi" ); - KEYVAL ( 0x0dca , "Thai_sosua" ); - KEYVAL ( 0x0dcb , "Thai_hohip" ); - KEYVAL ( 0x0dcc , "Thai_lochula" ); - KEYVAL ( 0x0dcd , "Thai_oang" ); - KEYVAL ( 0x0dce , "Thai_honokhuk" ); - KEYVAL ( 0x0dcf , "Thai_paiyannoi" ); - KEYVAL ( 0x0dd0 , "Thai_saraa" ); - KEYVAL ( 0x0dd1 , "Thai_maihanakat" ); - KEYVAL ( 0x0dd2 , "Thai_saraaa" ); - KEYVAL ( 0x0dd3 , "Thai_saraam" ); - KEYVAL ( 0x0dd4 , "Thai_sarai" ); - KEYVAL ( 0x0dd5 , "Thai_saraii" ); - KEYVAL ( 0x0dd6 , "Thai_saraue" ); - KEYVAL ( 0x0dd7 , "Thai_sarauee" ); - KEYVAL ( 0x0dd8 , "Thai_sarau" ); - KEYVAL ( 0x0dd9 , "Thai_sarauu" ); - KEYVAL ( 0x0dda , "Thai_phinthu" ); - KEYVAL ( 0x0dde , "Thai_maihanakat_maitho" ); - KEYVAL ( 0x0ddf , "Thai_baht" ); - KEYVAL ( 0x0de0 , "Thai_sarae" ); - KEYVAL ( 0x0de1 , "Thai_saraae" ); - KEYVAL ( 0x0de2 , "Thai_sarao" ); - KEYVAL ( 0x0de3 , "Thai_saraaimaimuan" ); - KEYVAL ( 0x0de4 , "Thai_saraaimaimalai" ); - KEYVAL ( 0x0de5 , "Thai_lakkhangyao" ); - KEYVAL ( 0x0de6 , "Thai_maiyamok" ); - KEYVAL ( 0x0de7 , "Thai_maitaikhu" ); - KEYVAL ( 0x0de8 , "Thai_maiek" ); - KEYVAL ( 0x0de9 , "Thai_maitho" ); - KEYVAL ( 0x0dea , "Thai_maitri" ); - KEYVAL ( 0x0deb , "Thai_maichattawa" ); - KEYVAL ( 0x0dec , "Thai_thanthakhat" ); - KEYVAL ( 0x0ded , "Thai_nikhahit" ); - KEYVAL ( 0x0df0 , "Thai_leksun" ); - KEYVAL ( 0x0df1 , "Thai_leknung" ); - KEYVAL ( 0x0df2 , "Thai_leksong" ); - KEYVAL ( 0x0df3 , "Thai_leksam" ); - KEYVAL ( 0x0df4 , "Thai_leksi" ); - KEYVAL ( 0x0df5 , "Thai_lekha" ); - KEYVAL ( 0x0df6 , "Thai_lekhok" ); - KEYVAL ( 0x0df7 , "Thai_lekchet" ); - KEYVAL ( 0x0df8 , "Thai_lekpaet" ); - KEYVAL ( 0x0df9 , "Thai_lekkao" ); - KEYVAL ( 0x0ea1 , "Hangul_Kiyeog" ); - KEYVAL ( 0x0ea2 , "Hangul_SsangKiyeog" ); - KEYVAL ( 0x0ea3 , "Hangul_KiyeogSios" ); - KEYVAL ( 0x0ea4 , "Hangul_Nieun" ); - KEYVAL ( 0x0ea5 , "Hangul_NieunJieuj" ); - KEYVAL ( 0x0ea6 , "Hangul_NieunHieuh" ); - KEYVAL ( 0x0ea7 , "Hangul_Dikeud" ); - KEYVAL ( 0x0ea8 , "Hangul_SsangDikeud" ); - KEYVAL ( 0x0ea9 , "Hangul_Rieul" ); - KEYVAL ( 0x0eaa , "Hangul_RieulKiyeog" ); - KEYVAL ( 0x0eab , "Hangul_RieulMieum" ); - KEYVAL ( 0x0eac , "Hangul_RieulPieub" ); - KEYVAL ( 0x0ead , "Hangul_RieulSios" ); - KEYVAL ( 0x0eae , "Hangul_RieulTieut" ); - KEYVAL ( 0x0eaf , "Hangul_RieulPhieuf" ); - KEYVAL ( 0x0eb0 , "Hangul_RieulHieuh" ); - KEYVAL ( 0x0eb1 , "Hangul_Mieum" ); - KEYVAL ( 0x0eb2 , "Hangul_Pieub" ); - KEYVAL ( 0x0eb3 , "Hangul_SsangPieub" ); - KEYVAL ( 0x0eb4 , "Hangul_PieubSios" ); - KEYVAL ( 0x0eb5 , "Hangul_Sios" ); - KEYVAL ( 0x0eb6 , "Hangul_SsangSios" ); - KEYVAL ( 0x0eb7 , "Hangul_Ieung" ); - KEYVAL ( 0x0eb8 , "Hangul_Jieuj" ); - KEYVAL ( 0x0eb9 , "Hangul_SsangJieuj" ); - KEYVAL ( 0x0eba , "Hangul_Cieuc" ); - KEYVAL ( 0x0ebb , "Hangul_Khieuq" ); - KEYVAL ( 0x0ebc , "Hangul_Tieut" ); - KEYVAL ( 0x0ebd , "Hangul_Phieuf" ); - KEYVAL ( 0x0ebe , "Hangul_Hieuh" ); - KEYVAL ( 0x0ebf , "Hangul_A" ); - KEYVAL ( 0x0ec0 , "Hangul_AE" ); - KEYVAL ( 0x0ec1 , "Hangul_YA" ); - KEYVAL ( 0x0ec2 , "Hangul_YAE" ); - KEYVAL ( 0x0ec3 , "Hangul_EO" ); - KEYVAL ( 0x0ec4 , "Hangul_E" ); - KEYVAL ( 0x0ec5 , "Hangul_YEO" ); - KEYVAL ( 0x0ec6 , "Hangul_YE" ); - KEYVAL ( 0x0ec7 , "Hangul_O" ); - KEYVAL ( 0x0ec8 , "Hangul_WA" ); - KEYVAL ( 0x0ec9 , "Hangul_WAE" ); - KEYVAL ( 0x0eca , "Hangul_OE" ); - KEYVAL ( 0x0ecb , "Hangul_YO" ); - KEYVAL ( 0x0ecc , "Hangul_U" ); - KEYVAL ( 0x0ecd , "Hangul_WEO" ); - KEYVAL ( 0x0ece , "Hangul_WE" ); - KEYVAL ( 0x0ecf , "Hangul_WI" ); - KEYVAL ( 0x0ed0 , "Hangul_YU" ); - KEYVAL ( 0x0ed1 , "Hangul_EU" ); - KEYVAL ( 0x0ed2 , "Hangul_YI" ); - KEYVAL ( 0x0ed3 , "Hangul_I" ); - KEYVAL ( 0x0ed4 , "Hangul_J_Kiyeog" ); - KEYVAL ( 0x0ed5 , "Hangul_J_SsangKiyeog" ); - KEYVAL ( 0x0ed6 , "Hangul_J_KiyeogSios" ); - KEYVAL ( 0x0ed7 , "Hangul_J_Nieun" ); - KEYVAL ( 0x0ed8 , "Hangul_J_NieunJieuj" ); - KEYVAL ( 0x0ed9 , "Hangul_J_NieunHieuh" ); - KEYVAL ( 0x0eda , "Hangul_J_Dikeud" ); - KEYVAL ( 0x0edb , "Hangul_J_Rieul" ); - KEYVAL ( 0x0edc , "Hangul_J_RieulKiyeog" ); - KEYVAL ( 0x0edd , "Hangul_J_RieulMieum" ); - KEYVAL ( 0x0ede , "Hangul_J_RieulPieub" ); - KEYVAL ( 0x0edf , "Hangul_J_RieulSios" ); - KEYVAL ( 0x0ee0 , "Hangul_J_RieulTieut" ); - KEYVAL ( 0x0ee1 , "Hangul_J_RieulPhieuf" ); - KEYVAL ( 0x0ee2 , "Hangul_J_RieulHieuh" ); - KEYVAL ( 0x0ee3 , "Hangul_J_Mieum" ); - KEYVAL ( 0x0ee4 , "Hangul_J_Pieub" ); - KEYVAL ( 0x0ee5 , "Hangul_J_PieubSios" ); - KEYVAL ( 0x0ee6 , "Hangul_J_Sios" ); - KEYVAL ( 0x0ee7 , "Hangul_J_SsangSios" ); - KEYVAL ( 0x0ee8 , "Hangul_J_Ieung" ); - KEYVAL ( 0x0ee9 , "Hangul_J_Jieuj" ); - KEYVAL ( 0x0eea , "Hangul_J_Cieuc" ); - KEYVAL ( 0x0eeb , "Hangul_J_Khieuq" ); - KEYVAL ( 0x0eec , "Hangul_J_Tieut" ); - KEYVAL ( 0x0eed , "Hangul_J_Phieuf" ); - KEYVAL ( 0x0eee , "Hangul_J_Hieuh" ); - KEYVAL ( 0x0eef , "Hangul_RieulYeorinHieuh" ); - KEYVAL ( 0x0ef0 , "Hangul_SunkyeongeumMieum" ); - KEYVAL ( 0x0ef1 , "Hangul_SunkyeongeumPieub" ); - KEYVAL ( 0x0ef2 , "Hangul_PanSios" ); - KEYVAL ( 0x0ef3 , "Hangul_KkogjiDalrinIeung" ); - KEYVAL ( 0x0ef4 , "Hangul_SunkyeongeumPhieuf" ); - KEYVAL ( 0x0ef5 , "Hangul_YeorinHieuh" ); - KEYVAL ( 0x0ef6 , "Hangul_AraeA" ); - KEYVAL ( 0x0ef7 , "Hangul_AraeAE" ); - KEYVAL ( 0x0ef8 , "Hangul_J_PanSios" ); - KEYVAL ( 0x0ef9 , "Hangul_J_KkogjiDalrinIeung" ); - KEYVAL ( 0x0efa , "Hangul_J_YeorinHieuh" ); - KEYVAL ( 0x0eff , "Korean_Won" ); - KEYVAL ( 0x13bc , "OE" ); - KEYVAL ( 0x13bd , "oe" ); - KEYVAL ( 0x13be , "Ydiaeresis" ); - KEYVAL ( 0x20a0 , "EcuSign" ); - KEYVAL ( 0x20a1 , "ColonSign" ); - KEYVAL ( 0x20a2 , "CruzeiroSign" ); - KEYVAL ( 0x20a3 , "FFrancSign" ); - KEYVAL ( 0x20a4 , "LiraSign" ); - KEYVAL ( 0x20a5 , "MillSign" ); - KEYVAL ( 0x20a6 , "NairaSign" ); - KEYVAL ( 0x20a7 , "PesetaSign" ); - KEYVAL ( 0x20a8 , "RupeeSign" ); - KEYVAL ( 0x20a9 , "WonSign" ); - KEYVAL ( 0x20aa , "NewSheqelSign" ); - KEYVAL ( 0x20ab , "DongSign" ); - KEYVAL ( 0x20ac , "EuroSign" ); - KEYVAL ( 0xFD01 , "3270_Duplicate" ); - KEYVAL ( 0xFD02 , "3270_FieldMark" ); - KEYVAL ( 0xFD03 , "3270_Right2" ); - KEYVAL ( 0xFD04 , "3270_Left2" ); - KEYVAL ( 0xFD05 , "3270_BackTab" ); - KEYVAL ( 0xFD06 , "3270_EraseEOF" ); - KEYVAL ( 0xFD07 , "3270_EraseInput" ); - KEYVAL ( 0xFD08 , "3270_Reset" ); - KEYVAL ( 0xFD09 , "3270_Quit" ); - KEYVAL ( 0xFD0A , "3270_PA1" ); - KEYVAL ( 0xFD0B , "3270_PA2" ); - KEYVAL ( 0xFD0C , "3270_PA3" ); - KEYVAL ( 0xFD0D , "3270_Test" ); - KEYVAL ( 0xFD0E , "3270_Attn" ); - KEYVAL ( 0xFD0F , "3270_CursorBlink" ); - KEYVAL ( 0xFD10 , "3270_AltCursor" ); - KEYVAL ( 0xFD11 , "3270_KeyClick" ); - KEYVAL ( 0xFD12 , "3270_Jump" ); - KEYVAL ( 0xFD13 , "3270_Ident" ); - KEYVAL ( 0xFD14 , "3270_Rule" ); - KEYVAL ( 0xFD15 , "3270_Copy" ); - KEYVAL ( 0xFD16 , "3270_Play" ); - KEYVAL ( 0xFD17 , "3270_Setup" ); - KEYVAL ( 0xFD18 , "3270_Record" ); - KEYVAL ( 0xFD19 , "3270_ChangeScreen" ); - KEYVAL ( 0xFD1A , "3270_DeleteWord" ); - KEYVAL ( 0xFD1B , "3270_ExSelect" ); - KEYVAL ( 0xFD1C , "3270_CursorSelect" ); - KEYVAL ( 0xFD1D , "3270_PrintScreen" ); - KEYVAL ( 0xFD1E , "3270_Enter" ); - KEYVAL ( 0xFE01 , "ISO_Lock" ); - KEYVAL ( 0xFE02 , "ISO_Level2_Latch" ); - KEYVAL ( 0xFE03 , "ISO_Level3_Shift" ); - KEYVAL ( 0xFE04 , "ISO_Level3_Latch" ); - KEYVAL ( 0xFE05 , "ISO_Level3_Lock" ); - KEYVAL ( 0xFE06 , "ISO_Group_Latch" ); - KEYVAL ( 0xFE07 , "ISO_Group_Lock" ); - KEYVAL ( 0xFE08 , "ISO_Next_Group" ); - KEYVAL ( 0xFE09 , "ISO_Next_Group_Lock" ); - KEYVAL ( 0xFE0A , "ISO_Prev_Group" ); - KEYVAL ( 0xFE0B , "ISO_Prev_Group_Lock" ); - KEYVAL ( 0xFE0C , "ISO_First_Group" ); - KEYVAL ( 0xFE0D , "ISO_First_Group_Lock" ); - KEYVAL ( 0xFE0E , "ISO_Last_Group" ); - KEYVAL ( 0xFE0F , "ISO_Last_Group_Lock" ); - KEYVAL ( 0xFE20 , "ISO_Left_Tab" ); - KEYVAL ( 0xFE21 , "ISO_Move_Line_Up" ); - KEYVAL ( 0xFE22 , "ISO_Move_Line_Down" ); - KEYVAL ( 0xFE23 , "ISO_Partial_Line_Up" ); - KEYVAL ( 0xFE24 , "ISO_Partial_Line_Down" ); - KEYVAL ( 0xFE25 , "ISO_Partial_Space_Left" ); - KEYVAL ( 0xFE26 , "ISO_Partial_Space_Right" ); - KEYVAL ( 0xFE27 , "ISO_Set_Margin_Left" ); - KEYVAL ( 0xFE28 , "ISO_Set_Margin_Right" ); - KEYVAL ( 0xFE29 , "ISO_Release_Margin_Left" ); - KEYVAL ( 0xFE2A , "ISO_Release_Margin_Right" ); - KEYVAL ( 0xFE2B , "ISO_Release_Both_Margins" ); - KEYVAL ( 0xFE2C , "ISO_Fast_Cursor_Left" ); - KEYVAL ( 0xFE2D , "ISO_Fast_Cursor_Right" ); - KEYVAL ( 0xFE2E , "ISO_Fast_Cursor_Up" ); - KEYVAL ( 0xFE2F , "ISO_Fast_Cursor_Down" ); - KEYVAL ( 0xFE30 , "ISO_Continuous_Underline" ); - KEYVAL ( 0xFE31 , "ISO_Discontinuous_Underline" ); - KEYVAL ( 0xFE32 , "ISO_Emphasize" ); - KEYVAL ( 0xFE33 , "ISO_Center_Object" ); - KEYVAL ( 0xFE34 , "ISO_Enter" ); - KEYVAL ( 0xFE50 , "dead_grave" ); - KEYVAL ( 0xFE51 , "dead_acute" ); - KEYVAL ( 0xFE52 , "dead_circumflex" ); - KEYVAL ( 0xFE53 , "dead_tilde" ); - KEYVAL ( 0xFE54 , "dead_macron" ); - KEYVAL ( 0xFE55 , "dead_breve" ); - KEYVAL ( 0xFE56 , "dead_abovedot" ); - KEYVAL ( 0xFE57 , "dead_diaeresis" ); - KEYVAL ( 0xFE58 , "dead_abovering" ); - KEYVAL ( 0xFE59 , "dead_doubleacute" ); - KEYVAL ( 0xFE5A , "dead_caron" ); - KEYVAL ( 0xFE5B , "dead_cedilla" ); - KEYVAL ( 0xFE5C , "dead_ogonek" ); - KEYVAL ( 0xFE5D , "dead_iota" ); - KEYVAL ( 0xFE5E , "dead_voiced_sound" ); - KEYVAL ( 0xFE5F , "dead_semivoiced_sound" ); - KEYVAL ( 0xFE60 , "dead_belowdot" ); - KEYVAL ( 0xFE61 , "dead_hook" ); - KEYVAL ( 0xFE62 , "dead_horn" ); - KEYVAL ( 0xFE70 , "AccessX_Enable" ); - KEYVAL ( 0xFE71 , "AccessX_Feedback_Enable" ); - KEYVAL ( 0xFE72 , "RepeatKeys_Enable" ); - KEYVAL ( 0xFE73 , "SlowKeys_Enable" ); - KEYVAL ( 0xFE74 , "BounceKeys_Enable" ); - KEYVAL ( 0xFE75 , "StickyKeys_Enable" ); - KEYVAL ( 0xFE76 , "MouseKeys_Enable" ); - KEYVAL ( 0xFE77 , "MouseKeys_Accel_Enable" ); - KEYVAL ( 0xFE78 , "Overlay1_Enable" ); - KEYVAL ( 0xFE79 , "Overlay2_Enable" ); - KEYVAL ( 0xFE7A , "AudibleBell_Enable" ); - KEYVAL ( 0xFED0 , "First_Virtual_Screen" ); - KEYVAL ( 0xFED1 , "Prev_Virtual_Screen" ); - KEYVAL ( 0xFED2 , "Next_Virtual_Screen" ); - KEYVAL ( 0xFED4 , "Last_Virtual_Screen" ); - KEYVAL ( 0xFED5 , "Terminate_Server" ); - KEYVAL ( 0xFEE0 , "Pointer_Left" ); - KEYVAL ( 0xFEE1 , "Pointer_Right" ); - KEYVAL ( 0xFEE2 , "Pointer_Up" ); - KEYVAL ( 0xFEE3 , "Pointer_Down" ); - KEYVAL ( 0xFEE4 , "Pointer_UpLeft" ); - KEYVAL ( 0xFEE5 , "Pointer_UpRight" ); - KEYVAL ( 0xFEE6 , "Pointer_DownLeft" ); - KEYVAL ( 0xFEE7 , "Pointer_DownRight" ); - KEYVAL ( 0xFEE8 , "Pointer_Button_Dflt" ); - KEYVAL ( 0xFEE9 , "Pointer_Button1" ); - KEYVAL ( 0xFEEA , "Pointer_Button2" ); - KEYVAL ( 0xFEEB , "Pointer_Button3" ); - KEYVAL ( 0xFEEC , "Pointer_Button4" ); - KEYVAL ( 0xFEED , "Pointer_Button5" ); - KEYVAL ( 0xFEEE , "Pointer_DblClick_Dflt" ); - KEYVAL ( 0xFEEF , "Pointer_DblClick1" ); - KEYVAL ( 0xFEF0 , "Pointer_DblClick2" ); - KEYVAL ( 0xFEF1 , "Pointer_DblClick3" ); - KEYVAL ( 0xFEF2 , "Pointer_DblClick4" ); - KEYVAL ( 0xFEF3 , "Pointer_DblClick5" ); - KEYVAL ( 0xFEF4 , "Pointer_Drag_Dflt" ); - KEYVAL ( 0xFEF5 , "Pointer_Drag1" ); - KEYVAL ( 0xFEF6 , "Pointer_Drag2" ); - KEYVAL ( 0xFEF7 , "Pointer_Drag3" ); - KEYVAL ( 0xFEF8 , "Pointer_Drag4" ); - KEYVAL ( 0xFEF9 , "Pointer_EnableKeys" ); - KEYVAL ( 0xFEFA , "Pointer_Accelerate" ); - KEYVAL ( 0xFEFB , "Pointer_DfltBtnNext" ); - KEYVAL ( 0xFEFC , "Pointer_DfltBtnPrev" ); - KEYVAL ( 0xFEFD , "Pointer_Drag5" ); - KEYVAL ( 0xFF08 , "BackSpace" ); - KEYVAL ( 0xFF09 , "Tab" ); - KEYVAL ( 0xFF0A , "Linefeed" ); - KEYVAL ( 0xFF0B , "Clear" ); - KEYVAL ( 0xFF0D , "Return" ); - KEYVAL ( 0xFF13 , "Pause" ); - KEYVAL ( 0xFF14 , "Scroll_Lock" ); - KEYVAL ( 0xFF15 , "Sys_Req" ); - KEYVAL ( 0xFF1B , "Escape" ); - KEYVAL ( 0xFF20 , "Multi_key" ); - KEYVAL ( 0xFF21 , "Kanji" ); - KEYVAL ( 0xFF22 , "Muhenkan" ); - KEYVAL ( 0xFF23 , "Henkan" ); - KEYVAL ( 0xFF23 , "Henkan_Mode" ); - KEYVAL ( 0xFF24 , "Romaji" ); - KEYVAL ( 0xFF25 , "Hiragana" ); - KEYVAL ( 0xFF26 , "Katakana" ); - KEYVAL ( 0xFF27 , "Hiragana_Katakana" ); - KEYVAL ( 0xFF28 , "Zenkaku" ); - KEYVAL ( 0xFF29 , "Hankaku" ); - KEYVAL ( 0xFF2A , "Zenkaku_Hankaku" ); - KEYVAL ( 0xFF2B , "Touroku" ); - KEYVAL ( 0xFF2C , "Massyo" ); - KEYVAL ( 0xFF2D , "Kana_Lock" ); - KEYVAL ( 0xFF2E , "Kana_Shift" ); - KEYVAL ( 0xFF2F , "Eisu_Shift" ); - KEYVAL ( 0xFF30 , "Eisu_toggle" ); - KEYVAL ( 0xff31 , "Hangul" ); - KEYVAL ( 0xff32 , "Hangul_Start" ); - KEYVAL ( 0xff33 , "Hangul_End" ); - KEYVAL ( 0xff34 , "Hangul_Hanja" ); - KEYVAL ( 0xff35 , "Hangul_Jamo" ); - KEYVAL ( 0xff36 , "Hangul_Romaja" ); - KEYVAL ( 0xFF37 , "Codeinput" ); - KEYVAL ( 0xff37 , "Hangul_Codeinput" ); - KEYVAL ( 0xFF37 , "Kanji_Bangou" ); - KEYVAL ( 0xff38 , "Hangul_Jeonja" ); - KEYVAL ( 0xff39 , "Hangul_Banja" ); - KEYVAL ( 0xff3a , "Hangul_PreHanja" ); - KEYVAL ( 0xff3b , "Hangul_PostHanja" ); - KEYVAL ( 0xff3c , "Hangul_SingleCandidate" ); - KEYVAL ( 0xFF3C , "SingleCandidate" ); - KEYVAL ( 0xff3d , "Hangul_MultipleCandidate" ); - KEYVAL ( 0xFF3D , "MultipleCandidate" ); - KEYVAL ( 0xFF3D , "Zen_Koho" ); - KEYVAL ( 0xff3e , "Hangul_PreviousCandidate" ); - KEYVAL ( 0xFF3E , "Mae_Koho" ); - KEYVAL ( 0xFF3E , "PreviousCandidate" ); - KEYVAL ( 0xff3f , "Hangul_Special" ); - KEYVAL ( 0xFF50 , "Home" ); - KEYVAL ( 0xFF51 , "Left" ); - KEYVAL ( 0xFF52 , "Up" ); - KEYVAL ( 0xFF53 , "Right" ); - KEYVAL ( 0xFF54 , "Down" ); - KEYVAL ( 0xFF55 , "Page_Up" ); - KEYVAL ( 0xFF55 , "Prior" ); - KEYVAL ( 0xFF56 , "Next" ); - KEYVAL ( 0xFF56 , "Page_Down" ); - KEYVAL ( 0xFF57 , "End" ); - KEYVAL ( 0xFF58 , "Begin" ); - KEYVAL ( 0xFF60 , "Select" ); - KEYVAL ( 0xFF61 , "Print" ); - KEYVAL ( 0xFF62 , "Execute" ); - KEYVAL ( 0xFF63 , "Insert" ); - KEYVAL ( 0xFF65 , "Undo" ); - KEYVAL ( 0xFF66 , "Redo" ); - KEYVAL ( 0xFF67 , "Menu" ); - KEYVAL ( 0xFF68 , "Find" ); - KEYVAL ( 0xFF69 , "Cancel" ); - KEYVAL ( 0xFF6A , "Help" ); - KEYVAL ( 0xFF6B , "Break" ); - KEYVAL ( 0xFF7E , "Arabic_switch" ); - KEYVAL ( 0xFF7E , "Greek_switch" ); - KEYVAL ( 0xFF7E , "Hangul_switch" ); - KEYVAL ( 0xFF7E , "Hebrew_switch" ); - KEYVAL ( 0xFF7E , "ISO_Group_Shift" ); - KEYVAL ( 0xFF7E , "kana_switch" ); - KEYVAL ( 0xFF7E , "Mode_switch" ); - KEYVAL ( 0xFF7E , "script_switch" ); - KEYVAL ( 0xFF7F , "Num_Lock" ); - KEYVAL ( 0xFF80 , "KP_Space" ); - KEYVAL ( 0xFF89 , "KP_Tab" ); - KEYVAL ( 0xFF8D , "KP_Enter" ); - KEYVAL ( 0xFF91 , "KP_F1" ); - KEYVAL ( 0xFF92 , "KP_F2" ); - KEYVAL ( 0xFF93 , "KP_F3" ); - KEYVAL ( 0xFF94 , "KP_F4" ); - KEYVAL ( 0xFF95 , "KP_Home" ); - KEYVAL ( 0xFF96 , "KP_Left" ); - KEYVAL ( 0xFF97 , "KP_Up" ); - KEYVAL ( 0xFF98 , "KP_Right" ); - KEYVAL ( 0xFF99 , "KP_Down" ); - KEYVAL ( 0xFF9A , "KP_Page_Up" ); - KEYVAL ( 0xFF9A , "KP_Prior" ); - KEYVAL ( 0xFF9B , "KP_Next" ); - KEYVAL ( 0xFF9B , "KP_Page_Down" ); - KEYVAL ( 0xFF9C , "KP_End" ); - KEYVAL ( 0xFF9D , "KP_Begin" ); - KEYVAL ( 0xFF9E , "KP_Insert" ); - KEYVAL ( 0xFF9F , "KP_Delete" ); - KEYVAL ( 0xFFAA , "KP_Multiply" ); - KEYVAL ( 0xFFAB , "KP_Add" ); - KEYVAL ( 0xFFAC , "KP_Separator" ); - KEYVAL ( 0xFFAD , "KP_Subtract" ); - KEYVAL ( 0xFFAE , "KP_Decimal" ); - KEYVAL ( 0xFFAF , "KP_Divide" ); - KEYVAL ( 0xFFB0 , "KP_0" ); - KEYVAL ( 0xFFB1 , "KP_1" ); - KEYVAL ( 0xFFB2 , "KP_2" ); - KEYVAL ( 0xFFB3 , "KP_3" ); - KEYVAL ( 0xFFB4 , "KP_4" ); - KEYVAL ( 0xFFB5 , "KP_5" ); - KEYVAL ( 0xFFB6 , "KP_6" ); - KEYVAL ( 0xFFB7 , "KP_7" ); - KEYVAL ( 0xFFB8 , "KP_8" ); - KEYVAL ( 0xFFB9 , "KP_9" ); - KEYVAL ( 0xFFBD , "KP_Equal" ); - KEYVAL ( 0xFFBE , "F1" ); - KEYVAL ( 0xFFBF , "F2" ); - KEYVAL ( 0xFFC0 , "F3" ); - KEYVAL ( 0xFFC1 , "F4" ); - KEYVAL ( 0xFFC2 , "F5" ); - KEYVAL ( 0xFFC3 , "F6" ); - KEYVAL ( 0xFFC4 , "F7" ); - KEYVAL ( 0xFFC5 , "F8" ); - KEYVAL ( 0xFFC6 , "F9" ); - KEYVAL ( 0xFFC7 , "F10" ); - KEYVAL ( 0xFFC8 , "F11" ); - KEYVAL ( 0xFFC8 , "L1" ); - KEYVAL ( 0xFFC9 , "F12" ); - KEYVAL ( 0xFFC9 , "L2" ); - KEYVAL ( 0xFFCA , "F13" ); - KEYVAL ( 0xFFCA , "L3" ); - KEYVAL ( 0xFFCB , "F14" ); - KEYVAL ( 0xFFCB , "L4" ); - KEYVAL ( 0xFFCC , "F15" ); - KEYVAL ( 0xFFCC , "L5" ); - KEYVAL ( 0xFFCD , "F16" ); - KEYVAL ( 0xFFCD , "L6" ); - KEYVAL ( 0xFFCE , "F17" ); - KEYVAL ( 0xFFCE , "L7" ); - KEYVAL ( 0xFFCF , "F18" ); - KEYVAL ( 0xFFCF , "L8" ); - KEYVAL ( 0xFFD0 , "F19" ); - KEYVAL ( 0xFFD0 , "L9" ); - KEYVAL ( 0xFFD1 , "F20" ); - KEYVAL ( 0xFFD1 , "L10" ); - KEYVAL ( 0xFFD2 , "F21" ); - KEYVAL ( 0xFFD2 , "R1" ); - KEYVAL ( 0xFFD3 , "F22" ); - KEYVAL ( 0xFFD3 , "R2" ); - KEYVAL ( 0xFFD4 , "F23" ); - KEYVAL ( 0xFFD4 , "R3" ); - KEYVAL ( 0xFFD5 , "F24" ); - KEYVAL ( 0xFFD5 , "R4" ); - KEYVAL ( 0xFFD6 , "F25" ); - KEYVAL ( 0xFFD6 , "R5" ); - KEYVAL ( 0xFFD7 , "F26" ); - KEYVAL ( 0xFFD7 , "R6" ); - KEYVAL ( 0xFFD8 , "F27" ); - KEYVAL ( 0xFFD8 , "R7" ); - KEYVAL ( 0xFFD9 , "F28" ); - KEYVAL ( 0xFFD9 , "R8" ); - KEYVAL ( 0xFFDA , "F29" ); - KEYVAL ( 0xFFDA , "R9" ); - KEYVAL ( 0xFFDB , "F30" ); - KEYVAL ( 0xFFDB , "R10" ); - KEYVAL ( 0xFFDC , "F31" ); - KEYVAL ( 0xFFDC , "R11" ); - KEYVAL ( 0xFFDD , "F32" ); - KEYVAL ( 0xFFDD , "R12" ); - KEYVAL ( 0xFFDE , "F33" ); - KEYVAL ( 0xFFDE , "R13" ); - KEYVAL ( 0xFFDF , "F34" ); - KEYVAL ( 0xFFDF , "R14" ); - KEYVAL ( 0xFFE0 , "F35" ); - KEYVAL ( 0xFFE0 , "R15" ); - KEYVAL ( 0xFFE1 , "Shift_L" ); - KEYVAL ( 0xFFE2 , "Shift_R" ); - KEYVAL ( 0xFFE3 , "Control_L" ); - KEYVAL ( 0xFFE4 , "Control_R" ); - KEYVAL ( 0xFFE5 , "Caps_Lock" ); - KEYVAL ( 0xFFE6 , "Shift_Lock" ); - KEYVAL ( 0xFFE7 , "Meta_L" ); - KEYVAL ( 0xFFE8 , "Meta_R" ); - KEYVAL ( 0xFFE9 , "Alt_L" ); - KEYVAL ( 0xFFEA , "Alt_R" ); - KEYVAL ( 0xFFEB , "Super_L" ); - KEYVAL ( 0xFFEC , "Super_R" ); - KEYVAL ( 0xFFED , "Hyper_L" ); - KEYVAL ( 0xFFEE , "Hyper_R" ); - KEYVAL ( 0xFFFF , "Delete" ); - -/* 0xFFFFFF "VoidSymbol" */ -} +/* keyval_names.cpp - this file is part of DeSmuME + * + * Copyright (C) 2007 Damien Nozay (damdoum) + * Author: damdoum at users.sourceforge.net + * + * This file is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2, or (at your option) + * any later version. + * + * This file is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; see the file COPYING. If not, write to + * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#include "keyval_names.h" +/* see */ + +const char * unknown="(unknown)"; +const char * KEYVAL_NAMES[0x10000]; + +const char * KEYNAME(int k) { + const char * s = unknown; + s = KEYVAL_NAMES[k & 0xFFFF]; + return s; +} + +static void KEYVAL(int k, const char * name) { + if (KEYVAL_NAMES[k] == unknown) + KEYVAL_NAMES[k] = name; +} + +void init_keyvals() { + int i; + for (i=0; i<0x10000; i++) + KEYVAL_NAMES[i]=unknown; + + KEYVAL ( 0x0020 , "space" ); + KEYVAL ( 0x0021 , "exclam" ); + KEYVAL ( 0x0022 , "quotedbl" ); + KEYVAL ( 0x0023 , "numbersign" ); + KEYVAL ( 0x0024 , "dollar" ); + KEYVAL ( 0x0025 , "percent" ); + KEYVAL ( 0x0026 , "ampersand" ); + KEYVAL ( 0x0027 , "apostrophe" ); + KEYVAL ( 0x0027 , "quoteright" ); + KEYVAL ( 0x0028 , "parenleft" ); + KEYVAL ( 0x0029 , "parenright" ); + KEYVAL ( 0x002a , "asterisk" ); + KEYVAL ( 0x002b , "plus" ); + KEYVAL ( 0x002c , "comma" ); + KEYVAL ( 0x002d , "minus" ); + KEYVAL ( 0x002e , "period" ); + KEYVAL ( 0x002f , "slash" ); + KEYVAL ( 0x0030 , "0" ); + KEYVAL ( 0x0031 , "1" ); + KEYVAL ( 0x0032 , "2" ); + KEYVAL ( 0x0033 , "3" ); + KEYVAL ( 0x0034 , "4" ); + KEYVAL ( 0x0035 , "5" ); + KEYVAL ( 0x0036 , "6" ); + KEYVAL ( 0x0037 , "7" ); + KEYVAL ( 0x0038 , "8" ); + KEYVAL ( 0x0039 , "9" ); + KEYVAL ( 0x003a , "colon" ); + KEYVAL ( 0x003b , "semicolon" ); + KEYVAL ( 0x003c , "less" ); + KEYVAL ( 0x003d , "equal" ); + KEYVAL ( 0x003e , "greater" ); + KEYVAL ( 0x003f , "question" ); + KEYVAL ( 0x0040 , "at" ); + KEYVAL ( 0x0041 , "A" ); + KEYVAL ( 0x0042 , "B" ); + KEYVAL ( 0x0043 , "C" ); + KEYVAL ( 0x0044 , "D" ); + KEYVAL ( 0x0045 , "E" ); + KEYVAL ( 0x0046 , "F" ); + KEYVAL ( 0x0047 , "G" ); + KEYVAL ( 0x0048 , "H" ); + KEYVAL ( 0x0049 , "I" ); + KEYVAL ( 0x004a , "J" ); + KEYVAL ( 0x004b , "K" ); + KEYVAL ( 0x004c , "L" ); + KEYVAL ( 0x004d , "M" ); + KEYVAL ( 0x004e , "N" ); + KEYVAL ( 0x004f , "O" ); + KEYVAL ( 0x0050 , "P" ); + KEYVAL ( 0x0051 , "Q" ); + KEYVAL ( 0x0052 , "R" ); + KEYVAL ( 0x0053 , "S" ); + KEYVAL ( 0x0054 , "T" ); + KEYVAL ( 0x0055 , "U" ); + KEYVAL ( 0x0056 , "V" ); + KEYVAL ( 0x0057 , "W" ); + KEYVAL ( 0x0058 , "X" ); + KEYVAL ( 0x0059 , "Y" ); + KEYVAL ( 0x005a , "Z" ); + KEYVAL ( 0x005b , "bracketleft" ); + KEYVAL ( 0x005c , "backslash" ); + KEYVAL ( 0x005d , "bracketright" ); + KEYVAL ( 0x005e , "asciicircum" ); + KEYVAL ( 0x005f , "underscore" ); + KEYVAL ( 0x0060 , "grave" ); + KEYVAL ( 0x0060 , "quoteleft" ); + KEYVAL ( 0x0061 , "a" ); + KEYVAL ( 0x0062 , "b" ); + KEYVAL ( 0x0063 , "c" ); + KEYVAL ( 0x0064 , "d" ); + KEYVAL ( 0x0065 , "e" ); + KEYVAL ( 0x0066 , "f" ); + KEYVAL ( 0x0067 , "g" ); + KEYVAL ( 0x0068 , "h" ); + KEYVAL ( 0x0069 , "i" ); + KEYVAL ( 0x006a , "j" ); + KEYVAL ( 0x006b , "k" ); + KEYVAL ( 0x006c , "l" ); + KEYVAL ( 0x006d , "m" ); + KEYVAL ( 0x006e , "n" ); + KEYVAL ( 0x006f , "o" ); + KEYVAL ( 0x0070 , "p" ); + KEYVAL ( 0x0071 , "q" ); + KEYVAL ( 0x0072 , "r" ); + KEYVAL ( 0x0073 , "s" ); + KEYVAL ( 0x0074 , "t" ); + KEYVAL ( 0x0075 , "u" ); + KEYVAL ( 0x0076 , "v" ); + KEYVAL ( 0x0077 , "w" ); + KEYVAL ( 0x0078 , "x" ); + KEYVAL ( 0x0079 , "y" ); + KEYVAL ( 0x007a , "z" ); + KEYVAL ( 0x007b , "braceleft" ); + KEYVAL ( 0x007c , "bar" ); + KEYVAL ( 0x007d , "braceright" ); + KEYVAL ( 0x007e , "asciitilde" ); + KEYVAL ( 0x00a0 , "nobreakspace" ); + KEYVAL ( 0x00a1 , "exclamdown" ); + KEYVAL ( 0x00a2 , "cent" ); + KEYVAL ( 0x00a3 , "sterling" ); + KEYVAL ( 0x00a4 , "currency" ); + KEYVAL ( 0x00a5 , "yen" ); + KEYVAL ( 0x00a6 , "brokenbar" ); + KEYVAL ( 0x00a7 , "section" ); + KEYVAL ( 0x00a8 , "diaeresis" ); + KEYVAL ( 0x00a9 , "copyright" ); + KEYVAL ( 0x00aa , "ordfeminine" ); + KEYVAL ( 0x00ab , "guillemotleft" ); + KEYVAL ( 0x00ac , "notsign" ); + KEYVAL ( 0x00ad , "hyphen" ); + KEYVAL ( 0x00ae , "registered" ); + KEYVAL ( 0x00af , "macron" ); + KEYVAL ( 0x00b0 , "degree" ); + KEYVAL ( 0x00b1 , "plusminus" ); + KEYVAL ( 0x00b2 , "twosuperior" ); + KEYVAL ( 0x00b3 , "threesuperior" ); + KEYVAL ( 0x00b4 , "acute" ); + KEYVAL ( 0x00b5 , "mu" ); + KEYVAL ( 0x00b6 , "paragraph" ); + KEYVAL ( 0x00b7 , "periodcentered" ); + KEYVAL ( 0x00b8 , "cedilla" ); + KEYVAL ( 0x00b9 , "onesuperior" ); + KEYVAL ( 0x00ba , "masculine" ); + KEYVAL ( 0x00bb , "guillemotright" ); + KEYVAL ( 0x00bc , "onequarter" ); + KEYVAL ( 0x00bd , "onehalf" ); + KEYVAL ( 0x00be , "threequarters" ); + KEYVAL ( 0x00bf , "questiondown" ); + KEYVAL ( 0x00c0 , "Agrave" ); + KEYVAL ( 0x00c1 , "Aacute" ); + KEYVAL ( 0x00c2 , "Acircumflex" ); + KEYVAL ( 0x00c3 , "Atilde" ); + KEYVAL ( 0x00c4 , "Adiaeresis" ); + KEYVAL ( 0x00c5 , "Aring" ); + KEYVAL ( 0x00c6 , "AE" ); + KEYVAL ( 0x00c7 , "Ccedilla" ); + KEYVAL ( 0x00c8 , "Egrave" ); + KEYVAL ( 0x00c9 , "Eacute" ); + KEYVAL ( 0x00ca , "Ecircumflex" ); + KEYVAL ( 0x00cb , "Ediaeresis" ); + KEYVAL ( 0x00cc , "Igrave" ); + KEYVAL ( 0x00cd , "Iacute" ); + KEYVAL ( 0x00ce , "Icircumflex" ); + KEYVAL ( 0x00cf , "Idiaeresis" ); + KEYVAL ( 0x00d0 , "ETH" ); + KEYVAL ( 0x00d0 , "Eth" ); + KEYVAL ( 0x00d1 , "Ntilde" ); + KEYVAL ( 0x00d2 , "Ograve" ); + KEYVAL ( 0x00d3 , "Oacute" ); + KEYVAL ( 0x00d4 , "Ocircumflex" ); + KEYVAL ( 0x00d5 , "Otilde" ); + KEYVAL ( 0x00d6 , "Odiaeresis" ); + KEYVAL ( 0x00d7 , "multiply" ); + KEYVAL ( 0x00d8 , "Ooblique" ); + KEYVAL ( 0x00d9 , "Ugrave" ); + KEYVAL ( 0x00da , "Uacute" ); + KEYVAL ( 0x00db , "Ucircumflex" ); + KEYVAL ( 0x00dc , "Udiaeresis" ); + KEYVAL ( 0x00dd , "Yacute" ); + KEYVAL ( 0x00de , "THORN" ); + KEYVAL ( 0x00de , "Thorn" ); + KEYVAL ( 0x00df , "ssharp" ); + KEYVAL ( 0x00e0 , "agrave" ); + KEYVAL ( 0x00e1 , "aacute" ); + KEYVAL ( 0x00e2 , "acircumflex" ); + KEYVAL ( 0x00e3 , "atilde" ); + KEYVAL ( 0x00e4 , "adiaeresis" ); + KEYVAL ( 0x00e5 , "aring" ); + KEYVAL ( 0x00e6 , "ae" ); + KEYVAL ( 0x00e7 , "ccedilla" ); + KEYVAL ( 0x00e8 , "egrave" ); + KEYVAL ( 0x00e9 , "eacute" ); + KEYVAL ( 0x00ea , "ecircumflex" ); + KEYVAL ( 0x00eb , "ediaeresis" ); + KEYVAL ( 0x00ec , "igrave" ); + KEYVAL ( 0x00ed , "iacute" ); + KEYVAL ( 0x00ee , "icircumflex" ); + KEYVAL ( 0x00ef , "idiaeresis" ); + KEYVAL ( 0x00f0 , "eth" ); + KEYVAL ( 0x00f1 , "ntilde" ); + KEYVAL ( 0x00f2 , "ograve" ); + KEYVAL ( 0x00f3 , "oacute" ); + KEYVAL ( 0x00f4 , "ocircumflex" ); + KEYVAL ( 0x00f5 , "otilde" ); + KEYVAL ( 0x00f6 , "odiaeresis" ); + KEYVAL ( 0x00f7 , "division" ); + KEYVAL ( 0x00f8 , "oslash" ); + KEYVAL ( 0x00f9 , "ugrave" ); + KEYVAL ( 0x00fa , "uacute" ); + KEYVAL ( 0x00fb , "ucircumflex" ); + KEYVAL ( 0x00fc , "udiaeresis" ); + KEYVAL ( 0x00fd , "yacute" ); + KEYVAL ( 0x00fe , "thorn" ); + KEYVAL ( 0x00ff , "ydiaeresis" ); + KEYVAL ( 0x01a1 , "Aogonek" ); + KEYVAL ( 0x01a2 , "breve" ); + KEYVAL ( 0x01a3 , "Lstroke" ); + KEYVAL ( 0x01a5 , "Lcaron" ); + KEYVAL ( 0x01a6 , "Sacute" ); + KEYVAL ( 0x01a9 , "Scaron" ); + KEYVAL ( 0x01aa , "Scedilla" ); + KEYVAL ( 0x01ab , "Tcaron" ); + KEYVAL ( 0x01ac , "Zacute" ); + KEYVAL ( 0x01ae , "Zcaron" ); + KEYVAL ( 0x01af , "Zabovedot" ); + KEYVAL ( 0x01b1 , "aogonek" ); + KEYVAL ( 0x01b2 , "ogonek" ); + KEYVAL ( 0x01b3 , "lstroke" ); + KEYVAL ( 0x01b5 , "lcaron" ); + KEYVAL ( 0x01b6 , "sacute" ); + KEYVAL ( 0x01b7 , "caron" ); + KEYVAL ( 0x01b9 , "scaron" ); + KEYVAL ( 0x01ba , "scedilla" ); + KEYVAL ( 0x01bb , "tcaron" ); + KEYVAL ( 0x01bc , "zacute" ); + KEYVAL ( 0x01bd , "doubleacute" ); + KEYVAL ( 0x01be , "zcaron" ); + KEYVAL ( 0x01bf , "zabovedot" ); + KEYVAL ( 0x01c0 , "Racute" ); + KEYVAL ( 0x01c3 , "Abreve" ); + KEYVAL ( 0x01c5 , "Lacute" ); + KEYVAL ( 0x01c6 , "Cacute" ); + KEYVAL ( 0x01c8 , "Ccaron" ); + KEYVAL ( 0x01ca , "Eogonek" ); + KEYVAL ( 0x01cc , "Ecaron" ); + KEYVAL ( 0x01cf , "Dcaron" ); + KEYVAL ( 0x01d0 , "Dstroke" ); + KEYVAL ( 0x01d1 , "Nacute" ); + KEYVAL ( 0x01d2 , "Ncaron" ); + KEYVAL ( 0x01d5 , "Odoubleacute" ); + KEYVAL ( 0x01d8 , "Rcaron" ); + KEYVAL ( 0x01d9 , "Uring" ); + KEYVAL ( 0x01db , "Udoubleacute" ); + KEYVAL ( 0x01de , "Tcedilla" ); + KEYVAL ( 0x01e0 , "racute" ); + KEYVAL ( 0x01e3 , "abreve" ); + KEYVAL ( 0x01e5 , "lacute" ); + KEYVAL ( 0x01e6 , "cacute" ); + KEYVAL ( 0x01e8 , "ccaron" ); + KEYVAL ( 0x01ea , "eogonek" ); + KEYVAL ( 0x01ec , "ecaron" ); + KEYVAL ( 0x01ef , "dcaron" ); + KEYVAL ( 0x01f0 , "dstroke" ); + KEYVAL ( 0x01f1 , "nacute" ); + KEYVAL ( 0x01f2 , "ncaron" ); + KEYVAL ( 0x01f5 , "odoubleacute" ); + KEYVAL ( 0x01f8 , "rcaron" ); + KEYVAL ( 0x01f9 , "uring" ); + KEYVAL ( 0x01fb , "udoubleacute" ); + KEYVAL ( 0x01fe , "tcedilla" ); + KEYVAL ( 0x01ff , "abovedot" ); + KEYVAL ( 0x02a1 , "Hstroke" ); + KEYVAL ( 0x02a6 , "Hcircumflex" ); + KEYVAL ( 0x02a9 , "Iabovedot" ); + KEYVAL ( 0x02ab , "Gbreve" ); + KEYVAL ( 0x02ac , "Jcircumflex" ); + KEYVAL ( 0x02b1 , "hstroke" ); + KEYVAL ( 0x02b6 , "hcircumflex" ); + KEYVAL ( 0x02b9 , "idotless" ); + KEYVAL ( 0x02bb , "gbreve" ); + KEYVAL ( 0x02bc , "jcircumflex" ); + KEYVAL ( 0x02c5 , "Cabovedot" ); + KEYVAL ( 0x02c6 , "Ccircumflex" ); + KEYVAL ( 0x02d5 , "Gabovedot" ); + KEYVAL ( 0x02d8 , "Gcircumflex" ); + KEYVAL ( 0x02dd , "Ubreve" ); + KEYVAL ( 0x02de , "Scircumflex" ); + KEYVAL ( 0x02e5 , "cabovedot" ); + KEYVAL ( 0x02e6 , "ccircumflex" ); + KEYVAL ( 0x02f5 , "gabovedot" ); + KEYVAL ( 0x02f8 , "gcircumflex" ); + KEYVAL ( 0x02fd , "ubreve" ); + KEYVAL ( 0x02fe , "scircumflex" ); + KEYVAL ( 0x03a2 , "kappa" ); + KEYVAL ( 0x03a2 , "kra" ); + KEYVAL ( 0x03a3 , "Rcedilla" ); + KEYVAL ( 0x03a5 , "Itilde" ); + KEYVAL ( 0x03a6 , "Lcedilla" ); + KEYVAL ( 0x03aa , "Emacron" ); + KEYVAL ( 0x03ab , "Gcedilla" ); + KEYVAL ( 0x03ac , "Tslash" ); + KEYVAL ( 0x03b3 , "rcedilla" ); + KEYVAL ( 0x03b5 , "itilde" ); + KEYVAL ( 0x03b6 , "lcedilla" ); + KEYVAL ( 0x03ba , "emacron" ); + KEYVAL ( 0x03bb , "gcedilla" ); + KEYVAL ( 0x03bc , "tslash" ); + KEYVAL ( 0x03bd , "ENG" ); + KEYVAL ( 0x03bf , "eng" ); + KEYVAL ( 0x03c0 , "Amacron" ); + KEYVAL ( 0x03c7 , "Iogonek" ); + KEYVAL ( 0x03cc , "Eabovedot" ); + KEYVAL ( 0x03cf , "Imacron" ); + KEYVAL ( 0x03d1 , "Ncedilla" ); + KEYVAL ( 0x03d2 , "Omacron" ); + KEYVAL ( 0x03d3 , "Kcedilla" ); + KEYVAL ( 0x03d9 , "Uogonek" ); + KEYVAL ( 0x03dd , "Utilde" ); + KEYVAL ( 0x03de , "Umacron" ); + KEYVAL ( 0x03e0 , "amacron" ); + KEYVAL ( 0x03e7 , "iogonek" ); + KEYVAL ( 0x03ec , "eabovedot" ); + KEYVAL ( 0x03ef , "imacron" ); + KEYVAL ( 0x03f1 , "ncedilla" ); + KEYVAL ( 0x03f2 , "omacron" ); + KEYVAL ( 0x03f3 , "kcedilla" ); + KEYVAL ( 0x03f9 , "uogonek" ); + KEYVAL ( 0x03fd , "utilde" ); + KEYVAL ( 0x03fe , "umacron" ); + KEYVAL ( 0x047e , "overline" ); + KEYVAL ( 0x04a1 , "kana_fullstop" ); + KEYVAL ( 0x04a2 , "kana_openingbracket" ); + KEYVAL ( 0x04a3 , "kana_closingbracket" ); + KEYVAL ( 0x04a4 , "kana_comma" ); + KEYVAL ( 0x04a5 , "kana_conjunctive" ); + KEYVAL ( 0x04a5 , "kana_middledot" ); + KEYVAL ( 0x04a6 , "kana_WO" ); + KEYVAL ( 0x04a7 , "kana_a" ); + KEYVAL ( 0x04a8 , "kana_i" ); + KEYVAL ( 0x04a9 , "kana_u" ); + KEYVAL ( 0x04aa , "kana_e" ); + KEYVAL ( 0x04ab , "kana_o" ); + KEYVAL ( 0x04ac , "kana_ya" ); + KEYVAL ( 0x04ad , "kana_yu" ); + KEYVAL ( 0x04ae , "kana_yo" ); + KEYVAL ( 0x04af , "kana_tsu" ); + KEYVAL ( 0x04af , "kana_tu" ); + KEYVAL ( 0x04b0 , "prolongedsound" ); + KEYVAL ( 0x04b1 , "kana_A" ); + KEYVAL ( 0x04b2 , "kana_I" ); + KEYVAL ( 0x04b3 , "kana_U" ); + KEYVAL ( 0x04b4 , "kana_E" ); + KEYVAL ( 0x04b5 , "kana_O" ); + KEYVAL ( 0x04b6 , "kana_KA" ); + KEYVAL ( 0x04b7 , "kana_KI" ); + KEYVAL ( 0x04b8 , "kana_KU" ); + KEYVAL ( 0x04b9 , "kana_KE" ); + KEYVAL ( 0x04ba , "kana_KO" ); + KEYVAL ( 0x04bb , "kana_SA" ); + KEYVAL ( 0x04bc , "kana_SHI" ); + KEYVAL ( 0x04bd , "kana_SU" ); + KEYVAL ( 0x04be , "kana_SE" ); + KEYVAL ( 0x04bf , "kana_SO" ); + KEYVAL ( 0x04c0 , "kana_TA" ); + KEYVAL ( 0x04c1 , "kana_CHI" ); + KEYVAL ( 0x04c1 , "kana_TI" ); + KEYVAL ( 0x04c2 , "kana_TSU" ); + KEYVAL ( 0x04c2 , "kana_TU" ); + KEYVAL ( 0x04c3 , "kana_TE" ); + KEYVAL ( 0x04c4 , "kana_TO" ); + KEYVAL ( 0x04c5 , "kana_NA" ); + KEYVAL ( 0x04c6 , "kana_NI" ); + KEYVAL ( 0x04c7 , "kana_NU" ); + KEYVAL ( 0x04c8 , "kana_NE" ); + KEYVAL ( 0x04c9 , "kana_NO" ); + KEYVAL ( 0x04ca , "kana_HA" ); + KEYVAL ( 0x04cb , "kana_HI" ); + KEYVAL ( 0x04cc , "kana_FU" ); + KEYVAL ( 0x04cc , "kana_HU" ); + KEYVAL ( 0x04cd , "kana_HE" ); + KEYVAL ( 0x04ce , "kana_HO" ); + KEYVAL ( 0x04cf , "kana_MA" ); + KEYVAL ( 0x04d0 , "kana_MI" ); + KEYVAL ( 0x04d1 , "kana_MU" ); + KEYVAL ( 0x04d2 , "kana_ME" ); + KEYVAL ( 0x04d3 , "kana_MO" ); + KEYVAL ( 0x04d4 , "kana_YA" ); + KEYVAL ( 0x04d5 , "kana_YU" ); + KEYVAL ( 0x04d6 , "kana_YO" ); + KEYVAL ( 0x04d7 , "kana_RA" ); + KEYVAL ( 0x04d8 , "kana_RI" ); + KEYVAL ( 0x04d9 , "kana_RU" ); + KEYVAL ( 0x04da , "kana_RE" ); + KEYVAL ( 0x04db , "kana_RO" ); + KEYVAL ( 0x04dc , "kana_WA" ); + KEYVAL ( 0x04dd , "kana_N" ); + KEYVAL ( 0x04de , "voicedsound" ); + KEYVAL ( 0x04df , "semivoicedsound" ); + KEYVAL ( 0x05ac , "Arabic_comma" ); + KEYVAL ( 0x05bb , "Arabic_semicolon" ); + KEYVAL ( 0x05bf , "Arabic_question_mark" ); + KEYVAL ( 0x05c1 , "Arabic_hamza" ); + KEYVAL ( 0x05c2 , "Arabic_maddaonalef" ); + KEYVAL ( 0x05c3 , "Arabic_hamzaonalef" ); + KEYVAL ( 0x05c4 , "Arabic_hamzaonwaw" ); + KEYVAL ( 0x05c5 , "Arabic_hamzaunderalef" ); + KEYVAL ( 0x05c6 , "Arabic_hamzaonyeh" ); + KEYVAL ( 0x05c7 , "Arabic_alef" ); + KEYVAL ( 0x05c8 , "Arabic_beh" ); + KEYVAL ( 0x05c9 , "Arabic_tehmarbuta" ); + KEYVAL ( 0x05ca , "Arabic_teh" ); + KEYVAL ( 0x05cb , "Arabic_theh" ); + KEYVAL ( 0x05cc , "Arabic_jeem" ); + KEYVAL ( 0x05cd , "Arabic_hah" ); + KEYVAL ( 0x05ce , "Arabic_khah" ); + KEYVAL ( 0x05cf , "Arabic_dal" ); + KEYVAL ( 0x05d0 , "Arabic_thal" ); + KEYVAL ( 0x05d1 , "Arabic_ra" ); + KEYVAL ( 0x05d2 , "Arabic_zain" ); + KEYVAL ( 0x05d3 , "Arabic_seen" ); + KEYVAL ( 0x05d4 , "Arabic_sheen" ); + KEYVAL ( 0x05d5 , "Arabic_sad" ); + KEYVAL ( 0x05d6 , "Arabic_dad" ); + KEYVAL ( 0x05d7 , "Arabic_tah" ); + KEYVAL ( 0x05d8 , "Arabic_zah" ); + KEYVAL ( 0x05d9 , "Arabic_ain" ); + KEYVAL ( 0x05da , "Arabic_ghain" ); + KEYVAL ( 0x05e0 , "Arabic_tatweel" ); + KEYVAL ( 0x05e1 , "Arabic_feh" ); + KEYVAL ( 0x05e2 , "Arabic_qaf" ); + KEYVAL ( 0x05e3 , "Arabic_kaf" ); + KEYVAL ( 0x05e4 , "Arabic_lam" ); + KEYVAL ( 0x05e5 , "Arabic_meem" ); + KEYVAL ( 0x05e6 , "Arabic_noon" ); + KEYVAL ( 0x05e7 , "Arabic_ha" ); + KEYVAL ( 0x05e7 , "Arabic_heh" ); + KEYVAL ( 0x05e8 , "Arabic_waw" ); + KEYVAL ( 0x05e9 , "Arabic_alefmaksura" ); + KEYVAL ( 0x05ea , "Arabic_yeh" ); + KEYVAL ( 0x05eb , "Arabic_fathatan" ); + KEYVAL ( 0x05ec , "Arabic_dammatan" ); + KEYVAL ( 0x05ed , "Arabic_kasratan" ); + KEYVAL ( 0x05ee , "Arabic_fatha" ); + KEYVAL ( 0x05ef , "Arabic_damma" ); + KEYVAL ( 0x05f0 , "Arabic_kasra" ); + KEYVAL ( 0x05f1 , "Arabic_shadda" ); + KEYVAL ( 0x05f2 , "Arabic_sukun" ); + KEYVAL ( 0x06a1 , "Serbian_dje" ); + KEYVAL ( 0x06a2 , "Macedonia_gje" ); + KEYVAL ( 0x06a3 , "Cyrillic_io" ); + KEYVAL ( 0x06a4 , "Ukrainian_ie" ); + KEYVAL ( 0x06a4 , "Ukranian_je" ); + KEYVAL ( 0x06a5 , "Macedonia_dse" ); + KEYVAL ( 0x06a6 , "Ukrainian_i" ); + KEYVAL ( 0x06a6 , "Ukranian_i" ); + KEYVAL ( 0x06a7 , "Ukrainian_yi" ); + KEYVAL ( 0x06a7 , "Ukranian_yi" ); + KEYVAL ( 0x06a8 , "Cyrillic_je" ); + KEYVAL ( 0x06a8 , "Serbian_je" ); + KEYVAL ( 0x06a9 , "Cyrillic_lje" ); + KEYVAL ( 0x06a9 , "Serbian_lje" ); + KEYVAL ( 0x06aa , "Cyrillic_nje" ); + KEYVAL ( 0x06aa , "Serbian_nje" ); + KEYVAL ( 0x06ab , "Serbian_tshe" ); + KEYVAL ( 0x06ac , "Macedonia_kje" ); + KEYVAL ( 0x06ad , "Ukrainian_ghe_with_upturn" ); + KEYVAL ( 0x06ae , "Byelorussian_shortu" ); + KEYVAL ( 0x06af , "Cyrillic_dzhe" ); + KEYVAL ( 0x06af , "Serbian_dze" ); + KEYVAL ( 0x06b0 , "numerosign" ); + KEYVAL ( 0x06b1 , "Serbian_DJE" ); + KEYVAL ( 0x06b2 , "Macedonia_GJE" ); + KEYVAL ( 0x06b3 , "Cyrillic_IO" ); + KEYVAL ( 0x06b4 , "Ukrainian_IE" ); + KEYVAL ( 0x06b4 , "Ukranian_JE" ); + KEYVAL ( 0x06b5 , "Macedonia_DSE" ); + KEYVAL ( 0x06b6 , "Ukrainian_I" ); + KEYVAL ( 0x06b6 , "Ukranian_I" ); + KEYVAL ( 0x06b7 , "Ukrainian_YI" ); + KEYVAL ( 0x06b7 , "Ukranian_YI" ); + KEYVAL ( 0x06b8 , "Cyrillic_JE" ); + KEYVAL ( 0x06b8 , "Serbian_JE" ); + KEYVAL ( 0x06b9 , "Cyrillic_LJE" ); + KEYVAL ( 0x06b9 , "Serbian_LJE" ); + KEYVAL ( 0x06ba , "Cyrillic_NJE" ); + KEYVAL ( 0x06ba , "Serbian_NJE" ); + KEYVAL ( 0x06bb , "Serbian_TSHE" ); + KEYVAL ( 0x06bc , "Macedonia_KJE" ); + KEYVAL ( 0x06bd , "Ukrainian_GHE_WITH_UPTURN" ); + KEYVAL ( 0x06be , "Byelorussian_SHORTU" ); + KEYVAL ( 0x06bf , "Cyrillic_DZHE" ); + KEYVAL ( 0x06bf , "Serbian_DZE" ); + KEYVAL ( 0x06c0 , "Cyrillic_yu" ); + KEYVAL ( 0x06c1 , "Cyrillic_a" ); + KEYVAL ( 0x06c2 , "Cyrillic_be" ); + KEYVAL ( 0x06c3 , "Cyrillic_tse" ); + KEYVAL ( 0x06c4 , "Cyrillic_de" ); + KEYVAL ( 0x06c5 , "Cyrillic_ie" ); + KEYVAL ( 0x06c6 , "Cyrillic_ef" ); + KEYVAL ( 0x06c7 , "Cyrillic_ghe" ); + KEYVAL ( 0x06c8 , "Cyrillic_ha" ); + KEYVAL ( 0x06c9 , "Cyrillic_i" ); + KEYVAL ( 0x06ca , "Cyrillic_shorti" ); + KEYVAL ( 0x06cb , "Cyrillic_ka" ); + KEYVAL ( 0x06cc , "Cyrillic_el" ); + KEYVAL ( 0x06cd , "Cyrillic_em" ); + KEYVAL ( 0x06ce , "Cyrillic_en" ); + KEYVAL ( 0x06cf , "Cyrillic_o" ); + KEYVAL ( 0x06d0 , "Cyrillic_pe" ); + KEYVAL ( 0x06d1 , "Cyrillic_ya" ); + KEYVAL ( 0x06d2 , "Cyrillic_er" ); + KEYVAL ( 0x06d3 , "Cyrillic_es" ); + KEYVAL ( 0x06d4 , "Cyrillic_te" ); + KEYVAL ( 0x06d5 , "Cyrillic_u" ); + KEYVAL ( 0x06d6 , "Cyrillic_zhe" ); + KEYVAL ( 0x06d7 , "Cyrillic_ve" ); + KEYVAL ( 0x06d8 , "Cyrillic_softsign" ); + KEYVAL ( 0x06d9 , "Cyrillic_yeru" ); + KEYVAL ( 0x06da , "Cyrillic_ze" ); + KEYVAL ( 0x06db , "Cyrillic_sha" ); + KEYVAL ( 0x06dc , "Cyrillic_e" ); + KEYVAL ( 0x06dd , "Cyrillic_shcha" ); + KEYVAL ( 0x06de , "Cyrillic_che" ); + KEYVAL ( 0x06df , "Cyrillic_hardsign" ); + KEYVAL ( 0x06e0 , "Cyrillic_YU" ); + KEYVAL ( 0x06e1 , "Cyrillic_A" ); + KEYVAL ( 0x06e2 , "Cyrillic_BE" ); + KEYVAL ( 0x06e3 , "Cyrillic_TSE" ); + KEYVAL ( 0x06e4 , "Cyrillic_DE" ); + KEYVAL ( 0x06e5 , "Cyrillic_IE" ); + KEYVAL ( 0x06e6 , "Cyrillic_EF" ); + KEYVAL ( 0x06e7 , "Cyrillic_GHE" ); + KEYVAL ( 0x06e8 , "Cyrillic_HA" ); + KEYVAL ( 0x06e9 , "Cyrillic_I" ); + KEYVAL ( 0x06ea , "Cyrillic_SHORTI" ); + KEYVAL ( 0x06eb , "Cyrillic_KA" ); + KEYVAL ( 0x06ec , "Cyrillic_EL" ); + KEYVAL ( 0x06ed , "Cyrillic_EM" ); + KEYVAL ( 0x06ee , "Cyrillic_EN" ); + KEYVAL ( 0x06ef , "Cyrillic_O" ); + KEYVAL ( 0x06f0 , "Cyrillic_PE" ); + KEYVAL ( 0x06f1 , "Cyrillic_YA" ); + KEYVAL ( 0x06f2 , "Cyrillic_ER" ); + KEYVAL ( 0x06f3 , "Cyrillic_ES" ); + KEYVAL ( 0x06f4 , "Cyrillic_TE" ); + KEYVAL ( 0x06f5 , "Cyrillic_U" ); + KEYVAL ( 0x06f6 , "Cyrillic_ZHE" ); + KEYVAL ( 0x06f7 , "Cyrillic_VE" ); + KEYVAL ( 0x06f8 , "Cyrillic_SOFTSIGN" ); + KEYVAL ( 0x06f9 , "Cyrillic_YERU" ); + KEYVAL ( 0x06fa , "Cyrillic_ZE" ); + KEYVAL ( 0x06fb , "Cyrillic_SHA" ); + KEYVAL ( 0x06fc , "Cyrillic_E" ); + KEYVAL ( 0x06fd , "Cyrillic_SHCHA" ); + KEYVAL ( 0x06fe , "Cyrillic_CHE" ); + KEYVAL ( 0x06ff , "Cyrillic_HARDSIGN" ); + KEYVAL ( 0x07a1 , "Greek_ALPHAaccent" ); + KEYVAL ( 0x07a2 , "Greek_EPSILONaccent" ); + KEYVAL ( 0x07a3 , "Greek_ETAaccent" ); + KEYVAL ( 0x07a4 , "Greek_IOTAaccent" ); + KEYVAL ( 0x07a5 , "Greek_IOTAdieresis" ); + KEYVAL ( 0x07a7 , "Greek_OMICRONaccent" ); + KEYVAL ( 0x07a8 , "Greek_UPSILONaccent" ); + KEYVAL ( 0x07a9 , "Greek_UPSILONdieresis" ); + KEYVAL ( 0x07ab , "Greek_OMEGAaccent" ); + KEYVAL ( 0x07ae , "Greek_accentdieresis" ); + KEYVAL ( 0x07af , "Greek_horizbar" ); + KEYVAL ( 0x07b1 , "Greek_alphaaccent" ); + KEYVAL ( 0x07b2 , "Greek_epsilonaccent" ); + KEYVAL ( 0x07b3 , "Greek_etaaccent" ); + KEYVAL ( 0x07b4 , "Greek_iotaaccent" ); + KEYVAL ( 0x07b5 , "Greek_iotadieresis" ); + KEYVAL ( 0x07b6 , "Greek_iotaaccentdieresis" ); + KEYVAL ( 0x07b7 , "Greek_omicronaccent" ); + KEYVAL ( 0x07b8 , "Greek_upsilonaccent" ); + KEYVAL ( 0x07b9 , "Greek_upsilondieresis" ); + KEYVAL ( 0x07ba , "Greek_upsilonaccentdieresis" ); + KEYVAL ( 0x07bb , "Greek_omegaaccent" ); + KEYVAL ( 0x07c1 , "Greek_ALPHA" ); + KEYVAL ( 0x07c2 , "Greek_BETA" ); + KEYVAL ( 0x07c3 , "Greek_GAMMA" ); + KEYVAL ( 0x07c4 , "Greek_DELTA" ); + KEYVAL ( 0x07c5 , "Greek_EPSILON" ); + KEYVAL ( 0x07c6 , "Greek_ZETA" ); + KEYVAL ( 0x07c7 , "Greek_ETA" ); + KEYVAL ( 0x07c8 , "Greek_THETA" ); + KEYVAL ( 0x07c9 , "Greek_IOTA" ); + KEYVAL ( 0x07ca , "Greek_KAPPA" ); + KEYVAL ( 0x07cb , "Greek_LAMBDA" ); + KEYVAL ( 0x07cb , "Greek_LAMDA" ); + KEYVAL ( 0x07cc , "Greek_MU" ); + KEYVAL ( 0x07cd , "Greek_NU" ); + KEYVAL ( 0x07ce , "Greek_XI" ); + KEYVAL ( 0x07cf , "Greek_OMICRON" ); + KEYVAL ( 0x07d0 , "Greek_PI" ); + KEYVAL ( 0x07d1 , "Greek_RHO" ); + KEYVAL ( 0x07d2 , "Greek_SIGMA" ); + KEYVAL ( 0x07d4 , "Greek_TAU" ); + KEYVAL ( 0x07d5 , "Greek_UPSILON" ); + KEYVAL ( 0x07d6 , "Greek_PHI" ); + KEYVAL ( 0x07d7 , "Greek_CHI" ); + KEYVAL ( 0x07d8 , "Greek_PSI" ); + KEYVAL ( 0x07d9 , "Greek_OMEGA" ); + KEYVAL ( 0x07e1 , "Greek_alpha" ); + KEYVAL ( 0x07e2 , "Greek_beta" ); + KEYVAL ( 0x07e3 , "Greek_gamma" ); + KEYVAL ( 0x07e4 , "Greek_delta" ); + KEYVAL ( 0x07e5 , "Greek_epsilon" ); + KEYVAL ( 0x07e6 , "Greek_zeta" ); + KEYVAL ( 0x07e7 , "Greek_eta" ); + KEYVAL ( 0x07e8 , "Greek_theta" ); + KEYVAL ( 0x07e9 , "Greek_iota" ); + KEYVAL ( 0x07ea , "Greek_kappa" ); + KEYVAL ( 0x07eb , "Greek_lambda" ); + KEYVAL ( 0x07eb , "Greek_lamda" ); + KEYVAL ( 0x07ec , "Greek_mu" ); + KEYVAL ( 0x07ed , "Greek_nu" ); + KEYVAL ( 0x07ee , "Greek_xi" ); + KEYVAL ( 0x07ef , "Greek_omicron" ); + KEYVAL ( 0x07f0 , "Greek_pi" ); + KEYVAL ( 0x07f1 , "Greek_rho" ); + KEYVAL ( 0x07f2 , "Greek_sigma" ); + KEYVAL ( 0x07f3 , "Greek_finalsmallsigma" ); + KEYVAL ( 0x07f4 , "Greek_tau" ); + KEYVAL ( 0x07f5 , "Greek_upsilon" ); + KEYVAL ( 0x07f6 , "Greek_phi" ); + KEYVAL ( 0x07f7 , "Greek_chi" ); + KEYVAL ( 0x07f8 , "Greek_psi" ); + KEYVAL ( 0x07f9 , "Greek_omega" ); + KEYVAL ( 0x08a1 , "leftradical" ); + KEYVAL ( 0x08a2 , "topleftradical" ); + KEYVAL ( 0x08a3 , "horizconnector" ); + KEYVAL ( 0x08a4 , "topintegral" ); + KEYVAL ( 0x08a5 , "botintegral" ); + KEYVAL ( 0x08a6 , "vertconnector" ); + KEYVAL ( 0x08a7 , "topleftsqbracket" ); + KEYVAL ( 0x08a8 , "botleftsqbracket" ); + KEYVAL ( 0x08a9 , "toprightsqbracket" ); + KEYVAL ( 0x08aa , "botrightsqbracket" ); + KEYVAL ( 0x08ab , "topleftparens" ); + KEYVAL ( 0x08ac , "botleftparens" ); + KEYVAL ( 0x08ad , "toprightparens" ); + KEYVAL ( 0x08ae , "botrightparens" ); + KEYVAL ( 0x08af , "leftmiddlecurlybrace" ); + KEYVAL ( 0x08b0 , "rightmiddlecurlybrace" ); + KEYVAL ( 0x08b1 , "topleftsummation" ); + KEYVAL ( 0x08b2 , "botleftsummation" ); + KEYVAL ( 0x08b3 , "topvertsummationconnector" ); + KEYVAL ( 0x08b4 , "botvertsummationconnector" ); + KEYVAL ( 0x08b5 , "toprightsummation" ); + KEYVAL ( 0x08b6 , "botrightsummation" ); + KEYVAL ( 0x08b7 , "rightmiddlesummation" ); + KEYVAL ( 0x08bc , "lessthanequal" ); + KEYVAL ( 0x08bd , "notequal" ); + KEYVAL ( 0x08be , "greaterthanequal" ); + KEYVAL ( 0x08bf , "integral" ); + KEYVAL ( 0x08c0 , "therefore" ); + KEYVAL ( 0x08c1 , "variation" ); + KEYVAL ( 0x08c2 , "infinity" ); + KEYVAL ( 0x08c5 , "nabla" ); + KEYVAL ( 0x08c8 , "approximate" ); + KEYVAL ( 0x08c9 , "similarequal" ); + KEYVAL ( 0x08cd , "ifonlyif" ); + KEYVAL ( 0x08ce , "implies" ); + KEYVAL ( 0x08cf , "identical" ); + KEYVAL ( 0x08d6 , "radical" ); + KEYVAL ( 0x08da , "includedin" ); + KEYVAL ( 0x08db , "includes" ); + KEYVAL ( 0x08dc , "intersection" ); + KEYVAL ( 0x08dd , "union" ); + KEYVAL ( 0x08de , "logicaland" ); + KEYVAL ( 0x08df , "logicalor" ); + KEYVAL ( 0x08ef , "partialderivative" ); + KEYVAL ( 0x08f6 , "function" ); + KEYVAL ( 0x08fb , "leftarrow" ); + KEYVAL ( 0x08fc , "uparrow" ); + KEYVAL ( 0x08fd , "rightarrow" ); + KEYVAL ( 0x08fe , "downarrow" ); + KEYVAL ( 0x09df , "blank" ); + KEYVAL ( 0x09e0 , "soliddiamond" ); + KEYVAL ( 0x09e1 , "checkerboard" ); + KEYVAL ( 0x09e2 , "ht" ); + KEYVAL ( 0x09e3 , "ff" ); + KEYVAL ( 0x09e4 , "cr" ); + KEYVAL ( 0x09e5 , "lf" ); + KEYVAL ( 0x09e8 , "nl" ); + KEYVAL ( 0x09e9 , "vt" ); + KEYVAL ( 0x09ea , "lowrightcorner" ); + KEYVAL ( 0x09eb , "uprightcorner" ); + KEYVAL ( 0x09ec , "upleftcorner" ); + KEYVAL ( 0x09ed , "lowleftcorner" ); + KEYVAL ( 0x09ee , "crossinglines" ); + KEYVAL ( 0x09ef , "horizlinescan1" ); + KEYVAL ( 0x09f0 , "horizlinescan3" ); + KEYVAL ( 0x09f1 , "horizlinescan5" ); + KEYVAL ( 0x09f2 , "horizlinescan7" ); + KEYVAL ( 0x09f3 , "horizlinescan9" ); + KEYVAL ( 0x09f4 , "leftt" ); + KEYVAL ( 0x09f5 , "rightt" ); + KEYVAL ( 0x09f6 , "bott" ); + KEYVAL ( 0x09f7 , "topt" ); + KEYVAL ( 0x09f8 , "vertbar" ); + KEYVAL ( 0x0aa1 , "emspace" ); + KEYVAL ( 0x0aa2 , "enspace" ); + KEYVAL ( 0x0aa3 , "em3space" ); + KEYVAL ( 0x0aa4 , "em4space" ); + KEYVAL ( 0x0aa5 , "digitspace" ); + KEYVAL ( 0x0aa6 , "punctspace" ); + KEYVAL ( 0x0aa7 , "thinspace" ); + KEYVAL ( 0x0aa8 , "hairspace" ); + KEYVAL ( 0x0aa9 , "emdash" ); + KEYVAL ( 0x0aaa , "endash" ); + KEYVAL ( 0x0aac , "signifblank" ); + KEYVAL ( 0x0aae , "ellipsis" ); + KEYVAL ( 0x0aaf , "doubbaselinedot" ); + KEYVAL ( 0x0ab0 , "onethird" ); + KEYVAL ( 0x0ab1 , "twothirds" ); + KEYVAL ( 0x0ab2 , "onefifth" ); + KEYVAL ( 0x0ab3 , "twofifths" ); + KEYVAL ( 0x0ab4 , "threefifths" ); + KEYVAL ( 0x0ab5 , "fourfifths" ); + KEYVAL ( 0x0ab6 , "onesixth" ); + KEYVAL ( 0x0ab7 , "fivesixths" ); + KEYVAL ( 0x0ab8 , "careof" ); + KEYVAL ( 0x0abb , "figdash" ); + KEYVAL ( 0x0abc , "leftanglebracket" ); + KEYVAL ( 0x0abd , "decimalpoint" ); + KEYVAL ( 0x0abe , "rightanglebracket" ); + KEYVAL ( 0x0abf , "marker" ); + KEYVAL ( 0x0ac3 , "oneeighth" ); + KEYVAL ( 0x0ac4 , "threeeighths" ); + KEYVAL ( 0x0ac5 , "fiveeighths" ); + KEYVAL ( 0x0ac6 , "seveneighths" ); + KEYVAL ( 0x0ac9 , "trademark" ); + KEYVAL ( 0x0aca , "signaturemark" ); + KEYVAL ( 0x0acb , "trademarkincircle" ); + KEYVAL ( 0x0acc , "leftopentriangle" ); + KEYVAL ( 0x0acd , "rightopentriangle" ); + KEYVAL ( 0x0ace , "emopencircle" ); + KEYVAL ( 0x0acf , "emopenrectangle" ); + KEYVAL ( 0x0ad0 , "leftsinglequotemark" ); + KEYVAL ( 0x0ad1 , "rightsinglequotemark" ); + KEYVAL ( 0x0ad2 , "leftdoublequotemark" ); + KEYVAL ( 0x0ad3 , "rightdoublequotemark" ); + KEYVAL ( 0x0ad4 , "prescription" ); + KEYVAL ( 0x0ad6 , "minutes" ); + KEYVAL ( 0x0ad7 , "seconds" ); + KEYVAL ( 0x0ad9 , "latincross" ); + KEYVAL ( 0x0ada , "hexagram" ); + KEYVAL ( 0x0adb , "filledrectbullet" ); + KEYVAL ( 0x0adc , "filledlefttribullet" ); + KEYVAL ( 0x0add , "filledrighttribullet" ); + KEYVAL ( 0x0ade , "emfilledcircle" ); + KEYVAL ( 0x0adf , "emfilledrect" ); + KEYVAL ( 0x0ae0 , "enopencircbullet" ); + KEYVAL ( 0x0ae1 , "enopensquarebullet" ); + KEYVAL ( 0x0ae2 , "openrectbullet" ); + KEYVAL ( 0x0ae3 , "opentribulletup" ); + KEYVAL ( 0x0ae4 , "opentribulletdown" ); + KEYVAL ( 0x0ae5 , "openstar" ); + KEYVAL ( 0x0ae6 , "enfilledcircbullet" ); + KEYVAL ( 0x0ae7 , "enfilledsqbullet" ); + KEYVAL ( 0x0ae8 , "filledtribulletup" ); + KEYVAL ( 0x0ae9 , "filledtribulletdown" ); + KEYVAL ( 0x0aea , "leftpointer" ); + KEYVAL ( 0x0aeb , "rightpointer" ); + KEYVAL ( 0x0aec , "club" ); + KEYVAL ( 0x0aed , "diamond" ); + KEYVAL ( 0x0aee , "heart" ); + KEYVAL ( 0x0af0 , "maltesecross" ); + KEYVAL ( 0x0af1 , "dagger" ); + KEYVAL ( 0x0af2 , "doubledagger" ); + KEYVAL ( 0x0af3 , "checkmark" ); + KEYVAL ( 0x0af4 , "ballotcross" ); + KEYVAL ( 0x0af5 , "musicalsharp" ); + KEYVAL ( 0x0af6 , "musicalflat" ); + KEYVAL ( 0x0af7 , "malesymbol" ); + KEYVAL ( 0x0af8 , "femalesymbol" ); + KEYVAL ( 0x0af9 , "telephone" ); + KEYVAL ( 0x0afa , "telephonerecorder" ); + KEYVAL ( 0x0afb , "phonographcopyright" ); + KEYVAL ( 0x0afc , "caret" ); + KEYVAL ( 0x0afd , "singlelowquotemark" ); + KEYVAL ( 0x0afe , "doublelowquotemark" ); + KEYVAL ( 0x0aff , "cursor" ); + KEYVAL ( 0x0ba3 , "leftcaret" ); + KEYVAL ( 0x0ba6 , "rightcaret" ); + KEYVAL ( 0x0ba8 , "downcaret" ); + KEYVAL ( 0x0ba9 , "upcaret" ); + KEYVAL ( 0x0bc0 , "overbar" ); + KEYVAL ( 0x0bc2 , "downtack" ); + KEYVAL ( 0x0bc3 , "upshoe" ); + KEYVAL ( 0x0bc4 , "downstile" ); + KEYVAL ( 0x0bc6 , "underbar" ); + KEYVAL ( 0x0bca , "jot" ); + KEYVAL ( 0x0bcc , "quad" ); + KEYVAL ( 0x0bce , "uptack" ); + KEYVAL ( 0x0bcf , "circle" ); + KEYVAL ( 0x0bd3 , "upstile" ); + KEYVAL ( 0x0bd6 , "downshoe" ); + KEYVAL ( 0x0bd8 , "rightshoe" ); + KEYVAL ( 0x0bda , "leftshoe" ); + KEYVAL ( 0x0bdc , "lefttack" ); + KEYVAL ( 0x0bfc , "righttack" ); + KEYVAL ( 0x0cdf , "hebrew_doublelowline" ); + KEYVAL ( 0x0ce0 , "hebrew_aleph" ); + KEYVAL ( 0x0ce1 , "hebrew_bet" ); + KEYVAL ( 0x0ce1 , "hebrew_beth" ); + KEYVAL ( 0x0ce2 , "hebrew_gimel" ); + KEYVAL ( 0x0ce2 , "hebrew_gimmel" ); + KEYVAL ( 0x0ce3 , "hebrew_dalet" ); + KEYVAL ( 0x0ce3 , "hebrew_daleth" ); + KEYVAL ( 0x0ce4 , "hebrew_he" ); + KEYVAL ( 0x0ce5 , "hebrew_waw" ); + KEYVAL ( 0x0ce6 , "hebrew_zain" ); + KEYVAL ( 0x0ce6 , "hebrew_zayin" ); + KEYVAL ( 0x0ce7 , "hebrew_chet" ); + KEYVAL ( 0x0ce7 , "hebrew_het" ); + KEYVAL ( 0x0ce8 , "hebrew_tet" ); + KEYVAL ( 0x0ce8 , "hebrew_teth" ); + KEYVAL ( 0x0ce9 , "hebrew_yod" ); + KEYVAL ( 0x0cea , "hebrew_finalkaph" ); + KEYVAL ( 0x0ceb , "hebrew_kaph" ); + KEYVAL ( 0x0cec , "hebrew_lamed" ); + KEYVAL ( 0x0ced , "hebrew_finalmem" ); + KEYVAL ( 0x0cee , "hebrew_mem" ); + KEYVAL ( 0x0cef , "hebrew_finalnun" ); + KEYVAL ( 0x0cf0 , "hebrew_nun" ); + KEYVAL ( 0x0cf1 , "hebrew_samech" ); + KEYVAL ( 0x0cf1 , "hebrew_samekh" ); + KEYVAL ( 0x0cf2 , "hebrew_ayin" ); + KEYVAL ( 0x0cf3 , "hebrew_finalpe" ); + KEYVAL ( 0x0cf4 , "hebrew_pe" ); + KEYVAL ( 0x0cf5 , "hebrew_finalzade" ); + KEYVAL ( 0x0cf5 , "hebrew_finalzadi" ); + KEYVAL ( 0x0cf6 , "hebrew_zade" ); + KEYVAL ( 0x0cf6 , "hebrew_zadi" ); + KEYVAL ( 0x0cf7 , "hebrew_kuf" ); + KEYVAL ( 0x0cf7 , "hebrew_qoph" ); + KEYVAL ( 0x0cf8 , "hebrew_resh" ); + KEYVAL ( 0x0cf9 , "hebrew_shin" ); + KEYVAL ( 0x0cfa , "hebrew_taf" ); + KEYVAL ( 0x0cfa , "hebrew_taw" ); + KEYVAL ( 0x0da1 , "Thai_kokai" ); + KEYVAL ( 0x0da2 , "Thai_khokhai" ); + KEYVAL ( 0x0da3 , "Thai_khokhuat" ); + KEYVAL ( 0x0da4 , "Thai_khokhwai" ); + KEYVAL ( 0x0da5 , "Thai_khokhon" ); + KEYVAL ( 0x0da6 , "Thai_khorakhang" ); + KEYVAL ( 0x0da7 , "Thai_ngongu" ); + KEYVAL ( 0x0da8 , "Thai_chochan" ); + KEYVAL ( 0x0da9 , "Thai_choching" ); + KEYVAL ( 0x0daa , "Thai_chochang" ); + KEYVAL ( 0x0dab , "Thai_soso" ); + KEYVAL ( 0x0dac , "Thai_chochoe" ); + KEYVAL ( 0x0dad , "Thai_yoying" ); + KEYVAL ( 0x0dae , "Thai_dochada" ); + KEYVAL ( 0x0daf , "Thai_topatak" ); + KEYVAL ( 0x0db0 , "Thai_thothan" ); + KEYVAL ( 0x0db1 , "Thai_thonangmontho" ); + KEYVAL ( 0x0db2 , "Thai_thophuthao" ); + KEYVAL ( 0x0db3 , "Thai_nonen" ); + KEYVAL ( 0x0db4 , "Thai_dodek" ); + KEYVAL ( 0x0db5 , "Thai_totao" ); + KEYVAL ( 0x0db6 , "Thai_thothung" ); + KEYVAL ( 0x0db7 , "Thai_thothahan" ); + KEYVAL ( 0x0db8 , "Thai_thothong" ); + KEYVAL ( 0x0db9 , "Thai_nonu" ); + KEYVAL ( 0x0dba , "Thai_bobaimai" ); + KEYVAL ( 0x0dbb , "Thai_popla" ); + KEYVAL ( 0x0dbc , "Thai_phophung" ); + KEYVAL ( 0x0dbd , "Thai_fofa" ); + KEYVAL ( 0x0dbe , "Thai_phophan" ); + KEYVAL ( 0x0dbf , "Thai_fofan" ); + KEYVAL ( 0x0dc0 , "Thai_phosamphao" ); + KEYVAL ( 0x0dc1 , "Thai_moma" ); + KEYVAL ( 0x0dc2 , "Thai_yoyak" ); + KEYVAL ( 0x0dc3 , "Thai_rorua" ); + KEYVAL ( 0x0dc4 , "Thai_ru" ); + KEYVAL ( 0x0dc5 , "Thai_loling" ); + KEYVAL ( 0x0dc6 , "Thai_lu" ); + KEYVAL ( 0x0dc7 , "Thai_wowaen" ); + KEYVAL ( 0x0dc8 , "Thai_sosala" ); + KEYVAL ( 0x0dc9 , "Thai_sorusi" ); + KEYVAL ( 0x0dca , "Thai_sosua" ); + KEYVAL ( 0x0dcb , "Thai_hohip" ); + KEYVAL ( 0x0dcc , "Thai_lochula" ); + KEYVAL ( 0x0dcd , "Thai_oang" ); + KEYVAL ( 0x0dce , "Thai_honokhuk" ); + KEYVAL ( 0x0dcf , "Thai_paiyannoi" ); + KEYVAL ( 0x0dd0 , "Thai_saraa" ); + KEYVAL ( 0x0dd1 , "Thai_maihanakat" ); + KEYVAL ( 0x0dd2 , "Thai_saraaa" ); + KEYVAL ( 0x0dd3 , "Thai_saraam" ); + KEYVAL ( 0x0dd4 , "Thai_sarai" ); + KEYVAL ( 0x0dd5 , "Thai_saraii" ); + KEYVAL ( 0x0dd6 , "Thai_saraue" ); + KEYVAL ( 0x0dd7 , "Thai_sarauee" ); + KEYVAL ( 0x0dd8 , "Thai_sarau" ); + KEYVAL ( 0x0dd9 , "Thai_sarauu" ); + KEYVAL ( 0x0dda , "Thai_phinthu" ); + KEYVAL ( 0x0dde , "Thai_maihanakat_maitho" ); + KEYVAL ( 0x0ddf , "Thai_baht" ); + KEYVAL ( 0x0de0 , "Thai_sarae" ); + KEYVAL ( 0x0de1 , "Thai_saraae" ); + KEYVAL ( 0x0de2 , "Thai_sarao" ); + KEYVAL ( 0x0de3 , "Thai_saraaimaimuan" ); + KEYVAL ( 0x0de4 , "Thai_saraaimaimalai" ); + KEYVAL ( 0x0de5 , "Thai_lakkhangyao" ); + KEYVAL ( 0x0de6 , "Thai_maiyamok" ); + KEYVAL ( 0x0de7 , "Thai_maitaikhu" ); + KEYVAL ( 0x0de8 , "Thai_maiek" ); + KEYVAL ( 0x0de9 , "Thai_maitho" ); + KEYVAL ( 0x0dea , "Thai_maitri" ); + KEYVAL ( 0x0deb , "Thai_maichattawa" ); + KEYVAL ( 0x0dec , "Thai_thanthakhat" ); + KEYVAL ( 0x0ded , "Thai_nikhahit" ); + KEYVAL ( 0x0df0 , "Thai_leksun" ); + KEYVAL ( 0x0df1 , "Thai_leknung" ); + KEYVAL ( 0x0df2 , "Thai_leksong" ); + KEYVAL ( 0x0df3 , "Thai_leksam" ); + KEYVAL ( 0x0df4 , "Thai_leksi" ); + KEYVAL ( 0x0df5 , "Thai_lekha" ); + KEYVAL ( 0x0df6 , "Thai_lekhok" ); + KEYVAL ( 0x0df7 , "Thai_lekchet" ); + KEYVAL ( 0x0df8 , "Thai_lekpaet" ); + KEYVAL ( 0x0df9 , "Thai_lekkao" ); + KEYVAL ( 0x0ea1 , "Hangul_Kiyeog" ); + KEYVAL ( 0x0ea2 , "Hangul_SsangKiyeog" ); + KEYVAL ( 0x0ea3 , "Hangul_KiyeogSios" ); + KEYVAL ( 0x0ea4 , "Hangul_Nieun" ); + KEYVAL ( 0x0ea5 , "Hangul_NieunJieuj" ); + KEYVAL ( 0x0ea6 , "Hangul_NieunHieuh" ); + KEYVAL ( 0x0ea7 , "Hangul_Dikeud" ); + KEYVAL ( 0x0ea8 , "Hangul_SsangDikeud" ); + KEYVAL ( 0x0ea9 , "Hangul_Rieul" ); + KEYVAL ( 0x0eaa , "Hangul_RieulKiyeog" ); + KEYVAL ( 0x0eab , "Hangul_RieulMieum" ); + KEYVAL ( 0x0eac , "Hangul_RieulPieub" ); + KEYVAL ( 0x0ead , "Hangul_RieulSios" ); + KEYVAL ( 0x0eae , "Hangul_RieulTieut" ); + KEYVAL ( 0x0eaf , "Hangul_RieulPhieuf" ); + KEYVAL ( 0x0eb0 , "Hangul_RieulHieuh" ); + KEYVAL ( 0x0eb1 , "Hangul_Mieum" ); + KEYVAL ( 0x0eb2 , "Hangul_Pieub" ); + KEYVAL ( 0x0eb3 , "Hangul_SsangPieub" ); + KEYVAL ( 0x0eb4 , "Hangul_PieubSios" ); + KEYVAL ( 0x0eb5 , "Hangul_Sios" ); + KEYVAL ( 0x0eb6 , "Hangul_SsangSios" ); + KEYVAL ( 0x0eb7 , "Hangul_Ieung" ); + KEYVAL ( 0x0eb8 , "Hangul_Jieuj" ); + KEYVAL ( 0x0eb9 , "Hangul_SsangJieuj" ); + KEYVAL ( 0x0eba , "Hangul_Cieuc" ); + KEYVAL ( 0x0ebb , "Hangul_Khieuq" ); + KEYVAL ( 0x0ebc , "Hangul_Tieut" ); + KEYVAL ( 0x0ebd , "Hangul_Phieuf" ); + KEYVAL ( 0x0ebe , "Hangul_Hieuh" ); + KEYVAL ( 0x0ebf , "Hangul_A" ); + KEYVAL ( 0x0ec0 , "Hangul_AE" ); + KEYVAL ( 0x0ec1 , "Hangul_YA" ); + KEYVAL ( 0x0ec2 , "Hangul_YAE" ); + KEYVAL ( 0x0ec3 , "Hangul_EO" ); + KEYVAL ( 0x0ec4 , "Hangul_E" ); + KEYVAL ( 0x0ec5 , "Hangul_YEO" ); + KEYVAL ( 0x0ec6 , "Hangul_YE" ); + KEYVAL ( 0x0ec7 , "Hangul_O" ); + KEYVAL ( 0x0ec8 , "Hangul_WA" ); + KEYVAL ( 0x0ec9 , "Hangul_WAE" ); + KEYVAL ( 0x0eca , "Hangul_OE" ); + KEYVAL ( 0x0ecb , "Hangul_YO" ); + KEYVAL ( 0x0ecc , "Hangul_U" ); + KEYVAL ( 0x0ecd , "Hangul_WEO" ); + KEYVAL ( 0x0ece , "Hangul_WE" ); + KEYVAL ( 0x0ecf , "Hangul_WI" ); + KEYVAL ( 0x0ed0 , "Hangul_YU" ); + KEYVAL ( 0x0ed1 , "Hangul_EU" ); + KEYVAL ( 0x0ed2 , "Hangul_YI" ); + KEYVAL ( 0x0ed3 , "Hangul_I" ); + KEYVAL ( 0x0ed4 , "Hangul_J_Kiyeog" ); + KEYVAL ( 0x0ed5 , "Hangul_J_SsangKiyeog" ); + KEYVAL ( 0x0ed6 , "Hangul_J_KiyeogSios" ); + KEYVAL ( 0x0ed7 , "Hangul_J_Nieun" ); + KEYVAL ( 0x0ed8 , "Hangul_J_NieunJieuj" ); + KEYVAL ( 0x0ed9 , "Hangul_J_NieunHieuh" ); + KEYVAL ( 0x0eda , "Hangul_J_Dikeud" ); + KEYVAL ( 0x0edb , "Hangul_J_Rieul" ); + KEYVAL ( 0x0edc , "Hangul_J_RieulKiyeog" ); + KEYVAL ( 0x0edd , "Hangul_J_RieulMieum" ); + KEYVAL ( 0x0ede , "Hangul_J_RieulPieub" ); + KEYVAL ( 0x0edf , "Hangul_J_RieulSios" ); + KEYVAL ( 0x0ee0 , "Hangul_J_RieulTieut" ); + KEYVAL ( 0x0ee1 , "Hangul_J_RieulPhieuf" ); + KEYVAL ( 0x0ee2 , "Hangul_J_RieulHieuh" ); + KEYVAL ( 0x0ee3 , "Hangul_J_Mieum" ); + KEYVAL ( 0x0ee4 , "Hangul_J_Pieub" ); + KEYVAL ( 0x0ee5 , "Hangul_J_PieubSios" ); + KEYVAL ( 0x0ee6 , "Hangul_J_Sios" ); + KEYVAL ( 0x0ee7 , "Hangul_J_SsangSios" ); + KEYVAL ( 0x0ee8 , "Hangul_J_Ieung" ); + KEYVAL ( 0x0ee9 , "Hangul_J_Jieuj" ); + KEYVAL ( 0x0eea , "Hangul_J_Cieuc" ); + KEYVAL ( 0x0eeb , "Hangul_J_Khieuq" ); + KEYVAL ( 0x0eec , "Hangul_J_Tieut" ); + KEYVAL ( 0x0eed , "Hangul_J_Phieuf" ); + KEYVAL ( 0x0eee , "Hangul_J_Hieuh" ); + KEYVAL ( 0x0eef , "Hangul_RieulYeorinHieuh" ); + KEYVAL ( 0x0ef0 , "Hangul_SunkyeongeumMieum" ); + KEYVAL ( 0x0ef1 , "Hangul_SunkyeongeumPieub" ); + KEYVAL ( 0x0ef2 , "Hangul_PanSios" ); + KEYVAL ( 0x0ef3 , "Hangul_KkogjiDalrinIeung" ); + KEYVAL ( 0x0ef4 , "Hangul_SunkyeongeumPhieuf" ); + KEYVAL ( 0x0ef5 , "Hangul_YeorinHieuh" ); + KEYVAL ( 0x0ef6 , "Hangul_AraeA" ); + KEYVAL ( 0x0ef7 , "Hangul_AraeAE" ); + KEYVAL ( 0x0ef8 , "Hangul_J_PanSios" ); + KEYVAL ( 0x0ef9 , "Hangul_J_KkogjiDalrinIeung" ); + KEYVAL ( 0x0efa , "Hangul_J_YeorinHieuh" ); + KEYVAL ( 0x0eff , "Korean_Won" ); + KEYVAL ( 0x13bc , "OE" ); + KEYVAL ( 0x13bd , "oe" ); + KEYVAL ( 0x13be , "Ydiaeresis" ); + KEYVAL ( 0x20a0 , "EcuSign" ); + KEYVAL ( 0x20a1 , "ColonSign" ); + KEYVAL ( 0x20a2 , "CruzeiroSign" ); + KEYVAL ( 0x20a3 , "FFrancSign" ); + KEYVAL ( 0x20a4 , "LiraSign" ); + KEYVAL ( 0x20a5 , "MillSign" ); + KEYVAL ( 0x20a6 , "NairaSign" ); + KEYVAL ( 0x20a7 , "PesetaSign" ); + KEYVAL ( 0x20a8 , "RupeeSign" ); + KEYVAL ( 0x20a9 , "WonSign" ); + KEYVAL ( 0x20aa , "NewSheqelSign" ); + KEYVAL ( 0x20ab , "DongSign" ); + KEYVAL ( 0x20ac , "EuroSign" ); + KEYVAL ( 0xFD01 , "3270_Duplicate" ); + KEYVAL ( 0xFD02 , "3270_FieldMark" ); + KEYVAL ( 0xFD03 , "3270_Right2" ); + KEYVAL ( 0xFD04 , "3270_Left2" ); + KEYVAL ( 0xFD05 , "3270_BackTab" ); + KEYVAL ( 0xFD06 , "3270_EraseEOF" ); + KEYVAL ( 0xFD07 , "3270_EraseInput" ); + KEYVAL ( 0xFD08 , "3270_Reset" ); + KEYVAL ( 0xFD09 , "3270_Quit" ); + KEYVAL ( 0xFD0A , "3270_PA1" ); + KEYVAL ( 0xFD0B , "3270_PA2" ); + KEYVAL ( 0xFD0C , "3270_PA3" ); + KEYVAL ( 0xFD0D , "3270_Test" ); + KEYVAL ( 0xFD0E , "3270_Attn" ); + KEYVAL ( 0xFD0F , "3270_CursorBlink" ); + KEYVAL ( 0xFD10 , "3270_AltCursor" ); + KEYVAL ( 0xFD11 , "3270_KeyClick" ); + KEYVAL ( 0xFD12 , "3270_Jump" ); + KEYVAL ( 0xFD13 , "3270_Ident" ); + KEYVAL ( 0xFD14 , "3270_Rule" ); + KEYVAL ( 0xFD15 , "3270_Copy" ); + KEYVAL ( 0xFD16 , "3270_Play" ); + KEYVAL ( 0xFD17 , "3270_Setup" ); + KEYVAL ( 0xFD18 , "3270_Record" ); + KEYVAL ( 0xFD19 , "3270_ChangeScreen" ); + KEYVAL ( 0xFD1A , "3270_DeleteWord" ); + KEYVAL ( 0xFD1B , "3270_ExSelect" ); + KEYVAL ( 0xFD1C , "3270_CursorSelect" ); + KEYVAL ( 0xFD1D , "3270_PrintScreen" ); + KEYVAL ( 0xFD1E , "3270_Enter" ); + KEYVAL ( 0xFE01 , "ISO_Lock" ); + KEYVAL ( 0xFE02 , "ISO_Level2_Latch" ); + KEYVAL ( 0xFE03 , "ISO_Level3_Shift" ); + KEYVAL ( 0xFE04 , "ISO_Level3_Latch" ); + KEYVAL ( 0xFE05 , "ISO_Level3_Lock" ); + KEYVAL ( 0xFE06 , "ISO_Group_Latch" ); + KEYVAL ( 0xFE07 , "ISO_Group_Lock" ); + KEYVAL ( 0xFE08 , "ISO_Next_Group" ); + KEYVAL ( 0xFE09 , "ISO_Next_Group_Lock" ); + KEYVAL ( 0xFE0A , "ISO_Prev_Group" ); + KEYVAL ( 0xFE0B , "ISO_Prev_Group_Lock" ); + KEYVAL ( 0xFE0C , "ISO_First_Group" ); + KEYVAL ( 0xFE0D , "ISO_First_Group_Lock" ); + KEYVAL ( 0xFE0E , "ISO_Last_Group" ); + KEYVAL ( 0xFE0F , "ISO_Last_Group_Lock" ); + KEYVAL ( 0xFE20 , "ISO_Left_Tab" ); + KEYVAL ( 0xFE21 , "ISO_Move_Line_Up" ); + KEYVAL ( 0xFE22 , "ISO_Move_Line_Down" ); + KEYVAL ( 0xFE23 , "ISO_Partial_Line_Up" ); + KEYVAL ( 0xFE24 , "ISO_Partial_Line_Down" ); + KEYVAL ( 0xFE25 , "ISO_Partial_Space_Left" ); + KEYVAL ( 0xFE26 , "ISO_Partial_Space_Right" ); + KEYVAL ( 0xFE27 , "ISO_Set_Margin_Left" ); + KEYVAL ( 0xFE28 , "ISO_Set_Margin_Right" ); + KEYVAL ( 0xFE29 , "ISO_Release_Margin_Left" ); + KEYVAL ( 0xFE2A , "ISO_Release_Margin_Right" ); + KEYVAL ( 0xFE2B , "ISO_Release_Both_Margins" ); + KEYVAL ( 0xFE2C , "ISO_Fast_Cursor_Left" ); + KEYVAL ( 0xFE2D , "ISO_Fast_Cursor_Right" ); + KEYVAL ( 0xFE2E , "ISO_Fast_Cursor_Up" ); + KEYVAL ( 0xFE2F , "ISO_Fast_Cursor_Down" ); + KEYVAL ( 0xFE30 , "ISO_Continuous_Underline" ); + KEYVAL ( 0xFE31 , "ISO_Discontinuous_Underline" ); + KEYVAL ( 0xFE32 , "ISO_Emphasize" ); + KEYVAL ( 0xFE33 , "ISO_Center_Object" ); + KEYVAL ( 0xFE34 , "ISO_Enter" ); + KEYVAL ( 0xFE50 , "dead_grave" ); + KEYVAL ( 0xFE51 , "dead_acute" ); + KEYVAL ( 0xFE52 , "dead_circumflex" ); + KEYVAL ( 0xFE53 , "dead_tilde" ); + KEYVAL ( 0xFE54 , "dead_macron" ); + KEYVAL ( 0xFE55 , "dead_breve" ); + KEYVAL ( 0xFE56 , "dead_abovedot" ); + KEYVAL ( 0xFE57 , "dead_diaeresis" ); + KEYVAL ( 0xFE58 , "dead_abovering" ); + KEYVAL ( 0xFE59 , "dead_doubleacute" ); + KEYVAL ( 0xFE5A , "dead_caron" ); + KEYVAL ( 0xFE5B , "dead_cedilla" ); + KEYVAL ( 0xFE5C , "dead_ogonek" ); + KEYVAL ( 0xFE5D , "dead_iota" ); + KEYVAL ( 0xFE5E , "dead_voiced_sound" ); + KEYVAL ( 0xFE5F , "dead_semivoiced_sound" ); + KEYVAL ( 0xFE60 , "dead_belowdot" ); + KEYVAL ( 0xFE61 , "dead_hook" ); + KEYVAL ( 0xFE62 , "dead_horn" ); + KEYVAL ( 0xFE70 , "AccessX_Enable" ); + KEYVAL ( 0xFE71 , "AccessX_Feedback_Enable" ); + KEYVAL ( 0xFE72 , "RepeatKeys_Enable" ); + KEYVAL ( 0xFE73 , "SlowKeys_Enable" ); + KEYVAL ( 0xFE74 , "BounceKeys_Enable" ); + KEYVAL ( 0xFE75 , "StickyKeys_Enable" ); + KEYVAL ( 0xFE76 , "MouseKeys_Enable" ); + KEYVAL ( 0xFE77 , "MouseKeys_Accel_Enable" ); + KEYVAL ( 0xFE78 , "Overlay1_Enable" ); + KEYVAL ( 0xFE79 , "Overlay2_Enable" ); + KEYVAL ( 0xFE7A , "AudibleBell_Enable" ); + KEYVAL ( 0xFED0 , "First_Virtual_Screen" ); + KEYVAL ( 0xFED1 , "Prev_Virtual_Screen" ); + KEYVAL ( 0xFED2 , "Next_Virtual_Screen" ); + KEYVAL ( 0xFED4 , "Last_Virtual_Screen" ); + KEYVAL ( 0xFED5 , "Terminate_Server" ); + KEYVAL ( 0xFEE0 , "Pointer_Left" ); + KEYVAL ( 0xFEE1 , "Pointer_Right" ); + KEYVAL ( 0xFEE2 , "Pointer_Up" ); + KEYVAL ( 0xFEE3 , "Pointer_Down" ); + KEYVAL ( 0xFEE4 , "Pointer_UpLeft" ); + KEYVAL ( 0xFEE5 , "Pointer_UpRight" ); + KEYVAL ( 0xFEE6 , "Pointer_DownLeft" ); + KEYVAL ( 0xFEE7 , "Pointer_DownRight" ); + KEYVAL ( 0xFEE8 , "Pointer_Button_Dflt" ); + KEYVAL ( 0xFEE9 , "Pointer_Button1" ); + KEYVAL ( 0xFEEA , "Pointer_Button2" ); + KEYVAL ( 0xFEEB , "Pointer_Button3" ); + KEYVAL ( 0xFEEC , "Pointer_Button4" ); + KEYVAL ( 0xFEED , "Pointer_Button5" ); + KEYVAL ( 0xFEEE , "Pointer_DblClick_Dflt" ); + KEYVAL ( 0xFEEF , "Pointer_DblClick1" ); + KEYVAL ( 0xFEF0 , "Pointer_DblClick2" ); + KEYVAL ( 0xFEF1 , "Pointer_DblClick3" ); + KEYVAL ( 0xFEF2 , "Pointer_DblClick4" ); + KEYVAL ( 0xFEF3 , "Pointer_DblClick5" ); + KEYVAL ( 0xFEF4 , "Pointer_Drag_Dflt" ); + KEYVAL ( 0xFEF5 , "Pointer_Drag1" ); + KEYVAL ( 0xFEF6 , "Pointer_Drag2" ); + KEYVAL ( 0xFEF7 , "Pointer_Drag3" ); + KEYVAL ( 0xFEF8 , "Pointer_Drag4" ); + KEYVAL ( 0xFEF9 , "Pointer_EnableKeys" ); + KEYVAL ( 0xFEFA , "Pointer_Accelerate" ); + KEYVAL ( 0xFEFB , "Pointer_DfltBtnNext" ); + KEYVAL ( 0xFEFC , "Pointer_DfltBtnPrev" ); + KEYVAL ( 0xFEFD , "Pointer_Drag5" ); + KEYVAL ( 0xFF08 , "BackSpace" ); + KEYVAL ( 0xFF09 , "Tab" ); + KEYVAL ( 0xFF0A , "Linefeed" ); + KEYVAL ( 0xFF0B , "Clear" ); + KEYVAL ( 0xFF0D , "Return" ); + KEYVAL ( 0xFF13 , "Pause" ); + KEYVAL ( 0xFF14 , "Scroll_Lock" ); + KEYVAL ( 0xFF15 , "Sys_Req" ); + KEYVAL ( 0xFF1B , "Escape" ); + KEYVAL ( 0xFF20 , "Multi_key" ); + KEYVAL ( 0xFF21 , "Kanji" ); + KEYVAL ( 0xFF22 , "Muhenkan" ); + KEYVAL ( 0xFF23 , "Henkan" ); + KEYVAL ( 0xFF23 , "Henkan_Mode" ); + KEYVAL ( 0xFF24 , "Romaji" ); + KEYVAL ( 0xFF25 , "Hiragana" ); + KEYVAL ( 0xFF26 , "Katakana" ); + KEYVAL ( 0xFF27 , "Hiragana_Katakana" ); + KEYVAL ( 0xFF28 , "Zenkaku" ); + KEYVAL ( 0xFF29 , "Hankaku" ); + KEYVAL ( 0xFF2A , "Zenkaku_Hankaku" ); + KEYVAL ( 0xFF2B , "Touroku" ); + KEYVAL ( 0xFF2C , "Massyo" ); + KEYVAL ( 0xFF2D , "Kana_Lock" ); + KEYVAL ( 0xFF2E , "Kana_Shift" ); + KEYVAL ( 0xFF2F , "Eisu_Shift" ); + KEYVAL ( 0xFF30 , "Eisu_toggle" ); + KEYVAL ( 0xff31 , "Hangul" ); + KEYVAL ( 0xff32 , "Hangul_Start" ); + KEYVAL ( 0xff33 , "Hangul_End" ); + KEYVAL ( 0xff34 , "Hangul_Hanja" ); + KEYVAL ( 0xff35 , "Hangul_Jamo" ); + KEYVAL ( 0xff36 , "Hangul_Romaja" ); + KEYVAL ( 0xFF37 , "Codeinput" ); + KEYVAL ( 0xff37 , "Hangul_Codeinput" ); + KEYVAL ( 0xFF37 , "Kanji_Bangou" ); + KEYVAL ( 0xff38 , "Hangul_Jeonja" ); + KEYVAL ( 0xff39 , "Hangul_Banja" ); + KEYVAL ( 0xff3a , "Hangul_PreHanja" ); + KEYVAL ( 0xff3b , "Hangul_PostHanja" ); + KEYVAL ( 0xff3c , "Hangul_SingleCandidate" ); + KEYVAL ( 0xFF3C , "SingleCandidate" ); + KEYVAL ( 0xff3d , "Hangul_MultipleCandidate" ); + KEYVAL ( 0xFF3D , "MultipleCandidate" ); + KEYVAL ( 0xFF3D , "Zen_Koho" ); + KEYVAL ( 0xff3e , "Hangul_PreviousCandidate" ); + KEYVAL ( 0xFF3E , "Mae_Koho" ); + KEYVAL ( 0xFF3E , "PreviousCandidate" ); + KEYVAL ( 0xff3f , "Hangul_Special" ); + KEYVAL ( 0xFF50 , "Home" ); + KEYVAL ( 0xFF51 , "Left" ); + KEYVAL ( 0xFF52 , "Up" ); + KEYVAL ( 0xFF53 , "Right" ); + KEYVAL ( 0xFF54 , "Down" ); + KEYVAL ( 0xFF55 , "Page_Up" ); + KEYVAL ( 0xFF55 , "Prior" ); + KEYVAL ( 0xFF56 , "Next" ); + KEYVAL ( 0xFF56 , "Page_Down" ); + KEYVAL ( 0xFF57 , "End" ); + KEYVAL ( 0xFF58 , "Begin" ); + KEYVAL ( 0xFF60 , "Select" ); + KEYVAL ( 0xFF61 , "Print" ); + KEYVAL ( 0xFF62 , "Execute" ); + KEYVAL ( 0xFF63 , "Insert" ); + KEYVAL ( 0xFF65 , "Undo" ); + KEYVAL ( 0xFF66 , "Redo" ); + KEYVAL ( 0xFF67 , "Menu" ); + KEYVAL ( 0xFF68 , "Find" ); + KEYVAL ( 0xFF69 , "Cancel" ); + KEYVAL ( 0xFF6A , "Help" ); + KEYVAL ( 0xFF6B , "Break" ); + KEYVAL ( 0xFF7E , "Arabic_switch" ); + KEYVAL ( 0xFF7E , "Greek_switch" ); + KEYVAL ( 0xFF7E , "Hangul_switch" ); + KEYVAL ( 0xFF7E , "Hebrew_switch" ); + KEYVAL ( 0xFF7E , "ISO_Group_Shift" ); + KEYVAL ( 0xFF7E , "kana_switch" ); + KEYVAL ( 0xFF7E , "Mode_switch" ); + KEYVAL ( 0xFF7E , "script_switch" ); + KEYVAL ( 0xFF7F , "Num_Lock" ); + KEYVAL ( 0xFF80 , "KP_Space" ); + KEYVAL ( 0xFF89 , "KP_Tab" ); + KEYVAL ( 0xFF8D , "KP_Enter" ); + KEYVAL ( 0xFF91 , "KP_F1" ); + KEYVAL ( 0xFF92 , "KP_F2" ); + KEYVAL ( 0xFF93 , "KP_F3" ); + KEYVAL ( 0xFF94 , "KP_F4" ); + KEYVAL ( 0xFF95 , "KP_Home" ); + KEYVAL ( 0xFF96 , "KP_Left" ); + KEYVAL ( 0xFF97 , "KP_Up" ); + KEYVAL ( 0xFF98 , "KP_Right" ); + KEYVAL ( 0xFF99 , "KP_Down" ); + KEYVAL ( 0xFF9A , "KP_Page_Up" ); + KEYVAL ( 0xFF9A , "KP_Prior" ); + KEYVAL ( 0xFF9B , "KP_Next" ); + KEYVAL ( 0xFF9B , "KP_Page_Down" ); + KEYVAL ( 0xFF9C , "KP_End" ); + KEYVAL ( 0xFF9D , "KP_Begin" ); + KEYVAL ( 0xFF9E , "KP_Insert" ); + KEYVAL ( 0xFF9F , "KP_Delete" ); + KEYVAL ( 0xFFAA , "KP_Multiply" ); + KEYVAL ( 0xFFAB , "KP_Add" ); + KEYVAL ( 0xFFAC , "KP_Separator" ); + KEYVAL ( 0xFFAD , "KP_Subtract" ); + KEYVAL ( 0xFFAE , "KP_Decimal" ); + KEYVAL ( 0xFFAF , "KP_Divide" ); + KEYVAL ( 0xFFB0 , "KP_0" ); + KEYVAL ( 0xFFB1 , "KP_1" ); + KEYVAL ( 0xFFB2 , "KP_2" ); + KEYVAL ( 0xFFB3 , "KP_3" ); + KEYVAL ( 0xFFB4 , "KP_4" ); + KEYVAL ( 0xFFB5 , "KP_5" ); + KEYVAL ( 0xFFB6 , "KP_6" ); + KEYVAL ( 0xFFB7 , "KP_7" ); + KEYVAL ( 0xFFB8 , "KP_8" ); + KEYVAL ( 0xFFB9 , "KP_9" ); + KEYVAL ( 0xFFBD , "KP_Equal" ); + KEYVAL ( 0xFFBE , "F1" ); + KEYVAL ( 0xFFBF , "F2" ); + KEYVAL ( 0xFFC0 , "F3" ); + KEYVAL ( 0xFFC1 , "F4" ); + KEYVAL ( 0xFFC2 , "F5" ); + KEYVAL ( 0xFFC3 , "F6" ); + KEYVAL ( 0xFFC4 , "F7" ); + KEYVAL ( 0xFFC5 , "F8" ); + KEYVAL ( 0xFFC6 , "F9" ); + KEYVAL ( 0xFFC7 , "F10" ); + KEYVAL ( 0xFFC8 , "F11" ); + KEYVAL ( 0xFFC8 , "L1" ); + KEYVAL ( 0xFFC9 , "F12" ); + KEYVAL ( 0xFFC9 , "L2" ); + KEYVAL ( 0xFFCA , "F13" ); + KEYVAL ( 0xFFCA , "L3" ); + KEYVAL ( 0xFFCB , "F14" ); + KEYVAL ( 0xFFCB , "L4" ); + KEYVAL ( 0xFFCC , "F15" ); + KEYVAL ( 0xFFCC , "L5" ); + KEYVAL ( 0xFFCD , "F16" ); + KEYVAL ( 0xFFCD , "L6" ); + KEYVAL ( 0xFFCE , "F17" ); + KEYVAL ( 0xFFCE , "L7" ); + KEYVAL ( 0xFFCF , "F18" ); + KEYVAL ( 0xFFCF , "L8" ); + KEYVAL ( 0xFFD0 , "F19" ); + KEYVAL ( 0xFFD0 , "L9" ); + KEYVAL ( 0xFFD1 , "F20" ); + KEYVAL ( 0xFFD1 , "L10" ); + KEYVAL ( 0xFFD2 , "F21" ); + KEYVAL ( 0xFFD2 , "R1" ); + KEYVAL ( 0xFFD3 , "F22" ); + KEYVAL ( 0xFFD3 , "R2" ); + KEYVAL ( 0xFFD4 , "F23" ); + KEYVAL ( 0xFFD4 , "R3" ); + KEYVAL ( 0xFFD5 , "F24" ); + KEYVAL ( 0xFFD5 , "R4" ); + KEYVAL ( 0xFFD6 , "F25" ); + KEYVAL ( 0xFFD6 , "R5" ); + KEYVAL ( 0xFFD7 , "F26" ); + KEYVAL ( 0xFFD7 , "R6" ); + KEYVAL ( 0xFFD8 , "F27" ); + KEYVAL ( 0xFFD8 , "R7" ); + KEYVAL ( 0xFFD9 , "F28" ); + KEYVAL ( 0xFFD9 , "R8" ); + KEYVAL ( 0xFFDA , "F29" ); + KEYVAL ( 0xFFDA , "R9" ); + KEYVAL ( 0xFFDB , "F30" ); + KEYVAL ( 0xFFDB , "R10" ); + KEYVAL ( 0xFFDC , "F31" ); + KEYVAL ( 0xFFDC , "R11" ); + KEYVAL ( 0xFFDD , "F32" ); + KEYVAL ( 0xFFDD , "R12" ); + KEYVAL ( 0xFFDE , "F33" ); + KEYVAL ( 0xFFDE , "R13" ); + KEYVAL ( 0xFFDF , "F34" ); + KEYVAL ( 0xFFDF , "R14" ); + KEYVAL ( 0xFFE0 , "F35" ); + KEYVAL ( 0xFFE0 , "R15" ); + KEYVAL ( 0xFFE1 , "Shift_L" ); + KEYVAL ( 0xFFE2 , "Shift_R" ); + KEYVAL ( 0xFFE3 , "Control_L" ); + KEYVAL ( 0xFFE4 , "Control_R" ); + KEYVAL ( 0xFFE5 , "Caps_Lock" ); + KEYVAL ( 0xFFE6 , "Shift_Lock" ); + KEYVAL ( 0xFFE7 , "Meta_L" ); + KEYVAL ( 0xFFE8 , "Meta_R" ); + KEYVAL ( 0xFFE9 , "Alt_L" ); + KEYVAL ( 0xFFEA , "Alt_R" ); + KEYVAL ( 0xFFEB , "Super_L" ); + KEYVAL ( 0xFFEC , "Super_R" ); + KEYVAL ( 0xFFED , "Hyper_L" ); + KEYVAL ( 0xFFEE , "Hyper_R" ); + KEYVAL ( 0xFFFF , "Delete" ); + +/* 0xFFFFFF "VoidSymbol" */ +} diff --git a/desmume/src/gtk-glade/keyval_names.h b/src/gtk-glade/keyval_names.h old mode 100755 new mode 100644 similarity index 97% rename from desmume/src/gtk-glade/keyval_names.h rename to src/gtk-glade/keyval_names.h index d6bebf976..af314b3ff --- a/desmume/src/gtk-glade/keyval_names.h +++ b/src/gtk-glade/keyval_names.h @@ -1,23 +1,23 @@ -/* keyval_names.h - this file is part of DeSmuME - * - * Copyright (C) 2007 Damien Nozay (damdoum) - * Author: damdoum at users.sourceforge.net - * - * This file is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2, or (at your option) - * any later version. - * - * This file is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; see the file COPYING. If not, write to - * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -const char * KEYNAME(int k); -void init_keyvals(); +/* keyval_names.h - this file is part of DeSmuME + * + * Copyright (C) 2007 Damien Nozay (damdoum) + * Author: damdoum at users.sourceforge.net + * + * This file is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2, or (at your option) + * any later version. + * + * This file is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; see the file COPYING. If not, write to + * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +const char * KEYNAME(int k); +void init_keyvals(); diff --git a/desmume/src/gtk-glade/main.cpp b/src/gtk-glade/main.cpp old mode 100755 new mode 100644 similarity index 96% rename from desmume/src/gtk-glade/main.cpp rename to src/gtk-glade/main.cpp index 732b9feee..3602eb540 --- a/desmume/src/gtk-glade/main.cpp +++ b/src/gtk-glade/main.cpp @@ -1,638 +1,638 @@ -/* main.c - this file is part of DeSmuME - * - * Copyright (C) 2007 Damien Nozay (damdoum) - * Copyright (C) 2007 Pascal Giard (evilynux) - * Author: damdoum at users.sourceforge.net - * - * This file is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2, or (at your option) - * any later version. - * - * This file is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; see the file COPYING. If not, write to - * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -#include "callbacks.h" -#include "callbacks_IO.h" -#include "dTools/callbacks_dtools.h" -#include "globals.h" -#include "keyval_names.h" -#include "rasterize.h" -#include "desmume.h" - -#ifdef GDB_STUB -#include "../gdbstub.h" -#endif - -#ifdef GTKGLEXT_AVAILABLE -#include -#include "../OGLRender.h" -#include "gdk_3Demu.h" -#endif - -int glade_fps_limiter_disabled = 0; - -GtkWidget * pWindow; -GtkWidget * pDrawingArea, * pDrawingArea2; -GladeXML * xml, * xml_tools; - -const u16 gtk_kb_cfg[NB_KEYS] = - { - GDK_x, // A - GDK_z, // B - GDK_Shift_R, // select - GDK_Return, // start - GDK_Right, // Right - GDK_Left, // Left - GDK_Up, // Up - GDK_Down, // Down - GDK_w, // R - GDK_q, // L - GDK_s, // X - GDK_a, // Y - GDK_p, // DEBUG - GDK_o // BOOST - }; - -SoundInterface_struct *SNDCoreList[] = { -&SNDDummy, -&SNDDummy, -&SNDSDL, -NULL -}; - -GPU3DInterface *core3DList[] = { -&gpu3DNull, -&gpu3DRasterize -#ifdef GTKGLEXT_AVAILABLE - , - &gpu3Dgl -#endif -}; - -/* - * - * Command line handling - * - */ -struct configured_features { - int load_slot; - int software_colour_convert; - int opengl_2d; - int engine_3d; - int disable_limiter; - int savetype; - - u16 arm9_gdb_port; - u16 arm7_gdb_port; - - int firmware_language; - - const char *nds_file; -}; - -static void -init_configured_features( struct configured_features *config) { - config->load_slot = 0; - config->arm9_gdb_port = 0; - config->arm7_gdb_port = 0; - - config->software_colour_convert = 0; - - config->opengl_2d = 0; - config->engine_3d = 1; - - config->disable_limiter = 0; - config->savetype = 0; - - config->nds_file = NULL; - - /* use the default language */ - config->firmware_language = -1; -} - -static int -fill_configured_features( struct configured_features *config, - int argc, char ** argv) { - int good_args = 1; - int print_usage = 0; - int i; - - for ( i = 1; i < argc && good_args; i++) { - if ( strcmp( argv[i], "--help") == 0) { - g_print( _("USAGE: %s [OPTIONS] [nds-file]\n"), argv[0]); - g_print( _("OPTIONS:\n")); - g_print( _("\ - --load-slot=NUM Load game saved under NUM position.\n\n")); -#ifdef GTKGLEXT_AVAILABLE - g_print( _("\ - --soft-convert Use software colour conversion during OpenGL\n\ - screen rendering. May produce better or worse\n\ - frame rates depending on hardware.\n\n")); -#endif - g_print( _("\ - --3d-engine=ENGINE Selects 3D rendering engine\n\ - 0 = disabled\n\ - 1 = internal desmume rasterizer (default)\n")); -#ifdef GTKGLEXT_AVAILABLE - g_print( _("\ - 2 = gtkglext off-screen 3d opengl\n\n")); -#endif - g_print( _("\ - --disable-limiter Disables the 60 fps limiter\n\n")); - g_print( _("\ - --save-type=TYPE Selects savetype:\n\ - 0 = Autodetect (default)\n\ - 1 = EEPROM 4kbit\n\ - 2 = EEPROM 64kbit\n\ - 3 = EEPROM 512kbit\n\ - 4 = FRAM 256kbit\n\ - 5 = FLASH 2mbit\n\ - 6 = FLASH 4mbit\n\ - \n")); - g_print( _("\ - --fwlang=LANG Set the language in the firmware, LANG as follows:\n\ - 0 = Japanese\n\ - 1 = English\n\ - 2 = French\n\ - 3 = German\n\ - 4 = Italian\n\ - 5 = Spanish\n\n")); -#ifdef GDB_STUB - g_print( _("\ - --arm9gdb=PORT_NUM Enable the ARM9 GDB stub on the given port\n\ - --arm7gdb=PORT_NUM Enable the ARM7 GDB stub on the given port\n\n")); -#endif - g_print( _("\ - --help Display this message\n")); - //g_print(" --sticky Enable sticky keys and stylus\n"); - good_args = 0; - } - else if ( strncmp( argv[i], "--load-slot=", 12) == 0) { - char *end_char; - int slot = strtoul( &argv[i][12], &end_char, 10); - - if ( slot >= 0 && slot <= 10) { - config->load_slot = slot; - } - else { - g_printerr( _("I only know how to load from slots 1-10.\n")); - good_args = 0; - } - } -#ifdef GTKGLEXT_AVAILABLE - else if ( strcmp( argv[i], "--opengl-2d") == 0) { - // FIXME: to be implemented - config->opengl_2d = 1; - } - else if ( strcmp( argv[i], "--soft-convert") == 0) { - config->software_colour_convert = 1; - } -#define MAX3DEMU 2 -#else -#define MAX3DEMU 1 -#endif - else if ( strncmp( argv[i], "--3d-engine=", 12) == 0) { - char *end_char; - int engine = strtoul( &argv[i][12], &end_char, 10); - - if ( engine >= 0 && engine <= MAX3DEMU) { - config->engine_3d = engine; - } - else { - g_printerr( _("Supported 3d engines: 0, 1, and on some machines 2; use --help option for details\n")); - good_args = 0; - } - } - else if ( strncmp( argv[i], "--save-type=", 12) == 0) { - char *end_char; - int type = strtoul( &argv[i][12], &end_char, 10); - - if ( type >= 0 && type <= 6) { - config->savetype = type; - } - else { - g_printerr( _("select savetype from 0 to 6; use --help option for details\n")); - good_args = 0; - } - } - else if ( strncmp( argv[i], "--fwlang=", 9) == 0) { - char *end_char; - int lang = strtoul( &argv[i][9], &end_char, 10); - - if ( lang >= 0 && lang <= 5) { - config->firmware_language = lang; - } - else { - g_printerr( _("Firmware language must be set to a value from 0 to 5.\n")); - good_args = 0; - } - } -#ifdef GDB_STUB - else if ( strncmp( argv[i], "--arm9gdb=", 10) == 0) { - char *end_char; - unsigned long port_num = strtoul( &argv[i][10], &end_char, 10); - - if ( port_num > 0 && port_num < 65536) { - config->arm9_gdb_port = port_num; - } - else { - g_print( _("ARM9 GDB stub port must be in the range 1 to 65535\n")); - good_args = 0; - } - } - else if ( strncmp( argv[i], "--arm7gdb=", 10) == 0) { - char *end_char; - unsigned long port_num = strtoul( &argv[i][10], &end_char, 10); - - if ( port_num > 0 && port_num < 65536) { - config->arm7_gdb_port = port_num; - } - else { - g_print( _("ARM7 GDB stub port must be in the range 1 to 65535\n")); - good_args = 0; - } - } -#endif - else if ( strcmp( argv[i], "--disable-limiter") == 0) { - config->disable_limiter = 1; - } - else { - if ( config->nds_file == NULL) { - config->nds_file = argv[i]; - } - else { - g_print( _("NDS file (\"%s\") already set\n"), config->nds_file); - good_args = 0; - } - } - } - - if ( good_args) { - /* - * check if the configured features are consistant - */ - } - - if ( print_usage) { - g_print( _("USAGE: %s [options] [nds-file]\n"), argv[0]); - g_print( _("USAGE: %s --help - for help\n"), argv[0]); - } - - return good_args; -} - - - -/* ***** ***** TOOLS ***** ***** */ - -GList * tools_to_update = NULL; - -// register tool -void register_Tool(VoidFunPtr fun) { - tools_to_update = g_list_append(tools_to_update, (void *) fun); -} -void unregister_Tool(VoidFunPtr fun) { - if (tools_to_update == NULL) return; - tools_to_update = g_list_remove(tools_to_update, (void *) fun); -} - -static void notify_Tool (VoidFunPtr fun, gpointer func_data) { - fun(); -} - -void notify_Tools() { - g_list_foreach(tools_to_update, (GFunc)notify_Tool, NULL); -} - -/* Return the glade directory. - Note: See configure.ac for the value of GLADEUI_UNINSTALLED_DIR. */ -gchar * get_ui_file (const char *filename) -{ - gchar *path; - - /* looking in uninstalled (aka building) dir first */ - path = g_build_filename (GLADEUI_UNINSTALLED_DIR, filename, NULL); - if (g_file_test (path, G_FILE_TEST_IS_REGULAR)) return path; - g_free (path); - - /* looking in installed dir */ - path = g_build_filename (DATADIR, filename, NULL); - if (g_file_test (path, G_FILE_TEST_IS_REGULAR)) return path; - g_free (path); - - /* not found */ - return NULL; -} - - -/* ***** ***** CONFIG FILE ***** ***** */ -char * CONFIG_FILE; - -static int Read_ConfigFile() -{ - int i, tmp; - GKeyFile * keyfile = g_key_file_new(); - GError * error = NULL; - - load_default_config(gtk_kb_cfg); - - g_key_file_load_from_file(keyfile, CONFIG_FILE, G_KEY_FILE_NONE, 0); - - /* Load keypad keys */ - for(i = 0; i < NB_KEYS; i++) - { - tmp = g_key_file_get_integer(keyfile, "KEYS", key_names[i], &error); - if (error != NULL) { - g_error_free(error); - error = NULL; - } else { - keyboard_cfg[i] = tmp; - } - } - - /* Load joypad keys */ - for(i = 0; i < NB_KEYS; i++) - { - tmp = g_key_file_get_integer(keyfile, "JOYKEYS", key_names[i], &error); - if (error != NULL) { - g_error_free(error); - error = NULL; - } else { - joypad_cfg[i] = tmp; - } - } - - g_key_file_free(keyfile); - - return 0; -} - -static int Write_ConfigFile() -{ - int i; - GKeyFile * keyfile; - gchar *contents; - - keyfile = g_key_file_new(); - - for(i = 0; i < NB_KEYS; i++) - { - g_key_file_set_integer(keyfile, "KEYS", key_names[i], keyboard_cfg[i]); - g_key_file_set_integer(keyfile, "JOYKEYS", key_names[i], joypad_cfg[i]); - } - - contents = g_key_file_to_data(keyfile, 0, 0); - g_file_set_contents(CONFIG_FILE, contents, -1, 0); - g_free(contents); - - g_key_file_free(keyfile); - - return 0; -} - - -/* - * The thread handling functions needed by the GDB stub code. - */ -#ifdef GDB_STUB -void * -createThread_gdb( void (*thread_function)( void *data), - void *thread_data) { - GThread *new_thread = g_thread_create( (GThreadFunc)thread_function, - thread_data, - TRUE, - NULL); - - return new_thread; -} - -void -joinThread_gdb( void *thread_handle) { - g_thread_join((GThread *) thread_handle); -} -#endif - - -/* ***** ***** MAIN ***** ***** */ - -static int -common_gtk_glade_main( struct configured_features *my_config) { - /*SDL_TimerID limiter_timer;*/ -#ifdef GDB_STUB - gdbstub_handle_t arm9_gdb_stub; - gdbstub_handle_t arm7_gdb_stub; -#endif - struct armcpu_memory_iface *arm9_memio = &arm9_base_memory_iface; - struct armcpu_memory_iface *arm7_memio = &arm7_base_memory_iface; - struct armcpu_ctrl_iface *arm9_ctrl_iface; - struct armcpu_ctrl_iface *arm7_ctrl_iface; - /* the firmware settings */ - struct NDS_fw_config_data fw_config; - gchar *uifile; - - /* default the firmware settings, they may get changed later */ - NDS_FillDefaultFirmwareConfigData( &fw_config); - - /* use any language set on the command line */ - if ( my_config->firmware_language != -1) { - fw_config.language = my_config->firmware_language; - } - desmume_savetype(my_config->savetype); - -#ifdef GTKGLEXT_AVAILABLE -// check if you have GTHREAD when running configure script - //g_thread_init(NULL); - register_gl_fun(my_gl_Begin,my_gl_End); -#endif - init_keyvals(); - -#ifdef GDB_STUB - if ( my_config->arm9_gdb_port != 0) { - arm9_gdb_stub = createStub_gdb( my_config->arm9_gdb_port, - &arm9_memio, - &arm9_base_memory_iface); - - if ( arm9_gdb_stub == NULL) { - g_print( _("Failed to create ARM9 gdbstub on port %d\n"), - my_config->arm9_gdb_port); - return -1; - } - } - if ( my_config->arm7_gdb_port != 0) { - arm7_gdb_stub = createStub_gdb( my_config->arm7_gdb_port, - &arm7_memio, - &arm7_base_memory_iface); - - if ( arm7_gdb_stub == NULL) { - g_print( _("Failed to create ARM7 gdbstub on port %d\n"), - my_config->arm7_gdb_port); - return -1; - } - } -#endif - - if(SDL_Init( SDL_INIT_TIMER | SDL_INIT_VIDEO) == -1) - { - fprintf(stderr, _("Error trying to initialize SDL: %s\n"), - SDL_GetError()); - return 1; - } - - desmume_init( arm9_memio, &arm9_ctrl_iface, - arm7_memio, &arm7_ctrl_iface); - - - /* Create the dummy firmware */ - NDS_CreateDummyFirmware( &fw_config); - - /* - * Activate the GDB stubs - * This has to come after the NDS_Init (called in desmume_init) - * where the cpus are set up. - */ -#ifdef GDB_STUB - if ( my_config->arm9_gdb_port != 0) { - activateStub_gdb( arm9_gdb_stub, arm9_ctrl_iface); - } - if ( my_config->arm7_gdb_port != 0) { - activateStub_gdb( arm7_gdb_stub, arm7_ctrl_iface); - } -#endif - - /* Initialize joysticks */ - if(!init_joy()) return 1; - - CONFIG_FILE = g_build_filename(g_get_home_dir(), ".desmume.ini", NULL); - Read_ConfigFile(); - - /* load the interface */ - uifile = get_ui_file("DeSmuMe.glade"); - xml = glade_xml_new(uifile, NULL, NULL); - g_free (uifile); - uifile = get_ui_file("DeSmuMe_Dtools.glade"); - xml_tools = glade_xml_new(uifile, NULL, NULL); - g_free (uifile); - pWindow = glade_xml_get_widget(xml, "wMainW"); - pDrawingArea = glade_xml_get_widget(xml, "wDraw_Main"); - pDrawingArea2 = glade_xml_get_widget(xml, "wDraw_Sub"); - - { - char wdgName[40]; - snprintf(wdgName, 39, "savetype%d", my_config->savetype+1); - GtkWidget * wdgt = glade_xml_get_widget(xml, wdgName); - gtk_check_menu_item_set_active (GTK_CHECK_MENU_ITEM (wdgt), TRUE); - } - - /* connect the signals in the interface */ - glade_xml_signal_autoconnect_StringObject(xml); - glade_xml_signal_autoconnect_StringObject(xml_tools); - - init_GL_capabilities( my_config->software_colour_convert); - - /* check command line file */ - if( my_config->nds_file) { - if(desmume_open( my_config->nds_file) >= 0) { - loadstate_slot( my_config->load_slot); - desmume_resume(); - enable_rom_features(); - } else { - GtkWidget *pDialog = gtk_message_dialog_new(GTK_WINDOW(pWindow), - GTK_DIALOG_MODAL, - GTK_MESSAGE_INFO, - GTK_BUTTONS_OK, - _("Unable to load :\n%s"), my_config->nds_file); - gtk_dialog_run(GTK_DIALOG(pDialog)); - gtk_widget_destroy(pDialog); - } - } - - gtk_widget_show(pDrawingArea); - gtk_widget_show(pDrawingArea2); - - { - int engine = my_config->engine_3d; - -#ifdef GTKGLEXT_AVAILABLE - if ( my_config->engine_3d==2 ) - /* setup the gdk 3D emulation */ - if(!init_opengl_gdk_3Demu(GDK_DRAWABLE(pWindow->window))){ - fprintf( stderr, _("Failed to initialise openGL 3D emulation; " - "removing 3D support\n")); - engine = 0; - } -#endif - NDS_3D_ChangeCore(engine); - if(my_config->engine_3d != 0 && gpu3D == GPU3D_NULL) - fprintf(stderr, _("Failed to setup 3D engine; removing 3D support\n")); - } - -// on_menu_tileview_activate(NULL,NULL); - - /* setup the frame limiter and indicate if it is disabled */ - glade_fps_limiter_disabled = my_config->disable_limiter; - - /* start event loop */ - gtk_main(); - desmume_free(); - - /* Unload joystick */ - uninit_joy(); - - SDL_Quit(); - Write_ConfigFile(); - return EXIT_SUCCESS; -} - -int main(int argc, char *argv[]) { - struct configured_features my_config; - - // Localization - bindtextdomain (GETTEXT_PACKAGE, LOCALEDIR); - bind_textdomain_codeset (GETTEXT_PACKAGE, "UTF-8"); - textdomain (GETTEXT_PACKAGE); - - init_configured_features( &my_config); - - if (!g_thread_supported()) - g_thread_init( NULL); - - gtk_init(&argc, &argv); - -#ifdef GTKGLEXT_AVAILABLE - gtk_gl_init( &argc, &argv); -#endif - - if ( !fill_configured_features( &my_config, argc, argv)) { - exit(0); - } - - return common_gtk_glade_main( &my_config); -} - - -#ifdef WIN32 -int WinMain ( HINSTANCE hThisInstance, HINSTANCE hPrevInstance, - LPSTR lpszArgument, int nFunsterStil) -{ - int argc = 0; - char *argv[] = NULL; - - /* - * FIXME: - * Emulate the argc and argv main parameters. Could do this using - * CommandLineToArgvW and then convert the wide chars to thin chars. - * Or parse the wide chars directly and call common_gtk_glade_main with a - * filled configuration structure. - */ - main( argc, argv); -} -#endif +/* main.c - this file is part of DeSmuME + * + * Copyright (C) 2007 Damien Nozay (damdoum) + * Copyright (C) 2007 Pascal Giard (evilynux) + * Author: damdoum at users.sourceforge.net + * + * This file is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2, or (at your option) + * any later version. + * + * This file is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; see the file COPYING. If not, write to + * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#include "callbacks.h" +#include "callbacks_IO.h" +#include "dTools/callbacks_dtools.h" +#include "globals.h" +#include "keyval_names.h" +#include "rasterize.h" +#include "desmume.h" + +#ifdef GDB_STUB +#include "../gdbstub.h" +#endif + +#ifdef GTKGLEXT_AVAILABLE +#include +#include "../OGLRender.h" +#include "gdk_3Demu.h" +#endif + +int glade_fps_limiter_disabled = 0; + +GtkWidget * pWindow; +GtkWidget * pDrawingArea, * pDrawingArea2; +GladeXML * xml, * xml_tools; + +const u16 gtk_kb_cfg[NB_KEYS] = + { + GDK_x, // A + GDK_z, // B + GDK_Shift_R, // select + GDK_Return, // start + GDK_Right, // Right + GDK_Left, // Left + GDK_Up, // Up + GDK_Down, // Down + GDK_w, // R + GDK_q, // L + GDK_s, // X + GDK_a, // Y + GDK_p, // DEBUG + GDK_o // BOOST + }; + +SoundInterface_struct *SNDCoreList[] = { +&SNDDummy, +&SNDFile, +&SNDSDL, +NULL +}; + +GPU3DInterface *core3DList[] = { +&gpu3DNull, +&gpu3DRasterize +#ifdef GTKGLEXT_AVAILABLE + , + &gpu3Dgl +#endif +}; + +/* + * + * Command line handling + * + */ +struct configured_features { + int load_slot; + int software_colour_convert; + int opengl_2d; + int engine_3d; + int disable_limiter; + int savetype; + + u16 arm9_gdb_port; + u16 arm7_gdb_port; + + int firmware_language; + + const char *nds_file; +}; + +static void +init_configured_features( struct configured_features *config) { + config->load_slot = 0; + config->arm9_gdb_port = 0; + config->arm7_gdb_port = 0; + + config->software_colour_convert = 0; + + config->opengl_2d = 0; + config->engine_3d = 1; + + config->disable_limiter = 0; + config->savetype = 0; + + config->nds_file = NULL; + + /* use the default language */ + config->firmware_language = -1; +} + +static int +fill_configured_features( struct configured_features *config, + int argc, char ** argv) { + int good_args = 1; + int print_usage = 0; + int i; + + for ( i = 1; i < argc && good_args; i++) { + if ( strcmp( argv[i], "--help") == 0) { + g_print( _("USAGE: %s [OPTIONS] [nds-file]\n"), argv[0]); + g_print( _("OPTIONS:\n")); + g_print( _("\ + --load-slot=NUM Load game saved under NUM position.\n\n")); +#ifdef GTKGLEXT_AVAILABLE + g_print( _("\ + --soft-convert Use software colour conversion during OpenGL\n\ + screen rendering. May produce better or worse\n\ + frame rates depending on hardware.\n\n")); +#endif + g_print( _("\ + --3d-engine=ENGINE Selects 3D rendering engine\n\ + 0 = disabled\n\ + 1 = internal desmume rasterizer (default)\n")); +#ifdef GTKGLEXT_AVAILABLE + g_print( _("\ + 2 = gtkglext off-screen 3d opengl\n\n")); +#endif + g_print( _("\ + --disable-limiter Disables the 60 fps limiter\n\n")); + g_print( _("\ + --save-type=TYPE Selects savetype:\n\ + 0 = Autodetect (default)\n\ + 1 = EEPROM 4kbit\n\ + 2 = EEPROM 64kbit\n\ + 3 = EEPROM 512kbit\n\ + 4 = FRAM 256kbit\n\ + 5 = FLASH 2mbit\n\ + 6 = FLASH 4mbit\n\ + \n")); + g_print( _("\ + --fwlang=LANG Set the language in the firmware, LANG as follows:\n\ + 0 = Japanese\n\ + 1 = English\n\ + 2 = French\n\ + 3 = German\n\ + 4 = Italian\n\ + 5 = Spanish\n\n")); +#ifdef GDB_STUB + g_print( _("\ + --arm9gdb=PORT_NUM Enable the ARM9 GDB stub on the given port\n\ + --arm7gdb=PORT_NUM Enable the ARM7 GDB stub on the given port\n\n")); +#endif + g_print( _("\ + --help Display this message\n")); + //g_print(" --sticky Enable sticky keys and stylus\n"); + good_args = 0; + } + else if ( strncmp( argv[i], "--load-slot=", 12) == 0) { + char *end_char; + int slot = strtoul( &argv[i][12], &end_char, 10); + + if ( slot >= 0 && slot <= 10) { + config->load_slot = slot; + } + else { + g_printerr( _("I only know how to load from slots 1-10.\n")); + good_args = 0; + } + } +#ifdef GTKGLEXT_AVAILABLE + else if ( strcmp( argv[i], "--opengl-2d") == 0) { + // FIXME: to be implemented + config->opengl_2d = 1; + } + else if ( strcmp( argv[i], "--soft-convert") == 0) { + config->software_colour_convert = 1; + } +#define MAX3DEMU 2 +#else +#define MAX3DEMU 1 +#endif + else if ( strncmp( argv[i], "--3d-engine=", 12) == 0) { + char *end_char; + int engine = strtoul( &argv[i][12], &end_char, 10); + + if ( engine >= 0 && engine <= MAX3DEMU) { + config->engine_3d = engine; + } + else { + g_printerr( _("Supported 3d engines: 0, 1, and on some machines 2; use --help option for details\n")); + good_args = 0; + } + } + else if ( strncmp( argv[i], "--save-type=", 12) == 0) { + char *end_char; + int type = strtoul( &argv[i][12], &end_char, 10); + + if ( type >= 0 && type <= 6) { + config->savetype = type; + } + else { + g_printerr( _("select savetype from 0 to 6; use --help option for details\n")); + good_args = 0; + } + } + else if ( strncmp( argv[i], "--fwlang=", 9) == 0) { + char *end_char; + int lang = strtoul( &argv[i][9], &end_char, 10); + + if ( lang >= 0 && lang <= 5) { + config->firmware_language = lang; + } + else { + g_printerr( _("Firmware language must be set to a value from 0 to 5.\n")); + good_args = 0; + } + } +#ifdef GDB_STUB + else if ( strncmp( argv[i], "--arm9gdb=", 10) == 0) { + char *end_char; + unsigned long port_num = strtoul( &argv[i][10], &end_char, 10); + + if ( port_num > 0 && port_num < 65536) { + config->arm9_gdb_port = port_num; + } + else { + g_print( _("ARM9 GDB stub port must be in the range 1 to 65535\n")); + good_args = 0; + } + } + else if ( strncmp( argv[i], "--arm7gdb=", 10) == 0) { + char *end_char; + unsigned long port_num = strtoul( &argv[i][10], &end_char, 10); + + if ( port_num > 0 && port_num < 65536) { + config->arm7_gdb_port = port_num; + } + else { + g_print( _("ARM7 GDB stub port must be in the range 1 to 65535\n")); + good_args = 0; + } + } +#endif + else if ( strcmp( argv[i], "--disable-limiter") == 0) { + config->disable_limiter = 1; + } + else { + if ( config->nds_file == NULL) { + config->nds_file = argv[i]; + } + else { + g_print( _("NDS file (\"%s\") already set\n"), config->nds_file); + good_args = 0; + } + } + } + + if ( good_args) { + /* + * check if the configured features are consistant + */ + } + + if ( print_usage) { + g_print( _("USAGE: %s [options] [nds-file]\n"), argv[0]); + g_print( _("USAGE: %s --help - for help\n"), argv[0]); + } + + return good_args; +} + + + +/* ***** ***** TOOLS ***** ***** */ + +GList * tools_to_update = NULL; + +// register tool +void register_Tool(VoidFunPtr fun) { + tools_to_update = g_list_append(tools_to_update, (void *) fun); +} +void unregister_Tool(VoidFunPtr fun) { + if (tools_to_update == NULL) return; + tools_to_update = g_list_remove(tools_to_update, (void *) fun); +} + +static void notify_Tool (VoidFunPtr fun, gpointer func_data) { + fun(); +} + +void notify_Tools() { + g_list_foreach(tools_to_update, (GFunc)notify_Tool, NULL); +} + +/* Return the glade directory. + Note: See configure.ac for the value of GLADEUI_UNINSTALLED_DIR. */ +gchar * get_ui_file (const char *filename) +{ + gchar *path; + + /* looking in uninstalled (aka building) dir first */ + path = g_build_filename (GLADEUI_UNINSTALLED_DIR, filename, NULL); + if (g_file_test (path, G_FILE_TEST_IS_REGULAR)) return path; + g_free (path); + + /* looking in installed dir */ + path = g_build_filename (DATADIR, filename, NULL); + if (g_file_test (path, G_FILE_TEST_IS_REGULAR)) return path; + g_free (path); + + /* not found */ + return NULL; +} + + +/* ***** ***** CONFIG FILE ***** ***** */ +char * CONFIG_FILE; + +static int Read_ConfigFile() +{ + int i, tmp; + GKeyFile * keyfile = g_key_file_new(); + GError * error = NULL; + + load_default_config(gtk_kb_cfg); + + g_key_file_load_from_file(keyfile, CONFIG_FILE, G_KEY_FILE_NONE, 0); + + /* Load keypad keys */ + for(i = 0; i < NB_KEYS; i++) + { + tmp = g_key_file_get_integer(keyfile, "KEYS", key_names[i], &error); + if (error != NULL) { + g_error_free(error); + error = NULL; + } else { + keyboard_cfg[i] = tmp; + } + } + + /* Load joypad keys */ + for(i = 0; i < NB_KEYS; i++) + { + tmp = g_key_file_get_integer(keyfile, "JOYKEYS", key_names[i], &error); + if (error != NULL) { + g_error_free(error); + error = NULL; + } else { + joypad_cfg[i] = tmp; + } + } + + g_key_file_free(keyfile); + + return 0; +} + +static int Write_ConfigFile() +{ + int i; + GKeyFile * keyfile; + gchar *contents; + + keyfile = g_key_file_new(); + + for(i = 0; i < NB_KEYS; i++) + { + g_key_file_set_integer(keyfile, "KEYS", key_names[i], keyboard_cfg[i]); + g_key_file_set_integer(keyfile, "JOYKEYS", key_names[i], joypad_cfg[i]); + } + + contents = g_key_file_to_data(keyfile, 0, 0); + g_file_set_contents(CONFIG_FILE, contents, -1, 0); + g_free(contents); + + g_key_file_free(keyfile); + + return 0; +} + + +/* + * The thread handling functions needed by the GDB stub code. + */ +#ifdef GDB_STUB +void * +createThread_gdb( void (*thread_function)( void *data), + void *thread_data) { + GThread *new_thread = g_thread_create( (GThreadFunc)thread_function, + thread_data, + TRUE, + NULL); + + return new_thread; +} + +void +joinThread_gdb( void *thread_handle) { + g_thread_join((GThread *) thread_handle); +} +#endif + + +/* ***** ***** MAIN ***** ***** */ + +static int +common_gtk_glade_main( struct configured_features *my_config) { + /*SDL_TimerID limiter_timer;*/ +#ifdef GDB_STUB + gdbstub_handle_t arm9_gdb_stub; + gdbstub_handle_t arm7_gdb_stub; +#endif + struct armcpu_memory_iface *arm9_memio = &arm9_base_memory_iface; + struct armcpu_memory_iface *arm7_memio = &arm7_base_memory_iface; + struct armcpu_ctrl_iface *arm9_ctrl_iface; + struct armcpu_ctrl_iface *arm7_ctrl_iface; + /* the firmware settings */ + struct NDS_fw_config_data fw_config; + gchar *uifile; + + /* default the firmware settings, they may get changed later */ + NDS_FillDefaultFirmwareConfigData( &fw_config); + + /* use any language set on the command line */ + if ( my_config->firmware_language != -1) { + fw_config.language = my_config->firmware_language; + } + desmume_savetype(my_config->savetype); + +#ifdef GTKGLEXT_AVAILABLE +// check if you have GTHREAD when running configure script + //g_thread_init(NULL); + register_gl_fun(my_gl_Begin,my_gl_End); +#endif + init_keyvals(); + +#ifdef GDB_STUB + if ( my_config->arm9_gdb_port != 0) { + arm9_gdb_stub = createStub_gdb( my_config->arm9_gdb_port, + &arm9_memio, + &arm9_base_memory_iface); + + if ( arm9_gdb_stub == NULL) { + g_print( _("Failed to create ARM9 gdbstub on port %d\n"), + my_config->arm9_gdb_port); + return -1; + } + } + if ( my_config->arm7_gdb_port != 0) { + arm7_gdb_stub = createStub_gdb( my_config->arm7_gdb_port, + &arm7_memio, + &arm7_base_memory_iface); + + if ( arm7_gdb_stub == NULL) { + g_print( _("Failed to create ARM7 gdbstub on port %d\n"), + my_config->arm7_gdb_port); + return -1; + } + } +#endif + + if(SDL_Init( SDL_INIT_TIMER | SDL_INIT_VIDEO) == -1) + { + fprintf(stderr, _("Error trying to initialize SDL: %s\n"), + SDL_GetError()); + return 1; + } + + desmume_init( arm9_memio, &arm9_ctrl_iface, + arm7_memio, &arm7_ctrl_iface); + + + /* Create the dummy firmware */ + NDS_CreateDummyFirmware( &fw_config); + + /* + * Activate the GDB stubs + * This has to come after the NDS_Init (called in desmume_init) + * where the cpus are set up. + */ +#ifdef GDB_STUB + if ( my_config->arm9_gdb_port != 0) { + activateStub_gdb( arm9_gdb_stub, arm9_ctrl_iface); + } + if ( my_config->arm7_gdb_port != 0) { + activateStub_gdb( arm7_gdb_stub, arm7_ctrl_iface); + } +#endif + + /* Initialize joysticks */ + if(!init_joy()) return 1; + + CONFIG_FILE = g_build_filename(g_get_home_dir(), ".desmume.ini", NULL); + Read_ConfigFile(); + + /* load the interface */ + uifile = get_ui_file("DeSmuMe.glade"); + xml = glade_xml_new(uifile, NULL, NULL); + g_free (uifile); + uifile = get_ui_file("DeSmuMe_Dtools.glade"); + xml_tools = glade_xml_new(uifile, NULL, NULL); + g_free (uifile); + pWindow = glade_xml_get_widget(xml, "wMainW"); + pDrawingArea = glade_xml_get_widget(xml, "wDraw_Main"); + pDrawingArea2 = glade_xml_get_widget(xml, "wDraw_Sub"); + + { + char wdgName[40]; + snprintf(wdgName, 39, "savetype%d", my_config->savetype+1); + GtkWidget * wdgt = glade_xml_get_widget(xml, wdgName); + gtk_check_menu_item_set_active (GTK_CHECK_MENU_ITEM (wdgt), TRUE); + } + + /* connect the signals in the interface */ + glade_xml_signal_autoconnect_StringObject(xml); + glade_xml_signal_autoconnect_StringObject(xml_tools); + + init_GL_capabilities( my_config->software_colour_convert); + + /* check command line file */ + if( my_config->nds_file) { + if(desmume_open( my_config->nds_file) >= 0) { + loadstate_slot( my_config->load_slot); + desmume_resume(); + enable_rom_features(); + } else { + GtkWidget *pDialog = gtk_message_dialog_new(GTK_WINDOW(pWindow), + GTK_DIALOG_MODAL, + GTK_MESSAGE_INFO, + GTK_BUTTONS_OK, + _("Unable to load :\n%s"), my_config->nds_file); + gtk_dialog_run(GTK_DIALOG(pDialog)); + gtk_widget_destroy(pDialog); + } + } + + gtk_widget_show(pDrawingArea); + gtk_widget_show(pDrawingArea2); + + { + int engine = my_config->engine_3d; + +#ifdef GTKGLEXT_AVAILABLE + if ( my_config->engine_3d==2 ) + /* setup the gdk 3D emulation */ + if(!init_opengl_gdk_3Demu(GDK_DRAWABLE(pWindow->window))){ + fprintf( stderr, _("Failed to initialise openGL 3D emulation; " + "removing 3D support\n")); + engine = 0; + } +#endif + NDS_3D_ChangeCore(engine); + if(my_config->engine_3d != 0 && gpu3D == GPU3D_NULL) + fprintf(stderr, _("Failed to setup 3D engine; removing 3D support\n")); + } + +// on_menu_tileview_activate(NULL,NULL); + + /* setup the frame limiter and indicate if it is disabled */ + glade_fps_limiter_disabled = my_config->disable_limiter; + + /* start event loop */ + gtk_main(); + desmume_free(); + + /* Unload joystick */ + uninit_joy(); + + SDL_Quit(); + Write_ConfigFile(); + return EXIT_SUCCESS; +} + +int main(int argc, char *argv[]) { + struct configured_features my_config; + + // Localization + bindtextdomain (GETTEXT_PACKAGE, LOCALEDIR); + bind_textdomain_codeset (GETTEXT_PACKAGE, "UTF-8"); + textdomain (GETTEXT_PACKAGE); + + init_configured_features( &my_config); + + if (!g_thread_supported()) + g_thread_init( NULL); + + gtk_init(&argc, &argv); + +#ifdef GTKGLEXT_AVAILABLE + gtk_gl_init( &argc, &argv); +#endif + + if ( !fill_configured_features( &my_config, argc, argv)) { + exit(0); + } + + return common_gtk_glade_main( &my_config); +} + + +#ifdef WIN32 +int WinMain ( HINSTANCE hThisInstance, HINSTANCE hPrevInstance, + LPSTR lpszArgument, int nFunsterStil) +{ + int argc = 0; + char *argv[] = NULL; + + /* + * FIXME: + * Emulate the argc and argv main parameters. Could do this using + * CommandLineToArgvW and then convert the wide chars to thin chars. + * Or parse the wide chars directly and call common_gtk_glade_main with a + * filled configuration structure. + */ + main( argc, argv); +} +#endif diff --git a/desmume/src/gtk/DeSmuME.xpm b/src/gtk/DeSmuME.xpm similarity index 100% rename from desmume/src/gtk/DeSmuME.xpm rename to src/gtk/DeSmuME.xpm diff --git a/desmume/src/gtk/Makefile.am b/src/gtk/Makefile.am similarity index 50% rename from desmume/src/gtk/Makefile.am rename to src/gtk/Makefile.am index 28034aa19..be1eb281f 100644 --- a/desmume/src/gtk/Makefile.am +++ b/src/gtk/Makefile.am @@ -1,7 +1,7 @@ SUBDIRS = doc include $(top_srcdir)/src/desmume.mk -AM_CPPFLAGS += $(SDL_CFLAGS) $(GTK_CFLAGS) $(GTHREAD_CFLAGS) $(ALSA_CFLAGS) $(LIBAGG_CFLAGS) +AM_CPPFLAGS += $(SDL_CFLAGS) $(GTK_CFLAGS) $(GTHREAD_CFLAGS) Applicationsdir = $(datadir)/applications Applications_DATA = desmume.desktop @@ -16,25 +16,10 @@ desmume_SOURCES = \ ../sndsdl.cpp \ ../ctrlssdl.h ../ctrlssdl.cpp \ osmesa_3Demu.cpp osmesa_3Demu.h \ - desmume_config.cpp desmume_config.h \ - cheatsGTK.h cheatsGTK.cpp \ - main.cpp main.h + desmume_config.cpp \ + main.cpp desmume_LDADD = ../libdesmume.a \ - $(SDL_LIBS) $(GTK_LIBS) $(GTHREAD_LIBS) $(ALSA_LIBS) $(LIBAGG_LIBS) + $(SDL_LIBS) $(GTK_LIBS) $(GTHREAD_LIBS) if HAVE_GDB_STUB desmume_LDADD += ../gdbstub/libgdbstub.a endif - -UPDATE_DESKTOP = \ - appsdir=$(DESTDIR)$(datadir)/applications ; \ - if [ -f $$appsdir/mimeinfo.cache ] ; then \ - if test ! "x$(UPDATEDESKTOP)" = "x" ; then \ - $(UPDATEDESKTOP) $$appsdir ; \ - fi \ - fi - -install-data-hook: - $(UPDATE_DESKTOP) - -uninstall-hook: - $(UPDATE_DESKTOP) diff --git a/desmume/src/gtk/dTool.h b/src/gtk/dTool.h similarity index 75% rename from desmume/src/gtk/dTool.h rename to src/gtk/dTool.h index 82685b3f7..5754b9399 100644 --- a/desmume/src/gtk/dTool.h +++ b/src/gtk/dTool.h @@ -1,23 +1,21 @@ -#ifndef __DTOOL_H__ -#define __DTOOL_H__ - -#include "../types.h" -#include "../registers.h" - -typedef void (*dTool_openFn)(int id); -typedef void (*dTool_updateFn)(); -typedef void (*dTool_closeFn)(); - -typedef struct -{ - /* this should be the same name of the action in the gui xml */ - const char shortname[16]; - const char name[32]; - dTool_openFn open; - dTool_updateFn update; - dTool_closeFn close; -} dTool_t; - -extern void dTool_CloseCallback(int id); - -#endif /*__DTOOL_H__*/ +#ifndef __DTOOL_H__ +#define __DTOOL_H__ + +#include "../types.h" +#include "../registers.h" + +typedef void (*dTool_openFn)(int id); +typedef void (*dTool_updateFn)(); +typedef void (*dTool_closeFn)(); + +typedef struct +{ + const char name[64]; + dTool_openFn open; + dTool_updateFn update; + dTool_closeFn close; +} dTool_t; + +extern void dTool_CloseCallback(int id); + +#endif /*__DTOOL_H__*/ diff --git a/desmume/src/gtk/dToolsList.cpp b/src/gtk/dToolsList.cpp similarity index 94% rename from desmume/src/gtk/dToolsList.cpp rename to src/gtk/dToolsList.cpp index 1b7e24d16..7be4db0cb 100644 --- a/desmume/src/gtk/dToolsList.cpp +++ b/src/gtk/dToolsList.cpp @@ -1,31 +1,31 @@ -/* dToolsList.cpp - * - * Copyright (C) 2006 Thoduv - * - * This file is part of DeSmuME - * - * DeSmuME is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * DeSmuME is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with DeSmuME; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -*/ - -#include "dTool.h" -#include "tools/ioregsView.h" - -dTool_t *dTools_list[] = -{ - &dTool_ioregsView -}; - -int dTools_list_size = ARRAY_SIZE(dTools_list); - +/* dToolsList.cpp + * + * Copyright (C) 2006 Thoduv + * + * This file is part of DeSmuME + * + * DeSmuME is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * DeSmuME is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with DeSmuME; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA +*/ + +#include "dTool.h" +#include "tools/ioregsView.h" + +dTool_t *dTools_list[] = +{ + &dTool_ioregsView +}; + +int dTools_list_size = 1; + diff --git a/desmume/src/gtk/desmume.cpp b/src/gtk/desmume.cpp similarity index 90% rename from desmume/src/gtk/desmume.cpp rename to src/gtk/desmume.cpp index 600da1d55..1a1206ca2 100644 --- a/desmume/src/gtk/desmume.cpp +++ b/src/gtk/desmume.cpp @@ -1,92 +1,92 @@ -/* desmume.c - this file is part of DeSmuME - * - * Copyright (C) 2006,2007 DeSmuME Team - * Copyright (C) 2007 Pascal Giard (evilynux) - * - * This file is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2, or (at your option) - * any later version. - * - * This file is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; see the file COPYING. If not, write to - * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -#include "types.h" -#include "NDSSystem.h" -#include "SPU.h" -#include "sndsdl.h" -#include "ctrlssdl.h" -#include "desmume.h" -#include "movie.h" - -volatile BOOL execute = FALSE; -BOOL click = FALSE; - -void desmume_init( struct armcpu_memory_iface *arm9_mem_if, - struct armcpu_ctrl_iface **arm9_ctrl_iface, - struct armcpu_memory_iface *arm7_mem_if, - struct armcpu_ctrl_iface **arm7_ctrl_iface, - int disable_sound) -{ -#ifdef GDB_STUB - NDS_Init( arm9_mem_if, arm9_ctrl_iface, - arm7_mem_if, arm7_ctrl_iface); -#else - NDS_Init(); -#endif - if ( !disable_sound) { - SPU_ChangeSoundCore(SNDCORE_SDL, 735 * 4); - } - execute = FALSE; -} - -void desmume_free( void) -{ - execute = FALSE; - NDS_DeInit(); -} - -void desmume_pause( void) -{ - execute = FALSE; - SPU_Pause(1); -} -void desmume_resume( void) -{ - execute = TRUE; - SPU_Pause(0); -} -void desmume_toggle( void) -{ - execute = (execute) ? FALSE : TRUE; -} -BOOL desmume_running( void) -{ - return execute; -} - -void desmume_cycle( void) -{ - u16 keypad; - - /* Joystick events */ - /* Retrieve old value: can use joysticks w/ another device (from our side) */ - keypad = get_keypad(); - /* Look for queued events */ - process_joystick_events( &keypad); - /* Update keypad value */ - update_keypad(keypad); - - FCEUMOV_AddInputState(); - NDS_exec(); - SPU_Emulate_user(); -} - +/* desmume.c - this file is part of DeSmuME + * + * Copyright (C) 2006,2007 DeSmuME Team + * Copyright (C) 2007 Pascal Giard (evilynux) + * + * This file is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2, or (at your option) + * any later version. + * + * This file is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; see the file COPYING. If not, write to + * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#include "types.h" +#include "NDSSystem.h" +#include "SPU.h" +#include "sndsdl.h" +#include "ctrlssdl.h" +#include "desmume.h" + +volatile BOOL execute = FALSE; +BOOL click = FALSE; + +void desmume_init( struct armcpu_memory_iface *arm9_mem_if, + struct armcpu_ctrl_iface **arm9_ctrl_iface, + struct armcpu_memory_iface *arm7_mem_if, + struct armcpu_ctrl_iface **arm7_ctrl_iface, + int disable_sound) +{ +#ifdef GDB_STUB + NDS_Init( arm9_mem_if, arm9_ctrl_iface, + arm7_mem_if, arm7_ctrl_iface); +#else + NDS_Init(); +#endif + if ( !disable_sound) { + SPU_ChangeSoundCore(SNDCORE_SDL, 735 * 4); + } + execute = FALSE; +} + +void desmume_free( void) +{ + execute = FALSE; + NDS_DeInit(); +} + +void desmume_pause( void) +{ + execute = FALSE; + SPU_Pause(1); +} +void desmume_resume( void) +{ + execute = TRUE; + SPU_Pause(0); +} +void desmume_toggle( void) +{ + execute = (execute) ? FALSE : TRUE; +} +BOOL desmume_running( void) +{ + return execute; +} + +void desmume_cycle( void) +{ + static u32 desmume_last_cycle; + u16 keypad; + + /* Joystick events */ + /* Retrieve old value: can use joysticks w/ another device (from our side) */ + keypad = get_keypad(); + /* Look for queued events */ + process_joystick_events( &keypad); + /* Update keypad value */ + update_keypad(keypad); + + desmume_last_cycle = NDS_exec((560190 << 1) - desmume_last_cycle); + SPU_Emulate_user(); + SPU_Emulate_core(); +} + diff --git a/desmume/src/gtk/desmume.desktop b/src/gtk/desmume.desktop similarity index 81% rename from desmume/src/gtk/desmume.desktop rename to src/gtk/desmume.desktop index cae4c8eba..1868030b1 100644 --- a/desmume/src/gtk/desmume.desktop +++ b/src/gtk/desmume.desktop @@ -7,4 +7,3 @@ TryExec=desmume Exec=desmume Icon=DeSmuME Categories=GNOME;GTK;Game;Emulator; -MimeType=application/x-nintendo-ds-rom; diff --git a/desmume/src/gtk/desmume.h b/src/gtk/desmume.h similarity index 97% rename from desmume/src/gtk/desmume.h rename to src/gtk/desmume.h index 883982183..5695521e2 100644 --- a/desmume/src/gtk/desmume.h +++ b/src/gtk/desmume.h @@ -1,40 +1,40 @@ -/* desmume.h - this file is part of DeSmuME - * - * Copyright (C) 2006,2007 DeSmuME Team - * Copyright (C) 2007 Pascal Giard (evilynux) - * - * This file is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2, or (at your option) - * any later version. - * - * This file is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; see the file COPYING. If not, write to - * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -#ifndef __DESMUME_H__ -#define __DESMUME_H__ - -extern void desmume_init( struct armcpu_memory_iface *arm9_mem_if, - struct armcpu_ctrl_iface **arm9_ctrl_iface, - struct armcpu_memory_iface *arm7_mem_if, - struct armcpu_ctrl_iface **arm7_ctrl_iface, - int disable_sound); -extern void desmume_free( void); - -extern void desmume_pause( void); -extern void desmume_resume( void); -extern void desmume_toggle( void); -extern BOOL desmume_running( void); - -extern void desmume_cycle( void); - -#endif /*__DESMUME_H__*/ - +/* desmume.h - this file is part of DeSmuME + * + * Copyright (C) 2006,2007 DeSmuME Team + * Copyright (C) 2007 Pascal Giard (evilynux) + * + * This file is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2, or (at your option) + * any later version. + * + * This file is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; see the file COPYING. If not, write to + * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#ifndef __DESMUME_H__ +#define __DESMUME_H__ + +extern void desmume_init( struct armcpu_memory_iface *arm9_mem_if, + struct armcpu_ctrl_iface **arm9_ctrl_iface, + struct armcpu_memory_iface *arm7_mem_if, + struct armcpu_ctrl_iface **arm7_ctrl_iface, + int disable_sound); +extern void desmume_free( void); + +extern void desmume_pause( void); +extern void desmume_resume( void); +extern void desmume_toggle( void); +extern BOOL desmume_running( void); + +extern void desmume_cycle( void); + +#endif /*__DESMUME_H__*/ + diff --git a/desmume/src/gtk/desmume_config.cpp b/src/gtk/desmume_config.cpp similarity index 96% rename from desmume/src/gtk/desmume_config.cpp rename to src/gtk/desmume_config.cpp index bb5406c0b..4403ce285 100644 --- a/desmume/src/gtk/desmume_config.cpp +++ b/src/gtk/desmume_config.cpp @@ -1,147 +1,147 @@ -/* main.c - this file is part of DeSmuME - * - * Copyright (C) 2009 DeSmuME Team - * - * This file is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2, or (at your option) - * any later version. - * - * This file is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; see the file COPYING. If not, write to - * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -#include -#include - -#include "ctrlssdl.h" -#include "desmume_config.h" - -static const gchar *desmume_config_file = ".desmume.ini"; -static const u16 gtk_kb_cfg[NB_KEYS] = { - GDK_x, // A - GDK_z, // B - GDK_Shift_R, // select - GDK_Return, // start - GDK_Right, // Right - GDK_Left, // Left - GDK_Up, // Up - GDK_Down, // Down - GDK_w, // R - GDK_q, // L - GDK_s, // X - GDK_a, // Y - GDK_p, // DEBUG - GDK_o // BOOST -}; - - -GKeyFile *desmume_config_read_file() -{ - gchar *config_file; - GKeyFile *keyfile; - GError *error = NULL; - gboolean ret; - - config_file = g_build_filename(g_get_home_dir(), desmume_config_file, NULL); - keyfile = g_key_file_new(); - ret = g_key_file_load_from_file(keyfile, config_file, G_KEY_FILE_NONE, &error); - if (!ret) { - g_error_free(error); - } - - g_free(config_file); - - load_default_config(gtk_kb_cfg); - desmume_config_read_keys(keyfile); - desmume_config_read_joykeys(keyfile); - - return keyfile; -} - -void desmume_config_dispose(GKeyFile *keyfile) -{ - g_key_file_free(keyfile); -} - -static gboolean desmume_config_write_file(GKeyFile *keyfile) -{ - gchar *config_file; - gchar *data; - GError *error = NULL; - gsize length; - gboolean ret = TRUE; - - config_file = g_build_filename(g_get_home_dir(), desmume_config_file, NULL); - data = g_key_file_to_data(keyfile, &length, NULL); - ret = g_file_set_contents(config_file, data, length, &error); - if (!ret) { - g_error_free(error); - } - - g_free(config_file); - g_free(data); - - return ret; -} - -gboolean desmume_config_update_keys(GKeyFile *keyfile) -{ - for(int i = 0; i < NB_KEYS; i++) { - g_key_file_set_integer(keyfile, "KEYS", key_names[i], keyboard_cfg[i]); - } - - return desmume_config_write_file(keyfile); -} - -gboolean desmume_config_update_joykeys(GKeyFile *keyfile) -{ - for(int i = 0; i < NB_KEYS; i++) { - g_key_file_set_integer(keyfile, "JOYKEYS", key_names[i], joypad_cfg[i]); - } - - return desmume_config_write_file(keyfile); -} - -gboolean desmume_config_read_keys(GKeyFile *keyfile) -{ - GError *error = NULL; - - if (!g_key_file_has_group(keyfile, "KEYS")) - return TRUE; - - for (int i = 0; i < NB_KEYS; i++) { - keyboard_cfg[i] = g_key_file_get_integer(keyfile, "KEYS", key_names[i], &error); - if (error != NULL) { - g_error_free(error); - return FALSE; - } - } - - return TRUE; -} - -gboolean desmume_config_read_joykeys(GKeyFile *keyfile) -{ - GError *error = NULL; - - if (!g_key_file_has_group(keyfile, "JOYKEYS")) - return TRUE; - - for (int i = 0; i < NB_KEYS; i++) { - joypad_cfg[i] = g_key_file_get_integer(keyfile, "JOYKEYS", key_names[i], &error); - if (error != NULL) { - g_error_free(error); - return FALSE; - } - } - - return TRUE; -} +/* main.c - this file is part of DeSmuME + * + * Copyright (C) 2009 DeSmuME Team + * + * This file is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2, or (at your option) + * any later version. + * + * This file is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; see the file COPYING. If not, write to + * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#include +#include + +#include "ctrlssdl.h" +#include "desmume_config.h" + +static const gchar *desmume_config_file = ".desmume.ini"; +static const u16 gtk_kb_cfg[NB_KEYS] = { + GDK_x, // A + GDK_z, // B + GDK_Shift_R, // select + GDK_Return, // start + GDK_Right, // Right + GDK_Left, // Left + GDK_Up, // Up + GDK_Down, // Down + GDK_w, // R + GDK_q, // L + GDK_s, // X + GDK_a, // Y + GDK_p, // DEBUG + GDK_o // BOOST +}; + + +GKeyFile *desmume_config_read_file() +{ + gchar *config_file; + GKeyFile *keyfile; + GError *error = NULL; + gboolean ret; + + config_file = g_build_filename(g_get_home_dir(), desmume_config_file, NULL); + keyfile = g_key_file_new(); + ret = g_key_file_load_from_file(keyfile, config_file, G_KEY_FILE_NONE, &error); + if (!ret) { + g_error_free(error); + } + + g_free(config_file); + + load_default_config(gtk_kb_cfg); + desmume_config_read_keys(keyfile); + desmume_config_read_joykeys(keyfile); + + return keyfile; +} + +void desmume_config_dispose(GKeyFile *keyfile) +{ + g_key_file_free(keyfile); +} + +static gboolean desmume_config_write_file(GKeyFile *keyfile) +{ + gchar *config_file; + gchar *data; + GError *error = NULL; + gsize length; + gboolean ret = TRUE; + + config_file = g_build_filename(g_get_home_dir(), desmume_config_file, NULL); + data = g_key_file_to_data(keyfile, &length, NULL); + ret = g_file_set_contents(config_file, data, length, &error); + if (!ret) { + g_error_free(error); + } + + g_free(config_file); + g_free(data); + + return ret; +} + +gboolean desmume_config_update_keys(GKeyFile *keyfile) +{ + for(int i = 0; i < NB_KEYS; i++) { + g_key_file_set_integer(keyfile, "KEYS", key_names[i], keyboard_cfg[i]); + } + + return desmume_config_write_file(keyfile); +} + +gboolean desmume_config_update_joykeys(GKeyFile *keyfile) +{ + for(int i = 0; i < NB_KEYS; i++) { + g_key_file_set_integer(keyfile, "JOYKEYS", key_names[i], joypad_cfg[i]); + } + + return desmume_config_write_file(keyfile); +} + +gboolean desmume_config_read_keys(GKeyFile *keyfile) +{ + GError *error = NULL; + + if (!g_key_file_has_group(keyfile, "KEYS")) + return TRUE; + + for (int i = 0; i < NB_KEYS; i++) { + keyboard_cfg[i] = g_key_file_get_integer(keyfile, "KEYS", key_names[i], &error); + if (error != NULL) { + g_error_free(error); + return FALSE; + } + } + + return TRUE; +} + +gboolean desmume_config_read_joykeys(GKeyFile *keyfile) +{ + GError *error = NULL; + + if (!g_key_file_has_group(keyfile, "JOYKEYS")) + return TRUE; + + for (int i = 0; i < NB_KEYS; i++) { + joypad_cfg[i] = g_key_file_get_integer(keyfile, "JOYKEYS", key_names[i], &error); + if (error != NULL) { + g_error_free(error); + return FALSE; + } + } + + return TRUE; +} diff --git a/desmume/src/gtk/desmume_config.h b/src/gtk/desmume_config.h similarity index 97% rename from desmume/src/gtk/desmume_config.h rename to src/gtk/desmume_config.h index 2fab74a48..e3e8b7247 100644 --- a/desmume/src/gtk/desmume_config.h +++ b/src/gtk/desmume_config.h @@ -1,32 +1,32 @@ -/* main.c - this file is part of DeSmuME - * - * Copyright (C) 2009 DeSmuME Team - * - * This file is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2, or (at your option) - * any later version. - * - * This file is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; see the file COPYING. If not, write to - * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -#ifndef _DESMUME_GTK_CONFIG -#define _DESMUME_GTK_CONFIG - -GKeyFile *desmume_config_read_file(); -void desmume_config_dispose(GKeyFile *); - -gboolean desmume_config_update_keys(GKeyFile*); -gboolean desmume_config_update_joykeys(GKeyFile*); -gboolean desmume_config_read_keys(GKeyFile*); -gboolean desmume_config_read_joykeys(GKeyFile*); - -#endif +/* main.c - this file is part of DeSmuME + * + * Copyright (C) 2009 DeSmuME Team + * + * This file is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2, or (at your option) + * any later version. + * + * This file is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; see the file COPYING. If not, write to + * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#ifndef _DESMUME_GTK_CONFIG +#define _DESMUME_GTK_CONFIG + +GKeyFile *desmume_config_read_file(); +void desmume_config_dispose(GKeyFile *); + +gboolean desmume_config_update_keys(GKeyFile*); +gboolean desmume_config_update_joykeys(GKeyFile*); +gboolean desmume_config_read_keys(GKeyFile*); +gboolean desmume_config_read_joykeys(GKeyFile*); + +#endif diff --git a/desmume/src/gtk/doc/Makefile.am b/src/gtk/doc/Makefile.am similarity index 100% rename from desmume/src/gtk/doc/Makefile.am rename to src/gtk/doc/Makefile.am diff --git a/desmume/src/gtk/doc/desmume.1 b/src/gtk/doc/desmume.1 similarity index 100% rename from desmume/src/gtk/doc/desmume.1 rename to src/gtk/doc/desmume.1 diff --git a/desmume/src/gtk/main.cpp b/src/gtk/main.cpp similarity index 87% rename from desmume/src/gtk/main.cpp rename to src/gtk/main.cpp index ea5a5aa57..8f14e7151 100644 --- a/desmume/src/gtk/main.cpp +++ b/src/gtk/main.cpp @@ -1,4 +1,4 @@ -/* main.cpp - this file is part of DeSmuME +/* main.c - this file is part of DeSmuME * * Copyright (C) 2006-2009 DeSmuME Team * Copyright (C) 2007 Pascal Giard (evilynux) @@ -42,16 +42,11 @@ #include "rasterize.h" #include "saves.h" #include "mic.h" -#include "movie.h" #include "dTool.h" #include "desmume_config.h" -#include "cheatsGTK.h" -#include "GPU_osd.h" #include "commandline.h" -#include "addons.h" - #ifdef GDB_STUB #include "gdbstub.h" #endif @@ -67,13 +62,11 @@ #define EMULOOP_PRIO (G_PRIORITY_HIGH_IDLE + 20) -#if GTK_CHECK_VERSION(2,10,0) -#define HAVE_RECENT_FILES 1 -#endif -#if GTK_CHECK_VERSION(2,14,0) -#define HAVE_TIMEOUT 1 -#endif +static int backupmemorytype=MC_TYPE_AUTODETECT; +static u32 backupmemorysize=1; + +static const char *bad_glob_cflash_disk_image_file; #define SCREENS_PIXEL_SIZE (256*192*2) #define SCREEN_BYTES_PER_PIXEL 3 @@ -98,14 +91,11 @@ enum { gboolean EmuLoop(gpointer data); -static void RecordMovieDialog(); -static void PlayMovieDialog(); -static void StopMovie(); static void OpenNdsDialog(); static void SaveStateDialog(); static void LoadStateDialog(); -void Launch(); -void Pause(); +static void Launch(); +static void Pause(); static void Printscreen(); static void Reset(); static void Edit_Controls(); @@ -116,9 +106,7 @@ static void ToggleMenuVisible(GtkToggleAction *action); static void ToggleStatusbarVisible(GtkToggleAction *action); static void ToggleToolbarVisible(GtkToggleAction *action); static void ToggleAudio (GtkToggleAction *action); -#ifdef FAKE_MIC static void ToggleMicNoise (GtkToggleAction *action); -#endif static void ToggleGap (GtkToggleAction *action); static void SetRotation (GtkAction *action); static void ToggleLayerVisibility(GtkToggleAction* action, gpointer data); @@ -131,10 +119,6 @@ static const char *ui_description = " " "

    " " " -#ifdef HAVE_RECENT_FILES -" " -#endif -" " " " " " " " @@ -164,12 +148,7 @@ static const char *ui_description = #ifdef GTK_DESMUME_FIRMWARE_BROKEN " " #endif -" " -" " -" " -" " " " -" " " " " " " " @@ -177,9 +156,7 @@ static const char *ui_description = " " " " " " -#ifdef FAKE_MIC " " -#endif " " " " " " @@ -204,10 +181,6 @@ static const char *ui_description = " " " " " " -" " -" " -" " -" " " " " " " " @@ -238,7 +211,7 @@ static const char *ui_description = " " " " " " -" " +" " " " " " " " @@ -255,14 +228,8 @@ static const char *ui_description = static const GtkActionEntry action_entries[] = { { "FileMenu", NULL, "_File" }, { "open", "gtk-open", "_Open", "o", NULL, OpenNdsDialog }, -#ifdef HAVE_RECENT_FILES - { "RecentMenu", NULL, "Open _recent" }, -#endif { "savestateto", NULL, "Save state _to ...", NULL, NULL, SaveStateDialog }, { "loadstatefrom", NULL, "Load state _from ...", NULL, NULL, LoadStateDialog }, - { "recordmovie", NULL, "Record movie _to ...", NULL, NULL, RecordMovieDialog }, - { "playmovie", NULL, "Play movie _from ...", NULL, NULL, PlayMovieDialog }, - { "stopmovie", NULL, "Stop movie", NULL, NULL, StopMovie }, { "SavestateMenu", NULL, "_Save state" }, { "LoadstateMenu", NULL, "_Load state" }, #ifdef DESMUME_GTK_FIRMWARE_BROKEN @@ -277,9 +244,6 @@ static const GtkActionEntry action_entries[] = { { "reset", "gtk-refresh", "Re_set", NULL, NULL, Reset }, { "FrameskipMenu", NULL, "_Frameskip" }, { "LayersMenu", NULL, "_Layers" }, - { "CheatMenu", NULL, "_Cheat" }, - { "cheatsearch", NULL, "_Search", NULL, NULL, CheatSearch }, - { "cheatlist", NULL, "_List", NULL, NULL, CheatList }, { "ConfigMenu", NULL, "_Config" }, { "ConfigSaveMenu", NULL, "_Saves" }, @@ -300,9 +264,7 @@ static const GtkActionEntry action_entries[] = { static const GtkToggleActionEntry toggle_entries[] = { { "enableaudio", NULL, "_Enable audio", NULL, NULL, G_CALLBACK(ToggleAudio), TRUE}, -#ifdef FAKE_MIC { "micnoise", NULL, "Fake mic _noise", NULL, NULL, G_CALLBACK(ToggleMicNoise), FALSE}, -#endif { "gap", NULL, "_Gap", NULL, NULL, G_CALLBACK(ToggleGap), FALSE}, { "view_menu", NULL, "View _menu", NULL, NULL, G_CALLBACK(ToggleMenuVisible), TRUE}, { "view_toolbar", NULL, "View _toolbar", NULL, NULL, G_CALLBACK(ToggleToolbarVisible), TRUE}, @@ -339,6 +301,7 @@ static const GtkRadioActionEntry savet_entries[] = { SoundInterface_struct *SNDCoreList[] = { &SNDDummy, +&SNDFile, &SNDSDL, NULL }; @@ -377,9 +340,7 @@ public: int firmware_language; const char *cflash_disk_image_file; -#ifdef HAVE_TIMEOUT int timeout; -#endif }; static void @@ -398,9 +359,7 @@ init_configured_features( struct configured_features *config) config->cflash_disk_image_file = NULL; -#ifdef HAVE_TIMEOUT config->timeout = 0; -#endif /* use the default language */ config->firmware_language = -1; @@ -437,9 +396,8 @@ fill_configured_features( struct configured_features *config, "\t\t\t\t 4 = Italian\n" "\t\t\t\t 5 = Spanish\n", "LANG"}, -#ifdef HAVE_TIMEOUT + { "cflash", 0, 0, G_OPTION_ARG_FILENAME, &config->cflash_disk_image_file, "Enable disk image GBAMP compact flash emulation", "PATH_TO_DISK_IMAGE"}, { "timeout", 0, 0, G_OPTION_ARG_INT, &config->timeout, "Quit desmume after the specified seconds for testing purpose.", "SECONDS"}, -#endif { NULL } }; @@ -589,16 +547,12 @@ static void ToggleStatusbarVisible(GtkToggleAction *action) -static int Open(const char *filename) +static int Open(const char *filename, const char *cflash_disk_image) { - int res; - res = NDS_LoadROM( filename ); - if(res > 0) - gtk_action_set_sensitive(gtk_action_group_get_action(action_group, "cheatlist"), TRUE); - return res; + return NDS_LoadROM( filename, backupmemorytype, backupmemorysize, cflash_disk_image ); } -void Launch() +static void Launch() { GtkWidget *pause; desmume_resume(); @@ -619,7 +573,7 @@ void Launch() gtk_widget_grab_focus(pause); } -void Pause() +static void Pause() { GtkWidget *run; desmume_pause(); @@ -691,109 +645,6 @@ static void LoadStateDialog() gtk_widget_destroy(pFileSelection); } -static void RecordMovieDialog() -{ - GtkFileFilter *pFilter_dsm, *pFilter_any; - GtkWidget *pFileSelection; - GtkWidget *pParent; - gchar *sPath; - - if (desmume_running()) - Pause(); - - pParent = GTK_WIDGET(pWindow); - - pFilter_dsm = gtk_file_filter_new(); - gtk_file_filter_add_pattern(pFilter_dsm, "*.dsm*"); - gtk_file_filter_set_name(pFilter_dsm, "DeSmuME movie file (.dsm*)"); - - pFilter_any = gtk_file_filter_new(); - gtk_file_filter_add_pattern(pFilter_any, "*"); - gtk_file_filter_set_name(pFilter_any, "All files"); - - /* Creating the selection window */ - pFileSelection = gtk_file_chooser_dialog_new("Save Movie To ...", - GTK_WINDOW(pParent), - GTK_FILE_CHOOSER_ACTION_SAVE, - GTK_STOCK_CANCEL, GTK_RESPONSE_CANCEL, - GTK_STOCK_SAVE, GTK_RESPONSE_OK, - NULL); - gtk_file_chooser_set_do_overwrite_confirmation (GTK_FILE_CHOOSER (pFileSelection), TRUE); - - /* Only the dialog window is accepting events: */ - gtk_window_set_modal(GTK_WINDOW(pFileSelection), TRUE); - - gtk_file_chooser_add_filter(GTK_FILE_CHOOSER(pFileSelection), pFilter_dsm); - gtk_file_chooser_add_filter(GTK_FILE_CHOOSER(pFileSelection), pFilter_any); - - /* Showing the window */ - switch(gtk_dialog_run(GTK_DIALOG(pFileSelection))) { - case GTK_RESPONSE_OK: - sPath = gtk_file_chooser_get_filename(GTK_FILE_CHOOSER(pFileSelection)); - FCEUI_SaveMovie(sPath,L"",0,NULL); - g_free(sPath); - break; - default: - break; - } - gtk_widget_destroy(pFileSelection); -} - -static void StopMovie() -{ - FCEUI_StopMovie(); -} - -static void PlayMovieDialog() -{ - GtkFileFilter *pFilter_dsm, *pFilter_any; - GtkWidget *pFileSelection; - GtkWidget *pParent; - gchar *sPath; - - if (desmume_running()) - Pause(); - - pParent = GTK_WIDGET(pWindow); - - pFilter_dsm = gtk_file_filter_new(); - gtk_file_filter_add_pattern(pFilter_dsm, "*.dsm*"); - gtk_file_filter_set_name(pFilter_dsm, "DeSmuME movie file (.dsm*)"); - - pFilter_any = gtk_file_filter_new(); - gtk_file_filter_add_pattern(pFilter_any, "*"); - gtk_file_filter_set_name(pFilter_any, "All files"); - - /* Creating the selection window */ - pFileSelection = gtk_file_chooser_dialog_new("Play movie from...", - GTK_WINDOW(pParent), - GTK_FILE_CHOOSER_ACTION_OPEN, - GTK_STOCK_CANCEL, GTK_RESPONSE_CANCEL, - GTK_STOCK_OPEN, GTK_RESPONSE_OK, - NULL); - gtk_file_chooser_set_do_overwrite_confirmation (GTK_FILE_CHOOSER (pFileSelection), TRUE); - - /* Only the dialog window is accepting events: */ - gtk_window_set_modal(GTK_WINDOW(pFileSelection), TRUE); - - gtk_file_chooser_add_filter(GTK_FILE_CHOOSER(pFileSelection), pFilter_dsm); - gtk_file_chooser_add_filter(GTK_FILE_CHOOSER(pFileSelection), pFilter_any); - - /* Showing the window */ - switch(gtk_dialog_run(GTK_DIALOG(pFileSelection))) { - case GTK_RESPONSE_OK: - sPath = gtk_file_chooser_get_filename(GTK_FILE_CHOOSER(pFileSelection)); - - FCEUI_LoadMovie(sPath,true,false,-1); - - g_free(sPath); - break; - default: - break; - } - gtk_widget_destroy(pFileSelection); -} - static void SaveStateDialog() { GtkFileFilter *pFilter_ds, *pFilter_any; @@ -904,7 +755,7 @@ static void OpenNdsDialog() switch(gtk_dialog_run(GTK_DIALOG(pFileSelection))) { case GTK_RESPONSE_OK: sPath = gtk_file_chooser_get_filename(GTK_FILE_CHOOSER(pFileSelection)); - if(Open((const char*)sPath) < 0) { + if(Open((const char*)sPath, bad_glob_cflash_disk_image_file) < 0) { GtkWidget *pDialog = gtk_message_dialog_new(GTK_WINDOW(pFileSelection), GTK_DIALOG_MODAL, GTK_MESSAGE_ERROR, @@ -913,23 +764,6 @@ static void OpenNdsDialog() gtk_dialog_run(GTK_DIALOG(pDialog)); gtk_widget_destroy(pDialog); } else { -#ifdef HAVE_RECENT_FILES - GtkRecentData recentData; - gchar *uri; - memset(&recentData, 0, sizeof(GtkRecentData)); - recentData.mime_type = g_strdup("application/x-nintendo-ds-rom"); - recentData.app_name = (gchar *) g_get_application_name (); - recentData.app_exec = g_strjoin (" ", g_get_prgname (), "%f", NULL); - - GtkRecentManager *manager; - manager = gtk_recent_manager_get_default (); - uri = g_filename_to_uri (sPath, NULL, NULL); - gtk_recent_manager_add_full (manager, uri, &recentData); - - g_free(uri); - g_free(recentData.app_name); - g_free(recentData.app_exec); -#endif gtk_action_set_sensitive(gtk_action_group_get_action(action_group, "run"), TRUE); } @@ -943,15 +777,6 @@ static void OpenNdsDialog() gtk_widget_destroy(pFileSelection); } -#ifdef HAVE_RECENT_FILES -static void OpenRecent(GtkRecentChooser *chooser, gpointer user_data) -{ - Open(g_filename_from_uri(gtk_recent_chooser_get_current_uri(chooser), NULL, NULL)); - - gtk_action_set_sensitive(gtk_action_group_get_action(action_group, "run"), TRUE); -} -#endif - static void Reset() { NDS_Reset(); @@ -1054,13 +879,8 @@ static int ExposeDrawingArea (GtkWidget *widget, GdkEventExpose *event, gpointer gint daW, daH, imgH, imgW, xoff, yoff, xsize, ysize, xs, ys, xd, yd; int rot = (nds_screen_rotation_angle % 180 == 90); -#if GTK_CHECK_VERSION(2,14,0) gdk_drawable_get_size( gtk_widget_get_window(GTK_WIDGET(pDrawingArea)), &daW, &daH); -#else - gdk_drawable_get_size( - (GTK_WIDGET(pDrawingArea))->window, &daW, &daH); -#endif if(!rot){ imgW = 256; imgH = 384; @@ -1092,7 +912,6 @@ static int ExposeDrawingArea (GtkWidget *widget, GdkEventExpose *event, gpointer yd = yoff; } - DrawHUD(); gpu_screen_to_rgb(rgb, SCREENS_PIXEL_SIZE*SCREEN_BYTES_PER_PIXEL); origPixbuf = gdk_pixbuf_new_from_data(rgb, GDK_COLORSPACE_RGB, 0, 8, imgW, imgH, imgW*SCREEN_BYTES_PER_PIXEL, NULL, NULL); @@ -1678,7 +1497,8 @@ static void desmume_gtk_menu_file_saveload_slot (GtkActionGroup *ag) static void changesavetype(GtkAction *action, GtkRadioAction *current) { - backup_setManualBackupType( gtk_radio_action_get_current_value(current)); + mmu_select_savetype( gtk_radio_action_get_current_value(current), + &backupmemorytype, &backupmemorysize); } static void desmume_gtk_menu_emulation_layers (GtkActionGroup *ag) @@ -1715,25 +1535,23 @@ static void ToggleAudio (GtkToggleAction *action) } } -#ifdef FAKE_MIC static void ToggleMicNoise (GtkToggleAction *action) { Mic_DoNoise((BOOL)gtk_toggle_action_get_active(action)); } -#endif static void desmume_gtk_menu_tools (GtkActionGroup *ag) { gint i; for(i = 0; i < dTools_list_size; i++) { GtkAction *act; - act = gtk_action_new(dTools_list[i]->shortname, dTools_list[i]->name, NULL, NULL); + //FIXME: remove hardcoded 'ioregtool' from here and in ui_description + act = gtk_action_new("ioregtool", dTools_list[i]->name, NULL, NULL); g_signal_connect(G_OBJECT(act), "activate", G_CALLBACK(Start_dTool), GINT_TO_POINTER(i)); gtk_action_group_add_action(ag, GTK_ACTION(act)); } } -#ifdef HAVE_TIMEOUT static gboolean timeout_exit_cb(gpointer data) { gtk_main_quit(); @@ -1741,13 +1559,11 @@ static gboolean timeout_exit_cb(gpointer data) return FALSE; } -#endif static int common_gtk_main( struct configured_features *my_config) { - Desmume_InitOnce(); SDL_TimerID limiter_timer = NULL; GtkAccelGroup * accel_group; @@ -1776,23 +1592,7 @@ common_gtk_main( struct configured_features *my_config) fw_config.language = my_config->firmware_language; } - //------------------addons---------- - my_config->process_addonCommands(); - addon_type = NDS_ADDON_NONE; - if (my_config->is_cflash_configured) - addon_type = NDS_ADDON_CFLASH; - - switch (addon_type) { - case NDS_ADDON_CFLASH: - case NDS_ADDON_RUMBLEPAK: - case NDS_ADDON_NONE: - case NDS_ADDON_GBAGAME: - break; - default: - addon_type = NDS_ADDON_NONE; - break; - } - addonsChangePak (addon_type); + bad_glob_cflash_disk_image_file = my_config->cflash_disk_image_file; #ifdef GDB_STUB if ( my_config->arm9_gdb_port != 0) { @@ -1894,8 +1694,6 @@ common_gtk_main( struct configured_features *my_config) gtk_action_set_sensitive(gtk_action_group_get_action(action_group, "run"), FALSE); gtk_action_set_sensitive(gtk_action_group_get_action(action_group, "reset"), FALSE); gtk_action_set_sensitive(gtk_action_group_get_action(action_group, "printscreen"), FALSE); - gtk_action_set_sensitive(gtk_action_group_get_action(action_group, "cheatlist"), FALSE); - gtk_action_set_sensitive(gtk_action_group_get_action(action_group, "cheatsearch"), FALSE); gtk_ui_manager_insert_action_group (ui_manager, action_group, 0); @@ -1909,18 +1707,6 @@ common_gtk_main( struct configured_features *my_config) pToolBar = gtk_ui_manager_get_widget (ui_manager, "/ToolBar"); gtk_box_pack_start (GTK_BOX(pVBox), pToolBar, FALSE, FALSE, 0); -#ifdef HAVE_RECENT_FILES - { - GtkWidget * recentMenu = gtk_ui_manager_get_widget (ui_manager, "/MainMenu/FileMenu/RecentMenu"); - GtkWidget * recentFiles = gtk_recent_chooser_menu_new(); - GtkRecentFilter * recentFilter = gtk_recent_filter_new(); - gtk_recent_filter_add_mime_type(recentFilter, "application/x-nintendo-ds-rom"); - gtk_recent_chooser_set_filter(GTK_RECENT_CHOOSER(recentFiles), recentFilter); - gtk_menu_item_set_submenu(GTK_MENU_ITEM(recentMenu), recentFiles); - g_signal_connect(G_OBJECT(recentFiles), "item-activated", G_CALLBACK(OpenRecent), NULL); - } -#endif - /* Creating the place for showing DS screens */ pDrawingArea = gtk_drawing_area_new(); gtk_container_add (GTK_CONTAINER (pVBox), pDrawingArea); @@ -1965,9 +1751,11 @@ common_gtk_main( struct configured_features *my_config) } } - //Set the 3D emulation to use + /* + * Set the 3D emulation to use + */ unsigned core = my_config->engine_3d; - // setup the gdk 3D emulation; + /* setup the gdk 3D emulation; */ #if defined(HAVE_LIBOSMESA) if(my_config->engine_3d == 2){ core = init_osmesa_3Demu() ? 2 : GPU3D_NULL; @@ -1979,13 +1767,11 @@ common_gtk_main( struct configured_features *my_config) "removing 3D support\n"); } - backup_setManualBackupType(my_config->savetype); + mmu_select_savetype(my_config->savetype, &backupmemorytype, &backupmemorysize); - // Command line arg + /* Command line arg */ if( my_config->nds_file != "") { - if(Open( my_config->nds_file.c_str()) >= 0) { - my_config->process_movieCommands(); - + if(Open( my_config->nds_file.c_str(), bad_glob_cflash_disk_image_file) >= 0) { if(my_config->load_slot){ loadstate_slot(my_config->load_slot); } @@ -2002,11 +1788,9 @@ common_gtk_main( struct configured_features *my_config) } } -#ifdef HAVE_TIMEOUT if (my_config->timeout > 0) { g_timeout_add_seconds(my_config->timeout, timeout_exit_cb, GINT_TO_POINTER(my_config->timeout)); } -#endif /* Main loop */ @@ -2043,7 +1827,8 @@ common_gtk_main( struct configured_features *my_config) } -int main (int argc, char *argv[]) +int +main (int argc, char *argv[]) { configured_features my_config; diff --git a/desmume/src/gtk/osmesa_3Demu.cpp b/src/gtk/osmesa_3Demu.cpp similarity index 96% rename from desmume/src/gtk/osmesa_3Demu.cpp rename to src/gtk/osmesa_3Demu.cpp index 302ba95a0..293b8b272 100644 --- a/desmume/src/gtk/osmesa_3Demu.cpp +++ b/src/gtk/osmesa_3Demu.cpp @@ -1,53 +1,53 @@ -/* - Copyright (C) 2009 Guillaume Duhamel - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#ifdef HAVE_LIBOSMESA -#include -#include -#include "../OGLRender.h" -#include "osmesa_3Demu.h" - -static bool osmesa_beginOpenGL(void) { - return 1; -} - -static void osmesa_endOpenGL(void) { -} - -static bool osmesa_init(void) { - - return true; -} - -int init_osmesa_3Demu(void) { - void * buffer; - OSMesaContext ctx; - - ctx = OSMesaCreateContext(OSMESA_RGBA, NULL); - buffer = malloc(256 * 192 * 4); - OSMesaMakeCurrent(ctx, buffer, GL_UNSIGNED_BYTE, 256, 192); - - oglrender_init = osmesa_init; - oglrender_beginOpenGL = osmesa_beginOpenGL; - oglrender_endOpenGL = osmesa_endOpenGL; - - return 1; -} -#endif +/* + Copyright (C) 2009 Guillaume Duhamel + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#ifdef HAVE_LIBOSMESA +#include +#include +#include "../OGLRender.h" +#include "osmesa_3Demu.h" + +static bool osmesa_beginOpenGL(void) { + return 1; +} + +static void osmesa_endOpenGL(void) { +} + +static bool osmesa_init(void) { + + return true; +} + +int init_osmesa_3Demu(void) { + void * buffer; + OSMesaContext ctx; + + ctx = OSMesaCreateContext(OSMESA_RGBA, NULL); + buffer = malloc(256 * 192 * 4); + OSMesaMakeCurrent(ctx, buffer, GL_UNSIGNED_BYTE, 256, 192); + + oglrender_init = osmesa_init; + oglrender_beginOpenGL = osmesa_beginOpenGL; + oglrender_endOpenGL = osmesa_endOpenGL; + + return 1; +} +#endif diff --git a/desmume/src/gtk/osmesa_3Demu.h b/src/gtk/osmesa_3Demu.h similarity index 97% rename from desmume/src/gtk/osmesa_3Demu.h rename to src/gtk/osmesa_3Demu.h index d9f04eb8e..abd7cd175 100644 --- a/desmume/src/gtk/osmesa_3Demu.h +++ b/src/gtk/osmesa_3Demu.h @@ -1,23 +1,23 @@ -/* - Copyright (C) 2009 Guillaume Duhamel - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#ifdef HAVE_LIBOSMESA -int init_osmesa_3Demu( void); -#endif +/* + Copyright (C) 2009 Guillaume Duhamel + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#ifdef HAVE_LIBOSMESA +int init_osmesa_3Demu( void); +#endif diff --git a/desmume/src/gtk/tools/ioregsView.cpp b/src/gtk/tools/ioregsView.cpp similarity index 96% rename from desmume/src/gtk/tools/ioregsView.cpp rename to src/gtk/tools/ioregsView.cpp index cf75b1530..ed6dc51cd 100644 --- a/desmume/src/gtk/tools/ioregsView.cpp +++ b/src/gtk/tools/ioregsView.cpp @@ -1,482 +1,480 @@ -/* ioregsView.cpp - this file is part of DeSmuME - * - * Copyright (C) 2006 Thoduv - * Copyright (C) 2006,2007 DeSmuME Team - * - * This file is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2, or (at your option) - * any later version. - * - * This file is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; see the file COPYING. If not, write to - * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -#include -#include -#include "../dTool.h" - -#include "../MMU.h" - -#define SHORTNAME "ioregs" -#define TOOL_NAME "IO regs view" - -BOOL CPUS [2] = {TRUE, TRUE}; - -static GtkWidget *mWin[2]; -static GtkWidget *mVbox0[2]; -static GtkWidget *mIoRegCombo[2]; -static GtkWidget *mRegInfos[2]; - -typedef void (*reg_dispFn)(int c); -typedef u32 (*reg_valFn)(int c); - -typedef struct -{ - char name[64]; - u32 adress; - int size; - reg_dispFn create; - reg_dispFn update; - reg_dispFn destroy; - reg_valFn value; -} reg_t; - -static reg_t *current_reg[2] = {NULL, NULL}; - -#define REGFN_BEGIN(reg) \ - GtkWidget **_wl_ = Widgets_##reg [c]; - -#define BIT_CHECK(w, n, s) { \ - char _bit_check_buf[64]; \ - snprintf(_bit_check_buf, ARRAY_SIZE(_bit_check_buf), "Bit %d: %s", n,s); \ - _wl_[w] = gtk_check_button_new_with_label(_bit_check_buf ); \ - gtk_box_pack_start(GTK_BOX(mVbox0[c]), _wl_[w], FALSE, FALSE, 0); } - -#define BIT_COMBO(w,n,s) { \ - _wl_[w] = gtk_hbox_new(FALSE, 0); \ - gtk_box_pack_start(GTK_BOX(mVbox0[c]), _wl_[w], FALSE, FALSE, 0); } \ - char _bit_combo_buf[64]; \ - snprintf(_bit_combo_buf, ARRAY_SIZE(_bit_combo_buf), "Bits %s: %s", n,s); \ - GtkWidget *__combo_lbl_tmp = gtk_label_new(_bit_combo_buf); \ - GtkWidget *__combo_tmp = gtk_combo_box_new_text(); \ - -#define BIT_COMBO_ADD(w, s) { \ - gtk_combo_box_append_text(GTK_COMBO_BOX(__combo_tmp), s); } - -#define BIT_COMBO_GET(w) (GTK_WIDGET(g_list_first(gtk_container_get_children(GTK_CONTAINER(_wl_[w])))->data)) - -#define BIT_COMBO_END(w) \ - gtk_box_pack_start(GTK_BOX(_wl_[w]), __combo_tmp, FALSE, FALSE, 0); \ - gtk_box_pack_start(GTK_BOX(_wl_[w]), __combo_lbl_tmp, FALSE, FALSE, 0); - -#define CREA_END() \ - gtk_widget_show_all(mWin[c]); - -/////////////////////////////// REG_IME /////////////////////////////// -static GtkWidget *Widgets_REG_IME[2][1]; -static void crea_REG_IME(int c) -{ - REGFN_BEGIN(REG_IME); - BIT_CHECK(0, 0, "Master interrupt enable"); - CREA_END(); -} -static void updt_REG_IME(int c) { gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(Widgets_REG_IME[c][0]), MMU.reg_IME[c] ? 1 : 0); } -static void dest_REG_IME(int c) { gtk_widget_destroy(Widgets_REG_IME[c][0]); } -static u32 val_REG_IME(int c) { return MMU.reg_IME[c]; } - -/////////////////////////////// REG_IE /////////////////////////////// - -static const char *interrupt_strings[25] = -{ - "LCD VBlank", // 0 - "LCD HBlank", // 1 - "LCD VCount", // 2 - "Timer0 overflow", // 3 - "Timer1 overflow", - "Timer2 overflow", - "Timer3 overflow", - "Serial communication (RTC)", // 7 - "DMA0", // 8 - "DMA1", - "DMA2", - "DMA3", - "Keypad", // 12 - "Game Pak (GBA slot)", // 13 - "", // 14 - "", // 15 - "IPC Sync", // 16 - "IPC Send FIFO empty", // 17 - "IPC Recv FIFO not empty", // 18 - "Card Data Transfer Completion (DS-card slot)", // 19 - "Card IREQ_MC (DS-card slot)", // 20 - "Geometry (3D) command FIFO", // 21 - "Screens unfolding", // 22 - "SPI bus", // 23 - "Wifi" // 24 -}; -#define INTERRUPT_SKIP(c) if(i == 14 || i == 15 || (c == 0 && (i == 7 || i == 22 || i == 23 || i == 24)) || (c == 1 && i == 21))continue; - -static GtkWidget *Widgets_REG_IE[2][32]; -static void crea_REG_IE(int c) -{ - REGFN_BEGIN(REG_IE); - int i; - for(i = 0; i < 24; i++) { INTERRUPT_SKIP(c); BIT_CHECK(i, i, interrupt_strings[i]); } - CREA_END(); -} -static void updt_REG_IE(int c) -{ - int i; - for(i = 0; i < 24; i++) { INTERRUPT_SKIP(c); gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(Widgets_REG_IE[c][i]), (MMU.reg_IE[c] & (1<>1]&(1<>1]; } - -/////////////////////////////// POWER_CR /////////////////////////////// -static const char *powercr9_strings[] = -{ - "Enable LCD", - "2D A engine", - "3D render engine", - "3D geometry engine (matrix)", - "", "", "", "", "", - "2D B engine", - "", "", "", "", "", - "Swap LCD" -}; -static const char *powercr7_strings[] = -{ - "Sound speakers", - "Wifi system" -}; -#define POWER_CR_SKIP(c) if(i==4||i==5||i==6||i==7||i==8||i==10||i==11||i==12||i==13||i==14)continue; -#define POWER_CR_SIZE(c) ((c==0)?16:2) - -static GtkWidget *Widgets_POWER_CR[2][16]; -static void crea_POWER_CR(int c) -{ - REGFN_BEGIN(POWER_CR); - int i; - for(i = 0; i < POWER_CR_SIZE(c); i++) { POWER_CR_SKIP(c); BIT_CHECK(i, i, (c==0?powercr9_strings:powercr7_strings)[i]); } - CREA_END(); -} -static void updt_POWER_CR(int c) -{ - int i; - for(i = 0; i < POWER_CR_SIZE(c); i++) { POWER_CR_SKIP(c); gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(Widgets_POWER_CR[c][i]), (((u16 *)(MMU.MMU_MEM[c][0x40]))[0x304>>1]&(1<>1]; } - -/////////////////////////////// REG_SPICNT /////////////////////////////// -static const char *spicnt_strings[16] = -{ - "Baudrate", - "","","","","","", - "Busy flag", - "Device", - "", - "Transfer size", - "Chipselect Hold", - "Unknown", - "Unknown", - "Interrupt request", - "Enable SPI bus", -}; - -// 0-1 Baudrate (0=4MHz/Firmware, 1=2MHz/Touchscr, 2=1MHz/Powerman., 3=512KHz) -// 2-6 Not used (Zero) -// 7 Busy Flag (0=Ready, 1=Busy) (presumably Read-only) -// 8-9 Device Select (0=Powerman., 1=Firmware, 2=Touchscr, 3=Reserved) -// 10 Transfer Size (0=8bit, 1=16bit) -// 11 Chipselect Hold (0=Deselect after transfer, 1=Keep selected) -// 12 Unknown (usually 0) (set equal to Bit11 when BIOS accesses firmware) -// 13 Unknown (usually 0) (set to 1 when BIOS accesses firmware) -// 14 Interrupt Request (0=Disable, 1=Enable) -// 15 SPI Bus Enable (0=Disable, 1=Enable) - - -#define REG_SPICNT_SKIP(c) if(i==1||i==2||i==3||i==4||i==5||i==6||i==9)continue; -#define REG_SPICNT_ISCHECK(c) (i==7||i==11||i==14||i==15||i==12||i==13) - -static GtkWidget *Widgets_REG_SPICNT[2][16]; -static void crea_REG_SPICNT(int c) -{ - REGFN_BEGIN(REG_SPICNT); - int i; - for(i = 0; i < 16; i++) { REG_SPICNT_SKIP(c); - if(REG_SPICNT_ISCHECK(c)) { BIT_CHECK(i, i, spicnt_strings[i]); } - else if(i == 0) { BIT_COMBO(i, "0-1", spicnt_strings[0]); - BIT_COMBO_ADD(i, "0= 4Mhz"); - BIT_COMBO_ADD(i, "1= 2Mhz"); - BIT_COMBO_ADD(i, "2= 1Mhz"); - BIT_COMBO_ADD(i, "3= 512Khz"); - BIT_COMBO_END(i); } - else if(i == 8) { BIT_COMBO(i, "8-9", spicnt_strings[8]); - BIT_COMBO_ADD(i, "0= Power management device"); - BIT_COMBO_ADD(i, "1= Firmware"); - BIT_COMBO_ADD(i, "2= Touchscreen/Microphone"); - BIT_COMBO_ADD(i, "3= Reserved/Prohibited"); - BIT_COMBO_END(i); } - else if(i == 10) { BIT_COMBO(i, "10", spicnt_strings[10]); - BIT_COMBO_ADD(i, "0= 8 bits"); - BIT_COMBO_ADD(i, "1= 16 bits"); - BIT_COMBO_END(i); } - } - CREA_END(); -} -static u32 val_REG_SPICNT(int c) { return ((u16 *)(MMU.MMU_MEM[c][0x40]))[0x1C0>>1]; } -static void updt_REG_SPICNT(int c) -{ - REGFN_BEGIN(REG_SPICNT); - u16 val = val_REG_SPICNT(c); - int i; - for(i = 0; i < 16; i++) { REG_SPICNT_SKIP(c); - if(REG_SPICNT_ISCHECK(c)) { gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(Widgets_REG_SPICNT[c][i]), (((u16 *)(MMU.MMU_MEM[c][0x40]))[0x1C0>>1]&(1<>8)&3); } - else if(i == 10) { gtk_combo_box_set_active(GTK_COMBO_BOX(BIT_COMBO_GET(i)) , (val>>10)&1); } - } -} -static void dest_REG_SPICNT(int c) -{ - int i; - for(i = 0; i < 16; i++) { REG_SPICNT_SKIP(c); gtk_widget_destroy(Widgets_REG_SPICNT[c][i]); } -} - -/////////////////////////////// LIST /////////////////////////////// -#define BITS_8 1 -#define BITS_16 2 -#define BITS_32 4 -static const char *bits_strings[5] = {"0", "8", "16", "24", "32"}; - -#define REG_STR(r, s) {#r, r, s, &crea_##r, &updt_##r, &dest_##r, &val_##r} -#define REG_FNS(r) &crea_##r, &updt_##r, &dest_##r, &val_##r -//////// ARM9 //////// -#define REG_LIST_SIZE_ARM9 5 -static const reg_t regs_list_9[] = -{ - {"REG_IME", REG_IME, BITS_16, REG_FNS(REG_IME)}, - {"REG_IE", REG_IE, BITS_32, REG_FNS(REG_IE)}, - {"REG_IF", REG_IF, BITS_32, REG_FNS(REG_IF)}, - {"REG_IPCFIFOCNT", 0x04000184, BITS_16, REG_FNS(REG_IPCFIFOCNT)}, - {"POWER_CR", REG_POWCNT1, BITS_16, REG_FNS(POWER_CR)} -}; - -//////// ARM7 //////// -#define REG_LIST_SIZE_ARM7 6 -static const reg_t regs_list_7[] = -{ - {"REG_IME", REG_IME, BITS_16, REG_FNS(REG_IME)}, - {"REG_IE", REG_IE, BITS_32, REG_FNS(REG_IE)}, - {"REG_IF", REG_IF, BITS_32, REG_FNS(REG_IF)}, - {"REG_IPCFIFOCNT", 0x04000184, BITS_16, REG_FNS(REG_IPCFIFOCNT)}, - {"POWER_CR", REG_POWCNT1, BITS_16, REG_FNS(POWER_CR)}, - {"REG_SPICNT", REG_SPICNT, BITS_16, REG_FNS(REG_SPICNT)} -}; - -#define GET_REG_LIST_SIZE(i) ((i==0)?REG_LIST_SIZE_ARM9:REG_LIST_SIZE_ARM7) -#define GET_REG_LIST(i) ((i==0)?regs_list_9:regs_list_7) - -static void _clearContainer(GtkWidget *widget, gpointer data) -{ - if(widget == mRegInfos[0] || widget == mRegInfos[1]) return; - if(widget == mIoRegCombo[0] || widget == mIoRegCombo[1]) return; - - gtk_container_remove(GTK_CONTAINER((GtkWidget*)data), widget); -// gtk_widget_destroy(widget); -// gtk_object_destroy(GTK_OBJECT(widget)); -} - -static void selected_reg(GtkWidget* widget, gpointer data) -{ - int c = GPOINTER_TO_INT(data); - gchar *regInfosBuffer; - - guint active = gtk_combo_box_get_active(GTK_COMBO_BOX(widget)); - - if(current_reg[c]) current_reg[c]->destroy(c); - gtk_container_foreach(GTK_CONTAINER(mVbox0[c]), _clearContainer, (gpointer)mVbox0[c]); - - current_reg[c] = (reg_t*)&(GET_REG_LIST(c)[active]); - -// gtk_box_pack_start(GTK_BOX(mVbox0[c]), mIoRegCombo[c], FALSE, FALSE, 0); - - switch (current_reg[c]->size) { - case BITS_8: - regInfosBuffer = g_strdup_printf("0x%02X", current_reg[c]->value(c)); - break; - case BITS_16: - regInfosBuffer = g_strdup_printf("0x%04X", current_reg[c]->value(c)); - break; - default: - regInfosBuffer = g_strdup_printf("0x%08X", current_reg[c]->value(c)); - } -// gtk_box_pack_start(GTK_BOX(mVbox0[c]), mRegInfos[c], FALSE, FALSE, 0); - gtk_label_set_label(GTK_LABEL(mRegInfos[c]), regInfosBuffer); - g_free(regInfosBuffer); - - current_reg[c]->create(c); - current_reg[c]->update(c); -} - -/////////////////////////////// TOOL /////////////////////////////// - -static int DTOOL_ID; - -static void close() -{ - memset(current_reg, 0, sizeof(current_reg)); - dTool_CloseCallback(DTOOL_ID); -} - -static void _closeOne(GtkWidget *widget, gpointer data) -{ - int c = GPOINTER_TO_INT(data); - - CPUS[c] = FALSE; - if(c == 0 && !CPUS[1]) close(); - if(c == 1 && !CPUS[0]) close(); - - gtk_widget_destroy(mRegInfos[c]); - gtk_widget_destroy(mIoRegCombo[c]); - gtk_widget_destroy(mVbox0[c]); -// gtk_widget_destroy(mWin[c]); -} - -static void update() -{ - int c; - - for(c = 0; c < 2; c++) - { - if(!CPUS[c]) continue; - current_reg[c]->update(c); - } -} - -static void open(int ID) -{ - int c, i; - - DTOOL_ID = ID; - - for(c = 0; c < 2; c++) - { - CPUS[c] = TRUE; - - mWin[c]= gtk_window_new(GTK_WINDOW_TOPLEVEL); - if(c == 0) gtk_window_set_title(GTK_WINDOW(mWin[c]), TOOL_NAME " : ARM9"); - else gtk_window_set_title(GTK_WINDOW(mWin[c]), TOOL_NAME " : ARM7"); - g_signal_connect(G_OBJECT(mWin[c]), "destroy", G_CALLBACK(&_closeOne), GINT_TO_POINTER(c)); - - mVbox0[c] = gtk_vbox_new(FALSE, 0); - gtk_container_add(GTK_CONTAINER(mWin[c]), mVbox0[c]); - - mIoRegCombo[c] = gtk_combo_box_new_text(); - mRegInfos[c] = gtk_label_new(""); - - for(i = 0; i < GET_REG_LIST_SIZE(c); i++) - { - gchar *reg_name_buffer; - reg_name_buffer = g_strdup_printf("0x%08X : %s (%s)", GET_REG_LIST(c)[i].adress, GET_REG_LIST(c)[i].name, bits_strings[GET_REG_LIST(c)[i].size]); - gtk_combo_box_append_text(GTK_COMBO_BOX(mIoRegCombo[c]), reg_name_buffer); - g_free(reg_name_buffer); - } - - gtk_combo_box_set_active(GTK_COMBO_BOX(mIoRegCombo[c]), 0); - g_signal_connect(G_OBJECT(mIoRegCombo[c]), "changed", G_CALLBACK(selected_reg), GINT_TO_POINTER(c)); - - gtk_box_pack_start(GTK_BOX(mVbox0[c]), mIoRegCombo[c], FALSE, FALSE, 0); - gtk_box_pack_start(GTK_BOX(mVbox0[c]), mRegInfos[c], FALSE, FALSE, 0); - selected_reg(mIoRegCombo[c], GINT_TO_POINTER(c)); - - gtk_widget_show_all(mWin[c]); - } -} - -/////////////////////////////// TOOL DEFINITION /////////////////////////////// - -dTool_t dTool_ioregsView = -{ - SHORTNAME, - TOOL_NAME, - &open, - &update, - &close -}; - +/* ioregsView.cpp - this file is part of DeSmuME + * + * Copyright (C) 2006 Thoduv + * Copyright (C) 2006,2007 DeSmuME Team + * + * This file is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2, or (at your option) + * any later version. + * + * This file is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; see the file COPYING. If not, write to + * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#include +#include +#include "../dTool.h" + +#include "../MMU.h" + +#define TOOL_NAME "IO regs view" + +BOOL CPUS [2] = {TRUE, TRUE}; + +static GtkWidget *mWin[2]; +static GtkWidget *mVbox0[2]; +static GtkWidget *mIoRegCombo[2]; +static GtkWidget *mRegInfos[2]; + +typedef void (*reg_dispFn)(int c); +typedef u32 (*reg_valFn)(int c); + +typedef struct +{ + char name[64]; + u32 adress; + int size; + reg_dispFn create; + reg_dispFn update; + reg_dispFn destroy; + reg_valFn value; +} reg_t; + +static reg_t *current_reg[2] = {NULL, NULL}; + +#define REGFN_BEGIN(reg) \ + GtkWidget **_wl_ = Widgets_##reg [c]; + +#define BIT_CHECK(w, n, s) { \ + char _bit_check_buf[64]; \ + snprintf(_bit_check_buf, ARRAY_SIZE(_bit_check_buf), "Bit %d: %s", n,s); \ + _wl_[w] = gtk_check_button_new_with_label(_bit_check_buf ); \ + gtk_box_pack_start(GTK_BOX(mVbox0[c]), _wl_[w], FALSE, FALSE, 0); } + +#define BIT_COMBO(w,n,s) { \ + _wl_[w] = gtk_hbox_new(FALSE, 0); \ + gtk_box_pack_start(GTK_BOX(mVbox0[c]), _wl_[w], FALSE, FALSE, 0); } \ + char _bit_combo_buf[64]; \ + snprintf(_bit_combo_buf, ARRAY_SIZE(_bit_combo_buf), "Bits %s: %s", n,s); \ + GtkWidget *__combo_lbl_tmp = gtk_label_new(_bit_combo_buf); \ + GtkWidget *__combo_tmp = gtk_combo_box_new_text(); \ + +#define BIT_COMBO_ADD(w, s) { \ + gtk_combo_box_append_text(GTK_COMBO_BOX(__combo_tmp), s); } + +#define BIT_COMBO_GET(w) (GTK_WIDGET(g_list_first(gtk_container_get_children(GTK_CONTAINER(_wl_[w])))->data)) + +#define BIT_COMBO_END(w) \ + gtk_box_pack_start(GTK_BOX(_wl_[w]), __combo_tmp, FALSE, FALSE, 0); \ + gtk_box_pack_start(GTK_BOX(_wl_[w]), __combo_lbl_tmp, FALSE, FALSE, 0); + +#define CREA_END() \ + gtk_widget_show_all(mWin[c]); + +/////////////////////////////// REG_IME /////////////////////////////// +static GtkWidget *Widgets_REG_IME[2][1]; +static void crea_REG_IME(int c) +{ + REGFN_BEGIN(REG_IME); + BIT_CHECK(0, 0, "Master interrupt enable"); + CREA_END(); +} +static void updt_REG_IME(int c) { gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(Widgets_REG_IME[c][0]), MMU.reg_IME[c] ? 1 : 0); } +static void dest_REG_IME(int c) { gtk_widget_destroy(Widgets_REG_IME[c][0]); } +static u32 val_REG_IME(int c) { return MMU.reg_IME[c]; } + +/////////////////////////////// REG_IE /////////////////////////////// + +static const char *interrupt_strings[25] = +{ + "LCD VBlank", // 0 + "LCD HBlank", // 1 + "LCD VCount", // 2 + "Timer0 overflow", // 3 + "Timer1 overflow", + "Timer2 overflow", + "Timer3 overflow", + "Serial communication (RTC)", // 7 + "DMA0", // 8 + "DMA1", + "DMA2", + "DMA3", + "Keypad", // 12 + "Game Pak (GBA slot)", // 13 + "", // 14 + "", // 15 + "IPC Sync", // 16 + "IPC Send FIFO empty", // 17 + "IPC Recv FIFO not empty", // 18 + "Card Data Transfer Completion (DS-card slot)", // 19 + "Card IREQ_MC (DS-card slot)", // 20 + "Geometry (3D) command FIFO", // 21 + "Screens unfolding", // 22 + "SPI bus", // 23 + "Wifi" // 24 +}; +#define INTERRUPT_SKIP(c) if(i == 14 || i == 15 || (c == 0 && (i == 7 || i == 22 || i == 23 || i == 24)) || (c == 1 && i == 21))continue; + +static GtkWidget *Widgets_REG_IE[2][32]; +static void crea_REG_IE(int c) +{ + REGFN_BEGIN(REG_IE); + int i; + for(i = 0; i < 24; i++) { INTERRUPT_SKIP(c); BIT_CHECK(i, i, interrupt_strings[i]); } + CREA_END(); +} +static void updt_REG_IE(int c) +{ + int i; + for(i = 0; i < 24; i++) { INTERRUPT_SKIP(c); gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(Widgets_REG_IE[c][i]), (MMU.reg_IE[c] & (1<>1]&(1<>1]; } + +/////////////////////////////// POWER_CR /////////////////////////////// +static const char *powercr9_strings[] = +{ + "Enable LCD", + "2D A engine", + "3D render engine", + "3D geometry engine (matrix)", + "", "", "", "", "", + "2D B engine", + "", "", "", "", "", + "Swap LCD" +}; +static const char *powercr7_strings[] = +{ + "Sound speakers", + "Wifi system" +}; +#define POWER_CR_SKIP(c) if(i==4||i==5||i==6||i==7||i==8||i==10||i==11||i==12||i==13||i==14)continue; +#define POWER_CR_SIZE(c) ((c==0)?16:2) + +static GtkWidget *Widgets_POWER_CR[2][16]; +static void crea_POWER_CR(int c) +{ + REGFN_BEGIN(POWER_CR); + int i; + for(i = 0; i < POWER_CR_SIZE(c); i++) { POWER_CR_SKIP(c); BIT_CHECK(i, i, (c==0?powercr9_strings:powercr7_strings)[i]); } + CREA_END(); +} +static void updt_POWER_CR(int c) +{ + int i; + for(i = 0; i < POWER_CR_SIZE(c); i++) { POWER_CR_SKIP(c); gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(Widgets_POWER_CR[c][i]), (((u16 *)(MMU.MMU_MEM[c][0x40]))[0x304>>1]&(1<>1]; } + +/////////////////////////////// REG_SPICNT /////////////////////////////// +static const char *spicnt_strings[16] = +{ + "Baudrate", + "","","","","","", + "Busy flag", + "Device", + "", + "Transfer size", + "Chipselect Hold", + "Unknown", + "Unknown", + "Interrupt request", + "Enable SPI bus", +}; + +// 0-1 Baudrate (0=4MHz/Firmware, 1=2MHz/Touchscr, 2=1MHz/Powerman., 3=512KHz) +// 2-6 Not used (Zero) +// 7 Busy Flag (0=Ready, 1=Busy) (presumably Read-only) +// 8-9 Device Select (0=Powerman., 1=Firmware, 2=Touchscr, 3=Reserved) +// 10 Transfer Size (0=8bit, 1=16bit) +// 11 Chipselect Hold (0=Deselect after transfer, 1=Keep selected) +// 12 Unknown (usually 0) (set equal to Bit11 when BIOS accesses firmware) +// 13 Unknown (usually 0) (set to 1 when BIOS accesses firmware) +// 14 Interrupt Request (0=Disable, 1=Enable) +// 15 SPI Bus Enable (0=Disable, 1=Enable) + + +#define REG_SPICNT_SKIP(c) if(i==1||i==2||i==3||i==4||i==5||i==6||i==9)continue; +#define REG_SPICNT_ISCHECK(c) (i==7||i==11||i==14||i==15||i==12||i==13) + +static GtkWidget *Widgets_REG_SPICNT[2][16]; +static void crea_REG_SPICNT(int c) +{ + REGFN_BEGIN(REG_SPICNT); + int i; + for(i = 0; i < 16; i++) { REG_SPICNT_SKIP(c); + if(REG_SPICNT_ISCHECK(c)) { BIT_CHECK(i, i, spicnt_strings[i]); } + else if(i == 0) { BIT_COMBO(i, "0-1", spicnt_strings[0]); + BIT_COMBO_ADD(i, "0= 4Mhz"); + BIT_COMBO_ADD(i, "1= 2Mhz"); + BIT_COMBO_ADD(i, "2= 1Mhz"); + BIT_COMBO_ADD(i, "3= 512Khz"); + BIT_COMBO_END(i); } + else if(i == 8) { BIT_COMBO(i, "8-9", spicnt_strings[8]); + BIT_COMBO_ADD(i, "0= Power management device"); + BIT_COMBO_ADD(i, "1= Firmware"); + BIT_COMBO_ADD(i, "2= Touchscreen/Microphone"); + BIT_COMBO_ADD(i, "3= Reserved/Prohibited"); + BIT_COMBO_END(i); } + else if(i == 10) { BIT_COMBO(i, "10", spicnt_strings[10]); + BIT_COMBO_ADD(i, "0= 8 bits"); + BIT_COMBO_ADD(i, "1= 16 bits"); + BIT_COMBO_END(i); } + } + CREA_END(); +} +static u32 val_REG_SPICNT(int c) { return ((u16 *)(MMU.MMU_MEM[c][0x40]))[0x1C0>>1]; } +static void updt_REG_SPICNT(int c) +{ + REGFN_BEGIN(REG_SPICNT); + u16 val = val_REG_SPICNT(c); + int i; + for(i = 0; i < 16; i++) { REG_SPICNT_SKIP(c); + if(REG_SPICNT_ISCHECK(c)) { gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(Widgets_REG_SPICNT[c][i]), (((u16 *)(MMU.MMU_MEM[c][0x40]))[0x1C0>>1]&(1<>8)&3); } + else if(i == 10) { gtk_combo_box_set_active(GTK_COMBO_BOX(BIT_COMBO_GET(i)) , (val>>10)&1); } + } +} +static void dest_REG_SPICNT(int c) +{ + int i; + for(i = 0; i < 16; i++) { REG_SPICNT_SKIP(c); gtk_widget_destroy(Widgets_REG_SPICNT[c][i]); } +} + +/////////////////////////////// LIST /////////////////////////////// +#define BITS_8 1 +#define BITS_16 2 +#define BITS_32 4 +static const char *bits_strings[5] = {"0", "8", "16", "24", "32"}; + +#define REG_STR(r, s) {#r, r, s, &crea_##r, &updt_##r, &dest_##r, &val_##r} +#define REG_FNS(r) &crea_##r, &updt_##r, &dest_##r, &val_##r +//////// ARM9 //////// +#define REG_LIST_SIZE_ARM9 5 +static const reg_t regs_list_9[] = +{ + {"REG_IME", REG_IME, BITS_16, REG_FNS(REG_IME)}, + {"REG_IE", REG_IE, BITS_32, REG_FNS(REG_IE)}, + {"REG_IF", REG_IF, BITS_32, REG_FNS(REG_IF)}, + {"REG_IPCFIFOCNT", 0x04000184, BITS_16, REG_FNS(REG_IPCFIFOCNT)}, + {"POWER_CR", REG_POWCNT1, BITS_16, REG_FNS(POWER_CR)} +}; + +//////// ARM7 //////// +#define REG_LIST_SIZE_ARM7 6 +static const reg_t regs_list_7[] = +{ + {"REG_IME", REG_IME, BITS_16, REG_FNS(REG_IME)}, + {"REG_IE", REG_IE, BITS_32, REG_FNS(REG_IE)}, + {"REG_IF", REG_IF, BITS_32, REG_FNS(REG_IF)}, + {"REG_IPCFIFOCNT", 0x04000184, BITS_16, REG_FNS(REG_IPCFIFOCNT)}, + {"POWER_CR", REG_POWCNT1, BITS_16, REG_FNS(POWER_CR)}, + {"REG_SPICNT", REG_SPICNT, BITS_16, REG_FNS(REG_SPICNT)} +}; + +#define GET_REG_LIST_SIZE(i) ((i==0)?REG_LIST_SIZE_ARM9:REG_LIST_SIZE_ARM7) +#define GET_REG_LIST(i) ((i==0)?regs_list_9:regs_list_7) + +static void _clearContainer(GtkWidget *widget, gpointer data) +{ + if(widget == mRegInfos[0] || widget == mRegInfos[1]) return; + if(widget == mIoRegCombo[0] || widget == mIoRegCombo[1]) return; + + gtk_container_remove(GTK_CONTAINER((GtkWidget*)data), widget); +// gtk_widget_destroy(widget); +// gtk_object_destroy(GTK_OBJECT(widget)); +} + +static void selected_reg(GtkWidget* widget, gpointer data) +{ + int c = GPOINTER_TO_INT(data); + gchar *regInfosBuffer; + + guint active = gtk_combo_box_get_active(GTK_COMBO_BOX(widget)); + + if(current_reg[c]) current_reg[c]->destroy(c); + gtk_container_foreach(GTK_CONTAINER(mVbox0[c]), _clearContainer, (gpointer)mVbox0[c]); + + current_reg[c] = (reg_t*)&(GET_REG_LIST(c)[active]); + +// gtk_box_pack_start(GTK_BOX(mVbox0[c]), mIoRegCombo[c], FALSE, FALSE, 0); + + switch (current_reg[c]->size) { + case BITS_8: + regInfosBuffer = g_strdup_printf("0x%02X", current_reg[c]->value(c)); + break; + case BITS_16: + regInfosBuffer = g_strdup_printf("0x%04X", current_reg[c]->value(c)); + break; + default: + regInfosBuffer = g_strdup_printf("0x%08X", current_reg[c]->value(c)); + } +// gtk_box_pack_start(GTK_BOX(mVbox0[c]), mRegInfos[c], FALSE, FALSE, 0); + gtk_label_set_label(GTK_LABEL(mRegInfos[c]), regInfosBuffer); + g_free(regInfosBuffer); + + current_reg[c]->create(c); + current_reg[c]->update(c); +} + +/////////////////////////////// TOOL /////////////////////////////// + +static int DTOOL_ID; + +static void close() +{ + memset(current_reg, 0, sizeof(current_reg)); + dTool_CloseCallback(DTOOL_ID); +} + +static void _closeOne(GtkWidget *widget, gpointer data) +{ + int c = GPOINTER_TO_INT(data); + + CPUS[c] = FALSE; + if(c == 0 && !CPUS[1]) close(); + if(c == 1 && !CPUS[0]) close(); + + gtk_widget_destroy(mRegInfos[c]); + gtk_widget_destroy(mIoRegCombo[c]); + gtk_widget_destroy(mVbox0[c]); +// gtk_widget_destroy(mWin[c]); +} + +static void update() +{ + int c; + + for(c = 0; c < 2; c++) + { + if(!CPUS[c]) continue; + current_reg[c]->update(c); + } +} + +static void open(int ID) +{ + int c, i; + + DTOOL_ID = ID; + + for(c = 0; c < 2; c++) + { + CPUS[c] = TRUE; + + mWin[c]= gtk_window_new(GTK_WINDOW_TOPLEVEL); + if(c == 0) gtk_window_set_title(GTK_WINDOW(mWin[c]), TOOL_NAME " : ARM9"); + else gtk_window_set_title(GTK_WINDOW(mWin[c]), TOOL_NAME " : ARM7"); + g_signal_connect(G_OBJECT(mWin[c]), "destroy", G_CALLBACK(&_closeOne), GINT_TO_POINTER(c)); + + mVbox0[c] = gtk_vbox_new(FALSE, 0); + gtk_container_add(GTK_CONTAINER(mWin[c]), mVbox0[c]); + + mIoRegCombo[c] = gtk_combo_box_new_text(); + mRegInfos[c] = gtk_label_new(""); + + for(i = 0; i < GET_REG_LIST_SIZE(c); i++) + { + gchar *reg_name_buffer; + reg_name_buffer = g_strdup_printf("0x%08X : %s (%s)", GET_REG_LIST(c)[i].adress, GET_REG_LIST(c)[i].name, bits_strings[GET_REG_LIST(c)[i].size]); + gtk_combo_box_append_text(GTK_COMBO_BOX(mIoRegCombo[c]), reg_name_buffer); + g_free(reg_name_buffer); + } + + gtk_combo_box_set_active(GTK_COMBO_BOX(mIoRegCombo[c]), 0); + g_signal_connect(G_OBJECT(mIoRegCombo[c]), "changed", G_CALLBACK(selected_reg), GINT_TO_POINTER(c)); + + gtk_box_pack_start(GTK_BOX(mVbox0[c]), mIoRegCombo[c], FALSE, FALSE, 0); + gtk_box_pack_start(GTK_BOX(mVbox0[c]), mRegInfos[c], FALSE, FALSE, 0); + selected_reg(mIoRegCombo[c], GINT_TO_POINTER(c)); + + gtk_widget_show_all(mWin[c]); + } +} + +/////////////////////////////// TOOL DEFINITION /////////////////////////////// + +dTool_t dTool_ioregsView = +{ + TOOL_NAME, + &open, + &update, + &close +}; + diff --git a/desmume/src/gtk/tools/ioregsView.h b/src/gtk/tools/ioregsView.h similarity index 97% rename from desmume/src/gtk/tools/ioregsView.h rename to src/gtk/tools/ioregsView.h index 2c814451a..4ee8949f8 100644 --- a/desmume/src/gtk/tools/ioregsView.h +++ b/src/gtk/tools/ioregsView.h @@ -1,29 +1,29 @@ -/* ioregsview.h - this file is part of DeSmuME - * - * Copyright (C) 2006,2007 DeSmuME Team - * - * This file is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2, or (at your option) - * any later version. - * - * This file is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; see the file COPYING. If not, write to - * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -#ifndef __IOREGSVIEW_H__ -#define __IOREGSVIEW_H__ - -#include "../dTool.h" - -extern dTool_t dTool_ioregsView; - -#endif /*__IOREGSVIEW_H__*/ - +/* ioregsview.h - this file is part of DeSmuME + * + * Copyright (C) 2006,2007 DeSmuME Team + * + * This file is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2, or (at your option) + * any later version. + * + * This file is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; see the file COPYING. If not, write to + * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#ifndef __IOREGSVIEW_H__ +#define __IOREGSVIEW_H__ + +#include "../dTool.h" + +extern dTool_t dTool_ioregsView; + +#endif /*__IOREGSVIEW_H__*/ + diff --git a/desmume/src/instruction_tabdef.inc b/src/instruction_tabdef.inc similarity index 100% rename from desmume/src/instruction_tabdef.inc rename to src/instruction_tabdef.inc diff --git a/desmume/src/lua-engine.cpp b/src/lua-engine.cpp similarity index 93% rename from desmume/src/lua-engine.cpp rename to src/lua-engine.cpp index 2c1b2c43e..86a30ef0d 100644 --- a/desmume/src/lua-engine.cpp +++ b/src/lua-engine.cpp @@ -1,5254 +1,5182 @@ -#include "lua-engine.h" -#include "movie.h" -#include -#include -#include -#include -#include -#include "zlib.h" -#include "NDSSystem.h" -#include "movie.h" -#include "GPU_osd.h" -#ifdef WIN32 -#include "main.h" -#include "windows.h" -#endif - -// the emulator must provide these so that we can implement -// the various functions the user can call from their lua script -// (this interface with the emulator needs cleanup, I know) -// adapted from gens-rr, nitsuja + upthorn -extern int (*Update_Frame)(); -extern int (*Update_Frame_Fast)(); - -extern "C" { - #include "lua.h" - #include "lauxlib.h" - #include "lualib.h" - #include "lstate.h" -}; - -enum SpeedMode -{ - SPEEDMODE_NORMAL, - SPEEDMODE_NOTHROTTLE, - SPEEDMODE_TURBO, - SPEEDMODE_MAXIMUM, -}; - -struct LuaContextInfo { - lua_State* L; // the Lua state - bool started; // script has been started and hasn't yet been terminated, although it may not be currently running - bool running; // script is currently running code (either the main call to the script or the callbacks it registered) - bool returned; // main call to the script has returned (but it may still be active if it registered callbacks) - bool crashed; // true if script has errored out - bool restart; // if true, tells the script-running code to restart the script when the script stops - bool restartLater; // set to true when a still-running script is stopped so that RestartAllLuaScripts can know which scripts to restart - unsigned int worryCount; // counts up as the script executes, gets reset when the application is able to process messages, triggers a warning prompt if it gets too high - bool stopWorrying; // set to true if the user says to let the script run forever despite appearing to be frozen - bool panic; // if set to true, tells the script to terminate as soon as it can do so safely (used because directly calling lua_close() or luaL_error() is unsafe in some contexts) - bool ranExit; // used to prevent a registered exit callback from ever getting called more than once - bool guiFuncsNeedDeferring; // true whenever GUI drawing would be cleared by the next emulation update before it would be visible, and thus needs to be deferred until after the next emulation update - int numDeferredGUIFuncs; // number of deferred function calls accumulated, used to impose an arbitrary limit to avoid running out of memory - bool ranFrameAdvance; // false if gens.frameadvance() hasn't been called yet - int transparencyModifier; // values less than 255 will scale down the opacity of whatever the GUI renders, values greater than 255 will increase the opacity of anything transparent the GUI renders - SpeedMode speedMode; // determines how gens.frameadvance() acts - char panicMessage [72]; // a message to print if the script terminates due to panic being set - std::string lastFilename; // path to where the script last ran from so that restart can work (note: storing the script in memory instead would not be useful because we always want the most up-to-date script from file) - std::string nextFilename; // path to where the script should run from next, mainly used in case the restart flag is true - unsigned int dataSaveKey; // crc32 of the save data key, used to decide which script should get which data... by default (if no key is specified) it's calculated from the script filename - unsigned int dataLoadKey; // same as dataSaveKey but set through registerload instead of registersave if the two differ - bool dataSaveLoadKeySet; // false if the data save keys are unset or set to their default value - bool rerecordCountingDisabled; // true if this script has disabled rerecord counting for the savestates it loads - std::vector persistVars; // names of the global variables to persist, kept here so their associated values can be output when the script exits - LuaSaveData newDefaultData; // data about the default state of persisted global variables, which we save on script exit so we can detect when the default value has changed to make it easier to reset persisted variables - unsigned int numMemHooks; // number of registered memory functions (1 per hooked byte) - // callbacks into the lua window... these don't need to exist per context the way I'm using them, but whatever - void(*print)(int uid, const char* str); - void(*onstart)(int uid); - void(*onstop)(int uid, bool statusOK); -}; -std::map luaContextInfo; -std::map luaStateToUIDMap; -int g_numScriptsStarted = 0; -bool g_anyScriptsHighSpeed = false; -bool g_stopAllScriptsEnabled = true; - -#define USE_INFO_STACK -#ifdef USE_INFO_STACK - std::vector infoStack; - #define GetCurrentInfo() *infoStack.front() // should be faster but relies on infoStack correctly being updated to always have the current info in the first element -#else - std::map luaStateToContextMap; - #define GetCurrentInfo() *luaStateToContextMap[L] // should always work but might be slower -#endif - -//#define ASK_USER_ON_FREEZE // dialog on freeze is disabled now because it seems to be unnecessary, but this can be re-defined to enable it - - -static std::map s_cFuncInfoMap; - -// using this macro you can define a callable-from-Lua function -// while associating with it some information about its arguments. -// that information will show up if the user tries to print the function -// or otherwise convert it to a string. -// (for example, "writebyte=function(addr,value)" instead of "writebyte=function:0A403490") -// note that the user can always use addressof(func) if they want to retrieve the address. -#define DEFINE_LUA_FUNCTION(name, argstring) \ - static int name(lua_State* L); \ - static const char* name##_args = s_cFuncInfoMap[name] = argstring; \ - static int name(lua_State* L) - -#ifdef _MSC_VER - #define snprintf _snprintf - #define vscprintf _vscprintf -#else - #define stricmp strcasecmp - #define strnicmp strncasecmp - #define __forceinline __attribute__((always_inline)) -#endif - - -static const char* luaCallIDStrings [] = -{ - "CALL_BEFOREEMULATION", - "CALL_AFTEREMULATION", - "CALL_AFTEREMULATIONGUI", - "CALL_BEFOREEXIT", - "CALL_BEFORESAVE", - "CALL_AFTERLOAD", - "CALL_ONSTART", - - "CALL_HOTKEY_1", - "CALL_HOTKEY_2", - "CALL_HOTKEY_3", - "CALL_HOTKEY_4", - "CALL_HOTKEY_5", - "CALL_HOTKEY_6", - "CALL_HOTKEY_7", - "CALL_HOTKEY_8", - "CALL_HOTKEY_9", - "CALL_HOTKEY_10", - "CALL_HOTKEY_11", - "CALL_HOTKEY_12", - "CALL_HOTKEY_13", - "CALL_HOTKEY_14", - "CALL_HOTKEY_15", - "CALL_HOTKEY_16", -}; -static const int _makeSureWeHaveTheRightNumberOfStrings [sizeof(luaCallIDStrings)/sizeof(*luaCallIDStrings) == LUACALL_COUNT ? 1 : 0]; - -static const char* luaMemHookTypeStrings [] = -{ - "MEMHOOK_WRITE", - "MEMHOOK_READ", - "MEMHOOK_EXEC", - - "MEMHOOK_WRITE_SUB", - "MEMHOOK_READ_SUB", - "MEMHOOK_EXEC_SUB", -}; -static const int _makeSureWeHaveTheRightNumberOfStrings2 [sizeof(luaMemHookTypeStrings)/sizeof(*luaMemHookTypeStrings) == LUAMEMHOOK_COUNT ? 1 : 0]; - -void StopScriptIfFinished(int uid, bool justReturned = false); -void SetSaveKey(LuaContextInfo& info, const char* key); -void SetLoadKey(LuaContextInfo& info, const char* key); -void RefreshScriptStartedStatus(); -void RefreshScriptSpeedStatus(); - -static char* rawToCString(lua_State* L, int idx=0); -static const char* toCString(lua_State* L, int idx=0); - -static void CalculateMemHookRegions(LuaMemHookType hookType); - -static int memory_registerHook(lua_State* L, LuaMemHookType hookType, int defaultSize) -{ - // get first argument: address - unsigned int addr = luaL_checkinteger(L,1); - if((addr & ~0xFFFFFF) == ~0xFFFFFF) - addr &= 0xFFFFFF; - - // get optional second argument: size - int size = defaultSize; - int funcIdx = 2; - if(lua_isnumber(L,2)) - { - size = luaL_checkinteger(L,2); - if(size < 0) - { - size = -size; - addr -= size; - } - funcIdx++; - } - - // check last argument: callback function - bool clearing = lua_isnil(L,funcIdx); - if(!clearing) - luaL_checktype(L, funcIdx, LUA_TFUNCTION); - lua_settop(L,funcIdx); - - // get the address-to-callback table for this hook type of the current script - lua_getfield(L, LUA_REGISTRYINDEX, luaMemHookTypeStrings[hookType]); - - // count how many callback functions we'll be displacing - int numFuncsAfter = clearing ? 0 : size; - int numFuncsBefore = 0; - for(unsigned int i = addr; i != addr+size; i++) - { - lua_rawgeti(L, -1, i); - if(lua_isfunction(L, -1)) - numFuncsBefore++; - lua_pop(L,1); - } - - // put the callback function in the address slots - for(unsigned int i = addr; i != addr+size; i++) - { - lua_pushvalue(L, -2); - lua_rawseti(L, -2, i); - } - - // adjust the count of active hooks - LuaContextInfo& info = GetCurrentInfo(); - info.numMemHooks += numFuncsAfter - numFuncsBefore; - - // re-cache regions of hooked memory across all scripts - CalculateMemHookRegions(hookType); - - StopScriptIfFinished(luaStateToUIDMap[L]); - return 0; -} - -LuaMemHookType MatchHookTypeToCPU(lua_State* L, LuaMemHookType hookType) -{ - int cpuID = 0; - - int cpunameIndex = 0; - if(lua_type(L,2) == LUA_TSTRING) - cpunameIndex = 2; - else if(lua_type(L,3) == LUA_TSTRING) - cpunameIndex = 3; - - if(cpunameIndex) - { - const char* cpuName = lua_tostring(L, cpunameIndex); - if(!stricmp(cpuName, "sub") || !stricmp(cpuName, "s68k")) - cpuID = 1; - lua_remove(L, cpunameIndex); - } - - switch(cpuID) - { - case 0: // m68k: - return hookType; - - case 1: // s68k: - switch(hookType) - { - case LUAMEMHOOK_WRITE: return LUAMEMHOOK_WRITE_SUB; - case LUAMEMHOOK_READ: return LUAMEMHOOK_READ_SUB; - case LUAMEMHOOK_EXEC: return LUAMEMHOOK_EXEC_SUB; - } - } - return hookType; -} - -DEFINE_LUA_FUNCTION(memory_registerwrite, "address,[size=1,][cpuname=\"main\",]func") -{ - return memory_registerHook(L, MatchHookTypeToCPU(L,LUAMEMHOOK_WRITE), 1); -} -DEFINE_LUA_FUNCTION(memory_registerread, "address,[size=1,][cpuname=\"main\",]func") -{ - return memory_registerHook(L, MatchHookTypeToCPU(L,LUAMEMHOOK_READ), 1); -} -DEFINE_LUA_FUNCTION(memory_registerexec, "address,[size=2,][cpuname=\"main\",]func") -{ - return memory_registerHook(L, MatchHookTypeToCPU(L,LUAMEMHOOK_EXEC), 2); -} - - -DEFINE_LUA_FUNCTION(emu_registerbefore, "func") -{ - if (!lua_isnil(L,1)) - luaL_checktype(L, 1, LUA_TFUNCTION); - lua_settop(L,1); - lua_getfield(L, LUA_REGISTRYINDEX, luaCallIDStrings[LUACALL_BEFOREEMULATION]); - lua_insert(L,1); - lua_setfield(L, LUA_REGISTRYINDEX, luaCallIDStrings[LUACALL_BEFOREEMULATION]); - StopScriptIfFinished(luaStateToUIDMap[L]); - return 1; -} -DEFINE_LUA_FUNCTION(emu_registerafter, "func") -{ - if (!lua_isnil(L,1)) - luaL_checktype(L, 1, LUA_TFUNCTION); - lua_settop(L,1); - lua_getfield(L, LUA_REGISTRYINDEX, luaCallIDStrings[LUACALL_AFTEREMULATION]); - lua_insert(L,1); - lua_setfield(L, LUA_REGISTRYINDEX, luaCallIDStrings[LUACALL_AFTEREMULATION]); - StopScriptIfFinished(luaStateToUIDMap[L]); - return 1; -} -DEFINE_LUA_FUNCTION(emu_registerexit, "func") -{ - if (!lua_isnil(L,1)) - luaL_checktype(L, 1, LUA_TFUNCTION); - lua_settop(L,1); - lua_getfield(L, LUA_REGISTRYINDEX, luaCallIDStrings[LUACALL_BEFOREEXIT]); - lua_insert(L,1); - lua_setfield(L, LUA_REGISTRYINDEX, luaCallIDStrings[LUACALL_BEFOREEXIT]); - StopScriptIfFinished(luaStateToUIDMap[L]); - return 1; -}/* -DEFINE_LUA_FUNCTION(emu_registerstart, "func") -{ - if (!lua_isnil(L,1)) - luaL_checktype(L, 1, LUA_TFUNCTION); - lua_settop(L,1); - lua_getfield(L, LUA_REGISTRYINDEX, luaCallIDStrings[LUACALL_ONSTART]); - lua_insert(L,1); - lua_pushvalue(L,-1); // copy the function so we can also call it - lua_setfield(L, LUA_REGISTRYINDEX, luaCallIDStrings[LUACALL_ONSTART]); - if (!lua_isnil(L,-1) && ((Genesis_Started)||(SegaCD_Started)||(_32X_Started))) - lua_call(L,0,0); // call the function now since the game has already started and this start function hasn't been called yet - StopScriptIfFinished(luaStateToUIDMap[L]); - return 1; -}*/ -DEFINE_LUA_FUNCTION(gui_register, "func") -{ - if (!lua_isnil(L,1)) - luaL_checktype(L, 1, LUA_TFUNCTION); - lua_settop(L,1); - lua_getfield(L, LUA_REGISTRYINDEX, luaCallIDStrings[LUACALL_AFTEREMULATIONGUI]); - lua_insert(L,1); - lua_setfield(L, LUA_REGISTRYINDEX, luaCallIDStrings[LUACALL_AFTEREMULATIONGUI]); - StopScriptIfFinished(luaStateToUIDMap[L]); - return 1; -} -DEFINE_LUA_FUNCTION(state_registersave, "func[,savekey]") -{ - if (!lua_isnil(L,1)) - luaL_checktype(L, 1, LUA_TFUNCTION); - if (!lua_isnoneornil(L,2)) - SetSaveKey(GetCurrentInfo(), rawToCString(L,2)); - lua_settop(L,1); - lua_getfield(L, LUA_REGISTRYINDEX, luaCallIDStrings[LUACALL_BEFORESAVE]); - lua_insert(L,1); - lua_setfield(L, LUA_REGISTRYINDEX, luaCallIDStrings[LUACALL_BEFORESAVE]); - StopScriptIfFinished(luaStateToUIDMap[L]); - return 1; -} -DEFINE_LUA_FUNCTION(state_registerload, "func[,loadkey]") -{ - if (!lua_isnil(L,1)) - luaL_checktype(L, 1, LUA_TFUNCTION); - if (!lua_isnoneornil(L,2)) - SetLoadKey(GetCurrentInfo(), rawToCString(L,2)); - lua_settop(L,1); - lua_getfield(L, LUA_REGISTRYINDEX, luaCallIDStrings[LUACALL_AFTERLOAD]); - lua_insert(L,1); - lua_setfield(L, LUA_REGISTRYINDEX, luaCallIDStrings[LUACALL_AFTERLOAD]); - StopScriptIfFinished(luaStateToUIDMap[L]); - return 1; -} - -DEFINE_LUA_FUNCTION(input_registerhotkey, "keynum,func") -{ - int hotkeyNumber = luaL_checkinteger(L,1); - if(hotkeyNumber < 1 || hotkeyNumber > 16) - { - luaL_error(L, "input.registerhotkey(n,func) requires 1 <= n <= 16, but got n = %d.", hotkeyNumber); - return 0; - } - else - { - const char* key = luaCallIDStrings[LUACALL_SCRIPT_HOTKEY_1 + hotkeyNumber-1]; - lua_getfield(L, LUA_REGISTRYINDEX, key); - lua_replace(L,1); - if (!lua_isnil(L,2)) - luaL_checktype(L, 2, LUA_TFUNCTION); - lua_settop(L,2); - lua_setfield(L, LUA_REGISTRYINDEX, key); - StopScriptIfFinished(luaStateToUIDMap[L]); - return 1; - } -} - -static int doPopup(lua_State* L, const char* deftype, const char* deficon) -{ - const char* str = toCString(L,1); - const char* type = lua_type(L,2) == LUA_TSTRING ? lua_tostring(L,2) : deftype; - const char* icon = lua_type(L,3) == LUA_TSTRING ? lua_tostring(L,3) : deficon; - - int itype = -1, iters = 0; - while(itype == -1 && iters++ < 2) - { - if(!stricmp(type, "ok")) itype = 0; - else if(!stricmp(type, "yesno")) itype = 1; - else if(!stricmp(type, "yesnocancel")) itype = 2; - else if(!stricmp(type, "okcancel")) itype = 3; - else if(!stricmp(type, "abortretryignore")) itype = 4; - else type = deftype; - } - assert(itype >= 0 && itype <= 4); - if(!(itype >= 0 && itype <= 4)) itype = 0; - - int iicon = -1; iters = 0; - while(iicon == -1 && iters++ < 2) - { - if(!stricmp(icon, "message") || !stricmp(icon, "notice")) iicon = 0; - else if(!stricmp(icon, "question")) iicon = 1; - else if(!stricmp(icon, "warning")) iicon = 2; - else if(!stricmp(icon, "error")) iicon = 3; - else icon = deficon; - } - assert(iicon >= 0 && iicon <= 3); - if(!(iicon >= 0 && iicon <= 3)) iicon = 0; - - static const char * const titles [] = {"Notice", "Question", "Warning", "Error"}; - const char* answer = "ok"; -#ifdef _WIN32 - static const int etypes [] = {MB_OK, MB_YESNO, MB_YESNOCANCEL, MB_OKCANCEL, MB_ABORTRETRYIGNORE}; - static const int eicons [] = {MB_ICONINFORMATION, MB_ICONQUESTION, MB_ICONWARNING, MB_ICONERROR}; -// DialogsOpen++; - int uid = luaStateToUIDMap[L]; - EnableWindow(MainWindow->getHWnd(), false); -// if (Full_Screen) -// { -// while (ShowCursor(false) >= 0); -// while (ShowCursor(true) < 0); -// } - int ianswer = MessageBox((HWND)uid, str, titles[iicon], etypes[itype] | eicons[iicon]); - EnableWindow(MainWindow->getHWnd(), true); -// DialogsOpen--; - switch(ianswer) - { - case IDOK: answer = "ok"; break; - case IDCANCEL: answer = "cancel"; break; - case IDABORT: answer = "abort"; break; - case IDRETRY: answer = "retry"; break; - case IDIGNORE: answer = "ignore"; break; - case IDYES: answer = "yes"; break; - case IDNO: answer = "no"; break; - } -#else - // NYI (assume first answer for now) - switch(itype) - { - case 0: case 3: answer = "ok"; break; - case 1: case 2: answer = "yes"; break; - case 4: answer = "abort"; break; - } -#endif - - lua_pushstring(L, answer); - return 1; -} - -// string gui.popup(string message, string type = "ok", string icon = "message") -// string input.popup(string message, string type = "yesno", string icon = "question") -DEFINE_LUA_FUNCTION(gui_popup, "message[,type=\"ok\"[,icon=\"message\"]]") -{ - return doPopup(L, "ok", "message"); -} -DEFINE_LUA_FUNCTION(input_popup, "message[,type=\"yesno\"[,icon=\"question\"]]") -{ - return doPopup(L, "yesno", "question"); -} - -static const char* FilenameFromPath(const char* path) -{ - const char* slash1 = strrchr(path, '\\'); - const char* slash2 = strrchr(path, '/'); - if(slash1) slash1++; - if(slash2) slash2++; - const char* rv = path; - rv = std::max(rv, slash1); - rv = std::max(rv, slash2); - if(!rv) rv = ""; - return rv; -} - - -static void toCStringConverter(lua_State* L, int i, char*& ptr, int& remaining); - -// compare the contents of two items on the Lua stack to determine if they differ -// only works for relatively simple, saveable items (numbers, strings, bools, nil, and possibly-nested tables of those, up to a certain max length) -// not the best implementation, but good enough for what it's currently used for -static bool luaValueContentsDiffer(lua_State* L, int idx1, int idx2) -{ - static const int maxLen = 8192; - static char str1[maxLen]; - static char str2[maxLen]; - str1[0] = 0; - str2[0] = 0; - char* ptr1 = str1; - char* ptr2 = str2; - int remaining1 = maxLen; - int remaining2 = maxLen; - toCStringConverter(L, idx1, ptr1, remaining1); - toCStringConverter(L, idx2, ptr2, remaining2); - return (remaining1 != remaining2) || (strcmp(str1,str2) != 0); -} - - -// fills output with the path -// also returns a pointer to the first character in the filename (non-directory) part of the path -static char* ConstructScriptSaveDataPath(char* output, int bufferSize, LuaContextInfo& info) -{ -// Get_State_File_Name(output); TODO - char* slash1 = strrchr(output, '\\'); - char* slash2 = strrchr(output, '/'); - if(slash1) slash1[1] = '\0'; - if(slash2) slash2[1] = '\0'; - char* rv = output + strlen(output); - strncat(output, "u.", bufferSize-(strlen(output)+1)); - if(!info.dataSaveLoadKeySet) - strncat(output, FilenameFromPath(info.lastFilename.c_str()), bufferSize-(strlen(output)+1)); - else - snprintf(output+strlen(output), bufferSize-(strlen(output)+1), "%X", info.dataSaveKey); - strncat(output, ".luasav", bufferSize-(strlen(output)+1)); - return rv; -} - -// gens.persistglobalvariables({ -// variable1 = defaultvalue1, -// variable2 = defaultvalue2, -// etc -// }) -// takes a table with variable names as the keys and default values as the values, -// and defines each of those variables names as a global variable, -// setting them equal to the values they had the last time the script exited, -// or (if that isn't available) setting them equal to the provided default values. -// as a special case, if you want the default value for a variable to be nil, -// then put the variable name alone in quotes as an entry in the table without saying "= nil". -// this special case is because tables in lua don't store nil valued entries. -// also, if you change the default value that will reset the variable to the new default. -DEFINE_LUA_FUNCTION(emu_persistglobalvariables, "variabletable") -{ - int uid = luaStateToUIDMap[L]; - LuaContextInfo& info = GetCurrentInfo(); - - // construct a path we can load the persistent variables from - char path [1024] = {0}; - char* pathTypeChrPtr = ConstructScriptSaveDataPath(path, 1024, info); - - // load the previously-saved final variable values from file - LuaSaveData exitData; - { - *pathTypeChrPtr = 'e'; - FILE* persistFile = fopen(path, "rb"); - if(persistFile) - { - exitData.ImportRecords(persistFile); - fclose(persistFile); - } - } - - // load the previously-saved default variable values from file - LuaSaveData defaultData; - { - *pathTypeChrPtr = 'd'; - FILE* defaultsFile = fopen(path, "rb"); - if(defaultsFile) - { - defaultData.ImportRecords(defaultsFile); - fclose(defaultsFile); - } - } - - // loop through the passed-in variables, - // exposing a global variable to the script for each one - // while also keeping a record of their names - // so we can save them (to the persistFile) later when the script exits - int numTables = lua_gettop(L); - for(int i = 1; i <= numTables; i++) - { - luaL_checktype(L, i, LUA_TTABLE); - - lua_pushnil(L); // before first key - int keyIndex = lua_gettop(L); - int valueIndex = keyIndex + 1; - while(lua_next(L, i)) - { - int keyType = lua_type(L, keyIndex); - int valueType = lua_type(L, valueIndex); - if(keyType == LUA_TSTRING && valueType <= LUA_TTABLE && valueType != LUA_TLIGHTUSERDATA) - { - // variablename = defaultvalue, - - // duplicate the key first because lua_next() needs to eat that - lua_pushvalue(L, keyIndex); - lua_insert(L, keyIndex); - } - else if(keyType == LUA_TNUMBER && valueType == LUA_TSTRING) - { - // "variablename", - // or [index] = "variablename", - - // defaultvalue is assumed to be nil - lua_pushnil(L); - } - else - { - luaL_error(L, "'%s' = '%s' entries are not allowed in the table passed to gens.persistglobalvariables()", lua_typename(L,keyType), lua_typename(L,valueType)); - } - - int varNameIndex = valueIndex; - int defaultIndex = valueIndex+1; - - // keep track of the variable name for later - const char* varName = lua_tostring(L, varNameIndex); - info.persistVars.push_back(varName); - unsigned int varNameCRC = crc32(0, (const unsigned char*)varName, strlen(varName)); - info.newDefaultData.SaveRecordPartial(uid, varNameCRC, defaultIndex); - - // load the previous default value for this variable if it exists. - // if the new default is different than the old one, - // assume the user wants to set the value to the new default value - // instead of the previously-saved exit value. - bool attemptPersist = true; - defaultData.LoadRecord(uid, varNameCRC, 1); - lua_pushnil(L); - if(luaValueContentsDiffer(L, defaultIndex, defaultIndex+1)) - attemptPersist = false; - lua_settop(L, defaultIndex); - - if(attemptPersist) - { - // load the previous saved value for this variable if it exists - exitData.LoadRecord(uid, varNameCRC, 1); - if(lua_gettop(L) > defaultIndex) - lua_remove(L, defaultIndex); // replace value with loaded record - lua_settop(L, defaultIndex); - } - - // set the global variable - lua_settable(L, LUA_GLOBALSINDEX); - - assert(lua_gettop(L) == keyIndex); - } - } - - return 0; -} - -static const char* deferredGUIIDString = "lazygui"; - -// store the most recent C function call from Lua (and all its arguments) -// for later evaluation -void DeferFunctionCall(lua_State* L, const char* idstring) -{ - // there might be a cleaner way of doing this using lua_pushcclosure and lua_getref - - int num = lua_gettop(L); - - // get the C function pointer - //lua_CFunction cf = lua_tocfunction(L, -(num+1)); - lua_CFunction cf = (L->ci->func)->value.gc->cl.c.f; - assert(cf); - lua_pushcfunction(L,cf); - - // make a list of the function and its arguments (and also pop those arguments from the stack) - lua_createtable(L, num+1, 0); - lua_insert(L, 1); - for(int n = num+1; n > 0; n--) - lua_rawseti(L, 1, n); - - // put the list into a global array - lua_getfield(L, LUA_REGISTRYINDEX, idstring); - lua_insert(L, 1); - int curSize = lua_objlen(L, 1); - lua_rawseti(L, 1, curSize+1); - - // clean the stack - lua_settop(L, 0); -} -void CallDeferredFunctions(lua_State* L, const char* idstring) -{ - lua_settop(L, 0); - lua_getfield(L, LUA_REGISTRYINDEX, idstring); - int numCalls = lua_objlen(L, 1); - for(int i = 1; i <= numCalls; i++) - { - lua_rawgeti(L, 1, i); // get the function+arguments list - int listSize = lua_objlen(L, 2); - - // push the arguments and the function - for(int j = 1; j <= listSize; j++) - lua_rawgeti(L, 2, j); - - // get and pop the function - lua_CFunction cf = lua_tocfunction(L, -1); - lua_pop(L, 1); - - // shift first argument to slot 1 and call the function - lua_remove(L, 2); - lua_remove(L, 1); - cf(L); - - // prepare for next iteration - lua_settop(L, 0); - lua_getfield(L, LUA_REGISTRYINDEX, idstring); - } - - // clear the list of deferred functions - lua_newtable(L); - lua_setfield(L, LUA_REGISTRYINDEX, idstring); - LuaContextInfo& info = GetCurrentInfo(); - info.numDeferredGUIFuncs = 0; - - // clean the stack - lua_settop(L, 0); -} - -#define MAX_DEFERRED_COUNT 16384 - -bool DeferGUIFuncIfNeeded(lua_State* L) -{ - LuaContextInfo& info = GetCurrentInfo(); - if(info.speedMode == SPEEDMODE_MAXIMUM) - { - // if the mode is "maximum" then discard all GUI function calls - // and pretend it was because we deferred them - return true; - } - if(info.guiFuncsNeedDeferring) - { - if(info.numDeferredGUIFuncs < MAX_DEFERRED_COUNT) - { - // defer whatever function called this one until later - DeferFunctionCall(L, deferredGUIIDString); - info.numDeferredGUIFuncs++; - } - else - { - // too many deferred functions on the same frame - // silently discard the rest - } - return true; - } - - // ok to run the function right now - return false; -} - -void worry(lua_State* L, int intensity) -{ - LuaContextInfo& info = GetCurrentInfo(); - info.worryCount += intensity; -} - -static inline bool isalphaorunderscore(char c) -{ - return isalpha(c) || c == '_'; -} - -static std::vector s_tableAddressStack; // prevents infinite recursion of a table within a table (when cycle is found, print something like table:parent) -static std::vector s_metacallStack; // prevents infinite recursion if something's __tostring returns another table that contains that something (when cycle is found, print the inner result without using __tostring) - -#define APPENDPRINT { int _n = snprintf(ptr, remaining, -#define END ); if(_n >= 0) { ptr += _n; remaining -= _n; } else { remaining = 0; } } -static void toCStringConverter(lua_State* L, int i, char*& ptr, int& remaining) -{ - if(remaining <= 0) - return; - - const char* str = ptr; // for debugging - - // if there is a __tostring metamethod then call it - int usedMeta = luaL_callmeta(L, i, "__tostring"); - if(usedMeta) - { - std::vector::const_iterator foundCycleIter = std::find(s_metacallStack.begin(), s_metacallStack.end(), lua_topointer(L,i)); - if(foundCycleIter != s_metacallStack.end()) - { - lua_pop(L, 1); - usedMeta = false; - } - else - { - s_metacallStack.push_back(lua_topointer(L,i)); - i = lua_gettop(L); - } - } - - switch(lua_type(L, i)) - { - case LUA_TNONE: break; - case LUA_TNIL: APPENDPRINT "nil" END break; - case LUA_TBOOLEAN: APPENDPRINT lua_toboolean(L,i) ? "true" : "false" END break; - case LUA_TSTRING: APPENDPRINT "%s",lua_tostring(L,i) END break; - case LUA_TNUMBER: APPENDPRINT "%.12Lg",lua_tonumber(L,i) END break; - case LUA_TFUNCTION: - if((L->base + i-1)->value.gc->cl.c.isC) - { - lua_CFunction func = lua_tocfunction(L, i); - std::map::iterator iter = s_cFuncInfoMap.find(func); - if(iter == s_cFuncInfoMap.end()) - goto defcase; - APPENDPRINT "function(%s)", iter->second END - } - else - { - APPENDPRINT "function(" END - Proto* p = (L->base + i-1)->value.gc->cl.l.p; - int numParams = p->numparams + (p->is_vararg?1:0); - for (int n=0; nnumparams; n++) - { - APPENDPRINT "%s", getstr(p->locvars[n].varname) END - if(n != numParams-1) - APPENDPRINT "," END - } - if(p->is_vararg) - APPENDPRINT "..." END - APPENDPRINT ")" END - } - break; -defcase:default: APPENDPRINT "%s:%p",luaL_typename(L,i),lua_topointer(L,i) END break; - case LUA_TTABLE: - { - // first make sure there's enough stack space - if(!lua_checkstack(L, 4)) - { - // note that even if lua_checkstack never returns false, - // that doesn't mean we didn't need to call it, - // because calling it retrieves stack space past LUA_MINSTACK - goto defcase; - } - - std::vector::const_iterator foundCycleIter = std::find(s_tableAddressStack.begin(), s_tableAddressStack.end(), lua_topointer(L,i)); - if(foundCycleIter != s_tableAddressStack.end()) - { - int parentNum = s_tableAddressStack.end() - foundCycleIter; - if(parentNum > 1) - APPENDPRINT "%s:parent^%d",luaL_typename(L,i),parentNum END - else - APPENDPRINT "%s:parent",luaL_typename(L,i) END - } - else - { - s_tableAddressStack.push_back(lua_topointer(L,i)); - struct Scope { ~Scope(){ s_tableAddressStack.pop_back(); } } scope; - - APPENDPRINT "{" END - - lua_pushnil(L); // first key - int keyIndex = lua_gettop(L); - int valueIndex = keyIndex + 1; - bool first = true; - bool skipKey = true; // true if we're still in the "array part" of the table - lua_Number arrayIndex = (lua_Number)0; - while(lua_next(L, i)) - { - if(first) - first = false; - else - APPENDPRINT ", " END - if(skipKey) - { - arrayIndex += (lua_Number)1; - bool keyIsNumber = (lua_type(L, keyIndex) == LUA_TNUMBER); - skipKey = keyIsNumber && (lua_tonumber(L, keyIndex) == arrayIndex); - } - if(!skipKey) - { - bool keyIsString = (lua_type(L, keyIndex) == LUA_TSTRING); - bool invalidLuaIdentifier = (!keyIsString || !isalphaorunderscore(*lua_tostring(L, keyIndex))); - if(invalidLuaIdentifier) - if(keyIsString) - APPENDPRINT "['" END - else - APPENDPRINT "[" END - - toCStringConverter(L, keyIndex, ptr, remaining); // key - - if(invalidLuaIdentifier) - if(keyIsString) - APPENDPRINT "']=" END - else - APPENDPRINT "]=" END - else - APPENDPRINT "=" END - } - - bool valueIsString = (lua_type(L, valueIndex) == LUA_TSTRING); - if(valueIsString) - APPENDPRINT "'" END - - toCStringConverter(L, valueIndex, ptr, remaining); // value - - if(valueIsString) - APPENDPRINT "'" END - - lua_pop(L, 1); - - if(remaining <= 0) - { - lua_settop(L, keyIndex-1); // stack might not be clean yet if we're breaking early - break; - } - } - APPENDPRINT "}" END - } - } break; - } - - if(usedMeta) - { - s_metacallStack.pop_back(); - lua_pop(L, 1); - } -} - -static const int s_tempStrMaxLen = 64 * 1024; -static char s_tempStr [s_tempStrMaxLen]; - -static char* rawToCString(lua_State* L, int idx) -{ - int a = idx>0 ? idx : 1; - int n = idx>0 ? idx : lua_gettop(L); - - char* ptr = s_tempStr; - *ptr = 0; - - int remaining = s_tempStrMaxLen; - for(int i = a; i <= n; i++) - { - toCStringConverter(L, i, ptr, remaining); - if(i != n) - APPENDPRINT " " END - } - - if(remaining < 3) - { - while(remaining < 6) - remaining++, ptr--; - APPENDPRINT "..." END - } - APPENDPRINT "\r\n" END - // the trailing newline is so print() can avoid having to do wasteful things to print its newline - // (string copying would be wasteful and calling info.print() twice can be extremely slow) - // at the cost of functions that don't want the newline needing to trim off the last two characters - // (which is a very fast operation and thus acceptable in this case) - - return s_tempStr; -} -#undef APPENDPRINT -#undef END - - -// replacement for luaB_tostring() that is able to show the contents of tables (and formats numbers better, and show function prototypes) -// can be called directly from lua via tostring(), assuming tostring hasn't been reassigned -DEFINE_LUA_FUNCTION(tostring, "...") -{ - char* str = rawToCString(L); - str[strlen(str)-2] = 0; // hack: trim off the \r\n (which is there to simplify the print function's task) - lua_pushstring(L, str); - return 1; -} - -// like rawToCString, but will check if the global Lua function tostring() -// has been replaced with a custom function, and call that instead if so -static const char* toCString(lua_State* L, int idx) -{ - int a = idx>0 ? idx : 1; - int n = idx>0 ? idx : lua_gettop(L); - lua_getglobal(L, "tostring"); - lua_CFunction cf = lua_tocfunction(L,-1); - if(cf == tostring) // optimization: if using our own C tostring function, we can bypass the call through Lua and all the string object allocation that would entail - { - lua_pop(L,1); - return rawToCString(L, idx); - } - else // if the user overrided the tostring function, we have to actually call it and store the temporarily allocated string it returns - { - lua_pushstring(L, ""); - for (int i=a; i<=n; i++) { - lua_pushvalue(L, -2); // function to be called - lua_pushvalue(L, i); // value to print - lua_call(L, 1, 1); - if(lua_tostring(L, -1) == NULL) - luaL_error(L, LUA_QL("tostring") " must return a string to " LUA_QL("print")); - lua_pushstring(L, (iUSR_InfoMessage(str); - return 0; -} - -// provides an easy way to copy a table from Lua -// (simple assignment only makes an alias, but sometimes an independent table is desired) -// currently this function only performs a shallow copy, -// but I think it should be changed to do a deep copy (possibly of configurable depth?) -// that maintains the internal table reference structure -DEFINE_LUA_FUNCTION(copytable, "origtable") -{ - int origIndex = 1; // we only care about the first argument - int origType = lua_type(L, origIndex); - if(origType == LUA_TNIL) - { - lua_pushnil(L); - return 1; - } - if(origType != LUA_TTABLE) - { - luaL_typerror(L, 1, lua_typename(L, LUA_TTABLE)); - lua_pushnil(L); - return 1; - } - - lua_createtable(L, lua_objlen(L,1), 0); - int copyIndex = lua_gettop(L); - - lua_pushnil(L); // first key - int keyIndex = lua_gettop(L); - int valueIndex = keyIndex + 1; - - while(lua_next(L, origIndex)) - { - lua_pushvalue(L, keyIndex); - lua_pushvalue(L, valueIndex); - lua_rawset(L, copyIndex); // copytable[key] = value - lua_pop(L, 1); - } - - // copy the reference to the metatable as well, if any - if(lua_getmetatable(L, origIndex)) - lua_setmetatable(L, copyIndex); - - return 1; // return the new table -} - -// because print traditionally shows the address of tables, -// and the print function I provide instead shows the contents of tables, -// I also provide this function -// (otherwise there would be no way to see a table's address, AFAICT) -DEFINE_LUA_FUNCTION(addressof, "table_or_function") -{ - const void* ptr = lua_topointer(L,-1); - lua_pushinteger(L, (lua_Integer)ptr); - return 1; -} - -DEFINE_LUA_FUNCTION(bitand, "...[integers]") -{ - int rv = ~0; - int numArgs = lua_gettop(L); - for(int i = 1; i <= numArgs; i++) - rv &= luaL_checkinteger(L,i); - lua_settop(L,0); - lua_pushinteger(L,rv); - return 1; -} -DEFINE_LUA_FUNCTION(bitor, "...[integers]") -{ - int rv = 0; - int numArgs = lua_gettop(L); - for(int i = 1; i <= numArgs; i++) - rv |= luaL_checkinteger(L,i); - lua_settop(L,0); - lua_pushinteger(L,rv); - return 1; -} -DEFINE_LUA_FUNCTION(bitxor, "...[integers]") -{ - int rv = 0; - int numArgs = lua_gettop(L); - for(int i = 1; i <= numArgs; i++) - rv ^= luaL_checkinteger(L,i); - lua_settop(L,0); - lua_pushinteger(L,rv); - return 1; -} -DEFINE_LUA_FUNCTION(bitshift, "num,shift") -{ - int num = luaL_checkinteger(L,1); - int shift = luaL_checkinteger(L,2); - if(shift < 0) - num <<= -shift; - else - num >>= shift; - lua_settop(L,0); - lua_pushinteger(L,num); - return 1; -} -DEFINE_LUA_FUNCTION(bitbit, "whichbit") -{ - int rv = 0; - int numArgs = lua_gettop(L); - for(int i = 1; i <= numArgs; i++) - rv |= (1 << luaL_checkinteger(L,i)); - lua_settop(L,0); - lua_pushinteger(L,rv); - return 1; -} - -//int gens_wait(lua_State* L); - -void indicateBusy(lua_State* L, bool busy) -{ - // disabled because there have been complaints about this message being useless spam. - // the script window's title changing should be sufficient, I guess. -/* if(busy) - { - const char* fmt = "script became busy (frozen?)"; - va_list argp; - va_start(argp, fmt); - luaL_where(L, 0); - lua_pushvfstring(L, fmt, argp); - va_end(argp); - lua_concat(L, 2); - LuaContextInfo& info = GetCurrentInfo(); - int uid = luaStateToUIDMap[L]; - if(info.print) - { - info.print(uid, lua_tostring(L,-1)); - info.print(uid, "\r\n"); - } - else - { - fprintf(stderr, "%s\n", lua_tostring(L,-1)); - } - lua_pop(L, 1); - } -*/ -#ifdef _WIN32 - int uid = luaStateToUIDMap[L]; - HWND hDlg = (HWND)uid; - char str [1024]; - GetWindowText(hDlg, str, 1000); - char* extra = strchr(str, '<'); - if(busy) - { - if(!extra) - extra = str + strlen(str), *extra++ = ' '; - strcpy(extra, ""); - } - else - { - if(extra) - extra[-1] = 0; - } - SetWindowText(hDlg, str); -#endif -} - -#define HOOKCOUNT 4096 -#define MAX_WORRY_COUNT 6000 -void LuaRescueHook(lua_State* L, lua_Debug *dbg) -{ - LuaContextInfo& info = GetCurrentInfo(); - - info.worryCount++; - - if(info.stopWorrying && !info.panic) - { - if(info.worryCount > (MAX_WORRY_COUNT >> 2)) - { - // the user already said they're OK with the script being frozen, - // but we don't trust their judgement completely, - // so periodically update the main loop so they have a chance to manually stop it - info.worryCount = 0; -// gens_wait(L); - info.stopWorrying = true; - } - return; - } - - if(info.worryCount > MAX_WORRY_COUNT || info.panic) - { - info.worryCount = 0; - info.stopWorrying = false; - - bool stoprunning = true; - bool stopworrying = true; - if(!info.panic) - { -// Clear_Sound_Buffer(); -#if defined(ASK_USER_ON_FREEZE) && defined(_WIN32) - DialogsOpen++; - int answer = MessageBox(HWnd, "A Lua script has been running for quite a while. Maybe it is in an infinite loop.\n\nWould you like to stop the script?\n\n(Yes to stop it now,\n No to keep running and not ask again,\n Cancel to keep running but ask again later)", "Lua Alert", MB_YESNOCANCEL | MB_DEFBUTTON3 | MB_ICONASTERISK); - DialogsOpen--; - if(answer == IDNO) - stoprunning = false; - if(answer == IDCANCEL) - stopworrying = false; -#else - stoprunning = false; -#endif - } - - if(!stoprunning && stopworrying) - { - info.stopWorrying = true; // don't remove the hook because we need it still running for RequestAbortLuaScript to work - indicateBusy(info.L, true); - } - - if(stoprunning) - { - //lua_sethook(L, NULL, 0, 0); - assert(L->errfunc || L->errorJmp); - luaL_error(L, info.panic ? info.panicMessage : "terminated by user"); - } - - info.panic = false; - } -} - -void printfToOutput(const char* fmt, ...) -{ - va_list list; - va_start(list, fmt); - int len = vscprintf(fmt, list); - char* str = new char[len+1]; - vsprintf(str, fmt, list); - va_end(list); - LuaContextInfo& info = GetCurrentInfo(); - if(info.print) - { - lua_State* L = info.L; - int uid = luaStateToUIDMap[L]; - info.print(uid, str); - info.print(uid, "\r\n"); - worry(L,300); - } - else - { - fprintf(stdout, "%s\n", str); - } - delete[] str; -} - -bool FailVerifyAtFrameBoundary(lua_State* L, const char* funcName, int unstartedSeverity=2, int inframeSeverity=2) -{//TODO -/* if (!((Genesis_Started)||(SegaCD_Started)||(_32X_Started))) - { - static const char* msg = "cannot call %s() when emulation has not started."; - switch(unstartedSeverity) - { - case 0: break; - case 1: printfToOutput(msg, funcName); break; - default: case 2: luaL_error(L, msg, funcName); break; - } - return true; - } - if(Inside_Frame) - { - static const char* msg = "cannot call %s() inside an emulation frame."; - switch(inframeSeverity) - { - case 0: break; - case 1: printfToOutput(msg, funcName); break; - default: case 2: luaL_error(L, msg, funcName); break; - } - return true; - }*/ - return false; -} -/* -// acts similar to normal emulation update -// except without the user being able to activate emulator commands -DEFINE_LUA_FUNCTION(gens_emulateframe, "") -{ - if(FailVerifyAtFrameBoundary(L, "gens.emulateframe", 0,1)) - return 0; - - Update_Emulation_One(HWnd); - Prevent_Next_Frame_Skipping(); // so we don't skip a whole bunch of frames immediately after emulating many frames by this method - - worry(L,300); - return 0; -} - -// acts as a fast-forward emulation update that still renders every frame -// and the user is unable to activate emulator commands during it -DEFINE_LUA_FUNCTION(gens_emulateframefastnoskipping, "") -{ - if(FailVerifyAtFrameBoundary(L, "gens.emulateframefastnoskipping", 0,1)) - return 0; - - Update_Emulation_One_Before(HWnd); - Update_Frame_Hook(); - Update_Emulation_After_Controlled(HWnd, true); - Prevent_Next_Frame_Skipping(); // so we don't skip a whole bunch of frames immediately after a bout of fast-forward frames - - worry(L,200); - return 0; -} - -// acts as a (very) fast-forward emulation update -// where the user is unable to activate emulator commands -DEFINE_LUA_FUNCTION(gens_emulateframefast, "") -{ - if(FailVerifyAtFrameBoundary(L, "gens.emulateframefast", 0,1)) - return 0; - - disableVideoLatencyCompensationCount = VideoLatencyCompensation + 1; - - Update_Emulation_One_Before(HWnd); - - if(FrameCount%16 == 0) // skip rendering 15 out of 16 frames - { - // update once and render - Update_Frame_Hook(); - Update_Emulation_After_Controlled(HWnd, true); - } - else - { - // update once but skip rendering - Update_Frame_Fast_Hook(); - Update_Emulation_After_Controlled(HWnd, false); - } - - Prevent_Next_Frame_Skipping(); // so we don't skip a whole bunch of frames immediately AFTER a bout of fast-forward frames - - worry(L,150); - return 0; -} - -// acts as an extremely-fast-forward emulation update -// that also doesn't render any graphics or generate any sounds, -// and the user is unable to activate emulator commands during it. -// if you load a savestate after calling this function, -// it should leave no trace of having been called, -// so you can do things like generate future emulation states every frame -// while the user continues to see and hear normal emulation -DEFINE_LUA_FUNCTION(gens_emulateframeinvisible, "") -{ - if(FailVerifyAtFrameBoundary(L, "gens.emulateframeinvisible", 0,1)) - return 0; - - int oldDisableSound2 = disableSound2; - int oldDisableRamSearchUpdate = disableRamSearchUpdate; - disableSound2 = true; - disableRamSearchUpdate = true; - - Update_Emulation_One_Before_Minimal(); - Update_Frame_Fast(); - UpdateLagCount(); - - disableSound2 = oldDisableSound2; - disableRamSearchUpdate = oldDisableRamSearchUpdate; - - // disable video latency compensation for a few frames - // because it can get pretty slow if that's doing prediction updates every frame - // when the lua script is also doing prediction updates - disableVideoLatencyCompensationCount = VideoLatencyCompensation + 1; - - worry(L,100); - return 0; -} - -DEFINE_LUA_FUNCTION(gens_speedmode, "mode") -{ - SpeedMode newSpeedMode = SPEEDMODE_NORMAL; - if(lua_isnumber(L,1)) - newSpeedMode = (SpeedMode)luaL_checkinteger(L,1); - else - { - const char* str = luaL_checkstring(L,1); - if(!stricmp(str, "normal")) - newSpeedMode = SPEEDMODE_NORMAL; - else if(!stricmp(str, "nothrottle")) - newSpeedMode = SPEEDMODE_NOTHROTTLE; - else if(!stricmp(str, "turbo")) - newSpeedMode = SPEEDMODE_TURBO; - else if(!stricmp(str, "maximum")) - newSpeedMode = SPEEDMODE_MAXIMUM; - } - - LuaContextInfo& info = GetCurrentInfo(); - info.speedMode = newSpeedMode; - RefreshScriptSpeedStatus(); - return 0; -} - -// tells Gens to wait while the script is doing calculations -// can call this periodically instead of gens.frameadvance -// note that the user can use hotkeys at this time -// (e.g. a savestate could possibly get loaded before gens.wait() returns) -DEFINE_LUA_FUNCTION(gens_wait, "") -{ - LuaContextInfo& info = GetCurrentInfo(); - - switch(info.speedMode) - { - default: - case SPEEDMODE_NORMAL: - Step_Gens_MainLoop(true, false); - break; - case SPEEDMODE_NOTHROTTLE: - case SPEEDMODE_TURBO: - case SPEEDMODE_MAXIMUM: - Step_Gens_MainLoop(Paused!=0, false); - break; - } - - return 0; -} -*/ - - - -/* -DEFINE_LUA_FUNCTION(gens_frameadvance, "") -{ - if(FailVerifyAtFrameBoundary(L, "gens.frameadvance", 0,1)) - return gens_wait(L); - - int uid = luaStateToUIDMap[L]; - LuaContextInfo& info = GetCurrentInfo(); - - if(!info.ranFrameAdvance) - { - // otherwise we'll never see the first frame of GUI drawing - if(info.speedMode != SPEEDMODE_MAXIMUM) - Show_Genesis_Screen(); - info.ranFrameAdvance = true; - } - - switch(info.speedMode) - { - default: - case SPEEDMODE_NORMAL: - while(!Step_Gens_MainLoop(true, true) && !info.panic); - break; - case SPEEDMODE_NOTHROTTLE: - while(!Step_Gens_MainLoop(Paused!=0, false) && !info.panic); - if(!(FastForwardKeyDown && (GetActiveWindow()==HWnd || BackgroundInput))) - gens_emulateframefastnoskipping(L); - else - gens_emulateframefast(L); - break; - case SPEEDMODE_TURBO: - while(!Step_Gens_MainLoop(Paused!=0, false) && !info.panic); - gens_emulateframefast(L); - break; - case SPEEDMODE_MAXIMUM: - while(!Step_Gens_MainLoop(Paused!=0, false) && !info.panic); - gens_emulateframeinvisible(L); - break; - } - return 0; -} - -DEFINE_LUA_FUNCTION(gens_pause, "") -{ - LuaContextInfo& info = GetCurrentInfo(); - - Paused = 1; - while(!Step_Gens_MainLoop(true, false) && !info.panic); - - // allow the user to not have to manually unpause - // after restarting a script that used gens.pause() - if(info.panic) - Paused = 0; - - return 0; -} - -DEFINE_LUA_FUNCTION(gens_unpause, "") -{ - LuaContextInfo& info = GetCurrentInfo(); - - Paused = 0; - return 0; -} - -DEFINE_LUA_FUNCTION(gens_redraw, "") -{ - Show_Genesis_Screen(); - worry(L,250); - return 0; -} - -*/ - -DEFINE_LUA_FUNCTION(memory_readbyte, "address") -{ - int address = luaL_checkinteger(L,1); - unsigned char value = (unsigned char)(_MMU_read08(address) & 0xFF); - lua_settop(L,0); - lua_pushinteger(L, value); - return 1; // we return the number of return values -} -DEFINE_LUA_FUNCTION(memory_readbytesigned, "address") -{ - int address = luaL_checkinteger(L,1); - signed char value = (signed char)(_MMU_read08(address) & 0xFF); - lua_settop(L,0); - lua_pushinteger(L, value); - return 1; -} -DEFINE_LUA_FUNCTION(memory_readword, "address") -{ - int address = luaL_checkinteger(L,1); - unsigned short value = (unsigned short)(_MMU_read16(address) & 0xFFFF); - lua_settop(L,0); - lua_pushinteger(L, value); - return 1; -} -DEFINE_LUA_FUNCTION(memory_readwordsigned, "address") -{ - int address = luaL_checkinteger(L,1); - signed short value = (signed short)(_MMU_read16(address) & 0xFFFF); - lua_settop(L,0); - lua_pushinteger(L, value); - return 1; -} -DEFINE_LUA_FUNCTION(memory_readdword, "address") -{ - int address = luaL_checkinteger(L,1); - unsigned long value = (unsigned long)(_MMU_read32(address)); - lua_settop(L,0); - lua_pushinteger(L, value); - return 1; -} -DEFINE_LUA_FUNCTION(memory_readdwordsigned, "address") -{ - int address = luaL_checkinteger(L,1); - signed long value = (signed long)(_MMU_read32(address)); - lua_settop(L,0); - lua_pushinteger(L, value); - return 1; -} - -DEFINE_LUA_FUNCTION(memory_writebyte, "address,value") -{ - int address = luaL_checkinteger(L,1); - unsigned char value = (unsigned char)(luaL_checkinteger(L,2) & 0xFF); - _MMU_write08(address, value); - return 0; -} -DEFINE_LUA_FUNCTION(memory_writeword, "address,value") -{ - int address = luaL_checkinteger(L,1); - unsigned short value = (unsigned short)(luaL_checkinteger(L,2) & 0xFFFF); - _MMU_write16(address, value); - return 0; -} -DEFINE_LUA_FUNCTION(memory_writedword, "address,value") -{ - int address = luaL_checkinteger(L,1); - unsigned long value = (unsigned long)(luaL_checkinteger(L,2)); - _MMU_write32(address, value); - return 0; -} - -DEFINE_LUA_FUNCTION(memory_readbyterange, "address,length") -{ - int address = luaL_checkinteger(L,1); - int length = luaL_checkinteger(L,2); - - if(length < 0) - { - address += length; - length = -length; - } - - // push the array - lua_createtable(L, abs(length), 0); - - // put all the values into the (1-based) array - for(int a = address, n = 1; n <= length; a++, n++) - { -// if(IsHardwareAddressValid(a)) -// { - unsigned char value = (unsigned char)(_MMU_read08(address) & 0xFF); - lua_pushinteger(L, value); - lua_rawseti(L, -2, n); -// } - // else leave the value nil - } - - return 1; -} -/* -DEFINE_LUA_FUNCTION(memory_isvalid, "address") -{ - int address = luaL_checkinteger(L,1); - lua_settop(L,0); - lua_pushboolean(L, IsHardwareAddressValid(address)); - return 1; -} -*/ -struct registerPointerMap -{ - const char* registerName; - unsigned int* pointer; - int dataSize; -}; - -#define RPM_ENTRY(name,var) {name, (unsigned int*)&var, sizeof(var)}, - -registerPointerMap m68kPointerMap [] = { -/* RPM_ENTRY("a0", main68k_context.areg[0]) - RPM_ENTRY("a1", main68k_context.areg[1]) - RPM_ENTRY("a2", main68k_context.areg[2]) - RPM_ENTRY("a3", main68k_context.areg[3]) - RPM_ENTRY("a4", main68k_context.areg[4]) - RPM_ENTRY("a5", main68k_context.areg[5]) - RPM_ENTRY("a6", main68k_context.areg[6]) - RPM_ENTRY("a7", main68k_context.areg[7]) - RPM_ENTRY("d0", main68k_context.dreg[0]) - RPM_ENTRY("d1", main68k_context.dreg[1]) - RPM_ENTRY("d2", main68k_context.dreg[2]) - RPM_ENTRY("d3", main68k_context.dreg[3]) - RPM_ENTRY("d4", main68k_context.dreg[4]) - RPM_ENTRY("d5", main68k_context.dreg[5]) - RPM_ENTRY("d6", main68k_context.dreg[6]) - RPM_ENTRY("d7", main68k_context.dreg[7]) - RPM_ENTRY("pc", main68k_context.pc) - RPM_ENTRY("sr", main68k_context.sr)*/ - {} -}; -registerPointerMap s68kPointerMap [] = {/* - RPM_ENTRY("a0", sub68k_context.areg[0]) - RPM_ENTRY("a1", sub68k_context.areg[1]) - RPM_ENTRY("a2", sub68k_context.areg[2]) - RPM_ENTRY("a3", sub68k_context.areg[3]) - RPM_ENTRY("a4", sub68k_context.areg[4]) - RPM_ENTRY("a5", sub68k_context.areg[5]) - RPM_ENTRY("a6", sub68k_context.areg[6]) - RPM_ENTRY("a7", sub68k_context.areg[7]) - RPM_ENTRY("d0", sub68k_context.dreg[0]) - RPM_ENTRY("d1", sub68k_context.dreg[1]) - RPM_ENTRY("d2", sub68k_context.dreg[2]) - RPM_ENTRY("d3", sub68k_context.dreg[3]) - RPM_ENTRY("d4", sub68k_context.dreg[4]) - RPM_ENTRY("d5", sub68k_context.dreg[5]) - RPM_ENTRY("d6", sub68k_context.dreg[6]) - RPM_ENTRY("d7", sub68k_context.dreg[7]) - RPM_ENTRY("pc", sub68k_context.pc) - RPM_ENTRY("sr", sub68k_context.sr)*/ - {} -}; - -struct cpuToRegisterMap -{ - const char* cpuName; - registerPointerMap* rpmap; -} -cpuToRegisterMaps [] = -{ - {"m68k.", m68kPointerMap}, - {"main.", m68kPointerMap}, - {"s68k.", s68kPointerMap}, - {"sub.", s68kPointerMap}, - {"", m68kPointerMap}, -}; - - -DEFINE_LUA_FUNCTION(memory_getregister, "cpu_dot_registername_string") -{ - const char* qualifiedRegisterName = luaL_checkstring(L,1); - lua_settop(L,0); - for(int cpu = 0; cpu < sizeof(cpuToRegisterMaps)/sizeof(*cpuToRegisterMaps); cpu++) - { - cpuToRegisterMap ctrm = cpuToRegisterMaps[cpu]; - int cpuNameLen = strlen(ctrm.cpuName); - if(!strnicmp(qualifiedRegisterName, ctrm.cpuName, cpuNameLen)) - { - qualifiedRegisterName += cpuNameLen; - for(int reg = 0; ctrm.rpmap[reg].dataSize; reg++) - { - registerPointerMap rpm = ctrm.rpmap[reg]; - if(!stricmp(qualifiedRegisterName, rpm.registerName)) - { - switch(rpm.dataSize) - { default: - case 1: lua_pushinteger(L, *(unsigned char*)rpm.pointer); break; - case 2: lua_pushinteger(L, *(unsigned short*)rpm.pointer); break; - case 4: lua_pushinteger(L, *(unsigned long*)rpm.pointer); break; - } - return 1; - } - } - lua_pushnil(L); - return 1; - } - } - lua_pushnil(L); - return 1; -} -DEFINE_LUA_FUNCTION(memory_setregister, "cpu_dot_registername_string,value") -{ - const char* qualifiedRegisterName = luaL_checkstring(L,1); - unsigned long value = (unsigned long)(luaL_checkinteger(L,2)); - lua_settop(L,0); - for(int cpu = 0; cpu < sizeof(cpuToRegisterMaps)/sizeof(*cpuToRegisterMaps); cpu++) - { - cpuToRegisterMap ctrm = cpuToRegisterMaps[cpu]; - int cpuNameLen = strlen(ctrm.cpuName); - if(!strnicmp(qualifiedRegisterName, ctrm.cpuName, cpuNameLen)) - { - qualifiedRegisterName += cpuNameLen; - for(int reg = 0; ctrm.rpmap[reg].dataSize; reg++) - { - registerPointerMap rpm = ctrm.rpmap[reg]; - if(!stricmp(qualifiedRegisterName, rpm.registerName)) - { - switch(rpm.dataSize) - { default: - case 1: *(unsigned char*)rpm.pointer = (unsigned char)(value & 0xFF); break; - case 2: *(unsigned short*)rpm.pointer = (unsigned short)(value & 0xFFFF); break; - case 4: *(unsigned long*)rpm.pointer = value; break; - } - return 0; - } - } - return 0; - } - } - return 0; -} - -/* -DEFINE_LUA_FUNCTION(state_create, "[location]") -{ - if(lua_isnumber(L,1)) - { - // simply return the integer that got passed in - // (that's as good a savestate object as any for a numbered savestate slot) - lua_settop(L,1); - return 1; - } - - int len = GENESIS_STATE_LENGTH; - if (SegaCD_Started) len += SEGACD_LENGTH_EX; - if (_32X_Started) len += G32X_LENGTH_EX; - if (!((Genesis_Started)||(SegaCD_Started)||(_32X_Started))) - len += std::max(SEGACD_LENGTH_EX, G32X_LENGTH_EX); - - // allocate the in-memory/anonymous savestate - unsigned char* stateBuffer = (unsigned char*)lua_newuserdata(L, len + 16); // 16 is for performance alignment reasons - stateBuffer[0] = 0; - - return 1; -} - -// savestate.save(location [, option]) -// saves the current emulation state to the given location -// you can pass in either a savestate file number (an integer), -// OR you can pass in a savestate object that was returned by savestate.create() -// if option is "quiet" then any warning messages will be suppressed -// if option is "scriptdataonly" then the state will not actually be saved, but any save callbacks will still get called and their results will be saved (see savestate.registerload()/savestate.registersave()) -DEFINE_LUA_FUNCTION(state_save, "location[,option]") -{ - const char* option = (lua_type(L,2) == LUA_TSTRING) ? lua_tostring(L,2) : NULL; - if(option) - { - if(!stricmp(option, "quiet")) // I'm not sure if saving can generate warning messages, but we might as well support suppressing them should they turn out to exist - g_disableStatestateWarnings = true; - else if(!stricmp(option, "scriptdataonly")) - g_onlyCallSavestateCallbacks = true; - } - struct Scope { ~Scope(){ g_disableStatestateWarnings = false; g_onlyCallSavestateCallbacks = false; } } scope; // needs to run even if the following code throws an exception... maybe I should have put this in a "finally" block instead, but this project seems to have something against using the "try" statement - - if(!g_onlyCallSavestateCallbacks && FailVerifyAtFrameBoundary(L, "savestate.save", 2,2)) - return 0; - - int type = lua_type(L,1); - switch(type) - { - case LUA_TNUMBER: // numbered save file - default: - { - int stateNumber = luaL_checkinteger(L,1); - Set_Current_State(stateNumber, false,false); - char Name [1024] = {0}; - Get_State_File_Name(Name); - Save_State(Name); - } return 0; - case LUA_TUSERDATA: // in-memory save slot - { - unsigned char* stateBuffer = (unsigned char*)lua_touserdata(L,1); - if(stateBuffer) - { - stateBuffer += ((16 - (int)stateBuffer) & 15); // for performance alignment reasons - Save_State_To_Buffer(stateBuffer); - } - } return 0; - } -} - -// savestate.load(location [, option]) -// loads the current emulation state from the given location -// you can pass in either a savestate file number (an integer), -// OR you can pass in a savestate object that was returned by savestate.create() and has already saved to with savestate.save() -// if option is "quiet" then any warning messages will be suppressed -// if option is "scriptdataonly" then the state will not actually be loaded, but load callbacks will still get called and supplied with the data saved by save callbacks (see savestate.registerload()/savestate.registersave()) -DEFINE_LUA_FUNCTION(state_load, "location[,option]") -{ - const char* option = (lua_type(L,2) == LUA_TSTRING) ? lua_tostring(L,2) : NULL; - if(option) - { - if(!stricmp(option, "quiet")) - g_disableStatestateWarnings = true; - else if(!stricmp(option, "scriptdataonly")) - g_onlyCallSavestateCallbacks = true; - } - struct Scope { ~Scope(){ g_disableStatestateWarnings = false; g_onlyCallSavestateCallbacks = false; } } scope; // needs to run even if the following code throws an exception... maybe I should have put this in a "finally" block instead, but this project seems to have something against using the "try" statement - - if(!g_onlyCallSavestateCallbacks && FailVerifyAtFrameBoundary(L, "savestate.load", 2,2)) - return 0; - - g_disableStatestateWarnings = lua_toboolean(L,2) != 0; - - int type = lua_type(L,1); - switch(type) - { - case LUA_TNUMBER: // numbered save file - default: - { - LuaContextInfo& info = GetCurrentInfo(); - if(info.rerecordCountingDisabled) - SkipNextRerecordIncrement = true; - int stateNumber = luaL_checkinteger(L,1); - Set_Current_State(stateNumber, false,!g_disableStatestateWarnings); - char Name [1024] = {0}; - Get_State_File_Name(Name); - Load_State(Name); - } return 0; - case LUA_TUSERDATA: // in-memory save slot - { - unsigned char* stateBuffer = (unsigned char*)lua_touserdata(L,1); - if(stateBuffer) - { - stateBuffer += ((16 - (int)stateBuffer) & 15); // for performance alignment reasons - if(stateBuffer[0]) - Load_State_From_Buffer(stateBuffer); - else // the first byte of a valid savestate is never 0 - luaL_error(L, "attempted to load an anonymous savestate before saving it"); - } - } return 0; - } -} -*/ -// savestate.loadscriptdata(location) -// returns the user data associated with the given savestate -// without actually loading the rest of that savestate or calling any callbacks. -// you can pass in either a savestate file number (an integer), -// OR you can pass in a savestate object that was returned by savestate.create() -// but note that currently only non-anonymous savestates can have associated scriptdata -// -// also note that this returns the same values -// that would be passed into a registered load function. -// the main reason this exists also is so you can register a load function that -// chooses whether or not to load the scriptdata instead of always loading it, -// and also to provide a nicer interface for loading scriptdata -// without needing to trigger savestate loading first -//DEFINE_LUA_FUNCTION(state_loadscriptdata, "location") -//{ -// int type = lua_type(L,1); -// switch(type) -// { -// case LUA_TNUMBER: // numbered save file -// default: -// { -// int stateNumber = luaL_checkinteger(L,1); -// Set_Current_State(stateNumber, false,false); -// char Name [1024] = {0}; -// Get_State_File_Name(Name); -// { -// LuaSaveData saveData; -// -// char luaSaveFilename [512]; -// strncpy(luaSaveFilename, Name, 512); -// luaSaveFilename[512-(1+7/*strlen(".luasav")*/)] = '\0'; -// strcat(luaSaveFilename, ".luasav"); -// FILE* luaSaveFile = fopen(luaSaveFilename, "rb"); -// if(luaSaveFile) -// { -// saveData.ImportRecords(luaSaveFile); -// fclose(luaSaveFile); -// -// int uid = luaStateToUIDMap[L]; -// LuaContextInfo& info = GetCurrentInfo(); -// -// lua_settop(L, 0); -// saveData.LoadRecord(uid, info.dataLoadKey, (unsigned int)-1); -// return lua_gettop(L); -// } -// } -// } return 0; -// case LUA_TUSERDATA: // in-memory save slot -// { // there can be no user data associated with those, at least not yet -// } return 0; -// } -//} - -// savestate.savescriptdata(location) -// same as savestate.save(location, "scriptdataonly") -// only provided for consistency with savestate.loadscriptdata(location) -/*DEFINE_LUA_FUNCTION(state_savescriptdata, "location") -{ - lua_settop(L, 1); - lua_pushstring(L, "scriptdataonly"); - return state_save(L); -} -*/ - -//joypad lib - -static const char *button_mappings[] = { -"debug","r","l","x","y","a","b","start","select","up","down","left","right" -}; - -// table joypad.read(int which = 1) -// -// Reads the joypads as inputted by the user. -static int joy_get(lua_State *L) { - - uint16 buttons = nds.pad; - - lua_newtable(L); - - int i; - for (i = 0; i < 16; i++) { - if (buttons & (1<= 2) color |= 0xFF; - return color; - } - else for(int i = 0; i 255) value = 255; - switch(key) - { - case 1: case 'r': color |= value << 24; break; - case 2: case 'g': color |= value << 16; break; - case 3: case 'b': color |= value << 8; break; - case 4: case 'a': color = (color & ~0xFF) | value; break; - } - lua_pop(L, 1); - } - return color; - } break; - case LUA_TFUNCTION: - return 0; - } - return defaultColor; -} -int getcolor(lua_State *L, int idx, int defaultColor) -{ - int color = getcolor_unmodified(L, idx, defaultColor); - LuaContextInfo& info = GetCurrentInfo(); - if(info.transparencyModifier != 255) - { - int alpha = (((color & 0xFF) * info.transparencyModifier) / 255); - if(alpha > 255) alpha = 255; - color = (color & ~0xFF) | alpha; - } - return color; -} - -// r,g,b,a = gui.parsecolor(color) -// examples: -// local r,g,b = gui.parsecolor("green") -// local r,g,b,a = gui.parsecolor(0x7F3FFF7F) -DEFINE_LUA_FUNCTION(gui_parsecolor, "color") -{ - int color = getcolor_unmodified(L, 1, 0); - int r = (color & 0xFF000000) >> 24; - int g = (color & 0x00FF0000) >> 16; - int b = (color & 0x0000FF00) >> 8; - int a = (color & 0x000000FF); - lua_pushinteger(L, r); - lua_pushinteger(L, g); - lua_pushinteger(L, b); - lua_pushinteger(L, a); - return 4; -} -/* -DEFINE_LUA_FUNCTION(gui_text, "x,y,str[,color=\"white\"[,outline=\"black\"]]") -{ - if(DeferGUIFuncIfNeeded(L)) - return 0; // we have to wait until later to call this function because gens hasn't emulated the next frame yet - // (the only way to avoid this deferring is to be in a gui.register or gens.registerafter callback) - - int x = luaL_checkinteger(L,1) & 0xFFFF; - int y = luaL_checkinteger(L,2) & 0xFFFF; - const char* str = toCString(L,3); // better than using luaL_checkstring here (more permissive) - - if(str && *str) - { - int foreColor = getcolor(L,4,0xFFFFFFFF); - int backColor = getcolor(L,5,0x000000FF); - PutText2(str, x, y, foreColor, backColor); - } - - return 0; -} - -static inline void ApplyShaderToPixel(int off, std::map& cachedShaderResults, lua_State* L, int idx) -{ - int color; - if (Bits32) - color = MD_Screen32[off]; - else - color = DrawUtil::Pix16To32(MD_Screen[off]); - - int result; - std::map::const_iterator found = cachedShaderResults.find(color); - if(found != cachedShaderResults.end()) - { - result = found->second; - } - else - { - int b = (color & 0x000000FF); - int g = (color & 0x0000FF00) >> 8; - int r = (color & 0x00FF0000) >> 16; - - lua_pushvalue(L, idx); - lua_pushinteger(L, r); - lua_pushinteger(L, g); - lua_pushinteger(L, b); - - lua_call(L, 3, 3); - - int rout = lua_tointeger(L, -3); - int gout = lua_tointeger(L, -2); - int bout = lua_tointeger(L, -1); - lua_pop(L,3); - if(rout < 0) rout = 0; if(rout > 255) rout = 255; - if(gout < 0) gout = 0; if(gout > 255) gout = 255; - if(bout < 0) bout = 0; if(bout > 255) bout = 255; - - result = DrawUtil::Make32(rout,gout,bout); - cachedShaderResults[color] = result; - } - if (Bits32) - MD_Screen32[off] = result; - else - MD_Screen[off] = DrawUtil::Pix32To16(result); -} - -#define SWAP_INTEGERS(x,y) x^=y, y^=x, x^=y - -// performance note: for me, this function is extremely slow in debug builds, -// but when compiled with full optimizations turned on it becomes very fast. -void ApplyShaderToBox(int x1, int y1, int x2, int y2, lua_State* L, int idx) -{ - if((x1 < 0 && x2 < 0) || (x1 > 319 && x2 > 319) || (y1 < 0 && y2 < 0) || (y1 > 223 && y2 > 223)) - return; - - // require x1,y1 <= x2,y2 - if (x1 > x2) SWAP_INTEGERS(x1,x2); - if (y1 > y2) SWAP_INTEGERS(y1,y2); - - // avoid trying to draw any offscreen pixels - if (x1 < 0) x1 = 0; - if (x1 > 319) x1 = 319; - if (x2 < 0) x2 = 0; - if (x2 > 319) x2 = 319; - if (y1 < 0) y1 = 0; - if (y1 > 223) y1 = 223; - if (y2 < 0) y2 = 0; - if (y2 > 223) y2 = 223; - - std::map cachedShaderResults; - - for(short y = y1; y <= y2; y++) - { - int off = (y * 336) + x1 + 8; - for(short x = x1; x <= x2; x++, off++) - { - ApplyShaderToPixel(off, cachedShaderResults, L, idx); - } - } -} - -void ApplyShaderToBoxOutline(int x1, int y1, int x2, int y2, lua_State* L, int idx) -{ - // require x1,y1 <= x2,y2 - if (x1 > x2) SWAP_INTEGERS(x1,x2); - if (y1 > y2) SWAP_INTEGERS(y1,y2); - - // avoid trying to draw any offscreen pixels - if (x1 < -1) x1 = -1; - if (x1 > 320) x1 = 320; - if (x2 < -1) x2 = -1; - if (x2 > 320) x2 = 320; - if (y1 < -1) y1 = -1; - if (y1 > 224) y1 = 224; - if (y2 < -1) y2 = -1; - if (y2 > 224) y2 = 224; - - std::map cachedShaderResults; - - if(y1 >= 0 && y1 < 224) - for (short x = x1+1; x < x2; x++) - ApplyShaderToPixel((y1 * 336) + x + 8, cachedShaderResults, L, idx); - if(x1 >= 0 && x1 < 320) - for (short y = y1; y <= y2; y++) - ApplyShaderToPixel((y * 336) + x1 + 8, cachedShaderResults, L, idx); - if(y1 != y2 && y2 >= 0 && y2 < 224) - for (short x = x1+1; x < x2; x++) - ApplyShaderToPixel((y2 * 336) + x + 8, cachedShaderResults, L, idx); - if(x1 != x2 && x2 >= 0 && x2 < 320) - for (short y = y1; y <= y2; y++) - ApplyShaderToPixel((y * 336) + x2 + 8, cachedShaderResults, L, idx); -} - -int amplifyShader(lua_State* L) -{ - int rin = lua_tointeger(L, 1); - int gin = lua_tointeger(L, 2); - int bin = lua_tointeger(L, 3); - lua_pushvalue(L, lua_upvalueindex(1)); - lua_insert(L, 1); - lua_call(L, 3, 3); - int rout = lua_tointeger(L, 1); - int gout = lua_tointeger(L, 2); - int bout = lua_tointeger(L, 3); - lua_settop(L, 0); - lua_pushinteger(L, rout*4 - rin*3); - lua_pushinteger(L, gout*4 - gin*3); - lua_pushinteger(L, bout*4 - bin*3); - return 3; -}*/ -/* -DEFINE_LUA_FUNCTION(gui_box, "x1,y1,x2,y2[,fill[,outline]]") -{ - if(DeferGUIFuncIfNeeded(L)) - return 0; - - int x1 = luaL_checkinteger(L,1); // & 0xFFFF removed because it was turning -1 into 65535 which screwed up the out-of-bounds checking in ApplyShaderToBox - int y1 = luaL_checkinteger(L,2); - int x2 = luaL_checkinteger(L,3); - int y2 = luaL_checkinteger(L,4); - int fillcolor = getcolor(L,5,0xFFFFFF3F); - int outlinecolor = getcolor(L,6,fillcolor|0xFF); - if(!lua_isfunction(L,5) || !lua_isnoneornil(L,6)) - { - DrawBoxPP2(x1, y1, x2, y2, fillcolor, outlinecolor); - if(lua_isfunction(L,5)) - ApplyShaderToBox(x1+1,y1+1,x2-1,y2-1, L,5); - if(lua_isfunction(L,6)) - ApplyShaderToBoxOutline(x1,y1,x2,y2, L,6); - } - else // fill is a shader and outline is not specified, so make the outline a more "opaque" version of the shader to match up with the default color behavior - { - ApplyShaderToBox(x1+1,y1+1,x2-1,y2-1, L,5); - lua_settop(L, 5); - lua_pushvalue(L, 5); - lua_pushcclosure(L, amplifyShader, 1); - ApplyShaderToBoxOutline(x1,y1,x2,y2, L,6); - } - - return 0; -} -// gui.setpixel(x,y,color) -// color can be a RGB web color like '#ff7030', or with alpha RGBA like '#ff703060' -// or it can be an RGBA hex number like 0xFF703060 -// or it can be a preset color like 'red', 'orange', 'blue', 'white', etc. -DEFINE_LUA_FUNCTION(gui_pixel, "x,y[,color=\"white\"]") -{ - if(DeferGUIFuncIfNeeded(L)) - return 0; - - int x = luaL_checkinteger(L,1) & 0xFFFF; - int y = luaL_checkinteger(L,2) & 0xFFFF; - int color = getcolor(L,3,0xFFFFFFFF); - int color32 = color>>8; - int color16 = DrawUtil::Pix32To16(color32); - int Opac = color & 0xFF; - - if(Opac) - Pixel(x, y, color32, color16, 0, Opac); - - return 0; -} -// r,g,b = gui.getpixel(x,y) -DEFINE_LUA_FUNCTION(gui_getpixel, "x,y") -{ - int x = luaL_checkinteger(L,1); - int y = luaL_checkinteger(L,2); - - int xres = ((VDP_Reg.Set4 & 0x1) || Debug || !Game || !FrameCount) ? 320 : 256; - int yres = ((VDP_Reg.Set2 & 0x8) && !(Debug || !Game || !FrameCount)) ? 240 : 224; - - x = std::max(0,std::min(xres,x)); - y = std::max(0,std::min(yres,y)); - - int off = (y * 336) + x + 8; - - int color; - if (Bits32) - color = MD_Screen32[off]; - else - color = DrawUtil::Pix16To32(MD_Screen[off]); - - int b = (color & 0x000000FF); - int g = (color & 0x0000FF00) >> 8; - int r = (color & 0x00FF0000) >> 16; - - lua_pushinteger(L, r); - lua_pushinteger(L, g); - lua_pushinteger(L, b); - - return 3; -} -DEFINE_LUA_FUNCTION(gui_line, "x1,y1,x2,y2[,color=\"white\"[,skipfirst=false]]") -{ - if(DeferGUIFuncIfNeeded(L)) - return 0; - - int x1 = luaL_checkinteger(L,1) & 0xFFFF; - int y1 = luaL_checkinteger(L,2) & 0xFFFF; - int x2 = luaL_checkinteger(L,3) & 0xFFFF; - int y2 = luaL_checkinteger(L,4) & 0xFFFF; - int color = getcolor(L,5,0xFFFFFFFF); - int color32 = color>>8; - int color16 = DrawUtil::Pix32To16(color32); - int Opac = color & 0xFF; - - if(Opac) - { - int skipFirst = lua_toboolean(L,6); - DrawLine(x1, y1, x2, y2, color32, color16, 0, Opac, skipFirst); - } - - return 0; -} - -// gui.opacity(number alphaValue) -// sets the transparency of subsequent draw calls -// 0.0 is completely transparent, 1.0 is completely opaque -// non-integer values are supported and meaningful, as are values greater than 1.0 -// it is not necessary to use this function to get transparency (or the less-recommended gui.transparency() either), -// because you can provide an alpha value in the color argument of each draw call. -// however, it can be convenient to be able to globally modify the drawing transparency -DEFINE_LUA_FUNCTION(gui_setopacity, "alpha_0_to_1") -{ - lua_Number opacF = luaL_checknumber(L,1); - opacF *= 255.0; - if(opacF < 0) opacF = 0; - int opac; - lua_number2int(opac, opacF); - LuaContextInfo& info = GetCurrentInfo(); - info.transparencyModifier = opac; - return 0; -} - -// gui.transparency(number transparencyValue) -// sets the transparency of subsequent draw calls -// 0.0 is completely opaque, 4.0 is completely transparent -// non-integer values are supported and meaningful, as are values less than 0.0 -// this is a legacy function, and the range is from 0 to 4 solely for this reason -// it does the exact same thing as gui.opacity() but with a different argument range -DEFINE_LUA_FUNCTION(gui_settransparency, "transparency_4_to_0") -{ - lua_Number transp = luaL_checknumber(L,1); - lua_Number opacF = 4 - transp; - opacF *= 255.0 / 4.0; - if(opacF < 0) opacF = 0; - int opac; - lua_number2int(opac, opacF); - LuaContextInfo& info = GetCurrentInfo(); - info.transparencyModifier = opac; - return 0; -} - -// takes a screenshot and returns it in gdstr format -// example: gd.createFromGdStr(gui.gdscreenshot()):png("outputimage.png") -DEFINE_LUA_FUNCTION(gui_gdscreenshot, "") -{ - int width = ((VDP_Reg.Set4 & 0x1) || Debug || !Game || !FrameCount) ? 320 : 256; - int height = ((VDP_Reg.Set2 & 0x8) && !(Debug || !Game || !FrameCount)) ? 240 : 224; - int size = 11 + width * height * 4; - - char* str = new char[size+1]; - str[size] = 0; - unsigned char* ptr = (unsigned char*)str; - - // GD format header for truecolor image (11 bytes) - *ptr++ = (65534 >> 8) & 0xFF; - *ptr++ = (65534 ) & 0xFF; - *ptr++ = (width >> 8) & 0xFF; - *ptr++ = (width ) & 0xFF; - *ptr++ = (height >> 8) & 0xFF; - *ptr++ = (height ) & 0xFF; - *ptr++ = 1; - *ptr++ = 255; - *ptr++ = 255; - *ptr++ = 255; - *ptr++ = 255; - - unsigned char *Src = Bits32 ? (unsigned char*)(MD_Screen32+8) : (unsigned char*)(MD_Screen+8); - - if(Bits32) - { - for(int y = 0; y < height; y++, Src += 336*4) - { - for(int x = 0; x < width; x++) - { - *ptr++ = Src[4*x+3]; - *ptr++ = Src[4*x+2]; - *ptr++ = Src[4*x+1]; - *ptr++ = Src[4*x+0]; - } - } - } - else if((Mode_555 & 1) == 0) - { - for(int y = 0; y < height; y++, Src += 336*2) - { - for(int x = 0; x < width; x++) - { - int pix = DrawUtil::Pix16To32((pix16)(Src[2*x]+(Src[2*x+1]<<8))); - *ptr++ = ((unsigned char*)&pix)[3]; - *ptr++ = ((unsigned char*)&pix)[2]; - *ptr++ = ((unsigned char*)&pix)[1]; - *ptr++ = ((unsigned char*)&pix)[0]; - } - } - } - else - { - for(int y = 0; y < height; y++, Src += 336*2) - { - for(int x = 0; x < width; x++) - { - int pix = DrawUtil::Pix15To32((pix15)(Src[2*x]+(Src[2*x+1]<<8))); - *ptr++ = ((unsigned char*)&pix)[3]; - *ptr++ = ((unsigned char*)&pix)[2]; - *ptr++ = ((unsigned char*)&pix)[1]; - *ptr++ = ((unsigned char*)&pix)[0]; - } - } - } - - lua_pushlstring(L, str, size); - delete[] str; - return 1; -} - -// draws a gd image that's in gdstr format to the screen -// example: gui.gdoverlay(gd.createFromPng("myimage.png"):gdStr()) -DEFINE_LUA_FUNCTION(gui_gdoverlay, "[x=0,y=0,]gdimage[,alphamul]") -{ - if(DeferGUIFuncIfNeeded(L)) - return 0; - - int xStart = 0; - int yStart = 0; - - int index = 1; - if(lua_type(L,index) == LUA_TNUMBER) - { - xStart = lua_tointeger(L,index++); - if(lua_type(L,index) == LUA_TNUMBER) - yStart = lua_tointeger(L,index++); - } - - luaL_checktype(L,index,LUA_TSTRING); - const unsigned char* ptr = (const unsigned char*)lua_tostring(L,index++); - - // GD format header for truecolor image (11 bytes) - ptr++; - ptr++; - int width = *ptr++ << 8; - width |= *ptr++; - int height = *ptr++ << 8; - height |= *ptr++; - ptr += 5; - - int maxWidth = ((VDP_Reg.Set4 & 0x1) || Debug || !Game || !FrameCount) ? 320 : 256; - int maxHeight = ((VDP_Reg.Set2 & 0x8) && !(Debug || !Game || !FrameCount)) ? 240 : 224; - - unsigned char *Dst = Bits32 ? (unsigned char*)(MD_Screen32+8) : (unsigned char*)(MD_Screen+8); - - LuaContextInfo& info = GetCurrentInfo(); - int alphaMul = info.transparencyModifier; - if(lua_isnumber(L, index)) - alphaMul = (int)(alphaMul * lua_tonumber(L, index++)); - if(alphaMul <= 0) - return 0; - - // since there aren't that many possible opacity levels, - // do the opacity modification calculations beforehand instead of per pixel - int opacMap[256]; - for(int i = 0; i < 256; i++) - { - int opac = 255 - (i << 1); // not sure why, but gdstr seems to divide each alpha value by 2 - opac = (opac * alphaMul) / 255; - if(opac < 0) opac = 0; - if(opac > 255) opac = 255; - opacMap[i] = 255 - opac; - } - - if(Bits32) - { - Dst += yStart * 336*4; - for(int y = yStart; y < height+yStart && y < maxHeight; y++, Dst += 336*4) - { - if(y < 0) - ptr += width * 4; - else - { - int xA = (xStart < 0 ? 0 : xStart); - int xB = (xStart+width > maxWidth ? maxWidth : xStart+width); - ptr += (xA - xStart) * 4; - for(int x = xA; x < xB; x++) - { - //Dst[4*x+3] = *ptr++; - //Dst[4*x+2] = *ptr++; - //Dst[4*x+1] = *ptr++; - //Dst[4*x+0] = *ptr++; - - int opac = opacMap[ptr[0]]; - pix32 pix = (ptr[3]|(ptr[2]<<8)|(ptr[1]<<16)); - pix32 prev = Dst[4*x] | (Dst[4*x+1] << 8) | (Dst[4*x+2] << 16); - pix = DrawUtil::Blend(prev, pix, opac); - Dst[4*x] = pix & 0xFF; - Dst[4*x+1] = (pix>>8) & 0xFF; - Dst[4*x+2] = (pix>>16) & 0xFF; - ptr += 4; - } - ptr += (xStart+width - xB) * 4; - } - } - } - else if((Mode_555 & 1) == 0) - { - Dst += yStart * 336*2; - for(int y = yStart; y < height+yStart && y < maxHeight; y++, Dst += 336*2) - { - if(y < 0) - ptr += width * 4; - else - { - int xA = (xStart < 0 ? 0 : xStart); - int xB = (xStart+width > maxWidth ? maxWidth : xStart+width); - ptr += (xA - xStart) * 4; - for(int x = xA; x < xB; x++) - { - int opac = opacMap[ptr[0]]; - pix32 pixh = (ptr[3]|(ptr[2]<<8)|(ptr[1]<<16)); - pix32 prev = DrawUtil::Pix16To32(Dst[2*x] | (Dst[2*x+1] << 8)); - pix16 pix = DrawUtil::Pix32To16(DrawUtil::Blend(prev, pixh, opac)); - Dst[2*x] = pix & 0xFF; - Dst[2*x+1] = (pix>>8) & 0xFF; - ptr += 4; - } - ptr += (xStart+width - xB) * 4; - } - } - } - else - { - Dst += yStart * 336*2; - for(int y = yStart; y < height+yStart && y < maxHeight; y++, Dst += 336*2) - { - if(y < 0) - ptr += width * 4; - else - { - int xA = (xStart < 0 ? 0 : xStart); - int xB = (xStart+width > maxWidth ? maxWidth : xStart+width); - ptr += (xA - xStart) * 4; - for(int x = xA; x < xB; x++) - { - int opac = opacMap[ptr[0]]; - pix32 pixh = (ptr[3]|(ptr[2]<<8)|(ptr[1]<<16)); - pix32 prev = DrawUtil::Pix15To32(Dst[2*x] | (Dst[2*x+1] << 8)); - pix15 pix = DrawUtil::Pix32To15(DrawUtil::Blend(prev, pixh, opac)); - Dst[2*x] = pix & 0xFF; - Dst[2*x+1] = (pix>>8) & 0xFF; - ptr += 4; - } - ptr += (xStart+width - xB) * 4; - } - } - } - - return 0; -} -*/ -static void GetCurrentScriptDir(char* buffer, int bufLen) -{ - LuaContextInfo& info = GetCurrentInfo(); - strncpy(buffer, info.lastFilename.c_str(), bufLen); - buffer[bufLen-1] = 0; - char* slash = std::max(strrchr(buffer, '/'), strrchr(buffer, '\\')); - if(slash) - slash[1] = 0; -} - -DEFINE_LUA_FUNCTION(emu_openscript, "filename") -{ -#ifdef WIN32 - char curScriptDir[1024]; GetCurrentScriptDir(curScriptDir, 1024); // make sure we can always find scripts that are in the same directory as the current script - const char* filename = lua_isstring(L,1) ? lua_tostring(L,1) : NULL; - extern const char* OpenLuaScript(const char* filename, const char* extraDirToCheck, bool makeSubservient); - const char* errorMsg = OpenLuaScript(filename, curScriptDir, true); - if(errorMsg) - luaL_error(L, errorMsg); -#endif - return 0; -} -/* -DEFINE_LUA_FUNCTION(gens_loadrom, "filename") -{ - struct Temp { Temp() {EnableStopAllLuaScripts(false);} ~Temp() {EnableStopAllLuaScripts(true);}} dontStopScriptsHere; - const char* filename = lua_isstring(L,1) ? lua_tostring(L,1) : NULL; - char curScriptDir[1024]; GetCurrentScriptDir(curScriptDir, 1024); - filename = MakeRomPathAbsolute(filename, curScriptDir); - int result = GensLoadRom(filename); - if(result <= 0) - luaL_error(L, "Failed to load ROM \"%s\": %s", filename, result ? "invalid or unsupported" : "cancelled or not found"); - CallRegisteredLuaFunctions(LUACALL_ONSTART); - return 0; -} -*/ -DEFINE_LUA_FUNCTION(emu_getframecount, "") -{ - lua_pushinteger(L, currFrameCounter); - return 1; -} -DEFINE_LUA_FUNCTION(emu_getlagcount, "") -{ - lua_pushinteger(L, TotalLagFrames); - return 1; -} -DEFINE_LUA_FUNCTION(emu_lagged, "") -{ - lua_pushboolean(L, LagFrameFlag); - return 1; -}/* -DEFINE_LUA_FUNCTION(gens_emulating, "") -{ - lua_pushboolean(L, Genesis_Started||SegaCD_Started||_32X_Started); - return 1; -} -DEFINE_LUA_FUNCTION(gens_atframeboundary, "") -{ - lua_pushboolean(L, !Inside_Frame); - return 1; -}*/ -DEFINE_LUA_FUNCTION(movie_getlength, "") -{ - lua_pushinteger(L, currMovieData.records.size()); - return 1; -} -DEFINE_LUA_FUNCTION(movie_isactive, "") -{ - if(movieMode != MOVIEMODE_INACTIVE); - lua_pushboolean(L, true); - return 1; -} -DEFINE_LUA_FUNCTION(movie_rerecordcount, "") -{ - lua_pushinteger(L, currMovieData.rerecordCount); - return 1; -}/* -DEFINE_LUA_FUNCTION(movie_setrerecordcount, "") -{ - MainMovie.NbRerecords = luaL_checkinteger(L, 1); - return 0; -}*/ -DEFINE_LUA_FUNCTION(emu_rerecordcounting, "[enabled]") -{ - LuaContextInfo& info = GetCurrentInfo(); - if(lua_gettop(L) == 0) - { - // if no arguments given, return the current value - lua_pushboolean(L, !info.rerecordCountingDisabled); - return 1; - } - else - { - // set rerecord disabling - info.rerecordCountingDisabled = !lua_toboolean(L,1); - return 0; - } -} -DEFINE_LUA_FUNCTION(movie_getreadonly, "") -{ - lua_pushboolean(L, movie_readonly); - return 1; -} -DEFINE_LUA_FUNCTION(movie_setreadonly, "readonly") -{ - int readonly = lua_toboolean(L,1) ? 1 : 0; - if(!movie_readonly) - movie_readonly = true; - else - movie_readonly = false; -// else if(!movie_readonly) -// luaL_error(L, "movie.setreadonly failed: write permission denied"); - - return 0; -} -DEFINE_LUA_FUNCTION(movie_isrecording, "") -{ - lua_pushboolean(L, movieMode == MOVIEMODE_RECORD); - return 1; -} -DEFINE_LUA_FUNCTION(movie_isplaying, "") -{ - lua_pushboolean(L, movieMode == MOVIEMODE_PLAY); - return 1; -} -DEFINE_LUA_FUNCTION(movie_getmode, "") -{ - switch(movieMode) - { - case MOVIEMODE_PLAY: - lua_pushstring(L, "playback"); - break; - case MOVIEMODE_RECORD: - lua_pushstring(L, "record"); - break; - case MOVIEMODE_INACTIVE: - lua_pushstring(L, "inactive"); - break; - default: - lua_pushnil(L); - break; - } - return 1; -} -DEFINE_LUA_FUNCTION(movie_getname, "") -{ - extern char curMovieFilename[512]; - lua_pushstring(L, curMovieFilename); - return 1; -} -// movie.play() -- plays a movie of the user's choice -// movie.play(filename) -- starts playing a particular movie -// throws an error (with a description) if for whatever reason the movie couldn't be played -DEFINE_LUA_FUNCTION(movie_play, "[filename]") -{ - const char* filename = lua_isstring(L,1) ? lua_tostring(L,1) : NULL; - FCEUI_LoadMovie(filename, true, false, 0); -// const char* errorMsg = -// if(errorMsg) -// luaL_error(L, errorMsg); - return 0; -} /* -DEFINE_LUA_FUNCTION(movie_replay, "") -{ - if(MainMovie.File) - GensReplayMovie(); - else - luaL_error(L, "it is invalid to call movie.replay when no movie open."); - return 0; -} */ -DEFINE_LUA_FUNCTION(movie_close, "") -{ - - FCEUI_StopMovie(); - return 0; -} - -DEFINE_LUA_FUNCTION(sound_clear, "") -{ -// Clear_Sound_Buffer(); - return 0; -} - -#ifdef _WIN32 -const char* s_keyToName[256] = -{ - NULL, - "leftclick", - "rightclick", - NULL, - "middleclick", - NULL, - NULL, - NULL, - "backspace", - "tab", - NULL, - NULL, - NULL, - "enter", - NULL, - NULL, - "shift", // 0x10 - "control", - "alt", - "pause", - "capslock", - NULL, - NULL, - NULL, - NULL, - NULL, - NULL, - "escape", - NULL, - NULL, - NULL, - NULL, - "space", // 0x20 - "pageup", - "pagedown", - "end", - "home", - "left", - "up", - "right", - "down", - NULL, - NULL, - NULL, - NULL, - "insert", - "delete", - NULL, - "0","1","2","3","4","5","6","7","8","9", - NULL, NULL, NULL, NULL, NULL, NULL, NULL, - "A","B","C","D","E","F","G","H","I","J", - "K","L","M","N","O","P","Q","R","S","T", - "U","V","W","X","Y","Z", - NULL, - NULL, - NULL, - NULL, - NULL, - "numpad0","numpad1","numpad2","numpad3","numpad4","numpad5","numpad6","numpad7","numpad8","numpad9", - "numpad*","numpad+", - NULL, - "numpad-","numpad.","numpad/", - "F1","F2","F3","F4","F5","F6","F7","F8","F9","F10","F11","F12", - "F13","F14","F15","F16","F17","F18","F19","F20","F21","F22","F23","F24", - NULL, - NULL, - NULL, - NULL, - NULL, - NULL, - NULL, - NULL, - "numlock", - "scrolllock", - NULL, // 0x92 - NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, - NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, - NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, - NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, - NULL, // 0xB9 - "semicolon", - "plus", - "comma", - "minus", - "period", - "slash", - "tilde", - NULL, // 0xC1 - NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, - NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, - NULL, NULL, NULL, NULL, NULL, NULL, NULL, - NULL, // 0xDA - "leftbracket", - "backslash", - "rightbracket", - "quote", -}; -#endif - - -// input.get() -// takes no input, returns a lua table of entries representing the current input state, -// independent of the joypad buttons the emulated game thinks are pressed -// for example: -// if the user is holding the W key and the left mouse button -// and has the mouse at the bottom-right corner of the game screen, -// then this would return {W=true, leftclick=true, xmouse=319, ymouse=223} -DEFINE_LUA_FUNCTION(input_getcurrentinputstatus, "") -{ - lua_newtable(L); - -#ifdef _WIN32 - // keyboard and mouse button status - { - int BackgroundInput = 0;//TODO - - unsigned char keys [256]; - if(!BackgroundInput) - { - if(GetKeyboardState(keys)) - { - for(int i = 1; i < 255; i++) - { - int mask = (i == VK_CAPITAL || i == VK_NUMLOCK || i == VK_SCROLL) ? 0x01 : 0x80; - if(keys[i] & mask) - { - const char* name = s_keyToName[i]; - if(name) - { - lua_pushboolean(L, true); - lua_setfield(L, -2, name); - } - } - } - } - } - else // use a slightly different method that will detect background input: - { - for(int i = 1; i < 255; i++) - { - const char* name = s_keyToName[i]; - if(name) - { - int active; - if(i == VK_CAPITAL || i == VK_NUMLOCK || i == VK_SCROLL) - active = GetKeyState(i) & 0x01; - else - active = GetAsyncKeyState(i) & 0x8000; - if(active) - { - lua_pushboolean(L, true); - lua_setfield(L, -2, name); - } - } - } - } - } - // mouse position in game screen pixel coordinates - { -/* POINT point; - RECT rect, srcRectUnused; - float xRatioUnused, yRatioUnused; - int depUnused; - GetCursorPos(&point); - ScreenToClient(MainWindow->getHWnd(), &point); - GetClientRect(MainWindow->getHWnd(), &rect); - void CalculateDrawArea(int Render_Mode, RECT& RectDest, RECT& RectSrc, float& Ratio_X, float& Ratio_Y, int& Dep); - CalculateDrawArea(Full_Screen ? Render_FS : Render_W, rect, srcRectUnused, xRatioUnused, yRatioUnused, depUnused); - int xres = ((VDP_Reg.Set4 & 0x1) || Debug || !Game || !FrameCount) ? 320 : 256; - int yres = ((VDP_Reg.Set2 & 0x8) && !(Debug || !Game || !FrameCount)) ? 240 : 224; - int x = ((point.x - rect.left) * xres) / max(1, rect.right - rect.left); - int y = ((point.y - rect.top) * yres) / max(1, rect.bottom - rect.top);*/ - int x = 0, y = 0; - lua_pushinteger(L, x); - lua_setfield(L, -2, "xmouse"); - lua_pushinteger(L, y); - lua_setfield(L, -2, "ymouse"); - } -#else - // NYI (well, return an empty table) -#endif - - return 1; -} - - -// resets our "worry" counter of the Lua state -int dontworry(LuaContextInfo& info) -{ - if(info.stopWorrying) - { - info.stopWorrying = false; - if(info.worryCount) - indicateBusy(info.L, false); - } - info.worryCount = 0; - return 0; -} - -//agg basic shapes -//TODO polygon and polyline, maybe the overloads for roundedRect and curve - -#include "aggdraw.h" - -static int line(lua_State *L) { - - int x1,y1,x2,y2; - x1 = luaL_checkinteger(L,1); - y1 = luaL_checkinteger(L,2); - x2 = luaL_checkinteger(L,3); - y2 = luaL_checkinteger(L,4); - - aggDraw.target->line(x1, y1, x2, y2); - - return 0; -} - -static int triangle(lua_State *L) { - - double x1,y1,x2,y2,x3,y3; - x1 = luaL_checkinteger(L,1); - y1 = luaL_checkinteger(L,2); - x2 = luaL_checkinteger(L,3); - y2 = luaL_checkinteger(L,4); - x3 = luaL_checkinteger(L,5); - y3 = luaL_checkinteger(L,6); - - aggDraw.target->triangle(x1, y1, x2, y2, x3, y3); - - return 0; -} - -static int rectangle(lua_State *L) { - - int x1,y1,x2,y2; - x1 = luaL_checkinteger(L,1); - y1 = luaL_checkinteger(L,2); - x2 = luaL_checkinteger(L,3); - y2 = luaL_checkinteger(L,4); - - aggDraw.target->rectangle(x1, y1, x2, y2); - - return 0; -} - -static int roundedRect(lua_State *L) { - - double x1,y1,x2,y2,r; - x1 = luaL_checkinteger(L,1); - y1 = luaL_checkinteger(L,2); - x2 = luaL_checkinteger(L,3); - y2 = luaL_checkinteger(L,4); - r = luaL_checkinteger(L,5); - - aggDraw.target->roundedRect(x1, y1, x2, y2, r); - - return 0; -} - -static int ellipse(lua_State *L) { - - int cx,cy,rx,ry; - cx = luaL_checkinteger(L,1); - cy = luaL_checkinteger(L,2); - rx = luaL_checkinteger(L,3); - ry = luaL_checkinteger(L,4); - - aggDraw.target->ellipse(cx, cy, rx, ry); - - return 0; -} - -static int arc(lua_State *L) { - - double cx,cy,rx,ry,start,sweep; - cx = luaL_checkinteger(L,1); - cy = luaL_checkinteger(L,2); - rx = luaL_checkinteger(L,3); - ry = luaL_checkinteger(L,4); - start = luaL_checkinteger(L,5); - sweep = luaL_checkinteger(L,6); - - aggDraw.target->arc(cx, cy,rx, ry, start, sweep); - - return 0; -} - -static int star(lua_State *L) { - - lua_Integer cx,cy,r1,r2,startAngle,numRays; - cx = luaL_checkinteger(L,1); - cy = luaL_checkinteger(L,2); - r1 = luaL_checkinteger(L,3); - r2 = luaL_checkinteger(L,4); - startAngle = luaL_checkinteger(L,5); - numRays = luaL_checkinteger(L,6); - - aggDraw.target->star(cx, cy, r1, r2, startAngle, numRays); - - return 0; -} - -static int curve(lua_State *L) { - - double x1,y1,x2,y2,x3,y3; - x1 = luaL_checkinteger(L,1); - y1 = luaL_checkinteger(L,2); - x2 = luaL_checkinteger(L,3); - y2 = luaL_checkinteger(L,4); - x3 = luaL_checkinteger(L,5); - y3 = luaL_checkinteger(L,6); - - aggDraw.target->curve(x1, y1, x2, y2, x3, y3); - - return 0; -} - -static const struct luaL_reg aggbasicshapes [] = -{ - {"line", line}, - {"triangle", triangle}, - {"rectangle", rectangle}, - {"roundedRect", roundedRect}, - {"ellipse", ellipse}, - {"arc", arc}, - {"star", star}, - {"curve", curve}, -// {"polygon", polygon}, -// {"polyline", polyline}, - {NULL, NULL} -}; - -//agg general attributes -//TODO missing functions, maybe the missing overloads - -static int fillColor(lua_State *L) { - - lua_Integer r,g,b,a; - r = luaL_checkinteger(L,1); - g = luaL_checkinteger(L,2); - b = luaL_checkinteger(L,3); - a = luaL_checkinteger(L,4); - - aggDraw.target->fillColor(r, g, b, a); - - return 0; -} - -static int noFill(lua_State *L) { - - aggDraw.target->noFill(); - return 0; -} - -static int lineColor(lua_State *L) { - - lua_Integer r,g,b,a; - r = luaL_checkinteger(L,1); - g = luaL_checkinteger(L,2); - b = luaL_checkinteger(L,3); - a = luaL_checkinteger(L,4); - - aggDraw.target->lineColor(r, g, b, a); - - return 0; -} - -static int noLine(lua_State *L) { - - aggDraw.target->noLine(); - return 0; -} - -static int lineWidth(lua_State *L) { - - double w; - w = luaL_checkinteger(L,1); - - aggDraw.target->lineWidth(w); - - return 0; -} - -static const struct luaL_reg agggeneralattributes [] = -{ -// {"blendMode", blendMode}, -// {"imageBlendMode", imageBlendMode}, -// {"imageBlendColor", imageBlendColor}, -// {"masterAlpha", masterAlpha}, -// {"antiAliasGamma", antiAliasGamma}, -// {"font", font}, - {"fillColor", fillColor}, - {"noFill", noFill}, - {"lineColor", lineColor}, - {"noLine", noLine}, -// {"fillLinearGradient", fillLinearGradient}, -// {"lineLinearGradient", lineLinearGradient}, -// {"fillRadialGradient", fillRadialGradient}, -// {"lineRadialGradient", lineRadialGradient}, - {"lineWidth", lineWidth}, -// {"lineCap", lineCap}, -// {"lineJoin", lineJoin}, -// {"fillEvenOdd", fillEvenOdd}, - {NULL, NULL} -}; - - -// gui.text(int x, int y, string msg) -// -// Displays the given text on the screen, using the same font and techniques as the -// main HUD. -static int gui_text(lua_State *L) { - const char *msg; - int x, y; - - x = luaL_checkinteger(L,1); - y = luaL_checkinteger(L,2); - msg = luaL_checkstring(L,3); - - osd->addFixed(x, y, "%s", msg); - - return 0; -} - -static int stylus_read(lua_State *L){ - - lua_newtable(L); - - lua_pushinteger(L, nds.touchX >> 4); - lua_setfield(L, -2, "x"); - lua_pushinteger(L, nds.touchY >> 4); - lua_setfield(L, -2, "y"); - lua_pushinteger(L, nds.isTouch); - lua_setfield(L, -2, "touch"); - - return 1; -} - -static const struct luaL_reg styluslib [] = -{ - {"read", stylus_read}, - {NULL, NULL} -}; - -static const struct luaL_reg emulib [] = -{ -// {"frameadvance", emu_frameadvance}, -// {"speedmode", emu_speedmode}, -// {"wait", emu_wait}, -// {"pause", emu_pause}, -// {"unpause", emu_unpause}, -// {"emulateframe", emu_emulateframe}, - //{"emulateframefastnoskipping", emu_emulateframefastnoskipping}, // removed from library because probably nobody would notice the difference from emu_emulateframe -// {"emulateframefast", emu_emulateframefast}, -// {"emulateframeinvisible", emu_emulateframeinvisible}, -// {"redraw", emu_redraw}, - {"framecount", emu_getframecount}, - {"lagcount", emu_getlagcount}, - {"lagged", emu_lagged}, -// {"emulating", emu_emulating}, -// {"atframeboundary", emu_atframeboundary}, - {"registerbefore", emu_registerbefore}, - {"registerafter", emu_registerafter}, -// {"registerstart", emu_registerstart}, - {"registerexit", emu_registerexit}, - {"persistglobalvariables", emu_persistglobalvariables}, - {"message", emu_message}, - {"print", print}, // sure, why not - {"openscript", emu_openscript}, -// {"loadrom", emu_loadrom}, - // alternative names -// {"openrom", emu_loadrom}, - {NULL, NULL} -}; -static const struct luaL_reg guilib [] = -{ - {"register", gui_register}, - {"text", gui_text}, -// {"box", gui_box}, -// {"line", gui_line}, -// {"pixel", gui_pixel}, -// {"getpixel", gui_getpixel}, -// {"opacity", gui_setopacity}, -// {"transparency", gui_settransparency}, - {"popup", gui_popup}, - {"parsecolor", gui_parsecolor}, -// {"gdscreenshot", gui_gdscreenshot}, -// {"gdoverlay", gui_gdoverlay}, -// {"redraw", emu_redraw}, // some people might think of this as more of a GUI function - // alternative names - {"drawtext", gui_text}, -// {"drawbox", gui_box}, -// {"drawline", gui_line}, -// {"drawpixel", gui_pixel}, -// {"setpixel", gui_pixel}, -// {"writepixel", gui_pixel}, -// {"readpixel", gui_getpixel}, -// {"rect", gui_box}, -// {"drawrect", gui_box}, -// {"drawimage", gui_gdoverlay}, -// {"image", gui_gdoverlay}, - {NULL, NULL} -}; -static const struct luaL_reg statelib [] = -{ -// {"create", state_create}, -// {"save", state_save}, -// {"load", state_load}, -// {"loadscriptdata", state_loadscriptdata}, -// {"savescriptdata", state_savescriptdata}, - {"registersave", state_registersave}, - {"registerload", state_registerload}, - {NULL, NULL} -}; -static const struct luaL_reg memorylib [] = -{ - {"readbyte", memory_readbyte}, - {"readbytesigned", memory_readbytesigned}, - {"readword", memory_readword}, - {"readwordsigned", memory_readwordsigned}, - {"readdword", memory_readdword}, - {"readdwordsigned", memory_readdwordsigned}, - {"readbyterange", memory_readbyterange}, - {"writebyte", memory_writebyte}, - {"writeword", memory_writeword}, - {"writedword", memory_writedword}, -// {"isvalid", memory_isvalid}, - {"getregister", memory_getregister}, - {"setregister", memory_setregister}, - // alternate naming scheme for word and double-word and unsigned - {"readbyteunsigned", memory_readbyte}, - {"readwordunsigned", memory_readword}, - {"readdwordunsigned", memory_readdword}, - {"readshort", memory_readword}, - {"readshortunsigned", memory_readword}, - {"readshortsigned", memory_readwordsigned}, - {"readlong", memory_readdword}, - {"readlongunsigned", memory_readdword}, - {"readlongsigned", memory_readdwordsigned}, - {"writeshort", memory_writeword}, - {"writelong", memory_writedword}, - - // memory hooks -// {"registerwrite", memory_registerwrite}, -// {"registerread", memory_registerread}, -// {"registerexec", memory_registerexec}, - // alternate names -// {"register", memory_registerwrite}, -// {"registerrun", memory_registerexec}, -// {"registerexecute", memory_registerexec}, - - {NULL, NULL} -}; -static const struct luaL_reg joylib [] = -{ - {"get", joy_get}, -// {"getdown", joy_getdown}, -// {"getup", joy_getup}, -// {"peek", joy_peek}, -// {"peekdown", joy_peekdown}, -// {"peekup", joy_peekup}, -// {"set", joy_set}, - // alternative names - {"read", joy_get}, -// {"write", joy_set}, -// {"readdown", joy_getdown}, -// {"readup", joy_getup}, - {NULL, NULL} -}; -static const struct luaL_reg inputlib [] = -{ - {"get", input_getcurrentinputstatus}, - {"registerhotkey", input_registerhotkey}, - {"popup", input_popup}, - // alternative names - {"read", input_getcurrentinputstatus}, - {NULL, NULL} -}; -static const struct luaL_reg movielib [] = -{ - {"active", movie_isactive}, - {"recording", movie_isrecording}, - {"playing", movie_isplaying}, - {"mode", movie_getmode}, - - {"length", movie_getlength}, - {"name", movie_getname}, - {"rerecordcount", movie_rerecordcount}, -// {"setrerecordcount", movie_setrerecordcount}, - - {"rerecordcounting", emu_rerecordcounting}, - {"readonly", movie_getreadonly}, - {"setreadonly", movie_setreadonly}, - {"framecount", emu_getframecount}, // for those familiar with other emulators that have movie.framecount() instead of emulatorname.framecount() - - {"play", movie_play}, -// {"replay", movie_replay}, - {"stop", movie_close}, - - // alternative names - {"open", movie_play}, - {"close", movie_close}, - {"getname", movie_getname}, - {"playback", movie_play}, - {"getreadonly", movie_getreadonly}, - {NULL, NULL} -}; -static const struct luaL_reg soundlib [] = -{ -// {"clear", sound_clear}, - {NULL, NULL} -}; - -static const struct CFuncInfo -{ - const char* library; - const char* name; - const char* args; - bool registry; -} -cFuncInfo [] = // this info is stored here to avoid having to change all of Lua's libraries to use something like DEFINE_LUA_FUNCTION -{ - {LUA_STRLIBNAME, "byte", "str[,start[,end]]"}, - {LUA_STRLIBNAME, "char", "...[bytes]"}, - {LUA_STRLIBNAME, "dump", "func"}, - {LUA_STRLIBNAME, "find", "str,pattern[,init[,plain]]"}, - {LUA_STRLIBNAME, "format", "formatstring,..."}, - {LUA_STRLIBNAME, "gfind", "!deprecated!"}, - {LUA_STRLIBNAME, "gmatch", "str,pattern"}, - {LUA_STRLIBNAME, "gsub", "str,pattern,repl[,n]"}, - {LUA_STRLIBNAME, "len", "str"}, - {LUA_STRLIBNAME, "lower", "str"}, - {LUA_STRLIBNAME, "match", "str,pattern[,init]"}, - {LUA_STRLIBNAME, "rep", "str,n"}, - {LUA_STRLIBNAME, "reverse", "str"}, - {LUA_STRLIBNAME, "sub", "str,start[,end]"}, - {LUA_STRLIBNAME, "upper", "str"}, - {NULL, "module", "name[,...]"}, - {NULL, "require", "modname"}, - {LUA_LOADLIBNAME, "loadlib", "libname,funcname"}, - {LUA_LOADLIBNAME, "seeall", "module"}, - {LUA_COLIBNAME, "create", "func"}, - {LUA_COLIBNAME, "resume", "co[,val1,...]"}, - {LUA_COLIBNAME, "running", ""}, - {LUA_COLIBNAME, "status", "co"}, - {LUA_COLIBNAME, "wrap", "func"}, - {LUA_COLIBNAME, "yield", "..."}, - {NULL, "assert", "cond[,message]"}, - {NULL, "collectgarbage", "opt[,arg]"}, - {NULL, "gcinfo", ""}, - {NULL, "dofile", "filename"}, - {NULL, "error", "message[,level]"}, - {NULL, "getfenv", "[level_or_func]"}, - {NULL, "getmetatable", "object"}, - {NULL, "ipairs", "arraytable"}, - {NULL, "load", "func[,chunkname]"}, - {NULL, "loadfile", "[filename]"}, - {NULL, "loadstring", "str[,chunkname]"}, - {NULL, "next", "table[,index]"}, - {NULL, "pairs", "table"}, - {NULL, "pcall", "func,arg1,..."}, - {NULL, "rawequal", "v1,v2"}, - {NULL, "rawget", "table,index"}, - {NULL, "rawset", "table,index,value"}, - {NULL, "select", "index,..."}, - {NULL, "setfenv", "level_or_func,envtable"}, - {NULL, "setmetatable", "table,metatable"}, - {NULL, "tonumber", "str_or_num[,base]"}, - {NULL, "type", "obj"}, - {NULL, "unpack", "list[,i=1[,j=#list]]"}, - {NULL, "xpcall", "func,errhandler"}, - {NULL, "newproxy", "hasmeta"}, - {LUA_MATHLIBNAME, "abs", "x"}, - {LUA_MATHLIBNAME, "acos", "x"}, - {LUA_MATHLIBNAME, "asin", "x"}, - {LUA_MATHLIBNAME, "atan", "x"}, - {LUA_MATHLIBNAME, "atan2", "y,x"}, - {LUA_MATHLIBNAME, "ceil", "x"}, - {LUA_MATHLIBNAME, "cos", "rads"}, - {LUA_MATHLIBNAME, "cosh", "x"}, - {LUA_MATHLIBNAME, "deg", "rads"}, - {LUA_MATHLIBNAME, "exp", "x"}, - {LUA_MATHLIBNAME, "floor", "x"}, - {LUA_MATHLIBNAME, "fmod", "x,y"}, - {LUA_MATHLIBNAME, "frexp", "x"}, - {LUA_MATHLIBNAME, "ldexp", "m,e"}, - {LUA_MATHLIBNAME, "log", "x"}, - {LUA_MATHLIBNAME, "log10", "x"}, - {LUA_MATHLIBNAME, "max", "x,..."}, - {LUA_MATHLIBNAME, "min", "x,..."}, - {LUA_MATHLIBNAME, "modf", "x"}, - {LUA_MATHLIBNAME, "pow", "x,y"}, - {LUA_MATHLIBNAME, "rad", "degs"}, - {LUA_MATHLIBNAME, "random", "[m[,n]]"}, - {LUA_MATHLIBNAME, "randomseed", "x"}, - {LUA_MATHLIBNAME, "sin", "rads"}, - {LUA_MATHLIBNAME, "sinh", "x"}, - {LUA_MATHLIBNAME, "sqrt", "x"}, - {LUA_MATHLIBNAME, "tan", "rads"}, - {LUA_MATHLIBNAME, "tanh", "x"}, - {LUA_IOLIBNAME, "close", "[file]"}, - {LUA_IOLIBNAME, "flush", ""}, - {LUA_IOLIBNAME, "input", "[file]"}, - {LUA_IOLIBNAME, "lines", "[filename]"}, - {LUA_IOLIBNAME, "open", "filename[,mode=\"r\"]"}, - {LUA_IOLIBNAME, "output", "[file]"}, - {LUA_IOLIBNAME, "popen", "prog,[model]"}, - {LUA_IOLIBNAME, "read", "..."}, - {LUA_IOLIBNAME, "tmpfile", ""}, - {LUA_IOLIBNAME, "type", "obj"}, - {LUA_IOLIBNAME, "write", "..."}, - {LUA_OSLIBNAME, "clock", ""}, - {LUA_OSLIBNAME, "date", "[format[,time]]"}, - {LUA_OSLIBNAME, "difftime", "t2,t1"}, - {LUA_OSLIBNAME, "execute", "[command]"}, - {LUA_OSLIBNAME, "exit", "[code]"}, - {LUA_OSLIBNAME, "getenv", "varname"}, - {LUA_OSLIBNAME, "remove", "filename"}, - {LUA_OSLIBNAME, "rename", "oldname,newname"}, - {LUA_OSLIBNAME, "setlocale", "locale[,category]"}, - {LUA_OSLIBNAME, "time", "[timetable]"}, - {LUA_OSLIBNAME, "tmpname", ""}, - {LUA_DBLIBNAME, "debug", ""}, - {LUA_DBLIBNAME, "getfenv", "o"}, - {LUA_DBLIBNAME, "gethook", "[thread]"}, - {LUA_DBLIBNAME, "getinfo", "[thread,]function[,what]"}, - {LUA_DBLIBNAME, "getlocal", "[thread,]level,local"}, - {LUA_DBLIBNAME, "getmetatable", "[object]"}, - {LUA_DBLIBNAME, "getregistry", ""}, - {LUA_DBLIBNAME, "getupvalue", "func,up"}, - {LUA_DBLIBNAME, "setfenv", "object,table"}, - {LUA_DBLIBNAME, "sethook", "[thread,]hook,mask[,count]"}, - {LUA_DBLIBNAME, "setlocal", "[thread,]level,local,value"}, - {LUA_DBLIBNAME, "setmetatable", "object,table"}, - {LUA_DBLIBNAME, "setupvalue", "func,up,value"}, - {LUA_DBLIBNAME, "traceback", "[thread,][message][,level]"}, - {LUA_TABLIBNAME, "concat", "table[,sep[,i[,j]]]"}, - {LUA_TABLIBNAME, "insert", "table,[pos,]value"}, - {LUA_TABLIBNAME, "maxn", "table"}, - {LUA_TABLIBNAME, "remove", "table[,pos]"}, - {LUA_TABLIBNAME, "sort", "table[,comp]"}, - {LUA_TABLIBNAME, "foreach", "table,func"}, - {LUA_TABLIBNAME, "foreachi", "table,func"}, - {LUA_TABLIBNAME, "getn", "table"}, - {LUA_TABLIBNAME, "maxn", "table"}, - {LUA_TABLIBNAME, "setn", "table,value"}, // I know some of these are obsolete but they should still have argument info if they're exposed to the user - {LUA_FILEHANDLE, "setvbuf", "mode[,size]", true}, - {LUA_FILEHANDLE, "lines", "", true}, - {LUA_FILEHANDLE, "read", "...", true}, - {LUA_FILEHANDLE, "flush", "", true}, - {LUA_FILEHANDLE, "seek", "[whence][,offset]", true}, - {LUA_FILEHANDLE, "write", "...", true}, - {LUA_FILEHANDLE, "__tostring", "obj", true}, - {LUA_FILEHANDLE, "__gc", "", true}, - {"_LOADLIB", "__gc", "", true}, -}; - -void registerLibs(lua_State* L) -{ - luaL_openlibs(L); - - luaL_register(L, "emu", emulib); - luaL_register(L, "gui", guilib); - luaL_register(L, "stylus", styluslib); - luaL_register(L, "savestate", statelib); - luaL_register(L, "memory", memorylib); - luaL_register(L, "joypad", joylib); // for game input - luaL_register(L, "input", inputlib); // for user input - luaL_register(L, "movie", movielib); - luaL_register(L, "sound", soundlib); - - luaL_register(L, "agg", aggbasicshapes); - luaL_register(L, "agg", agggeneralattributes); - - - lua_settop(L, 0); // clean the stack, because each call to luaL_register leaves a table on top - - // register a few utility functions outside of libraries (in the global namespace) - lua_register(L, "print", print); - lua_register(L, "tostring", tostring); - lua_register(L, "addressof", addressof); - lua_register(L, "copytable", copytable); - lua_register(L, "AND", bitand); - lua_register(L, "OR", bitor); - lua_register(L, "XOR", bitxor); - lua_register(L, "SHIFT", bitshift); - lua_register(L, "BIT", bitbit); - - // populate s_cFuncInfoMap the first time - static bool once = true; - if(once) - { - once = false; - - for(int i = 0; i < sizeof(cFuncInfo)/sizeof(*cFuncInfo); i++) - { - const CFuncInfo& cfi = cFuncInfo[i]; - if(cfi.registry) - { - lua_getregistry(L); - lua_getfield(L, -1, cfi.library); - lua_remove(L, -2); - lua_getfield(L, -1, cfi.name); - lua_remove(L, -2); - } - else if(cfi.library) - { - lua_getfield(L, LUA_GLOBALSINDEX, cfi.library); - lua_getfield(L, -1, cfi.name); - lua_remove(L, -2); - } - else - { - lua_getfield(L, LUA_GLOBALSINDEX, cfi.name); - } - - lua_CFunction func = lua_tocfunction(L, -1); - s_cFuncInfoMap[func] = cfi.args; - lua_pop(L, 1); - } - - // deal with some stragglers - lua_getfield(L, LUA_GLOBALSINDEX, "package"); - lua_getfield(L, -1, "loaders"); - lua_remove(L, -2); - if(lua_istable(L, -1)) - { - for(int i=1;;i++) - { - lua_rawgeti(L, -1, i); - lua_CFunction func = lua_tocfunction(L, -1); - lua_pop(L,1); - if(!func) - break; - s_cFuncInfoMap[func] = "name"; - } - } - lua_pop(L,1); - } - - // push arrays for storing hook functions in - for(int i = 0; i < LUAMEMHOOK_COUNT; i++) - { - lua_newtable(L); - lua_setfield(L, LUA_REGISTRYINDEX, luaMemHookTypeStrings[i]); - } -} - -void ResetInfo(LuaContextInfo& info) -{ - info.L = NULL; - info.started = false; - info.running = false; - info.returned = false; - info.crashed = false; - info.restart = false; - info.restartLater = false; - info.worryCount = 0; - info.stopWorrying = false; - info.panic = false; - info.ranExit = false; - info.numDeferredGUIFuncs = 0; - info.ranFrameAdvance = false; - info.transparencyModifier = 255; - info.speedMode = SPEEDMODE_NORMAL; - info.guiFuncsNeedDeferring = false; - info.dataSaveKey = 0; - info.dataLoadKey = 0; - info.dataSaveLoadKeySet = false; - info.rerecordCountingDisabled = false; - info.numMemHooks = 0; - info.persistVars.clear(); - info.newDefaultData.ClearRecords(); -} - -void OpenLuaContext(int uid, void(*print)(int uid, const char* str), void(*onstart)(int uid), void(*onstop)(int uid, bool statusOK)) -{ - LuaContextInfo* newInfo = new LuaContextInfo(); - ResetInfo(*newInfo); - newInfo->print = print; - newInfo->onstart = onstart; - newInfo->onstop = onstop; - luaContextInfo[uid] = newInfo; -} - -void RunLuaScriptFile(int uid, const char* filenameCStr) -{ - if(luaContextInfo.find(uid) == luaContextInfo.end()) - return; - StopLuaScript(uid); - - LuaContextInfo& info = *luaContextInfo[uid]; - -#ifdef USE_INFO_STACK - infoStack.insert(infoStack.begin(), &info); - struct Scope { ~Scope(){ infoStack.erase(infoStack.begin()); } } scope; // doing it like this makes sure that the info stack gets cleaned up even if an exception is thrown -#endif - - info.nextFilename = filenameCStr; - - if(info.running) - { - // it's a little complicated, but... the call to luaL_dofile below - // could call a C function that calls this very function again - // additionally, if that happened then the above call to StopLuaScript - // probably couldn't stop the script yet, so instead of continuing, - // we'll set a flag that tells the first call of this function to loop again - // when the script is able to stop safely - info.restart = true; - return; - } - - do - { - std::string filename = info.nextFilename; - - lua_State* L = lua_open(); -#ifndef USE_INFO_STACK - luaStateToContextMap[L] = &info; -#endif - luaStateToUIDMap[L] = uid; - ResetInfo(info); - info.L = L; - info.guiFuncsNeedDeferring = true; - info.lastFilename = filename; - - SetSaveKey(info, FilenameFromPath(filename.c_str())); - info.dataSaveLoadKeySet = false; - - registerLibs(L); - - // register a function to periodically check for inactivity - lua_sethook(L, LuaRescueHook, LUA_MASKCOUNT, HOOKCOUNT); - - // deferred evaluation table - lua_newtable(L); - lua_setfield(L, LUA_REGISTRYINDEX, deferredGUIIDString); - - info.started = true; - RefreshScriptStartedStatus(); - if(info.onstart) - info.onstart(uid); - info.running = true; - RefreshScriptSpeedStatus(); - info.returned = false; - int errorcode = luaL_dofile(L,filename.c_str()); - info.running = false; - RefreshScriptSpeedStatus(); - info.returned = true; - - if (errorcode) - { - info.crashed = true; - if(info.print) - { - info.print(uid, lua_tostring(L,-1)); - info.print(uid, "\r\n"); - } - else - { - fprintf(stderr, "%s\n", lua_tostring(L,-1)); - } - StopLuaScript(uid); - } - else - { -// Show_Genesis_Screen(); - StopScriptIfFinished(uid, true); - } - } while(info.restart); -} - -void StopScriptIfFinished(int uid, bool justReturned) -{ - LuaContextInfo& info = *luaContextInfo[uid]; - if(!info.returned) - return; - - // the script has returned, but it is not necessarily done running - // because it may have registered a function that it expects to keep getting called - // so check if it has any registered functions and stop the script only if it doesn't - - bool keepAlive = (info.numMemHooks != 0); - for(int calltype = 0; calltype < LUACALL_COUNT && !keepAlive; calltype++) - { - lua_State* L = info.L; - if(L) - { - const char* idstring = luaCallIDStrings[calltype]; - lua_getfield(L, LUA_REGISTRYINDEX, idstring); - bool isFunction = lua_isfunction(L, -1); - lua_pop(L, 1); - - if(isFunction) - keepAlive = true; - } - } - - if(keepAlive) - { - if(justReturned) - { - if(info.print) - info.print(uid, "script returned but is still running registered functions\r\n"); - else - fprintf(stderr, "%s\n", "script returned but is still running registered functions"); - } - } - else - { - if(info.print) - info.print(uid, "script finished running\r\n"); - else - fprintf(stderr, "%s\n", "script finished running"); - - StopLuaScript(uid); - } -} - -void RequestAbortLuaScript(int uid, const char* message) -{ - if(luaContextInfo.find(uid) == luaContextInfo.end()) - return; - LuaContextInfo& info = *luaContextInfo[uid]; - lua_State* L = info.L; - if(L) - { - // this probably isn't the right way to do it - // but calling luaL_error here is positively unsafe - // (it seemingly works fine but sometimes corrupts the emulation state in colorful ways) - // and this works pretty well and is definitely safe, so screw it - info.L->hookcount = 1; // run hook function as soon as possible - info.panic = true; // and call luaL_error once we're inside the hook function - if(message) - { - strncpy(info.panicMessage, message, sizeof(info.panicMessage)); - info.panicMessage[sizeof(info.panicMessage)-1] = 0; - } - else - { - // attach file/line info because this is the case where it's most necessary to see that, - // and often it won't be possible for the later luaL_error call to retrieve it otherwise. - // this means sometimes printing multiple file/line numbers if luaL_error does find something, - // but that's fine since more information is probably better anyway. - luaL_where(L,0); // should be 0 and not 1 here to get useful (on force stop) messages - const char* whereString = lua_tostring(L,-1); - snprintf(info.panicMessage, sizeof(info.panicMessage), "%sscript terminated", whereString); - lua_pop(L,1); - } - } -} - -void SetSaveKey(LuaContextInfo& info, const char* key) -{ - info.dataSaveKey = crc32(0, (const unsigned char*)key, strlen(key)); - - if(!info.dataSaveLoadKeySet) - { - info.dataLoadKey = info.dataSaveKey; - info.dataSaveLoadKeySet = true; - } -} -void SetLoadKey(LuaContextInfo& info, const char* key) -{ - info.dataLoadKey = crc32(0, (const unsigned char*)key, strlen(key)); - - if(!info.dataSaveLoadKeySet) - { - info.dataSaveKey = info.dataLoadKey; - info.dataSaveLoadKeySet = true; - } -} - -void HandleCallbackError(lua_State* L, LuaContextInfo& info, int uid, bool stopScript) -{ - info.crashed = true; - if(L->errfunc || L->errorJmp) - luaL_error(L, lua_tostring(L,-1)); - else - { - if(info.print) - { - info.print(uid, lua_tostring(L,-1)); - info.print(uid, "\r\n"); - } - else - { - fprintf(stderr, "%s\n", lua_tostring(L,-1)); - } - if(stopScript) - StopLuaScript(uid); - } -} - -void CallExitFunction(int uid) -{ - LuaContextInfo& info = *luaContextInfo[uid]; - lua_State* L = info.L; - - if(!L) - return; - - dontworry(info); - - // first call the registered exit function if there is one - if(!info.ranExit) - { - info.ranExit = true; - -#ifdef USE_INFO_STACK - infoStack.insert(infoStack.begin(), &info); - struct Scope { ~Scope(){ infoStack.erase(infoStack.begin()); } } scope; -#endif - - lua_settop(L, 0); - lua_getfield(L, LUA_REGISTRYINDEX, luaCallIDStrings[LUACALL_BEFOREEXIT]); - - int errorcode = 0; - if (lua_isfunction(L, -1)) - { - bool wasRunning = info.running; - info.running = true; - RefreshScriptSpeedStatus(); - - bool wasPanic = info.panic; - info.panic = false; // otherwise we could barely do anything in the exit function - - errorcode = lua_pcall(L, 0, 0, 0); - - info.panic |= wasPanic; // restore panic - - info.running = wasRunning; - RefreshScriptSpeedStatus(); - } - - // save persisted variable info after the exit function runs (even if it crashed) - { - // gather the final value of the variables we're supposed to persist - LuaSaveData newExitData; - { - int numPersistVars = info.persistVars.size(); - for(int i = 0; i < numPersistVars; i++) - { - const char* varName = info.persistVars[i].c_str(); - lua_getfield(L, LUA_GLOBALSINDEX, varName); - int type = lua_type(L,-1); - unsigned int varNameCRC = crc32(0, (const unsigned char*)varName, strlen(varName)); - newExitData.SaveRecordPartial(uid, varNameCRC, -1); - lua_pop(L,1); - } - } - - char path [1024] = {0}; - char* pathTypeChrPtr = ConstructScriptSaveDataPath(path, 1024, info); - - *pathTypeChrPtr = 'd'; - if(info.newDefaultData.recordList) - { - FILE* defaultsFile = fopen(path, "wb"); - if(defaultsFile) - { - info.newDefaultData.ExportRecords(defaultsFile); - fclose(defaultsFile); - } - } - else unlink(path); - - *pathTypeChrPtr = 'e'; - if(newExitData.recordList) - { - FILE* persistFile = fopen(path, "wb"); - if(persistFile) - { - newExitData.ExportRecords(persistFile); - fclose(persistFile); - } - } - else unlink(path); - } - - if (errorcode) - HandleCallbackError(L,info,uid,false); - - } -} - -void StopLuaScript(int uid) -{ - LuaContextInfo* infoPtr = luaContextInfo[uid]; - if(!infoPtr) - return; - - LuaContextInfo& info = *infoPtr; - - if(info.running) - { - // if it's currently running then we can't stop it now without crashing - // so the best we can do is politely request for it to go kill itself - RequestAbortLuaScript(uid); - return; - } - - lua_State* L = info.L; - if(L) - { - CallExitFunction(uid); - - if(info.onstop) - { - info.stopWorrying = true, info.worryCount++, dontworry(info); // clear "busy" status - info.onstop(uid, !info.crashed); // must happen before closing L and after the exit function, otherwise the final GUI state of the script won't be shown properly or at all - } - - if(info.started) // this check is necessary - { - lua_close(L); -#ifndef USE_INFO_STACK - luaStateToContextMap.erase(L); -#endif - luaStateToUIDMap.erase(L); - info.L = NULL; - info.started = false; - - info.numMemHooks = 0; - for(int i = 0; i < LUAMEMHOOK_COUNT; i++) - CalculateMemHookRegions((LuaMemHookType)i); - } - RefreshScriptStartedStatus(); - } -} - -void CloseLuaContext(int uid) -{ - StopLuaScript(uid); - delete luaContextInfo[uid]; - luaContextInfo.erase(uid); -} - - -// the purpose of this structure is to provide a way of -// QUICKLY determining whether a memory address range has a hook associated with it, -// with a bias toward fast rejection because the majority of addresses will not be hooked. -// (it must not use any part of Lua or perform any per-script operations, -// otherwise it would definitely be too slow.) -// calculating the regions when a hook is added/removed may be slow, -// but this is an intentional tradeoff to obtain a high speed of checking during later execution -struct TieredRegion -{ - template - struct Region - { - struct Island - { - unsigned int start; - unsigned int end; - __forceinline bool Contains(unsigned int address, int size) const { return address < end && address+size > start; } - }; - std::vector islands; - - void Calculate(const std::vector& bytes) - { - islands.clear(); - - unsigned int lastEnd = ~0; - - std::vector::const_iterator iter = bytes.begin(); - std::vector::const_iterator end = bytes.end(); - for(; iter != end; ++iter) - { - unsigned int addr = *iter; - if(addr < lastEnd || addr > lastEnd + (long long)maxGap) - { - islands.push_back(Island()); - islands.back().start = addr; - } - islands.back().end = addr+1; - lastEnd = addr+1; - } - } - - bool Contains(unsigned int address, int size) const - { - std::vector::const_iterator iter = islands.begin(); - std::vector::const_iterator end = islands.end(); - for(; iter != end; ++iter) - if(iter->Contains(address, size)) - return true; - return false; - } - }; - - Region<0xFFFFFFFF> broad; - Region<0x1000> mid; - Region<0> narrow; - - void Calculate(std::vector& bytes) - { - std::sort(bytes.begin(), bytes.end()); - - broad.Calculate(bytes); - mid.Calculate(bytes); - narrow.Calculate(bytes); - } - - TieredRegion() - { - Calculate(std::vector()); - } - - __forceinline int NotEmpty() - { - return broad.islands.size(); - } - - // note: it is illegal to call this if NotEmpty() returns 0 - __forceinline bool Contains(unsigned int address, int size) - { - return broad.islands[0].Contains(address,size) && - mid.Contains(address,size) && - narrow.Contains(address,size); - } -}; -TieredRegion hookedRegions [LUAMEMHOOK_COUNT]; - - -static void CalculateMemHookRegions(LuaMemHookType hookType) -{ - std::vector hookedBytes; - std::map::iterator iter = luaContextInfo.begin(); - std::map::iterator end = luaContextInfo.end(); - while(iter != end) - { - LuaContextInfo& info = *iter->second; - if(info.numMemHooks) - { - lua_State* L = info.L; - if(L) - { - lua_settop(L, 0); - lua_getfield(L, LUA_REGISTRYINDEX, luaMemHookTypeStrings[hookType]); - lua_pushnil(L); - while(lua_next(L, -2)) - { - if(lua_isfunction(L, -1)) - { - unsigned int addr = lua_tointeger(L, -2); - hookedBytes.push_back(addr); - } - lua_pop(L, 1); - } - lua_settop(L, 0); - } - } - ++iter; - } - hookedRegions[hookType].Calculate(hookedBytes); -} - - - - - -static void CallRegisteredLuaMemHook_LuaMatch(unsigned int address, int size, unsigned int value, LuaMemHookType hookType) -{ - std::map::iterator iter = luaContextInfo.begin(); - std::map::iterator end = luaContextInfo.end(); - while(iter != end) - { - LuaContextInfo& info = *iter->second; - if(info.numMemHooks) - { - lua_State* L = info.L; - if(L && !info.panic) - { -#ifdef USE_INFO_STACK - infoStack.insert(infoStack.begin(), &info); - struct Scope { ~Scope(){ infoStack.erase(infoStack.begin()); } } scope; -#endif - lua_settop(L, 0); - lua_getfield(L, LUA_REGISTRYINDEX, luaMemHookTypeStrings[hookType]); - for(int i = address; i != address+size; i++) - { - lua_rawgeti(L, -1, i); - if (lua_isfunction(L, -1)) - { - bool wasRunning = info.running; - info.running = true; - RefreshScriptSpeedStatus(); - lua_pushinteger(L, address); - lua_pushinteger(L, size); - int errorcode = lua_pcall(L, 2, 0, 0); - info.running = wasRunning; - RefreshScriptSpeedStatus(); - if (errorcode) - { - int uid = iter->first; - HandleCallbackError(L,info,uid,true); - } - break; - } - else - { - lua_pop(L,1); - } - } - lua_settop(L, 0); - } - } - ++iter; - } -} -void CallRegisteredLuaMemHook(unsigned int address, int size, unsigned int value, LuaMemHookType hookType) -{ - // performance critical! (called VERY frequently) - // I suggest timing a large number of calls to this function in Release if you change anything in here, - // before and after, because even the most innocent change can make it become 30% to 400% slower. - // a good amount to test is: 100000000 calls with no hook set, and another 100000000 with a hook set. - // (on my system that consistently took 200 ms total in the former case and 350 ms total in the latter case) - if(hookedRegions[hookType].NotEmpty()) - { - if((hookType <= LUAMEMHOOK_EXEC) && (address >= 0xE00000)) - address |= 0xFF0000; // account for mirroring of RAM - if(hookedRegions[hookType].Contains(address, size)) - CallRegisteredLuaMemHook_LuaMatch(address, size, value, hookType); // something has hooked this specific address - } -} - - - -void CallRegisteredLuaFunctions(LuaCallID calltype) -{ - assert((unsigned int)calltype < (unsigned int)LUACALL_COUNT); - const char* idstring = luaCallIDStrings[calltype]; - - std::map::iterator iter = luaContextInfo.begin(); - std::map::iterator end = luaContextInfo.end(); - while(iter != end) - { - int uid = iter->first; - LuaContextInfo& info = *iter->second; - lua_State* L = info.L; - if(L && (!info.panic || calltype == LUACALL_BEFOREEXIT)) - { -#ifdef USE_INFO_STACK - infoStack.insert(infoStack.begin(), &info); - struct Scope { ~Scope(){ infoStack.erase(infoStack.begin()); } } scope; -#endif - // handle deferred GUI function calls and disabling deferring when unnecessary - if(calltype == LUACALL_AFTEREMULATIONGUI || calltype == LUACALL_AFTEREMULATION) - info.guiFuncsNeedDeferring = false; - if(calltype == LUACALL_AFTEREMULATIONGUI) - CallDeferredFunctions(L, deferredGUIIDString); - - lua_settop(L, 0); - lua_getfield(L, LUA_REGISTRYINDEX, idstring); - - if (lua_isfunction(L, -1)) - { - bool wasRunning = info.running; - info.running = true; - RefreshScriptSpeedStatus(); - int errorcode = lua_pcall(L, 0, 0, 0); - info.running = wasRunning; - RefreshScriptSpeedStatus(); - if (errorcode) - HandleCallbackError(L,info,uid,true); - } - else - { - lua_pop(L, 1); - } - - info.guiFuncsNeedDeferring = true; - } - - ++iter; - } -} - -void CallRegisteredLuaSaveFunctions(int savestateNumber, LuaSaveData& saveData) -{ - const char* idstring = luaCallIDStrings[LUACALL_BEFORESAVE]; - - std::map::iterator iter = luaContextInfo.begin(); - std::map::iterator end = luaContextInfo.end(); - while(iter != end) - { - int uid = iter->first; - LuaContextInfo& info = *iter->second; - lua_State* L = info.L; - if(L) - { -#ifdef USE_INFO_STACK - infoStack.insert(infoStack.begin(), &info); - struct Scope { ~Scope(){ infoStack.erase(infoStack.begin()); } } scope; -#endif - - lua_settop(L, 0); - lua_getfield(L, LUA_REGISTRYINDEX, idstring); - - if (lua_isfunction(L, -1)) - { - bool wasRunning = info.running; - info.running = true; - RefreshScriptSpeedStatus(); - lua_pushinteger(L, savestateNumber); - int errorcode = lua_pcall(L, 1, LUA_MULTRET, 0); - info.running = wasRunning; - RefreshScriptSpeedStatus(); - if (errorcode) - HandleCallbackError(L,info,uid,true); - saveData.SaveRecord(uid, info.dataSaveKey); - } - else - { - lua_pop(L, 1); - } - } - - ++iter; - } -} - - -void CallRegisteredLuaLoadFunctions(int savestateNumber, const LuaSaveData& saveData) -{ - const char* idstring = luaCallIDStrings[LUACALL_AFTERLOAD]; - - std::map::iterator iter = luaContextInfo.begin(); - std::map::iterator end = luaContextInfo.end(); - while(iter != end) - { - int uid = iter->first; - LuaContextInfo& info = *iter->second; - lua_State* L = info.L; - if(L) - { -#ifdef USE_INFO_STACK - infoStack.insert(infoStack.begin(), &info); - struct Scope { ~Scope(){ infoStack.erase(infoStack.begin()); } } scope; -#endif - - lua_settop(L, 0); - lua_getfield(L, LUA_REGISTRYINDEX, idstring); - - if (lua_isfunction(L, -1)) - { - bool wasRunning = info.running; - info.running = true; - RefreshScriptSpeedStatus(); - - // since the scriptdata can be very expensive to load - // (e.g. the registered save function returned some huge tables) - // check the number of parameters the registered load function expects - // and don't bother loading the parameters it wouldn't receive anyway - int numParamsExpected = (L->top - 1)->value.gc->cl.l.p->numparams; - if(numParamsExpected) numParamsExpected--; // minus one for the savestate number we always pass in - - int prevGarbage = lua_gc(L, LUA_GCCOUNT, 0); - - lua_pushinteger(L, savestateNumber); - saveData.LoadRecord(uid, info.dataLoadKey, numParamsExpected); - int n = lua_gettop(L) - 1; - - int errorcode = lua_pcall(L, n, 0, 0); - info.running = wasRunning; - RefreshScriptSpeedStatus(); - if (errorcode) - HandleCallbackError(L,info,uid,true); - else - { - int newGarbage = lua_gc(L, LUA_GCCOUNT, 0); - if(newGarbage - prevGarbage > 50) - { - // now seems to be a very good time to run the garbage collector - // it might take a while now but that's better than taking 10 whiles 9 loads from now - lua_gc(L, LUA_GCCOLLECT, 0); - } - } - } - else - { - lua_pop(L, 1); - } - } - - ++iter; - } -} - -static const unsigned char* s_dbg_dataStart = NULL; -static int s_dbg_dataSize = 0; - - -// can't remember what the best way of doing this is... -#if defined(i386) || defined(__i386) || defined(__i386__) || defined(M_I86) || defined(_M_IX86) || defined(_WIN32) - #define IS_LITTLE_ENDIAN -#endif - -// push a value's bytes onto the output stack -template -void PushBinaryItem(T item, std::vector& output) -{ - unsigned char* buf = (unsigned char*)&item; -#ifdef IS_LITTLE_ENDIAN - for(int i = sizeof(T); i; i--) - output.push_back(*buf++); -#else - int vecsize = output.size(); - for(int i = sizeof(T); i; i--) - output.insert(output.begin() + vecsize, *buf++); -#endif -} -// read a value from the byte stream and advance the stream by its size -template -T AdvanceByteStream(const unsigned char*& data, unsigned int& remaining) -{ -#ifdef IS_LITTLE_ENDIAN - T rv = *(T*)data; - data += sizeof(T); -#else - T rv; unsigned char* rvptr = (unsigned char*)&rv; - for(int i = sizeof(T)-1; i>=0; i--) - rvptr[i] = *data++; -#endif - remaining -= sizeof(T); - return rv; -} -// advance the byte stream by a certain size without reading a value -void AdvanceByteStream(const unsigned char*& data, unsigned int& remaining, int amount) -{ - data += amount; - remaining -= amount; -} - -#define LUAEXT_TLONG 30 // 0x1E // 4-byte signed integer -#define LUAEXT_TUSHORT 31 // 0x1F // 2-byte unsigned integer -#define LUAEXT_TSHORT 32 // 0x20 // 2-byte signed integer -#define LUAEXT_TBYTE 33 // 0x21 // 1-byte unsigned integer -#define LUAEXT_TNILS 34 // 0x22 // multiple nils represented by a 4-byte integer (warning: becomes multiple stack entities) -#define LUAEXT_TTABLE 0x40 // 0x40 through 0x4F // tables of different sizes: -#define LUAEXT_BITS_1A 0x01 // size of array part fits in a 1-byte unsigned integer -#define LUAEXT_BITS_2A 0x02 // size of array part fits in a 2-byte unsigned integer -#define LUAEXT_BITS_4A 0x03 // size of array part fits in a 4-byte unsigned integer -#define LUAEXT_BITS_1H 0x04 // size of hash part fits in a 1-byte unsigned integer -#define LUAEXT_BITS_2H 0x08 // size of hash part fits in a 2-byte unsigned integer -#define LUAEXT_BITS_4H 0x0C // size of hash part fits in a 4-byte unsigned integer -#define BITMATCH(x,y) (((x) & (y)) == (y)) - -static void PushNils(std::vector& output, int& nilcount) -{ - int count = nilcount; - nilcount = 0; - - static const int minNilsWorthEncoding = 6; // because a LUAEXT_TNILS entry is 5 bytes - - if(count < minNilsWorthEncoding) - { - for(int i = 0; i < count; i++) - output.push_back(LUA_TNIL); - } - else - { - output.push_back(LUAEXT_TNILS); - PushBinaryItem(count, output); - } -} - - -static void LuaStackToBinaryConverter(lua_State* L, int i, std::vector& output) -{ - int type = lua_type(L, i); - - // the first byte of every serialized item says what Lua type it is - output.push_back(type & 0xFF); - - switch(type) - { - default: - { - //printf("wrote unknown type %d (0x%x)\n", type, type); - //assert(0); - - LuaContextInfo& info = GetCurrentInfo(); - if(info.print) - { - char errmsg [1024]; - sprintf(errmsg, "values of type \"%s\" are not allowed to be returned from registered save functions.\r\n", luaL_typename(L,i)); - info.print(luaStateToUIDMap[L], errmsg); - } - else - { - fprintf(stderr, "values of type \"%s\" are not allowed to be returned from registered save functions.\n", luaL_typename(L,i)); - } - } - break; - case LUA_TNIL: - // no information necessary beyond the type - break; - case LUA_TBOOLEAN: - // serialize as 0 or 1 - output.push_back(lua_toboolean(L,i)); - break; - case LUA_TSTRING: - // serialize as a 0-terminated string of characters - { - const char* str = lua_tostring(L,i); - while(*str) - output.push_back(*str++); - output.push_back('\0'); - } - break; - case LUA_TNUMBER: - { - double num = (double)lua_tonumber(L,i); - INT32 inum = (INT32)lua_tointeger(L,i); - if(num != inum) - { - PushBinaryItem(num, output); - } - else - { - if((inum & ~0xFF) == 0) - type = LUAEXT_TBYTE; - else if((UINT16)(inum & 0xFFFF) == inum) - type = LUAEXT_TUSHORT; - else if((INT16)(inum & 0xFFFF) == inum) - type = LUAEXT_TSHORT; - else - type = LUAEXT_TLONG; - output.back() = type; - switch(type) - { - case LUAEXT_TLONG: - PushBinaryItem(inum, output); - break; - case LUAEXT_TUSHORT: - PushBinaryItem(inum, output); - break; - case LUAEXT_TSHORT: - PushBinaryItem(inum, output); - break; - case LUAEXT_TBYTE: - output.push_back(inum); - break; - } - } - } - break; - case LUA_TTABLE: - // serialize as a type that describes how many bytes are used for storing the counts, - // followed by the number of array entries if any, then the number of hash entries if any, - // then a Lua value per array entry, then a (key,value) pair of Lua values per hashed entry - // note that the structure of table references are not faithfully serialized (yet) - { - int outputTypeIndex = output.size() - 1; - int arraySize = 0; - int hashSize = 0; - - if(lua_checkstack(L, 4) && std::find(s_tableAddressStack.begin(), s_tableAddressStack.end(), lua_topointer(L,i)) == s_tableAddressStack.end()) - { - s_tableAddressStack.push_back(lua_topointer(L,i)); - struct Scope { ~Scope(){ s_tableAddressStack.pop_back(); } } scope; - - bool wasnil = false; - int nilcount = 0; - arraySize = lua_objlen(L, i); - int arrayValIndex = lua_gettop(L) + 1; - for(int j = 1; j <= arraySize; j++) - { - lua_rawgeti(L, i, j); - bool isnil = lua_isnil(L, arrayValIndex); - if(isnil) - nilcount++; - else - { - if(wasnil) - PushNils(output, nilcount); - LuaStackToBinaryConverter(L, arrayValIndex, output); - } - lua_pop(L, 1); - wasnil = isnil; - } - if(wasnil) - PushNils(output, nilcount); - - if(arraySize) - lua_pushinteger(L, arraySize); // before first key - else - lua_pushnil(L); // before first key - - int keyIndex = lua_gettop(L); - int valueIndex = keyIndex + 1; - while(lua_next(L, i)) - { - assert(lua_type(L, keyIndex) && "nil key in Lua table, impossible"); - assert(lua_type(L, valueIndex) && "nil value in Lua table, impossible"); - LuaStackToBinaryConverter(L, keyIndex, output); - LuaStackToBinaryConverter(L, valueIndex, output); - lua_pop(L, 1); - hashSize++; - } - } - - int outputType = LUAEXT_TTABLE; - if(arraySize & 0xFFFF0000) - outputType |= LUAEXT_BITS_4A; - else if(arraySize & 0xFF00) - outputType |= LUAEXT_BITS_2A; - else if(arraySize & 0xFF) - outputType |= LUAEXT_BITS_1A; - if(hashSize & 0xFFFF0000) - outputType |= LUAEXT_BITS_4H; - else if(hashSize & 0xFF00) - outputType |= LUAEXT_BITS_2H; - else if(hashSize & 0xFF) - outputType |= LUAEXT_BITS_1H; - output[outputTypeIndex] = outputType; - - int insertIndex = outputTypeIndex; - if(BITMATCH(outputType,LUAEXT_BITS_4A) || BITMATCH(outputType,LUAEXT_BITS_2A) || BITMATCH(outputType,LUAEXT_BITS_1A)) - output.insert(output.begin() + (++insertIndex), arraySize & 0xFF); - if(BITMATCH(outputType,LUAEXT_BITS_4A) || BITMATCH(outputType,LUAEXT_BITS_2A)) - output.insert(output.begin() + (++insertIndex), (arraySize & 0xFF00) >> 8); - if(BITMATCH(outputType,LUAEXT_BITS_4A)) - output.insert(output.begin() + (++insertIndex), (arraySize & 0x00FF0000) >> 16), - output.insert(output.begin() + (++insertIndex), (arraySize & 0xFF000000) >> 24); - if(BITMATCH(outputType,LUAEXT_BITS_4H) || BITMATCH(outputType,LUAEXT_BITS_2H) || BITMATCH(outputType,LUAEXT_BITS_1H)) - output.insert(output.begin() + (++insertIndex), hashSize & 0xFF); - if(BITMATCH(outputType,LUAEXT_BITS_4H) || BITMATCH(outputType,LUAEXT_BITS_2H)) - output.insert(output.begin() + (++insertIndex), (hashSize & 0xFF00) >> 8); - if(BITMATCH(outputType,LUAEXT_BITS_4H)) - output.insert(output.begin() + (++insertIndex), (hashSize & 0x00FF0000) >> 16), - output.insert(output.begin() + (++insertIndex), (hashSize & 0xFF000000) >> 24); - - } break; - } -} - - -// complements LuaStackToBinaryConverter -void BinaryToLuaStackConverter(lua_State* L, const unsigned char*& data, unsigned int& remaining) -{ - assert(s_dbg_dataSize - (data - s_dbg_dataStart) == remaining); - - unsigned char type = AdvanceByteStream(data, remaining); - - switch(type) - { - default: - { - //printf("read unknown type %d (0x%x)\n", type, type); - //assert(0); - - LuaContextInfo& info = GetCurrentInfo(); - if(info.print) - { - char errmsg [1024]; - if(type <= 10 && type != LUA_TTABLE) - sprintf(errmsg, "values of type \"%s\" are not allowed to be loaded into registered load functions. The save state's Lua save data file might be corrupted.\r\n", lua_typename(L,type)); - else - sprintf(errmsg, "The save state's Lua save data file seems to be corrupted.\r\n"); - info.print(luaStateToUIDMap[L], errmsg); - } - else - { - if(type <= 10 && type != LUA_TTABLE) - fprintf(stderr, "values of type \"%s\" are not allowed to be loaded into registered load functions. The save state's Lua save data file might be corrupted.\n", lua_typename(L,type)); - else - fprintf(stderr, "The save state's Lua save data file seems to be corrupted.\n"); - } - } - break; - case LUA_TNIL: - lua_pushnil(L); - break; - case LUA_TBOOLEAN: - lua_pushboolean(L, AdvanceByteStream(data, remaining)); - break; - case LUA_TSTRING: - lua_pushstring(L, (const char*)data); - AdvanceByteStream(data, remaining, strlen((const char*)data) + 1); - break; - case LUA_TNUMBER: - lua_pushnumber(L, AdvanceByteStream(data, remaining)); - break; - case LUAEXT_TLONG: - lua_pushinteger(L, AdvanceByteStream(data, remaining)); - break; - case LUAEXT_TUSHORT: - lua_pushinteger(L, AdvanceByteStream(data, remaining)); - break; - case LUAEXT_TSHORT: - lua_pushinteger(L, AdvanceByteStream(data, remaining)); - break; - case LUAEXT_TBYTE: - lua_pushinteger(L, AdvanceByteStream(data, remaining)); - break; - case LUAEXT_TTABLE: - case LUAEXT_TTABLE | LUAEXT_BITS_1A: - case LUAEXT_TTABLE | LUAEXT_BITS_2A: - case LUAEXT_TTABLE | LUAEXT_BITS_4A: - case LUAEXT_TTABLE | LUAEXT_BITS_1H: - case LUAEXT_TTABLE | LUAEXT_BITS_2H: - case LUAEXT_TTABLE | LUAEXT_BITS_4H: - case LUAEXT_TTABLE | LUAEXT_BITS_1A | LUAEXT_BITS_1H: - case LUAEXT_TTABLE | LUAEXT_BITS_2A | LUAEXT_BITS_1H: - case LUAEXT_TTABLE | LUAEXT_BITS_4A | LUAEXT_BITS_1H: - case LUAEXT_TTABLE | LUAEXT_BITS_1A | LUAEXT_BITS_2H: - case LUAEXT_TTABLE | LUAEXT_BITS_2A | LUAEXT_BITS_2H: - case LUAEXT_TTABLE | LUAEXT_BITS_4A | LUAEXT_BITS_2H: - case LUAEXT_TTABLE | LUAEXT_BITS_1A | LUAEXT_BITS_4H: - case LUAEXT_TTABLE | LUAEXT_BITS_2A | LUAEXT_BITS_4H: - case LUAEXT_TTABLE | LUAEXT_BITS_4A | LUAEXT_BITS_4H: - { - unsigned int arraySize = 0; - if(BITMATCH(type,LUAEXT_BITS_4A) || BITMATCH(type,LUAEXT_BITS_2A) || BITMATCH(type,LUAEXT_BITS_1A)) - arraySize |= AdvanceByteStream(data, remaining); - if(BITMATCH(type,LUAEXT_BITS_4A) || BITMATCH(type,LUAEXT_BITS_2A)) - arraySize |= ((UINT16)AdvanceByteStream(data, remaining)) << 8; - if(BITMATCH(type,LUAEXT_BITS_4A)) - arraySize |= ((UINT32)AdvanceByteStream(data, remaining)) << 16, - arraySize |= ((UINT32)AdvanceByteStream(data, remaining)) << 24; - - unsigned int hashSize = 0; - if(BITMATCH(type,LUAEXT_BITS_4H) || BITMATCH(type,LUAEXT_BITS_2H) || BITMATCH(type,LUAEXT_BITS_1H)) - hashSize |= AdvanceByteStream(data, remaining); - if(BITMATCH(type,LUAEXT_BITS_4H) || BITMATCH(type,LUAEXT_BITS_2H)) - hashSize |= ((UINT16)AdvanceByteStream(data, remaining)) << 8; - if(BITMATCH(type,LUAEXT_BITS_4H)) - hashSize |= ((UINT32)AdvanceByteStream(data, remaining)) << 16, - hashSize |= ((UINT32)AdvanceByteStream(data, remaining)) << 24; - - lua_createtable(L, arraySize, hashSize); - - unsigned int n = 1; - while(n <= arraySize) - { - if(*data == LUAEXT_TNILS) - { - AdvanceByteStream(data, remaining, 1); - n += AdvanceByteStream(data, remaining); - } - else - { - BinaryToLuaStackConverter(L, data, remaining); // push value - lua_rawseti(L, -2, n); // table[n] = value - n++; - } - } - - for(unsigned int h = 1; h <= hashSize; h++) - { - BinaryToLuaStackConverter(L, data, remaining); // push key - BinaryToLuaStackConverter(L, data, remaining); // push value - lua_rawset(L, -3); // table[key] = value - } - } - break; - } -} - -static const unsigned char luaBinaryMajorVersion = 9; -static const unsigned char luaBinaryMinorVersion = 1; - -unsigned char* LuaStackToBinary(lua_State* L, unsigned int& size) -{ - int n = lua_gettop(L); - if(n == 0) - return NULL; - - std::vector output; - output.push_back(luaBinaryMajorVersion); - output.push_back(luaBinaryMinorVersion); - - for(int i = 1; i <= n; i++) - LuaStackToBinaryConverter(L, i, output); - - unsigned char* rv = new unsigned char [output.size()]; - memcpy(rv, &output.front(), output.size()); - size = output.size(); - return rv; -} - -void BinaryToLuaStack(lua_State* L, const unsigned char* data, unsigned int size, unsigned int itemsToLoad) -{ - unsigned char major = *data++; - unsigned char minor = *data++; - size -= 2; - if(luaBinaryMajorVersion != major || luaBinaryMinorVersion != minor) - return; - - while(size > 0 && itemsToLoad > 0) - { - BinaryToLuaStackConverter(L, data, size); - itemsToLoad--; - } -} - -// saves Lua stack into a record and pops it -void LuaSaveData::SaveRecord(int uid, unsigned int key) -{ - LuaContextInfo& info = *luaContextInfo[uid]; - lua_State* L = info.L; - if(!L) - return; - - Record* cur = new Record(); - cur->key = key; - cur->data = LuaStackToBinary(L, cur->size); - cur->next = NULL; - - lua_settop(L,0); - - if(cur->size <= 0) - { - delete cur; - return; - } - - Record* last = recordList; - while(last && last->next) - last = last->next; - if(last) - last->next = cur; - else - recordList = cur; -} - -// pushes a record's data onto the Lua stack -void LuaSaveData::LoadRecord(int uid, unsigned int key, unsigned int itemsToLoad) const -{ - LuaContextInfo& info = *luaContextInfo[uid]; - lua_State* L = info.L; - if(!L) - return; - - Record* cur = recordList; - while(cur) - { - if(cur->key == key) - { - s_dbg_dataStart = cur->data; - s_dbg_dataSize = cur->size; - BinaryToLuaStack(L, cur->data, cur->size, itemsToLoad); - return; - } - cur = cur->next; - } -} - -// saves part of the Lua stack (at the given index) into a record and does NOT pop anything -void LuaSaveData::SaveRecordPartial(int uid, unsigned int key, int idx) -{ - LuaContextInfo& info = *luaContextInfo[uid]; - lua_State* L = info.L; - if(!L) - return; - - if(idx < 0) - idx += lua_gettop(L)+1; - - Record* cur = new Record(); - cur->key = key; - cur->next = NULL; - - if(idx <= lua_gettop(L)) - { - std::vector output; - output.push_back(luaBinaryMajorVersion); - output.push_back(luaBinaryMinorVersion); - - LuaStackToBinaryConverter(L, idx, output); - - unsigned char* rv = new unsigned char [output.size()]; - memcpy(rv, &output.front(), output.size()); - cur->size = output.size(); - cur->data = rv; - } - - if(cur->size <= 0) - { - delete cur; - return; - } - - Record* last = recordList; - while(last && last->next) - last = last->next; - if(last) - last->next = cur; - else - recordList = cur; -} - -void fwriteint(unsigned int value, FILE* file) -{ - for(int i=0;i<4;i++) - { - int w = value & 0xFF; - fwrite(&w, 1, 1, file); - value >>= 8; - } -} -void freadint(unsigned int& value, FILE* file) -{ - int rv = 0; - for(int i=0;i<4;i++) - { - int r = 0; - fread(&r, 1, 1, file); - rv |= r << (i*8); - } - value = rv; -} - -// writes all records to an already-open file -void LuaSaveData::ExportRecords(void* fileV) const -{ - FILE* file = (FILE*)fileV; - if(!file) - return; - - Record* cur = recordList; - while(cur) - { - fwriteint(cur->key, file); - fwriteint(cur->size, file); - fwrite(cur->data, cur->size, 1, file); - cur = cur->next; - } -} - -// reads records from an already-open file -void LuaSaveData::ImportRecords(void* fileV) -{ - FILE* file = (FILE*)fileV; - if(!file) - return; - - ClearRecords(); - - Record rec; - Record* cur = &rec; - Record* last = NULL; - while(1) - { - freadint(cur->key, file); - freadint(cur->size, file); - - if(feof(file) || ferror(file)) - break; - - cur->data = new unsigned char [cur->size]; - fread(cur->data, cur->size, 1, file); - - Record* next = new Record(); - memcpy(next, cur, sizeof(Record)); - next->next = NULL; - - if(last) - last->next = next; - else - recordList = next; - last = next; - } -} - -void LuaSaveData::ClearRecords() -{ - Record* cur = recordList; - while(cur) - { - Record* del = cur; - cur = cur->next; - - delete[] del->data; - delete del; - } - - recordList = NULL; -} - - - -void DontWorryLua() // everything's going to be OK -{ - std::map::const_iterator iter = luaContextInfo.begin(); - std::map::const_iterator end = luaContextInfo.end(); - while(iter != end) - { - dontworry(*iter->second); - ++iter; - } -} - -void EnableStopAllLuaScripts(bool enable) -{ - g_stopAllScriptsEnabled = enable; -} - -void StopAllLuaScripts() -{ - if(!g_stopAllScriptsEnabled) - return; - - std::map::const_iterator iter = luaContextInfo.begin(); - std::map::const_iterator end = luaContextInfo.end(); - while(iter != end) - { - int uid = iter->first; - LuaContextInfo& info = *iter->second; - bool wasStarted = info.started; - StopLuaScript(uid); - info.restartLater = wasStarted; - ++iter; - } -} - -void RestartAllLuaScripts() -{ - if(!g_stopAllScriptsEnabled) - return; - - std::map::const_iterator iter = luaContextInfo.begin(); - std::map::const_iterator end = luaContextInfo.end(); - while(iter != end) - { - int uid = iter->first; - LuaContextInfo& info = *iter->second; - if(info.restartLater || info.started) - { - info.restartLater = false; - RunLuaScriptFile(uid, info.lastFilename.c_str()); - } - ++iter; - } -} - -// sets anything that needs to depend on the total number of scripts running -void RefreshScriptStartedStatus() -{ - int numScriptsStarted = 0; - - std::map::const_iterator iter = luaContextInfo.begin(); - std::map::const_iterator end = luaContextInfo.end(); - while(iter != end) - { - LuaContextInfo& info = *iter->second; - if(info.started) - numScriptsStarted++; - ++iter; - } - -// frameadvSkipLagForceDisable = (numScriptsStarted != 0); // disable while scripts are running because currently lag skipping makes lua callbacks get called twice per frame advance - g_numScriptsStarted = numScriptsStarted; -} - -// sets anything that needs to depend on speed mode or running status of scripts -void RefreshScriptSpeedStatus() -{ - g_anyScriptsHighSpeed = false; - - std::map::const_iterator iter = luaContextInfo.begin(); - std::map::const_iterator end = luaContextInfo.end(); - while(iter != end) - { - LuaContextInfo& info = *iter->second; - if(info.running) - if(info.speedMode == SPEEDMODE_TURBO || info.speedMode == SPEEDMODE_MAXIMUM) - g_anyScriptsHighSpeed = true; - ++iter; - } -} - +#include "lua-engine.h" +#include "movie.h" +#include +#include +#include +#include +#include +#include "zlib.h" +#include "NDSSystem.h" +#include "movie.h" +#ifdef WIN32 +#include "main.h" +#include "windows.h" +#endif + +// the emulator must provide these so that we can implement +// the various functions the user can call from their lua script +// (this interface with the emulator needs cleanup, I know) +// adapted from gens-rr, nitsuja + upthorn +extern int (*Update_Frame)(); +extern int (*Update_Frame_Fast)(); + +extern "C" { + #include "lua.h" + #include "lauxlib.h" + #include "lualib.h" + #include "lstate.h" +}; + +enum SpeedMode +{ + SPEEDMODE_NORMAL, + SPEEDMODE_NOTHROTTLE, + SPEEDMODE_TURBO, + SPEEDMODE_MAXIMUM, +}; + +struct LuaContextInfo { + lua_State* L; // the Lua state + bool started; // script has been started and hasn't yet been terminated, although it may not be currently running + bool running; // script is currently running code (either the main call to the script or the callbacks it registered) + bool returned; // main call to the script has returned (but it may still be active if it registered callbacks) + bool crashed; // true if script has errored out + bool restart; // if true, tells the script-running code to restart the script when the script stops + bool restartLater; // set to true when a still-running script is stopped so that RestartAllLuaScripts can know which scripts to restart + unsigned int worryCount; // counts up as the script executes, gets reset when the application is able to process messages, triggers a warning prompt if it gets too high + bool stopWorrying; // set to true if the user says to let the script run forever despite appearing to be frozen + bool panic; // if set to true, tells the script to terminate as soon as it can do so safely (used because directly calling lua_close() or luaL_error() is unsafe in some contexts) + bool ranExit; // used to prevent a registered exit callback from ever getting called more than once + bool guiFuncsNeedDeferring; // true whenever GUI drawing would be cleared by the next emulation update before it would be visible, and thus needs to be deferred until after the next emulation update + int numDeferredGUIFuncs; // number of deferred function calls accumulated, used to impose an arbitrary limit to avoid running out of memory + bool ranFrameAdvance; // false if gens.frameadvance() hasn't been called yet + int transparencyModifier; // values less than 255 will scale down the opacity of whatever the GUI renders, values greater than 255 will increase the opacity of anything transparent the GUI renders + SpeedMode speedMode; // determines how gens.frameadvance() acts + char panicMessage [72]; // a message to print if the script terminates due to panic being set + std::string lastFilename; // path to where the script last ran from so that restart can work (note: storing the script in memory instead would not be useful because we always want the most up-to-date script from file) + std::string nextFilename; // path to where the script should run from next, mainly used in case the restart flag is true + unsigned int dataSaveKey; // crc32 of the save data key, used to decide which script should get which data... by default (if no key is specified) it's calculated from the script filename + unsigned int dataLoadKey; // same as dataSaveKey but set through registerload instead of registersave if the two differ + bool dataSaveLoadKeySet; // false if the data save keys are unset or set to their default value + bool rerecordCountingDisabled; // true if this script has disabled rerecord counting for the savestates it loads + std::vector persistVars; // names of the global variables to persist, kept here so their associated values can be output when the script exits + LuaSaveData newDefaultData; // data about the default state of persisted global variables, which we save on script exit so we can detect when the default value has changed to make it easier to reset persisted variables + unsigned int numMemHooks; // number of registered memory functions (1 per hooked byte) + // callbacks into the lua window... these don't need to exist per context the way I'm using them, but whatever + void(*print)(int uid, const char* str); + void(*onstart)(int uid); + void(*onstop)(int uid, bool statusOK); +}; +std::map luaContextInfo; +std::map luaStateToUIDMap; +int g_numScriptsStarted = 0; +bool g_anyScriptsHighSpeed = false; +bool g_stopAllScriptsEnabled = true; + +#define USE_INFO_STACK +#ifdef USE_INFO_STACK + std::vector infoStack; + #define GetCurrentInfo() *infoStack.front() // should be faster but relies on infoStack correctly being updated to always have the current info in the first element +#else + std::map luaStateToContextMap; + #define GetCurrentInfo() *luaStateToContextMap[L] // should always work but might be slower +#endif + +//#define ASK_USER_ON_FREEZE // dialog on freeze is disabled now because it seems to be unnecessary, but this can be re-defined to enable it + + +static std::map s_cFuncInfoMap; + +// using this macro you can define a callable-from-Lua function +// while associating with it some information about its arguments. +// that information will show up if the user tries to print the function +// or otherwise convert it to a string. +// (for example, "writebyte=function(addr,value)" instead of "writebyte=function:0A403490") +// note that the user can always use addressof(func) if they want to retrieve the address. +#define DEFINE_LUA_FUNCTION(name, argstring) \ + static int name(lua_State* L); \ + static const char* name##_args = s_cFuncInfoMap[name] = argstring; \ + static int name(lua_State* L) + +#ifdef _MSC_VER + #define snprintf _snprintf + #define vscprintf _vscprintf +#else + #define stricmp strcasecmp + #define strnicmp strncasecmp + #define __forceinline __attribute__((always_inline)) +#endif + + +static const char* luaCallIDStrings [] = +{ + "CALL_BEFOREEMULATION", + "CALL_AFTEREMULATION", + "CALL_AFTEREMULATIONGUI", + "CALL_BEFOREEXIT", + "CALL_BEFORESAVE", + "CALL_AFTERLOAD", + "CALL_ONSTART", + + "CALL_HOTKEY_1", + "CALL_HOTKEY_2", + "CALL_HOTKEY_3", + "CALL_HOTKEY_4", + "CALL_HOTKEY_5", + "CALL_HOTKEY_6", + "CALL_HOTKEY_7", + "CALL_HOTKEY_8", + "CALL_HOTKEY_9", + "CALL_HOTKEY_10", + "CALL_HOTKEY_11", + "CALL_HOTKEY_12", + "CALL_HOTKEY_13", + "CALL_HOTKEY_14", + "CALL_HOTKEY_15", + "CALL_HOTKEY_16", +}; +static const int _makeSureWeHaveTheRightNumberOfStrings [sizeof(luaCallIDStrings)/sizeof(*luaCallIDStrings) == LUACALL_COUNT ? 1 : 0]; + +static const char* luaMemHookTypeStrings [] = +{ + "MEMHOOK_WRITE", + "MEMHOOK_READ", + "MEMHOOK_EXEC", + + "MEMHOOK_WRITE_SUB", + "MEMHOOK_READ_SUB", + "MEMHOOK_EXEC_SUB", +}; +static const int _makeSureWeHaveTheRightNumberOfStrings2 [sizeof(luaMemHookTypeStrings)/sizeof(*luaMemHookTypeStrings) == LUAMEMHOOK_COUNT ? 1 : 0]; + +void StopScriptIfFinished(int uid, bool justReturned = false); +void SetSaveKey(LuaContextInfo& info, const char* key); +void SetLoadKey(LuaContextInfo& info, const char* key); +void RefreshScriptStartedStatus(); +void RefreshScriptSpeedStatus(); + +static char* rawToCString(lua_State* L, int idx=0); +static const char* toCString(lua_State* L, int idx=0); + +static void CalculateMemHookRegions(LuaMemHookType hookType); + +static int memory_registerHook(lua_State* L, LuaMemHookType hookType, int defaultSize) +{ + // get first argument: address + unsigned int addr = luaL_checkinteger(L,1); + if((addr & ~0xFFFFFF) == ~0xFFFFFF) + addr &= 0xFFFFFF; + + // get optional second argument: size + int size = defaultSize; + int funcIdx = 2; + if(lua_isnumber(L,2)) + { + size = luaL_checkinteger(L,2); + if(size < 0) + { + size = -size; + addr -= size; + } + funcIdx++; + } + + // check last argument: callback function + bool clearing = lua_isnil(L,funcIdx); + if(!clearing) + luaL_checktype(L, funcIdx, LUA_TFUNCTION); + lua_settop(L,funcIdx); + + // get the address-to-callback table for this hook type of the current script + lua_getfield(L, LUA_REGISTRYINDEX, luaMemHookTypeStrings[hookType]); + + // count how many callback functions we'll be displacing + int numFuncsAfter = clearing ? 0 : size; + int numFuncsBefore = 0; + for(unsigned int i = addr; i != addr+size; i++) + { + lua_rawgeti(L, -1, i); + if(lua_isfunction(L, -1)) + numFuncsBefore++; + lua_pop(L,1); + } + + // put the callback function in the address slots + for(unsigned int i = addr; i != addr+size; i++) + { + lua_pushvalue(L, -2); + lua_rawseti(L, -2, i); + } + + // adjust the count of active hooks + LuaContextInfo& info = GetCurrentInfo(); + info.numMemHooks += numFuncsAfter - numFuncsBefore; + + // re-cache regions of hooked memory across all scripts + CalculateMemHookRegions(hookType); + + StopScriptIfFinished(luaStateToUIDMap[L]); + return 0; +} + +LuaMemHookType MatchHookTypeToCPU(lua_State* L, LuaMemHookType hookType) +{ + int cpuID = 0; + + int cpunameIndex = 0; + if(lua_type(L,2) == LUA_TSTRING) + cpunameIndex = 2; + else if(lua_type(L,3) == LUA_TSTRING) + cpunameIndex = 3; + + if(cpunameIndex) + { + const char* cpuName = lua_tostring(L, cpunameIndex); + if(!stricmp(cpuName, "sub") || !stricmp(cpuName, "s68k")) + cpuID = 1; + lua_remove(L, cpunameIndex); + } + + switch(cpuID) + { + case 0: // m68k: + return hookType; + + case 1: // s68k: + switch(hookType) + { + case LUAMEMHOOK_WRITE: return LUAMEMHOOK_WRITE_SUB; + case LUAMEMHOOK_READ: return LUAMEMHOOK_READ_SUB; + case LUAMEMHOOK_EXEC: return LUAMEMHOOK_EXEC_SUB; + } + } + return hookType; +} + +DEFINE_LUA_FUNCTION(memory_registerwrite, "address,[size=1,][cpuname=\"main\",]func") +{ + return memory_registerHook(L, MatchHookTypeToCPU(L,LUAMEMHOOK_WRITE), 1); +} +DEFINE_LUA_FUNCTION(memory_registerread, "address,[size=1,][cpuname=\"main\",]func") +{ + return memory_registerHook(L, MatchHookTypeToCPU(L,LUAMEMHOOK_READ), 1); +} +DEFINE_LUA_FUNCTION(memory_registerexec, "address,[size=2,][cpuname=\"main\",]func") +{ + return memory_registerHook(L, MatchHookTypeToCPU(L,LUAMEMHOOK_EXEC), 2); +} + + +DEFINE_LUA_FUNCTION(emu_registerbefore, "func") +{ + if (!lua_isnil(L,1)) + luaL_checktype(L, 1, LUA_TFUNCTION); + lua_settop(L,1); + lua_getfield(L, LUA_REGISTRYINDEX, luaCallIDStrings[LUACALL_BEFOREEMULATION]); + lua_insert(L,1); + lua_setfield(L, LUA_REGISTRYINDEX, luaCallIDStrings[LUACALL_BEFOREEMULATION]); + StopScriptIfFinished(luaStateToUIDMap[L]); + return 1; +} +DEFINE_LUA_FUNCTION(emu_registerafter, "func") +{ + if (!lua_isnil(L,1)) + luaL_checktype(L, 1, LUA_TFUNCTION); + lua_settop(L,1); + lua_getfield(L, LUA_REGISTRYINDEX, luaCallIDStrings[LUACALL_AFTEREMULATION]); + lua_insert(L,1); + lua_setfield(L, LUA_REGISTRYINDEX, luaCallIDStrings[LUACALL_AFTEREMULATION]); + StopScriptIfFinished(luaStateToUIDMap[L]); + return 1; +} +DEFINE_LUA_FUNCTION(emu_registerexit, "func") +{ + if (!lua_isnil(L,1)) + luaL_checktype(L, 1, LUA_TFUNCTION); + lua_settop(L,1); + lua_getfield(L, LUA_REGISTRYINDEX, luaCallIDStrings[LUACALL_BEFOREEXIT]); + lua_insert(L,1); + lua_setfield(L, LUA_REGISTRYINDEX, luaCallIDStrings[LUACALL_BEFOREEXIT]); + StopScriptIfFinished(luaStateToUIDMap[L]); + return 1; +}/* +DEFINE_LUA_FUNCTION(emu_registerstart, "func") +{ + if (!lua_isnil(L,1)) + luaL_checktype(L, 1, LUA_TFUNCTION); + lua_settop(L,1); + lua_getfield(L, LUA_REGISTRYINDEX, luaCallIDStrings[LUACALL_ONSTART]); + lua_insert(L,1); + lua_pushvalue(L,-1); // copy the function so we can also call it + lua_setfield(L, LUA_REGISTRYINDEX, luaCallIDStrings[LUACALL_ONSTART]); + if (!lua_isnil(L,-1) && ((Genesis_Started)||(SegaCD_Started)||(_32X_Started))) + lua_call(L,0,0); // call the function now since the game has already started and this start function hasn't been called yet + StopScriptIfFinished(luaStateToUIDMap[L]); + return 1; +}*/ +DEFINE_LUA_FUNCTION(gui_register, "func") +{ + if (!lua_isnil(L,1)) + luaL_checktype(L, 1, LUA_TFUNCTION); + lua_settop(L,1); + lua_getfield(L, LUA_REGISTRYINDEX, luaCallIDStrings[LUACALL_AFTEREMULATIONGUI]); + lua_insert(L,1); + lua_setfield(L, LUA_REGISTRYINDEX, luaCallIDStrings[LUACALL_AFTEREMULATIONGUI]); + StopScriptIfFinished(luaStateToUIDMap[L]); + return 1; +} +DEFINE_LUA_FUNCTION(state_registersave, "func[,savekey]") +{ + if (!lua_isnil(L,1)) + luaL_checktype(L, 1, LUA_TFUNCTION); + if (!lua_isnoneornil(L,2)) + SetSaveKey(GetCurrentInfo(), rawToCString(L,2)); + lua_settop(L,1); + lua_getfield(L, LUA_REGISTRYINDEX, luaCallIDStrings[LUACALL_BEFORESAVE]); + lua_insert(L,1); + lua_setfield(L, LUA_REGISTRYINDEX, luaCallIDStrings[LUACALL_BEFORESAVE]); + StopScriptIfFinished(luaStateToUIDMap[L]); + return 1; +} +DEFINE_LUA_FUNCTION(state_registerload, "func[,loadkey]") +{ + if (!lua_isnil(L,1)) + luaL_checktype(L, 1, LUA_TFUNCTION); + if (!lua_isnoneornil(L,2)) + SetLoadKey(GetCurrentInfo(), rawToCString(L,2)); + lua_settop(L,1); + lua_getfield(L, LUA_REGISTRYINDEX, luaCallIDStrings[LUACALL_AFTERLOAD]); + lua_insert(L,1); + lua_setfield(L, LUA_REGISTRYINDEX, luaCallIDStrings[LUACALL_AFTERLOAD]); + StopScriptIfFinished(luaStateToUIDMap[L]); + return 1; +} + +DEFINE_LUA_FUNCTION(input_registerhotkey, "keynum,func") +{ + int hotkeyNumber = luaL_checkinteger(L,1); + if(hotkeyNumber < 1 || hotkeyNumber > 16) + { + luaL_error(L, "input.registerhotkey(n,func) requires 1 <= n <= 16, but got n = %d.", hotkeyNumber); + return 0; + } + else + { + const char* key = luaCallIDStrings[LUACALL_SCRIPT_HOTKEY_1 + hotkeyNumber-1]; + lua_getfield(L, LUA_REGISTRYINDEX, key); + lua_replace(L,1); + if (!lua_isnil(L,2)) + luaL_checktype(L, 2, LUA_TFUNCTION); + lua_settop(L,2); + lua_setfield(L, LUA_REGISTRYINDEX, key); + StopScriptIfFinished(luaStateToUIDMap[L]); + return 1; + } +} + +static int doPopup(lua_State* L, const char* deftype, const char* deficon) +{ + const char* str = toCString(L,1); + const char* type = lua_type(L,2) == LUA_TSTRING ? lua_tostring(L,2) : deftype; + const char* icon = lua_type(L,3) == LUA_TSTRING ? lua_tostring(L,3) : deficon; + + int itype = -1, iters = 0; + while(itype == -1 && iters++ < 2) + { + if(!stricmp(type, "ok")) itype = 0; + else if(!stricmp(type, "yesno")) itype = 1; + else if(!stricmp(type, "yesnocancel")) itype = 2; + else if(!stricmp(type, "okcancel")) itype = 3; + else if(!stricmp(type, "abortretryignore")) itype = 4; + else type = deftype; + } + assert(itype >= 0 && itype <= 4); + if(!(itype >= 0 && itype <= 4)) itype = 0; + + int iicon = -1; iters = 0; + while(iicon == -1 && iters++ < 2) + { + if(!stricmp(icon, "message") || !stricmp(icon, "notice")) iicon = 0; + else if(!stricmp(icon, "question")) iicon = 1; + else if(!stricmp(icon, "warning")) iicon = 2; + else if(!stricmp(icon, "error")) iicon = 3; + else icon = deficon; + } + assert(iicon >= 0 && iicon <= 3); + if(!(iicon >= 0 && iicon <= 3)) iicon = 0; + + static const char * const titles [] = {"Notice", "Question", "Warning", "Error"}; + const char* answer = "ok"; +#ifdef _WIN32 + static const int etypes [] = {MB_OK, MB_YESNO, MB_YESNOCANCEL, MB_OKCANCEL, MB_ABORTRETRYIGNORE}; + static const int eicons [] = {MB_ICONINFORMATION, MB_ICONQUESTION, MB_ICONWARNING, MB_ICONERROR}; +// DialogsOpen++; + int uid = luaStateToUIDMap[L]; + EnableWindow(MainWindow->getHWnd(), false); +// if (Full_Screen) +// { +// while (ShowCursor(false) >= 0); +// while (ShowCursor(true) < 0); +// } + int ianswer = MessageBox((HWND)uid, str, titles[iicon], etypes[itype] | eicons[iicon]); + EnableWindow(MainWindow->getHWnd(), true); +// DialogsOpen--; + switch(ianswer) + { + case IDOK: answer = "ok"; break; + case IDCANCEL: answer = "cancel"; break; + case IDABORT: answer = "abort"; break; + case IDRETRY: answer = "retry"; break; + case IDIGNORE: answer = "ignore"; break; + case IDYES: answer = "yes"; break; + case IDNO: answer = "no"; break; + } +#else + // NYI (assume first answer for now) + switch(itype) + { + case 0: case 3: answer = "ok"; break; + case 1: case 2: answer = "yes"; break; + case 4: answer = "abort"; break; + } +#endif + + lua_pushstring(L, answer); + return 1; +} + +// string gui.popup(string message, string type = "ok", string icon = "message") +// string input.popup(string message, string type = "yesno", string icon = "question") +DEFINE_LUA_FUNCTION(gui_popup, "message[,type=\"ok\"[,icon=\"message\"]]") +{ + return doPopup(L, "ok", "message"); +} +DEFINE_LUA_FUNCTION(input_popup, "message[,type=\"yesno\"[,icon=\"question\"]]") +{ + return doPopup(L, "yesno", "question"); +} + +static const char* FilenameFromPath(const char* path) +{ + const char* slash1 = strrchr(path, '\\'); + const char* slash2 = strrchr(path, '/'); + if(slash1) slash1++; + if(slash2) slash2++; + const char* rv = path; + rv = std::max(rv, slash1); + rv = std::max(rv, slash2); + if(!rv) rv = ""; + return rv; +} + + +static void toCStringConverter(lua_State* L, int i, char*& ptr, int& remaining); + +// compare the contents of two items on the Lua stack to determine if they differ +// only works for relatively simple, saveable items (numbers, strings, bools, nil, and possibly-nested tables of those, up to a certain max length) +// not the best implementation, but good enough for what it's currently used for +static bool luaValueContentsDiffer(lua_State* L, int idx1, int idx2) +{ + static const int maxLen = 8192; + static char str1[maxLen]; + static char str2[maxLen]; + str1[0] = 0; + str2[0] = 0; + char* ptr1 = str1; + char* ptr2 = str2; + int remaining1 = maxLen; + int remaining2 = maxLen; + toCStringConverter(L, idx1, ptr1, remaining1); + toCStringConverter(L, idx2, ptr2, remaining2); + return (remaining1 != remaining2) || (strcmp(str1,str2) != 0); +} + + +// fills output with the path +// also returns a pointer to the first character in the filename (non-directory) part of the path +static char* ConstructScriptSaveDataPath(char* output, int bufferSize, LuaContextInfo& info) +{ +// Get_State_File_Name(output); TODO + char* slash1 = strrchr(output, '\\'); + char* slash2 = strrchr(output, '/'); + if(slash1) slash1[1] = '\0'; + if(slash2) slash2[1] = '\0'; + char* rv = output + strlen(output); + strncat(output, "u.", bufferSize-(strlen(output)+1)); + if(!info.dataSaveLoadKeySet) + strncat(output, FilenameFromPath(info.lastFilename.c_str()), bufferSize-(strlen(output)+1)); + else + snprintf(output+strlen(output), bufferSize-(strlen(output)+1), "%X", info.dataSaveKey); + strncat(output, ".luasav", bufferSize-(strlen(output)+1)); + return rv; +} + +// gens.persistglobalvariables({ +// variable1 = defaultvalue1, +// variable2 = defaultvalue2, +// etc +// }) +// takes a table with variable names as the keys and default values as the values, +// and defines each of those variables names as a global variable, +// setting them equal to the values they had the last time the script exited, +// or (if that isn't available) setting them equal to the provided default values. +// as a special case, if you want the default value for a variable to be nil, +// then put the variable name alone in quotes as an entry in the table without saying "= nil". +// this special case is because tables in lua don't store nil valued entries. +// also, if you change the default value that will reset the variable to the new default. +DEFINE_LUA_FUNCTION(emu_persistglobalvariables, "variabletable") +{ + int uid = luaStateToUIDMap[L]; + LuaContextInfo& info = GetCurrentInfo(); + + // construct a path we can load the persistent variables from + char path [1024] = {0}; + char* pathTypeChrPtr = ConstructScriptSaveDataPath(path, 1024, info); + + // load the previously-saved final variable values from file + LuaSaveData exitData; + { + *pathTypeChrPtr = 'e'; + FILE* persistFile = fopen(path, "rb"); + if(persistFile) + { + exitData.ImportRecords(persistFile); + fclose(persistFile); + } + } + + // load the previously-saved default variable values from file + LuaSaveData defaultData; + { + *pathTypeChrPtr = 'd'; + FILE* defaultsFile = fopen(path, "rb"); + if(defaultsFile) + { + defaultData.ImportRecords(defaultsFile); + fclose(defaultsFile); + } + } + + // loop through the passed-in variables, + // exposing a global variable to the script for each one + // while also keeping a record of their names + // so we can save them (to the persistFile) later when the script exits + int numTables = lua_gettop(L); + for(int i = 1; i <= numTables; i++) + { + luaL_checktype(L, i, LUA_TTABLE); + + lua_pushnil(L); // before first key + int keyIndex = lua_gettop(L); + int valueIndex = keyIndex + 1; + while(lua_next(L, i)) + { + int keyType = lua_type(L, keyIndex); + int valueType = lua_type(L, valueIndex); + if(keyType == LUA_TSTRING && valueType <= LUA_TTABLE && valueType != LUA_TLIGHTUSERDATA) + { + // variablename = defaultvalue, + + // duplicate the key first because lua_next() needs to eat that + lua_pushvalue(L, keyIndex); + lua_insert(L, keyIndex); + } + else if(keyType == LUA_TNUMBER && valueType == LUA_TSTRING) + { + // "variablename", + // or [index] = "variablename", + + // defaultvalue is assumed to be nil + lua_pushnil(L); + } + else + { + luaL_error(L, "'%s' = '%s' entries are not allowed in the table passed to gens.persistglobalvariables()", lua_typename(L,keyType), lua_typename(L,valueType)); + } + + int varNameIndex = valueIndex; + int defaultIndex = valueIndex+1; + + // keep track of the variable name for later + const char* varName = lua_tostring(L, varNameIndex); + info.persistVars.push_back(varName); + unsigned int varNameCRC = crc32(0, (const unsigned char*)varName, strlen(varName)); + info.newDefaultData.SaveRecordPartial(uid, varNameCRC, defaultIndex); + + // load the previous default value for this variable if it exists. + // if the new default is different than the old one, + // assume the user wants to set the value to the new default value + // instead of the previously-saved exit value. + bool attemptPersist = true; + defaultData.LoadRecord(uid, varNameCRC, 1); + lua_pushnil(L); + if(luaValueContentsDiffer(L, defaultIndex, defaultIndex+1)) + attemptPersist = false; + lua_settop(L, defaultIndex); + + if(attemptPersist) + { + // load the previous saved value for this variable if it exists + exitData.LoadRecord(uid, varNameCRC, 1); + if(lua_gettop(L) > defaultIndex) + lua_remove(L, defaultIndex); // replace value with loaded record + lua_settop(L, defaultIndex); + } + + // set the global variable + lua_settable(L, LUA_GLOBALSINDEX); + + assert(lua_gettop(L) == keyIndex); + } + } + + return 0; +} + +static const char* deferredGUIIDString = "lazygui"; + +// store the most recent C function call from Lua (and all its arguments) +// for later evaluation +void DeferFunctionCall(lua_State* L, const char* idstring) +{ + // there might be a cleaner way of doing this using lua_pushcclosure and lua_getref + + int num = lua_gettop(L); + + // get the C function pointer + //lua_CFunction cf = lua_tocfunction(L, -(num+1)); + lua_CFunction cf = (L->ci->func)->value.gc->cl.c.f; + assert(cf); + lua_pushcfunction(L,cf); + + // make a list of the function and its arguments (and also pop those arguments from the stack) + lua_createtable(L, num+1, 0); + lua_insert(L, 1); + for(int n = num+1; n > 0; n--) + lua_rawseti(L, 1, n); + + // put the list into a global array + lua_getfield(L, LUA_REGISTRYINDEX, idstring); + lua_insert(L, 1); + int curSize = lua_objlen(L, 1); + lua_rawseti(L, 1, curSize+1); + + // clean the stack + lua_settop(L, 0); +} +void CallDeferredFunctions(lua_State* L, const char* idstring) +{ + lua_settop(L, 0); + lua_getfield(L, LUA_REGISTRYINDEX, idstring); + int numCalls = lua_objlen(L, 1); + for(int i = 1; i <= numCalls; i++) + { + lua_rawgeti(L, 1, i); // get the function+arguments list + int listSize = lua_objlen(L, 2); + + // push the arguments and the function + for(int j = 1; j <= listSize; j++) + lua_rawgeti(L, 2, j); + + // get and pop the function + lua_CFunction cf = lua_tocfunction(L, -1); + lua_pop(L, 1); + + // shift first argument to slot 1 and call the function + lua_remove(L, 2); + lua_remove(L, 1); + cf(L); + + // prepare for next iteration + lua_settop(L, 0); + lua_getfield(L, LUA_REGISTRYINDEX, idstring); + } + + // clear the list of deferred functions + lua_newtable(L); + lua_setfield(L, LUA_REGISTRYINDEX, idstring); + LuaContextInfo& info = GetCurrentInfo(); + info.numDeferredGUIFuncs = 0; + + // clean the stack + lua_settop(L, 0); +} + +#define MAX_DEFERRED_COUNT 16384 + +bool DeferGUIFuncIfNeeded(lua_State* L) +{ + LuaContextInfo& info = GetCurrentInfo(); + if(info.speedMode == SPEEDMODE_MAXIMUM) + { + // if the mode is "maximum" then discard all GUI function calls + // and pretend it was because we deferred them + return true; + } + if(info.guiFuncsNeedDeferring) + { + if(info.numDeferredGUIFuncs < MAX_DEFERRED_COUNT) + { + // defer whatever function called this one until later + DeferFunctionCall(L, deferredGUIIDString); + info.numDeferredGUIFuncs++; + } + else + { + // too many deferred functions on the same frame + // silently discard the rest + } + return true; + } + + // ok to run the function right now + return false; +} + +void worry(lua_State* L, int intensity) +{ + LuaContextInfo& info = GetCurrentInfo(); + info.worryCount += intensity; +} + +static inline bool isalphaorunderscore(char c) +{ + return isalpha(c) || c == '_'; +} + +static std::vector s_tableAddressStack; // prevents infinite recursion of a table within a table (when cycle is found, print something like table:parent) +static std::vector s_metacallStack; // prevents infinite recursion if something's __tostring returns another table that contains that something (when cycle is found, print the inner result without using __tostring) + +#define APPENDPRINT { int _n = snprintf(ptr, remaining, +#define END ); if(_n >= 0) { ptr += _n; remaining -= _n; } else { remaining = 0; } } +static void toCStringConverter(lua_State* L, int i, char*& ptr, int& remaining) +{ + if(remaining <= 0) + return; + + const char* str = ptr; // for debugging + + // if there is a __tostring metamethod then call it + int usedMeta = luaL_callmeta(L, i, "__tostring"); + if(usedMeta) + { + std::vector::const_iterator foundCycleIter = std::find(s_metacallStack.begin(), s_metacallStack.end(), lua_topointer(L,i)); + if(foundCycleIter != s_metacallStack.end()) + { + lua_pop(L, 1); + usedMeta = false; + } + else + { + s_metacallStack.push_back(lua_topointer(L,i)); + i = lua_gettop(L); + } + } + + switch(lua_type(L, i)) + { + case LUA_TNONE: break; + case LUA_TNIL: APPENDPRINT "nil" END break; + case LUA_TBOOLEAN: APPENDPRINT lua_toboolean(L,i) ? "true" : "false" END break; + case LUA_TSTRING: APPENDPRINT "%s",lua_tostring(L,i) END break; + case LUA_TNUMBER: APPENDPRINT "%.12Lg",lua_tonumber(L,i) END break; + case LUA_TFUNCTION: + if((L->base + i-1)->value.gc->cl.c.isC) + { + lua_CFunction func = lua_tocfunction(L, i); + std::map::iterator iter = s_cFuncInfoMap.find(func); + if(iter == s_cFuncInfoMap.end()) + goto defcase; + APPENDPRINT "function(%s)", iter->second END + } + else + { + APPENDPRINT "function(" END + Proto* p = (L->base + i-1)->value.gc->cl.l.p; + int numParams = p->numparams + (p->is_vararg?1:0); + for (int n=0; nnumparams; n++) + { + APPENDPRINT "%s", getstr(p->locvars[n].varname) END + if(n != numParams-1) + APPENDPRINT "," END + } + if(p->is_vararg) + APPENDPRINT "..." END + APPENDPRINT ")" END + } + break; +defcase:default: APPENDPRINT "%s:%p",luaL_typename(L,i),lua_topointer(L,i) END break; + case LUA_TTABLE: + { + // first make sure there's enough stack space + if(!lua_checkstack(L, 4)) + { + // note that even if lua_checkstack never returns false, + // that doesn't mean we didn't need to call it, + // because calling it retrieves stack space past LUA_MINSTACK + goto defcase; + } + + std::vector::const_iterator foundCycleIter = std::find(s_tableAddressStack.begin(), s_tableAddressStack.end(), lua_topointer(L,i)); + if(foundCycleIter != s_tableAddressStack.end()) + { + int parentNum = s_tableAddressStack.end() - foundCycleIter; + if(parentNum > 1) + APPENDPRINT "%s:parent^%d",luaL_typename(L,i),parentNum END + else + APPENDPRINT "%s:parent",luaL_typename(L,i) END + } + else + { + s_tableAddressStack.push_back(lua_topointer(L,i)); + struct Scope { ~Scope(){ s_tableAddressStack.pop_back(); } } scope; + + APPENDPRINT "{" END + + lua_pushnil(L); // first key + int keyIndex = lua_gettop(L); + int valueIndex = keyIndex + 1; + bool first = true; + bool skipKey = true; // true if we're still in the "array part" of the table + lua_Number arrayIndex = (lua_Number)0; + while(lua_next(L, i)) + { + if(first) + first = false; + else + APPENDPRINT ", " END + if(skipKey) + { + arrayIndex += (lua_Number)1; + bool keyIsNumber = (lua_type(L, keyIndex) == LUA_TNUMBER); + skipKey = keyIsNumber && (lua_tonumber(L, keyIndex) == arrayIndex); + } + if(!skipKey) + { + bool keyIsString = (lua_type(L, keyIndex) == LUA_TSTRING); + bool invalidLuaIdentifier = (!keyIsString || !isalphaorunderscore(*lua_tostring(L, keyIndex))); + if(invalidLuaIdentifier) + if(keyIsString) + APPENDPRINT "['" END + else + APPENDPRINT "[" END + + toCStringConverter(L, keyIndex, ptr, remaining); // key + + if(invalidLuaIdentifier) + if(keyIsString) + APPENDPRINT "']=" END + else + APPENDPRINT "]=" END + else + APPENDPRINT "=" END + } + + bool valueIsString = (lua_type(L, valueIndex) == LUA_TSTRING); + if(valueIsString) + APPENDPRINT "'" END + + toCStringConverter(L, valueIndex, ptr, remaining); // value + + if(valueIsString) + APPENDPRINT "'" END + + lua_pop(L, 1); + + if(remaining <= 0) + { + lua_settop(L, keyIndex-1); // stack might not be clean yet if we're breaking early + break; + } + } + APPENDPRINT "}" END + } + } break; + } + + if(usedMeta) + { + s_metacallStack.pop_back(); + lua_pop(L, 1); + } +} + +static const int s_tempStrMaxLen = 64 * 1024; +static char s_tempStr [s_tempStrMaxLen]; + +static char* rawToCString(lua_State* L, int idx) +{ + int a = idx>0 ? idx : 1; + int n = idx>0 ? idx : lua_gettop(L); + + char* ptr = s_tempStr; + *ptr = 0; + + int remaining = s_tempStrMaxLen; + for(int i = a; i <= n; i++) + { + toCStringConverter(L, i, ptr, remaining); + if(i != n) + APPENDPRINT " " END + } + + if(remaining < 3) + { + while(remaining < 6) + remaining++, ptr--; + APPENDPRINT "..." END + } + APPENDPRINT "\r\n" END + // the trailing newline is so print() can avoid having to do wasteful things to print its newline + // (string copying would be wasteful and calling info.print() twice can be extremely slow) + // at the cost of functions that don't want the newline needing to trim off the last two characters + // (which is a very fast operation and thus acceptable in this case) + + return s_tempStr; +} +#undef APPENDPRINT +#undef END + + +// replacement for luaB_tostring() that is able to show the contents of tables (and formats numbers better, and show function prototypes) +// can be called directly from lua via tostring(), assuming tostring hasn't been reassigned +DEFINE_LUA_FUNCTION(tostring, "...") +{ + char* str = rawToCString(L); + str[strlen(str)-2] = 0; // hack: trim off the \r\n (which is there to simplify the print function's task) + lua_pushstring(L, str); + return 1; +} + +// like rawToCString, but will check if the global Lua function tostring() +// has been replaced with a custom function, and call that instead if so +static const char* toCString(lua_State* L, int idx) +{ + int a = idx>0 ? idx : 1; + int n = idx>0 ? idx : lua_gettop(L); + lua_getglobal(L, "tostring"); + lua_CFunction cf = lua_tocfunction(L,-1); + if(cf == tostring) // optimization: if using our own C tostring function, we can bypass the call through Lua and all the string object allocation that would entail + { + lua_pop(L,1); + return rawToCString(L, idx); + } + else // if the user overrided the tostring function, we have to actually call it and store the temporarily allocated string it returns + { + lua_pushstring(L, ""); + for (int i=a; i<=n; i++) { + lua_pushvalue(L, -2); // function to be called + lua_pushvalue(L, i); // value to print + lua_call(L, 1, 1); + if(lua_tostring(L, -1) == NULL) + luaL_error(L, LUA_QL("tostring") " must return a string to " LUA_QL("print")); + lua_pushstring(L, (iUSR_InfoMessage(str); + return 0; +} + +// provides an easy way to copy a table from Lua +// (simple assignment only makes an alias, but sometimes an independent table is desired) +// currently this function only performs a shallow copy, +// but I think it should be changed to do a deep copy (possibly of configurable depth?) +// that maintains the internal table reference structure +DEFINE_LUA_FUNCTION(copytable, "origtable") +{ + int origIndex = 1; // we only care about the first argument + int origType = lua_type(L, origIndex); + if(origType == LUA_TNIL) + { + lua_pushnil(L); + return 1; + } + if(origType != LUA_TTABLE) + { + luaL_typerror(L, 1, lua_typename(L, LUA_TTABLE)); + lua_pushnil(L); + return 1; + } + + lua_createtable(L, lua_objlen(L,1), 0); + int copyIndex = lua_gettop(L); + + lua_pushnil(L); // first key + int keyIndex = lua_gettop(L); + int valueIndex = keyIndex + 1; + + while(lua_next(L, origIndex)) + { + lua_pushvalue(L, keyIndex); + lua_pushvalue(L, valueIndex); + lua_rawset(L, copyIndex); // copytable[key] = value + lua_pop(L, 1); + } + + // copy the reference to the metatable as well, if any + if(lua_getmetatable(L, origIndex)) + lua_setmetatable(L, copyIndex); + + return 1; // return the new table +} + +// because print traditionally shows the address of tables, +// and the print function I provide instead shows the contents of tables, +// I also provide this function +// (otherwise there would be no way to see a table's address, AFAICT) +DEFINE_LUA_FUNCTION(addressof, "table_or_function") +{ + const void* ptr = lua_topointer(L,-1); + lua_pushinteger(L, (lua_Integer)ptr); + return 1; +} + +DEFINE_LUA_FUNCTION(bitand, "...[integers]") +{ + int rv = ~0; + int numArgs = lua_gettop(L); + for(int i = 1; i <= numArgs; i++) + rv &= luaL_checkinteger(L,i); + lua_settop(L,0); + lua_pushinteger(L,rv); + return 1; +} +DEFINE_LUA_FUNCTION(bitor, "...[integers]") +{ + int rv = 0; + int numArgs = lua_gettop(L); + for(int i = 1; i <= numArgs; i++) + rv |= luaL_checkinteger(L,i); + lua_settop(L,0); + lua_pushinteger(L,rv); + return 1; +} +DEFINE_LUA_FUNCTION(bitxor, "...[integers]") +{ + int rv = 0; + int numArgs = lua_gettop(L); + for(int i = 1; i <= numArgs; i++) + rv ^= luaL_checkinteger(L,i); + lua_settop(L,0); + lua_pushinteger(L,rv); + return 1; +} +DEFINE_LUA_FUNCTION(bitshift, "num,shift") +{ + int num = luaL_checkinteger(L,1); + int shift = luaL_checkinteger(L,2); + if(shift < 0) + num <<= -shift; + else + num >>= shift; + lua_settop(L,0); + lua_pushinteger(L,num); + return 1; +} +DEFINE_LUA_FUNCTION(bitbit, "whichbit") +{ + int rv = 0; + int numArgs = lua_gettop(L); + for(int i = 1; i <= numArgs; i++) + rv |= (1 << luaL_checkinteger(L,i)); + lua_settop(L,0); + lua_pushinteger(L,rv); + return 1; +} + +//int gens_wait(lua_State* L); + +void indicateBusy(lua_State* L, bool busy) +{ + // disabled because there have been complaints about this message being useless spam. + // the script window's title changing should be sufficient, I guess. +/* if(busy) + { + const char* fmt = "script became busy (frozen?)"; + va_list argp; + va_start(argp, fmt); + luaL_where(L, 0); + lua_pushvfstring(L, fmt, argp); + va_end(argp); + lua_concat(L, 2); + LuaContextInfo& info = GetCurrentInfo(); + int uid = luaStateToUIDMap[L]; + if(info.print) + { + info.print(uid, lua_tostring(L,-1)); + info.print(uid, "\r\n"); + } + else + { + fprintf(stderr, "%s\n", lua_tostring(L,-1)); + } + lua_pop(L, 1); + } +*/ +#ifdef _WIN32 + int uid = luaStateToUIDMap[L]; + HWND hDlg = (HWND)uid; + char str [1024]; + GetWindowText(hDlg, str, 1000); + char* extra = strchr(str, '<'); + if(busy) + { + if(!extra) + extra = str + strlen(str), *extra++ = ' '; + strcpy(extra, ""); + } + else + { + if(extra) + extra[-1] = 0; + } + SetWindowText(hDlg, str); +#endif +} + +#define HOOKCOUNT 4096 +#define MAX_WORRY_COUNT 6000 +void LuaRescueHook(lua_State* L, lua_Debug *dbg) +{ + LuaContextInfo& info = GetCurrentInfo(); + + info.worryCount++; + + if(info.stopWorrying && !info.panic) + { + if(info.worryCount > (MAX_WORRY_COUNT >> 2)) + { + // the user already said they're OK with the script being frozen, + // but we don't trust their judgement completely, + // so periodically update the main loop so they have a chance to manually stop it + info.worryCount = 0; +// gens_wait(L); + info.stopWorrying = true; + } + return; + } + + if(info.worryCount > MAX_WORRY_COUNT || info.panic) + { + info.worryCount = 0; + info.stopWorrying = false; + + bool stoprunning = true; + bool stopworrying = true; + if(!info.panic) + { +// Clear_Sound_Buffer(); +#if defined(ASK_USER_ON_FREEZE) && defined(_WIN32) + DialogsOpen++; + int answer = MessageBox(HWnd, "A Lua script has been running for quite a while. Maybe it is in an infinite loop.\n\nWould you like to stop the script?\n\n(Yes to stop it now,\n No to keep running and not ask again,\n Cancel to keep running but ask again later)", "Lua Alert", MB_YESNOCANCEL | MB_DEFBUTTON3 | MB_ICONASTERISK); + DialogsOpen--; + if(answer == IDNO) + stoprunning = false; + if(answer == IDCANCEL) + stopworrying = false; +#else + stoprunning = false; +#endif + } + + if(!stoprunning && stopworrying) + { + info.stopWorrying = true; // don't remove the hook because we need it still running for RequestAbortLuaScript to work + indicateBusy(info.L, true); + } + + if(stoprunning) + { + //lua_sethook(L, NULL, 0, 0); + assert(L->errfunc || L->errorJmp); + luaL_error(L, info.panic ? info.panicMessage : "terminated by user"); + } + + info.panic = false; + } +} + +void printfToOutput(const char* fmt, ...) +{ + va_list list; + va_start(list, fmt); + int len = vscprintf(fmt, list); + char* str = new char[len+1]; + vsprintf(str, fmt, list); + va_end(list); + LuaContextInfo& info = GetCurrentInfo(); + if(info.print) + { + lua_State* L = info.L; + int uid = luaStateToUIDMap[L]; + info.print(uid, str); + info.print(uid, "\r\n"); + worry(L,300); + } + else + { + fprintf(stdout, "%s\n", str); + } + delete[] str; +} + +bool FailVerifyAtFrameBoundary(lua_State* L, const char* funcName, int unstartedSeverity=2, int inframeSeverity=2) +{//TODO +/* if (!((Genesis_Started)||(SegaCD_Started)||(_32X_Started))) + { + static const char* msg = "cannot call %s() when emulation has not started."; + switch(unstartedSeverity) + { + case 0: break; + case 1: printfToOutput(msg, funcName); break; + default: case 2: luaL_error(L, msg, funcName); break; + } + return true; + } + if(Inside_Frame) + { + static const char* msg = "cannot call %s() inside an emulation frame."; + switch(inframeSeverity) + { + case 0: break; + case 1: printfToOutput(msg, funcName); break; + default: case 2: luaL_error(L, msg, funcName); break; + } + return true; + }*/ + return false; +} +/* +// acts similar to normal emulation update +// except without the user being able to activate emulator commands +DEFINE_LUA_FUNCTION(gens_emulateframe, "") +{ + if(FailVerifyAtFrameBoundary(L, "gens.emulateframe", 0,1)) + return 0; + + Update_Emulation_One(HWnd); + Prevent_Next_Frame_Skipping(); // so we don't skip a whole bunch of frames immediately after emulating many frames by this method + + worry(L,300); + return 0; +} + +// acts as a fast-forward emulation update that still renders every frame +// and the user is unable to activate emulator commands during it +DEFINE_LUA_FUNCTION(gens_emulateframefastnoskipping, "") +{ + if(FailVerifyAtFrameBoundary(L, "gens.emulateframefastnoskipping", 0,1)) + return 0; + + Update_Emulation_One_Before(HWnd); + Update_Frame_Hook(); + Update_Emulation_After_Controlled(HWnd, true); + Prevent_Next_Frame_Skipping(); // so we don't skip a whole bunch of frames immediately after a bout of fast-forward frames + + worry(L,200); + return 0; +} + +// acts as a (very) fast-forward emulation update +// where the user is unable to activate emulator commands +DEFINE_LUA_FUNCTION(gens_emulateframefast, "") +{ + if(FailVerifyAtFrameBoundary(L, "gens.emulateframefast", 0,1)) + return 0; + + disableVideoLatencyCompensationCount = VideoLatencyCompensation + 1; + + Update_Emulation_One_Before(HWnd); + + if(FrameCount%16 == 0) // skip rendering 15 out of 16 frames + { + // update once and render + Update_Frame_Hook(); + Update_Emulation_After_Controlled(HWnd, true); + } + else + { + // update once but skip rendering + Update_Frame_Fast_Hook(); + Update_Emulation_After_Controlled(HWnd, false); + } + + Prevent_Next_Frame_Skipping(); // so we don't skip a whole bunch of frames immediately AFTER a bout of fast-forward frames + + worry(L,150); + return 0; +} + +// acts as an extremely-fast-forward emulation update +// that also doesn't render any graphics or generate any sounds, +// and the user is unable to activate emulator commands during it. +// if you load a savestate after calling this function, +// it should leave no trace of having been called, +// so you can do things like generate future emulation states every frame +// while the user continues to see and hear normal emulation +DEFINE_LUA_FUNCTION(gens_emulateframeinvisible, "") +{ + if(FailVerifyAtFrameBoundary(L, "gens.emulateframeinvisible", 0,1)) + return 0; + + int oldDisableSound2 = disableSound2; + int oldDisableRamSearchUpdate = disableRamSearchUpdate; + disableSound2 = true; + disableRamSearchUpdate = true; + + Update_Emulation_One_Before_Minimal(); + Update_Frame_Fast(); + UpdateLagCount(); + + disableSound2 = oldDisableSound2; + disableRamSearchUpdate = oldDisableRamSearchUpdate; + + // disable video latency compensation for a few frames + // because it can get pretty slow if that's doing prediction updates every frame + // when the lua script is also doing prediction updates + disableVideoLatencyCompensationCount = VideoLatencyCompensation + 1; + + worry(L,100); + return 0; +} + +DEFINE_LUA_FUNCTION(gens_speedmode, "mode") +{ + SpeedMode newSpeedMode = SPEEDMODE_NORMAL; + if(lua_isnumber(L,1)) + newSpeedMode = (SpeedMode)luaL_checkinteger(L,1); + else + { + const char* str = luaL_checkstring(L,1); + if(!stricmp(str, "normal")) + newSpeedMode = SPEEDMODE_NORMAL; + else if(!stricmp(str, "nothrottle")) + newSpeedMode = SPEEDMODE_NOTHROTTLE; + else if(!stricmp(str, "turbo")) + newSpeedMode = SPEEDMODE_TURBO; + else if(!stricmp(str, "maximum")) + newSpeedMode = SPEEDMODE_MAXIMUM; + } + + LuaContextInfo& info = GetCurrentInfo(); + info.speedMode = newSpeedMode; + RefreshScriptSpeedStatus(); + return 0; +} + +// tells Gens to wait while the script is doing calculations +// can call this periodically instead of gens.frameadvance +// note that the user can use hotkeys at this time +// (e.g. a savestate could possibly get loaded before gens.wait() returns) +DEFINE_LUA_FUNCTION(gens_wait, "") +{ + LuaContextInfo& info = GetCurrentInfo(); + + switch(info.speedMode) + { + default: + case SPEEDMODE_NORMAL: + Step_Gens_MainLoop(true, false); + break; + case SPEEDMODE_NOTHROTTLE: + case SPEEDMODE_TURBO: + case SPEEDMODE_MAXIMUM: + Step_Gens_MainLoop(Paused!=0, false); + break; + } + + return 0; +} +*/ + + + +/* +DEFINE_LUA_FUNCTION(gens_frameadvance, "") +{ + if(FailVerifyAtFrameBoundary(L, "gens.frameadvance", 0,1)) + return gens_wait(L); + + int uid = luaStateToUIDMap[L]; + LuaContextInfo& info = GetCurrentInfo(); + + if(!info.ranFrameAdvance) + { + // otherwise we'll never see the first frame of GUI drawing + if(info.speedMode != SPEEDMODE_MAXIMUM) + Show_Genesis_Screen(); + info.ranFrameAdvance = true; + } + + switch(info.speedMode) + { + default: + case SPEEDMODE_NORMAL: + while(!Step_Gens_MainLoop(true, true) && !info.panic); + break; + case SPEEDMODE_NOTHROTTLE: + while(!Step_Gens_MainLoop(Paused!=0, false) && !info.panic); + if(!(FastForwardKeyDown && (GetActiveWindow()==HWnd || BackgroundInput))) + gens_emulateframefastnoskipping(L); + else + gens_emulateframefast(L); + break; + case SPEEDMODE_TURBO: + while(!Step_Gens_MainLoop(Paused!=0, false) && !info.panic); + gens_emulateframefast(L); + break; + case SPEEDMODE_MAXIMUM: + while(!Step_Gens_MainLoop(Paused!=0, false) && !info.panic); + gens_emulateframeinvisible(L); + break; + } + return 0; +} + +DEFINE_LUA_FUNCTION(gens_pause, "") +{ + LuaContextInfo& info = GetCurrentInfo(); + + Paused = 1; + while(!Step_Gens_MainLoop(true, false) && !info.panic); + + // allow the user to not have to manually unpause + // after restarting a script that used gens.pause() + if(info.panic) + Paused = 0; + + return 0; +} + +DEFINE_LUA_FUNCTION(gens_unpause, "") +{ + LuaContextInfo& info = GetCurrentInfo(); + + Paused = 0; + return 0; +} + +DEFINE_LUA_FUNCTION(gens_redraw, "") +{ + Show_Genesis_Screen(); + worry(L,250); + return 0; +} + +*/ + +DEFINE_LUA_FUNCTION(memory_readbyte, "address") +{ + int address = luaL_checkinteger(L,1); + unsigned char value = (unsigned char)(_MMU_read08(address) & 0xFF); + lua_settop(L,0); + lua_pushinteger(L, value); + return 1; // we return the number of return values +} +DEFINE_LUA_FUNCTION(memory_readbytesigned, "address") +{ + int address = luaL_checkinteger(L,1); + signed char value = (signed char)(_MMU_read08(address) & 0xFF); + lua_settop(L,0); + lua_pushinteger(L, value); + return 1; +} +DEFINE_LUA_FUNCTION(memory_readword, "address") +{ + int address = luaL_checkinteger(L,1); + unsigned short value = (unsigned short)(_MMU_read16(address) & 0xFFFF); + lua_settop(L,0); + lua_pushinteger(L, value); + return 1; +} +DEFINE_LUA_FUNCTION(memory_readwordsigned, "address") +{ + int address = luaL_checkinteger(L,1); + signed short value = (signed short)(_MMU_read16(address) & 0xFFFF); + lua_settop(L,0); + lua_pushinteger(L, value); + return 1; +} +DEFINE_LUA_FUNCTION(memory_readdword, "address") +{ + int address = luaL_checkinteger(L,1); + unsigned long value = (unsigned long)(_MMU_read32(address)); + lua_settop(L,0); + lua_pushinteger(L, value); + return 1; +} +DEFINE_LUA_FUNCTION(memory_readdwordsigned, "address") +{ + int address = luaL_checkinteger(L,1); + signed long value = (signed long)(_MMU_read32(address)); + lua_settop(L,0); + lua_pushinteger(L, value); + return 1; +} + +DEFINE_LUA_FUNCTION(memory_writebyte, "address,value") +{ + int address = luaL_checkinteger(L,1); + unsigned char value = (unsigned char)(luaL_checkinteger(L,2) & 0xFF); + _MMU_write08(address, value); + return 0; +} +DEFINE_LUA_FUNCTION(memory_writeword, "address,value") +{ + int address = luaL_checkinteger(L,1); + unsigned short value = (unsigned short)(luaL_checkinteger(L,2) & 0xFFFF); + _MMU_write16(address, value); + return 0; +} +DEFINE_LUA_FUNCTION(memory_writedword, "address,value") +{ + int address = luaL_checkinteger(L,1); + unsigned long value = (unsigned long)(luaL_checkinteger(L,2)); + _MMU_write32(address, value); + return 0; +} + +DEFINE_LUA_FUNCTION(memory_readbyterange, "address,length") +{ + int address = luaL_checkinteger(L,1); + int length = luaL_checkinteger(L,2); + + if(length < 0) + { + address += length; + length = -length; + } + + // push the array + lua_createtable(L, abs(length), 0); + + // put all the values into the (1-based) array + for(int a = address, n = 1; n <= length; a++, n++) + { +// if(IsHardwareAddressValid(a)) +// { + unsigned char value = (unsigned char)(_MMU_read08(address) & 0xFF); + lua_pushinteger(L, value); + lua_rawseti(L, -2, n); +// } + // else leave the value nil + } + + return 1; +} +/* +DEFINE_LUA_FUNCTION(memory_isvalid, "address") +{ + int address = luaL_checkinteger(L,1); + lua_settop(L,0); + lua_pushboolean(L, IsHardwareAddressValid(address)); + return 1; +} +*/ +struct registerPointerMap +{ + const char* registerName; + unsigned int* pointer; + int dataSize; +}; + +#define RPM_ENTRY(name,var) {name, (unsigned int*)&var, sizeof(var)}, + +registerPointerMap m68kPointerMap [] = { +/* RPM_ENTRY("a0", main68k_context.areg[0]) + RPM_ENTRY("a1", main68k_context.areg[1]) + RPM_ENTRY("a2", main68k_context.areg[2]) + RPM_ENTRY("a3", main68k_context.areg[3]) + RPM_ENTRY("a4", main68k_context.areg[4]) + RPM_ENTRY("a5", main68k_context.areg[5]) + RPM_ENTRY("a6", main68k_context.areg[6]) + RPM_ENTRY("a7", main68k_context.areg[7]) + RPM_ENTRY("d0", main68k_context.dreg[0]) + RPM_ENTRY("d1", main68k_context.dreg[1]) + RPM_ENTRY("d2", main68k_context.dreg[2]) + RPM_ENTRY("d3", main68k_context.dreg[3]) + RPM_ENTRY("d4", main68k_context.dreg[4]) + RPM_ENTRY("d5", main68k_context.dreg[5]) + RPM_ENTRY("d6", main68k_context.dreg[6]) + RPM_ENTRY("d7", main68k_context.dreg[7]) + RPM_ENTRY("pc", main68k_context.pc) + RPM_ENTRY("sr", main68k_context.sr)*/ + {} +}; +registerPointerMap s68kPointerMap [] = {/* + RPM_ENTRY("a0", sub68k_context.areg[0]) + RPM_ENTRY("a1", sub68k_context.areg[1]) + RPM_ENTRY("a2", sub68k_context.areg[2]) + RPM_ENTRY("a3", sub68k_context.areg[3]) + RPM_ENTRY("a4", sub68k_context.areg[4]) + RPM_ENTRY("a5", sub68k_context.areg[5]) + RPM_ENTRY("a6", sub68k_context.areg[6]) + RPM_ENTRY("a7", sub68k_context.areg[7]) + RPM_ENTRY("d0", sub68k_context.dreg[0]) + RPM_ENTRY("d1", sub68k_context.dreg[1]) + RPM_ENTRY("d2", sub68k_context.dreg[2]) + RPM_ENTRY("d3", sub68k_context.dreg[3]) + RPM_ENTRY("d4", sub68k_context.dreg[4]) + RPM_ENTRY("d5", sub68k_context.dreg[5]) + RPM_ENTRY("d6", sub68k_context.dreg[6]) + RPM_ENTRY("d7", sub68k_context.dreg[7]) + RPM_ENTRY("pc", sub68k_context.pc) + RPM_ENTRY("sr", sub68k_context.sr)*/ + {} +}; + +struct cpuToRegisterMap +{ + const char* cpuName; + registerPointerMap* rpmap; +} +cpuToRegisterMaps [] = +{ + {"m68k.", m68kPointerMap}, + {"main.", m68kPointerMap}, + {"s68k.", s68kPointerMap}, + {"sub.", s68kPointerMap}, + {"", m68kPointerMap}, +}; + + +DEFINE_LUA_FUNCTION(memory_getregister, "cpu_dot_registername_string") +{ + const char* qualifiedRegisterName = luaL_checkstring(L,1); + lua_settop(L,0); + for(int cpu = 0; cpu < sizeof(cpuToRegisterMaps)/sizeof(*cpuToRegisterMaps); cpu++) + { + cpuToRegisterMap ctrm = cpuToRegisterMaps[cpu]; + int cpuNameLen = strlen(ctrm.cpuName); + if(!strnicmp(qualifiedRegisterName, ctrm.cpuName, cpuNameLen)) + { + qualifiedRegisterName += cpuNameLen; + for(int reg = 0; ctrm.rpmap[reg].dataSize; reg++) + { + registerPointerMap rpm = ctrm.rpmap[reg]; + if(!stricmp(qualifiedRegisterName, rpm.registerName)) + { + switch(rpm.dataSize) + { default: + case 1: lua_pushinteger(L, *(unsigned char*)rpm.pointer); break; + case 2: lua_pushinteger(L, *(unsigned short*)rpm.pointer); break; + case 4: lua_pushinteger(L, *(unsigned long*)rpm.pointer); break; + } + return 1; + } + } + lua_pushnil(L); + return 1; + } + } + lua_pushnil(L); + return 1; +} +DEFINE_LUA_FUNCTION(memory_setregister, "cpu_dot_registername_string,value") +{ + const char* qualifiedRegisterName = luaL_checkstring(L,1); + unsigned long value = (unsigned long)(luaL_checkinteger(L,2)); + lua_settop(L,0); + for(int cpu = 0; cpu < sizeof(cpuToRegisterMaps)/sizeof(*cpuToRegisterMaps); cpu++) + { + cpuToRegisterMap ctrm = cpuToRegisterMaps[cpu]; + int cpuNameLen = strlen(ctrm.cpuName); + if(!strnicmp(qualifiedRegisterName, ctrm.cpuName, cpuNameLen)) + { + qualifiedRegisterName += cpuNameLen; + for(int reg = 0; ctrm.rpmap[reg].dataSize; reg++) + { + registerPointerMap rpm = ctrm.rpmap[reg]; + if(!stricmp(qualifiedRegisterName, rpm.registerName)) + { + switch(rpm.dataSize) + { default: + case 1: *(unsigned char*)rpm.pointer = (unsigned char)(value & 0xFF); break; + case 2: *(unsigned short*)rpm.pointer = (unsigned short)(value & 0xFFFF); break; + case 4: *(unsigned long*)rpm.pointer = value; break; + } + return 0; + } + } + return 0; + } + } + return 0; +} + +/* +DEFINE_LUA_FUNCTION(state_create, "[location]") +{ + if(lua_isnumber(L,1)) + { + // simply return the integer that got passed in + // (that's as good a savestate object as any for a numbered savestate slot) + lua_settop(L,1); + return 1; + } + + int len = GENESIS_STATE_LENGTH; + if (SegaCD_Started) len += SEGACD_LENGTH_EX; + if (_32X_Started) len += G32X_LENGTH_EX; + if (!((Genesis_Started)||(SegaCD_Started)||(_32X_Started))) + len += std::max(SEGACD_LENGTH_EX, G32X_LENGTH_EX); + + // allocate the in-memory/anonymous savestate + unsigned char* stateBuffer = (unsigned char*)lua_newuserdata(L, len + 16); // 16 is for performance alignment reasons + stateBuffer[0] = 0; + + return 1; +} + +// savestate.save(location [, option]) +// saves the current emulation state to the given location +// you can pass in either a savestate file number (an integer), +// OR you can pass in a savestate object that was returned by savestate.create() +// if option is "quiet" then any warning messages will be suppressed +// if option is "scriptdataonly" then the state will not actually be saved, but any save callbacks will still get called and their results will be saved (see savestate.registerload()/savestate.registersave()) +DEFINE_LUA_FUNCTION(state_save, "location[,option]") +{ + const char* option = (lua_type(L,2) == LUA_TSTRING) ? lua_tostring(L,2) : NULL; + if(option) + { + if(!stricmp(option, "quiet")) // I'm not sure if saving can generate warning messages, but we might as well support suppressing them should they turn out to exist + g_disableStatestateWarnings = true; + else if(!stricmp(option, "scriptdataonly")) + g_onlyCallSavestateCallbacks = true; + } + struct Scope { ~Scope(){ g_disableStatestateWarnings = false; g_onlyCallSavestateCallbacks = false; } } scope; // needs to run even if the following code throws an exception... maybe I should have put this in a "finally" block instead, but this project seems to have something against using the "try" statement + + if(!g_onlyCallSavestateCallbacks && FailVerifyAtFrameBoundary(L, "savestate.save", 2,2)) + return 0; + + int type = lua_type(L,1); + switch(type) + { + case LUA_TNUMBER: // numbered save file + default: + { + int stateNumber = luaL_checkinteger(L,1); + Set_Current_State(stateNumber, false,false); + char Name [1024] = {0}; + Get_State_File_Name(Name); + Save_State(Name); + } return 0; + case LUA_TUSERDATA: // in-memory save slot + { + unsigned char* stateBuffer = (unsigned char*)lua_touserdata(L,1); + if(stateBuffer) + { + stateBuffer += ((16 - (int)stateBuffer) & 15); // for performance alignment reasons + Save_State_To_Buffer(stateBuffer); + } + } return 0; + } +} + +// savestate.load(location [, option]) +// loads the current emulation state from the given location +// you can pass in either a savestate file number (an integer), +// OR you can pass in a savestate object that was returned by savestate.create() and has already saved to with savestate.save() +// if option is "quiet" then any warning messages will be suppressed +// if option is "scriptdataonly" then the state will not actually be loaded, but load callbacks will still get called and supplied with the data saved by save callbacks (see savestate.registerload()/savestate.registersave()) +DEFINE_LUA_FUNCTION(state_load, "location[,option]") +{ + const char* option = (lua_type(L,2) == LUA_TSTRING) ? lua_tostring(L,2) : NULL; + if(option) + { + if(!stricmp(option, "quiet")) + g_disableStatestateWarnings = true; + else if(!stricmp(option, "scriptdataonly")) + g_onlyCallSavestateCallbacks = true; + } + struct Scope { ~Scope(){ g_disableStatestateWarnings = false; g_onlyCallSavestateCallbacks = false; } } scope; // needs to run even if the following code throws an exception... maybe I should have put this in a "finally" block instead, but this project seems to have something against using the "try" statement + + if(!g_onlyCallSavestateCallbacks && FailVerifyAtFrameBoundary(L, "savestate.load", 2,2)) + return 0; + + g_disableStatestateWarnings = lua_toboolean(L,2) != 0; + + int type = lua_type(L,1); + switch(type) + { + case LUA_TNUMBER: // numbered save file + default: + { + LuaContextInfo& info = GetCurrentInfo(); + if(info.rerecordCountingDisabled) + SkipNextRerecordIncrement = true; + int stateNumber = luaL_checkinteger(L,1); + Set_Current_State(stateNumber, false,!g_disableStatestateWarnings); + char Name [1024] = {0}; + Get_State_File_Name(Name); + Load_State(Name); + } return 0; + case LUA_TUSERDATA: // in-memory save slot + { + unsigned char* stateBuffer = (unsigned char*)lua_touserdata(L,1); + if(stateBuffer) + { + stateBuffer += ((16 - (int)stateBuffer) & 15); // for performance alignment reasons + if(stateBuffer[0]) + Load_State_From_Buffer(stateBuffer); + else // the first byte of a valid savestate is never 0 + luaL_error(L, "attempted to load an anonymous savestate before saving it"); + } + } return 0; + } +} +*/ +// savestate.loadscriptdata(location) +// returns the user data associated with the given savestate +// without actually loading the rest of that savestate or calling any callbacks. +// you can pass in either a savestate file number (an integer), +// OR you can pass in a savestate object that was returned by savestate.create() +// but note that currently only non-anonymous savestates can have associated scriptdata +// +// also note that this returns the same values +// that would be passed into a registered load function. +// the main reason this exists also is so you can register a load function that +// chooses whether or not to load the scriptdata instead of always loading it, +// and also to provide a nicer interface for loading scriptdata +// without needing to trigger savestate loading first +//DEFINE_LUA_FUNCTION(state_loadscriptdata, "location") +//{ +// int type = lua_type(L,1); +// switch(type) +// { +// case LUA_TNUMBER: // numbered save file +// default: +// { +// int stateNumber = luaL_checkinteger(L,1); +// Set_Current_State(stateNumber, false,false); +// char Name [1024] = {0}; +// Get_State_File_Name(Name); +// { +// LuaSaveData saveData; +// +// char luaSaveFilename [512]; +// strncpy(luaSaveFilename, Name, 512); +// luaSaveFilename[512-(1+7/*strlen(".luasav")*/)] = '\0'; +// strcat(luaSaveFilename, ".luasav"); +// FILE* luaSaveFile = fopen(luaSaveFilename, "rb"); +// if(luaSaveFile) +// { +// saveData.ImportRecords(luaSaveFile); +// fclose(luaSaveFile); +// +// int uid = luaStateToUIDMap[L]; +// LuaContextInfo& info = GetCurrentInfo(); +// +// lua_settop(L, 0); +// saveData.LoadRecord(uid, info.dataLoadKey, (unsigned int)-1); +// return lua_gettop(L); +// } +// } +// } return 0; +// case LUA_TUSERDATA: // in-memory save slot +// { // there can be no user data associated with those, at least not yet +// } return 0; +// } +//} + +// savestate.savescriptdata(location) +// same as savestate.save(location, "scriptdataonly") +// only provided for consistency with savestate.loadscriptdata(location) +/*DEFINE_LUA_FUNCTION(state_savescriptdata, "location") +{ + lua_settop(L, 1); + lua_pushstring(L, "scriptdataonly"); + return state_save(L); +} +*/ + +//joypad lib + +static const char *button_mappings[] = { +"debug","r","l","x","y","a","b","start","select","up","down","left","right" +}; + +// table joypad.read(int which = 1) +// +// Reads the joypads as inputted by the user. +static int joy_get(lua_State *L) { + + uint16 buttons = nds.pad; + + lua_newtable(L); + + int i; + for (i = 0; i < 16; i++) { + if (buttons & (1<= 2) color |= 0xFF; + return color; + } + else for(int i = 0; i 255) value = 255; + switch(key) + { + case 1: case 'r': color |= value << 24; break; + case 2: case 'g': color |= value << 16; break; + case 3: case 'b': color |= value << 8; break; + case 4: case 'a': color = (color & ~0xFF) | value; break; + } + lua_pop(L, 1); + } + return color; + } break; + case LUA_TFUNCTION: + return 0; + } + return defaultColor; +} +int getcolor(lua_State *L, int idx, int defaultColor) +{ + int color = getcolor_unmodified(L, idx, defaultColor); + LuaContextInfo& info = GetCurrentInfo(); + if(info.transparencyModifier != 255) + { + int alpha = (((color & 0xFF) * info.transparencyModifier) / 255); + if(alpha > 255) alpha = 255; + color = (color & ~0xFF) | alpha; + } + return color; +} + +// r,g,b,a = gui.parsecolor(color) +// examples: +// local r,g,b = gui.parsecolor("green") +// local r,g,b,a = gui.parsecolor(0x7F3FFF7F) +DEFINE_LUA_FUNCTION(gui_parsecolor, "color") +{ + int color = getcolor_unmodified(L, 1, 0); + int r = (color & 0xFF000000) >> 24; + int g = (color & 0x00FF0000) >> 16; + int b = (color & 0x0000FF00) >> 8; + int a = (color & 0x000000FF); + lua_pushinteger(L, r); + lua_pushinteger(L, g); + lua_pushinteger(L, b); + lua_pushinteger(L, a); + return 4; +} +/* +DEFINE_LUA_FUNCTION(gui_text, "x,y,str[,color=\"white\"[,outline=\"black\"]]") +{ + if(DeferGUIFuncIfNeeded(L)) + return 0; // we have to wait until later to call this function because gens hasn't emulated the next frame yet + // (the only way to avoid this deferring is to be in a gui.register or gens.registerafter callback) + + int x = luaL_checkinteger(L,1) & 0xFFFF; + int y = luaL_checkinteger(L,2) & 0xFFFF; + const char* str = toCString(L,3); // better than using luaL_checkstring here (more permissive) + + if(str && *str) + { + int foreColor = getcolor(L,4,0xFFFFFFFF); + int backColor = getcolor(L,5,0x000000FF); + PutText2(str, x, y, foreColor, backColor); + } + + return 0; +} + +static inline void ApplyShaderToPixel(int off, std::map& cachedShaderResults, lua_State* L, int idx) +{ + int color; + if (Bits32) + color = MD_Screen32[off]; + else + color = DrawUtil::Pix16To32(MD_Screen[off]); + + int result; + std::map::const_iterator found = cachedShaderResults.find(color); + if(found != cachedShaderResults.end()) + { + result = found->second; + } + else + { + int b = (color & 0x000000FF); + int g = (color & 0x0000FF00) >> 8; + int r = (color & 0x00FF0000) >> 16; + + lua_pushvalue(L, idx); + lua_pushinteger(L, r); + lua_pushinteger(L, g); + lua_pushinteger(L, b); + + lua_call(L, 3, 3); + + int rout = lua_tointeger(L, -3); + int gout = lua_tointeger(L, -2); + int bout = lua_tointeger(L, -1); + lua_pop(L,3); + if(rout < 0) rout = 0; if(rout > 255) rout = 255; + if(gout < 0) gout = 0; if(gout > 255) gout = 255; + if(bout < 0) bout = 0; if(bout > 255) bout = 255; + + result = DrawUtil::Make32(rout,gout,bout); + cachedShaderResults[color] = result; + } + if (Bits32) + MD_Screen32[off] = result; + else + MD_Screen[off] = DrawUtil::Pix32To16(result); +} + +#define SWAP_INTEGERS(x,y) x^=y, y^=x, x^=y + +// performance note: for me, this function is extremely slow in debug builds, +// but when compiled with full optimizations turned on it becomes very fast. +void ApplyShaderToBox(int x1, int y1, int x2, int y2, lua_State* L, int idx) +{ + if((x1 < 0 && x2 < 0) || (x1 > 319 && x2 > 319) || (y1 < 0 && y2 < 0) || (y1 > 223 && y2 > 223)) + return; + + // require x1,y1 <= x2,y2 + if (x1 > x2) SWAP_INTEGERS(x1,x2); + if (y1 > y2) SWAP_INTEGERS(y1,y2); + + // avoid trying to draw any offscreen pixels + if (x1 < 0) x1 = 0; + if (x1 > 319) x1 = 319; + if (x2 < 0) x2 = 0; + if (x2 > 319) x2 = 319; + if (y1 < 0) y1 = 0; + if (y1 > 223) y1 = 223; + if (y2 < 0) y2 = 0; + if (y2 > 223) y2 = 223; + + std::map cachedShaderResults; + + for(short y = y1; y <= y2; y++) + { + int off = (y * 336) + x1 + 8; + for(short x = x1; x <= x2; x++, off++) + { + ApplyShaderToPixel(off, cachedShaderResults, L, idx); + } + } +} + +void ApplyShaderToBoxOutline(int x1, int y1, int x2, int y2, lua_State* L, int idx) +{ + // require x1,y1 <= x2,y2 + if (x1 > x2) SWAP_INTEGERS(x1,x2); + if (y1 > y2) SWAP_INTEGERS(y1,y2); + + // avoid trying to draw any offscreen pixels + if (x1 < -1) x1 = -1; + if (x1 > 320) x1 = 320; + if (x2 < -1) x2 = -1; + if (x2 > 320) x2 = 320; + if (y1 < -1) y1 = -1; + if (y1 > 224) y1 = 224; + if (y2 < -1) y2 = -1; + if (y2 > 224) y2 = 224; + + std::map cachedShaderResults; + + if(y1 >= 0 && y1 < 224) + for (short x = x1+1; x < x2; x++) + ApplyShaderToPixel((y1 * 336) + x + 8, cachedShaderResults, L, idx); + if(x1 >= 0 && x1 < 320) + for (short y = y1; y <= y2; y++) + ApplyShaderToPixel((y * 336) + x1 + 8, cachedShaderResults, L, idx); + if(y1 != y2 && y2 >= 0 && y2 < 224) + for (short x = x1+1; x < x2; x++) + ApplyShaderToPixel((y2 * 336) + x + 8, cachedShaderResults, L, idx); + if(x1 != x2 && x2 >= 0 && x2 < 320) + for (short y = y1; y <= y2; y++) + ApplyShaderToPixel((y * 336) + x2 + 8, cachedShaderResults, L, idx); +} + +int amplifyShader(lua_State* L) +{ + int rin = lua_tointeger(L, 1); + int gin = lua_tointeger(L, 2); + int bin = lua_tointeger(L, 3); + lua_pushvalue(L, lua_upvalueindex(1)); + lua_insert(L, 1); + lua_call(L, 3, 3); + int rout = lua_tointeger(L, 1); + int gout = lua_tointeger(L, 2); + int bout = lua_tointeger(L, 3); + lua_settop(L, 0); + lua_pushinteger(L, rout*4 - rin*3); + lua_pushinteger(L, gout*4 - gin*3); + lua_pushinteger(L, bout*4 - bin*3); + return 3; +}*/ +/* +DEFINE_LUA_FUNCTION(gui_box, "x1,y1,x2,y2[,fill[,outline]]") +{ + if(DeferGUIFuncIfNeeded(L)) + return 0; + + int x1 = luaL_checkinteger(L,1); // & 0xFFFF removed because it was turning -1 into 65535 which screwed up the out-of-bounds checking in ApplyShaderToBox + int y1 = luaL_checkinteger(L,2); + int x2 = luaL_checkinteger(L,3); + int y2 = luaL_checkinteger(L,4); + int fillcolor = getcolor(L,5,0xFFFFFF3F); + int outlinecolor = getcolor(L,6,fillcolor|0xFF); + if(!lua_isfunction(L,5) || !lua_isnoneornil(L,6)) + { + DrawBoxPP2(x1, y1, x2, y2, fillcolor, outlinecolor); + if(lua_isfunction(L,5)) + ApplyShaderToBox(x1+1,y1+1,x2-1,y2-1, L,5); + if(lua_isfunction(L,6)) + ApplyShaderToBoxOutline(x1,y1,x2,y2, L,6); + } + else // fill is a shader and outline is not specified, so make the outline a more "opaque" version of the shader to match up with the default color behavior + { + ApplyShaderToBox(x1+1,y1+1,x2-1,y2-1, L,5); + lua_settop(L, 5); + lua_pushvalue(L, 5); + lua_pushcclosure(L, amplifyShader, 1); + ApplyShaderToBoxOutline(x1,y1,x2,y2, L,6); + } + + return 0; +} +// gui.setpixel(x,y,color) +// color can be a RGB web color like '#ff7030', or with alpha RGBA like '#ff703060' +// or it can be an RGBA hex number like 0xFF703060 +// or it can be a preset color like 'red', 'orange', 'blue', 'white', etc. +DEFINE_LUA_FUNCTION(gui_pixel, "x,y[,color=\"white\"]") +{ + if(DeferGUIFuncIfNeeded(L)) + return 0; + + int x = luaL_checkinteger(L,1) & 0xFFFF; + int y = luaL_checkinteger(L,2) & 0xFFFF; + int color = getcolor(L,3,0xFFFFFFFF); + int color32 = color>>8; + int color16 = DrawUtil::Pix32To16(color32); + int Opac = color & 0xFF; + + if(Opac) + Pixel(x, y, color32, color16, 0, Opac); + + return 0; +} +// r,g,b = gui.getpixel(x,y) +DEFINE_LUA_FUNCTION(gui_getpixel, "x,y") +{ + int x = luaL_checkinteger(L,1); + int y = luaL_checkinteger(L,2); + + int xres = ((VDP_Reg.Set4 & 0x1) || Debug || !Game || !FrameCount) ? 320 : 256; + int yres = ((VDP_Reg.Set2 & 0x8) && !(Debug || !Game || !FrameCount)) ? 240 : 224; + + x = std::max(0,std::min(xres,x)); + y = std::max(0,std::min(yres,y)); + + int off = (y * 336) + x + 8; + + int color; + if (Bits32) + color = MD_Screen32[off]; + else + color = DrawUtil::Pix16To32(MD_Screen[off]); + + int b = (color & 0x000000FF); + int g = (color & 0x0000FF00) >> 8; + int r = (color & 0x00FF0000) >> 16; + + lua_pushinteger(L, r); + lua_pushinteger(L, g); + lua_pushinteger(L, b); + + return 3; +} +DEFINE_LUA_FUNCTION(gui_line, "x1,y1,x2,y2[,color=\"white\"[,skipfirst=false]]") +{ + if(DeferGUIFuncIfNeeded(L)) + return 0; + + int x1 = luaL_checkinteger(L,1) & 0xFFFF; + int y1 = luaL_checkinteger(L,2) & 0xFFFF; + int x2 = luaL_checkinteger(L,3) & 0xFFFF; + int y2 = luaL_checkinteger(L,4) & 0xFFFF; + int color = getcolor(L,5,0xFFFFFFFF); + int color32 = color>>8; + int color16 = DrawUtil::Pix32To16(color32); + int Opac = color & 0xFF; + + if(Opac) + { + int skipFirst = lua_toboolean(L,6); + DrawLine(x1, y1, x2, y2, color32, color16, 0, Opac, skipFirst); + } + + return 0; +} + +// gui.opacity(number alphaValue) +// sets the transparency of subsequent draw calls +// 0.0 is completely transparent, 1.0 is completely opaque +// non-integer values are supported and meaningful, as are values greater than 1.0 +// it is not necessary to use this function to get transparency (or the less-recommended gui.transparency() either), +// because you can provide an alpha value in the color argument of each draw call. +// however, it can be convenient to be able to globally modify the drawing transparency +DEFINE_LUA_FUNCTION(gui_setopacity, "alpha_0_to_1") +{ + lua_Number opacF = luaL_checknumber(L,1); + opacF *= 255.0; + if(opacF < 0) opacF = 0; + int opac; + lua_number2int(opac, opacF); + LuaContextInfo& info = GetCurrentInfo(); + info.transparencyModifier = opac; + return 0; +} + +// gui.transparency(number transparencyValue) +// sets the transparency of subsequent draw calls +// 0.0 is completely opaque, 4.0 is completely transparent +// non-integer values are supported and meaningful, as are values less than 0.0 +// this is a legacy function, and the range is from 0 to 4 solely for this reason +// it does the exact same thing as gui.opacity() but with a different argument range +DEFINE_LUA_FUNCTION(gui_settransparency, "transparency_4_to_0") +{ + lua_Number transp = luaL_checknumber(L,1); + lua_Number opacF = 4 - transp; + opacF *= 255.0 / 4.0; + if(opacF < 0) opacF = 0; + int opac; + lua_number2int(opac, opacF); + LuaContextInfo& info = GetCurrentInfo(); + info.transparencyModifier = opac; + return 0; +} + +// takes a screenshot and returns it in gdstr format +// example: gd.createFromGdStr(gui.gdscreenshot()):png("outputimage.png") +DEFINE_LUA_FUNCTION(gui_gdscreenshot, "") +{ + int width = ((VDP_Reg.Set4 & 0x1) || Debug || !Game || !FrameCount) ? 320 : 256; + int height = ((VDP_Reg.Set2 & 0x8) && !(Debug || !Game || !FrameCount)) ? 240 : 224; + int size = 11 + width * height * 4; + + char* str = new char[size+1]; + str[size] = 0; + unsigned char* ptr = (unsigned char*)str; + + // GD format header for truecolor image (11 bytes) + *ptr++ = (65534 >> 8) & 0xFF; + *ptr++ = (65534 ) & 0xFF; + *ptr++ = (width >> 8) & 0xFF; + *ptr++ = (width ) & 0xFF; + *ptr++ = (height >> 8) & 0xFF; + *ptr++ = (height ) & 0xFF; + *ptr++ = 1; + *ptr++ = 255; + *ptr++ = 255; + *ptr++ = 255; + *ptr++ = 255; + + unsigned char *Src = Bits32 ? (unsigned char*)(MD_Screen32+8) : (unsigned char*)(MD_Screen+8); + + if(Bits32) + { + for(int y = 0; y < height; y++, Src += 336*4) + { + for(int x = 0; x < width; x++) + { + *ptr++ = Src[4*x+3]; + *ptr++ = Src[4*x+2]; + *ptr++ = Src[4*x+1]; + *ptr++ = Src[4*x+0]; + } + } + } + else if((Mode_555 & 1) == 0) + { + for(int y = 0; y < height; y++, Src += 336*2) + { + for(int x = 0; x < width; x++) + { + int pix = DrawUtil::Pix16To32((pix16)(Src[2*x]+(Src[2*x+1]<<8))); + *ptr++ = ((unsigned char*)&pix)[3]; + *ptr++ = ((unsigned char*)&pix)[2]; + *ptr++ = ((unsigned char*)&pix)[1]; + *ptr++ = ((unsigned char*)&pix)[0]; + } + } + } + else + { + for(int y = 0; y < height; y++, Src += 336*2) + { + for(int x = 0; x < width; x++) + { + int pix = DrawUtil::Pix15To32((pix15)(Src[2*x]+(Src[2*x+1]<<8))); + *ptr++ = ((unsigned char*)&pix)[3]; + *ptr++ = ((unsigned char*)&pix)[2]; + *ptr++ = ((unsigned char*)&pix)[1]; + *ptr++ = ((unsigned char*)&pix)[0]; + } + } + } + + lua_pushlstring(L, str, size); + delete[] str; + return 1; +} + +// draws a gd image that's in gdstr format to the screen +// example: gui.gdoverlay(gd.createFromPng("myimage.png"):gdStr()) +DEFINE_LUA_FUNCTION(gui_gdoverlay, "[x=0,y=0,]gdimage[,alphamul]") +{ + if(DeferGUIFuncIfNeeded(L)) + return 0; + + int xStart = 0; + int yStart = 0; + + int index = 1; + if(lua_type(L,index) == LUA_TNUMBER) + { + xStart = lua_tointeger(L,index++); + if(lua_type(L,index) == LUA_TNUMBER) + yStart = lua_tointeger(L,index++); + } + + luaL_checktype(L,index,LUA_TSTRING); + const unsigned char* ptr = (const unsigned char*)lua_tostring(L,index++); + + // GD format header for truecolor image (11 bytes) + ptr++; + ptr++; + int width = *ptr++ << 8; + width |= *ptr++; + int height = *ptr++ << 8; + height |= *ptr++; + ptr += 5; + + int maxWidth = ((VDP_Reg.Set4 & 0x1) || Debug || !Game || !FrameCount) ? 320 : 256; + int maxHeight = ((VDP_Reg.Set2 & 0x8) && !(Debug || !Game || !FrameCount)) ? 240 : 224; + + unsigned char *Dst = Bits32 ? (unsigned char*)(MD_Screen32+8) : (unsigned char*)(MD_Screen+8); + + LuaContextInfo& info = GetCurrentInfo(); + int alphaMul = info.transparencyModifier; + if(lua_isnumber(L, index)) + alphaMul = (int)(alphaMul * lua_tonumber(L, index++)); + if(alphaMul <= 0) + return 0; + + // since there aren't that many possible opacity levels, + // do the opacity modification calculations beforehand instead of per pixel + int opacMap[256]; + for(int i = 0; i < 256; i++) + { + int opac = 255 - (i << 1); // not sure why, but gdstr seems to divide each alpha value by 2 + opac = (opac * alphaMul) / 255; + if(opac < 0) opac = 0; + if(opac > 255) opac = 255; + opacMap[i] = 255 - opac; + } + + if(Bits32) + { + Dst += yStart * 336*4; + for(int y = yStart; y < height+yStart && y < maxHeight; y++, Dst += 336*4) + { + if(y < 0) + ptr += width * 4; + else + { + int xA = (xStart < 0 ? 0 : xStart); + int xB = (xStart+width > maxWidth ? maxWidth : xStart+width); + ptr += (xA - xStart) * 4; + for(int x = xA; x < xB; x++) + { + //Dst[4*x+3] = *ptr++; + //Dst[4*x+2] = *ptr++; + //Dst[4*x+1] = *ptr++; + //Dst[4*x+0] = *ptr++; + + int opac = opacMap[ptr[0]]; + pix32 pix = (ptr[3]|(ptr[2]<<8)|(ptr[1]<<16)); + pix32 prev = Dst[4*x] | (Dst[4*x+1] << 8) | (Dst[4*x+2] << 16); + pix = DrawUtil::Blend(prev, pix, opac); + Dst[4*x] = pix & 0xFF; + Dst[4*x+1] = (pix>>8) & 0xFF; + Dst[4*x+2] = (pix>>16) & 0xFF; + ptr += 4; + } + ptr += (xStart+width - xB) * 4; + } + } + } + else if((Mode_555 & 1) == 0) + { + Dst += yStart * 336*2; + for(int y = yStart; y < height+yStart && y < maxHeight; y++, Dst += 336*2) + { + if(y < 0) + ptr += width * 4; + else + { + int xA = (xStart < 0 ? 0 : xStart); + int xB = (xStart+width > maxWidth ? maxWidth : xStart+width); + ptr += (xA - xStart) * 4; + for(int x = xA; x < xB; x++) + { + int opac = opacMap[ptr[0]]; + pix32 pixh = (ptr[3]|(ptr[2]<<8)|(ptr[1]<<16)); + pix32 prev = DrawUtil::Pix16To32(Dst[2*x] | (Dst[2*x+1] << 8)); + pix16 pix = DrawUtil::Pix32To16(DrawUtil::Blend(prev, pixh, opac)); + Dst[2*x] = pix & 0xFF; + Dst[2*x+1] = (pix>>8) & 0xFF; + ptr += 4; + } + ptr += (xStart+width - xB) * 4; + } + } + } + else + { + Dst += yStart * 336*2; + for(int y = yStart; y < height+yStart && y < maxHeight; y++, Dst += 336*2) + { + if(y < 0) + ptr += width * 4; + else + { + int xA = (xStart < 0 ? 0 : xStart); + int xB = (xStart+width > maxWidth ? maxWidth : xStart+width); + ptr += (xA - xStart) * 4; + for(int x = xA; x < xB; x++) + { + int opac = opacMap[ptr[0]]; + pix32 pixh = (ptr[3]|(ptr[2]<<8)|(ptr[1]<<16)); + pix32 prev = DrawUtil::Pix15To32(Dst[2*x] | (Dst[2*x+1] << 8)); + pix15 pix = DrawUtil::Pix32To15(DrawUtil::Blend(prev, pixh, opac)); + Dst[2*x] = pix & 0xFF; + Dst[2*x+1] = (pix>>8) & 0xFF; + ptr += 4; + } + ptr += (xStart+width - xB) * 4; + } + } + } + + return 0; +} +*/ +static void GetCurrentScriptDir(char* buffer, int bufLen) +{ + LuaContextInfo& info = GetCurrentInfo(); + strncpy(buffer, info.lastFilename.c_str(), bufLen); + buffer[bufLen-1] = 0; + char* slash = std::max(strrchr(buffer, '/'), strrchr(buffer, '\\')); + if(slash) + slash[1] = 0; +} + +DEFINE_LUA_FUNCTION(emu_openscript, "filename") +{ +#ifdef WIN32 + char curScriptDir[1024]; GetCurrentScriptDir(curScriptDir, 1024); // make sure we can always find scripts that are in the same directory as the current script + const char* filename = lua_isstring(L,1) ? lua_tostring(L,1) : NULL; + extern const char* OpenLuaScript(const char* filename, const char* extraDirToCheck, bool makeSubservient); + const char* errorMsg = OpenLuaScript(filename, curScriptDir, true); + if(errorMsg) + luaL_error(L, errorMsg); +#endif + return 0; +} +/* +DEFINE_LUA_FUNCTION(gens_loadrom, "filename") +{ + struct Temp { Temp() {EnableStopAllLuaScripts(false);} ~Temp() {EnableStopAllLuaScripts(true);}} dontStopScriptsHere; + const char* filename = lua_isstring(L,1) ? lua_tostring(L,1) : NULL; + char curScriptDir[1024]; GetCurrentScriptDir(curScriptDir, 1024); + filename = MakeRomPathAbsolute(filename, curScriptDir); + int result = GensLoadRom(filename); + if(result <= 0) + luaL_error(L, "Failed to load ROM \"%s\": %s", filename, result ? "invalid or unsupported" : "cancelled or not found"); + CallRegisteredLuaFunctions(LUACALL_ONSTART); + return 0; +} +*/ +DEFINE_LUA_FUNCTION(emu_getframecount, "") +{ + lua_pushinteger(L, currFrameCounter); + return 1; +} +DEFINE_LUA_FUNCTION(emu_getlagcount, "") +{ + lua_pushinteger(L, TotalLagFrames); + return 1; +} +DEFINE_LUA_FUNCTION(emu_lagged, "") +{ + lua_pushboolean(L, LagFrameFlag); + return 1; +}/* +DEFINE_LUA_FUNCTION(gens_emulating, "") +{ + lua_pushboolean(L, Genesis_Started||SegaCD_Started||_32X_Started); + return 1; +} +DEFINE_LUA_FUNCTION(gens_atframeboundary, "") +{ + lua_pushboolean(L, !Inside_Frame); + return 1; +}*/ +DEFINE_LUA_FUNCTION(movie_getlength, "") +{ + lua_pushinteger(L, currMovieData.records.size()); + return 1; +} +DEFINE_LUA_FUNCTION(movie_isactive, "") +{ + if(movieMode != MOVIEMODE_INACTIVE); + lua_pushboolean(L, true); + return 1; +} +DEFINE_LUA_FUNCTION(movie_rerecordcount, "") +{ + lua_pushinteger(L, currMovieData.rerecordCount); + return 1; +}/* +DEFINE_LUA_FUNCTION(movie_setrerecordcount, "") +{ + MainMovie.NbRerecords = luaL_checkinteger(L, 1); + return 0; +}*/ +DEFINE_LUA_FUNCTION(emu_rerecordcounting, "[enabled]") +{ + LuaContextInfo& info = GetCurrentInfo(); + if(lua_gettop(L) == 0) + { + // if no arguments given, return the current value + lua_pushboolean(L, !info.rerecordCountingDisabled); + return 1; + } + else + { + // set rerecord disabling + info.rerecordCountingDisabled = !lua_toboolean(L,1); + return 0; + } +} +DEFINE_LUA_FUNCTION(movie_getreadonly, "") +{ + lua_pushboolean(L, movie_readonly); + return 1; +} +DEFINE_LUA_FUNCTION(movie_setreadonly, "readonly") +{ + int readonly = lua_toboolean(L,1) ? 1 : 0; + if(!movie_readonly) + movie_readonly = true; + else + movie_readonly = false; +// else if(!movie_readonly) +// luaL_error(L, "movie.setreadonly failed: write permission denied"); + + return 0; +} +DEFINE_LUA_FUNCTION(movie_isrecording, "") +{ + lua_pushboolean(L, movieMode == MOVIEMODE_RECORD); + return 1; +} +DEFINE_LUA_FUNCTION(movie_isplaying, "") +{ + lua_pushboolean(L, movieMode == MOVIEMODE_PLAY); + return 1; +} +DEFINE_LUA_FUNCTION(movie_getmode, "") +{ + switch(movieMode) + { + case MOVIEMODE_PLAY: + lua_pushstring(L, "playback"); + break; + case MOVIEMODE_RECORD: + lua_pushstring(L, "record"); + break; + case MOVIEMODE_INACTIVE: + lua_pushstring(L, "inactive"); + break; + default: + lua_pushnil(L); + break; + } + return 1; +} +DEFINE_LUA_FUNCTION(movie_getname, "") +{ + extern char curMovieFilename[512]; + lua_pushstring(L, curMovieFilename); + return 1; +} +// movie.play() -- plays a movie of the user's choice +// movie.play(filename) -- starts playing a particular movie +// throws an error (with a description) if for whatever reason the movie couldn't be played +DEFINE_LUA_FUNCTION(movie_play, "[filename]") +{ + const char* filename = lua_isstring(L,1) ? lua_tostring(L,1) : NULL; + FCEUI_LoadMovie(filename, true, false, 0); +// const char* errorMsg = +// if(errorMsg) +// luaL_error(L, errorMsg); + return 0; +} /* +DEFINE_LUA_FUNCTION(movie_replay, "") +{ + if(MainMovie.File) + GensReplayMovie(); + else + luaL_error(L, "it is invalid to call movie.replay when no movie open."); + return 0; +} */ +DEFINE_LUA_FUNCTION(movie_close, "") +{ + + FCEUI_StopMovie(); + return 0; +} + +DEFINE_LUA_FUNCTION(sound_clear, "") +{ +// Clear_Sound_Buffer(); + return 0; +} + +#ifdef _WIN32 +const char* s_keyToName[256] = +{ + NULL, + "leftclick", + "rightclick", + NULL, + "middleclick", + NULL, + NULL, + NULL, + "backspace", + "tab", + NULL, + NULL, + NULL, + "enter", + NULL, + NULL, + "shift", // 0x10 + "control", + "alt", + "pause", + "capslock", + NULL, + NULL, + NULL, + NULL, + NULL, + NULL, + "escape", + NULL, + NULL, + NULL, + NULL, + "space", // 0x20 + "pageup", + "pagedown", + "end", + "home", + "left", + "up", + "right", + "down", + NULL, + NULL, + NULL, + NULL, + "insert", + "delete", + NULL, + "0","1","2","3","4","5","6","7","8","9", + NULL, NULL, NULL, NULL, NULL, NULL, NULL, + "A","B","C","D","E","F","G","H","I","J", + "K","L","M","N","O","P","Q","R","S","T", + "U","V","W","X","Y","Z", + NULL, + NULL, + NULL, + NULL, + NULL, + "numpad0","numpad1","numpad2","numpad3","numpad4","numpad5","numpad6","numpad7","numpad8","numpad9", + "numpad*","numpad+", + NULL, + "numpad-","numpad.","numpad/", + "F1","F2","F3","F4","F5","F6","F7","F8","F9","F10","F11","F12", + "F13","F14","F15","F16","F17","F18","F19","F20","F21","F22","F23","F24", + NULL, + NULL, + NULL, + NULL, + NULL, + NULL, + NULL, + NULL, + "numlock", + "scrolllock", + NULL, // 0x92 + NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, + NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, + NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, + NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, + NULL, // 0xB9 + "semicolon", + "plus", + "comma", + "minus", + "period", + "slash", + "tilde", + NULL, // 0xC1 + NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, + NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, + NULL, NULL, NULL, NULL, NULL, NULL, NULL, + NULL, // 0xDA + "leftbracket", + "backslash", + "rightbracket", + "quote", +}; +#endif + + +// input.get() +// takes no input, returns a lua table of entries representing the current input state, +// independent of the joypad buttons the emulated game thinks are pressed +// for example: +// if the user is holding the W key and the left mouse button +// and has the mouse at the bottom-right corner of the game screen, +// then this would return {W=true, leftclick=true, xmouse=319, ymouse=223} +DEFINE_LUA_FUNCTION(input_getcurrentinputstatus, "") +{ + lua_newtable(L); + +#ifdef _WIN32 + // keyboard and mouse button status + { + int BackgroundInput = 0;//TODO + + unsigned char keys [256]; + if(!BackgroundInput) + { + if(GetKeyboardState(keys)) + { + for(int i = 1; i < 255; i++) + { + int mask = (i == VK_CAPITAL || i == VK_NUMLOCK || i == VK_SCROLL) ? 0x01 : 0x80; + if(keys[i] & mask) + { + const char* name = s_keyToName[i]; + if(name) + { + lua_pushboolean(L, true); + lua_setfield(L, -2, name); + } + } + } + } + } + else // use a slightly different method that will detect background input: + { + for(int i = 1; i < 255; i++) + { + const char* name = s_keyToName[i]; + if(name) + { + int active; + if(i == VK_CAPITAL || i == VK_NUMLOCK || i == VK_SCROLL) + active = GetKeyState(i) & 0x01; + else + active = GetAsyncKeyState(i) & 0x8000; + if(active) + { + lua_pushboolean(L, true); + lua_setfield(L, -2, name); + } + } + } + } + } + // mouse position in game screen pixel coordinates + { +/* POINT point; + RECT rect, srcRectUnused; + float xRatioUnused, yRatioUnused; + int depUnused; + GetCursorPos(&point); + ScreenToClient(MainWindow->getHWnd(), &point); + GetClientRect(MainWindow->getHWnd(), &rect); + void CalculateDrawArea(int Render_Mode, RECT& RectDest, RECT& RectSrc, float& Ratio_X, float& Ratio_Y, int& Dep); + CalculateDrawArea(Full_Screen ? Render_FS : Render_W, rect, srcRectUnused, xRatioUnused, yRatioUnused, depUnused); + int xres = ((VDP_Reg.Set4 & 0x1) || Debug || !Game || !FrameCount) ? 320 : 256; + int yres = ((VDP_Reg.Set2 & 0x8) && !(Debug || !Game || !FrameCount)) ? 240 : 224; + int x = ((point.x - rect.left) * xres) / max(1, rect.right - rect.left); + int y = ((point.y - rect.top) * yres) / max(1, rect.bottom - rect.top);*/ + int x = 0, y = 0; + lua_pushinteger(L, x); + lua_setfield(L, -2, "xmouse"); + lua_pushinteger(L, y); + lua_setfield(L, -2, "ymouse"); + } +#else + // NYI (well, return an empty table) +#endif + + return 1; +} + + +// resets our "worry" counter of the Lua state +int dontworry(LuaContextInfo& info) +{ + if(info.stopWorrying) + { + info.stopWorrying = false; + if(info.worryCount) + indicateBusy(info.L, false); + } + info.worryCount = 0; + return 0; +} + +//start placeholder drawing funcs--------------------------------------------------- +//TODO a real drawing lib + +// I'm going to use this a lot in here +#define swap(T, one, two) { \ + T temp = one; \ + one = two; \ + two = temp; \ +} + + +// gui.drawbox(x1, y1, x2, y2, colour) +static int gui_box(lua_State *L) { + + int x1,y1,x2,y2; + uint8 colour; + int i; + + x1 = luaL_checkinteger(L,1); + y1 = luaL_checkinteger(L,2); + x2 = luaL_checkinteger(L,3); + y2 = luaL_checkinteger(L,4); +// y1 += FSettings.FirstSLine; +// y2 += FSettings.FirstSLine; +// colour = gui_getcolour(L,5); + +// if (x1 < 0 || x1 >= 256 || y1 < 0 || y1 > 384) +// luaL_error(L,"bad coordinates"); + +// if (x2 < 0 || x2 >= 256 || y2 < 0 || y2 > 384) +// luaL_error(L,"bad coordinates"); + + +// gui_prepare(); + + // For simplicity, we mandate that x1,y1 be the upper-left corner + if (x1 > x2) + swap(int, x1, x2); + if (y1 > y2) + swap(int, y1, y2); + + // top surface + for (i=x1; i <= x2; i++) +// gui_data[y1*256 + i] = colour; + osd->addFixed(i, y1, "%s", "."); + + // bottom surface + for (i=x1; i <= x2; i++) +// gui_data[y2*256 + i] = colour; + osd->addFixed(i, y2, "%s", "."); + + // left surface + for (i=y1; i <= y2; i++) +// gui_data[i*256+x1] = colour; + osd->addFixed(x1, i, "%s", "."); + + // right surface + for (i=y1; i <= y2; i++) +// gui_data[i*256+x2] = colour; + osd->addFixed(x2, i, "%s", "."); + + + return 0; +} + +// gui.drawline(x1,y1,x2,y2,type colour) +static int gui_line(lua_State *L) { + + int x1,y1,x2,y2; + uint8 colour; + x1 = luaL_checkinteger(L,1); + y1 = luaL_checkinteger(L,2); + x2 = luaL_checkinteger(L,3); + y2 = luaL_checkinteger(L,4); +// y1 += FSettings.FirstSLine; +// y2 += FSettings.FirstSLine; +// colour = gui_getcolour(L,5); + +// if (x1 < 0 || x1 >= 256 || y1 < FSettings.FirstSLine || y1 > FSettings.LastSLine) +// luaL_error(L,"bad coordinates"); + +// if (x2 < 0 || x2 >= 256 || y2 < FSettings.FirstSLine || y2 > FSettings.LastSLine) +// luaL_error(L,"bad coordinates"); + +// gui_prepare(); + + + // Horizontal line? + if (y1 == y2) { + if (x1 > x2) + swap(int, x1, x2); + int i; + for (i=x1; i <= x2; i++) + osd->addFixed(i, y1, "%s", "."); +// gui_data[y1*256+i] = colour; + } else if (x1 == x2) { // Vertical line? + if (y1 > y2) + swap(int, y1, y2); + int i; + for (i=y1; i < y2; i++) + osd->addFixed(x1, i, "%s", "."); +// gui_data[i*256+x1] = colour; + } else { + // Some very real slope. We want to increase along the x value, so we swap for that. + if (x1 > x2) { + swap(int, x1, x2); + swap(int, y1, y2); + } + + + double slope = ((double)y2-(double)y1) / ((double)x2-(double)x1); + int myX = x1, myY = y1; + double accum = 0; + + while (myX <= x2) { + // Draw the current pixel + //gui_data[myY*256 + myX] = colour; + osd->addFixed(myX, myY, "%s", "."); + + // If it's above 1, we knock 1 off it and go up 1 pixel + if (accum >= 1.0) { + myY += 1; + accum -= 1.0; + } else if (accum <= -1.0) { + myY -= 1; + accum += 1.0; + } else { + myX += 1; + accum += slope; // Step up + + } + } + + + } + + return 0; +} + +//end placeholder drawing funcs--------------------------------------------------- + +// gui.text(int x, int y, string msg) +// +// Displays the given text on the screen, using the same font and techniques as the +// main HUD. +static int gui_text(lua_State *L) { + const char *msg; + int x, y; + + x = luaL_checkinteger(L,1); + y = luaL_checkinteger(L,2); + msg = luaL_checkstring(L,3); + + osd->addFixed(x, y, "%s", msg); + + return 0; +} + +static int stylus_read(lua_State *L){ + + lua_newtable(L); + + lua_pushinteger(L, nds.touchX >> 4); + lua_setfield(L, -2, "x"); + lua_pushinteger(L, nds.touchY >> 4); + lua_setfield(L, -2, "y"); + lua_pushinteger(L, nds.isTouch); + lua_setfield(L, -2, "touch"); + + return 1; +} + +static const struct luaL_reg styluslib [] = +{ + {"read", stylus_read}, + {NULL, NULL} +}; + +static const struct luaL_reg emulib [] = +{ +// {"frameadvance", emu_frameadvance}, +// {"speedmode", emu_speedmode}, +// {"wait", emu_wait}, +// {"pause", emu_pause}, +// {"unpause", emu_unpause}, +// {"emulateframe", emu_emulateframe}, + //{"emulateframefastnoskipping", emu_emulateframefastnoskipping}, // removed from library because probably nobody would notice the difference from emu_emulateframe +// {"emulateframefast", emu_emulateframefast}, +// {"emulateframeinvisible", emu_emulateframeinvisible}, +// {"redraw", emu_redraw}, + {"framecount", emu_getframecount}, + {"lagcount", emu_getlagcount}, + {"lagged", emu_lagged}, +// {"emulating", emu_emulating}, +// {"atframeboundary", emu_atframeboundary}, + {"registerbefore", emu_registerbefore}, + {"registerafter", emu_registerafter}, +// {"registerstart", emu_registerstart}, + {"registerexit", emu_registerexit}, + {"persistglobalvariables", emu_persistglobalvariables}, + {"message", emu_message}, + {"print", print}, // sure, why not + {"openscript", emu_openscript}, +// {"loadrom", emu_loadrom}, + // alternative names +// {"openrom", emu_loadrom}, + {NULL, NULL} +}; +static const struct luaL_reg guilib [] = +{ +// {"register", gui_register}, + {"text", gui_text}, + {"box", gui_box}, + {"line", gui_line}, +// {"pixel", gui_pixel}, +// {"getpixel", gui_getpixel}, +// {"opacity", gui_setopacity}, +// {"transparency", gui_settransparency}, + {"popup", gui_popup}, + {"parsecolor", gui_parsecolor}, +// {"gdscreenshot", gui_gdscreenshot}, +// {"gdoverlay", gui_gdoverlay}, +// {"redraw", emu_redraw}, // some people might think of this as more of a GUI function + // alternative names + {"drawtext", gui_text}, + {"drawbox", gui_box}, + {"drawline", gui_line}, +// {"drawpixel", gui_pixel}, +// {"setpixel", gui_pixel}, +// {"writepixel", gui_pixel}, +// {"readpixel", gui_getpixel}, +// {"rect", gui_box}, +// {"drawrect", gui_box}, +// {"drawimage", gui_gdoverlay}, +// {"image", gui_gdoverlay}, + {NULL, NULL} +}; +static const struct luaL_reg statelib [] = +{ +// {"create", state_create}, +// {"save", state_save}, +// {"load", state_load}, +// {"loadscriptdata", state_loadscriptdata}, +// {"savescriptdata", state_savescriptdata}, + {"registersave", state_registersave}, + {"registerload", state_registerload}, + {NULL, NULL} +}; +static const struct luaL_reg memorylib [] = +{ + {"readbyte", memory_readbyte}, + {"readbytesigned", memory_readbytesigned}, + {"readword", memory_readword}, + {"readwordsigned", memory_readwordsigned}, + {"readdword", memory_readdword}, + {"readdwordsigned", memory_readdwordsigned}, + {"readbyterange", memory_readbyterange}, + {"writebyte", memory_writebyte}, + {"writeword", memory_writeword}, + {"writedword", memory_writedword}, +// {"isvalid", memory_isvalid}, + {"getregister", memory_getregister}, + {"setregister", memory_setregister}, + // alternate naming scheme for word and double-word and unsigned + {"readbyteunsigned", memory_readbyte}, + {"readwordunsigned", memory_readword}, + {"readdwordunsigned", memory_readdword}, + {"readshort", memory_readword}, + {"readshortunsigned", memory_readword}, + {"readshortsigned", memory_readwordsigned}, + {"readlong", memory_readdword}, + {"readlongunsigned", memory_readdword}, + {"readlongsigned", memory_readdwordsigned}, + {"writeshort", memory_writeword}, + {"writelong", memory_writedword}, + + // memory hooks +// {"registerwrite", memory_registerwrite}, +// {"registerread", memory_registerread}, +// {"registerexec", memory_registerexec}, + // alternate names +// {"register", memory_registerwrite}, +// {"registerrun", memory_registerexec}, +// {"registerexecute", memory_registerexec}, + + {NULL, NULL} +}; +static const struct luaL_reg joylib [] = +{ + {"get", joy_get}, +// {"getdown", joy_getdown}, +// {"getup", joy_getup}, +// {"peek", joy_peek}, +// {"peekdown", joy_peekdown}, +// {"peekup", joy_peekup}, +// {"set", joy_set}, + // alternative names + {"read", joy_get}, +// {"write", joy_set}, +// {"readdown", joy_getdown}, +// {"readup", joy_getup}, + {NULL, NULL} +}; +static const struct luaL_reg inputlib [] = +{ + {"get", input_getcurrentinputstatus}, + {"registerhotkey", input_registerhotkey}, + {"popup", input_popup}, + // alternative names + {"read", input_getcurrentinputstatus}, + {NULL, NULL} +}; +static const struct luaL_reg movielib [] = +{ + {"active", movie_isactive}, + {"recording", movie_isrecording}, + {"playing", movie_isplaying}, + {"mode", movie_getmode}, + + {"length", movie_getlength}, + {"name", movie_getname}, + {"rerecordcount", movie_rerecordcount}, +// {"setrerecordcount", movie_setrerecordcount}, + + {"rerecordcounting", emu_rerecordcounting}, + {"readonly", movie_getreadonly}, + {"setreadonly", movie_setreadonly}, + {"framecount", emu_getframecount}, // for those familiar with other emulators that have movie.framecount() instead of emulatorname.framecount() + + {"play", movie_play}, +// {"replay", movie_replay}, + {"stop", movie_close}, + + // alternative names + {"open", movie_play}, + {"close", movie_close}, + {"getname", movie_getname}, + {"playback", movie_play}, + {"getreadonly", movie_getreadonly}, + {NULL, NULL} +}; +static const struct luaL_reg soundlib [] = +{ +// {"clear", sound_clear}, + {NULL, NULL} +}; + +static const struct CFuncInfo +{ + const char* library; + const char* name; + const char* args; + bool registry; +} +cFuncInfo [] = // this info is stored here to avoid having to change all of Lua's libraries to use something like DEFINE_LUA_FUNCTION +{ + {LUA_STRLIBNAME, "byte", "str[,start[,end]]"}, + {LUA_STRLIBNAME, "char", "...[bytes]"}, + {LUA_STRLIBNAME, "dump", "func"}, + {LUA_STRLIBNAME, "find", "str,pattern[,init[,plain]]"}, + {LUA_STRLIBNAME, "format", "formatstring,..."}, + {LUA_STRLIBNAME, "gfind", "!deprecated!"}, + {LUA_STRLIBNAME, "gmatch", "str,pattern"}, + {LUA_STRLIBNAME, "gsub", "str,pattern,repl[,n]"}, + {LUA_STRLIBNAME, "len", "str"}, + {LUA_STRLIBNAME, "lower", "str"}, + {LUA_STRLIBNAME, "match", "str,pattern[,init]"}, + {LUA_STRLIBNAME, "rep", "str,n"}, + {LUA_STRLIBNAME, "reverse", "str"}, + {LUA_STRLIBNAME, "sub", "str,start[,end]"}, + {LUA_STRLIBNAME, "upper", "str"}, + {NULL, "module", "name[,...]"}, + {NULL, "require", "modname"}, + {LUA_LOADLIBNAME, "loadlib", "libname,funcname"}, + {LUA_LOADLIBNAME, "seeall", "module"}, + {LUA_COLIBNAME, "create", "func"}, + {LUA_COLIBNAME, "resume", "co[,val1,...]"}, + {LUA_COLIBNAME, "running", ""}, + {LUA_COLIBNAME, "status", "co"}, + {LUA_COLIBNAME, "wrap", "func"}, + {LUA_COLIBNAME, "yield", "..."}, + {NULL, "assert", "cond[,message]"}, + {NULL, "collectgarbage", "opt[,arg]"}, + {NULL, "gcinfo", ""}, + {NULL, "dofile", "filename"}, + {NULL, "error", "message[,level]"}, + {NULL, "getfenv", "[level_or_func]"}, + {NULL, "getmetatable", "object"}, + {NULL, "ipairs", "arraytable"}, + {NULL, "load", "func[,chunkname]"}, + {NULL, "loadfile", "[filename]"}, + {NULL, "loadstring", "str[,chunkname]"}, + {NULL, "next", "table[,index]"}, + {NULL, "pairs", "table"}, + {NULL, "pcall", "func,arg1,..."}, + {NULL, "rawequal", "v1,v2"}, + {NULL, "rawget", "table,index"}, + {NULL, "rawset", "table,index,value"}, + {NULL, "select", "index,..."}, + {NULL, "setfenv", "level_or_func,envtable"}, + {NULL, "setmetatable", "table,metatable"}, + {NULL, "tonumber", "str_or_num[,base]"}, + {NULL, "type", "obj"}, + {NULL, "unpack", "list[,i=1[,j=#list]]"}, + {NULL, "xpcall", "func,errhandler"}, + {NULL, "newproxy", "hasmeta"}, + {LUA_MATHLIBNAME, "abs", "x"}, + {LUA_MATHLIBNAME, "acos", "x"}, + {LUA_MATHLIBNAME, "asin", "x"}, + {LUA_MATHLIBNAME, "atan", "x"}, + {LUA_MATHLIBNAME, "atan2", "y,x"}, + {LUA_MATHLIBNAME, "ceil", "x"}, + {LUA_MATHLIBNAME, "cos", "rads"}, + {LUA_MATHLIBNAME, "cosh", "x"}, + {LUA_MATHLIBNAME, "deg", "rads"}, + {LUA_MATHLIBNAME, "exp", "x"}, + {LUA_MATHLIBNAME, "floor", "x"}, + {LUA_MATHLIBNAME, "fmod", "x,y"}, + {LUA_MATHLIBNAME, "frexp", "x"}, + {LUA_MATHLIBNAME, "ldexp", "m,e"}, + {LUA_MATHLIBNAME, "log", "x"}, + {LUA_MATHLIBNAME, "log10", "x"}, + {LUA_MATHLIBNAME, "max", "x,..."}, + {LUA_MATHLIBNAME, "min", "x,..."}, + {LUA_MATHLIBNAME, "modf", "x"}, + {LUA_MATHLIBNAME, "pow", "x,y"}, + {LUA_MATHLIBNAME, "rad", "degs"}, + {LUA_MATHLIBNAME, "random", "[m[,n]]"}, + {LUA_MATHLIBNAME, "randomseed", "x"}, + {LUA_MATHLIBNAME, "sin", "rads"}, + {LUA_MATHLIBNAME, "sinh", "x"}, + {LUA_MATHLIBNAME, "sqrt", "x"}, + {LUA_MATHLIBNAME, "tan", "rads"}, + {LUA_MATHLIBNAME, "tanh", "x"}, + {LUA_IOLIBNAME, "close", "[file]"}, + {LUA_IOLIBNAME, "flush", ""}, + {LUA_IOLIBNAME, "input", "[file]"}, + {LUA_IOLIBNAME, "lines", "[filename]"}, + {LUA_IOLIBNAME, "open", "filename[,mode=\"r\"]"}, + {LUA_IOLIBNAME, "output", "[file]"}, + {LUA_IOLIBNAME, "popen", "prog,[model]"}, + {LUA_IOLIBNAME, "read", "..."}, + {LUA_IOLIBNAME, "tmpfile", ""}, + {LUA_IOLIBNAME, "type", "obj"}, + {LUA_IOLIBNAME, "write", "..."}, + {LUA_OSLIBNAME, "clock", ""}, + {LUA_OSLIBNAME, "date", "[format[,time]]"}, + {LUA_OSLIBNAME, "difftime", "t2,t1"}, + {LUA_OSLIBNAME, "execute", "[command]"}, + {LUA_OSLIBNAME, "exit", "[code]"}, + {LUA_OSLIBNAME, "getenv", "varname"}, + {LUA_OSLIBNAME, "remove", "filename"}, + {LUA_OSLIBNAME, "rename", "oldname,newname"}, + {LUA_OSLIBNAME, "setlocale", "locale[,category]"}, + {LUA_OSLIBNAME, "time", "[timetable]"}, + {LUA_OSLIBNAME, "tmpname", ""}, + {LUA_DBLIBNAME, "debug", ""}, + {LUA_DBLIBNAME, "getfenv", "o"}, + {LUA_DBLIBNAME, "gethook", "[thread]"}, + {LUA_DBLIBNAME, "getinfo", "[thread,]function[,what]"}, + {LUA_DBLIBNAME, "getlocal", "[thread,]level,local"}, + {LUA_DBLIBNAME, "getmetatable", "[object]"}, + {LUA_DBLIBNAME, "getregistry", ""}, + {LUA_DBLIBNAME, "getupvalue", "func,up"}, + {LUA_DBLIBNAME, "setfenv", "object,table"}, + {LUA_DBLIBNAME, "sethook", "[thread,]hook,mask[,count]"}, + {LUA_DBLIBNAME, "setlocal", "[thread,]level,local,value"}, + {LUA_DBLIBNAME, "setmetatable", "object,table"}, + {LUA_DBLIBNAME, "setupvalue", "func,up,value"}, + {LUA_DBLIBNAME, "traceback", "[thread,][message][,level]"}, + {LUA_TABLIBNAME, "concat", "table[,sep[,i[,j]]]"}, + {LUA_TABLIBNAME, "insert", "table,[pos,]value"}, + {LUA_TABLIBNAME, "maxn", "table"}, + {LUA_TABLIBNAME, "remove", "table[,pos]"}, + {LUA_TABLIBNAME, "sort", "table[,comp]"}, + {LUA_TABLIBNAME, "foreach", "table,func"}, + {LUA_TABLIBNAME, "foreachi", "table,func"}, + {LUA_TABLIBNAME, "getn", "table"}, + {LUA_TABLIBNAME, "maxn", "table"}, + {LUA_TABLIBNAME, "setn", "table,value"}, // I know some of these are obsolete but they should still have argument info if they're exposed to the user + {LUA_FILEHANDLE, "setvbuf", "mode[,size]", true}, + {LUA_FILEHANDLE, "lines", "", true}, + {LUA_FILEHANDLE, "read", "...", true}, + {LUA_FILEHANDLE, "flush", "", true}, + {LUA_FILEHANDLE, "seek", "[whence][,offset]", true}, + {LUA_FILEHANDLE, "write", "...", true}, + {LUA_FILEHANDLE, "__tostring", "obj", true}, + {LUA_FILEHANDLE, "__gc", "", true}, + {"_LOADLIB", "__gc", "", true}, +}; + +void registerLibs(lua_State* L) +{ + luaL_openlibs(L); + + luaL_register(L, "emu", emulib); + luaL_register(L, "gui", guilib); + luaL_register(L, "stylus", styluslib); + luaL_register(L, "savestate", statelib); + luaL_register(L, "memory", memorylib); + luaL_register(L, "joypad", joylib); // for game input + luaL_register(L, "input", inputlib); // for user input + luaL_register(L, "movie", movielib); + luaL_register(L, "sound", soundlib); + + lua_settop(L, 0); // clean the stack, because each call to luaL_register leaves a table on top + + // register a few utility functions outside of libraries (in the global namespace) + lua_register(L, "print", print); + lua_register(L, "tostring", tostring); + lua_register(L, "addressof", addressof); + lua_register(L, "copytable", copytable); + lua_register(L, "AND", bitand); + lua_register(L, "OR", bitor); + lua_register(L, "XOR", bitxor); + lua_register(L, "SHIFT", bitshift); + lua_register(L, "BIT", bitbit); + + // populate s_cFuncInfoMap the first time + static bool once = true; + if(once) + { + once = false; + + for(int i = 0; i < sizeof(cFuncInfo)/sizeof(*cFuncInfo); i++) + { + const CFuncInfo& cfi = cFuncInfo[i]; + if(cfi.registry) + { + lua_getregistry(L); + lua_getfield(L, -1, cfi.library); + lua_remove(L, -2); + lua_getfield(L, -1, cfi.name); + lua_remove(L, -2); + } + else if(cfi.library) + { + lua_getfield(L, LUA_GLOBALSINDEX, cfi.library); + lua_getfield(L, -1, cfi.name); + lua_remove(L, -2); + } + else + { + lua_getfield(L, LUA_GLOBALSINDEX, cfi.name); + } + + lua_CFunction func = lua_tocfunction(L, -1); + s_cFuncInfoMap[func] = cfi.args; + lua_pop(L, 1); + } + + // deal with some stragglers + lua_getfield(L, LUA_GLOBALSINDEX, "package"); + lua_getfield(L, -1, "loaders"); + lua_remove(L, -2); + if(lua_istable(L, -1)) + { + for(int i=1;;i++) + { + lua_rawgeti(L, -1, i); + lua_CFunction func = lua_tocfunction(L, -1); + lua_pop(L,1); + if(!func) + break; + s_cFuncInfoMap[func] = "name"; + } + } + lua_pop(L,1); + } + + // push arrays for storing hook functions in + for(int i = 0; i < LUAMEMHOOK_COUNT; i++) + { + lua_newtable(L); + lua_setfield(L, LUA_REGISTRYINDEX, luaMemHookTypeStrings[i]); + } +} + +void ResetInfo(LuaContextInfo& info) +{ + info.L = NULL; + info.started = false; + info.running = false; + info.returned = false; + info.crashed = false; + info.restart = false; + info.restartLater = false; + info.worryCount = 0; + info.stopWorrying = false; + info.panic = false; + info.ranExit = false; + info.numDeferredGUIFuncs = 0; + info.ranFrameAdvance = false; + info.transparencyModifier = 255; + info.speedMode = SPEEDMODE_NORMAL; + info.guiFuncsNeedDeferring = false; + info.dataSaveKey = 0; + info.dataLoadKey = 0; + info.dataSaveLoadKeySet = false; + info.rerecordCountingDisabled = false; + info.numMemHooks = 0; + info.persistVars.clear(); + info.newDefaultData.ClearRecords(); +} + +void OpenLuaContext(int uid, void(*print)(int uid, const char* str), void(*onstart)(int uid), void(*onstop)(int uid, bool statusOK)) +{ + LuaContextInfo* newInfo = new LuaContextInfo(); + ResetInfo(*newInfo); + newInfo->print = print; + newInfo->onstart = onstart; + newInfo->onstop = onstop; + luaContextInfo[uid] = newInfo; +} + +void RunLuaScriptFile(int uid, const char* filenameCStr) +{ + if(luaContextInfo.find(uid) == luaContextInfo.end()) + return; + StopLuaScript(uid); + + LuaContextInfo& info = *luaContextInfo[uid]; + +#ifdef USE_INFO_STACK + infoStack.insert(infoStack.begin(), &info); + struct Scope { ~Scope(){ infoStack.erase(infoStack.begin()); } } scope; // doing it like this makes sure that the info stack gets cleaned up even if an exception is thrown +#endif + + info.nextFilename = filenameCStr; + + if(info.running) + { + // it's a little complicated, but... the call to luaL_dofile below + // could call a C function that calls this very function again + // additionally, if that happened then the above call to StopLuaScript + // probably couldn't stop the script yet, so instead of continuing, + // we'll set a flag that tells the first call of this function to loop again + // when the script is able to stop safely + info.restart = true; + return; + } + + do + { + std::string filename = info.nextFilename; + + lua_State* L = lua_open(); +#ifndef USE_INFO_STACK + luaStateToContextMap[L] = &info; +#endif + luaStateToUIDMap[L] = uid; + ResetInfo(info); + info.L = L; + info.guiFuncsNeedDeferring = true; + info.lastFilename = filename; + + SetSaveKey(info, FilenameFromPath(filename.c_str())); + info.dataSaveLoadKeySet = false; + + registerLibs(L); + + // register a function to periodically check for inactivity + lua_sethook(L, LuaRescueHook, LUA_MASKCOUNT, HOOKCOUNT); + + // deferred evaluation table + lua_newtable(L); + lua_setfield(L, LUA_REGISTRYINDEX, deferredGUIIDString); + + info.started = true; + RefreshScriptStartedStatus(); + if(info.onstart) + info.onstart(uid); + info.running = true; + RefreshScriptSpeedStatus(); + info.returned = false; + int errorcode = luaL_dofile(L,filename.c_str()); + info.running = false; + RefreshScriptSpeedStatus(); + info.returned = true; + + if (errorcode) + { + info.crashed = true; + if(info.print) + { + info.print(uid, lua_tostring(L,-1)); + info.print(uid, "\r\n"); + } + else + { + fprintf(stderr, "%s\n", lua_tostring(L,-1)); + } + StopLuaScript(uid); + } + else + { +// Show_Genesis_Screen(); + StopScriptIfFinished(uid, true); + } + } while(info.restart); +} + +void StopScriptIfFinished(int uid, bool justReturned) +{ + LuaContextInfo& info = *luaContextInfo[uid]; + if(!info.returned) + return; + + // the script has returned, but it is not necessarily done running + // because it may have registered a function that it expects to keep getting called + // so check if it has any registered functions and stop the script only if it doesn't + + bool keepAlive = (info.numMemHooks != 0); + for(int calltype = 0; calltype < LUACALL_COUNT && !keepAlive; calltype++) + { + lua_State* L = info.L; + if(L) + { + const char* idstring = luaCallIDStrings[calltype]; + lua_getfield(L, LUA_REGISTRYINDEX, idstring); + bool isFunction = lua_isfunction(L, -1); + lua_pop(L, 1); + + if(isFunction) + keepAlive = true; + } + } + + if(keepAlive) + { + if(justReturned) + { + if(info.print) + info.print(uid, "script returned but is still running registered functions\r\n"); + else + fprintf(stderr, "%s\n", "script returned but is still running registered functions"); + } + } + else + { + if(info.print) + info.print(uid, "script finished running\r\n"); + else + fprintf(stderr, "%s\n", "script finished running"); + + StopLuaScript(uid); + } +} + +void RequestAbortLuaScript(int uid, const char* message) +{ + if(luaContextInfo.find(uid) == luaContextInfo.end()) + return; + LuaContextInfo& info = *luaContextInfo[uid]; + lua_State* L = info.L; + if(L) + { + // this probably isn't the right way to do it + // but calling luaL_error here is positively unsafe + // (it seemingly works fine but sometimes corrupts the emulation state in colorful ways) + // and this works pretty well and is definitely safe, so screw it + info.L->hookcount = 1; // run hook function as soon as possible + info.panic = true; // and call luaL_error once we're inside the hook function + if(message) + { + strncpy(info.panicMessage, message, sizeof(info.panicMessage)); + info.panicMessage[sizeof(info.panicMessage)-1] = 0; + } + else + { + // attach file/line info because this is the case where it's most necessary to see that, + // and often it won't be possible for the later luaL_error call to retrieve it otherwise. + // this means sometimes printing multiple file/line numbers if luaL_error does find something, + // but that's fine since more information is probably better anyway. + luaL_where(L,0); // should be 0 and not 1 here to get useful (on force stop) messages + const char* whereString = lua_tostring(L,-1); + snprintf(info.panicMessage, sizeof(info.panicMessage), "%sscript terminated", whereString); + lua_pop(L,1); + } + } +} + +void SetSaveKey(LuaContextInfo& info, const char* key) +{ + info.dataSaveKey = crc32(0, (const unsigned char*)key, strlen(key)); + + if(!info.dataSaveLoadKeySet) + { + info.dataLoadKey = info.dataSaveKey; + info.dataSaveLoadKeySet = true; + } +} +void SetLoadKey(LuaContextInfo& info, const char* key) +{ + info.dataLoadKey = crc32(0, (const unsigned char*)key, strlen(key)); + + if(!info.dataSaveLoadKeySet) + { + info.dataSaveKey = info.dataLoadKey; + info.dataSaveLoadKeySet = true; + } +} + +void HandleCallbackError(lua_State* L, LuaContextInfo& info, int uid, bool stopScript) +{ + info.crashed = true; + if(L->errfunc || L->errorJmp) + luaL_error(L, lua_tostring(L,-1)); + else + { + if(info.print) + { + info.print(uid, lua_tostring(L,-1)); + info.print(uid, "\r\n"); + } + else + { + fprintf(stderr, "%s\n", lua_tostring(L,-1)); + } + if(stopScript) + StopLuaScript(uid); + } +} + +void CallExitFunction(int uid) +{ + LuaContextInfo& info = *luaContextInfo[uid]; + lua_State* L = info.L; + + if(!L) + return; + + dontworry(info); + + // first call the registered exit function if there is one + if(!info.ranExit) + { + info.ranExit = true; + +#ifdef USE_INFO_STACK + infoStack.insert(infoStack.begin(), &info); + struct Scope { ~Scope(){ infoStack.erase(infoStack.begin()); } } scope; +#endif + + lua_settop(L, 0); + lua_getfield(L, LUA_REGISTRYINDEX, luaCallIDStrings[LUACALL_BEFOREEXIT]); + + int errorcode = 0; + if (lua_isfunction(L, -1)) + { + bool wasRunning = info.running; + info.running = true; + RefreshScriptSpeedStatus(); + + bool wasPanic = info.panic; + info.panic = false; // otherwise we could barely do anything in the exit function + + errorcode = lua_pcall(L, 0, 0, 0); + + info.panic |= wasPanic; // restore panic + + info.running = wasRunning; + RefreshScriptSpeedStatus(); + } + + // save persisted variable info after the exit function runs (even if it crashed) + { + // gather the final value of the variables we're supposed to persist + LuaSaveData newExitData; + { + int numPersistVars = info.persistVars.size(); + for(int i = 0; i < numPersistVars; i++) + { + const char* varName = info.persistVars[i].c_str(); + lua_getfield(L, LUA_GLOBALSINDEX, varName); + int type = lua_type(L,-1); + unsigned int varNameCRC = crc32(0, (const unsigned char*)varName, strlen(varName)); + newExitData.SaveRecordPartial(uid, varNameCRC, -1); + lua_pop(L,1); + } + } + + char path [1024] = {0}; + char* pathTypeChrPtr = ConstructScriptSaveDataPath(path, 1024, info); + + *pathTypeChrPtr = 'd'; + if(info.newDefaultData.recordList) + { + FILE* defaultsFile = fopen(path, "wb"); + if(defaultsFile) + { + info.newDefaultData.ExportRecords(defaultsFile); + fclose(defaultsFile); + } + } + else unlink(path); + + *pathTypeChrPtr = 'e'; + if(newExitData.recordList) + { + FILE* persistFile = fopen(path, "wb"); + if(persistFile) + { + newExitData.ExportRecords(persistFile); + fclose(persistFile); + } + } + else unlink(path); + } + + if (errorcode) + HandleCallbackError(L,info,uid,false); + + } +} + +void StopLuaScript(int uid) +{ + LuaContextInfo* infoPtr = luaContextInfo[uid]; + if(!infoPtr) + return; + + LuaContextInfo& info = *infoPtr; + + if(info.running) + { + // if it's currently running then we can't stop it now without crashing + // so the best we can do is politely request for it to go kill itself + RequestAbortLuaScript(uid); + return; + } + + lua_State* L = info.L; + if(L) + { + CallExitFunction(uid); + + if(info.onstop) + { + info.stopWorrying = true, info.worryCount++, dontworry(info); // clear "busy" status + info.onstop(uid, !info.crashed); // must happen before closing L and after the exit function, otherwise the final GUI state of the script won't be shown properly or at all + } + + if(info.started) // this check is necessary + { + lua_close(L); +#ifndef USE_INFO_STACK + luaStateToContextMap.erase(L); +#endif + luaStateToUIDMap.erase(L); + info.L = NULL; + info.started = false; + + info.numMemHooks = 0; + for(int i = 0; i < LUAMEMHOOK_COUNT; i++) + CalculateMemHookRegions((LuaMemHookType)i); + } + RefreshScriptStartedStatus(); + } +} + +void CloseLuaContext(int uid) +{ + StopLuaScript(uid); + delete luaContextInfo[uid]; + luaContextInfo.erase(uid); +} + + +// the purpose of this structure is to provide a way of +// QUICKLY determining whether a memory address range has a hook associated with it, +// with a bias toward fast rejection because the majority of addresses will not be hooked. +// (it must not use any part of Lua or perform any per-script operations, +// otherwise it would definitely be too slow.) +// calculating the regions when a hook is added/removed may be slow, +// but this is an intentional tradeoff to obtain a high speed of checking during later execution +struct TieredRegion +{ + template + struct Region + { + struct Island + { + unsigned int start; + unsigned int end; + __forceinline bool Contains(unsigned int address, int size) const { return address < end && address+size > start; } + }; + std::vector islands; + + void Calculate(const std::vector& bytes) + { + islands.clear(); + + unsigned int lastEnd = ~0; + + std::vector::const_iterator iter = bytes.begin(); + std::vector::const_iterator end = bytes.end(); + for(; iter != end; ++iter) + { + unsigned int addr = *iter; + if(addr < lastEnd || addr > lastEnd + (long long)maxGap) + { + islands.push_back(Island()); + islands.back().start = addr; + } + islands.back().end = addr+1; + lastEnd = addr+1; + } + } + + bool Contains(unsigned int address, int size) const + { + std::vector::const_iterator iter = islands.begin(); + std::vector::const_iterator end = islands.end(); + for(; iter != end; ++iter) + if(iter->Contains(address, size)) + return true; + return false; + } + }; + + Region<0xFFFFFFFF> broad; + Region<0x1000> mid; + Region<0> narrow; + + void Calculate(std::vector& bytes) + { + std::sort(bytes.begin(), bytes.end()); + + broad.Calculate(bytes); + mid.Calculate(bytes); + narrow.Calculate(bytes); + } + + TieredRegion() + { + Calculate(std::vector()); + } + + __forceinline int NotEmpty() + { + return broad.islands.size(); + } + + // note: it is illegal to call this if NotEmpty() returns 0 + __forceinline bool Contains(unsigned int address, int size) + { + return broad.islands[0].Contains(address,size) && + mid.Contains(address,size) && + narrow.Contains(address,size); + } +}; +TieredRegion hookedRegions [LUAMEMHOOK_COUNT]; + + +static void CalculateMemHookRegions(LuaMemHookType hookType) +{ + std::vector hookedBytes; + std::map::iterator iter = luaContextInfo.begin(); + std::map::iterator end = luaContextInfo.end(); + while(iter != end) + { + LuaContextInfo& info = *iter->second; + if(info.numMemHooks) + { + lua_State* L = info.L; + if(L) + { + lua_settop(L, 0); + lua_getfield(L, LUA_REGISTRYINDEX, luaMemHookTypeStrings[hookType]); + lua_pushnil(L); + while(lua_next(L, -2)) + { + if(lua_isfunction(L, -1)) + { + unsigned int addr = lua_tointeger(L, -2); + hookedBytes.push_back(addr); + } + lua_pop(L, 1); + } + lua_settop(L, 0); + } + } + ++iter; + } + hookedRegions[hookType].Calculate(hookedBytes); +} + + + + + +static void CallRegisteredLuaMemHook_LuaMatch(unsigned int address, int size, unsigned int value, LuaMemHookType hookType) +{ + std::map::iterator iter = luaContextInfo.begin(); + std::map::iterator end = luaContextInfo.end(); + while(iter != end) + { + LuaContextInfo& info = *iter->second; + if(info.numMemHooks) + { + lua_State* L = info.L; + if(L && !info.panic) + { +#ifdef USE_INFO_STACK + infoStack.insert(infoStack.begin(), &info); + struct Scope { ~Scope(){ infoStack.erase(infoStack.begin()); } } scope; +#endif + lua_settop(L, 0); + lua_getfield(L, LUA_REGISTRYINDEX, luaMemHookTypeStrings[hookType]); + for(int i = address; i != address+size; i++) + { + lua_rawgeti(L, -1, i); + if (lua_isfunction(L, -1)) + { + bool wasRunning = info.running; + info.running = true; + RefreshScriptSpeedStatus(); + lua_pushinteger(L, address); + lua_pushinteger(L, size); + int errorcode = lua_pcall(L, 2, 0, 0); + info.running = wasRunning; + RefreshScriptSpeedStatus(); + if (errorcode) + { + int uid = iter->first; + HandleCallbackError(L,info,uid,true); + } + break; + } + else + { + lua_pop(L,1); + } + } + lua_settop(L, 0); + } + } + ++iter; + } +} +void CallRegisteredLuaMemHook(unsigned int address, int size, unsigned int value, LuaMemHookType hookType) +{ + // performance critical! (called VERY frequently) + // I suggest timing a large number of calls to this function in Release if you change anything in here, + // before and after, because even the most innocent change can make it become 30% to 400% slower. + // a good amount to test is: 100000000 calls with no hook set, and another 100000000 with a hook set. + // (on my system that consistently took 200 ms total in the former case and 350 ms total in the latter case) + if(hookedRegions[hookType].NotEmpty()) + { + if((hookType <= LUAMEMHOOK_EXEC) && (address >= 0xE00000)) + address |= 0xFF0000; // account for mirroring of RAM + if(hookedRegions[hookType].Contains(address, size)) + CallRegisteredLuaMemHook_LuaMatch(address, size, value, hookType); // something has hooked this specific address + } +} + + + +void CallRegisteredLuaFunctions(LuaCallID calltype) +{ + assert((unsigned int)calltype < (unsigned int)LUACALL_COUNT); + const char* idstring = luaCallIDStrings[calltype]; + + std::map::iterator iter = luaContextInfo.begin(); + std::map::iterator end = luaContextInfo.end(); + while(iter != end) + { + int uid = iter->first; + LuaContextInfo& info = *iter->second; + lua_State* L = info.L; + if(L && (!info.panic || calltype == LUACALL_BEFOREEXIT)) + { +#ifdef USE_INFO_STACK + infoStack.insert(infoStack.begin(), &info); + struct Scope { ~Scope(){ infoStack.erase(infoStack.begin()); } } scope; +#endif + // handle deferred GUI function calls and disabling deferring when unnecessary + if(calltype == LUACALL_AFTEREMULATIONGUI || calltype == LUACALL_AFTEREMULATION) + info.guiFuncsNeedDeferring = false; + if(calltype == LUACALL_AFTEREMULATIONGUI) + CallDeferredFunctions(L, deferredGUIIDString); + + lua_settop(L, 0); + lua_getfield(L, LUA_REGISTRYINDEX, idstring); + + if (lua_isfunction(L, -1)) + { + bool wasRunning = info.running; + info.running = true; + RefreshScriptSpeedStatus(); + int errorcode = lua_pcall(L, 0, 0, 0); + info.running = wasRunning; + RefreshScriptSpeedStatus(); + if (errorcode) + HandleCallbackError(L,info,uid,true); + } + else + { + lua_pop(L, 1); + } + + info.guiFuncsNeedDeferring = true; + } + + ++iter; + } +} + +void CallRegisteredLuaSaveFunctions(int savestateNumber, LuaSaveData& saveData) +{ + const char* idstring = luaCallIDStrings[LUACALL_BEFORESAVE]; + + std::map::iterator iter = luaContextInfo.begin(); + std::map::iterator end = luaContextInfo.end(); + while(iter != end) + { + int uid = iter->first; + LuaContextInfo& info = *iter->second; + lua_State* L = info.L; + if(L) + { +#ifdef USE_INFO_STACK + infoStack.insert(infoStack.begin(), &info); + struct Scope { ~Scope(){ infoStack.erase(infoStack.begin()); } } scope; +#endif + + lua_settop(L, 0); + lua_getfield(L, LUA_REGISTRYINDEX, idstring); + + if (lua_isfunction(L, -1)) + { + bool wasRunning = info.running; + info.running = true; + RefreshScriptSpeedStatus(); + lua_pushinteger(L, savestateNumber); + int errorcode = lua_pcall(L, 1, LUA_MULTRET, 0); + info.running = wasRunning; + RefreshScriptSpeedStatus(); + if (errorcode) + HandleCallbackError(L,info,uid,true); + saveData.SaveRecord(uid, info.dataSaveKey); + } + else + { + lua_pop(L, 1); + } + } + + ++iter; + } +} + + +void CallRegisteredLuaLoadFunctions(int savestateNumber, const LuaSaveData& saveData) +{ + const char* idstring = luaCallIDStrings[LUACALL_AFTERLOAD]; + + std::map::iterator iter = luaContextInfo.begin(); + std::map::iterator end = luaContextInfo.end(); + while(iter != end) + { + int uid = iter->first; + LuaContextInfo& info = *iter->second; + lua_State* L = info.L; + if(L) + { +#ifdef USE_INFO_STACK + infoStack.insert(infoStack.begin(), &info); + struct Scope { ~Scope(){ infoStack.erase(infoStack.begin()); } } scope; +#endif + + lua_settop(L, 0); + lua_getfield(L, LUA_REGISTRYINDEX, idstring); + + if (lua_isfunction(L, -1)) + { + bool wasRunning = info.running; + info.running = true; + RefreshScriptSpeedStatus(); + + // since the scriptdata can be very expensive to load + // (e.g. the registered save function returned some huge tables) + // check the number of parameters the registered load function expects + // and don't bother loading the parameters it wouldn't receive anyway + int numParamsExpected = (L->top - 1)->value.gc->cl.l.p->numparams; + if(numParamsExpected) numParamsExpected--; // minus one for the savestate number we always pass in + + int prevGarbage = lua_gc(L, LUA_GCCOUNT, 0); + + lua_pushinteger(L, savestateNumber); + saveData.LoadRecord(uid, info.dataLoadKey, numParamsExpected); + int n = lua_gettop(L) - 1; + + int errorcode = lua_pcall(L, n, 0, 0); + info.running = wasRunning; + RefreshScriptSpeedStatus(); + if (errorcode) + HandleCallbackError(L,info,uid,true); + else + { + int newGarbage = lua_gc(L, LUA_GCCOUNT, 0); + if(newGarbage - prevGarbage > 50) + { + // now seems to be a very good time to run the garbage collector + // it might take a while now but that's better than taking 10 whiles 9 loads from now + lua_gc(L, LUA_GCCOLLECT, 0); + } + } + } + else + { + lua_pop(L, 1); + } + } + + ++iter; + } +} + +static const unsigned char* s_dbg_dataStart = NULL; +static int s_dbg_dataSize = 0; + + +// can't remember what the best way of doing this is... +#if defined(i386) || defined(__i386) || defined(__i386__) || defined(M_I86) || defined(_M_IX86) || defined(_WIN32) + #define IS_LITTLE_ENDIAN +#endif + +// push a value's bytes onto the output stack +template +void PushBinaryItem(T item, std::vector& output) +{ + unsigned char* buf = (unsigned char*)&item; +#ifdef IS_LITTLE_ENDIAN + for(int i = sizeof(T); i; i--) + output.push_back(*buf++); +#else + int vecsize = output.size(); + for(int i = sizeof(T); i; i--) + output.insert(output.begin() + vecsize, *buf++); +#endif +} +// read a value from the byte stream and advance the stream by its size +template +T AdvanceByteStream(const unsigned char*& data, unsigned int& remaining) +{ +#ifdef IS_LITTLE_ENDIAN + T rv = *(T*)data; + data += sizeof(T); +#else + T rv; unsigned char* rvptr = (unsigned char*)&rv; + for(int i = sizeof(T)-1; i>=0; i--) + rvptr[i] = *data++; +#endif + remaining -= sizeof(T); + return rv; +} +// advance the byte stream by a certain size without reading a value +void AdvanceByteStream(const unsigned char*& data, unsigned int& remaining, int amount) +{ + data += amount; + remaining -= amount; +} + +#define LUAEXT_TLONG 30 // 0x1E // 4-byte signed integer +#define LUAEXT_TUSHORT 31 // 0x1F // 2-byte unsigned integer +#define LUAEXT_TSHORT 32 // 0x20 // 2-byte signed integer +#define LUAEXT_TBYTE 33 // 0x21 // 1-byte unsigned integer +#define LUAEXT_TNILS 34 // 0x22 // multiple nils represented by a 4-byte integer (warning: becomes multiple stack entities) +#define LUAEXT_TTABLE 0x40 // 0x40 through 0x4F // tables of different sizes: +#define LUAEXT_BITS_1A 0x01 // size of array part fits in a 1-byte unsigned integer +#define LUAEXT_BITS_2A 0x02 // size of array part fits in a 2-byte unsigned integer +#define LUAEXT_BITS_4A 0x03 // size of array part fits in a 4-byte unsigned integer +#define LUAEXT_BITS_1H 0x04 // size of hash part fits in a 1-byte unsigned integer +#define LUAEXT_BITS_2H 0x08 // size of hash part fits in a 2-byte unsigned integer +#define LUAEXT_BITS_4H 0x0C // size of hash part fits in a 4-byte unsigned integer +#define BITMATCH(x,y) (((x) & (y)) == (y)) + +static void PushNils(std::vector& output, int& nilcount) +{ + int count = nilcount; + nilcount = 0; + + static const int minNilsWorthEncoding = 6; // because a LUAEXT_TNILS entry is 5 bytes + + if(count < minNilsWorthEncoding) + { + for(int i = 0; i < count; i++) + output.push_back(LUA_TNIL); + } + else + { + output.push_back(LUAEXT_TNILS); + PushBinaryItem(count, output); + } +} + + +static void LuaStackToBinaryConverter(lua_State* L, int i, std::vector& output) +{ + int type = lua_type(L, i); + + // the first byte of every serialized item says what Lua type it is + output.push_back(type & 0xFF); + + switch(type) + { + default: + { + //printf("wrote unknown type %d (0x%x)\n", type, type); + //assert(0); + + LuaContextInfo& info = GetCurrentInfo(); + if(info.print) + { + char errmsg [1024]; + sprintf(errmsg, "values of type \"%s\" are not allowed to be returned from registered save functions.\r\n", luaL_typename(L,i)); + info.print(luaStateToUIDMap[L], errmsg); + } + else + { + fprintf(stderr, "values of type \"%s\" are not allowed to be returned from registered save functions.\n", luaL_typename(L,i)); + } + } + break; + case LUA_TNIL: + // no information necessary beyond the type + break; + case LUA_TBOOLEAN: + // serialize as 0 or 1 + output.push_back(lua_toboolean(L,i)); + break; + case LUA_TSTRING: + // serialize as a 0-terminated string of characters + { + const char* str = lua_tostring(L,i); + while(*str) + output.push_back(*str++); + output.push_back('\0'); + } + break; + case LUA_TNUMBER: + { + double num = (double)lua_tonumber(L,i); + INT32 inum = (INT32)lua_tointeger(L,i); + if(num != inum) + { + PushBinaryItem(num, output); + } + else + { + if((inum & ~0xFF) == 0) + type = LUAEXT_TBYTE; + else if((UINT16)(inum & 0xFFFF) == inum) + type = LUAEXT_TUSHORT; + else if((INT16)(inum & 0xFFFF) == inum) + type = LUAEXT_TSHORT; + else + type = LUAEXT_TLONG; + output.back() = type; + switch(type) + { + case LUAEXT_TLONG: + PushBinaryItem(inum, output); + break; + case LUAEXT_TUSHORT: + PushBinaryItem(inum, output); + break; + case LUAEXT_TSHORT: + PushBinaryItem(inum, output); + break; + case LUAEXT_TBYTE: + output.push_back(inum); + break; + } + } + } + break; + case LUA_TTABLE: + // serialize as a type that describes how many bytes are used for storing the counts, + // followed by the number of array entries if any, then the number of hash entries if any, + // then a Lua value per array entry, then a (key,value) pair of Lua values per hashed entry + // note that the structure of table references are not faithfully serialized (yet) + { + int outputTypeIndex = output.size() - 1; + int arraySize = 0; + int hashSize = 0; + + if(lua_checkstack(L, 4) && std::find(s_tableAddressStack.begin(), s_tableAddressStack.end(), lua_topointer(L,i)) == s_tableAddressStack.end()) + { + s_tableAddressStack.push_back(lua_topointer(L,i)); + struct Scope { ~Scope(){ s_tableAddressStack.pop_back(); } } scope; + + bool wasnil = false; + int nilcount = 0; + arraySize = lua_objlen(L, i); + int arrayValIndex = lua_gettop(L) + 1; + for(int j = 1; j <= arraySize; j++) + { + lua_rawgeti(L, i, j); + bool isnil = lua_isnil(L, arrayValIndex); + if(isnil) + nilcount++; + else + { + if(wasnil) + PushNils(output, nilcount); + LuaStackToBinaryConverter(L, arrayValIndex, output); + } + lua_pop(L, 1); + wasnil = isnil; + } + if(wasnil) + PushNils(output, nilcount); + + if(arraySize) + lua_pushinteger(L, arraySize); // before first key + else + lua_pushnil(L); // before first key + + int keyIndex = lua_gettop(L); + int valueIndex = keyIndex + 1; + while(lua_next(L, i)) + { + assert(lua_type(L, keyIndex) && "nil key in Lua table, impossible"); + assert(lua_type(L, valueIndex) && "nil value in Lua table, impossible"); + LuaStackToBinaryConverter(L, keyIndex, output); + LuaStackToBinaryConverter(L, valueIndex, output); + lua_pop(L, 1); + hashSize++; + } + } + + int outputType = LUAEXT_TTABLE; + if(arraySize & 0xFFFF0000) + outputType |= LUAEXT_BITS_4A; + else if(arraySize & 0xFF00) + outputType |= LUAEXT_BITS_2A; + else if(arraySize & 0xFF) + outputType |= LUAEXT_BITS_1A; + if(hashSize & 0xFFFF0000) + outputType |= LUAEXT_BITS_4H; + else if(hashSize & 0xFF00) + outputType |= LUAEXT_BITS_2H; + else if(hashSize & 0xFF) + outputType |= LUAEXT_BITS_1H; + output[outputTypeIndex] = outputType; + + int insertIndex = outputTypeIndex; + if(BITMATCH(outputType,LUAEXT_BITS_4A) || BITMATCH(outputType,LUAEXT_BITS_2A) || BITMATCH(outputType,LUAEXT_BITS_1A)) + output.insert(output.begin() + (++insertIndex), arraySize & 0xFF); + if(BITMATCH(outputType,LUAEXT_BITS_4A) || BITMATCH(outputType,LUAEXT_BITS_2A)) + output.insert(output.begin() + (++insertIndex), (arraySize & 0xFF00) >> 8); + if(BITMATCH(outputType,LUAEXT_BITS_4A)) + output.insert(output.begin() + (++insertIndex), (arraySize & 0x00FF0000) >> 16), + output.insert(output.begin() + (++insertIndex), (arraySize & 0xFF000000) >> 24); + if(BITMATCH(outputType,LUAEXT_BITS_4H) || BITMATCH(outputType,LUAEXT_BITS_2H) || BITMATCH(outputType,LUAEXT_BITS_1H)) + output.insert(output.begin() + (++insertIndex), hashSize & 0xFF); + if(BITMATCH(outputType,LUAEXT_BITS_4H) || BITMATCH(outputType,LUAEXT_BITS_2H)) + output.insert(output.begin() + (++insertIndex), (hashSize & 0xFF00) >> 8); + if(BITMATCH(outputType,LUAEXT_BITS_4H)) + output.insert(output.begin() + (++insertIndex), (hashSize & 0x00FF0000) >> 16), + output.insert(output.begin() + (++insertIndex), (hashSize & 0xFF000000) >> 24); + + } break; + } +} + + +// complements LuaStackToBinaryConverter +void BinaryToLuaStackConverter(lua_State* L, const unsigned char*& data, unsigned int& remaining) +{ + assert(s_dbg_dataSize - (data - s_dbg_dataStart) == remaining); + + unsigned char type = AdvanceByteStream(data, remaining); + + switch(type) + { + default: + { + //printf("read unknown type %d (0x%x)\n", type, type); + //assert(0); + + LuaContextInfo& info = GetCurrentInfo(); + if(info.print) + { + char errmsg [1024]; + if(type <= 10 && type != LUA_TTABLE) + sprintf(errmsg, "values of type \"%s\" are not allowed to be loaded into registered load functions. The save state's Lua save data file might be corrupted.\r\n", lua_typename(L,type)); + else + sprintf(errmsg, "The save state's Lua save data file seems to be corrupted.\r\n"); + info.print(luaStateToUIDMap[L], errmsg); + } + else + { + if(type <= 10 && type != LUA_TTABLE) + fprintf(stderr, "values of type \"%s\" are not allowed to be loaded into registered load functions. The save state's Lua save data file might be corrupted.\n", lua_typename(L,type)); + else + fprintf(stderr, "The save state's Lua save data file seems to be corrupted.\n"); + } + } + break; + case LUA_TNIL: + lua_pushnil(L); + break; + case LUA_TBOOLEAN: + lua_pushboolean(L, AdvanceByteStream(data, remaining)); + break; + case LUA_TSTRING: + lua_pushstring(L, (const char*)data); + AdvanceByteStream(data, remaining, strlen((const char*)data) + 1); + break; + case LUA_TNUMBER: + lua_pushnumber(L, AdvanceByteStream(data, remaining)); + break; + case LUAEXT_TLONG: + lua_pushinteger(L, AdvanceByteStream(data, remaining)); + break; + case LUAEXT_TUSHORT: + lua_pushinteger(L, AdvanceByteStream(data, remaining)); + break; + case LUAEXT_TSHORT: + lua_pushinteger(L, AdvanceByteStream(data, remaining)); + break; + case LUAEXT_TBYTE: + lua_pushinteger(L, AdvanceByteStream(data, remaining)); + break; + case LUAEXT_TTABLE: + case LUAEXT_TTABLE | LUAEXT_BITS_1A: + case LUAEXT_TTABLE | LUAEXT_BITS_2A: + case LUAEXT_TTABLE | LUAEXT_BITS_4A: + case LUAEXT_TTABLE | LUAEXT_BITS_1H: + case LUAEXT_TTABLE | LUAEXT_BITS_2H: + case LUAEXT_TTABLE | LUAEXT_BITS_4H: + case LUAEXT_TTABLE | LUAEXT_BITS_1A | LUAEXT_BITS_1H: + case LUAEXT_TTABLE | LUAEXT_BITS_2A | LUAEXT_BITS_1H: + case LUAEXT_TTABLE | LUAEXT_BITS_4A | LUAEXT_BITS_1H: + case LUAEXT_TTABLE | LUAEXT_BITS_1A | LUAEXT_BITS_2H: + case LUAEXT_TTABLE | LUAEXT_BITS_2A | LUAEXT_BITS_2H: + case LUAEXT_TTABLE | LUAEXT_BITS_4A | LUAEXT_BITS_2H: + case LUAEXT_TTABLE | LUAEXT_BITS_1A | LUAEXT_BITS_4H: + case LUAEXT_TTABLE | LUAEXT_BITS_2A | LUAEXT_BITS_4H: + case LUAEXT_TTABLE | LUAEXT_BITS_4A | LUAEXT_BITS_4H: + { + unsigned int arraySize = 0; + if(BITMATCH(type,LUAEXT_BITS_4A) || BITMATCH(type,LUAEXT_BITS_2A) || BITMATCH(type,LUAEXT_BITS_1A)) + arraySize |= AdvanceByteStream(data, remaining); + if(BITMATCH(type,LUAEXT_BITS_4A) || BITMATCH(type,LUAEXT_BITS_2A)) + arraySize |= ((UINT16)AdvanceByteStream(data, remaining)) << 8; + if(BITMATCH(type,LUAEXT_BITS_4A)) + arraySize |= ((UINT32)AdvanceByteStream(data, remaining)) << 16, + arraySize |= ((UINT32)AdvanceByteStream(data, remaining)) << 24; + + unsigned int hashSize = 0; + if(BITMATCH(type,LUAEXT_BITS_4H) || BITMATCH(type,LUAEXT_BITS_2H) || BITMATCH(type,LUAEXT_BITS_1H)) + hashSize |= AdvanceByteStream(data, remaining); + if(BITMATCH(type,LUAEXT_BITS_4H) || BITMATCH(type,LUAEXT_BITS_2H)) + hashSize |= ((UINT16)AdvanceByteStream(data, remaining)) << 8; + if(BITMATCH(type,LUAEXT_BITS_4H)) + hashSize |= ((UINT32)AdvanceByteStream(data, remaining)) << 16, + hashSize |= ((UINT32)AdvanceByteStream(data, remaining)) << 24; + + lua_createtable(L, arraySize, hashSize); + + unsigned int n = 1; + while(n <= arraySize) + { + if(*data == LUAEXT_TNILS) + { + AdvanceByteStream(data, remaining, 1); + n += AdvanceByteStream(data, remaining); + } + else + { + BinaryToLuaStackConverter(L, data, remaining); // push value + lua_rawseti(L, -2, n); // table[n] = value + n++; + } + } + + for(unsigned int h = 1; h <= hashSize; h++) + { + BinaryToLuaStackConverter(L, data, remaining); // push key + BinaryToLuaStackConverter(L, data, remaining); // push value + lua_rawset(L, -3); // table[key] = value + } + } + break; + } +} + +static const unsigned char luaBinaryMajorVersion = 9; +static const unsigned char luaBinaryMinorVersion = 1; + +unsigned char* LuaStackToBinary(lua_State* L, unsigned int& size) +{ + int n = lua_gettop(L); + if(n == 0) + return NULL; + + std::vector output; + output.push_back(luaBinaryMajorVersion); + output.push_back(luaBinaryMinorVersion); + + for(int i = 1; i <= n; i++) + LuaStackToBinaryConverter(L, i, output); + + unsigned char* rv = new unsigned char [output.size()]; + memcpy(rv, &output.front(), output.size()); + size = output.size(); + return rv; +} + +void BinaryToLuaStack(lua_State* L, const unsigned char* data, unsigned int size, unsigned int itemsToLoad) +{ + unsigned char major = *data++; + unsigned char minor = *data++; + size -= 2; + if(luaBinaryMajorVersion != major || luaBinaryMinorVersion != minor) + return; + + while(size > 0 && itemsToLoad > 0) + { + BinaryToLuaStackConverter(L, data, size); + itemsToLoad--; + } +} + +// saves Lua stack into a record and pops it +void LuaSaveData::SaveRecord(int uid, unsigned int key) +{ + LuaContextInfo& info = *luaContextInfo[uid]; + lua_State* L = info.L; + if(!L) + return; + + Record* cur = new Record(); + cur->key = key; + cur->data = LuaStackToBinary(L, cur->size); + cur->next = NULL; + + lua_settop(L,0); + + if(cur->size <= 0) + { + delete cur; + return; + } + + Record* last = recordList; + while(last && last->next) + last = last->next; + if(last) + last->next = cur; + else + recordList = cur; +} + +// pushes a record's data onto the Lua stack +void LuaSaveData::LoadRecord(int uid, unsigned int key, unsigned int itemsToLoad) const +{ + LuaContextInfo& info = *luaContextInfo[uid]; + lua_State* L = info.L; + if(!L) + return; + + Record* cur = recordList; + while(cur) + { + if(cur->key == key) + { + s_dbg_dataStart = cur->data; + s_dbg_dataSize = cur->size; + BinaryToLuaStack(L, cur->data, cur->size, itemsToLoad); + return; + } + cur = cur->next; + } +} + +// saves part of the Lua stack (at the given index) into a record and does NOT pop anything +void LuaSaveData::SaveRecordPartial(int uid, unsigned int key, int idx) +{ + LuaContextInfo& info = *luaContextInfo[uid]; + lua_State* L = info.L; + if(!L) + return; + + if(idx < 0) + idx += lua_gettop(L)+1; + + Record* cur = new Record(); + cur->key = key; + cur->next = NULL; + + if(idx <= lua_gettop(L)) + { + std::vector output; + output.push_back(luaBinaryMajorVersion); + output.push_back(luaBinaryMinorVersion); + + LuaStackToBinaryConverter(L, idx, output); + + unsigned char* rv = new unsigned char [output.size()]; + memcpy(rv, &output.front(), output.size()); + cur->size = output.size(); + cur->data = rv; + } + + if(cur->size <= 0) + { + delete cur; + return; + } + + Record* last = recordList; + while(last && last->next) + last = last->next; + if(last) + last->next = cur; + else + recordList = cur; +} + +void fwriteint(unsigned int value, FILE* file) +{ + for(int i=0;i<4;i++) + { + int w = value & 0xFF; + fwrite(&w, 1, 1, file); + value >>= 8; + } +} +void freadint(unsigned int& value, FILE* file) +{ + int rv = 0; + for(int i=0;i<4;i++) + { + int r = 0; + fread(&r, 1, 1, file); + rv |= r << (i*8); + } + value = rv; +} + +// writes all records to an already-open file +void LuaSaveData::ExportRecords(void* fileV) const +{ + FILE* file = (FILE*)fileV; + if(!file) + return; + + Record* cur = recordList; + while(cur) + { + fwriteint(cur->key, file); + fwriteint(cur->size, file); + fwrite(cur->data, cur->size, 1, file); + cur = cur->next; + } +} + +// reads records from an already-open file +void LuaSaveData::ImportRecords(void* fileV) +{ + FILE* file = (FILE*)fileV; + if(!file) + return; + + ClearRecords(); + + Record rec; + Record* cur = &rec; + Record* last = NULL; + while(1) + { + freadint(cur->key, file); + freadint(cur->size, file); + + if(feof(file) || ferror(file)) + break; + + cur->data = new unsigned char [cur->size]; + fread(cur->data, cur->size, 1, file); + + Record* next = new Record(); + memcpy(next, cur, sizeof(Record)); + next->next = NULL; + + if(last) + last->next = next; + else + recordList = next; + last = next; + } +} + +void LuaSaveData::ClearRecords() +{ + Record* cur = recordList; + while(cur) + { + Record* del = cur; + cur = cur->next; + + delete[] del->data; + delete del; + } + + recordList = NULL; +} + + + +void DontWorryLua() // everything's going to be OK +{ + std::map::const_iterator iter = luaContextInfo.begin(); + std::map::const_iterator end = luaContextInfo.end(); + while(iter != end) + { + dontworry(*iter->second); + ++iter; + } +} + +void EnableStopAllLuaScripts(bool enable) +{ + g_stopAllScriptsEnabled = enable; +} + +void StopAllLuaScripts() +{ + if(!g_stopAllScriptsEnabled) + return; + + std::map::const_iterator iter = luaContextInfo.begin(); + std::map::const_iterator end = luaContextInfo.end(); + while(iter != end) + { + int uid = iter->first; + LuaContextInfo& info = *iter->second; + bool wasStarted = info.started; + StopLuaScript(uid); + info.restartLater = wasStarted; + ++iter; + } +} + +void RestartAllLuaScripts() +{ + if(!g_stopAllScriptsEnabled) + return; + + std::map::const_iterator iter = luaContextInfo.begin(); + std::map::const_iterator end = luaContextInfo.end(); + while(iter != end) + { + int uid = iter->first; + LuaContextInfo& info = *iter->second; + if(info.restartLater || info.started) + { + info.restartLater = false; + RunLuaScriptFile(uid, info.lastFilename.c_str()); + } + ++iter; + } +} + +// sets anything that needs to depend on the total number of scripts running +void RefreshScriptStartedStatus() +{ + int numScriptsStarted = 0; + + std::map::const_iterator iter = luaContextInfo.begin(); + std::map::const_iterator end = luaContextInfo.end(); + while(iter != end) + { + LuaContextInfo& info = *iter->second; + if(info.started) + numScriptsStarted++; + ++iter; + } + +// frameadvSkipLagForceDisable = (numScriptsStarted != 0); // disable while scripts are running because currently lag skipping makes lua callbacks get called twice per frame advance + g_numScriptsStarted = numScriptsStarted; +} + +// sets anything that needs to depend on speed mode or running status of scripts +void RefreshScriptSpeedStatus() +{ + g_anyScriptsHighSpeed = false; + + std::map::const_iterator iter = luaContextInfo.begin(); + std::map::const_iterator end = luaContextInfo.end(); + while(iter != end) + { + LuaContextInfo& info = *iter->second; + if(info.running) + if(info.speedMode == SPEEDMODE_TURBO || info.speedMode == SPEEDMODE_MAXIMUM) + g_anyScriptsHighSpeed = true; + ++iter; + } +} + diff --git a/desmume/src/lua-engine.h b/src/lua-engine.h similarity index 96% rename from desmume/src/lua-engine.h rename to src/lua-engine.h index 31846b6c3..253e15513 100644 --- a/desmume/src/lua-engine.h +++ b/src/lua-engine.h @@ -1,95 +1,95 @@ -#ifndef LUA_SCRIPT_H -#define LUA_SCRIPT_H - - -void OpenLuaContext(int uid, void(*print)(int uid, const char* str) = 0, void(*onstart)(int uid) = 0, void(*onstop)(int uid, bool statusOK) = 0); -void RunLuaScriptFile(int uid, const char* filename); -void StopLuaScript(int uid); -void RequestAbortLuaScript(int uid, const char* message = 0); -void CloseLuaContext(int uid); - -enum LuaCallID -{ - LUACALL_BEFOREEMULATION, - LUACALL_AFTEREMULATION, - LUACALL_AFTEREMULATIONGUI, - LUACALL_BEFOREEXIT, - LUACALL_BEFORESAVE, - LUACALL_AFTERLOAD, - LUACALL_ONSTART, - - LUACALL_SCRIPT_HOTKEY_1, - LUACALL_SCRIPT_HOTKEY_2, - LUACALL_SCRIPT_HOTKEY_3, - LUACALL_SCRIPT_HOTKEY_4, - LUACALL_SCRIPT_HOTKEY_5, - LUACALL_SCRIPT_HOTKEY_6, - LUACALL_SCRIPT_HOTKEY_7, - LUACALL_SCRIPT_HOTKEY_8, - LUACALL_SCRIPT_HOTKEY_9, - LUACALL_SCRIPT_HOTKEY_10, - LUACALL_SCRIPT_HOTKEY_11, - LUACALL_SCRIPT_HOTKEY_12, - LUACALL_SCRIPT_HOTKEY_13, - LUACALL_SCRIPT_HOTKEY_14, - LUACALL_SCRIPT_HOTKEY_15, - LUACALL_SCRIPT_HOTKEY_16, - - LUACALL_COUNT -}; -void CallRegisteredLuaFunctions(LuaCallID calltype); - -enum LuaMemHookType -{ - LUAMEMHOOK_WRITE, - LUAMEMHOOK_READ, - LUAMEMHOOK_EXEC, - LUAMEMHOOK_WRITE_SUB, - LUAMEMHOOK_READ_SUB, - LUAMEMHOOK_EXEC_SUB, - - LUAMEMHOOK_COUNT -}; -void CallRegisteredLuaMemHook(unsigned int address, int size, unsigned int value, LuaMemHookType hookType); - -struct LuaSaveData -{ - LuaSaveData() { recordList = 0; } - ~LuaSaveData() { ClearRecords(); } - - struct Record - { - unsigned int key; // crc32 - unsigned int size; // size of data - unsigned char* data; - Record* next; - }; - - Record* recordList; - - void SaveRecord(int uid, unsigned int key); // saves Lua stack into a record and pops it - void LoadRecord(int uid, unsigned int key, unsigned int itemsToLoad) const; // pushes a record's data onto the Lua stack - void SaveRecordPartial(int uid, unsigned int key, int idx); // saves part of the Lua stack (at the given index) into a record and does NOT pop anything - - void ExportRecords(void* file) const; // writes all records to an already-open file - void ImportRecords(void* file); // reads records from an already-open file - void ClearRecords(); // deletes all record data - -private: - // disallowed, it's dangerous to call this - // (because the memory the destructor deletes isn't refcounted and shouldn't need to be copied) - // so pass LuaSaveDatas by reference and this should never get called - LuaSaveData(const LuaSaveData& copy) {} -}; -void CallRegisteredLuaSaveFunctions(int savestateNumber, LuaSaveData& saveData); -void CallRegisteredLuaLoadFunctions(int savestateNumber, const LuaSaveData& saveData); - -void StopAllLuaScripts(); -void RestartAllLuaScripts(); -void EnableStopAllLuaScripts(bool enable); -void DontWorryLua(); - - - -#endif - +#ifndef LUA_SCRIPT_H +#define LUA_SCRIPT_H + + +void OpenLuaContext(int uid, void(*print)(int uid, const char* str) = 0, void(*onstart)(int uid) = 0, void(*onstop)(int uid, bool statusOK) = 0); +void RunLuaScriptFile(int uid, const char* filename); +void StopLuaScript(int uid); +void RequestAbortLuaScript(int uid, const char* message = 0); +void CloseLuaContext(int uid); + +enum LuaCallID +{ + LUACALL_BEFOREEMULATION, + LUACALL_AFTEREMULATION, + LUACALL_AFTEREMULATIONGUI, + LUACALL_BEFOREEXIT, + LUACALL_BEFORESAVE, + LUACALL_AFTERLOAD, + LUACALL_ONSTART, + + LUACALL_SCRIPT_HOTKEY_1, + LUACALL_SCRIPT_HOTKEY_2, + LUACALL_SCRIPT_HOTKEY_3, + LUACALL_SCRIPT_HOTKEY_4, + LUACALL_SCRIPT_HOTKEY_5, + LUACALL_SCRIPT_HOTKEY_6, + LUACALL_SCRIPT_HOTKEY_7, + LUACALL_SCRIPT_HOTKEY_8, + LUACALL_SCRIPT_HOTKEY_9, + LUACALL_SCRIPT_HOTKEY_10, + LUACALL_SCRIPT_HOTKEY_11, + LUACALL_SCRIPT_HOTKEY_12, + LUACALL_SCRIPT_HOTKEY_13, + LUACALL_SCRIPT_HOTKEY_14, + LUACALL_SCRIPT_HOTKEY_15, + LUACALL_SCRIPT_HOTKEY_16, + + LUACALL_COUNT +}; +void CallRegisteredLuaFunctions(LuaCallID calltype); + +enum LuaMemHookType +{ + LUAMEMHOOK_WRITE, + LUAMEMHOOK_READ, + LUAMEMHOOK_EXEC, + LUAMEMHOOK_WRITE_SUB, + LUAMEMHOOK_READ_SUB, + LUAMEMHOOK_EXEC_SUB, + + LUAMEMHOOK_COUNT +}; +void CallRegisteredLuaMemHook(unsigned int address, int size, unsigned int value, LuaMemHookType hookType); + +struct LuaSaveData +{ + LuaSaveData() { recordList = 0; } + ~LuaSaveData() { ClearRecords(); } + + struct Record + { + unsigned int key; // crc32 + unsigned int size; // size of data + unsigned char* data; + Record* next; + }; + + Record* recordList; + + void SaveRecord(int uid, unsigned int key); // saves Lua stack into a record and pops it + void LoadRecord(int uid, unsigned int key, unsigned int itemsToLoad) const; // pushes a record's data onto the Lua stack + void SaveRecordPartial(int uid, unsigned int key, int idx); // saves part of the Lua stack (at the given index) into a record and does NOT pop anything + + void ExportRecords(void* file) const; // writes all records to an already-open file + void ImportRecords(void* file); // reads records from an already-open file + void ClearRecords(); // deletes all record data + +private: + // disallowed, it's dangerous to call this + // (because the memory the destructor deletes isn't refcounted and shouldn't need to be copied) + // so pass LuaSaveDatas by reference and this should never get called + LuaSaveData(const LuaSaveData& copy) {} +}; +void CallRegisteredLuaSaveFunctions(int savestateNumber, LuaSaveData& saveData); +void CallRegisteredLuaLoadFunctions(int savestateNumber, const LuaSaveData& saveData); + +void StopAllLuaScripts(); +void RestartAllLuaScripts(); +void EnableStopAllLuaScripts(bool enable); +void DontWorryLua(); + + + +#endif + diff --git a/desmume/src/matrix.cpp b/src/matrix.cpp similarity index 91% rename from desmume/src/matrix.cpp rename to src/matrix.cpp index 4261abee0..f611473c6 100644 --- a/desmume/src/matrix.cpp +++ b/src/matrix.cpp @@ -25,10 +25,17 @@ #include #include "matrix.h" -//------------------------- -//switched SSE functions: implementations for no SSE -#ifndef ENABLE_SSE -void MatrixMultVec4x4 (const float *matrix, float *vecPtr) +extern "C" { + + +void MatrixInit (float *matrix) +{ + memset (matrix, 0, sizeof(float)*16); + matrix[0] = matrix[5] = matrix[10] = matrix[15] = 1.f; +} + +#ifdef NOSSE2 +void MATRIXFASTCALL MatrixMultVec4x4 (const float *matrix, float *vecPtr) { float x = vecPtr[0]; float y = vecPtr[1]; @@ -41,8 +48,7 @@ void MatrixMultVec4x4 (const float *matrix, float *vecPtr) vecPtr[3] = x * matrix[3] + y * matrix[7] + z * matrix[11] + w * matrix[15]; } - -void MatrixMultVec3x3 (const float *matrix, float *vecPtr) +void MATRIXFASTCALL MatrixMultVec3x3 (const float *matrix, float *vecPtr) { float x = vecPtr[0]; float y = vecPtr[1]; @@ -53,7 +59,7 @@ void MatrixMultVec3x3 (const float *matrix, float *vecPtr) vecPtr[2] = x * matrix[2] + y * matrix[6] + z * matrix[10]; } -void MatrixMultiply (float *matrix, const float *rightMatrix) +void MATRIXFASTCALL MatrixMultiply (float *matrix, const float *rightMatrix) { float tmpMatrix[16]; @@ -80,7 +86,7 @@ void MatrixMultiply (float *matrix, const float *rightMatrix) memcpy (matrix, tmpMatrix, sizeof(float)*16); } -void MatrixTranslate (float *matrix, const float *ptr) +void MATRIXFASTCALL MatrixTranslate (float *matrix, const float *ptr) { matrix[12] += (matrix[0]*ptr[0])+(matrix[4]*ptr[1])+(matrix[ 8]*ptr[2]); matrix[13] += (matrix[1]*ptr[0])+(matrix[5]*ptr[1])+(matrix[ 9]*ptr[2]); @@ -88,7 +94,7 @@ void MatrixTranslate (float *matrix, const float *ptr) matrix[15] += (matrix[3]*ptr[0])+(matrix[7]*ptr[1])+(matrix[11]*ptr[2]); } -void MatrixScale (float *matrix, const float *ptr) +void MATRIXFASTCALL MatrixScale (float *matrix, const float *ptr) { matrix[0] *= ptr[0]; matrix[1] *= ptr[0]; @@ -105,16 +111,9 @@ void MatrixScale (float *matrix, const float *ptr) matrix[10] *= ptr[2]; matrix[11] *= ptr[2]; } - #endif //switched c/asm functions //----------------------------------------- -void MatrixInit (float *matrix) -{ - memset (matrix, 0, sizeof(float)*16); - matrix[0] = matrix[5] = matrix[10] = matrix[15] = 1.f; -} - void MatrixTranspose(float *matrix) { float temp; @@ -128,7 +127,7 @@ void MatrixTranspose(float *matrix) #undef swap } -void MatrixIdentity (float *matrix) +void MATRIXFASTCALL MatrixIdentity (float *matrix) { matrix[1] = matrix[2] = matrix[3] = matrix[4] = 0.0f; matrix[6] = matrix[7] = matrix[8] = matrix[9] = 0.0f; @@ -136,7 +135,7 @@ void MatrixIdentity (float *matrix) matrix[0] = matrix[5] = matrix[10] = matrix[15] = 1.f; } -float MatrixGetMultipliedIndex (int index, float *matrix, float *rightMatrix) +float MATRIXFASTCALL MatrixGetMultipliedIndex (int index, float *matrix, float *rightMatrix) { int iMod = index%4, iDiv = (index>>2)<<2; @@ -144,12 +143,12 @@ float MatrixGetMultipliedIndex (int index, float *matrix, float *rightMatrix) (matrix[iMod+8]*rightMatrix[iDiv+2])+(matrix[iMod+12]*rightMatrix[iDiv+3]); } -void MatrixSet (float *matrix, int x, int y, float value) // TODO +void MATRIXFASTCALL MatrixSet (float *matrix, int x, int y, float value) // TODO { matrix [x+(y<<2)] = value; } -void MatrixCopy (float* matrixDST, const float* matrixSRC) +void MATRIXFASTCALL MatrixCopy (float* matrixDST, const float* matrixSRC) { matrixDST[0] = matrixSRC[0]; matrixDST[1] = matrixSRC[1]; @@ -170,20 +169,11 @@ void MatrixCopy (float* matrixDST, const float* matrixSRC) } -int MatrixCompare (const float* matrixDST, const float* matrixSRC) +int MATRIXFASTCALL MatrixCompare (const float* matrixDST, const float* matrixSRC) { return memcmp((void*)matrixDST, matrixSRC, sizeof(float)*16); } -void MatrixStackInit(MatrixStack *stack) -{ - for (int i = 0; i < stack->size; i++) - { - MatrixInit(&stack->matrix[i]); - } - stack->position = 0; -} - void MatrixStackSetMaxSize (MatrixStack *stack, int size) { int i; @@ -341,4 +331,5 @@ void Vector4Copy(float *dst, const float *src) dst[3] = src[3]; } +} //extern "C" diff --git a/src/matrix.h b/src/matrix.h new file mode 100644 index 000000000..f87ed8ec2 --- /dev/null +++ b/src/matrix.h @@ -0,0 +1,146 @@ +/* + Copyright (C) 2006-2007 shash + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#ifndef MATRIX_H +#define MATRIX_H + +#include + +#include "types.h" + +extern "C" { + +struct MatrixStack +{ + MatrixStack(int size); + float *matrix; + int position; + int size; +}; + +void MatrixInit (float *matrix); + +#if defined(_MSC_VER) || defined(__INTEL_COMPILER) +#define MATRIXFASTCALL __fastcall +#else +#define MATRIXFASTCALL +#endif + +//In order to conditionally use these asm optimized functions in visual studio +//without having to make new build types to exclude the assembly files. +//a bit sloppy, but there aint much to it +#ifndef NOSSE2 +#define SSE2_FUNC(X) _sse2_##X +#define MatrixMultVec4x4 _sse2_MatrixMultVec4x4 +#define MatrixMultVec3x3 _sse2_MatrixMultVec3x3 +#define MatrixMultiply _sse2_MatrixMultiply +#define MatrixTranslate _sse2_MatrixTranslate +#define MatrixScale _sse2_MatrixScale +void MATRIXFASTCALL _sse2_fix2float_16 (float* matrix, float* divizor_mask); +void MATRIXFASTCALL _sse2_fix2float_12 (float* matrix, float* divizor_mask); +void MATRIXFASTCALL _sse2_MatrixMultVec4x4_M2 (const float * matrix, float * vecPtr); // mode 2 +#else +#define SSE2_FUNC(X) X +#endif + +void MATRIXFASTCALL SSE2_FUNC(MatrixMultVec3x3) (const float * matrix, float * vecPtr); +void MATRIXFASTCALL SSE2_FUNC(MatrixMultVec4x4) (const float * matrix, float * vecPtr); +void MATRIXFASTCALL SSE2_FUNC(MatrixMultiply) (float * matrix, const float * rightMatrix); +void MATRIXFASTCALL SSE2_FUNC(MatrixTranslate) (float *matrix, const float *ptr); +void MATRIXFASTCALL SSE2_FUNC(MatrixScale) (float * matrix, const float * ptr); + + + +float MATRIXFASTCALL MatrixGetMultipliedIndex (int index, float *matrix, float *rightMatrix); +void MATRIXFASTCALL MatrixSet (float *matrix, int x, int y, float value); +void MATRIXFASTCALL MatrixCopy (float * matrixDST, const float * matrixSRC); +int MATRIXFASTCALL MatrixCompare (const float * matrixDST, const float * matrixSRC); +void MATRIXFASTCALL MatrixIdentity (float *matrix); + +void MatrixTranspose (float *matrix); +void MatrixStackInit (MatrixStack *stack); +void MatrixStackSetMaxSize (MatrixStack *stack, int size); +void MatrixStackSetStackPosition (MatrixStack *stack, int pos); +void MatrixStackPushMatrix (MatrixStack *stack, const float *ptr); +float* MatrixStackPopMatrix (MatrixStack *stack, int size); +float* MatrixStackGetPos (MatrixStack *stack, int pos); +float* MatrixStackGet (MatrixStack *stack); +void MatrixStackLoadMatrix (MatrixStack *stack, int pos, const float *ptr); + +void Vector2Copy(float *dst, const float *src); +void Vector2Add(float *dst, const float *src); +void Vector2Subtract(float *dst, const float *src); +float Vector2Dot(const float *a, const float *b); +float Vector2Cross(const float *a, const float *b); + +float Vector3Dot(const float *a, const float *b); +void Vector3Cross(float* dst, const float *a, const float *b); +float Vector3Length(const float *a); +void Vector3Add(float *dst, const float *src); +void Vector3Subtract(float *dst, const float *src); +void Vector3Scale(float *dst, const float scale); +void Vector3Copy(float *dst, const float *src); +void Vector3Normalize(float *dst); + +void Vector4Copy(float *dst, const float *src); + +} //extern "C" + +//these functions are an unreliable, inaccurate floor. +//it should only be used for positive numbers +//this isnt as fast as it could be if we used a visual c++ intrinsic, but those appear not to be universally available +FORCEINLINE u32 u32floor(float f) +{ +#ifndef NOSSE2 + __asm cvttss2si eax, f; +#else + return (u32)f; +#endif +} +FORCEINLINE u32 u32floor(double d) +{ +#ifndef NOSSE2 + __asm cvttsd2si eax, d; +#else + return (u32)d; +#endif +} + +//same as above but works for negative values too. +//be sure that the results are the same thing as floorf! +FORCEINLINE s32 s32floor(float f) +{ +#ifndef NOSSE2 + static const float c = -0.5f; + __asm + { + movss xmm0, f; + addss xmm0, xmm0; + addss xmm0, c; + cvtss2si eax, xmm0 + sar eax, 1 + } +#else + return (s32)floorf(f); +#endif +} + + +#endif diff --git a/src/matrix_sse2-x64.asm b/src/matrix_sse2-x64.asm new file mode 100644 index 000000000..a919548b6 --- /dev/null +++ b/src/matrix_sse2-x64.asm @@ -0,0 +1,182 @@ +; +; Copyright (C) 2006 yopyop +; Copyright (C) 2008 CrazyMax +; +; This file is part of DeSmuME +; +; DeSmuME is free software; you can redistribute it and/or modify +; it under the terms of the GNU General Public License as published by +; the Free Software Foundation; either version 2 of the License, or +; (at your option) any later version. +; +; DeSmuME is distributed in the hope that it will be useful, +; but WITHOUT ANY WARRANTY; without even the implied warranty of +; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +; GNU General Public License for more details. +; +; You should have received a copy of the GNU General Public License +; along with DeSmuME; if not, write to the Free Software +; Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + + TITLE matrix_sse2-x64.asm + .code + +_sse2_MatrixMultVec4x4 PROC PUBLIC + movaps xmm0, XMMWORD PTR [rcx] + movaps xmm1, XMMWORD PTR [rcx+16] + movaps xmm2, XMMWORD PTR [rcx+32] + movaps xmm3, XMMWORD PTR [rcx+48] + movaps xmm4, XMMWORD PTR [rdx] + movaps xmm5, xmm4 + movaps xmm6, xmm4 + movaps xmm7, xmm4 + shufps xmm4, xmm4, 00000000b + shufps xmm5, xmm5, 01010101b + shufps xmm6, xmm6, 10101010b + shufps xmm7, xmm7, 11111111b + mulps xmm4, xmm0 + mulps xmm5, xmm1 + mulps xmm6, xmm2 + mulps xmm7, xmm3 + addps xmm4, xmm5 + addps xmm4, xmm6 + addps xmm4, xmm7 + movaps XMMWORD PTR [rdx], xmm4 + ret 0 +_sse2_MatrixMultVec4x4 ENDP + +_sse2_MatrixMultVec3x3 PROC PUBLIC + movaps xmm0, XMMWORD PTR [rcx] + movaps xmm1, XMMWORD PTR [rcx+16] + movaps xmm2, XMMWORD PTR [rcx+32] + movaps xmm4, XMMWORD PTR [rdx] + movaps xmm5, xmm4 + movaps xmm6, xmm4 + movaps xmm7, xmm4 + shufps xmm4, xmm4, 00000000b + shufps xmm5, xmm5, 01010101b + shufps xmm6, xmm6, 10101010b + mulps xmm4, xmm0 + mulps xmm5, xmm1 + mulps xmm6, xmm2 + addps xmm4, xmm5 + addps xmm4, xmm6 + movaps XMMWORD PTR [rdx], xmm4 + ret 0 +_sse2_MatrixMultVec3x3 ENDP + +_sse2_MatrixMultiply PROC PUBLIC + movaps xmm0, XMMWORD PTR [rcx] + movaps xmm1, XMMWORD PTR [rcx+16] + movaps xmm2, XMMWORD PTR [rcx+32] + movaps xmm3, XMMWORD PTR [rcx+48] + movaps xmm4, XMMWORD PTR [rdx] ; r00, r01, r02, r03 + movaps xmm8, XMMWORD PTR [rdx+16] ; r04, r05, r06, r07 + movaps xmm5,xmm4 + movaps xmm6,xmm4 + movaps xmm7,xmm4 + movaps xmm9,xmm8 ; + movaps xmm10,xmm8 + movaps xmm11,xmm8 + shufps xmm4,xmm4,00000000b + shufps xmm5,xmm5,01010101b + shufps xmm6,xmm6,10101010b + shufps xmm7,xmm7,11111111b + shufps xmm8, xmm8, 00000000b ; + shufps xmm9, xmm9, 01010101b + shufps xmm10,xmm10,10101010b + shufps xmm11,xmm11,11111111b + mulps xmm4,xmm0 + mulps xmm5,xmm1 + mulps xmm6,xmm2 + mulps xmm7,xmm3 + mulps xmm8, xmm0 ; + mulps xmm9, xmm1 + mulps xmm10,xmm2 + mulps xmm11,xmm3 + addps xmm4,xmm5 + addps xmm4,xmm6 + addps xmm4,xmm7 + addps xmm8,xmm9 ; + addps xmm8,xmm10 + addps xmm8,xmm11 + movaps XMMWORD PTR [rcx],xmm4 + movaps XMMWORD PTR [rcx+16],xmm8 + + movaps xmm4, XMMWORD PTR [rdx+32] ; r00, r01, r02, r03 + movaps xmm8, XMMWORD PTR [rdx+48] ; r04, r05, r06, r07 + movaps xmm5,xmm4 + movaps xmm6,xmm4 + movaps xmm7,xmm4 + movaps xmm9,xmm8 ; + movaps xmm10,xmm8 + movaps xmm11,xmm8 + shufps xmm4,xmm4,00000000b + shufps xmm5,xmm5,01010101b + shufps xmm6,xmm6,10101010b + shufps xmm7,xmm7,11111111b + shufps xmm8, xmm8, 00000000b ; + shufps xmm9, xmm9, 01010101b + shufps xmm10,xmm10,10101010b + shufps xmm11,xmm11,11111111b + mulps xmm4,xmm0 + mulps xmm5,xmm1 + mulps xmm6,xmm2 + mulps xmm7,xmm3 + mulps xmm8, xmm0 ; + mulps xmm9, xmm1 + mulps xmm10,xmm2 + mulps xmm11,xmm3 + addps xmm4,xmm5 + addps xmm4,xmm6 + addps xmm4,xmm7 + addps xmm8,xmm9 ; + addps xmm8,xmm10 + addps xmm8,xmm11 + movaps XMMWORD PTR [rcx+32],xmm4 + movaps XMMWORD PTR [rcx+48],xmm8 + ret 0 +_sse2_MatrixMultiply ENDP + +_sse2_MatrixTranslate PROC PUBLIC + movaps xmm0, XMMWORD PTR [rcx] + movaps xmm1, XMMWORD PTR [rcx+16] + movaps xmm2, XMMWORD PTR [rcx+32] + movaps xmm3, XMMWORD PTR [rcx+48] + movaps xmm4, XMMWORD PTR [rdx] + movaps xmm5, xmm4 + movaps xmm6, xmm4 + movaps xmm7, xmm4 + shufps xmm4, xmm4, 00000000b + shufps xmm5, xmm5, 01010101b + shufps xmm6, xmm6, 10101010b + mulps xmm4, xmm0 + mulps xmm5, xmm1 + mulps xmm6, xmm2 + addps xmm4, xmm5 + addps xmm4, xmm6 + addps xmm4, xmm3 + movaps XMMWORD PTR [rcx+48], xmm4 + ret 0 +_sse2_MatrixTranslate ENDP + +_sse2_MatrixScale PROC PUBLIC + movaps xmm0, XMMWORD PTR [rcx] + movaps xmm1, XMMWORD PTR [rcx+16] + movaps xmm2, XMMWORD PTR [rcx+32] + movaps xmm4, XMMWORD PTR [rdx] + movaps xmm5, xmm4 + movaps xmm6, xmm4 + shufps xmm4, xmm4, 00000000b + shufps xmm5, xmm5, 01010101b + shufps xmm6, xmm6, 10101010b + mulps xmm4, xmm0 + mulps xmm5, xmm1 + mulps xmm6, xmm2 + movaps XMMWORD PTR [rcx],xmm4 + movaps XMMWORD PTR [rcx+16],xmm5 + movaps XMMWORD PTR [rcx+32],xmm6 + ret 0 +_sse2_MatrixScale ENDP + +end diff --git a/src/matrix_sse2-x86.asm b/src/matrix_sse2-x86.asm new file mode 100644 index 000000000..0a5a3a44c --- /dev/null +++ b/src/matrix_sse2-x86.asm @@ -0,0 +1,214 @@ +; +; Copyright (C) 2006 yopyop +; Copyright (C) 2008 CrazyMax +; +; This file is part of DeSmuME +; +; DeSmuME is free software; you can redistribute it and/or modify +; it under the terms of the GNU General Public License as published by +; the Free Software Foundation; either version 2 of the License, or +; (at your option) any later version. +; +; DeSmuME is distributed in the hope that it will be useful, +; but WITHOUT ANY WARRANTY; without even the implied warranty of +; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +; GNU General Public License for more details. +; +; You should have received a copy of the GNU General Public License +; along with DeSmuME; if not, write to the Free Software +; Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + + TITLE matrix_sse2-x86.asm + .686P + .XMM + .model flat + .code + +@_sse2_MatrixMultVec4x4@8 PROC PUBLIC + movaps xmm4, XMMWORD PTR [edx] + pshufd xmm5, xmm4, 01010101b + pshufd xmm6, xmm4, 10101010b + pshufd xmm7, xmm4, 11111111b + shufps xmm4, xmm4, 00000000b + mulps xmm4, XMMWORD PTR [ecx] + mulps xmm5, XMMWORD PTR [ecx+16] + mulps xmm6, XMMWORD PTR [ecx+32] + mulps xmm7, XMMWORD PTR [ecx+48] + addps xmm4, xmm5 + addps xmm4, xmm6 + addps xmm4, xmm7 + movaps XMMWORD PTR [edx], xmm4 + ret 0 +@_sse2_MatrixMultVec4x4@8 ENDP + +@_sse2_MatrixMultVec4x4_M2@8 PROC PUBLIC + movaps xmm4, XMMWORD PTR [edx] + pshufd xmm5, xmm4, 01010101b + pshufd xmm6, xmm4, 10101010b + pshufd xmm7, xmm4, 11111111b + shufps xmm4, xmm4, 00000000b + mulps xmm4, XMMWORD PTR [ecx+64] + mulps xmm5, XMMWORD PTR [ecx+80] + mulps xmm6, XMMWORD PTR [ecx+96] + mulps xmm7, XMMWORD PTR [ecx+112] + addps xmm4, xmm5 + addps xmm4, xmm6 + addps xmm4, xmm7 + pshufd xmm5, xmm4, 01010101b + pshufd xmm6, xmm4, 10101010b + pshufd xmm7, xmm4, 11111111b + shufps xmm4, xmm4, 00000000b + mulps xmm4, XMMWORD PTR [ecx] + mulps xmm5, XMMWORD PTR [ecx+16] + mulps xmm6, XMMWORD PTR [ecx+32] + mulps xmm7, XMMWORD PTR [ecx+48] + addps xmm4, xmm5 + addps xmm4, xmm6 + addps xmm4, xmm7 + movaps XMMWORD PTR [edx], xmm4 + ret 0 +@_sse2_MatrixMultVec4x4_M2@8 ENDP + + +@_sse2_MatrixMultVec3x3@8 PROC PUBLIC + movaps xmm4, XMMWORD PTR [edx] + pshufd xmm5, xmm4, 01010101b + pshufd xmm6, xmm4, 10101010b + shufps xmm4, xmm4, 00000000b + mulps xmm4, XMMWORD PTR [ecx] + mulps xmm5, XMMWORD PTR [ecx+16] + mulps xmm6, XMMWORD PTR [ecx+32] + addps xmm4, xmm5 + addps xmm4, xmm6 + movaps XMMWORD PTR [edx], xmm4 + ret 0 +@_sse2_MatrixMultVec3x3@8 ENDP + +@_sse2_MatrixMultiply@8 PROC PUBLIC + movaps xmm0, XMMWORD PTR [ecx] + movaps xmm1, XMMWORD PTR [ecx+16] + movaps xmm2, XMMWORD PTR [ecx+32] + movaps xmm3, XMMWORD PTR [ecx+48] + movaps xmm4, XMMWORD PTR [edx] ; r00, r01, r02, r03 + pshufd xmm5, xmm4, 01010101b + pshufd xmm6, xmm4, 10101010b + pshufd xmm7, xmm4, 11111111b + shufps xmm4, xmm4, 00000000b + mulps xmm4,xmm0 + mulps xmm5,xmm1 + mulps xmm6,xmm2 + mulps xmm7,xmm3 + addps xmm4,xmm5 + addps xmm4,xmm6 + addps xmm4,xmm7 + movaps XMMWORD PTR [ecx],xmm4 + + movaps xmm4, XMMWORD PTR [edx+16] ; r04, r05, r06, r07 + pshufd xmm5, xmm4, 01010101b + pshufd xmm6, xmm4, 10101010b + pshufd xmm7, xmm4, 11111111b + shufps xmm4, xmm4, 00000000b + mulps xmm4,xmm0 + mulps xmm5,xmm1 + mulps xmm6,xmm2 + mulps xmm7,xmm3 + addps xmm4,xmm5 + addps xmm4,xmm6 + addps xmm4,xmm7 + movaps XMMWORD PTR [ecx+16],xmm4 + + movaps xmm4, XMMWORD PTR [edx+32] ; r08, r09, r10, r11 + pshufd xmm5, xmm4, 01010101b + pshufd xmm6, xmm4, 10101010b + pshufd xmm7, xmm4, 11111111b + shufps xmm4, xmm4, 00000000b + mulps xmm4,xmm0 + mulps xmm5,xmm1 + mulps xmm6,xmm2 + mulps xmm7,xmm3 + addps xmm4,xmm5 + addps xmm4,xmm6 + addps xmm4,xmm7 + movaps XMMWORD PTR [ecx+32],xmm4 + + movaps xmm4, XMMWORD PTR [edx+48] ; r12, r13, r14, r15 + pshufd xmm5, xmm4, 01010101b + pshufd xmm6, xmm4, 10101010b + pshufd xmm7, xmm4, 11111111b + shufps xmm4, xmm4, 00000000b + mulps xmm4,xmm0 + mulps xmm5,xmm1 + mulps xmm6,xmm2 + mulps xmm7,xmm3 + addps xmm4,xmm5 + addps xmm4,xmm6 + addps xmm4,xmm7 + movaps XMMWORD PTR [ecx+48],xmm4 + + ret 0 +@_sse2_MatrixMultiply@8 ENDP + +@_sse2_MatrixTranslate@8 PROC PUBLIC + movaps xmm4, XMMWORD PTR [edx] + pshufd xmm5, xmm4, 01010101b + pshufd xmm6, xmm4, 10101010b + shufps xmm4, xmm4, 00000000b + mulps xmm4, XMMWORD PTR [ecx] + mulps xmm5, XMMWORD PTR [ecx+16] + mulps xmm6, XMMWORD PTR [ecx+32] + addps xmm4, xmm5 + addps xmm4, xmm6 + addps xmm4, XMMWORD PTR [ecx+48] + movaps XMMWORD PTR [ecx+48], xmm4 + ret 0 +@_sse2_MatrixTranslate@8 ENDP + +@_sse2_MatrixScale@8 PROC PUBLIC + movaps xmm4, XMMWORD PTR [edx] + pshufd xmm5, xmm4, 01010101b + pshufd xmm6, xmm4, 10101010b + shufps xmm4, xmm4, 00000000b + mulps xmm4, XMMWORD PTR [ecx] + mulps xmm5, XMMWORD PTR [ecx+16] + mulps xmm6, XMMWORD PTR [ecx+32] + movaps XMMWORD PTR [ecx], xmm4 + movaps XMMWORD PTR [ecx+16], xmm5 + movaps XMMWORD PTR [ecx+32], xmm6 + ret 0 +@_sse2_MatrixScale@8 ENDP + +@_sse2_fix2float_12@8 PROC PUBLIC + movaps xmm0, XMMWORD PTR[ecx] + movaps xmm1, XMMWORD PTR[ecx+16] + movaps xmm2, XMMWORD PTR[ecx+32] + movaps xmm4, XMMWORD PTR [edx] + ;prefetchnta [ecx+64] + divps xmm0, xmm4 + divps xmm1, xmm4 + divps xmm2, xmm4 + movaps XMMWORD PTR[ecx], xmm0 + movaps XMMWORD PTR[ecx+16],xmm1 + movaps XMMWORD PTR[ecx+32],xmm2 + ret 0 +@_sse2_fix2float_12@8 ENDP + +@_sse2_fix2float_16@8 PROC PUBLIC + movaps xmm0, XMMWORD PTR[ecx] + movaps xmm1, XMMWORD PTR[ecx+16] + movaps xmm2, XMMWORD PTR[ecx+32] + movaps xmm3, XMMWORD PTR[ecx+48] + movaps xmm4, XMMWORD PTR [edx] + ;prefetchnta [ecx+64] + divps xmm0, xmm4 + divps xmm1, xmm4 + divps xmm2, xmm4 + divps xmm3, xmm4 + movaps XMMWORD PTR[ecx], xmm0 + movaps XMMWORD PTR[ecx+16],xmm1 + movaps XMMWORD PTR[ecx+32],xmm2 + movaps XMMWORD PTR[ecx+48],xmm3 + ret 0 +@_sse2_fix2float_16@8 ENDP + +end + diff --git a/src/mc.cpp b/src/mc.cpp new file mode 100644 index 000000000..abccf08b9 --- /dev/null +++ b/src/mc.cpp @@ -0,0 +1,512 @@ +/* Copyright (C) 2006 thoduv + Copyright (C) 2006-2007 Theo Berkau + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#include +#include +#include "debug.h" +#include "types.h" +#include "mc.h" +#include "movie.h" + +#define FW_CMD_READ 0x3 +#define FW_CMD_WRITEDISABLE 0x4 +#define FW_CMD_READSTATUS 0x5 +#define FW_CMD_WRITEENABLE 0x6 +#define FW_CMD_PAGEWRITE 0xA + +#define BM_CMD_AUTODETECT 0xFF +#define BM_CMD_WRITESTATUS 0x1 +#define BM_CMD_WRITELOW 0x2 +#define BM_CMD_READLOW 0x3 +#define BM_CMD_WRITEDISABLE 0x4 +#define BM_CMD_READSTATUS 0x5 +#define BM_CMD_WRITEENABLE 0x6 +#define BM_CMD_WRITEHIGH 0xA +#define BM_CMD_READHIGH 0xB + +/* FLASH*/ +#define COMM_PAGE_WRITE 0x0A +#define COMM_PAGE_ERASE 0xDB +#define COMM_SECTOR_ERASE 0xD8 +#define COMM_CHIP_ERASE 0xC7 +#define CARDFLASH_READ_BYTES_FAST 0x0B /* Not used*/ +#define CARDFLASH_DEEP_POWDOWN 0xB9 /* Not used*/ +#define CARDFLASH_WAKEUP 0xAB /* Not used*/ + +void mc_init(memory_chip_t *mc, int type) +{ + mc->com = 0; + mc->addr = 0; + mc->addr_shift = 0; + mc->data = NULL; + mc->size = 0; + mc->write_enable = FALSE; + mc->writeable_buffer = FALSE; + mc->type = type; + mc->autodetectsize = 0; + + switch(mc->type) + { + case MC_TYPE_EEPROM1: + mc->addr_size = 1; + break; + case MC_TYPE_EEPROM2: + case MC_TYPE_FRAM: + mc->addr_size = 2; + break; + case MC_TYPE_FLASH: + mc->addr_size = 3; + break; + default: break; + } +} + +u8 *mc_alloc(memory_chip_t *mc, u32 size) +{ + u8 *buffer; + buffer = new u8[size]; + memset(buffer,0,size); + + mc->data = buffer; + if(!buffer) { return NULL; } + mc->size = size; + mc->writeable_buffer = TRUE; + + return buffer; +} + +void mc_free(memory_chip_t *mc) +{ + if(mc->data) delete[] mc->data; + mc_init(mc, 0); +} + +void mc_reset_com(memory_chip_t *mc) +{ + size_t elems_written = 0; + + if (mc->type == MC_TYPE_AUTODETECT && mc->com == BM_CMD_AUTODETECT) + { + u32 addr, size; + + LOG("autodetectsize = %d\n",mc->autodetectsize); + + if (mc->autodetectsize == (32768+2)) + { + // FRAM + addr = (mc->autodetectbuf[0] << 8) | mc->autodetectbuf[1]; + mc->type = MC_TYPE_FRAM; + mc->size = MC_SIZE_256KBITS; + } + else if (mc->autodetectsize == (512+3)) + { + // Flash 4Mbit + addr = (mc->autodetectbuf[0] << 16) | + (mc->autodetectbuf[1] << 8) | + mc->autodetectbuf[2]; + mc->type = MC_TYPE_FLASH; + mc->size = MC_SIZE_4MBITS; + } + else if (mc->autodetectsize == (256+3)) + { + // Flash 2Mbit + addr = (mc->autodetectbuf[0] << 16) | + (mc->autodetectbuf[1] << 8) | + mc->autodetectbuf[2]; + mc->type = MC_TYPE_FLASH; + mc->size = MC_SIZE_2MBITS; + } + else if ((mc->autodetectsize == (128+2)) || (mc->autodetectsize == (64+2)) || (mc->autodetectsize == (40+2))) + { + // 512 Kbit EEPROM + addr = (mc->autodetectbuf[0] << 8) | mc->autodetectbuf[1]; + mc->type = MC_TYPE_EEPROM2; + mc->size = MC_SIZE_512KBITS; + } + else if ((mc->autodetectsize == (32+2)) || (mc->autodetectsize == (16+2))) + { + // 64 Kbit EEPROM + addr = (mc->autodetectbuf[0] << 8) | mc->autodetectbuf[1]; + mc->type = MC_TYPE_EEPROM2; + mc->size = MC_SIZE_64KBITS; + } + else if (mc->autodetectsize == (16+1)) + { + // 4 Kbit EEPROM + addr = mc->autodetectbuf[0]; + mc->type = MC_TYPE_EEPROM1; + mc->size = MC_SIZE_4KBITS; + } + else + { + /* + // Assume it's a Flash non-page write + LOG("Flash detected(guessed). autodetectsize = %d\n", mc->autodetectsize); + addr = (mc->autodetectbuf[0] << 16) | + (mc->autodetectbuf[1] << 8) | + mc->autodetectbuf[2]; + mc->type = MC_TYPE_FLASH; + mc->size = MC_SIZE_2MBITS; + */ + // 64 Kbit EEPROM + addr = (mc->autodetectbuf[0] << 8) | mc->autodetectbuf[1]; + mc->type = MC_TYPE_EEPROM2; + mc->size = MC_SIZE_64KBITS; + } + + size = mc->autodetectsize; + mc_realloc(mc, mc->type, mc->size); + memcpy(mc->data+addr, mc->autodetectbuf+mc->addr_size, size-mc->addr_size); + mc->autodetectsize = 0; + mc->write_enable = FALSE; + + // Generate file + if ((mc->fp = fopen(mc->filename, "wb+")) != NULL) + elems_written += fwrite((void *)mc->data, 1, mc->size, mc->fp); + } + else if ((mc->com == BM_CMD_WRITELOW) || (mc->com == FW_CMD_PAGEWRITE)) + { + if(!mc->fp) + mc->fp = fopen(mc->filename, "wb+"); + + if (mc->fp) + { + fseek(mc->fp, 0, SEEK_SET); + elems_written += fwrite((void *)mc->data, 1, mc->size, mc->fp); // FIXME + } + // FIXME: desmume silently ignores not having opened save-file + mc->write_enable = FALSE; + } + + mc->com = 0; +} + +void mc_realloc(memory_chip_t *mc, int type, u32 size) +{ + if(mc->data) delete[] mc->data; + mc_init(mc, type); + mc_alloc(mc, size); +} + +void mc_load_file(memory_chip_t *mc, const char* filename) +{ + long size; + int type = -1; + FILE* file; + size_t elems_read; + + if(movieMode != MOVIEMODE_INACTIVE) { + mc->filename = strdup(filename); + return; + } + else + file = fopen(filename, "rb+"); + + if(file == NULL) + { + mc->filename = strdup(filename); + return; + } + + fseek(file, 0, SEEK_END); + size = ftell(file); + fseek(file, 0, SEEK_SET); + + if (mc->type == MC_TYPE_AUTODETECT) + { + if (size == MC_SIZE_4KBITS) + type = MC_TYPE_EEPROM1; + else if (size == MC_SIZE_64KBITS) + type = MC_TYPE_EEPROM2; + else if (size == MC_SIZE_256KBITS) + type = MC_TYPE_FRAM; + else if (size == MC_SIZE_512KBITS) + type = MC_TYPE_EEPROM2; + else if (size >= MC_SIZE_2MBITS) + type = MC_TYPE_FLASH; + else if (size >= MC_SIZE_4MBITS) + type = MC_TYPE_FLASH; + + if (type != -1) + mc_realloc(mc, type, size); + } + + if ((u32)size > mc->size) + size = mc->size; + elems_read = fread (mc->data, 1, size, file); + mc->fp = file; +} + +int mc_load_duc(memory_chip_t *mc, const char* filename) +{ + long size; + int type = -1; + char id[16]; + FILE* file = fopen(filename, "rb"); + size_t elems_read = 0; + if(file == NULL) + return 0; + + fseek(file, 0, SEEK_END); + size = ftell(file) - 500; + fseek(file, 0, SEEK_SET); + + // Make sure we really have the right file + elems_read += fread((void *)id, sizeof(char), 16, file); + + if (memcmp(id, "ARDS000000000001", 16) != 0) + { + fclose(file); + return 0; + } + + // Alright, it's time to load the file + if (mc->type == MC_TYPE_AUTODETECT) + { + if (size == MC_SIZE_4KBITS) + type = MC_TYPE_EEPROM1; + else if (size == MC_SIZE_64KBITS) + type = MC_TYPE_EEPROM2; + else if (size == MC_SIZE_256KBITS) + type = MC_TYPE_FRAM; + else if (size == MC_SIZE_512KBITS) + type = MC_TYPE_EEPROM2; + else if (size >= MC_SIZE_2MBITS) + type = MC_TYPE_FLASH; + else if (size >= MC_SIZE_4MBITS) + type = MC_TYPE_FLASH; + + if (type != -1) + mc_realloc(mc, type, size); + } + + if ((u32)size > mc->size) + size = mc->size; + // Skip the rest of the header since we don't need it + fseek(file, 500, SEEK_SET); + elems_read += fread (mc->data, 1, size, file); + fclose(file); + + return 1; +} + +u8 fw_transfer(memory_chip_t *mc, u8 data) +{ + if(mc->com == FW_CMD_READ || mc->com == FW_CMD_PAGEWRITE) /* check if we are in a command that needs 3 bytes address */ + { + if(mc->addr_shift > 0) /* if we got a complete address */ + { + mc->addr_shift--; + mc->addr |= data << (mc->addr_shift * 8); /* argument is a byte of address */ + } + else /* if we have received 3 bytes of address, proceed command */ + { + switch(mc->com) + { + case FW_CMD_READ: + if(mc->addr < mc->size) /* check if we can read */ + { + data = mc->data[mc->addr]; /* return byte */ + mc->addr++; /* then increment address */ + } + break; + + case FW_CMD_PAGEWRITE: + if(mc->addr < mc->size) + { + mc->data[mc->addr] = data; /* write byte */ + mc->addr++; + } + break; + } + + } + } + else if(mc->com == FW_CMD_READSTATUS) + { + return (mc->write_enable ? 0x02 : 0x00); + } + else /* finally, check if it's a new command */ + { + switch(data) + { + case 0: break; /* nothing */ + + case FW_CMD_READ: /* read command */ + mc->addr = 0; + mc->addr_shift = 3; + mc->com = FW_CMD_READ; + break; + + case FW_CMD_WRITEENABLE: /* enable writing */ + if(mc->writeable_buffer) { mc->write_enable = TRUE; } + break; + + case FW_CMD_WRITEDISABLE: /* disable writing */ + mc->write_enable = FALSE; + break; + + case FW_CMD_PAGEWRITE: /* write command */ + if(mc->write_enable) + { + mc->addr = 0; + mc->addr_shift = 3; + mc->com = FW_CMD_PAGEWRITE; + } + else { data = 0; } + break; + + case FW_CMD_READSTATUS: /* status register command */ + mc->com = FW_CMD_READSTATUS; + break; + + default: + LOG("Unhandled FW command: %02X\n", data); + break; + } + } + + return data; +} + +u8 bm_transfer(memory_chip_t *mc, u8 data) +{ + if(mc->com == BM_CMD_READLOW || mc->com == BM_CMD_WRITELOW) /* check if we are in a command that needs multiple byte address */ + { + if(mc->addr_shift > 0) /* if we got a complete address */ + { + mc->addr_shift--; + mc->addr |= data << (mc->addr_shift * 8); /* argument is a byte of address */ + } + else /* if we have received all bytes of address, proceed command */ + { + switch(mc->com) + { + case BM_CMD_READLOW: + if(mc->addr < mc->size) /* check if we can read */ + { + //LOG("Read Backup Memory addr %08X(%02X)\n", mc->addr, mc->data[mc->addr]); + data = mc->data[mc->addr]; /* return byte */ + mc->addr++; /* then increment address */ + } + break; + + case BM_CMD_WRITELOW: + if(mc->addr < mc->size) + { + //LOG("Write Backup Memory addr %08X with %02X\n", mc->addr, data); + mc->data[mc->addr] = data; /* write byte */ + mc->addr++; + } + break; + } + + } + } + else if(mc->com == BM_CMD_AUTODETECT) + { + // Store everything in a temporary + mc->autodetectbuf[mc->autodetectsize] = data; + mc->autodetectsize++; + return 0; + } + else if(mc->com == BM_CMD_READSTATUS) + { + //LOG("Backup Memory Read Status: %02X\n", mc->write_enable << 1); + return (mc->write_enable << 1); + } + else /* finally, check if it's a new command */ + { + switch(data) + { + case 0: break; /* nothing */ + + case BM_CMD_WRITELOW: /* write command */ + if(mc->write_enable) + { + if(mc->type == MC_TYPE_AUTODETECT) + { + mc->com = BM_CMD_AUTODETECT; + break; + } + + mc->addr = 0; + mc->addr_shift = mc->addr_size; + mc->com = BM_CMD_WRITELOW; + } + else { data = 0; } + break; + + case BM_CMD_READLOW: /* read command */ + mc->addr = 0; + mc->addr_shift = mc->addr_size; + mc->com = BM_CMD_READLOW; + break; + + case BM_CMD_WRITEDISABLE: /* disable writing */ + mc->write_enable = FALSE; + break; + + case BM_CMD_READSTATUS: /* status register command */ + mc->com = BM_CMD_READSTATUS; + break; + + case BM_CMD_WRITEENABLE: /* enable writing */ + if(mc->writeable_buffer) { mc->write_enable = TRUE; } + break; + + case BM_CMD_WRITEHIGH: /* write command that's only available on ST M95040-W that I know of */ + if(mc->write_enable) + { + if(mc->type == MC_TYPE_AUTODETECT) + { + mc->com = BM_CMD_AUTODETECT; + break; + } + + if (mc->type == MC_TYPE_EEPROM1) + mc->addr = 0x100; + else + mc->addr = 0; + mc->addr_shift = mc->addr_size; + mc->com = BM_CMD_WRITELOW; + } + else { data = 0; } + break; + + case BM_CMD_READHIGH: /* read command that's only available on ST M95040-W that I know of */ + if (mc->type == MC_TYPE_EEPROM1) + mc->addr = 0x100; + else + mc->addr = 0; + mc->addr_shift = mc->addr_size; + mc->com = BM_CMD_READLOW; + + break; + + default: + LOG("Unhandled Backup Memory command: %02X\n", data); + break; + } + } + + return data; +} + diff --git a/desmume/src/mc.h b/src/mc.h similarity index 57% rename from desmume/src/mc.h rename to src/mc.h index 8cdc4f580..17121d8f7 100644 --- a/desmume/src/mc.h +++ b/src/mc.h @@ -1,147 +1,77 @@ -/* Copyright (C) 2006 thoduv - Copyright (C) 2006 Theo Berkau - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#ifndef __FW_H__ -#define __FW_H__ - -#include -#include -#include -#include "types.h" - -#define MC_TYPE_AUTODETECT 0x0 -#define MC_TYPE_EEPROM1 0x1 -#define MC_TYPE_EEPROM2 0x2 -#define MC_TYPE_FLASH 0x3 -#define MC_TYPE_FRAM 0x4 - -#define MC_SIZE_4KBITS 0x000200 -#define MC_SIZE_64KBITS 0x002000 -#define MC_SIZE_256KBITS 0x008000 -#define MC_SIZE_512KBITS 0x010000 -#define MC_SIZE_1MBITS 0x020000 -#define MC_SIZE_2MBITS 0x040000 -#define MC_SIZE_4MBITS 0x080000 -#define MC_SIZE_8MBITS 0x100000 -#define MC_SIZE_16MBITS 0x200000 -#define MC_SIZE_64MBITS 0x800000 - -typedef struct -{ - u8 com; /* persistent command actually handled */ - u32 addr; /* current address for reading/writing */ - u8 addr_shift; /* shift for address (since addresses are transfered by 3 bytes units) */ - u8 addr_size; /* size of addr when writing/reading */ - - BOOL write_enable; /* is write enabled ? */ - - u8 *data; /* memory data */ - u32 size; /* memory size */ - BOOL writeable_buffer; /* is "data" writeable ? */ - int type; /* type of Memory */ - char *filename; - FILE *fp; - u8 autodetectbuf[32768]; - int autodetectsize; -} memory_chip_t; - -//the new backup system by zeromus -class BackupDevice -{ -public: - BackupDevice(); - - //signals the save system that we are in our regular mode, loading up a rom. initializes for that case. - void load_rom(const char* filename); - //signals the save system that we are in MOVIE mode. doesnt load up a rom, and never saves it. initializes for that case. - void movie_mode(); - - void reset(); - void close_rom(); - - bool save_state(std::ostream* os); - bool load_state(std::istream* is); - - //commands from mmu - void reset_command(); - u8 data_command(u8); - - //this info was saved before the last reset (used for savestate compatibility) - struct SavedInfo - { - u32 addr_size; - } savedInfo; - - //and these are used by old savestates - void load_old_state(u32 addr_size, u8* data, u32 datasize); - static u32 addr_size_for_old_save_size(int bupmem_size); - static u32 addr_size_for_old_save_type(int bupmem_type); - - static u32 pad_up_size(u32 startSize); - void raw_applyUserSettings(u32& size); - - bool load_duc(const char* filename); - bool load_raw(const char* filename); - bool save_raw(const char* filename); - bool load_movie(std::istream* is); - - //call me once a second or so to lazy flush the save data - //here's the reason for this system: we want to dump save files when theyre READ - //so that we have a better idea earlier on how large they are. but it slows things down - //way too much if we flush whenever we read. - void lazy_flush(); - -private: - BOOL write_enable; //is write enabled? - u32 com; //persistent command actually handled - u32 addr_size, addr_counter; - u32 addr; - bool isMovieMode; - - std::string filename; - std::vector data; - std::vector data_autodetect; - enum STATE { - DETECTING = 0, RUNNING = 1 - } state; - - void loadfile(); - bool _loadfile(const char *fname); - void ensure(u32 addr); - void flush(); - - bool flushPending, lazyFlushPending; -}; - -#define NDS_FW_SIZE_V1 (256 * 1024) /* size of fw memory on nds v1 */ -#define NDS_FW_SIZE_V2 (512 * 1024) /* size of fw memory on nds v2 */ - -void mc_init(memory_chip_t *mc, int type); /* reset and init values for memory struct */ -u8 *mc_alloc(memory_chip_t *mc, u32 size); /* alloc mc memory */ -void mc_realloc(memory_chip_t *mc, int type, u32 size); /* realloc mc memory */ -void mc_load_file(memory_chip_t *mc, const char* filename); /* load save file and setup fp */ -void mc_free(memory_chip_t *mc); /* delete mc memory */ -void fw_reset_com(memory_chip_t *mc); /* reset communication with mc */ -u8 fw_transfer(memory_chip_t *mc, u8 data); - -void backup_setManualBackupType(int type); - -#endif /*__FW_H__*/ - +/* Copyright (C) 2006 thoduv + Copyright (C) 2006 Theo Berkau + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#ifndef __FW_H__ +#define __FW_H__ + +#include +#include "types.h" + +#define MC_TYPE_AUTODETECT 0x0 +#define MC_TYPE_EEPROM1 0x1 +#define MC_TYPE_EEPROM2 0x2 +#define MC_TYPE_FLASH 0x3 +#define MC_TYPE_FRAM 0x4 + +#define MC_SIZE_4KBITS 0x000200 +#define MC_SIZE_64KBITS 0x002000 +#define MC_SIZE_256KBITS 0x008000 +#define MC_SIZE_512KBITS 0x010000 +#define MC_SIZE_1MBITS 0x020000 +#define MC_SIZE_2MBITS 0x040000 +#define MC_SIZE_4MBITS 0x080000 +#define MC_SIZE_8MBITS 0x100000 +#define MC_SIZE_16MBITS 0x200000 +#define MC_SIZE_64MBITS 0x800000 + +typedef struct +{ + u8 com; /* persistent command actually handled */ + u32 addr; /* current address for reading/writing */ + u8 addr_shift; /* shift for address (since addresses are transfered by 3 bytes units) */ + u8 addr_size; /* size of addr when writing/reading */ + + BOOL write_enable; /* is write enabled ? */ + + u8 *data; /* memory data */ + u32 size; /* memory size */ + BOOL writeable_buffer; /* is "data" writeable ? */ + int type; /* type of Memory */ + char *filename; + FILE *fp; + u8 autodetectbuf[32768]; + int autodetectsize; +} memory_chip_t; + +#define NDS_FW_SIZE_V1 (256 * 1024) /* size of fw memory on nds v1 */ +#define NDS_FW_SIZE_V2 (512 * 1024) /* size of fw memory on nds v2 */ + +void mc_init(memory_chip_t *mc, int type); /* reset and init values for memory struct */ +u8 *mc_alloc(memory_chip_t *mc, u32 size); /* alloc mc memory */ +void mc_realloc(memory_chip_t *mc, int type, u32 size); /* realloc mc memory */ +void mc_load_file(memory_chip_t *mc, const char* filename); /* load save file and setup fp */ +int mc_load_duc(memory_chip_t *mc, const char* filename); /* load Action Replay DS save file */ +void mc_free(memory_chip_t *mc); /* delete mc memory */ +void mc_reset_com(memory_chip_t *mc); /* reset communication with mc */ +u8 fw_transfer(memory_chip_t *mc, u8 data); /* transfer to, then receive data from firmware */ +u8 bm_transfer(memory_chip_t *mc, u8 data); /* transfer to, then receive data from backup memory */ + +#endif /*__FW_H__*/ + diff --git a/desmume/src/mem.h b/src/mem.h similarity index 96% rename from desmume/src/mem.h rename to src/mem.h index 261f7c138..4b0d4cd7c 100644 --- a/desmume/src/mem.h +++ b/src/mem.h @@ -1,164 +1,164 @@ -/* Copyright 2005-2006 Guillaume Duhamel - Copyright 2005 Theo Berkau - - This file is part of Yabause. - - Yabause is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - Yabause is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with Yabause; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#ifndef MEM_H -#define MEM_H - -#include -#include -#include "types.h" - -/* Type 1 Memory, faster for byte (8 bits) accesses */ - -static INLINE u8 T1ReadByte(u8* const mem, const u32 addr) -{ - return mem[addr]; -} - -static INLINE u16 T1ReadWord_guaranteedAligned(void* const mem, const u32 addr) -{ - assert((addr&1)==0); -#ifdef WORDS_BIGENDIAN - return (((u8*)mem)[addr + 1] << 8) | ((u8*)mem)[addr]; -#else - return *(u16*)((u8*)mem + addr); -#endif -} - -static INLINE u16 T1ReadWord(void* const mem, const u32 addr) -{ -#ifdef WORDS_BIGENDIAN - return (((u8*)mem)[addr + 1] << 8) | ((u8*)mem)[addr]; -#else - return *((u16 *) ((u8*)mem + addr)); -#endif -} - -static INLINE u32 T1ReadLong_guaranteedAligned(u8* const mem, const u32 addr) -{ - assert((addr&3)==0); -#ifdef WORDS_BIGENDIAN - return (mem[addr + 3] << 24 | mem[addr + 2] << 16 | - mem[addr + 1] << 8 | mem[addr]); -#else - return *(u32*)(mem + addr); -#endif -} - - -static INLINE u32 T1ReadLong(u8* const mem, const u32 addr) -{ -#ifdef WORDS_BIGENDIAN - return (mem[addr + 3] << 24 | mem[addr + 2] << 16 | - mem[addr + 1] << 8 | mem[addr]); -#else - return *((u32 *)mem + (addr>>2)); -#endif -} - -static INLINE u64 T1ReadQuad(u8* const mem, const u32 addr) -{ -#ifdef WORDS_BIGENDIAN - return (u64(mem[addr + 7]) << 56 | u64(mem[addr + 6]) << 48 | - u64(mem[addr + 5]) << 40 | u64(mem[addr + 4]) << 32 | - u64(mem[addr + 3]) << 24 | u64(mem[addr + 2]) << 16 | - u64(mem[addr + 1]) << 8 | u64(mem[addr ])); -#else - return *((u64 *) (mem + addr)); -#endif -} - -static INLINE void T1WriteByte(u8* const mem, const u32 addr, const u8 val) -{ - mem[addr] = val; -} - -static INLINE void T1WriteWord(u8* const mem, const u32 addr, const u16 val) -{ -#ifdef WORDS_BIGENDIAN - mem[addr + 1] = val >> 8; - mem[addr] = val & 0xFF; -#else - *((u16 *) (mem + addr)) = val; -#endif -} - -static INLINE void T1WriteLong(u8* const mem, const u32 addr, const u32 val) -{ -#ifdef WORDS_BIGENDIAN - mem[addr + 3] = val >> 24; - mem[addr + 2] = (val >> 16) & 0xFF; - mem[addr + 1] = (val >> 8) & 0xFF; - mem[addr] = val & 0xFF; -#else - *((u32 *) (mem + addr)) = val; -#endif -} - -/* Type 2 Memory, faster for word (16 bits) accesses */ - -static INLINE u8 T2ReadByte(u8* const mem, const u32 addr) -{ -#ifdef WORDS_BIGENDIAN - return mem[addr ^ 1]; -#else - return mem[addr]; -#endif -} - -static INLINE u16 T2ReadWord(u8* const mem, const u32 addr) -{ - return *((u16 *) (mem + addr)); -} - -static INLINE u32 T2ReadLong(u8* const mem, const u32 addr) -{ -#ifdef WORDS_BIGENDIAN - return *((u16 *) (mem + addr + 2)) << 16 | *((u16 *) (mem + addr)); -#else - return *((u32 *) (mem + addr)); -#endif -} - -static INLINE void T2WriteByte(u8* const mem, const u32 addr, const u8 val) -{ -#ifdef WORDS_BIGENDIAN - mem[addr ^ 1] = val; -#else - mem[addr] = val; -#endif -} - -static INLINE void T2WriteWord(u8* const mem, const u32 addr, const u16 val) -{ - *((u16 *) (mem + addr)) = val; -} - -static INLINE void T2WriteLong(u8* const mem, const u32 addr, const u32 val) -{ -#ifdef WORDS_BIGENDIAN - *((u16 *) (mem + addr + 2)) = val >> 16; - *((u16 *) (mem + addr)) = val & 0xFFFF; -#else - *((u32 *) (mem + addr)) = val; -#endif -} - -#endif +/* Copyright 2005-2006 Guillaume Duhamel + Copyright 2005 Theo Berkau + + This file is part of Yabause. + + Yabause is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + Yabause is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with Yabause; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#ifndef MEM_H +#define MEM_H + +#include +#include +#include "types.h" + +/* Type 1 Memory, faster for byte (8 bits) accesses */ + +static INLINE u8 T1ReadByte(u8* const mem, const u32 addr) +{ + return mem[addr]; +} + +static INLINE u16 T1ReadWord_guaranteedAligned(void* const mem, const u32 addr) +{ + assert((addr&1)==0); +#ifdef WORDS_BIGENDIAN + return (((u8*)mem)[addr + 1] << 8) | ((u8*)mem)[addr]; +#else + return *(u16*)((u8*)mem + addr); +#endif +} + +static INLINE u16 T1ReadWord(void* const mem, const u32 addr) +{ +#ifdef WORDS_BIGENDIAN + return (((u8*)mem)[addr + 1] << 8) | ((u8*)mem)[addr]; +#else + return *((u16 *) ((u8*)mem + addr)); +#endif +} + +static INLINE u32 T1ReadLong_guaranteedAligned(u8* const mem, const u32 addr) +{ + assert((addr&3)==0); +#ifdef WORDS_BIGENDIAN + return (mem[addr + 3] << 24 | mem[addr + 2] << 16 | + mem[addr + 1] << 8 | mem[addr]); +#else + return *(u32*)(mem + addr); +#endif +} + + +static INLINE u32 T1ReadLong(u8* const mem, const u32 addr) +{ +#ifdef WORDS_BIGENDIAN + return (mem[addr + 3] << 24 | mem[addr + 2] << 16 | + mem[addr + 1] << 8 | mem[addr]); +#else + return *((u32 *)mem + (addr>>2)); +#endif +} + +static INLINE u64 T1ReadQuad(u8* const mem, const u32 addr) +{ +#ifdef WORDS_BIGENDIAN + return (u64(mem[addr + 7]) << 56 | u64(mem[addr + 6]) << 48 | + u64(mem[addr + 5]) << 40 | u64(mem[addr + 4]) << 32 | + u64(mem[addr + 3]) << 24 | u64(mem[addr + 2]) << 16 | + u64(mem[addr + 1]) << 8 | u64(mem[addr ])); +#else + return *((u64 *) (mem + addr)); +#endif +} + +static INLINE void T1WriteByte(u8* const mem, const u32 addr, const u8 val) +{ + mem[addr] = val; +} + +static INLINE void T1WriteWord(u8* const mem, const u32 addr, const u16 val) +{ +#ifdef WORDS_BIGENDIAN + mem[addr + 1] = val >> 8; + mem[addr] = val & 0xFF; +#else + *((u16 *) (mem + addr)) = val; +#endif +} + +static INLINE void T1WriteLong(u8* const mem, const u32 addr, const u32 val) +{ +#ifdef WORDS_BIGENDIAN + mem[addr + 3] = val >> 24; + mem[addr + 2] = (val >> 16) & 0xFF; + mem[addr + 1] = (val >> 8) & 0xFF; + mem[addr] = val & 0xFF; +#else + *((u32 *) (mem + addr)) = val; +#endif +} + +/* Type 2 Memory, faster for word (16 bits) accesses */ + +static INLINE u8 T2ReadByte(u8* const mem, const u32 addr) +{ +#ifdef WORDS_BIGENDIAN + return mem[addr ^ 1]; +#else + return mem[addr]; +#endif +} + +static INLINE u16 T2ReadWord(u8* const mem, const u32 addr) +{ + return *((u16 *) (mem + addr)); +} + +static INLINE u32 T2ReadLong(u8* const mem, const u32 addr) +{ +#ifdef WORDS_BIGENDIAN + return *((u16 *) (mem + addr + 2)) << 16 | *((u16 *) (mem + addr)); +#else + return *((u32 *) (mem + addr)); +#endif +} + +static INLINE void T2WriteByte(u8* const mem, const u32 addr, const u8 val) +{ +#ifdef WORDS_BIGENDIAN + mem[addr ^ 1] = val; +#else + mem[addr] = val; +#endif +} + +static INLINE void T2WriteWord(u8* const mem, const u32 addr, const u16 val) +{ + *((u16 *) (mem + addr)) = val; +} + +static INLINE void T2WriteLong(u8* const mem, const u32 addr, const u32 val) +{ +#ifdef WORDS_BIGENDIAN + *((u16 *) (mem + addr + 2)) = val >> 16; + *((u16 *) (mem + addr)) = val & 0xFFFF; +#else + *((u32 *) (mem + addr)) = val; +#endif +} + +#endif diff --git a/desmume/src/memorystream.h b/src/memorystream.h similarity index 95% rename from desmume/src/memorystream.h rename to src/memorystream.h index c796f7cf1..82ca09106 100644 --- a/desmume/src/memorystream.h +++ b/src/memorystream.h @@ -1,305 +1,303 @@ -#ifndef _memorystream_h_ -#define _memorystream_h_ - -#include -#include -#include -#include -#include -#include - -template -class memory_streambuf: public std::streambuf { -private: - - friend class memorystream; - - //the current buffer - T* buf; - - //the current allocated capacity of the buffer - size_t capacity; - - //whether the sequence is owned by the stringbuf - bool myBuf; - - //the logical length of the buffer - size_t length; - - //the current 'write window' starting position within the buffer for writing. - size_t ww; - - //a vector that we have been told to use - std::vector* usevec; - - -public: - - memory_streambuf(int _capacity) - : buf(new T[capacity=_capacity]) - , myBuf(true) - , length(_capacity) - , ww(0) - , usevec(0) - { - sync(); - } - - - memory_streambuf() - : buf(new T[capacity = 128]) - , myBuf(true) - , length(0) - , ww(0) - , usevec(0) - { - sync(); - } - - //constructs a non-expandable streambuf around the provided buffer - memory_streambuf(T* usebuf, int buflength) - : buf(usebuf) - , myBuf(false) - , length(buflength) - , ww(0) - , usevec(0) - { - sync(); - } - - //constructs an expandable streambuf around the provided buffer - memory_streambuf(std::vector* _usevec) - : capacity(_usevec->size()) - , myBuf(false) - , length(_usevec->size()) - , ww(0) - , usevec(_usevec) - { - if(length>0) - buf = &(*_usevec)[0]; - else buf = 0; - - sync(); - } - - ~memory_streambuf() - { - //only cleanup if we own the seq - if(myBuf) delete[] buf; - } - - //the logical length of the buffer - size_t size() - { - sync(); - return length; - } - - //to avoid copying, rebuilds the provided vector and copies the streambuf contents into it - void toVector(std::vector& out) - { - out.resize(length); - memcpy(&out[0],buf,length); - } - - //maybe the compiler can avoid copying, but maybe not: returns a vector representing the current streambuf - std::vector toVector() - { - return std::vector(buf,buf+length); - } - - //if the memorystream wraps a vector, the vector will be trimmed to the correct size,. - //you probably need to use this if you are using the vector wrapper - void trim() - { - if(!usevec) return; - usevec->resize(size()); - } - - //tells the current read or write position - std::streampos tell(std::ios::openmode which) - { - if(which == std::ios::in) - return tellRead(); - else if(which == std::ios::out) - return tellWrite(); - else return -1; - } - - //tells the current read position - std::streampos tellRead() - { - return gptr()-eback(); - } - - //tells the current write position - std::streampos tellWrite() - { - return pptr()-pbase() + ww; - } - - int sync() - { - dosync(-1); - return 0; - } - - T* getbuf() - { - sync(); - return buf; - } - - //if we were provided a buffer, then calling this gives us ownership of it - void giveBuf() { - myBuf = true; - } - - void expand(size_t upto) - { - if(!myBuf && !usevec) - throw new std::runtime_error("memory_streambuf is not expandable"); - - size_t newcapacity; - if(upto == (size_t)-1) - newcapacity = capacity + capacity/2 + 2; - else - newcapacity = std::max(upto,capacity); - - if(newcapacity == capacity) return; - - //if we are supposed to use the vector, then do it now - if(usevec) - { - usevec->resize(newcapacity); - capacity = usevec->size(); - buf = &(*usevec)[0]; - } - else - { - //otherwise, manage our own buffer - T* newbuf = new T[newcapacity]; - memcpy(newbuf,buf,capacity); - delete[] buf; - capacity = newcapacity; - buf = newbuf; - } - } - -private: - - void dosync(int c) - { - size_t wp = tellWrite(); - size_t rp = tellRead(); - - //if we are supposed to insert a character.. - if(c != -1) - { - buf[wp] = c; - wp++; - } - - //the length is determined by the highest character that was ever inserted - length = std::max(length,wp); - - //the write window advances to begin at the current write insertion point - ww = wp; - - //set the new write and read windows - setp(buf+ww, buf + capacity); - setg(buf, buf+rp, buf + length); - } - -protected: - - int overflow(int c) - { - expand((size_t)-1); - dosync(c); - return 1; - } - - std::streambuf::pos_type seekpos(pos_type pos, std::ios::openmode which) - { - //extend if we are seeking the write cursor - if(which & std::ios_base::out) - expand(pos); - - sync(); - - if(which & std::ios_base::in) - setg(buf, buf+pos, buf + length); - if(which & std::ios_base::out) - { - ww = pos; - setp(buf+pos, buf + capacity); - } - - return pos; - } - - pos_type seekoff(off_type off, std::ios::seekdir way, std::ios::openmode which) - { - switch(way) { - case std::ios::beg: - return seekpos(off, which); - case std::ios::cur: - return seekpos(tell(which)+off, which); - case std::ios::end: - return seekpos(length+off, which); - default: - return -1; - } - } - -}; - -//an iostream that uses the memory_streambuf to effectively act much like a c# memorystream -//please call sync() after writing data if you want to read it back -class memorystream : public std::basic_iostream > -{ -public: - memorystream() - : std::basic_iostream >(&streambuf) - {} - - memorystream(int sz) - : std::basic_iostream >(&streambuf) - , streambuf(sz) - {} - - memorystream(char* usebuf, int buflength) - : std::basic_iostream >(&streambuf) - , streambuf(usebuf, buflength) - {} - - memorystream(std::vector* usevec) - : std::basic_iostream >(&streambuf) - , streambuf(usevec) - {} - - //the underlying memory_streambuf - memory_streambuf streambuf; - - -public: - - size_t size() { return streambuf.size(); } - char* buf() { return streambuf.getbuf(); } - //flushes all the writing state and ensures the stream is ready for reading - void sync() { streambuf.sync(); } - //rewinds the cursors to offset 0 - void rewind() { streambuf.seekpos(0,std::ios::in | std::ios::out); } - - //if the memorystream wraps a vector, the vector will be trimmed to the correct size,. - //you probably need to use this if you are using the vector wrapper - void trim() { streambuf.trim(); } - - void giveBuf() { streambuf.giveBuf(); } - - memory_streambuf& getStreambuf() { return streambuf; } -}; - - -#endif +#ifndef _memorystream_h_ +#define _memorystream_h_ + +#include +#include +#include +#include +#include +#include + +template +class memory_streambuf: public std::streambuf { +private: + + friend class memorystream; + + //the current buffer + T* buf; + + //the current allocated capacity of the buffer + size_t capacity; + + //whether the sequence is owned by the stringbuf + bool myBuf; + + //the logical length of the buffer + size_t length; + + //the current 'write window' starting position within the buffer for writing. + size_t ww; + + //a vector that we have been told to use + std::vector* usevec; + + +public: + + memory_streambuf(int _capacity) + : buf(new T[capacity=_capacity]) + , myBuf(true) + , length(_capacity) + , ww(0) + , usevec(0) + { + sync(); + } + + + memory_streambuf() + : buf(new T[capacity = 128]) + , myBuf(true) + , length(0) + , ww(0) + , usevec(0) + { + sync(); + } + + //constructs a non-expandable streambuf around the provided buffer + memory_streambuf(T* usebuf, int buflength) + : buf(usebuf) + , myBuf(false) + , length(buflength) + , ww(0) + , usevec(0) + { + sync(); + } + + //constructs an expandable streambuf around the provided buffer + memory_streambuf(std::vector* _usevec) + : capacity(_usevec->size()) + , myBuf(false) + , length(_usevec->size()) + , ww(0) + , usevec(_usevec) + { + if(length>0) + buf = &(*_usevec)[0]; + else buf = 0; + + sync(); + } + + ~memory_streambuf() + { + //only cleanup if we own the seq + if(myBuf) delete[] buf; + } + + //the logical length of the buffer + size_t size() + { + sync(); + return length; + } + + //to avoid copying, rebuilds the provided vector and copies the streambuf contents into it + void toVector(std::vector& out) + { + out.resize(length); + memcpy(&out[0],buf,length); + } + + //maybe the compiler can avoid copying, but maybe not: returns a vector representing the current streambuf + std::vector toVector() + { + return std::vector(buf,buf+length); + } + + //if the memorystream wraps a vector, the vector will be trimmed to the correct size,. + //you probably need to use this if you are using the vector wrapper + void trim() + { + if(!usevec) return; + usevec->resize(size()); + } + + //tells the current read or write position + std::streampos tell(std::ios::openmode which) + { + if(which == std::ios::in) + return tellRead(); + else if(which == std::ios::out) + return tellWrite(); + else return -1; + } + + //tells the current read position + std::streampos tellRead() + { + return gptr()-eback(); + } + + //tells the current write position + std::streampos tellWrite() + { + return pptr()-pbase() + ww; + } + + int sync() + { + dosync(-1); + return 0; + } + + T* getbuf() + { + sync(); + return buf; + } + + //if we were provided a buffer, then calling this gives us ownership of it + void giveBuf() { + myBuf = true; + } + +private: + + void dosync(int c) + { + size_t wp = tellWrite(); + size_t rp = tellRead(); + + //if we are supposed to insert a character.. + if(c != -1) + { + buf[wp] = c; + wp++; + } + + //the length is determined by the highest character that was ever inserted + length = std::max(length,wp); + + //the write window advances to begin at the current write insertion point + ww = wp; + + //set the new write and read windows + setp(buf+ww, buf + capacity); + setg(buf, buf+rp, buf + length); + } + + void expand(size_t upto) + { + if(!myBuf && !usevec) + throw new std::runtime_error("memory_streambuf is not expandable"); + + size_t newcapacity; + if(upto == (size_t)-1) + newcapacity = capacity + capacity/2 + 2; + else + newcapacity = std::max(upto,capacity); + + if(newcapacity == capacity) return; + + //if we are supposed to use the vector, then do it now + if(usevec) + { + usevec->resize(newcapacity); + capacity = usevec->size(); + buf = &(*usevec)[0]; + } + else + { + //otherwise, manage our own buffer + T* newbuf = new T[newcapacity]; + memcpy(newbuf,buf,capacity); + delete[] buf; + capacity = newcapacity; + buf = newbuf; + } + } + +protected: + + int overflow(int c) + { + expand((size_t)-1); + dosync(c); + return 1; + } + + std::streambuf::pos_type seekpos(pos_type pos, std::ios::openmode which) + { + //extend if we are seeking the write cursor + if(which & std::ios_base::out) + expand(pos); + + sync(); + + if(which & std::ios_base::in) + setg(buf, buf+pos, buf + length); + if(which & std::ios_base::out) + { + ww = pos; + setp(buf+pos, buf + capacity); + } + + return pos; + } + + pos_type seekoff(off_type off, std::ios::seekdir way, std::ios::openmode which) + { + switch(way) { + case std::ios::beg: + return seekpos(off, which); + case std::ios::cur: + return seekpos(tell(which)+off, which); + case std::ios::end: + return seekpos(length+off, which); + default: + return -1; + } + } + +}; + +//an iostream that uses the memory_streambuf to effectively act much like a c# memorystream +//please call sync() after writing data if you want to read it back +class memorystream : public std::basic_iostream > +{ +public: + memorystream() + : std::basic_iostream >(&streambuf) + {} + + memorystream(int sz) + : std::basic_iostream >(&streambuf) + , streambuf(sz) + {} + + memorystream(char* usebuf, int buflength) + : std::basic_iostream >(&streambuf) + , streambuf(usebuf, buflength) + {} + + memorystream(std::vector* usevec) + : std::basic_iostream >(&streambuf) + , streambuf(usevec) + {} + + //the underlying memory_streambuf + memory_streambuf streambuf; + + +public: + + size_t size() { return streambuf.size(); } + char* buf() { return streambuf.getbuf(); } + //flushes all the writing state and ensures the stream is ready for reading + void sync() { streambuf.sync(); } + //rewinds the cursors to offset 0 + void rewind() { streambuf.seekpos(0,std::ios::in | std::ios::out); } + + //if the memorystream wraps a vector, the vector will be trimmed to the correct size,. + //you probably need to use this if you are using the vector wrapper + void trim() { streambuf.trim(); } + + void giveBuf() { streambuf.giveBuf(); } +}; + + +#endif diff --git a/src/mic.cpp b/src/mic.cpp new file mode 100644 index 000000000..93362ac5e --- /dev/null +++ b/src/mic.cpp @@ -0,0 +1,35 @@ +#ifndef WIN32 + +#include "types.h" +#include "mic.h" + +static BOOL silence = TRUE; +int MicButtonPressed; + +BOOL Mic_Init() +{ + return TRUE; +} + +void Mic_Reset() +{ +} + +void Mic_DeInit() +{ +} + +u8 Mic_ReadSample() +{ + if (silence) + return 0; + + return 150; +} + +void Mic_DoNoise(BOOL noise) +{ + silence = !noise; +} + +#endif diff --git a/src/mic.h b/src/mic.h new file mode 100644 index 000000000..508895bd0 --- /dev/null +++ b/src/mic.h @@ -0,0 +1,19 @@ +#ifndef MIC_H +#define MIC_H + +extern int MicButtonPressed; + +#ifdef WIN32 +static char MicSampleName[256]; +char* LoadSample(const char *name); +extern int MicDisplay; +#else +void Mic_DoNoise(BOOL); +#endif + +BOOL Mic_Init(); +void Mic_Reset(); +void Mic_DeInit(); +u8 Mic_ReadSample(); + +#endif diff --git a/desmume/src/movie.cpp b/src/movie.cpp similarity index 92% rename from desmume/src/movie.cpp rename to src/movie.cpp index fdfc0adae..7f22c57ef 100644 --- a/desmume/src/movie.cpp +++ b/src/movie.cpp @@ -31,10 +31,6 @@ #include "rtc.h" #include "common.h" #include "mic.h" -#include "version.h" -#include "GPU_osd.h" -#include "memorystream.h" -#include "path.h" using namespace std; bool freshMovie = false; //True when a movie loads, false when movie is altered. Used to determine if a movie has been altered since opening @@ -59,6 +55,7 @@ bool movie_readonly = true; char curMovieFilename[512] = {0}; MovieData currMovieData; int currRerecordCount; +bool ShowInputDisplay = false; bool movie_reset_command = false; bool movie_lid = false; //-------------- @@ -169,9 +166,9 @@ void MovieRecord::dump(MovieData* md, std::ostream* os, int index) MovieData::MovieData() : version(MOVIE_VERSION) , emuVersion(DESMUME_VERSION_NUMERIC) - , romChecksum(0) , rerecordCount(1) , binaryFlag(false) + , romChecksum(0) { } @@ -212,16 +209,6 @@ void MovieData::installValue(std::string& key, std::string& val) StringToBytes(val,&savestate[0],len); // decodes either base64 or hex } } - else if(key == "sram") - { - int len = Base64StringToBytesLength(val); - if(len == -1) len = HexStringToBytesLength(val); // wasn't base64, try hex - if(len >= 1) - { - sram.resize(len); - StringToBytes(val,&sram[0],len); // decodes either base64 or hex - } - } } @@ -248,8 +235,6 @@ int MovieData::dump(std::ostream *os, bool binary) if(savestate.size() != 0) *os << "savestate " << BytesToString(&savestate[0],savestate.size()) << endl; - if(sram.size() != 0) - *os << "sram " << BytesToString(&sram[0],sram.size()) << endl; if(binary) { //put one | to start the binary dump @@ -408,7 +393,7 @@ void FCEUI_StopMovie() //begin playing an existing movie -void _CDECL_ FCEUI_LoadMovie(const char *fname, bool _read_only, bool tasedit, int _pauseframe) +void FCEUI_LoadMovie(const char *fname, bool _read_only, bool tasedit, int _pauseframe) { //if(!tasedit && !FCEU_IsValidUI(FCEUI_PLAYMOVIE)) // return; @@ -462,12 +447,7 @@ void _CDECL_ FCEUI_LoadMovie(const char *fname, bool _read_only, bool tasedit, i movieMode = MOVIEMODE_PLAY; currRerecordCount = currMovieData.rerecordCount; InitMovieTime(); - MMU_new.backupDevice.movie_mode(); - if(currMovieData.sram.size() != 0) - { - bool success = MovieData::loadSramFrom(&currMovieData.sram); - if(!success) return; - } + MovieSRAM(); freshMovie = true; ClearAutoHold(); @@ -486,55 +466,10 @@ static void openRecordingMovie(const char* fname) strcpy(curMovieFilename, fname); } -bool MovieData::loadSramFrom(std::vector* buf) -{ - memorystream ms(buf); - MMU_new.backupDevice.load_movie(&ms); - return true; -} - -static bool FCEUSS_SaveSRAM(std::ostream* outstream, std:: string fname) -{ - //a temp memory stream. we'll dump some data here and then compress - //TODO - support dumping directly without compressing to save a buffer copy - - memorystream ms; - std::ostream* os = (std::ostream*)&ms; - - //size it - FILE * fp = fopen( fname.c_str(), "r" ); - if(!fp) - return 0; - - fseek( fp, 0, SEEK_END ); - int size = ftell(fp); - fclose(fp); - - filebuf fb; - fb.open (fname.c_str(), ios::in | ios::binary);//ios::in - istream is(&fb); - - char *buffer = new char[size]; - - is.read(buffer, size); - - outstream->write((char*)buffer,size); - - fb.close(); - - return true; -} - -void MovieData::dumpSramTo(std::vector* buf, std::string sramfname) { - - memorystream ms(buf); - FCEUSS_SaveSRAM(&ms, sramfname); - ms.trim(); -} //begin recording a new movie //TODO - BUG - the record-from-another-savestate doesnt work. -void _CDECL_ FCEUI_SaveMovie(const char *fname, std::wstring author, int flag, std::string sramfname) + void FCEUI_SaveMovie(const char *fname, std::wstring author) { //if(!FCEU_IsValidUI(FCEUI_RECORDMOVIE)) // return; @@ -554,7 +489,7 @@ void _CDECL_ FCEUI_SaveMovie(const char *fname, std::wstring author, int flag, s if(author != L"") currMovieData.comments.push_back(L"author " + author); currMovieData.romChecksum = gameInfo.crc; currMovieData.romSerial = gameInfo.ROMserial; - currMovieData.romFilename = path.GetRomName(); + currMovieData.romFilename = GetRomName(); NDS_Reset(); @@ -563,9 +498,6 @@ void _CDECL_ FCEUI_SaveMovie(const char *fname, std::wstring author, int flag, s //else // MovieData::dumpSavestateTo(&currMovieData.savestate,Z_BEST_COMPRESSION); - if(flag == 1) - MovieData::dumpSramTo(&currMovieData.sram, sramfname); - //we are going to go ahead and dump the header. from now on we will only be appending frames currMovieData.dump(osRecordingMovie, false); @@ -579,13 +511,7 @@ void _CDECL_ FCEUI_SaveMovie(const char *fname, std::wstring author, int flag, s movie_readonly = false; currRerecordCount = 0; InitMovieTime(); - MMU_new.backupDevice.movie_mode(); - - if(currMovieData.sram.size() != 0) - { - bool success = MovieData::loadSramFrom(&currMovieData.sram); - if(!success) return; - } + MovieSRAM(); driver->USR_InfoMessage("Movie recording started."); } @@ -618,6 +544,11 @@ void _CDECL_ FCEUI_SaveMovie(const char *fname, std::wstring author, int flag, s //either dumps the current joystick state or loads one state from the movie void FCEUMOV_AddInputState() { + //todo - for tasedit, either dump or load depending on whether input recording is enabled + //or something like that + //(input recording is just like standard read+write movie recording with input taken from gamepad) + //otherwise, it will come from the tasedit data. + if(movieMode == MOVIEMODE_PLAY) { //stop when we run out of frames @@ -695,8 +626,13 @@ void _CDECL_ FCEUI_SaveMovie(const char *fname, std::wstring author, int flag, s osd->addFixed(180, 176, "%s", "Recording"); } + currFrameCounter++; + /*extern uint8 joy[4]; memcpy(&cur_input_display,joy,4);*/ + + if (ShowInputDisplay && nds.isTouch) + osd->addFixed(nds.touchX >> 4, (nds.touchY >> 4) + 192 , "%s %d %d", "X", nds.touchX >> 4, nds.touchY >> 4); } diff --git a/desmume/src/movie.h b/src/movie.h similarity index 92% rename from desmume/src/movie.h rename to src/movie.h index 432a6226b..d1857539d 100644 --- a/desmume/src/movie.h +++ b/src/movie.h @@ -119,7 +119,6 @@ public: std::string romSerial; std::string romFilename; std::vector savestate; - std::vector sram; std::vector records; std::vector comments; @@ -167,9 +166,6 @@ public: static bool loadSavestateFrom(std::vector* buf); static void dumpSavestateTo(std::vector* buf, int compressionLevel); - - static bool loadSramFrom(std::vector* buf); - static void dumpSramTo(std::vector* buf, std::string sramfname); //void TryDumpIncremental(); private: @@ -192,8 +188,8 @@ extern bool movie_reset_command; extern bool movie_lid; bool FCEUI_MovieGetInfo(std::istream* fp, MOVIE_INFO& info, bool skipFrameCount); -void _CDECL_ FCEUI_SaveMovie(const char *fname, std::wstring author, int flag, std::string sramfname); -void _CDECL_ FCEUI_LoadMovie(const char *fname, bool _read_only, bool tasedit, int _pauseframe); +void FCEUI_SaveMovie(const char *fname, std::wstring author); +void FCEUI_LoadMovie(const char *fname, bool _read_only, bool tasedit, int _pauseframe); void FCEUI_StopMovie(); void FCEUMOV_AddInputState(); void NDS_setTouchFromMovie(void); diff --git a/desmume/src/rasterize.cpp b/src/rasterize.cpp similarity index 94% rename from desmume/src/rasterize.cpp rename to src/rasterize.cpp index 2f584327e..2ebd066a7 100644 --- a/desmume/src/rasterize.cpp +++ b/src/rasterize.cpp @@ -64,8 +64,6 @@ template T _max(T a, T b, T c) { return max(max(a,b),c); } template T _min(T a, T b, T c, T d) { return min(_min(a,b,d),c); } template T _max(T a, T b, T c, T d) { return max(_max(a,b,d),c); } -static const int kUnsetTranslucentPolyID = 255; - static int polynum; static u8 modulate_table[32][32]; @@ -394,6 +392,9 @@ struct Shader u = invu*w; v = invv*w; texColor = sampler.sample(u,v); + if(texColor.r != 0x1f || texColor.g != 0x1f || texColor.b != 0x1f) { + int zzz=9; + } FragmentColor toonColor = toonTable[materialColor.r]; if(sampler.texFormat == 0) { @@ -443,7 +444,7 @@ static FORCEINLINE void alphaBlend(FragmentColor & dst, const FragmentColor & sr u8 dstAlpha = dst.a; if(gfx3d.enableAlphaBlending) { - if(src.a == 0 || dst.a == 0) + if(src.a == 0) { dst = src; } @@ -539,18 +540,33 @@ static FORCEINLINE void pixel(int adr,float r, float g, float b, float invu, flo { if(polyAttr.polyid == 0) { + destFragment.stencil = 1; goto rejected_fragment; } else { + //some shadow volumes are rendering two-sided + //and this is the only way to fix them. + //rendering two-sided makes no sense, since the back side + //will clear the stencil bit and cause the shadow to get drawn in + //empty space. + //but yet, it is done, and gbatek even suggests that we should do it + if(polyAttr.backfacing) + goto rejected_fragment; + //now, if we arent supposed to draw shadow here, then bail out - if(destFragment.stencil == 0) + if(destFragment.stencil == 1) { + destFragment.stencil = 0; goto rejected_fragment; } destFragment.stencil = 0; } + + //reset the shadow flag to keep the shadow from getting drawn more than once + //if(polyAttr.polyid == 0) + // destFragment.stencil = 1; } //handle polyids @@ -596,10 +612,10 @@ static FORCEINLINE void pixel(int adr,float r, float g, float b, float invu, flo depth_fail: //handle stencil-writing in shadow mode - if((shader.mode == 3) && (polyAttr.polyid == 0)) +/* if((shader.mode == 3) && (polyAttr.polyid == 0)) { destFragment.stencil = 1; - } + }*/ rejected_fragment: done_with_pixel: @@ -612,7 +628,7 @@ typedef int fixed28_4; static bool failure; // handle floor divides and mods correctly -FORCEINLINE void FloorDivMod(long Numerator, long Denominator, long &Floor, long &Mod) +INLINE void FloorDivMod(long Numerator, long Denominator, long &Floor, long &Mod) { //These must be caused by invalid or degenerate shapes.. not sure yet. //check it out in the mario face intro of SM64 @@ -643,10 +659,10 @@ FORCEINLINE void FloorDivMod(long Numerator, long Denominator, long &Floor, long } } -FORCEINLINE fixed28_4 FloatToFixed28_4( float Value ) { +INLINE fixed28_4 FloatToFixed28_4( float Value ) { return (fixed28_4)(Value * 16); } -FORCEINLINE float Fixed28_4ToFloat( fixed28_4 Value ) { +INLINE float Fixed28_4ToFloat( fixed28_4 Value ) { return Value / 16.0; } //inline fixed16_16 FloatToFixed16_16( float Value ) { @@ -655,11 +671,11 @@ FORCEINLINE float Fixed28_4ToFloat( fixed28_4 Value ) { //inline float Fixed16_16ToFloat( fixed16_16 Value ) { // return Value / 65536.0; //} -FORCEINLINE fixed28_4 Fixed28_4Mul( fixed28_4 A, fixed28_4 B ) { +INLINE fixed28_4 Fixed28_4Mul( fixed28_4 A, fixed28_4 B ) { // could make this asm to prevent overflow return (A * B) / 16; // 28.4 * 28.4 = 24.8 / 16 = 28.4 } -FORCEINLINE int Ceil28_4( fixed28_4 Value ) { +INLINE int Ceil28_4( fixed28_4 Value ) { int ReturnValue; int Numerator = Value - 1 + 16; if(Numerator >= 0) { @@ -685,7 +701,7 @@ struct edge_fx_fl { float curr, step, stepExtra; FORCEINLINE void doStep() { curr += step; } FORCEINLINE void doStepExtra() { curr += stepExtra; } - FORCEINLINE void initialize(float top, float bottom, float dx, float dy, long XStep, float XPrestep, float YPrestep) { + void initialize(float top, float bottom, float dx, float dy, long XStep, float XPrestep, float YPrestep) { dx = 0; dy *= (bottom-top); curr = top + YPrestep * dy + XPrestep * dx; @@ -706,8 +722,8 @@ struct edge_fx_fl { }; FORCEINLINE edge_fx_fl::edge_fx_fl(int Top, int Bottom) { - Y = Ceil28_4((fixed28_4)verts[Top]->y); - int YEnd = Ceil28_4((fixed28_4)verts[Bottom]->y); + Y = Ceil28_4(verts[Top]->y); + int YEnd = Ceil28_4(verts[Bottom]->y); Height = YEnd - Y; if(Height) @@ -715,13 +731,13 @@ FORCEINLINE edge_fx_fl::edge_fx_fl(int Top, int Bottom) { long dN = long(verts[Bottom]->y - verts[Top]->y); long dM = long(verts[Bottom]->x - verts[Top]->x); - long InitialNumerator = (long)(dM*16*Y - dM*verts[Top]->y + dN*verts[Top]->x - 1 + dN*16); + long InitialNumerator = dM*16*Y - dM*verts[Top]->y + dN*verts[Top]->x - 1 + dN*16; FloorDivMod(InitialNumerator,dN*16,X,ErrorTerm); FloorDivMod(dM*16,dN*16,XStep,Numerator); Denominator = dN*16; - float YPrestep = Fixed28_4ToFloat((fixed28_4)(Y*16 - verts[Top]->y)); - float XPrestep = Fixed28_4ToFloat((fixed28_4)(X*16 - verts[Top]->x)); + float YPrestep = Fixed28_4ToFloat(Y*16 - verts[Top]->y); + float XPrestep = Fixed28_4ToFloat(X*16 - verts[Top]->x); float dy = 1/Fixed28_4ToFloat(dN); float dx = 1/Fixed28_4ToFloat(dM); @@ -749,7 +765,7 @@ FORCEINLINE int edge_fx_fl::Step() { } //draws a single scanline -FORCEINLINE static void drawscanline(edge_fx_fl *pLeft, edge_fx_fl *pRight) +static void drawscanline(edge_fx_fl *pLeft, edge_fx_fl *pRight) { int XStart = pLeft->X; int width = pRight->X - XStart; @@ -1022,10 +1038,12 @@ static void SoftRastConvertFramebuffer() for(int i=0,y=0;y<192;y++) { - // u8* wanx = (u8*)&src[i]; - // #define ASS(X,Y) __asm { prefetchnta [wanx+32*0x##X##Y] } - // #define PUNK(X) ASS(X,0) ASS(X,1) ASS(X,2) ASS(X,3) ASS(X,4) ASS(X,5) ASS(X,6) ASS(X,7) ASS(X,8) ASS(X,9) ASS(X,A) ASS(X,B) ASS(X,C) ASS(X,D) ASS(X,E) ASS(X,F) - // PUNK(0); PUNK(1); + #ifndef NOSSE2 + u8* wanx = (u8*)&src[i]; + #define ASS(X,Y) __asm { prefetchnta [wanx+32*0x##X##Y] } + #define PUNK(X) ASS(X,0) ASS(X,1) ASS(X,2) ASS(X,3) ASS(X,4) ASS(X,5) ASS(X,6) ASS(X,7) ASS(X,8) ASS(X,9) ASS(X,A) ASS(X,B) ASS(X,C) ASS(X,D) ASS(X,E) ASS(X,F) + PUNK(0); PUNK(1); + #endif for(int x=0;x<256;x++,i++) { @@ -1042,7 +1060,7 @@ static void SoftRastConvertFramebuffer() template static T interpolate(const float ratio, const T& x0, const T& x1) { - return (T)(x0 + (float)(x1-x0) * (ratio)); + return x0 + (float)(x1-x0) * (ratio); } @@ -1215,7 +1233,7 @@ static void SoftRastRender() //special value for uninitialized translucent polyid. without this, fires in spiderman2 dont display //I am not sure whether it is right, though. previously this was cleared to 0, as a guess, //but in spiderman2 some fires with polyid 0 try to render on top of the background - clearFragment.polyid.translucent = kUnsetTranslucentPolyID; + clearFragment.polyid.translucent = 255; clearFragment.depth = gfx3d.clearDepth; clearFragment.stencil = 0; for(int i=0;i<256*192;i++) @@ -1381,7 +1399,7 @@ static void SoftRastRender() //which is currently just a float for(int j=0;jpolyAttr); diff --git a/desmume/src/rasterize.h b/src/rasterize.h similarity index 96% rename from desmume/src/rasterize.h rename to src/rasterize.h index 9f24e2c04..ca7a515e9 100644 --- a/desmume/src/rasterize.h +++ b/src/rasterize.h @@ -1,31 +1,31 @@ -/* Copyright (C) 2006 yopyop - yopyop156@ifrance.com - yopyop156.ifrance.com - - Copyright 2009 DeSmuME team - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -*/ - -#ifndef _RASTERIZE_H_ -#define _RASTERIZE_H_ - -#include "render3D.h" - -extern GPU3DInterface gpu3DRasterize; - -#endif +/* Copyright (C) 2006 yopyop + yopyop156@ifrance.com + yopyop156.ifrance.com + + Copyright 2009 DeSmuME team + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA +*/ + +#ifndef _RASTERIZE_H_ +#define _RASTERIZE_H_ + +#include "render3D.h" + +extern GPU3DInterface gpu3DRasterize; + +#endif diff --git a/desmume/src/readwrite.cpp b/src/readwrite.cpp similarity index 63% rename from desmume/src/readwrite.cpp rename to src/readwrite.cpp index dc8ae1e5e..f7a64ff39 100644 --- a/desmume/src/readwrite.cpp +++ b/src/readwrite.cpp @@ -1,183 +1,157 @@ -/* readwrite.cpp - - Copyright (C) 2006-2009 DeSmuME team - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -*/ - -#include "readwrite.h" -#include "types.h" - -//well. just for the sake of consistency -int write8le(u8 b, FILE *fp) -{ - return((fwrite(&b,1,1,fp)<1)?0:1); -} - -//well. just for the sake of consistency -int write8le(u8 b, std::ostream *os) -{ - os->write((char*)&b,1); - return 1; -} - -//well. just for the sake of consistency -int read8le(u8 *Bufo, std::istream *is) -{ - if(is->read((char*)Bufo,1).gcount() != 1) - return 0; - return 1; -} - -///writes a little endian 16bit value to the specified file -int write16le(u16 b, FILE *fp) -{ - u8 s[2]; - s[0]=b; - s[1]=b>>8; - return((fwrite(s,1,2,fp)<2)?0:2); -} - - -///writes a little endian 16bit value to the specified file -int write16le(u16 b, std::ostream *os) -{ - u8 s[2]; - s[0]=b; - s[1]=b>>8; - os->write((char*)&s,2); - return 2; -} - -///writes a little endian 32bit value to the specified file -int write32le(u32 b, FILE *fp) -{ - u8 s[4]; - s[0]=b; - s[1]=b>>8; - s[2]=b>>16; - s[3]=b>>24; - return((fwrite(s,1,4,fp)<4)?0:4); -} - -int write32le(u32 b, std::ostream* os) -{ - u8 s[4]; - s[0]=b; - s[1]=b>>8; - s[2]=b>>16; - s[3]=b>>24; - os->write((char*)&s,4); - return 4; -} - -void writebool(bool b, std::ostream* os) { write32le(b?1:0,os); } - -int write64le(u64 b, std::ostream* os) -{ - u8 s[8]; - s[0]=b; - s[1]=b>>8; - s[2]=b>>16; - s[3]=b>>24; - s[4]=b>>32; - s[5]=b>>40; - s[6]=b>>48; - s[7]=b>>56; - os->write((char*)&s,8); - return 8; -} - - -///reads a little endian 32bit value from the specified file -int read32le(u32 *Bufo, FILE *fp) -{ - u32 buf; - if(fread(&buf,1,4,fp)<4) - return 0; -#ifdef LOCAL_LE - *(u32*)Bufo=buf; -#else - *(u32*)Bufo=((buf&0xFF)<<24)|((buf&0xFF00)<<8)|((buf&0xFF0000)>>8)|((buf&0xFF000000)>>24); -#endif - return 1; -} - -int read16le(u16 *Bufo, std::istream *is) -{ - u16 buf; - if(is->read((char*)&buf,2).gcount() != 2) - return 0; -#ifdef LOCAL_LE - *Bufo=buf; -#else - *Bufo = LE_TO_LOCAL_16(buf); -#endif - return 1; -} - -///reads a little endian 64bit value from the specified file -int read64le(u64 *Bufo, std::istream *is) -{ - u64 buf; - if(is->read((char*)&buf,8).gcount() != 8) - return 0; -#ifdef LOCAL_LE - *Bufo=buf; -#else - *Bufo = LE_TO_LOCAL_64(buf); -#endif - return 1; -} - -int read32le(u32 *Bufo, std::istream *is) -{ - u32 buf; - if(is->read((char*)&buf,4).gcount() != 4) - return 0; -#ifdef LOCAL_LE - *(u32*)Bufo=buf; -#else - *(u32*)Bufo=((buf&0xFF)<<24)|((buf&0xFF00)<<8)|((buf&0xFF0000)>>8)|((buf&0xFF000000)>>24); -#endif - return 1; -} - -int readbool(bool *b, std::istream* is) -{ - u32 temp; - int ret = read32le(&temp,is); - *b = (bool)temp; - return ret; -} - -int readbuffer(std::vector &vec, std::istream* is) -{ - u32 size; - if(read32le(&size,is) != 1) return 0; - vec.resize(size); - if(size>0) is->read((char*)&vec[0],size); - return 1; -} - -int writebuffer(std::vector& vec, std::ostream* os) -{ - u32 size = vec.size(); - write32le(size,os); - if(size>0) os->write((char*)&vec[0],size); - return 1; -} +/* readwrite.cpp + * + * Copyright (C) 2006-2008 Zeromus + * + * This file is part of DeSmuME + * + * DeSmuME is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * DeSmuME is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with DeSmuME; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA +*/ + +#include "readwrite.h" +#include "types.h" + +//well. just for the sake of consistency +int write8le(u8 b, FILE *fp) +{ + return((fwrite(&b,1,1,fp)<1)?0:1); +} + +//well. just for the sake of consistency +int write8le(u8 b, std::ostream *os) +{ + os->write((char*)&b,1); + return 1; +} + +//well. just for the sake of consistency +int read8le(u8 *Bufo, std::istream *is) +{ + if(is->read((char*)Bufo,1).gcount() != 1) + return 0; + return 1; +} + +///writes a little endian 16bit value to the specified file +int write16le(u16 b, FILE *fp) +{ + u8 s[2]; + s[0]=b; + s[1]=b>>8; + return((fwrite(s,1,2,fp)<2)?0:2); +} + + +///writes a little endian 16bit value to the specified file +int write16le(u16 b, std::ostream *os) +{ + u8 s[2]; + s[0]=b; + s[1]=b>>8; + os->write((char*)&s,2); + return 2; +} + +///writes a little endian 32bit value to the specified file +int write32le(u32 b, FILE *fp) +{ + u8 s[4]; + s[0]=b; + s[1]=b>>8; + s[2]=b>>16; + s[3]=b>>24; + return((fwrite(s,1,4,fp)<4)?0:4); +} + +int write32le(u32 b, std::ostream* os) +{ + u8 s[4]; + s[0]=b; + s[1]=b>>8; + s[2]=b>>16; + s[3]=b>>24; + os->write((char*)&s,4); + return 4; +} + +int write64le(u64 b, std::ostream* os) +{ + u8 s[8]; + s[0]=b; + s[1]=b>>8; + s[2]=b>>16; + s[3]=b>>24; + s[4]=b>>32; + s[5]=b>>40; + s[6]=b>>48; + s[7]=b>>56; + os->write((char*)&s,8); + return 8; +} + + +///reads a little endian 32bit value from the specified file +int read32le(u32 *Bufo, FILE *fp) +{ + u32 buf; + if(fread(&buf,1,4,fp)<4) + return 0; +#ifdef LOCAL_LE + *(u32*)Bufo=buf; +#else + *(u32*)Bufo=((buf&0xFF)<<24)|((buf&0xFF00)<<8)|((buf&0xFF0000)>>8)|((buf&0xFF000000)>>24); +#endif + return 1; +} + +int read16le(u16 *Bufo, std::istream *is) +{ + u16 buf; + if(is->read((char*)&buf,2).gcount() != 2) + return 0; +#ifdef LOCAL_LE + *Bufo=buf; +#else + *Bufo = LE_TO_LOCAL_16(buf); +#endif + return 1; +} + +///reads a little endian 64bit value from the specified file +int read64le(u64 *Bufo, std::istream *is) +{ + u64 buf; + if(is->read((char*)&buf,8).gcount() != 8) + return 0; +#ifdef LOCAL_LE + *Bufo=buf; +#else + *Bufo = LE_TO_LOCAL_64(buf); +#endif + return 1; +} + +int read32le(u32 *Bufo, std::istream *is) +{ + u32 buf; + if(is->read((char*)&buf,4).gcount() != 4) + return 0; +#ifdef LOCAL_LE + *(u32*)Bufo=buf; +#else + *(u32*)Bufo=((buf&0xFF)<<24)|((buf&0xFF00)<<8)|((buf&0xFF0000)>>8)|((buf&0xFF000000)>>24); +#endif + return 1; +} + diff --git a/desmume/src/readwrite.h b/src/readwrite.h similarity index 78% rename from desmume/src/readwrite.h rename to src/readwrite.h index 6ee2f6225..a1b6f39cf 100644 --- a/desmume/src/readwrite.h +++ b/src/readwrite.h @@ -1,30 +1,24 @@ -#ifndef _READWRITE_H_ -#define _READWRITE_H_ - -#include "types.h" -#include -#include -#include - -//well. just for the sake of consistency -int write8le(u8 b, FILE *fp); -int write8le(u8 b, std::ostream *os); -int write16le(u16 b, FILE *fp); -int write16le(u16 b, std::ostream* os); -int write32le(u32 b, FILE *fp); -int write32le(u32 b, std::ostream* os); -int write64le(u64 b, std::ostream* os); -int read64le(u64 *Bufo, std::istream *is); -int read32le(u32 *Bufo, std::istream *is); -inline int read32le(int *Bufo, std::istream *is) { return read32le((u32*)Bufo,is); } -int read32le(u32 *Bufo, FILE *fp); -int read16le(u16 *Bufo, std::istream *is); -inline int read16le(s16 *Bufo, std::istream* is) { return read16le((u16*)Bufo,is); } -int read8le(u8 *Bufo, std::istream *is); -int readbool(bool *b, std::istream* is); -void writebool(bool b, std::ostream* os); - -int readbuffer(std::vector &vec, std::istream* is); -int writebuffer(std::vector& vec, std::ostream* os); - -#endif +#ifndef _READWRITE_H_ +#define _READWRITE_H_ + +#include "types.h" +#include +#include + +//well. just for the sake of consistency +int write8le(u8 b, FILE *fp); +int write8le(u8 b, std::ostream *os); +int write16le(u16 b, FILE *fp); +int write16le(u16 b, std::ostream* os); +int write32le(u32 b, FILE *fp); +int write32le(u32 b, std::ostream* os); +int write64le(u64 b, std::ostream* os); +int read64le(u64 *Bufo, std::istream *is); +int read32le(u32 *Bufo, std::istream *is); +inline int read32le(int *Bufo, std::istream *is) { return read32le((u32*)Bufo,is); } +int read32le(u32 *Bufo, FILE *fp); +int read16le(u16 *Bufo, std::istream *is); +inline int read16le(s16 *Bufo, std::istream* is) { return read16le((u16*)Bufo,is); } +int read8le(u8 *Bufo, std::istream *is); + +#endif diff --git a/desmume/src/registers.h b/src/registers.h similarity index 97% rename from desmume/src/registers.h rename to src/registers.h index f9060214d..d679e9643 100644 --- a/desmume/src/registers.h +++ b/src/registers.h @@ -1,333 +1,333 @@ -/* Copyright (C) 2006 Theo Berkau - - Ideas borrowed from Stephane Dallongeville's SCSP core - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#ifndef REGISTERS_H -#define REGISTERS_H - -#define REG_REGION_MASK 0x0FFFEF80 -#define REG_BASE_DISPx 0x04000000 -#define REG_BASE_DISPA 0x04000000 -#define REG_BASE_DISPB 0x04001000 -#define REG_BASE_DMA 0x04000080 -#define REG_BASE_SIORTCTIMERS 0x04000100 -#define REG_BASE_ROMIPC 0x04000180 -#define REG_BASE_MEMIRQ 0x04000200 -#define REG_BASE_MATH 0x04000280 -#define REG_BASE_OTHER 0x04000300 -#define REG_BASE_RCVPORTS 0x04100000 - -// Display Engine A -#define REG_DISPA_DISPCNT 0x04000000 -#define REG_DISPA_VCOUNT 0x04000006 -#define REG_DISPA_BG0CNT 0x04000008 -#define REG_DISPA_BG1CNT 0x0400000A -#define REG_DISPA_BG2CNT 0x0400000C -#define REG_DISPA_BG3CNT 0x0400000E -#define REG_DISPA_BG0HOFS 0x04000010 -#define REG_DISPA_BG0VOFS 0x04000012 -#define REG_DISPA_BG1HOFS 0x04000014 -#define REG_DISPA_BG1VOFS 0x04000016 -#define REG_DISPA_BG2HOFS 0x04000018 -#define REG_DISPA_BG2VOFS 0x0400001A -#define REG_DISPA_BG3HOFS 0x0400001C -#define REG_DISPA_BG3VOFS 0x0400001E -#define REG_DISPA_BG2PA 0x04000020 -#define REG_DISPA_BG2PB 0x04000022 -#define REG_DISPA_BG2PC 0x04000024 -#define REG_DISPA_BG2PD 0x04000026 -#define REG_DISPA_BG2XL 0x04000028 -#define REG_DISPA_BG2XH 0x0400002A -#define REG_DISPA_BG2YL 0x0400002C -#define REG_DISPA_BG2YH 0x0400002E -#define REG_DISPA_BG3PA 0x04000030 -#define REG_DISPA_BG3PB 0x04000032 -#define REG_DISPA_BG3PC 0x04000034 -#define REG_DISPA_BG3PD 0x04000036 -#define REG_DISPA_BG3XL 0x04000038 -#define REG_DISPA_BG3XH 0x0400003A -#define REG_DISPA_BG3YL 0x0400003C -#define REG_DISPA_BG3YH 0x0400003E -#define REG_DISPA_WIN0H 0x04000040 -#define REG_DISPA_WIN1H 0x04000042 -#define REG_DISPA_WIN0V 0x04000044 -#define REG_DISPA_WIN1V 0x04000046 -#define REG_DISPA_WININ 0x04000048 -#define REG_DISPA_WINOUT 0x0400004A -#define REG_DISPA_MOSAIC 0x0400004C -#define REG_DISPA_BLDCNT 0x04000050 -#define REG_DISPA_BLDALPHA 0x04000052 -#define REG_DISPA_BLDY 0x04000054 -#define REG_DISPA_MASTERBRIGHT 0x0400006C - -// DMA -#define REG_DMA0SAD 0x040000B0 -#define REG_DMA0DAD 0x040000B4 -#define REG_DMA0CNTL 0x040000B8 -#define REG_DMA0CNTH 0x040000BA -#define REG_DMA1SAD 0x040000BC -#define REG_DMA1DAD 0x040000C0 -#define REG_DMA1CNTL 0x040000C4 -#define REG_DMA1CNTH 0x040000C6 -#define REG_DMA2SAD 0x040000C8 -#define REG_DMA2DAD 0x040000CC -#define REG_DMA2CNTL 0x040000D0 -#define REG_DMA2CNTH 0x040000D2 -#define REG_DMA3SAD 0x040000D4 -#define REG_DMA3DAD 0x040000D8 -#define REG_DMA3CNTL 0x040000DC -#define REG_DMA3CNTH 0x040000DE -#define REG_DMA0FILL 0x040000E0 -#define REG_DMA1FILL 0x040000E4 -#define REG_DMA2FILL 0x040000E8 -#define REG_DMA3FILL 0x040000EC - -// Timers -#define REG_TM0CNTL 0x04000100 -#define REG_TM0CNTH 0x04000102 -#define REG_TM1CNTL 0x04000104 -#define REG_TM1CNTH 0x04000106 -#define REG_TM2CNTL 0x04000108 -#define REG_TM2CNTH 0x0400010A -#define REG_TM3CNTL 0x0400010C -#define REG_TM3CNTH 0x0400010E - -// SIO/Keypad Input/RTC -#define REG_SIODATA32 0x04000120 -#define REG_SIOCNT 0x04000128 -#define REG_KEYINPUT 0x04000130 -#define REG_KEYCNT 0x04000132 -#define REG_RCNT 0x04000134 -#define REG_EXTKEYIN 0x04000136 -#define REG_RTC 0x04000138 - -// IPC -#define REG_IPCSYNC 0x04000180 -#define REG_IPCFIFOCNT 0x04000184 -#define REG_IPCFIFOSEND 0x04000188 - -// ROM -#define REG_AUXSPICNT 0x040001A0 -#define REG_AUXSPIDATA 0x040001A2 -#define REG_GCROMCTRL 0x040001A4 -#define REG_GCCMDOUT 0x040001A8 -#define REG_ENCSEED0L 0x040001B0 -#define REG_ENCSEED1L 0x040001B4 -#define REG_ENCSEED0H 0x040001B8 -#define REG_ENCSEED1H 0x040001BC -#define REG_SPICNT 0x040001C0 -#define REG_SPIDATA 0x040001C2 - -// Memory/IRQ -#define REG_EXMEMCNT 0x04000204 -#define REG_WIFIWAITCNT 0x04000206 -#define REG_IME 0x04000208 -#define REG_IE 0x04000210 -#define REG_IF 0x04000214 -#define REG_VRAMCNTA 0x04000240 -#define REG_VRAMSTAT 0x04000240 -#define REG_VRAMCNTB 0x04000241 -#define REG_WRAMSTAT 0x04000241 -#define REG_VRAMCNTC 0x04000242 -#define REG_VRAMCNTD 0x04000243 -#define REG_VRAMCNTE 0x04000244 -#define REG_VRAMCNTF 0x04000245 -#define REG_VRAMCNTG 0x04000246 -#define REG_WRAMCNT 0x04000247 -#define REG_VRAMCNTH 0x04000248 -#define REG_VRAMCNTI 0x04000249 - -// Math -#define REG_DIVCNT 0x04000280 -#define REG_DIVNUMER 0x04000290 -#define REG_DIVDENOM 0x04000298 -#define REG_DIVRESULT 0x040002A0 -#define REG_DIVREMRESULT 0x040002A8 -#define REG_SQRTCNT 0x040002B0 -#define REG_SQRTRESULT 0x040002B4 -#define REG_SQRTPARAM 0x040002B8 - -// Other -#define REG_POSTFLG 0x04000300 -#define REG_HALTCNT 0x04000301 -#define REG_POWCNT1 0x04000304 -#define REG_POWCNT2 0x04000304 -#define REG_BIOSPROT 0x04000308 - -#define REG_DISPB_DISPCNT 0x04001000 -#define REG_DISPB_BG0CNT 0x04001008 -#define REG_DISPB_BG1CNT 0x0400100A -#define REG_DISPB_BG2CNT 0x0400100C -#define REG_DISPB_BG3CNT 0x0400100E -#define REG_DISPB_BG0HOFS 0x04001010 -#define REG_DISPB_BG0VOFS 0x04001012 -#define REG_DISPB_BG1HOFS 0x04001014 -#define REG_DISPB_BG1VOFS 0x04001016 -#define REG_DISPB_BG2HOFS 0x04001018 -#define REG_DISPB_BG2VOFS 0x0400101A -#define REG_DISPB_BG3HOFS 0x0400101C -#define REG_DISPB_BG3VOFS 0x0400101E -#define REG_DISPB_BG2PA 0x04001020 -#define REG_DISPB_BG2PB 0x04001022 -#define REG_DISPB_BG2PC 0x04001024 -#define REG_DISPB_BG2PD 0x04001026 -#define REG_DISPB_BG2XL 0x04001028 -#define REG_DISPB_BG2XH 0x0400102A -#define REG_DISPB_BG2YL 0x0400102C -#define REG_DISPB_BG2YH 0x0400102E -#define REG_DISPB_BG3PA 0x04001030 -#define REG_DISPB_BG3PB 0x04001032 -#define REG_DISPB_BG3PC 0x04001034 -#define REG_DISPB_BG3PD 0x04001036 -#define REG_DISPB_BG3XL 0x04001038 -#define REG_DISPB_BG3XH 0x0400103A -#define REG_DISPB_BG3YL 0x0400103C -#define REG_DISPB_BG3YH 0x0400103E -#define REG_DISPB_WIN0H 0x04001040 -#define REG_DISPB_WIN1H 0x04001042 -#define REG_DISPB_WIN0V 0x04001044 -#define REG_DISPB_WIN1V 0x04001046 -#define REG_DISPB_WININ 0x04001048 -#define REG_DISPB_WINOUT 0x0400104A -#define REG_DISPB_MOSAIC 0x0400104C -#define REG_DISPB_BLDCNT 0x04001050 -#define REG_DISPB_BLDALPHA 0x04001052 -#define REG_DISPB_BLDY 0x04001054 -#define REG_DISPB_MASTERBRIGHT 0x0400106C - -// Receive ports -#define REG_IPCFIFORECV 0x04100000 -#define REG_GCDATAIN 0x04100010 - - - - - -#define REG_DISPB 0x00001000 -// core A and B specific -#define REG_DISPx_DISPCNT 0x04000000 -#define REG_DISPx_VCOUNT 0x04000006 -#define REG_DISPx_BG0CNT 0x04000008 -#define REG_DISPx_BG1CNT 0x0400000A -#define REG_DISPx_BG2CNT 0x0400000C -#define REG_DISPx_BG3CNT 0x0400000E -#define REG_DISPx_BG0HOFS 0x04000010 -#define REG_DISPx_BG0VOFS 0x04000012 -#define REG_DISPx_BG1HOFS 0x04000014 -#define REG_DISPx_BG1VOFS 0x04000016 -#define REG_DISPx_BG2HOFS 0x04000018 -#define REG_DISPx_BG2VOFS 0x0400001A -#define REG_DISPx_BG3HOFS 0x0400001C -#define REG_DISPx_BG3VOFS 0x0400001E -#define REG_DISPx_BG2PA 0x04000020 -#define REG_DISPx_BG2PB 0x04000022 -#define REG_DISPx_BG2PC 0x04000024 -#define REG_DISPx_BG2PD 0x04000026 -#define REG_DISPx_BG2XL 0x04000028 -#define REG_DISPx_BG2XH 0x0400002A -#define REG_DISPx_BG2YL 0x0400002C -#define REG_DISPx_BG2YH 0x0400002E -#define REG_DISPx_BG3PA 0x04000030 -#define REG_DISPx_BG3PB 0x04000032 -#define REG_DISPx_BG3PC 0x04000034 -#define REG_DISPx_BG3PD 0x04000036 -#define REG_DISPx_BG3XL 0x04000038 -#define REG_DISPx_BG3XH 0x0400003A -#define REG_DISPx_BG3YL 0x0400003C -#define REG_DISPx_BG3YH 0x0400003E -#define REG_DISPx_WIN0H 0x04000040 -#define REG_DISPx_WIN1H 0x04000042 -#define REG_DISPx_WIN0V 0x04000044 -#define REG_DISPx_WIN1V 0x04000046 -#define REG_DISPx_WININ 0x04000048 -#define REG_DISPx_WINOUT 0x0400004A -#define REG_DISPx_MOSAIC 0x0400004C -#define REG_DISPx_BLDCNT 0x04000050 -#define REG_DISPx_BLDALPHA 0x04000052 -#define REG_DISPx_BLDY 0x04000054 -#define REG_DISPx_MASTERBRIGHT 0x0400006C -// core A specific -#define REG_DISPA_DISPSTAT 0x04000004 -#define REG_DISPA_DISP3DCNT 0x04000060 -#define REG_DISPA_DISPCAPCNT 0x04000064 -#define REG_DISPA_DISPMMEMFIFO 0x04000068 - - -#define eng_3D_RDLINES_COUNT 0x04000320 -#define eng_3D_EDGE_COLOR 0x04000330 -#define eng_3D_ALPHA_TEST_REF 0x04000340 -#define eng_3D_CLEAR_COLOR 0x04000350 -#define eng_3D_CLEAR_DEPTH 0x04000354 -#define eng_3D_CLRIMAGE_OFFSET 0x04000356 -#define eng_3D_FOG_COLOR 0x04000358 -#define eng_3D_FOG_OFFSET 0x0400035C -#define eng_3D_FOG_TABLE 0x04000360 -#define eng_3D_TOON_TABLE 0x04000380 -#define eng_3D_GXFIFO 0x04000400 - -// 3d commands -#define cmd_3D_MTX_MODE 0x04000440 -#define cmd_3D_MTX_PUSH 0x04000444 -#define cmd_3D_MTX_POP 0x04000448 -#define cmd_3D_MTX_STORE 0x0400044C -#define cmd_3D_MTX_RESTORE 0x04000450 -#define cmd_3D_MTX_IDENTITY 0x04000454 -#define cmd_3D_MTX_LOAD_4x4 0x04000458 -#define cmd_3D_MTX_LOAD_4x3 0x0400045C -#define cmd_3D_MTX_MULT_4x4 0x04000460 -#define cmd_3D_MTX_MULT_4x3 0x04000464 -#define cmd_3D_MTX_MULT_3x3 0x04000468 -#define cmd_3D_MTX_SCALE 0x0400046C -#define cmd_3D_MTX_TRANS 0x04000470 -#define cmd_3D_COLOR 0x04000480 -#define cmd_3D_NORMA 0x04000484 -#define cmd_3D_TEXCOORD 0x04000488 -#define cmd_3D_VTX_16 0x0400048C -#define cmd_3D_VTX_10 0x04000490 -#define cmd_3D_VTX_XY 0x04000494 -#define cmd_3D_VTX_XZ 0x04000498 -#define cmd_3D_VTX_YZ 0x0400049C -#define cmd_3D_VTX_DIFF 0x040004A0 -#define cmd_3D_POLYGON_ATTR 0x040004A4 -#define cmd_3D_TEXIMAGE_PARAM 0x040004A8 -#define cmd_3D_PLTT_BASE 0x040004AC -#define cmd_3D_DIF_AMB 0x040004C0 -#define cmd_3D_SPE_EMI 0x040004C4 -#define cmd_3D_LIGHT_VECTOR 0x040004C8 -#define cmd_3D_LIGHT_COLOR 0x040004CC -#define cmd_3D_SHININESS 0x040004D0 -#define cmd_3D_BEGIN_VTXS 0x04000500 -#define cmd_3D_END_VTXS 0x04000504 -#define cmd_3D_SWAP_BUFFERS 0x04000540 -#define cmd_3D_VIEWPORT 0x04000580 -#define cmd_3D_BOX_TEST 0x040005C0 -#define cmd_3D_POS_TEST 0x040005C4 -#define cmd_3D_VEC_TEST 0x040005C8 - -#define eng_3D_GXSTAT 0x04000600 -#define eng_3D_RAM_COUNT 0x04000604 -#define eng_3D_DISP_1DOT_DEPTH 0x04000610 -#define eng_3D_POS_RESULT 0x04000620 -#define eng_3D_VEC_RESULT 0x04000630 -#define eng_3D_CLIPMTX_RESULT 0x04000640 -#define eng_3D_VECMTX_RESULT 0x04000680 - - -#endif +/* Copyright (C) 2006 Theo Berkau + + Ideas borrowed from Stephane Dallongeville's SCSP core + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#ifndef REGISTERS_H +#define REGISTERS_H + +#define REG_REGION_MASK 0x0FFFEF80 +#define REG_BASE_DISPx 0x04000000 +#define REG_BASE_DISPA 0x04000000 +#define REG_BASE_DISPB 0x04001000 +#define REG_BASE_DMA 0x04000080 +#define REG_BASE_SIORTCTIMERS 0x04000100 +#define REG_BASE_ROMIPC 0x04000180 +#define REG_BASE_MEMIRQ 0x04000200 +#define REG_BASE_MATH 0x04000280 +#define REG_BASE_OTHER 0x04000300 +#define REG_BASE_RCVPORTS 0x04100000 + +// Display Engine A +#define REG_DISPA_DISPCNT 0x04000000 +#define REG_DISPA_VCOUNT 0x04000006 +#define REG_DISPA_BG0CNT 0x04000008 +#define REG_DISPA_BG1CNT 0x0400000A +#define REG_DISPA_BG2CNT 0x0400000C +#define REG_DISPA_BG3CNT 0x0400000E +#define REG_DISPA_BG0HOFS 0x04000010 +#define REG_DISPA_BG0VOFS 0x04000012 +#define REG_DISPA_BG1HOFS 0x04000014 +#define REG_DISPA_BG1VOFS 0x04000016 +#define REG_DISPA_BG2HOFS 0x04000018 +#define REG_DISPA_BG2VOFS 0x0400001A +#define REG_DISPA_BG3HOFS 0x0400001C +#define REG_DISPA_BG3VOFS 0x0400001E +#define REG_DISPA_BG2PA 0x04000020 +#define REG_DISPA_BG2PB 0x04000022 +#define REG_DISPA_BG2PC 0x04000024 +#define REG_DISPA_BG2PD 0x04000026 +#define REG_DISPA_BG2XL 0x04000028 +#define REG_DISPA_BG2XH 0x0400002A +#define REG_DISPA_BG2YL 0x0400002C +#define REG_DISPA_BG2YH 0x0400002E +#define REG_DISPA_BG3PA 0x04000030 +#define REG_DISPA_BG3PB 0x04000032 +#define REG_DISPA_BG3PC 0x04000034 +#define REG_DISPA_BG3PD 0x04000036 +#define REG_DISPA_BG3XL 0x04000038 +#define REG_DISPA_BG3XH 0x0400003A +#define REG_DISPA_BG3YL 0x0400003C +#define REG_DISPA_BG3YH 0x0400003E +#define REG_DISPA_WIN0H 0x04000040 +#define REG_DISPA_WIN1H 0x04000042 +#define REG_DISPA_WIN0V 0x04000044 +#define REG_DISPA_WIN1V 0x04000046 +#define REG_DISPA_WININ 0x04000048 +#define REG_DISPA_WINOUT 0x0400004A +#define REG_DISPA_MOSAIC 0x0400004C +#define REG_DISPA_BLDCNT 0x04000050 +#define REG_DISPA_BLDALPHA 0x04000052 +#define REG_DISPA_BLDY 0x04000054 +#define REG_DISPA_MASTERBRIGHT 0x0400006C + +// DMA +#define REG_DMA0SAD 0x040000B0 +#define REG_DMA0DAD 0x040000B4 +#define REG_DMA0CNTL 0x040000B8 +#define REG_DMA0CNTH 0x040000BA +#define REG_DMA1SAD 0x040000BC +#define REG_DMA1DAD 0x040000C0 +#define REG_DMA1CNTL 0x040000C4 +#define REG_DMA1CNTH 0x040000C6 +#define REG_DMA2SAD 0x040000C8 +#define REG_DMA2DAD 0x040000CC +#define REG_DMA2CNTL 0x040000D0 +#define REG_DMA2CNTH 0x040000D2 +#define REG_DMA3SAD 0x040000D4 +#define REG_DMA3DAD 0x040000D8 +#define REG_DMA3CNTL 0x040000DC +#define REG_DMA3CNTH 0x040000DE +#define REG_DMA0FILL 0x040000E0 +#define REG_DMA1FILL 0x040000E4 +#define REG_DMA2FILL 0x040000E8 +#define REG_DMA3FILL 0x040000EC + +// Timers +#define REG_TM0CNTL 0x04000100 +#define REG_TM0CNTH 0x04000102 +#define REG_TM1CNTL 0x04000104 +#define REG_TM1CNTH 0x04000106 +#define REG_TM2CNTL 0x04000108 +#define REG_TM2CNTH 0x0400010A +#define REG_TM3CNTL 0x0400010C +#define REG_TM3CNTH 0x0400010E + +// SIO/Keypad Input/RTC +#define REG_SIODATA32 0x04000120 +#define REG_SIOCNT 0x04000128 +#define REG_KEYINPUT 0x04000130 +#define REG_KEYCNT 0x04000132 +#define REG_RCNT 0x04000134 +#define REG_EXTKEYIN 0x04000136 +#define REG_RTC 0x04000138 + +// IPC +#define REG_IPCSYNC 0x04000180 +#define REG_IPCFIFOCNT 0x04000184 +#define REG_IPCFIFOSEND 0x04000188 + +// ROM +#define REG_AUXSPICNT 0x040001A0 +#define REG_AUXSPIDATA 0x040001A2 +#define REG_GCROMCTRL 0x040001A4 +#define REG_GCCMDOUT 0x040001A8 +#define REG_ENCSEED0L 0x040001B0 +#define REG_ENCSEED1L 0x040001B4 +#define REG_ENCSEED0H 0x040001B8 +#define REG_ENCSEED1H 0x040001BC +#define REG_SPICNT 0x040001C0 +#define REG_SPIDATA 0x040001C2 + +// Memory/IRQ +#define REG_EXMEMCNT 0x04000204 +#define REG_WIFIWAITCNT 0x04000206 +#define REG_IME 0x04000208 +#define REG_IE 0x04000210 +#define REG_IF 0x04000214 +#define REG_VRAMCNTA 0x04000240 +#define REG_VRAMSTAT 0x04000240 +#define REG_VRAMCNTB 0x04000241 +#define REG_WRAMSTAT 0x04000241 +#define REG_VRAMCNTC 0x04000242 +#define REG_VRAMCNTD 0x04000243 +#define REG_VRAMCNTE 0x04000244 +#define REG_VRAMCNTF 0x04000245 +#define REG_VRAMCNTG 0x04000246 +#define REG_WRAMCNT 0x04000247 +#define REG_VRAMCNTH 0x04000248 +#define REG_VRAMCNTI 0x04000249 + +// Math +#define REG_DIVCNT 0x04000280 +#define REG_DIVNUMER 0x04000290 +#define REG_DIVDENOM 0x04000298 +#define REG_DIVRESULT 0x040002A0 +#define REG_DIVREMRESULT 0x040002A8 +#define REG_SQRTCNT 0x040002B0 +#define REG_SQRTRESULT 0x040002B4 +#define REG_SQRTPARAM 0x040002B8 + +// Other +#define REG_POSTFLG 0x04000300 +#define REG_HALTCNT 0x04000301 +#define REG_POWCNT1 0x04000304 +#define REG_POWCNT2 0x04000304 +#define REG_BIOSPROT 0x04000308 + +#define REG_DISPB_DISPCNT 0x04001000 +#define REG_DISPB_BG0CNT 0x04001008 +#define REG_DISPB_BG1CNT 0x0400100A +#define REG_DISPB_BG2CNT 0x0400100C +#define REG_DISPB_BG3CNT 0x0400100E +#define REG_DISPB_BG0HOFS 0x04001010 +#define REG_DISPB_BG0VOFS 0x04001012 +#define REG_DISPB_BG1HOFS 0x04001014 +#define REG_DISPB_BG1VOFS 0x04001016 +#define REG_DISPB_BG2HOFS 0x04001018 +#define REG_DISPB_BG2VOFS 0x0400101A +#define REG_DISPB_BG3HOFS 0x0400101C +#define REG_DISPB_BG3VOFS 0x0400101E +#define REG_DISPB_BG2PA 0x04001020 +#define REG_DISPB_BG2PB 0x04001022 +#define REG_DISPB_BG2PC 0x04001024 +#define REG_DISPB_BG2PD 0x04001026 +#define REG_DISPB_BG2XL 0x04001028 +#define REG_DISPB_BG2XH 0x0400102A +#define REG_DISPB_BG2YL 0x0400102C +#define REG_DISPB_BG2YH 0x0400102E +#define REG_DISPB_BG3PA 0x04001030 +#define REG_DISPB_BG3PB 0x04001032 +#define REG_DISPB_BG3PC 0x04001034 +#define REG_DISPB_BG3PD 0x04001036 +#define REG_DISPB_BG3XL 0x04001038 +#define REG_DISPB_BG3XH 0x0400103A +#define REG_DISPB_BG3YL 0x0400103C +#define REG_DISPB_BG3YH 0x0400103E +#define REG_DISPB_WIN0H 0x04001040 +#define REG_DISPB_WIN1H 0x04001042 +#define REG_DISPB_WIN0V 0x04001044 +#define REG_DISPB_WIN1V 0x04001046 +#define REG_DISPB_WININ 0x04001048 +#define REG_DISPB_WINOUT 0x0400104A +#define REG_DISPB_MOSAIC 0x0400104C +#define REG_DISPB_BLDCNT 0x04001050 +#define REG_DISPB_BLDALPHA 0x04001052 +#define REG_DISPB_BLDY 0x04001054 +#define REG_DISPB_MASTERBRIGHT 0x0400106C + +// Receive ports +#define REG_IPCFIFORECV 0x04100000 +#define REG_GCDATAIN 0x04100010 + + + + + +#define REG_DISPB 0x00001000 +// core A and B specific +#define REG_DISPx_DISPCNT 0x04000000 +#define REG_DISPx_VCOUNT 0x04000006 +#define REG_DISPx_BG0CNT 0x04000008 +#define REG_DISPx_BG1CNT 0x0400000A +#define REG_DISPx_BG2CNT 0x0400000C +#define REG_DISPx_BG3CNT 0x0400000E +#define REG_DISPx_BG0HOFS 0x04000010 +#define REG_DISPx_BG0VOFS 0x04000012 +#define REG_DISPx_BG1HOFS 0x04000014 +#define REG_DISPx_BG1VOFS 0x04000016 +#define REG_DISPx_BG2HOFS 0x04000018 +#define REG_DISPx_BG2VOFS 0x0400001A +#define REG_DISPx_BG3HOFS 0x0400001C +#define REG_DISPx_BG3VOFS 0x0400001E +#define REG_DISPx_BG2PA 0x04000020 +#define REG_DISPx_BG2PB 0x04000022 +#define REG_DISPx_BG2PC 0x04000024 +#define REG_DISPx_BG2PD 0x04000026 +#define REG_DISPx_BG2XL 0x04000028 +#define REG_DISPx_BG2XH 0x0400002A +#define REG_DISPx_BG2YL 0x0400002C +#define REG_DISPx_BG2YH 0x0400002E +#define REG_DISPx_BG3PA 0x04000030 +#define REG_DISPx_BG3PB 0x04000032 +#define REG_DISPx_BG3PC 0x04000034 +#define REG_DISPx_BG3PD 0x04000036 +#define REG_DISPx_BG3XL 0x04000038 +#define REG_DISPx_BG3XH 0x0400003A +#define REG_DISPx_BG3YL 0x0400003C +#define REG_DISPx_BG3YH 0x0400003E +#define REG_DISPx_WIN0H 0x04000040 +#define REG_DISPx_WIN1H 0x04000042 +#define REG_DISPx_WIN0V 0x04000044 +#define REG_DISPx_WIN1V 0x04000046 +#define REG_DISPx_WININ 0x04000048 +#define REG_DISPx_WINOUT 0x0400004A +#define REG_DISPx_MOSAIC 0x0400004C +#define REG_DISPx_BLDCNT 0x04000050 +#define REG_DISPx_BLDALPHA 0x04000052 +#define REG_DISPx_BLDY 0x04000054 +#define REG_DISPx_MASTERBRIGHT 0x0400006C +// core A specific +#define REG_DISPA_DISPSTAT 0x04000004 +#define REG_DISPA_DISP3DCNT 0x04000060 +#define REG_DISPA_DISPCAPCNT 0x04000064 +#define REG_DISPA_DISPMMEMFIFO 0x04000068 + + +#define eng_3D_RDLINES_COUNT 0x04000320 +#define eng_3D_EDGE_COLOR 0x04000330 +#define eng_3D_ALPHA_TEST_REF 0x04000340 +#define eng_3D_CLEAR_COLOR 0x04000350 +#define eng_3D_CLEAR_DEPTH 0x04000354 +#define eng_3D_CLRIMAGE_OFFSET 0x04000356 +#define eng_3D_FOG_COLOR 0x04000358 +#define eng_3D_FOG_OFFSET 0x0400035C +#define eng_3D_FOG_TABLE 0x04000360 +#define eng_3D_TOON_TABLE 0x04000380 +#define eng_3D_GXFIFO 0x04000400 + +// 3d commands +#define cmd_3D_MTX_MODE 0x04000440 +#define cmd_3D_MTX_PUSH 0x04000444 +#define cmd_3D_MTX_POP 0x04000448 +#define cmd_3D_MTX_STORE 0x0400044C +#define cmd_3D_MTX_RESTORE 0x04000450 +#define cmd_3D_MTX_IDENTITY 0x04000454 +#define cmd_3D_MTX_LOAD_4x4 0x04000458 +#define cmd_3D_MTX_LOAD_4x3 0x0400045C +#define cmd_3D_MTX_MULT_4x4 0x04000460 +#define cmd_3D_MTX_MULT_4x3 0x04000464 +#define cmd_3D_MTX_MULT_3x3 0x04000468 +#define cmd_3D_MTX_SCALE 0x0400046C +#define cmd_3D_MTX_TRANS 0x04000470 +#define cmd_3D_COLOR 0x04000480 +#define cmd_3D_NORMA 0x04000484 +#define cmd_3D_TEXCOORD 0x04000488 +#define cmd_3D_VTX_16 0x0400048C +#define cmd_3D_VTX_10 0x04000490 +#define cmd_3D_VTX_XY 0x04000494 +#define cmd_3D_VTX_XZ 0x04000498 +#define cmd_3D_VTX_YZ 0x0400049C +#define cmd_3D_VTX_DIFF 0x040004A0 +#define cmd_3D_POLYGON_ATTR 0x040004A4 +#define cmd_3D_TEXIMAGE_PARAM 0x040004A8 +#define cmd_3D_PLTT_BASE 0x040004AC +#define cmd_3D_DIF_AMB 0x040004C0 +#define cmd_3D_SPE_EMI 0x040004C4 +#define cmd_3D_LIGHT_VECTOR 0x040004C8 +#define cmd_3D_LIGHT_COLOR 0x040004CC +#define cmd_3D_SHININESS 0x040004D0 +#define cmd_3D_BEGIN_VTXS 0x04000500 +#define cmd_3D_END_VTXS 0x04000504 +#define cmd_3D_SWAP_BUFFERS 0x04000540 +#define cmd_3D_VIEWPORT 0x04000580 +#define cmd_3D_BOX_TEST 0x040005C0 +#define cmd_3D_POS_TEST 0x040005C4 +#define cmd_3D_VEC_TEST 0x040005C8 + +#define eng_3D_GXSTAT 0x04000600 +#define eng_3D_RAM_COUNT 0x04000604 +#define eng_3D_DISP_1DOT_DEPTH 0x04000610 +#define eng_3D_POS_RESULT 0x04000620 +#define eng_3D_VEC_RESULT 0x04000630 +#define eng_3D_CLIPMTX_RESULT 0x04000640 +#define eng_3D_VECMTX_RESULT 0x04000680 + + +#endif diff --git a/desmume/src/render3D.cpp b/src/render3D.cpp similarity index 96% rename from desmume/src/render3D.cpp rename to src/render3D.cpp index 03650a2f0..bf853fe8f 100644 --- a/desmume/src/render3D.cpp +++ b/src/render3D.cpp @@ -1,54 +1,54 @@ -/* - Copyright (C) 2006-2007 shash - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#include "render3D.h" - -int cur3DCore = GPU3D_NULL; - -static void NDS_nullFunc1 (void){} -static char NDS_nullFunc2 (void){ return 1; } - -GPU3DInterface gpu3DNull = { - "None", - NDS_nullFunc2, //NDS_3D_Init - NDS_nullFunc1, //NDS_3D_Reset - NDS_nullFunc1, //NDS_3D_Close - NDS_nullFunc1, //NDS_3D_Render - NDS_nullFunc1, //NDS_3D_VramReconfigureSignal -}; - -GPU3DInterface *gpu3D = &gpu3DNull; - -void NDS_3D_SetDriver (int core3DIndex) -{ - cur3DCore = core3DIndex; - gpu3D = core3DList[cur3DCore]; -} - -void NDS_3D_ChangeCore(int newCore) -{ - gpu3D->NDS_3D_Close(); - NDS_3D_SetDriver(newCore); - if(gpu3D->NDS_3D_Init() == 0) - { - NDS_3D_SetDriver(GPU3D_NULL); - gpu3D->NDS_3D_Init(); - } -} +/* + Copyright (C) 2006-2007 shash + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#include "render3D.h" + +int cur3DCore = GPU3D_NULL; + +static void NDS_nullFunc1 (void){} +static char NDS_nullFunc2 (void){ return 1; } + +GPU3DInterface gpu3DNull = { + "None", + NDS_nullFunc2, //NDS_3D_Init + NDS_nullFunc1, //NDS_3D_Reset + NDS_nullFunc1, //NDS_3D_Close + NDS_nullFunc1, //NDS_3D_Render + NDS_nullFunc1, //NDS_3D_VramReconfigureSignal +}; + +GPU3DInterface *gpu3D = &gpu3DNull; + +void NDS_3D_SetDriver (int core3DIndex) +{ + cur3DCore = core3DIndex; + gpu3D = core3DList[cur3DCore]; +} + +void NDS_3D_ChangeCore(int newCore) +{ + gpu3D->NDS_3D_Close(); + NDS_3D_SetDriver(newCore); + if(gpu3D->NDS_3D_Init() == 0) + { + NDS_3D_SetDriver(GPU3D_NULL); + gpu3D->NDS_3D_Init(); + } +} diff --git a/desmume/src/render3D.h b/src/render3D.h similarity index 96% rename from desmume/src/render3D.h rename to src/render3D.h index 877afa4d8..428b806de 100644 --- a/desmume/src/render3D.h +++ b/src/render3D.h @@ -1,67 +1,67 @@ -/* - Copyright (C) 2006-2007 shash - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#ifndef RENDER3D_H -#define RENDER3D_H - -#include "types.h" - -//not using this right now -#define CALL_CONVENTION - -typedef struct Render3DInterface -{ - // The name of the plugin, this name will appear in the plugins list - const char * name; - - //called once when the plugin starts up - char (CALL_CONVENTION* NDS_3D_Init) (void); - - //called when the emulator resets (is this necessary?) - void (CALL_CONVENTION* NDS_3D_Reset) (void); - - //called when the plugin shuts down - void (CALL_CONVENTION* NDS_3D_Close) (void); - - //called when the renderer should do its job and render the current display lists - void (CALL_CONVENTION* NDS_3D_Render) (void); - - //called when the emulator reconfigures its vram. you may need to invalidate your texture cache. - void (CALL_CONVENTION* NDS_3D_VramReconfigureSignal) (); - -} GPU3DInterface; - -extern int cur3DCore; - -// gpu 3D core list, per port -extern GPU3DInterface *core3DList[]; - -// Default null plugin -#define GPU3D_NULL 0 -extern GPU3DInterface gpu3DNull; - -// Extern pointer -extern GPU3DInterface *gpu3D; - -void NDS_3D_SetDriver (int core3DIndex); -void NDS_3D_ChangeCore(int newCore); - -#endif - +/* + Copyright (C) 2006-2007 shash + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#ifndef RENDER3D_H +#define RENDER3D_H + +#include "types.h" + +//not using this right now +#define CALL_CONVENTION + +typedef struct Render3DInterface +{ + // The name of the plugin, this name will appear in the plugins list + const char * name; + + //called once when the plugin starts up + char (CALL_CONVENTION* NDS_3D_Init) (void); + + //called when the emulator resets (is this necessary?) + void (CALL_CONVENTION* NDS_3D_Reset) (void); + + //called when the plugin shuts down + void (CALL_CONVENTION* NDS_3D_Close) (void); + + //called when the renderer should do its job and render the current display lists + void (CALL_CONVENTION* NDS_3D_Render) (void); + + //called when the emulator reconfigures its vram. you may need to invalidate your texture cache. + void (CALL_CONVENTION* NDS_3D_VramReconfigureSignal) (); + +} GPU3DInterface; + +extern int cur3DCore; + +// gpu 3D core list, per port +extern GPU3DInterface *core3DList[]; + +// Default null plugin +#define GPU3D_NULL 0 +extern GPU3DInterface gpu3DNull; + +// Extern pointer +extern GPU3DInterface *gpu3D; + +void NDS_3D_SetDriver (int core3DIndex); +void NDS_3D_ChangeCore(int newCore); + +#endif + diff --git a/desmume/src/rtc.cpp b/src/rtc.cpp similarity index 95% rename from desmume/src/rtc.cpp rename to src/rtc.cpp index 43c7f977c..e601ff609 100644 --- a/desmume/src/rtc.cpp +++ b/src/rtc.cpp @@ -1,376 +1,376 @@ -/* Copyright (C) 2006 yopyop - yopyop156@ifrance.com - yopyop156.ifrance.com - - Copyright 2008 CrazyMax - Copyright 2008-2009 DeSmuME team - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -*/ - -// TODO: interrupt handler - -#include "rtc.h" -#include "common.h" -#include "debug.h" -#include "armcpu.h" -#include -#include -#ifdef WIN32 -#include "windows/main.h" -#endif -#include "movie.h" - -typedef struct -{ - // RTC registers - u8 regStatus1; - u8 regStatus2; - u8 regAdjustment; - u8 regFree; - - // BUS - u8 _prevSCK; - u8 _prevCS; - u8 _prevSIO; - u8 _SCK; - u8 _CS; - u8 _SIO; - u8 _DD; - u16 _REG; - - // command & data - u8 cmd; - u8 cmdStat; - u8 bitsCount; - u8 data[8]; -} _RTC; - -_RTC rtc; - -u8 cmdBitsSize[8] = {8, 8, 56, 24, 0, 24, 8, 8}; - -#define toBCD(x) ((x / 10) << 4) | (x % 10); - -struct movietime { - - int sec; - int minute; - int hour; - int monthday; - int month; - int year; - int weekday; -}; - -struct movietime movie; - -bool moviemode=false; - -void InitMovieTime(void) -{ - movie.year=9; - movie.month=1; - movie.monthday=1; - movie.weekday=4; -} - -#ifdef WIN32 -static void MovieTime(void) { - - //now, you might think it is silly to go through all these conniptions - //when we could just assume that there are 60fps and base the seconds on frameCounter/60 - //but, we were imagining that one day we might need more precision - - const u32 arm9rate_unitsperframe = 560190<<1; - const u32 arm9rate_unitspersecond = (u32)(arm9rate_unitsperframe * 59.8261); - const u64 noon = (u64)arm9rate_unitspersecond * 60 * 60 * 12; - - u64 frameCycles = (u64)arm9rate_unitsperframe * currFrameCounter; - u64 totalcycles = frameCycles + noon; - u32 totalseconds=totalcycles/arm9rate_unitspersecond; - - movie.sec=totalseconds % 60; - movie.minute=totalseconds/60; - movie.hour=movie.minute/60; - - //convert to sane numbers - movie.minute=movie.minute % 60; - movie.hour=movie.hour % 24; -} -#else -static void MovieTime(void) -{ -} -#endif - -static void rtcRecv() -{ - //INFO("RTC Read command 0x%02X\n", (rtc.cmd >> 1)); - memset(rtc.data, 0, sizeof(rtc.data)); - switch (rtc.cmd >> 1) - { - case 0: // status register 1 - //INFO("RTC: read regstatus1 (0x%02X)\n", rtc.regStatus1); - rtc.regStatus1 &= 0x0F; - rtc.data[0] = rtc.regStatus1; - //rtc.regStatus1 &= 0x7F; - break; - case 1: // status register 2 - //INFO("RTC: read regstatus2 (0x%02X)\n", rtc.regStatus1); - rtc.data[0] = rtc.regStatus2; - break; - case 2: // date & time - { - //INFO("RTC: read date & time\n"); - time_t tm; - time(&tm); - struct tm *tm_local= localtime(&tm); - tm_local->tm_year %= 100; - tm_local->tm_mon++; - - if(movieMode != MOVIEMODE_INACTIVE) { - - MovieTime(); - - rtc.data[0]=toBCD(movie.year); - rtc.data[1]=toBCD(movie.month); - rtc.data[2]=toBCD(movie.monthday); - rtc.data[3]=(movie.weekday + 6) & 7; - if (!(rtc.regStatus1 & 0x02)) movie.hour %= 12; - rtc.data[4] = ((movie.hour < 12) ? 0x00 : 0x40) | toBCD(movie.hour); - rtc.data[5]=toBCD(movie.minute); - rtc.data[6]=toBCD(movie.sec); - break; - } - else { - - rtc.data[0] = toBCD(tm_local->tm_year); - rtc.data[1] = toBCD(tm_local->tm_mon); - rtc.data[2] = toBCD(tm_local->tm_mday); - rtc.data[3] = (tm_local->tm_wday + 6) & 7; - if (!(rtc.regStatus1 & 0x02)) tm_local->tm_hour %= 12; - rtc.data[4] = ((tm_local->tm_hour < 12) ? 0x00 : 0x40) | toBCD(tm_local->tm_hour); - rtc.data[5] = toBCD(tm_local->tm_min); - rtc.data[6] = toBCD(tm_local->tm_sec); - break; - } - } - case 3: // time - { - //INFO("RTC: read time\n"); - time_t tm; - time(&tm); - struct tm *tm_local= localtime(&tm); - - if(movieMode != MOVIEMODE_INACTIVE) { - - MovieTime(); - - if (!(rtc.regStatus1 & 0x02)) movie.hour %= 12; - rtc.data[0] = ((movie.hour < 12) ? 0x00 : 0x40) | toBCD(movie.hour); - rtc.data[1] = toBCD(movie.minute); - rtc.data[2] = toBCD(movie.sec); - } - else { - - if (!(rtc.regStatus1 & 0x02)) tm_local->tm_hour %= 12; - rtc.data[0] = ((tm_local->tm_hour < 12) ? 0x00 : 0x40) | toBCD(tm_local->tm_hour); - rtc.data[1] = toBCD(tm_local->tm_min); - rtc.data[2] = toBCD(tm_local->tm_sec); - break; - } - } - case 4: // freq/alarm 1 - /*if (cmdBitsSize[0x04] == 8) - INFO("RTC: read INT1 freq\n"); - else - INFO("RTC: read INT1 alarm1\n");*/ - //NDS_makeARM7Int(7); - break; - case 5: // alarm 2 - //INFO("RTC: read alarm 2\n"); - break; - case 6: // clock adjust - //INFO("RTC: read clock adjust\n"); - rtc.data[0] = rtc.regAdjustment; - break; - case 7: // free register - //INFO("RTC: read free register\n"); - rtc.data[0] = rtc.regFree; - break; - } -} - -static void rtcSend() -{ - //INFO("RTC write 0x%02X\n", (rtc.cmd >> 1)); - switch (rtc.cmd >> 1) - { - case 0: // status register 1 - //INFO("RTC: write regstatus1 0x%02X\n", rtc.data[0]); - // rtc.regStatus1 &= 0xF1; - // rtc.regStatus1 |= (rtc.data[0] | 0x0E); - rtc.regStatus1 = rtc.data[0]; - break; - case 1: // status register 2 - //INFO("RTC: write regstatus2 0x%02X\n", rtc.data[0]); - rtc.regStatus2 = rtc.data[0]; - break; - case 2: // date & time - //INFO("RTC: write date & time : %02X %02X %02X %02X %02X %02X %02X\n", rtc.data[0], rtc.data[1], rtc.data[2], rtc.data[3], rtc.data[4], rtc.data[5], rtc.data[6]); - break; - case 3: // time - //INFO("RTC: write time : %02X %02X %02X\n", rtc.data[0], rtc.data[1], rtc.data[2]); - break; - case 4: // freq/alarm 1 - /*if (cmdBitsSize[0x04] == 8) - INFO("RTC: write INT1 freq 0x%02X\n", rtc.data[0]); - else - INFO("RTC: write INT1 alarm1 0x%02X\n", rtc.data[0]);*/ - break; - case 5: // alarm 2 - //INFO("RTC: write alarm 2\n"); - break; - case 6: // clock adjust - //INFO("RTC: write clock adjust\n"); - rtc.regAdjustment = rtc.data[0]; - break; - case 7: // free register - //INFO("RTC: write free register\n"); - rtc.regFree = rtc.data[0]; - break; - } -} - -void rtcInit() -{ - memset(&rtc, 0, sizeof(_RTC)); - rtc.regStatus1 |= 0x02; -} - -u16 rtcRead() -{ - //INFO("MMU Read RTC 0x%02X (%03i)\n", rtc._REG, rtc.bitsCount); - return (rtc._REG); -} - -void rtcWrite(u16 val) -{ - //INFO("MMU Write RTC 0x%02X (%03i)\n", val, rtc.bitsCount); - rtc._DD = (val & 0x10) >> 4; - rtc._SIO = rtc._DD?(val & 0x01):rtc._prevSIO; - rtc._SCK = (val & 0x20)?((val & 0x02) >> 1):rtc._prevSCK; - rtc._CS = (val & 0x40)?((val & 0x04) >> 2):rtc._prevCS; - - switch (rtc.cmdStat) - { - case 0: - if ( (!rtc._prevCS) && (rtc._prevSCK) && (rtc._CS) && (rtc._SCK) ) - { - rtc.cmdStat = 1; - rtc.bitsCount = 0; - rtc.cmd = 0; - } - break; - - case 1: - if (!rtc._CS) - { - rtc.cmdStat = 0; - break; - } - - if (rtc._SCK && rtc._DD) break; - if (!rtc._SCK && !rtc._DD) break; - - rtc.cmd |= (rtc._SIO << rtc.bitsCount ); - rtc.bitsCount ++; - if (rtc.bitsCount == 8) - { - //INFO("RTC command 0x%02X\n", rtc.cmd); - - // Little-endian command - if((rtc.cmd & 0x0F) == 0x06) - { - u8 tmp = rtc.cmd; - rtc.cmd = ((tmp & 0x80) >> 7) | ((tmp & 0x40) >> 5) | ((tmp & 0x20) >> 3) | ((tmp & 0x10) >> 1); - } - // Big-endian command - else - { - rtc.cmd &= 0x0F; - } - - if((rtc._prevSCK) && (!rtc._SCK)) - { - rtc.bitsCount = 0; - if ((rtc.cmd >> 1) == 0x04) - { - if ((rtc.regStatus2 & 0x0F) == 0x04) - cmdBitsSize[rtc.cmd >> 1] = 24; - else - cmdBitsSize[rtc.cmd >> 1] = 8; - } - if (rtc.cmd & 0x01) - { - rtc.cmdStat = 4; - rtcRecv(); - } - else - { - rtc.cmdStat = 3; - } - } - } - - break; - - case 3: // write: - if( (rtc._prevSCK) && (!rtc._SCK) ) - { - if(rtc._SIO) rtc.data[rtc.bitsCount >> 3] |= (1 << (rtc.bitsCount & 0x07)); - rtc.bitsCount++; - if (rtc.bitsCount == cmdBitsSize[rtc.cmd >> 1]) - { - rtcSend(); - rtc.cmdStat = 0; - } - } - break; - - case 4: // read: - if( (rtc._prevSCK) && (!rtc._SCK) ) - { - rtc._REG = val; - if(rtc.data[rtc.bitsCount >> 3] >> (rtc.bitsCount & 0x07) & 0x01) - rtc._REG |= 0x01; - else - rtc._REG &= ~0x01; - - rtc.bitsCount++; - if (rtc.bitsCount == cmdBitsSize[rtc.cmd >> 1]) - rtc.cmdStat = 0; - } - break; - - } - - rtc._prevSIO = rtc._SIO; - rtc._prevSCK = rtc._SCK; - rtc._prevCS = rtc._CS; -} +/* Copyright (C) 2006 yopyop + yopyop156@ifrance.com + yopyop156.ifrance.com + + Copyright 2008 CrazyMax + Copyright 2008-2009 DeSmuME team + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA +*/ + +// TODO: interrupt handler + +#include "rtc.h" +#include "common.h" +#include "debug.h" +#include "armcpu.h" +#include +#include +#ifdef WIN32 +#include "windows/main.h" +#endif +#include "movie.h" + +typedef struct +{ + // RTC registers + u8 regStatus1; + u8 regStatus2; + u8 regAdjustment; + u8 regFree; + + // BUS + u8 _prevSCK; + u8 _prevCS; + u8 _prevSIO; + u8 _SCK; + u8 _CS; + u8 _SIO; + u8 _DD; + u16 _REG; + + // command & data + u8 cmd; + u8 cmdStat; + u8 bitsCount; + u8 data[8]; +} _RTC; + +_RTC rtc; + +u8 cmdBitsSize[8] = {8, 8, 56, 24, 0, 24, 8, 8}; + +#define toBCD(x) ((x / 10) << 4) | (x % 10); + +struct movietime { + + int sec; + int minute; + int hour; + int monthday; + int month; + int year; + int weekday; +}; + +struct movietime movie; + +bool moviemode=false; + +void InitMovieTime(void) +{ + movie.year=9; + movie.month=1; + movie.monthday=1; + movie.weekday=4; +} + +#ifdef WIN32 +static void MovieTime(void) { + + //now, you might think it is silly to go through all these conniptions + //when we could just assume that there are 60fps and base the seconds on frameCounter/60 + //but, we were imagining that one day we might need more precision + + const u32 arm9rate_unitsperframe = 560190<<1; + const u32 arm9rate_unitspersecond = (u32)(arm9rate_unitsperframe * 59.8261); + const u64 noon = (u64)arm9rate_unitspersecond * 60 * 60 * 12; + + u64 frameCycles = (u64)arm9rate_unitsperframe * currFrameCounter; + u64 totalcycles = frameCycles + noon; + u32 totalseconds=totalcycles/arm9rate_unitspersecond; + + movie.sec=totalseconds % 60; + movie.minute=totalseconds/60; + movie.hour=movie.minute/60; + + //convert to sane numbers + movie.minute=movie.minute % 60; + movie.hour=movie.hour % 24; +} +#else +static void MovieTime(void) +{ +} +#endif + +static void rtcRecv() +{ + //INFO("RTC Read command 0x%02X\n", (rtc.cmd >> 1)); + memset(rtc.data, 0, sizeof(rtc.data)); + switch (rtc.cmd >> 1) + { + case 0: // status register 1 + //INFO("RTC: read regstatus1 (0x%02X)\n", rtc.regStatus1); + rtc.regStatus1 &= 0x0F; + rtc.data[0] = rtc.regStatus1; + //rtc.regStatus1 &= 0x7F; + break; + case 1: // status register 2 + //INFO("RTC: read regstatus2 (0x%02X)\n", rtc.regStatus1); + rtc.data[0] = rtc.regStatus2; + break; + case 2: // date & time + { + //INFO("RTC: read date & time\n"); + time_t tm; + time(&tm); + struct tm *tm_local= localtime(&tm); + tm_local->tm_year %= 100; + tm_local->tm_mon++; + + if(movieMode != MOVIEMODE_INACTIVE) { + + MovieTime(); + + rtc.data[0]=toBCD(movie.year); + rtc.data[1]=toBCD(movie.month); + rtc.data[2]=toBCD(movie.monthday); + rtc.data[3]=(movie.weekday + 6) & 7; + if (!(rtc.regStatus1 & 0x02)) movie.hour %= 12; + rtc.data[4] = ((movie.hour < 12) ? 0x00 : 0x40) | toBCD(movie.hour); + rtc.data[5]=toBCD(movie.minute); + rtc.data[6]=toBCD(movie.sec); + break; + } + else { + + rtc.data[0] = toBCD(tm_local->tm_year); + rtc.data[1] = toBCD(tm_local->tm_mon); + rtc.data[2] = toBCD(tm_local->tm_mday); + rtc.data[3] = (tm_local->tm_wday + 6) & 7; + if (!(rtc.regStatus1 & 0x02)) tm_local->tm_hour %= 12; + rtc.data[4] = ((tm_local->tm_hour < 12) ? 0x00 : 0x40) | toBCD(tm_local->tm_hour); + rtc.data[5] = toBCD(tm_local->tm_min); + rtc.data[6] = toBCD(tm_local->tm_sec); + break; + } + } + case 3: // time + { + //INFO("RTC: read time\n"); + time_t tm; + time(&tm); + struct tm *tm_local= localtime(&tm); + + if(movieMode != MOVIEMODE_INACTIVE) { + + MovieTime(); + + if (!(rtc.regStatus1 & 0x02)) movie.hour %= 12; + rtc.data[0] = ((movie.hour < 12) ? 0x00 : 0x40) | toBCD(movie.hour); + rtc.data[1] = toBCD(movie.minute); + rtc.data[2] = toBCD(movie.sec); + } + else { + + if (!(rtc.regStatus1 & 0x02)) tm_local->tm_hour %= 12; + rtc.data[0] = ((tm_local->tm_hour < 12) ? 0x00 : 0x40) | toBCD(tm_local->tm_hour); + rtc.data[1] = toBCD(tm_local->tm_min); + rtc.data[2] = toBCD(tm_local->tm_sec); + break; + } + } + case 4: // freq/alarm 1 + /*if (cmdBitsSize[0x04] == 8) + INFO("RTC: read INT1 freq\n"); + else + INFO("RTC: read INT1 alarm1\n");*/ + //NDS_makeARM7Int(7); + break; + case 5: // alarm 2 + //INFO("RTC: read alarm 2\n"); + break; + case 6: // clock adjust + //INFO("RTC: read clock adjust\n"); + rtc.data[0] = rtc.regAdjustment; + break; + case 7: // free register + //INFO("RTC: read free register\n"); + rtc.data[0] = rtc.regFree; + break; + } +} + +static void rtcSend() +{ + //INFO("RTC write 0x%02X\n", (rtc.cmd >> 1)); + switch (rtc.cmd >> 1) + { + case 0: // status register 1 + //INFO("RTC: write regstatus1 0x%02X\n", rtc.data[0]); + // rtc.regStatus1 &= 0xF1; + // rtc.regStatus1 |= (rtc.data[0] | 0x0E); + rtc.regStatus1 = rtc.data[0]; + break; + case 1: // status register 2 + //INFO("RTC: write regstatus2 0x%02X\n", rtc.data[0]); + rtc.regStatus2 = rtc.data[0]; + break; + case 2: // date & time + //INFO("RTC: write date & time : %02X %02X %02X %02X %02X %02X %02X\n", rtc.data[0], rtc.data[1], rtc.data[2], rtc.data[3], rtc.data[4], rtc.data[5], rtc.data[6]); + break; + case 3: // time + //INFO("RTC: write time : %02X %02X %02X\n", rtc.data[0], rtc.data[1], rtc.data[2]); + break; + case 4: // freq/alarm 1 + /*if (cmdBitsSize[0x04] == 8) + INFO("RTC: write INT1 freq 0x%02X\n", rtc.data[0]); + else + INFO("RTC: write INT1 alarm1 0x%02X\n", rtc.data[0]);*/ + break; + case 5: // alarm 2 + //INFO("RTC: write alarm 2\n"); + break; + case 6: // clock adjust + //INFO("RTC: write clock adjust\n"); + rtc.regAdjustment = rtc.data[0]; + break; + case 7: // free register + //INFO("RTC: write free register\n"); + rtc.regFree = rtc.data[0]; + break; + } +} + +void rtcInit() +{ + memset(&rtc, 0, sizeof(_RTC)); + rtc.regStatus1 |= 0x02; +} + +u16 rtcRead() +{ + //INFO("MMU Read RTC 0x%02X (%03i)\n", rtc._REG, rtc.bitsCount); + return (rtc._REG); +} + +void rtcWrite(u16 val) +{ + //INFO("MMU Write RTC 0x%02X (%03i)\n", val, rtc.bitsCount); + rtc._DD = (val & 0x10) >> 4; + rtc._SIO = rtc._DD?(val & 0x01):rtc._prevSIO; + rtc._SCK = (val & 0x20)?((val & 0x02) >> 1):rtc._prevSCK; + rtc._CS = (val & 0x40)?((val & 0x04) >> 2):rtc._prevCS; + + switch (rtc.cmdStat) + { + case 0: + if ( (!rtc._prevCS) && (rtc._prevSCK) && (rtc._CS) && (rtc._SCK) ) + { + rtc.cmdStat = 1; + rtc.bitsCount = 0; + rtc.cmd = 0; + } + break; + + case 1: + if (!rtc._CS) + { + rtc.cmdStat = 0; + break; + } + + if (rtc._SCK && rtc._DD) break; + if (!rtc._SCK && !rtc._DD) break; + + rtc.cmd |= (rtc._SIO << rtc.bitsCount ); + rtc.bitsCount ++; + if (rtc.bitsCount == 8) + { + //INFO("RTC command 0x%02X\n", rtc.cmd); + + // Little-endian command + if((rtc.cmd & 0x0F) == 0x06) + { + u8 tmp = rtc.cmd; + rtc.cmd = ((tmp & 0x80) >> 7) | ((tmp & 0x40) >> 5) | ((tmp & 0x20) >> 3) | ((tmp & 0x10) >> 1); + } + // Big-endian command + else + { + rtc.cmd &= 0x0F; + } + + if((rtc._prevSCK) && (!rtc._SCK)) + { + rtc.bitsCount = 0; + if ((rtc.cmd >> 1) == 0x04) + { + if ((rtc.regStatus2 & 0x0F) == 0x04) + cmdBitsSize[rtc.cmd >> 1] = 24; + else + cmdBitsSize[rtc.cmd >> 1] = 8; + } + if (rtc.cmd & 0x01) + { + rtc.cmdStat = 4; + rtcRecv(); + } + else + { + rtc.cmdStat = 3; + } + } + } + + break; + + case 3: // write: + if( (rtc._prevSCK) && (!rtc._SCK) ) + { + if(rtc._SIO) rtc.data[rtc.bitsCount >> 3] |= (1 << (rtc.bitsCount & 0x07)); + rtc.bitsCount++; + if (rtc.bitsCount == cmdBitsSize[rtc.cmd >> 1]) + { + rtcSend(); + rtc.cmdStat = 0; + } + } + break; + + case 4: // read: + if( (rtc._prevSCK) && (!rtc._SCK) ) + { + rtc._REG = val; + if(rtc.data[rtc.bitsCount >> 3] >> (rtc.bitsCount & 0x07) & 0x01) + rtc._REG |= 0x01; + else + rtc._REG &= ~0x01; + + rtc.bitsCount++; + if (rtc.bitsCount == cmdBitsSize[rtc.cmd >> 1]) + rtc.cmdStat = 0; + } + break; + + } + + rtc._prevSIO = rtc._SIO; + rtc._prevSCK = rtc._SCK; + rtc._prevCS = rtc._CS; +} diff --git a/desmume/src/rtc.h b/src/rtc.h similarity index 96% rename from desmume/src/rtc.h rename to src/rtc.h index f1b6765ae..e57653082 100644 --- a/desmume/src/rtc.h +++ b/src/rtc.h @@ -1,35 +1,35 @@ -/* Copyright (C) 2006 yopyop - yopyop156@ifrance.com - yopyop156.ifrance.com - - Copyright 2008 CrazyMax - Copyright 2008-2009 DeSmuME team - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -*/ - -#ifndef _RTC_H_ -#define _RTC_H_ -#include -#include "types.h" - -extern void rtcInit(); -extern u16 rtcRead(); -extern void rtcWrite(u16 val); - -void InitMovieTime(void); -#endif +/* Copyright (C) 2006 yopyop + yopyop156@ifrance.com + yopyop156.ifrance.com + + Copyright 2008 CrazyMax + Copyright 2008-2009 DeSmuME team + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA +*/ + +#ifndef _RTC_H_ +#define _RTC_H_ +#include +#include "types.h" + +extern void rtcInit(); +extern u16 rtcRead(); +extern void rtcWrite(u16 val); + +void InitMovieTime(void); +#endif diff --git a/desmume/src/saves.cpp b/src/saves.cpp similarity index 86% rename from desmume/src/saves.cpp rename to src/saves.cpp index 91b14a2cc..6b6a34157 100644 --- a/desmume/src/saves.cpp +++ b/src/saves.cpp @@ -22,7 +22,6 @@ #ifdef HAVE_LIBZ #include #endif -#include #include #include #include @@ -34,20 +33,15 @@ #include "render3D.h" #include "cp15.h" #include "GPU_osd.h" -#include "version.h" #include "memorystream.h" #include "readwrite.h" #include "gfx3d.h" #include "movie.h" - -#include "path.h" - #ifdef _MSC_VER #include "windows/main.h" #endif -int lastSaveState = 0; //Keeps track of last savestate used for quick save/load functions //void*v is actually a void** which will be indirected before reading //since this isnt supported right now, it is declared in here to make things compile @@ -55,7 +49,7 @@ int lastSaveState = 0; //Keeps track of last savestate used for quick save/load savestates_t savestates[NB_STATES]; -#define SAVESTATE_VERSION 12 +#define SAVESTATE_VERSION 11 static const char* magic = "DeSmuME SState\0"; //a savestate chunk loader can set this if it wants to permit a silent failure (for compatibility) @@ -164,10 +158,16 @@ SFORMAT SF_MEM[]={ }; SFORMAT SF_NDS[]={ - { "_WCY", 4, 1, &nds.wifiCycle}, - { "_TCY", 8, 8, nds.timerCycle}, + { "_9CY", 4, 1, &nds.ARM9Cycle}, + { "_7CY", 4, 1, &nds.ARM7Cycle}, + { "_CYC", 4, 1, &nds.cycles}, + { "_TCY", 4, 8, nds.timerCycle}, + { "_TOV", 4, 8, nds.timerOver}, + { "_NHB", 4, 1, &nds.nextHBlank}, { "_VCT", 4, 1, &nds.VCount}, { "_OLD", 4, 1, &nds.old}, + { "_DIF", 4, 1, &nds.diff}, + { "_LIG", 4, 1, &nds.lignerendu}, { "_TPX", 2, 1, &nds.touchX}, { "_TPY", 2, 1, &nds.touchY}, { "_TPB", 4, 1, &nds.isTouch}, @@ -197,15 +197,8 @@ SFORMAT SF_MMU[]={ { "MIE_", 4, 2, MMU.reg_IE}, { "MIF_", 4, 2, MMU.reg_IF}, - { "MGXC", 8, 1, &MMU.gfx3dCycles}, - - { "M_SX", 1, 2, &MMU.SPI_CNT}, - { "M_SC", 1, 2, &MMU.SPI_CMD}, - { "MASX", 1, 2, &MMU.AUX_SPI_CNT}, - { "MASC", 1, 2, &MMU.AUX_SPI_CMD}, - { "MDST", 4, 8, MMU.DMAStartTime}, - { "MDCY", 8, 8, MMU.DMACycle}, + { "MDCY", 4, 8, MMU.DMACycle}, { "MDCR", 4, 8, MMU.DMACrt}, { "MDMA", 4, 8, MMU.DMAing}, { "MDSR", 4, 8, DMASrc}, @@ -215,12 +208,12 @@ SFORMAT SF_MMU[]={ { "MDV2", 8, 1, &MMU.divResult}, { "MDV3", 8, 1, &MMU.divMod}, { "MDV4", 4, 1, &MMU.divCnt}, - { "MDV5", 8, 1, &MMU.divCycles}, + { "MDV5", 4, 1, &MMU.divCycles}, { "MSQ1", 4, 1, &MMU.sqrtRunning}, { "MSQ2", 4, 1, &MMU.sqrtResult}, { "MSQ3", 4, 1, &MMU.sqrtCnt}, - { "MSQ4", 8, 1, &MMU.sqrtCycles}, + { "MSQ4", 4, 1, &MMU.sqrtCycles}, //begin memory chips //we are skipping the firmware, because we really don't want to save the firmware to the savestate @@ -263,10 +256,11 @@ SFORMAT SF_MOVIE[]={ static void mmu_savestate(std::ostream* os) { //version - write32le(2,os); - - //newer savefile system: - MMU_new.backupDevice.save_state(os); + write32le(1,os); + + write32le(MMU.bupmem.type,os); + write32le(MMU.bupmem.size,os); + os->write((char*)MMU.bupmem.data,MMU.bupmem.size); } static bool mmu_loadstate(std::istream* is, int size) @@ -275,46 +269,30 @@ static bool mmu_loadstate(std::istream* is, int size) int version; if(read32le(&version,is) != 1) return false; - if(version == 0 || version == 1) + + u32 bupmem_size; + + if(version == 0) { - u32 bupmem_size; - u32 addr_size; - - if(version == 0) - { - //version 0 was buggy and didnt save the type. - //it would silently fail if there was a size mismatch - SAV_silent_fail_flag = true; - if(read32le(&bupmem_size,is) != 1) return false; - //if(bupmem_size != MMU.bupmem.size) return false; //mismatch between current initialized and saved size - addr_size = BackupDevice::addr_size_for_old_save_size(bupmem_size); - } - else if(version == 1) - { - //version 1 reinitializes the save system with the type that was saved - int bupmem_type; - if(read32le(&bupmem_type,is) != 1) return false; - if(read32le(&bupmem_size,is) != 1) return false; - addr_size = BackupDevice::addr_size_for_old_save_type(bupmem_type); - if(addr_size == 0xFFFFFFFF) - addr_size = BackupDevice::addr_size_for_old_save_size(bupmem_size); - } - - if(addr_size == 0xFFFFFFFF) - return false; - - u8* temp = new u8[bupmem_size]; - is->read((char*)temp,bupmem_size); - MMU_new.backupDevice.load_old_state(addr_size,temp,bupmem_size); - delete[] temp; - if(is->fail()) return false; + //version 0 was buggy and didnt save the type. + //it would silently fail if there was a size mismatch + SAV_silent_fail_flag = true; + if(read32le(&bupmem_size,is) != 1) return false; + //if(bupmem_size != MMU.bupmem.size) return false; //mismatch between current initialized and saved size + mc_realloc(&MMU.bupmem,MC_TYPE_AUTODETECT,bupmem_size); } - else if(version == 2) + else { - //newer savefile system: - MMU_new.backupDevice.load_state(is); + //version 1 reinitializes the save system with the type that was saved + int bupmem_type; + if(read32le(&bupmem_type,is) != 1) return false; + if(read32le(&bupmem_size,is) != 1) return false; + mc_realloc(&MMU.bupmem,bupmem_type,bupmem_size); } + is->read((char*)MMU.bupmem.data,bupmem_size); + if(is->fail()) return false; + return true; } @@ -460,7 +438,11 @@ void scan_savestates() for( i = 1; i <= NB_STATES; i++ ) { - path.getpathnoext(path.STATES, filename); + #ifdef WIN32 + GetFullPathNoExt(STATES, filename, MAX_PATH); + #else + strncpy(filename, pathFilenameToROMwithoutExt, MAX_PATH); + #endif if (strlen(filename) + strlen(".dst") + strlen("-2147483648") /* = biggest string for i */ >MAX_PATH) return ; sprintf(filename+strlen(filename), ".ds%d", i); @@ -477,9 +459,11 @@ void savestate_slot(int num) struct stat sbuf; char filename[MAX_PATH]; - lastSaveState = num; //Set last savestate used - - path.getpathnoext(path.STATES, filename); + #ifdef WIN32 + GetFullPathNoExt(STATES, filename, MAX_PATH); + #else + strncpy(filename, pathFilenameToROMwithoutExt, MAX_PATH); + #endif if (strlen(filename) + strlen(".dsx") + strlen("-2147483648") /* = biggest string for num */ >MAX_PATH) return ; sprintf(filename+strlen(filename), ".ds%d", num); @@ -505,9 +489,11 @@ void loadstate_slot(int num) { char filename[MAX_PATH]; - lastSaveState = num; //Set last savestate used - - path.getpathnoext(path.STATES, filename); + #ifdef WIN32 + GetFullPathNoExt(STATES, filename, MAX_PATH); + #else + strncpy(filename, pathFilenameToROMwithoutExt, MAX_PATH); + #endif if (strlen(filename) + strlen(".dsx") + strlen("-2147483648") /* = biggest string for num */ >MAX_PATH) return ; sprintf(filename+strlen(filename), ".ds%d", num); @@ -555,9 +541,6 @@ int sram_load (const char *file_name) { fclose ( file ); - osd->setLineColor(255, 255, 255); - osd->addLine("Loaded SRAM"); - return 1; } @@ -575,6 +558,9 @@ int sram_save (const char *file_name) { fclose ( file ); + osd->setLineColor(255, 255, 255); + osd->addLine("Loaded SRAM"); + osd->setLineColor(255, 255, 255); osd->addLine("Saved SRAM"); @@ -739,40 +725,23 @@ static void writechunks(std::ostream* os); static bool savestate_save(std::ostream* outstream, int compressionLevel) { - #ifndef HAVE_LIBZ - compressionLevel = Z_NO_COMPRESSION; - #endif - + //generate the savestate in memory first memorystream ms; - std::ostream* os; - - if(compressionLevel != Z_NO_COMPRESSION) - { - //generate the savestate in memory first - os = (std::ostream*)&ms; - writechunks(os); - ms.flush(); - } - else - { - os = outstream; - os->seekp(32); //skip the header - writechunks(os); - } - - os->flush(); + std::ostream* os = (std::ostream*)&ms; + writechunks(os); + ms.flush(); //save the length of the file - u32 len = os->tellp(); + u32 len = ms.size(); u32 comprlen = 0xFFFFFFFF; - u8* cbuf; + u8* cbuf = (u8*)ms.buf(); +#ifdef HAVE_LIBZ //compress the data int error = Z_OK; if(compressionLevel != Z_NO_COMPRESSION) { - cbuf = (u8*)ms.buf(); uLongf comprlen2; //worst case compression. //zlib says "0.1% larger than sourceLen plus 12 bytes" @@ -783,23 +752,22 @@ static bool savestate_save(std::ostream* outstream, int compressionLevel) error = compress2(cbuf,&comprlen2,(u8*)ms.buf(),len,compressionLevel); comprlen = (u32)comprlen2; } +#endif //dump the header - outstream->seekp(0); outstream->write(magic,16); write32le(SAVESTATE_VERSION,outstream); write32le(DESMUME_VERSION_NUMERIC,outstream); //desmume version write32le(len,outstream); //uncompressed length write32le(comprlen,outstream); //compressed length (-1 if it is not compressed) - outstream->flush(); - - if(compressionLevel != Z_NO_COMPRESSION) - { - outstream->write((char*)cbuf,comprlen==(u32)-1?len:comprlen); - delete[] cbuf; - } + outstream->write((char*)cbuf,comprlen==(u32)-1?len:comprlen); + if(cbuf != (uint8*)ms.buf()) delete[] cbuf; +#ifdef HAVE_LIBZ return error == Z_OK; +#else + return true; +#endif } bool savestate_save (const char *file_name) @@ -828,7 +796,6 @@ static void writechunks(std::ostream* os) { savestate_WriteChunk(os,3,cp15_savestate); savestate_WriteChunk(os,4,SF_MEM); savestate_WriteChunk(os,5,SF_NDS); - savestate_WriteChunk(os,51,nds_savestate); savestate_WriteChunk(os,60,SF_MMU); savestate_WriteChunk(os,61,mmu_savestate); savestate_WriteChunk(os,7,gpu_savestate); @@ -857,7 +824,6 @@ static bool ReadStateChunks(std::istream* is, s32 totalsize) case 3: if(!cp15_loadstate(is,size)) ret=false; break; case 4: if(!ReadStateChunk(is,SF_MEM,size)) ret=false; break; case 5: if(!ReadStateChunk(is,SF_NDS,size)) ret=false; break; - case 51: if(!nds_loadstate(is,size)) ret=false; break; case 60: if(!ReadStateChunk(is,SF_MMU,size)) ret=false; break; case 61: if(!mmu_loadstate(is,size)) ret=false; break; case 7: if(!gpu_loadstate(is,size)) ret=false; break; @@ -983,73 +949,3 @@ bool savestate_load(const char *file_name) return savestate_load(&f); } - -static std::stack rewindFreeList; -static std::vector rewindbuffer; - -int rewindstates = 16; -int rewindinterval = 4; - -void rewindsave () { - - if(currFrameCounter % rewindinterval) - return; - - //printf("rewindsave"); printf("%d%s", currFrameCounter, "\n"); - - - memorystream *ms; - if(!rewindFreeList.empty()) { - ms = rewindFreeList.top(); - rewindFreeList.pop(); - } else { - ms = new memorystream(); - } - - ms->getStreambuf().expand(1024*1024*12); - - if(!savestate_save(ms, Z_NO_COMPRESSION)) - return; - - ms->sync(); - - rewindbuffer.push_back(ms); - - if(rewindbuffer.size() > rewindstates) { - delete *rewindbuffer.begin(); - rewindbuffer.erase(rewindbuffer.begin()); - } -} - -void dorewind() -{ - - if(currFrameCounter % rewindinterval) - return; - - //printf("rewind\n"); - - nds.debugConsole = FALSE; - - int size = rewindbuffer.size(); - - if(size < 1) { - printf("rewind buffer empty\n"); - return; - } - - printf("%d", size); - - memorystream* loadms = rewindbuffer[size-1]; - loadms->seekg(32, std::ios::beg); - - ReadStateChunks(loadms,loadms->size()-32); - loadstate(); - - if(rewindbuffer.size()>1) - { - rewindFreeList.push(loadms); - rewindbuffer.pop_back(); - } - -} \ No newline at end of file diff --git a/desmume/src/saves.h b/src/saves.h similarity index 96% rename from desmume/src/saves.h rename to src/saves.h index 9a25cb3ea..0366e30e4 100644 --- a/desmume/src/saves.h +++ b/src/saves.h @@ -1,69 +1,67 @@ -/* Copyright (C) 2006 Normmatt - Copyright (C) 2007 Pascal Giard - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#ifndef _SRAM_H -#define _SRAM_H - -#include "types.h" - -#define SRAM_ADDRESS 0x0A000000 -#define SRAM_SIZE 0x10000 -#define NB_STATES 10 - -extern int lastSaveState; - -typedef struct -{ - BOOL exists; - char date[40]; -} savestates_t; - - -struct SFORMAT -{ - //a string description of the element - const char *desc; - - //the size of each element - u32 size; - - //the number of each element - u32 count; - - //a void* to the data or a void** to the data - void *v; -}; - -extern savestates_t savestates[NB_STATES]; - -void clear_savestates(); -void scan_savestates(); -u8 sram_read (u32 address); -void sram_write (u32 address, u8 value); -int sram_load (const char *file_name); -int sram_save (const char *file_name); - -bool savestate_load (const char *file_name); -bool savestate_save (const char *file_name); - -void savestate_slot(int num); -void loadstate_slot(int num); - -#endif +/* Copyright (C) 2006 Normmatt + Copyright (C) 2007 Pascal Giard + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#ifndef _SRAM_H +#define _SRAM_H + +#include "types.h" + +#define SRAM_ADDRESS 0x0A000000 +#define SRAM_SIZE 0x10000 +#define NB_STATES 10 + +typedef struct +{ + BOOL exists; + char date[40]; +} savestates_t; + + +struct SFORMAT +{ + //a string description of the element + const char *desc; + + //the size of each element + u32 size; + + //the number of each element + u32 count; + + //a void* to the data or a void** to the data + void *v; +}; + +extern savestates_t savestates[NB_STATES]; + +void clear_savestates(); +void scan_savestates(); +u8 sram_read (u32 address); +void sram_write (u32 address, u8 value); +int sram_load (const char *file_name); +int sram_save (const char *file_name); + +bool savestate_load (const char *file_name); +bool savestate_save (const char *file_name); + +void savestate_slot(int num); +void loadstate_slot(int num); + +#endif diff --git a/desmume/src/shaders.h b/src/shaders.h similarity index 96% rename from desmume/src/shaders.h rename to src/shaders.h index 4cd2cbf6e..89386fd99 100644 --- a/desmume/src/shaders.h +++ b/src/shaders.h @@ -1,78 +1,78 @@ -/* Predefined OpenGL shaders */ - -/* Vertex shader */ -const char *vertexShader = {"\ - void main() \n\ - { \n\ - gl_Position = gl_ModelViewProjectionMatrix * gl_Vertex; \n\ - gl_TexCoord[0] = gl_TextureMatrix[0] * gl_MultiTexCoord0; \n\ - gl_FrontColor = gl_Color; \n\ - } \n\ -"}; - -/* Fragment shader */ -const char *fragmentShader = {"\ - uniform sampler1D toonTable; \n\ - uniform sampler2D tex2d; \n\ - uniform int hasTexture; \n\ - uniform int texBlending; \n\ - \n\ - vec4 float_to_6bit(in vec4 color) \n\ - { \n\ - vec4 ret = color * vec4(31.0,31.0,31.0,31.0);\n\ - \n\ - if(ret.r > 0.0) ret.r = (ret.r * 2.0) + 1.0; \n\ - if(ret.g > 0.0) ret.g = (ret.g * 2.0) + 1.0; \n\ - if(ret.b > 0.0) ret.b = (ret.b * 2.0) + 1.0; \n\ - if(ret.a > 0.0) ret.a = (ret.a * 2.0) + 1.0; \n\ - \n\ - return ret; \n\ - } \n\ - \n\ - void main() \n\ - { \n\ - vec4 vtxColor = float_to_6bit(gl_Color); \n\ - vec4 texColor = float_to_6bit(texture2D(tex2d, gl_TexCoord[0].st)); \n\ - vec3 toonColor = vec3(float_to_6bit(vec4(texture1D(toonTable, gl_Color.r).rgb, 0.0))); \n\ - vec4 fragColor = vec4(0.0, 0.0, 0.0, 0.0); \n\ - \n\ - if(hasTexture == 0) \n\ - { \n\ - texColor = vec4(63.0, 63.0, 63.0, 63.0); \n\ - } \n\ - \n\ - if(texBlending == 0) \n\ - { \n\ - fragColor = ((texColor + 1.0) * (vtxColor + 1.0) - 1.0) / 64.0; \n\ - } \n\ - else if(texBlending == 1) \n\ - { \n\ - if(texColor.a == 0.0 || hasTexture == 0) \n\ - { \n\ - fragColor.rgb = vtxColor.rgb; \n\ - } \n\ - else if(texColor.a == 63.0) \n\ - { \n\ - fragColor.rgb = texColor.rgb; \n\ - } \n\ - else \n\ - { \n\ - fragColor.rgb = ((texColor.rgb * texColor.a) + (vtxColor.rgb * (63.0 - texColor.a))) / 64.0; \n\ - } \n\ - \n\ - fragColor.a = vtxColor.a; \n\ - } \n\ - else if(texBlending == 2) \n\ - { \n\ - fragColor.rgb = ((texColor.rgb + 1.0) * (toonColor + 1.0) - 1.0) / 64.0; \n\ - fragColor.a = ((texColor.a + 1.0) * (vtxColor.a + 1.0) - 1.0) / 64.0; \n\ - } \n\ - else if(texBlending == 3) \n\ - { \n\ - fragColor.rgb = min((((texColor.rgb + 1.0) * (toonColor + 1.0) - 1.0) / 64.0) + toonColor, 63.0); \n\ - fragColor.a = ((texColor.a + 1.0) * (vtxColor.a + 1.0) - 1.0) / 64.0; \n\ - } \n\ - \n\ - gl_FragColor = ((fragColor - 1.0) / 2.0) / 31.0; \n\ - } \n\ -"}; +/* Predefined OpenGL shaders */ + +/* Vertex shader */ +const char *vertexShader = {"\ + void main() \n\ + { \n\ + gl_Position = gl_ModelViewProjectionMatrix * gl_Vertex; \n\ + gl_TexCoord[0] = gl_TextureMatrix[0] * gl_MultiTexCoord0; \n\ + gl_FrontColor = gl_Color; \n\ + } \n\ +"}; + +/* Fragment shader */ +const char *fragmentShader = {"\ + uniform sampler1D toonTable; \n\ + uniform sampler2D tex2d; \n\ + uniform int hasTexture; \n\ + uniform int texBlending; \n\ + \n\ + vec4 float_to_6bit(in vec4 color) \n\ + { \n\ + vec4 ret = color * vec4(31.0,31.0,31.0,31.0);\n\ + \n\ + if(ret.r > 0.0) ret.r = (ret.r * 2.0) + 1.0; \n\ + if(ret.g > 0.0) ret.g = (ret.g * 2.0) + 1.0; \n\ + if(ret.b > 0.0) ret.b = (ret.b * 2.0) + 1.0; \n\ + if(ret.a > 0.0) ret.a = (ret.a * 2.0) + 1.0; \n\ + \n\ + return ret; \n\ + } \n\ + \n\ + void main() \n\ + { \n\ + vec4 vtxColor = float_to_6bit(gl_Color); \n\ + vec4 texColor = float_to_6bit(texture2D(tex2d, gl_TexCoord[0].st)); \n\ + vec3 toonColor = vec3(float_to_6bit(vec4(texture1D(toonTable, gl_Color.r).rgb, 0.0))); \n\ + vec4 fragColor = vec4(0.0, 0.0, 0.0, 0.0); \n\ + \n\ + if(hasTexture == 0) \n\ + { \n\ + texColor = vec4(63.0, 63.0, 63.0, 63.0); \n\ + } \n\ + \n\ + if(texBlending == 0) \n\ + { \n\ + fragColor = ((texColor + 1.0) * (vtxColor + 1.0) - 1.0) / 64.0; \n\ + } \n\ + else if(texBlending == 1) \n\ + { \n\ + if(texColor.a == 0.0 || hasTexture == 0) \n\ + { \n\ + fragColor.rgb = vtxColor.rgb; \n\ + } \n\ + else if(texColor.a == 63.0) \n\ + { \n\ + fragColor.rgb = texColor.rgb; \n\ + } \n\ + else \n\ + { \n\ + fragColor.rgb = ((texColor.rgb * texColor.a) + (vtxColor.rgb * (63.0 - texColor.a))) / 64.0; \n\ + } \n\ + \n\ + fragColor.a = vtxColor.a; \n\ + } \n\ + else if(texBlending == 2) \n\ + { \n\ + fragColor.rgb = ((texColor.rgb + 1.0) * (toonColor + 1.0) - 1.0) / 64.0; \n\ + fragColor.a = ((texColor.a + 1.0) * (vtxColor.a + 1.0) - 1.0) / 64.0; \n\ + } \n\ + else if(texBlending == 3) \n\ + { \n\ + fragColor.rgb = min((((texColor.rgb + 1.0) * (toonColor + 1.0) - 1.0) / 64.0) + toonColor, 63.0); \n\ + fragColor.a = ((texColor.a + 1.0) * (vtxColor.a + 1.0) - 1.0) / 64.0; \n\ + } \n\ + \n\ + gl_FragColor = ((fragColor - 1.0) / 2.0) / 31.0; \n\ + } \n\ +"}; diff --git a/desmume/src/sndsdl.cpp b/src/sndsdl.cpp similarity index 96% rename from desmume/src/sndsdl.cpp rename to src/sndsdl.cpp index 4f2c8bd34..16ea300c5 100644 --- a/desmume/src/sndsdl.cpp +++ b/src/sndsdl.cpp @@ -1,189 +1,189 @@ -/* Copyright 2005-2006 Theo Berkau - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - Yabause is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with Yabause; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#include -#include - -#include -#include "types.h" -#include "SPU.h" -#include "sndsdl.h" -#include "debug.h" - -int SNDSDLInit(int buffersize); -void SNDSDLDeInit(); -void SNDSDLUpdateAudio(s16 *buffer, u32 num_samples); -u32 SNDSDLGetAudioSpace(); -void SNDSDLMuteAudio(); -void SNDSDLUnMuteAudio(); -void SNDSDLSetVolume(int volume); - -SoundInterface_struct SNDSDL = { -SNDCORE_SDL, -"SDL Sound Interface", -SNDSDLInit, -SNDSDLDeInit, -SNDSDLUpdateAudio, -SNDSDLGetAudioSpace, -SNDSDLMuteAudio, -SNDSDLUnMuteAudio, -SNDSDLSetVolume -}; - -static u16 *stereodata16; -static u32 soundoffset; -static volatile u32 soundpos; -static u32 soundlen; -static u32 soundbufsize; -static SDL_AudioSpec audiofmt; - -////////////////////////////////////////////////////////////////////////////// - -static void MixAudio(void *userdata, Uint8 *stream, int len) { - int i; - Uint8 *soundbuf=(Uint8 *)stereodata16; - - for (i = 0; i < len; i++) - { - if (soundpos >= soundbufsize) - soundpos = 0; - - stream[i] = soundbuf[soundpos]; - soundpos++; - } -} - -////////////////////////////////////////////////////////////////////////////// - -int SNDSDLInit(int buffersize) -{ - if (SDL_InitSubSystem(SDL_INIT_AUDIO) != 0) - return -1; - - audiofmt.freq = 44100; - audiofmt.format = AUDIO_S16SYS; - audiofmt.channels = 2; - audiofmt.samples = (audiofmt.freq / 60) * 2; - audiofmt.callback = MixAudio; - audiofmt.userdata = NULL; - - //samples should be a power of 2 according to SDL-doc - //so normalize it to the nearest power of 2 here - u32 normSamples = 512; - while (normSamples < audiofmt.samples) - normSamples <<= 1; - - audiofmt.samples = normSamples; - - soundlen = audiofmt.freq / 60; // 60 for NTSC - soundbufsize = buffersize * sizeof(s16) * 2; - - if (SDL_OpenAudio(&audiofmt, NULL) != 0) - { - return -1; - } - - if ((stereodata16 = (u16 *)malloc(soundbufsize)) == NULL) - return -1; - - memset(stereodata16, 0, soundbufsize); - - soundpos = 0; - - SDL_PauseAudio(0); - - return 0; -} - -////////////////////////////////////////////////////////////////////////////// - -void SNDSDLDeInit() -{ - SDL_CloseAudio(); - - if (stereodata16) - free(stereodata16); -} - -////////////////////////////////////////////////////////////////////////////// - -void SNDSDLUpdateAudio(s16 *buffer, u32 num_samples) -{ - u32 copy1size=0, copy2size=0; - SDL_LockAudio(); - - if ((soundbufsize - soundoffset) < (num_samples * sizeof(s16) * 2)) - { - copy1size = (soundbufsize - soundoffset); - copy2size = (num_samples * sizeof(s16) * 2) - copy1size; - } - else - { - copy1size = (num_samples * sizeof(s16) * 2); - copy2size = 0; - } - - memcpy((((u8 *)stereodata16)+soundoffset), buffer, copy1size); -// ScspConvert32uto16s((s32 *)leftchanbuffer, (s32 *)rightchanbuffer, (s16 *)(((u8 *)stereodata16)+soundoffset), copy1size / sizeof(s16) / 2); - - if (copy2size) - memcpy(stereodata16, ((u8 *)buffer)+copy1size, copy2size); -// ScspConvert32uto16s((s32 *)leftchanbuffer, (s32 *)rightchanbuffer, (s16 *)stereodata16, copy2size / sizeof(s16) / 2); - - soundoffset += copy1size + copy2size; - soundoffset %= soundbufsize; - - SDL_UnlockAudio(); -} - -////////////////////////////////////////////////////////////////////////////// - -u32 SNDSDLGetAudioSpace() -{ - u32 freespace=0; - - if (soundoffset > soundpos) - freespace = soundbufsize - soundoffset + soundpos; - else - freespace = soundpos - soundoffset; - - return (freespace / sizeof(s16) / 2); -} - -////////////////////////////////////////////////////////////////////////////// - -void SNDSDLMuteAudio() -{ - SDL_PauseAudio(1); -} - -////////////////////////////////////////////////////////////////////////////// - -void SNDSDLUnMuteAudio() -{ - SDL_PauseAudio(0); -} - -////////////////////////////////////////////////////////////////////////////// - -void SNDSDLSetVolume(int volume) -{ -} - -////////////////////////////////////////////////////////////////////////////// +/* Copyright 2005-2006 Theo Berkau + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + Yabause is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with Yabause; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#include +#include + +#include +#include "types.h" +#include "SPU.h" +#include "sndsdl.h" +#include "debug.h" + +int SNDSDLInit(int buffersize); +void SNDSDLDeInit(); +void SNDSDLUpdateAudio(s16 *buffer, u32 num_samples); +u32 SNDSDLGetAudioSpace(); +void SNDSDLMuteAudio(); +void SNDSDLUnMuteAudio(); +void SNDSDLSetVolume(int volume); + +SoundInterface_struct SNDSDL = { +SNDCORE_SDL, +"SDL Sound Interface", +SNDSDLInit, +SNDSDLDeInit, +SNDSDLUpdateAudio, +SNDSDLGetAudioSpace, +SNDSDLMuteAudio, +SNDSDLUnMuteAudio, +SNDSDLSetVolume +}; + +static u16 *stereodata16; +static u32 soundoffset; +static volatile u32 soundpos; +static u32 soundlen; +static u32 soundbufsize; +static SDL_AudioSpec audiofmt; + +////////////////////////////////////////////////////////////////////////////// + +static void MixAudio(void *userdata, Uint8 *stream, int len) { + int i; + Uint8 *soundbuf=(Uint8 *)stereodata16; + + for (i = 0; i < len; i++) + { + if (soundpos >= soundbufsize) + soundpos = 0; + + stream[i] = soundbuf[soundpos]; + soundpos++; + } +} + +////////////////////////////////////////////////////////////////////////////// + +int SNDSDLInit(int buffersize) +{ + if (SDL_InitSubSystem(SDL_INIT_AUDIO) != 0) + return -1; + + audiofmt.freq = 44100; + audiofmt.format = AUDIO_S16SYS; + audiofmt.channels = 2; + audiofmt.samples = (audiofmt.freq / 60) * 2; + audiofmt.callback = MixAudio; + audiofmt.userdata = NULL; + + //samples should be a power of 2 according to SDL-doc + //so normalize it to the nearest power of 2 here + u32 normSamples = 512; + while (normSamples < audiofmt.samples) + normSamples <<= 1; + + audiofmt.samples = normSamples; + + soundlen = audiofmt.freq / 60; // 60 for NTSC + soundbufsize = buffersize * sizeof(s16) * 2; + + if (SDL_OpenAudio(&audiofmt, NULL) != 0) + { + return -1; + } + + if ((stereodata16 = (u16 *)malloc(soundbufsize)) == NULL) + return -1; + + memset(stereodata16, 0, soundbufsize); + + soundpos = 0; + + SDL_PauseAudio(0); + + return 0; +} + +////////////////////////////////////////////////////////////////////////////// + +void SNDSDLDeInit() +{ + SDL_CloseAudio(); + + if (stereodata16) + free(stereodata16); +} + +////////////////////////////////////////////////////////////////////////////// + +void SNDSDLUpdateAudio(s16 *buffer, u32 num_samples) +{ + u32 copy1size=0, copy2size=0; + SDL_LockAudio(); + + if ((soundbufsize - soundoffset) < (num_samples * sizeof(s16) * 2)) + { + copy1size = (soundbufsize - soundoffset); + copy2size = (num_samples * sizeof(s16) * 2) - copy1size; + } + else + { + copy1size = (num_samples * sizeof(s16) * 2); + copy2size = 0; + } + + memcpy((((u8 *)stereodata16)+soundoffset), buffer, copy1size); +// ScspConvert32uto16s((s32 *)leftchanbuffer, (s32 *)rightchanbuffer, (s16 *)(((u8 *)stereodata16)+soundoffset), copy1size / sizeof(s16) / 2); + + if (copy2size) + memcpy(stereodata16, ((u8 *)buffer)+copy1size, copy2size); +// ScspConvert32uto16s((s32 *)leftchanbuffer, (s32 *)rightchanbuffer, (s16 *)stereodata16, copy2size / sizeof(s16) / 2); + + soundoffset += copy1size + copy2size; + soundoffset %= soundbufsize; + + SDL_UnlockAudio(); +} + +////////////////////////////////////////////////////////////////////////////// + +u32 SNDSDLGetAudioSpace() +{ + u32 freespace=0; + + if (soundoffset > soundpos) + freespace = soundbufsize - soundoffset + soundpos; + else + freespace = soundpos - soundoffset; + + return (freespace / sizeof(s16) / 2); +} + +////////////////////////////////////////////////////////////////////////////// + +void SNDSDLMuteAudio() +{ + SDL_PauseAudio(1); +} + +////////////////////////////////////////////////////////////////////////////// + +void SNDSDLUnMuteAudio() +{ + SDL_PauseAudio(0); +} + +////////////////////////////////////////////////////////////////////////////// + +void SNDSDLSetVolume(int volume) +{ +} + +////////////////////////////////////////////////////////////////////////////// diff --git a/desmume/src/sndsdl.h b/src/sndsdl.h similarity index 97% rename from desmume/src/sndsdl.h rename to src/sndsdl.h index 2561455b5..71288d9c3 100644 --- a/desmume/src/sndsdl.h +++ b/src/sndsdl.h @@ -1,26 +1,26 @@ -/* Copyright 2005-2006 Theo Berkau - - This file is part of DeSmuME. - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - Yabause is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with Yabause; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#ifndef SNDSDL_H -#define SNDSDL_H - -#define SNDCORE_SDL 2 - -extern SoundInterface_struct SNDSDL; -#endif +/* Copyright 2005-2006 Theo Berkau + + This file is part of DeSmuME. + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + Yabause is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with Yabause; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#ifndef SNDSDL_H +#define SNDSDL_H + +#define SNDCORE_SDL 2 + +extern SoundInterface_struct SNDSDL; +#endif diff --git a/src/softrender.cpp b/src/softrender.cpp new file mode 100644 index 000000000..e703aa5a6 --- /dev/null +++ b/src/softrender.cpp @@ -0,0 +1,752 @@ +/// The VERGE 3 Project is originally by Ben Eirich and is made available via +/// the BSD License. +/// +/// Please see LICENSE in the project's root directory for the text of the +/// licensing agreement. The CREDITS file in the same directory enumerates the +/// folks involved in this public build. +/// +/// If you have altered this source file, please log your name, date, and what +/// changes you made below this line. + + +/**************************************************************** + xerxes engine + vid_manager.cpp + ****************************************************************/ + +#include "softrender.h" +#include +#include + +#include "softrender_v3sysfont.h" + +namespace softrender { + + //instantiations + Trender32 render32; + Trender16 render16; + Trender15 render15; + Trender51 render51; + + + template + T sgn(const T& a) { + if (a<0) + return -1; + else if (a>0) + return +1; + else return 0; + } + + template + T abs(const T& a) { + if (a<0) + return -a; + else return a; + } + + template + void SWAP(T& a, T& b) { + T temp = a; + a = b; + b = temp; + } + + +/***************************** data *****************************/ + +bool vid_initd = false; +bool vid_window = true; +int vid_bpp, vid_xres, vid_yres, vid_bytesperpixel; +int transColor; +image *screen; + +/****************************************************************/ + +image::image() +{ +} + + +image::image(int xres, int yres) +{ + width = pitch = xres; + height = yres; + cx1 = 0; + cy1 = 0; + cx2 = width - 1; + cy2 = height - 1; + bpp = vid_bpp; + shell = 0; + data = new char[width*height*vid_bytesperpixel]; + //switch (vid_bpp) + //{ + // case 15: + // case 16: + // case 61: data = new word[width * height]; + // break; + // case 32: data = new quad[width * height]; + // break; + //} +} + +void image::delete_data() +{ + delete[] (char *)data; +} + +image::~image() +{ + if (data && !shell) + delete_data(); +} + + +void image::SetClip(int x1, int y1, int x2, int y2) +{ + cx1 = x1 >= 0 ? x1 : 0; + cy1 = y1 >= 0 ? y1 : 0; + cx1 = cx1 < width ? cx1 : width-1; + cy1 = cy1 < height ? cy1 : height-1; + cx2 = x2 >= 0 ? x2 : 0; + cy2 = y2 >= 0 ? y2 : 0; + cx2 = cx2 < width ? cx2 : width-1; + cy2 = cy2 < height ? cy2 : height-1; +} + + +void image::GetClip(int &x1, int &y1, int &x2, int &y2) +{ + x1 = cx1; + y1 = cy1; + x2 = cx2; + y2 = cy2; +} + + +//generic render methods + +//template +//void renderbase::print_char(char c, image *dest) +//{ +// int height = FONT::height(c); +//} + +void renderbase::Line(int x, int y, int xe, int ye, int color, image *dest) +{ + int dx = xe - x, dy = ye - y, + xg = sgn(dx), yg = sgn(dy), + i = 0; + float slope = 0; + + if (abs(dx) >= abs(dy)) + { + slope = (float) dy / (float) dx; + for (i=0; i!=dx; i+=xg) + PutPixel(x+i, y+(int)(slope*i), color, dest); + } + else + { + slope = (float) dx / (float) dy; + for (i=0; i!=dy; i+=yg) + PutPixel(x+(int)(slope*i), y+i, color, dest); + } + PutPixel(xe, ye, color, dest); +} + +void renderbase::Box(int x, int y, int x2, int y2, int color, image *dest) +{ + if (x20) + { + if (r<=0) + { + xx-=2; + x++, xe++; + rx-=dy; + r+=rx; + } + if (r>0) + { + y--, ye++; + ry+=dx; + r-=ry; + } + + if (Fill && y != lasty) + { + HLine(x, y, x+xx-1, color, dest); + HLine(xe, ye, xe+xx-1, color, dest); + } + else { + PutPixel(x, y, color, dest); + PutPixel(x+xx, y, color, dest); + PutPixel(xe, ye, color, dest); + PutPixel(xe+xx, ye, color, dest); + } + lasty = y; + } +} + + + +void renderbase::GrabRegion(int sx1, int sy1, int sx2, int sy2, int dx, int dy, image *s, image *d) +{ + int dcx1, dcy1, dcx2, dcy2; + d->GetClip(dcx1, dcy1, dcx2, dcy2); + + if (sx1>sx2) SWAP(sx1, sx2); + if (sy1>sy2) SWAP(sy1, sy2); + int grabwidth = sx2 - sx1; + int grabheight = sy2 - sy1; + d->SetClip(dx, dy, dx+grabwidth, dy+grabheight); + Blit(dx-sx1, dy-sy1, s, d); + + d->SetClip(dcx1, dcy1, dcx2, dcy2); +} + +// Overkill 2006-02-04 +void renderbase::RectVGrad(int x, int y, int x2, int y2, int color, int color2, image *dest) +{ + int r, g, b; + int color_r, color_g, color_b; + int color_r2, color_g2, color_b2; + int i = 0; + + GetColor(color, color_r, color_g, color_b); + GetColor(color2, color_r2, color_g2, color_b2); + + if (y2 < y) SWAP(y,y2); + + for(i = 0; i <= y2 - y; i++) + { + r = ((i * (color_r2 - color_r) / (y2 - y)) + color_r); + g = ((i * (color_g2 - color_g) / (y2 - y)) + color_g); + b = ((i * (color_b2 - color_b) / (y2 - y)) + color_b); + HLine(x, y + i, x2, MakeColor(r, g, b), dest); + } +} + +// Overkill 2006-02-04 +void renderbase::RectHGrad(int x, int y, int x2, int y2, int color, int color2, image *dest) +{ + int r, g, b; + int color_r, color_g, color_b; + int color_r2, color_g2, color_b2; + int i = 0; + + GetColor(color, color_r, color_g, color_b); + GetColor(color2, color_r2, color_g2, color_b2); + + if (x2 < x) SWAP(x,x2); + + for(i = 0; i <= x2 - x; i++) + { + r = ((i * (color_r2 - color_r) / (x2 - x)) + color_r); + g = ((i * (color_g2 - color_g) / (x2 - x)) + color_g); + b = ((i * (color_b2 - color_b) / (x2 - x)) + color_b); + VLine(x + i, y, y2, MakeColor(r, g, b), dest); + } +} + +// janus 2006-07-22 + +// radial gradient: color1 is edge color, color2 is center color +void renderbase::RectRGrad(int x1, int y1, int x2, int y2, int color1, int color2, image *dest) +{ + int r1, r2, g1, g2, b1, b2; + GetColor(color1, r1, g1, b1); + GetColor(color2, r2, g2, b2); + if (x2 < x1) SWAP(x1,x2); + if (y2 < y1) SWAP(y1,y2); + int w = (x2 - x1) + 1; + int h = (y2 - y1) + 1; + int z; + if ((w == 0) || (h == 0)) return; + // lookup table to eliminate the sqrt-per-pixel + static bool tableInitialized = false; + static struct pythagorasTable { byte v[256]; } pythagorasLookup[256]; + if (!tableInitialized) { + // we initialize this table on the fly the first time this function is invoked + // the output of the formula is not in the value range we require for 8bpp so we scale it + // if you want a nonscaled gradient, set this constant to 1.0f + const float pythagorasConstant = 0.707106781186547f; + for (unsigned a = 0; a < 256; a++) { + for (unsigned b = 0; b < 256; b++) { + float value = sqrt((float)(a * a) + (b * b)) * pythagorasConstant; + if (value <= 0) + pythagorasLookup[a].v[b] = 0; + else if (value >= 255) + pythagorasLookup[a].v[b] = 255; + else + pythagorasLookup[a].v[b] = unsigned(value) & 0xFF; + } + } + tableInitialized = true; + } + // color lookup table to reduce per-pixel blending computations + int colorTable[256]; + for (int i = 0; i < 256; i++) { + unsigned r = r2 + ((r1 - r2) * i / 255); + unsigned g = g2 + ((g1 - g2) * i / 255); + unsigned b = b2 + ((b1 - b2) * i / 255); + colorTable[i] = MakeColor(r, g, b); + } + // x and y weight tables which unfortunately must be dynamically allocated due to the fact that their size depends on the size of the rect + byte* xTable = new byte[w]; + byte* yTable = new byte[h]; + { + // the float->int conversions in here are kind of expensive, it might be alright to do this in integer. + // haven't tested the math enough to be sure though, so float it is ('cause i'm lazy) + float xMul = 255.0f / (w / 2), yMul = 255.0f / (h / 2); + int xOffset = (w / 2), yOffset = (h / 2); + // these tables convert x/y coordinates into 0-255 weights which can be used to index the sqrt table + for (int x = 0; x < w; x++) { + xTable[x] = unsigned((float)abs(x - xOffset) * xMul) & 0xFF; + } + for (int y = 0; y < h; y++) { + yTable[y] = unsigned((float)abs(y - yOffset) * yMul) & 0xFF; + } + } + for (int y = 0; y < h; y++) { + for (int x = 0; x < w; x++) { + z = pythagorasLookup[yTable[y]].v[xTable[x]]; + PutPixel(x+x1, y+y1, colorTable[z], dest); + } + } + // cleanup locals + delete[] xTable; + delete[] yTable; +} + +// 4-corner gradient: color1-4 are edges top left, top right, bottom left, bottom right +void renderbase::Rect4Grad(int x1, int y1, int x2, int y2, int color1, int color2, int color3, int color4, image *dest) +{ + int cr[4], cg[4], cb[4]; + GetColor(color1, cr[0], cg[0], cb[0]); + GetColor(color2, cr[1], cg[1], cb[1]); + GetColor(color3, cr[2], cg[2], cb[2]); + GetColor(color4, cr[3], cg[3], cb[3]); + if (x2 < x1) SWAP(x1,x2); + if (y2 < y1) SWAP(y1,y2); + int w = (x2 - x1) + 1; + int h = (y2 - y1) + 1; + if ((w == 0) || (h == 0)) return; + unsigned wDiv = w-1; + unsigned hDiv = h-1; + for (int y = 0; y < h; y++) { + for (int x = 0; x < w; x++) { + // calculate x and y weights + unsigned aX = x * 255 / wDiv; + unsigned aY = y * 255 / hDiv; + // calculate per-color weights + unsigned a[4]; // tl tr bl br + a[0] = (aX^0xFF) * (aY^0xFF) / 255; + a[1] = aX * (aY^0xFF) / 255; + a[2] = (aX^0xFF) * aY / 255; + a[3] = 255 - (a[0] + a[1] + a[2]); + // blend + unsigned r = ((cr[0] * a[0]) + (cr[1] * a[1]) + (cr[2] * a[2]) + (cr[3] * a[3])) / 255; + unsigned g = ((cg[0] * a[0]) + (cg[1] * a[1]) + (cg[2] * a[2]) + (cg[3] * a[3])) / 255; + unsigned b = ((cb[0] * a[0]) + (cb[1] * a[1]) + (cb[2] * a[2]) + (cb[3] * a[3])) / 255; + PutPixel(x+x1, y+y1, MakeColor(r, g, b), dest); + } + } +} + +int Trender32::MakeColor(int r, int g, int b) +{ + return ((r<<16)|(g<<8)|b); +} + + +bool Trender32::GetColor(int c, int &r, int &g, int &b) +{ +// if (c == transColor) return false; + b = c & 0xff; + g = (c >> 8) & 0xff; + r = (c >> 16) & 0xff; + return true; +} + + + +void Trender32::Clear(int color, image *dest) +{ + int *d = (int *)dest->data; + int bytes = dest->pitch * dest->height; + while (bytes--) + *d++ = color; +} + + +int Trender32::ReadPixel(int x, int y, image *source) +{ + quad *ptr = (quad*)source->data; + return ptr[(y * source->pitch) + x]; +} + + +void Trender32::PutPixel(int x, int y, int color, image *dest) +{ + int *ptr = (int *)dest->data; + if (xcx1 || x>dest->cx2 || ycy1 || y>dest->cy2) + return; + ptr[(y * dest->pitch) + x] = color; +} + + +void Trender32::HLine(int x, int y, int xe, int color, image *dest) +{ + int *d = (int *) dest->data; + int cx1=0, cy1=0, cx2=0, cy2=0; + if (xeGetClip(cx1, cy1, cx2, cy2); + if (x>cx2 || y>cy2 || xecx2) xe=cx2; + if (xpitch) + x; + for (; x<=xe; x++) + *d++ = color; +} + +void Trender32::VLine(int x, int y, int ye, int color, image *dest) +{ + int *d = (int *) dest->data; + int cx1=0, cy1=0, cx2=0, cy2=0; + if (yeGetClip(cx1, cy1, cx2, cy2); + if (x>cx2 || y>cy2 || xcy2) ye=cy2; + if (ypitch) + x; + for (; y<=ye; y++, d+=dest->pitch) + *d = color; +} + +void Trender32::Blit(int x, int y, image *src, image *dest) +{ + int *s=(int *)src->data, + *d=(int *)dest->data; + int spitch=src->pitch, + dpitch=dest->pitch; + int xlen=src->width, + ylen=src->height; + int cx1=0, cy1=0, + cx2=0, cy2=0; + + dest->GetClip(cx1, cy1, cx2, cy2); + if (x>cx2 || y>cy2 || x+xlencx2) xlen = cx2-x+1; + if (y+ylen>cy2) ylen = cy2-y+1; + if (xdata,c, + *d=(int *)dest->data; + int spitch=src->pitch, + dpitch=dest->pitch; + int xlen=src->width, + ylen=src->height; + int cx1=0, cy1=0, + cx2=0, cy2=0; + + dest->GetClip(cx1, cy1, cx2, cy2); + if (x>cx2 || y>cy2 || x+xlen cx2) xlen=cx2-x+1; + if (y+ylen > cy2) ylen=cy2-y+1; + if (x>3)<<11)|((g>>2)<<5)|(b>>3)); +} + +bool Trender16::GetColor(int c, int &r, int &g, int &b) +{ +// if (c == transColor) return false; + b = (c & 0x1F) << 3; + g = ((c >> 5) & 0x3f) << 2; + r = ((c >> 11) & 0x1f) << 3; + return true; +} + + +void Trender16::Clear(int color, image *dest) +{ + word *d = (word *)dest->data; + int bytes = dest->pitch * dest->height; + while (bytes--) + *d++ = color; +} + + +int Trender16::ReadPixel(int x, int y, image *source) +{ + word *ptr = (word*)source->data; + return ptr[(y * source->pitch) + x]; +} + + +void Trender16::PutPixel(int x, int y, int color, image *dest) +{ + word *ptr = (word *)dest->data; + if (xcx1 || x>dest->cx2 || ycy1 || y>dest->cy2) + return; + ptr[(y * dest->pitch) + x] = color; +} + +void Trender16::VLine(int x, int y, int ye, int color, image *dest) +{ + word *d = (word *) dest->data; + int cx1=0, cy1=0, cx2=0, cy2=0; + if (yeGetClip(cx1, cy1, cx2, cy2); + if (x>cx2 || y>cy2 || xcy2) ye=cy2; + if (ypitch) + x; + for (; y<=ye; y++, d+=dest->pitch) + *d = color; +} + +void Trender16::HLine(int x, int y, int xe, int color, image *dest) +{ + word *d = (word *) dest->data; + int cx1=0, cy1=0, cx2=0, cy2=0; + if (xeGetClip(cx1, cy1, cx2, cy2); + if (x>cx2 || y>cy2 || xecx2) xe=cx2; + if (xpitch) + x; + for (; x<=xe; x++) + *d++ = color; +} + +void Trender16::Blit(int x, int y, image *src, image *dest) +{ + word *s=(word *)src->data, + *d=(word *)dest->data; + int spitch=src->pitch, + dpitch=dest->pitch; + int xlen=src->width, + ylen=src->height; + int cx1=0, cy1=0, + cx2=0, cy2=0; + + dest->GetClip(cx1, cy1, cx2, cy2); + if (x>cx2 || y>cy2 || x+xlencx2) xlen = cx2-x+1; + if (y+ylen>cy2) ylen = cy2-y+1; + if (xdata,c, + *d=(word *)dest->data; + int spitch=src->pitch, + dpitch=dest->pitch; + int xlen=src->width, + ylen=src->height; + int cx1=0, cy1=0, + cx2=0, cy2=0; + + dest->GetClip(cx1, cy1, cx2, cy2); + if (x>cx2 || y>cy2 || x+xlen cx2) xlen=cx2-x+1; + if (y+ylen > cy2) ylen=cy2-y+1; + if (x>3)<<10)|((g>>3)<<5)|(b>>3))|0x8000; //0x8000 for opaque +} + + +bool Trender15::GetColor(int c, int &r, int &g, int &b) +{ +// if (c == transColor) return false; + b = (c & 0x1F) << 3; + g = ((c >> 5) & 0x1f) << 3; + r = ((c >> 10) & 0x1f) << 3; + return true; +} + +/********************** 51bpp (15bpp with high bit blue) blitter code **********************/ + +int Trender51::MakeColor(int r, int g, int b) +{ + return (((b>>3)<<10)|((g>>3)<<5)|(r>>3))|0x8000; //0x8000 for opaque +} + + +bool Trender51::GetColor(int c, int &r, int &g, int &b) +{ +// if (c == transColor) return false; + r = (c & 0x1F) << 3; + g = ((c >> 5) & 0x1f) << 3; + b = ((c >> 10) & 0x1f) << 3; + return true; +} + + +} //end namespace diff --git a/src/softrender.h b/src/softrender.h new file mode 100644 index 000000000..e43020f9c --- /dev/null +++ b/src/softrender.h @@ -0,0 +1,235 @@ +/// The VERGE 3 Project is originally by Ben Eirich and is made available via +/// the BSD License. +/// +/// Please see LICENSE in the project's root directory for the text of the +/// licensing agreement. The CREDITS file in the same directory enumerates the +/// folks involved in this public build. +/// +/// If you have altered this source file, please log your name, date, and what +/// changes you made below this line. + + +#ifndef SOFTRENDER_H +#define SOFTRENDER_H + +#include +#include "softrender_config.h" + +namespace softrender { + + +class image +{ +public: + int width, height, pitch; + int cx1, cy1, cx2, cy2; + int bpp, shell; + void *data; + + image(); + image(int xres, int yres); + ~image(); + void delete_data(); + void SetClip(int x1, int y1, int x2, int y2); + void GetClip(int &x1, int &y1, int &x2, int &y2); +}; + +extern int vid_bpp, vid_xres, vid_yres, vid_bytesperpixel, transColor; +extern bool vid_window; +extern image *screen; +extern int alpha, ialpha; +extern int skewlines[]; + +int SetLucent(int percent); + +//void run2xSAI(image *src, image *dest); + +class renderbase { +private: + + void Oval(int x, int y, int xe, int ye, int color, int Fill, image *dest); +public: + //render methods that do not depend on the pixel format + void Line(int x, int y, int xe, int ye, int color, image *dest); + void Box(int x, int y, int xe, int ye, int color, image *dest); + void Rect(int x, int y, int xe, int ye, int color, image *dest); + void Sphere(int x, int y, int xradius, int yradius, int color, image *dest); + void Circle(int x, int y, int xradius, int yradius, int color, image *dest); + void RectVGrad(int x, int y, int xe, int ye, int color, int color2, image *dest); + void RectHGrad(int x, int y, int xe, int ye, int color, int color2, image *dest); + void RectRGrad(int x1, int y1, int x2, int y2, int color1, int color2, image *dest); + void Rect4Grad(int x1, int y1, int x2, int y2, int color1, int color2, int color3, int color4, image *dest); + + //things that werent originally even blitter-specific + void GrabRegion(int sx1, int sy1, int sx2, int sy2, int dx, int dy, image *s, image *d); + +private: + bool textBoxBorder; + template + void print_char(int scale, int x, int y, int color, char c, image *dest) + { + int height = FONT::height(); + int width = FONT::width(c); + int ofs = FONT::haveContour()?1:0; + + if (FONT::haveContour()) + { + for (int yc=0; yc + void PrintString(int scale, int x, int y, int color, char *str, image *dest) + { + int xc = x; + int yc = y; + + int height = FONT::height(); + int boxSize= 0; + if (FONT::haveContour()) + boxSize = ((FONT::width(*str)*scale+scale+1)*strlen(str)); + else + boxSize = ((FONT::width(*str)*scale+scale)*strlen(str)); + + int x1 = x; // Remember where x where the line should start. -- Overkill 2005-12-28. + for (; *str; ++str) + { + // New lines -- Overkill 2005-12-28. + if (*str == '\n' || *str == '\r') + { + if (*str == '\r') + { + // Checks for \r\n so they aren't parsed as two seperate line breaks. + if (!*++str) return; + if (*str != '\n') + { + *--str; + } + } + xc = x1; + yc += height*scale + scale; + } else { + print_char(scale, xc, yc, color, *str, dest); + xc += FONT::width(*str)*scale + scale; + if (FONT::haveContour()) xc += 1; + } + } + if (textBoxBorder) + Box(x, y, x+boxSize, y+height, MakeColor(0, 0, 0), dest); + } + + +public: + virtual int MakeColor(int r, int g, int b)=0; + virtual bool GetColor(int c, int &r, int &g, int &b)=0; + virtual void Clear(int color, image *dest)=0; + virtual int ReadPixel(int x, int y, image *dest)=0; + virtual void PutPixel(int x, int y, int color, image *dest)=0; + virtual void VLine(int x, int y, int ye, int color, image *dest)=0; + virtual void HLine(int x, int y, int xe, int color, image *dest)=0; + virtual void Blit(int x, int y, image *src, image *dest)=0; + virtual void TBlit(int x, int y, image *src, image *dest)=0; + //virtual void AlphaBlit(int x, int y, image *src, image *alpha, image *dest); + //virtual void AdditiveBlit(int x, int y, image *src, image *dest); + //virtual void TAdditiveBlit(int x, int y, image *src, image *dest); + //virtual void SubtractiveBlit(int x, int y, image *src, image *dest); + //virtual void TSubtractiveBlit(int x, int y, image *src, image *dest); + //virtual void BlitTile(int x, int y, char *src, image *dest); + //virtual void TBlitTile(int x, int y, char *src, image *dest); + //virtual void ScaleBlit(int x, int y, int dw, int dh, image *src, image *dest); + //virtual void TScaleBlit(int x, int y, int dw, int dh, image *src, image *dest); + //virtual void WrapBlit(int x, int y, image *src, image *dst); + //virtual void TWrapBlit(int x, int y, image *src, image *dst); + //virtual void Silhouette(int x, int y, int c, image *src, image *dst); + //virtual void RotScale(int x, int y, float angle, float scale, image *src, image *dest); + //virtual void Mosaic(int xf, int yf, image *src); + //virtual void Timeless(int x, int y1, int y, image *src, image *dest); + //virtual void BlitWrap(int x, int y, image *src, image *dest); + //virtual void ColorFilter(int filter, image *img); + //virtual void Triangle(int x1, int y1, int x2, int y2, int x3, int y3, int c, image *dest); + //virtual void FlipBlit(int x, int y, int fx, int fy, image *src, image *dest); + //virtual image* ImageFrom8bpp(byte *src, int width, int height, byte *pal); + //virtual image* ImageFrom24bpp(byte *src, int width, int height); + //virtual image* ImageFrom32bpp(byte *src, int width, int height); + //// Overkill (2007-05-04) + //virtual int HSVtoColor(int h, int s, int v); + //// Overkill (2007-05-04) + //virtual void GetHSV(int color, int &h, int &s, int &v); + //// Overkill (2007-05-04) + //virtual void HueReplace(int hue_find, int hue_tolerance, int hue_replace, image *img); + //// Overkill (2007-05-04) + //virtual void ColorReplace(int color_find, int color_replace, image *img); +}; + +class Trender16: public renderbase +{ +public: + virtual int MakeColor(int r, int g, int b); + virtual bool GetColor(int c, int &r, int &g, int &b); + virtual void Clear(int color, image *dest); + virtual int ReadPixel(int x, int y, image *dest); + virtual void PutPixel(int x, int y, int color, image *dest); + virtual void VLine(int x, int y, int ye, int color, image *dest); + virtual void HLine(int x, int y, int xe, int color, image *dest); + virtual void Blit(int x, int y, image *src, image *dest); + virtual void TBlit(int x, int y, image *src, image *dest); +}; + +class Trender32: public renderbase +{ +public: + virtual int MakeColor(int r, int g, int b); + virtual bool GetColor(int c, int &r, int &g, int &b); + virtual void Clear(int color, image *dest); + virtual int ReadPixel(int x, int y, image *dest); + virtual void PutPixel(int x, int y, int color, image *dest); + virtual void VLine(int x, int y, int ye, int color, image *dest); + virtual void HLine(int x, int y, int xe, int color, image *dest); + virtual void Blit(int x, int y, image *src, image *dest); + virtual void TBlit(int x, int y, image *src, image *dest); +}; + + +class Trender15 : public Trender16 +{ +public: + virtual int MakeColor(int r, int g, int b); + virtual bool GetColor(int c, int &r, int &g, int &b); +}; + +class Trender51 : public Trender16 +{ +public: + virtual int MakeColor(int r, int g, int b); + virtual bool GetColor(int c, int &r, int &g, int &b); +}; + +extern Trender32 render32; +extern Trender16 render16; +extern Trender15 render15; +extern Trender51 render51; + + +} //end namespace + +#endif diff --git a/src/softrender_config.h b/src/softrender_config.h new file mode 100644 index 000000000..1e6c43189 --- /dev/null +++ b/src/softrender_config.h @@ -0,0 +1,14 @@ +#ifndef SOFTRENDER_CONFIG_H +#define SOFTRENDER_CONFIG_H + +namespace softrender { + +typedef unsigned char byte; +typedef unsigned short word; +typedef unsigned int quad; + + + +} + +#endif diff --git a/src/softrender_desmumefont.h b/src/softrender_desmumefont.h new file mode 100644 index 000000000..a6eb8f2d8 --- /dev/null +++ b/src/softrender_desmumefont.h @@ -0,0 +1,574 @@ +/* Copyright (C) 2006 yopyop + yopyop156@ifrance.com + yopyop156.ifrance.com + + Copyright (C) 2006-2008 DeSmuME team + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#ifndef SYSFONT_DESMUME_H +#define SYSFONT_DESMUME_H + +#define OSD_FONT_WIDTH 8 +#define OSD_FONT_HEIGHT 16 + +namespace softrender { + + class DesmumeFont { + public: + static int height() { return OSD_FONT_HEIGHT; } + static int width(char c) { return OSD_FONT_WIDTH; } + static bool valid(char c) { return true; } + static bool haveContour() { return true; } + + static int pixel(char c, int x, int y) { + + static const unsigned char font_eng[256*OSD_FONT_HEIGHT] = + { + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 00 */ + 0x00,0x00,0x7E,0x81,0xA5,0x81,0x81,0xBD,0x99,0x81,0x81,0x7E,0x00,0x00,0x00,0x00, /* 01 */ + 0x00,0x00,0x7E,0xFF,0xDB,0xFF,0xFF,0xC3,0xE7,0xFF,0xFF,0x7E,0x00,0x00,0x00,0x00, /* 02 */ + 0x00,0x00,0x00,0x00,0x6C,0xFE,0xFE,0xFE,0xFE,0x7C,0x38,0x10,0x00,0x00,0x00,0x00, /* 03 */ + 0x00,0x00,0x00,0x00,0x10,0x38,0x7C,0xFE,0x7C,0x38,0x10,0x00,0x00,0x00,0x00,0x00, /* 04 */ + 0x00,0x00,0x00,0x18,0x3C,0x3C,0xE7,0xE7,0xE7,0x18,0x18,0x3C,0x00,0x00,0x00,0x00, /* 05 */ + 0x00,0x00,0x00,0x18,0x3C,0x7E,0xFF,0xFF,0x7E,0x18,0x18,0x3C,0x00,0x00,0x00,0x00, /* 06 */ + 0x00,0x00,0x00,0x00,0x00,0x00,0x18,0x3C,0x3C,0x18,0x00,0x00,0x00,0x00,0x00,0x00, /* 07 */ + 0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xE7,0xC3,0xC3,0xE7,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF, /* 08 */ + 0x00,0x00,0x00,0x00,0x00,0x3C,0x66,0x42,0x42,0x66,0x3C,0x00,0x00,0x00,0x00,0x00, /* 09 */ + 0xFF,0xFF,0xFF,0xFF,0xFF,0xC3,0x99,0xBD,0xBD,0x99,0xC3,0xFF,0xFF,0xFF,0xFF,0xFF, /* 0A */ + 0x00,0x00,0x1E,0x0E,0x1A,0x32,0x78,0xCC,0xCC,0xCC,0xCC,0x78,0x00,0x00,0x00,0x00, /* 0B */ + 0x00,0x00,0x3C,0x66,0x66,0x66,0x66,0x3C,0x18,0x7E,0x18,0x18,0x00,0x00,0x00,0x00, /* 0C */ + 0x00,0x00,0x3F,0x33,0x3F,0x30,0x30,0x30,0x30,0x70,0xF0,0xE0,0x00,0x00,0x00,0x00, /* 0D */ + 0x00,0x00,0x7F,0x63,0x7F,0x63,0x63,0x63,0x63,0x67,0xE7,0xE6,0xC0,0x00,0x00,0x00, /* 0E */ + 0x00,0x00,0x00,0x18,0x18,0xDB,0x3C,0xE7,0x3C,0xDB,0x18,0x18,0x00,0x00,0x00,0x00, /* 0F */ + 0x00,0x80,0xC0,0xE0,0xF0,0xF8,0xFE,0xF8,0xF0,0xE0,0xC0,0x80,0x00,0x00,0x00,0x00, /* 10 */ + 0x00,0x02,0x06,0x0E,0x1E,0x3E,0xFE,0x3E,0x1E,0x0E,0x06,0x02,0x00,0x00,0x00,0x00, /* 11 */ + 0x00,0x00,0x18,0x3C,0x7E,0x18,0x18,0x18,0x7E,0x3C,0x18,0x00,0x00,0x00,0x00,0x00, /* 12 */ + 0x00,0x00,0x66,0x66,0x66,0x66,0x66,0x66,0x66,0x00,0x66,0x66,0x00,0x00,0x00,0x00, /* 13 */ + 0x00,0x00,0x7F,0xDB,0xDB,0xDB,0x7B,0x1B,0x1B,0x1B,0x1B,0x1B,0x00,0x00,0x00,0x00, /* 14 */ + 0x00,0x7C,0xC6,0x60,0x38,0x6C,0xC6,0xC6,0x6C,0x38,0x0C,0xC6,0x7C,0x00,0x00,0x00, /* 15 */ + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xFE,0xFE,0xFE,0xFE,0x00,0x00,0x00,0x00, /* 16 */ + 0x00,0x00,0x18,0x3C,0x7E,0x18,0x18,0x18,0x7E,0x3C,0x18,0x7E,0x00,0x00,0x00,0x00, /* 17 */ + 0x00,0x00,0x18,0x3C,0x7E,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x00,0x00,0x00,0x00, /* 18 */ + 0x00,0x00,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x7E,0x3C,0x18,0x00,0x00,0x00,0x00, /* 19 */ + 0x00,0x00,0x00,0x00,0x00,0x18,0x0C,0xFE,0x0C,0x18,0x00,0x00,0x00,0x00,0x00,0x00, /* 1A */ + 0x00,0x00,0x00,0x00,0x00,0x30,0x60,0xFE,0x60,0x30,0x00,0x00,0x00,0x00,0x00,0x00, /* 1B */ + 0x00,0x00,0x00,0x00,0x00,0x00,0xC0,0xC0,0xC0,0xFE,0x00,0x00,0x00,0x00,0x00,0x00, /* 1C */ + 0x00,0x00,0x00,0x00,0x00,0x24,0x66,0xFF,0x66,0x24,0x00,0x00,0x00,0x00,0x00,0x00, /* 1D */ + 0x00,0x00,0x00,0x00,0x10,0x38,0x38,0x7C,0x7C,0xFE,0xFE,0x00,0x00,0x00,0x00,0x00, /* 1E */ + 0x00,0x00,0x00,0x00,0xFE,0xFE,0x7C,0x7C,0x38,0x38,0x10,0x00,0x00,0x00,0x00,0x00, /* 1F */ + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 20 */ + 0x00,0x00,0x18,0x3C,0x3C,0x3C,0x18,0x18,0x18,0x00,0x18,0x18,0x00,0x00,0x00,0x00, /* 21 */ + 0x00,0x66,0x66,0x66,0x24,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 22 */ + 0x00,0x00,0x00,0x6C,0x6C,0xFE,0x6C,0x6C,0x6C,0xFE,0x6C,0x6C,0x00,0x00,0x00,0x00, /* 23 */ + 0x18,0x18,0x7C,0xC6,0xC2,0xC0,0x7C,0x06,0x06,0x86,0xC6,0x7C,0x18,0x18,0x00,0x00, /* 24 */ + 0x00,0x00,0x00,0x00,0xC2,0xC6,0x0C,0x18,0x30,0x60,0xC6,0x86,0x00,0x00,0x00,0x00, /* 25 */ + 0x00,0x00,0x38,0x6C,0x6C,0x38,0x76,0xDC,0xCC,0xCC,0xCC,0x76,0x00,0x00,0x00,0x00, /* 26 */ + 0x00,0x30,0x30,0x30,0x60,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 27 */ + 0x00,0x00,0x0C,0x18,0x30,0x30,0x30,0x30,0x30,0x30,0x18,0x0C,0x00,0x00,0x00,0x00, /* 28 */ + 0x00,0x00,0x30,0x18,0x0C,0x0C,0x0C,0x0C,0x0C,0x0C,0x18,0x30,0x00,0x00,0x00,0x00, /* 29 */ + 0x00,0x00,0x00,0x00,0x00,0x66,0x3C,0xFF,0x3C,0x66,0x00,0x00,0x00,0x00,0x00,0x00, /* 2A */ + 0x00,0x00,0x00,0x00,0x00,0x18,0x18,0x7E,0x18,0x18,0x00,0x00,0x00,0x00,0x00,0x00, /* 2B */ + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x18,0x18,0x18,0x30,0x00,0x00,0x00, /* 2C */ + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xFE,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 2D */ + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x18,0x18,0x00,0x00,0x00,0x00, /* 2E */ + 0x00,0x00,0x00,0x00,0x02,0x06,0x0C,0x18,0x30,0x60,0xC0,0x80,0x00,0x00,0x00,0x00, /* 2F */ + 0x00,0x00,0x3C,0x66,0xC3,0xC3,0xDB,0xDB,0xC3,0xC3,0x66,0x3C,0x00,0x00,0x00,0x00, /* 30 */ + 0x00,0x00,0x18,0x38,0x78,0x18,0x18,0x18,0x18,0x18,0x18,0x7E,0x00,0x00,0x00,0x00, /* 31 */ + 0x00,0x00,0x7C,0xC6,0x06,0x0C,0x18,0x30,0x60,0xC0,0xC6,0xFE,0x00,0x00,0x00,0x00, /* 32 */ + 0x00,0x00,0x7C,0xC6,0x06,0x06,0x3C,0x06,0x06,0x06,0xC6,0x7C,0x00,0x00,0x00,0x00, /* 33 */ + 0x00,0x00,0x0C,0x1C,0x3C,0x6C,0xCC,0xFE,0x0C,0x0C,0x0C,0x1E,0x00,0x00,0x00,0x00, /* 34 */ + 0x00,0x00,0xFE,0xC0,0xC0,0xC0,0xFC,0x06,0x06,0x06,0xC6,0x7C,0x00,0x00,0x00,0x00, /* 35 */ + 0x00,0x00,0x38,0x60,0xC0,0xC0,0xFC,0xC6,0xC6,0xC6,0xC6,0x7C,0x00,0x00,0x00,0x00, /* 36 */ + 0x00,0x00,0xFE,0xC6,0x06,0x06,0x0C,0x18,0x30,0x30,0x30,0x30,0x00,0x00,0x00,0x00, /* 37 */ + 0x00,0x00,0x7C,0xC6,0xC6,0xC6,0x7C,0xC6,0xC6,0xC6,0xC6,0x7C,0x00,0x00,0x00,0x00, /* 38 */ + 0x00,0x00,0x7C,0xC6,0xC6,0xC6,0x7E,0x06,0x06,0x06,0x0C,0x78,0x00,0x00,0x00,0x00, /* 39 */ + 0x00,0x00,0x00,0x00,0x18,0x18,0x00,0x00,0x00,0x18,0x18,0x00,0x00,0x00,0x00,0x00, /* 3A */ + 0x00,0x00,0x00,0x00,0x18,0x18,0x00,0x00,0x00,0x18,0x18,0x30,0x00,0x00,0x00,0x00, /* 3B */ + 0x00,0x00,0x00,0x06,0x0C,0x18,0x30,0x60,0x30,0x18,0x0C,0x06,0x00,0x00,0x00,0x00, /* 3C */ + 0x00,0x00,0x00,0x00,0x00,0x7E,0x00,0x00,0x7E,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 3D */ + 0x00,0x00,0x00,0x60,0x30,0x18,0x0C,0x06,0x0C,0x18,0x30,0x60,0x00,0x00,0x00,0x00, /* 3E */ + 0x00,0x00,0x7C,0xC6,0xC6,0x0C,0x18,0x18,0x18,0x00,0x18,0x18,0x00,0x00,0x00,0x00, /* 3F */ + 0x00,0x00,0x00,0x7C,0xC6,0xC6,0xDE,0xDE,0xDE,0xDC,0xC0,0x7C,0x00,0x00,0x00,0x00, /* 40 */ + 0x00,0x00,0x10,0x38,0x6C,0xC6,0xC6,0xFE,0xC6,0xC6,0xC6,0xC6,0x00,0x00,0x00,0x00, /* 41 */ + 0x00,0x00,0xFC,0x66,0x66,0x66,0x7C,0x66,0x66,0x66,0x66,0xFC,0x00,0x00,0x00,0x00, /* 42 */ + 0x00,0x00,0x3C,0x66,0xC2,0xC0,0xC0,0xC0,0xC0,0xC2,0x66,0x3C,0x00,0x00,0x00,0x00, /* 43 */ + 0x00,0x00,0xF8,0x6C,0x66,0x66,0x66,0x66,0x66,0x66,0x6C,0xF8,0x00,0x00,0x00,0x00, /* 44 */ + 0x00,0x00,0xFE,0x66,0x62,0x68,0x78,0x68,0x60,0x62,0x66,0xFE,0x00,0x00,0x00,0x00, /* 45 */ + 0x00,0x00,0xFE,0x66,0x62,0x68,0x78,0x68,0x60,0x60,0x60,0xF0,0x00,0x00,0x00,0x00, /* 46 */ + 0x00,0x00,0x3C,0x66,0xC2,0xC0,0xC0,0xDE,0xC6,0xC6,0x66,0x3A,0x00,0x00,0x00,0x00, /* 47 */ + 0x00,0x00,0xC6,0xC6,0xC6,0xC6,0xFE,0xC6,0xC6,0xC6,0xC6,0xC6,0x00,0x00,0x00,0x00, /* 48 */ + 0x00,0x00,0x3C,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x3C,0x00,0x00,0x00,0x00, /* 49 */ + 0x00,0x00,0x1E,0x0C,0x0C,0x0C,0x0C,0x0C,0xCC,0xCC,0xCC,0x78,0x00,0x00,0x00,0x00, /* 4A */ + 0x00,0x00,0xE6,0x66,0x66,0x6C,0x78,0x78,0x6C,0x66,0x66,0xE6,0x00,0x00,0x00,0x00, /* 4B */ + 0x00,0x00,0xF0,0x60,0x60,0x60,0x60,0x60,0x60,0x62,0x66,0xFE,0x00,0x00,0x00,0x00, /* 4C */ + 0x00,0x00,0xC3,0xE7,0xFF,0xFF,0xDB,0xC3,0xC3,0xC3,0xC3,0xC3,0x00,0x00,0x00,0x00, /* 4D */ + 0x00,0x00,0xC6,0xE6,0xF6,0xFE,0xDE,0xCE,0xC6,0xC6,0xC6,0xC6,0x00,0x00,0x00,0x00, /* 4E */ + 0x00,0x00,0x7C,0xC6,0xC6,0xC6,0xC6,0xC6,0xC6,0xC6,0xC6,0x7C,0x00,0x00,0x00,0x00, /* 4F */ + 0x00,0x00,0xFC,0x66,0x66,0x66,0x7C,0x60,0x60,0x60,0x60,0xF0,0x00,0x00,0x00,0x00, /* 50 */ + 0x00,0x00,0x7C,0xC6,0xC6,0xC6,0xC6,0xC6,0xC6,0xD6,0xDE,0x7C,0x0C,0x0E,0x00,0x00, /* 51 */ + 0x00,0x00,0xFC,0x66,0x66,0x66,0x7C,0x6C,0x66,0x66,0x66,0xE6,0x00,0x00,0x00,0x00, /* 52 */ + 0x00,0x00,0x7C,0xC6,0xC6,0x60,0x38,0x0C,0x06,0xC6,0xC6,0x7C,0x00,0x00,0x00,0x00, /* 53 */ + 0x00,0x00,0xFF,0xDB,0x99,0x18,0x18,0x18,0x18,0x18,0x18,0x3C,0x00,0x00,0x00,0x00, /* 54 */ + 0x00,0x00,0xC6,0xC6,0xC6,0xC6,0xC6,0xC6,0xC6,0xC6,0xC6,0x7C,0x00,0x00,0x00,0x00, /* 55 */ + 0x00,0x00,0xC3,0xC3,0xC3,0xC3,0xC3,0xC3,0xC3,0x66,0x3C,0x18,0x00,0x00,0x00,0x00, /* 56 */ + 0x00,0x00,0xC3,0xC3,0xC3,0xC3,0xC3,0xDB,0xDB,0xFF,0x66,0x66,0x00,0x00,0x00,0x00, /* 57 */ + 0x00,0x00,0xC3,0xC3,0x66,0x3C,0x18,0x18,0x3C,0x66,0xC3,0xC3,0x00,0x00,0x00,0x00, /* 58 */ + 0x00,0x00,0xC3,0xC3,0xC3,0x66,0x3C,0x18,0x18,0x18,0x18,0x3C,0x00,0x00,0x00,0x00, /* 59 */ + 0x00,0x00,0xFF,0xC3,0x86,0x0C,0x18,0x30,0x60,0xC1,0xC3,0xFF,0x00,0x00,0x00,0x00, /* 5A */ + 0x00,0x00,0x3C,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x3C,0x00,0x00,0x00,0x00, /* 5B */ + 0x00,0x00,0x00,0x80,0xC0,0xE0,0x70,0x38,0x1C,0x0E,0x06,0x02,0x00,0x00,0x00,0x00, /* 5C */ + 0x00,0x00,0x3C,0x0C,0x0C,0x0C,0x0C,0x0C,0x0C,0x0C,0x0C,0x3C,0x00,0x00,0x00,0x00, /* 5D */ + 0x10,0x38,0x6C,0xC6,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 5E */ + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xFF,0x00,0x00, /* 5F */ + 0x30,0x30,0x18,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 60 */ + 0x00,0x00,0x00,0x00,0x00,0x78,0x0C,0x7C,0xCC,0xCC,0xCC,0x76,0x00,0x00,0x00,0x00, /* 61 */ + 0x00,0x00,0xE0,0x60,0x60,0x78,0x6C,0x66,0x66,0x66,0x66,0x7C,0x00,0x00,0x00,0x00, /* 62 */ + 0x00,0x00,0x00,0x00,0x00,0x7C,0xC6,0xC0,0xC0,0xC0,0xC6,0x7C,0x00,0x00,0x00,0x00, /* 63 */ + 0x00,0x00,0x1C,0x0C,0x0C,0x3C,0x6C,0xCC,0xCC,0xCC,0xCC,0x76,0x00,0x00,0x00,0x00, /* 64 */ + 0x00,0x00,0x00,0x00,0x00,0x7C,0xC6,0xFE,0xC0,0xC0,0xC6,0x7C,0x00,0x00,0x00,0x00, /* 65 */ + 0x00,0x00,0x38,0x6C,0x64,0x60,0xF0,0x60,0x60,0x60,0x60,0xF0,0x00,0x00,0x00,0x00, /* 66 */ + 0x00,0x00,0x00,0x00,0x00,0x76,0xCC,0xCC,0xCC,0xCC,0xCC,0x7C,0x0C,0xCC,0x78,0x00, /* 67 */ + 0x00,0x00,0xE0,0x60,0x60,0x6C,0x76,0x66,0x66,0x66,0x66,0xE6,0x00,0x00,0x00,0x00, /* 68 */ + 0x00,0x00,0x18,0x18,0x00,0x38,0x18,0x18,0x18,0x18,0x18,0x3C,0x00,0x00,0x00,0x00, /* 69 */ + 0x00,0x00,0x06,0x06,0x00,0x0E,0x06,0x06,0x06,0x06,0x06,0x06,0x66,0x66,0x3C,0x00, /* 6A */ + 0x00,0x00,0xE0,0x60,0x60,0x66,0x6C,0x78,0x78,0x6C,0x66,0xE6,0x00,0x00,0x00,0x00, /* 6B */ + 0x00,0x00,0x38,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x3C,0x00,0x00,0x00,0x00, /* 6C */ + 0x00,0x00,0x00,0x00,0x00,0xE6,0xFF,0xDB,0xDB,0xDB,0xDB,0xDB,0x00,0x00,0x00,0x00, /* 6D */ + 0x00,0x00,0x00,0x00,0x00,0xDC,0x66,0x66,0x66,0x66,0x66,0x66,0x00,0x00,0x00,0x00, /* 6E */ + 0x00,0x00,0x00,0x00,0x00,0x7C,0xC6,0xC6,0xC6,0xC6,0xC6,0x7C,0x00,0x00,0x00,0x00, /* 6F */ + 0x00,0x00,0x00,0x00,0x00,0xDC,0x66,0x66,0x66,0x66,0x66,0x7C,0x60,0x60,0xF0,0x00, /* 70 */ + 0x00,0x00,0x00,0x00,0x00,0x76,0xCC,0xCC,0xCC,0xCC,0xCC,0x7C,0x0C,0x0C,0x1E,0x00, /* 71 */ + 0x00,0x00,0x00,0x00,0x00,0xDC,0x76,0x66,0x60,0x60,0x60,0xF0,0x00,0x00,0x00,0x00, /* 72 */ + 0x00,0x00,0x00,0x00,0x00,0x7C,0xC6,0x60,0x38,0x0C,0xC6,0x7C,0x00,0x00,0x00,0x00, /* 73 */ + 0x00,0x00,0x10,0x30,0x30,0xFC,0x30,0x30,0x30,0x30,0x36,0x1C,0x00,0x00,0x00,0x00, /* 74 */ + 0x00,0x00,0x00,0x00,0x00,0xCC,0xCC,0xCC,0xCC,0xCC,0xCC,0x76,0x00,0x00,0x00,0x00, /* 75 */ + 0x00,0x00,0x00,0x00,0x00,0xC3,0xC3,0xC3,0xC3,0x66,0x3C,0x18,0x00,0x00,0x00,0x00, /* 76 */ + 0x00,0x00,0x00,0x00,0x00,0xC3,0xC3,0xC3,0xDB,0xDB,0xFF,0x66,0x00,0x00,0x00,0x00, /* 77 */ + 0x00,0x00,0x00,0x00,0x00,0xC3,0x66,0x3C,0x18,0x3C,0x66,0xC3,0x00,0x00,0x00,0x00, /* 78 */ + 0x00,0x00,0x00,0x00,0x00,0xC6,0xC6,0xC6,0xC6,0xC6,0xC6,0x7E,0x06,0x0C,0xF8,0x00, /* 79 */ + 0x00,0x00,0x00,0x00,0x00,0xFE,0xCC,0x18,0x30,0x60,0xC6,0xFE,0x00,0x00,0x00,0x00, /* 7A */ + 0x00,0x00,0x0E,0x18,0x18,0x18,0x70,0x18,0x18,0x18,0x18,0x0E,0x00,0x00,0x00,0x00, /* 7B */ + 0x00,0x00,0x18,0x18,0x18,0x18,0x00,0x18,0x18,0x18,0x18,0x18,0x00,0x00,0x00,0x00, /* 7C */ + 0x00,0x00,0x70,0x18,0x18,0x18,0x0E,0x18,0x18,0x18,0x18,0x70,0x00,0x00,0x00,0x00, /* 7D */ + 0x00,0x00,0x76,0xDC,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 7E */ + 0x00,0x00,0x00,0x00,0x10,0x38,0x6C,0xC6,0xC6,0xC6,0xFE,0x00,0x00,0x00,0x00,0x00, /* 7F */ + 0x00,0x00,0x3C,0x66,0xC2,0xC0,0xC0,0xC0,0xC2,0x66,0x3C,0x0C,0x06,0x7C,0x00,0x00, /* 80 */ + 0x00,0x00,0xCC,0x00,0x00,0xCC,0xCC,0xCC,0xCC,0xCC,0xCC,0x76,0x00,0x00,0x00,0x00, /* 81 */ + 0x00,0x0C,0x18,0x30,0x00,0x7C,0xC6,0xFE,0xC0,0xC0,0xC6,0x7C,0x00,0x00,0x00,0x00, /* 82 */ + 0x00,0x10,0x38,0x6C,0x00,0x78,0x0C,0x7C,0xCC,0xCC,0xCC,0x76,0x00,0x00,0x00,0x00, /* 83 */ + 0x00,0x00,0xCC,0x00,0x00,0x78,0x0C,0x7C,0xCC,0xCC,0xCC,0x76,0x00,0x00,0x00,0x00, /* 84 */ + 0x00,0x60,0x30,0x18,0x00,0x78,0x0C,0x7C,0xCC,0xCC,0xCC,0x76,0x00,0x00,0x00,0x00, /* 85 */ + 0x00,0x38,0x6C,0x38,0x00,0x78,0x0C,0x7C,0xCC,0xCC,0xCC,0x76,0x00,0x00,0x00,0x00, /* 86 */ + 0x00,0x00,0x00,0x00,0x3C,0x66,0x60,0x60,0x66,0x3C,0x0C,0x06,0x3C,0x00,0x00,0x00, /* 87 */ + 0x00,0x10,0x38,0x6C,0x00,0x7C,0xC6,0xFE,0xC0,0xC0,0xC6,0x7C,0x00,0x00,0x00,0x00, /* 88 */ + 0x00,0x00,0xC6,0x00,0x00,0x7C,0xC6,0xFE,0xC0,0xC0,0xC6,0x7C,0x00,0x00,0x00,0x00, /* 89 */ + 0x00,0x60,0x30,0x18,0x00,0x7C,0xC6,0xFE,0xC0,0xC0,0xC6,0x7C,0x00,0x00,0x00,0x00, /* 8A */ + 0x00,0x00,0x66,0x00,0x00,0x38,0x18,0x18,0x18,0x18,0x18,0x3C,0x00,0x00,0x00,0x00, /* 8B */ + 0x00,0x18,0x3C,0x66,0x00,0x38,0x18,0x18,0x18,0x18,0x18,0x3C,0x00,0x00,0x00,0x00, /* 8C */ + 0x00,0x60,0x30,0x18,0x00,0x38,0x18,0x18,0x18,0x18,0x18,0x3C,0x00,0x00,0x00,0x00, /* 8D */ + 0x00,0xC6,0x00,0x10,0x38,0x6C,0xC6,0xC6,0xFE,0xC6,0xC6,0xC6,0x00,0x00,0x00,0x00, /* 8E */ + 0x38,0x6C,0x38,0x00,0x38,0x6C,0xC6,0xC6,0xFE,0xC6,0xC6,0xC6,0x00,0x00,0x00,0x00, /* 8F */ + 0x18,0x30,0x60,0x00,0xFE,0x66,0x60,0x7C,0x60,0x60,0x66,0xFE,0x00,0x00,0x00,0x00, /* 90 */ + 0x00,0x00,0x00,0x00,0x00,0x6E,0x3B,0x1B,0x7E,0xD8,0xDC,0x77,0x00,0x00,0x00,0x00, /* 91 */ + 0x00,0x00,0x3E,0x6C,0xCC,0xCC,0xFE,0xCC,0xCC,0xCC,0xCC,0xCE,0x00,0x00,0x00,0x00, /* 92 */ + 0x00,0x10,0x38,0x6C,0x00,0x7C,0xC6,0xC6,0xC6,0xC6,0xC6,0x7C,0x00,0x00,0x00,0x00, /* 93 */ + 0x00,0x00,0xC6,0x00,0x00,0x7C,0xC6,0xC6,0xC6,0xC6,0xC6,0x7C,0x00,0x00,0x00,0x00, /* 94 */ + 0x00,0x60,0x30,0x18,0x00,0x7C,0xC6,0xC6,0xC6,0xC6,0xC6,0x7C,0x00,0x00,0x00,0x00, /* 95 */ + 0x00,0x30,0x78,0xCC,0x00,0xCC,0xCC,0xCC,0xCC,0xCC,0xCC,0x76,0x00,0x00,0x00,0x00, /* 96 */ + 0x00,0x60,0x30,0x18,0x00,0xCC,0xCC,0xCC,0xCC,0xCC,0xCC,0x76,0x00,0x00,0x00,0x00, /* 97 */ + 0x00,0x00,0xC6,0x00,0x00,0xC6,0xC6,0xC6,0xC6,0xC6,0xC6,0x7E,0x06,0x0C,0x78,0x00, /* 98 */ + 0x00,0xC6,0x00,0x7C,0xC6,0xC6,0xC6,0xC6,0xC6,0xC6,0xC6,0x7C,0x00,0x00,0x00,0x00, /* 99 */ + 0x00,0xC6,0x00,0xC6,0xC6,0xC6,0xC6,0xC6,0xC6,0xC6,0xC6,0x7C,0x00,0x00,0x00,0x00, /* 9A */ + 0x00,0x18,0x18,0x7E,0xC3,0xC0,0xC0,0xC0,0xC3,0x7E,0x18,0x18,0x00,0x00,0x00,0x00, /* 9B */ + 0x00,0x38,0x6C,0x64,0x60,0xF0,0x60,0x60,0x60,0x60,0xE6,0xFC,0x00,0x00,0x00,0x00, /* 9C */ + 0x00,0x00,0xC3,0x66,0x3C,0x18,0xFF,0x18,0xFF,0x18,0x18,0x18,0x00,0x00,0x00,0x00, /* 9D */ + 0x00,0xFC,0x66,0x66,0x7C,0x62,0x66,0x6F,0x66,0x66,0x66,0xF3,0x00,0x00,0x00,0x00, /* 9E */ + 0x00,0x0E,0x1B,0x18,0x18,0x18,0x7E,0x18,0x18,0x18,0x18,0x18,0xD8,0x70,0x00,0x00, /* 9F */ + 0x00,0x18,0x30,0x60,0x00,0x78,0x0C,0x7C,0xCC,0xCC,0xCC,0x76,0x00,0x00,0x00,0x00, /* A0 */ + 0x00,0x0C,0x18,0x30,0x00,0x38,0x18,0x18,0x18,0x18,0x18,0x3C,0x00,0x00,0x00,0x00, /* A1 */ + 0x00,0x18,0x30,0x60,0x00,0x7C,0xC6,0xC6,0xC6,0xC6,0xC6,0x7C,0x00,0x00,0x00,0x00, /* A2 */ + 0x00,0x18,0x30,0x60,0x00,0xCC,0xCC,0xCC,0xCC,0xCC,0xCC,0x76,0x00,0x00,0x00,0x00, /* A3 */ + 0x00,0x00,0x76,0xDC,0x00,0xDC,0x66,0x66,0x66,0x66,0x66,0x66,0x00,0x00,0x00,0x00, /* A4 */ + 0x76,0xDC,0x00,0xC6,0xE6,0xF6,0xFE,0xDE,0xCE,0xC6,0xC6,0xC6,0x00,0x00,0x00,0x00, /* A5 */ + 0x00,0x3C,0x6C,0x6C,0x3E,0x00,0x7E,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* A6 */ + 0x00,0x38,0x6C,0x6C,0x38,0x00,0x7C,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* A7 */ + 0x00,0x00,0x30,0x30,0x00,0x30,0x30,0x60,0xC0,0xC6,0xC6,0x7C,0x00,0x00,0x00,0x00, /* A8 */ + 0x00,0x00,0x00,0x00,0x00,0x00,0xFE,0xC0,0xC0,0xC0,0xC0,0x00,0x00,0x00,0x00,0x00, /* A9 */ + 0x00,0x00,0x00,0x00,0x00,0x00,0xFE,0x06,0x06,0x06,0x06,0x00,0x00,0x00,0x00,0x00, /* AA */ + 0x00,0xC0,0xC0,0xC2,0xC6,0xCC,0x18,0x30,0x60,0xCE,0x9B,0x06,0x0C,0x1F,0x00,0x00, /* AB */ + 0x00,0xC0,0xC0,0xC2,0xC6,0xCC,0x18,0x30,0x66,0xCE,0x96,0x3E,0x06,0x06,0x00,0x00, /* AC */ + 0x00,0x00,0x18,0x18,0x00,0x18,0x18,0x18,0x3C,0x3C,0x3C,0x18,0x00,0x00,0x00,0x00, /* AD */ + 0x00,0x00,0x00,0x00,0x00,0x36,0x6C,0xD8,0x6C,0x36,0x00,0x00,0x00,0x00,0x00,0x00, /* AE */ + 0x00,0x00,0x00,0x00,0x00,0xD8,0x6C,0x36,0x6C,0xD8,0x00,0x00,0x00,0x00,0x00,0x00, /* AF */ + 0x11,0x44,0x11,0x44,0x11,0x44,0x11,0x44,0x11,0x44,0x11,0x44,0x11,0x44,0x11,0x44, /* B0 */ + 0x55,0xAA,0x55,0xAA,0x55,0xAA,0x55,0xAA,0x55,0xAA,0x55,0xAA,0x55,0xAA,0x55,0xAA, /* B1 */ + 0xDD,0x77,0xDD,0x77,0xDD,0x77,0xDD,0x77,0xDD,0x77,0xDD,0x77,0xDD,0x77,0xDD,0x77, /* B2 */ + 0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18, /* B3 */ + 0x18,0x18,0x18,0x18,0x18,0x18,0x18,0xF8,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18, /* B4 */ + 0x18,0x18,0x18,0x18,0x18,0xF8,0x18,0xF8,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18, /* B5 */ + 0x36,0x36,0x36,0x36,0x36,0x36,0x36,0xF6,0x36,0x36,0x36,0x36,0x36,0x36,0x36,0x36, /* B6 */ + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xFE,0x36,0x36,0x36,0x36,0x36,0x36,0x36,0x36, /* B7 */ + 0x00,0x00,0x00,0x00,0x00,0xF8,0x18,0xF8,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18, /* B8 */ + 0x36,0x36,0x36,0x36,0x36,0xF6,0x06,0xF6,0x36,0x36,0x36,0x36,0x36,0x36,0x36,0x36, /* B9 */ + 0x36,0x36,0x36,0x36,0x36,0x36,0x36,0x36,0x36,0x36,0x36,0x36,0x36,0x36,0x36,0x36, /* BA */ + 0x00,0x00,0x00,0x00,0x00,0xFE,0x06,0xF6,0x36,0x36,0x36,0x36,0x36,0x36,0x36,0x36, /* BB */ + 0x36,0x36,0x36,0x36,0x36,0xF6,0x06,0xFE,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* BC */ + 0x36,0x36,0x36,0x36,0x36,0x36,0x36,0xFE,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* BD */ + 0x18,0x18,0x18,0x18,0x18,0xF8,0x18,0xF8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* BE */ + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xF8,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18, /* BF */ + 0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x1F,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* C0 */ + 0x18,0x18,0x18,0x18,0x18,0x18,0x18,0xFF,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* C1 */ + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xFF,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18, /* C2 */ + 0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x1F,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18, /* C3 */ + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xFF,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* C4 */ + 0x18,0x18,0x18,0x18,0x18,0x18,0x18,0xFF,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18, /* C5 */ + 0x18,0x18,0x18,0x18,0x18,0x1F,0x18,0x1F,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18, /* C6 */ + 0x36,0x36,0x36,0x36,0x36,0x36,0x36,0x37,0x36,0x36,0x36,0x36,0x36,0x36,0x36,0x36, /* C7 */ + 0x36,0x36,0x36,0x36,0x36,0x37,0x30,0x3F,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* C8 */ + 0x00,0x00,0x00,0x00,0x00,0x3F,0x30,0x37,0x36,0x36,0x36,0x36,0x36,0x36,0x36,0x36, /* C9 */ + 0x36,0x36,0x36,0x36,0x36,0xF7,0x00,0xFF,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* CA */ + 0x00,0x00,0x00,0x00,0x00,0xFF,0x00,0xF7,0x36,0x36,0x36,0x36,0x36,0x36,0x36,0x36, /* CB */ + 0x36,0x36,0x36,0x36,0x36,0x37,0x30,0x37,0x36,0x36,0x36,0x36,0x36,0x36,0x36,0x36, /* CC */ + 0x00,0x00,0x00,0x00,0x00,0xFF,0x00,0xFF,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* CD */ + 0x36,0x36,0x36,0x36,0x36,0xF7,0x00,0xF7,0x36,0x36,0x36,0x36,0x36,0x36,0x36,0x36, /* CE */ + 0x18,0x18,0x18,0x18,0x18,0xFF,0x00,0xFF,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* CF */ + 0x36,0x36,0x36,0x36,0x36,0x36,0x36,0xFF,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* D0 */ + 0x00,0x00,0x00,0x00,0x00,0xFF,0x00,0xFF,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18, /* D1 */ + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xFF,0x36,0x36,0x36,0x36,0x36,0x36,0x36,0x36, /* D2 */ + 0x36,0x36,0x36,0x36,0x36,0x36,0x36,0x3F,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* D3 */ + 0x18,0x18,0x18,0x18,0x18,0x1F,0x18,0x1F,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* D4 */ + 0x00,0x00,0x00,0x00,0x00,0x1F,0x18,0x1F,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18, /* D5 */ + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3F,0x36,0x36,0x36,0x36,0x36,0x36,0x36,0x36, /* D6 */ + 0x36,0x36,0x36,0x36,0x36,0x36,0x36,0xFF,0x36,0x36,0x36,0x36,0x36,0x36,0x36,0x36, /* D7 */ + 0x18,0x18,0x18,0x18,0x18,0xFF,0x18,0xFF,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18, /* D8 */ + 0x18,0x18,0x18,0x18,0x18,0x18,0x18,0xF8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* D9 */ + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1F,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18, /* DA */ + 0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF, /* DB */ + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF, /* DC */ + 0xF0,0xF0,0xF0,0xF0,0xF0,0xF0,0xF0,0xF0,0xF0,0xF0,0xF0,0xF0,0xF0,0xF0,0xF0,0xF0, /* DD */ + 0x0F,0x0F,0x0F,0x0F,0x0F,0x0F,0x0F,0x0F,0x0F,0x0F,0x0F,0x0F,0x0F,0x0F,0x0F,0x0F, /* DE */ + 0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* DF */ + 0x00,0x00,0x00,0x00,0x00,0x76,0xDC,0xD8,0xD8,0xD8,0xDC,0x76,0x00,0x00,0x00,0x00, /* E0 */ + 0x00,0x00,0x78,0xCC,0xCC,0xCC,0xD8,0xCC,0xC6,0xC6,0xC6,0xCC,0x00,0x00,0x00,0x00, /* E1 */ + 0x00,0x00,0xFE,0xC6,0xC6,0xC0,0xC0,0xC0,0xC0,0xC0,0xC0,0xC0,0x00,0x00,0x00,0x00, /* E2 */ + 0x00,0x00,0x00,0x00,0xFE,0x6C,0x6C,0x6C,0x6C,0x6C,0x6C,0x6C,0x00,0x00,0x00,0x00, /* E3 */ + 0x00,0x00,0x00,0xFE,0xC6,0x60,0x30,0x18,0x30,0x60,0xC6,0xFE,0x00,0x00,0x00,0x00, /* E4 */ + 0x00,0x00,0x00,0x00,0x00,0x7E,0xD8,0xD8,0xD8,0xD8,0xD8,0x70,0x00,0x00,0x00,0x00, /* E5 */ + 0x00,0x00,0x00,0x00,0x66,0x66,0x66,0x66,0x66,0x7C,0x60,0x60,0xC0,0x00,0x00,0x00, /* E6 */ + 0x00,0x00,0x00,0x00,0x76,0xDC,0x18,0x18,0x18,0x18,0x18,0x18,0x00,0x00,0x00,0x00, /* E7 */ + 0x00,0x00,0x00,0x7E,0x18,0x3C,0x66,0x66,0x66,0x3C,0x18,0x7E,0x00,0x00,0x00,0x00, /* E8 */ + 0x00,0x00,0x00,0x38,0x6C,0xC6,0xC6,0xFE,0xC6,0xC6,0x6C,0x38,0x00,0x00,0x00,0x00, /* E9 */ + 0x00,0x00,0x38,0x6C,0xC6,0xC6,0xC6,0x6C,0x6C,0x6C,0x6C,0xEE,0x00,0x00,0x00,0x00, /* EA */ + 0x00,0x00,0x1E,0x30,0x18,0x0C,0x3E,0x66,0x66,0x66,0x66,0x3C,0x00,0x00,0x00,0x00, /* EB */ + 0x00,0x00,0x00,0x00,0x00,0x7E,0xDB,0xDB,0xDB,0x7E,0x00,0x00,0x00,0x00,0x00,0x00, /* EC */ + 0x00,0x00,0x00,0x03,0x06,0x7E,0xDB,0xDB,0xF3,0x7E,0x60,0xC0,0x00,0x00,0x00,0x00, /* ED */ + 0x00,0x00,0x1C,0x30,0x60,0x60,0x7C,0x60,0x60,0x60,0x30,0x1C,0x00,0x00,0x00,0x00, /* EE */ + 0x00,0x00,0x00,0x7C,0xC6,0xC6,0xC6,0xC6,0xC6,0xC6,0xC6,0xC6,0x00,0x00,0x00,0x00, /* EF */ + 0x00,0x00,0x00,0x00,0xFE,0x00,0x00,0xFE,0x00,0x00,0xFE,0x00,0x00,0x00,0x00,0x00, /* F0 */ + 0x00,0x00,0x00,0x00,0x18,0x18,0x7E,0x18,0x18,0x00,0x00,0xFF,0x00,0x00,0x00,0x00, /* F1 */ + 0x00,0x00,0x00,0x30,0x18,0x0C,0x06,0x0C,0x18,0x30,0x00,0x7E,0x00,0x00,0x00,0x00, /* F2 */ + 0x00,0x00,0x00,0x0C,0x18,0x30,0x60,0x30,0x18,0x0C,0x00,0x7E,0x00,0x00,0x00,0x00, /* F3 */ + 0x00,0x00,0x0E,0x1B,0x1B,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18, /* F4 */ + 0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18,0xD8,0xD8,0xD8,0x70,0x00,0x00,0x00,0x00, /* F5 */ + 0x00,0x00,0x00,0x00,0x18,0x18,0x00,0x7E,0x00,0x18,0x18,0x00,0x00,0x00,0x00,0x00, /* F6 */ + 0x00,0x00,0x00,0x00,0x00,0x76,0xDC,0x00,0x76,0xDC,0x00,0x00,0x00,0x00,0x00,0x00, /* F7 */ + 0x00,0x38,0x6C,0x6C,0x38,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* F8 */ + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x18,0x18,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* F9 */ + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x18,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* FA */ + 0x00,0x0F,0x0C,0x0C,0x0C,0x0C,0x0C,0xEC,0x6C,0x6C,0x3C,0x1C,0x00,0x00,0x00,0x00, /* FB */ + 0x00,0xD8,0x6C,0x6C,0x6C,0x6C,0x6C,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* FC */ + 0x00,0x70,0xD8,0x30,0x60,0xC8,0xF8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* FD */ + 0x00,0x00,0x00,0x00,0x7C,0x7C,0x7C,0x7C,0x7C,0x7C,0x7C,0x00,0x00,0x00,0x00,0x00, /* FE */ + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00 /* FF */ + }; + + return (font_eng[(int)c*OSD_FONT_HEIGHT + y] >> (7-x))&1; + } //pixel() + + static int contour(char c, int x, int y) { + + static const u16 font_eng_contour[256*(OSD_FONT_HEIGHT+2)] = + { +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 00 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 01 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 02 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 03 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 04 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 05 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 06 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 07 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 08 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 09 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 0A */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 0B */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 0C */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 0D */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 0E */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 0F */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 10 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 11 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 12 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 13 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 14 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 15 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 16 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 17 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 18 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 19 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 1A */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 1B */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 1C */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 1D */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 1E */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 1F */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 20 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 21 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 22 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 23 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 24 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 25 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 26 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 27 */ +0x000,0x000,0x03C,0x064,0x0CC,0x198,0x198,0x198,0x198,0x198,0x198,0x0CC,0x064,0x03C,0x000,0x000,0x000,0x000, /* 28 */ +0x000,0x000,0x0F0,0x098,0x0CC,0x066,0x066,0x066,0x066,0x066,0x066,0x0CC,0x098,0x0F0,0x000,0x000,0x000,0x000, /* 29 */ +0x000,0x000,0x000,0x000,0x000,0x0CC,0x132,0x186,0x201,0x186,0x132,0x0CC,0x000,0x000,0x000,0x000,0x000,0x000, /* 2A */ +0x000,0x000,0x000,0x000,0x000,0x030,0x048,0x0CC,0x102,0x0CC,0x048,0x030,0x000,0x000,0x000,0x000,0x000,0x000, /* 2B */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x078,0x048,0x048,0x0C8,0x098,0x0F0,0x000,0x000,0x000, /* 2C */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x3FE,0x202,0x3FE,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 2D */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x030,0x048,0x048,0x030,0x000,0x000,0x000,0x000, /* 2E */ +0x000,0x000,0x000,0x000,0x00E,0x01A,0x032,0x066,0x0CC,0x198,0x330,0x260,0x2C0,0x380,0x000,0x000,0x000,0x000, /* 2F */ +0x000,0x000,0x0FC,0x186,0x333,0x249,0x279,0x201,0x201,0x279,0x249,0x333,0x186,0x0FC,0x000,0x000,0x000,0x000, /* 30 */ +0x000,0x000,0x078,0x0C8,0x188,0x308,0x3C8,0x048,0x048,0x048,0x048,0x1CE,0x102,0x1FE,0x000,0x000,0x000,0x000, /* 31 */ +0x000,0x000,0x1FC,0x304,0x272,0x3D2,0x024,0x048,0x090,0x120,0x25E,0x272,0x202,0x3FE,0x000,0x000,0x000,0x000, /* 32 */ +0x000,0x000,0x1FC,0x306,0x272,0x3D2,0x0F2,0x086,0x0F2,0x012,0x3D2,0x272,0x306,0x1FC,0x000,0x000,0x000,0x000, /* 33 */ +0x000,0x000,0x03C,0x064,0x0C4,0x184,0x324,0x266,0x202,0x3E6,0x024,0x066,0x042,0x07E,0x000,0x000,0x000,0x000, /* 34 */ +0x000,0x000,0x3FE,0x202,0x27E,0x240,0x27C,0x206,0x3F2,0x012,0x3D2,0x272,0x306,0x1FC,0x000,0x000,0x000,0x000, /* 35 */ +0x000,0x000,0x0F8,0x188,0x338,0x260,0x27C,0x206,0x272,0x252,0x252,0x272,0x306,0x1FC,0x000,0x000,0x000,0x000, /* 36 */ +0x000,0x000,0x3FE,0x202,0x272,0x3F2,0x032,0x064,0x0C8,0x090,0x090,0x090,0x090,0x0F0,0x000,0x000,0x000,0x000, /* 37 */ +0x000,0x000,0x1FC,0x306,0x272,0x252,0x272,0x306,0x272,0x252,0x252,0x272,0x306,0x1FC,0x000,0x000,0x000,0x000, /* 38 */ +0x000,0x000,0x1FC,0x306,0x272,0x252,0x272,0x302,0x1F2,0x012,0x012,0x1E6,0x10C,0x1F8,0x000,0x000,0x000,0x000, /* 39 */ +0x000,0x000,0x000,0x000,0x078,0x048,0x048,0x078,0x000,0x078,0x048,0x048,0x078,0x000,0x000,0x000,0x000,0x000, /* 3A */ +0x000,0x000,0x000,0x000,0x078,0x048,0x048,0x078,0x000,0x078,0x048,0x0C8,0x098,0x0F0,0x000,0x000,0x000,0x000, /* 3B */ +0x000,0x000,0x000,0x01E,0x012,0x024,0x048,0x090,0x120,0x090,0x048,0x024,0x012,0x01E,0x000,0x000,0x000,0x000, /* 3C */ +0x000,0x000,0x000,0x000,0x000,0x1FE,0x102,0x1FE,0x1FE,0x102,0x1FE,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 3D */ +0x000,0x000,0x000,0x1E0,0x120,0x090,0x048,0x024,0x012,0x024,0x048,0x090,0x120,0x1E0,0x000,0x000,0x000,0x000, /* 3E */ +0x000,0x000,0x1FC,0x306,0x272,0x272,0x3E6,0x04C,0x048,0x048,0x078,0x048,0x048,0x078,0x000,0x000,0x000,0x000, /* 3F */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 40 */ +0x000,0x000,0x070,0x0D8,0x18C,0x326,0x252,0x272,0x202,0x272,0x252,0x252,0x252,0x3DE,0x000,0x000,0x000,0x000, /* 41 */ +0x000,0x000,0x3FC,0x206,0x332,0x132,0x132,0x106,0x132,0x132,0x132,0x332,0x206,0x3FC,0x000,0x000,0x000,0x000, /* 42 */ +0x000,0x000,0x0FC,0x186,0x332,0x27A,0x24E,0x240,0x240,0x24E,0x27A,0x332,0x186,0x0FC,0x000,0x000,0x000,0x000, /* 43 */ +0x000,0x000,0x3F8,0x20C,0x326,0x132,0x132,0x132,0x132,0x132,0x132,0x326,0x20C,0x3F8,0x000,0x000,0x000,0x000, /* 44 */ +0x000,0x000,0x3FE,0x202,0x332,0x13A,0x12E,0x108,0x128,0x13E,0x13A,0x332,0x202,0x3FE,0x000,0x000,0x000,0x000, /* 45 */ +0x000,0x000,0x3FE,0x202,0x332,0x13A,0x12E,0x108,0x128,0x138,0x120,0x330,0x210,0x3F0,0x000,0x000,0x000,0x000, /* 46 */ +0x000,0x000,0x0FC,0x184,0x332,0x27A,0x24E,0x27E,0x242,0x272,0x252,0x332,0x18A,0x0FE,0x000,0x000,0x000,0x000, /* 47 */ +0x000,0x000,0x3DE,0x252,0x252,0x252,0x272,0x202,0x272,0x252,0x252,0x252,0x252,0x3DE,0x000,0x000,0x000,0x000, /* 48 */ +0x000,0x000,0x0FC,0x084,0x0CC,0x048,0x048,0x048,0x048,0x048,0x048,0x0CC,0x084,0x0FC,0x000,0x000,0x000,0x000, /* 49 */ +0x000,0x000,0x07E,0x042,0x066,0x024,0x024,0x024,0x3E4,0x264,0x264,0x264,0x30C,0x1F8,0x000,0x000,0x000,0x000, /* 4A */ +0x000,0x000,0x3FE,0x232,0x332,0x132,0x126,0x10C,0x10C,0x126,0x132,0x332,0x232,0x3FE,0x000,0x000,0x000,0x000, /* 4B */ +0x000,0x000,0x3F0,0x210,0x330,0x120,0x120,0x120,0x120,0x12E,0x13A,0x332,0x202,0x3FE,0x000,0x000,0x000,0x000, /* 4C */ +0x000,0x000,0x3CF,0x279,0x231,0x201,0x201,0x249,0x279,0x249,0x249,0x249,0x249,0x3CF,0x000,0x000,0x000,0x000, /* 4D */ +0x000,0x000,0x3DE,0x252,0x232,0x212,0x202,0x242,0x262,0x272,0x252,0x252,0x252,0x3DE,0x000,0x000,0x000,0x000, /* 4E */ +0x000,0x000,0x1FC,0x306,0x272,0x252,0x252,0x252,0x252,0x252,0x252,0x272,0x306,0x1FC,0x000,0x000,0x000,0x000, /* 4F */ +0x000,0x000,0x3FC,0x206,0x332,0x132,0x132,0x106,0x13C,0x120,0x120,0x330,0x210,0x3F0,0x000,0x000,0x000,0x000, /* 50 */ +0x000,0x000,0x1FC,0x306,0x272,0x252,0x252,0x252,0x252,0x272,0x252,0x242,0x306,0x1E6,0x022,0x03E,0x000,0x000, /* 51 */ +0x000,0x000,0x3FC,0x206,0x332,0x132,0x132,0x106,0x126,0x132,0x132,0x332,0x232,0x3FE,0x000,0x000,0x000,0x000, /* 52 */ +0x000,0x000,0x1FC,0x306,0x272,0x272,0x33E,0x18C,0x0E6,0x3F2,0x272,0x272,0x306,0x1FC,0x000,0x000,0x000,0x000, /* 53 */ +0x000,0x000,0x3FF,0x201,0x201,0x2CD,0x3CF,0x048,0x048,0x048,0x048,0x0CC,0x084,0x0FC,0x000,0x000,0x000,0x000, /* 54 */ +0x000,0x000,0x3DE,0x252,0x252,0x252,0x252,0x252,0x252,0x252,0x252,0x272,0x306,0x1FC,0x000,0x000,0x000,0x000, /* 55 */ +0x000,0x000,0x3CF,0x249,0x249,0x249,0x249,0x249,0x249,0x279,0x333,0x186,0x0CC,0x078,0x000,0x000,0x000,0x000, /* 56 */ +0x000,0x000,0x3CF,0x249,0x249,0x249,0x249,0x279,0x249,0x249,0x201,0x333,0x132,0x1FE,0x000,0x000,0x000,0x000, /* 57 */ +0x000,0x000,0x3CF,0x249,0x279,0x333,0x086,0x0CC,0x0CC,0x186,0x333,0x279,0x249,0x3CF,0x000,0x000,0x000,0x000, /* 58 */ +0x000,0x000,0x3CF,0x249,0x249,0x279,0x333,0x186,0x0CC,0x048,0x048,0x0CC,0x084,0x0FC,0x000,0x000,0x000,0x000, /* 59 */ +0x000,0x000,0x3FF,0x201,0x279,0x2F3,0x3E6,0x0CC,0x198,0x337,0x26D,0x279,0x201,0x3FF,0x000,0x000,0x000,0x000, /* 5A */ +0x000,0x000,0x0FC,0x084,0x09C,0x090,0x090,0x090,0x090,0x090,0x090,0x09C,0x084,0x0FC,0x000,0x000,0x000,0x000, /* 5B */ +0x000,0x000,0x000,0x380,0x2C0,0x260,0x230,0x318,0x18C,0x0C6,0x062,0x032,0x01A,0x00E,0x000,0x000,0x000,0x000, /* 5C */ +0x000,0x000,0x0FC,0x084,0x0E4,0x024,0x024,0x024,0x024,0x024,0x024,0x0E4,0x084,0x0FC,0x000,0x000,0x000,0x000, /* 5D */ +0x070,0x0D8,0x18C,0x326,0x272,0x3DE,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 5E */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x3FF,0x201,0x3FF,0x000,0x000, /* 5F */ +0x0F0,0x090,0x098,0x0C8,0x078,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 60 */ +0x000,0x000,0x000,0x000,0x000,0x1F8,0x10C,0x1E4,0x304,0x264,0x264,0x266,0x312,0x1FE,0x000,0x000,0x000,0x000, /* 61 */ +0x000,0x000,0x3E0,0x220,0x320,0x138,0x10C,0x126,0x132,0x132,0x132,0x132,0x106,0x1FC,0x000,0x000,0x000,0x000, /* 62 */ +0x000,0x000,0x000,0x000,0x000,0x1FC,0x306,0x272,0x25E,0x240,0x25E,0x272,0x306,0x1FC,0x000,0x000,0x000,0x000, /* 63 */ +0x000,0x000,0x07C,0x044,0x064,0x0E4,0x184,0x324,0x264,0x264,0x264,0x266,0x312,0x1FE,0x000,0x000,0x000,0x000, /* 64 */ +0x000,0x000,0x000,0x000,0x000,0x1FC,0x306,0x272,0x202,0x27E,0x25E,0x272,0x306,0x1FC,0x000,0x000,0x000,0x000, /* 65 */ +0x000,0x000,0x0F8,0x18C,0x124,0x134,0x33C,0x210,0x330,0x120,0x120,0x330,0x210,0x3F0,0x000,0x000,0x000,0x000, /* 66 */ +0x000,0x000,0x000,0x000,0x000,0x1FE,0x312,0x266,0x264,0x264,0x264,0x264,0x304,0x3E4,0x264,0x30C,0x1F8,0x000, /* 67 */ +0x000,0x000,0x3E0,0x220,0x320,0x13C,0x126,0x112,0x132,0x132,0x132,0x332,0x232,0x3FE,0x000,0x000,0x000,0x000, /* 68 */ +0x000,0x000,0x078,0x048,0x048,0x0F8,0x088,0x0C8,0x048,0x048,0x048,0x0CC,0x084,0x0FC,0x000,0x000,0x000,0x000, /* 69 */ +0x000,0x000,0x01E,0x012,0x012,0x03E,0x022,0x032,0x012,0x012,0x012,0x012,0x1F2,0x132,0x132,0x186,0x0FC,0x000, /* 6A */ +0x000,0x000,0x3E0,0x220,0x320,0x13E,0x132,0x126,0x10C,0x10C,0x126,0x332,0x232,0x3FE,0x000,0x000,0x000,0x000, /* 6B */ +0x000,0x000,0x0F8,0x088,0x0C8,0x048,0x048,0x048,0x048,0x048,0x048,0x0CC,0x084,0x0FC,0x000,0x000,0x000,0x000, /* 6C */ +0x000,0x000,0x000,0x000,0x000,0x3FE,0x233,0x201,0x249,0x249,0x249,0x249,0x249,0x3FF,0x000,0x000,0x000,0x000, /* 6D */ +0x000,0x000,0x000,0x000,0x000,0x3FC,0x246,0x332,0x132,0x132,0x132,0x132,0x132,0x1FE,0x000,0x000,0x000,0x000, /* 6E */ +0x000,0x000,0x000,0x000,0x000,0x1FC,0x306,0x272,0x252,0x252,0x252,0x272,0x306,0x1FC,0x000,0x000,0x000,0x000, /* 6F */ +0x000,0x000,0x000,0x000,0x000,0x3FC,0x246,0x332,0x132,0x132,0x132,0x132,0x106,0x13C,0x330,0x210,0x3F0,0x000, /* 70 */ +0x000,0x000,0x000,0x000,0x000,0x1FE,0x312,0x266,0x264,0x264,0x264,0x264,0x304,0x1E4,0x066,0x042,0x07E,0x000, /* 71 */ +0x000,0x000,0x000,0x000,0x000,0x3FC,0x246,0x312,0x132,0x13E,0x120,0x330,0x210,0x3F0,0x000,0x000,0x000,0x000, /* 72 */ +0x000,0x000,0x000,0x000,0x000,0x1FC,0x306,0x272,0x33E,0x088,0x3E6,0x272,0x306,0x1FC,0x000,0x000,0x000,0x000, /* 73 */ +0x000,0x000,0x070,0x0D0,0x090,0x39C,0x204,0x39C,0x090,0x090,0x09E,0x092,0x0C6,0x07C,0x000,0x000,0x000,0x000, /* 74 */ +0x000,0x000,0x000,0x000,0x000,0x3FC,0x264,0x264,0x264,0x264,0x264,0x266,0x312,0x1FE,0x000,0x000,0x000,0x000, /* 75 */ +0x000,0x000,0x000,0x000,0x000,0x3CF,0x249,0x249,0x249,0x279,0x333,0x186,0x0CC,0x078,0x000,0x000,0x000,0x000, /* 76 */ +0x000,0x000,0x000,0x000,0x000,0x3CF,0x249,0x249,0x279,0x249,0x249,0x201,0x333,0x1FE,0x000,0x000,0x000,0x000, /* 77 */ +0x000,0x000,0x000,0x000,0x000,0x3CF,0x279,0x333,0x084,0x0CC,0x084,0x333,0x279,0x3CF,0x000,0x000,0x000,0x000, /* 78 */ +0x000,0x000,0x000,0x000,0x000,0x3DE,0x252,0x252,0x252,0x252,0x252,0x272,0x302,0x1F2,0x3E6,0x20C,0x3F8,0x000, /* 79 */ +0x000,0x000,0x000,0x000,0x000,0x3FE,0x202,0x264,0x3C8,0x090,0x13E,0x272,0x202,0x3FE,0x000,0x000,0x000,0x000, /* 7A */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 7B */ +0x000,0x000,0x078,0x048,0x048,0x048,0x048,0x078,0x048,0x048,0x048,0x048,0x048,0x078,0x000,0x000,0x000,0x000, /* 7C */ +0x000,0x000,0x0E0,0x110,0x0C8,0x048,0x04C,0x022,0x04C,0x048,0x048,0x0C8,0x110,0x0E0,0x000,0x000,0x000,0x000, /* 7D */ +0x000,0x000,0x1EE,0x312,0x246,0x3BC,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 7E */ +0x000,0x000,0x000,0x000,0x020,0x050,0x088,0x124,0x252,0x252,0x272,0x202,0x1FC,0x000,0x000,0x000,0x000,0x000, /* 7F */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 80 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 81 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 82 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 83 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 84 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 85 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 86 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 87 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 88 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 89 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 8A */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 8B */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 8C */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 8D */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 8E */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 8F */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 90 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 91 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 92 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 93 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 94 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 95 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 96 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 97 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 98 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 99 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 9A */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 9B */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 9C */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 9D */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 9E */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* 9F */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* A0 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* A1 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* A2 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* A3 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* A4 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* A5 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* A6 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* A7 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* A8 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* A9 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* AA */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* AB */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* AC */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* AD */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* AE */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* AF */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* B0 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* B1 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* B2 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* B3 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* B4 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* B5 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* B6 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* B7 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* B8 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* B9 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* BA */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* BB */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* BC */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* BD */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* BE */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* BF */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* C0 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* C1 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* C2 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* C3 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* C4 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* C5 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* C6 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* C7 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* C8 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* C9 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* CA */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* CB */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* CC */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* CD */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* CE */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* CF */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* D0 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* D1 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* D2 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* D3 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* D4 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* D5 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* D6 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* D7 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* D8 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* D9 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* DA */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* DB */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* DC */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* DD */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* DE */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* DF */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* E0 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* E1 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* E2 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* E3 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* E4 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* E5 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* E6 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* E7 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* E8 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* E9 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* EA */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* EB */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* EC */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* ED */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* EE */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* EF */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* F0 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* F1 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* F2 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* F3 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* F4 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* F5 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* F6 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* F7 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* F8 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x078,0x048,0x048,0x078,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* F9 */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x078,0x048,0x078,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* FA */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* FB */ +0x000,0x3F8,0x20C,0x304,0x104,0x104,0x104,0x104,0x1FC,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* FC */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000, /* FD */ +0x000,0x000,0x000,0x000,0x1FC,0x104,0x104,0x104,0x104,0x104,0x104,0x104,0x1FC,0x000,0x000,0x000,0x000,0x000, /* FE */ +0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000,0x000 /* FF */ +}; + + return (font_eng_contour[(int)c*(OSD_FONT_HEIGHT+2) + y] >> (9-x))&1; + } //contour() + + }; //class + +} //namespace + + +#endif diff --git a/src/softrender_v3sysfont.h b/src/softrender_v3sysfont.h new file mode 100644 index 000000000..11f0a654d --- /dev/null +++ b/src/softrender_v3sysfont.h @@ -0,0 +1,940 @@ +#include "softrender.h" + +#define xx 1 +#define zz 0 + +namespace softrender { + + class v3sysfont { + public: + static int height() { return 7; } + static int width(char c) { return charByte(c,0); } + static int pixel(char c, int x, int y) { return charByte(c,width(c)*y+x+1); } + static bool valid(char c) { return c>=32; } + static bool haveContour() { return false; } + + static char charByte(byte c, int i) { + + if (c < 32 || c > 128) + c = 2; + else + c -= 32; + + static const char sbA[]= + {4, + zz,xx,xx,zz, + xx,zz,zz,xx, + xx,zz,zz,xx, + xx,xx,xx,xx, + xx,zz,zz,xx, + xx,zz,zz,xx, + xx,zz,zz,xx}; + + static const char ssA[]= + {5, + zz,zz,zz,zz,zz, + zz,zz,zz,zz,zz, + zz,xx,xx,zz,zz, + xx,zz,zz,xx,zz, + xx,zz,zz,xx,zz, + xx,zz,zz,xx,zz, + zz,xx,xx,zz,xx}; + + static const char sbB[]= + {4, + xx,xx,xx,zz, + xx,zz,zz,xx, + xx,zz,zz,xx, + xx,xx,xx,zz, + xx,zz,zz,xx, + xx,zz,zz,xx, + xx,xx,xx,zz}; + + static const char ssB[]= + {4, + xx,zz,zz,zz, + xx,zz,zz,zz, + xx,xx,xx,zz, + xx,zz,zz,xx, + xx,zz,zz,xx, + xx,zz,zz,xx, + xx,xx,xx,zz}; + + static const char sbC[]= + {4, + zz,xx,xx,zz, + xx,zz,zz,xx, + xx,zz,zz,zz, + xx,zz,zz,zz, + xx,zz,zz,zz, + xx,zz,zz,xx, + zz,xx,xx,zz}; + + static const char ssC[]= + {3, + zz,zz,zz, + zz,zz,zz, + zz,xx,xx, + xx,zz,zz, + xx,zz,zz, + xx,zz,zz, + zz,xx,xx}; + + static const char sbD[]= + {4, + xx,xx,zz,zz, + xx,zz,xx,zz, + xx,zz,zz,xx, + xx,zz,zz,xx, + xx,zz,zz,xx, + xx,zz,xx,zz, + xx,xx,zz,zz}; + + + static const char ssD[]= + {4, + zz,zz,zz,xx, + zz,zz,zz,xx, + zz,xx,xx,xx, + xx,zz,zz,xx, + xx,zz,zz,xx, + xx,zz,zz,xx, + zz,xx,xx,xx}; + + static const char sbE[]= + {4, + xx,xx,xx,xx, + xx,zz,zz,zz, + xx,zz,zz,zz, + xx,xx,xx,zz, + xx,zz,zz,zz, + xx,zz,zz,zz, + xx,xx,xx,xx}; + + static const char ssE[]= + {4, + zz,zz,zz,zz, + zz,zz,zz,zz, + zz,xx,xx,zz, + xx,zz,zz,xx, + xx,xx,xx,zz, + xx,zz,zz,zz, + zz,xx,xx,zz}; + + static const char sbF[]= + {4, + xx,xx,xx,xx, + xx,zz,zz,zz, + xx,zz,zz,zz, + xx,xx,xx,zz, + xx,zz,zz,zz, + xx,zz,zz,zz, + xx,zz,zz,zz}; + + static const char ssF[]= + {4, + zz,zz,xx,zz, + zz,xx,zz,xx, + zz,xx,zz,zz, + xx,xx,xx,zz, + zz,xx,zz,zz, + zz,xx,zz,zz, + zz,xx,zz,zz}; + + static const char sbG[]= + {4, + zz,xx,xx,zz, + xx,zz,zz,xx, + xx,zz,zz,zz, + xx,zz,zz,zz, + xx,zz,xx,xx, + xx,zz,zz,xx, + zz,xx,xx,zz}; + + static const char ssG[]= + {4, + zz,zz,zz,zz, + zz,zz,zz,zz, + zz,xx,xx,zz, + xx,zz,zz,zz, + xx,zz,xx,xx, + xx,zz,zz,xx, + zz,xx,xx,zz}; + + + static const char sbH[]= + {4, + xx,zz,zz,xx, + xx,zz,zz,xx, + xx,zz,zz,xx, + xx,xx,xx,xx, + xx,zz,zz,xx, + xx,zz,zz,xx, + xx,zz,zz,xx}; + + static const char ssH[]= + {4, + xx,zz,zz,zz, + xx,zz,zz,zz, + xx,xx,xx,zz, + xx,zz,zz,xx, + xx,zz,zz,xx, + xx,zz,zz,xx, + xx,zz,zz,xx}; + + static const char sbI[]= + {3, + xx,xx,xx, + zz,xx,zz, + zz,xx,zz, + zz,xx,zz, + zz,xx,zz, + zz,xx,zz, + xx,xx,xx}; + + static const char ssI[]= + {1, + zz, + xx, + zz, + xx, + xx, + xx, + xx}; + + static const char sbJ[]= + {4, + zz,zz,zz,xx, + zz,zz,zz,xx, + zz,zz,zz,xx, + zz,zz,zz,xx, + zz,zz,zz,xx, + xx,zz,zz,xx, + zz,xx,xx,zz}; + + static const char ssJ[]= + {3, + zz,zz,xx, + zz,zz,zz, + zz,zz,xx, + zz,zz,xx, + zz,zz,xx, + xx,zz,xx, + zz,xx,zz}; + + static const char sbK[]= + {4, + xx,zz,zz,xx, + xx,zz,zz,xx, + xx,zz,xx,zz, + xx,xx,zz,zz, + xx,xx,xx,zz, + xx,zz,zz,xx, + xx,zz,zz,xx}; + + static const char ssK[]= + {3, + xx,zz,zz, + xx,zz,zz, + xx,zz,xx, + xx,zz,xx, + xx,xx,zz, + xx,zz,xx, + xx,zz,xx}; + + static const char sbL[]= + {3, + xx,zz,zz, + xx,zz,zz, + xx,zz,zz, + xx,zz,zz, + xx,zz,zz, + xx,zz,zz, + xx,xx,xx}; + + static const char ssL[]= + {3, + zz,zz,zz, + zz,zz,zz, + xx,zz,zz, + xx,zz,zz, + xx,zz,zz, + xx,zz,zz, + xx,xx,xx}; + + static const char sbM[]= + {5, + xx,zz,zz,zz,xx, + xx,xx,zz,xx,xx, + xx,zz,xx,zz,xx, + xx,zz,xx,zz,xx, + xx,zz,zz,zz,xx, + xx,zz,zz,zz,xx, + xx,zz,zz,zz,xx}; + + static const char ssM[]= + {5, + zz,zz,zz,zz,zz, + zz,zz,zz,zz,zz, + zz,xx,zz,xx,zz, + xx,zz,xx,zz,xx, + xx,zz,xx,zz,xx, + xx,zz,xx,zz,xx, + xx,zz,xx,zz,xx}; + + static const char sbN[]= + {4, + xx,zz,zz,xx, + xx,zz,zz,xx, + xx,xx,zz,xx, + xx,zz,xx,xx, + xx,zz,zz,xx, + xx,zz,zz,xx, + xx,zz,zz,xx}; + + static const char ssN[]= + {4, + zz,zz,zz,zz, + zz,zz,zz,zz, + xx,zz,xx,zz, + xx,xx,zz,xx, + xx,zz,zz,xx, + xx,zz,zz,xx, + xx,zz,zz,xx}; + + static const char sbO[]= + {4, + zz,xx,xx,zz, + xx,zz,zz,xx, + xx,zz,zz,xx, + xx,zz,zz,xx, + xx,zz,zz,xx, + xx,zz,zz,xx, + zz,xx,xx,zz}; + + static const char ssO[]= + {4, + zz,zz,zz,zz, + zz,zz,zz,zz, + zz,xx,xx,zz, + xx,zz,zz,xx, + xx,zz,zz,xx, + xx,zz,zz,xx, + zz,xx,xx,zz}; + + static const char sbP[]= + {4, + xx,xx,xx,zz, + xx,zz,zz,xx, + xx,zz,zz,xx, + xx,xx,xx,zz, + xx,zz,zz,zz, + xx,zz,zz,zz, + xx,zz,zz,zz}; + + static const char ssP[]= + {4, + zz,zz,zz,zz, + zz,zz,zz,zz, + xx,xx,xx,zz, + xx,zz,zz,xx, + xx,zz,zz,xx, + xx,xx,xx,zz, + xx,zz,zz,zz}; + + static const char sbQ[]= + {4, + zz,xx,xx,zz, + xx,zz,zz,xx, + xx,zz,zz,xx, + xx,zz,zz,xx, + xx,zz,zz,xx, + xx,zz,xx,zz, + zz,xx,zz,xx}; + + static const char ssQ[]= + {4, + zz,zz,zz,zz, + zz,zz,zz,zz, + zz,xx,xx,zz, + xx,zz,zz,xx, + xx,zz,zz,xx, + xx,zz,xx,zz, + zz,xx,zz,xx}; + + static const char sbR[]= + {4, + xx,xx,xx,zz, + xx,zz,zz,xx, + xx,zz,zz,xx, + xx,xx,xx,zz, + xx,zz,zz,xx, + xx,zz,zz,xx, + xx,zz,zz,xx}; + + static const char ssR[]= + {4, + zz,zz,zz,zz, + zz,zz,zz,zz, + zz,xx,xx,zz, + xx,zz,zz,xx, + xx,zz,zz,zz, + xx,zz,zz,zz, + xx,zz,zz,zz}; + + static const char sbS[]= + {4, + zz,xx,xx,zz, + xx,zz,zz,xx, + xx,zz,zz,zz, + zz,xx,xx,zz, + zz,zz,zz,xx, + xx,zz,zz,xx, + zz,xx,xx,zz,}; + + static const char ssS[]= + {3, + zz,zz,zz, + zz,zz,zz, + zz,xx,xx, + xx,zz,zz, + zz,xx,zz, + zz,zz,xx, + xx,xx,zz}; + + static const char sbT[]= + {3, + xx,xx,xx, + zz,xx,zz, + zz,xx,zz, + zz,xx,zz, + zz,xx,zz, + zz,xx,zz, + zz,xx,zz}; + + static const char ssT[]= + {3, + zz,xx,zz, + zz,xx,zz, + xx,xx,xx, + zz,xx,zz, + zz,xx,zz, + zz,xx,zz, + zz,xx,xx}; + + static const char sbU[]= + {3, + xx,zz,xx, + xx,zz,xx, + xx,zz,xx, + xx,zz,xx, + xx,zz,xx, + xx,zz,xx, + xx,xx,xx}; + + static const char ssU[]= + {3, + zz,zz,zz, + zz,zz,zz, + xx,zz,xx, + xx,zz,xx, + xx,zz,xx, + xx,zz,xx, + xx,xx,xx}; + + static const char sbV[]= + {3, + xx,zz,xx, + xx,zz,xx, + xx,zz,xx, + xx,zz,xx, + xx,zz,xx, + xx,zz,xx, + zz,xx,zz}; + + static const char ssV[]= + {3, + zz,zz,zz, + zz,zz,zz, + xx,zz,xx, + xx,zz,xx, + xx,zz,xx, + xx,zz,xx, + zz,xx,zz}; + + static const char sbW[]= + {5, + xx,zz,zz,zz,xx, + xx,zz,zz,zz,xx, + xx,zz,zz,zz,xx, + xx,zz,xx,zz,xx, + xx,zz,xx,zz,xx, + xx,xx,zz,xx,xx, + xx,zz,zz,zz,xx}; + + static const char ssW[]= + {5, + zz,zz,zz,zz,zz, + zz,zz,zz,zz,zz, + xx,zz,zz,zz,xx, + xx,zz,xx,zz,xx, + xx,zz,xx,zz,xx, + xx,xx,zz,xx,xx, + xx,zz,zz,zz,xx}; + + static const char sbX[]= + {5, + xx,zz,zz,zz,xx, + xx,zz,zz,zz,xx, + zz,xx,zz,xx,zz, + zz,zz,xx,zz,zz, + zz,xx,zz,xx,zz, + xx,zz,zz,zz,xx, + xx,zz,zz,zz,xx}; + + static const char ssX[]= + {3, + zz,zz,zz, + zz,zz,zz, + xx,zz,xx, + xx,zz,xx, + zz,xx,zz, + xx,zz,xx, + xx,zz,xx}; + + static const char sbY[]= + {3, + xx,zz,xx, + xx,zz,xx, + xx,zz,xx, + zz,xx,zz, + zz,xx,zz, + zz,xx,zz, + zz,xx,zz}; + + static const char ssY[]= + {3, + zz,zz,zz, + zz,zz,zz, + xx,zz,xx, + xx,zz,xx, + zz,xx,zz, + zz,xx,zz, + zz,xx,zz}; + + static const char sbZ[]= + {5, + xx,xx,xx,xx,xx, + zz,zz,zz,zz,xx, + zz,zz,zz,xx,zz, + zz,zz,xx,zz,zz, + zz,xx,zz,zz,zz, + xx,zz,zz,zz,zz, + xx,xx,xx,xx,xx}; + + static const char ssZ[]= + {4, + zz,zz,zz,zz, + zz,zz,zz,zz, + xx,xx,xx,xx, + zz,zz,zz,xx, + zz,zz,xx,zz, + zz,xx,zz,zz, + xx,xx,xx,xx}; + + static const char s1[]= + {3, + zz,xx,zz, + xx,xx,zz, + zz,xx,zz, + zz,xx,zz, + zz,xx,zz, + zz,xx,zz, + xx,xx,xx}; + + static const char s2[]= + {4, + zz,xx,xx,zz, + xx,zz,zz,xx, + zz,zz,zz,xx, + zz,zz,zz,xx, + zz,zz,xx,zz, + zz,xx,zz,zz, + xx,xx,xx,xx}; + + static const char s3[]= + {4, + xx,xx,xx,xx, + zz,zz,zz,xx, + zz,zz,zz,xx, + zz,xx,xx,xx, + zz,zz,zz,xx, + zz,zz,zz,xx, + xx,xx,xx,xx}; + + static const char s4[]= + {4, + xx,zz,xx,zz, + xx,zz,xx,zz, + xx,zz,xx,zz, + xx,xx,xx,xx, + zz,zz,xx,zz, + zz,zz,xx,zz, + zz,zz,xx,zz}; + + static const char s5[]= + {4, + xx,xx,xx,xx, + xx,zz,zz,zz, + xx,zz,zz,zz, + xx,xx,xx,zz, + zz,zz,zz,xx, + zz,zz,zz,xx, + xx,xx,xx,zz}; + + static const char s6[]= + {4, + zz,xx,xx,zz, + xx,zz,zz,xx, + xx,zz,zz,zz, + xx,xx,xx,zz, + xx,zz,zz,xx, + xx,zz,zz,xx, + zz,xx,xx,zz}; + + static const char s7[]= + {3, + xx,xx,xx, + zz,zz,xx, + zz,zz,xx, + zz,xx,zz, + zz,xx,zz, + zz,xx,zz, + zz,xx,zz}; + + static const char s8[]= + {4, + zz,xx,xx,zz, + xx,zz,zz,xx, + xx,zz,zz,xx, + zz,xx,xx,zz, + xx,zz,zz,xx, + xx,zz,zz,xx, + zz,xx,xx,zz}; + + static const char s9[]= + {3, + xx,xx,xx, + xx,zz,xx, + xx,zz,xx, + xx,xx,xx, + zz,zz,xx, + zz,zz,xx, + xx,xx,xx}; + + static const char s0[]= + {3, + xx,xx,xx, + xx,zz,xx, + xx,zz,xx, + xx,zz,xx, + xx,zz,xx, + xx,zz,xx, + xx,xx,xx}; + + static const char sQuote[]={3, + xx,zz,xx, + xx,zz,xx, + zz,zz,zz, + zz,zz,zz, + zz,zz,zz, + zz,zz,zz, + zz,zz,zz}; + + static const char sYow[]={3, + zz,xx,zz, + xx,xx,xx, + xx,xx,xx, + xx,xx,xx, + zz,xx,zz, + zz,zz,zz, + zz,xx,zz}; + + static const char sQuotes[]={1, + xx, + xx, + zz, + zz, + zz, + zz, + zz}; + + + static const char sComma[]={2, + zz,zz, + zz,zz, + zz,zz, + zz,zz, + zz,zz, + zz,xx, + xx,zz}; + + static const char sPeriod[]={1, + zz, + zz, + zz, + zz, + zz, + zz, + xx}; + + static const char sMinus[]={2, + zz,zz, + zz,zz, + zz,zz, + xx,xx, + zz,zz, + zz,zz, + zz,zz}; + + static const char sQuest[]={3, + xx,xx,xx, + zz,zz,xx, + zz,zz,xx, + zz,zz,xx, + zz,xx,xx, + zz,zz,zz, + zz,xx,zz}; + + static const char sColon[]={1, + zz, + zz, + xx, + zz, + xx, + zz, + zz}; + + static const char sch[]={3, + zz,xx,zz, + xx,xx,xx, + xx,xx,xx, + xx,xx,xx, + zz,xx,zz}; + + static const char usc[]={2, + zz,zz, + zz,zz, + zz,zz, + zz,zz, + xx,xx}; + + static const char star[]={5, + zz,zz,zz,zz,zz, + zz,zz,zz,zz,zz, + xx,xx,xx,xx,xx, + xx,xx,xx,xx,xx, + zz,zz,zz,zz,zz, + zz,zz,zz,zz,zz, + zz,zz,zz,zz,zz}; + + static const char ss[]={2, + xx,xx, + xx,xx, + xx,xx, + xx,xx, + xx,xx, + xx,xx, + xx,xx}; + + static const char sra[]={3, + zz,zz,zz, + xx,zz,zz, + xx,xx,zz, + xx,xx,xx, + xx,xx,zz, + xx,zz,zz, + zz,zz,zz}; + + static const char slParen[]={2, + zz,xx, + xx,zz, + xx,zz, + xx,zz, + xx,zz, + xx,zz, + zz,xx}; + + static const char srParen[]={2, + xx,zz, + zz,xx, + zz,xx, + zz,xx, + zz,xx, + zz,xx, + xx,zz}; + + static const char ssemic[]={2, + zz,xx, + zz,zz, + zz,xx, + zz,xx, + zz,xx, + zz,xx, + xx,zz}; + + static const char sSlash[]={3, + zz,zz,zz, + zz,zz,xx, + zz,zz,xx, + zz,xx,zz, + zz,xx,zz, + xx,zz,zz, + xx,zz,zz}; + + static const char sbSlash[]={3, + zz,zz,zz, + xx,zz,zz, + xx,zz,zz, + zz,xx,zz, + zz,xx,zz, + zz,zz,xx, + zz,zz,xx}; + + static const char sBlock[]={3, + zz,zz,zz, + zz,zz,zz, + xx,xx,xx, + xx,xx,xx, + xx,xx,xx, + zz,zz,zz, + zz,zz,zz}; + + static const char sBlank[]={2, + zz,zz, + zz,zz, + zz,zz, + zz,zz, + zz,zz, + zz,zz, + zz,zz}; + + static const char sAT[]= + { 5, + zz,xx,xx,xx,zz, + xx,zz,zz,zz,xx, + xx,zz,xx,xx,xx, + xx,zz,xx,zz,xx, + xx,zz,xx,xx,xx, + xx,zz,zz,zz,zz, + zz,xx,xx,xx,zz}; + + static const char sNum[]= + { 5, + zz,zz,zz,zz,zz, + zz,xx,zz,xx,zz, + xx,xx,xx,xx,xx, + zz,xx,zz,xx,zz, + xx,xx,xx,xx,xx, + zz,xx,zz,xx,zz, + zz,zz,zz,zz,zz}; + + static const char sBuck[]= + {5, + zz,zz,zz,zz,zz, + zz,zz,zz,zz,zz, + zz,zz,xx,zz,zz, + zz,xx,xx,xx,zz, + xx,xx,xx,xx,xx, + zz,zz,zz,zz,zz, + zz,zz,zz,zz,zz}; + + static const char sPercnt[]= + { + 5, + zz,zz,zz,zz,zz, + xx,zz,zz,zz,xx, + zz,zz,zz,xx,zz, + zz,zz,xx,zz,zz, + zz,xx,zz,zz,zz, + xx,zz,zz,zz,xx, + zz,zz,zz,zz,zz}; + + static const char sCarot[]= + { 3, + zz,xx,zz, + xx,zz,xx, + zz,zz,zz, + zz,zz,zz, + zz,zz,zz, + zz,zz,zz, + zz,zz,zz}; + + static const char sCopy[]= + { 7, + zz,xx,xx,xx,xx,xx,zz, + xx,zz,zz,zz,zz,zz,xx, + xx,zz,zz,xx,xx,zz,xx, + xx,zz,xx,zz,zz,zz,xx, + xx,zz,zz,xx,xx,zz,xx, + xx,zz,zz,zz,zz,zz,xx, + zz,xx,xx,xx,xx,xx,zz}; + + static const char sPtr[]= + { 5, + xx,zz,zz,zz,zz, + xx,xx,zz,zz,zz, + xx,xx,xx,zz,zz, + xx,xx,xx,xx,zz, + xx,xx,xx,xx,xx, + zz,zz,xx,zz,zz, + zz,zz,zz,xx,zz}; + + static const char check[]= + { 7, + xx,zz,zz,zz,zz,zz,xx, + zz,xx,zz,zz,zz,xx,zz, + zz,zz,xx,zz,xx,zz,zz, + zz,zz,zz,xx,zz,zz,zz, + zz,zz,xx,zz,xx,zz,zz, + zz,xx,zz,zz,zz,xx,zz, + xx,zz,zz,zz,zz,zz,xx }; + + static const char target[]= + { 7, + zz,zz,zz,xx,zz,zz,zz, + zz,zz,xx,zz,xx,zz,zz, + zz,xx,zz,zz,zz,xx,zz, + xx,zz,zz,xx,zz,zz,xx, + zz,xx,zz,zz,zz,xx,zz, + zz,zz,xx,zz,xx,zz,zz, + zz,zz,zz,xx,zz,zz,zz }; + + static const char *smal_tbl[]= + { sBlank, + sYow, sQuote, sNum, sBuck,sPercnt, sCarot, sQuotes, slParen, + srParen, star, sPtr, sComma, sMinus,sPeriod, sSlash, s0, + s1, s2, s3, s4, s5, s6, s7, s8, + s9, sColon, ssemic, ss, ss, sra, sQuest, sAT, + sbA, sbB, sbC, sbD, sbE, sbF, sbG, sbH, + sbI, sbJ, sbK, sbL, sbM, sbN, sbO, sbP, + sbQ, sbR, sbS, sbT, sbU, sbV, sbW, sbX, + sbY, sbZ, ss, sbSlash, ss, sCarot, usc, sch, + ssA, ssB, ssC, ssD, ssE, ssF, ssG, ssH, + ssI, ssJ, ssK, ssL, ssM, ssN, ssO, ssP, + ssQ, ssR, ssS, ssT, ssU, ssV, ssW, ssX, + ssY, ssZ, ss, target, check, sCopy, sBlock, ss}; + + return smal_tbl[c][i]; + } + + + }; + +} + + + + +#undef xx +#undef zz diff --git a/desmume/src/texcache.cpp b/src/texcache.cpp similarity index 96% rename from desmume/src/texcache.cpp rename to src/texcache.cpp index e33220d0a..ece81b4a0 100644 --- a/desmume/src/texcache.cpp +++ b/src/texcache.cpp @@ -1,650 +1,650 @@ -#include "texcache.h" - -#include -#include - -#include "bits.h" -#include "common.h" -#include "debug.h" -#include "gfx3d.h" -#include "NDSSystem.h" - -using std::min; -using std::max; - -//only dump this from ogl renderer. for now, softrasterizer creates things in an incompatible pixel format -//#define DEBUG_DUMP_TEXTURE - -//This class represents a number of regions of memory which should be viewed as contiguous -class MemSpan -{ -public: - static const int MAXSIZE = 8; - - MemSpan() - : numItems(0) - {} - - int numItems; - - struct Item { - u32 start; - u32 len; - u8* ptr; - u32 ofs; //offset within the memspan - } items[MAXSIZE]; - - int size; - - //this MemSpan shall be considered the first argument to a standard memcmp - //the length shall be as specified in this MemSpan, unless you specify otherwise - int memcmp(void* buf2, int size=-1) - { - if(size==-1) size = this->size; - size = min(this->size,size); - for(int i=0;isize; - size = min(this->size,size); - u8* bufptr = (u8*)buf; - int done = 0; - for(int i=0;isize; - size = min(this->size,size); - u16* bufptr = (u16*)buf; - int done = 0; - for(int i=0;i>17)&3; //slots will wrap around - curr.len = min(len,0x20000-curr.start); - curr.ofs = currofs; - len -= curr.len; - ofs += curr.len; - currofs += curr.len; - u8* ptr = ARM9Mem.texInfo.textureSlotAddr[slot]; - - if(ptr == ARM9Mem.blank_memory) { - PROGINFO("Tried to reference unmapped texture memory: slot %d\n",slot); - } - curr.ptr = ptr + curr.start; - } - return ret; -} - -//creates a MemSpan in texture palette memory -static MemSpan MemSpan_TexPalette(u32 ofs, u32 len) -{ - MemSpan ret; - ret.size = len; - u32 currofs = 0; - while(len) { - MemSpan::Item &curr = ret.items[ret.numItems++]; - curr.start = ofs&0x3FFF; - u32 slot = (ofs>>14)&7; //this masks to 8 slots, but there are really only 6 - if(slot>5) { - PROGINFO("Texture palette overruns texture memory. Wrapping at palette slot 0.\n"); - slot -= 5; - } - curr.len = min(len,0x4000-curr.start); - curr.ofs = currofs; - len -= curr.len; - ofs += curr.len; - //if(len != 0) - //here is an actual test case of bank spanning - currofs += curr.len; - u8* ptr = ARM9Mem.texInfo.texPalSlot[slot]; - - if(ptr == ARM9Mem.blank_memory) { - PROGINFO("Tried to reference unmapped texture palette memory: 16k slot #%d\n",slot); - } - curr.ptr = ptr + curr.start; - } - return ret; -} - -TextureCache *texcache; -u32 texcache_start; -u32 texcache_stop; -u8 *TexCache_texMAP = NULL; - - -#if defined (DEBUG_DUMP_TEXTURE) && defined (WIN32) -#define DO_DEBUG_DUMP_TEXTURE -static void DebugDumpTexture(int which) -{ - char fname[100]; - sprintf(fname,"c:\\dump\\%d.bmp", which); - - NDS_WriteBMP_32bppBuffer(texcache[which].sizeX,texcache[which].sizeY,TexCache_texMAP,fname); -} -#endif - - -static int lastTexture = -1; - -#define CONVERT(color,alpha) ((TEXFORMAT == TexFormat_32bpp)?(RGB15TO32(color,alpha)):RGB15TO5555(color,alpha)) - -template -void TexCache_SetTexture(u32 format, u32 texpal) -{ - //for each texformat, number of palette entries - const int palSizes[] = {0, 32, 4, 16, 256, 0, 8, 0}; - - //for each texformat, multiplier from numtexels to numbytes (fixed point 30.2) - const int texSizes[] = {0, 4, 1, 2, 4, 1, 4, 8}; - - //used to hold a copy of the palette specified for this texture - u16 pal[256]; - - u32 *dwdst = (u32*)TexCache_texMAP; - - u32 textureMode = (unsigned short)((format>>26)&0x07); - unsigned int sizeX=(8 << ((format>>20)&0x07)); - unsigned int sizeY=(8 << ((format>>23)&0x07)); - unsigned int imageSize = sizeX*sizeY; - - u8 *adr; - - u32 paletteAddress; - - switch (textureMode) - { - case TEXMODE_I2: - paletteAddress = texpal<<3; - break; - case TEXMODE_A3I5: //a3i5 - case TEXMODE_I4: //i4 - case TEXMODE_I8: //i8 - case TEXMODE_A5I3: //a5i3 - case TEXMODE_16BPP: //16bpp - case TEXMODE_4X4: //4x4 - default: - paletteAddress = texpal<<4; - break; - } - - //analyze the texture memory mapping and the specifications of this texture - int palSize = palSizes[textureMode]; - int texSize = (imageSize*texSizes[textureMode])>>2; //shifted because the texSizes multiplier is fixed point - MemSpan ms = MemSpan_TexMem((format&0xFFFF)<<3,texSize); - MemSpan mspal = MemSpan_TexPalette(paletteAddress,palSize*2); - - //determine the location for 4x4 index data - u32 indexBase; - if((format & 0xc000) == 0x8000) indexBase = 0x30000; - else indexBase = 0x20000; - - u32 indexOffset = (format&0x3FFF)<<2; - - int indexSize = 0; - MemSpan msIndex; - if(textureMode == TEXMODE_4X4) - { - indexSize = imageSize>>3; - msIndex = MemSpan_TexMem(indexOffset+indexBase,indexSize); - } - - - //dump the palette to a temp buffer, so that we don't have to worry about memory mapping. - //this isnt such a problem with texture memory, because we read sequentially from it. - //however, we read randomly from palette memory, so the mapping is more costly. -#ifdef WORDS_BIGENDIAN - mspal.dump16(pal); -#else - mspal.dump(pal); -#endif - - - u32 tx=texcache_start; - - //if(false) - while (TRUE) - { - //conditions where we give up and regenerate the texture: - if (texcache_stop == tx) break; - if (texcache[tx].frm == 0) break; - - //conditions where we reject matches: - //when the teximage or texpal params dont match - //(this is our key for identifying palettes in the cache) - if (texcache[tx].frm != format) goto REJECT; - if (texcache[tx].pal != texpal) goto REJECT; - - //the texture matches params, but isnt suspected invalid. accept it. - if (!texcache[tx].suspectedInvalid) goto ACCEPT; - - //if we couldnt cache this entire texture due to it being too large, then reject it - if (texSize+indexSize > (int)sizeof(texcache[tx].dump.texture)) goto REJECT; - - //when the palettes dont match: - //note that we are considering 4x4 textures to have a palette size of 0. - //they really have a potentially HUGE palette, too big for us to handle like a normal palette, - //so they go through a different system - if (mspal.size != 0 && memcmp(texcache[tx].dump.palette,pal,mspal.size)) goto REJECT; - - //when the texture data doesn't match - if(ms.memcmp(texcache[tx].dump.texture,sizeof(texcache[tx].dump.texture))) goto REJECT; - - //if the texture is 4x4 then the index data must match - if(textureMode == TEXMODE_4X4) - { - if(msIndex.memcmp(texcache[tx].dump.texture + texcache[tx].dump.textureSize,texcache[tx].dump.indexSize)) goto REJECT; - } - - -ACCEPT: - texcache[tx].suspectedInvalid = false; - if(lastTexture == -1 || (int)tx != lastTexture) - { - lastTexture = tx; - if(TexCache_BindTexture) - TexCache_BindTexture(tx); - } - return; - -REJECT: - tx++; - if ( tx > MAX_TEXTURE ) - { - texcache_stop=texcache_start; - texcache[texcache_stop].frm=0; - texcache_start++; - if (texcache_start>MAX_TEXTURE) - { - texcache_start=0; - texcache_stop=MAX_TEXTURE<<1; - } - tx=0; - } - } - - lastTexture = tx; - //glBindTexture(GL_TEXTURE_2D, texcache[tx].id); - - texcache[tx].suspectedInvalid = false; - texcache[tx].frm=format; - texcache[tx].mode=textureMode; - texcache[tx].pal=texpal; - texcache[tx].sizeX=sizeX; - texcache[tx].sizeY=sizeY; - texcache[tx].invSizeX=1.0f/((float)(sizeX)); - texcache[tx].invSizeY=1.0f/((float)(sizeY)); - texcache[tx].dump.textureSize = ms.dump(texcache[tx].dump.texture,sizeof(texcache[tx].dump.texture)); - - //dump palette data for cache keying - if ( palSize ) - { - memcpy(texcache[tx].dump.palette, pal, palSize*2); - } - //dump 4x4 index data for cache keying - texcache[tx].dump.indexSize = 0; - if(textureMode == TEXMODE_4X4) - { - texcache[tx].dump.indexSize = min(msIndex.size,(int)sizeof(texcache[tx].dump.texture) - texcache[tx].dump.textureSize); - msIndex.dump(texcache[tx].dump.texture+texcache[tx].dump.textureSize,texcache[tx].dump.indexSize); - } - - - //INFO("Texture %03i - format=%08X; pal=%04X (mode %X, width %04i, height %04i)\n",i, texcache[i].frm, texcache[i].pal, texcache[i].mode, sizeX, sizeY); - - //============================================================================ Texture conversion - const u32 opaqueColor = TEXFORMAT==TexFormat_32bpp?255:31; - u32 palZeroTransparent = (1-((format>>29)&1))*opaqueColor; - - switch (texcache[tx].mode) - { - case TEXMODE_A3I5: - { - for(int j=0;j>5; - if(TEXFORMAT == TexFormat_15bpp) - *dwdst++ = RGB15TO5555(c,material_3bit_to_5bit[alpha]); - else - *dwdst++ = RGB15TO32(c,material_3bit_to_8bit[alpha]); - adr++; - } - } - - break; - } - case TEXMODE_I2: - { - for(int j=0;j>2)&0x3; - c = pal[bits]; - *dwdst++ = CONVERT(c,(bits == 0) ? palZeroTransparent : opaqueColor); - - bits = ((*adr)>>4)&0x3; - c = pal[bits]; - *dwdst++ = CONVERT(c,(bits == 0) ? palZeroTransparent : opaqueColor); - - bits = ((*adr)>>6)&0x3; - c = pal[bits]; - *dwdst++ = CONVERT(c,(bits == 0) ? palZeroTransparent : opaqueColor); - - adr++; - } - } - break; - } - case TEXMODE_I4: - { - for(int j=0;j>4); - c = pal[bits]; - *dwdst++ = CONVERT(c,(bits == 0) ? palZeroTransparent : opaqueColor); - adr++; - } - } - break; - } - case TEXMODE_I8: - { - for(int j=0;j>14)] + ((paletteAddress + (offset)*2)&0x3FFF) ) ) - - u16* slot1; - u32* map = (u32*)ms.items[0].ptr; - u32 limit = ms.items[0].len<<2; - u32 d = 0; - if ( (texcache[tx].frm & 0xc000) == 0x8000) - // texel are in slot 2 - slot1=(u16*)&ARM9Mem.texInfo.textureSlotAddr[1][((texcache[tx].frm & 0x3FFF)<<2)+0x010000]; - else - slot1=(u16*)&ARM9Mem.texInfo.textureSlotAddr[1][(texcache[tx].frm & 0x3FFF)<<2]; - - u16 yTmpSize = (texcache[tx].sizeY>>2); - u16 xTmpSize = (texcache[tx].sizeX>>2); - - //this is flagged whenever a 4x4 overruns its slot. - //i am guessing we just generate black in that case - bool dead = false; - - for (int y = 0; y < yTmpSize; y ++) - { - u32 tmpPos[4]={(y<<2)*texcache[tx].sizeX,((y<<2)+1)*texcache[tx].sizeX, - ((y<<2)+2)*texcache[tx].sizeX,((y<<2)+3)*texcache[tx].sizeX}; - for (int x = 0; x < xTmpSize; x ++, d++) - { - if(d >= limit) - dead = true; - - if(dead) { - for (int sy = 0; sy < 4; sy++) - { - u32 currentPos = (x<<2) + tmpPos[sy]; - dwdst[currentPos] = dwdst[currentPos+1] = dwdst[currentPos+2] = dwdst[currentPos+3] = 0; - } - continue; - } - - u32 currBlock = map[d]; - u16 pal1 = slot1[d]; - u16 pal1offset = (pal1 & 0x3FFF)<<1; - u8 mode = pal1>>14; - u32 tmp_col[4]; - - tmp_col[0]=RGB16TO32(PAL4X4(pal1offset),255); - tmp_col[1]=RGB16TO32(PAL4X4(pal1offset+1),255); - - switch (mode) - { - case 0: - tmp_col[2]=RGB16TO32(PAL4X4(pal1offset+2),255); - tmp_col[3]=RGB16TO32(0x7FFF,0); - break; - case 1: - tmp_col[2]=(((tmp_col[0]&0xFF)+(tmp_col[1]&0xff))>>1)| - (((tmp_col[0]&(0xFF<<8))+(tmp_col[1]&(0xFF<<8)))>>1)| - (((tmp_col[0]&(0xFF<<16))+(tmp_col[1]&(0xFF<<16)))>>1)| - (0xff<<24); - tmp_col[3]=RGB16TO32(0x7FFF,0); - break; - case 2: - tmp_col[2]=RGB16TO32(PAL4X4(pal1offset+2),255); - tmp_col[3]=RGB16TO32(PAL4X4(pal1offset+3),255); - break; - case 3: - { - u32 red1, red2; - u32 green1, green2; - u32 blue1, blue2; - u16 tmp1, tmp2; - - red1=tmp_col[0]&0xff; - green1=(tmp_col[0]>>8)&0xff; - blue1=(tmp_col[0]>>16)&0xff; - red2=tmp_col[1]&0xff; - green2=(tmp_col[1]>>8)&0xff; - blue2=(tmp_col[1]>>16)&0xff; - - tmp1=((red1*5+red2*3)>>6)| - (((green1*5+green2*3)>>6)<<5)| - (((blue1*5+blue2*3)>>6)<<10); - tmp2=((red2*5+red1*3)>>6)| - (((green2*5+green1*3)>>6)<<5)| - (((blue2*5+blue1*3)>>6)<<10); - - tmp_col[2]=RGB16TO32(tmp1,255); - tmp_col[3]=RGB16TO32(tmp2,255); - break; - } - } - - if(TEXFORMAT==TexFormat_15bpp) - { - for(int i=0;i<4;i++) - { - tmp_col[i] >>= 3; - tmp_col[i] &= 0x1F1F1F1F; - } - } - - //TODO - this could be more precise for 32bpp mode (run it through the color separation table) - - //set all 16 texels - for (int sy = 0; sy < 4; sy++) - { - // Texture offset - u32 currentPos = (x<<2) + tmpPos[sy]; - u8 currRow = (u8)((currBlock>>(sy<<3))&0xFF); - - dwdst[currentPos] = tmp_col[currRow&3]; - dwdst[currentPos+1] = tmp_col[(currRow>>2)&3]; - dwdst[currentPos+2] = tmp_col[(currRow>>4)&3]; - dwdst[currentPos+3] = tmp_col[(currRow>>6)&3]; - } - - - } - } - - - break; - } - case TEXMODE_A5I3: - { - for(int j=0;j>3); - if(TEXFORMAT == TexFormat_15bpp) - *dwdst++ = RGB15TO5555(c,alpha); - else - *dwdst++ = RGB15TO32(c,material_5bit_to_8bit[alpha]); - adr++; - } - } - break; - } - case TEXMODE_16BPP: - { - for(int j=0;j>1; - for(u32 x = 0; x < len; ++x) - { - u16 c = map[x]; - int alpha = ((c&0x8000)?opaqueColor:0); - *dwdst++ = CONVERT(c&0x7FFF,alpha); - } - } - break; - } - } - - if(TexCache_BindTextureData != 0) - TexCache_BindTextureData(tx,TexCache_texMAP); - -#ifdef DO_DEBUG_DUMP_TEXTURE - DebugDumpTexture(tx); -#endif - -} - -void TexCache_Reset() -{ - if(TexCache_texMAP == NULL) TexCache_texMAP = new u8[1024*2048*4]; - if(texcache == NULL) texcache = new TextureCache[MAX_TEXTURE+1]; - - memset(texcache,0,sizeof(TextureCache[MAX_TEXTURE+1])); - - texcache_start=0; - texcache_stop=MAX_TEXTURE<<1; -} - -TextureCache* TexCache_Curr() -{ - if(lastTexture == -1) - return NULL; - else return &texcache[lastTexture]; -} - -void TexCache_Invalidate() -{ - //well, this is a very blunt instrument. - //lets just flag all the textures as invalid. - for(int i=0;i(u32 format, u32 texpal); -template void TexCache_SetTexture(u32 format, u32 texpal); +#include "texcache.h" + +#include +#include + +#include "bits.h" +#include "common.h" +#include "debug.h" +#include "gfx3d.h" +#include "NDSSystem.h" + +using std::min; +using std::max; + +//only dump this from ogl renderer. for now, softrasterizer creates things in an incompatible pixel format +//#define DEBUG_DUMP_TEXTURE + +//This class represents a number of regions of memory which should be viewed as contiguous +class MemSpan +{ +public: + static const int MAXSIZE = 8; + + MemSpan() + : numItems(0) + {} + + int numItems; + + struct Item { + u32 start; + u32 len; + u8* ptr; + u32 ofs; //offset within the memspan + } items[MAXSIZE]; + + int size; + + //this MemSpan shall be considered the first argument to a standard memcmp + //the length shall be as specified in this MemSpan, unless you specify otherwise + int memcmp(void* buf2, int size=-1) + { + if(size==-1) size = this->size; + size = min(this->size,size); + for(int i=0;isize; + size = min(this->size,size); + u8* bufptr = (u8*)buf; + int done = 0; + for(int i=0;isize; + size = min(this->size,size); + u16* bufptr = (u16*)buf; + int done = 0; + for(int i=0;i>17)&3; //slots will wrap around + curr.len = min(len,0x20000-curr.start); + curr.ofs = currofs; + len -= curr.len; + ofs += curr.len; + currofs += curr.len; + u8* ptr = ARM9Mem.texInfo.textureSlotAddr[slot]; + + if(ptr == ARM9Mem.blank_memory) { + PROGINFO("Tried to reference unmapped texture memory: slot %d\n",slot); + } + curr.ptr = ptr + curr.start; + } + return ret; +} + +//creates a MemSpan in texture palette memory +static MemSpan MemSpan_TexPalette(u32 ofs, u32 len) +{ + MemSpan ret; + ret.size = len; + u32 currofs = 0; + while(len) { + MemSpan::Item &curr = ret.items[ret.numItems++]; + curr.start = ofs&0x3FFF; + u32 slot = (ofs>>14)&7; //this masks to 8 slots, but there are really only 6 + if(slot>5) { + PROGINFO("Texture palette overruns texture memory. Wrapping at palette slot 0.\n"); + slot -= 5; + } + curr.len = min(len,0x4000-curr.start); + curr.ofs = currofs; + len -= curr.len; + ofs += curr.len; + //if(len != 0) + //here is an actual test case of bank spanning + currofs += curr.len; + u8* ptr = ARM9Mem.texInfo.texPalSlot[slot]; + + if(ptr == ARM9Mem.blank_memory) { + PROGINFO("Tried to reference unmapped texture palette memory: 16k slot #%d\n",slot); + } + curr.ptr = ptr + curr.start; + } + return ret; +} + +TextureCache *texcache; +u32 texcache_start; +u32 texcache_stop; +u8 *TexCache_texMAP = NULL; + + +#if defined (DEBUG_DUMP_TEXTURE) && defined (WIN32) +#define DO_DEBUG_DUMP_TEXTURE +static void DebugDumpTexture(int which) +{ + char fname[100]; + sprintf(fname,"c:\\dump\\%d.bmp", which); + + NDS_WriteBMP_32bppBuffer(texcache[which].sizeX,texcache[which].sizeY,TexCache_texMAP,fname); +} +#endif + + +static int lastTexture = -1; + +#define CONVERT(color,alpha) ((TEXFORMAT == TexFormat_32bpp)?(RGB15TO32(color,alpha)):RGB15TO5555(color,alpha)) + +template +void TexCache_SetTexture(u32 format, u32 texpal) +{ + //for each texformat, number of palette entries + const int palSizes[] = {0, 32, 4, 16, 256, 0, 8, 0}; + + //for each texformat, multiplier from numtexels to numbytes (fixed point 30.2) + const int texSizes[] = {0, 4, 1, 2, 4, 1, 4, 8}; + + //used to hold a copy of the palette specified for this texture + u16 pal[256]; + + u32 *dwdst = (u32*)TexCache_texMAP; + + u32 textureMode = (unsigned short)((format>>26)&0x07); + unsigned int sizeX=(8 << ((format>>20)&0x07)); + unsigned int sizeY=(8 << ((format>>23)&0x07)); + unsigned int imageSize = sizeX*sizeY; + + u8 *adr; + + u32 paletteAddress; + + switch (textureMode) + { + case TEXMODE_I2: + paletteAddress = texpal<<3; + break; + case TEXMODE_A3I5: //a3i5 + case TEXMODE_I4: //i4 + case TEXMODE_I8: //i8 + case TEXMODE_A5I3: //a5i3 + case TEXMODE_16BPP: //16bpp + case TEXMODE_4X4: //4x4 + default: + paletteAddress = texpal<<4; + break; + } + + //analyze the texture memory mapping and the specifications of this texture + int palSize = palSizes[textureMode]; + int texSize = (imageSize*texSizes[textureMode])>>2; //shifted because the texSizes multiplier is fixed point + MemSpan ms = MemSpan_TexMem((format&0xFFFF)<<3,texSize); + MemSpan mspal = MemSpan_TexPalette(paletteAddress,palSize*2); + + //determine the location for 4x4 index data + u32 indexBase; + if((format & 0xc000) == 0x8000) indexBase = 0x30000; + else indexBase = 0x20000; + + u32 indexOffset = (format&0x3FFF)<<2; + + int indexSize = 0; + MemSpan msIndex; + if(textureMode == TEXMODE_4X4) + { + indexSize = imageSize>>3; + msIndex = MemSpan_TexMem(indexOffset+indexBase,indexSize); + } + + + //dump the palette to a temp buffer, so that we don't have to worry about memory mapping. + //this isnt such a problem with texture memory, because we read sequentially from it. + //however, we read randomly from palette memory, so the mapping is more costly. +#ifdef WORDS_BIGENDIAN + mspal.dump16(pal); +#else + mspal.dump(pal); +#endif + + + u32 tx=texcache_start; + + //if(false) + while (TRUE) + { + //conditions where we give up and regenerate the texture: + if (texcache_stop == tx) break; + if (texcache[tx].frm == 0) break; + + //conditions where we reject matches: + //when the teximage or texpal params dont match + //(this is our key for identifying palettes in the cache) + if (texcache[tx].frm != format) goto REJECT; + if (texcache[tx].pal != texpal) goto REJECT; + + //the texture matches params, but isnt suspected invalid. accept it. + if (!texcache[tx].suspectedInvalid) goto ACCEPT; + + //if we couldnt cache this entire texture due to it being too large, then reject it + if (texSize+indexSize > (int)sizeof(texcache[tx].dump.texture)) goto REJECT; + + //when the palettes dont match: + //note that we are considering 4x4 textures to have a palette size of 0. + //they really have a potentially HUGE palette, too big for us to handle like a normal palette, + //so they go through a different system + if (mspal.size != 0 && memcmp(texcache[tx].dump.palette,pal,mspal.size)) goto REJECT; + + //when the texture data doesn't match + if(ms.memcmp(texcache[tx].dump.texture,sizeof(texcache[tx].dump.texture))) goto REJECT; + + //if the texture is 4x4 then the index data must match + if(textureMode == TEXMODE_4X4) + { + if(msIndex.memcmp(texcache[tx].dump.texture + texcache[tx].dump.textureSize,texcache[tx].dump.indexSize)) goto REJECT; + } + + +ACCEPT: + texcache[tx].suspectedInvalid = false; + if(lastTexture == -1 || (int)tx != lastTexture) + { + lastTexture = tx; + if(TexCache_BindTexture) + TexCache_BindTexture(tx); + } + return; + +REJECT: + tx++; + if ( tx > MAX_TEXTURE ) + { + texcache_stop=texcache_start; + texcache[texcache_stop].frm=0; + texcache_start++; + if (texcache_start>MAX_TEXTURE) + { + texcache_start=0; + texcache_stop=MAX_TEXTURE<<1; + } + tx=0; + } + } + + lastTexture = tx; + //glBindTexture(GL_TEXTURE_2D, texcache[tx].id); + + texcache[tx].suspectedInvalid = false; + texcache[tx].frm=format; + texcache[tx].mode=textureMode; + texcache[tx].pal=texpal; + texcache[tx].sizeX=sizeX; + texcache[tx].sizeY=sizeY; + texcache[tx].invSizeX=1.0f/((float)(sizeX)); + texcache[tx].invSizeY=1.0f/((float)(sizeY)); + texcache[tx].dump.textureSize = ms.dump(texcache[tx].dump.texture,sizeof(texcache[tx].dump.texture)); + + //dump palette data for cache keying + if ( palSize ) + { + memcpy(texcache[tx].dump.palette, pal, palSize*2); + } + //dump 4x4 index data for cache keying + texcache[tx].dump.indexSize = 0; + if(textureMode == TEXMODE_4X4) + { + texcache[tx].dump.indexSize = min(msIndex.size,(int)sizeof(texcache[tx].dump.texture) - texcache[tx].dump.textureSize); + msIndex.dump(texcache[tx].dump.texture+texcache[tx].dump.textureSize,texcache[tx].dump.indexSize); + } + + + //INFO("Texture %03i - format=%08X; pal=%04X (mode %X, width %04i, height %04i)\n",i, texcache[i].frm, texcache[i].pal, texcache[i].mode, sizeX, sizeY); + + //============================================================================ Texture conversion + const u32 opaqueColor = TEXFORMAT==TexFormat_32bpp?255:31; + u32 palZeroTransparent = (1-((format>>29)&1))*opaqueColor; + + switch (texcache[tx].mode) + { + case TEXMODE_A3I5: + { + for(int j=0;j>5; + if(TEXFORMAT == TexFormat_15bpp) + *dwdst++ = RGB15TO5555(c,material_3bit_to_5bit[alpha]); + else + *dwdst++ = RGB15TO32(c,material_3bit_to_8bit[alpha]); + adr++; + } + } + + break; + } + case TEXMODE_I2: + { + for(int j=0;j>2)&0x3; + c = pal[bits]; + *dwdst++ = CONVERT(c,(bits == 0) ? palZeroTransparent : opaqueColor); + + bits = ((*adr)>>4)&0x3; + c = pal[bits]; + *dwdst++ = CONVERT(c,(bits == 0) ? palZeroTransparent : opaqueColor); + + bits = ((*adr)>>6)&0x3; + c = pal[bits]; + *dwdst++ = CONVERT(c,(bits == 0) ? palZeroTransparent : opaqueColor); + + adr++; + } + } + break; + } + case TEXMODE_I4: + { + for(int j=0;j>4); + c = pal[bits]; + *dwdst++ = CONVERT(c,(bits == 0) ? palZeroTransparent : opaqueColor); + adr++; + } + } + break; + } + case TEXMODE_I8: + { + for(int j=0;j>14)] + ((paletteAddress + (offset)*2)&0x3FFF) ) ) + + u16* slot1; + u32* map = (u32*)ms.items[0].ptr; + u32 limit = ms.items[0].len<<2; + u32 d = 0; + if ( (texcache[tx].frm & 0xc000) == 0x8000) + // texel are in slot 2 + slot1=(u16*)&ARM9Mem.texInfo.textureSlotAddr[1][((texcache[tx].frm & 0x3FFF)<<2)+0x010000]; + else + slot1=(u16*)&ARM9Mem.texInfo.textureSlotAddr[1][(texcache[tx].frm & 0x3FFF)<<2]; + + u16 yTmpSize = (texcache[tx].sizeY>>2); + u16 xTmpSize = (texcache[tx].sizeX>>2); + + //this is flagged whenever a 4x4 overruns its slot. + //i am guessing we just generate black in that case + bool dead = false; + + for (int y = 0; y < yTmpSize; y ++) + { + u32 tmpPos[4]={(y<<2)*texcache[tx].sizeX,((y<<2)+1)*texcache[tx].sizeX, + ((y<<2)+2)*texcache[tx].sizeX,((y<<2)+3)*texcache[tx].sizeX}; + for (int x = 0; x < xTmpSize; x ++, d++) + { + if(d >= limit) + dead = true; + + if(dead) { + for (int sy = 0; sy < 4; sy++) + { + u32 currentPos = (x<<2) + tmpPos[sy]; + dwdst[currentPos] = dwdst[currentPos+1] = dwdst[currentPos+2] = dwdst[currentPos+3] = 0; + } + continue; + } + + u32 currBlock = map[d]; + u16 pal1 = slot1[d]; + u16 pal1offset = (pal1 & 0x3FFF)<<1; + u8 mode = pal1>>14; + u32 tmp_col[4]; + + tmp_col[0]=RGB16TO32(PAL4X4(pal1offset),255); + tmp_col[1]=RGB16TO32(PAL4X4(pal1offset+1),255); + + switch (mode) + { + case 0: + tmp_col[2]=RGB16TO32(PAL4X4(pal1offset+2),255); + tmp_col[3]=RGB16TO32(0x7FFF,0); + break; + case 1: + tmp_col[2]=(((tmp_col[0]&0xFF)+(tmp_col[1]&0xff))>>1)| + (((tmp_col[0]&(0xFF<<8))+(tmp_col[1]&(0xFF<<8)))>>1)| + (((tmp_col[0]&(0xFF<<16))+(tmp_col[1]&(0xFF<<16)))>>1)| + (0xff<<24); + tmp_col[3]=RGB16TO32(0x7FFF,0); + break; + case 2: + tmp_col[2]=RGB16TO32(PAL4X4(pal1offset+2),255); + tmp_col[3]=RGB16TO32(PAL4X4(pal1offset+3),255); + break; + case 3: + { + u32 red1, red2; + u32 green1, green2; + u32 blue1, blue2; + u16 tmp1, tmp2; + + red1=tmp_col[0]&0xff; + green1=(tmp_col[0]>>8)&0xff; + blue1=(tmp_col[0]>>16)&0xff; + red2=tmp_col[1]&0xff; + green2=(tmp_col[1]>>8)&0xff; + blue2=(tmp_col[1]>>16)&0xff; + + tmp1=((red1*5+red2*3)>>6)| + (((green1*5+green2*3)>>6)<<5)| + (((blue1*5+blue2*3)>>6)<<10); + tmp2=((red2*5+red1*3)>>6)| + (((green2*5+green1*3)>>6)<<5)| + (((blue2*5+blue1*3)>>6)<<10); + + tmp_col[2]=RGB16TO32(tmp1,255); + tmp_col[3]=RGB16TO32(tmp2,255); + break; + } + } + + if(TEXFORMAT==TexFormat_15bpp) + { + for(int i=0;i<4;i++) + { + tmp_col[i] >>= 3; + tmp_col[i] &= 0x1F1F1F1F; + } + } + + //TODO - this could be more precise for 32bpp mode (run it through the color separation table) + + //set all 16 texels + for (int sy = 0; sy < 4; sy++) + { + // Texture offset + u32 currentPos = (x<<2) + tmpPos[sy]; + u8 currRow = (u8)((currBlock>>(sy<<3))&0xFF); + + dwdst[currentPos] = tmp_col[currRow&3]; + dwdst[currentPos+1] = tmp_col[(currRow>>2)&3]; + dwdst[currentPos+2] = tmp_col[(currRow>>4)&3]; + dwdst[currentPos+3] = tmp_col[(currRow>>6)&3]; + } + + + } + } + + + break; + } + case TEXMODE_A5I3: + { + for(int j=0;j>3); + if(TEXFORMAT == TexFormat_15bpp) + *dwdst++ = RGB15TO5555(c,alpha); + else + *dwdst++ = RGB15TO32(c,material_5bit_to_8bit[alpha]); + adr++; + } + } + break; + } + case TEXMODE_16BPP: + { + for(int j=0;j>1; + for(u32 x = 0; x < len; ++x) + { + u16 c = map[x]; + int alpha = ((c&0x8000)?opaqueColor:0); + *dwdst++ = CONVERT(c&0x7FFF,alpha); + } + } + break; + } + } + + if(TexCache_BindTextureData != 0) + TexCache_BindTextureData(tx,TexCache_texMAP); + +#ifdef DO_DEBUG_DUMP_TEXTURE + DebugDumpTexture(tx); +#endif + +} + +void TexCache_Reset() +{ + if(TexCache_texMAP == NULL) TexCache_texMAP = new u8[1024*2048*4]; + if(texcache == NULL) texcache = new TextureCache[MAX_TEXTURE+1]; + + memset(texcache,0,sizeof(TextureCache[MAX_TEXTURE+1])); + + texcache_start=0; + texcache_stop=MAX_TEXTURE<<1; +} + +TextureCache* TexCache_Curr() +{ + if(lastTexture == -1) + return NULL; + else return &texcache[lastTexture]; +} + +void TexCache_Invalidate() +{ + //well, this is a very blunt instrument. + //lets just flag all the textures as invalid. + for(int i=0;i(u32 format, u32 texpal); +template void TexCache_SetTexture(u32 format, u32 texpal); diff --git a/desmume/src/texcache.h b/src/texcache.h similarity index 90% rename from desmume/src/texcache.h rename to src/texcache.h index d51de2f0f..8d7f2c48a 100644 --- a/desmume/src/texcache.h +++ b/src/texcache.h @@ -10,9 +10,11 @@ enum TexCache_TexFormat }; #define MAX_TEXTURE 500 - - -struct CACHE_ALIGN TextureCache +#ifndef NOSSE2 +struct ALIGN(16) TextureCache +#else +struct ALIGN(8) TextureCache +#endif { u32 id; u32 frm; @@ -31,6 +33,7 @@ struct CACHE_ALIGN TextureCache //set if this texture is suspected be invalid due to a vram reconfigure bool suspectedInvalid; + }; extern TextureCache *texcache; diff --git a/desmume/src/thumb_instructions.cpp b/src/thumb_instructions.cpp similarity index 100% rename from desmume/src/thumb_instructions.cpp rename to src/thumb_instructions.cpp diff --git a/desmume/src/thumb_instructions.h b/src/thumb_instructions.h similarity index 97% rename from desmume/src/thumb_instructions.h rename to src/thumb_instructions.h index 08db2521c..1aa89fb76 100644 --- a/desmume/src/thumb_instructions.h +++ b/src/thumb_instructions.h @@ -1,31 +1,31 @@ -/* Copyright (C) 2006 yopyop - yopyop156@ifrance.com - yopyop156.ifrance.com - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#ifndef THUMB_INSTRUCTIONS_H -#define THUMB_INSTRUCTIONS_H - -#include "armcpu.h" - -extern u32 (FASTCALL* thumb_instructions_set_0[1024])(); -extern u32 (FASTCALL* thumb_instructions_set_1[1024])(); - -#endif - +/* Copyright (C) 2006 yopyop + yopyop156@ifrance.com + yopyop156.ifrance.com + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#ifndef THUMB_INSTRUCTIONS_H +#define THUMB_INSTRUCTIONS_H + +#include "armcpu.h" + +extern u32 (FASTCALL* thumb_instructions_set_0[1024])(); +extern u32 (FASTCALL* thumb_instructions_set_1[1024])(); + +#endif + diff --git a/desmume/src/thumb_tabdef.inc b/src/thumb_tabdef.inc similarity index 100% rename from desmume/src/thumb_tabdef.inc rename to src/thumb_tabdef.inc diff --git a/desmume/src/types.h b/src/types.h similarity index 72% rename from desmume/src/types.h rename to src/types.h index 07539035c..4290089d4 100644 --- a/desmume/src/types.h +++ b/src/types.h @@ -1,394 +1,386 @@ -/* Copyright (C) 2005 Guillaume Duhamel - Copyright (C) 2008-2009 DeSmuME team - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -*/ - -#ifndef TYPES_HPP -#define TYPES_HPP - -//todo - everyone will want to support this eventually, i suppose -#ifdef _MSC_VER -#include "config.h" -#endif - -#ifdef _MSC_VER -#define ENABLE_SSE -#define ENABLE_SSE2 -#endif - -#ifdef NOSSE -#undef ENABLE_SSE -#endif - -#ifdef NOSSE2 -#undef ENABLE_SSE2 -#endif - -#ifdef _WIN32 -#define strcasecmp(x,y) _stricmp(x,y) -#else -#define WINAPI -#endif - -#ifdef __GNUC__ -#include -#define MAX_PATH PATH_MAX -#endif - -#if defined(_MSC_VER) || defined(__INTEL_COMPILER) -#define ALIGN(X) __declspec(align(X)) -#elif __GNUC__ -#define ALIGN(X) __attribute__ ((aligned (X))) -#else -#define ALIGN(X) -#endif - -#define CACHE_ALIGN ALIGN(32) - -#ifndef FASTCALL -#ifdef __MINGW32__ -#define FASTCALL __attribute__((fastcall)) -#elif defined (__i386__) -#define FASTCALL __attribute__((regparm(3))) -#elif defined(_MSC_VER) || defined(__INTEL_COMPILER) -#define FASTCALL -#else -#define FASTCALL -#endif -#endif - -#ifdef _MSC_VER -#define _CDECL_ __cdecl -#else -#define _CDECL_ -#endif - -#ifndef INLINE -#if defined(_MSC_VER) || defined(__INTEL_COMPILER) -#define INLINE _inline -#else -#define INLINE inline -#endif -#endif - -#ifndef FORCEINLINE -#if defined(_MSC_VER) || defined(__INTEL_COMPILER) -#define FORCEINLINE __forceinline -#define MSC_FORCEINLINE __forceinline -#else -#define FORCEINLINE INLINE -#define MSC_FORCEINLINE -#endif -#endif - -#if defined(__LP64__) -typedef unsigned char u8; -typedef unsigned short u16; -typedef unsigned int u32; -typedef unsigned long long u64; - -typedef signed char s8; -typedef signed short s16; -typedef signed int s32; -typedef signed long long s64; -#else -typedef unsigned char u8; -typedef unsigned short u16; -typedef unsigned int u32; -#if defined(_MSC_VER) || defined(__INTEL_COMPILER) -typedef unsigned __int64 u64; -#else -typedef unsigned long long u64; -#endif - -typedef signed char s8; -typedef signed short s16; -typedef signed int s32; -#if defined(_MSC_VER) || defined(__INTEL_COMPILER) -typedef __int64 s64; -#else -typedef signed long long s64; -#endif -#endif - -typedef u8 uint8; -typedef u16 uint16; - -#ifndef OBJ_C -typedef u32 uint32; -#else -#define uint32 u32 //uint32 is defined in Leopard somewhere, avoid conflicts -#endif - -/*---------- GPU3D fixed-points types -----------*/ - -typedef s32 f32; -#define inttof32(n) ((n) << 12) -#define f32toint(n) ((n) >> 12) -#define floattof32(n) ((int32)((n) * (1 << 12))) -#define f32tofloat(n) (((float)(n)) / (float)(1<<12)) - -typedef s16 t16; -#define f32tot16(n) ((t16)(n >> 8)) -#define inttot16(n) ((n) << 4) -#define t16toint(n) ((n) >> 4) -#define floattot16(n) ((t16)((n) * (1 << 4))) -#define t16ofloat(n) (((float)(n)) / (float)(1<<4)) - -typedef s16 v16; -#define inttov16(n) ((n) << 12) -#define f32tov16(n) (n) -#define floattov16(n) ((v16)((n) * (1 << 12))) -#define v16toint(n) ((n) >> 12) -#define v16tofloat(n) (((float)(n)) / (float)(1<<12)) - -typedef s16 v10; -#define inttov10(n) ((n) << 9) -#define f32tov10(n) ((v10)(n >> 3)) -#define v10toint(n) ((n) >> 9) -#define floattov10(n) ((v10)((n) * (1 << 9))) -#define v10tofloat(n) (((float)(n)) / (float)(1<<9)) - -/*----------------------*/ - -#ifndef OBJ_C -typedef int BOOL; -#else -//apple also defines BOOL -typedef int desmume_BOOL; -#define BOOL desmume_BOOL -#endif - -#ifndef TRUE -#define TRUE 1 -#endif - -#ifndef FALSE -#define FALSE 0 -#endif - -#ifdef __BIG_ENDIAN__ -#ifndef WORDS_BIGENDIAN -#define WORDS_BIGENDIAN -#endif -#endif - -#ifdef WORDS_BIGENDIAN -# define LOCAL_BE -#else -# define LOCAL_LE -#endif - -/* little endian (ds' endianess) to local endianess convert macros */ -#ifdef LOCAL_BE /* local arch is big endian */ -# define LE_TO_LOCAL_16(x) ((((x)&0xff)<<8)|(((x)>>8)&0xff)) -# define LE_TO_LOCAL_32(x) ((((x)&0xff)<<24)|(((x)&0xff00)<<8)|(((x)>>8)&0xff00)|(((x)>>24)&0xff)) -# define LE_TO_LOCAL_64(x) ((((x)&0xff)<<56)|(((x)&0xff00)<<40)|(((x)&0xff0000)<<24)|(((x)&0xff000000)<<8)|(((x)>>8)&0xff000000)|(((x)>>24)&0xff00)|(((x)>>40)&0xff00)|(((x)>>56)&0xff)) -# define LOCAL_TO_LE_16(x) ((((x)&0xff)<<8)|(((x)>>8)&0xff)) -# define LOCAL_TO_LE_32(x) ((((x)&0xff)<<24)|(((x)&0xff00)<<8)|(((x)>>8)&0xff00)|(((x)>>24)&0xff)) -# define LOCAL_TO_LE_64(x) ((((x)&0xff)<<56)|(((x)&0xff00)<<40)|(((x)&0xff0000)<<24)|(((x)&0xff000000)<<8)|(((x)>>8)&0xff000000)|(((x)>>24)&0xff00)|(((x)>>40)&0xff00)|(((x)>>56)&0xff)) -#else /* local arch is little endian */ -# define LE_TO_LOCAL_16(x) (x) -# define LE_TO_LOCAL_32(x) (x) -# define LE_TO_LOCAL_64(x) (x) -# define LOCAL_TO_LE_16(x) (x) -# define LOCAL_TO_LE_32(x) (x) -# define LOCAL_TO_LE_64(x) (x) -#endif - -// kilobytes and megabytes macro -#define MB(x) ((x)*1024*1024) -#define KB(x) ((x)*1024) - -#define ARRAY_SIZE(a) (sizeof(a) / sizeof((a)[0])) - -#define CPU_STR(c) ((c==ARM9)?"ARM9":"ARM7") -typedef enum -{ - ARM9 = 0, - ARM7 = 1 -} cpu_id_t; - -///endian-flips count bytes. count should be even and nonzero. -inline void FlipByteOrder(u8 *src, u32 count) -{ - u8 *start=src; - u8 *end=src+count-1; - - if((count&1) || !count) return; /* This shouldn't happen. */ - - while(count--) - { - u8 tmp; - - tmp=*end; - *end=*start; - *start=tmp; - end--; - start++; - } -} - - - -inline u64 double_to_u64(double d) { - union { - u64 a; - double b; - } fuxor; - fuxor.b = d; - return fuxor.a; -} - -inline double u64_to_double(u64 u) { - union { - u64 a; - double b; - } fuxor; - fuxor.a = u; - return fuxor.b; -} - -inline u32 float_to_u32(float f) { - union { - u32 a; - float b; - } fuxor; - fuxor.b = f; - return fuxor.a; -} - -inline float u32_to_float(u32 u) { - union { - u32 a; - float b; - } fuxor; - fuxor.a = u; - return fuxor.b; -} - - -///stores a 32bit value into the provided byte array in guaranteed little endian form -inline void en32lsb(u8 *buf, u32 morp) -{ - buf[0]=morp; - buf[1]=morp>>8; - buf[2]=morp>>16; - buf[3]=morp>>24; -} - -inline void en16lsb(u8* buf, u16 morp) -{ - buf[0]=morp; - buf[1]=morp>>8; -} - -///unpacks a 64bit little endian value from the provided byte array into host byte order -inline u64 de64lsb(u8 *morp) -{ - return morp[0]|(morp[1]<<8)|(morp[2]<<16)|(morp[3]<<24)|((u64)morp[4]<<32)|((u64)morp[5]<<40)|((u64)morp[6]<<48)|((u64)morp[7]<<56); -} - -///unpacks a 32bit little endian value from the provided byte array into host byte order -inline u32 de32lsb(u8 *morp) -{ - return morp[0]|(morp[1]<<8)|(morp[2]<<16)|(morp[3]<<24); -} - -///unpacks a 16bit little endian value from the provided byte array into host byte order -inline u16 de16lsb(u8 *morp) -{ - return morp[0]|(morp[1]<<8); -} - -#ifndef ARRAY_SIZE -//taken from winnt.h -extern "C++" // templates cannot be declared to have 'C' linkage -template -char (*BLAHBLAHBLAH( UNALIGNED T (&)[N] ))[N]; - -#define ARRAY_SIZE(A) (sizeof(*BLAHBLAHBLAH(A))) -#endif - - -//fairly standard for loop macros -#define MACRODO1(TRICK,TODO) { const int X = TRICK; TODO; } -#define MACRODO2(X,TODO) { MACRODO1((X),TODO) MACRODO1(((X)+1),TODO) } -#define MACRODO4(X,TODO) { MACRODO2((X),TODO) MACRODO2(((X)+2),TODO) } -#define MACRODO8(X,TODO) { MACRODO4((X),TODO) MACRODO4(((X)+4),TODO) } -#define MACRODO16(X,TODO) { MACRODO8((X),TODO) MACRODO8(((X)+8),TODO) } -#define MACRODO32(X,TODO) { MACRODO16((X),TODO) MACRODO16(((X)+16),TODO) } -#define MACRODO64(X,TODO) { MACRODO32((X),TODO) MACRODO32(((X)+32),TODO) } -#define MACRODO128(X,TODO) { MACRODO64((X),TODO) MACRODO64(((X)+64),TODO) } -#define MACRODO256(X,TODO) { MACRODO128((X),TODO) MACRODO128(((X)+128),TODO) } - -//this one lets you loop any number of times (as long as N<256) -#define MACRODO_N(N,TODO) {\ - if((N)&0x100) MACRODO256(0,TODO); \ - if((N)&0x080) MACRODO128((N)&(0x100),TODO); \ - if((N)&0x040) MACRODO64((N)&(0x100|0x080),TODO); \ - if((N)&0x020) MACRODO32((N)&(0x100|0x080|0x040),TODO); \ - if((N)&0x010) MACRODO16((N)&(0x100|0x080|0x040|0x020),TODO); \ - if((N)&0x008) MACRODO8((N)&(0x100|0x080|0x040|0x020|0x010),TODO); \ - if((N)&0x004) MACRODO4((N)&(0x100|0x080|0x040|0x020|0x010|0x008),TODO); \ - if((N)&0x002) MACRODO2((N)&(0x100|0x080|0x040|0x020|0x010|0x008|0x004),TODO); \ - if((N)&0x001) MACRODO1((N)&(0x100|0x080|0x040|0x020|0x010|0x008|0x004|0x002),TODO); \ -} - -//--------------------------- -//Binary constant generator macro By Tom Torfs - donated to the public domain - -//turn a numeric literal into a hex constant -//(avoids problems with leading zeroes) -//8-bit constants max value 0x11111111, always fits in unsigned long -#define HEX__(n) 0x##n##LU - -//8-bit conversion function -#define B8__(x) ((x&0x0000000FLU)?1:0) \ -+((x&0x000000F0LU)?2:0) \ -+((x&0x00000F00LU)?4:0) \ -+((x&0x0000F000LU)?8:0) \ -+((x&0x000F0000LU)?16:0) \ -+((x&0x00F00000LU)?32:0) \ -+((x&0x0F000000LU)?64:0) \ -+((x&0xF0000000LU)?128:0) - -//for upto 8-bit binary constants -#define B8(d) ((unsigned char)B8__(HEX__(d))) - -// for upto 16-bit binary constants, MSB first -#define B16(dmsb,dlsb) (((unsigned short)B8(dmsb)<<8) \ -+ B8(dlsb)) - -// for upto 32-bit binary constants, MSB first */ -#define B32(dmsb,db2,db3,dlsb) (((unsigned long)B8(dmsb)<<24) \ -+ ((unsigned long)B8(db2)<<16) \ -+ ((unsigned long)B8(db3)<<8) \ -+ B8(dlsb)) - -//Sample usage: -//B8(01010101) = 85 -//B16(10101010,01010101) = 43605 -//B32(10000000,11111111,10101010,01010101) = 2164238933 -//--------------------------- - -#ifndef CTASSERT -#define CTASSERT(x) typedef char __assert ## y[(x) ? 1 : -1] -#endif - -#endif +/* Copyright (C) 2005 Guillaume Duhamel + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#ifndef TYPES_HPP +#define TYPES_HPP + +//todo - everyone will want to support this eventually, i suppose +#ifdef _MSC_VER +#include "config.h" +#endif + +#ifndef _MSC_VER +#define NOSSE2 +#endif + +#define DESMUME_NAME "DeSmuME" + +#ifdef _WIN64 +#define DESMUME_PLATFORM_STRING " x64" +#else +#ifdef _WIN32 +#define DESMUME_PLATFORM_STRING " x86" +#else +#define DESMUME_PLATFORM_STRING "" +#endif +#endif + +#ifdef NOSSE2 +#define DESMUME_CPUEXT_STRING " NOSSE2" +#else +#define DESMUME_CPUEXT_STRING "" +#endif + +#ifdef DEVELOPER +#define DESMUME_FEATURE_STRING " dev+" +#else +#define DESMUME_FEATURE_STRING "" +#endif + +#ifdef DEBUG +#define DESMUME_SUBVERSION_STRING " debug" +#elif defined(PUBLIC_RELEASE) +#define DESMUME_SUBVERSION_STRING "" +#else +#define DESMUME_SUBVERSION_STRING " WIP" // " svn" +#endif + +#ifdef __INTEL_COMPILER +#define DESMUME_COMPILER " (Intel) " +#define DESMUME_COMPILER_DETAIL " (Intel) " +#elif defined(_MSC_VER) +#define DESMUME_COMPILER "" +#define DESMUME_COMPILER_DETAIL " msvc " _Py_STRINGIZE(_MSC_VER) +#define _Py_STRINGIZE(X) _Py_STRINGIZE1((X)) +#define _Py_STRINGIZE1(X) _Py_STRINGIZE2 ## X +#define _Py_STRINGIZE2(X) #X +//re: http://72.14.203.104/search?q=cache:HG-okth5NGkJ:mail.python.org/pipermail/python-checkins/2002-November/030704.html+_msc_ver+compiler+version+string&hl=en&gl=us&ct=clnk&cd=5 +#else +// TODO: make for others compilers +#define DESMUME_COMPILER "" +#define DESMUME_COMPILER_DETAIL "" +#endif + +#define DESMUME_VERSION_NUMERIC 90300 +#define DESMUME_VERSION_STRING " " "0.9.2+" DESMUME_SUBVERSION_STRING DESMUME_FEATURE_STRING DESMUME_PLATFORM_STRING DESMUME_CPUEXT_STRING DESMUME_COMPILER +#define DESMUME_NAME_AND_VERSION " " DESMUME_NAME DESMUME_VERSION_STRING + +#ifdef _WIN32 +#define strcasecmp(x,y) _stricmp(x,y) +#else +#define WINAPI +#endif + +#ifdef __GNUC__ +#include +#define MAX_PATH PATH_MAX +#endif + +#if defined(_MSC_VER) || defined(__INTEL_COMPILER) +#define ALIGN(X) __declspec(align(X)) +#elif __GNUC__ +#define ALIGN(X) __attribute__ ((aligned (X))) +#else +#define ALIGN(X) +#endif + +#define CACHE_ALIGN ALIGN(32) + +#ifndef FASTCALL +#ifdef __MINGW32__ +#define FASTCALL __attribute__((fastcall)) +#elif defined (__i386__) +#define FASTCALL __attribute__((regparm(3))) +#elif defined(_MSC_VER) || defined(__INTEL_COMPILER) +#define FASTCALL +#else +#define FASTCALL +#endif +#endif + +#ifdef _MSC_VER +#define _CDECL_ __cdecl +#else +#define _CDECL_ +#endif + +#ifndef INLINE +#if defined(_MSC_VER) || defined(__INTEL_COMPILER) +#define INLINE _inline +#else +#define INLINE inline +#endif +#endif + +#ifndef FORCEINLINE +#if defined(_MSC_VER) || defined(__INTEL_COMPILER) +#define FORCEINLINE __forceinline +#define MSC_FORCEINLINE __forceinline +#else +#define FORCEINLINE INLINE +#define MSC_FORCEINLINE +#endif +#endif + +//#ifndef _PREFETCH +//#if (defined(_MSC_VER) || defined(__INTEL_COMPILER)) && !defined(NOSSE2) +//#include +//#include +//#define _PREFETCH(X) _mm_prefetch((char*)(X),_MM_HINT_T0); +//#define _PREFETCHNTA(X) _mm_prefetch((char*)(X),_MM_HINT_NTA); +//#else +#define _PREFETCH(X) {} +#define _PREFETCHNTA(X) {} +//#endif +//#endif + + + +#if defined(__LP64__) +typedef unsigned char u8; +typedef unsigned short u16; +typedef unsigned int u32; +typedef unsigned long u64; + +typedef signed char s8; +typedef signed short s16; +typedef signed int s32; +typedef signed long long s64; +#else +typedef unsigned char u8; +typedef unsigned short u16; +typedef unsigned int u32; +#if defined(_MSC_VER) || defined(__INTEL_COMPILER) +typedef unsigned __int64 u64; +#else +typedef unsigned long long u64; +#endif + +typedef signed char s8; +typedef signed short s16; +typedef signed int s32; +#if defined(_MSC_VER) || defined(__INTEL_COMPILER) +typedef __int64 s64; +#else +typedef signed long long s64; +#endif +#endif + +typedef u8 uint8; +typedef u16 uint16; + +#ifndef OBJ_C +typedef u32 uint32; +#else +#define uint32 u32 //uint32 is defined in Leopard somewhere, avoid conflicts +#endif + +/*---------- GPU3D fixed-points types -----------*/ + +typedef s32 f32; +#define inttof32(n) ((n) << 12) +#define f32toint(n) ((n) >> 12) +#define floattof32(n) ((int32)((n) * (1 << 12))) +#define f32tofloat(n) (((float)(n)) / (float)(1<<12)) + +typedef s16 t16; +#define f32tot16(n) ((t16)(n >> 8)) +#define inttot16(n) ((n) << 4) +#define t16toint(n) ((n) >> 4) +#define floattot16(n) ((t16)((n) * (1 << 4))) +#define t16ofloat(n) (((float)(n)) / (float)(1<<4)) + +typedef s16 v16; +#define inttov16(n) ((n) << 12) +#define f32tov16(n) (n) +#define floattov16(n) ((v16)((n) * (1 << 12))) +#define v16toint(n) ((n) >> 12) +#define v16tofloat(n) (((float)(n)) / (float)(1<<12)) + +typedef s16 v10; +#define inttov10(n) ((n) << 9) +#define f32tov10(n) ((v10)(n >> 3)) +#define v10toint(n) ((n) >> 9) +#define floattov10(n) ((v10)((n) * (1 << 9))) +#define v10tofloat(n) (((float)(n)) / (float)(1<<9)) + +/*----------------------*/ + +#ifndef OBJ_C +typedef int BOOL; +#else +//apple also defines BOOL +typedef int desmume_BOOL; +#define BOOL desmume_BOOL +#endif + +#ifndef TRUE +#define TRUE 1 +#endif + +#ifndef FALSE +#define FALSE 0 +#endif + +#ifdef __BIG_ENDIAN__ +#ifndef WORDS_BIGENDIAN +#define WORDS_BIGENDIAN +#endif +#endif + +#ifdef WORDS_BIGENDIAN +# define LOCAL_BE +#else +# define LOCAL_LE +#endif + +/* little endian (ds' endianess) to local endianess convert macros */ +#ifdef LOCAL_BE /* local arch is big endian */ +# define LE_TO_LOCAL_16(x) ((((x)&0xff)<<8)|(((x)>>8)&0xff)) +# define LE_TO_LOCAL_32(x) ((((x)&0xff)<<24)|(((x)&0xff00)<<8)|(((x)>>8)&0xff00)|(((x)>>24)&0xff)) +# define LE_TO_LOCAL_64(x) ((((x)&0xff)<<56)|(((x)&0xff00)<<40)|(((x)&0xff0000)<<24)|(((x)&0xff000000)<<8)|(((x)>>8)&0xff000000)|(((x)>>24)&0xff00)|(((x)>>40)&0xff00)|(((x)>>56)&0xff)) +# define LOCAL_TO_LE_16(x) ((((x)&0xff)<<8)|(((x)>>8)&0xff)) +# define LOCAL_TO_LE_32(x) ((((x)&0xff)<<24)|(((x)&0xff00)<<8)|(((x)>>8)&0xff00)|(((x)>>24)&0xff)) +# define LOCAL_TO_LE_64(x) ((((x)&0xff)<<56)|(((x)&0xff00)<<40)|(((x)&0xff0000)<<24)|(((x)&0xff000000)<<8)|(((x)>>8)&0xff000000)|(((x)>>24)&0xff00)|(((x)>>40)&0xff00)|(((x)>>56)&0xff)) +#else /* local arch is little endian */ +# define LE_TO_LOCAL_16(x) (x) +# define LE_TO_LOCAL_32(x) (x) +# define LE_TO_LOCAL_64(x) (x) +# define LOCAL_TO_LE_16(x) (x) +# define LOCAL_TO_LE_32(x) (x) +# define LOCAL_TO_LE_64(x) (x) +#endif + +// kilobytes and megabytes macro +#define MB(x) ((x)*1024*1024) +#define KB(x) ((x)*1024) + +#define ARRAY_SIZE(a) (sizeof(a) / sizeof((a)[0])) + +#define CPU_STR(c) ((c==ARM9)?"ARM9":"ARM7") +typedef enum +{ + ARM9 = 0, + ARM7 = 1 +} cpu_id_t; + +///endian-flips count bytes. count should be even and nonzero. +inline void FlipByteOrder(u8 *src, u32 count) +{ + u8 *start=src; + u8 *end=src+count-1; + + if((count&1) || !count) return; /* This shouldn't happen. */ + + while(count--) + { + u8 tmp; + + tmp=*end; + *end=*start; + *start=tmp; + end--; + start++; + } +} + + + +inline u64 double_to_u64(double d) { + union { + u64 a; + double b; + } fuxor; + fuxor.b = d; + return fuxor.a; +} + +inline double u64_to_double(u64 u) { + union { + u64 a; + double b; + } fuxor; + fuxor.a = u; + return fuxor.b; +} + +inline u32 float_to_u32(float f) { + union { + u32 a; + float b; + } fuxor; + fuxor.b = f; + return fuxor.a; +} + +inline float u32_to_float(u32 u) { + union { + u32 a; + float b; + } fuxor; + fuxor.a = u; + return fuxor.b; +} + + +///stores a 32bit value into the provided byte array in guaranteed little endian form +inline void en32lsb(u8 *buf, u32 morp) +{ + buf[0]=morp; + buf[1]=morp>>8; + buf[2]=morp>>16; + buf[3]=morp>>24; +} + +inline void en16lsb(u8* buf, u16 morp) +{ + buf[0]=morp; + buf[1]=morp>>8; +} + +///unpacks a 64bit little endian value from the provided byte array into host byte order +inline u64 de64lsb(u8 *morp) +{ + return morp[0]|(morp[1]<<8)|(morp[2]<<16)|(morp[3]<<24)|((u64)morp[4]<<32)|((u64)morp[5]<<40)|((u64)morp[6]<<48)|((u64)morp[7]<<56); +} + +///unpacks a 32bit little endian value from the provided byte array into host byte order +inline u32 de32lsb(u8 *morp) +{ + return morp[0]|(morp[1]<<8)|(morp[2]<<16)|(morp[3]<<24); +} + +///unpacks a 16bit little endian value from the provided byte array into host byte order +inline u16 de16lsb(u8 *morp) +{ + return morp[0]|(morp[1]<<8); +} + +#ifndef ARRAY_SIZE +//taken from winnt.h +extern "C++" // templates cannot be declared to have 'C' linkage +template +char (*BLAHBLAHBLAH( UNALIGNED T (&)[N] ))[N]; + +#define ARRAY_SIZE(A) (sizeof(*BLAHBLAHBLAH(A))) +#endif + + + +#endif diff --git a/desmume/src/utils/ConvertUTF.c b/src/utils/ConvertUTF.c similarity index 100% rename from desmume/src/utils/ConvertUTF.c rename to src/utils/ConvertUTF.c diff --git a/desmume/src/utils/ConvertUTF.h b/src/utils/ConvertUTF.h similarity index 97% rename from desmume/src/utils/ConvertUTF.h rename to src/utils/ConvertUTF.h index e26491536..bff37f5bc 100644 --- a/desmume/src/utils/ConvertUTF.h +++ b/src/utils/ConvertUTF.h @@ -1,149 +1,149 @@ -/* - * Copyright 2001-2004 Unicode, Inc. - * - * Disclaimer - * - * This source code is provided as is by Unicode, Inc. No claims are - * made as to fitness for any particular purpose. No warranties of any - * kind are expressed or implied. The recipient agrees to determine - * applicability of information provided. If this file has been - * purchased on magnetic or optical media from Unicode, Inc., the - * sole remedy for any claim will be exchange of defective media - * within 90 days of receipt. - * - * Limitations on Rights to Redistribute This Code - * - * Unicode, Inc. hereby grants the right to freely use the information - * supplied in this file in the creation of products supporting the - * Unicode Standard, and to make copies of this file in any form - * for internal or external distribution as long as this notice - * remains attached. - */ - -/* --------------------------------------------------------------------- - - Conversions between UTF32, UTF-16, and UTF-8. Header file. - - Several funtions are included here, forming a complete set of - conversions between the three formats. UTF-7 is not included - here, but is handled in a separate source file. - - Each of these routines takes pointers to input buffers and output - buffers. The input buffers are const. - - Each routine converts the text between *sourceStart and sourceEnd, - putting the result into the buffer between *targetStart and - targetEnd. Note: the end pointers are *after* the last item: e.g. - *(sourceEnd - 1) is the last item. - - The return result indicates whether the conversion was successful, - and if not, whether the problem was in the source or target buffers. - (Only the first encountered problem is indicated.) - - After the conversion, *sourceStart and *targetStart are both - updated to point to the end of last text successfully converted in - the respective buffers. - - Input parameters: - sourceStart - pointer to a pointer to the source buffer. - The contents of this are modified on return so that - it points at the next thing to be converted. - targetStart - similarly, pointer to pointer to the target buffer. - sourceEnd, targetEnd - respectively pointers to the ends of the - two buffers, for overflow checking only. - - These conversion functions take a ConversionFlags argument. When this - flag is set to strict, both irregular sequences and isolated surrogates - will cause an error. When the flag is set to lenient, both irregular - sequences and isolated surrogates are converted. - - Whether the flag is strict or lenient, all illegal sequences will cause - an error return. This includes sequences such as: , , - or in UTF-8, and values above 0x10FFFF in UTF-32. Conformant code - must check for illegal sequences. - - When the flag is set to lenient, characters over 0x10FFFF are converted - to the replacement character; otherwise (when the flag is set to strict) - they constitute an error. - - Output parameters: - The value "sourceIllegal" is returned from some routines if the input - sequence is malformed. When "sourceIllegal" is returned, the source - value will point to the illegal value that caused the problem. E.g., - in UTF-8 when a sequence is malformed, it points to the start of the - malformed sequence. - - Author: Mark E. Davis, 1994. - Rev History: Rick McGowan, fixes & updates May 2001. - Fixes & updates, Sept 2001. - ------------------------------------------------------------------------- */ - -/* --------------------------------------------------------------------- - The following 4 definitions are compiler-specific. - The C standard does not guarantee that wchar_t has at least - 16 bits, so wchar_t is no less portable than unsigned short! - All should be unsigned values to avoid sign extension during - bit mask & shift operations. ------------------------------------------------------------------------- */ - -typedef unsigned long UTF32; /* at least 32 bits */ -typedef unsigned short UTF16; /* at least 16 bits */ -typedef unsigned char UTF8; /* typically 8 bits */ -typedef unsigned char Boolean; /* 0 or 1 */ - -/* Some fundamental constants */ -#define UNI_REPLACEMENT_CHAR (UTF32)0x0000FFFD -#define UNI_MAX_BMP (UTF32)0x0000FFFF -#define UNI_MAX_UTF16 (UTF32)0x0010FFFF -#define UNI_MAX_UTF32 (UTF32)0x7FFFFFFF -#define UNI_MAX_LEGAL_UTF32 (UTF32)0x0010FFFF - -typedef enum { - conversionOK, /* conversion successful */ - sourceExhausted, /* partial character in source, but hit end */ - targetExhausted, /* insuff. room in target for conversion */ - sourceIllegal /* source sequence is illegal/malformed */ -} ConversionResult; - -typedef enum { - strictConversion = 0, - lenientConversion -} ConversionFlags; - -/* This is for C++ and does no harm in C */ -#ifdef __cplusplus -extern "C" { -#endif - -ConversionResult ConvertUTF8toUTF16 ( - const UTF8** sourceStart, const UTF8* sourceEnd, - UTF16** targetStart, UTF16* targetEnd, ConversionFlags flags); - -ConversionResult ConvertUTF16toUTF8 ( - const UTF16** sourceStart, const UTF16* sourceEnd, - UTF8** targetStart, UTF8* targetEnd, ConversionFlags flags); - -ConversionResult ConvertUTF8toUTF32 ( - const UTF8** sourceStart, const UTF8* sourceEnd, - UTF32** targetStart, UTF32* targetEnd, ConversionFlags flags); - -ConversionResult ConvertUTF32toUTF8 ( - const UTF32** sourceStart, const UTF32* sourceEnd, - UTF8** targetStart, UTF8* targetEnd, ConversionFlags flags); - -ConversionResult ConvertUTF16toUTF32 ( - const UTF16** sourceStart, const UTF16* sourceEnd, - UTF32** targetStart, UTF32* targetEnd, ConversionFlags flags); - -ConversionResult ConvertUTF32toUTF16 ( - const UTF32** sourceStart, const UTF32* sourceEnd, - UTF16** targetStart, UTF16* targetEnd, ConversionFlags flags); - -Boolean isLegalUTF8Sequence(const UTF8 *source, const UTF8 *sourceEnd); - -#ifdef __cplusplus -} -#endif - -/* --------------------------------------------------------------------- */ +/* + * Copyright 2001-2004 Unicode, Inc. + * + * Disclaimer + * + * This source code is provided as is by Unicode, Inc. No claims are + * made as to fitness for any particular purpose. No warranties of any + * kind are expressed or implied. The recipient agrees to determine + * applicability of information provided. If this file has been + * purchased on magnetic or optical media from Unicode, Inc., the + * sole remedy for any claim will be exchange of defective media + * within 90 days of receipt. + * + * Limitations on Rights to Redistribute This Code + * + * Unicode, Inc. hereby grants the right to freely use the information + * supplied in this file in the creation of products supporting the + * Unicode Standard, and to make copies of this file in any form + * for internal or external distribution as long as this notice + * remains attached. + */ + +/* --------------------------------------------------------------------- + + Conversions between UTF32, UTF-16, and UTF-8. Header file. + + Several funtions are included here, forming a complete set of + conversions between the three formats. UTF-7 is not included + here, but is handled in a separate source file. + + Each of these routines takes pointers to input buffers and output + buffers. The input buffers are const. + + Each routine converts the text between *sourceStart and sourceEnd, + putting the result into the buffer between *targetStart and + targetEnd. Note: the end pointers are *after* the last item: e.g. + *(sourceEnd - 1) is the last item. + + The return result indicates whether the conversion was successful, + and if not, whether the problem was in the source or target buffers. + (Only the first encountered problem is indicated.) + + After the conversion, *sourceStart and *targetStart are both + updated to point to the end of last text successfully converted in + the respective buffers. + + Input parameters: + sourceStart - pointer to a pointer to the source buffer. + The contents of this are modified on return so that + it points at the next thing to be converted. + targetStart - similarly, pointer to pointer to the target buffer. + sourceEnd, targetEnd - respectively pointers to the ends of the + two buffers, for overflow checking only. + + These conversion functions take a ConversionFlags argument. When this + flag is set to strict, both irregular sequences and isolated surrogates + will cause an error. When the flag is set to lenient, both irregular + sequences and isolated surrogates are converted. + + Whether the flag is strict or lenient, all illegal sequences will cause + an error return. This includes sequences such as: , , + or in UTF-8, and values above 0x10FFFF in UTF-32. Conformant code + must check for illegal sequences. + + When the flag is set to lenient, characters over 0x10FFFF are converted + to the replacement character; otherwise (when the flag is set to strict) + they constitute an error. + + Output parameters: + The value "sourceIllegal" is returned from some routines if the input + sequence is malformed. When "sourceIllegal" is returned, the source + value will point to the illegal value that caused the problem. E.g., + in UTF-8 when a sequence is malformed, it points to the start of the + malformed sequence. + + Author: Mark E. Davis, 1994. + Rev History: Rick McGowan, fixes & updates May 2001. + Fixes & updates, Sept 2001. + +------------------------------------------------------------------------ */ + +/* --------------------------------------------------------------------- + The following 4 definitions are compiler-specific. + The C standard does not guarantee that wchar_t has at least + 16 bits, so wchar_t is no less portable than unsigned short! + All should be unsigned values to avoid sign extension during + bit mask & shift operations. +------------------------------------------------------------------------ */ + +typedef unsigned long UTF32; /* at least 32 bits */ +typedef unsigned short UTF16; /* at least 16 bits */ +typedef unsigned char UTF8; /* typically 8 bits */ +typedef unsigned char Boolean; /* 0 or 1 */ + +/* Some fundamental constants */ +#define UNI_REPLACEMENT_CHAR (UTF32)0x0000FFFD +#define UNI_MAX_BMP (UTF32)0x0000FFFF +#define UNI_MAX_UTF16 (UTF32)0x0010FFFF +#define UNI_MAX_UTF32 (UTF32)0x7FFFFFFF +#define UNI_MAX_LEGAL_UTF32 (UTF32)0x0010FFFF + +typedef enum { + conversionOK, /* conversion successful */ + sourceExhausted, /* partial character in source, but hit end */ + targetExhausted, /* insuff. room in target for conversion */ + sourceIllegal /* source sequence is illegal/malformed */ +} ConversionResult; + +typedef enum { + strictConversion = 0, + lenientConversion +} ConversionFlags; + +/* This is for C++ and does no harm in C */ +#ifdef __cplusplus +extern "C" { +#endif + +ConversionResult ConvertUTF8toUTF16 ( + const UTF8** sourceStart, const UTF8* sourceEnd, + UTF16** targetStart, UTF16* targetEnd, ConversionFlags flags); + +ConversionResult ConvertUTF16toUTF8 ( + const UTF16** sourceStart, const UTF16* sourceEnd, + UTF8** targetStart, UTF8* targetEnd, ConversionFlags flags); + +ConversionResult ConvertUTF8toUTF32 ( + const UTF8** sourceStart, const UTF8* sourceEnd, + UTF32** targetStart, UTF32* targetEnd, ConversionFlags flags); + +ConversionResult ConvertUTF32toUTF8 ( + const UTF32** sourceStart, const UTF32* sourceEnd, + UTF8** targetStart, UTF8* targetEnd, ConversionFlags flags); + +ConversionResult ConvertUTF16toUTF32 ( + const UTF16** sourceStart, const UTF16* sourceEnd, + UTF32** targetStart, UTF32* targetEnd, ConversionFlags flags); + +ConversionResult ConvertUTF32toUTF16 ( + const UTF32** sourceStart, const UTF32* sourceEnd, + UTF16** targetStart, UTF16* targetEnd, ConversionFlags flags); + +Boolean isLegalUTF8Sequence(const UTF8 *source, const UTF8 *sourceEnd); + +#ifdef __cplusplus +} +#endif + +/* --------------------------------------------------------------------- */ diff --git a/desmume/src/utils/decrypt/crc.cpp b/src/utils/decrypt/crc.cpp similarity index 98% rename from desmume/src/utils/decrypt/crc.cpp rename to src/utils/decrypt/crc.cpp index 30f62cf9e..e079ab28a 100644 --- a/desmume/src/utils/decrypt/crc.cpp +++ b/src/utils/decrypt/crc.cpp @@ -1,167 +1,167 @@ -//taken from ndstool -//http://devkitpro.cvs.sourceforge.net/viewvc/devkitpro/tools/nds/ndstool/source/crc.cpp?revision=1.2 - -/* crc.cpp - this file is part of DeSmuME - * - * Copyright (C) 2005-2006 Rafael Vuijk - * - * This file is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2, or (at your option) - * any later version. - * - * This file is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; see the file COPYING. If not, write to - * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -/* - Cyclic Redundancy Code (CRC) functions - by Rafael Vuijk (aka DarkFader) -*/ - -unsigned short ccitt16tab[] = -{ - 0x0000, 0x1021, 0x2042, 0x3063, 0x4084, 0x50A5, 0x60C6, 0x70E7, - 0x8108, 0x9129, 0xA14A, 0xB16B, 0xC18C, 0xD1AD, 0xE1CE, 0xF1EF, - 0x1231, 0x0210, 0x3273, 0x2252, 0x52B5, 0x4294, 0x72F7, 0x62D6, - 0x9339, 0x8318, 0xB37B, 0xA35A, 0xD3BD, 0xC39C, 0xF3FF, 0xE3DE, - 0x2462, 0x3443, 0x0420, 0x1401, 0x64E6, 0x74C7, 0x44A4, 0x5485, - 0xA56A, 0xB54B, 0x8528, 0x9509, 0xE5EE, 0xF5CF, 0xC5AC, 0xD58D, - 0x3653, 0x2672, 0x1611, 0x0630, 0x76D7, 0x66F6, 0x5695, 0x46B4, - 0xB75B, 0xA77A, 0x9719, 0x8738, 0xF7DF, 0xE7FE, 0xD79D, 0xC7BC, - 0x48C4, 0x58E5, 0x6886, 0x78A7, 0x0840, 0x1861, 0x2802, 0x3823, - 0xC9CC, 0xD9ED, 0xE98E, 0xF9AF, 0x8948, 0x9969, 0xA90A, 0xB92B, - 0x5AF5, 0x4AD4, 0x7AB7, 0x6A96, 0x1A71, 0x0A50, 0x3A33, 0x2A12, - 0xDBFD, 0xCBDC, 0xFBBF, 0xEB9E, 0x9B79, 0x8B58, 0xBB3B, 0xAB1A, - 0x6CA6, 0x7C87, 0x4CE4, 0x5CC5, 0x2C22, 0x3C03, 0x0C60, 0x1C41, - 0xEDAE, 0xFD8F, 0xCDEC, 0xDDCD, 0xAD2A, 0xBD0B, 0x8D68, 0x9D49, - 0x7E97, 0x6EB6, 0x5ED5, 0x4EF4, 0x3E13, 0x2E32, 0x1E51, 0x0E70, - 0xFF9F, 0xEFBE, 0xDFDD, 0xCFFC, 0xBF1B, 0xAF3A, 0x9F59, 0x8F78, - 0x9188, 0x81A9, 0xB1CA, 0xA1EB, 0xD10C, 0xC12D, 0xF14E, 0xE16F, - 0x1080, 0x00A1, 0x30C2, 0x20E3, 0x5004, 0x4025, 0x7046, 0x6067, - 0x83B9, 0x9398, 0xA3FB, 0xB3DA, 0xC33D, 0xD31C, 0xE37F, 0xF35E, - 0x02B1, 0x1290, 0x22F3, 0x32D2, 0x4235, 0x5214, 0x6277, 0x7256, - 0xB5EA, 0xA5CB, 0x95A8, 0x8589, 0xF56E, 0xE54F, 0xD52C, 0xC50D, - 0x34E2, 0x24C3, 0x14A0, 0x0481, 0x7466, 0x6447, 0x5424, 0x4405, - 0xA7DB, 0xB7FA, 0x8799, 0x97B8, 0xE75F, 0xF77E, 0xC71D, 0xD73C, - 0x26D3, 0x36F2, 0x0691, 0x16B0, 0x6657, 0x7676, 0x4615, 0x5634, - 0xD94C, 0xC96D, 0xF90E, 0xE92F, 0x99C8, 0x89E9, 0xB98A, 0xA9AB, - 0x5844, 0x4865, 0x7806, 0x6827, 0x18C0, 0x08E1, 0x3882, 0x28A3, - 0xCB7D, 0xDB5C, 0xEB3F, 0xFB1E, 0x8BF9, 0x9BD8, 0xABBB, 0xBB9A, - 0x4A75, 0x5A54, 0x6A37, 0x7A16, 0x0AF1, 0x1AD0, 0x2AB3, 0x3A92, - 0xFD2E, 0xED0F, 0xDD6C, 0xCD4D, 0xBDAA, 0xAD8B, 0x9DE8, 0x8DC9, - 0x7C26, 0x6C07, 0x5C64, 0x4C45, 0x3CA2, 0x2C83, 0x1CE0, 0x0CC1, - 0xEF1F, 0xFF3E, 0xCF5D, 0xDF7C, 0xAF9B, 0xBFBA, 0x8FD9, 0x9FF8, - 0x6E17, 0x7E36, 0x4E55, 0x5E74, 0x2E93, 0x3EB2, 0x0ED1, 0x1EF0 -}; - -unsigned short crc16tab[] = -{ - 0x0000, 0xC0C1, 0xC181, 0x0140, 0xC301, 0x03C0, 0x0280, 0xC241, - 0xC601, 0x06C0, 0x0780, 0xC741, 0x0500, 0xC5C1, 0xC481, 0x0440, - 0xCC01, 0x0CC0, 0x0D80, 0xCD41, 0x0F00, 0xCFC1, 0xCE81, 0x0E40, - 0x0A00, 0xCAC1, 0xCB81, 0x0B40, 0xC901, 0x09C0, 0x0880, 0xC841, - 0xD801, 0x18C0, 0x1980, 0xD941, 0x1B00, 0xDBC1, 0xDA81, 0x1A40, - 0x1E00, 0xDEC1, 0xDF81, 0x1F40, 0xDD01, 0x1DC0, 0x1C80, 0xDC41, - 0x1400, 0xD4C1, 0xD581, 0x1540, 0xD701, 0x17C0, 0x1680, 0xD641, - 0xD201, 0x12C0, 0x1380, 0xD341, 0x1100, 0xD1C1, 0xD081, 0x1040, - 0xF001, 0x30C0, 0x3180, 0xF141, 0x3300, 0xF3C1, 0xF281, 0x3240, - 0x3600, 0xF6C1, 0xF781, 0x3740, 0xF501, 0x35C0, 0x3480, 0xF441, - 0x3C00, 0xFCC1, 0xFD81, 0x3D40, 0xFF01, 0x3FC0, 0x3E80, 0xFE41, - 0xFA01, 0x3AC0, 0x3B80, 0xFB41, 0x3900, 0xF9C1, 0xF881, 0x3840, - 0x2800, 0xE8C1, 0xE981, 0x2940, 0xEB01, 0x2BC0, 0x2A80, 0xEA41, - 0xEE01, 0x2EC0, 0x2F80, 0xEF41, 0x2D00, 0xEDC1, 0xEC81, 0x2C40, - 0xE401, 0x24C0, 0x2580, 0xE541, 0x2700, 0xE7C1, 0xE681, 0x2640, - 0x2200, 0xE2C1, 0xE381, 0x2340, 0xE101, 0x21C0, 0x2080, 0xE041, - 0xA001, 0x60C0, 0x6180, 0xA141, 0x6300, 0xA3C1, 0xA281, 0x6240, - 0x6600, 0xA6C1, 0xA781, 0x6740, 0xA501, 0x65C0, 0x6480, 0xA441, - 0x6C00, 0xACC1, 0xAD81, 0x6D40, 0xAF01, 0x6FC0, 0x6E80, 0xAE41, - 0xAA01, 0x6AC0, 0x6B80, 0xAB41, 0x6900, 0xA9C1, 0xA881, 0x6840, - 0x7800, 0xB8C1, 0xB981, 0x7940, 0xBB01, 0x7BC0, 0x7A80, 0xBA41, - 0xBE01, 0x7EC0, 0x7F80, 0xBF41, 0x7D00, 0xBDC1, 0xBC81, 0x7C40, - 0xB401, 0x74C0, 0x7580, 0xB541, 0x7700, 0xB7C1, 0xB681, 0x7640, - 0x7200, 0xB2C1, 0xB381, 0x7340, 0xB101, 0x71C0, 0x7080, 0xB041, - 0x5000, 0x90C1, 0x9181, 0x5140, 0x9301, 0x53C0, 0x5280, 0x9241, - 0x9601, 0x56C0, 0x5780, 0x9741, 0x5500, 0x95C1, 0x9481, 0x5440, - 0x9C01, 0x5CC0, 0x5D80, 0x9D41, 0x5F00, 0x9FC1, 0x9E81, 0x5E40, - 0x5A00, 0x9AC1, 0x9B81, 0x5B40, 0x9901, 0x59C0, 0x5880, 0x9841, - 0x8801, 0x48C0, 0x4980, 0x8941, 0x4B00, 0x8BC1, 0x8A81, 0x4A40, - 0x4E00, 0x8EC1, 0x8F81, 0x4F40, 0x8D01, 0x4DC0, 0x4C80, 0x8C41, - 0x4400, 0x84C1, 0x8581, 0x4540, 0x8701, 0x47C0, 0x4680, 0x8641, - 0x8201, 0x42C0, 0x4380, 0x8341, 0x4100, 0x81C1, 0x8081, 0x4040 -}; - -unsigned long crc32tab[] = -{ - 0x00000000L, 0x77073096L, 0xEE0E612CL, 0x990951BAL, - 0x076DC419L, 0x706AF48FL, 0xE963A535L, 0x9E6495A3L, - 0x0EDB8832L, 0x79DCB8A4L, 0xE0D5E91EL, 0x97D2D988L, - 0x09B64C2BL, 0x7EB17CBDL, 0xE7B82D07L, 0x90BF1D91L, - 0x1DB71064L, 0x6AB020F2L, 0xF3B97148L, 0x84BE41DEL, - 0x1ADAD47DL, 0x6DDDE4EBL, 0xF4D4B551L, 0x83D385C7L, - 0x136C9856L, 0x646BA8C0L, 0xFD62F97AL, 0x8A65C9ECL, - 0x14015C4FL, 0x63066CD9L, 0xFA0F3D63L, 0x8D080DF5L, - 0x3B6E20C8L, 0x4C69105EL, 0xD56041E4L, 0xA2677172L, - 0x3C03E4D1L, 0x4B04D447L, 0xD20D85FDL, 0xA50AB56BL, - 0x35B5A8FAL, 0x42B2986CL, 0xDBBBC9D6L, 0xACBCF940L, - 0x32D86CE3L, 0x45DF5C75L, 0xDCD60DCFL, 0xABD13D59L, - 0x26D930ACL, 0x51DE003AL, 0xC8D75180L, 0xBFD06116L, - 0x21B4F4B5L, 0x56B3C423L, 0xCFBA9599L, 0xB8BDA50FL, - 0x2802B89EL, 0x5F058808L, 0xC60CD9B2L, 0xB10BE924L, - 0x2F6F7C87L, 0x58684C11L, 0xC1611DABL, 0xB6662D3DL, - 0x76DC4190L, 0x01DB7106L, 0x98D220BCL, 0xEFD5102AL, - 0x71B18589L, 0x06B6B51FL, 0x9FBFE4A5L, 0xE8B8D433L, - 0x7807C9A2L, 0x0F00F934L, 0x9609A88EL, 0xE10E9818L, - 0x7F6A0DBBL, 0x086D3D2DL, 0x91646C97L, 0xE6635C01L, - 0x6B6B51F4L, 0x1C6C6162L, 0x856530D8L, 0xF262004EL, - 0x6C0695EDL, 0x1B01A57BL, 0x8208F4C1L, 0xF50FC457L, - 0x65B0D9C6L, 0x12B7E950L, 0x8BBEB8EAL, 0xFCB9887CL, - 0x62DD1DDFL, 0x15DA2D49L, 0x8CD37CF3L, 0xFBD44C65L, - 0x4DB26158L, 0x3AB551CEL, 0xA3BC0074L, 0xD4BB30E2L, - 0x4ADFA541L, 0x3DD895D7L, 0xA4D1C46DL, 0xD3D6F4FBL, - 0x4369E96AL, 0x346ED9FCL, 0xAD678846L, 0xDA60B8D0L, - 0x44042D73L, 0x33031DE5L, 0xAA0A4C5FL, 0xDD0D7CC9L, - 0x5005713CL, 0x270241AAL, 0xBE0B1010L, 0xC90C2086L, - 0x5768B525L, 0x206F85B3L, 0xB966D409L, 0xCE61E49FL, - 0x5EDEF90EL, 0x29D9C998L, 0xB0D09822L, 0xC7D7A8B4L, - 0x59B33D17L, 0x2EB40D81L, 0xB7BD5C3BL, 0xC0BA6CADL, - 0xEDB88320L, 0x9ABFB3B6L, 0x03B6E20CL, 0x74B1D29AL, - 0xEAD54739L, 0x9DD277AFL, 0x04DB2615L, 0x73DC1683L, - 0xE3630B12L, 0x94643B84L, 0x0D6D6A3EL, 0x7A6A5AA8L, - 0xE40ECF0BL, 0x9309FF9DL, 0x0A00AE27L, 0x7D079EB1L, - 0xF00F9344L, 0x8708A3D2L, 0x1E01F268L, 0x6906C2FEL, - 0xF762575DL, 0x806567CBL, 0x196C3671L, 0x6E6B06E7L, - 0xFED41B76L, 0x89D32BE0L, 0x10DA7A5AL, 0x67DD4ACCL, - 0xF9B9DF6FL, 0x8EBEEFF9L, 0x17B7BE43L, 0x60B08ED5L, - 0xD6D6A3E8L, 0xA1D1937EL, 0x38D8C2C4L, 0x4FDFF252L, - 0xD1BB67F1L, 0xA6BC5767L, 0x3FB506DDL, 0x48B2364BL, - 0xD80D2BDAL, 0xAF0A1B4CL, 0x36034AF6L, 0x41047A60L, - 0xDF60EFC3L, 0xA867DF55L, 0x316E8EEFL, 0x4669BE79L, - 0xCB61B38CL, 0xBC66831AL, 0x256FD2A0L, 0x5268E236L, - 0xCC0C7795L, 0xBB0B4703L, 0x220216B9L, 0x5505262FL, - 0xC5BA3BBEL, 0xB2BD0B28L, 0x2BB45A92L, 0x5CB36A04L, - 0xC2D7FFA7L, 0xB5D0CF31L, 0x2CD99E8BL, 0x5BDEAE1DL, - 0x9B64C2B0L, 0xEC63F226L, 0x756AA39CL, 0x026D930AL, - 0x9C0906A9L, 0xEB0E363FL, 0x72076785L, 0x05005713L, - 0x95BF4A82L, 0xE2B87A14L, 0x7BB12BAEL, 0x0CB61B38L, - 0x92D28E9BL, 0xE5D5BE0DL, 0x7CDCEFB7L, 0x0BDBDF21L, - 0x86D3D2D4L, 0xF1D4E242L, 0x68DDB3F8L, 0x1FDA836EL, - 0x81BE16CDL, 0xF6B9265BL, 0x6FB077E1L, 0x18B74777L, - 0x88085AE6L, 0xFF0F6A70L, 0x66063BCAL, 0x11010B5CL, - 0x8F659EFFL, 0xF862AE69L, 0x616BFFD3L, 0x166CCF45L, - 0xA00AE278L, 0xD70DD2EEL, 0x4E048354L, 0x3903B3C2L, - 0xA7672661L, 0xD06016F7L, 0x4969474DL, 0x3E6E77DBL, - 0xAED16A4AL, 0xD9D65ADCL, 0x40DF0B66L, 0x37D83BF0L, - 0xA9BCAE53L, 0xDEBB9EC5L, 0x47B2CF7FL, 0x30B5FFE9L, - 0xBDBDF21CL, 0xCABAC28AL, 0x53B39330L, 0x24B4A3A6L, - 0xBAD03605L, 0xCDD70693L, 0x54DE5729L, 0x23D967BFL, - 0xB3667A2EL, 0xC4614AB8L, 0x5D681B02L, 0x2A6F2B94L, - 0xB40BBE37L, 0xC30C8EA1L, 0x5A05DF1BL, 0x2D02EF8DL -}; +//taken from ndstool +//http://devkitpro.cvs.sourceforge.net/viewvc/devkitpro/tools/nds/ndstool/source/crc.cpp?revision=1.2 + +/* crc.cpp - this file is part of DeSmuME + * + * Copyright (C) 2005-2006 Rafael Vuijk + * + * This file is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2, or (at your option) + * any later version. + * + * This file is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; see the file COPYING. If not, write to + * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +/* + Cyclic Redundancy Code (CRC) functions + by Rafael Vuijk (aka DarkFader) +*/ + +unsigned short ccitt16tab[] = +{ + 0x0000, 0x1021, 0x2042, 0x3063, 0x4084, 0x50A5, 0x60C6, 0x70E7, + 0x8108, 0x9129, 0xA14A, 0xB16B, 0xC18C, 0xD1AD, 0xE1CE, 0xF1EF, + 0x1231, 0x0210, 0x3273, 0x2252, 0x52B5, 0x4294, 0x72F7, 0x62D6, + 0x9339, 0x8318, 0xB37B, 0xA35A, 0xD3BD, 0xC39C, 0xF3FF, 0xE3DE, + 0x2462, 0x3443, 0x0420, 0x1401, 0x64E6, 0x74C7, 0x44A4, 0x5485, + 0xA56A, 0xB54B, 0x8528, 0x9509, 0xE5EE, 0xF5CF, 0xC5AC, 0xD58D, + 0x3653, 0x2672, 0x1611, 0x0630, 0x76D7, 0x66F6, 0x5695, 0x46B4, + 0xB75B, 0xA77A, 0x9719, 0x8738, 0xF7DF, 0xE7FE, 0xD79D, 0xC7BC, + 0x48C4, 0x58E5, 0x6886, 0x78A7, 0x0840, 0x1861, 0x2802, 0x3823, + 0xC9CC, 0xD9ED, 0xE98E, 0xF9AF, 0x8948, 0x9969, 0xA90A, 0xB92B, + 0x5AF5, 0x4AD4, 0x7AB7, 0x6A96, 0x1A71, 0x0A50, 0x3A33, 0x2A12, + 0xDBFD, 0xCBDC, 0xFBBF, 0xEB9E, 0x9B79, 0x8B58, 0xBB3B, 0xAB1A, + 0x6CA6, 0x7C87, 0x4CE4, 0x5CC5, 0x2C22, 0x3C03, 0x0C60, 0x1C41, + 0xEDAE, 0xFD8F, 0xCDEC, 0xDDCD, 0xAD2A, 0xBD0B, 0x8D68, 0x9D49, + 0x7E97, 0x6EB6, 0x5ED5, 0x4EF4, 0x3E13, 0x2E32, 0x1E51, 0x0E70, + 0xFF9F, 0xEFBE, 0xDFDD, 0xCFFC, 0xBF1B, 0xAF3A, 0x9F59, 0x8F78, + 0x9188, 0x81A9, 0xB1CA, 0xA1EB, 0xD10C, 0xC12D, 0xF14E, 0xE16F, + 0x1080, 0x00A1, 0x30C2, 0x20E3, 0x5004, 0x4025, 0x7046, 0x6067, + 0x83B9, 0x9398, 0xA3FB, 0xB3DA, 0xC33D, 0xD31C, 0xE37F, 0xF35E, + 0x02B1, 0x1290, 0x22F3, 0x32D2, 0x4235, 0x5214, 0x6277, 0x7256, + 0xB5EA, 0xA5CB, 0x95A8, 0x8589, 0xF56E, 0xE54F, 0xD52C, 0xC50D, + 0x34E2, 0x24C3, 0x14A0, 0x0481, 0x7466, 0x6447, 0x5424, 0x4405, + 0xA7DB, 0xB7FA, 0x8799, 0x97B8, 0xE75F, 0xF77E, 0xC71D, 0xD73C, + 0x26D3, 0x36F2, 0x0691, 0x16B0, 0x6657, 0x7676, 0x4615, 0x5634, + 0xD94C, 0xC96D, 0xF90E, 0xE92F, 0x99C8, 0x89E9, 0xB98A, 0xA9AB, + 0x5844, 0x4865, 0x7806, 0x6827, 0x18C0, 0x08E1, 0x3882, 0x28A3, + 0xCB7D, 0xDB5C, 0xEB3F, 0xFB1E, 0x8BF9, 0x9BD8, 0xABBB, 0xBB9A, + 0x4A75, 0x5A54, 0x6A37, 0x7A16, 0x0AF1, 0x1AD0, 0x2AB3, 0x3A92, + 0xFD2E, 0xED0F, 0xDD6C, 0xCD4D, 0xBDAA, 0xAD8B, 0x9DE8, 0x8DC9, + 0x7C26, 0x6C07, 0x5C64, 0x4C45, 0x3CA2, 0x2C83, 0x1CE0, 0x0CC1, + 0xEF1F, 0xFF3E, 0xCF5D, 0xDF7C, 0xAF9B, 0xBFBA, 0x8FD9, 0x9FF8, + 0x6E17, 0x7E36, 0x4E55, 0x5E74, 0x2E93, 0x3EB2, 0x0ED1, 0x1EF0 +}; + +unsigned short crc16tab[] = +{ + 0x0000, 0xC0C1, 0xC181, 0x0140, 0xC301, 0x03C0, 0x0280, 0xC241, + 0xC601, 0x06C0, 0x0780, 0xC741, 0x0500, 0xC5C1, 0xC481, 0x0440, + 0xCC01, 0x0CC0, 0x0D80, 0xCD41, 0x0F00, 0xCFC1, 0xCE81, 0x0E40, + 0x0A00, 0xCAC1, 0xCB81, 0x0B40, 0xC901, 0x09C0, 0x0880, 0xC841, + 0xD801, 0x18C0, 0x1980, 0xD941, 0x1B00, 0xDBC1, 0xDA81, 0x1A40, + 0x1E00, 0xDEC1, 0xDF81, 0x1F40, 0xDD01, 0x1DC0, 0x1C80, 0xDC41, + 0x1400, 0xD4C1, 0xD581, 0x1540, 0xD701, 0x17C0, 0x1680, 0xD641, + 0xD201, 0x12C0, 0x1380, 0xD341, 0x1100, 0xD1C1, 0xD081, 0x1040, + 0xF001, 0x30C0, 0x3180, 0xF141, 0x3300, 0xF3C1, 0xF281, 0x3240, + 0x3600, 0xF6C1, 0xF781, 0x3740, 0xF501, 0x35C0, 0x3480, 0xF441, + 0x3C00, 0xFCC1, 0xFD81, 0x3D40, 0xFF01, 0x3FC0, 0x3E80, 0xFE41, + 0xFA01, 0x3AC0, 0x3B80, 0xFB41, 0x3900, 0xF9C1, 0xF881, 0x3840, + 0x2800, 0xE8C1, 0xE981, 0x2940, 0xEB01, 0x2BC0, 0x2A80, 0xEA41, + 0xEE01, 0x2EC0, 0x2F80, 0xEF41, 0x2D00, 0xEDC1, 0xEC81, 0x2C40, + 0xE401, 0x24C0, 0x2580, 0xE541, 0x2700, 0xE7C1, 0xE681, 0x2640, + 0x2200, 0xE2C1, 0xE381, 0x2340, 0xE101, 0x21C0, 0x2080, 0xE041, + 0xA001, 0x60C0, 0x6180, 0xA141, 0x6300, 0xA3C1, 0xA281, 0x6240, + 0x6600, 0xA6C1, 0xA781, 0x6740, 0xA501, 0x65C0, 0x6480, 0xA441, + 0x6C00, 0xACC1, 0xAD81, 0x6D40, 0xAF01, 0x6FC0, 0x6E80, 0xAE41, + 0xAA01, 0x6AC0, 0x6B80, 0xAB41, 0x6900, 0xA9C1, 0xA881, 0x6840, + 0x7800, 0xB8C1, 0xB981, 0x7940, 0xBB01, 0x7BC0, 0x7A80, 0xBA41, + 0xBE01, 0x7EC0, 0x7F80, 0xBF41, 0x7D00, 0xBDC1, 0xBC81, 0x7C40, + 0xB401, 0x74C0, 0x7580, 0xB541, 0x7700, 0xB7C1, 0xB681, 0x7640, + 0x7200, 0xB2C1, 0xB381, 0x7340, 0xB101, 0x71C0, 0x7080, 0xB041, + 0x5000, 0x90C1, 0x9181, 0x5140, 0x9301, 0x53C0, 0x5280, 0x9241, + 0x9601, 0x56C0, 0x5780, 0x9741, 0x5500, 0x95C1, 0x9481, 0x5440, + 0x9C01, 0x5CC0, 0x5D80, 0x9D41, 0x5F00, 0x9FC1, 0x9E81, 0x5E40, + 0x5A00, 0x9AC1, 0x9B81, 0x5B40, 0x9901, 0x59C0, 0x5880, 0x9841, + 0x8801, 0x48C0, 0x4980, 0x8941, 0x4B00, 0x8BC1, 0x8A81, 0x4A40, + 0x4E00, 0x8EC1, 0x8F81, 0x4F40, 0x8D01, 0x4DC0, 0x4C80, 0x8C41, + 0x4400, 0x84C1, 0x8581, 0x4540, 0x8701, 0x47C0, 0x4680, 0x8641, + 0x8201, 0x42C0, 0x4380, 0x8341, 0x4100, 0x81C1, 0x8081, 0x4040 +}; + +unsigned long crc32tab[] = +{ + 0x00000000L, 0x77073096L, 0xEE0E612CL, 0x990951BAL, + 0x076DC419L, 0x706AF48FL, 0xE963A535L, 0x9E6495A3L, + 0x0EDB8832L, 0x79DCB8A4L, 0xE0D5E91EL, 0x97D2D988L, + 0x09B64C2BL, 0x7EB17CBDL, 0xE7B82D07L, 0x90BF1D91L, + 0x1DB71064L, 0x6AB020F2L, 0xF3B97148L, 0x84BE41DEL, + 0x1ADAD47DL, 0x6DDDE4EBL, 0xF4D4B551L, 0x83D385C7L, + 0x136C9856L, 0x646BA8C0L, 0xFD62F97AL, 0x8A65C9ECL, + 0x14015C4FL, 0x63066CD9L, 0xFA0F3D63L, 0x8D080DF5L, + 0x3B6E20C8L, 0x4C69105EL, 0xD56041E4L, 0xA2677172L, + 0x3C03E4D1L, 0x4B04D447L, 0xD20D85FDL, 0xA50AB56BL, + 0x35B5A8FAL, 0x42B2986CL, 0xDBBBC9D6L, 0xACBCF940L, + 0x32D86CE3L, 0x45DF5C75L, 0xDCD60DCFL, 0xABD13D59L, + 0x26D930ACL, 0x51DE003AL, 0xC8D75180L, 0xBFD06116L, + 0x21B4F4B5L, 0x56B3C423L, 0xCFBA9599L, 0xB8BDA50FL, + 0x2802B89EL, 0x5F058808L, 0xC60CD9B2L, 0xB10BE924L, + 0x2F6F7C87L, 0x58684C11L, 0xC1611DABL, 0xB6662D3DL, + 0x76DC4190L, 0x01DB7106L, 0x98D220BCL, 0xEFD5102AL, + 0x71B18589L, 0x06B6B51FL, 0x9FBFE4A5L, 0xE8B8D433L, + 0x7807C9A2L, 0x0F00F934L, 0x9609A88EL, 0xE10E9818L, + 0x7F6A0DBBL, 0x086D3D2DL, 0x91646C97L, 0xE6635C01L, + 0x6B6B51F4L, 0x1C6C6162L, 0x856530D8L, 0xF262004EL, + 0x6C0695EDL, 0x1B01A57BL, 0x8208F4C1L, 0xF50FC457L, + 0x65B0D9C6L, 0x12B7E950L, 0x8BBEB8EAL, 0xFCB9887CL, + 0x62DD1DDFL, 0x15DA2D49L, 0x8CD37CF3L, 0xFBD44C65L, + 0x4DB26158L, 0x3AB551CEL, 0xA3BC0074L, 0xD4BB30E2L, + 0x4ADFA541L, 0x3DD895D7L, 0xA4D1C46DL, 0xD3D6F4FBL, + 0x4369E96AL, 0x346ED9FCL, 0xAD678846L, 0xDA60B8D0L, + 0x44042D73L, 0x33031DE5L, 0xAA0A4C5FL, 0xDD0D7CC9L, + 0x5005713CL, 0x270241AAL, 0xBE0B1010L, 0xC90C2086L, + 0x5768B525L, 0x206F85B3L, 0xB966D409L, 0xCE61E49FL, + 0x5EDEF90EL, 0x29D9C998L, 0xB0D09822L, 0xC7D7A8B4L, + 0x59B33D17L, 0x2EB40D81L, 0xB7BD5C3BL, 0xC0BA6CADL, + 0xEDB88320L, 0x9ABFB3B6L, 0x03B6E20CL, 0x74B1D29AL, + 0xEAD54739L, 0x9DD277AFL, 0x04DB2615L, 0x73DC1683L, + 0xE3630B12L, 0x94643B84L, 0x0D6D6A3EL, 0x7A6A5AA8L, + 0xE40ECF0BL, 0x9309FF9DL, 0x0A00AE27L, 0x7D079EB1L, + 0xF00F9344L, 0x8708A3D2L, 0x1E01F268L, 0x6906C2FEL, + 0xF762575DL, 0x806567CBL, 0x196C3671L, 0x6E6B06E7L, + 0xFED41B76L, 0x89D32BE0L, 0x10DA7A5AL, 0x67DD4ACCL, + 0xF9B9DF6FL, 0x8EBEEFF9L, 0x17B7BE43L, 0x60B08ED5L, + 0xD6D6A3E8L, 0xA1D1937EL, 0x38D8C2C4L, 0x4FDFF252L, + 0xD1BB67F1L, 0xA6BC5767L, 0x3FB506DDL, 0x48B2364BL, + 0xD80D2BDAL, 0xAF0A1B4CL, 0x36034AF6L, 0x41047A60L, + 0xDF60EFC3L, 0xA867DF55L, 0x316E8EEFL, 0x4669BE79L, + 0xCB61B38CL, 0xBC66831AL, 0x256FD2A0L, 0x5268E236L, + 0xCC0C7795L, 0xBB0B4703L, 0x220216B9L, 0x5505262FL, + 0xC5BA3BBEL, 0xB2BD0B28L, 0x2BB45A92L, 0x5CB36A04L, + 0xC2D7FFA7L, 0xB5D0CF31L, 0x2CD99E8BL, 0x5BDEAE1DL, + 0x9B64C2B0L, 0xEC63F226L, 0x756AA39CL, 0x026D930AL, + 0x9C0906A9L, 0xEB0E363FL, 0x72076785L, 0x05005713L, + 0x95BF4A82L, 0xE2B87A14L, 0x7BB12BAEL, 0x0CB61B38L, + 0x92D28E9BL, 0xE5D5BE0DL, 0x7CDCEFB7L, 0x0BDBDF21L, + 0x86D3D2D4L, 0xF1D4E242L, 0x68DDB3F8L, 0x1FDA836EL, + 0x81BE16CDL, 0xF6B9265BL, 0x6FB077E1L, 0x18B74777L, + 0x88085AE6L, 0xFF0F6A70L, 0x66063BCAL, 0x11010B5CL, + 0x8F659EFFL, 0xF862AE69L, 0x616BFFD3L, 0x166CCF45L, + 0xA00AE278L, 0xD70DD2EEL, 0x4E048354L, 0x3903B3C2L, + 0xA7672661L, 0xD06016F7L, 0x4969474DL, 0x3E6E77DBL, + 0xAED16A4AL, 0xD9D65ADCL, 0x40DF0B66L, 0x37D83BF0L, + 0xA9BCAE53L, 0xDEBB9EC5L, 0x47B2CF7FL, 0x30B5FFE9L, + 0xBDBDF21CL, 0xCABAC28AL, 0x53B39330L, 0x24B4A3A6L, + 0xBAD03605L, 0xCDD70693L, 0x54DE5729L, 0x23D967BFL, + 0xB3667A2EL, 0xC4614AB8L, 0x5D681B02L, 0x2A6F2B94L, + 0xB40BBE37L, 0xC30C8EA1L, 0x5A05DF1BL, 0x2D02EF8DL +}; diff --git a/desmume/src/utils/decrypt/crc.h b/src/utils/decrypt/crc.h similarity index 96% rename from desmume/src/utils/decrypt/crc.h rename to src/utils/decrypt/crc.h index 38da26d76..9d77f1574 100644 --- a/desmume/src/utils/decrypt/crc.h +++ b/src/utils/decrypt/crc.h @@ -1,198 +1,198 @@ -//taken from ndstool -//http://devkitpro.cvs.sourceforge.net/viewvc/devkitpro/tools/nds/ndstool/include/crc.h?revision=1.3 - -/* crc.h - this file is part of DeSmuME - * - * Copyright (C) 2005-2006 Rafael Vuijk - * - * This file is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2, or (at your option) - * any later version. - * - * This file is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; see the file COPYING. If not, write to - * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -/* - Cyclic Redundancy Code (CRC) functions - by Rafael Vuijk (aka DarkFader) -*/ - -#ifndef __CRC_H -#define __CRC_H - -//#include "little.h" // FixCrc is not yet big endian compatible - -/* - * Data - */ -extern unsigned short ccitt16tab[]; -extern unsigned short crc16tab[]; -extern unsigned long crc32tab[]; - -/* - * Defines - */ -#define CRC_TEMPLATE template - -/* - * CalcCcitt - * Does not perform final inversion. - */ -#define CalcCcitt_ CalcCcitt -#define CalcCcitt16 CalcCcitt -CRC_TEMPLATE inline CrcType CalcCcitt(unsigned char *data, unsigned int length, CrcType crc = (CrcType)0) -{ - for (unsigned int i=0; i> 8) ^ data[i]]; - } - return crc; -} - -/* - * CalcCrc - * Does not perform final inversion. - */ -#define CalcCrc_ CalcCrc -#define CalcCrc16 CalcCrc -#define CalcCrc32 CalcCrc -CRC_TEMPLATE inline CrcType CalcCrc(unsigned char *data, unsigned int length, CrcType crc = (CrcType)~0) -{ - for (unsigned int i=0; i> 8) ^ crcTable[(crc ^ data[i]) & 0xFF]; - } - return crc; -} - -/* - * FCalcCrc - * Does not perform final inversion. - */ -#define FCalcCrc_ FCalcCrc -#define FCalcCrc16 FCalcCrc -#define FCalcCrc32 FCalcCrc -CRC_TEMPLATE inline CrcType FCalcCrc(FILE *f, unsigned int offset, unsigned int length, CrcType crc = (CrcType)~0) -{ - fseek(f, offset, SEEK_SET); - for (unsigned int i=0; i> 8) ^ crcTable[(crc ^ fgetc(f)) & 0xFF]; - } - return crc; -} - -/* - * RevCrc - * Reverse table lookup. - */ -#define RevCrc_ RevCrc -CRC_TEMPLATE inline unsigned char RevCrc(unsigned char x, CrcType *value = 0) -{ - for (int y=0; y<256; y++) - { - if ((crcTable[y] >> (8*sizeof(CrcType)-8)) == x) - { - if (value) *value = crcTable[y]; - return y; - } - } - return 0; -} - -/* - * FixCrc - */ -#define FixCrc_ FixCrc -#define FixCrc16 FixCrc -#define FixCrc32 FixCrc -CRC_TEMPLATE void FixCrc -( - unsigned char *data, // data to be patched - unsigned int patch_offset, unsigned char *patch_data, unsigned int patch_length, // patch data - unsigned int fix_offset = 0, // position to write the fix. by default, it is immediately after the patched data - CrcType initial_crc = (CrcType)~0 // useful when manually calculating leading data -) -{ - if (!fix_offset) fix_offset = patch_offset + patch_length; - - // calculate CRC after leading data - initial_crc = CalcCrc_(data, patch_offset, initial_crc); - - // calculate CRC before fix - unsigned char buf[2*sizeof(CrcType)]; - CrcType crc_before_fix = CalcCrc_(data + patch_offset, fix_offset - patch_offset); - *(CrcType *)(buf + 0) = crc_before_fix; - - // patch - memcpy(data + patch_offset, patch_data, patch_length); - - // calculate CRC after unfixed - CrcType crc_after_unfix = CalcCrc_(data + patch_offset, fix_offset - patch_offset + sizeof(CrcType)); - *(CrcType *)(buf + sizeof(CrcType)) = crc_after_unfix; - - // fix it - for (int i=sizeof(CrcType); i>=1; i--) - { - CrcType value; - unsigned char index = RevCrc_(buf[i + sizeof(CrcType) - 1], &value); - *(CrcType *)(buf + i) ^= value; - buf[i - 1] ^= index; - } - memcpy(data + fix_offset, buf, sizeof(CrcType)); -} - -/* - * FFixCrc - */ -#define FFixCrc_ FFixCrc -#define FFixCrc16 FFixCrc -#define FFixCrc32 FFixCrc -CRC_TEMPLATE void FFixCrc -( - FILE *f, // file to be patched - unsigned int patch_offset, unsigned char *patch_data, unsigned int patch_length, // patch data - unsigned int fix_offset = 0, // position to write the fix. by default, it is immediately after the patched data - CrcType initial_crc = (CrcType)~0 // useful when manually calculating leading data -) -{ - if (!fix_offset) fix_offset = patch_offset + patch_length; - - // calculate CRC after leading data - initial_crc = FCalcCrc_(f, 0, patch_offset, initial_crc); - - // calculate CRC before fix - unsigned char buf[2*sizeof(CrcType)]; - CrcType crc_before_fix = FCalcCrc_(f, patch_offset, fix_offset - patch_offset); - *(CrcType *)(buf + 0) = crc_before_fix; - - // patch - fseek(f, patch_offset, SEEK_SET); - fwrite(patch_data, 1, patch_length, f); - - // calculate CRC after unfixed - CrcType crc_after_unfix = FCalcCrc_(f, patch_offset, fix_offset - patch_offset + sizeof(CrcType)); - *(CrcType *)(buf + sizeof(CrcType)) = crc_after_unfix; - - // fix it - for (int i=sizeof(CrcType); i>=1; i--) - { - CrcType value=0; - unsigned char index = RevCrc_(buf[i + sizeof(CrcType) - 1], &value); - *(CrcType *)(buf + i) ^= value; - buf[i - 1] ^= index; - } - fseek(f, fix_offset, SEEK_SET); - fwrite(buf, sizeof(CrcType), 1, f); -} - -#endif // __CRC_H +//taken from ndstool +//http://devkitpro.cvs.sourceforge.net/viewvc/devkitpro/tools/nds/ndstool/include/crc.h?revision=1.3 + +/* crc.h - this file is part of DeSmuME + * + * Copyright (C) 2005-2006 Rafael Vuijk + * + * This file is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2, or (at your option) + * any later version. + * + * This file is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; see the file COPYING. If not, write to + * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +/* + Cyclic Redundancy Code (CRC) functions + by Rafael Vuijk (aka DarkFader) +*/ + +#ifndef __CRC_H +#define __CRC_H + +//#include "little.h" // FixCrc is not yet big endian compatible + +/* + * Data + */ +extern unsigned short ccitt16tab[]; +extern unsigned short crc16tab[]; +extern unsigned long crc32tab[]; + +/* + * Defines + */ +#define CRC_TEMPLATE template + +/* + * CalcCcitt + * Does not perform final inversion. + */ +#define CalcCcitt_ CalcCcitt +#define CalcCcitt16 CalcCcitt +CRC_TEMPLATE inline CrcType CalcCcitt(unsigned char *data, unsigned int length, CrcType crc = (CrcType)0) +{ + for (unsigned int i=0; i> 8) ^ data[i]]; + } + return crc; +} + +/* + * CalcCrc + * Does not perform final inversion. + */ +#define CalcCrc_ CalcCrc +#define CalcCrc16 CalcCrc +#define CalcCrc32 CalcCrc +CRC_TEMPLATE inline CrcType CalcCrc(unsigned char *data, unsigned int length, CrcType crc = (CrcType)~0) +{ + for (unsigned int i=0; i> 8) ^ crcTable[(crc ^ data[i]) & 0xFF]; + } + return crc; +} + +/* + * FCalcCrc + * Does not perform final inversion. + */ +#define FCalcCrc_ FCalcCrc +#define FCalcCrc16 FCalcCrc +#define FCalcCrc32 FCalcCrc +CRC_TEMPLATE inline CrcType FCalcCrc(FILE *f, unsigned int offset, unsigned int length, CrcType crc = (CrcType)~0) +{ + fseek(f, offset, SEEK_SET); + for (unsigned int i=0; i> 8) ^ crcTable[(crc ^ fgetc(f)) & 0xFF]; + } + return crc; +} + +/* + * RevCrc + * Reverse table lookup. + */ +#define RevCrc_ RevCrc +CRC_TEMPLATE inline unsigned char RevCrc(unsigned char x, CrcType *value = 0) +{ + for (int y=0; y<256; y++) + { + if ((crcTable[y] >> (8*sizeof(CrcType)-8)) == x) + { + if (value) *value = crcTable[y]; + return y; + } + } + return 0; +} + +/* + * FixCrc + */ +#define FixCrc_ FixCrc +#define FixCrc16 FixCrc +#define FixCrc32 FixCrc +CRC_TEMPLATE void FixCrc +( + unsigned char *data, // data to be patched + unsigned int patch_offset, unsigned char *patch_data, unsigned int patch_length, // patch data + unsigned int fix_offset = 0, // position to write the fix. by default, it is immediately after the patched data + CrcType initial_crc = (CrcType)~0 // useful when manually calculating leading data +) +{ + if (!fix_offset) fix_offset = patch_offset + patch_length; + + // calculate CRC after leading data + initial_crc = CalcCrc_(data, patch_offset, initial_crc); + + // calculate CRC before fix + unsigned char buf[2*sizeof(CrcType)]; + CrcType crc_before_fix = CalcCrc_(data + patch_offset, fix_offset - patch_offset); + *(CrcType *)(buf + 0) = crc_before_fix; + + // patch + memcpy(data + patch_offset, patch_data, patch_length); + + // calculate CRC after unfixed + CrcType crc_after_unfix = CalcCrc_(data + patch_offset, fix_offset - patch_offset + sizeof(CrcType)); + *(CrcType *)(buf + sizeof(CrcType)) = crc_after_unfix; + + // fix it + for (int i=sizeof(CrcType); i>=1; i--) + { + CrcType value; + unsigned char index = RevCrc_(buf[i + sizeof(CrcType) - 1], &value); + *(CrcType *)(buf + i) ^= value; + buf[i - 1] ^= index; + } + memcpy(data + fix_offset, buf, sizeof(CrcType)); +} + +/* + * FFixCrc + */ +#define FFixCrc_ FFixCrc +#define FFixCrc16 FFixCrc +#define FFixCrc32 FFixCrc +CRC_TEMPLATE void FFixCrc +( + FILE *f, // file to be patched + unsigned int patch_offset, unsigned char *patch_data, unsigned int patch_length, // patch data + unsigned int fix_offset = 0, // position to write the fix. by default, it is immediately after the patched data + CrcType initial_crc = (CrcType)~0 // useful when manually calculating leading data +) +{ + if (!fix_offset) fix_offset = patch_offset + patch_length; + + // calculate CRC after leading data + initial_crc = FCalcCrc_(f, 0, patch_offset, initial_crc); + + // calculate CRC before fix + unsigned char buf[2*sizeof(CrcType)]; + CrcType crc_before_fix = FCalcCrc_(f, patch_offset, fix_offset - patch_offset); + *(CrcType *)(buf + 0) = crc_before_fix; + + // patch + fseek(f, patch_offset, SEEK_SET); + fwrite(patch_data, 1, patch_length, f); + + // calculate CRC after unfixed + CrcType crc_after_unfix = FCalcCrc_(f, patch_offset, fix_offset - patch_offset + sizeof(CrcType)); + *(CrcType *)(buf + sizeof(CrcType)) = crc_after_unfix; + + // fix it + for (int i=sizeof(CrcType); i>=1; i--) + { + CrcType value=0; + unsigned char index = RevCrc_(buf[i + sizeof(CrcType) - 1], &value); + *(CrcType *)(buf + i) ^= value; + buf[i - 1] ^= index; + } + fseek(f, fix_offset, SEEK_SET); + fwrite(buf, sizeof(CrcType), 1, f); +} + +#endif // __CRC_H diff --git a/desmume/src/utils/decrypt/decrypt.cpp b/src/utils/decrypt/decrypt.cpp similarity index 100% rename from desmume/src/utils/decrypt/decrypt.cpp rename to src/utils/decrypt/decrypt.cpp diff --git a/desmume/src/utils/decrypt/decrypt.h b/src/utils/decrypt/decrypt.h similarity index 100% rename from desmume/src/utils/decrypt/decrypt.h rename to src/utils/decrypt/decrypt.h diff --git a/desmume/src/utils/decrypt/header.cpp b/src/utils/decrypt/header.cpp similarity index 100% rename from desmume/src/utils/decrypt/header.cpp rename to src/utils/decrypt/header.cpp diff --git a/desmume/src/utils/decrypt/header.h b/src/utils/decrypt/header.h similarity index 100% rename from desmume/src/utils/decrypt/header.h rename to src/utils/decrypt/header.h diff --git a/desmume/src/utils/guid.cpp b/src/utils/guid.cpp similarity index 56% rename from desmume/src/utils/guid.cpp rename to src/utils/guid.cpp index 6d4206c63..b8d7d5ac7 100644 --- a/desmume/src/utils/guid.cpp +++ b/src/utils/guid.cpp @@ -1,70 +1,70 @@ -/* guid.cpp - - Copyright (C) 2008-2009 DeSmuME team - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -*/ - -#include -#include "guid.h" -#include "../types.h" - -void Desmume_Guid::newGuid() -{ - for(int i=0;i='A') a=a-'A'+10; - else a-='0'; - if(b>='A') b=b-'A'+10; - else b-='0'; - return ((unsigned char)a<<4)|(unsigned char)b; -} - -void Desmume_Guid::scan(std::string& str) -{ - char* endptr = (char*)str.c_str(); - en32lsb(data,strtoul(endptr,&endptr,16)); - en16lsb(data+4,strtoul(endptr+1,&endptr,16)); - en16lsb(data+6,strtoul(endptr+1,&endptr,16)); - en16lsb(data+8,strtoul(endptr+1,&endptr,16)); - endptr++; - for(int i=0;i<6;i++) - data[10+i] = hexToByte(&endptr); -} +/* guid.cpp + * + * Copyright (C) 2008 Zeromus + * + * This file is part of DeSmuME + * + * DeSmuME is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * DeSmuME is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with DeSmuME; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA +*/ + +#include +#include "guid.h" +#include "../types.h" + +void Desmume_Guid::newGuid() +{ + for(int i=0;i='A') a=a-'A'+10; + else a-='0'; + if(b>='A') b=b-'A'+10; + else b-='0'; + return ((unsigned char)a<<4)|(unsigned char)b; +} + +void Desmume_Guid::scan(std::string& str) +{ + char* endptr = (char*)str.c_str(); + en32lsb(data,strtoul(endptr,&endptr,16)); + en16lsb(data+4,strtoul(endptr+1,&endptr,16)); + en16lsb(data+6,strtoul(endptr+1,&endptr,16)); + en16lsb(data+8,strtoul(endptr+1,&endptr,16)); + endptr++; + for(int i=0;i<6;i++) + data[10+i] = hexToByte(&endptr); +} diff --git a/desmume/src/utils/guid.h b/src/utils/guid.h similarity index 94% rename from desmume/src/utils/guid.h rename to src/utils/guid.h index df5e57e43..b1a1ae787 100644 --- a/desmume/src/utils/guid.h +++ b/src/utils/guid.h @@ -1,19 +1,19 @@ -#ifndef _guid_h_ -#define _guid_h_ - -#include -#include -#include "../types.h" -#include "valuearray.h" - -struct Desmume_Guid : public ValueArray -{ - void newGuid(); - std::string toString(); - static Desmume_Guid fromString(std::string str); - static uint8 hexToByte(char** ptrptr); - void scan(std::string& str); -}; - - -#endif +#ifndef _guid_h_ +#define _guid_h_ + +#include +#include +#include "../types.h" +#include "valuearray.h" + +struct Desmume_Guid : public ValueArray +{ + void newGuid(); + std::string toString(); + static Desmume_Guid fromString(std::string str); + static uint8 hexToByte(char** ptrptr); + void scan(std::string& str); +}; + + +#endif diff --git a/desmume/src/utils/md5.cpp b/src/utils/md5.cpp similarity index 100% rename from desmume/src/utils/md5.cpp rename to src/utils/md5.cpp diff --git a/desmume/src/utils/md5.h b/src/utils/md5.h similarity index 95% rename from desmume/src/utils/md5.h rename to src/utils/md5.h index bbd2593b1..f197aac19 100644 --- a/desmume/src/utils/md5.h +++ b/src/utils/md5.h @@ -1,23 +1,23 @@ -#ifndef _MD5_H -#define _MD5_H - -#include "../types.h" -#include "valuearray.h" - -struct md5_context -{ - u32 total[2]; - u32 state[4]; - u8 buffer[64]; -}; - -typedef ValueArray MD5DATA; - -void md5_starts( struct md5_context *ctx ); -void md5_update( struct md5_context *ctx, u8 *input, u32 length ); -void md5_finish( struct md5_context *ctx, u8 digest[16] ); - -/* Uses a static buffer, so beware of how it's used. */ -char *md5_asciistr(MD5DATA& md5); - -#endif /* md5.h */ +#ifndef _MD5_H +#define _MD5_H + +#include "../types.h" +#include "valuearray.h" + +struct md5_context +{ + u32 total[2]; + u32 state[4]; + u8 buffer[64]; +}; + +typedef ValueArray MD5DATA; + +void md5_starts( struct md5_context *ctx ); +void md5_update( struct md5_context *ctx, u8 *input, u32 length ); +void md5_finish( struct md5_context *ctx, u8 digest[16] ); + +/* Uses a static buffer, so beware of how it's used. */ +char *md5_asciistr(MD5DATA& md5); + +#endif /* md5.h */ diff --git a/desmume/src/utils/valuearray.h b/src/utils/valuearray.h similarity index 95% rename from desmume/src/utils/valuearray.h rename to src/utils/valuearray.h index 697014d56..8606ff829 100644 --- a/desmume/src/utils/valuearray.h +++ b/src/utils/valuearray.h @@ -1,21 +1,21 @@ -#ifndef _VALUEARRAY_H_ -#define _VALUEARRAY_H_ - -template -struct ValueArray -{ - T data[N]; - T &operator[](int index) { return data[index]; } - static const int size = N; - bool operator!=(ValueArray &other) { return !operator==(other); } - bool operator==(ValueArray &other) - { - for(int i=0;i +struct ValueArray +{ + T data[N]; + T &operator[](int index) { return data[index]; } + static const int size = N; + bool operator!=(ValueArray &other) { return !operator==(other); } + bool operator==(ValueArray &other) + { + for(int i=0;i -//a vc-style substring operation (very kind and lenient) -std::string strsub(const std::string& str, int pos, int len) { - int strlen = str.size(); - - if(strlen==0) return str; //empty strings always return empty strings - if(pos>=strlen) return str; //if you start past the end of the string, return the entire string. this is unusual, but there you have it - - //clipping - if(pos<0) { - len += pos; - pos = 0; - } - - if (pos+len>=strlen) - len=strlen-pos+1; - - //return str.str().substr(pos,len); - return str.substr(pos,len); -} - -std::string strmid(const std::string& str, int pos, int len) { return strsub(str,pos,len); } -std::string strleft(const std::string& str, int len) { return strsub(str,0,len); } -std::string strright(const std::string& str, int len) { return len ? strsub(str,str.size()-len,len) : ""; } -std::string toupper(const std::string& str) -{ - std::string ret = str; - for(u32 i=0;i= 'a') && (str[i] <= 'z')) { @@ -51,7 +20,7 @@ int str_ucase(char *str) { ///Lower case routine. Returns number of characters modified int str_lcase(char *str) { - u32 i=0,j=0; + unsigned int i=0,j=0; //mbg merge 7/17/06 changed to unsigned int while (i < strlen(str)) { if ((str[i] >= 'A') && (str[i] <= 'Z')) { @@ -69,7 +38,7 @@ int str_lcase(char *str) { ///Removes whitespace from left side of string, depending on the flags set (See STRIP_x definitions in xstring.h) ///Returns number of characters removed int str_ltrim(char *str, int flags) { - u32 i=0; + unsigned int i=0; //mbg merge 7/17/06 changed to unsigned int while (str[0]) { if ((str[0] != ' ') || (str[0] != '\t') || (str[0] != '\r') || (str[0] != '\n')) break; @@ -100,7 +69,7 @@ int str_ltrim(char *str, int flags) { ///Removes whitespace from right side of string, depending on the flags set (See STRIP_x definitions in xstring.h) ///Returns number of characters removed int str_rtrim(char *str, int flags) { - u32 i=0; + unsigned int i=0; //mbg merge 7/17/06 changed to unsigned int while (strlen(str)) { if ((str[strlen(str)-1] != ' ') || @@ -134,7 +103,7 @@ int str_rtrim(char *str, int flags) { ///Removes whitespace depending on the flags set (See STRIP_x definitions in xstring.h) ///Returns number of characters removed, or -1 on error int str_strip(char *str, int flags) { - u32 i=0,j=0; + unsigned int i=0,j=0; //mbg merge 7/17/06 changed to unsigned int char *astr,chr; if (!strlen(str)) return -1; @@ -161,7 +130,7 @@ int str_strip(char *str, int flags) { ///Replaces all instances of 'search' with 'replace' ///Returns number of characters modified int chr_replace(char *str, char search, char replace) { - u32 i=0,j=0; + unsigned int i=0,j=0; //mbg merge 7/17/06 changed to unsigned int while (i < strlen(str)) { if (str[i] == search) { @@ -179,7 +148,7 @@ int chr_replace(char *str, char search, char replace) { ///Replaces all instances of 'search' with 'replace' ///Returns number of sub-strings modified, or -1 on error int str_replace(char *str, char *search, char *replace) { - u32 i=0,j=0; + unsigned int i=0,j=0; //mbg merge 7/17/06 changed to unsigned int int searchlen,replacelen; char *astr; @@ -620,7 +589,7 @@ namespace UtfConverter } else if (sizeof(wchar_t) == 4) { - wchar_t* widestringnative = new wchar_t[widesize+1]; + wchar_t* widestringnative = new wchar_t[widesize]; const UTF8* sourcestart = reinterpret_cast(utf8string.c_str()); const UTF8* sourceend = sourcestart + widesize; UTF32* targetstart = reinterpret_cast(widestringnative); diff --git a/desmume/src/utils/xstring.h b/src/utils/xstring.h similarity index 90% rename from desmume/src/utils/xstring.h rename to src/utils/xstring.h index 1c24e9e61..f02246c43 100644 --- a/desmume/src/utils/xstring.h +++ b/src/utils/xstring.h @@ -28,12 +28,6 @@ int str_strip(char *str, int flags); int chr_replace(char *str, char search, char replace); int str_replace(char *str, char *search, char *replace); -std::string strsub(const std::string& str, int pos, int len); -std::string strmid(const std::string& str, int pos, int len); -std::string strleft(const std::string& str, int len); -std::string strright(const std::string& str, int len); -std::string toupper(const std::string& str); - int HexStringToBytesLength(const std::string& str); int Base64StringToBytesLength(const std::string& str); std::string u32ToHexString(u32 val); diff --git a/desmume/src/wifi.cpp b/src/wifi.cpp similarity index 95% rename from desmume/src/wifi.cpp rename to src/wifi.cpp index b19773327..9d2f6c2ca 100644 --- a/desmume/src/wifi.cpp +++ b/src/wifi.cpp @@ -217,61 +217,6 @@ INLINE u32 WIFI_alignedLen(u32 len) return ((len + 3) & ~3); } -#ifdef WIN32 -static pcap_t *desmume_pcap_open(const char *source, int snaplen, int flags, - int read_timeout, char *errbuf) -{ - return PCAP::pcap_open(source, snaplen, flags, read_timeout, NULL, errbuf); -} - -static int desmume_pcap_findalldevs(pcap_if_t **alldevs, char *errbuf) -{ - return PCAP::pcap_findalldevs_ex(PCAP_SRC_IF_STRING, NULL, alldevs, errbuf); -} - -static void desmume_pcap_freealldevs(pcap_if_t *alldevs) -{ - return PCAP::pcap_freealldevs(alldevs); -} - -static void desmume_pcap_close(pcap_t *p) -{ - return PCAP::pcap_close(p); -} - -static int desmume_pcap_sendpacket(pcap_t *p, u_char *buf, int size) -{ - return PCAP::pcap_sendpacket(p, buf, size); -} - -#else -static pcap_t *desmume_pcap_open(const char *device, int snaplen, int promisc, - int to_ms, char *errbuf) -{ - return pcap_open_live(device, snaplen, promisc, to_ms, errbuf); -} - -static int desmume_pcap_findalldevs(pcap_if_t **alldevs, char *errbuf) -{ - return pcap_findalldevs(alldevs, errbuf); -} - -static void desmume_pcap_freealldevs(pcap_if_t *alldevs) -{ - return pcap_freealldevs(alldevs); -} - -static void desmume_pcap_close(pcap_t *p) -{ - return pcap_close(p); -} - -static int desmume_pcap_sendpacket(pcap_t *p, u_char *buf, int size) -{ - return pcap_sendpacket(p, buf, size); -} -#endif - /******************************************************************************* CRC32 (http://www.codeproject.com/KB/recipes/crc32_large.aspx) @@ -294,7 +239,7 @@ static u32 reflect(u32 ref, char ch) return value; } -static u32 WIFI_getCRC32(u8 *data, int len) +u32 WIFI_getCRC32(u8 *data, int len) { u32 crc = 0xFFFFFFFF; @@ -304,7 +249,7 @@ static u32 WIFI_getCRC32(u8 *data, int len) return (crc ^ 0xFFFFFFFF); } -static void WIFI_initCRC32Table() +void WIFI_initCRC32Table() { u32 polynomial = 0x04C11DB7; @@ -734,15 +679,14 @@ void WIFI_write16(wifimac_t *wifi,u32 address, u16 val) case REG_WIFI_FORCEPS: if((val & 0x8000) && (!wifi->powerOnPending)) { - /* BOOL newPower = ((val & 0x0001)?FALSE:TRUE); + BOOL newPower = ((val & 0x0001)?FALSE:TRUE); if(newPower != wifi->powerOn) { if(!newPower) wifi->powerOn = FALSE; else wifi->powerOnPending = TRUE; - }*/ - wifi->powerOn = ((val & 0x0001) ? FALSE : TRUE); + } } break; case REG_WIFI_POWERACK: @@ -1261,20 +1205,20 @@ int WIFI_SoftAP_Init(wifimac_t *wifi) if(wifiMac.netEnabled) { - if(desmume_pcap_findalldevs(&alldevs, errbuf) == -1) + if(PCAP::pcap_findalldevs_ex(PCAP_SRC_IF_STRING, NULL, &alldevs, errbuf) == -1) { printf("SoftAP: PCAP error with pcap_findalldevs_ex(): %s\n", errbuf); return 0; } - wifi->SoftAP.bridge = desmume_pcap_open(WIFI_index_device(alldevs,CommonSettings.wifiBridgeAdapterNum)->name, PACKET_SIZE, 0, 1, errbuf); + wifi->SoftAP.bridge = PCAP::pcap_open(WIFI_index_device(alldevs,CommonSettings.wifiBridgeAdapterNum)->name, PACKET_SIZE, 0, 1, NULL, errbuf); if(wifi->SoftAP.bridge == NULL) { printf("SoftAP: PCAP error with pcap_open(): %s\n", errbuf); return 0; } - desmume_pcap_freealldevs(alldevs); + PCAP::pcap_freealldevs(alldevs); } return 1; @@ -1285,14 +1229,14 @@ void WIFI_SoftAP_Shutdown(wifimac_t *wifi) if(wifiMac.netEnabled) { if(wifi->SoftAP.bridge != NULL) - desmume_pcap_close(wifi->SoftAP.bridge); + PCAP::pcap_close(wifi->SoftAP.bridge); } if(wifi->SoftAP.curPacket) delete wifi->SoftAP.curPacket; } -static void WIFI_SoftAP_MakeRXHeader(wifimac_t *wifi, u16 flags, u16 xferRate, u16 len, u8 maxRSSI, u8 minRSSI) +void WIFI_SoftAP_MakeRXHeader(wifimac_t *wifi, u16 flags, u16 xferRate, u16 len, u8 maxRSSI, u8 minRSSI) { *(u16*)&wifi->SoftAP.curPacket[0] = flags; @@ -1454,7 +1398,7 @@ void WIFI_SoftAP_RecvPacketFromDS(wifimac_t *wifi, u8 *packet, int len) // TODO ? if(wifi->netEnabled) //dont try to pcap out the packet unless network is enabled - desmume_pcap_sendpacket(wifi->SoftAP.bridge, ethernetframe, eflen); + PCAP::pcap_sendpacket(wifi->SoftAP.bridge, ethernetframe, eflen); delete ethernetframe; } @@ -1462,7 +1406,7 @@ void WIFI_SoftAP_RecvPacketFromDS(wifimac_t *wifi, u8 *packet, int len) } } -static void WIFI_SoftAP_SendBeacon(wifimac_t *wifi) +void WIFI_SoftAP_SendBeacon(wifimac_t *wifi) { int packetLen = sizeof(SoftAP_Beacon); int totalLen = (packetLen + 12); @@ -1498,9 +1442,7 @@ void WIFI_SoftAP_usTrigger(wifimac_t *wifi) { //if(wifi->ioMem[0xD0 >> 1] & 0x0400) { - //zero sez: every 1/10 second? does it have to be precise? this is so costly.. - //if((wifi->SoftAP.usecCounter % 100000) == 0) - if((wifi->SoftAP.usecCounter & 131071) == 0) + if((wifi->SoftAP.usecCounter % 100000) == 0) { WIFI_SoftAP_SendBeacon(wifi); } diff --git a/desmume/src/wifi.h b/src/wifi.h similarity index 100% rename from desmume/src/wifi.h rename to src/wifi.h diff --git a/desmume/src/windows/7z/7zip.lib b/src/windows/7z/7zip.lib similarity index 100% rename from desmume/src/windows/7z/7zip.lib rename to src/windows/7z/7zip.lib diff --git a/desmume/src/windows/7z/7zip.vcproj b/src/windows/7z/7zip.vcproj similarity index 100% rename from desmume/src/windows/7z/7zip.vcproj rename to src/windows/7z/7zip.vcproj diff --git a/desmume/src/windows/7z/C/7zCrc.c b/src/windows/7z/C/7zCrc.c similarity index 100% rename from desmume/src/windows/7z/C/7zCrc.c rename to src/windows/7z/C/7zCrc.c diff --git a/desmume/src/windows/7z/C/7zCrc.h b/src/windows/7z/C/7zCrc.h similarity index 100% rename from desmume/src/windows/7z/C/7zCrc.h rename to src/windows/7z/C/7zCrc.h diff --git a/desmume/src/windows/7z/C/Aes.c b/src/windows/7z/C/Aes.c similarity index 100% rename from desmume/src/windows/7z/C/Aes.c rename to src/windows/7z/C/Aes.c diff --git a/desmume/src/windows/7z/C/Aes.h b/src/windows/7z/C/Aes.h similarity index 100% rename from desmume/src/windows/7z/C/Aes.h rename to src/windows/7z/C/Aes.h diff --git a/desmume/src/windows/7z/C/Alloc.c b/src/windows/7z/C/Alloc.c similarity index 100% rename from desmume/src/windows/7z/C/Alloc.c rename to src/windows/7z/C/Alloc.c diff --git a/desmume/src/windows/7z/C/Alloc.h b/src/windows/7z/C/Alloc.h similarity index 100% rename from desmume/src/windows/7z/C/Alloc.h rename to src/windows/7z/C/Alloc.h diff --git a/desmume/src/windows/7z/C/Bra.c b/src/windows/7z/C/Bra.c similarity index 100% rename from desmume/src/windows/7z/C/Bra.c rename to src/windows/7z/C/Bra.c diff --git a/desmume/src/windows/7z/C/Bra.h b/src/windows/7z/C/Bra.h similarity index 100% rename from desmume/src/windows/7z/C/Bra.h rename to src/windows/7z/C/Bra.h diff --git a/desmume/src/windows/7z/C/Bra86.c b/src/windows/7z/C/Bra86.c similarity index 100% rename from desmume/src/windows/7z/C/Bra86.c rename to src/windows/7z/C/Bra86.c diff --git a/desmume/src/windows/7z/C/BraIA64.c b/src/windows/7z/C/BraIA64.c similarity index 100% rename from desmume/src/windows/7z/C/BraIA64.c rename to src/windows/7z/C/BraIA64.c diff --git a/desmume/src/windows/7z/C/BwtSort.c b/src/windows/7z/C/BwtSort.c similarity index 100% rename from desmume/src/windows/7z/C/BwtSort.c rename to src/windows/7z/C/BwtSort.c diff --git a/desmume/src/windows/7z/C/BwtSort.h b/src/windows/7z/C/BwtSort.h similarity index 100% rename from desmume/src/windows/7z/C/BwtSort.h rename to src/windows/7z/C/BwtSort.h diff --git a/desmume/src/windows/7z/C/CpuArch.h b/src/windows/7z/C/CpuArch.h similarity index 100% rename from desmume/src/windows/7z/C/CpuArch.h rename to src/windows/7z/C/CpuArch.h diff --git a/desmume/src/windows/7z/C/HuffEnc.c b/src/windows/7z/C/HuffEnc.c similarity index 100% rename from desmume/src/windows/7z/C/HuffEnc.c rename to src/windows/7z/C/HuffEnc.c diff --git a/desmume/src/windows/7z/C/HuffEnc.h b/src/windows/7z/C/HuffEnc.h similarity index 100% rename from desmume/src/windows/7z/C/HuffEnc.h rename to src/windows/7z/C/HuffEnc.h diff --git a/desmume/src/windows/7z/C/LzFind.c b/src/windows/7z/C/LzFind.c similarity index 100% rename from desmume/src/windows/7z/C/LzFind.c rename to src/windows/7z/C/LzFind.c diff --git a/desmume/src/windows/7z/C/LzFind.h b/src/windows/7z/C/LzFind.h similarity index 100% rename from desmume/src/windows/7z/C/LzFind.h rename to src/windows/7z/C/LzFind.h diff --git a/desmume/src/windows/7z/C/LzFindMt.c b/src/windows/7z/C/LzFindMt.c similarity index 100% rename from desmume/src/windows/7z/C/LzFindMt.c rename to src/windows/7z/C/LzFindMt.c diff --git a/desmume/src/windows/7z/C/LzFindMt.h b/src/windows/7z/C/LzFindMt.h similarity index 100% rename from desmume/src/windows/7z/C/LzFindMt.h rename to src/windows/7z/C/LzFindMt.h diff --git a/desmume/src/windows/7z/C/LzHash.h b/src/windows/7z/C/LzHash.h similarity index 100% rename from desmume/src/windows/7z/C/LzHash.h rename to src/windows/7z/C/LzHash.h diff --git a/desmume/src/windows/7z/C/LzmaDec.c b/src/windows/7z/C/LzmaDec.c similarity index 100% rename from desmume/src/windows/7z/C/LzmaDec.c rename to src/windows/7z/C/LzmaDec.c diff --git a/desmume/src/windows/7z/C/LzmaDec.h b/src/windows/7z/C/LzmaDec.h similarity index 100% rename from desmume/src/windows/7z/C/LzmaDec.h rename to src/windows/7z/C/LzmaDec.h diff --git a/desmume/src/windows/7z/C/LzmaEnc.c b/src/windows/7z/C/LzmaEnc.c similarity index 100% rename from desmume/src/windows/7z/C/LzmaEnc.c rename to src/windows/7z/C/LzmaEnc.c diff --git a/desmume/src/windows/7z/C/LzmaEnc.h b/src/windows/7z/C/LzmaEnc.h similarity index 100% rename from desmume/src/windows/7z/C/LzmaEnc.h rename to src/windows/7z/C/LzmaEnc.h diff --git a/desmume/src/windows/7z/C/RotateDefs.h b/src/windows/7z/C/RotateDefs.h similarity index 100% rename from desmume/src/windows/7z/C/RotateDefs.h rename to src/windows/7z/C/RotateDefs.h diff --git a/desmume/src/windows/7z/C/Sha256.c b/src/windows/7z/C/Sha256.c similarity index 100% rename from desmume/src/windows/7z/C/Sha256.c rename to src/windows/7z/C/Sha256.c diff --git a/desmume/src/windows/7z/C/Sha256.h b/src/windows/7z/C/Sha256.h similarity index 100% rename from desmume/src/windows/7z/C/Sha256.h rename to src/windows/7z/C/Sha256.h diff --git a/desmume/src/windows/7z/C/Sort.c b/src/windows/7z/C/Sort.c similarity index 100% rename from desmume/src/windows/7z/C/Sort.c rename to src/windows/7z/C/Sort.c diff --git a/desmume/src/windows/7z/C/Sort.h b/src/windows/7z/C/Sort.h similarity index 100% rename from desmume/src/windows/7z/C/Sort.h rename to src/windows/7z/C/Sort.h diff --git a/desmume/src/windows/7z/C/Threads.c b/src/windows/7z/C/Threads.c similarity index 100% rename from desmume/src/windows/7z/C/Threads.c rename to src/windows/7z/C/Threads.c diff --git a/desmume/src/windows/7z/C/Threads.h b/src/windows/7z/C/Threads.h similarity index 100% rename from desmume/src/windows/7z/C/Threads.h rename to src/windows/7z/C/Threads.h diff --git a/desmume/src/windows/7z/C/Types.h b/src/windows/7z/C/Types.h similarity index 100% rename from desmume/src/windows/7z/C/Types.h rename to src/windows/7z/C/Types.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/7z/7zCompressionMode.cpp b/src/windows/7z/CPP/7zip/Archive/7z/7zCompressionMode.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/7z/7zCompressionMode.cpp rename to src/windows/7z/CPP/7zip/Archive/7z/7zCompressionMode.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/7z/7zCompressionMode.h b/src/windows/7z/CPP/7zip/Archive/7z/7zCompressionMode.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/7z/7zCompressionMode.h rename to src/windows/7z/CPP/7zip/Archive/7z/7zCompressionMode.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/7z/7zDecode.cpp b/src/windows/7z/CPP/7zip/Archive/7z/7zDecode.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/7z/7zDecode.cpp rename to src/windows/7z/CPP/7zip/Archive/7z/7zDecode.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/7z/7zDecode.h b/src/windows/7z/CPP/7zip/Archive/7z/7zDecode.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/7z/7zDecode.h rename to src/windows/7z/CPP/7zip/Archive/7z/7zDecode.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/7z/7zExtract.cpp b/src/windows/7z/CPP/7zip/Archive/7z/7zExtract.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/7z/7zExtract.cpp rename to src/windows/7z/CPP/7zip/Archive/7z/7zExtract.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/7z/7zFolderInStream.cpp b/src/windows/7z/CPP/7zip/Archive/7z/7zFolderInStream.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/7z/7zFolderInStream.cpp rename to src/windows/7z/CPP/7zip/Archive/7z/7zFolderInStream.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/7z/7zFolderInStream.h b/src/windows/7z/CPP/7zip/Archive/7z/7zFolderInStream.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/7z/7zFolderInStream.h rename to src/windows/7z/CPP/7zip/Archive/7z/7zFolderInStream.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/7z/7zFolderOutStream.cpp b/src/windows/7z/CPP/7zip/Archive/7z/7zFolderOutStream.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/7z/7zFolderOutStream.cpp rename to src/windows/7z/CPP/7zip/Archive/7z/7zFolderOutStream.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/7z/7zFolderOutStream.h b/src/windows/7z/CPP/7zip/Archive/7z/7zFolderOutStream.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/7z/7zFolderOutStream.h rename to src/windows/7z/CPP/7zip/Archive/7z/7zFolderOutStream.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/7z/7zHandler.cpp b/src/windows/7z/CPP/7zip/Archive/7z/7zHandler.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/7z/7zHandler.cpp rename to src/windows/7z/CPP/7zip/Archive/7z/7zHandler.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/7z/7zHandler.h b/src/windows/7z/CPP/7zip/Archive/7z/7zHandler.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/7z/7zHandler.h rename to src/windows/7z/CPP/7zip/Archive/7z/7zHandler.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/7z/7zHeader.cpp b/src/windows/7z/CPP/7zip/Archive/7z/7zHeader.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/7z/7zHeader.cpp rename to src/windows/7z/CPP/7zip/Archive/7z/7zHeader.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/7z/7zHeader.h b/src/windows/7z/CPP/7zip/Archive/7z/7zHeader.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/7z/7zHeader.h rename to src/windows/7z/CPP/7zip/Archive/7z/7zHeader.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/7z/7zIn.cpp b/src/windows/7z/CPP/7zip/Archive/7z/7zIn.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/7z/7zIn.cpp rename to src/windows/7z/CPP/7zip/Archive/7z/7zIn.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/7z/7zIn.h b/src/windows/7z/CPP/7zip/Archive/7z/7zIn.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/7z/7zIn.h rename to src/windows/7z/CPP/7zip/Archive/7z/7zIn.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/7z/7zItem.h b/src/windows/7z/CPP/7zip/Archive/7z/7zItem.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/7z/7zItem.h rename to src/windows/7z/CPP/7zip/Archive/7z/7zItem.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/7z/7zProperties.cpp b/src/windows/7z/CPP/7zip/Archive/7z/7zProperties.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/7z/7zProperties.cpp rename to src/windows/7z/CPP/7zip/Archive/7z/7zProperties.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/7z/7zProperties.h b/src/windows/7z/CPP/7zip/Archive/7z/7zProperties.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/7z/7zProperties.h rename to src/windows/7z/CPP/7zip/Archive/7z/7zProperties.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/7z/7zRegister.cpp b/src/windows/7z/CPP/7zip/Archive/7z/7zRegister.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/7z/7zRegister.cpp rename to src/windows/7z/CPP/7zip/Archive/7z/7zRegister.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/7z/7zSpecStream.cpp b/src/windows/7z/CPP/7zip/Archive/7z/7zSpecStream.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/7z/7zSpecStream.cpp rename to src/windows/7z/CPP/7zip/Archive/7z/7zSpecStream.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/7z/7zSpecStream.h b/src/windows/7z/CPP/7zip/Archive/7z/7zSpecStream.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/7z/7zSpecStream.h rename to src/windows/7z/CPP/7zip/Archive/7z/7zSpecStream.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/7z/StdAfx.h b/src/windows/7z/CPP/7zip/Archive/7z/StdAfx.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/7z/StdAfx.h rename to src/windows/7z/CPP/7zip/Archive/7z/StdAfx.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/ArchiveExports.cpp b/src/windows/7z/CPP/7zip/Archive/ArchiveExports.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/ArchiveExports.cpp rename to src/windows/7z/CPP/7zip/Archive/ArchiveExports.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/BZip2/BZip2Handler.cpp b/src/windows/7z/CPP/7zip/Archive/BZip2/BZip2Handler.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/BZip2/BZip2Handler.cpp rename to src/windows/7z/CPP/7zip/Archive/BZip2/BZip2Handler.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/BZip2/BZip2Handler.h b/src/windows/7z/CPP/7zip/Archive/BZip2/BZip2Handler.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/BZip2/BZip2Handler.h rename to src/windows/7z/CPP/7zip/Archive/BZip2/BZip2Handler.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/BZip2/BZip2Item.h b/src/windows/7z/CPP/7zip/Archive/BZip2/BZip2Item.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/BZip2/BZip2Item.h rename to src/windows/7z/CPP/7zip/Archive/BZip2/BZip2Item.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/BZip2/StdAfx.h b/src/windows/7z/CPP/7zip/Archive/BZip2/StdAfx.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/BZip2/StdAfx.h rename to src/windows/7z/CPP/7zip/Archive/BZip2/StdAfx.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/BZip2/bz2Register.cpp b/src/windows/7z/CPP/7zip/Archive/BZip2/bz2Register.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/BZip2/bz2Register.cpp rename to src/windows/7z/CPP/7zip/Archive/BZip2/bz2Register.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Common/CoderMixer2.cpp b/src/windows/7z/CPP/7zip/Archive/Common/CoderMixer2.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Common/CoderMixer2.cpp rename to src/windows/7z/CPP/7zip/Archive/Common/CoderMixer2.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Common/CoderMixer2.h b/src/windows/7z/CPP/7zip/Archive/Common/CoderMixer2.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Common/CoderMixer2.h rename to src/windows/7z/CPP/7zip/Archive/Common/CoderMixer2.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Common/CoderMixer2MT.cpp b/src/windows/7z/CPP/7zip/Archive/Common/CoderMixer2MT.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Common/CoderMixer2MT.cpp rename to src/windows/7z/CPP/7zip/Archive/Common/CoderMixer2MT.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Common/CoderMixer2MT.h b/src/windows/7z/CPP/7zip/Archive/Common/CoderMixer2MT.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Common/CoderMixer2MT.h rename to src/windows/7z/CPP/7zip/Archive/Common/CoderMixer2MT.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Common/DummyOutStream.cpp b/src/windows/7z/CPP/7zip/Archive/Common/DummyOutStream.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Common/DummyOutStream.cpp rename to src/windows/7z/CPP/7zip/Archive/Common/DummyOutStream.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Common/DummyOutStream.h b/src/windows/7z/CPP/7zip/Archive/Common/DummyOutStream.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Common/DummyOutStream.h rename to src/windows/7z/CPP/7zip/Archive/Common/DummyOutStream.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Common/FindSignature.cpp b/src/windows/7z/CPP/7zip/Archive/Common/FindSignature.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Common/FindSignature.cpp rename to src/windows/7z/CPP/7zip/Archive/Common/FindSignature.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Common/FindSignature.h b/src/windows/7z/CPP/7zip/Archive/Common/FindSignature.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Common/FindSignature.h rename to src/windows/7z/CPP/7zip/Archive/Common/FindSignature.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Common/InStreamWithCRC.cpp b/src/windows/7z/CPP/7zip/Archive/Common/InStreamWithCRC.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Common/InStreamWithCRC.cpp rename to src/windows/7z/CPP/7zip/Archive/Common/InStreamWithCRC.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Common/InStreamWithCRC.h b/src/windows/7z/CPP/7zip/Archive/Common/InStreamWithCRC.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Common/InStreamWithCRC.h rename to src/windows/7z/CPP/7zip/Archive/Common/InStreamWithCRC.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Common/ItemNameUtils.cpp b/src/windows/7z/CPP/7zip/Archive/Common/ItemNameUtils.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Common/ItemNameUtils.cpp rename to src/windows/7z/CPP/7zip/Archive/Common/ItemNameUtils.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Common/ItemNameUtils.h b/src/windows/7z/CPP/7zip/Archive/Common/ItemNameUtils.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Common/ItemNameUtils.h rename to src/windows/7z/CPP/7zip/Archive/Common/ItemNameUtils.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Common/MultiStream.cpp b/src/windows/7z/CPP/7zip/Archive/Common/MultiStream.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Common/MultiStream.cpp rename to src/windows/7z/CPP/7zip/Archive/Common/MultiStream.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Common/MultiStream.h b/src/windows/7z/CPP/7zip/Archive/Common/MultiStream.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Common/MultiStream.h rename to src/windows/7z/CPP/7zip/Archive/Common/MultiStream.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Common/OutStreamWithCRC.cpp b/src/windows/7z/CPP/7zip/Archive/Common/OutStreamWithCRC.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Common/OutStreamWithCRC.cpp rename to src/windows/7z/CPP/7zip/Archive/Common/OutStreamWithCRC.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Common/OutStreamWithCRC.h b/src/windows/7z/CPP/7zip/Archive/Common/OutStreamWithCRC.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Common/OutStreamWithCRC.h rename to src/windows/7z/CPP/7zip/Archive/Common/OutStreamWithCRC.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Common/ParseProperties.cpp b/src/windows/7z/CPP/7zip/Archive/Common/ParseProperties.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Common/ParseProperties.cpp rename to src/windows/7z/CPP/7zip/Archive/Common/ParseProperties.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Common/ParseProperties.h b/src/windows/7z/CPP/7zip/Archive/Common/ParseProperties.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Common/ParseProperties.h rename to src/windows/7z/CPP/7zip/Archive/Common/ParseProperties.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Common/StdAfx.h b/src/windows/7z/CPP/7zip/Archive/Common/StdAfx.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Common/StdAfx.h rename to src/windows/7z/CPP/7zip/Archive/Common/StdAfx.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/DllExports2.cpp b/src/windows/7z/CPP/7zip/Archive/DllExports2.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/DllExports2.cpp rename to src/windows/7z/CPP/7zip/Archive/DllExports2.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/GZip/GZipHandler.cpp b/src/windows/7z/CPP/7zip/Archive/GZip/GZipHandler.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/GZip/GZipHandler.cpp rename to src/windows/7z/CPP/7zip/Archive/GZip/GZipHandler.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/GZip/GZipHandler.h b/src/windows/7z/CPP/7zip/Archive/GZip/GZipHandler.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/GZip/GZipHandler.h rename to src/windows/7z/CPP/7zip/Archive/GZip/GZipHandler.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/GZip/GZipHeader.cpp b/src/windows/7z/CPP/7zip/Archive/GZip/GZipHeader.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/GZip/GZipHeader.cpp rename to src/windows/7z/CPP/7zip/Archive/GZip/GZipHeader.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/GZip/GZipHeader.h b/src/windows/7z/CPP/7zip/Archive/GZip/GZipHeader.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/GZip/GZipHeader.h rename to src/windows/7z/CPP/7zip/Archive/GZip/GZipHeader.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/GZip/GZipIn.cpp b/src/windows/7z/CPP/7zip/Archive/GZip/GZipIn.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/GZip/GZipIn.cpp rename to src/windows/7z/CPP/7zip/Archive/GZip/GZipIn.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/GZip/GZipIn.h b/src/windows/7z/CPP/7zip/Archive/GZip/GZipIn.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/GZip/GZipIn.h rename to src/windows/7z/CPP/7zip/Archive/GZip/GZipIn.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/GZip/GZipItem.h b/src/windows/7z/CPP/7zip/Archive/GZip/GZipItem.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/GZip/GZipItem.h rename to src/windows/7z/CPP/7zip/Archive/GZip/GZipItem.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/GZip/GZipRegister.cpp b/src/windows/7z/CPP/7zip/Archive/GZip/GZipRegister.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/GZip/GZipRegister.cpp rename to src/windows/7z/CPP/7zip/Archive/GZip/GZipRegister.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/GZip/GZipUpdate.h b/src/windows/7z/CPP/7zip/Archive/GZip/GZipUpdate.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/GZip/GZipUpdate.h rename to src/windows/7z/CPP/7zip/Archive/GZip/GZipUpdate.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/GZip/StdAfx.h b/src/windows/7z/CPP/7zip/Archive/GZip/StdAfx.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/GZip/StdAfx.h rename to src/windows/7z/CPP/7zip/Archive/GZip/StdAfx.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/IArchive.h b/src/windows/7z/CPP/7zip/Archive/IArchive.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/IArchive.h rename to src/windows/7z/CPP/7zip/Archive/IArchive.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Lzh/LzhCRC.cpp b/src/windows/7z/CPP/7zip/Archive/Lzh/LzhCRC.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Lzh/LzhCRC.cpp rename to src/windows/7z/CPP/7zip/Archive/Lzh/LzhCRC.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Lzh/LzhCRC.h b/src/windows/7z/CPP/7zip/Archive/Lzh/LzhCRC.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Lzh/LzhCRC.h rename to src/windows/7z/CPP/7zip/Archive/Lzh/LzhCRC.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Lzh/LzhHandler.cpp b/src/windows/7z/CPP/7zip/Archive/Lzh/LzhHandler.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Lzh/LzhHandler.cpp rename to src/windows/7z/CPP/7zip/Archive/Lzh/LzhHandler.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Lzh/LzhHandler.h b/src/windows/7z/CPP/7zip/Archive/Lzh/LzhHandler.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Lzh/LzhHandler.h rename to src/windows/7z/CPP/7zip/Archive/Lzh/LzhHandler.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Lzh/LzhHeader.h b/src/windows/7z/CPP/7zip/Archive/Lzh/LzhHeader.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Lzh/LzhHeader.h rename to src/windows/7z/CPP/7zip/Archive/Lzh/LzhHeader.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Lzh/LzhIn.cpp b/src/windows/7z/CPP/7zip/Archive/Lzh/LzhIn.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Lzh/LzhIn.cpp rename to src/windows/7z/CPP/7zip/Archive/Lzh/LzhIn.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Lzh/LzhIn.h b/src/windows/7z/CPP/7zip/Archive/Lzh/LzhIn.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Lzh/LzhIn.h rename to src/windows/7z/CPP/7zip/Archive/Lzh/LzhIn.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Lzh/LzhItem.h b/src/windows/7z/CPP/7zip/Archive/Lzh/LzhItem.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Lzh/LzhItem.h rename to src/windows/7z/CPP/7zip/Archive/Lzh/LzhItem.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Lzh/LzhOutStreamWithCRC.cpp b/src/windows/7z/CPP/7zip/Archive/Lzh/LzhOutStreamWithCRC.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Lzh/LzhOutStreamWithCRC.cpp rename to src/windows/7z/CPP/7zip/Archive/Lzh/LzhOutStreamWithCRC.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Lzh/LzhOutStreamWithCRC.h b/src/windows/7z/CPP/7zip/Archive/Lzh/LzhOutStreamWithCRC.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Lzh/LzhOutStreamWithCRC.h rename to src/windows/7z/CPP/7zip/Archive/Lzh/LzhOutStreamWithCRC.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Lzh/LzhRegister.cpp b/src/windows/7z/CPP/7zip/Archive/Lzh/LzhRegister.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Lzh/LzhRegister.cpp rename to src/windows/7z/CPP/7zip/Archive/Lzh/LzhRegister.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Lzh/StdAfx.h b/src/windows/7z/CPP/7zip/Archive/Lzh/StdAfx.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Lzh/StdAfx.h rename to src/windows/7z/CPP/7zip/Archive/Lzh/StdAfx.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Lzma/LzmaArcRegister.cpp b/src/windows/7z/CPP/7zip/Archive/Lzma/LzmaArcRegister.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Lzma/LzmaArcRegister.cpp rename to src/windows/7z/CPP/7zip/Archive/Lzma/LzmaArcRegister.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Lzma/LzmaFiltersDecode.cpp b/src/windows/7z/CPP/7zip/Archive/Lzma/LzmaFiltersDecode.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Lzma/LzmaFiltersDecode.cpp rename to src/windows/7z/CPP/7zip/Archive/Lzma/LzmaFiltersDecode.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Lzma/LzmaFiltersDecode.h b/src/windows/7z/CPP/7zip/Archive/Lzma/LzmaFiltersDecode.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Lzma/LzmaFiltersDecode.h rename to src/windows/7z/CPP/7zip/Archive/Lzma/LzmaFiltersDecode.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Lzma/LzmaHandler.cpp b/src/windows/7z/CPP/7zip/Archive/Lzma/LzmaHandler.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Lzma/LzmaHandler.cpp rename to src/windows/7z/CPP/7zip/Archive/Lzma/LzmaHandler.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Lzma/LzmaHandler.h b/src/windows/7z/CPP/7zip/Archive/Lzma/LzmaHandler.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Lzma/LzmaHandler.h rename to src/windows/7z/CPP/7zip/Archive/Lzma/LzmaHandler.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Lzma/LzmaIn.cpp b/src/windows/7z/CPP/7zip/Archive/Lzma/LzmaIn.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Lzma/LzmaIn.cpp rename to src/windows/7z/CPP/7zip/Archive/Lzma/LzmaIn.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Lzma/LzmaIn.h b/src/windows/7z/CPP/7zip/Archive/Lzma/LzmaIn.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Lzma/LzmaIn.h rename to src/windows/7z/CPP/7zip/Archive/Lzma/LzmaIn.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Lzma/LzmaItem.h b/src/windows/7z/CPP/7zip/Archive/Lzma/LzmaItem.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Lzma/LzmaItem.h rename to src/windows/7z/CPP/7zip/Archive/Lzma/LzmaItem.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Lzma/StdAfx.h b/src/windows/7z/CPP/7zip/Archive/Lzma/StdAfx.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Lzma/StdAfx.h rename to src/windows/7z/CPP/7zip/Archive/Lzma/StdAfx.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Rar/RarHandler.cpp b/src/windows/7z/CPP/7zip/Archive/Rar/RarHandler.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Rar/RarHandler.cpp rename to src/windows/7z/CPP/7zip/Archive/Rar/RarHandler.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Rar/RarHandler.h b/src/windows/7z/CPP/7zip/Archive/Rar/RarHandler.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Rar/RarHandler.h rename to src/windows/7z/CPP/7zip/Archive/Rar/RarHandler.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Rar/RarHeader.cpp b/src/windows/7z/CPP/7zip/Archive/Rar/RarHeader.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Rar/RarHeader.cpp rename to src/windows/7z/CPP/7zip/Archive/Rar/RarHeader.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Rar/RarHeader.h b/src/windows/7z/CPP/7zip/Archive/Rar/RarHeader.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Rar/RarHeader.h rename to src/windows/7z/CPP/7zip/Archive/Rar/RarHeader.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Rar/RarIn.cpp b/src/windows/7z/CPP/7zip/Archive/Rar/RarIn.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Rar/RarIn.cpp rename to src/windows/7z/CPP/7zip/Archive/Rar/RarIn.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Rar/RarIn.h b/src/windows/7z/CPP/7zip/Archive/Rar/RarIn.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Rar/RarIn.h rename to src/windows/7z/CPP/7zip/Archive/Rar/RarIn.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Rar/RarItem.cpp b/src/windows/7z/CPP/7zip/Archive/Rar/RarItem.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Rar/RarItem.cpp rename to src/windows/7z/CPP/7zip/Archive/Rar/RarItem.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Rar/RarItem.h b/src/windows/7z/CPP/7zip/Archive/Rar/RarItem.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Rar/RarItem.h rename to src/windows/7z/CPP/7zip/Archive/Rar/RarItem.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Rar/RarRegister.cpp b/src/windows/7z/CPP/7zip/Archive/Rar/RarRegister.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Rar/RarRegister.cpp rename to src/windows/7z/CPP/7zip/Archive/Rar/RarRegister.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Rar/RarVolumeInStream.cpp b/src/windows/7z/CPP/7zip/Archive/Rar/RarVolumeInStream.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Rar/RarVolumeInStream.cpp rename to src/windows/7z/CPP/7zip/Archive/Rar/RarVolumeInStream.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Rar/RarVolumeInStream.h b/src/windows/7z/CPP/7zip/Archive/Rar/RarVolumeInStream.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Rar/RarVolumeInStream.h rename to src/windows/7z/CPP/7zip/Archive/Rar/RarVolumeInStream.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Rar/StdAfx.h b/src/windows/7z/CPP/7zip/Archive/Rar/StdAfx.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Rar/StdAfx.h rename to src/windows/7z/CPP/7zip/Archive/Rar/StdAfx.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Split/SplitHandler.cpp b/src/windows/7z/CPP/7zip/Archive/Split/SplitHandler.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Split/SplitHandler.cpp rename to src/windows/7z/CPP/7zip/Archive/Split/SplitHandler.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Split/SplitHandler.h b/src/windows/7z/CPP/7zip/Archive/Split/SplitHandler.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Split/SplitHandler.h rename to src/windows/7z/CPP/7zip/Archive/Split/SplitHandler.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Split/SplitRegister.cpp b/src/windows/7z/CPP/7zip/Archive/Split/SplitRegister.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Split/SplitRegister.cpp rename to src/windows/7z/CPP/7zip/Archive/Split/SplitRegister.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Split/StdAfx.h b/src/windows/7z/CPP/7zip/Archive/Split/StdAfx.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Split/StdAfx.h rename to src/windows/7z/CPP/7zip/Archive/Split/StdAfx.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/StdAfx.h b/src/windows/7z/CPP/7zip/Archive/StdAfx.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/StdAfx.h rename to src/windows/7z/CPP/7zip/Archive/StdAfx.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Tar/StdAfx.h b/src/windows/7z/CPP/7zip/Archive/Tar/StdAfx.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Tar/StdAfx.h rename to src/windows/7z/CPP/7zip/Archive/Tar/StdAfx.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Tar/TarHandler.cpp b/src/windows/7z/CPP/7zip/Archive/Tar/TarHandler.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Tar/TarHandler.cpp rename to src/windows/7z/CPP/7zip/Archive/Tar/TarHandler.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Tar/TarHandler.h b/src/windows/7z/CPP/7zip/Archive/Tar/TarHandler.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Tar/TarHandler.h rename to src/windows/7z/CPP/7zip/Archive/Tar/TarHandler.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Tar/TarHeader.cpp b/src/windows/7z/CPP/7zip/Archive/Tar/TarHeader.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Tar/TarHeader.cpp rename to src/windows/7z/CPP/7zip/Archive/Tar/TarHeader.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Tar/TarHeader.h b/src/windows/7z/CPP/7zip/Archive/Tar/TarHeader.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Tar/TarHeader.h rename to src/windows/7z/CPP/7zip/Archive/Tar/TarHeader.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Tar/TarIn.cpp b/src/windows/7z/CPP/7zip/Archive/Tar/TarIn.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Tar/TarIn.cpp rename to src/windows/7z/CPP/7zip/Archive/Tar/TarIn.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Tar/TarIn.h b/src/windows/7z/CPP/7zip/Archive/Tar/TarIn.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Tar/TarIn.h rename to src/windows/7z/CPP/7zip/Archive/Tar/TarIn.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Tar/TarItem.h b/src/windows/7z/CPP/7zip/Archive/Tar/TarItem.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Tar/TarItem.h rename to src/windows/7z/CPP/7zip/Archive/Tar/TarItem.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Tar/TarRegister.cpp b/src/windows/7z/CPP/7zip/Archive/Tar/TarRegister.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Tar/TarRegister.cpp rename to src/windows/7z/CPP/7zip/Archive/Tar/TarRegister.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Zip/StdAfx.h b/src/windows/7z/CPP/7zip/Archive/Zip/StdAfx.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Zip/StdAfx.h rename to src/windows/7z/CPP/7zip/Archive/Zip/StdAfx.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Zip/ZipCompressionMode.h b/src/windows/7z/CPP/7zip/Archive/Zip/ZipCompressionMode.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Zip/ZipCompressionMode.h rename to src/windows/7z/CPP/7zip/Archive/Zip/ZipCompressionMode.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Zip/ZipHandler.cpp b/src/windows/7z/CPP/7zip/Archive/Zip/ZipHandler.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Zip/ZipHandler.cpp rename to src/windows/7z/CPP/7zip/Archive/Zip/ZipHandler.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Zip/ZipHandler.h b/src/windows/7z/CPP/7zip/Archive/Zip/ZipHandler.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Zip/ZipHandler.h rename to src/windows/7z/CPP/7zip/Archive/Zip/ZipHandler.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Zip/ZipHeader.cpp b/src/windows/7z/CPP/7zip/Archive/Zip/ZipHeader.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Zip/ZipHeader.cpp rename to src/windows/7z/CPP/7zip/Archive/Zip/ZipHeader.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Zip/ZipHeader.h b/src/windows/7z/CPP/7zip/Archive/Zip/ZipHeader.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Zip/ZipHeader.h rename to src/windows/7z/CPP/7zip/Archive/Zip/ZipHeader.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Zip/ZipIn.cpp b/src/windows/7z/CPP/7zip/Archive/Zip/ZipIn.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Zip/ZipIn.cpp rename to src/windows/7z/CPP/7zip/Archive/Zip/ZipIn.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Zip/ZipIn.h b/src/windows/7z/CPP/7zip/Archive/Zip/ZipIn.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Zip/ZipIn.h rename to src/windows/7z/CPP/7zip/Archive/Zip/ZipIn.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Zip/ZipItem.cpp b/src/windows/7z/CPP/7zip/Archive/Zip/ZipItem.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Zip/ZipItem.cpp rename to src/windows/7z/CPP/7zip/Archive/Zip/ZipItem.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Zip/ZipItem.h b/src/windows/7z/CPP/7zip/Archive/Zip/ZipItem.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Zip/ZipItem.h rename to src/windows/7z/CPP/7zip/Archive/Zip/ZipItem.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Zip/ZipItemEx.h b/src/windows/7z/CPP/7zip/Archive/Zip/ZipItemEx.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Zip/ZipItemEx.h rename to src/windows/7z/CPP/7zip/Archive/Zip/ZipItemEx.h diff --git a/desmume/src/windows/7z/CPP/7zip/Archive/Zip/ZipRegister.cpp b/src/windows/7z/CPP/7zip/Archive/Zip/ZipRegister.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Archive/Zip/ZipRegister.cpp rename to src/windows/7z/CPP/7zip/Archive/Zip/ZipRegister.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Common/CreateCoder.cpp b/src/windows/7z/CPP/7zip/Common/CreateCoder.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Common/CreateCoder.cpp rename to src/windows/7z/CPP/7zip/Common/CreateCoder.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Common/CreateCoder.h b/src/windows/7z/CPP/7zip/Common/CreateCoder.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Common/CreateCoder.h rename to src/windows/7z/CPP/7zip/Common/CreateCoder.h diff --git a/desmume/src/windows/7z/CPP/7zip/Common/DeclareArcs.h b/src/windows/7z/CPP/7zip/Common/DeclareArcs.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Common/DeclareArcs.h rename to src/windows/7z/CPP/7zip/Common/DeclareArcs.h diff --git a/desmume/src/windows/7z/CPP/7zip/Common/DeclareCodecs.h b/src/windows/7z/CPP/7zip/Common/DeclareCodecs.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Common/DeclareCodecs.h rename to src/windows/7z/CPP/7zip/Common/DeclareCodecs.h diff --git a/desmume/src/windows/7z/CPP/7zip/Common/FilterCoder.cpp b/src/windows/7z/CPP/7zip/Common/FilterCoder.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Common/FilterCoder.cpp rename to src/windows/7z/CPP/7zip/Common/FilterCoder.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Common/FilterCoder.h b/src/windows/7z/CPP/7zip/Common/FilterCoder.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Common/FilterCoder.h rename to src/windows/7z/CPP/7zip/Common/FilterCoder.h diff --git a/desmume/src/windows/7z/CPP/7zip/Common/InBuffer.cpp b/src/windows/7z/CPP/7zip/Common/InBuffer.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Common/InBuffer.cpp rename to src/windows/7z/CPP/7zip/Common/InBuffer.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Common/InBuffer.h b/src/windows/7z/CPP/7zip/Common/InBuffer.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Common/InBuffer.h rename to src/windows/7z/CPP/7zip/Common/InBuffer.h diff --git a/desmume/src/windows/7z/CPP/7zip/Common/InOutTempBuffer.cpp b/src/windows/7z/CPP/7zip/Common/InOutTempBuffer.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Common/InOutTempBuffer.cpp rename to src/windows/7z/CPP/7zip/Common/InOutTempBuffer.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Common/InOutTempBuffer.h b/src/windows/7z/CPP/7zip/Common/InOutTempBuffer.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Common/InOutTempBuffer.h rename to src/windows/7z/CPP/7zip/Common/InOutTempBuffer.h diff --git a/desmume/src/windows/7z/CPP/7zip/Common/LimitedStreams.cpp b/src/windows/7z/CPP/7zip/Common/LimitedStreams.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Common/LimitedStreams.cpp rename to src/windows/7z/CPP/7zip/Common/LimitedStreams.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Common/LimitedStreams.h b/src/windows/7z/CPP/7zip/Common/LimitedStreams.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Common/LimitedStreams.h rename to src/windows/7z/CPP/7zip/Common/LimitedStreams.h diff --git a/desmume/src/windows/7z/CPP/7zip/Common/LockedStream.cpp b/src/windows/7z/CPP/7zip/Common/LockedStream.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Common/LockedStream.cpp rename to src/windows/7z/CPP/7zip/Common/LockedStream.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Common/LockedStream.h b/src/windows/7z/CPP/7zip/Common/LockedStream.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Common/LockedStream.h rename to src/windows/7z/CPP/7zip/Common/LockedStream.h diff --git a/desmume/src/windows/7z/CPP/7zip/Common/MemBlocks.cpp b/src/windows/7z/CPP/7zip/Common/MemBlocks.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Common/MemBlocks.cpp rename to src/windows/7z/CPP/7zip/Common/MemBlocks.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Common/MemBlocks.h b/src/windows/7z/CPP/7zip/Common/MemBlocks.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Common/MemBlocks.h rename to src/windows/7z/CPP/7zip/Common/MemBlocks.h diff --git a/desmume/src/windows/7z/CPP/7zip/Common/MethodId.cpp b/src/windows/7z/CPP/7zip/Common/MethodId.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Common/MethodId.cpp rename to src/windows/7z/CPP/7zip/Common/MethodId.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Common/MethodId.h b/src/windows/7z/CPP/7zip/Common/MethodId.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Common/MethodId.h rename to src/windows/7z/CPP/7zip/Common/MethodId.h diff --git a/desmume/src/windows/7z/CPP/7zip/Common/MethodProps.cpp b/src/windows/7z/CPP/7zip/Common/MethodProps.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Common/MethodProps.cpp rename to src/windows/7z/CPP/7zip/Common/MethodProps.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Common/MethodProps.h b/src/windows/7z/CPP/7zip/Common/MethodProps.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Common/MethodProps.h rename to src/windows/7z/CPP/7zip/Common/MethodProps.h diff --git a/desmume/src/windows/7z/CPP/7zip/Common/OffsetStream.cpp b/src/windows/7z/CPP/7zip/Common/OffsetStream.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Common/OffsetStream.cpp rename to src/windows/7z/CPP/7zip/Common/OffsetStream.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Common/OffsetStream.h b/src/windows/7z/CPP/7zip/Common/OffsetStream.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Common/OffsetStream.h rename to src/windows/7z/CPP/7zip/Common/OffsetStream.h diff --git a/desmume/src/windows/7z/CPP/7zip/Common/OutBuffer.cpp b/src/windows/7z/CPP/7zip/Common/OutBuffer.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Common/OutBuffer.cpp rename to src/windows/7z/CPP/7zip/Common/OutBuffer.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Common/OutBuffer.h b/src/windows/7z/CPP/7zip/Common/OutBuffer.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Common/OutBuffer.h rename to src/windows/7z/CPP/7zip/Common/OutBuffer.h diff --git a/desmume/src/windows/7z/CPP/7zip/Common/OutMemStream.cpp b/src/windows/7z/CPP/7zip/Common/OutMemStream.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Common/OutMemStream.cpp rename to src/windows/7z/CPP/7zip/Common/OutMemStream.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Common/OutMemStream.h b/src/windows/7z/CPP/7zip/Common/OutMemStream.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Common/OutMemStream.h rename to src/windows/7z/CPP/7zip/Common/OutMemStream.h diff --git a/desmume/src/windows/7z/CPP/7zip/Common/ProgressMt.cpp b/src/windows/7z/CPP/7zip/Common/ProgressMt.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Common/ProgressMt.cpp rename to src/windows/7z/CPP/7zip/Common/ProgressMt.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Common/ProgressMt.h b/src/windows/7z/CPP/7zip/Common/ProgressMt.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Common/ProgressMt.h rename to src/windows/7z/CPP/7zip/Common/ProgressMt.h diff --git a/desmume/src/windows/7z/CPP/7zip/Common/ProgressUtils.cpp b/src/windows/7z/CPP/7zip/Common/ProgressUtils.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Common/ProgressUtils.cpp rename to src/windows/7z/CPP/7zip/Common/ProgressUtils.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Common/ProgressUtils.h b/src/windows/7z/CPP/7zip/Common/ProgressUtils.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Common/ProgressUtils.h rename to src/windows/7z/CPP/7zip/Common/ProgressUtils.h diff --git a/desmume/src/windows/7z/CPP/7zip/Common/RegisterArc.h b/src/windows/7z/CPP/7zip/Common/RegisterArc.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Common/RegisterArc.h rename to src/windows/7z/CPP/7zip/Common/RegisterArc.h diff --git a/desmume/src/windows/7z/CPP/7zip/Common/RegisterCodec.h b/src/windows/7z/CPP/7zip/Common/RegisterCodec.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Common/RegisterCodec.h rename to src/windows/7z/CPP/7zip/Common/RegisterCodec.h diff --git a/desmume/src/windows/7z/CPP/7zip/Common/StdAfx.h b/src/windows/7z/CPP/7zip/Common/StdAfx.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Common/StdAfx.h rename to src/windows/7z/CPP/7zip/Common/StdAfx.h diff --git a/desmume/src/windows/7z/CPP/7zip/Common/StreamBinder.cpp b/src/windows/7z/CPP/7zip/Common/StreamBinder.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Common/StreamBinder.cpp rename to src/windows/7z/CPP/7zip/Common/StreamBinder.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Common/StreamBinder.h b/src/windows/7z/CPP/7zip/Common/StreamBinder.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Common/StreamBinder.h rename to src/windows/7z/CPP/7zip/Common/StreamBinder.h diff --git a/desmume/src/windows/7z/CPP/7zip/Common/StreamObjects.cpp b/src/windows/7z/CPP/7zip/Common/StreamObjects.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Common/StreamObjects.cpp rename to src/windows/7z/CPP/7zip/Common/StreamObjects.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Common/StreamObjects.h b/src/windows/7z/CPP/7zip/Common/StreamObjects.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Common/StreamObjects.h rename to src/windows/7z/CPP/7zip/Common/StreamObjects.h diff --git a/desmume/src/windows/7z/CPP/7zip/Common/StreamUtils.cpp b/src/windows/7z/CPP/7zip/Common/StreamUtils.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Common/StreamUtils.cpp rename to src/windows/7z/CPP/7zip/Common/StreamUtils.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Common/StreamUtils.h b/src/windows/7z/CPP/7zip/Common/StreamUtils.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Common/StreamUtils.h rename to src/windows/7z/CPP/7zip/Common/StreamUtils.h diff --git a/desmume/src/windows/7z/CPP/7zip/Common/VirtThread.cpp b/src/windows/7z/CPP/7zip/Common/VirtThread.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Common/VirtThread.cpp rename to src/windows/7z/CPP/7zip/Common/VirtThread.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Common/VirtThread.h b/src/windows/7z/CPP/7zip/Common/VirtThread.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Common/VirtThread.h rename to src/windows/7z/CPP/7zip/Common/VirtThread.h diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/BZip2Const.h b/src/windows/7z/CPP/7zip/Compress/BZip2Const.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/BZip2Const.h rename to src/windows/7z/CPP/7zip/Compress/BZip2Const.h diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/BZip2Crc.cpp b/src/windows/7z/CPP/7zip/Compress/BZip2Crc.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/BZip2Crc.cpp rename to src/windows/7z/CPP/7zip/Compress/BZip2Crc.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/BZip2Crc.h b/src/windows/7z/CPP/7zip/Compress/BZip2Crc.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/BZip2Crc.h rename to src/windows/7z/CPP/7zip/Compress/BZip2Crc.h diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/BZip2Decoder.cpp b/src/windows/7z/CPP/7zip/Compress/BZip2Decoder.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/BZip2Decoder.cpp rename to src/windows/7z/CPP/7zip/Compress/BZip2Decoder.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/BZip2Decoder.h b/src/windows/7z/CPP/7zip/Compress/BZip2Decoder.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/BZip2Decoder.h rename to src/windows/7z/CPP/7zip/Compress/BZip2Decoder.h diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/BZip2Register.cpp b/src/windows/7z/CPP/7zip/Compress/BZip2Register.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/BZip2Register.cpp rename to src/windows/7z/CPP/7zip/Compress/BZip2Register.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/Bcj2Coder.cpp b/src/windows/7z/CPP/7zip/Compress/Bcj2Coder.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/Bcj2Coder.cpp rename to src/windows/7z/CPP/7zip/Compress/Bcj2Coder.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/Bcj2Coder.h b/src/windows/7z/CPP/7zip/Compress/Bcj2Coder.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/Bcj2Coder.h rename to src/windows/7z/CPP/7zip/Compress/Bcj2Coder.h diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/Bcj2Register.cpp b/src/windows/7z/CPP/7zip/Compress/Bcj2Register.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/Bcj2Register.cpp rename to src/windows/7z/CPP/7zip/Compress/Bcj2Register.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/BcjCoder.cpp b/src/windows/7z/CPP/7zip/Compress/BcjCoder.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/BcjCoder.cpp rename to src/windows/7z/CPP/7zip/Compress/BcjCoder.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/BcjCoder.h b/src/windows/7z/CPP/7zip/Compress/BcjCoder.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/BcjCoder.h rename to src/windows/7z/CPP/7zip/Compress/BcjCoder.h diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/BcjRegister.cpp b/src/windows/7z/CPP/7zip/Compress/BcjRegister.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/BcjRegister.cpp rename to src/windows/7z/CPP/7zip/Compress/BcjRegister.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/BitlDecoder.cpp b/src/windows/7z/CPP/7zip/Compress/BitlDecoder.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/BitlDecoder.cpp rename to src/windows/7z/CPP/7zip/Compress/BitlDecoder.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/BitlDecoder.h b/src/windows/7z/CPP/7zip/Compress/BitlDecoder.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/BitlDecoder.h rename to src/windows/7z/CPP/7zip/Compress/BitlDecoder.h diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/BitmDecoder.h b/src/windows/7z/CPP/7zip/Compress/BitmDecoder.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/BitmDecoder.h rename to src/windows/7z/CPP/7zip/Compress/BitmDecoder.h diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/BranchCoder.cpp b/src/windows/7z/CPP/7zip/Compress/BranchCoder.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/BranchCoder.cpp rename to src/windows/7z/CPP/7zip/Compress/BranchCoder.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/BranchCoder.h b/src/windows/7z/CPP/7zip/Compress/BranchCoder.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/BranchCoder.h rename to src/windows/7z/CPP/7zip/Compress/BranchCoder.h diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/BranchMisc.cpp b/src/windows/7z/CPP/7zip/Compress/BranchMisc.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/BranchMisc.cpp rename to src/windows/7z/CPP/7zip/Compress/BranchMisc.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/BranchMisc.h b/src/windows/7z/CPP/7zip/Compress/BranchMisc.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/BranchMisc.h rename to src/windows/7z/CPP/7zip/Compress/BranchMisc.h diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/BranchRegister.cpp b/src/windows/7z/CPP/7zip/Compress/BranchRegister.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/BranchRegister.cpp rename to src/windows/7z/CPP/7zip/Compress/BranchRegister.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/ByteSwap.cpp b/src/windows/7z/CPP/7zip/Compress/ByteSwap.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/ByteSwap.cpp rename to src/windows/7z/CPP/7zip/Compress/ByteSwap.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/ByteSwap.h b/src/windows/7z/CPP/7zip/Compress/ByteSwap.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/ByteSwap.h rename to src/windows/7z/CPP/7zip/Compress/ByteSwap.h diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/ByteSwapRegister.cpp b/src/windows/7z/CPP/7zip/Compress/ByteSwapRegister.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/ByteSwapRegister.cpp rename to src/windows/7z/CPP/7zip/Compress/ByteSwapRegister.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/Codec.def b/src/windows/7z/CPP/7zip/Compress/Codec.def similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/Codec.def rename to src/windows/7z/CPP/7zip/Compress/Codec.def diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/CodecExports.cpp b/src/windows/7z/CPP/7zip/Compress/CodecExports.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/CodecExports.cpp rename to src/windows/7z/CPP/7zip/Compress/CodecExports.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/CopyCoder.cpp b/src/windows/7z/CPP/7zip/Compress/CopyCoder.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/CopyCoder.cpp rename to src/windows/7z/CPP/7zip/Compress/CopyCoder.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/CopyCoder.h b/src/windows/7z/CPP/7zip/Compress/CopyCoder.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/CopyCoder.h rename to src/windows/7z/CPP/7zip/Compress/CopyCoder.h diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/CopyRegister.cpp b/src/windows/7z/CPP/7zip/Compress/CopyRegister.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/CopyRegister.cpp rename to src/windows/7z/CPP/7zip/Compress/CopyRegister.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/Deflate64Register.cpp b/src/windows/7z/CPP/7zip/Compress/Deflate64Register.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/Deflate64Register.cpp rename to src/windows/7z/CPP/7zip/Compress/Deflate64Register.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/DeflateConst.h b/src/windows/7z/CPP/7zip/Compress/DeflateConst.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/DeflateConst.h rename to src/windows/7z/CPP/7zip/Compress/DeflateConst.h diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/DeflateDecoder.cpp b/src/windows/7z/CPP/7zip/Compress/DeflateDecoder.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/DeflateDecoder.cpp rename to src/windows/7z/CPP/7zip/Compress/DeflateDecoder.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/DeflateDecoder.h b/src/windows/7z/CPP/7zip/Compress/DeflateDecoder.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/DeflateDecoder.h rename to src/windows/7z/CPP/7zip/Compress/DeflateDecoder.h diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/DeflateNsisRegister.cpp b/src/windows/7z/CPP/7zip/Compress/DeflateNsisRegister.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/DeflateNsisRegister.cpp rename to src/windows/7z/CPP/7zip/Compress/DeflateNsisRegister.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/DeflateRegister.cpp b/src/windows/7z/CPP/7zip/Compress/DeflateRegister.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/DeflateRegister.cpp rename to src/windows/7z/CPP/7zip/Compress/DeflateRegister.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/HuffmanDecoder.h b/src/windows/7z/CPP/7zip/Compress/HuffmanDecoder.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/HuffmanDecoder.h rename to src/windows/7z/CPP/7zip/Compress/HuffmanDecoder.h diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/ImplodeDecoder.cpp b/src/windows/7z/CPP/7zip/Compress/ImplodeDecoder.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/ImplodeDecoder.cpp rename to src/windows/7z/CPP/7zip/Compress/ImplodeDecoder.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/ImplodeDecoder.h b/src/windows/7z/CPP/7zip/Compress/ImplodeDecoder.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/ImplodeDecoder.h rename to src/windows/7z/CPP/7zip/Compress/ImplodeDecoder.h diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/ImplodeHuffmanDecoder.cpp b/src/windows/7z/CPP/7zip/Compress/ImplodeHuffmanDecoder.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/ImplodeHuffmanDecoder.cpp rename to src/windows/7z/CPP/7zip/Compress/ImplodeHuffmanDecoder.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/ImplodeHuffmanDecoder.h b/src/windows/7z/CPP/7zip/Compress/ImplodeHuffmanDecoder.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/ImplodeHuffmanDecoder.h rename to src/windows/7z/CPP/7zip/Compress/ImplodeHuffmanDecoder.h diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/LzOutWindow.cpp b/src/windows/7z/CPP/7zip/Compress/LzOutWindow.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/LzOutWindow.cpp rename to src/windows/7z/CPP/7zip/Compress/LzOutWindow.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/LzOutWindow.h b/src/windows/7z/CPP/7zip/Compress/LzOutWindow.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/LzOutWindow.h rename to src/windows/7z/CPP/7zip/Compress/LzOutWindow.h diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/LzhDecoder.cpp b/src/windows/7z/CPP/7zip/Compress/LzhDecoder.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/LzhDecoder.cpp rename to src/windows/7z/CPP/7zip/Compress/LzhDecoder.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/LzhDecoder.h b/src/windows/7z/CPP/7zip/Compress/LzhDecoder.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/LzhDecoder.h rename to src/windows/7z/CPP/7zip/Compress/LzhDecoder.h diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/LzmaDecoder.cpp b/src/windows/7z/CPP/7zip/Compress/LzmaDecoder.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/LzmaDecoder.cpp rename to src/windows/7z/CPP/7zip/Compress/LzmaDecoder.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/LzmaDecoder.h b/src/windows/7z/CPP/7zip/Compress/LzmaDecoder.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/LzmaDecoder.h rename to src/windows/7z/CPP/7zip/Compress/LzmaDecoder.h diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/LzmaRegister.cpp b/src/windows/7z/CPP/7zip/Compress/LzmaRegister.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/LzmaRegister.cpp rename to src/windows/7z/CPP/7zip/Compress/LzmaRegister.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/Mtf8.h b/src/windows/7z/CPP/7zip/Compress/Mtf8.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/Mtf8.h rename to src/windows/7z/CPP/7zip/Compress/Mtf8.h diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/PpmdContext.h b/src/windows/7z/CPP/7zip/Compress/PpmdContext.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/PpmdContext.h rename to src/windows/7z/CPP/7zip/Compress/PpmdContext.h diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/PpmdDecode.h b/src/windows/7z/CPP/7zip/Compress/PpmdDecode.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/PpmdDecode.h rename to src/windows/7z/CPP/7zip/Compress/PpmdDecode.h diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/PpmdDecoder.cpp b/src/windows/7z/CPP/7zip/Compress/PpmdDecoder.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/PpmdDecoder.cpp rename to src/windows/7z/CPP/7zip/Compress/PpmdDecoder.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/PpmdDecoder.h b/src/windows/7z/CPP/7zip/Compress/PpmdDecoder.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/PpmdDecoder.h rename to src/windows/7z/CPP/7zip/Compress/PpmdDecoder.h diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/PpmdRegister.cpp b/src/windows/7z/CPP/7zip/Compress/PpmdRegister.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/PpmdRegister.cpp rename to src/windows/7z/CPP/7zip/Compress/PpmdRegister.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/PpmdSubAlloc.h b/src/windows/7z/CPP/7zip/Compress/PpmdSubAlloc.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/PpmdSubAlloc.h rename to src/windows/7z/CPP/7zip/Compress/PpmdSubAlloc.h diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/PpmdType.h b/src/windows/7z/CPP/7zip/Compress/PpmdType.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/PpmdType.h rename to src/windows/7z/CPP/7zip/Compress/PpmdType.h diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/RangeCoder.h b/src/windows/7z/CPP/7zip/Compress/RangeCoder.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/RangeCoder.h rename to src/windows/7z/CPP/7zip/Compress/RangeCoder.h diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/RangeCoderBit.h b/src/windows/7z/CPP/7zip/Compress/RangeCoderBit.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/RangeCoderBit.h rename to src/windows/7z/CPP/7zip/Compress/RangeCoderBit.h diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/Rar1Decoder.cpp b/src/windows/7z/CPP/7zip/Compress/Rar1Decoder.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/Rar1Decoder.cpp rename to src/windows/7z/CPP/7zip/Compress/Rar1Decoder.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/Rar1Decoder.h b/src/windows/7z/CPP/7zip/Compress/Rar1Decoder.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/Rar1Decoder.h rename to src/windows/7z/CPP/7zip/Compress/Rar1Decoder.h diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/Rar2Decoder.cpp b/src/windows/7z/CPP/7zip/Compress/Rar2Decoder.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/Rar2Decoder.cpp rename to src/windows/7z/CPP/7zip/Compress/Rar2Decoder.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/Rar2Decoder.h b/src/windows/7z/CPP/7zip/Compress/Rar2Decoder.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/Rar2Decoder.h rename to src/windows/7z/CPP/7zip/Compress/Rar2Decoder.h diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/Rar3Decoder.cpp b/src/windows/7z/CPP/7zip/Compress/Rar3Decoder.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/Rar3Decoder.cpp rename to src/windows/7z/CPP/7zip/Compress/Rar3Decoder.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/Rar3Decoder.h b/src/windows/7z/CPP/7zip/Compress/Rar3Decoder.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/Rar3Decoder.h rename to src/windows/7z/CPP/7zip/Compress/Rar3Decoder.h diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/Rar3Vm.cpp b/src/windows/7z/CPP/7zip/Compress/Rar3Vm.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/Rar3Vm.cpp rename to src/windows/7z/CPP/7zip/Compress/Rar3Vm.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/Rar3Vm.h b/src/windows/7z/CPP/7zip/Compress/Rar3Vm.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/Rar3Vm.h rename to src/windows/7z/CPP/7zip/Compress/Rar3Vm.h diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/RarCodecsRegister.cpp b/src/windows/7z/CPP/7zip/Compress/RarCodecsRegister.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/RarCodecsRegister.cpp rename to src/windows/7z/CPP/7zip/Compress/RarCodecsRegister.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/ShrinkDecoder.cpp b/src/windows/7z/CPP/7zip/Compress/ShrinkDecoder.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/ShrinkDecoder.cpp rename to src/windows/7z/CPP/7zip/Compress/ShrinkDecoder.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/ShrinkDecoder.h b/src/windows/7z/CPP/7zip/Compress/ShrinkDecoder.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/ShrinkDecoder.h rename to src/windows/7z/CPP/7zip/Compress/ShrinkDecoder.h diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/StdAfx.h b/src/windows/7z/CPP/7zip/Compress/StdAfx.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/StdAfx.h rename to src/windows/7z/CPP/7zip/Compress/StdAfx.h diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/ZlibDecoder.cpp b/src/windows/7z/CPP/7zip/Compress/ZlibDecoder.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/ZlibDecoder.cpp rename to src/windows/7z/CPP/7zip/Compress/ZlibDecoder.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Compress/ZlibDecoder.h b/src/windows/7z/CPP/7zip/Compress/ZlibDecoder.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Compress/ZlibDecoder.h rename to src/windows/7z/CPP/7zip/Compress/ZlibDecoder.h diff --git a/desmume/src/windows/7z/CPP/7zip/Crypto/7zAes.cpp b/src/windows/7z/CPP/7zip/Crypto/7zAes.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Crypto/7zAes.cpp rename to src/windows/7z/CPP/7zip/Crypto/7zAes.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Crypto/7zAes.h b/src/windows/7z/CPP/7zip/Crypto/7zAes.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Crypto/7zAes.h rename to src/windows/7z/CPP/7zip/Crypto/7zAes.h diff --git a/desmume/src/windows/7z/CPP/7zip/Crypto/7zAesRegister.cpp b/src/windows/7z/CPP/7zip/Crypto/7zAesRegister.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Crypto/7zAesRegister.cpp rename to src/windows/7z/CPP/7zip/Crypto/7zAesRegister.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Crypto/HmacSha1.cpp b/src/windows/7z/CPP/7zip/Crypto/HmacSha1.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Crypto/HmacSha1.cpp rename to src/windows/7z/CPP/7zip/Crypto/HmacSha1.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Crypto/HmacSha1.h b/src/windows/7z/CPP/7zip/Crypto/HmacSha1.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Crypto/HmacSha1.h rename to src/windows/7z/CPP/7zip/Crypto/HmacSha1.h diff --git a/desmume/src/windows/7z/CPP/7zip/Crypto/MyAes.cpp b/src/windows/7z/CPP/7zip/Crypto/MyAes.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Crypto/MyAes.cpp rename to src/windows/7z/CPP/7zip/Crypto/MyAes.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Crypto/MyAes.h b/src/windows/7z/CPP/7zip/Crypto/MyAes.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Crypto/MyAes.h rename to src/windows/7z/CPP/7zip/Crypto/MyAes.h diff --git a/desmume/src/windows/7z/CPP/7zip/Crypto/Pbkdf2HmacSha1.cpp b/src/windows/7z/CPP/7zip/Crypto/Pbkdf2HmacSha1.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Crypto/Pbkdf2HmacSha1.cpp rename to src/windows/7z/CPP/7zip/Crypto/Pbkdf2HmacSha1.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Crypto/Pbkdf2HmacSha1.h b/src/windows/7z/CPP/7zip/Crypto/Pbkdf2HmacSha1.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Crypto/Pbkdf2HmacSha1.h rename to src/windows/7z/CPP/7zip/Crypto/Pbkdf2HmacSha1.h diff --git a/desmume/src/windows/7z/CPP/7zip/Crypto/RandGen.cpp b/src/windows/7z/CPP/7zip/Crypto/RandGen.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Crypto/RandGen.cpp rename to src/windows/7z/CPP/7zip/Crypto/RandGen.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Crypto/RandGen.h b/src/windows/7z/CPP/7zip/Crypto/RandGen.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Crypto/RandGen.h rename to src/windows/7z/CPP/7zip/Crypto/RandGen.h diff --git a/desmume/src/windows/7z/CPP/7zip/Crypto/Rar20Crypto.cpp b/src/windows/7z/CPP/7zip/Crypto/Rar20Crypto.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Crypto/Rar20Crypto.cpp rename to src/windows/7z/CPP/7zip/Crypto/Rar20Crypto.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Crypto/Rar20Crypto.h b/src/windows/7z/CPP/7zip/Crypto/Rar20Crypto.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Crypto/Rar20Crypto.h rename to src/windows/7z/CPP/7zip/Crypto/Rar20Crypto.h diff --git a/desmume/src/windows/7z/CPP/7zip/Crypto/RarAes.cpp b/src/windows/7z/CPP/7zip/Crypto/RarAes.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Crypto/RarAes.cpp rename to src/windows/7z/CPP/7zip/Crypto/RarAes.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Crypto/RarAes.h b/src/windows/7z/CPP/7zip/Crypto/RarAes.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Crypto/RarAes.h rename to src/windows/7z/CPP/7zip/Crypto/RarAes.h diff --git a/desmume/src/windows/7z/CPP/7zip/Crypto/Sha1.cpp b/src/windows/7z/CPP/7zip/Crypto/Sha1.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Crypto/Sha1.cpp rename to src/windows/7z/CPP/7zip/Crypto/Sha1.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Crypto/Sha1.h b/src/windows/7z/CPP/7zip/Crypto/Sha1.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Crypto/Sha1.h rename to src/windows/7z/CPP/7zip/Crypto/Sha1.h diff --git a/desmume/src/windows/7z/CPP/7zip/Crypto/StdAfx.h b/src/windows/7z/CPP/7zip/Crypto/StdAfx.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Crypto/StdAfx.h rename to src/windows/7z/CPP/7zip/Crypto/StdAfx.h diff --git a/desmume/src/windows/7z/CPP/7zip/Crypto/WzAes.cpp b/src/windows/7z/CPP/7zip/Crypto/WzAes.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Crypto/WzAes.cpp rename to src/windows/7z/CPP/7zip/Crypto/WzAes.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Crypto/WzAes.h b/src/windows/7z/CPP/7zip/Crypto/WzAes.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Crypto/WzAes.h rename to src/windows/7z/CPP/7zip/Crypto/WzAes.h diff --git a/desmume/src/windows/7z/CPP/7zip/Crypto/ZipCrypto.cpp b/src/windows/7z/CPP/7zip/Crypto/ZipCrypto.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Crypto/ZipCrypto.cpp rename to src/windows/7z/CPP/7zip/Crypto/ZipCrypto.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Crypto/ZipCrypto.h b/src/windows/7z/CPP/7zip/Crypto/ZipCrypto.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Crypto/ZipCrypto.h rename to src/windows/7z/CPP/7zip/Crypto/ZipCrypto.h diff --git a/desmume/src/windows/7z/CPP/7zip/Crypto/ZipStrong.cpp b/src/windows/7z/CPP/7zip/Crypto/ZipStrong.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Crypto/ZipStrong.cpp rename to src/windows/7z/CPP/7zip/Crypto/ZipStrong.cpp diff --git a/desmume/src/windows/7z/CPP/7zip/Crypto/ZipStrong.h b/src/windows/7z/CPP/7zip/Crypto/ZipStrong.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/Crypto/ZipStrong.h rename to src/windows/7z/CPP/7zip/Crypto/ZipStrong.h diff --git a/desmume/src/windows/7z/CPP/7zip/ICoder.h b/src/windows/7z/CPP/7zip/ICoder.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/ICoder.h rename to src/windows/7z/CPP/7zip/ICoder.h diff --git a/desmume/src/windows/7z/CPP/7zip/IDecl.h b/src/windows/7z/CPP/7zip/IDecl.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/IDecl.h rename to src/windows/7z/CPP/7zip/IDecl.h diff --git a/desmume/src/windows/7z/CPP/7zip/IPassword.h b/src/windows/7z/CPP/7zip/IPassword.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/IPassword.h rename to src/windows/7z/CPP/7zip/IPassword.h diff --git a/desmume/src/windows/7z/CPP/7zip/IProgress.h b/src/windows/7z/CPP/7zip/IProgress.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/IProgress.h rename to src/windows/7z/CPP/7zip/IProgress.h diff --git a/desmume/src/windows/7z/CPP/7zip/IStream.h b/src/windows/7z/CPP/7zip/IStream.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/IStream.h rename to src/windows/7z/CPP/7zip/IStream.h diff --git a/desmume/src/windows/7z/CPP/7zip/PropID.h b/src/windows/7z/CPP/7zip/PropID.h similarity index 100% rename from desmume/src/windows/7z/CPP/7zip/PropID.h rename to src/windows/7z/CPP/7zip/PropID.h diff --git a/desmume/src/windows/7z/CPP/Common/Buffer.h b/src/windows/7z/CPP/Common/Buffer.h similarity index 100% rename from desmume/src/windows/7z/CPP/Common/Buffer.h rename to src/windows/7z/CPP/Common/Buffer.h diff --git a/desmume/src/windows/7z/CPP/Common/CRC.cpp b/src/windows/7z/CPP/Common/CRC.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/Common/CRC.cpp rename to src/windows/7z/CPP/Common/CRC.cpp diff --git a/desmume/src/windows/7z/CPP/Common/ComTry.h b/src/windows/7z/CPP/Common/ComTry.h similarity index 100% rename from desmume/src/windows/7z/CPP/Common/ComTry.h rename to src/windows/7z/CPP/Common/ComTry.h diff --git a/desmume/src/windows/7z/CPP/Common/Defs.h b/src/windows/7z/CPP/Common/Defs.h similarity index 100% rename from desmume/src/windows/7z/CPP/Common/Defs.h rename to src/windows/7z/CPP/Common/Defs.h diff --git a/desmume/src/windows/7z/CPP/Common/DynamicBuffer.h b/src/windows/7z/CPP/Common/DynamicBuffer.h similarity index 100% rename from desmume/src/windows/7z/CPP/Common/DynamicBuffer.h rename to src/windows/7z/CPP/Common/DynamicBuffer.h diff --git a/desmume/src/windows/7z/CPP/Common/InitializeStaticLib.h b/src/windows/7z/CPP/Common/InitializeStaticLib.h similarity index 100% rename from desmume/src/windows/7z/CPP/Common/InitializeStaticLib.h rename to src/windows/7z/CPP/Common/InitializeStaticLib.h diff --git a/desmume/src/windows/7z/CPP/Common/IntToString.cpp b/src/windows/7z/CPP/Common/IntToString.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/Common/IntToString.cpp rename to src/windows/7z/CPP/Common/IntToString.cpp diff --git a/desmume/src/windows/7z/CPP/Common/IntToString.h b/src/windows/7z/CPP/Common/IntToString.h similarity index 100% rename from desmume/src/windows/7z/CPP/Common/IntToString.h rename to src/windows/7z/CPP/Common/IntToString.h diff --git a/desmume/src/windows/7z/CPP/Common/MyCom.h b/src/windows/7z/CPP/Common/MyCom.h similarity index 100% rename from desmume/src/windows/7z/CPP/Common/MyCom.h rename to src/windows/7z/CPP/Common/MyCom.h diff --git a/desmume/src/windows/7z/CPP/Common/MyException.h b/src/windows/7z/CPP/Common/MyException.h similarity index 100% rename from desmume/src/windows/7z/CPP/Common/MyException.h rename to src/windows/7z/CPP/Common/MyException.h diff --git a/desmume/src/windows/7z/CPP/Common/MyInitGuid.h b/src/windows/7z/CPP/Common/MyInitGuid.h similarity index 100% rename from desmume/src/windows/7z/CPP/Common/MyInitGuid.h rename to src/windows/7z/CPP/Common/MyInitGuid.h diff --git a/desmume/src/windows/7z/CPP/Common/MyMap.cpp b/src/windows/7z/CPP/Common/MyMap.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/Common/MyMap.cpp rename to src/windows/7z/CPP/Common/MyMap.cpp diff --git a/desmume/src/windows/7z/CPP/Common/MyMap.h b/src/windows/7z/CPP/Common/MyMap.h similarity index 100% rename from desmume/src/windows/7z/CPP/Common/MyMap.h rename to src/windows/7z/CPP/Common/MyMap.h diff --git a/desmume/src/windows/7z/CPP/Common/MyString.cpp b/src/windows/7z/CPP/Common/MyString.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/Common/MyString.cpp rename to src/windows/7z/CPP/Common/MyString.cpp diff --git a/desmume/src/windows/7z/CPP/Common/MyString.h b/src/windows/7z/CPP/Common/MyString.h similarity index 100% rename from desmume/src/windows/7z/CPP/Common/MyString.h rename to src/windows/7z/CPP/Common/MyString.h diff --git a/desmume/src/windows/7z/CPP/Common/MyUnknown.h b/src/windows/7z/CPP/Common/MyUnknown.h similarity index 100% rename from desmume/src/windows/7z/CPP/Common/MyUnknown.h rename to src/windows/7z/CPP/Common/MyUnknown.h diff --git a/desmume/src/windows/7z/CPP/Common/MyVector.cpp b/src/windows/7z/CPP/Common/MyVector.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/Common/MyVector.cpp rename to src/windows/7z/CPP/Common/MyVector.cpp diff --git a/desmume/src/windows/7z/CPP/Common/MyVector.h b/src/windows/7z/CPP/Common/MyVector.h similarity index 100% rename from desmume/src/windows/7z/CPP/Common/MyVector.h rename to src/windows/7z/CPP/Common/MyVector.h diff --git a/desmume/src/windows/7z/CPP/Common/MyWindows.h b/src/windows/7z/CPP/Common/MyWindows.h similarity index 100% rename from desmume/src/windows/7z/CPP/Common/MyWindows.h rename to src/windows/7z/CPP/Common/MyWindows.h diff --git a/desmume/src/windows/7z/CPP/Common/MyXml.cpp b/src/windows/7z/CPP/Common/MyXml.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/Common/MyXml.cpp rename to src/windows/7z/CPP/Common/MyXml.cpp diff --git a/desmume/src/windows/7z/CPP/Common/MyXml.h b/src/windows/7z/CPP/Common/MyXml.h similarity index 100% rename from desmume/src/windows/7z/CPP/Common/MyXml.h rename to src/windows/7z/CPP/Common/MyXml.h diff --git a/desmume/src/windows/7z/CPP/Common/NewHandler.cpp b/src/windows/7z/CPP/Common/NewHandler.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/Common/NewHandler.cpp rename to src/windows/7z/CPP/Common/NewHandler.cpp diff --git a/desmume/src/windows/7z/CPP/Common/NewHandler.h b/src/windows/7z/CPP/Common/NewHandler.h similarity index 100% rename from desmume/src/windows/7z/CPP/Common/NewHandler.h rename to src/windows/7z/CPP/Common/NewHandler.h diff --git a/desmume/src/windows/7z/CPP/Common/StringConvert.cpp b/src/windows/7z/CPP/Common/StringConvert.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/Common/StringConvert.cpp rename to src/windows/7z/CPP/Common/StringConvert.cpp diff --git a/desmume/src/windows/7z/CPP/Common/StringConvert.h b/src/windows/7z/CPP/Common/StringConvert.h similarity index 100% rename from desmume/src/windows/7z/CPP/Common/StringConvert.h rename to src/windows/7z/CPP/Common/StringConvert.h diff --git a/desmume/src/windows/7z/CPP/Common/StringToInt.cpp b/src/windows/7z/CPP/Common/StringToInt.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/Common/StringToInt.cpp rename to src/windows/7z/CPP/Common/StringToInt.cpp diff --git a/desmume/src/windows/7z/CPP/Common/StringToInt.h b/src/windows/7z/CPP/Common/StringToInt.h similarity index 100% rename from desmume/src/windows/7z/CPP/Common/StringToInt.h rename to src/windows/7z/CPP/Common/StringToInt.h diff --git a/desmume/src/windows/7z/CPP/Common/Types.h b/src/windows/7z/CPP/Common/Types.h similarity index 100% rename from desmume/src/windows/7z/CPP/Common/Types.h rename to src/windows/7z/CPP/Common/Types.h diff --git a/desmume/src/windows/7z/CPP/Common/UTFConvert.cpp b/src/windows/7z/CPP/Common/UTFConvert.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/Common/UTFConvert.cpp rename to src/windows/7z/CPP/Common/UTFConvert.cpp diff --git a/desmume/src/windows/7z/CPP/Common/UTFConvert.h b/src/windows/7z/CPP/Common/UTFConvert.h similarity index 100% rename from desmume/src/windows/7z/CPP/Common/UTFConvert.h rename to src/windows/7z/CPP/Common/UTFConvert.h diff --git a/desmume/src/windows/7z/CPP/Common/Wildcard.cpp b/src/windows/7z/CPP/Common/Wildcard.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/Common/Wildcard.cpp rename to src/windows/7z/CPP/Common/Wildcard.cpp diff --git a/desmume/src/windows/7z/CPP/Common/Wildcard.h b/src/windows/7z/CPP/Common/Wildcard.h similarity index 100% rename from desmume/src/windows/7z/CPP/Common/Wildcard.h rename to src/windows/7z/CPP/Common/Wildcard.h diff --git a/desmume/src/windows/7z/CPP/Windows/Defs.h b/src/windows/7z/CPP/Windows/Defs.h similarity index 100% rename from desmume/src/windows/7z/CPP/Windows/Defs.h rename to src/windows/7z/CPP/Windows/Defs.h diff --git a/desmume/src/windows/7z/CPP/Windows/FileDir.cpp b/src/windows/7z/CPP/Windows/FileDir.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/Windows/FileDir.cpp rename to src/windows/7z/CPP/Windows/FileDir.cpp diff --git a/desmume/src/windows/7z/CPP/Windows/FileDir.h b/src/windows/7z/CPP/Windows/FileDir.h similarity index 100% rename from desmume/src/windows/7z/CPP/Windows/FileDir.h rename to src/windows/7z/CPP/Windows/FileDir.h diff --git a/desmume/src/windows/7z/CPP/Windows/FileFind.cpp b/src/windows/7z/CPP/Windows/FileFind.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/Windows/FileFind.cpp rename to src/windows/7z/CPP/Windows/FileFind.cpp diff --git a/desmume/src/windows/7z/CPP/Windows/FileFind.h b/src/windows/7z/CPP/Windows/FileFind.h similarity index 100% rename from desmume/src/windows/7z/CPP/Windows/FileFind.h rename to src/windows/7z/CPP/Windows/FileFind.h diff --git a/desmume/src/windows/7z/CPP/Windows/FileIO.cpp b/src/windows/7z/CPP/Windows/FileIO.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/Windows/FileIO.cpp rename to src/windows/7z/CPP/Windows/FileIO.cpp diff --git a/desmume/src/windows/7z/CPP/Windows/FileIO.h b/src/windows/7z/CPP/Windows/FileIO.h similarity index 100% rename from desmume/src/windows/7z/CPP/Windows/FileIO.h rename to src/windows/7z/CPP/Windows/FileIO.h diff --git a/desmume/src/windows/7z/CPP/Windows/FileName.h b/src/windows/7z/CPP/Windows/FileName.h similarity index 100% rename from desmume/src/windows/7z/CPP/Windows/FileName.h rename to src/windows/7z/CPP/Windows/FileName.h diff --git a/desmume/src/windows/7z/CPP/Windows/Handle.h b/src/windows/7z/CPP/Windows/Handle.h similarity index 100% rename from desmume/src/windows/7z/CPP/Windows/Handle.h rename to src/windows/7z/CPP/Windows/Handle.h diff --git a/desmume/src/windows/7z/CPP/Windows/PropVariant.cpp b/src/windows/7z/CPP/Windows/PropVariant.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/Windows/PropVariant.cpp rename to src/windows/7z/CPP/Windows/PropVariant.cpp diff --git a/desmume/src/windows/7z/CPP/Windows/PropVariant.h b/src/windows/7z/CPP/Windows/PropVariant.h similarity index 100% rename from desmume/src/windows/7z/CPP/Windows/PropVariant.h rename to src/windows/7z/CPP/Windows/PropVariant.h diff --git a/desmume/src/windows/7z/CPP/Windows/StdAfx.h b/src/windows/7z/CPP/Windows/StdAfx.h similarity index 100% rename from desmume/src/windows/7z/CPP/Windows/StdAfx.h rename to src/windows/7z/CPP/Windows/StdAfx.h diff --git a/desmume/src/windows/7z/CPP/Windows/Synchronization.h b/src/windows/7z/CPP/Windows/Synchronization.h similarity index 100% rename from desmume/src/windows/7z/CPP/Windows/Synchronization.h rename to src/windows/7z/CPP/Windows/Synchronization.h diff --git a/desmume/src/windows/7z/CPP/Windows/Thread.h b/src/windows/7z/CPP/Windows/Thread.h similarity index 100% rename from desmume/src/windows/7z/CPP/Windows/Thread.h rename to src/windows/7z/CPP/Windows/Thread.h diff --git a/desmume/src/windows/7z/CPP/Windows/Time.cpp b/src/windows/7z/CPP/Windows/Time.cpp similarity index 100% rename from desmume/src/windows/7z/CPP/Windows/Time.cpp rename to src/windows/7z/CPP/Windows/Time.cpp diff --git a/desmume/src/windows/7z/CPP/Windows/Time.h b/src/windows/7z/CPP/Windows/Time.h similarity index 100% rename from desmume/src/windows/7z/CPP/Windows/Time.h rename to src/windows/7z/CPP/Windows/Time.h diff --git a/desmume/src/windows/7z/DOC/License.txt b/src/windows/7z/DOC/License.txt similarity index 100% rename from desmume/src/windows/7z/DOC/License.txt rename to src/windows/7z/DOC/License.txt diff --git a/desmume/src/windows/7z/DOC/gpl.txt b/src/windows/7z/DOC/gpl.txt similarity index 100% rename from desmume/src/windows/7z/DOC/gpl.txt rename to src/windows/7z/DOC/gpl.txt diff --git a/desmume/src/windows/7z/DOC/readme.txt b/src/windows/7z/DOC/readme.txt similarity index 100% rename from desmume/src/windows/7z/DOC/readme.txt rename to src/windows/7z/DOC/readme.txt diff --git a/desmume/src/windows/7z/DOC/unRarLicense.txt b/src/windows/7z/DOC/unRarLicense.txt similarity index 100% rename from desmume/src/windows/7z/DOC/unRarLicense.txt rename to src/windows/7z/DOC/unRarLicense.txt diff --git a/desmume/src/windows/7zip.cpp b/src/windows/7zip.cpp similarity index 95% rename from desmume/src/windows/7zip.cpp rename to src/windows/7zip.cpp index 9c10b5a20..90c82027f 100644 --- a/desmume/src/windows/7zip.cpp +++ b/src/windows/7zip.cpp @@ -351,8 +351,7 @@ int ArchiveFile::ExtractItem(int index, const char* outFilename) const InFileStream* ifs = new InFileStream(m_filename); if(SUCCEEDED(object->Open(ifs,0,0))) { - gameInfo.resize(rv); - OutStream* os = new OutStream(index, gameInfo.romdata, rv); + OutStream* os = new OutStream(index, outFilename); const UInt32 indices [1] = {index}; hr = object->Extract(indices, 1, 0, os); object->Close(); diff --git a/desmume/src/windows/7zip.h b/src/windows/7zip.h similarity index 93% rename from desmume/src/windows/7zip.h rename to src/windows/7zip.h index 98fd44a3f..c5d6f0af7 100644 --- a/desmume/src/windows/7zip.h +++ b/src/windows/7zip.h @@ -1,8 +1,6 @@ #ifndef _7ZIP_DEC_HEADER #define _7ZIP_DEC_HEADER -#include "NDSSystem.h" - // 7zip file extraction // NOTE: if you want to add support for opening files within archives to some part of Gens, // consider using the higher-level interface provided by OpenArchive.h instead diff --git a/desmume/src/windows/7zipstreams.h b/src/windows/7zipstreams.h similarity index 100% rename from desmume/src/windows/7zipstreams.h rename to src/windows/7zipstreams.h diff --git a/desmume/src/windows/AboutBox.cpp b/src/windows/AboutBox.cpp similarity index 71% rename from desmume/src/windows/AboutBox.cpp rename to src/windows/AboutBox.cpp index bc68fe960..3dfb4c9d9 100644 --- a/desmume/src/windows/AboutBox.cpp +++ b/src/windows/AboutBox.cpp @@ -1,134 +1,116 @@ -/* AboutBox.cpp - - Copyright (C) 2008-2009 shash - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -*/ - - -#include "../common.h" -#include "version.h" - -#include "AboutBox.h" -#include "resource.h" - -#define ABOUT_TIMER_ID 110222 -#define PER_PAGE_TEAM 23 -#define SIZE_SCROLL_BUFFER PER_PAGE_TEAM + TEAM -const char *team[] = { - "Current Team", - "------------", - "Guillaume Duhamel", - "Normmatt", - "Bernat Muñoz (shash)", - "Riccardo Magliocchetti", - "Max Tabachenko (CrazyMax)", - "zeromus", - "Luigi__", - "adelikat", - "matusz", - "pa__", - "gocha", - "", - "Contributors", - "------------", - "Allustar", - "amponzi", - "Anthony Molinaro", - "ape", - "Damien Nozay (damdoum)", - "delfare", - "Romain Vallet", - "snkmad", - "Theo Berkau", - "thoduv", - "Tim Seidel (Mighty Max)", - "Pascal Giard (evilynux)", - "Ben Jaques (masscat)", - "Jeff Bland", - "", - "Honorary Nagmasters", - "(Thanks to our super testers for this release!)", - "------------", - "nash679", - "pokefan999", - "dottorleo", - "lbalbalba", - "", - "average time from bug checkin to bugreport:", - "23 seconds", -}; - -const int TEAM = ARRAY_SIZE(team); - -u8 scroll_start; -u8 scroll_buffer[SIZE_SCROLL_BUFFER][255]; - -BOOL CALLBACK AboutBox_Proc (HWND dialog, UINT message,WPARAM wparam,LPARAM lparam) -{ - switch(message) - { - case WM_INITDIALOG: - { - char buf[2048]; - memset(buf, 0, sizeof(buf)); - wsprintf(buf, "version %s", DESMUME_VERSION_STRING DESMUME_COMPILER_DETAIL); - SetDlgItemText(dialog, IDC_TXT_VERSION, buf); - - memset(buf, 0, sizeof(buf)); - wsprintf(buf, "compiled: %s %s", __DATE__,__TIME__); - SetDlgItemText(dialog, IDC_TXT_COMPILED, buf); - - for (int i = 0; i < SIZE_SCROLL_BUFFER; i++) - strcpy((char *)scroll_buffer[i], "\n"); - for (int i = 0; i < TEAM; i++) - { - strcpy((char *)scroll_buffer[i + PER_PAGE_TEAM], team[i]); - strcat((char *)scroll_buffer[i + PER_PAGE_TEAM], "\n"); - } - SetTimer(dialog, ABOUT_TIMER_ID, 400, (TIMERPROC) NULL); - scroll_start = 1; - break; - } - - case WM_COMMAND: - { - if((HIWORD(wparam) == BN_CLICKED)&&(((int)LOWORD(wparam)) == IDC_FERMER)) - { - KillTimer(dialog, ABOUT_TIMER_ID); - EndDialog(dialog,0); - return 1; - } - break; - } - - case WM_TIMER: - { - char buf[4096]; - memset(buf, 0, sizeof(buf)); - for (int i = 0; i < PER_PAGE_TEAM; i++) - if(i+scroll_start < SIZE_SCROLL_BUFFER) - strcat(buf, (char *)scroll_buffer[i + scroll_start]); - scroll_start++; - if (scroll_start >= SIZE_SCROLL_BUFFER) - scroll_start = 0; - SetDlgItemText(dialog, IDC_AUTHORS_LIST, buf); - break; - } - } - return 0; -} +/* + Copyright (C) 2008 shash + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + + +#include "../common.h" + +#include "AboutBox.h" +#include "resource.h" + +#define ABOUT_TIMER_ID 110222 +#define PER_PAGE_TEAM 23 +#define TEAM 27 +#define SIZE_SCROLL_BUFFER PER_PAGE_TEAM + TEAM +const char *team[TEAM] = { "Guillaume Duhamel", + "Normmatt", + "Bernat Muñoz (shash)", + "thoduv", + "Tim Seidel (Mighty Max)", + "Pascal Giard (evilynux)", + "Ben Jaques (masscat)", + "Jeff Bland", + "Riccardo Magliocchetti", + "Max Tabachenko (CrazyMax)", + "zeromus", + "Luigi__", + "adelikat", + "matusz", + "pa__", + "", + "Contributors", + "------------", + "Allustar", + "amponzi", + "Anthony Molinaro", + "ape", + "Damien Nozay (damdoum)", + "delfare", + "Romain Vallet", + "snkmad", + "Theo Berkau"}; + + +u8 scroll_start; +u8 scroll_buffer[SIZE_SCROLL_BUFFER][255]; + +BOOL CALLBACK AboutBox_Proc (HWND dialog, UINT message,WPARAM wparam,LPARAM lparam) +{ + switch(message) + { + case WM_INITDIALOG: + { + char buf[2048]; + memset(buf, 0, sizeof(buf)); + wsprintf(buf, "version %s", DESMUME_VERSION_STRING DESMUME_COMPILER_DETAIL); + SetDlgItemText(dialog, IDC_TXT_VERSION, buf); + + memset(buf, 0, sizeof(buf)); + wsprintf(buf, "compiled: %s %s", __DATE__,__TIME__); + SetDlgItemText(dialog, IDC_TXT_COMPILED, buf); + + for (int i = 0; i < SIZE_SCROLL_BUFFER; i++) + strcpy((char *)scroll_buffer[i], "\n"); + for (int i = 0; i < TEAM; i++) + { + strcpy((char *)scroll_buffer[i + PER_PAGE_TEAM], team[i]); + strcat((char *)scroll_buffer[i + PER_PAGE_TEAM], "\n"); + } + SetTimer(dialog, ABOUT_TIMER_ID, 400, (TIMERPROC) NULL); + scroll_start = 1; + break; + } + + case WM_COMMAND: + { + if((HIWORD(wparam) == BN_CLICKED)&&(((int)LOWORD(wparam)) == IDC_FERMER)) + { + KillTimer(dialog, ABOUT_TIMER_ID); + EndDialog(dialog,0); + return 1; + } + break; + } + + case WM_TIMER: + { + char buf[4096]; + memset(buf, 0, sizeof(buf)); + for (int i = 0; i < PER_PAGE_TEAM; i++) + if(i+scroll_start < SIZE_SCROLL_BUFFER) + strcat(buf, (char *)scroll_buffer[i + scroll_start]); + scroll_start++; + if (scroll_start >= SIZE_SCROLL_BUFFER) + scroll_start = 0; + SetDlgItemText(dialog, IDC_AUTHORS_LIST, buf); + break; + } + } + return 0; +} diff --git a/desmume/src/windows/AboutBox.h b/src/windows/AboutBox.h similarity index 96% rename from desmume/src/windows/AboutBox.h rename to src/windows/AboutBox.h index ac53852e8..be6d84f7b 100644 --- a/desmume/src/windows/AboutBox.h +++ b/src/windows/AboutBox.h @@ -1,26 +1,26 @@ -/* - Copyright (C) 2008 shash - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#ifndef ABOUTBOX_H -#define ABOUTBOX_H - -extern BOOL CALLBACK AboutBox_Proc(HWND dialog,UINT komunikat,WPARAM wparam,LPARAM lparam); - +/* + Copyright (C) 2008 shash + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#ifndef ABOUTBOX_H +#define ABOUTBOX_H + +extern BOOL CALLBACK AboutBox_Proc(HWND dialog,UINT komunikat,WPARAM wparam,LPARAM lparam); + #endif \ No newline at end of file diff --git a/desmume/src/windows/CWindow.cpp b/src/windows/CWindow.cpp similarity index 93% rename from desmume/src/windows/CWindow.cpp rename to src/windows/CWindow.cpp index 11a18b838..b0c642793 100644 --- a/desmume/src/windows/CWindow.cpp +++ b/src/windows/CWindow.cpp @@ -1,335 +1,335 @@ -/* Copyright (C) 2006 yopyop - yopyop156@ifrance.com - yopyop156.ifrance.com - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#include "CWindow.h" -#include "debug.h" - -WINCLASS::WINCLASS(LPSTR rclass, HINSTANCE hInst) -{ - memset(regclass, 0, sizeof(regclass)); - memcpy(regclass, rclass, strlen(rclass)); - - hwnd = NULL; - hmenu = NULL; - hInstance = hInst; - - minWidth = 0; - minHeight = 0; -} - -WINCLASS::~WINCLASS() -{ -} - -bool WINCLASS::create(LPSTR caption, int x, int y, int width, int height, int style, HMENU menu) -{ - if (hwnd != NULL) return false; - - hwnd = CreateWindow(regclass, caption, style, x, y, width, height, NULL, menu, hInstance, NULL); - - if (hwnd != NULL) return true; - return false; -} - -bool WINCLASS::createEx(LPSTR caption, int x, int y, int width, int height, int style, int styleEx, HMENU menu) -{ - if (hwnd != NULL) return false; - - hwnd = CreateWindowEx(styleEx, regclass, caption, style, x, y, width, height, NULL, menu, hInstance, NULL); - - if (hwnd != NULL) return true; - return false; -} - -bool WINCLASS::setMenu(HMENU menu) -{ - hmenu = menu; - return SetMenu(hwnd, hmenu); -} - -DWORD WINCLASS::checkMenu(UINT idd, UINT check) -{ - return CheckMenuItem(hmenu, idd, check); -} - -HWND WINCLASS::getHWnd() -{ - return hwnd; -} - -void WINCLASS::Show(int mode) -{ - ShowWindow(hwnd, mode); -} - -void WINCLASS::Hide() -{ - ShowWindow(hwnd, SW_HIDE); -} - -void WINCLASS::setMinSize(int width, int height) -{ - minWidth = width; - minHeight = height; -} - -void WINCLASS::sizingMsg(WPARAM wParam, LPARAM lParam, BOOL keepRatio) -{ - RECT *rect = (RECT*)lParam; - - int _minWidth, _minHeight; - - int xborder, yborder; - int ymenu, ymenunew; - int ycaption; - - MENUBARINFO mbi; - - /* Get the size of the border */ - xborder = GetSystemMetrics(SM_CXSIZEFRAME); - yborder = GetSystemMetrics(SM_CYSIZEFRAME); - - /* Get the size of the menu bar */ - ZeroMemory(&mbi, sizeof(mbi)); - mbi.cbSize = sizeof(mbi); - GetMenuBarInfo(hwnd, OBJID_MENU, 0, &mbi); - ymenu = (mbi.rcBar.bottom - mbi.rcBar.top + 1); - - /* Get the size of the caption bar */ - ycaption = GetSystemMetrics(SM_CYCAPTION); - - /* Calculate the minimum size in pixels */ - _minWidth = (xborder + minWidth + xborder); - _minHeight = (ycaption + yborder + ymenu + minHeight + yborder); - - /* Clamp the size to the minimum size (256x384) */ - rect->right = (rect->left + std::max(_minWidth, (int)(rect->right - rect->left))); - rect->bottom = (rect->top + std::max(_minHeight, (int)(rect->bottom - rect->top))); - - /* Apply the ratio stuff */ - if(keepRatio) - { - switch(wParam) - { - case WMSZ_LEFT: - case WMSZ_RIGHT: - case WMSZ_TOPLEFT: - case WMSZ_TOPRIGHT: - case WMSZ_BOTTOMLEFT: - case WMSZ_BOTTOMRIGHT: - { - float ratio = ((rect->right - rect->left - xborder - xborder) / (float)minWidth); - rect->bottom = (LONG)((rect->top + ycaption + yborder + ymenu + (minHeight * ratio) + yborder)); - } - break; - - case WMSZ_TOP: - case WMSZ_BOTTOM: - { - float ratio = ((rect->bottom - rect->top - ycaption - yborder - ymenu - yborder) / (float)minHeight); - rect->right = (LONG)((rect->left + xborder + (minWidth * ratio) + xborder)); - } - break; - } - } - - /* Check if the height of the menu has changed during the resize */ - ZeroMemory(&mbi, sizeof(mbi)); - mbi.cbSize = sizeof(mbi); - GetMenuBarInfo(hwnd, OBJID_MENU, 0, &mbi); - ymenunew = (mbi.rcBar.bottom - mbi.rcBar.top + 1); - - if(ymenunew != ymenu) - rect->bottom += (ymenunew - ymenu); -} - -void WINCLASS::setClientSize(int width, int height) -{ - int xborder, yborder; - int ymenu, ymenunew; - int ycaption; - - MENUBARINFO mbi; - - RECT wndRect; - int finalx, finaly; - - /* Get the size of the border */ - xborder = GetSystemMetrics(SM_CXSIZEFRAME); - yborder = GetSystemMetrics(SM_CYSIZEFRAME); - - /* Get the size of the menu bar */ - ZeroMemory(&mbi, sizeof(mbi)); - mbi.cbSize = sizeof(mbi); - GetMenuBarInfo(hwnd, OBJID_MENU, 0, &mbi); - ymenu = (mbi.rcBar.bottom - mbi.rcBar.top + 1); - - /* Get the size of the caption bar */ - ycaption = GetSystemMetrics(SM_CYCAPTION); - - /* Finally, resize the window */ - GetWindowRect(hwnd, &wndRect); - finalx = (xborder + width + xborder); - finaly = (ycaption + yborder + ymenu + height + yborder); - MoveWindow(hwnd, wndRect.left, wndRect.top, finalx, finaly, TRUE); - - /* Oops, we also need to check if the height */ - /* of the menu bar has changed after the resize */ - ZeroMemory(&mbi, sizeof(mbi)); - mbi.cbSize = sizeof(mbi); - GetMenuBarInfo(hwnd, OBJID_MENU, 0, &mbi); - ymenunew = (mbi.rcBar.bottom - mbi.rcBar.top + 1); - - if(ymenunew != ymenu) - MoveWindow(hwnd, wndRect.left, wndRect.top, finalx, (finaly + (ymenunew - ymenu)), TRUE); -} - -//========================================================= Thread class -extern DWORD WINAPI ThreadProc(LPVOID lpParameter) -{ - THREADCLASS *tmp = (THREADCLASS *)lpParameter; - return tmp->ThreadFunc(); -} - -THREADCLASS::THREADCLASS() -{ - hThread = NULL; -} - -THREADCLASS::~THREADCLASS() -{ - closeThread(); -} - -void THREADCLASS::closeThread() -{ - if (hThread) - { - CloseHandle(hThread); - hThread = NULL; - } -} - -bool THREADCLASS::createThread() -{ - if (hThread) return false; - - hThread = CreateThread(NULL, 0, (LPTHREAD_START_ROUTINE)ThreadProc, this, 0, &threadID); - if (!hThread) return false; - //WaitForSingleObject(hThread, INFINITE); - return true; -} - -//========================================================= Tools class -TOOLSCLASS::TOOLSCLASS(HINSTANCE hInst, int IDD, DLGPROC dlgproc) -{ - this->dlgproc = dlgproc; - hwnd = NULL; - hInstance = hInst; - idd=IDD; - memset(class_name, 0, sizeof(class_name)); - memset(class_name2, 0, sizeof(class_name2)); -} - -TOOLSCLASS::~TOOLSCLASS() -{ - close(); -} - -bool TOOLSCLASS::open() -{ - if (!createThread()) return false; - return true; -} - -bool TOOLSCLASS::close() -{ - return true; -} - -DWORD TOOLSCLASS::ThreadFunc() -{ - MSG messages; - LOG("Start thread\n"); - - GetLastError(); - hwnd = CreateDialog(hInstance, MAKEINTRESOURCE(idd), NULL, (DLGPROC) dlgproc); - - if (!hwnd) - { - LOG("error creating dialog\n"); - return (-2); - } - - ShowWindow(hwnd, SW_SHOW); - UpdateWindow(hwnd); - - while (GetMessage (&messages, NULL, 0, 0)) - { - TranslateMessage(&messages); - DispatchMessage(&messages); - } - - unregClass(); - hwnd = NULL; - - closeThread(); - return 0; -} - -void TOOLSCLASS::regClass(LPSTR class_name, WNDPROC wproc, bool SecondReg) -{ - WNDCLASSEX wc; - - wc.cbSize = sizeof(wc); - if (SecondReg) - strcpy(this->class_name2, class_name); - else - strcpy(this->class_name, class_name); - - wc.lpszClassName = class_name; - wc.hInstance = hInstance; - wc.lpfnWndProc = wproc; - wc.hCursor = LoadCursor (NULL, IDC_ARROW); - wc.hIcon = 0; - wc.lpszMenuName = 0; - wc.hbrBackground = (HBRUSH)GetSysColorBrush(COLOR_BTNFACE); - wc.style = 0; - wc.cbClsExtra = 0; - wc.cbWndExtra = 0; - wc.hIconSm = 0; - - RegisterClassEx(&wc); -} - -void TOOLSCLASS::unregClass() -{ - if (class_name[0]) - { - UnregisterClass(class_name, hInstance); - } - if (class_name2[0]) - { - UnregisterClass(class_name2, hInstance); - } - memset(class_name, 0, sizeof(class_name)); - memset(class_name2, 0, sizeof(class_name2)); -} +/* Copyright (C) 2006 yopyop + yopyop156@ifrance.com + yopyop156.ifrance.com + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#include "CWindow.h" +#include "debug.h" + +WINCLASS::WINCLASS(LPSTR rclass, HINSTANCE hInst) +{ + memset(regclass, 0, sizeof(regclass)); + memcpy(regclass, rclass, strlen(rclass)); + + hwnd = NULL; + hmenu = NULL; + hInstance = hInst; + + minWidth = 0; + minHeight = 0; +} + +WINCLASS::~WINCLASS() +{ +} + +bool WINCLASS::create(LPSTR caption, int x, int y, int width, int height, int style, HMENU menu) +{ + if (hwnd != NULL) return false; + + hwnd = CreateWindow(regclass, caption, style, x, y, width, height, NULL, menu, hInstance, NULL); + + if (hwnd != NULL) return true; + return false; +} + +bool WINCLASS::createEx(LPSTR caption, int x, int y, int width, int height, int style, int styleEx, HMENU menu) +{ + if (hwnd != NULL) return false; + + hwnd = CreateWindowEx(styleEx, regclass, caption, style, x, y, width, height, NULL, menu, hInstance, NULL); + + if (hwnd != NULL) return true; + return false; +} + +bool WINCLASS::setMenu(HMENU menu) +{ + hmenu = menu; + return SetMenu(hwnd, hmenu); +} + +DWORD WINCLASS::checkMenu(UINT idd, UINT check) +{ + return CheckMenuItem(hmenu, idd, check); +} + +HWND WINCLASS::getHWnd() +{ + return hwnd; +} + +void WINCLASS::Show(int mode) +{ + ShowWindow(hwnd, mode); +} + +void WINCLASS::Hide() +{ + ShowWindow(hwnd, SW_HIDE); +} + +void WINCLASS::setMinSize(int width, int height) +{ + minWidth = width; + minHeight = height; +} + +void WINCLASS::sizingMsg(WPARAM wParam, LPARAM lParam, BOOL keepRatio) +{ + RECT *rect = (RECT*)lParam; + + int _minWidth, _minHeight; + + int xborder, yborder; + int ymenu, ymenunew; + int ycaption; + + MENUBARINFO mbi; + + /* Get the size of the border */ + xborder = GetSystemMetrics(SM_CXSIZEFRAME); + yborder = GetSystemMetrics(SM_CYSIZEFRAME); + + /* Get the size of the menu bar */ + ZeroMemory(&mbi, sizeof(mbi)); + mbi.cbSize = sizeof(mbi); + GetMenuBarInfo(hwnd, OBJID_MENU, 0, &mbi); + ymenu = (mbi.rcBar.bottom - mbi.rcBar.top + 1); + + /* Get the size of the caption bar */ + ycaption = GetSystemMetrics(SM_CYCAPTION); + + /* Calculate the minimum size in pixels */ + _minWidth = (xborder + minWidth + xborder); + _minHeight = (ycaption + yborder + ymenu + minHeight + yborder); + + /* Clamp the size to the minimum size (256x384) */ + rect->right = (rect->left + std::max(_minWidth, (int)(rect->right - rect->left))); + rect->bottom = (rect->top + std::max(_minHeight, (int)(rect->bottom - rect->top))); + + /* Apply the ratio stuff */ + if(keepRatio) + { + switch(wParam) + { + case WMSZ_LEFT: + case WMSZ_RIGHT: + case WMSZ_TOPLEFT: + case WMSZ_TOPRIGHT: + case WMSZ_BOTTOMLEFT: + case WMSZ_BOTTOMRIGHT: + { + float ratio = ((rect->right - rect->left - xborder - xborder) / (float)minWidth); + rect->bottom = (rect->top + ycaption + yborder + ymenu + (minHeight * ratio) + yborder); + } + break; + + case WMSZ_TOP: + case WMSZ_BOTTOM: + { + float ratio = ((rect->bottom - rect->top - ycaption - yborder - ymenu - yborder) / (float)minHeight); + rect->right = (rect->left + xborder + (minWidth * ratio) + xborder); + } + break; + } + } + + /* Check if the height of the menu has changed during the resize */ + ZeroMemory(&mbi, sizeof(mbi)); + mbi.cbSize = sizeof(mbi); + GetMenuBarInfo(hwnd, OBJID_MENU, 0, &mbi); + ymenunew = (mbi.rcBar.bottom - mbi.rcBar.top + 1); + + if(ymenunew != ymenu) + rect->bottom += (ymenunew - ymenu); +} + +void WINCLASS::setClientSize(int width, int height) +{ + int xborder, yborder; + int ymenu, ymenunew; + int ycaption; + + MENUBARINFO mbi; + + RECT wndRect; + int finalx, finaly; + + /* Get the size of the border */ + xborder = GetSystemMetrics(SM_CXSIZEFRAME); + yborder = GetSystemMetrics(SM_CYSIZEFRAME); + + /* Get the size of the menu bar */ + ZeroMemory(&mbi, sizeof(mbi)); + mbi.cbSize = sizeof(mbi); + GetMenuBarInfo(hwnd, OBJID_MENU, 0, &mbi); + ymenu = (mbi.rcBar.bottom - mbi.rcBar.top + 1); + + /* Get the size of the caption bar */ + ycaption = GetSystemMetrics(SM_CYCAPTION); + + /* Finally, resize the window */ + GetWindowRect(hwnd, &wndRect); + finalx = (xborder + width + xborder); + finaly = (ycaption + yborder + ymenu + height + yborder); + MoveWindow(hwnd, wndRect.left, wndRect.top, finalx, finaly, TRUE); + + /* Oops, we also need to check if the height */ + /* of the menu bar has changed after the resize */ + ZeroMemory(&mbi, sizeof(mbi)); + mbi.cbSize = sizeof(mbi); + GetMenuBarInfo(hwnd, OBJID_MENU, 0, &mbi); + ymenunew = (mbi.rcBar.bottom - mbi.rcBar.top + 1); + + if(ymenunew != ymenu) + MoveWindow(hwnd, wndRect.left, wndRect.top, finalx, (finaly + (ymenunew - ymenu)), TRUE); +} + +//========================================================= Thread class +extern DWORD WINAPI ThreadProc(LPVOID lpParameter) +{ + THREADCLASS *tmp = (THREADCLASS *)lpParameter; + return tmp->ThreadFunc(); +} + +THREADCLASS::THREADCLASS() +{ + hThread = NULL; +} + +THREADCLASS::~THREADCLASS() +{ + closeThread(); +} + +void THREADCLASS::closeThread() +{ + if (hThread) + { + CloseHandle(hThread); + hThread = NULL; + } +} + +bool THREADCLASS::createThread() +{ + if (hThread) return false; + + hThread = CreateThread(NULL, 0, (LPTHREAD_START_ROUTINE)ThreadProc, this, 0, &threadID); + if (!hThread) return false; + //WaitForSingleObject(hThread, INFINITE); + return true; +} + +//========================================================= Tools class +TOOLSCLASS::TOOLSCLASS(HINSTANCE hInst, int IDD, DLGPROC dlgproc) +{ + this->dlgproc = dlgproc; + hwnd = NULL; + hInstance = hInst; + idd=IDD; + memset(class_name, 0, sizeof(class_name)); + memset(class_name2, 0, sizeof(class_name2)); +} + +TOOLSCLASS::~TOOLSCLASS() +{ + close(); +} + +bool TOOLSCLASS::open() +{ + if (!createThread()) return false; + return true; +} + +bool TOOLSCLASS::close() +{ + return true; +} + +DWORD TOOLSCLASS::ThreadFunc() +{ + MSG messages; + LOG("Start thread\n"); + + GetLastError(); + hwnd = CreateDialog(hInstance, MAKEINTRESOURCE(idd), NULL, (DLGPROC) dlgproc); + + if (!hwnd) + { + LOG("error creating dialog\n"); + return (-2); + } + + ShowWindow(hwnd, SW_SHOW); + UpdateWindow(hwnd); + + while (GetMessage (&messages, NULL, 0, 0)) + { + TranslateMessage(&messages); + DispatchMessage(&messages); + } + + unregClass(); + hwnd = NULL; + + closeThread(); + return 0; +} + +void TOOLSCLASS::regClass(LPSTR class_name, WNDPROC wproc, bool SecondReg) +{ + WNDCLASSEX wc; + + wc.cbSize = sizeof(wc); + if (SecondReg) + strcpy(this->class_name2, class_name); + else + strcpy(this->class_name, class_name); + + wc.lpszClassName = class_name; + wc.hInstance = hInstance; + wc.lpfnWndProc = wproc; + wc.hCursor = LoadCursor (NULL, IDC_ARROW); + wc.hIcon = 0; + wc.lpszMenuName = 0; + wc.hbrBackground = (HBRUSH)GetSysColorBrush(COLOR_BTNFACE); + wc.style = 0; + wc.cbClsExtra = 0; + wc.cbWndExtra = 0; + wc.hIconSm = 0; + + RegisterClassEx(&wc); +} + +void TOOLSCLASS::unregClass() +{ + if (class_name[0]) + { + UnregisterClass(class_name, hInstance); + } + if (class_name2[0]) + { + UnregisterClass(class_name2, hInstance); + } + memset(class_name, 0, sizeof(class_name)); + memset(class_name2, 0, sizeof(class_name2)); +} diff --git a/desmume/src/windows/CWindow.h b/src/windows/CWindow.h similarity index 95% rename from desmume/src/windows/CWindow.h rename to src/windows/CWindow.h index 9e2a52db1..930b02822 100644 --- a/desmume/src/windows/CWindow.h +++ b/src/windows/CWindow.h @@ -1,96 +1,96 @@ -/* Copyright (C) 2006 yopyop - yopyop156@ifrance.com - yopyop156.ifrance.com - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#ifndef CWINDOW_H -#define CWINDOW_H - -#include "../common.h" - -class WINCLASS -{ -private: - HWND hwnd; - HMENU hmenu; - HINSTANCE hInstance; - char regclass[256]; - int minWidth, minHeight; -public: - WINCLASS(LPSTR rclass, HINSTANCE hInst); - ~WINCLASS(); - - bool create(LPSTR caption, int x, int y, int width, int height, int style, - HMENU menu); - bool createEx(LPSTR caption, int x, int y, int width, int height, int style, int styleEx, - HMENU menu); - - bool setMenu(HMENU menu); - DWORD checkMenu(UINT idd, UINT check); - - void Show(int mode); - void Hide(); - - HWND getHWnd(); - - void setMinSize(int width, int height); - - void sizingMsg(WPARAM wParam, LPARAM lParam, BOOL keepRatio = FALSE); - void setClientSize(int width, int height); -}; - -class THREADCLASS -{ - friend DWORD WINAPI ThreadProc(LPVOID lpParameter); - HANDLE hThread; - -public: - THREADCLASS(); - virtual ~THREADCLASS(); - bool createThread(); - void closeThread(); - -protected: - DWORD threadID; - virtual DWORD ThreadFunc()=NULL; -}; - -class TOOLSCLASS : public THREADCLASS -{ -private: - HWND hwnd; - HINSTANCE hInstance; - DLGPROC dlgproc; - int idd; - char class_name[256]; - char class_name2[256]; - -protected: - DWORD ThreadFunc(); - -public: - TOOLSCLASS(HINSTANCE hInst, int IDD, DLGPROC wndproc); - virtual ~TOOLSCLASS(); - bool open(); - bool close(); - void regClass(LPSTR class_name, WNDPROC wproc, bool SecondReg = false); - void unregClass(); -}; - -#endif +/* Copyright (C) 2006 yopyop + yopyop156@ifrance.com + yopyop156.ifrance.com + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#ifndef CWINDOW_H +#define CWINDOW_H + +#include "../common.h" + +class WINCLASS +{ +private: + HWND hwnd; + HMENU hmenu; + HINSTANCE hInstance; + char regclass[256]; + int minWidth, minHeight; +public: + WINCLASS(LPSTR rclass, HINSTANCE hInst); + ~WINCLASS(); + + bool create(LPSTR caption, int x, int y, int width, int height, int style, + HMENU menu); + bool createEx(LPSTR caption, int x, int y, int width, int height, int style, int styleEx, + HMENU menu); + + bool setMenu(HMENU menu); + DWORD checkMenu(UINT idd, UINT check); + + void Show(int mode); + void Hide(); + + HWND getHWnd(); + + void setMinSize(int width, int height); + + void sizingMsg(WPARAM wParam, LPARAM lParam, BOOL keepRatio = FALSE); + void setClientSize(int width, int height); +}; + +class THREADCLASS +{ + friend DWORD WINAPI ThreadProc(LPVOID lpParameter); + HANDLE hThread; + +public: + THREADCLASS(); + virtual ~THREADCLASS(); + bool createThread(); + void closeThread(); + +protected: + DWORD threadID; + virtual DWORD ThreadFunc()=NULL; +}; + +class TOOLSCLASS : public THREADCLASS +{ +private: + HWND hwnd; + HINSTANCE hInstance; + DLGPROC dlgproc; + int idd; + char class_name[256]; + char class_name2[256]; + +protected: + DWORD ThreadFunc(); + +public: + TOOLSCLASS(HINSTANCE hInst, int IDD, DLGPROC wndproc); + virtual ~TOOLSCLASS(); + bool open(); + bool close(); + void regClass(LPSTR class_name, WNDPROC wproc, bool SecondReg = false); + void unregClass(); +}; + +#endif diff --git a/desmume/src/windows/DeSmuME.ico b/src/windows/DeSmuME.ico similarity index 100% rename from desmume/src/windows/DeSmuME.ico rename to src/windows/DeSmuME.ico diff --git a/desmume/src/windows/DeSmuME_2005.sln b/src/windows/DeSmuME_2005.sln similarity index 93% rename from desmume/src/windows/DeSmuME_2005.sln rename to src/windows/DeSmuME_2005.sln index 7f670c9f6..1d43d6786 100644 --- a/desmume/src/windows/DeSmuME_2005.sln +++ b/src/windows/DeSmuME_2005.sln @@ -21,6 +21,6 @@ Global HideSolutionNode = FALSE EndGlobalSection GlobalSection(ExtensibilityGlobals) = postSolution - AMDCaProjectFile = D:\svn\desmume\trunk\desmume\src\windows\CodeAnalyst\DeSmuME_2005.caw + AMDCaProjectFile = C:\svn\desmume\trunk\desmume\src\windows\CodeAnalyst\DeSmuME_2005.caw EndGlobalSection EndGlobal diff --git a/desmume/src/windows/DeSmuME_2005.vcproj b/src/windows/DeSmuME_2005.vcproj similarity index 82% rename from desmume/src/windows/DeSmuME_2005.vcproj rename to src/windows/DeSmuME_2005.vcproj index 1c8bdf933..9dd4672ed 100644 --- a/desmume/src/windows/DeSmuME_2005.vcproj +++ b/src/windows/DeSmuME_2005.vcproj @@ -1,1128 +1,1129 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/desmume/src/windows/DeSmuME_2008.sln b/src/windows/DeSmuME_2008.sln similarity index 100% rename from desmume/src/windows/DeSmuME_2008.sln rename to src/windows/DeSmuME_2008.sln diff --git a/desmume/src/windows/DeSmuME_2008.vcproj b/src/windows/DeSmuME_2008.vcproj similarity index 70% rename from desmume/src/windows/DeSmuME_2008.vcproj rename to src/windows/DeSmuME_2008.vcproj index c9e078083..56d0b55c7 100644 --- a/desmume/src/windows/DeSmuME_2008.vcproj +++ b/src/windows/DeSmuME_2008.vcproj @@ -27,7 +27,6 @@ > - - @@ -325,6 +318,10 @@ RelativePath="..\bios.cpp" > + + @@ -437,6 +434,10 @@ RelativePath="..\saves.cpp" > + + @@ -521,6 +522,142 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -532,10 +669,6 @@ RelativePath="..\addons\gbagame.cpp" > - - @@ -593,6 +726,10 @@ RelativePath=".\CWindow.cpp" > + + @@ -613,6 +750,14 @@ RelativePath=".\inputdx.cpp" > + + + + @@ -621,10 +766,26 @@ RelativePath=".\main.cpp" > + + + + + + + + @@ -637,10 +798,22 @@ RelativePath=".\OpenArchive.h" > + + + + + + @@ -649,82 +822,22 @@ RelativePath=".\snddx.cpp" > + + - - - - - - - - - - - + - - - - - - - - - - - - - - - - - - - - - - - - - + + + @@ -867,14 +984,6 @@ > - - - - + + @@ -927,10 +1040,6 @@ RelativePath="..\Disassembler.h" > - - @@ -1007,10 +1116,6 @@ RelativePath="..\OGLRender.h" > - - @@ -1075,10 +1180,6 @@ RelativePath="..\types.h" > - - diff --git a/desmume/src/windows/DeSmuME_Intel.icproj b/src/windows/DeSmuME_Intel.icproj similarity index 96% rename from desmume/src/windows/DeSmuME_Intel.icproj rename to src/windows/DeSmuME_Intel.icproj index e0f3931b1..ac4214530 100644 --- a/desmume/src/windows/DeSmuME_Intel.icproj +++ b/src/windows/DeSmuME_Intel.icproj @@ -1,499 +1,499 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/desmume/src/windows/DeSmuME_Intel.sln b/src/windows/DeSmuME_Intel.sln similarity index 100% rename from desmume/src/windows/DeSmuME_Intel.sln rename to src/windows/DeSmuME_Intel.sln diff --git a/desmume/src/windows/DeSmuME_Intel.vcproj b/src/windows/DeSmuME_Intel.vcproj similarity index 95% rename from desmume/src/windows/DeSmuME_Intel.vcproj rename to src/windows/DeSmuME_Intel.vcproj index 0d20d549b..52c2ec9b3 100644 --- a/desmume/src/windows/DeSmuME_Intel.vcproj +++ b/src/windows/DeSmuME_Intel.vcproj @@ -1,1044 +1,1044 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/desmume/src/windows/DeSmuME_x64.manifest b/src/windows/DeSmuME_x64.manifest similarity index 100% rename from desmume/src/windows/DeSmuME_x64.manifest rename to src/windows/DeSmuME_x64.manifest diff --git a/desmume/src/windows/DeSmuME_x86.manifest b/src/windows/DeSmuME_x86.manifest similarity index 100% rename from desmume/src/windows/DeSmuME_x86.manifest rename to src/windows/DeSmuME_x86.manifest diff --git a/desmume/src/windows/FirmConfig.cpp b/src/windows/FirmConfig.cpp similarity index 97% rename from desmume/src/windows/FirmConfig.cpp rename to src/windows/FirmConfig.cpp index 5055dbb66..0ddc4b279 100644 --- a/desmume/src/windows/FirmConfig.cpp +++ b/src/windows/FirmConfig.cpp @@ -1,165 +1,165 @@ -/* - Copyright (C) 2007 Normmatt - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#include -#include -#include "../common.h" -#include -#include -#include - -#include "CWindow.h" - -#include "resource.h" -#include "FirmConfig.h" - -#include "../debug.h" -#include "../NDSSystem.h" - -static char nickname_buffer[11]; -static char message_buffer[27]; - -const char firmLang[6][16] = {"Japanese","English","French","German","Italian","Spanish"}; -const char firmColor[16][16] = {"Gray","Brown","Red","Pink","Orange","Yellow","Lime Green", - "Green","Dark Green","Sea Green","Turquoise","Blue", - "Dark Blue","Dark Purple","Violet","Magenta"}; -const char firmDay[31][16] = {"1","2","3","4","5","6","7","8","9","10","11","12","13","14", - "15","16","17","18","19","20","21","22","23","24","25","26", - "27","28","29","30","31"}; -const char firmMonth[12][16] = {"January","Feburary","March","April","May","June","July", - "August","September","October","November","December"}; - -static void WriteFirmConfig( struct NDS_fw_config_data *fw_config) -{ - char temp_str[27]; - int i; - - WritePrivateProfileInt("Firmware","favColor", fw_config->fav_colour,IniName); - WritePrivateProfileInt("Firmware","bMonth", fw_config->birth_month,IniName); - WritePrivateProfileInt("Firmware","bDay",fw_config->birth_day,IniName); - WritePrivateProfileInt("Firmware","Language",fw_config->language,IniName); - - /* FIXME: harshly only use the lower byte of the UTF-16 character. - * This would cause strange behaviour if the user could set UTF-16 but - * they cannot yet. - */ - for ( i = 0; i < fw_config->nickname_len; i++) { - temp_str[i] = fw_config->nickname[i]; - } - temp_str[i] = '\0'; - WritePrivateProfileString("Firmware", "nickName", temp_str, IniName); - - for ( i = 0; i < fw_config->message_len; i++) { - temp_str[i] = fw_config->message[i]; - } - temp_str[i] = '\0'; - WritePrivateProfileString("Firmware","Message", temp_str, IniName); -} - -BOOL CALLBACK FirmConfig_Proc(HWND dialog,UINT komunikat,WPARAM wparam,LPARAM lparam) -{ - struct NDS_fw_config_data *fw_config = &win_fw_config; - int i; - char temp_str[27]; - - switch(komunikat) - { - case WM_INITDIALOG: - for(i=0;i<6;i++) SendDlgItemMessage(dialog,IDC_COMBO4,CB_ADDSTRING,0,(LPARAM)&firmLang[i]); - for(i=0;i<12;i++) SendDlgItemMessage(dialog,IDC_COMBO2,CB_ADDSTRING,0,(LPARAM)&firmMonth[i]); - for(i=0;i<16;i++) SendDlgItemMessage(dialog,IDC_COMBO1,CB_ADDSTRING,0,(LPARAM)&firmColor[i]); - for(i=0;i<31;i++) SendDlgItemMessage(dialog,IDC_COMBO3,CB_ADDSTRING,0,(LPARAM)&firmDay[i]); - SendDlgItemMessage(dialog,IDC_COMBO1,CB_SETCURSEL,fw_config->fav_colour,0); - SendDlgItemMessage(dialog,IDC_COMBO2,CB_SETCURSEL,fw_config->birth_month-1,0); - SendDlgItemMessage(dialog,IDC_COMBO3,CB_SETCURSEL,fw_config->birth_day-1,0); - SendDlgItemMessage(dialog,IDC_COMBO4,CB_SETCURSEL,fw_config->language,0); - SendDlgItemMessage(dialog,IDC_EDIT1,EM_SETLIMITTEXT,10,0); - SendDlgItemMessage(dialog,IDC_EDIT2,EM_SETLIMITTEXT,26,0); - SendDlgItemMessage(dialog,IDC_EDIT1,EM_SETSEL,0,10); - SendDlgItemMessage(dialog,IDC_EDIT2,EM_SETSEL,0,26); - - for ( i = 0; i < fw_config->nickname_len; i++) { - nickname_buffer[i] = fw_config->nickname[i]; - } - nickname_buffer[i] = '\0'; - SendDlgItemMessage(dialog,IDC_EDIT1,WM_SETTEXT,0,(LPARAM)nickname_buffer); - - for ( i = 0; i < fw_config->message_len; i++) { - message_buffer[i] = fw_config->message[i]; - } - message_buffer[i] = '\0'; - SendDlgItemMessage(dialog,IDC_EDIT2,WM_SETTEXT,0,(LPARAM)message_buffer); - break; - - case WM_COMMAND: - if((HIWORD(wparam)==BN_CLICKED)&&(((int)LOWORD(wparam))==IDOK)) - { - int char_index; - LRESULT res; - fw_config->fav_colour = SendDlgItemMessage(dialog,IDC_COMBO1,CB_GETCURSEL,0,0); - fw_config->birth_month = 1 + SendDlgItemMessage(dialog,IDC_COMBO2,CB_GETCURSEL,0,0); - fw_config->birth_day = 1 + SendDlgItemMessage(dialog,IDC_COMBO3,CB_GETCURSEL,0,0); - fw_config->language = SendDlgItemMessage(dialog,IDC_COMBO4,CB_GETCURSEL,0,0); - - *(WORD *)temp_str = 10; - res = SendDlgItemMessage(dialog,IDC_EDIT1,EM_GETLINE,0,(LPARAM)temp_str); - - if ( res > 0) { - temp_str[res] = '\0'; - fw_config->nickname_len = strlen( temp_str); - } - else { - strcpy( temp_str, "yopyop"); - fw_config->nickname_len = strlen( temp_str); - } - for ( char_index = 0; char_index < fw_config->nickname_len; char_index++) { - fw_config->nickname[char_index] = temp_str[char_index]; - } - - *(WORD *)temp_str = 26; - res = SendDlgItemMessage(dialog,IDC_EDIT2,EM_GETLINE,0,(LPARAM)temp_str); - if ( res > 0) { - temp_str[res] = '\0'; - fw_config->message_len = strlen( temp_str); - } - else { - fw_config->message_len = 0; - } - for ( char_index = 0; char_index < fw_config->message_len; char_index++) { - fw_config->message[char_index] = temp_str[char_index]; - } - - WriteFirmConfig( fw_config); - EndDialog(dialog,0); - NDS_CreateDummyFirmware( fw_config); - return 1; - } - else - if((HIWORD(wparam)==BN_CLICKED)&&(((int)LOWORD(wparam))==IDCANCEL)) - { - EndDialog(dialog, 0); - return 0; - } - break; - } - return 0; -} - - +/* + Copyright (C) 2007 Normmatt + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#include +#include +#include "../common.h" +#include +#include +#include + +#include "CWindow.h" + +#include "resource.h" +#include "FirmConfig.h" + +#include "../debug.h" +#include "../NDSSystem.h" + +static char nickname_buffer[11]; +static char message_buffer[27]; + +const char firmLang[6][16] = {"Japanese","English","French","German","Italian","Spanish"}; +const char firmColor[16][16] = {"Gray","Brown","Red","Pink","Orange","Yellow","Lime Green", + "Green","Dark Green","Sea Green","Turquoise","Blue", + "Dark Blue","Dark Purple","Violet","Magenta"}; +const char firmDay[31][16] = {"1","2","3","4","5","6","7","8","9","10","11","12","13","14", + "15","16","17","18","19","20","21","22","23","24","25","26", + "27","28","29","30","31"}; +const char firmMonth[12][16] = {"January","Feburary","March","April","May","June","July", + "August","September","October","November","December"}; + +static void WriteFirmConfig( struct NDS_fw_config_data *fw_config) +{ + char temp_str[27]; + int i; + + WritePrivateProfileInt("Firmware","favColor", fw_config->fav_colour,IniName); + WritePrivateProfileInt("Firmware","bMonth", fw_config->birth_month,IniName); + WritePrivateProfileInt("Firmware","bDay",fw_config->birth_day,IniName); + WritePrivateProfileInt("Firmware","Language",fw_config->language,IniName); + + /* FIXME: harshly only use the lower byte of the UTF-16 character. + * This would cause strange behaviour if the user could set UTF-16 but + * they cannot yet. + */ + for ( i = 0; i < fw_config->nickname_len; i++) { + temp_str[i] = fw_config->nickname[i]; + } + temp_str[i] = '\0'; + WritePrivateProfileString("Firmware", "nickName", temp_str, IniName); + + for ( i = 0; i < fw_config->message_len; i++) { + temp_str[i] = fw_config->message[i]; + } + temp_str[i] = '\0'; + WritePrivateProfileString("Firmware","Message", temp_str, IniName); +} + +BOOL CALLBACK FirmConfig_Proc(HWND dialog,UINT komunikat,WPARAM wparam,LPARAM lparam) +{ + struct NDS_fw_config_data *fw_config = &win_fw_config; + int i; + char temp_str[27]; + + switch(komunikat) + { + case WM_INITDIALOG: + for(i=0;i<6;i++) SendDlgItemMessage(dialog,IDC_COMBO4,CB_ADDSTRING,0,(LPARAM)&firmLang[i]); + for(i=0;i<12;i++) SendDlgItemMessage(dialog,IDC_COMBO2,CB_ADDSTRING,0,(LPARAM)&firmMonth[i]); + for(i=0;i<16;i++) SendDlgItemMessage(dialog,IDC_COMBO1,CB_ADDSTRING,0,(LPARAM)&firmColor[i]); + for(i=0;i<31;i++) SendDlgItemMessage(dialog,IDC_COMBO3,CB_ADDSTRING,0,(LPARAM)&firmDay[i]); + SendDlgItemMessage(dialog,IDC_COMBO1,CB_SETCURSEL,fw_config->fav_colour,0); + SendDlgItemMessage(dialog,IDC_COMBO2,CB_SETCURSEL,fw_config->birth_month-1,0); + SendDlgItemMessage(dialog,IDC_COMBO3,CB_SETCURSEL,fw_config->birth_day-1,0); + SendDlgItemMessage(dialog,IDC_COMBO4,CB_SETCURSEL,fw_config->language,0); + SendDlgItemMessage(dialog,IDC_EDIT1,EM_SETLIMITTEXT,10,0); + SendDlgItemMessage(dialog,IDC_EDIT2,EM_SETLIMITTEXT,26,0); + SendDlgItemMessage(dialog,IDC_EDIT1,EM_SETSEL,0,10); + SendDlgItemMessage(dialog,IDC_EDIT2,EM_SETSEL,0,26); + + for ( i = 0; i < fw_config->nickname_len; i++) { + nickname_buffer[i] = fw_config->nickname[i]; + } + nickname_buffer[i] = '\0'; + SendDlgItemMessage(dialog,IDC_EDIT1,WM_SETTEXT,0,(LPARAM)nickname_buffer); + + for ( i = 0; i < fw_config->message_len; i++) { + message_buffer[i] = fw_config->message[i]; + } + message_buffer[i] = '\0'; + SendDlgItemMessage(dialog,IDC_EDIT2,WM_SETTEXT,0,(LPARAM)message_buffer); + break; + + case WM_COMMAND: + if((HIWORD(wparam)==BN_CLICKED)&&(((int)LOWORD(wparam))==IDOK)) + { + int char_index; + LRESULT res; + fw_config->fav_colour = SendDlgItemMessage(dialog,IDC_COMBO1,CB_GETCURSEL,0,0); + fw_config->birth_month = 1 + SendDlgItemMessage(dialog,IDC_COMBO2,CB_GETCURSEL,0,0); + fw_config->birth_day = 1 + SendDlgItemMessage(dialog,IDC_COMBO3,CB_GETCURSEL,0,0); + fw_config->language = SendDlgItemMessage(dialog,IDC_COMBO4,CB_GETCURSEL,0,0); + + *(WORD *)temp_str = 10; + res = SendDlgItemMessage(dialog,IDC_EDIT1,EM_GETLINE,0,(LPARAM)temp_str); + + if ( res > 0) { + temp_str[res] = '\0'; + fw_config->nickname_len = strlen( temp_str); + } + else { + strcpy( temp_str, "yopyop"); + fw_config->nickname_len = strlen( temp_str); + } + for ( char_index = 0; char_index < fw_config->nickname_len; char_index++) { + fw_config->nickname[char_index] = temp_str[char_index]; + } + + *(WORD *)temp_str = 26; + res = SendDlgItemMessage(dialog,IDC_EDIT2,EM_GETLINE,0,(LPARAM)temp_str); + if ( res > 0) { + temp_str[res] = '\0'; + fw_config->message_len = strlen( temp_str); + } + else { + fw_config->message_len = 0; + } + for ( char_index = 0; char_index < fw_config->message_len; char_index++) { + fw_config->message[char_index] = temp_str[char_index]; + } + + WriteFirmConfig( fw_config); + EndDialog(dialog,0); + NDS_CreateDummyFirmware( fw_config); + return 1; + } + else + if((HIWORD(wparam)==BN_CLICKED)&&(((int)LOWORD(wparam))==IDCANCEL)) + { + EndDialog(dialog, 0); + return 0; + } + break; + } + return 0; +} + + diff --git a/desmume/src/windows/FirmConfig.h b/src/windows/FirmConfig.h similarity index 97% rename from desmume/src/windows/FirmConfig.h rename to src/windows/FirmConfig.h index 245bf25f9..b9764fd2c 100644 --- a/desmume/src/windows/FirmConfig.h +++ b/src/windows/FirmConfig.h @@ -1,28 +1,28 @@ -/* - Copyright (C) 2007 Normmatt - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#ifndef FIRMCONFIG_H -#define FIRMCONFIG_H - -extern struct NDS_fw_config_data win_fw_config; - -BOOL CALLBACK FirmConfig_Proc(HWND dialog,UINT komunikat,WPARAM wparam,LPARAM lparam); - -#endif +/* + Copyright (C) 2007 Normmatt + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#ifndef FIRMCONFIG_H +#define FIRMCONFIG_H + +extern struct NDS_fw_config_data win_fw_config; + +BOOL CALLBACK FirmConfig_Proc(HWND dialog,UINT komunikat,WPARAM wparam,LPARAM lparam); + +#endif diff --git a/desmume/src/windows/GL/glext.h b/src/windows/GL/glext.h similarity index 98% rename from desmume/src/windows/GL/glext.h rename to src/windows/GL/glext.h index 8a82753a6..d982c5a18 100644 --- a/desmume/src/windows/GL/glext.h +++ b/src/windows/GL/glext.h @@ -1,8460 +1,8460 @@ -#ifndef __glext_h_ -#define __glext_h_ - -#ifdef __cplusplus -extern "C" { -#endif - -/* -** Copyright (c) 2007 The Khronos Group Inc. -** -** Permission is hereby granted, free of charge, to any person obtaining a -** copy of this software and/or associated documentation files (the -** "Materials"), to deal in the Materials without restriction, including -** without limitation the rights to use, copy, modify, merge, publish, -** distribute, sublicense, and/or sell copies of the Materials, and to -** permit persons to whom the Materials are furnished to do so, subject to -** the following conditions: -** -** The above copyright notice and this permission notice shall be included -** in all copies or substantial portions of the Materials. -** -** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY -** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, -** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE -** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS. -*/ - -#if defined(_WIN32) && !defined(APIENTRY) && !defined(__CYGWIN__) && !defined(__SCITECH_SNAP__) -#define WIN32_LEAN_AND_MEAN 1 -#include -#endif - -#ifndef APIENTRY -#define APIENTRY -#endif -#ifndef APIENTRYP -#define APIENTRYP APIENTRY * -#endif -#ifndef GLAPI -#define GLAPI extern -#endif - -/*************************************************************/ - -/* Header file version number, required by OpenGL ABI for Linux */ -/* glext.h last updated 2008/11/14 */ -/* Current version at http://www.opengl.org/registry/ */ -#define GL_GLEXT_VERSION 44 - -#ifndef GL_VERSION_1_2 -#define GL_UNSIGNED_BYTE_3_3_2 0x8032 -#define GL_UNSIGNED_SHORT_4_4_4_4 0x8033 -#define GL_UNSIGNED_SHORT_5_5_5_1 0x8034 -#define GL_UNSIGNED_INT_8_8_8_8 0x8035 -#define GL_UNSIGNED_INT_10_10_10_2 0x8036 -#define GL_RESCALE_NORMAL 0x803A -#define GL_TEXTURE_BINDING_3D 0x806A -#define GL_PACK_SKIP_IMAGES 0x806B -#define GL_PACK_IMAGE_HEIGHT 0x806C -#define GL_UNPACK_SKIP_IMAGES 0x806D -#define GL_UNPACK_IMAGE_HEIGHT 0x806E -#define GL_TEXTURE_3D 0x806F -#define GL_PROXY_TEXTURE_3D 0x8070 -#define GL_TEXTURE_DEPTH 0x8071 -#define GL_TEXTURE_WRAP_R 0x8072 -#define GL_MAX_3D_TEXTURE_SIZE 0x8073 -#define GL_UNSIGNED_BYTE_2_3_3_REV 0x8362 -#define GL_UNSIGNED_SHORT_5_6_5 0x8363 -#define GL_UNSIGNED_SHORT_5_6_5_REV 0x8364 -#define GL_UNSIGNED_SHORT_4_4_4_4_REV 0x8365 -#define GL_UNSIGNED_SHORT_1_5_5_5_REV 0x8366 -#define GL_UNSIGNED_INT_8_8_8_8_REV 0x8367 -#define GL_UNSIGNED_INT_2_10_10_10_REV 0x8368 -#define GL_BGR 0x80E0 -#define GL_BGRA 0x80E1 -#define GL_MAX_ELEMENTS_VERTICES 0x80E8 -#define GL_MAX_ELEMENTS_INDICES 0x80E9 -#define GL_CLAMP_TO_EDGE 0x812F -#define GL_TEXTURE_MIN_LOD 0x813A -#define GL_TEXTURE_MAX_LOD 0x813B -#define GL_TEXTURE_BASE_LEVEL 0x813C -#define GL_TEXTURE_MAX_LEVEL 0x813D -#define GL_LIGHT_MODEL_COLOR_CONTROL 0x81F8 -#define GL_SINGLE_COLOR 0x81F9 -#define GL_SEPARATE_SPECULAR_COLOR 0x81FA -#define GL_SMOOTH_POINT_SIZE_RANGE 0x0B12 -#define GL_SMOOTH_POINT_SIZE_GRANULARITY 0x0B13 -#define GL_SMOOTH_LINE_WIDTH_RANGE 0x0B22 -#define GL_SMOOTH_LINE_WIDTH_GRANULARITY 0x0B23 -#define GL_ALIASED_POINT_SIZE_RANGE 0x846D -#define GL_ALIASED_LINE_WIDTH_RANGE 0x846E -#endif - -#ifndef GL_ARB_imaging -#define GL_CONSTANT_COLOR 0x8001 -#define GL_ONE_MINUS_CONSTANT_COLOR 0x8002 -#define GL_CONSTANT_ALPHA 0x8003 -#define GL_ONE_MINUS_CONSTANT_ALPHA 0x8004 -#define GL_BLEND_COLOR 0x8005 -#define GL_FUNC_ADD 0x8006 -#define GL_MIN 0x8007 -#define GL_MAX 0x8008 -#define GL_BLEND_EQUATION 0x8009 -#define GL_FUNC_SUBTRACT 0x800A -#define GL_FUNC_REVERSE_SUBTRACT 0x800B -#define GL_CONVOLUTION_1D 0x8010 -#define GL_CONVOLUTION_2D 0x8011 -#define GL_SEPARABLE_2D 0x8012 -#define GL_CONVOLUTION_BORDER_MODE 0x8013 -#define GL_CONVOLUTION_FILTER_SCALE 0x8014 -#define GL_CONVOLUTION_FILTER_BIAS 0x8015 -#define GL_REDUCE 0x8016 -#define GL_CONVOLUTION_FORMAT 0x8017 -#define GL_CONVOLUTION_WIDTH 0x8018 -#define GL_CONVOLUTION_HEIGHT 0x8019 -#define GL_MAX_CONVOLUTION_WIDTH 0x801A -#define GL_MAX_CONVOLUTION_HEIGHT 0x801B -#define GL_POST_CONVOLUTION_RED_SCALE 0x801C -#define GL_POST_CONVOLUTION_GREEN_SCALE 0x801D -#define GL_POST_CONVOLUTION_BLUE_SCALE 0x801E -#define GL_POST_CONVOLUTION_ALPHA_SCALE 0x801F -#define GL_POST_CONVOLUTION_RED_BIAS 0x8020 -#define GL_POST_CONVOLUTION_GREEN_BIAS 0x8021 -#define GL_POST_CONVOLUTION_BLUE_BIAS 0x8022 -#define GL_POST_CONVOLUTION_ALPHA_BIAS 0x8023 -#define GL_HISTOGRAM 0x8024 -#define GL_PROXY_HISTOGRAM 0x8025 -#define GL_HISTOGRAM_WIDTH 0x8026 -#define GL_HISTOGRAM_FORMAT 0x8027 -#define GL_HISTOGRAM_RED_SIZE 0x8028 -#define GL_HISTOGRAM_GREEN_SIZE 0x8029 -#define GL_HISTOGRAM_BLUE_SIZE 0x802A -#define GL_HISTOGRAM_ALPHA_SIZE 0x802B -#define GL_HISTOGRAM_LUMINANCE_SIZE 0x802C -#define GL_HISTOGRAM_SINK 0x802D -#define GL_MINMAX 0x802E -#define GL_MINMAX_FORMAT 0x802F -#define GL_MINMAX_SINK 0x8030 -#define GL_TABLE_TOO_LARGE 0x8031 -#define GL_COLOR_MATRIX 0x80B1 -#define GL_COLOR_MATRIX_STACK_DEPTH 0x80B2 -#define GL_MAX_COLOR_MATRIX_STACK_DEPTH 0x80B3 -#define GL_POST_COLOR_MATRIX_RED_SCALE 0x80B4 -#define GL_POST_COLOR_MATRIX_GREEN_SCALE 0x80B5 -#define GL_POST_COLOR_MATRIX_BLUE_SCALE 0x80B6 -#define GL_POST_COLOR_MATRIX_ALPHA_SCALE 0x80B7 -#define GL_POST_COLOR_MATRIX_RED_BIAS 0x80B8 -#define GL_POST_COLOR_MATRIX_GREEN_BIAS 0x80B9 -#define GL_POST_COLOR_MATRIX_BLUE_BIAS 0x80BA -#define GL_POST_COLOR_MATRIX_ALPHA_BIAS 0x80BB -#define GL_COLOR_TABLE 0x80D0 -#define GL_POST_CONVOLUTION_COLOR_TABLE 0x80D1 -#define GL_POST_COLOR_MATRIX_COLOR_TABLE 0x80D2 -#define GL_PROXY_COLOR_TABLE 0x80D3 -#define GL_PROXY_POST_CONVOLUTION_COLOR_TABLE 0x80D4 -#define GL_PROXY_POST_COLOR_MATRIX_COLOR_TABLE 0x80D5 -#define GL_COLOR_TABLE_SCALE 0x80D6 -#define GL_COLOR_TABLE_BIAS 0x80D7 -#define GL_COLOR_TABLE_FORMAT 0x80D8 -#define GL_COLOR_TABLE_WIDTH 0x80D9 -#define GL_COLOR_TABLE_RED_SIZE 0x80DA -#define GL_COLOR_TABLE_GREEN_SIZE 0x80DB -#define GL_COLOR_TABLE_BLUE_SIZE 0x80DC -#define GL_COLOR_TABLE_ALPHA_SIZE 0x80DD -#define GL_COLOR_TABLE_LUMINANCE_SIZE 0x80DE -#define GL_COLOR_TABLE_INTENSITY_SIZE 0x80DF -#define GL_CONSTANT_BORDER 0x8151 -#define GL_REPLICATE_BORDER 0x8153 -#define GL_CONVOLUTION_BORDER_COLOR 0x8154 -#endif - -#ifndef GL_VERSION_1_3 -#define GL_TEXTURE0 0x84C0 -#define GL_TEXTURE1 0x84C1 -#define GL_TEXTURE2 0x84C2 -#define GL_TEXTURE3 0x84C3 -#define GL_TEXTURE4 0x84C4 -#define GL_TEXTURE5 0x84C5 -#define GL_TEXTURE6 0x84C6 -#define GL_TEXTURE7 0x84C7 -#define GL_TEXTURE8 0x84C8 -#define GL_TEXTURE9 0x84C9 -#define GL_TEXTURE10 0x84CA -#define GL_TEXTURE11 0x84CB -#define GL_TEXTURE12 0x84CC -#define GL_TEXTURE13 0x84CD -#define GL_TEXTURE14 0x84CE -#define GL_TEXTURE15 0x84CF -#define GL_TEXTURE16 0x84D0 -#define GL_TEXTURE17 0x84D1 -#define GL_TEXTURE18 0x84D2 -#define GL_TEXTURE19 0x84D3 -#define GL_TEXTURE20 0x84D4 -#define GL_TEXTURE21 0x84D5 -#define GL_TEXTURE22 0x84D6 -#define GL_TEXTURE23 0x84D7 -#define GL_TEXTURE24 0x84D8 -#define GL_TEXTURE25 0x84D9 -#define GL_TEXTURE26 0x84DA -#define GL_TEXTURE27 0x84DB -#define GL_TEXTURE28 0x84DC -#define GL_TEXTURE29 0x84DD -#define GL_TEXTURE30 0x84DE -#define GL_TEXTURE31 0x84DF -#define GL_ACTIVE_TEXTURE 0x84E0 -#define GL_CLIENT_ACTIVE_TEXTURE 0x84E1 -#define GL_MAX_TEXTURE_UNITS 0x84E2 -#define GL_TRANSPOSE_MODELVIEW_MATRIX 0x84E3 -#define GL_TRANSPOSE_PROJECTION_MATRIX 0x84E4 -#define GL_TRANSPOSE_TEXTURE_MATRIX 0x84E5 -#define GL_TRANSPOSE_COLOR_MATRIX 0x84E6 -#define GL_MULTISAMPLE 0x809D -#define GL_SAMPLE_ALPHA_TO_COVERAGE 0x809E -#define GL_SAMPLE_ALPHA_TO_ONE 0x809F -#define GL_SAMPLE_COVERAGE 0x80A0 -#define GL_SAMPLE_BUFFERS 0x80A8 -#define GL_SAMPLES 0x80A9 -#define GL_SAMPLE_COVERAGE_VALUE 0x80AA -#define GL_SAMPLE_COVERAGE_INVERT 0x80AB -#define GL_MULTISAMPLE_BIT 0x20000000 -#define GL_NORMAL_MAP 0x8511 -#define GL_REFLECTION_MAP 0x8512 -#define GL_TEXTURE_CUBE_MAP 0x8513 -#define GL_TEXTURE_BINDING_CUBE_MAP 0x8514 -#define GL_TEXTURE_CUBE_MAP_POSITIVE_X 0x8515 -#define GL_TEXTURE_CUBE_MAP_NEGATIVE_X 0x8516 -#define GL_TEXTURE_CUBE_MAP_POSITIVE_Y 0x8517 -#define GL_TEXTURE_CUBE_MAP_NEGATIVE_Y 0x8518 -#define GL_TEXTURE_CUBE_MAP_POSITIVE_Z 0x8519 -#define GL_TEXTURE_CUBE_MAP_NEGATIVE_Z 0x851A -#define GL_PROXY_TEXTURE_CUBE_MAP 0x851B -#define GL_MAX_CUBE_MAP_TEXTURE_SIZE 0x851C -#define GL_COMPRESSED_ALPHA 0x84E9 -#define GL_COMPRESSED_LUMINANCE 0x84EA -#define GL_COMPRESSED_LUMINANCE_ALPHA 0x84EB -#define GL_COMPRESSED_INTENSITY 0x84EC -#define GL_COMPRESSED_RGB 0x84ED -#define GL_COMPRESSED_RGBA 0x84EE -#define GL_TEXTURE_COMPRESSION_HINT 0x84EF -#define GL_TEXTURE_COMPRESSED_IMAGE_SIZE 0x86A0 -#define GL_TEXTURE_COMPRESSED 0x86A1 -#define GL_NUM_COMPRESSED_TEXTURE_FORMATS 0x86A2 -#define GL_COMPRESSED_TEXTURE_FORMATS 0x86A3 -#define GL_CLAMP_TO_BORDER 0x812D -#define GL_COMBINE 0x8570 -#define GL_COMBINE_RGB 0x8571 -#define GL_COMBINE_ALPHA 0x8572 -#define GL_SOURCE0_RGB 0x8580 -#define GL_SOURCE1_RGB 0x8581 -#define GL_SOURCE2_RGB 0x8582 -#define GL_SOURCE0_ALPHA 0x8588 -#define GL_SOURCE1_ALPHA 0x8589 -#define GL_SOURCE2_ALPHA 0x858A -#define GL_OPERAND0_RGB 0x8590 -#define GL_OPERAND1_RGB 0x8591 -#define GL_OPERAND2_RGB 0x8592 -#define GL_OPERAND0_ALPHA 0x8598 -#define GL_OPERAND1_ALPHA 0x8599 -#define GL_OPERAND2_ALPHA 0x859A -#define GL_RGB_SCALE 0x8573 -#define GL_ADD_SIGNED 0x8574 -#define GL_INTERPOLATE 0x8575 -#define GL_SUBTRACT 0x84E7 -#define GL_CONSTANT 0x8576 -#define GL_PRIMARY_COLOR 0x8577 -#define GL_PREVIOUS 0x8578 -#define GL_DOT3_RGB 0x86AE -#define GL_DOT3_RGBA 0x86AF -#endif - -#ifndef GL_VERSION_1_4 -#define GL_BLEND_DST_RGB 0x80C8 -#define GL_BLEND_SRC_RGB 0x80C9 -#define GL_BLEND_DST_ALPHA 0x80CA -#define GL_BLEND_SRC_ALPHA 0x80CB -#define GL_POINT_SIZE_MIN 0x8126 -#define GL_POINT_SIZE_MAX 0x8127 -#define GL_POINT_FADE_THRESHOLD_SIZE 0x8128 -#define GL_POINT_DISTANCE_ATTENUATION 0x8129 -#define GL_GENERATE_MIPMAP 0x8191 -#define GL_GENERATE_MIPMAP_HINT 0x8192 -#define GL_DEPTH_COMPONENT16 0x81A5 -#define GL_DEPTH_COMPONENT24 0x81A6 -#define GL_DEPTH_COMPONENT32 0x81A7 -#define GL_MIRRORED_REPEAT 0x8370 -#define GL_FOG_COORDINATE_SOURCE 0x8450 -#define GL_FOG_COORDINATE 0x8451 -#define GL_FRAGMENT_DEPTH 0x8452 -#define GL_CURRENT_FOG_COORDINATE 0x8453 -#define GL_FOG_COORDINATE_ARRAY_TYPE 0x8454 -#define GL_FOG_COORDINATE_ARRAY_STRIDE 0x8455 -#define GL_FOG_COORDINATE_ARRAY_POINTER 0x8456 -#define GL_FOG_COORDINATE_ARRAY 0x8457 -#define GL_COLOR_SUM 0x8458 -#define GL_CURRENT_SECONDARY_COLOR 0x8459 -#define GL_SECONDARY_COLOR_ARRAY_SIZE 0x845A -#define GL_SECONDARY_COLOR_ARRAY_TYPE 0x845B -#define GL_SECONDARY_COLOR_ARRAY_STRIDE 0x845C -#define GL_SECONDARY_COLOR_ARRAY_POINTER 0x845D -#define GL_SECONDARY_COLOR_ARRAY 0x845E -#define GL_MAX_TEXTURE_LOD_BIAS 0x84FD -#define GL_TEXTURE_FILTER_CONTROL 0x8500 -#define GL_TEXTURE_LOD_BIAS 0x8501 -#define GL_INCR_WRAP 0x8507 -#define GL_DECR_WRAP 0x8508 -#define GL_TEXTURE_DEPTH_SIZE 0x884A -#define GL_DEPTH_TEXTURE_MODE 0x884B -#define GL_TEXTURE_COMPARE_MODE 0x884C -#define GL_TEXTURE_COMPARE_FUNC 0x884D -#define GL_COMPARE_R_TO_TEXTURE 0x884E -#endif - -#ifndef GL_VERSION_1_5 -#define GL_BUFFER_SIZE 0x8764 -#define GL_BUFFER_USAGE 0x8765 -#define GL_QUERY_COUNTER_BITS 0x8864 -#define GL_CURRENT_QUERY 0x8865 -#define GL_QUERY_RESULT 0x8866 -#define GL_QUERY_RESULT_AVAILABLE 0x8867 -#define GL_ARRAY_BUFFER 0x8892 -#define GL_ELEMENT_ARRAY_BUFFER 0x8893 -#define GL_ARRAY_BUFFER_BINDING 0x8894 -#define GL_ELEMENT_ARRAY_BUFFER_BINDING 0x8895 -#define GL_VERTEX_ARRAY_BUFFER_BINDING 0x8896 -#define GL_NORMAL_ARRAY_BUFFER_BINDING 0x8897 -#define GL_COLOR_ARRAY_BUFFER_BINDING 0x8898 -#define GL_INDEX_ARRAY_BUFFER_BINDING 0x8899 -#define GL_TEXTURE_COORD_ARRAY_BUFFER_BINDING 0x889A -#define GL_EDGE_FLAG_ARRAY_BUFFER_BINDING 0x889B -#define GL_SECONDARY_COLOR_ARRAY_BUFFER_BINDING 0x889C -#define GL_FOG_COORDINATE_ARRAY_BUFFER_BINDING 0x889D -#define GL_WEIGHT_ARRAY_BUFFER_BINDING 0x889E -#define GL_VERTEX_ATTRIB_ARRAY_BUFFER_BINDING 0x889F -#define GL_READ_ONLY 0x88B8 -#define GL_WRITE_ONLY 0x88B9 -#define GL_READ_WRITE 0x88BA -#define GL_BUFFER_ACCESS 0x88BB -#define GL_BUFFER_MAPPED 0x88BC -#define GL_BUFFER_MAP_POINTER 0x88BD -#define GL_STREAM_DRAW 0x88E0 -#define GL_STREAM_READ 0x88E1 -#define GL_STREAM_COPY 0x88E2 -#define GL_STATIC_DRAW 0x88E4 -#define GL_STATIC_READ 0x88E5 -#define GL_STATIC_COPY 0x88E6 -#define GL_DYNAMIC_DRAW 0x88E8 -#define GL_DYNAMIC_READ 0x88E9 -#define GL_DYNAMIC_COPY 0x88EA -#define GL_SAMPLES_PASSED 0x8914 -#define GL_FOG_COORD_SRC GL_FOG_COORDINATE_SOURCE -#define GL_FOG_COORD GL_FOG_COORDINATE -#define GL_CURRENT_FOG_COORD GL_CURRENT_FOG_COORDINATE -#define GL_FOG_COORD_ARRAY_TYPE GL_FOG_COORDINATE_ARRAY_TYPE -#define GL_FOG_COORD_ARRAY_STRIDE GL_FOG_COORDINATE_ARRAY_STRIDE -#define GL_FOG_COORD_ARRAY_POINTER GL_FOG_COORDINATE_ARRAY_POINTER -#define GL_FOG_COORD_ARRAY GL_FOG_COORDINATE_ARRAY -#define GL_FOG_COORD_ARRAY_BUFFER_BINDING GL_FOG_COORDINATE_ARRAY_BUFFER_BINDING -#define GL_SRC0_RGB GL_SOURCE0_RGB -#define GL_SRC1_RGB GL_SOURCE1_RGB -#define GL_SRC2_RGB GL_SOURCE2_RGB -#define GL_SRC0_ALPHA GL_SOURCE0_ALPHA -#define GL_SRC1_ALPHA GL_SOURCE1_ALPHA -#define GL_SRC2_ALPHA GL_SOURCE2_ALPHA -#endif - -#ifndef GL_VERSION_2_0 -#define GL_BLEND_EQUATION_RGB GL_BLEND_EQUATION -#define GL_VERTEX_ATTRIB_ARRAY_ENABLED 0x8622 -#define GL_VERTEX_ATTRIB_ARRAY_SIZE 0x8623 -#define GL_VERTEX_ATTRIB_ARRAY_STRIDE 0x8624 -#define GL_VERTEX_ATTRIB_ARRAY_TYPE 0x8625 -#define GL_CURRENT_VERTEX_ATTRIB 0x8626 -#define GL_VERTEX_PROGRAM_POINT_SIZE 0x8642 -#define GL_VERTEX_PROGRAM_TWO_SIDE 0x8643 -#define GL_VERTEX_ATTRIB_ARRAY_POINTER 0x8645 -#define GL_STENCIL_BACK_FUNC 0x8800 -#define GL_STENCIL_BACK_FAIL 0x8801 -#define GL_STENCIL_BACK_PASS_DEPTH_FAIL 0x8802 -#define GL_STENCIL_BACK_PASS_DEPTH_PASS 0x8803 -#define GL_MAX_DRAW_BUFFERS 0x8824 -#define GL_DRAW_BUFFER0 0x8825 -#define GL_DRAW_BUFFER1 0x8826 -#define GL_DRAW_BUFFER2 0x8827 -#define GL_DRAW_BUFFER3 0x8828 -#define GL_DRAW_BUFFER4 0x8829 -#define GL_DRAW_BUFFER5 0x882A -#define GL_DRAW_BUFFER6 0x882B -#define GL_DRAW_BUFFER7 0x882C -#define GL_DRAW_BUFFER8 0x882D -#define GL_DRAW_BUFFER9 0x882E -#define GL_DRAW_BUFFER10 0x882F -#define GL_DRAW_BUFFER11 0x8830 -#define GL_DRAW_BUFFER12 0x8831 -#define GL_DRAW_BUFFER13 0x8832 -#define GL_DRAW_BUFFER14 0x8833 -#define GL_DRAW_BUFFER15 0x8834 -#define GL_BLEND_EQUATION_ALPHA 0x883D -#define GL_POINT_SPRITE 0x8861 -#define GL_COORD_REPLACE 0x8862 -#define GL_MAX_VERTEX_ATTRIBS 0x8869 -#define GL_VERTEX_ATTRIB_ARRAY_NORMALIZED 0x886A -#define GL_MAX_TEXTURE_COORDS 0x8871 -#define GL_MAX_TEXTURE_IMAGE_UNITS 0x8872 -#define GL_FRAGMENT_SHADER 0x8B30 -#define GL_VERTEX_SHADER 0x8B31 -#define GL_MAX_FRAGMENT_UNIFORM_COMPONENTS 0x8B49 -#define GL_MAX_VERTEX_UNIFORM_COMPONENTS 0x8B4A -#define GL_MAX_VARYING_FLOATS 0x8B4B -#define GL_MAX_VERTEX_TEXTURE_IMAGE_UNITS 0x8B4C -#define GL_MAX_COMBINED_TEXTURE_IMAGE_UNITS 0x8B4D -#define GL_SHADER_TYPE 0x8B4F -#define GL_FLOAT_VEC2 0x8B50 -#define GL_FLOAT_VEC3 0x8B51 -#define GL_FLOAT_VEC4 0x8B52 -#define GL_INT_VEC2 0x8B53 -#define GL_INT_VEC3 0x8B54 -#define GL_INT_VEC4 0x8B55 -#define GL_BOOL 0x8B56 -#define GL_BOOL_VEC2 0x8B57 -#define GL_BOOL_VEC3 0x8B58 -#define GL_BOOL_VEC4 0x8B59 -#define GL_FLOAT_MAT2 0x8B5A -#define GL_FLOAT_MAT3 0x8B5B -#define GL_FLOAT_MAT4 0x8B5C -#define GL_SAMPLER_1D 0x8B5D -#define GL_SAMPLER_2D 0x8B5E -#define GL_SAMPLER_3D 0x8B5F -#define GL_SAMPLER_CUBE 0x8B60 -#define GL_SAMPLER_1D_SHADOW 0x8B61 -#define GL_SAMPLER_2D_SHADOW 0x8B62 -#define GL_DELETE_STATUS 0x8B80 -#define GL_COMPILE_STATUS 0x8B81 -#define GL_LINK_STATUS 0x8B82 -#define GL_VALIDATE_STATUS 0x8B83 -#define GL_INFO_LOG_LENGTH 0x8B84 -#define GL_ATTACHED_SHADERS 0x8B85 -#define GL_ACTIVE_UNIFORMS 0x8B86 -#define GL_ACTIVE_UNIFORM_MAX_LENGTH 0x8B87 -#define GL_SHADER_SOURCE_LENGTH 0x8B88 -#define GL_ACTIVE_ATTRIBUTES 0x8B89 -#define GL_ACTIVE_ATTRIBUTE_MAX_LENGTH 0x8B8A -#define GL_FRAGMENT_SHADER_DERIVATIVE_HINT 0x8B8B -#define GL_SHADING_LANGUAGE_VERSION 0x8B8C -#define GL_CURRENT_PROGRAM 0x8B8D -#define GL_POINT_SPRITE_COORD_ORIGIN 0x8CA0 -#define GL_LOWER_LEFT 0x8CA1 -#define GL_UPPER_LEFT 0x8CA2 -#define GL_STENCIL_BACK_REF 0x8CA3 -#define GL_STENCIL_BACK_VALUE_MASK 0x8CA4 -#define GL_STENCIL_BACK_WRITEMASK 0x8CA5 -#endif - -#ifndef GL_VERSION_2_1 -#define GL_CURRENT_RASTER_SECONDARY_COLOR 0x845F -#define GL_PIXEL_PACK_BUFFER 0x88EB -#define GL_PIXEL_UNPACK_BUFFER 0x88EC -#define GL_PIXEL_PACK_BUFFER_BINDING 0x88ED -#define GL_PIXEL_UNPACK_BUFFER_BINDING 0x88EF -#define GL_FLOAT_MAT2x3 0x8B65 -#define GL_FLOAT_MAT2x4 0x8B66 -#define GL_FLOAT_MAT3x2 0x8B67 -#define GL_FLOAT_MAT3x4 0x8B68 -#define GL_FLOAT_MAT4x2 0x8B69 -#define GL_FLOAT_MAT4x3 0x8B6A -#define GL_SRGB 0x8C40 -#define GL_SRGB8 0x8C41 -#define GL_SRGB_ALPHA 0x8C42 -#define GL_SRGB8_ALPHA8 0x8C43 -#define GL_SLUMINANCE_ALPHA 0x8C44 -#define GL_SLUMINANCE8_ALPHA8 0x8C45 -#define GL_SLUMINANCE 0x8C46 -#define GL_SLUMINANCE8 0x8C47 -#define GL_COMPRESSED_SRGB 0x8C48 -#define GL_COMPRESSED_SRGB_ALPHA 0x8C49 -#define GL_COMPRESSED_SLUMINANCE 0x8C4A -#define GL_COMPRESSED_SLUMINANCE_ALPHA 0x8C4B -#endif - -#ifndef GL_VERSION_3_0 -#define GL_COMPARE_REF_TO_TEXTURE GL_COMPARE_R_TO_TEXTURE_ARB -#define GL_CLIP_DISTANCE0 GL_CLIP_PLANE0 -#define GL_CLIP_DISTANCE1 GL_CLIP_PLANE1 -#define GL_CLIP_DISTANCE2 GL_CLIP_PLANE2 -#define GL_CLIP_DISTANCE3 GL_CLIP_PLANE3 -#define GL_CLIP_DISTANCE4 GL_CLIP_PLANE4 -#define GL_CLIP_DISTANCE5 GL_CLIP_PLANE5 -#define GL_MAX_CLIP_DISTANCES GL_MAX_CLIP_PLANES -#define GL_MAJOR_VERSION 0x821B -#define GL_MINOR_VERSION 0x821C -#define GL_NUM_EXTENSIONS 0x821D -#define GL_CONTEXT_FLAGS 0x821E -#define GL_DEPTH_BUFFER 0x8223 -#define GL_STENCIL_BUFFER 0x8224 -#define GL_COMPRESSED_RED 0x8225 -#define GL_COMPRESSED_RG 0x8226 -#define GL_CONTEXT_FLAG_FORWARD_COMPATIBLE_BIT 0x0001 -#define GL_RGBA32F 0x8814 -#define GL_RGB32F 0x8815 -#define GL_RGBA16F 0x881A -#define GL_RGB16F 0x881B -#define GL_VERTEX_ATTRIB_ARRAY_INTEGER 0x88FD -#define GL_MAX_ARRAY_TEXTURE_LAYERS 0x88FF -#define GL_MIN_PROGRAM_TEXEL_OFFSET 0x8904 -#define GL_MAX_PROGRAM_TEXEL_OFFSET 0x8905 -#define GL_CLAMP_VERTEX_COLOR 0x891A -#define GL_CLAMP_FRAGMENT_COLOR 0x891B -#define GL_CLAMP_READ_COLOR 0x891C -#define GL_FIXED_ONLY 0x891D -#define GL_MAX_VARYING_COMPONENTS GL_MAX_VARYING_FLOATS -#define GL_TEXTURE_RED_TYPE 0x8C10 -#define GL_TEXTURE_GREEN_TYPE 0x8C11 -#define GL_TEXTURE_BLUE_TYPE 0x8C12 -#define GL_TEXTURE_ALPHA_TYPE 0x8C13 -#define GL_TEXTURE_LUMINANCE_TYPE 0x8C14 -#define GL_TEXTURE_INTENSITY_TYPE 0x8C15 -#define GL_TEXTURE_DEPTH_TYPE 0x8C16 -#define GL_UNSIGNED_NORMALIZED 0x8C17 -#define GL_TEXTURE_1D_ARRAY 0x8C18 -#define GL_PROXY_TEXTURE_1D_ARRAY 0x8C19 -#define GL_TEXTURE_2D_ARRAY 0x8C1A -#define GL_PROXY_TEXTURE_2D_ARRAY 0x8C1B -#define GL_TEXTURE_BINDING_1D_ARRAY 0x8C1C -#define GL_TEXTURE_BINDING_2D_ARRAY 0x8C1D -#define GL_R11F_G11F_B10F 0x8C3A -#define GL_UNSIGNED_INT_10F_11F_11F_REV 0x8C3B -#define GL_RGB9_E5 0x8C3D -#define GL_UNSIGNED_INT_5_9_9_9_REV 0x8C3E -#define GL_TEXTURE_SHARED_SIZE 0x8C3F -#define GL_TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH 0x8C76 -#define GL_TRANSFORM_FEEDBACK_BUFFER_MODE 0x8C7F -#define GL_MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS 0x8C80 -#define GL_TRANSFORM_FEEDBACK_VARYINGS 0x8C83 -#define GL_TRANSFORM_FEEDBACK_BUFFER_START 0x8C84 -#define GL_TRANSFORM_FEEDBACK_BUFFER_SIZE 0x8C85 -#define GL_PRIMITIVES_GENERATED 0x8C87 -#define GL_TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN 0x8C88 -#define GL_RASTERIZER_DISCARD 0x8C89 -#define GL_MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS 0x8C8A -#define GL_MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS 0x8C8B -#define GL_INTERLEAVED_ATTRIBS 0x8C8C -#define GL_SEPARATE_ATTRIBS 0x8C8D -#define GL_TRANSFORM_FEEDBACK_BUFFER 0x8C8E -#define GL_TRANSFORM_FEEDBACK_BUFFER_BINDING 0x8C8F -#define GL_RGBA32UI 0x8D70 -#define GL_RGB32UI 0x8D71 -#define GL_RGBA16UI 0x8D76 -#define GL_RGB16UI 0x8D77 -#define GL_RGBA8UI 0x8D7C -#define GL_RGB8UI 0x8D7D -#define GL_RGBA32I 0x8D82 -#define GL_RGB32I 0x8D83 -#define GL_RGBA16I 0x8D88 -#define GL_RGB16I 0x8D89 -#define GL_RGBA8I 0x8D8E -#define GL_RGB8I 0x8D8F -#define GL_RED_INTEGER 0x8D94 -#define GL_GREEN_INTEGER 0x8D95 -#define GL_BLUE_INTEGER 0x8D96 -#define GL_ALPHA_INTEGER 0x8D97 -#define GL_RGB_INTEGER 0x8D98 -#define GL_RGBA_INTEGER 0x8D99 -#define GL_BGR_INTEGER 0x8D9A -#define GL_BGRA_INTEGER 0x8D9B -#define GL_SAMPLER_1D_ARRAY 0x8DC0 -#define GL_SAMPLER_2D_ARRAY 0x8DC1 -#define GL_SAMPLER_1D_ARRAY_SHADOW 0x8DC3 -#define GL_SAMPLER_2D_ARRAY_SHADOW 0x8DC4 -#define GL_SAMPLER_CUBE_SHADOW 0x8DC5 -#define GL_UNSIGNED_INT_VEC2 0x8DC6 -#define GL_UNSIGNED_INT_VEC3 0x8DC7 -#define GL_UNSIGNED_INT_VEC4 0x8DC8 -#define GL_INT_SAMPLER_1D 0x8DC9 -#define GL_INT_SAMPLER_2D 0x8DCA -#define GL_INT_SAMPLER_3D 0x8DCB -#define GL_INT_SAMPLER_CUBE 0x8DCC -#define GL_INT_SAMPLER_1D_ARRAY 0x8DCE -#define GL_INT_SAMPLER_2D_ARRAY 0x8DCF -#define GL_UNSIGNED_INT_SAMPLER_1D 0x8DD1 -#define GL_UNSIGNED_INT_SAMPLER_2D 0x8DD2 -#define GL_UNSIGNED_INT_SAMPLER_3D 0x8DD3 -#define GL_UNSIGNED_INT_SAMPLER_CUBE 0x8DD4 -#define GL_UNSIGNED_INT_SAMPLER_1D_ARRAY 0x8DD6 -#define GL_UNSIGNED_INT_SAMPLER_2D_ARRAY 0x8DD7 -#define GL_QUERY_WAIT 0x8E13 -#define GL_QUERY_NO_WAIT 0x8E14 -#define GL_QUERY_BY_REGION_WAIT 0x8E15 -#define GL_QUERY_BY_REGION_NO_WAIT 0x8E16 -/* Reuse tokens from ARB_depth_buffer_float */ -/* reuse GL_DEPTH_COMPONENT32F */ -/* reuse GL_DEPTH32F_STENCIL8 */ -/* reuse GL_FLOAT_32_UNSIGNED_INT_24_8_REV */ -/* Reuse tokens from ARB_framebuffer_object */ -/* reuse GL_INVALID_FRAMEBUFFER_OPERATION */ -/* reuse GL_FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING */ -/* reuse GL_FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE */ -/* reuse GL_FRAMEBUFFER_ATTACHMENT_RED_SIZE */ -/* reuse GL_FRAMEBUFFER_ATTACHMENT_GREEN_SIZE */ -/* reuse GL_FRAMEBUFFER_ATTACHMENT_BLUE_SIZE */ -/* reuse GL_FRAMEBUFFER_ATTACHMENT_ALPHA_SIZE */ -/* reuse GL_FRAMEBUFFER_ATTACHMENT_DEPTH_SIZE */ -/* reuse GL_FRAMEBUFFER_ATTACHMENT_STENCIL_SIZE */ -/* reuse GL_FRAMEBUFFER_DEFAULT */ -/* reuse GL_FRAMEBUFFER_UNDEFINED */ -/* reuse GL_DEPTH_STENCIL_ATTACHMENT */ -/* reuse GL_INDEX */ -/* reuse GL_MAX_RENDERBUFFER_SIZE */ -/* reuse GL_DEPTH_STENCIL */ -/* reuse GL_UNSIGNED_INT_24_8 */ -/* reuse GL_DEPTH24_STENCIL8 */ -/* reuse GL_TEXTURE_STENCIL_SIZE */ -/* reuse GL_TEXTURE_RED_TYPE */ -/* reuse GL_TEXTURE_GREEN_TYPE */ -/* reuse GL_TEXTURE_BLUE_TYPE */ -/* reuse GL_TEXTURE_ALPHA_TYPE */ -/* reuse GL_TEXTURE_LUMINANCE_TYPE */ -/* reuse GL_TEXTURE_INTENSITY_TYPE */ -/* reuse GL_TEXTURE_DEPTH_TYPE */ -/* reuse GL_UNSIGNED_NORMALIZED */ -/* reuse GL_FRAMEBUFFER_BINDING */ -/* reuse GL_DRAW_FRAMEBUFFER_BINDING */ -/* reuse GL_RENDERBUFFER_BINDING */ -/* reuse GL_READ_FRAMEBUFFER */ -/* reuse GL_DRAW_FRAMEBUFFER */ -/* reuse GL_READ_FRAMEBUFFER_BINDING */ -/* reuse GL_RENDERBUFFER_SAMPLES */ -/* reuse GL_FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE */ -/* reuse GL_FRAMEBUFFER_ATTACHMENT_OBJECT_NAME */ -/* reuse GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL */ -/* reuse GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE */ -/* reuse GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER */ -/* reuse GL_FRAMEBUFFER_COMPLETE */ -/* reuse GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT */ -/* reuse GL_FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT */ -/* reuse GL_FRAMEBUFFER_INCOMPLETE_DRAW_BUFFER */ -/* reuse GL_FRAMEBUFFER_INCOMPLETE_READ_BUFFER */ -/* reuse GL_FRAMEBUFFER_UNSUPPORTED */ -/* reuse GL_MAX_COLOR_ATTACHMENTS */ -/* reuse GL_COLOR_ATTACHMENT0 */ -/* reuse GL_COLOR_ATTACHMENT1 */ -/* reuse GL_COLOR_ATTACHMENT2 */ -/* reuse GL_COLOR_ATTACHMENT3 */ -/* reuse GL_COLOR_ATTACHMENT4 */ -/* reuse GL_COLOR_ATTACHMENT5 */ -/* reuse GL_COLOR_ATTACHMENT6 */ -/* reuse GL_COLOR_ATTACHMENT7 */ -/* reuse GL_COLOR_ATTACHMENT8 */ -/* reuse GL_COLOR_ATTACHMENT9 */ -/* reuse GL_COLOR_ATTACHMENT10 */ -/* reuse GL_COLOR_ATTACHMENT11 */ -/* reuse GL_COLOR_ATTACHMENT12 */ -/* reuse GL_COLOR_ATTACHMENT13 */ -/* reuse GL_COLOR_ATTACHMENT14 */ -/* reuse GL_COLOR_ATTACHMENT15 */ -/* reuse GL_DEPTH_ATTACHMENT */ -/* reuse GL_STENCIL_ATTACHMENT */ -/* reuse GL_FRAMEBUFFER */ -/* reuse GL_RENDERBUFFER */ -/* reuse GL_RENDERBUFFER_WIDTH */ -/* reuse GL_RENDERBUFFER_HEIGHT */ -/* reuse GL_RENDERBUFFER_INTERNAL_FORMAT */ -/* reuse GL_STENCIL_INDEX1 */ -/* reuse GL_STENCIL_INDEX4 */ -/* reuse GL_STENCIL_INDEX8 */ -/* reuse GL_STENCIL_INDEX16 */ -/* reuse GL_RENDERBUFFER_RED_SIZE */ -/* reuse GL_RENDERBUFFER_GREEN_SIZE */ -/* reuse GL_RENDERBUFFER_BLUE_SIZE */ -/* reuse GL_RENDERBUFFER_ALPHA_SIZE */ -/* reuse GL_RENDERBUFFER_DEPTH_SIZE */ -/* reuse GL_RENDERBUFFER_STENCIL_SIZE */ -/* reuse GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE */ -/* reuse GL_MAX_SAMPLES */ -/* Reuse tokens from ARB_framebuffer_sRGB */ -/* reuse GL_FRAMEBUFFER_SRGB */ -/* Reuse tokens from ARB_half_float_vertex */ -/* reuse GL_HALF_FLOAT */ -/* Reuse tokens from ARB_map_buffer_range */ -/* reuse GL_MAP_READ_BIT */ -/* reuse GL_MAP_WRITE_BIT */ -/* reuse GL_MAP_INVALIDATE_RANGE_BIT */ -/* reuse GL_MAP_INVALIDATE_BUFFER_BIT */ -/* reuse GL_MAP_FLUSH_EXPLICIT_BIT */ -/* reuse GL_MAP_UNSYNCHRONIZED_BIT */ -/* Reuse tokens from ARB_texture_compression_rgtc */ -/* reuse GL_COMPRESSED_RED_RGTC1 */ -/* reuse GL_COMPRESSED_SIGNED_RED_RGTC1 */ -/* reuse GL_COMPRESSED_RG_RGTC2 */ -/* reuse GL_COMPRESSED_SIGNED_RG_RGTC2 */ -/* Reuse tokens from ARB_texture_rg */ -/* reuse GL_RG */ -/* reuse GL_RG_INTEGER */ -/* reuse GL_R8 */ -/* reuse GL_R16 */ -/* reuse GL_RG8 */ -/* reuse GL_RG16 */ -/* reuse GL_R16F */ -/* reuse GL_R32F */ -/* reuse GL_RG16F */ -/* reuse GL_RG32F */ -/* reuse GL_R8I */ -/* reuse GL_R8UI */ -/* reuse GL_R16I */ -/* reuse GL_R16UI */ -/* reuse GL_R32I */ -/* reuse GL_R32UI */ -/* reuse GL_RG8I */ -/* reuse GL_RG8UI */ -/* reuse GL_RG16I */ -/* reuse GL_RG16UI */ -/* reuse GL_RG32I */ -/* reuse GL_RG32UI */ -/* Reuse tokens from ARB_vertex_array_object */ -/* reuse GL_VERTEX_ARRAY_BINDING */ -#endif - -#ifndef GL_ARB_multitexture -#define GL_TEXTURE0_ARB 0x84C0 -#define GL_TEXTURE1_ARB 0x84C1 -#define GL_TEXTURE2_ARB 0x84C2 -#define GL_TEXTURE3_ARB 0x84C3 -#define GL_TEXTURE4_ARB 0x84C4 -#define GL_TEXTURE5_ARB 0x84C5 -#define GL_TEXTURE6_ARB 0x84C6 -#define GL_TEXTURE7_ARB 0x84C7 -#define GL_TEXTURE8_ARB 0x84C8 -#define GL_TEXTURE9_ARB 0x84C9 -#define GL_TEXTURE10_ARB 0x84CA -#define GL_TEXTURE11_ARB 0x84CB -#define GL_TEXTURE12_ARB 0x84CC -#define GL_TEXTURE13_ARB 0x84CD -#define GL_TEXTURE14_ARB 0x84CE -#define GL_TEXTURE15_ARB 0x84CF -#define GL_TEXTURE16_ARB 0x84D0 -#define GL_TEXTURE17_ARB 0x84D1 -#define GL_TEXTURE18_ARB 0x84D2 -#define GL_TEXTURE19_ARB 0x84D3 -#define GL_TEXTURE20_ARB 0x84D4 -#define GL_TEXTURE21_ARB 0x84D5 -#define GL_TEXTURE22_ARB 0x84D6 -#define GL_TEXTURE23_ARB 0x84D7 -#define GL_TEXTURE24_ARB 0x84D8 -#define GL_TEXTURE25_ARB 0x84D9 -#define GL_TEXTURE26_ARB 0x84DA -#define GL_TEXTURE27_ARB 0x84DB -#define GL_TEXTURE28_ARB 0x84DC -#define GL_TEXTURE29_ARB 0x84DD -#define GL_TEXTURE30_ARB 0x84DE -#define GL_TEXTURE31_ARB 0x84DF -#define GL_ACTIVE_TEXTURE_ARB 0x84E0 -#define GL_CLIENT_ACTIVE_TEXTURE_ARB 0x84E1 -#define GL_MAX_TEXTURE_UNITS_ARB 0x84E2 -#endif - -#ifndef GL_ARB_transpose_matrix -#define GL_TRANSPOSE_MODELVIEW_MATRIX_ARB 0x84E3 -#define GL_TRANSPOSE_PROJECTION_MATRIX_ARB 0x84E4 -#define GL_TRANSPOSE_TEXTURE_MATRIX_ARB 0x84E5 -#define GL_TRANSPOSE_COLOR_MATRIX_ARB 0x84E6 -#endif - -#ifndef GL_ARB_multisample -#define GL_MULTISAMPLE_ARB 0x809D -#define GL_SAMPLE_ALPHA_TO_COVERAGE_ARB 0x809E -#define GL_SAMPLE_ALPHA_TO_ONE_ARB 0x809F -#define GL_SAMPLE_COVERAGE_ARB 0x80A0 -#define GL_SAMPLE_BUFFERS_ARB 0x80A8 -#define GL_SAMPLES_ARB 0x80A9 -#define GL_SAMPLE_COVERAGE_VALUE_ARB 0x80AA -#define GL_SAMPLE_COVERAGE_INVERT_ARB 0x80AB -#define GL_MULTISAMPLE_BIT_ARB 0x20000000 -#endif - -#ifndef GL_ARB_texture_env_add -#endif - -#ifndef GL_ARB_texture_cube_map -#define GL_NORMAL_MAP_ARB 0x8511 -#define GL_REFLECTION_MAP_ARB 0x8512 -#define GL_TEXTURE_CUBE_MAP_ARB 0x8513 -#define GL_TEXTURE_BINDING_CUBE_MAP_ARB 0x8514 -#define GL_TEXTURE_CUBE_MAP_POSITIVE_X_ARB 0x8515 -#define GL_TEXTURE_CUBE_MAP_NEGATIVE_X_ARB 0x8516 -#define GL_TEXTURE_CUBE_MAP_POSITIVE_Y_ARB 0x8517 -#define GL_TEXTURE_CUBE_MAP_NEGATIVE_Y_ARB 0x8518 -#define GL_TEXTURE_CUBE_MAP_POSITIVE_Z_ARB 0x8519 -#define GL_TEXTURE_CUBE_MAP_NEGATIVE_Z_ARB 0x851A -#define GL_PROXY_TEXTURE_CUBE_MAP_ARB 0x851B -#define GL_MAX_CUBE_MAP_TEXTURE_SIZE_ARB 0x851C -#endif - -#ifndef GL_ARB_texture_compression -#define GL_COMPRESSED_ALPHA_ARB 0x84E9 -#define GL_COMPRESSED_LUMINANCE_ARB 0x84EA -#define GL_COMPRESSED_LUMINANCE_ALPHA_ARB 0x84EB -#define GL_COMPRESSED_INTENSITY_ARB 0x84EC -#define GL_COMPRESSED_RGB_ARB 0x84ED -#define GL_COMPRESSED_RGBA_ARB 0x84EE -#define GL_TEXTURE_COMPRESSION_HINT_ARB 0x84EF -#define GL_TEXTURE_COMPRESSED_IMAGE_SIZE_ARB 0x86A0 -#define GL_TEXTURE_COMPRESSED_ARB 0x86A1 -#define GL_NUM_COMPRESSED_TEXTURE_FORMATS_ARB 0x86A2 -#define GL_COMPRESSED_TEXTURE_FORMATS_ARB 0x86A3 -#endif - -#ifndef GL_ARB_texture_border_clamp -#define GL_CLAMP_TO_BORDER_ARB 0x812D -#endif - -#ifndef GL_ARB_point_parameters -#define GL_POINT_SIZE_MIN_ARB 0x8126 -#define GL_POINT_SIZE_MAX_ARB 0x8127 -#define GL_POINT_FADE_THRESHOLD_SIZE_ARB 0x8128 -#define GL_POINT_DISTANCE_ATTENUATION_ARB 0x8129 -#endif - -#ifndef GL_ARB_vertex_blend -#define GL_MAX_VERTEX_UNITS_ARB 0x86A4 -#define GL_ACTIVE_VERTEX_UNITS_ARB 0x86A5 -#define GL_WEIGHT_SUM_UNITY_ARB 0x86A6 -#define GL_VERTEX_BLEND_ARB 0x86A7 -#define GL_CURRENT_WEIGHT_ARB 0x86A8 -#define GL_WEIGHT_ARRAY_TYPE_ARB 0x86A9 -#define GL_WEIGHT_ARRAY_STRIDE_ARB 0x86AA -#define GL_WEIGHT_ARRAY_SIZE_ARB 0x86AB -#define GL_WEIGHT_ARRAY_POINTER_ARB 0x86AC -#define GL_WEIGHT_ARRAY_ARB 0x86AD -#define GL_MODELVIEW0_ARB 0x1700 -#define GL_MODELVIEW1_ARB 0x850A -#define GL_MODELVIEW2_ARB 0x8722 -#define GL_MODELVIEW3_ARB 0x8723 -#define GL_MODELVIEW4_ARB 0x8724 -#define GL_MODELVIEW5_ARB 0x8725 -#define GL_MODELVIEW6_ARB 0x8726 -#define GL_MODELVIEW7_ARB 0x8727 -#define GL_MODELVIEW8_ARB 0x8728 -#define GL_MODELVIEW9_ARB 0x8729 -#define GL_MODELVIEW10_ARB 0x872A -#define GL_MODELVIEW11_ARB 0x872B -#define GL_MODELVIEW12_ARB 0x872C -#define GL_MODELVIEW13_ARB 0x872D -#define GL_MODELVIEW14_ARB 0x872E -#define GL_MODELVIEW15_ARB 0x872F -#define GL_MODELVIEW16_ARB 0x8730 -#define GL_MODELVIEW17_ARB 0x8731 -#define GL_MODELVIEW18_ARB 0x8732 -#define GL_MODELVIEW19_ARB 0x8733 -#define GL_MODELVIEW20_ARB 0x8734 -#define GL_MODELVIEW21_ARB 0x8735 -#define GL_MODELVIEW22_ARB 0x8736 -#define GL_MODELVIEW23_ARB 0x8737 -#define GL_MODELVIEW24_ARB 0x8738 -#define GL_MODELVIEW25_ARB 0x8739 -#define GL_MODELVIEW26_ARB 0x873A -#define GL_MODELVIEW27_ARB 0x873B -#define GL_MODELVIEW28_ARB 0x873C -#define GL_MODELVIEW29_ARB 0x873D -#define GL_MODELVIEW30_ARB 0x873E -#define GL_MODELVIEW31_ARB 0x873F -#endif - -#ifndef GL_ARB_matrix_palette -#define GL_MATRIX_PALETTE_ARB 0x8840 -#define GL_MAX_MATRIX_PALETTE_STACK_DEPTH_ARB 0x8841 -#define GL_MAX_PALETTE_MATRICES_ARB 0x8842 -#define GL_CURRENT_PALETTE_MATRIX_ARB 0x8843 -#define GL_MATRIX_INDEX_ARRAY_ARB 0x8844 -#define GL_CURRENT_MATRIX_INDEX_ARB 0x8845 -#define GL_MATRIX_INDEX_ARRAY_SIZE_ARB 0x8846 -#define GL_MATRIX_INDEX_ARRAY_TYPE_ARB 0x8847 -#define GL_MATRIX_INDEX_ARRAY_STRIDE_ARB 0x8848 -#define GL_MATRIX_INDEX_ARRAY_POINTER_ARB 0x8849 -#endif - -#ifndef GL_ARB_texture_env_combine -#define GL_COMBINE_ARB 0x8570 -#define GL_COMBINE_RGB_ARB 0x8571 -#define GL_COMBINE_ALPHA_ARB 0x8572 -#define GL_SOURCE0_RGB_ARB 0x8580 -#define GL_SOURCE1_RGB_ARB 0x8581 -#define GL_SOURCE2_RGB_ARB 0x8582 -#define GL_SOURCE0_ALPHA_ARB 0x8588 -#define GL_SOURCE1_ALPHA_ARB 0x8589 -#define GL_SOURCE2_ALPHA_ARB 0x858A -#define GL_OPERAND0_RGB_ARB 0x8590 -#define GL_OPERAND1_RGB_ARB 0x8591 -#define GL_OPERAND2_RGB_ARB 0x8592 -#define GL_OPERAND0_ALPHA_ARB 0x8598 -#define GL_OPERAND1_ALPHA_ARB 0x8599 -#define GL_OPERAND2_ALPHA_ARB 0x859A -#define GL_RGB_SCALE_ARB 0x8573 -#define GL_ADD_SIGNED_ARB 0x8574 -#define GL_INTERPOLATE_ARB 0x8575 -#define GL_SUBTRACT_ARB 0x84E7 -#define GL_CONSTANT_ARB 0x8576 -#define GL_PRIMARY_COLOR_ARB 0x8577 -#define GL_PREVIOUS_ARB 0x8578 -#endif - -#ifndef GL_ARB_texture_env_crossbar -#endif - -#ifndef GL_ARB_texture_env_dot3 -#define GL_DOT3_RGB_ARB 0x86AE -#define GL_DOT3_RGBA_ARB 0x86AF -#endif - -#ifndef GL_ARB_texture_mirrored_repeat -#define GL_MIRRORED_REPEAT_ARB 0x8370 -#endif - -#ifndef GL_ARB_depth_texture -#define GL_DEPTH_COMPONENT16_ARB 0x81A5 -#define GL_DEPTH_COMPONENT24_ARB 0x81A6 -#define GL_DEPTH_COMPONENT32_ARB 0x81A7 -#define GL_TEXTURE_DEPTH_SIZE_ARB 0x884A -#define GL_DEPTH_TEXTURE_MODE_ARB 0x884B -#endif - -#ifndef GL_ARB_shadow -#define GL_TEXTURE_COMPARE_MODE_ARB 0x884C -#define GL_TEXTURE_COMPARE_FUNC_ARB 0x884D -#define GL_COMPARE_R_TO_TEXTURE_ARB 0x884E -#endif - -#ifndef GL_ARB_shadow_ambient -#define GL_TEXTURE_COMPARE_FAIL_VALUE_ARB 0x80BF -#endif - -#ifndef GL_ARB_window_pos -#endif - -#ifndef GL_ARB_vertex_program -#define GL_COLOR_SUM_ARB 0x8458 -#define GL_VERTEX_PROGRAM_ARB 0x8620 -#define GL_VERTEX_ATTRIB_ARRAY_ENABLED_ARB 0x8622 -#define GL_VERTEX_ATTRIB_ARRAY_SIZE_ARB 0x8623 -#define GL_VERTEX_ATTRIB_ARRAY_STRIDE_ARB 0x8624 -#define GL_VERTEX_ATTRIB_ARRAY_TYPE_ARB 0x8625 -#define GL_CURRENT_VERTEX_ATTRIB_ARB 0x8626 -#define GL_PROGRAM_LENGTH_ARB 0x8627 -#define GL_PROGRAM_STRING_ARB 0x8628 -#define GL_MAX_PROGRAM_MATRIX_STACK_DEPTH_ARB 0x862E -#define GL_MAX_PROGRAM_MATRICES_ARB 0x862F -#define GL_CURRENT_MATRIX_STACK_DEPTH_ARB 0x8640 -#define GL_CURRENT_MATRIX_ARB 0x8641 -#define GL_VERTEX_PROGRAM_POINT_SIZE_ARB 0x8642 -#define GL_VERTEX_PROGRAM_TWO_SIDE_ARB 0x8643 -#define GL_VERTEX_ATTRIB_ARRAY_POINTER_ARB 0x8645 -#define GL_PROGRAM_ERROR_POSITION_ARB 0x864B -#define GL_PROGRAM_BINDING_ARB 0x8677 -#define GL_MAX_VERTEX_ATTRIBS_ARB 0x8869 -#define GL_VERTEX_ATTRIB_ARRAY_NORMALIZED_ARB 0x886A -#define GL_PROGRAM_ERROR_STRING_ARB 0x8874 -#define GL_PROGRAM_FORMAT_ASCII_ARB 0x8875 -#define GL_PROGRAM_FORMAT_ARB 0x8876 -#define GL_PROGRAM_INSTRUCTIONS_ARB 0x88A0 -#define GL_MAX_PROGRAM_INSTRUCTIONS_ARB 0x88A1 -#define GL_PROGRAM_NATIVE_INSTRUCTIONS_ARB 0x88A2 -#define GL_MAX_PROGRAM_NATIVE_INSTRUCTIONS_ARB 0x88A3 -#define GL_PROGRAM_TEMPORARIES_ARB 0x88A4 -#define GL_MAX_PROGRAM_TEMPORARIES_ARB 0x88A5 -#define GL_PROGRAM_NATIVE_TEMPORARIES_ARB 0x88A6 -#define GL_MAX_PROGRAM_NATIVE_TEMPORARIES_ARB 0x88A7 -#define GL_PROGRAM_PARAMETERS_ARB 0x88A8 -#define GL_MAX_PROGRAM_PARAMETERS_ARB 0x88A9 -#define GL_PROGRAM_NATIVE_PARAMETERS_ARB 0x88AA -#define GL_MAX_PROGRAM_NATIVE_PARAMETERS_ARB 0x88AB -#define GL_PROGRAM_ATTRIBS_ARB 0x88AC -#define GL_MAX_PROGRAM_ATTRIBS_ARB 0x88AD -#define GL_PROGRAM_NATIVE_ATTRIBS_ARB 0x88AE -#define GL_MAX_PROGRAM_NATIVE_ATTRIBS_ARB 0x88AF -#define GL_PROGRAM_ADDRESS_REGISTERS_ARB 0x88B0 -#define GL_MAX_PROGRAM_ADDRESS_REGISTERS_ARB 0x88B1 -#define GL_PROGRAM_NATIVE_ADDRESS_REGISTERS_ARB 0x88B2 -#define GL_MAX_PROGRAM_NATIVE_ADDRESS_REGISTERS_ARB 0x88B3 -#define GL_MAX_PROGRAM_LOCAL_PARAMETERS_ARB 0x88B4 -#define GL_MAX_PROGRAM_ENV_PARAMETERS_ARB 0x88B5 -#define GL_PROGRAM_UNDER_NATIVE_LIMITS_ARB 0x88B6 -#define GL_TRANSPOSE_CURRENT_MATRIX_ARB 0x88B7 -#define GL_MATRIX0_ARB 0x88C0 -#define GL_MATRIX1_ARB 0x88C1 -#define GL_MATRIX2_ARB 0x88C2 -#define GL_MATRIX3_ARB 0x88C3 -#define GL_MATRIX4_ARB 0x88C4 -#define GL_MATRIX5_ARB 0x88C5 -#define GL_MATRIX6_ARB 0x88C6 -#define GL_MATRIX7_ARB 0x88C7 -#define GL_MATRIX8_ARB 0x88C8 -#define GL_MATRIX9_ARB 0x88C9 -#define GL_MATRIX10_ARB 0x88CA -#define GL_MATRIX11_ARB 0x88CB -#define GL_MATRIX12_ARB 0x88CC -#define GL_MATRIX13_ARB 0x88CD -#define GL_MATRIX14_ARB 0x88CE -#define GL_MATRIX15_ARB 0x88CF -#define GL_MATRIX16_ARB 0x88D0 -#define GL_MATRIX17_ARB 0x88D1 -#define GL_MATRIX18_ARB 0x88D2 -#define GL_MATRIX19_ARB 0x88D3 -#define GL_MATRIX20_ARB 0x88D4 -#define GL_MATRIX21_ARB 0x88D5 -#define GL_MATRIX22_ARB 0x88D6 -#define GL_MATRIX23_ARB 0x88D7 -#define GL_MATRIX24_ARB 0x88D8 -#define GL_MATRIX25_ARB 0x88D9 -#define GL_MATRIX26_ARB 0x88DA -#define GL_MATRIX27_ARB 0x88DB -#define GL_MATRIX28_ARB 0x88DC -#define GL_MATRIX29_ARB 0x88DD -#define GL_MATRIX30_ARB 0x88DE -#define GL_MATRIX31_ARB 0x88DF -#endif - -#ifndef GL_ARB_fragment_program -#define GL_FRAGMENT_PROGRAM_ARB 0x8804 -#define GL_PROGRAM_ALU_INSTRUCTIONS_ARB 0x8805 -#define GL_PROGRAM_TEX_INSTRUCTIONS_ARB 0x8806 -#define GL_PROGRAM_TEX_INDIRECTIONS_ARB 0x8807 -#define GL_PROGRAM_NATIVE_ALU_INSTRUCTIONS_ARB 0x8808 -#define GL_PROGRAM_NATIVE_TEX_INSTRUCTIONS_ARB 0x8809 -#define GL_PROGRAM_NATIVE_TEX_INDIRECTIONS_ARB 0x880A -#define GL_MAX_PROGRAM_ALU_INSTRUCTIONS_ARB 0x880B -#define GL_MAX_PROGRAM_TEX_INSTRUCTIONS_ARB 0x880C -#define GL_MAX_PROGRAM_TEX_INDIRECTIONS_ARB 0x880D -#define GL_MAX_PROGRAM_NATIVE_ALU_INSTRUCTIONS_ARB 0x880E -#define GL_MAX_PROGRAM_NATIVE_TEX_INSTRUCTIONS_ARB 0x880F -#define GL_MAX_PROGRAM_NATIVE_TEX_INDIRECTIONS_ARB 0x8810 -#define GL_MAX_TEXTURE_COORDS_ARB 0x8871 -#define GL_MAX_TEXTURE_IMAGE_UNITS_ARB 0x8872 -#endif - -#ifndef GL_ARB_vertex_buffer_object -#define GL_BUFFER_SIZE_ARB 0x8764 -#define GL_BUFFER_USAGE_ARB 0x8765 -#define GL_ARRAY_BUFFER_ARB 0x8892 -#define GL_ELEMENT_ARRAY_BUFFER_ARB 0x8893 -#define GL_ARRAY_BUFFER_BINDING_ARB 0x8894 -#define GL_ELEMENT_ARRAY_BUFFER_BINDING_ARB 0x8895 -#define GL_VERTEX_ARRAY_BUFFER_BINDING_ARB 0x8896 -#define GL_NORMAL_ARRAY_BUFFER_BINDING_ARB 0x8897 -#define GL_COLOR_ARRAY_BUFFER_BINDING_ARB 0x8898 -#define GL_INDEX_ARRAY_BUFFER_BINDING_ARB 0x8899 -#define GL_TEXTURE_COORD_ARRAY_BUFFER_BINDING_ARB 0x889A -#define GL_EDGE_FLAG_ARRAY_BUFFER_BINDING_ARB 0x889B -#define GL_SECONDARY_COLOR_ARRAY_BUFFER_BINDING_ARB 0x889C -#define GL_FOG_COORDINATE_ARRAY_BUFFER_BINDING_ARB 0x889D -#define GL_WEIGHT_ARRAY_BUFFER_BINDING_ARB 0x889E -#define GL_VERTEX_ATTRIB_ARRAY_BUFFER_BINDING_ARB 0x889F -#define GL_READ_ONLY_ARB 0x88B8 -#define GL_WRITE_ONLY_ARB 0x88B9 -#define GL_READ_WRITE_ARB 0x88BA -#define GL_BUFFER_ACCESS_ARB 0x88BB -#define GL_BUFFER_MAPPED_ARB 0x88BC -#define GL_BUFFER_MAP_POINTER_ARB 0x88BD -#define GL_STREAM_DRAW_ARB 0x88E0 -#define GL_STREAM_READ_ARB 0x88E1 -#define GL_STREAM_COPY_ARB 0x88E2 -#define GL_STATIC_DRAW_ARB 0x88E4 -#define GL_STATIC_READ_ARB 0x88E5 -#define GL_STATIC_COPY_ARB 0x88E6 -#define GL_DYNAMIC_DRAW_ARB 0x88E8 -#define GL_DYNAMIC_READ_ARB 0x88E9 -#define GL_DYNAMIC_COPY_ARB 0x88EA -#endif - -#ifndef GL_ARB_occlusion_query -#define GL_QUERY_COUNTER_BITS_ARB 0x8864 -#define GL_CURRENT_QUERY_ARB 0x8865 -#define GL_QUERY_RESULT_ARB 0x8866 -#define GL_QUERY_RESULT_AVAILABLE_ARB 0x8867 -#define GL_SAMPLES_PASSED_ARB 0x8914 -#endif - -#ifndef GL_ARB_shader_objects -#define GL_PROGRAM_OBJECT_ARB 0x8B40 -#define GL_SHADER_OBJECT_ARB 0x8B48 -#define GL_OBJECT_TYPE_ARB 0x8B4E -#define GL_OBJECT_SUBTYPE_ARB 0x8B4F -#define GL_FLOAT_VEC2_ARB 0x8B50 -#define GL_FLOAT_VEC3_ARB 0x8B51 -#define GL_FLOAT_VEC4_ARB 0x8B52 -#define GL_INT_VEC2_ARB 0x8B53 -#define GL_INT_VEC3_ARB 0x8B54 -#define GL_INT_VEC4_ARB 0x8B55 -#define GL_BOOL_ARB 0x8B56 -#define GL_BOOL_VEC2_ARB 0x8B57 -#define GL_BOOL_VEC3_ARB 0x8B58 -#define GL_BOOL_VEC4_ARB 0x8B59 -#define GL_FLOAT_MAT2_ARB 0x8B5A -#define GL_FLOAT_MAT3_ARB 0x8B5B -#define GL_FLOAT_MAT4_ARB 0x8B5C -#define GL_SAMPLER_1D_ARB 0x8B5D -#define GL_SAMPLER_2D_ARB 0x8B5E -#define GL_SAMPLER_3D_ARB 0x8B5F -#define GL_SAMPLER_CUBE_ARB 0x8B60 -#define GL_SAMPLER_1D_SHADOW_ARB 0x8B61 -#define GL_SAMPLER_2D_SHADOW_ARB 0x8B62 -#define GL_SAMPLER_2D_RECT_ARB 0x8B63 -#define GL_SAMPLER_2D_RECT_SHADOW_ARB 0x8B64 -#define GL_OBJECT_DELETE_STATUS_ARB 0x8B80 -#define GL_OBJECT_COMPILE_STATUS_ARB 0x8B81 -#define GL_OBJECT_LINK_STATUS_ARB 0x8B82 -#define GL_OBJECT_VALIDATE_STATUS_ARB 0x8B83 -#define GL_OBJECT_INFO_LOG_LENGTH_ARB 0x8B84 -#define GL_OBJECT_ATTACHED_OBJECTS_ARB 0x8B85 -#define GL_OBJECT_ACTIVE_UNIFORMS_ARB 0x8B86 -#define GL_OBJECT_ACTIVE_UNIFORM_MAX_LENGTH_ARB 0x8B87 -#define GL_OBJECT_SHADER_SOURCE_LENGTH_ARB 0x8B88 -#endif - -#ifndef GL_ARB_vertex_shader -#define GL_VERTEX_SHADER_ARB 0x8B31 -#define GL_MAX_VERTEX_UNIFORM_COMPONENTS_ARB 0x8B4A -#define GL_MAX_VARYING_FLOATS_ARB 0x8B4B -#define GL_MAX_VERTEX_TEXTURE_IMAGE_UNITS_ARB 0x8B4C -#define GL_MAX_COMBINED_TEXTURE_IMAGE_UNITS_ARB 0x8B4D -#define GL_OBJECT_ACTIVE_ATTRIBUTES_ARB 0x8B89 -#define GL_OBJECT_ACTIVE_ATTRIBUTE_MAX_LENGTH_ARB 0x8B8A -#endif - -#ifndef GL_ARB_fragment_shader -#define GL_FRAGMENT_SHADER_ARB 0x8B30 -#define GL_MAX_FRAGMENT_UNIFORM_COMPONENTS_ARB 0x8B49 -#define GL_FRAGMENT_SHADER_DERIVATIVE_HINT_ARB 0x8B8B -#endif - -#ifndef GL_ARB_shading_language_100 -#define GL_SHADING_LANGUAGE_VERSION_ARB 0x8B8C -#endif - -#ifndef GL_ARB_texture_non_power_of_two -#endif - -#ifndef GL_ARB_point_sprite -#define GL_POINT_SPRITE_ARB 0x8861 -#define GL_COORD_REPLACE_ARB 0x8862 -#endif - -#ifndef GL_ARB_fragment_program_shadow -#endif - -#ifndef GL_ARB_draw_buffers -#define GL_MAX_DRAW_BUFFERS_ARB 0x8824 -#define GL_DRAW_BUFFER0_ARB 0x8825 -#define GL_DRAW_BUFFER1_ARB 0x8826 -#define GL_DRAW_BUFFER2_ARB 0x8827 -#define GL_DRAW_BUFFER3_ARB 0x8828 -#define GL_DRAW_BUFFER4_ARB 0x8829 -#define GL_DRAW_BUFFER5_ARB 0x882A -#define GL_DRAW_BUFFER6_ARB 0x882B -#define GL_DRAW_BUFFER7_ARB 0x882C -#define GL_DRAW_BUFFER8_ARB 0x882D -#define GL_DRAW_BUFFER9_ARB 0x882E -#define GL_DRAW_BUFFER10_ARB 0x882F -#define GL_DRAW_BUFFER11_ARB 0x8830 -#define GL_DRAW_BUFFER12_ARB 0x8831 -#define GL_DRAW_BUFFER13_ARB 0x8832 -#define GL_DRAW_BUFFER14_ARB 0x8833 -#define GL_DRAW_BUFFER15_ARB 0x8834 -#endif - -#ifndef GL_ARB_texture_rectangle -#define GL_TEXTURE_RECTANGLE_ARB 0x84F5 -#define GL_TEXTURE_BINDING_RECTANGLE_ARB 0x84F6 -#define GL_PROXY_TEXTURE_RECTANGLE_ARB 0x84F7 -#define GL_MAX_RECTANGLE_TEXTURE_SIZE_ARB 0x84F8 -#endif - -#ifndef GL_ARB_color_buffer_float -#define GL_RGBA_FLOAT_MODE_ARB 0x8820 -#define GL_CLAMP_VERTEX_COLOR_ARB 0x891A -#define GL_CLAMP_FRAGMENT_COLOR_ARB 0x891B -#define GL_CLAMP_READ_COLOR_ARB 0x891C -#define GL_FIXED_ONLY_ARB 0x891D -#endif - -#ifndef GL_ARB_half_float_pixel -#define GL_HALF_FLOAT_ARB 0x140B -#endif - -#ifndef GL_ARB_texture_float -#define GL_TEXTURE_RED_TYPE_ARB 0x8C10 -#define GL_TEXTURE_GREEN_TYPE_ARB 0x8C11 -#define GL_TEXTURE_BLUE_TYPE_ARB 0x8C12 -#define GL_TEXTURE_ALPHA_TYPE_ARB 0x8C13 -#define GL_TEXTURE_LUMINANCE_TYPE_ARB 0x8C14 -#define GL_TEXTURE_INTENSITY_TYPE_ARB 0x8C15 -#define GL_TEXTURE_DEPTH_TYPE_ARB 0x8C16 -#define GL_UNSIGNED_NORMALIZED_ARB 0x8C17 -#define GL_RGBA32F_ARB 0x8814 -#define GL_RGB32F_ARB 0x8815 -#define GL_ALPHA32F_ARB 0x8816 -#define GL_INTENSITY32F_ARB 0x8817 -#define GL_LUMINANCE32F_ARB 0x8818 -#define GL_LUMINANCE_ALPHA32F_ARB 0x8819 -#define GL_RGBA16F_ARB 0x881A -#define GL_RGB16F_ARB 0x881B -#define GL_ALPHA16F_ARB 0x881C -#define GL_INTENSITY16F_ARB 0x881D -#define GL_LUMINANCE16F_ARB 0x881E -#define GL_LUMINANCE_ALPHA16F_ARB 0x881F -#endif - -#ifndef GL_ARB_pixel_buffer_object -#define GL_PIXEL_PACK_BUFFER_ARB 0x88EB -#define GL_PIXEL_UNPACK_BUFFER_ARB 0x88EC -#define GL_PIXEL_PACK_BUFFER_BINDING_ARB 0x88ED -#define GL_PIXEL_UNPACK_BUFFER_BINDING_ARB 0x88EF -#endif - -#ifndef GL_ARB_depth_buffer_float -#define GL_DEPTH_COMPONENT32F 0x8CAC -#define GL_DEPTH32F_STENCIL8 0x8CAD -#define GL_FLOAT_32_UNSIGNED_INT_24_8_REV 0x8DAD -#endif - -#ifndef GL_ARB_draw_instanced -#endif - -#ifndef GL_ARB_framebuffer_object -#define GL_INVALID_FRAMEBUFFER_OPERATION 0x0506 -#define GL_FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING 0x8210 -#define GL_FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE 0x8211 -#define GL_FRAMEBUFFER_ATTACHMENT_RED_SIZE 0x8212 -#define GL_FRAMEBUFFER_ATTACHMENT_GREEN_SIZE 0x8213 -#define GL_FRAMEBUFFER_ATTACHMENT_BLUE_SIZE 0x8214 -#define GL_FRAMEBUFFER_ATTACHMENT_ALPHA_SIZE 0x8215 -#define GL_FRAMEBUFFER_ATTACHMENT_DEPTH_SIZE 0x8216 -#define GL_FRAMEBUFFER_ATTACHMENT_STENCIL_SIZE 0x8217 -#define GL_FRAMEBUFFER_DEFAULT 0x8218 -#define GL_FRAMEBUFFER_UNDEFINED 0x8219 -#define GL_DEPTH_STENCIL_ATTACHMENT 0x821A -#define GL_INDEX 0x8222 -#define GL_MAX_RENDERBUFFER_SIZE 0x84E8 -#define GL_DEPTH_STENCIL 0x84F9 -#define GL_UNSIGNED_INT_24_8 0x84FA -#define GL_DEPTH24_STENCIL8 0x88F0 -#define GL_TEXTURE_STENCIL_SIZE 0x88F1 -#define GL_FRAMEBUFFER_BINDING 0x8CA6 -#define GL_DRAW_FRAMEBUFFER_BINDING GL_FRAMEBUFFER_BINDING -#define GL_RENDERBUFFER_BINDING 0x8CA7 -#define GL_READ_FRAMEBUFFER 0x8CA8 -#define GL_DRAW_FRAMEBUFFER 0x8CA9 -#define GL_READ_FRAMEBUFFER_BINDING 0x8CAA -#define GL_RENDERBUFFER_SAMPLES 0x8CAB -#define GL_FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE 0x8CD0 -#define GL_FRAMEBUFFER_ATTACHMENT_OBJECT_NAME 0x8CD1 -#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL 0x8CD2 -#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE 0x8CD3 -#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER 0x8CD4 -#define GL_FRAMEBUFFER_COMPLETE 0x8CD5 -#define GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT 0x8CD6 -#define GL_FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT 0x8CD7 -#define GL_FRAMEBUFFER_INCOMPLETE_DRAW_BUFFER 0x8CDB -#define GL_FRAMEBUFFER_INCOMPLETE_READ_BUFFER 0x8CDC -#define GL_FRAMEBUFFER_UNSUPPORTED 0x8CDD -#define GL_MAX_COLOR_ATTACHMENTS 0x8CDF -#define GL_COLOR_ATTACHMENT0 0x8CE0 -#define GL_COLOR_ATTACHMENT1 0x8CE1 -#define GL_COLOR_ATTACHMENT2 0x8CE2 -#define GL_COLOR_ATTACHMENT3 0x8CE3 -#define GL_COLOR_ATTACHMENT4 0x8CE4 -#define GL_COLOR_ATTACHMENT5 0x8CE5 -#define GL_COLOR_ATTACHMENT6 0x8CE6 -#define GL_COLOR_ATTACHMENT7 0x8CE7 -#define GL_COLOR_ATTACHMENT8 0x8CE8 -#define GL_COLOR_ATTACHMENT9 0x8CE9 -#define GL_COLOR_ATTACHMENT10 0x8CEA -#define GL_COLOR_ATTACHMENT11 0x8CEB -#define GL_COLOR_ATTACHMENT12 0x8CEC -#define GL_COLOR_ATTACHMENT13 0x8CED -#define GL_COLOR_ATTACHMENT14 0x8CEE -#define GL_COLOR_ATTACHMENT15 0x8CEF -#define GL_DEPTH_ATTACHMENT 0x8D00 -#define GL_STENCIL_ATTACHMENT 0x8D20 -#define GL_FRAMEBUFFER 0x8D40 -#define GL_RENDERBUFFER 0x8D41 -#define GL_RENDERBUFFER_WIDTH 0x8D42 -#define GL_RENDERBUFFER_HEIGHT 0x8D43 -#define GL_RENDERBUFFER_INTERNAL_FORMAT 0x8D44 -#define GL_STENCIL_INDEX1 0x8D46 -#define GL_STENCIL_INDEX4 0x8D47 -#define GL_STENCIL_INDEX8 0x8D48 -#define GL_STENCIL_INDEX16 0x8D49 -#define GL_RENDERBUFFER_RED_SIZE 0x8D50 -#define GL_RENDERBUFFER_GREEN_SIZE 0x8D51 -#define GL_RENDERBUFFER_BLUE_SIZE 0x8D52 -#define GL_RENDERBUFFER_ALPHA_SIZE 0x8D53 -#define GL_RENDERBUFFER_DEPTH_SIZE 0x8D54 -#define GL_RENDERBUFFER_STENCIL_SIZE 0x8D55 -#define GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE 0x8D56 -#define GL_MAX_SAMPLES 0x8D57 -#endif - -#ifndef GL_ARB_framebuffer_sRGB -#define GL_FRAMEBUFFER_SRGB 0x8DB9 -#endif - -#ifndef GL_ARB_geometry_shader4 -#define GL_LINES_ADJACENCY_ARB 0x000A -#define GL_LINE_STRIP_ADJACENCY_ARB 0x000B -#define GL_TRIANGLES_ADJACENCY_ARB 0x000C -#define GL_TRIANGLE_STRIP_ADJACENCY_ARB 0x000D -#define GL_PROGRAM_POINT_SIZE_ARB 0x8642 -#define GL_MAX_GEOMETRY_TEXTURE_IMAGE_UNITS_ARB 0x8C29 -#define GL_FRAMEBUFFER_ATTACHMENT_LAYERED_ARB 0x8DA7 -#define GL_FRAMEBUFFER_INCOMPLETE_LAYER_TARGETS_ARB 0x8DA8 -#define GL_FRAMEBUFFER_INCOMPLETE_LAYER_COUNT_ARB 0x8DA9 -#define GL_GEOMETRY_SHADER_ARB 0x8DD9 -#define GL_GEOMETRY_VERTICES_OUT_ARB 0x8DDA -#define GL_GEOMETRY_INPUT_TYPE_ARB 0x8DDB -#define GL_GEOMETRY_OUTPUT_TYPE_ARB 0x8DDC -#define GL_MAX_GEOMETRY_VARYING_COMPONENTS_ARB 0x8DDD -#define GL_MAX_VERTEX_VARYING_COMPONENTS_ARB 0x8DDE -#define GL_MAX_GEOMETRY_UNIFORM_COMPONENTS_ARB 0x8DDF -#define GL_MAX_GEOMETRY_OUTPUT_VERTICES_ARB 0x8DE0 -#define GL_MAX_GEOMETRY_TOTAL_OUTPUT_COMPONENTS_ARB 0x8DE1 -/* reuse GL_MAX_VARYING_COMPONENTS */ -/* reuse GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER */ -#endif - -#ifndef GL_ARB_half_float_vertex -#define GL_HALF_FLOAT 0x140B -#endif - -#ifndef GL_ARB_instanced_arrays -#endif - -#ifndef GL_ARB_map_buffer_range -#define GL_MAP_READ_BIT 0x0001 -#define GL_MAP_WRITE_BIT 0x0002 -#define GL_MAP_INVALIDATE_RANGE_BIT 0x0004 -#define GL_MAP_INVALIDATE_BUFFER_BIT 0x0008 -#define GL_MAP_FLUSH_EXPLICIT_BIT 0x0010 -#define GL_MAP_UNSYNCHRONIZED_BIT 0x0020 -#endif - -#ifndef GL_ARB_texture_buffer_object -#define GL_TEXTURE_BUFFER_ARB 0x8C2A -#define GL_MAX_TEXTURE_BUFFER_SIZE_ARB 0x8C2B -#define GL_TEXTURE_BINDING_BUFFER_ARB 0x8C2C -#define GL_TEXTURE_BUFFER_DATA_STORE_BINDING_ARB 0x8C2D -#define GL_TEXTURE_BUFFER_FORMAT_ARB 0x8C2E -#endif - -#ifndef GL_ARB_texture_compression_rgtc -#define GL_COMPRESSED_RED_RGTC1 0x8DBB -#define GL_COMPRESSED_SIGNED_RED_RGTC1 0x8DBC -#define GL_COMPRESSED_RG_RGTC2 0x8DBD -#define GL_COMPRESSED_SIGNED_RG_RGTC2 0x8DBE -#endif - -#ifndef GL_ARB_texture_rg -#define GL_RG 0x8227 -#define GL_RG_INTEGER 0x8228 -#define GL_R8 0x8229 -#define GL_R16 0x822A -#define GL_RG8 0x822B -#define GL_RG16 0x822C -#define GL_R16F 0x822D -#define GL_R32F 0x822E -#define GL_RG16F 0x822F -#define GL_RG32F 0x8230 -#define GL_R8I 0x8231 -#define GL_R8UI 0x8232 -#define GL_R16I 0x8233 -#define GL_R16UI 0x8234 -#define GL_R32I 0x8235 -#define GL_R32UI 0x8236 -#define GL_RG8I 0x8237 -#define GL_RG8UI 0x8238 -#define GL_RG16I 0x8239 -#define GL_RG16UI 0x823A -#define GL_RG32I 0x823B -#define GL_RG32UI 0x823C -#endif - -#ifndef GL_ARB_vertex_array_object -#define GL_VERTEX_ARRAY_BINDING 0x85B5 -#endif - -#ifndef GL_EXT_abgr -#define GL_ABGR_EXT 0x8000 -#endif - -#ifndef GL_EXT_blend_color -#define GL_CONSTANT_COLOR_EXT 0x8001 -#define GL_ONE_MINUS_CONSTANT_COLOR_EXT 0x8002 -#define GL_CONSTANT_ALPHA_EXT 0x8003 -#define GL_ONE_MINUS_CONSTANT_ALPHA_EXT 0x8004 -#define GL_BLEND_COLOR_EXT 0x8005 -#endif - -#ifndef GL_EXT_polygon_offset -#define GL_POLYGON_OFFSET_EXT 0x8037 -#define GL_POLYGON_OFFSET_FACTOR_EXT 0x8038 -#define GL_POLYGON_OFFSET_BIAS_EXT 0x8039 -#endif - -#ifndef GL_EXT_texture -#define GL_ALPHA4_EXT 0x803B -#define GL_ALPHA8_EXT 0x803C -#define GL_ALPHA12_EXT 0x803D -#define GL_ALPHA16_EXT 0x803E -#define GL_LUMINANCE4_EXT 0x803F -#define GL_LUMINANCE8_EXT 0x8040 -#define GL_LUMINANCE12_EXT 0x8041 -#define GL_LUMINANCE16_EXT 0x8042 -#define GL_LUMINANCE4_ALPHA4_EXT 0x8043 -#define GL_LUMINANCE6_ALPHA2_EXT 0x8044 -#define GL_LUMINANCE8_ALPHA8_EXT 0x8045 -#define GL_LUMINANCE12_ALPHA4_EXT 0x8046 -#define GL_LUMINANCE12_ALPHA12_EXT 0x8047 -#define GL_LUMINANCE16_ALPHA16_EXT 0x8048 -#define GL_INTENSITY_EXT 0x8049 -#define GL_INTENSITY4_EXT 0x804A -#define GL_INTENSITY8_EXT 0x804B -#define GL_INTENSITY12_EXT 0x804C -#define GL_INTENSITY16_EXT 0x804D -#define GL_RGB2_EXT 0x804E -#define GL_RGB4_EXT 0x804F -#define GL_RGB5_EXT 0x8050 -#define GL_RGB8_EXT 0x8051 -#define GL_RGB10_EXT 0x8052 -#define GL_RGB12_EXT 0x8053 -#define GL_RGB16_EXT 0x8054 -#define GL_RGBA2_EXT 0x8055 -#define GL_RGBA4_EXT 0x8056 -#define GL_RGB5_A1_EXT 0x8057 -#define GL_RGBA8_EXT 0x8058 -#define GL_RGB10_A2_EXT 0x8059 -#define GL_RGBA12_EXT 0x805A -#define GL_RGBA16_EXT 0x805B -#define GL_TEXTURE_RED_SIZE_EXT 0x805C -#define GL_TEXTURE_GREEN_SIZE_EXT 0x805D -#define GL_TEXTURE_BLUE_SIZE_EXT 0x805E -#define GL_TEXTURE_ALPHA_SIZE_EXT 0x805F -#define GL_TEXTURE_LUMINANCE_SIZE_EXT 0x8060 -#define GL_TEXTURE_INTENSITY_SIZE_EXT 0x8061 -#define GL_REPLACE_EXT 0x8062 -#define GL_PROXY_TEXTURE_1D_EXT 0x8063 -#define GL_PROXY_TEXTURE_2D_EXT 0x8064 -#define GL_TEXTURE_TOO_LARGE_EXT 0x8065 -#endif - -#ifndef GL_EXT_texture3D -#define GL_PACK_SKIP_IMAGES_EXT 0x806B -#define GL_PACK_IMAGE_HEIGHT_EXT 0x806C -#define GL_UNPACK_SKIP_IMAGES_EXT 0x806D -#define GL_UNPACK_IMAGE_HEIGHT_EXT 0x806E -#define GL_TEXTURE_3D_EXT 0x806F -#define GL_PROXY_TEXTURE_3D_EXT 0x8070 -#define GL_TEXTURE_DEPTH_EXT 0x8071 -#define GL_TEXTURE_WRAP_R_EXT 0x8072 -#define GL_MAX_3D_TEXTURE_SIZE_EXT 0x8073 -#endif - -#ifndef GL_SGIS_texture_filter4 -#define GL_FILTER4_SGIS 0x8146 -#define GL_TEXTURE_FILTER4_SIZE_SGIS 0x8147 -#endif - -#ifndef GL_EXT_subtexture -#endif - -#ifndef GL_EXT_copy_texture -#endif - -#ifndef GL_EXT_histogram -#define GL_HISTOGRAM_EXT 0x8024 -#define GL_PROXY_HISTOGRAM_EXT 0x8025 -#define GL_HISTOGRAM_WIDTH_EXT 0x8026 -#define GL_HISTOGRAM_FORMAT_EXT 0x8027 -#define GL_HISTOGRAM_RED_SIZE_EXT 0x8028 -#define GL_HISTOGRAM_GREEN_SIZE_EXT 0x8029 -#define GL_HISTOGRAM_BLUE_SIZE_EXT 0x802A -#define GL_HISTOGRAM_ALPHA_SIZE_EXT 0x802B -#define GL_HISTOGRAM_LUMINANCE_SIZE_EXT 0x802C -#define GL_HISTOGRAM_SINK_EXT 0x802D -#define GL_MINMAX_EXT 0x802E -#define GL_MINMAX_FORMAT_EXT 0x802F -#define GL_MINMAX_SINK_EXT 0x8030 -#define GL_TABLE_TOO_LARGE_EXT 0x8031 -#endif - -#ifndef GL_EXT_convolution -#define GL_CONVOLUTION_1D_EXT 0x8010 -#define GL_CONVOLUTION_2D_EXT 0x8011 -#define GL_SEPARABLE_2D_EXT 0x8012 -#define GL_CONVOLUTION_BORDER_MODE_EXT 0x8013 -#define GL_CONVOLUTION_FILTER_SCALE_EXT 0x8014 -#define GL_CONVOLUTION_FILTER_BIAS_EXT 0x8015 -#define GL_REDUCE_EXT 0x8016 -#define GL_CONVOLUTION_FORMAT_EXT 0x8017 -#define GL_CONVOLUTION_WIDTH_EXT 0x8018 -#define GL_CONVOLUTION_HEIGHT_EXT 0x8019 -#define GL_MAX_CONVOLUTION_WIDTH_EXT 0x801A -#define GL_MAX_CONVOLUTION_HEIGHT_EXT 0x801B -#define GL_POST_CONVOLUTION_RED_SCALE_EXT 0x801C -#define GL_POST_CONVOLUTION_GREEN_SCALE_EXT 0x801D -#define GL_POST_CONVOLUTION_BLUE_SCALE_EXT 0x801E -#define GL_POST_CONVOLUTION_ALPHA_SCALE_EXT 0x801F -#define GL_POST_CONVOLUTION_RED_BIAS_EXT 0x8020 -#define GL_POST_CONVOLUTION_GREEN_BIAS_EXT 0x8021 -#define GL_POST_CONVOLUTION_BLUE_BIAS_EXT 0x8022 -#define GL_POST_CONVOLUTION_ALPHA_BIAS_EXT 0x8023 -#endif - -#ifndef GL_SGI_color_matrix -#define GL_COLOR_MATRIX_SGI 0x80B1 -#define GL_COLOR_MATRIX_STACK_DEPTH_SGI 0x80B2 -#define GL_MAX_COLOR_MATRIX_STACK_DEPTH_SGI 0x80B3 -#define GL_POST_COLOR_MATRIX_RED_SCALE_SGI 0x80B4 -#define GL_POST_COLOR_MATRIX_GREEN_SCALE_SGI 0x80B5 -#define GL_POST_COLOR_MATRIX_BLUE_SCALE_SGI 0x80B6 -#define GL_POST_COLOR_MATRIX_ALPHA_SCALE_SGI 0x80B7 -#define GL_POST_COLOR_MATRIX_RED_BIAS_SGI 0x80B8 -#define GL_POST_COLOR_MATRIX_GREEN_BIAS_SGI 0x80B9 -#define GL_POST_COLOR_MATRIX_BLUE_BIAS_SGI 0x80BA -#define GL_POST_COLOR_MATRIX_ALPHA_BIAS_SGI 0x80BB -#endif - -#ifndef GL_SGI_color_table -#define GL_COLOR_TABLE_SGI 0x80D0 -#define GL_POST_CONVOLUTION_COLOR_TABLE_SGI 0x80D1 -#define GL_POST_COLOR_MATRIX_COLOR_TABLE_SGI 0x80D2 -#define GL_PROXY_COLOR_TABLE_SGI 0x80D3 -#define GL_PROXY_POST_CONVOLUTION_COLOR_TABLE_SGI 0x80D4 -#define GL_PROXY_POST_COLOR_MATRIX_COLOR_TABLE_SGI 0x80D5 -#define GL_COLOR_TABLE_SCALE_SGI 0x80D6 -#define GL_COLOR_TABLE_BIAS_SGI 0x80D7 -#define GL_COLOR_TABLE_FORMAT_SGI 0x80D8 -#define GL_COLOR_TABLE_WIDTH_SGI 0x80D9 -#define GL_COLOR_TABLE_RED_SIZE_SGI 0x80DA -#define GL_COLOR_TABLE_GREEN_SIZE_SGI 0x80DB -#define GL_COLOR_TABLE_BLUE_SIZE_SGI 0x80DC -#define GL_COLOR_TABLE_ALPHA_SIZE_SGI 0x80DD -#define GL_COLOR_TABLE_LUMINANCE_SIZE_SGI 0x80DE -#define GL_COLOR_TABLE_INTENSITY_SIZE_SGI 0x80DF -#endif - -#ifndef GL_SGIS_pixel_texture -#define GL_PIXEL_TEXTURE_SGIS 0x8353 -#define GL_PIXEL_FRAGMENT_RGB_SOURCE_SGIS 0x8354 -#define GL_PIXEL_FRAGMENT_ALPHA_SOURCE_SGIS 0x8355 -#define GL_PIXEL_GROUP_COLOR_SGIS 0x8356 -#endif - -#ifndef GL_SGIX_pixel_texture -#define GL_PIXEL_TEX_GEN_SGIX 0x8139 -#define GL_PIXEL_TEX_GEN_MODE_SGIX 0x832B -#endif - -#ifndef GL_SGIS_texture4D -#define GL_PACK_SKIP_VOLUMES_SGIS 0x8130 -#define GL_PACK_IMAGE_DEPTH_SGIS 0x8131 -#define GL_UNPACK_SKIP_VOLUMES_SGIS 0x8132 -#define GL_UNPACK_IMAGE_DEPTH_SGIS 0x8133 -#define GL_TEXTURE_4D_SGIS 0x8134 -#define GL_PROXY_TEXTURE_4D_SGIS 0x8135 -#define GL_TEXTURE_4DSIZE_SGIS 0x8136 -#define GL_TEXTURE_WRAP_Q_SGIS 0x8137 -#define GL_MAX_4D_TEXTURE_SIZE_SGIS 0x8138 -#define GL_TEXTURE_4D_BINDING_SGIS 0x814F -#endif - -#ifndef GL_SGI_texture_color_table -#define GL_TEXTURE_COLOR_TABLE_SGI 0x80BC -#define GL_PROXY_TEXTURE_COLOR_TABLE_SGI 0x80BD -#endif - -#ifndef GL_EXT_cmyka -#define GL_CMYK_EXT 0x800C -#define GL_CMYKA_EXT 0x800D -#define GL_PACK_CMYK_HINT_EXT 0x800E -#define GL_UNPACK_CMYK_HINT_EXT 0x800F -#endif - -#ifndef GL_EXT_texture_object -#define GL_TEXTURE_PRIORITY_EXT 0x8066 -#define GL_TEXTURE_RESIDENT_EXT 0x8067 -#define GL_TEXTURE_1D_BINDING_EXT 0x8068 -#define GL_TEXTURE_2D_BINDING_EXT 0x8069 -#define GL_TEXTURE_3D_BINDING_EXT 0x806A -#endif - -#ifndef GL_SGIS_detail_texture -#define GL_DETAIL_TEXTURE_2D_SGIS 0x8095 -#define GL_DETAIL_TEXTURE_2D_BINDING_SGIS 0x8096 -#define GL_LINEAR_DETAIL_SGIS 0x8097 -#define GL_LINEAR_DETAIL_ALPHA_SGIS 0x8098 -#define GL_LINEAR_DETAIL_COLOR_SGIS 0x8099 -#define GL_DETAIL_TEXTURE_LEVEL_SGIS 0x809A -#define GL_DETAIL_TEXTURE_MODE_SGIS 0x809B -#define GL_DETAIL_TEXTURE_FUNC_POINTS_SGIS 0x809C -#endif - -#ifndef GL_SGIS_sharpen_texture -#define GL_LINEAR_SHARPEN_SGIS 0x80AD -#define GL_LINEAR_SHARPEN_ALPHA_SGIS 0x80AE -#define GL_LINEAR_SHARPEN_COLOR_SGIS 0x80AF -#define GL_SHARPEN_TEXTURE_FUNC_POINTS_SGIS 0x80B0 -#endif - -#ifndef GL_EXT_packed_pixels -#define GL_UNSIGNED_BYTE_3_3_2_EXT 0x8032 -#define GL_UNSIGNED_SHORT_4_4_4_4_EXT 0x8033 -#define GL_UNSIGNED_SHORT_5_5_5_1_EXT 0x8034 -#define GL_UNSIGNED_INT_8_8_8_8_EXT 0x8035 -#define GL_UNSIGNED_INT_10_10_10_2_EXT 0x8036 -#endif - -#ifndef GL_SGIS_texture_lod -#define GL_TEXTURE_MIN_LOD_SGIS 0x813A -#define GL_TEXTURE_MAX_LOD_SGIS 0x813B -#define GL_TEXTURE_BASE_LEVEL_SGIS 0x813C -#define GL_TEXTURE_MAX_LEVEL_SGIS 0x813D -#endif - -#ifndef GL_SGIS_multisample -#define GL_MULTISAMPLE_SGIS 0x809D -#define GL_SAMPLE_ALPHA_TO_MASK_SGIS 0x809E -#define GL_SAMPLE_ALPHA_TO_ONE_SGIS 0x809F -#define GL_SAMPLE_MASK_SGIS 0x80A0 -#define GL_1PASS_SGIS 0x80A1 -#define GL_2PASS_0_SGIS 0x80A2 -#define GL_2PASS_1_SGIS 0x80A3 -#define GL_4PASS_0_SGIS 0x80A4 -#define GL_4PASS_1_SGIS 0x80A5 -#define GL_4PASS_2_SGIS 0x80A6 -#define GL_4PASS_3_SGIS 0x80A7 -#define GL_SAMPLE_BUFFERS_SGIS 0x80A8 -#define GL_SAMPLES_SGIS 0x80A9 -#define GL_SAMPLE_MASK_VALUE_SGIS 0x80AA -#define GL_SAMPLE_MASK_INVERT_SGIS 0x80AB -#define GL_SAMPLE_PATTERN_SGIS 0x80AC -#endif - -#ifndef GL_EXT_rescale_normal -#define GL_RESCALE_NORMAL_EXT 0x803A -#endif - -#ifndef GL_EXT_vertex_array -#define GL_VERTEX_ARRAY_EXT 0x8074 -#define GL_NORMAL_ARRAY_EXT 0x8075 -#define GL_COLOR_ARRAY_EXT 0x8076 -#define GL_INDEX_ARRAY_EXT 0x8077 -#define GL_TEXTURE_COORD_ARRAY_EXT 0x8078 -#define GL_EDGE_FLAG_ARRAY_EXT 0x8079 -#define GL_VERTEX_ARRAY_SIZE_EXT 0x807A -#define GL_VERTEX_ARRAY_TYPE_EXT 0x807B -#define GL_VERTEX_ARRAY_STRIDE_EXT 0x807C -#define GL_VERTEX_ARRAY_COUNT_EXT 0x807D -#define GL_NORMAL_ARRAY_TYPE_EXT 0x807E -#define GL_NORMAL_ARRAY_STRIDE_EXT 0x807F -#define GL_NORMAL_ARRAY_COUNT_EXT 0x8080 -#define GL_COLOR_ARRAY_SIZE_EXT 0x8081 -#define GL_COLOR_ARRAY_TYPE_EXT 0x8082 -#define GL_COLOR_ARRAY_STRIDE_EXT 0x8083 -#define GL_COLOR_ARRAY_COUNT_EXT 0x8084 -#define GL_INDEX_ARRAY_TYPE_EXT 0x8085 -#define GL_INDEX_ARRAY_STRIDE_EXT 0x8086 -#define GL_INDEX_ARRAY_COUNT_EXT 0x8087 -#define GL_TEXTURE_COORD_ARRAY_SIZE_EXT 0x8088 -#define GL_TEXTURE_COORD_ARRAY_TYPE_EXT 0x8089 -#define GL_TEXTURE_COORD_ARRAY_STRIDE_EXT 0x808A -#define GL_TEXTURE_COORD_ARRAY_COUNT_EXT 0x808B -#define GL_EDGE_FLAG_ARRAY_STRIDE_EXT 0x808C -#define GL_EDGE_FLAG_ARRAY_COUNT_EXT 0x808D -#define GL_VERTEX_ARRAY_POINTER_EXT 0x808E -#define GL_NORMAL_ARRAY_POINTER_EXT 0x808F -#define GL_COLOR_ARRAY_POINTER_EXT 0x8090 -#define GL_INDEX_ARRAY_POINTER_EXT 0x8091 -#define GL_TEXTURE_COORD_ARRAY_POINTER_EXT 0x8092 -#define GL_EDGE_FLAG_ARRAY_POINTER_EXT 0x8093 -#endif - -#ifndef GL_EXT_misc_attribute -#endif - -#ifndef GL_SGIS_generate_mipmap -#define GL_GENERATE_MIPMAP_SGIS 0x8191 -#define GL_GENERATE_MIPMAP_HINT_SGIS 0x8192 -#endif - -#ifndef GL_SGIX_clipmap -#define GL_LINEAR_CLIPMAP_LINEAR_SGIX 0x8170 -#define GL_TEXTURE_CLIPMAP_CENTER_SGIX 0x8171 -#define GL_TEXTURE_CLIPMAP_FRAME_SGIX 0x8172 -#define GL_TEXTURE_CLIPMAP_OFFSET_SGIX 0x8173 -#define GL_TEXTURE_CLIPMAP_VIRTUAL_DEPTH_SGIX 0x8174 -#define GL_TEXTURE_CLIPMAP_LOD_OFFSET_SGIX 0x8175 -#define GL_TEXTURE_CLIPMAP_DEPTH_SGIX 0x8176 -#define GL_MAX_CLIPMAP_DEPTH_SGIX 0x8177 -#define GL_MAX_CLIPMAP_VIRTUAL_DEPTH_SGIX 0x8178 -#define GL_NEAREST_CLIPMAP_NEAREST_SGIX 0x844D -#define GL_NEAREST_CLIPMAP_LINEAR_SGIX 0x844E -#define GL_LINEAR_CLIPMAP_NEAREST_SGIX 0x844F -#endif - -#ifndef GL_SGIX_shadow -#define GL_TEXTURE_COMPARE_SGIX 0x819A -#define GL_TEXTURE_COMPARE_OPERATOR_SGIX 0x819B -#define GL_TEXTURE_LEQUAL_R_SGIX 0x819C -#define GL_TEXTURE_GEQUAL_R_SGIX 0x819D -#endif - -#ifndef GL_SGIS_texture_edge_clamp -#define GL_CLAMP_TO_EDGE_SGIS 0x812F -#endif - -#ifndef GL_SGIS_texture_border_clamp -#define GL_CLAMP_TO_BORDER_SGIS 0x812D -#endif - -#ifndef GL_EXT_blend_minmax -#define GL_FUNC_ADD_EXT 0x8006 -#define GL_MIN_EXT 0x8007 -#define GL_MAX_EXT 0x8008 -#define GL_BLEND_EQUATION_EXT 0x8009 -#endif - -#ifndef GL_EXT_blend_subtract -#define GL_FUNC_SUBTRACT_EXT 0x800A -#define GL_FUNC_REVERSE_SUBTRACT_EXT 0x800B -#endif - -#ifndef GL_EXT_blend_logic_op -#endif - -#ifndef GL_SGIX_interlace -#define GL_INTERLACE_SGIX 0x8094 -#endif - -#ifndef GL_SGIX_pixel_tiles -#define GL_PIXEL_TILE_BEST_ALIGNMENT_SGIX 0x813E -#define GL_PIXEL_TILE_CACHE_INCREMENT_SGIX 0x813F -#define GL_PIXEL_TILE_WIDTH_SGIX 0x8140 -#define GL_PIXEL_TILE_HEIGHT_SGIX 0x8141 -#define GL_PIXEL_TILE_GRID_WIDTH_SGIX 0x8142 -#define GL_PIXEL_TILE_GRID_HEIGHT_SGIX 0x8143 -#define GL_PIXEL_TILE_GRID_DEPTH_SGIX 0x8144 -#define GL_PIXEL_TILE_CACHE_SIZE_SGIX 0x8145 -#endif - -#ifndef GL_SGIS_texture_select -#define GL_DUAL_ALPHA4_SGIS 0x8110 -#define GL_DUAL_ALPHA8_SGIS 0x8111 -#define GL_DUAL_ALPHA12_SGIS 0x8112 -#define GL_DUAL_ALPHA16_SGIS 0x8113 -#define GL_DUAL_LUMINANCE4_SGIS 0x8114 -#define GL_DUAL_LUMINANCE8_SGIS 0x8115 -#define GL_DUAL_LUMINANCE12_SGIS 0x8116 -#define GL_DUAL_LUMINANCE16_SGIS 0x8117 -#define GL_DUAL_INTENSITY4_SGIS 0x8118 -#define GL_DUAL_INTENSITY8_SGIS 0x8119 -#define GL_DUAL_INTENSITY12_SGIS 0x811A -#define GL_DUAL_INTENSITY16_SGIS 0x811B -#define GL_DUAL_LUMINANCE_ALPHA4_SGIS 0x811C -#define GL_DUAL_LUMINANCE_ALPHA8_SGIS 0x811D -#define GL_QUAD_ALPHA4_SGIS 0x811E -#define GL_QUAD_ALPHA8_SGIS 0x811F -#define GL_QUAD_LUMINANCE4_SGIS 0x8120 -#define GL_QUAD_LUMINANCE8_SGIS 0x8121 -#define GL_QUAD_INTENSITY4_SGIS 0x8122 -#define GL_QUAD_INTENSITY8_SGIS 0x8123 -#define GL_DUAL_TEXTURE_SELECT_SGIS 0x8124 -#define GL_QUAD_TEXTURE_SELECT_SGIS 0x8125 -#endif - -#ifndef GL_SGIX_sprite -#define GL_SPRITE_SGIX 0x8148 -#define GL_SPRITE_MODE_SGIX 0x8149 -#define GL_SPRITE_AXIS_SGIX 0x814A -#define GL_SPRITE_TRANSLATION_SGIX 0x814B -#define GL_SPRITE_AXIAL_SGIX 0x814C -#define GL_SPRITE_OBJECT_ALIGNED_SGIX 0x814D -#define GL_SPRITE_EYE_ALIGNED_SGIX 0x814E -#endif - -#ifndef GL_SGIX_texture_multi_buffer -#define GL_TEXTURE_MULTI_BUFFER_HINT_SGIX 0x812E -#endif - -#ifndef GL_EXT_point_parameters -#define GL_POINT_SIZE_MIN_EXT 0x8126 -#define GL_POINT_SIZE_MAX_EXT 0x8127 -#define GL_POINT_FADE_THRESHOLD_SIZE_EXT 0x8128 -#define GL_DISTANCE_ATTENUATION_EXT 0x8129 -#endif - -#ifndef GL_SGIS_point_parameters -#define GL_POINT_SIZE_MIN_SGIS 0x8126 -#define GL_POINT_SIZE_MAX_SGIS 0x8127 -#define GL_POINT_FADE_THRESHOLD_SIZE_SGIS 0x8128 -#define GL_DISTANCE_ATTENUATION_SGIS 0x8129 -#endif - -#ifndef GL_SGIX_instruments -#define GL_INSTRUMENT_BUFFER_POINTER_SGIX 0x8180 -#define GL_INSTRUMENT_MEASUREMENTS_SGIX 0x8181 -#endif - -#ifndef GL_SGIX_texture_scale_bias -#define GL_POST_TEXTURE_FILTER_BIAS_SGIX 0x8179 -#define GL_POST_TEXTURE_FILTER_SCALE_SGIX 0x817A -#define GL_POST_TEXTURE_FILTER_BIAS_RANGE_SGIX 0x817B -#define GL_POST_TEXTURE_FILTER_SCALE_RANGE_SGIX 0x817C -#endif - -#ifndef GL_SGIX_framezoom -#define GL_FRAMEZOOM_SGIX 0x818B -#define GL_FRAMEZOOM_FACTOR_SGIX 0x818C -#define GL_MAX_FRAMEZOOM_FACTOR_SGIX 0x818D -#endif - -#ifndef GL_SGIX_tag_sample_buffer -#endif - -#ifndef GL_FfdMaskSGIX -#define GL_TEXTURE_DEFORMATION_BIT_SGIX 0x00000001 -#define GL_GEOMETRY_DEFORMATION_BIT_SGIX 0x00000002 -#endif - -#ifndef GL_SGIX_polynomial_ffd -#define GL_GEOMETRY_DEFORMATION_SGIX 0x8194 -#define GL_TEXTURE_DEFORMATION_SGIX 0x8195 -#define GL_DEFORMATIONS_MASK_SGIX 0x8196 -#define GL_MAX_DEFORMATION_ORDER_SGIX 0x8197 -#endif - -#ifndef GL_SGIX_reference_plane -#define GL_REFERENCE_PLANE_SGIX 0x817D -#define GL_REFERENCE_PLANE_EQUATION_SGIX 0x817E -#endif - -#ifndef GL_SGIX_flush_raster -#endif - -#ifndef GL_SGIX_depth_texture -#define GL_DEPTH_COMPONENT16_SGIX 0x81A5 -#define GL_DEPTH_COMPONENT24_SGIX 0x81A6 -#define GL_DEPTH_COMPONENT32_SGIX 0x81A7 -#endif - -#ifndef GL_SGIS_fog_function -#define GL_FOG_FUNC_SGIS 0x812A -#define GL_FOG_FUNC_POINTS_SGIS 0x812B -#define GL_MAX_FOG_FUNC_POINTS_SGIS 0x812C -#endif - -#ifndef GL_SGIX_fog_offset -#define GL_FOG_OFFSET_SGIX 0x8198 -#define GL_FOG_OFFSET_VALUE_SGIX 0x8199 -#endif - -#ifndef GL_HP_image_transform -#define GL_IMAGE_SCALE_X_HP 0x8155 -#define GL_IMAGE_SCALE_Y_HP 0x8156 -#define GL_IMAGE_TRANSLATE_X_HP 0x8157 -#define GL_IMAGE_TRANSLATE_Y_HP 0x8158 -#define GL_IMAGE_ROTATE_ANGLE_HP 0x8159 -#define GL_IMAGE_ROTATE_ORIGIN_X_HP 0x815A -#define GL_IMAGE_ROTATE_ORIGIN_Y_HP 0x815B -#define GL_IMAGE_MAG_FILTER_HP 0x815C -#define GL_IMAGE_MIN_FILTER_HP 0x815D -#define GL_IMAGE_CUBIC_WEIGHT_HP 0x815E -#define GL_CUBIC_HP 0x815F -#define GL_AVERAGE_HP 0x8160 -#define GL_IMAGE_TRANSFORM_2D_HP 0x8161 -#define GL_POST_IMAGE_TRANSFORM_COLOR_TABLE_HP 0x8162 -#define GL_PROXY_POST_IMAGE_TRANSFORM_COLOR_TABLE_HP 0x8163 -#endif - -#ifndef GL_HP_convolution_border_modes -#define GL_IGNORE_BORDER_HP 0x8150 -#define GL_CONSTANT_BORDER_HP 0x8151 -#define GL_REPLICATE_BORDER_HP 0x8153 -#define GL_CONVOLUTION_BORDER_COLOR_HP 0x8154 -#endif - -#ifndef GL_INGR_palette_buffer -#endif - -#ifndef GL_SGIX_texture_add_env -#define GL_TEXTURE_ENV_BIAS_SGIX 0x80BE -#endif - -#ifndef GL_EXT_color_subtable -#endif - -#ifndef GL_PGI_vertex_hints -#define GL_VERTEX_DATA_HINT_PGI 0x1A22A -#define GL_VERTEX_CONSISTENT_HINT_PGI 0x1A22B -#define GL_MATERIAL_SIDE_HINT_PGI 0x1A22C -#define GL_MAX_VERTEX_HINT_PGI 0x1A22D -#define GL_COLOR3_BIT_PGI 0x00010000 -#define GL_COLOR4_BIT_PGI 0x00020000 -#define GL_EDGEFLAG_BIT_PGI 0x00040000 -#define GL_INDEX_BIT_PGI 0x00080000 -#define GL_MAT_AMBIENT_BIT_PGI 0x00100000 -#define GL_MAT_AMBIENT_AND_DIFFUSE_BIT_PGI 0x00200000 -#define GL_MAT_DIFFUSE_BIT_PGI 0x00400000 -#define GL_MAT_EMISSION_BIT_PGI 0x00800000 -#define GL_MAT_COLOR_INDEXES_BIT_PGI 0x01000000 -#define GL_MAT_SHININESS_BIT_PGI 0x02000000 -#define GL_MAT_SPECULAR_BIT_PGI 0x04000000 -#define GL_NORMAL_BIT_PGI 0x08000000 -#define GL_TEXCOORD1_BIT_PGI 0x10000000 -#define GL_TEXCOORD2_BIT_PGI 0x20000000 -#define GL_TEXCOORD3_BIT_PGI 0x40000000 -#define GL_TEXCOORD4_BIT_PGI 0x80000000 -#define GL_VERTEX23_BIT_PGI 0x00000004 -#define GL_VERTEX4_BIT_PGI 0x00000008 -#endif - -#ifndef GL_PGI_misc_hints -#define GL_PREFER_DOUBLEBUFFER_HINT_PGI 0x1A1F8 -#define GL_CONSERVE_MEMORY_HINT_PGI 0x1A1FD -#define GL_RECLAIM_MEMORY_HINT_PGI 0x1A1FE -#define GL_NATIVE_GRAPHICS_HANDLE_PGI 0x1A202 -#define GL_NATIVE_GRAPHICS_BEGIN_HINT_PGI 0x1A203 -#define GL_NATIVE_GRAPHICS_END_HINT_PGI 0x1A204 -#define GL_ALWAYS_FAST_HINT_PGI 0x1A20C -#define GL_ALWAYS_SOFT_HINT_PGI 0x1A20D -#define GL_ALLOW_DRAW_OBJ_HINT_PGI 0x1A20E -#define GL_ALLOW_DRAW_WIN_HINT_PGI 0x1A20F -#define GL_ALLOW_DRAW_FRG_HINT_PGI 0x1A210 -#define GL_ALLOW_DRAW_MEM_HINT_PGI 0x1A211 -#define GL_STRICT_DEPTHFUNC_HINT_PGI 0x1A216 -#define GL_STRICT_LIGHTING_HINT_PGI 0x1A217 -#define GL_STRICT_SCISSOR_HINT_PGI 0x1A218 -#define GL_FULL_STIPPLE_HINT_PGI 0x1A219 -#define GL_CLIP_NEAR_HINT_PGI 0x1A220 -#define GL_CLIP_FAR_HINT_PGI 0x1A221 -#define GL_WIDE_LINE_HINT_PGI 0x1A222 -#define GL_BACK_NORMALS_HINT_PGI 0x1A223 -#endif - -#ifndef GL_EXT_paletted_texture -#define GL_COLOR_INDEX1_EXT 0x80E2 -#define GL_COLOR_INDEX2_EXT 0x80E3 -#define GL_COLOR_INDEX4_EXT 0x80E4 -#define GL_COLOR_INDEX8_EXT 0x80E5 -#define GL_COLOR_INDEX12_EXT 0x80E6 -#define GL_COLOR_INDEX16_EXT 0x80E7 -#define GL_TEXTURE_INDEX_SIZE_EXT 0x80ED -#endif - -#ifndef GL_EXT_clip_volume_hint -#define GL_CLIP_VOLUME_CLIPPING_HINT_EXT 0x80F0 -#endif - -#ifndef GL_SGIX_list_priority -#define GL_LIST_PRIORITY_SGIX 0x8182 -#endif - -#ifndef GL_SGIX_ir_instrument1 -#define GL_IR_INSTRUMENT1_SGIX 0x817F -#endif - -#ifndef GL_SGIX_calligraphic_fragment -#define GL_CALLIGRAPHIC_FRAGMENT_SGIX 0x8183 -#endif - -#ifndef GL_SGIX_texture_lod_bias -#define GL_TEXTURE_LOD_BIAS_S_SGIX 0x818E -#define GL_TEXTURE_LOD_BIAS_T_SGIX 0x818F -#define GL_TEXTURE_LOD_BIAS_R_SGIX 0x8190 -#endif - -#ifndef GL_SGIX_shadow_ambient -#define GL_SHADOW_AMBIENT_SGIX 0x80BF -#endif - -#ifndef GL_EXT_index_texture -#endif - -#ifndef GL_EXT_index_material -#define GL_INDEX_MATERIAL_EXT 0x81B8 -#define GL_INDEX_MATERIAL_PARAMETER_EXT 0x81B9 -#define GL_INDEX_MATERIAL_FACE_EXT 0x81BA -#endif - -#ifndef GL_EXT_index_func -#define GL_INDEX_TEST_EXT 0x81B5 -#define GL_INDEX_TEST_FUNC_EXT 0x81B6 -#define GL_INDEX_TEST_REF_EXT 0x81B7 -#endif - -#ifndef GL_EXT_index_array_formats -#define GL_IUI_V2F_EXT 0x81AD -#define GL_IUI_V3F_EXT 0x81AE -#define GL_IUI_N3F_V2F_EXT 0x81AF -#define GL_IUI_N3F_V3F_EXT 0x81B0 -#define GL_T2F_IUI_V2F_EXT 0x81B1 -#define GL_T2F_IUI_V3F_EXT 0x81B2 -#define GL_T2F_IUI_N3F_V2F_EXT 0x81B3 -#define GL_T2F_IUI_N3F_V3F_EXT 0x81B4 -#endif - -#ifndef GL_EXT_compiled_vertex_array -#define GL_ARRAY_ELEMENT_LOCK_FIRST_EXT 0x81A8 -#define GL_ARRAY_ELEMENT_LOCK_COUNT_EXT 0x81A9 -#endif - -#ifndef GL_EXT_cull_vertex -#define GL_CULL_VERTEX_EXT 0x81AA -#define GL_CULL_VERTEX_EYE_POSITION_EXT 0x81AB -#define GL_CULL_VERTEX_OBJECT_POSITION_EXT 0x81AC -#endif - -#ifndef GL_SGIX_ycrcb -#define GL_YCRCB_422_SGIX 0x81BB -#define GL_YCRCB_444_SGIX 0x81BC -#endif - -#ifndef GL_SGIX_fragment_lighting -#define GL_FRAGMENT_LIGHTING_SGIX 0x8400 -#define GL_FRAGMENT_COLOR_MATERIAL_SGIX 0x8401 -#define GL_FRAGMENT_COLOR_MATERIAL_FACE_SGIX 0x8402 -#define GL_FRAGMENT_COLOR_MATERIAL_PARAMETER_SGIX 0x8403 -#define GL_MAX_FRAGMENT_LIGHTS_SGIX 0x8404 -#define GL_MAX_ACTIVE_LIGHTS_SGIX 0x8405 -#define GL_CURRENT_RASTER_NORMAL_SGIX 0x8406 -#define GL_LIGHT_ENV_MODE_SGIX 0x8407 -#define GL_FRAGMENT_LIGHT_MODEL_LOCAL_VIEWER_SGIX 0x8408 -#define GL_FRAGMENT_LIGHT_MODEL_TWO_SIDE_SGIX 0x8409 -#define GL_FRAGMENT_LIGHT_MODEL_AMBIENT_SGIX 0x840A -#define GL_FRAGMENT_LIGHT_MODEL_NORMAL_INTERPOLATION_SGIX 0x840B -#define GL_FRAGMENT_LIGHT0_SGIX 0x840C -#define GL_FRAGMENT_LIGHT1_SGIX 0x840D -#define GL_FRAGMENT_LIGHT2_SGIX 0x840E -#define GL_FRAGMENT_LIGHT3_SGIX 0x840F -#define GL_FRAGMENT_LIGHT4_SGIX 0x8410 -#define GL_FRAGMENT_LIGHT5_SGIX 0x8411 -#define GL_FRAGMENT_LIGHT6_SGIX 0x8412 -#define GL_FRAGMENT_LIGHT7_SGIX 0x8413 -#endif - -#ifndef GL_IBM_rasterpos_clip -#define GL_RASTER_POSITION_UNCLIPPED_IBM 0x19262 -#endif - -#ifndef GL_HP_texture_lighting -#define GL_TEXTURE_LIGHTING_MODE_HP 0x8167 -#define GL_TEXTURE_POST_SPECULAR_HP 0x8168 -#define GL_TEXTURE_PRE_SPECULAR_HP 0x8169 -#endif - -#ifndef GL_EXT_draw_range_elements -#define GL_MAX_ELEMENTS_VERTICES_EXT 0x80E8 -#define GL_MAX_ELEMENTS_INDICES_EXT 0x80E9 -#endif - -#ifndef GL_WIN_phong_shading -#define GL_PHONG_WIN 0x80EA -#define GL_PHONG_HINT_WIN 0x80EB -#endif - -#ifndef GL_WIN_specular_fog -#define GL_FOG_SPECULAR_TEXTURE_WIN 0x80EC -#endif - -#ifndef GL_EXT_light_texture -#define GL_FRAGMENT_MATERIAL_EXT 0x8349 -#define GL_FRAGMENT_NORMAL_EXT 0x834A -#define GL_FRAGMENT_COLOR_EXT 0x834C -#define GL_ATTENUATION_EXT 0x834D -#define GL_SHADOW_ATTENUATION_EXT 0x834E -#define GL_TEXTURE_APPLICATION_MODE_EXT 0x834F -#define GL_TEXTURE_LIGHT_EXT 0x8350 -#define GL_TEXTURE_MATERIAL_FACE_EXT 0x8351 -#define GL_TEXTURE_MATERIAL_PARAMETER_EXT 0x8352 -/* reuse GL_FRAGMENT_DEPTH_EXT */ -#endif - -#ifndef GL_SGIX_blend_alpha_minmax -#define GL_ALPHA_MIN_SGIX 0x8320 -#define GL_ALPHA_MAX_SGIX 0x8321 -#endif - -#ifndef GL_SGIX_impact_pixel_texture -#define GL_PIXEL_TEX_GEN_Q_CEILING_SGIX 0x8184 -#define GL_PIXEL_TEX_GEN_Q_ROUND_SGIX 0x8185 -#define GL_PIXEL_TEX_GEN_Q_FLOOR_SGIX 0x8186 -#define GL_PIXEL_TEX_GEN_ALPHA_REPLACE_SGIX 0x8187 -#define GL_PIXEL_TEX_GEN_ALPHA_NO_REPLACE_SGIX 0x8188 -#define GL_PIXEL_TEX_GEN_ALPHA_LS_SGIX 0x8189 -#define GL_PIXEL_TEX_GEN_ALPHA_MS_SGIX 0x818A -#endif - -#ifndef GL_EXT_bgra -#define GL_BGR_EXT 0x80E0 -#define GL_BGRA_EXT 0x80E1 -#endif - -#ifndef GL_SGIX_async -#define GL_ASYNC_MARKER_SGIX 0x8329 -#endif - -#ifndef GL_SGIX_async_pixel -#define GL_ASYNC_TEX_IMAGE_SGIX 0x835C -#define GL_ASYNC_DRAW_PIXELS_SGIX 0x835D -#define GL_ASYNC_READ_PIXELS_SGIX 0x835E -#define GL_MAX_ASYNC_TEX_IMAGE_SGIX 0x835F -#define GL_MAX_ASYNC_DRAW_PIXELS_SGIX 0x8360 -#define GL_MAX_ASYNC_READ_PIXELS_SGIX 0x8361 -#endif - -#ifndef GL_SGIX_async_histogram -#define GL_ASYNC_HISTOGRAM_SGIX 0x832C -#define GL_MAX_ASYNC_HISTOGRAM_SGIX 0x832D -#endif - -#ifndef GL_INTEL_texture_scissor -#endif - -#ifndef GL_INTEL_parallel_arrays -#define GL_PARALLEL_ARRAYS_INTEL 0x83F4 -#define GL_VERTEX_ARRAY_PARALLEL_POINTERS_INTEL 0x83F5 -#define GL_NORMAL_ARRAY_PARALLEL_POINTERS_INTEL 0x83F6 -#define GL_COLOR_ARRAY_PARALLEL_POINTERS_INTEL 0x83F7 -#define GL_TEXTURE_COORD_ARRAY_PARALLEL_POINTERS_INTEL 0x83F8 -#endif - -#ifndef GL_HP_occlusion_test -#define GL_OCCLUSION_TEST_HP 0x8165 -#define GL_OCCLUSION_TEST_RESULT_HP 0x8166 -#endif - -#ifndef GL_EXT_pixel_transform -#define GL_PIXEL_TRANSFORM_2D_EXT 0x8330 -#define GL_PIXEL_MAG_FILTER_EXT 0x8331 -#define GL_PIXEL_MIN_FILTER_EXT 0x8332 -#define GL_PIXEL_CUBIC_WEIGHT_EXT 0x8333 -#define GL_CUBIC_EXT 0x8334 -#define GL_AVERAGE_EXT 0x8335 -#define GL_PIXEL_TRANSFORM_2D_STACK_DEPTH_EXT 0x8336 -#define GL_MAX_PIXEL_TRANSFORM_2D_STACK_DEPTH_EXT 0x8337 -#define GL_PIXEL_TRANSFORM_2D_MATRIX_EXT 0x8338 -#endif - -#ifndef GL_EXT_pixel_transform_color_table -#endif - -#ifndef GL_EXT_shared_texture_palette -#define GL_SHARED_TEXTURE_PALETTE_EXT 0x81FB -#endif - -#ifndef GL_EXT_separate_specular_color -#define GL_LIGHT_MODEL_COLOR_CONTROL_EXT 0x81F8 -#define GL_SINGLE_COLOR_EXT 0x81F9 -#define GL_SEPARATE_SPECULAR_COLOR_EXT 0x81FA -#endif - -#ifndef GL_EXT_secondary_color -#define GL_COLOR_SUM_EXT 0x8458 -#define GL_CURRENT_SECONDARY_COLOR_EXT 0x8459 -#define GL_SECONDARY_COLOR_ARRAY_SIZE_EXT 0x845A -#define GL_SECONDARY_COLOR_ARRAY_TYPE_EXT 0x845B -#define GL_SECONDARY_COLOR_ARRAY_STRIDE_EXT 0x845C -#define GL_SECONDARY_COLOR_ARRAY_POINTER_EXT 0x845D -#define GL_SECONDARY_COLOR_ARRAY_EXT 0x845E -#endif - -#ifndef GL_EXT_texture_perturb_normal -#define GL_PERTURB_EXT 0x85AE -#define GL_TEXTURE_NORMAL_EXT 0x85AF -#endif - -#ifndef GL_EXT_multi_draw_arrays -#endif - -#ifndef GL_EXT_fog_coord -#define GL_FOG_COORDINATE_SOURCE_EXT 0x8450 -#define GL_FOG_COORDINATE_EXT 0x8451 -#define GL_FRAGMENT_DEPTH_EXT 0x8452 -#define GL_CURRENT_FOG_COORDINATE_EXT 0x8453 -#define GL_FOG_COORDINATE_ARRAY_TYPE_EXT 0x8454 -#define GL_FOG_COORDINATE_ARRAY_STRIDE_EXT 0x8455 -#define GL_FOG_COORDINATE_ARRAY_POINTER_EXT 0x8456 -#define GL_FOG_COORDINATE_ARRAY_EXT 0x8457 -#endif - -#ifndef GL_REND_screen_coordinates -#define GL_SCREEN_COORDINATES_REND 0x8490 -#define GL_INVERTED_SCREEN_W_REND 0x8491 -#endif - -#ifndef GL_EXT_coordinate_frame -#define GL_TANGENT_ARRAY_EXT 0x8439 -#define GL_BINORMAL_ARRAY_EXT 0x843A -#define GL_CURRENT_TANGENT_EXT 0x843B -#define GL_CURRENT_BINORMAL_EXT 0x843C -#define GL_TANGENT_ARRAY_TYPE_EXT 0x843E -#define GL_TANGENT_ARRAY_STRIDE_EXT 0x843F -#define GL_BINORMAL_ARRAY_TYPE_EXT 0x8440 -#define GL_BINORMAL_ARRAY_STRIDE_EXT 0x8441 -#define GL_TANGENT_ARRAY_POINTER_EXT 0x8442 -#define GL_BINORMAL_ARRAY_POINTER_EXT 0x8443 -#define GL_MAP1_TANGENT_EXT 0x8444 -#define GL_MAP2_TANGENT_EXT 0x8445 -#define GL_MAP1_BINORMAL_EXT 0x8446 -#define GL_MAP2_BINORMAL_EXT 0x8447 -#endif - -#ifndef GL_EXT_texture_env_combine -#define GL_COMBINE_EXT 0x8570 -#define GL_COMBINE_RGB_EXT 0x8571 -#define GL_COMBINE_ALPHA_EXT 0x8572 -#define GL_RGB_SCALE_EXT 0x8573 -#define GL_ADD_SIGNED_EXT 0x8574 -#define GL_INTERPOLATE_EXT 0x8575 -#define GL_CONSTANT_EXT 0x8576 -#define GL_PRIMARY_COLOR_EXT 0x8577 -#define GL_PREVIOUS_EXT 0x8578 -#define GL_SOURCE0_RGB_EXT 0x8580 -#define GL_SOURCE1_RGB_EXT 0x8581 -#define GL_SOURCE2_RGB_EXT 0x8582 -#define GL_SOURCE0_ALPHA_EXT 0x8588 -#define GL_SOURCE1_ALPHA_EXT 0x8589 -#define GL_SOURCE2_ALPHA_EXT 0x858A -#define GL_OPERAND0_RGB_EXT 0x8590 -#define GL_OPERAND1_RGB_EXT 0x8591 -#define GL_OPERAND2_RGB_EXT 0x8592 -#define GL_OPERAND0_ALPHA_EXT 0x8598 -#define GL_OPERAND1_ALPHA_EXT 0x8599 -#define GL_OPERAND2_ALPHA_EXT 0x859A -#endif - -#ifndef GL_APPLE_specular_vector -#define GL_LIGHT_MODEL_SPECULAR_VECTOR_APPLE 0x85B0 -#endif - -#ifndef GL_APPLE_transform_hint -#define GL_TRANSFORM_HINT_APPLE 0x85B1 -#endif - -#ifndef GL_SGIX_fog_scale -#define GL_FOG_SCALE_SGIX 0x81FC -#define GL_FOG_SCALE_VALUE_SGIX 0x81FD -#endif - -#ifndef GL_SUNX_constant_data -#define GL_UNPACK_CONSTANT_DATA_SUNX 0x81D5 -#define GL_TEXTURE_CONSTANT_DATA_SUNX 0x81D6 -#endif - -#ifndef GL_SUN_global_alpha -#define GL_GLOBAL_ALPHA_SUN 0x81D9 -#define GL_GLOBAL_ALPHA_FACTOR_SUN 0x81DA -#endif - -#ifndef GL_SUN_triangle_list -#define GL_RESTART_SUN 0x0001 -#define GL_REPLACE_MIDDLE_SUN 0x0002 -#define GL_REPLACE_OLDEST_SUN 0x0003 -#define GL_TRIANGLE_LIST_SUN 0x81D7 -#define GL_REPLACEMENT_CODE_SUN 0x81D8 -#define GL_REPLACEMENT_CODE_ARRAY_SUN 0x85C0 -#define GL_REPLACEMENT_CODE_ARRAY_TYPE_SUN 0x85C1 -#define GL_REPLACEMENT_CODE_ARRAY_STRIDE_SUN 0x85C2 -#define GL_REPLACEMENT_CODE_ARRAY_POINTER_SUN 0x85C3 -#define GL_R1UI_V3F_SUN 0x85C4 -#define GL_R1UI_C4UB_V3F_SUN 0x85C5 -#define GL_R1UI_C3F_V3F_SUN 0x85C6 -#define GL_R1UI_N3F_V3F_SUN 0x85C7 -#define GL_R1UI_C4F_N3F_V3F_SUN 0x85C8 -#define GL_R1UI_T2F_V3F_SUN 0x85C9 -#define GL_R1UI_T2F_N3F_V3F_SUN 0x85CA -#define GL_R1UI_T2F_C4F_N3F_V3F_SUN 0x85CB -#endif - -#ifndef GL_SUN_vertex -#endif - -#ifndef GL_EXT_blend_func_separate -#define GL_BLEND_DST_RGB_EXT 0x80C8 -#define GL_BLEND_SRC_RGB_EXT 0x80C9 -#define GL_BLEND_DST_ALPHA_EXT 0x80CA -#define GL_BLEND_SRC_ALPHA_EXT 0x80CB -#endif - -#ifndef GL_INGR_color_clamp -#define GL_RED_MIN_CLAMP_INGR 0x8560 -#define GL_GREEN_MIN_CLAMP_INGR 0x8561 -#define GL_BLUE_MIN_CLAMP_INGR 0x8562 -#define GL_ALPHA_MIN_CLAMP_INGR 0x8563 -#define GL_RED_MAX_CLAMP_INGR 0x8564 -#define GL_GREEN_MAX_CLAMP_INGR 0x8565 -#define GL_BLUE_MAX_CLAMP_INGR 0x8566 -#define GL_ALPHA_MAX_CLAMP_INGR 0x8567 -#endif - -#ifndef GL_INGR_interlace_read -#define GL_INTERLACE_READ_INGR 0x8568 -#endif - -#ifndef GL_EXT_stencil_wrap -#define GL_INCR_WRAP_EXT 0x8507 -#define GL_DECR_WRAP_EXT 0x8508 -#endif - -#ifndef GL_EXT_422_pixels -#define GL_422_EXT 0x80CC -#define GL_422_REV_EXT 0x80CD -#define GL_422_AVERAGE_EXT 0x80CE -#define GL_422_REV_AVERAGE_EXT 0x80CF -#endif - -#ifndef GL_NV_texgen_reflection -#define GL_NORMAL_MAP_NV 0x8511 -#define GL_REFLECTION_MAP_NV 0x8512 -#endif - -#ifndef GL_EXT_texture_cube_map -#define GL_NORMAL_MAP_EXT 0x8511 -#define GL_REFLECTION_MAP_EXT 0x8512 -#define GL_TEXTURE_CUBE_MAP_EXT 0x8513 -#define GL_TEXTURE_BINDING_CUBE_MAP_EXT 0x8514 -#define GL_TEXTURE_CUBE_MAP_POSITIVE_X_EXT 0x8515 -#define GL_TEXTURE_CUBE_MAP_NEGATIVE_X_EXT 0x8516 -#define GL_TEXTURE_CUBE_MAP_POSITIVE_Y_EXT 0x8517 -#define GL_TEXTURE_CUBE_MAP_NEGATIVE_Y_EXT 0x8518 -#define GL_TEXTURE_CUBE_MAP_POSITIVE_Z_EXT 0x8519 -#define GL_TEXTURE_CUBE_MAP_NEGATIVE_Z_EXT 0x851A -#define GL_PROXY_TEXTURE_CUBE_MAP_EXT 0x851B -#define GL_MAX_CUBE_MAP_TEXTURE_SIZE_EXT 0x851C -#endif - -#ifndef GL_SUN_convolution_border_modes -#define GL_WRAP_BORDER_SUN 0x81D4 -#endif - -#ifndef GL_EXT_texture_env_add -#endif - -#ifndef GL_EXT_texture_lod_bias -#define GL_MAX_TEXTURE_LOD_BIAS_EXT 0x84FD -#define GL_TEXTURE_FILTER_CONTROL_EXT 0x8500 -#define GL_TEXTURE_LOD_BIAS_EXT 0x8501 -#endif - -#ifndef GL_EXT_texture_filter_anisotropic -#define GL_TEXTURE_MAX_ANISOTROPY_EXT 0x84FE -#define GL_MAX_TEXTURE_MAX_ANISOTROPY_EXT 0x84FF -#endif - -#ifndef GL_EXT_vertex_weighting -#define GL_MODELVIEW0_STACK_DEPTH_EXT GL_MODELVIEW_STACK_DEPTH -#define GL_MODELVIEW1_STACK_DEPTH_EXT 0x8502 -#define GL_MODELVIEW0_MATRIX_EXT GL_MODELVIEW_MATRIX -#define GL_MODELVIEW1_MATRIX_EXT 0x8506 -#define GL_VERTEX_WEIGHTING_EXT 0x8509 -#define GL_MODELVIEW0_EXT GL_MODELVIEW -#define GL_MODELVIEW1_EXT 0x850A -#define GL_CURRENT_VERTEX_WEIGHT_EXT 0x850B -#define GL_VERTEX_WEIGHT_ARRAY_EXT 0x850C -#define GL_VERTEX_WEIGHT_ARRAY_SIZE_EXT 0x850D -#define GL_VERTEX_WEIGHT_ARRAY_TYPE_EXT 0x850E -#define GL_VERTEX_WEIGHT_ARRAY_STRIDE_EXT 0x850F -#define GL_VERTEX_WEIGHT_ARRAY_POINTER_EXT 0x8510 -#endif - -#ifndef GL_NV_light_max_exponent -#define GL_MAX_SHININESS_NV 0x8504 -#define GL_MAX_SPOT_EXPONENT_NV 0x8505 -#endif - -#ifndef GL_NV_vertex_array_range -#define GL_VERTEX_ARRAY_RANGE_NV 0x851D -#define GL_VERTEX_ARRAY_RANGE_LENGTH_NV 0x851E -#define GL_VERTEX_ARRAY_RANGE_VALID_NV 0x851F -#define GL_MAX_VERTEX_ARRAY_RANGE_ELEMENT_NV 0x8520 -#define GL_VERTEX_ARRAY_RANGE_POINTER_NV 0x8521 -#endif - -#ifndef GL_NV_register_combiners -#define GL_REGISTER_COMBINERS_NV 0x8522 -#define GL_VARIABLE_A_NV 0x8523 -#define GL_VARIABLE_B_NV 0x8524 -#define GL_VARIABLE_C_NV 0x8525 -#define GL_VARIABLE_D_NV 0x8526 -#define GL_VARIABLE_E_NV 0x8527 -#define GL_VARIABLE_F_NV 0x8528 -#define GL_VARIABLE_G_NV 0x8529 -#define GL_CONSTANT_COLOR0_NV 0x852A -#define GL_CONSTANT_COLOR1_NV 0x852B -#define GL_PRIMARY_COLOR_NV 0x852C -#define GL_SECONDARY_COLOR_NV 0x852D -#define GL_SPARE0_NV 0x852E -#define GL_SPARE1_NV 0x852F -#define GL_DISCARD_NV 0x8530 -#define GL_E_TIMES_F_NV 0x8531 -#define GL_SPARE0_PLUS_SECONDARY_COLOR_NV 0x8532 -#define GL_UNSIGNED_IDENTITY_NV 0x8536 -#define GL_UNSIGNED_INVERT_NV 0x8537 -#define GL_EXPAND_NORMAL_NV 0x8538 -#define GL_EXPAND_NEGATE_NV 0x8539 -#define GL_HALF_BIAS_NORMAL_NV 0x853A -#define GL_HALF_BIAS_NEGATE_NV 0x853B -#define GL_SIGNED_IDENTITY_NV 0x853C -#define GL_SIGNED_NEGATE_NV 0x853D -#define GL_SCALE_BY_TWO_NV 0x853E -#define GL_SCALE_BY_FOUR_NV 0x853F -#define GL_SCALE_BY_ONE_HALF_NV 0x8540 -#define GL_BIAS_BY_NEGATIVE_ONE_HALF_NV 0x8541 -#define GL_COMBINER_INPUT_NV 0x8542 -#define GL_COMBINER_MAPPING_NV 0x8543 -#define GL_COMBINER_COMPONENT_USAGE_NV 0x8544 -#define GL_COMBINER_AB_DOT_PRODUCT_NV 0x8545 -#define GL_COMBINER_CD_DOT_PRODUCT_NV 0x8546 -#define GL_COMBINER_MUX_SUM_NV 0x8547 -#define GL_COMBINER_SCALE_NV 0x8548 -#define GL_COMBINER_BIAS_NV 0x8549 -#define GL_COMBINER_AB_OUTPUT_NV 0x854A -#define GL_COMBINER_CD_OUTPUT_NV 0x854B -#define GL_COMBINER_SUM_OUTPUT_NV 0x854C -#define GL_MAX_GENERAL_COMBINERS_NV 0x854D -#define GL_NUM_GENERAL_COMBINERS_NV 0x854E -#define GL_COLOR_SUM_CLAMP_NV 0x854F -#define GL_COMBINER0_NV 0x8550 -#define GL_COMBINER1_NV 0x8551 -#define GL_COMBINER2_NV 0x8552 -#define GL_COMBINER3_NV 0x8553 -#define GL_COMBINER4_NV 0x8554 -#define GL_COMBINER5_NV 0x8555 -#define GL_COMBINER6_NV 0x8556 -#define GL_COMBINER7_NV 0x8557 -/* reuse GL_TEXTURE0_ARB */ -/* reuse GL_TEXTURE1_ARB */ -/* reuse GL_ZERO */ -/* reuse GL_NONE */ -/* reuse GL_FOG */ -#endif - -#ifndef GL_NV_fog_distance -#define GL_FOG_DISTANCE_MODE_NV 0x855A -#define GL_EYE_RADIAL_NV 0x855B -#define GL_EYE_PLANE_ABSOLUTE_NV 0x855C -/* reuse GL_EYE_PLANE */ -#endif - -#ifndef GL_NV_texgen_emboss -#define GL_EMBOSS_LIGHT_NV 0x855D -#define GL_EMBOSS_CONSTANT_NV 0x855E -#define GL_EMBOSS_MAP_NV 0x855F -#endif - -#ifndef GL_NV_blend_square -#endif - -#ifndef GL_NV_texture_env_combine4 -#define GL_COMBINE4_NV 0x8503 -#define GL_SOURCE3_RGB_NV 0x8583 -#define GL_SOURCE3_ALPHA_NV 0x858B -#define GL_OPERAND3_RGB_NV 0x8593 -#define GL_OPERAND3_ALPHA_NV 0x859B -#endif - -#ifndef GL_MESA_resize_buffers -#endif - -#ifndef GL_MESA_window_pos -#endif - -#ifndef GL_EXT_texture_compression_s3tc -#define GL_COMPRESSED_RGB_S3TC_DXT1_EXT 0x83F0 -#define GL_COMPRESSED_RGBA_S3TC_DXT1_EXT 0x83F1 -#define GL_COMPRESSED_RGBA_S3TC_DXT3_EXT 0x83F2 -#define GL_COMPRESSED_RGBA_S3TC_DXT5_EXT 0x83F3 -#endif - -#ifndef GL_IBM_cull_vertex -#define GL_CULL_VERTEX_IBM 103050 -#endif - -#ifndef GL_IBM_multimode_draw_arrays -#endif - -#ifndef GL_IBM_vertex_array_lists -#define GL_VERTEX_ARRAY_LIST_IBM 103070 -#define GL_NORMAL_ARRAY_LIST_IBM 103071 -#define GL_COLOR_ARRAY_LIST_IBM 103072 -#define GL_INDEX_ARRAY_LIST_IBM 103073 -#define GL_TEXTURE_COORD_ARRAY_LIST_IBM 103074 -#define GL_EDGE_FLAG_ARRAY_LIST_IBM 103075 -#define GL_FOG_COORDINATE_ARRAY_LIST_IBM 103076 -#define GL_SECONDARY_COLOR_ARRAY_LIST_IBM 103077 -#define GL_VERTEX_ARRAY_LIST_STRIDE_IBM 103080 -#define GL_NORMAL_ARRAY_LIST_STRIDE_IBM 103081 -#define GL_COLOR_ARRAY_LIST_STRIDE_IBM 103082 -#define GL_INDEX_ARRAY_LIST_STRIDE_IBM 103083 -#define GL_TEXTURE_COORD_ARRAY_LIST_STRIDE_IBM 103084 -#define GL_EDGE_FLAG_ARRAY_LIST_STRIDE_IBM 103085 -#define GL_FOG_COORDINATE_ARRAY_LIST_STRIDE_IBM 103086 -#define GL_SECONDARY_COLOR_ARRAY_LIST_STRIDE_IBM 103087 -#endif - -#ifndef GL_SGIX_subsample -#define GL_PACK_SUBSAMPLE_RATE_SGIX 0x85A0 -#define GL_UNPACK_SUBSAMPLE_RATE_SGIX 0x85A1 -#define GL_PIXEL_SUBSAMPLE_4444_SGIX 0x85A2 -#define GL_PIXEL_SUBSAMPLE_2424_SGIX 0x85A3 -#define GL_PIXEL_SUBSAMPLE_4242_SGIX 0x85A4 -#endif - -#ifndef GL_SGIX_ycrcb_subsample -#endif - -#ifndef GL_SGIX_ycrcba -#define GL_YCRCB_SGIX 0x8318 -#define GL_YCRCBA_SGIX 0x8319 -#endif - -#ifndef GL_SGI_depth_pass_instrument -#define GL_DEPTH_PASS_INSTRUMENT_SGIX 0x8310 -#define GL_DEPTH_PASS_INSTRUMENT_COUNTERS_SGIX 0x8311 -#define GL_DEPTH_PASS_INSTRUMENT_MAX_SGIX 0x8312 -#endif - -#ifndef GL_3DFX_texture_compression_FXT1 -#define GL_COMPRESSED_RGB_FXT1_3DFX 0x86B0 -#define GL_COMPRESSED_RGBA_FXT1_3DFX 0x86B1 -#endif - -#ifndef GL_3DFX_multisample -#define GL_MULTISAMPLE_3DFX 0x86B2 -#define GL_SAMPLE_BUFFERS_3DFX 0x86B3 -#define GL_SAMPLES_3DFX 0x86B4 -#define GL_MULTISAMPLE_BIT_3DFX 0x20000000 -#endif - -#ifndef GL_3DFX_tbuffer -#endif - -#ifndef GL_EXT_multisample -#define GL_MULTISAMPLE_EXT 0x809D -#define GL_SAMPLE_ALPHA_TO_MASK_EXT 0x809E -#define GL_SAMPLE_ALPHA_TO_ONE_EXT 0x809F -#define GL_SAMPLE_MASK_EXT 0x80A0 -#define GL_1PASS_EXT 0x80A1 -#define GL_2PASS_0_EXT 0x80A2 -#define GL_2PASS_1_EXT 0x80A3 -#define GL_4PASS_0_EXT 0x80A4 -#define GL_4PASS_1_EXT 0x80A5 -#define GL_4PASS_2_EXT 0x80A6 -#define GL_4PASS_3_EXT 0x80A7 -#define GL_SAMPLE_BUFFERS_EXT 0x80A8 -#define GL_SAMPLES_EXT 0x80A9 -#define GL_SAMPLE_MASK_VALUE_EXT 0x80AA -#define GL_SAMPLE_MASK_INVERT_EXT 0x80AB -#define GL_SAMPLE_PATTERN_EXT 0x80AC -#define GL_MULTISAMPLE_BIT_EXT 0x20000000 -#endif - -#ifndef GL_SGIX_vertex_preclip -#define GL_VERTEX_PRECLIP_SGIX 0x83EE -#define GL_VERTEX_PRECLIP_HINT_SGIX 0x83EF -#endif - -#ifndef GL_SGIX_convolution_accuracy -#define GL_CONVOLUTION_HINT_SGIX 0x8316 -#endif - -#ifndef GL_SGIX_resample -#define GL_PACK_RESAMPLE_SGIX 0x842C -#define GL_UNPACK_RESAMPLE_SGIX 0x842D -#define GL_RESAMPLE_REPLICATE_SGIX 0x842E -#define GL_RESAMPLE_ZERO_FILL_SGIX 0x842F -#define GL_RESAMPLE_DECIMATE_SGIX 0x8430 -#endif - -#ifndef GL_SGIS_point_line_texgen -#define GL_EYE_DISTANCE_TO_POINT_SGIS 0x81F0 -#define GL_OBJECT_DISTANCE_TO_POINT_SGIS 0x81F1 -#define GL_EYE_DISTANCE_TO_LINE_SGIS 0x81F2 -#define GL_OBJECT_DISTANCE_TO_LINE_SGIS 0x81F3 -#define GL_EYE_POINT_SGIS 0x81F4 -#define GL_OBJECT_POINT_SGIS 0x81F5 -#define GL_EYE_LINE_SGIS 0x81F6 -#define GL_OBJECT_LINE_SGIS 0x81F7 -#endif - -#ifndef GL_SGIS_texture_color_mask -#define GL_TEXTURE_COLOR_WRITEMASK_SGIS 0x81EF -#endif - -#ifndef GL_EXT_texture_env_dot3 -#define GL_DOT3_RGB_EXT 0x8740 -#define GL_DOT3_RGBA_EXT 0x8741 -#endif - -#ifndef GL_ATI_texture_mirror_once -#define GL_MIRROR_CLAMP_ATI 0x8742 -#define GL_MIRROR_CLAMP_TO_EDGE_ATI 0x8743 -#endif - -#ifndef GL_NV_fence -#define GL_ALL_COMPLETED_NV 0x84F2 -#define GL_FENCE_STATUS_NV 0x84F3 -#define GL_FENCE_CONDITION_NV 0x84F4 -#endif - -#ifndef GL_IBM_texture_mirrored_repeat -#define GL_MIRRORED_REPEAT_IBM 0x8370 -#endif - -#ifndef GL_NV_evaluators -#define GL_EVAL_2D_NV 0x86C0 -#define GL_EVAL_TRIANGULAR_2D_NV 0x86C1 -#define GL_MAP_TESSELLATION_NV 0x86C2 -#define GL_MAP_ATTRIB_U_ORDER_NV 0x86C3 -#define GL_MAP_ATTRIB_V_ORDER_NV 0x86C4 -#define GL_EVAL_FRACTIONAL_TESSELLATION_NV 0x86C5 -#define GL_EVAL_VERTEX_ATTRIB0_NV 0x86C6 -#define GL_EVAL_VERTEX_ATTRIB1_NV 0x86C7 -#define GL_EVAL_VERTEX_ATTRIB2_NV 0x86C8 -#define GL_EVAL_VERTEX_ATTRIB3_NV 0x86C9 -#define GL_EVAL_VERTEX_ATTRIB4_NV 0x86CA -#define GL_EVAL_VERTEX_ATTRIB5_NV 0x86CB -#define GL_EVAL_VERTEX_ATTRIB6_NV 0x86CC -#define GL_EVAL_VERTEX_ATTRIB7_NV 0x86CD -#define GL_EVAL_VERTEX_ATTRIB8_NV 0x86CE -#define GL_EVAL_VERTEX_ATTRIB9_NV 0x86CF -#define GL_EVAL_VERTEX_ATTRIB10_NV 0x86D0 -#define GL_EVAL_VERTEX_ATTRIB11_NV 0x86D1 -#define GL_EVAL_VERTEX_ATTRIB12_NV 0x86D2 -#define GL_EVAL_VERTEX_ATTRIB13_NV 0x86D3 -#define GL_EVAL_VERTEX_ATTRIB14_NV 0x86D4 -#define GL_EVAL_VERTEX_ATTRIB15_NV 0x86D5 -#define GL_MAX_MAP_TESSELLATION_NV 0x86D6 -#define GL_MAX_RATIONAL_EVAL_ORDER_NV 0x86D7 -#endif - -#ifndef GL_NV_packed_depth_stencil -#define GL_DEPTH_STENCIL_NV 0x84F9 -#define GL_UNSIGNED_INT_24_8_NV 0x84FA -#endif - -#ifndef GL_NV_register_combiners2 -#define GL_PER_STAGE_CONSTANTS_NV 0x8535 -#endif - -#ifndef GL_NV_texture_compression_vtc -#endif - -#ifndef GL_NV_texture_rectangle -#define GL_TEXTURE_RECTANGLE_NV 0x84F5 -#define GL_TEXTURE_BINDING_RECTANGLE_NV 0x84F6 -#define GL_PROXY_TEXTURE_RECTANGLE_NV 0x84F7 -#define GL_MAX_RECTANGLE_TEXTURE_SIZE_NV 0x84F8 -#endif - -#ifndef GL_NV_texture_shader -#define GL_OFFSET_TEXTURE_RECTANGLE_NV 0x864C -#define GL_OFFSET_TEXTURE_RECTANGLE_SCALE_NV 0x864D -#define GL_DOT_PRODUCT_TEXTURE_RECTANGLE_NV 0x864E -#define GL_RGBA_UNSIGNED_DOT_PRODUCT_MAPPING_NV 0x86D9 -#define GL_UNSIGNED_INT_S8_S8_8_8_NV 0x86DA -#define GL_UNSIGNED_INT_8_8_S8_S8_REV_NV 0x86DB -#define GL_DSDT_MAG_INTENSITY_NV 0x86DC -#define GL_SHADER_CONSISTENT_NV 0x86DD -#define GL_TEXTURE_SHADER_NV 0x86DE -#define GL_SHADER_OPERATION_NV 0x86DF -#define GL_CULL_MODES_NV 0x86E0 -#define GL_OFFSET_TEXTURE_MATRIX_NV 0x86E1 -#define GL_OFFSET_TEXTURE_SCALE_NV 0x86E2 -#define GL_OFFSET_TEXTURE_BIAS_NV 0x86E3 -#define GL_OFFSET_TEXTURE_2D_MATRIX_NV GL_OFFSET_TEXTURE_MATRIX_NV -#define GL_OFFSET_TEXTURE_2D_SCALE_NV GL_OFFSET_TEXTURE_SCALE_NV -#define GL_OFFSET_TEXTURE_2D_BIAS_NV GL_OFFSET_TEXTURE_BIAS_NV -#define GL_PREVIOUS_TEXTURE_INPUT_NV 0x86E4 -#define GL_CONST_EYE_NV 0x86E5 -#define GL_PASS_THROUGH_NV 0x86E6 -#define GL_CULL_FRAGMENT_NV 0x86E7 -#define GL_OFFSET_TEXTURE_2D_NV 0x86E8 -#define GL_DEPENDENT_AR_TEXTURE_2D_NV 0x86E9 -#define GL_DEPENDENT_GB_TEXTURE_2D_NV 0x86EA -#define GL_DOT_PRODUCT_NV 0x86EC -#define GL_DOT_PRODUCT_DEPTH_REPLACE_NV 0x86ED -#define GL_DOT_PRODUCT_TEXTURE_2D_NV 0x86EE -#define GL_DOT_PRODUCT_TEXTURE_CUBE_MAP_NV 0x86F0 -#define GL_DOT_PRODUCT_DIFFUSE_CUBE_MAP_NV 0x86F1 -#define GL_DOT_PRODUCT_REFLECT_CUBE_MAP_NV 0x86F2 -#define GL_DOT_PRODUCT_CONST_EYE_REFLECT_CUBE_MAP_NV 0x86F3 -#define GL_HILO_NV 0x86F4 -#define GL_DSDT_NV 0x86F5 -#define GL_DSDT_MAG_NV 0x86F6 -#define GL_DSDT_MAG_VIB_NV 0x86F7 -#define GL_HILO16_NV 0x86F8 -#define GL_SIGNED_HILO_NV 0x86F9 -#define GL_SIGNED_HILO16_NV 0x86FA -#define GL_SIGNED_RGBA_NV 0x86FB -#define GL_SIGNED_RGBA8_NV 0x86FC -#define GL_SIGNED_RGB_NV 0x86FE -#define GL_SIGNED_RGB8_NV 0x86FF -#define GL_SIGNED_LUMINANCE_NV 0x8701 -#define GL_SIGNED_LUMINANCE8_NV 0x8702 -#define GL_SIGNED_LUMINANCE_ALPHA_NV 0x8703 -#define GL_SIGNED_LUMINANCE8_ALPHA8_NV 0x8704 -#define GL_SIGNED_ALPHA_NV 0x8705 -#define GL_SIGNED_ALPHA8_NV 0x8706 -#define GL_SIGNED_INTENSITY_NV 0x8707 -#define GL_SIGNED_INTENSITY8_NV 0x8708 -#define GL_DSDT8_NV 0x8709 -#define GL_DSDT8_MAG8_NV 0x870A -#define GL_DSDT8_MAG8_INTENSITY8_NV 0x870B -#define GL_SIGNED_RGB_UNSIGNED_ALPHA_NV 0x870C -#define GL_SIGNED_RGB8_UNSIGNED_ALPHA8_NV 0x870D -#define GL_HI_SCALE_NV 0x870E -#define GL_LO_SCALE_NV 0x870F -#define GL_DS_SCALE_NV 0x8710 -#define GL_DT_SCALE_NV 0x8711 -#define GL_MAGNITUDE_SCALE_NV 0x8712 -#define GL_VIBRANCE_SCALE_NV 0x8713 -#define GL_HI_BIAS_NV 0x8714 -#define GL_LO_BIAS_NV 0x8715 -#define GL_DS_BIAS_NV 0x8716 -#define GL_DT_BIAS_NV 0x8717 -#define GL_MAGNITUDE_BIAS_NV 0x8718 -#define GL_VIBRANCE_BIAS_NV 0x8719 -#define GL_TEXTURE_BORDER_VALUES_NV 0x871A -#define GL_TEXTURE_HI_SIZE_NV 0x871B -#define GL_TEXTURE_LO_SIZE_NV 0x871C -#define GL_TEXTURE_DS_SIZE_NV 0x871D -#define GL_TEXTURE_DT_SIZE_NV 0x871E -#define GL_TEXTURE_MAG_SIZE_NV 0x871F -#endif - -#ifndef GL_NV_texture_shader2 -#define GL_DOT_PRODUCT_TEXTURE_3D_NV 0x86EF -#endif - -#ifndef GL_NV_vertex_array_range2 -#define GL_VERTEX_ARRAY_RANGE_WITHOUT_FLUSH_NV 0x8533 -#endif - -#ifndef GL_NV_vertex_program -#define GL_VERTEX_PROGRAM_NV 0x8620 -#define GL_VERTEX_STATE_PROGRAM_NV 0x8621 -#define GL_ATTRIB_ARRAY_SIZE_NV 0x8623 -#define GL_ATTRIB_ARRAY_STRIDE_NV 0x8624 -#define GL_ATTRIB_ARRAY_TYPE_NV 0x8625 -#define GL_CURRENT_ATTRIB_NV 0x8626 -#define GL_PROGRAM_LENGTH_NV 0x8627 -#define GL_PROGRAM_STRING_NV 0x8628 -#define GL_MODELVIEW_PROJECTION_NV 0x8629 -#define GL_IDENTITY_NV 0x862A -#define GL_INVERSE_NV 0x862B -#define GL_TRANSPOSE_NV 0x862C -#define GL_INVERSE_TRANSPOSE_NV 0x862D -#define GL_MAX_TRACK_MATRIX_STACK_DEPTH_NV 0x862E -#define GL_MAX_TRACK_MATRICES_NV 0x862F -#define GL_MATRIX0_NV 0x8630 -#define GL_MATRIX1_NV 0x8631 -#define GL_MATRIX2_NV 0x8632 -#define GL_MATRIX3_NV 0x8633 -#define GL_MATRIX4_NV 0x8634 -#define GL_MATRIX5_NV 0x8635 -#define GL_MATRIX6_NV 0x8636 -#define GL_MATRIX7_NV 0x8637 -#define GL_CURRENT_MATRIX_STACK_DEPTH_NV 0x8640 -#define GL_CURRENT_MATRIX_NV 0x8641 -#define GL_VERTEX_PROGRAM_POINT_SIZE_NV 0x8642 -#define GL_VERTEX_PROGRAM_TWO_SIDE_NV 0x8643 -#define GL_PROGRAM_PARAMETER_NV 0x8644 -#define GL_ATTRIB_ARRAY_POINTER_NV 0x8645 -#define GL_PROGRAM_TARGET_NV 0x8646 -#define GL_PROGRAM_RESIDENT_NV 0x8647 -#define GL_TRACK_MATRIX_NV 0x8648 -#define GL_TRACK_MATRIX_TRANSFORM_NV 0x8649 -#define GL_VERTEX_PROGRAM_BINDING_NV 0x864A -#define GL_PROGRAM_ERROR_POSITION_NV 0x864B -#define GL_VERTEX_ATTRIB_ARRAY0_NV 0x8650 -#define GL_VERTEX_ATTRIB_ARRAY1_NV 0x8651 -#define GL_VERTEX_ATTRIB_ARRAY2_NV 0x8652 -#define GL_VERTEX_ATTRIB_ARRAY3_NV 0x8653 -#define GL_VERTEX_ATTRIB_ARRAY4_NV 0x8654 -#define GL_VERTEX_ATTRIB_ARRAY5_NV 0x8655 -#define GL_VERTEX_ATTRIB_ARRAY6_NV 0x8656 -#define GL_VERTEX_ATTRIB_ARRAY7_NV 0x8657 -#define GL_VERTEX_ATTRIB_ARRAY8_NV 0x8658 -#define GL_VERTEX_ATTRIB_ARRAY9_NV 0x8659 -#define GL_VERTEX_ATTRIB_ARRAY10_NV 0x865A -#define GL_VERTEX_ATTRIB_ARRAY11_NV 0x865B -#define GL_VERTEX_ATTRIB_ARRAY12_NV 0x865C -#define GL_VERTEX_ATTRIB_ARRAY13_NV 0x865D -#define GL_VERTEX_ATTRIB_ARRAY14_NV 0x865E -#define GL_VERTEX_ATTRIB_ARRAY15_NV 0x865F -#define GL_MAP1_VERTEX_ATTRIB0_4_NV 0x8660 -#define GL_MAP1_VERTEX_ATTRIB1_4_NV 0x8661 -#define GL_MAP1_VERTEX_ATTRIB2_4_NV 0x8662 -#define GL_MAP1_VERTEX_ATTRIB3_4_NV 0x8663 -#define GL_MAP1_VERTEX_ATTRIB4_4_NV 0x8664 -#define GL_MAP1_VERTEX_ATTRIB5_4_NV 0x8665 -#define GL_MAP1_VERTEX_ATTRIB6_4_NV 0x8666 -#define GL_MAP1_VERTEX_ATTRIB7_4_NV 0x8667 -#define GL_MAP1_VERTEX_ATTRIB8_4_NV 0x8668 -#define GL_MAP1_VERTEX_ATTRIB9_4_NV 0x8669 -#define GL_MAP1_VERTEX_ATTRIB10_4_NV 0x866A -#define GL_MAP1_VERTEX_ATTRIB11_4_NV 0x866B -#define GL_MAP1_VERTEX_ATTRIB12_4_NV 0x866C -#define GL_MAP1_VERTEX_ATTRIB13_4_NV 0x866D -#define GL_MAP1_VERTEX_ATTRIB14_4_NV 0x866E -#define GL_MAP1_VERTEX_ATTRIB15_4_NV 0x866F -#define GL_MAP2_VERTEX_ATTRIB0_4_NV 0x8670 -#define GL_MAP2_VERTEX_ATTRIB1_4_NV 0x8671 -#define GL_MAP2_VERTEX_ATTRIB2_4_NV 0x8672 -#define GL_MAP2_VERTEX_ATTRIB3_4_NV 0x8673 -#define GL_MAP2_VERTEX_ATTRIB4_4_NV 0x8674 -#define GL_MAP2_VERTEX_ATTRIB5_4_NV 0x8675 -#define GL_MAP2_VERTEX_ATTRIB6_4_NV 0x8676 -#define GL_MAP2_VERTEX_ATTRIB7_4_NV 0x8677 -#define GL_MAP2_VERTEX_ATTRIB8_4_NV 0x8678 -#define GL_MAP2_VERTEX_ATTRIB9_4_NV 0x8679 -#define GL_MAP2_VERTEX_ATTRIB10_4_NV 0x867A -#define GL_MAP2_VERTEX_ATTRIB11_4_NV 0x867B -#define GL_MAP2_VERTEX_ATTRIB12_4_NV 0x867C -#define GL_MAP2_VERTEX_ATTRIB13_4_NV 0x867D -#define GL_MAP2_VERTEX_ATTRIB14_4_NV 0x867E -#define GL_MAP2_VERTEX_ATTRIB15_4_NV 0x867F -#endif - -#ifndef GL_SGIX_texture_coordinate_clamp -#define GL_TEXTURE_MAX_CLAMP_S_SGIX 0x8369 -#define GL_TEXTURE_MAX_CLAMP_T_SGIX 0x836A -#define GL_TEXTURE_MAX_CLAMP_R_SGIX 0x836B -#endif - -#ifndef GL_SGIX_scalebias_hint -#define GL_SCALEBIAS_HINT_SGIX 0x8322 -#endif - -#ifndef GL_OML_interlace -#define GL_INTERLACE_OML 0x8980 -#define GL_INTERLACE_READ_OML 0x8981 -#endif - -#ifndef GL_OML_subsample -#define GL_FORMAT_SUBSAMPLE_24_24_OML 0x8982 -#define GL_FORMAT_SUBSAMPLE_244_244_OML 0x8983 -#endif - -#ifndef GL_OML_resample -#define GL_PACK_RESAMPLE_OML 0x8984 -#define GL_UNPACK_RESAMPLE_OML 0x8985 -#define GL_RESAMPLE_REPLICATE_OML 0x8986 -#define GL_RESAMPLE_ZERO_FILL_OML 0x8987 -#define GL_RESAMPLE_AVERAGE_OML 0x8988 -#define GL_RESAMPLE_DECIMATE_OML 0x8989 -#endif - -#ifndef GL_NV_copy_depth_to_color -#define GL_DEPTH_STENCIL_TO_RGBA_NV 0x886E -#define GL_DEPTH_STENCIL_TO_BGRA_NV 0x886F -#endif - -#ifndef GL_ATI_envmap_bumpmap -#define GL_BUMP_ROT_MATRIX_ATI 0x8775 -#define GL_BUMP_ROT_MATRIX_SIZE_ATI 0x8776 -#define GL_BUMP_NUM_TEX_UNITS_ATI 0x8777 -#define GL_BUMP_TEX_UNITS_ATI 0x8778 -#define GL_DUDV_ATI 0x8779 -#define GL_DU8DV8_ATI 0x877A -#define GL_BUMP_ENVMAP_ATI 0x877B -#define GL_BUMP_TARGET_ATI 0x877C -#endif - -#ifndef GL_ATI_fragment_shader -#define GL_FRAGMENT_SHADER_ATI 0x8920 -#define GL_REG_0_ATI 0x8921 -#define GL_REG_1_ATI 0x8922 -#define GL_REG_2_ATI 0x8923 -#define GL_REG_3_ATI 0x8924 -#define GL_REG_4_ATI 0x8925 -#define GL_REG_5_ATI 0x8926 -#define GL_REG_6_ATI 0x8927 -#define GL_REG_7_ATI 0x8928 -#define GL_REG_8_ATI 0x8929 -#define GL_REG_9_ATI 0x892A -#define GL_REG_10_ATI 0x892B -#define GL_REG_11_ATI 0x892C -#define GL_REG_12_ATI 0x892D -#define GL_REG_13_ATI 0x892E -#define GL_REG_14_ATI 0x892F -#define GL_REG_15_ATI 0x8930 -#define GL_REG_16_ATI 0x8931 -#define GL_REG_17_ATI 0x8932 -#define GL_REG_18_ATI 0x8933 -#define GL_REG_19_ATI 0x8934 -#define GL_REG_20_ATI 0x8935 -#define GL_REG_21_ATI 0x8936 -#define GL_REG_22_ATI 0x8937 -#define GL_REG_23_ATI 0x8938 -#define GL_REG_24_ATI 0x8939 -#define GL_REG_25_ATI 0x893A -#define GL_REG_26_ATI 0x893B -#define GL_REG_27_ATI 0x893C -#define GL_REG_28_ATI 0x893D -#define GL_REG_29_ATI 0x893E -#define GL_REG_30_ATI 0x893F -#define GL_REG_31_ATI 0x8940 -#define GL_CON_0_ATI 0x8941 -#define GL_CON_1_ATI 0x8942 -#define GL_CON_2_ATI 0x8943 -#define GL_CON_3_ATI 0x8944 -#define GL_CON_4_ATI 0x8945 -#define GL_CON_5_ATI 0x8946 -#define GL_CON_6_ATI 0x8947 -#define GL_CON_7_ATI 0x8948 -#define GL_CON_8_ATI 0x8949 -#define GL_CON_9_ATI 0x894A -#define GL_CON_10_ATI 0x894B -#define GL_CON_11_ATI 0x894C -#define GL_CON_12_ATI 0x894D -#define GL_CON_13_ATI 0x894E -#define GL_CON_14_ATI 0x894F -#define GL_CON_15_ATI 0x8950 -#define GL_CON_16_ATI 0x8951 -#define GL_CON_17_ATI 0x8952 -#define GL_CON_18_ATI 0x8953 -#define GL_CON_19_ATI 0x8954 -#define GL_CON_20_ATI 0x8955 -#define GL_CON_21_ATI 0x8956 -#define GL_CON_22_ATI 0x8957 -#define GL_CON_23_ATI 0x8958 -#define GL_CON_24_ATI 0x8959 -#define GL_CON_25_ATI 0x895A -#define GL_CON_26_ATI 0x895B -#define GL_CON_27_ATI 0x895C -#define GL_CON_28_ATI 0x895D -#define GL_CON_29_ATI 0x895E -#define GL_CON_30_ATI 0x895F -#define GL_CON_31_ATI 0x8960 -#define GL_MOV_ATI 0x8961 -#define GL_ADD_ATI 0x8963 -#define GL_MUL_ATI 0x8964 -#define GL_SUB_ATI 0x8965 -#define GL_DOT3_ATI 0x8966 -#define GL_DOT4_ATI 0x8967 -#define GL_MAD_ATI 0x8968 -#define GL_LERP_ATI 0x8969 -#define GL_CND_ATI 0x896A -#define GL_CND0_ATI 0x896B -#define GL_DOT2_ADD_ATI 0x896C -#define GL_SECONDARY_INTERPOLATOR_ATI 0x896D -#define GL_NUM_FRAGMENT_REGISTERS_ATI 0x896E -#define GL_NUM_FRAGMENT_CONSTANTS_ATI 0x896F -#define GL_NUM_PASSES_ATI 0x8970 -#define GL_NUM_INSTRUCTIONS_PER_PASS_ATI 0x8971 -#define GL_NUM_INSTRUCTIONS_TOTAL_ATI 0x8972 -#define GL_NUM_INPUT_INTERPOLATOR_COMPONENTS_ATI 0x8973 -#define GL_NUM_LOOPBACK_COMPONENTS_ATI 0x8974 -#define GL_COLOR_ALPHA_PAIRING_ATI 0x8975 -#define GL_SWIZZLE_STR_ATI 0x8976 -#define GL_SWIZZLE_STQ_ATI 0x8977 -#define GL_SWIZZLE_STR_DR_ATI 0x8978 -#define GL_SWIZZLE_STQ_DQ_ATI 0x8979 -#define GL_SWIZZLE_STRQ_ATI 0x897A -#define GL_SWIZZLE_STRQ_DQ_ATI 0x897B -#define GL_RED_BIT_ATI 0x00000001 -#define GL_GREEN_BIT_ATI 0x00000002 -#define GL_BLUE_BIT_ATI 0x00000004 -#define GL_2X_BIT_ATI 0x00000001 -#define GL_4X_BIT_ATI 0x00000002 -#define GL_8X_BIT_ATI 0x00000004 -#define GL_HALF_BIT_ATI 0x00000008 -#define GL_QUARTER_BIT_ATI 0x00000010 -#define GL_EIGHTH_BIT_ATI 0x00000020 -#define GL_SATURATE_BIT_ATI 0x00000040 -#define GL_COMP_BIT_ATI 0x00000002 -#define GL_NEGATE_BIT_ATI 0x00000004 -#define GL_BIAS_BIT_ATI 0x00000008 -#endif - -#ifndef GL_ATI_pn_triangles -#define GL_PN_TRIANGLES_ATI 0x87F0 -#define GL_MAX_PN_TRIANGLES_TESSELATION_LEVEL_ATI 0x87F1 -#define GL_PN_TRIANGLES_POINT_MODE_ATI 0x87F2 -#define GL_PN_TRIANGLES_NORMAL_MODE_ATI 0x87F3 -#define GL_PN_TRIANGLES_TESSELATION_LEVEL_ATI 0x87F4 -#define GL_PN_TRIANGLES_POINT_MODE_LINEAR_ATI 0x87F5 -#define GL_PN_TRIANGLES_POINT_MODE_CUBIC_ATI 0x87F6 -#define GL_PN_TRIANGLES_NORMAL_MODE_LINEAR_ATI 0x87F7 -#define GL_PN_TRIANGLES_NORMAL_MODE_QUADRATIC_ATI 0x87F8 -#endif - -#ifndef GL_ATI_vertex_array_object -#define GL_STATIC_ATI 0x8760 -#define GL_DYNAMIC_ATI 0x8761 -#define GL_PRESERVE_ATI 0x8762 -#define GL_DISCARD_ATI 0x8763 -#define GL_OBJECT_BUFFER_SIZE_ATI 0x8764 -#define GL_OBJECT_BUFFER_USAGE_ATI 0x8765 -#define GL_ARRAY_OBJECT_BUFFER_ATI 0x8766 -#define GL_ARRAY_OBJECT_OFFSET_ATI 0x8767 -#endif - -#ifndef GL_EXT_vertex_shader -#define GL_VERTEX_SHADER_EXT 0x8780 -#define GL_VERTEX_SHADER_BINDING_EXT 0x8781 -#define GL_OP_INDEX_EXT 0x8782 -#define GL_OP_NEGATE_EXT 0x8783 -#define GL_OP_DOT3_EXT 0x8784 -#define GL_OP_DOT4_EXT 0x8785 -#define GL_OP_MUL_EXT 0x8786 -#define GL_OP_ADD_EXT 0x8787 -#define GL_OP_MADD_EXT 0x8788 -#define GL_OP_FRAC_EXT 0x8789 -#define GL_OP_MAX_EXT 0x878A -#define GL_OP_MIN_EXT 0x878B -#define GL_OP_SET_GE_EXT 0x878C -#define GL_OP_SET_LT_EXT 0x878D -#define GL_OP_CLAMP_EXT 0x878E -#define GL_OP_FLOOR_EXT 0x878F -#define GL_OP_ROUND_EXT 0x8790 -#define GL_OP_EXP_BASE_2_EXT 0x8791 -#define GL_OP_LOG_BASE_2_EXT 0x8792 -#define GL_OP_POWER_EXT 0x8793 -#define GL_OP_RECIP_EXT 0x8794 -#define GL_OP_RECIP_SQRT_EXT 0x8795 -#define GL_OP_SUB_EXT 0x8796 -#define GL_OP_CROSS_PRODUCT_EXT 0x8797 -#define GL_OP_MULTIPLY_MATRIX_EXT 0x8798 -#define GL_OP_MOV_EXT 0x8799 -#define GL_OUTPUT_VERTEX_EXT 0x879A -#define GL_OUTPUT_COLOR0_EXT 0x879B -#define GL_OUTPUT_COLOR1_EXT 0x879C -#define GL_OUTPUT_TEXTURE_COORD0_EXT 0x879D -#define GL_OUTPUT_TEXTURE_COORD1_EXT 0x879E -#define GL_OUTPUT_TEXTURE_COORD2_EXT 0x879F -#define GL_OUTPUT_TEXTURE_COORD3_EXT 0x87A0 -#define GL_OUTPUT_TEXTURE_COORD4_EXT 0x87A1 -#define GL_OUTPUT_TEXTURE_COORD5_EXT 0x87A2 -#define GL_OUTPUT_TEXTURE_COORD6_EXT 0x87A3 -#define GL_OUTPUT_TEXTURE_COORD7_EXT 0x87A4 -#define GL_OUTPUT_TEXTURE_COORD8_EXT 0x87A5 -#define GL_OUTPUT_TEXTURE_COORD9_EXT 0x87A6 -#define GL_OUTPUT_TEXTURE_COORD10_EXT 0x87A7 -#define GL_OUTPUT_TEXTURE_COORD11_EXT 0x87A8 -#define GL_OUTPUT_TEXTURE_COORD12_EXT 0x87A9 -#define GL_OUTPUT_TEXTURE_COORD13_EXT 0x87AA -#define GL_OUTPUT_TEXTURE_COORD14_EXT 0x87AB -#define GL_OUTPUT_TEXTURE_COORD15_EXT 0x87AC -#define GL_OUTPUT_TEXTURE_COORD16_EXT 0x87AD -#define GL_OUTPUT_TEXTURE_COORD17_EXT 0x87AE -#define GL_OUTPUT_TEXTURE_COORD18_EXT 0x87AF -#define GL_OUTPUT_TEXTURE_COORD19_EXT 0x87B0 -#define GL_OUTPUT_TEXTURE_COORD20_EXT 0x87B1 -#define GL_OUTPUT_TEXTURE_COORD21_EXT 0x87B2 -#define GL_OUTPUT_TEXTURE_COORD22_EXT 0x87B3 -#define GL_OUTPUT_TEXTURE_COORD23_EXT 0x87B4 -#define GL_OUTPUT_TEXTURE_COORD24_EXT 0x87B5 -#define GL_OUTPUT_TEXTURE_COORD25_EXT 0x87B6 -#define GL_OUTPUT_TEXTURE_COORD26_EXT 0x87B7 -#define GL_OUTPUT_TEXTURE_COORD27_EXT 0x87B8 -#define GL_OUTPUT_TEXTURE_COORD28_EXT 0x87B9 -#define GL_OUTPUT_TEXTURE_COORD29_EXT 0x87BA -#define GL_OUTPUT_TEXTURE_COORD30_EXT 0x87BB -#define GL_OUTPUT_TEXTURE_COORD31_EXT 0x87BC -#define GL_OUTPUT_FOG_EXT 0x87BD -#define GL_SCALAR_EXT 0x87BE -#define GL_VECTOR_EXT 0x87BF -#define GL_MATRIX_EXT 0x87C0 -#define GL_VARIANT_EXT 0x87C1 -#define GL_INVARIANT_EXT 0x87C2 -#define GL_LOCAL_CONSTANT_EXT 0x87C3 -#define GL_LOCAL_EXT 0x87C4 -#define GL_MAX_VERTEX_SHADER_INSTRUCTIONS_EXT 0x87C5 -#define GL_MAX_VERTEX_SHADER_VARIANTS_EXT 0x87C6 -#define GL_MAX_VERTEX_SHADER_INVARIANTS_EXT 0x87C7 -#define GL_MAX_VERTEX_SHADER_LOCAL_CONSTANTS_EXT 0x87C8 -#define GL_MAX_VERTEX_SHADER_LOCALS_EXT 0x87C9 -#define GL_MAX_OPTIMIZED_VERTEX_SHADER_INSTRUCTIONS_EXT 0x87CA -#define GL_MAX_OPTIMIZED_VERTEX_SHADER_VARIANTS_EXT 0x87CB -#define GL_MAX_OPTIMIZED_VERTEX_SHADER_LOCAL_CONSTANTS_EXT 0x87CC -#define GL_MAX_OPTIMIZED_VERTEX_SHADER_INVARIANTS_EXT 0x87CD -#define GL_MAX_OPTIMIZED_VERTEX_SHADER_LOCALS_EXT 0x87CE -#define GL_VERTEX_SHADER_INSTRUCTIONS_EXT 0x87CF -#define GL_VERTEX_SHADER_VARIANTS_EXT 0x87D0 -#define GL_VERTEX_SHADER_INVARIANTS_EXT 0x87D1 -#define GL_VERTEX_SHADER_LOCAL_CONSTANTS_EXT 0x87D2 -#define GL_VERTEX_SHADER_LOCALS_EXT 0x87D3 -#define GL_VERTEX_SHADER_OPTIMIZED_EXT 0x87D4 -#define GL_X_EXT 0x87D5 -#define GL_Y_EXT 0x87D6 -#define GL_Z_EXT 0x87D7 -#define GL_W_EXT 0x87D8 -#define GL_NEGATIVE_X_EXT 0x87D9 -#define GL_NEGATIVE_Y_EXT 0x87DA -#define GL_NEGATIVE_Z_EXT 0x87DB -#define GL_NEGATIVE_W_EXT 0x87DC -#define GL_ZERO_EXT 0x87DD -#define GL_ONE_EXT 0x87DE -#define GL_NEGATIVE_ONE_EXT 0x87DF -#define GL_NORMALIZED_RANGE_EXT 0x87E0 -#define GL_FULL_RANGE_EXT 0x87E1 -#define GL_CURRENT_VERTEX_EXT 0x87E2 -#define GL_MVP_MATRIX_EXT 0x87E3 -#define GL_VARIANT_VALUE_EXT 0x87E4 -#define GL_VARIANT_DATATYPE_EXT 0x87E5 -#define GL_VARIANT_ARRAY_STRIDE_EXT 0x87E6 -#define GL_VARIANT_ARRAY_TYPE_EXT 0x87E7 -#define GL_VARIANT_ARRAY_EXT 0x87E8 -#define GL_VARIANT_ARRAY_POINTER_EXT 0x87E9 -#define GL_INVARIANT_VALUE_EXT 0x87EA -#define GL_INVARIANT_DATATYPE_EXT 0x87EB -#define GL_LOCAL_CONSTANT_VALUE_EXT 0x87EC -#define GL_LOCAL_CONSTANT_DATATYPE_EXT 0x87ED -#endif - -#ifndef GL_ATI_vertex_streams -#define GL_MAX_VERTEX_STREAMS_ATI 0x876B -#define GL_VERTEX_STREAM0_ATI 0x876C -#define GL_VERTEX_STREAM1_ATI 0x876D -#define GL_VERTEX_STREAM2_ATI 0x876E -#define GL_VERTEX_STREAM3_ATI 0x876F -#define GL_VERTEX_STREAM4_ATI 0x8770 -#define GL_VERTEX_STREAM5_ATI 0x8771 -#define GL_VERTEX_STREAM6_ATI 0x8772 -#define GL_VERTEX_STREAM7_ATI 0x8773 -#define GL_VERTEX_SOURCE_ATI 0x8774 -#endif - -#ifndef GL_ATI_element_array -#define GL_ELEMENT_ARRAY_ATI 0x8768 -#define GL_ELEMENT_ARRAY_TYPE_ATI 0x8769 -#define GL_ELEMENT_ARRAY_POINTER_ATI 0x876A -#endif - -#ifndef GL_SUN_mesh_array -#define GL_QUAD_MESH_SUN 0x8614 -#define GL_TRIANGLE_MESH_SUN 0x8615 -#endif - -#ifndef GL_SUN_slice_accum -#define GL_SLICE_ACCUM_SUN 0x85CC -#endif - -#ifndef GL_NV_multisample_filter_hint -#define GL_MULTISAMPLE_FILTER_HINT_NV 0x8534 -#endif - -#ifndef GL_NV_depth_clamp -#define GL_DEPTH_CLAMP_NV 0x864F -#endif - -#ifndef GL_NV_occlusion_query -#define GL_PIXEL_COUNTER_BITS_NV 0x8864 -#define GL_CURRENT_OCCLUSION_QUERY_ID_NV 0x8865 -#define GL_PIXEL_COUNT_NV 0x8866 -#define GL_PIXEL_COUNT_AVAILABLE_NV 0x8867 -#endif - -#ifndef GL_NV_point_sprite -#define GL_POINT_SPRITE_NV 0x8861 -#define GL_COORD_REPLACE_NV 0x8862 -#define GL_POINT_SPRITE_R_MODE_NV 0x8863 -#endif - -#ifndef GL_NV_texture_shader3 -#define GL_OFFSET_PROJECTIVE_TEXTURE_2D_NV 0x8850 -#define GL_OFFSET_PROJECTIVE_TEXTURE_2D_SCALE_NV 0x8851 -#define GL_OFFSET_PROJECTIVE_TEXTURE_RECTANGLE_NV 0x8852 -#define GL_OFFSET_PROJECTIVE_TEXTURE_RECTANGLE_SCALE_NV 0x8853 -#define GL_OFFSET_HILO_TEXTURE_2D_NV 0x8854 -#define GL_OFFSET_HILO_TEXTURE_RECTANGLE_NV 0x8855 -#define GL_OFFSET_HILO_PROJECTIVE_TEXTURE_2D_NV 0x8856 -#define GL_OFFSET_HILO_PROJECTIVE_TEXTURE_RECTANGLE_NV 0x8857 -#define GL_DEPENDENT_HILO_TEXTURE_2D_NV 0x8858 -#define GL_DEPENDENT_RGB_TEXTURE_3D_NV 0x8859 -#define GL_DEPENDENT_RGB_TEXTURE_CUBE_MAP_NV 0x885A -#define GL_DOT_PRODUCT_PASS_THROUGH_NV 0x885B -#define GL_DOT_PRODUCT_TEXTURE_1D_NV 0x885C -#define GL_DOT_PRODUCT_AFFINE_DEPTH_REPLACE_NV 0x885D -#define GL_HILO8_NV 0x885E -#define GL_SIGNED_HILO8_NV 0x885F -#define GL_FORCE_BLUE_TO_ONE_NV 0x8860 -#endif - -#ifndef GL_NV_vertex_program1_1 -#endif - -#ifndef GL_EXT_shadow_funcs -#endif - -#ifndef GL_EXT_stencil_two_side -#define GL_STENCIL_TEST_TWO_SIDE_EXT 0x8910 -#define GL_ACTIVE_STENCIL_FACE_EXT 0x8911 -#endif - -#ifndef GL_ATI_text_fragment_shader -#define GL_TEXT_FRAGMENT_SHADER_ATI 0x8200 -#endif - -#ifndef GL_APPLE_client_storage -#define GL_UNPACK_CLIENT_STORAGE_APPLE 0x85B2 -#endif - -#ifndef GL_APPLE_element_array -#define GL_ELEMENT_ARRAY_APPLE 0x8768 -#define GL_ELEMENT_ARRAY_TYPE_APPLE 0x8769 -#define GL_ELEMENT_ARRAY_POINTER_APPLE 0x876A -#endif - -#ifndef GL_APPLE_fence -#define GL_DRAW_PIXELS_APPLE 0x8A0A -#define GL_FENCE_APPLE 0x8A0B -#endif - -#ifndef GL_APPLE_vertex_array_object -#define GL_VERTEX_ARRAY_BINDING_APPLE 0x85B5 -#endif - -#ifndef GL_APPLE_vertex_array_range -#define GL_VERTEX_ARRAY_RANGE_APPLE 0x851D -#define GL_VERTEX_ARRAY_RANGE_LENGTH_APPLE 0x851E -#define GL_VERTEX_ARRAY_STORAGE_HINT_APPLE 0x851F -#define GL_VERTEX_ARRAY_RANGE_POINTER_APPLE 0x8521 -#define GL_STORAGE_CACHED_APPLE 0x85BE -#define GL_STORAGE_SHARED_APPLE 0x85BF -#endif - -#ifndef GL_APPLE_ycbcr_422 -#define GL_YCBCR_422_APPLE 0x85B9 -#define GL_UNSIGNED_SHORT_8_8_APPLE 0x85BA -#define GL_UNSIGNED_SHORT_8_8_REV_APPLE 0x85BB -#endif - -#ifndef GL_S3_s3tc -#define GL_RGB_S3TC 0x83A0 -#define GL_RGB4_S3TC 0x83A1 -#define GL_RGBA_S3TC 0x83A2 -#define GL_RGBA4_S3TC 0x83A3 -#endif - -#ifndef GL_ATI_draw_buffers -#define GL_MAX_DRAW_BUFFERS_ATI 0x8824 -#define GL_DRAW_BUFFER0_ATI 0x8825 -#define GL_DRAW_BUFFER1_ATI 0x8826 -#define GL_DRAW_BUFFER2_ATI 0x8827 -#define GL_DRAW_BUFFER3_ATI 0x8828 -#define GL_DRAW_BUFFER4_ATI 0x8829 -#define GL_DRAW_BUFFER5_ATI 0x882A -#define GL_DRAW_BUFFER6_ATI 0x882B -#define GL_DRAW_BUFFER7_ATI 0x882C -#define GL_DRAW_BUFFER8_ATI 0x882D -#define GL_DRAW_BUFFER9_ATI 0x882E -#define GL_DRAW_BUFFER10_ATI 0x882F -#define GL_DRAW_BUFFER11_ATI 0x8830 -#define GL_DRAW_BUFFER12_ATI 0x8831 -#define GL_DRAW_BUFFER13_ATI 0x8832 -#define GL_DRAW_BUFFER14_ATI 0x8833 -#define GL_DRAW_BUFFER15_ATI 0x8834 -#endif - -#ifndef GL_ATI_pixel_format_float -#define GL_TYPE_RGBA_FLOAT_ATI 0x8820 -#define GL_COLOR_CLEAR_UNCLAMPED_VALUE_ATI 0x8835 -#endif - -#ifndef GL_ATI_texture_env_combine3 -#define GL_MODULATE_ADD_ATI 0x8744 -#define GL_MODULATE_SIGNED_ADD_ATI 0x8745 -#define GL_MODULATE_SUBTRACT_ATI 0x8746 -#endif - -#ifndef GL_ATI_texture_float -#define GL_RGBA_FLOAT32_ATI 0x8814 -#define GL_RGB_FLOAT32_ATI 0x8815 -#define GL_ALPHA_FLOAT32_ATI 0x8816 -#define GL_INTENSITY_FLOAT32_ATI 0x8817 -#define GL_LUMINANCE_FLOAT32_ATI 0x8818 -#define GL_LUMINANCE_ALPHA_FLOAT32_ATI 0x8819 -#define GL_RGBA_FLOAT16_ATI 0x881A -#define GL_RGB_FLOAT16_ATI 0x881B -#define GL_ALPHA_FLOAT16_ATI 0x881C -#define GL_INTENSITY_FLOAT16_ATI 0x881D -#define GL_LUMINANCE_FLOAT16_ATI 0x881E -#define GL_LUMINANCE_ALPHA_FLOAT16_ATI 0x881F -#endif - -#ifndef GL_NV_float_buffer -#define GL_FLOAT_R_NV 0x8880 -#define GL_FLOAT_RG_NV 0x8881 -#define GL_FLOAT_RGB_NV 0x8882 -#define GL_FLOAT_RGBA_NV 0x8883 -#define GL_FLOAT_R16_NV 0x8884 -#define GL_FLOAT_R32_NV 0x8885 -#define GL_FLOAT_RG16_NV 0x8886 -#define GL_FLOAT_RG32_NV 0x8887 -#define GL_FLOAT_RGB16_NV 0x8888 -#define GL_FLOAT_RGB32_NV 0x8889 -#define GL_FLOAT_RGBA16_NV 0x888A -#define GL_FLOAT_RGBA32_NV 0x888B -#define GL_TEXTURE_FLOAT_COMPONENTS_NV 0x888C -#define GL_FLOAT_CLEAR_COLOR_VALUE_NV 0x888D -#define GL_FLOAT_RGBA_MODE_NV 0x888E -#endif - -#ifndef GL_NV_fragment_program -#define GL_MAX_FRAGMENT_PROGRAM_LOCAL_PARAMETERS_NV 0x8868 -#define GL_FRAGMENT_PROGRAM_NV 0x8870 -#define GL_MAX_TEXTURE_COORDS_NV 0x8871 -#define GL_MAX_TEXTURE_IMAGE_UNITS_NV 0x8872 -#define GL_FRAGMENT_PROGRAM_BINDING_NV 0x8873 -#define GL_PROGRAM_ERROR_STRING_NV 0x8874 -#endif - -#ifndef GL_NV_half_float -#define GL_HALF_FLOAT_NV 0x140B -#endif - -#ifndef GL_NV_pixel_data_range -#define GL_WRITE_PIXEL_DATA_RANGE_NV 0x8878 -#define GL_READ_PIXEL_DATA_RANGE_NV 0x8879 -#define GL_WRITE_PIXEL_DATA_RANGE_LENGTH_NV 0x887A -#define GL_READ_PIXEL_DATA_RANGE_LENGTH_NV 0x887B -#define GL_WRITE_PIXEL_DATA_RANGE_POINTER_NV 0x887C -#define GL_READ_PIXEL_DATA_RANGE_POINTER_NV 0x887D -#endif - -#ifndef GL_NV_primitive_restart -#define GL_PRIMITIVE_RESTART_NV 0x8558 -#define GL_PRIMITIVE_RESTART_INDEX_NV 0x8559 -#endif - -#ifndef GL_NV_texture_expand_normal -#define GL_TEXTURE_UNSIGNED_REMAP_MODE_NV 0x888F -#endif - -#ifndef GL_NV_vertex_program2 -#endif - -#ifndef GL_ATI_map_object_buffer -#endif - -#ifndef GL_ATI_separate_stencil -#define GL_STENCIL_BACK_FUNC_ATI 0x8800 -#define GL_STENCIL_BACK_FAIL_ATI 0x8801 -#define GL_STENCIL_BACK_PASS_DEPTH_FAIL_ATI 0x8802 -#define GL_STENCIL_BACK_PASS_DEPTH_PASS_ATI 0x8803 -#endif - -#ifndef GL_ATI_vertex_attrib_array_object -#endif - -#ifndef GL_OES_read_format -#define GL_IMPLEMENTATION_COLOR_READ_TYPE_OES 0x8B9A -#define GL_IMPLEMENTATION_COLOR_READ_FORMAT_OES 0x8B9B -#endif - -#ifndef GL_EXT_depth_bounds_test -#define GL_DEPTH_BOUNDS_TEST_EXT 0x8890 -#define GL_DEPTH_BOUNDS_EXT 0x8891 -#endif - -#ifndef GL_EXT_texture_mirror_clamp -#define GL_MIRROR_CLAMP_EXT 0x8742 -#define GL_MIRROR_CLAMP_TO_EDGE_EXT 0x8743 -#define GL_MIRROR_CLAMP_TO_BORDER_EXT 0x8912 -#endif - -#ifndef GL_EXT_blend_equation_separate -#define GL_BLEND_EQUATION_RGB_EXT GL_BLEND_EQUATION -#define GL_BLEND_EQUATION_ALPHA_EXT 0x883D -#endif - -#ifndef GL_MESA_pack_invert -#define GL_PACK_INVERT_MESA 0x8758 -#endif - -#ifndef GL_MESA_ycbcr_texture -#define GL_UNSIGNED_SHORT_8_8_MESA 0x85BA -#define GL_UNSIGNED_SHORT_8_8_REV_MESA 0x85BB -#define GL_YCBCR_MESA 0x8757 -#endif - -#ifndef GL_EXT_pixel_buffer_object -#define GL_PIXEL_PACK_BUFFER_EXT 0x88EB -#define GL_PIXEL_UNPACK_BUFFER_EXT 0x88EC -#define GL_PIXEL_PACK_BUFFER_BINDING_EXT 0x88ED -#define GL_PIXEL_UNPACK_BUFFER_BINDING_EXT 0x88EF -#endif - -#ifndef GL_NV_fragment_program_option -#endif - -#ifndef GL_NV_fragment_program2 -#define GL_MAX_PROGRAM_EXEC_INSTRUCTIONS_NV 0x88F4 -#define GL_MAX_PROGRAM_CALL_DEPTH_NV 0x88F5 -#define GL_MAX_PROGRAM_IF_DEPTH_NV 0x88F6 -#define GL_MAX_PROGRAM_LOOP_DEPTH_NV 0x88F7 -#define GL_MAX_PROGRAM_LOOP_COUNT_NV 0x88F8 -#endif - -#ifndef GL_NV_vertex_program2_option -/* reuse GL_MAX_PROGRAM_EXEC_INSTRUCTIONS_NV */ -/* reuse GL_MAX_PROGRAM_CALL_DEPTH_NV */ -#endif - -#ifndef GL_NV_vertex_program3 -/* reuse GL_MAX_VERTEX_TEXTURE_IMAGE_UNITS_ARB */ -#endif - -#ifndef GL_EXT_framebuffer_object -#define GL_INVALID_FRAMEBUFFER_OPERATION_EXT 0x0506 -#define GL_MAX_RENDERBUFFER_SIZE_EXT 0x84E8 -#define GL_FRAMEBUFFER_BINDING_EXT 0x8CA6 -#define GL_RENDERBUFFER_BINDING_EXT 0x8CA7 -#define GL_FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE_EXT 0x8CD0 -#define GL_FRAMEBUFFER_ATTACHMENT_OBJECT_NAME_EXT 0x8CD1 -#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL_EXT 0x8CD2 -#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE_EXT 0x8CD3 -#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_3D_ZOFFSET_EXT 0x8CD4 -#define GL_FRAMEBUFFER_COMPLETE_EXT 0x8CD5 -#define GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT_EXT 0x8CD6 -#define GL_FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT_EXT 0x8CD7 -#define GL_FRAMEBUFFER_INCOMPLETE_DIMENSIONS_EXT 0x8CD9 -#define GL_FRAMEBUFFER_INCOMPLETE_FORMATS_EXT 0x8CDA -#define GL_FRAMEBUFFER_INCOMPLETE_DRAW_BUFFER_EXT 0x8CDB -#define GL_FRAMEBUFFER_INCOMPLETE_READ_BUFFER_EXT 0x8CDC -#define GL_FRAMEBUFFER_UNSUPPORTED_EXT 0x8CDD -#define GL_MAX_COLOR_ATTACHMENTS_EXT 0x8CDF -#define GL_COLOR_ATTACHMENT0_EXT 0x8CE0 -#define GL_COLOR_ATTACHMENT1_EXT 0x8CE1 -#define GL_COLOR_ATTACHMENT2_EXT 0x8CE2 -#define GL_COLOR_ATTACHMENT3_EXT 0x8CE3 -#define GL_COLOR_ATTACHMENT4_EXT 0x8CE4 -#define GL_COLOR_ATTACHMENT5_EXT 0x8CE5 -#define GL_COLOR_ATTACHMENT6_EXT 0x8CE6 -#define GL_COLOR_ATTACHMENT7_EXT 0x8CE7 -#define GL_COLOR_ATTACHMENT8_EXT 0x8CE8 -#define GL_COLOR_ATTACHMENT9_EXT 0x8CE9 -#define GL_COLOR_ATTACHMENT10_EXT 0x8CEA -#define GL_COLOR_ATTACHMENT11_EXT 0x8CEB -#define GL_COLOR_ATTACHMENT12_EXT 0x8CEC -#define GL_COLOR_ATTACHMENT13_EXT 0x8CED -#define GL_COLOR_ATTACHMENT14_EXT 0x8CEE -#define GL_COLOR_ATTACHMENT15_EXT 0x8CEF -#define GL_DEPTH_ATTACHMENT_EXT 0x8D00 -#define GL_STENCIL_ATTACHMENT_EXT 0x8D20 -#define GL_FRAMEBUFFER_EXT 0x8D40 -#define GL_RENDERBUFFER_EXT 0x8D41 -#define GL_RENDERBUFFER_WIDTH_EXT 0x8D42 -#define GL_RENDERBUFFER_HEIGHT_EXT 0x8D43 -#define GL_RENDERBUFFER_INTERNAL_FORMAT_EXT 0x8D44 -#define GL_STENCIL_INDEX1_EXT 0x8D46 -#define GL_STENCIL_INDEX4_EXT 0x8D47 -#define GL_STENCIL_INDEX8_EXT 0x8D48 -#define GL_STENCIL_INDEX16_EXT 0x8D49 -#define GL_RENDERBUFFER_RED_SIZE_EXT 0x8D50 -#define GL_RENDERBUFFER_GREEN_SIZE_EXT 0x8D51 -#define GL_RENDERBUFFER_BLUE_SIZE_EXT 0x8D52 -#define GL_RENDERBUFFER_ALPHA_SIZE_EXT 0x8D53 -#define GL_RENDERBUFFER_DEPTH_SIZE_EXT 0x8D54 -#define GL_RENDERBUFFER_STENCIL_SIZE_EXT 0x8D55 -#endif - -#ifndef GL_GREMEDY_string_marker -#endif - -#ifndef GL_EXT_packed_depth_stencil -#define GL_DEPTH_STENCIL_EXT 0x84F9 -#define GL_UNSIGNED_INT_24_8_EXT 0x84FA -#define GL_DEPTH24_STENCIL8_EXT 0x88F0 -#define GL_TEXTURE_STENCIL_SIZE_EXT 0x88F1 -#endif - -#ifndef GL_EXT_stencil_clear_tag -#define GL_STENCIL_TAG_BITS_EXT 0x88F2 -#define GL_STENCIL_CLEAR_TAG_VALUE_EXT 0x88F3 -#endif - -#ifndef GL_EXT_texture_sRGB -#define GL_SRGB_EXT 0x8C40 -#define GL_SRGB8_EXT 0x8C41 -#define GL_SRGB_ALPHA_EXT 0x8C42 -#define GL_SRGB8_ALPHA8_EXT 0x8C43 -#define GL_SLUMINANCE_ALPHA_EXT 0x8C44 -#define GL_SLUMINANCE8_ALPHA8_EXT 0x8C45 -#define GL_SLUMINANCE_EXT 0x8C46 -#define GL_SLUMINANCE8_EXT 0x8C47 -#define GL_COMPRESSED_SRGB_EXT 0x8C48 -#define GL_COMPRESSED_SRGB_ALPHA_EXT 0x8C49 -#define GL_COMPRESSED_SLUMINANCE_EXT 0x8C4A -#define GL_COMPRESSED_SLUMINANCE_ALPHA_EXT 0x8C4B -#define GL_COMPRESSED_SRGB_S3TC_DXT1_EXT 0x8C4C -#define GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT1_EXT 0x8C4D -#define GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT3_EXT 0x8C4E -#define GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT5_EXT 0x8C4F -#endif - -#ifndef GL_EXT_framebuffer_blit -#define GL_READ_FRAMEBUFFER_EXT 0x8CA8 -#define GL_DRAW_FRAMEBUFFER_EXT 0x8CA9 -#define GL_DRAW_FRAMEBUFFER_BINDING_EXT GL_FRAMEBUFFER_BINDING_EXT -#define GL_READ_FRAMEBUFFER_BINDING_EXT 0x8CAA -#endif - -#ifndef GL_EXT_framebuffer_multisample -#define GL_RENDERBUFFER_SAMPLES_EXT 0x8CAB -#define GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE_EXT 0x8D56 -#define GL_MAX_SAMPLES_EXT 0x8D57 -#endif - -#ifndef GL_MESAX_texture_stack -#define GL_TEXTURE_1D_STACK_MESAX 0x8759 -#define GL_TEXTURE_2D_STACK_MESAX 0x875A -#define GL_PROXY_TEXTURE_1D_STACK_MESAX 0x875B -#define GL_PROXY_TEXTURE_2D_STACK_MESAX 0x875C -#define GL_TEXTURE_1D_STACK_BINDING_MESAX 0x875D -#define GL_TEXTURE_2D_STACK_BINDING_MESAX 0x875E -#endif - -#ifndef GL_EXT_timer_query -#define GL_TIME_ELAPSED_EXT 0x88BF -#endif - -#ifndef GL_EXT_gpu_program_parameters -#endif - -#ifndef GL_APPLE_flush_buffer_range -#define GL_BUFFER_SERIALIZED_MODIFY_APPLE 0x8A12 -#define GL_BUFFER_FLUSHING_UNMAP_APPLE 0x8A13 -#endif - -#ifndef GL_NV_gpu_program4 -#define GL_MIN_PROGRAM_TEXEL_OFFSET_NV 0x8904 -#define GL_MAX_PROGRAM_TEXEL_OFFSET_NV 0x8905 -#define GL_PROGRAM_ATTRIB_COMPONENTS_NV 0x8906 -#define GL_PROGRAM_RESULT_COMPONENTS_NV 0x8907 -#define GL_MAX_PROGRAM_ATTRIB_COMPONENTS_NV 0x8908 -#define GL_MAX_PROGRAM_RESULT_COMPONENTS_NV 0x8909 -#define GL_MAX_PROGRAM_GENERIC_ATTRIBS_NV 0x8DA5 -#define GL_MAX_PROGRAM_GENERIC_RESULTS_NV 0x8DA6 -#endif - -#ifndef GL_NV_geometry_program4 -#define GL_LINES_ADJACENCY_EXT 0x000A -#define GL_LINE_STRIP_ADJACENCY_EXT 0x000B -#define GL_TRIANGLES_ADJACENCY_EXT 0x000C -#define GL_TRIANGLE_STRIP_ADJACENCY_EXT 0x000D -#define GL_GEOMETRY_PROGRAM_NV 0x8C26 -#define GL_MAX_PROGRAM_OUTPUT_VERTICES_NV 0x8C27 -#define GL_MAX_PROGRAM_TOTAL_OUTPUT_COMPONENTS_NV 0x8C28 -#define GL_GEOMETRY_VERTICES_OUT_EXT 0x8DDA -#define GL_GEOMETRY_INPUT_TYPE_EXT 0x8DDB -#define GL_GEOMETRY_OUTPUT_TYPE_EXT 0x8DDC -#define GL_MAX_GEOMETRY_TEXTURE_IMAGE_UNITS_EXT 0x8C29 -#define GL_FRAMEBUFFER_ATTACHMENT_LAYERED_EXT 0x8DA7 -#define GL_FRAMEBUFFER_INCOMPLETE_LAYER_TARGETS_EXT 0x8DA8 -#define GL_FRAMEBUFFER_INCOMPLETE_LAYER_COUNT_EXT 0x8DA9 -#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER_EXT 0x8CD4 -#define GL_PROGRAM_POINT_SIZE_EXT 0x8642 -#endif - -#ifndef GL_EXT_geometry_shader4 -#define GL_GEOMETRY_SHADER_EXT 0x8DD9 -/* reuse GL_GEOMETRY_VERTICES_OUT_EXT */ -/* reuse GL_GEOMETRY_INPUT_TYPE_EXT */ -/* reuse GL_GEOMETRY_OUTPUT_TYPE_EXT */ -/* reuse GL_MAX_GEOMETRY_TEXTURE_IMAGE_UNITS_EXT */ -#define GL_MAX_GEOMETRY_VARYING_COMPONENTS_EXT 0x8DDD -#define GL_MAX_VERTEX_VARYING_COMPONENTS_EXT 0x8DDE -#define GL_MAX_VARYING_COMPONENTS_EXT 0x8B4B -#define GL_MAX_GEOMETRY_UNIFORM_COMPONENTS_EXT 0x8DDF -#define GL_MAX_GEOMETRY_OUTPUT_VERTICES_EXT 0x8DE0 -#define GL_MAX_GEOMETRY_TOTAL_OUTPUT_COMPONENTS_EXT 0x8DE1 -/* reuse GL_LINES_ADJACENCY_EXT */ -/* reuse GL_LINE_STRIP_ADJACENCY_EXT */ -/* reuse GL_TRIANGLES_ADJACENCY_EXT */ -/* reuse GL_TRIANGLE_STRIP_ADJACENCY_EXT */ -/* reuse GL_FRAMEBUFFER_INCOMPLETE_LAYER_TARGETS_EXT */ -/* reuse GL_FRAMEBUFFER_INCOMPLETE_LAYER_COUNT_EXT */ -/* reuse GL_FRAMEBUFFER_ATTACHMENT_LAYERED_EXT */ -/* reuse GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER_EXT */ -/* reuse GL_PROGRAM_POINT_SIZE_EXT */ -#endif - -#ifndef GL_NV_vertex_program4 -#define GL_VERTEX_ATTRIB_ARRAY_INTEGER_NV 0x88FD -#endif - -#ifndef GL_EXT_gpu_shader4 -#define GL_SAMPLER_1D_ARRAY_EXT 0x8DC0 -#define GL_SAMPLER_2D_ARRAY_EXT 0x8DC1 -#define GL_SAMPLER_BUFFER_EXT 0x8DC2 -#define GL_SAMPLER_1D_ARRAY_SHADOW_EXT 0x8DC3 -#define GL_SAMPLER_2D_ARRAY_SHADOW_EXT 0x8DC4 -#define GL_SAMPLER_CUBE_SHADOW_EXT 0x8DC5 -#define GL_UNSIGNED_INT_VEC2_EXT 0x8DC6 -#define GL_UNSIGNED_INT_VEC3_EXT 0x8DC7 -#define GL_UNSIGNED_INT_VEC4_EXT 0x8DC8 -#define GL_INT_SAMPLER_1D_EXT 0x8DC9 -#define GL_INT_SAMPLER_2D_EXT 0x8DCA -#define GL_INT_SAMPLER_3D_EXT 0x8DCB -#define GL_INT_SAMPLER_CUBE_EXT 0x8DCC -#define GL_INT_SAMPLER_2D_RECT_EXT 0x8DCD -#define GL_INT_SAMPLER_1D_ARRAY_EXT 0x8DCE -#define GL_INT_SAMPLER_2D_ARRAY_EXT 0x8DCF -#define GL_INT_SAMPLER_BUFFER_EXT 0x8DD0 -#define GL_UNSIGNED_INT_SAMPLER_1D_EXT 0x8DD1 -#define GL_UNSIGNED_INT_SAMPLER_2D_EXT 0x8DD2 -#define GL_UNSIGNED_INT_SAMPLER_3D_EXT 0x8DD3 -#define GL_UNSIGNED_INT_SAMPLER_CUBE_EXT 0x8DD4 -#define GL_UNSIGNED_INT_SAMPLER_2D_RECT_EXT 0x8DD5 -#define GL_UNSIGNED_INT_SAMPLER_1D_ARRAY_EXT 0x8DD6 -#define GL_UNSIGNED_INT_SAMPLER_2D_ARRAY_EXT 0x8DD7 -#define GL_UNSIGNED_INT_SAMPLER_BUFFER_EXT 0x8DD8 -#endif - -#ifndef GL_EXT_draw_instanced -#endif - -#ifndef GL_EXT_packed_float -#define GL_R11F_G11F_B10F_EXT 0x8C3A -#define GL_UNSIGNED_INT_10F_11F_11F_REV_EXT 0x8C3B -#define GL_RGBA_SIGNED_COMPONENTS_EXT 0x8C3C -#endif - -#ifndef GL_EXT_texture_array -#define GL_TEXTURE_1D_ARRAY_EXT 0x8C18 -#define GL_PROXY_TEXTURE_1D_ARRAY_EXT 0x8C19 -#define GL_TEXTURE_2D_ARRAY_EXT 0x8C1A -#define GL_PROXY_TEXTURE_2D_ARRAY_EXT 0x8C1B -#define GL_TEXTURE_BINDING_1D_ARRAY_EXT 0x8C1C -#define GL_TEXTURE_BINDING_2D_ARRAY_EXT 0x8C1D -#define GL_MAX_ARRAY_TEXTURE_LAYERS_EXT 0x88FF -#define GL_COMPARE_REF_DEPTH_TO_TEXTURE_EXT 0x884E -/* reuse GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER_EXT */ -#endif - -#ifndef GL_EXT_texture_buffer_object -#define GL_TEXTURE_BUFFER_EXT 0x8C2A -#define GL_MAX_TEXTURE_BUFFER_SIZE_EXT 0x8C2B -#define GL_TEXTURE_BINDING_BUFFER_EXT 0x8C2C -#define GL_TEXTURE_BUFFER_DATA_STORE_BINDING_EXT 0x8C2D -#define GL_TEXTURE_BUFFER_FORMAT_EXT 0x8C2E -#endif - -#ifndef GL_EXT_texture_compression_latc -#define GL_COMPRESSED_LUMINANCE_LATC1_EXT 0x8C70 -#define GL_COMPRESSED_SIGNED_LUMINANCE_LATC1_EXT 0x8C71 -#define GL_COMPRESSED_LUMINANCE_ALPHA_LATC2_EXT 0x8C72 -#define GL_COMPRESSED_SIGNED_LUMINANCE_ALPHA_LATC2_EXT 0x8C73 -#endif - -#ifndef GL_EXT_texture_compression_rgtc -#define GL_COMPRESSED_RED_RGTC1_EXT 0x8DBB -#define GL_COMPRESSED_SIGNED_RED_RGTC1_EXT 0x8DBC -#define GL_COMPRESSED_RED_GREEN_RGTC2_EXT 0x8DBD -#define GL_COMPRESSED_SIGNED_RED_GREEN_RGTC2_EXT 0x8DBE -#endif - -#ifndef GL_EXT_texture_shared_exponent -#define GL_RGB9_E5_EXT 0x8C3D -#define GL_UNSIGNED_INT_5_9_9_9_REV_EXT 0x8C3E -#define GL_TEXTURE_SHARED_SIZE_EXT 0x8C3F -#endif - -#ifndef GL_NV_depth_buffer_float -#define GL_DEPTH_COMPONENT32F_NV 0x8DAB -#define GL_DEPTH32F_STENCIL8_NV 0x8DAC -#define GL_FLOAT_32_UNSIGNED_INT_24_8_REV_NV 0x8DAD -#define GL_DEPTH_BUFFER_FLOAT_MODE_NV 0x8DAF -#endif - -#ifndef GL_NV_fragment_program4 -#endif - -#ifndef GL_NV_framebuffer_multisample_coverage -#define GL_RENDERBUFFER_COVERAGE_SAMPLES_NV 0x8CAB -#define GL_RENDERBUFFER_COLOR_SAMPLES_NV 0x8E10 -#define GL_MAX_MULTISAMPLE_COVERAGE_MODES_NV 0x8E11 -#define GL_MULTISAMPLE_COVERAGE_MODES_NV 0x8E12 -#endif - -#ifndef GL_EXT_framebuffer_sRGB -#define GL_FRAMEBUFFER_SRGB_EXT 0x8DB9 -#define GL_FRAMEBUFFER_SRGB_CAPABLE_EXT 0x8DBA -#endif - -#ifndef GL_NV_geometry_shader4 -#endif - -#ifndef GL_NV_parameter_buffer_object -#define GL_MAX_PROGRAM_PARAMETER_BUFFER_BINDINGS_NV 0x8DA0 -#define GL_MAX_PROGRAM_PARAMETER_BUFFER_SIZE_NV 0x8DA1 -#define GL_VERTEX_PROGRAM_PARAMETER_BUFFER_NV 0x8DA2 -#define GL_GEOMETRY_PROGRAM_PARAMETER_BUFFER_NV 0x8DA3 -#define GL_FRAGMENT_PROGRAM_PARAMETER_BUFFER_NV 0x8DA4 -#endif - -#ifndef GL_EXT_draw_buffers2 -#endif - -#ifndef GL_NV_transform_feedback -#define GL_BACK_PRIMARY_COLOR_NV 0x8C77 -#define GL_BACK_SECONDARY_COLOR_NV 0x8C78 -#define GL_TEXTURE_COORD_NV 0x8C79 -#define GL_CLIP_DISTANCE_NV 0x8C7A -#define GL_VERTEX_ID_NV 0x8C7B -#define GL_PRIMITIVE_ID_NV 0x8C7C -#define GL_GENERIC_ATTRIB_NV 0x8C7D -#define GL_TRANSFORM_FEEDBACK_ATTRIBS_NV 0x8C7E -#define GL_TRANSFORM_FEEDBACK_BUFFER_MODE_NV 0x8C7F -#define GL_MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS_NV 0x8C80 -#define GL_ACTIVE_VARYINGS_NV 0x8C81 -#define GL_ACTIVE_VARYING_MAX_LENGTH_NV 0x8C82 -#define GL_TRANSFORM_FEEDBACK_VARYINGS_NV 0x8C83 -#define GL_TRANSFORM_FEEDBACK_BUFFER_START_NV 0x8C84 -#define GL_TRANSFORM_FEEDBACK_BUFFER_SIZE_NV 0x8C85 -#define GL_TRANSFORM_FEEDBACK_RECORD_NV 0x8C86 -#define GL_PRIMITIVES_GENERATED_NV 0x8C87 -#define GL_TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN_NV 0x8C88 -#define GL_RASTERIZER_DISCARD_NV 0x8C89 -#define GL_MAX_TRANSFORM_FEEDBACK_INTERLEAVED_ATTRIBS_NV 0x8C8A -#define GL_MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS_NV 0x8C8B -#define GL_INTERLEAVED_ATTRIBS_NV 0x8C8C -#define GL_SEPARATE_ATTRIBS_NV 0x8C8D -#define GL_TRANSFORM_FEEDBACK_BUFFER_NV 0x8C8E -#define GL_TRANSFORM_FEEDBACK_BUFFER_BINDING_NV 0x8C8F -#endif - -#ifndef GL_EXT_bindable_uniform -#define GL_MAX_VERTEX_BINDABLE_UNIFORMS_EXT 0x8DE2 -#define GL_MAX_FRAGMENT_BINDABLE_UNIFORMS_EXT 0x8DE3 -#define GL_MAX_GEOMETRY_BINDABLE_UNIFORMS_EXT 0x8DE4 -#define GL_MAX_BINDABLE_UNIFORM_SIZE_EXT 0x8DED -#define GL_UNIFORM_BUFFER_EXT 0x8DEE -#define GL_UNIFORM_BUFFER_BINDING_EXT 0x8DEF -#endif - -#ifndef GL_EXT_texture_integer -#define GL_RGBA32UI_EXT 0x8D70 -#define GL_RGB32UI_EXT 0x8D71 -#define GL_ALPHA32UI_EXT 0x8D72 -#define GL_INTENSITY32UI_EXT 0x8D73 -#define GL_LUMINANCE32UI_EXT 0x8D74 -#define GL_LUMINANCE_ALPHA32UI_EXT 0x8D75 -#define GL_RGBA16UI_EXT 0x8D76 -#define GL_RGB16UI_EXT 0x8D77 -#define GL_ALPHA16UI_EXT 0x8D78 -#define GL_INTENSITY16UI_EXT 0x8D79 -#define GL_LUMINANCE16UI_EXT 0x8D7A -#define GL_LUMINANCE_ALPHA16UI_EXT 0x8D7B -#define GL_RGBA8UI_EXT 0x8D7C -#define GL_RGB8UI_EXT 0x8D7D -#define GL_ALPHA8UI_EXT 0x8D7E -#define GL_INTENSITY8UI_EXT 0x8D7F -#define GL_LUMINANCE8UI_EXT 0x8D80 -#define GL_LUMINANCE_ALPHA8UI_EXT 0x8D81 -#define GL_RGBA32I_EXT 0x8D82 -#define GL_RGB32I_EXT 0x8D83 -#define GL_ALPHA32I_EXT 0x8D84 -#define GL_INTENSITY32I_EXT 0x8D85 -#define GL_LUMINANCE32I_EXT 0x8D86 -#define GL_LUMINANCE_ALPHA32I_EXT 0x8D87 -#define GL_RGBA16I_EXT 0x8D88 -#define GL_RGB16I_EXT 0x8D89 -#define GL_ALPHA16I_EXT 0x8D8A -#define GL_INTENSITY16I_EXT 0x8D8B -#define GL_LUMINANCE16I_EXT 0x8D8C -#define GL_LUMINANCE_ALPHA16I_EXT 0x8D8D -#define GL_RGBA8I_EXT 0x8D8E -#define GL_RGB8I_EXT 0x8D8F -#define GL_ALPHA8I_EXT 0x8D90 -#define GL_INTENSITY8I_EXT 0x8D91 -#define GL_LUMINANCE8I_EXT 0x8D92 -#define GL_LUMINANCE_ALPHA8I_EXT 0x8D93 -#define GL_RED_INTEGER_EXT 0x8D94 -#define GL_GREEN_INTEGER_EXT 0x8D95 -#define GL_BLUE_INTEGER_EXT 0x8D96 -#define GL_ALPHA_INTEGER_EXT 0x8D97 -#define GL_RGB_INTEGER_EXT 0x8D98 -#define GL_RGBA_INTEGER_EXT 0x8D99 -#define GL_BGR_INTEGER_EXT 0x8D9A -#define GL_BGRA_INTEGER_EXT 0x8D9B -#define GL_LUMINANCE_INTEGER_EXT 0x8D9C -#define GL_LUMINANCE_ALPHA_INTEGER_EXT 0x8D9D -#define GL_RGBA_INTEGER_MODE_EXT 0x8D9E -#endif - -#ifndef GL_GREMEDY_frame_terminator -#endif - -#ifndef GL_NV_conditional_render -#define GL_QUERY_WAIT_NV 0x8E13 -#define GL_QUERY_NO_WAIT_NV 0x8E14 -#define GL_QUERY_BY_REGION_WAIT_NV 0x8E15 -#define GL_QUERY_BY_REGION_NO_WAIT_NV 0x8E16 -#endif - -#ifndef GL_NV_present_video -#define GL_FRAME_NV 0x8E26 -#define GL_FIELDS_NV 0x8E27 -#define GL_CURRENT_TIME_NV 0x8E28 -#define GL_NUM_FILL_STREAMS_NV 0x8E29 -#define GL_PRESENT_TIME_NV 0x8E2A -#define GL_PRESENT_DURATION_NV 0x8E2B -#endif - -#ifndef GL_EXT_transform_feedback -#define GL_TRANSFORM_FEEDBACK_BUFFER_EXT 0x8C8E -#define GL_TRANSFORM_FEEDBACK_BUFFER_START_EXT 0x8C84 -#define GL_TRANSFORM_FEEDBACK_BUFFER_SIZE_EXT 0x8C85 -#define GL_TRANSFORM_FEEDBACK_BUFFER_BINDING_EXT 0x8C8F -#define GL_INTERLEAVED_ATTRIBS_EXT 0x8C8C -#define GL_SEPARATE_ATTRIBS_EXT 0x8C8D -#define GL_PRIMITIVES_GENERATED_EXT 0x8C87 -#define GL_TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN_EXT 0x8C88 -#define GL_RASTERIZER_DISCARD_EXT 0x8C89 -#define GL_MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS_EXT 0x8C8A -#define GL_MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS_EXT 0x8C8B -#define GL_MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS_EXT 0x8C80 -#define GL_TRANSFORM_FEEDBACK_VARYINGS_EXT 0x8C83 -#define GL_TRANSFORM_FEEDBACK_BUFFER_MODE_EXT 0x8C7F -#define GL_TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH_EXT 0x8C76 -#endif - -#ifndef GL_EXT_direct_state_access -#define GL_PROGRAM_MATRIX_EXT 0x8E2D -#define GL_TRANSPOSE_PROGRAM_MATRIX_EXT 0x8E2E -#define GL_PROGRAM_MATRIX_STACK_DEPTH_EXT 0x8E2F -#endif - -#ifndef GL_EXT_vertex_array_bgra -/* reuse GL_BGRA */ -#endif - -#ifndef GL_EXT_texture_swizzle -#define GL_TEXTURE_SWIZZLE_R_EXT 0x8E42 -#define GL_TEXTURE_SWIZZLE_G_EXT 0x8E43 -#define GL_TEXTURE_SWIZZLE_B_EXT 0x8E44 -#define GL_TEXTURE_SWIZZLE_A_EXT 0x8E45 -#define GL_TEXTURE_SWIZZLE_RGBA_EXT 0x8E46 -#endif - -#ifndef GL_NV_explicit_multisample -#define GL_SAMPLE_POSITION_NV 0x8E50 -#define GL_SAMPLE_MASK_NV 0x8E51 -#define GL_SAMPLE_MASK_VALUE_NV 0x8E52 -#define GL_TEXTURE_BINDING_RENDERBUFFER_NV 0x8E53 -#define GL_TEXTURE_RENDERBUFFER_DATA_STORE_BINDING_NV 0x8E54 -#define GL_MAX_SAMPLE_MASK_WORDS_NV 0x8E59 -#define GL_TEXTURE_RENDERBUFFER_NV 0x8E55 -#define GL_SAMPLER_RENDERBUFFER_NV 0x8E56 -#define GL_INT_SAMPLER_RENDERBUFFER_NV 0x8E57 -#define GL_UNSIGNED_INT_SAMPLER_RENDERBUFFER_NV 0x8E58 -#endif - -#ifndef GL_NV_transform_feedback2 -#define GL_TRANSFORM_FEEDBACK_NV 0x8E22 -#define GL_TRANSFORM_FEEDBACK_BUFFER_PAUSED_NV 0x8E23 -#define GL_TRANSFORM_FEEDBACK_BUFFER_ACTIVE_NV 0x8E24 -#define GL_TRANSFORM_FEEDBACK_BINDING_NV 0x8E25 -#endif - - -/*************************************************************/ - -#include -#ifndef GL_VERSION_2_0 -/* GL type for program/shader text */ -typedef char GLchar; /* native character */ -#endif - -#ifndef GL_VERSION_1_5 -/* GL types for handling large vertex buffer objects */ -typedef ptrdiff_t GLintptr; -typedef ptrdiff_t GLsizeiptr; -#endif - -#ifndef GL_ARB_vertex_buffer_object -/* GL types for handling large vertex buffer objects */ -typedef ptrdiff_t GLintptrARB; -typedef ptrdiff_t GLsizeiptrARB; -#endif - -#ifndef GL_ARB_shader_objects -/* GL types for handling shader object handles and program/shader text */ -typedef char GLcharARB; /* native character */ -typedef unsigned int GLhandleARB; /* shader object handle */ -#endif - -/* GL types for "half" precision (s10e5) float data in host memory */ -#ifndef GL_ARB_half_float_pixel -typedef unsigned short GLhalfARB; -#endif - -#ifndef GL_NV_half_float -typedef unsigned short GLhalfNV; -#endif - -#ifndef GLEXT_64_TYPES_DEFINED -/* This code block is duplicated in glxext.h, so must be protected */ -#define GLEXT_64_TYPES_DEFINED -/* Define int32_t, int64_t, and uint64_t types for UST/MSC */ -/* (as used in the GL_EXT_timer_query extension). */ -#if defined(__STDC_VERSION__) && __STDC_VERSION__ >= 199901L -#include -#elif defined(__sun__) || defined(__digital__) -#include -#if defined(__STDC__) -#if defined(__arch64__) || defined(_LP64) -typedef long int int64_t; -typedef unsigned long int uint64_t; -#else -typedef long long int int64_t; -typedef unsigned long long int uint64_t; -#endif /* __arch64__ */ -#endif /* __STDC__ */ -#elif defined( __VMS ) || defined(__sgi) -#include -#elif defined(__SCO__) || defined(__USLC__) -#include -#elif defined(__UNIXOS2__) || defined(__SOL64__) -typedef long int int32_t; -typedef long long int int64_t; -typedef unsigned long long int uint64_t; -#elif defined(_WIN32) && defined(__GNUC__) -#include -#elif defined(_WIN32) -typedef __int32 int32_t; -typedef __int64 int64_t; -typedef unsigned __int64 uint64_t; -#else -#include /* Fallback option */ -#endif -#endif - -#ifndef GL_EXT_timer_query -typedef int64_t GLint64EXT; -typedef uint64_t GLuint64EXT; -#endif - -#ifndef GL_VERSION_1_2 -#define GL_VERSION_1_2 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glBlendColor (GLclampf, GLclampf, GLclampf, GLclampf); -GLAPI void APIENTRY glBlendEquation (GLenum); -GLAPI void APIENTRY glDrawRangeElements (GLenum, GLuint, GLuint, GLsizei, GLenum, const GLvoid *); -GLAPI void APIENTRY glColorTable (GLenum, GLenum, GLsizei, GLenum, GLenum, const GLvoid *); -GLAPI void APIENTRY glColorTableParameterfv (GLenum, GLenum, const GLfloat *); -GLAPI void APIENTRY glColorTableParameteriv (GLenum, GLenum, const GLint *); -GLAPI void APIENTRY glCopyColorTable (GLenum, GLenum, GLint, GLint, GLsizei); -GLAPI void APIENTRY glGetColorTable (GLenum, GLenum, GLenum, GLvoid *); -GLAPI void APIENTRY glGetColorTableParameterfv (GLenum, GLenum, GLfloat *); -GLAPI void APIENTRY glGetColorTableParameteriv (GLenum, GLenum, GLint *); -GLAPI void APIENTRY glColorSubTable (GLenum, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *); -GLAPI void APIENTRY glCopyColorSubTable (GLenum, GLsizei, GLint, GLint, GLsizei); -GLAPI void APIENTRY glConvolutionFilter1D (GLenum, GLenum, GLsizei, GLenum, GLenum, const GLvoid *); -GLAPI void APIENTRY glConvolutionFilter2D (GLenum, GLenum, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *); -GLAPI void APIENTRY glConvolutionParameterf (GLenum, GLenum, GLfloat); -GLAPI void APIENTRY glConvolutionParameterfv (GLenum, GLenum, const GLfloat *); -GLAPI void APIENTRY glConvolutionParameteri (GLenum, GLenum, GLint); -GLAPI void APIENTRY glConvolutionParameteriv (GLenum, GLenum, const GLint *); -GLAPI void APIENTRY glCopyConvolutionFilter1D (GLenum, GLenum, GLint, GLint, GLsizei); -GLAPI void APIENTRY glCopyConvolutionFilter2D (GLenum, GLenum, GLint, GLint, GLsizei, GLsizei); -GLAPI void APIENTRY glGetConvolutionFilter (GLenum, GLenum, GLenum, GLvoid *); -GLAPI void APIENTRY glGetConvolutionParameterfv (GLenum, GLenum, GLfloat *); -GLAPI void APIENTRY glGetConvolutionParameteriv (GLenum, GLenum, GLint *); -GLAPI void APIENTRY glGetSeparableFilter (GLenum, GLenum, GLenum, GLvoid *, GLvoid *, GLvoid *); -GLAPI void APIENTRY glSeparableFilter2D (GLenum, GLenum, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *, const GLvoid *); -GLAPI void APIENTRY glGetHistogram (GLenum, GLboolean, GLenum, GLenum, GLvoid *); -GLAPI void APIENTRY glGetHistogramParameterfv (GLenum, GLenum, GLfloat *); -GLAPI void APIENTRY glGetHistogramParameteriv (GLenum, GLenum, GLint *); -GLAPI void APIENTRY glGetMinmax (GLenum, GLboolean, GLenum, GLenum, GLvoid *); -GLAPI void APIENTRY glGetMinmaxParameterfv (GLenum, GLenum, GLfloat *); -GLAPI void APIENTRY glGetMinmaxParameteriv (GLenum, GLenum, GLint *); -GLAPI void APIENTRY glHistogram (GLenum, GLsizei, GLenum, GLboolean); -GLAPI void APIENTRY glMinmax (GLenum, GLenum, GLboolean); -GLAPI void APIENTRY glResetHistogram (GLenum); -GLAPI void APIENTRY glResetMinmax (GLenum); -GLAPI void APIENTRY glTexImage3D (GLenum, GLint, GLint, GLsizei, GLsizei, GLsizei, GLint, GLenum, GLenum, const GLvoid *); -GLAPI void APIENTRY glTexSubImage3D (GLenum, GLint, GLint, GLint, GLint, GLsizei, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *); -GLAPI void APIENTRY glCopyTexSubImage3D (GLenum, GLint, GLint, GLint, GLint, GLint, GLint, GLsizei, GLsizei); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLBLENDCOLORPROC) (GLclampf red, GLclampf green, GLclampf blue, GLclampf alpha); -typedef void (APIENTRYP PFNGLBLENDEQUATIONPROC) (GLenum mode); -typedef void (APIENTRYP PFNGLDRAWRANGEELEMENTSPROC) (GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices); -typedef void (APIENTRYP PFNGLCOLORTABLEPROC) (GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *table); -typedef void (APIENTRYP PFNGLCOLORTABLEPARAMETERFVPROC) (GLenum target, GLenum pname, const GLfloat *params); -typedef void (APIENTRYP PFNGLCOLORTABLEPARAMETERIVPROC) (GLenum target, GLenum pname, const GLint *params); -typedef void (APIENTRYP PFNGLCOPYCOLORTABLEPROC) (GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width); -typedef void (APIENTRYP PFNGLGETCOLORTABLEPROC) (GLenum target, GLenum format, GLenum type, GLvoid *table); -typedef void (APIENTRYP PFNGLGETCOLORTABLEPARAMETERFVPROC) (GLenum target, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETCOLORTABLEPARAMETERIVPROC) (GLenum target, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLCOLORSUBTABLEPROC) (GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum type, const GLvoid *data); -typedef void (APIENTRYP PFNGLCOPYCOLORSUBTABLEPROC) (GLenum target, GLsizei start, GLint x, GLint y, GLsizei width); -typedef void (APIENTRYP PFNGLCONVOLUTIONFILTER1DPROC) (GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *image); -typedef void (APIENTRYP PFNGLCONVOLUTIONFILTER2DPROC) (GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *image); -typedef void (APIENTRYP PFNGLCONVOLUTIONPARAMETERFPROC) (GLenum target, GLenum pname, GLfloat params); -typedef void (APIENTRYP PFNGLCONVOLUTIONPARAMETERFVPROC) (GLenum target, GLenum pname, const GLfloat *params); -typedef void (APIENTRYP PFNGLCONVOLUTIONPARAMETERIPROC) (GLenum target, GLenum pname, GLint params); -typedef void (APIENTRYP PFNGLCONVOLUTIONPARAMETERIVPROC) (GLenum target, GLenum pname, const GLint *params); -typedef void (APIENTRYP PFNGLCOPYCONVOLUTIONFILTER1DPROC) (GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width); -typedef void (APIENTRYP PFNGLCOPYCONVOLUTIONFILTER2DPROC) (GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height); -typedef void (APIENTRYP PFNGLGETCONVOLUTIONFILTERPROC) (GLenum target, GLenum format, GLenum type, GLvoid *image); -typedef void (APIENTRYP PFNGLGETCONVOLUTIONPARAMETERFVPROC) (GLenum target, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETCONVOLUTIONPARAMETERIVPROC) (GLenum target, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETSEPARABLEFILTERPROC) (GLenum target, GLenum format, GLenum type, GLvoid *row, GLvoid *column, GLvoid *span); -typedef void (APIENTRYP PFNGLSEPARABLEFILTER2DPROC) (GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *row, const GLvoid *column); -typedef void (APIENTRYP PFNGLGETHISTOGRAMPROC) (GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values); -typedef void (APIENTRYP PFNGLGETHISTOGRAMPARAMETERFVPROC) (GLenum target, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETHISTOGRAMPARAMETERIVPROC) (GLenum target, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETMINMAXPROC) (GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values); -typedef void (APIENTRYP PFNGLGETMINMAXPARAMETERFVPROC) (GLenum target, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETMINMAXPARAMETERIVPROC) (GLenum target, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLHISTOGRAMPROC) (GLenum target, GLsizei width, GLenum internalformat, GLboolean sink); -typedef void (APIENTRYP PFNGLMINMAXPROC) (GLenum target, GLenum internalformat, GLboolean sink); -typedef void (APIENTRYP PFNGLRESETHISTOGRAMPROC) (GLenum target); -typedef void (APIENTRYP PFNGLRESETMINMAXPROC) (GLenum target); -typedef void (APIENTRYP PFNGLTEXIMAGE3DPROC) (GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels); -typedef void (APIENTRYP PFNGLTEXSUBIMAGE3DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels); -typedef void (APIENTRYP PFNGLCOPYTEXSUBIMAGE3DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height); -#endif - -#ifndef GL_VERSION_1_3 -#define GL_VERSION_1_3 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glActiveTexture (GLenum); -GLAPI void APIENTRY glClientActiveTexture (GLenum); -GLAPI void APIENTRY glMultiTexCoord1d (GLenum, GLdouble); -GLAPI void APIENTRY glMultiTexCoord1dv (GLenum, const GLdouble *); -GLAPI void APIENTRY glMultiTexCoord1f (GLenum, GLfloat); -GLAPI void APIENTRY glMultiTexCoord1fv (GLenum, const GLfloat *); -GLAPI void APIENTRY glMultiTexCoord1i (GLenum, GLint); -GLAPI void APIENTRY glMultiTexCoord1iv (GLenum, const GLint *); -GLAPI void APIENTRY glMultiTexCoord1s (GLenum, GLshort); -GLAPI void APIENTRY glMultiTexCoord1sv (GLenum, const GLshort *); -GLAPI void APIENTRY glMultiTexCoord2d (GLenum, GLdouble, GLdouble); -GLAPI void APIENTRY glMultiTexCoord2dv (GLenum, const GLdouble *); -GLAPI void APIENTRY glMultiTexCoord2f (GLenum, GLfloat, GLfloat); -GLAPI void APIENTRY glMultiTexCoord2fv (GLenum, const GLfloat *); -GLAPI void APIENTRY glMultiTexCoord2i (GLenum, GLint, GLint); -GLAPI void APIENTRY glMultiTexCoord2iv (GLenum, const GLint *); -GLAPI void APIENTRY glMultiTexCoord2s (GLenum, GLshort, GLshort); -GLAPI void APIENTRY glMultiTexCoord2sv (GLenum, const GLshort *); -GLAPI void APIENTRY glMultiTexCoord3d (GLenum, GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glMultiTexCoord3dv (GLenum, const GLdouble *); -GLAPI void APIENTRY glMultiTexCoord3f (GLenum, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glMultiTexCoord3fv (GLenum, const GLfloat *); -GLAPI void APIENTRY glMultiTexCoord3i (GLenum, GLint, GLint, GLint); -GLAPI void APIENTRY glMultiTexCoord3iv (GLenum, const GLint *); -GLAPI void APIENTRY glMultiTexCoord3s (GLenum, GLshort, GLshort, GLshort); -GLAPI void APIENTRY glMultiTexCoord3sv (GLenum, const GLshort *); -GLAPI void APIENTRY glMultiTexCoord4d (GLenum, GLdouble, GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glMultiTexCoord4dv (GLenum, const GLdouble *); -GLAPI void APIENTRY glMultiTexCoord4f (GLenum, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glMultiTexCoord4fv (GLenum, const GLfloat *); -GLAPI void APIENTRY glMultiTexCoord4i (GLenum, GLint, GLint, GLint, GLint); -GLAPI void APIENTRY glMultiTexCoord4iv (GLenum, const GLint *); -GLAPI void APIENTRY glMultiTexCoord4s (GLenum, GLshort, GLshort, GLshort, GLshort); -GLAPI void APIENTRY glMultiTexCoord4sv (GLenum, const GLshort *); -GLAPI void APIENTRY glLoadTransposeMatrixf (const GLfloat *); -GLAPI void APIENTRY glLoadTransposeMatrixd (const GLdouble *); -GLAPI void APIENTRY glMultTransposeMatrixf (const GLfloat *); -GLAPI void APIENTRY glMultTransposeMatrixd (const GLdouble *); -GLAPI void APIENTRY glSampleCoverage (GLclampf, GLboolean); -GLAPI void APIENTRY glCompressedTexImage3D (GLenum, GLint, GLenum, GLsizei, GLsizei, GLsizei, GLint, GLsizei, const GLvoid *); -GLAPI void APIENTRY glCompressedTexImage2D (GLenum, GLint, GLenum, GLsizei, GLsizei, GLint, GLsizei, const GLvoid *); -GLAPI void APIENTRY glCompressedTexImage1D (GLenum, GLint, GLenum, GLsizei, GLint, GLsizei, const GLvoid *); -GLAPI void APIENTRY glCompressedTexSubImage3D (GLenum, GLint, GLint, GLint, GLint, GLsizei, GLsizei, GLsizei, GLenum, GLsizei, const GLvoid *); -GLAPI void APIENTRY glCompressedTexSubImage2D (GLenum, GLint, GLint, GLint, GLsizei, GLsizei, GLenum, GLsizei, const GLvoid *); -GLAPI void APIENTRY glCompressedTexSubImage1D (GLenum, GLint, GLint, GLsizei, GLenum, GLsizei, const GLvoid *); -GLAPI void APIENTRY glGetCompressedTexImage (GLenum, GLint, GLvoid *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLACTIVETEXTUREPROC) (GLenum texture); -typedef void (APIENTRYP PFNGLCLIENTACTIVETEXTUREPROC) (GLenum texture); -typedef void (APIENTRYP PFNGLMULTITEXCOORD1DPROC) (GLenum target, GLdouble s); -typedef void (APIENTRYP PFNGLMULTITEXCOORD1DVPROC) (GLenum target, const GLdouble *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD1FPROC) (GLenum target, GLfloat s); -typedef void (APIENTRYP PFNGLMULTITEXCOORD1FVPROC) (GLenum target, const GLfloat *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD1IPROC) (GLenum target, GLint s); -typedef void (APIENTRYP PFNGLMULTITEXCOORD1IVPROC) (GLenum target, const GLint *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD1SPROC) (GLenum target, GLshort s); -typedef void (APIENTRYP PFNGLMULTITEXCOORD1SVPROC) (GLenum target, const GLshort *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD2DPROC) (GLenum target, GLdouble s, GLdouble t); -typedef void (APIENTRYP PFNGLMULTITEXCOORD2DVPROC) (GLenum target, const GLdouble *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD2FPROC) (GLenum target, GLfloat s, GLfloat t); -typedef void (APIENTRYP PFNGLMULTITEXCOORD2FVPROC) (GLenum target, const GLfloat *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD2IPROC) (GLenum target, GLint s, GLint t); -typedef void (APIENTRYP PFNGLMULTITEXCOORD2IVPROC) (GLenum target, const GLint *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD2SPROC) (GLenum target, GLshort s, GLshort t); -typedef void (APIENTRYP PFNGLMULTITEXCOORD2SVPROC) (GLenum target, const GLshort *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD3DPROC) (GLenum target, GLdouble s, GLdouble t, GLdouble r); -typedef void (APIENTRYP PFNGLMULTITEXCOORD3DVPROC) (GLenum target, const GLdouble *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD3FPROC) (GLenum target, GLfloat s, GLfloat t, GLfloat r); -typedef void (APIENTRYP PFNGLMULTITEXCOORD3FVPROC) (GLenum target, const GLfloat *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD3IPROC) (GLenum target, GLint s, GLint t, GLint r); -typedef void (APIENTRYP PFNGLMULTITEXCOORD3IVPROC) (GLenum target, const GLint *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD3SPROC) (GLenum target, GLshort s, GLshort t, GLshort r); -typedef void (APIENTRYP PFNGLMULTITEXCOORD3SVPROC) (GLenum target, const GLshort *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD4DPROC) (GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q); -typedef void (APIENTRYP PFNGLMULTITEXCOORD4DVPROC) (GLenum target, const GLdouble *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD4FPROC) (GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q); -typedef void (APIENTRYP PFNGLMULTITEXCOORD4FVPROC) (GLenum target, const GLfloat *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD4IPROC) (GLenum target, GLint s, GLint t, GLint r, GLint q); -typedef void (APIENTRYP PFNGLMULTITEXCOORD4IVPROC) (GLenum target, const GLint *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD4SPROC) (GLenum target, GLshort s, GLshort t, GLshort r, GLshort q); -typedef void (APIENTRYP PFNGLMULTITEXCOORD4SVPROC) (GLenum target, const GLshort *v); -typedef void (APIENTRYP PFNGLLOADTRANSPOSEMATRIXFPROC) (const GLfloat *m); -typedef void (APIENTRYP PFNGLLOADTRANSPOSEMATRIXDPROC) (const GLdouble *m); -typedef void (APIENTRYP PFNGLMULTTRANSPOSEMATRIXFPROC) (const GLfloat *m); -typedef void (APIENTRYP PFNGLMULTTRANSPOSEMATRIXDPROC) (const GLdouble *m); -typedef void (APIENTRYP PFNGLSAMPLECOVERAGEPROC) (GLclampf value, GLboolean invert); -typedef void (APIENTRYP PFNGLCOMPRESSEDTEXIMAGE3DPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data); -typedef void (APIENTRYP PFNGLCOMPRESSEDTEXIMAGE2DPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data); -typedef void (APIENTRYP PFNGLCOMPRESSEDTEXIMAGE1DPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data); -typedef void (APIENTRYP PFNGLCOMPRESSEDTEXSUBIMAGE3DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data); -typedef void (APIENTRYP PFNGLCOMPRESSEDTEXSUBIMAGE2DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data); -typedef void (APIENTRYP PFNGLCOMPRESSEDTEXSUBIMAGE1DPROC) (GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data); -typedef void (APIENTRYP PFNGLGETCOMPRESSEDTEXIMAGEPROC) (GLenum target, GLint level, GLvoid *img); -#endif - -#ifndef GL_VERSION_1_4 -#define GL_VERSION_1_4 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glBlendFuncSeparate (GLenum, GLenum, GLenum, GLenum); -GLAPI void APIENTRY glFogCoordf (GLfloat); -GLAPI void APIENTRY glFogCoordfv (const GLfloat *); -GLAPI void APIENTRY glFogCoordd (GLdouble); -GLAPI void APIENTRY glFogCoorddv (const GLdouble *); -GLAPI void APIENTRY glFogCoordPointer (GLenum, GLsizei, const GLvoid *); -GLAPI void APIENTRY glMultiDrawArrays (GLenum, GLint *, GLsizei *, GLsizei); -GLAPI void APIENTRY glMultiDrawElements (GLenum, const GLsizei *, GLenum, const GLvoid* *, GLsizei); -GLAPI void APIENTRY glPointParameterf (GLenum, GLfloat); -GLAPI void APIENTRY glPointParameterfv (GLenum, const GLfloat *); -GLAPI void APIENTRY glPointParameteri (GLenum, GLint); -GLAPI void APIENTRY glPointParameteriv (GLenum, const GLint *); -GLAPI void APIENTRY glSecondaryColor3b (GLbyte, GLbyte, GLbyte); -GLAPI void APIENTRY glSecondaryColor3bv (const GLbyte *); -GLAPI void APIENTRY glSecondaryColor3d (GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glSecondaryColor3dv (const GLdouble *); -GLAPI void APIENTRY glSecondaryColor3f (GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glSecondaryColor3fv (const GLfloat *); -GLAPI void APIENTRY glSecondaryColor3i (GLint, GLint, GLint); -GLAPI void APIENTRY glSecondaryColor3iv (const GLint *); -GLAPI void APIENTRY glSecondaryColor3s (GLshort, GLshort, GLshort); -GLAPI void APIENTRY glSecondaryColor3sv (const GLshort *); -GLAPI void APIENTRY glSecondaryColor3ub (GLubyte, GLubyte, GLubyte); -GLAPI void APIENTRY glSecondaryColor3ubv (const GLubyte *); -GLAPI void APIENTRY glSecondaryColor3ui (GLuint, GLuint, GLuint); -GLAPI void APIENTRY glSecondaryColor3uiv (const GLuint *); -GLAPI void APIENTRY glSecondaryColor3us (GLushort, GLushort, GLushort); -GLAPI void APIENTRY glSecondaryColor3usv (const GLushort *); -GLAPI void APIENTRY glSecondaryColorPointer (GLint, GLenum, GLsizei, const GLvoid *); -GLAPI void APIENTRY glWindowPos2d (GLdouble, GLdouble); -GLAPI void APIENTRY glWindowPos2dv (const GLdouble *); -GLAPI void APIENTRY glWindowPos2f (GLfloat, GLfloat); -GLAPI void APIENTRY glWindowPos2fv (const GLfloat *); -GLAPI void APIENTRY glWindowPos2i (GLint, GLint); -GLAPI void APIENTRY glWindowPos2iv (const GLint *); -GLAPI void APIENTRY glWindowPos2s (GLshort, GLshort); -GLAPI void APIENTRY glWindowPos2sv (const GLshort *); -GLAPI void APIENTRY glWindowPos3d (GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glWindowPos3dv (const GLdouble *); -GLAPI void APIENTRY glWindowPos3f (GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glWindowPos3fv (const GLfloat *); -GLAPI void APIENTRY glWindowPos3i (GLint, GLint, GLint); -GLAPI void APIENTRY glWindowPos3iv (const GLint *); -GLAPI void APIENTRY glWindowPos3s (GLshort, GLshort, GLshort); -GLAPI void APIENTRY glWindowPos3sv (const GLshort *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLBLENDFUNCSEPARATEPROC) (GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha); -typedef void (APIENTRYP PFNGLFOGCOORDFPROC) (GLfloat coord); -typedef void (APIENTRYP PFNGLFOGCOORDFVPROC) (const GLfloat *coord); -typedef void (APIENTRYP PFNGLFOGCOORDDPROC) (GLdouble coord); -typedef void (APIENTRYP PFNGLFOGCOORDDVPROC) (const GLdouble *coord); -typedef void (APIENTRYP PFNGLFOGCOORDPOINTERPROC) (GLenum type, GLsizei stride, const GLvoid *pointer); -typedef void (APIENTRYP PFNGLMULTIDRAWARRAYSPROC) (GLenum mode, GLint *first, GLsizei *count, GLsizei primcount); -typedef void (APIENTRYP PFNGLMULTIDRAWELEMENTSPROC) (GLenum mode, const GLsizei *count, GLenum type, const GLvoid* *indices, GLsizei primcount); -typedef void (APIENTRYP PFNGLPOINTPARAMETERFPROC) (GLenum pname, GLfloat param); -typedef void (APIENTRYP PFNGLPOINTPARAMETERFVPROC) (GLenum pname, const GLfloat *params); -typedef void (APIENTRYP PFNGLPOINTPARAMETERIPROC) (GLenum pname, GLint param); -typedef void (APIENTRYP PFNGLPOINTPARAMETERIVPROC) (GLenum pname, const GLint *params); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3BPROC) (GLbyte red, GLbyte green, GLbyte blue); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3BVPROC) (const GLbyte *v); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3DPROC) (GLdouble red, GLdouble green, GLdouble blue); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3DVPROC) (const GLdouble *v); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3FPROC) (GLfloat red, GLfloat green, GLfloat blue); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3FVPROC) (const GLfloat *v); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3IPROC) (GLint red, GLint green, GLint blue); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3IVPROC) (const GLint *v); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3SPROC) (GLshort red, GLshort green, GLshort blue); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3SVPROC) (const GLshort *v); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3UBPROC) (GLubyte red, GLubyte green, GLubyte blue); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3UBVPROC) (const GLubyte *v); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3UIPROC) (GLuint red, GLuint green, GLuint blue); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3UIVPROC) (const GLuint *v); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3USPROC) (GLushort red, GLushort green, GLushort blue); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3USVPROC) (const GLushort *v); -typedef void (APIENTRYP PFNGLSECONDARYCOLORPOINTERPROC) (GLint size, GLenum type, GLsizei stride, const GLvoid *pointer); -typedef void (APIENTRYP PFNGLWINDOWPOS2DPROC) (GLdouble x, GLdouble y); -typedef void (APIENTRYP PFNGLWINDOWPOS2DVPROC) (const GLdouble *v); -typedef void (APIENTRYP PFNGLWINDOWPOS2FPROC) (GLfloat x, GLfloat y); -typedef void (APIENTRYP PFNGLWINDOWPOS2FVPROC) (const GLfloat *v); -typedef void (APIENTRYP PFNGLWINDOWPOS2IPROC) (GLint x, GLint y); -typedef void (APIENTRYP PFNGLWINDOWPOS2IVPROC) (const GLint *v); -typedef void (APIENTRYP PFNGLWINDOWPOS2SPROC) (GLshort x, GLshort y); -typedef void (APIENTRYP PFNGLWINDOWPOS2SVPROC) (const GLshort *v); -typedef void (APIENTRYP PFNGLWINDOWPOS3DPROC) (GLdouble x, GLdouble y, GLdouble z); -typedef void (APIENTRYP PFNGLWINDOWPOS3DVPROC) (const GLdouble *v); -typedef void (APIENTRYP PFNGLWINDOWPOS3FPROC) (GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLWINDOWPOS3FVPROC) (const GLfloat *v); -typedef void (APIENTRYP PFNGLWINDOWPOS3IPROC) (GLint x, GLint y, GLint z); -typedef void (APIENTRYP PFNGLWINDOWPOS3IVPROC) (const GLint *v); -typedef void (APIENTRYP PFNGLWINDOWPOS3SPROC) (GLshort x, GLshort y, GLshort z); -typedef void (APIENTRYP PFNGLWINDOWPOS3SVPROC) (const GLshort *v); -#endif - -#ifndef GL_VERSION_1_5 -#define GL_VERSION_1_5 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glGenQueries (GLsizei, GLuint *); -GLAPI void APIENTRY glDeleteQueries (GLsizei, const GLuint *); -GLAPI GLboolean APIENTRY glIsQuery (GLuint); -GLAPI void APIENTRY glBeginQuery (GLenum, GLuint); -GLAPI void APIENTRY glEndQuery (GLenum); -GLAPI void APIENTRY glGetQueryiv (GLenum, GLenum, GLint *); -GLAPI void APIENTRY glGetQueryObjectiv (GLuint, GLenum, GLint *); -GLAPI void APIENTRY glGetQueryObjectuiv (GLuint, GLenum, GLuint *); -GLAPI void APIENTRY glBindBuffer (GLenum, GLuint); -GLAPI void APIENTRY glDeleteBuffers (GLsizei, const GLuint *); -GLAPI void APIENTRY glGenBuffers (GLsizei, GLuint *); -GLAPI GLboolean APIENTRY glIsBuffer (GLuint); -GLAPI void APIENTRY glBufferData (GLenum, GLsizeiptr, const GLvoid *, GLenum); -GLAPI void APIENTRY glBufferSubData (GLenum, GLintptr, GLsizeiptr, const GLvoid *); -GLAPI void APIENTRY glGetBufferSubData (GLenum, GLintptr, GLsizeiptr, GLvoid *); -GLAPI GLvoid* APIENTRY glMapBuffer (GLenum, GLenum); -GLAPI GLboolean APIENTRY glUnmapBuffer (GLenum); -GLAPI void APIENTRY glGetBufferParameteriv (GLenum, GLenum, GLint *); -GLAPI void APIENTRY glGetBufferPointerv (GLenum, GLenum, GLvoid* *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLGENQUERIESPROC) (GLsizei n, GLuint *ids); -typedef void (APIENTRYP PFNGLDELETEQUERIESPROC) (GLsizei n, const GLuint *ids); -typedef GLboolean (APIENTRYP PFNGLISQUERYPROC) (GLuint id); -typedef void (APIENTRYP PFNGLBEGINQUERYPROC) (GLenum target, GLuint id); -typedef void (APIENTRYP PFNGLENDQUERYPROC) (GLenum target); -typedef void (APIENTRYP PFNGLGETQUERYIVPROC) (GLenum target, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETQUERYOBJECTIVPROC) (GLuint id, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETQUERYOBJECTUIVPROC) (GLuint id, GLenum pname, GLuint *params); -typedef void (APIENTRYP PFNGLBINDBUFFERPROC) (GLenum target, GLuint buffer); -typedef void (APIENTRYP PFNGLDELETEBUFFERSPROC) (GLsizei n, const GLuint *buffers); -typedef void (APIENTRYP PFNGLGENBUFFERSPROC) (GLsizei n, GLuint *buffers); -typedef GLboolean (APIENTRYP PFNGLISBUFFERPROC) (GLuint buffer); -typedef void (APIENTRYP PFNGLBUFFERDATAPROC) (GLenum target, GLsizeiptr size, const GLvoid *data, GLenum usage); -typedef void (APIENTRYP PFNGLBUFFERSUBDATAPROC) (GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid *data); -typedef void (APIENTRYP PFNGLGETBUFFERSUBDATAPROC) (GLenum target, GLintptr offset, GLsizeiptr size, GLvoid *data); -typedef GLvoid* (APIENTRYP PFNGLMAPBUFFERPROC) (GLenum target, GLenum access); -typedef GLboolean (APIENTRYP PFNGLUNMAPBUFFERPROC) (GLenum target); -typedef void (APIENTRYP PFNGLGETBUFFERPARAMETERIVPROC) (GLenum target, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETBUFFERPOINTERVPROC) (GLenum target, GLenum pname, GLvoid* *params); -#endif - -#ifndef GL_VERSION_2_0 -#define GL_VERSION_2_0 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glBlendEquationSeparate (GLenum, GLenum); -GLAPI void APIENTRY glDrawBuffers (GLsizei, const GLenum *); -GLAPI void APIENTRY glStencilOpSeparate (GLenum, GLenum, GLenum, GLenum); -GLAPI void APIENTRY glStencilFuncSeparate (GLenum, GLenum, GLint, GLuint); -GLAPI void APIENTRY glStencilMaskSeparate (GLenum, GLuint); -GLAPI void APIENTRY glAttachShader (GLuint, GLuint); -GLAPI void APIENTRY glBindAttribLocation (GLuint, GLuint, const GLchar *); -GLAPI void APIENTRY glCompileShader (GLuint); -GLAPI GLuint APIENTRY glCreateProgram (void); -GLAPI GLuint APIENTRY glCreateShader (GLenum); -GLAPI void APIENTRY glDeleteProgram (GLuint); -GLAPI void APIENTRY glDeleteShader (GLuint); -GLAPI void APIENTRY glDetachShader (GLuint, GLuint); -GLAPI void APIENTRY glDisableVertexAttribArray (GLuint); -GLAPI void APIENTRY glEnableVertexAttribArray (GLuint); -GLAPI void APIENTRY glGetActiveAttrib (GLuint, GLuint, GLsizei, GLsizei *, GLint *, GLenum *, GLchar *); -GLAPI void APIENTRY glGetActiveUniform (GLuint, GLuint, GLsizei, GLsizei *, GLint *, GLenum *, GLchar *); -GLAPI void APIENTRY glGetAttachedShaders (GLuint, GLsizei, GLsizei *, GLuint *); -GLAPI GLint APIENTRY glGetAttribLocation (GLuint, const GLchar *); -GLAPI void APIENTRY glGetProgramiv (GLuint, GLenum, GLint *); -GLAPI void APIENTRY glGetProgramInfoLog (GLuint, GLsizei, GLsizei *, GLchar *); -GLAPI void APIENTRY glGetShaderiv (GLuint, GLenum, GLint *); -GLAPI void APIENTRY glGetShaderInfoLog (GLuint, GLsizei, GLsizei *, GLchar *); -GLAPI void APIENTRY glGetShaderSource (GLuint, GLsizei, GLsizei *, GLchar *); -GLAPI GLint APIENTRY glGetUniformLocation (GLuint, const GLchar *); -GLAPI void APIENTRY glGetUniformfv (GLuint, GLint, GLfloat *); -GLAPI void APIENTRY glGetUniformiv (GLuint, GLint, GLint *); -GLAPI void APIENTRY glGetVertexAttribdv (GLuint, GLenum, GLdouble *); -GLAPI void APIENTRY glGetVertexAttribfv (GLuint, GLenum, GLfloat *); -GLAPI void APIENTRY glGetVertexAttribiv (GLuint, GLenum, GLint *); -GLAPI void APIENTRY glGetVertexAttribPointerv (GLuint, GLenum, GLvoid* *); -GLAPI GLboolean APIENTRY glIsProgram (GLuint); -GLAPI GLboolean APIENTRY glIsShader (GLuint); -GLAPI void APIENTRY glLinkProgram (GLuint); -GLAPI void APIENTRY glShaderSource (GLuint, GLsizei, const GLchar* *, const GLint *); -GLAPI void APIENTRY glUseProgram (GLuint); -GLAPI void APIENTRY glUniform1f (GLint, GLfloat); -GLAPI void APIENTRY glUniform2f (GLint, GLfloat, GLfloat); -GLAPI void APIENTRY glUniform3f (GLint, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glUniform4f (GLint, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glUniform1i (GLint, GLint); -GLAPI void APIENTRY glUniform2i (GLint, GLint, GLint); -GLAPI void APIENTRY glUniform3i (GLint, GLint, GLint, GLint); -GLAPI void APIENTRY glUniform4i (GLint, GLint, GLint, GLint, GLint); -GLAPI void APIENTRY glUniform1fv (GLint, GLsizei, const GLfloat *); -GLAPI void APIENTRY glUniform2fv (GLint, GLsizei, const GLfloat *); -GLAPI void APIENTRY glUniform3fv (GLint, GLsizei, const GLfloat *); -GLAPI void APIENTRY glUniform4fv (GLint, GLsizei, const GLfloat *); -GLAPI void APIENTRY glUniform1iv (GLint, GLsizei, const GLint *); -GLAPI void APIENTRY glUniform2iv (GLint, GLsizei, const GLint *); -GLAPI void APIENTRY glUniform3iv (GLint, GLsizei, const GLint *); -GLAPI void APIENTRY glUniform4iv (GLint, GLsizei, const GLint *); -GLAPI void APIENTRY glUniformMatrix2fv (GLint, GLsizei, GLboolean, const GLfloat *); -GLAPI void APIENTRY glUniformMatrix3fv (GLint, GLsizei, GLboolean, const GLfloat *); -GLAPI void APIENTRY glUniformMatrix4fv (GLint, GLsizei, GLboolean, const GLfloat *); -GLAPI void APIENTRY glValidateProgram (GLuint); -GLAPI void APIENTRY glVertexAttrib1d (GLuint, GLdouble); -GLAPI void APIENTRY glVertexAttrib1dv (GLuint, const GLdouble *); -GLAPI void APIENTRY glVertexAttrib1f (GLuint, GLfloat); -GLAPI void APIENTRY glVertexAttrib1fv (GLuint, const GLfloat *); -GLAPI void APIENTRY glVertexAttrib1s (GLuint, GLshort); -GLAPI void APIENTRY glVertexAttrib1sv (GLuint, const GLshort *); -GLAPI void APIENTRY glVertexAttrib2d (GLuint, GLdouble, GLdouble); -GLAPI void APIENTRY glVertexAttrib2dv (GLuint, const GLdouble *); -GLAPI void APIENTRY glVertexAttrib2f (GLuint, GLfloat, GLfloat); -GLAPI void APIENTRY glVertexAttrib2fv (GLuint, const GLfloat *); -GLAPI void APIENTRY glVertexAttrib2s (GLuint, GLshort, GLshort); -GLAPI void APIENTRY glVertexAttrib2sv (GLuint, const GLshort *); -GLAPI void APIENTRY glVertexAttrib3d (GLuint, GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glVertexAttrib3dv (GLuint, const GLdouble *); -GLAPI void APIENTRY glVertexAttrib3f (GLuint, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glVertexAttrib3fv (GLuint, const GLfloat *); -GLAPI void APIENTRY glVertexAttrib3s (GLuint, GLshort, GLshort, GLshort); -GLAPI void APIENTRY glVertexAttrib3sv (GLuint, const GLshort *); -GLAPI void APIENTRY glVertexAttrib4Nbv (GLuint, const GLbyte *); -GLAPI void APIENTRY glVertexAttrib4Niv (GLuint, const GLint *); -GLAPI void APIENTRY glVertexAttrib4Nsv (GLuint, const GLshort *); -GLAPI void APIENTRY glVertexAttrib4Nub (GLuint, GLubyte, GLubyte, GLubyte, GLubyte); -GLAPI void APIENTRY glVertexAttrib4Nubv (GLuint, const GLubyte *); -GLAPI void APIENTRY glVertexAttrib4Nuiv (GLuint, const GLuint *); -GLAPI void APIENTRY glVertexAttrib4Nusv (GLuint, const GLushort *); -GLAPI void APIENTRY glVertexAttrib4bv (GLuint, const GLbyte *); -GLAPI void APIENTRY glVertexAttrib4d (GLuint, GLdouble, GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glVertexAttrib4dv (GLuint, const GLdouble *); -GLAPI void APIENTRY glVertexAttrib4f (GLuint, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glVertexAttrib4fv (GLuint, const GLfloat *); -GLAPI void APIENTRY glVertexAttrib4iv (GLuint, const GLint *); -GLAPI void APIENTRY glVertexAttrib4s (GLuint, GLshort, GLshort, GLshort, GLshort); -GLAPI void APIENTRY glVertexAttrib4sv (GLuint, const GLshort *); -GLAPI void APIENTRY glVertexAttrib4ubv (GLuint, const GLubyte *); -GLAPI void APIENTRY glVertexAttrib4uiv (GLuint, const GLuint *); -GLAPI void APIENTRY glVertexAttrib4usv (GLuint, const GLushort *); -GLAPI void APIENTRY glVertexAttribPointer (GLuint, GLint, GLenum, GLboolean, GLsizei, const GLvoid *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLBLENDEQUATIONSEPARATEPROC) (GLenum modeRGB, GLenum modeAlpha); -typedef void (APIENTRYP PFNGLDRAWBUFFERSPROC) (GLsizei n, const GLenum *bufs); -typedef void (APIENTRYP PFNGLSTENCILOPSEPARATEPROC) (GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass); -typedef void (APIENTRYP PFNGLSTENCILFUNCSEPARATEPROC) (GLenum frontfunc, GLenum backfunc, GLint ref, GLuint mask); -typedef void (APIENTRYP PFNGLSTENCILMASKSEPARATEPROC) (GLenum face, GLuint mask); -typedef void (APIENTRYP PFNGLATTACHSHADERPROC) (GLuint program, GLuint shader); -typedef void (APIENTRYP PFNGLBINDATTRIBLOCATIONPROC) (GLuint program, GLuint index, const GLchar *name); -typedef void (APIENTRYP PFNGLCOMPILESHADERPROC) (GLuint shader); -typedef GLuint (APIENTRYP PFNGLCREATEPROGRAMPROC) (void); -typedef GLuint (APIENTRYP PFNGLCREATESHADERPROC) (GLenum type); -typedef void (APIENTRYP PFNGLDELETEPROGRAMPROC) (GLuint program); -typedef void (APIENTRYP PFNGLDELETESHADERPROC) (GLuint shader); -typedef void (APIENTRYP PFNGLDETACHSHADERPROC) (GLuint program, GLuint shader); -typedef void (APIENTRYP PFNGLDISABLEVERTEXATTRIBARRAYPROC) (GLuint index); -typedef void (APIENTRYP PFNGLENABLEVERTEXATTRIBARRAYPROC) (GLuint index); -typedef void (APIENTRYP PFNGLGETACTIVEATTRIBPROC) (GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name); -typedef void (APIENTRYP PFNGLGETACTIVEUNIFORMPROC) (GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name); -typedef void (APIENTRYP PFNGLGETATTACHEDSHADERSPROC) (GLuint program, GLsizei maxCount, GLsizei *count, GLuint *obj); -typedef GLint (APIENTRYP PFNGLGETATTRIBLOCATIONPROC) (GLuint program, const GLchar *name); -typedef void (APIENTRYP PFNGLGETPROGRAMIVPROC) (GLuint program, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETPROGRAMINFOLOGPROC) (GLuint program, GLsizei bufSize, GLsizei *length, GLchar *infoLog); -typedef void (APIENTRYP PFNGLGETSHADERIVPROC) (GLuint shader, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETSHADERINFOLOGPROC) (GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *infoLog); -typedef void (APIENTRYP PFNGLGETSHADERSOURCEPROC) (GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *source); -typedef GLint (APIENTRYP PFNGLGETUNIFORMLOCATIONPROC) (GLuint program, const GLchar *name); -typedef void (APIENTRYP PFNGLGETUNIFORMFVPROC) (GLuint program, GLint location, GLfloat *params); -typedef void (APIENTRYP PFNGLGETUNIFORMIVPROC) (GLuint program, GLint location, GLint *params); -typedef void (APIENTRYP PFNGLGETVERTEXATTRIBDVPROC) (GLuint index, GLenum pname, GLdouble *params); -typedef void (APIENTRYP PFNGLGETVERTEXATTRIBFVPROC) (GLuint index, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETVERTEXATTRIBIVPROC) (GLuint index, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETVERTEXATTRIBPOINTERVPROC) (GLuint index, GLenum pname, GLvoid* *pointer); -typedef GLboolean (APIENTRYP PFNGLISPROGRAMPROC) (GLuint program); -typedef GLboolean (APIENTRYP PFNGLISSHADERPROC) (GLuint shader); -typedef void (APIENTRYP PFNGLLINKPROGRAMPROC) (GLuint program); -typedef void (APIENTRYP PFNGLSHADERSOURCEPROC) (GLuint shader, GLsizei count, const GLchar* *string, const GLint *length); -typedef void (APIENTRYP PFNGLUSEPROGRAMPROC) (GLuint program); -typedef void (APIENTRYP PFNGLUNIFORM1FPROC) (GLint location, GLfloat v0); -typedef void (APIENTRYP PFNGLUNIFORM2FPROC) (GLint location, GLfloat v0, GLfloat v1); -typedef void (APIENTRYP PFNGLUNIFORM3FPROC) (GLint location, GLfloat v0, GLfloat v1, GLfloat v2); -typedef void (APIENTRYP PFNGLUNIFORM4FPROC) (GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3); -typedef void (APIENTRYP PFNGLUNIFORM1IPROC) (GLint location, GLint v0); -typedef void (APIENTRYP PFNGLUNIFORM2IPROC) (GLint location, GLint v0, GLint v1); -typedef void (APIENTRYP PFNGLUNIFORM3IPROC) (GLint location, GLint v0, GLint v1, GLint v2); -typedef void (APIENTRYP PFNGLUNIFORM4IPROC) (GLint location, GLint v0, GLint v1, GLint v2, GLint v3); -typedef void (APIENTRYP PFNGLUNIFORM1FVPROC) (GLint location, GLsizei count, const GLfloat *value); -typedef void (APIENTRYP PFNGLUNIFORM2FVPROC) (GLint location, GLsizei count, const GLfloat *value); -typedef void (APIENTRYP PFNGLUNIFORM3FVPROC) (GLint location, GLsizei count, const GLfloat *value); -typedef void (APIENTRYP PFNGLUNIFORM4FVPROC) (GLint location, GLsizei count, const GLfloat *value); -typedef void (APIENTRYP PFNGLUNIFORM1IVPROC) (GLint location, GLsizei count, const GLint *value); -typedef void (APIENTRYP PFNGLUNIFORM2IVPROC) (GLint location, GLsizei count, const GLint *value); -typedef void (APIENTRYP PFNGLUNIFORM3IVPROC) (GLint location, GLsizei count, const GLint *value); -typedef void (APIENTRYP PFNGLUNIFORM4IVPROC) (GLint location, GLsizei count, const GLint *value); -typedef void (APIENTRYP PFNGLUNIFORMMATRIX2FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); -typedef void (APIENTRYP PFNGLUNIFORMMATRIX3FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); -typedef void (APIENTRYP PFNGLUNIFORMMATRIX4FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); -typedef void (APIENTRYP PFNGLVALIDATEPROGRAMPROC) (GLuint program); -typedef void (APIENTRYP PFNGLVERTEXATTRIB1DPROC) (GLuint index, GLdouble x); -typedef void (APIENTRYP PFNGLVERTEXATTRIB1DVPROC) (GLuint index, const GLdouble *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB1FPROC) (GLuint index, GLfloat x); -typedef void (APIENTRYP PFNGLVERTEXATTRIB1FVPROC) (GLuint index, const GLfloat *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB1SPROC) (GLuint index, GLshort x); -typedef void (APIENTRYP PFNGLVERTEXATTRIB1SVPROC) (GLuint index, const GLshort *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB2DPROC) (GLuint index, GLdouble x, GLdouble y); -typedef void (APIENTRYP PFNGLVERTEXATTRIB2DVPROC) (GLuint index, const GLdouble *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB2FPROC) (GLuint index, GLfloat x, GLfloat y); -typedef void (APIENTRYP PFNGLVERTEXATTRIB2FVPROC) (GLuint index, const GLfloat *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB2SPROC) (GLuint index, GLshort x, GLshort y); -typedef void (APIENTRYP PFNGLVERTEXATTRIB2SVPROC) (GLuint index, const GLshort *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB3DPROC) (GLuint index, GLdouble x, GLdouble y, GLdouble z); -typedef void (APIENTRYP PFNGLVERTEXATTRIB3DVPROC) (GLuint index, const GLdouble *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB3FPROC) (GLuint index, GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLVERTEXATTRIB3FVPROC) (GLuint index, const GLfloat *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB3SPROC) (GLuint index, GLshort x, GLshort y, GLshort z); -typedef void (APIENTRYP PFNGLVERTEXATTRIB3SVPROC) (GLuint index, const GLshort *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4NBVPROC) (GLuint index, const GLbyte *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4NIVPROC) (GLuint index, const GLint *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4NSVPROC) (GLuint index, const GLshort *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4NUBPROC) (GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4NUBVPROC) (GLuint index, const GLubyte *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4NUIVPROC) (GLuint index, const GLuint *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4NUSVPROC) (GLuint index, const GLushort *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4BVPROC) (GLuint index, const GLbyte *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4DPROC) (GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4DVPROC) (GLuint index, const GLdouble *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4FPROC) (GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4FVPROC) (GLuint index, const GLfloat *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4IVPROC) (GLuint index, const GLint *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4SPROC) (GLuint index, GLshort x, GLshort y, GLshort z, GLshort w); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4SVPROC) (GLuint index, const GLshort *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4UBVPROC) (GLuint index, const GLubyte *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4UIVPROC) (GLuint index, const GLuint *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4USVPROC) (GLuint index, const GLushort *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBPOINTERPROC) (GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const GLvoid *pointer); -#endif - -#ifndef GL_VERSION_2_1 -#define GL_VERSION_2_1 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glUniformMatrix2x3fv (GLint, GLsizei, GLboolean, const GLfloat *); -GLAPI void APIENTRY glUniformMatrix3x2fv (GLint, GLsizei, GLboolean, const GLfloat *); -GLAPI void APIENTRY glUniformMatrix2x4fv (GLint, GLsizei, GLboolean, const GLfloat *); -GLAPI void APIENTRY glUniformMatrix4x2fv (GLint, GLsizei, GLboolean, const GLfloat *); -GLAPI void APIENTRY glUniformMatrix3x4fv (GLint, GLsizei, GLboolean, const GLfloat *); -GLAPI void APIENTRY glUniformMatrix4x3fv (GLint, GLsizei, GLboolean, const GLfloat *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLUNIFORMMATRIX2X3FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); -typedef void (APIENTRYP PFNGLUNIFORMMATRIX3X2FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); -typedef void (APIENTRYP PFNGLUNIFORMMATRIX2X4FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); -typedef void (APIENTRYP PFNGLUNIFORMMATRIX4X2FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); -typedef void (APIENTRYP PFNGLUNIFORMMATRIX3X4FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); -typedef void (APIENTRYP PFNGLUNIFORMMATRIX4X3FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); -#endif - -#ifndef GL_VERSION_3_0 -#define GL_VERSION_3_0 1 -/* OpenGL 3.0 also reuses entry points from these extensions: */ -/* ARB_framebuffer_object */ -/* ARB_map_buffer_range */ -/* ARB_vertex_array_object */ -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glColorMaski (GLuint, GLboolean, GLboolean, GLboolean, GLboolean); -GLAPI void APIENTRY glGetBooleani_v (GLenum, GLuint, GLboolean *); -GLAPI void APIENTRY glGetIntegeri_v (GLenum, GLuint, GLint *); -GLAPI void APIENTRY glEnablei (GLenum, GLuint); -GLAPI void APIENTRY glDisablei (GLenum, GLuint); -GLAPI GLboolean APIENTRY glIsEnabledi (GLenum, GLuint); -GLAPI void APIENTRY glBeginTransformFeedback (GLenum); -GLAPI void APIENTRY glEndTransformFeedback (void); -GLAPI void APIENTRY glBindBufferRange (GLenum, GLuint, GLuint, GLintptr, GLsizeiptr); -GLAPI void APIENTRY glBindBufferBase (GLenum, GLuint, GLuint); -GLAPI void APIENTRY glTransformFeedbackVaryings (GLuint, GLsizei, const GLint *, GLenum); -GLAPI void APIENTRY glGetTransformFeedbackVarying (GLuint, GLuint, GLint *); -GLAPI void APIENTRY glClampColor (GLenum, GLenum); -GLAPI void APIENTRY glBeginConditionalRender (GLuint, GLenum); -GLAPI void APIENTRY glEndConditionalRender (void); -GLAPI void APIENTRY glVertexAttribI1i (GLuint, GLint); -GLAPI void APIENTRY glVertexAttribI2i (GLuint, GLint, GLint); -GLAPI void APIENTRY glVertexAttribI3i (GLuint, GLint, GLint, GLint); -GLAPI void APIENTRY glVertexAttribI4i (GLuint, GLint, GLint, GLint, GLint); -GLAPI void APIENTRY glVertexAttribI1ui (GLuint, GLuint); -GLAPI void APIENTRY glVertexAttribI2ui (GLuint, GLuint, GLuint); -GLAPI void APIENTRY glVertexAttribI3ui (GLuint, GLuint, GLuint, GLuint); -GLAPI void APIENTRY glVertexAttribI4ui (GLuint, GLuint, GLuint, GLuint, GLuint); -GLAPI void APIENTRY glVertexAttribI1iv (GLuint, const GLint *); -GLAPI void APIENTRY glVertexAttribI2iv (GLuint, const GLint *); -GLAPI void APIENTRY glVertexAttribI3iv (GLuint, const GLint *); -GLAPI void APIENTRY glVertexAttribI4iv (GLuint, const GLint *); -GLAPI void APIENTRY glVertexAttribI1uiv (GLuint, const GLuint *); -GLAPI void APIENTRY glVertexAttribI2uiv (GLuint, const GLuint *); -GLAPI void APIENTRY glVertexAttribI3uiv (GLuint, const GLuint *); -GLAPI void APIENTRY glVertexAttribI4uiv (GLuint, const GLuint *); -GLAPI void APIENTRY glVertexAttribI4bv (GLuint, const GLbyte *); -GLAPI void APIENTRY glVertexAttribI4sv (GLuint, const GLshort *); -GLAPI void APIENTRY glVertexAttribI4ubv (GLuint, const GLubyte *); -GLAPI void APIENTRY glVertexAttribI4usv (GLuint, const GLushort *); -GLAPI void APIENTRY glVertexAttribIPointer (GLuint, GLint, GLenum, GLsizei, const GLvoid *); -GLAPI void APIENTRY glGetVertexAttribIiv (GLuint, GLenum, GLint *); -GLAPI void APIENTRY glGetVertexAttribIuiv (GLuint, GLenum, GLuint *); -GLAPI void APIENTRY glGetUniformuiv (GLuint, GLint, GLuint *); -GLAPI void APIENTRY glBindFragDataLocation (GLuint, GLuint, const GLchar *); -GLAPI GLint APIENTRY glGetFragDataLocation (GLuint, const GLchar *); -GLAPI void APIENTRY glUniform1ui (GLint, GLuint); -GLAPI void APIENTRY glUniform2ui (GLint, GLuint, GLuint); -GLAPI void APIENTRY glUniform3ui (GLint, GLuint, GLuint, GLuint); -GLAPI void APIENTRY glUniform4ui (GLint, GLuint, GLuint, GLuint, GLuint); -GLAPI void APIENTRY glUniform1uiv (GLint, GLsizei, const GLuint *); -GLAPI void APIENTRY glUniform2uiv (GLint, GLsizei, const GLuint *); -GLAPI void APIENTRY glUniform3uiv (GLint, GLsizei, const GLuint *); -GLAPI void APIENTRY glUniform4uiv (GLint, GLsizei, const GLuint *); -GLAPI void APIENTRY glTexParameterIiv (GLenum, GLenum, const GLint *); -GLAPI void APIENTRY glTexParameterIuiv (GLenum, GLenum, const GLuint *); -GLAPI void APIENTRY glGetTexParameterIiv (GLenum, GLenum, GLint *); -GLAPI void APIENTRY glGetTexParameterIuiv (GLenum, GLenum, GLuint *); -GLAPI void APIENTRY glClearBufferiv (GLenum, GLint, const GLint *); -GLAPI void APIENTRY glClearBufferuiv (GLenum, GLint, const GLuint *); -GLAPI void APIENTRY glClearBufferfv (GLenum, GLint, const GLfloat *); -GLAPI void APIENTRY glClearBufferfi (GLenum, GLint, GLfloat, GLint); -GLAPI const GLubyte * APIENTRY glGetStringi (GLenum, GLuint); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLCOLORMASKIPROC) (GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a); -typedef void (APIENTRYP PFNGLGETBOOLEANI_VPROC) (GLenum target, GLuint index, GLboolean *data); -typedef void (APIENTRYP PFNGLGETINTEGERI_VPROC) (GLenum target, GLuint index, GLint *data); -typedef void (APIENTRYP PFNGLENABLEIPROC) (GLenum target, GLuint index); -typedef void (APIENTRYP PFNGLDISABLEIPROC) (GLenum target, GLuint index); -typedef GLboolean (APIENTRYP PFNGLISENABLEDIPROC) (GLenum target, GLuint index); -typedef void (APIENTRYP PFNGLBEGINTRANSFORMFEEDBACKPROC) (GLenum primitiveMode); -typedef void (APIENTRYP PFNGLENDTRANSFORMFEEDBACKPROC) (void); -typedef void (APIENTRYP PFNGLBINDBUFFERRANGEPROC) (GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size); -typedef void (APIENTRYP PFNGLBINDBUFFERBASEPROC) (GLenum target, GLuint index, GLuint buffer); -typedef void (APIENTRYP PFNGLTRANSFORMFEEDBACKVARYINGSPROC) (GLuint program, GLsizei count, const GLint *locations, GLenum bufferMode); -typedef void (APIENTRYP PFNGLGETTRANSFORMFEEDBACKVARYINGPROC) (GLuint program, GLuint index, GLint *location); -typedef void (APIENTRYP PFNGLCLAMPCOLORPROC) (GLenum target, GLenum clamp); -typedef void (APIENTRYP PFNGLBEGINCONDITIONALRENDERPROC) (GLuint id, GLenum mode); -typedef void (APIENTRYP PFNGLENDCONDITIONALRENDERPROC) (void); -typedef void (APIENTRYP PFNGLVERTEXATTRIBI1IPROC) (GLuint index, GLint x); -typedef void (APIENTRYP PFNGLVERTEXATTRIBI2IPROC) (GLuint index, GLint x, GLint y); -typedef void (APIENTRYP PFNGLVERTEXATTRIBI3IPROC) (GLuint index, GLint x, GLint y, GLint z); -typedef void (APIENTRYP PFNGLVERTEXATTRIBI4IPROC) (GLuint index, GLint x, GLint y, GLint z, GLint w); -typedef void (APIENTRYP PFNGLVERTEXATTRIBI1UIPROC) (GLuint index, GLuint x); -typedef void (APIENTRYP PFNGLVERTEXATTRIBI2UIPROC) (GLuint index, GLuint x, GLuint y); -typedef void (APIENTRYP PFNGLVERTEXATTRIBI3UIPROC) (GLuint index, GLuint x, GLuint y, GLuint z); -typedef void (APIENTRYP PFNGLVERTEXATTRIBI4UIPROC) (GLuint index, GLuint x, GLuint y, GLuint z, GLuint w); -typedef void (APIENTRYP PFNGLVERTEXATTRIBI1IVPROC) (GLuint index, const GLint *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBI2IVPROC) (GLuint index, const GLint *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBI3IVPROC) (GLuint index, const GLint *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBI4IVPROC) (GLuint index, const GLint *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBI1UIVPROC) (GLuint index, const GLuint *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBI2UIVPROC) (GLuint index, const GLuint *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBI3UIVPROC) (GLuint index, const GLuint *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBI4UIVPROC) (GLuint index, const GLuint *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBI4BVPROC) (GLuint index, const GLbyte *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBI4SVPROC) (GLuint index, const GLshort *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBI4UBVPROC) (GLuint index, const GLubyte *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBI4USVPROC) (GLuint index, const GLushort *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBIPOINTERPROC) (GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer); -typedef void (APIENTRYP PFNGLGETVERTEXATTRIBIIVPROC) (GLuint index, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETVERTEXATTRIBIUIVPROC) (GLuint index, GLenum pname, GLuint *params); -typedef void (APIENTRYP PFNGLGETUNIFORMUIVPROC) (GLuint program, GLint location, GLuint *params); -typedef void (APIENTRYP PFNGLBINDFRAGDATALOCATIONPROC) (GLuint program, GLuint color, const GLchar *name); -typedef GLint (APIENTRYP PFNGLGETFRAGDATALOCATIONPROC) (GLuint program, const GLchar *name); -typedef void (APIENTRYP PFNGLUNIFORM1UIPROC) (GLint location, GLuint v0); -typedef void (APIENTRYP PFNGLUNIFORM2UIPROC) (GLint location, GLuint v0, GLuint v1); -typedef void (APIENTRYP PFNGLUNIFORM3UIPROC) (GLint location, GLuint v0, GLuint v1, GLuint v2); -typedef void (APIENTRYP PFNGLUNIFORM4UIPROC) (GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3); -typedef void (APIENTRYP PFNGLUNIFORM1UIVPROC) (GLint location, GLsizei count, const GLuint *value); -typedef void (APIENTRYP PFNGLUNIFORM2UIVPROC) (GLint location, GLsizei count, const GLuint *value); -typedef void (APIENTRYP PFNGLUNIFORM3UIVPROC) (GLint location, GLsizei count, const GLuint *value); -typedef void (APIENTRYP PFNGLUNIFORM4UIVPROC) (GLint location, GLsizei count, const GLuint *value); -typedef void (APIENTRYP PFNGLTEXPARAMETERIIVPROC) (GLenum target, GLenum pname, const GLint *params); -typedef void (APIENTRYP PFNGLTEXPARAMETERIUIVPROC) (GLenum target, GLenum pname, const GLuint *params); -typedef void (APIENTRYP PFNGLGETTEXPARAMETERIIVPROC) (GLenum target, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETTEXPARAMETERIUIVPROC) (GLenum target, GLenum pname, GLuint *params); -typedef void (APIENTRYP PFNGLCLEARBUFFERIVPROC) (GLenum buffer, GLint drawbuffer, const GLint *value); -typedef void (APIENTRYP PFNGLCLEARBUFFERUIVPROC) (GLenum buffer, GLint drawbuffer, const GLuint *value); -typedef void (APIENTRYP PFNGLCLEARBUFFERFVPROC) (GLenum buffer, GLint drawbuffer, const GLfloat *value); -typedef void (APIENTRYP PFNGLCLEARBUFFERFIPROC) (GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil); -typedef const GLubyte * (APIENTRYP PFNGLGETSTRINGIPROC) (GLenum name, GLuint index); -#endif - -#ifndef GL_ARB_multitexture -#define GL_ARB_multitexture 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glActiveTextureARB (GLenum); -GLAPI void APIENTRY glClientActiveTextureARB (GLenum); -GLAPI void APIENTRY glMultiTexCoord1dARB (GLenum, GLdouble); -GLAPI void APIENTRY glMultiTexCoord1dvARB (GLenum, const GLdouble *); -GLAPI void APIENTRY glMultiTexCoord1fARB (GLenum, GLfloat); -GLAPI void APIENTRY glMultiTexCoord1fvARB (GLenum, const GLfloat *); -GLAPI void APIENTRY glMultiTexCoord1iARB (GLenum, GLint); -GLAPI void APIENTRY glMultiTexCoord1ivARB (GLenum, const GLint *); -GLAPI void APIENTRY glMultiTexCoord1sARB (GLenum, GLshort); -GLAPI void APIENTRY glMultiTexCoord1svARB (GLenum, const GLshort *); -GLAPI void APIENTRY glMultiTexCoord2dARB (GLenum, GLdouble, GLdouble); -GLAPI void APIENTRY glMultiTexCoord2dvARB (GLenum, const GLdouble *); -GLAPI void APIENTRY glMultiTexCoord2fARB (GLenum, GLfloat, GLfloat); -GLAPI void APIENTRY glMultiTexCoord2fvARB (GLenum, const GLfloat *); -GLAPI void APIENTRY glMultiTexCoord2iARB (GLenum, GLint, GLint); -GLAPI void APIENTRY glMultiTexCoord2ivARB (GLenum, const GLint *); -GLAPI void APIENTRY glMultiTexCoord2sARB (GLenum, GLshort, GLshort); -GLAPI void APIENTRY glMultiTexCoord2svARB (GLenum, const GLshort *); -GLAPI void APIENTRY glMultiTexCoord3dARB (GLenum, GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glMultiTexCoord3dvARB (GLenum, const GLdouble *); -GLAPI void APIENTRY glMultiTexCoord3fARB (GLenum, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glMultiTexCoord3fvARB (GLenum, const GLfloat *); -GLAPI void APIENTRY glMultiTexCoord3iARB (GLenum, GLint, GLint, GLint); -GLAPI void APIENTRY glMultiTexCoord3ivARB (GLenum, const GLint *); -GLAPI void APIENTRY glMultiTexCoord3sARB (GLenum, GLshort, GLshort, GLshort); -GLAPI void APIENTRY glMultiTexCoord3svARB (GLenum, const GLshort *); -GLAPI void APIENTRY glMultiTexCoord4dARB (GLenum, GLdouble, GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glMultiTexCoord4dvARB (GLenum, const GLdouble *); -GLAPI void APIENTRY glMultiTexCoord4fARB (GLenum, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glMultiTexCoord4fvARB (GLenum, const GLfloat *); -GLAPI void APIENTRY glMultiTexCoord4iARB (GLenum, GLint, GLint, GLint, GLint); -GLAPI void APIENTRY glMultiTexCoord4ivARB (GLenum, const GLint *); -GLAPI void APIENTRY glMultiTexCoord4sARB (GLenum, GLshort, GLshort, GLshort, GLshort); -GLAPI void APIENTRY glMultiTexCoord4svARB (GLenum, const GLshort *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLACTIVETEXTUREARBPROC) (GLenum texture); -typedef void (APIENTRYP PFNGLCLIENTACTIVETEXTUREARBPROC) (GLenum texture); -typedef void (APIENTRYP PFNGLMULTITEXCOORD1DARBPROC) (GLenum target, GLdouble s); -typedef void (APIENTRYP PFNGLMULTITEXCOORD1DVARBPROC) (GLenum target, const GLdouble *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD1FARBPROC) (GLenum target, GLfloat s); -typedef void (APIENTRYP PFNGLMULTITEXCOORD1FVARBPROC) (GLenum target, const GLfloat *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD1IARBPROC) (GLenum target, GLint s); -typedef void (APIENTRYP PFNGLMULTITEXCOORD1IVARBPROC) (GLenum target, const GLint *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD1SARBPROC) (GLenum target, GLshort s); -typedef void (APIENTRYP PFNGLMULTITEXCOORD1SVARBPROC) (GLenum target, const GLshort *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD2DARBPROC) (GLenum target, GLdouble s, GLdouble t); -typedef void (APIENTRYP PFNGLMULTITEXCOORD2DVARBPROC) (GLenum target, const GLdouble *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD2FARBPROC) (GLenum target, GLfloat s, GLfloat t); -typedef void (APIENTRYP PFNGLMULTITEXCOORD2FVARBPROC) (GLenum target, const GLfloat *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD2IARBPROC) (GLenum target, GLint s, GLint t); -typedef void (APIENTRYP PFNGLMULTITEXCOORD2IVARBPROC) (GLenum target, const GLint *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD2SARBPROC) (GLenum target, GLshort s, GLshort t); -typedef void (APIENTRYP PFNGLMULTITEXCOORD2SVARBPROC) (GLenum target, const GLshort *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD3DARBPROC) (GLenum target, GLdouble s, GLdouble t, GLdouble r); -typedef void (APIENTRYP PFNGLMULTITEXCOORD3DVARBPROC) (GLenum target, const GLdouble *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD3FARBPROC) (GLenum target, GLfloat s, GLfloat t, GLfloat r); -typedef void (APIENTRYP PFNGLMULTITEXCOORD3FVARBPROC) (GLenum target, const GLfloat *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD3IARBPROC) (GLenum target, GLint s, GLint t, GLint r); -typedef void (APIENTRYP PFNGLMULTITEXCOORD3IVARBPROC) (GLenum target, const GLint *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD3SARBPROC) (GLenum target, GLshort s, GLshort t, GLshort r); -typedef void (APIENTRYP PFNGLMULTITEXCOORD3SVARBPROC) (GLenum target, const GLshort *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD4DARBPROC) (GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q); -typedef void (APIENTRYP PFNGLMULTITEXCOORD4DVARBPROC) (GLenum target, const GLdouble *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD4FARBPROC) (GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q); -typedef void (APIENTRYP PFNGLMULTITEXCOORD4FVARBPROC) (GLenum target, const GLfloat *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD4IARBPROC) (GLenum target, GLint s, GLint t, GLint r, GLint q); -typedef void (APIENTRYP PFNGLMULTITEXCOORD4IVARBPROC) (GLenum target, const GLint *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD4SARBPROC) (GLenum target, GLshort s, GLshort t, GLshort r, GLshort q); -typedef void (APIENTRYP PFNGLMULTITEXCOORD4SVARBPROC) (GLenum target, const GLshort *v); -#endif - -#ifndef GL_ARB_transpose_matrix -#define GL_ARB_transpose_matrix 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glLoadTransposeMatrixfARB (const GLfloat *); -GLAPI void APIENTRY glLoadTransposeMatrixdARB (const GLdouble *); -GLAPI void APIENTRY glMultTransposeMatrixfARB (const GLfloat *); -GLAPI void APIENTRY glMultTransposeMatrixdARB (const GLdouble *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLLOADTRANSPOSEMATRIXFARBPROC) (const GLfloat *m); -typedef void (APIENTRYP PFNGLLOADTRANSPOSEMATRIXDARBPROC) (const GLdouble *m); -typedef void (APIENTRYP PFNGLMULTTRANSPOSEMATRIXFARBPROC) (const GLfloat *m); -typedef void (APIENTRYP PFNGLMULTTRANSPOSEMATRIXDARBPROC) (const GLdouble *m); -#endif - -#ifndef GL_ARB_multisample -#define GL_ARB_multisample 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glSampleCoverageARB (GLclampf, GLboolean); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLSAMPLECOVERAGEARBPROC) (GLclampf value, GLboolean invert); -#endif - -#ifndef GL_ARB_texture_env_add -#define GL_ARB_texture_env_add 1 -#endif - -#ifndef GL_ARB_texture_cube_map -#define GL_ARB_texture_cube_map 1 -#endif - -#ifndef GL_ARB_texture_compression -#define GL_ARB_texture_compression 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glCompressedTexImage3DARB (GLenum, GLint, GLenum, GLsizei, GLsizei, GLsizei, GLint, GLsizei, const GLvoid *); -GLAPI void APIENTRY glCompressedTexImage2DARB (GLenum, GLint, GLenum, GLsizei, GLsizei, GLint, GLsizei, const GLvoid *); -GLAPI void APIENTRY glCompressedTexImage1DARB (GLenum, GLint, GLenum, GLsizei, GLint, GLsizei, const GLvoid *); -GLAPI void APIENTRY glCompressedTexSubImage3DARB (GLenum, GLint, GLint, GLint, GLint, GLsizei, GLsizei, GLsizei, GLenum, GLsizei, const GLvoid *); -GLAPI void APIENTRY glCompressedTexSubImage2DARB (GLenum, GLint, GLint, GLint, GLsizei, GLsizei, GLenum, GLsizei, const GLvoid *); -GLAPI void APIENTRY glCompressedTexSubImage1DARB (GLenum, GLint, GLint, GLsizei, GLenum, GLsizei, const GLvoid *); -GLAPI void APIENTRY glGetCompressedTexImageARB (GLenum, GLint, GLvoid *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLCOMPRESSEDTEXIMAGE3DARBPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data); -typedef void (APIENTRYP PFNGLCOMPRESSEDTEXIMAGE2DARBPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data); -typedef void (APIENTRYP PFNGLCOMPRESSEDTEXIMAGE1DARBPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data); -typedef void (APIENTRYP PFNGLCOMPRESSEDTEXSUBIMAGE3DARBPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data); -typedef void (APIENTRYP PFNGLCOMPRESSEDTEXSUBIMAGE2DARBPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data); -typedef void (APIENTRYP PFNGLCOMPRESSEDTEXSUBIMAGE1DARBPROC) (GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data); -typedef void (APIENTRYP PFNGLGETCOMPRESSEDTEXIMAGEARBPROC) (GLenum target, GLint level, GLvoid *img); -#endif - -#ifndef GL_ARB_texture_border_clamp -#define GL_ARB_texture_border_clamp 1 -#endif - -#ifndef GL_ARB_point_parameters -#define GL_ARB_point_parameters 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glPointParameterfARB (GLenum, GLfloat); -GLAPI void APIENTRY glPointParameterfvARB (GLenum, const GLfloat *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLPOINTPARAMETERFARBPROC) (GLenum pname, GLfloat param); -typedef void (APIENTRYP PFNGLPOINTPARAMETERFVARBPROC) (GLenum pname, const GLfloat *params); -#endif - -#ifndef GL_ARB_vertex_blend -#define GL_ARB_vertex_blend 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glWeightbvARB (GLint, const GLbyte *); -GLAPI void APIENTRY glWeightsvARB (GLint, const GLshort *); -GLAPI void APIENTRY glWeightivARB (GLint, const GLint *); -GLAPI void APIENTRY glWeightfvARB (GLint, const GLfloat *); -GLAPI void APIENTRY glWeightdvARB (GLint, const GLdouble *); -GLAPI void APIENTRY glWeightubvARB (GLint, const GLubyte *); -GLAPI void APIENTRY glWeightusvARB (GLint, const GLushort *); -GLAPI void APIENTRY glWeightuivARB (GLint, const GLuint *); -GLAPI void APIENTRY glWeightPointerARB (GLint, GLenum, GLsizei, const GLvoid *); -GLAPI void APIENTRY glVertexBlendARB (GLint); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLWEIGHTBVARBPROC) (GLint size, const GLbyte *weights); -typedef void (APIENTRYP PFNGLWEIGHTSVARBPROC) (GLint size, const GLshort *weights); -typedef void (APIENTRYP PFNGLWEIGHTIVARBPROC) (GLint size, const GLint *weights); -typedef void (APIENTRYP PFNGLWEIGHTFVARBPROC) (GLint size, const GLfloat *weights); -typedef void (APIENTRYP PFNGLWEIGHTDVARBPROC) (GLint size, const GLdouble *weights); -typedef void (APIENTRYP PFNGLWEIGHTUBVARBPROC) (GLint size, const GLubyte *weights); -typedef void (APIENTRYP PFNGLWEIGHTUSVARBPROC) (GLint size, const GLushort *weights); -typedef void (APIENTRYP PFNGLWEIGHTUIVARBPROC) (GLint size, const GLuint *weights); -typedef void (APIENTRYP PFNGLWEIGHTPOINTERARBPROC) (GLint size, GLenum type, GLsizei stride, const GLvoid *pointer); -typedef void (APIENTRYP PFNGLVERTEXBLENDARBPROC) (GLint count); -#endif - -#ifndef GL_ARB_matrix_palette -#define GL_ARB_matrix_palette 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glCurrentPaletteMatrixARB (GLint); -GLAPI void APIENTRY glMatrixIndexubvARB (GLint, const GLubyte *); -GLAPI void APIENTRY glMatrixIndexusvARB (GLint, const GLushort *); -GLAPI void APIENTRY glMatrixIndexuivARB (GLint, const GLuint *); -GLAPI void APIENTRY glMatrixIndexPointerARB (GLint, GLenum, GLsizei, const GLvoid *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLCURRENTPALETTEMATRIXARBPROC) (GLint index); -typedef void (APIENTRYP PFNGLMATRIXINDEXUBVARBPROC) (GLint size, const GLubyte *indices); -typedef void (APIENTRYP PFNGLMATRIXINDEXUSVARBPROC) (GLint size, const GLushort *indices); -typedef void (APIENTRYP PFNGLMATRIXINDEXUIVARBPROC) (GLint size, const GLuint *indices); -typedef void (APIENTRYP PFNGLMATRIXINDEXPOINTERARBPROC) (GLint size, GLenum type, GLsizei stride, const GLvoid *pointer); -#endif - -#ifndef GL_ARB_texture_env_combine -#define GL_ARB_texture_env_combine 1 -#endif - -#ifndef GL_ARB_texture_env_crossbar -#define GL_ARB_texture_env_crossbar 1 -#endif - -#ifndef GL_ARB_texture_env_dot3 -#define GL_ARB_texture_env_dot3 1 -#endif - -#ifndef GL_ARB_texture_mirrored_repeat -#define GL_ARB_texture_mirrored_repeat 1 -#endif - -#ifndef GL_ARB_depth_texture -#define GL_ARB_depth_texture 1 -#endif - -#ifndef GL_ARB_shadow -#define GL_ARB_shadow 1 -#endif - -#ifndef GL_ARB_shadow_ambient -#define GL_ARB_shadow_ambient 1 -#endif - -#ifndef GL_ARB_window_pos -#define GL_ARB_window_pos 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glWindowPos2dARB (GLdouble, GLdouble); -GLAPI void APIENTRY glWindowPos2dvARB (const GLdouble *); -GLAPI void APIENTRY glWindowPos2fARB (GLfloat, GLfloat); -GLAPI void APIENTRY glWindowPos2fvARB (const GLfloat *); -GLAPI void APIENTRY glWindowPos2iARB (GLint, GLint); -GLAPI void APIENTRY glWindowPos2ivARB (const GLint *); -GLAPI void APIENTRY glWindowPos2sARB (GLshort, GLshort); -GLAPI void APIENTRY glWindowPos2svARB (const GLshort *); -GLAPI void APIENTRY glWindowPos3dARB (GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glWindowPos3dvARB (const GLdouble *); -GLAPI void APIENTRY glWindowPos3fARB (GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glWindowPos3fvARB (const GLfloat *); -GLAPI void APIENTRY glWindowPos3iARB (GLint, GLint, GLint); -GLAPI void APIENTRY glWindowPos3ivARB (const GLint *); -GLAPI void APIENTRY glWindowPos3sARB (GLshort, GLshort, GLshort); -GLAPI void APIENTRY glWindowPos3svARB (const GLshort *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLWINDOWPOS2DARBPROC) (GLdouble x, GLdouble y); -typedef void (APIENTRYP PFNGLWINDOWPOS2DVARBPROC) (const GLdouble *v); -typedef void (APIENTRYP PFNGLWINDOWPOS2FARBPROC) (GLfloat x, GLfloat y); -typedef void (APIENTRYP PFNGLWINDOWPOS2FVARBPROC) (const GLfloat *v); -typedef void (APIENTRYP PFNGLWINDOWPOS2IARBPROC) (GLint x, GLint y); -typedef void (APIENTRYP PFNGLWINDOWPOS2IVARBPROC) (const GLint *v); -typedef void (APIENTRYP PFNGLWINDOWPOS2SARBPROC) (GLshort x, GLshort y); -typedef void (APIENTRYP PFNGLWINDOWPOS2SVARBPROC) (const GLshort *v); -typedef void (APIENTRYP PFNGLWINDOWPOS3DARBPROC) (GLdouble x, GLdouble y, GLdouble z); -typedef void (APIENTRYP PFNGLWINDOWPOS3DVARBPROC) (const GLdouble *v); -typedef void (APIENTRYP PFNGLWINDOWPOS3FARBPROC) (GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLWINDOWPOS3FVARBPROC) (const GLfloat *v); -typedef void (APIENTRYP PFNGLWINDOWPOS3IARBPROC) (GLint x, GLint y, GLint z); -typedef void (APIENTRYP PFNGLWINDOWPOS3IVARBPROC) (const GLint *v); -typedef void (APIENTRYP PFNGLWINDOWPOS3SARBPROC) (GLshort x, GLshort y, GLshort z); -typedef void (APIENTRYP PFNGLWINDOWPOS3SVARBPROC) (const GLshort *v); -#endif - -#ifndef GL_ARB_vertex_program -#define GL_ARB_vertex_program 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glVertexAttrib1dARB (GLuint, GLdouble); -GLAPI void APIENTRY glVertexAttrib1dvARB (GLuint, const GLdouble *); -GLAPI void APIENTRY glVertexAttrib1fARB (GLuint, GLfloat); -GLAPI void APIENTRY glVertexAttrib1fvARB (GLuint, const GLfloat *); -GLAPI void APIENTRY glVertexAttrib1sARB (GLuint, GLshort); -GLAPI void APIENTRY glVertexAttrib1svARB (GLuint, const GLshort *); -GLAPI void APIENTRY glVertexAttrib2dARB (GLuint, GLdouble, GLdouble); -GLAPI void APIENTRY glVertexAttrib2dvARB (GLuint, const GLdouble *); -GLAPI void APIENTRY glVertexAttrib2fARB (GLuint, GLfloat, GLfloat); -GLAPI void APIENTRY glVertexAttrib2fvARB (GLuint, const GLfloat *); -GLAPI void APIENTRY glVertexAttrib2sARB (GLuint, GLshort, GLshort); -GLAPI void APIENTRY glVertexAttrib2svARB (GLuint, const GLshort *); -GLAPI void APIENTRY glVertexAttrib3dARB (GLuint, GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glVertexAttrib3dvARB (GLuint, const GLdouble *); -GLAPI void APIENTRY glVertexAttrib3fARB (GLuint, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glVertexAttrib3fvARB (GLuint, const GLfloat *); -GLAPI void APIENTRY glVertexAttrib3sARB (GLuint, GLshort, GLshort, GLshort); -GLAPI void APIENTRY glVertexAttrib3svARB (GLuint, const GLshort *); -GLAPI void APIENTRY glVertexAttrib4NbvARB (GLuint, const GLbyte *); -GLAPI void APIENTRY glVertexAttrib4NivARB (GLuint, const GLint *); -GLAPI void APIENTRY glVertexAttrib4NsvARB (GLuint, const GLshort *); -GLAPI void APIENTRY glVertexAttrib4NubARB (GLuint, GLubyte, GLubyte, GLubyte, GLubyte); -GLAPI void APIENTRY glVertexAttrib4NubvARB (GLuint, const GLubyte *); -GLAPI void APIENTRY glVertexAttrib4NuivARB (GLuint, const GLuint *); -GLAPI void APIENTRY glVertexAttrib4NusvARB (GLuint, const GLushort *); -GLAPI void APIENTRY glVertexAttrib4bvARB (GLuint, const GLbyte *); -GLAPI void APIENTRY glVertexAttrib4dARB (GLuint, GLdouble, GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glVertexAttrib4dvARB (GLuint, const GLdouble *); -GLAPI void APIENTRY glVertexAttrib4fARB (GLuint, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glVertexAttrib4fvARB (GLuint, const GLfloat *); -GLAPI void APIENTRY glVertexAttrib4ivARB (GLuint, const GLint *); -GLAPI void APIENTRY glVertexAttrib4sARB (GLuint, GLshort, GLshort, GLshort, GLshort); -GLAPI void APIENTRY glVertexAttrib4svARB (GLuint, const GLshort *); -GLAPI void APIENTRY glVertexAttrib4ubvARB (GLuint, const GLubyte *); -GLAPI void APIENTRY glVertexAttrib4uivARB (GLuint, const GLuint *); -GLAPI void APIENTRY glVertexAttrib4usvARB (GLuint, const GLushort *); -GLAPI void APIENTRY glVertexAttribPointerARB (GLuint, GLint, GLenum, GLboolean, GLsizei, const GLvoid *); -GLAPI void APIENTRY glEnableVertexAttribArrayARB (GLuint); -GLAPI void APIENTRY glDisableVertexAttribArrayARB (GLuint); -GLAPI void APIENTRY glProgramStringARB (GLenum, GLenum, GLsizei, const GLvoid *); -GLAPI void APIENTRY glBindProgramARB (GLenum, GLuint); -GLAPI void APIENTRY glDeleteProgramsARB (GLsizei, const GLuint *); -GLAPI void APIENTRY glGenProgramsARB (GLsizei, GLuint *); -GLAPI void APIENTRY glProgramEnvParameter4dARB (GLenum, GLuint, GLdouble, GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glProgramEnvParameter4dvARB (GLenum, GLuint, const GLdouble *); -GLAPI void APIENTRY glProgramEnvParameter4fARB (GLenum, GLuint, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glProgramEnvParameter4fvARB (GLenum, GLuint, const GLfloat *); -GLAPI void APIENTRY glProgramLocalParameter4dARB (GLenum, GLuint, GLdouble, GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glProgramLocalParameter4dvARB (GLenum, GLuint, const GLdouble *); -GLAPI void APIENTRY glProgramLocalParameter4fARB (GLenum, GLuint, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glProgramLocalParameter4fvARB (GLenum, GLuint, const GLfloat *); -GLAPI void APIENTRY glGetProgramEnvParameterdvARB (GLenum, GLuint, GLdouble *); -GLAPI void APIENTRY glGetProgramEnvParameterfvARB (GLenum, GLuint, GLfloat *); -GLAPI void APIENTRY glGetProgramLocalParameterdvARB (GLenum, GLuint, GLdouble *); -GLAPI void APIENTRY glGetProgramLocalParameterfvARB (GLenum, GLuint, GLfloat *); -GLAPI void APIENTRY glGetProgramivARB (GLenum, GLenum, GLint *); -GLAPI void APIENTRY glGetProgramStringARB (GLenum, GLenum, GLvoid *); -GLAPI void APIENTRY glGetVertexAttribdvARB (GLuint, GLenum, GLdouble *); -GLAPI void APIENTRY glGetVertexAttribfvARB (GLuint, GLenum, GLfloat *); -GLAPI void APIENTRY glGetVertexAttribivARB (GLuint, GLenum, GLint *); -GLAPI void APIENTRY glGetVertexAttribPointervARB (GLuint, GLenum, GLvoid* *); -GLAPI GLboolean APIENTRY glIsProgramARB (GLuint); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLVERTEXATTRIB1DARBPROC) (GLuint index, GLdouble x); -typedef void (APIENTRYP PFNGLVERTEXATTRIB1DVARBPROC) (GLuint index, const GLdouble *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB1FARBPROC) (GLuint index, GLfloat x); -typedef void (APIENTRYP PFNGLVERTEXATTRIB1FVARBPROC) (GLuint index, const GLfloat *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB1SARBPROC) (GLuint index, GLshort x); -typedef void (APIENTRYP PFNGLVERTEXATTRIB1SVARBPROC) (GLuint index, const GLshort *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB2DARBPROC) (GLuint index, GLdouble x, GLdouble y); -typedef void (APIENTRYP PFNGLVERTEXATTRIB2DVARBPROC) (GLuint index, const GLdouble *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB2FARBPROC) (GLuint index, GLfloat x, GLfloat y); -typedef void (APIENTRYP PFNGLVERTEXATTRIB2FVARBPROC) (GLuint index, const GLfloat *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB2SARBPROC) (GLuint index, GLshort x, GLshort y); -typedef void (APIENTRYP PFNGLVERTEXATTRIB2SVARBPROC) (GLuint index, const GLshort *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB3DARBPROC) (GLuint index, GLdouble x, GLdouble y, GLdouble z); -typedef void (APIENTRYP PFNGLVERTEXATTRIB3DVARBPROC) (GLuint index, const GLdouble *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB3FARBPROC) (GLuint index, GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLVERTEXATTRIB3FVARBPROC) (GLuint index, const GLfloat *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB3SARBPROC) (GLuint index, GLshort x, GLshort y, GLshort z); -typedef void (APIENTRYP PFNGLVERTEXATTRIB3SVARBPROC) (GLuint index, const GLshort *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4NBVARBPROC) (GLuint index, const GLbyte *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4NIVARBPROC) (GLuint index, const GLint *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4NSVARBPROC) (GLuint index, const GLshort *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4NUBARBPROC) (GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4NUBVARBPROC) (GLuint index, const GLubyte *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4NUIVARBPROC) (GLuint index, const GLuint *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4NUSVARBPROC) (GLuint index, const GLushort *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4BVARBPROC) (GLuint index, const GLbyte *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4DARBPROC) (GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4DVARBPROC) (GLuint index, const GLdouble *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4FARBPROC) (GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4FVARBPROC) (GLuint index, const GLfloat *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4IVARBPROC) (GLuint index, const GLint *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4SARBPROC) (GLuint index, GLshort x, GLshort y, GLshort z, GLshort w); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4SVARBPROC) (GLuint index, const GLshort *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4UBVARBPROC) (GLuint index, const GLubyte *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4UIVARBPROC) (GLuint index, const GLuint *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4USVARBPROC) (GLuint index, const GLushort *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBPOINTERARBPROC) (GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const GLvoid *pointer); -typedef void (APIENTRYP PFNGLENABLEVERTEXATTRIBARRAYARBPROC) (GLuint index); -typedef void (APIENTRYP PFNGLDISABLEVERTEXATTRIBARRAYARBPROC) (GLuint index); -typedef void (APIENTRYP PFNGLPROGRAMSTRINGARBPROC) (GLenum target, GLenum format, GLsizei len, const GLvoid *string); -typedef void (APIENTRYP PFNGLBINDPROGRAMARBPROC) (GLenum target, GLuint program); -typedef void (APIENTRYP PFNGLDELETEPROGRAMSARBPROC) (GLsizei n, const GLuint *programs); -typedef void (APIENTRYP PFNGLGENPROGRAMSARBPROC) (GLsizei n, GLuint *programs); -typedef void (APIENTRYP PFNGLPROGRAMENVPARAMETER4DARBPROC) (GLenum target, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w); -typedef void (APIENTRYP PFNGLPROGRAMENVPARAMETER4DVARBPROC) (GLenum target, GLuint index, const GLdouble *params); -typedef void (APIENTRYP PFNGLPROGRAMENVPARAMETER4FARBPROC) (GLenum target, GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w); -typedef void (APIENTRYP PFNGLPROGRAMENVPARAMETER4FVARBPROC) (GLenum target, GLuint index, const GLfloat *params); -typedef void (APIENTRYP PFNGLPROGRAMLOCALPARAMETER4DARBPROC) (GLenum target, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w); -typedef void (APIENTRYP PFNGLPROGRAMLOCALPARAMETER4DVARBPROC) (GLenum target, GLuint index, const GLdouble *params); -typedef void (APIENTRYP PFNGLPROGRAMLOCALPARAMETER4FARBPROC) (GLenum target, GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w); -typedef void (APIENTRYP PFNGLPROGRAMLOCALPARAMETER4FVARBPROC) (GLenum target, GLuint index, const GLfloat *params); -typedef void (APIENTRYP PFNGLGETPROGRAMENVPARAMETERDVARBPROC) (GLenum target, GLuint index, GLdouble *params); -typedef void (APIENTRYP PFNGLGETPROGRAMENVPARAMETERFVARBPROC) (GLenum target, GLuint index, GLfloat *params); -typedef void (APIENTRYP PFNGLGETPROGRAMLOCALPARAMETERDVARBPROC) (GLenum target, GLuint index, GLdouble *params); -typedef void (APIENTRYP PFNGLGETPROGRAMLOCALPARAMETERFVARBPROC) (GLenum target, GLuint index, GLfloat *params); -typedef void (APIENTRYP PFNGLGETPROGRAMIVARBPROC) (GLenum target, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETPROGRAMSTRINGARBPROC) (GLenum target, GLenum pname, GLvoid *string); -typedef void (APIENTRYP PFNGLGETVERTEXATTRIBDVARBPROC) (GLuint index, GLenum pname, GLdouble *params); -typedef void (APIENTRYP PFNGLGETVERTEXATTRIBFVARBPROC) (GLuint index, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETVERTEXATTRIBIVARBPROC) (GLuint index, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETVERTEXATTRIBPOINTERVARBPROC) (GLuint index, GLenum pname, GLvoid* *pointer); -typedef GLboolean (APIENTRYP PFNGLISPROGRAMARBPROC) (GLuint program); -#endif - -#ifndef GL_ARB_fragment_program -#define GL_ARB_fragment_program 1 -/* All ARB_fragment_program entry points are shared with ARB_vertex_program. */ -#endif - -#ifndef GL_ARB_vertex_buffer_object -#define GL_ARB_vertex_buffer_object 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glBindBufferARB (GLenum, GLuint); -GLAPI void APIENTRY glDeleteBuffersARB (GLsizei, const GLuint *); -GLAPI void APIENTRY glGenBuffersARB (GLsizei, GLuint *); -GLAPI GLboolean APIENTRY glIsBufferARB (GLuint); -GLAPI void APIENTRY glBufferDataARB (GLenum, GLsizeiptrARB, const GLvoid *, GLenum); -GLAPI void APIENTRY glBufferSubDataARB (GLenum, GLintptrARB, GLsizeiptrARB, const GLvoid *); -GLAPI void APIENTRY glGetBufferSubDataARB (GLenum, GLintptrARB, GLsizeiptrARB, GLvoid *); -GLAPI GLvoid* APIENTRY glMapBufferARB (GLenum, GLenum); -GLAPI GLboolean APIENTRY glUnmapBufferARB (GLenum); -GLAPI void APIENTRY glGetBufferParameterivARB (GLenum, GLenum, GLint *); -GLAPI void APIENTRY glGetBufferPointervARB (GLenum, GLenum, GLvoid* *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLBINDBUFFERARBPROC) (GLenum target, GLuint buffer); -typedef void (APIENTRYP PFNGLDELETEBUFFERSARBPROC) (GLsizei n, const GLuint *buffers); -typedef void (APIENTRYP PFNGLGENBUFFERSARBPROC) (GLsizei n, GLuint *buffers); -typedef GLboolean (APIENTRYP PFNGLISBUFFERARBPROC) (GLuint buffer); -typedef void (APIENTRYP PFNGLBUFFERDATAARBPROC) (GLenum target, GLsizeiptrARB size, const GLvoid *data, GLenum usage); -typedef void (APIENTRYP PFNGLBUFFERSUBDATAARBPROC) (GLenum target, GLintptrARB offset, GLsizeiptrARB size, const GLvoid *data); -typedef void (APIENTRYP PFNGLGETBUFFERSUBDATAARBPROC) (GLenum target, GLintptrARB offset, GLsizeiptrARB size, GLvoid *data); -typedef GLvoid* (APIENTRYP PFNGLMAPBUFFERARBPROC) (GLenum target, GLenum access); -typedef GLboolean (APIENTRYP PFNGLUNMAPBUFFERARBPROC) (GLenum target); -typedef void (APIENTRYP PFNGLGETBUFFERPARAMETERIVARBPROC) (GLenum target, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETBUFFERPOINTERVARBPROC) (GLenum target, GLenum pname, GLvoid* *params); -#endif - -#ifndef GL_ARB_occlusion_query -#define GL_ARB_occlusion_query 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glGenQueriesARB (GLsizei, GLuint *); -GLAPI void APIENTRY glDeleteQueriesARB (GLsizei, const GLuint *); -GLAPI GLboolean APIENTRY glIsQueryARB (GLuint); -GLAPI void APIENTRY glBeginQueryARB (GLenum, GLuint); -GLAPI void APIENTRY glEndQueryARB (GLenum); -GLAPI void APIENTRY glGetQueryivARB (GLenum, GLenum, GLint *); -GLAPI void APIENTRY glGetQueryObjectivARB (GLuint, GLenum, GLint *); -GLAPI void APIENTRY glGetQueryObjectuivARB (GLuint, GLenum, GLuint *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLGENQUERIESARBPROC) (GLsizei n, GLuint *ids); -typedef void (APIENTRYP PFNGLDELETEQUERIESARBPROC) (GLsizei n, const GLuint *ids); -typedef GLboolean (APIENTRYP PFNGLISQUERYARBPROC) (GLuint id); -typedef void (APIENTRYP PFNGLBEGINQUERYARBPROC) (GLenum target, GLuint id); -typedef void (APIENTRYP PFNGLENDQUERYARBPROC) (GLenum target); -typedef void (APIENTRYP PFNGLGETQUERYIVARBPROC) (GLenum target, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETQUERYOBJECTIVARBPROC) (GLuint id, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETQUERYOBJECTUIVARBPROC) (GLuint id, GLenum pname, GLuint *params); -#endif - -#ifndef GL_ARB_shader_objects -#define GL_ARB_shader_objects 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glDeleteObjectARB (GLhandleARB); -GLAPI GLhandleARB APIENTRY glGetHandleARB (GLenum); -GLAPI void APIENTRY glDetachObjectARB (GLhandleARB, GLhandleARB); -GLAPI GLhandleARB APIENTRY glCreateShaderObjectARB (GLenum); -GLAPI void APIENTRY glShaderSourceARB (GLhandleARB, GLsizei, const GLcharARB* *, const GLint *); -GLAPI void APIENTRY glCompileShaderARB (GLhandleARB); -GLAPI GLhandleARB APIENTRY glCreateProgramObjectARB (void); -GLAPI void APIENTRY glAttachObjectARB (GLhandleARB, GLhandleARB); -GLAPI void APIENTRY glLinkProgramARB (GLhandleARB); -GLAPI void APIENTRY glUseProgramObjectARB (GLhandleARB); -GLAPI void APIENTRY glValidateProgramARB (GLhandleARB); -GLAPI void APIENTRY glUniform1fARB (GLint, GLfloat); -GLAPI void APIENTRY glUniform2fARB (GLint, GLfloat, GLfloat); -GLAPI void APIENTRY glUniform3fARB (GLint, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glUniform4fARB (GLint, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glUniform1iARB (GLint, GLint); -GLAPI void APIENTRY glUniform2iARB (GLint, GLint, GLint); -GLAPI void APIENTRY glUniform3iARB (GLint, GLint, GLint, GLint); -GLAPI void APIENTRY glUniform4iARB (GLint, GLint, GLint, GLint, GLint); -GLAPI void APIENTRY glUniform1fvARB (GLint, GLsizei, const GLfloat *); -GLAPI void APIENTRY glUniform2fvARB (GLint, GLsizei, const GLfloat *); -GLAPI void APIENTRY glUniform3fvARB (GLint, GLsizei, const GLfloat *); -GLAPI void APIENTRY glUniform4fvARB (GLint, GLsizei, const GLfloat *); -GLAPI void APIENTRY glUniform1ivARB (GLint, GLsizei, const GLint *); -GLAPI void APIENTRY glUniform2ivARB (GLint, GLsizei, const GLint *); -GLAPI void APIENTRY glUniform3ivARB (GLint, GLsizei, const GLint *); -GLAPI void APIENTRY glUniform4ivARB (GLint, GLsizei, const GLint *); -GLAPI void APIENTRY glUniformMatrix2fvARB (GLint, GLsizei, GLboolean, const GLfloat *); -GLAPI void APIENTRY glUniformMatrix3fvARB (GLint, GLsizei, GLboolean, const GLfloat *); -GLAPI void APIENTRY glUniformMatrix4fvARB (GLint, GLsizei, GLboolean, const GLfloat *); -GLAPI void APIENTRY glGetObjectParameterfvARB (GLhandleARB, GLenum, GLfloat *); -GLAPI void APIENTRY glGetObjectParameterivARB (GLhandleARB, GLenum, GLint *); -GLAPI void APIENTRY glGetInfoLogARB (GLhandleARB, GLsizei, GLsizei *, GLcharARB *); -GLAPI void APIENTRY glGetAttachedObjectsARB (GLhandleARB, GLsizei, GLsizei *, GLhandleARB *); -GLAPI GLint APIENTRY glGetUniformLocationARB (GLhandleARB, const GLcharARB *); -GLAPI void APIENTRY glGetActiveUniformARB (GLhandleARB, GLuint, GLsizei, GLsizei *, GLint *, GLenum *, GLcharARB *); -GLAPI void APIENTRY glGetUniformfvARB (GLhandleARB, GLint, GLfloat *); -GLAPI void APIENTRY glGetUniformivARB (GLhandleARB, GLint, GLint *); -GLAPI void APIENTRY glGetShaderSourceARB (GLhandleARB, GLsizei, GLsizei *, GLcharARB *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLDELETEOBJECTARBPROC) (GLhandleARB obj); -typedef GLhandleARB (APIENTRYP PFNGLGETHANDLEARBPROC) (GLenum pname); -typedef void (APIENTRYP PFNGLDETACHOBJECTARBPROC) (GLhandleARB containerObj, GLhandleARB attachedObj); -typedef GLhandleARB (APIENTRYP PFNGLCREATESHADEROBJECTARBPROC) (GLenum shaderType); -typedef void (APIENTRYP PFNGLSHADERSOURCEARBPROC) (GLhandleARB shaderObj, GLsizei count, const GLcharARB* *string, const GLint *length); -typedef void (APIENTRYP PFNGLCOMPILESHADERARBPROC) (GLhandleARB shaderObj); -typedef GLhandleARB (APIENTRYP PFNGLCREATEPROGRAMOBJECTARBPROC) (void); -typedef void (APIENTRYP PFNGLATTACHOBJECTARBPROC) (GLhandleARB containerObj, GLhandleARB obj); -typedef void (APIENTRYP PFNGLLINKPROGRAMARBPROC) (GLhandleARB programObj); -typedef void (APIENTRYP PFNGLUSEPROGRAMOBJECTARBPROC) (GLhandleARB programObj); -typedef void (APIENTRYP PFNGLVALIDATEPROGRAMARBPROC) (GLhandleARB programObj); -typedef void (APIENTRYP PFNGLUNIFORM1FARBPROC) (GLint location, GLfloat v0); -typedef void (APIENTRYP PFNGLUNIFORM2FARBPROC) (GLint location, GLfloat v0, GLfloat v1); -typedef void (APIENTRYP PFNGLUNIFORM3FARBPROC) (GLint location, GLfloat v0, GLfloat v1, GLfloat v2); -typedef void (APIENTRYP PFNGLUNIFORM4FARBPROC) (GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3); -typedef void (APIENTRYP PFNGLUNIFORM1IARBPROC) (GLint location, GLint v0); -typedef void (APIENTRYP PFNGLUNIFORM2IARBPROC) (GLint location, GLint v0, GLint v1); -typedef void (APIENTRYP PFNGLUNIFORM3IARBPROC) (GLint location, GLint v0, GLint v1, GLint v2); -typedef void (APIENTRYP PFNGLUNIFORM4IARBPROC) (GLint location, GLint v0, GLint v1, GLint v2, GLint v3); -typedef void (APIENTRYP PFNGLUNIFORM1FVARBPROC) (GLint location, GLsizei count, const GLfloat *value); -typedef void (APIENTRYP PFNGLUNIFORM2FVARBPROC) (GLint location, GLsizei count, const GLfloat *value); -typedef void (APIENTRYP PFNGLUNIFORM3FVARBPROC) (GLint location, GLsizei count, const GLfloat *value); -typedef void (APIENTRYP PFNGLUNIFORM4FVARBPROC) (GLint location, GLsizei count, const GLfloat *value); -typedef void (APIENTRYP PFNGLUNIFORM1IVARBPROC) (GLint location, GLsizei count, const GLint *value); -typedef void (APIENTRYP PFNGLUNIFORM2IVARBPROC) (GLint location, GLsizei count, const GLint *value); -typedef void (APIENTRYP PFNGLUNIFORM3IVARBPROC) (GLint location, GLsizei count, const GLint *value); -typedef void (APIENTRYP PFNGLUNIFORM4IVARBPROC) (GLint location, GLsizei count, const GLint *value); -typedef void (APIENTRYP PFNGLUNIFORMMATRIX2FVARBPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); -typedef void (APIENTRYP PFNGLUNIFORMMATRIX3FVARBPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); -typedef void (APIENTRYP PFNGLUNIFORMMATRIX4FVARBPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); -typedef void (APIENTRYP PFNGLGETOBJECTPARAMETERFVARBPROC) (GLhandleARB obj, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETOBJECTPARAMETERIVARBPROC) (GLhandleARB obj, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETINFOLOGARBPROC) (GLhandleARB obj, GLsizei maxLength, GLsizei *length, GLcharARB *infoLog); -typedef void (APIENTRYP PFNGLGETATTACHEDOBJECTSARBPROC) (GLhandleARB containerObj, GLsizei maxCount, GLsizei *count, GLhandleARB *obj); -typedef GLint (APIENTRYP PFNGLGETUNIFORMLOCATIONARBPROC) (GLhandleARB programObj, const GLcharARB *name); -typedef void (APIENTRYP PFNGLGETACTIVEUNIFORMARBPROC) (GLhandleARB programObj, GLuint index, GLsizei maxLength, GLsizei *length, GLint *size, GLenum *type, GLcharARB *name); -typedef void (APIENTRYP PFNGLGETUNIFORMFVARBPROC) (GLhandleARB programObj, GLint location, GLfloat *params); -typedef void (APIENTRYP PFNGLGETUNIFORMIVARBPROC) (GLhandleARB programObj, GLint location, GLint *params); -typedef void (APIENTRYP PFNGLGETSHADERSOURCEARBPROC) (GLhandleARB obj, GLsizei maxLength, GLsizei *length, GLcharARB *source); -#endif - -#ifndef GL_ARB_vertex_shader -#define GL_ARB_vertex_shader 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glBindAttribLocationARB (GLhandleARB, GLuint, const GLcharARB *); -GLAPI void APIENTRY glGetActiveAttribARB (GLhandleARB, GLuint, GLsizei, GLsizei *, GLint *, GLenum *, GLcharARB *); -GLAPI GLint APIENTRY glGetAttribLocationARB (GLhandleARB, const GLcharARB *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLBINDATTRIBLOCATIONARBPROC) (GLhandleARB programObj, GLuint index, const GLcharARB *name); -typedef void (APIENTRYP PFNGLGETACTIVEATTRIBARBPROC) (GLhandleARB programObj, GLuint index, GLsizei maxLength, GLsizei *length, GLint *size, GLenum *type, GLcharARB *name); -typedef GLint (APIENTRYP PFNGLGETATTRIBLOCATIONARBPROC) (GLhandleARB programObj, const GLcharARB *name); -#endif - -#ifndef GL_ARB_fragment_shader -#define GL_ARB_fragment_shader 1 -#endif - -#ifndef GL_ARB_shading_language_100 -#define GL_ARB_shading_language_100 1 -#endif - -#ifndef GL_ARB_texture_non_power_of_two -#define GL_ARB_texture_non_power_of_two 1 -#endif - -#ifndef GL_ARB_point_sprite -#define GL_ARB_point_sprite 1 -#endif - -#ifndef GL_ARB_fragment_program_shadow -#define GL_ARB_fragment_program_shadow 1 -#endif - -#ifndef GL_ARB_draw_buffers -#define GL_ARB_draw_buffers 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glDrawBuffersARB (GLsizei, const GLenum *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLDRAWBUFFERSARBPROC) (GLsizei n, const GLenum *bufs); -#endif - -#ifndef GL_ARB_texture_rectangle -#define GL_ARB_texture_rectangle 1 -#endif - -#ifndef GL_ARB_color_buffer_float -#define GL_ARB_color_buffer_float 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glClampColorARB (GLenum, GLenum); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLCLAMPCOLORARBPROC) (GLenum target, GLenum clamp); -#endif - -#ifndef GL_ARB_half_float_pixel -#define GL_ARB_half_float_pixel 1 -#endif - -#ifndef GL_ARB_texture_float -#define GL_ARB_texture_float 1 -#endif - -#ifndef GL_ARB_pixel_buffer_object -#define GL_ARB_pixel_buffer_object 1 -#endif - -#ifndef GL_ARB_depth_buffer_float -#define GL_ARB_depth_buffer_float 1 -#endif - -#ifndef GL_ARB_draw_instanced -#define GL_ARB_draw_instanced 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glDrawArraysInstancedARB (GLenum, GLint, GLsizei, GLsizei); -GLAPI void APIENTRY glDrawElementsInstancedARB (GLenum, GLsizei, GLenum, const GLvoid *, GLsizei); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLDRAWARRAYSINSTANCEDARBPROC) (GLenum mode, GLint first, GLsizei count, GLsizei primcount); -typedef void (APIENTRYP PFNGLDRAWELEMENTSINSTANCEDARBPROC) (GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei primcount); -#endif - -#ifndef GL_ARB_framebuffer_object -#define GL_ARB_framebuffer_object 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI GLboolean APIENTRY glIsRenderbuffer (GLuint); -GLAPI void APIENTRY glBindRenderbuffer (GLenum, GLuint); -GLAPI void APIENTRY glDeleteRenderbuffers (GLsizei, const GLuint *); -GLAPI void APIENTRY glGenRenderbuffers (GLsizei, GLuint *); -GLAPI void APIENTRY glRenderbufferStorage (GLenum, GLenum, GLsizei, GLsizei); -GLAPI void APIENTRY glGetRenderbufferParameteriv (GLenum, GLenum, GLint *); -GLAPI GLboolean APIENTRY glIsFramebuffer (GLuint); -GLAPI void APIENTRY glBindFramebuffer (GLenum, GLuint); -GLAPI void APIENTRY glDeleteFramebuffers (GLsizei, const GLuint *); -GLAPI void APIENTRY glGenFramebuffers (GLsizei, GLuint *); -GLAPI GLenum APIENTRY glCheckFramebufferStatus (GLenum); -GLAPI void APIENTRY glFramebufferTexture1D (GLenum, GLenum, GLenum, GLuint, GLint); -GLAPI void APIENTRY glFramebufferTexture2D (GLenum, GLenum, GLenum, GLuint, GLint); -GLAPI void APIENTRY glFramebufferTexture3D (GLenum, GLenum, GLenum, GLuint, GLint, GLint); -GLAPI void APIENTRY glFramebufferRenderbuffer (GLenum, GLenum, GLenum, GLuint); -GLAPI void APIENTRY glGetFramebufferAttachmentParameteriv (GLenum, GLenum, GLenum, GLint *); -GLAPI void APIENTRY glGenerateMipmap (GLenum); -GLAPI void APIENTRY glBlitFramebuffer (GLint, GLint, GLint, GLint, GLint, GLint, GLint, GLint, GLbitfield, GLenum); -GLAPI void APIENTRY glRenderbufferStorageMultisample (GLenum, GLsizei, GLenum, GLsizei, GLsizei); -GLAPI void APIENTRY glFramebufferTextureLayer (GLenum, GLenum, GLuint, GLint, GLint); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef GLboolean (APIENTRYP PFNGLISRENDERBUFFERPROC) (GLuint renderbuffer); -typedef void (APIENTRYP PFNGLBINDRENDERBUFFERPROC) (GLenum target, GLuint renderbuffer); -typedef void (APIENTRYP PFNGLDELETERENDERBUFFERSPROC) (GLsizei n, const GLuint *renderbuffers); -typedef void (APIENTRYP PFNGLGENRENDERBUFFERSPROC) (GLsizei n, GLuint *renderbuffers); -typedef void (APIENTRYP PFNGLRENDERBUFFERSTORAGEPROC) (GLenum target, GLenum internalformat, GLsizei width, GLsizei height); -typedef void (APIENTRYP PFNGLGETRENDERBUFFERPARAMETERIVPROC) (GLenum target, GLenum pname, GLint *params); -typedef GLboolean (APIENTRYP PFNGLISFRAMEBUFFERPROC) (GLuint framebuffer); -typedef void (APIENTRYP PFNGLBINDFRAMEBUFFERPROC) (GLenum target, GLuint framebuffer); -typedef void (APIENTRYP PFNGLDELETEFRAMEBUFFERSPROC) (GLsizei n, const GLuint *framebuffers); -typedef void (APIENTRYP PFNGLGENFRAMEBUFFERSPROC) (GLsizei n, GLuint *framebuffers); -typedef GLenum (APIENTRYP PFNGLCHECKFRAMEBUFFERSTATUSPROC) (GLenum target); -typedef void (APIENTRYP PFNGLFRAMEBUFFERTEXTURE1DPROC) (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level); -typedef void (APIENTRYP PFNGLFRAMEBUFFERTEXTURE2DPROC) (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level); -typedef void (APIENTRYP PFNGLFRAMEBUFFERTEXTURE3DPROC) (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset); -typedef void (APIENTRYP PFNGLFRAMEBUFFERRENDERBUFFERPROC) (GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer); -typedef void (APIENTRYP PFNGLGETFRAMEBUFFERATTACHMENTPARAMETERIVPROC) (GLenum target, GLenum attachment, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGENERATEMIPMAPPROC) (GLenum target); -typedef void (APIENTRYP PFNGLBLITFRAMEBUFFERPROC) (GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter); -typedef void (APIENTRYP PFNGLRENDERBUFFERSTORAGEMULTISAMPLEPROC) (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height); -typedef void (APIENTRYP PFNGLFRAMEBUFFERTEXTURELAYERPROC) (GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer); -#endif - -#ifndef GL_ARB_framebuffer_sRGB -#define GL_ARB_framebuffer_sRGB 1 -#endif - -#ifndef GL_ARB_geometry_shader4 -#define GL_ARB_geometry_shader4 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glProgramParameteriARB (GLuint, GLenum, GLint); -GLAPI void APIENTRY glFramebufferTextureARB (GLenum, GLenum, GLuint, GLint); -GLAPI void APIENTRY glFramebufferTextureLayerARB (GLenum, GLenum, GLuint, GLint, GLint); -GLAPI void APIENTRY glFramebufferTextureFaceARB (GLenum, GLenum, GLuint, GLint, GLenum); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLPROGRAMPARAMETERIARBPROC) (GLuint program, GLenum pname, GLint value); -typedef void (APIENTRYP PFNGLFRAMEBUFFERTEXTUREARBPROC) (GLenum target, GLenum attachment, GLuint texture, GLint level); -typedef void (APIENTRYP PFNGLFRAMEBUFFERTEXTURELAYERARBPROC) (GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer); -typedef void (APIENTRYP PFNGLFRAMEBUFFERTEXTUREFACEARBPROC) (GLenum target, GLenum attachment, GLuint texture, GLint level, GLenum face); -#endif - -#ifndef GL_ARB_half_float_vertex -#define GL_ARB_half_float_vertex 1 -#endif - -#ifndef GL_ARB_instanced_arrays -#define GL_ARB_instanced_arrays 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glVertexAttribDivisor (GLuint, GLuint); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLVERTEXATTRIBDIVISORPROC) (GLuint index, GLuint divisor); -#endif - -#ifndef GL_ARB_map_buffer_range -#define GL_ARB_map_buffer_range 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glMapBufferRange (GLenum, GLintptr, GLsizeiptr, GLbitfield); -GLAPI void APIENTRY glFlushMappedBufferRange (GLenum, GLintptr, GLsizeiptr); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLMAPBUFFERRANGEPROC) (GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access); -typedef void (APIENTRYP PFNGLFLUSHMAPPEDBUFFERRANGEPROC) (GLenum target, GLintptr offset, GLsizeiptr length); -#endif - -#ifndef GL_ARB_texture_buffer_object -#define GL_ARB_texture_buffer_object 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glTexBufferARB (GLenum, GLenum, GLuint); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLTEXBUFFERARBPROC) (GLenum target, GLenum internalformat, GLuint buffer); -#endif - -#ifndef GL_ARB_texture_compression_rgtc -#define GL_ARB_texture_compression_rgtc 1 -#endif - -#ifndef GL_ARB_texture_rg -#define GL_ARB_texture_rg 1 -#endif - -#ifndef GL_ARB_vertex_array_object -#define GL_ARB_vertex_array_object 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glBindVertexArray (GLuint); -GLAPI void APIENTRY glDeleteVertexArrays (GLsizei, const GLuint *); -GLAPI void APIENTRY glGenVertexArrays (GLsizei, GLuint *); -GLAPI GLboolean APIENTRY glIsVertexArray (GLuint); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLBINDVERTEXARRAYPROC) (GLuint array); -typedef void (APIENTRYP PFNGLDELETEVERTEXARRAYSPROC) (GLsizei n, const GLuint *arrays); -typedef void (APIENTRYP PFNGLGENVERTEXARRAYSPROC) (GLsizei n, GLuint *arrays); -typedef GLboolean (APIENTRYP PFNGLISVERTEXARRAYPROC) (GLuint array); -#endif - -#ifndef GL_EXT_abgr -#define GL_EXT_abgr 1 -#endif - -#ifndef GL_EXT_blend_color -#define GL_EXT_blend_color 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glBlendColorEXT (GLclampf, GLclampf, GLclampf, GLclampf); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLBLENDCOLOREXTPROC) (GLclampf red, GLclampf green, GLclampf blue, GLclampf alpha); -#endif - -#ifndef GL_EXT_polygon_offset -#define GL_EXT_polygon_offset 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glPolygonOffsetEXT (GLfloat, GLfloat); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLPOLYGONOFFSETEXTPROC) (GLfloat factor, GLfloat bias); -#endif - -#ifndef GL_EXT_texture -#define GL_EXT_texture 1 -#endif - -#ifndef GL_EXT_texture3D -#define GL_EXT_texture3D 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glTexImage3DEXT (GLenum, GLint, GLenum, GLsizei, GLsizei, GLsizei, GLint, GLenum, GLenum, const GLvoid *); -GLAPI void APIENTRY glTexSubImage3DEXT (GLenum, GLint, GLint, GLint, GLint, GLsizei, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLTEXIMAGE3DEXTPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels); -typedef void (APIENTRYP PFNGLTEXSUBIMAGE3DEXTPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels); -#endif - -#ifndef GL_SGIS_texture_filter4 -#define GL_SGIS_texture_filter4 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glGetTexFilterFuncSGIS (GLenum, GLenum, GLfloat *); -GLAPI void APIENTRY glTexFilterFuncSGIS (GLenum, GLenum, GLsizei, const GLfloat *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLGETTEXFILTERFUNCSGISPROC) (GLenum target, GLenum filter, GLfloat *weights); -typedef void (APIENTRYP PFNGLTEXFILTERFUNCSGISPROC) (GLenum target, GLenum filter, GLsizei n, const GLfloat *weights); -#endif - -#ifndef GL_EXT_subtexture -#define GL_EXT_subtexture 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glTexSubImage1DEXT (GLenum, GLint, GLint, GLsizei, GLenum, GLenum, const GLvoid *); -GLAPI void APIENTRY glTexSubImage2DEXT (GLenum, GLint, GLint, GLint, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLTEXSUBIMAGE1DEXTPROC) (GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels); -typedef void (APIENTRYP PFNGLTEXSUBIMAGE2DEXTPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels); -#endif - -#ifndef GL_EXT_copy_texture -#define GL_EXT_copy_texture 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glCopyTexImage1DEXT (GLenum, GLint, GLenum, GLint, GLint, GLsizei, GLint); -GLAPI void APIENTRY glCopyTexImage2DEXT (GLenum, GLint, GLenum, GLint, GLint, GLsizei, GLsizei, GLint); -GLAPI void APIENTRY glCopyTexSubImage1DEXT (GLenum, GLint, GLint, GLint, GLint, GLsizei); -GLAPI void APIENTRY glCopyTexSubImage2DEXT (GLenum, GLint, GLint, GLint, GLint, GLint, GLsizei, GLsizei); -GLAPI void APIENTRY glCopyTexSubImage3DEXT (GLenum, GLint, GLint, GLint, GLint, GLint, GLint, GLsizei, GLsizei); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLCOPYTEXIMAGE1DEXTPROC) (GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border); -typedef void (APIENTRYP PFNGLCOPYTEXIMAGE2DEXTPROC) (GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border); -typedef void (APIENTRYP PFNGLCOPYTEXSUBIMAGE1DEXTPROC) (GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width); -typedef void (APIENTRYP PFNGLCOPYTEXSUBIMAGE2DEXTPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height); -typedef void (APIENTRYP PFNGLCOPYTEXSUBIMAGE3DEXTPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height); -#endif - -#ifndef GL_EXT_histogram -#define GL_EXT_histogram 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glGetHistogramEXT (GLenum, GLboolean, GLenum, GLenum, GLvoid *); -GLAPI void APIENTRY glGetHistogramParameterfvEXT (GLenum, GLenum, GLfloat *); -GLAPI void APIENTRY glGetHistogramParameterivEXT (GLenum, GLenum, GLint *); -GLAPI void APIENTRY glGetMinmaxEXT (GLenum, GLboolean, GLenum, GLenum, GLvoid *); -GLAPI void APIENTRY glGetMinmaxParameterfvEXT (GLenum, GLenum, GLfloat *); -GLAPI void APIENTRY glGetMinmaxParameterivEXT (GLenum, GLenum, GLint *); -GLAPI void APIENTRY glHistogramEXT (GLenum, GLsizei, GLenum, GLboolean); -GLAPI void APIENTRY glMinmaxEXT (GLenum, GLenum, GLboolean); -GLAPI void APIENTRY glResetHistogramEXT (GLenum); -GLAPI void APIENTRY glResetMinmaxEXT (GLenum); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLGETHISTOGRAMEXTPROC) (GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values); -typedef void (APIENTRYP PFNGLGETHISTOGRAMPARAMETERFVEXTPROC) (GLenum target, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETHISTOGRAMPARAMETERIVEXTPROC) (GLenum target, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETMINMAXEXTPROC) (GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values); -typedef void (APIENTRYP PFNGLGETMINMAXPARAMETERFVEXTPROC) (GLenum target, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETMINMAXPARAMETERIVEXTPROC) (GLenum target, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLHISTOGRAMEXTPROC) (GLenum target, GLsizei width, GLenum internalformat, GLboolean sink); -typedef void (APIENTRYP PFNGLMINMAXEXTPROC) (GLenum target, GLenum internalformat, GLboolean sink); -typedef void (APIENTRYP PFNGLRESETHISTOGRAMEXTPROC) (GLenum target); -typedef void (APIENTRYP PFNGLRESETMINMAXEXTPROC) (GLenum target); -#endif - -#ifndef GL_EXT_convolution -#define GL_EXT_convolution 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glConvolutionFilter1DEXT (GLenum, GLenum, GLsizei, GLenum, GLenum, const GLvoid *); -GLAPI void APIENTRY glConvolutionFilter2DEXT (GLenum, GLenum, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *); -GLAPI void APIENTRY glConvolutionParameterfEXT (GLenum, GLenum, GLfloat); -GLAPI void APIENTRY glConvolutionParameterfvEXT (GLenum, GLenum, const GLfloat *); -GLAPI void APIENTRY glConvolutionParameteriEXT (GLenum, GLenum, GLint); -GLAPI void APIENTRY glConvolutionParameterivEXT (GLenum, GLenum, const GLint *); -GLAPI void APIENTRY glCopyConvolutionFilter1DEXT (GLenum, GLenum, GLint, GLint, GLsizei); -GLAPI void APIENTRY glCopyConvolutionFilter2DEXT (GLenum, GLenum, GLint, GLint, GLsizei, GLsizei); -GLAPI void APIENTRY glGetConvolutionFilterEXT (GLenum, GLenum, GLenum, GLvoid *); -GLAPI void APIENTRY glGetConvolutionParameterfvEXT (GLenum, GLenum, GLfloat *); -GLAPI void APIENTRY glGetConvolutionParameterivEXT (GLenum, GLenum, GLint *); -GLAPI void APIENTRY glGetSeparableFilterEXT (GLenum, GLenum, GLenum, GLvoid *, GLvoid *, GLvoid *); -GLAPI void APIENTRY glSeparableFilter2DEXT (GLenum, GLenum, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *, const GLvoid *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLCONVOLUTIONFILTER1DEXTPROC) (GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *image); -typedef void (APIENTRYP PFNGLCONVOLUTIONFILTER2DEXTPROC) (GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *image); -typedef void (APIENTRYP PFNGLCONVOLUTIONPARAMETERFEXTPROC) (GLenum target, GLenum pname, GLfloat params); -typedef void (APIENTRYP PFNGLCONVOLUTIONPARAMETERFVEXTPROC) (GLenum target, GLenum pname, const GLfloat *params); -typedef void (APIENTRYP PFNGLCONVOLUTIONPARAMETERIEXTPROC) (GLenum target, GLenum pname, GLint params); -typedef void (APIENTRYP PFNGLCONVOLUTIONPARAMETERIVEXTPROC) (GLenum target, GLenum pname, const GLint *params); -typedef void (APIENTRYP PFNGLCOPYCONVOLUTIONFILTER1DEXTPROC) (GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width); -typedef void (APIENTRYP PFNGLCOPYCONVOLUTIONFILTER2DEXTPROC) (GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height); -typedef void (APIENTRYP PFNGLGETCONVOLUTIONFILTEREXTPROC) (GLenum target, GLenum format, GLenum type, GLvoid *image); -typedef void (APIENTRYP PFNGLGETCONVOLUTIONPARAMETERFVEXTPROC) (GLenum target, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETCONVOLUTIONPARAMETERIVEXTPROC) (GLenum target, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETSEPARABLEFILTEREXTPROC) (GLenum target, GLenum format, GLenum type, GLvoid *row, GLvoid *column, GLvoid *span); -typedef void (APIENTRYP PFNGLSEPARABLEFILTER2DEXTPROC) (GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *row, const GLvoid *column); -#endif - -#ifndef GL_SGI_color_matrix -#define GL_SGI_color_matrix 1 -#endif - -#ifndef GL_SGI_color_table -#define GL_SGI_color_table 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glColorTableSGI (GLenum, GLenum, GLsizei, GLenum, GLenum, const GLvoid *); -GLAPI void APIENTRY glColorTableParameterfvSGI (GLenum, GLenum, const GLfloat *); -GLAPI void APIENTRY glColorTableParameterivSGI (GLenum, GLenum, const GLint *); -GLAPI void APIENTRY glCopyColorTableSGI (GLenum, GLenum, GLint, GLint, GLsizei); -GLAPI void APIENTRY glGetColorTableSGI (GLenum, GLenum, GLenum, GLvoid *); -GLAPI void APIENTRY glGetColorTableParameterfvSGI (GLenum, GLenum, GLfloat *); -GLAPI void APIENTRY glGetColorTableParameterivSGI (GLenum, GLenum, GLint *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLCOLORTABLESGIPROC) (GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *table); -typedef void (APIENTRYP PFNGLCOLORTABLEPARAMETERFVSGIPROC) (GLenum target, GLenum pname, const GLfloat *params); -typedef void (APIENTRYP PFNGLCOLORTABLEPARAMETERIVSGIPROC) (GLenum target, GLenum pname, const GLint *params); -typedef void (APIENTRYP PFNGLCOPYCOLORTABLESGIPROC) (GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width); -typedef void (APIENTRYP PFNGLGETCOLORTABLESGIPROC) (GLenum target, GLenum format, GLenum type, GLvoid *table); -typedef void (APIENTRYP PFNGLGETCOLORTABLEPARAMETERFVSGIPROC) (GLenum target, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETCOLORTABLEPARAMETERIVSGIPROC) (GLenum target, GLenum pname, GLint *params); -#endif - -#ifndef GL_SGIX_pixel_texture -#define GL_SGIX_pixel_texture 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glPixelTexGenSGIX (GLenum); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLPIXELTEXGENSGIXPROC) (GLenum mode); -#endif - -#ifndef GL_SGIS_pixel_texture -#define GL_SGIS_pixel_texture 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glPixelTexGenParameteriSGIS (GLenum, GLint); -GLAPI void APIENTRY glPixelTexGenParameterivSGIS (GLenum, const GLint *); -GLAPI void APIENTRY glPixelTexGenParameterfSGIS (GLenum, GLfloat); -GLAPI void APIENTRY glPixelTexGenParameterfvSGIS (GLenum, const GLfloat *); -GLAPI void APIENTRY glGetPixelTexGenParameterivSGIS (GLenum, GLint *); -GLAPI void APIENTRY glGetPixelTexGenParameterfvSGIS (GLenum, GLfloat *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLPIXELTEXGENPARAMETERISGISPROC) (GLenum pname, GLint param); -typedef void (APIENTRYP PFNGLPIXELTEXGENPARAMETERIVSGISPROC) (GLenum pname, const GLint *params); -typedef void (APIENTRYP PFNGLPIXELTEXGENPARAMETERFSGISPROC) (GLenum pname, GLfloat param); -typedef void (APIENTRYP PFNGLPIXELTEXGENPARAMETERFVSGISPROC) (GLenum pname, const GLfloat *params); -typedef void (APIENTRYP PFNGLGETPIXELTEXGENPARAMETERIVSGISPROC) (GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETPIXELTEXGENPARAMETERFVSGISPROC) (GLenum pname, GLfloat *params); -#endif - -#ifndef GL_SGIS_texture4D -#define GL_SGIS_texture4D 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glTexImage4DSGIS (GLenum, GLint, GLenum, GLsizei, GLsizei, GLsizei, GLsizei, GLint, GLenum, GLenum, const GLvoid *); -GLAPI void APIENTRY glTexSubImage4DSGIS (GLenum, GLint, GLint, GLint, GLint, GLint, GLsizei, GLsizei, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLTEXIMAGE4DSGISPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLsizei size4d, GLint border, GLenum format, GLenum type, const GLvoid *pixels); -typedef void (APIENTRYP PFNGLTEXSUBIMAGE4DSGISPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint woffset, GLsizei width, GLsizei height, GLsizei depth, GLsizei size4d, GLenum format, GLenum type, const GLvoid *pixels); -#endif - -#ifndef GL_SGI_texture_color_table -#define GL_SGI_texture_color_table 1 -#endif - -#ifndef GL_EXT_cmyka -#define GL_EXT_cmyka 1 -#endif - -#ifndef GL_EXT_texture_object -#define GL_EXT_texture_object 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI GLboolean APIENTRY glAreTexturesResidentEXT (GLsizei, const GLuint *, GLboolean *); -GLAPI void APIENTRY glBindTextureEXT (GLenum, GLuint); -GLAPI void APIENTRY glDeleteTexturesEXT (GLsizei, const GLuint *); -GLAPI void APIENTRY glGenTexturesEXT (GLsizei, GLuint *); -GLAPI GLboolean APIENTRY glIsTextureEXT (GLuint); -GLAPI void APIENTRY glPrioritizeTexturesEXT (GLsizei, const GLuint *, const GLclampf *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef GLboolean (APIENTRYP PFNGLARETEXTURESRESIDENTEXTPROC) (GLsizei n, const GLuint *textures, GLboolean *residences); -typedef void (APIENTRYP PFNGLBINDTEXTUREEXTPROC) (GLenum target, GLuint texture); -typedef void (APIENTRYP PFNGLDELETETEXTURESEXTPROC) (GLsizei n, const GLuint *textures); -typedef void (APIENTRYP PFNGLGENTEXTURESEXTPROC) (GLsizei n, GLuint *textures); -typedef GLboolean (APIENTRYP PFNGLISTEXTUREEXTPROC) (GLuint texture); -typedef void (APIENTRYP PFNGLPRIORITIZETEXTURESEXTPROC) (GLsizei n, const GLuint *textures, const GLclampf *priorities); -#endif - -#ifndef GL_SGIS_detail_texture -#define GL_SGIS_detail_texture 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glDetailTexFuncSGIS (GLenum, GLsizei, const GLfloat *); -GLAPI void APIENTRY glGetDetailTexFuncSGIS (GLenum, GLfloat *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLDETAILTEXFUNCSGISPROC) (GLenum target, GLsizei n, const GLfloat *points); -typedef void (APIENTRYP PFNGLGETDETAILTEXFUNCSGISPROC) (GLenum target, GLfloat *points); -#endif - -#ifndef GL_SGIS_sharpen_texture -#define GL_SGIS_sharpen_texture 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glSharpenTexFuncSGIS (GLenum, GLsizei, const GLfloat *); -GLAPI void APIENTRY glGetSharpenTexFuncSGIS (GLenum, GLfloat *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLSHARPENTEXFUNCSGISPROC) (GLenum target, GLsizei n, const GLfloat *points); -typedef void (APIENTRYP PFNGLGETSHARPENTEXFUNCSGISPROC) (GLenum target, GLfloat *points); -#endif - -#ifndef GL_EXT_packed_pixels -#define GL_EXT_packed_pixels 1 -#endif - -#ifndef GL_SGIS_texture_lod -#define GL_SGIS_texture_lod 1 -#endif - -#ifndef GL_SGIS_multisample -#define GL_SGIS_multisample 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glSampleMaskSGIS (GLclampf, GLboolean); -GLAPI void APIENTRY glSamplePatternSGIS (GLenum); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLSAMPLEMASKSGISPROC) (GLclampf value, GLboolean invert); -typedef void (APIENTRYP PFNGLSAMPLEPATTERNSGISPROC) (GLenum pattern); -#endif - -#ifndef GL_EXT_rescale_normal -#define GL_EXT_rescale_normal 1 -#endif - -#ifndef GL_EXT_vertex_array -#define GL_EXT_vertex_array 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glArrayElementEXT (GLint); -GLAPI void APIENTRY glColorPointerEXT (GLint, GLenum, GLsizei, GLsizei, const GLvoid *); -GLAPI void APIENTRY glDrawArraysEXT (GLenum, GLint, GLsizei); -GLAPI void APIENTRY glEdgeFlagPointerEXT (GLsizei, GLsizei, const GLboolean *); -GLAPI void APIENTRY glGetPointervEXT (GLenum, GLvoid* *); -GLAPI void APIENTRY glIndexPointerEXT (GLenum, GLsizei, GLsizei, const GLvoid *); -GLAPI void APIENTRY glNormalPointerEXT (GLenum, GLsizei, GLsizei, const GLvoid *); -GLAPI void APIENTRY glTexCoordPointerEXT (GLint, GLenum, GLsizei, GLsizei, const GLvoid *); -GLAPI void APIENTRY glVertexPointerEXT (GLint, GLenum, GLsizei, GLsizei, const GLvoid *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLARRAYELEMENTEXTPROC) (GLint i); -typedef void (APIENTRYP PFNGLCOLORPOINTEREXTPROC) (GLint size, GLenum type, GLsizei stride, GLsizei count, const GLvoid *pointer); -typedef void (APIENTRYP PFNGLDRAWARRAYSEXTPROC) (GLenum mode, GLint first, GLsizei count); -typedef void (APIENTRYP PFNGLEDGEFLAGPOINTEREXTPROC) (GLsizei stride, GLsizei count, const GLboolean *pointer); -typedef void (APIENTRYP PFNGLGETPOINTERVEXTPROC) (GLenum pname, GLvoid* *params); -typedef void (APIENTRYP PFNGLINDEXPOINTEREXTPROC) (GLenum type, GLsizei stride, GLsizei count, const GLvoid *pointer); -typedef void (APIENTRYP PFNGLNORMALPOINTEREXTPROC) (GLenum type, GLsizei stride, GLsizei count, const GLvoid *pointer); -typedef void (APIENTRYP PFNGLTEXCOORDPOINTEREXTPROC) (GLint size, GLenum type, GLsizei stride, GLsizei count, const GLvoid *pointer); -typedef void (APIENTRYP PFNGLVERTEXPOINTEREXTPROC) (GLint size, GLenum type, GLsizei stride, GLsizei count, const GLvoid *pointer); -#endif - -#ifndef GL_EXT_misc_attribute -#define GL_EXT_misc_attribute 1 -#endif - -#ifndef GL_SGIS_generate_mipmap -#define GL_SGIS_generate_mipmap 1 -#endif - -#ifndef GL_SGIX_clipmap -#define GL_SGIX_clipmap 1 -#endif - -#ifndef GL_SGIX_shadow -#define GL_SGIX_shadow 1 -#endif - -#ifndef GL_SGIS_texture_edge_clamp -#define GL_SGIS_texture_edge_clamp 1 -#endif - -#ifndef GL_SGIS_texture_border_clamp -#define GL_SGIS_texture_border_clamp 1 -#endif - -#ifndef GL_EXT_blend_minmax -#define GL_EXT_blend_minmax 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glBlendEquationEXT (GLenum); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLBLENDEQUATIONEXTPROC) (GLenum mode); -#endif - -#ifndef GL_EXT_blend_subtract -#define GL_EXT_blend_subtract 1 -#endif - -#ifndef GL_EXT_blend_logic_op -#define GL_EXT_blend_logic_op 1 -#endif - -#ifndef GL_SGIX_interlace -#define GL_SGIX_interlace 1 -#endif - -#ifndef GL_SGIX_pixel_tiles -#define GL_SGIX_pixel_tiles 1 -#endif - -#ifndef GL_SGIX_texture_select -#define GL_SGIX_texture_select 1 -#endif - -#ifndef GL_SGIX_sprite -#define GL_SGIX_sprite 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glSpriteParameterfSGIX (GLenum, GLfloat); -GLAPI void APIENTRY glSpriteParameterfvSGIX (GLenum, const GLfloat *); -GLAPI void APIENTRY glSpriteParameteriSGIX (GLenum, GLint); -GLAPI void APIENTRY glSpriteParameterivSGIX (GLenum, const GLint *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLSPRITEPARAMETERFSGIXPROC) (GLenum pname, GLfloat param); -typedef void (APIENTRYP PFNGLSPRITEPARAMETERFVSGIXPROC) (GLenum pname, const GLfloat *params); -typedef void (APIENTRYP PFNGLSPRITEPARAMETERISGIXPROC) (GLenum pname, GLint param); -typedef void (APIENTRYP PFNGLSPRITEPARAMETERIVSGIXPROC) (GLenum pname, const GLint *params); -#endif - -#ifndef GL_SGIX_texture_multi_buffer -#define GL_SGIX_texture_multi_buffer 1 -#endif - -#ifndef GL_EXT_point_parameters -#define GL_EXT_point_parameters 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glPointParameterfEXT (GLenum, GLfloat); -GLAPI void APIENTRY glPointParameterfvEXT (GLenum, const GLfloat *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLPOINTPARAMETERFEXTPROC) (GLenum pname, GLfloat param); -typedef void (APIENTRYP PFNGLPOINTPARAMETERFVEXTPROC) (GLenum pname, const GLfloat *params); -#endif - -#ifndef GL_SGIS_point_parameters -#define GL_SGIS_point_parameters 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glPointParameterfSGIS (GLenum, GLfloat); -GLAPI void APIENTRY glPointParameterfvSGIS (GLenum, const GLfloat *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLPOINTPARAMETERFSGISPROC) (GLenum pname, GLfloat param); -typedef void (APIENTRYP PFNGLPOINTPARAMETERFVSGISPROC) (GLenum pname, const GLfloat *params); -#endif - -#ifndef GL_SGIX_instruments -#define GL_SGIX_instruments 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI GLint APIENTRY glGetInstrumentsSGIX (void); -GLAPI void APIENTRY glInstrumentsBufferSGIX (GLsizei, GLint *); -GLAPI GLint APIENTRY glPollInstrumentsSGIX (GLint *); -GLAPI void APIENTRY glReadInstrumentsSGIX (GLint); -GLAPI void APIENTRY glStartInstrumentsSGIX (void); -GLAPI void APIENTRY glStopInstrumentsSGIX (GLint); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef GLint (APIENTRYP PFNGLGETINSTRUMENTSSGIXPROC) (void); -typedef void (APIENTRYP PFNGLINSTRUMENTSBUFFERSGIXPROC) (GLsizei size, GLint *buffer); -typedef GLint (APIENTRYP PFNGLPOLLINSTRUMENTSSGIXPROC) (GLint *marker_p); -typedef void (APIENTRYP PFNGLREADINSTRUMENTSSGIXPROC) (GLint marker); -typedef void (APIENTRYP PFNGLSTARTINSTRUMENTSSGIXPROC) (void); -typedef void (APIENTRYP PFNGLSTOPINSTRUMENTSSGIXPROC) (GLint marker); -#endif - -#ifndef GL_SGIX_texture_scale_bias -#define GL_SGIX_texture_scale_bias 1 -#endif - -#ifndef GL_SGIX_framezoom -#define GL_SGIX_framezoom 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glFrameZoomSGIX (GLint); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLFRAMEZOOMSGIXPROC) (GLint factor); -#endif - -#ifndef GL_SGIX_tag_sample_buffer -#define GL_SGIX_tag_sample_buffer 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glTagSampleBufferSGIX (void); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLTAGSAMPLEBUFFERSGIXPROC) (void); -#endif - -#ifndef GL_SGIX_polynomial_ffd -#define GL_SGIX_polynomial_ffd 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glDeformationMap3dSGIX (GLenum, GLdouble, GLdouble, GLint, GLint, GLdouble, GLdouble, GLint, GLint, GLdouble, GLdouble, GLint, GLint, const GLdouble *); -GLAPI void APIENTRY glDeformationMap3fSGIX (GLenum, GLfloat, GLfloat, GLint, GLint, GLfloat, GLfloat, GLint, GLint, GLfloat, GLfloat, GLint, GLint, const GLfloat *); -GLAPI void APIENTRY glDeformSGIX (GLbitfield); -GLAPI void APIENTRY glLoadIdentityDeformationMapSGIX (GLbitfield); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLDEFORMATIONMAP3DSGIXPROC) (GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, GLdouble w1, GLdouble w2, GLint wstride, GLint worder, const GLdouble *points); -typedef void (APIENTRYP PFNGLDEFORMATIONMAP3FSGIXPROC) (GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, GLfloat w1, GLfloat w2, GLint wstride, GLint worder, const GLfloat *points); -typedef void (APIENTRYP PFNGLDEFORMSGIXPROC) (GLbitfield mask); -typedef void (APIENTRYP PFNGLLOADIDENTITYDEFORMATIONMAPSGIXPROC) (GLbitfield mask); -#endif - -#ifndef GL_SGIX_reference_plane -#define GL_SGIX_reference_plane 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glReferencePlaneSGIX (const GLdouble *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLREFERENCEPLANESGIXPROC) (const GLdouble *equation); -#endif - -#ifndef GL_SGIX_flush_raster -#define GL_SGIX_flush_raster 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glFlushRasterSGIX (void); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLFLUSHRASTERSGIXPROC) (void); -#endif - -#ifndef GL_SGIX_depth_texture -#define GL_SGIX_depth_texture 1 -#endif - -#ifndef GL_SGIS_fog_function -#define GL_SGIS_fog_function 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glFogFuncSGIS (GLsizei, const GLfloat *); -GLAPI void APIENTRY glGetFogFuncSGIS (GLfloat *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLFOGFUNCSGISPROC) (GLsizei n, const GLfloat *points); -typedef void (APIENTRYP PFNGLGETFOGFUNCSGISPROC) (GLfloat *points); -#endif - -#ifndef GL_SGIX_fog_offset -#define GL_SGIX_fog_offset 1 -#endif - -#ifndef GL_HP_image_transform -#define GL_HP_image_transform 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glImageTransformParameteriHP (GLenum, GLenum, GLint); -GLAPI void APIENTRY glImageTransformParameterfHP (GLenum, GLenum, GLfloat); -GLAPI void APIENTRY glImageTransformParameterivHP (GLenum, GLenum, const GLint *); -GLAPI void APIENTRY glImageTransformParameterfvHP (GLenum, GLenum, const GLfloat *); -GLAPI void APIENTRY glGetImageTransformParameterivHP (GLenum, GLenum, GLint *); -GLAPI void APIENTRY glGetImageTransformParameterfvHP (GLenum, GLenum, GLfloat *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLIMAGETRANSFORMPARAMETERIHPPROC) (GLenum target, GLenum pname, GLint param); -typedef void (APIENTRYP PFNGLIMAGETRANSFORMPARAMETERFHPPROC) (GLenum target, GLenum pname, GLfloat param); -typedef void (APIENTRYP PFNGLIMAGETRANSFORMPARAMETERIVHPPROC) (GLenum target, GLenum pname, const GLint *params); -typedef void (APIENTRYP PFNGLIMAGETRANSFORMPARAMETERFVHPPROC) (GLenum target, GLenum pname, const GLfloat *params); -typedef void (APIENTRYP PFNGLGETIMAGETRANSFORMPARAMETERIVHPPROC) (GLenum target, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETIMAGETRANSFORMPARAMETERFVHPPROC) (GLenum target, GLenum pname, GLfloat *params); -#endif - -#ifndef GL_HP_convolution_border_modes -#define GL_HP_convolution_border_modes 1 -#endif - -#ifndef GL_SGIX_texture_add_env -#define GL_SGIX_texture_add_env 1 -#endif - -#ifndef GL_EXT_color_subtable -#define GL_EXT_color_subtable 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glColorSubTableEXT (GLenum, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *); -GLAPI void APIENTRY glCopyColorSubTableEXT (GLenum, GLsizei, GLint, GLint, GLsizei); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLCOLORSUBTABLEEXTPROC) (GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum type, const GLvoid *data); -typedef void (APIENTRYP PFNGLCOPYCOLORSUBTABLEEXTPROC) (GLenum target, GLsizei start, GLint x, GLint y, GLsizei width); -#endif - -#ifndef GL_PGI_vertex_hints -#define GL_PGI_vertex_hints 1 -#endif - -#ifndef GL_PGI_misc_hints -#define GL_PGI_misc_hints 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glHintPGI (GLenum, GLint); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLHINTPGIPROC) (GLenum target, GLint mode); -#endif - -#ifndef GL_EXT_paletted_texture -#define GL_EXT_paletted_texture 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glColorTableEXT (GLenum, GLenum, GLsizei, GLenum, GLenum, const GLvoid *); -GLAPI void APIENTRY glGetColorTableEXT (GLenum, GLenum, GLenum, GLvoid *); -GLAPI void APIENTRY glGetColorTableParameterivEXT (GLenum, GLenum, GLint *); -GLAPI void APIENTRY glGetColorTableParameterfvEXT (GLenum, GLenum, GLfloat *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLCOLORTABLEEXTPROC) (GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum type, const GLvoid *table); -typedef void (APIENTRYP PFNGLGETCOLORTABLEEXTPROC) (GLenum target, GLenum format, GLenum type, GLvoid *data); -typedef void (APIENTRYP PFNGLGETCOLORTABLEPARAMETERIVEXTPROC) (GLenum target, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETCOLORTABLEPARAMETERFVEXTPROC) (GLenum target, GLenum pname, GLfloat *params); -#endif - -#ifndef GL_EXT_clip_volume_hint -#define GL_EXT_clip_volume_hint 1 -#endif - -#ifndef GL_SGIX_list_priority -#define GL_SGIX_list_priority 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glGetListParameterfvSGIX (GLuint, GLenum, GLfloat *); -GLAPI void APIENTRY glGetListParameterivSGIX (GLuint, GLenum, GLint *); -GLAPI void APIENTRY glListParameterfSGIX (GLuint, GLenum, GLfloat); -GLAPI void APIENTRY glListParameterfvSGIX (GLuint, GLenum, const GLfloat *); -GLAPI void APIENTRY glListParameteriSGIX (GLuint, GLenum, GLint); -GLAPI void APIENTRY glListParameterivSGIX (GLuint, GLenum, const GLint *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLGETLISTPARAMETERFVSGIXPROC) (GLuint list, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETLISTPARAMETERIVSGIXPROC) (GLuint list, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLLISTPARAMETERFSGIXPROC) (GLuint list, GLenum pname, GLfloat param); -typedef void (APIENTRYP PFNGLLISTPARAMETERFVSGIXPROC) (GLuint list, GLenum pname, const GLfloat *params); -typedef void (APIENTRYP PFNGLLISTPARAMETERISGIXPROC) (GLuint list, GLenum pname, GLint param); -typedef void (APIENTRYP PFNGLLISTPARAMETERIVSGIXPROC) (GLuint list, GLenum pname, const GLint *params); -#endif - -#ifndef GL_SGIX_ir_instrument1 -#define GL_SGIX_ir_instrument1 1 -#endif - -#ifndef GL_SGIX_calligraphic_fragment -#define GL_SGIX_calligraphic_fragment 1 -#endif - -#ifndef GL_SGIX_texture_lod_bias -#define GL_SGIX_texture_lod_bias 1 -#endif - -#ifndef GL_SGIX_shadow_ambient -#define GL_SGIX_shadow_ambient 1 -#endif - -#ifndef GL_EXT_index_texture -#define GL_EXT_index_texture 1 -#endif - -#ifndef GL_EXT_index_material -#define GL_EXT_index_material 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glIndexMaterialEXT (GLenum, GLenum); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLINDEXMATERIALEXTPROC) (GLenum face, GLenum mode); -#endif - -#ifndef GL_EXT_index_func -#define GL_EXT_index_func 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glIndexFuncEXT (GLenum, GLclampf); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLINDEXFUNCEXTPROC) (GLenum func, GLclampf ref); -#endif - -#ifndef GL_EXT_index_array_formats -#define GL_EXT_index_array_formats 1 -#endif - -#ifndef GL_EXT_compiled_vertex_array -#define GL_EXT_compiled_vertex_array 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glLockArraysEXT (GLint, GLsizei); -GLAPI void APIENTRY glUnlockArraysEXT (void); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLLOCKARRAYSEXTPROC) (GLint first, GLsizei count); -typedef void (APIENTRYP PFNGLUNLOCKARRAYSEXTPROC) (void); -#endif - -#ifndef GL_EXT_cull_vertex -#define GL_EXT_cull_vertex 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glCullParameterdvEXT (GLenum, GLdouble *); -GLAPI void APIENTRY glCullParameterfvEXT (GLenum, GLfloat *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLCULLPARAMETERDVEXTPROC) (GLenum pname, GLdouble *params); -typedef void (APIENTRYP PFNGLCULLPARAMETERFVEXTPROC) (GLenum pname, GLfloat *params); -#endif - -#ifndef GL_SGIX_ycrcb -#define GL_SGIX_ycrcb 1 -#endif - -#ifndef GL_SGIX_fragment_lighting -#define GL_SGIX_fragment_lighting 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glFragmentColorMaterialSGIX (GLenum, GLenum); -GLAPI void APIENTRY glFragmentLightfSGIX (GLenum, GLenum, GLfloat); -GLAPI void APIENTRY glFragmentLightfvSGIX (GLenum, GLenum, const GLfloat *); -GLAPI void APIENTRY glFragmentLightiSGIX (GLenum, GLenum, GLint); -GLAPI void APIENTRY glFragmentLightivSGIX (GLenum, GLenum, const GLint *); -GLAPI void APIENTRY glFragmentLightModelfSGIX (GLenum, GLfloat); -GLAPI void APIENTRY glFragmentLightModelfvSGIX (GLenum, const GLfloat *); -GLAPI void APIENTRY glFragmentLightModeliSGIX (GLenum, GLint); -GLAPI void APIENTRY glFragmentLightModelivSGIX (GLenum, const GLint *); -GLAPI void APIENTRY glFragmentMaterialfSGIX (GLenum, GLenum, GLfloat); -GLAPI void APIENTRY glFragmentMaterialfvSGIX (GLenum, GLenum, const GLfloat *); -GLAPI void APIENTRY glFragmentMaterialiSGIX (GLenum, GLenum, GLint); -GLAPI void APIENTRY glFragmentMaterialivSGIX (GLenum, GLenum, const GLint *); -GLAPI void APIENTRY glGetFragmentLightfvSGIX (GLenum, GLenum, GLfloat *); -GLAPI void APIENTRY glGetFragmentLightivSGIX (GLenum, GLenum, GLint *); -GLAPI void APIENTRY glGetFragmentMaterialfvSGIX (GLenum, GLenum, GLfloat *); -GLAPI void APIENTRY glGetFragmentMaterialivSGIX (GLenum, GLenum, GLint *); -GLAPI void APIENTRY glLightEnviSGIX (GLenum, GLint); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLFRAGMENTCOLORMATERIALSGIXPROC) (GLenum face, GLenum mode); -typedef void (APIENTRYP PFNGLFRAGMENTLIGHTFSGIXPROC) (GLenum light, GLenum pname, GLfloat param); -typedef void (APIENTRYP PFNGLFRAGMENTLIGHTFVSGIXPROC) (GLenum light, GLenum pname, const GLfloat *params); -typedef void (APIENTRYP PFNGLFRAGMENTLIGHTISGIXPROC) (GLenum light, GLenum pname, GLint param); -typedef void (APIENTRYP PFNGLFRAGMENTLIGHTIVSGIXPROC) (GLenum light, GLenum pname, const GLint *params); -typedef void (APIENTRYP PFNGLFRAGMENTLIGHTMODELFSGIXPROC) (GLenum pname, GLfloat param); -typedef void (APIENTRYP PFNGLFRAGMENTLIGHTMODELFVSGIXPROC) (GLenum pname, const GLfloat *params); -typedef void (APIENTRYP PFNGLFRAGMENTLIGHTMODELISGIXPROC) (GLenum pname, GLint param); -typedef void (APIENTRYP PFNGLFRAGMENTLIGHTMODELIVSGIXPROC) (GLenum pname, const GLint *params); -typedef void (APIENTRYP PFNGLFRAGMENTMATERIALFSGIXPROC) (GLenum face, GLenum pname, GLfloat param); -typedef void (APIENTRYP PFNGLFRAGMENTMATERIALFVSGIXPROC) (GLenum face, GLenum pname, const GLfloat *params); -typedef void (APIENTRYP PFNGLFRAGMENTMATERIALISGIXPROC) (GLenum face, GLenum pname, GLint param); -typedef void (APIENTRYP PFNGLFRAGMENTMATERIALIVSGIXPROC) (GLenum face, GLenum pname, const GLint *params); -typedef void (APIENTRYP PFNGLGETFRAGMENTLIGHTFVSGIXPROC) (GLenum light, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETFRAGMENTLIGHTIVSGIXPROC) (GLenum light, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETFRAGMENTMATERIALFVSGIXPROC) (GLenum face, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETFRAGMENTMATERIALIVSGIXPROC) (GLenum face, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLLIGHTENVISGIXPROC) (GLenum pname, GLint param); -#endif - -#ifndef GL_IBM_rasterpos_clip -#define GL_IBM_rasterpos_clip 1 -#endif - -#ifndef GL_HP_texture_lighting -#define GL_HP_texture_lighting 1 -#endif - -#ifndef GL_EXT_draw_range_elements -#define GL_EXT_draw_range_elements 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glDrawRangeElementsEXT (GLenum, GLuint, GLuint, GLsizei, GLenum, const GLvoid *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLDRAWRANGEELEMENTSEXTPROC) (GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices); -#endif - -#ifndef GL_WIN_phong_shading -#define GL_WIN_phong_shading 1 -#endif - -#ifndef GL_WIN_specular_fog -#define GL_WIN_specular_fog 1 -#endif - -#ifndef GL_EXT_light_texture -#define GL_EXT_light_texture 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glApplyTextureEXT (GLenum); -GLAPI void APIENTRY glTextureLightEXT (GLenum); -GLAPI void APIENTRY glTextureMaterialEXT (GLenum, GLenum); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLAPPLYTEXTUREEXTPROC) (GLenum mode); -typedef void (APIENTRYP PFNGLTEXTURELIGHTEXTPROC) (GLenum pname); -typedef void (APIENTRYP PFNGLTEXTUREMATERIALEXTPROC) (GLenum face, GLenum mode); -#endif - -#ifndef GL_SGIX_blend_alpha_minmax -#define GL_SGIX_blend_alpha_minmax 1 -#endif - -#ifndef GL_EXT_bgra -#define GL_EXT_bgra 1 -#endif - -#ifndef GL_SGIX_async -#define GL_SGIX_async 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glAsyncMarkerSGIX (GLuint); -GLAPI GLint APIENTRY glFinishAsyncSGIX (GLuint *); -GLAPI GLint APIENTRY glPollAsyncSGIX (GLuint *); -GLAPI GLuint APIENTRY glGenAsyncMarkersSGIX (GLsizei); -GLAPI void APIENTRY glDeleteAsyncMarkersSGIX (GLuint, GLsizei); -GLAPI GLboolean APIENTRY glIsAsyncMarkerSGIX (GLuint); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLASYNCMARKERSGIXPROC) (GLuint marker); -typedef GLint (APIENTRYP PFNGLFINISHASYNCSGIXPROC) (GLuint *markerp); -typedef GLint (APIENTRYP PFNGLPOLLASYNCSGIXPROC) (GLuint *markerp); -typedef GLuint (APIENTRYP PFNGLGENASYNCMARKERSSGIXPROC) (GLsizei range); -typedef void (APIENTRYP PFNGLDELETEASYNCMARKERSSGIXPROC) (GLuint marker, GLsizei range); -typedef GLboolean (APIENTRYP PFNGLISASYNCMARKERSGIXPROC) (GLuint marker); -#endif - -#ifndef GL_SGIX_async_pixel -#define GL_SGIX_async_pixel 1 -#endif - -#ifndef GL_SGIX_async_histogram -#define GL_SGIX_async_histogram 1 -#endif - -#ifndef GL_INTEL_parallel_arrays -#define GL_INTEL_parallel_arrays 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glVertexPointervINTEL (GLint, GLenum, const GLvoid* *); -GLAPI void APIENTRY glNormalPointervINTEL (GLenum, const GLvoid* *); -GLAPI void APIENTRY glColorPointervINTEL (GLint, GLenum, const GLvoid* *); -GLAPI void APIENTRY glTexCoordPointervINTEL (GLint, GLenum, const GLvoid* *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLVERTEXPOINTERVINTELPROC) (GLint size, GLenum type, const GLvoid* *pointer); -typedef void (APIENTRYP PFNGLNORMALPOINTERVINTELPROC) (GLenum type, const GLvoid* *pointer); -typedef void (APIENTRYP PFNGLCOLORPOINTERVINTELPROC) (GLint size, GLenum type, const GLvoid* *pointer); -typedef void (APIENTRYP PFNGLTEXCOORDPOINTERVINTELPROC) (GLint size, GLenum type, const GLvoid* *pointer); -#endif - -#ifndef GL_HP_occlusion_test -#define GL_HP_occlusion_test 1 -#endif - -#ifndef GL_EXT_pixel_transform -#define GL_EXT_pixel_transform 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glPixelTransformParameteriEXT (GLenum, GLenum, GLint); -GLAPI void APIENTRY glPixelTransformParameterfEXT (GLenum, GLenum, GLfloat); -GLAPI void APIENTRY glPixelTransformParameterivEXT (GLenum, GLenum, const GLint *); -GLAPI void APIENTRY glPixelTransformParameterfvEXT (GLenum, GLenum, const GLfloat *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLPIXELTRANSFORMPARAMETERIEXTPROC) (GLenum target, GLenum pname, GLint param); -typedef void (APIENTRYP PFNGLPIXELTRANSFORMPARAMETERFEXTPROC) (GLenum target, GLenum pname, GLfloat param); -typedef void (APIENTRYP PFNGLPIXELTRANSFORMPARAMETERIVEXTPROC) (GLenum target, GLenum pname, const GLint *params); -typedef void (APIENTRYP PFNGLPIXELTRANSFORMPARAMETERFVEXTPROC) (GLenum target, GLenum pname, const GLfloat *params); -#endif - -#ifndef GL_EXT_pixel_transform_color_table -#define GL_EXT_pixel_transform_color_table 1 -#endif - -#ifndef GL_EXT_shared_texture_palette -#define GL_EXT_shared_texture_palette 1 -#endif - -#ifndef GL_EXT_separate_specular_color -#define GL_EXT_separate_specular_color 1 -#endif - -#ifndef GL_EXT_secondary_color -#define GL_EXT_secondary_color 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glSecondaryColor3bEXT (GLbyte, GLbyte, GLbyte); -GLAPI void APIENTRY glSecondaryColor3bvEXT (const GLbyte *); -GLAPI void APIENTRY glSecondaryColor3dEXT (GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glSecondaryColor3dvEXT (const GLdouble *); -GLAPI void APIENTRY glSecondaryColor3fEXT (GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glSecondaryColor3fvEXT (const GLfloat *); -GLAPI void APIENTRY glSecondaryColor3iEXT (GLint, GLint, GLint); -GLAPI void APIENTRY glSecondaryColor3ivEXT (const GLint *); -GLAPI void APIENTRY glSecondaryColor3sEXT (GLshort, GLshort, GLshort); -GLAPI void APIENTRY glSecondaryColor3svEXT (const GLshort *); -GLAPI void APIENTRY glSecondaryColor3ubEXT (GLubyte, GLubyte, GLubyte); -GLAPI void APIENTRY glSecondaryColor3ubvEXT (const GLubyte *); -GLAPI void APIENTRY glSecondaryColor3uiEXT (GLuint, GLuint, GLuint); -GLAPI void APIENTRY glSecondaryColor3uivEXT (const GLuint *); -GLAPI void APIENTRY glSecondaryColor3usEXT (GLushort, GLushort, GLushort); -GLAPI void APIENTRY glSecondaryColor3usvEXT (const GLushort *); -GLAPI void APIENTRY glSecondaryColorPointerEXT (GLint, GLenum, GLsizei, const GLvoid *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3BEXTPROC) (GLbyte red, GLbyte green, GLbyte blue); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3BVEXTPROC) (const GLbyte *v); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3DEXTPROC) (GLdouble red, GLdouble green, GLdouble blue); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3DVEXTPROC) (const GLdouble *v); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3FEXTPROC) (GLfloat red, GLfloat green, GLfloat blue); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3FVEXTPROC) (const GLfloat *v); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3IEXTPROC) (GLint red, GLint green, GLint blue); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3IVEXTPROC) (const GLint *v); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3SEXTPROC) (GLshort red, GLshort green, GLshort blue); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3SVEXTPROC) (const GLshort *v); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3UBEXTPROC) (GLubyte red, GLubyte green, GLubyte blue); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3UBVEXTPROC) (const GLubyte *v); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3UIEXTPROC) (GLuint red, GLuint green, GLuint blue); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3UIVEXTPROC) (const GLuint *v); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3USEXTPROC) (GLushort red, GLushort green, GLushort blue); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3USVEXTPROC) (const GLushort *v); -typedef void (APIENTRYP PFNGLSECONDARYCOLORPOINTEREXTPROC) (GLint size, GLenum type, GLsizei stride, const GLvoid *pointer); -#endif - -#ifndef GL_EXT_texture_perturb_normal -#define GL_EXT_texture_perturb_normal 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glTextureNormalEXT (GLenum); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLTEXTURENORMALEXTPROC) (GLenum mode); -#endif - -#ifndef GL_EXT_multi_draw_arrays -#define GL_EXT_multi_draw_arrays 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glMultiDrawArraysEXT (GLenum, GLint *, GLsizei *, GLsizei); -GLAPI void APIENTRY glMultiDrawElementsEXT (GLenum, const GLsizei *, GLenum, const GLvoid* *, GLsizei); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLMULTIDRAWARRAYSEXTPROC) (GLenum mode, GLint *first, GLsizei *count, GLsizei primcount); -typedef void (APIENTRYP PFNGLMULTIDRAWELEMENTSEXTPROC) (GLenum mode, const GLsizei *count, GLenum type, const GLvoid* *indices, GLsizei primcount); -#endif - -#ifndef GL_EXT_fog_coord -#define GL_EXT_fog_coord 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glFogCoordfEXT (GLfloat); -GLAPI void APIENTRY glFogCoordfvEXT (const GLfloat *); -GLAPI void APIENTRY glFogCoorddEXT (GLdouble); -GLAPI void APIENTRY glFogCoorddvEXT (const GLdouble *); -GLAPI void APIENTRY glFogCoordPointerEXT (GLenum, GLsizei, const GLvoid *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLFOGCOORDFEXTPROC) (GLfloat coord); -typedef void (APIENTRYP PFNGLFOGCOORDFVEXTPROC) (const GLfloat *coord); -typedef void (APIENTRYP PFNGLFOGCOORDDEXTPROC) (GLdouble coord); -typedef void (APIENTRYP PFNGLFOGCOORDDVEXTPROC) (const GLdouble *coord); -typedef void (APIENTRYP PFNGLFOGCOORDPOINTEREXTPROC) (GLenum type, GLsizei stride, const GLvoid *pointer); -#endif - -#ifndef GL_REND_screen_coordinates -#define GL_REND_screen_coordinates 1 -#endif - -#ifndef GL_EXT_coordinate_frame -#define GL_EXT_coordinate_frame 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glTangent3bEXT (GLbyte, GLbyte, GLbyte); -GLAPI void APIENTRY glTangent3bvEXT (const GLbyte *); -GLAPI void APIENTRY glTangent3dEXT (GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glTangent3dvEXT (const GLdouble *); -GLAPI void APIENTRY glTangent3fEXT (GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glTangent3fvEXT (const GLfloat *); -GLAPI void APIENTRY glTangent3iEXT (GLint, GLint, GLint); -GLAPI void APIENTRY glTangent3ivEXT (const GLint *); -GLAPI void APIENTRY glTangent3sEXT (GLshort, GLshort, GLshort); -GLAPI void APIENTRY glTangent3svEXT (const GLshort *); -GLAPI void APIENTRY glBinormal3bEXT (GLbyte, GLbyte, GLbyte); -GLAPI void APIENTRY glBinormal3bvEXT (const GLbyte *); -GLAPI void APIENTRY glBinormal3dEXT (GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glBinormal3dvEXT (const GLdouble *); -GLAPI void APIENTRY glBinormal3fEXT (GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glBinormal3fvEXT (const GLfloat *); -GLAPI void APIENTRY glBinormal3iEXT (GLint, GLint, GLint); -GLAPI void APIENTRY glBinormal3ivEXT (const GLint *); -GLAPI void APIENTRY glBinormal3sEXT (GLshort, GLshort, GLshort); -GLAPI void APIENTRY glBinormal3svEXT (const GLshort *); -GLAPI void APIENTRY glTangentPointerEXT (GLenum, GLsizei, const GLvoid *); -GLAPI void APIENTRY glBinormalPointerEXT (GLenum, GLsizei, const GLvoid *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLTANGENT3BEXTPROC) (GLbyte tx, GLbyte ty, GLbyte tz); -typedef void (APIENTRYP PFNGLTANGENT3BVEXTPROC) (const GLbyte *v); -typedef void (APIENTRYP PFNGLTANGENT3DEXTPROC) (GLdouble tx, GLdouble ty, GLdouble tz); -typedef void (APIENTRYP PFNGLTANGENT3DVEXTPROC) (const GLdouble *v); -typedef void (APIENTRYP PFNGLTANGENT3FEXTPROC) (GLfloat tx, GLfloat ty, GLfloat tz); -typedef void (APIENTRYP PFNGLTANGENT3FVEXTPROC) (const GLfloat *v); -typedef void (APIENTRYP PFNGLTANGENT3IEXTPROC) (GLint tx, GLint ty, GLint tz); -typedef void (APIENTRYP PFNGLTANGENT3IVEXTPROC) (const GLint *v); -typedef void (APIENTRYP PFNGLTANGENT3SEXTPROC) (GLshort tx, GLshort ty, GLshort tz); -typedef void (APIENTRYP PFNGLTANGENT3SVEXTPROC) (const GLshort *v); -typedef void (APIENTRYP PFNGLBINORMAL3BEXTPROC) (GLbyte bx, GLbyte by, GLbyte bz); -typedef void (APIENTRYP PFNGLBINORMAL3BVEXTPROC) (const GLbyte *v); -typedef void (APIENTRYP PFNGLBINORMAL3DEXTPROC) (GLdouble bx, GLdouble by, GLdouble bz); -typedef void (APIENTRYP PFNGLBINORMAL3DVEXTPROC) (const GLdouble *v); -typedef void (APIENTRYP PFNGLBINORMAL3FEXTPROC) (GLfloat bx, GLfloat by, GLfloat bz); -typedef void (APIENTRYP PFNGLBINORMAL3FVEXTPROC) (const GLfloat *v); -typedef void (APIENTRYP PFNGLBINORMAL3IEXTPROC) (GLint bx, GLint by, GLint bz); -typedef void (APIENTRYP PFNGLBINORMAL3IVEXTPROC) (const GLint *v); -typedef void (APIENTRYP PFNGLBINORMAL3SEXTPROC) (GLshort bx, GLshort by, GLshort bz); -typedef void (APIENTRYP PFNGLBINORMAL3SVEXTPROC) (const GLshort *v); -typedef void (APIENTRYP PFNGLTANGENTPOINTEREXTPROC) (GLenum type, GLsizei stride, const GLvoid *pointer); -typedef void (APIENTRYP PFNGLBINORMALPOINTEREXTPROC) (GLenum type, GLsizei stride, const GLvoid *pointer); -#endif - -#ifndef GL_EXT_texture_env_combine -#define GL_EXT_texture_env_combine 1 -#endif - -#ifndef GL_APPLE_specular_vector -#define GL_APPLE_specular_vector 1 -#endif - -#ifndef GL_APPLE_transform_hint -#define GL_APPLE_transform_hint 1 -#endif - -#ifndef GL_SGIX_fog_scale -#define GL_SGIX_fog_scale 1 -#endif - -#ifndef GL_SUNX_constant_data -#define GL_SUNX_constant_data 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glFinishTextureSUNX (void); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLFINISHTEXTURESUNXPROC) (void); -#endif - -#ifndef GL_SUN_global_alpha -#define GL_SUN_global_alpha 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glGlobalAlphaFactorbSUN (GLbyte); -GLAPI void APIENTRY glGlobalAlphaFactorsSUN (GLshort); -GLAPI void APIENTRY glGlobalAlphaFactoriSUN (GLint); -GLAPI void APIENTRY glGlobalAlphaFactorfSUN (GLfloat); -GLAPI void APIENTRY glGlobalAlphaFactordSUN (GLdouble); -GLAPI void APIENTRY glGlobalAlphaFactorubSUN (GLubyte); -GLAPI void APIENTRY glGlobalAlphaFactorusSUN (GLushort); -GLAPI void APIENTRY glGlobalAlphaFactoruiSUN (GLuint); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLGLOBALALPHAFACTORBSUNPROC) (GLbyte factor); -typedef void (APIENTRYP PFNGLGLOBALALPHAFACTORSSUNPROC) (GLshort factor); -typedef void (APIENTRYP PFNGLGLOBALALPHAFACTORISUNPROC) (GLint factor); -typedef void (APIENTRYP PFNGLGLOBALALPHAFACTORFSUNPROC) (GLfloat factor); -typedef void (APIENTRYP PFNGLGLOBALALPHAFACTORDSUNPROC) (GLdouble factor); -typedef void (APIENTRYP PFNGLGLOBALALPHAFACTORUBSUNPROC) (GLubyte factor); -typedef void (APIENTRYP PFNGLGLOBALALPHAFACTORUSSUNPROC) (GLushort factor); -typedef void (APIENTRYP PFNGLGLOBALALPHAFACTORUISUNPROC) (GLuint factor); -#endif - -#ifndef GL_SUN_triangle_list -#define GL_SUN_triangle_list 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glReplacementCodeuiSUN (GLuint); -GLAPI void APIENTRY glReplacementCodeusSUN (GLushort); -GLAPI void APIENTRY glReplacementCodeubSUN (GLubyte); -GLAPI void APIENTRY glReplacementCodeuivSUN (const GLuint *); -GLAPI void APIENTRY glReplacementCodeusvSUN (const GLushort *); -GLAPI void APIENTRY glReplacementCodeubvSUN (const GLubyte *); -GLAPI void APIENTRY glReplacementCodePointerSUN (GLenum, GLsizei, const GLvoid* *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLREPLACEMENTCODEUISUNPROC) (GLuint code); -typedef void (APIENTRYP PFNGLREPLACEMENTCODEUSSUNPROC) (GLushort code); -typedef void (APIENTRYP PFNGLREPLACEMENTCODEUBSUNPROC) (GLubyte code); -typedef void (APIENTRYP PFNGLREPLACEMENTCODEUIVSUNPROC) (const GLuint *code); -typedef void (APIENTRYP PFNGLREPLACEMENTCODEUSVSUNPROC) (const GLushort *code); -typedef void (APIENTRYP PFNGLREPLACEMENTCODEUBVSUNPROC) (const GLubyte *code); -typedef void (APIENTRYP PFNGLREPLACEMENTCODEPOINTERSUNPROC) (GLenum type, GLsizei stride, const GLvoid* *pointer); -#endif - -#ifndef GL_SUN_vertex -#define GL_SUN_vertex 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glColor4ubVertex2fSUN (GLubyte, GLubyte, GLubyte, GLubyte, GLfloat, GLfloat); -GLAPI void APIENTRY glColor4ubVertex2fvSUN (const GLubyte *, const GLfloat *); -GLAPI void APIENTRY glColor4ubVertex3fSUN (GLubyte, GLubyte, GLubyte, GLubyte, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glColor4ubVertex3fvSUN (const GLubyte *, const GLfloat *); -GLAPI void APIENTRY glColor3fVertex3fSUN (GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glColor3fVertex3fvSUN (const GLfloat *, const GLfloat *); -GLAPI void APIENTRY glNormal3fVertex3fSUN (GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glNormal3fVertex3fvSUN (const GLfloat *, const GLfloat *); -GLAPI void APIENTRY glColor4fNormal3fVertex3fSUN (GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glColor4fNormal3fVertex3fvSUN (const GLfloat *, const GLfloat *, const GLfloat *); -GLAPI void APIENTRY glTexCoord2fVertex3fSUN (GLfloat, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glTexCoord2fVertex3fvSUN (const GLfloat *, const GLfloat *); -GLAPI void APIENTRY glTexCoord4fVertex4fSUN (GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glTexCoord4fVertex4fvSUN (const GLfloat *, const GLfloat *); -GLAPI void APIENTRY glTexCoord2fColor4ubVertex3fSUN (GLfloat, GLfloat, GLubyte, GLubyte, GLubyte, GLubyte, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glTexCoord2fColor4ubVertex3fvSUN (const GLfloat *, const GLubyte *, const GLfloat *); -GLAPI void APIENTRY glTexCoord2fColor3fVertex3fSUN (GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glTexCoord2fColor3fVertex3fvSUN (const GLfloat *, const GLfloat *, const GLfloat *); -GLAPI void APIENTRY glTexCoord2fNormal3fVertex3fSUN (GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glTexCoord2fNormal3fVertex3fvSUN (const GLfloat *, const GLfloat *, const GLfloat *); -GLAPI void APIENTRY glTexCoord2fColor4fNormal3fVertex3fSUN (GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glTexCoord2fColor4fNormal3fVertex3fvSUN (const GLfloat *, const GLfloat *, const GLfloat *, const GLfloat *); -GLAPI void APIENTRY glTexCoord4fColor4fNormal3fVertex4fSUN (GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glTexCoord4fColor4fNormal3fVertex4fvSUN (const GLfloat *, const GLfloat *, const GLfloat *, const GLfloat *); -GLAPI void APIENTRY glReplacementCodeuiVertex3fSUN (GLuint, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glReplacementCodeuiVertex3fvSUN (const GLuint *, const GLfloat *); -GLAPI void APIENTRY glReplacementCodeuiColor4ubVertex3fSUN (GLuint, GLubyte, GLubyte, GLubyte, GLubyte, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glReplacementCodeuiColor4ubVertex3fvSUN (const GLuint *, const GLubyte *, const GLfloat *); -GLAPI void APIENTRY glReplacementCodeuiColor3fVertex3fSUN (GLuint, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glReplacementCodeuiColor3fVertex3fvSUN (const GLuint *, const GLfloat *, const GLfloat *); -GLAPI void APIENTRY glReplacementCodeuiNormal3fVertex3fSUN (GLuint, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glReplacementCodeuiNormal3fVertex3fvSUN (const GLuint *, const GLfloat *, const GLfloat *); -GLAPI void APIENTRY glReplacementCodeuiColor4fNormal3fVertex3fSUN (GLuint, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glReplacementCodeuiColor4fNormal3fVertex3fvSUN (const GLuint *, const GLfloat *, const GLfloat *, const GLfloat *); -GLAPI void APIENTRY glReplacementCodeuiTexCoord2fVertex3fSUN (GLuint, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glReplacementCodeuiTexCoord2fVertex3fvSUN (const GLuint *, const GLfloat *, const GLfloat *); -GLAPI void APIENTRY glReplacementCodeuiTexCoord2fNormal3fVertex3fSUN (GLuint, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glReplacementCodeuiTexCoord2fNormal3fVertex3fvSUN (const GLuint *, const GLfloat *, const GLfloat *, const GLfloat *); -GLAPI void APIENTRY glReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fSUN (GLuint, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fvSUN (const GLuint *, const GLfloat *, const GLfloat *, const GLfloat *, const GLfloat *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLCOLOR4UBVERTEX2FSUNPROC) (GLubyte r, GLubyte g, GLubyte b, GLubyte a, GLfloat x, GLfloat y); -typedef void (APIENTRYP PFNGLCOLOR4UBVERTEX2FVSUNPROC) (const GLubyte *c, const GLfloat *v); -typedef void (APIENTRYP PFNGLCOLOR4UBVERTEX3FSUNPROC) (GLubyte r, GLubyte g, GLubyte b, GLubyte a, GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLCOLOR4UBVERTEX3FVSUNPROC) (const GLubyte *c, const GLfloat *v); -typedef void (APIENTRYP PFNGLCOLOR3FVERTEX3FSUNPROC) (GLfloat r, GLfloat g, GLfloat b, GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLCOLOR3FVERTEX3FVSUNPROC) (const GLfloat *c, const GLfloat *v); -typedef void (APIENTRYP PFNGLNORMAL3FVERTEX3FSUNPROC) (GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLNORMAL3FVERTEX3FVSUNPROC) (const GLfloat *n, const GLfloat *v); -typedef void (APIENTRYP PFNGLCOLOR4FNORMAL3FVERTEX3FSUNPROC) (GLfloat r, GLfloat g, GLfloat b, GLfloat a, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLCOLOR4FNORMAL3FVERTEX3FVSUNPROC) (const GLfloat *c, const GLfloat *n, const GLfloat *v); -typedef void (APIENTRYP PFNGLTEXCOORD2FVERTEX3FSUNPROC) (GLfloat s, GLfloat t, GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLTEXCOORD2FVERTEX3FVSUNPROC) (const GLfloat *tc, const GLfloat *v); -typedef void (APIENTRYP PFNGLTEXCOORD4FVERTEX4FSUNPROC) (GLfloat s, GLfloat t, GLfloat p, GLfloat q, GLfloat x, GLfloat y, GLfloat z, GLfloat w); -typedef void (APIENTRYP PFNGLTEXCOORD4FVERTEX4FVSUNPROC) (const GLfloat *tc, const GLfloat *v); -typedef void (APIENTRYP PFNGLTEXCOORD2FCOLOR4UBVERTEX3FSUNPROC) (GLfloat s, GLfloat t, GLubyte r, GLubyte g, GLubyte b, GLubyte a, GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLTEXCOORD2FCOLOR4UBVERTEX3FVSUNPROC) (const GLfloat *tc, const GLubyte *c, const GLfloat *v); -typedef void (APIENTRYP PFNGLTEXCOORD2FCOLOR3FVERTEX3FSUNPROC) (GLfloat s, GLfloat t, GLfloat r, GLfloat g, GLfloat b, GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLTEXCOORD2FCOLOR3FVERTEX3FVSUNPROC) (const GLfloat *tc, const GLfloat *c, const GLfloat *v); -typedef void (APIENTRYP PFNGLTEXCOORD2FNORMAL3FVERTEX3FSUNPROC) (GLfloat s, GLfloat t, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLTEXCOORD2FNORMAL3FVERTEX3FVSUNPROC) (const GLfloat *tc, const GLfloat *n, const GLfloat *v); -typedef void (APIENTRYP PFNGLTEXCOORD2FCOLOR4FNORMAL3FVERTEX3FSUNPROC) (GLfloat s, GLfloat t, GLfloat r, GLfloat g, GLfloat b, GLfloat a, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLTEXCOORD2FCOLOR4FNORMAL3FVERTEX3FVSUNPROC) (const GLfloat *tc, const GLfloat *c, const GLfloat *n, const GLfloat *v); -typedef void (APIENTRYP PFNGLTEXCOORD4FCOLOR4FNORMAL3FVERTEX4FSUNPROC) (GLfloat s, GLfloat t, GLfloat p, GLfloat q, GLfloat r, GLfloat g, GLfloat b, GLfloat a, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z, GLfloat w); -typedef void (APIENTRYP PFNGLTEXCOORD4FCOLOR4FNORMAL3FVERTEX4FVSUNPROC) (const GLfloat *tc, const GLfloat *c, const GLfloat *n, const GLfloat *v); -typedef void (APIENTRYP PFNGLREPLACEMENTCODEUIVERTEX3FSUNPROC) (GLuint rc, GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLREPLACEMENTCODEUIVERTEX3FVSUNPROC) (const GLuint *rc, const GLfloat *v); -typedef void (APIENTRYP PFNGLREPLACEMENTCODEUICOLOR4UBVERTEX3FSUNPROC) (GLuint rc, GLubyte r, GLubyte g, GLubyte b, GLubyte a, GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLREPLACEMENTCODEUICOLOR4UBVERTEX3FVSUNPROC) (const GLuint *rc, const GLubyte *c, const GLfloat *v); -typedef void (APIENTRYP PFNGLREPLACEMENTCODEUICOLOR3FVERTEX3FSUNPROC) (GLuint rc, GLfloat r, GLfloat g, GLfloat b, GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLREPLACEMENTCODEUICOLOR3FVERTEX3FVSUNPROC) (const GLuint *rc, const GLfloat *c, const GLfloat *v); -typedef void (APIENTRYP PFNGLREPLACEMENTCODEUINORMAL3FVERTEX3FSUNPROC) (GLuint rc, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLREPLACEMENTCODEUINORMAL3FVERTEX3FVSUNPROC) (const GLuint *rc, const GLfloat *n, const GLfloat *v); -typedef void (APIENTRYP PFNGLREPLACEMENTCODEUICOLOR4FNORMAL3FVERTEX3FSUNPROC) (GLuint rc, GLfloat r, GLfloat g, GLfloat b, GLfloat a, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLREPLACEMENTCODEUICOLOR4FNORMAL3FVERTEX3FVSUNPROC) (const GLuint *rc, const GLfloat *c, const GLfloat *n, const GLfloat *v); -typedef void (APIENTRYP PFNGLREPLACEMENTCODEUITEXCOORD2FVERTEX3FSUNPROC) (GLuint rc, GLfloat s, GLfloat t, GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLREPLACEMENTCODEUITEXCOORD2FVERTEX3FVSUNPROC) (const GLuint *rc, const GLfloat *tc, const GLfloat *v); -typedef void (APIENTRYP PFNGLREPLACEMENTCODEUITEXCOORD2FNORMAL3FVERTEX3FSUNPROC) (GLuint rc, GLfloat s, GLfloat t, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLREPLACEMENTCODEUITEXCOORD2FNORMAL3FVERTEX3FVSUNPROC) (const GLuint *rc, const GLfloat *tc, const GLfloat *n, const GLfloat *v); -typedef void (APIENTRYP PFNGLREPLACEMENTCODEUITEXCOORD2FCOLOR4FNORMAL3FVERTEX3FSUNPROC) (GLuint rc, GLfloat s, GLfloat t, GLfloat r, GLfloat g, GLfloat b, GLfloat a, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLREPLACEMENTCODEUITEXCOORD2FCOLOR4FNORMAL3FVERTEX3FVSUNPROC) (const GLuint *rc, const GLfloat *tc, const GLfloat *c, const GLfloat *n, const GLfloat *v); -#endif - -#ifndef GL_EXT_blend_func_separate -#define GL_EXT_blend_func_separate 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glBlendFuncSeparateEXT (GLenum, GLenum, GLenum, GLenum); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLBLENDFUNCSEPARATEEXTPROC) (GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha); -#endif - -#ifndef GL_INGR_blend_func_separate -#define GL_INGR_blend_func_separate 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glBlendFuncSeparateINGR (GLenum, GLenum, GLenum, GLenum); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLBLENDFUNCSEPARATEINGRPROC) (GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha); -#endif - -#ifndef GL_INGR_color_clamp -#define GL_INGR_color_clamp 1 -#endif - -#ifndef GL_INGR_interlace_read -#define GL_INGR_interlace_read 1 -#endif - -#ifndef GL_EXT_stencil_wrap -#define GL_EXT_stencil_wrap 1 -#endif - -#ifndef GL_EXT_422_pixels -#define GL_EXT_422_pixels 1 -#endif - -#ifndef GL_NV_texgen_reflection -#define GL_NV_texgen_reflection 1 -#endif - -#ifndef GL_SUN_convolution_border_modes -#define GL_SUN_convolution_border_modes 1 -#endif - -#ifndef GL_EXT_texture_env_add -#define GL_EXT_texture_env_add 1 -#endif - -#ifndef GL_EXT_texture_lod_bias -#define GL_EXT_texture_lod_bias 1 -#endif - -#ifndef GL_EXT_texture_filter_anisotropic -#define GL_EXT_texture_filter_anisotropic 1 -#endif - -#ifndef GL_EXT_vertex_weighting -#define GL_EXT_vertex_weighting 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glVertexWeightfEXT (GLfloat); -GLAPI void APIENTRY glVertexWeightfvEXT (const GLfloat *); -GLAPI void APIENTRY glVertexWeightPointerEXT (GLsizei, GLenum, GLsizei, const GLvoid *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLVERTEXWEIGHTFEXTPROC) (GLfloat weight); -typedef void (APIENTRYP PFNGLVERTEXWEIGHTFVEXTPROC) (const GLfloat *weight); -typedef void (APIENTRYP PFNGLVERTEXWEIGHTPOINTEREXTPROC) (GLsizei size, GLenum type, GLsizei stride, const GLvoid *pointer); -#endif - -#ifndef GL_NV_light_max_exponent -#define GL_NV_light_max_exponent 1 -#endif - -#ifndef GL_NV_vertex_array_range -#define GL_NV_vertex_array_range 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glFlushVertexArrayRangeNV (void); -GLAPI void APIENTRY glVertexArrayRangeNV (GLsizei, const GLvoid *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLFLUSHVERTEXARRAYRANGENVPROC) (void); -typedef void (APIENTRYP PFNGLVERTEXARRAYRANGENVPROC) (GLsizei length, const GLvoid *pointer); -#endif - -#ifndef GL_NV_register_combiners -#define GL_NV_register_combiners 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glCombinerParameterfvNV (GLenum, const GLfloat *); -GLAPI void APIENTRY glCombinerParameterfNV (GLenum, GLfloat); -GLAPI void APIENTRY glCombinerParameterivNV (GLenum, const GLint *); -GLAPI void APIENTRY glCombinerParameteriNV (GLenum, GLint); -GLAPI void APIENTRY glCombinerInputNV (GLenum, GLenum, GLenum, GLenum, GLenum, GLenum); -GLAPI void APIENTRY glCombinerOutputNV (GLenum, GLenum, GLenum, GLenum, GLenum, GLenum, GLenum, GLboolean, GLboolean, GLboolean); -GLAPI void APIENTRY glFinalCombinerInputNV (GLenum, GLenum, GLenum, GLenum); -GLAPI void APIENTRY glGetCombinerInputParameterfvNV (GLenum, GLenum, GLenum, GLenum, GLfloat *); -GLAPI void APIENTRY glGetCombinerInputParameterivNV (GLenum, GLenum, GLenum, GLenum, GLint *); -GLAPI void APIENTRY glGetCombinerOutputParameterfvNV (GLenum, GLenum, GLenum, GLfloat *); -GLAPI void APIENTRY glGetCombinerOutputParameterivNV (GLenum, GLenum, GLenum, GLint *); -GLAPI void APIENTRY glGetFinalCombinerInputParameterfvNV (GLenum, GLenum, GLfloat *); -GLAPI void APIENTRY glGetFinalCombinerInputParameterivNV (GLenum, GLenum, GLint *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLCOMBINERPARAMETERFVNVPROC) (GLenum pname, const GLfloat *params); -typedef void (APIENTRYP PFNGLCOMBINERPARAMETERFNVPROC) (GLenum pname, GLfloat param); -typedef void (APIENTRYP PFNGLCOMBINERPARAMETERIVNVPROC) (GLenum pname, const GLint *params); -typedef void (APIENTRYP PFNGLCOMBINERPARAMETERINVPROC) (GLenum pname, GLint param); -typedef void (APIENTRYP PFNGLCOMBINERINPUTNVPROC) (GLenum stage, GLenum portion, GLenum variable, GLenum input, GLenum mapping, GLenum componentUsage); -typedef void (APIENTRYP PFNGLCOMBINEROUTPUTNVPROC) (GLenum stage, GLenum portion, GLenum abOutput, GLenum cdOutput, GLenum sumOutput, GLenum scale, GLenum bias, GLboolean abDotProduct, GLboolean cdDotProduct, GLboolean muxSum); -typedef void (APIENTRYP PFNGLFINALCOMBINERINPUTNVPROC) (GLenum variable, GLenum input, GLenum mapping, GLenum componentUsage); -typedef void (APIENTRYP PFNGLGETCOMBINERINPUTPARAMETERFVNVPROC) (GLenum stage, GLenum portion, GLenum variable, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETCOMBINERINPUTPARAMETERIVNVPROC) (GLenum stage, GLenum portion, GLenum variable, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETCOMBINEROUTPUTPARAMETERFVNVPROC) (GLenum stage, GLenum portion, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETCOMBINEROUTPUTPARAMETERIVNVPROC) (GLenum stage, GLenum portion, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETFINALCOMBINERINPUTPARAMETERFVNVPROC) (GLenum variable, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETFINALCOMBINERINPUTPARAMETERIVNVPROC) (GLenum variable, GLenum pname, GLint *params); -#endif - -#ifndef GL_NV_fog_distance -#define GL_NV_fog_distance 1 -#endif - -#ifndef GL_NV_texgen_emboss -#define GL_NV_texgen_emboss 1 -#endif - -#ifndef GL_NV_blend_square -#define GL_NV_blend_square 1 -#endif - -#ifndef GL_NV_texture_env_combine4 -#define GL_NV_texture_env_combine4 1 -#endif - -#ifndef GL_MESA_resize_buffers -#define GL_MESA_resize_buffers 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glResizeBuffersMESA (void); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLRESIZEBUFFERSMESAPROC) (void); -#endif - -#ifndef GL_MESA_window_pos -#define GL_MESA_window_pos 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glWindowPos2dMESA (GLdouble, GLdouble); -GLAPI void APIENTRY glWindowPos2dvMESA (const GLdouble *); -GLAPI void APIENTRY glWindowPos2fMESA (GLfloat, GLfloat); -GLAPI void APIENTRY glWindowPos2fvMESA (const GLfloat *); -GLAPI void APIENTRY glWindowPos2iMESA (GLint, GLint); -GLAPI void APIENTRY glWindowPos2ivMESA (const GLint *); -GLAPI void APIENTRY glWindowPos2sMESA (GLshort, GLshort); -GLAPI void APIENTRY glWindowPos2svMESA (const GLshort *); -GLAPI void APIENTRY glWindowPos3dMESA (GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glWindowPos3dvMESA (const GLdouble *); -GLAPI void APIENTRY glWindowPos3fMESA (GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glWindowPos3fvMESA (const GLfloat *); -GLAPI void APIENTRY glWindowPos3iMESA (GLint, GLint, GLint); -GLAPI void APIENTRY glWindowPos3ivMESA (const GLint *); -GLAPI void APIENTRY glWindowPos3sMESA (GLshort, GLshort, GLshort); -GLAPI void APIENTRY glWindowPos3svMESA (const GLshort *); -GLAPI void APIENTRY glWindowPos4dMESA (GLdouble, GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glWindowPos4dvMESA (const GLdouble *); -GLAPI void APIENTRY glWindowPos4fMESA (GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glWindowPos4fvMESA (const GLfloat *); -GLAPI void APIENTRY glWindowPos4iMESA (GLint, GLint, GLint, GLint); -GLAPI void APIENTRY glWindowPos4ivMESA (const GLint *); -GLAPI void APIENTRY glWindowPos4sMESA (GLshort, GLshort, GLshort, GLshort); -GLAPI void APIENTRY glWindowPos4svMESA (const GLshort *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLWINDOWPOS2DMESAPROC) (GLdouble x, GLdouble y); -typedef void (APIENTRYP PFNGLWINDOWPOS2DVMESAPROC) (const GLdouble *v); -typedef void (APIENTRYP PFNGLWINDOWPOS2FMESAPROC) (GLfloat x, GLfloat y); -typedef void (APIENTRYP PFNGLWINDOWPOS2FVMESAPROC) (const GLfloat *v); -typedef void (APIENTRYP PFNGLWINDOWPOS2IMESAPROC) (GLint x, GLint y); -typedef void (APIENTRYP PFNGLWINDOWPOS2IVMESAPROC) (const GLint *v); -typedef void (APIENTRYP PFNGLWINDOWPOS2SMESAPROC) (GLshort x, GLshort y); -typedef void (APIENTRYP PFNGLWINDOWPOS2SVMESAPROC) (const GLshort *v); -typedef void (APIENTRYP PFNGLWINDOWPOS3DMESAPROC) (GLdouble x, GLdouble y, GLdouble z); -typedef void (APIENTRYP PFNGLWINDOWPOS3DVMESAPROC) (const GLdouble *v); -typedef void (APIENTRYP PFNGLWINDOWPOS3FMESAPROC) (GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLWINDOWPOS3FVMESAPROC) (const GLfloat *v); -typedef void (APIENTRYP PFNGLWINDOWPOS3IMESAPROC) (GLint x, GLint y, GLint z); -typedef void (APIENTRYP PFNGLWINDOWPOS3IVMESAPROC) (const GLint *v); -typedef void (APIENTRYP PFNGLWINDOWPOS3SMESAPROC) (GLshort x, GLshort y, GLshort z); -typedef void (APIENTRYP PFNGLWINDOWPOS3SVMESAPROC) (const GLshort *v); -typedef void (APIENTRYP PFNGLWINDOWPOS4DMESAPROC) (GLdouble x, GLdouble y, GLdouble z, GLdouble w); -typedef void (APIENTRYP PFNGLWINDOWPOS4DVMESAPROC) (const GLdouble *v); -typedef void (APIENTRYP PFNGLWINDOWPOS4FMESAPROC) (GLfloat x, GLfloat y, GLfloat z, GLfloat w); -typedef void (APIENTRYP PFNGLWINDOWPOS4FVMESAPROC) (const GLfloat *v); -typedef void (APIENTRYP PFNGLWINDOWPOS4IMESAPROC) (GLint x, GLint y, GLint z, GLint w); -typedef void (APIENTRYP PFNGLWINDOWPOS4IVMESAPROC) (const GLint *v); -typedef void (APIENTRYP PFNGLWINDOWPOS4SMESAPROC) (GLshort x, GLshort y, GLshort z, GLshort w); -typedef void (APIENTRYP PFNGLWINDOWPOS4SVMESAPROC) (const GLshort *v); -#endif - -#ifndef GL_IBM_cull_vertex -#define GL_IBM_cull_vertex 1 -#endif - -#ifndef GL_IBM_multimode_draw_arrays -#define GL_IBM_multimode_draw_arrays 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glMultiModeDrawArraysIBM (const GLenum *, const GLint *, const GLsizei *, GLsizei, GLint); -GLAPI void APIENTRY glMultiModeDrawElementsIBM (const GLenum *, const GLsizei *, GLenum, const GLvoid* const *, GLsizei, GLint); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLMULTIMODEDRAWARRAYSIBMPROC) (const GLenum *mode, const GLint *first, const GLsizei *count, GLsizei primcount, GLint modestride); -typedef void (APIENTRYP PFNGLMULTIMODEDRAWELEMENTSIBMPROC) (const GLenum *mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei primcount, GLint modestride); -#endif - -#ifndef GL_IBM_vertex_array_lists -#define GL_IBM_vertex_array_lists 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glColorPointerListIBM (GLint, GLenum, GLint, const GLvoid* *, GLint); -GLAPI void APIENTRY glSecondaryColorPointerListIBM (GLint, GLenum, GLint, const GLvoid* *, GLint); -GLAPI void APIENTRY glEdgeFlagPointerListIBM (GLint, const GLboolean* *, GLint); -GLAPI void APIENTRY glFogCoordPointerListIBM (GLenum, GLint, const GLvoid* *, GLint); -GLAPI void APIENTRY glIndexPointerListIBM (GLenum, GLint, const GLvoid* *, GLint); -GLAPI void APIENTRY glNormalPointerListIBM (GLenum, GLint, const GLvoid* *, GLint); -GLAPI void APIENTRY glTexCoordPointerListIBM (GLint, GLenum, GLint, const GLvoid* *, GLint); -GLAPI void APIENTRY glVertexPointerListIBM (GLint, GLenum, GLint, const GLvoid* *, GLint); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLCOLORPOINTERLISTIBMPROC) (GLint size, GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride); -typedef void (APIENTRYP PFNGLSECONDARYCOLORPOINTERLISTIBMPROC) (GLint size, GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride); -typedef void (APIENTRYP PFNGLEDGEFLAGPOINTERLISTIBMPROC) (GLint stride, const GLboolean* *pointer, GLint ptrstride); -typedef void (APIENTRYP PFNGLFOGCOORDPOINTERLISTIBMPROC) (GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride); -typedef void (APIENTRYP PFNGLINDEXPOINTERLISTIBMPROC) (GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride); -typedef void (APIENTRYP PFNGLNORMALPOINTERLISTIBMPROC) (GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride); -typedef void (APIENTRYP PFNGLTEXCOORDPOINTERLISTIBMPROC) (GLint size, GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride); -typedef void (APIENTRYP PFNGLVERTEXPOINTERLISTIBMPROC) (GLint size, GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride); -#endif - -#ifndef GL_SGIX_subsample -#define GL_SGIX_subsample 1 -#endif - -#ifndef GL_SGIX_ycrcba -#define GL_SGIX_ycrcba 1 -#endif - -#ifndef GL_SGIX_ycrcb_subsample -#define GL_SGIX_ycrcb_subsample 1 -#endif - -#ifndef GL_SGIX_depth_pass_instrument -#define GL_SGIX_depth_pass_instrument 1 -#endif - -#ifndef GL_3DFX_texture_compression_FXT1 -#define GL_3DFX_texture_compression_FXT1 1 -#endif - -#ifndef GL_3DFX_multisample -#define GL_3DFX_multisample 1 -#endif - -#ifndef GL_3DFX_tbuffer -#define GL_3DFX_tbuffer 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glTbufferMask3DFX (GLuint); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLTBUFFERMASK3DFXPROC) (GLuint mask); -#endif - -#ifndef GL_EXT_multisample -#define GL_EXT_multisample 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glSampleMaskEXT (GLclampf, GLboolean); -GLAPI void APIENTRY glSamplePatternEXT (GLenum); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLSAMPLEMASKEXTPROC) (GLclampf value, GLboolean invert); -typedef void (APIENTRYP PFNGLSAMPLEPATTERNEXTPROC) (GLenum pattern); -#endif - -#ifndef GL_SGIX_vertex_preclip -#define GL_SGIX_vertex_preclip 1 -#endif - -#ifndef GL_SGIX_convolution_accuracy -#define GL_SGIX_convolution_accuracy 1 -#endif - -#ifndef GL_SGIX_resample -#define GL_SGIX_resample 1 -#endif - -#ifndef GL_SGIS_point_line_texgen -#define GL_SGIS_point_line_texgen 1 -#endif - -#ifndef GL_SGIS_texture_color_mask -#define GL_SGIS_texture_color_mask 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glTextureColorMaskSGIS (GLboolean, GLboolean, GLboolean, GLboolean); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLTEXTURECOLORMASKSGISPROC) (GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha); -#endif - -#ifndef GL_SGIX_igloo_interface -#define GL_SGIX_igloo_interface 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glIglooInterfaceSGIX (GLenum, const GLvoid *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLIGLOOINTERFACESGIXPROC) (GLenum pname, const GLvoid *params); -#endif - -#ifndef GL_EXT_texture_env_dot3 -#define GL_EXT_texture_env_dot3 1 -#endif - -#ifndef GL_ATI_texture_mirror_once -#define GL_ATI_texture_mirror_once 1 -#endif - -#ifndef GL_NV_fence -#define GL_NV_fence 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glDeleteFencesNV (GLsizei, const GLuint *); -GLAPI void APIENTRY glGenFencesNV (GLsizei, GLuint *); -GLAPI GLboolean APIENTRY glIsFenceNV (GLuint); -GLAPI GLboolean APIENTRY glTestFenceNV (GLuint); -GLAPI void APIENTRY glGetFenceivNV (GLuint, GLenum, GLint *); -GLAPI void APIENTRY glFinishFenceNV (GLuint); -GLAPI void APIENTRY glSetFenceNV (GLuint, GLenum); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLDELETEFENCESNVPROC) (GLsizei n, const GLuint *fences); -typedef void (APIENTRYP PFNGLGENFENCESNVPROC) (GLsizei n, GLuint *fences); -typedef GLboolean (APIENTRYP PFNGLISFENCENVPROC) (GLuint fence); -typedef GLboolean (APIENTRYP PFNGLTESTFENCENVPROC) (GLuint fence); -typedef void (APIENTRYP PFNGLGETFENCEIVNVPROC) (GLuint fence, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLFINISHFENCENVPROC) (GLuint fence); -typedef void (APIENTRYP PFNGLSETFENCENVPROC) (GLuint fence, GLenum condition); -#endif - -#ifndef GL_NV_evaluators -#define GL_NV_evaluators 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glMapControlPointsNV (GLenum, GLuint, GLenum, GLsizei, GLsizei, GLint, GLint, GLboolean, const GLvoid *); -GLAPI void APIENTRY glMapParameterivNV (GLenum, GLenum, const GLint *); -GLAPI void APIENTRY glMapParameterfvNV (GLenum, GLenum, const GLfloat *); -GLAPI void APIENTRY glGetMapControlPointsNV (GLenum, GLuint, GLenum, GLsizei, GLsizei, GLboolean, GLvoid *); -GLAPI void APIENTRY glGetMapParameterivNV (GLenum, GLenum, GLint *); -GLAPI void APIENTRY glGetMapParameterfvNV (GLenum, GLenum, GLfloat *); -GLAPI void APIENTRY glGetMapAttribParameterivNV (GLenum, GLuint, GLenum, GLint *); -GLAPI void APIENTRY glGetMapAttribParameterfvNV (GLenum, GLuint, GLenum, GLfloat *); -GLAPI void APIENTRY glEvalMapsNV (GLenum, GLenum); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLMAPCONTROLPOINTSNVPROC) (GLenum target, GLuint index, GLenum type, GLsizei ustride, GLsizei vstride, GLint uorder, GLint vorder, GLboolean packed, const GLvoid *points); -typedef void (APIENTRYP PFNGLMAPPARAMETERIVNVPROC) (GLenum target, GLenum pname, const GLint *params); -typedef void (APIENTRYP PFNGLMAPPARAMETERFVNVPROC) (GLenum target, GLenum pname, const GLfloat *params); -typedef void (APIENTRYP PFNGLGETMAPCONTROLPOINTSNVPROC) (GLenum target, GLuint index, GLenum type, GLsizei ustride, GLsizei vstride, GLboolean packed, GLvoid *points); -typedef void (APIENTRYP PFNGLGETMAPPARAMETERIVNVPROC) (GLenum target, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETMAPPARAMETERFVNVPROC) (GLenum target, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETMAPATTRIBPARAMETERIVNVPROC) (GLenum target, GLuint index, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETMAPATTRIBPARAMETERFVNVPROC) (GLenum target, GLuint index, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLEVALMAPSNVPROC) (GLenum target, GLenum mode); -#endif - -#ifndef GL_NV_packed_depth_stencil -#define GL_NV_packed_depth_stencil 1 -#endif - -#ifndef GL_NV_register_combiners2 -#define GL_NV_register_combiners2 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glCombinerStageParameterfvNV (GLenum, GLenum, const GLfloat *); -GLAPI void APIENTRY glGetCombinerStageParameterfvNV (GLenum, GLenum, GLfloat *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLCOMBINERSTAGEPARAMETERFVNVPROC) (GLenum stage, GLenum pname, const GLfloat *params); -typedef void (APIENTRYP PFNGLGETCOMBINERSTAGEPARAMETERFVNVPROC) (GLenum stage, GLenum pname, GLfloat *params); -#endif - -#ifndef GL_NV_texture_compression_vtc -#define GL_NV_texture_compression_vtc 1 -#endif - -#ifndef GL_NV_texture_rectangle -#define GL_NV_texture_rectangle 1 -#endif - -#ifndef GL_NV_texture_shader -#define GL_NV_texture_shader 1 -#endif - -#ifndef GL_NV_texture_shader2 -#define GL_NV_texture_shader2 1 -#endif - -#ifndef GL_NV_vertex_array_range2 -#define GL_NV_vertex_array_range2 1 -#endif - -#ifndef GL_NV_vertex_program -#define GL_NV_vertex_program 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI GLboolean APIENTRY glAreProgramsResidentNV (GLsizei, const GLuint *, GLboolean *); -GLAPI void APIENTRY glBindProgramNV (GLenum, GLuint); -GLAPI void APIENTRY glDeleteProgramsNV (GLsizei, const GLuint *); -GLAPI void APIENTRY glExecuteProgramNV (GLenum, GLuint, const GLfloat *); -GLAPI void APIENTRY glGenProgramsNV (GLsizei, GLuint *); -GLAPI void APIENTRY glGetProgramParameterdvNV (GLenum, GLuint, GLenum, GLdouble *); -GLAPI void APIENTRY glGetProgramParameterfvNV (GLenum, GLuint, GLenum, GLfloat *); -GLAPI void APIENTRY glGetProgramivNV (GLuint, GLenum, GLint *); -GLAPI void APIENTRY glGetProgramStringNV (GLuint, GLenum, GLubyte *); -GLAPI void APIENTRY glGetTrackMatrixivNV (GLenum, GLuint, GLenum, GLint *); -GLAPI void APIENTRY glGetVertexAttribdvNV (GLuint, GLenum, GLdouble *); -GLAPI void APIENTRY glGetVertexAttribfvNV (GLuint, GLenum, GLfloat *); -GLAPI void APIENTRY glGetVertexAttribivNV (GLuint, GLenum, GLint *); -GLAPI void APIENTRY glGetVertexAttribPointervNV (GLuint, GLenum, GLvoid* *); -GLAPI GLboolean APIENTRY glIsProgramNV (GLuint); -GLAPI void APIENTRY glLoadProgramNV (GLenum, GLuint, GLsizei, const GLubyte *); -GLAPI void APIENTRY glProgramParameter4dNV (GLenum, GLuint, GLdouble, GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glProgramParameter4dvNV (GLenum, GLuint, const GLdouble *); -GLAPI void APIENTRY glProgramParameter4fNV (GLenum, GLuint, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glProgramParameter4fvNV (GLenum, GLuint, const GLfloat *); -GLAPI void APIENTRY glProgramParameters4dvNV (GLenum, GLuint, GLuint, const GLdouble *); -GLAPI void APIENTRY glProgramParameters4fvNV (GLenum, GLuint, GLuint, const GLfloat *); -GLAPI void APIENTRY glRequestResidentProgramsNV (GLsizei, const GLuint *); -GLAPI void APIENTRY glTrackMatrixNV (GLenum, GLuint, GLenum, GLenum); -GLAPI void APIENTRY glVertexAttribPointerNV (GLuint, GLint, GLenum, GLsizei, const GLvoid *); -GLAPI void APIENTRY glVertexAttrib1dNV (GLuint, GLdouble); -GLAPI void APIENTRY glVertexAttrib1dvNV (GLuint, const GLdouble *); -GLAPI void APIENTRY glVertexAttrib1fNV (GLuint, GLfloat); -GLAPI void APIENTRY glVertexAttrib1fvNV (GLuint, const GLfloat *); -GLAPI void APIENTRY glVertexAttrib1sNV (GLuint, GLshort); -GLAPI void APIENTRY glVertexAttrib1svNV (GLuint, const GLshort *); -GLAPI void APIENTRY glVertexAttrib2dNV (GLuint, GLdouble, GLdouble); -GLAPI void APIENTRY glVertexAttrib2dvNV (GLuint, const GLdouble *); -GLAPI void APIENTRY glVertexAttrib2fNV (GLuint, GLfloat, GLfloat); -GLAPI void APIENTRY glVertexAttrib2fvNV (GLuint, const GLfloat *); -GLAPI void APIENTRY glVertexAttrib2sNV (GLuint, GLshort, GLshort); -GLAPI void APIENTRY glVertexAttrib2svNV (GLuint, const GLshort *); -GLAPI void APIENTRY glVertexAttrib3dNV (GLuint, GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glVertexAttrib3dvNV (GLuint, const GLdouble *); -GLAPI void APIENTRY glVertexAttrib3fNV (GLuint, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glVertexAttrib3fvNV (GLuint, const GLfloat *); -GLAPI void APIENTRY glVertexAttrib3sNV (GLuint, GLshort, GLshort, GLshort); -GLAPI void APIENTRY glVertexAttrib3svNV (GLuint, const GLshort *); -GLAPI void APIENTRY glVertexAttrib4dNV (GLuint, GLdouble, GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glVertexAttrib4dvNV (GLuint, const GLdouble *); -GLAPI void APIENTRY glVertexAttrib4fNV (GLuint, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glVertexAttrib4fvNV (GLuint, const GLfloat *); -GLAPI void APIENTRY glVertexAttrib4sNV (GLuint, GLshort, GLshort, GLshort, GLshort); -GLAPI void APIENTRY glVertexAttrib4svNV (GLuint, const GLshort *); -GLAPI void APIENTRY glVertexAttrib4ubNV (GLuint, GLubyte, GLubyte, GLubyte, GLubyte); -GLAPI void APIENTRY glVertexAttrib4ubvNV (GLuint, const GLubyte *); -GLAPI void APIENTRY glVertexAttribs1dvNV (GLuint, GLsizei, const GLdouble *); -GLAPI void APIENTRY glVertexAttribs1fvNV (GLuint, GLsizei, const GLfloat *); -GLAPI void APIENTRY glVertexAttribs1svNV (GLuint, GLsizei, const GLshort *); -GLAPI void APIENTRY glVertexAttribs2dvNV (GLuint, GLsizei, const GLdouble *); -GLAPI void APIENTRY glVertexAttribs2fvNV (GLuint, GLsizei, const GLfloat *); -GLAPI void APIENTRY glVertexAttribs2svNV (GLuint, GLsizei, const GLshort *); -GLAPI void APIENTRY glVertexAttribs3dvNV (GLuint, GLsizei, const GLdouble *); -GLAPI void APIENTRY glVertexAttribs3fvNV (GLuint, GLsizei, const GLfloat *); -GLAPI void APIENTRY glVertexAttribs3svNV (GLuint, GLsizei, const GLshort *); -GLAPI void APIENTRY glVertexAttribs4dvNV (GLuint, GLsizei, const GLdouble *); -GLAPI void APIENTRY glVertexAttribs4fvNV (GLuint, GLsizei, const GLfloat *); -GLAPI void APIENTRY glVertexAttribs4svNV (GLuint, GLsizei, const GLshort *); -GLAPI void APIENTRY glVertexAttribs4ubvNV (GLuint, GLsizei, const GLubyte *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef GLboolean (APIENTRYP PFNGLAREPROGRAMSRESIDENTNVPROC) (GLsizei n, const GLuint *programs, GLboolean *residences); -typedef void (APIENTRYP PFNGLBINDPROGRAMNVPROC) (GLenum target, GLuint id); -typedef void (APIENTRYP PFNGLDELETEPROGRAMSNVPROC) (GLsizei n, const GLuint *programs); -typedef void (APIENTRYP PFNGLEXECUTEPROGRAMNVPROC) (GLenum target, GLuint id, const GLfloat *params); -typedef void (APIENTRYP PFNGLGENPROGRAMSNVPROC) (GLsizei n, GLuint *programs); -typedef void (APIENTRYP PFNGLGETPROGRAMPARAMETERDVNVPROC) (GLenum target, GLuint index, GLenum pname, GLdouble *params); -typedef void (APIENTRYP PFNGLGETPROGRAMPARAMETERFVNVPROC) (GLenum target, GLuint index, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETPROGRAMIVNVPROC) (GLuint id, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETPROGRAMSTRINGNVPROC) (GLuint id, GLenum pname, GLubyte *program); -typedef void (APIENTRYP PFNGLGETTRACKMATRIXIVNVPROC) (GLenum target, GLuint address, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETVERTEXATTRIBDVNVPROC) (GLuint index, GLenum pname, GLdouble *params); -typedef void (APIENTRYP PFNGLGETVERTEXATTRIBFVNVPROC) (GLuint index, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETVERTEXATTRIBIVNVPROC) (GLuint index, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETVERTEXATTRIBPOINTERVNVPROC) (GLuint index, GLenum pname, GLvoid* *pointer); -typedef GLboolean (APIENTRYP PFNGLISPROGRAMNVPROC) (GLuint id); -typedef void (APIENTRYP PFNGLLOADPROGRAMNVPROC) (GLenum target, GLuint id, GLsizei len, const GLubyte *program); -typedef void (APIENTRYP PFNGLPROGRAMPARAMETER4DNVPROC) (GLenum target, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w); -typedef void (APIENTRYP PFNGLPROGRAMPARAMETER4DVNVPROC) (GLenum target, GLuint index, const GLdouble *v); -typedef void (APIENTRYP PFNGLPROGRAMPARAMETER4FNVPROC) (GLenum target, GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w); -typedef void (APIENTRYP PFNGLPROGRAMPARAMETER4FVNVPROC) (GLenum target, GLuint index, const GLfloat *v); -typedef void (APIENTRYP PFNGLPROGRAMPARAMETERS4DVNVPROC) (GLenum target, GLuint index, GLuint count, const GLdouble *v); -typedef void (APIENTRYP PFNGLPROGRAMPARAMETERS4FVNVPROC) (GLenum target, GLuint index, GLuint count, const GLfloat *v); -typedef void (APIENTRYP PFNGLREQUESTRESIDENTPROGRAMSNVPROC) (GLsizei n, const GLuint *programs); -typedef void (APIENTRYP PFNGLTRACKMATRIXNVPROC) (GLenum target, GLuint address, GLenum matrix, GLenum transform); -typedef void (APIENTRYP PFNGLVERTEXATTRIBPOINTERNVPROC) (GLuint index, GLint fsize, GLenum type, GLsizei stride, const GLvoid *pointer); -typedef void (APIENTRYP PFNGLVERTEXATTRIB1DNVPROC) (GLuint index, GLdouble x); -typedef void (APIENTRYP PFNGLVERTEXATTRIB1DVNVPROC) (GLuint index, const GLdouble *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB1FNVPROC) (GLuint index, GLfloat x); -typedef void (APIENTRYP PFNGLVERTEXATTRIB1FVNVPROC) (GLuint index, const GLfloat *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB1SNVPROC) (GLuint index, GLshort x); -typedef void (APIENTRYP PFNGLVERTEXATTRIB1SVNVPROC) (GLuint index, const GLshort *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB2DNVPROC) (GLuint index, GLdouble x, GLdouble y); -typedef void (APIENTRYP PFNGLVERTEXATTRIB2DVNVPROC) (GLuint index, const GLdouble *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB2FNVPROC) (GLuint index, GLfloat x, GLfloat y); -typedef void (APIENTRYP PFNGLVERTEXATTRIB2FVNVPROC) (GLuint index, const GLfloat *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB2SNVPROC) (GLuint index, GLshort x, GLshort y); -typedef void (APIENTRYP PFNGLVERTEXATTRIB2SVNVPROC) (GLuint index, const GLshort *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB3DNVPROC) (GLuint index, GLdouble x, GLdouble y, GLdouble z); -typedef void (APIENTRYP PFNGLVERTEXATTRIB3DVNVPROC) (GLuint index, const GLdouble *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB3FNVPROC) (GLuint index, GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLVERTEXATTRIB3FVNVPROC) (GLuint index, const GLfloat *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB3SNVPROC) (GLuint index, GLshort x, GLshort y, GLshort z); -typedef void (APIENTRYP PFNGLVERTEXATTRIB3SVNVPROC) (GLuint index, const GLshort *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4DNVPROC) (GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4DVNVPROC) (GLuint index, const GLdouble *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4FNVPROC) (GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4FVNVPROC) (GLuint index, const GLfloat *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4SNVPROC) (GLuint index, GLshort x, GLshort y, GLshort z, GLshort w); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4SVNVPROC) (GLuint index, const GLshort *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4UBNVPROC) (GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4UBVNVPROC) (GLuint index, const GLubyte *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBS1DVNVPROC) (GLuint index, GLsizei count, const GLdouble *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBS1FVNVPROC) (GLuint index, GLsizei count, const GLfloat *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBS1SVNVPROC) (GLuint index, GLsizei count, const GLshort *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBS2DVNVPROC) (GLuint index, GLsizei count, const GLdouble *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBS2FVNVPROC) (GLuint index, GLsizei count, const GLfloat *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBS2SVNVPROC) (GLuint index, GLsizei count, const GLshort *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBS3DVNVPROC) (GLuint index, GLsizei count, const GLdouble *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBS3FVNVPROC) (GLuint index, GLsizei count, const GLfloat *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBS3SVNVPROC) (GLuint index, GLsizei count, const GLshort *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBS4DVNVPROC) (GLuint index, GLsizei count, const GLdouble *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBS4FVNVPROC) (GLuint index, GLsizei count, const GLfloat *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBS4SVNVPROC) (GLuint index, GLsizei count, const GLshort *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBS4UBVNVPROC) (GLuint index, GLsizei count, const GLubyte *v); -#endif - -#ifndef GL_SGIX_texture_coordinate_clamp -#define GL_SGIX_texture_coordinate_clamp 1 -#endif - -#ifndef GL_SGIX_scalebias_hint -#define GL_SGIX_scalebias_hint 1 -#endif - -#ifndef GL_OML_interlace -#define GL_OML_interlace 1 -#endif - -#ifndef GL_OML_subsample -#define GL_OML_subsample 1 -#endif - -#ifndef GL_OML_resample -#define GL_OML_resample 1 -#endif - -#ifndef GL_NV_copy_depth_to_color -#define GL_NV_copy_depth_to_color 1 -#endif - -#ifndef GL_ATI_envmap_bumpmap -#define GL_ATI_envmap_bumpmap 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glTexBumpParameterivATI (GLenum, const GLint *); -GLAPI void APIENTRY glTexBumpParameterfvATI (GLenum, const GLfloat *); -GLAPI void APIENTRY glGetTexBumpParameterivATI (GLenum, GLint *); -GLAPI void APIENTRY glGetTexBumpParameterfvATI (GLenum, GLfloat *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLTEXBUMPPARAMETERIVATIPROC) (GLenum pname, const GLint *param); -typedef void (APIENTRYP PFNGLTEXBUMPPARAMETERFVATIPROC) (GLenum pname, const GLfloat *param); -typedef void (APIENTRYP PFNGLGETTEXBUMPPARAMETERIVATIPROC) (GLenum pname, GLint *param); -typedef void (APIENTRYP PFNGLGETTEXBUMPPARAMETERFVATIPROC) (GLenum pname, GLfloat *param); -#endif - -#ifndef GL_ATI_fragment_shader -#define GL_ATI_fragment_shader 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI GLuint APIENTRY glGenFragmentShadersATI (GLuint); -GLAPI void APIENTRY glBindFragmentShaderATI (GLuint); -GLAPI void APIENTRY glDeleteFragmentShaderATI (GLuint); -GLAPI void APIENTRY glBeginFragmentShaderATI (void); -GLAPI void APIENTRY glEndFragmentShaderATI (void); -GLAPI void APIENTRY glPassTexCoordATI (GLuint, GLuint, GLenum); -GLAPI void APIENTRY glSampleMapATI (GLuint, GLuint, GLenum); -GLAPI void APIENTRY glColorFragmentOp1ATI (GLenum, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint); -GLAPI void APIENTRY glColorFragmentOp2ATI (GLenum, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint); -GLAPI void APIENTRY glColorFragmentOp3ATI (GLenum, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint); -GLAPI void APIENTRY glAlphaFragmentOp1ATI (GLenum, GLuint, GLuint, GLuint, GLuint, GLuint); -GLAPI void APIENTRY glAlphaFragmentOp2ATI (GLenum, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint); -GLAPI void APIENTRY glAlphaFragmentOp3ATI (GLenum, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint); -GLAPI void APIENTRY glSetFragmentShaderConstantATI (GLuint, const GLfloat *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef GLuint (APIENTRYP PFNGLGENFRAGMENTSHADERSATIPROC) (GLuint range); -typedef void (APIENTRYP PFNGLBINDFRAGMENTSHADERATIPROC) (GLuint id); -typedef void (APIENTRYP PFNGLDELETEFRAGMENTSHADERATIPROC) (GLuint id); -typedef void (APIENTRYP PFNGLBEGINFRAGMENTSHADERATIPROC) (void); -typedef void (APIENTRYP PFNGLENDFRAGMENTSHADERATIPROC) (void); -typedef void (APIENTRYP PFNGLPASSTEXCOORDATIPROC) (GLuint dst, GLuint coord, GLenum swizzle); -typedef void (APIENTRYP PFNGLSAMPLEMAPATIPROC) (GLuint dst, GLuint interp, GLenum swizzle); -typedef void (APIENTRYP PFNGLCOLORFRAGMENTOP1ATIPROC) (GLenum op, GLuint dst, GLuint dstMask, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod); -typedef void (APIENTRYP PFNGLCOLORFRAGMENTOP2ATIPROC) (GLenum op, GLuint dst, GLuint dstMask, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod, GLuint arg2, GLuint arg2Rep, GLuint arg2Mod); -typedef void (APIENTRYP PFNGLCOLORFRAGMENTOP3ATIPROC) (GLenum op, GLuint dst, GLuint dstMask, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod, GLuint arg2, GLuint arg2Rep, GLuint arg2Mod, GLuint arg3, GLuint arg3Rep, GLuint arg3Mod); -typedef void (APIENTRYP PFNGLALPHAFRAGMENTOP1ATIPROC) (GLenum op, GLuint dst, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod); -typedef void (APIENTRYP PFNGLALPHAFRAGMENTOP2ATIPROC) (GLenum op, GLuint dst, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod, GLuint arg2, GLuint arg2Rep, GLuint arg2Mod); -typedef void (APIENTRYP PFNGLALPHAFRAGMENTOP3ATIPROC) (GLenum op, GLuint dst, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod, GLuint arg2, GLuint arg2Rep, GLuint arg2Mod, GLuint arg3, GLuint arg3Rep, GLuint arg3Mod); -typedef void (APIENTRYP PFNGLSETFRAGMENTSHADERCONSTANTATIPROC) (GLuint dst, const GLfloat *value); -#endif - -#ifndef GL_ATI_pn_triangles -#define GL_ATI_pn_triangles 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glPNTrianglesiATI (GLenum, GLint); -GLAPI void APIENTRY glPNTrianglesfATI (GLenum, GLfloat); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLPNTRIANGLESIATIPROC) (GLenum pname, GLint param); -typedef void (APIENTRYP PFNGLPNTRIANGLESFATIPROC) (GLenum pname, GLfloat param); -#endif - -#ifndef GL_ATI_vertex_array_object -#define GL_ATI_vertex_array_object 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI GLuint APIENTRY glNewObjectBufferATI (GLsizei, const GLvoid *, GLenum); -GLAPI GLboolean APIENTRY glIsObjectBufferATI (GLuint); -GLAPI void APIENTRY glUpdateObjectBufferATI (GLuint, GLuint, GLsizei, const GLvoid *, GLenum); -GLAPI void APIENTRY glGetObjectBufferfvATI (GLuint, GLenum, GLfloat *); -GLAPI void APIENTRY glGetObjectBufferivATI (GLuint, GLenum, GLint *); -GLAPI void APIENTRY glFreeObjectBufferATI (GLuint); -GLAPI void APIENTRY glArrayObjectATI (GLenum, GLint, GLenum, GLsizei, GLuint, GLuint); -GLAPI void APIENTRY glGetArrayObjectfvATI (GLenum, GLenum, GLfloat *); -GLAPI void APIENTRY glGetArrayObjectivATI (GLenum, GLenum, GLint *); -GLAPI void APIENTRY glVariantArrayObjectATI (GLuint, GLenum, GLsizei, GLuint, GLuint); -GLAPI void APIENTRY glGetVariantArrayObjectfvATI (GLuint, GLenum, GLfloat *); -GLAPI void APIENTRY glGetVariantArrayObjectivATI (GLuint, GLenum, GLint *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef GLuint (APIENTRYP PFNGLNEWOBJECTBUFFERATIPROC) (GLsizei size, const GLvoid *pointer, GLenum usage); -typedef GLboolean (APIENTRYP PFNGLISOBJECTBUFFERATIPROC) (GLuint buffer); -typedef void (APIENTRYP PFNGLUPDATEOBJECTBUFFERATIPROC) (GLuint buffer, GLuint offset, GLsizei size, const GLvoid *pointer, GLenum preserve); -typedef void (APIENTRYP PFNGLGETOBJECTBUFFERFVATIPROC) (GLuint buffer, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETOBJECTBUFFERIVATIPROC) (GLuint buffer, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLFREEOBJECTBUFFERATIPROC) (GLuint buffer); -typedef void (APIENTRYP PFNGLARRAYOBJECTATIPROC) (GLenum array, GLint size, GLenum type, GLsizei stride, GLuint buffer, GLuint offset); -typedef void (APIENTRYP PFNGLGETARRAYOBJECTFVATIPROC) (GLenum array, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETARRAYOBJECTIVATIPROC) (GLenum array, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLVARIANTARRAYOBJECTATIPROC) (GLuint id, GLenum type, GLsizei stride, GLuint buffer, GLuint offset); -typedef void (APIENTRYP PFNGLGETVARIANTARRAYOBJECTFVATIPROC) (GLuint id, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETVARIANTARRAYOBJECTIVATIPROC) (GLuint id, GLenum pname, GLint *params); -#endif - -#ifndef GL_EXT_vertex_shader -#define GL_EXT_vertex_shader 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glBeginVertexShaderEXT (void); -GLAPI void APIENTRY glEndVertexShaderEXT (void); -GLAPI void APIENTRY glBindVertexShaderEXT (GLuint); -GLAPI GLuint APIENTRY glGenVertexShadersEXT (GLuint); -GLAPI void APIENTRY glDeleteVertexShaderEXT (GLuint); -GLAPI void APIENTRY glShaderOp1EXT (GLenum, GLuint, GLuint); -GLAPI void APIENTRY glShaderOp2EXT (GLenum, GLuint, GLuint, GLuint); -GLAPI void APIENTRY glShaderOp3EXT (GLenum, GLuint, GLuint, GLuint, GLuint); -GLAPI void APIENTRY glSwizzleEXT (GLuint, GLuint, GLenum, GLenum, GLenum, GLenum); -GLAPI void APIENTRY glWriteMaskEXT (GLuint, GLuint, GLenum, GLenum, GLenum, GLenum); -GLAPI void APIENTRY glInsertComponentEXT (GLuint, GLuint, GLuint); -GLAPI void APIENTRY glExtractComponentEXT (GLuint, GLuint, GLuint); -GLAPI GLuint APIENTRY glGenSymbolsEXT (GLenum, GLenum, GLenum, GLuint); -GLAPI void APIENTRY glSetInvariantEXT (GLuint, GLenum, const GLvoid *); -GLAPI void APIENTRY glSetLocalConstantEXT (GLuint, GLenum, const GLvoid *); -GLAPI void APIENTRY glVariantbvEXT (GLuint, const GLbyte *); -GLAPI void APIENTRY glVariantsvEXT (GLuint, const GLshort *); -GLAPI void APIENTRY glVariantivEXT (GLuint, const GLint *); -GLAPI void APIENTRY glVariantfvEXT (GLuint, const GLfloat *); -GLAPI void APIENTRY glVariantdvEXT (GLuint, const GLdouble *); -GLAPI void APIENTRY glVariantubvEXT (GLuint, const GLubyte *); -GLAPI void APIENTRY glVariantusvEXT (GLuint, const GLushort *); -GLAPI void APIENTRY glVariantuivEXT (GLuint, const GLuint *); -GLAPI void APIENTRY glVariantPointerEXT (GLuint, GLenum, GLuint, const GLvoid *); -GLAPI void APIENTRY glEnableVariantClientStateEXT (GLuint); -GLAPI void APIENTRY glDisableVariantClientStateEXT (GLuint); -GLAPI GLuint APIENTRY glBindLightParameterEXT (GLenum, GLenum); -GLAPI GLuint APIENTRY glBindMaterialParameterEXT (GLenum, GLenum); -GLAPI GLuint APIENTRY glBindTexGenParameterEXT (GLenum, GLenum, GLenum); -GLAPI GLuint APIENTRY glBindTextureUnitParameterEXT (GLenum, GLenum); -GLAPI GLuint APIENTRY glBindParameterEXT (GLenum); -GLAPI GLboolean APIENTRY glIsVariantEnabledEXT (GLuint, GLenum); -GLAPI void APIENTRY glGetVariantBooleanvEXT (GLuint, GLenum, GLboolean *); -GLAPI void APIENTRY glGetVariantIntegervEXT (GLuint, GLenum, GLint *); -GLAPI void APIENTRY glGetVariantFloatvEXT (GLuint, GLenum, GLfloat *); -GLAPI void APIENTRY glGetVariantPointervEXT (GLuint, GLenum, GLvoid* *); -GLAPI void APIENTRY glGetInvariantBooleanvEXT (GLuint, GLenum, GLboolean *); -GLAPI void APIENTRY glGetInvariantIntegervEXT (GLuint, GLenum, GLint *); -GLAPI void APIENTRY glGetInvariantFloatvEXT (GLuint, GLenum, GLfloat *); -GLAPI void APIENTRY glGetLocalConstantBooleanvEXT (GLuint, GLenum, GLboolean *); -GLAPI void APIENTRY glGetLocalConstantIntegervEXT (GLuint, GLenum, GLint *); -GLAPI void APIENTRY glGetLocalConstantFloatvEXT (GLuint, GLenum, GLfloat *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLBEGINVERTEXSHADEREXTPROC) (void); -typedef void (APIENTRYP PFNGLENDVERTEXSHADEREXTPROC) (void); -typedef void (APIENTRYP PFNGLBINDVERTEXSHADEREXTPROC) (GLuint id); -typedef GLuint (APIENTRYP PFNGLGENVERTEXSHADERSEXTPROC) (GLuint range); -typedef void (APIENTRYP PFNGLDELETEVERTEXSHADEREXTPROC) (GLuint id); -typedef void (APIENTRYP PFNGLSHADEROP1EXTPROC) (GLenum op, GLuint res, GLuint arg1); -typedef void (APIENTRYP PFNGLSHADEROP2EXTPROC) (GLenum op, GLuint res, GLuint arg1, GLuint arg2); -typedef void (APIENTRYP PFNGLSHADEROP3EXTPROC) (GLenum op, GLuint res, GLuint arg1, GLuint arg2, GLuint arg3); -typedef void (APIENTRYP PFNGLSWIZZLEEXTPROC) (GLuint res, GLuint in, GLenum outX, GLenum outY, GLenum outZ, GLenum outW); -typedef void (APIENTRYP PFNGLWRITEMASKEXTPROC) (GLuint res, GLuint in, GLenum outX, GLenum outY, GLenum outZ, GLenum outW); -typedef void (APIENTRYP PFNGLINSERTCOMPONENTEXTPROC) (GLuint res, GLuint src, GLuint num); -typedef void (APIENTRYP PFNGLEXTRACTCOMPONENTEXTPROC) (GLuint res, GLuint src, GLuint num); -typedef GLuint (APIENTRYP PFNGLGENSYMBOLSEXTPROC) (GLenum datatype, GLenum storagetype, GLenum range, GLuint components); -typedef void (APIENTRYP PFNGLSETINVARIANTEXTPROC) (GLuint id, GLenum type, const GLvoid *addr); -typedef void (APIENTRYP PFNGLSETLOCALCONSTANTEXTPROC) (GLuint id, GLenum type, const GLvoid *addr); -typedef void (APIENTRYP PFNGLVARIANTBVEXTPROC) (GLuint id, const GLbyte *addr); -typedef void (APIENTRYP PFNGLVARIANTSVEXTPROC) (GLuint id, const GLshort *addr); -typedef void (APIENTRYP PFNGLVARIANTIVEXTPROC) (GLuint id, const GLint *addr); -typedef void (APIENTRYP PFNGLVARIANTFVEXTPROC) (GLuint id, const GLfloat *addr); -typedef void (APIENTRYP PFNGLVARIANTDVEXTPROC) (GLuint id, const GLdouble *addr); -typedef void (APIENTRYP PFNGLVARIANTUBVEXTPROC) (GLuint id, const GLubyte *addr); -typedef void (APIENTRYP PFNGLVARIANTUSVEXTPROC) (GLuint id, const GLushort *addr); -typedef void (APIENTRYP PFNGLVARIANTUIVEXTPROC) (GLuint id, const GLuint *addr); -typedef void (APIENTRYP PFNGLVARIANTPOINTEREXTPROC) (GLuint id, GLenum type, GLuint stride, const GLvoid *addr); -typedef void (APIENTRYP PFNGLENABLEVARIANTCLIENTSTATEEXTPROC) (GLuint id); -typedef void (APIENTRYP PFNGLDISABLEVARIANTCLIENTSTATEEXTPROC) (GLuint id); -typedef GLuint (APIENTRYP PFNGLBINDLIGHTPARAMETEREXTPROC) (GLenum light, GLenum value); -typedef GLuint (APIENTRYP PFNGLBINDMATERIALPARAMETEREXTPROC) (GLenum face, GLenum value); -typedef GLuint (APIENTRYP PFNGLBINDTEXGENPARAMETEREXTPROC) (GLenum unit, GLenum coord, GLenum value); -typedef GLuint (APIENTRYP PFNGLBINDTEXTUREUNITPARAMETEREXTPROC) (GLenum unit, GLenum value); -typedef GLuint (APIENTRYP PFNGLBINDPARAMETEREXTPROC) (GLenum value); -typedef GLboolean (APIENTRYP PFNGLISVARIANTENABLEDEXTPROC) (GLuint id, GLenum cap); -typedef void (APIENTRYP PFNGLGETVARIANTBOOLEANVEXTPROC) (GLuint id, GLenum value, GLboolean *data); -typedef void (APIENTRYP PFNGLGETVARIANTINTEGERVEXTPROC) (GLuint id, GLenum value, GLint *data); -typedef void (APIENTRYP PFNGLGETVARIANTFLOATVEXTPROC) (GLuint id, GLenum value, GLfloat *data); -typedef void (APIENTRYP PFNGLGETVARIANTPOINTERVEXTPROC) (GLuint id, GLenum value, GLvoid* *data); -typedef void (APIENTRYP PFNGLGETINVARIANTBOOLEANVEXTPROC) (GLuint id, GLenum value, GLboolean *data); -typedef void (APIENTRYP PFNGLGETINVARIANTINTEGERVEXTPROC) (GLuint id, GLenum value, GLint *data); -typedef void (APIENTRYP PFNGLGETINVARIANTFLOATVEXTPROC) (GLuint id, GLenum value, GLfloat *data); -typedef void (APIENTRYP PFNGLGETLOCALCONSTANTBOOLEANVEXTPROC) (GLuint id, GLenum value, GLboolean *data); -typedef void (APIENTRYP PFNGLGETLOCALCONSTANTINTEGERVEXTPROC) (GLuint id, GLenum value, GLint *data); -typedef void (APIENTRYP PFNGLGETLOCALCONSTANTFLOATVEXTPROC) (GLuint id, GLenum value, GLfloat *data); -#endif - -#ifndef GL_ATI_vertex_streams -#define GL_ATI_vertex_streams 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glVertexStream1sATI (GLenum, GLshort); -GLAPI void APIENTRY glVertexStream1svATI (GLenum, const GLshort *); -GLAPI void APIENTRY glVertexStream1iATI (GLenum, GLint); -GLAPI void APIENTRY glVertexStream1ivATI (GLenum, const GLint *); -GLAPI void APIENTRY glVertexStream1fATI (GLenum, GLfloat); -GLAPI void APIENTRY glVertexStream1fvATI (GLenum, const GLfloat *); -GLAPI void APIENTRY glVertexStream1dATI (GLenum, GLdouble); -GLAPI void APIENTRY glVertexStream1dvATI (GLenum, const GLdouble *); -GLAPI void APIENTRY glVertexStream2sATI (GLenum, GLshort, GLshort); -GLAPI void APIENTRY glVertexStream2svATI (GLenum, const GLshort *); -GLAPI void APIENTRY glVertexStream2iATI (GLenum, GLint, GLint); -GLAPI void APIENTRY glVertexStream2ivATI (GLenum, const GLint *); -GLAPI void APIENTRY glVertexStream2fATI (GLenum, GLfloat, GLfloat); -GLAPI void APIENTRY glVertexStream2fvATI (GLenum, const GLfloat *); -GLAPI void APIENTRY glVertexStream2dATI (GLenum, GLdouble, GLdouble); -GLAPI void APIENTRY glVertexStream2dvATI (GLenum, const GLdouble *); -GLAPI void APIENTRY glVertexStream3sATI (GLenum, GLshort, GLshort, GLshort); -GLAPI void APIENTRY glVertexStream3svATI (GLenum, const GLshort *); -GLAPI void APIENTRY glVertexStream3iATI (GLenum, GLint, GLint, GLint); -GLAPI void APIENTRY glVertexStream3ivATI (GLenum, const GLint *); -GLAPI void APIENTRY glVertexStream3fATI (GLenum, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glVertexStream3fvATI (GLenum, const GLfloat *); -GLAPI void APIENTRY glVertexStream3dATI (GLenum, GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glVertexStream3dvATI (GLenum, const GLdouble *); -GLAPI void APIENTRY glVertexStream4sATI (GLenum, GLshort, GLshort, GLshort, GLshort); -GLAPI void APIENTRY glVertexStream4svATI (GLenum, const GLshort *); -GLAPI void APIENTRY glVertexStream4iATI (GLenum, GLint, GLint, GLint, GLint); -GLAPI void APIENTRY glVertexStream4ivATI (GLenum, const GLint *); -GLAPI void APIENTRY glVertexStream4fATI (GLenum, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glVertexStream4fvATI (GLenum, const GLfloat *); -GLAPI void APIENTRY glVertexStream4dATI (GLenum, GLdouble, GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glVertexStream4dvATI (GLenum, const GLdouble *); -GLAPI void APIENTRY glNormalStream3bATI (GLenum, GLbyte, GLbyte, GLbyte); -GLAPI void APIENTRY glNormalStream3bvATI (GLenum, const GLbyte *); -GLAPI void APIENTRY glNormalStream3sATI (GLenum, GLshort, GLshort, GLshort); -GLAPI void APIENTRY glNormalStream3svATI (GLenum, const GLshort *); -GLAPI void APIENTRY glNormalStream3iATI (GLenum, GLint, GLint, GLint); -GLAPI void APIENTRY glNormalStream3ivATI (GLenum, const GLint *); -GLAPI void APIENTRY glNormalStream3fATI (GLenum, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glNormalStream3fvATI (GLenum, const GLfloat *); -GLAPI void APIENTRY glNormalStream3dATI (GLenum, GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glNormalStream3dvATI (GLenum, const GLdouble *); -GLAPI void APIENTRY glClientActiveVertexStreamATI (GLenum); -GLAPI void APIENTRY glVertexBlendEnviATI (GLenum, GLint); -GLAPI void APIENTRY glVertexBlendEnvfATI (GLenum, GLfloat); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLVERTEXSTREAM1SATIPROC) (GLenum stream, GLshort x); -typedef void (APIENTRYP PFNGLVERTEXSTREAM1SVATIPROC) (GLenum stream, const GLshort *coords); -typedef void (APIENTRYP PFNGLVERTEXSTREAM1IATIPROC) (GLenum stream, GLint x); -typedef void (APIENTRYP PFNGLVERTEXSTREAM1IVATIPROC) (GLenum stream, const GLint *coords); -typedef void (APIENTRYP PFNGLVERTEXSTREAM1FATIPROC) (GLenum stream, GLfloat x); -typedef void (APIENTRYP PFNGLVERTEXSTREAM1FVATIPROC) (GLenum stream, const GLfloat *coords); -typedef void (APIENTRYP PFNGLVERTEXSTREAM1DATIPROC) (GLenum stream, GLdouble x); -typedef void (APIENTRYP PFNGLVERTEXSTREAM1DVATIPROC) (GLenum stream, const GLdouble *coords); -typedef void (APIENTRYP PFNGLVERTEXSTREAM2SATIPROC) (GLenum stream, GLshort x, GLshort y); -typedef void (APIENTRYP PFNGLVERTEXSTREAM2SVATIPROC) (GLenum stream, const GLshort *coords); -typedef void (APIENTRYP PFNGLVERTEXSTREAM2IATIPROC) (GLenum stream, GLint x, GLint y); -typedef void (APIENTRYP PFNGLVERTEXSTREAM2IVATIPROC) (GLenum stream, const GLint *coords); -typedef void (APIENTRYP PFNGLVERTEXSTREAM2FATIPROC) (GLenum stream, GLfloat x, GLfloat y); -typedef void (APIENTRYP PFNGLVERTEXSTREAM2FVATIPROC) (GLenum stream, const GLfloat *coords); -typedef void (APIENTRYP PFNGLVERTEXSTREAM2DATIPROC) (GLenum stream, GLdouble x, GLdouble y); -typedef void (APIENTRYP PFNGLVERTEXSTREAM2DVATIPROC) (GLenum stream, const GLdouble *coords); -typedef void (APIENTRYP PFNGLVERTEXSTREAM3SATIPROC) (GLenum stream, GLshort x, GLshort y, GLshort z); -typedef void (APIENTRYP PFNGLVERTEXSTREAM3SVATIPROC) (GLenum stream, const GLshort *coords); -typedef void (APIENTRYP PFNGLVERTEXSTREAM3IATIPROC) (GLenum stream, GLint x, GLint y, GLint z); -typedef void (APIENTRYP PFNGLVERTEXSTREAM3IVATIPROC) (GLenum stream, const GLint *coords); -typedef void (APIENTRYP PFNGLVERTEXSTREAM3FATIPROC) (GLenum stream, GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLVERTEXSTREAM3FVATIPROC) (GLenum stream, const GLfloat *coords); -typedef void (APIENTRYP PFNGLVERTEXSTREAM3DATIPROC) (GLenum stream, GLdouble x, GLdouble y, GLdouble z); -typedef void (APIENTRYP PFNGLVERTEXSTREAM3DVATIPROC) (GLenum stream, const GLdouble *coords); -typedef void (APIENTRYP PFNGLVERTEXSTREAM4SATIPROC) (GLenum stream, GLshort x, GLshort y, GLshort z, GLshort w); -typedef void (APIENTRYP PFNGLVERTEXSTREAM4SVATIPROC) (GLenum stream, const GLshort *coords); -typedef void (APIENTRYP PFNGLVERTEXSTREAM4IATIPROC) (GLenum stream, GLint x, GLint y, GLint z, GLint w); -typedef void (APIENTRYP PFNGLVERTEXSTREAM4IVATIPROC) (GLenum stream, const GLint *coords); -typedef void (APIENTRYP PFNGLVERTEXSTREAM4FATIPROC) (GLenum stream, GLfloat x, GLfloat y, GLfloat z, GLfloat w); -typedef void (APIENTRYP PFNGLVERTEXSTREAM4FVATIPROC) (GLenum stream, const GLfloat *coords); -typedef void (APIENTRYP PFNGLVERTEXSTREAM4DATIPROC) (GLenum stream, GLdouble x, GLdouble y, GLdouble z, GLdouble w); -typedef void (APIENTRYP PFNGLVERTEXSTREAM4DVATIPROC) (GLenum stream, const GLdouble *coords); -typedef void (APIENTRYP PFNGLNORMALSTREAM3BATIPROC) (GLenum stream, GLbyte nx, GLbyte ny, GLbyte nz); -typedef void (APIENTRYP PFNGLNORMALSTREAM3BVATIPROC) (GLenum stream, const GLbyte *coords); -typedef void (APIENTRYP PFNGLNORMALSTREAM3SATIPROC) (GLenum stream, GLshort nx, GLshort ny, GLshort nz); -typedef void (APIENTRYP PFNGLNORMALSTREAM3SVATIPROC) (GLenum stream, const GLshort *coords); -typedef void (APIENTRYP PFNGLNORMALSTREAM3IATIPROC) (GLenum stream, GLint nx, GLint ny, GLint nz); -typedef void (APIENTRYP PFNGLNORMALSTREAM3IVATIPROC) (GLenum stream, const GLint *coords); -typedef void (APIENTRYP PFNGLNORMALSTREAM3FATIPROC) (GLenum stream, GLfloat nx, GLfloat ny, GLfloat nz); -typedef void (APIENTRYP PFNGLNORMALSTREAM3FVATIPROC) (GLenum stream, const GLfloat *coords); -typedef void (APIENTRYP PFNGLNORMALSTREAM3DATIPROC) (GLenum stream, GLdouble nx, GLdouble ny, GLdouble nz); -typedef void (APIENTRYP PFNGLNORMALSTREAM3DVATIPROC) (GLenum stream, const GLdouble *coords); -typedef void (APIENTRYP PFNGLCLIENTACTIVEVERTEXSTREAMATIPROC) (GLenum stream); -typedef void (APIENTRYP PFNGLVERTEXBLENDENVIATIPROC) (GLenum pname, GLint param); -typedef void (APIENTRYP PFNGLVERTEXBLENDENVFATIPROC) (GLenum pname, GLfloat param); -#endif - -#ifndef GL_ATI_element_array -#define GL_ATI_element_array 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glElementPointerATI (GLenum, const GLvoid *); -GLAPI void APIENTRY glDrawElementArrayATI (GLenum, GLsizei); -GLAPI void APIENTRY glDrawRangeElementArrayATI (GLenum, GLuint, GLuint, GLsizei); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLELEMENTPOINTERATIPROC) (GLenum type, const GLvoid *pointer); -typedef void (APIENTRYP PFNGLDRAWELEMENTARRAYATIPROC) (GLenum mode, GLsizei count); -typedef void (APIENTRYP PFNGLDRAWRANGEELEMENTARRAYATIPROC) (GLenum mode, GLuint start, GLuint end, GLsizei count); -#endif - -#ifndef GL_SUN_mesh_array -#define GL_SUN_mesh_array 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glDrawMeshArraysSUN (GLenum, GLint, GLsizei, GLsizei); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLDRAWMESHARRAYSSUNPROC) (GLenum mode, GLint first, GLsizei count, GLsizei width); -#endif - -#ifndef GL_SUN_slice_accum -#define GL_SUN_slice_accum 1 -#endif - -#ifndef GL_NV_multisample_filter_hint -#define GL_NV_multisample_filter_hint 1 -#endif - -#ifndef GL_NV_depth_clamp -#define GL_NV_depth_clamp 1 -#endif - -#ifndef GL_NV_occlusion_query -#define GL_NV_occlusion_query 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glGenOcclusionQueriesNV (GLsizei, GLuint *); -GLAPI void APIENTRY glDeleteOcclusionQueriesNV (GLsizei, const GLuint *); -GLAPI GLboolean APIENTRY glIsOcclusionQueryNV (GLuint); -GLAPI void APIENTRY glBeginOcclusionQueryNV (GLuint); -GLAPI void APIENTRY glEndOcclusionQueryNV (void); -GLAPI void APIENTRY glGetOcclusionQueryivNV (GLuint, GLenum, GLint *); -GLAPI void APIENTRY glGetOcclusionQueryuivNV (GLuint, GLenum, GLuint *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLGENOCCLUSIONQUERIESNVPROC) (GLsizei n, GLuint *ids); -typedef void (APIENTRYP PFNGLDELETEOCCLUSIONQUERIESNVPROC) (GLsizei n, const GLuint *ids); -typedef GLboolean (APIENTRYP PFNGLISOCCLUSIONQUERYNVPROC) (GLuint id); -typedef void (APIENTRYP PFNGLBEGINOCCLUSIONQUERYNVPROC) (GLuint id); -typedef void (APIENTRYP PFNGLENDOCCLUSIONQUERYNVPROC) (void); -typedef void (APIENTRYP PFNGLGETOCCLUSIONQUERYIVNVPROC) (GLuint id, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETOCCLUSIONQUERYUIVNVPROC) (GLuint id, GLenum pname, GLuint *params); -#endif - -#ifndef GL_NV_point_sprite -#define GL_NV_point_sprite 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glPointParameteriNV (GLenum, GLint); -GLAPI void APIENTRY glPointParameterivNV (GLenum, const GLint *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLPOINTPARAMETERINVPROC) (GLenum pname, GLint param); -typedef void (APIENTRYP PFNGLPOINTPARAMETERIVNVPROC) (GLenum pname, const GLint *params); -#endif - -#ifndef GL_NV_texture_shader3 -#define GL_NV_texture_shader3 1 -#endif - -#ifndef GL_NV_vertex_program1_1 -#define GL_NV_vertex_program1_1 1 -#endif - -#ifndef GL_EXT_shadow_funcs -#define GL_EXT_shadow_funcs 1 -#endif - -#ifndef GL_EXT_stencil_two_side -#define GL_EXT_stencil_two_side 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glActiveStencilFaceEXT (GLenum); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLACTIVESTENCILFACEEXTPROC) (GLenum face); -#endif - -#ifndef GL_ATI_text_fragment_shader -#define GL_ATI_text_fragment_shader 1 -#endif - -#ifndef GL_APPLE_client_storage -#define GL_APPLE_client_storage 1 -#endif - -#ifndef GL_APPLE_element_array -#define GL_APPLE_element_array 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glElementPointerAPPLE (GLenum, const GLvoid *); -GLAPI void APIENTRY glDrawElementArrayAPPLE (GLenum, GLint, GLsizei); -GLAPI void APIENTRY glDrawRangeElementArrayAPPLE (GLenum, GLuint, GLuint, GLint, GLsizei); -GLAPI void APIENTRY glMultiDrawElementArrayAPPLE (GLenum, const GLint *, const GLsizei *, GLsizei); -GLAPI void APIENTRY glMultiDrawRangeElementArrayAPPLE (GLenum, GLuint, GLuint, const GLint *, const GLsizei *, GLsizei); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLELEMENTPOINTERAPPLEPROC) (GLenum type, const GLvoid *pointer); -typedef void (APIENTRYP PFNGLDRAWELEMENTARRAYAPPLEPROC) (GLenum mode, GLint first, GLsizei count); -typedef void (APIENTRYP PFNGLDRAWRANGEELEMENTARRAYAPPLEPROC) (GLenum mode, GLuint start, GLuint end, GLint first, GLsizei count); -typedef void (APIENTRYP PFNGLMULTIDRAWELEMENTARRAYAPPLEPROC) (GLenum mode, const GLint *first, const GLsizei *count, GLsizei primcount); -typedef void (APIENTRYP PFNGLMULTIDRAWRANGEELEMENTARRAYAPPLEPROC) (GLenum mode, GLuint start, GLuint end, const GLint *first, const GLsizei *count, GLsizei primcount); -#endif - -#ifndef GL_APPLE_fence -#define GL_APPLE_fence 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glGenFencesAPPLE (GLsizei, GLuint *); -GLAPI void APIENTRY glDeleteFencesAPPLE (GLsizei, const GLuint *); -GLAPI void APIENTRY glSetFenceAPPLE (GLuint); -GLAPI GLboolean APIENTRY glIsFenceAPPLE (GLuint); -GLAPI GLboolean APIENTRY glTestFenceAPPLE (GLuint); -GLAPI void APIENTRY glFinishFenceAPPLE (GLuint); -GLAPI GLboolean APIENTRY glTestObjectAPPLE (GLenum, GLuint); -GLAPI void APIENTRY glFinishObjectAPPLE (GLenum, GLint); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLGENFENCESAPPLEPROC) (GLsizei n, GLuint *fences); -typedef void (APIENTRYP PFNGLDELETEFENCESAPPLEPROC) (GLsizei n, const GLuint *fences); -typedef void (APIENTRYP PFNGLSETFENCEAPPLEPROC) (GLuint fence); -typedef GLboolean (APIENTRYP PFNGLISFENCEAPPLEPROC) (GLuint fence); -typedef GLboolean (APIENTRYP PFNGLTESTFENCEAPPLEPROC) (GLuint fence); -typedef void (APIENTRYP PFNGLFINISHFENCEAPPLEPROC) (GLuint fence); -typedef GLboolean (APIENTRYP PFNGLTESTOBJECTAPPLEPROC) (GLenum object, GLuint name); -typedef void (APIENTRYP PFNGLFINISHOBJECTAPPLEPROC) (GLenum object, GLint name); -#endif - -#ifndef GL_APPLE_vertex_array_object -#define GL_APPLE_vertex_array_object 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glBindVertexArrayAPPLE (GLuint); -GLAPI void APIENTRY glDeleteVertexArraysAPPLE (GLsizei, const GLuint *); -GLAPI void APIENTRY glGenVertexArraysAPPLE (GLsizei, GLuint *); -GLAPI GLboolean APIENTRY glIsVertexArrayAPPLE (GLuint); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLBINDVERTEXARRAYAPPLEPROC) (GLuint array); -typedef void (APIENTRYP PFNGLDELETEVERTEXARRAYSAPPLEPROC) (GLsizei n, const GLuint *arrays); -typedef void (APIENTRYP PFNGLGENVERTEXARRAYSAPPLEPROC) (GLsizei n, GLuint *arrays); -typedef GLboolean (APIENTRYP PFNGLISVERTEXARRAYAPPLEPROC) (GLuint array); -#endif - -#ifndef GL_APPLE_vertex_array_range -#define GL_APPLE_vertex_array_range 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glVertexArrayRangeAPPLE (GLsizei, GLvoid *); -GLAPI void APIENTRY glFlushVertexArrayRangeAPPLE (GLsizei, GLvoid *); -GLAPI void APIENTRY glVertexArrayParameteriAPPLE (GLenum, GLint); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLVERTEXARRAYRANGEAPPLEPROC) (GLsizei length, GLvoid *pointer); -typedef void (APIENTRYP PFNGLFLUSHVERTEXARRAYRANGEAPPLEPROC) (GLsizei length, GLvoid *pointer); -typedef void (APIENTRYP PFNGLVERTEXARRAYPARAMETERIAPPLEPROC) (GLenum pname, GLint param); -#endif - -#ifndef GL_APPLE_ycbcr_422 -#define GL_APPLE_ycbcr_422 1 -#endif - -#ifndef GL_S3_s3tc -#define GL_S3_s3tc 1 -#endif - -#ifndef GL_ATI_draw_buffers -#define GL_ATI_draw_buffers 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glDrawBuffersATI (GLsizei, const GLenum *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLDRAWBUFFERSATIPROC) (GLsizei n, const GLenum *bufs); -#endif - -#ifndef GL_ATI_pixel_format_float -#define GL_ATI_pixel_format_float 1 -/* This is really a WGL extension, but defines some associated GL enums. - * ATI does not export "GL_ATI_pixel_format_float" in the GL_EXTENSIONS string. - */ -#endif - -#ifndef GL_ATI_texture_env_combine3 -#define GL_ATI_texture_env_combine3 1 -#endif - -#ifndef GL_ATI_texture_float -#define GL_ATI_texture_float 1 -#endif - -#ifndef GL_NV_float_buffer -#define GL_NV_float_buffer 1 -#endif - -#ifndef GL_NV_fragment_program -#define GL_NV_fragment_program 1 -/* Some NV_fragment_program entry points are shared with ARB_vertex_program. */ -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glProgramNamedParameter4fNV (GLuint, GLsizei, const GLubyte *, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glProgramNamedParameter4dNV (GLuint, GLsizei, const GLubyte *, GLdouble, GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glProgramNamedParameter4fvNV (GLuint, GLsizei, const GLubyte *, const GLfloat *); -GLAPI void APIENTRY glProgramNamedParameter4dvNV (GLuint, GLsizei, const GLubyte *, const GLdouble *); -GLAPI void APIENTRY glGetProgramNamedParameterfvNV (GLuint, GLsizei, const GLubyte *, GLfloat *); -GLAPI void APIENTRY glGetProgramNamedParameterdvNV (GLuint, GLsizei, const GLubyte *, GLdouble *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLPROGRAMNAMEDPARAMETER4FNVPROC) (GLuint id, GLsizei len, const GLubyte *name, GLfloat x, GLfloat y, GLfloat z, GLfloat w); -typedef void (APIENTRYP PFNGLPROGRAMNAMEDPARAMETER4DNVPROC) (GLuint id, GLsizei len, const GLubyte *name, GLdouble x, GLdouble y, GLdouble z, GLdouble w); -typedef void (APIENTRYP PFNGLPROGRAMNAMEDPARAMETER4FVNVPROC) (GLuint id, GLsizei len, const GLubyte *name, const GLfloat *v); -typedef void (APIENTRYP PFNGLPROGRAMNAMEDPARAMETER4DVNVPROC) (GLuint id, GLsizei len, const GLubyte *name, const GLdouble *v); -typedef void (APIENTRYP PFNGLGETPROGRAMNAMEDPARAMETERFVNVPROC) (GLuint id, GLsizei len, const GLubyte *name, GLfloat *params); -typedef void (APIENTRYP PFNGLGETPROGRAMNAMEDPARAMETERDVNVPROC) (GLuint id, GLsizei len, const GLubyte *name, GLdouble *params); -#endif - -#ifndef GL_NV_half_float -#define GL_NV_half_float 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glVertex2hNV (GLhalfNV, GLhalfNV); -GLAPI void APIENTRY glVertex2hvNV (const GLhalfNV *); -GLAPI void APIENTRY glVertex3hNV (GLhalfNV, GLhalfNV, GLhalfNV); -GLAPI void APIENTRY glVertex3hvNV (const GLhalfNV *); -GLAPI void APIENTRY glVertex4hNV (GLhalfNV, GLhalfNV, GLhalfNV, GLhalfNV); -GLAPI void APIENTRY glVertex4hvNV (const GLhalfNV *); -GLAPI void APIENTRY glNormal3hNV (GLhalfNV, GLhalfNV, GLhalfNV); -GLAPI void APIENTRY glNormal3hvNV (const GLhalfNV *); -GLAPI void APIENTRY glColor3hNV (GLhalfNV, GLhalfNV, GLhalfNV); -GLAPI void APIENTRY glColor3hvNV (const GLhalfNV *); -GLAPI void APIENTRY glColor4hNV (GLhalfNV, GLhalfNV, GLhalfNV, GLhalfNV); -GLAPI void APIENTRY glColor4hvNV (const GLhalfNV *); -GLAPI void APIENTRY glTexCoord1hNV (GLhalfNV); -GLAPI void APIENTRY glTexCoord1hvNV (const GLhalfNV *); -GLAPI void APIENTRY glTexCoord2hNV (GLhalfNV, GLhalfNV); -GLAPI void APIENTRY glTexCoord2hvNV (const GLhalfNV *); -GLAPI void APIENTRY glTexCoord3hNV (GLhalfNV, GLhalfNV, GLhalfNV); -GLAPI void APIENTRY glTexCoord3hvNV (const GLhalfNV *); -GLAPI void APIENTRY glTexCoord4hNV (GLhalfNV, GLhalfNV, GLhalfNV, GLhalfNV); -GLAPI void APIENTRY glTexCoord4hvNV (const GLhalfNV *); -GLAPI void APIENTRY glMultiTexCoord1hNV (GLenum, GLhalfNV); -GLAPI void APIENTRY glMultiTexCoord1hvNV (GLenum, const GLhalfNV *); -GLAPI void APIENTRY glMultiTexCoord2hNV (GLenum, GLhalfNV, GLhalfNV); -GLAPI void APIENTRY glMultiTexCoord2hvNV (GLenum, const GLhalfNV *); -GLAPI void APIENTRY glMultiTexCoord3hNV (GLenum, GLhalfNV, GLhalfNV, GLhalfNV); -GLAPI void APIENTRY glMultiTexCoord3hvNV (GLenum, const GLhalfNV *); -GLAPI void APIENTRY glMultiTexCoord4hNV (GLenum, GLhalfNV, GLhalfNV, GLhalfNV, GLhalfNV); -GLAPI void APIENTRY glMultiTexCoord4hvNV (GLenum, const GLhalfNV *); -GLAPI void APIENTRY glFogCoordhNV (GLhalfNV); -GLAPI void APIENTRY glFogCoordhvNV (const GLhalfNV *); -GLAPI void APIENTRY glSecondaryColor3hNV (GLhalfNV, GLhalfNV, GLhalfNV); -GLAPI void APIENTRY glSecondaryColor3hvNV (const GLhalfNV *); -GLAPI void APIENTRY glVertexWeighthNV (GLhalfNV); -GLAPI void APIENTRY glVertexWeighthvNV (const GLhalfNV *); -GLAPI void APIENTRY glVertexAttrib1hNV (GLuint, GLhalfNV); -GLAPI void APIENTRY glVertexAttrib1hvNV (GLuint, const GLhalfNV *); -GLAPI void APIENTRY glVertexAttrib2hNV (GLuint, GLhalfNV, GLhalfNV); -GLAPI void APIENTRY glVertexAttrib2hvNV (GLuint, const GLhalfNV *); -GLAPI void APIENTRY glVertexAttrib3hNV (GLuint, GLhalfNV, GLhalfNV, GLhalfNV); -GLAPI void APIENTRY glVertexAttrib3hvNV (GLuint, const GLhalfNV *); -GLAPI void APIENTRY glVertexAttrib4hNV (GLuint, GLhalfNV, GLhalfNV, GLhalfNV, GLhalfNV); -GLAPI void APIENTRY glVertexAttrib4hvNV (GLuint, const GLhalfNV *); -GLAPI void APIENTRY glVertexAttribs1hvNV (GLuint, GLsizei, const GLhalfNV *); -GLAPI void APIENTRY glVertexAttribs2hvNV (GLuint, GLsizei, const GLhalfNV *); -GLAPI void APIENTRY glVertexAttribs3hvNV (GLuint, GLsizei, const GLhalfNV *); -GLAPI void APIENTRY glVertexAttribs4hvNV (GLuint, GLsizei, const GLhalfNV *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLVERTEX2HNVPROC) (GLhalfNV x, GLhalfNV y); -typedef void (APIENTRYP PFNGLVERTEX2HVNVPROC) (const GLhalfNV *v); -typedef void (APIENTRYP PFNGLVERTEX3HNVPROC) (GLhalfNV x, GLhalfNV y, GLhalfNV z); -typedef void (APIENTRYP PFNGLVERTEX3HVNVPROC) (const GLhalfNV *v); -typedef void (APIENTRYP PFNGLVERTEX4HNVPROC) (GLhalfNV x, GLhalfNV y, GLhalfNV z, GLhalfNV w); -typedef void (APIENTRYP PFNGLVERTEX4HVNVPROC) (const GLhalfNV *v); -typedef void (APIENTRYP PFNGLNORMAL3HNVPROC) (GLhalfNV nx, GLhalfNV ny, GLhalfNV nz); -typedef void (APIENTRYP PFNGLNORMAL3HVNVPROC) (const GLhalfNV *v); -typedef void (APIENTRYP PFNGLCOLOR3HNVPROC) (GLhalfNV red, GLhalfNV green, GLhalfNV blue); -typedef void (APIENTRYP PFNGLCOLOR3HVNVPROC) (const GLhalfNV *v); -typedef void (APIENTRYP PFNGLCOLOR4HNVPROC) (GLhalfNV red, GLhalfNV green, GLhalfNV blue, GLhalfNV alpha); -typedef void (APIENTRYP PFNGLCOLOR4HVNVPROC) (const GLhalfNV *v); -typedef void (APIENTRYP PFNGLTEXCOORD1HNVPROC) (GLhalfNV s); -typedef void (APIENTRYP PFNGLTEXCOORD1HVNVPROC) (const GLhalfNV *v); -typedef void (APIENTRYP PFNGLTEXCOORD2HNVPROC) (GLhalfNV s, GLhalfNV t); -typedef void (APIENTRYP PFNGLTEXCOORD2HVNVPROC) (const GLhalfNV *v); -typedef void (APIENTRYP PFNGLTEXCOORD3HNVPROC) (GLhalfNV s, GLhalfNV t, GLhalfNV r); -typedef void (APIENTRYP PFNGLTEXCOORD3HVNVPROC) (const GLhalfNV *v); -typedef void (APIENTRYP PFNGLTEXCOORD4HNVPROC) (GLhalfNV s, GLhalfNV t, GLhalfNV r, GLhalfNV q); -typedef void (APIENTRYP PFNGLTEXCOORD4HVNVPROC) (const GLhalfNV *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD1HNVPROC) (GLenum target, GLhalfNV s); -typedef void (APIENTRYP PFNGLMULTITEXCOORD1HVNVPROC) (GLenum target, const GLhalfNV *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD2HNVPROC) (GLenum target, GLhalfNV s, GLhalfNV t); -typedef void (APIENTRYP PFNGLMULTITEXCOORD2HVNVPROC) (GLenum target, const GLhalfNV *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD3HNVPROC) (GLenum target, GLhalfNV s, GLhalfNV t, GLhalfNV r); -typedef void (APIENTRYP PFNGLMULTITEXCOORD3HVNVPROC) (GLenum target, const GLhalfNV *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD4HNVPROC) (GLenum target, GLhalfNV s, GLhalfNV t, GLhalfNV r, GLhalfNV q); -typedef void (APIENTRYP PFNGLMULTITEXCOORD4HVNVPROC) (GLenum target, const GLhalfNV *v); -typedef void (APIENTRYP PFNGLFOGCOORDHNVPROC) (GLhalfNV fog); -typedef void (APIENTRYP PFNGLFOGCOORDHVNVPROC) (const GLhalfNV *fog); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3HNVPROC) (GLhalfNV red, GLhalfNV green, GLhalfNV blue); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3HVNVPROC) (const GLhalfNV *v); -typedef void (APIENTRYP PFNGLVERTEXWEIGHTHNVPROC) (GLhalfNV weight); -typedef void (APIENTRYP PFNGLVERTEXWEIGHTHVNVPROC) (const GLhalfNV *weight); -typedef void (APIENTRYP PFNGLVERTEXATTRIB1HNVPROC) (GLuint index, GLhalfNV x); -typedef void (APIENTRYP PFNGLVERTEXATTRIB1HVNVPROC) (GLuint index, const GLhalfNV *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB2HNVPROC) (GLuint index, GLhalfNV x, GLhalfNV y); -typedef void (APIENTRYP PFNGLVERTEXATTRIB2HVNVPROC) (GLuint index, const GLhalfNV *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB3HNVPROC) (GLuint index, GLhalfNV x, GLhalfNV y, GLhalfNV z); -typedef void (APIENTRYP PFNGLVERTEXATTRIB3HVNVPROC) (GLuint index, const GLhalfNV *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4HNVPROC) (GLuint index, GLhalfNV x, GLhalfNV y, GLhalfNV z, GLhalfNV w); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4HVNVPROC) (GLuint index, const GLhalfNV *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBS1HVNVPROC) (GLuint index, GLsizei n, const GLhalfNV *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBS2HVNVPROC) (GLuint index, GLsizei n, const GLhalfNV *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBS3HVNVPROC) (GLuint index, GLsizei n, const GLhalfNV *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBS4HVNVPROC) (GLuint index, GLsizei n, const GLhalfNV *v); -#endif - -#ifndef GL_NV_pixel_data_range -#define GL_NV_pixel_data_range 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glPixelDataRangeNV (GLenum, GLsizei, GLvoid *); -GLAPI void APIENTRY glFlushPixelDataRangeNV (GLenum); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLPIXELDATARANGENVPROC) (GLenum target, GLsizei length, GLvoid *pointer); -typedef void (APIENTRYP PFNGLFLUSHPIXELDATARANGENVPROC) (GLenum target); -#endif - -#ifndef GL_NV_primitive_restart -#define GL_NV_primitive_restart 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glPrimitiveRestartNV (void); -GLAPI void APIENTRY glPrimitiveRestartIndexNV (GLuint); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLPRIMITIVERESTARTNVPROC) (void); -typedef void (APIENTRYP PFNGLPRIMITIVERESTARTINDEXNVPROC) (GLuint index); -#endif - -#ifndef GL_NV_texture_expand_normal -#define GL_NV_texture_expand_normal 1 -#endif - -#ifndef GL_NV_vertex_program2 -#define GL_NV_vertex_program2 1 -#endif - -#ifndef GL_ATI_map_object_buffer -#define GL_ATI_map_object_buffer 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI GLvoid* APIENTRY glMapObjectBufferATI (GLuint); -GLAPI void APIENTRY glUnmapObjectBufferATI (GLuint); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef GLvoid* (APIENTRYP PFNGLMAPOBJECTBUFFERATIPROC) (GLuint buffer); -typedef void (APIENTRYP PFNGLUNMAPOBJECTBUFFERATIPROC) (GLuint buffer); -#endif - -#ifndef GL_ATI_separate_stencil -#define GL_ATI_separate_stencil 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glStencilOpSeparateATI (GLenum, GLenum, GLenum, GLenum); -GLAPI void APIENTRY glStencilFuncSeparateATI (GLenum, GLenum, GLint, GLuint); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLSTENCILOPSEPARATEATIPROC) (GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass); -typedef void (APIENTRYP PFNGLSTENCILFUNCSEPARATEATIPROC) (GLenum frontfunc, GLenum backfunc, GLint ref, GLuint mask); -#endif - -#ifndef GL_ATI_vertex_attrib_array_object -#define GL_ATI_vertex_attrib_array_object 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glVertexAttribArrayObjectATI (GLuint, GLint, GLenum, GLboolean, GLsizei, GLuint, GLuint); -GLAPI void APIENTRY glGetVertexAttribArrayObjectfvATI (GLuint, GLenum, GLfloat *); -GLAPI void APIENTRY glGetVertexAttribArrayObjectivATI (GLuint, GLenum, GLint *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLVERTEXATTRIBARRAYOBJECTATIPROC) (GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, GLuint buffer, GLuint offset); -typedef void (APIENTRYP PFNGLGETVERTEXATTRIBARRAYOBJECTFVATIPROC) (GLuint index, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETVERTEXATTRIBARRAYOBJECTIVATIPROC) (GLuint index, GLenum pname, GLint *params); -#endif - -#ifndef GL_OES_read_format -#define GL_OES_read_format 1 -#endif - -#ifndef GL_EXT_depth_bounds_test -#define GL_EXT_depth_bounds_test 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glDepthBoundsEXT (GLclampd, GLclampd); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLDEPTHBOUNDSEXTPROC) (GLclampd zmin, GLclampd zmax); -#endif - -#ifndef GL_EXT_texture_mirror_clamp -#define GL_EXT_texture_mirror_clamp 1 -#endif - -#ifndef GL_EXT_blend_equation_separate -#define GL_EXT_blend_equation_separate 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glBlendEquationSeparateEXT (GLenum, GLenum); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLBLENDEQUATIONSEPARATEEXTPROC) (GLenum modeRGB, GLenum modeAlpha); -#endif - -#ifndef GL_MESA_pack_invert -#define GL_MESA_pack_invert 1 -#endif - -#ifndef GL_MESA_ycbcr_texture -#define GL_MESA_ycbcr_texture 1 -#endif - -#ifndef GL_EXT_pixel_buffer_object -#define GL_EXT_pixel_buffer_object 1 -#endif - -#ifndef GL_NV_fragment_program_option -#define GL_NV_fragment_program_option 1 -#endif - -#ifndef GL_NV_fragment_program2 -#define GL_NV_fragment_program2 1 -#endif - -#ifndef GL_NV_vertex_program2_option -#define GL_NV_vertex_program2_option 1 -#endif - -#ifndef GL_NV_vertex_program3 -#define GL_NV_vertex_program3 1 -#endif - -#ifndef GL_EXT_framebuffer_object -#define GL_EXT_framebuffer_object 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI GLboolean APIENTRY glIsRenderbufferEXT (GLuint); -GLAPI void APIENTRY glBindRenderbufferEXT (GLenum, GLuint); -GLAPI void APIENTRY glDeleteRenderbuffersEXT (GLsizei, const GLuint *); -GLAPI void APIENTRY glGenRenderbuffersEXT (GLsizei, GLuint *); -GLAPI void APIENTRY glRenderbufferStorageEXT (GLenum, GLenum, GLsizei, GLsizei); -GLAPI void APIENTRY glGetRenderbufferParameterivEXT (GLenum, GLenum, GLint *); -GLAPI GLboolean APIENTRY glIsFramebufferEXT (GLuint); -GLAPI void APIENTRY glBindFramebufferEXT (GLenum, GLuint); -GLAPI void APIENTRY glDeleteFramebuffersEXT (GLsizei, const GLuint *); -GLAPI void APIENTRY glGenFramebuffersEXT (GLsizei, GLuint *); -GLAPI GLenum APIENTRY glCheckFramebufferStatusEXT (GLenum); -GLAPI void APIENTRY glFramebufferTexture1DEXT (GLenum, GLenum, GLenum, GLuint, GLint); -GLAPI void APIENTRY glFramebufferTexture2DEXT (GLenum, GLenum, GLenum, GLuint, GLint); -GLAPI void APIENTRY glFramebufferTexture3DEXT (GLenum, GLenum, GLenum, GLuint, GLint, GLint); -GLAPI void APIENTRY glFramebufferRenderbufferEXT (GLenum, GLenum, GLenum, GLuint); -GLAPI void APIENTRY glGetFramebufferAttachmentParameterivEXT (GLenum, GLenum, GLenum, GLint *); -GLAPI void APIENTRY glGenerateMipmapEXT (GLenum); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef GLboolean (APIENTRYP PFNGLISRENDERBUFFEREXTPROC) (GLuint renderbuffer); -typedef void (APIENTRYP PFNGLBINDRENDERBUFFEREXTPROC) (GLenum target, GLuint renderbuffer); -typedef void (APIENTRYP PFNGLDELETERENDERBUFFERSEXTPROC) (GLsizei n, const GLuint *renderbuffers); -typedef void (APIENTRYP PFNGLGENRENDERBUFFERSEXTPROC) (GLsizei n, GLuint *renderbuffers); -typedef void (APIENTRYP PFNGLRENDERBUFFERSTORAGEEXTPROC) (GLenum target, GLenum internalformat, GLsizei width, GLsizei height); -typedef void (APIENTRYP PFNGLGETRENDERBUFFERPARAMETERIVEXTPROC) (GLenum target, GLenum pname, GLint *params); -typedef GLboolean (APIENTRYP PFNGLISFRAMEBUFFEREXTPROC) (GLuint framebuffer); -typedef void (APIENTRYP PFNGLBINDFRAMEBUFFEREXTPROC) (GLenum target, GLuint framebuffer); -typedef void (APIENTRYP PFNGLDELETEFRAMEBUFFERSEXTPROC) (GLsizei n, const GLuint *framebuffers); -typedef void (APIENTRYP PFNGLGENFRAMEBUFFERSEXTPROC) (GLsizei n, GLuint *framebuffers); -typedef GLenum (APIENTRYP PFNGLCHECKFRAMEBUFFERSTATUSEXTPROC) (GLenum target); -typedef void (APIENTRYP PFNGLFRAMEBUFFERTEXTURE1DEXTPROC) (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level); -typedef void (APIENTRYP PFNGLFRAMEBUFFERTEXTURE2DEXTPROC) (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level); -typedef void (APIENTRYP PFNGLFRAMEBUFFERTEXTURE3DEXTPROC) (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset); -typedef void (APIENTRYP PFNGLFRAMEBUFFERRENDERBUFFEREXTPROC) (GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer); -typedef void (APIENTRYP PFNGLGETFRAMEBUFFERATTACHMENTPARAMETERIVEXTPROC) (GLenum target, GLenum attachment, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGENERATEMIPMAPEXTPROC) (GLenum target); -#endif - -#ifndef GL_GREMEDY_string_marker -#define GL_GREMEDY_string_marker 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glStringMarkerGREMEDY (GLsizei, const GLvoid *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLSTRINGMARKERGREMEDYPROC) (GLsizei len, const GLvoid *string); -#endif - -#ifndef GL_EXT_packed_depth_stencil -#define GL_EXT_packed_depth_stencil 1 -#endif - -#ifndef GL_EXT_stencil_clear_tag -#define GL_EXT_stencil_clear_tag 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glStencilClearTagEXT (GLsizei, GLuint); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLSTENCILCLEARTAGEXTPROC) (GLsizei stencilTagBits, GLuint stencilClearTag); -#endif - -#ifndef GL_EXT_texture_sRGB -#define GL_EXT_texture_sRGB 1 -#endif - -#ifndef GL_EXT_framebuffer_blit -#define GL_EXT_framebuffer_blit 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glBlitFramebufferEXT (GLint, GLint, GLint, GLint, GLint, GLint, GLint, GLint, GLbitfield, GLenum); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLBLITFRAMEBUFFEREXTPROC) (GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter); -#endif - -#ifndef GL_EXT_framebuffer_multisample -#define GL_EXT_framebuffer_multisample 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glRenderbufferStorageMultisampleEXT (GLenum, GLsizei, GLenum, GLsizei, GLsizei); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLRENDERBUFFERSTORAGEMULTISAMPLEEXTPROC) (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height); -#endif - -#ifndef GL_MESAX_texture_stack -#define GL_MESAX_texture_stack 1 -#endif - -#ifndef GL_EXT_timer_query -#define GL_EXT_timer_query 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glGetQueryObjecti64vEXT (GLuint, GLenum, GLint64EXT *); -GLAPI void APIENTRY glGetQueryObjectui64vEXT (GLuint, GLenum, GLuint64EXT *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLGETQUERYOBJECTI64VEXTPROC) (GLuint id, GLenum pname, GLint64EXT *params); -typedef void (APIENTRYP PFNGLGETQUERYOBJECTUI64VEXTPROC) (GLuint id, GLenum pname, GLuint64EXT *params); -#endif - -#ifndef GL_EXT_gpu_program_parameters -#define GL_EXT_gpu_program_parameters 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glProgramEnvParameters4fvEXT (GLenum, GLuint, GLsizei, const GLfloat *); -GLAPI void APIENTRY glProgramLocalParameters4fvEXT (GLenum, GLuint, GLsizei, const GLfloat *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLPROGRAMENVPARAMETERS4FVEXTPROC) (GLenum target, GLuint index, GLsizei count, const GLfloat *params); -typedef void (APIENTRYP PFNGLPROGRAMLOCALPARAMETERS4FVEXTPROC) (GLenum target, GLuint index, GLsizei count, const GLfloat *params); -#endif - -#ifndef GL_APPLE_flush_buffer_range -#define GL_APPLE_flush_buffer_range 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glBufferParameteriAPPLE (GLenum, GLenum, GLint); -GLAPI void APIENTRY glFlushMappedBufferRangeAPPLE (GLenum, GLintptr, GLsizeiptr); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLBUFFERPARAMETERIAPPLEPROC) (GLenum target, GLenum pname, GLint param); -typedef void (APIENTRYP PFNGLFLUSHMAPPEDBUFFERRANGEAPPLEPROC) (GLenum target, GLintptr offset, GLsizeiptr size); -#endif - -#ifndef GL_NV_gpu_program4 -#define GL_NV_gpu_program4 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glProgramLocalParameterI4iNV (GLenum, GLuint, GLint, GLint, GLint, GLint); -GLAPI void APIENTRY glProgramLocalParameterI4ivNV (GLenum, GLuint, const GLint *); -GLAPI void APIENTRY glProgramLocalParametersI4ivNV (GLenum, GLuint, GLsizei, const GLint *); -GLAPI void APIENTRY glProgramLocalParameterI4uiNV (GLenum, GLuint, GLuint, GLuint, GLuint, GLuint); -GLAPI void APIENTRY glProgramLocalParameterI4uivNV (GLenum, GLuint, const GLuint *); -GLAPI void APIENTRY glProgramLocalParametersI4uivNV (GLenum, GLuint, GLsizei, const GLuint *); -GLAPI void APIENTRY glProgramEnvParameterI4iNV (GLenum, GLuint, GLint, GLint, GLint, GLint); -GLAPI void APIENTRY glProgramEnvParameterI4ivNV (GLenum, GLuint, const GLint *); -GLAPI void APIENTRY glProgramEnvParametersI4ivNV (GLenum, GLuint, GLsizei, const GLint *); -GLAPI void APIENTRY glProgramEnvParameterI4uiNV (GLenum, GLuint, GLuint, GLuint, GLuint, GLuint); -GLAPI void APIENTRY glProgramEnvParameterI4uivNV (GLenum, GLuint, const GLuint *); -GLAPI void APIENTRY glProgramEnvParametersI4uivNV (GLenum, GLuint, GLsizei, const GLuint *); -GLAPI void APIENTRY glGetProgramLocalParameterIivNV (GLenum, GLuint, GLint *); -GLAPI void APIENTRY glGetProgramLocalParameterIuivNV (GLenum, GLuint, GLuint *); -GLAPI void APIENTRY glGetProgramEnvParameterIivNV (GLenum, GLuint, GLint *); -GLAPI void APIENTRY glGetProgramEnvParameterIuivNV (GLenum, GLuint, GLuint *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLPROGRAMLOCALPARAMETERI4INVPROC) (GLenum target, GLuint index, GLint x, GLint y, GLint z, GLint w); -typedef void (APIENTRYP PFNGLPROGRAMLOCALPARAMETERI4IVNVPROC) (GLenum target, GLuint index, const GLint *params); -typedef void (APIENTRYP PFNGLPROGRAMLOCALPARAMETERSI4IVNVPROC) (GLenum target, GLuint index, GLsizei count, const GLint *params); -typedef void (APIENTRYP PFNGLPROGRAMLOCALPARAMETERI4UINVPROC) (GLenum target, GLuint index, GLuint x, GLuint y, GLuint z, GLuint w); -typedef void (APIENTRYP PFNGLPROGRAMLOCALPARAMETERI4UIVNVPROC) (GLenum target, GLuint index, const GLuint *params); -typedef void (APIENTRYP PFNGLPROGRAMLOCALPARAMETERSI4UIVNVPROC) (GLenum target, GLuint index, GLsizei count, const GLuint *params); -typedef void (APIENTRYP PFNGLPROGRAMENVPARAMETERI4INVPROC) (GLenum target, GLuint index, GLint x, GLint y, GLint z, GLint w); -typedef void (APIENTRYP PFNGLPROGRAMENVPARAMETERI4IVNVPROC) (GLenum target, GLuint index, const GLint *params); -typedef void (APIENTRYP PFNGLPROGRAMENVPARAMETERSI4IVNVPROC) (GLenum target, GLuint index, GLsizei count, const GLint *params); -typedef void (APIENTRYP PFNGLPROGRAMENVPARAMETERI4UINVPROC) (GLenum target, GLuint index, GLuint x, GLuint y, GLuint z, GLuint w); -typedef void (APIENTRYP PFNGLPROGRAMENVPARAMETERI4UIVNVPROC) (GLenum target, GLuint index, const GLuint *params); -typedef void (APIENTRYP PFNGLPROGRAMENVPARAMETERSI4UIVNVPROC) (GLenum target, GLuint index, GLsizei count, const GLuint *params); -typedef void (APIENTRYP PFNGLGETPROGRAMLOCALPARAMETERIIVNVPROC) (GLenum target, GLuint index, GLint *params); -typedef void (APIENTRYP PFNGLGETPROGRAMLOCALPARAMETERIUIVNVPROC) (GLenum target, GLuint index, GLuint *params); -typedef void (APIENTRYP PFNGLGETPROGRAMENVPARAMETERIIVNVPROC) (GLenum target, GLuint index, GLint *params); -typedef void (APIENTRYP PFNGLGETPROGRAMENVPARAMETERIUIVNVPROC) (GLenum target, GLuint index, GLuint *params); -#endif - -#ifndef GL_NV_geometry_program4 -#define GL_NV_geometry_program4 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glProgramVertexLimitNV (GLenum, GLint); -GLAPI void APIENTRY glFramebufferTextureEXT (GLenum, GLenum, GLuint, GLint); -GLAPI void APIENTRY glFramebufferTextureLayerEXT (GLenum, GLenum, GLuint, GLint, GLint); -GLAPI void APIENTRY glFramebufferTextureFaceEXT (GLenum, GLenum, GLuint, GLint, GLenum); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLPROGRAMVERTEXLIMITNVPROC) (GLenum target, GLint limit); -typedef void (APIENTRYP PFNGLFRAMEBUFFERTEXTUREEXTPROC) (GLenum target, GLenum attachment, GLuint texture, GLint level); -typedef void (APIENTRYP PFNGLFRAMEBUFFERTEXTURELAYEREXTPROC) (GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer); -typedef void (APIENTRYP PFNGLFRAMEBUFFERTEXTUREFACEEXTPROC) (GLenum target, GLenum attachment, GLuint texture, GLint level, GLenum face); -#endif - -#ifndef GL_EXT_geometry_shader4 -#define GL_EXT_geometry_shader4 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glProgramParameteriEXT (GLuint, GLenum, GLint); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLPROGRAMPARAMETERIEXTPROC) (GLuint program, GLenum pname, GLint value); -#endif - -#ifndef GL_NV_vertex_program4 -#define GL_NV_vertex_program4 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glVertexAttribI1iEXT (GLuint, GLint); -GLAPI void APIENTRY glVertexAttribI2iEXT (GLuint, GLint, GLint); -GLAPI void APIENTRY glVertexAttribI3iEXT (GLuint, GLint, GLint, GLint); -GLAPI void APIENTRY glVertexAttribI4iEXT (GLuint, GLint, GLint, GLint, GLint); -GLAPI void APIENTRY glVertexAttribI1uiEXT (GLuint, GLuint); -GLAPI void APIENTRY glVertexAttribI2uiEXT (GLuint, GLuint, GLuint); -GLAPI void APIENTRY glVertexAttribI3uiEXT (GLuint, GLuint, GLuint, GLuint); -GLAPI void APIENTRY glVertexAttribI4uiEXT (GLuint, GLuint, GLuint, GLuint, GLuint); -GLAPI void APIENTRY glVertexAttribI1ivEXT (GLuint, const GLint *); -GLAPI void APIENTRY glVertexAttribI2ivEXT (GLuint, const GLint *); -GLAPI void APIENTRY glVertexAttribI3ivEXT (GLuint, const GLint *); -GLAPI void APIENTRY glVertexAttribI4ivEXT (GLuint, const GLint *); -GLAPI void APIENTRY glVertexAttribI1uivEXT (GLuint, const GLuint *); -GLAPI void APIENTRY glVertexAttribI2uivEXT (GLuint, const GLuint *); -GLAPI void APIENTRY glVertexAttribI3uivEXT (GLuint, const GLuint *); -GLAPI void APIENTRY glVertexAttribI4uivEXT (GLuint, const GLuint *); -GLAPI void APIENTRY glVertexAttribI4bvEXT (GLuint, const GLbyte *); -GLAPI void APIENTRY glVertexAttribI4svEXT (GLuint, const GLshort *); -GLAPI void APIENTRY glVertexAttribI4ubvEXT (GLuint, const GLubyte *); -GLAPI void APIENTRY glVertexAttribI4usvEXT (GLuint, const GLushort *); -GLAPI void APIENTRY glVertexAttribIPointerEXT (GLuint, GLint, GLenum, GLsizei, const GLvoid *); -GLAPI void APIENTRY glGetVertexAttribIivEXT (GLuint, GLenum, GLint *); -GLAPI void APIENTRY glGetVertexAttribIuivEXT (GLuint, GLenum, GLuint *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLVERTEXATTRIBI1IEXTPROC) (GLuint index, GLint x); -typedef void (APIENTRYP PFNGLVERTEXATTRIBI2IEXTPROC) (GLuint index, GLint x, GLint y); -typedef void (APIENTRYP PFNGLVERTEXATTRIBI3IEXTPROC) (GLuint index, GLint x, GLint y, GLint z); -typedef void (APIENTRYP PFNGLVERTEXATTRIBI4IEXTPROC) (GLuint index, GLint x, GLint y, GLint z, GLint w); -typedef void (APIENTRYP PFNGLVERTEXATTRIBI1UIEXTPROC) (GLuint index, GLuint x); -typedef void (APIENTRYP PFNGLVERTEXATTRIBI2UIEXTPROC) (GLuint index, GLuint x, GLuint y); -typedef void (APIENTRYP PFNGLVERTEXATTRIBI3UIEXTPROC) (GLuint index, GLuint x, GLuint y, GLuint z); -typedef void (APIENTRYP PFNGLVERTEXATTRIBI4UIEXTPROC) (GLuint index, GLuint x, GLuint y, GLuint z, GLuint w); -typedef void (APIENTRYP PFNGLVERTEXATTRIBI1IVEXTPROC) (GLuint index, const GLint *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBI2IVEXTPROC) (GLuint index, const GLint *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBI3IVEXTPROC) (GLuint index, const GLint *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBI4IVEXTPROC) (GLuint index, const GLint *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBI1UIVEXTPROC) (GLuint index, const GLuint *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBI2UIVEXTPROC) (GLuint index, const GLuint *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBI3UIVEXTPROC) (GLuint index, const GLuint *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBI4UIVEXTPROC) (GLuint index, const GLuint *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBI4BVEXTPROC) (GLuint index, const GLbyte *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBI4SVEXTPROC) (GLuint index, const GLshort *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBI4UBVEXTPROC) (GLuint index, const GLubyte *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBI4USVEXTPROC) (GLuint index, const GLushort *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBIPOINTEREXTPROC) (GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer); -typedef void (APIENTRYP PFNGLGETVERTEXATTRIBIIVEXTPROC) (GLuint index, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETVERTEXATTRIBIUIVEXTPROC) (GLuint index, GLenum pname, GLuint *params); -#endif - -#ifndef GL_EXT_gpu_shader4 -#define GL_EXT_gpu_shader4 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glGetUniformuivEXT (GLuint, GLint, GLuint *); -GLAPI void APIENTRY glBindFragDataLocationEXT (GLuint, GLuint, const GLchar *); -GLAPI GLint APIENTRY glGetFragDataLocationEXT (GLuint, const GLchar *); -GLAPI void APIENTRY glUniform1uiEXT (GLint, GLuint); -GLAPI void APIENTRY glUniform2uiEXT (GLint, GLuint, GLuint); -GLAPI void APIENTRY glUniform3uiEXT (GLint, GLuint, GLuint, GLuint); -GLAPI void APIENTRY glUniform4uiEXT (GLint, GLuint, GLuint, GLuint, GLuint); -GLAPI void APIENTRY glUniform1uivEXT (GLint, GLsizei, const GLuint *); -GLAPI void APIENTRY glUniform2uivEXT (GLint, GLsizei, const GLuint *); -GLAPI void APIENTRY glUniform3uivEXT (GLint, GLsizei, const GLuint *); -GLAPI void APIENTRY glUniform4uivEXT (GLint, GLsizei, const GLuint *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLGETUNIFORMUIVEXTPROC) (GLuint program, GLint location, GLuint *params); -typedef void (APIENTRYP PFNGLBINDFRAGDATALOCATIONEXTPROC) (GLuint program, GLuint color, const GLchar *name); -typedef GLint (APIENTRYP PFNGLGETFRAGDATALOCATIONEXTPROC) (GLuint program, const GLchar *name); -typedef void (APIENTRYP PFNGLUNIFORM1UIEXTPROC) (GLint location, GLuint v0); -typedef void (APIENTRYP PFNGLUNIFORM2UIEXTPROC) (GLint location, GLuint v0, GLuint v1); -typedef void (APIENTRYP PFNGLUNIFORM3UIEXTPROC) (GLint location, GLuint v0, GLuint v1, GLuint v2); -typedef void (APIENTRYP PFNGLUNIFORM4UIEXTPROC) (GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3); -typedef void (APIENTRYP PFNGLUNIFORM1UIVEXTPROC) (GLint location, GLsizei count, const GLuint *value); -typedef void (APIENTRYP PFNGLUNIFORM2UIVEXTPROC) (GLint location, GLsizei count, const GLuint *value); -typedef void (APIENTRYP PFNGLUNIFORM3UIVEXTPROC) (GLint location, GLsizei count, const GLuint *value); -typedef void (APIENTRYP PFNGLUNIFORM4UIVEXTPROC) (GLint location, GLsizei count, const GLuint *value); -#endif - -#ifndef GL_EXT_draw_instanced -#define GL_EXT_draw_instanced 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glDrawArraysInstancedEXT (GLenum, GLint, GLsizei, GLsizei); -GLAPI void APIENTRY glDrawElementsInstancedEXT (GLenum, GLsizei, GLenum, const GLvoid *, GLsizei); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLDRAWARRAYSINSTANCEDEXTPROC) (GLenum mode, GLint start, GLsizei count, GLsizei primcount); -typedef void (APIENTRYP PFNGLDRAWELEMENTSINSTANCEDEXTPROC) (GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei primcount); -#endif - -#ifndef GL_EXT_packed_float -#define GL_EXT_packed_float 1 -#endif - -#ifndef GL_EXT_texture_array -#define GL_EXT_texture_array 1 -#endif - -#ifndef GL_EXT_texture_buffer_object -#define GL_EXT_texture_buffer_object 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glTexBufferEXT (GLenum, GLenum, GLuint); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLTEXBUFFEREXTPROC) (GLenum target, GLenum internalformat, GLuint buffer); -#endif - -#ifndef GL_EXT_texture_compression_latc -#define GL_EXT_texture_compression_latc 1 -#endif - -#ifndef GL_EXT_texture_compression_rgtc -#define GL_EXT_texture_compression_rgtc 1 -#endif - -#ifndef GL_EXT_texture_shared_exponent -#define GL_EXT_texture_shared_exponent 1 -#endif - -#ifndef GL_NV_depth_buffer_float -#define GL_NV_depth_buffer_float 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glDepthRangedNV (GLdouble, GLdouble); -GLAPI void APIENTRY glClearDepthdNV (GLdouble); -GLAPI void APIENTRY glDepthBoundsdNV (GLdouble, GLdouble); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLDEPTHRANGEDNVPROC) (GLdouble zNear, GLdouble zFar); -typedef void (APIENTRYP PFNGLCLEARDEPTHDNVPROC) (GLdouble depth); -typedef void (APIENTRYP PFNGLDEPTHBOUNDSDNVPROC) (GLdouble zmin, GLdouble zmax); -#endif - -#ifndef GL_NV_fragment_program4 -#define GL_NV_fragment_program4 1 -#endif - -#ifndef GL_NV_framebuffer_multisample_coverage -#define GL_NV_framebuffer_multisample_coverage 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glRenderbufferStorageMultisampleCoverageNV (GLenum, GLsizei, GLsizei, GLenum, GLsizei, GLsizei); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLRENDERBUFFERSTORAGEMULTISAMPLECOVERAGENVPROC) (GLenum target, GLsizei coverageSamples, GLsizei colorSamples, GLenum internalformat, GLsizei width, GLsizei height); -#endif - -#ifndef GL_EXT_framebuffer_sRGB -#define GL_EXT_framebuffer_sRGB 1 -#endif - -#ifndef GL_NV_geometry_shader4 -#define GL_NV_geometry_shader4 1 -#endif - -#ifndef GL_NV_parameter_buffer_object -#define GL_NV_parameter_buffer_object 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glProgramBufferParametersfvNV (GLenum, GLuint, GLuint, GLsizei, const GLfloat *); -GLAPI void APIENTRY glProgramBufferParametersIivNV (GLenum, GLuint, GLuint, GLsizei, const GLint *); -GLAPI void APIENTRY glProgramBufferParametersIuivNV (GLenum, GLuint, GLuint, GLsizei, const GLuint *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLPROGRAMBUFFERPARAMETERSFVNVPROC) (GLenum target, GLuint buffer, GLuint index, GLsizei count, const GLfloat *params); -typedef void (APIENTRYP PFNGLPROGRAMBUFFERPARAMETERSIIVNVPROC) (GLenum target, GLuint buffer, GLuint index, GLsizei count, const GLint *params); -typedef void (APIENTRYP PFNGLPROGRAMBUFFERPARAMETERSIUIVNVPROC) (GLenum target, GLuint buffer, GLuint index, GLsizei count, const GLuint *params); -#endif - -#ifndef GL_EXT_draw_buffers2 -#define GL_EXT_draw_buffers2 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glColorMaskIndexedEXT (GLuint, GLboolean, GLboolean, GLboolean, GLboolean); -GLAPI void APIENTRY glGetBooleanIndexedvEXT (GLenum, GLuint, GLboolean *); -GLAPI void APIENTRY glGetIntegerIndexedvEXT (GLenum, GLuint, GLint *); -GLAPI void APIENTRY glEnableIndexedEXT (GLenum, GLuint); -GLAPI void APIENTRY glDisableIndexedEXT (GLenum, GLuint); -GLAPI GLboolean APIENTRY glIsEnabledIndexedEXT (GLenum, GLuint); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLCOLORMASKINDEXEDEXTPROC) (GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a); -typedef void (APIENTRYP PFNGLGETBOOLEANINDEXEDVEXTPROC) (GLenum target, GLuint index, GLboolean *data); -typedef void (APIENTRYP PFNGLGETINTEGERINDEXEDVEXTPROC) (GLenum target, GLuint index, GLint *data); -typedef void (APIENTRYP PFNGLENABLEINDEXEDEXTPROC) (GLenum target, GLuint index); -typedef void (APIENTRYP PFNGLDISABLEINDEXEDEXTPROC) (GLenum target, GLuint index); -typedef GLboolean (APIENTRYP PFNGLISENABLEDINDEXEDEXTPROC) (GLenum target, GLuint index); -#endif - -#ifndef GL_NV_transform_feedback -#define GL_NV_transform_feedback 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glBeginTransformFeedbackNV (GLenum); -GLAPI void APIENTRY glEndTransformFeedbackNV (void); -GLAPI void APIENTRY glTransformFeedbackAttribsNV (GLuint, const GLint *, GLenum); -GLAPI void APIENTRY glBindBufferRangeNV (GLenum, GLuint, GLuint, GLintptr, GLsizeiptr); -GLAPI void APIENTRY glBindBufferOffsetNV (GLenum, GLuint, GLuint, GLintptr); -GLAPI void APIENTRY glBindBufferBaseNV (GLenum, GLuint, GLuint); -GLAPI void APIENTRY glTransformFeedbackVaryingsNV (GLuint, GLsizei, const GLint *, GLenum); -GLAPI void APIENTRY glActiveVaryingNV (GLuint, const GLchar *); -GLAPI GLint APIENTRY glGetVaryingLocationNV (GLuint, const GLchar *); -GLAPI void APIENTRY glGetActiveVaryingNV (GLuint, GLuint, GLsizei, GLsizei *, GLsizei *, GLenum *, GLchar *); -GLAPI void APIENTRY glGetTransformFeedbackVaryingNV (GLuint, GLuint, GLint *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLBEGINTRANSFORMFEEDBACKNVPROC) (GLenum primitiveMode); -typedef void (APIENTRYP PFNGLENDTRANSFORMFEEDBACKNVPROC) (void); -typedef void (APIENTRYP PFNGLTRANSFORMFEEDBACKATTRIBSNVPROC) (GLuint count, const GLint *attribs, GLenum bufferMode); -typedef void (APIENTRYP PFNGLBINDBUFFERRANGENVPROC) (GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size); -typedef void (APIENTRYP PFNGLBINDBUFFEROFFSETNVPROC) (GLenum target, GLuint index, GLuint buffer, GLintptr offset); -typedef void (APIENTRYP PFNGLBINDBUFFERBASENVPROC) (GLenum target, GLuint index, GLuint buffer); -typedef void (APIENTRYP PFNGLTRANSFORMFEEDBACKVARYINGSNVPROC) (GLuint program, GLsizei count, const GLint *locations, GLenum bufferMode); -typedef void (APIENTRYP PFNGLACTIVEVARYINGNVPROC) (GLuint program, const GLchar *name); -typedef GLint (APIENTRYP PFNGLGETVARYINGLOCATIONNVPROC) (GLuint program, const GLchar *name); -typedef void (APIENTRYP PFNGLGETACTIVEVARYINGNVPROC) (GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLsizei *size, GLenum *type, GLchar *name); -typedef void (APIENTRYP PFNGLGETTRANSFORMFEEDBACKVARYINGNVPROC) (GLuint program, GLuint index, GLint *location); -#endif - -#ifndef GL_EXT_bindable_uniform -#define GL_EXT_bindable_uniform 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glUniformBufferEXT (GLuint, GLint, GLuint); -GLAPI GLint APIENTRY glGetUniformBufferSizeEXT (GLuint, GLint); -GLAPI GLintptr APIENTRY glGetUniformOffsetEXT (GLuint, GLint); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLUNIFORMBUFFEREXTPROC) (GLuint program, GLint location, GLuint buffer); -typedef GLint (APIENTRYP PFNGLGETUNIFORMBUFFERSIZEEXTPROC) (GLuint program, GLint location); -typedef GLintptr (APIENTRYP PFNGLGETUNIFORMOFFSETEXTPROC) (GLuint program, GLint location); -#endif - -#ifndef GL_EXT_texture_integer -#define GL_EXT_texture_integer 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glTexParameterIivEXT (GLenum, GLenum, const GLint *); -GLAPI void APIENTRY glTexParameterIuivEXT (GLenum, GLenum, const GLuint *); -GLAPI void APIENTRY glGetTexParameterIivEXT (GLenum, GLenum, GLint *); -GLAPI void APIENTRY glGetTexParameterIuivEXT (GLenum, GLenum, GLuint *); -GLAPI void APIENTRY glClearColorIiEXT (GLint, GLint, GLint, GLint); -GLAPI void APIENTRY glClearColorIuiEXT (GLuint, GLuint, GLuint, GLuint); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLTEXPARAMETERIIVEXTPROC) (GLenum target, GLenum pname, const GLint *params); -typedef void (APIENTRYP PFNGLTEXPARAMETERIUIVEXTPROC) (GLenum target, GLenum pname, const GLuint *params); -typedef void (APIENTRYP PFNGLGETTEXPARAMETERIIVEXTPROC) (GLenum target, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETTEXPARAMETERIUIVEXTPROC) (GLenum target, GLenum pname, GLuint *params); -typedef void (APIENTRYP PFNGLCLEARCOLORIIEXTPROC) (GLint red, GLint green, GLint blue, GLint alpha); -typedef void (APIENTRYP PFNGLCLEARCOLORIUIEXTPROC) (GLuint red, GLuint green, GLuint blue, GLuint alpha); -#endif - -#ifndef GL_GREMEDY_frame_terminator -#define GL_GREMEDY_frame_terminator 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glFrameTerminatorGREMEDY (void); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLFRAMETERMINATORGREMEDYPROC) (void); -#endif - -#ifndef GL_NV_conditional_render -#define GL_NV_conditional_render 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glBeginConditionalRenderNV (GLuint, GLenum); -GLAPI void APIENTRY glEndConditionalRenderNV (void); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLBEGINCONDITIONALRENDERNVPROC) (GLuint id, GLenum mode); -typedef void (APIENTRYP PFNGLENDCONDITIONALRENDERNVPROC) (void); -#endif - -#ifndef GL_NV_present_video -#define GL_NV_present_video 1 -#endif - -#ifndef GL_EXT_transform_feedback -#define GL_EXT_transform_feedback 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glBeginTransformFeedbackEXT (GLenum); -GLAPI void APIENTRY glEndTransformFeedbackEXT (void); -GLAPI void APIENTRY glBindBufferRangeEXT (GLenum, GLuint, GLuint, GLintptr, GLsizeiptr); -GLAPI void APIENTRY glBindBufferOffsetEXT (GLenum, GLuint, GLuint, GLintptr); -GLAPI void APIENTRY glBindBufferBaseEXT (GLenum, GLuint, GLuint); -GLAPI void APIENTRY glTransformFeedbackVaryingsEXT (GLuint, GLsizei, const GLint *, GLenum); -GLAPI void APIENTRY glGetTransformFeedbackVaryingEXT (GLuint, GLuint, GLint *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLBEGINTRANSFORMFEEDBACKEXTPROC) (GLenum primitiveMode); -typedef void (APIENTRYP PFNGLENDTRANSFORMFEEDBACKEXTPROC) (void); -typedef void (APIENTRYP PFNGLBINDBUFFERRANGEEXTPROC) (GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size); -typedef void (APIENTRYP PFNGLBINDBUFFEROFFSETEXTPROC) (GLenum target, GLuint index, GLuint buffer, GLintptr offset); -typedef void (APIENTRYP PFNGLBINDBUFFERBASEEXTPROC) (GLenum target, GLuint index, GLuint buffer); -typedef void (APIENTRYP PFNGLTRANSFORMFEEDBACKVARYINGSEXTPROC) (GLuint program, GLsizei count, const GLint *locations, GLenum bufferMode); -typedef void (APIENTRYP PFNGLGETTRANSFORMFEEDBACKVARYINGEXTPROC) (GLuint program, GLuint index, GLint *location); -#endif - -#ifndef GL_EXT_direct_state_access -#define GL_EXT_direct_state_access 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glClientAttribDefaultEXT (GLbitfield); -GLAPI void APIENTRY glPushClientAttribDefaultEXT (GLbitfield); -GLAPI void APIENTRY glMatrixLoadfEXT (GLenum, const GLfloat *); -GLAPI void APIENTRY glMatrixLoaddEXT (GLenum, const GLdouble *); -GLAPI void APIENTRY glMatrixMultfEXT (GLenum, const GLfloat *); -GLAPI void APIENTRY glMatrixMultdEXT (GLenum, const GLdouble *); -GLAPI void APIENTRY glMatrixLoadIdentityEXT (GLenum); -GLAPI void APIENTRY glMatrixRotatefEXT (GLenum, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glMatrixRotatedEXT (GLenum, GLdouble, GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glMatrixScalefEXT (GLenum, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glMatrixScaledEXT (GLenum, GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glMatrixTranslatefEXT (GLenum, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glMatrixTranslatedEXT (GLenum, GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glMatrixFrustumEXT (GLenum, GLdouble, GLdouble, GLdouble, GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glMatrixOrthoEXT (GLenum, GLdouble, GLdouble, GLdouble, GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glMatrixPopEXT (GLenum); -GLAPI void APIENTRY glMatrixPushEXT (GLenum); -GLAPI void APIENTRY glMatrixLoadTransposefEXT (GLenum, const GLfloat *); -GLAPI void APIENTRY glMatrixLoadTransposedEXT (GLenum, const GLdouble *); -GLAPI void APIENTRY glMatrixMultTransposefEXT (GLenum, const GLfloat *); -GLAPI void APIENTRY glMatrixMultTransposedEXT (GLenum, const GLdouble *); -GLAPI void APIENTRY glTextureParameterfEXT (GLuint, GLenum, GLenum, GLfloat); -GLAPI void APIENTRY glTextureParameterfvEXT (GLuint, GLenum, GLenum, const GLfloat *); -GLAPI void APIENTRY glTextureParameteriEXT (GLuint, GLenum, GLenum, GLint); -GLAPI void APIENTRY glTextureParameterivEXT (GLuint, GLenum, GLenum, const GLint *); -GLAPI void APIENTRY glTextureImage1DEXT (GLuint, GLenum, GLint, GLenum, GLsizei, GLint, GLenum, GLenum, const GLvoid *); -GLAPI void APIENTRY glTextureImage2DEXT (GLuint, GLenum, GLint, GLenum, GLsizei, GLsizei, GLint, GLenum, GLenum, const GLvoid *); -GLAPI void APIENTRY glTextureSubImage1DEXT (GLuint, GLenum, GLint, GLint, GLsizei, GLenum, GLenum, const GLvoid *); -GLAPI void APIENTRY glTextureSubImage2DEXT (GLuint, GLenum, GLint, GLint, GLint, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *); -GLAPI void APIENTRY glCopyTextureImage1DEXT (GLuint, GLenum, GLint, GLenum, GLint, GLint, GLsizei, GLint); -GLAPI void APIENTRY glCopyTextureImage2DEXT (GLuint, GLenum, GLint, GLenum, GLint, GLint, GLsizei, GLsizei, GLint); -GLAPI void APIENTRY glCopyTextureSubImage1DEXT (GLuint, GLenum, GLint, GLint, GLint, GLint, GLsizei); -GLAPI void APIENTRY glCopyTextureSubImage2DEXT (GLuint, GLenum, GLint, GLint, GLint, GLint, GLint, GLsizei, GLsizei); -GLAPI void APIENTRY glGetTextureImageEXT (GLuint, GLenum, GLint, GLenum, GLenum, GLvoid *); -GLAPI void APIENTRY glGetTextureParameterfvEXT (GLuint, GLenum, GLenum, GLfloat *); -GLAPI void APIENTRY glGetTextureParameterivEXT (GLuint, GLenum, GLenum, GLint *); -GLAPI void APIENTRY glGetTextureLevelParameterfvEXT (GLuint, GLenum, GLint, GLenum, GLfloat *); -GLAPI void APIENTRY glGetTextureLevelParameterivEXT (GLuint, GLenum, GLint, GLenum, GLint *); -GLAPI void APIENTRY glTextureImage3DEXT (GLuint, GLenum, GLint, GLenum, GLsizei, GLsizei, GLsizei, GLint, GLenum, GLenum, const GLvoid *); -GLAPI void APIENTRY glTextureSubImage3DEXT (GLuint, GLenum, GLint, GLint, GLint, GLint, GLsizei, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *); -GLAPI void APIENTRY glCopyTextureSubImage3DEXT (GLuint, GLenum, GLint, GLint, GLint, GLint, GLint, GLint, GLsizei, GLsizei); -GLAPI void APIENTRY glMultiTexParameterfEXT (GLenum, GLenum, GLenum, GLfloat); -GLAPI void APIENTRY glMultiTexParameterfvEXT (GLenum, GLenum, GLenum, const GLfloat *); -GLAPI void APIENTRY glMultiTexParameteriEXT (GLenum, GLenum, GLenum, GLint); -GLAPI void APIENTRY glMultiTexParameterivEXT (GLenum, GLenum, GLenum, const GLint *); -GLAPI void APIENTRY glMultiTexImage1DEXT (GLenum, GLenum, GLint, GLenum, GLsizei, GLint, GLenum, GLenum, const GLvoid *); -GLAPI void APIENTRY glMultiTexImage2DEXT (GLenum, GLenum, GLint, GLenum, GLsizei, GLsizei, GLint, GLenum, GLenum, const GLvoid *); -GLAPI void APIENTRY glMultiTexSubImage1DEXT (GLenum, GLenum, GLint, GLint, GLsizei, GLenum, GLenum, const GLvoid *); -GLAPI void APIENTRY glMultiTexSubImage2DEXT (GLenum, GLenum, GLint, GLint, GLint, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *); -GLAPI void APIENTRY glCopyMultiTexImage1DEXT (GLenum, GLenum, GLint, GLenum, GLint, GLint, GLsizei, GLint); -GLAPI void APIENTRY glCopyMultiTexImage2DEXT (GLenum, GLenum, GLint, GLenum, GLint, GLint, GLsizei, GLsizei, GLint); -GLAPI void APIENTRY glCopyMultiTexSubImage1DEXT (GLenum, GLenum, GLint, GLint, GLint, GLint, GLsizei); -GLAPI void APIENTRY glCopyMultiTexSubImage2DEXT (GLenum, GLenum, GLint, GLint, GLint, GLint, GLint, GLsizei, GLsizei); -GLAPI void APIENTRY glGetMultiTexImageEXT (GLenum, GLenum, GLint, GLenum, GLenum, GLvoid *); -GLAPI void APIENTRY glGetMultiTexParameterfvEXT (GLenum, GLenum, GLenum, GLfloat *); -GLAPI void APIENTRY glGetMultiTexParameterivEXT (GLenum, GLenum, GLenum, GLint *); -GLAPI void APIENTRY glGetMultiTexLevelParameterfvEXT (GLenum, GLenum, GLint, GLenum, GLfloat *); -GLAPI void APIENTRY glGetMultiTexLevelParameterivEXT (GLenum, GLenum, GLint, GLenum, GLint *); -GLAPI void APIENTRY glMultiTexImage3DEXT (GLenum, GLenum, GLint, GLenum, GLsizei, GLsizei, GLsizei, GLint, GLenum, GLenum, const GLvoid *); -GLAPI void APIENTRY glMultiTexSubImage3DEXT (GLenum, GLenum, GLint, GLint, GLint, GLint, GLsizei, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *); -GLAPI void APIENTRY glCopyMultiTexSubImage3DEXT (GLenum, GLenum, GLint, GLint, GLint, GLint, GLint, GLint, GLsizei, GLsizei); -GLAPI void APIENTRY glBindMultiTextureEXT (GLenum, GLenum, GLuint); -GLAPI void APIENTRY glEnableClientStateIndexedEXT (GLenum, GLuint); -GLAPI void APIENTRY glDisableClientStateIndexedEXT (GLenum, GLuint); -GLAPI void APIENTRY glMultiTexCoordPointerEXT (GLenum, GLint, GLenum, GLsizei, const GLvoid *); -GLAPI void APIENTRY glMultiTexEnvfEXT (GLenum, GLenum, GLenum, GLfloat); -GLAPI void APIENTRY glMultiTexEnvfvEXT (GLenum, GLenum, GLenum, const GLfloat *); -GLAPI void APIENTRY glMultiTexEnviEXT (GLenum, GLenum, GLenum, GLint); -GLAPI void APIENTRY glMultiTexEnvivEXT (GLenum, GLenum, GLenum, const GLint *); -GLAPI void APIENTRY glMultiTexGendEXT (GLenum, GLenum, GLenum, GLdouble); -GLAPI void APIENTRY glMultiTexGendvEXT (GLenum, GLenum, GLenum, const GLdouble *); -GLAPI void APIENTRY glMultiTexGenfEXT (GLenum, GLenum, GLenum, GLfloat); -GLAPI void APIENTRY glMultiTexGenfvEXT (GLenum, GLenum, GLenum, const GLfloat *); -GLAPI void APIENTRY glMultiTexGeniEXT (GLenum, GLenum, GLenum, GLint); -GLAPI void APIENTRY glMultiTexGenivEXT (GLenum, GLenum, GLenum, const GLint *); -GLAPI void APIENTRY glGetMultiTexEnvfvEXT (GLenum, GLenum, GLenum, GLfloat *); -GLAPI void APIENTRY glGetMultiTexEnvivEXT (GLenum, GLenum, GLenum, GLint *); -GLAPI void APIENTRY glGetMultiTexGendvEXT (GLenum, GLenum, GLenum, GLdouble *); -GLAPI void APIENTRY glGetMultiTexGenfvEXT (GLenum, GLenum, GLenum, GLfloat *); -GLAPI void APIENTRY glGetMultiTexGenivEXT (GLenum, GLenum, GLenum, GLint *); -GLAPI void APIENTRY glGetFloatIndexedvEXT (GLenum, GLuint, GLfloat *); -GLAPI void APIENTRY glGetDoubleIndexedvEXT (GLenum, GLuint, GLdouble *); -GLAPI void APIENTRY glGetPointerIndexedvEXT (GLenum, GLuint, GLvoid* *); -GLAPI void APIENTRY glCompressedTextureImage3DEXT (GLuint, GLenum, GLint, GLenum, GLsizei, GLsizei, GLsizei, GLint, GLsizei, const GLvoid *); -GLAPI void APIENTRY glCompressedTextureImage2DEXT (GLuint, GLenum, GLint, GLenum, GLsizei, GLsizei, GLint, GLsizei, const GLvoid *); -GLAPI void APIENTRY glCompressedTextureImage1DEXT (GLuint, GLenum, GLint, GLenum, GLsizei, GLint, GLsizei, const GLvoid *); -GLAPI void APIENTRY glCompressedTextureSubImage3DEXT (GLuint, GLenum, GLint, GLint, GLint, GLint, GLsizei, GLsizei, GLsizei, GLenum, GLsizei, const GLvoid *); -GLAPI void APIENTRY glCompressedTextureSubImage2DEXT (GLuint, GLenum, GLint, GLint, GLint, GLsizei, GLsizei, GLenum, GLsizei, const GLvoid *); -GLAPI void APIENTRY glCompressedTextureSubImage1DEXT (GLuint, GLenum, GLint, GLint, GLsizei, GLenum, GLsizei, const GLvoid *); -GLAPI void APIENTRY glGetCompressedTextureImageEXT (GLuint, GLenum, GLint, GLvoid *); -GLAPI void APIENTRY glCompressedMultiTexImage3DEXT (GLenum, GLenum, GLint, GLenum, GLsizei, GLsizei, GLsizei, GLint, GLsizei, const GLvoid *); -GLAPI void APIENTRY glCompressedMultiTexImage2DEXT (GLenum, GLenum, GLint, GLenum, GLsizei, GLsizei, GLint, GLsizei, const GLvoid *); -GLAPI void APIENTRY glCompressedMultiTexImage1DEXT (GLenum, GLenum, GLint, GLenum, GLsizei, GLint, GLsizei, const GLvoid *); -GLAPI void APIENTRY glCompressedMultiTexSubImage3DEXT (GLenum, GLenum, GLint, GLint, GLint, GLint, GLsizei, GLsizei, GLsizei, GLenum, GLsizei, const GLvoid *); -GLAPI void APIENTRY glCompressedMultiTexSubImage2DEXT (GLenum, GLenum, GLint, GLint, GLint, GLsizei, GLsizei, GLenum, GLsizei, const GLvoid *); -GLAPI void APIENTRY glCompressedMultiTexSubImage1DEXT (GLenum, GLenum, GLint, GLint, GLsizei, GLenum, GLsizei, const GLvoid *); -GLAPI void APIENTRY glGetCompressedMultiTexImageEXT (GLenum, GLenum, GLint, GLvoid *); -GLAPI void APIENTRY glNamedProgramStringEXT (GLuint, GLenum, GLenum, GLsizei, const GLvoid *); -GLAPI void APIENTRY glNamedProgramLocalParameter4dEXT (GLuint, GLenum, GLuint, GLdouble, GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glNamedProgramLocalParameter4dvEXT (GLuint, GLenum, GLuint, const GLdouble *); -GLAPI void APIENTRY glNamedProgramLocalParameter4fEXT (GLuint, GLenum, GLuint, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glNamedProgramLocalParameter4fvEXT (GLuint, GLenum, GLuint, const GLfloat *); -GLAPI void APIENTRY glGetNamedProgramLocalParameterdvEXT (GLuint, GLenum, GLuint, GLdouble *); -GLAPI void APIENTRY glGetNamedProgramLocalParameterfvEXT (GLuint, GLenum, GLuint, GLfloat *); -GLAPI void APIENTRY glGetNamedProgramivEXT (GLuint, GLenum, GLenum, GLint *); -GLAPI void APIENTRY glGetNamedProgramStringEXT (GLuint, GLenum, GLenum, GLvoid *); -GLAPI void APIENTRY glNamedProgramLocalParameters4fvEXT (GLuint, GLenum, GLuint, GLsizei, const GLfloat *); -GLAPI void APIENTRY glNamedProgramLocalParameterI4iEXT (GLuint, GLenum, GLuint, GLint, GLint, GLint, GLint); -GLAPI void APIENTRY glNamedProgramLocalParameterI4ivEXT (GLuint, GLenum, GLuint, const GLint *); -GLAPI void APIENTRY glNamedProgramLocalParametersI4ivEXT (GLuint, GLenum, GLuint, GLsizei, const GLint *); -GLAPI void APIENTRY glNamedProgramLocalParameterI4uiEXT (GLuint, GLenum, GLuint, GLuint, GLuint, GLuint, GLuint); -GLAPI void APIENTRY glNamedProgramLocalParameterI4uivEXT (GLuint, GLenum, GLuint, const GLuint *); -GLAPI void APIENTRY glNamedProgramLocalParametersI4uivEXT (GLuint, GLenum, GLuint, GLsizei, const GLuint *); -GLAPI void APIENTRY glGetNamedProgramLocalParameterIivEXT (GLuint, GLenum, GLuint, GLint *); -GLAPI void APIENTRY glGetNamedProgramLocalParameterIuivEXT (GLuint, GLenum, GLuint, GLuint *); -GLAPI void APIENTRY glTextureParameterIivEXT (GLuint, GLenum, GLenum, const GLint *); -GLAPI void APIENTRY glTextureParameterIuivEXT (GLuint, GLenum, GLenum, const GLuint *); -GLAPI void APIENTRY glGetTextureParameterIivEXT (GLuint, GLenum, GLenum, GLint *); -GLAPI void APIENTRY glGetTextureParameterIuivEXT (GLuint, GLenum, GLenum, GLuint *); -GLAPI void APIENTRY glMultiTexParameterIivEXT (GLenum, GLenum, GLenum, const GLint *); -GLAPI void APIENTRY glMultiTexParameterIuivEXT (GLenum, GLenum, GLenum, const GLuint *); -GLAPI void APIENTRY glGetMultiTexParameterIivEXT (GLenum, GLenum, GLenum, GLint *); -GLAPI void APIENTRY glGetMultiTexParameterIuivEXT (GLenum, GLenum, GLenum, GLuint *); -GLAPI void APIENTRY glProgramUniform1fEXT (GLuint, GLint, GLfloat); -GLAPI void APIENTRY glProgramUniform2fEXT (GLuint, GLint, GLfloat, GLfloat); -GLAPI void APIENTRY glProgramUniform3fEXT (GLuint, GLint, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glProgramUniform4fEXT (GLuint, GLint, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glProgramUniform1iEXT (GLuint, GLint, GLint); -GLAPI void APIENTRY glProgramUniform2iEXT (GLuint, GLint, GLint, GLint); -GLAPI void APIENTRY glProgramUniform3iEXT (GLuint, GLint, GLint, GLint, GLint); -GLAPI void APIENTRY glProgramUniform4iEXT (GLuint, GLint, GLint, GLint, GLint, GLint); -GLAPI void APIENTRY glProgramUniform1fvEXT (GLuint, GLint, GLsizei, const GLfloat *); -GLAPI void APIENTRY glProgramUniform2fvEXT (GLuint, GLint, GLsizei, const GLfloat *); -GLAPI void APIENTRY glProgramUniform3fvEXT (GLuint, GLint, GLsizei, const GLfloat *); -GLAPI void APIENTRY glProgramUniform4fvEXT (GLuint, GLint, GLsizei, const GLfloat *); -GLAPI void APIENTRY glProgramUniform1ivEXT (GLuint, GLint, GLsizei, const GLint *); -GLAPI void APIENTRY glProgramUniform2ivEXT (GLuint, GLint, GLsizei, const GLint *); -GLAPI void APIENTRY glProgramUniform3ivEXT (GLuint, GLint, GLsizei, const GLint *); -GLAPI void APIENTRY glProgramUniform4ivEXT (GLuint, GLint, GLsizei, const GLint *); -GLAPI void APIENTRY glProgramUniformMatrix2fvEXT (GLuint, GLint, GLsizei, GLboolean, const GLfloat *); -GLAPI void APIENTRY glProgramUniformMatrix3fvEXT (GLuint, GLint, GLsizei, GLboolean, const GLfloat *); -GLAPI void APIENTRY glProgramUniformMatrix4fvEXT (GLuint, GLint, GLsizei, GLboolean, const GLfloat *); -GLAPI void APIENTRY glProgramUniformMatrix2x3fvEXT (GLuint, GLint, GLsizei, GLboolean, const GLfloat *); -GLAPI void APIENTRY glProgramUniformMatrix3x2fvEXT (GLuint, GLint, GLsizei, GLboolean, const GLfloat *); -GLAPI void APIENTRY glProgramUniformMatrix2x4fvEXT (GLuint, GLint, GLsizei, GLboolean, const GLfloat *); -GLAPI void APIENTRY glProgramUniformMatrix4x2fvEXT (GLuint, GLint, GLsizei, GLboolean, const GLfloat *); -GLAPI void APIENTRY glProgramUniformMatrix3x4fvEXT (GLuint, GLint, GLsizei, GLboolean, const GLfloat *); -GLAPI void APIENTRY glProgramUniformMatrix4x3fvEXT (GLuint, GLint, GLsizei, GLboolean, const GLfloat *); -GLAPI void APIENTRY glProgramUniform1uiEXT (GLuint, GLint, GLuint); -GLAPI void APIENTRY glProgramUniform2uiEXT (GLuint, GLint, GLuint, GLuint); -GLAPI void APIENTRY glProgramUniform3uiEXT (GLuint, GLint, GLuint, GLuint, GLuint); -GLAPI void APIENTRY glProgramUniform4uiEXT (GLuint, GLint, GLuint, GLuint, GLuint, GLuint); -GLAPI void APIENTRY glProgramUniform1uivEXT (GLuint, GLint, GLsizei, const GLuint *); -GLAPI void APIENTRY glProgramUniform2uivEXT (GLuint, GLint, GLsizei, const GLuint *); -GLAPI void APIENTRY glProgramUniform3uivEXT (GLuint, GLint, GLsizei, const GLuint *); -GLAPI void APIENTRY glProgramUniform4uivEXT (GLuint, GLint, GLsizei, const GLuint *); -GLAPI void APIENTRY glNamedBufferDataEXT (GLuint, GLsizeiptr, const GLvoid *, GLenum); -GLAPI void APIENTRY glNamedBufferSubDataEXT (GLuint, GLintptr, GLsizeiptr, const GLvoid *); -GLAPI GLvoid* APIENTRY glMapNamedBufferEXT (GLuint, GLenum); -GLAPI GLboolean APIENTRY glUnmapNamedBufferEXT (GLuint); -GLAPI void APIENTRY glGetNamedBufferParameterivEXT (GLuint, GLenum, GLint *); -GLAPI void APIENTRY glGetNamedBufferPointervEXT (GLuint, GLenum, GLvoid* *); -GLAPI void APIENTRY glGetNamedBufferSubDataEXT (GLuint, GLintptr, GLsizeiptr, GLvoid *); -GLAPI void APIENTRY glTextureBufferEXT (GLuint, GLenum, GLenum, GLuint); -GLAPI void APIENTRY glMultiTexBufferEXT (GLenum, GLenum, GLenum, GLuint); -GLAPI void APIENTRY glNamedRenderbufferStorageEXT (GLuint, GLenum, GLsizei, GLsizei); -GLAPI void APIENTRY glGetNamedRenderbufferParameterivEXT (GLuint, GLenum, GLint *); -GLAPI GLenum APIENTRY glCheckNamedFramebufferStatusEXT (GLuint, GLenum); -GLAPI void APIENTRY glNamedFramebufferTexture1DEXT (GLuint, GLenum, GLenum, GLuint, GLint); -GLAPI void APIENTRY glNamedFramebufferTexture2DEXT (GLuint, GLenum, GLenum, GLuint, GLint); -GLAPI void APIENTRY glNamedFramebufferTexture3DEXT (GLuint, GLenum, GLenum, GLuint, GLint, GLint); -GLAPI void APIENTRY glNamedFramebufferRenderbufferEXT (GLuint, GLenum, GLenum, GLuint); -GLAPI void APIENTRY glGetNamedFramebufferAttachmentParameterivEXT (GLuint, GLenum, GLenum, GLint *); -GLAPI void APIENTRY glGenerateTextureMipmapEXT (GLuint, GLenum); -GLAPI void APIENTRY glGenerateMultiTexMipmapEXT (GLenum, GLenum); -GLAPI void APIENTRY glFramebufferDrawBufferEXT (GLuint, GLenum); -GLAPI void APIENTRY glFramebufferDrawBuffersEXT (GLuint, GLsizei, const GLenum *); -GLAPI void APIENTRY glFramebufferReadBufferEXT (GLuint, GLenum); -GLAPI void APIENTRY glGetFramebufferParameterivEXT (GLuint, GLenum, GLint *); -GLAPI void APIENTRY glNamedRenderbufferStorageMultisampleEXT (GLuint, GLsizei, GLenum, GLsizei, GLsizei); -GLAPI void APIENTRY glNamedRenderbufferStorageMultisampleCoverageEXT (GLuint, GLsizei, GLsizei, GLenum, GLsizei, GLsizei); -GLAPI void APIENTRY glNamedFramebufferTextureEXT (GLuint, GLenum, GLuint, GLint); -GLAPI void APIENTRY glNamedFramebufferTextureLayerEXT (GLuint, GLenum, GLuint, GLint, GLint); -GLAPI void APIENTRY glNamedFramebufferTextureFaceEXT (GLuint, GLenum, GLuint, GLint, GLenum); -GLAPI void APIENTRY glTextureRenderbufferEXT (GLuint, GLenum, GLuint); -GLAPI void APIENTRY glMultiTexRenderbufferEXT (GLenum, GLenum, GLuint); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLCLIENTATTRIBDEFAULTEXTPROC) (GLbitfield mask); -typedef void (APIENTRYP PFNGLPUSHCLIENTATTRIBDEFAULTEXTPROC) (GLbitfield mask); -typedef void (APIENTRYP PFNGLMATRIXLOADFEXTPROC) (GLenum mode, const GLfloat *m); -typedef void (APIENTRYP PFNGLMATRIXLOADDEXTPROC) (GLenum mode, const GLdouble *m); -typedef void (APIENTRYP PFNGLMATRIXMULTFEXTPROC) (GLenum mode, const GLfloat *m); -typedef void (APIENTRYP PFNGLMATRIXMULTDEXTPROC) (GLenum mode, const GLdouble *m); -typedef void (APIENTRYP PFNGLMATRIXLOADIDENTITYEXTPROC) (GLenum mode); -typedef void (APIENTRYP PFNGLMATRIXROTATEFEXTPROC) (GLenum mode, GLfloat angle, GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLMATRIXROTATEDEXTPROC) (GLenum mode, GLdouble angle, GLdouble x, GLdouble y, GLdouble z); -typedef void (APIENTRYP PFNGLMATRIXSCALEFEXTPROC) (GLenum mode, GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLMATRIXSCALEDEXTPROC) (GLenum mode, GLdouble x, GLdouble y, GLdouble z); -typedef void (APIENTRYP PFNGLMATRIXTRANSLATEFEXTPROC) (GLenum mode, GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLMATRIXTRANSLATEDEXTPROC) (GLenum mode, GLdouble x, GLdouble y, GLdouble z); -typedef void (APIENTRYP PFNGLMATRIXFRUSTUMEXTPROC) (GLenum mode, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar); -typedef void (APIENTRYP PFNGLMATRIXORTHOEXTPROC) (GLenum mode, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar); -typedef void (APIENTRYP PFNGLMATRIXPOPEXTPROC) (GLenum mode); -typedef void (APIENTRYP PFNGLMATRIXPUSHEXTPROC) (GLenum mode); -typedef void (APIENTRYP PFNGLMATRIXLOADTRANSPOSEFEXTPROC) (GLenum mode, const GLfloat *m); -typedef void (APIENTRYP PFNGLMATRIXLOADTRANSPOSEDEXTPROC) (GLenum mode, const GLdouble *m); -typedef void (APIENTRYP PFNGLMATRIXMULTTRANSPOSEFEXTPROC) (GLenum mode, const GLfloat *m); -typedef void (APIENTRYP PFNGLMATRIXMULTTRANSPOSEDEXTPROC) (GLenum mode, const GLdouble *m); -typedef void (APIENTRYP PFNGLTEXTUREPARAMETERFEXTPROC) (GLuint texture, GLenum target, GLenum pname, GLfloat param); -typedef void (APIENTRYP PFNGLTEXTUREPARAMETERFVEXTPROC) (GLuint texture, GLenum target, GLenum pname, const GLfloat *params); -typedef void (APIENTRYP PFNGLTEXTUREPARAMETERIEXTPROC) (GLuint texture, GLenum target, GLenum pname, GLint param); -typedef void (APIENTRYP PFNGLTEXTUREPARAMETERIVEXTPROC) (GLuint texture, GLenum target, GLenum pname, const GLint *params); -typedef void (APIENTRYP PFNGLTEXTUREIMAGE1DEXTPROC) (GLuint texture, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels); -typedef void (APIENTRYP PFNGLTEXTUREIMAGE2DEXTPROC) (GLuint texture, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels); -typedef void (APIENTRYP PFNGLTEXTURESUBIMAGE1DEXTPROC) (GLuint texture, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels); -typedef void (APIENTRYP PFNGLTEXTURESUBIMAGE2DEXTPROC) (GLuint texture, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels); -typedef void (APIENTRYP PFNGLCOPYTEXTUREIMAGE1DEXTPROC) (GLuint texture, GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border); -typedef void (APIENTRYP PFNGLCOPYTEXTUREIMAGE2DEXTPROC) (GLuint texture, GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border); -typedef void (APIENTRYP PFNGLCOPYTEXTURESUBIMAGE1DEXTPROC) (GLuint texture, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width); -typedef void (APIENTRYP PFNGLCOPYTEXTURESUBIMAGE2DEXTPROC) (GLuint texture, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height); -typedef void (APIENTRYP PFNGLGETTEXTUREIMAGEEXTPROC) (GLuint texture, GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels); -typedef void (APIENTRYP PFNGLGETTEXTUREPARAMETERFVEXTPROC) (GLuint texture, GLenum target, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETTEXTUREPARAMETERIVEXTPROC) (GLuint texture, GLenum target, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETTEXTURELEVELPARAMETERFVEXTPROC) (GLuint texture, GLenum target, GLint level, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETTEXTURELEVELPARAMETERIVEXTPROC) (GLuint texture, GLenum target, GLint level, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLTEXTUREIMAGE3DEXTPROC) (GLuint texture, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels); -typedef void (APIENTRYP PFNGLTEXTURESUBIMAGE3DEXTPROC) (GLuint texture, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels); -typedef void (APIENTRYP PFNGLCOPYTEXTURESUBIMAGE3DEXTPROC) (GLuint texture, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height); -typedef void (APIENTRYP PFNGLMULTITEXPARAMETERFEXTPROC) (GLenum texunit, GLenum target, GLenum pname, GLfloat param); -typedef void (APIENTRYP PFNGLMULTITEXPARAMETERFVEXTPROC) (GLenum texunit, GLenum target, GLenum pname, const GLfloat *params); -typedef void (APIENTRYP PFNGLMULTITEXPARAMETERIEXTPROC) (GLenum texunit, GLenum target, GLenum pname, GLint param); -typedef void (APIENTRYP PFNGLMULTITEXPARAMETERIVEXTPROC) (GLenum texunit, GLenum target, GLenum pname, const GLint *params); -typedef void (APIENTRYP PFNGLMULTITEXIMAGE1DEXTPROC) (GLenum texunit, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels); -typedef void (APIENTRYP PFNGLMULTITEXIMAGE2DEXTPROC) (GLenum texunit, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels); -typedef void (APIENTRYP PFNGLMULTITEXSUBIMAGE1DEXTPROC) (GLenum texunit, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels); -typedef void (APIENTRYP PFNGLMULTITEXSUBIMAGE2DEXTPROC) (GLenum texunit, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels); -typedef void (APIENTRYP PFNGLCOPYMULTITEXIMAGE1DEXTPROC) (GLenum texunit, GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border); -typedef void (APIENTRYP PFNGLCOPYMULTITEXIMAGE2DEXTPROC) (GLenum texunit, GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border); -typedef void (APIENTRYP PFNGLCOPYMULTITEXSUBIMAGE1DEXTPROC) (GLenum texunit, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width); -typedef void (APIENTRYP PFNGLCOPYMULTITEXSUBIMAGE2DEXTPROC) (GLenum texunit, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height); -typedef void (APIENTRYP PFNGLGETMULTITEXIMAGEEXTPROC) (GLenum texunit, GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels); -typedef void (APIENTRYP PFNGLGETMULTITEXPARAMETERFVEXTPROC) (GLenum texunit, GLenum target, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETMULTITEXPARAMETERIVEXTPROC) (GLenum texunit, GLenum target, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETMULTITEXLEVELPARAMETERFVEXTPROC) (GLenum texunit, GLenum target, GLint level, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETMULTITEXLEVELPARAMETERIVEXTPROC) (GLenum texunit, GLenum target, GLint level, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLMULTITEXIMAGE3DEXTPROC) (GLenum texunit, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels); -typedef void (APIENTRYP PFNGLMULTITEXSUBIMAGE3DEXTPROC) (GLenum texunit, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels); -typedef void (APIENTRYP PFNGLCOPYMULTITEXSUBIMAGE3DEXTPROC) (GLenum texunit, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height); -typedef void (APIENTRYP PFNGLBINDMULTITEXTUREEXTPROC) (GLenum texunit, GLenum target, GLuint texture); -typedef void (APIENTRYP PFNGLENABLECLIENTSTATEINDEXEDEXTPROC) (GLenum array, GLuint index); -typedef void (APIENTRYP PFNGLDISABLECLIENTSTATEINDEXEDEXTPROC) (GLenum array, GLuint index); -typedef void (APIENTRYP PFNGLMULTITEXCOORDPOINTEREXTPROC) (GLenum texunit, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer); -typedef void (APIENTRYP PFNGLMULTITEXENVFEXTPROC) (GLenum texunit, GLenum target, GLenum pname, GLfloat param); -typedef void (APIENTRYP PFNGLMULTITEXENVFVEXTPROC) (GLenum texunit, GLenum target, GLenum pname, const GLfloat *params); -typedef void (APIENTRYP PFNGLMULTITEXENVIEXTPROC) (GLenum texunit, GLenum target, GLenum pname, GLint param); -typedef void (APIENTRYP PFNGLMULTITEXENVIVEXTPROC) (GLenum texunit, GLenum target, GLenum pname, const GLint *params); -typedef void (APIENTRYP PFNGLMULTITEXGENDEXTPROC) (GLenum texunit, GLenum coord, GLenum pname, GLdouble param); -typedef void (APIENTRYP PFNGLMULTITEXGENDVEXTPROC) (GLenum texunit, GLenum coord, GLenum pname, const GLdouble *params); -typedef void (APIENTRYP PFNGLMULTITEXGENFEXTPROC) (GLenum texunit, GLenum coord, GLenum pname, GLfloat param); -typedef void (APIENTRYP PFNGLMULTITEXGENFVEXTPROC) (GLenum texunit, GLenum coord, GLenum pname, const GLfloat *params); -typedef void (APIENTRYP PFNGLMULTITEXGENIEXTPROC) (GLenum texunit, GLenum coord, GLenum pname, GLint param); -typedef void (APIENTRYP PFNGLMULTITEXGENIVEXTPROC) (GLenum texunit, GLenum coord, GLenum pname, const GLint *params); -typedef void (APIENTRYP PFNGLGETMULTITEXENVFVEXTPROC) (GLenum texunit, GLenum target, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETMULTITEXENVIVEXTPROC) (GLenum texunit, GLenum target, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETMULTITEXGENDVEXTPROC) (GLenum texunit, GLenum coord, GLenum pname, GLdouble *params); -typedef void (APIENTRYP PFNGLGETMULTITEXGENFVEXTPROC) (GLenum texunit, GLenum coord, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETMULTITEXGENIVEXTPROC) (GLenum texunit, GLenum coord, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETFLOATINDEXEDVEXTPROC) (GLenum target, GLuint index, GLfloat *data); -typedef void (APIENTRYP PFNGLGETDOUBLEINDEXEDVEXTPROC) (GLenum target, GLuint index, GLdouble *data); -typedef void (APIENTRYP PFNGLGETPOINTERINDEXEDVEXTPROC) (GLenum target, GLuint index, GLvoid* *data); -typedef void (APIENTRYP PFNGLCOMPRESSEDTEXTUREIMAGE3DEXTPROC) (GLuint texture, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *bits); -typedef void (APIENTRYP PFNGLCOMPRESSEDTEXTUREIMAGE2DEXTPROC) (GLuint texture, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *bits); -typedef void (APIENTRYP PFNGLCOMPRESSEDTEXTUREIMAGE1DEXTPROC) (GLuint texture, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *bits); -typedef void (APIENTRYP PFNGLCOMPRESSEDTEXTURESUBIMAGE3DEXTPROC) (GLuint texture, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *bits); -typedef void (APIENTRYP PFNGLCOMPRESSEDTEXTURESUBIMAGE2DEXTPROC) (GLuint texture, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *bits); -typedef void (APIENTRYP PFNGLCOMPRESSEDTEXTURESUBIMAGE1DEXTPROC) (GLuint texture, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *bits); -typedef void (APIENTRYP PFNGLGETCOMPRESSEDTEXTUREIMAGEEXTPROC) (GLuint texture, GLenum target, GLint lod, GLvoid *img); -typedef void (APIENTRYP PFNGLCOMPRESSEDMULTITEXIMAGE3DEXTPROC) (GLenum texunit, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *bits); -typedef void (APIENTRYP PFNGLCOMPRESSEDMULTITEXIMAGE2DEXTPROC) (GLenum texunit, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *bits); -typedef void (APIENTRYP PFNGLCOMPRESSEDMULTITEXIMAGE1DEXTPROC) (GLenum texunit, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *bits); -typedef void (APIENTRYP PFNGLCOMPRESSEDMULTITEXSUBIMAGE3DEXTPROC) (GLenum texunit, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *bits); -typedef void (APIENTRYP PFNGLCOMPRESSEDMULTITEXSUBIMAGE2DEXTPROC) (GLenum texunit, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *bits); -typedef void (APIENTRYP PFNGLCOMPRESSEDMULTITEXSUBIMAGE1DEXTPROC) (GLenum texunit, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *bits); -typedef void (APIENTRYP PFNGLGETCOMPRESSEDMULTITEXIMAGEEXTPROC) (GLenum texunit, GLenum target, GLint lod, GLvoid *img); -typedef void (APIENTRYP PFNGLNAMEDPROGRAMSTRINGEXTPROC) (GLuint program, GLenum target, GLenum format, GLsizei len, const GLvoid *string); -typedef void (APIENTRYP PFNGLNAMEDPROGRAMLOCALPARAMETER4DEXTPROC) (GLuint program, GLenum target, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w); -typedef void (APIENTRYP PFNGLNAMEDPROGRAMLOCALPARAMETER4DVEXTPROC) (GLuint program, GLenum target, GLuint index, const GLdouble *params); -typedef void (APIENTRYP PFNGLNAMEDPROGRAMLOCALPARAMETER4FEXTPROC) (GLuint program, GLenum target, GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w); -typedef void (APIENTRYP PFNGLNAMEDPROGRAMLOCALPARAMETER4FVEXTPROC) (GLuint program, GLenum target, GLuint index, const GLfloat *params); -typedef void (APIENTRYP PFNGLGETNAMEDPROGRAMLOCALPARAMETERDVEXTPROC) (GLuint program, GLenum target, GLuint index, GLdouble *params); -typedef void (APIENTRYP PFNGLGETNAMEDPROGRAMLOCALPARAMETERFVEXTPROC) (GLuint program, GLenum target, GLuint index, GLfloat *params); -typedef void (APIENTRYP PFNGLGETNAMEDPROGRAMIVEXTPROC) (GLuint program, GLenum target, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETNAMEDPROGRAMSTRINGEXTPROC) (GLuint program, GLenum target, GLenum pname, GLvoid *string); -typedef void (APIENTRYP PFNGLNAMEDPROGRAMLOCALPARAMETERS4FVEXTPROC) (GLuint program, GLenum target, GLuint index, GLsizei count, const GLfloat *params); -typedef void (APIENTRYP PFNGLNAMEDPROGRAMLOCALPARAMETERI4IEXTPROC) (GLuint program, GLenum target, GLuint index, GLint x, GLint y, GLint z, GLint w); -typedef void (APIENTRYP PFNGLNAMEDPROGRAMLOCALPARAMETERI4IVEXTPROC) (GLuint program, GLenum target, GLuint index, const GLint *params); -typedef void (APIENTRYP PFNGLNAMEDPROGRAMLOCALPARAMETERSI4IVEXTPROC) (GLuint program, GLenum target, GLuint index, GLsizei count, const GLint *params); -typedef void (APIENTRYP PFNGLNAMEDPROGRAMLOCALPARAMETERI4UIEXTPROC) (GLuint program, GLenum target, GLuint index, GLuint x, GLuint y, GLuint z, GLuint w); -typedef void (APIENTRYP PFNGLNAMEDPROGRAMLOCALPARAMETERI4UIVEXTPROC) (GLuint program, GLenum target, GLuint index, const GLuint *params); -typedef void (APIENTRYP PFNGLNAMEDPROGRAMLOCALPARAMETERSI4UIVEXTPROC) (GLuint program, GLenum target, GLuint index, GLsizei count, const GLuint *params); -typedef void (APIENTRYP PFNGLGETNAMEDPROGRAMLOCALPARAMETERIIVEXTPROC) (GLuint program, GLenum target, GLuint index, GLint *params); -typedef void (APIENTRYP PFNGLGETNAMEDPROGRAMLOCALPARAMETERIUIVEXTPROC) (GLuint program, GLenum target, GLuint index, GLuint *params); -typedef void (APIENTRYP PFNGLTEXTUREPARAMETERIIVEXTPROC) (GLuint texture, GLenum target, GLenum pname, const GLint *params); -typedef void (APIENTRYP PFNGLTEXTUREPARAMETERIUIVEXTPROC) (GLuint texture, GLenum target, GLenum pname, const GLuint *params); -typedef void (APIENTRYP PFNGLGETTEXTUREPARAMETERIIVEXTPROC) (GLuint texture, GLenum target, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETTEXTUREPARAMETERIUIVEXTPROC) (GLuint texture, GLenum target, GLenum pname, GLuint *params); -typedef void (APIENTRYP PFNGLMULTITEXPARAMETERIIVEXTPROC) (GLenum texunit, GLenum target, GLenum pname, const GLint *params); -typedef void (APIENTRYP PFNGLMULTITEXPARAMETERIUIVEXTPROC) (GLenum texunit, GLenum target, GLenum pname, const GLuint *params); -typedef void (APIENTRYP PFNGLGETMULTITEXPARAMETERIIVEXTPROC) (GLenum texunit, GLenum target, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETMULTITEXPARAMETERIUIVEXTPROC) (GLenum texunit, GLenum target, GLenum pname, GLuint *params); -typedef void (APIENTRYP PFNGLPROGRAMUNIFORM1FEXTPROC) (GLuint program, GLint location, GLfloat v0); -typedef void (APIENTRYP PFNGLPROGRAMUNIFORM2FEXTPROC) (GLuint program, GLint location, GLfloat v0, GLfloat v1); -typedef void (APIENTRYP PFNGLPROGRAMUNIFORM3FEXTPROC) (GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2); -typedef void (APIENTRYP PFNGLPROGRAMUNIFORM4FEXTPROC) (GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3); -typedef void (APIENTRYP PFNGLPROGRAMUNIFORM1IEXTPROC) (GLuint program, GLint location, GLint v0); -typedef void (APIENTRYP PFNGLPROGRAMUNIFORM2IEXTPROC) (GLuint program, GLint location, GLint v0, GLint v1); -typedef void (APIENTRYP PFNGLPROGRAMUNIFORM3IEXTPROC) (GLuint program, GLint location, GLint v0, GLint v1, GLint v2); -typedef void (APIENTRYP PFNGLPROGRAMUNIFORM4IEXTPROC) (GLuint program, GLint location, GLint v0, GLint v1, GLint v2, GLint v3); -typedef void (APIENTRYP PFNGLPROGRAMUNIFORM1FVEXTPROC) (GLuint program, GLint location, GLsizei count, const GLfloat *value); -typedef void (APIENTRYP PFNGLPROGRAMUNIFORM2FVEXTPROC) (GLuint program, GLint location, GLsizei count, const GLfloat *value); -typedef void (APIENTRYP PFNGLPROGRAMUNIFORM3FVEXTPROC) (GLuint program, GLint location, GLsizei count, const GLfloat *value); -typedef void (APIENTRYP PFNGLPROGRAMUNIFORM4FVEXTPROC) (GLuint program, GLint location, GLsizei count, const GLfloat *value); -typedef void (APIENTRYP PFNGLPROGRAMUNIFORM1IVEXTPROC) (GLuint program, GLint location, GLsizei count, const GLint *value); -typedef void (APIENTRYP PFNGLPROGRAMUNIFORM2IVEXTPROC) (GLuint program, GLint location, GLsizei count, const GLint *value); -typedef void (APIENTRYP PFNGLPROGRAMUNIFORM3IVEXTPROC) (GLuint program, GLint location, GLsizei count, const GLint *value); -typedef void (APIENTRYP PFNGLPROGRAMUNIFORM4IVEXTPROC) (GLuint program, GLint location, GLsizei count, const GLint *value); -typedef void (APIENTRYP PFNGLPROGRAMUNIFORMMATRIX2FVEXTPROC) (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); -typedef void (APIENTRYP PFNGLPROGRAMUNIFORMMATRIX3FVEXTPROC) (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); -typedef void (APIENTRYP PFNGLPROGRAMUNIFORMMATRIX4FVEXTPROC) (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); -typedef void (APIENTRYP PFNGLPROGRAMUNIFORMMATRIX2X3FVEXTPROC) (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); -typedef void (APIENTRYP PFNGLPROGRAMUNIFORMMATRIX3X2FVEXTPROC) (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); -typedef void (APIENTRYP PFNGLPROGRAMUNIFORMMATRIX2X4FVEXTPROC) (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); -typedef void (APIENTRYP PFNGLPROGRAMUNIFORMMATRIX4X2FVEXTPROC) (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); -typedef void (APIENTRYP PFNGLPROGRAMUNIFORMMATRIX3X4FVEXTPROC) (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); -typedef void (APIENTRYP PFNGLPROGRAMUNIFORMMATRIX4X3FVEXTPROC) (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); -typedef void (APIENTRYP PFNGLPROGRAMUNIFORM1UIEXTPROC) (GLuint program, GLint location, GLuint v0); -typedef void (APIENTRYP PFNGLPROGRAMUNIFORM2UIEXTPROC) (GLuint program, GLint location, GLuint v0, GLuint v1); -typedef void (APIENTRYP PFNGLPROGRAMUNIFORM3UIEXTPROC) (GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2); -typedef void (APIENTRYP PFNGLPROGRAMUNIFORM4UIEXTPROC) (GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3); -typedef void (APIENTRYP PFNGLPROGRAMUNIFORM1UIVEXTPROC) (GLuint program, GLint location, GLsizei count, const GLuint *value); -typedef void (APIENTRYP PFNGLPROGRAMUNIFORM2UIVEXTPROC) (GLuint program, GLint location, GLsizei count, const GLuint *value); -typedef void (APIENTRYP PFNGLPROGRAMUNIFORM3UIVEXTPROC) (GLuint program, GLint location, GLsizei count, const GLuint *value); -typedef void (APIENTRYP PFNGLPROGRAMUNIFORM4UIVEXTPROC) (GLuint program, GLint location, GLsizei count, const GLuint *value); -typedef void (APIENTRYP PFNGLNAMEDBUFFERDATAEXTPROC) (GLuint buffer, GLsizeiptr size, const GLvoid *data, GLenum usage); -typedef void (APIENTRYP PFNGLNAMEDBUFFERSUBDATAEXTPROC) (GLuint buffer, GLintptr offset, GLsizeiptr size, const GLvoid *data); -typedef GLvoid* (APIENTRYP PFNGLMAPNAMEDBUFFEREXTPROC) (GLuint buffer, GLenum access); -typedef GLboolean (APIENTRYP PFNGLUNMAPNAMEDBUFFEREXTPROC) (GLuint buffer); -typedef void (APIENTRYP PFNGLGETNAMEDBUFFERPARAMETERIVEXTPROC) (GLuint buffer, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETNAMEDBUFFERPOINTERVEXTPROC) (GLuint buffer, GLenum pname, GLvoid* *params); -typedef void (APIENTRYP PFNGLGETNAMEDBUFFERSUBDATAEXTPROC) (GLuint buffer, GLintptr offset, GLsizeiptr size, GLvoid *data); -typedef void (APIENTRYP PFNGLTEXTUREBUFFEREXTPROC) (GLuint texture, GLenum target, GLenum internalformat, GLuint buffer); -typedef void (APIENTRYP PFNGLMULTITEXBUFFEREXTPROC) (GLenum texunit, GLenum target, GLenum internalformat, GLuint buffer); -typedef void (APIENTRYP PFNGLNAMEDRENDERBUFFERSTORAGEEXTPROC) (GLuint renderbuffer, GLenum internalformat, GLsizei width, GLsizei height); -typedef void (APIENTRYP PFNGLGETNAMEDRENDERBUFFERPARAMETERIVEXTPROC) (GLuint renderbuffer, GLenum pname, GLint *params); -typedef GLenum (APIENTRYP PFNGLCHECKNAMEDFRAMEBUFFERSTATUSEXTPROC) (GLuint framebuffer, GLenum target); -typedef void (APIENTRYP PFNGLNAMEDFRAMEBUFFERTEXTURE1DEXTPROC) (GLuint framebuffer, GLenum attachment, GLenum textarget, GLuint texture, GLint level); -typedef void (APIENTRYP PFNGLNAMEDFRAMEBUFFERTEXTURE2DEXTPROC) (GLuint framebuffer, GLenum attachment, GLenum textarget, GLuint texture, GLint level); -typedef void (APIENTRYP PFNGLNAMEDFRAMEBUFFERTEXTURE3DEXTPROC) (GLuint framebuffer, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset); -typedef void (APIENTRYP PFNGLNAMEDFRAMEBUFFERRENDERBUFFEREXTPROC) (GLuint framebuffer, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer); -typedef void (APIENTRYP PFNGLGETNAMEDFRAMEBUFFERATTACHMENTPARAMETERIVEXTPROC) (GLuint framebuffer, GLenum attachment, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGENERATETEXTUREMIPMAPEXTPROC) (GLuint texture, GLenum target); -typedef void (APIENTRYP PFNGLGENERATEMULTITEXMIPMAPEXTPROC) (GLenum texunit, GLenum target); -typedef void (APIENTRYP PFNGLFRAMEBUFFERDRAWBUFFEREXTPROC) (GLuint framebuffer, GLenum mode); -typedef void (APIENTRYP PFNGLFRAMEBUFFERDRAWBUFFERSEXTPROC) (GLuint framebuffer, GLsizei n, const GLenum *bufs); -typedef void (APIENTRYP PFNGLFRAMEBUFFERREADBUFFEREXTPROC) (GLuint framebuffer, GLenum mode); -typedef void (APIENTRYP PFNGLGETFRAMEBUFFERPARAMETERIVEXTPROC) (GLuint framebuffer, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLNAMEDRENDERBUFFERSTORAGEMULTISAMPLEEXTPROC) (GLuint renderbuffer, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height); -typedef void (APIENTRYP PFNGLNAMEDRENDERBUFFERSTORAGEMULTISAMPLECOVERAGEEXTPROC) (GLuint renderbuffer, GLsizei coverageSamples, GLsizei colorSamples, GLenum internalformat, GLsizei width, GLsizei height); -typedef void (APIENTRYP PFNGLNAMEDFRAMEBUFFERTEXTUREEXTPROC) (GLuint framebuffer, GLenum attachment, GLuint texture, GLint level); -typedef void (APIENTRYP PFNGLNAMEDFRAMEBUFFERTEXTURELAYEREXTPROC) (GLuint framebuffer, GLenum attachment, GLuint texture, GLint level, GLint layer); -typedef void (APIENTRYP PFNGLNAMEDFRAMEBUFFERTEXTUREFACEEXTPROC) (GLuint framebuffer, GLenum attachment, GLuint texture, GLint level, GLenum face); -typedef void (APIENTRYP PFNGLTEXTURERENDERBUFFEREXTPROC) (GLuint texture, GLenum target, GLuint renderbuffer); -typedef void (APIENTRYP PFNGLMULTITEXRENDERBUFFEREXTPROC) (GLenum texunit, GLenum target, GLuint renderbuffer); -#endif - -#ifndef GL_EXT_vertex_array_bgra -#define GL_EXT_vertex_array_bgra 1 -#endif - -#ifndef GL_EXT_texture_swizzle -#define GL_EXT_texture_swizzle 1 -#endif - -#ifndef GL_NV_explicit_multisample -#define GL_NV_explicit_multisample 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glGetMultisamplefvNV (GLenum, GLuint, GLfloat *); -GLAPI void APIENTRY glSampleMaskIndexedNV (GLuint, GLbitfield); -GLAPI void APIENTRY glTexRenderbufferNV (GLenum, GLuint); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLGETMULTISAMPLEFVNVPROC) (GLenum pname, GLuint index, GLfloat *val); -typedef void (APIENTRYP PFNGLSAMPLEMASKINDEXEDNVPROC) (GLuint index, GLbitfield mask); -typedef void (APIENTRYP PFNGLTEXRENDERBUFFERNVPROC) (GLenum target, GLuint renderbuffer); -#endif - -#ifndef GL_NV_transform_feedback2 -#define GL_NV_transform_feedback2 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glBindTransformFeedbackNV (GLenum, GLuint); -GLAPI void APIENTRY glDeleteTransformFeedbacksNV (GLsizei, const GLuint *); -GLAPI void APIENTRY glGenTransformFeedbacksNV (GLsizei, GLuint *); -GLAPI GLboolean APIENTRY glIsTransformFeedbackNV (GLuint); -GLAPI void APIENTRY glPauseTransformFeedbackNV (void); -GLAPI void APIENTRY glResumeTransformFeedbackNV (void); -GLAPI void APIENTRY glDrawTransformFeedbackNV (GLenum, GLuint); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLBINDTRANSFORMFEEDBACKNVPROC) (GLenum target, GLuint id); -typedef void (APIENTRYP PFNGLDELETETRANSFORMFEEDBACKSNVPROC) (GLsizei n, const GLuint *ids); -typedef void (APIENTRYP PFNGLGENTRANSFORMFEEDBACKSNVPROC) (GLsizei n, GLuint *ids); -typedef GLboolean (APIENTRYP PFNGLISTRANSFORMFEEDBACKNVPROC) (GLuint id); -typedef void (APIENTRYP PFNGLPAUSETRANSFORMFEEDBACKNVPROC) (void); -typedef void (APIENTRYP PFNGLRESUMETRANSFORMFEEDBACKNVPROC) (void); -typedef void (APIENTRYP PFNGLDRAWTRANSFORMFEEDBACKNVPROC) (GLenum mode, GLuint id); -#endif - - -#ifdef __cplusplus -} -#endif - -#endif - +#ifndef __glext_h_ +#define __glext_h_ + +#ifdef __cplusplus +extern "C" { +#endif + +/* +** Copyright (c) 2007 The Khronos Group Inc. +** +** Permission is hereby granted, free of charge, to any person obtaining a +** copy of this software and/or associated documentation files (the +** "Materials"), to deal in the Materials without restriction, including +** without limitation the rights to use, copy, modify, merge, publish, +** distribute, sublicense, and/or sell copies of the Materials, and to +** permit persons to whom the Materials are furnished to do so, subject to +** the following conditions: +** +** The above copyright notice and this permission notice shall be included +** in all copies or substantial portions of the Materials. +** +** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. +** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY +** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, +** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE +** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS. +*/ + +#if defined(_WIN32) && !defined(APIENTRY) && !defined(__CYGWIN__) && !defined(__SCITECH_SNAP__) +#define WIN32_LEAN_AND_MEAN 1 +#include +#endif + +#ifndef APIENTRY +#define APIENTRY +#endif +#ifndef APIENTRYP +#define APIENTRYP APIENTRY * +#endif +#ifndef GLAPI +#define GLAPI extern +#endif + +/*************************************************************/ + +/* Header file version number, required by OpenGL ABI for Linux */ +/* glext.h last updated 2008/11/14 */ +/* Current version at http://www.opengl.org/registry/ */ +#define GL_GLEXT_VERSION 44 + +#ifndef GL_VERSION_1_2 +#define GL_UNSIGNED_BYTE_3_3_2 0x8032 +#define GL_UNSIGNED_SHORT_4_4_4_4 0x8033 +#define GL_UNSIGNED_SHORT_5_5_5_1 0x8034 +#define GL_UNSIGNED_INT_8_8_8_8 0x8035 +#define GL_UNSIGNED_INT_10_10_10_2 0x8036 +#define GL_RESCALE_NORMAL 0x803A +#define GL_TEXTURE_BINDING_3D 0x806A +#define GL_PACK_SKIP_IMAGES 0x806B +#define GL_PACK_IMAGE_HEIGHT 0x806C +#define GL_UNPACK_SKIP_IMAGES 0x806D +#define GL_UNPACK_IMAGE_HEIGHT 0x806E +#define GL_TEXTURE_3D 0x806F +#define GL_PROXY_TEXTURE_3D 0x8070 +#define GL_TEXTURE_DEPTH 0x8071 +#define GL_TEXTURE_WRAP_R 0x8072 +#define GL_MAX_3D_TEXTURE_SIZE 0x8073 +#define GL_UNSIGNED_BYTE_2_3_3_REV 0x8362 +#define GL_UNSIGNED_SHORT_5_6_5 0x8363 +#define GL_UNSIGNED_SHORT_5_6_5_REV 0x8364 +#define GL_UNSIGNED_SHORT_4_4_4_4_REV 0x8365 +#define GL_UNSIGNED_SHORT_1_5_5_5_REV 0x8366 +#define GL_UNSIGNED_INT_8_8_8_8_REV 0x8367 +#define GL_UNSIGNED_INT_2_10_10_10_REV 0x8368 +#define GL_BGR 0x80E0 +#define GL_BGRA 0x80E1 +#define GL_MAX_ELEMENTS_VERTICES 0x80E8 +#define GL_MAX_ELEMENTS_INDICES 0x80E9 +#define GL_CLAMP_TO_EDGE 0x812F +#define GL_TEXTURE_MIN_LOD 0x813A +#define GL_TEXTURE_MAX_LOD 0x813B +#define GL_TEXTURE_BASE_LEVEL 0x813C +#define GL_TEXTURE_MAX_LEVEL 0x813D +#define GL_LIGHT_MODEL_COLOR_CONTROL 0x81F8 +#define GL_SINGLE_COLOR 0x81F9 +#define GL_SEPARATE_SPECULAR_COLOR 0x81FA +#define GL_SMOOTH_POINT_SIZE_RANGE 0x0B12 +#define GL_SMOOTH_POINT_SIZE_GRANULARITY 0x0B13 +#define GL_SMOOTH_LINE_WIDTH_RANGE 0x0B22 +#define GL_SMOOTH_LINE_WIDTH_GRANULARITY 0x0B23 +#define GL_ALIASED_POINT_SIZE_RANGE 0x846D +#define GL_ALIASED_LINE_WIDTH_RANGE 0x846E +#endif + +#ifndef GL_ARB_imaging +#define GL_CONSTANT_COLOR 0x8001 +#define GL_ONE_MINUS_CONSTANT_COLOR 0x8002 +#define GL_CONSTANT_ALPHA 0x8003 +#define GL_ONE_MINUS_CONSTANT_ALPHA 0x8004 +#define GL_BLEND_COLOR 0x8005 +#define GL_FUNC_ADD 0x8006 +#define GL_MIN 0x8007 +#define GL_MAX 0x8008 +#define GL_BLEND_EQUATION 0x8009 +#define GL_FUNC_SUBTRACT 0x800A +#define GL_FUNC_REVERSE_SUBTRACT 0x800B +#define GL_CONVOLUTION_1D 0x8010 +#define GL_CONVOLUTION_2D 0x8011 +#define GL_SEPARABLE_2D 0x8012 +#define GL_CONVOLUTION_BORDER_MODE 0x8013 +#define GL_CONVOLUTION_FILTER_SCALE 0x8014 +#define GL_CONVOLUTION_FILTER_BIAS 0x8015 +#define GL_REDUCE 0x8016 +#define GL_CONVOLUTION_FORMAT 0x8017 +#define GL_CONVOLUTION_WIDTH 0x8018 +#define GL_CONVOLUTION_HEIGHT 0x8019 +#define GL_MAX_CONVOLUTION_WIDTH 0x801A +#define GL_MAX_CONVOLUTION_HEIGHT 0x801B +#define GL_POST_CONVOLUTION_RED_SCALE 0x801C +#define GL_POST_CONVOLUTION_GREEN_SCALE 0x801D +#define GL_POST_CONVOLUTION_BLUE_SCALE 0x801E +#define GL_POST_CONVOLUTION_ALPHA_SCALE 0x801F +#define GL_POST_CONVOLUTION_RED_BIAS 0x8020 +#define GL_POST_CONVOLUTION_GREEN_BIAS 0x8021 +#define GL_POST_CONVOLUTION_BLUE_BIAS 0x8022 +#define GL_POST_CONVOLUTION_ALPHA_BIAS 0x8023 +#define GL_HISTOGRAM 0x8024 +#define GL_PROXY_HISTOGRAM 0x8025 +#define GL_HISTOGRAM_WIDTH 0x8026 +#define GL_HISTOGRAM_FORMAT 0x8027 +#define GL_HISTOGRAM_RED_SIZE 0x8028 +#define GL_HISTOGRAM_GREEN_SIZE 0x8029 +#define GL_HISTOGRAM_BLUE_SIZE 0x802A +#define GL_HISTOGRAM_ALPHA_SIZE 0x802B +#define GL_HISTOGRAM_LUMINANCE_SIZE 0x802C +#define GL_HISTOGRAM_SINK 0x802D +#define GL_MINMAX 0x802E +#define GL_MINMAX_FORMAT 0x802F +#define GL_MINMAX_SINK 0x8030 +#define GL_TABLE_TOO_LARGE 0x8031 +#define GL_COLOR_MATRIX 0x80B1 +#define GL_COLOR_MATRIX_STACK_DEPTH 0x80B2 +#define GL_MAX_COLOR_MATRIX_STACK_DEPTH 0x80B3 +#define GL_POST_COLOR_MATRIX_RED_SCALE 0x80B4 +#define GL_POST_COLOR_MATRIX_GREEN_SCALE 0x80B5 +#define GL_POST_COLOR_MATRIX_BLUE_SCALE 0x80B6 +#define GL_POST_COLOR_MATRIX_ALPHA_SCALE 0x80B7 +#define GL_POST_COLOR_MATRIX_RED_BIAS 0x80B8 +#define GL_POST_COLOR_MATRIX_GREEN_BIAS 0x80B9 +#define GL_POST_COLOR_MATRIX_BLUE_BIAS 0x80BA +#define GL_POST_COLOR_MATRIX_ALPHA_BIAS 0x80BB +#define GL_COLOR_TABLE 0x80D0 +#define GL_POST_CONVOLUTION_COLOR_TABLE 0x80D1 +#define GL_POST_COLOR_MATRIX_COLOR_TABLE 0x80D2 +#define GL_PROXY_COLOR_TABLE 0x80D3 +#define GL_PROXY_POST_CONVOLUTION_COLOR_TABLE 0x80D4 +#define GL_PROXY_POST_COLOR_MATRIX_COLOR_TABLE 0x80D5 +#define GL_COLOR_TABLE_SCALE 0x80D6 +#define GL_COLOR_TABLE_BIAS 0x80D7 +#define GL_COLOR_TABLE_FORMAT 0x80D8 +#define GL_COLOR_TABLE_WIDTH 0x80D9 +#define GL_COLOR_TABLE_RED_SIZE 0x80DA +#define GL_COLOR_TABLE_GREEN_SIZE 0x80DB +#define GL_COLOR_TABLE_BLUE_SIZE 0x80DC +#define GL_COLOR_TABLE_ALPHA_SIZE 0x80DD +#define GL_COLOR_TABLE_LUMINANCE_SIZE 0x80DE +#define GL_COLOR_TABLE_INTENSITY_SIZE 0x80DF +#define GL_CONSTANT_BORDER 0x8151 +#define GL_REPLICATE_BORDER 0x8153 +#define GL_CONVOLUTION_BORDER_COLOR 0x8154 +#endif + +#ifndef GL_VERSION_1_3 +#define GL_TEXTURE0 0x84C0 +#define GL_TEXTURE1 0x84C1 +#define GL_TEXTURE2 0x84C2 +#define GL_TEXTURE3 0x84C3 +#define GL_TEXTURE4 0x84C4 +#define GL_TEXTURE5 0x84C5 +#define GL_TEXTURE6 0x84C6 +#define GL_TEXTURE7 0x84C7 +#define GL_TEXTURE8 0x84C8 +#define GL_TEXTURE9 0x84C9 +#define GL_TEXTURE10 0x84CA +#define GL_TEXTURE11 0x84CB +#define GL_TEXTURE12 0x84CC +#define GL_TEXTURE13 0x84CD +#define GL_TEXTURE14 0x84CE +#define GL_TEXTURE15 0x84CF +#define GL_TEXTURE16 0x84D0 +#define GL_TEXTURE17 0x84D1 +#define GL_TEXTURE18 0x84D2 +#define GL_TEXTURE19 0x84D3 +#define GL_TEXTURE20 0x84D4 +#define GL_TEXTURE21 0x84D5 +#define GL_TEXTURE22 0x84D6 +#define GL_TEXTURE23 0x84D7 +#define GL_TEXTURE24 0x84D8 +#define GL_TEXTURE25 0x84D9 +#define GL_TEXTURE26 0x84DA +#define GL_TEXTURE27 0x84DB +#define GL_TEXTURE28 0x84DC +#define GL_TEXTURE29 0x84DD +#define GL_TEXTURE30 0x84DE +#define GL_TEXTURE31 0x84DF +#define GL_ACTIVE_TEXTURE 0x84E0 +#define GL_CLIENT_ACTIVE_TEXTURE 0x84E1 +#define GL_MAX_TEXTURE_UNITS 0x84E2 +#define GL_TRANSPOSE_MODELVIEW_MATRIX 0x84E3 +#define GL_TRANSPOSE_PROJECTION_MATRIX 0x84E4 +#define GL_TRANSPOSE_TEXTURE_MATRIX 0x84E5 +#define GL_TRANSPOSE_COLOR_MATRIX 0x84E6 +#define GL_MULTISAMPLE 0x809D +#define GL_SAMPLE_ALPHA_TO_COVERAGE 0x809E +#define GL_SAMPLE_ALPHA_TO_ONE 0x809F +#define GL_SAMPLE_COVERAGE 0x80A0 +#define GL_SAMPLE_BUFFERS 0x80A8 +#define GL_SAMPLES 0x80A9 +#define GL_SAMPLE_COVERAGE_VALUE 0x80AA +#define GL_SAMPLE_COVERAGE_INVERT 0x80AB +#define GL_MULTISAMPLE_BIT 0x20000000 +#define GL_NORMAL_MAP 0x8511 +#define GL_REFLECTION_MAP 0x8512 +#define GL_TEXTURE_CUBE_MAP 0x8513 +#define GL_TEXTURE_BINDING_CUBE_MAP 0x8514 +#define GL_TEXTURE_CUBE_MAP_POSITIVE_X 0x8515 +#define GL_TEXTURE_CUBE_MAP_NEGATIVE_X 0x8516 +#define GL_TEXTURE_CUBE_MAP_POSITIVE_Y 0x8517 +#define GL_TEXTURE_CUBE_MAP_NEGATIVE_Y 0x8518 +#define GL_TEXTURE_CUBE_MAP_POSITIVE_Z 0x8519 +#define GL_TEXTURE_CUBE_MAP_NEGATIVE_Z 0x851A +#define GL_PROXY_TEXTURE_CUBE_MAP 0x851B +#define GL_MAX_CUBE_MAP_TEXTURE_SIZE 0x851C +#define GL_COMPRESSED_ALPHA 0x84E9 +#define GL_COMPRESSED_LUMINANCE 0x84EA +#define GL_COMPRESSED_LUMINANCE_ALPHA 0x84EB +#define GL_COMPRESSED_INTENSITY 0x84EC +#define GL_COMPRESSED_RGB 0x84ED +#define GL_COMPRESSED_RGBA 0x84EE +#define GL_TEXTURE_COMPRESSION_HINT 0x84EF +#define GL_TEXTURE_COMPRESSED_IMAGE_SIZE 0x86A0 +#define GL_TEXTURE_COMPRESSED 0x86A1 +#define GL_NUM_COMPRESSED_TEXTURE_FORMATS 0x86A2 +#define GL_COMPRESSED_TEXTURE_FORMATS 0x86A3 +#define GL_CLAMP_TO_BORDER 0x812D +#define GL_COMBINE 0x8570 +#define GL_COMBINE_RGB 0x8571 +#define GL_COMBINE_ALPHA 0x8572 +#define GL_SOURCE0_RGB 0x8580 +#define GL_SOURCE1_RGB 0x8581 +#define GL_SOURCE2_RGB 0x8582 +#define GL_SOURCE0_ALPHA 0x8588 +#define GL_SOURCE1_ALPHA 0x8589 +#define GL_SOURCE2_ALPHA 0x858A +#define GL_OPERAND0_RGB 0x8590 +#define GL_OPERAND1_RGB 0x8591 +#define GL_OPERAND2_RGB 0x8592 +#define GL_OPERAND0_ALPHA 0x8598 +#define GL_OPERAND1_ALPHA 0x8599 +#define GL_OPERAND2_ALPHA 0x859A +#define GL_RGB_SCALE 0x8573 +#define GL_ADD_SIGNED 0x8574 +#define GL_INTERPOLATE 0x8575 +#define GL_SUBTRACT 0x84E7 +#define GL_CONSTANT 0x8576 +#define GL_PRIMARY_COLOR 0x8577 +#define GL_PREVIOUS 0x8578 +#define GL_DOT3_RGB 0x86AE +#define GL_DOT3_RGBA 0x86AF +#endif + +#ifndef GL_VERSION_1_4 +#define GL_BLEND_DST_RGB 0x80C8 +#define GL_BLEND_SRC_RGB 0x80C9 +#define GL_BLEND_DST_ALPHA 0x80CA +#define GL_BLEND_SRC_ALPHA 0x80CB +#define GL_POINT_SIZE_MIN 0x8126 +#define GL_POINT_SIZE_MAX 0x8127 +#define GL_POINT_FADE_THRESHOLD_SIZE 0x8128 +#define GL_POINT_DISTANCE_ATTENUATION 0x8129 +#define GL_GENERATE_MIPMAP 0x8191 +#define GL_GENERATE_MIPMAP_HINT 0x8192 +#define GL_DEPTH_COMPONENT16 0x81A5 +#define GL_DEPTH_COMPONENT24 0x81A6 +#define GL_DEPTH_COMPONENT32 0x81A7 +#define GL_MIRRORED_REPEAT 0x8370 +#define GL_FOG_COORDINATE_SOURCE 0x8450 +#define GL_FOG_COORDINATE 0x8451 +#define GL_FRAGMENT_DEPTH 0x8452 +#define GL_CURRENT_FOG_COORDINATE 0x8453 +#define GL_FOG_COORDINATE_ARRAY_TYPE 0x8454 +#define GL_FOG_COORDINATE_ARRAY_STRIDE 0x8455 +#define GL_FOG_COORDINATE_ARRAY_POINTER 0x8456 +#define GL_FOG_COORDINATE_ARRAY 0x8457 +#define GL_COLOR_SUM 0x8458 +#define GL_CURRENT_SECONDARY_COLOR 0x8459 +#define GL_SECONDARY_COLOR_ARRAY_SIZE 0x845A +#define GL_SECONDARY_COLOR_ARRAY_TYPE 0x845B +#define GL_SECONDARY_COLOR_ARRAY_STRIDE 0x845C +#define GL_SECONDARY_COLOR_ARRAY_POINTER 0x845D +#define GL_SECONDARY_COLOR_ARRAY 0x845E +#define GL_MAX_TEXTURE_LOD_BIAS 0x84FD +#define GL_TEXTURE_FILTER_CONTROL 0x8500 +#define GL_TEXTURE_LOD_BIAS 0x8501 +#define GL_INCR_WRAP 0x8507 +#define GL_DECR_WRAP 0x8508 +#define GL_TEXTURE_DEPTH_SIZE 0x884A +#define GL_DEPTH_TEXTURE_MODE 0x884B +#define GL_TEXTURE_COMPARE_MODE 0x884C +#define GL_TEXTURE_COMPARE_FUNC 0x884D +#define GL_COMPARE_R_TO_TEXTURE 0x884E +#endif + +#ifndef GL_VERSION_1_5 +#define GL_BUFFER_SIZE 0x8764 +#define GL_BUFFER_USAGE 0x8765 +#define GL_QUERY_COUNTER_BITS 0x8864 +#define GL_CURRENT_QUERY 0x8865 +#define GL_QUERY_RESULT 0x8866 +#define GL_QUERY_RESULT_AVAILABLE 0x8867 +#define GL_ARRAY_BUFFER 0x8892 +#define GL_ELEMENT_ARRAY_BUFFER 0x8893 +#define GL_ARRAY_BUFFER_BINDING 0x8894 +#define GL_ELEMENT_ARRAY_BUFFER_BINDING 0x8895 +#define GL_VERTEX_ARRAY_BUFFER_BINDING 0x8896 +#define GL_NORMAL_ARRAY_BUFFER_BINDING 0x8897 +#define GL_COLOR_ARRAY_BUFFER_BINDING 0x8898 +#define GL_INDEX_ARRAY_BUFFER_BINDING 0x8899 +#define GL_TEXTURE_COORD_ARRAY_BUFFER_BINDING 0x889A +#define GL_EDGE_FLAG_ARRAY_BUFFER_BINDING 0x889B +#define GL_SECONDARY_COLOR_ARRAY_BUFFER_BINDING 0x889C +#define GL_FOG_COORDINATE_ARRAY_BUFFER_BINDING 0x889D +#define GL_WEIGHT_ARRAY_BUFFER_BINDING 0x889E +#define GL_VERTEX_ATTRIB_ARRAY_BUFFER_BINDING 0x889F +#define GL_READ_ONLY 0x88B8 +#define GL_WRITE_ONLY 0x88B9 +#define GL_READ_WRITE 0x88BA +#define GL_BUFFER_ACCESS 0x88BB +#define GL_BUFFER_MAPPED 0x88BC +#define GL_BUFFER_MAP_POINTER 0x88BD +#define GL_STREAM_DRAW 0x88E0 +#define GL_STREAM_READ 0x88E1 +#define GL_STREAM_COPY 0x88E2 +#define GL_STATIC_DRAW 0x88E4 +#define GL_STATIC_READ 0x88E5 +#define GL_STATIC_COPY 0x88E6 +#define GL_DYNAMIC_DRAW 0x88E8 +#define GL_DYNAMIC_READ 0x88E9 +#define GL_DYNAMIC_COPY 0x88EA +#define GL_SAMPLES_PASSED 0x8914 +#define GL_FOG_COORD_SRC GL_FOG_COORDINATE_SOURCE +#define GL_FOG_COORD GL_FOG_COORDINATE +#define GL_CURRENT_FOG_COORD GL_CURRENT_FOG_COORDINATE +#define GL_FOG_COORD_ARRAY_TYPE GL_FOG_COORDINATE_ARRAY_TYPE +#define GL_FOG_COORD_ARRAY_STRIDE GL_FOG_COORDINATE_ARRAY_STRIDE +#define GL_FOG_COORD_ARRAY_POINTER GL_FOG_COORDINATE_ARRAY_POINTER +#define GL_FOG_COORD_ARRAY GL_FOG_COORDINATE_ARRAY +#define GL_FOG_COORD_ARRAY_BUFFER_BINDING GL_FOG_COORDINATE_ARRAY_BUFFER_BINDING +#define GL_SRC0_RGB GL_SOURCE0_RGB +#define GL_SRC1_RGB GL_SOURCE1_RGB +#define GL_SRC2_RGB GL_SOURCE2_RGB +#define GL_SRC0_ALPHA GL_SOURCE0_ALPHA +#define GL_SRC1_ALPHA GL_SOURCE1_ALPHA +#define GL_SRC2_ALPHA GL_SOURCE2_ALPHA +#endif + +#ifndef GL_VERSION_2_0 +#define GL_BLEND_EQUATION_RGB GL_BLEND_EQUATION +#define GL_VERTEX_ATTRIB_ARRAY_ENABLED 0x8622 +#define GL_VERTEX_ATTRIB_ARRAY_SIZE 0x8623 +#define GL_VERTEX_ATTRIB_ARRAY_STRIDE 0x8624 +#define GL_VERTEX_ATTRIB_ARRAY_TYPE 0x8625 +#define GL_CURRENT_VERTEX_ATTRIB 0x8626 +#define GL_VERTEX_PROGRAM_POINT_SIZE 0x8642 +#define GL_VERTEX_PROGRAM_TWO_SIDE 0x8643 +#define GL_VERTEX_ATTRIB_ARRAY_POINTER 0x8645 +#define GL_STENCIL_BACK_FUNC 0x8800 +#define GL_STENCIL_BACK_FAIL 0x8801 +#define GL_STENCIL_BACK_PASS_DEPTH_FAIL 0x8802 +#define GL_STENCIL_BACK_PASS_DEPTH_PASS 0x8803 +#define GL_MAX_DRAW_BUFFERS 0x8824 +#define GL_DRAW_BUFFER0 0x8825 +#define GL_DRAW_BUFFER1 0x8826 +#define GL_DRAW_BUFFER2 0x8827 +#define GL_DRAW_BUFFER3 0x8828 +#define GL_DRAW_BUFFER4 0x8829 +#define GL_DRAW_BUFFER5 0x882A +#define GL_DRAW_BUFFER6 0x882B +#define GL_DRAW_BUFFER7 0x882C +#define GL_DRAW_BUFFER8 0x882D +#define GL_DRAW_BUFFER9 0x882E +#define GL_DRAW_BUFFER10 0x882F +#define GL_DRAW_BUFFER11 0x8830 +#define GL_DRAW_BUFFER12 0x8831 +#define GL_DRAW_BUFFER13 0x8832 +#define GL_DRAW_BUFFER14 0x8833 +#define GL_DRAW_BUFFER15 0x8834 +#define GL_BLEND_EQUATION_ALPHA 0x883D +#define GL_POINT_SPRITE 0x8861 +#define GL_COORD_REPLACE 0x8862 +#define GL_MAX_VERTEX_ATTRIBS 0x8869 +#define GL_VERTEX_ATTRIB_ARRAY_NORMALIZED 0x886A +#define GL_MAX_TEXTURE_COORDS 0x8871 +#define GL_MAX_TEXTURE_IMAGE_UNITS 0x8872 +#define GL_FRAGMENT_SHADER 0x8B30 +#define GL_VERTEX_SHADER 0x8B31 +#define GL_MAX_FRAGMENT_UNIFORM_COMPONENTS 0x8B49 +#define GL_MAX_VERTEX_UNIFORM_COMPONENTS 0x8B4A +#define GL_MAX_VARYING_FLOATS 0x8B4B +#define GL_MAX_VERTEX_TEXTURE_IMAGE_UNITS 0x8B4C +#define GL_MAX_COMBINED_TEXTURE_IMAGE_UNITS 0x8B4D +#define GL_SHADER_TYPE 0x8B4F +#define GL_FLOAT_VEC2 0x8B50 +#define GL_FLOAT_VEC3 0x8B51 +#define GL_FLOAT_VEC4 0x8B52 +#define GL_INT_VEC2 0x8B53 +#define GL_INT_VEC3 0x8B54 +#define GL_INT_VEC4 0x8B55 +#define GL_BOOL 0x8B56 +#define GL_BOOL_VEC2 0x8B57 +#define GL_BOOL_VEC3 0x8B58 +#define GL_BOOL_VEC4 0x8B59 +#define GL_FLOAT_MAT2 0x8B5A +#define GL_FLOAT_MAT3 0x8B5B +#define GL_FLOAT_MAT4 0x8B5C +#define GL_SAMPLER_1D 0x8B5D +#define GL_SAMPLER_2D 0x8B5E +#define GL_SAMPLER_3D 0x8B5F +#define GL_SAMPLER_CUBE 0x8B60 +#define GL_SAMPLER_1D_SHADOW 0x8B61 +#define GL_SAMPLER_2D_SHADOW 0x8B62 +#define GL_DELETE_STATUS 0x8B80 +#define GL_COMPILE_STATUS 0x8B81 +#define GL_LINK_STATUS 0x8B82 +#define GL_VALIDATE_STATUS 0x8B83 +#define GL_INFO_LOG_LENGTH 0x8B84 +#define GL_ATTACHED_SHADERS 0x8B85 +#define GL_ACTIVE_UNIFORMS 0x8B86 +#define GL_ACTIVE_UNIFORM_MAX_LENGTH 0x8B87 +#define GL_SHADER_SOURCE_LENGTH 0x8B88 +#define GL_ACTIVE_ATTRIBUTES 0x8B89 +#define GL_ACTIVE_ATTRIBUTE_MAX_LENGTH 0x8B8A +#define GL_FRAGMENT_SHADER_DERIVATIVE_HINT 0x8B8B +#define GL_SHADING_LANGUAGE_VERSION 0x8B8C +#define GL_CURRENT_PROGRAM 0x8B8D +#define GL_POINT_SPRITE_COORD_ORIGIN 0x8CA0 +#define GL_LOWER_LEFT 0x8CA1 +#define GL_UPPER_LEFT 0x8CA2 +#define GL_STENCIL_BACK_REF 0x8CA3 +#define GL_STENCIL_BACK_VALUE_MASK 0x8CA4 +#define GL_STENCIL_BACK_WRITEMASK 0x8CA5 +#endif + +#ifndef GL_VERSION_2_1 +#define GL_CURRENT_RASTER_SECONDARY_COLOR 0x845F +#define GL_PIXEL_PACK_BUFFER 0x88EB +#define GL_PIXEL_UNPACK_BUFFER 0x88EC +#define GL_PIXEL_PACK_BUFFER_BINDING 0x88ED +#define GL_PIXEL_UNPACK_BUFFER_BINDING 0x88EF +#define GL_FLOAT_MAT2x3 0x8B65 +#define GL_FLOAT_MAT2x4 0x8B66 +#define GL_FLOAT_MAT3x2 0x8B67 +#define GL_FLOAT_MAT3x4 0x8B68 +#define GL_FLOAT_MAT4x2 0x8B69 +#define GL_FLOAT_MAT4x3 0x8B6A +#define GL_SRGB 0x8C40 +#define GL_SRGB8 0x8C41 +#define GL_SRGB_ALPHA 0x8C42 +#define GL_SRGB8_ALPHA8 0x8C43 +#define GL_SLUMINANCE_ALPHA 0x8C44 +#define GL_SLUMINANCE8_ALPHA8 0x8C45 +#define GL_SLUMINANCE 0x8C46 +#define GL_SLUMINANCE8 0x8C47 +#define GL_COMPRESSED_SRGB 0x8C48 +#define GL_COMPRESSED_SRGB_ALPHA 0x8C49 +#define GL_COMPRESSED_SLUMINANCE 0x8C4A +#define GL_COMPRESSED_SLUMINANCE_ALPHA 0x8C4B +#endif + +#ifndef GL_VERSION_3_0 +#define GL_COMPARE_REF_TO_TEXTURE GL_COMPARE_R_TO_TEXTURE_ARB +#define GL_CLIP_DISTANCE0 GL_CLIP_PLANE0 +#define GL_CLIP_DISTANCE1 GL_CLIP_PLANE1 +#define GL_CLIP_DISTANCE2 GL_CLIP_PLANE2 +#define GL_CLIP_DISTANCE3 GL_CLIP_PLANE3 +#define GL_CLIP_DISTANCE4 GL_CLIP_PLANE4 +#define GL_CLIP_DISTANCE5 GL_CLIP_PLANE5 +#define GL_MAX_CLIP_DISTANCES GL_MAX_CLIP_PLANES +#define GL_MAJOR_VERSION 0x821B +#define GL_MINOR_VERSION 0x821C +#define GL_NUM_EXTENSIONS 0x821D +#define GL_CONTEXT_FLAGS 0x821E +#define GL_DEPTH_BUFFER 0x8223 +#define GL_STENCIL_BUFFER 0x8224 +#define GL_COMPRESSED_RED 0x8225 +#define GL_COMPRESSED_RG 0x8226 +#define GL_CONTEXT_FLAG_FORWARD_COMPATIBLE_BIT 0x0001 +#define GL_RGBA32F 0x8814 +#define GL_RGB32F 0x8815 +#define GL_RGBA16F 0x881A +#define GL_RGB16F 0x881B +#define GL_VERTEX_ATTRIB_ARRAY_INTEGER 0x88FD +#define GL_MAX_ARRAY_TEXTURE_LAYERS 0x88FF +#define GL_MIN_PROGRAM_TEXEL_OFFSET 0x8904 +#define GL_MAX_PROGRAM_TEXEL_OFFSET 0x8905 +#define GL_CLAMP_VERTEX_COLOR 0x891A +#define GL_CLAMP_FRAGMENT_COLOR 0x891B +#define GL_CLAMP_READ_COLOR 0x891C +#define GL_FIXED_ONLY 0x891D +#define GL_MAX_VARYING_COMPONENTS GL_MAX_VARYING_FLOATS +#define GL_TEXTURE_RED_TYPE 0x8C10 +#define GL_TEXTURE_GREEN_TYPE 0x8C11 +#define GL_TEXTURE_BLUE_TYPE 0x8C12 +#define GL_TEXTURE_ALPHA_TYPE 0x8C13 +#define GL_TEXTURE_LUMINANCE_TYPE 0x8C14 +#define GL_TEXTURE_INTENSITY_TYPE 0x8C15 +#define GL_TEXTURE_DEPTH_TYPE 0x8C16 +#define GL_UNSIGNED_NORMALIZED 0x8C17 +#define GL_TEXTURE_1D_ARRAY 0x8C18 +#define GL_PROXY_TEXTURE_1D_ARRAY 0x8C19 +#define GL_TEXTURE_2D_ARRAY 0x8C1A +#define GL_PROXY_TEXTURE_2D_ARRAY 0x8C1B +#define GL_TEXTURE_BINDING_1D_ARRAY 0x8C1C +#define GL_TEXTURE_BINDING_2D_ARRAY 0x8C1D +#define GL_R11F_G11F_B10F 0x8C3A +#define GL_UNSIGNED_INT_10F_11F_11F_REV 0x8C3B +#define GL_RGB9_E5 0x8C3D +#define GL_UNSIGNED_INT_5_9_9_9_REV 0x8C3E +#define GL_TEXTURE_SHARED_SIZE 0x8C3F +#define GL_TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH 0x8C76 +#define GL_TRANSFORM_FEEDBACK_BUFFER_MODE 0x8C7F +#define GL_MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS 0x8C80 +#define GL_TRANSFORM_FEEDBACK_VARYINGS 0x8C83 +#define GL_TRANSFORM_FEEDBACK_BUFFER_START 0x8C84 +#define GL_TRANSFORM_FEEDBACK_BUFFER_SIZE 0x8C85 +#define GL_PRIMITIVES_GENERATED 0x8C87 +#define GL_TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN 0x8C88 +#define GL_RASTERIZER_DISCARD 0x8C89 +#define GL_MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS 0x8C8A +#define GL_MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS 0x8C8B +#define GL_INTERLEAVED_ATTRIBS 0x8C8C +#define GL_SEPARATE_ATTRIBS 0x8C8D +#define GL_TRANSFORM_FEEDBACK_BUFFER 0x8C8E +#define GL_TRANSFORM_FEEDBACK_BUFFER_BINDING 0x8C8F +#define GL_RGBA32UI 0x8D70 +#define GL_RGB32UI 0x8D71 +#define GL_RGBA16UI 0x8D76 +#define GL_RGB16UI 0x8D77 +#define GL_RGBA8UI 0x8D7C +#define GL_RGB8UI 0x8D7D +#define GL_RGBA32I 0x8D82 +#define GL_RGB32I 0x8D83 +#define GL_RGBA16I 0x8D88 +#define GL_RGB16I 0x8D89 +#define GL_RGBA8I 0x8D8E +#define GL_RGB8I 0x8D8F +#define GL_RED_INTEGER 0x8D94 +#define GL_GREEN_INTEGER 0x8D95 +#define GL_BLUE_INTEGER 0x8D96 +#define GL_ALPHA_INTEGER 0x8D97 +#define GL_RGB_INTEGER 0x8D98 +#define GL_RGBA_INTEGER 0x8D99 +#define GL_BGR_INTEGER 0x8D9A +#define GL_BGRA_INTEGER 0x8D9B +#define GL_SAMPLER_1D_ARRAY 0x8DC0 +#define GL_SAMPLER_2D_ARRAY 0x8DC1 +#define GL_SAMPLER_1D_ARRAY_SHADOW 0x8DC3 +#define GL_SAMPLER_2D_ARRAY_SHADOW 0x8DC4 +#define GL_SAMPLER_CUBE_SHADOW 0x8DC5 +#define GL_UNSIGNED_INT_VEC2 0x8DC6 +#define GL_UNSIGNED_INT_VEC3 0x8DC7 +#define GL_UNSIGNED_INT_VEC4 0x8DC8 +#define GL_INT_SAMPLER_1D 0x8DC9 +#define GL_INT_SAMPLER_2D 0x8DCA +#define GL_INT_SAMPLER_3D 0x8DCB +#define GL_INT_SAMPLER_CUBE 0x8DCC +#define GL_INT_SAMPLER_1D_ARRAY 0x8DCE +#define GL_INT_SAMPLER_2D_ARRAY 0x8DCF +#define GL_UNSIGNED_INT_SAMPLER_1D 0x8DD1 +#define GL_UNSIGNED_INT_SAMPLER_2D 0x8DD2 +#define GL_UNSIGNED_INT_SAMPLER_3D 0x8DD3 +#define GL_UNSIGNED_INT_SAMPLER_CUBE 0x8DD4 +#define GL_UNSIGNED_INT_SAMPLER_1D_ARRAY 0x8DD6 +#define GL_UNSIGNED_INT_SAMPLER_2D_ARRAY 0x8DD7 +#define GL_QUERY_WAIT 0x8E13 +#define GL_QUERY_NO_WAIT 0x8E14 +#define GL_QUERY_BY_REGION_WAIT 0x8E15 +#define GL_QUERY_BY_REGION_NO_WAIT 0x8E16 +/* Reuse tokens from ARB_depth_buffer_float */ +/* reuse GL_DEPTH_COMPONENT32F */ +/* reuse GL_DEPTH32F_STENCIL8 */ +/* reuse GL_FLOAT_32_UNSIGNED_INT_24_8_REV */ +/* Reuse tokens from ARB_framebuffer_object */ +/* reuse GL_INVALID_FRAMEBUFFER_OPERATION */ +/* reuse GL_FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING */ +/* reuse GL_FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE */ +/* reuse GL_FRAMEBUFFER_ATTACHMENT_RED_SIZE */ +/* reuse GL_FRAMEBUFFER_ATTACHMENT_GREEN_SIZE */ +/* reuse GL_FRAMEBUFFER_ATTACHMENT_BLUE_SIZE */ +/* reuse GL_FRAMEBUFFER_ATTACHMENT_ALPHA_SIZE */ +/* reuse GL_FRAMEBUFFER_ATTACHMENT_DEPTH_SIZE */ +/* reuse GL_FRAMEBUFFER_ATTACHMENT_STENCIL_SIZE */ +/* reuse GL_FRAMEBUFFER_DEFAULT */ +/* reuse GL_FRAMEBUFFER_UNDEFINED */ +/* reuse GL_DEPTH_STENCIL_ATTACHMENT */ +/* reuse GL_INDEX */ +/* reuse GL_MAX_RENDERBUFFER_SIZE */ +/* reuse GL_DEPTH_STENCIL */ +/* reuse GL_UNSIGNED_INT_24_8 */ +/* reuse GL_DEPTH24_STENCIL8 */ +/* reuse GL_TEXTURE_STENCIL_SIZE */ +/* reuse GL_TEXTURE_RED_TYPE */ +/* reuse GL_TEXTURE_GREEN_TYPE */ +/* reuse GL_TEXTURE_BLUE_TYPE */ +/* reuse GL_TEXTURE_ALPHA_TYPE */ +/* reuse GL_TEXTURE_LUMINANCE_TYPE */ +/* reuse GL_TEXTURE_INTENSITY_TYPE */ +/* reuse GL_TEXTURE_DEPTH_TYPE */ +/* reuse GL_UNSIGNED_NORMALIZED */ +/* reuse GL_FRAMEBUFFER_BINDING */ +/* reuse GL_DRAW_FRAMEBUFFER_BINDING */ +/* reuse GL_RENDERBUFFER_BINDING */ +/* reuse GL_READ_FRAMEBUFFER */ +/* reuse GL_DRAW_FRAMEBUFFER */ +/* reuse GL_READ_FRAMEBUFFER_BINDING */ +/* reuse GL_RENDERBUFFER_SAMPLES */ +/* reuse GL_FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE */ +/* reuse GL_FRAMEBUFFER_ATTACHMENT_OBJECT_NAME */ +/* reuse GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL */ +/* reuse GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE */ +/* reuse GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER */ +/* reuse GL_FRAMEBUFFER_COMPLETE */ +/* reuse GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT */ +/* reuse GL_FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT */ +/* reuse GL_FRAMEBUFFER_INCOMPLETE_DRAW_BUFFER */ +/* reuse GL_FRAMEBUFFER_INCOMPLETE_READ_BUFFER */ +/* reuse GL_FRAMEBUFFER_UNSUPPORTED */ +/* reuse GL_MAX_COLOR_ATTACHMENTS */ +/* reuse GL_COLOR_ATTACHMENT0 */ +/* reuse GL_COLOR_ATTACHMENT1 */ +/* reuse GL_COLOR_ATTACHMENT2 */ +/* reuse GL_COLOR_ATTACHMENT3 */ +/* reuse GL_COLOR_ATTACHMENT4 */ +/* reuse GL_COLOR_ATTACHMENT5 */ +/* reuse GL_COLOR_ATTACHMENT6 */ +/* reuse GL_COLOR_ATTACHMENT7 */ +/* reuse GL_COLOR_ATTACHMENT8 */ +/* reuse GL_COLOR_ATTACHMENT9 */ +/* reuse GL_COLOR_ATTACHMENT10 */ +/* reuse GL_COLOR_ATTACHMENT11 */ +/* reuse GL_COLOR_ATTACHMENT12 */ +/* reuse GL_COLOR_ATTACHMENT13 */ +/* reuse GL_COLOR_ATTACHMENT14 */ +/* reuse GL_COLOR_ATTACHMENT15 */ +/* reuse GL_DEPTH_ATTACHMENT */ +/* reuse GL_STENCIL_ATTACHMENT */ +/* reuse GL_FRAMEBUFFER */ +/* reuse GL_RENDERBUFFER */ +/* reuse GL_RENDERBUFFER_WIDTH */ +/* reuse GL_RENDERBUFFER_HEIGHT */ +/* reuse GL_RENDERBUFFER_INTERNAL_FORMAT */ +/* reuse GL_STENCIL_INDEX1 */ +/* reuse GL_STENCIL_INDEX4 */ +/* reuse GL_STENCIL_INDEX8 */ +/* reuse GL_STENCIL_INDEX16 */ +/* reuse GL_RENDERBUFFER_RED_SIZE */ +/* reuse GL_RENDERBUFFER_GREEN_SIZE */ +/* reuse GL_RENDERBUFFER_BLUE_SIZE */ +/* reuse GL_RENDERBUFFER_ALPHA_SIZE */ +/* reuse GL_RENDERBUFFER_DEPTH_SIZE */ +/* reuse GL_RENDERBUFFER_STENCIL_SIZE */ +/* reuse GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE */ +/* reuse GL_MAX_SAMPLES */ +/* Reuse tokens from ARB_framebuffer_sRGB */ +/* reuse GL_FRAMEBUFFER_SRGB */ +/* Reuse tokens from ARB_half_float_vertex */ +/* reuse GL_HALF_FLOAT */ +/* Reuse tokens from ARB_map_buffer_range */ +/* reuse GL_MAP_READ_BIT */ +/* reuse GL_MAP_WRITE_BIT */ +/* reuse GL_MAP_INVALIDATE_RANGE_BIT */ +/* reuse GL_MAP_INVALIDATE_BUFFER_BIT */ +/* reuse GL_MAP_FLUSH_EXPLICIT_BIT */ +/* reuse GL_MAP_UNSYNCHRONIZED_BIT */ +/* Reuse tokens from ARB_texture_compression_rgtc */ +/* reuse GL_COMPRESSED_RED_RGTC1 */ +/* reuse GL_COMPRESSED_SIGNED_RED_RGTC1 */ +/* reuse GL_COMPRESSED_RG_RGTC2 */ +/* reuse GL_COMPRESSED_SIGNED_RG_RGTC2 */ +/* Reuse tokens from ARB_texture_rg */ +/* reuse GL_RG */ +/* reuse GL_RG_INTEGER */ +/* reuse GL_R8 */ +/* reuse GL_R16 */ +/* reuse GL_RG8 */ +/* reuse GL_RG16 */ +/* reuse GL_R16F */ +/* reuse GL_R32F */ +/* reuse GL_RG16F */ +/* reuse GL_RG32F */ +/* reuse GL_R8I */ +/* reuse GL_R8UI */ +/* reuse GL_R16I */ +/* reuse GL_R16UI */ +/* reuse GL_R32I */ +/* reuse GL_R32UI */ +/* reuse GL_RG8I */ +/* reuse GL_RG8UI */ +/* reuse GL_RG16I */ +/* reuse GL_RG16UI */ +/* reuse GL_RG32I */ +/* reuse GL_RG32UI */ +/* Reuse tokens from ARB_vertex_array_object */ +/* reuse GL_VERTEX_ARRAY_BINDING */ +#endif + +#ifndef GL_ARB_multitexture +#define GL_TEXTURE0_ARB 0x84C0 +#define GL_TEXTURE1_ARB 0x84C1 +#define GL_TEXTURE2_ARB 0x84C2 +#define GL_TEXTURE3_ARB 0x84C3 +#define GL_TEXTURE4_ARB 0x84C4 +#define GL_TEXTURE5_ARB 0x84C5 +#define GL_TEXTURE6_ARB 0x84C6 +#define GL_TEXTURE7_ARB 0x84C7 +#define GL_TEXTURE8_ARB 0x84C8 +#define GL_TEXTURE9_ARB 0x84C9 +#define GL_TEXTURE10_ARB 0x84CA +#define GL_TEXTURE11_ARB 0x84CB +#define GL_TEXTURE12_ARB 0x84CC +#define GL_TEXTURE13_ARB 0x84CD +#define GL_TEXTURE14_ARB 0x84CE +#define GL_TEXTURE15_ARB 0x84CF +#define GL_TEXTURE16_ARB 0x84D0 +#define GL_TEXTURE17_ARB 0x84D1 +#define GL_TEXTURE18_ARB 0x84D2 +#define GL_TEXTURE19_ARB 0x84D3 +#define GL_TEXTURE20_ARB 0x84D4 +#define GL_TEXTURE21_ARB 0x84D5 +#define GL_TEXTURE22_ARB 0x84D6 +#define GL_TEXTURE23_ARB 0x84D7 +#define GL_TEXTURE24_ARB 0x84D8 +#define GL_TEXTURE25_ARB 0x84D9 +#define GL_TEXTURE26_ARB 0x84DA +#define GL_TEXTURE27_ARB 0x84DB +#define GL_TEXTURE28_ARB 0x84DC +#define GL_TEXTURE29_ARB 0x84DD +#define GL_TEXTURE30_ARB 0x84DE +#define GL_TEXTURE31_ARB 0x84DF +#define GL_ACTIVE_TEXTURE_ARB 0x84E0 +#define GL_CLIENT_ACTIVE_TEXTURE_ARB 0x84E1 +#define GL_MAX_TEXTURE_UNITS_ARB 0x84E2 +#endif + +#ifndef GL_ARB_transpose_matrix +#define GL_TRANSPOSE_MODELVIEW_MATRIX_ARB 0x84E3 +#define GL_TRANSPOSE_PROJECTION_MATRIX_ARB 0x84E4 +#define GL_TRANSPOSE_TEXTURE_MATRIX_ARB 0x84E5 +#define GL_TRANSPOSE_COLOR_MATRIX_ARB 0x84E6 +#endif + +#ifndef GL_ARB_multisample +#define GL_MULTISAMPLE_ARB 0x809D +#define GL_SAMPLE_ALPHA_TO_COVERAGE_ARB 0x809E +#define GL_SAMPLE_ALPHA_TO_ONE_ARB 0x809F +#define GL_SAMPLE_COVERAGE_ARB 0x80A0 +#define GL_SAMPLE_BUFFERS_ARB 0x80A8 +#define GL_SAMPLES_ARB 0x80A9 +#define GL_SAMPLE_COVERAGE_VALUE_ARB 0x80AA +#define GL_SAMPLE_COVERAGE_INVERT_ARB 0x80AB +#define GL_MULTISAMPLE_BIT_ARB 0x20000000 +#endif + +#ifndef GL_ARB_texture_env_add +#endif + +#ifndef GL_ARB_texture_cube_map +#define GL_NORMAL_MAP_ARB 0x8511 +#define GL_REFLECTION_MAP_ARB 0x8512 +#define GL_TEXTURE_CUBE_MAP_ARB 0x8513 +#define GL_TEXTURE_BINDING_CUBE_MAP_ARB 0x8514 +#define GL_TEXTURE_CUBE_MAP_POSITIVE_X_ARB 0x8515 +#define GL_TEXTURE_CUBE_MAP_NEGATIVE_X_ARB 0x8516 +#define GL_TEXTURE_CUBE_MAP_POSITIVE_Y_ARB 0x8517 +#define GL_TEXTURE_CUBE_MAP_NEGATIVE_Y_ARB 0x8518 +#define GL_TEXTURE_CUBE_MAP_POSITIVE_Z_ARB 0x8519 +#define GL_TEXTURE_CUBE_MAP_NEGATIVE_Z_ARB 0x851A +#define GL_PROXY_TEXTURE_CUBE_MAP_ARB 0x851B +#define GL_MAX_CUBE_MAP_TEXTURE_SIZE_ARB 0x851C +#endif + +#ifndef GL_ARB_texture_compression +#define GL_COMPRESSED_ALPHA_ARB 0x84E9 +#define GL_COMPRESSED_LUMINANCE_ARB 0x84EA +#define GL_COMPRESSED_LUMINANCE_ALPHA_ARB 0x84EB +#define GL_COMPRESSED_INTENSITY_ARB 0x84EC +#define GL_COMPRESSED_RGB_ARB 0x84ED +#define GL_COMPRESSED_RGBA_ARB 0x84EE +#define GL_TEXTURE_COMPRESSION_HINT_ARB 0x84EF +#define GL_TEXTURE_COMPRESSED_IMAGE_SIZE_ARB 0x86A0 +#define GL_TEXTURE_COMPRESSED_ARB 0x86A1 +#define GL_NUM_COMPRESSED_TEXTURE_FORMATS_ARB 0x86A2 +#define GL_COMPRESSED_TEXTURE_FORMATS_ARB 0x86A3 +#endif + +#ifndef GL_ARB_texture_border_clamp +#define GL_CLAMP_TO_BORDER_ARB 0x812D +#endif + +#ifndef GL_ARB_point_parameters +#define GL_POINT_SIZE_MIN_ARB 0x8126 +#define GL_POINT_SIZE_MAX_ARB 0x8127 +#define GL_POINT_FADE_THRESHOLD_SIZE_ARB 0x8128 +#define GL_POINT_DISTANCE_ATTENUATION_ARB 0x8129 +#endif + +#ifndef GL_ARB_vertex_blend +#define GL_MAX_VERTEX_UNITS_ARB 0x86A4 +#define GL_ACTIVE_VERTEX_UNITS_ARB 0x86A5 +#define GL_WEIGHT_SUM_UNITY_ARB 0x86A6 +#define GL_VERTEX_BLEND_ARB 0x86A7 +#define GL_CURRENT_WEIGHT_ARB 0x86A8 +#define GL_WEIGHT_ARRAY_TYPE_ARB 0x86A9 +#define GL_WEIGHT_ARRAY_STRIDE_ARB 0x86AA +#define GL_WEIGHT_ARRAY_SIZE_ARB 0x86AB +#define GL_WEIGHT_ARRAY_POINTER_ARB 0x86AC +#define GL_WEIGHT_ARRAY_ARB 0x86AD +#define GL_MODELVIEW0_ARB 0x1700 +#define GL_MODELVIEW1_ARB 0x850A +#define GL_MODELVIEW2_ARB 0x8722 +#define GL_MODELVIEW3_ARB 0x8723 +#define GL_MODELVIEW4_ARB 0x8724 +#define GL_MODELVIEW5_ARB 0x8725 +#define GL_MODELVIEW6_ARB 0x8726 +#define GL_MODELVIEW7_ARB 0x8727 +#define GL_MODELVIEW8_ARB 0x8728 +#define GL_MODELVIEW9_ARB 0x8729 +#define GL_MODELVIEW10_ARB 0x872A +#define GL_MODELVIEW11_ARB 0x872B +#define GL_MODELVIEW12_ARB 0x872C +#define GL_MODELVIEW13_ARB 0x872D +#define GL_MODELVIEW14_ARB 0x872E +#define GL_MODELVIEW15_ARB 0x872F +#define GL_MODELVIEW16_ARB 0x8730 +#define GL_MODELVIEW17_ARB 0x8731 +#define GL_MODELVIEW18_ARB 0x8732 +#define GL_MODELVIEW19_ARB 0x8733 +#define GL_MODELVIEW20_ARB 0x8734 +#define GL_MODELVIEW21_ARB 0x8735 +#define GL_MODELVIEW22_ARB 0x8736 +#define GL_MODELVIEW23_ARB 0x8737 +#define GL_MODELVIEW24_ARB 0x8738 +#define GL_MODELVIEW25_ARB 0x8739 +#define GL_MODELVIEW26_ARB 0x873A +#define GL_MODELVIEW27_ARB 0x873B +#define GL_MODELVIEW28_ARB 0x873C +#define GL_MODELVIEW29_ARB 0x873D +#define GL_MODELVIEW30_ARB 0x873E +#define GL_MODELVIEW31_ARB 0x873F +#endif + +#ifndef GL_ARB_matrix_palette +#define GL_MATRIX_PALETTE_ARB 0x8840 +#define GL_MAX_MATRIX_PALETTE_STACK_DEPTH_ARB 0x8841 +#define GL_MAX_PALETTE_MATRICES_ARB 0x8842 +#define GL_CURRENT_PALETTE_MATRIX_ARB 0x8843 +#define GL_MATRIX_INDEX_ARRAY_ARB 0x8844 +#define GL_CURRENT_MATRIX_INDEX_ARB 0x8845 +#define GL_MATRIX_INDEX_ARRAY_SIZE_ARB 0x8846 +#define GL_MATRIX_INDEX_ARRAY_TYPE_ARB 0x8847 +#define GL_MATRIX_INDEX_ARRAY_STRIDE_ARB 0x8848 +#define GL_MATRIX_INDEX_ARRAY_POINTER_ARB 0x8849 +#endif + +#ifndef GL_ARB_texture_env_combine +#define GL_COMBINE_ARB 0x8570 +#define GL_COMBINE_RGB_ARB 0x8571 +#define GL_COMBINE_ALPHA_ARB 0x8572 +#define GL_SOURCE0_RGB_ARB 0x8580 +#define GL_SOURCE1_RGB_ARB 0x8581 +#define GL_SOURCE2_RGB_ARB 0x8582 +#define GL_SOURCE0_ALPHA_ARB 0x8588 +#define GL_SOURCE1_ALPHA_ARB 0x8589 +#define GL_SOURCE2_ALPHA_ARB 0x858A +#define GL_OPERAND0_RGB_ARB 0x8590 +#define GL_OPERAND1_RGB_ARB 0x8591 +#define GL_OPERAND2_RGB_ARB 0x8592 +#define GL_OPERAND0_ALPHA_ARB 0x8598 +#define GL_OPERAND1_ALPHA_ARB 0x8599 +#define GL_OPERAND2_ALPHA_ARB 0x859A +#define GL_RGB_SCALE_ARB 0x8573 +#define GL_ADD_SIGNED_ARB 0x8574 +#define GL_INTERPOLATE_ARB 0x8575 +#define GL_SUBTRACT_ARB 0x84E7 +#define GL_CONSTANT_ARB 0x8576 +#define GL_PRIMARY_COLOR_ARB 0x8577 +#define GL_PREVIOUS_ARB 0x8578 +#endif + +#ifndef GL_ARB_texture_env_crossbar +#endif + +#ifndef GL_ARB_texture_env_dot3 +#define GL_DOT3_RGB_ARB 0x86AE +#define GL_DOT3_RGBA_ARB 0x86AF +#endif + +#ifndef GL_ARB_texture_mirrored_repeat +#define GL_MIRRORED_REPEAT_ARB 0x8370 +#endif + +#ifndef GL_ARB_depth_texture +#define GL_DEPTH_COMPONENT16_ARB 0x81A5 +#define GL_DEPTH_COMPONENT24_ARB 0x81A6 +#define GL_DEPTH_COMPONENT32_ARB 0x81A7 +#define GL_TEXTURE_DEPTH_SIZE_ARB 0x884A +#define GL_DEPTH_TEXTURE_MODE_ARB 0x884B +#endif + +#ifndef GL_ARB_shadow +#define GL_TEXTURE_COMPARE_MODE_ARB 0x884C +#define GL_TEXTURE_COMPARE_FUNC_ARB 0x884D +#define GL_COMPARE_R_TO_TEXTURE_ARB 0x884E +#endif + +#ifndef GL_ARB_shadow_ambient +#define GL_TEXTURE_COMPARE_FAIL_VALUE_ARB 0x80BF +#endif + +#ifndef GL_ARB_window_pos +#endif + +#ifndef GL_ARB_vertex_program +#define GL_COLOR_SUM_ARB 0x8458 +#define GL_VERTEX_PROGRAM_ARB 0x8620 +#define GL_VERTEX_ATTRIB_ARRAY_ENABLED_ARB 0x8622 +#define GL_VERTEX_ATTRIB_ARRAY_SIZE_ARB 0x8623 +#define GL_VERTEX_ATTRIB_ARRAY_STRIDE_ARB 0x8624 +#define GL_VERTEX_ATTRIB_ARRAY_TYPE_ARB 0x8625 +#define GL_CURRENT_VERTEX_ATTRIB_ARB 0x8626 +#define GL_PROGRAM_LENGTH_ARB 0x8627 +#define GL_PROGRAM_STRING_ARB 0x8628 +#define GL_MAX_PROGRAM_MATRIX_STACK_DEPTH_ARB 0x862E +#define GL_MAX_PROGRAM_MATRICES_ARB 0x862F +#define GL_CURRENT_MATRIX_STACK_DEPTH_ARB 0x8640 +#define GL_CURRENT_MATRIX_ARB 0x8641 +#define GL_VERTEX_PROGRAM_POINT_SIZE_ARB 0x8642 +#define GL_VERTEX_PROGRAM_TWO_SIDE_ARB 0x8643 +#define GL_VERTEX_ATTRIB_ARRAY_POINTER_ARB 0x8645 +#define GL_PROGRAM_ERROR_POSITION_ARB 0x864B +#define GL_PROGRAM_BINDING_ARB 0x8677 +#define GL_MAX_VERTEX_ATTRIBS_ARB 0x8869 +#define GL_VERTEX_ATTRIB_ARRAY_NORMALIZED_ARB 0x886A +#define GL_PROGRAM_ERROR_STRING_ARB 0x8874 +#define GL_PROGRAM_FORMAT_ASCII_ARB 0x8875 +#define GL_PROGRAM_FORMAT_ARB 0x8876 +#define GL_PROGRAM_INSTRUCTIONS_ARB 0x88A0 +#define GL_MAX_PROGRAM_INSTRUCTIONS_ARB 0x88A1 +#define GL_PROGRAM_NATIVE_INSTRUCTIONS_ARB 0x88A2 +#define GL_MAX_PROGRAM_NATIVE_INSTRUCTIONS_ARB 0x88A3 +#define GL_PROGRAM_TEMPORARIES_ARB 0x88A4 +#define GL_MAX_PROGRAM_TEMPORARIES_ARB 0x88A5 +#define GL_PROGRAM_NATIVE_TEMPORARIES_ARB 0x88A6 +#define GL_MAX_PROGRAM_NATIVE_TEMPORARIES_ARB 0x88A7 +#define GL_PROGRAM_PARAMETERS_ARB 0x88A8 +#define GL_MAX_PROGRAM_PARAMETERS_ARB 0x88A9 +#define GL_PROGRAM_NATIVE_PARAMETERS_ARB 0x88AA +#define GL_MAX_PROGRAM_NATIVE_PARAMETERS_ARB 0x88AB +#define GL_PROGRAM_ATTRIBS_ARB 0x88AC +#define GL_MAX_PROGRAM_ATTRIBS_ARB 0x88AD +#define GL_PROGRAM_NATIVE_ATTRIBS_ARB 0x88AE +#define GL_MAX_PROGRAM_NATIVE_ATTRIBS_ARB 0x88AF +#define GL_PROGRAM_ADDRESS_REGISTERS_ARB 0x88B0 +#define GL_MAX_PROGRAM_ADDRESS_REGISTERS_ARB 0x88B1 +#define GL_PROGRAM_NATIVE_ADDRESS_REGISTERS_ARB 0x88B2 +#define GL_MAX_PROGRAM_NATIVE_ADDRESS_REGISTERS_ARB 0x88B3 +#define GL_MAX_PROGRAM_LOCAL_PARAMETERS_ARB 0x88B4 +#define GL_MAX_PROGRAM_ENV_PARAMETERS_ARB 0x88B5 +#define GL_PROGRAM_UNDER_NATIVE_LIMITS_ARB 0x88B6 +#define GL_TRANSPOSE_CURRENT_MATRIX_ARB 0x88B7 +#define GL_MATRIX0_ARB 0x88C0 +#define GL_MATRIX1_ARB 0x88C1 +#define GL_MATRIX2_ARB 0x88C2 +#define GL_MATRIX3_ARB 0x88C3 +#define GL_MATRIX4_ARB 0x88C4 +#define GL_MATRIX5_ARB 0x88C5 +#define GL_MATRIX6_ARB 0x88C6 +#define GL_MATRIX7_ARB 0x88C7 +#define GL_MATRIX8_ARB 0x88C8 +#define GL_MATRIX9_ARB 0x88C9 +#define GL_MATRIX10_ARB 0x88CA +#define GL_MATRIX11_ARB 0x88CB +#define GL_MATRIX12_ARB 0x88CC +#define GL_MATRIX13_ARB 0x88CD +#define GL_MATRIX14_ARB 0x88CE +#define GL_MATRIX15_ARB 0x88CF +#define GL_MATRIX16_ARB 0x88D0 +#define GL_MATRIX17_ARB 0x88D1 +#define GL_MATRIX18_ARB 0x88D2 +#define GL_MATRIX19_ARB 0x88D3 +#define GL_MATRIX20_ARB 0x88D4 +#define GL_MATRIX21_ARB 0x88D5 +#define GL_MATRIX22_ARB 0x88D6 +#define GL_MATRIX23_ARB 0x88D7 +#define GL_MATRIX24_ARB 0x88D8 +#define GL_MATRIX25_ARB 0x88D9 +#define GL_MATRIX26_ARB 0x88DA +#define GL_MATRIX27_ARB 0x88DB +#define GL_MATRIX28_ARB 0x88DC +#define GL_MATRIX29_ARB 0x88DD +#define GL_MATRIX30_ARB 0x88DE +#define GL_MATRIX31_ARB 0x88DF +#endif + +#ifndef GL_ARB_fragment_program +#define GL_FRAGMENT_PROGRAM_ARB 0x8804 +#define GL_PROGRAM_ALU_INSTRUCTIONS_ARB 0x8805 +#define GL_PROGRAM_TEX_INSTRUCTIONS_ARB 0x8806 +#define GL_PROGRAM_TEX_INDIRECTIONS_ARB 0x8807 +#define GL_PROGRAM_NATIVE_ALU_INSTRUCTIONS_ARB 0x8808 +#define GL_PROGRAM_NATIVE_TEX_INSTRUCTIONS_ARB 0x8809 +#define GL_PROGRAM_NATIVE_TEX_INDIRECTIONS_ARB 0x880A +#define GL_MAX_PROGRAM_ALU_INSTRUCTIONS_ARB 0x880B +#define GL_MAX_PROGRAM_TEX_INSTRUCTIONS_ARB 0x880C +#define GL_MAX_PROGRAM_TEX_INDIRECTIONS_ARB 0x880D +#define GL_MAX_PROGRAM_NATIVE_ALU_INSTRUCTIONS_ARB 0x880E +#define GL_MAX_PROGRAM_NATIVE_TEX_INSTRUCTIONS_ARB 0x880F +#define GL_MAX_PROGRAM_NATIVE_TEX_INDIRECTIONS_ARB 0x8810 +#define GL_MAX_TEXTURE_COORDS_ARB 0x8871 +#define GL_MAX_TEXTURE_IMAGE_UNITS_ARB 0x8872 +#endif + +#ifndef GL_ARB_vertex_buffer_object +#define GL_BUFFER_SIZE_ARB 0x8764 +#define GL_BUFFER_USAGE_ARB 0x8765 +#define GL_ARRAY_BUFFER_ARB 0x8892 +#define GL_ELEMENT_ARRAY_BUFFER_ARB 0x8893 +#define GL_ARRAY_BUFFER_BINDING_ARB 0x8894 +#define GL_ELEMENT_ARRAY_BUFFER_BINDING_ARB 0x8895 +#define GL_VERTEX_ARRAY_BUFFER_BINDING_ARB 0x8896 +#define GL_NORMAL_ARRAY_BUFFER_BINDING_ARB 0x8897 +#define GL_COLOR_ARRAY_BUFFER_BINDING_ARB 0x8898 +#define GL_INDEX_ARRAY_BUFFER_BINDING_ARB 0x8899 +#define GL_TEXTURE_COORD_ARRAY_BUFFER_BINDING_ARB 0x889A +#define GL_EDGE_FLAG_ARRAY_BUFFER_BINDING_ARB 0x889B +#define GL_SECONDARY_COLOR_ARRAY_BUFFER_BINDING_ARB 0x889C +#define GL_FOG_COORDINATE_ARRAY_BUFFER_BINDING_ARB 0x889D +#define GL_WEIGHT_ARRAY_BUFFER_BINDING_ARB 0x889E +#define GL_VERTEX_ATTRIB_ARRAY_BUFFER_BINDING_ARB 0x889F +#define GL_READ_ONLY_ARB 0x88B8 +#define GL_WRITE_ONLY_ARB 0x88B9 +#define GL_READ_WRITE_ARB 0x88BA +#define GL_BUFFER_ACCESS_ARB 0x88BB +#define GL_BUFFER_MAPPED_ARB 0x88BC +#define GL_BUFFER_MAP_POINTER_ARB 0x88BD +#define GL_STREAM_DRAW_ARB 0x88E0 +#define GL_STREAM_READ_ARB 0x88E1 +#define GL_STREAM_COPY_ARB 0x88E2 +#define GL_STATIC_DRAW_ARB 0x88E4 +#define GL_STATIC_READ_ARB 0x88E5 +#define GL_STATIC_COPY_ARB 0x88E6 +#define GL_DYNAMIC_DRAW_ARB 0x88E8 +#define GL_DYNAMIC_READ_ARB 0x88E9 +#define GL_DYNAMIC_COPY_ARB 0x88EA +#endif + +#ifndef GL_ARB_occlusion_query +#define GL_QUERY_COUNTER_BITS_ARB 0x8864 +#define GL_CURRENT_QUERY_ARB 0x8865 +#define GL_QUERY_RESULT_ARB 0x8866 +#define GL_QUERY_RESULT_AVAILABLE_ARB 0x8867 +#define GL_SAMPLES_PASSED_ARB 0x8914 +#endif + +#ifndef GL_ARB_shader_objects +#define GL_PROGRAM_OBJECT_ARB 0x8B40 +#define GL_SHADER_OBJECT_ARB 0x8B48 +#define GL_OBJECT_TYPE_ARB 0x8B4E +#define GL_OBJECT_SUBTYPE_ARB 0x8B4F +#define GL_FLOAT_VEC2_ARB 0x8B50 +#define GL_FLOAT_VEC3_ARB 0x8B51 +#define GL_FLOAT_VEC4_ARB 0x8B52 +#define GL_INT_VEC2_ARB 0x8B53 +#define GL_INT_VEC3_ARB 0x8B54 +#define GL_INT_VEC4_ARB 0x8B55 +#define GL_BOOL_ARB 0x8B56 +#define GL_BOOL_VEC2_ARB 0x8B57 +#define GL_BOOL_VEC3_ARB 0x8B58 +#define GL_BOOL_VEC4_ARB 0x8B59 +#define GL_FLOAT_MAT2_ARB 0x8B5A +#define GL_FLOAT_MAT3_ARB 0x8B5B +#define GL_FLOAT_MAT4_ARB 0x8B5C +#define GL_SAMPLER_1D_ARB 0x8B5D +#define GL_SAMPLER_2D_ARB 0x8B5E +#define GL_SAMPLER_3D_ARB 0x8B5F +#define GL_SAMPLER_CUBE_ARB 0x8B60 +#define GL_SAMPLER_1D_SHADOW_ARB 0x8B61 +#define GL_SAMPLER_2D_SHADOW_ARB 0x8B62 +#define GL_SAMPLER_2D_RECT_ARB 0x8B63 +#define GL_SAMPLER_2D_RECT_SHADOW_ARB 0x8B64 +#define GL_OBJECT_DELETE_STATUS_ARB 0x8B80 +#define GL_OBJECT_COMPILE_STATUS_ARB 0x8B81 +#define GL_OBJECT_LINK_STATUS_ARB 0x8B82 +#define GL_OBJECT_VALIDATE_STATUS_ARB 0x8B83 +#define GL_OBJECT_INFO_LOG_LENGTH_ARB 0x8B84 +#define GL_OBJECT_ATTACHED_OBJECTS_ARB 0x8B85 +#define GL_OBJECT_ACTIVE_UNIFORMS_ARB 0x8B86 +#define GL_OBJECT_ACTIVE_UNIFORM_MAX_LENGTH_ARB 0x8B87 +#define GL_OBJECT_SHADER_SOURCE_LENGTH_ARB 0x8B88 +#endif + +#ifndef GL_ARB_vertex_shader +#define GL_VERTEX_SHADER_ARB 0x8B31 +#define GL_MAX_VERTEX_UNIFORM_COMPONENTS_ARB 0x8B4A +#define GL_MAX_VARYING_FLOATS_ARB 0x8B4B +#define GL_MAX_VERTEX_TEXTURE_IMAGE_UNITS_ARB 0x8B4C +#define GL_MAX_COMBINED_TEXTURE_IMAGE_UNITS_ARB 0x8B4D +#define GL_OBJECT_ACTIVE_ATTRIBUTES_ARB 0x8B89 +#define GL_OBJECT_ACTIVE_ATTRIBUTE_MAX_LENGTH_ARB 0x8B8A +#endif + +#ifndef GL_ARB_fragment_shader +#define GL_FRAGMENT_SHADER_ARB 0x8B30 +#define GL_MAX_FRAGMENT_UNIFORM_COMPONENTS_ARB 0x8B49 +#define GL_FRAGMENT_SHADER_DERIVATIVE_HINT_ARB 0x8B8B +#endif + +#ifndef GL_ARB_shading_language_100 +#define GL_SHADING_LANGUAGE_VERSION_ARB 0x8B8C +#endif + +#ifndef GL_ARB_texture_non_power_of_two +#endif + +#ifndef GL_ARB_point_sprite +#define GL_POINT_SPRITE_ARB 0x8861 +#define GL_COORD_REPLACE_ARB 0x8862 +#endif + +#ifndef GL_ARB_fragment_program_shadow +#endif + +#ifndef GL_ARB_draw_buffers +#define GL_MAX_DRAW_BUFFERS_ARB 0x8824 +#define GL_DRAW_BUFFER0_ARB 0x8825 +#define GL_DRAW_BUFFER1_ARB 0x8826 +#define GL_DRAW_BUFFER2_ARB 0x8827 +#define GL_DRAW_BUFFER3_ARB 0x8828 +#define GL_DRAW_BUFFER4_ARB 0x8829 +#define GL_DRAW_BUFFER5_ARB 0x882A +#define GL_DRAW_BUFFER6_ARB 0x882B +#define GL_DRAW_BUFFER7_ARB 0x882C +#define GL_DRAW_BUFFER8_ARB 0x882D +#define GL_DRAW_BUFFER9_ARB 0x882E +#define GL_DRAW_BUFFER10_ARB 0x882F +#define GL_DRAW_BUFFER11_ARB 0x8830 +#define GL_DRAW_BUFFER12_ARB 0x8831 +#define GL_DRAW_BUFFER13_ARB 0x8832 +#define GL_DRAW_BUFFER14_ARB 0x8833 +#define GL_DRAW_BUFFER15_ARB 0x8834 +#endif + +#ifndef GL_ARB_texture_rectangle +#define GL_TEXTURE_RECTANGLE_ARB 0x84F5 +#define GL_TEXTURE_BINDING_RECTANGLE_ARB 0x84F6 +#define GL_PROXY_TEXTURE_RECTANGLE_ARB 0x84F7 +#define GL_MAX_RECTANGLE_TEXTURE_SIZE_ARB 0x84F8 +#endif + +#ifndef GL_ARB_color_buffer_float +#define GL_RGBA_FLOAT_MODE_ARB 0x8820 +#define GL_CLAMP_VERTEX_COLOR_ARB 0x891A +#define GL_CLAMP_FRAGMENT_COLOR_ARB 0x891B +#define GL_CLAMP_READ_COLOR_ARB 0x891C +#define GL_FIXED_ONLY_ARB 0x891D +#endif + +#ifndef GL_ARB_half_float_pixel +#define GL_HALF_FLOAT_ARB 0x140B +#endif + +#ifndef GL_ARB_texture_float +#define GL_TEXTURE_RED_TYPE_ARB 0x8C10 +#define GL_TEXTURE_GREEN_TYPE_ARB 0x8C11 +#define GL_TEXTURE_BLUE_TYPE_ARB 0x8C12 +#define GL_TEXTURE_ALPHA_TYPE_ARB 0x8C13 +#define GL_TEXTURE_LUMINANCE_TYPE_ARB 0x8C14 +#define GL_TEXTURE_INTENSITY_TYPE_ARB 0x8C15 +#define GL_TEXTURE_DEPTH_TYPE_ARB 0x8C16 +#define GL_UNSIGNED_NORMALIZED_ARB 0x8C17 +#define GL_RGBA32F_ARB 0x8814 +#define GL_RGB32F_ARB 0x8815 +#define GL_ALPHA32F_ARB 0x8816 +#define GL_INTENSITY32F_ARB 0x8817 +#define GL_LUMINANCE32F_ARB 0x8818 +#define GL_LUMINANCE_ALPHA32F_ARB 0x8819 +#define GL_RGBA16F_ARB 0x881A +#define GL_RGB16F_ARB 0x881B +#define GL_ALPHA16F_ARB 0x881C +#define GL_INTENSITY16F_ARB 0x881D +#define GL_LUMINANCE16F_ARB 0x881E +#define GL_LUMINANCE_ALPHA16F_ARB 0x881F +#endif + +#ifndef GL_ARB_pixel_buffer_object +#define GL_PIXEL_PACK_BUFFER_ARB 0x88EB +#define GL_PIXEL_UNPACK_BUFFER_ARB 0x88EC +#define GL_PIXEL_PACK_BUFFER_BINDING_ARB 0x88ED +#define GL_PIXEL_UNPACK_BUFFER_BINDING_ARB 0x88EF +#endif + +#ifndef GL_ARB_depth_buffer_float +#define GL_DEPTH_COMPONENT32F 0x8CAC +#define GL_DEPTH32F_STENCIL8 0x8CAD +#define GL_FLOAT_32_UNSIGNED_INT_24_8_REV 0x8DAD +#endif + +#ifndef GL_ARB_draw_instanced +#endif + +#ifndef GL_ARB_framebuffer_object +#define GL_INVALID_FRAMEBUFFER_OPERATION 0x0506 +#define GL_FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING 0x8210 +#define GL_FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE 0x8211 +#define GL_FRAMEBUFFER_ATTACHMENT_RED_SIZE 0x8212 +#define GL_FRAMEBUFFER_ATTACHMENT_GREEN_SIZE 0x8213 +#define GL_FRAMEBUFFER_ATTACHMENT_BLUE_SIZE 0x8214 +#define GL_FRAMEBUFFER_ATTACHMENT_ALPHA_SIZE 0x8215 +#define GL_FRAMEBUFFER_ATTACHMENT_DEPTH_SIZE 0x8216 +#define GL_FRAMEBUFFER_ATTACHMENT_STENCIL_SIZE 0x8217 +#define GL_FRAMEBUFFER_DEFAULT 0x8218 +#define GL_FRAMEBUFFER_UNDEFINED 0x8219 +#define GL_DEPTH_STENCIL_ATTACHMENT 0x821A +#define GL_INDEX 0x8222 +#define GL_MAX_RENDERBUFFER_SIZE 0x84E8 +#define GL_DEPTH_STENCIL 0x84F9 +#define GL_UNSIGNED_INT_24_8 0x84FA +#define GL_DEPTH24_STENCIL8 0x88F0 +#define GL_TEXTURE_STENCIL_SIZE 0x88F1 +#define GL_FRAMEBUFFER_BINDING 0x8CA6 +#define GL_DRAW_FRAMEBUFFER_BINDING GL_FRAMEBUFFER_BINDING +#define GL_RENDERBUFFER_BINDING 0x8CA7 +#define GL_READ_FRAMEBUFFER 0x8CA8 +#define GL_DRAW_FRAMEBUFFER 0x8CA9 +#define GL_READ_FRAMEBUFFER_BINDING 0x8CAA +#define GL_RENDERBUFFER_SAMPLES 0x8CAB +#define GL_FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE 0x8CD0 +#define GL_FRAMEBUFFER_ATTACHMENT_OBJECT_NAME 0x8CD1 +#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL 0x8CD2 +#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE 0x8CD3 +#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER 0x8CD4 +#define GL_FRAMEBUFFER_COMPLETE 0x8CD5 +#define GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT 0x8CD6 +#define GL_FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT 0x8CD7 +#define GL_FRAMEBUFFER_INCOMPLETE_DRAW_BUFFER 0x8CDB +#define GL_FRAMEBUFFER_INCOMPLETE_READ_BUFFER 0x8CDC +#define GL_FRAMEBUFFER_UNSUPPORTED 0x8CDD +#define GL_MAX_COLOR_ATTACHMENTS 0x8CDF +#define GL_COLOR_ATTACHMENT0 0x8CE0 +#define GL_COLOR_ATTACHMENT1 0x8CE1 +#define GL_COLOR_ATTACHMENT2 0x8CE2 +#define GL_COLOR_ATTACHMENT3 0x8CE3 +#define GL_COLOR_ATTACHMENT4 0x8CE4 +#define GL_COLOR_ATTACHMENT5 0x8CE5 +#define GL_COLOR_ATTACHMENT6 0x8CE6 +#define GL_COLOR_ATTACHMENT7 0x8CE7 +#define GL_COLOR_ATTACHMENT8 0x8CE8 +#define GL_COLOR_ATTACHMENT9 0x8CE9 +#define GL_COLOR_ATTACHMENT10 0x8CEA +#define GL_COLOR_ATTACHMENT11 0x8CEB +#define GL_COLOR_ATTACHMENT12 0x8CEC +#define GL_COLOR_ATTACHMENT13 0x8CED +#define GL_COLOR_ATTACHMENT14 0x8CEE +#define GL_COLOR_ATTACHMENT15 0x8CEF +#define GL_DEPTH_ATTACHMENT 0x8D00 +#define GL_STENCIL_ATTACHMENT 0x8D20 +#define GL_FRAMEBUFFER 0x8D40 +#define GL_RENDERBUFFER 0x8D41 +#define GL_RENDERBUFFER_WIDTH 0x8D42 +#define GL_RENDERBUFFER_HEIGHT 0x8D43 +#define GL_RENDERBUFFER_INTERNAL_FORMAT 0x8D44 +#define GL_STENCIL_INDEX1 0x8D46 +#define GL_STENCIL_INDEX4 0x8D47 +#define GL_STENCIL_INDEX8 0x8D48 +#define GL_STENCIL_INDEX16 0x8D49 +#define GL_RENDERBUFFER_RED_SIZE 0x8D50 +#define GL_RENDERBUFFER_GREEN_SIZE 0x8D51 +#define GL_RENDERBUFFER_BLUE_SIZE 0x8D52 +#define GL_RENDERBUFFER_ALPHA_SIZE 0x8D53 +#define GL_RENDERBUFFER_DEPTH_SIZE 0x8D54 +#define GL_RENDERBUFFER_STENCIL_SIZE 0x8D55 +#define GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE 0x8D56 +#define GL_MAX_SAMPLES 0x8D57 +#endif + +#ifndef GL_ARB_framebuffer_sRGB +#define GL_FRAMEBUFFER_SRGB 0x8DB9 +#endif + +#ifndef GL_ARB_geometry_shader4 +#define GL_LINES_ADJACENCY_ARB 0x000A +#define GL_LINE_STRIP_ADJACENCY_ARB 0x000B +#define GL_TRIANGLES_ADJACENCY_ARB 0x000C +#define GL_TRIANGLE_STRIP_ADJACENCY_ARB 0x000D +#define GL_PROGRAM_POINT_SIZE_ARB 0x8642 +#define GL_MAX_GEOMETRY_TEXTURE_IMAGE_UNITS_ARB 0x8C29 +#define GL_FRAMEBUFFER_ATTACHMENT_LAYERED_ARB 0x8DA7 +#define GL_FRAMEBUFFER_INCOMPLETE_LAYER_TARGETS_ARB 0x8DA8 +#define GL_FRAMEBUFFER_INCOMPLETE_LAYER_COUNT_ARB 0x8DA9 +#define GL_GEOMETRY_SHADER_ARB 0x8DD9 +#define GL_GEOMETRY_VERTICES_OUT_ARB 0x8DDA +#define GL_GEOMETRY_INPUT_TYPE_ARB 0x8DDB +#define GL_GEOMETRY_OUTPUT_TYPE_ARB 0x8DDC +#define GL_MAX_GEOMETRY_VARYING_COMPONENTS_ARB 0x8DDD +#define GL_MAX_VERTEX_VARYING_COMPONENTS_ARB 0x8DDE +#define GL_MAX_GEOMETRY_UNIFORM_COMPONENTS_ARB 0x8DDF +#define GL_MAX_GEOMETRY_OUTPUT_VERTICES_ARB 0x8DE0 +#define GL_MAX_GEOMETRY_TOTAL_OUTPUT_COMPONENTS_ARB 0x8DE1 +/* reuse GL_MAX_VARYING_COMPONENTS */ +/* reuse GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER */ +#endif + +#ifndef GL_ARB_half_float_vertex +#define GL_HALF_FLOAT 0x140B +#endif + +#ifndef GL_ARB_instanced_arrays +#endif + +#ifndef GL_ARB_map_buffer_range +#define GL_MAP_READ_BIT 0x0001 +#define GL_MAP_WRITE_BIT 0x0002 +#define GL_MAP_INVALIDATE_RANGE_BIT 0x0004 +#define GL_MAP_INVALIDATE_BUFFER_BIT 0x0008 +#define GL_MAP_FLUSH_EXPLICIT_BIT 0x0010 +#define GL_MAP_UNSYNCHRONIZED_BIT 0x0020 +#endif + +#ifndef GL_ARB_texture_buffer_object +#define GL_TEXTURE_BUFFER_ARB 0x8C2A +#define GL_MAX_TEXTURE_BUFFER_SIZE_ARB 0x8C2B +#define GL_TEXTURE_BINDING_BUFFER_ARB 0x8C2C +#define GL_TEXTURE_BUFFER_DATA_STORE_BINDING_ARB 0x8C2D +#define GL_TEXTURE_BUFFER_FORMAT_ARB 0x8C2E +#endif + +#ifndef GL_ARB_texture_compression_rgtc +#define GL_COMPRESSED_RED_RGTC1 0x8DBB +#define GL_COMPRESSED_SIGNED_RED_RGTC1 0x8DBC +#define GL_COMPRESSED_RG_RGTC2 0x8DBD +#define GL_COMPRESSED_SIGNED_RG_RGTC2 0x8DBE +#endif + +#ifndef GL_ARB_texture_rg +#define GL_RG 0x8227 +#define GL_RG_INTEGER 0x8228 +#define GL_R8 0x8229 +#define GL_R16 0x822A +#define GL_RG8 0x822B +#define GL_RG16 0x822C +#define GL_R16F 0x822D +#define GL_R32F 0x822E +#define GL_RG16F 0x822F +#define GL_RG32F 0x8230 +#define GL_R8I 0x8231 +#define GL_R8UI 0x8232 +#define GL_R16I 0x8233 +#define GL_R16UI 0x8234 +#define GL_R32I 0x8235 +#define GL_R32UI 0x8236 +#define GL_RG8I 0x8237 +#define GL_RG8UI 0x8238 +#define GL_RG16I 0x8239 +#define GL_RG16UI 0x823A +#define GL_RG32I 0x823B +#define GL_RG32UI 0x823C +#endif + +#ifndef GL_ARB_vertex_array_object +#define GL_VERTEX_ARRAY_BINDING 0x85B5 +#endif + +#ifndef GL_EXT_abgr +#define GL_ABGR_EXT 0x8000 +#endif + +#ifndef GL_EXT_blend_color +#define GL_CONSTANT_COLOR_EXT 0x8001 +#define GL_ONE_MINUS_CONSTANT_COLOR_EXT 0x8002 +#define GL_CONSTANT_ALPHA_EXT 0x8003 +#define GL_ONE_MINUS_CONSTANT_ALPHA_EXT 0x8004 +#define GL_BLEND_COLOR_EXT 0x8005 +#endif + +#ifndef GL_EXT_polygon_offset +#define GL_POLYGON_OFFSET_EXT 0x8037 +#define GL_POLYGON_OFFSET_FACTOR_EXT 0x8038 +#define GL_POLYGON_OFFSET_BIAS_EXT 0x8039 +#endif + +#ifndef GL_EXT_texture +#define GL_ALPHA4_EXT 0x803B +#define GL_ALPHA8_EXT 0x803C +#define GL_ALPHA12_EXT 0x803D +#define GL_ALPHA16_EXT 0x803E +#define GL_LUMINANCE4_EXT 0x803F +#define GL_LUMINANCE8_EXT 0x8040 +#define GL_LUMINANCE12_EXT 0x8041 +#define GL_LUMINANCE16_EXT 0x8042 +#define GL_LUMINANCE4_ALPHA4_EXT 0x8043 +#define GL_LUMINANCE6_ALPHA2_EXT 0x8044 +#define GL_LUMINANCE8_ALPHA8_EXT 0x8045 +#define GL_LUMINANCE12_ALPHA4_EXT 0x8046 +#define GL_LUMINANCE12_ALPHA12_EXT 0x8047 +#define GL_LUMINANCE16_ALPHA16_EXT 0x8048 +#define GL_INTENSITY_EXT 0x8049 +#define GL_INTENSITY4_EXT 0x804A +#define GL_INTENSITY8_EXT 0x804B +#define GL_INTENSITY12_EXT 0x804C +#define GL_INTENSITY16_EXT 0x804D +#define GL_RGB2_EXT 0x804E +#define GL_RGB4_EXT 0x804F +#define GL_RGB5_EXT 0x8050 +#define GL_RGB8_EXT 0x8051 +#define GL_RGB10_EXT 0x8052 +#define GL_RGB12_EXT 0x8053 +#define GL_RGB16_EXT 0x8054 +#define GL_RGBA2_EXT 0x8055 +#define GL_RGBA4_EXT 0x8056 +#define GL_RGB5_A1_EXT 0x8057 +#define GL_RGBA8_EXT 0x8058 +#define GL_RGB10_A2_EXT 0x8059 +#define GL_RGBA12_EXT 0x805A +#define GL_RGBA16_EXT 0x805B +#define GL_TEXTURE_RED_SIZE_EXT 0x805C +#define GL_TEXTURE_GREEN_SIZE_EXT 0x805D +#define GL_TEXTURE_BLUE_SIZE_EXT 0x805E +#define GL_TEXTURE_ALPHA_SIZE_EXT 0x805F +#define GL_TEXTURE_LUMINANCE_SIZE_EXT 0x8060 +#define GL_TEXTURE_INTENSITY_SIZE_EXT 0x8061 +#define GL_REPLACE_EXT 0x8062 +#define GL_PROXY_TEXTURE_1D_EXT 0x8063 +#define GL_PROXY_TEXTURE_2D_EXT 0x8064 +#define GL_TEXTURE_TOO_LARGE_EXT 0x8065 +#endif + +#ifndef GL_EXT_texture3D +#define GL_PACK_SKIP_IMAGES_EXT 0x806B +#define GL_PACK_IMAGE_HEIGHT_EXT 0x806C +#define GL_UNPACK_SKIP_IMAGES_EXT 0x806D +#define GL_UNPACK_IMAGE_HEIGHT_EXT 0x806E +#define GL_TEXTURE_3D_EXT 0x806F +#define GL_PROXY_TEXTURE_3D_EXT 0x8070 +#define GL_TEXTURE_DEPTH_EXT 0x8071 +#define GL_TEXTURE_WRAP_R_EXT 0x8072 +#define GL_MAX_3D_TEXTURE_SIZE_EXT 0x8073 +#endif + +#ifndef GL_SGIS_texture_filter4 +#define GL_FILTER4_SGIS 0x8146 +#define GL_TEXTURE_FILTER4_SIZE_SGIS 0x8147 +#endif + +#ifndef GL_EXT_subtexture +#endif + +#ifndef GL_EXT_copy_texture +#endif + +#ifndef GL_EXT_histogram +#define GL_HISTOGRAM_EXT 0x8024 +#define GL_PROXY_HISTOGRAM_EXT 0x8025 +#define GL_HISTOGRAM_WIDTH_EXT 0x8026 +#define GL_HISTOGRAM_FORMAT_EXT 0x8027 +#define GL_HISTOGRAM_RED_SIZE_EXT 0x8028 +#define GL_HISTOGRAM_GREEN_SIZE_EXT 0x8029 +#define GL_HISTOGRAM_BLUE_SIZE_EXT 0x802A +#define GL_HISTOGRAM_ALPHA_SIZE_EXT 0x802B +#define GL_HISTOGRAM_LUMINANCE_SIZE_EXT 0x802C +#define GL_HISTOGRAM_SINK_EXT 0x802D +#define GL_MINMAX_EXT 0x802E +#define GL_MINMAX_FORMAT_EXT 0x802F +#define GL_MINMAX_SINK_EXT 0x8030 +#define GL_TABLE_TOO_LARGE_EXT 0x8031 +#endif + +#ifndef GL_EXT_convolution +#define GL_CONVOLUTION_1D_EXT 0x8010 +#define GL_CONVOLUTION_2D_EXT 0x8011 +#define GL_SEPARABLE_2D_EXT 0x8012 +#define GL_CONVOLUTION_BORDER_MODE_EXT 0x8013 +#define GL_CONVOLUTION_FILTER_SCALE_EXT 0x8014 +#define GL_CONVOLUTION_FILTER_BIAS_EXT 0x8015 +#define GL_REDUCE_EXT 0x8016 +#define GL_CONVOLUTION_FORMAT_EXT 0x8017 +#define GL_CONVOLUTION_WIDTH_EXT 0x8018 +#define GL_CONVOLUTION_HEIGHT_EXT 0x8019 +#define GL_MAX_CONVOLUTION_WIDTH_EXT 0x801A +#define GL_MAX_CONVOLUTION_HEIGHT_EXT 0x801B +#define GL_POST_CONVOLUTION_RED_SCALE_EXT 0x801C +#define GL_POST_CONVOLUTION_GREEN_SCALE_EXT 0x801D +#define GL_POST_CONVOLUTION_BLUE_SCALE_EXT 0x801E +#define GL_POST_CONVOLUTION_ALPHA_SCALE_EXT 0x801F +#define GL_POST_CONVOLUTION_RED_BIAS_EXT 0x8020 +#define GL_POST_CONVOLUTION_GREEN_BIAS_EXT 0x8021 +#define GL_POST_CONVOLUTION_BLUE_BIAS_EXT 0x8022 +#define GL_POST_CONVOLUTION_ALPHA_BIAS_EXT 0x8023 +#endif + +#ifndef GL_SGI_color_matrix +#define GL_COLOR_MATRIX_SGI 0x80B1 +#define GL_COLOR_MATRIX_STACK_DEPTH_SGI 0x80B2 +#define GL_MAX_COLOR_MATRIX_STACK_DEPTH_SGI 0x80B3 +#define GL_POST_COLOR_MATRIX_RED_SCALE_SGI 0x80B4 +#define GL_POST_COLOR_MATRIX_GREEN_SCALE_SGI 0x80B5 +#define GL_POST_COLOR_MATRIX_BLUE_SCALE_SGI 0x80B6 +#define GL_POST_COLOR_MATRIX_ALPHA_SCALE_SGI 0x80B7 +#define GL_POST_COLOR_MATRIX_RED_BIAS_SGI 0x80B8 +#define GL_POST_COLOR_MATRIX_GREEN_BIAS_SGI 0x80B9 +#define GL_POST_COLOR_MATRIX_BLUE_BIAS_SGI 0x80BA +#define GL_POST_COLOR_MATRIX_ALPHA_BIAS_SGI 0x80BB +#endif + +#ifndef GL_SGI_color_table +#define GL_COLOR_TABLE_SGI 0x80D0 +#define GL_POST_CONVOLUTION_COLOR_TABLE_SGI 0x80D1 +#define GL_POST_COLOR_MATRIX_COLOR_TABLE_SGI 0x80D2 +#define GL_PROXY_COLOR_TABLE_SGI 0x80D3 +#define GL_PROXY_POST_CONVOLUTION_COLOR_TABLE_SGI 0x80D4 +#define GL_PROXY_POST_COLOR_MATRIX_COLOR_TABLE_SGI 0x80D5 +#define GL_COLOR_TABLE_SCALE_SGI 0x80D6 +#define GL_COLOR_TABLE_BIAS_SGI 0x80D7 +#define GL_COLOR_TABLE_FORMAT_SGI 0x80D8 +#define GL_COLOR_TABLE_WIDTH_SGI 0x80D9 +#define GL_COLOR_TABLE_RED_SIZE_SGI 0x80DA +#define GL_COLOR_TABLE_GREEN_SIZE_SGI 0x80DB +#define GL_COLOR_TABLE_BLUE_SIZE_SGI 0x80DC +#define GL_COLOR_TABLE_ALPHA_SIZE_SGI 0x80DD +#define GL_COLOR_TABLE_LUMINANCE_SIZE_SGI 0x80DE +#define GL_COLOR_TABLE_INTENSITY_SIZE_SGI 0x80DF +#endif + +#ifndef GL_SGIS_pixel_texture +#define GL_PIXEL_TEXTURE_SGIS 0x8353 +#define GL_PIXEL_FRAGMENT_RGB_SOURCE_SGIS 0x8354 +#define GL_PIXEL_FRAGMENT_ALPHA_SOURCE_SGIS 0x8355 +#define GL_PIXEL_GROUP_COLOR_SGIS 0x8356 +#endif + +#ifndef GL_SGIX_pixel_texture +#define GL_PIXEL_TEX_GEN_SGIX 0x8139 +#define GL_PIXEL_TEX_GEN_MODE_SGIX 0x832B +#endif + +#ifndef GL_SGIS_texture4D +#define GL_PACK_SKIP_VOLUMES_SGIS 0x8130 +#define GL_PACK_IMAGE_DEPTH_SGIS 0x8131 +#define GL_UNPACK_SKIP_VOLUMES_SGIS 0x8132 +#define GL_UNPACK_IMAGE_DEPTH_SGIS 0x8133 +#define GL_TEXTURE_4D_SGIS 0x8134 +#define GL_PROXY_TEXTURE_4D_SGIS 0x8135 +#define GL_TEXTURE_4DSIZE_SGIS 0x8136 +#define GL_TEXTURE_WRAP_Q_SGIS 0x8137 +#define GL_MAX_4D_TEXTURE_SIZE_SGIS 0x8138 +#define GL_TEXTURE_4D_BINDING_SGIS 0x814F +#endif + +#ifndef GL_SGI_texture_color_table +#define GL_TEXTURE_COLOR_TABLE_SGI 0x80BC +#define GL_PROXY_TEXTURE_COLOR_TABLE_SGI 0x80BD +#endif + +#ifndef GL_EXT_cmyka +#define GL_CMYK_EXT 0x800C +#define GL_CMYKA_EXT 0x800D +#define GL_PACK_CMYK_HINT_EXT 0x800E +#define GL_UNPACK_CMYK_HINT_EXT 0x800F +#endif + +#ifndef GL_EXT_texture_object +#define GL_TEXTURE_PRIORITY_EXT 0x8066 +#define GL_TEXTURE_RESIDENT_EXT 0x8067 +#define GL_TEXTURE_1D_BINDING_EXT 0x8068 +#define GL_TEXTURE_2D_BINDING_EXT 0x8069 +#define GL_TEXTURE_3D_BINDING_EXT 0x806A +#endif + +#ifndef GL_SGIS_detail_texture +#define GL_DETAIL_TEXTURE_2D_SGIS 0x8095 +#define GL_DETAIL_TEXTURE_2D_BINDING_SGIS 0x8096 +#define GL_LINEAR_DETAIL_SGIS 0x8097 +#define GL_LINEAR_DETAIL_ALPHA_SGIS 0x8098 +#define GL_LINEAR_DETAIL_COLOR_SGIS 0x8099 +#define GL_DETAIL_TEXTURE_LEVEL_SGIS 0x809A +#define GL_DETAIL_TEXTURE_MODE_SGIS 0x809B +#define GL_DETAIL_TEXTURE_FUNC_POINTS_SGIS 0x809C +#endif + +#ifndef GL_SGIS_sharpen_texture +#define GL_LINEAR_SHARPEN_SGIS 0x80AD +#define GL_LINEAR_SHARPEN_ALPHA_SGIS 0x80AE +#define GL_LINEAR_SHARPEN_COLOR_SGIS 0x80AF +#define GL_SHARPEN_TEXTURE_FUNC_POINTS_SGIS 0x80B0 +#endif + +#ifndef GL_EXT_packed_pixels +#define GL_UNSIGNED_BYTE_3_3_2_EXT 0x8032 +#define GL_UNSIGNED_SHORT_4_4_4_4_EXT 0x8033 +#define GL_UNSIGNED_SHORT_5_5_5_1_EXT 0x8034 +#define GL_UNSIGNED_INT_8_8_8_8_EXT 0x8035 +#define GL_UNSIGNED_INT_10_10_10_2_EXT 0x8036 +#endif + +#ifndef GL_SGIS_texture_lod +#define GL_TEXTURE_MIN_LOD_SGIS 0x813A +#define GL_TEXTURE_MAX_LOD_SGIS 0x813B +#define GL_TEXTURE_BASE_LEVEL_SGIS 0x813C +#define GL_TEXTURE_MAX_LEVEL_SGIS 0x813D +#endif + +#ifndef GL_SGIS_multisample +#define GL_MULTISAMPLE_SGIS 0x809D +#define GL_SAMPLE_ALPHA_TO_MASK_SGIS 0x809E +#define GL_SAMPLE_ALPHA_TO_ONE_SGIS 0x809F +#define GL_SAMPLE_MASK_SGIS 0x80A0 +#define GL_1PASS_SGIS 0x80A1 +#define GL_2PASS_0_SGIS 0x80A2 +#define GL_2PASS_1_SGIS 0x80A3 +#define GL_4PASS_0_SGIS 0x80A4 +#define GL_4PASS_1_SGIS 0x80A5 +#define GL_4PASS_2_SGIS 0x80A6 +#define GL_4PASS_3_SGIS 0x80A7 +#define GL_SAMPLE_BUFFERS_SGIS 0x80A8 +#define GL_SAMPLES_SGIS 0x80A9 +#define GL_SAMPLE_MASK_VALUE_SGIS 0x80AA +#define GL_SAMPLE_MASK_INVERT_SGIS 0x80AB +#define GL_SAMPLE_PATTERN_SGIS 0x80AC +#endif + +#ifndef GL_EXT_rescale_normal +#define GL_RESCALE_NORMAL_EXT 0x803A +#endif + +#ifndef GL_EXT_vertex_array +#define GL_VERTEX_ARRAY_EXT 0x8074 +#define GL_NORMAL_ARRAY_EXT 0x8075 +#define GL_COLOR_ARRAY_EXT 0x8076 +#define GL_INDEX_ARRAY_EXT 0x8077 +#define GL_TEXTURE_COORD_ARRAY_EXT 0x8078 +#define GL_EDGE_FLAG_ARRAY_EXT 0x8079 +#define GL_VERTEX_ARRAY_SIZE_EXT 0x807A +#define GL_VERTEX_ARRAY_TYPE_EXT 0x807B +#define GL_VERTEX_ARRAY_STRIDE_EXT 0x807C +#define GL_VERTEX_ARRAY_COUNT_EXT 0x807D +#define GL_NORMAL_ARRAY_TYPE_EXT 0x807E +#define GL_NORMAL_ARRAY_STRIDE_EXT 0x807F +#define GL_NORMAL_ARRAY_COUNT_EXT 0x8080 +#define GL_COLOR_ARRAY_SIZE_EXT 0x8081 +#define GL_COLOR_ARRAY_TYPE_EXT 0x8082 +#define GL_COLOR_ARRAY_STRIDE_EXT 0x8083 +#define GL_COLOR_ARRAY_COUNT_EXT 0x8084 +#define GL_INDEX_ARRAY_TYPE_EXT 0x8085 +#define GL_INDEX_ARRAY_STRIDE_EXT 0x8086 +#define GL_INDEX_ARRAY_COUNT_EXT 0x8087 +#define GL_TEXTURE_COORD_ARRAY_SIZE_EXT 0x8088 +#define GL_TEXTURE_COORD_ARRAY_TYPE_EXT 0x8089 +#define GL_TEXTURE_COORD_ARRAY_STRIDE_EXT 0x808A +#define GL_TEXTURE_COORD_ARRAY_COUNT_EXT 0x808B +#define GL_EDGE_FLAG_ARRAY_STRIDE_EXT 0x808C +#define GL_EDGE_FLAG_ARRAY_COUNT_EXT 0x808D +#define GL_VERTEX_ARRAY_POINTER_EXT 0x808E +#define GL_NORMAL_ARRAY_POINTER_EXT 0x808F +#define GL_COLOR_ARRAY_POINTER_EXT 0x8090 +#define GL_INDEX_ARRAY_POINTER_EXT 0x8091 +#define GL_TEXTURE_COORD_ARRAY_POINTER_EXT 0x8092 +#define GL_EDGE_FLAG_ARRAY_POINTER_EXT 0x8093 +#endif + +#ifndef GL_EXT_misc_attribute +#endif + +#ifndef GL_SGIS_generate_mipmap +#define GL_GENERATE_MIPMAP_SGIS 0x8191 +#define GL_GENERATE_MIPMAP_HINT_SGIS 0x8192 +#endif + +#ifndef GL_SGIX_clipmap +#define GL_LINEAR_CLIPMAP_LINEAR_SGIX 0x8170 +#define GL_TEXTURE_CLIPMAP_CENTER_SGIX 0x8171 +#define GL_TEXTURE_CLIPMAP_FRAME_SGIX 0x8172 +#define GL_TEXTURE_CLIPMAP_OFFSET_SGIX 0x8173 +#define GL_TEXTURE_CLIPMAP_VIRTUAL_DEPTH_SGIX 0x8174 +#define GL_TEXTURE_CLIPMAP_LOD_OFFSET_SGIX 0x8175 +#define GL_TEXTURE_CLIPMAP_DEPTH_SGIX 0x8176 +#define GL_MAX_CLIPMAP_DEPTH_SGIX 0x8177 +#define GL_MAX_CLIPMAP_VIRTUAL_DEPTH_SGIX 0x8178 +#define GL_NEAREST_CLIPMAP_NEAREST_SGIX 0x844D +#define GL_NEAREST_CLIPMAP_LINEAR_SGIX 0x844E +#define GL_LINEAR_CLIPMAP_NEAREST_SGIX 0x844F +#endif + +#ifndef GL_SGIX_shadow +#define GL_TEXTURE_COMPARE_SGIX 0x819A +#define GL_TEXTURE_COMPARE_OPERATOR_SGIX 0x819B +#define GL_TEXTURE_LEQUAL_R_SGIX 0x819C +#define GL_TEXTURE_GEQUAL_R_SGIX 0x819D +#endif + +#ifndef GL_SGIS_texture_edge_clamp +#define GL_CLAMP_TO_EDGE_SGIS 0x812F +#endif + +#ifndef GL_SGIS_texture_border_clamp +#define GL_CLAMP_TO_BORDER_SGIS 0x812D +#endif + +#ifndef GL_EXT_blend_minmax +#define GL_FUNC_ADD_EXT 0x8006 +#define GL_MIN_EXT 0x8007 +#define GL_MAX_EXT 0x8008 +#define GL_BLEND_EQUATION_EXT 0x8009 +#endif + +#ifndef GL_EXT_blend_subtract +#define GL_FUNC_SUBTRACT_EXT 0x800A +#define GL_FUNC_REVERSE_SUBTRACT_EXT 0x800B +#endif + +#ifndef GL_EXT_blend_logic_op +#endif + +#ifndef GL_SGIX_interlace +#define GL_INTERLACE_SGIX 0x8094 +#endif + +#ifndef GL_SGIX_pixel_tiles +#define GL_PIXEL_TILE_BEST_ALIGNMENT_SGIX 0x813E +#define GL_PIXEL_TILE_CACHE_INCREMENT_SGIX 0x813F +#define GL_PIXEL_TILE_WIDTH_SGIX 0x8140 +#define GL_PIXEL_TILE_HEIGHT_SGIX 0x8141 +#define GL_PIXEL_TILE_GRID_WIDTH_SGIX 0x8142 +#define GL_PIXEL_TILE_GRID_HEIGHT_SGIX 0x8143 +#define GL_PIXEL_TILE_GRID_DEPTH_SGIX 0x8144 +#define GL_PIXEL_TILE_CACHE_SIZE_SGIX 0x8145 +#endif + +#ifndef GL_SGIS_texture_select +#define GL_DUAL_ALPHA4_SGIS 0x8110 +#define GL_DUAL_ALPHA8_SGIS 0x8111 +#define GL_DUAL_ALPHA12_SGIS 0x8112 +#define GL_DUAL_ALPHA16_SGIS 0x8113 +#define GL_DUAL_LUMINANCE4_SGIS 0x8114 +#define GL_DUAL_LUMINANCE8_SGIS 0x8115 +#define GL_DUAL_LUMINANCE12_SGIS 0x8116 +#define GL_DUAL_LUMINANCE16_SGIS 0x8117 +#define GL_DUAL_INTENSITY4_SGIS 0x8118 +#define GL_DUAL_INTENSITY8_SGIS 0x8119 +#define GL_DUAL_INTENSITY12_SGIS 0x811A +#define GL_DUAL_INTENSITY16_SGIS 0x811B +#define GL_DUAL_LUMINANCE_ALPHA4_SGIS 0x811C +#define GL_DUAL_LUMINANCE_ALPHA8_SGIS 0x811D +#define GL_QUAD_ALPHA4_SGIS 0x811E +#define GL_QUAD_ALPHA8_SGIS 0x811F +#define GL_QUAD_LUMINANCE4_SGIS 0x8120 +#define GL_QUAD_LUMINANCE8_SGIS 0x8121 +#define GL_QUAD_INTENSITY4_SGIS 0x8122 +#define GL_QUAD_INTENSITY8_SGIS 0x8123 +#define GL_DUAL_TEXTURE_SELECT_SGIS 0x8124 +#define GL_QUAD_TEXTURE_SELECT_SGIS 0x8125 +#endif + +#ifndef GL_SGIX_sprite +#define GL_SPRITE_SGIX 0x8148 +#define GL_SPRITE_MODE_SGIX 0x8149 +#define GL_SPRITE_AXIS_SGIX 0x814A +#define GL_SPRITE_TRANSLATION_SGIX 0x814B +#define GL_SPRITE_AXIAL_SGIX 0x814C +#define GL_SPRITE_OBJECT_ALIGNED_SGIX 0x814D +#define GL_SPRITE_EYE_ALIGNED_SGIX 0x814E +#endif + +#ifndef GL_SGIX_texture_multi_buffer +#define GL_TEXTURE_MULTI_BUFFER_HINT_SGIX 0x812E +#endif + +#ifndef GL_EXT_point_parameters +#define GL_POINT_SIZE_MIN_EXT 0x8126 +#define GL_POINT_SIZE_MAX_EXT 0x8127 +#define GL_POINT_FADE_THRESHOLD_SIZE_EXT 0x8128 +#define GL_DISTANCE_ATTENUATION_EXT 0x8129 +#endif + +#ifndef GL_SGIS_point_parameters +#define GL_POINT_SIZE_MIN_SGIS 0x8126 +#define GL_POINT_SIZE_MAX_SGIS 0x8127 +#define GL_POINT_FADE_THRESHOLD_SIZE_SGIS 0x8128 +#define GL_DISTANCE_ATTENUATION_SGIS 0x8129 +#endif + +#ifndef GL_SGIX_instruments +#define GL_INSTRUMENT_BUFFER_POINTER_SGIX 0x8180 +#define GL_INSTRUMENT_MEASUREMENTS_SGIX 0x8181 +#endif + +#ifndef GL_SGIX_texture_scale_bias +#define GL_POST_TEXTURE_FILTER_BIAS_SGIX 0x8179 +#define GL_POST_TEXTURE_FILTER_SCALE_SGIX 0x817A +#define GL_POST_TEXTURE_FILTER_BIAS_RANGE_SGIX 0x817B +#define GL_POST_TEXTURE_FILTER_SCALE_RANGE_SGIX 0x817C +#endif + +#ifndef GL_SGIX_framezoom +#define GL_FRAMEZOOM_SGIX 0x818B +#define GL_FRAMEZOOM_FACTOR_SGIX 0x818C +#define GL_MAX_FRAMEZOOM_FACTOR_SGIX 0x818D +#endif + +#ifndef GL_SGIX_tag_sample_buffer +#endif + +#ifndef GL_FfdMaskSGIX +#define GL_TEXTURE_DEFORMATION_BIT_SGIX 0x00000001 +#define GL_GEOMETRY_DEFORMATION_BIT_SGIX 0x00000002 +#endif + +#ifndef GL_SGIX_polynomial_ffd +#define GL_GEOMETRY_DEFORMATION_SGIX 0x8194 +#define GL_TEXTURE_DEFORMATION_SGIX 0x8195 +#define GL_DEFORMATIONS_MASK_SGIX 0x8196 +#define GL_MAX_DEFORMATION_ORDER_SGIX 0x8197 +#endif + +#ifndef GL_SGIX_reference_plane +#define GL_REFERENCE_PLANE_SGIX 0x817D +#define GL_REFERENCE_PLANE_EQUATION_SGIX 0x817E +#endif + +#ifndef GL_SGIX_flush_raster +#endif + +#ifndef GL_SGIX_depth_texture +#define GL_DEPTH_COMPONENT16_SGIX 0x81A5 +#define GL_DEPTH_COMPONENT24_SGIX 0x81A6 +#define GL_DEPTH_COMPONENT32_SGIX 0x81A7 +#endif + +#ifndef GL_SGIS_fog_function +#define GL_FOG_FUNC_SGIS 0x812A +#define GL_FOG_FUNC_POINTS_SGIS 0x812B +#define GL_MAX_FOG_FUNC_POINTS_SGIS 0x812C +#endif + +#ifndef GL_SGIX_fog_offset +#define GL_FOG_OFFSET_SGIX 0x8198 +#define GL_FOG_OFFSET_VALUE_SGIX 0x8199 +#endif + +#ifndef GL_HP_image_transform +#define GL_IMAGE_SCALE_X_HP 0x8155 +#define GL_IMAGE_SCALE_Y_HP 0x8156 +#define GL_IMAGE_TRANSLATE_X_HP 0x8157 +#define GL_IMAGE_TRANSLATE_Y_HP 0x8158 +#define GL_IMAGE_ROTATE_ANGLE_HP 0x8159 +#define GL_IMAGE_ROTATE_ORIGIN_X_HP 0x815A +#define GL_IMAGE_ROTATE_ORIGIN_Y_HP 0x815B +#define GL_IMAGE_MAG_FILTER_HP 0x815C +#define GL_IMAGE_MIN_FILTER_HP 0x815D +#define GL_IMAGE_CUBIC_WEIGHT_HP 0x815E +#define GL_CUBIC_HP 0x815F +#define GL_AVERAGE_HP 0x8160 +#define GL_IMAGE_TRANSFORM_2D_HP 0x8161 +#define GL_POST_IMAGE_TRANSFORM_COLOR_TABLE_HP 0x8162 +#define GL_PROXY_POST_IMAGE_TRANSFORM_COLOR_TABLE_HP 0x8163 +#endif + +#ifndef GL_HP_convolution_border_modes +#define GL_IGNORE_BORDER_HP 0x8150 +#define GL_CONSTANT_BORDER_HP 0x8151 +#define GL_REPLICATE_BORDER_HP 0x8153 +#define GL_CONVOLUTION_BORDER_COLOR_HP 0x8154 +#endif + +#ifndef GL_INGR_palette_buffer +#endif + +#ifndef GL_SGIX_texture_add_env +#define GL_TEXTURE_ENV_BIAS_SGIX 0x80BE +#endif + +#ifndef GL_EXT_color_subtable +#endif + +#ifndef GL_PGI_vertex_hints +#define GL_VERTEX_DATA_HINT_PGI 0x1A22A +#define GL_VERTEX_CONSISTENT_HINT_PGI 0x1A22B +#define GL_MATERIAL_SIDE_HINT_PGI 0x1A22C +#define GL_MAX_VERTEX_HINT_PGI 0x1A22D +#define GL_COLOR3_BIT_PGI 0x00010000 +#define GL_COLOR4_BIT_PGI 0x00020000 +#define GL_EDGEFLAG_BIT_PGI 0x00040000 +#define GL_INDEX_BIT_PGI 0x00080000 +#define GL_MAT_AMBIENT_BIT_PGI 0x00100000 +#define GL_MAT_AMBIENT_AND_DIFFUSE_BIT_PGI 0x00200000 +#define GL_MAT_DIFFUSE_BIT_PGI 0x00400000 +#define GL_MAT_EMISSION_BIT_PGI 0x00800000 +#define GL_MAT_COLOR_INDEXES_BIT_PGI 0x01000000 +#define GL_MAT_SHININESS_BIT_PGI 0x02000000 +#define GL_MAT_SPECULAR_BIT_PGI 0x04000000 +#define GL_NORMAL_BIT_PGI 0x08000000 +#define GL_TEXCOORD1_BIT_PGI 0x10000000 +#define GL_TEXCOORD2_BIT_PGI 0x20000000 +#define GL_TEXCOORD3_BIT_PGI 0x40000000 +#define GL_TEXCOORD4_BIT_PGI 0x80000000 +#define GL_VERTEX23_BIT_PGI 0x00000004 +#define GL_VERTEX4_BIT_PGI 0x00000008 +#endif + +#ifndef GL_PGI_misc_hints +#define GL_PREFER_DOUBLEBUFFER_HINT_PGI 0x1A1F8 +#define GL_CONSERVE_MEMORY_HINT_PGI 0x1A1FD +#define GL_RECLAIM_MEMORY_HINT_PGI 0x1A1FE +#define GL_NATIVE_GRAPHICS_HANDLE_PGI 0x1A202 +#define GL_NATIVE_GRAPHICS_BEGIN_HINT_PGI 0x1A203 +#define GL_NATIVE_GRAPHICS_END_HINT_PGI 0x1A204 +#define GL_ALWAYS_FAST_HINT_PGI 0x1A20C +#define GL_ALWAYS_SOFT_HINT_PGI 0x1A20D +#define GL_ALLOW_DRAW_OBJ_HINT_PGI 0x1A20E +#define GL_ALLOW_DRAW_WIN_HINT_PGI 0x1A20F +#define GL_ALLOW_DRAW_FRG_HINT_PGI 0x1A210 +#define GL_ALLOW_DRAW_MEM_HINT_PGI 0x1A211 +#define GL_STRICT_DEPTHFUNC_HINT_PGI 0x1A216 +#define GL_STRICT_LIGHTING_HINT_PGI 0x1A217 +#define GL_STRICT_SCISSOR_HINT_PGI 0x1A218 +#define GL_FULL_STIPPLE_HINT_PGI 0x1A219 +#define GL_CLIP_NEAR_HINT_PGI 0x1A220 +#define GL_CLIP_FAR_HINT_PGI 0x1A221 +#define GL_WIDE_LINE_HINT_PGI 0x1A222 +#define GL_BACK_NORMALS_HINT_PGI 0x1A223 +#endif + +#ifndef GL_EXT_paletted_texture +#define GL_COLOR_INDEX1_EXT 0x80E2 +#define GL_COLOR_INDEX2_EXT 0x80E3 +#define GL_COLOR_INDEX4_EXT 0x80E4 +#define GL_COLOR_INDEX8_EXT 0x80E5 +#define GL_COLOR_INDEX12_EXT 0x80E6 +#define GL_COLOR_INDEX16_EXT 0x80E7 +#define GL_TEXTURE_INDEX_SIZE_EXT 0x80ED +#endif + +#ifndef GL_EXT_clip_volume_hint +#define GL_CLIP_VOLUME_CLIPPING_HINT_EXT 0x80F0 +#endif + +#ifndef GL_SGIX_list_priority +#define GL_LIST_PRIORITY_SGIX 0x8182 +#endif + +#ifndef GL_SGIX_ir_instrument1 +#define GL_IR_INSTRUMENT1_SGIX 0x817F +#endif + +#ifndef GL_SGIX_calligraphic_fragment +#define GL_CALLIGRAPHIC_FRAGMENT_SGIX 0x8183 +#endif + +#ifndef GL_SGIX_texture_lod_bias +#define GL_TEXTURE_LOD_BIAS_S_SGIX 0x818E +#define GL_TEXTURE_LOD_BIAS_T_SGIX 0x818F +#define GL_TEXTURE_LOD_BIAS_R_SGIX 0x8190 +#endif + +#ifndef GL_SGIX_shadow_ambient +#define GL_SHADOW_AMBIENT_SGIX 0x80BF +#endif + +#ifndef GL_EXT_index_texture +#endif + +#ifndef GL_EXT_index_material +#define GL_INDEX_MATERIAL_EXT 0x81B8 +#define GL_INDEX_MATERIAL_PARAMETER_EXT 0x81B9 +#define GL_INDEX_MATERIAL_FACE_EXT 0x81BA +#endif + +#ifndef GL_EXT_index_func +#define GL_INDEX_TEST_EXT 0x81B5 +#define GL_INDEX_TEST_FUNC_EXT 0x81B6 +#define GL_INDEX_TEST_REF_EXT 0x81B7 +#endif + +#ifndef GL_EXT_index_array_formats +#define GL_IUI_V2F_EXT 0x81AD +#define GL_IUI_V3F_EXT 0x81AE +#define GL_IUI_N3F_V2F_EXT 0x81AF +#define GL_IUI_N3F_V3F_EXT 0x81B0 +#define GL_T2F_IUI_V2F_EXT 0x81B1 +#define GL_T2F_IUI_V3F_EXT 0x81B2 +#define GL_T2F_IUI_N3F_V2F_EXT 0x81B3 +#define GL_T2F_IUI_N3F_V3F_EXT 0x81B4 +#endif + +#ifndef GL_EXT_compiled_vertex_array +#define GL_ARRAY_ELEMENT_LOCK_FIRST_EXT 0x81A8 +#define GL_ARRAY_ELEMENT_LOCK_COUNT_EXT 0x81A9 +#endif + +#ifndef GL_EXT_cull_vertex +#define GL_CULL_VERTEX_EXT 0x81AA +#define GL_CULL_VERTEX_EYE_POSITION_EXT 0x81AB +#define GL_CULL_VERTEX_OBJECT_POSITION_EXT 0x81AC +#endif + +#ifndef GL_SGIX_ycrcb +#define GL_YCRCB_422_SGIX 0x81BB +#define GL_YCRCB_444_SGIX 0x81BC +#endif + +#ifndef GL_SGIX_fragment_lighting +#define GL_FRAGMENT_LIGHTING_SGIX 0x8400 +#define GL_FRAGMENT_COLOR_MATERIAL_SGIX 0x8401 +#define GL_FRAGMENT_COLOR_MATERIAL_FACE_SGIX 0x8402 +#define GL_FRAGMENT_COLOR_MATERIAL_PARAMETER_SGIX 0x8403 +#define GL_MAX_FRAGMENT_LIGHTS_SGIX 0x8404 +#define GL_MAX_ACTIVE_LIGHTS_SGIX 0x8405 +#define GL_CURRENT_RASTER_NORMAL_SGIX 0x8406 +#define GL_LIGHT_ENV_MODE_SGIX 0x8407 +#define GL_FRAGMENT_LIGHT_MODEL_LOCAL_VIEWER_SGIX 0x8408 +#define GL_FRAGMENT_LIGHT_MODEL_TWO_SIDE_SGIX 0x8409 +#define GL_FRAGMENT_LIGHT_MODEL_AMBIENT_SGIX 0x840A +#define GL_FRAGMENT_LIGHT_MODEL_NORMAL_INTERPOLATION_SGIX 0x840B +#define GL_FRAGMENT_LIGHT0_SGIX 0x840C +#define GL_FRAGMENT_LIGHT1_SGIX 0x840D +#define GL_FRAGMENT_LIGHT2_SGIX 0x840E +#define GL_FRAGMENT_LIGHT3_SGIX 0x840F +#define GL_FRAGMENT_LIGHT4_SGIX 0x8410 +#define GL_FRAGMENT_LIGHT5_SGIX 0x8411 +#define GL_FRAGMENT_LIGHT6_SGIX 0x8412 +#define GL_FRAGMENT_LIGHT7_SGIX 0x8413 +#endif + +#ifndef GL_IBM_rasterpos_clip +#define GL_RASTER_POSITION_UNCLIPPED_IBM 0x19262 +#endif + +#ifndef GL_HP_texture_lighting +#define GL_TEXTURE_LIGHTING_MODE_HP 0x8167 +#define GL_TEXTURE_POST_SPECULAR_HP 0x8168 +#define GL_TEXTURE_PRE_SPECULAR_HP 0x8169 +#endif + +#ifndef GL_EXT_draw_range_elements +#define GL_MAX_ELEMENTS_VERTICES_EXT 0x80E8 +#define GL_MAX_ELEMENTS_INDICES_EXT 0x80E9 +#endif + +#ifndef GL_WIN_phong_shading +#define GL_PHONG_WIN 0x80EA +#define GL_PHONG_HINT_WIN 0x80EB +#endif + +#ifndef GL_WIN_specular_fog +#define GL_FOG_SPECULAR_TEXTURE_WIN 0x80EC +#endif + +#ifndef GL_EXT_light_texture +#define GL_FRAGMENT_MATERIAL_EXT 0x8349 +#define GL_FRAGMENT_NORMAL_EXT 0x834A +#define GL_FRAGMENT_COLOR_EXT 0x834C +#define GL_ATTENUATION_EXT 0x834D +#define GL_SHADOW_ATTENUATION_EXT 0x834E +#define GL_TEXTURE_APPLICATION_MODE_EXT 0x834F +#define GL_TEXTURE_LIGHT_EXT 0x8350 +#define GL_TEXTURE_MATERIAL_FACE_EXT 0x8351 +#define GL_TEXTURE_MATERIAL_PARAMETER_EXT 0x8352 +/* reuse GL_FRAGMENT_DEPTH_EXT */ +#endif + +#ifndef GL_SGIX_blend_alpha_minmax +#define GL_ALPHA_MIN_SGIX 0x8320 +#define GL_ALPHA_MAX_SGIX 0x8321 +#endif + +#ifndef GL_SGIX_impact_pixel_texture +#define GL_PIXEL_TEX_GEN_Q_CEILING_SGIX 0x8184 +#define GL_PIXEL_TEX_GEN_Q_ROUND_SGIX 0x8185 +#define GL_PIXEL_TEX_GEN_Q_FLOOR_SGIX 0x8186 +#define GL_PIXEL_TEX_GEN_ALPHA_REPLACE_SGIX 0x8187 +#define GL_PIXEL_TEX_GEN_ALPHA_NO_REPLACE_SGIX 0x8188 +#define GL_PIXEL_TEX_GEN_ALPHA_LS_SGIX 0x8189 +#define GL_PIXEL_TEX_GEN_ALPHA_MS_SGIX 0x818A +#endif + +#ifndef GL_EXT_bgra +#define GL_BGR_EXT 0x80E0 +#define GL_BGRA_EXT 0x80E1 +#endif + +#ifndef GL_SGIX_async +#define GL_ASYNC_MARKER_SGIX 0x8329 +#endif + +#ifndef GL_SGIX_async_pixel +#define GL_ASYNC_TEX_IMAGE_SGIX 0x835C +#define GL_ASYNC_DRAW_PIXELS_SGIX 0x835D +#define GL_ASYNC_READ_PIXELS_SGIX 0x835E +#define GL_MAX_ASYNC_TEX_IMAGE_SGIX 0x835F +#define GL_MAX_ASYNC_DRAW_PIXELS_SGIX 0x8360 +#define GL_MAX_ASYNC_READ_PIXELS_SGIX 0x8361 +#endif + +#ifndef GL_SGIX_async_histogram +#define GL_ASYNC_HISTOGRAM_SGIX 0x832C +#define GL_MAX_ASYNC_HISTOGRAM_SGIX 0x832D +#endif + +#ifndef GL_INTEL_texture_scissor +#endif + +#ifndef GL_INTEL_parallel_arrays +#define GL_PARALLEL_ARRAYS_INTEL 0x83F4 +#define GL_VERTEX_ARRAY_PARALLEL_POINTERS_INTEL 0x83F5 +#define GL_NORMAL_ARRAY_PARALLEL_POINTERS_INTEL 0x83F6 +#define GL_COLOR_ARRAY_PARALLEL_POINTERS_INTEL 0x83F7 +#define GL_TEXTURE_COORD_ARRAY_PARALLEL_POINTERS_INTEL 0x83F8 +#endif + +#ifndef GL_HP_occlusion_test +#define GL_OCCLUSION_TEST_HP 0x8165 +#define GL_OCCLUSION_TEST_RESULT_HP 0x8166 +#endif + +#ifndef GL_EXT_pixel_transform +#define GL_PIXEL_TRANSFORM_2D_EXT 0x8330 +#define GL_PIXEL_MAG_FILTER_EXT 0x8331 +#define GL_PIXEL_MIN_FILTER_EXT 0x8332 +#define GL_PIXEL_CUBIC_WEIGHT_EXT 0x8333 +#define GL_CUBIC_EXT 0x8334 +#define GL_AVERAGE_EXT 0x8335 +#define GL_PIXEL_TRANSFORM_2D_STACK_DEPTH_EXT 0x8336 +#define GL_MAX_PIXEL_TRANSFORM_2D_STACK_DEPTH_EXT 0x8337 +#define GL_PIXEL_TRANSFORM_2D_MATRIX_EXT 0x8338 +#endif + +#ifndef GL_EXT_pixel_transform_color_table +#endif + +#ifndef GL_EXT_shared_texture_palette +#define GL_SHARED_TEXTURE_PALETTE_EXT 0x81FB +#endif + +#ifndef GL_EXT_separate_specular_color +#define GL_LIGHT_MODEL_COLOR_CONTROL_EXT 0x81F8 +#define GL_SINGLE_COLOR_EXT 0x81F9 +#define GL_SEPARATE_SPECULAR_COLOR_EXT 0x81FA +#endif + +#ifndef GL_EXT_secondary_color +#define GL_COLOR_SUM_EXT 0x8458 +#define GL_CURRENT_SECONDARY_COLOR_EXT 0x8459 +#define GL_SECONDARY_COLOR_ARRAY_SIZE_EXT 0x845A +#define GL_SECONDARY_COLOR_ARRAY_TYPE_EXT 0x845B +#define GL_SECONDARY_COLOR_ARRAY_STRIDE_EXT 0x845C +#define GL_SECONDARY_COLOR_ARRAY_POINTER_EXT 0x845D +#define GL_SECONDARY_COLOR_ARRAY_EXT 0x845E +#endif + +#ifndef GL_EXT_texture_perturb_normal +#define GL_PERTURB_EXT 0x85AE +#define GL_TEXTURE_NORMAL_EXT 0x85AF +#endif + +#ifndef GL_EXT_multi_draw_arrays +#endif + +#ifndef GL_EXT_fog_coord +#define GL_FOG_COORDINATE_SOURCE_EXT 0x8450 +#define GL_FOG_COORDINATE_EXT 0x8451 +#define GL_FRAGMENT_DEPTH_EXT 0x8452 +#define GL_CURRENT_FOG_COORDINATE_EXT 0x8453 +#define GL_FOG_COORDINATE_ARRAY_TYPE_EXT 0x8454 +#define GL_FOG_COORDINATE_ARRAY_STRIDE_EXT 0x8455 +#define GL_FOG_COORDINATE_ARRAY_POINTER_EXT 0x8456 +#define GL_FOG_COORDINATE_ARRAY_EXT 0x8457 +#endif + +#ifndef GL_REND_screen_coordinates +#define GL_SCREEN_COORDINATES_REND 0x8490 +#define GL_INVERTED_SCREEN_W_REND 0x8491 +#endif + +#ifndef GL_EXT_coordinate_frame +#define GL_TANGENT_ARRAY_EXT 0x8439 +#define GL_BINORMAL_ARRAY_EXT 0x843A +#define GL_CURRENT_TANGENT_EXT 0x843B +#define GL_CURRENT_BINORMAL_EXT 0x843C +#define GL_TANGENT_ARRAY_TYPE_EXT 0x843E +#define GL_TANGENT_ARRAY_STRIDE_EXT 0x843F +#define GL_BINORMAL_ARRAY_TYPE_EXT 0x8440 +#define GL_BINORMAL_ARRAY_STRIDE_EXT 0x8441 +#define GL_TANGENT_ARRAY_POINTER_EXT 0x8442 +#define GL_BINORMAL_ARRAY_POINTER_EXT 0x8443 +#define GL_MAP1_TANGENT_EXT 0x8444 +#define GL_MAP2_TANGENT_EXT 0x8445 +#define GL_MAP1_BINORMAL_EXT 0x8446 +#define GL_MAP2_BINORMAL_EXT 0x8447 +#endif + +#ifndef GL_EXT_texture_env_combine +#define GL_COMBINE_EXT 0x8570 +#define GL_COMBINE_RGB_EXT 0x8571 +#define GL_COMBINE_ALPHA_EXT 0x8572 +#define GL_RGB_SCALE_EXT 0x8573 +#define GL_ADD_SIGNED_EXT 0x8574 +#define GL_INTERPOLATE_EXT 0x8575 +#define GL_CONSTANT_EXT 0x8576 +#define GL_PRIMARY_COLOR_EXT 0x8577 +#define GL_PREVIOUS_EXT 0x8578 +#define GL_SOURCE0_RGB_EXT 0x8580 +#define GL_SOURCE1_RGB_EXT 0x8581 +#define GL_SOURCE2_RGB_EXT 0x8582 +#define GL_SOURCE0_ALPHA_EXT 0x8588 +#define GL_SOURCE1_ALPHA_EXT 0x8589 +#define GL_SOURCE2_ALPHA_EXT 0x858A +#define GL_OPERAND0_RGB_EXT 0x8590 +#define GL_OPERAND1_RGB_EXT 0x8591 +#define GL_OPERAND2_RGB_EXT 0x8592 +#define GL_OPERAND0_ALPHA_EXT 0x8598 +#define GL_OPERAND1_ALPHA_EXT 0x8599 +#define GL_OPERAND2_ALPHA_EXT 0x859A +#endif + +#ifndef GL_APPLE_specular_vector +#define GL_LIGHT_MODEL_SPECULAR_VECTOR_APPLE 0x85B0 +#endif + +#ifndef GL_APPLE_transform_hint +#define GL_TRANSFORM_HINT_APPLE 0x85B1 +#endif + +#ifndef GL_SGIX_fog_scale +#define GL_FOG_SCALE_SGIX 0x81FC +#define GL_FOG_SCALE_VALUE_SGIX 0x81FD +#endif + +#ifndef GL_SUNX_constant_data +#define GL_UNPACK_CONSTANT_DATA_SUNX 0x81D5 +#define GL_TEXTURE_CONSTANT_DATA_SUNX 0x81D6 +#endif + +#ifndef GL_SUN_global_alpha +#define GL_GLOBAL_ALPHA_SUN 0x81D9 +#define GL_GLOBAL_ALPHA_FACTOR_SUN 0x81DA +#endif + +#ifndef GL_SUN_triangle_list +#define GL_RESTART_SUN 0x0001 +#define GL_REPLACE_MIDDLE_SUN 0x0002 +#define GL_REPLACE_OLDEST_SUN 0x0003 +#define GL_TRIANGLE_LIST_SUN 0x81D7 +#define GL_REPLACEMENT_CODE_SUN 0x81D8 +#define GL_REPLACEMENT_CODE_ARRAY_SUN 0x85C0 +#define GL_REPLACEMENT_CODE_ARRAY_TYPE_SUN 0x85C1 +#define GL_REPLACEMENT_CODE_ARRAY_STRIDE_SUN 0x85C2 +#define GL_REPLACEMENT_CODE_ARRAY_POINTER_SUN 0x85C3 +#define GL_R1UI_V3F_SUN 0x85C4 +#define GL_R1UI_C4UB_V3F_SUN 0x85C5 +#define GL_R1UI_C3F_V3F_SUN 0x85C6 +#define GL_R1UI_N3F_V3F_SUN 0x85C7 +#define GL_R1UI_C4F_N3F_V3F_SUN 0x85C8 +#define GL_R1UI_T2F_V3F_SUN 0x85C9 +#define GL_R1UI_T2F_N3F_V3F_SUN 0x85CA +#define GL_R1UI_T2F_C4F_N3F_V3F_SUN 0x85CB +#endif + +#ifndef GL_SUN_vertex +#endif + +#ifndef GL_EXT_blend_func_separate +#define GL_BLEND_DST_RGB_EXT 0x80C8 +#define GL_BLEND_SRC_RGB_EXT 0x80C9 +#define GL_BLEND_DST_ALPHA_EXT 0x80CA +#define GL_BLEND_SRC_ALPHA_EXT 0x80CB +#endif + +#ifndef GL_INGR_color_clamp +#define GL_RED_MIN_CLAMP_INGR 0x8560 +#define GL_GREEN_MIN_CLAMP_INGR 0x8561 +#define GL_BLUE_MIN_CLAMP_INGR 0x8562 +#define GL_ALPHA_MIN_CLAMP_INGR 0x8563 +#define GL_RED_MAX_CLAMP_INGR 0x8564 +#define GL_GREEN_MAX_CLAMP_INGR 0x8565 +#define GL_BLUE_MAX_CLAMP_INGR 0x8566 +#define GL_ALPHA_MAX_CLAMP_INGR 0x8567 +#endif + +#ifndef GL_INGR_interlace_read +#define GL_INTERLACE_READ_INGR 0x8568 +#endif + +#ifndef GL_EXT_stencil_wrap +#define GL_INCR_WRAP_EXT 0x8507 +#define GL_DECR_WRAP_EXT 0x8508 +#endif + +#ifndef GL_EXT_422_pixels +#define GL_422_EXT 0x80CC +#define GL_422_REV_EXT 0x80CD +#define GL_422_AVERAGE_EXT 0x80CE +#define GL_422_REV_AVERAGE_EXT 0x80CF +#endif + +#ifndef GL_NV_texgen_reflection +#define GL_NORMAL_MAP_NV 0x8511 +#define GL_REFLECTION_MAP_NV 0x8512 +#endif + +#ifndef GL_EXT_texture_cube_map +#define GL_NORMAL_MAP_EXT 0x8511 +#define GL_REFLECTION_MAP_EXT 0x8512 +#define GL_TEXTURE_CUBE_MAP_EXT 0x8513 +#define GL_TEXTURE_BINDING_CUBE_MAP_EXT 0x8514 +#define GL_TEXTURE_CUBE_MAP_POSITIVE_X_EXT 0x8515 +#define GL_TEXTURE_CUBE_MAP_NEGATIVE_X_EXT 0x8516 +#define GL_TEXTURE_CUBE_MAP_POSITIVE_Y_EXT 0x8517 +#define GL_TEXTURE_CUBE_MAP_NEGATIVE_Y_EXT 0x8518 +#define GL_TEXTURE_CUBE_MAP_POSITIVE_Z_EXT 0x8519 +#define GL_TEXTURE_CUBE_MAP_NEGATIVE_Z_EXT 0x851A +#define GL_PROXY_TEXTURE_CUBE_MAP_EXT 0x851B +#define GL_MAX_CUBE_MAP_TEXTURE_SIZE_EXT 0x851C +#endif + +#ifndef GL_SUN_convolution_border_modes +#define GL_WRAP_BORDER_SUN 0x81D4 +#endif + +#ifndef GL_EXT_texture_env_add +#endif + +#ifndef GL_EXT_texture_lod_bias +#define GL_MAX_TEXTURE_LOD_BIAS_EXT 0x84FD +#define GL_TEXTURE_FILTER_CONTROL_EXT 0x8500 +#define GL_TEXTURE_LOD_BIAS_EXT 0x8501 +#endif + +#ifndef GL_EXT_texture_filter_anisotropic +#define GL_TEXTURE_MAX_ANISOTROPY_EXT 0x84FE +#define GL_MAX_TEXTURE_MAX_ANISOTROPY_EXT 0x84FF +#endif + +#ifndef GL_EXT_vertex_weighting +#define GL_MODELVIEW0_STACK_DEPTH_EXT GL_MODELVIEW_STACK_DEPTH +#define GL_MODELVIEW1_STACK_DEPTH_EXT 0x8502 +#define GL_MODELVIEW0_MATRIX_EXT GL_MODELVIEW_MATRIX +#define GL_MODELVIEW1_MATRIX_EXT 0x8506 +#define GL_VERTEX_WEIGHTING_EXT 0x8509 +#define GL_MODELVIEW0_EXT GL_MODELVIEW +#define GL_MODELVIEW1_EXT 0x850A +#define GL_CURRENT_VERTEX_WEIGHT_EXT 0x850B +#define GL_VERTEX_WEIGHT_ARRAY_EXT 0x850C +#define GL_VERTEX_WEIGHT_ARRAY_SIZE_EXT 0x850D +#define GL_VERTEX_WEIGHT_ARRAY_TYPE_EXT 0x850E +#define GL_VERTEX_WEIGHT_ARRAY_STRIDE_EXT 0x850F +#define GL_VERTEX_WEIGHT_ARRAY_POINTER_EXT 0x8510 +#endif + +#ifndef GL_NV_light_max_exponent +#define GL_MAX_SHININESS_NV 0x8504 +#define GL_MAX_SPOT_EXPONENT_NV 0x8505 +#endif + +#ifndef GL_NV_vertex_array_range +#define GL_VERTEX_ARRAY_RANGE_NV 0x851D +#define GL_VERTEX_ARRAY_RANGE_LENGTH_NV 0x851E +#define GL_VERTEX_ARRAY_RANGE_VALID_NV 0x851F +#define GL_MAX_VERTEX_ARRAY_RANGE_ELEMENT_NV 0x8520 +#define GL_VERTEX_ARRAY_RANGE_POINTER_NV 0x8521 +#endif + +#ifndef GL_NV_register_combiners +#define GL_REGISTER_COMBINERS_NV 0x8522 +#define GL_VARIABLE_A_NV 0x8523 +#define GL_VARIABLE_B_NV 0x8524 +#define GL_VARIABLE_C_NV 0x8525 +#define GL_VARIABLE_D_NV 0x8526 +#define GL_VARIABLE_E_NV 0x8527 +#define GL_VARIABLE_F_NV 0x8528 +#define GL_VARIABLE_G_NV 0x8529 +#define GL_CONSTANT_COLOR0_NV 0x852A +#define GL_CONSTANT_COLOR1_NV 0x852B +#define GL_PRIMARY_COLOR_NV 0x852C +#define GL_SECONDARY_COLOR_NV 0x852D +#define GL_SPARE0_NV 0x852E +#define GL_SPARE1_NV 0x852F +#define GL_DISCARD_NV 0x8530 +#define GL_E_TIMES_F_NV 0x8531 +#define GL_SPARE0_PLUS_SECONDARY_COLOR_NV 0x8532 +#define GL_UNSIGNED_IDENTITY_NV 0x8536 +#define GL_UNSIGNED_INVERT_NV 0x8537 +#define GL_EXPAND_NORMAL_NV 0x8538 +#define GL_EXPAND_NEGATE_NV 0x8539 +#define GL_HALF_BIAS_NORMAL_NV 0x853A +#define GL_HALF_BIAS_NEGATE_NV 0x853B +#define GL_SIGNED_IDENTITY_NV 0x853C +#define GL_SIGNED_NEGATE_NV 0x853D +#define GL_SCALE_BY_TWO_NV 0x853E +#define GL_SCALE_BY_FOUR_NV 0x853F +#define GL_SCALE_BY_ONE_HALF_NV 0x8540 +#define GL_BIAS_BY_NEGATIVE_ONE_HALF_NV 0x8541 +#define GL_COMBINER_INPUT_NV 0x8542 +#define GL_COMBINER_MAPPING_NV 0x8543 +#define GL_COMBINER_COMPONENT_USAGE_NV 0x8544 +#define GL_COMBINER_AB_DOT_PRODUCT_NV 0x8545 +#define GL_COMBINER_CD_DOT_PRODUCT_NV 0x8546 +#define GL_COMBINER_MUX_SUM_NV 0x8547 +#define GL_COMBINER_SCALE_NV 0x8548 +#define GL_COMBINER_BIAS_NV 0x8549 +#define GL_COMBINER_AB_OUTPUT_NV 0x854A +#define GL_COMBINER_CD_OUTPUT_NV 0x854B +#define GL_COMBINER_SUM_OUTPUT_NV 0x854C +#define GL_MAX_GENERAL_COMBINERS_NV 0x854D +#define GL_NUM_GENERAL_COMBINERS_NV 0x854E +#define GL_COLOR_SUM_CLAMP_NV 0x854F +#define GL_COMBINER0_NV 0x8550 +#define GL_COMBINER1_NV 0x8551 +#define GL_COMBINER2_NV 0x8552 +#define GL_COMBINER3_NV 0x8553 +#define GL_COMBINER4_NV 0x8554 +#define GL_COMBINER5_NV 0x8555 +#define GL_COMBINER6_NV 0x8556 +#define GL_COMBINER7_NV 0x8557 +/* reuse GL_TEXTURE0_ARB */ +/* reuse GL_TEXTURE1_ARB */ +/* reuse GL_ZERO */ +/* reuse GL_NONE */ +/* reuse GL_FOG */ +#endif + +#ifndef GL_NV_fog_distance +#define GL_FOG_DISTANCE_MODE_NV 0x855A +#define GL_EYE_RADIAL_NV 0x855B +#define GL_EYE_PLANE_ABSOLUTE_NV 0x855C +/* reuse GL_EYE_PLANE */ +#endif + +#ifndef GL_NV_texgen_emboss +#define GL_EMBOSS_LIGHT_NV 0x855D +#define GL_EMBOSS_CONSTANT_NV 0x855E +#define GL_EMBOSS_MAP_NV 0x855F +#endif + +#ifndef GL_NV_blend_square +#endif + +#ifndef GL_NV_texture_env_combine4 +#define GL_COMBINE4_NV 0x8503 +#define GL_SOURCE3_RGB_NV 0x8583 +#define GL_SOURCE3_ALPHA_NV 0x858B +#define GL_OPERAND3_RGB_NV 0x8593 +#define GL_OPERAND3_ALPHA_NV 0x859B +#endif + +#ifndef GL_MESA_resize_buffers +#endif + +#ifndef GL_MESA_window_pos +#endif + +#ifndef GL_EXT_texture_compression_s3tc +#define GL_COMPRESSED_RGB_S3TC_DXT1_EXT 0x83F0 +#define GL_COMPRESSED_RGBA_S3TC_DXT1_EXT 0x83F1 +#define GL_COMPRESSED_RGBA_S3TC_DXT3_EXT 0x83F2 +#define GL_COMPRESSED_RGBA_S3TC_DXT5_EXT 0x83F3 +#endif + +#ifndef GL_IBM_cull_vertex +#define GL_CULL_VERTEX_IBM 103050 +#endif + +#ifndef GL_IBM_multimode_draw_arrays +#endif + +#ifndef GL_IBM_vertex_array_lists +#define GL_VERTEX_ARRAY_LIST_IBM 103070 +#define GL_NORMAL_ARRAY_LIST_IBM 103071 +#define GL_COLOR_ARRAY_LIST_IBM 103072 +#define GL_INDEX_ARRAY_LIST_IBM 103073 +#define GL_TEXTURE_COORD_ARRAY_LIST_IBM 103074 +#define GL_EDGE_FLAG_ARRAY_LIST_IBM 103075 +#define GL_FOG_COORDINATE_ARRAY_LIST_IBM 103076 +#define GL_SECONDARY_COLOR_ARRAY_LIST_IBM 103077 +#define GL_VERTEX_ARRAY_LIST_STRIDE_IBM 103080 +#define GL_NORMAL_ARRAY_LIST_STRIDE_IBM 103081 +#define GL_COLOR_ARRAY_LIST_STRIDE_IBM 103082 +#define GL_INDEX_ARRAY_LIST_STRIDE_IBM 103083 +#define GL_TEXTURE_COORD_ARRAY_LIST_STRIDE_IBM 103084 +#define GL_EDGE_FLAG_ARRAY_LIST_STRIDE_IBM 103085 +#define GL_FOG_COORDINATE_ARRAY_LIST_STRIDE_IBM 103086 +#define GL_SECONDARY_COLOR_ARRAY_LIST_STRIDE_IBM 103087 +#endif + +#ifndef GL_SGIX_subsample +#define GL_PACK_SUBSAMPLE_RATE_SGIX 0x85A0 +#define GL_UNPACK_SUBSAMPLE_RATE_SGIX 0x85A1 +#define GL_PIXEL_SUBSAMPLE_4444_SGIX 0x85A2 +#define GL_PIXEL_SUBSAMPLE_2424_SGIX 0x85A3 +#define GL_PIXEL_SUBSAMPLE_4242_SGIX 0x85A4 +#endif + +#ifndef GL_SGIX_ycrcb_subsample +#endif + +#ifndef GL_SGIX_ycrcba +#define GL_YCRCB_SGIX 0x8318 +#define GL_YCRCBA_SGIX 0x8319 +#endif + +#ifndef GL_SGI_depth_pass_instrument +#define GL_DEPTH_PASS_INSTRUMENT_SGIX 0x8310 +#define GL_DEPTH_PASS_INSTRUMENT_COUNTERS_SGIX 0x8311 +#define GL_DEPTH_PASS_INSTRUMENT_MAX_SGIX 0x8312 +#endif + +#ifndef GL_3DFX_texture_compression_FXT1 +#define GL_COMPRESSED_RGB_FXT1_3DFX 0x86B0 +#define GL_COMPRESSED_RGBA_FXT1_3DFX 0x86B1 +#endif + +#ifndef GL_3DFX_multisample +#define GL_MULTISAMPLE_3DFX 0x86B2 +#define GL_SAMPLE_BUFFERS_3DFX 0x86B3 +#define GL_SAMPLES_3DFX 0x86B4 +#define GL_MULTISAMPLE_BIT_3DFX 0x20000000 +#endif + +#ifndef GL_3DFX_tbuffer +#endif + +#ifndef GL_EXT_multisample +#define GL_MULTISAMPLE_EXT 0x809D +#define GL_SAMPLE_ALPHA_TO_MASK_EXT 0x809E +#define GL_SAMPLE_ALPHA_TO_ONE_EXT 0x809F +#define GL_SAMPLE_MASK_EXT 0x80A0 +#define GL_1PASS_EXT 0x80A1 +#define GL_2PASS_0_EXT 0x80A2 +#define GL_2PASS_1_EXT 0x80A3 +#define GL_4PASS_0_EXT 0x80A4 +#define GL_4PASS_1_EXT 0x80A5 +#define GL_4PASS_2_EXT 0x80A6 +#define GL_4PASS_3_EXT 0x80A7 +#define GL_SAMPLE_BUFFERS_EXT 0x80A8 +#define GL_SAMPLES_EXT 0x80A9 +#define GL_SAMPLE_MASK_VALUE_EXT 0x80AA +#define GL_SAMPLE_MASK_INVERT_EXT 0x80AB +#define GL_SAMPLE_PATTERN_EXT 0x80AC +#define GL_MULTISAMPLE_BIT_EXT 0x20000000 +#endif + +#ifndef GL_SGIX_vertex_preclip +#define GL_VERTEX_PRECLIP_SGIX 0x83EE +#define GL_VERTEX_PRECLIP_HINT_SGIX 0x83EF +#endif + +#ifndef GL_SGIX_convolution_accuracy +#define GL_CONVOLUTION_HINT_SGIX 0x8316 +#endif + +#ifndef GL_SGIX_resample +#define GL_PACK_RESAMPLE_SGIX 0x842C +#define GL_UNPACK_RESAMPLE_SGIX 0x842D +#define GL_RESAMPLE_REPLICATE_SGIX 0x842E +#define GL_RESAMPLE_ZERO_FILL_SGIX 0x842F +#define GL_RESAMPLE_DECIMATE_SGIX 0x8430 +#endif + +#ifndef GL_SGIS_point_line_texgen +#define GL_EYE_DISTANCE_TO_POINT_SGIS 0x81F0 +#define GL_OBJECT_DISTANCE_TO_POINT_SGIS 0x81F1 +#define GL_EYE_DISTANCE_TO_LINE_SGIS 0x81F2 +#define GL_OBJECT_DISTANCE_TO_LINE_SGIS 0x81F3 +#define GL_EYE_POINT_SGIS 0x81F4 +#define GL_OBJECT_POINT_SGIS 0x81F5 +#define GL_EYE_LINE_SGIS 0x81F6 +#define GL_OBJECT_LINE_SGIS 0x81F7 +#endif + +#ifndef GL_SGIS_texture_color_mask +#define GL_TEXTURE_COLOR_WRITEMASK_SGIS 0x81EF +#endif + +#ifndef GL_EXT_texture_env_dot3 +#define GL_DOT3_RGB_EXT 0x8740 +#define GL_DOT3_RGBA_EXT 0x8741 +#endif + +#ifndef GL_ATI_texture_mirror_once +#define GL_MIRROR_CLAMP_ATI 0x8742 +#define GL_MIRROR_CLAMP_TO_EDGE_ATI 0x8743 +#endif + +#ifndef GL_NV_fence +#define GL_ALL_COMPLETED_NV 0x84F2 +#define GL_FENCE_STATUS_NV 0x84F3 +#define GL_FENCE_CONDITION_NV 0x84F4 +#endif + +#ifndef GL_IBM_texture_mirrored_repeat +#define GL_MIRRORED_REPEAT_IBM 0x8370 +#endif + +#ifndef GL_NV_evaluators +#define GL_EVAL_2D_NV 0x86C0 +#define GL_EVAL_TRIANGULAR_2D_NV 0x86C1 +#define GL_MAP_TESSELLATION_NV 0x86C2 +#define GL_MAP_ATTRIB_U_ORDER_NV 0x86C3 +#define GL_MAP_ATTRIB_V_ORDER_NV 0x86C4 +#define GL_EVAL_FRACTIONAL_TESSELLATION_NV 0x86C5 +#define GL_EVAL_VERTEX_ATTRIB0_NV 0x86C6 +#define GL_EVAL_VERTEX_ATTRIB1_NV 0x86C7 +#define GL_EVAL_VERTEX_ATTRIB2_NV 0x86C8 +#define GL_EVAL_VERTEX_ATTRIB3_NV 0x86C9 +#define GL_EVAL_VERTEX_ATTRIB4_NV 0x86CA +#define GL_EVAL_VERTEX_ATTRIB5_NV 0x86CB +#define GL_EVAL_VERTEX_ATTRIB6_NV 0x86CC +#define GL_EVAL_VERTEX_ATTRIB7_NV 0x86CD +#define GL_EVAL_VERTEX_ATTRIB8_NV 0x86CE +#define GL_EVAL_VERTEX_ATTRIB9_NV 0x86CF +#define GL_EVAL_VERTEX_ATTRIB10_NV 0x86D0 +#define GL_EVAL_VERTEX_ATTRIB11_NV 0x86D1 +#define GL_EVAL_VERTEX_ATTRIB12_NV 0x86D2 +#define GL_EVAL_VERTEX_ATTRIB13_NV 0x86D3 +#define GL_EVAL_VERTEX_ATTRIB14_NV 0x86D4 +#define GL_EVAL_VERTEX_ATTRIB15_NV 0x86D5 +#define GL_MAX_MAP_TESSELLATION_NV 0x86D6 +#define GL_MAX_RATIONAL_EVAL_ORDER_NV 0x86D7 +#endif + +#ifndef GL_NV_packed_depth_stencil +#define GL_DEPTH_STENCIL_NV 0x84F9 +#define GL_UNSIGNED_INT_24_8_NV 0x84FA +#endif + +#ifndef GL_NV_register_combiners2 +#define GL_PER_STAGE_CONSTANTS_NV 0x8535 +#endif + +#ifndef GL_NV_texture_compression_vtc +#endif + +#ifndef GL_NV_texture_rectangle +#define GL_TEXTURE_RECTANGLE_NV 0x84F5 +#define GL_TEXTURE_BINDING_RECTANGLE_NV 0x84F6 +#define GL_PROXY_TEXTURE_RECTANGLE_NV 0x84F7 +#define GL_MAX_RECTANGLE_TEXTURE_SIZE_NV 0x84F8 +#endif + +#ifndef GL_NV_texture_shader +#define GL_OFFSET_TEXTURE_RECTANGLE_NV 0x864C +#define GL_OFFSET_TEXTURE_RECTANGLE_SCALE_NV 0x864D +#define GL_DOT_PRODUCT_TEXTURE_RECTANGLE_NV 0x864E +#define GL_RGBA_UNSIGNED_DOT_PRODUCT_MAPPING_NV 0x86D9 +#define GL_UNSIGNED_INT_S8_S8_8_8_NV 0x86DA +#define GL_UNSIGNED_INT_8_8_S8_S8_REV_NV 0x86DB +#define GL_DSDT_MAG_INTENSITY_NV 0x86DC +#define GL_SHADER_CONSISTENT_NV 0x86DD +#define GL_TEXTURE_SHADER_NV 0x86DE +#define GL_SHADER_OPERATION_NV 0x86DF +#define GL_CULL_MODES_NV 0x86E0 +#define GL_OFFSET_TEXTURE_MATRIX_NV 0x86E1 +#define GL_OFFSET_TEXTURE_SCALE_NV 0x86E2 +#define GL_OFFSET_TEXTURE_BIAS_NV 0x86E3 +#define GL_OFFSET_TEXTURE_2D_MATRIX_NV GL_OFFSET_TEXTURE_MATRIX_NV +#define GL_OFFSET_TEXTURE_2D_SCALE_NV GL_OFFSET_TEXTURE_SCALE_NV +#define GL_OFFSET_TEXTURE_2D_BIAS_NV GL_OFFSET_TEXTURE_BIAS_NV +#define GL_PREVIOUS_TEXTURE_INPUT_NV 0x86E4 +#define GL_CONST_EYE_NV 0x86E5 +#define GL_PASS_THROUGH_NV 0x86E6 +#define GL_CULL_FRAGMENT_NV 0x86E7 +#define GL_OFFSET_TEXTURE_2D_NV 0x86E8 +#define GL_DEPENDENT_AR_TEXTURE_2D_NV 0x86E9 +#define GL_DEPENDENT_GB_TEXTURE_2D_NV 0x86EA +#define GL_DOT_PRODUCT_NV 0x86EC +#define GL_DOT_PRODUCT_DEPTH_REPLACE_NV 0x86ED +#define GL_DOT_PRODUCT_TEXTURE_2D_NV 0x86EE +#define GL_DOT_PRODUCT_TEXTURE_CUBE_MAP_NV 0x86F0 +#define GL_DOT_PRODUCT_DIFFUSE_CUBE_MAP_NV 0x86F1 +#define GL_DOT_PRODUCT_REFLECT_CUBE_MAP_NV 0x86F2 +#define GL_DOT_PRODUCT_CONST_EYE_REFLECT_CUBE_MAP_NV 0x86F3 +#define GL_HILO_NV 0x86F4 +#define GL_DSDT_NV 0x86F5 +#define GL_DSDT_MAG_NV 0x86F6 +#define GL_DSDT_MAG_VIB_NV 0x86F7 +#define GL_HILO16_NV 0x86F8 +#define GL_SIGNED_HILO_NV 0x86F9 +#define GL_SIGNED_HILO16_NV 0x86FA +#define GL_SIGNED_RGBA_NV 0x86FB +#define GL_SIGNED_RGBA8_NV 0x86FC +#define GL_SIGNED_RGB_NV 0x86FE +#define GL_SIGNED_RGB8_NV 0x86FF +#define GL_SIGNED_LUMINANCE_NV 0x8701 +#define GL_SIGNED_LUMINANCE8_NV 0x8702 +#define GL_SIGNED_LUMINANCE_ALPHA_NV 0x8703 +#define GL_SIGNED_LUMINANCE8_ALPHA8_NV 0x8704 +#define GL_SIGNED_ALPHA_NV 0x8705 +#define GL_SIGNED_ALPHA8_NV 0x8706 +#define GL_SIGNED_INTENSITY_NV 0x8707 +#define GL_SIGNED_INTENSITY8_NV 0x8708 +#define GL_DSDT8_NV 0x8709 +#define GL_DSDT8_MAG8_NV 0x870A +#define GL_DSDT8_MAG8_INTENSITY8_NV 0x870B +#define GL_SIGNED_RGB_UNSIGNED_ALPHA_NV 0x870C +#define GL_SIGNED_RGB8_UNSIGNED_ALPHA8_NV 0x870D +#define GL_HI_SCALE_NV 0x870E +#define GL_LO_SCALE_NV 0x870F +#define GL_DS_SCALE_NV 0x8710 +#define GL_DT_SCALE_NV 0x8711 +#define GL_MAGNITUDE_SCALE_NV 0x8712 +#define GL_VIBRANCE_SCALE_NV 0x8713 +#define GL_HI_BIAS_NV 0x8714 +#define GL_LO_BIAS_NV 0x8715 +#define GL_DS_BIAS_NV 0x8716 +#define GL_DT_BIAS_NV 0x8717 +#define GL_MAGNITUDE_BIAS_NV 0x8718 +#define GL_VIBRANCE_BIAS_NV 0x8719 +#define GL_TEXTURE_BORDER_VALUES_NV 0x871A +#define GL_TEXTURE_HI_SIZE_NV 0x871B +#define GL_TEXTURE_LO_SIZE_NV 0x871C +#define GL_TEXTURE_DS_SIZE_NV 0x871D +#define GL_TEXTURE_DT_SIZE_NV 0x871E +#define GL_TEXTURE_MAG_SIZE_NV 0x871F +#endif + +#ifndef GL_NV_texture_shader2 +#define GL_DOT_PRODUCT_TEXTURE_3D_NV 0x86EF +#endif + +#ifndef GL_NV_vertex_array_range2 +#define GL_VERTEX_ARRAY_RANGE_WITHOUT_FLUSH_NV 0x8533 +#endif + +#ifndef GL_NV_vertex_program +#define GL_VERTEX_PROGRAM_NV 0x8620 +#define GL_VERTEX_STATE_PROGRAM_NV 0x8621 +#define GL_ATTRIB_ARRAY_SIZE_NV 0x8623 +#define GL_ATTRIB_ARRAY_STRIDE_NV 0x8624 +#define GL_ATTRIB_ARRAY_TYPE_NV 0x8625 +#define GL_CURRENT_ATTRIB_NV 0x8626 +#define GL_PROGRAM_LENGTH_NV 0x8627 +#define GL_PROGRAM_STRING_NV 0x8628 +#define GL_MODELVIEW_PROJECTION_NV 0x8629 +#define GL_IDENTITY_NV 0x862A +#define GL_INVERSE_NV 0x862B +#define GL_TRANSPOSE_NV 0x862C +#define GL_INVERSE_TRANSPOSE_NV 0x862D +#define GL_MAX_TRACK_MATRIX_STACK_DEPTH_NV 0x862E +#define GL_MAX_TRACK_MATRICES_NV 0x862F +#define GL_MATRIX0_NV 0x8630 +#define GL_MATRIX1_NV 0x8631 +#define GL_MATRIX2_NV 0x8632 +#define GL_MATRIX3_NV 0x8633 +#define GL_MATRIX4_NV 0x8634 +#define GL_MATRIX5_NV 0x8635 +#define GL_MATRIX6_NV 0x8636 +#define GL_MATRIX7_NV 0x8637 +#define GL_CURRENT_MATRIX_STACK_DEPTH_NV 0x8640 +#define GL_CURRENT_MATRIX_NV 0x8641 +#define GL_VERTEX_PROGRAM_POINT_SIZE_NV 0x8642 +#define GL_VERTEX_PROGRAM_TWO_SIDE_NV 0x8643 +#define GL_PROGRAM_PARAMETER_NV 0x8644 +#define GL_ATTRIB_ARRAY_POINTER_NV 0x8645 +#define GL_PROGRAM_TARGET_NV 0x8646 +#define GL_PROGRAM_RESIDENT_NV 0x8647 +#define GL_TRACK_MATRIX_NV 0x8648 +#define GL_TRACK_MATRIX_TRANSFORM_NV 0x8649 +#define GL_VERTEX_PROGRAM_BINDING_NV 0x864A +#define GL_PROGRAM_ERROR_POSITION_NV 0x864B +#define GL_VERTEX_ATTRIB_ARRAY0_NV 0x8650 +#define GL_VERTEX_ATTRIB_ARRAY1_NV 0x8651 +#define GL_VERTEX_ATTRIB_ARRAY2_NV 0x8652 +#define GL_VERTEX_ATTRIB_ARRAY3_NV 0x8653 +#define GL_VERTEX_ATTRIB_ARRAY4_NV 0x8654 +#define GL_VERTEX_ATTRIB_ARRAY5_NV 0x8655 +#define GL_VERTEX_ATTRIB_ARRAY6_NV 0x8656 +#define GL_VERTEX_ATTRIB_ARRAY7_NV 0x8657 +#define GL_VERTEX_ATTRIB_ARRAY8_NV 0x8658 +#define GL_VERTEX_ATTRIB_ARRAY9_NV 0x8659 +#define GL_VERTEX_ATTRIB_ARRAY10_NV 0x865A +#define GL_VERTEX_ATTRIB_ARRAY11_NV 0x865B +#define GL_VERTEX_ATTRIB_ARRAY12_NV 0x865C +#define GL_VERTEX_ATTRIB_ARRAY13_NV 0x865D +#define GL_VERTEX_ATTRIB_ARRAY14_NV 0x865E +#define GL_VERTEX_ATTRIB_ARRAY15_NV 0x865F +#define GL_MAP1_VERTEX_ATTRIB0_4_NV 0x8660 +#define GL_MAP1_VERTEX_ATTRIB1_4_NV 0x8661 +#define GL_MAP1_VERTEX_ATTRIB2_4_NV 0x8662 +#define GL_MAP1_VERTEX_ATTRIB3_4_NV 0x8663 +#define GL_MAP1_VERTEX_ATTRIB4_4_NV 0x8664 +#define GL_MAP1_VERTEX_ATTRIB5_4_NV 0x8665 +#define GL_MAP1_VERTEX_ATTRIB6_4_NV 0x8666 +#define GL_MAP1_VERTEX_ATTRIB7_4_NV 0x8667 +#define GL_MAP1_VERTEX_ATTRIB8_4_NV 0x8668 +#define GL_MAP1_VERTEX_ATTRIB9_4_NV 0x8669 +#define GL_MAP1_VERTEX_ATTRIB10_4_NV 0x866A +#define GL_MAP1_VERTEX_ATTRIB11_4_NV 0x866B +#define GL_MAP1_VERTEX_ATTRIB12_4_NV 0x866C +#define GL_MAP1_VERTEX_ATTRIB13_4_NV 0x866D +#define GL_MAP1_VERTEX_ATTRIB14_4_NV 0x866E +#define GL_MAP1_VERTEX_ATTRIB15_4_NV 0x866F +#define GL_MAP2_VERTEX_ATTRIB0_4_NV 0x8670 +#define GL_MAP2_VERTEX_ATTRIB1_4_NV 0x8671 +#define GL_MAP2_VERTEX_ATTRIB2_4_NV 0x8672 +#define GL_MAP2_VERTEX_ATTRIB3_4_NV 0x8673 +#define GL_MAP2_VERTEX_ATTRIB4_4_NV 0x8674 +#define GL_MAP2_VERTEX_ATTRIB5_4_NV 0x8675 +#define GL_MAP2_VERTEX_ATTRIB6_4_NV 0x8676 +#define GL_MAP2_VERTEX_ATTRIB7_4_NV 0x8677 +#define GL_MAP2_VERTEX_ATTRIB8_4_NV 0x8678 +#define GL_MAP2_VERTEX_ATTRIB9_4_NV 0x8679 +#define GL_MAP2_VERTEX_ATTRIB10_4_NV 0x867A +#define GL_MAP2_VERTEX_ATTRIB11_4_NV 0x867B +#define GL_MAP2_VERTEX_ATTRIB12_4_NV 0x867C +#define GL_MAP2_VERTEX_ATTRIB13_4_NV 0x867D +#define GL_MAP2_VERTEX_ATTRIB14_4_NV 0x867E +#define GL_MAP2_VERTEX_ATTRIB15_4_NV 0x867F +#endif + +#ifndef GL_SGIX_texture_coordinate_clamp +#define GL_TEXTURE_MAX_CLAMP_S_SGIX 0x8369 +#define GL_TEXTURE_MAX_CLAMP_T_SGIX 0x836A +#define GL_TEXTURE_MAX_CLAMP_R_SGIX 0x836B +#endif + +#ifndef GL_SGIX_scalebias_hint +#define GL_SCALEBIAS_HINT_SGIX 0x8322 +#endif + +#ifndef GL_OML_interlace +#define GL_INTERLACE_OML 0x8980 +#define GL_INTERLACE_READ_OML 0x8981 +#endif + +#ifndef GL_OML_subsample +#define GL_FORMAT_SUBSAMPLE_24_24_OML 0x8982 +#define GL_FORMAT_SUBSAMPLE_244_244_OML 0x8983 +#endif + +#ifndef GL_OML_resample +#define GL_PACK_RESAMPLE_OML 0x8984 +#define GL_UNPACK_RESAMPLE_OML 0x8985 +#define GL_RESAMPLE_REPLICATE_OML 0x8986 +#define GL_RESAMPLE_ZERO_FILL_OML 0x8987 +#define GL_RESAMPLE_AVERAGE_OML 0x8988 +#define GL_RESAMPLE_DECIMATE_OML 0x8989 +#endif + +#ifndef GL_NV_copy_depth_to_color +#define GL_DEPTH_STENCIL_TO_RGBA_NV 0x886E +#define GL_DEPTH_STENCIL_TO_BGRA_NV 0x886F +#endif + +#ifndef GL_ATI_envmap_bumpmap +#define GL_BUMP_ROT_MATRIX_ATI 0x8775 +#define GL_BUMP_ROT_MATRIX_SIZE_ATI 0x8776 +#define GL_BUMP_NUM_TEX_UNITS_ATI 0x8777 +#define GL_BUMP_TEX_UNITS_ATI 0x8778 +#define GL_DUDV_ATI 0x8779 +#define GL_DU8DV8_ATI 0x877A +#define GL_BUMP_ENVMAP_ATI 0x877B +#define GL_BUMP_TARGET_ATI 0x877C +#endif + +#ifndef GL_ATI_fragment_shader +#define GL_FRAGMENT_SHADER_ATI 0x8920 +#define GL_REG_0_ATI 0x8921 +#define GL_REG_1_ATI 0x8922 +#define GL_REG_2_ATI 0x8923 +#define GL_REG_3_ATI 0x8924 +#define GL_REG_4_ATI 0x8925 +#define GL_REG_5_ATI 0x8926 +#define GL_REG_6_ATI 0x8927 +#define GL_REG_7_ATI 0x8928 +#define GL_REG_8_ATI 0x8929 +#define GL_REG_9_ATI 0x892A +#define GL_REG_10_ATI 0x892B +#define GL_REG_11_ATI 0x892C +#define GL_REG_12_ATI 0x892D +#define GL_REG_13_ATI 0x892E +#define GL_REG_14_ATI 0x892F +#define GL_REG_15_ATI 0x8930 +#define GL_REG_16_ATI 0x8931 +#define GL_REG_17_ATI 0x8932 +#define GL_REG_18_ATI 0x8933 +#define GL_REG_19_ATI 0x8934 +#define GL_REG_20_ATI 0x8935 +#define GL_REG_21_ATI 0x8936 +#define GL_REG_22_ATI 0x8937 +#define GL_REG_23_ATI 0x8938 +#define GL_REG_24_ATI 0x8939 +#define GL_REG_25_ATI 0x893A +#define GL_REG_26_ATI 0x893B +#define GL_REG_27_ATI 0x893C +#define GL_REG_28_ATI 0x893D +#define GL_REG_29_ATI 0x893E +#define GL_REG_30_ATI 0x893F +#define GL_REG_31_ATI 0x8940 +#define GL_CON_0_ATI 0x8941 +#define GL_CON_1_ATI 0x8942 +#define GL_CON_2_ATI 0x8943 +#define GL_CON_3_ATI 0x8944 +#define GL_CON_4_ATI 0x8945 +#define GL_CON_5_ATI 0x8946 +#define GL_CON_6_ATI 0x8947 +#define GL_CON_7_ATI 0x8948 +#define GL_CON_8_ATI 0x8949 +#define GL_CON_9_ATI 0x894A +#define GL_CON_10_ATI 0x894B +#define GL_CON_11_ATI 0x894C +#define GL_CON_12_ATI 0x894D +#define GL_CON_13_ATI 0x894E +#define GL_CON_14_ATI 0x894F +#define GL_CON_15_ATI 0x8950 +#define GL_CON_16_ATI 0x8951 +#define GL_CON_17_ATI 0x8952 +#define GL_CON_18_ATI 0x8953 +#define GL_CON_19_ATI 0x8954 +#define GL_CON_20_ATI 0x8955 +#define GL_CON_21_ATI 0x8956 +#define GL_CON_22_ATI 0x8957 +#define GL_CON_23_ATI 0x8958 +#define GL_CON_24_ATI 0x8959 +#define GL_CON_25_ATI 0x895A +#define GL_CON_26_ATI 0x895B +#define GL_CON_27_ATI 0x895C +#define GL_CON_28_ATI 0x895D +#define GL_CON_29_ATI 0x895E +#define GL_CON_30_ATI 0x895F +#define GL_CON_31_ATI 0x8960 +#define GL_MOV_ATI 0x8961 +#define GL_ADD_ATI 0x8963 +#define GL_MUL_ATI 0x8964 +#define GL_SUB_ATI 0x8965 +#define GL_DOT3_ATI 0x8966 +#define GL_DOT4_ATI 0x8967 +#define GL_MAD_ATI 0x8968 +#define GL_LERP_ATI 0x8969 +#define GL_CND_ATI 0x896A +#define GL_CND0_ATI 0x896B +#define GL_DOT2_ADD_ATI 0x896C +#define GL_SECONDARY_INTERPOLATOR_ATI 0x896D +#define GL_NUM_FRAGMENT_REGISTERS_ATI 0x896E +#define GL_NUM_FRAGMENT_CONSTANTS_ATI 0x896F +#define GL_NUM_PASSES_ATI 0x8970 +#define GL_NUM_INSTRUCTIONS_PER_PASS_ATI 0x8971 +#define GL_NUM_INSTRUCTIONS_TOTAL_ATI 0x8972 +#define GL_NUM_INPUT_INTERPOLATOR_COMPONENTS_ATI 0x8973 +#define GL_NUM_LOOPBACK_COMPONENTS_ATI 0x8974 +#define GL_COLOR_ALPHA_PAIRING_ATI 0x8975 +#define GL_SWIZZLE_STR_ATI 0x8976 +#define GL_SWIZZLE_STQ_ATI 0x8977 +#define GL_SWIZZLE_STR_DR_ATI 0x8978 +#define GL_SWIZZLE_STQ_DQ_ATI 0x8979 +#define GL_SWIZZLE_STRQ_ATI 0x897A +#define GL_SWIZZLE_STRQ_DQ_ATI 0x897B +#define GL_RED_BIT_ATI 0x00000001 +#define GL_GREEN_BIT_ATI 0x00000002 +#define GL_BLUE_BIT_ATI 0x00000004 +#define GL_2X_BIT_ATI 0x00000001 +#define GL_4X_BIT_ATI 0x00000002 +#define GL_8X_BIT_ATI 0x00000004 +#define GL_HALF_BIT_ATI 0x00000008 +#define GL_QUARTER_BIT_ATI 0x00000010 +#define GL_EIGHTH_BIT_ATI 0x00000020 +#define GL_SATURATE_BIT_ATI 0x00000040 +#define GL_COMP_BIT_ATI 0x00000002 +#define GL_NEGATE_BIT_ATI 0x00000004 +#define GL_BIAS_BIT_ATI 0x00000008 +#endif + +#ifndef GL_ATI_pn_triangles +#define GL_PN_TRIANGLES_ATI 0x87F0 +#define GL_MAX_PN_TRIANGLES_TESSELATION_LEVEL_ATI 0x87F1 +#define GL_PN_TRIANGLES_POINT_MODE_ATI 0x87F2 +#define GL_PN_TRIANGLES_NORMAL_MODE_ATI 0x87F3 +#define GL_PN_TRIANGLES_TESSELATION_LEVEL_ATI 0x87F4 +#define GL_PN_TRIANGLES_POINT_MODE_LINEAR_ATI 0x87F5 +#define GL_PN_TRIANGLES_POINT_MODE_CUBIC_ATI 0x87F6 +#define GL_PN_TRIANGLES_NORMAL_MODE_LINEAR_ATI 0x87F7 +#define GL_PN_TRIANGLES_NORMAL_MODE_QUADRATIC_ATI 0x87F8 +#endif + +#ifndef GL_ATI_vertex_array_object +#define GL_STATIC_ATI 0x8760 +#define GL_DYNAMIC_ATI 0x8761 +#define GL_PRESERVE_ATI 0x8762 +#define GL_DISCARD_ATI 0x8763 +#define GL_OBJECT_BUFFER_SIZE_ATI 0x8764 +#define GL_OBJECT_BUFFER_USAGE_ATI 0x8765 +#define GL_ARRAY_OBJECT_BUFFER_ATI 0x8766 +#define GL_ARRAY_OBJECT_OFFSET_ATI 0x8767 +#endif + +#ifndef GL_EXT_vertex_shader +#define GL_VERTEX_SHADER_EXT 0x8780 +#define GL_VERTEX_SHADER_BINDING_EXT 0x8781 +#define GL_OP_INDEX_EXT 0x8782 +#define GL_OP_NEGATE_EXT 0x8783 +#define GL_OP_DOT3_EXT 0x8784 +#define GL_OP_DOT4_EXT 0x8785 +#define GL_OP_MUL_EXT 0x8786 +#define GL_OP_ADD_EXT 0x8787 +#define GL_OP_MADD_EXT 0x8788 +#define GL_OP_FRAC_EXT 0x8789 +#define GL_OP_MAX_EXT 0x878A +#define GL_OP_MIN_EXT 0x878B +#define GL_OP_SET_GE_EXT 0x878C +#define GL_OP_SET_LT_EXT 0x878D +#define GL_OP_CLAMP_EXT 0x878E +#define GL_OP_FLOOR_EXT 0x878F +#define GL_OP_ROUND_EXT 0x8790 +#define GL_OP_EXP_BASE_2_EXT 0x8791 +#define GL_OP_LOG_BASE_2_EXT 0x8792 +#define GL_OP_POWER_EXT 0x8793 +#define GL_OP_RECIP_EXT 0x8794 +#define GL_OP_RECIP_SQRT_EXT 0x8795 +#define GL_OP_SUB_EXT 0x8796 +#define GL_OP_CROSS_PRODUCT_EXT 0x8797 +#define GL_OP_MULTIPLY_MATRIX_EXT 0x8798 +#define GL_OP_MOV_EXT 0x8799 +#define GL_OUTPUT_VERTEX_EXT 0x879A +#define GL_OUTPUT_COLOR0_EXT 0x879B +#define GL_OUTPUT_COLOR1_EXT 0x879C +#define GL_OUTPUT_TEXTURE_COORD0_EXT 0x879D +#define GL_OUTPUT_TEXTURE_COORD1_EXT 0x879E +#define GL_OUTPUT_TEXTURE_COORD2_EXT 0x879F +#define GL_OUTPUT_TEXTURE_COORD3_EXT 0x87A0 +#define GL_OUTPUT_TEXTURE_COORD4_EXT 0x87A1 +#define GL_OUTPUT_TEXTURE_COORD5_EXT 0x87A2 +#define GL_OUTPUT_TEXTURE_COORD6_EXT 0x87A3 +#define GL_OUTPUT_TEXTURE_COORD7_EXT 0x87A4 +#define GL_OUTPUT_TEXTURE_COORD8_EXT 0x87A5 +#define GL_OUTPUT_TEXTURE_COORD9_EXT 0x87A6 +#define GL_OUTPUT_TEXTURE_COORD10_EXT 0x87A7 +#define GL_OUTPUT_TEXTURE_COORD11_EXT 0x87A8 +#define GL_OUTPUT_TEXTURE_COORD12_EXT 0x87A9 +#define GL_OUTPUT_TEXTURE_COORD13_EXT 0x87AA +#define GL_OUTPUT_TEXTURE_COORD14_EXT 0x87AB +#define GL_OUTPUT_TEXTURE_COORD15_EXT 0x87AC +#define GL_OUTPUT_TEXTURE_COORD16_EXT 0x87AD +#define GL_OUTPUT_TEXTURE_COORD17_EXT 0x87AE +#define GL_OUTPUT_TEXTURE_COORD18_EXT 0x87AF +#define GL_OUTPUT_TEXTURE_COORD19_EXT 0x87B0 +#define GL_OUTPUT_TEXTURE_COORD20_EXT 0x87B1 +#define GL_OUTPUT_TEXTURE_COORD21_EXT 0x87B2 +#define GL_OUTPUT_TEXTURE_COORD22_EXT 0x87B3 +#define GL_OUTPUT_TEXTURE_COORD23_EXT 0x87B4 +#define GL_OUTPUT_TEXTURE_COORD24_EXT 0x87B5 +#define GL_OUTPUT_TEXTURE_COORD25_EXT 0x87B6 +#define GL_OUTPUT_TEXTURE_COORD26_EXT 0x87B7 +#define GL_OUTPUT_TEXTURE_COORD27_EXT 0x87B8 +#define GL_OUTPUT_TEXTURE_COORD28_EXT 0x87B9 +#define GL_OUTPUT_TEXTURE_COORD29_EXT 0x87BA +#define GL_OUTPUT_TEXTURE_COORD30_EXT 0x87BB +#define GL_OUTPUT_TEXTURE_COORD31_EXT 0x87BC +#define GL_OUTPUT_FOG_EXT 0x87BD +#define GL_SCALAR_EXT 0x87BE +#define GL_VECTOR_EXT 0x87BF +#define GL_MATRIX_EXT 0x87C0 +#define GL_VARIANT_EXT 0x87C1 +#define GL_INVARIANT_EXT 0x87C2 +#define GL_LOCAL_CONSTANT_EXT 0x87C3 +#define GL_LOCAL_EXT 0x87C4 +#define GL_MAX_VERTEX_SHADER_INSTRUCTIONS_EXT 0x87C5 +#define GL_MAX_VERTEX_SHADER_VARIANTS_EXT 0x87C6 +#define GL_MAX_VERTEX_SHADER_INVARIANTS_EXT 0x87C7 +#define GL_MAX_VERTEX_SHADER_LOCAL_CONSTANTS_EXT 0x87C8 +#define GL_MAX_VERTEX_SHADER_LOCALS_EXT 0x87C9 +#define GL_MAX_OPTIMIZED_VERTEX_SHADER_INSTRUCTIONS_EXT 0x87CA +#define GL_MAX_OPTIMIZED_VERTEX_SHADER_VARIANTS_EXT 0x87CB +#define GL_MAX_OPTIMIZED_VERTEX_SHADER_LOCAL_CONSTANTS_EXT 0x87CC +#define GL_MAX_OPTIMIZED_VERTEX_SHADER_INVARIANTS_EXT 0x87CD +#define GL_MAX_OPTIMIZED_VERTEX_SHADER_LOCALS_EXT 0x87CE +#define GL_VERTEX_SHADER_INSTRUCTIONS_EXT 0x87CF +#define GL_VERTEX_SHADER_VARIANTS_EXT 0x87D0 +#define GL_VERTEX_SHADER_INVARIANTS_EXT 0x87D1 +#define GL_VERTEX_SHADER_LOCAL_CONSTANTS_EXT 0x87D2 +#define GL_VERTEX_SHADER_LOCALS_EXT 0x87D3 +#define GL_VERTEX_SHADER_OPTIMIZED_EXT 0x87D4 +#define GL_X_EXT 0x87D5 +#define GL_Y_EXT 0x87D6 +#define GL_Z_EXT 0x87D7 +#define GL_W_EXT 0x87D8 +#define GL_NEGATIVE_X_EXT 0x87D9 +#define GL_NEGATIVE_Y_EXT 0x87DA +#define GL_NEGATIVE_Z_EXT 0x87DB +#define GL_NEGATIVE_W_EXT 0x87DC +#define GL_ZERO_EXT 0x87DD +#define GL_ONE_EXT 0x87DE +#define GL_NEGATIVE_ONE_EXT 0x87DF +#define GL_NORMALIZED_RANGE_EXT 0x87E0 +#define GL_FULL_RANGE_EXT 0x87E1 +#define GL_CURRENT_VERTEX_EXT 0x87E2 +#define GL_MVP_MATRIX_EXT 0x87E3 +#define GL_VARIANT_VALUE_EXT 0x87E4 +#define GL_VARIANT_DATATYPE_EXT 0x87E5 +#define GL_VARIANT_ARRAY_STRIDE_EXT 0x87E6 +#define GL_VARIANT_ARRAY_TYPE_EXT 0x87E7 +#define GL_VARIANT_ARRAY_EXT 0x87E8 +#define GL_VARIANT_ARRAY_POINTER_EXT 0x87E9 +#define GL_INVARIANT_VALUE_EXT 0x87EA +#define GL_INVARIANT_DATATYPE_EXT 0x87EB +#define GL_LOCAL_CONSTANT_VALUE_EXT 0x87EC +#define GL_LOCAL_CONSTANT_DATATYPE_EXT 0x87ED +#endif + +#ifndef GL_ATI_vertex_streams +#define GL_MAX_VERTEX_STREAMS_ATI 0x876B +#define GL_VERTEX_STREAM0_ATI 0x876C +#define GL_VERTEX_STREAM1_ATI 0x876D +#define GL_VERTEX_STREAM2_ATI 0x876E +#define GL_VERTEX_STREAM3_ATI 0x876F +#define GL_VERTEX_STREAM4_ATI 0x8770 +#define GL_VERTEX_STREAM5_ATI 0x8771 +#define GL_VERTEX_STREAM6_ATI 0x8772 +#define GL_VERTEX_STREAM7_ATI 0x8773 +#define GL_VERTEX_SOURCE_ATI 0x8774 +#endif + +#ifndef GL_ATI_element_array +#define GL_ELEMENT_ARRAY_ATI 0x8768 +#define GL_ELEMENT_ARRAY_TYPE_ATI 0x8769 +#define GL_ELEMENT_ARRAY_POINTER_ATI 0x876A +#endif + +#ifndef GL_SUN_mesh_array +#define GL_QUAD_MESH_SUN 0x8614 +#define GL_TRIANGLE_MESH_SUN 0x8615 +#endif + +#ifndef GL_SUN_slice_accum +#define GL_SLICE_ACCUM_SUN 0x85CC +#endif + +#ifndef GL_NV_multisample_filter_hint +#define GL_MULTISAMPLE_FILTER_HINT_NV 0x8534 +#endif + +#ifndef GL_NV_depth_clamp +#define GL_DEPTH_CLAMP_NV 0x864F +#endif + +#ifndef GL_NV_occlusion_query +#define GL_PIXEL_COUNTER_BITS_NV 0x8864 +#define GL_CURRENT_OCCLUSION_QUERY_ID_NV 0x8865 +#define GL_PIXEL_COUNT_NV 0x8866 +#define GL_PIXEL_COUNT_AVAILABLE_NV 0x8867 +#endif + +#ifndef GL_NV_point_sprite +#define GL_POINT_SPRITE_NV 0x8861 +#define GL_COORD_REPLACE_NV 0x8862 +#define GL_POINT_SPRITE_R_MODE_NV 0x8863 +#endif + +#ifndef GL_NV_texture_shader3 +#define GL_OFFSET_PROJECTIVE_TEXTURE_2D_NV 0x8850 +#define GL_OFFSET_PROJECTIVE_TEXTURE_2D_SCALE_NV 0x8851 +#define GL_OFFSET_PROJECTIVE_TEXTURE_RECTANGLE_NV 0x8852 +#define GL_OFFSET_PROJECTIVE_TEXTURE_RECTANGLE_SCALE_NV 0x8853 +#define GL_OFFSET_HILO_TEXTURE_2D_NV 0x8854 +#define GL_OFFSET_HILO_TEXTURE_RECTANGLE_NV 0x8855 +#define GL_OFFSET_HILO_PROJECTIVE_TEXTURE_2D_NV 0x8856 +#define GL_OFFSET_HILO_PROJECTIVE_TEXTURE_RECTANGLE_NV 0x8857 +#define GL_DEPENDENT_HILO_TEXTURE_2D_NV 0x8858 +#define GL_DEPENDENT_RGB_TEXTURE_3D_NV 0x8859 +#define GL_DEPENDENT_RGB_TEXTURE_CUBE_MAP_NV 0x885A +#define GL_DOT_PRODUCT_PASS_THROUGH_NV 0x885B +#define GL_DOT_PRODUCT_TEXTURE_1D_NV 0x885C +#define GL_DOT_PRODUCT_AFFINE_DEPTH_REPLACE_NV 0x885D +#define GL_HILO8_NV 0x885E +#define GL_SIGNED_HILO8_NV 0x885F +#define GL_FORCE_BLUE_TO_ONE_NV 0x8860 +#endif + +#ifndef GL_NV_vertex_program1_1 +#endif + +#ifndef GL_EXT_shadow_funcs +#endif + +#ifndef GL_EXT_stencil_two_side +#define GL_STENCIL_TEST_TWO_SIDE_EXT 0x8910 +#define GL_ACTIVE_STENCIL_FACE_EXT 0x8911 +#endif + +#ifndef GL_ATI_text_fragment_shader +#define GL_TEXT_FRAGMENT_SHADER_ATI 0x8200 +#endif + +#ifndef GL_APPLE_client_storage +#define GL_UNPACK_CLIENT_STORAGE_APPLE 0x85B2 +#endif + +#ifndef GL_APPLE_element_array +#define GL_ELEMENT_ARRAY_APPLE 0x8768 +#define GL_ELEMENT_ARRAY_TYPE_APPLE 0x8769 +#define GL_ELEMENT_ARRAY_POINTER_APPLE 0x876A +#endif + +#ifndef GL_APPLE_fence +#define GL_DRAW_PIXELS_APPLE 0x8A0A +#define GL_FENCE_APPLE 0x8A0B +#endif + +#ifndef GL_APPLE_vertex_array_object +#define GL_VERTEX_ARRAY_BINDING_APPLE 0x85B5 +#endif + +#ifndef GL_APPLE_vertex_array_range +#define GL_VERTEX_ARRAY_RANGE_APPLE 0x851D +#define GL_VERTEX_ARRAY_RANGE_LENGTH_APPLE 0x851E +#define GL_VERTEX_ARRAY_STORAGE_HINT_APPLE 0x851F +#define GL_VERTEX_ARRAY_RANGE_POINTER_APPLE 0x8521 +#define GL_STORAGE_CACHED_APPLE 0x85BE +#define GL_STORAGE_SHARED_APPLE 0x85BF +#endif + +#ifndef GL_APPLE_ycbcr_422 +#define GL_YCBCR_422_APPLE 0x85B9 +#define GL_UNSIGNED_SHORT_8_8_APPLE 0x85BA +#define GL_UNSIGNED_SHORT_8_8_REV_APPLE 0x85BB +#endif + +#ifndef GL_S3_s3tc +#define GL_RGB_S3TC 0x83A0 +#define GL_RGB4_S3TC 0x83A1 +#define GL_RGBA_S3TC 0x83A2 +#define GL_RGBA4_S3TC 0x83A3 +#endif + +#ifndef GL_ATI_draw_buffers +#define GL_MAX_DRAW_BUFFERS_ATI 0x8824 +#define GL_DRAW_BUFFER0_ATI 0x8825 +#define GL_DRAW_BUFFER1_ATI 0x8826 +#define GL_DRAW_BUFFER2_ATI 0x8827 +#define GL_DRAW_BUFFER3_ATI 0x8828 +#define GL_DRAW_BUFFER4_ATI 0x8829 +#define GL_DRAW_BUFFER5_ATI 0x882A +#define GL_DRAW_BUFFER6_ATI 0x882B +#define GL_DRAW_BUFFER7_ATI 0x882C +#define GL_DRAW_BUFFER8_ATI 0x882D +#define GL_DRAW_BUFFER9_ATI 0x882E +#define GL_DRAW_BUFFER10_ATI 0x882F +#define GL_DRAW_BUFFER11_ATI 0x8830 +#define GL_DRAW_BUFFER12_ATI 0x8831 +#define GL_DRAW_BUFFER13_ATI 0x8832 +#define GL_DRAW_BUFFER14_ATI 0x8833 +#define GL_DRAW_BUFFER15_ATI 0x8834 +#endif + +#ifndef GL_ATI_pixel_format_float +#define GL_TYPE_RGBA_FLOAT_ATI 0x8820 +#define GL_COLOR_CLEAR_UNCLAMPED_VALUE_ATI 0x8835 +#endif + +#ifndef GL_ATI_texture_env_combine3 +#define GL_MODULATE_ADD_ATI 0x8744 +#define GL_MODULATE_SIGNED_ADD_ATI 0x8745 +#define GL_MODULATE_SUBTRACT_ATI 0x8746 +#endif + +#ifndef GL_ATI_texture_float +#define GL_RGBA_FLOAT32_ATI 0x8814 +#define GL_RGB_FLOAT32_ATI 0x8815 +#define GL_ALPHA_FLOAT32_ATI 0x8816 +#define GL_INTENSITY_FLOAT32_ATI 0x8817 +#define GL_LUMINANCE_FLOAT32_ATI 0x8818 +#define GL_LUMINANCE_ALPHA_FLOAT32_ATI 0x8819 +#define GL_RGBA_FLOAT16_ATI 0x881A +#define GL_RGB_FLOAT16_ATI 0x881B +#define GL_ALPHA_FLOAT16_ATI 0x881C +#define GL_INTENSITY_FLOAT16_ATI 0x881D +#define GL_LUMINANCE_FLOAT16_ATI 0x881E +#define GL_LUMINANCE_ALPHA_FLOAT16_ATI 0x881F +#endif + +#ifndef GL_NV_float_buffer +#define GL_FLOAT_R_NV 0x8880 +#define GL_FLOAT_RG_NV 0x8881 +#define GL_FLOAT_RGB_NV 0x8882 +#define GL_FLOAT_RGBA_NV 0x8883 +#define GL_FLOAT_R16_NV 0x8884 +#define GL_FLOAT_R32_NV 0x8885 +#define GL_FLOAT_RG16_NV 0x8886 +#define GL_FLOAT_RG32_NV 0x8887 +#define GL_FLOAT_RGB16_NV 0x8888 +#define GL_FLOAT_RGB32_NV 0x8889 +#define GL_FLOAT_RGBA16_NV 0x888A +#define GL_FLOAT_RGBA32_NV 0x888B +#define GL_TEXTURE_FLOAT_COMPONENTS_NV 0x888C +#define GL_FLOAT_CLEAR_COLOR_VALUE_NV 0x888D +#define GL_FLOAT_RGBA_MODE_NV 0x888E +#endif + +#ifndef GL_NV_fragment_program +#define GL_MAX_FRAGMENT_PROGRAM_LOCAL_PARAMETERS_NV 0x8868 +#define GL_FRAGMENT_PROGRAM_NV 0x8870 +#define GL_MAX_TEXTURE_COORDS_NV 0x8871 +#define GL_MAX_TEXTURE_IMAGE_UNITS_NV 0x8872 +#define GL_FRAGMENT_PROGRAM_BINDING_NV 0x8873 +#define GL_PROGRAM_ERROR_STRING_NV 0x8874 +#endif + +#ifndef GL_NV_half_float +#define GL_HALF_FLOAT_NV 0x140B +#endif + +#ifndef GL_NV_pixel_data_range +#define GL_WRITE_PIXEL_DATA_RANGE_NV 0x8878 +#define GL_READ_PIXEL_DATA_RANGE_NV 0x8879 +#define GL_WRITE_PIXEL_DATA_RANGE_LENGTH_NV 0x887A +#define GL_READ_PIXEL_DATA_RANGE_LENGTH_NV 0x887B +#define GL_WRITE_PIXEL_DATA_RANGE_POINTER_NV 0x887C +#define GL_READ_PIXEL_DATA_RANGE_POINTER_NV 0x887D +#endif + +#ifndef GL_NV_primitive_restart +#define GL_PRIMITIVE_RESTART_NV 0x8558 +#define GL_PRIMITIVE_RESTART_INDEX_NV 0x8559 +#endif + +#ifndef GL_NV_texture_expand_normal +#define GL_TEXTURE_UNSIGNED_REMAP_MODE_NV 0x888F +#endif + +#ifndef GL_NV_vertex_program2 +#endif + +#ifndef GL_ATI_map_object_buffer +#endif + +#ifndef GL_ATI_separate_stencil +#define GL_STENCIL_BACK_FUNC_ATI 0x8800 +#define GL_STENCIL_BACK_FAIL_ATI 0x8801 +#define GL_STENCIL_BACK_PASS_DEPTH_FAIL_ATI 0x8802 +#define GL_STENCIL_BACK_PASS_DEPTH_PASS_ATI 0x8803 +#endif + +#ifndef GL_ATI_vertex_attrib_array_object +#endif + +#ifndef GL_OES_read_format +#define GL_IMPLEMENTATION_COLOR_READ_TYPE_OES 0x8B9A +#define GL_IMPLEMENTATION_COLOR_READ_FORMAT_OES 0x8B9B +#endif + +#ifndef GL_EXT_depth_bounds_test +#define GL_DEPTH_BOUNDS_TEST_EXT 0x8890 +#define GL_DEPTH_BOUNDS_EXT 0x8891 +#endif + +#ifndef GL_EXT_texture_mirror_clamp +#define GL_MIRROR_CLAMP_EXT 0x8742 +#define GL_MIRROR_CLAMP_TO_EDGE_EXT 0x8743 +#define GL_MIRROR_CLAMP_TO_BORDER_EXT 0x8912 +#endif + +#ifndef GL_EXT_blend_equation_separate +#define GL_BLEND_EQUATION_RGB_EXT GL_BLEND_EQUATION +#define GL_BLEND_EQUATION_ALPHA_EXT 0x883D +#endif + +#ifndef GL_MESA_pack_invert +#define GL_PACK_INVERT_MESA 0x8758 +#endif + +#ifndef GL_MESA_ycbcr_texture +#define GL_UNSIGNED_SHORT_8_8_MESA 0x85BA +#define GL_UNSIGNED_SHORT_8_8_REV_MESA 0x85BB +#define GL_YCBCR_MESA 0x8757 +#endif + +#ifndef GL_EXT_pixel_buffer_object +#define GL_PIXEL_PACK_BUFFER_EXT 0x88EB +#define GL_PIXEL_UNPACK_BUFFER_EXT 0x88EC +#define GL_PIXEL_PACK_BUFFER_BINDING_EXT 0x88ED +#define GL_PIXEL_UNPACK_BUFFER_BINDING_EXT 0x88EF +#endif + +#ifndef GL_NV_fragment_program_option +#endif + +#ifndef GL_NV_fragment_program2 +#define GL_MAX_PROGRAM_EXEC_INSTRUCTIONS_NV 0x88F4 +#define GL_MAX_PROGRAM_CALL_DEPTH_NV 0x88F5 +#define GL_MAX_PROGRAM_IF_DEPTH_NV 0x88F6 +#define GL_MAX_PROGRAM_LOOP_DEPTH_NV 0x88F7 +#define GL_MAX_PROGRAM_LOOP_COUNT_NV 0x88F8 +#endif + +#ifndef GL_NV_vertex_program2_option +/* reuse GL_MAX_PROGRAM_EXEC_INSTRUCTIONS_NV */ +/* reuse GL_MAX_PROGRAM_CALL_DEPTH_NV */ +#endif + +#ifndef GL_NV_vertex_program3 +/* reuse GL_MAX_VERTEX_TEXTURE_IMAGE_UNITS_ARB */ +#endif + +#ifndef GL_EXT_framebuffer_object +#define GL_INVALID_FRAMEBUFFER_OPERATION_EXT 0x0506 +#define GL_MAX_RENDERBUFFER_SIZE_EXT 0x84E8 +#define GL_FRAMEBUFFER_BINDING_EXT 0x8CA6 +#define GL_RENDERBUFFER_BINDING_EXT 0x8CA7 +#define GL_FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE_EXT 0x8CD0 +#define GL_FRAMEBUFFER_ATTACHMENT_OBJECT_NAME_EXT 0x8CD1 +#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL_EXT 0x8CD2 +#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE_EXT 0x8CD3 +#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_3D_ZOFFSET_EXT 0x8CD4 +#define GL_FRAMEBUFFER_COMPLETE_EXT 0x8CD5 +#define GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT_EXT 0x8CD6 +#define GL_FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT_EXT 0x8CD7 +#define GL_FRAMEBUFFER_INCOMPLETE_DIMENSIONS_EXT 0x8CD9 +#define GL_FRAMEBUFFER_INCOMPLETE_FORMATS_EXT 0x8CDA +#define GL_FRAMEBUFFER_INCOMPLETE_DRAW_BUFFER_EXT 0x8CDB +#define GL_FRAMEBUFFER_INCOMPLETE_READ_BUFFER_EXT 0x8CDC +#define GL_FRAMEBUFFER_UNSUPPORTED_EXT 0x8CDD +#define GL_MAX_COLOR_ATTACHMENTS_EXT 0x8CDF +#define GL_COLOR_ATTACHMENT0_EXT 0x8CE0 +#define GL_COLOR_ATTACHMENT1_EXT 0x8CE1 +#define GL_COLOR_ATTACHMENT2_EXT 0x8CE2 +#define GL_COLOR_ATTACHMENT3_EXT 0x8CE3 +#define GL_COLOR_ATTACHMENT4_EXT 0x8CE4 +#define GL_COLOR_ATTACHMENT5_EXT 0x8CE5 +#define GL_COLOR_ATTACHMENT6_EXT 0x8CE6 +#define GL_COLOR_ATTACHMENT7_EXT 0x8CE7 +#define GL_COLOR_ATTACHMENT8_EXT 0x8CE8 +#define GL_COLOR_ATTACHMENT9_EXT 0x8CE9 +#define GL_COLOR_ATTACHMENT10_EXT 0x8CEA +#define GL_COLOR_ATTACHMENT11_EXT 0x8CEB +#define GL_COLOR_ATTACHMENT12_EXT 0x8CEC +#define GL_COLOR_ATTACHMENT13_EXT 0x8CED +#define GL_COLOR_ATTACHMENT14_EXT 0x8CEE +#define GL_COLOR_ATTACHMENT15_EXT 0x8CEF +#define GL_DEPTH_ATTACHMENT_EXT 0x8D00 +#define GL_STENCIL_ATTACHMENT_EXT 0x8D20 +#define GL_FRAMEBUFFER_EXT 0x8D40 +#define GL_RENDERBUFFER_EXT 0x8D41 +#define GL_RENDERBUFFER_WIDTH_EXT 0x8D42 +#define GL_RENDERBUFFER_HEIGHT_EXT 0x8D43 +#define GL_RENDERBUFFER_INTERNAL_FORMAT_EXT 0x8D44 +#define GL_STENCIL_INDEX1_EXT 0x8D46 +#define GL_STENCIL_INDEX4_EXT 0x8D47 +#define GL_STENCIL_INDEX8_EXT 0x8D48 +#define GL_STENCIL_INDEX16_EXT 0x8D49 +#define GL_RENDERBUFFER_RED_SIZE_EXT 0x8D50 +#define GL_RENDERBUFFER_GREEN_SIZE_EXT 0x8D51 +#define GL_RENDERBUFFER_BLUE_SIZE_EXT 0x8D52 +#define GL_RENDERBUFFER_ALPHA_SIZE_EXT 0x8D53 +#define GL_RENDERBUFFER_DEPTH_SIZE_EXT 0x8D54 +#define GL_RENDERBUFFER_STENCIL_SIZE_EXT 0x8D55 +#endif + +#ifndef GL_GREMEDY_string_marker +#endif + +#ifndef GL_EXT_packed_depth_stencil +#define GL_DEPTH_STENCIL_EXT 0x84F9 +#define GL_UNSIGNED_INT_24_8_EXT 0x84FA +#define GL_DEPTH24_STENCIL8_EXT 0x88F0 +#define GL_TEXTURE_STENCIL_SIZE_EXT 0x88F1 +#endif + +#ifndef GL_EXT_stencil_clear_tag +#define GL_STENCIL_TAG_BITS_EXT 0x88F2 +#define GL_STENCIL_CLEAR_TAG_VALUE_EXT 0x88F3 +#endif + +#ifndef GL_EXT_texture_sRGB +#define GL_SRGB_EXT 0x8C40 +#define GL_SRGB8_EXT 0x8C41 +#define GL_SRGB_ALPHA_EXT 0x8C42 +#define GL_SRGB8_ALPHA8_EXT 0x8C43 +#define GL_SLUMINANCE_ALPHA_EXT 0x8C44 +#define GL_SLUMINANCE8_ALPHA8_EXT 0x8C45 +#define GL_SLUMINANCE_EXT 0x8C46 +#define GL_SLUMINANCE8_EXT 0x8C47 +#define GL_COMPRESSED_SRGB_EXT 0x8C48 +#define GL_COMPRESSED_SRGB_ALPHA_EXT 0x8C49 +#define GL_COMPRESSED_SLUMINANCE_EXT 0x8C4A +#define GL_COMPRESSED_SLUMINANCE_ALPHA_EXT 0x8C4B +#define GL_COMPRESSED_SRGB_S3TC_DXT1_EXT 0x8C4C +#define GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT1_EXT 0x8C4D +#define GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT3_EXT 0x8C4E +#define GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT5_EXT 0x8C4F +#endif + +#ifndef GL_EXT_framebuffer_blit +#define GL_READ_FRAMEBUFFER_EXT 0x8CA8 +#define GL_DRAW_FRAMEBUFFER_EXT 0x8CA9 +#define GL_DRAW_FRAMEBUFFER_BINDING_EXT GL_FRAMEBUFFER_BINDING_EXT +#define GL_READ_FRAMEBUFFER_BINDING_EXT 0x8CAA +#endif + +#ifndef GL_EXT_framebuffer_multisample +#define GL_RENDERBUFFER_SAMPLES_EXT 0x8CAB +#define GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE_EXT 0x8D56 +#define GL_MAX_SAMPLES_EXT 0x8D57 +#endif + +#ifndef GL_MESAX_texture_stack +#define GL_TEXTURE_1D_STACK_MESAX 0x8759 +#define GL_TEXTURE_2D_STACK_MESAX 0x875A +#define GL_PROXY_TEXTURE_1D_STACK_MESAX 0x875B +#define GL_PROXY_TEXTURE_2D_STACK_MESAX 0x875C +#define GL_TEXTURE_1D_STACK_BINDING_MESAX 0x875D +#define GL_TEXTURE_2D_STACK_BINDING_MESAX 0x875E +#endif + +#ifndef GL_EXT_timer_query +#define GL_TIME_ELAPSED_EXT 0x88BF +#endif + +#ifndef GL_EXT_gpu_program_parameters +#endif + +#ifndef GL_APPLE_flush_buffer_range +#define GL_BUFFER_SERIALIZED_MODIFY_APPLE 0x8A12 +#define GL_BUFFER_FLUSHING_UNMAP_APPLE 0x8A13 +#endif + +#ifndef GL_NV_gpu_program4 +#define GL_MIN_PROGRAM_TEXEL_OFFSET_NV 0x8904 +#define GL_MAX_PROGRAM_TEXEL_OFFSET_NV 0x8905 +#define GL_PROGRAM_ATTRIB_COMPONENTS_NV 0x8906 +#define GL_PROGRAM_RESULT_COMPONENTS_NV 0x8907 +#define GL_MAX_PROGRAM_ATTRIB_COMPONENTS_NV 0x8908 +#define GL_MAX_PROGRAM_RESULT_COMPONENTS_NV 0x8909 +#define GL_MAX_PROGRAM_GENERIC_ATTRIBS_NV 0x8DA5 +#define GL_MAX_PROGRAM_GENERIC_RESULTS_NV 0x8DA6 +#endif + +#ifndef GL_NV_geometry_program4 +#define GL_LINES_ADJACENCY_EXT 0x000A +#define GL_LINE_STRIP_ADJACENCY_EXT 0x000B +#define GL_TRIANGLES_ADJACENCY_EXT 0x000C +#define GL_TRIANGLE_STRIP_ADJACENCY_EXT 0x000D +#define GL_GEOMETRY_PROGRAM_NV 0x8C26 +#define GL_MAX_PROGRAM_OUTPUT_VERTICES_NV 0x8C27 +#define GL_MAX_PROGRAM_TOTAL_OUTPUT_COMPONENTS_NV 0x8C28 +#define GL_GEOMETRY_VERTICES_OUT_EXT 0x8DDA +#define GL_GEOMETRY_INPUT_TYPE_EXT 0x8DDB +#define GL_GEOMETRY_OUTPUT_TYPE_EXT 0x8DDC +#define GL_MAX_GEOMETRY_TEXTURE_IMAGE_UNITS_EXT 0x8C29 +#define GL_FRAMEBUFFER_ATTACHMENT_LAYERED_EXT 0x8DA7 +#define GL_FRAMEBUFFER_INCOMPLETE_LAYER_TARGETS_EXT 0x8DA8 +#define GL_FRAMEBUFFER_INCOMPLETE_LAYER_COUNT_EXT 0x8DA9 +#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER_EXT 0x8CD4 +#define GL_PROGRAM_POINT_SIZE_EXT 0x8642 +#endif + +#ifndef GL_EXT_geometry_shader4 +#define GL_GEOMETRY_SHADER_EXT 0x8DD9 +/* reuse GL_GEOMETRY_VERTICES_OUT_EXT */ +/* reuse GL_GEOMETRY_INPUT_TYPE_EXT */ +/* reuse GL_GEOMETRY_OUTPUT_TYPE_EXT */ +/* reuse GL_MAX_GEOMETRY_TEXTURE_IMAGE_UNITS_EXT */ +#define GL_MAX_GEOMETRY_VARYING_COMPONENTS_EXT 0x8DDD +#define GL_MAX_VERTEX_VARYING_COMPONENTS_EXT 0x8DDE +#define GL_MAX_VARYING_COMPONENTS_EXT 0x8B4B +#define GL_MAX_GEOMETRY_UNIFORM_COMPONENTS_EXT 0x8DDF +#define GL_MAX_GEOMETRY_OUTPUT_VERTICES_EXT 0x8DE0 +#define GL_MAX_GEOMETRY_TOTAL_OUTPUT_COMPONENTS_EXT 0x8DE1 +/* reuse GL_LINES_ADJACENCY_EXT */ +/* reuse GL_LINE_STRIP_ADJACENCY_EXT */ +/* reuse GL_TRIANGLES_ADJACENCY_EXT */ +/* reuse GL_TRIANGLE_STRIP_ADJACENCY_EXT */ +/* reuse GL_FRAMEBUFFER_INCOMPLETE_LAYER_TARGETS_EXT */ +/* reuse GL_FRAMEBUFFER_INCOMPLETE_LAYER_COUNT_EXT */ +/* reuse GL_FRAMEBUFFER_ATTACHMENT_LAYERED_EXT */ +/* reuse GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER_EXT */ +/* reuse GL_PROGRAM_POINT_SIZE_EXT */ +#endif + +#ifndef GL_NV_vertex_program4 +#define GL_VERTEX_ATTRIB_ARRAY_INTEGER_NV 0x88FD +#endif + +#ifndef GL_EXT_gpu_shader4 +#define GL_SAMPLER_1D_ARRAY_EXT 0x8DC0 +#define GL_SAMPLER_2D_ARRAY_EXT 0x8DC1 +#define GL_SAMPLER_BUFFER_EXT 0x8DC2 +#define GL_SAMPLER_1D_ARRAY_SHADOW_EXT 0x8DC3 +#define GL_SAMPLER_2D_ARRAY_SHADOW_EXT 0x8DC4 +#define GL_SAMPLER_CUBE_SHADOW_EXT 0x8DC5 +#define GL_UNSIGNED_INT_VEC2_EXT 0x8DC6 +#define GL_UNSIGNED_INT_VEC3_EXT 0x8DC7 +#define GL_UNSIGNED_INT_VEC4_EXT 0x8DC8 +#define GL_INT_SAMPLER_1D_EXT 0x8DC9 +#define GL_INT_SAMPLER_2D_EXT 0x8DCA +#define GL_INT_SAMPLER_3D_EXT 0x8DCB +#define GL_INT_SAMPLER_CUBE_EXT 0x8DCC +#define GL_INT_SAMPLER_2D_RECT_EXT 0x8DCD +#define GL_INT_SAMPLER_1D_ARRAY_EXT 0x8DCE +#define GL_INT_SAMPLER_2D_ARRAY_EXT 0x8DCF +#define GL_INT_SAMPLER_BUFFER_EXT 0x8DD0 +#define GL_UNSIGNED_INT_SAMPLER_1D_EXT 0x8DD1 +#define GL_UNSIGNED_INT_SAMPLER_2D_EXT 0x8DD2 +#define GL_UNSIGNED_INT_SAMPLER_3D_EXT 0x8DD3 +#define GL_UNSIGNED_INT_SAMPLER_CUBE_EXT 0x8DD4 +#define GL_UNSIGNED_INT_SAMPLER_2D_RECT_EXT 0x8DD5 +#define GL_UNSIGNED_INT_SAMPLER_1D_ARRAY_EXT 0x8DD6 +#define GL_UNSIGNED_INT_SAMPLER_2D_ARRAY_EXT 0x8DD7 +#define GL_UNSIGNED_INT_SAMPLER_BUFFER_EXT 0x8DD8 +#endif + +#ifndef GL_EXT_draw_instanced +#endif + +#ifndef GL_EXT_packed_float +#define GL_R11F_G11F_B10F_EXT 0x8C3A +#define GL_UNSIGNED_INT_10F_11F_11F_REV_EXT 0x8C3B +#define GL_RGBA_SIGNED_COMPONENTS_EXT 0x8C3C +#endif + +#ifndef GL_EXT_texture_array +#define GL_TEXTURE_1D_ARRAY_EXT 0x8C18 +#define GL_PROXY_TEXTURE_1D_ARRAY_EXT 0x8C19 +#define GL_TEXTURE_2D_ARRAY_EXT 0x8C1A +#define GL_PROXY_TEXTURE_2D_ARRAY_EXT 0x8C1B +#define GL_TEXTURE_BINDING_1D_ARRAY_EXT 0x8C1C +#define GL_TEXTURE_BINDING_2D_ARRAY_EXT 0x8C1D +#define GL_MAX_ARRAY_TEXTURE_LAYERS_EXT 0x88FF +#define GL_COMPARE_REF_DEPTH_TO_TEXTURE_EXT 0x884E +/* reuse GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER_EXT */ +#endif + +#ifndef GL_EXT_texture_buffer_object +#define GL_TEXTURE_BUFFER_EXT 0x8C2A +#define GL_MAX_TEXTURE_BUFFER_SIZE_EXT 0x8C2B +#define GL_TEXTURE_BINDING_BUFFER_EXT 0x8C2C +#define GL_TEXTURE_BUFFER_DATA_STORE_BINDING_EXT 0x8C2D +#define GL_TEXTURE_BUFFER_FORMAT_EXT 0x8C2E +#endif + +#ifndef GL_EXT_texture_compression_latc +#define GL_COMPRESSED_LUMINANCE_LATC1_EXT 0x8C70 +#define GL_COMPRESSED_SIGNED_LUMINANCE_LATC1_EXT 0x8C71 +#define GL_COMPRESSED_LUMINANCE_ALPHA_LATC2_EXT 0x8C72 +#define GL_COMPRESSED_SIGNED_LUMINANCE_ALPHA_LATC2_EXT 0x8C73 +#endif + +#ifndef GL_EXT_texture_compression_rgtc +#define GL_COMPRESSED_RED_RGTC1_EXT 0x8DBB +#define GL_COMPRESSED_SIGNED_RED_RGTC1_EXT 0x8DBC +#define GL_COMPRESSED_RED_GREEN_RGTC2_EXT 0x8DBD +#define GL_COMPRESSED_SIGNED_RED_GREEN_RGTC2_EXT 0x8DBE +#endif + +#ifndef GL_EXT_texture_shared_exponent +#define GL_RGB9_E5_EXT 0x8C3D +#define GL_UNSIGNED_INT_5_9_9_9_REV_EXT 0x8C3E +#define GL_TEXTURE_SHARED_SIZE_EXT 0x8C3F +#endif + +#ifndef GL_NV_depth_buffer_float +#define GL_DEPTH_COMPONENT32F_NV 0x8DAB +#define GL_DEPTH32F_STENCIL8_NV 0x8DAC +#define GL_FLOAT_32_UNSIGNED_INT_24_8_REV_NV 0x8DAD +#define GL_DEPTH_BUFFER_FLOAT_MODE_NV 0x8DAF +#endif + +#ifndef GL_NV_fragment_program4 +#endif + +#ifndef GL_NV_framebuffer_multisample_coverage +#define GL_RENDERBUFFER_COVERAGE_SAMPLES_NV 0x8CAB +#define GL_RENDERBUFFER_COLOR_SAMPLES_NV 0x8E10 +#define GL_MAX_MULTISAMPLE_COVERAGE_MODES_NV 0x8E11 +#define GL_MULTISAMPLE_COVERAGE_MODES_NV 0x8E12 +#endif + +#ifndef GL_EXT_framebuffer_sRGB +#define GL_FRAMEBUFFER_SRGB_EXT 0x8DB9 +#define GL_FRAMEBUFFER_SRGB_CAPABLE_EXT 0x8DBA +#endif + +#ifndef GL_NV_geometry_shader4 +#endif + +#ifndef GL_NV_parameter_buffer_object +#define GL_MAX_PROGRAM_PARAMETER_BUFFER_BINDINGS_NV 0x8DA0 +#define GL_MAX_PROGRAM_PARAMETER_BUFFER_SIZE_NV 0x8DA1 +#define GL_VERTEX_PROGRAM_PARAMETER_BUFFER_NV 0x8DA2 +#define GL_GEOMETRY_PROGRAM_PARAMETER_BUFFER_NV 0x8DA3 +#define GL_FRAGMENT_PROGRAM_PARAMETER_BUFFER_NV 0x8DA4 +#endif + +#ifndef GL_EXT_draw_buffers2 +#endif + +#ifndef GL_NV_transform_feedback +#define GL_BACK_PRIMARY_COLOR_NV 0x8C77 +#define GL_BACK_SECONDARY_COLOR_NV 0x8C78 +#define GL_TEXTURE_COORD_NV 0x8C79 +#define GL_CLIP_DISTANCE_NV 0x8C7A +#define GL_VERTEX_ID_NV 0x8C7B +#define GL_PRIMITIVE_ID_NV 0x8C7C +#define GL_GENERIC_ATTRIB_NV 0x8C7D +#define GL_TRANSFORM_FEEDBACK_ATTRIBS_NV 0x8C7E +#define GL_TRANSFORM_FEEDBACK_BUFFER_MODE_NV 0x8C7F +#define GL_MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS_NV 0x8C80 +#define GL_ACTIVE_VARYINGS_NV 0x8C81 +#define GL_ACTIVE_VARYING_MAX_LENGTH_NV 0x8C82 +#define GL_TRANSFORM_FEEDBACK_VARYINGS_NV 0x8C83 +#define GL_TRANSFORM_FEEDBACK_BUFFER_START_NV 0x8C84 +#define GL_TRANSFORM_FEEDBACK_BUFFER_SIZE_NV 0x8C85 +#define GL_TRANSFORM_FEEDBACK_RECORD_NV 0x8C86 +#define GL_PRIMITIVES_GENERATED_NV 0x8C87 +#define GL_TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN_NV 0x8C88 +#define GL_RASTERIZER_DISCARD_NV 0x8C89 +#define GL_MAX_TRANSFORM_FEEDBACK_INTERLEAVED_ATTRIBS_NV 0x8C8A +#define GL_MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS_NV 0x8C8B +#define GL_INTERLEAVED_ATTRIBS_NV 0x8C8C +#define GL_SEPARATE_ATTRIBS_NV 0x8C8D +#define GL_TRANSFORM_FEEDBACK_BUFFER_NV 0x8C8E +#define GL_TRANSFORM_FEEDBACK_BUFFER_BINDING_NV 0x8C8F +#endif + +#ifndef GL_EXT_bindable_uniform +#define GL_MAX_VERTEX_BINDABLE_UNIFORMS_EXT 0x8DE2 +#define GL_MAX_FRAGMENT_BINDABLE_UNIFORMS_EXT 0x8DE3 +#define GL_MAX_GEOMETRY_BINDABLE_UNIFORMS_EXT 0x8DE4 +#define GL_MAX_BINDABLE_UNIFORM_SIZE_EXT 0x8DED +#define GL_UNIFORM_BUFFER_EXT 0x8DEE +#define GL_UNIFORM_BUFFER_BINDING_EXT 0x8DEF +#endif + +#ifndef GL_EXT_texture_integer +#define GL_RGBA32UI_EXT 0x8D70 +#define GL_RGB32UI_EXT 0x8D71 +#define GL_ALPHA32UI_EXT 0x8D72 +#define GL_INTENSITY32UI_EXT 0x8D73 +#define GL_LUMINANCE32UI_EXT 0x8D74 +#define GL_LUMINANCE_ALPHA32UI_EXT 0x8D75 +#define GL_RGBA16UI_EXT 0x8D76 +#define GL_RGB16UI_EXT 0x8D77 +#define GL_ALPHA16UI_EXT 0x8D78 +#define GL_INTENSITY16UI_EXT 0x8D79 +#define GL_LUMINANCE16UI_EXT 0x8D7A +#define GL_LUMINANCE_ALPHA16UI_EXT 0x8D7B +#define GL_RGBA8UI_EXT 0x8D7C +#define GL_RGB8UI_EXT 0x8D7D +#define GL_ALPHA8UI_EXT 0x8D7E +#define GL_INTENSITY8UI_EXT 0x8D7F +#define GL_LUMINANCE8UI_EXT 0x8D80 +#define GL_LUMINANCE_ALPHA8UI_EXT 0x8D81 +#define GL_RGBA32I_EXT 0x8D82 +#define GL_RGB32I_EXT 0x8D83 +#define GL_ALPHA32I_EXT 0x8D84 +#define GL_INTENSITY32I_EXT 0x8D85 +#define GL_LUMINANCE32I_EXT 0x8D86 +#define GL_LUMINANCE_ALPHA32I_EXT 0x8D87 +#define GL_RGBA16I_EXT 0x8D88 +#define GL_RGB16I_EXT 0x8D89 +#define GL_ALPHA16I_EXT 0x8D8A +#define GL_INTENSITY16I_EXT 0x8D8B +#define GL_LUMINANCE16I_EXT 0x8D8C +#define GL_LUMINANCE_ALPHA16I_EXT 0x8D8D +#define GL_RGBA8I_EXT 0x8D8E +#define GL_RGB8I_EXT 0x8D8F +#define GL_ALPHA8I_EXT 0x8D90 +#define GL_INTENSITY8I_EXT 0x8D91 +#define GL_LUMINANCE8I_EXT 0x8D92 +#define GL_LUMINANCE_ALPHA8I_EXT 0x8D93 +#define GL_RED_INTEGER_EXT 0x8D94 +#define GL_GREEN_INTEGER_EXT 0x8D95 +#define GL_BLUE_INTEGER_EXT 0x8D96 +#define GL_ALPHA_INTEGER_EXT 0x8D97 +#define GL_RGB_INTEGER_EXT 0x8D98 +#define GL_RGBA_INTEGER_EXT 0x8D99 +#define GL_BGR_INTEGER_EXT 0x8D9A +#define GL_BGRA_INTEGER_EXT 0x8D9B +#define GL_LUMINANCE_INTEGER_EXT 0x8D9C +#define GL_LUMINANCE_ALPHA_INTEGER_EXT 0x8D9D +#define GL_RGBA_INTEGER_MODE_EXT 0x8D9E +#endif + +#ifndef GL_GREMEDY_frame_terminator +#endif + +#ifndef GL_NV_conditional_render +#define GL_QUERY_WAIT_NV 0x8E13 +#define GL_QUERY_NO_WAIT_NV 0x8E14 +#define GL_QUERY_BY_REGION_WAIT_NV 0x8E15 +#define GL_QUERY_BY_REGION_NO_WAIT_NV 0x8E16 +#endif + +#ifndef GL_NV_present_video +#define GL_FRAME_NV 0x8E26 +#define GL_FIELDS_NV 0x8E27 +#define GL_CURRENT_TIME_NV 0x8E28 +#define GL_NUM_FILL_STREAMS_NV 0x8E29 +#define GL_PRESENT_TIME_NV 0x8E2A +#define GL_PRESENT_DURATION_NV 0x8E2B +#endif + +#ifndef GL_EXT_transform_feedback +#define GL_TRANSFORM_FEEDBACK_BUFFER_EXT 0x8C8E +#define GL_TRANSFORM_FEEDBACK_BUFFER_START_EXT 0x8C84 +#define GL_TRANSFORM_FEEDBACK_BUFFER_SIZE_EXT 0x8C85 +#define GL_TRANSFORM_FEEDBACK_BUFFER_BINDING_EXT 0x8C8F +#define GL_INTERLEAVED_ATTRIBS_EXT 0x8C8C +#define GL_SEPARATE_ATTRIBS_EXT 0x8C8D +#define GL_PRIMITIVES_GENERATED_EXT 0x8C87 +#define GL_TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN_EXT 0x8C88 +#define GL_RASTERIZER_DISCARD_EXT 0x8C89 +#define GL_MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS_EXT 0x8C8A +#define GL_MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS_EXT 0x8C8B +#define GL_MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS_EXT 0x8C80 +#define GL_TRANSFORM_FEEDBACK_VARYINGS_EXT 0x8C83 +#define GL_TRANSFORM_FEEDBACK_BUFFER_MODE_EXT 0x8C7F +#define GL_TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH_EXT 0x8C76 +#endif + +#ifndef GL_EXT_direct_state_access +#define GL_PROGRAM_MATRIX_EXT 0x8E2D +#define GL_TRANSPOSE_PROGRAM_MATRIX_EXT 0x8E2E +#define GL_PROGRAM_MATRIX_STACK_DEPTH_EXT 0x8E2F +#endif + +#ifndef GL_EXT_vertex_array_bgra +/* reuse GL_BGRA */ +#endif + +#ifndef GL_EXT_texture_swizzle +#define GL_TEXTURE_SWIZZLE_R_EXT 0x8E42 +#define GL_TEXTURE_SWIZZLE_G_EXT 0x8E43 +#define GL_TEXTURE_SWIZZLE_B_EXT 0x8E44 +#define GL_TEXTURE_SWIZZLE_A_EXT 0x8E45 +#define GL_TEXTURE_SWIZZLE_RGBA_EXT 0x8E46 +#endif + +#ifndef GL_NV_explicit_multisample +#define GL_SAMPLE_POSITION_NV 0x8E50 +#define GL_SAMPLE_MASK_NV 0x8E51 +#define GL_SAMPLE_MASK_VALUE_NV 0x8E52 +#define GL_TEXTURE_BINDING_RENDERBUFFER_NV 0x8E53 +#define GL_TEXTURE_RENDERBUFFER_DATA_STORE_BINDING_NV 0x8E54 +#define GL_MAX_SAMPLE_MASK_WORDS_NV 0x8E59 +#define GL_TEXTURE_RENDERBUFFER_NV 0x8E55 +#define GL_SAMPLER_RENDERBUFFER_NV 0x8E56 +#define GL_INT_SAMPLER_RENDERBUFFER_NV 0x8E57 +#define GL_UNSIGNED_INT_SAMPLER_RENDERBUFFER_NV 0x8E58 +#endif + +#ifndef GL_NV_transform_feedback2 +#define GL_TRANSFORM_FEEDBACK_NV 0x8E22 +#define GL_TRANSFORM_FEEDBACK_BUFFER_PAUSED_NV 0x8E23 +#define GL_TRANSFORM_FEEDBACK_BUFFER_ACTIVE_NV 0x8E24 +#define GL_TRANSFORM_FEEDBACK_BINDING_NV 0x8E25 +#endif + + +/*************************************************************/ + +#include +#ifndef GL_VERSION_2_0 +/* GL type for program/shader text */ +typedef char GLchar; /* native character */ +#endif + +#ifndef GL_VERSION_1_5 +/* GL types for handling large vertex buffer objects */ +typedef ptrdiff_t GLintptr; +typedef ptrdiff_t GLsizeiptr; +#endif + +#ifndef GL_ARB_vertex_buffer_object +/* GL types for handling large vertex buffer objects */ +typedef ptrdiff_t GLintptrARB; +typedef ptrdiff_t GLsizeiptrARB; +#endif + +#ifndef GL_ARB_shader_objects +/* GL types for handling shader object handles and program/shader text */ +typedef char GLcharARB; /* native character */ +typedef unsigned int GLhandleARB; /* shader object handle */ +#endif + +/* GL types for "half" precision (s10e5) float data in host memory */ +#ifndef GL_ARB_half_float_pixel +typedef unsigned short GLhalfARB; +#endif + +#ifndef GL_NV_half_float +typedef unsigned short GLhalfNV; +#endif + +#ifndef GLEXT_64_TYPES_DEFINED +/* This code block is duplicated in glxext.h, so must be protected */ +#define GLEXT_64_TYPES_DEFINED +/* Define int32_t, int64_t, and uint64_t types for UST/MSC */ +/* (as used in the GL_EXT_timer_query extension). */ +#if defined(__STDC_VERSION__) && __STDC_VERSION__ >= 199901L +#include +#elif defined(__sun__) || defined(__digital__) +#include +#if defined(__STDC__) +#if defined(__arch64__) || defined(_LP64) +typedef long int int64_t; +typedef unsigned long int uint64_t; +#else +typedef long long int int64_t; +typedef unsigned long long int uint64_t; +#endif /* __arch64__ */ +#endif /* __STDC__ */ +#elif defined( __VMS ) || defined(__sgi) +#include +#elif defined(__SCO__) || defined(__USLC__) +#include +#elif defined(__UNIXOS2__) || defined(__SOL64__) +typedef long int int32_t; +typedef long long int int64_t; +typedef unsigned long long int uint64_t; +#elif defined(_WIN32) && defined(__GNUC__) +#include +#elif defined(_WIN32) +typedef __int32 int32_t; +typedef __int64 int64_t; +typedef unsigned __int64 uint64_t; +#else +#include /* Fallback option */ +#endif +#endif + +#ifndef GL_EXT_timer_query +typedef int64_t GLint64EXT; +typedef uint64_t GLuint64EXT; +#endif + +#ifndef GL_VERSION_1_2 +#define GL_VERSION_1_2 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glBlendColor (GLclampf, GLclampf, GLclampf, GLclampf); +GLAPI void APIENTRY glBlendEquation (GLenum); +GLAPI void APIENTRY glDrawRangeElements (GLenum, GLuint, GLuint, GLsizei, GLenum, const GLvoid *); +GLAPI void APIENTRY glColorTable (GLenum, GLenum, GLsizei, GLenum, GLenum, const GLvoid *); +GLAPI void APIENTRY glColorTableParameterfv (GLenum, GLenum, const GLfloat *); +GLAPI void APIENTRY glColorTableParameteriv (GLenum, GLenum, const GLint *); +GLAPI void APIENTRY glCopyColorTable (GLenum, GLenum, GLint, GLint, GLsizei); +GLAPI void APIENTRY glGetColorTable (GLenum, GLenum, GLenum, GLvoid *); +GLAPI void APIENTRY glGetColorTableParameterfv (GLenum, GLenum, GLfloat *); +GLAPI void APIENTRY glGetColorTableParameteriv (GLenum, GLenum, GLint *); +GLAPI void APIENTRY glColorSubTable (GLenum, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *); +GLAPI void APIENTRY glCopyColorSubTable (GLenum, GLsizei, GLint, GLint, GLsizei); +GLAPI void APIENTRY glConvolutionFilter1D (GLenum, GLenum, GLsizei, GLenum, GLenum, const GLvoid *); +GLAPI void APIENTRY glConvolutionFilter2D (GLenum, GLenum, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *); +GLAPI void APIENTRY glConvolutionParameterf (GLenum, GLenum, GLfloat); +GLAPI void APIENTRY glConvolutionParameterfv (GLenum, GLenum, const GLfloat *); +GLAPI void APIENTRY glConvolutionParameteri (GLenum, GLenum, GLint); +GLAPI void APIENTRY glConvolutionParameteriv (GLenum, GLenum, const GLint *); +GLAPI void APIENTRY glCopyConvolutionFilter1D (GLenum, GLenum, GLint, GLint, GLsizei); +GLAPI void APIENTRY glCopyConvolutionFilter2D (GLenum, GLenum, GLint, GLint, GLsizei, GLsizei); +GLAPI void APIENTRY glGetConvolutionFilter (GLenum, GLenum, GLenum, GLvoid *); +GLAPI void APIENTRY glGetConvolutionParameterfv (GLenum, GLenum, GLfloat *); +GLAPI void APIENTRY glGetConvolutionParameteriv (GLenum, GLenum, GLint *); +GLAPI void APIENTRY glGetSeparableFilter (GLenum, GLenum, GLenum, GLvoid *, GLvoid *, GLvoid *); +GLAPI void APIENTRY glSeparableFilter2D (GLenum, GLenum, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *, const GLvoid *); +GLAPI void APIENTRY glGetHistogram (GLenum, GLboolean, GLenum, GLenum, GLvoid *); +GLAPI void APIENTRY glGetHistogramParameterfv (GLenum, GLenum, GLfloat *); +GLAPI void APIENTRY glGetHistogramParameteriv (GLenum, GLenum, GLint *); +GLAPI void APIENTRY glGetMinmax (GLenum, GLboolean, GLenum, GLenum, GLvoid *); +GLAPI void APIENTRY glGetMinmaxParameterfv (GLenum, GLenum, GLfloat *); +GLAPI void APIENTRY glGetMinmaxParameteriv (GLenum, GLenum, GLint *); +GLAPI void APIENTRY glHistogram (GLenum, GLsizei, GLenum, GLboolean); +GLAPI void APIENTRY glMinmax (GLenum, GLenum, GLboolean); +GLAPI void APIENTRY glResetHistogram (GLenum); +GLAPI void APIENTRY glResetMinmax (GLenum); +GLAPI void APIENTRY glTexImage3D (GLenum, GLint, GLint, GLsizei, GLsizei, GLsizei, GLint, GLenum, GLenum, const GLvoid *); +GLAPI void APIENTRY glTexSubImage3D (GLenum, GLint, GLint, GLint, GLint, GLsizei, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *); +GLAPI void APIENTRY glCopyTexSubImage3D (GLenum, GLint, GLint, GLint, GLint, GLint, GLint, GLsizei, GLsizei); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLBLENDCOLORPROC) (GLclampf red, GLclampf green, GLclampf blue, GLclampf alpha); +typedef void (APIENTRYP PFNGLBLENDEQUATIONPROC) (GLenum mode); +typedef void (APIENTRYP PFNGLDRAWRANGEELEMENTSPROC) (GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices); +typedef void (APIENTRYP PFNGLCOLORTABLEPROC) (GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *table); +typedef void (APIENTRYP PFNGLCOLORTABLEPARAMETERFVPROC) (GLenum target, GLenum pname, const GLfloat *params); +typedef void (APIENTRYP PFNGLCOLORTABLEPARAMETERIVPROC) (GLenum target, GLenum pname, const GLint *params); +typedef void (APIENTRYP PFNGLCOPYCOLORTABLEPROC) (GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width); +typedef void (APIENTRYP PFNGLGETCOLORTABLEPROC) (GLenum target, GLenum format, GLenum type, GLvoid *table); +typedef void (APIENTRYP PFNGLGETCOLORTABLEPARAMETERFVPROC) (GLenum target, GLenum pname, GLfloat *params); +typedef void (APIENTRYP PFNGLGETCOLORTABLEPARAMETERIVPROC) (GLenum target, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLCOLORSUBTABLEPROC) (GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum type, const GLvoid *data); +typedef void (APIENTRYP PFNGLCOPYCOLORSUBTABLEPROC) (GLenum target, GLsizei start, GLint x, GLint y, GLsizei width); +typedef void (APIENTRYP PFNGLCONVOLUTIONFILTER1DPROC) (GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *image); +typedef void (APIENTRYP PFNGLCONVOLUTIONFILTER2DPROC) (GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *image); +typedef void (APIENTRYP PFNGLCONVOLUTIONPARAMETERFPROC) (GLenum target, GLenum pname, GLfloat params); +typedef void (APIENTRYP PFNGLCONVOLUTIONPARAMETERFVPROC) (GLenum target, GLenum pname, const GLfloat *params); +typedef void (APIENTRYP PFNGLCONVOLUTIONPARAMETERIPROC) (GLenum target, GLenum pname, GLint params); +typedef void (APIENTRYP PFNGLCONVOLUTIONPARAMETERIVPROC) (GLenum target, GLenum pname, const GLint *params); +typedef void (APIENTRYP PFNGLCOPYCONVOLUTIONFILTER1DPROC) (GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width); +typedef void (APIENTRYP PFNGLCOPYCONVOLUTIONFILTER2DPROC) (GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height); +typedef void (APIENTRYP PFNGLGETCONVOLUTIONFILTERPROC) (GLenum target, GLenum format, GLenum type, GLvoid *image); +typedef void (APIENTRYP PFNGLGETCONVOLUTIONPARAMETERFVPROC) (GLenum target, GLenum pname, GLfloat *params); +typedef void (APIENTRYP PFNGLGETCONVOLUTIONPARAMETERIVPROC) (GLenum target, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLGETSEPARABLEFILTERPROC) (GLenum target, GLenum format, GLenum type, GLvoid *row, GLvoid *column, GLvoid *span); +typedef void (APIENTRYP PFNGLSEPARABLEFILTER2DPROC) (GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *row, const GLvoid *column); +typedef void (APIENTRYP PFNGLGETHISTOGRAMPROC) (GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values); +typedef void (APIENTRYP PFNGLGETHISTOGRAMPARAMETERFVPROC) (GLenum target, GLenum pname, GLfloat *params); +typedef void (APIENTRYP PFNGLGETHISTOGRAMPARAMETERIVPROC) (GLenum target, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLGETMINMAXPROC) (GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values); +typedef void (APIENTRYP PFNGLGETMINMAXPARAMETERFVPROC) (GLenum target, GLenum pname, GLfloat *params); +typedef void (APIENTRYP PFNGLGETMINMAXPARAMETERIVPROC) (GLenum target, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLHISTOGRAMPROC) (GLenum target, GLsizei width, GLenum internalformat, GLboolean sink); +typedef void (APIENTRYP PFNGLMINMAXPROC) (GLenum target, GLenum internalformat, GLboolean sink); +typedef void (APIENTRYP PFNGLRESETHISTOGRAMPROC) (GLenum target); +typedef void (APIENTRYP PFNGLRESETMINMAXPROC) (GLenum target); +typedef void (APIENTRYP PFNGLTEXIMAGE3DPROC) (GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels); +typedef void (APIENTRYP PFNGLTEXSUBIMAGE3DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels); +typedef void (APIENTRYP PFNGLCOPYTEXSUBIMAGE3DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height); +#endif + +#ifndef GL_VERSION_1_3 +#define GL_VERSION_1_3 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glActiveTexture (GLenum); +GLAPI void APIENTRY glClientActiveTexture (GLenum); +GLAPI void APIENTRY glMultiTexCoord1d (GLenum, GLdouble); +GLAPI void APIENTRY glMultiTexCoord1dv (GLenum, const GLdouble *); +GLAPI void APIENTRY glMultiTexCoord1f (GLenum, GLfloat); +GLAPI void APIENTRY glMultiTexCoord1fv (GLenum, const GLfloat *); +GLAPI void APIENTRY glMultiTexCoord1i (GLenum, GLint); +GLAPI void APIENTRY glMultiTexCoord1iv (GLenum, const GLint *); +GLAPI void APIENTRY glMultiTexCoord1s (GLenum, GLshort); +GLAPI void APIENTRY glMultiTexCoord1sv (GLenum, const GLshort *); +GLAPI void APIENTRY glMultiTexCoord2d (GLenum, GLdouble, GLdouble); +GLAPI void APIENTRY glMultiTexCoord2dv (GLenum, const GLdouble *); +GLAPI void APIENTRY glMultiTexCoord2f (GLenum, GLfloat, GLfloat); +GLAPI void APIENTRY glMultiTexCoord2fv (GLenum, const GLfloat *); +GLAPI void APIENTRY glMultiTexCoord2i (GLenum, GLint, GLint); +GLAPI void APIENTRY glMultiTexCoord2iv (GLenum, const GLint *); +GLAPI void APIENTRY glMultiTexCoord2s (GLenum, GLshort, GLshort); +GLAPI void APIENTRY glMultiTexCoord2sv (GLenum, const GLshort *); +GLAPI void APIENTRY glMultiTexCoord3d (GLenum, GLdouble, GLdouble, GLdouble); +GLAPI void APIENTRY glMultiTexCoord3dv (GLenum, const GLdouble *); +GLAPI void APIENTRY glMultiTexCoord3f (GLenum, GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glMultiTexCoord3fv (GLenum, const GLfloat *); +GLAPI void APIENTRY glMultiTexCoord3i (GLenum, GLint, GLint, GLint); +GLAPI void APIENTRY glMultiTexCoord3iv (GLenum, const GLint *); +GLAPI void APIENTRY glMultiTexCoord3s (GLenum, GLshort, GLshort, GLshort); +GLAPI void APIENTRY glMultiTexCoord3sv (GLenum, const GLshort *); +GLAPI void APIENTRY glMultiTexCoord4d (GLenum, GLdouble, GLdouble, GLdouble, GLdouble); +GLAPI void APIENTRY glMultiTexCoord4dv (GLenum, const GLdouble *); +GLAPI void APIENTRY glMultiTexCoord4f (GLenum, GLfloat, GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glMultiTexCoord4fv (GLenum, const GLfloat *); +GLAPI void APIENTRY glMultiTexCoord4i (GLenum, GLint, GLint, GLint, GLint); +GLAPI void APIENTRY glMultiTexCoord4iv (GLenum, const GLint *); +GLAPI void APIENTRY glMultiTexCoord4s (GLenum, GLshort, GLshort, GLshort, GLshort); +GLAPI void APIENTRY glMultiTexCoord4sv (GLenum, const GLshort *); +GLAPI void APIENTRY glLoadTransposeMatrixf (const GLfloat *); +GLAPI void APIENTRY glLoadTransposeMatrixd (const GLdouble *); +GLAPI void APIENTRY glMultTransposeMatrixf (const GLfloat *); +GLAPI void APIENTRY glMultTransposeMatrixd (const GLdouble *); +GLAPI void APIENTRY glSampleCoverage (GLclampf, GLboolean); +GLAPI void APIENTRY glCompressedTexImage3D (GLenum, GLint, GLenum, GLsizei, GLsizei, GLsizei, GLint, GLsizei, const GLvoid *); +GLAPI void APIENTRY glCompressedTexImage2D (GLenum, GLint, GLenum, GLsizei, GLsizei, GLint, GLsizei, const GLvoid *); +GLAPI void APIENTRY glCompressedTexImage1D (GLenum, GLint, GLenum, GLsizei, GLint, GLsizei, const GLvoid *); +GLAPI void APIENTRY glCompressedTexSubImage3D (GLenum, GLint, GLint, GLint, GLint, GLsizei, GLsizei, GLsizei, GLenum, GLsizei, const GLvoid *); +GLAPI void APIENTRY glCompressedTexSubImage2D (GLenum, GLint, GLint, GLint, GLsizei, GLsizei, GLenum, GLsizei, const GLvoid *); +GLAPI void APIENTRY glCompressedTexSubImage1D (GLenum, GLint, GLint, GLsizei, GLenum, GLsizei, const GLvoid *); +GLAPI void APIENTRY glGetCompressedTexImage (GLenum, GLint, GLvoid *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLACTIVETEXTUREPROC) (GLenum texture); +typedef void (APIENTRYP PFNGLCLIENTACTIVETEXTUREPROC) (GLenum texture); +typedef void (APIENTRYP PFNGLMULTITEXCOORD1DPROC) (GLenum target, GLdouble s); +typedef void (APIENTRYP PFNGLMULTITEXCOORD1DVPROC) (GLenum target, const GLdouble *v); +typedef void (APIENTRYP PFNGLMULTITEXCOORD1FPROC) (GLenum target, GLfloat s); +typedef void (APIENTRYP PFNGLMULTITEXCOORD1FVPROC) (GLenum target, const GLfloat *v); +typedef void (APIENTRYP PFNGLMULTITEXCOORD1IPROC) (GLenum target, GLint s); +typedef void (APIENTRYP PFNGLMULTITEXCOORD1IVPROC) (GLenum target, const GLint *v); +typedef void (APIENTRYP PFNGLMULTITEXCOORD1SPROC) (GLenum target, GLshort s); +typedef void (APIENTRYP PFNGLMULTITEXCOORD1SVPROC) (GLenum target, const GLshort *v); +typedef void (APIENTRYP PFNGLMULTITEXCOORD2DPROC) (GLenum target, GLdouble s, GLdouble t); +typedef void (APIENTRYP PFNGLMULTITEXCOORD2DVPROC) (GLenum target, const GLdouble *v); +typedef void (APIENTRYP PFNGLMULTITEXCOORD2FPROC) (GLenum target, GLfloat s, GLfloat t); +typedef void (APIENTRYP PFNGLMULTITEXCOORD2FVPROC) (GLenum target, const GLfloat *v); +typedef void (APIENTRYP PFNGLMULTITEXCOORD2IPROC) (GLenum target, GLint s, GLint t); +typedef void (APIENTRYP PFNGLMULTITEXCOORD2IVPROC) (GLenum target, const GLint *v); +typedef void (APIENTRYP PFNGLMULTITEXCOORD2SPROC) (GLenum target, GLshort s, GLshort t); +typedef void (APIENTRYP PFNGLMULTITEXCOORD2SVPROC) (GLenum target, const GLshort *v); +typedef void (APIENTRYP PFNGLMULTITEXCOORD3DPROC) (GLenum target, GLdouble s, GLdouble t, GLdouble r); +typedef void (APIENTRYP PFNGLMULTITEXCOORD3DVPROC) (GLenum target, const GLdouble *v); +typedef void (APIENTRYP PFNGLMULTITEXCOORD3FPROC) (GLenum target, GLfloat s, GLfloat t, GLfloat r); +typedef void (APIENTRYP PFNGLMULTITEXCOORD3FVPROC) (GLenum target, const GLfloat *v); +typedef void (APIENTRYP PFNGLMULTITEXCOORD3IPROC) (GLenum target, GLint s, GLint t, GLint r); +typedef void (APIENTRYP PFNGLMULTITEXCOORD3IVPROC) (GLenum target, const GLint *v); +typedef void (APIENTRYP PFNGLMULTITEXCOORD3SPROC) (GLenum target, GLshort s, GLshort t, GLshort r); +typedef void (APIENTRYP PFNGLMULTITEXCOORD3SVPROC) (GLenum target, const GLshort *v); +typedef void (APIENTRYP PFNGLMULTITEXCOORD4DPROC) (GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q); +typedef void (APIENTRYP PFNGLMULTITEXCOORD4DVPROC) (GLenum target, const GLdouble *v); +typedef void (APIENTRYP PFNGLMULTITEXCOORD4FPROC) (GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q); +typedef void (APIENTRYP PFNGLMULTITEXCOORD4FVPROC) (GLenum target, const GLfloat *v); +typedef void (APIENTRYP PFNGLMULTITEXCOORD4IPROC) (GLenum target, GLint s, GLint t, GLint r, GLint q); +typedef void (APIENTRYP PFNGLMULTITEXCOORD4IVPROC) (GLenum target, const GLint *v); +typedef void (APIENTRYP PFNGLMULTITEXCOORD4SPROC) (GLenum target, GLshort s, GLshort t, GLshort r, GLshort q); +typedef void (APIENTRYP PFNGLMULTITEXCOORD4SVPROC) (GLenum target, const GLshort *v); +typedef void (APIENTRYP PFNGLLOADTRANSPOSEMATRIXFPROC) (const GLfloat *m); +typedef void (APIENTRYP PFNGLLOADTRANSPOSEMATRIXDPROC) (const GLdouble *m); +typedef void (APIENTRYP PFNGLMULTTRANSPOSEMATRIXFPROC) (const GLfloat *m); +typedef void (APIENTRYP PFNGLMULTTRANSPOSEMATRIXDPROC) (const GLdouble *m); +typedef void (APIENTRYP PFNGLSAMPLECOVERAGEPROC) (GLclampf value, GLboolean invert); +typedef void (APIENTRYP PFNGLCOMPRESSEDTEXIMAGE3DPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data); +typedef void (APIENTRYP PFNGLCOMPRESSEDTEXIMAGE2DPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data); +typedef void (APIENTRYP PFNGLCOMPRESSEDTEXIMAGE1DPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data); +typedef void (APIENTRYP PFNGLCOMPRESSEDTEXSUBIMAGE3DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data); +typedef void (APIENTRYP PFNGLCOMPRESSEDTEXSUBIMAGE2DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data); +typedef void (APIENTRYP PFNGLCOMPRESSEDTEXSUBIMAGE1DPROC) (GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data); +typedef void (APIENTRYP PFNGLGETCOMPRESSEDTEXIMAGEPROC) (GLenum target, GLint level, GLvoid *img); +#endif + +#ifndef GL_VERSION_1_4 +#define GL_VERSION_1_4 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glBlendFuncSeparate (GLenum, GLenum, GLenum, GLenum); +GLAPI void APIENTRY glFogCoordf (GLfloat); +GLAPI void APIENTRY glFogCoordfv (const GLfloat *); +GLAPI void APIENTRY glFogCoordd (GLdouble); +GLAPI void APIENTRY glFogCoorddv (const GLdouble *); +GLAPI void APIENTRY glFogCoordPointer (GLenum, GLsizei, const GLvoid *); +GLAPI void APIENTRY glMultiDrawArrays (GLenum, GLint *, GLsizei *, GLsizei); +GLAPI void APIENTRY glMultiDrawElements (GLenum, const GLsizei *, GLenum, const GLvoid* *, GLsizei); +GLAPI void APIENTRY glPointParameterf (GLenum, GLfloat); +GLAPI void APIENTRY glPointParameterfv (GLenum, const GLfloat *); +GLAPI void APIENTRY glPointParameteri (GLenum, GLint); +GLAPI void APIENTRY glPointParameteriv (GLenum, const GLint *); +GLAPI void APIENTRY glSecondaryColor3b (GLbyte, GLbyte, GLbyte); +GLAPI void APIENTRY glSecondaryColor3bv (const GLbyte *); +GLAPI void APIENTRY glSecondaryColor3d (GLdouble, GLdouble, GLdouble); +GLAPI void APIENTRY glSecondaryColor3dv (const GLdouble *); +GLAPI void APIENTRY glSecondaryColor3f (GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glSecondaryColor3fv (const GLfloat *); +GLAPI void APIENTRY glSecondaryColor3i (GLint, GLint, GLint); +GLAPI void APIENTRY glSecondaryColor3iv (const GLint *); +GLAPI void APIENTRY glSecondaryColor3s (GLshort, GLshort, GLshort); +GLAPI void APIENTRY glSecondaryColor3sv (const GLshort *); +GLAPI void APIENTRY glSecondaryColor3ub (GLubyte, GLubyte, GLubyte); +GLAPI void APIENTRY glSecondaryColor3ubv (const GLubyte *); +GLAPI void APIENTRY glSecondaryColor3ui (GLuint, GLuint, GLuint); +GLAPI void APIENTRY glSecondaryColor3uiv (const GLuint *); +GLAPI void APIENTRY glSecondaryColor3us (GLushort, GLushort, GLushort); +GLAPI void APIENTRY glSecondaryColor3usv (const GLushort *); +GLAPI void APIENTRY glSecondaryColorPointer (GLint, GLenum, GLsizei, const GLvoid *); +GLAPI void APIENTRY glWindowPos2d (GLdouble, GLdouble); +GLAPI void APIENTRY glWindowPos2dv (const GLdouble *); +GLAPI void APIENTRY glWindowPos2f (GLfloat, GLfloat); +GLAPI void APIENTRY glWindowPos2fv (const GLfloat *); +GLAPI void APIENTRY glWindowPos2i (GLint, GLint); +GLAPI void APIENTRY glWindowPos2iv (const GLint *); +GLAPI void APIENTRY glWindowPos2s (GLshort, GLshort); +GLAPI void APIENTRY glWindowPos2sv (const GLshort *); +GLAPI void APIENTRY glWindowPos3d (GLdouble, GLdouble, GLdouble); +GLAPI void APIENTRY glWindowPos3dv (const GLdouble *); +GLAPI void APIENTRY glWindowPos3f (GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glWindowPos3fv (const GLfloat *); +GLAPI void APIENTRY glWindowPos3i (GLint, GLint, GLint); +GLAPI void APIENTRY glWindowPos3iv (const GLint *); +GLAPI void APIENTRY glWindowPos3s (GLshort, GLshort, GLshort); +GLAPI void APIENTRY glWindowPos3sv (const GLshort *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLBLENDFUNCSEPARATEPROC) (GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha); +typedef void (APIENTRYP PFNGLFOGCOORDFPROC) (GLfloat coord); +typedef void (APIENTRYP PFNGLFOGCOORDFVPROC) (const GLfloat *coord); +typedef void (APIENTRYP PFNGLFOGCOORDDPROC) (GLdouble coord); +typedef void (APIENTRYP PFNGLFOGCOORDDVPROC) (const GLdouble *coord); +typedef void (APIENTRYP PFNGLFOGCOORDPOINTERPROC) (GLenum type, GLsizei stride, const GLvoid *pointer); +typedef void (APIENTRYP PFNGLMULTIDRAWARRAYSPROC) (GLenum mode, GLint *first, GLsizei *count, GLsizei primcount); +typedef void (APIENTRYP PFNGLMULTIDRAWELEMENTSPROC) (GLenum mode, const GLsizei *count, GLenum type, const GLvoid* *indices, GLsizei primcount); +typedef void (APIENTRYP PFNGLPOINTPARAMETERFPROC) (GLenum pname, GLfloat param); +typedef void (APIENTRYP PFNGLPOINTPARAMETERFVPROC) (GLenum pname, const GLfloat *params); +typedef void (APIENTRYP PFNGLPOINTPARAMETERIPROC) (GLenum pname, GLint param); +typedef void (APIENTRYP PFNGLPOINTPARAMETERIVPROC) (GLenum pname, const GLint *params); +typedef void (APIENTRYP PFNGLSECONDARYCOLOR3BPROC) (GLbyte red, GLbyte green, GLbyte blue); +typedef void (APIENTRYP PFNGLSECONDARYCOLOR3BVPROC) (const GLbyte *v); +typedef void (APIENTRYP PFNGLSECONDARYCOLOR3DPROC) (GLdouble red, GLdouble green, GLdouble blue); +typedef void (APIENTRYP PFNGLSECONDARYCOLOR3DVPROC) (const GLdouble *v); +typedef void (APIENTRYP PFNGLSECONDARYCOLOR3FPROC) (GLfloat red, GLfloat green, GLfloat blue); +typedef void (APIENTRYP PFNGLSECONDARYCOLOR3FVPROC) (const GLfloat *v); +typedef void (APIENTRYP PFNGLSECONDARYCOLOR3IPROC) (GLint red, GLint green, GLint blue); +typedef void (APIENTRYP PFNGLSECONDARYCOLOR3IVPROC) (const GLint *v); +typedef void (APIENTRYP PFNGLSECONDARYCOLOR3SPROC) (GLshort red, GLshort green, GLshort blue); +typedef void (APIENTRYP PFNGLSECONDARYCOLOR3SVPROC) (const GLshort *v); +typedef void (APIENTRYP PFNGLSECONDARYCOLOR3UBPROC) (GLubyte red, GLubyte green, GLubyte blue); +typedef void (APIENTRYP PFNGLSECONDARYCOLOR3UBVPROC) (const GLubyte *v); +typedef void (APIENTRYP PFNGLSECONDARYCOLOR3UIPROC) (GLuint red, GLuint green, GLuint blue); +typedef void (APIENTRYP PFNGLSECONDARYCOLOR3UIVPROC) (const GLuint *v); +typedef void (APIENTRYP PFNGLSECONDARYCOLOR3USPROC) (GLushort red, GLushort green, GLushort blue); +typedef void (APIENTRYP PFNGLSECONDARYCOLOR3USVPROC) (const GLushort *v); +typedef void (APIENTRYP PFNGLSECONDARYCOLORPOINTERPROC) (GLint size, GLenum type, GLsizei stride, const GLvoid *pointer); +typedef void (APIENTRYP PFNGLWINDOWPOS2DPROC) (GLdouble x, GLdouble y); +typedef void (APIENTRYP PFNGLWINDOWPOS2DVPROC) (const GLdouble *v); +typedef void (APIENTRYP PFNGLWINDOWPOS2FPROC) (GLfloat x, GLfloat y); +typedef void (APIENTRYP PFNGLWINDOWPOS2FVPROC) (const GLfloat *v); +typedef void (APIENTRYP PFNGLWINDOWPOS2IPROC) (GLint x, GLint y); +typedef void (APIENTRYP PFNGLWINDOWPOS2IVPROC) (const GLint *v); +typedef void (APIENTRYP PFNGLWINDOWPOS2SPROC) (GLshort x, GLshort y); +typedef void (APIENTRYP PFNGLWINDOWPOS2SVPROC) (const GLshort *v); +typedef void (APIENTRYP PFNGLWINDOWPOS3DPROC) (GLdouble x, GLdouble y, GLdouble z); +typedef void (APIENTRYP PFNGLWINDOWPOS3DVPROC) (const GLdouble *v); +typedef void (APIENTRYP PFNGLWINDOWPOS3FPROC) (GLfloat x, GLfloat y, GLfloat z); +typedef void (APIENTRYP PFNGLWINDOWPOS3FVPROC) (const GLfloat *v); +typedef void (APIENTRYP PFNGLWINDOWPOS3IPROC) (GLint x, GLint y, GLint z); +typedef void (APIENTRYP PFNGLWINDOWPOS3IVPROC) (const GLint *v); +typedef void (APIENTRYP PFNGLWINDOWPOS3SPROC) (GLshort x, GLshort y, GLshort z); +typedef void (APIENTRYP PFNGLWINDOWPOS3SVPROC) (const GLshort *v); +#endif + +#ifndef GL_VERSION_1_5 +#define GL_VERSION_1_5 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glGenQueries (GLsizei, GLuint *); +GLAPI void APIENTRY glDeleteQueries (GLsizei, const GLuint *); +GLAPI GLboolean APIENTRY glIsQuery (GLuint); +GLAPI void APIENTRY glBeginQuery (GLenum, GLuint); +GLAPI void APIENTRY glEndQuery (GLenum); +GLAPI void APIENTRY glGetQueryiv (GLenum, GLenum, GLint *); +GLAPI void APIENTRY glGetQueryObjectiv (GLuint, GLenum, GLint *); +GLAPI void APIENTRY glGetQueryObjectuiv (GLuint, GLenum, GLuint *); +GLAPI void APIENTRY glBindBuffer (GLenum, GLuint); +GLAPI void APIENTRY glDeleteBuffers (GLsizei, const GLuint *); +GLAPI void APIENTRY glGenBuffers (GLsizei, GLuint *); +GLAPI GLboolean APIENTRY glIsBuffer (GLuint); +GLAPI void APIENTRY glBufferData (GLenum, GLsizeiptr, const GLvoid *, GLenum); +GLAPI void APIENTRY glBufferSubData (GLenum, GLintptr, GLsizeiptr, const GLvoid *); +GLAPI void APIENTRY glGetBufferSubData (GLenum, GLintptr, GLsizeiptr, GLvoid *); +GLAPI GLvoid* APIENTRY glMapBuffer (GLenum, GLenum); +GLAPI GLboolean APIENTRY glUnmapBuffer (GLenum); +GLAPI void APIENTRY glGetBufferParameteriv (GLenum, GLenum, GLint *); +GLAPI void APIENTRY glGetBufferPointerv (GLenum, GLenum, GLvoid* *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLGENQUERIESPROC) (GLsizei n, GLuint *ids); +typedef void (APIENTRYP PFNGLDELETEQUERIESPROC) (GLsizei n, const GLuint *ids); +typedef GLboolean (APIENTRYP PFNGLISQUERYPROC) (GLuint id); +typedef void (APIENTRYP PFNGLBEGINQUERYPROC) (GLenum target, GLuint id); +typedef void (APIENTRYP PFNGLENDQUERYPROC) (GLenum target); +typedef void (APIENTRYP PFNGLGETQUERYIVPROC) (GLenum target, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLGETQUERYOBJECTIVPROC) (GLuint id, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLGETQUERYOBJECTUIVPROC) (GLuint id, GLenum pname, GLuint *params); +typedef void (APIENTRYP PFNGLBINDBUFFERPROC) (GLenum target, GLuint buffer); +typedef void (APIENTRYP PFNGLDELETEBUFFERSPROC) (GLsizei n, const GLuint *buffers); +typedef void (APIENTRYP PFNGLGENBUFFERSPROC) (GLsizei n, GLuint *buffers); +typedef GLboolean (APIENTRYP PFNGLISBUFFERPROC) (GLuint buffer); +typedef void (APIENTRYP PFNGLBUFFERDATAPROC) (GLenum target, GLsizeiptr size, const GLvoid *data, GLenum usage); +typedef void (APIENTRYP PFNGLBUFFERSUBDATAPROC) (GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid *data); +typedef void (APIENTRYP PFNGLGETBUFFERSUBDATAPROC) (GLenum target, GLintptr offset, GLsizeiptr size, GLvoid *data); +typedef GLvoid* (APIENTRYP PFNGLMAPBUFFERPROC) (GLenum target, GLenum access); +typedef GLboolean (APIENTRYP PFNGLUNMAPBUFFERPROC) (GLenum target); +typedef void (APIENTRYP PFNGLGETBUFFERPARAMETERIVPROC) (GLenum target, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLGETBUFFERPOINTERVPROC) (GLenum target, GLenum pname, GLvoid* *params); +#endif + +#ifndef GL_VERSION_2_0 +#define GL_VERSION_2_0 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glBlendEquationSeparate (GLenum, GLenum); +GLAPI void APIENTRY glDrawBuffers (GLsizei, const GLenum *); +GLAPI void APIENTRY glStencilOpSeparate (GLenum, GLenum, GLenum, GLenum); +GLAPI void APIENTRY glStencilFuncSeparate (GLenum, GLenum, GLint, GLuint); +GLAPI void APIENTRY glStencilMaskSeparate (GLenum, GLuint); +GLAPI void APIENTRY glAttachShader (GLuint, GLuint); +GLAPI void APIENTRY glBindAttribLocation (GLuint, GLuint, const GLchar *); +GLAPI void APIENTRY glCompileShader (GLuint); +GLAPI GLuint APIENTRY glCreateProgram (void); +GLAPI GLuint APIENTRY glCreateShader (GLenum); +GLAPI void APIENTRY glDeleteProgram (GLuint); +GLAPI void APIENTRY glDeleteShader (GLuint); +GLAPI void APIENTRY glDetachShader (GLuint, GLuint); +GLAPI void APIENTRY glDisableVertexAttribArray (GLuint); +GLAPI void APIENTRY glEnableVertexAttribArray (GLuint); +GLAPI void APIENTRY glGetActiveAttrib (GLuint, GLuint, GLsizei, GLsizei *, GLint *, GLenum *, GLchar *); +GLAPI void APIENTRY glGetActiveUniform (GLuint, GLuint, GLsizei, GLsizei *, GLint *, GLenum *, GLchar *); +GLAPI void APIENTRY glGetAttachedShaders (GLuint, GLsizei, GLsizei *, GLuint *); +GLAPI GLint APIENTRY glGetAttribLocation (GLuint, const GLchar *); +GLAPI void APIENTRY glGetProgramiv (GLuint, GLenum, GLint *); +GLAPI void APIENTRY glGetProgramInfoLog (GLuint, GLsizei, GLsizei *, GLchar *); +GLAPI void APIENTRY glGetShaderiv (GLuint, GLenum, GLint *); +GLAPI void APIENTRY glGetShaderInfoLog (GLuint, GLsizei, GLsizei *, GLchar *); +GLAPI void APIENTRY glGetShaderSource (GLuint, GLsizei, GLsizei *, GLchar *); +GLAPI GLint APIENTRY glGetUniformLocation (GLuint, const GLchar *); +GLAPI void APIENTRY glGetUniformfv (GLuint, GLint, GLfloat *); +GLAPI void APIENTRY glGetUniformiv (GLuint, GLint, GLint *); +GLAPI void APIENTRY glGetVertexAttribdv (GLuint, GLenum, GLdouble *); +GLAPI void APIENTRY glGetVertexAttribfv (GLuint, GLenum, GLfloat *); +GLAPI void APIENTRY glGetVertexAttribiv (GLuint, GLenum, GLint *); +GLAPI void APIENTRY glGetVertexAttribPointerv (GLuint, GLenum, GLvoid* *); +GLAPI GLboolean APIENTRY glIsProgram (GLuint); +GLAPI GLboolean APIENTRY glIsShader (GLuint); +GLAPI void APIENTRY glLinkProgram (GLuint); +GLAPI void APIENTRY glShaderSource (GLuint, GLsizei, const GLchar* *, const GLint *); +GLAPI void APIENTRY glUseProgram (GLuint); +GLAPI void APIENTRY glUniform1f (GLint, GLfloat); +GLAPI void APIENTRY glUniform2f (GLint, GLfloat, GLfloat); +GLAPI void APIENTRY glUniform3f (GLint, GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glUniform4f (GLint, GLfloat, GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glUniform1i (GLint, GLint); +GLAPI void APIENTRY glUniform2i (GLint, GLint, GLint); +GLAPI void APIENTRY glUniform3i (GLint, GLint, GLint, GLint); +GLAPI void APIENTRY glUniform4i (GLint, GLint, GLint, GLint, GLint); +GLAPI void APIENTRY glUniform1fv (GLint, GLsizei, const GLfloat *); +GLAPI void APIENTRY glUniform2fv (GLint, GLsizei, const GLfloat *); +GLAPI void APIENTRY glUniform3fv (GLint, GLsizei, const GLfloat *); +GLAPI void APIENTRY glUniform4fv (GLint, GLsizei, const GLfloat *); +GLAPI void APIENTRY glUniform1iv (GLint, GLsizei, const GLint *); +GLAPI void APIENTRY glUniform2iv (GLint, GLsizei, const GLint *); +GLAPI void APIENTRY glUniform3iv (GLint, GLsizei, const GLint *); +GLAPI void APIENTRY glUniform4iv (GLint, GLsizei, const GLint *); +GLAPI void APIENTRY glUniformMatrix2fv (GLint, GLsizei, GLboolean, const GLfloat *); +GLAPI void APIENTRY glUniformMatrix3fv (GLint, GLsizei, GLboolean, const GLfloat *); +GLAPI void APIENTRY glUniformMatrix4fv (GLint, GLsizei, GLboolean, const GLfloat *); +GLAPI void APIENTRY glValidateProgram (GLuint); +GLAPI void APIENTRY glVertexAttrib1d (GLuint, GLdouble); +GLAPI void APIENTRY glVertexAttrib1dv (GLuint, const GLdouble *); +GLAPI void APIENTRY glVertexAttrib1f (GLuint, GLfloat); +GLAPI void APIENTRY glVertexAttrib1fv (GLuint, const GLfloat *); +GLAPI void APIENTRY glVertexAttrib1s (GLuint, GLshort); +GLAPI void APIENTRY glVertexAttrib1sv (GLuint, const GLshort *); +GLAPI void APIENTRY glVertexAttrib2d (GLuint, GLdouble, GLdouble); +GLAPI void APIENTRY glVertexAttrib2dv (GLuint, const GLdouble *); +GLAPI void APIENTRY glVertexAttrib2f (GLuint, GLfloat, GLfloat); +GLAPI void APIENTRY glVertexAttrib2fv (GLuint, const GLfloat *); +GLAPI void APIENTRY glVertexAttrib2s (GLuint, GLshort, GLshort); +GLAPI void APIENTRY glVertexAttrib2sv (GLuint, const GLshort *); +GLAPI void APIENTRY glVertexAttrib3d (GLuint, GLdouble, GLdouble, GLdouble); +GLAPI void APIENTRY glVertexAttrib3dv (GLuint, const GLdouble *); +GLAPI void APIENTRY glVertexAttrib3f (GLuint, GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glVertexAttrib3fv (GLuint, const GLfloat *); +GLAPI void APIENTRY glVertexAttrib3s (GLuint, GLshort, GLshort, GLshort); +GLAPI void APIENTRY glVertexAttrib3sv (GLuint, const GLshort *); +GLAPI void APIENTRY glVertexAttrib4Nbv (GLuint, const GLbyte *); +GLAPI void APIENTRY glVertexAttrib4Niv (GLuint, const GLint *); +GLAPI void APIENTRY glVertexAttrib4Nsv (GLuint, const GLshort *); +GLAPI void APIENTRY glVertexAttrib4Nub (GLuint, GLubyte, GLubyte, GLubyte, GLubyte); +GLAPI void APIENTRY glVertexAttrib4Nubv (GLuint, const GLubyte *); +GLAPI void APIENTRY glVertexAttrib4Nuiv (GLuint, const GLuint *); +GLAPI void APIENTRY glVertexAttrib4Nusv (GLuint, const GLushort *); +GLAPI void APIENTRY glVertexAttrib4bv (GLuint, const GLbyte *); +GLAPI void APIENTRY glVertexAttrib4d (GLuint, GLdouble, GLdouble, GLdouble, GLdouble); +GLAPI void APIENTRY glVertexAttrib4dv (GLuint, const GLdouble *); +GLAPI void APIENTRY glVertexAttrib4f (GLuint, GLfloat, GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glVertexAttrib4fv (GLuint, const GLfloat *); +GLAPI void APIENTRY glVertexAttrib4iv (GLuint, const GLint *); +GLAPI void APIENTRY glVertexAttrib4s (GLuint, GLshort, GLshort, GLshort, GLshort); +GLAPI void APIENTRY glVertexAttrib4sv (GLuint, const GLshort *); +GLAPI void APIENTRY glVertexAttrib4ubv (GLuint, const GLubyte *); +GLAPI void APIENTRY glVertexAttrib4uiv (GLuint, const GLuint *); +GLAPI void APIENTRY glVertexAttrib4usv (GLuint, const GLushort *); +GLAPI void APIENTRY glVertexAttribPointer (GLuint, GLint, GLenum, GLboolean, GLsizei, const GLvoid *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLBLENDEQUATIONSEPARATEPROC) (GLenum modeRGB, GLenum modeAlpha); +typedef void (APIENTRYP PFNGLDRAWBUFFERSPROC) (GLsizei n, const GLenum *bufs); +typedef void (APIENTRYP PFNGLSTENCILOPSEPARATEPROC) (GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass); +typedef void (APIENTRYP PFNGLSTENCILFUNCSEPARATEPROC) (GLenum frontfunc, GLenum backfunc, GLint ref, GLuint mask); +typedef void (APIENTRYP PFNGLSTENCILMASKSEPARATEPROC) (GLenum face, GLuint mask); +typedef void (APIENTRYP PFNGLATTACHSHADERPROC) (GLuint program, GLuint shader); +typedef void (APIENTRYP PFNGLBINDATTRIBLOCATIONPROC) (GLuint program, GLuint index, const GLchar *name); +typedef void (APIENTRYP PFNGLCOMPILESHADERPROC) (GLuint shader); +typedef GLuint (APIENTRYP PFNGLCREATEPROGRAMPROC) (void); +typedef GLuint (APIENTRYP PFNGLCREATESHADERPROC) (GLenum type); +typedef void (APIENTRYP PFNGLDELETEPROGRAMPROC) (GLuint program); +typedef void (APIENTRYP PFNGLDELETESHADERPROC) (GLuint shader); +typedef void (APIENTRYP PFNGLDETACHSHADERPROC) (GLuint program, GLuint shader); +typedef void (APIENTRYP PFNGLDISABLEVERTEXATTRIBARRAYPROC) (GLuint index); +typedef void (APIENTRYP PFNGLENABLEVERTEXATTRIBARRAYPROC) (GLuint index); +typedef void (APIENTRYP PFNGLGETACTIVEATTRIBPROC) (GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name); +typedef void (APIENTRYP PFNGLGETACTIVEUNIFORMPROC) (GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name); +typedef void (APIENTRYP PFNGLGETATTACHEDSHADERSPROC) (GLuint program, GLsizei maxCount, GLsizei *count, GLuint *obj); +typedef GLint (APIENTRYP PFNGLGETATTRIBLOCATIONPROC) (GLuint program, const GLchar *name); +typedef void (APIENTRYP PFNGLGETPROGRAMIVPROC) (GLuint program, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLGETPROGRAMINFOLOGPROC) (GLuint program, GLsizei bufSize, GLsizei *length, GLchar *infoLog); +typedef void (APIENTRYP PFNGLGETSHADERIVPROC) (GLuint shader, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLGETSHADERINFOLOGPROC) (GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *infoLog); +typedef void (APIENTRYP PFNGLGETSHADERSOURCEPROC) (GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *source); +typedef GLint (APIENTRYP PFNGLGETUNIFORMLOCATIONPROC) (GLuint program, const GLchar *name); +typedef void (APIENTRYP PFNGLGETUNIFORMFVPROC) (GLuint program, GLint location, GLfloat *params); +typedef void (APIENTRYP PFNGLGETUNIFORMIVPROC) (GLuint program, GLint location, GLint *params); +typedef void (APIENTRYP PFNGLGETVERTEXATTRIBDVPROC) (GLuint index, GLenum pname, GLdouble *params); +typedef void (APIENTRYP PFNGLGETVERTEXATTRIBFVPROC) (GLuint index, GLenum pname, GLfloat *params); +typedef void (APIENTRYP PFNGLGETVERTEXATTRIBIVPROC) (GLuint index, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLGETVERTEXATTRIBPOINTERVPROC) (GLuint index, GLenum pname, GLvoid* *pointer); +typedef GLboolean (APIENTRYP PFNGLISPROGRAMPROC) (GLuint program); +typedef GLboolean (APIENTRYP PFNGLISSHADERPROC) (GLuint shader); +typedef void (APIENTRYP PFNGLLINKPROGRAMPROC) (GLuint program); +typedef void (APIENTRYP PFNGLSHADERSOURCEPROC) (GLuint shader, GLsizei count, const GLchar* *string, const GLint *length); +typedef void (APIENTRYP PFNGLUSEPROGRAMPROC) (GLuint program); +typedef void (APIENTRYP PFNGLUNIFORM1FPROC) (GLint location, GLfloat v0); +typedef void (APIENTRYP PFNGLUNIFORM2FPROC) (GLint location, GLfloat v0, GLfloat v1); +typedef void (APIENTRYP PFNGLUNIFORM3FPROC) (GLint location, GLfloat v0, GLfloat v1, GLfloat v2); +typedef void (APIENTRYP PFNGLUNIFORM4FPROC) (GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3); +typedef void (APIENTRYP PFNGLUNIFORM1IPROC) (GLint location, GLint v0); +typedef void (APIENTRYP PFNGLUNIFORM2IPROC) (GLint location, GLint v0, GLint v1); +typedef void (APIENTRYP PFNGLUNIFORM3IPROC) (GLint location, GLint v0, GLint v1, GLint v2); +typedef void (APIENTRYP PFNGLUNIFORM4IPROC) (GLint location, GLint v0, GLint v1, GLint v2, GLint v3); +typedef void (APIENTRYP PFNGLUNIFORM1FVPROC) (GLint location, GLsizei count, const GLfloat *value); +typedef void (APIENTRYP PFNGLUNIFORM2FVPROC) (GLint location, GLsizei count, const GLfloat *value); +typedef void (APIENTRYP PFNGLUNIFORM3FVPROC) (GLint location, GLsizei count, const GLfloat *value); +typedef void (APIENTRYP PFNGLUNIFORM4FVPROC) (GLint location, GLsizei count, const GLfloat *value); +typedef void (APIENTRYP PFNGLUNIFORM1IVPROC) (GLint location, GLsizei count, const GLint *value); +typedef void (APIENTRYP PFNGLUNIFORM2IVPROC) (GLint location, GLsizei count, const GLint *value); +typedef void (APIENTRYP PFNGLUNIFORM3IVPROC) (GLint location, GLsizei count, const GLint *value); +typedef void (APIENTRYP PFNGLUNIFORM4IVPROC) (GLint location, GLsizei count, const GLint *value); +typedef void (APIENTRYP PFNGLUNIFORMMATRIX2FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (APIENTRYP PFNGLUNIFORMMATRIX3FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (APIENTRYP PFNGLUNIFORMMATRIX4FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (APIENTRYP PFNGLVALIDATEPROGRAMPROC) (GLuint program); +typedef void (APIENTRYP PFNGLVERTEXATTRIB1DPROC) (GLuint index, GLdouble x); +typedef void (APIENTRYP PFNGLVERTEXATTRIB1DVPROC) (GLuint index, const GLdouble *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB1FPROC) (GLuint index, GLfloat x); +typedef void (APIENTRYP PFNGLVERTEXATTRIB1FVPROC) (GLuint index, const GLfloat *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB1SPROC) (GLuint index, GLshort x); +typedef void (APIENTRYP PFNGLVERTEXATTRIB1SVPROC) (GLuint index, const GLshort *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB2DPROC) (GLuint index, GLdouble x, GLdouble y); +typedef void (APIENTRYP PFNGLVERTEXATTRIB2DVPROC) (GLuint index, const GLdouble *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB2FPROC) (GLuint index, GLfloat x, GLfloat y); +typedef void (APIENTRYP PFNGLVERTEXATTRIB2FVPROC) (GLuint index, const GLfloat *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB2SPROC) (GLuint index, GLshort x, GLshort y); +typedef void (APIENTRYP PFNGLVERTEXATTRIB2SVPROC) (GLuint index, const GLshort *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB3DPROC) (GLuint index, GLdouble x, GLdouble y, GLdouble z); +typedef void (APIENTRYP PFNGLVERTEXATTRIB3DVPROC) (GLuint index, const GLdouble *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB3FPROC) (GLuint index, GLfloat x, GLfloat y, GLfloat z); +typedef void (APIENTRYP PFNGLVERTEXATTRIB3FVPROC) (GLuint index, const GLfloat *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB3SPROC) (GLuint index, GLshort x, GLshort y, GLshort z); +typedef void (APIENTRYP PFNGLVERTEXATTRIB3SVPROC) (GLuint index, const GLshort *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB4NBVPROC) (GLuint index, const GLbyte *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB4NIVPROC) (GLuint index, const GLint *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB4NSVPROC) (GLuint index, const GLshort *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB4NUBPROC) (GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w); +typedef void (APIENTRYP PFNGLVERTEXATTRIB4NUBVPROC) (GLuint index, const GLubyte *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB4NUIVPROC) (GLuint index, const GLuint *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB4NUSVPROC) (GLuint index, const GLushort *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB4BVPROC) (GLuint index, const GLbyte *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB4DPROC) (GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w); +typedef void (APIENTRYP PFNGLVERTEXATTRIB4DVPROC) (GLuint index, const GLdouble *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB4FPROC) (GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w); +typedef void (APIENTRYP PFNGLVERTEXATTRIB4FVPROC) (GLuint index, const GLfloat *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB4IVPROC) (GLuint index, const GLint *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB4SPROC) (GLuint index, GLshort x, GLshort y, GLshort z, GLshort w); +typedef void (APIENTRYP PFNGLVERTEXATTRIB4SVPROC) (GLuint index, const GLshort *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB4UBVPROC) (GLuint index, const GLubyte *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB4UIVPROC) (GLuint index, const GLuint *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB4USVPROC) (GLuint index, const GLushort *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIBPOINTERPROC) (GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const GLvoid *pointer); +#endif + +#ifndef GL_VERSION_2_1 +#define GL_VERSION_2_1 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glUniformMatrix2x3fv (GLint, GLsizei, GLboolean, const GLfloat *); +GLAPI void APIENTRY glUniformMatrix3x2fv (GLint, GLsizei, GLboolean, const GLfloat *); +GLAPI void APIENTRY glUniformMatrix2x4fv (GLint, GLsizei, GLboolean, const GLfloat *); +GLAPI void APIENTRY glUniformMatrix4x2fv (GLint, GLsizei, GLboolean, const GLfloat *); +GLAPI void APIENTRY glUniformMatrix3x4fv (GLint, GLsizei, GLboolean, const GLfloat *); +GLAPI void APIENTRY glUniformMatrix4x3fv (GLint, GLsizei, GLboolean, const GLfloat *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLUNIFORMMATRIX2X3FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (APIENTRYP PFNGLUNIFORMMATRIX3X2FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (APIENTRYP PFNGLUNIFORMMATRIX2X4FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (APIENTRYP PFNGLUNIFORMMATRIX4X2FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (APIENTRYP PFNGLUNIFORMMATRIX3X4FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (APIENTRYP PFNGLUNIFORMMATRIX4X3FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +#endif + +#ifndef GL_VERSION_3_0 +#define GL_VERSION_3_0 1 +/* OpenGL 3.0 also reuses entry points from these extensions: */ +/* ARB_framebuffer_object */ +/* ARB_map_buffer_range */ +/* ARB_vertex_array_object */ +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glColorMaski (GLuint, GLboolean, GLboolean, GLboolean, GLboolean); +GLAPI void APIENTRY glGetBooleani_v (GLenum, GLuint, GLboolean *); +GLAPI void APIENTRY glGetIntegeri_v (GLenum, GLuint, GLint *); +GLAPI void APIENTRY glEnablei (GLenum, GLuint); +GLAPI void APIENTRY glDisablei (GLenum, GLuint); +GLAPI GLboolean APIENTRY glIsEnabledi (GLenum, GLuint); +GLAPI void APIENTRY glBeginTransformFeedback (GLenum); +GLAPI void APIENTRY glEndTransformFeedback (void); +GLAPI void APIENTRY glBindBufferRange (GLenum, GLuint, GLuint, GLintptr, GLsizeiptr); +GLAPI void APIENTRY glBindBufferBase (GLenum, GLuint, GLuint); +GLAPI void APIENTRY glTransformFeedbackVaryings (GLuint, GLsizei, const GLint *, GLenum); +GLAPI void APIENTRY glGetTransformFeedbackVarying (GLuint, GLuint, GLint *); +GLAPI void APIENTRY glClampColor (GLenum, GLenum); +GLAPI void APIENTRY glBeginConditionalRender (GLuint, GLenum); +GLAPI void APIENTRY glEndConditionalRender (void); +GLAPI void APIENTRY glVertexAttribI1i (GLuint, GLint); +GLAPI void APIENTRY glVertexAttribI2i (GLuint, GLint, GLint); +GLAPI void APIENTRY glVertexAttribI3i (GLuint, GLint, GLint, GLint); +GLAPI void APIENTRY glVertexAttribI4i (GLuint, GLint, GLint, GLint, GLint); +GLAPI void APIENTRY glVertexAttribI1ui (GLuint, GLuint); +GLAPI void APIENTRY glVertexAttribI2ui (GLuint, GLuint, GLuint); +GLAPI void APIENTRY glVertexAttribI3ui (GLuint, GLuint, GLuint, GLuint); +GLAPI void APIENTRY glVertexAttribI4ui (GLuint, GLuint, GLuint, GLuint, GLuint); +GLAPI void APIENTRY glVertexAttribI1iv (GLuint, const GLint *); +GLAPI void APIENTRY glVertexAttribI2iv (GLuint, const GLint *); +GLAPI void APIENTRY glVertexAttribI3iv (GLuint, const GLint *); +GLAPI void APIENTRY glVertexAttribI4iv (GLuint, const GLint *); +GLAPI void APIENTRY glVertexAttribI1uiv (GLuint, const GLuint *); +GLAPI void APIENTRY glVertexAttribI2uiv (GLuint, const GLuint *); +GLAPI void APIENTRY glVertexAttribI3uiv (GLuint, const GLuint *); +GLAPI void APIENTRY glVertexAttribI4uiv (GLuint, const GLuint *); +GLAPI void APIENTRY glVertexAttribI4bv (GLuint, const GLbyte *); +GLAPI void APIENTRY glVertexAttribI4sv (GLuint, const GLshort *); +GLAPI void APIENTRY glVertexAttribI4ubv (GLuint, const GLubyte *); +GLAPI void APIENTRY glVertexAttribI4usv (GLuint, const GLushort *); +GLAPI void APIENTRY glVertexAttribIPointer (GLuint, GLint, GLenum, GLsizei, const GLvoid *); +GLAPI void APIENTRY glGetVertexAttribIiv (GLuint, GLenum, GLint *); +GLAPI void APIENTRY glGetVertexAttribIuiv (GLuint, GLenum, GLuint *); +GLAPI void APIENTRY glGetUniformuiv (GLuint, GLint, GLuint *); +GLAPI void APIENTRY glBindFragDataLocation (GLuint, GLuint, const GLchar *); +GLAPI GLint APIENTRY glGetFragDataLocation (GLuint, const GLchar *); +GLAPI void APIENTRY glUniform1ui (GLint, GLuint); +GLAPI void APIENTRY glUniform2ui (GLint, GLuint, GLuint); +GLAPI void APIENTRY glUniform3ui (GLint, GLuint, GLuint, GLuint); +GLAPI void APIENTRY glUniform4ui (GLint, GLuint, GLuint, GLuint, GLuint); +GLAPI void APIENTRY glUniform1uiv (GLint, GLsizei, const GLuint *); +GLAPI void APIENTRY glUniform2uiv (GLint, GLsizei, const GLuint *); +GLAPI void APIENTRY glUniform3uiv (GLint, GLsizei, const GLuint *); +GLAPI void APIENTRY glUniform4uiv (GLint, GLsizei, const GLuint *); +GLAPI void APIENTRY glTexParameterIiv (GLenum, GLenum, const GLint *); +GLAPI void APIENTRY glTexParameterIuiv (GLenum, GLenum, const GLuint *); +GLAPI void APIENTRY glGetTexParameterIiv (GLenum, GLenum, GLint *); +GLAPI void APIENTRY glGetTexParameterIuiv (GLenum, GLenum, GLuint *); +GLAPI void APIENTRY glClearBufferiv (GLenum, GLint, const GLint *); +GLAPI void APIENTRY glClearBufferuiv (GLenum, GLint, const GLuint *); +GLAPI void APIENTRY glClearBufferfv (GLenum, GLint, const GLfloat *); +GLAPI void APIENTRY glClearBufferfi (GLenum, GLint, GLfloat, GLint); +GLAPI const GLubyte * APIENTRY glGetStringi (GLenum, GLuint); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLCOLORMASKIPROC) (GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a); +typedef void (APIENTRYP PFNGLGETBOOLEANI_VPROC) (GLenum target, GLuint index, GLboolean *data); +typedef void (APIENTRYP PFNGLGETINTEGERI_VPROC) (GLenum target, GLuint index, GLint *data); +typedef void (APIENTRYP PFNGLENABLEIPROC) (GLenum target, GLuint index); +typedef void (APIENTRYP PFNGLDISABLEIPROC) (GLenum target, GLuint index); +typedef GLboolean (APIENTRYP PFNGLISENABLEDIPROC) (GLenum target, GLuint index); +typedef void (APIENTRYP PFNGLBEGINTRANSFORMFEEDBACKPROC) (GLenum primitiveMode); +typedef void (APIENTRYP PFNGLENDTRANSFORMFEEDBACKPROC) (void); +typedef void (APIENTRYP PFNGLBINDBUFFERRANGEPROC) (GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size); +typedef void (APIENTRYP PFNGLBINDBUFFERBASEPROC) (GLenum target, GLuint index, GLuint buffer); +typedef void (APIENTRYP PFNGLTRANSFORMFEEDBACKVARYINGSPROC) (GLuint program, GLsizei count, const GLint *locations, GLenum bufferMode); +typedef void (APIENTRYP PFNGLGETTRANSFORMFEEDBACKVARYINGPROC) (GLuint program, GLuint index, GLint *location); +typedef void (APIENTRYP PFNGLCLAMPCOLORPROC) (GLenum target, GLenum clamp); +typedef void (APIENTRYP PFNGLBEGINCONDITIONALRENDERPROC) (GLuint id, GLenum mode); +typedef void (APIENTRYP PFNGLENDCONDITIONALRENDERPROC) (void); +typedef void (APIENTRYP PFNGLVERTEXATTRIBI1IPROC) (GLuint index, GLint x); +typedef void (APIENTRYP PFNGLVERTEXATTRIBI2IPROC) (GLuint index, GLint x, GLint y); +typedef void (APIENTRYP PFNGLVERTEXATTRIBI3IPROC) (GLuint index, GLint x, GLint y, GLint z); +typedef void (APIENTRYP PFNGLVERTEXATTRIBI4IPROC) (GLuint index, GLint x, GLint y, GLint z, GLint w); +typedef void (APIENTRYP PFNGLVERTEXATTRIBI1UIPROC) (GLuint index, GLuint x); +typedef void (APIENTRYP PFNGLVERTEXATTRIBI2UIPROC) (GLuint index, GLuint x, GLuint y); +typedef void (APIENTRYP PFNGLVERTEXATTRIBI3UIPROC) (GLuint index, GLuint x, GLuint y, GLuint z); +typedef void (APIENTRYP PFNGLVERTEXATTRIBI4UIPROC) (GLuint index, GLuint x, GLuint y, GLuint z, GLuint w); +typedef void (APIENTRYP PFNGLVERTEXATTRIBI1IVPROC) (GLuint index, const GLint *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIBI2IVPROC) (GLuint index, const GLint *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIBI3IVPROC) (GLuint index, const GLint *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIBI4IVPROC) (GLuint index, const GLint *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIBI1UIVPROC) (GLuint index, const GLuint *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIBI2UIVPROC) (GLuint index, const GLuint *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIBI3UIVPROC) (GLuint index, const GLuint *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIBI4UIVPROC) (GLuint index, const GLuint *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIBI4BVPROC) (GLuint index, const GLbyte *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIBI4SVPROC) (GLuint index, const GLshort *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIBI4UBVPROC) (GLuint index, const GLubyte *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIBI4USVPROC) (GLuint index, const GLushort *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIBIPOINTERPROC) (GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer); +typedef void (APIENTRYP PFNGLGETVERTEXATTRIBIIVPROC) (GLuint index, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLGETVERTEXATTRIBIUIVPROC) (GLuint index, GLenum pname, GLuint *params); +typedef void (APIENTRYP PFNGLGETUNIFORMUIVPROC) (GLuint program, GLint location, GLuint *params); +typedef void (APIENTRYP PFNGLBINDFRAGDATALOCATIONPROC) (GLuint program, GLuint color, const GLchar *name); +typedef GLint (APIENTRYP PFNGLGETFRAGDATALOCATIONPROC) (GLuint program, const GLchar *name); +typedef void (APIENTRYP PFNGLUNIFORM1UIPROC) (GLint location, GLuint v0); +typedef void (APIENTRYP PFNGLUNIFORM2UIPROC) (GLint location, GLuint v0, GLuint v1); +typedef void (APIENTRYP PFNGLUNIFORM3UIPROC) (GLint location, GLuint v0, GLuint v1, GLuint v2); +typedef void (APIENTRYP PFNGLUNIFORM4UIPROC) (GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3); +typedef void (APIENTRYP PFNGLUNIFORM1UIVPROC) (GLint location, GLsizei count, const GLuint *value); +typedef void (APIENTRYP PFNGLUNIFORM2UIVPROC) (GLint location, GLsizei count, const GLuint *value); +typedef void (APIENTRYP PFNGLUNIFORM3UIVPROC) (GLint location, GLsizei count, const GLuint *value); +typedef void (APIENTRYP PFNGLUNIFORM4UIVPROC) (GLint location, GLsizei count, const GLuint *value); +typedef void (APIENTRYP PFNGLTEXPARAMETERIIVPROC) (GLenum target, GLenum pname, const GLint *params); +typedef void (APIENTRYP PFNGLTEXPARAMETERIUIVPROC) (GLenum target, GLenum pname, const GLuint *params); +typedef void (APIENTRYP PFNGLGETTEXPARAMETERIIVPROC) (GLenum target, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLGETTEXPARAMETERIUIVPROC) (GLenum target, GLenum pname, GLuint *params); +typedef void (APIENTRYP PFNGLCLEARBUFFERIVPROC) (GLenum buffer, GLint drawbuffer, const GLint *value); +typedef void (APIENTRYP PFNGLCLEARBUFFERUIVPROC) (GLenum buffer, GLint drawbuffer, const GLuint *value); +typedef void (APIENTRYP PFNGLCLEARBUFFERFVPROC) (GLenum buffer, GLint drawbuffer, const GLfloat *value); +typedef void (APIENTRYP PFNGLCLEARBUFFERFIPROC) (GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil); +typedef const GLubyte * (APIENTRYP PFNGLGETSTRINGIPROC) (GLenum name, GLuint index); +#endif + +#ifndef GL_ARB_multitexture +#define GL_ARB_multitexture 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glActiveTextureARB (GLenum); +GLAPI void APIENTRY glClientActiveTextureARB (GLenum); +GLAPI void APIENTRY glMultiTexCoord1dARB (GLenum, GLdouble); +GLAPI void APIENTRY glMultiTexCoord1dvARB (GLenum, const GLdouble *); +GLAPI void APIENTRY glMultiTexCoord1fARB (GLenum, GLfloat); +GLAPI void APIENTRY glMultiTexCoord1fvARB (GLenum, const GLfloat *); +GLAPI void APIENTRY glMultiTexCoord1iARB (GLenum, GLint); +GLAPI void APIENTRY glMultiTexCoord1ivARB (GLenum, const GLint *); +GLAPI void APIENTRY glMultiTexCoord1sARB (GLenum, GLshort); +GLAPI void APIENTRY glMultiTexCoord1svARB (GLenum, const GLshort *); +GLAPI void APIENTRY glMultiTexCoord2dARB (GLenum, GLdouble, GLdouble); +GLAPI void APIENTRY glMultiTexCoord2dvARB (GLenum, const GLdouble *); +GLAPI void APIENTRY glMultiTexCoord2fARB (GLenum, GLfloat, GLfloat); +GLAPI void APIENTRY glMultiTexCoord2fvARB (GLenum, const GLfloat *); +GLAPI void APIENTRY glMultiTexCoord2iARB (GLenum, GLint, GLint); +GLAPI void APIENTRY glMultiTexCoord2ivARB (GLenum, const GLint *); +GLAPI void APIENTRY glMultiTexCoord2sARB (GLenum, GLshort, GLshort); +GLAPI void APIENTRY glMultiTexCoord2svARB (GLenum, const GLshort *); +GLAPI void APIENTRY glMultiTexCoord3dARB (GLenum, GLdouble, GLdouble, GLdouble); +GLAPI void APIENTRY glMultiTexCoord3dvARB (GLenum, const GLdouble *); +GLAPI void APIENTRY glMultiTexCoord3fARB (GLenum, GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glMultiTexCoord3fvARB (GLenum, const GLfloat *); +GLAPI void APIENTRY glMultiTexCoord3iARB (GLenum, GLint, GLint, GLint); +GLAPI void APIENTRY glMultiTexCoord3ivARB (GLenum, const GLint *); +GLAPI void APIENTRY glMultiTexCoord3sARB (GLenum, GLshort, GLshort, GLshort); +GLAPI void APIENTRY glMultiTexCoord3svARB (GLenum, const GLshort *); +GLAPI void APIENTRY glMultiTexCoord4dARB (GLenum, GLdouble, GLdouble, GLdouble, GLdouble); +GLAPI void APIENTRY glMultiTexCoord4dvARB (GLenum, const GLdouble *); +GLAPI void APIENTRY glMultiTexCoord4fARB (GLenum, GLfloat, GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glMultiTexCoord4fvARB (GLenum, const GLfloat *); +GLAPI void APIENTRY glMultiTexCoord4iARB (GLenum, GLint, GLint, GLint, GLint); +GLAPI void APIENTRY glMultiTexCoord4ivARB (GLenum, const GLint *); +GLAPI void APIENTRY glMultiTexCoord4sARB (GLenum, GLshort, GLshort, GLshort, GLshort); +GLAPI void APIENTRY glMultiTexCoord4svARB (GLenum, const GLshort *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLACTIVETEXTUREARBPROC) (GLenum texture); +typedef void (APIENTRYP PFNGLCLIENTACTIVETEXTUREARBPROC) (GLenum texture); +typedef void (APIENTRYP PFNGLMULTITEXCOORD1DARBPROC) (GLenum target, GLdouble s); +typedef void (APIENTRYP PFNGLMULTITEXCOORD1DVARBPROC) (GLenum target, const GLdouble *v); +typedef void (APIENTRYP PFNGLMULTITEXCOORD1FARBPROC) (GLenum target, GLfloat s); +typedef void (APIENTRYP PFNGLMULTITEXCOORD1FVARBPROC) (GLenum target, const GLfloat *v); +typedef void (APIENTRYP PFNGLMULTITEXCOORD1IARBPROC) (GLenum target, GLint s); +typedef void (APIENTRYP PFNGLMULTITEXCOORD1IVARBPROC) (GLenum target, const GLint *v); +typedef void (APIENTRYP PFNGLMULTITEXCOORD1SARBPROC) (GLenum target, GLshort s); +typedef void (APIENTRYP PFNGLMULTITEXCOORD1SVARBPROC) (GLenum target, const GLshort *v); +typedef void (APIENTRYP PFNGLMULTITEXCOORD2DARBPROC) (GLenum target, GLdouble s, GLdouble t); +typedef void (APIENTRYP PFNGLMULTITEXCOORD2DVARBPROC) (GLenum target, const GLdouble *v); +typedef void (APIENTRYP PFNGLMULTITEXCOORD2FARBPROC) (GLenum target, GLfloat s, GLfloat t); +typedef void (APIENTRYP PFNGLMULTITEXCOORD2FVARBPROC) (GLenum target, const GLfloat *v); +typedef void (APIENTRYP PFNGLMULTITEXCOORD2IARBPROC) (GLenum target, GLint s, GLint t); +typedef void (APIENTRYP PFNGLMULTITEXCOORD2IVARBPROC) (GLenum target, const GLint *v); +typedef void (APIENTRYP PFNGLMULTITEXCOORD2SARBPROC) (GLenum target, GLshort s, GLshort t); +typedef void (APIENTRYP PFNGLMULTITEXCOORD2SVARBPROC) (GLenum target, const GLshort *v); +typedef void (APIENTRYP PFNGLMULTITEXCOORD3DARBPROC) (GLenum target, GLdouble s, GLdouble t, GLdouble r); +typedef void (APIENTRYP PFNGLMULTITEXCOORD3DVARBPROC) (GLenum target, const GLdouble *v); +typedef void (APIENTRYP PFNGLMULTITEXCOORD3FARBPROC) (GLenum target, GLfloat s, GLfloat t, GLfloat r); +typedef void (APIENTRYP PFNGLMULTITEXCOORD3FVARBPROC) (GLenum target, const GLfloat *v); +typedef void (APIENTRYP PFNGLMULTITEXCOORD3IARBPROC) (GLenum target, GLint s, GLint t, GLint r); +typedef void (APIENTRYP PFNGLMULTITEXCOORD3IVARBPROC) (GLenum target, const GLint *v); +typedef void (APIENTRYP PFNGLMULTITEXCOORD3SARBPROC) (GLenum target, GLshort s, GLshort t, GLshort r); +typedef void (APIENTRYP PFNGLMULTITEXCOORD3SVARBPROC) (GLenum target, const GLshort *v); +typedef void (APIENTRYP PFNGLMULTITEXCOORD4DARBPROC) (GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q); +typedef void (APIENTRYP PFNGLMULTITEXCOORD4DVARBPROC) (GLenum target, const GLdouble *v); +typedef void (APIENTRYP PFNGLMULTITEXCOORD4FARBPROC) (GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q); +typedef void (APIENTRYP PFNGLMULTITEXCOORD4FVARBPROC) (GLenum target, const GLfloat *v); +typedef void (APIENTRYP PFNGLMULTITEXCOORD4IARBPROC) (GLenum target, GLint s, GLint t, GLint r, GLint q); +typedef void (APIENTRYP PFNGLMULTITEXCOORD4IVARBPROC) (GLenum target, const GLint *v); +typedef void (APIENTRYP PFNGLMULTITEXCOORD4SARBPROC) (GLenum target, GLshort s, GLshort t, GLshort r, GLshort q); +typedef void (APIENTRYP PFNGLMULTITEXCOORD4SVARBPROC) (GLenum target, const GLshort *v); +#endif + +#ifndef GL_ARB_transpose_matrix +#define GL_ARB_transpose_matrix 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glLoadTransposeMatrixfARB (const GLfloat *); +GLAPI void APIENTRY glLoadTransposeMatrixdARB (const GLdouble *); +GLAPI void APIENTRY glMultTransposeMatrixfARB (const GLfloat *); +GLAPI void APIENTRY glMultTransposeMatrixdARB (const GLdouble *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLLOADTRANSPOSEMATRIXFARBPROC) (const GLfloat *m); +typedef void (APIENTRYP PFNGLLOADTRANSPOSEMATRIXDARBPROC) (const GLdouble *m); +typedef void (APIENTRYP PFNGLMULTTRANSPOSEMATRIXFARBPROC) (const GLfloat *m); +typedef void (APIENTRYP PFNGLMULTTRANSPOSEMATRIXDARBPROC) (const GLdouble *m); +#endif + +#ifndef GL_ARB_multisample +#define GL_ARB_multisample 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glSampleCoverageARB (GLclampf, GLboolean); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLSAMPLECOVERAGEARBPROC) (GLclampf value, GLboolean invert); +#endif + +#ifndef GL_ARB_texture_env_add +#define GL_ARB_texture_env_add 1 +#endif + +#ifndef GL_ARB_texture_cube_map +#define GL_ARB_texture_cube_map 1 +#endif + +#ifndef GL_ARB_texture_compression +#define GL_ARB_texture_compression 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glCompressedTexImage3DARB (GLenum, GLint, GLenum, GLsizei, GLsizei, GLsizei, GLint, GLsizei, const GLvoid *); +GLAPI void APIENTRY glCompressedTexImage2DARB (GLenum, GLint, GLenum, GLsizei, GLsizei, GLint, GLsizei, const GLvoid *); +GLAPI void APIENTRY glCompressedTexImage1DARB (GLenum, GLint, GLenum, GLsizei, GLint, GLsizei, const GLvoid *); +GLAPI void APIENTRY glCompressedTexSubImage3DARB (GLenum, GLint, GLint, GLint, GLint, GLsizei, GLsizei, GLsizei, GLenum, GLsizei, const GLvoid *); +GLAPI void APIENTRY glCompressedTexSubImage2DARB (GLenum, GLint, GLint, GLint, GLsizei, GLsizei, GLenum, GLsizei, const GLvoid *); +GLAPI void APIENTRY glCompressedTexSubImage1DARB (GLenum, GLint, GLint, GLsizei, GLenum, GLsizei, const GLvoid *); +GLAPI void APIENTRY glGetCompressedTexImageARB (GLenum, GLint, GLvoid *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLCOMPRESSEDTEXIMAGE3DARBPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data); +typedef void (APIENTRYP PFNGLCOMPRESSEDTEXIMAGE2DARBPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data); +typedef void (APIENTRYP PFNGLCOMPRESSEDTEXIMAGE1DARBPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data); +typedef void (APIENTRYP PFNGLCOMPRESSEDTEXSUBIMAGE3DARBPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data); +typedef void (APIENTRYP PFNGLCOMPRESSEDTEXSUBIMAGE2DARBPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data); +typedef void (APIENTRYP PFNGLCOMPRESSEDTEXSUBIMAGE1DARBPROC) (GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data); +typedef void (APIENTRYP PFNGLGETCOMPRESSEDTEXIMAGEARBPROC) (GLenum target, GLint level, GLvoid *img); +#endif + +#ifndef GL_ARB_texture_border_clamp +#define GL_ARB_texture_border_clamp 1 +#endif + +#ifndef GL_ARB_point_parameters +#define GL_ARB_point_parameters 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glPointParameterfARB (GLenum, GLfloat); +GLAPI void APIENTRY glPointParameterfvARB (GLenum, const GLfloat *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLPOINTPARAMETERFARBPROC) (GLenum pname, GLfloat param); +typedef void (APIENTRYP PFNGLPOINTPARAMETERFVARBPROC) (GLenum pname, const GLfloat *params); +#endif + +#ifndef GL_ARB_vertex_blend +#define GL_ARB_vertex_blend 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glWeightbvARB (GLint, const GLbyte *); +GLAPI void APIENTRY glWeightsvARB (GLint, const GLshort *); +GLAPI void APIENTRY glWeightivARB (GLint, const GLint *); +GLAPI void APIENTRY glWeightfvARB (GLint, const GLfloat *); +GLAPI void APIENTRY glWeightdvARB (GLint, const GLdouble *); +GLAPI void APIENTRY glWeightubvARB (GLint, const GLubyte *); +GLAPI void APIENTRY glWeightusvARB (GLint, const GLushort *); +GLAPI void APIENTRY glWeightuivARB (GLint, const GLuint *); +GLAPI void APIENTRY glWeightPointerARB (GLint, GLenum, GLsizei, const GLvoid *); +GLAPI void APIENTRY glVertexBlendARB (GLint); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLWEIGHTBVARBPROC) (GLint size, const GLbyte *weights); +typedef void (APIENTRYP PFNGLWEIGHTSVARBPROC) (GLint size, const GLshort *weights); +typedef void (APIENTRYP PFNGLWEIGHTIVARBPROC) (GLint size, const GLint *weights); +typedef void (APIENTRYP PFNGLWEIGHTFVARBPROC) (GLint size, const GLfloat *weights); +typedef void (APIENTRYP PFNGLWEIGHTDVARBPROC) (GLint size, const GLdouble *weights); +typedef void (APIENTRYP PFNGLWEIGHTUBVARBPROC) (GLint size, const GLubyte *weights); +typedef void (APIENTRYP PFNGLWEIGHTUSVARBPROC) (GLint size, const GLushort *weights); +typedef void (APIENTRYP PFNGLWEIGHTUIVARBPROC) (GLint size, const GLuint *weights); +typedef void (APIENTRYP PFNGLWEIGHTPOINTERARBPROC) (GLint size, GLenum type, GLsizei stride, const GLvoid *pointer); +typedef void (APIENTRYP PFNGLVERTEXBLENDARBPROC) (GLint count); +#endif + +#ifndef GL_ARB_matrix_palette +#define GL_ARB_matrix_palette 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glCurrentPaletteMatrixARB (GLint); +GLAPI void APIENTRY glMatrixIndexubvARB (GLint, const GLubyte *); +GLAPI void APIENTRY glMatrixIndexusvARB (GLint, const GLushort *); +GLAPI void APIENTRY glMatrixIndexuivARB (GLint, const GLuint *); +GLAPI void APIENTRY glMatrixIndexPointerARB (GLint, GLenum, GLsizei, const GLvoid *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLCURRENTPALETTEMATRIXARBPROC) (GLint index); +typedef void (APIENTRYP PFNGLMATRIXINDEXUBVARBPROC) (GLint size, const GLubyte *indices); +typedef void (APIENTRYP PFNGLMATRIXINDEXUSVARBPROC) (GLint size, const GLushort *indices); +typedef void (APIENTRYP PFNGLMATRIXINDEXUIVARBPROC) (GLint size, const GLuint *indices); +typedef void (APIENTRYP PFNGLMATRIXINDEXPOINTERARBPROC) (GLint size, GLenum type, GLsizei stride, const GLvoid *pointer); +#endif + +#ifndef GL_ARB_texture_env_combine +#define GL_ARB_texture_env_combine 1 +#endif + +#ifndef GL_ARB_texture_env_crossbar +#define GL_ARB_texture_env_crossbar 1 +#endif + +#ifndef GL_ARB_texture_env_dot3 +#define GL_ARB_texture_env_dot3 1 +#endif + +#ifndef GL_ARB_texture_mirrored_repeat +#define GL_ARB_texture_mirrored_repeat 1 +#endif + +#ifndef GL_ARB_depth_texture +#define GL_ARB_depth_texture 1 +#endif + +#ifndef GL_ARB_shadow +#define GL_ARB_shadow 1 +#endif + +#ifndef GL_ARB_shadow_ambient +#define GL_ARB_shadow_ambient 1 +#endif + +#ifndef GL_ARB_window_pos +#define GL_ARB_window_pos 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glWindowPos2dARB (GLdouble, GLdouble); +GLAPI void APIENTRY glWindowPos2dvARB (const GLdouble *); +GLAPI void APIENTRY glWindowPos2fARB (GLfloat, GLfloat); +GLAPI void APIENTRY glWindowPos2fvARB (const GLfloat *); +GLAPI void APIENTRY glWindowPos2iARB (GLint, GLint); +GLAPI void APIENTRY glWindowPos2ivARB (const GLint *); +GLAPI void APIENTRY glWindowPos2sARB (GLshort, GLshort); +GLAPI void APIENTRY glWindowPos2svARB (const GLshort *); +GLAPI void APIENTRY glWindowPos3dARB (GLdouble, GLdouble, GLdouble); +GLAPI void APIENTRY glWindowPos3dvARB (const GLdouble *); +GLAPI void APIENTRY glWindowPos3fARB (GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glWindowPos3fvARB (const GLfloat *); +GLAPI void APIENTRY glWindowPos3iARB (GLint, GLint, GLint); +GLAPI void APIENTRY glWindowPos3ivARB (const GLint *); +GLAPI void APIENTRY glWindowPos3sARB (GLshort, GLshort, GLshort); +GLAPI void APIENTRY glWindowPos3svARB (const GLshort *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLWINDOWPOS2DARBPROC) (GLdouble x, GLdouble y); +typedef void (APIENTRYP PFNGLWINDOWPOS2DVARBPROC) (const GLdouble *v); +typedef void (APIENTRYP PFNGLWINDOWPOS2FARBPROC) (GLfloat x, GLfloat y); +typedef void (APIENTRYP PFNGLWINDOWPOS2FVARBPROC) (const GLfloat *v); +typedef void (APIENTRYP PFNGLWINDOWPOS2IARBPROC) (GLint x, GLint y); +typedef void (APIENTRYP PFNGLWINDOWPOS2IVARBPROC) (const GLint *v); +typedef void (APIENTRYP PFNGLWINDOWPOS2SARBPROC) (GLshort x, GLshort y); +typedef void (APIENTRYP PFNGLWINDOWPOS2SVARBPROC) (const GLshort *v); +typedef void (APIENTRYP PFNGLWINDOWPOS3DARBPROC) (GLdouble x, GLdouble y, GLdouble z); +typedef void (APIENTRYP PFNGLWINDOWPOS3DVARBPROC) (const GLdouble *v); +typedef void (APIENTRYP PFNGLWINDOWPOS3FARBPROC) (GLfloat x, GLfloat y, GLfloat z); +typedef void (APIENTRYP PFNGLWINDOWPOS3FVARBPROC) (const GLfloat *v); +typedef void (APIENTRYP PFNGLWINDOWPOS3IARBPROC) (GLint x, GLint y, GLint z); +typedef void (APIENTRYP PFNGLWINDOWPOS3IVARBPROC) (const GLint *v); +typedef void (APIENTRYP PFNGLWINDOWPOS3SARBPROC) (GLshort x, GLshort y, GLshort z); +typedef void (APIENTRYP PFNGLWINDOWPOS3SVARBPROC) (const GLshort *v); +#endif + +#ifndef GL_ARB_vertex_program +#define GL_ARB_vertex_program 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glVertexAttrib1dARB (GLuint, GLdouble); +GLAPI void APIENTRY glVertexAttrib1dvARB (GLuint, const GLdouble *); +GLAPI void APIENTRY glVertexAttrib1fARB (GLuint, GLfloat); +GLAPI void APIENTRY glVertexAttrib1fvARB (GLuint, const GLfloat *); +GLAPI void APIENTRY glVertexAttrib1sARB (GLuint, GLshort); +GLAPI void APIENTRY glVertexAttrib1svARB (GLuint, const GLshort *); +GLAPI void APIENTRY glVertexAttrib2dARB (GLuint, GLdouble, GLdouble); +GLAPI void APIENTRY glVertexAttrib2dvARB (GLuint, const GLdouble *); +GLAPI void APIENTRY glVertexAttrib2fARB (GLuint, GLfloat, GLfloat); +GLAPI void APIENTRY glVertexAttrib2fvARB (GLuint, const GLfloat *); +GLAPI void APIENTRY glVertexAttrib2sARB (GLuint, GLshort, GLshort); +GLAPI void APIENTRY glVertexAttrib2svARB (GLuint, const GLshort *); +GLAPI void APIENTRY glVertexAttrib3dARB (GLuint, GLdouble, GLdouble, GLdouble); +GLAPI void APIENTRY glVertexAttrib3dvARB (GLuint, const GLdouble *); +GLAPI void APIENTRY glVertexAttrib3fARB (GLuint, GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glVertexAttrib3fvARB (GLuint, const GLfloat *); +GLAPI void APIENTRY glVertexAttrib3sARB (GLuint, GLshort, GLshort, GLshort); +GLAPI void APIENTRY glVertexAttrib3svARB (GLuint, const GLshort *); +GLAPI void APIENTRY glVertexAttrib4NbvARB (GLuint, const GLbyte *); +GLAPI void APIENTRY glVertexAttrib4NivARB (GLuint, const GLint *); +GLAPI void APIENTRY glVertexAttrib4NsvARB (GLuint, const GLshort *); +GLAPI void APIENTRY glVertexAttrib4NubARB (GLuint, GLubyte, GLubyte, GLubyte, GLubyte); +GLAPI void APIENTRY glVertexAttrib4NubvARB (GLuint, const GLubyte *); +GLAPI void APIENTRY glVertexAttrib4NuivARB (GLuint, const GLuint *); +GLAPI void APIENTRY glVertexAttrib4NusvARB (GLuint, const GLushort *); +GLAPI void APIENTRY glVertexAttrib4bvARB (GLuint, const GLbyte *); +GLAPI void APIENTRY glVertexAttrib4dARB (GLuint, GLdouble, GLdouble, GLdouble, GLdouble); +GLAPI void APIENTRY glVertexAttrib4dvARB (GLuint, const GLdouble *); +GLAPI void APIENTRY glVertexAttrib4fARB (GLuint, GLfloat, GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glVertexAttrib4fvARB (GLuint, const GLfloat *); +GLAPI void APIENTRY glVertexAttrib4ivARB (GLuint, const GLint *); +GLAPI void APIENTRY glVertexAttrib4sARB (GLuint, GLshort, GLshort, GLshort, GLshort); +GLAPI void APIENTRY glVertexAttrib4svARB (GLuint, const GLshort *); +GLAPI void APIENTRY glVertexAttrib4ubvARB (GLuint, const GLubyte *); +GLAPI void APIENTRY glVertexAttrib4uivARB (GLuint, const GLuint *); +GLAPI void APIENTRY glVertexAttrib4usvARB (GLuint, const GLushort *); +GLAPI void APIENTRY glVertexAttribPointerARB (GLuint, GLint, GLenum, GLboolean, GLsizei, const GLvoid *); +GLAPI void APIENTRY glEnableVertexAttribArrayARB (GLuint); +GLAPI void APIENTRY glDisableVertexAttribArrayARB (GLuint); +GLAPI void APIENTRY glProgramStringARB (GLenum, GLenum, GLsizei, const GLvoid *); +GLAPI void APIENTRY glBindProgramARB (GLenum, GLuint); +GLAPI void APIENTRY glDeleteProgramsARB (GLsizei, const GLuint *); +GLAPI void APIENTRY glGenProgramsARB (GLsizei, GLuint *); +GLAPI void APIENTRY glProgramEnvParameter4dARB (GLenum, GLuint, GLdouble, GLdouble, GLdouble, GLdouble); +GLAPI void APIENTRY glProgramEnvParameter4dvARB (GLenum, GLuint, const GLdouble *); +GLAPI void APIENTRY glProgramEnvParameter4fARB (GLenum, GLuint, GLfloat, GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glProgramEnvParameter4fvARB (GLenum, GLuint, const GLfloat *); +GLAPI void APIENTRY glProgramLocalParameter4dARB (GLenum, GLuint, GLdouble, GLdouble, GLdouble, GLdouble); +GLAPI void APIENTRY glProgramLocalParameter4dvARB (GLenum, GLuint, const GLdouble *); +GLAPI void APIENTRY glProgramLocalParameter4fARB (GLenum, GLuint, GLfloat, GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glProgramLocalParameter4fvARB (GLenum, GLuint, const GLfloat *); +GLAPI void APIENTRY glGetProgramEnvParameterdvARB (GLenum, GLuint, GLdouble *); +GLAPI void APIENTRY glGetProgramEnvParameterfvARB (GLenum, GLuint, GLfloat *); +GLAPI void APIENTRY glGetProgramLocalParameterdvARB (GLenum, GLuint, GLdouble *); +GLAPI void APIENTRY glGetProgramLocalParameterfvARB (GLenum, GLuint, GLfloat *); +GLAPI void APIENTRY glGetProgramivARB (GLenum, GLenum, GLint *); +GLAPI void APIENTRY glGetProgramStringARB (GLenum, GLenum, GLvoid *); +GLAPI void APIENTRY glGetVertexAttribdvARB (GLuint, GLenum, GLdouble *); +GLAPI void APIENTRY glGetVertexAttribfvARB (GLuint, GLenum, GLfloat *); +GLAPI void APIENTRY glGetVertexAttribivARB (GLuint, GLenum, GLint *); +GLAPI void APIENTRY glGetVertexAttribPointervARB (GLuint, GLenum, GLvoid* *); +GLAPI GLboolean APIENTRY glIsProgramARB (GLuint); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLVERTEXATTRIB1DARBPROC) (GLuint index, GLdouble x); +typedef void (APIENTRYP PFNGLVERTEXATTRIB1DVARBPROC) (GLuint index, const GLdouble *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB1FARBPROC) (GLuint index, GLfloat x); +typedef void (APIENTRYP PFNGLVERTEXATTRIB1FVARBPROC) (GLuint index, const GLfloat *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB1SARBPROC) (GLuint index, GLshort x); +typedef void (APIENTRYP PFNGLVERTEXATTRIB1SVARBPROC) (GLuint index, const GLshort *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB2DARBPROC) (GLuint index, GLdouble x, GLdouble y); +typedef void (APIENTRYP PFNGLVERTEXATTRIB2DVARBPROC) (GLuint index, const GLdouble *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB2FARBPROC) (GLuint index, GLfloat x, GLfloat y); +typedef void (APIENTRYP PFNGLVERTEXATTRIB2FVARBPROC) (GLuint index, const GLfloat *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB2SARBPROC) (GLuint index, GLshort x, GLshort y); +typedef void (APIENTRYP PFNGLVERTEXATTRIB2SVARBPROC) (GLuint index, const GLshort *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB3DARBPROC) (GLuint index, GLdouble x, GLdouble y, GLdouble z); +typedef void (APIENTRYP PFNGLVERTEXATTRIB3DVARBPROC) (GLuint index, const GLdouble *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB3FARBPROC) (GLuint index, GLfloat x, GLfloat y, GLfloat z); +typedef void (APIENTRYP PFNGLVERTEXATTRIB3FVARBPROC) (GLuint index, const GLfloat *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB3SARBPROC) (GLuint index, GLshort x, GLshort y, GLshort z); +typedef void (APIENTRYP PFNGLVERTEXATTRIB3SVARBPROC) (GLuint index, const GLshort *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB4NBVARBPROC) (GLuint index, const GLbyte *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB4NIVARBPROC) (GLuint index, const GLint *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB4NSVARBPROC) (GLuint index, const GLshort *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB4NUBARBPROC) (GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w); +typedef void (APIENTRYP PFNGLVERTEXATTRIB4NUBVARBPROC) (GLuint index, const GLubyte *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB4NUIVARBPROC) (GLuint index, const GLuint *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB4NUSVARBPROC) (GLuint index, const GLushort *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB4BVARBPROC) (GLuint index, const GLbyte *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB4DARBPROC) (GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w); +typedef void (APIENTRYP PFNGLVERTEXATTRIB4DVARBPROC) (GLuint index, const GLdouble *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB4FARBPROC) (GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w); +typedef void (APIENTRYP PFNGLVERTEXATTRIB4FVARBPROC) (GLuint index, const GLfloat *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB4IVARBPROC) (GLuint index, const GLint *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB4SARBPROC) (GLuint index, GLshort x, GLshort y, GLshort z, GLshort w); +typedef void (APIENTRYP PFNGLVERTEXATTRIB4SVARBPROC) (GLuint index, const GLshort *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB4UBVARBPROC) (GLuint index, const GLubyte *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB4UIVARBPROC) (GLuint index, const GLuint *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB4USVARBPROC) (GLuint index, const GLushort *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIBPOINTERARBPROC) (GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const GLvoid *pointer); +typedef void (APIENTRYP PFNGLENABLEVERTEXATTRIBARRAYARBPROC) (GLuint index); +typedef void (APIENTRYP PFNGLDISABLEVERTEXATTRIBARRAYARBPROC) (GLuint index); +typedef void (APIENTRYP PFNGLPROGRAMSTRINGARBPROC) (GLenum target, GLenum format, GLsizei len, const GLvoid *string); +typedef void (APIENTRYP PFNGLBINDPROGRAMARBPROC) (GLenum target, GLuint program); +typedef void (APIENTRYP PFNGLDELETEPROGRAMSARBPROC) (GLsizei n, const GLuint *programs); +typedef void (APIENTRYP PFNGLGENPROGRAMSARBPROC) (GLsizei n, GLuint *programs); +typedef void (APIENTRYP PFNGLPROGRAMENVPARAMETER4DARBPROC) (GLenum target, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w); +typedef void (APIENTRYP PFNGLPROGRAMENVPARAMETER4DVARBPROC) (GLenum target, GLuint index, const GLdouble *params); +typedef void (APIENTRYP PFNGLPROGRAMENVPARAMETER4FARBPROC) (GLenum target, GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w); +typedef void (APIENTRYP PFNGLPROGRAMENVPARAMETER4FVARBPROC) (GLenum target, GLuint index, const GLfloat *params); +typedef void (APIENTRYP PFNGLPROGRAMLOCALPARAMETER4DARBPROC) (GLenum target, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w); +typedef void (APIENTRYP PFNGLPROGRAMLOCALPARAMETER4DVARBPROC) (GLenum target, GLuint index, const GLdouble *params); +typedef void (APIENTRYP PFNGLPROGRAMLOCALPARAMETER4FARBPROC) (GLenum target, GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w); +typedef void (APIENTRYP PFNGLPROGRAMLOCALPARAMETER4FVARBPROC) (GLenum target, GLuint index, const GLfloat *params); +typedef void (APIENTRYP PFNGLGETPROGRAMENVPARAMETERDVARBPROC) (GLenum target, GLuint index, GLdouble *params); +typedef void (APIENTRYP PFNGLGETPROGRAMENVPARAMETERFVARBPROC) (GLenum target, GLuint index, GLfloat *params); +typedef void (APIENTRYP PFNGLGETPROGRAMLOCALPARAMETERDVARBPROC) (GLenum target, GLuint index, GLdouble *params); +typedef void (APIENTRYP PFNGLGETPROGRAMLOCALPARAMETERFVARBPROC) (GLenum target, GLuint index, GLfloat *params); +typedef void (APIENTRYP PFNGLGETPROGRAMIVARBPROC) (GLenum target, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLGETPROGRAMSTRINGARBPROC) (GLenum target, GLenum pname, GLvoid *string); +typedef void (APIENTRYP PFNGLGETVERTEXATTRIBDVARBPROC) (GLuint index, GLenum pname, GLdouble *params); +typedef void (APIENTRYP PFNGLGETVERTEXATTRIBFVARBPROC) (GLuint index, GLenum pname, GLfloat *params); +typedef void (APIENTRYP PFNGLGETVERTEXATTRIBIVARBPROC) (GLuint index, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLGETVERTEXATTRIBPOINTERVARBPROC) (GLuint index, GLenum pname, GLvoid* *pointer); +typedef GLboolean (APIENTRYP PFNGLISPROGRAMARBPROC) (GLuint program); +#endif + +#ifndef GL_ARB_fragment_program +#define GL_ARB_fragment_program 1 +/* All ARB_fragment_program entry points are shared with ARB_vertex_program. */ +#endif + +#ifndef GL_ARB_vertex_buffer_object +#define GL_ARB_vertex_buffer_object 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glBindBufferARB (GLenum, GLuint); +GLAPI void APIENTRY glDeleteBuffersARB (GLsizei, const GLuint *); +GLAPI void APIENTRY glGenBuffersARB (GLsizei, GLuint *); +GLAPI GLboolean APIENTRY glIsBufferARB (GLuint); +GLAPI void APIENTRY glBufferDataARB (GLenum, GLsizeiptrARB, const GLvoid *, GLenum); +GLAPI void APIENTRY glBufferSubDataARB (GLenum, GLintptrARB, GLsizeiptrARB, const GLvoid *); +GLAPI void APIENTRY glGetBufferSubDataARB (GLenum, GLintptrARB, GLsizeiptrARB, GLvoid *); +GLAPI GLvoid* APIENTRY glMapBufferARB (GLenum, GLenum); +GLAPI GLboolean APIENTRY glUnmapBufferARB (GLenum); +GLAPI void APIENTRY glGetBufferParameterivARB (GLenum, GLenum, GLint *); +GLAPI void APIENTRY glGetBufferPointervARB (GLenum, GLenum, GLvoid* *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLBINDBUFFERARBPROC) (GLenum target, GLuint buffer); +typedef void (APIENTRYP PFNGLDELETEBUFFERSARBPROC) (GLsizei n, const GLuint *buffers); +typedef void (APIENTRYP PFNGLGENBUFFERSARBPROC) (GLsizei n, GLuint *buffers); +typedef GLboolean (APIENTRYP PFNGLISBUFFERARBPROC) (GLuint buffer); +typedef void (APIENTRYP PFNGLBUFFERDATAARBPROC) (GLenum target, GLsizeiptrARB size, const GLvoid *data, GLenum usage); +typedef void (APIENTRYP PFNGLBUFFERSUBDATAARBPROC) (GLenum target, GLintptrARB offset, GLsizeiptrARB size, const GLvoid *data); +typedef void (APIENTRYP PFNGLGETBUFFERSUBDATAARBPROC) (GLenum target, GLintptrARB offset, GLsizeiptrARB size, GLvoid *data); +typedef GLvoid* (APIENTRYP PFNGLMAPBUFFERARBPROC) (GLenum target, GLenum access); +typedef GLboolean (APIENTRYP PFNGLUNMAPBUFFERARBPROC) (GLenum target); +typedef void (APIENTRYP PFNGLGETBUFFERPARAMETERIVARBPROC) (GLenum target, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLGETBUFFERPOINTERVARBPROC) (GLenum target, GLenum pname, GLvoid* *params); +#endif + +#ifndef GL_ARB_occlusion_query +#define GL_ARB_occlusion_query 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glGenQueriesARB (GLsizei, GLuint *); +GLAPI void APIENTRY glDeleteQueriesARB (GLsizei, const GLuint *); +GLAPI GLboolean APIENTRY glIsQueryARB (GLuint); +GLAPI void APIENTRY glBeginQueryARB (GLenum, GLuint); +GLAPI void APIENTRY glEndQueryARB (GLenum); +GLAPI void APIENTRY glGetQueryivARB (GLenum, GLenum, GLint *); +GLAPI void APIENTRY glGetQueryObjectivARB (GLuint, GLenum, GLint *); +GLAPI void APIENTRY glGetQueryObjectuivARB (GLuint, GLenum, GLuint *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLGENQUERIESARBPROC) (GLsizei n, GLuint *ids); +typedef void (APIENTRYP PFNGLDELETEQUERIESARBPROC) (GLsizei n, const GLuint *ids); +typedef GLboolean (APIENTRYP PFNGLISQUERYARBPROC) (GLuint id); +typedef void (APIENTRYP PFNGLBEGINQUERYARBPROC) (GLenum target, GLuint id); +typedef void (APIENTRYP PFNGLENDQUERYARBPROC) (GLenum target); +typedef void (APIENTRYP PFNGLGETQUERYIVARBPROC) (GLenum target, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLGETQUERYOBJECTIVARBPROC) (GLuint id, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLGETQUERYOBJECTUIVARBPROC) (GLuint id, GLenum pname, GLuint *params); +#endif + +#ifndef GL_ARB_shader_objects +#define GL_ARB_shader_objects 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glDeleteObjectARB (GLhandleARB); +GLAPI GLhandleARB APIENTRY glGetHandleARB (GLenum); +GLAPI void APIENTRY glDetachObjectARB (GLhandleARB, GLhandleARB); +GLAPI GLhandleARB APIENTRY glCreateShaderObjectARB (GLenum); +GLAPI void APIENTRY glShaderSourceARB (GLhandleARB, GLsizei, const GLcharARB* *, const GLint *); +GLAPI void APIENTRY glCompileShaderARB (GLhandleARB); +GLAPI GLhandleARB APIENTRY glCreateProgramObjectARB (void); +GLAPI void APIENTRY glAttachObjectARB (GLhandleARB, GLhandleARB); +GLAPI void APIENTRY glLinkProgramARB (GLhandleARB); +GLAPI void APIENTRY glUseProgramObjectARB (GLhandleARB); +GLAPI void APIENTRY glValidateProgramARB (GLhandleARB); +GLAPI void APIENTRY glUniform1fARB (GLint, GLfloat); +GLAPI void APIENTRY glUniform2fARB (GLint, GLfloat, GLfloat); +GLAPI void APIENTRY glUniform3fARB (GLint, GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glUniform4fARB (GLint, GLfloat, GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glUniform1iARB (GLint, GLint); +GLAPI void APIENTRY glUniform2iARB (GLint, GLint, GLint); +GLAPI void APIENTRY glUniform3iARB (GLint, GLint, GLint, GLint); +GLAPI void APIENTRY glUniform4iARB (GLint, GLint, GLint, GLint, GLint); +GLAPI void APIENTRY glUniform1fvARB (GLint, GLsizei, const GLfloat *); +GLAPI void APIENTRY glUniform2fvARB (GLint, GLsizei, const GLfloat *); +GLAPI void APIENTRY glUniform3fvARB (GLint, GLsizei, const GLfloat *); +GLAPI void APIENTRY glUniform4fvARB (GLint, GLsizei, const GLfloat *); +GLAPI void APIENTRY glUniform1ivARB (GLint, GLsizei, const GLint *); +GLAPI void APIENTRY glUniform2ivARB (GLint, GLsizei, const GLint *); +GLAPI void APIENTRY glUniform3ivARB (GLint, GLsizei, const GLint *); +GLAPI void APIENTRY glUniform4ivARB (GLint, GLsizei, const GLint *); +GLAPI void APIENTRY glUniformMatrix2fvARB (GLint, GLsizei, GLboolean, const GLfloat *); +GLAPI void APIENTRY glUniformMatrix3fvARB (GLint, GLsizei, GLboolean, const GLfloat *); +GLAPI void APIENTRY glUniformMatrix4fvARB (GLint, GLsizei, GLboolean, const GLfloat *); +GLAPI void APIENTRY glGetObjectParameterfvARB (GLhandleARB, GLenum, GLfloat *); +GLAPI void APIENTRY glGetObjectParameterivARB (GLhandleARB, GLenum, GLint *); +GLAPI void APIENTRY glGetInfoLogARB (GLhandleARB, GLsizei, GLsizei *, GLcharARB *); +GLAPI void APIENTRY glGetAttachedObjectsARB (GLhandleARB, GLsizei, GLsizei *, GLhandleARB *); +GLAPI GLint APIENTRY glGetUniformLocationARB (GLhandleARB, const GLcharARB *); +GLAPI void APIENTRY glGetActiveUniformARB (GLhandleARB, GLuint, GLsizei, GLsizei *, GLint *, GLenum *, GLcharARB *); +GLAPI void APIENTRY glGetUniformfvARB (GLhandleARB, GLint, GLfloat *); +GLAPI void APIENTRY glGetUniformivARB (GLhandleARB, GLint, GLint *); +GLAPI void APIENTRY glGetShaderSourceARB (GLhandleARB, GLsizei, GLsizei *, GLcharARB *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLDELETEOBJECTARBPROC) (GLhandleARB obj); +typedef GLhandleARB (APIENTRYP PFNGLGETHANDLEARBPROC) (GLenum pname); +typedef void (APIENTRYP PFNGLDETACHOBJECTARBPROC) (GLhandleARB containerObj, GLhandleARB attachedObj); +typedef GLhandleARB (APIENTRYP PFNGLCREATESHADEROBJECTARBPROC) (GLenum shaderType); +typedef void (APIENTRYP PFNGLSHADERSOURCEARBPROC) (GLhandleARB shaderObj, GLsizei count, const GLcharARB* *string, const GLint *length); +typedef void (APIENTRYP PFNGLCOMPILESHADERARBPROC) (GLhandleARB shaderObj); +typedef GLhandleARB (APIENTRYP PFNGLCREATEPROGRAMOBJECTARBPROC) (void); +typedef void (APIENTRYP PFNGLATTACHOBJECTARBPROC) (GLhandleARB containerObj, GLhandleARB obj); +typedef void (APIENTRYP PFNGLLINKPROGRAMARBPROC) (GLhandleARB programObj); +typedef void (APIENTRYP PFNGLUSEPROGRAMOBJECTARBPROC) (GLhandleARB programObj); +typedef void (APIENTRYP PFNGLVALIDATEPROGRAMARBPROC) (GLhandleARB programObj); +typedef void (APIENTRYP PFNGLUNIFORM1FARBPROC) (GLint location, GLfloat v0); +typedef void (APIENTRYP PFNGLUNIFORM2FARBPROC) (GLint location, GLfloat v0, GLfloat v1); +typedef void (APIENTRYP PFNGLUNIFORM3FARBPROC) (GLint location, GLfloat v0, GLfloat v1, GLfloat v2); +typedef void (APIENTRYP PFNGLUNIFORM4FARBPROC) (GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3); +typedef void (APIENTRYP PFNGLUNIFORM1IARBPROC) (GLint location, GLint v0); +typedef void (APIENTRYP PFNGLUNIFORM2IARBPROC) (GLint location, GLint v0, GLint v1); +typedef void (APIENTRYP PFNGLUNIFORM3IARBPROC) (GLint location, GLint v0, GLint v1, GLint v2); +typedef void (APIENTRYP PFNGLUNIFORM4IARBPROC) (GLint location, GLint v0, GLint v1, GLint v2, GLint v3); +typedef void (APIENTRYP PFNGLUNIFORM1FVARBPROC) (GLint location, GLsizei count, const GLfloat *value); +typedef void (APIENTRYP PFNGLUNIFORM2FVARBPROC) (GLint location, GLsizei count, const GLfloat *value); +typedef void (APIENTRYP PFNGLUNIFORM3FVARBPROC) (GLint location, GLsizei count, const GLfloat *value); +typedef void (APIENTRYP PFNGLUNIFORM4FVARBPROC) (GLint location, GLsizei count, const GLfloat *value); +typedef void (APIENTRYP PFNGLUNIFORM1IVARBPROC) (GLint location, GLsizei count, const GLint *value); +typedef void (APIENTRYP PFNGLUNIFORM2IVARBPROC) (GLint location, GLsizei count, const GLint *value); +typedef void (APIENTRYP PFNGLUNIFORM3IVARBPROC) (GLint location, GLsizei count, const GLint *value); +typedef void (APIENTRYP PFNGLUNIFORM4IVARBPROC) (GLint location, GLsizei count, const GLint *value); +typedef void (APIENTRYP PFNGLUNIFORMMATRIX2FVARBPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (APIENTRYP PFNGLUNIFORMMATRIX3FVARBPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (APIENTRYP PFNGLUNIFORMMATRIX4FVARBPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (APIENTRYP PFNGLGETOBJECTPARAMETERFVARBPROC) (GLhandleARB obj, GLenum pname, GLfloat *params); +typedef void (APIENTRYP PFNGLGETOBJECTPARAMETERIVARBPROC) (GLhandleARB obj, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLGETINFOLOGARBPROC) (GLhandleARB obj, GLsizei maxLength, GLsizei *length, GLcharARB *infoLog); +typedef void (APIENTRYP PFNGLGETATTACHEDOBJECTSARBPROC) (GLhandleARB containerObj, GLsizei maxCount, GLsizei *count, GLhandleARB *obj); +typedef GLint (APIENTRYP PFNGLGETUNIFORMLOCATIONARBPROC) (GLhandleARB programObj, const GLcharARB *name); +typedef void (APIENTRYP PFNGLGETACTIVEUNIFORMARBPROC) (GLhandleARB programObj, GLuint index, GLsizei maxLength, GLsizei *length, GLint *size, GLenum *type, GLcharARB *name); +typedef void (APIENTRYP PFNGLGETUNIFORMFVARBPROC) (GLhandleARB programObj, GLint location, GLfloat *params); +typedef void (APIENTRYP PFNGLGETUNIFORMIVARBPROC) (GLhandleARB programObj, GLint location, GLint *params); +typedef void (APIENTRYP PFNGLGETSHADERSOURCEARBPROC) (GLhandleARB obj, GLsizei maxLength, GLsizei *length, GLcharARB *source); +#endif + +#ifndef GL_ARB_vertex_shader +#define GL_ARB_vertex_shader 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glBindAttribLocationARB (GLhandleARB, GLuint, const GLcharARB *); +GLAPI void APIENTRY glGetActiveAttribARB (GLhandleARB, GLuint, GLsizei, GLsizei *, GLint *, GLenum *, GLcharARB *); +GLAPI GLint APIENTRY glGetAttribLocationARB (GLhandleARB, const GLcharARB *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLBINDATTRIBLOCATIONARBPROC) (GLhandleARB programObj, GLuint index, const GLcharARB *name); +typedef void (APIENTRYP PFNGLGETACTIVEATTRIBARBPROC) (GLhandleARB programObj, GLuint index, GLsizei maxLength, GLsizei *length, GLint *size, GLenum *type, GLcharARB *name); +typedef GLint (APIENTRYP PFNGLGETATTRIBLOCATIONARBPROC) (GLhandleARB programObj, const GLcharARB *name); +#endif + +#ifndef GL_ARB_fragment_shader +#define GL_ARB_fragment_shader 1 +#endif + +#ifndef GL_ARB_shading_language_100 +#define GL_ARB_shading_language_100 1 +#endif + +#ifndef GL_ARB_texture_non_power_of_two +#define GL_ARB_texture_non_power_of_two 1 +#endif + +#ifndef GL_ARB_point_sprite +#define GL_ARB_point_sprite 1 +#endif + +#ifndef GL_ARB_fragment_program_shadow +#define GL_ARB_fragment_program_shadow 1 +#endif + +#ifndef GL_ARB_draw_buffers +#define GL_ARB_draw_buffers 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glDrawBuffersARB (GLsizei, const GLenum *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLDRAWBUFFERSARBPROC) (GLsizei n, const GLenum *bufs); +#endif + +#ifndef GL_ARB_texture_rectangle +#define GL_ARB_texture_rectangle 1 +#endif + +#ifndef GL_ARB_color_buffer_float +#define GL_ARB_color_buffer_float 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glClampColorARB (GLenum, GLenum); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLCLAMPCOLORARBPROC) (GLenum target, GLenum clamp); +#endif + +#ifndef GL_ARB_half_float_pixel +#define GL_ARB_half_float_pixel 1 +#endif + +#ifndef GL_ARB_texture_float +#define GL_ARB_texture_float 1 +#endif + +#ifndef GL_ARB_pixel_buffer_object +#define GL_ARB_pixel_buffer_object 1 +#endif + +#ifndef GL_ARB_depth_buffer_float +#define GL_ARB_depth_buffer_float 1 +#endif + +#ifndef GL_ARB_draw_instanced +#define GL_ARB_draw_instanced 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glDrawArraysInstancedARB (GLenum, GLint, GLsizei, GLsizei); +GLAPI void APIENTRY glDrawElementsInstancedARB (GLenum, GLsizei, GLenum, const GLvoid *, GLsizei); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLDRAWARRAYSINSTANCEDARBPROC) (GLenum mode, GLint first, GLsizei count, GLsizei primcount); +typedef void (APIENTRYP PFNGLDRAWELEMENTSINSTANCEDARBPROC) (GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei primcount); +#endif + +#ifndef GL_ARB_framebuffer_object +#define GL_ARB_framebuffer_object 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI GLboolean APIENTRY glIsRenderbuffer (GLuint); +GLAPI void APIENTRY glBindRenderbuffer (GLenum, GLuint); +GLAPI void APIENTRY glDeleteRenderbuffers (GLsizei, const GLuint *); +GLAPI void APIENTRY glGenRenderbuffers (GLsizei, GLuint *); +GLAPI void APIENTRY glRenderbufferStorage (GLenum, GLenum, GLsizei, GLsizei); +GLAPI void APIENTRY glGetRenderbufferParameteriv (GLenum, GLenum, GLint *); +GLAPI GLboolean APIENTRY glIsFramebuffer (GLuint); +GLAPI void APIENTRY glBindFramebuffer (GLenum, GLuint); +GLAPI void APIENTRY glDeleteFramebuffers (GLsizei, const GLuint *); +GLAPI void APIENTRY glGenFramebuffers (GLsizei, GLuint *); +GLAPI GLenum APIENTRY glCheckFramebufferStatus (GLenum); +GLAPI void APIENTRY glFramebufferTexture1D (GLenum, GLenum, GLenum, GLuint, GLint); +GLAPI void APIENTRY glFramebufferTexture2D (GLenum, GLenum, GLenum, GLuint, GLint); +GLAPI void APIENTRY glFramebufferTexture3D (GLenum, GLenum, GLenum, GLuint, GLint, GLint); +GLAPI void APIENTRY glFramebufferRenderbuffer (GLenum, GLenum, GLenum, GLuint); +GLAPI void APIENTRY glGetFramebufferAttachmentParameteriv (GLenum, GLenum, GLenum, GLint *); +GLAPI void APIENTRY glGenerateMipmap (GLenum); +GLAPI void APIENTRY glBlitFramebuffer (GLint, GLint, GLint, GLint, GLint, GLint, GLint, GLint, GLbitfield, GLenum); +GLAPI void APIENTRY glRenderbufferStorageMultisample (GLenum, GLsizei, GLenum, GLsizei, GLsizei); +GLAPI void APIENTRY glFramebufferTextureLayer (GLenum, GLenum, GLuint, GLint, GLint); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef GLboolean (APIENTRYP PFNGLISRENDERBUFFERPROC) (GLuint renderbuffer); +typedef void (APIENTRYP PFNGLBINDRENDERBUFFERPROC) (GLenum target, GLuint renderbuffer); +typedef void (APIENTRYP PFNGLDELETERENDERBUFFERSPROC) (GLsizei n, const GLuint *renderbuffers); +typedef void (APIENTRYP PFNGLGENRENDERBUFFERSPROC) (GLsizei n, GLuint *renderbuffers); +typedef void (APIENTRYP PFNGLRENDERBUFFERSTORAGEPROC) (GLenum target, GLenum internalformat, GLsizei width, GLsizei height); +typedef void (APIENTRYP PFNGLGETRENDERBUFFERPARAMETERIVPROC) (GLenum target, GLenum pname, GLint *params); +typedef GLboolean (APIENTRYP PFNGLISFRAMEBUFFERPROC) (GLuint framebuffer); +typedef void (APIENTRYP PFNGLBINDFRAMEBUFFERPROC) (GLenum target, GLuint framebuffer); +typedef void (APIENTRYP PFNGLDELETEFRAMEBUFFERSPROC) (GLsizei n, const GLuint *framebuffers); +typedef void (APIENTRYP PFNGLGENFRAMEBUFFERSPROC) (GLsizei n, GLuint *framebuffers); +typedef GLenum (APIENTRYP PFNGLCHECKFRAMEBUFFERSTATUSPROC) (GLenum target); +typedef void (APIENTRYP PFNGLFRAMEBUFFERTEXTURE1DPROC) (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level); +typedef void (APIENTRYP PFNGLFRAMEBUFFERTEXTURE2DPROC) (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level); +typedef void (APIENTRYP PFNGLFRAMEBUFFERTEXTURE3DPROC) (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset); +typedef void (APIENTRYP PFNGLFRAMEBUFFERRENDERBUFFERPROC) (GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer); +typedef void (APIENTRYP PFNGLGETFRAMEBUFFERATTACHMENTPARAMETERIVPROC) (GLenum target, GLenum attachment, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLGENERATEMIPMAPPROC) (GLenum target); +typedef void (APIENTRYP PFNGLBLITFRAMEBUFFERPROC) (GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter); +typedef void (APIENTRYP PFNGLRENDERBUFFERSTORAGEMULTISAMPLEPROC) (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height); +typedef void (APIENTRYP PFNGLFRAMEBUFFERTEXTURELAYERPROC) (GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer); +#endif + +#ifndef GL_ARB_framebuffer_sRGB +#define GL_ARB_framebuffer_sRGB 1 +#endif + +#ifndef GL_ARB_geometry_shader4 +#define GL_ARB_geometry_shader4 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glProgramParameteriARB (GLuint, GLenum, GLint); +GLAPI void APIENTRY glFramebufferTextureARB (GLenum, GLenum, GLuint, GLint); +GLAPI void APIENTRY glFramebufferTextureLayerARB (GLenum, GLenum, GLuint, GLint, GLint); +GLAPI void APIENTRY glFramebufferTextureFaceARB (GLenum, GLenum, GLuint, GLint, GLenum); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLPROGRAMPARAMETERIARBPROC) (GLuint program, GLenum pname, GLint value); +typedef void (APIENTRYP PFNGLFRAMEBUFFERTEXTUREARBPROC) (GLenum target, GLenum attachment, GLuint texture, GLint level); +typedef void (APIENTRYP PFNGLFRAMEBUFFERTEXTURELAYERARBPROC) (GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer); +typedef void (APIENTRYP PFNGLFRAMEBUFFERTEXTUREFACEARBPROC) (GLenum target, GLenum attachment, GLuint texture, GLint level, GLenum face); +#endif + +#ifndef GL_ARB_half_float_vertex +#define GL_ARB_half_float_vertex 1 +#endif + +#ifndef GL_ARB_instanced_arrays +#define GL_ARB_instanced_arrays 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glVertexAttribDivisor (GLuint, GLuint); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLVERTEXATTRIBDIVISORPROC) (GLuint index, GLuint divisor); +#endif + +#ifndef GL_ARB_map_buffer_range +#define GL_ARB_map_buffer_range 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glMapBufferRange (GLenum, GLintptr, GLsizeiptr, GLbitfield); +GLAPI void APIENTRY glFlushMappedBufferRange (GLenum, GLintptr, GLsizeiptr); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLMAPBUFFERRANGEPROC) (GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access); +typedef void (APIENTRYP PFNGLFLUSHMAPPEDBUFFERRANGEPROC) (GLenum target, GLintptr offset, GLsizeiptr length); +#endif + +#ifndef GL_ARB_texture_buffer_object +#define GL_ARB_texture_buffer_object 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glTexBufferARB (GLenum, GLenum, GLuint); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLTEXBUFFERARBPROC) (GLenum target, GLenum internalformat, GLuint buffer); +#endif + +#ifndef GL_ARB_texture_compression_rgtc +#define GL_ARB_texture_compression_rgtc 1 +#endif + +#ifndef GL_ARB_texture_rg +#define GL_ARB_texture_rg 1 +#endif + +#ifndef GL_ARB_vertex_array_object +#define GL_ARB_vertex_array_object 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glBindVertexArray (GLuint); +GLAPI void APIENTRY glDeleteVertexArrays (GLsizei, const GLuint *); +GLAPI void APIENTRY glGenVertexArrays (GLsizei, GLuint *); +GLAPI GLboolean APIENTRY glIsVertexArray (GLuint); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLBINDVERTEXARRAYPROC) (GLuint array); +typedef void (APIENTRYP PFNGLDELETEVERTEXARRAYSPROC) (GLsizei n, const GLuint *arrays); +typedef void (APIENTRYP PFNGLGENVERTEXARRAYSPROC) (GLsizei n, GLuint *arrays); +typedef GLboolean (APIENTRYP PFNGLISVERTEXARRAYPROC) (GLuint array); +#endif + +#ifndef GL_EXT_abgr +#define GL_EXT_abgr 1 +#endif + +#ifndef GL_EXT_blend_color +#define GL_EXT_blend_color 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glBlendColorEXT (GLclampf, GLclampf, GLclampf, GLclampf); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLBLENDCOLOREXTPROC) (GLclampf red, GLclampf green, GLclampf blue, GLclampf alpha); +#endif + +#ifndef GL_EXT_polygon_offset +#define GL_EXT_polygon_offset 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glPolygonOffsetEXT (GLfloat, GLfloat); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLPOLYGONOFFSETEXTPROC) (GLfloat factor, GLfloat bias); +#endif + +#ifndef GL_EXT_texture +#define GL_EXT_texture 1 +#endif + +#ifndef GL_EXT_texture3D +#define GL_EXT_texture3D 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glTexImage3DEXT (GLenum, GLint, GLenum, GLsizei, GLsizei, GLsizei, GLint, GLenum, GLenum, const GLvoid *); +GLAPI void APIENTRY glTexSubImage3DEXT (GLenum, GLint, GLint, GLint, GLint, GLsizei, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLTEXIMAGE3DEXTPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels); +typedef void (APIENTRYP PFNGLTEXSUBIMAGE3DEXTPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels); +#endif + +#ifndef GL_SGIS_texture_filter4 +#define GL_SGIS_texture_filter4 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glGetTexFilterFuncSGIS (GLenum, GLenum, GLfloat *); +GLAPI void APIENTRY glTexFilterFuncSGIS (GLenum, GLenum, GLsizei, const GLfloat *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLGETTEXFILTERFUNCSGISPROC) (GLenum target, GLenum filter, GLfloat *weights); +typedef void (APIENTRYP PFNGLTEXFILTERFUNCSGISPROC) (GLenum target, GLenum filter, GLsizei n, const GLfloat *weights); +#endif + +#ifndef GL_EXT_subtexture +#define GL_EXT_subtexture 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glTexSubImage1DEXT (GLenum, GLint, GLint, GLsizei, GLenum, GLenum, const GLvoid *); +GLAPI void APIENTRY glTexSubImage2DEXT (GLenum, GLint, GLint, GLint, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLTEXSUBIMAGE1DEXTPROC) (GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels); +typedef void (APIENTRYP PFNGLTEXSUBIMAGE2DEXTPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels); +#endif + +#ifndef GL_EXT_copy_texture +#define GL_EXT_copy_texture 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glCopyTexImage1DEXT (GLenum, GLint, GLenum, GLint, GLint, GLsizei, GLint); +GLAPI void APIENTRY glCopyTexImage2DEXT (GLenum, GLint, GLenum, GLint, GLint, GLsizei, GLsizei, GLint); +GLAPI void APIENTRY glCopyTexSubImage1DEXT (GLenum, GLint, GLint, GLint, GLint, GLsizei); +GLAPI void APIENTRY glCopyTexSubImage2DEXT (GLenum, GLint, GLint, GLint, GLint, GLint, GLsizei, GLsizei); +GLAPI void APIENTRY glCopyTexSubImage3DEXT (GLenum, GLint, GLint, GLint, GLint, GLint, GLint, GLsizei, GLsizei); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLCOPYTEXIMAGE1DEXTPROC) (GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border); +typedef void (APIENTRYP PFNGLCOPYTEXIMAGE2DEXTPROC) (GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border); +typedef void (APIENTRYP PFNGLCOPYTEXSUBIMAGE1DEXTPROC) (GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width); +typedef void (APIENTRYP PFNGLCOPYTEXSUBIMAGE2DEXTPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height); +typedef void (APIENTRYP PFNGLCOPYTEXSUBIMAGE3DEXTPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height); +#endif + +#ifndef GL_EXT_histogram +#define GL_EXT_histogram 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glGetHistogramEXT (GLenum, GLboolean, GLenum, GLenum, GLvoid *); +GLAPI void APIENTRY glGetHistogramParameterfvEXT (GLenum, GLenum, GLfloat *); +GLAPI void APIENTRY glGetHistogramParameterivEXT (GLenum, GLenum, GLint *); +GLAPI void APIENTRY glGetMinmaxEXT (GLenum, GLboolean, GLenum, GLenum, GLvoid *); +GLAPI void APIENTRY glGetMinmaxParameterfvEXT (GLenum, GLenum, GLfloat *); +GLAPI void APIENTRY glGetMinmaxParameterivEXT (GLenum, GLenum, GLint *); +GLAPI void APIENTRY glHistogramEXT (GLenum, GLsizei, GLenum, GLboolean); +GLAPI void APIENTRY glMinmaxEXT (GLenum, GLenum, GLboolean); +GLAPI void APIENTRY glResetHistogramEXT (GLenum); +GLAPI void APIENTRY glResetMinmaxEXT (GLenum); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLGETHISTOGRAMEXTPROC) (GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values); +typedef void (APIENTRYP PFNGLGETHISTOGRAMPARAMETERFVEXTPROC) (GLenum target, GLenum pname, GLfloat *params); +typedef void (APIENTRYP PFNGLGETHISTOGRAMPARAMETERIVEXTPROC) (GLenum target, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLGETMINMAXEXTPROC) (GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values); +typedef void (APIENTRYP PFNGLGETMINMAXPARAMETERFVEXTPROC) (GLenum target, GLenum pname, GLfloat *params); +typedef void (APIENTRYP PFNGLGETMINMAXPARAMETERIVEXTPROC) (GLenum target, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLHISTOGRAMEXTPROC) (GLenum target, GLsizei width, GLenum internalformat, GLboolean sink); +typedef void (APIENTRYP PFNGLMINMAXEXTPROC) (GLenum target, GLenum internalformat, GLboolean sink); +typedef void (APIENTRYP PFNGLRESETHISTOGRAMEXTPROC) (GLenum target); +typedef void (APIENTRYP PFNGLRESETMINMAXEXTPROC) (GLenum target); +#endif + +#ifndef GL_EXT_convolution +#define GL_EXT_convolution 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glConvolutionFilter1DEXT (GLenum, GLenum, GLsizei, GLenum, GLenum, const GLvoid *); +GLAPI void APIENTRY glConvolutionFilter2DEXT (GLenum, GLenum, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *); +GLAPI void APIENTRY glConvolutionParameterfEXT (GLenum, GLenum, GLfloat); +GLAPI void APIENTRY glConvolutionParameterfvEXT (GLenum, GLenum, const GLfloat *); +GLAPI void APIENTRY glConvolutionParameteriEXT (GLenum, GLenum, GLint); +GLAPI void APIENTRY glConvolutionParameterivEXT (GLenum, GLenum, const GLint *); +GLAPI void APIENTRY glCopyConvolutionFilter1DEXT (GLenum, GLenum, GLint, GLint, GLsizei); +GLAPI void APIENTRY glCopyConvolutionFilter2DEXT (GLenum, GLenum, GLint, GLint, GLsizei, GLsizei); +GLAPI void APIENTRY glGetConvolutionFilterEXT (GLenum, GLenum, GLenum, GLvoid *); +GLAPI void APIENTRY glGetConvolutionParameterfvEXT (GLenum, GLenum, GLfloat *); +GLAPI void APIENTRY glGetConvolutionParameterivEXT (GLenum, GLenum, GLint *); +GLAPI void APIENTRY glGetSeparableFilterEXT (GLenum, GLenum, GLenum, GLvoid *, GLvoid *, GLvoid *); +GLAPI void APIENTRY glSeparableFilter2DEXT (GLenum, GLenum, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *, const GLvoid *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLCONVOLUTIONFILTER1DEXTPROC) (GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *image); +typedef void (APIENTRYP PFNGLCONVOLUTIONFILTER2DEXTPROC) (GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *image); +typedef void (APIENTRYP PFNGLCONVOLUTIONPARAMETERFEXTPROC) (GLenum target, GLenum pname, GLfloat params); +typedef void (APIENTRYP PFNGLCONVOLUTIONPARAMETERFVEXTPROC) (GLenum target, GLenum pname, const GLfloat *params); +typedef void (APIENTRYP PFNGLCONVOLUTIONPARAMETERIEXTPROC) (GLenum target, GLenum pname, GLint params); +typedef void (APIENTRYP PFNGLCONVOLUTIONPARAMETERIVEXTPROC) (GLenum target, GLenum pname, const GLint *params); +typedef void (APIENTRYP PFNGLCOPYCONVOLUTIONFILTER1DEXTPROC) (GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width); +typedef void (APIENTRYP PFNGLCOPYCONVOLUTIONFILTER2DEXTPROC) (GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height); +typedef void (APIENTRYP PFNGLGETCONVOLUTIONFILTEREXTPROC) (GLenum target, GLenum format, GLenum type, GLvoid *image); +typedef void (APIENTRYP PFNGLGETCONVOLUTIONPARAMETERFVEXTPROC) (GLenum target, GLenum pname, GLfloat *params); +typedef void (APIENTRYP PFNGLGETCONVOLUTIONPARAMETERIVEXTPROC) (GLenum target, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLGETSEPARABLEFILTEREXTPROC) (GLenum target, GLenum format, GLenum type, GLvoid *row, GLvoid *column, GLvoid *span); +typedef void (APIENTRYP PFNGLSEPARABLEFILTER2DEXTPROC) (GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *row, const GLvoid *column); +#endif + +#ifndef GL_SGI_color_matrix +#define GL_SGI_color_matrix 1 +#endif + +#ifndef GL_SGI_color_table +#define GL_SGI_color_table 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glColorTableSGI (GLenum, GLenum, GLsizei, GLenum, GLenum, const GLvoid *); +GLAPI void APIENTRY glColorTableParameterfvSGI (GLenum, GLenum, const GLfloat *); +GLAPI void APIENTRY glColorTableParameterivSGI (GLenum, GLenum, const GLint *); +GLAPI void APIENTRY glCopyColorTableSGI (GLenum, GLenum, GLint, GLint, GLsizei); +GLAPI void APIENTRY glGetColorTableSGI (GLenum, GLenum, GLenum, GLvoid *); +GLAPI void APIENTRY glGetColorTableParameterfvSGI (GLenum, GLenum, GLfloat *); +GLAPI void APIENTRY glGetColorTableParameterivSGI (GLenum, GLenum, GLint *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLCOLORTABLESGIPROC) (GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *table); +typedef void (APIENTRYP PFNGLCOLORTABLEPARAMETERFVSGIPROC) (GLenum target, GLenum pname, const GLfloat *params); +typedef void (APIENTRYP PFNGLCOLORTABLEPARAMETERIVSGIPROC) (GLenum target, GLenum pname, const GLint *params); +typedef void (APIENTRYP PFNGLCOPYCOLORTABLESGIPROC) (GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width); +typedef void (APIENTRYP PFNGLGETCOLORTABLESGIPROC) (GLenum target, GLenum format, GLenum type, GLvoid *table); +typedef void (APIENTRYP PFNGLGETCOLORTABLEPARAMETERFVSGIPROC) (GLenum target, GLenum pname, GLfloat *params); +typedef void (APIENTRYP PFNGLGETCOLORTABLEPARAMETERIVSGIPROC) (GLenum target, GLenum pname, GLint *params); +#endif + +#ifndef GL_SGIX_pixel_texture +#define GL_SGIX_pixel_texture 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glPixelTexGenSGIX (GLenum); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLPIXELTEXGENSGIXPROC) (GLenum mode); +#endif + +#ifndef GL_SGIS_pixel_texture +#define GL_SGIS_pixel_texture 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glPixelTexGenParameteriSGIS (GLenum, GLint); +GLAPI void APIENTRY glPixelTexGenParameterivSGIS (GLenum, const GLint *); +GLAPI void APIENTRY glPixelTexGenParameterfSGIS (GLenum, GLfloat); +GLAPI void APIENTRY glPixelTexGenParameterfvSGIS (GLenum, const GLfloat *); +GLAPI void APIENTRY glGetPixelTexGenParameterivSGIS (GLenum, GLint *); +GLAPI void APIENTRY glGetPixelTexGenParameterfvSGIS (GLenum, GLfloat *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLPIXELTEXGENPARAMETERISGISPROC) (GLenum pname, GLint param); +typedef void (APIENTRYP PFNGLPIXELTEXGENPARAMETERIVSGISPROC) (GLenum pname, const GLint *params); +typedef void (APIENTRYP PFNGLPIXELTEXGENPARAMETERFSGISPROC) (GLenum pname, GLfloat param); +typedef void (APIENTRYP PFNGLPIXELTEXGENPARAMETERFVSGISPROC) (GLenum pname, const GLfloat *params); +typedef void (APIENTRYP PFNGLGETPIXELTEXGENPARAMETERIVSGISPROC) (GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLGETPIXELTEXGENPARAMETERFVSGISPROC) (GLenum pname, GLfloat *params); +#endif + +#ifndef GL_SGIS_texture4D +#define GL_SGIS_texture4D 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glTexImage4DSGIS (GLenum, GLint, GLenum, GLsizei, GLsizei, GLsizei, GLsizei, GLint, GLenum, GLenum, const GLvoid *); +GLAPI void APIENTRY glTexSubImage4DSGIS (GLenum, GLint, GLint, GLint, GLint, GLint, GLsizei, GLsizei, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLTEXIMAGE4DSGISPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLsizei size4d, GLint border, GLenum format, GLenum type, const GLvoid *pixels); +typedef void (APIENTRYP PFNGLTEXSUBIMAGE4DSGISPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint woffset, GLsizei width, GLsizei height, GLsizei depth, GLsizei size4d, GLenum format, GLenum type, const GLvoid *pixels); +#endif + +#ifndef GL_SGI_texture_color_table +#define GL_SGI_texture_color_table 1 +#endif + +#ifndef GL_EXT_cmyka +#define GL_EXT_cmyka 1 +#endif + +#ifndef GL_EXT_texture_object +#define GL_EXT_texture_object 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI GLboolean APIENTRY glAreTexturesResidentEXT (GLsizei, const GLuint *, GLboolean *); +GLAPI void APIENTRY glBindTextureEXT (GLenum, GLuint); +GLAPI void APIENTRY glDeleteTexturesEXT (GLsizei, const GLuint *); +GLAPI void APIENTRY glGenTexturesEXT (GLsizei, GLuint *); +GLAPI GLboolean APIENTRY glIsTextureEXT (GLuint); +GLAPI void APIENTRY glPrioritizeTexturesEXT (GLsizei, const GLuint *, const GLclampf *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef GLboolean (APIENTRYP PFNGLARETEXTURESRESIDENTEXTPROC) (GLsizei n, const GLuint *textures, GLboolean *residences); +typedef void (APIENTRYP PFNGLBINDTEXTUREEXTPROC) (GLenum target, GLuint texture); +typedef void (APIENTRYP PFNGLDELETETEXTURESEXTPROC) (GLsizei n, const GLuint *textures); +typedef void (APIENTRYP PFNGLGENTEXTURESEXTPROC) (GLsizei n, GLuint *textures); +typedef GLboolean (APIENTRYP PFNGLISTEXTUREEXTPROC) (GLuint texture); +typedef void (APIENTRYP PFNGLPRIORITIZETEXTURESEXTPROC) (GLsizei n, const GLuint *textures, const GLclampf *priorities); +#endif + +#ifndef GL_SGIS_detail_texture +#define GL_SGIS_detail_texture 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glDetailTexFuncSGIS (GLenum, GLsizei, const GLfloat *); +GLAPI void APIENTRY glGetDetailTexFuncSGIS (GLenum, GLfloat *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLDETAILTEXFUNCSGISPROC) (GLenum target, GLsizei n, const GLfloat *points); +typedef void (APIENTRYP PFNGLGETDETAILTEXFUNCSGISPROC) (GLenum target, GLfloat *points); +#endif + +#ifndef GL_SGIS_sharpen_texture +#define GL_SGIS_sharpen_texture 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glSharpenTexFuncSGIS (GLenum, GLsizei, const GLfloat *); +GLAPI void APIENTRY glGetSharpenTexFuncSGIS (GLenum, GLfloat *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLSHARPENTEXFUNCSGISPROC) (GLenum target, GLsizei n, const GLfloat *points); +typedef void (APIENTRYP PFNGLGETSHARPENTEXFUNCSGISPROC) (GLenum target, GLfloat *points); +#endif + +#ifndef GL_EXT_packed_pixels +#define GL_EXT_packed_pixels 1 +#endif + +#ifndef GL_SGIS_texture_lod +#define GL_SGIS_texture_lod 1 +#endif + +#ifndef GL_SGIS_multisample +#define GL_SGIS_multisample 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glSampleMaskSGIS (GLclampf, GLboolean); +GLAPI void APIENTRY glSamplePatternSGIS (GLenum); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLSAMPLEMASKSGISPROC) (GLclampf value, GLboolean invert); +typedef void (APIENTRYP PFNGLSAMPLEPATTERNSGISPROC) (GLenum pattern); +#endif + +#ifndef GL_EXT_rescale_normal +#define GL_EXT_rescale_normal 1 +#endif + +#ifndef GL_EXT_vertex_array +#define GL_EXT_vertex_array 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glArrayElementEXT (GLint); +GLAPI void APIENTRY glColorPointerEXT (GLint, GLenum, GLsizei, GLsizei, const GLvoid *); +GLAPI void APIENTRY glDrawArraysEXT (GLenum, GLint, GLsizei); +GLAPI void APIENTRY glEdgeFlagPointerEXT (GLsizei, GLsizei, const GLboolean *); +GLAPI void APIENTRY glGetPointervEXT (GLenum, GLvoid* *); +GLAPI void APIENTRY glIndexPointerEXT (GLenum, GLsizei, GLsizei, const GLvoid *); +GLAPI void APIENTRY glNormalPointerEXT (GLenum, GLsizei, GLsizei, const GLvoid *); +GLAPI void APIENTRY glTexCoordPointerEXT (GLint, GLenum, GLsizei, GLsizei, const GLvoid *); +GLAPI void APIENTRY glVertexPointerEXT (GLint, GLenum, GLsizei, GLsizei, const GLvoid *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLARRAYELEMENTEXTPROC) (GLint i); +typedef void (APIENTRYP PFNGLCOLORPOINTEREXTPROC) (GLint size, GLenum type, GLsizei stride, GLsizei count, const GLvoid *pointer); +typedef void (APIENTRYP PFNGLDRAWARRAYSEXTPROC) (GLenum mode, GLint first, GLsizei count); +typedef void (APIENTRYP PFNGLEDGEFLAGPOINTEREXTPROC) (GLsizei stride, GLsizei count, const GLboolean *pointer); +typedef void (APIENTRYP PFNGLGETPOINTERVEXTPROC) (GLenum pname, GLvoid* *params); +typedef void (APIENTRYP PFNGLINDEXPOINTEREXTPROC) (GLenum type, GLsizei stride, GLsizei count, const GLvoid *pointer); +typedef void (APIENTRYP PFNGLNORMALPOINTEREXTPROC) (GLenum type, GLsizei stride, GLsizei count, const GLvoid *pointer); +typedef void (APIENTRYP PFNGLTEXCOORDPOINTEREXTPROC) (GLint size, GLenum type, GLsizei stride, GLsizei count, const GLvoid *pointer); +typedef void (APIENTRYP PFNGLVERTEXPOINTEREXTPROC) (GLint size, GLenum type, GLsizei stride, GLsizei count, const GLvoid *pointer); +#endif + +#ifndef GL_EXT_misc_attribute +#define GL_EXT_misc_attribute 1 +#endif + +#ifndef GL_SGIS_generate_mipmap +#define GL_SGIS_generate_mipmap 1 +#endif + +#ifndef GL_SGIX_clipmap +#define GL_SGIX_clipmap 1 +#endif + +#ifndef GL_SGIX_shadow +#define GL_SGIX_shadow 1 +#endif + +#ifndef GL_SGIS_texture_edge_clamp +#define GL_SGIS_texture_edge_clamp 1 +#endif + +#ifndef GL_SGIS_texture_border_clamp +#define GL_SGIS_texture_border_clamp 1 +#endif + +#ifndef GL_EXT_blend_minmax +#define GL_EXT_blend_minmax 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glBlendEquationEXT (GLenum); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLBLENDEQUATIONEXTPROC) (GLenum mode); +#endif + +#ifndef GL_EXT_blend_subtract +#define GL_EXT_blend_subtract 1 +#endif + +#ifndef GL_EXT_blend_logic_op +#define GL_EXT_blend_logic_op 1 +#endif + +#ifndef GL_SGIX_interlace +#define GL_SGIX_interlace 1 +#endif + +#ifndef GL_SGIX_pixel_tiles +#define GL_SGIX_pixel_tiles 1 +#endif + +#ifndef GL_SGIX_texture_select +#define GL_SGIX_texture_select 1 +#endif + +#ifndef GL_SGIX_sprite +#define GL_SGIX_sprite 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glSpriteParameterfSGIX (GLenum, GLfloat); +GLAPI void APIENTRY glSpriteParameterfvSGIX (GLenum, const GLfloat *); +GLAPI void APIENTRY glSpriteParameteriSGIX (GLenum, GLint); +GLAPI void APIENTRY glSpriteParameterivSGIX (GLenum, const GLint *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLSPRITEPARAMETERFSGIXPROC) (GLenum pname, GLfloat param); +typedef void (APIENTRYP PFNGLSPRITEPARAMETERFVSGIXPROC) (GLenum pname, const GLfloat *params); +typedef void (APIENTRYP PFNGLSPRITEPARAMETERISGIXPROC) (GLenum pname, GLint param); +typedef void (APIENTRYP PFNGLSPRITEPARAMETERIVSGIXPROC) (GLenum pname, const GLint *params); +#endif + +#ifndef GL_SGIX_texture_multi_buffer +#define GL_SGIX_texture_multi_buffer 1 +#endif + +#ifndef GL_EXT_point_parameters +#define GL_EXT_point_parameters 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glPointParameterfEXT (GLenum, GLfloat); +GLAPI void APIENTRY glPointParameterfvEXT (GLenum, const GLfloat *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLPOINTPARAMETERFEXTPROC) (GLenum pname, GLfloat param); +typedef void (APIENTRYP PFNGLPOINTPARAMETERFVEXTPROC) (GLenum pname, const GLfloat *params); +#endif + +#ifndef GL_SGIS_point_parameters +#define GL_SGIS_point_parameters 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glPointParameterfSGIS (GLenum, GLfloat); +GLAPI void APIENTRY glPointParameterfvSGIS (GLenum, const GLfloat *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLPOINTPARAMETERFSGISPROC) (GLenum pname, GLfloat param); +typedef void (APIENTRYP PFNGLPOINTPARAMETERFVSGISPROC) (GLenum pname, const GLfloat *params); +#endif + +#ifndef GL_SGIX_instruments +#define GL_SGIX_instruments 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI GLint APIENTRY glGetInstrumentsSGIX (void); +GLAPI void APIENTRY glInstrumentsBufferSGIX (GLsizei, GLint *); +GLAPI GLint APIENTRY glPollInstrumentsSGIX (GLint *); +GLAPI void APIENTRY glReadInstrumentsSGIX (GLint); +GLAPI void APIENTRY glStartInstrumentsSGIX (void); +GLAPI void APIENTRY glStopInstrumentsSGIX (GLint); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef GLint (APIENTRYP PFNGLGETINSTRUMENTSSGIXPROC) (void); +typedef void (APIENTRYP PFNGLINSTRUMENTSBUFFERSGIXPROC) (GLsizei size, GLint *buffer); +typedef GLint (APIENTRYP PFNGLPOLLINSTRUMENTSSGIXPROC) (GLint *marker_p); +typedef void (APIENTRYP PFNGLREADINSTRUMENTSSGIXPROC) (GLint marker); +typedef void (APIENTRYP PFNGLSTARTINSTRUMENTSSGIXPROC) (void); +typedef void (APIENTRYP PFNGLSTOPINSTRUMENTSSGIXPROC) (GLint marker); +#endif + +#ifndef GL_SGIX_texture_scale_bias +#define GL_SGIX_texture_scale_bias 1 +#endif + +#ifndef GL_SGIX_framezoom +#define GL_SGIX_framezoom 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glFrameZoomSGIX (GLint); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLFRAMEZOOMSGIXPROC) (GLint factor); +#endif + +#ifndef GL_SGIX_tag_sample_buffer +#define GL_SGIX_tag_sample_buffer 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glTagSampleBufferSGIX (void); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLTAGSAMPLEBUFFERSGIXPROC) (void); +#endif + +#ifndef GL_SGIX_polynomial_ffd +#define GL_SGIX_polynomial_ffd 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glDeformationMap3dSGIX (GLenum, GLdouble, GLdouble, GLint, GLint, GLdouble, GLdouble, GLint, GLint, GLdouble, GLdouble, GLint, GLint, const GLdouble *); +GLAPI void APIENTRY glDeformationMap3fSGIX (GLenum, GLfloat, GLfloat, GLint, GLint, GLfloat, GLfloat, GLint, GLint, GLfloat, GLfloat, GLint, GLint, const GLfloat *); +GLAPI void APIENTRY glDeformSGIX (GLbitfield); +GLAPI void APIENTRY glLoadIdentityDeformationMapSGIX (GLbitfield); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLDEFORMATIONMAP3DSGIXPROC) (GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, GLdouble w1, GLdouble w2, GLint wstride, GLint worder, const GLdouble *points); +typedef void (APIENTRYP PFNGLDEFORMATIONMAP3FSGIXPROC) (GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, GLfloat w1, GLfloat w2, GLint wstride, GLint worder, const GLfloat *points); +typedef void (APIENTRYP PFNGLDEFORMSGIXPROC) (GLbitfield mask); +typedef void (APIENTRYP PFNGLLOADIDENTITYDEFORMATIONMAPSGIXPROC) (GLbitfield mask); +#endif + +#ifndef GL_SGIX_reference_plane +#define GL_SGIX_reference_plane 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glReferencePlaneSGIX (const GLdouble *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLREFERENCEPLANESGIXPROC) (const GLdouble *equation); +#endif + +#ifndef GL_SGIX_flush_raster +#define GL_SGIX_flush_raster 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glFlushRasterSGIX (void); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLFLUSHRASTERSGIXPROC) (void); +#endif + +#ifndef GL_SGIX_depth_texture +#define GL_SGIX_depth_texture 1 +#endif + +#ifndef GL_SGIS_fog_function +#define GL_SGIS_fog_function 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glFogFuncSGIS (GLsizei, const GLfloat *); +GLAPI void APIENTRY glGetFogFuncSGIS (GLfloat *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLFOGFUNCSGISPROC) (GLsizei n, const GLfloat *points); +typedef void (APIENTRYP PFNGLGETFOGFUNCSGISPROC) (GLfloat *points); +#endif + +#ifndef GL_SGIX_fog_offset +#define GL_SGIX_fog_offset 1 +#endif + +#ifndef GL_HP_image_transform +#define GL_HP_image_transform 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glImageTransformParameteriHP (GLenum, GLenum, GLint); +GLAPI void APIENTRY glImageTransformParameterfHP (GLenum, GLenum, GLfloat); +GLAPI void APIENTRY glImageTransformParameterivHP (GLenum, GLenum, const GLint *); +GLAPI void APIENTRY glImageTransformParameterfvHP (GLenum, GLenum, const GLfloat *); +GLAPI void APIENTRY glGetImageTransformParameterivHP (GLenum, GLenum, GLint *); +GLAPI void APIENTRY glGetImageTransformParameterfvHP (GLenum, GLenum, GLfloat *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLIMAGETRANSFORMPARAMETERIHPPROC) (GLenum target, GLenum pname, GLint param); +typedef void (APIENTRYP PFNGLIMAGETRANSFORMPARAMETERFHPPROC) (GLenum target, GLenum pname, GLfloat param); +typedef void (APIENTRYP PFNGLIMAGETRANSFORMPARAMETERIVHPPROC) (GLenum target, GLenum pname, const GLint *params); +typedef void (APIENTRYP PFNGLIMAGETRANSFORMPARAMETERFVHPPROC) (GLenum target, GLenum pname, const GLfloat *params); +typedef void (APIENTRYP PFNGLGETIMAGETRANSFORMPARAMETERIVHPPROC) (GLenum target, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLGETIMAGETRANSFORMPARAMETERFVHPPROC) (GLenum target, GLenum pname, GLfloat *params); +#endif + +#ifndef GL_HP_convolution_border_modes +#define GL_HP_convolution_border_modes 1 +#endif + +#ifndef GL_SGIX_texture_add_env +#define GL_SGIX_texture_add_env 1 +#endif + +#ifndef GL_EXT_color_subtable +#define GL_EXT_color_subtable 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glColorSubTableEXT (GLenum, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *); +GLAPI void APIENTRY glCopyColorSubTableEXT (GLenum, GLsizei, GLint, GLint, GLsizei); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLCOLORSUBTABLEEXTPROC) (GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum type, const GLvoid *data); +typedef void (APIENTRYP PFNGLCOPYCOLORSUBTABLEEXTPROC) (GLenum target, GLsizei start, GLint x, GLint y, GLsizei width); +#endif + +#ifndef GL_PGI_vertex_hints +#define GL_PGI_vertex_hints 1 +#endif + +#ifndef GL_PGI_misc_hints +#define GL_PGI_misc_hints 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glHintPGI (GLenum, GLint); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLHINTPGIPROC) (GLenum target, GLint mode); +#endif + +#ifndef GL_EXT_paletted_texture +#define GL_EXT_paletted_texture 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glColorTableEXT (GLenum, GLenum, GLsizei, GLenum, GLenum, const GLvoid *); +GLAPI void APIENTRY glGetColorTableEXT (GLenum, GLenum, GLenum, GLvoid *); +GLAPI void APIENTRY glGetColorTableParameterivEXT (GLenum, GLenum, GLint *); +GLAPI void APIENTRY glGetColorTableParameterfvEXT (GLenum, GLenum, GLfloat *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLCOLORTABLEEXTPROC) (GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum type, const GLvoid *table); +typedef void (APIENTRYP PFNGLGETCOLORTABLEEXTPROC) (GLenum target, GLenum format, GLenum type, GLvoid *data); +typedef void (APIENTRYP PFNGLGETCOLORTABLEPARAMETERIVEXTPROC) (GLenum target, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLGETCOLORTABLEPARAMETERFVEXTPROC) (GLenum target, GLenum pname, GLfloat *params); +#endif + +#ifndef GL_EXT_clip_volume_hint +#define GL_EXT_clip_volume_hint 1 +#endif + +#ifndef GL_SGIX_list_priority +#define GL_SGIX_list_priority 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glGetListParameterfvSGIX (GLuint, GLenum, GLfloat *); +GLAPI void APIENTRY glGetListParameterivSGIX (GLuint, GLenum, GLint *); +GLAPI void APIENTRY glListParameterfSGIX (GLuint, GLenum, GLfloat); +GLAPI void APIENTRY glListParameterfvSGIX (GLuint, GLenum, const GLfloat *); +GLAPI void APIENTRY glListParameteriSGIX (GLuint, GLenum, GLint); +GLAPI void APIENTRY glListParameterivSGIX (GLuint, GLenum, const GLint *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLGETLISTPARAMETERFVSGIXPROC) (GLuint list, GLenum pname, GLfloat *params); +typedef void (APIENTRYP PFNGLGETLISTPARAMETERIVSGIXPROC) (GLuint list, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLLISTPARAMETERFSGIXPROC) (GLuint list, GLenum pname, GLfloat param); +typedef void (APIENTRYP PFNGLLISTPARAMETERFVSGIXPROC) (GLuint list, GLenum pname, const GLfloat *params); +typedef void (APIENTRYP PFNGLLISTPARAMETERISGIXPROC) (GLuint list, GLenum pname, GLint param); +typedef void (APIENTRYP PFNGLLISTPARAMETERIVSGIXPROC) (GLuint list, GLenum pname, const GLint *params); +#endif + +#ifndef GL_SGIX_ir_instrument1 +#define GL_SGIX_ir_instrument1 1 +#endif + +#ifndef GL_SGIX_calligraphic_fragment +#define GL_SGIX_calligraphic_fragment 1 +#endif + +#ifndef GL_SGIX_texture_lod_bias +#define GL_SGIX_texture_lod_bias 1 +#endif + +#ifndef GL_SGIX_shadow_ambient +#define GL_SGIX_shadow_ambient 1 +#endif + +#ifndef GL_EXT_index_texture +#define GL_EXT_index_texture 1 +#endif + +#ifndef GL_EXT_index_material +#define GL_EXT_index_material 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glIndexMaterialEXT (GLenum, GLenum); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLINDEXMATERIALEXTPROC) (GLenum face, GLenum mode); +#endif + +#ifndef GL_EXT_index_func +#define GL_EXT_index_func 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glIndexFuncEXT (GLenum, GLclampf); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLINDEXFUNCEXTPROC) (GLenum func, GLclampf ref); +#endif + +#ifndef GL_EXT_index_array_formats +#define GL_EXT_index_array_formats 1 +#endif + +#ifndef GL_EXT_compiled_vertex_array +#define GL_EXT_compiled_vertex_array 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glLockArraysEXT (GLint, GLsizei); +GLAPI void APIENTRY glUnlockArraysEXT (void); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLLOCKARRAYSEXTPROC) (GLint first, GLsizei count); +typedef void (APIENTRYP PFNGLUNLOCKARRAYSEXTPROC) (void); +#endif + +#ifndef GL_EXT_cull_vertex +#define GL_EXT_cull_vertex 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glCullParameterdvEXT (GLenum, GLdouble *); +GLAPI void APIENTRY glCullParameterfvEXT (GLenum, GLfloat *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLCULLPARAMETERDVEXTPROC) (GLenum pname, GLdouble *params); +typedef void (APIENTRYP PFNGLCULLPARAMETERFVEXTPROC) (GLenum pname, GLfloat *params); +#endif + +#ifndef GL_SGIX_ycrcb +#define GL_SGIX_ycrcb 1 +#endif + +#ifndef GL_SGIX_fragment_lighting +#define GL_SGIX_fragment_lighting 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glFragmentColorMaterialSGIX (GLenum, GLenum); +GLAPI void APIENTRY glFragmentLightfSGIX (GLenum, GLenum, GLfloat); +GLAPI void APIENTRY glFragmentLightfvSGIX (GLenum, GLenum, const GLfloat *); +GLAPI void APIENTRY glFragmentLightiSGIX (GLenum, GLenum, GLint); +GLAPI void APIENTRY glFragmentLightivSGIX (GLenum, GLenum, const GLint *); +GLAPI void APIENTRY glFragmentLightModelfSGIX (GLenum, GLfloat); +GLAPI void APIENTRY glFragmentLightModelfvSGIX (GLenum, const GLfloat *); +GLAPI void APIENTRY glFragmentLightModeliSGIX (GLenum, GLint); +GLAPI void APIENTRY glFragmentLightModelivSGIX (GLenum, const GLint *); +GLAPI void APIENTRY glFragmentMaterialfSGIX (GLenum, GLenum, GLfloat); +GLAPI void APIENTRY glFragmentMaterialfvSGIX (GLenum, GLenum, const GLfloat *); +GLAPI void APIENTRY glFragmentMaterialiSGIX (GLenum, GLenum, GLint); +GLAPI void APIENTRY glFragmentMaterialivSGIX (GLenum, GLenum, const GLint *); +GLAPI void APIENTRY glGetFragmentLightfvSGIX (GLenum, GLenum, GLfloat *); +GLAPI void APIENTRY glGetFragmentLightivSGIX (GLenum, GLenum, GLint *); +GLAPI void APIENTRY glGetFragmentMaterialfvSGIX (GLenum, GLenum, GLfloat *); +GLAPI void APIENTRY glGetFragmentMaterialivSGIX (GLenum, GLenum, GLint *); +GLAPI void APIENTRY glLightEnviSGIX (GLenum, GLint); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLFRAGMENTCOLORMATERIALSGIXPROC) (GLenum face, GLenum mode); +typedef void (APIENTRYP PFNGLFRAGMENTLIGHTFSGIXPROC) (GLenum light, GLenum pname, GLfloat param); +typedef void (APIENTRYP PFNGLFRAGMENTLIGHTFVSGIXPROC) (GLenum light, GLenum pname, const GLfloat *params); +typedef void (APIENTRYP PFNGLFRAGMENTLIGHTISGIXPROC) (GLenum light, GLenum pname, GLint param); +typedef void (APIENTRYP PFNGLFRAGMENTLIGHTIVSGIXPROC) (GLenum light, GLenum pname, const GLint *params); +typedef void (APIENTRYP PFNGLFRAGMENTLIGHTMODELFSGIXPROC) (GLenum pname, GLfloat param); +typedef void (APIENTRYP PFNGLFRAGMENTLIGHTMODELFVSGIXPROC) (GLenum pname, const GLfloat *params); +typedef void (APIENTRYP PFNGLFRAGMENTLIGHTMODELISGIXPROC) (GLenum pname, GLint param); +typedef void (APIENTRYP PFNGLFRAGMENTLIGHTMODELIVSGIXPROC) (GLenum pname, const GLint *params); +typedef void (APIENTRYP PFNGLFRAGMENTMATERIALFSGIXPROC) (GLenum face, GLenum pname, GLfloat param); +typedef void (APIENTRYP PFNGLFRAGMENTMATERIALFVSGIXPROC) (GLenum face, GLenum pname, const GLfloat *params); +typedef void (APIENTRYP PFNGLFRAGMENTMATERIALISGIXPROC) (GLenum face, GLenum pname, GLint param); +typedef void (APIENTRYP PFNGLFRAGMENTMATERIALIVSGIXPROC) (GLenum face, GLenum pname, const GLint *params); +typedef void (APIENTRYP PFNGLGETFRAGMENTLIGHTFVSGIXPROC) (GLenum light, GLenum pname, GLfloat *params); +typedef void (APIENTRYP PFNGLGETFRAGMENTLIGHTIVSGIXPROC) (GLenum light, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLGETFRAGMENTMATERIALFVSGIXPROC) (GLenum face, GLenum pname, GLfloat *params); +typedef void (APIENTRYP PFNGLGETFRAGMENTMATERIALIVSGIXPROC) (GLenum face, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLLIGHTENVISGIXPROC) (GLenum pname, GLint param); +#endif + +#ifndef GL_IBM_rasterpos_clip +#define GL_IBM_rasterpos_clip 1 +#endif + +#ifndef GL_HP_texture_lighting +#define GL_HP_texture_lighting 1 +#endif + +#ifndef GL_EXT_draw_range_elements +#define GL_EXT_draw_range_elements 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glDrawRangeElementsEXT (GLenum, GLuint, GLuint, GLsizei, GLenum, const GLvoid *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLDRAWRANGEELEMENTSEXTPROC) (GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices); +#endif + +#ifndef GL_WIN_phong_shading +#define GL_WIN_phong_shading 1 +#endif + +#ifndef GL_WIN_specular_fog +#define GL_WIN_specular_fog 1 +#endif + +#ifndef GL_EXT_light_texture +#define GL_EXT_light_texture 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glApplyTextureEXT (GLenum); +GLAPI void APIENTRY glTextureLightEXT (GLenum); +GLAPI void APIENTRY glTextureMaterialEXT (GLenum, GLenum); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLAPPLYTEXTUREEXTPROC) (GLenum mode); +typedef void (APIENTRYP PFNGLTEXTURELIGHTEXTPROC) (GLenum pname); +typedef void (APIENTRYP PFNGLTEXTUREMATERIALEXTPROC) (GLenum face, GLenum mode); +#endif + +#ifndef GL_SGIX_blend_alpha_minmax +#define GL_SGIX_blend_alpha_minmax 1 +#endif + +#ifndef GL_EXT_bgra +#define GL_EXT_bgra 1 +#endif + +#ifndef GL_SGIX_async +#define GL_SGIX_async 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glAsyncMarkerSGIX (GLuint); +GLAPI GLint APIENTRY glFinishAsyncSGIX (GLuint *); +GLAPI GLint APIENTRY glPollAsyncSGIX (GLuint *); +GLAPI GLuint APIENTRY glGenAsyncMarkersSGIX (GLsizei); +GLAPI void APIENTRY glDeleteAsyncMarkersSGIX (GLuint, GLsizei); +GLAPI GLboolean APIENTRY glIsAsyncMarkerSGIX (GLuint); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLASYNCMARKERSGIXPROC) (GLuint marker); +typedef GLint (APIENTRYP PFNGLFINISHASYNCSGIXPROC) (GLuint *markerp); +typedef GLint (APIENTRYP PFNGLPOLLASYNCSGIXPROC) (GLuint *markerp); +typedef GLuint (APIENTRYP PFNGLGENASYNCMARKERSSGIXPROC) (GLsizei range); +typedef void (APIENTRYP PFNGLDELETEASYNCMARKERSSGIXPROC) (GLuint marker, GLsizei range); +typedef GLboolean (APIENTRYP PFNGLISASYNCMARKERSGIXPROC) (GLuint marker); +#endif + +#ifndef GL_SGIX_async_pixel +#define GL_SGIX_async_pixel 1 +#endif + +#ifndef GL_SGIX_async_histogram +#define GL_SGIX_async_histogram 1 +#endif + +#ifndef GL_INTEL_parallel_arrays +#define GL_INTEL_parallel_arrays 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glVertexPointervINTEL (GLint, GLenum, const GLvoid* *); +GLAPI void APIENTRY glNormalPointervINTEL (GLenum, const GLvoid* *); +GLAPI void APIENTRY glColorPointervINTEL (GLint, GLenum, const GLvoid* *); +GLAPI void APIENTRY glTexCoordPointervINTEL (GLint, GLenum, const GLvoid* *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLVERTEXPOINTERVINTELPROC) (GLint size, GLenum type, const GLvoid* *pointer); +typedef void (APIENTRYP PFNGLNORMALPOINTERVINTELPROC) (GLenum type, const GLvoid* *pointer); +typedef void (APIENTRYP PFNGLCOLORPOINTERVINTELPROC) (GLint size, GLenum type, const GLvoid* *pointer); +typedef void (APIENTRYP PFNGLTEXCOORDPOINTERVINTELPROC) (GLint size, GLenum type, const GLvoid* *pointer); +#endif + +#ifndef GL_HP_occlusion_test +#define GL_HP_occlusion_test 1 +#endif + +#ifndef GL_EXT_pixel_transform +#define GL_EXT_pixel_transform 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glPixelTransformParameteriEXT (GLenum, GLenum, GLint); +GLAPI void APIENTRY glPixelTransformParameterfEXT (GLenum, GLenum, GLfloat); +GLAPI void APIENTRY glPixelTransformParameterivEXT (GLenum, GLenum, const GLint *); +GLAPI void APIENTRY glPixelTransformParameterfvEXT (GLenum, GLenum, const GLfloat *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLPIXELTRANSFORMPARAMETERIEXTPROC) (GLenum target, GLenum pname, GLint param); +typedef void (APIENTRYP PFNGLPIXELTRANSFORMPARAMETERFEXTPROC) (GLenum target, GLenum pname, GLfloat param); +typedef void (APIENTRYP PFNGLPIXELTRANSFORMPARAMETERIVEXTPROC) (GLenum target, GLenum pname, const GLint *params); +typedef void (APIENTRYP PFNGLPIXELTRANSFORMPARAMETERFVEXTPROC) (GLenum target, GLenum pname, const GLfloat *params); +#endif + +#ifndef GL_EXT_pixel_transform_color_table +#define GL_EXT_pixel_transform_color_table 1 +#endif + +#ifndef GL_EXT_shared_texture_palette +#define GL_EXT_shared_texture_palette 1 +#endif + +#ifndef GL_EXT_separate_specular_color +#define GL_EXT_separate_specular_color 1 +#endif + +#ifndef GL_EXT_secondary_color +#define GL_EXT_secondary_color 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glSecondaryColor3bEXT (GLbyte, GLbyte, GLbyte); +GLAPI void APIENTRY glSecondaryColor3bvEXT (const GLbyte *); +GLAPI void APIENTRY glSecondaryColor3dEXT (GLdouble, GLdouble, GLdouble); +GLAPI void APIENTRY glSecondaryColor3dvEXT (const GLdouble *); +GLAPI void APIENTRY glSecondaryColor3fEXT (GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glSecondaryColor3fvEXT (const GLfloat *); +GLAPI void APIENTRY glSecondaryColor3iEXT (GLint, GLint, GLint); +GLAPI void APIENTRY glSecondaryColor3ivEXT (const GLint *); +GLAPI void APIENTRY glSecondaryColor3sEXT (GLshort, GLshort, GLshort); +GLAPI void APIENTRY glSecondaryColor3svEXT (const GLshort *); +GLAPI void APIENTRY glSecondaryColor3ubEXT (GLubyte, GLubyte, GLubyte); +GLAPI void APIENTRY glSecondaryColor3ubvEXT (const GLubyte *); +GLAPI void APIENTRY glSecondaryColor3uiEXT (GLuint, GLuint, GLuint); +GLAPI void APIENTRY glSecondaryColor3uivEXT (const GLuint *); +GLAPI void APIENTRY glSecondaryColor3usEXT (GLushort, GLushort, GLushort); +GLAPI void APIENTRY glSecondaryColor3usvEXT (const GLushort *); +GLAPI void APIENTRY glSecondaryColorPointerEXT (GLint, GLenum, GLsizei, const GLvoid *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLSECONDARYCOLOR3BEXTPROC) (GLbyte red, GLbyte green, GLbyte blue); +typedef void (APIENTRYP PFNGLSECONDARYCOLOR3BVEXTPROC) (const GLbyte *v); +typedef void (APIENTRYP PFNGLSECONDARYCOLOR3DEXTPROC) (GLdouble red, GLdouble green, GLdouble blue); +typedef void (APIENTRYP PFNGLSECONDARYCOLOR3DVEXTPROC) (const GLdouble *v); +typedef void (APIENTRYP PFNGLSECONDARYCOLOR3FEXTPROC) (GLfloat red, GLfloat green, GLfloat blue); +typedef void (APIENTRYP PFNGLSECONDARYCOLOR3FVEXTPROC) (const GLfloat *v); +typedef void (APIENTRYP PFNGLSECONDARYCOLOR3IEXTPROC) (GLint red, GLint green, GLint blue); +typedef void (APIENTRYP PFNGLSECONDARYCOLOR3IVEXTPROC) (const GLint *v); +typedef void (APIENTRYP PFNGLSECONDARYCOLOR3SEXTPROC) (GLshort red, GLshort green, GLshort blue); +typedef void (APIENTRYP PFNGLSECONDARYCOLOR3SVEXTPROC) (const GLshort *v); +typedef void (APIENTRYP PFNGLSECONDARYCOLOR3UBEXTPROC) (GLubyte red, GLubyte green, GLubyte blue); +typedef void (APIENTRYP PFNGLSECONDARYCOLOR3UBVEXTPROC) (const GLubyte *v); +typedef void (APIENTRYP PFNGLSECONDARYCOLOR3UIEXTPROC) (GLuint red, GLuint green, GLuint blue); +typedef void (APIENTRYP PFNGLSECONDARYCOLOR3UIVEXTPROC) (const GLuint *v); +typedef void (APIENTRYP PFNGLSECONDARYCOLOR3USEXTPROC) (GLushort red, GLushort green, GLushort blue); +typedef void (APIENTRYP PFNGLSECONDARYCOLOR3USVEXTPROC) (const GLushort *v); +typedef void (APIENTRYP PFNGLSECONDARYCOLORPOINTEREXTPROC) (GLint size, GLenum type, GLsizei stride, const GLvoid *pointer); +#endif + +#ifndef GL_EXT_texture_perturb_normal +#define GL_EXT_texture_perturb_normal 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glTextureNormalEXT (GLenum); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLTEXTURENORMALEXTPROC) (GLenum mode); +#endif + +#ifndef GL_EXT_multi_draw_arrays +#define GL_EXT_multi_draw_arrays 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glMultiDrawArraysEXT (GLenum, GLint *, GLsizei *, GLsizei); +GLAPI void APIENTRY glMultiDrawElementsEXT (GLenum, const GLsizei *, GLenum, const GLvoid* *, GLsizei); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLMULTIDRAWARRAYSEXTPROC) (GLenum mode, GLint *first, GLsizei *count, GLsizei primcount); +typedef void (APIENTRYP PFNGLMULTIDRAWELEMENTSEXTPROC) (GLenum mode, const GLsizei *count, GLenum type, const GLvoid* *indices, GLsizei primcount); +#endif + +#ifndef GL_EXT_fog_coord +#define GL_EXT_fog_coord 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glFogCoordfEXT (GLfloat); +GLAPI void APIENTRY glFogCoordfvEXT (const GLfloat *); +GLAPI void APIENTRY glFogCoorddEXT (GLdouble); +GLAPI void APIENTRY glFogCoorddvEXT (const GLdouble *); +GLAPI void APIENTRY glFogCoordPointerEXT (GLenum, GLsizei, const GLvoid *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLFOGCOORDFEXTPROC) (GLfloat coord); +typedef void (APIENTRYP PFNGLFOGCOORDFVEXTPROC) (const GLfloat *coord); +typedef void (APIENTRYP PFNGLFOGCOORDDEXTPROC) (GLdouble coord); +typedef void (APIENTRYP PFNGLFOGCOORDDVEXTPROC) (const GLdouble *coord); +typedef void (APIENTRYP PFNGLFOGCOORDPOINTEREXTPROC) (GLenum type, GLsizei stride, const GLvoid *pointer); +#endif + +#ifndef GL_REND_screen_coordinates +#define GL_REND_screen_coordinates 1 +#endif + +#ifndef GL_EXT_coordinate_frame +#define GL_EXT_coordinate_frame 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glTangent3bEXT (GLbyte, GLbyte, GLbyte); +GLAPI void APIENTRY glTangent3bvEXT (const GLbyte *); +GLAPI void APIENTRY glTangent3dEXT (GLdouble, GLdouble, GLdouble); +GLAPI void APIENTRY glTangent3dvEXT (const GLdouble *); +GLAPI void APIENTRY glTangent3fEXT (GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glTangent3fvEXT (const GLfloat *); +GLAPI void APIENTRY glTangent3iEXT (GLint, GLint, GLint); +GLAPI void APIENTRY glTangent3ivEXT (const GLint *); +GLAPI void APIENTRY glTangent3sEXT (GLshort, GLshort, GLshort); +GLAPI void APIENTRY glTangent3svEXT (const GLshort *); +GLAPI void APIENTRY glBinormal3bEXT (GLbyte, GLbyte, GLbyte); +GLAPI void APIENTRY glBinormal3bvEXT (const GLbyte *); +GLAPI void APIENTRY glBinormal3dEXT (GLdouble, GLdouble, GLdouble); +GLAPI void APIENTRY glBinormal3dvEXT (const GLdouble *); +GLAPI void APIENTRY glBinormal3fEXT (GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glBinormal3fvEXT (const GLfloat *); +GLAPI void APIENTRY glBinormal3iEXT (GLint, GLint, GLint); +GLAPI void APIENTRY glBinormal3ivEXT (const GLint *); +GLAPI void APIENTRY glBinormal3sEXT (GLshort, GLshort, GLshort); +GLAPI void APIENTRY glBinormal3svEXT (const GLshort *); +GLAPI void APIENTRY glTangentPointerEXT (GLenum, GLsizei, const GLvoid *); +GLAPI void APIENTRY glBinormalPointerEXT (GLenum, GLsizei, const GLvoid *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLTANGENT3BEXTPROC) (GLbyte tx, GLbyte ty, GLbyte tz); +typedef void (APIENTRYP PFNGLTANGENT3BVEXTPROC) (const GLbyte *v); +typedef void (APIENTRYP PFNGLTANGENT3DEXTPROC) (GLdouble tx, GLdouble ty, GLdouble tz); +typedef void (APIENTRYP PFNGLTANGENT3DVEXTPROC) (const GLdouble *v); +typedef void (APIENTRYP PFNGLTANGENT3FEXTPROC) (GLfloat tx, GLfloat ty, GLfloat tz); +typedef void (APIENTRYP PFNGLTANGENT3FVEXTPROC) (const GLfloat *v); +typedef void (APIENTRYP PFNGLTANGENT3IEXTPROC) (GLint tx, GLint ty, GLint tz); +typedef void (APIENTRYP PFNGLTANGENT3IVEXTPROC) (const GLint *v); +typedef void (APIENTRYP PFNGLTANGENT3SEXTPROC) (GLshort tx, GLshort ty, GLshort tz); +typedef void (APIENTRYP PFNGLTANGENT3SVEXTPROC) (const GLshort *v); +typedef void (APIENTRYP PFNGLBINORMAL3BEXTPROC) (GLbyte bx, GLbyte by, GLbyte bz); +typedef void (APIENTRYP PFNGLBINORMAL3BVEXTPROC) (const GLbyte *v); +typedef void (APIENTRYP PFNGLBINORMAL3DEXTPROC) (GLdouble bx, GLdouble by, GLdouble bz); +typedef void (APIENTRYP PFNGLBINORMAL3DVEXTPROC) (const GLdouble *v); +typedef void (APIENTRYP PFNGLBINORMAL3FEXTPROC) (GLfloat bx, GLfloat by, GLfloat bz); +typedef void (APIENTRYP PFNGLBINORMAL3FVEXTPROC) (const GLfloat *v); +typedef void (APIENTRYP PFNGLBINORMAL3IEXTPROC) (GLint bx, GLint by, GLint bz); +typedef void (APIENTRYP PFNGLBINORMAL3IVEXTPROC) (const GLint *v); +typedef void (APIENTRYP PFNGLBINORMAL3SEXTPROC) (GLshort bx, GLshort by, GLshort bz); +typedef void (APIENTRYP PFNGLBINORMAL3SVEXTPROC) (const GLshort *v); +typedef void (APIENTRYP PFNGLTANGENTPOINTEREXTPROC) (GLenum type, GLsizei stride, const GLvoid *pointer); +typedef void (APIENTRYP PFNGLBINORMALPOINTEREXTPROC) (GLenum type, GLsizei stride, const GLvoid *pointer); +#endif + +#ifndef GL_EXT_texture_env_combine +#define GL_EXT_texture_env_combine 1 +#endif + +#ifndef GL_APPLE_specular_vector +#define GL_APPLE_specular_vector 1 +#endif + +#ifndef GL_APPLE_transform_hint +#define GL_APPLE_transform_hint 1 +#endif + +#ifndef GL_SGIX_fog_scale +#define GL_SGIX_fog_scale 1 +#endif + +#ifndef GL_SUNX_constant_data +#define GL_SUNX_constant_data 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glFinishTextureSUNX (void); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLFINISHTEXTURESUNXPROC) (void); +#endif + +#ifndef GL_SUN_global_alpha +#define GL_SUN_global_alpha 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glGlobalAlphaFactorbSUN (GLbyte); +GLAPI void APIENTRY glGlobalAlphaFactorsSUN (GLshort); +GLAPI void APIENTRY glGlobalAlphaFactoriSUN (GLint); +GLAPI void APIENTRY glGlobalAlphaFactorfSUN (GLfloat); +GLAPI void APIENTRY glGlobalAlphaFactordSUN (GLdouble); +GLAPI void APIENTRY glGlobalAlphaFactorubSUN (GLubyte); +GLAPI void APIENTRY glGlobalAlphaFactorusSUN (GLushort); +GLAPI void APIENTRY glGlobalAlphaFactoruiSUN (GLuint); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLGLOBALALPHAFACTORBSUNPROC) (GLbyte factor); +typedef void (APIENTRYP PFNGLGLOBALALPHAFACTORSSUNPROC) (GLshort factor); +typedef void (APIENTRYP PFNGLGLOBALALPHAFACTORISUNPROC) (GLint factor); +typedef void (APIENTRYP PFNGLGLOBALALPHAFACTORFSUNPROC) (GLfloat factor); +typedef void (APIENTRYP PFNGLGLOBALALPHAFACTORDSUNPROC) (GLdouble factor); +typedef void (APIENTRYP PFNGLGLOBALALPHAFACTORUBSUNPROC) (GLubyte factor); +typedef void (APIENTRYP PFNGLGLOBALALPHAFACTORUSSUNPROC) (GLushort factor); +typedef void (APIENTRYP PFNGLGLOBALALPHAFACTORUISUNPROC) (GLuint factor); +#endif + +#ifndef GL_SUN_triangle_list +#define GL_SUN_triangle_list 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glReplacementCodeuiSUN (GLuint); +GLAPI void APIENTRY glReplacementCodeusSUN (GLushort); +GLAPI void APIENTRY glReplacementCodeubSUN (GLubyte); +GLAPI void APIENTRY glReplacementCodeuivSUN (const GLuint *); +GLAPI void APIENTRY glReplacementCodeusvSUN (const GLushort *); +GLAPI void APIENTRY glReplacementCodeubvSUN (const GLubyte *); +GLAPI void APIENTRY glReplacementCodePointerSUN (GLenum, GLsizei, const GLvoid* *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLREPLACEMENTCODEUISUNPROC) (GLuint code); +typedef void (APIENTRYP PFNGLREPLACEMENTCODEUSSUNPROC) (GLushort code); +typedef void (APIENTRYP PFNGLREPLACEMENTCODEUBSUNPROC) (GLubyte code); +typedef void (APIENTRYP PFNGLREPLACEMENTCODEUIVSUNPROC) (const GLuint *code); +typedef void (APIENTRYP PFNGLREPLACEMENTCODEUSVSUNPROC) (const GLushort *code); +typedef void (APIENTRYP PFNGLREPLACEMENTCODEUBVSUNPROC) (const GLubyte *code); +typedef void (APIENTRYP PFNGLREPLACEMENTCODEPOINTERSUNPROC) (GLenum type, GLsizei stride, const GLvoid* *pointer); +#endif + +#ifndef GL_SUN_vertex +#define GL_SUN_vertex 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glColor4ubVertex2fSUN (GLubyte, GLubyte, GLubyte, GLubyte, GLfloat, GLfloat); +GLAPI void APIENTRY glColor4ubVertex2fvSUN (const GLubyte *, const GLfloat *); +GLAPI void APIENTRY glColor4ubVertex3fSUN (GLubyte, GLubyte, GLubyte, GLubyte, GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glColor4ubVertex3fvSUN (const GLubyte *, const GLfloat *); +GLAPI void APIENTRY glColor3fVertex3fSUN (GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glColor3fVertex3fvSUN (const GLfloat *, const GLfloat *); +GLAPI void APIENTRY glNormal3fVertex3fSUN (GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glNormal3fVertex3fvSUN (const GLfloat *, const GLfloat *); +GLAPI void APIENTRY glColor4fNormal3fVertex3fSUN (GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glColor4fNormal3fVertex3fvSUN (const GLfloat *, const GLfloat *, const GLfloat *); +GLAPI void APIENTRY glTexCoord2fVertex3fSUN (GLfloat, GLfloat, GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glTexCoord2fVertex3fvSUN (const GLfloat *, const GLfloat *); +GLAPI void APIENTRY glTexCoord4fVertex4fSUN (GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glTexCoord4fVertex4fvSUN (const GLfloat *, const GLfloat *); +GLAPI void APIENTRY glTexCoord2fColor4ubVertex3fSUN (GLfloat, GLfloat, GLubyte, GLubyte, GLubyte, GLubyte, GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glTexCoord2fColor4ubVertex3fvSUN (const GLfloat *, const GLubyte *, const GLfloat *); +GLAPI void APIENTRY glTexCoord2fColor3fVertex3fSUN (GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glTexCoord2fColor3fVertex3fvSUN (const GLfloat *, const GLfloat *, const GLfloat *); +GLAPI void APIENTRY glTexCoord2fNormal3fVertex3fSUN (GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glTexCoord2fNormal3fVertex3fvSUN (const GLfloat *, const GLfloat *, const GLfloat *); +GLAPI void APIENTRY glTexCoord2fColor4fNormal3fVertex3fSUN (GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glTexCoord2fColor4fNormal3fVertex3fvSUN (const GLfloat *, const GLfloat *, const GLfloat *, const GLfloat *); +GLAPI void APIENTRY glTexCoord4fColor4fNormal3fVertex4fSUN (GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glTexCoord4fColor4fNormal3fVertex4fvSUN (const GLfloat *, const GLfloat *, const GLfloat *, const GLfloat *); +GLAPI void APIENTRY glReplacementCodeuiVertex3fSUN (GLuint, GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glReplacementCodeuiVertex3fvSUN (const GLuint *, const GLfloat *); +GLAPI void APIENTRY glReplacementCodeuiColor4ubVertex3fSUN (GLuint, GLubyte, GLubyte, GLubyte, GLubyte, GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glReplacementCodeuiColor4ubVertex3fvSUN (const GLuint *, const GLubyte *, const GLfloat *); +GLAPI void APIENTRY glReplacementCodeuiColor3fVertex3fSUN (GLuint, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glReplacementCodeuiColor3fVertex3fvSUN (const GLuint *, const GLfloat *, const GLfloat *); +GLAPI void APIENTRY glReplacementCodeuiNormal3fVertex3fSUN (GLuint, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glReplacementCodeuiNormal3fVertex3fvSUN (const GLuint *, const GLfloat *, const GLfloat *); +GLAPI void APIENTRY glReplacementCodeuiColor4fNormal3fVertex3fSUN (GLuint, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glReplacementCodeuiColor4fNormal3fVertex3fvSUN (const GLuint *, const GLfloat *, const GLfloat *, const GLfloat *); +GLAPI void APIENTRY glReplacementCodeuiTexCoord2fVertex3fSUN (GLuint, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glReplacementCodeuiTexCoord2fVertex3fvSUN (const GLuint *, const GLfloat *, const GLfloat *); +GLAPI void APIENTRY glReplacementCodeuiTexCoord2fNormal3fVertex3fSUN (GLuint, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glReplacementCodeuiTexCoord2fNormal3fVertex3fvSUN (const GLuint *, const GLfloat *, const GLfloat *, const GLfloat *); +GLAPI void APIENTRY glReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fSUN (GLuint, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fvSUN (const GLuint *, const GLfloat *, const GLfloat *, const GLfloat *, const GLfloat *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLCOLOR4UBVERTEX2FSUNPROC) (GLubyte r, GLubyte g, GLubyte b, GLubyte a, GLfloat x, GLfloat y); +typedef void (APIENTRYP PFNGLCOLOR4UBVERTEX2FVSUNPROC) (const GLubyte *c, const GLfloat *v); +typedef void (APIENTRYP PFNGLCOLOR4UBVERTEX3FSUNPROC) (GLubyte r, GLubyte g, GLubyte b, GLubyte a, GLfloat x, GLfloat y, GLfloat z); +typedef void (APIENTRYP PFNGLCOLOR4UBVERTEX3FVSUNPROC) (const GLubyte *c, const GLfloat *v); +typedef void (APIENTRYP PFNGLCOLOR3FVERTEX3FSUNPROC) (GLfloat r, GLfloat g, GLfloat b, GLfloat x, GLfloat y, GLfloat z); +typedef void (APIENTRYP PFNGLCOLOR3FVERTEX3FVSUNPROC) (const GLfloat *c, const GLfloat *v); +typedef void (APIENTRYP PFNGLNORMAL3FVERTEX3FSUNPROC) (GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z); +typedef void (APIENTRYP PFNGLNORMAL3FVERTEX3FVSUNPROC) (const GLfloat *n, const GLfloat *v); +typedef void (APIENTRYP PFNGLCOLOR4FNORMAL3FVERTEX3FSUNPROC) (GLfloat r, GLfloat g, GLfloat b, GLfloat a, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z); +typedef void (APIENTRYP PFNGLCOLOR4FNORMAL3FVERTEX3FVSUNPROC) (const GLfloat *c, const GLfloat *n, const GLfloat *v); +typedef void (APIENTRYP PFNGLTEXCOORD2FVERTEX3FSUNPROC) (GLfloat s, GLfloat t, GLfloat x, GLfloat y, GLfloat z); +typedef void (APIENTRYP PFNGLTEXCOORD2FVERTEX3FVSUNPROC) (const GLfloat *tc, const GLfloat *v); +typedef void (APIENTRYP PFNGLTEXCOORD4FVERTEX4FSUNPROC) (GLfloat s, GLfloat t, GLfloat p, GLfloat q, GLfloat x, GLfloat y, GLfloat z, GLfloat w); +typedef void (APIENTRYP PFNGLTEXCOORD4FVERTEX4FVSUNPROC) (const GLfloat *tc, const GLfloat *v); +typedef void (APIENTRYP PFNGLTEXCOORD2FCOLOR4UBVERTEX3FSUNPROC) (GLfloat s, GLfloat t, GLubyte r, GLubyte g, GLubyte b, GLubyte a, GLfloat x, GLfloat y, GLfloat z); +typedef void (APIENTRYP PFNGLTEXCOORD2FCOLOR4UBVERTEX3FVSUNPROC) (const GLfloat *tc, const GLubyte *c, const GLfloat *v); +typedef void (APIENTRYP PFNGLTEXCOORD2FCOLOR3FVERTEX3FSUNPROC) (GLfloat s, GLfloat t, GLfloat r, GLfloat g, GLfloat b, GLfloat x, GLfloat y, GLfloat z); +typedef void (APIENTRYP PFNGLTEXCOORD2FCOLOR3FVERTEX3FVSUNPROC) (const GLfloat *tc, const GLfloat *c, const GLfloat *v); +typedef void (APIENTRYP PFNGLTEXCOORD2FNORMAL3FVERTEX3FSUNPROC) (GLfloat s, GLfloat t, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z); +typedef void (APIENTRYP PFNGLTEXCOORD2FNORMAL3FVERTEX3FVSUNPROC) (const GLfloat *tc, const GLfloat *n, const GLfloat *v); +typedef void (APIENTRYP PFNGLTEXCOORD2FCOLOR4FNORMAL3FVERTEX3FSUNPROC) (GLfloat s, GLfloat t, GLfloat r, GLfloat g, GLfloat b, GLfloat a, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z); +typedef void (APIENTRYP PFNGLTEXCOORD2FCOLOR4FNORMAL3FVERTEX3FVSUNPROC) (const GLfloat *tc, const GLfloat *c, const GLfloat *n, const GLfloat *v); +typedef void (APIENTRYP PFNGLTEXCOORD4FCOLOR4FNORMAL3FVERTEX4FSUNPROC) (GLfloat s, GLfloat t, GLfloat p, GLfloat q, GLfloat r, GLfloat g, GLfloat b, GLfloat a, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z, GLfloat w); +typedef void (APIENTRYP PFNGLTEXCOORD4FCOLOR4FNORMAL3FVERTEX4FVSUNPROC) (const GLfloat *tc, const GLfloat *c, const GLfloat *n, const GLfloat *v); +typedef void (APIENTRYP PFNGLREPLACEMENTCODEUIVERTEX3FSUNPROC) (GLuint rc, GLfloat x, GLfloat y, GLfloat z); +typedef void (APIENTRYP PFNGLREPLACEMENTCODEUIVERTEX3FVSUNPROC) (const GLuint *rc, const GLfloat *v); +typedef void (APIENTRYP PFNGLREPLACEMENTCODEUICOLOR4UBVERTEX3FSUNPROC) (GLuint rc, GLubyte r, GLubyte g, GLubyte b, GLubyte a, GLfloat x, GLfloat y, GLfloat z); +typedef void (APIENTRYP PFNGLREPLACEMENTCODEUICOLOR4UBVERTEX3FVSUNPROC) (const GLuint *rc, const GLubyte *c, const GLfloat *v); +typedef void (APIENTRYP PFNGLREPLACEMENTCODEUICOLOR3FVERTEX3FSUNPROC) (GLuint rc, GLfloat r, GLfloat g, GLfloat b, GLfloat x, GLfloat y, GLfloat z); +typedef void (APIENTRYP PFNGLREPLACEMENTCODEUICOLOR3FVERTEX3FVSUNPROC) (const GLuint *rc, const GLfloat *c, const GLfloat *v); +typedef void (APIENTRYP PFNGLREPLACEMENTCODEUINORMAL3FVERTEX3FSUNPROC) (GLuint rc, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z); +typedef void (APIENTRYP PFNGLREPLACEMENTCODEUINORMAL3FVERTEX3FVSUNPROC) (const GLuint *rc, const GLfloat *n, const GLfloat *v); +typedef void (APIENTRYP PFNGLREPLACEMENTCODEUICOLOR4FNORMAL3FVERTEX3FSUNPROC) (GLuint rc, GLfloat r, GLfloat g, GLfloat b, GLfloat a, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z); +typedef void (APIENTRYP PFNGLREPLACEMENTCODEUICOLOR4FNORMAL3FVERTEX3FVSUNPROC) (const GLuint *rc, const GLfloat *c, const GLfloat *n, const GLfloat *v); +typedef void (APIENTRYP PFNGLREPLACEMENTCODEUITEXCOORD2FVERTEX3FSUNPROC) (GLuint rc, GLfloat s, GLfloat t, GLfloat x, GLfloat y, GLfloat z); +typedef void (APIENTRYP PFNGLREPLACEMENTCODEUITEXCOORD2FVERTEX3FVSUNPROC) (const GLuint *rc, const GLfloat *tc, const GLfloat *v); +typedef void (APIENTRYP PFNGLREPLACEMENTCODEUITEXCOORD2FNORMAL3FVERTEX3FSUNPROC) (GLuint rc, GLfloat s, GLfloat t, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z); +typedef void (APIENTRYP PFNGLREPLACEMENTCODEUITEXCOORD2FNORMAL3FVERTEX3FVSUNPROC) (const GLuint *rc, const GLfloat *tc, const GLfloat *n, const GLfloat *v); +typedef void (APIENTRYP PFNGLREPLACEMENTCODEUITEXCOORD2FCOLOR4FNORMAL3FVERTEX3FSUNPROC) (GLuint rc, GLfloat s, GLfloat t, GLfloat r, GLfloat g, GLfloat b, GLfloat a, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z); +typedef void (APIENTRYP PFNGLREPLACEMENTCODEUITEXCOORD2FCOLOR4FNORMAL3FVERTEX3FVSUNPROC) (const GLuint *rc, const GLfloat *tc, const GLfloat *c, const GLfloat *n, const GLfloat *v); +#endif + +#ifndef GL_EXT_blend_func_separate +#define GL_EXT_blend_func_separate 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glBlendFuncSeparateEXT (GLenum, GLenum, GLenum, GLenum); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLBLENDFUNCSEPARATEEXTPROC) (GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha); +#endif + +#ifndef GL_INGR_blend_func_separate +#define GL_INGR_blend_func_separate 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glBlendFuncSeparateINGR (GLenum, GLenum, GLenum, GLenum); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLBLENDFUNCSEPARATEINGRPROC) (GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha); +#endif + +#ifndef GL_INGR_color_clamp +#define GL_INGR_color_clamp 1 +#endif + +#ifndef GL_INGR_interlace_read +#define GL_INGR_interlace_read 1 +#endif + +#ifndef GL_EXT_stencil_wrap +#define GL_EXT_stencil_wrap 1 +#endif + +#ifndef GL_EXT_422_pixels +#define GL_EXT_422_pixels 1 +#endif + +#ifndef GL_NV_texgen_reflection +#define GL_NV_texgen_reflection 1 +#endif + +#ifndef GL_SUN_convolution_border_modes +#define GL_SUN_convolution_border_modes 1 +#endif + +#ifndef GL_EXT_texture_env_add +#define GL_EXT_texture_env_add 1 +#endif + +#ifndef GL_EXT_texture_lod_bias +#define GL_EXT_texture_lod_bias 1 +#endif + +#ifndef GL_EXT_texture_filter_anisotropic +#define GL_EXT_texture_filter_anisotropic 1 +#endif + +#ifndef GL_EXT_vertex_weighting +#define GL_EXT_vertex_weighting 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glVertexWeightfEXT (GLfloat); +GLAPI void APIENTRY glVertexWeightfvEXT (const GLfloat *); +GLAPI void APIENTRY glVertexWeightPointerEXT (GLsizei, GLenum, GLsizei, const GLvoid *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLVERTEXWEIGHTFEXTPROC) (GLfloat weight); +typedef void (APIENTRYP PFNGLVERTEXWEIGHTFVEXTPROC) (const GLfloat *weight); +typedef void (APIENTRYP PFNGLVERTEXWEIGHTPOINTEREXTPROC) (GLsizei size, GLenum type, GLsizei stride, const GLvoid *pointer); +#endif + +#ifndef GL_NV_light_max_exponent +#define GL_NV_light_max_exponent 1 +#endif + +#ifndef GL_NV_vertex_array_range +#define GL_NV_vertex_array_range 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glFlushVertexArrayRangeNV (void); +GLAPI void APIENTRY glVertexArrayRangeNV (GLsizei, const GLvoid *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLFLUSHVERTEXARRAYRANGENVPROC) (void); +typedef void (APIENTRYP PFNGLVERTEXARRAYRANGENVPROC) (GLsizei length, const GLvoid *pointer); +#endif + +#ifndef GL_NV_register_combiners +#define GL_NV_register_combiners 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glCombinerParameterfvNV (GLenum, const GLfloat *); +GLAPI void APIENTRY glCombinerParameterfNV (GLenum, GLfloat); +GLAPI void APIENTRY glCombinerParameterivNV (GLenum, const GLint *); +GLAPI void APIENTRY glCombinerParameteriNV (GLenum, GLint); +GLAPI void APIENTRY glCombinerInputNV (GLenum, GLenum, GLenum, GLenum, GLenum, GLenum); +GLAPI void APIENTRY glCombinerOutputNV (GLenum, GLenum, GLenum, GLenum, GLenum, GLenum, GLenum, GLboolean, GLboolean, GLboolean); +GLAPI void APIENTRY glFinalCombinerInputNV (GLenum, GLenum, GLenum, GLenum); +GLAPI void APIENTRY glGetCombinerInputParameterfvNV (GLenum, GLenum, GLenum, GLenum, GLfloat *); +GLAPI void APIENTRY glGetCombinerInputParameterivNV (GLenum, GLenum, GLenum, GLenum, GLint *); +GLAPI void APIENTRY glGetCombinerOutputParameterfvNV (GLenum, GLenum, GLenum, GLfloat *); +GLAPI void APIENTRY glGetCombinerOutputParameterivNV (GLenum, GLenum, GLenum, GLint *); +GLAPI void APIENTRY glGetFinalCombinerInputParameterfvNV (GLenum, GLenum, GLfloat *); +GLAPI void APIENTRY glGetFinalCombinerInputParameterivNV (GLenum, GLenum, GLint *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLCOMBINERPARAMETERFVNVPROC) (GLenum pname, const GLfloat *params); +typedef void (APIENTRYP PFNGLCOMBINERPARAMETERFNVPROC) (GLenum pname, GLfloat param); +typedef void (APIENTRYP PFNGLCOMBINERPARAMETERIVNVPROC) (GLenum pname, const GLint *params); +typedef void (APIENTRYP PFNGLCOMBINERPARAMETERINVPROC) (GLenum pname, GLint param); +typedef void (APIENTRYP PFNGLCOMBINERINPUTNVPROC) (GLenum stage, GLenum portion, GLenum variable, GLenum input, GLenum mapping, GLenum componentUsage); +typedef void (APIENTRYP PFNGLCOMBINEROUTPUTNVPROC) (GLenum stage, GLenum portion, GLenum abOutput, GLenum cdOutput, GLenum sumOutput, GLenum scale, GLenum bias, GLboolean abDotProduct, GLboolean cdDotProduct, GLboolean muxSum); +typedef void (APIENTRYP PFNGLFINALCOMBINERINPUTNVPROC) (GLenum variable, GLenum input, GLenum mapping, GLenum componentUsage); +typedef void (APIENTRYP PFNGLGETCOMBINERINPUTPARAMETERFVNVPROC) (GLenum stage, GLenum portion, GLenum variable, GLenum pname, GLfloat *params); +typedef void (APIENTRYP PFNGLGETCOMBINERINPUTPARAMETERIVNVPROC) (GLenum stage, GLenum portion, GLenum variable, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLGETCOMBINEROUTPUTPARAMETERFVNVPROC) (GLenum stage, GLenum portion, GLenum pname, GLfloat *params); +typedef void (APIENTRYP PFNGLGETCOMBINEROUTPUTPARAMETERIVNVPROC) (GLenum stage, GLenum portion, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLGETFINALCOMBINERINPUTPARAMETERFVNVPROC) (GLenum variable, GLenum pname, GLfloat *params); +typedef void (APIENTRYP PFNGLGETFINALCOMBINERINPUTPARAMETERIVNVPROC) (GLenum variable, GLenum pname, GLint *params); +#endif + +#ifndef GL_NV_fog_distance +#define GL_NV_fog_distance 1 +#endif + +#ifndef GL_NV_texgen_emboss +#define GL_NV_texgen_emboss 1 +#endif + +#ifndef GL_NV_blend_square +#define GL_NV_blend_square 1 +#endif + +#ifndef GL_NV_texture_env_combine4 +#define GL_NV_texture_env_combine4 1 +#endif + +#ifndef GL_MESA_resize_buffers +#define GL_MESA_resize_buffers 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glResizeBuffersMESA (void); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLRESIZEBUFFERSMESAPROC) (void); +#endif + +#ifndef GL_MESA_window_pos +#define GL_MESA_window_pos 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glWindowPos2dMESA (GLdouble, GLdouble); +GLAPI void APIENTRY glWindowPos2dvMESA (const GLdouble *); +GLAPI void APIENTRY glWindowPos2fMESA (GLfloat, GLfloat); +GLAPI void APIENTRY glWindowPos2fvMESA (const GLfloat *); +GLAPI void APIENTRY glWindowPos2iMESA (GLint, GLint); +GLAPI void APIENTRY glWindowPos2ivMESA (const GLint *); +GLAPI void APIENTRY glWindowPos2sMESA (GLshort, GLshort); +GLAPI void APIENTRY glWindowPos2svMESA (const GLshort *); +GLAPI void APIENTRY glWindowPos3dMESA (GLdouble, GLdouble, GLdouble); +GLAPI void APIENTRY glWindowPos3dvMESA (const GLdouble *); +GLAPI void APIENTRY glWindowPos3fMESA (GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glWindowPos3fvMESA (const GLfloat *); +GLAPI void APIENTRY glWindowPos3iMESA (GLint, GLint, GLint); +GLAPI void APIENTRY glWindowPos3ivMESA (const GLint *); +GLAPI void APIENTRY glWindowPos3sMESA (GLshort, GLshort, GLshort); +GLAPI void APIENTRY glWindowPos3svMESA (const GLshort *); +GLAPI void APIENTRY glWindowPos4dMESA (GLdouble, GLdouble, GLdouble, GLdouble); +GLAPI void APIENTRY glWindowPos4dvMESA (const GLdouble *); +GLAPI void APIENTRY glWindowPos4fMESA (GLfloat, GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glWindowPos4fvMESA (const GLfloat *); +GLAPI void APIENTRY glWindowPos4iMESA (GLint, GLint, GLint, GLint); +GLAPI void APIENTRY glWindowPos4ivMESA (const GLint *); +GLAPI void APIENTRY glWindowPos4sMESA (GLshort, GLshort, GLshort, GLshort); +GLAPI void APIENTRY glWindowPos4svMESA (const GLshort *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLWINDOWPOS2DMESAPROC) (GLdouble x, GLdouble y); +typedef void (APIENTRYP PFNGLWINDOWPOS2DVMESAPROC) (const GLdouble *v); +typedef void (APIENTRYP PFNGLWINDOWPOS2FMESAPROC) (GLfloat x, GLfloat y); +typedef void (APIENTRYP PFNGLWINDOWPOS2FVMESAPROC) (const GLfloat *v); +typedef void (APIENTRYP PFNGLWINDOWPOS2IMESAPROC) (GLint x, GLint y); +typedef void (APIENTRYP PFNGLWINDOWPOS2IVMESAPROC) (const GLint *v); +typedef void (APIENTRYP PFNGLWINDOWPOS2SMESAPROC) (GLshort x, GLshort y); +typedef void (APIENTRYP PFNGLWINDOWPOS2SVMESAPROC) (const GLshort *v); +typedef void (APIENTRYP PFNGLWINDOWPOS3DMESAPROC) (GLdouble x, GLdouble y, GLdouble z); +typedef void (APIENTRYP PFNGLWINDOWPOS3DVMESAPROC) (const GLdouble *v); +typedef void (APIENTRYP PFNGLWINDOWPOS3FMESAPROC) (GLfloat x, GLfloat y, GLfloat z); +typedef void (APIENTRYP PFNGLWINDOWPOS3FVMESAPROC) (const GLfloat *v); +typedef void (APIENTRYP PFNGLWINDOWPOS3IMESAPROC) (GLint x, GLint y, GLint z); +typedef void (APIENTRYP PFNGLWINDOWPOS3IVMESAPROC) (const GLint *v); +typedef void (APIENTRYP PFNGLWINDOWPOS3SMESAPROC) (GLshort x, GLshort y, GLshort z); +typedef void (APIENTRYP PFNGLWINDOWPOS3SVMESAPROC) (const GLshort *v); +typedef void (APIENTRYP PFNGLWINDOWPOS4DMESAPROC) (GLdouble x, GLdouble y, GLdouble z, GLdouble w); +typedef void (APIENTRYP PFNGLWINDOWPOS4DVMESAPROC) (const GLdouble *v); +typedef void (APIENTRYP PFNGLWINDOWPOS4FMESAPROC) (GLfloat x, GLfloat y, GLfloat z, GLfloat w); +typedef void (APIENTRYP PFNGLWINDOWPOS4FVMESAPROC) (const GLfloat *v); +typedef void (APIENTRYP PFNGLWINDOWPOS4IMESAPROC) (GLint x, GLint y, GLint z, GLint w); +typedef void (APIENTRYP PFNGLWINDOWPOS4IVMESAPROC) (const GLint *v); +typedef void (APIENTRYP PFNGLWINDOWPOS4SMESAPROC) (GLshort x, GLshort y, GLshort z, GLshort w); +typedef void (APIENTRYP PFNGLWINDOWPOS4SVMESAPROC) (const GLshort *v); +#endif + +#ifndef GL_IBM_cull_vertex +#define GL_IBM_cull_vertex 1 +#endif + +#ifndef GL_IBM_multimode_draw_arrays +#define GL_IBM_multimode_draw_arrays 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glMultiModeDrawArraysIBM (const GLenum *, const GLint *, const GLsizei *, GLsizei, GLint); +GLAPI void APIENTRY glMultiModeDrawElementsIBM (const GLenum *, const GLsizei *, GLenum, const GLvoid* const *, GLsizei, GLint); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLMULTIMODEDRAWARRAYSIBMPROC) (const GLenum *mode, const GLint *first, const GLsizei *count, GLsizei primcount, GLint modestride); +typedef void (APIENTRYP PFNGLMULTIMODEDRAWELEMENTSIBMPROC) (const GLenum *mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei primcount, GLint modestride); +#endif + +#ifndef GL_IBM_vertex_array_lists +#define GL_IBM_vertex_array_lists 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glColorPointerListIBM (GLint, GLenum, GLint, const GLvoid* *, GLint); +GLAPI void APIENTRY glSecondaryColorPointerListIBM (GLint, GLenum, GLint, const GLvoid* *, GLint); +GLAPI void APIENTRY glEdgeFlagPointerListIBM (GLint, const GLboolean* *, GLint); +GLAPI void APIENTRY glFogCoordPointerListIBM (GLenum, GLint, const GLvoid* *, GLint); +GLAPI void APIENTRY glIndexPointerListIBM (GLenum, GLint, const GLvoid* *, GLint); +GLAPI void APIENTRY glNormalPointerListIBM (GLenum, GLint, const GLvoid* *, GLint); +GLAPI void APIENTRY glTexCoordPointerListIBM (GLint, GLenum, GLint, const GLvoid* *, GLint); +GLAPI void APIENTRY glVertexPointerListIBM (GLint, GLenum, GLint, const GLvoid* *, GLint); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLCOLORPOINTERLISTIBMPROC) (GLint size, GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride); +typedef void (APIENTRYP PFNGLSECONDARYCOLORPOINTERLISTIBMPROC) (GLint size, GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride); +typedef void (APIENTRYP PFNGLEDGEFLAGPOINTERLISTIBMPROC) (GLint stride, const GLboolean* *pointer, GLint ptrstride); +typedef void (APIENTRYP PFNGLFOGCOORDPOINTERLISTIBMPROC) (GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride); +typedef void (APIENTRYP PFNGLINDEXPOINTERLISTIBMPROC) (GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride); +typedef void (APIENTRYP PFNGLNORMALPOINTERLISTIBMPROC) (GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride); +typedef void (APIENTRYP PFNGLTEXCOORDPOINTERLISTIBMPROC) (GLint size, GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride); +typedef void (APIENTRYP PFNGLVERTEXPOINTERLISTIBMPROC) (GLint size, GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride); +#endif + +#ifndef GL_SGIX_subsample +#define GL_SGIX_subsample 1 +#endif + +#ifndef GL_SGIX_ycrcba +#define GL_SGIX_ycrcba 1 +#endif + +#ifndef GL_SGIX_ycrcb_subsample +#define GL_SGIX_ycrcb_subsample 1 +#endif + +#ifndef GL_SGIX_depth_pass_instrument +#define GL_SGIX_depth_pass_instrument 1 +#endif + +#ifndef GL_3DFX_texture_compression_FXT1 +#define GL_3DFX_texture_compression_FXT1 1 +#endif + +#ifndef GL_3DFX_multisample +#define GL_3DFX_multisample 1 +#endif + +#ifndef GL_3DFX_tbuffer +#define GL_3DFX_tbuffer 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glTbufferMask3DFX (GLuint); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLTBUFFERMASK3DFXPROC) (GLuint mask); +#endif + +#ifndef GL_EXT_multisample +#define GL_EXT_multisample 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glSampleMaskEXT (GLclampf, GLboolean); +GLAPI void APIENTRY glSamplePatternEXT (GLenum); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLSAMPLEMASKEXTPROC) (GLclampf value, GLboolean invert); +typedef void (APIENTRYP PFNGLSAMPLEPATTERNEXTPROC) (GLenum pattern); +#endif + +#ifndef GL_SGIX_vertex_preclip +#define GL_SGIX_vertex_preclip 1 +#endif + +#ifndef GL_SGIX_convolution_accuracy +#define GL_SGIX_convolution_accuracy 1 +#endif + +#ifndef GL_SGIX_resample +#define GL_SGIX_resample 1 +#endif + +#ifndef GL_SGIS_point_line_texgen +#define GL_SGIS_point_line_texgen 1 +#endif + +#ifndef GL_SGIS_texture_color_mask +#define GL_SGIS_texture_color_mask 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glTextureColorMaskSGIS (GLboolean, GLboolean, GLboolean, GLboolean); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLTEXTURECOLORMASKSGISPROC) (GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha); +#endif + +#ifndef GL_SGIX_igloo_interface +#define GL_SGIX_igloo_interface 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glIglooInterfaceSGIX (GLenum, const GLvoid *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLIGLOOINTERFACESGIXPROC) (GLenum pname, const GLvoid *params); +#endif + +#ifndef GL_EXT_texture_env_dot3 +#define GL_EXT_texture_env_dot3 1 +#endif + +#ifndef GL_ATI_texture_mirror_once +#define GL_ATI_texture_mirror_once 1 +#endif + +#ifndef GL_NV_fence +#define GL_NV_fence 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glDeleteFencesNV (GLsizei, const GLuint *); +GLAPI void APIENTRY glGenFencesNV (GLsizei, GLuint *); +GLAPI GLboolean APIENTRY glIsFenceNV (GLuint); +GLAPI GLboolean APIENTRY glTestFenceNV (GLuint); +GLAPI void APIENTRY glGetFenceivNV (GLuint, GLenum, GLint *); +GLAPI void APIENTRY glFinishFenceNV (GLuint); +GLAPI void APIENTRY glSetFenceNV (GLuint, GLenum); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLDELETEFENCESNVPROC) (GLsizei n, const GLuint *fences); +typedef void (APIENTRYP PFNGLGENFENCESNVPROC) (GLsizei n, GLuint *fences); +typedef GLboolean (APIENTRYP PFNGLISFENCENVPROC) (GLuint fence); +typedef GLboolean (APIENTRYP PFNGLTESTFENCENVPROC) (GLuint fence); +typedef void (APIENTRYP PFNGLGETFENCEIVNVPROC) (GLuint fence, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLFINISHFENCENVPROC) (GLuint fence); +typedef void (APIENTRYP PFNGLSETFENCENVPROC) (GLuint fence, GLenum condition); +#endif + +#ifndef GL_NV_evaluators +#define GL_NV_evaluators 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glMapControlPointsNV (GLenum, GLuint, GLenum, GLsizei, GLsizei, GLint, GLint, GLboolean, const GLvoid *); +GLAPI void APIENTRY glMapParameterivNV (GLenum, GLenum, const GLint *); +GLAPI void APIENTRY glMapParameterfvNV (GLenum, GLenum, const GLfloat *); +GLAPI void APIENTRY glGetMapControlPointsNV (GLenum, GLuint, GLenum, GLsizei, GLsizei, GLboolean, GLvoid *); +GLAPI void APIENTRY glGetMapParameterivNV (GLenum, GLenum, GLint *); +GLAPI void APIENTRY glGetMapParameterfvNV (GLenum, GLenum, GLfloat *); +GLAPI void APIENTRY glGetMapAttribParameterivNV (GLenum, GLuint, GLenum, GLint *); +GLAPI void APIENTRY glGetMapAttribParameterfvNV (GLenum, GLuint, GLenum, GLfloat *); +GLAPI void APIENTRY glEvalMapsNV (GLenum, GLenum); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLMAPCONTROLPOINTSNVPROC) (GLenum target, GLuint index, GLenum type, GLsizei ustride, GLsizei vstride, GLint uorder, GLint vorder, GLboolean packed, const GLvoid *points); +typedef void (APIENTRYP PFNGLMAPPARAMETERIVNVPROC) (GLenum target, GLenum pname, const GLint *params); +typedef void (APIENTRYP PFNGLMAPPARAMETERFVNVPROC) (GLenum target, GLenum pname, const GLfloat *params); +typedef void (APIENTRYP PFNGLGETMAPCONTROLPOINTSNVPROC) (GLenum target, GLuint index, GLenum type, GLsizei ustride, GLsizei vstride, GLboolean packed, GLvoid *points); +typedef void (APIENTRYP PFNGLGETMAPPARAMETERIVNVPROC) (GLenum target, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLGETMAPPARAMETERFVNVPROC) (GLenum target, GLenum pname, GLfloat *params); +typedef void (APIENTRYP PFNGLGETMAPATTRIBPARAMETERIVNVPROC) (GLenum target, GLuint index, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLGETMAPATTRIBPARAMETERFVNVPROC) (GLenum target, GLuint index, GLenum pname, GLfloat *params); +typedef void (APIENTRYP PFNGLEVALMAPSNVPROC) (GLenum target, GLenum mode); +#endif + +#ifndef GL_NV_packed_depth_stencil +#define GL_NV_packed_depth_stencil 1 +#endif + +#ifndef GL_NV_register_combiners2 +#define GL_NV_register_combiners2 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glCombinerStageParameterfvNV (GLenum, GLenum, const GLfloat *); +GLAPI void APIENTRY glGetCombinerStageParameterfvNV (GLenum, GLenum, GLfloat *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLCOMBINERSTAGEPARAMETERFVNVPROC) (GLenum stage, GLenum pname, const GLfloat *params); +typedef void (APIENTRYP PFNGLGETCOMBINERSTAGEPARAMETERFVNVPROC) (GLenum stage, GLenum pname, GLfloat *params); +#endif + +#ifndef GL_NV_texture_compression_vtc +#define GL_NV_texture_compression_vtc 1 +#endif + +#ifndef GL_NV_texture_rectangle +#define GL_NV_texture_rectangle 1 +#endif + +#ifndef GL_NV_texture_shader +#define GL_NV_texture_shader 1 +#endif + +#ifndef GL_NV_texture_shader2 +#define GL_NV_texture_shader2 1 +#endif + +#ifndef GL_NV_vertex_array_range2 +#define GL_NV_vertex_array_range2 1 +#endif + +#ifndef GL_NV_vertex_program +#define GL_NV_vertex_program 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI GLboolean APIENTRY glAreProgramsResidentNV (GLsizei, const GLuint *, GLboolean *); +GLAPI void APIENTRY glBindProgramNV (GLenum, GLuint); +GLAPI void APIENTRY glDeleteProgramsNV (GLsizei, const GLuint *); +GLAPI void APIENTRY glExecuteProgramNV (GLenum, GLuint, const GLfloat *); +GLAPI void APIENTRY glGenProgramsNV (GLsizei, GLuint *); +GLAPI void APIENTRY glGetProgramParameterdvNV (GLenum, GLuint, GLenum, GLdouble *); +GLAPI void APIENTRY glGetProgramParameterfvNV (GLenum, GLuint, GLenum, GLfloat *); +GLAPI void APIENTRY glGetProgramivNV (GLuint, GLenum, GLint *); +GLAPI void APIENTRY glGetProgramStringNV (GLuint, GLenum, GLubyte *); +GLAPI void APIENTRY glGetTrackMatrixivNV (GLenum, GLuint, GLenum, GLint *); +GLAPI void APIENTRY glGetVertexAttribdvNV (GLuint, GLenum, GLdouble *); +GLAPI void APIENTRY glGetVertexAttribfvNV (GLuint, GLenum, GLfloat *); +GLAPI void APIENTRY glGetVertexAttribivNV (GLuint, GLenum, GLint *); +GLAPI void APIENTRY glGetVertexAttribPointervNV (GLuint, GLenum, GLvoid* *); +GLAPI GLboolean APIENTRY glIsProgramNV (GLuint); +GLAPI void APIENTRY glLoadProgramNV (GLenum, GLuint, GLsizei, const GLubyte *); +GLAPI void APIENTRY glProgramParameter4dNV (GLenum, GLuint, GLdouble, GLdouble, GLdouble, GLdouble); +GLAPI void APIENTRY glProgramParameter4dvNV (GLenum, GLuint, const GLdouble *); +GLAPI void APIENTRY glProgramParameter4fNV (GLenum, GLuint, GLfloat, GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glProgramParameter4fvNV (GLenum, GLuint, const GLfloat *); +GLAPI void APIENTRY glProgramParameters4dvNV (GLenum, GLuint, GLuint, const GLdouble *); +GLAPI void APIENTRY glProgramParameters4fvNV (GLenum, GLuint, GLuint, const GLfloat *); +GLAPI void APIENTRY glRequestResidentProgramsNV (GLsizei, const GLuint *); +GLAPI void APIENTRY glTrackMatrixNV (GLenum, GLuint, GLenum, GLenum); +GLAPI void APIENTRY glVertexAttribPointerNV (GLuint, GLint, GLenum, GLsizei, const GLvoid *); +GLAPI void APIENTRY glVertexAttrib1dNV (GLuint, GLdouble); +GLAPI void APIENTRY glVertexAttrib1dvNV (GLuint, const GLdouble *); +GLAPI void APIENTRY glVertexAttrib1fNV (GLuint, GLfloat); +GLAPI void APIENTRY glVertexAttrib1fvNV (GLuint, const GLfloat *); +GLAPI void APIENTRY glVertexAttrib1sNV (GLuint, GLshort); +GLAPI void APIENTRY glVertexAttrib1svNV (GLuint, const GLshort *); +GLAPI void APIENTRY glVertexAttrib2dNV (GLuint, GLdouble, GLdouble); +GLAPI void APIENTRY glVertexAttrib2dvNV (GLuint, const GLdouble *); +GLAPI void APIENTRY glVertexAttrib2fNV (GLuint, GLfloat, GLfloat); +GLAPI void APIENTRY glVertexAttrib2fvNV (GLuint, const GLfloat *); +GLAPI void APIENTRY glVertexAttrib2sNV (GLuint, GLshort, GLshort); +GLAPI void APIENTRY glVertexAttrib2svNV (GLuint, const GLshort *); +GLAPI void APIENTRY glVertexAttrib3dNV (GLuint, GLdouble, GLdouble, GLdouble); +GLAPI void APIENTRY glVertexAttrib3dvNV (GLuint, const GLdouble *); +GLAPI void APIENTRY glVertexAttrib3fNV (GLuint, GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glVertexAttrib3fvNV (GLuint, const GLfloat *); +GLAPI void APIENTRY glVertexAttrib3sNV (GLuint, GLshort, GLshort, GLshort); +GLAPI void APIENTRY glVertexAttrib3svNV (GLuint, const GLshort *); +GLAPI void APIENTRY glVertexAttrib4dNV (GLuint, GLdouble, GLdouble, GLdouble, GLdouble); +GLAPI void APIENTRY glVertexAttrib4dvNV (GLuint, const GLdouble *); +GLAPI void APIENTRY glVertexAttrib4fNV (GLuint, GLfloat, GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glVertexAttrib4fvNV (GLuint, const GLfloat *); +GLAPI void APIENTRY glVertexAttrib4sNV (GLuint, GLshort, GLshort, GLshort, GLshort); +GLAPI void APIENTRY glVertexAttrib4svNV (GLuint, const GLshort *); +GLAPI void APIENTRY glVertexAttrib4ubNV (GLuint, GLubyte, GLubyte, GLubyte, GLubyte); +GLAPI void APIENTRY glVertexAttrib4ubvNV (GLuint, const GLubyte *); +GLAPI void APIENTRY glVertexAttribs1dvNV (GLuint, GLsizei, const GLdouble *); +GLAPI void APIENTRY glVertexAttribs1fvNV (GLuint, GLsizei, const GLfloat *); +GLAPI void APIENTRY glVertexAttribs1svNV (GLuint, GLsizei, const GLshort *); +GLAPI void APIENTRY glVertexAttribs2dvNV (GLuint, GLsizei, const GLdouble *); +GLAPI void APIENTRY glVertexAttribs2fvNV (GLuint, GLsizei, const GLfloat *); +GLAPI void APIENTRY glVertexAttribs2svNV (GLuint, GLsizei, const GLshort *); +GLAPI void APIENTRY glVertexAttribs3dvNV (GLuint, GLsizei, const GLdouble *); +GLAPI void APIENTRY glVertexAttribs3fvNV (GLuint, GLsizei, const GLfloat *); +GLAPI void APIENTRY glVertexAttribs3svNV (GLuint, GLsizei, const GLshort *); +GLAPI void APIENTRY glVertexAttribs4dvNV (GLuint, GLsizei, const GLdouble *); +GLAPI void APIENTRY glVertexAttribs4fvNV (GLuint, GLsizei, const GLfloat *); +GLAPI void APIENTRY glVertexAttribs4svNV (GLuint, GLsizei, const GLshort *); +GLAPI void APIENTRY glVertexAttribs4ubvNV (GLuint, GLsizei, const GLubyte *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef GLboolean (APIENTRYP PFNGLAREPROGRAMSRESIDENTNVPROC) (GLsizei n, const GLuint *programs, GLboolean *residences); +typedef void (APIENTRYP PFNGLBINDPROGRAMNVPROC) (GLenum target, GLuint id); +typedef void (APIENTRYP PFNGLDELETEPROGRAMSNVPROC) (GLsizei n, const GLuint *programs); +typedef void (APIENTRYP PFNGLEXECUTEPROGRAMNVPROC) (GLenum target, GLuint id, const GLfloat *params); +typedef void (APIENTRYP PFNGLGENPROGRAMSNVPROC) (GLsizei n, GLuint *programs); +typedef void (APIENTRYP PFNGLGETPROGRAMPARAMETERDVNVPROC) (GLenum target, GLuint index, GLenum pname, GLdouble *params); +typedef void (APIENTRYP PFNGLGETPROGRAMPARAMETERFVNVPROC) (GLenum target, GLuint index, GLenum pname, GLfloat *params); +typedef void (APIENTRYP PFNGLGETPROGRAMIVNVPROC) (GLuint id, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLGETPROGRAMSTRINGNVPROC) (GLuint id, GLenum pname, GLubyte *program); +typedef void (APIENTRYP PFNGLGETTRACKMATRIXIVNVPROC) (GLenum target, GLuint address, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLGETVERTEXATTRIBDVNVPROC) (GLuint index, GLenum pname, GLdouble *params); +typedef void (APIENTRYP PFNGLGETVERTEXATTRIBFVNVPROC) (GLuint index, GLenum pname, GLfloat *params); +typedef void (APIENTRYP PFNGLGETVERTEXATTRIBIVNVPROC) (GLuint index, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLGETVERTEXATTRIBPOINTERVNVPROC) (GLuint index, GLenum pname, GLvoid* *pointer); +typedef GLboolean (APIENTRYP PFNGLISPROGRAMNVPROC) (GLuint id); +typedef void (APIENTRYP PFNGLLOADPROGRAMNVPROC) (GLenum target, GLuint id, GLsizei len, const GLubyte *program); +typedef void (APIENTRYP PFNGLPROGRAMPARAMETER4DNVPROC) (GLenum target, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w); +typedef void (APIENTRYP PFNGLPROGRAMPARAMETER4DVNVPROC) (GLenum target, GLuint index, const GLdouble *v); +typedef void (APIENTRYP PFNGLPROGRAMPARAMETER4FNVPROC) (GLenum target, GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w); +typedef void (APIENTRYP PFNGLPROGRAMPARAMETER4FVNVPROC) (GLenum target, GLuint index, const GLfloat *v); +typedef void (APIENTRYP PFNGLPROGRAMPARAMETERS4DVNVPROC) (GLenum target, GLuint index, GLuint count, const GLdouble *v); +typedef void (APIENTRYP PFNGLPROGRAMPARAMETERS4FVNVPROC) (GLenum target, GLuint index, GLuint count, const GLfloat *v); +typedef void (APIENTRYP PFNGLREQUESTRESIDENTPROGRAMSNVPROC) (GLsizei n, const GLuint *programs); +typedef void (APIENTRYP PFNGLTRACKMATRIXNVPROC) (GLenum target, GLuint address, GLenum matrix, GLenum transform); +typedef void (APIENTRYP PFNGLVERTEXATTRIBPOINTERNVPROC) (GLuint index, GLint fsize, GLenum type, GLsizei stride, const GLvoid *pointer); +typedef void (APIENTRYP PFNGLVERTEXATTRIB1DNVPROC) (GLuint index, GLdouble x); +typedef void (APIENTRYP PFNGLVERTEXATTRIB1DVNVPROC) (GLuint index, const GLdouble *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB1FNVPROC) (GLuint index, GLfloat x); +typedef void (APIENTRYP PFNGLVERTEXATTRIB1FVNVPROC) (GLuint index, const GLfloat *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB1SNVPROC) (GLuint index, GLshort x); +typedef void (APIENTRYP PFNGLVERTEXATTRIB1SVNVPROC) (GLuint index, const GLshort *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB2DNVPROC) (GLuint index, GLdouble x, GLdouble y); +typedef void (APIENTRYP PFNGLVERTEXATTRIB2DVNVPROC) (GLuint index, const GLdouble *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB2FNVPROC) (GLuint index, GLfloat x, GLfloat y); +typedef void (APIENTRYP PFNGLVERTEXATTRIB2FVNVPROC) (GLuint index, const GLfloat *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB2SNVPROC) (GLuint index, GLshort x, GLshort y); +typedef void (APIENTRYP PFNGLVERTEXATTRIB2SVNVPROC) (GLuint index, const GLshort *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB3DNVPROC) (GLuint index, GLdouble x, GLdouble y, GLdouble z); +typedef void (APIENTRYP PFNGLVERTEXATTRIB3DVNVPROC) (GLuint index, const GLdouble *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB3FNVPROC) (GLuint index, GLfloat x, GLfloat y, GLfloat z); +typedef void (APIENTRYP PFNGLVERTEXATTRIB3FVNVPROC) (GLuint index, const GLfloat *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB3SNVPROC) (GLuint index, GLshort x, GLshort y, GLshort z); +typedef void (APIENTRYP PFNGLVERTEXATTRIB3SVNVPROC) (GLuint index, const GLshort *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB4DNVPROC) (GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w); +typedef void (APIENTRYP PFNGLVERTEXATTRIB4DVNVPROC) (GLuint index, const GLdouble *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB4FNVPROC) (GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w); +typedef void (APIENTRYP PFNGLVERTEXATTRIB4FVNVPROC) (GLuint index, const GLfloat *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB4SNVPROC) (GLuint index, GLshort x, GLshort y, GLshort z, GLshort w); +typedef void (APIENTRYP PFNGLVERTEXATTRIB4SVNVPROC) (GLuint index, const GLshort *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB4UBNVPROC) (GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w); +typedef void (APIENTRYP PFNGLVERTEXATTRIB4UBVNVPROC) (GLuint index, const GLubyte *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIBS1DVNVPROC) (GLuint index, GLsizei count, const GLdouble *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIBS1FVNVPROC) (GLuint index, GLsizei count, const GLfloat *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIBS1SVNVPROC) (GLuint index, GLsizei count, const GLshort *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIBS2DVNVPROC) (GLuint index, GLsizei count, const GLdouble *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIBS2FVNVPROC) (GLuint index, GLsizei count, const GLfloat *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIBS2SVNVPROC) (GLuint index, GLsizei count, const GLshort *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIBS3DVNVPROC) (GLuint index, GLsizei count, const GLdouble *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIBS3FVNVPROC) (GLuint index, GLsizei count, const GLfloat *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIBS3SVNVPROC) (GLuint index, GLsizei count, const GLshort *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIBS4DVNVPROC) (GLuint index, GLsizei count, const GLdouble *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIBS4FVNVPROC) (GLuint index, GLsizei count, const GLfloat *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIBS4SVNVPROC) (GLuint index, GLsizei count, const GLshort *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIBS4UBVNVPROC) (GLuint index, GLsizei count, const GLubyte *v); +#endif + +#ifndef GL_SGIX_texture_coordinate_clamp +#define GL_SGIX_texture_coordinate_clamp 1 +#endif + +#ifndef GL_SGIX_scalebias_hint +#define GL_SGIX_scalebias_hint 1 +#endif + +#ifndef GL_OML_interlace +#define GL_OML_interlace 1 +#endif + +#ifndef GL_OML_subsample +#define GL_OML_subsample 1 +#endif + +#ifndef GL_OML_resample +#define GL_OML_resample 1 +#endif + +#ifndef GL_NV_copy_depth_to_color +#define GL_NV_copy_depth_to_color 1 +#endif + +#ifndef GL_ATI_envmap_bumpmap +#define GL_ATI_envmap_bumpmap 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glTexBumpParameterivATI (GLenum, const GLint *); +GLAPI void APIENTRY glTexBumpParameterfvATI (GLenum, const GLfloat *); +GLAPI void APIENTRY glGetTexBumpParameterivATI (GLenum, GLint *); +GLAPI void APIENTRY glGetTexBumpParameterfvATI (GLenum, GLfloat *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLTEXBUMPPARAMETERIVATIPROC) (GLenum pname, const GLint *param); +typedef void (APIENTRYP PFNGLTEXBUMPPARAMETERFVATIPROC) (GLenum pname, const GLfloat *param); +typedef void (APIENTRYP PFNGLGETTEXBUMPPARAMETERIVATIPROC) (GLenum pname, GLint *param); +typedef void (APIENTRYP PFNGLGETTEXBUMPPARAMETERFVATIPROC) (GLenum pname, GLfloat *param); +#endif + +#ifndef GL_ATI_fragment_shader +#define GL_ATI_fragment_shader 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI GLuint APIENTRY glGenFragmentShadersATI (GLuint); +GLAPI void APIENTRY glBindFragmentShaderATI (GLuint); +GLAPI void APIENTRY glDeleteFragmentShaderATI (GLuint); +GLAPI void APIENTRY glBeginFragmentShaderATI (void); +GLAPI void APIENTRY glEndFragmentShaderATI (void); +GLAPI void APIENTRY glPassTexCoordATI (GLuint, GLuint, GLenum); +GLAPI void APIENTRY glSampleMapATI (GLuint, GLuint, GLenum); +GLAPI void APIENTRY glColorFragmentOp1ATI (GLenum, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint); +GLAPI void APIENTRY glColorFragmentOp2ATI (GLenum, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint); +GLAPI void APIENTRY glColorFragmentOp3ATI (GLenum, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint); +GLAPI void APIENTRY glAlphaFragmentOp1ATI (GLenum, GLuint, GLuint, GLuint, GLuint, GLuint); +GLAPI void APIENTRY glAlphaFragmentOp2ATI (GLenum, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint); +GLAPI void APIENTRY glAlphaFragmentOp3ATI (GLenum, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint); +GLAPI void APIENTRY glSetFragmentShaderConstantATI (GLuint, const GLfloat *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef GLuint (APIENTRYP PFNGLGENFRAGMENTSHADERSATIPROC) (GLuint range); +typedef void (APIENTRYP PFNGLBINDFRAGMENTSHADERATIPROC) (GLuint id); +typedef void (APIENTRYP PFNGLDELETEFRAGMENTSHADERATIPROC) (GLuint id); +typedef void (APIENTRYP PFNGLBEGINFRAGMENTSHADERATIPROC) (void); +typedef void (APIENTRYP PFNGLENDFRAGMENTSHADERATIPROC) (void); +typedef void (APIENTRYP PFNGLPASSTEXCOORDATIPROC) (GLuint dst, GLuint coord, GLenum swizzle); +typedef void (APIENTRYP PFNGLSAMPLEMAPATIPROC) (GLuint dst, GLuint interp, GLenum swizzle); +typedef void (APIENTRYP PFNGLCOLORFRAGMENTOP1ATIPROC) (GLenum op, GLuint dst, GLuint dstMask, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod); +typedef void (APIENTRYP PFNGLCOLORFRAGMENTOP2ATIPROC) (GLenum op, GLuint dst, GLuint dstMask, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod, GLuint arg2, GLuint arg2Rep, GLuint arg2Mod); +typedef void (APIENTRYP PFNGLCOLORFRAGMENTOP3ATIPROC) (GLenum op, GLuint dst, GLuint dstMask, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod, GLuint arg2, GLuint arg2Rep, GLuint arg2Mod, GLuint arg3, GLuint arg3Rep, GLuint arg3Mod); +typedef void (APIENTRYP PFNGLALPHAFRAGMENTOP1ATIPROC) (GLenum op, GLuint dst, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod); +typedef void (APIENTRYP PFNGLALPHAFRAGMENTOP2ATIPROC) (GLenum op, GLuint dst, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod, GLuint arg2, GLuint arg2Rep, GLuint arg2Mod); +typedef void (APIENTRYP PFNGLALPHAFRAGMENTOP3ATIPROC) (GLenum op, GLuint dst, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod, GLuint arg2, GLuint arg2Rep, GLuint arg2Mod, GLuint arg3, GLuint arg3Rep, GLuint arg3Mod); +typedef void (APIENTRYP PFNGLSETFRAGMENTSHADERCONSTANTATIPROC) (GLuint dst, const GLfloat *value); +#endif + +#ifndef GL_ATI_pn_triangles +#define GL_ATI_pn_triangles 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glPNTrianglesiATI (GLenum, GLint); +GLAPI void APIENTRY glPNTrianglesfATI (GLenum, GLfloat); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLPNTRIANGLESIATIPROC) (GLenum pname, GLint param); +typedef void (APIENTRYP PFNGLPNTRIANGLESFATIPROC) (GLenum pname, GLfloat param); +#endif + +#ifndef GL_ATI_vertex_array_object +#define GL_ATI_vertex_array_object 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI GLuint APIENTRY glNewObjectBufferATI (GLsizei, const GLvoid *, GLenum); +GLAPI GLboolean APIENTRY glIsObjectBufferATI (GLuint); +GLAPI void APIENTRY glUpdateObjectBufferATI (GLuint, GLuint, GLsizei, const GLvoid *, GLenum); +GLAPI void APIENTRY glGetObjectBufferfvATI (GLuint, GLenum, GLfloat *); +GLAPI void APIENTRY glGetObjectBufferivATI (GLuint, GLenum, GLint *); +GLAPI void APIENTRY glFreeObjectBufferATI (GLuint); +GLAPI void APIENTRY glArrayObjectATI (GLenum, GLint, GLenum, GLsizei, GLuint, GLuint); +GLAPI void APIENTRY glGetArrayObjectfvATI (GLenum, GLenum, GLfloat *); +GLAPI void APIENTRY glGetArrayObjectivATI (GLenum, GLenum, GLint *); +GLAPI void APIENTRY glVariantArrayObjectATI (GLuint, GLenum, GLsizei, GLuint, GLuint); +GLAPI void APIENTRY glGetVariantArrayObjectfvATI (GLuint, GLenum, GLfloat *); +GLAPI void APIENTRY glGetVariantArrayObjectivATI (GLuint, GLenum, GLint *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef GLuint (APIENTRYP PFNGLNEWOBJECTBUFFERATIPROC) (GLsizei size, const GLvoid *pointer, GLenum usage); +typedef GLboolean (APIENTRYP PFNGLISOBJECTBUFFERATIPROC) (GLuint buffer); +typedef void (APIENTRYP PFNGLUPDATEOBJECTBUFFERATIPROC) (GLuint buffer, GLuint offset, GLsizei size, const GLvoid *pointer, GLenum preserve); +typedef void (APIENTRYP PFNGLGETOBJECTBUFFERFVATIPROC) (GLuint buffer, GLenum pname, GLfloat *params); +typedef void (APIENTRYP PFNGLGETOBJECTBUFFERIVATIPROC) (GLuint buffer, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLFREEOBJECTBUFFERATIPROC) (GLuint buffer); +typedef void (APIENTRYP PFNGLARRAYOBJECTATIPROC) (GLenum array, GLint size, GLenum type, GLsizei stride, GLuint buffer, GLuint offset); +typedef void (APIENTRYP PFNGLGETARRAYOBJECTFVATIPROC) (GLenum array, GLenum pname, GLfloat *params); +typedef void (APIENTRYP PFNGLGETARRAYOBJECTIVATIPROC) (GLenum array, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLVARIANTARRAYOBJECTATIPROC) (GLuint id, GLenum type, GLsizei stride, GLuint buffer, GLuint offset); +typedef void (APIENTRYP PFNGLGETVARIANTARRAYOBJECTFVATIPROC) (GLuint id, GLenum pname, GLfloat *params); +typedef void (APIENTRYP PFNGLGETVARIANTARRAYOBJECTIVATIPROC) (GLuint id, GLenum pname, GLint *params); +#endif + +#ifndef GL_EXT_vertex_shader +#define GL_EXT_vertex_shader 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glBeginVertexShaderEXT (void); +GLAPI void APIENTRY glEndVertexShaderEXT (void); +GLAPI void APIENTRY glBindVertexShaderEXT (GLuint); +GLAPI GLuint APIENTRY glGenVertexShadersEXT (GLuint); +GLAPI void APIENTRY glDeleteVertexShaderEXT (GLuint); +GLAPI void APIENTRY glShaderOp1EXT (GLenum, GLuint, GLuint); +GLAPI void APIENTRY glShaderOp2EXT (GLenum, GLuint, GLuint, GLuint); +GLAPI void APIENTRY glShaderOp3EXT (GLenum, GLuint, GLuint, GLuint, GLuint); +GLAPI void APIENTRY glSwizzleEXT (GLuint, GLuint, GLenum, GLenum, GLenum, GLenum); +GLAPI void APIENTRY glWriteMaskEXT (GLuint, GLuint, GLenum, GLenum, GLenum, GLenum); +GLAPI void APIENTRY glInsertComponentEXT (GLuint, GLuint, GLuint); +GLAPI void APIENTRY glExtractComponentEXT (GLuint, GLuint, GLuint); +GLAPI GLuint APIENTRY glGenSymbolsEXT (GLenum, GLenum, GLenum, GLuint); +GLAPI void APIENTRY glSetInvariantEXT (GLuint, GLenum, const GLvoid *); +GLAPI void APIENTRY glSetLocalConstantEXT (GLuint, GLenum, const GLvoid *); +GLAPI void APIENTRY glVariantbvEXT (GLuint, const GLbyte *); +GLAPI void APIENTRY glVariantsvEXT (GLuint, const GLshort *); +GLAPI void APIENTRY glVariantivEXT (GLuint, const GLint *); +GLAPI void APIENTRY glVariantfvEXT (GLuint, const GLfloat *); +GLAPI void APIENTRY glVariantdvEXT (GLuint, const GLdouble *); +GLAPI void APIENTRY glVariantubvEXT (GLuint, const GLubyte *); +GLAPI void APIENTRY glVariantusvEXT (GLuint, const GLushort *); +GLAPI void APIENTRY glVariantuivEXT (GLuint, const GLuint *); +GLAPI void APIENTRY glVariantPointerEXT (GLuint, GLenum, GLuint, const GLvoid *); +GLAPI void APIENTRY glEnableVariantClientStateEXT (GLuint); +GLAPI void APIENTRY glDisableVariantClientStateEXT (GLuint); +GLAPI GLuint APIENTRY glBindLightParameterEXT (GLenum, GLenum); +GLAPI GLuint APIENTRY glBindMaterialParameterEXT (GLenum, GLenum); +GLAPI GLuint APIENTRY glBindTexGenParameterEXT (GLenum, GLenum, GLenum); +GLAPI GLuint APIENTRY glBindTextureUnitParameterEXT (GLenum, GLenum); +GLAPI GLuint APIENTRY glBindParameterEXT (GLenum); +GLAPI GLboolean APIENTRY glIsVariantEnabledEXT (GLuint, GLenum); +GLAPI void APIENTRY glGetVariantBooleanvEXT (GLuint, GLenum, GLboolean *); +GLAPI void APIENTRY glGetVariantIntegervEXT (GLuint, GLenum, GLint *); +GLAPI void APIENTRY glGetVariantFloatvEXT (GLuint, GLenum, GLfloat *); +GLAPI void APIENTRY glGetVariantPointervEXT (GLuint, GLenum, GLvoid* *); +GLAPI void APIENTRY glGetInvariantBooleanvEXT (GLuint, GLenum, GLboolean *); +GLAPI void APIENTRY glGetInvariantIntegervEXT (GLuint, GLenum, GLint *); +GLAPI void APIENTRY glGetInvariantFloatvEXT (GLuint, GLenum, GLfloat *); +GLAPI void APIENTRY glGetLocalConstantBooleanvEXT (GLuint, GLenum, GLboolean *); +GLAPI void APIENTRY glGetLocalConstantIntegervEXT (GLuint, GLenum, GLint *); +GLAPI void APIENTRY glGetLocalConstantFloatvEXT (GLuint, GLenum, GLfloat *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLBEGINVERTEXSHADEREXTPROC) (void); +typedef void (APIENTRYP PFNGLENDVERTEXSHADEREXTPROC) (void); +typedef void (APIENTRYP PFNGLBINDVERTEXSHADEREXTPROC) (GLuint id); +typedef GLuint (APIENTRYP PFNGLGENVERTEXSHADERSEXTPROC) (GLuint range); +typedef void (APIENTRYP PFNGLDELETEVERTEXSHADEREXTPROC) (GLuint id); +typedef void (APIENTRYP PFNGLSHADEROP1EXTPROC) (GLenum op, GLuint res, GLuint arg1); +typedef void (APIENTRYP PFNGLSHADEROP2EXTPROC) (GLenum op, GLuint res, GLuint arg1, GLuint arg2); +typedef void (APIENTRYP PFNGLSHADEROP3EXTPROC) (GLenum op, GLuint res, GLuint arg1, GLuint arg2, GLuint arg3); +typedef void (APIENTRYP PFNGLSWIZZLEEXTPROC) (GLuint res, GLuint in, GLenum outX, GLenum outY, GLenum outZ, GLenum outW); +typedef void (APIENTRYP PFNGLWRITEMASKEXTPROC) (GLuint res, GLuint in, GLenum outX, GLenum outY, GLenum outZ, GLenum outW); +typedef void (APIENTRYP PFNGLINSERTCOMPONENTEXTPROC) (GLuint res, GLuint src, GLuint num); +typedef void (APIENTRYP PFNGLEXTRACTCOMPONENTEXTPROC) (GLuint res, GLuint src, GLuint num); +typedef GLuint (APIENTRYP PFNGLGENSYMBOLSEXTPROC) (GLenum datatype, GLenum storagetype, GLenum range, GLuint components); +typedef void (APIENTRYP PFNGLSETINVARIANTEXTPROC) (GLuint id, GLenum type, const GLvoid *addr); +typedef void (APIENTRYP PFNGLSETLOCALCONSTANTEXTPROC) (GLuint id, GLenum type, const GLvoid *addr); +typedef void (APIENTRYP PFNGLVARIANTBVEXTPROC) (GLuint id, const GLbyte *addr); +typedef void (APIENTRYP PFNGLVARIANTSVEXTPROC) (GLuint id, const GLshort *addr); +typedef void (APIENTRYP PFNGLVARIANTIVEXTPROC) (GLuint id, const GLint *addr); +typedef void (APIENTRYP PFNGLVARIANTFVEXTPROC) (GLuint id, const GLfloat *addr); +typedef void (APIENTRYP PFNGLVARIANTDVEXTPROC) (GLuint id, const GLdouble *addr); +typedef void (APIENTRYP PFNGLVARIANTUBVEXTPROC) (GLuint id, const GLubyte *addr); +typedef void (APIENTRYP PFNGLVARIANTUSVEXTPROC) (GLuint id, const GLushort *addr); +typedef void (APIENTRYP PFNGLVARIANTUIVEXTPROC) (GLuint id, const GLuint *addr); +typedef void (APIENTRYP PFNGLVARIANTPOINTEREXTPROC) (GLuint id, GLenum type, GLuint stride, const GLvoid *addr); +typedef void (APIENTRYP PFNGLENABLEVARIANTCLIENTSTATEEXTPROC) (GLuint id); +typedef void (APIENTRYP PFNGLDISABLEVARIANTCLIENTSTATEEXTPROC) (GLuint id); +typedef GLuint (APIENTRYP PFNGLBINDLIGHTPARAMETEREXTPROC) (GLenum light, GLenum value); +typedef GLuint (APIENTRYP PFNGLBINDMATERIALPARAMETEREXTPROC) (GLenum face, GLenum value); +typedef GLuint (APIENTRYP PFNGLBINDTEXGENPARAMETEREXTPROC) (GLenum unit, GLenum coord, GLenum value); +typedef GLuint (APIENTRYP PFNGLBINDTEXTUREUNITPARAMETEREXTPROC) (GLenum unit, GLenum value); +typedef GLuint (APIENTRYP PFNGLBINDPARAMETEREXTPROC) (GLenum value); +typedef GLboolean (APIENTRYP PFNGLISVARIANTENABLEDEXTPROC) (GLuint id, GLenum cap); +typedef void (APIENTRYP PFNGLGETVARIANTBOOLEANVEXTPROC) (GLuint id, GLenum value, GLboolean *data); +typedef void (APIENTRYP PFNGLGETVARIANTINTEGERVEXTPROC) (GLuint id, GLenum value, GLint *data); +typedef void (APIENTRYP PFNGLGETVARIANTFLOATVEXTPROC) (GLuint id, GLenum value, GLfloat *data); +typedef void (APIENTRYP PFNGLGETVARIANTPOINTERVEXTPROC) (GLuint id, GLenum value, GLvoid* *data); +typedef void (APIENTRYP PFNGLGETINVARIANTBOOLEANVEXTPROC) (GLuint id, GLenum value, GLboolean *data); +typedef void (APIENTRYP PFNGLGETINVARIANTINTEGERVEXTPROC) (GLuint id, GLenum value, GLint *data); +typedef void (APIENTRYP PFNGLGETINVARIANTFLOATVEXTPROC) (GLuint id, GLenum value, GLfloat *data); +typedef void (APIENTRYP PFNGLGETLOCALCONSTANTBOOLEANVEXTPROC) (GLuint id, GLenum value, GLboolean *data); +typedef void (APIENTRYP PFNGLGETLOCALCONSTANTINTEGERVEXTPROC) (GLuint id, GLenum value, GLint *data); +typedef void (APIENTRYP PFNGLGETLOCALCONSTANTFLOATVEXTPROC) (GLuint id, GLenum value, GLfloat *data); +#endif + +#ifndef GL_ATI_vertex_streams +#define GL_ATI_vertex_streams 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glVertexStream1sATI (GLenum, GLshort); +GLAPI void APIENTRY glVertexStream1svATI (GLenum, const GLshort *); +GLAPI void APIENTRY glVertexStream1iATI (GLenum, GLint); +GLAPI void APIENTRY glVertexStream1ivATI (GLenum, const GLint *); +GLAPI void APIENTRY glVertexStream1fATI (GLenum, GLfloat); +GLAPI void APIENTRY glVertexStream1fvATI (GLenum, const GLfloat *); +GLAPI void APIENTRY glVertexStream1dATI (GLenum, GLdouble); +GLAPI void APIENTRY glVertexStream1dvATI (GLenum, const GLdouble *); +GLAPI void APIENTRY glVertexStream2sATI (GLenum, GLshort, GLshort); +GLAPI void APIENTRY glVertexStream2svATI (GLenum, const GLshort *); +GLAPI void APIENTRY glVertexStream2iATI (GLenum, GLint, GLint); +GLAPI void APIENTRY glVertexStream2ivATI (GLenum, const GLint *); +GLAPI void APIENTRY glVertexStream2fATI (GLenum, GLfloat, GLfloat); +GLAPI void APIENTRY glVertexStream2fvATI (GLenum, const GLfloat *); +GLAPI void APIENTRY glVertexStream2dATI (GLenum, GLdouble, GLdouble); +GLAPI void APIENTRY glVertexStream2dvATI (GLenum, const GLdouble *); +GLAPI void APIENTRY glVertexStream3sATI (GLenum, GLshort, GLshort, GLshort); +GLAPI void APIENTRY glVertexStream3svATI (GLenum, const GLshort *); +GLAPI void APIENTRY glVertexStream3iATI (GLenum, GLint, GLint, GLint); +GLAPI void APIENTRY glVertexStream3ivATI (GLenum, const GLint *); +GLAPI void APIENTRY glVertexStream3fATI (GLenum, GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glVertexStream3fvATI (GLenum, const GLfloat *); +GLAPI void APIENTRY glVertexStream3dATI (GLenum, GLdouble, GLdouble, GLdouble); +GLAPI void APIENTRY glVertexStream3dvATI (GLenum, const GLdouble *); +GLAPI void APIENTRY glVertexStream4sATI (GLenum, GLshort, GLshort, GLshort, GLshort); +GLAPI void APIENTRY glVertexStream4svATI (GLenum, const GLshort *); +GLAPI void APIENTRY glVertexStream4iATI (GLenum, GLint, GLint, GLint, GLint); +GLAPI void APIENTRY glVertexStream4ivATI (GLenum, const GLint *); +GLAPI void APIENTRY glVertexStream4fATI (GLenum, GLfloat, GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glVertexStream4fvATI (GLenum, const GLfloat *); +GLAPI void APIENTRY glVertexStream4dATI (GLenum, GLdouble, GLdouble, GLdouble, GLdouble); +GLAPI void APIENTRY glVertexStream4dvATI (GLenum, const GLdouble *); +GLAPI void APIENTRY glNormalStream3bATI (GLenum, GLbyte, GLbyte, GLbyte); +GLAPI void APIENTRY glNormalStream3bvATI (GLenum, const GLbyte *); +GLAPI void APIENTRY glNormalStream3sATI (GLenum, GLshort, GLshort, GLshort); +GLAPI void APIENTRY glNormalStream3svATI (GLenum, const GLshort *); +GLAPI void APIENTRY glNormalStream3iATI (GLenum, GLint, GLint, GLint); +GLAPI void APIENTRY glNormalStream3ivATI (GLenum, const GLint *); +GLAPI void APIENTRY glNormalStream3fATI (GLenum, GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glNormalStream3fvATI (GLenum, const GLfloat *); +GLAPI void APIENTRY glNormalStream3dATI (GLenum, GLdouble, GLdouble, GLdouble); +GLAPI void APIENTRY glNormalStream3dvATI (GLenum, const GLdouble *); +GLAPI void APIENTRY glClientActiveVertexStreamATI (GLenum); +GLAPI void APIENTRY glVertexBlendEnviATI (GLenum, GLint); +GLAPI void APIENTRY glVertexBlendEnvfATI (GLenum, GLfloat); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLVERTEXSTREAM1SATIPROC) (GLenum stream, GLshort x); +typedef void (APIENTRYP PFNGLVERTEXSTREAM1SVATIPROC) (GLenum stream, const GLshort *coords); +typedef void (APIENTRYP PFNGLVERTEXSTREAM1IATIPROC) (GLenum stream, GLint x); +typedef void (APIENTRYP PFNGLVERTEXSTREAM1IVATIPROC) (GLenum stream, const GLint *coords); +typedef void (APIENTRYP PFNGLVERTEXSTREAM1FATIPROC) (GLenum stream, GLfloat x); +typedef void (APIENTRYP PFNGLVERTEXSTREAM1FVATIPROC) (GLenum stream, const GLfloat *coords); +typedef void (APIENTRYP PFNGLVERTEXSTREAM1DATIPROC) (GLenum stream, GLdouble x); +typedef void (APIENTRYP PFNGLVERTEXSTREAM1DVATIPROC) (GLenum stream, const GLdouble *coords); +typedef void (APIENTRYP PFNGLVERTEXSTREAM2SATIPROC) (GLenum stream, GLshort x, GLshort y); +typedef void (APIENTRYP PFNGLVERTEXSTREAM2SVATIPROC) (GLenum stream, const GLshort *coords); +typedef void (APIENTRYP PFNGLVERTEXSTREAM2IATIPROC) (GLenum stream, GLint x, GLint y); +typedef void (APIENTRYP PFNGLVERTEXSTREAM2IVATIPROC) (GLenum stream, const GLint *coords); +typedef void (APIENTRYP PFNGLVERTEXSTREAM2FATIPROC) (GLenum stream, GLfloat x, GLfloat y); +typedef void (APIENTRYP PFNGLVERTEXSTREAM2FVATIPROC) (GLenum stream, const GLfloat *coords); +typedef void (APIENTRYP PFNGLVERTEXSTREAM2DATIPROC) (GLenum stream, GLdouble x, GLdouble y); +typedef void (APIENTRYP PFNGLVERTEXSTREAM2DVATIPROC) (GLenum stream, const GLdouble *coords); +typedef void (APIENTRYP PFNGLVERTEXSTREAM3SATIPROC) (GLenum stream, GLshort x, GLshort y, GLshort z); +typedef void (APIENTRYP PFNGLVERTEXSTREAM3SVATIPROC) (GLenum stream, const GLshort *coords); +typedef void (APIENTRYP PFNGLVERTEXSTREAM3IATIPROC) (GLenum stream, GLint x, GLint y, GLint z); +typedef void (APIENTRYP PFNGLVERTEXSTREAM3IVATIPROC) (GLenum stream, const GLint *coords); +typedef void (APIENTRYP PFNGLVERTEXSTREAM3FATIPROC) (GLenum stream, GLfloat x, GLfloat y, GLfloat z); +typedef void (APIENTRYP PFNGLVERTEXSTREAM3FVATIPROC) (GLenum stream, const GLfloat *coords); +typedef void (APIENTRYP PFNGLVERTEXSTREAM3DATIPROC) (GLenum stream, GLdouble x, GLdouble y, GLdouble z); +typedef void (APIENTRYP PFNGLVERTEXSTREAM3DVATIPROC) (GLenum stream, const GLdouble *coords); +typedef void (APIENTRYP PFNGLVERTEXSTREAM4SATIPROC) (GLenum stream, GLshort x, GLshort y, GLshort z, GLshort w); +typedef void (APIENTRYP PFNGLVERTEXSTREAM4SVATIPROC) (GLenum stream, const GLshort *coords); +typedef void (APIENTRYP PFNGLVERTEXSTREAM4IATIPROC) (GLenum stream, GLint x, GLint y, GLint z, GLint w); +typedef void (APIENTRYP PFNGLVERTEXSTREAM4IVATIPROC) (GLenum stream, const GLint *coords); +typedef void (APIENTRYP PFNGLVERTEXSTREAM4FATIPROC) (GLenum stream, GLfloat x, GLfloat y, GLfloat z, GLfloat w); +typedef void (APIENTRYP PFNGLVERTEXSTREAM4FVATIPROC) (GLenum stream, const GLfloat *coords); +typedef void (APIENTRYP PFNGLVERTEXSTREAM4DATIPROC) (GLenum stream, GLdouble x, GLdouble y, GLdouble z, GLdouble w); +typedef void (APIENTRYP PFNGLVERTEXSTREAM4DVATIPROC) (GLenum stream, const GLdouble *coords); +typedef void (APIENTRYP PFNGLNORMALSTREAM3BATIPROC) (GLenum stream, GLbyte nx, GLbyte ny, GLbyte nz); +typedef void (APIENTRYP PFNGLNORMALSTREAM3BVATIPROC) (GLenum stream, const GLbyte *coords); +typedef void (APIENTRYP PFNGLNORMALSTREAM3SATIPROC) (GLenum stream, GLshort nx, GLshort ny, GLshort nz); +typedef void (APIENTRYP PFNGLNORMALSTREAM3SVATIPROC) (GLenum stream, const GLshort *coords); +typedef void (APIENTRYP PFNGLNORMALSTREAM3IATIPROC) (GLenum stream, GLint nx, GLint ny, GLint nz); +typedef void (APIENTRYP PFNGLNORMALSTREAM3IVATIPROC) (GLenum stream, const GLint *coords); +typedef void (APIENTRYP PFNGLNORMALSTREAM3FATIPROC) (GLenum stream, GLfloat nx, GLfloat ny, GLfloat nz); +typedef void (APIENTRYP PFNGLNORMALSTREAM3FVATIPROC) (GLenum stream, const GLfloat *coords); +typedef void (APIENTRYP PFNGLNORMALSTREAM3DATIPROC) (GLenum stream, GLdouble nx, GLdouble ny, GLdouble nz); +typedef void (APIENTRYP PFNGLNORMALSTREAM3DVATIPROC) (GLenum stream, const GLdouble *coords); +typedef void (APIENTRYP PFNGLCLIENTACTIVEVERTEXSTREAMATIPROC) (GLenum stream); +typedef void (APIENTRYP PFNGLVERTEXBLENDENVIATIPROC) (GLenum pname, GLint param); +typedef void (APIENTRYP PFNGLVERTEXBLENDENVFATIPROC) (GLenum pname, GLfloat param); +#endif + +#ifndef GL_ATI_element_array +#define GL_ATI_element_array 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glElementPointerATI (GLenum, const GLvoid *); +GLAPI void APIENTRY glDrawElementArrayATI (GLenum, GLsizei); +GLAPI void APIENTRY glDrawRangeElementArrayATI (GLenum, GLuint, GLuint, GLsizei); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLELEMENTPOINTERATIPROC) (GLenum type, const GLvoid *pointer); +typedef void (APIENTRYP PFNGLDRAWELEMENTARRAYATIPROC) (GLenum mode, GLsizei count); +typedef void (APIENTRYP PFNGLDRAWRANGEELEMENTARRAYATIPROC) (GLenum mode, GLuint start, GLuint end, GLsizei count); +#endif + +#ifndef GL_SUN_mesh_array +#define GL_SUN_mesh_array 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glDrawMeshArraysSUN (GLenum, GLint, GLsizei, GLsizei); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLDRAWMESHARRAYSSUNPROC) (GLenum mode, GLint first, GLsizei count, GLsizei width); +#endif + +#ifndef GL_SUN_slice_accum +#define GL_SUN_slice_accum 1 +#endif + +#ifndef GL_NV_multisample_filter_hint +#define GL_NV_multisample_filter_hint 1 +#endif + +#ifndef GL_NV_depth_clamp +#define GL_NV_depth_clamp 1 +#endif + +#ifndef GL_NV_occlusion_query +#define GL_NV_occlusion_query 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glGenOcclusionQueriesNV (GLsizei, GLuint *); +GLAPI void APIENTRY glDeleteOcclusionQueriesNV (GLsizei, const GLuint *); +GLAPI GLboolean APIENTRY glIsOcclusionQueryNV (GLuint); +GLAPI void APIENTRY glBeginOcclusionQueryNV (GLuint); +GLAPI void APIENTRY glEndOcclusionQueryNV (void); +GLAPI void APIENTRY glGetOcclusionQueryivNV (GLuint, GLenum, GLint *); +GLAPI void APIENTRY glGetOcclusionQueryuivNV (GLuint, GLenum, GLuint *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLGENOCCLUSIONQUERIESNVPROC) (GLsizei n, GLuint *ids); +typedef void (APIENTRYP PFNGLDELETEOCCLUSIONQUERIESNVPROC) (GLsizei n, const GLuint *ids); +typedef GLboolean (APIENTRYP PFNGLISOCCLUSIONQUERYNVPROC) (GLuint id); +typedef void (APIENTRYP PFNGLBEGINOCCLUSIONQUERYNVPROC) (GLuint id); +typedef void (APIENTRYP PFNGLENDOCCLUSIONQUERYNVPROC) (void); +typedef void (APIENTRYP PFNGLGETOCCLUSIONQUERYIVNVPROC) (GLuint id, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLGETOCCLUSIONQUERYUIVNVPROC) (GLuint id, GLenum pname, GLuint *params); +#endif + +#ifndef GL_NV_point_sprite +#define GL_NV_point_sprite 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glPointParameteriNV (GLenum, GLint); +GLAPI void APIENTRY glPointParameterivNV (GLenum, const GLint *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLPOINTPARAMETERINVPROC) (GLenum pname, GLint param); +typedef void (APIENTRYP PFNGLPOINTPARAMETERIVNVPROC) (GLenum pname, const GLint *params); +#endif + +#ifndef GL_NV_texture_shader3 +#define GL_NV_texture_shader3 1 +#endif + +#ifndef GL_NV_vertex_program1_1 +#define GL_NV_vertex_program1_1 1 +#endif + +#ifndef GL_EXT_shadow_funcs +#define GL_EXT_shadow_funcs 1 +#endif + +#ifndef GL_EXT_stencil_two_side +#define GL_EXT_stencil_two_side 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glActiveStencilFaceEXT (GLenum); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLACTIVESTENCILFACEEXTPROC) (GLenum face); +#endif + +#ifndef GL_ATI_text_fragment_shader +#define GL_ATI_text_fragment_shader 1 +#endif + +#ifndef GL_APPLE_client_storage +#define GL_APPLE_client_storage 1 +#endif + +#ifndef GL_APPLE_element_array +#define GL_APPLE_element_array 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glElementPointerAPPLE (GLenum, const GLvoid *); +GLAPI void APIENTRY glDrawElementArrayAPPLE (GLenum, GLint, GLsizei); +GLAPI void APIENTRY glDrawRangeElementArrayAPPLE (GLenum, GLuint, GLuint, GLint, GLsizei); +GLAPI void APIENTRY glMultiDrawElementArrayAPPLE (GLenum, const GLint *, const GLsizei *, GLsizei); +GLAPI void APIENTRY glMultiDrawRangeElementArrayAPPLE (GLenum, GLuint, GLuint, const GLint *, const GLsizei *, GLsizei); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLELEMENTPOINTERAPPLEPROC) (GLenum type, const GLvoid *pointer); +typedef void (APIENTRYP PFNGLDRAWELEMENTARRAYAPPLEPROC) (GLenum mode, GLint first, GLsizei count); +typedef void (APIENTRYP PFNGLDRAWRANGEELEMENTARRAYAPPLEPROC) (GLenum mode, GLuint start, GLuint end, GLint first, GLsizei count); +typedef void (APIENTRYP PFNGLMULTIDRAWELEMENTARRAYAPPLEPROC) (GLenum mode, const GLint *first, const GLsizei *count, GLsizei primcount); +typedef void (APIENTRYP PFNGLMULTIDRAWRANGEELEMENTARRAYAPPLEPROC) (GLenum mode, GLuint start, GLuint end, const GLint *first, const GLsizei *count, GLsizei primcount); +#endif + +#ifndef GL_APPLE_fence +#define GL_APPLE_fence 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glGenFencesAPPLE (GLsizei, GLuint *); +GLAPI void APIENTRY glDeleteFencesAPPLE (GLsizei, const GLuint *); +GLAPI void APIENTRY glSetFenceAPPLE (GLuint); +GLAPI GLboolean APIENTRY glIsFenceAPPLE (GLuint); +GLAPI GLboolean APIENTRY glTestFenceAPPLE (GLuint); +GLAPI void APIENTRY glFinishFenceAPPLE (GLuint); +GLAPI GLboolean APIENTRY glTestObjectAPPLE (GLenum, GLuint); +GLAPI void APIENTRY glFinishObjectAPPLE (GLenum, GLint); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLGENFENCESAPPLEPROC) (GLsizei n, GLuint *fences); +typedef void (APIENTRYP PFNGLDELETEFENCESAPPLEPROC) (GLsizei n, const GLuint *fences); +typedef void (APIENTRYP PFNGLSETFENCEAPPLEPROC) (GLuint fence); +typedef GLboolean (APIENTRYP PFNGLISFENCEAPPLEPROC) (GLuint fence); +typedef GLboolean (APIENTRYP PFNGLTESTFENCEAPPLEPROC) (GLuint fence); +typedef void (APIENTRYP PFNGLFINISHFENCEAPPLEPROC) (GLuint fence); +typedef GLboolean (APIENTRYP PFNGLTESTOBJECTAPPLEPROC) (GLenum object, GLuint name); +typedef void (APIENTRYP PFNGLFINISHOBJECTAPPLEPROC) (GLenum object, GLint name); +#endif + +#ifndef GL_APPLE_vertex_array_object +#define GL_APPLE_vertex_array_object 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glBindVertexArrayAPPLE (GLuint); +GLAPI void APIENTRY glDeleteVertexArraysAPPLE (GLsizei, const GLuint *); +GLAPI void APIENTRY glGenVertexArraysAPPLE (GLsizei, GLuint *); +GLAPI GLboolean APIENTRY glIsVertexArrayAPPLE (GLuint); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLBINDVERTEXARRAYAPPLEPROC) (GLuint array); +typedef void (APIENTRYP PFNGLDELETEVERTEXARRAYSAPPLEPROC) (GLsizei n, const GLuint *arrays); +typedef void (APIENTRYP PFNGLGENVERTEXARRAYSAPPLEPROC) (GLsizei n, GLuint *arrays); +typedef GLboolean (APIENTRYP PFNGLISVERTEXARRAYAPPLEPROC) (GLuint array); +#endif + +#ifndef GL_APPLE_vertex_array_range +#define GL_APPLE_vertex_array_range 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glVertexArrayRangeAPPLE (GLsizei, GLvoid *); +GLAPI void APIENTRY glFlushVertexArrayRangeAPPLE (GLsizei, GLvoid *); +GLAPI void APIENTRY glVertexArrayParameteriAPPLE (GLenum, GLint); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLVERTEXARRAYRANGEAPPLEPROC) (GLsizei length, GLvoid *pointer); +typedef void (APIENTRYP PFNGLFLUSHVERTEXARRAYRANGEAPPLEPROC) (GLsizei length, GLvoid *pointer); +typedef void (APIENTRYP PFNGLVERTEXARRAYPARAMETERIAPPLEPROC) (GLenum pname, GLint param); +#endif + +#ifndef GL_APPLE_ycbcr_422 +#define GL_APPLE_ycbcr_422 1 +#endif + +#ifndef GL_S3_s3tc +#define GL_S3_s3tc 1 +#endif + +#ifndef GL_ATI_draw_buffers +#define GL_ATI_draw_buffers 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glDrawBuffersATI (GLsizei, const GLenum *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLDRAWBUFFERSATIPROC) (GLsizei n, const GLenum *bufs); +#endif + +#ifndef GL_ATI_pixel_format_float +#define GL_ATI_pixel_format_float 1 +/* This is really a WGL extension, but defines some associated GL enums. + * ATI does not export "GL_ATI_pixel_format_float" in the GL_EXTENSIONS string. + */ +#endif + +#ifndef GL_ATI_texture_env_combine3 +#define GL_ATI_texture_env_combine3 1 +#endif + +#ifndef GL_ATI_texture_float +#define GL_ATI_texture_float 1 +#endif + +#ifndef GL_NV_float_buffer +#define GL_NV_float_buffer 1 +#endif + +#ifndef GL_NV_fragment_program +#define GL_NV_fragment_program 1 +/* Some NV_fragment_program entry points are shared with ARB_vertex_program. */ +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glProgramNamedParameter4fNV (GLuint, GLsizei, const GLubyte *, GLfloat, GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glProgramNamedParameter4dNV (GLuint, GLsizei, const GLubyte *, GLdouble, GLdouble, GLdouble, GLdouble); +GLAPI void APIENTRY glProgramNamedParameter4fvNV (GLuint, GLsizei, const GLubyte *, const GLfloat *); +GLAPI void APIENTRY glProgramNamedParameter4dvNV (GLuint, GLsizei, const GLubyte *, const GLdouble *); +GLAPI void APIENTRY glGetProgramNamedParameterfvNV (GLuint, GLsizei, const GLubyte *, GLfloat *); +GLAPI void APIENTRY glGetProgramNamedParameterdvNV (GLuint, GLsizei, const GLubyte *, GLdouble *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLPROGRAMNAMEDPARAMETER4FNVPROC) (GLuint id, GLsizei len, const GLubyte *name, GLfloat x, GLfloat y, GLfloat z, GLfloat w); +typedef void (APIENTRYP PFNGLPROGRAMNAMEDPARAMETER4DNVPROC) (GLuint id, GLsizei len, const GLubyte *name, GLdouble x, GLdouble y, GLdouble z, GLdouble w); +typedef void (APIENTRYP PFNGLPROGRAMNAMEDPARAMETER4FVNVPROC) (GLuint id, GLsizei len, const GLubyte *name, const GLfloat *v); +typedef void (APIENTRYP PFNGLPROGRAMNAMEDPARAMETER4DVNVPROC) (GLuint id, GLsizei len, const GLubyte *name, const GLdouble *v); +typedef void (APIENTRYP PFNGLGETPROGRAMNAMEDPARAMETERFVNVPROC) (GLuint id, GLsizei len, const GLubyte *name, GLfloat *params); +typedef void (APIENTRYP PFNGLGETPROGRAMNAMEDPARAMETERDVNVPROC) (GLuint id, GLsizei len, const GLubyte *name, GLdouble *params); +#endif + +#ifndef GL_NV_half_float +#define GL_NV_half_float 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glVertex2hNV (GLhalfNV, GLhalfNV); +GLAPI void APIENTRY glVertex2hvNV (const GLhalfNV *); +GLAPI void APIENTRY glVertex3hNV (GLhalfNV, GLhalfNV, GLhalfNV); +GLAPI void APIENTRY glVertex3hvNV (const GLhalfNV *); +GLAPI void APIENTRY glVertex4hNV (GLhalfNV, GLhalfNV, GLhalfNV, GLhalfNV); +GLAPI void APIENTRY glVertex4hvNV (const GLhalfNV *); +GLAPI void APIENTRY glNormal3hNV (GLhalfNV, GLhalfNV, GLhalfNV); +GLAPI void APIENTRY glNormal3hvNV (const GLhalfNV *); +GLAPI void APIENTRY glColor3hNV (GLhalfNV, GLhalfNV, GLhalfNV); +GLAPI void APIENTRY glColor3hvNV (const GLhalfNV *); +GLAPI void APIENTRY glColor4hNV (GLhalfNV, GLhalfNV, GLhalfNV, GLhalfNV); +GLAPI void APIENTRY glColor4hvNV (const GLhalfNV *); +GLAPI void APIENTRY glTexCoord1hNV (GLhalfNV); +GLAPI void APIENTRY glTexCoord1hvNV (const GLhalfNV *); +GLAPI void APIENTRY glTexCoord2hNV (GLhalfNV, GLhalfNV); +GLAPI void APIENTRY glTexCoord2hvNV (const GLhalfNV *); +GLAPI void APIENTRY glTexCoord3hNV (GLhalfNV, GLhalfNV, GLhalfNV); +GLAPI void APIENTRY glTexCoord3hvNV (const GLhalfNV *); +GLAPI void APIENTRY glTexCoord4hNV (GLhalfNV, GLhalfNV, GLhalfNV, GLhalfNV); +GLAPI void APIENTRY glTexCoord4hvNV (const GLhalfNV *); +GLAPI void APIENTRY glMultiTexCoord1hNV (GLenum, GLhalfNV); +GLAPI void APIENTRY glMultiTexCoord1hvNV (GLenum, const GLhalfNV *); +GLAPI void APIENTRY glMultiTexCoord2hNV (GLenum, GLhalfNV, GLhalfNV); +GLAPI void APIENTRY glMultiTexCoord2hvNV (GLenum, const GLhalfNV *); +GLAPI void APIENTRY glMultiTexCoord3hNV (GLenum, GLhalfNV, GLhalfNV, GLhalfNV); +GLAPI void APIENTRY glMultiTexCoord3hvNV (GLenum, const GLhalfNV *); +GLAPI void APIENTRY glMultiTexCoord4hNV (GLenum, GLhalfNV, GLhalfNV, GLhalfNV, GLhalfNV); +GLAPI void APIENTRY glMultiTexCoord4hvNV (GLenum, const GLhalfNV *); +GLAPI void APIENTRY glFogCoordhNV (GLhalfNV); +GLAPI void APIENTRY glFogCoordhvNV (const GLhalfNV *); +GLAPI void APIENTRY glSecondaryColor3hNV (GLhalfNV, GLhalfNV, GLhalfNV); +GLAPI void APIENTRY glSecondaryColor3hvNV (const GLhalfNV *); +GLAPI void APIENTRY glVertexWeighthNV (GLhalfNV); +GLAPI void APIENTRY glVertexWeighthvNV (const GLhalfNV *); +GLAPI void APIENTRY glVertexAttrib1hNV (GLuint, GLhalfNV); +GLAPI void APIENTRY glVertexAttrib1hvNV (GLuint, const GLhalfNV *); +GLAPI void APIENTRY glVertexAttrib2hNV (GLuint, GLhalfNV, GLhalfNV); +GLAPI void APIENTRY glVertexAttrib2hvNV (GLuint, const GLhalfNV *); +GLAPI void APIENTRY glVertexAttrib3hNV (GLuint, GLhalfNV, GLhalfNV, GLhalfNV); +GLAPI void APIENTRY glVertexAttrib3hvNV (GLuint, const GLhalfNV *); +GLAPI void APIENTRY glVertexAttrib4hNV (GLuint, GLhalfNV, GLhalfNV, GLhalfNV, GLhalfNV); +GLAPI void APIENTRY glVertexAttrib4hvNV (GLuint, const GLhalfNV *); +GLAPI void APIENTRY glVertexAttribs1hvNV (GLuint, GLsizei, const GLhalfNV *); +GLAPI void APIENTRY glVertexAttribs2hvNV (GLuint, GLsizei, const GLhalfNV *); +GLAPI void APIENTRY glVertexAttribs3hvNV (GLuint, GLsizei, const GLhalfNV *); +GLAPI void APIENTRY glVertexAttribs4hvNV (GLuint, GLsizei, const GLhalfNV *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLVERTEX2HNVPROC) (GLhalfNV x, GLhalfNV y); +typedef void (APIENTRYP PFNGLVERTEX2HVNVPROC) (const GLhalfNV *v); +typedef void (APIENTRYP PFNGLVERTEX3HNVPROC) (GLhalfNV x, GLhalfNV y, GLhalfNV z); +typedef void (APIENTRYP PFNGLVERTEX3HVNVPROC) (const GLhalfNV *v); +typedef void (APIENTRYP PFNGLVERTEX4HNVPROC) (GLhalfNV x, GLhalfNV y, GLhalfNV z, GLhalfNV w); +typedef void (APIENTRYP PFNGLVERTEX4HVNVPROC) (const GLhalfNV *v); +typedef void (APIENTRYP PFNGLNORMAL3HNVPROC) (GLhalfNV nx, GLhalfNV ny, GLhalfNV nz); +typedef void (APIENTRYP PFNGLNORMAL3HVNVPROC) (const GLhalfNV *v); +typedef void (APIENTRYP PFNGLCOLOR3HNVPROC) (GLhalfNV red, GLhalfNV green, GLhalfNV blue); +typedef void (APIENTRYP PFNGLCOLOR3HVNVPROC) (const GLhalfNV *v); +typedef void (APIENTRYP PFNGLCOLOR4HNVPROC) (GLhalfNV red, GLhalfNV green, GLhalfNV blue, GLhalfNV alpha); +typedef void (APIENTRYP PFNGLCOLOR4HVNVPROC) (const GLhalfNV *v); +typedef void (APIENTRYP PFNGLTEXCOORD1HNVPROC) (GLhalfNV s); +typedef void (APIENTRYP PFNGLTEXCOORD1HVNVPROC) (const GLhalfNV *v); +typedef void (APIENTRYP PFNGLTEXCOORD2HNVPROC) (GLhalfNV s, GLhalfNV t); +typedef void (APIENTRYP PFNGLTEXCOORD2HVNVPROC) (const GLhalfNV *v); +typedef void (APIENTRYP PFNGLTEXCOORD3HNVPROC) (GLhalfNV s, GLhalfNV t, GLhalfNV r); +typedef void (APIENTRYP PFNGLTEXCOORD3HVNVPROC) (const GLhalfNV *v); +typedef void (APIENTRYP PFNGLTEXCOORD4HNVPROC) (GLhalfNV s, GLhalfNV t, GLhalfNV r, GLhalfNV q); +typedef void (APIENTRYP PFNGLTEXCOORD4HVNVPROC) (const GLhalfNV *v); +typedef void (APIENTRYP PFNGLMULTITEXCOORD1HNVPROC) (GLenum target, GLhalfNV s); +typedef void (APIENTRYP PFNGLMULTITEXCOORD1HVNVPROC) (GLenum target, const GLhalfNV *v); +typedef void (APIENTRYP PFNGLMULTITEXCOORD2HNVPROC) (GLenum target, GLhalfNV s, GLhalfNV t); +typedef void (APIENTRYP PFNGLMULTITEXCOORD2HVNVPROC) (GLenum target, const GLhalfNV *v); +typedef void (APIENTRYP PFNGLMULTITEXCOORD3HNVPROC) (GLenum target, GLhalfNV s, GLhalfNV t, GLhalfNV r); +typedef void (APIENTRYP PFNGLMULTITEXCOORD3HVNVPROC) (GLenum target, const GLhalfNV *v); +typedef void (APIENTRYP PFNGLMULTITEXCOORD4HNVPROC) (GLenum target, GLhalfNV s, GLhalfNV t, GLhalfNV r, GLhalfNV q); +typedef void (APIENTRYP PFNGLMULTITEXCOORD4HVNVPROC) (GLenum target, const GLhalfNV *v); +typedef void (APIENTRYP PFNGLFOGCOORDHNVPROC) (GLhalfNV fog); +typedef void (APIENTRYP PFNGLFOGCOORDHVNVPROC) (const GLhalfNV *fog); +typedef void (APIENTRYP PFNGLSECONDARYCOLOR3HNVPROC) (GLhalfNV red, GLhalfNV green, GLhalfNV blue); +typedef void (APIENTRYP PFNGLSECONDARYCOLOR3HVNVPROC) (const GLhalfNV *v); +typedef void (APIENTRYP PFNGLVERTEXWEIGHTHNVPROC) (GLhalfNV weight); +typedef void (APIENTRYP PFNGLVERTEXWEIGHTHVNVPROC) (const GLhalfNV *weight); +typedef void (APIENTRYP PFNGLVERTEXATTRIB1HNVPROC) (GLuint index, GLhalfNV x); +typedef void (APIENTRYP PFNGLVERTEXATTRIB1HVNVPROC) (GLuint index, const GLhalfNV *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB2HNVPROC) (GLuint index, GLhalfNV x, GLhalfNV y); +typedef void (APIENTRYP PFNGLVERTEXATTRIB2HVNVPROC) (GLuint index, const GLhalfNV *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB3HNVPROC) (GLuint index, GLhalfNV x, GLhalfNV y, GLhalfNV z); +typedef void (APIENTRYP PFNGLVERTEXATTRIB3HVNVPROC) (GLuint index, const GLhalfNV *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIB4HNVPROC) (GLuint index, GLhalfNV x, GLhalfNV y, GLhalfNV z, GLhalfNV w); +typedef void (APIENTRYP PFNGLVERTEXATTRIB4HVNVPROC) (GLuint index, const GLhalfNV *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIBS1HVNVPROC) (GLuint index, GLsizei n, const GLhalfNV *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIBS2HVNVPROC) (GLuint index, GLsizei n, const GLhalfNV *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIBS3HVNVPROC) (GLuint index, GLsizei n, const GLhalfNV *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIBS4HVNVPROC) (GLuint index, GLsizei n, const GLhalfNV *v); +#endif + +#ifndef GL_NV_pixel_data_range +#define GL_NV_pixel_data_range 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glPixelDataRangeNV (GLenum, GLsizei, GLvoid *); +GLAPI void APIENTRY glFlushPixelDataRangeNV (GLenum); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLPIXELDATARANGENVPROC) (GLenum target, GLsizei length, GLvoid *pointer); +typedef void (APIENTRYP PFNGLFLUSHPIXELDATARANGENVPROC) (GLenum target); +#endif + +#ifndef GL_NV_primitive_restart +#define GL_NV_primitive_restart 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glPrimitiveRestartNV (void); +GLAPI void APIENTRY glPrimitiveRestartIndexNV (GLuint); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLPRIMITIVERESTARTNVPROC) (void); +typedef void (APIENTRYP PFNGLPRIMITIVERESTARTINDEXNVPROC) (GLuint index); +#endif + +#ifndef GL_NV_texture_expand_normal +#define GL_NV_texture_expand_normal 1 +#endif + +#ifndef GL_NV_vertex_program2 +#define GL_NV_vertex_program2 1 +#endif + +#ifndef GL_ATI_map_object_buffer +#define GL_ATI_map_object_buffer 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI GLvoid* APIENTRY glMapObjectBufferATI (GLuint); +GLAPI void APIENTRY glUnmapObjectBufferATI (GLuint); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef GLvoid* (APIENTRYP PFNGLMAPOBJECTBUFFERATIPROC) (GLuint buffer); +typedef void (APIENTRYP PFNGLUNMAPOBJECTBUFFERATIPROC) (GLuint buffer); +#endif + +#ifndef GL_ATI_separate_stencil +#define GL_ATI_separate_stencil 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glStencilOpSeparateATI (GLenum, GLenum, GLenum, GLenum); +GLAPI void APIENTRY glStencilFuncSeparateATI (GLenum, GLenum, GLint, GLuint); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLSTENCILOPSEPARATEATIPROC) (GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass); +typedef void (APIENTRYP PFNGLSTENCILFUNCSEPARATEATIPROC) (GLenum frontfunc, GLenum backfunc, GLint ref, GLuint mask); +#endif + +#ifndef GL_ATI_vertex_attrib_array_object +#define GL_ATI_vertex_attrib_array_object 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glVertexAttribArrayObjectATI (GLuint, GLint, GLenum, GLboolean, GLsizei, GLuint, GLuint); +GLAPI void APIENTRY glGetVertexAttribArrayObjectfvATI (GLuint, GLenum, GLfloat *); +GLAPI void APIENTRY glGetVertexAttribArrayObjectivATI (GLuint, GLenum, GLint *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLVERTEXATTRIBARRAYOBJECTATIPROC) (GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, GLuint buffer, GLuint offset); +typedef void (APIENTRYP PFNGLGETVERTEXATTRIBARRAYOBJECTFVATIPROC) (GLuint index, GLenum pname, GLfloat *params); +typedef void (APIENTRYP PFNGLGETVERTEXATTRIBARRAYOBJECTIVATIPROC) (GLuint index, GLenum pname, GLint *params); +#endif + +#ifndef GL_OES_read_format +#define GL_OES_read_format 1 +#endif + +#ifndef GL_EXT_depth_bounds_test +#define GL_EXT_depth_bounds_test 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glDepthBoundsEXT (GLclampd, GLclampd); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLDEPTHBOUNDSEXTPROC) (GLclampd zmin, GLclampd zmax); +#endif + +#ifndef GL_EXT_texture_mirror_clamp +#define GL_EXT_texture_mirror_clamp 1 +#endif + +#ifndef GL_EXT_blend_equation_separate +#define GL_EXT_blend_equation_separate 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glBlendEquationSeparateEXT (GLenum, GLenum); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLBLENDEQUATIONSEPARATEEXTPROC) (GLenum modeRGB, GLenum modeAlpha); +#endif + +#ifndef GL_MESA_pack_invert +#define GL_MESA_pack_invert 1 +#endif + +#ifndef GL_MESA_ycbcr_texture +#define GL_MESA_ycbcr_texture 1 +#endif + +#ifndef GL_EXT_pixel_buffer_object +#define GL_EXT_pixel_buffer_object 1 +#endif + +#ifndef GL_NV_fragment_program_option +#define GL_NV_fragment_program_option 1 +#endif + +#ifndef GL_NV_fragment_program2 +#define GL_NV_fragment_program2 1 +#endif + +#ifndef GL_NV_vertex_program2_option +#define GL_NV_vertex_program2_option 1 +#endif + +#ifndef GL_NV_vertex_program3 +#define GL_NV_vertex_program3 1 +#endif + +#ifndef GL_EXT_framebuffer_object +#define GL_EXT_framebuffer_object 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI GLboolean APIENTRY glIsRenderbufferEXT (GLuint); +GLAPI void APIENTRY glBindRenderbufferEXT (GLenum, GLuint); +GLAPI void APIENTRY glDeleteRenderbuffersEXT (GLsizei, const GLuint *); +GLAPI void APIENTRY glGenRenderbuffersEXT (GLsizei, GLuint *); +GLAPI void APIENTRY glRenderbufferStorageEXT (GLenum, GLenum, GLsizei, GLsizei); +GLAPI void APIENTRY glGetRenderbufferParameterivEXT (GLenum, GLenum, GLint *); +GLAPI GLboolean APIENTRY glIsFramebufferEXT (GLuint); +GLAPI void APIENTRY glBindFramebufferEXT (GLenum, GLuint); +GLAPI void APIENTRY glDeleteFramebuffersEXT (GLsizei, const GLuint *); +GLAPI void APIENTRY glGenFramebuffersEXT (GLsizei, GLuint *); +GLAPI GLenum APIENTRY glCheckFramebufferStatusEXT (GLenum); +GLAPI void APIENTRY glFramebufferTexture1DEXT (GLenum, GLenum, GLenum, GLuint, GLint); +GLAPI void APIENTRY glFramebufferTexture2DEXT (GLenum, GLenum, GLenum, GLuint, GLint); +GLAPI void APIENTRY glFramebufferTexture3DEXT (GLenum, GLenum, GLenum, GLuint, GLint, GLint); +GLAPI void APIENTRY glFramebufferRenderbufferEXT (GLenum, GLenum, GLenum, GLuint); +GLAPI void APIENTRY glGetFramebufferAttachmentParameterivEXT (GLenum, GLenum, GLenum, GLint *); +GLAPI void APIENTRY glGenerateMipmapEXT (GLenum); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef GLboolean (APIENTRYP PFNGLISRENDERBUFFEREXTPROC) (GLuint renderbuffer); +typedef void (APIENTRYP PFNGLBINDRENDERBUFFEREXTPROC) (GLenum target, GLuint renderbuffer); +typedef void (APIENTRYP PFNGLDELETERENDERBUFFERSEXTPROC) (GLsizei n, const GLuint *renderbuffers); +typedef void (APIENTRYP PFNGLGENRENDERBUFFERSEXTPROC) (GLsizei n, GLuint *renderbuffers); +typedef void (APIENTRYP PFNGLRENDERBUFFERSTORAGEEXTPROC) (GLenum target, GLenum internalformat, GLsizei width, GLsizei height); +typedef void (APIENTRYP PFNGLGETRENDERBUFFERPARAMETERIVEXTPROC) (GLenum target, GLenum pname, GLint *params); +typedef GLboolean (APIENTRYP PFNGLISFRAMEBUFFEREXTPROC) (GLuint framebuffer); +typedef void (APIENTRYP PFNGLBINDFRAMEBUFFEREXTPROC) (GLenum target, GLuint framebuffer); +typedef void (APIENTRYP PFNGLDELETEFRAMEBUFFERSEXTPROC) (GLsizei n, const GLuint *framebuffers); +typedef void (APIENTRYP PFNGLGENFRAMEBUFFERSEXTPROC) (GLsizei n, GLuint *framebuffers); +typedef GLenum (APIENTRYP PFNGLCHECKFRAMEBUFFERSTATUSEXTPROC) (GLenum target); +typedef void (APIENTRYP PFNGLFRAMEBUFFERTEXTURE1DEXTPROC) (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level); +typedef void (APIENTRYP PFNGLFRAMEBUFFERTEXTURE2DEXTPROC) (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level); +typedef void (APIENTRYP PFNGLFRAMEBUFFERTEXTURE3DEXTPROC) (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset); +typedef void (APIENTRYP PFNGLFRAMEBUFFERRENDERBUFFEREXTPROC) (GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer); +typedef void (APIENTRYP PFNGLGETFRAMEBUFFERATTACHMENTPARAMETERIVEXTPROC) (GLenum target, GLenum attachment, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLGENERATEMIPMAPEXTPROC) (GLenum target); +#endif + +#ifndef GL_GREMEDY_string_marker +#define GL_GREMEDY_string_marker 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glStringMarkerGREMEDY (GLsizei, const GLvoid *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLSTRINGMARKERGREMEDYPROC) (GLsizei len, const GLvoid *string); +#endif + +#ifndef GL_EXT_packed_depth_stencil +#define GL_EXT_packed_depth_stencil 1 +#endif + +#ifndef GL_EXT_stencil_clear_tag +#define GL_EXT_stencil_clear_tag 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glStencilClearTagEXT (GLsizei, GLuint); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLSTENCILCLEARTAGEXTPROC) (GLsizei stencilTagBits, GLuint stencilClearTag); +#endif + +#ifndef GL_EXT_texture_sRGB +#define GL_EXT_texture_sRGB 1 +#endif + +#ifndef GL_EXT_framebuffer_blit +#define GL_EXT_framebuffer_blit 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glBlitFramebufferEXT (GLint, GLint, GLint, GLint, GLint, GLint, GLint, GLint, GLbitfield, GLenum); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLBLITFRAMEBUFFEREXTPROC) (GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter); +#endif + +#ifndef GL_EXT_framebuffer_multisample +#define GL_EXT_framebuffer_multisample 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glRenderbufferStorageMultisampleEXT (GLenum, GLsizei, GLenum, GLsizei, GLsizei); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLRENDERBUFFERSTORAGEMULTISAMPLEEXTPROC) (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height); +#endif + +#ifndef GL_MESAX_texture_stack +#define GL_MESAX_texture_stack 1 +#endif + +#ifndef GL_EXT_timer_query +#define GL_EXT_timer_query 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glGetQueryObjecti64vEXT (GLuint, GLenum, GLint64EXT *); +GLAPI void APIENTRY glGetQueryObjectui64vEXT (GLuint, GLenum, GLuint64EXT *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLGETQUERYOBJECTI64VEXTPROC) (GLuint id, GLenum pname, GLint64EXT *params); +typedef void (APIENTRYP PFNGLGETQUERYOBJECTUI64VEXTPROC) (GLuint id, GLenum pname, GLuint64EXT *params); +#endif + +#ifndef GL_EXT_gpu_program_parameters +#define GL_EXT_gpu_program_parameters 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glProgramEnvParameters4fvEXT (GLenum, GLuint, GLsizei, const GLfloat *); +GLAPI void APIENTRY glProgramLocalParameters4fvEXT (GLenum, GLuint, GLsizei, const GLfloat *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLPROGRAMENVPARAMETERS4FVEXTPROC) (GLenum target, GLuint index, GLsizei count, const GLfloat *params); +typedef void (APIENTRYP PFNGLPROGRAMLOCALPARAMETERS4FVEXTPROC) (GLenum target, GLuint index, GLsizei count, const GLfloat *params); +#endif + +#ifndef GL_APPLE_flush_buffer_range +#define GL_APPLE_flush_buffer_range 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glBufferParameteriAPPLE (GLenum, GLenum, GLint); +GLAPI void APIENTRY glFlushMappedBufferRangeAPPLE (GLenum, GLintptr, GLsizeiptr); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLBUFFERPARAMETERIAPPLEPROC) (GLenum target, GLenum pname, GLint param); +typedef void (APIENTRYP PFNGLFLUSHMAPPEDBUFFERRANGEAPPLEPROC) (GLenum target, GLintptr offset, GLsizeiptr size); +#endif + +#ifndef GL_NV_gpu_program4 +#define GL_NV_gpu_program4 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glProgramLocalParameterI4iNV (GLenum, GLuint, GLint, GLint, GLint, GLint); +GLAPI void APIENTRY glProgramLocalParameterI4ivNV (GLenum, GLuint, const GLint *); +GLAPI void APIENTRY glProgramLocalParametersI4ivNV (GLenum, GLuint, GLsizei, const GLint *); +GLAPI void APIENTRY glProgramLocalParameterI4uiNV (GLenum, GLuint, GLuint, GLuint, GLuint, GLuint); +GLAPI void APIENTRY glProgramLocalParameterI4uivNV (GLenum, GLuint, const GLuint *); +GLAPI void APIENTRY glProgramLocalParametersI4uivNV (GLenum, GLuint, GLsizei, const GLuint *); +GLAPI void APIENTRY glProgramEnvParameterI4iNV (GLenum, GLuint, GLint, GLint, GLint, GLint); +GLAPI void APIENTRY glProgramEnvParameterI4ivNV (GLenum, GLuint, const GLint *); +GLAPI void APIENTRY glProgramEnvParametersI4ivNV (GLenum, GLuint, GLsizei, const GLint *); +GLAPI void APIENTRY glProgramEnvParameterI4uiNV (GLenum, GLuint, GLuint, GLuint, GLuint, GLuint); +GLAPI void APIENTRY glProgramEnvParameterI4uivNV (GLenum, GLuint, const GLuint *); +GLAPI void APIENTRY glProgramEnvParametersI4uivNV (GLenum, GLuint, GLsizei, const GLuint *); +GLAPI void APIENTRY glGetProgramLocalParameterIivNV (GLenum, GLuint, GLint *); +GLAPI void APIENTRY glGetProgramLocalParameterIuivNV (GLenum, GLuint, GLuint *); +GLAPI void APIENTRY glGetProgramEnvParameterIivNV (GLenum, GLuint, GLint *); +GLAPI void APIENTRY glGetProgramEnvParameterIuivNV (GLenum, GLuint, GLuint *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLPROGRAMLOCALPARAMETERI4INVPROC) (GLenum target, GLuint index, GLint x, GLint y, GLint z, GLint w); +typedef void (APIENTRYP PFNGLPROGRAMLOCALPARAMETERI4IVNVPROC) (GLenum target, GLuint index, const GLint *params); +typedef void (APIENTRYP PFNGLPROGRAMLOCALPARAMETERSI4IVNVPROC) (GLenum target, GLuint index, GLsizei count, const GLint *params); +typedef void (APIENTRYP PFNGLPROGRAMLOCALPARAMETERI4UINVPROC) (GLenum target, GLuint index, GLuint x, GLuint y, GLuint z, GLuint w); +typedef void (APIENTRYP PFNGLPROGRAMLOCALPARAMETERI4UIVNVPROC) (GLenum target, GLuint index, const GLuint *params); +typedef void (APIENTRYP PFNGLPROGRAMLOCALPARAMETERSI4UIVNVPROC) (GLenum target, GLuint index, GLsizei count, const GLuint *params); +typedef void (APIENTRYP PFNGLPROGRAMENVPARAMETERI4INVPROC) (GLenum target, GLuint index, GLint x, GLint y, GLint z, GLint w); +typedef void (APIENTRYP PFNGLPROGRAMENVPARAMETERI4IVNVPROC) (GLenum target, GLuint index, const GLint *params); +typedef void (APIENTRYP PFNGLPROGRAMENVPARAMETERSI4IVNVPROC) (GLenum target, GLuint index, GLsizei count, const GLint *params); +typedef void (APIENTRYP PFNGLPROGRAMENVPARAMETERI4UINVPROC) (GLenum target, GLuint index, GLuint x, GLuint y, GLuint z, GLuint w); +typedef void (APIENTRYP PFNGLPROGRAMENVPARAMETERI4UIVNVPROC) (GLenum target, GLuint index, const GLuint *params); +typedef void (APIENTRYP PFNGLPROGRAMENVPARAMETERSI4UIVNVPROC) (GLenum target, GLuint index, GLsizei count, const GLuint *params); +typedef void (APIENTRYP PFNGLGETPROGRAMLOCALPARAMETERIIVNVPROC) (GLenum target, GLuint index, GLint *params); +typedef void (APIENTRYP PFNGLGETPROGRAMLOCALPARAMETERIUIVNVPROC) (GLenum target, GLuint index, GLuint *params); +typedef void (APIENTRYP PFNGLGETPROGRAMENVPARAMETERIIVNVPROC) (GLenum target, GLuint index, GLint *params); +typedef void (APIENTRYP PFNGLGETPROGRAMENVPARAMETERIUIVNVPROC) (GLenum target, GLuint index, GLuint *params); +#endif + +#ifndef GL_NV_geometry_program4 +#define GL_NV_geometry_program4 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glProgramVertexLimitNV (GLenum, GLint); +GLAPI void APIENTRY glFramebufferTextureEXT (GLenum, GLenum, GLuint, GLint); +GLAPI void APIENTRY glFramebufferTextureLayerEXT (GLenum, GLenum, GLuint, GLint, GLint); +GLAPI void APIENTRY glFramebufferTextureFaceEXT (GLenum, GLenum, GLuint, GLint, GLenum); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLPROGRAMVERTEXLIMITNVPROC) (GLenum target, GLint limit); +typedef void (APIENTRYP PFNGLFRAMEBUFFERTEXTUREEXTPROC) (GLenum target, GLenum attachment, GLuint texture, GLint level); +typedef void (APIENTRYP PFNGLFRAMEBUFFERTEXTURELAYEREXTPROC) (GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer); +typedef void (APIENTRYP PFNGLFRAMEBUFFERTEXTUREFACEEXTPROC) (GLenum target, GLenum attachment, GLuint texture, GLint level, GLenum face); +#endif + +#ifndef GL_EXT_geometry_shader4 +#define GL_EXT_geometry_shader4 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glProgramParameteriEXT (GLuint, GLenum, GLint); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLPROGRAMPARAMETERIEXTPROC) (GLuint program, GLenum pname, GLint value); +#endif + +#ifndef GL_NV_vertex_program4 +#define GL_NV_vertex_program4 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glVertexAttribI1iEXT (GLuint, GLint); +GLAPI void APIENTRY glVertexAttribI2iEXT (GLuint, GLint, GLint); +GLAPI void APIENTRY glVertexAttribI3iEXT (GLuint, GLint, GLint, GLint); +GLAPI void APIENTRY glVertexAttribI4iEXT (GLuint, GLint, GLint, GLint, GLint); +GLAPI void APIENTRY glVertexAttribI1uiEXT (GLuint, GLuint); +GLAPI void APIENTRY glVertexAttribI2uiEXT (GLuint, GLuint, GLuint); +GLAPI void APIENTRY glVertexAttribI3uiEXT (GLuint, GLuint, GLuint, GLuint); +GLAPI void APIENTRY glVertexAttribI4uiEXT (GLuint, GLuint, GLuint, GLuint, GLuint); +GLAPI void APIENTRY glVertexAttribI1ivEXT (GLuint, const GLint *); +GLAPI void APIENTRY glVertexAttribI2ivEXT (GLuint, const GLint *); +GLAPI void APIENTRY glVertexAttribI3ivEXT (GLuint, const GLint *); +GLAPI void APIENTRY glVertexAttribI4ivEXT (GLuint, const GLint *); +GLAPI void APIENTRY glVertexAttribI1uivEXT (GLuint, const GLuint *); +GLAPI void APIENTRY glVertexAttribI2uivEXT (GLuint, const GLuint *); +GLAPI void APIENTRY glVertexAttribI3uivEXT (GLuint, const GLuint *); +GLAPI void APIENTRY glVertexAttribI4uivEXT (GLuint, const GLuint *); +GLAPI void APIENTRY glVertexAttribI4bvEXT (GLuint, const GLbyte *); +GLAPI void APIENTRY glVertexAttribI4svEXT (GLuint, const GLshort *); +GLAPI void APIENTRY glVertexAttribI4ubvEXT (GLuint, const GLubyte *); +GLAPI void APIENTRY glVertexAttribI4usvEXT (GLuint, const GLushort *); +GLAPI void APIENTRY glVertexAttribIPointerEXT (GLuint, GLint, GLenum, GLsizei, const GLvoid *); +GLAPI void APIENTRY glGetVertexAttribIivEXT (GLuint, GLenum, GLint *); +GLAPI void APIENTRY glGetVertexAttribIuivEXT (GLuint, GLenum, GLuint *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLVERTEXATTRIBI1IEXTPROC) (GLuint index, GLint x); +typedef void (APIENTRYP PFNGLVERTEXATTRIBI2IEXTPROC) (GLuint index, GLint x, GLint y); +typedef void (APIENTRYP PFNGLVERTEXATTRIBI3IEXTPROC) (GLuint index, GLint x, GLint y, GLint z); +typedef void (APIENTRYP PFNGLVERTEXATTRIBI4IEXTPROC) (GLuint index, GLint x, GLint y, GLint z, GLint w); +typedef void (APIENTRYP PFNGLVERTEXATTRIBI1UIEXTPROC) (GLuint index, GLuint x); +typedef void (APIENTRYP PFNGLVERTEXATTRIBI2UIEXTPROC) (GLuint index, GLuint x, GLuint y); +typedef void (APIENTRYP PFNGLVERTEXATTRIBI3UIEXTPROC) (GLuint index, GLuint x, GLuint y, GLuint z); +typedef void (APIENTRYP PFNGLVERTEXATTRIBI4UIEXTPROC) (GLuint index, GLuint x, GLuint y, GLuint z, GLuint w); +typedef void (APIENTRYP PFNGLVERTEXATTRIBI1IVEXTPROC) (GLuint index, const GLint *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIBI2IVEXTPROC) (GLuint index, const GLint *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIBI3IVEXTPROC) (GLuint index, const GLint *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIBI4IVEXTPROC) (GLuint index, const GLint *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIBI1UIVEXTPROC) (GLuint index, const GLuint *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIBI2UIVEXTPROC) (GLuint index, const GLuint *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIBI3UIVEXTPROC) (GLuint index, const GLuint *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIBI4UIVEXTPROC) (GLuint index, const GLuint *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIBI4BVEXTPROC) (GLuint index, const GLbyte *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIBI4SVEXTPROC) (GLuint index, const GLshort *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIBI4UBVEXTPROC) (GLuint index, const GLubyte *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIBI4USVEXTPROC) (GLuint index, const GLushort *v); +typedef void (APIENTRYP PFNGLVERTEXATTRIBIPOINTEREXTPROC) (GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer); +typedef void (APIENTRYP PFNGLGETVERTEXATTRIBIIVEXTPROC) (GLuint index, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLGETVERTEXATTRIBIUIVEXTPROC) (GLuint index, GLenum pname, GLuint *params); +#endif + +#ifndef GL_EXT_gpu_shader4 +#define GL_EXT_gpu_shader4 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glGetUniformuivEXT (GLuint, GLint, GLuint *); +GLAPI void APIENTRY glBindFragDataLocationEXT (GLuint, GLuint, const GLchar *); +GLAPI GLint APIENTRY glGetFragDataLocationEXT (GLuint, const GLchar *); +GLAPI void APIENTRY glUniform1uiEXT (GLint, GLuint); +GLAPI void APIENTRY glUniform2uiEXT (GLint, GLuint, GLuint); +GLAPI void APIENTRY glUniform3uiEXT (GLint, GLuint, GLuint, GLuint); +GLAPI void APIENTRY glUniform4uiEXT (GLint, GLuint, GLuint, GLuint, GLuint); +GLAPI void APIENTRY glUniform1uivEXT (GLint, GLsizei, const GLuint *); +GLAPI void APIENTRY glUniform2uivEXT (GLint, GLsizei, const GLuint *); +GLAPI void APIENTRY glUniform3uivEXT (GLint, GLsizei, const GLuint *); +GLAPI void APIENTRY glUniform4uivEXT (GLint, GLsizei, const GLuint *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLGETUNIFORMUIVEXTPROC) (GLuint program, GLint location, GLuint *params); +typedef void (APIENTRYP PFNGLBINDFRAGDATALOCATIONEXTPROC) (GLuint program, GLuint color, const GLchar *name); +typedef GLint (APIENTRYP PFNGLGETFRAGDATALOCATIONEXTPROC) (GLuint program, const GLchar *name); +typedef void (APIENTRYP PFNGLUNIFORM1UIEXTPROC) (GLint location, GLuint v0); +typedef void (APIENTRYP PFNGLUNIFORM2UIEXTPROC) (GLint location, GLuint v0, GLuint v1); +typedef void (APIENTRYP PFNGLUNIFORM3UIEXTPROC) (GLint location, GLuint v0, GLuint v1, GLuint v2); +typedef void (APIENTRYP PFNGLUNIFORM4UIEXTPROC) (GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3); +typedef void (APIENTRYP PFNGLUNIFORM1UIVEXTPROC) (GLint location, GLsizei count, const GLuint *value); +typedef void (APIENTRYP PFNGLUNIFORM2UIVEXTPROC) (GLint location, GLsizei count, const GLuint *value); +typedef void (APIENTRYP PFNGLUNIFORM3UIVEXTPROC) (GLint location, GLsizei count, const GLuint *value); +typedef void (APIENTRYP PFNGLUNIFORM4UIVEXTPROC) (GLint location, GLsizei count, const GLuint *value); +#endif + +#ifndef GL_EXT_draw_instanced +#define GL_EXT_draw_instanced 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glDrawArraysInstancedEXT (GLenum, GLint, GLsizei, GLsizei); +GLAPI void APIENTRY glDrawElementsInstancedEXT (GLenum, GLsizei, GLenum, const GLvoid *, GLsizei); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLDRAWARRAYSINSTANCEDEXTPROC) (GLenum mode, GLint start, GLsizei count, GLsizei primcount); +typedef void (APIENTRYP PFNGLDRAWELEMENTSINSTANCEDEXTPROC) (GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei primcount); +#endif + +#ifndef GL_EXT_packed_float +#define GL_EXT_packed_float 1 +#endif + +#ifndef GL_EXT_texture_array +#define GL_EXT_texture_array 1 +#endif + +#ifndef GL_EXT_texture_buffer_object +#define GL_EXT_texture_buffer_object 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glTexBufferEXT (GLenum, GLenum, GLuint); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLTEXBUFFEREXTPROC) (GLenum target, GLenum internalformat, GLuint buffer); +#endif + +#ifndef GL_EXT_texture_compression_latc +#define GL_EXT_texture_compression_latc 1 +#endif + +#ifndef GL_EXT_texture_compression_rgtc +#define GL_EXT_texture_compression_rgtc 1 +#endif + +#ifndef GL_EXT_texture_shared_exponent +#define GL_EXT_texture_shared_exponent 1 +#endif + +#ifndef GL_NV_depth_buffer_float +#define GL_NV_depth_buffer_float 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glDepthRangedNV (GLdouble, GLdouble); +GLAPI void APIENTRY glClearDepthdNV (GLdouble); +GLAPI void APIENTRY glDepthBoundsdNV (GLdouble, GLdouble); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLDEPTHRANGEDNVPROC) (GLdouble zNear, GLdouble zFar); +typedef void (APIENTRYP PFNGLCLEARDEPTHDNVPROC) (GLdouble depth); +typedef void (APIENTRYP PFNGLDEPTHBOUNDSDNVPROC) (GLdouble zmin, GLdouble zmax); +#endif + +#ifndef GL_NV_fragment_program4 +#define GL_NV_fragment_program4 1 +#endif + +#ifndef GL_NV_framebuffer_multisample_coverage +#define GL_NV_framebuffer_multisample_coverage 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glRenderbufferStorageMultisampleCoverageNV (GLenum, GLsizei, GLsizei, GLenum, GLsizei, GLsizei); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLRENDERBUFFERSTORAGEMULTISAMPLECOVERAGENVPROC) (GLenum target, GLsizei coverageSamples, GLsizei colorSamples, GLenum internalformat, GLsizei width, GLsizei height); +#endif + +#ifndef GL_EXT_framebuffer_sRGB +#define GL_EXT_framebuffer_sRGB 1 +#endif + +#ifndef GL_NV_geometry_shader4 +#define GL_NV_geometry_shader4 1 +#endif + +#ifndef GL_NV_parameter_buffer_object +#define GL_NV_parameter_buffer_object 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glProgramBufferParametersfvNV (GLenum, GLuint, GLuint, GLsizei, const GLfloat *); +GLAPI void APIENTRY glProgramBufferParametersIivNV (GLenum, GLuint, GLuint, GLsizei, const GLint *); +GLAPI void APIENTRY glProgramBufferParametersIuivNV (GLenum, GLuint, GLuint, GLsizei, const GLuint *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLPROGRAMBUFFERPARAMETERSFVNVPROC) (GLenum target, GLuint buffer, GLuint index, GLsizei count, const GLfloat *params); +typedef void (APIENTRYP PFNGLPROGRAMBUFFERPARAMETERSIIVNVPROC) (GLenum target, GLuint buffer, GLuint index, GLsizei count, const GLint *params); +typedef void (APIENTRYP PFNGLPROGRAMBUFFERPARAMETERSIUIVNVPROC) (GLenum target, GLuint buffer, GLuint index, GLsizei count, const GLuint *params); +#endif + +#ifndef GL_EXT_draw_buffers2 +#define GL_EXT_draw_buffers2 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glColorMaskIndexedEXT (GLuint, GLboolean, GLboolean, GLboolean, GLboolean); +GLAPI void APIENTRY glGetBooleanIndexedvEXT (GLenum, GLuint, GLboolean *); +GLAPI void APIENTRY glGetIntegerIndexedvEXT (GLenum, GLuint, GLint *); +GLAPI void APIENTRY glEnableIndexedEXT (GLenum, GLuint); +GLAPI void APIENTRY glDisableIndexedEXT (GLenum, GLuint); +GLAPI GLboolean APIENTRY glIsEnabledIndexedEXT (GLenum, GLuint); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLCOLORMASKINDEXEDEXTPROC) (GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a); +typedef void (APIENTRYP PFNGLGETBOOLEANINDEXEDVEXTPROC) (GLenum target, GLuint index, GLboolean *data); +typedef void (APIENTRYP PFNGLGETINTEGERINDEXEDVEXTPROC) (GLenum target, GLuint index, GLint *data); +typedef void (APIENTRYP PFNGLENABLEINDEXEDEXTPROC) (GLenum target, GLuint index); +typedef void (APIENTRYP PFNGLDISABLEINDEXEDEXTPROC) (GLenum target, GLuint index); +typedef GLboolean (APIENTRYP PFNGLISENABLEDINDEXEDEXTPROC) (GLenum target, GLuint index); +#endif + +#ifndef GL_NV_transform_feedback +#define GL_NV_transform_feedback 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glBeginTransformFeedbackNV (GLenum); +GLAPI void APIENTRY glEndTransformFeedbackNV (void); +GLAPI void APIENTRY glTransformFeedbackAttribsNV (GLuint, const GLint *, GLenum); +GLAPI void APIENTRY glBindBufferRangeNV (GLenum, GLuint, GLuint, GLintptr, GLsizeiptr); +GLAPI void APIENTRY glBindBufferOffsetNV (GLenum, GLuint, GLuint, GLintptr); +GLAPI void APIENTRY glBindBufferBaseNV (GLenum, GLuint, GLuint); +GLAPI void APIENTRY glTransformFeedbackVaryingsNV (GLuint, GLsizei, const GLint *, GLenum); +GLAPI void APIENTRY glActiveVaryingNV (GLuint, const GLchar *); +GLAPI GLint APIENTRY glGetVaryingLocationNV (GLuint, const GLchar *); +GLAPI void APIENTRY glGetActiveVaryingNV (GLuint, GLuint, GLsizei, GLsizei *, GLsizei *, GLenum *, GLchar *); +GLAPI void APIENTRY glGetTransformFeedbackVaryingNV (GLuint, GLuint, GLint *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLBEGINTRANSFORMFEEDBACKNVPROC) (GLenum primitiveMode); +typedef void (APIENTRYP PFNGLENDTRANSFORMFEEDBACKNVPROC) (void); +typedef void (APIENTRYP PFNGLTRANSFORMFEEDBACKATTRIBSNVPROC) (GLuint count, const GLint *attribs, GLenum bufferMode); +typedef void (APIENTRYP PFNGLBINDBUFFERRANGENVPROC) (GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size); +typedef void (APIENTRYP PFNGLBINDBUFFEROFFSETNVPROC) (GLenum target, GLuint index, GLuint buffer, GLintptr offset); +typedef void (APIENTRYP PFNGLBINDBUFFERBASENVPROC) (GLenum target, GLuint index, GLuint buffer); +typedef void (APIENTRYP PFNGLTRANSFORMFEEDBACKVARYINGSNVPROC) (GLuint program, GLsizei count, const GLint *locations, GLenum bufferMode); +typedef void (APIENTRYP PFNGLACTIVEVARYINGNVPROC) (GLuint program, const GLchar *name); +typedef GLint (APIENTRYP PFNGLGETVARYINGLOCATIONNVPROC) (GLuint program, const GLchar *name); +typedef void (APIENTRYP PFNGLGETACTIVEVARYINGNVPROC) (GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLsizei *size, GLenum *type, GLchar *name); +typedef void (APIENTRYP PFNGLGETTRANSFORMFEEDBACKVARYINGNVPROC) (GLuint program, GLuint index, GLint *location); +#endif + +#ifndef GL_EXT_bindable_uniform +#define GL_EXT_bindable_uniform 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glUniformBufferEXT (GLuint, GLint, GLuint); +GLAPI GLint APIENTRY glGetUniformBufferSizeEXT (GLuint, GLint); +GLAPI GLintptr APIENTRY glGetUniformOffsetEXT (GLuint, GLint); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLUNIFORMBUFFEREXTPROC) (GLuint program, GLint location, GLuint buffer); +typedef GLint (APIENTRYP PFNGLGETUNIFORMBUFFERSIZEEXTPROC) (GLuint program, GLint location); +typedef GLintptr (APIENTRYP PFNGLGETUNIFORMOFFSETEXTPROC) (GLuint program, GLint location); +#endif + +#ifndef GL_EXT_texture_integer +#define GL_EXT_texture_integer 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glTexParameterIivEXT (GLenum, GLenum, const GLint *); +GLAPI void APIENTRY glTexParameterIuivEXT (GLenum, GLenum, const GLuint *); +GLAPI void APIENTRY glGetTexParameterIivEXT (GLenum, GLenum, GLint *); +GLAPI void APIENTRY glGetTexParameterIuivEXT (GLenum, GLenum, GLuint *); +GLAPI void APIENTRY glClearColorIiEXT (GLint, GLint, GLint, GLint); +GLAPI void APIENTRY glClearColorIuiEXT (GLuint, GLuint, GLuint, GLuint); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLTEXPARAMETERIIVEXTPROC) (GLenum target, GLenum pname, const GLint *params); +typedef void (APIENTRYP PFNGLTEXPARAMETERIUIVEXTPROC) (GLenum target, GLenum pname, const GLuint *params); +typedef void (APIENTRYP PFNGLGETTEXPARAMETERIIVEXTPROC) (GLenum target, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLGETTEXPARAMETERIUIVEXTPROC) (GLenum target, GLenum pname, GLuint *params); +typedef void (APIENTRYP PFNGLCLEARCOLORIIEXTPROC) (GLint red, GLint green, GLint blue, GLint alpha); +typedef void (APIENTRYP PFNGLCLEARCOLORIUIEXTPROC) (GLuint red, GLuint green, GLuint blue, GLuint alpha); +#endif + +#ifndef GL_GREMEDY_frame_terminator +#define GL_GREMEDY_frame_terminator 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glFrameTerminatorGREMEDY (void); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLFRAMETERMINATORGREMEDYPROC) (void); +#endif + +#ifndef GL_NV_conditional_render +#define GL_NV_conditional_render 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glBeginConditionalRenderNV (GLuint, GLenum); +GLAPI void APIENTRY glEndConditionalRenderNV (void); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLBEGINCONDITIONALRENDERNVPROC) (GLuint id, GLenum mode); +typedef void (APIENTRYP PFNGLENDCONDITIONALRENDERNVPROC) (void); +#endif + +#ifndef GL_NV_present_video +#define GL_NV_present_video 1 +#endif + +#ifndef GL_EXT_transform_feedback +#define GL_EXT_transform_feedback 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glBeginTransformFeedbackEXT (GLenum); +GLAPI void APIENTRY glEndTransformFeedbackEXT (void); +GLAPI void APIENTRY glBindBufferRangeEXT (GLenum, GLuint, GLuint, GLintptr, GLsizeiptr); +GLAPI void APIENTRY glBindBufferOffsetEXT (GLenum, GLuint, GLuint, GLintptr); +GLAPI void APIENTRY glBindBufferBaseEXT (GLenum, GLuint, GLuint); +GLAPI void APIENTRY glTransformFeedbackVaryingsEXT (GLuint, GLsizei, const GLint *, GLenum); +GLAPI void APIENTRY glGetTransformFeedbackVaryingEXT (GLuint, GLuint, GLint *); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLBEGINTRANSFORMFEEDBACKEXTPROC) (GLenum primitiveMode); +typedef void (APIENTRYP PFNGLENDTRANSFORMFEEDBACKEXTPROC) (void); +typedef void (APIENTRYP PFNGLBINDBUFFERRANGEEXTPROC) (GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size); +typedef void (APIENTRYP PFNGLBINDBUFFEROFFSETEXTPROC) (GLenum target, GLuint index, GLuint buffer, GLintptr offset); +typedef void (APIENTRYP PFNGLBINDBUFFERBASEEXTPROC) (GLenum target, GLuint index, GLuint buffer); +typedef void (APIENTRYP PFNGLTRANSFORMFEEDBACKVARYINGSEXTPROC) (GLuint program, GLsizei count, const GLint *locations, GLenum bufferMode); +typedef void (APIENTRYP PFNGLGETTRANSFORMFEEDBACKVARYINGEXTPROC) (GLuint program, GLuint index, GLint *location); +#endif + +#ifndef GL_EXT_direct_state_access +#define GL_EXT_direct_state_access 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glClientAttribDefaultEXT (GLbitfield); +GLAPI void APIENTRY glPushClientAttribDefaultEXT (GLbitfield); +GLAPI void APIENTRY glMatrixLoadfEXT (GLenum, const GLfloat *); +GLAPI void APIENTRY glMatrixLoaddEXT (GLenum, const GLdouble *); +GLAPI void APIENTRY glMatrixMultfEXT (GLenum, const GLfloat *); +GLAPI void APIENTRY glMatrixMultdEXT (GLenum, const GLdouble *); +GLAPI void APIENTRY glMatrixLoadIdentityEXT (GLenum); +GLAPI void APIENTRY glMatrixRotatefEXT (GLenum, GLfloat, GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glMatrixRotatedEXT (GLenum, GLdouble, GLdouble, GLdouble, GLdouble); +GLAPI void APIENTRY glMatrixScalefEXT (GLenum, GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glMatrixScaledEXT (GLenum, GLdouble, GLdouble, GLdouble); +GLAPI void APIENTRY glMatrixTranslatefEXT (GLenum, GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glMatrixTranslatedEXT (GLenum, GLdouble, GLdouble, GLdouble); +GLAPI void APIENTRY glMatrixFrustumEXT (GLenum, GLdouble, GLdouble, GLdouble, GLdouble, GLdouble, GLdouble); +GLAPI void APIENTRY glMatrixOrthoEXT (GLenum, GLdouble, GLdouble, GLdouble, GLdouble, GLdouble, GLdouble); +GLAPI void APIENTRY glMatrixPopEXT (GLenum); +GLAPI void APIENTRY glMatrixPushEXT (GLenum); +GLAPI void APIENTRY glMatrixLoadTransposefEXT (GLenum, const GLfloat *); +GLAPI void APIENTRY glMatrixLoadTransposedEXT (GLenum, const GLdouble *); +GLAPI void APIENTRY glMatrixMultTransposefEXT (GLenum, const GLfloat *); +GLAPI void APIENTRY glMatrixMultTransposedEXT (GLenum, const GLdouble *); +GLAPI void APIENTRY glTextureParameterfEXT (GLuint, GLenum, GLenum, GLfloat); +GLAPI void APIENTRY glTextureParameterfvEXT (GLuint, GLenum, GLenum, const GLfloat *); +GLAPI void APIENTRY glTextureParameteriEXT (GLuint, GLenum, GLenum, GLint); +GLAPI void APIENTRY glTextureParameterivEXT (GLuint, GLenum, GLenum, const GLint *); +GLAPI void APIENTRY glTextureImage1DEXT (GLuint, GLenum, GLint, GLenum, GLsizei, GLint, GLenum, GLenum, const GLvoid *); +GLAPI void APIENTRY glTextureImage2DEXT (GLuint, GLenum, GLint, GLenum, GLsizei, GLsizei, GLint, GLenum, GLenum, const GLvoid *); +GLAPI void APIENTRY glTextureSubImage1DEXT (GLuint, GLenum, GLint, GLint, GLsizei, GLenum, GLenum, const GLvoid *); +GLAPI void APIENTRY glTextureSubImage2DEXT (GLuint, GLenum, GLint, GLint, GLint, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *); +GLAPI void APIENTRY glCopyTextureImage1DEXT (GLuint, GLenum, GLint, GLenum, GLint, GLint, GLsizei, GLint); +GLAPI void APIENTRY glCopyTextureImage2DEXT (GLuint, GLenum, GLint, GLenum, GLint, GLint, GLsizei, GLsizei, GLint); +GLAPI void APIENTRY glCopyTextureSubImage1DEXT (GLuint, GLenum, GLint, GLint, GLint, GLint, GLsizei); +GLAPI void APIENTRY glCopyTextureSubImage2DEXT (GLuint, GLenum, GLint, GLint, GLint, GLint, GLint, GLsizei, GLsizei); +GLAPI void APIENTRY glGetTextureImageEXT (GLuint, GLenum, GLint, GLenum, GLenum, GLvoid *); +GLAPI void APIENTRY glGetTextureParameterfvEXT (GLuint, GLenum, GLenum, GLfloat *); +GLAPI void APIENTRY glGetTextureParameterivEXT (GLuint, GLenum, GLenum, GLint *); +GLAPI void APIENTRY glGetTextureLevelParameterfvEXT (GLuint, GLenum, GLint, GLenum, GLfloat *); +GLAPI void APIENTRY glGetTextureLevelParameterivEXT (GLuint, GLenum, GLint, GLenum, GLint *); +GLAPI void APIENTRY glTextureImage3DEXT (GLuint, GLenum, GLint, GLenum, GLsizei, GLsizei, GLsizei, GLint, GLenum, GLenum, const GLvoid *); +GLAPI void APIENTRY glTextureSubImage3DEXT (GLuint, GLenum, GLint, GLint, GLint, GLint, GLsizei, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *); +GLAPI void APIENTRY glCopyTextureSubImage3DEXT (GLuint, GLenum, GLint, GLint, GLint, GLint, GLint, GLint, GLsizei, GLsizei); +GLAPI void APIENTRY glMultiTexParameterfEXT (GLenum, GLenum, GLenum, GLfloat); +GLAPI void APIENTRY glMultiTexParameterfvEXT (GLenum, GLenum, GLenum, const GLfloat *); +GLAPI void APIENTRY glMultiTexParameteriEXT (GLenum, GLenum, GLenum, GLint); +GLAPI void APIENTRY glMultiTexParameterivEXT (GLenum, GLenum, GLenum, const GLint *); +GLAPI void APIENTRY glMultiTexImage1DEXT (GLenum, GLenum, GLint, GLenum, GLsizei, GLint, GLenum, GLenum, const GLvoid *); +GLAPI void APIENTRY glMultiTexImage2DEXT (GLenum, GLenum, GLint, GLenum, GLsizei, GLsizei, GLint, GLenum, GLenum, const GLvoid *); +GLAPI void APIENTRY glMultiTexSubImage1DEXT (GLenum, GLenum, GLint, GLint, GLsizei, GLenum, GLenum, const GLvoid *); +GLAPI void APIENTRY glMultiTexSubImage2DEXT (GLenum, GLenum, GLint, GLint, GLint, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *); +GLAPI void APIENTRY glCopyMultiTexImage1DEXT (GLenum, GLenum, GLint, GLenum, GLint, GLint, GLsizei, GLint); +GLAPI void APIENTRY glCopyMultiTexImage2DEXT (GLenum, GLenum, GLint, GLenum, GLint, GLint, GLsizei, GLsizei, GLint); +GLAPI void APIENTRY glCopyMultiTexSubImage1DEXT (GLenum, GLenum, GLint, GLint, GLint, GLint, GLsizei); +GLAPI void APIENTRY glCopyMultiTexSubImage2DEXT (GLenum, GLenum, GLint, GLint, GLint, GLint, GLint, GLsizei, GLsizei); +GLAPI void APIENTRY glGetMultiTexImageEXT (GLenum, GLenum, GLint, GLenum, GLenum, GLvoid *); +GLAPI void APIENTRY glGetMultiTexParameterfvEXT (GLenum, GLenum, GLenum, GLfloat *); +GLAPI void APIENTRY glGetMultiTexParameterivEXT (GLenum, GLenum, GLenum, GLint *); +GLAPI void APIENTRY glGetMultiTexLevelParameterfvEXT (GLenum, GLenum, GLint, GLenum, GLfloat *); +GLAPI void APIENTRY glGetMultiTexLevelParameterivEXT (GLenum, GLenum, GLint, GLenum, GLint *); +GLAPI void APIENTRY glMultiTexImage3DEXT (GLenum, GLenum, GLint, GLenum, GLsizei, GLsizei, GLsizei, GLint, GLenum, GLenum, const GLvoid *); +GLAPI void APIENTRY glMultiTexSubImage3DEXT (GLenum, GLenum, GLint, GLint, GLint, GLint, GLsizei, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *); +GLAPI void APIENTRY glCopyMultiTexSubImage3DEXT (GLenum, GLenum, GLint, GLint, GLint, GLint, GLint, GLint, GLsizei, GLsizei); +GLAPI void APIENTRY glBindMultiTextureEXT (GLenum, GLenum, GLuint); +GLAPI void APIENTRY glEnableClientStateIndexedEXT (GLenum, GLuint); +GLAPI void APIENTRY glDisableClientStateIndexedEXT (GLenum, GLuint); +GLAPI void APIENTRY glMultiTexCoordPointerEXT (GLenum, GLint, GLenum, GLsizei, const GLvoid *); +GLAPI void APIENTRY glMultiTexEnvfEXT (GLenum, GLenum, GLenum, GLfloat); +GLAPI void APIENTRY glMultiTexEnvfvEXT (GLenum, GLenum, GLenum, const GLfloat *); +GLAPI void APIENTRY glMultiTexEnviEXT (GLenum, GLenum, GLenum, GLint); +GLAPI void APIENTRY glMultiTexEnvivEXT (GLenum, GLenum, GLenum, const GLint *); +GLAPI void APIENTRY glMultiTexGendEXT (GLenum, GLenum, GLenum, GLdouble); +GLAPI void APIENTRY glMultiTexGendvEXT (GLenum, GLenum, GLenum, const GLdouble *); +GLAPI void APIENTRY glMultiTexGenfEXT (GLenum, GLenum, GLenum, GLfloat); +GLAPI void APIENTRY glMultiTexGenfvEXT (GLenum, GLenum, GLenum, const GLfloat *); +GLAPI void APIENTRY glMultiTexGeniEXT (GLenum, GLenum, GLenum, GLint); +GLAPI void APIENTRY glMultiTexGenivEXT (GLenum, GLenum, GLenum, const GLint *); +GLAPI void APIENTRY glGetMultiTexEnvfvEXT (GLenum, GLenum, GLenum, GLfloat *); +GLAPI void APIENTRY glGetMultiTexEnvivEXT (GLenum, GLenum, GLenum, GLint *); +GLAPI void APIENTRY glGetMultiTexGendvEXT (GLenum, GLenum, GLenum, GLdouble *); +GLAPI void APIENTRY glGetMultiTexGenfvEXT (GLenum, GLenum, GLenum, GLfloat *); +GLAPI void APIENTRY glGetMultiTexGenivEXT (GLenum, GLenum, GLenum, GLint *); +GLAPI void APIENTRY glGetFloatIndexedvEXT (GLenum, GLuint, GLfloat *); +GLAPI void APIENTRY glGetDoubleIndexedvEXT (GLenum, GLuint, GLdouble *); +GLAPI void APIENTRY glGetPointerIndexedvEXT (GLenum, GLuint, GLvoid* *); +GLAPI void APIENTRY glCompressedTextureImage3DEXT (GLuint, GLenum, GLint, GLenum, GLsizei, GLsizei, GLsizei, GLint, GLsizei, const GLvoid *); +GLAPI void APIENTRY glCompressedTextureImage2DEXT (GLuint, GLenum, GLint, GLenum, GLsizei, GLsizei, GLint, GLsizei, const GLvoid *); +GLAPI void APIENTRY glCompressedTextureImage1DEXT (GLuint, GLenum, GLint, GLenum, GLsizei, GLint, GLsizei, const GLvoid *); +GLAPI void APIENTRY glCompressedTextureSubImage3DEXT (GLuint, GLenum, GLint, GLint, GLint, GLint, GLsizei, GLsizei, GLsizei, GLenum, GLsizei, const GLvoid *); +GLAPI void APIENTRY glCompressedTextureSubImage2DEXT (GLuint, GLenum, GLint, GLint, GLint, GLsizei, GLsizei, GLenum, GLsizei, const GLvoid *); +GLAPI void APIENTRY glCompressedTextureSubImage1DEXT (GLuint, GLenum, GLint, GLint, GLsizei, GLenum, GLsizei, const GLvoid *); +GLAPI void APIENTRY glGetCompressedTextureImageEXT (GLuint, GLenum, GLint, GLvoid *); +GLAPI void APIENTRY glCompressedMultiTexImage3DEXT (GLenum, GLenum, GLint, GLenum, GLsizei, GLsizei, GLsizei, GLint, GLsizei, const GLvoid *); +GLAPI void APIENTRY glCompressedMultiTexImage2DEXT (GLenum, GLenum, GLint, GLenum, GLsizei, GLsizei, GLint, GLsizei, const GLvoid *); +GLAPI void APIENTRY glCompressedMultiTexImage1DEXT (GLenum, GLenum, GLint, GLenum, GLsizei, GLint, GLsizei, const GLvoid *); +GLAPI void APIENTRY glCompressedMultiTexSubImage3DEXT (GLenum, GLenum, GLint, GLint, GLint, GLint, GLsizei, GLsizei, GLsizei, GLenum, GLsizei, const GLvoid *); +GLAPI void APIENTRY glCompressedMultiTexSubImage2DEXT (GLenum, GLenum, GLint, GLint, GLint, GLsizei, GLsizei, GLenum, GLsizei, const GLvoid *); +GLAPI void APIENTRY glCompressedMultiTexSubImage1DEXT (GLenum, GLenum, GLint, GLint, GLsizei, GLenum, GLsizei, const GLvoid *); +GLAPI void APIENTRY glGetCompressedMultiTexImageEXT (GLenum, GLenum, GLint, GLvoid *); +GLAPI void APIENTRY glNamedProgramStringEXT (GLuint, GLenum, GLenum, GLsizei, const GLvoid *); +GLAPI void APIENTRY glNamedProgramLocalParameter4dEXT (GLuint, GLenum, GLuint, GLdouble, GLdouble, GLdouble, GLdouble); +GLAPI void APIENTRY glNamedProgramLocalParameter4dvEXT (GLuint, GLenum, GLuint, const GLdouble *); +GLAPI void APIENTRY glNamedProgramLocalParameter4fEXT (GLuint, GLenum, GLuint, GLfloat, GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glNamedProgramLocalParameter4fvEXT (GLuint, GLenum, GLuint, const GLfloat *); +GLAPI void APIENTRY glGetNamedProgramLocalParameterdvEXT (GLuint, GLenum, GLuint, GLdouble *); +GLAPI void APIENTRY glGetNamedProgramLocalParameterfvEXT (GLuint, GLenum, GLuint, GLfloat *); +GLAPI void APIENTRY glGetNamedProgramivEXT (GLuint, GLenum, GLenum, GLint *); +GLAPI void APIENTRY glGetNamedProgramStringEXT (GLuint, GLenum, GLenum, GLvoid *); +GLAPI void APIENTRY glNamedProgramLocalParameters4fvEXT (GLuint, GLenum, GLuint, GLsizei, const GLfloat *); +GLAPI void APIENTRY glNamedProgramLocalParameterI4iEXT (GLuint, GLenum, GLuint, GLint, GLint, GLint, GLint); +GLAPI void APIENTRY glNamedProgramLocalParameterI4ivEXT (GLuint, GLenum, GLuint, const GLint *); +GLAPI void APIENTRY glNamedProgramLocalParametersI4ivEXT (GLuint, GLenum, GLuint, GLsizei, const GLint *); +GLAPI void APIENTRY glNamedProgramLocalParameterI4uiEXT (GLuint, GLenum, GLuint, GLuint, GLuint, GLuint, GLuint); +GLAPI void APIENTRY glNamedProgramLocalParameterI4uivEXT (GLuint, GLenum, GLuint, const GLuint *); +GLAPI void APIENTRY glNamedProgramLocalParametersI4uivEXT (GLuint, GLenum, GLuint, GLsizei, const GLuint *); +GLAPI void APIENTRY glGetNamedProgramLocalParameterIivEXT (GLuint, GLenum, GLuint, GLint *); +GLAPI void APIENTRY glGetNamedProgramLocalParameterIuivEXT (GLuint, GLenum, GLuint, GLuint *); +GLAPI void APIENTRY glTextureParameterIivEXT (GLuint, GLenum, GLenum, const GLint *); +GLAPI void APIENTRY glTextureParameterIuivEXT (GLuint, GLenum, GLenum, const GLuint *); +GLAPI void APIENTRY glGetTextureParameterIivEXT (GLuint, GLenum, GLenum, GLint *); +GLAPI void APIENTRY glGetTextureParameterIuivEXT (GLuint, GLenum, GLenum, GLuint *); +GLAPI void APIENTRY glMultiTexParameterIivEXT (GLenum, GLenum, GLenum, const GLint *); +GLAPI void APIENTRY glMultiTexParameterIuivEXT (GLenum, GLenum, GLenum, const GLuint *); +GLAPI void APIENTRY glGetMultiTexParameterIivEXT (GLenum, GLenum, GLenum, GLint *); +GLAPI void APIENTRY glGetMultiTexParameterIuivEXT (GLenum, GLenum, GLenum, GLuint *); +GLAPI void APIENTRY glProgramUniform1fEXT (GLuint, GLint, GLfloat); +GLAPI void APIENTRY glProgramUniform2fEXT (GLuint, GLint, GLfloat, GLfloat); +GLAPI void APIENTRY glProgramUniform3fEXT (GLuint, GLint, GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glProgramUniform4fEXT (GLuint, GLint, GLfloat, GLfloat, GLfloat, GLfloat); +GLAPI void APIENTRY glProgramUniform1iEXT (GLuint, GLint, GLint); +GLAPI void APIENTRY glProgramUniform2iEXT (GLuint, GLint, GLint, GLint); +GLAPI void APIENTRY glProgramUniform3iEXT (GLuint, GLint, GLint, GLint, GLint); +GLAPI void APIENTRY glProgramUniform4iEXT (GLuint, GLint, GLint, GLint, GLint, GLint); +GLAPI void APIENTRY glProgramUniform1fvEXT (GLuint, GLint, GLsizei, const GLfloat *); +GLAPI void APIENTRY glProgramUniform2fvEXT (GLuint, GLint, GLsizei, const GLfloat *); +GLAPI void APIENTRY glProgramUniform3fvEXT (GLuint, GLint, GLsizei, const GLfloat *); +GLAPI void APIENTRY glProgramUniform4fvEXT (GLuint, GLint, GLsizei, const GLfloat *); +GLAPI void APIENTRY glProgramUniform1ivEXT (GLuint, GLint, GLsizei, const GLint *); +GLAPI void APIENTRY glProgramUniform2ivEXT (GLuint, GLint, GLsizei, const GLint *); +GLAPI void APIENTRY glProgramUniform3ivEXT (GLuint, GLint, GLsizei, const GLint *); +GLAPI void APIENTRY glProgramUniform4ivEXT (GLuint, GLint, GLsizei, const GLint *); +GLAPI void APIENTRY glProgramUniformMatrix2fvEXT (GLuint, GLint, GLsizei, GLboolean, const GLfloat *); +GLAPI void APIENTRY glProgramUniformMatrix3fvEXT (GLuint, GLint, GLsizei, GLboolean, const GLfloat *); +GLAPI void APIENTRY glProgramUniformMatrix4fvEXT (GLuint, GLint, GLsizei, GLboolean, const GLfloat *); +GLAPI void APIENTRY glProgramUniformMatrix2x3fvEXT (GLuint, GLint, GLsizei, GLboolean, const GLfloat *); +GLAPI void APIENTRY glProgramUniformMatrix3x2fvEXT (GLuint, GLint, GLsizei, GLboolean, const GLfloat *); +GLAPI void APIENTRY glProgramUniformMatrix2x4fvEXT (GLuint, GLint, GLsizei, GLboolean, const GLfloat *); +GLAPI void APIENTRY glProgramUniformMatrix4x2fvEXT (GLuint, GLint, GLsizei, GLboolean, const GLfloat *); +GLAPI void APIENTRY glProgramUniformMatrix3x4fvEXT (GLuint, GLint, GLsizei, GLboolean, const GLfloat *); +GLAPI void APIENTRY glProgramUniformMatrix4x3fvEXT (GLuint, GLint, GLsizei, GLboolean, const GLfloat *); +GLAPI void APIENTRY glProgramUniform1uiEXT (GLuint, GLint, GLuint); +GLAPI void APIENTRY glProgramUniform2uiEXT (GLuint, GLint, GLuint, GLuint); +GLAPI void APIENTRY glProgramUniform3uiEXT (GLuint, GLint, GLuint, GLuint, GLuint); +GLAPI void APIENTRY glProgramUniform4uiEXT (GLuint, GLint, GLuint, GLuint, GLuint, GLuint); +GLAPI void APIENTRY glProgramUniform1uivEXT (GLuint, GLint, GLsizei, const GLuint *); +GLAPI void APIENTRY glProgramUniform2uivEXT (GLuint, GLint, GLsizei, const GLuint *); +GLAPI void APIENTRY glProgramUniform3uivEXT (GLuint, GLint, GLsizei, const GLuint *); +GLAPI void APIENTRY glProgramUniform4uivEXT (GLuint, GLint, GLsizei, const GLuint *); +GLAPI void APIENTRY glNamedBufferDataEXT (GLuint, GLsizeiptr, const GLvoid *, GLenum); +GLAPI void APIENTRY glNamedBufferSubDataEXT (GLuint, GLintptr, GLsizeiptr, const GLvoid *); +GLAPI GLvoid* APIENTRY glMapNamedBufferEXT (GLuint, GLenum); +GLAPI GLboolean APIENTRY glUnmapNamedBufferEXT (GLuint); +GLAPI void APIENTRY glGetNamedBufferParameterivEXT (GLuint, GLenum, GLint *); +GLAPI void APIENTRY glGetNamedBufferPointervEXT (GLuint, GLenum, GLvoid* *); +GLAPI void APIENTRY glGetNamedBufferSubDataEXT (GLuint, GLintptr, GLsizeiptr, GLvoid *); +GLAPI void APIENTRY glTextureBufferEXT (GLuint, GLenum, GLenum, GLuint); +GLAPI void APIENTRY glMultiTexBufferEXT (GLenum, GLenum, GLenum, GLuint); +GLAPI void APIENTRY glNamedRenderbufferStorageEXT (GLuint, GLenum, GLsizei, GLsizei); +GLAPI void APIENTRY glGetNamedRenderbufferParameterivEXT (GLuint, GLenum, GLint *); +GLAPI GLenum APIENTRY glCheckNamedFramebufferStatusEXT (GLuint, GLenum); +GLAPI void APIENTRY glNamedFramebufferTexture1DEXT (GLuint, GLenum, GLenum, GLuint, GLint); +GLAPI void APIENTRY glNamedFramebufferTexture2DEXT (GLuint, GLenum, GLenum, GLuint, GLint); +GLAPI void APIENTRY glNamedFramebufferTexture3DEXT (GLuint, GLenum, GLenum, GLuint, GLint, GLint); +GLAPI void APIENTRY glNamedFramebufferRenderbufferEXT (GLuint, GLenum, GLenum, GLuint); +GLAPI void APIENTRY glGetNamedFramebufferAttachmentParameterivEXT (GLuint, GLenum, GLenum, GLint *); +GLAPI void APIENTRY glGenerateTextureMipmapEXT (GLuint, GLenum); +GLAPI void APIENTRY glGenerateMultiTexMipmapEXT (GLenum, GLenum); +GLAPI void APIENTRY glFramebufferDrawBufferEXT (GLuint, GLenum); +GLAPI void APIENTRY glFramebufferDrawBuffersEXT (GLuint, GLsizei, const GLenum *); +GLAPI void APIENTRY glFramebufferReadBufferEXT (GLuint, GLenum); +GLAPI void APIENTRY glGetFramebufferParameterivEXT (GLuint, GLenum, GLint *); +GLAPI void APIENTRY glNamedRenderbufferStorageMultisampleEXT (GLuint, GLsizei, GLenum, GLsizei, GLsizei); +GLAPI void APIENTRY glNamedRenderbufferStorageMultisampleCoverageEXT (GLuint, GLsizei, GLsizei, GLenum, GLsizei, GLsizei); +GLAPI void APIENTRY glNamedFramebufferTextureEXT (GLuint, GLenum, GLuint, GLint); +GLAPI void APIENTRY glNamedFramebufferTextureLayerEXT (GLuint, GLenum, GLuint, GLint, GLint); +GLAPI void APIENTRY glNamedFramebufferTextureFaceEXT (GLuint, GLenum, GLuint, GLint, GLenum); +GLAPI void APIENTRY glTextureRenderbufferEXT (GLuint, GLenum, GLuint); +GLAPI void APIENTRY glMultiTexRenderbufferEXT (GLenum, GLenum, GLuint); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLCLIENTATTRIBDEFAULTEXTPROC) (GLbitfield mask); +typedef void (APIENTRYP PFNGLPUSHCLIENTATTRIBDEFAULTEXTPROC) (GLbitfield mask); +typedef void (APIENTRYP PFNGLMATRIXLOADFEXTPROC) (GLenum mode, const GLfloat *m); +typedef void (APIENTRYP PFNGLMATRIXLOADDEXTPROC) (GLenum mode, const GLdouble *m); +typedef void (APIENTRYP PFNGLMATRIXMULTFEXTPROC) (GLenum mode, const GLfloat *m); +typedef void (APIENTRYP PFNGLMATRIXMULTDEXTPROC) (GLenum mode, const GLdouble *m); +typedef void (APIENTRYP PFNGLMATRIXLOADIDENTITYEXTPROC) (GLenum mode); +typedef void (APIENTRYP PFNGLMATRIXROTATEFEXTPROC) (GLenum mode, GLfloat angle, GLfloat x, GLfloat y, GLfloat z); +typedef void (APIENTRYP PFNGLMATRIXROTATEDEXTPROC) (GLenum mode, GLdouble angle, GLdouble x, GLdouble y, GLdouble z); +typedef void (APIENTRYP PFNGLMATRIXSCALEFEXTPROC) (GLenum mode, GLfloat x, GLfloat y, GLfloat z); +typedef void (APIENTRYP PFNGLMATRIXSCALEDEXTPROC) (GLenum mode, GLdouble x, GLdouble y, GLdouble z); +typedef void (APIENTRYP PFNGLMATRIXTRANSLATEFEXTPROC) (GLenum mode, GLfloat x, GLfloat y, GLfloat z); +typedef void (APIENTRYP PFNGLMATRIXTRANSLATEDEXTPROC) (GLenum mode, GLdouble x, GLdouble y, GLdouble z); +typedef void (APIENTRYP PFNGLMATRIXFRUSTUMEXTPROC) (GLenum mode, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar); +typedef void (APIENTRYP PFNGLMATRIXORTHOEXTPROC) (GLenum mode, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar); +typedef void (APIENTRYP PFNGLMATRIXPOPEXTPROC) (GLenum mode); +typedef void (APIENTRYP PFNGLMATRIXPUSHEXTPROC) (GLenum mode); +typedef void (APIENTRYP PFNGLMATRIXLOADTRANSPOSEFEXTPROC) (GLenum mode, const GLfloat *m); +typedef void (APIENTRYP PFNGLMATRIXLOADTRANSPOSEDEXTPROC) (GLenum mode, const GLdouble *m); +typedef void (APIENTRYP PFNGLMATRIXMULTTRANSPOSEFEXTPROC) (GLenum mode, const GLfloat *m); +typedef void (APIENTRYP PFNGLMATRIXMULTTRANSPOSEDEXTPROC) (GLenum mode, const GLdouble *m); +typedef void (APIENTRYP PFNGLTEXTUREPARAMETERFEXTPROC) (GLuint texture, GLenum target, GLenum pname, GLfloat param); +typedef void (APIENTRYP PFNGLTEXTUREPARAMETERFVEXTPROC) (GLuint texture, GLenum target, GLenum pname, const GLfloat *params); +typedef void (APIENTRYP PFNGLTEXTUREPARAMETERIEXTPROC) (GLuint texture, GLenum target, GLenum pname, GLint param); +typedef void (APIENTRYP PFNGLTEXTUREPARAMETERIVEXTPROC) (GLuint texture, GLenum target, GLenum pname, const GLint *params); +typedef void (APIENTRYP PFNGLTEXTUREIMAGE1DEXTPROC) (GLuint texture, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels); +typedef void (APIENTRYP PFNGLTEXTUREIMAGE2DEXTPROC) (GLuint texture, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels); +typedef void (APIENTRYP PFNGLTEXTURESUBIMAGE1DEXTPROC) (GLuint texture, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels); +typedef void (APIENTRYP PFNGLTEXTURESUBIMAGE2DEXTPROC) (GLuint texture, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels); +typedef void (APIENTRYP PFNGLCOPYTEXTUREIMAGE1DEXTPROC) (GLuint texture, GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border); +typedef void (APIENTRYP PFNGLCOPYTEXTUREIMAGE2DEXTPROC) (GLuint texture, GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border); +typedef void (APIENTRYP PFNGLCOPYTEXTURESUBIMAGE1DEXTPROC) (GLuint texture, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width); +typedef void (APIENTRYP PFNGLCOPYTEXTURESUBIMAGE2DEXTPROC) (GLuint texture, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height); +typedef void (APIENTRYP PFNGLGETTEXTUREIMAGEEXTPROC) (GLuint texture, GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels); +typedef void (APIENTRYP PFNGLGETTEXTUREPARAMETERFVEXTPROC) (GLuint texture, GLenum target, GLenum pname, GLfloat *params); +typedef void (APIENTRYP PFNGLGETTEXTUREPARAMETERIVEXTPROC) (GLuint texture, GLenum target, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLGETTEXTURELEVELPARAMETERFVEXTPROC) (GLuint texture, GLenum target, GLint level, GLenum pname, GLfloat *params); +typedef void (APIENTRYP PFNGLGETTEXTURELEVELPARAMETERIVEXTPROC) (GLuint texture, GLenum target, GLint level, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLTEXTUREIMAGE3DEXTPROC) (GLuint texture, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels); +typedef void (APIENTRYP PFNGLTEXTURESUBIMAGE3DEXTPROC) (GLuint texture, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels); +typedef void (APIENTRYP PFNGLCOPYTEXTURESUBIMAGE3DEXTPROC) (GLuint texture, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height); +typedef void (APIENTRYP PFNGLMULTITEXPARAMETERFEXTPROC) (GLenum texunit, GLenum target, GLenum pname, GLfloat param); +typedef void (APIENTRYP PFNGLMULTITEXPARAMETERFVEXTPROC) (GLenum texunit, GLenum target, GLenum pname, const GLfloat *params); +typedef void (APIENTRYP PFNGLMULTITEXPARAMETERIEXTPROC) (GLenum texunit, GLenum target, GLenum pname, GLint param); +typedef void (APIENTRYP PFNGLMULTITEXPARAMETERIVEXTPROC) (GLenum texunit, GLenum target, GLenum pname, const GLint *params); +typedef void (APIENTRYP PFNGLMULTITEXIMAGE1DEXTPROC) (GLenum texunit, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels); +typedef void (APIENTRYP PFNGLMULTITEXIMAGE2DEXTPROC) (GLenum texunit, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels); +typedef void (APIENTRYP PFNGLMULTITEXSUBIMAGE1DEXTPROC) (GLenum texunit, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels); +typedef void (APIENTRYP PFNGLMULTITEXSUBIMAGE2DEXTPROC) (GLenum texunit, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels); +typedef void (APIENTRYP PFNGLCOPYMULTITEXIMAGE1DEXTPROC) (GLenum texunit, GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border); +typedef void (APIENTRYP PFNGLCOPYMULTITEXIMAGE2DEXTPROC) (GLenum texunit, GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border); +typedef void (APIENTRYP PFNGLCOPYMULTITEXSUBIMAGE1DEXTPROC) (GLenum texunit, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width); +typedef void (APIENTRYP PFNGLCOPYMULTITEXSUBIMAGE2DEXTPROC) (GLenum texunit, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height); +typedef void (APIENTRYP PFNGLGETMULTITEXIMAGEEXTPROC) (GLenum texunit, GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels); +typedef void (APIENTRYP PFNGLGETMULTITEXPARAMETERFVEXTPROC) (GLenum texunit, GLenum target, GLenum pname, GLfloat *params); +typedef void (APIENTRYP PFNGLGETMULTITEXPARAMETERIVEXTPROC) (GLenum texunit, GLenum target, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLGETMULTITEXLEVELPARAMETERFVEXTPROC) (GLenum texunit, GLenum target, GLint level, GLenum pname, GLfloat *params); +typedef void (APIENTRYP PFNGLGETMULTITEXLEVELPARAMETERIVEXTPROC) (GLenum texunit, GLenum target, GLint level, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLMULTITEXIMAGE3DEXTPROC) (GLenum texunit, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels); +typedef void (APIENTRYP PFNGLMULTITEXSUBIMAGE3DEXTPROC) (GLenum texunit, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels); +typedef void (APIENTRYP PFNGLCOPYMULTITEXSUBIMAGE3DEXTPROC) (GLenum texunit, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height); +typedef void (APIENTRYP PFNGLBINDMULTITEXTUREEXTPROC) (GLenum texunit, GLenum target, GLuint texture); +typedef void (APIENTRYP PFNGLENABLECLIENTSTATEINDEXEDEXTPROC) (GLenum array, GLuint index); +typedef void (APIENTRYP PFNGLDISABLECLIENTSTATEINDEXEDEXTPROC) (GLenum array, GLuint index); +typedef void (APIENTRYP PFNGLMULTITEXCOORDPOINTEREXTPROC) (GLenum texunit, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer); +typedef void (APIENTRYP PFNGLMULTITEXENVFEXTPROC) (GLenum texunit, GLenum target, GLenum pname, GLfloat param); +typedef void (APIENTRYP PFNGLMULTITEXENVFVEXTPROC) (GLenum texunit, GLenum target, GLenum pname, const GLfloat *params); +typedef void (APIENTRYP PFNGLMULTITEXENVIEXTPROC) (GLenum texunit, GLenum target, GLenum pname, GLint param); +typedef void (APIENTRYP PFNGLMULTITEXENVIVEXTPROC) (GLenum texunit, GLenum target, GLenum pname, const GLint *params); +typedef void (APIENTRYP PFNGLMULTITEXGENDEXTPROC) (GLenum texunit, GLenum coord, GLenum pname, GLdouble param); +typedef void (APIENTRYP PFNGLMULTITEXGENDVEXTPROC) (GLenum texunit, GLenum coord, GLenum pname, const GLdouble *params); +typedef void (APIENTRYP PFNGLMULTITEXGENFEXTPROC) (GLenum texunit, GLenum coord, GLenum pname, GLfloat param); +typedef void (APIENTRYP PFNGLMULTITEXGENFVEXTPROC) (GLenum texunit, GLenum coord, GLenum pname, const GLfloat *params); +typedef void (APIENTRYP PFNGLMULTITEXGENIEXTPROC) (GLenum texunit, GLenum coord, GLenum pname, GLint param); +typedef void (APIENTRYP PFNGLMULTITEXGENIVEXTPROC) (GLenum texunit, GLenum coord, GLenum pname, const GLint *params); +typedef void (APIENTRYP PFNGLGETMULTITEXENVFVEXTPROC) (GLenum texunit, GLenum target, GLenum pname, GLfloat *params); +typedef void (APIENTRYP PFNGLGETMULTITEXENVIVEXTPROC) (GLenum texunit, GLenum target, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLGETMULTITEXGENDVEXTPROC) (GLenum texunit, GLenum coord, GLenum pname, GLdouble *params); +typedef void (APIENTRYP PFNGLGETMULTITEXGENFVEXTPROC) (GLenum texunit, GLenum coord, GLenum pname, GLfloat *params); +typedef void (APIENTRYP PFNGLGETMULTITEXGENIVEXTPROC) (GLenum texunit, GLenum coord, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLGETFLOATINDEXEDVEXTPROC) (GLenum target, GLuint index, GLfloat *data); +typedef void (APIENTRYP PFNGLGETDOUBLEINDEXEDVEXTPROC) (GLenum target, GLuint index, GLdouble *data); +typedef void (APIENTRYP PFNGLGETPOINTERINDEXEDVEXTPROC) (GLenum target, GLuint index, GLvoid* *data); +typedef void (APIENTRYP PFNGLCOMPRESSEDTEXTUREIMAGE3DEXTPROC) (GLuint texture, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *bits); +typedef void (APIENTRYP PFNGLCOMPRESSEDTEXTUREIMAGE2DEXTPROC) (GLuint texture, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *bits); +typedef void (APIENTRYP PFNGLCOMPRESSEDTEXTUREIMAGE1DEXTPROC) (GLuint texture, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *bits); +typedef void (APIENTRYP PFNGLCOMPRESSEDTEXTURESUBIMAGE3DEXTPROC) (GLuint texture, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *bits); +typedef void (APIENTRYP PFNGLCOMPRESSEDTEXTURESUBIMAGE2DEXTPROC) (GLuint texture, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *bits); +typedef void (APIENTRYP PFNGLCOMPRESSEDTEXTURESUBIMAGE1DEXTPROC) (GLuint texture, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *bits); +typedef void (APIENTRYP PFNGLGETCOMPRESSEDTEXTUREIMAGEEXTPROC) (GLuint texture, GLenum target, GLint lod, GLvoid *img); +typedef void (APIENTRYP PFNGLCOMPRESSEDMULTITEXIMAGE3DEXTPROC) (GLenum texunit, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *bits); +typedef void (APIENTRYP PFNGLCOMPRESSEDMULTITEXIMAGE2DEXTPROC) (GLenum texunit, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *bits); +typedef void (APIENTRYP PFNGLCOMPRESSEDMULTITEXIMAGE1DEXTPROC) (GLenum texunit, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *bits); +typedef void (APIENTRYP PFNGLCOMPRESSEDMULTITEXSUBIMAGE3DEXTPROC) (GLenum texunit, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *bits); +typedef void (APIENTRYP PFNGLCOMPRESSEDMULTITEXSUBIMAGE2DEXTPROC) (GLenum texunit, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *bits); +typedef void (APIENTRYP PFNGLCOMPRESSEDMULTITEXSUBIMAGE1DEXTPROC) (GLenum texunit, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *bits); +typedef void (APIENTRYP PFNGLGETCOMPRESSEDMULTITEXIMAGEEXTPROC) (GLenum texunit, GLenum target, GLint lod, GLvoid *img); +typedef void (APIENTRYP PFNGLNAMEDPROGRAMSTRINGEXTPROC) (GLuint program, GLenum target, GLenum format, GLsizei len, const GLvoid *string); +typedef void (APIENTRYP PFNGLNAMEDPROGRAMLOCALPARAMETER4DEXTPROC) (GLuint program, GLenum target, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w); +typedef void (APIENTRYP PFNGLNAMEDPROGRAMLOCALPARAMETER4DVEXTPROC) (GLuint program, GLenum target, GLuint index, const GLdouble *params); +typedef void (APIENTRYP PFNGLNAMEDPROGRAMLOCALPARAMETER4FEXTPROC) (GLuint program, GLenum target, GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w); +typedef void (APIENTRYP PFNGLNAMEDPROGRAMLOCALPARAMETER4FVEXTPROC) (GLuint program, GLenum target, GLuint index, const GLfloat *params); +typedef void (APIENTRYP PFNGLGETNAMEDPROGRAMLOCALPARAMETERDVEXTPROC) (GLuint program, GLenum target, GLuint index, GLdouble *params); +typedef void (APIENTRYP PFNGLGETNAMEDPROGRAMLOCALPARAMETERFVEXTPROC) (GLuint program, GLenum target, GLuint index, GLfloat *params); +typedef void (APIENTRYP PFNGLGETNAMEDPROGRAMIVEXTPROC) (GLuint program, GLenum target, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLGETNAMEDPROGRAMSTRINGEXTPROC) (GLuint program, GLenum target, GLenum pname, GLvoid *string); +typedef void (APIENTRYP PFNGLNAMEDPROGRAMLOCALPARAMETERS4FVEXTPROC) (GLuint program, GLenum target, GLuint index, GLsizei count, const GLfloat *params); +typedef void (APIENTRYP PFNGLNAMEDPROGRAMLOCALPARAMETERI4IEXTPROC) (GLuint program, GLenum target, GLuint index, GLint x, GLint y, GLint z, GLint w); +typedef void (APIENTRYP PFNGLNAMEDPROGRAMLOCALPARAMETERI4IVEXTPROC) (GLuint program, GLenum target, GLuint index, const GLint *params); +typedef void (APIENTRYP PFNGLNAMEDPROGRAMLOCALPARAMETERSI4IVEXTPROC) (GLuint program, GLenum target, GLuint index, GLsizei count, const GLint *params); +typedef void (APIENTRYP PFNGLNAMEDPROGRAMLOCALPARAMETERI4UIEXTPROC) (GLuint program, GLenum target, GLuint index, GLuint x, GLuint y, GLuint z, GLuint w); +typedef void (APIENTRYP PFNGLNAMEDPROGRAMLOCALPARAMETERI4UIVEXTPROC) (GLuint program, GLenum target, GLuint index, const GLuint *params); +typedef void (APIENTRYP PFNGLNAMEDPROGRAMLOCALPARAMETERSI4UIVEXTPROC) (GLuint program, GLenum target, GLuint index, GLsizei count, const GLuint *params); +typedef void (APIENTRYP PFNGLGETNAMEDPROGRAMLOCALPARAMETERIIVEXTPROC) (GLuint program, GLenum target, GLuint index, GLint *params); +typedef void (APIENTRYP PFNGLGETNAMEDPROGRAMLOCALPARAMETERIUIVEXTPROC) (GLuint program, GLenum target, GLuint index, GLuint *params); +typedef void (APIENTRYP PFNGLTEXTUREPARAMETERIIVEXTPROC) (GLuint texture, GLenum target, GLenum pname, const GLint *params); +typedef void (APIENTRYP PFNGLTEXTUREPARAMETERIUIVEXTPROC) (GLuint texture, GLenum target, GLenum pname, const GLuint *params); +typedef void (APIENTRYP PFNGLGETTEXTUREPARAMETERIIVEXTPROC) (GLuint texture, GLenum target, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLGETTEXTUREPARAMETERIUIVEXTPROC) (GLuint texture, GLenum target, GLenum pname, GLuint *params); +typedef void (APIENTRYP PFNGLMULTITEXPARAMETERIIVEXTPROC) (GLenum texunit, GLenum target, GLenum pname, const GLint *params); +typedef void (APIENTRYP PFNGLMULTITEXPARAMETERIUIVEXTPROC) (GLenum texunit, GLenum target, GLenum pname, const GLuint *params); +typedef void (APIENTRYP PFNGLGETMULTITEXPARAMETERIIVEXTPROC) (GLenum texunit, GLenum target, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLGETMULTITEXPARAMETERIUIVEXTPROC) (GLenum texunit, GLenum target, GLenum pname, GLuint *params); +typedef void (APIENTRYP PFNGLPROGRAMUNIFORM1FEXTPROC) (GLuint program, GLint location, GLfloat v0); +typedef void (APIENTRYP PFNGLPROGRAMUNIFORM2FEXTPROC) (GLuint program, GLint location, GLfloat v0, GLfloat v1); +typedef void (APIENTRYP PFNGLPROGRAMUNIFORM3FEXTPROC) (GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2); +typedef void (APIENTRYP PFNGLPROGRAMUNIFORM4FEXTPROC) (GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3); +typedef void (APIENTRYP PFNGLPROGRAMUNIFORM1IEXTPROC) (GLuint program, GLint location, GLint v0); +typedef void (APIENTRYP PFNGLPROGRAMUNIFORM2IEXTPROC) (GLuint program, GLint location, GLint v0, GLint v1); +typedef void (APIENTRYP PFNGLPROGRAMUNIFORM3IEXTPROC) (GLuint program, GLint location, GLint v0, GLint v1, GLint v2); +typedef void (APIENTRYP PFNGLPROGRAMUNIFORM4IEXTPROC) (GLuint program, GLint location, GLint v0, GLint v1, GLint v2, GLint v3); +typedef void (APIENTRYP PFNGLPROGRAMUNIFORM1FVEXTPROC) (GLuint program, GLint location, GLsizei count, const GLfloat *value); +typedef void (APIENTRYP PFNGLPROGRAMUNIFORM2FVEXTPROC) (GLuint program, GLint location, GLsizei count, const GLfloat *value); +typedef void (APIENTRYP PFNGLPROGRAMUNIFORM3FVEXTPROC) (GLuint program, GLint location, GLsizei count, const GLfloat *value); +typedef void (APIENTRYP PFNGLPROGRAMUNIFORM4FVEXTPROC) (GLuint program, GLint location, GLsizei count, const GLfloat *value); +typedef void (APIENTRYP PFNGLPROGRAMUNIFORM1IVEXTPROC) (GLuint program, GLint location, GLsizei count, const GLint *value); +typedef void (APIENTRYP PFNGLPROGRAMUNIFORM2IVEXTPROC) (GLuint program, GLint location, GLsizei count, const GLint *value); +typedef void (APIENTRYP PFNGLPROGRAMUNIFORM3IVEXTPROC) (GLuint program, GLint location, GLsizei count, const GLint *value); +typedef void (APIENTRYP PFNGLPROGRAMUNIFORM4IVEXTPROC) (GLuint program, GLint location, GLsizei count, const GLint *value); +typedef void (APIENTRYP PFNGLPROGRAMUNIFORMMATRIX2FVEXTPROC) (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (APIENTRYP PFNGLPROGRAMUNIFORMMATRIX3FVEXTPROC) (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (APIENTRYP PFNGLPROGRAMUNIFORMMATRIX4FVEXTPROC) (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (APIENTRYP PFNGLPROGRAMUNIFORMMATRIX2X3FVEXTPROC) (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (APIENTRYP PFNGLPROGRAMUNIFORMMATRIX3X2FVEXTPROC) (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (APIENTRYP PFNGLPROGRAMUNIFORMMATRIX2X4FVEXTPROC) (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (APIENTRYP PFNGLPROGRAMUNIFORMMATRIX4X2FVEXTPROC) (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (APIENTRYP PFNGLPROGRAMUNIFORMMATRIX3X4FVEXTPROC) (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (APIENTRYP PFNGLPROGRAMUNIFORMMATRIX4X3FVEXTPROC) (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (APIENTRYP PFNGLPROGRAMUNIFORM1UIEXTPROC) (GLuint program, GLint location, GLuint v0); +typedef void (APIENTRYP PFNGLPROGRAMUNIFORM2UIEXTPROC) (GLuint program, GLint location, GLuint v0, GLuint v1); +typedef void (APIENTRYP PFNGLPROGRAMUNIFORM3UIEXTPROC) (GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2); +typedef void (APIENTRYP PFNGLPROGRAMUNIFORM4UIEXTPROC) (GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3); +typedef void (APIENTRYP PFNGLPROGRAMUNIFORM1UIVEXTPROC) (GLuint program, GLint location, GLsizei count, const GLuint *value); +typedef void (APIENTRYP PFNGLPROGRAMUNIFORM2UIVEXTPROC) (GLuint program, GLint location, GLsizei count, const GLuint *value); +typedef void (APIENTRYP PFNGLPROGRAMUNIFORM3UIVEXTPROC) (GLuint program, GLint location, GLsizei count, const GLuint *value); +typedef void (APIENTRYP PFNGLPROGRAMUNIFORM4UIVEXTPROC) (GLuint program, GLint location, GLsizei count, const GLuint *value); +typedef void (APIENTRYP PFNGLNAMEDBUFFERDATAEXTPROC) (GLuint buffer, GLsizeiptr size, const GLvoid *data, GLenum usage); +typedef void (APIENTRYP PFNGLNAMEDBUFFERSUBDATAEXTPROC) (GLuint buffer, GLintptr offset, GLsizeiptr size, const GLvoid *data); +typedef GLvoid* (APIENTRYP PFNGLMAPNAMEDBUFFEREXTPROC) (GLuint buffer, GLenum access); +typedef GLboolean (APIENTRYP PFNGLUNMAPNAMEDBUFFEREXTPROC) (GLuint buffer); +typedef void (APIENTRYP PFNGLGETNAMEDBUFFERPARAMETERIVEXTPROC) (GLuint buffer, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLGETNAMEDBUFFERPOINTERVEXTPROC) (GLuint buffer, GLenum pname, GLvoid* *params); +typedef void (APIENTRYP PFNGLGETNAMEDBUFFERSUBDATAEXTPROC) (GLuint buffer, GLintptr offset, GLsizeiptr size, GLvoid *data); +typedef void (APIENTRYP PFNGLTEXTUREBUFFEREXTPROC) (GLuint texture, GLenum target, GLenum internalformat, GLuint buffer); +typedef void (APIENTRYP PFNGLMULTITEXBUFFEREXTPROC) (GLenum texunit, GLenum target, GLenum internalformat, GLuint buffer); +typedef void (APIENTRYP PFNGLNAMEDRENDERBUFFERSTORAGEEXTPROC) (GLuint renderbuffer, GLenum internalformat, GLsizei width, GLsizei height); +typedef void (APIENTRYP PFNGLGETNAMEDRENDERBUFFERPARAMETERIVEXTPROC) (GLuint renderbuffer, GLenum pname, GLint *params); +typedef GLenum (APIENTRYP PFNGLCHECKNAMEDFRAMEBUFFERSTATUSEXTPROC) (GLuint framebuffer, GLenum target); +typedef void (APIENTRYP PFNGLNAMEDFRAMEBUFFERTEXTURE1DEXTPROC) (GLuint framebuffer, GLenum attachment, GLenum textarget, GLuint texture, GLint level); +typedef void (APIENTRYP PFNGLNAMEDFRAMEBUFFERTEXTURE2DEXTPROC) (GLuint framebuffer, GLenum attachment, GLenum textarget, GLuint texture, GLint level); +typedef void (APIENTRYP PFNGLNAMEDFRAMEBUFFERTEXTURE3DEXTPROC) (GLuint framebuffer, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset); +typedef void (APIENTRYP PFNGLNAMEDFRAMEBUFFERRENDERBUFFEREXTPROC) (GLuint framebuffer, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer); +typedef void (APIENTRYP PFNGLGETNAMEDFRAMEBUFFERATTACHMENTPARAMETERIVEXTPROC) (GLuint framebuffer, GLenum attachment, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLGENERATETEXTUREMIPMAPEXTPROC) (GLuint texture, GLenum target); +typedef void (APIENTRYP PFNGLGENERATEMULTITEXMIPMAPEXTPROC) (GLenum texunit, GLenum target); +typedef void (APIENTRYP PFNGLFRAMEBUFFERDRAWBUFFEREXTPROC) (GLuint framebuffer, GLenum mode); +typedef void (APIENTRYP PFNGLFRAMEBUFFERDRAWBUFFERSEXTPROC) (GLuint framebuffer, GLsizei n, const GLenum *bufs); +typedef void (APIENTRYP PFNGLFRAMEBUFFERREADBUFFEREXTPROC) (GLuint framebuffer, GLenum mode); +typedef void (APIENTRYP PFNGLGETFRAMEBUFFERPARAMETERIVEXTPROC) (GLuint framebuffer, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLNAMEDRENDERBUFFERSTORAGEMULTISAMPLEEXTPROC) (GLuint renderbuffer, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height); +typedef void (APIENTRYP PFNGLNAMEDRENDERBUFFERSTORAGEMULTISAMPLECOVERAGEEXTPROC) (GLuint renderbuffer, GLsizei coverageSamples, GLsizei colorSamples, GLenum internalformat, GLsizei width, GLsizei height); +typedef void (APIENTRYP PFNGLNAMEDFRAMEBUFFERTEXTUREEXTPROC) (GLuint framebuffer, GLenum attachment, GLuint texture, GLint level); +typedef void (APIENTRYP PFNGLNAMEDFRAMEBUFFERTEXTURELAYEREXTPROC) (GLuint framebuffer, GLenum attachment, GLuint texture, GLint level, GLint layer); +typedef void (APIENTRYP PFNGLNAMEDFRAMEBUFFERTEXTUREFACEEXTPROC) (GLuint framebuffer, GLenum attachment, GLuint texture, GLint level, GLenum face); +typedef void (APIENTRYP PFNGLTEXTURERENDERBUFFEREXTPROC) (GLuint texture, GLenum target, GLuint renderbuffer); +typedef void (APIENTRYP PFNGLMULTITEXRENDERBUFFEREXTPROC) (GLenum texunit, GLenum target, GLuint renderbuffer); +#endif + +#ifndef GL_EXT_vertex_array_bgra +#define GL_EXT_vertex_array_bgra 1 +#endif + +#ifndef GL_EXT_texture_swizzle +#define GL_EXT_texture_swizzle 1 +#endif + +#ifndef GL_NV_explicit_multisample +#define GL_NV_explicit_multisample 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glGetMultisamplefvNV (GLenum, GLuint, GLfloat *); +GLAPI void APIENTRY glSampleMaskIndexedNV (GLuint, GLbitfield); +GLAPI void APIENTRY glTexRenderbufferNV (GLenum, GLuint); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLGETMULTISAMPLEFVNVPROC) (GLenum pname, GLuint index, GLfloat *val); +typedef void (APIENTRYP PFNGLSAMPLEMASKINDEXEDNVPROC) (GLuint index, GLbitfield mask); +typedef void (APIENTRYP PFNGLTEXRENDERBUFFERNVPROC) (GLenum target, GLuint renderbuffer); +#endif + +#ifndef GL_NV_transform_feedback2 +#define GL_NV_transform_feedback2 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glBindTransformFeedbackNV (GLenum, GLuint); +GLAPI void APIENTRY glDeleteTransformFeedbacksNV (GLsizei, const GLuint *); +GLAPI void APIENTRY glGenTransformFeedbacksNV (GLsizei, GLuint *); +GLAPI GLboolean APIENTRY glIsTransformFeedbackNV (GLuint); +GLAPI void APIENTRY glPauseTransformFeedbackNV (void); +GLAPI void APIENTRY glResumeTransformFeedbackNV (void); +GLAPI void APIENTRY glDrawTransformFeedbackNV (GLenum, GLuint); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLBINDTRANSFORMFEEDBACKNVPROC) (GLenum target, GLuint id); +typedef void (APIENTRYP PFNGLDELETETRANSFORMFEEDBACKSNVPROC) (GLsizei n, const GLuint *ids); +typedef void (APIENTRYP PFNGLGENTRANSFORMFEEDBACKSNVPROC) (GLsizei n, GLuint *ids); +typedef GLboolean (APIENTRYP PFNGLISTRANSFORMFEEDBACKNVPROC) (GLuint id); +typedef void (APIENTRYP PFNGLPAUSETRANSFORMFEEDBACKNVPROC) (void); +typedef void (APIENTRYP PFNGLRESUMETRANSFORMFEEDBACKNVPROC) (void); +typedef void (APIENTRYP PFNGLDRAWTRANSFORMFEEDBACKNVPROC) (GLenum mode, GLuint id); +#endif + + +#ifdef __cplusplus +} +#endif + +#endif + diff --git a/desmume/src/windows/IORegView.cpp b/src/windows/IORegView.cpp similarity index 100% rename from desmume/src/windows/IORegView.cpp rename to src/windows/IORegView.cpp diff --git a/desmume/src/windows/IORegView.h b/src/windows/IORegView.h similarity index 97% rename from desmume/src/windows/IORegView.h rename to src/windows/IORegView.h index f5431ea78..d76aa8751 100644 --- a/desmume/src/windows/IORegView.h +++ b/src/windows/IORegView.h @@ -1,28 +1,28 @@ -/* Copyright (C) 2006 yopyop - yopyop156@ifrance.com - yopyop156.ifrance.com - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#ifndef IO_REG_H -#define IO_REG_H -#include "../common.h" - -extern BOOL CALLBACK IoregView_Proc (HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam); - -#endif +/* Copyright (C) 2006 yopyop + yopyop156@ifrance.com + yopyop156.ifrance.com + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#ifndef IO_REG_H +#define IO_REG_H +#include "../common.h" + +extern BOOL CALLBACK IoregView_Proc (HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam); + +#endif diff --git a/desmume/src/windows/Makefile.am b/src/windows/Makefile.am similarity index 89% rename from desmume/src/windows/Makefile.am rename to src/windows/Makefile.am index 5fcc52a37..797a05e76 100644 --- a/desmume/src/windows/Makefile.am +++ b/src/windows/Makefile.am @@ -5,7 +5,7 @@ EXTRA_DIST = DeSmuME.ico \ resources.rc bin_PROGRAMS = desmume desmume_SOURCES = \ - afxres.h aviout.h config.h \ + afxres.h \ CWindow.cpp CWindow.h \ disView.cpp disView.h ginfo.cpp ginfo.h \ IORegView.cpp IORegView.h \ @@ -24,8 +24,6 @@ desmume_SOURCES = \ throttle.cpp throttle.h windriver.h \ cheatsWin.cpp cheatsWin.h gbaslot_config.cpp gbaslot_config.h \ mic.cpp hotkey.cpp hotkey.h \ - ram_search.cpp ram_search.h ramwatch.cpp ramwatch.h \ - replay.cpp replay.h soundView.cpp soundView.h \ DeSmuME_2005.vcproj DeSmuME_2008.vcproj \ DeSmuME_Intel.icproj DeSmuME_Intel.vcproj DeSmuME_Intel.sln \ DeSmuME_x64.manifest DeSmuME_x86.manifest diff --git a/desmume/src/windows/Makefile.win b/src/windows/Makefile.win similarity index 100% rename from desmume/src/windows/Makefile.win rename to src/windows/Makefile.win diff --git a/desmume/src/windows/OpenArchive.cpp b/src/windows/OpenArchive.cpp similarity index 100% rename from desmume/src/windows/OpenArchive.cpp rename to src/windows/OpenArchive.cpp diff --git a/desmume/src/windows/OpenArchive.h b/src/windows/OpenArchive.h similarity index 100% rename from desmume/src/windows/OpenArchive.h rename to src/windows/OpenArchive.h diff --git a/desmume/src/windows/afxres.h b/src/windows/afxres.h similarity index 100% rename from desmume/src/windows/afxres.h rename to src/windows/afxres.h diff --git a/desmume/src/windows/aviout.cpp b/src/windows/aviout.cpp similarity index 90% rename from desmume/src/windows/aviout.cpp rename to src/windows/aviout.cpp index a6cb1f0e5..7e62f5426 100644 --- a/desmume/src/windows/aviout.cpp +++ b/src/windows/aviout.cpp @@ -1,25 +1,24 @@ -/* aviout.cpp - - Copyright (C) 2006-2009 DeSmuME team - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA +/* aviout.cpp + * + * Copyright (C) 2006-2008 Zeromus + * + * This file is part of DeSmuME + * + * DeSmuME is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * DeSmuME is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with DeSmuME; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA */ - -#include "main.h" +#include "main.h" //I added this so that this file could gain access to SetMessageToDisplay. #include "types.h" #include "windriver.h" #include "console.h" @@ -41,6 +40,12 @@ static void EMU_PrintMessage(const char* msg) { LOG(msg); } +bool DRV_AviBegin(const char* fname); +void DRV_AviEnd(); +void DRV_AviSoundUpdate(void* soundData, int soundLen); +bool DRV_AviIsRecording(); +void DRV_AviVideoUpdate(const u16* buffer); + //extern PALETTEENTRY *color_palette; //extern WAVEFORMATEX wf; //extern int soundo; @@ -77,7 +82,7 @@ static struct AVIFile u8 convert_buffer[256*384*3]; int start_scanline; int end_scanline; - + long tBytes, ByteBuffer; u8 audio_buffer[44100*2*2]; // 1 second buffer @@ -231,8 +236,13 @@ static int avi_open(const char* filename, const BITMAPINFOHEADER* pbmih, const W memset(&avi_file->avi_video_header, 0, sizeof(AVISTREAMINFO)); avi_file->avi_video_header.fccType = streamtypeVIDEO; +#if defined(WIN32) && defined(G_NEW_SPU_TIMING) avi_file->avi_video_header.dwScale = 6*355*263; avi_file->avi_video_header.dwRate = 33513982; +#else + avi_file->avi_video_header.dwScale = 65536*256; + avi_file->avi_video_header.dwRate = (int)(59.8261*65536*256); +#endif avi_file->avi_video_header.dwSuggestedBufferSize = avi_file->bitmap_format.biSizeImage; if(FAILED(AVIFileCreateStream(avi_file->avi_file, &avi_file->streams[VIDEO_STREAM], &avi_file->avi_video_header))) break; @@ -436,7 +446,7 @@ void DRV_AviVideoUpdate(const u16* buffer) AviNextSegment(); } -bool AVI_IsRecording() +BOOL AVI_IsRecording() { return avi_file && avi_file->valid; } @@ -482,3 +492,11 @@ void DRV_AviEnd() avi_destroy(&avi_file); } + +bool DRV_AviIsRecording() +{ + if(avi_file) + return true; + + return false; +} diff --git a/src/windows/aviout.h b/src/windows/aviout.h new file mode 100644 index 000000000..38dc381a5 --- /dev/null +++ b/src/windows/aviout.h @@ -0,0 +1,5 @@ +bool DRV_AviBegin(const char* fname); +void DRV_AviEnd(); +void DRV_AviSoundUpdate(void* soundData, int soundLen); +bool DRV_AviIsRecording(); +void DRV_AviVideoUpdate(const u16* buffer); \ No newline at end of file diff --git a/desmume/src/windows/bitmap1.bmp b/src/windows/bitmap1.bmp similarity index 100% rename from desmume/src/windows/bitmap1.bmp rename to src/windows/bitmap1.bmp diff --git a/desmume/src/windows/cheatsWin.cpp b/src/windows/cheatsWin.cpp similarity index 96% rename from desmume/src/windows/cheatsWin.cpp rename to src/windows/cheatsWin.cpp index 1d9a0466a..e564f9072 100644 --- a/desmume/src/windows/cheatsWin.cpp +++ b/src/windows/cheatsWin.cpp @@ -1,1272 +1,1272 @@ -/* Copyright (C) 2006 yopyop - yopyop156@ifrance.com - yopyop156.ifrance.com - - Copyright 2009 DeSmuME team - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -*/ - -#include "cheatsWin.h" -#include -#include "../cheatSystem.h" -#include "resource.h" -#include "../debug.h" - -static u8 searchType = 0; -static u8 searchSize = 0; -static u8 searchSign = 0; -static u8 searchStep = 0; -static u8 searchComp = 0; -static HWND hBRestart = NULL; -static HWND hBView = NULL; -static HWND hBSearch = NULL; -static u32 exactVal = 0; -static u32 searchNumberResults = 0; - -static u32 searchAddAddress = 0; -static u32 searchAddValue = 0; -static u8 searchAddMode = 0; -static u8 searchAddFreeze = 1; -static u8 searchAddSize = 0; -static char editBuf[3][75] = { 0 }; -static u32 cheatEditPos = 0; -static u8 cheatXXtype = 0; -static u8 cheatXXaction = 0; - -static HWND searchWnd = NULL; -static HWND searchListView = NULL; -static HWND cheatListView = NULL; -static WNDPROC oldEditProc = NULL; -static WNDPROC oldEditProcHEX = NULL; - -CHEATS_LIST tempCheat; - -u32 searchIDDs[2][4] = { - { IDD_CHEAT_SEARCH_MAIN, IDD_CHEAT_SEARCH_EXACT, IDD_CHEAT_SEARCH_RESULT, NULL }, - { IDD_CHEAT_SEARCH_MAIN, IDD_CHEAT_SEARCH_RESULT, IDD_CHEAT_SEARCH_COMP, IDD_CHEAT_SEARCH_RESULT} -}; - -u32 searchSizeIDDs[4] = { IDC_RADIO1, IDC_RADIO2, IDC_RADIO3, IDC_RADIO4 }; -u32 searchSignIDDs[2] = { IDC_RADIO5, IDC_RADIO6 }; -u32 searchTypeIDDs[2] = { IDC_RADIO7, IDC_RADIO8 }; -u32 searchCompIDDs[4] = { IDC_RADIO1, IDC_RADIO2, IDC_RADIO3, IDC_RADIO4 }; - -u32 searchRangeIDDs[4] = { IDC_STATIC_S1, IDC_STATIC_S2, IDC_STATIC_S3, IDC_STATIC_S4 }; -char *searchRangeText[2][4] = { {"[0..255]", "[0..65536]", "[0..16777215]", "[0..4294967295]"}, - {"[-128..127]", "[-32168..32767]", "[-8388608..8388607]", "[-2147483648..2147483647]"}}; - -u32 searchRange[4][2] = { - { 0, 255 }, - { 0, 65536 }, - { 0, 16777215 }, - { 0, 4294967295 } - }; - -LRESULT CALLBACK EditValueProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam) -{ - // TODO: check paste - if (msg == WM_CHAR) - { - switch (wParam) - { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': - break; - case '-': - { - u8 pos = 0; - SendMessage(hwnd, EM_GETSEL, (WPARAM)&pos, NULL); - if (pos != 0) wParam = 0; - } - break; - - case VK_BACK: - break; - default: - wParam = 0; - break; - } - - } - - return CallWindowProc(oldEditProc, hwnd, msg, wParam, lParam); -} - -LRESULT CALLBACK EditValueHEXProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam) -{ - // TODO: check paste - if (msg == WM_CHAR) - { - switch (wParam) - { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - break; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - wParam -= 32; - break; - case VK_BACK: - break; - default: - wParam = 0; - break; - } - - } - - return CallWindowProc(oldEditProcHEX, hwnd, msg, wParam, lParam); -} - -BOOL CALLBACK CheatsAddProc(HWND dialog, UINT msg,WPARAM wparam,LPARAM lparam) -{ - static WNDPROC saveOldEditProc = NULL; - - switch(msg) - { - case WM_INITDIALOG: - { - saveOldEditProc = oldEditProc; - SendMessage(GetDlgItem(dialog, IDC_EDIT1), EM_SETLIMITTEXT, 6, 0); - SendMessage(GetDlgItem(dialog, IDC_EDIT2), EM_SETLIMITTEXT, 10, 0); - SendMessage(GetDlgItem(dialog, IDC_EDIT3), EM_SETLIMITTEXT, 75, 0); - oldEditProcHEX = (WNDPROC)SetWindowLongPtr(GetDlgItem(dialog, IDC_EDIT1), GWLP_WNDPROC, (LONG)EditValueHEXProc); - oldEditProc = (WNDPROC)SetWindowLongPtr(GetDlgItem(dialog, IDC_EDIT2), GWLP_WNDPROC, (LONG)EditValueProc); - - if (searchAddMode == 1) - { - char buf[10]; - searchAddAddress &= 0x00FFFFFF; - wsprintf(buf, "%06X", searchAddAddress); - SetWindowText(GetDlgItem(dialog, IDC_EDIT1), buf); - wsprintf(buf, "%i", searchAddValue); - SetWindowText(GetDlgItem(dialog, IDC_EDIT2), buf); - EnableWindow(GetDlgItem(dialog, IDOK), TRUE); - EnableWindow(GetDlgItem(dialog, IDC_EDIT1), FALSE); - EnableWindow(GetDlgItem(dialog, IDC_RADIO1), FALSE); - EnableWindow(GetDlgItem(dialog, IDC_RADIO2), FALSE); - EnableWindow(GetDlgItem(dialog, IDC_RADIO3), FALSE); - EnableWindow(GetDlgItem(dialog, IDC_RADIO4), FALSE); - EnableWindow(GetDlgItem(dialog, IDC_RADIO8), FALSE); - } - else - { - SetWindowText(GetDlgItem(dialog, IDC_EDIT2), "0"); - CheckDlgButton(dialog, IDC_RADIO1, BST_CHECKED); - } - - memset(editBuf, 0, sizeof(editBuf)); - - GetWindowText(GetDlgItem(dialog, IDC_EDIT1), editBuf[0], 10); - GetWindowText(GetDlgItem(dialog, IDC_EDIT2), editBuf[1], 10); - - CheckDlgButton(dialog, IDC_CHECK1, BST_CHECKED); - CheckDlgButton(dialog, searchSizeIDDs[searchAddSize], BST_CHECKED); - } - return TRUE; - - case WM_COMMAND: - { - switch (LOWORD(wparam)) - { - case IDOK: - { - u32 tmp_addr = 0; - sscanf_s(editBuf[0], "%x", &tmp_addr); - - if (cheatsAdd(searchAddSize, tmp_addr, atol(editBuf[1]), editBuf[2], searchAddFreeze)) - { - if ((searchAddMode == 0) || (cheatsSave() && searchAddMode == 1)) - { - oldEditProc = saveOldEditProc; - searchAddAddress = tmp_addr; - searchAddValue = atol(editBuf[1]); - - EndDialog(dialog, TRUE); - } - } - } - return TRUE; - - case IDCANCEL: - oldEditProc = saveOldEditProc; - EndDialog(dialog, FALSE); - return TRUE; - - case IDC_EDIT1: // address - { - if (HIWORD(wparam) == EN_UPDATE) - { - GetWindowText(GetDlgItem(dialog, IDC_EDIT1), editBuf[0], 8); - if ( (strlen(editBuf[0]) < 6) || (!strlen(editBuf[1])) ) - { - EnableWindow(GetDlgItem(dialog, IDOK), FALSE); - return TRUE; - } - - u32 val = 0; - sscanf_s(editBuf[0], "%x", &val); - val &= 0x00FFFFFF; - if (val > 0x400000) - { - EnableWindow(GetDlgItem(dialog, IDOK), FALSE); - return TRUE; - } - EnableWindow(GetDlgItem(dialog, IDOK), TRUE); - } - return TRUE; - } - - case IDC_EDIT2: // value - { - if (HIWORD(wparam) == EN_UPDATE) - { - GetWindowText(GetDlgItem(dialog, IDC_EDIT2), editBuf[1], 10); - if ( (strlen(editBuf[0]) < 6) || (!strlen(editBuf[1])) ) - { - EnableWindow(GetDlgItem(dialog, IDOK), FALSE); - return TRUE; - } - - u32 val = atol(editBuf[1]); - if (val > searchRange[searchAddSize][1]) - { - EnableWindow(GetDlgItem(dialog, IDOK), FALSE); - return TRUE; - } - EnableWindow(GetDlgItem(dialog, IDOK), TRUE); - } - return TRUE; - } - - case IDC_EDIT3: // description - { - if (HIWORD(wparam) == EN_UPDATE) - GetWindowText(GetDlgItem(dialog, IDC_EDIT3), editBuf[2], 75); - return TRUE; - } - - case IDC_RADIO1: // 1 byte - searchAddSize = 0; - return TRUE; - case IDC_RADIO2: // 2 bytes - searchAddSize = 1; - return TRUE; - case IDC_RADIO3: // 3 bytes - searchAddSize = 2; - return TRUE; - case IDC_RADIO4: // 4 bytes - searchAddSize = 3; - return TRUE; - - case IDC_CHECK1: - { - if (IsDlgButtonChecked(dialog, IDC_CHECK1) == BST_CHECKED) - searchAddFreeze = 1; - else - searchAddFreeze = 0; - } - } - } - } - return FALSE; -} - -BOOL CALLBACK CheatsEditProc(HWND dialog, UINT msg,WPARAM wparam,LPARAM lparam) -{ - static WNDPROC saveOldEditProc = NULL; - char buf[100] = {0}, buf2[100] = {0}; - - switch(msg) - { - case WM_INITDIALOG: - { - saveOldEditProc = oldEditProc; - SendMessage(GetDlgItem(dialog, IDC_EDIT1), EM_SETLIMITTEXT, 6, 0); - SendMessage(GetDlgItem(dialog, IDC_EDIT2), EM_SETLIMITTEXT, 10, 0); - SendMessage(GetDlgItem(dialog, IDC_EDIT3), EM_SETLIMITTEXT, 75, 0); - oldEditProcHEX = (WNDPROC)SetWindowLongPtr(GetDlgItem(dialog, IDC_EDIT1), GWLP_WNDPROC, (LONG)EditValueHEXProc); - oldEditProc = (WNDPROC)SetWindowLongPtr(GetDlgItem(dialog, IDC_EDIT2), GWLP_WNDPROC, (LONG)EditValueProc); - - cheatsGet(&tempCheat, cheatEditPos); - - memset(buf, 0, 100); - memset(buf2, 0, 100); - tempCheat.hi[0] &= 0x00FFFFFF; - wsprintf(buf, "%06X", tempCheat.hi[0]); - SetWindowText(GetDlgItem(dialog, IDC_EDIT1), buf); - wsprintf(buf, "%i", tempCheat.lo[0]); - SetWindowText(GetDlgItem(dialog, IDC_EDIT2), buf); - strcpy(buf, tempCheat.description); - SetWindowText(GetDlgItem(dialog, IDC_EDIT3), buf); - EnableWindow(GetDlgItem(dialog, IDOK), TRUE); - - CheckDlgButton(dialog, IDC_CHECK1, tempCheat.enabled?BST_CHECKED:BST_UNCHECKED); - CheckDlgButton(dialog, searchSizeIDDs[tempCheat.size], BST_CHECKED); - SetWindowText(GetDlgItem(dialog, IDOK), "Update"); - } - return TRUE; - - case WM_COMMAND: - { - switch (LOWORD(wparam)) - { - case IDOK: - { - if (cheatsUpdate(tempCheat.size, tempCheat.hi[0], tempCheat.lo[0], tempCheat.description, tempCheat.enabled, cheatEditPos)) - { - oldEditProc = saveOldEditProc; - EndDialog(dialog, TRUE); - } - } - return TRUE; - - case IDCANCEL: - oldEditProc = saveOldEditProc; - EndDialog(dialog, FALSE); - return TRUE; - - case IDC_EDIT1: // address - { - if (HIWORD(wparam) == EN_UPDATE) - { - GetWindowText(GetDlgItem(dialog, IDC_EDIT1), buf, 8); - GetWindowText(GetDlgItem(dialog, IDC_EDIT2), buf2, 10); - if ( (strlen(buf) < 6) || (!strlen(buf2)) ) - { - EnableWindow(GetDlgItem(dialog, IDOK), FALSE); - return TRUE; - } - - u32 val = 0; - sscanf_s(buf, "%x", &val); - val &= 0x00FFFFFF; - if (val > 0x400000) - { - EnableWindow(GetDlgItem(dialog, IDOK), FALSE); - return TRUE; - } - EnableWindow(GetDlgItem(dialog, IDOK), TRUE); - tempCheat.hi[0] = val; - } - return TRUE; - } - - case IDC_EDIT2: // value - { - if (HIWORD(wparam) == EN_UPDATE) - { - GetWindowText(GetDlgItem(dialog, IDC_EDIT2), buf, 10); - GetWindowText(GetDlgItem(dialog, IDC_EDIT1), buf2, 8); - if ( (strlen(buf2) < 6) || (!strlen(buf)) ) - { - EnableWindow(GetDlgItem(dialog, IDOK), FALSE); - return TRUE; - } - - u32 val = atol(buf); - if (val > searchRange[tempCheat.size][1]) - { - EnableWindow(GetDlgItem(dialog, IDOK), FALSE); - return TRUE; - } - EnableWindow(GetDlgItem(dialog, IDOK), TRUE); - tempCheat.lo[0] = val; - } - return TRUE; - } - - case IDC_EDIT3: // description - { - if (HIWORD(wparam) == EN_UPDATE) - GetWindowText(GetDlgItem(dialog, IDC_EDIT3), tempCheat.description, 75); - return TRUE; - } - - case IDC_RADIO1: // 1 byte - tempCheat.size = 0; - return TRUE; - case IDC_RADIO2: // 2 bytes - tempCheat.size = 1; - return TRUE; - case IDC_RADIO3: // 3 bytes - tempCheat.size = 2; - return TRUE; - case IDC_RADIO4: // 4 bytes - tempCheat.size = 3; - return TRUE; - - case IDC_CHECK1: // freeze - { - if (IsDlgButtonChecked(dialog, IDC_CHECK1) == BST_CHECKED) - tempCheat.enabled = 1; - else - tempCheat.enabled = 0; - } - } - } - } - return FALSE; -} -//============================================================================== Action Replay -BOOL CALLBACK CheatsAdd_XX_Proc(HWND dialog, UINT msg,WPARAM wparam,LPARAM lparam) -{ - switch(msg) - { - case WM_INITDIALOG: - { - SendMessage(GetDlgItem(dialog, IDC_EDIT2), EM_FMTLINES, (WPARAM)TRUE, (LPARAM)0); - - if (cheatXXtype == 0) - { - if (cheatXXaction == 0) // add - { - SetWindowText(dialog, "Add Action Replay code"); - tempCheat.enabled = TRUE; - } - else // edit - { - SetWindowText(dialog, "Edit Action Replay code"); - } - } - else - { - if (cheatXXaction == 0) // add - { - SetWindowText(dialog, "Add Codebreaker code"); - tempCheat.enabled = TRUE; - } - else // edit - { - SetWindowText(dialog, "Edit Codebreaker code"); - } - } - - if (cheatXXaction != 0) - { - char buf[sizeof(tempCheat.hi)+sizeof(tempCheat.lo)] = { 0 }; - memset(buf, 0, sizeof(buf)); - - cheatGetXXcodeString(tempCheat, buf); - SetWindowText(GetDlgItem(dialog, IDC_EDIT2), buf); - SetWindowText(GetDlgItem(dialog, IDC_EDIT3), tempCheat.description); - - EnableWindow(GetDlgItem(dialog, IDOK), (strlen(buf) > 16)?TRUE:FALSE); - SetWindowText(GetDlgItem(dialog, IDOK), "Update"); - } - CheckDlgButton(dialog, IDC_CHECK1, tempCheat.enabled?BST_CHECKED:BST_UNCHECKED); - - SendMessage(GetDlgItem(dialog, IDC_EDIT2), EM_SETLIMITTEXT, sizeof(tempCheat.hi)+sizeof(tempCheat.lo), 0); - SendMessage(GetDlgItem(dialog, IDC_EDIT3), EM_SETLIMITTEXT, sizeof(tempCheat.description), 0); - } - return TRUE; - - case WM_COMMAND: - { - switch (LOWORD(wparam)) - { - case IDOK: - { - char buf[sizeof(tempCheat.hi)+sizeof(tempCheat.lo)] = { 0 }; - - memset(buf, 0, sizeof(buf)); - GetWindowText(GetDlgItem(dialog, IDC_EDIT2), buf, sizeof(buf)); - - if (cheatXXtype == 0) // Action Replay - { - if (cheatXXaction == 0) // add - { - if (!cheatsAdd_AR(buf, tempCheat.description, tempCheat.enabled)) - { - MessageBox(dialog, "Syntax error in Action Replay code.\nTry again", "DeSmuME", - MB_OK | MB_ICONERROR); - return FALSE; - } - } - else // edit - { - if (!cheatsUpdate_AR(buf, tempCheat.description, tempCheat.enabled, cheatEditPos)) - { - MessageBox(dialog, "Syntax error in Action Replay code.\nTry again", "DeSmuME", - MB_OK | MB_ICONERROR); - return FALSE; - } - } - } - else - { - if (cheatXXaction == 0) // add - { - if (!cheatsAdd_CB(buf, tempCheat.description, tempCheat.enabled)) - { - MessageBox(dialog, "Syntax error in Codebreaker code.\nTry again", "DeSmuME", - MB_OK | MB_ICONERROR); - return FALSE; - } - } - else // edit - { - if (!cheatsUpdate_CB(buf, tempCheat.description, tempCheat.enabled, cheatEditPos)) - { - MessageBox(dialog, "Syntax error in Codebreaker code.\nTry again", "DeSmuME", - MB_OK | MB_ICONERROR); - return FALSE; - } - } - } - EndDialog(dialog, TRUE); - } - return TRUE; - - case IDCANCEL: - EndDialog(dialog, FALSE); - return TRUE; - - case IDC_EDIT2: // code - if (HIWORD(wparam) == EN_UPDATE) - { - char buf[sizeof(tempCheat.hi)+sizeof(tempCheat.lo)] = { 0 }; - - memset(buf, 0, sizeof(buf)); - GetWindowText(GetDlgItem(dialog, IDC_EDIT2), buf, sizeof(buf)); - if (strlen(buf) < 17) // min size of code "CXXXXXXX YYYYYYYY" - { - EnableWindow(GetDlgItem(dialog, IDOK), FALSE); - return TRUE; - } - EnableWindow(GetDlgItem(dialog, IDOK), TRUE); - } - return TRUE; - - case IDC_EDIT3: // description - if (HIWORD(wparam) == EN_UPDATE) - { - memset(tempCheat.description, 0, sizeof(tempCheat.description)); - GetWindowText(GetDlgItem(dialog, IDC_EDIT3), tempCheat.description, sizeof(tempCheat.description)); - } - return TRUE; - - case IDC_CHECK1: - if (IsDlgButtonChecked(dialog, IDC_CHECK1) == BST_CHECKED) - tempCheat.enabled = 1; - else - tempCheat.enabled = 0; - return TRUE; - } - } - } - return FALSE; -} -//============================================================================== -BOOL CALLBACK CheatsListBox_Proc(HWND dialog, UINT msg,WPARAM wparam,LPARAM lparam) -{ - switch(msg) - { - case WM_INITDIALOG: - { - LV_COLUMN lvColumn; - u32 address = 0; - u32 val = 0; - - cheatListView = GetDlgItem(dialog, IDC_LIST1); - - ListView_SetExtendedListViewStyle(cheatListView, LVS_EX_FULLROWSELECT | LVS_EX_TWOCLICKACTIVATE); - - memset(&lvColumn,0,sizeof(LV_COLUMN)); - lvColumn.mask=LVCF_FMT|LVCF_WIDTH|LVCF_TEXT; - - lvColumn.fmt=LVCFMT_CENTER; - lvColumn.cx=20; - lvColumn.pszText="X"; - ListView_InsertColumn(cheatListView, 0, &lvColumn); - - lvColumn.fmt=LVCFMT_LEFT; - lvColumn.cx=84; - lvColumn.pszText="Address"; - ListView_InsertColumn(cheatListView, 1, &lvColumn); - lvColumn.cx=100; - lvColumn.pszText="Value"; - ListView_InsertColumn(cheatListView, 2, &lvColumn); - lvColumn.cx=245; - lvColumn.pszText="Description"; - ListView_InsertColumn(cheatListView, 3, &lvColumn); - lvColumn.fmt=LVCFMT_CENTER; - - LVITEM lvi; - memset(&lvi,0,sizeof(LVITEM)); - lvi.mask = LVIF_TEXT|LVIF_STATE; - lvi.iItem = INT_MAX; - - cheatsGetListReset(); - SendMessage(cheatListView, WM_SETREDRAW, (WPARAM)FALSE,0); - while (cheatsGetList(&tempCheat)) - { - char buf[256]; - if (tempCheat.enabled) - lvi.pszText= "X"; - else - lvi.pszText= ""; - switch (tempCheat.type) - { - case 0: // Internal - { - u32 row = ListView_InsertItem(cheatListView, &lvi); - wsprintf(buf, "0x02%06X", tempCheat.hi[0]); - ListView_SetItemText(cheatListView, row, 1, buf); - ltoa(tempCheat.lo[0], buf, 10); - ListView_SetItemText(cheatListView, row, 2, buf); - ListView_SetItemText(cheatListView, row, 3, tempCheat.description); - break; - } - - case 1: // Action Replay - { - u32 row = ListView_InsertItem(cheatListView, &lvi); - ListView_SetItemText(cheatListView, row, 1, "Action"); - ListView_SetItemText(cheatListView, row, 2, "Replay"); - ListView_SetItemText(cheatListView, row, 3, tempCheat.description); - break; - } - - case 2: // Codebreaker - { - u32 row = ListView_InsertItem(cheatListView, &lvi); - ListView_SetItemText(cheatListView, row, 1, "Code"); - ListView_SetItemText(cheatListView, row, 2, "breaker"); - ListView_SetItemText(cheatListView, row, 3, tempCheat.description); - break; - } - } - } - SendMessage(cheatListView, WM_SETREDRAW, (WPARAM)TRUE,0); - - ListView_SetItemState(searchListView,0, LVIS_SELECTED|LVIS_FOCUSED, LVIS_SELECTED|LVIS_FOCUSED); - SetFocus(searchListView); - return TRUE; - } - - case WM_NOTIFY: - if (wparam == IDC_LIST1) - { - LPNMHDR tmp_msg = (LPNMHDR)lparam; - if ( tmp_msg->code == LVN_ITEMACTIVATE ) - { - cheatEditPos = ListView_GetNextItem(cheatListView, -1, LVNI_SELECTED|LVNI_FOCUSED); - cheatsGet(&tempCheat, cheatEditPos); - tempCheat.enabled = !tempCheat.enabled; - switch (tempCheat.type) - { - case 0: // internal - cheatsUpdate(tempCheat.size, tempCheat.hi[0], tempCheat.lo[0], tempCheat.description, tempCheat.enabled, cheatEditPos); - break; - - case 1: // Action Replay - cheatsUpdate_AR(NULL, NULL, tempCheat.enabled, cheatEditPos); - break; - - case 2: // Codebreaker - cheatsUpdate_CB(NULL, NULL, tempCheat.enabled, cheatEditPos); - break; - } - - - if (tempCheat.enabled) - ListView_SetItemText(cheatListView, cheatEditPos, 0, "X") - else - ListView_SetItemText(cheatListView, cheatEditPos, 0, ""); - EnableWindow(GetDlgItem(dialog, IDOK), TRUE); - } - - if ( tmp_msg->code == NM_CLICK ) - { - if (ListView_GetNextItem(cheatListView, -1, LVNI_SELECTED|LVNI_FOCUSED) != -1) - { - EnableWindow(GetDlgItem(dialog, IDC_BEDIT), TRUE); - EnableWindow(GetDlgItem(dialog, IDC_BREMOVE), TRUE); - } - else - { - EnableWindow(GetDlgItem(dialog, IDC_BEDIT), FALSE); - EnableWindow(GetDlgItem(dialog, IDC_BREMOVE), FALSE); - } - } - - return TRUE; - } - return FALSE; - - case WM_COMMAND: - { - switch (LOWORD(wparam)) - { - case IDOK: - if (cheatsSave()) - { - EndDialog(dialog, TRUE); - } - else - MessageBox(dialog, "Can't save cheats to file","Error",MB_OK); - return TRUE; - case IDCANCEL: - EndDialog(dialog, FALSE); - return TRUE; - - case IDC_BADD: - { - searchAddAddress = 0;; - searchAddValue = 0; - searchAddMode = 0; - searchAddFreeze = 1; - if (DialogBox(hAppInst, MAKEINTRESOURCE(IDD_CHEAT_ADD), dialog, (DLGPROC) CheatsAddProc)) - { - LVITEM lvi; - char buf[256]; - - memset(&lvi,0,sizeof(LVITEM)); - lvi.mask = LVIF_TEXT|LVIF_STATE; - lvi.iItem = INT_MAX; - - if (searchAddFreeze) - lvi.pszText= "X"; - else - lvi.pszText= " "; - u32 row = ListView_InsertItem(cheatListView, &lvi); - wsprintf(buf, "0x02%06X", searchAddAddress); - ListView_SetItemText(cheatListView, row, 1, buf); - ltoa(searchAddValue, buf, 10); - ListView_SetItemText(cheatListView, row, 2, buf); - ListView_SetItemText(cheatListView, row, 3, editBuf[2]); - - EnableWindow(GetDlgItem(dialog, IDOK), TRUE); - } - } - return TRUE; - - case IDC_BADD_AR: - { - if (LOWORD(wparam) == IDC_BADD_AR) - { - cheatXXtype = 0; - } - else - if (LOWORD(wparam) == IDC_BADD_CB) - { - cheatXXtype = 1; - } - else - return TRUE; - cheatXXaction = 0; // 0 = add - - if (DialogBox(hAppInst, MAKEINTRESOURCE(IDD_CHEAT_ADD_XX_CODE), dialog, (DLGPROC) CheatsAdd_XX_Proc)) - { - LVITEM lvi; - - memset(&lvi,0,sizeof(LVITEM)); - lvi.mask = LVIF_TEXT|LVIF_STATE; - lvi.iItem = INT_MAX; - - if (tempCheat.enabled) - lvi.pszText= "X"; - else - lvi.pszText= " "; - u32 row = ListView_InsertItem(cheatListView, &lvi); - if (cheatXXtype == 0) - { - ListView_SetItemText(cheatListView, row, 1, "Action"); - ListView_SetItemText(cheatListView, row, 2, "Replay"); - } - else - { - ListView_SetItemText(cheatListView, row, 1, "Code"); - ListView_SetItemText(cheatListView, row, 2, "breaker"); - } - ListView_SetItemText(cheatListView, row, 3, tempCheat.description); - - EnableWindow(GetDlgItem(dialog, IDOK), TRUE); - } - } - return TRUE; - - case IDC_BEDIT: - { - cheatEditPos = ListView_GetNextItem(cheatListView, -1, LVNI_SELECTED|LVNI_FOCUSED); - if (cheatEditPos > cheatsGetSize()) return TRUE; - - cheatsGet(&tempCheat, cheatEditPos); - - switch (tempCheat.type) - { - case 0: // internal - if (DialogBox(hAppInst, MAKEINTRESOURCE(IDD_CHEAT_ADD), dialog, (DLGPROC) CheatsEditProc)) - { - char buf[256]; - cheatsGet(&tempCheat, cheatEditPos); - if (tempCheat.enabled) - ListView_SetItemText(cheatListView, cheatEditPos, 0, "X"); - wsprintf(buf, "0x02%06X", tempCheat.hi[0]); - ListView_SetItemText(cheatListView, cheatEditPos, 1, buf); - ltoa(tempCheat.lo[0], buf, 10); - ListView_SetItemText(cheatListView, cheatEditPos, 2, buf); - ListView_SetItemText(cheatListView, cheatEditPos, 3, tempCheat.description); - EnableWindow(GetDlgItem(dialog, IDOK), TRUE); - } - break; - - case 1: // Action replay - case 2: // Codebreaker - if (tempCheat.type == 1) - cheatXXtype = 0; - else - cheatXXtype = 1; - cheatXXaction = 1; // 1 = edit - - if (DialogBox(hAppInst, MAKEINTRESOURCE(IDD_CHEAT_ADD_XX_CODE), dialog, (DLGPROC) CheatsAdd_XX_Proc)) - { - cheatsGet(&tempCheat, cheatEditPos); - if (tempCheat.enabled) - ListView_SetItemText(cheatListView, cheatEditPos, 0, "X"); - - if (cheatXXtype == 0) - { - ListView_SetItemText(cheatListView, cheatEditPos, 1, "Action"); - ListView_SetItemText(cheatListView, cheatEditPos, 2, "Replay"); - } - else - { - ListView_SetItemText(cheatListView, cheatEditPos, 1, "Code"); - ListView_SetItemText(cheatListView, cheatEditPos, 2, "breaker"); - } - - ListView_SetItemText(cheatListView, cheatEditPos, 3, tempCheat.description); - EnableWindow(GetDlgItem(dialog, IDOK), TRUE); - } - break; - } - } - return TRUE; - - case IDC_BREMOVE: - { - int tmp_pos = ListView_GetNextItem(cheatListView, -1, LVNI_SELECTED|LVNI_FOCUSED); - if (tmp_pos != -1) - { - if (cheatsRemove(tmp_pos)) - { - ListView_DeleteItem(cheatListView, tmp_pos); - EnableWindow(GetDlgItem(dialog, IDOK), TRUE); - } - } - - } - return TRUE; - } - break; - } - } - return FALSE; -} - -void CheatsListDialog(HWND hwnd) -{ - if (!cheatsPush()) return; - memset(&tempCheat, 0, sizeof(CHEATS_LIST)); - u32 res=DialogBox(hAppInst, MAKEINTRESOURCE(IDD_CHEAT_LIST), hwnd, (DLGPROC) CheatsListBox_Proc); - if (res) - { - cheatsSave(); - cheatsStackClear(); - } - else - { - cheatsPop(); - } -} - - -// ================================================================================== Search -BOOL CALLBACK CheatsSearchExactWnd(HWND dialog, UINT msg,WPARAM wparam,LPARAM lparam) -{ - switch(msg) - { - case WM_INITDIALOG: - { - EnableWindow(hBRestart, TRUE); - if (searchNumberResults) - EnableWindow(hBView, TRUE); - else - EnableWindow(hBView, FALSE); - EnableWindow(hBSearch, FALSE); - - SendMessage(GetDlgItem(dialog, IDC_EVALUE), EM_SETLIMITTEXT, 10, 0); - SetWindowText(GetDlgItem(dialog, IDC_STATIC_RANGE), searchRangeText[searchSign][searchSize]); - oldEditProc = (WNDPROC)SetWindowLongPtr(GetDlgItem(dialog, IDC_EVALUE), GWLP_WNDPROC, (LONG)EditValueProc); - char buf[256]; - memset(buf, 0, 256); - ltoa(searchNumberResults, buf, 10); - SetWindowText(GetDlgItem(dialog, IDC_SNUMBER), buf); - SetFocus(GetDlgItem(dialog, IDC_EVALUE)); - break; - } - - case WM_COMMAND: - { - switch (LOWORD(wparam)) - { - case IDC_EVALUE: - { - if (HIWORD(wparam) == EN_UPDATE) - { - char buf[10]; - GetWindowText(GetDlgItem(dialog, IDC_EVALUE), buf, 10); - if (!strlen(buf)) - { - EnableWindow(hBSearch, FALSE); - return TRUE; - } - - u32 val = atol(buf); - if (val > searchRange[searchSize][1]) - { - EnableWindow(hBSearch, FALSE); - return TRUE; - } - EnableWindow(hBSearch, TRUE); - exactVal = val; - } - return TRUE; - } - } - break; - } - } - return FALSE; -} - -BOOL CALLBACK CheatsSearchCompWnd(HWND dialog, UINT msg,WPARAM wparam,LPARAM lparam) -{ - switch(msg) - { - case WM_INITDIALOG: - { - EnableWindow(hBRestart, TRUE); - if (searchNumberResults) - EnableWindow(hBView, TRUE); - else - EnableWindow(hBView, FALSE); - EnableWindow(hBSearch, TRUE); - - CheckDlgButton(dialog, searchCompIDDs[searchComp], BST_CHECKED); - - char buf[256]; - ltoa(searchNumberResults, buf, 10); - SetWindowText(GetDlgItem(dialog, IDC_SNUMBER), buf); - break; - } - - case WM_COMMAND: - { - switch (LOWORD(wparam)) - { - case IDC_RADIO1: searchComp = 0; break; - case IDC_RADIO2: searchComp = 1; break; - case IDC_RADIO3: searchComp = 2; break; - case IDC_RADIO4: searchComp = 3; break; - } - break; - } - } - return FALSE; -} - -BOOL CALLBACK CheatsSearchResultWnd(HWND dialog, UINT msg,WPARAM wparam,LPARAM lparam) -{ - switch(msg) - { - case WM_INITDIALOG: - { - EnableWindow(hBRestart, TRUE); - if (searchNumberResults) - EnableWindow(hBView, TRUE); - else - EnableWindow(hBView, FALSE); - EnableWindow(hBSearch, FALSE); - char buf[256]; - ltoa(searchNumberResults, buf, 10); - SetWindowText(GetDlgItem(dialog, IDC_SNUMBER), buf); - return TRUE; - } - } - return FALSE; -} - -BOOL CALLBACK CheatsSearchViewWnd(HWND dialog, UINT msg,WPARAM wparam,LPARAM lparam) -{ - switch(msg) - { - case WM_INITDIALOG: - { - LV_COLUMN lvColumn; - u32 address = 0; - u32 val = 0; - - searchListView = GetDlgItem(dialog, IDC_LIST); - - ListView_SetExtendedListViewStyle(searchListView, LVS_EX_FULLROWSELECT|LVS_EX_GRIDLINES); - - memset(&lvColumn,0,sizeof(LV_COLUMN)); - lvColumn.mask=LVCF_FMT|LVCF_WIDTH|LVCF_TEXT; - lvColumn.fmt=LVCFMT_LEFT; - lvColumn.cx=94; - lvColumn.pszText="Address"; - ListView_InsertColumn(searchListView, 0, &lvColumn); - lvColumn.cx=130; - lvColumn.pszText="Value"; - ListView_InsertColumn(searchListView, 1, &lvColumn); - - LVITEM lvi; - memset(&lvi,0,sizeof(LVITEM)); - lvi.mask = LVIF_TEXT|LVIF_STATE; - lvi.iItem = INT_MAX; - - cheatSearchGetListReset(); - SendMessage(searchListView, WM_SETREDRAW, (WPARAM)FALSE,0); - while (cheatSearchGetList(&address, &val)) - { - char buf[256]; - wsprintf(buf, "0x02%06X", address); - lvi.pszText= buf; - u32 row = SendMessage(searchListView, LVM_INSERTITEM, 0, (LPARAM)&lvi); - _ltoa(val, buf, 10); - ListView_SetItemText(searchListView, row, 1, buf); - } - SendMessage(searchListView, WM_SETREDRAW, (WPARAM)TRUE,0); - ListView_SetItemState(searchListView,0, LVIS_SELECTED|LVIS_FOCUSED, LVIS_SELECTED|LVIS_FOCUSED); - SetFocus(searchListView); - } - return TRUE; - - case WM_COMMAND: - { - switch (LOWORD(wparam)) - { - case IDCANCEL: - ListView_DeleteAllItems(searchListView); - EndDialog(dialog, FALSE); - return TRUE; - case IDC_BADD: - { - u32 val = 0; - char buf[12]; - u32 pos = ListView_GetNextItem(searchListView, -1, LVNI_SELECTED|LVNI_FOCUSED); - ListView_GetItemText(searchListView, pos, 0, buf, 12); - sscanf_s(buf, "%x", &val); - searchAddAddress = val & 0x00FFFFFF; - ListView_GetItemText(searchListView, pos, 1, buf, 12); - searchAddValue = atol(buf); - searchAddMode = 1; - searchAddSize = searchSize; - DialogBox(hAppInst, MAKEINTRESOURCE(IDD_CHEAT_ADD), dialog, (DLGPROC) CheatsAddProc); - } - return TRUE; - } - } - } - return FALSE; -} - -BOOL CALLBACK CheatsSearchMainWnd(HWND dialog, UINT msg,WPARAM wparam,LPARAM lparam) -{ - switch(msg) - { - case WM_INITDIALOG: - { - CheckDlgButton(dialog, searchSizeIDDs[searchSize], BST_CHECKED); - CheckDlgButton(dialog, searchSignIDDs[searchSign], BST_CHECKED); - CheckDlgButton(dialog, searchTypeIDDs[searchType], BST_CHECKED); - for (int i = 0; i < 4; i++) - SetWindowText(GetDlgItem(dialog, searchRangeIDDs[i]), searchRangeText[searchSign][i]); - EnableWindow(hBRestart, FALSE); - EnableWindow(hBView, FALSE); - EnableWindow(hBSearch, TRUE); - break; - } - - case WM_COMMAND: - { - switch (LOWORD(wparam)) - { - case IDC_RADIO1: // 1 byte - searchSize = 0; - return TRUE; - case IDC_RADIO2: // 2 bytes - searchSize = 1; - return TRUE; - case IDC_RADIO3: // 3 bytes - searchSize = 2; - return TRUE; - case IDC_RADIO4: // 4 bytes - searchSize = 3; - return TRUE; - - case IDC_RADIO5: // unsigned - searchSign = 0; - for (int i = 0; i < 4; i++) - SetWindowText(GetDlgItem(dialog, searchRangeIDDs[i]), searchRangeText[searchSign][i]); - return TRUE; - - case IDC_RADIO6: //signed - searchSign = 1; - for (int i = 0; i < 4; i++) - SetWindowText(GetDlgItem(dialog, searchRangeIDDs[i]), searchRangeText[searchSign][i]); - return TRUE; - - case IDC_RADIO7: // exact value search - searchType = 0; - return TRUE; - - case IDC_RADIO8: // comparative search - searchType = 1; - return TRUE; - } - return TRUE; - } - } - return FALSE; -} - -DLGPROC CheatsSearchSubWnds[2][4] = { - { CheatsSearchMainWnd, CheatsSearchExactWnd, CheatsSearchResultWnd, NULL }, - { CheatsSearchMainWnd, CheatsSearchResultWnd, CheatsSearchCompWnd, CheatsSearchResultWnd } -}; - -//============================================================================== -BOOL CALLBACK CheatsSearchProc(HWND dialog, UINT msg,WPARAM wparam,LPARAM lparam) -{ - switch(msg) - { - case WM_INITDIALOG: - { - hBRestart = GetDlgItem(dialog, IDC_BRESTART); - hBView = GetDlgItem(dialog, IDC_BVIEW); - hBSearch = GetDlgItem(dialog, IDC_BSEARCH); - - searchWnd=CreateDialog(hAppInst, MAKEINTRESOURCE(searchIDDs[searchType][searchStep]), - dialog, (DLGPROC)CheatsSearchSubWnds[searchType][searchStep]); - return TRUE; - } - - case WM_COMMAND: - { - switch (LOWORD(wparam)) - { - case IDOK: - case IDCANCEL: - if (searchWnd) DestroyWindow(searchWnd); - EndDialog(dialog, FALSE); - return TRUE; - - case IDC_BVIEW: - DialogBox(hAppInst, MAKEINTRESOURCE(IDD_CHEAT_SEARCH_VIEW), dialog, (DLGPROC)CheatsSearchViewWnd); - return TRUE; - - case IDC_BSEARCH: - if (searchStep == 0) - cheatsSearchInit(searchType, searchSize, searchSign); - if (searchType == 0) - { - if (searchStep == 1) - searchNumberResults = cheatsSearchValue(exactVal); - } - else - { - if (searchStep == 2) - searchNumberResults = cheatsSearchComp(searchComp); - } - - searchStep++; - if (searchWnd) DestroyWindow(searchWnd); - searchWnd=CreateDialog(hAppInst, MAKEINTRESOURCE(searchIDDs[searchType][searchStep]), - dialog, (DLGPROC)CheatsSearchSubWnds[searchType][searchStep]); - if (searchType == 0) - { - if (searchStep == 2) searchStep = 1; - } - else - { - if (searchStep == 1) searchStep = 2; - if (searchStep == 3) searchStep = 2; - } - return TRUE; - - case IDC_BRESTART: - cheatsSearchClose(); - searchStep = 0; - searchNumberResults = 0; - if (searchWnd) DestroyWindow(searchWnd); - searchWnd=CreateDialog(hAppInst, MAKEINTRESOURCE(searchIDDs[searchType][searchStep]), - dialog, (DLGPROC)CheatsSearchSubWnds[searchType][searchStep]); - return TRUE; - } - break; - } - } - return FALSE; -} - -void CheatsSearchDialog(HWND hwnd) -{ - DialogBox(hAppInst, MAKEINTRESOURCE(IDD_CHEAT_SEARCH), hwnd, (DLGPROC) CheatsSearchProc); -} - -void CheatsSearchReset() -{ - searchType = 0; - searchSize = 0; - searchSign = 0; - searchStep = 0; - searchComp = 0; - searchAddSize = 0; - exactVal = 0; - searchNumberResults = 0; -} +/* Copyright (C) 2006 yopyop + yopyop156@ifrance.com + yopyop156.ifrance.com + + Copyright 2009 DeSmuME team + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA +*/ + +#include "cheatsWin.h" +#include +#include "../cheatSystem.h" +#include "resource.h" +#include "../debug.h" + +static u8 searchType = 0; +static u8 searchSize = 0; +static u8 searchSign = 0; +static u8 searchStep = 0; +static u8 searchComp = 0; +static HWND hBRestart = NULL; +static HWND hBView = NULL; +static HWND hBSearch = NULL; +static u32 exactVal = 0; +static u32 searchNumberResults = 0; + +static u32 searchAddAddress = 0; +static u32 searchAddValue = 0; +static u8 searchAddMode = 0; +static u8 searchAddFreeze = 1; +static u8 searchAddSize = 0; +static char editBuf[3][75] = { 0 }; +static u32 cheatEditPos = 0; +static u8 cheatXXtype = 0; +static u8 cheatXXaction = 0; + +static HWND searchWnd = NULL; +static HWND searchListView = NULL; +static HWND cheatListView = NULL; +static WNDPROC oldEditProc = NULL; +static WNDPROC oldEditProcHEX = NULL; + +CHEATS_LIST tempCheat; + +u32 searchIDDs[2][4] = { + { IDD_CHEAT_SEARCH_MAIN, IDD_CHEAT_SEARCH_EXACT, IDD_CHEAT_SEARCH_RESULT, NULL }, + { IDD_CHEAT_SEARCH_MAIN, IDD_CHEAT_SEARCH_RESULT, IDD_CHEAT_SEARCH_COMP, IDD_CHEAT_SEARCH_RESULT} +}; + +u32 searchSizeIDDs[4] = { IDC_RADIO1, IDC_RADIO2, IDC_RADIO3, IDC_RADIO4 }; +u32 searchSignIDDs[2] = { IDC_RADIO5, IDC_RADIO6 }; +u32 searchTypeIDDs[2] = { IDC_RADIO7, IDC_RADIO8 }; +u32 searchCompIDDs[4] = { IDC_RADIO1, IDC_RADIO2, IDC_RADIO3, IDC_RADIO4 }; + +u32 searchRangeIDDs[4] = { IDC_STATIC_S1, IDC_STATIC_S2, IDC_STATIC_S3, IDC_STATIC_S4 }; +char *searchRangeText[2][4] = { {"[0..255]", "[0..65536]", "[0..16777215]", "[0..4294967295]"}, + {"[-128..127]", "[-32168..32767]", "[-8388608..8388607]", "[-2147483648..2147483647]"}}; + +u32 searchRange[4][2] = { + { 0, 255 }, + { 0, 65536 }, + { 0, 16777215 }, + { 0, 4294967295 } + }; + +LRESULT CALLBACK EditValueProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam) +{ + // TODO: check paste + if (msg == WM_CHAR) + { + switch (wParam) + { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': + break; + case '-': + { + u8 pos = 0; + SendMessage(hwnd, EM_GETSEL, (WPARAM)&pos, NULL); + if (pos != 0) wParam = 0; + } + break; + + case VK_BACK: + break; + default: + wParam = 0; + break; + } + + } + + return CallWindowProc(oldEditProc, hwnd, msg, wParam, lParam); +} + +LRESULT CALLBACK EditValueHEXProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam) +{ + // TODO: check paste + if (msg == WM_CHAR) + { + switch (wParam) + { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + break; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + wParam -= 32; + break; + case VK_BACK: + break; + default: + wParam = 0; + break; + } + + } + + return CallWindowProc(oldEditProcHEX, hwnd, msg, wParam, lParam); +} + +BOOL CALLBACK CheatsAddProc(HWND dialog, UINT msg,WPARAM wparam,LPARAM lparam) +{ + static WNDPROC saveOldEditProc = NULL; + + switch(msg) + { + case WM_INITDIALOG: + { + saveOldEditProc = oldEditProc; + SendMessage(GetDlgItem(dialog, IDC_EDIT1), EM_SETLIMITTEXT, 6, 0); + SendMessage(GetDlgItem(dialog, IDC_EDIT2), EM_SETLIMITTEXT, 10, 0); + SendMessage(GetDlgItem(dialog, IDC_EDIT3), EM_SETLIMITTEXT, 75, 0); + oldEditProcHEX = (WNDPROC)SetWindowLongPtr(GetDlgItem(dialog, IDC_EDIT1), GWLP_WNDPROC, (LONG)EditValueHEXProc); + oldEditProc = (WNDPROC)SetWindowLongPtr(GetDlgItem(dialog, IDC_EDIT2), GWLP_WNDPROC, (LONG)EditValueProc); + + if (searchAddMode == 1) + { + char buf[10]; + searchAddAddress &= 0x00FFFFFF; + wsprintf(buf, "%06X", searchAddAddress); + SetWindowText(GetDlgItem(dialog, IDC_EDIT1), buf); + wsprintf(buf, "%i", searchAddValue); + SetWindowText(GetDlgItem(dialog, IDC_EDIT2), buf); + EnableWindow(GetDlgItem(dialog, IDOK), TRUE); + EnableWindow(GetDlgItem(dialog, IDC_EDIT1), FALSE); + EnableWindow(GetDlgItem(dialog, IDC_RADIO1), FALSE); + EnableWindow(GetDlgItem(dialog, IDC_RADIO2), FALSE); + EnableWindow(GetDlgItem(dialog, IDC_RADIO3), FALSE); + EnableWindow(GetDlgItem(dialog, IDC_RADIO4), FALSE); + EnableWindow(GetDlgItem(dialog, IDC_RADIO8), FALSE); + } + else + { + SetWindowText(GetDlgItem(dialog, IDC_EDIT2), "0"); + CheckDlgButton(dialog, IDC_RADIO1, BST_CHECKED); + } + + memset(editBuf, 0, sizeof(editBuf)); + + GetWindowText(GetDlgItem(dialog, IDC_EDIT1), editBuf[0], 10); + GetWindowText(GetDlgItem(dialog, IDC_EDIT2), editBuf[1], 10); + + CheckDlgButton(dialog, IDC_CHECK1, BST_CHECKED); + CheckDlgButton(dialog, searchSizeIDDs[searchAddSize], BST_CHECKED); + } + return TRUE; + + case WM_COMMAND: + { + switch (LOWORD(wparam)) + { + case IDOK: + { + u32 tmp_addr = 0; + sscanf_s(editBuf[0], "%x", &tmp_addr); + + if (cheatsAdd(searchAddSize, tmp_addr, atol(editBuf[1]), editBuf[2], searchAddFreeze)) + { + if ((searchAddMode == 0) || (cheatsSave() && searchAddMode == 1)) + { + oldEditProc = saveOldEditProc; + searchAddAddress = tmp_addr; + searchAddValue = atol(editBuf[1]); + + EndDialog(dialog, TRUE); + } + } + } + return TRUE; + + case IDCANCEL: + oldEditProc = saveOldEditProc; + EndDialog(dialog, FALSE); + return TRUE; + + case IDC_EDIT1: // address + { + if (HIWORD(wparam) == EN_UPDATE) + { + GetWindowText(GetDlgItem(dialog, IDC_EDIT1), editBuf[0], 8); + if ( (strlen(editBuf[0]) < 6) || (!strlen(editBuf[1])) ) + { + EnableWindow(GetDlgItem(dialog, IDOK), FALSE); + return TRUE; + } + + u32 val = 0; + sscanf_s(editBuf[0], "%x", &val); + val &= 0x00FFFFFF; + if (val > 0x400000) + { + EnableWindow(GetDlgItem(dialog, IDOK), FALSE); + return TRUE; + } + EnableWindow(GetDlgItem(dialog, IDOK), TRUE); + } + return TRUE; + } + + case IDC_EDIT2: // value + { + if (HIWORD(wparam) == EN_UPDATE) + { + GetWindowText(GetDlgItem(dialog, IDC_EDIT2), editBuf[1], 10); + if ( (strlen(editBuf[0]) < 6) || (!strlen(editBuf[1])) ) + { + EnableWindow(GetDlgItem(dialog, IDOK), FALSE); + return TRUE; + } + + u32 val = atol(editBuf[1]); + if (val > searchRange[searchAddSize][1]) + { + EnableWindow(GetDlgItem(dialog, IDOK), FALSE); + return TRUE; + } + EnableWindow(GetDlgItem(dialog, IDOK), TRUE); + } + return TRUE; + } + + case IDC_EDIT3: // description + { + if (HIWORD(wparam) == EN_UPDATE) + GetWindowText(GetDlgItem(dialog, IDC_EDIT3), editBuf[2], 75); + return TRUE; + } + + case IDC_RADIO1: // 1 byte + searchAddSize = 0; + return TRUE; + case IDC_RADIO2: // 2 bytes + searchAddSize = 1; + return TRUE; + case IDC_RADIO3: // 3 bytes + searchAddSize = 2; + return TRUE; + case IDC_RADIO4: // 4 bytes + searchAddSize = 3; + return TRUE; + + case IDC_CHECK1: + { + if (IsDlgButtonChecked(dialog, IDC_CHECK1) == BST_CHECKED) + searchAddFreeze = 1; + else + searchAddFreeze = 0; + } + } + } + } + return FALSE; +} + +BOOL CALLBACK CheatsEditProc(HWND dialog, UINT msg,WPARAM wparam,LPARAM lparam) +{ + static WNDPROC saveOldEditProc = NULL; + char buf[100] = {0}, buf2[100] = {0}; + + switch(msg) + { + case WM_INITDIALOG: + { + saveOldEditProc = oldEditProc; + SendMessage(GetDlgItem(dialog, IDC_EDIT1), EM_SETLIMITTEXT, 6, 0); + SendMessage(GetDlgItem(dialog, IDC_EDIT2), EM_SETLIMITTEXT, 10, 0); + SendMessage(GetDlgItem(dialog, IDC_EDIT3), EM_SETLIMITTEXT, 75, 0); + oldEditProcHEX = (WNDPROC)SetWindowLongPtr(GetDlgItem(dialog, IDC_EDIT1), GWLP_WNDPROC, (LONG)EditValueHEXProc); + oldEditProc = (WNDPROC)SetWindowLongPtr(GetDlgItem(dialog, IDC_EDIT2), GWLP_WNDPROC, (LONG)EditValueProc); + + cheatsGet(&tempCheat, cheatEditPos); + + memset(buf, 0, 100); + memset(buf2, 0, 100); + tempCheat.hi[0] &= 0x00FFFFFF; + wsprintf(buf, "%06X", tempCheat.hi[0]); + SetWindowText(GetDlgItem(dialog, IDC_EDIT1), buf); + wsprintf(buf, "%i", tempCheat.lo[0]); + SetWindowText(GetDlgItem(dialog, IDC_EDIT2), buf); + strcpy(buf, tempCheat.description); + SetWindowText(GetDlgItem(dialog, IDC_EDIT3), buf); + EnableWindow(GetDlgItem(dialog, IDOK), TRUE); + + CheckDlgButton(dialog, IDC_CHECK1, tempCheat.enabled?BST_CHECKED:BST_UNCHECKED); + CheckDlgButton(dialog, searchSizeIDDs[tempCheat.size], BST_CHECKED); + SetWindowText(GetDlgItem(dialog, IDOK), "Update"); + } + return TRUE; + + case WM_COMMAND: + { + switch (LOWORD(wparam)) + { + case IDOK: + { + if (cheatsUpdate(tempCheat.size, tempCheat.hi[0], tempCheat.lo[0], tempCheat.description, tempCheat.enabled, cheatEditPos)) + { + oldEditProc = saveOldEditProc; + EndDialog(dialog, TRUE); + } + } + return TRUE; + + case IDCANCEL: + oldEditProc = saveOldEditProc; + EndDialog(dialog, FALSE); + return TRUE; + + case IDC_EDIT1: // address + { + if (HIWORD(wparam) == EN_UPDATE) + { + GetWindowText(GetDlgItem(dialog, IDC_EDIT1), buf, 8); + GetWindowText(GetDlgItem(dialog, IDC_EDIT2), buf2, 10); + if ( (strlen(buf) < 6) || (!strlen(buf2)) ) + { + EnableWindow(GetDlgItem(dialog, IDOK), FALSE); + return TRUE; + } + + u32 val = 0; + sscanf_s(buf, "%x", &val); + val &= 0x00FFFFFF; + if (val > 0x400000) + { + EnableWindow(GetDlgItem(dialog, IDOK), FALSE); + return TRUE; + } + EnableWindow(GetDlgItem(dialog, IDOK), TRUE); + tempCheat.hi[0] = val; + } + return TRUE; + } + + case IDC_EDIT2: // value + { + if (HIWORD(wparam) == EN_UPDATE) + { + GetWindowText(GetDlgItem(dialog, IDC_EDIT2), buf, 10); + GetWindowText(GetDlgItem(dialog, IDC_EDIT1), buf2, 8); + if ( (strlen(buf2) < 6) || (!strlen(buf)) ) + { + EnableWindow(GetDlgItem(dialog, IDOK), FALSE); + return TRUE; + } + + u32 val = atol(buf); + if (val > searchRange[tempCheat.size][1]) + { + EnableWindow(GetDlgItem(dialog, IDOK), FALSE); + return TRUE; + } + EnableWindow(GetDlgItem(dialog, IDOK), TRUE); + tempCheat.lo[0] = val; + } + return TRUE; + } + + case IDC_EDIT3: // description + { + if (HIWORD(wparam) == EN_UPDATE) + GetWindowText(GetDlgItem(dialog, IDC_EDIT3), tempCheat.description, 75); + return TRUE; + } + + case IDC_RADIO1: // 1 byte + tempCheat.size = 0; + return TRUE; + case IDC_RADIO2: // 2 bytes + tempCheat.size = 1; + return TRUE; + case IDC_RADIO3: // 3 bytes + tempCheat.size = 2; + return TRUE; + case IDC_RADIO4: // 4 bytes + tempCheat.size = 3; + return TRUE; + + case IDC_CHECK1: // freeze + { + if (IsDlgButtonChecked(dialog, IDC_CHECK1) == BST_CHECKED) + tempCheat.enabled = 1; + else + tempCheat.enabled = 0; + } + } + } + } + return FALSE; +} +//============================================================================== Action Replay +BOOL CALLBACK CheatsAdd_XX_Proc(HWND dialog, UINT msg,WPARAM wparam,LPARAM lparam) +{ + switch(msg) + { + case WM_INITDIALOG: + { + SendMessage(GetDlgItem(dialog, IDC_EDIT2), EM_FMTLINES, (WPARAM)TRUE, (LPARAM)0); + + if (cheatXXtype == 0) + { + if (cheatXXaction == 0) // add + { + SetWindowText(dialog, "Add Action Replay code"); + tempCheat.enabled = TRUE; + } + else // edit + { + SetWindowText(dialog, "Edit Action Replay code"); + } + } + else + { + if (cheatXXaction == 0) // add + { + SetWindowText(dialog, "Add Codebreaker code"); + tempCheat.enabled = TRUE; + } + else // edit + { + SetWindowText(dialog, "Edit Codebreaker code"); + } + } + + if (cheatXXaction != 0) + { + char buf[sizeof(tempCheat.hi)+sizeof(tempCheat.lo)] = { 0 }; + memset(buf, 0, sizeof(buf)); + + cheatGetXXcodeString(tempCheat, buf); + SetWindowText(GetDlgItem(dialog, IDC_EDIT2), buf); + SetWindowText(GetDlgItem(dialog, IDC_EDIT3), tempCheat.description); + + EnableWindow(GetDlgItem(dialog, IDOK), (strlen(buf) > 16)?TRUE:FALSE); + SetWindowText(GetDlgItem(dialog, IDOK), "Update"); + } + CheckDlgButton(dialog, IDC_CHECK1, tempCheat.enabled?BST_CHECKED:BST_UNCHECKED); + + SendMessage(GetDlgItem(dialog, IDC_EDIT2), EM_SETLIMITTEXT, sizeof(tempCheat.hi)+sizeof(tempCheat.lo), 0); + SendMessage(GetDlgItem(dialog, IDC_EDIT3), EM_SETLIMITTEXT, sizeof(tempCheat.description), 0); + } + return TRUE; + + case WM_COMMAND: + { + switch (LOWORD(wparam)) + { + case IDOK: + { + char buf[sizeof(tempCheat.hi)+sizeof(tempCheat.lo)] = { 0 }; + + memset(buf, 0, sizeof(buf)); + GetWindowText(GetDlgItem(dialog, IDC_EDIT2), buf, sizeof(buf)); + + if (cheatXXtype == 0) // Action Replay + { + if (cheatXXaction == 0) // add + { + if (!cheatsAdd_AR(buf, tempCheat.description, tempCheat.enabled)) + { + MessageBox(dialog, "Syntax error in Action Replay code.\nTry again", "DeSmuME", + MB_OK | MB_ICONERROR); + return FALSE; + } + } + else // edit + { + if (!cheatsUpdate_AR(buf, tempCheat.description, tempCheat.enabled, cheatEditPos)) + { + MessageBox(dialog, "Syntax error in Action Replay code.\nTry again", "DeSmuME", + MB_OK | MB_ICONERROR); + return FALSE; + } + } + } + else + { + if (cheatXXaction == 0) // add + { + if (!cheatsAdd_CB(buf, tempCheat.description, tempCheat.enabled)) + { + MessageBox(dialog, "Syntax error in Codebreaker code.\nTry again", "DeSmuME", + MB_OK | MB_ICONERROR); + return FALSE; + } + } + else // edit + { + if (!cheatsUpdate_CB(buf, tempCheat.description, tempCheat.enabled, cheatEditPos)) + { + MessageBox(dialog, "Syntax error in Codebreaker code.\nTry again", "DeSmuME", + MB_OK | MB_ICONERROR); + return FALSE; + } + } + } + EndDialog(dialog, TRUE); + } + return TRUE; + + case IDCANCEL: + EndDialog(dialog, FALSE); + return TRUE; + + case IDC_EDIT2: // code + if (HIWORD(wparam) == EN_UPDATE) + { + char buf[sizeof(tempCheat.hi)+sizeof(tempCheat.lo)] = { 0 }; + + memset(buf, 0, sizeof(buf)); + GetWindowText(GetDlgItem(dialog, IDC_EDIT2), buf, sizeof(buf)); + if (strlen(buf) < 17) // min size of code "CXXXXXXX YYYYYYYY" + { + EnableWindow(GetDlgItem(dialog, IDOK), FALSE); + return TRUE; + } + EnableWindow(GetDlgItem(dialog, IDOK), TRUE); + } + return TRUE; + + case IDC_EDIT3: // description + if (HIWORD(wparam) == EN_UPDATE) + { + memset(tempCheat.description, 0, sizeof(tempCheat.description)); + GetWindowText(GetDlgItem(dialog, IDC_EDIT3), tempCheat.description, sizeof(tempCheat.description)); + } + return TRUE; + + case IDC_CHECK1: + if (IsDlgButtonChecked(dialog, IDC_CHECK1) == BST_CHECKED) + tempCheat.enabled = 1; + else + tempCheat.enabled = 0; + return TRUE; + } + } + } + return FALSE; +} +//============================================================================== +BOOL CALLBACK CheatsListBox_Proc(HWND dialog, UINT msg,WPARAM wparam,LPARAM lparam) +{ + switch(msg) + { + case WM_INITDIALOG: + { + LV_COLUMN lvColumn; + u32 address = 0; + u32 val = 0; + + cheatListView = GetDlgItem(dialog, IDC_LIST1); + + ListView_SetExtendedListViewStyle(cheatListView, LVS_EX_FULLROWSELECT | LVS_EX_TWOCLICKACTIVATE); + + memset(&lvColumn,0,sizeof(LV_COLUMN)); + lvColumn.mask=LVCF_FMT|LVCF_WIDTH|LVCF_TEXT; + + lvColumn.fmt=LVCFMT_CENTER; + lvColumn.cx=20; + lvColumn.pszText="X"; + ListView_InsertColumn(cheatListView, 0, &lvColumn); + + lvColumn.fmt=LVCFMT_LEFT; + lvColumn.cx=84; + lvColumn.pszText="Address"; + ListView_InsertColumn(cheatListView, 1, &lvColumn); + lvColumn.cx=100; + lvColumn.pszText="Value"; + ListView_InsertColumn(cheatListView, 2, &lvColumn); + lvColumn.cx=245; + lvColumn.pszText="Description"; + ListView_InsertColumn(cheatListView, 3, &lvColumn); + lvColumn.fmt=LVCFMT_CENTER; + + LVITEM lvi; + memset(&lvi,0,sizeof(LVITEM)); + lvi.mask = LVIF_TEXT|LVIF_STATE; + lvi.iItem = INT_MAX; + + cheatsGetListReset(); + SendMessage(cheatListView, WM_SETREDRAW, (WPARAM)FALSE,0); + while (cheatsGetList(&tempCheat)) + { + char buf[256]; + if (tempCheat.enabled) + lvi.pszText= "X"; + else + lvi.pszText= ""; + switch (tempCheat.type) + { + case 0: // Internal + { + u32 row = ListView_InsertItem(cheatListView, &lvi); + wsprintf(buf, "0x02%06X", tempCheat.hi[0]); + ListView_SetItemText(cheatListView, row, 1, buf); + ltoa(tempCheat.lo[0], buf, 10); + ListView_SetItemText(cheatListView, row, 2, buf); + ListView_SetItemText(cheatListView, row, 3, tempCheat.description); + break; + } + + case 1: // Action Replay + { + u32 row = ListView_InsertItem(cheatListView, &lvi); + ListView_SetItemText(cheatListView, row, 1, "Action"); + ListView_SetItemText(cheatListView, row, 2, "Replay"); + ListView_SetItemText(cheatListView, row, 3, tempCheat.description); + break; + } + + case 2: // Codebreaker + { + u32 row = ListView_InsertItem(cheatListView, &lvi); + ListView_SetItemText(cheatListView, row, 1, "Code"); + ListView_SetItemText(cheatListView, row, 2, "breaker"); + ListView_SetItemText(cheatListView, row, 3, tempCheat.description); + break; + } + } + } + SendMessage(cheatListView, WM_SETREDRAW, (WPARAM)TRUE,0); + + ListView_SetItemState(searchListView,0, LVIS_SELECTED|LVIS_FOCUSED, LVIS_SELECTED|LVIS_FOCUSED); + SetFocus(searchListView); + return TRUE; + } + + case WM_NOTIFY: + if (wparam == IDC_LIST1) + { + LPNMHDR tmp_msg = (LPNMHDR)lparam; + if ( tmp_msg->code == LVN_ITEMACTIVATE ) + { + cheatEditPos = ListView_GetNextItem(cheatListView, -1, LVNI_SELECTED|LVNI_FOCUSED); + cheatsGet(&tempCheat, cheatEditPos); + tempCheat.enabled = !tempCheat.enabled; + switch (tempCheat.type) + { + case 0: // internal + cheatsUpdate(tempCheat.size, tempCheat.hi[0], tempCheat.lo[0], tempCheat.description, tempCheat.enabled, cheatEditPos); + break; + + case 1: // Action Replay + cheatsUpdate_AR(NULL, NULL, tempCheat.enabled, cheatEditPos); + break; + + case 2: // Codebreaker + cheatsUpdate_CB(NULL, NULL, tempCheat.enabled, cheatEditPos); + break; + } + + + if (tempCheat.enabled) + ListView_SetItemText(cheatListView, cheatEditPos, 0, "X") + else + ListView_SetItemText(cheatListView, cheatEditPos, 0, ""); + EnableWindow(GetDlgItem(dialog, IDOK), TRUE); + } + + if ( tmp_msg->code == NM_CLICK ) + { + if (ListView_GetNextItem(cheatListView, -1, LVNI_SELECTED|LVNI_FOCUSED) != -1) + { + EnableWindow(GetDlgItem(dialog, IDC_BEDIT), TRUE); + EnableWindow(GetDlgItem(dialog, IDC_BREMOVE), TRUE); + } + else + { + EnableWindow(GetDlgItem(dialog, IDC_BEDIT), FALSE); + EnableWindow(GetDlgItem(dialog, IDC_BREMOVE), FALSE); + } + } + + return TRUE; + } + return FALSE; + + case WM_COMMAND: + { + switch (LOWORD(wparam)) + { + case IDOK: + if (cheatsSave()) + { + EndDialog(dialog, TRUE); + } + else + MessageBox(dialog, "Can't save cheats to file","Error",MB_OK); + return TRUE; + case IDCANCEL: + EndDialog(dialog, FALSE); + return TRUE; + + case IDC_BADD: + { + searchAddAddress = 0;; + searchAddValue = 0; + searchAddMode = 0; + searchAddFreeze = 1; + if (DialogBox(hAppInst, MAKEINTRESOURCE(IDD_CHEAT_ADD), dialog, (DLGPROC) CheatsAddProc)) + { + LVITEM lvi; + char buf[256]; + + memset(&lvi,0,sizeof(LVITEM)); + lvi.mask = LVIF_TEXT|LVIF_STATE; + lvi.iItem = INT_MAX; + + if (searchAddFreeze) + lvi.pszText= "X"; + else + lvi.pszText= " "; + u32 row = ListView_InsertItem(cheatListView, &lvi); + wsprintf(buf, "0x02%06X", searchAddAddress); + ListView_SetItemText(cheatListView, row, 1, buf); + ltoa(searchAddValue, buf, 10); + ListView_SetItemText(cheatListView, row, 2, buf); + ListView_SetItemText(cheatListView, row, 3, editBuf[2]); + + EnableWindow(GetDlgItem(dialog, IDOK), TRUE); + } + } + return TRUE; + + case IDC_BADD_AR: + { + if (LOWORD(wparam) == IDC_BADD_AR) + { + cheatXXtype = 0; + } + else + if (LOWORD(wparam) == IDC_BADD_CB) + { + cheatXXtype = 1; + } + else + return TRUE; + cheatXXaction = 0; // 0 = add + + if (DialogBox(hAppInst, MAKEINTRESOURCE(IDD_CHEAT_ADD_XX_CODE), dialog, (DLGPROC) CheatsAdd_XX_Proc)) + { + LVITEM lvi; + + memset(&lvi,0,sizeof(LVITEM)); + lvi.mask = LVIF_TEXT|LVIF_STATE; + lvi.iItem = INT_MAX; + + if (tempCheat.enabled) + lvi.pszText= "X"; + else + lvi.pszText= " "; + u32 row = ListView_InsertItem(cheatListView, &lvi); + if (cheatXXtype == 0) + { + ListView_SetItemText(cheatListView, row, 1, "Action"); + ListView_SetItemText(cheatListView, row, 2, "Replay"); + } + else + { + ListView_SetItemText(cheatListView, row, 1, "Code"); + ListView_SetItemText(cheatListView, row, 2, "breaker"); + } + ListView_SetItemText(cheatListView, row, 3, tempCheat.description); + + EnableWindow(GetDlgItem(dialog, IDOK), TRUE); + } + } + return TRUE; + + case IDC_BEDIT: + { + cheatEditPos = ListView_GetNextItem(cheatListView, -1, LVNI_SELECTED|LVNI_FOCUSED); + if (cheatEditPos > cheatsGetSize()) return TRUE; + + cheatsGet(&tempCheat, cheatEditPos); + + switch (tempCheat.type) + { + case 0: // internal + if (DialogBox(hAppInst, MAKEINTRESOURCE(IDD_CHEAT_ADD), dialog, (DLGPROC) CheatsEditProc)) + { + char buf[256]; + cheatsGet(&tempCheat, cheatEditPos); + if (tempCheat.enabled) + ListView_SetItemText(cheatListView, cheatEditPos, 0, "X"); + wsprintf(buf, "0x02%06X", tempCheat.hi[0]); + ListView_SetItemText(cheatListView, cheatEditPos, 1, buf); + ltoa(tempCheat.lo[0], buf, 10); + ListView_SetItemText(cheatListView, cheatEditPos, 2, buf); + ListView_SetItemText(cheatListView, cheatEditPos, 3, tempCheat.description); + EnableWindow(GetDlgItem(dialog, IDOK), TRUE); + } + break; + + case 1: // Action replay + case 2: // Codebreaker + if (tempCheat.type == 1) + cheatXXtype = 0; + else + cheatXXtype = 1; + cheatXXaction = 1; // 1 = edit + + if (DialogBox(hAppInst, MAKEINTRESOURCE(IDD_CHEAT_ADD_XX_CODE), dialog, (DLGPROC) CheatsAdd_XX_Proc)) + { + cheatsGet(&tempCheat, cheatEditPos); + if (tempCheat.enabled) + ListView_SetItemText(cheatListView, cheatEditPos, 0, "X"); + + if (cheatXXtype == 0) + { + ListView_SetItemText(cheatListView, cheatEditPos, 1, "Action"); + ListView_SetItemText(cheatListView, cheatEditPos, 2, "Replay"); + } + else + { + ListView_SetItemText(cheatListView, cheatEditPos, 1, "Code"); + ListView_SetItemText(cheatListView, cheatEditPos, 2, "breaker"); + } + + ListView_SetItemText(cheatListView, cheatEditPos, 3, tempCheat.description); + EnableWindow(GetDlgItem(dialog, IDOK), TRUE); + } + break; + } + } + return TRUE; + + case IDC_BREMOVE: + { + int tmp_pos = ListView_GetNextItem(cheatListView, -1, LVNI_SELECTED|LVNI_FOCUSED); + if (tmp_pos != -1) + { + if (cheatsRemove(tmp_pos)) + { + ListView_DeleteItem(cheatListView, tmp_pos); + EnableWindow(GetDlgItem(dialog, IDOK), TRUE); + } + } + + } + return TRUE; + } + break; + } + } + return FALSE; +} + +void CheatsListDialog(HWND hwnd) +{ + if (!cheatsPush()) return; + memset(&tempCheat, 0, sizeof(CHEATS_LIST)); + u32 res=DialogBox(hAppInst, MAKEINTRESOURCE(IDD_CHEAT_LIST), hwnd, (DLGPROC) CheatsListBox_Proc); + if (res) + { + cheatsSave(); + cheatsStackClear(); + } + else + { + cheatsPop(); + } +} + + +// ================================================================================== Search +BOOL CALLBACK CheatsSearchExactWnd(HWND dialog, UINT msg,WPARAM wparam,LPARAM lparam) +{ + switch(msg) + { + case WM_INITDIALOG: + { + EnableWindow(hBRestart, TRUE); + if (searchNumberResults) + EnableWindow(hBView, TRUE); + else + EnableWindow(hBView, FALSE); + EnableWindow(hBSearch, FALSE); + + SendMessage(GetDlgItem(dialog, IDC_EVALUE), EM_SETLIMITTEXT, 10, 0); + SetWindowText(GetDlgItem(dialog, IDC_STATIC_RANGE), searchRangeText[searchSign][searchSize]); + oldEditProc = (WNDPROC)SetWindowLongPtr(GetDlgItem(dialog, IDC_EVALUE), GWLP_WNDPROC, (LONG)EditValueProc); + char buf[256]; + memset(buf, 0, 256); + ltoa(searchNumberResults, buf, 10); + SetWindowText(GetDlgItem(dialog, IDC_SNUMBER), buf); + SetFocus(GetDlgItem(dialog, IDC_EVALUE)); + break; + } + + case WM_COMMAND: + { + switch (LOWORD(wparam)) + { + case IDC_EVALUE: + { + if (HIWORD(wparam) == EN_UPDATE) + { + char buf[10]; + GetWindowText(GetDlgItem(dialog, IDC_EVALUE), buf, 10); + if (!strlen(buf)) + { + EnableWindow(hBSearch, FALSE); + return TRUE; + } + + u32 val = atol(buf); + if (val > searchRange[searchSize][1]) + { + EnableWindow(hBSearch, FALSE); + return TRUE; + } + EnableWindow(hBSearch, TRUE); + exactVal = val; + } + return TRUE; + } + } + break; + } + } + return FALSE; +} + +BOOL CALLBACK CheatsSearchCompWnd(HWND dialog, UINT msg,WPARAM wparam,LPARAM lparam) +{ + switch(msg) + { + case WM_INITDIALOG: + { + EnableWindow(hBRestart, TRUE); + if (searchNumberResults) + EnableWindow(hBView, TRUE); + else + EnableWindow(hBView, FALSE); + EnableWindow(hBSearch, TRUE); + + CheckDlgButton(dialog, searchCompIDDs[searchComp], BST_CHECKED); + + char buf[256]; + ltoa(searchNumberResults, buf, 10); + SetWindowText(GetDlgItem(dialog, IDC_SNUMBER), buf); + break; + } + + case WM_COMMAND: + { + switch (LOWORD(wparam)) + { + case IDC_RADIO1: searchComp = 0; break; + case IDC_RADIO2: searchComp = 1; break; + case IDC_RADIO3: searchComp = 2; break; + case IDC_RADIO4: searchComp = 3; break; + } + break; + } + } + return FALSE; +} + +BOOL CALLBACK CheatsSearchResultWnd(HWND dialog, UINT msg,WPARAM wparam,LPARAM lparam) +{ + switch(msg) + { + case WM_INITDIALOG: + { + EnableWindow(hBRestart, TRUE); + if (searchNumberResults) + EnableWindow(hBView, TRUE); + else + EnableWindow(hBView, FALSE); + EnableWindow(hBSearch, FALSE); + char buf[256]; + ltoa(searchNumberResults, buf, 10); + SetWindowText(GetDlgItem(dialog, IDC_SNUMBER), buf); + return TRUE; + } + } + return FALSE; +} + +BOOL CALLBACK CheatsSearchViewWnd(HWND dialog, UINT msg,WPARAM wparam,LPARAM lparam) +{ + switch(msg) + { + case WM_INITDIALOG: + { + LV_COLUMN lvColumn; + u32 address = 0; + u32 val = 0; + + searchListView = GetDlgItem(dialog, IDC_LIST); + + ListView_SetExtendedListViewStyle(searchListView, LVS_EX_FULLROWSELECT|LVS_EX_GRIDLINES); + + memset(&lvColumn,0,sizeof(LV_COLUMN)); + lvColumn.mask=LVCF_FMT|LVCF_WIDTH|LVCF_TEXT; + lvColumn.fmt=LVCFMT_LEFT; + lvColumn.cx=94; + lvColumn.pszText="Address"; + ListView_InsertColumn(searchListView, 0, &lvColumn); + lvColumn.cx=130; + lvColumn.pszText="Value"; + ListView_InsertColumn(searchListView, 1, &lvColumn); + + LVITEM lvi; + memset(&lvi,0,sizeof(LVITEM)); + lvi.mask = LVIF_TEXT|LVIF_STATE; + lvi.iItem = INT_MAX; + + cheatSearchGetListReset(); + SendMessage(searchListView, WM_SETREDRAW, (WPARAM)FALSE,0); + while (cheatSearchGetList(&address, &val)) + { + char buf[256]; + wsprintf(buf, "0x02%06X", address); + lvi.pszText= buf; + u32 row = SendMessage(searchListView, LVM_INSERTITEM, 0, (LPARAM)&lvi); + _ltoa(val, buf, 10); + ListView_SetItemText(searchListView, row, 1, buf); + } + SendMessage(searchListView, WM_SETREDRAW, (WPARAM)TRUE,0); + ListView_SetItemState(searchListView,0, LVIS_SELECTED|LVIS_FOCUSED, LVIS_SELECTED|LVIS_FOCUSED); + SetFocus(searchListView); + } + return TRUE; + + case WM_COMMAND: + { + switch (LOWORD(wparam)) + { + case IDCANCEL: + ListView_DeleteAllItems(searchListView); + EndDialog(dialog, FALSE); + return TRUE; + case IDC_BADD: + { + u32 val = 0; + char buf[12]; + u32 pos = ListView_GetNextItem(searchListView, -1, LVNI_SELECTED|LVNI_FOCUSED); + ListView_GetItemText(searchListView, pos, 0, buf, 12); + sscanf_s(buf, "%x", &val); + searchAddAddress = val & 0x00FFFFFF; + ListView_GetItemText(searchListView, pos, 1, buf, 12); + searchAddValue = atol(buf); + searchAddMode = 1; + searchAddSize = searchSize; + DialogBox(hAppInst, MAKEINTRESOURCE(IDD_CHEAT_ADD), dialog, (DLGPROC) CheatsAddProc); + } + return TRUE; + } + } + } + return FALSE; +} + +BOOL CALLBACK CheatsSearchMainWnd(HWND dialog, UINT msg,WPARAM wparam,LPARAM lparam) +{ + switch(msg) + { + case WM_INITDIALOG: + { + CheckDlgButton(dialog, searchSizeIDDs[searchSize], BST_CHECKED); + CheckDlgButton(dialog, searchSignIDDs[searchSign], BST_CHECKED); + CheckDlgButton(dialog, searchTypeIDDs[searchType], BST_CHECKED); + for (int i = 0; i < 4; i++) + SetWindowText(GetDlgItem(dialog, searchRangeIDDs[i]), searchRangeText[searchSign][i]); + EnableWindow(hBRestart, FALSE); + EnableWindow(hBView, FALSE); + EnableWindow(hBSearch, TRUE); + break; + } + + case WM_COMMAND: + { + switch (LOWORD(wparam)) + { + case IDC_RADIO1: // 1 byte + searchSize = 0; + return TRUE; + case IDC_RADIO2: // 2 bytes + searchSize = 1; + return TRUE; + case IDC_RADIO3: // 3 bytes + searchSize = 2; + return TRUE; + case IDC_RADIO4: // 4 bytes + searchSize = 3; + return TRUE; + + case IDC_RADIO5: // unsigned + searchSign = 0; + for (int i = 0; i < 4; i++) + SetWindowText(GetDlgItem(dialog, searchRangeIDDs[i]), searchRangeText[searchSign][i]); + return TRUE; + + case IDC_RADIO6: //signed + searchSign = 1; + for (int i = 0; i < 4; i++) + SetWindowText(GetDlgItem(dialog, searchRangeIDDs[i]), searchRangeText[searchSign][i]); + return TRUE; + + case IDC_RADIO7: // exact value search + searchType = 0; + return TRUE; + + case IDC_RADIO8: // comparative search + searchType = 1; + return TRUE; + } + return TRUE; + } + } + return FALSE; +} + +DLGPROC CheatsSearchSubWnds[2][4] = { + { CheatsSearchMainWnd, CheatsSearchExactWnd, CheatsSearchResultWnd, NULL }, + { CheatsSearchMainWnd, CheatsSearchResultWnd, CheatsSearchCompWnd, CheatsSearchResultWnd } +}; + +//============================================================================== +BOOL CALLBACK CheatsSearchProc(HWND dialog, UINT msg,WPARAM wparam,LPARAM lparam) +{ + switch(msg) + { + case WM_INITDIALOG: + { + hBRestart = GetDlgItem(dialog, IDC_BRESTART); + hBView = GetDlgItem(dialog, IDC_BVIEW); + hBSearch = GetDlgItem(dialog, IDC_BSEARCH); + + searchWnd=CreateDialog(hAppInst, MAKEINTRESOURCE(searchIDDs[searchType][searchStep]), + dialog, (DLGPROC)CheatsSearchSubWnds[searchType][searchStep]); + return TRUE; + } + + case WM_COMMAND: + { + switch (LOWORD(wparam)) + { + case IDOK: + case IDCANCEL: + if (searchWnd) DestroyWindow(searchWnd); + EndDialog(dialog, FALSE); + return TRUE; + + case IDC_BVIEW: + DialogBox(hAppInst, MAKEINTRESOURCE(IDD_CHEAT_SEARCH_VIEW), dialog, (DLGPROC)CheatsSearchViewWnd); + return TRUE; + + case IDC_BSEARCH: + if (searchStep == 0) + cheatsSearchInit(searchType, searchSize, searchSign); + if (searchType == 0) + { + if (searchStep == 1) + searchNumberResults = cheatsSearchValue(exactVal); + } + else + { + if (searchStep == 2) + searchNumberResults = cheatsSearchComp(searchComp); + } + + searchStep++; + if (searchWnd) DestroyWindow(searchWnd); + searchWnd=CreateDialog(hAppInst, MAKEINTRESOURCE(searchIDDs[searchType][searchStep]), + dialog, (DLGPROC)CheatsSearchSubWnds[searchType][searchStep]); + if (searchType == 0) + { + if (searchStep == 2) searchStep = 1; + } + else + { + if (searchStep == 1) searchStep = 2; + if (searchStep == 3) searchStep = 2; + } + return TRUE; + + case IDC_BRESTART: + cheatsSearchClose(); + searchStep = 0; + searchNumberResults = 0; + if (searchWnd) DestroyWindow(searchWnd); + searchWnd=CreateDialog(hAppInst, MAKEINTRESOURCE(searchIDDs[searchType][searchStep]), + dialog, (DLGPROC)CheatsSearchSubWnds[searchType][searchStep]); + return TRUE; + } + break; + } + } + return FALSE; +} + +void CheatsSearchDialog(HWND hwnd) +{ + DialogBox(hAppInst, MAKEINTRESOURCE(IDD_CHEAT_SEARCH), hwnd, (DLGPROC) CheatsSearchProc); +} + +void CheatsSearchReset() +{ + searchType = 0; + searchSize = 0; + searchSign = 0; + searchStep = 0; + searchComp = 0; + searchAddSize = 0; + exactVal = 0; + searchNumberResults = 0; +} diff --git a/desmume/src/windows/cheatsWin.h b/src/windows/cheatsWin.h similarity index 94% rename from desmume/src/windows/cheatsWin.h rename to src/windows/cheatsWin.h index 27cf3a4f5..7dc10bf89 100644 --- a/desmume/src/windows/cheatsWin.h +++ b/src/windows/cheatsWin.h @@ -1,28 +1,28 @@ -/* Copyright (C) 2006 yopyop - yopyop156@ifrance.com - yopyop156.ifrance.com - - Copyright 2009 DeSmuME team - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -*/ - -#include "../common.h" - -extern void CheatsListDialog(HWND hwnd); -extern void CheatsSearchDialog(HWND hwnd); +/* Copyright (C) 2006 yopyop + yopyop156@ifrance.com + yopyop156.ifrance.com + + Copyright 2009 DeSmuME team + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA +*/ + +#include "../common.h" + +extern void CheatsListDialog(HWND hwnd); +extern void CheatsSearchDialog(HWND hwnd); extern void CheatsSearchReset(); \ No newline at end of file diff --git a/desmume/src/windows/colorctrl.cpp b/src/windows/colorctrl.cpp similarity index 96% rename from desmume/src/windows/colorctrl.cpp rename to src/windows/colorctrl.cpp index c7c2358fc..7890edc2e 100644 --- a/desmume/src/windows/colorctrl.cpp +++ b/src/windows/colorctrl.cpp @@ -1,158 +1,158 @@ -/* colorctrl.cpp - this file is part of DeSmuME - * - * Copyright (C) 2007 Acid Burn - * - * This file is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2, or (at your option) - * any later version. - * - * This file is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; see the file COPYING. If not, write to - * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ - -#include "../common.h" -#include -#include "colorctrl.h" - -static char szClassName[] = "DeSmuME_ColorCtrl"; - -LRESULT CALLBACK ColorCtrl_WndProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam); -LRESULT ColorCtrl_OnPaint(ColorCtrl *ccp, WPARAM wParam, LPARAM lParam); -LRESULT ColorCtrl_OnNCCreate(HWND hWnd, WPARAM wParam, LPARAM lParam); -LRESULT ColorCtrl_OnNCDestroy(ColorCtrl *ccp, WPARAM wParam, LPARAM lParam); - -static ColorCtrl* ColorCtrl_Get(HWND hWnd) -{ - return (ColorCtrl*)GetWindowLong(hWnd, 0); -} - -void ColorCtrl_Register() -{ - WNDCLASSEX wc; - - wc.cbSize = sizeof(wc); - wc.lpszClassName = szClassName; - wc.hInstance = GetModuleHandle(0); - wc.lpfnWndProc = ColorCtrl_WndProc; - wc.hCursor = LoadCursor (NULL, IDC_ARROW); - wc.hIcon = 0; - wc.lpszMenuName = 0; - wc.hbrBackground = (HBRUSH)GetSysColorBrush(COLOR_BTNFACE); - wc.style = 0; - wc.cbClsExtra = 0; - wc.cbWndExtra = sizeof(ColorCtrl*); - wc.hIconSm = 0; - - RegisterClassEx(&wc); -} - -HWND ColorCtrl_Create(HWND hParent) -{ - HWND hwndCtrl; - - hwndCtrl = CreateWindowEx( - WS_EX_CLIENTEDGE, // give it a standard border - szClassName, - NULL, - WS_VISIBLE | WS_CHILD, - 0, 0, 16, 16, - hParent, - NULL, GetModuleHandle(0), NULL - ); - - return hwndCtrl; -} - -LRESULT CALLBACK ColorCtrl_WndProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam) -{ - ColorCtrl *pCtrl = ColorCtrl_Get(hwnd); - - switch(msg) - { - case WM_NCCREATE: - return ColorCtrl_OnNCCreate(hwnd, wParam, lParam); - - case WM_NCDESTROY: - ColorCtrl_OnNCDestroy(pCtrl, wParam, lParam); - break; - - case WM_PAINT: - return ColorCtrl_OnPaint(pCtrl, wParam, lParam); - - case WM_ERASEBKGND: - return 1; - - default: - break; - } - - return DefWindowProc(hwnd, msg, wParam, lParam); -} - -LRESULT ColorCtrl_OnNCCreate(HWND hWnd, WPARAM wParam, LPARAM lParam) -{ - // Allocate a new CustCtrl structure for this window. - ColorCtrl* pCtrl = (ColorCtrl*)malloc(sizeof(ColorCtrl)); - - // Failed to allocate, stop window creation. - if(pCtrl == NULL) - return FALSE; - - // Initialize the CustCtrl structure. - pCtrl->hWnd = hWnd; - pCtrl->color = 0; - - // Attach custom structure to this window. - SetWindowLong(hWnd, 0, (LONG)pCtrl); - - // Continue with window creation. - return TRUE; -} - -LRESULT ColorCtrl_OnNCDestroy(ColorCtrl *pCtrl, WPARAM wParam, LPARAM lParam) -{ - free(pCtrl); - return TRUE; -} - -LRESULT ColorCtrl_OnPaint(ColorCtrl *pCtrl, WPARAM wParam, LPARAM lParam) -{ - HDC hdc; - PAINTSTRUCT ps; - RECT rect; - HBRUSH brush; - - // Get a device context for this window - hdc = BeginPaint(pCtrl->hWnd, &ps); - - // Work out where to draw - GetClientRect(pCtrl->hWnd, &rect); - - // Create brush and fill - brush = CreateSolidBrush(pCtrl->color); - FillRect(hdc, &rect, brush); - - // Release the device context - EndPaint(pCtrl->hWnd, &ps); - - // free brush again - DeleteObject(brush); - - return 0; -} - -void ColorCtrl_SetColor(HWND hWnd, COLORREF color) -{ - ColorCtrl *pCtrl = ColorCtrl_Get(hWnd); - - pCtrl->color = color; - InvalidateRect(hWnd, NULL, FALSE); -} +/* colorctrl.cpp - this file is part of DeSmuME + * + * Copyright (C) 2007 Acid Burn + * + * This file is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2, or (at your option) + * any later version. + * + * This file is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; see the file COPYING. If not, write to + * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#include "../common.h" +#include +#include "colorctrl.h" + +static char szClassName[] = "DeSmuME_ColorCtrl"; + +LRESULT CALLBACK ColorCtrl_WndProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam); +LRESULT ColorCtrl_OnPaint(ColorCtrl *ccp, WPARAM wParam, LPARAM lParam); +LRESULT ColorCtrl_OnNCCreate(HWND hWnd, WPARAM wParam, LPARAM lParam); +LRESULT ColorCtrl_OnNCDestroy(ColorCtrl *ccp, WPARAM wParam, LPARAM lParam); + +static ColorCtrl* ColorCtrl_Get(HWND hWnd) +{ + return (ColorCtrl*)GetWindowLong(hWnd, 0); +} + +void ColorCtrl_Register() +{ + WNDCLASSEX wc; + + wc.cbSize = sizeof(wc); + wc.lpszClassName = szClassName; + wc.hInstance = GetModuleHandle(0); + wc.lpfnWndProc = ColorCtrl_WndProc; + wc.hCursor = LoadCursor (NULL, IDC_ARROW); + wc.hIcon = 0; + wc.lpszMenuName = 0; + wc.hbrBackground = (HBRUSH)GetSysColorBrush(COLOR_BTNFACE); + wc.style = 0; + wc.cbClsExtra = 0; + wc.cbWndExtra = sizeof(ColorCtrl*); + wc.hIconSm = 0; + + RegisterClassEx(&wc); +} + +HWND ColorCtrl_Create(HWND hParent) +{ + HWND hwndCtrl; + + hwndCtrl = CreateWindowEx( + WS_EX_CLIENTEDGE, // give it a standard border + szClassName, + NULL, + WS_VISIBLE | WS_CHILD, + 0, 0, 16, 16, + hParent, + NULL, GetModuleHandle(0), NULL + ); + + return hwndCtrl; +} + +LRESULT CALLBACK ColorCtrl_WndProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam) +{ + ColorCtrl *pCtrl = ColorCtrl_Get(hwnd); + + switch(msg) + { + case WM_NCCREATE: + return ColorCtrl_OnNCCreate(hwnd, wParam, lParam); + + case WM_NCDESTROY: + ColorCtrl_OnNCDestroy(pCtrl, wParam, lParam); + break; + + case WM_PAINT: + return ColorCtrl_OnPaint(pCtrl, wParam, lParam); + + case WM_ERASEBKGND: + return 1; + + default: + break; + } + + return DefWindowProc(hwnd, msg, wParam, lParam); +} + +LRESULT ColorCtrl_OnNCCreate(HWND hWnd, WPARAM wParam, LPARAM lParam) +{ + // Allocate a new CustCtrl structure for this window. + ColorCtrl* pCtrl = (ColorCtrl*)malloc(sizeof(ColorCtrl)); + + // Failed to allocate, stop window creation. + if(pCtrl == NULL) + return FALSE; + + // Initialize the CustCtrl structure. + pCtrl->hWnd = hWnd; + pCtrl->color = 0; + + // Attach custom structure to this window. + SetWindowLong(hWnd, 0, (LONG)pCtrl); + + // Continue with window creation. + return TRUE; +} + +LRESULT ColorCtrl_OnNCDestroy(ColorCtrl *pCtrl, WPARAM wParam, LPARAM lParam) +{ + free(pCtrl); + return TRUE; +} + +LRESULT ColorCtrl_OnPaint(ColorCtrl *pCtrl, WPARAM wParam, LPARAM lParam) +{ + HDC hdc; + PAINTSTRUCT ps; + RECT rect; + HBRUSH brush; + + // Get a device context for this window + hdc = BeginPaint(pCtrl->hWnd, &ps); + + // Work out where to draw + GetClientRect(pCtrl->hWnd, &rect); + + // Create brush and fill + brush = CreateSolidBrush(pCtrl->color); + FillRect(hdc, &rect, brush); + + // Release the device context + EndPaint(pCtrl->hWnd, &ps); + + // free brush again + DeleteObject(brush); + + return 0; +} + +void ColorCtrl_SetColor(HWND hWnd, COLORREF color) +{ + ColorCtrl *pCtrl = ColorCtrl_Get(hWnd); + + pCtrl->color = color; + InvalidateRect(hWnd, NULL, FALSE); +} diff --git a/desmume/src/windows/colorctrl.h b/src/windows/colorctrl.h similarity index 94% rename from desmume/src/windows/colorctrl.h rename to src/windows/colorctrl.h index a10aed29a..7cff4060d 100644 --- a/desmume/src/windows/colorctrl.h +++ b/src/windows/colorctrl.h @@ -1,14 +1,14 @@ -#ifndef COLORCTRL_H -#define COLORCTRL_H - -typedef struct -{ - HWND hWnd; - COLORREF color; -} ColorCtrl; - -void ColorCtrl_Register(); -HWND ColorCtrl_Create(HWND hParent); -void ColorCtrl_SetColor(HWND hWnd, COLORREF color); - -#endif // COLORCTRL_H +#ifndef COLORCTRL_H +#define COLORCTRL_H + +typedef struct +{ + HWND hWnd; + COLORREF color; +} ColorCtrl; + +void ColorCtrl_Register(); +HWND ColorCtrl_Create(HWND hParent); +void ColorCtrl_SetColor(HWND hWnd, COLORREF color); + +#endif // COLORCTRL_H diff --git a/desmume/src/windows/config.h b/src/windows/config.h similarity index 92% rename from desmume/src/windows/config.h rename to src/windows/config.h index fbf96dd8e..fc3646704 100644 --- a/desmume/src/windows/config.h +++ b/src/windows/config.h @@ -1,6 +1,6 @@ -#ifndef _CONFIG_H -#define _CONFIG_H - -#include "userconfig.h" - -#endif +#ifndef _CONFIG_H +#define _CONFIG_H + +#include "userconfig.h" + +#endif diff --git a/desmume/src/windows/console.cpp b/src/windows/console.cpp similarity index 99% rename from desmume/src/windows/console.cpp rename to src/windows/console.cpp index f38b30ce3..a5909c6fd 100644 --- a/desmume/src/windows/console.cpp +++ b/src/windows/console.cpp @@ -25,7 +25,7 @@ #include #include #include -#include "version.h" +#include "types.h" ///////////////////////////////////////////////////////////////// Console diff --git a/desmume/src/windows/console.h b/src/windows/console.h similarity index 95% rename from desmume/src/windows/console.h rename to src/windows/console.h index 193eb8ae2..5da99e387 100644 --- a/desmume/src/windows/console.h +++ b/src/windows/console.h @@ -1,41 +1,41 @@ -/* Copyright (C) 2006 yopyop - yopyop156@ifrance.com - yopyop156.ifrance.com - - Copyright 2008 CrazyMax (mtabachenko) - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ -#ifndef _CONSOLE_H_ -#define _CONSOLE_H_ - -#ifdef BETA_VERSION - -#include "../common.h" -#include -#include "debug.h" - -#else - -#define pringlog(...) - -#endif - -void OpenConsole(); -void CloseConsole(); - +/* Copyright (C) 2006 yopyop + yopyop156@ifrance.com + yopyop156.ifrance.com + + Copyright 2008 CrazyMax (mtabachenko) + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ +#ifndef _CONSOLE_H_ +#define _CONSOLE_H_ + +#ifdef BETA_VERSION + +#include "../common.h" +#include +#include "debug.h" + +#else + +#define pringlog(...) + +#endif + +void OpenConsole(); +void CloseConsole(); + #endif \ No newline at end of file diff --git a/desmume/src/windows/defaultconfig/userconfig.h b/src/windows/defaultconfig/userconfig.h similarity index 65% rename from desmume/src/windows/defaultconfig/userconfig.h rename to src/windows/defaultconfig/userconfig.h index c0b89c83c..be8adbedc 100644 --- a/desmume/src/windows/defaultconfig/userconfig.h +++ b/src/windows/defaultconfig/userconfig.h @@ -5,11 +5,7 @@ //to customize your build, place a customized copy in the userconfig directory //(alongside this defaultconfig directory) -//disables SSE and SSE2 optimizations (better change it in the vc++ codegen options too) -//note that you may have to use this if your compiler doesn't support standard SSE intrinsics -//#define NOSSE -//#define NOSSE2 - +//#define NOSSE2 //disables SSE2 optimizations (better change it in the vc++ codegen options too) //#define DEVELOPER //enables dev+ features //#define GDB_STUB //enables the gdb stub. for some reason this is separate from dev+ for now diff --git a/desmume/src/windows/directx/DxErr8.lib b/src/windows/directx/DxErr8.lib similarity index 100% rename from desmume/src/windows/directx/DxErr8.lib rename to src/windows/directx/DxErr8.lib diff --git a/desmume/src/windows/directx/ddraw.h b/src/windows/directx/ddraw.h similarity index 97% rename from desmume/src/windows/directx/ddraw.h rename to src/windows/directx/ddraw.h index e66314bfc..0f204f844 100644 --- a/desmume/src/windows/directx/ddraw.h +++ b/src/windows/directx/ddraw.h @@ -1,5792 +1,5792 @@ -/*==========================================================================; - * - * Copyright (C) Microsoft Corporation. All Rights Reserved. - * - * File: ddraw.h - * Content: DirectDraw include file - * - ***************************************************************************/ - -#ifndef __DDRAW_INCLUDED__ -#define __DDRAW_INCLUDED__ - -//Disable the nameless union warning when building internally -#undef ENABLE_NAMELESS_UNION_PRAGMA -#ifdef DIRECTX_REDIST -#define ENABLE_NAMELESS_UNION_PRAGMA -#endif - -#ifdef ENABLE_NAMELESS_UNION_PRAGMA -#pragma warning(disable:4201) -#endif - -/* - * If you wish an application built against the newest version of DirectDraw - * to run against an older DirectDraw run time then define DIRECTDRAW_VERSION - * to be the earlies version of DirectDraw you wish to run against. For, - * example if you wish an application to run against a DX 3 runtime define - * DIRECTDRAW_VERSION to be 0x0300. - */ -#ifndef DIRECTDRAW_VERSION -#define DIRECTDRAW_VERSION 0x0700 -#endif /* DIRECTDRAW_VERSION */ - -#if defined( _WIN32 ) && !defined( _NO_COM ) -#define COM_NO_WINDOWS_H -#include -#else -#define IUnknown void -#if !defined( NT_BUILD_ENVIRONMENT ) && !defined(WINNT) - #define CO_E_NOTINITIALIZED 0x800401F0L -#endif -#endif - -#define _FACDD 0x876 -#define MAKE_DDHRESULT( code ) MAKE_HRESULT( 1, _FACDD, code ) - -#ifdef __cplusplus -extern "C" { -#endif - -// -// For compilers that don't support nameless unions, do a -// -// #define NONAMELESSUNION -// -// before #include -// -#ifndef DUMMYUNIONNAMEN -#if defined(__cplusplus) || !defined(NONAMELESSUNION) -#define DUMMYUNIONNAMEN(n) -#else -#define DUMMYUNIONNAMEN(n) u##n -#endif -#endif - -#ifndef MAKEFOURCC - #define MAKEFOURCC(ch0, ch1, ch2, ch3) \ - ((DWORD)(BYTE)(ch0) | ((DWORD)(BYTE)(ch1) << 8) | \ - ((DWORD)(BYTE)(ch2) << 16) | ((DWORD)(BYTE)(ch3) << 24 )) -#endif //defined(MAKEFOURCC) - -/* - * FOURCC codes for DX compressed-texture pixel formats - */ -#define FOURCC_DXT1 (MAKEFOURCC('D','X','T','1')) -#define FOURCC_DXT2 (MAKEFOURCC('D','X','T','2')) -#define FOURCC_DXT3 (MAKEFOURCC('D','X','T','3')) -#define FOURCC_DXT4 (MAKEFOURCC('D','X','T','4')) -#define FOURCC_DXT5 (MAKEFOURCC('D','X','T','5')) - -/* - * GUIDS used by DirectDraw objects - */ -#if defined( _WIN32 ) && !defined( _NO_COM ) - -DEFINE_GUID( CLSID_DirectDraw, 0xD7B70EE0,0x4340,0x11CF,0xB0,0x63,0x00,0x20,0xAF,0xC2,0xCD,0x35 ); -DEFINE_GUID( CLSID_DirectDraw7, 0x3c305196,0x50db,0x11d3,0x9c,0xfe,0x00,0xc0,0x4f,0xd9,0x30,0xc5 ); -DEFINE_GUID( CLSID_DirectDrawClipper, 0x593817A0,0x7DB3,0x11CF,0xA2,0xDE,0x00,0xAA,0x00,0xb9,0x33,0x56 ); -DEFINE_GUID( IID_IDirectDraw, 0x6C14DB80,0xA733,0x11CE,0xA5,0x21,0x00,0x20,0xAF,0x0B,0xE5,0x60 ); -DEFINE_GUID( IID_IDirectDraw2, 0xB3A6F3E0,0x2B43,0x11CF,0xA2,0xDE,0x00,0xAA,0x00,0xB9,0x33,0x56 ); -DEFINE_GUID( IID_IDirectDraw4, 0x9c59509a,0x39bd,0x11d1,0x8c,0x4a,0x00,0xc0,0x4f,0xd9,0x30,0xc5 ); -DEFINE_GUID( IID_IDirectDraw7, 0x15e65ec0,0x3b9c,0x11d2,0xb9,0x2f,0x00,0x60,0x97,0x97,0xea,0x5b ); -DEFINE_GUID( IID_IDirectDrawSurface, 0x6C14DB81,0xA733,0x11CE,0xA5,0x21,0x00,0x20,0xAF,0x0B,0xE5,0x60 ); -DEFINE_GUID( IID_IDirectDrawSurface2, 0x57805885,0x6eec,0x11cf,0x94,0x41,0xa8,0x23,0x03,0xc1,0x0e,0x27 ); -DEFINE_GUID( IID_IDirectDrawSurface3, 0xDA044E00,0x69B2,0x11D0,0xA1,0xD5,0x00,0xAA,0x00,0xB8,0xDF,0xBB ); -DEFINE_GUID( IID_IDirectDrawSurface4, 0x0B2B8630,0xAD35,0x11D0,0x8E,0xA6,0x00,0x60,0x97,0x97,0xEA,0x5B ); -DEFINE_GUID( IID_IDirectDrawSurface7, 0x06675a80,0x3b9b,0x11d2,0xb9,0x2f,0x00,0x60,0x97,0x97,0xea,0x5b ); -DEFINE_GUID( IID_IDirectDrawPalette, 0x6C14DB84,0xA733,0x11CE,0xA5,0x21,0x00,0x20,0xAF,0x0B,0xE5,0x60 ); -DEFINE_GUID( IID_IDirectDrawClipper, 0x6C14DB85,0xA733,0x11CE,0xA5,0x21,0x00,0x20,0xAF,0x0B,0xE5,0x60 ); -DEFINE_GUID( IID_IDirectDrawColorControl, 0x4B9F0EE0,0x0D7E,0x11D0,0x9B,0x06,0x00,0xA0,0xC9,0x03,0xA3,0xB8 ); -DEFINE_GUID( IID_IDirectDrawGammaControl, 0x69C11C3E,0xB46B,0x11D1,0xAD,0x7A,0x00,0xC0,0x4F,0xC2,0x9B,0x4E ); - -#endif - -/*============================================================================ - * - * DirectDraw Structures - * - * Various structures used to invoke DirectDraw. - * - *==========================================================================*/ - -struct IDirectDraw; -struct IDirectDrawSurface; -struct IDirectDrawPalette; -struct IDirectDrawClipper; - -typedef struct IDirectDraw FAR *LPDIRECTDRAW; -typedef struct IDirectDraw2 FAR *LPDIRECTDRAW2; -typedef struct IDirectDraw4 FAR *LPDIRECTDRAW4; -typedef struct IDirectDraw7 FAR *LPDIRECTDRAW7; -typedef struct IDirectDrawSurface FAR *LPDIRECTDRAWSURFACE; -typedef struct IDirectDrawSurface2 FAR *LPDIRECTDRAWSURFACE2; -typedef struct IDirectDrawSurface3 FAR *LPDIRECTDRAWSURFACE3; -typedef struct IDirectDrawSurface4 FAR *LPDIRECTDRAWSURFACE4; -typedef struct IDirectDrawSurface7 FAR *LPDIRECTDRAWSURFACE7; -typedef struct IDirectDrawPalette FAR *LPDIRECTDRAWPALETTE; -typedef struct IDirectDrawClipper FAR *LPDIRECTDRAWCLIPPER; -typedef struct IDirectDrawColorControl FAR *LPDIRECTDRAWCOLORCONTROL; -typedef struct IDirectDrawGammaControl FAR *LPDIRECTDRAWGAMMACONTROL; - -typedef struct _DDFXROP FAR *LPDDFXROP; -typedef struct _DDSURFACEDESC FAR *LPDDSURFACEDESC; -typedef struct _DDSURFACEDESC2 FAR *LPDDSURFACEDESC2; -typedef struct _DDCOLORCONTROL FAR *LPDDCOLORCONTROL; - -/* - * API's - */ -#if (defined (WIN32) || defined( _WIN32 ) ) && !defined( _NO_COM ) -//#if defined( _WIN32 ) && !defined( _NO_ENUM ) - typedef BOOL (FAR PASCAL * LPDDENUMCALLBACKA)(GUID FAR *, LPSTR, LPSTR, LPVOID); - typedef BOOL (FAR PASCAL * LPDDENUMCALLBACKW)(GUID FAR *, LPWSTR, LPWSTR, LPVOID); - extern HRESULT WINAPI DirectDrawEnumerateW( LPDDENUMCALLBACKW lpCallback, LPVOID lpContext ); - extern HRESULT WINAPI DirectDrawEnumerateA( LPDDENUMCALLBACKA lpCallback, LPVOID lpContext ); - /* - * Protect against old SDKs - */ - #if !defined(HMONITOR_DECLARED) && (WINVER < 0x0500) - #define HMONITOR_DECLARED - DECLARE_HANDLE(HMONITOR); - #endif - typedef BOOL (FAR PASCAL * LPDDENUMCALLBACKEXA)(GUID FAR *, LPSTR, LPSTR, LPVOID, HMONITOR); - typedef BOOL (FAR PASCAL * LPDDENUMCALLBACKEXW)(GUID FAR *, LPWSTR, LPWSTR, LPVOID, HMONITOR); - extern HRESULT WINAPI DirectDrawEnumerateExW( LPDDENUMCALLBACKEXW lpCallback, LPVOID lpContext, DWORD dwFlags); - extern HRESULT WINAPI DirectDrawEnumerateExA( LPDDENUMCALLBACKEXA lpCallback, LPVOID lpContext, DWORD dwFlags); - typedef HRESULT (WINAPI * LPDIRECTDRAWENUMERATEEXA)( LPDDENUMCALLBACKEXA lpCallback, LPVOID lpContext, DWORD dwFlags); - typedef HRESULT (WINAPI * LPDIRECTDRAWENUMERATEEXW)( LPDDENUMCALLBACKEXW lpCallback, LPVOID lpContext, DWORD dwFlags); - - #ifdef UNICODE - typedef LPDDENUMCALLBACKW LPDDENUMCALLBACK; - #define DirectDrawEnumerate DirectDrawEnumerateW - typedef LPDDENUMCALLBACKEXW LPDDENUMCALLBACKEX; - typedef LPDIRECTDRAWENUMERATEEXW LPDIRECTDRAWENUMERATEEX; - #define DirectDrawEnumerateEx DirectDrawEnumerateExW - #else - typedef LPDDENUMCALLBACKA LPDDENUMCALLBACK; - #define DirectDrawEnumerate DirectDrawEnumerateA - typedef LPDDENUMCALLBACKEXA LPDDENUMCALLBACKEX; - typedef LPDIRECTDRAWENUMERATEEXA LPDIRECTDRAWENUMERATEEX; - #define DirectDrawEnumerateEx DirectDrawEnumerateExA - #endif - extern HRESULT WINAPI DirectDrawCreate( GUID FAR *lpGUID, LPDIRECTDRAW FAR *lplpDD, IUnknown FAR *pUnkOuter ); - extern HRESULT WINAPI DirectDrawCreateEx( GUID FAR * lpGuid, LPVOID *lplpDD, REFIID iid,IUnknown FAR *pUnkOuter ); - extern HRESULT WINAPI DirectDrawCreateClipper( DWORD dwFlags, LPDIRECTDRAWCLIPPER FAR *lplpDDClipper, IUnknown FAR *pUnkOuter ); -#endif -/* - * Flags for DirectDrawEnumerateEx - * DirectDrawEnumerateEx supercedes DirectDrawEnumerate. You must use GetProcAddress to - * obtain a function pointer (of type LPDIRECTDRAWENUMERATEEX) to DirectDrawEnumerateEx. - * By default, only the primary display device is enumerated. - * DirectDrawEnumerate is equivalent to DirectDrawEnumerate(,,DDENUM_NONDISPLAYDEVICES) - */ - -/* - * This flag causes enumeration of any GDI display devices which are part of - * the Windows Desktop - */ -#define DDENUM_ATTACHEDSECONDARYDEVICES 0x00000001L - -/* - * This flag causes enumeration of any GDI display devices which are not - * part of the Windows Desktop - */ -#define DDENUM_DETACHEDSECONDARYDEVICES 0x00000002L - -/* - * This flag causes enumeration of non-display devices - */ -#define DDENUM_NONDISPLAYDEVICES 0x00000004L - - -#define REGSTR_KEY_DDHW_DESCRIPTION "Description" -#define REGSTR_KEY_DDHW_DRIVERNAME "DriverName" -#define REGSTR_PATH_DDHW "Hardware\\DirectDrawDrivers" - -#define DDCREATE_HARDWAREONLY 0x00000001l -#define DDCREATE_EMULATIONONLY 0x00000002l - -#if defined(WINNT) || !defined(WIN32) -typedef long HRESULT; -#endif - -//#ifndef WINNT -typedef HRESULT (FAR PASCAL * LPDDENUMMODESCALLBACK)(LPDDSURFACEDESC, LPVOID); -typedef HRESULT (FAR PASCAL * LPDDENUMMODESCALLBACK2)(LPDDSURFACEDESC2, LPVOID); -typedef HRESULT (FAR PASCAL * LPDDENUMSURFACESCALLBACK)(LPDIRECTDRAWSURFACE, LPDDSURFACEDESC, LPVOID); -typedef HRESULT (FAR PASCAL * LPDDENUMSURFACESCALLBACK2)(LPDIRECTDRAWSURFACE4, LPDDSURFACEDESC2, LPVOID); -typedef HRESULT (FAR PASCAL * LPDDENUMSURFACESCALLBACK7)(LPDIRECTDRAWSURFACE7, LPDDSURFACEDESC2, LPVOID); -//#endif - -/* - * Generic pixel format with 8-bit RGB and alpha components - */ -typedef struct _DDARGB -{ - BYTE blue; - BYTE green; - BYTE red; - BYTE alpha; -} DDARGB; - -typedef DDARGB FAR *LPDDARGB; - -/* - * This version of the structure remains for backwards source compatibility. - * The DDARGB structure is the one that should be used for all DirectDraw APIs. - */ -typedef struct _DDRGBA -{ - BYTE red; - BYTE green; - BYTE blue; - BYTE alpha; -} DDRGBA; - -typedef DDRGBA FAR *LPDDRGBA; - - -/* - * DDCOLORKEY - */ -typedef struct _DDCOLORKEY -{ - DWORD dwColorSpaceLowValue; // low boundary of color space that is to - // be treated as Color Key, inclusive - DWORD dwColorSpaceHighValue; // high boundary of color space that is - // to be treated as Color Key, inclusive -} DDCOLORKEY; - -typedef DDCOLORKEY FAR* LPDDCOLORKEY; - -/* - * DDBLTFX - * Used to pass override information to the DIRECTDRAWSURFACE callback Blt. - */ -typedef struct _DDBLTFX -{ - DWORD dwSize; // size of structure - DWORD dwDDFX; // FX operations - DWORD dwROP; // Win32 raster operations - DWORD dwDDROP; // Raster operations new for DirectDraw - DWORD dwRotationAngle; // Rotation angle for blt - DWORD dwZBufferOpCode; // ZBuffer compares - DWORD dwZBufferLow; // Low limit of Z buffer - DWORD dwZBufferHigh; // High limit of Z buffer - DWORD dwZBufferBaseDest; // Destination base value - DWORD dwZDestConstBitDepth; // Bit depth used to specify Z constant for destination - union - { - DWORD dwZDestConst; // Constant to use as Z buffer for dest - LPDIRECTDRAWSURFACE lpDDSZBufferDest; // Surface to use as Z buffer for dest - } DUMMYUNIONNAMEN(1); - DWORD dwZSrcConstBitDepth; // Bit depth used to specify Z constant for source - union - { - DWORD dwZSrcConst; // Constant to use as Z buffer for src - LPDIRECTDRAWSURFACE lpDDSZBufferSrc; // Surface to use as Z buffer for src - } DUMMYUNIONNAMEN(2); - DWORD dwAlphaEdgeBlendBitDepth; // Bit depth used to specify constant for alpha edge blend - DWORD dwAlphaEdgeBlend; // Alpha for edge blending - DWORD dwReserved; - DWORD dwAlphaDestConstBitDepth; // Bit depth used to specify alpha constant for destination - union - { - DWORD dwAlphaDestConst; // Constant to use as Alpha Channel - LPDIRECTDRAWSURFACE lpDDSAlphaDest; // Surface to use as Alpha Channel - } DUMMYUNIONNAMEN(3); - DWORD dwAlphaSrcConstBitDepth; // Bit depth used to specify alpha constant for source - union - { - DWORD dwAlphaSrcConst; // Constant to use as Alpha Channel - LPDIRECTDRAWSURFACE lpDDSAlphaSrc; // Surface to use as Alpha Channel - } DUMMYUNIONNAMEN(4); - union - { - DWORD dwFillColor; // color in RGB or Palettized - DWORD dwFillDepth; // depth value for z-buffer - DWORD dwFillPixel; // pixel value for RGBA or RGBZ - LPDIRECTDRAWSURFACE lpDDSPattern; // Surface to use as pattern - } DUMMYUNIONNAMEN(5); - DDCOLORKEY ddckDestColorkey; // DestColorkey override - DDCOLORKEY ddckSrcColorkey; // SrcColorkey override -} DDBLTFX; - -typedef DDBLTFX FAR* LPDDBLTFX; - - - -/* - * DDSCAPS - */ -typedef struct _DDSCAPS -{ - DWORD dwCaps; // capabilities of surface wanted -} DDSCAPS; - -typedef DDSCAPS FAR* LPDDSCAPS; - - -/* - * DDOSCAPS - */ -typedef struct _DDOSCAPS -{ - DWORD dwCaps; // capabilities of surface wanted -} DDOSCAPS; - -typedef DDOSCAPS FAR* LPDDOSCAPS; - -/* - * This structure is used internally by DirectDraw. - */ -typedef struct _DDSCAPSEX -{ - DWORD dwCaps2; - DWORD dwCaps3; - union - { - DWORD dwCaps4; - DWORD dwVolumeDepth; - } DUMMYUNIONNAMEN(1); -} DDSCAPSEX, FAR * LPDDSCAPSEX; - -/* - * DDSCAPS2 - */ -typedef struct _DDSCAPS2 -{ - DWORD dwCaps; // capabilities of surface wanted - DWORD dwCaps2; - DWORD dwCaps3; - union - { - DWORD dwCaps4; - DWORD dwVolumeDepth; - } DUMMYUNIONNAMEN(1); -} DDSCAPS2; - -typedef DDSCAPS2 FAR* LPDDSCAPS2; - -/* - * DDCAPS - */ -#define DD_ROP_SPACE (256/32) // space required to store ROP array -/* - * NOTE: Our choosen structure number scheme is to append a single digit to - * the end of the structure giving the version that structure is associated - * with. - */ - -/* - * This structure represents the DDCAPS structure released in DirectDraw 1.0. It is used internally - * by DirectDraw to interpret caps passed into ddraw by drivers written prior to the release of DirectDraw 2.0. - * New applications should use the DDCAPS structure defined below. - */ -typedef struct _DDCAPS_DX1 -{ - DWORD dwSize; // size of the DDDRIVERCAPS structure - DWORD dwCaps; // driver specific capabilities - DWORD dwCaps2; // more driver specific capabilites - DWORD dwCKeyCaps; // color key capabilities of the surface - DWORD dwFXCaps; // driver specific stretching and effects capabilites - DWORD dwFXAlphaCaps; // alpha driver specific capabilities - DWORD dwPalCaps; // palette capabilities - DWORD dwSVCaps; // stereo vision capabilities - DWORD dwAlphaBltConstBitDepths; // DDBD_2,4,8 - DWORD dwAlphaBltPixelBitDepths; // DDBD_1,2,4,8 - DWORD dwAlphaBltSurfaceBitDepths; // DDBD_1,2,4,8 - DWORD dwAlphaOverlayConstBitDepths; // DDBD_2,4,8 - DWORD dwAlphaOverlayPixelBitDepths; // DDBD_1,2,4,8 - DWORD dwAlphaOverlaySurfaceBitDepths; // DDBD_1,2,4,8 - DWORD dwZBufferBitDepths; // DDBD_8,16,24,32 - DWORD dwVidMemTotal; // total amount of video memory - DWORD dwVidMemFree; // amount of free video memory - DWORD dwMaxVisibleOverlays; // maximum number of visible overlays - DWORD dwCurrVisibleOverlays; // current number of visible overlays - DWORD dwNumFourCCCodes; // number of four cc codes - DWORD dwAlignBoundarySrc; // source rectangle alignment - DWORD dwAlignSizeSrc; // source rectangle byte size - DWORD dwAlignBoundaryDest; // dest rectangle alignment - DWORD dwAlignSizeDest; // dest rectangle byte size - DWORD dwAlignStrideAlign; // stride alignment - DWORD dwRops[DD_ROP_SPACE]; // ROPS supported - DDSCAPS ddsCaps; // DDSCAPS structure has all the general capabilities - DWORD dwMinOverlayStretch; // minimum overlay stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 - DWORD dwMaxOverlayStretch; // maximum overlay stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 - DWORD dwMinLiveVideoStretch; // OBSOLETE! This field remains for compatability reasons only - DWORD dwMaxLiveVideoStretch; // OBSOLETE! This field remains for compatability reasons only - DWORD dwMinHwCodecStretch; // OBSOLETE! This field remains for compatability reasons only - DWORD dwMaxHwCodecStretch; // OBSOLETE! This field remains for compatability reasons only - DWORD dwReserved1; // reserved - DWORD dwReserved2; // reserved - DWORD dwReserved3; // reserved -} DDCAPS_DX1; - -typedef DDCAPS_DX1 FAR* LPDDCAPS_DX1; - -/* - * This structure is the DDCAPS structure as it was in version 2 and 3 of Direct X. - * It is present for back compatability. - */ -typedef struct _DDCAPS_DX3 -{ - DWORD dwSize; // size of the DDDRIVERCAPS structure - DWORD dwCaps; // driver specific capabilities - DWORD dwCaps2; // more driver specific capabilites - DWORD dwCKeyCaps; // color key capabilities of the surface - DWORD dwFXCaps; // driver specific stretching and effects capabilites - DWORD dwFXAlphaCaps; // alpha driver specific capabilities - DWORD dwPalCaps; // palette capabilities - DWORD dwSVCaps; // stereo vision capabilities - DWORD dwAlphaBltConstBitDepths; // DDBD_2,4,8 - DWORD dwAlphaBltPixelBitDepths; // DDBD_1,2,4,8 - DWORD dwAlphaBltSurfaceBitDepths; // DDBD_1,2,4,8 - DWORD dwAlphaOverlayConstBitDepths; // DDBD_2,4,8 - DWORD dwAlphaOverlayPixelBitDepths; // DDBD_1,2,4,8 - DWORD dwAlphaOverlaySurfaceBitDepths; // DDBD_1,2,4,8 - DWORD dwZBufferBitDepths; // DDBD_8,16,24,32 - DWORD dwVidMemTotal; // total amount of video memory - DWORD dwVidMemFree; // amount of free video memory - DWORD dwMaxVisibleOverlays; // maximum number of visible overlays - DWORD dwCurrVisibleOverlays; // current number of visible overlays - DWORD dwNumFourCCCodes; // number of four cc codes - DWORD dwAlignBoundarySrc; // source rectangle alignment - DWORD dwAlignSizeSrc; // source rectangle byte size - DWORD dwAlignBoundaryDest; // dest rectangle alignment - DWORD dwAlignSizeDest; // dest rectangle byte size - DWORD dwAlignStrideAlign; // stride alignment - DWORD dwRops[DD_ROP_SPACE]; // ROPS supported - DDSCAPS ddsCaps; // DDSCAPS structure has all the general capabilities - DWORD dwMinOverlayStretch; // minimum overlay stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 - DWORD dwMaxOverlayStretch; // maximum overlay stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 - DWORD dwMinLiveVideoStretch; // minimum live video stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 - DWORD dwMaxLiveVideoStretch; // maximum live video stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 - DWORD dwMinHwCodecStretch; // minimum hardware codec stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 - DWORD dwMaxHwCodecStretch; // maximum hardware codec stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 - DWORD dwReserved1; // reserved - DWORD dwReserved2; // reserved - DWORD dwReserved3; // reserved - DWORD dwSVBCaps; // driver specific capabilities for System->Vmem blts - DWORD dwSVBCKeyCaps; // driver color key capabilities for System->Vmem blts - DWORD dwSVBFXCaps; // driver FX capabilities for System->Vmem blts - DWORD dwSVBRops[DD_ROP_SPACE];// ROPS supported for System->Vmem blts - DWORD dwVSBCaps; // driver specific capabilities for Vmem->System blts - DWORD dwVSBCKeyCaps; // driver color key capabilities for Vmem->System blts - DWORD dwVSBFXCaps; // driver FX capabilities for Vmem->System blts - DWORD dwVSBRops[DD_ROP_SPACE];// ROPS supported for Vmem->System blts - DWORD dwSSBCaps; // driver specific capabilities for System->System blts - DWORD dwSSBCKeyCaps; // driver color key capabilities for System->System blts - DWORD dwSSBFXCaps; // driver FX capabilities for System->System blts - DWORD dwSSBRops[DD_ROP_SPACE];// ROPS supported for System->System blts - DWORD dwReserved4; // reserved - DWORD dwReserved5; // reserved - DWORD dwReserved6; // reserved -} DDCAPS_DX3; -typedef DDCAPS_DX3 FAR* LPDDCAPS_DX3; - -/* - * This structure is the DDCAPS structure as it was in version 5 of Direct X. - * It is present for back compatability. - */ -typedef struct _DDCAPS_DX5 -{ -/* 0*/ DWORD dwSize; // size of the DDDRIVERCAPS structure -/* 4*/ DWORD dwCaps; // driver specific capabilities -/* 8*/ DWORD dwCaps2; // more driver specific capabilites -/* c*/ DWORD dwCKeyCaps; // color key capabilities of the surface -/* 10*/ DWORD dwFXCaps; // driver specific stretching and effects capabilites -/* 14*/ DWORD dwFXAlphaCaps; // alpha driver specific capabilities -/* 18*/ DWORD dwPalCaps; // palette capabilities -/* 1c*/ DWORD dwSVCaps; // stereo vision capabilities -/* 20*/ DWORD dwAlphaBltConstBitDepths; // DDBD_2,4,8 -/* 24*/ DWORD dwAlphaBltPixelBitDepths; // DDBD_1,2,4,8 -/* 28*/ DWORD dwAlphaBltSurfaceBitDepths; // DDBD_1,2,4,8 -/* 2c*/ DWORD dwAlphaOverlayConstBitDepths; // DDBD_2,4,8 -/* 30*/ DWORD dwAlphaOverlayPixelBitDepths; // DDBD_1,2,4,8 -/* 34*/ DWORD dwAlphaOverlaySurfaceBitDepths; // DDBD_1,2,4,8 -/* 38*/ DWORD dwZBufferBitDepths; // DDBD_8,16,24,32 -/* 3c*/ DWORD dwVidMemTotal; // total amount of video memory -/* 40*/ DWORD dwVidMemFree; // amount of free video memory -/* 44*/ DWORD dwMaxVisibleOverlays; // maximum number of visible overlays -/* 48*/ DWORD dwCurrVisibleOverlays; // current number of visible overlays -/* 4c*/ DWORD dwNumFourCCCodes; // number of four cc codes -/* 50*/ DWORD dwAlignBoundarySrc; // source rectangle alignment -/* 54*/ DWORD dwAlignSizeSrc; // source rectangle byte size -/* 58*/ DWORD dwAlignBoundaryDest; // dest rectangle alignment -/* 5c*/ DWORD dwAlignSizeDest; // dest rectangle byte size -/* 60*/ DWORD dwAlignStrideAlign; // stride alignment -/* 64*/ DWORD dwRops[DD_ROP_SPACE]; // ROPS supported -/* 84*/ DDSCAPS ddsCaps; // DDSCAPS structure has all the general capabilities -/* 88*/ DWORD dwMinOverlayStretch; // minimum overlay stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 -/* 8c*/ DWORD dwMaxOverlayStretch; // maximum overlay stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 -/* 90*/ DWORD dwMinLiveVideoStretch; // minimum live video stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 -/* 94*/ DWORD dwMaxLiveVideoStretch; // maximum live video stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 -/* 98*/ DWORD dwMinHwCodecStretch; // minimum hardware codec stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 -/* 9c*/ DWORD dwMaxHwCodecStretch; // maximum hardware codec stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 -/* a0*/ DWORD dwReserved1; // reserved -/* a4*/ DWORD dwReserved2; // reserved -/* a8*/ DWORD dwReserved3; // reserved -/* ac*/ DWORD dwSVBCaps; // driver specific capabilities for System->Vmem blts -/* b0*/ DWORD dwSVBCKeyCaps; // driver color key capabilities for System->Vmem blts -/* b4*/ DWORD dwSVBFXCaps; // driver FX capabilities for System->Vmem blts -/* b8*/ DWORD dwSVBRops[DD_ROP_SPACE];// ROPS supported for System->Vmem blts -/* d8*/ DWORD dwVSBCaps; // driver specific capabilities for Vmem->System blts -/* dc*/ DWORD dwVSBCKeyCaps; // driver color key capabilities for Vmem->System blts -/* e0*/ DWORD dwVSBFXCaps; // driver FX capabilities for Vmem->System blts -/* e4*/ DWORD dwVSBRops[DD_ROP_SPACE];// ROPS supported for Vmem->System blts -/*104*/ DWORD dwSSBCaps; // driver specific capabilities for System->System blts -/*108*/ DWORD dwSSBCKeyCaps; // driver color key capabilities for System->System blts -/*10c*/ DWORD dwSSBFXCaps; // driver FX capabilities for System->System blts -/*110*/ DWORD dwSSBRops[DD_ROP_SPACE];// ROPS supported for System->System blts -// Members added for DX5: -/*130*/ DWORD dwMaxVideoPorts; // maximum number of usable video ports -/*134*/ DWORD dwCurrVideoPorts; // current number of video ports used -/*138*/ DWORD dwSVBCaps2; // more driver specific capabilities for System->Vmem blts -/*13c*/ DWORD dwNLVBCaps; // driver specific capabilities for non-local->local vidmem blts -/*140*/ DWORD dwNLVBCaps2; // more driver specific capabilities non-local->local vidmem blts -/*144*/ DWORD dwNLVBCKeyCaps; // driver color key capabilities for non-local->local vidmem blts -/*148*/ DWORD dwNLVBFXCaps; // driver FX capabilities for non-local->local blts -/*14c*/ DWORD dwNLVBRops[DD_ROP_SPACE]; // ROPS supported for non-local->local blts -} DDCAPS_DX5; -typedef DDCAPS_DX5 FAR* LPDDCAPS_DX5; - -typedef struct _DDCAPS_DX6 -{ -/* 0*/ DWORD dwSize; // size of the DDDRIVERCAPS structure -/* 4*/ DWORD dwCaps; // driver specific capabilities -/* 8*/ DWORD dwCaps2; // more driver specific capabilites -/* c*/ DWORD dwCKeyCaps; // color key capabilities of the surface -/* 10*/ DWORD dwFXCaps; // driver specific stretching and effects capabilites -/* 14*/ DWORD dwFXAlphaCaps; // alpha caps -/* 18*/ DWORD dwPalCaps; // palette capabilities -/* 1c*/ DWORD dwSVCaps; // stereo vision capabilities -/* 20*/ DWORD dwAlphaBltConstBitDepths; // DDBD_2,4,8 -/* 24*/ DWORD dwAlphaBltPixelBitDepths; // DDBD_1,2,4,8 -/* 28*/ DWORD dwAlphaBltSurfaceBitDepths; // DDBD_1,2,4,8 -/* 2c*/ DWORD dwAlphaOverlayConstBitDepths; // DDBD_2,4,8 -/* 30*/ DWORD dwAlphaOverlayPixelBitDepths; // DDBD_1,2,4,8 -/* 34*/ DWORD dwAlphaOverlaySurfaceBitDepths; // DDBD_1,2,4,8 -/* 38*/ DWORD dwZBufferBitDepths; // DDBD_8,16,24,32 -/* 3c*/ DWORD dwVidMemTotal; // total amount of video memory -/* 40*/ DWORD dwVidMemFree; // amount of free video memory -/* 44*/ DWORD dwMaxVisibleOverlays; // maximum number of visible overlays -/* 48*/ DWORD dwCurrVisibleOverlays; // current number of visible overlays -/* 4c*/ DWORD dwNumFourCCCodes; // number of four cc codes -/* 50*/ DWORD dwAlignBoundarySrc; // source rectangle alignment -/* 54*/ DWORD dwAlignSizeSrc; // source rectangle byte size -/* 58*/ DWORD dwAlignBoundaryDest; // dest rectangle alignment -/* 5c*/ DWORD dwAlignSizeDest; // dest rectangle byte size -/* 60*/ DWORD dwAlignStrideAlign; // stride alignment -/* 64*/ DWORD dwRops[DD_ROP_SPACE]; // ROPS supported -/* 84*/ DDSCAPS ddsOldCaps; // Was DDSCAPS ddsCaps. ddsCaps is of type DDSCAPS2 for DX6 -/* 88*/ DWORD dwMinOverlayStretch; // minimum overlay stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 -/* 8c*/ DWORD dwMaxOverlayStretch; // maximum overlay stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 -/* 90*/ DWORD dwMinLiveVideoStretch; // minimum live video stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 -/* 94*/ DWORD dwMaxLiveVideoStretch; // maximum live video stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 -/* 98*/ DWORD dwMinHwCodecStretch; // minimum hardware codec stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 -/* 9c*/ DWORD dwMaxHwCodecStretch; // maximum hardware codec stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 -/* a0*/ DWORD dwReserved1; // reserved -/* a4*/ DWORD dwReserved2; // reserved -/* a8*/ DWORD dwReserved3; // reserved -/* ac*/ DWORD dwSVBCaps; // driver specific capabilities for System->Vmem blts -/* b0*/ DWORD dwSVBCKeyCaps; // driver color key capabilities for System->Vmem blts -/* b4*/ DWORD dwSVBFXCaps; // driver FX capabilities for System->Vmem blts -/* b8*/ DWORD dwSVBRops[DD_ROP_SPACE];// ROPS supported for System->Vmem blts -/* d8*/ DWORD dwVSBCaps; // driver specific capabilities for Vmem->System blts -/* dc*/ DWORD dwVSBCKeyCaps; // driver color key capabilities for Vmem->System blts -/* e0*/ DWORD dwVSBFXCaps; // driver FX capabilities for Vmem->System blts -/* e4*/ DWORD dwVSBRops[DD_ROP_SPACE];// ROPS supported for Vmem->System blts -/*104*/ DWORD dwSSBCaps; // driver specific capabilities for System->System blts -/*108*/ DWORD dwSSBCKeyCaps; // driver color key capabilities for System->System blts -/*10c*/ DWORD dwSSBFXCaps; // driver FX capabilities for System->System blts -/*110*/ DWORD dwSSBRops[DD_ROP_SPACE];// ROPS supported for System->System blts -/*130*/ DWORD dwMaxVideoPorts; // maximum number of usable video ports -/*134*/ DWORD dwCurrVideoPorts; // current number of video ports used -/*138*/ DWORD dwSVBCaps2; // more driver specific capabilities for System->Vmem blts -/*13c*/ DWORD dwNLVBCaps; // driver specific capabilities for non-local->local vidmem blts -/*140*/ DWORD dwNLVBCaps2; // more driver specific capabilities non-local->local vidmem blts -/*144*/ DWORD dwNLVBCKeyCaps; // driver color key capabilities for non-local->local vidmem blts -/*148*/ DWORD dwNLVBFXCaps; // driver FX capabilities for non-local->local blts -/*14c*/ DWORD dwNLVBRops[DD_ROP_SPACE]; // ROPS supported for non-local->local blts -// Members added for DX6 release -/*16c*/ DDSCAPS2 ddsCaps; // Surface Caps -} DDCAPS_DX6; -typedef DDCAPS_DX6 FAR* LPDDCAPS_DX6; - -typedef struct _DDCAPS_DX7 -{ -/* 0*/ DWORD dwSize; // size of the DDDRIVERCAPS structure -/* 4*/ DWORD dwCaps; // driver specific capabilities -/* 8*/ DWORD dwCaps2; // more driver specific capabilites -/* c*/ DWORD dwCKeyCaps; // color key capabilities of the surface -/* 10*/ DWORD dwFXCaps; // driver specific stretching and effects capabilites -/* 14*/ DWORD dwFXAlphaCaps; // alpha driver specific capabilities -/* 18*/ DWORD dwPalCaps; // palette capabilities -/* 1c*/ DWORD dwSVCaps; // stereo vision capabilities -/* 20*/ DWORD dwAlphaBltConstBitDepths; // DDBD_2,4,8 -/* 24*/ DWORD dwAlphaBltPixelBitDepths; // DDBD_1,2,4,8 -/* 28*/ DWORD dwAlphaBltSurfaceBitDepths; // DDBD_1,2,4,8 -/* 2c*/ DWORD dwAlphaOverlayConstBitDepths; // DDBD_2,4,8 -/* 30*/ DWORD dwAlphaOverlayPixelBitDepths; // DDBD_1,2,4,8 -/* 34*/ DWORD dwAlphaOverlaySurfaceBitDepths; // DDBD_1,2,4,8 -/* 38*/ DWORD dwZBufferBitDepths; // DDBD_8,16,24,32 -/* 3c*/ DWORD dwVidMemTotal; // total amount of video memory -/* 40*/ DWORD dwVidMemFree; // amount of free video memory -/* 44*/ DWORD dwMaxVisibleOverlays; // maximum number of visible overlays -/* 48*/ DWORD dwCurrVisibleOverlays; // current number of visible overlays -/* 4c*/ DWORD dwNumFourCCCodes; // number of four cc codes -/* 50*/ DWORD dwAlignBoundarySrc; // source rectangle alignment -/* 54*/ DWORD dwAlignSizeSrc; // source rectangle byte size -/* 58*/ DWORD dwAlignBoundaryDest; // dest rectangle alignment -/* 5c*/ DWORD dwAlignSizeDest; // dest rectangle byte size -/* 60*/ DWORD dwAlignStrideAlign; // stride alignment -/* 64*/ DWORD dwRops[DD_ROP_SPACE]; // ROPS supported -/* 84*/ DDSCAPS ddsOldCaps; // Was DDSCAPS ddsCaps. ddsCaps is of type DDSCAPS2 for DX6 -/* 88*/ DWORD dwMinOverlayStretch; // minimum overlay stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 -/* 8c*/ DWORD dwMaxOverlayStretch; // maximum overlay stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 -/* 90*/ DWORD dwMinLiveVideoStretch; // minimum live video stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 -/* 94*/ DWORD dwMaxLiveVideoStretch; // maximum live video stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 -/* 98*/ DWORD dwMinHwCodecStretch; // minimum hardware codec stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 -/* 9c*/ DWORD dwMaxHwCodecStretch; // maximum hardware codec stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 -/* a0*/ DWORD dwReserved1; // reserved -/* a4*/ DWORD dwReserved2; // reserved -/* a8*/ DWORD dwReserved3; // reserved -/* ac*/ DWORD dwSVBCaps; // driver specific capabilities for System->Vmem blts -/* b0*/ DWORD dwSVBCKeyCaps; // driver color key capabilities for System->Vmem blts -/* b4*/ DWORD dwSVBFXCaps; // driver FX capabilities for System->Vmem blts -/* b8*/ DWORD dwSVBRops[DD_ROP_SPACE];// ROPS supported for System->Vmem blts -/* d8*/ DWORD dwVSBCaps; // driver specific capabilities for Vmem->System blts -/* dc*/ DWORD dwVSBCKeyCaps; // driver color key capabilities for Vmem->System blts -/* e0*/ DWORD dwVSBFXCaps; // driver FX capabilities for Vmem->System blts -/* e4*/ DWORD dwVSBRops[DD_ROP_SPACE];// ROPS supported for Vmem->System blts -/*104*/ DWORD dwSSBCaps; // driver specific capabilities for System->System blts -/*108*/ DWORD dwSSBCKeyCaps; // driver color key capabilities for System->System blts -/*10c*/ DWORD dwSSBFXCaps; // driver FX capabilities for System->System blts -/*110*/ DWORD dwSSBRops[DD_ROP_SPACE];// ROPS supported for System->System blts -/*130*/ DWORD dwMaxVideoPorts; // maximum number of usable video ports -/*134*/ DWORD dwCurrVideoPorts; // current number of video ports used -/*138*/ DWORD dwSVBCaps2; // more driver specific capabilities for System->Vmem blts -/*13c*/ DWORD dwNLVBCaps; // driver specific capabilities for non-local->local vidmem blts -/*140*/ DWORD dwNLVBCaps2; // more driver specific capabilities non-local->local vidmem blts -/*144*/ DWORD dwNLVBCKeyCaps; // driver color key capabilities for non-local->local vidmem blts -/*148*/ DWORD dwNLVBFXCaps; // driver FX capabilities for non-local->local blts -/*14c*/ DWORD dwNLVBRops[DD_ROP_SPACE]; // ROPS supported for non-local->local blts -// Members added for DX6 release -/*16c*/ DDSCAPS2 ddsCaps; // Surface Caps -} DDCAPS_DX7; -typedef DDCAPS_DX7 FAR* LPDDCAPS_DX7; - - -#if DIRECTDRAW_VERSION <= 0x300 - typedef DDCAPS_DX3 DDCAPS; -#elif DIRECTDRAW_VERSION <= 0x500 - typedef DDCAPS_DX5 DDCAPS; -#elif DIRECTDRAW_VERSION <= 0x600 - typedef DDCAPS_DX6 DDCAPS; -#else - typedef DDCAPS_DX7 DDCAPS; -#endif - -typedef DDCAPS FAR* LPDDCAPS; - - - -/* - * DDPIXELFORMAT - */ -typedef struct _DDPIXELFORMAT -{ - DWORD dwSize; // size of structure - DWORD dwFlags; // pixel format flags - DWORD dwFourCC; // (FOURCC code) - union - { - DWORD dwRGBBitCount; // how many bits per pixel - DWORD dwYUVBitCount; // how many bits per pixel - DWORD dwZBufferBitDepth; // how many total bits/pixel in z buffer (including any stencil bits) - DWORD dwAlphaBitDepth; // how many bits for alpha channels - DWORD dwLuminanceBitCount; // how many bits per pixel - DWORD dwBumpBitCount; // how many bits per "buxel", total - DWORD dwPrivateFormatBitCount;// Bits per pixel of private driver formats. Only valid in texture - // format list and if DDPF_D3DFORMAT is set - } DUMMYUNIONNAMEN(1); - union - { - DWORD dwRBitMask; // mask for red bit - DWORD dwYBitMask; // mask for Y bits - DWORD dwStencilBitDepth; // how many stencil bits (note: dwZBufferBitDepth-dwStencilBitDepth is total Z-only bits) - DWORD dwLuminanceBitMask; // mask for luminance bits - DWORD dwBumpDuBitMask; // mask for bump map U delta bits - DWORD dwOperations; // DDPF_D3DFORMAT Operations - } DUMMYUNIONNAMEN(2); - union - { - DWORD dwGBitMask; // mask for green bits - DWORD dwUBitMask; // mask for U bits - DWORD dwZBitMask; // mask for Z bits - DWORD dwBumpDvBitMask; // mask for bump map V delta bits - struct - { - WORD wFlipMSTypes; // Multisample methods supported via flip for this D3DFORMAT - WORD wBltMSTypes; // Multisample methods supported via blt for this D3DFORMAT - } MultiSampleCaps; - - } DUMMYUNIONNAMEN(3); - union - { - DWORD dwBBitMask; // mask for blue bits - DWORD dwVBitMask; // mask for V bits - DWORD dwStencilBitMask; // mask for stencil bits - DWORD dwBumpLuminanceBitMask; // mask for luminance in bump map - } DUMMYUNIONNAMEN(4); - union - { - DWORD dwRGBAlphaBitMask; // mask for alpha channel - DWORD dwYUVAlphaBitMask; // mask for alpha channel - DWORD dwLuminanceAlphaBitMask;// mask for alpha channel - DWORD dwRGBZBitMask; // mask for Z channel - DWORD dwYUVZBitMask; // mask for Z channel - } DUMMYUNIONNAMEN(5); -} DDPIXELFORMAT; - -typedef DDPIXELFORMAT FAR* LPDDPIXELFORMAT; - -/* - * DDOVERLAYFX - */ -typedef struct _DDOVERLAYFX -{ - DWORD dwSize; // size of structure - DWORD dwAlphaEdgeBlendBitDepth; // Bit depth used to specify constant for alpha edge blend - DWORD dwAlphaEdgeBlend; // Constant to use as alpha for edge blend - DWORD dwReserved; - DWORD dwAlphaDestConstBitDepth; // Bit depth used to specify alpha constant for destination - union - { - DWORD dwAlphaDestConst; // Constant to use as alpha channel for dest - LPDIRECTDRAWSURFACE lpDDSAlphaDest; // Surface to use as alpha channel for dest - } DUMMYUNIONNAMEN(1); - DWORD dwAlphaSrcConstBitDepth; // Bit depth used to specify alpha constant for source - union - { - DWORD dwAlphaSrcConst; // Constant to use as alpha channel for src - LPDIRECTDRAWSURFACE lpDDSAlphaSrc; // Surface to use as alpha channel for src - } DUMMYUNIONNAMEN(2); - DDCOLORKEY dckDestColorkey; // DestColorkey override - DDCOLORKEY dckSrcColorkey; // DestColorkey override - DWORD dwDDFX; // Overlay FX - DWORD dwFlags; // flags -} DDOVERLAYFX; - -typedef DDOVERLAYFX FAR *LPDDOVERLAYFX; - - -/* - * DDBLTBATCH: BltBatch entry structure - */ -typedef struct _DDBLTBATCH -{ - LPRECT lprDest; - LPDIRECTDRAWSURFACE lpDDSSrc; - LPRECT lprSrc; - DWORD dwFlags; - LPDDBLTFX lpDDBltFx; -} DDBLTBATCH; - -typedef DDBLTBATCH FAR * LPDDBLTBATCH; - - -/* - * DDGAMMARAMP - */ -typedef struct _DDGAMMARAMP -{ - WORD red[256]; - WORD green[256]; - WORD blue[256]; -} DDGAMMARAMP; -typedef DDGAMMARAMP FAR * LPDDGAMMARAMP; - -/* - * This is the structure within which DirectDraw returns data about the current graphics driver and chipset - */ - -#define MAX_DDDEVICEID_STRING 512 - -typedef struct tagDDDEVICEIDENTIFIER -{ - /* - * These elements are for presentation to the user only. They should not be used to identify particular - * drivers, since this is unreliable and many different strings may be associated with the same - * device, and the same driver from different vendors. - */ - char szDriver[MAX_DDDEVICEID_STRING]; - char szDescription[MAX_DDDEVICEID_STRING]; - - /* - * This element is the version of the DirectDraw/3D driver. It is legal to do <, > comparisons - * on the whole 64 bits. Caution should be exercised if you use this element to identify problematic - * drivers. It is recommended that guidDeviceIdentifier is used for this purpose. - * - * This version has the form: - * wProduct = HIWORD(liDriverVersion.HighPart) - * wVersion = LOWORD(liDriverVersion.HighPart) - * wSubVersion = HIWORD(liDriverVersion.LowPart) - * wBuild = LOWORD(liDriverVersion.LowPart) - */ -#ifdef _WIN32 - LARGE_INTEGER liDriverVersion; /* Defined for applications and other 32 bit components */ -#else - DWORD dwDriverVersionLowPart; /* Defined for 16 bit driver components */ - DWORD dwDriverVersionHighPart; -#endif - - - /* - * These elements can be used to identify particular chipsets. Use with extreme caution. - * dwVendorId Identifies the manufacturer. May be zero if unknown. - * dwDeviceId Identifies the type of chipset. May be zero if unknown. - * dwSubSysId Identifies the subsystem, typically this means the particular board. May be zero if unknown. - * dwRevision Identifies the revision level of the chipset. May be zero if unknown. - */ - DWORD dwVendorId; - DWORD dwDeviceId; - DWORD dwSubSysId; - DWORD dwRevision; - - /* - * This element can be used to check changes in driver/chipset. This GUID is a unique identifier for the - * driver/chipset pair. Use this element if you wish to track changes to the driver/chipset in order to - * reprofile the graphics subsystem. - * This element can also be used to identify particular problematic drivers. - */ - GUID guidDeviceIdentifier; -} DDDEVICEIDENTIFIER, * LPDDDEVICEIDENTIFIER; - -typedef struct tagDDDEVICEIDENTIFIER2 -{ - /* - * These elements are for presentation to the user only. They should not be used to identify particular - * drivers, since this is unreliable and many different strings may be associated with the same - * device, and the same driver from different vendors. - */ - char szDriver[MAX_DDDEVICEID_STRING]; - char szDescription[MAX_DDDEVICEID_STRING]; - - /* - * This element is the version of the DirectDraw/3D driver. It is legal to do <, > comparisons - * on the whole 64 bits. Caution should be exercised if you use this element to identify problematic - * drivers. It is recommended that guidDeviceIdentifier is used for this purpose. - * - * This version has the form: - * wProduct = HIWORD(liDriverVersion.HighPart) - * wVersion = LOWORD(liDriverVersion.HighPart) - * wSubVersion = HIWORD(liDriverVersion.LowPart) - * wBuild = LOWORD(liDriverVersion.LowPart) - */ -#ifdef _WIN32 - LARGE_INTEGER liDriverVersion; /* Defined for applications and other 32 bit components */ -#else - DWORD dwDriverVersionLowPart; /* Defined for 16 bit driver components */ - DWORD dwDriverVersionHighPart; -#endif - - - /* - * These elements can be used to identify particular chipsets. Use with extreme caution. - * dwVendorId Identifies the manufacturer. May be zero if unknown. - * dwDeviceId Identifies the type of chipset. May be zero if unknown. - * dwSubSysId Identifies the subsystem, typically this means the particular board. May be zero if unknown. - * dwRevision Identifies the revision level of the chipset. May be zero if unknown. - */ - DWORD dwVendorId; - DWORD dwDeviceId; - DWORD dwSubSysId; - DWORD dwRevision; - - /* - * This element can be used to check changes in driver/chipset. This GUID is a unique identifier for the - * driver/chipset pair. Use this element if you wish to track changes to the driver/chipset in order to - * reprofile the graphics subsystem. - * This element can also be used to identify particular problematic drivers. - */ - GUID guidDeviceIdentifier; - - /* - * This element is used to determine the Windows Hardware Quality Lab (WHQL) - * certification level for this driver/device pair. - */ - DWORD dwWHQLLevel; - -} DDDEVICEIDENTIFIER2, * LPDDDEVICEIDENTIFIER2; - -/* - * Flags for the IDirectDraw4::GetDeviceIdentifier method - */ - -/* - * This flag causes GetDeviceIdentifier to return information about the host (typically 2D) adapter in a system equipped - * with a stacked secondary 3D adapter. Such an adapter appears to the application as if it were part of the - * host adapter, but is typically physcially located on a separate card. The stacked secondary's information is - * returned when GetDeviceIdentifier's dwFlags field is zero, since this most accurately reflects the qualities - * of the DirectDraw object involved. - */ -#define DDGDI_GETHOSTIDENTIFIER 0x00000001L - -/* - * Macros for interpretting DDEVICEIDENTIFIER2.dwWHQLLevel - */ -#define GET_WHQL_YEAR( dwWHQLLevel ) \ - ( (dwWHQLLevel) / 0x10000 ) -#define GET_WHQL_MONTH( dwWHQLLevel ) \ - ( ( (dwWHQLLevel) / 0x100 ) & 0x00ff ) -#define GET_WHQL_DAY( dwWHQLLevel ) \ - ( (dwWHQLLevel) & 0xff ) - - -/* - * callbacks - */ -typedef DWORD (FAR PASCAL *LPCLIPPERCALLBACK)(LPDIRECTDRAWCLIPPER lpDDClipper, HWND hWnd, DWORD code, LPVOID lpContext ); -#ifdef STREAMING -typedef DWORD (FAR PASCAL *LPSURFACESTREAMINGCALLBACK)(DWORD); -#endif - - -/* - * INTERACES FOLLOW: - * IDirectDraw - * IDirectDrawClipper - * IDirectDrawPalette - * IDirectDrawSurface - */ - -/* - * IDirectDraw - */ -#if defined( _WIN32 ) && !defined( _NO_COM ) -#undef INTERFACE -#define INTERFACE IDirectDraw -DECLARE_INTERFACE_( IDirectDraw, IUnknown ) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID FAR * ppvObj) PURE; - STDMETHOD_(ULONG,AddRef) (THIS) PURE; - STDMETHOD_(ULONG,Release) (THIS) PURE; - /*** IDirectDraw methods ***/ - STDMETHOD(Compact)(THIS) PURE; - STDMETHOD(CreateClipper)(THIS_ DWORD, LPDIRECTDRAWCLIPPER FAR*, IUnknown FAR * ) PURE; - STDMETHOD(CreatePalette)(THIS_ DWORD, LPPALETTEENTRY, LPDIRECTDRAWPALETTE FAR*, IUnknown FAR * ) PURE; - STDMETHOD(CreateSurface)(THIS_ LPDDSURFACEDESC, LPDIRECTDRAWSURFACE FAR *, IUnknown FAR *) PURE; - STDMETHOD(DuplicateSurface)( THIS_ LPDIRECTDRAWSURFACE, LPDIRECTDRAWSURFACE FAR * ) PURE; - STDMETHOD(EnumDisplayModes)( THIS_ DWORD, LPDDSURFACEDESC, LPVOID, LPDDENUMMODESCALLBACK ) PURE; - STDMETHOD(EnumSurfaces)(THIS_ DWORD, LPDDSURFACEDESC, LPVOID,LPDDENUMSURFACESCALLBACK ) PURE; - STDMETHOD(FlipToGDISurface)(THIS) PURE; - STDMETHOD(GetCaps)( THIS_ LPDDCAPS, LPDDCAPS) PURE; - STDMETHOD(GetDisplayMode)( THIS_ LPDDSURFACEDESC) PURE; - STDMETHOD(GetFourCCCodes)(THIS_ LPDWORD, LPDWORD ) PURE; - STDMETHOD(GetGDISurface)(THIS_ LPDIRECTDRAWSURFACE FAR *) PURE; - STDMETHOD(GetMonitorFrequency)(THIS_ LPDWORD) PURE; - STDMETHOD(GetScanLine)(THIS_ LPDWORD) PURE; - STDMETHOD(GetVerticalBlankStatus)(THIS_ LPBOOL ) PURE; - STDMETHOD(Initialize)(THIS_ GUID FAR *) PURE; - STDMETHOD(RestoreDisplayMode)(THIS) PURE; - STDMETHOD(SetCooperativeLevel)(THIS_ HWND, DWORD) PURE; - STDMETHOD(SetDisplayMode)(THIS_ DWORD, DWORD,DWORD) PURE; - STDMETHOD(WaitForVerticalBlank)(THIS_ DWORD, HANDLE ) PURE; -}; - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectDraw_QueryInterface(p, a, b) (p)->lpVtbl->QueryInterface(p, a, b) -#define IDirectDraw_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirectDraw_Release(p) (p)->lpVtbl->Release(p) -#define IDirectDraw_Compact(p) (p)->lpVtbl->Compact(p) -#define IDirectDraw_CreateClipper(p, a, b, c) (p)->lpVtbl->CreateClipper(p, a, b, c) -#define IDirectDraw_CreatePalette(p, a, b, c, d) (p)->lpVtbl->CreatePalette(p, a, b, c, d) -#define IDirectDraw_CreateSurface(p, a, b, c) (p)->lpVtbl->CreateSurface(p, a, b, c) -#define IDirectDraw_DuplicateSurface(p, a, b) (p)->lpVtbl->DuplicateSurface(p, a, b) -#define IDirectDraw_EnumDisplayModes(p, a, b, c, d) (p)->lpVtbl->EnumDisplayModes(p, a, b, c, d) -#define IDirectDraw_EnumSurfaces(p, a, b, c, d) (p)->lpVtbl->EnumSurfaces(p, a, b, c, d) -#define IDirectDraw_FlipToGDISurface(p) (p)->lpVtbl->FlipToGDISurface(p) -#define IDirectDraw_GetCaps(p, a, b) (p)->lpVtbl->GetCaps(p, a, b) -#define IDirectDraw_GetDisplayMode(p, a) (p)->lpVtbl->GetDisplayMode(p, a) -#define IDirectDraw_GetFourCCCodes(p, a, b) (p)->lpVtbl->GetFourCCCodes(p, a, b) -#define IDirectDraw_GetGDISurface(p, a) (p)->lpVtbl->GetGDISurface(p, a) -#define IDirectDraw_GetMonitorFrequency(p, a) (p)->lpVtbl->GetMonitorFrequency(p, a) -#define IDirectDraw_GetScanLine(p, a) (p)->lpVtbl->GetScanLine(p, a) -#define IDirectDraw_GetVerticalBlankStatus(p, a) (p)->lpVtbl->GetVerticalBlankStatus(p, a) -#define IDirectDraw_Initialize(p, a) (p)->lpVtbl->Initialize(p, a) -#define IDirectDraw_RestoreDisplayMode(p) (p)->lpVtbl->RestoreDisplayMode(p) -#define IDirectDraw_SetCooperativeLevel(p, a, b) (p)->lpVtbl->SetCooperativeLevel(p, a, b) -#define IDirectDraw_SetDisplayMode(p, a, b, c) (p)->lpVtbl->SetDisplayMode(p, a, b, c) -#define IDirectDraw_WaitForVerticalBlank(p, a, b) (p)->lpVtbl->WaitForVerticalBlank(p, a, b) -#else -#define IDirectDraw_QueryInterface(p, a, b) (p)->QueryInterface(a, b) -#define IDirectDraw_AddRef(p) (p)->AddRef() -#define IDirectDraw_Release(p) (p)->Release() -#define IDirectDraw_Compact(p) (p)->Compact() -#define IDirectDraw_CreateClipper(p, a, b, c) (p)->CreateClipper(a, b, c) -#define IDirectDraw_CreatePalette(p, a, b, c, d) (p)->CreatePalette(a, b, c, d) -#define IDirectDraw_CreateSurface(p, a, b, c) (p)->CreateSurface(a, b, c) -#define IDirectDraw_DuplicateSurface(p, a, b) (p)->DuplicateSurface(a, b) -#define IDirectDraw_EnumDisplayModes(p, a, b, c, d) (p)->EnumDisplayModes(a, b, c, d) -#define IDirectDraw_EnumSurfaces(p, a, b, c, d) (p)->EnumSurfaces(a, b, c, d) -#define IDirectDraw_FlipToGDISurface(p) (p)->FlipToGDISurface() -#define IDirectDraw_GetCaps(p, a, b) (p)->GetCaps(a, b) -#define IDirectDraw_GetDisplayMode(p, a) (p)->GetDisplayMode(a) -#define IDirectDraw_GetFourCCCodes(p, a, b) (p)->GetFourCCCodes(a, b) -#define IDirectDraw_GetGDISurface(p, a) (p)->GetGDISurface(a) -#define IDirectDraw_GetMonitorFrequency(p, a) (p)->GetMonitorFrequency(a) -#define IDirectDraw_GetScanLine(p, a) (p)->GetScanLine(a) -#define IDirectDraw_GetVerticalBlankStatus(p, a) (p)->GetVerticalBlankStatus(a) -#define IDirectDraw_Initialize(p, a) (p)->Initialize(a) -#define IDirectDraw_RestoreDisplayMode(p) (p)->RestoreDisplayMode() -#define IDirectDraw_SetCooperativeLevel(p, a, b) (p)->SetCooperativeLevel(a, b) -#define IDirectDraw_SetDisplayMode(p, a, b, c) (p)->SetDisplayMode(a, b, c) -#define IDirectDraw_WaitForVerticalBlank(p, a, b) (p)->WaitForVerticalBlank(a, b) -#endif - -#endif - -#if defined( _WIN32 ) && !defined( _NO_COM ) -#undef INTERFACE -#define INTERFACE IDirectDraw2 -DECLARE_INTERFACE_( IDirectDraw2, IUnknown ) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID FAR * ppvObj) PURE; - STDMETHOD_(ULONG,AddRef) (THIS) PURE; - STDMETHOD_(ULONG,Release) (THIS) PURE; - /*** IDirectDraw methods ***/ - STDMETHOD(Compact)(THIS) PURE; - STDMETHOD(CreateClipper)(THIS_ DWORD, LPDIRECTDRAWCLIPPER FAR*, IUnknown FAR * ) PURE; - STDMETHOD(CreatePalette)(THIS_ DWORD, LPPALETTEENTRY, LPDIRECTDRAWPALETTE FAR*, IUnknown FAR * ) PURE; - STDMETHOD(CreateSurface)(THIS_ LPDDSURFACEDESC, LPDIRECTDRAWSURFACE FAR *, IUnknown FAR *) PURE; - STDMETHOD(DuplicateSurface)( THIS_ LPDIRECTDRAWSURFACE, LPDIRECTDRAWSURFACE FAR * ) PURE; - STDMETHOD(EnumDisplayModes)( THIS_ DWORD, LPDDSURFACEDESC, LPVOID, LPDDENUMMODESCALLBACK ) PURE; - STDMETHOD(EnumSurfaces)(THIS_ DWORD, LPDDSURFACEDESC, LPVOID,LPDDENUMSURFACESCALLBACK ) PURE; - STDMETHOD(FlipToGDISurface)(THIS) PURE; - STDMETHOD(GetCaps)( THIS_ LPDDCAPS, LPDDCAPS) PURE; - STDMETHOD(GetDisplayMode)( THIS_ LPDDSURFACEDESC) PURE; - STDMETHOD(GetFourCCCodes)(THIS_ LPDWORD, LPDWORD ) PURE; - STDMETHOD(GetGDISurface)(THIS_ LPDIRECTDRAWSURFACE FAR *) PURE; - STDMETHOD(GetMonitorFrequency)(THIS_ LPDWORD) PURE; - STDMETHOD(GetScanLine)(THIS_ LPDWORD) PURE; - STDMETHOD(GetVerticalBlankStatus)(THIS_ LPBOOL ) PURE; - STDMETHOD(Initialize)(THIS_ GUID FAR *) PURE; - STDMETHOD(RestoreDisplayMode)(THIS) PURE; - STDMETHOD(SetCooperativeLevel)(THIS_ HWND, DWORD) PURE; - STDMETHOD(SetDisplayMode)(THIS_ DWORD, DWORD,DWORD, DWORD, DWORD) PURE; - STDMETHOD(WaitForVerticalBlank)(THIS_ DWORD, HANDLE ) PURE; - /*** Added in the v2 interface ***/ - STDMETHOD(GetAvailableVidMem)(THIS_ LPDDSCAPS, LPDWORD, LPDWORD) PURE; -}; -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectDraw2_QueryInterface(p, a, b) (p)->lpVtbl->QueryInterface(p, a, b) -#define IDirectDraw2_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirectDraw2_Release(p) (p)->lpVtbl->Release(p) -#define IDirectDraw2_Compact(p) (p)->lpVtbl->Compact(p) -#define IDirectDraw2_CreateClipper(p, a, b, c) (p)->lpVtbl->CreateClipper(p, a, b, c) -#define IDirectDraw2_CreatePalette(p, a, b, c, d) (p)->lpVtbl->CreatePalette(p, a, b, c, d) -#define IDirectDraw2_CreateSurface(p, a, b, c) (p)->lpVtbl->CreateSurface(p, a, b, c) -#define IDirectDraw2_DuplicateSurface(p, a, b) (p)->lpVtbl->DuplicateSurface(p, a, b) -#define IDirectDraw2_EnumDisplayModes(p, a, b, c, d) (p)->lpVtbl->EnumDisplayModes(p, a, b, c, d) -#define IDirectDraw2_EnumSurfaces(p, a, b, c, d) (p)->lpVtbl->EnumSurfaces(p, a, b, c, d) -#define IDirectDraw2_FlipToGDISurface(p) (p)->lpVtbl->FlipToGDISurface(p) -#define IDirectDraw2_GetCaps(p, a, b) (p)->lpVtbl->GetCaps(p, a, b) -#define IDirectDraw2_GetDisplayMode(p, a) (p)->lpVtbl->GetDisplayMode(p, a) -#define IDirectDraw2_GetFourCCCodes(p, a, b) (p)->lpVtbl->GetFourCCCodes(p, a, b) -#define IDirectDraw2_GetGDISurface(p, a) (p)->lpVtbl->GetGDISurface(p, a) -#define IDirectDraw2_GetMonitorFrequency(p, a) (p)->lpVtbl->GetMonitorFrequency(p, a) -#define IDirectDraw2_GetScanLine(p, a) (p)->lpVtbl->GetScanLine(p, a) -#define IDirectDraw2_GetVerticalBlankStatus(p, a) (p)->lpVtbl->GetVerticalBlankStatus(p, a) -#define IDirectDraw2_Initialize(p, a) (p)->lpVtbl->Initialize(p, a) -#define IDirectDraw2_RestoreDisplayMode(p) (p)->lpVtbl->RestoreDisplayMode(p) -#define IDirectDraw2_SetCooperativeLevel(p, a, b) (p)->lpVtbl->SetCooperativeLevel(p, a, b) -#define IDirectDraw2_SetDisplayMode(p, a, b, c, d, e) (p)->lpVtbl->SetDisplayMode(p, a, b, c, d, e) -#define IDirectDraw2_WaitForVerticalBlank(p, a, b) (p)->lpVtbl->WaitForVerticalBlank(p, a, b) -#define IDirectDraw2_GetAvailableVidMem(p, a, b, c) (p)->lpVtbl->GetAvailableVidMem(p, a, b, c) -#else -#define IDirectDraw2_QueryInterface(p, a, b) (p)->QueryInterface(a, b) -#define IDirectDraw2_AddRef(p) (p)->AddRef() -#define IDirectDraw2_Release(p) (p)->Release() -#define IDirectDraw2_Compact(p) (p)->Compact() -#define IDirectDraw2_CreateClipper(p, a, b, c) (p)->CreateClipper(a, b, c) -#define IDirectDraw2_CreatePalette(p, a, b, c, d) (p)->CreatePalette(a, b, c, d) -#define IDirectDraw2_CreateSurface(p, a, b, c) (p)->CreateSurface(a, b, c) -#define IDirectDraw2_DuplicateSurface(p, a, b) (p)->DuplicateSurface(a, b) -#define IDirectDraw2_EnumDisplayModes(p, a, b, c, d) (p)->EnumDisplayModes(a, b, c, d) -#define IDirectDraw2_EnumSurfaces(p, a, b, c, d) (p)->EnumSurfaces(a, b, c, d) -#define IDirectDraw2_FlipToGDISurface(p) (p)->FlipToGDISurface() -#define IDirectDraw2_GetCaps(p, a, b) (p)->GetCaps(a, b) -#define IDirectDraw2_GetDisplayMode(p, a) (p)->GetDisplayMode(a) -#define IDirectDraw2_GetFourCCCodes(p, a, b) (p)->GetFourCCCodes(a, b) -#define IDirectDraw2_GetGDISurface(p, a) (p)->GetGDISurface(a) -#define IDirectDraw2_GetMonitorFrequency(p, a) (p)->GetMonitorFrequency(a) -#define IDirectDraw2_GetScanLine(p, a) (p)->GetScanLine(a) -#define IDirectDraw2_GetVerticalBlankStatus(p, a) (p)->GetVerticalBlankStatus(a) -#define IDirectDraw2_Initialize(p, a) (p)->Initialize(a) -#define IDirectDraw2_RestoreDisplayMode(p) (p)->RestoreDisplayMode() -#define IDirectDraw2_SetCooperativeLevel(p, a, b) (p)->SetCooperativeLevel(a, b) -#define IDirectDraw2_SetDisplayMode(p, a, b, c, d, e) (p)->SetDisplayMode(a, b, c, d, e) -#define IDirectDraw2_WaitForVerticalBlank(p, a, b) (p)->WaitForVerticalBlank(a, b) -#define IDirectDraw2_GetAvailableVidMem(p, a, b, c) (p)->GetAvailableVidMem(a, b, c) -#endif - -#endif - -#if defined( _WIN32 ) && !defined( _NO_COM ) -#undef INTERFACE -#define INTERFACE IDirectDraw4 -DECLARE_INTERFACE_( IDirectDraw4, IUnknown ) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID FAR * ppvObj) PURE; - STDMETHOD_(ULONG,AddRef) (THIS) PURE; - STDMETHOD_(ULONG,Release) (THIS) PURE; - /*** IDirectDraw methods ***/ - STDMETHOD(Compact)(THIS) PURE; - STDMETHOD(CreateClipper)(THIS_ DWORD, LPDIRECTDRAWCLIPPER FAR*, IUnknown FAR * ) PURE; - STDMETHOD(CreatePalette)(THIS_ DWORD, LPPALETTEENTRY, LPDIRECTDRAWPALETTE FAR*, IUnknown FAR * ) PURE; - STDMETHOD(CreateSurface)(THIS_ LPDDSURFACEDESC2, LPDIRECTDRAWSURFACE4 FAR *, IUnknown FAR *) PURE; - STDMETHOD(DuplicateSurface)( THIS_ LPDIRECTDRAWSURFACE4, LPDIRECTDRAWSURFACE4 FAR * ) PURE; - STDMETHOD(EnumDisplayModes)( THIS_ DWORD, LPDDSURFACEDESC2, LPVOID, LPDDENUMMODESCALLBACK2 ) PURE; - STDMETHOD(EnumSurfaces)(THIS_ DWORD, LPDDSURFACEDESC2, LPVOID,LPDDENUMSURFACESCALLBACK2 ) PURE; - STDMETHOD(FlipToGDISurface)(THIS) PURE; - STDMETHOD(GetCaps)( THIS_ LPDDCAPS, LPDDCAPS) PURE; - STDMETHOD(GetDisplayMode)( THIS_ LPDDSURFACEDESC2) PURE; - STDMETHOD(GetFourCCCodes)(THIS_ LPDWORD, LPDWORD ) PURE; - STDMETHOD(GetGDISurface)(THIS_ LPDIRECTDRAWSURFACE4 FAR *) PURE; - STDMETHOD(GetMonitorFrequency)(THIS_ LPDWORD) PURE; - STDMETHOD(GetScanLine)(THIS_ LPDWORD) PURE; - STDMETHOD(GetVerticalBlankStatus)(THIS_ LPBOOL ) PURE; - STDMETHOD(Initialize)(THIS_ GUID FAR *) PURE; - STDMETHOD(RestoreDisplayMode)(THIS) PURE; - STDMETHOD(SetCooperativeLevel)(THIS_ HWND, DWORD) PURE; - STDMETHOD(SetDisplayMode)(THIS_ DWORD, DWORD,DWORD, DWORD, DWORD) PURE; - STDMETHOD(WaitForVerticalBlank)(THIS_ DWORD, HANDLE ) PURE; - /*** Added in the v2 interface ***/ - STDMETHOD(GetAvailableVidMem)(THIS_ LPDDSCAPS2, LPDWORD, LPDWORD) PURE; - /*** Added in the V4 Interface ***/ - STDMETHOD(GetSurfaceFromDC) (THIS_ HDC, LPDIRECTDRAWSURFACE4 *) PURE; - STDMETHOD(RestoreAllSurfaces)(THIS) PURE; - STDMETHOD(TestCooperativeLevel)(THIS) PURE; - STDMETHOD(GetDeviceIdentifier)(THIS_ LPDDDEVICEIDENTIFIER, DWORD ) PURE; -}; -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectDraw4_QueryInterface(p, a, b) (p)->lpVtbl->QueryInterface(p, a, b) -#define IDirectDraw4_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirectDraw4_Release(p) (p)->lpVtbl->Release(p) -#define IDirectDraw4_Compact(p) (p)->lpVtbl->Compact(p) -#define IDirectDraw4_CreateClipper(p, a, b, c) (p)->lpVtbl->CreateClipper(p, a, b, c) -#define IDirectDraw4_CreatePalette(p, a, b, c, d) (p)->lpVtbl->CreatePalette(p, a, b, c, d) -#define IDirectDraw4_CreateSurface(p, a, b, c) (p)->lpVtbl->CreateSurface(p, a, b, c) -#define IDirectDraw4_DuplicateSurface(p, a, b) (p)->lpVtbl->DuplicateSurface(p, a, b) -#define IDirectDraw4_EnumDisplayModes(p, a, b, c, d) (p)->lpVtbl->EnumDisplayModes(p, a, b, c, d) -#define IDirectDraw4_EnumSurfaces(p, a, b, c, d) (p)->lpVtbl->EnumSurfaces(p, a, b, c, d) -#define IDirectDraw4_FlipToGDISurface(p) (p)->lpVtbl->FlipToGDISurface(p) -#define IDirectDraw4_GetCaps(p, a, b) (p)->lpVtbl->GetCaps(p, a, b) -#define IDirectDraw4_GetDisplayMode(p, a) (p)->lpVtbl->GetDisplayMode(p, a) -#define IDirectDraw4_GetFourCCCodes(p, a, b) (p)->lpVtbl->GetFourCCCodes(p, a, b) -#define IDirectDraw4_GetGDISurface(p, a) (p)->lpVtbl->GetGDISurface(p, a) -#define IDirectDraw4_GetMonitorFrequency(p, a) (p)->lpVtbl->GetMonitorFrequency(p, a) -#define IDirectDraw4_GetScanLine(p, a) (p)->lpVtbl->GetScanLine(p, a) -#define IDirectDraw4_GetVerticalBlankStatus(p, a) (p)->lpVtbl->GetVerticalBlankStatus(p, a) -#define IDirectDraw4_Initialize(p, a) (p)->lpVtbl->Initialize(p, a) -#define IDirectDraw4_RestoreDisplayMode(p) (p)->lpVtbl->RestoreDisplayMode(p) -#define IDirectDraw4_SetCooperativeLevel(p, a, b) (p)->lpVtbl->SetCooperativeLevel(p, a, b) -#define IDirectDraw4_SetDisplayMode(p, a, b, c, d, e) (p)->lpVtbl->SetDisplayMode(p, a, b, c, d, e) -#define IDirectDraw4_WaitForVerticalBlank(p, a, b) (p)->lpVtbl->WaitForVerticalBlank(p, a, b) -#define IDirectDraw4_GetAvailableVidMem(p, a, b, c) (p)->lpVtbl->GetAvailableVidMem(p, a, b, c) -#define IDirectDraw4_GetSurfaceFromDC(p, a, b) (p)->lpVtbl->GetSurfaceFromDC(p, a, b) -#define IDirectDraw4_RestoreAllSurfaces(p) (p)->lpVtbl->RestoreAllSurfaces(p) -#define IDirectDraw4_TestCooperativeLevel(p) (p)->lpVtbl->TestCooperativeLevel(p) -#define IDirectDraw4_GetDeviceIdentifier(p,a,b) (p)->lpVtbl->GetDeviceIdentifier(p,a,b) -#else -#define IDirectDraw4_QueryInterface(p, a, b) (p)->QueryInterface(a, b) -#define IDirectDraw4_AddRef(p) (p)->AddRef() -#define IDirectDraw4_Release(p) (p)->Release() -#define IDirectDraw4_Compact(p) (p)->Compact() -#define IDirectDraw4_CreateClipper(p, a, b, c) (p)->CreateClipper(a, b, c) -#define IDirectDraw4_CreatePalette(p, a, b, c, d) (p)->CreatePalette(a, b, c, d) -#define IDirectDraw4_CreateSurface(p, a, b, c) (p)->CreateSurface(a, b, c) -#define IDirectDraw4_DuplicateSurface(p, a, b) (p)->DuplicateSurface(a, b) -#define IDirectDraw4_EnumDisplayModes(p, a, b, c, d) (p)->EnumDisplayModes(a, b, c, d) -#define IDirectDraw4_EnumSurfaces(p, a, b, c, d) (p)->EnumSurfaces(a, b, c, d) -#define IDirectDraw4_FlipToGDISurface(p) (p)->FlipToGDISurface() -#define IDirectDraw4_GetCaps(p, a, b) (p)->GetCaps(a, b) -#define IDirectDraw4_GetDisplayMode(p, a) (p)->GetDisplayMode(a) -#define IDirectDraw4_GetFourCCCodes(p, a, b) (p)->GetFourCCCodes(a, b) -#define IDirectDraw4_GetGDISurface(p, a) (p)->GetGDISurface(a) -#define IDirectDraw4_GetMonitorFrequency(p, a) (p)->GetMonitorFrequency(a) -#define IDirectDraw4_GetScanLine(p, a) (p)->GetScanLine(a) -#define IDirectDraw4_GetVerticalBlankStatus(p, a) (p)->GetVerticalBlankStatus(a) -#define IDirectDraw4_Initialize(p, a) (p)->Initialize(a) -#define IDirectDraw4_RestoreDisplayMode(p) (p)->RestoreDisplayMode() -#define IDirectDraw4_SetCooperativeLevel(p, a, b) (p)->SetCooperativeLevel(a, b) -#define IDirectDraw4_SetDisplayMode(p, a, b, c, d, e) (p)->SetDisplayMode(a, b, c, d, e) -#define IDirectDraw4_WaitForVerticalBlank(p, a, b) (p)->WaitForVerticalBlank(a, b) -#define IDirectDraw4_GetAvailableVidMem(p, a, b, c) (p)->GetAvailableVidMem(a, b, c) -#define IDirectDraw4_GetSurfaceFromDC(p, a, b) (p)->GetSurfaceFromDC(a, b) -#define IDirectDraw4_RestoreAllSurfaces(p) (p)->RestoreAllSurfaces() -#define IDirectDraw4_TestCooperativeLevel(p) (p)->TestCooperativeLevel() -#define IDirectDraw4_GetDeviceIdentifier(p,a,b) (p)->GetDeviceIdentifier(a,b) -#endif - -#endif - -#if defined( _WIN32 ) && !defined( _NO_COM ) -#undef INTERFACE -#define INTERFACE IDirectDraw7 -DECLARE_INTERFACE_( IDirectDraw7, IUnknown ) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID FAR * ppvObj) PURE; - STDMETHOD_(ULONG,AddRef) (THIS) PURE; - STDMETHOD_(ULONG,Release) (THIS) PURE; - /*** IDirectDraw methods ***/ - STDMETHOD(Compact)(THIS) PURE; - STDMETHOD(CreateClipper)(THIS_ DWORD, LPDIRECTDRAWCLIPPER FAR*, IUnknown FAR * ) PURE; - STDMETHOD(CreatePalette)(THIS_ DWORD, LPPALETTEENTRY, LPDIRECTDRAWPALETTE FAR*, IUnknown FAR * ) PURE; - STDMETHOD(CreateSurface)(THIS_ LPDDSURFACEDESC2, LPDIRECTDRAWSURFACE7 FAR *, IUnknown FAR *) PURE; - STDMETHOD(DuplicateSurface)( THIS_ LPDIRECTDRAWSURFACE7, LPDIRECTDRAWSURFACE7 FAR * ) PURE; - STDMETHOD(EnumDisplayModes)( THIS_ DWORD, LPDDSURFACEDESC2, LPVOID, LPDDENUMMODESCALLBACK2 ) PURE; - STDMETHOD(EnumSurfaces)(THIS_ DWORD, LPDDSURFACEDESC2, LPVOID,LPDDENUMSURFACESCALLBACK7 ) PURE; - STDMETHOD(FlipToGDISurface)(THIS) PURE; - STDMETHOD(GetCaps)( THIS_ LPDDCAPS, LPDDCAPS) PURE; - STDMETHOD(GetDisplayMode)( THIS_ LPDDSURFACEDESC2) PURE; - STDMETHOD(GetFourCCCodes)(THIS_ LPDWORD, LPDWORD ) PURE; - STDMETHOD(GetGDISurface)(THIS_ LPDIRECTDRAWSURFACE7 FAR *) PURE; - STDMETHOD(GetMonitorFrequency)(THIS_ LPDWORD) PURE; - STDMETHOD(GetScanLine)(THIS_ LPDWORD) PURE; - STDMETHOD(GetVerticalBlankStatus)(THIS_ LPBOOL ) PURE; - STDMETHOD(Initialize)(THIS_ GUID FAR *) PURE; - STDMETHOD(RestoreDisplayMode)(THIS) PURE; - STDMETHOD(SetCooperativeLevel)(THIS_ HWND, DWORD) PURE; - STDMETHOD(SetDisplayMode)(THIS_ DWORD, DWORD,DWORD, DWORD, DWORD) PURE; - STDMETHOD(WaitForVerticalBlank)(THIS_ DWORD, HANDLE ) PURE; - /*** Added in the v2 interface ***/ - STDMETHOD(GetAvailableVidMem)(THIS_ LPDDSCAPS2, LPDWORD, LPDWORD) PURE; - /*** Added in the V4 Interface ***/ - STDMETHOD(GetSurfaceFromDC) (THIS_ HDC, LPDIRECTDRAWSURFACE7 *) PURE; - STDMETHOD(RestoreAllSurfaces)(THIS) PURE; - STDMETHOD(TestCooperativeLevel)(THIS) PURE; - STDMETHOD(GetDeviceIdentifier)(THIS_ LPDDDEVICEIDENTIFIER2, DWORD ) PURE; - STDMETHOD(StartModeTest)(THIS_ LPSIZE, DWORD, DWORD ) PURE; - STDMETHOD(EvaluateMode)(THIS_ DWORD, DWORD * ) PURE; -}; -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectDraw7_QueryInterface(p, a, b) (p)->lpVtbl->QueryInterface(p, a, b) -#define IDirectDraw7_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirectDraw7_Release(p) (p)->lpVtbl->Release(p) -#define IDirectDraw7_Compact(p) (p)->lpVtbl->Compact(p) -#define IDirectDraw7_CreateClipper(p, a, b, c) (p)->lpVtbl->CreateClipper(p, a, b, c) -#define IDirectDraw7_CreatePalette(p, a, b, c, d) (p)->lpVtbl->CreatePalette(p, a, b, c, d) -#define IDirectDraw7_CreateSurface(p, a, b, c) (p)->lpVtbl->CreateSurface(p, a, b, c) -#define IDirectDraw7_DuplicateSurface(p, a, b) (p)->lpVtbl->DuplicateSurface(p, a, b) -#define IDirectDraw7_EnumDisplayModes(p, a, b, c, d) (p)->lpVtbl->EnumDisplayModes(p, a, b, c, d) -#define IDirectDraw7_EnumSurfaces(p, a, b, c, d) (p)->lpVtbl->EnumSurfaces(p, a, b, c, d) -#define IDirectDraw7_FlipToGDISurface(p) (p)->lpVtbl->FlipToGDISurface(p) -#define IDirectDraw7_GetCaps(p, a, b) (p)->lpVtbl->GetCaps(p, a, b) -#define IDirectDraw7_GetDisplayMode(p, a) (p)->lpVtbl->GetDisplayMode(p, a) -#define IDirectDraw7_GetFourCCCodes(p, a, b) (p)->lpVtbl->GetFourCCCodes(p, a, b) -#define IDirectDraw7_GetGDISurface(p, a) (p)->lpVtbl->GetGDISurface(p, a) -#define IDirectDraw7_GetMonitorFrequency(p, a) (p)->lpVtbl->GetMonitorFrequency(p, a) -#define IDirectDraw7_GetScanLine(p, a) (p)->lpVtbl->GetScanLine(p, a) -#define IDirectDraw7_GetVerticalBlankStatus(p, a) (p)->lpVtbl->GetVerticalBlankStatus(p, a) -#define IDirectDraw7_Initialize(p, a) (p)->lpVtbl->Initialize(p, a) -#define IDirectDraw7_RestoreDisplayMode(p) (p)->lpVtbl->RestoreDisplayMode(p) -#define IDirectDraw7_SetCooperativeLevel(p, a, b) (p)->lpVtbl->SetCooperativeLevel(p, a, b) -#define IDirectDraw7_SetDisplayMode(p, a, b, c, d, e) (p)->lpVtbl->SetDisplayMode(p, a, b, c, d, e) -#define IDirectDraw7_WaitForVerticalBlank(p, a, b) (p)->lpVtbl->WaitForVerticalBlank(p, a, b) -#define IDirectDraw7_GetAvailableVidMem(p, a, b, c) (p)->lpVtbl->GetAvailableVidMem(p, a, b, c) -#define IDirectDraw7_GetSurfaceFromDC(p, a, b) (p)->lpVtbl->GetSurfaceFromDC(p, a, b) -#define IDirectDraw7_RestoreAllSurfaces(p) (p)->lpVtbl->RestoreAllSurfaces(p) -#define IDirectDraw7_TestCooperativeLevel(p) (p)->lpVtbl->TestCooperativeLevel(p) -#define IDirectDraw7_GetDeviceIdentifier(p,a,b) (p)->lpVtbl->GetDeviceIdentifier(p,a,b) -#define IDirectDraw7_StartModeTest(p,a,b,c) (p)->lpVtbl->StartModeTest(p,a,b,c) -#define IDirectDraw7_EvaluateMode(p,a,b) (p)->lpVtbl->EvaluateMode(p,a,b) -#else -#define IDirectDraw7_QueryInterface(p, a, b) (p)->QueryInterface(a, b) -#define IDirectDraw7_AddRef(p) (p)->AddRef() -#define IDirectDraw7_Release(p) (p)->Release() -#define IDirectDraw7_Compact(p) (p)->Compact() -#define IDirectDraw7_CreateClipper(p, a, b, c) (p)->CreateClipper(a, b, c) -#define IDirectDraw7_CreatePalette(p, a, b, c, d) (p)->CreatePalette(a, b, c, d) -#define IDirectDraw7_CreateSurface(p, a, b, c) (p)->CreateSurface(a, b, c) -#define IDirectDraw7_DuplicateSurface(p, a, b) (p)->DuplicateSurface(a, b) -#define IDirectDraw7_EnumDisplayModes(p, a, b, c, d) (p)->EnumDisplayModes(a, b, c, d) -#define IDirectDraw7_EnumSurfaces(p, a, b, c, d) (p)->EnumSurfaces(a, b, c, d) -#define IDirectDraw7_FlipToGDISurface(p) (p)->FlipToGDISurface() -#define IDirectDraw7_GetCaps(p, a, b) (p)->GetCaps(a, b) -#define IDirectDraw7_GetDisplayMode(p, a) (p)->GetDisplayMode(a) -#define IDirectDraw7_GetFourCCCodes(p, a, b) (p)->GetFourCCCodes(a, b) -#define IDirectDraw7_GetGDISurface(p, a) (p)->GetGDISurface(a) -#define IDirectDraw7_GetMonitorFrequency(p, a) (p)->GetMonitorFrequency(a) -#define IDirectDraw7_GetScanLine(p, a) (p)->GetScanLine(a) -#define IDirectDraw7_GetVerticalBlankStatus(p, a) (p)->GetVerticalBlankStatus(a) -#define IDirectDraw7_Initialize(p, a) (p)->Initialize(a) -#define IDirectDraw7_RestoreDisplayMode(p) (p)->RestoreDisplayMode() -#define IDirectDraw7_SetCooperativeLevel(p, a, b) (p)->SetCooperativeLevel(a, b) -#define IDirectDraw7_SetDisplayMode(p, a, b, c, d, e) (p)->SetDisplayMode(a, b, c, d, e) -#define IDirectDraw7_WaitForVerticalBlank(p, a, b) (p)->WaitForVerticalBlank(a, b) -#define IDirectDraw7_GetAvailableVidMem(p, a, b, c) (p)->GetAvailableVidMem(a, b, c) -#define IDirectDraw7_GetSurfaceFromDC(p, a, b) (p)->GetSurfaceFromDC(a, b) -#define IDirectDraw7_RestoreAllSurfaces(p) (p)->RestoreAllSurfaces() -#define IDirectDraw7_TestCooperativeLevel(p) (p)->TestCooperativeLevel() -#define IDirectDraw7_GetDeviceIdentifier(p,a,b) (p)->GetDeviceIdentifier(a,b) -#define IDirectDraw7_StartModeTest(p,a,b,c) (p)->lpVtbl->StartModeTest(a,b,c) -#define IDirectDraw7_EvaluateMode(p,a,b) (p)->lpVtbl->EvaluateMode(a,b) -#endif - -#endif - - -/* - * IDirectDrawPalette - */ -#if defined( _WIN32 ) && !defined( _NO_COM ) -#undef INTERFACE -#define INTERFACE IDirectDrawPalette -DECLARE_INTERFACE_( IDirectDrawPalette, IUnknown ) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID FAR * ppvObj) PURE; - STDMETHOD_(ULONG,AddRef) (THIS) PURE; - STDMETHOD_(ULONG,Release) (THIS) PURE; - /*** IDirectDrawPalette methods ***/ - STDMETHOD(GetCaps)(THIS_ LPDWORD) PURE; - STDMETHOD(GetEntries)(THIS_ DWORD,DWORD,DWORD,LPPALETTEENTRY) PURE; - STDMETHOD(Initialize)(THIS_ LPDIRECTDRAW, DWORD, LPPALETTEENTRY) PURE; - STDMETHOD(SetEntries)(THIS_ DWORD,DWORD,DWORD,LPPALETTEENTRY) PURE; -}; - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectDrawPalette_QueryInterface(p, a, b) (p)->lpVtbl->QueryInterface(p, a, b) -#define IDirectDrawPalette_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirectDrawPalette_Release(p) (p)->lpVtbl->Release(p) -#define IDirectDrawPalette_GetCaps(p, a) (p)->lpVtbl->GetCaps(p, a) -#define IDirectDrawPalette_GetEntries(p, a, b, c, d) (p)->lpVtbl->GetEntries(p, a, b, c, d) -#define IDirectDrawPalette_Initialize(p, a, b, c) (p)->lpVtbl->Initialize(p, a, b, c) -#define IDirectDrawPalette_SetEntries(p, a, b, c, d) (p)->lpVtbl->SetEntries(p, a, b, c, d) -#else -#define IDirectDrawPalette_QueryInterface(p, a, b) (p)->QueryInterface(a, b) -#define IDirectDrawPalette_AddRef(p) (p)->AddRef() -#define IDirectDrawPalette_Release(p) (p)->Release() -#define IDirectDrawPalette_GetCaps(p, a) (p)->GetCaps(a) -#define IDirectDrawPalette_GetEntries(p, a, b, c, d) (p)->GetEntries(a, b, c, d) -#define IDirectDrawPalette_Initialize(p, a, b, c) (p)->Initialize(a, b, c) -#define IDirectDrawPalette_SetEntries(p, a, b, c, d) (p)->SetEntries(a, b, c, d) -#endif - -#endif - - -/* - * IDirectDrawClipper - */ -#if defined( _WIN32 ) && !defined( _NO_COM ) -#undef INTERFACE -#define INTERFACE IDirectDrawClipper -DECLARE_INTERFACE_( IDirectDrawClipper, IUnknown ) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID FAR * ppvObj) PURE; - STDMETHOD_(ULONG,AddRef) (THIS) PURE; - STDMETHOD_(ULONG,Release) (THIS) PURE; - /*** IDirectDrawClipper methods ***/ - STDMETHOD(GetClipList)(THIS_ LPRECT, LPRGNDATA, LPDWORD) PURE; - STDMETHOD(GetHWnd)(THIS_ HWND FAR *) PURE; - STDMETHOD(Initialize)(THIS_ LPDIRECTDRAW, DWORD) PURE; - STDMETHOD(IsClipListChanged)(THIS_ BOOL FAR *) PURE; - STDMETHOD(SetClipList)(THIS_ LPRGNDATA,DWORD) PURE; - STDMETHOD(SetHWnd)(THIS_ DWORD, HWND ) PURE; -}; - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectDrawClipper_QueryInterface(p, a, b) (p)->lpVtbl->QueryInterface(p, a, b) -#define IDirectDrawClipper_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirectDrawClipper_Release(p) (p)->lpVtbl->Release(p) -#define IDirectDrawClipper_GetClipList(p, a, b, c) (p)->lpVtbl->GetClipList(p, a, b, c) -#define IDirectDrawClipper_GetHWnd(p, a) (p)->lpVtbl->GetHWnd(p, a) -#define IDirectDrawClipper_Initialize(p, a, b) (p)->lpVtbl->Initialize(p, a, b) -#define IDirectDrawClipper_IsClipListChanged(p, a) (p)->lpVtbl->IsClipListChanged(p, a) -#define IDirectDrawClipper_SetClipList(p, a, b) (p)->lpVtbl->SetClipList(p, a, b) -#define IDirectDrawClipper_SetHWnd(p, a, b) (p)->lpVtbl->SetHWnd(p, a, b) -#else -#define IDirectDrawClipper_QueryInterface(p, a, b) (p)->QueryInterface(a, b) -#define IDirectDrawClipper_AddRef(p) (p)->AddRef() -#define IDirectDrawClipper_Release(p) (p)->Release() -#define IDirectDrawClipper_GetClipList(p, a, b, c) (p)->GetClipList(a, b, c) -#define IDirectDrawClipper_GetHWnd(p, a) (p)->GetHWnd(a) -#define IDirectDrawClipper_Initialize(p, a, b) (p)->Initialize(a, b) -#define IDirectDrawClipper_IsClipListChanged(p, a) (p)->IsClipListChanged(a) -#define IDirectDrawClipper_SetClipList(p, a, b) (p)->SetClipList(a, b) -#define IDirectDrawClipper_SetHWnd(p, a, b) (p)->SetHWnd(a, b) -#endif - -#endif - -/* - * IDirectDrawSurface and related interfaces - */ -#if defined( _WIN32 ) && !defined( _NO_COM ) -#undef INTERFACE -#define INTERFACE IDirectDrawSurface -DECLARE_INTERFACE_( IDirectDrawSurface, IUnknown ) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID FAR * ppvObj) PURE; - STDMETHOD_(ULONG,AddRef) (THIS) PURE; - STDMETHOD_(ULONG,Release) (THIS) PURE; - /*** IDirectDrawSurface methods ***/ - STDMETHOD(AddAttachedSurface)(THIS_ LPDIRECTDRAWSURFACE) PURE; - STDMETHOD(AddOverlayDirtyRect)(THIS_ LPRECT) PURE; - STDMETHOD(Blt)(THIS_ LPRECT,LPDIRECTDRAWSURFACE, LPRECT,DWORD, LPDDBLTFX) PURE; - STDMETHOD(BltBatch)(THIS_ LPDDBLTBATCH, DWORD, DWORD ) PURE; - STDMETHOD(BltFast)(THIS_ DWORD,DWORD,LPDIRECTDRAWSURFACE, LPRECT,DWORD) PURE; - STDMETHOD(DeleteAttachedSurface)(THIS_ DWORD,LPDIRECTDRAWSURFACE) PURE; - STDMETHOD(EnumAttachedSurfaces)(THIS_ LPVOID,LPDDENUMSURFACESCALLBACK) PURE; - STDMETHOD(EnumOverlayZOrders)(THIS_ DWORD,LPVOID,LPDDENUMSURFACESCALLBACK) PURE; - STDMETHOD(Flip)(THIS_ LPDIRECTDRAWSURFACE, DWORD) PURE; - STDMETHOD(GetAttachedSurface)(THIS_ LPDDSCAPS, LPDIRECTDRAWSURFACE FAR *) PURE; - STDMETHOD(GetBltStatus)(THIS_ DWORD) PURE; - STDMETHOD(GetCaps)(THIS_ LPDDSCAPS) PURE; - STDMETHOD(GetClipper)(THIS_ LPDIRECTDRAWCLIPPER FAR*) PURE; - STDMETHOD(GetColorKey)(THIS_ DWORD, LPDDCOLORKEY) PURE; - STDMETHOD(GetDC)(THIS_ HDC FAR *) PURE; - STDMETHOD(GetFlipStatus)(THIS_ DWORD) PURE; - STDMETHOD(GetOverlayPosition)(THIS_ LPLONG, LPLONG ) PURE; - STDMETHOD(GetPalette)(THIS_ LPDIRECTDRAWPALETTE FAR*) PURE; - STDMETHOD(GetPixelFormat)(THIS_ LPDDPIXELFORMAT) PURE; - STDMETHOD(GetSurfaceDesc)(THIS_ LPDDSURFACEDESC) PURE; - STDMETHOD(Initialize)(THIS_ LPDIRECTDRAW, LPDDSURFACEDESC) PURE; - STDMETHOD(IsLost)(THIS) PURE; - STDMETHOD(Lock)(THIS_ LPRECT,LPDDSURFACEDESC,DWORD,HANDLE) PURE; - STDMETHOD(ReleaseDC)(THIS_ HDC) PURE; - STDMETHOD(Restore)(THIS) PURE; - STDMETHOD(SetClipper)(THIS_ LPDIRECTDRAWCLIPPER) PURE; - STDMETHOD(SetColorKey)(THIS_ DWORD, LPDDCOLORKEY) PURE; - STDMETHOD(SetOverlayPosition)(THIS_ LONG, LONG ) PURE; - STDMETHOD(SetPalette)(THIS_ LPDIRECTDRAWPALETTE) PURE; - STDMETHOD(Unlock)(THIS_ LPVOID) PURE; - STDMETHOD(UpdateOverlay)(THIS_ LPRECT, LPDIRECTDRAWSURFACE,LPRECT,DWORD, LPDDOVERLAYFX) PURE; - STDMETHOD(UpdateOverlayDisplay)(THIS_ DWORD) PURE; - STDMETHOD(UpdateOverlayZOrder)(THIS_ DWORD, LPDIRECTDRAWSURFACE) PURE; -}; - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectDrawSurface_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) -#define IDirectDrawSurface_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirectDrawSurface_Release(p) (p)->lpVtbl->Release(p) -#define IDirectDrawSurface_AddAttachedSurface(p,a) (p)->lpVtbl->AddAttachedSurface(p,a) -#define IDirectDrawSurface_AddOverlayDirtyRect(p,a) (p)->lpVtbl->AddOverlayDirtyRect(p,a) -#define IDirectDrawSurface_Blt(p,a,b,c,d,e) (p)->lpVtbl->Blt(p,a,b,c,d,e) -#define IDirectDrawSurface_BltBatch(p,a,b,c) (p)->lpVtbl->BltBatch(p,a,b,c) -#define IDirectDrawSurface_BltFast(p,a,b,c,d,e) (p)->lpVtbl->BltFast(p,a,b,c,d,e) -#define IDirectDrawSurface_DeleteAttachedSurface(p,a,b) (p)->lpVtbl->DeleteAttachedSurface(p,a,b) -#define IDirectDrawSurface_EnumAttachedSurfaces(p,a,b) (p)->lpVtbl->EnumAttachedSurfaces(p,a,b) -#define IDirectDrawSurface_EnumOverlayZOrders(p,a,b,c) (p)->lpVtbl->EnumOverlayZOrders(p,a,b,c) -#define IDirectDrawSurface_Flip(p,a,b) (p)->lpVtbl->Flip(p,a,b) -#define IDirectDrawSurface_GetAttachedSurface(p,a,b) (p)->lpVtbl->GetAttachedSurface(p,a,b) -#define IDirectDrawSurface_GetBltStatus(p,a) (p)->lpVtbl->GetBltStatus(p,a) -#define IDirectDrawSurface_GetCaps(p,b) (p)->lpVtbl->GetCaps(p,b) -#define IDirectDrawSurface_GetClipper(p,a) (p)->lpVtbl->GetClipper(p,a) -#define IDirectDrawSurface_GetColorKey(p,a,b) (p)->lpVtbl->GetColorKey(p,a,b) -#define IDirectDrawSurface_GetDC(p,a) (p)->lpVtbl->GetDC(p,a) -#define IDirectDrawSurface_GetFlipStatus(p,a) (p)->lpVtbl->GetFlipStatus(p,a) -#define IDirectDrawSurface_GetOverlayPosition(p,a,b) (p)->lpVtbl->GetOverlayPosition(p,a,b) -#define IDirectDrawSurface_GetPalette(p,a) (p)->lpVtbl->GetPalette(p,a) -#define IDirectDrawSurface_GetPixelFormat(p,a) (p)->lpVtbl->GetPixelFormat(p,a) -#define IDirectDrawSurface_GetSurfaceDesc(p,a) (p)->lpVtbl->GetSurfaceDesc(p,a) -#define IDirectDrawSurface_Initialize(p,a,b) (p)->lpVtbl->Initialize(p,a,b) -#define IDirectDrawSurface_IsLost(p) (p)->lpVtbl->IsLost(p) -#define IDirectDrawSurface_Lock(p,a,b,c,d) (p)->lpVtbl->Lock(p,a,b,c,d) -#define IDirectDrawSurface_ReleaseDC(p,a) (p)->lpVtbl->ReleaseDC(p,a) -#define IDirectDrawSurface_Restore(p) (p)->lpVtbl->Restore(p) -#define IDirectDrawSurface_SetClipper(p,a) (p)->lpVtbl->SetClipper(p,a) -#define IDirectDrawSurface_SetColorKey(p,a,b) (p)->lpVtbl->SetColorKey(p,a,b) -#define IDirectDrawSurface_SetOverlayPosition(p,a,b) (p)->lpVtbl->SetOverlayPosition(p,a,b) -#define IDirectDrawSurface_SetPalette(p,a) (p)->lpVtbl->SetPalette(p,a) -#define IDirectDrawSurface_Unlock(p,b) (p)->lpVtbl->Unlock(p,b) -#define IDirectDrawSurface_UpdateOverlay(p,a,b,c,d,e) (p)->lpVtbl->UpdateOverlay(p,a,b,c,d,e) -#define IDirectDrawSurface_UpdateOverlayDisplay(p,a) (p)->lpVtbl->UpdateOverlayDisplay(p,a) -#define IDirectDrawSurface_UpdateOverlayZOrder(p,a,b) (p)->lpVtbl->UpdateOverlayZOrder(p,a,b) -#else -#define IDirectDrawSurface_QueryInterface(p,a,b) (p)->QueryInterface(a,b) -#define IDirectDrawSurface_AddRef(p) (p)->AddRef() -#define IDirectDrawSurface_Release(p) (p)->Release() -#define IDirectDrawSurface_AddAttachedSurface(p,a) (p)->AddAttachedSurface(a) -#define IDirectDrawSurface_AddOverlayDirtyRect(p,a) (p)->AddOverlayDirtyRect(a) -#define IDirectDrawSurface_Blt(p,a,b,c,d,e) (p)->Blt(a,b,c,d,e) -#define IDirectDrawSurface_BltBatch(p,a,b,c) (p)->BltBatch(a,b,c) -#define IDirectDrawSurface_BltFast(p,a,b,c,d,e) (p)->BltFast(a,b,c,d,e) -#define IDirectDrawSurface_DeleteAttachedSurface(p,a,b) (p)->DeleteAttachedSurface(a,b) -#define IDirectDrawSurface_EnumAttachedSurfaces(p,a,b) (p)->EnumAttachedSurfaces(a,b) -#define IDirectDrawSurface_EnumOverlayZOrders(p,a,b,c) (p)->EnumOverlayZOrders(a,b,c) -#define IDirectDrawSurface_Flip(p,a,b) (p)->Flip(a,b) -#define IDirectDrawSurface_GetAttachedSurface(p,a,b) (p)->GetAttachedSurface(a,b) -#define IDirectDrawSurface_GetBltStatus(p,a) (p)->GetBltStatus(a) -#define IDirectDrawSurface_GetCaps(p,b) (p)->GetCaps(b) -#define IDirectDrawSurface_GetClipper(p,a) (p)->GetClipper(a) -#define IDirectDrawSurface_GetColorKey(p,a,b) (p)->GetColorKey(a,b) -#define IDirectDrawSurface_GetDC(p,a) (p)->GetDC(a) -#define IDirectDrawSurface_GetFlipStatus(p,a) (p)->GetFlipStatus(a) -#define IDirectDrawSurface_GetOverlayPosition(p,a,b) (p)->GetOverlayPosition(a,b) -#define IDirectDrawSurface_GetPalette(p,a) (p)->GetPalette(a) -#define IDirectDrawSurface_GetPixelFormat(p,a) (p)->GetPixelFormat(a) -#define IDirectDrawSurface_GetSurfaceDesc(p,a) (p)->GetSurfaceDesc(a) -#define IDirectDrawSurface_Initialize(p,a,b) (p)->Initialize(a,b) -#define IDirectDrawSurface_IsLost(p) (p)->IsLost() -#define IDirectDrawSurface_Lock(p,a,b,c,d) (p)->Lock(a,b,c,d) -#define IDirectDrawSurface_ReleaseDC(p,a) (p)->ReleaseDC(a) -#define IDirectDrawSurface_Restore(p) (p)->Restore() -#define IDirectDrawSurface_SetClipper(p,a) (p)->SetClipper(a) -#define IDirectDrawSurface_SetColorKey(p,a,b) (p)->SetColorKey(a,b) -#define IDirectDrawSurface_SetOverlayPosition(p,a,b) (p)->SetOverlayPosition(a,b) -#define IDirectDrawSurface_SetPalette(p,a) (p)->SetPalette(a) -#define IDirectDrawSurface_Unlock(p,b) (p)->Unlock(b) -#define IDirectDrawSurface_UpdateOverlay(p,a,b,c,d,e) (p)->UpdateOverlay(a,b,c,d,e) -#define IDirectDrawSurface_UpdateOverlayDisplay(p,a) (p)->UpdateOverlayDisplay(a) -#define IDirectDrawSurface_UpdateOverlayZOrder(p,a,b) (p)->UpdateOverlayZOrder(a,b) -#endif - -/* - * IDirectDrawSurface2 and related interfaces - */ -#undef INTERFACE -#define INTERFACE IDirectDrawSurface2 -DECLARE_INTERFACE_( IDirectDrawSurface2, IUnknown ) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID FAR * ppvObj) PURE; - STDMETHOD_(ULONG,AddRef) (THIS) PURE; - STDMETHOD_(ULONG,Release) (THIS) PURE; - /*** IDirectDrawSurface methods ***/ - STDMETHOD(AddAttachedSurface)(THIS_ LPDIRECTDRAWSURFACE2) PURE; - STDMETHOD(AddOverlayDirtyRect)(THIS_ LPRECT) PURE; - STDMETHOD(Blt)(THIS_ LPRECT,LPDIRECTDRAWSURFACE2, LPRECT,DWORD, LPDDBLTFX) PURE; - STDMETHOD(BltBatch)(THIS_ LPDDBLTBATCH, DWORD, DWORD ) PURE; - STDMETHOD(BltFast)(THIS_ DWORD,DWORD,LPDIRECTDRAWSURFACE2, LPRECT,DWORD) PURE; - STDMETHOD(DeleteAttachedSurface)(THIS_ DWORD,LPDIRECTDRAWSURFACE2) PURE; - STDMETHOD(EnumAttachedSurfaces)(THIS_ LPVOID,LPDDENUMSURFACESCALLBACK) PURE; - STDMETHOD(EnumOverlayZOrders)(THIS_ DWORD,LPVOID,LPDDENUMSURFACESCALLBACK) PURE; - STDMETHOD(Flip)(THIS_ LPDIRECTDRAWSURFACE2, DWORD) PURE; - STDMETHOD(GetAttachedSurface)(THIS_ LPDDSCAPS, LPDIRECTDRAWSURFACE2 FAR *) PURE; - STDMETHOD(GetBltStatus)(THIS_ DWORD) PURE; - STDMETHOD(GetCaps)(THIS_ LPDDSCAPS) PURE; - STDMETHOD(GetClipper)(THIS_ LPDIRECTDRAWCLIPPER FAR*) PURE; - STDMETHOD(GetColorKey)(THIS_ DWORD, LPDDCOLORKEY) PURE; - STDMETHOD(GetDC)(THIS_ HDC FAR *) PURE; - STDMETHOD(GetFlipStatus)(THIS_ DWORD) PURE; - STDMETHOD(GetOverlayPosition)(THIS_ LPLONG, LPLONG ) PURE; - STDMETHOD(GetPalette)(THIS_ LPDIRECTDRAWPALETTE FAR*) PURE; - STDMETHOD(GetPixelFormat)(THIS_ LPDDPIXELFORMAT) PURE; - STDMETHOD(GetSurfaceDesc)(THIS_ LPDDSURFACEDESC) PURE; - STDMETHOD(Initialize)(THIS_ LPDIRECTDRAW, LPDDSURFACEDESC) PURE; - STDMETHOD(IsLost)(THIS) PURE; - STDMETHOD(Lock)(THIS_ LPRECT,LPDDSURFACEDESC,DWORD,HANDLE) PURE; - STDMETHOD(ReleaseDC)(THIS_ HDC) PURE; - STDMETHOD(Restore)(THIS) PURE; - STDMETHOD(SetClipper)(THIS_ LPDIRECTDRAWCLIPPER) PURE; - STDMETHOD(SetColorKey)(THIS_ DWORD, LPDDCOLORKEY) PURE; - STDMETHOD(SetOverlayPosition)(THIS_ LONG, LONG ) PURE; - STDMETHOD(SetPalette)(THIS_ LPDIRECTDRAWPALETTE) PURE; - STDMETHOD(Unlock)(THIS_ LPVOID) PURE; - STDMETHOD(UpdateOverlay)(THIS_ LPRECT, LPDIRECTDRAWSURFACE2,LPRECT,DWORD, LPDDOVERLAYFX) PURE; - STDMETHOD(UpdateOverlayDisplay)(THIS_ DWORD) PURE; - STDMETHOD(UpdateOverlayZOrder)(THIS_ DWORD, LPDIRECTDRAWSURFACE2) PURE; - /*** Added in the v2 interface ***/ - STDMETHOD(GetDDInterface)(THIS_ LPVOID FAR *) PURE; - STDMETHOD(PageLock)(THIS_ DWORD) PURE; - STDMETHOD(PageUnlock)(THIS_ DWORD) PURE; -}; - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectDrawSurface2_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) -#define IDirectDrawSurface2_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirectDrawSurface2_Release(p) (p)->lpVtbl->Release(p) -#define IDirectDrawSurface2_AddAttachedSurface(p,a) (p)->lpVtbl->AddAttachedSurface(p,a) -#define IDirectDrawSurface2_AddOverlayDirtyRect(p,a) (p)->lpVtbl->AddOverlayDirtyRect(p,a) -#define IDirectDrawSurface2_Blt(p,a,b,c,d,e) (p)->lpVtbl->Blt(p,a,b,c,d,e) -#define IDirectDrawSurface2_BltBatch(p,a,b,c) (p)->lpVtbl->BltBatch(p,a,b,c) -#define IDirectDrawSurface2_BltFast(p,a,b,c,d,e) (p)->lpVtbl->BltFast(p,a,b,c,d,e) -#define IDirectDrawSurface2_DeleteAttachedSurface(p,a,b) (p)->lpVtbl->DeleteAttachedSurface(p,a,b) -#define IDirectDrawSurface2_EnumAttachedSurfaces(p,a,b) (p)->lpVtbl->EnumAttachedSurfaces(p,a,b) -#define IDirectDrawSurface2_EnumOverlayZOrders(p,a,b,c) (p)->lpVtbl->EnumOverlayZOrders(p,a,b,c) -#define IDirectDrawSurface2_Flip(p,a,b) (p)->lpVtbl->Flip(p,a,b) -#define IDirectDrawSurface2_GetAttachedSurface(p,a,b) (p)->lpVtbl->GetAttachedSurface(p,a,b) -#define IDirectDrawSurface2_GetBltStatus(p,a) (p)->lpVtbl->GetBltStatus(p,a) -#define IDirectDrawSurface2_GetCaps(p,b) (p)->lpVtbl->GetCaps(p,b) -#define IDirectDrawSurface2_GetClipper(p,a) (p)->lpVtbl->GetClipper(p,a) -#define IDirectDrawSurface2_GetColorKey(p,a,b) (p)->lpVtbl->GetColorKey(p,a,b) -#define IDirectDrawSurface2_GetDC(p,a) (p)->lpVtbl->GetDC(p,a) -#define IDirectDrawSurface2_GetFlipStatus(p,a) (p)->lpVtbl->GetFlipStatus(p,a) -#define IDirectDrawSurface2_GetOverlayPosition(p,a,b) (p)->lpVtbl->GetOverlayPosition(p,a,b) -#define IDirectDrawSurface2_GetPalette(p,a) (p)->lpVtbl->GetPalette(p,a) -#define IDirectDrawSurface2_GetPixelFormat(p,a) (p)->lpVtbl->GetPixelFormat(p,a) -#define IDirectDrawSurface2_GetSurfaceDesc(p,a) (p)->lpVtbl->GetSurfaceDesc(p,a) -#define IDirectDrawSurface2_Initialize(p,a,b) (p)->lpVtbl->Initialize(p,a,b) -#define IDirectDrawSurface2_IsLost(p) (p)->lpVtbl->IsLost(p) -#define IDirectDrawSurface2_Lock(p,a,b,c,d) (p)->lpVtbl->Lock(p,a,b,c,d) -#define IDirectDrawSurface2_ReleaseDC(p,a) (p)->lpVtbl->ReleaseDC(p,a) -#define IDirectDrawSurface2_Restore(p) (p)->lpVtbl->Restore(p) -#define IDirectDrawSurface2_SetClipper(p,a) (p)->lpVtbl->SetClipper(p,a) -#define IDirectDrawSurface2_SetColorKey(p,a,b) (p)->lpVtbl->SetColorKey(p,a,b) -#define IDirectDrawSurface2_SetOverlayPosition(p,a,b) (p)->lpVtbl->SetOverlayPosition(p,a,b) -#define IDirectDrawSurface2_SetPalette(p,a) (p)->lpVtbl->SetPalette(p,a) -#define IDirectDrawSurface2_Unlock(p,b) (p)->lpVtbl->Unlock(p,b) -#define IDirectDrawSurface2_UpdateOverlay(p,a,b,c,d,e) (p)->lpVtbl->UpdateOverlay(p,a,b,c,d,e) -#define IDirectDrawSurface2_UpdateOverlayDisplay(p,a) (p)->lpVtbl->UpdateOverlayDisplay(p,a) -#define IDirectDrawSurface2_UpdateOverlayZOrder(p,a,b) (p)->lpVtbl->UpdateOverlayZOrder(p,a,b) -#define IDirectDrawSurface2_GetDDInterface(p,a) (p)->lpVtbl->GetDDInterface(p,a) -#define IDirectDrawSurface2_PageLock(p,a) (p)->lpVtbl->PageLock(p,a) -#define IDirectDrawSurface2_PageUnlock(p,a) (p)->lpVtbl->PageUnlock(p,a) -#else -#define IDirectDrawSurface2_QueryInterface(p,a,b) (p)->QueryInterface(a,b) -#define IDirectDrawSurface2_AddRef(p) (p)->AddRef() -#define IDirectDrawSurface2_Release(p) (p)->Release() -#define IDirectDrawSurface2_AddAttachedSurface(p,a) (p)->AddAttachedSurface(a) -#define IDirectDrawSurface2_AddOverlayDirtyRect(p,a) (p)->AddOverlayDirtyRect(a) -#define IDirectDrawSurface2_Blt(p,a,b,c,d,e) (p)->Blt(a,b,c,d,e) -#define IDirectDrawSurface2_BltBatch(p,a,b,c) (p)->BltBatch(a,b,c) -#define IDirectDrawSurface2_BltFast(p,a,b,c,d,e) (p)->BltFast(a,b,c,d,e) -#define IDirectDrawSurface2_DeleteAttachedSurface(p,a,b) (p)->DeleteAttachedSurface(a,b) -#define IDirectDrawSurface2_EnumAttachedSurfaces(p,a,b) (p)->EnumAttachedSurfaces(a,b) -#define IDirectDrawSurface2_EnumOverlayZOrders(p,a,b,c) (p)->EnumOverlayZOrders(a,b,c) -#define IDirectDrawSurface2_Flip(p,a,b) (p)->Flip(a,b) -#define IDirectDrawSurface2_GetAttachedSurface(p,a,b) (p)->GetAttachedSurface(a,b) -#define IDirectDrawSurface2_GetBltStatus(p,a) (p)->GetBltStatus(a) -#define IDirectDrawSurface2_GetCaps(p,b) (p)->GetCaps(b) -#define IDirectDrawSurface2_GetClipper(p,a) (p)->GetClipper(a) -#define IDirectDrawSurface2_GetColorKey(p,a,b) (p)->GetColorKey(a,b) -#define IDirectDrawSurface2_GetDC(p,a) (p)->GetDC(a) -#define IDirectDrawSurface2_GetFlipStatus(p,a) (p)->GetFlipStatus(a) -#define IDirectDrawSurface2_GetOverlayPosition(p,a,b) (p)->GetOverlayPosition(a,b) -#define IDirectDrawSurface2_GetPalette(p,a) (p)->GetPalette(a) -#define IDirectDrawSurface2_GetPixelFormat(p,a) (p)->GetPixelFormat(a) -#define IDirectDrawSurface2_GetSurfaceDesc(p,a) (p)->GetSurfaceDesc(a) -#define IDirectDrawSurface2_Initialize(p,a,b) (p)->Initialize(a,b) -#define IDirectDrawSurface2_IsLost(p) (p)->IsLost() -#define IDirectDrawSurface2_Lock(p,a,b,c,d) (p)->Lock(a,b,c,d) -#define IDirectDrawSurface2_ReleaseDC(p,a) (p)->ReleaseDC(a) -#define IDirectDrawSurface2_Restore(p) (p)->Restore() -#define IDirectDrawSurface2_SetClipper(p,a) (p)->SetClipper(a) -#define IDirectDrawSurface2_SetColorKey(p,a,b) (p)->SetColorKey(a,b) -#define IDirectDrawSurface2_SetOverlayPosition(p,a,b) (p)->SetOverlayPosition(a,b) -#define IDirectDrawSurface2_SetPalette(p,a) (p)->SetPalette(a) -#define IDirectDrawSurface2_Unlock(p,b) (p)->Unlock(b) -#define IDirectDrawSurface2_UpdateOverlay(p,a,b,c,d,e) (p)->UpdateOverlay(a,b,c,d,e) -#define IDirectDrawSurface2_UpdateOverlayDisplay(p,a) (p)->UpdateOverlayDisplay(a) -#define IDirectDrawSurface2_UpdateOverlayZOrder(p,a,b) (p)->UpdateOverlayZOrder(a,b) -#define IDirectDrawSurface2_GetDDInterface(p,a) (p)->GetDDInterface(a) -#define IDirectDrawSurface2_PageLock(p,a) (p)->PageLock(a) -#define IDirectDrawSurface2_PageUnlock(p,a) (p)->PageUnlock(a) -#endif - -/* - * IDirectDrawSurface3 and related interfaces - */ -#undef INTERFACE -#define INTERFACE IDirectDrawSurface3 -DECLARE_INTERFACE_( IDirectDrawSurface3, IUnknown ) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID FAR * ppvObj) PURE; - STDMETHOD_(ULONG,AddRef) (THIS) PURE; - STDMETHOD_(ULONG,Release) (THIS) PURE; - /*** IDirectDrawSurface methods ***/ - STDMETHOD(AddAttachedSurface)(THIS_ LPDIRECTDRAWSURFACE3) PURE; - STDMETHOD(AddOverlayDirtyRect)(THIS_ LPRECT) PURE; - STDMETHOD(Blt)(THIS_ LPRECT,LPDIRECTDRAWSURFACE3, LPRECT,DWORD, LPDDBLTFX) PURE; - STDMETHOD(BltBatch)(THIS_ LPDDBLTBATCH, DWORD, DWORD ) PURE; - STDMETHOD(BltFast)(THIS_ DWORD,DWORD,LPDIRECTDRAWSURFACE3, LPRECT,DWORD) PURE; - STDMETHOD(DeleteAttachedSurface)(THIS_ DWORD,LPDIRECTDRAWSURFACE3) PURE; - STDMETHOD(EnumAttachedSurfaces)(THIS_ LPVOID,LPDDENUMSURFACESCALLBACK) PURE; - STDMETHOD(EnumOverlayZOrders)(THIS_ DWORD,LPVOID,LPDDENUMSURFACESCALLBACK) PURE; - STDMETHOD(Flip)(THIS_ LPDIRECTDRAWSURFACE3, DWORD) PURE; - STDMETHOD(GetAttachedSurface)(THIS_ LPDDSCAPS, LPDIRECTDRAWSURFACE3 FAR *) PURE; - STDMETHOD(GetBltStatus)(THIS_ DWORD) PURE; - STDMETHOD(GetCaps)(THIS_ LPDDSCAPS) PURE; - STDMETHOD(GetClipper)(THIS_ LPDIRECTDRAWCLIPPER FAR*) PURE; - STDMETHOD(GetColorKey)(THIS_ DWORD, LPDDCOLORKEY) PURE; - STDMETHOD(GetDC)(THIS_ HDC FAR *) PURE; - STDMETHOD(GetFlipStatus)(THIS_ DWORD) PURE; - STDMETHOD(GetOverlayPosition)(THIS_ LPLONG, LPLONG ) PURE; - STDMETHOD(GetPalette)(THIS_ LPDIRECTDRAWPALETTE FAR*) PURE; - STDMETHOD(GetPixelFormat)(THIS_ LPDDPIXELFORMAT) PURE; - STDMETHOD(GetSurfaceDesc)(THIS_ LPDDSURFACEDESC) PURE; - STDMETHOD(Initialize)(THIS_ LPDIRECTDRAW, LPDDSURFACEDESC) PURE; - STDMETHOD(IsLost)(THIS) PURE; - STDMETHOD(Lock)(THIS_ LPRECT,LPDDSURFACEDESC,DWORD,HANDLE) PURE; - STDMETHOD(ReleaseDC)(THIS_ HDC) PURE; - STDMETHOD(Restore)(THIS) PURE; - STDMETHOD(SetClipper)(THIS_ LPDIRECTDRAWCLIPPER) PURE; - STDMETHOD(SetColorKey)(THIS_ DWORD, LPDDCOLORKEY) PURE; - STDMETHOD(SetOverlayPosition)(THIS_ LONG, LONG ) PURE; - STDMETHOD(SetPalette)(THIS_ LPDIRECTDRAWPALETTE) PURE; - STDMETHOD(Unlock)(THIS_ LPVOID) PURE; - STDMETHOD(UpdateOverlay)(THIS_ LPRECT, LPDIRECTDRAWSURFACE3,LPRECT,DWORD, LPDDOVERLAYFX) PURE; - STDMETHOD(UpdateOverlayDisplay)(THIS_ DWORD) PURE; - STDMETHOD(UpdateOverlayZOrder)(THIS_ DWORD, LPDIRECTDRAWSURFACE3) PURE; - /*** Added in the v2 interface ***/ - STDMETHOD(GetDDInterface)(THIS_ LPVOID FAR *) PURE; - STDMETHOD(PageLock)(THIS_ DWORD) PURE; - STDMETHOD(PageUnlock)(THIS_ DWORD) PURE; - /*** Added in the V3 interface ***/ - STDMETHOD(SetSurfaceDesc)(THIS_ LPDDSURFACEDESC, DWORD) PURE; -}; - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectDrawSurface3_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) -#define IDirectDrawSurface3_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirectDrawSurface3_Release(p) (p)->lpVtbl->Release(p) -#define IDirectDrawSurface3_AddAttachedSurface(p,a) (p)->lpVtbl->AddAttachedSurface(p,a) -#define IDirectDrawSurface3_AddOverlayDirtyRect(p,a) (p)->lpVtbl->AddOverlayDirtyRect(p,a) -#define IDirectDrawSurface3_Blt(p,a,b,c,d,e) (p)->lpVtbl->Blt(p,a,b,c,d,e) -#define IDirectDrawSurface3_BltBatch(p,a,b,c) (p)->lpVtbl->BltBatch(p,a,b,c) -#define IDirectDrawSurface3_BltFast(p,a,b,c,d,e) (p)->lpVtbl->BltFast(p,a,b,c,d,e) -#define IDirectDrawSurface3_DeleteAttachedSurface(p,a,b) (p)->lpVtbl->DeleteAttachedSurface(p,a,b) -#define IDirectDrawSurface3_EnumAttachedSurfaces(p,a,b) (p)->lpVtbl->EnumAttachedSurfaces(p,a,b) -#define IDirectDrawSurface3_EnumOverlayZOrders(p,a,b,c) (p)->lpVtbl->EnumOverlayZOrders(p,a,b,c) -#define IDirectDrawSurface3_Flip(p,a,b) (p)->lpVtbl->Flip(p,a,b) -#define IDirectDrawSurface3_GetAttachedSurface(p,a,b) (p)->lpVtbl->GetAttachedSurface(p,a,b) -#define IDirectDrawSurface3_GetBltStatus(p,a) (p)->lpVtbl->GetBltStatus(p,a) -#define IDirectDrawSurface3_GetCaps(p,b) (p)->lpVtbl->GetCaps(p,b) -#define IDirectDrawSurface3_GetClipper(p,a) (p)->lpVtbl->GetClipper(p,a) -#define IDirectDrawSurface3_GetColorKey(p,a,b) (p)->lpVtbl->GetColorKey(p,a,b) -#define IDirectDrawSurface3_GetDC(p,a) (p)->lpVtbl->GetDC(p,a) -#define IDirectDrawSurface3_GetFlipStatus(p,a) (p)->lpVtbl->GetFlipStatus(p,a) -#define IDirectDrawSurface3_GetOverlayPosition(p,a,b) (p)->lpVtbl->GetOverlayPosition(p,a,b) -#define IDirectDrawSurface3_GetPalette(p,a) (p)->lpVtbl->GetPalette(p,a) -#define IDirectDrawSurface3_GetPixelFormat(p,a) (p)->lpVtbl->GetPixelFormat(p,a) -#define IDirectDrawSurface3_GetSurfaceDesc(p,a) (p)->lpVtbl->GetSurfaceDesc(p,a) -#define IDirectDrawSurface3_Initialize(p,a,b) (p)->lpVtbl->Initialize(p,a,b) -#define IDirectDrawSurface3_IsLost(p) (p)->lpVtbl->IsLost(p) -#define IDirectDrawSurface3_Lock(p,a,b,c,d) (p)->lpVtbl->Lock(p,a,b,c,d) -#define IDirectDrawSurface3_ReleaseDC(p,a) (p)->lpVtbl->ReleaseDC(p,a) -#define IDirectDrawSurface3_Restore(p) (p)->lpVtbl->Restore(p) -#define IDirectDrawSurface3_SetClipper(p,a) (p)->lpVtbl->SetClipper(p,a) -#define IDirectDrawSurface3_SetColorKey(p,a,b) (p)->lpVtbl->SetColorKey(p,a,b) -#define IDirectDrawSurface3_SetOverlayPosition(p,a,b) (p)->lpVtbl->SetOverlayPosition(p,a,b) -#define IDirectDrawSurface3_SetPalette(p,a) (p)->lpVtbl->SetPalette(p,a) -#define IDirectDrawSurface3_Unlock(p,b) (p)->lpVtbl->Unlock(p,b) -#define IDirectDrawSurface3_UpdateOverlay(p,a,b,c,d,e) (p)->lpVtbl->UpdateOverlay(p,a,b,c,d,e) -#define IDirectDrawSurface3_UpdateOverlayDisplay(p,a) (p)->lpVtbl->UpdateOverlayDisplay(p,a) -#define IDirectDrawSurface3_UpdateOverlayZOrder(p,a,b) (p)->lpVtbl->UpdateOverlayZOrder(p,a,b) -#define IDirectDrawSurface3_GetDDInterface(p,a) (p)->lpVtbl->GetDDInterface(p,a) -#define IDirectDrawSurface3_PageLock(p,a) (p)->lpVtbl->PageLock(p,a) -#define IDirectDrawSurface3_PageUnlock(p,a) (p)->lpVtbl->PageUnlock(p,a) -#define IDirectDrawSurface3_SetSurfaceDesc(p,a,b) (p)->lpVtbl->SetSurfaceDesc(p,a,b) -#else -#define IDirectDrawSurface3_QueryInterface(p,a,b) (p)->QueryInterface(a,b) -#define IDirectDrawSurface3_AddRef(p) (p)->AddRef() -#define IDirectDrawSurface3_Release(p) (p)->Release() -#define IDirectDrawSurface3_AddAttachedSurface(p,a) (p)->AddAttachedSurface(a) -#define IDirectDrawSurface3_AddOverlayDirtyRect(p,a) (p)->AddOverlayDirtyRect(a) -#define IDirectDrawSurface3_Blt(p,a,b,c,d,e) (p)->Blt(a,b,c,d,e) -#define IDirectDrawSurface3_BltBatch(p,a,b,c) (p)->BltBatch(a,b,c) -#define IDirectDrawSurface3_BltFast(p,a,b,c,d,e) (p)->BltFast(a,b,c,d,e) -#define IDirectDrawSurface3_DeleteAttachedSurface(p,a,b) (p)->DeleteAttachedSurface(a,b) -#define IDirectDrawSurface3_EnumAttachedSurfaces(p,a,b) (p)->EnumAttachedSurfaces(a,b) -#define IDirectDrawSurface3_EnumOverlayZOrders(p,a,b,c) (p)->EnumOverlayZOrders(a,b,c) -#define IDirectDrawSurface3_Flip(p,a,b) (p)->Flip(a,b) -#define IDirectDrawSurface3_GetAttachedSurface(p,a,b) (p)->GetAttachedSurface(a,b) -#define IDirectDrawSurface3_GetBltStatus(p,a) (p)->GetBltStatus(a) -#define IDirectDrawSurface3_GetCaps(p,b) (p)->GetCaps(b) -#define IDirectDrawSurface3_GetClipper(p,a) (p)->GetClipper(a) -#define IDirectDrawSurface3_GetColorKey(p,a,b) (p)->GetColorKey(a,b) -#define IDirectDrawSurface3_GetDC(p,a) (p)->GetDC(a) -#define IDirectDrawSurface3_GetFlipStatus(p,a) (p)->GetFlipStatus(a) -#define IDirectDrawSurface3_GetOverlayPosition(p,a,b) (p)->GetOverlayPosition(a,b) -#define IDirectDrawSurface3_GetPalette(p,a) (p)->GetPalette(a) -#define IDirectDrawSurface3_GetPixelFormat(p,a) (p)->GetPixelFormat(a) -#define IDirectDrawSurface3_GetSurfaceDesc(p,a) (p)->GetSurfaceDesc(a) -#define IDirectDrawSurface3_Initialize(p,a,b) (p)->Initialize(a,b) -#define IDirectDrawSurface3_IsLost(p) (p)->IsLost() -#define IDirectDrawSurface3_Lock(p,a,b,c,d) (p)->Lock(a,b,c,d) -#define IDirectDrawSurface3_ReleaseDC(p,a) (p)->ReleaseDC(a) -#define IDirectDrawSurface3_Restore(p) (p)->Restore() -#define IDirectDrawSurface3_SetClipper(p,a) (p)->SetClipper(a) -#define IDirectDrawSurface3_SetColorKey(p,a,b) (p)->SetColorKey(a,b) -#define IDirectDrawSurface3_SetOverlayPosition(p,a,b) (p)->SetOverlayPosition(a,b) -#define IDirectDrawSurface3_SetPalette(p,a) (p)->SetPalette(a) -#define IDirectDrawSurface3_Unlock(p,b) (p)->Unlock(b) -#define IDirectDrawSurface3_UpdateOverlay(p,a,b,c,d,e) (p)->UpdateOverlay(a,b,c,d,e) -#define IDirectDrawSurface3_UpdateOverlayDisplay(p,a) (p)->UpdateOverlayDisplay(a) -#define IDirectDrawSurface3_UpdateOverlayZOrder(p,a,b) (p)->UpdateOverlayZOrder(a,b) -#define IDirectDrawSurface3_GetDDInterface(p,a) (p)->GetDDInterface(a) -#define IDirectDrawSurface3_PageLock(p,a) (p)->PageLock(a) -#define IDirectDrawSurface3_PageUnlock(p,a) (p)->PageUnlock(a) -#define IDirectDrawSurface3_SetSurfaceDesc(p,a,b) (p)->SetSurfaceDesc(a,b) -#endif - -/* - * IDirectDrawSurface4 and related interfaces - */ -#undef INTERFACE -#define INTERFACE IDirectDrawSurface4 -DECLARE_INTERFACE_( IDirectDrawSurface4, IUnknown ) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID FAR * ppvObj) PURE; - STDMETHOD_(ULONG,AddRef) (THIS) PURE; - STDMETHOD_(ULONG,Release) (THIS) PURE; - /*** IDirectDrawSurface methods ***/ - STDMETHOD(AddAttachedSurface)(THIS_ LPDIRECTDRAWSURFACE4) PURE; - STDMETHOD(AddOverlayDirtyRect)(THIS_ LPRECT) PURE; - STDMETHOD(Blt)(THIS_ LPRECT,LPDIRECTDRAWSURFACE4, LPRECT,DWORD, LPDDBLTFX) PURE; - STDMETHOD(BltBatch)(THIS_ LPDDBLTBATCH, DWORD, DWORD ) PURE; - STDMETHOD(BltFast)(THIS_ DWORD,DWORD,LPDIRECTDRAWSURFACE4, LPRECT,DWORD) PURE; - STDMETHOD(DeleteAttachedSurface)(THIS_ DWORD,LPDIRECTDRAWSURFACE4) PURE; - STDMETHOD(EnumAttachedSurfaces)(THIS_ LPVOID,LPDDENUMSURFACESCALLBACK2) PURE; - STDMETHOD(EnumOverlayZOrders)(THIS_ DWORD,LPVOID,LPDDENUMSURFACESCALLBACK2) PURE; - STDMETHOD(Flip)(THIS_ LPDIRECTDRAWSURFACE4, DWORD) PURE; - STDMETHOD(GetAttachedSurface)(THIS_ LPDDSCAPS2, LPDIRECTDRAWSURFACE4 FAR *) PURE; - STDMETHOD(GetBltStatus)(THIS_ DWORD) PURE; - STDMETHOD(GetCaps)(THIS_ LPDDSCAPS2) PURE; - STDMETHOD(GetClipper)(THIS_ LPDIRECTDRAWCLIPPER FAR*) PURE; - STDMETHOD(GetColorKey)(THIS_ DWORD, LPDDCOLORKEY) PURE; - STDMETHOD(GetDC)(THIS_ HDC FAR *) PURE; - STDMETHOD(GetFlipStatus)(THIS_ DWORD) PURE; - STDMETHOD(GetOverlayPosition)(THIS_ LPLONG, LPLONG ) PURE; - STDMETHOD(GetPalette)(THIS_ LPDIRECTDRAWPALETTE FAR*) PURE; - STDMETHOD(GetPixelFormat)(THIS_ LPDDPIXELFORMAT) PURE; - STDMETHOD(GetSurfaceDesc)(THIS_ LPDDSURFACEDESC2) PURE; - STDMETHOD(Initialize)(THIS_ LPDIRECTDRAW, LPDDSURFACEDESC2) PURE; - STDMETHOD(IsLost)(THIS) PURE; - STDMETHOD(Lock)(THIS_ LPRECT,LPDDSURFACEDESC2,DWORD,HANDLE) PURE; - STDMETHOD(ReleaseDC)(THIS_ HDC) PURE; - STDMETHOD(Restore)(THIS) PURE; - STDMETHOD(SetClipper)(THIS_ LPDIRECTDRAWCLIPPER) PURE; - STDMETHOD(SetColorKey)(THIS_ DWORD, LPDDCOLORKEY) PURE; - STDMETHOD(SetOverlayPosition)(THIS_ LONG, LONG ) PURE; - STDMETHOD(SetPalette)(THIS_ LPDIRECTDRAWPALETTE) PURE; - STDMETHOD(Unlock)(THIS_ LPRECT) PURE; - STDMETHOD(UpdateOverlay)(THIS_ LPRECT, LPDIRECTDRAWSURFACE4,LPRECT,DWORD, LPDDOVERLAYFX) PURE; - STDMETHOD(UpdateOverlayDisplay)(THIS_ DWORD) PURE; - STDMETHOD(UpdateOverlayZOrder)(THIS_ DWORD, LPDIRECTDRAWSURFACE4) PURE; - /*** Added in the v2 interface ***/ - STDMETHOD(GetDDInterface)(THIS_ LPVOID FAR *) PURE; - STDMETHOD(PageLock)(THIS_ DWORD) PURE; - STDMETHOD(PageUnlock)(THIS_ DWORD) PURE; - /*** Added in the v3 interface ***/ - STDMETHOD(SetSurfaceDesc)(THIS_ LPDDSURFACEDESC2, DWORD) PURE; - /*** Added in the v4 interface ***/ - STDMETHOD(SetPrivateData)(THIS_ REFGUID, LPVOID, DWORD, DWORD) PURE; - STDMETHOD(GetPrivateData)(THIS_ REFGUID, LPVOID, LPDWORD) PURE; - STDMETHOD(FreePrivateData)(THIS_ REFGUID) PURE; - STDMETHOD(GetUniquenessValue)(THIS_ LPDWORD) PURE; - STDMETHOD(ChangeUniquenessValue)(THIS) PURE; -}; - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectDrawSurface4_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) -#define IDirectDrawSurface4_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirectDrawSurface4_Release(p) (p)->lpVtbl->Release(p) -#define IDirectDrawSurface4_AddAttachedSurface(p,a) (p)->lpVtbl->AddAttachedSurface(p,a) -#define IDirectDrawSurface4_AddOverlayDirtyRect(p,a) (p)->lpVtbl->AddOverlayDirtyRect(p,a) -#define IDirectDrawSurface4_Blt(p,a,b,c,d,e) (p)->lpVtbl->Blt(p,a,b,c,d,e) -#define IDirectDrawSurface4_BltBatch(p,a,b,c) (p)->lpVtbl->BltBatch(p,a,b,c) -#define IDirectDrawSurface4_BltFast(p,a,b,c,d,e) (p)->lpVtbl->BltFast(p,a,b,c,d,e) -#define IDirectDrawSurface4_DeleteAttachedSurface(p,a,b) (p)->lpVtbl->DeleteAttachedSurface(p,a,b) -#define IDirectDrawSurface4_EnumAttachedSurfaces(p,a,b) (p)->lpVtbl->EnumAttachedSurfaces(p,a,b) -#define IDirectDrawSurface4_EnumOverlayZOrders(p,a,b,c) (p)->lpVtbl->EnumOverlayZOrders(p,a,b,c) -#define IDirectDrawSurface4_Flip(p,a,b) (p)->lpVtbl->Flip(p,a,b) -#define IDirectDrawSurface4_GetAttachedSurface(p,a,b) (p)->lpVtbl->GetAttachedSurface(p,a,b) -#define IDirectDrawSurface4_GetBltStatus(p,a) (p)->lpVtbl->GetBltStatus(p,a) -#define IDirectDrawSurface4_GetCaps(p,b) (p)->lpVtbl->GetCaps(p,b) -#define IDirectDrawSurface4_GetClipper(p,a) (p)->lpVtbl->GetClipper(p,a) -#define IDirectDrawSurface4_GetColorKey(p,a,b) (p)->lpVtbl->GetColorKey(p,a,b) -#define IDirectDrawSurface4_GetDC(p,a) (p)->lpVtbl->GetDC(p,a) -#define IDirectDrawSurface4_GetFlipStatus(p,a) (p)->lpVtbl->GetFlipStatus(p,a) -#define IDirectDrawSurface4_GetOverlayPosition(p,a,b) (p)->lpVtbl->GetOverlayPosition(p,a,b) -#define IDirectDrawSurface4_GetPalette(p,a) (p)->lpVtbl->GetPalette(p,a) -#define IDirectDrawSurface4_GetPixelFormat(p,a) (p)->lpVtbl->GetPixelFormat(p,a) -#define IDirectDrawSurface4_GetSurfaceDesc(p,a) (p)->lpVtbl->GetSurfaceDesc(p,a) -#define IDirectDrawSurface4_Initialize(p,a,b) (p)->lpVtbl->Initialize(p,a,b) -#define IDirectDrawSurface4_IsLost(p) (p)->lpVtbl->IsLost(p) -#define IDirectDrawSurface4_Lock(p,a,b,c,d) (p)->lpVtbl->Lock(p,a,b,c,d) -#define IDirectDrawSurface4_ReleaseDC(p,a) (p)->lpVtbl->ReleaseDC(p,a) -#define IDirectDrawSurface4_Restore(p) (p)->lpVtbl->Restore(p) -#define IDirectDrawSurface4_SetClipper(p,a) (p)->lpVtbl->SetClipper(p,a) -#define IDirectDrawSurface4_SetColorKey(p,a,b) (p)->lpVtbl->SetColorKey(p,a,b) -#define IDirectDrawSurface4_SetOverlayPosition(p,a,b) (p)->lpVtbl->SetOverlayPosition(p,a,b) -#define IDirectDrawSurface4_SetPalette(p,a) (p)->lpVtbl->SetPalette(p,a) -#define IDirectDrawSurface4_Unlock(p,b) (p)->lpVtbl->Unlock(p,b) -#define IDirectDrawSurface4_UpdateOverlay(p,a,b,c,d,e) (p)->lpVtbl->UpdateOverlay(p,a,b,c,d,e) -#define IDirectDrawSurface4_UpdateOverlayDisplay(p,a) (p)->lpVtbl->UpdateOverlayDisplay(p,a) -#define IDirectDrawSurface4_UpdateOverlayZOrder(p,a,b) (p)->lpVtbl->UpdateOverlayZOrder(p,a,b) -#define IDirectDrawSurface4_GetDDInterface(p,a) (p)->lpVtbl->GetDDInterface(p,a) -#define IDirectDrawSurface4_PageLock(p,a) (p)->lpVtbl->PageLock(p,a) -#define IDirectDrawSurface4_PageUnlock(p,a) (p)->lpVtbl->PageUnlock(p,a) -#define IDirectDrawSurface4_SetSurfaceDesc(p,a,b) (p)->lpVtbl->SetSurfaceDesc(p,a,b) -#define IDirectDrawSurface4_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d) -#define IDirectDrawSurface4_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c) -#define IDirectDrawSurface4_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a) -#define IDirectDrawSurface4_GetUniquenessValue(p, a) (p)->lpVtbl->GetUniquenessValue(p, a) -#define IDirectDrawSurface4_ChangeUniquenessValue(p) (p)->lpVtbl->ChangeUniquenessValue(p) -#else -#define IDirectDrawSurface4_QueryInterface(p,a,b) (p)->QueryInterface(a,b) -#define IDirectDrawSurface4_AddRef(p) (p)->AddRef() -#define IDirectDrawSurface4_Release(p) (p)->Release() -#define IDirectDrawSurface4_AddAttachedSurface(p,a) (p)->AddAttachedSurface(a) -#define IDirectDrawSurface4_AddOverlayDirtyRect(p,a) (p)->AddOverlayDirtyRect(a) -#define IDirectDrawSurface4_Blt(p,a,b,c,d,e) (p)->Blt(a,b,c,d,e) -#define IDirectDrawSurface4_BltBatch(p,a,b,c) (p)->BltBatch(a,b,c) -#define IDirectDrawSurface4_BltFast(p,a,b,c,d,e) (p)->BltFast(a,b,c,d,e) -#define IDirectDrawSurface4_DeleteAttachedSurface(p,a,b) (p)->DeleteAttachedSurface(a,b) -#define IDirectDrawSurface4_EnumAttachedSurfaces(p,a,b) (p)->EnumAttachedSurfaces(a,b) -#define IDirectDrawSurface4_EnumOverlayZOrders(p,a,b,c) (p)->EnumOverlayZOrders(a,b,c) -#define IDirectDrawSurface4_Flip(p,a,b) (p)->Flip(a,b) -#define IDirectDrawSurface4_GetAttachedSurface(p,a,b) (p)->GetAttachedSurface(a,b) -#define IDirectDrawSurface4_GetBltStatus(p,a) (p)->GetBltStatus(a) -#define IDirectDrawSurface4_GetCaps(p,b) (p)->GetCaps(b) -#define IDirectDrawSurface4_GetClipper(p,a) (p)->GetClipper(a) -#define IDirectDrawSurface4_GetColorKey(p,a,b) (p)->GetColorKey(a,b) -#define IDirectDrawSurface4_GetDC(p,a) (p)->GetDC(a) -#define IDirectDrawSurface4_GetFlipStatus(p,a) (p)->GetFlipStatus(a) -#define IDirectDrawSurface4_GetOverlayPosition(p,a,b) (p)->GetOverlayPosition(a,b) -#define IDirectDrawSurface4_GetPalette(p,a) (p)->GetPalette(a) -#define IDirectDrawSurface4_GetPixelFormat(p,a) (p)->GetPixelFormat(a) -#define IDirectDrawSurface4_GetSurfaceDesc(p,a) (p)->GetSurfaceDesc(a) -#define IDirectDrawSurface4_Initialize(p,a,b) (p)->Initialize(a,b) -#define IDirectDrawSurface4_IsLost(p) (p)->IsLost() -#define IDirectDrawSurface4_Lock(p,a,b,c,d) (p)->Lock(a,b,c,d) -#define IDirectDrawSurface4_ReleaseDC(p,a) (p)->ReleaseDC(a) -#define IDirectDrawSurface4_Restore(p) (p)->Restore() -#define IDirectDrawSurface4_SetClipper(p,a) (p)->SetClipper(a) -#define IDirectDrawSurface4_SetColorKey(p,a,b) (p)->SetColorKey(a,b) -#define IDirectDrawSurface4_SetOverlayPosition(p,a,b) (p)->SetOverlayPosition(a,b) -#define IDirectDrawSurface4_SetPalette(p,a) (p)->SetPalette(a) -#define IDirectDrawSurface4_Unlock(p,b) (p)->Unlock(b) -#define IDirectDrawSurface4_UpdateOverlay(p,a,b,c,d,e) (p)->UpdateOverlay(a,b,c,d,e) -#define IDirectDrawSurface4_UpdateOverlayDisplay(p,a) (p)->UpdateOverlayDisplay(a) -#define IDirectDrawSurface4_UpdateOverlayZOrder(p,a,b) (p)->UpdateOverlayZOrder(a,b) -#define IDirectDrawSurface4_GetDDInterface(p,a) (p)->GetDDInterface(a) -#define IDirectDrawSurface4_PageLock(p,a) (p)->PageLock(a) -#define IDirectDrawSurface4_PageUnlock(p,a) (p)->PageUnlock(a) -#define IDirectDrawSurface4_SetSurfaceDesc(p,a,b) (p)->SetSurfaceDesc(a,b) -#define IDirectDrawSurface4_SetPrivateData(p,a,b,c,d) (p)->SetPrivateData(a,b,c,d) -#define IDirectDrawSurface4_GetPrivateData(p,a,b,c) (p)->GetPrivateData(a,b,c) -#define IDirectDrawSurface4_FreePrivateData(p,a) (p)->FreePrivateData(a) -#define IDirectDrawSurface4_GetUniquenessValue(p, a) (p)->GetUniquenessValue(a) -#define IDirectDrawSurface4_ChangeUniquenessValue(p) (p)->ChangeUniquenessValue() -#endif - -/* - * IDirectDrawSurface7 and related interfaces - */ -#undef INTERFACE -#define INTERFACE IDirectDrawSurface7 -DECLARE_INTERFACE_( IDirectDrawSurface7, IUnknown ) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID FAR * ppvObj) PURE; - STDMETHOD_(ULONG,AddRef) (THIS) PURE; - STDMETHOD_(ULONG,Release) (THIS) PURE; - /*** IDirectDrawSurface methods ***/ - STDMETHOD(AddAttachedSurface)(THIS_ LPDIRECTDRAWSURFACE7) PURE; - STDMETHOD(AddOverlayDirtyRect)(THIS_ LPRECT) PURE; - STDMETHOD(Blt)(THIS_ LPRECT,LPDIRECTDRAWSURFACE7, LPRECT,DWORD, LPDDBLTFX) PURE; - STDMETHOD(BltBatch)(THIS_ LPDDBLTBATCH, DWORD, DWORD ) PURE; - STDMETHOD(BltFast)(THIS_ DWORD,DWORD,LPDIRECTDRAWSURFACE7, LPRECT,DWORD) PURE; - STDMETHOD(DeleteAttachedSurface)(THIS_ DWORD,LPDIRECTDRAWSURFACE7) PURE; - STDMETHOD(EnumAttachedSurfaces)(THIS_ LPVOID,LPDDENUMSURFACESCALLBACK7) PURE; - STDMETHOD(EnumOverlayZOrders)(THIS_ DWORD,LPVOID,LPDDENUMSURFACESCALLBACK7) PURE; - STDMETHOD(Flip)(THIS_ LPDIRECTDRAWSURFACE7, DWORD) PURE; - STDMETHOD(GetAttachedSurface)(THIS_ LPDDSCAPS2, LPDIRECTDRAWSURFACE7 FAR *) PURE; - STDMETHOD(GetBltStatus)(THIS_ DWORD) PURE; - STDMETHOD(GetCaps)(THIS_ LPDDSCAPS2) PURE; - STDMETHOD(GetClipper)(THIS_ LPDIRECTDRAWCLIPPER FAR*) PURE; - STDMETHOD(GetColorKey)(THIS_ DWORD, LPDDCOLORKEY) PURE; - STDMETHOD(GetDC)(THIS_ HDC FAR *) PURE; - STDMETHOD(GetFlipStatus)(THIS_ DWORD) PURE; - STDMETHOD(GetOverlayPosition)(THIS_ LPLONG, LPLONG ) PURE; - STDMETHOD(GetPalette)(THIS_ LPDIRECTDRAWPALETTE FAR*) PURE; - STDMETHOD(GetPixelFormat)(THIS_ LPDDPIXELFORMAT) PURE; - STDMETHOD(GetSurfaceDesc)(THIS_ LPDDSURFACEDESC2) PURE; - STDMETHOD(Initialize)(THIS_ LPDIRECTDRAW, LPDDSURFACEDESC2) PURE; - STDMETHOD(IsLost)(THIS) PURE; - STDMETHOD(Lock)(THIS_ LPRECT,LPDDSURFACEDESC2,DWORD,HANDLE) PURE; - STDMETHOD(ReleaseDC)(THIS_ HDC) PURE; - STDMETHOD(Restore)(THIS) PURE; - STDMETHOD(SetClipper)(THIS_ LPDIRECTDRAWCLIPPER) PURE; - STDMETHOD(SetColorKey)(THIS_ DWORD, LPDDCOLORKEY) PURE; - STDMETHOD(SetOverlayPosition)(THIS_ LONG, LONG ) PURE; - STDMETHOD(SetPalette)(THIS_ LPDIRECTDRAWPALETTE) PURE; - STDMETHOD(Unlock)(THIS_ LPRECT) PURE; - STDMETHOD(UpdateOverlay)(THIS_ LPRECT, LPDIRECTDRAWSURFACE7,LPRECT,DWORD, LPDDOVERLAYFX) PURE; - STDMETHOD(UpdateOverlayDisplay)(THIS_ DWORD) PURE; - STDMETHOD(UpdateOverlayZOrder)(THIS_ DWORD, LPDIRECTDRAWSURFACE7) PURE; - /*** Added in the v2 interface ***/ - STDMETHOD(GetDDInterface)(THIS_ LPVOID FAR *) PURE; - STDMETHOD(PageLock)(THIS_ DWORD) PURE; - STDMETHOD(PageUnlock)(THIS_ DWORD) PURE; - /*** Added in the v3 interface ***/ - STDMETHOD(SetSurfaceDesc)(THIS_ LPDDSURFACEDESC2, DWORD) PURE; - /*** Added in the v4 interface ***/ - STDMETHOD(SetPrivateData)(THIS_ REFGUID, LPVOID, DWORD, DWORD) PURE; - STDMETHOD(GetPrivateData)(THIS_ REFGUID, LPVOID, LPDWORD) PURE; - STDMETHOD(FreePrivateData)(THIS_ REFGUID) PURE; - STDMETHOD(GetUniquenessValue)(THIS_ LPDWORD) PURE; - STDMETHOD(ChangeUniquenessValue)(THIS) PURE; - /*** Moved Texture7 methods here ***/ - STDMETHOD(SetPriority)(THIS_ DWORD) PURE; - STDMETHOD(GetPriority)(THIS_ LPDWORD) PURE; - STDMETHOD(SetLOD)(THIS_ DWORD) PURE; - STDMETHOD(GetLOD)(THIS_ LPDWORD) PURE; -}; - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectDrawSurface7_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) -#define IDirectDrawSurface7_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirectDrawSurface7_Release(p) (p)->lpVtbl->Release(p) -#define IDirectDrawSurface7_AddAttachedSurface(p,a) (p)->lpVtbl->AddAttachedSurface(p,a) -#define IDirectDrawSurface7_AddOverlayDirtyRect(p,a) (p)->lpVtbl->AddOverlayDirtyRect(p,a) -#define IDirectDrawSurface7_Blt(p,a,b,c,d,e) (p)->lpVtbl->Blt(p,a,b,c,d,e) -#define IDirectDrawSurface7_BltBatch(p,a,b,c) (p)->lpVtbl->BltBatch(p,a,b,c) -#define IDirectDrawSurface7_BltFast(p,a,b,c,d,e) (p)->lpVtbl->BltFast(p,a,b,c,d,e) -#define IDirectDrawSurface7_DeleteAttachedSurface(p,a,b) (p)->lpVtbl->DeleteAttachedSurface(p,a,b) -#define IDirectDrawSurface7_EnumAttachedSurfaces(p,a,b) (p)->lpVtbl->EnumAttachedSurfaces(p,a,b) -#define IDirectDrawSurface7_EnumOverlayZOrders(p,a,b,c) (p)->lpVtbl->EnumOverlayZOrders(p,a,b,c) -#define IDirectDrawSurface7_Flip(p,a,b) (p)->lpVtbl->Flip(p,a,b) -#define IDirectDrawSurface7_GetAttachedSurface(p,a,b) (p)->lpVtbl->GetAttachedSurface(p,a,b) -#define IDirectDrawSurface7_GetBltStatus(p,a) (p)->lpVtbl->GetBltStatus(p,a) -#define IDirectDrawSurface7_GetCaps(p,b) (p)->lpVtbl->GetCaps(p,b) -#define IDirectDrawSurface7_GetClipper(p,a) (p)->lpVtbl->GetClipper(p,a) -#define IDirectDrawSurface7_GetColorKey(p,a,b) (p)->lpVtbl->GetColorKey(p,a,b) -#define IDirectDrawSurface7_GetDC(p,a) (p)->lpVtbl->GetDC(p,a) -#define IDirectDrawSurface7_GetFlipStatus(p,a) (p)->lpVtbl->GetFlipStatus(p,a) -#define IDirectDrawSurface7_GetOverlayPosition(p,a,b) (p)->lpVtbl->GetOverlayPosition(p,a,b) -#define IDirectDrawSurface7_GetPalette(p,a) (p)->lpVtbl->GetPalette(p,a) -#define IDirectDrawSurface7_GetPixelFormat(p,a) (p)->lpVtbl->GetPixelFormat(p,a) -#define IDirectDrawSurface7_GetSurfaceDesc(p,a) (p)->lpVtbl->GetSurfaceDesc(p,a) -#define IDirectDrawSurface7_Initialize(p,a,b) (p)->lpVtbl->Initialize(p,a,b) -#define IDirectDrawSurface7_IsLost(p) (p)->lpVtbl->IsLost(p) -#define IDirectDrawSurface7_Lock(p,a,b,c,d) (p)->lpVtbl->Lock(p,a,b,c,d) -#define IDirectDrawSurface7_ReleaseDC(p,a) (p)->lpVtbl->ReleaseDC(p,a) -#define IDirectDrawSurface7_Restore(p) (p)->lpVtbl->Restore(p) -#define IDirectDrawSurface7_SetClipper(p,a) (p)->lpVtbl->SetClipper(p,a) -#define IDirectDrawSurface7_SetColorKey(p,a,b) (p)->lpVtbl->SetColorKey(p,a,b) -#define IDirectDrawSurface7_SetOverlayPosition(p,a,b) (p)->lpVtbl->SetOverlayPosition(p,a,b) -#define IDirectDrawSurface7_SetPalette(p,a) (p)->lpVtbl->SetPalette(p,a) -#define IDirectDrawSurface7_Unlock(p,b) (p)->lpVtbl->Unlock(p,b) -#define IDirectDrawSurface7_UpdateOverlay(p,a,b,c,d,e) (p)->lpVtbl->UpdateOverlay(p,a,b,c,d,e) -#define IDirectDrawSurface7_UpdateOverlayDisplay(p,a) (p)->lpVtbl->UpdateOverlayDisplay(p,a) -#define IDirectDrawSurface7_UpdateOverlayZOrder(p,a,b) (p)->lpVtbl->UpdateOverlayZOrder(p,a,b) -#define IDirectDrawSurface7_GetDDInterface(p,a) (p)->lpVtbl->GetDDInterface(p,a) -#define IDirectDrawSurface7_PageLock(p,a) (p)->lpVtbl->PageLock(p,a) -#define IDirectDrawSurface7_PageUnlock(p,a) (p)->lpVtbl->PageUnlock(p,a) -#define IDirectDrawSurface7_SetSurfaceDesc(p,a,b) (p)->lpVtbl->SetSurfaceDesc(p,a,b) -#define IDirectDrawSurface7_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d) -#define IDirectDrawSurface7_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c) -#define IDirectDrawSurface7_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a) -#define IDirectDrawSurface7_GetUniquenessValue(p, a) (p)->lpVtbl->GetUniquenessValue(p, a) -#define IDirectDrawSurface7_ChangeUniquenessValue(p) (p)->lpVtbl->ChangeUniquenessValue(p) -#define IDirectDrawSurface7_SetPriority(p,a) (p)->lpVtbl->SetPriority(p,a) -#define IDirectDrawSurface7_GetPriority(p,a) (p)->lpVtbl->GetPriority(p,a) -#define IDirectDrawSurface7_SetLOD(p,a) (p)->lpVtbl->SetLOD(p,a) -#define IDirectDrawSurface7_GetLOD(p,a) (p)->lpVtbl->GetLOD(p,a) -#else -#define IDirectDrawSurface7_QueryInterface(p,a,b) (p)->QueryInterface(a,b) -#define IDirectDrawSurface7_AddRef(p) (p)->AddRef() -#define IDirectDrawSurface7_Release(p) (p)->Release() -#define IDirectDrawSurface7_AddAttachedSurface(p,a) (p)->AddAttachedSurface(a) -#define IDirectDrawSurface7_AddOverlayDirtyRect(p,a) (p)->AddOverlayDirtyRect(a) -#define IDirectDrawSurface7_Blt(p,a,b,c,d,e) (p)->Blt(a,b,c,d,e) -#define IDirectDrawSurface7_BltBatch(p,a,b,c) (p)->BltBatch(a,b,c) -#define IDirectDrawSurface7_BltFast(p,a,b,c,d,e) (p)->BltFast(a,b,c,d,e) -#define IDirectDrawSurface7_DeleteAttachedSurface(p,a,b) (p)->DeleteAttachedSurface(a,b) -#define IDirectDrawSurface7_EnumAttachedSurfaces(p,a,b) (p)->EnumAttachedSurfaces(a,b) -#define IDirectDrawSurface7_EnumOverlayZOrders(p,a,b,c) (p)->EnumOverlayZOrders(a,b,c) -#define IDirectDrawSurface7_Flip(p,a,b) (p)->Flip(a,b) -#define IDirectDrawSurface7_GetAttachedSurface(p,a,b) (p)->GetAttachedSurface(a,b) -#define IDirectDrawSurface7_GetBltStatus(p,a) (p)->GetBltStatus(a) -#define IDirectDrawSurface7_GetCaps(p,b) (p)->GetCaps(b) -#define IDirectDrawSurface7_GetClipper(p,a) (p)->GetClipper(a) -#define IDirectDrawSurface7_GetColorKey(p,a,b) (p)->GetColorKey(a,b) -#define IDirectDrawSurface7_GetDC(p,a) (p)->GetDC(a) -#define IDirectDrawSurface7_GetFlipStatus(p,a) (p)->GetFlipStatus(a) -#define IDirectDrawSurface7_GetOverlayPosition(p,a,b) (p)->GetOverlayPosition(a,b) -#define IDirectDrawSurface7_GetPalette(p,a) (p)->GetPalette(a) -#define IDirectDrawSurface7_GetPixelFormat(p,a) (p)->GetPixelFormat(a) -#define IDirectDrawSurface7_GetSurfaceDesc(p,a) (p)->GetSurfaceDesc(a) -#define IDirectDrawSurface7_Initialize(p,a,b) (p)->Initialize(a,b) -#define IDirectDrawSurface7_IsLost(p) (p)->IsLost() -#define IDirectDrawSurface7_Lock(p,a,b,c,d) (p)->Lock(a,b,c,d) -#define IDirectDrawSurface7_ReleaseDC(p,a) (p)->ReleaseDC(a) -#define IDirectDrawSurface7_Restore(p) (p)->Restore() -#define IDirectDrawSurface7_SetClipper(p,a) (p)->SetClipper(a) -#define IDirectDrawSurface7_SetColorKey(p,a,b) (p)->SetColorKey(a,b) -#define IDirectDrawSurface7_SetOverlayPosition(p,a,b) (p)->SetOverlayPosition(a,b) -#define IDirectDrawSurface7_SetPalette(p,a) (p)->SetPalette(a) -#define IDirectDrawSurface7_Unlock(p,b) (p)->Unlock(b) -#define IDirectDrawSurface7_UpdateOverlay(p,a,b,c,d,e) (p)->UpdateOverlay(a,b,c,d,e) -#define IDirectDrawSurface7_UpdateOverlayDisplay(p,a) (p)->UpdateOverlayDisplay(a) -#define IDirectDrawSurface7_UpdateOverlayZOrder(p,a,b) (p)->UpdateOverlayZOrder(a,b) -#define IDirectDrawSurface7_GetDDInterface(p,a) (p)->GetDDInterface(a) -#define IDirectDrawSurface7_PageLock(p,a) (p)->PageLock(a) -#define IDirectDrawSurface7_PageUnlock(p,a) (p)->PageUnlock(a) -#define IDirectDrawSurface7_SetSurfaceDesc(p,a,b) (p)->SetSurfaceDesc(a,b) -#define IDirectDrawSurface7_SetPrivateData(p,a,b,c,d) (p)->SetPrivateData(a,b,c,d) -#define IDirectDrawSurface7_GetPrivateData(p,a,b,c) (p)->GetPrivateData(a,b,c) -#define IDirectDrawSurface7_FreePrivateData(p,a) (p)->FreePrivateData(a) -#define IDirectDrawSurface7_GetUniquenessValue(p, a) (p)->GetUniquenessValue(a) -#define IDirectDrawSurface7_ChangeUniquenessValue(p) (p)->ChangeUniquenessValue() -#define IDirectDrawSurface7_SetPriority(p,a) (p)->SetPriority(a) -#define IDirectDrawSurface7_GetPriority(p,a) (p)->GetPriority(a) -#define IDirectDrawSurface7_SetLOD(p,a) (p)->SetLOD(a) -#define IDirectDrawSurface7_GetLOD(p,a) (p)->GetLOD(a) -#endif - - -/* - * IDirectDrawColorControl - */ -#if defined( _WIN32 ) && !defined( _NO_COM ) -#undef INTERFACE -#define INTERFACE IDirectDrawColorControl -DECLARE_INTERFACE_( IDirectDrawColorControl, IUnknown ) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID FAR * ppvObj) PURE; - STDMETHOD_(ULONG,AddRef) (THIS) PURE; - STDMETHOD_(ULONG,Release) (THIS) PURE; - /*** IDirectDrawColorControl methods ***/ - STDMETHOD(GetColorControls)(THIS_ LPDDCOLORCONTROL) PURE; - STDMETHOD(SetColorControls)(THIS_ LPDDCOLORCONTROL) PURE; -}; - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectDrawColorControl_QueryInterface(p, a, b) (p)->lpVtbl->QueryInterface(p, a, b) -#define IDirectDrawColorControl_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirectDrawColorControl_Release(p) (p)->lpVtbl->Release(p) -#define IDirectDrawColorControl_GetColorControls(p, a) (p)->lpVtbl->GetColorControls(p, a) -#define IDirectDrawColorControl_SetColorControls(p, a) (p)->lpVtbl->SetColorControls(p, a) -#else -#define IDirectDrawColorControl_QueryInterface(p, a, b) (p)->QueryInterface(a, b) -#define IDirectDrawColorControl_AddRef(p) (p)->AddRef() -#define IDirectDrawColorControl_Release(p) (p)->Release() -#define IDirectDrawColorControl_GetColorControls(p, a) (p)->GetColorControls(a) -#define IDirectDrawColorControl_SetColorControls(p, a) (p)->SetColorControls(a) -#endif - -#endif - - -/* - * IDirectDrawGammaControl - */ -#if defined( _WIN32 ) && !defined( _NO_COM ) -#undef INTERFACE -#define INTERFACE IDirectDrawGammaControl -DECLARE_INTERFACE_( IDirectDrawGammaControl, IUnknown ) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID FAR * ppvObj) PURE; - STDMETHOD_(ULONG,AddRef) (THIS) PURE; - STDMETHOD_(ULONG,Release) (THIS) PURE; - /*** IDirectDrawGammaControl methods ***/ - STDMETHOD(GetGammaRamp)(THIS_ DWORD, LPDDGAMMARAMP) PURE; - STDMETHOD(SetGammaRamp)(THIS_ DWORD, LPDDGAMMARAMP) PURE; -}; - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectDrawGammaControl_QueryInterface(p, a, b) (p)->lpVtbl->QueryInterface(p, a, b) -#define IDirectDrawGammaControl_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirectDrawGammaControl_Release(p) (p)->lpVtbl->Release(p) -#define IDirectDrawGammaControl_GetGammaRamp(p, a, b) (p)->lpVtbl->GetGammaRamp(p, a, b) -#define IDirectDrawGammaControl_SetGammaRamp(p, a, b) (p)->lpVtbl->SetGammaRamp(p, a, b) -#else -#define IDirectDrawGammaControl_QueryInterface(p, a, b) (p)->QueryInterface(a, b) -#define IDirectDrawGammaControl_AddRef(p) (p)->AddRef() -#define IDirectDrawGammaControl_Release(p) (p)->Release() -#define IDirectDrawGammaControl_GetGammaRamp(p, a, b) (p)->GetGammaRamp(a, b) -#define IDirectDrawGammaControl_SetGammaRamp(p, a, b) (p)->SetGammaRamp(a, b) -#endif - -#endif - - - -#endif - - -/* - * DDSURFACEDESC - */ -typedef struct _DDSURFACEDESC -{ - DWORD dwSize; // size of the DDSURFACEDESC structure - DWORD dwFlags; // determines what fields are valid - DWORD dwHeight; // height of surface to be created - DWORD dwWidth; // width of input surface - union - { - LONG lPitch; // distance to start of next line (return value only) - DWORD dwLinearSize; // Formless late-allocated optimized surface size - } DUMMYUNIONNAMEN(1); - DWORD dwBackBufferCount; // number of back buffers requested - union - { - DWORD dwMipMapCount; // number of mip-map levels requested - DWORD dwZBufferBitDepth; // depth of Z buffer requested - DWORD dwRefreshRate; // refresh rate (used when display mode is described) - } DUMMYUNIONNAMEN(2); - DWORD dwAlphaBitDepth; // depth of alpha buffer requested - DWORD dwReserved; // reserved - LPVOID lpSurface; // pointer to the associated surface memory - DDCOLORKEY ddckCKDestOverlay; // color key for destination overlay use - DDCOLORKEY ddckCKDestBlt; // color key for destination blt use - DDCOLORKEY ddckCKSrcOverlay; // color key for source overlay use - DDCOLORKEY ddckCKSrcBlt; // color key for source blt use - DDPIXELFORMAT ddpfPixelFormat; // pixel format description of the surface - DDSCAPS ddsCaps; // direct draw surface capabilities -} DDSURFACEDESC; - -/* - * DDSURFACEDESC2 - */ -typedef struct _DDSURFACEDESC2 -{ - DWORD dwSize; // size of the DDSURFACEDESC structure - DWORD dwFlags; // determines what fields are valid - DWORD dwHeight; // height of surface to be created - DWORD dwWidth; // width of input surface - union - { - LONG lPitch; // distance to start of next line (return value only) - DWORD dwLinearSize; // Formless late-allocated optimized surface size - } DUMMYUNIONNAMEN(1); - union - { - DWORD dwBackBufferCount; // number of back buffers requested - DWORD dwDepth; // the depth if this is a volume texture - } DUMMYUNIONNAMEN(5); - union - { - DWORD dwMipMapCount; // number of mip-map levels requestde - // dwZBufferBitDepth removed, use ddpfPixelFormat one instead - DWORD dwRefreshRate; // refresh rate (used when display mode is described) - DWORD dwSrcVBHandle; // The source used in VB::Optimize - } DUMMYUNIONNAMEN(2); - DWORD dwAlphaBitDepth; // depth of alpha buffer requested - DWORD dwReserved; // reserved - LPVOID lpSurface; // pointer to the associated surface memory - union - { - DDCOLORKEY ddckCKDestOverlay; // color key for destination overlay use - DWORD dwEmptyFaceColor; // Physical color for empty cubemap faces - } DUMMYUNIONNAMEN(3); - DDCOLORKEY ddckCKDestBlt; // color key for destination blt use - DDCOLORKEY ddckCKSrcOverlay; // color key for source overlay use - DDCOLORKEY ddckCKSrcBlt; // color key for source blt use - union - { - DDPIXELFORMAT ddpfPixelFormat; // pixel format description of the surface - DWORD dwFVF; // vertex format description of vertex buffers - } DUMMYUNIONNAMEN(4); - DDSCAPS2 ddsCaps; // direct draw surface capabilities - DWORD dwTextureStage; // stage in multitexture cascade -} DDSURFACEDESC2; - -/* - * ddsCaps field is valid. - */ -#define DDSD_CAPS 0x00000001l // default - -/* - * dwHeight field is valid. - */ -#define DDSD_HEIGHT 0x00000002l - -/* - * dwWidth field is valid. - */ -#define DDSD_WIDTH 0x00000004l - -/* - * lPitch is valid. - */ -#define DDSD_PITCH 0x00000008l - -/* - * dwBackBufferCount is valid. - */ -#define DDSD_BACKBUFFERCOUNT 0x00000020l - -/* - * dwZBufferBitDepth is valid. (shouldnt be used in DDSURFACEDESC2) - */ -#define DDSD_ZBUFFERBITDEPTH 0x00000040l - -/* - * dwAlphaBitDepth is valid. - */ -#define DDSD_ALPHABITDEPTH 0x00000080l - - -/* - * lpSurface is valid. - */ -#define DDSD_LPSURFACE 0x00000800l - -/* - * ddpfPixelFormat is valid. - */ -#define DDSD_PIXELFORMAT 0x00001000l - -/* - * ddckCKDestOverlay is valid. - */ -#define DDSD_CKDESTOVERLAY 0x00002000l - -/* - * ddckCKDestBlt is valid. - */ -#define DDSD_CKDESTBLT 0x00004000l - -/* - * ddckCKSrcOverlay is valid. - */ -#define DDSD_CKSRCOVERLAY 0x00008000l - -/* - * ddckCKSrcBlt is valid. - */ -#define DDSD_CKSRCBLT 0x00010000l - -/* - * dwMipMapCount is valid. - */ -#define DDSD_MIPMAPCOUNT 0x00020000l - - /* - * dwRefreshRate is valid - */ -#define DDSD_REFRESHRATE 0x00040000l - -/* - * dwLinearSize is valid - */ -#define DDSD_LINEARSIZE 0x00080000l - -/* - * dwTextureStage is valid - */ -#define DDSD_TEXTURESTAGE 0x00100000l -/* - * dwFVF is valid - */ -#define DDSD_FVF 0x00200000l -/* - * dwSrcVBHandle is valid - */ -#define DDSD_SRCVBHANDLE 0x00400000l - -/* - * dwDepth is valid - */ -#define DDSD_DEPTH 0x00800000l - -/* - * All input fields are valid. - */ -#define DDSD_ALL 0x00fff9eel - -/* - * DDOPTSURFACEDESC - */ -typedef struct _DDOPTSURFACEDESC -{ - DWORD dwSize; // size of the DDOPTSURFACEDESC structure - DWORD dwFlags; // determines what fields are valid - DDSCAPS2 ddSCaps; // Common caps like: Memory type - DDOSCAPS ddOSCaps; // Common caps like: Memory type - GUID guid; // Compression technique GUID - DWORD dwCompressionRatio; // Compression ratio -} DDOPTSURFACEDESC; - -/* - * guid field is valid. - */ -#define DDOSD_GUID 0x00000001l - -/* - * dwCompressionRatio field is valid. - */ -#define DDOSD_COMPRESSION_RATIO 0x00000002l - -/* - * ddSCaps field is valid. - */ -#define DDOSD_SCAPS 0x00000004l - -/* - * ddOSCaps field is valid. - */ -#define DDOSD_OSCAPS 0x00000008l - -/* - * All input fields are valid. - */ -#define DDOSD_ALL 0x0000000fl - -/* - * The surface's optimized pixelformat is compressed - */ -#define DDOSDCAPS_OPTCOMPRESSED 0x00000001l - -/* - * The surface's optimized pixelformat is reordered - */ -#define DDOSDCAPS_OPTREORDERED 0x00000002l - -/* - * The opt surface is a monolithic mipmap - */ -#define DDOSDCAPS_MONOLITHICMIPMAP 0x00000004l - -/* - * The valid Surf caps: - * #define DDSCAPS_SYSTEMMEMORY 0x00000800l - * #define DDSCAPS_VIDEOMEMORY 0x00004000l - * #define DDSCAPS_LOCALVIDMEM 0x10000000l - * #define DDSCAPS_NONLOCALVIDMEM 0x20000000l - */ -#define DDOSDCAPS_VALIDSCAPS 0x30004800l - -/* - * The valid OptSurf caps - */ -#define DDOSDCAPS_VALIDOSCAPS 0x00000007l - - -/* - * DDCOLORCONTROL - */ -typedef struct _DDCOLORCONTROL -{ - DWORD dwSize; - DWORD dwFlags; - LONG lBrightness; - LONG lContrast; - LONG lHue; - LONG lSaturation; - LONG lSharpness; - LONG lGamma; - LONG lColorEnable; - DWORD dwReserved1; -} DDCOLORCONTROL; - - -/* - * lBrightness field is valid. - */ -#define DDCOLOR_BRIGHTNESS 0x00000001l - -/* - * lContrast field is valid. - */ -#define DDCOLOR_CONTRAST 0x00000002l - -/* - * lHue field is valid. - */ -#define DDCOLOR_HUE 0x00000004l - -/* - * lSaturation field is valid. - */ -#define DDCOLOR_SATURATION 0x00000008l - -/* - * lSharpness field is valid. - */ -#define DDCOLOR_SHARPNESS 0x00000010l - -/* - * lGamma field is valid. - */ -#define DDCOLOR_GAMMA 0x00000020l - -/* - * lColorEnable field is valid. - */ -#define DDCOLOR_COLORENABLE 0x00000040l - - - -/*============================================================================ - * - * Direct Draw Capability Flags - * - * These flags are used to describe the capabilities of a given Surface. - * All flags are bit flags. - * - *==========================================================================*/ - -/**************************************************************************** - * - * DIRECTDRAWSURFACE CAPABILITY FLAGS - * - ****************************************************************************/ - -/* - * This bit is reserved. It should not be specified. - */ -#define DDSCAPS_RESERVED1 0x00000001l - -/* - * Indicates that this surface contains alpha-only information. - * (To determine if a surface is RGBA/YUVA, the pixel format must be - * interrogated.) - */ -#define DDSCAPS_ALPHA 0x00000002l - -/* - * Indicates that this surface is a backbuffer. It is generally - * set by CreateSurface when the DDSCAPS_FLIP capability bit is set. - * It indicates that this surface is THE back buffer of a surface - * flipping structure. DirectDraw supports N surfaces in a - * surface flipping structure. Only the surface that immediately - * precedeces the DDSCAPS_FRONTBUFFER has this capability bit set. - * The other surfaces are identified as back buffers by the presence - * of the DDSCAPS_FLIP capability, their attachment order, and the - * absence of the DDSCAPS_FRONTBUFFER and DDSCAPS_BACKBUFFER - * capabilities. The bit is sent to CreateSurface when a standalone - * back buffer is being created. This surface could be attached to - * a front buffer and/or back buffers to form a flipping surface - * structure after the CreateSurface call. See AddAttachments for - * a detailed description of the behaviors in this case. - */ -#define DDSCAPS_BACKBUFFER 0x00000004l - -/* - * Indicates a complex surface structure is being described. A - * complex surface structure results in the creation of more than - * one surface. The additional surfaces are attached to the root - * surface. The complex structure can only be destroyed by - * destroying the root. - */ -#define DDSCAPS_COMPLEX 0x00000008l - -/* - * Indicates that this surface is a part of a surface flipping structure. - * When it is passed to CreateSurface the DDSCAPS_FRONTBUFFER and - * DDSCAP_BACKBUFFER bits are not set. They are set by CreateSurface - * on the resulting creations. The dwBackBufferCount field in the - * DDSURFACEDESC structure must be set to at least 1 in order for - * the CreateSurface call to succeed. The DDSCAPS_COMPLEX capability - * must always be set with creating multiple surfaces through CreateSurface. - */ -#define DDSCAPS_FLIP 0x00000010l - -/* - * Indicates that this surface is THE front buffer of a surface flipping - * structure. It is generally set by CreateSurface when the DDSCAPS_FLIP - * capability bit is set. - * If this capability is sent to CreateSurface then a standalonw front buffer - * is created. This surface will not have the DDSCAPS_FLIP capability. - * It can be attached to other back buffers to form a flipping structure. - * See AddAttachments for a detailed description of the behaviors in this - * case. - */ -#define DDSCAPS_FRONTBUFFER 0x00000020l - -/* - * Indicates that this surface is any offscreen surface that is not an overlay, - * texture, zbuffer, front buffer, back buffer, or alpha surface. It is used - * to identify plain vanilla surfaces. - */ -#define DDSCAPS_OFFSCREENPLAIN 0x00000040l - -/* - * Indicates that this surface is an overlay. It may or may not be directly visible - * depending on whether or not it is currently being overlayed onto the primary - * surface. DDSCAPS_VISIBLE can be used to determine whether or not it is being - * overlayed at the moment. - */ -#define DDSCAPS_OVERLAY 0x00000080l - -/* - * Indicates that unique DirectDrawPalette objects can be created and - * attached to this surface. - */ -#define DDSCAPS_PALETTE 0x00000100l - -/* - * Indicates that this surface is the primary surface. The primary - * surface represents what the user is seeing at the moment. - */ -#define DDSCAPS_PRIMARYSURFACE 0x00000200l - - -/* - * This flag used to be DDSCAPS_PRIMARYSURFACELEFT, which is now - * obsolete. - */ -#define DDSCAPS_RESERVED3 0x00000400l -#define DDSCAPS_PRIMARYSURFACELEFT 0x00000000l - -/* - * Indicates that this surface memory was allocated in system memory - */ -#define DDSCAPS_SYSTEMMEMORY 0x00000800l - -/* - * Indicates that this surface can be used as a 3D texture. It does not - * indicate whether or not the surface is being used for that purpose. - */ -#define DDSCAPS_TEXTURE 0x00001000l - -/* - * Indicates that a surface may be a destination for 3D rendering. This - * bit must be set in order to query for a Direct3D Device Interface - * from this surface. - */ -#define DDSCAPS_3DDEVICE 0x00002000l - -/* - * Indicates that this surface exists in video memory. - */ -#define DDSCAPS_VIDEOMEMORY 0x00004000l - -/* - * Indicates that changes made to this surface are immediately visible. - * It is always set for the primary surface and is set for overlays while - * they are being overlayed and texture maps while they are being textured. - */ -#define DDSCAPS_VISIBLE 0x00008000l - -/* - * Indicates that only writes are permitted to the surface. Read accesses - * from the surface may or may not generate a protection fault, but the - * results of a read from this surface will not be meaningful. READ ONLY. - */ -#define DDSCAPS_WRITEONLY 0x00010000l - -/* - * Indicates that this surface is a z buffer. A z buffer does not contain - * displayable information. Instead it contains bit depth information that is - * used to determine which pixels are visible and which are obscured. - */ -#define DDSCAPS_ZBUFFER 0x00020000l - -/* - * Indicates surface will have a DC associated long term - */ -#define DDSCAPS_OWNDC 0x00040000l - -/* - * Indicates surface should be able to receive live video - */ -#define DDSCAPS_LIVEVIDEO 0x00080000l - -/* - * Indicates surface should be able to have a stream decompressed - * to it by the hardware. - */ -#define DDSCAPS_HWCODEC 0x00100000l - -/* - * Surface is a ModeX surface. - * - */ -#define DDSCAPS_MODEX 0x00200000l - -/* - * Indicates surface is one level of a mip-map. This surface will - * be attached to other DDSCAPS_MIPMAP surfaces to form the mip-map. - * This can be done explicitly, by creating a number of surfaces and - * attaching them with AddAttachedSurface or by implicitly by CreateSurface. - * If this bit is set then DDSCAPS_TEXTURE must also be set. - */ -#define DDSCAPS_MIPMAP 0x00400000l - -/* - * This bit is reserved. It should not be specified. - */ -#define DDSCAPS_RESERVED2 0x00800000l - - -/* - * Indicates that memory for the surface is not allocated until the surface - * is loaded (via the Direct3D texture Load() function). - */ -#define DDSCAPS_ALLOCONLOAD 0x04000000l - -/* - * Indicates that the surface will recieve data from a video port. - */ -#define DDSCAPS_VIDEOPORT 0x08000000l - -/* - * Indicates that a video memory surface is resident in true, local video - * memory rather than non-local video memory. If this flag is specified then - * so must DDSCAPS_VIDEOMEMORY. This flag is mutually exclusive with - * DDSCAPS_NONLOCALVIDMEM. - */ -#define DDSCAPS_LOCALVIDMEM 0x10000000l - -/* - * Indicates that a video memory surface is resident in non-local video - * memory rather than true, local video memory. If this flag is specified - * then so must DDSCAPS_VIDEOMEMORY. This flag is mutually exclusive with - * DDSCAPS_LOCALVIDMEM. - */ -#define DDSCAPS_NONLOCALVIDMEM 0x20000000l - -/* - * Indicates that this surface is a standard VGA mode surface, and not a - * ModeX surface. (This flag will never be set in combination with the - * DDSCAPS_MODEX flag). - */ -#define DDSCAPS_STANDARDVGAMODE 0x40000000l - -/* - * Indicates that this surface will be an optimized surface. This flag is - * currently only valid in conjunction with the DDSCAPS_TEXTURE flag. The surface - * will be created without any underlying video memory until loaded. - */ -#define DDSCAPS_OPTIMIZED 0x80000000l - - - -/* - * This bit is reserved - */ -#define DDSCAPS2_RESERVED4 0x00000002L -#define DDSCAPS2_HARDWAREDEINTERLACE 0x00000000L - -/* - * Indicates to the driver that this surface will be locked very frequently - * (for procedural textures, dynamic lightmaps, etc). Surfaces with this cap - * set must also have DDSCAPS_TEXTURE. This cap cannot be used with - * DDSCAPS2_HINTSTATIC and DDSCAPS2_OPAQUE. - */ -#define DDSCAPS2_HINTDYNAMIC 0x00000004L - -/* - * Indicates to the driver that this surface can be re-ordered/retiled on - * load. This operation will not change the size of the texture. It is - * relatively fast and symmetrical, since the application may lock these - * bits (although it will take a performance hit when doing so). Surfaces - * with this cap set must also have DDSCAPS_TEXTURE. This cap cannot be - * used with DDSCAPS2_HINTDYNAMIC and DDSCAPS2_OPAQUE. - */ -#define DDSCAPS2_HINTSTATIC 0x00000008L - -/* - * Indicates that the client would like this texture surface to be managed by the - * DirectDraw/Direct3D runtime. Surfaces with this cap set must also have - * DDSCAPS_TEXTURE set. - */ -#define DDSCAPS2_TEXTUREMANAGE 0x00000010L - -/* - * These bits are reserved for internal use */ -#define DDSCAPS2_RESERVED1 0x00000020L -#define DDSCAPS2_RESERVED2 0x00000040L - -/* - * Indicates to the driver that this surface will never be locked again. - * The driver is free to optimize this surface via retiling and actual compression. - * All calls to Lock() or Blts from this surface will fail. Surfaces with this - * cap set must also have DDSCAPS_TEXTURE. This cap cannot be used with - * DDSCAPS2_HINTDYNAMIC and DDSCAPS2_HINTSTATIC. - */ -#define DDSCAPS2_OPAQUE 0x00000080L - -/* - * Applications should set this bit at CreateSurface time to indicate that they - * intend to use antialiasing. Only valid if DDSCAPS_3DDEVICE is also set. - */ -#define DDSCAPS2_HINTANTIALIASING 0x00000100L - - -/* - * This flag is used at CreateSurface time to indicate that this set of - * surfaces is a cubic environment map - */ -#define DDSCAPS2_CUBEMAP 0x00000200L - -/* - * These flags preform two functions: - * - At CreateSurface time, they define which of the six cube faces are - * required by the application. - * - After creation, each face in the cubemap will have exactly one of these - * bits set. - */ -#define DDSCAPS2_CUBEMAP_POSITIVEX 0x00000400L -#define DDSCAPS2_CUBEMAP_NEGATIVEX 0x00000800L -#define DDSCAPS2_CUBEMAP_POSITIVEY 0x00001000L -#define DDSCAPS2_CUBEMAP_NEGATIVEY 0x00002000L -#define DDSCAPS2_CUBEMAP_POSITIVEZ 0x00004000L -#define DDSCAPS2_CUBEMAP_NEGATIVEZ 0x00008000L - -/* - * This macro may be used to specify all faces of a cube map at CreateSurface time - */ -#define DDSCAPS2_CUBEMAP_ALLFACES ( DDSCAPS2_CUBEMAP_POSITIVEX |\ - DDSCAPS2_CUBEMAP_NEGATIVEX |\ - DDSCAPS2_CUBEMAP_POSITIVEY |\ - DDSCAPS2_CUBEMAP_NEGATIVEY |\ - DDSCAPS2_CUBEMAP_POSITIVEZ |\ - DDSCAPS2_CUBEMAP_NEGATIVEZ ) - - -/* - * This flag is an additional flag which is present on mipmap sublevels from DX7 onwards - * It enables easier use of GetAttachedSurface rather than EnumAttachedSurfaces for surface - * constructs such as Cube Maps, wherein there are more than one mipmap surface attached - * to the root surface. - * This caps bit is ignored by CreateSurface - */ -#define DDSCAPS2_MIPMAPSUBLEVEL 0x00010000L - -/* This flag indicates that the texture should be managed by D3D only */ -#define DDSCAPS2_D3DTEXTUREMANAGE 0x00020000L - -/* This flag indicates that the managed surface can be safely lost */ -#define DDSCAPS2_DONOTPERSIST 0x00040000L - -/* indicates that this surface is part of a stereo flipping chain */ -#define DDSCAPS2_STEREOSURFACELEFT 0x00080000L - - -/* - * Indicates that the surface is a volume. - * Can be combined with DDSCAPS_MIPMAP to indicate a multi-level volume - */ -#define DDSCAPS2_VOLUME 0x00200000L - -/* - * Indicates that the surface may be locked multiple times by the application. - * This cap cannot be used with DDSCAPS2_OPAQUE. - */ -#define DDSCAPS2_NOTUSERLOCKABLE 0x00400000L - -/* - * Indicates that the vertex buffer data can be used to render points and - * point sprites. - */ -#define DDSCAPS2_POINTS 0x00800000L - -/* - * Indicates that the vertex buffer data can be used to render rt pactches. - */ -#define DDSCAPS2_RTPATCHES 0x01000000L - -/* - * Indicates that the vertex buffer data can be used to render n patches. - */ -#define DDSCAPS2_NPATCHES 0x02000000L - -/* - * This bit is reserved for internal use - */ -#define DDSCAPS2_RESERVED3 0x04000000L - - -/* - * Indicates that the contents of the backbuffer do not have to be preserved - * the contents of the backbuffer after they are presented. - */ -#define DDSCAPS2_DISCARDBACKBUFFER 0x10000000L - -/* - * Indicates that all surfaces in this creation chain should be given an alpha channel. - * This flag will be set on primary surface chains that may have no explicit pixel format - * (and thus take on the format of the current display mode). - * The driver should infer that all these surfaces have a format having an alpha channel. - * (e.g. assume D3DFMT_A8R8G8B8 if the display mode is x888.) - */ -#define DDSCAPS2_ENABLEALPHACHANNEL 0x20000000L - -/* - * Indicates that all surfaces in this creation chain is extended primary surface format. - * This flag will be set on extended primary surface chains that always have explicit pixel - * format and the pixel format is typically GDI (Graphics Device Interface) couldn't handle, - * thus only used with fullscreen application. (e.g. D3DFMT_A2R10G10B10 format) - */ -#define DDSCAPS2_EXTENDEDFORMATPRIMARY 0x40000000L - -/* - * Indicates that all surfaces in this creation chain is additional primary surface. - * This flag will be set on primary surface chains which must present on the adapter - * id provided on dwCaps4. Typically this will be used to create secondary primary surface - * on DualView display adapter. - */ -#define DDSCAPS2_ADDITIONALPRIMARY 0x80000000L - -/* - * This is a mask that indicates the set of bits that may be set - * at createsurface time to indicate number of samples per pixel - * when multisampling - */ -#define DDSCAPS3_MULTISAMPLE_MASK 0x0000001FL - -/* - * This is a mask that indicates the set of bits that may be set - * at createsurface time to indicate the quality level of rendering - * for the current number of samples per pixel - */ -#define DDSCAPS3_MULTISAMPLE_QUALITY_MASK 0x000000E0L -#define DDSCAPS3_MULTISAMPLE_QUALITY_SHIFT 5 - -/* - * This bit is reserved for internal use - */ -#define DDSCAPS3_RESERVED1 0x00000100L - -/* - * This bit is reserved for internal use - */ -#define DDSCAPS3_RESERVED2 0x00000200L - -/* - * This indicates whether this surface has light-weight miplevels - */ -#define DDSCAPS3_LIGHTWEIGHTMIPMAP 0x00000400L - -/* - * This indicates that the mipsublevels for this surface are auto-generated - */ -#define DDSCAPS3_AUTOGENMIPMAP 0x00000800L - -/* - * This indicates that the mipsublevels for this surface are auto-generated - */ -#define DDSCAPS3_DMAP 0x00001000L - - - /**************************************************************************** - * - * DIRECTDRAW DRIVER CAPABILITY FLAGS - * - ****************************************************************************/ - -/* - * Display hardware has 3D acceleration. - */ -#define DDCAPS_3D 0x00000001l - -/* - * Indicates that DirectDraw will support only dest rectangles that are aligned - * on DIRECTDRAWCAPS.dwAlignBoundaryDest boundaries of the surface, respectively. - * READ ONLY. - */ -#define DDCAPS_ALIGNBOUNDARYDEST 0x00000002l - -/* - * Indicates that DirectDraw will support only source rectangles whose sizes in - * BYTEs are DIRECTDRAWCAPS.dwAlignSizeDest multiples, respectively. READ ONLY. - */ -#define DDCAPS_ALIGNSIZEDEST 0x00000004l -/* - * Indicates that DirectDraw will support only source rectangles that are aligned - * on DIRECTDRAWCAPS.dwAlignBoundarySrc boundaries of the surface, respectively. - * READ ONLY. - */ -#define DDCAPS_ALIGNBOUNDARYSRC 0x00000008l - -/* - * Indicates that DirectDraw will support only source rectangles whose sizes in - * BYTEs are DIRECTDRAWCAPS.dwAlignSizeSrc multiples, respectively. READ ONLY. - */ -#define DDCAPS_ALIGNSIZESRC 0x00000010l - -/* - * Indicates that DirectDraw will create video memory surfaces that have a stride - * alignment equal to DIRECTDRAWCAPS.dwAlignStride. READ ONLY. - */ -#define DDCAPS_ALIGNSTRIDE 0x00000020l - -/* - * Display hardware is capable of blt operations. - */ -#define DDCAPS_BLT 0x00000040l - -/* - * Display hardware is capable of asynchronous blt operations. - */ -#define DDCAPS_BLTQUEUE 0x00000080l - -/* - * Display hardware is capable of color space conversions during the blt operation. - */ -#define DDCAPS_BLTFOURCC 0x00000100l - -/* - * Display hardware is capable of stretching during blt operations. - */ -#define DDCAPS_BLTSTRETCH 0x00000200l - -/* - * Display hardware is shared with GDI. - */ -#define DDCAPS_GDI 0x00000400l - -/* - * Display hardware can overlay. - */ -#define DDCAPS_OVERLAY 0x00000800l - -/* - * Set if display hardware supports overlays but can not clip them. - */ -#define DDCAPS_OVERLAYCANTCLIP 0x00001000l - -/* - * Indicates that overlay hardware is capable of color space conversions during - * the overlay operation. - */ -#define DDCAPS_OVERLAYFOURCC 0x00002000l - -/* - * Indicates that stretching can be done by the overlay hardware. - */ -#define DDCAPS_OVERLAYSTRETCH 0x00004000l - -/* - * Indicates that unique DirectDrawPalettes can be created for DirectDrawSurfaces - * other than the primary surface. - */ -#define DDCAPS_PALETTE 0x00008000l - -/* - * Indicates that palette changes can be syncd with the veritcal refresh. - */ -#define DDCAPS_PALETTEVSYNC 0x00010000l - -/* - * Display hardware can return the current scan line. - */ -#define DDCAPS_READSCANLINE 0x00020000l - - -/* - * This flag used to bo DDCAPS_STEREOVIEW, which is now obsolete - */ -#define DDCAPS_RESERVED1 0x00040000l - -/* - * Display hardware is capable of generating a vertical blank interrupt. - */ -#define DDCAPS_VBI 0x00080000l - -/* - * Supports the use of z buffers with blt operations. - */ -#define DDCAPS_ZBLTS 0x00100000l - -/* - * Supports Z Ordering of overlays. - */ -#define DDCAPS_ZOVERLAYS 0x00200000l - -/* - * Supports color key - */ -#define DDCAPS_COLORKEY 0x00400000l - -/* - * Supports alpha surfaces - */ -#define DDCAPS_ALPHA 0x00800000l - -/* - * colorkey is hardware assisted(DDCAPS_COLORKEY will also be set) - */ -#define DDCAPS_COLORKEYHWASSIST 0x01000000l - -/* - * no hardware support at all - */ -#define DDCAPS_NOHARDWARE 0x02000000l - -/* - * Display hardware is capable of color fill with bltter - */ -#define DDCAPS_BLTCOLORFILL 0x04000000l - -/* - * Display hardware is bank switched, and potentially very slow at - * random access to VRAM. - */ -#define DDCAPS_BANKSWITCHED 0x08000000l - -/* - * Display hardware is capable of depth filling Z-buffers with bltter - */ -#define DDCAPS_BLTDEPTHFILL 0x10000000l - -/* - * Display hardware is capable of clipping while bltting. - */ -#define DDCAPS_CANCLIP 0x20000000l - -/* - * Display hardware is capable of clipping while stretch bltting. - */ -#define DDCAPS_CANCLIPSTRETCHED 0x40000000l - -/* - * Display hardware is capable of bltting to or from system memory - */ -#define DDCAPS_CANBLTSYSMEM 0x80000000l - - - /**************************************************************************** - * - * MORE DIRECTDRAW DRIVER CAPABILITY FLAGS (dwCaps2) - * - ****************************************************************************/ - -/* - * Display hardware is certified - */ -#define DDCAPS2_CERTIFIED 0x00000001l - -/* - * Driver cannot interleave 2D operations (lock and blt) to surfaces with - * Direct3D rendering operations between calls to BeginScene() and EndScene() - */ -#define DDCAPS2_NO2DDURING3DSCENE 0x00000002l - -/* - * Display hardware contains a video port - */ -#define DDCAPS2_VIDEOPORT 0x00000004l - -/* - * The overlay can be automatically flipped according to the video port - * VSYNCs, providing automatic doubled buffered display of video port - * data using an overlay - */ -#define DDCAPS2_AUTOFLIPOVERLAY 0x00000008l - -/* - * Overlay can display each field of interlaced data individually while - * it is interleaved in memory without causing jittery artifacts. - */ -#define DDCAPS2_CANBOBINTERLEAVED 0x00000010l - -/* - * Overlay can display each field of interlaced data individually while - * it is not interleaved in memory without causing jittery artifacts. - */ -#define DDCAPS2_CANBOBNONINTERLEAVED 0x00000020l - -/* - * The overlay surface contains color controls (brightness, sharpness, etc.) - */ -#define DDCAPS2_COLORCONTROLOVERLAY 0x00000040l - -/* - * The primary surface contains color controls (gamma, etc.) - */ -#define DDCAPS2_COLORCONTROLPRIMARY 0x00000080l - -/* - * RGBZ -> RGB supported for 16:16 RGB:Z - */ -#define DDCAPS2_CANDROPZ16BIT 0x00000100l - -/* - * Driver supports non-local video memory. - */ -#define DDCAPS2_NONLOCALVIDMEM 0x00000200l - -/* - * Dirver supports non-local video memory but has different capabilities for - * non-local video memory surfaces. If this bit is set then so must - * DDCAPS2_NONLOCALVIDMEM. - */ -#define DDCAPS2_NONLOCALVIDMEMCAPS 0x00000400l - -/* - * Driver neither requires nor prefers surfaces to be pagelocked when performing - * blts involving system memory surfaces - */ -#define DDCAPS2_NOPAGELOCKREQUIRED 0x00000800l - -/* - * Driver can create surfaces which are wider than the primary surface - */ -#define DDCAPS2_WIDESURFACES 0x00001000l - -/* - * Driver supports bob without using a video port by handling the - * DDFLIP_ODD and DDFLIP_EVEN flags specified in Flip. - */ -#define DDCAPS2_CANFLIPODDEVEN 0x00002000l - -/* - * Driver supports bob using hardware - */ -#define DDCAPS2_CANBOBHARDWARE 0x00004000l - -/* - * Driver supports bltting any FOURCC surface to another surface of the same FOURCC - */ -#define DDCAPS2_COPYFOURCC 0x00008000l - - -/* - * Driver supports loadable gamma ramps for the primary surface - */ -#define DDCAPS2_PRIMARYGAMMA 0x00020000l - -/* - * Driver can render in windowed mode. - */ -#define DDCAPS2_CANRENDERWINDOWED 0x00080000l - -/* - * A calibrator is available to adjust the gamma ramp according to the - * physical display properties so that the result will be identical on - * all calibrated systems. - */ -#define DDCAPS2_CANCALIBRATEGAMMA 0x00100000l - -/* - * Indicates that the driver will respond to DDFLIP_INTERVALn flags - */ -#define DDCAPS2_FLIPINTERVAL 0x00200000l - -/* - * Indicates that the driver will respond to DDFLIP_NOVSYNC - */ -#define DDCAPS2_FLIPNOVSYNC 0x00400000l - -/* - * Driver supports management of video memory, if this flag is ON, - * driver manages the texture if requested with DDSCAPS2_TEXTUREMANAGE on - * DirectX manages the texture if this flag is OFF and surface has DDSCAPS2_TEXTUREMANAGE on - */ -#define DDCAPS2_CANMANAGETEXTURE 0x00800000l - -/* - * The Direct3D texture manager uses this cap to decide whether to put managed - * surfaces in non-local video memory. If the cap is set, the texture manager will - * put managed surfaces in non-local vidmem. Drivers that cannot texture from - * local vidmem SHOULD NOT set this cap. - */ -#define DDCAPS2_TEXMANINNONLOCALVIDMEM 0x01000000l - -/* - * Indicates that the driver supports DX7 type of stereo in at least one mode (which may - * not necessarily be the current mode). Applications should use IDirectDraw7 (or higher) - * ::EnumDisplayModes and check the DDSURFACEDESC.ddsCaps.dwCaps2 field for the presence of - * DDSCAPS2_STEREOSURFACELEFT to check if a particular mode supports stereo. The application - * can also use IDirectDraw7(or higher)::GetDisplayMode to check the current mode. - */ -#define DDCAPS2_STEREO 0x02000000L - -/* - * This caps bit is intended for internal DirectDraw use. - * -It is only valid if DDCAPS2_NONLOCALVIDMEMCAPS is set. - * -If this bit is set, then DDCAPS_CANBLTSYSMEM MUST be set by the driver (and - * all the assoicated system memory blt caps must be correct). - * -It implies that the system->video blt caps in DDCAPS also apply to system to - * nonlocal blts. I.e. the dwSVBCaps, dwSVBCKeyCaps, dwSVBFXCaps and dwSVBRops - * members of DDCAPS (DDCORECAPS) are filled in correctly. - * -Any blt from system to nonlocal memory that matches these caps bits will - * be passed to the driver. - * - * NOTE: This is intended to enable the driver itself to do efficient reordering - * of textures. This is NOT meant to imply that hardware can write into AGP memory. - * This operation is not currently supported. - */ -#define DDCAPS2_SYSTONONLOCAL_AS_SYSTOLOCAL 0x04000000L - -/* - * was DDCAPS2_PUREHAL - */ -#define DDCAPS2_RESERVED1 0x08000000L - -/* - * Driver supports management of video memory, if this flag is ON, - * driver manages the resource if requested with DDSCAPS2_TEXTUREMANAGE on - * DirectX manages the resource if this flag is OFF and surface has DDSCAPS2_TEXTUREMANAGE on - */ -#define DDCAPS2_CANMANAGERESOURCE 0x10000000L - -/* - * Driver supports dynamic textures. This will allow the application to set - * D3DUSAGE_DYNAMIC (DDSCAPS2_HINTDYNAMIC for drivers) at texture create time. - * Video memory dynamic textures WILL be lockable by applications. It is - * expected that these locks will be very efficient (which implies that the - * driver should always maintain a linear copy, a pointer to which can be - * quickly handed out to the application). - */ -#define DDCAPS2_DYNAMICTEXTURES 0x20000000L - -/* - * Driver supports auto-generation of mipmaps. - */ -#define DDCAPS2_CANAUTOGENMIPMAP 0x40000000L - - -/**************************************************************************** - * - * DIRECTDRAW FX ALPHA CAPABILITY FLAGS - * - ****************************************************************************/ - -/* - * Supports alpha blending around the edge of a source color keyed surface. - * For Blt. - */ -#define DDFXALPHACAPS_BLTALPHAEDGEBLEND 0x00000001l - -/* - * Supports alpha information in the pixel format. The bit depth of alpha - * information in the pixel format can be 1,2,4, or 8. The alpha value becomes - * more opaque as the alpha value increases. (0 is transparent.) - * For Blt. - */ -#define DDFXALPHACAPS_BLTALPHAPIXELS 0x00000002l - -/* - * Supports alpha information in the pixel format. The bit depth of alpha - * information in the pixel format can be 1,2,4, or 8. The alpha value - * becomes more transparent as the alpha value increases. (0 is opaque.) - * This flag can only be set if DDCAPS_ALPHA is set. - * For Blt. - */ -#define DDFXALPHACAPS_BLTALPHAPIXELSNEG 0x00000004l - -/* - * Supports alpha only surfaces. The bit depth of an alpha only surface can be - * 1,2,4, or 8. The alpha value becomes more opaque as the alpha value increases. - * (0 is transparent.) - * For Blt. - */ -#define DDFXALPHACAPS_BLTALPHASURFACES 0x00000008l - -/* - * The depth of the alpha channel data can range can be 1,2,4, or 8. - * The NEG suffix indicates that this alpha channel becomes more transparent - * as the alpha value increases. (0 is opaque.) This flag can only be set if - * DDCAPS_ALPHA is set. - * For Blt. - */ -#define DDFXALPHACAPS_BLTALPHASURFACESNEG 0x00000010l - -/* - * Supports alpha blending around the edge of a source color keyed surface. - * For Overlays. - */ -#define DDFXALPHACAPS_OVERLAYALPHAEDGEBLEND 0x00000020l - -/* - * Supports alpha information in the pixel format. The bit depth of alpha - * information in the pixel format can be 1,2,4, or 8. The alpha value becomes - * more opaque as the alpha value increases. (0 is transparent.) - * For Overlays. - */ -#define DDFXALPHACAPS_OVERLAYALPHAPIXELS 0x00000040l - -/* - * Supports alpha information in the pixel format. The bit depth of alpha - * information in the pixel format can be 1,2,4, or 8. The alpha value - * becomes more transparent as the alpha value increases. (0 is opaque.) - * This flag can only be set if DDCAPS_ALPHA is set. - * For Overlays. - */ -#define DDFXALPHACAPS_OVERLAYALPHAPIXELSNEG 0x00000080l - -/* - * Supports alpha only surfaces. The bit depth of an alpha only surface can be - * 1,2,4, or 8. The alpha value becomes more opaque as the alpha value increases. - * (0 is transparent.) - * For Overlays. - */ -#define DDFXALPHACAPS_OVERLAYALPHASURFACES 0x00000100l - -/* - * The depth of the alpha channel data can range can be 1,2,4, or 8. - * The NEG suffix indicates that this alpha channel becomes more transparent - * as the alpha value increases. (0 is opaque.) This flag can only be set if - * DDCAPS_ALPHA is set. - * For Overlays. - */ -#define DDFXALPHACAPS_OVERLAYALPHASURFACESNEG 0x00000200l - -#if DIRECTDRAW_VERSION < 0x0600 -#endif //DIRECTDRAW_VERSION - - -/**************************************************************************** - * - * DIRECTDRAW FX CAPABILITY FLAGS - * - ****************************************************************************/ - -/* - * Uses arithmetic operations to stretch and shrink surfaces during blt - * rather than pixel doubling techniques. Along the Y axis. - */ -#define DDFXCAPS_BLTARITHSTRETCHY 0x00000020l - -/* - * Uses arithmetic operations to stretch during blt - * rather than pixel doubling techniques. Along the Y axis. Only - * works for x1, x2, etc. - */ -#define DDFXCAPS_BLTARITHSTRETCHYN 0x00000010l - -/* - * Supports mirroring left to right in blt. - */ -#define DDFXCAPS_BLTMIRRORLEFTRIGHT 0x00000040l - -/* - * Supports mirroring top to bottom in blt. - */ -#define DDFXCAPS_BLTMIRRORUPDOWN 0x00000080l - -/* - * Supports arbitrary rotation for blts. - */ -#define DDFXCAPS_BLTROTATION 0x00000100l - -/* - * Supports 90 degree rotations for blts. - */ -#define DDFXCAPS_BLTROTATION90 0x00000200l - -/* - * DirectDraw supports arbitrary shrinking of a surface along the - * x axis (horizontal direction) for blts. - */ -#define DDFXCAPS_BLTSHRINKX 0x00000400l - -/* - * DirectDraw supports integer shrinking (1x,2x,) of a surface - * along the x axis (horizontal direction) for blts. - */ -#define DDFXCAPS_BLTSHRINKXN 0x00000800l - -/* - * DirectDraw supports arbitrary shrinking of a surface along the - * y axis (horizontal direction) for blts. - */ -#define DDFXCAPS_BLTSHRINKY 0x00001000l - -/* - * DirectDraw supports integer shrinking (1x,2x,) of a surface - * along the y axis (vertical direction) for blts. - */ -#define DDFXCAPS_BLTSHRINKYN 0x00002000l - -/* - * DirectDraw supports arbitrary stretching of a surface along the - * x axis (horizontal direction) for blts. - */ -#define DDFXCAPS_BLTSTRETCHX 0x00004000l - -/* - * DirectDraw supports integer stretching (1x,2x,) of a surface - * along the x axis (horizontal direction) for blts. - */ -#define DDFXCAPS_BLTSTRETCHXN 0x00008000l - -/* - * DirectDraw supports arbitrary stretching of a surface along the - * y axis (horizontal direction) for blts. - */ -#define DDFXCAPS_BLTSTRETCHY 0x00010000l - -/* - * DirectDraw supports integer stretching (1x,2x,) of a surface - * along the y axis (vertical direction) for blts. - */ -#define DDFXCAPS_BLTSTRETCHYN 0x00020000l - -/* - * Uses arithmetic operations to stretch and shrink surfaces during - * overlay rather than pixel doubling techniques. Along the Y axis - * for overlays. - */ -#define DDFXCAPS_OVERLAYARITHSTRETCHY 0x00040000l - -/* - * Uses arithmetic operations to stretch surfaces during - * overlay rather than pixel doubling techniques. Along the Y axis - * for overlays. Only works for x1, x2, etc. - */ -#define DDFXCAPS_OVERLAYARITHSTRETCHYN 0x00000008l - -/* - * DirectDraw supports arbitrary shrinking of a surface along the - * x axis (horizontal direction) for overlays. - */ -#define DDFXCAPS_OVERLAYSHRINKX 0x00080000l - -/* - * DirectDraw supports integer shrinking (1x,2x,) of a surface - * along the x axis (horizontal direction) for overlays. - */ -#define DDFXCAPS_OVERLAYSHRINKXN 0x00100000l - -/* - * DirectDraw supports arbitrary shrinking of a surface along the - * y axis (horizontal direction) for overlays. - */ -#define DDFXCAPS_OVERLAYSHRINKY 0x00200000l - -/* - * DirectDraw supports integer shrinking (1x,2x,) of a surface - * along the y axis (vertical direction) for overlays. - */ -#define DDFXCAPS_OVERLAYSHRINKYN 0x00400000l - -/* - * DirectDraw supports arbitrary stretching of a surface along the - * x axis (horizontal direction) for overlays. - */ -#define DDFXCAPS_OVERLAYSTRETCHX 0x00800000l - -/* - * DirectDraw supports integer stretching (1x,2x,) of a surface - * along the x axis (horizontal direction) for overlays. - */ -#define DDFXCAPS_OVERLAYSTRETCHXN 0x01000000l - -/* - * DirectDraw supports arbitrary stretching of a surface along the - * y axis (horizontal direction) for overlays. - */ -#define DDFXCAPS_OVERLAYSTRETCHY 0x02000000l - -/* - * DirectDraw supports integer stretching (1x,2x,) of a surface - * along the y axis (vertical direction) for overlays. - */ -#define DDFXCAPS_OVERLAYSTRETCHYN 0x04000000l - -/* - * DirectDraw supports mirroring of overlays across the vertical axis - */ -#define DDFXCAPS_OVERLAYMIRRORLEFTRIGHT 0x08000000l - -/* - * DirectDraw supports mirroring of overlays across the horizontal axis - */ -#define DDFXCAPS_OVERLAYMIRRORUPDOWN 0x10000000l - -/* - * DirectDraw supports deinterlacing of overlay surfaces - */ -#define DDFXCAPS_OVERLAYDEINTERLACE 0x20000000l - -/* - * Driver can do alpha blending for blits. - */ -#define DDFXCAPS_BLTALPHA 0x00000001l - - -/* - * Driver can do surface-reconstruction filtering for warped blits. - */ -#define DDFXCAPS_BLTFILTER DDFXCAPS_BLTARITHSTRETCHY - -/* - * Driver can do alpha blending for overlays. - */ -#define DDFXCAPS_OVERLAYALPHA 0x00000004l - - -/* - * Driver can do surface-reconstruction filtering for warped overlays. - */ -#define DDFXCAPS_OVERLAYFILTER DDFXCAPS_OVERLAYARITHSTRETCHY - -/**************************************************************************** - * - * DIRECTDRAW STEREO VIEW CAPABILITIES - * - ****************************************************************************/ - -/* - * This flag used to be DDSVCAPS_ENIGMA, which is now obsolete - */ - -#define DDSVCAPS_RESERVED1 0x00000001l - -/* - * This flag used to be DDSVCAPS_FLICKER, which is now obsolete - */ -#define DDSVCAPS_RESERVED2 0x00000002l - -/* - * This flag used to be DDSVCAPS_REDBLUE, which is now obsolete - */ -#define DDSVCAPS_RESERVED3 0x00000004l - -/* - * This flag used to be DDSVCAPS_SPLIT, which is now obsolete - */ -#define DDSVCAPS_RESERVED4 0x00000008l - -/* - * The stereo view is accomplished with switching technology - */ - -#define DDSVCAPS_STEREOSEQUENTIAL 0x00000010L - - - -/**************************************************************************** - * - * DIRECTDRAWPALETTE CAPABILITIES - * - ****************************************************************************/ - -/* - * Index is 4 bits. There are sixteen color entries in the palette table. - */ -#define DDPCAPS_4BIT 0x00000001l - -/* - * Index is onto a 8 bit color index. This field is only valid with the - * DDPCAPS_1BIT, DDPCAPS_2BIT or DDPCAPS_4BIT capability and the target - * surface is in 8bpp. Each color entry is one byte long and is an index - * into destination surface's 8bpp palette. - */ -#define DDPCAPS_8BITENTRIES 0x00000002l - -/* - * Index is 8 bits. There are 256 color entries in the palette table. - */ -#define DDPCAPS_8BIT 0x00000004l - -/* - * Indicates that this DIRECTDRAWPALETTE should use the palette color array - * passed into the lpDDColorArray parameter to initialize the DIRECTDRAWPALETTE - * object. - * This flag is obsolete. DirectDraw always initializes the color array from - * the lpDDColorArray parameter. The definition remains for source-level - * compatibility. - */ -#define DDPCAPS_INITIALIZE 0x00000000l - -/* - * This palette is the one attached to the primary surface. Changing this - * table has immediate effect on the display unless DDPSETPAL_VSYNC is specified - * and supported. - */ -#define DDPCAPS_PRIMARYSURFACE 0x00000010l - -/* - * This palette is the one attached to the primary surface left. Changing - * this table has immediate effect on the display for the left eye unless - * DDPSETPAL_VSYNC is specified and supported. - */ -#define DDPCAPS_PRIMARYSURFACELEFT 0x00000020l - -/* - * This palette can have all 256 entries defined - */ -#define DDPCAPS_ALLOW256 0x00000040l - -/* - * This palette can have modifications to it synced with the monitors - * refresh rate. - */ -#define DDPCAPS_VSYNC 0x00000080l - -/* - * Index is 1 bit. There are two color entries in the palette table. - */ -#define DDPCAPS_1BIT 0x00000100l - -/* - * Index is 2 bit. There are four color entries in the palette table. - */ -#define DDPCAPS_2BIT 0x00000200l - -/* - * The peFlags member of PALETTEENTRY denotes an 8 bit alpha value - */ -#define DDPCAPS_ALPHA 0x00000400l - - -/**************************************************************************** - * - * DIRECTDRAWPALETTE SETENTRY CONSTANTS - * - ****************************************************************************/ - - -/**************************************************************************** - * - * DIRECTDRAWPALETTE GETENTRY CONSTANTS - * - ****************************************************************************/ - -/* 0 is the only legal value */ - -/**************************************************************************** - * - * DIRECTDRAWSURFACE SETPRIVATEDATA CONSTANTS - * - ****************************************************************************/ - -/* - * The passed pointer is an IUnknown ptr. The cbData argument to SetPrivateData - * must be set to sizeof(IUnknown*). DirectDraw will call AddRef through this - * pointer and Release when the private data is destroyed. This includes when - * the surface or palette is destroyed before such priovate data is destroyed. - */ -#define DDSPD_IUNKNOWNPOINTER 0x00000001L - -/* - * Private data is only valid for the current state of the object, - * as determined by the uniqueness value. - */ -#define DDSPD_VOLATILE 0x00000002L - - -/**************************************************************************** - * - * DIRECTDRAWSURFACE SETPALETTE CONSTANTS - * - ****************************************************************************/ - - -/**************************************************************************** - * - * DIRECTDRAW BITDEPTH CONSTANTS - * - * NOTE: These are only used to indicate supported bit depths. These - * are flags only, they are not to be used as an actual bit depth. The - * absolute numbers 1, 2, 4, 8, 16, 24 and 32 are used to indicate actual - * bit depths in a surface or for changing the display mode. - * - ****************************************************************************/ - -/* - * 1 bit per pixel. - */ -#define DDBD_1 0x00004000l - -/* - * 2 bits per pixel. - */ -#define DDBD_2 0x00002000l - -/* - * 4 bits per pixel. - */ -#define DDBD_4 0x00001000l - -/* - * 8 bits per pixel. - */ -#define DDBD_8 0x00000800l - -/* - * 16 bits per pixel. - */ -#define DDBD_16 0x00000400l - -/* - * 24 bits per pixel. - */ -#define DDBD_24 0X00000200l - -/* - * 32 bits per pixel. - */ -#define DDBD_32 0x00000100l - -/**************************************************************************** - * - * DIRECTDRAWSURFACE SET/GET COLOR KEY FLAGS - * - ****************************************************************************/ - -/* - * Set if the structure contains a color space. Not set if the structure - * contains a single color key. - */ -#define DDCKEY_COLORSPACE 0x00000001l - -/* - * Set if the structure specifies a color key or color space which is to be - * used as a destination color key for blt operations. - */ -#define DDCKEY_DESTBLT 0x00000002l - -/* - * Set if the structure specifies a color key or color space which is to be - * used as a destination color key for overlay operations. - */ -#define DDCKEY_DESTOVERLAY 0x00000004l - -/* - * Set if the structure specifies a color key or color space which is to be - * used as a source color key for blt operations. - */ -#define DDCKEY_SRCBLT 0x00000008l - -/* - * Set if the structure specifies a color key or color space which is to be - * used as a source color key for overlay operations. - */ -#define DDCKEY_SRCOVERLAY 0x00000010l - - -/**************************************************************************** - * - * DIRECTDRAW COLOR KEY CAPABILITY FLAGS - * - ****************************************************************************/ - -/* - * Supports transparent blting using a color key to identify the replaceable - * bits of the destination surface for RGB colors. - */ -#define DDCKEYCAPS_DESTBLT 0x00000001l - -/* - * Supports transparent blting using a color space to identify the replaceable - * bits of the destination surface for RGB colors. - */ -#define DDCKEYCAPS_DESTBLTCLRSPACE 0x00000002l - -/* - * Supports transparent blting using a color space to identify the replaceable - * bits of the destination surface for YUV colors. - */ -#define DDCKEYCAPS_DESTBLTCLRSPACEYUV 0x00000004l - -/* - * Supports transparent blting using a color key to identify the replaceable - * bits of the destination surface for YUV colors. - */ -#define DDCKEYCAPS_DESTBLTYUV 0x00000008l - -/* - * Supports overlaying using colorkeying of the replaceable bits of the surface - * being overlayed for RGB colors. - */ -#define DDCKEYCAPS_DESTOVERLAY 0x00000010l - -/* - * Supports a color space as the color key for the destination for RGB colors. - */ -#define DDCKEYCAPS_DESTOVERLAYCLRSPACE 0x00000020l - -/* - * Supports a color space as the color key for the destination for YUV colors. - */ -#define DDCKEYCAPS_DESTOVERLAYCLRSPACEYUV 0x00000040l - -/* - * Supports only one active destination color key value for visible overlay - * surfaces. - */ -#define DDCKEYCAPS_DESTOVERLAYONEACTIVE 0x00000080l - -/* - * Supports overlaying using colorkeying of the replaceable bits of the - * surface being overlayed for YUV colors. - */ -#define DDCKEYCAPS_DESTOVERLAYYUV 0x00000100l - -/* - * Supports transparent blting using the color key for the source with - * this surface for RGB colors. - */ -#define DDCKEYCAPS_SRCBLT 0x00000200l - -/* - * Supports transparent blting using a color space for the source with - * this surface for RGB colors. - */ -#define DDCKEYCAPS_SRCBLTCLRSPACE 0x00000400l - -/* - * Supports transparent blting using a color space for the source with - * this surface for YUV colors. - */ -#define DDCKEYCAPS_SRCBLTCLRSPACEYUV 0x00000800l - -/* - * Supports transparent blting using the color key for the source with - * this surface for YUV colors. - */ -#define DDCKEYCAPS_SRCBLTYUV 0x00001000l - -/* - * Supports overlays using the color key for the source with this - * overlay surface for RGB colors. - */ -#define DDCKEYCAPS_SRCOVERLAY 0x00002000l - -/* - * Supports overlays using a color space as the source color key for - * the overlay surface for RGB colors. - */ -#define DDCKEYCAPS_SRCOVERLAYCLRSPACE 0x00004000l - -/* - * Supports overlays using a color space as the source color key for - * the overlay surface for YUV colors. - */ -#define DDCKEYCAPS_SRCOVERLAYCLRSPACEYUV 0x00008000l - -/* - * Supports only one active source color key value for visible - * overlay surfaces. - */ -#define DDCKEYCAPS_SRCOVERLAYONEACTIVE 0x00010000l - -/* - * Supports overlays using the color key for the source with this - * overlay surface for YUV colors. - */ -#define DDCKEYCAPS_SRCOVERLAYYUV 0x00020000l - -/* - * there are no bandwidth trade-offs for using colorkey with an overlay - */ -#define DDCKEYCAPS_NOCOSTOVERLAY 0x00040000l - - -/**************************************************************************** - * - * DIRECTDRAW PIXELFORMAT FLAGS - * - ****************************************************************************/ - -/* - * The surface has alpha channel information in the pixel format. - */ -#define DDPF_ALPHAPIXELS 0x00000001l - -/* - * The pixel format contains alpha only information - */ -#define DDPF_ALPHA 0x00000002l - -/* - * The FourCC code is valid. - */ -#define DDPF_FOURCC 0x00000004l - -/* - * The surface is 4-bit color indexed. - */ -#define DDPF_PALETTEINDEXED4 0x00000008l - -/* - * The surface is indexed into a palette which stores indices - * into the destination surface's 8-bit palette. - */ -#define DDPF_PALETTEINDEXEDTO8 0x00000010l - -/* - * The surface is 8-bit color indexed. - */ -#define DDPF_PALETTEINDEXED8 0x00000020l - -/* - * The RGB data in the pixel format structure is valid. - */ -#define DDPF_RGB 0x00000040l - -/* - * The surface will accept pixel data in the format specified - * and compress it during the write. - */ -#define DDPF_COMPRESSED 0x00000080l - -/* - * The surface will accept RGB data and translate it during - * the write to YUV data. The format of the data to be written - * will be contained in the pixel format structure. The DDPF_RGB - * flag will be set. - */ -#define DDPF_RGBTOYUV 0x00000100l - -/* - * pixel format is YUV - YUV data in pixel format struct is valid - */ -#define DDPF_YUV 0x00000200l - -/* - * pixel format is a z buffer only surface - */ -#define DDPF_ZBUFFER 0x00000400l - -/* - * The surface is 1-bit color indexed. - */ -#define DDPF_PALETTEINDEXED1 0x00000800l - -/* - * The surface is 2-bit color indexed. - */ -#define DDPF_PALETTEINDEXED2 0x00001000l - -/* - * The surface contains Z information in the pixels - */ -#define DDPF_ZPIXELS 0x00002000l - -/* - * The surface contains stencil information along with Z - */ -#define DDPF_STENCILBUFFER 0x00004000l - -/* - * Premultiplied alpha format -- the color components have been - * premultiplied by the alpha component. - */ -#define DDPF_ALPHAPREMULT 0x00008000l - - -/* - * Luminance data in the pixel format is valid. - * Use this flag for luminance-only or luminance+alpha surfaces, - * the bit depth is then ddpf.dwLuminanceBitCount. - */ -#define DDPF_LUMINANCE 0x00020000l - -/* - * Luminance data in the pixel format is valid. - * Use this flag when hanging luminance off bumpmap surfaces, - * the bit mask for the luminance portion of the pixel is then - * ddpf.dwBumpLuminanceBitMask - */ -#define DDPF_BUMPLUMINANCE 0x00040000l - -/* - * Bump map dUdV data in the pixel format is valid. - */ -#define DDPF_BUMPDUDV 0x00080000l - - -/*=========================================================================== - * - * - * DIRECTDRAW CALLBACK FLAGS - * - * - *==========================================================================*/ - -/**************************************************************************** - * - * DIRECTDRAW ENUMSURFACES FLAGS - * - ****************************************************************************/ - -/* - * Enumerate all of the surfaces that meet the search criterion. - */ -#define DDENUMSURFACES_ALL 0x00000001l - -/* - * A search hit is a surface that matches the surface description. - */ -#define DDENUMSURFACES_MATCH 0x00000002l - -/* - * A search hit is a surface that does not match the surface description. - */ -#define DDENUMSURFACES_NOMATCH 0x00000004l - -/* - * Enumerate the first surface that can be created which meets the search criterion. - */ -#define DDENUMSURFACES_CANBECREATED 0x00000008l - -/* - * Enumerate the surfaces that already exist that meet the search criterion. - */ -#define DDENUMSURFACES_DOESEXIST 0x00000010l - - -/**************************************************************************** - * - * DIRECTDRAW SETDISPLAYMODE FLAGS - * - ****************************************************************************/ - -/* - * The desired mode is a standard VGA mode - */ -#define DDSDM_STANDARDVGAMODE 0x00000001l - - -/**************************************************************************** - * - * DIRECTDRAW ENUMDISPLAYMODES FLAGS - * - ****************************************************************************/ - -/* - * Enumerate Modes with different refresh rates. EnumDisplayModes guarantees - * that a particular mode will be enumerated only once. This flag specifies whether - * the refresh rate is taken into account when determining if a mode is unique. - */ -#define DDEDM_REFRESHRATES 0x00000001l - -/* - * Enumerate VGA modes. Specify this flag if you wish to enumerate supported VGA - * modes such as mode 0x13 in addition to the usual ModeX modes (which are always - * enumerated if the application has previously called SetCooperativeLevel with the - * DDSCL_ALLOWMODEX flag set). - */ -#define DDEDM_STANDARDVGAMODES 0x00000002L - - -/**************************************************************************** - * - * DIRECTDRAW SETCOOPERATIVELEVEL FLAGS - * - ****************************************************************************/ - -/* - * Exclusive mode owner will be responsible for the entire primary surface. - * GDI can be ignored. used with DD - */ -#define DDSCL_FULLSCREEN 0x00000001l - -/* - * allow CTRL_ALT_DEL to work while in fullscreen exclusive mode - */ -#define DDSCL_ALLOWREBOOT 0x00000002l - -/* - * prevents DDRAW from modifying the application window. - * prevents DDRAW from minimize/restore the application window on activation. - */ -#define DDSCL_NOWINDOWCHANGES 0x00000004l - -/* - * app wants to work as a regular Windows application - */ -#define DDSCL_NORMAL 0x00000008l - -/* - * app wants exclusive access - */ -#define DDSCL_EXCLUSIVE 0x00000010l - - -/* - * app can deal with non-windows display modes - */ -#define DDSCL_ALLOWMODEX 0x00000040l - -/* - * this window will receive the focus messages - */ -#define DDSCL_SETFOCUSWINDOW 0x00000080l - -/* - * this window is associated with the DDRAW object and will - * cover the screen in fullscreen mode - */ -#define DDSCL_SETDEVICEWINDOW 0x00000100l - -/* - * app wants DDRAW to create a window to be associated with the - * DDRAW object - */ -#define DDSCL_CREATEDEVICEWINDOW 0x00000200l - -/* - * App explicitly asks DDRAW/D3D to be multithread safe. This makes D3D - * take the global crtisec more frequently. - */ -#define DDSCL_MULTITHREADED 0x00000400l - -/* - * App specifies that it would like to keep the FPU set up for optimal Direct3D - * performance (single precision and exceptions disabled) so Direct3D - * does not need to explicitly set the FPU each time. This is assumed by - * default in DirectX 7. See also DDSCL_FPUPRESERVE - */ -#define DDSCL_FPUSETUP 0x00000800l - -/* - * App specifies that it needs either double precision FPU or FPU exceptions - * enabled. This makes Direct3D explicitly set the FPU state eah time it is - * called. Setting the flag will reduce Direct3D performance. The flag is - * assumed by default in DirectX 6 and earlier. See also DDSCL_FPUSETUP - */ -#define DDSCL_FPUPRESERVE 0x00001000l - - -/**************************************************************************** - * - * DIRECTDRAW BLT FLAGS - * - ****************************************************************************/ - -/* - * Use the alpha information in the pixel format or the alpha channel surface - * attached to the destination surface as the alpha channel for this blt. - */ -#define DDBLT_ALPHADEST 0x00000001l - -/* - * Use the dwConstAlphaDest field in the DDBLTFX structure as the alpha channel - * for the destination surface for this blt. - */ -#define DDBLT_ALPHADESTCONSTOVERRIDE 0x00000002l - -/* - * The NEG suffix indicates that the destination surface becomes more - * transparent as the alpha value increases. (0 is opaque) - */ -#define DDBLT_ALPHADESTNEG 0x00000004l - -/* - * Use the lpDDSAlphaDest field in the DDBLTFX structure as the alpha - * channel for the destination for this blt. - */ -#define DDBLT_ALPHADESTSURFACEOVERRIDE 0x00000008l - -/* - * Use the dwAlphaEdgeBlend field in the DDBLTFX structure as the alpha channel - * for the edges of the image that border the color key colors. - */ -#define DDBLT_ALPHAEDGEBLEND 0x00000010l - -/* - * Use the alpha information in the pixel format or the alpha channel surface - * attached to the source surface as the alpha channel for this blt. - */ -#define DDBLT_ALPHASRC 0x00000020l - -/* - * Use the dwConstAlphaSrc field in the DDBLTFX structure as the alpha channel - * for the source for this blt. - */ -#define DDBLT_ALPHASRCCONSTOVERRIDE 0x00000040l - -/* - * The NEG suffix indicates that the source surface becomes more transparent - * as the alpha value increases. (0 is opaque) - */ -#define DDBLT_ALPHASRCNEG 0x00000080l - -/* - * Use the lpDDSAlphaSrc field in the DDBLTFX structure as the alpha channel - * for the source for this blt. - */ -#define DDBLT_ALPHASRCSURFACEOVERRIDE 0x00000100l - -/* - * Do this blt asynchronously through the FIFO in the order received. If - * there is no room in the hardware FIFO fail the call. - */ -#define DDBLT_ASYNC 0x00000200l - -/* - * Uses the dwFillColor field in the DDBLTFX structure as the RGB color - * to fill the destination rectangle on the destination surface with. - */ -#define DDBLT_COLORFILL 0x00000400l - -/* - * Uses the dwDDFX field in the DDBLTFX structure to specify the effects - * to use for the blt. - */ -#define DDBLT_DDFX 0x00000800l - -/* - * Uses the dwDDROPS field in the DDBLTFX structure to specify the ROPS - * that are not part of the Win32 API. - */ -#define DDBLT_DDROPS 0x00001000l - -/* - * Use the color key associated with the destination surface. - */ -#define DDBLT_KEYDEST 0x00002000l - -/* - * Use the dckDestColorkey field in the DDBLTFX structure as the color key - * for the destination surface. - */ -#define DDBLT_KEYDESTOVERRIDE 0x00004000l - -/* - * Use the color key associated with the source surface. - */ -#define DDBLT_KEYSRC 0x00008000l - -/* - * Use the dckSrcColorkey field in the DDBLTFX structure as the color key - * for the source surface. - */ -#define DDBLT_KEYSRCOVERRIDE 0x00010000l - -/* - * Use the dwROP field in the DDBLTFX structure for the raster operation - * for this blt. These ROPs are the same as the ones defined in the Win32 API. - */ -#define DDBLT_ROP 0x00020000l - -/* - * Use the dwRotationAngle field in the DDBLTFX structure as the angle - * (specified in 1/100th of a degree) to rotate the surface. - */ -#define DDBLT_ROTATIONANGLE 0x00040000l - -/* - * Z-buffered blt using the z-buffers attached to the source and destination - * surfaces and the dwZBufferOpCode field in the DDBLTFX structure as the - * z-buffer opcode. - */ -#define DDBLT_ZBUFFER 0x00080000l - -/* - * Z-buffered blt using the dwConstDest Zfield and the dwZBufferOpCode field - * in the DDBLTFX structure as the z-buffer and z-buffer opcode respectively - * for the destination. - */ -#define DDBLT_ZBUFFERDESTCONSTOVERRIDE 0x00100000l - -/* - * Z-buffered blt using the lpDDSDestZBuffer field and the dwZBufferOpCode - * field in the DDBLTFX structure as the z-buffer and z-buffer opcode - * respectively for the destination. - */ -#define DDBLT_ZBUFFERDESTOVERRIDE 0x00200000l - -/* - * Z-buffered blt using the dwConstSrcZ field and the dwZBufferOpCode field - * in the DDBLTFX structure as the z-buffer and z-buffer opcode respectively - * for the source. - */ -#define DDBLT_ZBUFFERSRCCONSTOVERRIDE 0x00400000l - -/* - * Z-buffered blt using the lpDDSSrcZBuffer field and the dwZBufferOpCode - * field in the DDBLTFX structure as the z-buffer and z-buffer opcode - * respectively for the source. - */ -#define DDBLT_ZBUFFERSRCOVERRIDE 0x00800000l - -/* - * wait until the device is ready to handle the blt - * this will cause blt to not return DDERR_WASSTILLDRAWING - */ -#define DDBLT_WAIT 0x01000000l - -/* - * Uses the dwFillDepth field in the DDBLTFX structure as the depth value - * to fill the destination rectangle on the destination Z-buffer surface - * with. - */ -#define DDBLT_DEPTHFILL 0x02000000l - - -/* - * Return immediately (with DDERR_WASSTILLDRAWING) if the device is not - * ready to schedule the blt at the time Blt() is called. - */ -#define DDBLT_DONOTWAIT 0x08000000l - -/* - * These flags indicate a presentation blt (i.e. a blt - * that moves surface contents from an offscreen back buffer to the primary - * surface). The driver is not allowed to "queue" more than three such blts. - * The "end" of the presentation blt is indicated, since the - * blt may be clipped, in which case the runtime will call the driver with - * several blts. All blts (even if not clipped) are tagged with DDBLT_PRESENTATION - * and the last (even if not clipped) additionally with DDBLT_LAST_PRESENTATION. - * Thus the true rule is that the driver must not schedule a DDBLT_PRESENTATION - * blt if there are 3 or more DDBLT_PRESENTLAST blts in the hardware pipe. - * If there are such blts in the pipe, the driver should return DDERR_WASSTILLDRAWING - * until the oldest queued DDBLT_LAST_PRESENTATION blts has been retired (i.e. the - * pixels have been actually written to the primary surface). Once the oldest blt - * has been retired, the driver is free to schedule the current blt. - * The goal is to provide a mechanism whereby the device's hardware queue never - * gets more than 3 frames ahead of the frames being generated by the application. - * When excessive queueing occurs, applications become unusable because the application - * visibly lags user input, and such problems make windowed interactive applications impossible. - * Some drivers may not have sufficient knowledge of their hardware's FIFO to know - * when a certain blt has been retired. Such drivers should code cautiously, and - * simply not allow any frames to be queued at all. DDBLT_LAST_PRESENTATION should cause - * such drivers to return DDERR_WASSTILLDRAWING until the accelerator is completely - * finished- exactly as if the application had called Lock on the source surface - * before calling Blt. - * In other words, the driver is allowed and encouraged to - * generate as much latency as it can, but never more than 3 frames worth. - * Implementation detail: Drivers should count blts against the SOURCE surface, not - * against the primary surface. This enables multiple parallel windowed application - * to function more optimally. - * This flag is passed only to DX8 or higher drivers. - * - * APPLICATIONS DO NOT SET THESE FLAGS. THEY ARE SET BY THE DIRECTDRAW RUNTIME. - * - */ -#define DDBLT_PRESENTATION 0x10000000l -#define DDBLT_LAST_PRESENTATION 0x20000000l - -/* - * If DDBLT_EXTENDED_FLAGS is set, then the driver should re-interpret - * other flags according to the definitions that follow. - * For example, bit 0 (0x00000001L) means DDBLT_ALPHADEST, unless - * DDBLT_EXTENDED_FLAGS is also set, in which case bit 0 means - * DDBLT_EXTENDED_LINEAR_CONTENT. - * Only DirectX9 and higher drivers will be given extended blt flags. - * Only flags explicitly mentioned here should be re-interpreted. - * All other flags retain their original meanings. - * - * List of re-interpreted flags: - * - * Bit Hex value New meaning old meaning - * --------------------------------------------------------------- - * 2 0x00000004 DDBLT_EXTENDED_LINEAR_CONTENT DDBLT_ALPHADESTNEG - * 4 0x00000010 DDBLT_EXTENDED_PRESENTATION_STRETCHFACTOR DDBLT_ALPHAEDGEBLEND - * - * - * NOTE: APPLICATIONS SHOULD NOT SET THIS FLAG. THIS FLAG IS INTENDED - * FOR USE BY THE DIRECT3D RUNTIME. - */ -#define DDBLT_EXTENDED_FLAGS 0x40000000l - -/* - * EXTENDED FLAG. SEE DEFINITION OF DDBLT_EXTENDED_FLAGS. - * This flag indidcates that the source surface contains content in a - * linear color space. The driver may perform gamma correction to the - * desktop color space (i.e. sRGB, gamma 2.2) as part of this blt. - * If the device can perform such a conversion as part of the copy, - * the driver should also set D3DCAPS3_LINEAR_TO_SRGB_PRESENTATION - * - * NOTE: APPLICATIONS SHOULD NOT SET THIS FLAG. THIS FLAG IS INTENDED - * FOR USE BY THE DIRECT3D RUNTIME. Use IDirect3DSwapChain9::Present - * and specify D3DPRESENT_LINEAR_CONTENT in order to use this functionality. - */ -#define DDBLT_EXTENDED_LINEAR_CONTENT 0x00000004l - - -/**************************************************************************** - * - * BLTFAST FLAGS - * - ****************************************************************************/ - -#define DDBLTFAST_NOCOLORKEY 0x00000000 -#define DDBLTFAST_SRCCOLORKEY 0x00000001 -#define DDBLTFAST_DESTCOLORKEY 0x00000002 -#define DDBLTFAST_WAIT 0x00000010 -#define DDBLTFAST_DONOTWAIT 0x00000020 - -/**************************************************************************** - * - * FLIP FLAGS - * - ****************************************************************************/ - -#define DDFLIP_WAIT 0x00000001L - -/* - * Indicates that the target surface contains the even field of video data. - * This flag is only valid with an overlay surface. - */ -#define DDFLIP_EVEN 0x00000002L - -/* - * Indicates that the target surface contains the odd field of video data. - * This flag is only valid with an overlay surface. - */ -#define DDFLIP_ODD 0x00000004L - -/* - * Causes DirectDraw to perform the physical flip immediately and return - * to the application. Typically, what was the front buffer but is now the back - * buffer will still be visible (depending on timing) until the next vertical - * retrace. Subsequent operations involving the two flipped surfaces will - * not check to see if the physical flip has finished (i.e. will not return - * DDERR_WASSTILLDRAWING for that reason (but may for other reasons)). - * This allows an application to perform Flips at a higher frequency than the - * monitor refresh rate, but may introduce visible artifacts. - * Only effective if DDCAPS2_FLIPNOVSYNC is set. If that bit is not set, - * DDFLIP_NOVSYNC has no effect. - */ -#define DDFLIP_NOVSYNC 0x00000008L - - -/* - * Flip Interval Flags. These flags indicate how many vertical retraces to wait between - * each flip. The default is one. DirectDraw will return DDERR_WASSTILLDRAWING for each - * surface involved in the flip until the specified number of vertical retraces has - * ocurred. Only effective if DDCAPS2_FLIPINTERVAL is set. If that bit is not set, - * DDFLIP_INTERVALn has no effect. - */ - -/* - * DirectDraw will flip on every other vertical sync - */ -#define DDFLIP_INTERVAL2 0x02000000L - - -/* - * DirectDraw will flip on every third vertical sync - */ -#define DDFLIP_INTERVAL3 0x03000000L - - -/* - * DirectDraw will flip on every fourth vertical sync - */ -#define DDFLIP_INTERVAL4 0x04000000L - -/* - * DirectDraw will flip and display a main stereo surface - */ -#define DDFLIP_STEREO 0x00000010L - -/* - * On IDirectDrawSurface7 and higher interfaces, the default is DDFLIP_WAIT. If you wish - * to override the default and use time when the accelerator is busy (as denoted by - * the DDERR_WASSTILLDRAWING return code) then use DDFLIP_DONOTWAIT. - */ -#define DDFLIP_DONOTWAIT 0x00000020L - - -/**************************************************************************** - * - * DIRECTDRAW SURFACE OVERLAY FLAGS - * - ****************************************************************************/ - -/* - * Use the alpha information in the pixel format or the alpha channel surface - * attached to the destination surface as the alpha channel for the - * destination overlay. - */ -#define DDOVER_ALPHADEST 0x00000001l - -/* - * Use the dwConstAlphaDest field in the DDOVERLAYFX structure as the - * destination alpha channel for this overlay. - */ -#define DDOVER_ALPHADESTCONSTOVERRIDE 0x00000002l - -/* - * The NEG suffix indicates that the destination surface becomes more - * transparent as the alpha value increases. - */ -#define DDOVER_ALPHADESTNEG 0x00000004l - -/* - * Use the lpDDSAlphaDest field in the DDOVERLAYFX structure as the alpha - * channel destination for this overlay. - */ -#define DDOVER_ALPHADESTSURFACEOVERRIDE 0x00000008l - -/* - * Use the dwAlphaEdgeBlend field in the DDOVERLAYFX structure as the alpha - * channel for the edges of the image that border the color key colors. - */ -#define DDOVER_ALPHAEDGEBLEND 0x00000010l - -/* - * Use the alpha information in the pixel format or the alpha channel surface - * attached to the source surface as the source alpha channel for this overlay. - */ -#define DDOVER_ALPHASRC 0x00000020l - -/* - * Use the dwConstAlphaSrc field in the DDOVERLAYFX structure as the source - * alpha channel for this overlay. - */ -#define DDOVER_ALPHASRCCONSTOVERRIDE 0x00000040l - -/* - * The NEG suffix indicates that the source surface becomes more transparent - * as the alpha value increases. - */ -#define DDOVER_ALPHASRCNEG 0x00000080l - -/* - * Use the lpDDSAlphaSrc field in the DDOVERLAYFX structure as the alpha channel - * source for this overlay. - */ -#define DDOVER_ALPHASRCSURFACEOVERRIDE 0x00000100l - -/* - * Turn this overlay off. - */ -#define DDOVER_HIDE 0x00000200l - -/* - * Use the color key associated with the destination surface. - */ -#define DDOVER_KEYDEST 0x00000400l - -/* - * Use the dckDestColorkey field in the DDOVERLAYFX structure as the color key - * for the destination surface - */ -#define DDOVER_KEYDESTOVERRIDE 0x00000800l - -/* - * Use the color key associated with the source surface. - */ -#define DDOVER_KEYSRC 0x00001000l - -/* - * Use the dckSrcColorkey field in the DDOVERLAYFX structure as the color key - * for the source surface. - */ -#define DDOVER_KEYSRCOVERRIDE 0x00002000l - -/* - * Turn this overlay on. - */ -#define DDOVER_SHOW 0x00004000l - -/* - * Add a dirty rect to an emulated overlayed surface. - */ -#define DDOVER_ADDDIRTYRECT 0x00008000l - -/* - * Redraw all dirty rects on an emulated overlayed surface. - */ -#define DDOVER_REFRESHDIRTYRECTS 0x00010000l - -/* - * Redraw the entire surface on an emulated overlayed surface. - */ -#define DDOVER_REFRESHALL 0x00020000l - - -/* - * Use the overlay FX flags to define special overlay FX - */ -#define DDOVER_DDFX 0x00080000l - -/* - * Autoflip the overlay when ever the video port autoflips - */ -#define DDOVER_AUTOFLIP 0x00100000l - -/* - * Display each field of video port data individually without - * causing any jittery artifacts - */ -#define DDOVER_BOB 0x00200000l - -/* - * Indicates that bob/weave decisions should not be overridden by other - * interfaces. - */ -#define DDOVER_OVERRIDEBOBWEAVE 0x00400000l - -/* - * Indicates that the surface memory is composed of interleaved fields. - */ -#define DDOVER_INTERLEAVED 0x00800000l - -/* - * Indicates that bob will be performed using hardware rather than - * software or emulated. - */ -#define DDOVER_BOBHARDWARE 0x01000000l - -/* - * Indicates that overlay FX structure contains valid ARGB scaling factors. - */ -#define DDOVER_ARGBSCALEFACTORS 0x02000000l - -/* - * Indicates that ARGB scaling factors can be degraded to fit driver capabilities. - */ -#define DDOVER_DEGRADEARGBSCALING 0x04000000l - - -/**************************************************************************** - * - * DIRECTDRAWSURFACE LOCK FLAGS - * - ****************************************************************************/ - -/* - * The default. Set to indicate that Lock should return a valid memory pointer - * to the top of the specified rectangle. If no rectangle is specified then a - * pointer to the top of the surface is returned. - */ -#define DDLOCK_SURFACEMEMORYPTR 0x00000000L // default - -/* - * Set to indicate that Lock should wait until it can obtain a valid memory - * pointer before returning. If this bit is set, Lock will never return - * DDERR_WASSTILLDRAWING. - */ -#define DDLOCK_WAIT 0x00000001L - -/* - * Set if an event handle is being passed to Lock. Lock will trigger the event - * when it can return the surface memory pointer requested. - */ -#define DDLOCK_EVENT 0x00000002L - -/* - * Indicates that the surface being locked will only be read from. - */ -#define DDLOCK_READONLY 0x00000010L - -/* - * Indicates that the surface being locked will only be written to - */ -#define DDLOCK_WRITEONLY 0x00000020L - - -/* - * Indicates that a system wide lock should not be taken when this surface - * is locked. This has several advantages (cursor responsiveness, ability - * to call more Windows functions, easier debugging) when locking video - * memory surfaces. However, an application specifying this flag must - * comply with a number of conditions documented in the help file. - * Furthermore, this flag cannot be specified when locking the primary. - */ -#define DDLOCK_NOSYSLOCK 0x00000800L - -/* - * Used only with Direct3D Vertex Buffer Locks. Indicates that no vertices - * that were referred to in Draw*PrimtiveVB calls since the start of the - * frame (or the last lock without this flag) will be modified during the - * lock. This can be useful when one is only appending data to the vertex - * buffer - */ -#define DDLOCK_NOOVERWRITE 0x00001000L - -/* - * Indicates that no assumptions will be made about the contents of the - * surface or vertex buffer during this lock. - * This enables two things: - * - Direct3D or the driver may provide an alternative memory - * area as the vertex buffer. This is useful when one plans to clear the - * contents of the vertex buffer and fill in new data. - * - Drivers sometimes store surface data in a re-ordered format. - * When the application locks the surface, the driver is forced to un-re-order - * the surface data before allowing the application to see the surface contents. - * This flag is a hint to the driver that it can skip the un-re-ordering process - * since the application plans to overwrite every single pixel in the surface - * or locked rectangle (and so erase any un-re-ordered pixels anyway). - * Applications should always set this flag when they intend to overwrite the entire - * surface or locked rectangle. - */ -#define DDLOCK_DISCARDCONTENTS 0x00002000L - /* - * DDLOCK_OKTOSWAP is an older, less informative name for DDLOCK_DISCARDCONTENTS - */ -#define DDLOCK_OKTOSWAP 0x00002000L - -/* - * On IDirectDrawSurface7 and higher interfaces, the default is DDLOCK_WAIT. If you wish - * to override the default and use time when the accelerator is busy (as denoted by - * the DDERR_WASSTILLDRAWING return code) then use DDLOCK_DONOTWAIT. - */ -#define DDLOCK_DONOTWAIT 0x00004000L - -/* - * This indicates volume texture lock with front and back specified. - */ -#define DDLOCK_HASVOLUMETEXTUREBOXRECT 0x00008000L - -/* - * This indicates that the driver should not update dirty rect information for this lock. - */ -#define DDLOCK_NODIRTYUPDATE 0x00010000L - - -/**************************************************************************** - * - * DIRECTDRAWSURFACE PAGELOCK FLAGS - * - ****************************************************************************/ - -/* - * No flags defined at present - */ - - -/**************************************************************************** - * - * DIRECTDRAWSURFACE PAGEUNLOCK FLAGS - * - ****************************************************************************/ - -/* - * No flags defined at present - */ - - -/**************************************************************************** - * - * DIRECTDRAWSURFACE BLT FX FLAGS - * - ****************************************************************************/ - -/* - * If stretching, use arithmetic stretching along the Y axis for this blt. - */ -#define DDBLTFX_ARITHSTRETCHY 0x00000001l - -/* - * Do this blt mirroring the surface left to right. Spin the - * surface around its y-axis. - */ -#define DDBLTFX_MIRRORLEFTRIGHT 0x00000002l - -/* - * Do this blt mirroring the surface up and down. Spin the surface - * around its x-axis. - */ -#define DDBLTFX_MIRRORUPDOWN 0x00000004l - -/* - * Schedule this blt to avoid tearing. - */ -#define DDBLTFX_NOTEARING 0x00000008l - -/* - * Do this blt rotating the surface one hundred and eighty degrees. - */ -#define DDBLTFX_ROTATE180 0x00000010l - -/* - * Do this blt rotating the surface two hundred and seventy degrees. - */ -#define DDBLTFX_ROTATE270 0x00000020l - -/* - * Do this blt rotating the surface ninety degrees. - */ -#define DDBLTFX_ROTATE90 0x00000040l - -/* - * Do this z blt using dwZBufferLow and dwZBufferHigh as range values - * specified to limit the bits copied from the source surface. - */ -#define DDBLTFX_ZBUFFERRANGE 0x00000080l - -/* - * Do this z blt adding the dwZBufferBaseDest to each of the sources z values - * before comparing it with the desting z values. - */ -#define DDBLTFX_ZBUFFERBASEDEST 0x00000100l - -/**************************************************************************** - * - * DIRECTDRAWSURFACE OVERLAY FX FLAGS - * - ****************************************************************************/ - -/* - * If stretching, use arithmetic stretching along the Y axis for this overlay. - */ -#define DDOVERFX_ARITHSTRETCHY 0x00000001l - -/* - * Mirror the overlay across the vertical axis - */ -#define DDOVERFX_MIRRORLEFTRIGHT 0x00000002l - -/* - * Mirror the overlay across the horizontal axis - */ -#define DDOVERFX_MIRRORUPDOWN 0x00000004l - -/* - * Deinterlace the overlay, if possible - */ -#define DDOVERFX_DEINTERLACE 0x00000008l - - -/**************************************************************************** - * - * DIRECTDRAW WAITFORVERTICALBLANK FLAGS - * - ****************************************************************************/ - -/* - * return when the vertical blank interval begins - */ -#define DDWAITVB_BLOCKBEGIN 0x00000001l - -/* - * set up an event to trigger when the vertical blank begins - */ -#define DDWAITVB_BLOCKBEGINEVENT 0x00000002l - -/* - * return when the vertical blank interval ends and display begins - */ -#define DDWAITVB_BLOCKEND 0x00000004l - -/**************************************************************************** - * - * DIRECTDRAW GETFLIPSTATUS FLAGS - * - ****************************************************************************/ - -/* - * is it OK to flip now? - */ -#define DDGFS_CANFLIP 0x00000001l - -/* - * is the last flip finished? - */ -#define DDGFS_ISFLIPDONE 0x00000002l - -/**************************************************************************** - * - * DIRECTDRAW GETBLTSTATUS FLAGS - * - ****************************************************************************/ - -/* - * is it OK to blt now? - */ -#define DDGBS_CANBLT 0x00000001l - -/* - * is the blt to the surface finished? - */ -#define DDGBS_ISBLTDONE 0x00000002l - - -/**************************************************************************** - * - * DIRECTDRAW ENUMOVERLAYZORDER FLAGS - * - ****************************************************************************/ - -/* - * Enumerate overlays back to front. - */ -#define DDENUMOVERLAYZ_BACKTOFRONT 0x00000000l - -/* - * Enumerate overlays front to back - */ -#define DDENUMOVERLAYZ_FRONTTOBACK 0x00000001l - -/**************************************************************************** - * - * DIRECTDRAW UPDATEOVERLAYZORDER FLAGS - * - ****************************************************************************/ - -/* - * Send overlay to front - */ -#define DDOVERZ_SENDTOFRONT 0x00000000l - -/* - * Send overlay to back - */ -#define DDOVERZ_SENDTOBACK 0x00000001l - -/* - * Move Overlay forward - */ -#define DDOVERZ_MOVEFORWARD 0x00000002l - -/* - * Move Overlay backward - */ -#define DDOVERZ_MOVEBACKWARD 0x00000003l - -/* - * Move Overlay in front of relative surface - */ -#define DDOVERZ_INSERTINFRONTOF 0x00000004l - -/* - * Move Overlay in back of relative surface - */ -#define DDOVERZ_INSERTINBACKOF 0x00000005l - - -/**************************************************************************** - * - * DIRECTDRAW SETGAMMARAMP FLAGS - * - ****************************************************************************/ - -/* - * Request calibrator to adjust the gamma ramp according to the physical - * properties of the display so that the result should appear identical - * on all systems. - */ -#define DDSGR_CALIBRATE 0x00000001L - - -/**************************************************************************** - * - * DIRECTDRAW STARTMODETEST FLAGS - * - ****************************************************************************/ - -/* - * Indicates that the mode being tested has passed - */ -#define DDSMT_ISTESTREQUIRED 0x00000001L - - -/**************************************************************************** - * - * DIRECTDRAW EVALUATEMODE FLAGS - * - ****************************************************************************/ - -/* - * Indicates that the mode being tested has passed - */ -#define DDEM_MODEPASSED 0x00000001L - -/* - * Indicates that the mode being tested has failed - */ -#define DDEM_MODEFAILED 0x00000002L - - -/*=========================================================================== - * - * - * DIRECTDRAW RETURN CODES - * - * The return values from DirectDraw Commands and Surface that return an HRESULT - * are codes from DirectDraw concerning the results of the action - * requested by DirectDraw. - * - *==========================================================================*/ - -/* - * Status is OK - * - * Issued by: DirectDraw Commands and all callbacks - */ -#define DD_OK S_OK -#define DD_FALSE S_FALSE - -/**************************************************************************** - * - * DIRECTDRAW ENUMCALLBACK RETURN VALUES - * - * EnumCallback returns are used to control the flow of the DIRECTDRAW and - * DIRECTDRAWSURFACE object enumerations. They can only be returned by - * enumeration callback routines. - * - ****************************************************************************/ - -/* - * stop the enumeration - */ -#define DDENUMRET_CANCEL 0 - -/* - * continue the enumeration - */ -#define DDENUMRET_OK 1 - -/**************************************************************************** - * - * DIRECTDRAW ERRORS - * - * Errors are represented by negative values and cannot be combined. - * - ****************************************************************************/ - -/* - * This object is already initialized - */ -#define DDERR_ALREADYINITIALIZED MAKE_DDHRESULT( 5 ) - -/* - * This surface can not be attached to the requested surface. - */ -#define DDERR_CANNOTATTACHSURFACE MAKE_DDHRESULT( 10 ) - -/* - * This surface can not be detached from the requested surface. - */ -#define DDERR_CANNOTDETACHSURFACE MAKE_DDHRESULT( 20 ) - -/* - * Support is currently not available. - */ -#define DDERR_CURRENTLYNOTAVAIL MAKE_DDHRESULT( 40 ) - -/* - * An exception was encountered while performing the requested operation - */ -#define DDERR_EXCEPTION MAKE_DDHRESULT( 55 ) - -/* - * Generic failure. - */ -#define DDERR_GENERIC E_FAIL - -/* - * Height of rectangle provided is not a multiple of reqd alignment - */ -#define DDERR_HEIGHTALIGN MAKE_DDHRESULT( 90 ) - -/* - * Unable to match primary surface creation request with existing - * primary surface. - */ -#define DDERR_INCOMPATIBLEPRIMARY MAKE_DDHRESULT( 95 ) - -/* - * One or more of the caps bits passed to the callback are incorrect. - */ -#define DDERR_INVALIDCAPS MAKE_DDHRESULT( 100 ) - -/* - * DirectDraw does not support provided Cliplist. - */ -#define DDERR_INVALIDCLIPLIST MAKE_DDHRESULT( 110 ) - -/* - * DirectDraw does not support the requested mode - */ -#define DDERR_INVALIDMODE MAKE_DDHRESULT( 120 ) - -/* - * DirectDraw received a pointer that was an invalid DIRECTDRAW object. - */ -#define DDERR_INVALIDOBJECT MAKE_DDHRESULT( 130 ) - -/* - * One or more of the parameters passed to the callback function are - * incorrect. - */ -#define DDERR_INVALIDPARAMS E_INVALIDARG - -/* - * pixel format was invalid as specified - */ -#define DDERR_INVALIDPIXELFORMAT MAKE_DDHRESULT( 145 ) - -/* - * Rectangle provided was invalid. - */ -#define DDERR_INVALIDRECT MAKE_DDHRESULT( 150 ) - -/* - * Operation could not be carried out because one or more surfaces are locked - */ -#define DDERR_LOCKEDSURFACES MAKE_DDHRESULT( 160 ) - -/* - * There is no 3D present. - */ -#define DDERR_NO3D MAKE_DDHRESULT( 170 ) - -/* - * Operation could not be carried out because there is no alpha accleration - * hardware present or available. - */ -#define DDERR_NOALPHAHW MAKE_DDHRESULT( 180 ) - -/* - * Operation could not be carried out because there is no stereo - * hardware present or available. - */ -#define DDERR_NOSTEREOHARDWARE MAKE_DDHRESULT( 181 ) - -/* - * Operation could not be carried out because there is no hardware - * present which supports stereo surfaces - */ -#define DDERR_NOSURFACELEFT MAKE_DDHRESULT( 182 ) - - - -/* - * no clip list available - */ -#define DDERR_NOCLIPLIST MAKE_DDHRESULT( 205 ) - -/* - * Operation could not be carried out because there is no color conversion - * hardware present or available. - */ -#define DDERR_NOCOLORCONVHW MAKE_DDHRESULT( 210 ) - -/* - * Create function called without DirectDraw object method SetCooperativeLevel - * being called. - */ -#define DDERR_NOCOOPERATIVELEVELSET MAKE_DDHRESULT( 212 ) - -/* - * Surface doesn't currently have a color key - */ -#define DDERR_NOCOLORKEY MAKE_DDHRESULT( 215 ) - -/* - * Operation could not be carried out because there is no hardware support - * of the dest color key. - */ -#define DDERR_NOCOLORKEYHW MAKE_DDHRESULT( 220 ) - -/* - * No DirectDraw support possible with current display driver - */ -#define DDERR_NODIRECTDRAWSUPPORT MAKE_DDHRESULT( 222 ) - -/* - * Operation requires the application to have exclusive mode but the - * application does not have exclusive mode. - */ -#define DDERR_NOEXCLUSIVEMODE MAKE_DDHRESULT( 225 ) - -/* - * Flipping visible surfaces is not supported. - */ -#define DDERR_NOFLIPHW MAKE_DDHRESULT( 230 ) - -/* - * There is no GDI present. - */ -#define DDERR_NOGDI MAKE_DDHRESULT( 240 ) - -/* - * Operation could not be carried out because there is no hardware present - * or available. - */ -#define DDERR_NOMIRRORHW MAKE_DDHRESULT( 250 ) - -/* - * Requested item was not found - */ -#define DDERR_NOTFOUND MAKE_DDHRESULT( 255 ) - -/* - * Operation could not be carried out because there is no overlay hardware - * present or available. - */ -#define DDERR_NOOVERLAYHW MAKE_DDHRESULT( 260 ) - -/* - * Operation could not be carried out because the source and destination - * rectangles are on the same surface and overlap each other. - */ -#define DDERR_OVERLAPPINGRECTS MAKE_DDHRESULT( 270 ) - -/* - * Operation could not be carried out because there is no appropriate raster - * op hardware present or available. - */ -#define DDERR_NORASTEROPHW MAKE_DDHRESULT( 280 ) - -/* - * Operation could not be carried out because there is no rotation hardware - * present or available. - */ -#define DDERR_NOROTATIONHW MAKE_DDHRESULT( 290 ) - -/* - * Operation could not be carried out because there is no hardware support - * for stretching - */ -#define DDERR_NOSTRETCHHW MAKE_DDHRESULT( 310 ) - -/* - * DirectDrawSurface is not in 4 bit color palette and the requested operation - * requires 4 bit color palette. - */ -#define DDERR_NOT4BITCOLOR MAKE_DDHRESULT( 316 ) - -/* - * DirectDrawSurface is not in 4 bit color index palette and the requested - * operation requires 4 bit color index palette. - */ -#define DDERR_NOT4BITCOLORINDEX MAKE_DDHRESULT( 317 ) - -/* - * DirectDraw Surface is not in 8 bit color mode and the requested operation - * requires 8 bit color. - */ -#define DDERR_NOT8BITCOLOR MAKE_DDHRESULT( 320 ) - -/* - * Operation could not be carried out because there is no texture mapping - * hardware present or available. - */ -#define DDERR_NOTEXTUREHW MAKE_DDHRESULT( 330 ) - -/* - * Operation could not be carried out because there is no hardware support - * for vertical blank synchronized operations. - */ -#define DDERR_NOVSYNCHW MAKE_DDHRESULT( 335 ) - -/* - * Operation could not be carried out because there is no hardware support - * for zbuffer blting. - */ -#define DDERR_NOZBUFFERHW MAKE_DDHRESULT( 340 ) - -/* - * Overlay surfaces could not be z layered based on their BltOrder because - * the hardware does not support z layering of overlays. - */ -#define DDERR_NOZOVERLAYHW MAKE_DDHRESULT( 350 ) - -/* - * The hardware needed for the requested operation has already been - * allocated. - */ -#define DDERR_OUTOFCAPS MAKE_DDHRESULT( 360 ) - -/* - * DirectDraw does not have enough memory to perform the operation. - */ -#define DDERR_OUTOFMEMORY E_OUTOFMEMORY - -/* - * DirectDraw does not have enough memory to perform the operation. - */ -#define DDERR_OUTOFVIDEOMEMORY MAKE_DDHRESULT( 380 ) - -/* - * hardware does not support clipped overlays - */ -#define DDERR_OVERLAYCANTCLIP MAKE_DDHRESULT( 382 ) - -/* - * Can only have ony color key active at one time for overlays - */ -#define DDERR_OVERLAYCOLORKEYONLYONEACTIVE MAKE_DDHRESULT( 384 ) - -/* - * Access to this palette is being refused because the palette is already - * locked by another thread. - */ -#define DDERR_PALETTEBUSY MAKE_DDHRESULT( 387 ) - -/* - * No src color key specified for this operation. - */ -#define DDERR_COLORKEYNOTSET MAKE_DDHRESULT( 400 ) - -/* - * This surface is already attached to the surface it is being attached to. - */ -#define DDERR_SURFACEALREADYATTACHED MAKE_DDHRESULT( 410 ) - -/* - * This surface is already a dependency of the surface it is being made a - * dependency of. - */ -#define DDERR_SURFACEALREADYDEPENDENT MAKE_DDHRESULT( 420 ) - -/* - * Access to this surface is being refused because the surface is already - * locked by another thread. - */ -#define DDERR_SURFACEBUSY MAKE_DDHRESULT( 430 ) - -/* - * Access to this surface is being refused because no driver exists - * which can supply a pointer to the surface. - * This is most likely to happen when attempting to lock the primary - * surface when no DCI provider is present. - * Will also happen on attempts to lock an optimized surface. - */ -#define DDERR_CANTLOCKSURFACE MAKE_DDHRESULT( 435 ) - -/* - * Access to Surface refused because Surface is obscured. - */ -#define DDERR_SURFACEISOBSCURED MAKE_DDHRESULT( 440 ) - -/* - * Access to this surface is being refused because the surface is gone. - * The DIRECTDRAWSURFACE object representing this surface should - * have Restore called on it. - */ -#define DDERR_SURFACELOST MAKE_DDHRESULT( 450 ) - -/* - * The requested surface is not attached. - */ -#define DDERR_SURFACENOTATTACHED MAKE_DDHRESULT( 460 ) - -/* - * Height requested by DirectDraw is too large. - */ -#define DDERR_TOOBIGHEIGHT MAKE_DDHRESULT( 470 ) - -/* - * Size requested by DirectDraw is too large -- The individual height and - * width are OK. - */ -#define DDERR_TOOBIGSIZE MAKE_DDHRESULT( 480 ) - -/* - * Width requested by DirectDraw is too large. - */ -#define DDERR_TOOBIGWIDTH MAKE_DDHRESULT( 490 ) - -/* - * Action not supported. - */ -#define DDERR_UNSUPPORTED E_NOTIMPL - -/* - * Pixel format requested is unsupported by DirectDraw - */ -#define DDERR_UNSUPPORTEDFORMAT MAKE_DDHRESULT( 510 ) - -/* - * Bitmask in the pixel format requested is unsupported by DirectDraw - */ -#define DDERR_UNSUPPORTEDMASK MAKE_DDHRESULT( 520 ) - -/* - * The specified stream contains invalid data - */ -#define DDERR_INVALIDSTREAM MAKE_DDHRESULT( 521 ) - -/* - * vertical blank is in progress - */ -#define DDERR_VERTICALBLANKINPROGRESS MAKE_DDHRESULT( 537 ) - -/* - * Informs DirectDraw that the previous Blt which is transfering information - * to or from this Surface is incomplete. - */ -#define DDERR_WASSTILLDRAWING MAKE_DDHRESULT( 540 ) - - -/* - * The specified surface type requires specification of the COMPLEX flag - */ -#define DDERR_DDSCAPSCOMPLEXREQUIRED MAKE_DDHRESULT( 542 ) - - -/* - * Rectangle provided was not horizontally aligned on reqd. boundary - */ -#define DDERR_XALIGN MAKE_DDHRESULT( 560 ) - -/* - * The GUID passed to DirectDrawCreate is not a valid DirectDraw driver - * identifier. - */ -#define DDERR_INVALIDDIRECTDRAWGUID MAKE_DDHRESULT( 561 ) - -/* - * A DirectDraw object representing this driver has already been created - * for this process. - */ -#define DDERR_DIRECTDRAWALREADYCREATED MAKE_DDHRESULT( 562 ) - -/* - * A hardware only DirectDraw object creation was attempted but the driver - * did not support any hardware. - */ -#define DDERR_NODIRECTDRAWHW MAKE_DDHRESULT( 563 ) - -/* - * this process already has created a primary surface - */ -#define DDERR_PRIMARYSURFACEALREADYEXISTS MAKE_DDHRESULT( 564 ) - -/* - * software emulation not available. - */ -#define DDERR_NOEMULATION MAKE_DDHRESULT( 565 ) - -/* - * region passed to Clipper::GetClipList is too small. - */ -#define DDERR_REGIONTOOSMALL MAKE_DDHRESULT( 566 ) - -/* - * an attempt was made to set a clip list for a clipper objec that - * is already monitoring an hwnd. - */ -#define DDERR_CLIPPERISUSINGHWND MAKE_DDHRESULT( 567 ) - -/* - * No clipper object attached to surface object - */ -#define DDERR_NOCLIPPERATTACHED MAKE_DDHRESULT( 568 ) - -/* - * Clipper notification requires an HWND or - * no HWND has previously been set as the CooperativeLevel HWND. - */ -#define DDERR_NOHWND MAKE_DDHRESULT( 569 ) - -/* - * HWND used by DirectDraw CooperativeLevel has been subclassed, - * this prevents DirectDraw from restoring state. - */ -#define DDERR_HWNDSUBCLASSED MAKE_DDHRESULT( 570 ) - -/* - * The CooperativeLevel HWND has already been set. - * It can not be reset while the process has surfaces or palettes created. - */ -#define DDERR_HWNDALREADYSET MAKE_DDHRESULT( 571 ) - -/* - * No palette object attached to this surface. - */ -#define DDERR_NOPALETTEATTACHED MAKE_DDHRESULT( 572 ) - -/* - * No hardware support for 16 or 256 color palettes. - */ -#define DDERR_NOPALETTEHW MAKE_DDHRESULT( 573 ) - -/* - * If a clipper object is attached to the source surface passed into a - * BltFast call. - */ -#define DDERR_BLTFASTCANTCLIP MAKE_DDHRESULT( 574 ) - -/* - * No blter. - */ -#define DDERR_NOBLTHW MAKE_DDHRESULT( 575 ) - -/* - * No DirectDraw ROP hardware. - */ -#define DDERR_NODDROPSHW MAKE_DDHRESULT( 576 ) - -/* - * returned when GetOverlayPosition is called on a hidden overlay - */ -#define DDERR_OVERLAYNOTVISIBLE MAKE_DDHRESULT( 577 ) - -/* - * returned when GetOverlayPosition is called on a overlay that UpdateOverlay - * has never been called on to establish a destionation. - */ -#define DDERR_NOOVERLAYDEST MAKE_DDHRESULT( 578 ) - -/* - * returned when the position of the overlay on the destionation is no longer - * legal for that destionation. - */ -#define DDERR_INVALIDPOSITION MAKE_DDHRESULT( 579 ) - -/* - * returned when an overlay member is called for a non-overlay surface - */ -#define DDERR_NOTAOVERLAYSURFACE MAKE_DDHRESULT( 580 ) - -/* - * An attempt was made to set the cooperative level when it was already - * set to exclusive. - */ -#define DDERR_EXCLUSIVEMODEALREADYSET MAKE_DDHRESULT( 581 ) - -/* - * An attempt has been made to flip a surface that is not flippable. - */ -#define DDERR_NOTFLIPPABLE MAKE_DDHRESULT( 582 ) - -/* - * Can't duplicate primary & 3D surfaces, or surfaces that are implicitly - * created. - */ -#define DDERR_CANTDUPLICATE MAKE_DDHRESULT( 583 ) - -/* - * Surface was not locked. An attempt to unlock a surface that was not - * locked at all, or by this process, has been attempted. - */ -#define DDERR_NOTLOCKED MAKE_DDHRESULT( 584 ) - -/* - * Windows can not create any more DCs, or a DC was requested for a paltte-indexed - * surface when the surface had no palette AND the display mode was not palette-indexed - * (in this case DirectDraw cannot select a proper palette into the DC) - */ -#define DDERR_CANTCREATEDC MAKE_DDHRESULT( 585 ) - -/* - * No DC was ever created for this surface. - */ -#define DDERR_NODC MAKE_DDHRESULT( 586 ) - -/* - * This surface can not be restored because it was created in a different - * mode. - */ -#define DDERR_WRONGMODE MAKE_DDHRESULT( 587 ) - -/* - * This surface can not be restored because it is an implicitly created - * surface. - */ -#define DDERR_IMPLICITLYCREATED MAKE_DDHRESULT( 588 ) - -/* - * The surface being used is not a palette-based surface - */ -#define DDERR_NOTPALETTIZED MAKE_DDHRESULT( 589 ) - - -/* - * The display is currently in an unsupported mode - */ -#define DDERR_UNSUPPORTEDMODE MAKE_DDHRESULT( 590 ) - -/* - * Operation could not be carried out because there is no mip-map - * texture mapping hardware present or available. - */ -#define DDERR_NOMIPMAPHW MAKE_DDHRESULT( 591 ) - -/* - * The requested action could not be performed because the surface was of - * the wrong type. - */ -#define DDERR_INVALIDSURFACETYPE MAKE_DDHRESULT( 592 ) - - -/* - * Device does not support optimized surfaces, therefore no video memory optimized surfaces - */ -#define DDERR_NOOPTIMIZEHW MAKE_DDHRESULT( 600 ) - -/* - * Surface is an optimized surface, but has not yet been allocated any memory - */ -#define DDERR_NOTLOADED MAKE_DDHRESULT( 601 ) - -/* - * Attempt was made to create or set a device window without first setting - * the focus window - */ -#define DDERR_NOFOCUSWINDOW MAKE_DDHRESULT( 602 ) - -/* - * Attempt was made to set a palette on a mipmap sublevel - */ -#define DDERR_NOTONMIPMAPSUBLEVEL MAKE_DDHRESULT( 603 ) - -/* - * A DC has already been returned for this surface. Only one DC can be - * retrieved per surface. - */ -#define DDERR_DCALREADYCREATED MAKE_DDHRESULT( 620 ) - -/* - * An attempt was made to allocate non-local video memory from a device - * that does not support non-local video memory. - */ -#define DDERR_NONONLOCALVIDMEM MAKE_DDHRESULT( 630 ) - -/* - * The attempt to page lock a surface failed. - */ -#define DDERR_CANTPAGELOCK MAKE_DDHRESULT( 640 ) - - -/* - * The attempt to page unlock a surface failed. - */ -#define DDERR_CANTPAGEUNLOCK MAKE_DDHRESULT( 660 ) - -/* - * An attempt was made to page unlock a surface with no outstanding page locks. - */ -#define DDERR_NOTPAGELOCKED MAKE_DDHRESULT( 680 ) - -/* - * There is more data available than the specified buffer size could hold - */ -#define DDERR_MOREDATA MAKE_DDHRESULT( 690 ) - -/* - * The data has expired and is therefore no longer valid. - */ -#define DDERR_EXPIRED MAKE_DDHRESULT( 691 ) - -/* - * The mode test has finished executing. - */ -#define DDERR_TESTFINISHED MAKE_DDHRESULT( 692 ) - -/* - * The mode test has switched to a new mode. - */ -#define DDERR_NEWMODE MAKE_DDHRESULT( 693 ) - -/* - * D3D has not yet been initialized. - */ -#define DDERR_D3DNOTINITIALIZED MAKE_DDHRESULT( 694 ) - -/* - * The video port is not active - */ -#define DDERR_VIDEONOTACTIVE MAKE_DDHRESULT( 695 ) - -/* - * The monitor does not have EDID data. - */ -#define DDERR_NOMONITORINFORMATION MAKE_DDHRESULT( 696 ) - -/* - * The driver does not enumerate display mode refresh rates. - */ -#define DDERR_NODRIVERSUPPORT MAKE_DDHRESULT( 697 ) - -/* - * Surfaces created by one direct draw device cannot be used directly by - * another direct draw device. - */ -#define DDERR_DEVICEDOESNTOWNSURFACE MAKE_DDHRESULT( 699 ) - - - -/* - * An attempt was made to invoke an interface member of a DirectDraw object - * created by CoCreateInstance() before it was initialized. - */ -#define DDERR_NOTINITIALIZED CO_E_NOTINITIALIZED - - -/* Alpha bit depth constants */ - - -#ifdef __cplusplus -}; -#endif - -#ifdef ENABLE_NAMELESS_UNION_PRAGMA -#pragma warning(default:4201) -#endif - -#endif //__DDRAW_INCLUDED__ - - +/*==========================================================================; + * + * Copyright (C) Microsoft Corporation. All Rights Reserved. + * + * File: ddraw.h + * Content: DirectDraw include file + * + ***************************************************************************/ + +#ifndef __DDRAW_INCLUDED__ +#define __DDRAW_INCLUDED__ + +//Disable the nameless union warning when building internally +#undef ENABLE_NAMELESS_UNION_PRAGMA +#ifdef DIRECTX_REDIST +#define ENABLE_NAMELESS_UNION_PRAGMA +#endif + +#ifdef ENABLE_NAMELESS_UNION_PRAGMA +#pragma warning(disable:4201) +#endif + +/* + * If you wish an application built against the newest version of DirectDraw + * to run against an older DirectDraw run time then define DIRECTDRAW_VERSION + * to be the earlies version of DirectDraw you wish to run against. For, + * example if you wish an application to run against a DX 3 runtime define + * DIRECTDRAW_VERSION to be 0x0300. + */ +#ifndef DIRECTDRAW_VERSION +#define DIRECTDRAW_VERSION 0x0700 +#endif /* DIRECTDRAW_VERSION */ + +#if defined( _WIN32 ) && !defined( _NO_COM ) +#define COM_NO_WINDOWS_H +#include +#else +#define IUnknown void +#if !defined( NT_BUILD_ENVIRONMENT ) && !defined(WINNT) + #define CO_E_NOTINITIALIZED 0x800401F0L +#endif +#endif + +#define _FACDD 0x876 +#define MAKE_DDHRESULT( code ) MAKE_HRESULT( 1, _FACDD, code ) + +#ifdef __cplusplus +extern "C" { +#endif + +// +// For compilers that don't support nameless unions, do a +// +// #define NONAMELESSUNION +// +// before #include +// +#ifndef DUMMYUNIONNAMEN +#if defined(__cplusplus) || !defined(NONAMELESSUNION) +#define DUMMYUNIONNAMEN(n) +#else +#define DUMMYUNIONNAMEN(n) u##n +#endif +#endif + +#ifndef MAKEFOURCC + #define MAKEFOURCC(ch0, ch1, ch2, ch3) \ + ((DWORD)(BYTE)(ch0) | ((DWORD)(BYTE)(ch1) << 8) | \ + ((DWORD)(BYTE)(ch2) << 16) | ((DWORD)(BYTE)(ch3) << 24 )) +#endif //defined(MAKEFOURCC) + +/* + * FOURCC codes for DX compressed-texture pixel formats + */ +#define FOURCC_DXT1 (MAKEFOURCC('D','X','T','1')) +#define FOURCC_DXT2 (MAKEFOURCC('D','X','T','2')) +#define FOURCC_DXT3 (MAKEFOURCC('D','X','T','3')) +#define FOURCC_DXT4 (MAKEFOURCC('D','X','T','4')) +#define FOURCC_DXT5 (MAKEFOURCC('D','X','T','5')) + +/* + * GUIDS used by DirectDraw objects + */ +#if defined( _WIN32 ) && !defined( _NO_COM ) + +DEFINE_GUID( CLSID_DirectDraw, 0xD7B70EE0,0x4340,0x11CF,0xB0,0x63,0x00,0x20,0xAF,0xC2,0xCD,0x35 ); +DEFINE_GUID( CLSID_DirectDraw7, 0x3c305196,0x50db,0x11d3,0x9c,0xfe,0x00,0xc0,0x4f,0xd9,0x30,0xc5 ); +DEFINE_GUID( CLSID_DirectDrawClipper, 0x593817A0,0x7DB3,0x11CF,0xA2,0xDE,0x00,0xAA,0x00,0xb9,0x33,0x56 ); +DEFINE_GUID( IID_IDirectDraw, 0x6C14DB80,0xA733,0x11CE,0xA5,0x21,0x00,0x20,0xAF,0x0B,0xE5,0x60 ); +DEFINE_GUID( IID_IDirectDraw2, 0xB3A6F3E0,0x2B43,0x11CF,0xA2,0xDE,0x00,0xAA,0x00,0xB9,0x33,0x56 ); +DEFINE_GUID( IID_IDirectDraw4, 0x9c59509a,0x39bd,0x11d1,0x8c,0x4a,0x00,0xc0,0x4f,0xd9,0x30,0xc5 ); +DEFINE_GUID( IID_IDirectDraw7, 0x15e65ec0,0x3b9c,0x11d2,0xb9,0x2f,0x00,0x60,0x97,0x97,0xea,0x5b ); +DEFINE_GUID( IID_IDirectDrawSurface, 0x6C14DB81,0xA733,0x11CE,0xA5,0x21,0x00,0x20,0xAF,0x0B,0xE5,0x60 ); +DEFINE_GUID( IID_IDirectDrawSurface2, 0x57805885,0x6eec,0x11cf,0x94,0x41,0xa8,0x23,0x03,0xc1,0x0e,0x27 ); +DEFINE_GUID( IID_IDirectDrawSurface3, 0xDA044E00,0x69B2,0x11D0,0xA1,0xD5,0x00,0xAA,0x00,0xB8,0xDF,0xBB ); +DEFINE_GUID( IID_IDirectDrawSurface4, 0x0B2B8630,0xAD35,0x11D0,0x8E,0xA6,0x00,0x60,0x97,0x97,0xEA,0x5B ); +DEFINE_GUID( IID_IDirectDrawSurface7, 0x06675a80,0x3b9b,0x11d2,0xb9,0x2f,0x00,0x60,0x97,0x97,0xea,0x5b ); +DEFINE_GUID( IID_IDirectDrawPalette, 0x6C14DB84,0xA733,0x11CE,0xA5,0x21,0x00,0x20,0xAF,0x0B,0xE5,0x60 ); +DEFINE_GUID( IID_IDirectDrawClipper, 0x6C14DB85,0xA733,0x11CE,0xA5,0x21,0x00,0x20,0xAF,0x0B,0xE5,0x60 ); +DEFINE_GUID( IID_IDirectDrawColorControl, 0x4B9F0EE0,0x0D7E,0x11D0,0x9B,0x06,0x00,0xA0,0xC9,0x03,0xA3,0xB8 ); +DEFINE_GUID( IID_IDirectDrawGammaControl, 0x69C11C3E,0xB46B,0x11D1,0xAD,0x7A,0x00,0xC0,0x4F,0xC2,0x9B,0x4E ); + +#endif + +/*============================================================================ + * + * DirectDraw Structures + * + * Various structures used to invoke DirectDraw. + * + *==========================================================================*/ + +struct IDirectDraw; +struct IDirectDrawSurface; +struct IDirectDrawPalette; +struct IDirectDrawClipper; + +typedef struct IDirectDraw FAR *LPDIRECTDRAW; +typedef struct IDirectDraw2 FAR *LPDIRECTDRAW2; +typedef struct IDirectDraw4 FAR *LPDIRECTDRAW4; +typedef struct IDirectDraw7 FAR *LPDIRECTDRAW7; +typedef struct IDirectDrawSurface FAR *LPDIRECTDRAWSURFACE; +typedef struct IDirectDrawSurface2 FAR *LPDIRECTDRAWSURFACE2; +typedef struct IDirectDrawSurface3 FAR *LPDIRECTDRAWSURFACE3; +typedef struct IDirectDrawSurface4 FAR *LPDIRECTDRAWSURFACE4; +typedef struct IDirectDrawSurface7 FAR *LPDIRECTDRAWSURFACE7; +typedef struct IDirectDrawPalette FAR *LPDIRECTDRAWPALETTE; +typedef struct IDirectDrawClipper FAR *LPDIRECTDRAWCLIPPER; +typedef struct IDirectDrawColorControl FAR *LPDIRECTDRAWCOLORCONTROL; +typedef struct IDirectDrawGammaControl FAR *LPDIRECTDRAWGAMMACONTROL; + +typedef struct _DDFXROP FAR *LPDDFXROP; +typedef struct _DDSURFACEDESC FAR *LPDDSURFACEDESC; +typedef struct _DDSURFACEDESC2 FAR *LPDDSURFACEDESC2; +typedef struct _DDCOLORCONTROL FAR *LPDDCOLORCONTROL; + +/* + * API's + */ +#if (defined (WIN32) || defined( _WIN32 ) ) && !defined( _NO_COM ) +//#if defined( _WIN32 ) && !defined( _NO_ENUM ) + typedef BOOL (FAR PASCAL * LPDDENUMCALLBACKA)(GUID FAR *, LPSTR, LPSTR, LPVOID); + typedef BOOL (FAR PASCAL * LPDDENUMCALLBACKW)(GUID FAR *, LPWSTR, LPWSTR, LPVOID); + extern HRESULT WINAPI DirectDrawEnumerateW( LPDDENUMCALLBACKW lpCallback, LPVOID lpContext ); + extern HRESULT WINAPI DirectDrawEnumerateA( LPDDENUMCALLBACKA lpCallback, LPVOID lpContext ); + /* + * Protect against old SDKs + */ + #if !defined(HMONITOR_DECLARED) && (WINVER < 0x0500) + #define HMONITOR_DECLARED + DECLARE_HANDLE(HMONITOR); + #endif + typedef BOOL (FAR PASCAL * LPDDENUMCALLBACKEXA)(GUID FAR *, LPSTR, LPSTR, LPVOID, HMONITOR); + typedef BOOL (FAR PASCAL * LPDDENUMCALLBACKEXW)(GUID FAR *, LPWSTR, LPWSTR, LPVOID, HMONITOR); + extern HRESULT WINAPI DirectDrawEnumerateExW( LPDDENUMCALLBACKEXW lpCallback, LPVOID lpContext, DWORD dwFlags); + extern HRESULT WINAPI DirectDrawEnumerateExA( LPDDENUMCALLBACKEXA lpCallback, LPVOID lpContext, DWORD dwFlags); + typedef HRESULT (WINAPI * LPDIRECTDRAWENUMERATEEXA)( LPDDENUMCALLBACKEXA lpCallback, LPVOID lpContext, DWORD dwFlags); + typedef HRESULT (WINAPI * LPDIRECTDRAWENUMERATEEXW)( LPDDENUMCALLBACKEXW lpCallback, LPVOID lpContext, DWORD dwFlags); + + #ifdef UNICODE + typedef LPDDENUMCALLBACKW LPDDENUMCALLBACK; + #define DirectDrawEnumerate DirectDrawEnumerateW + typedef LPDDENUMCALLBACKEXW LPDDENUMCALLBACKEX; + typedef LPDIRECTDRAWENUMERATEEXW LPDIRECTDRAWENUMERATEEX; + #define DirectDrawEnumerateEx DirectDrawEnumerateExW + #else + typedef LPDDENUMCALLBACKA LPDDENUMCALLBACK; + #define DirectDrawEnumerate DirectDrawEnumerateA + typedef LPDDENUMCALLBACKEXA LPDDENUMCALLBACKEX; + typedef LPDIRECTDRAWENUMERATEEXA LPDIRECTDRAWENUMERATEEX; + #define DirectDrawEnumerateEx DirectDrawEnumerateExA + #endif + extern HRESULT WINAPI DirectDrawCreate( GUID FAR *lpGUID, LPDIRECTDRAW FAR *lplpDD, IUnknown FAR *pUnkOuter ); + extern HRESULT WINAPI DirectDrawCreateEx( GUID FAR * lpGuid, LPVOID *lplpDD, REFIID iid,IUnknown FAR *pUnkOuter ); + extern HRESULT WINAPI DirectDrawCreateClipper( DWORD dwFlags, LPDIRECTDRAWCLIPPER FAR *lplpDDClipper, IUnknown FAR *pUnkOuter ); +#endif +/* + * Flags for DirectDrawEnumerateEx + * DirectDrawEnumerateEx supercedes DirectDrawEnumerate. You must use GetProcAddress to + * obtain a function pointer (of type LPDIRECTDRAWENUMERATEEX) to DirectDrawEnumerateEx. + * By default, only the primary display device is enumerated. + * DirectDrawEnumerate is equivalent to DirectDrawEnumerate(,,DDENUM_NONDISPLAYDEVICES) + */ + +/* + * This flag causes enumeration of any GDI display devices which are part of + * the Windows Desktop + */ +#define DDENUM_ATTACHEDSECONDARYDEVICES 0x00000001L + +/* + * This flag causes enumeration of any GDI display devices which are not + * part of the Windows Desktop + */ +#define DDENUM_DETACHEDSECONDARYDEVICES 0x00000002L + +/* + * This flag causes enumeration of non-display devices + */ +#define DDENUM_NONDISPLAYDEVICES 0x00000004L + + +#define REGSTR_KEY_DDHW_DESCRIPTION "Description" +#define REGSTR_KEY_DDHW_DRIVERNAME "DriverName" +#define REGSTR_PATH_DDHW "Hardware\\DirectDrawDrivers" + +#define DDCREATE_HARDWAREONLY 0x00000001l +#define DDCREATE_EMULATIONONLY 0x00000002l + +#if defined(WINNT) || !defined(WIN32) +typedef long HRESULT; +#endif + +//#ifndef WINNT +typedef HRESULT (FAR PASCAL * LPDDENUMMODESCALLBACK)(LPDDSURFACEDESC, LPVOID); +typedef HRESULT (FAR PASCAL * LPDDENUMMODESCALLBACK2)(LPDDSURFACEDESC2, LPVOID); +typedef HRESULT (FAR PASCAL * LPDDENUMSURFACESCALLBACK)(LPDIRECTDRAWSURFACE, LPDDSURFACEDESC, LPVOID); +typedef HRESULT (FAR PASCAL * LPDDENUMSURFACESCALLBACK2)(LPDIRECTDRAWSURFACE4, LPDDSURFACEDESC2, LPVOID); +typedef HRESULT (FAR PASCAL * LPDDENUMSURFACESCALLBACK7)(LPDIRECTDRAWSURFACE7, LPDDSURFACEDESC2, LPVOID); +//#endif + +/* + * Generic pixel format with 8-bit RGB and alpha components + */ +typedef struct _DDARGB +{ + BYTE blue; + BYTE green; + BYTE red; + BYTE alpha; +} DDARGB; + +typedef DDARGB FAR *LPDDARGB; + +/* + * This version of the structure remains for backwards source compatibility. + * The DDARGB structure is the one that should be used for all DirectDraw APIs. + */ +typedef struct _DDRGBA +{ + BYTE red; + BYTE green; + BYTE blue; + BYTE alpha; +} DDRGBA; + +typedef DDRGBA FAR *LPDDRGBA; + + +/* + * DDCOLORKEY + */ +typedef struct _DDCOLORKEY +{ + DWORD dwColorSpaceLowValue; // low boundary of color space that is to + // be treated as Color Key, inclusive + DWORD dwColorSpaceHighValue; // high boundary of color space that is + // to be treated as Color Key, inclusive +} DDCOLORKEY; + +typedef DDCOLORKEY FAR* LPDDCOLORKEY; + +/* + * DDBLTFX + * Used to pass override information to the DIRECTDRAWSURFACE callback Blt. + */ +typedef struct _DDBLTFX +{ + DWORD dwSize; // size of structure + DWORD dwDDFX; // FX operations + DWORD dwROP; // Win32 raster operations + DWORD dwDDROP; // Raster operations new for DirectDraw + DWORD dwRotationAngle; // Rotation angle for blt + DWORD dwZBufferOpCode; // ZBuffer compares + DWORD dwZBufferLow; // Low limit of Z buffer + DWORD dwZBufferHigh; // High limit of Z buffer + DWORD dwZBufferBaseDest; // Destination base value + DWORD dwZDestConstBitDepth; // Bit depth used to specify Z constant for destination + union + { + DWORD dwZDestConst; // Constant to use as Z buffer for dest + LPDIRECTDRAWSURFACE lpDDSZBufferDest; // Surface to use as Z buffer for dest + } DUMMYUNIONNAMEN(1); + DWORD dwZSrcConstBitDepth; // Bit depth used to specify Z constant for source + union + { + DWORD dwZSrcConst; // Constant to use as Z buffer for src + LPDIRECTDRAWSURFACE lpDDSZBufferSrc; // Surface to use as Z buffer for src + } DUMMYUNIONNAMEN(2); + DWORD dwAlphaEdgeBlendBitDepth; // Bit depth used to specify constant for alpha edge blend + DWORD dwAlphaEdgeBlend; // Alpha for edge blending + DWORD dwReserved; + DWORD dwAlphaDestConstBitDepth; // Bit depth used to specify alpha constant for destination + union + { + DWORD dwAlphaDestConst; // Constant to use as Alpha Channel + LPDIRECTDRAWSURFACE lpDDSAlphaDest; // Surface to use as Alpha Channel + } DUMMYUNIONNAMEN(3); + DWORD dwAlphaSrcConstBitDepth; // Bit depth used to specify alpha constant for source + union + { + DWORD dwAlphaSrcConst; // Constant to use as Alpha Channel + LPDIRECTDRAWSURFACE lpDDSAlphaSrc; // Surface to use as Alpha Channel + } DUMMYUNIONNAMEN(4); + union + { + DWORD dwFillColor; // color in RGB or Palettized + DWORD dwFillDepth; // depth value for z-buffer + DWORD dwFillPixel; // pixel value for RGBA or RGBZ + LPDIRECTDRAWSURFACE lpDDSPattern; // Surface to use as pattern + } DUMMYUNIONNAMEN(5); + DDCOLORKEY ddckDestColorkey; // DestColorkey override + DDCOLORKEY ddckSrcColorkey; // SrcColorkey override +} DDBLTFX; + +typedef DDBLTFX FAR* LPDDBLTFX; + + + +/* + * DDSCAPS + */ +typedef struct _DDSCAPS +{ + DWORD dwCaps; // capabilities of surface wanted +} DDSCAPS; + +typedef DDSCAPS FAR* LPDDSCAPS; + + +/* + * DDOSCAPS + */ +typedef struct _DDOSCAPS +{ + DWORD dwCaps; // capabilities of surface wanted +} DDOSCAPS; + +typedef DDOSCAPS FAR* LPDDOSCAPS; + +/* + * This structure is used internally by DirectDraw. + */ +typedef struct _DDSCAPSEX +{ + DWORD dwCaps2; + DWORD dwCaps3; + union + { + DWORD dwCaps4; + DWORD dwVolumeDepth; + } DUMMYUNIONNAMEN(1); +} DDSCAPSEX, FAR * LPDDSCAPSEX; + +/* + * DDSCAPS2 + */ +typedef struct _DDSCAPS2 +{ + DWORD dwCaps; // capabilities of surface wanted + DWORD dwCaps2; + DWORD dwCaps3; + union + { + DWORD dwCaps4; + DWORD dwVolumeDepth; + } DUMMYUNIONNAMEN(1); +} DDSCAPS2; + +typedef DDSCAPS2 FAR* LPDDSCAPS2; + +/* + * DDCAPS + */ +#define DD_ROP_SPACE (256/32) // space required to store ROP array +/* + * NOTE: Our choosen structure number scheme is to append a single digit to + * the end of the structure giving the version that structure is associated + * with. + */ + +/* + * This structure represents the DDCAPS structure released in DirectDraw 1.0. It is used internally + * by DirectDraw to interpret caps passed into ddraw by drivers written prior to the release of DirectDraw 2.0. + * New applications should use the DDCAPS structure defined below. + */ +typedef struct _DDCAPS_DX1 +{ + DWORD dwSize; // size of the DDDRIVERCAPS structure + DWORD dwCaps; // driver specific capabilities + DWORD dwCaps2; // more driver specific capabilites + DWORD dwCKeyCaps; // color key capabilities of the surface + DWORD dwFXCaps; // driver specific stretching and effects capabilites + DWORD dwFXAlphaCaps; // alpha driver specific capabilities + DWORD dwPalCaps; // palette capabilities + DWORD dwSVCaps; // stereo vision capabilities + DWORD dwAlphaBltConstBitDepths; // DDBD_2,4,8 + DWORD dwAlphaBltPixelBitDepths; // DDBD_1,2,4,8 + DWORD dwAlphaBltSurfaceBitDepths; // DDBD_1,2,4,8 + DWORD dwAlphaOverlayConstBitDepths; // DDBD_2,4,8 + DWORD dwAlphaOverlayPixelBitDepths; // DDBD_1,2,4,8 + DWORD dwAlphaOverlaySurfaceBitDepths; // DDBD_1,2,4,8 + DWORD dwZBufferBitDepths; // DDBD_8,16,24,32 + DWORD dwVidMemTotal; // total amount of video memory + DWORD dwVidMemFree; // amount of free video memory + DWORD dwMaxVisibleOverlays; // maximum number of visible overlays + DWORD dwCurrVisibleOverlays; // current number of visible overlays + DWORD dwNumFourCCCodes; // number of four cc codes + DWORD dwAlignBoundarySrc; // source rectangle alignment + DWORD dwAlignSizeSrc; // source rectangle byte size + DWORD dwAlignBoundaryDest; // dest rectangle alignment + DWORD dwAlignSizeDest; // dest rectangle byte size + DWORD dwAlignStrideAlign; // stride alignment + DWORD dwRops[DD_ROP_SPACE]; // ROPS supported + DDSCAPS ddsCaps; // DDSCAPS structure has all the general capabilities + DWORD dwMinOverlayStretch; // minimum overlay stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 + DWORD dwMaxOverlayStretch; // maximum overlay stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 + DWORD dwMinLiveVideoStretch; // OBSOLETE! This field remains for compatability reasons only + DWORD dwMaxLiveVideoStretch; // OBSOLETE! This field remains for compatability reasons only + DWORD dwMinHwCodecStretch; // OBSOLETE! This field remains for compatability reasons only + DWORD dwMaxHwCodecStretch; // OBSOLETE! This field remains for compatability reasons only + DWORD dwReserved1; // reserved + DWORD dwReserved2; // reserved + DWORD dwReserved3; // reserved +} DDCAPS_DX1; + +typedef DDCAPS_DX1 FAR* LPDDCAPS_DX1; + +/* + * This structure is the DDCAPS structure as it was in version 2 and 3 of Direct X. + * It is present for back compatability. + */ +typedef struct _DDCAPS_DX3 +{ + DWORD dwSize; // size of the DDDRIVERCAPS structure + DWORD dwCaps; // driver specific capabilities + DWORD dwCaps2; // more driver specific capabilites + DWORD dwCKeyCaps; // color key capabilities of the surface + DWORD dwFXCaps; // driver specific stretching and effects capabilites + DWORD dwFXAlphaCaps; // alpha driver specific capabilities + DWORD dwPalCaps; // palette capabilities + DWORD dwSVCaps; // stereo vision capabilities + DWORD dwAlphaBltConstBitDepths; // DDBD_2,4,8 + DWORD dwAlphaBltPixelBitDepths; // DDBD_1,2,4,8 + DWORD dwAlphaBltSurfaceBitDepths; // DDBD_1,2,4,8 + DWORD dwAlphaOverlayConstBitDepths; // DDBD_2,4,8 + DWORD dwAlphaOverlayPixelBitDepths; // DDBD_1,2,4,8 + DWORD dwAlphaOverlaySurfaceBitDepths; // DDBD_1,2,4,8 + DWORD dwZBufferBitDepths; // DDBD_8,16,24,32 + DWORD dwVidMemTotal; // total amount of video memory + DWORD dwVidMemFree; // amount of free video memory + DWORD dwMaxVisibleOverlays; // maximum number of visible overlays + DWORD dwCurrVisibleOverlays; // current number of visible overlays + DWORD dwNumFourCCCodes; // number of four cc codes + DWORD dwAlignBoundarySrc; // source rectangle alignment + DWORD dwAlignSizeSrc; // source rectangle byte size + DWORD dwAlignBoundaryDest; // dest rectangle alignment + DWORD dwAlignSizeDest; // dest rectangle byte size + DWORD dwAlignStrideAlign; // stride alignment + DWORD dwRops[DD_ROP_SPACE]; // ROPS supported + DDSCAPS ddsCaps; // DDSCAPS structure has all the general capabilities + DWORD dwMinOverlayStretch; // minimum overlay stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 + DWORD dwMaxOverlayStretch; // maximum overlay stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 + DWORD dwMinLiveVideoStretch; // minimum live video stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 + DWORD dwMaxLiveVideoStretch; // maximum live video stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 + DWORD dwMinHwCodecStretch; // minimum hardware codec stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 + DWORD dwMaxHwCodecStretch; // maximum hardware codec stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 + DWORD dwReserved1; // reserved + DWORD dwReserved2; // reserved + DWORD dwReserved3; // reserved + DWORD dwSVBCaps; // driver specific capabilities for System->Vmem blts + DWORD dwSVBCKeyCaps; // driver color key capabilities for System->Vmem blts + DWORD dwSVBFXCaps; // driver FX capabilities for System->Vmem blts + DWORD dwSVBRops[DD_ROP_SPACE];// ROPS supported for System->Vmem blts + DWORD dwVSBCaps; // driver specific capabilities for Vmem->System blts + DWORD dwVSBCKeyCaps; // driver color key capabilities for Vmem->System blts + DWORD dwVSBFXCaps; // driver FX capabilities for Vmem->System blts + DWORD dwVSBRops[DD_ROP_SPACE];// ROPS supported for Vmem->System blts + DWORD dwSSBCaps; // driver specific capabilities for System->System blts + DWORD dwSSBCKeyCaps; // driver color key capabilities for System->System blts + DWORD dwSSBFXCaps; // driver FX capabilities for System->System blts + DWORD dwSSBRops[DD_ROP_SPACE];// ROPS supported for System->System blts + DWORD dwReserved4; // reserved + DWORD dwReserved5; // reserved + DWORD dwReserved6; // reserved +} DDCAPS_DX3; +typedef DDCAPS_DX3 FAR* LPDDCAPS_DX3; + +/* + * This structure is the DDCAPS structure as it was in version 5 of Direct X. + * It is present for back compatability. + */ +typedef struct _DDCAPS_DX5 +{ +/* 0*/ DWORD dwSize; // size of the DDDRIVERCAPS structure +/* 4*/ DWORD dwCaps; // driver specific capabilities +/* 8*/ DWORD dwCaps2; // more driver specific capabilites +/* c*/ DWORD dwCKeyCaps; // color key capabilities of the surface +/* 10*/ DWORD dwFXCaps; // driver specific stretching and effects capabilites +/* 14*/ DWORD dwFXAlphaCaps; // alpha driver specific capabilities +/* 18*/ DWORD dwPalCaps; // palette capabilities +/* 1c*/ DWORD dwSVCaps; // stereo vision capabilities +/* 20*/ DWORD dwAlphaBltConstBitDepths; // DDBD_2,4,8 +/* 24*/ DWORD dwAlphaBltPixelBitDepths; // DDBD_1,2,4,8 +/* 28*/ DWORD dwAlphaBltSurfaceBitDepths; // DDBD_1,2,4,8 +/* 2c*/ DWORD dwAlphaOverlayConstBitDepths; // DDBD_2,4,8 +/* 30*/ DWORD dwAlphaOverlayPixelBitDepths; // DDBD_1,2,4,8 +/* 34*/ DWORD dwAlphaOverlaySurfaceBitDepths; // DDBD_1,2,4,8 +/* 38*/ DWORD dwZBufferBitDepths; // DDBD_8,16,24,32 +/* 3c*/ DWORD dwVidMemTotal; // total amount of video memory +/* 40*/ DWORD dwVidMemFree; // amount of free video memory +/* 44*/ DWORD dwMaxVisibleOverlays; // maximum number of visible overlays +/* 48*/ DWORD dwCurrVisibleOverlays; // current number of visible overlays +/* 4c*/ DWORD dwNumFourCCCodes; // number of four cc codes +/* 50*/ DWORD dwAlignBoundarySrc; // source rectangle alignment +/* 54*/ DWORD dwAlignSizeSrc; // source rectangle byte size +/* 58*/ DWORD dwAlignBoundaryDest; // dest rectangle alignment +/* 5c*/ DWORD dwAlignSizeDest; // dest rectangle byte size +/* 60*/ DWORD dwAlignStrideAlign; // stride alignment +/* 64*/ DWORD dwRops[DD_ROP_SPACE]; // ROPS supported +/* 84*/ DDSCAPS ddsCaps; // DDSCAPS structure has all the general capabilities +/* 88*/ DWORD dwMinOverlayStretch; // minimum overlay stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 +/* 8c*/ DWORD dwMaxOverlayStretch; // maximum overlay stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 +/* 90*/ DWORD dwMinLiveVideoStretch; // minimum live video stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 +/* 94*/ DWORD dwMaxLiveVideoStretch; // maximum live video stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 +/* 98*/ DWORD dwMinHwCodecStretch; // minimum hardware codec stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 +/* 9c*/ DWORD dwMaxHwCodecStretch; // maximum hardware codec stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 +/* a0*/ DWORD dwReserved1; // reserved +/* a4*/ DWORD dwReserved2; // reserved +/* a8*/ DWORD dwReserved3; // reserved +/* ac*/ DWORD dwSVBCaps; // driver specific capabilities for System->Vmem blts +/* b0*/ DWORD dwSVBCKeyCaps; // driver color key capabilities for System->Vmem blts +/* b4*/ DWORD dwSVBFXCaps; // driver FX capabilities for System->Vmem blts +/* b8*/ DWORD dwSVBRops[DD_ROP_SPACE];// ROPS supported for System->Vmem blts +/* d8*/ DWORD dwVSBCaps; // driver specific capabilities for Vmem->System blts +/* dc*/ DWORD dwVSBCKeyCaps; // driver color key capabilities for Vmem->System blts +/* e0*/ DWORD dwVSBFXCaps; // driver FX capabilities for Vmem->System blts +/* e4*/ DWORD dwVSBRops[DD_ROP_SPACE];// ROPS supported for Vmem->System blts +/*104*/ DWORD dwSSBCaps; // driver specific capabilities for System->System blts +/*108*/ DWORD dwSSBCKeyCaps; // driver color key capabilities for System->System blts +/*10c*/ DWORD dwSSBFXCaps; // driver FX capabilities for System->System blts +/*110*/ DWORD dwSSBRops[DD_ROP_SPACE];// ROPS supported for System->System blts +// Members added for DX5: +/*130*/ DWORD dwMaxVideoPorts; // maximum number of usable video ports +/*134*/ DWORD dwCurrVideoPorts; // current number of video ports used +/*138*/ DWORD dwSVBCaps2; // more driver specific capabilities for System->Vmem blts +/*13c*/ DWORD dwNLVBCaps; // driver specific capabilities for non-local->local vidmem blts +/*140*/ DWORD dwNLVBCaps2; // more driver specific capabilities non-local->local vidmem blts +/*144*/ DWORD dwNLVBCKeyCaps; // driver color key capabilities for non-local->local vidmem blts +/*148*/ DWORD dwNLVBFXCaps; // driver FX capabilities for non-local->local blts +/*14c*/ DWORD dwNLVBRops[DD_ROP_SPACE]; // ROPS supported for non-local->local blts +} DDCAPS_DX5; +typedef DDCAPS_DX5 FAR* LPDDCAPS_DX5; + +typedef struct _DDCAPS_DX6 +{ +/* 0*/ DWORD dwSize; // size of the DDDRIVERCAPS structure +/* 4*/ DWORD dwCaps; // driver specific capabilities +/* 8*/ DWORD dwCaps2; // more driver specific capabilites +/* c*/ DWORD dwCKeyCaps; // color key capabilities of the surface +/* 10*/ DWORD dwFXCaps; // driver specific stretching and effects capabilites +/* 14*/ DWORD dwFXAlphaCaps; // alpha caps +/* 18*/ DWORD dwPalCaps; // palette capabilities +/* 1c*/ DWORD dwSVCaps; // stereo vision capabilities +/* 20*/ DWORD dwAlphaBltConstBitDepths; // DDBD_2,4,8 +/* 24*/ DWORD dwAlphaBltPixelBitDepths; // DDBD_1,2,4,8 +/* 28*/ DWORD dwAlphaBltSurfaceBitDepths; // DDBD_1,2,4,8 +/* 2c*/ DWORD dwAlphaOverlayConstBitDepths; // DDBD_2,4,8 +/* 30*/ DWORD dwAlphaOverlayPixelBitDepths; // DDBD_1,2,4,8 +/* 34*/ DWORD dwAlphaOverlaySurfaceBitDepths; // DDBD_1,2,4,8 +/* 38*/ DWORD dwZBufferBitDepths; // DDBD_8,16,24,32 +/* 3c*/ DWORD dwVidMemTotal; // total amount of video memory +/* 40*/ DWORD dwVidMemFree; // amount of free video memory +/* 44*/ DWORD dwMaxVisibleOverlays; // maximum number of visible overlays +/* 48*/ DWORD dwCurrVisibleOverlays; // current number of visible overlays +/* 4c*/ DWORD dwNumFourCCCodes; // number of four cc codes +/* 50*/ DWORD dwAlignBoundarySrc; // source rectangle alignment +/* 54*/ DWORD dwAlignSizeSrc; // source rectangle byte size +/* 58*/ DWORD dwAlignBoundaryDest; // dest rectangle alignment +/* 5c*/ DWORD dwAlignSizeDest; // dest rectangle byte size +/* 60*/ DWORD dwAlignStrideAlign; // stride alignment +/* 64*/ DWORD dwRops[DD_ROP_SPACE]; // ROPS supported +/* 84*/ DDSCAPS ddsOldCaps; // Was DDSCAPS ddsCaps. ddsCaps is of type DDSCAPS2 for DX6 +/* 88*/ DWORD dwMinOverlayStretch; // minimum overlay stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 +/* 8c*/ DWORD dwMaxOverlayStretch; // maximum overlay stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 +/* 90*/ DWORD dwMinLiveVideoStretch; // minimum live video stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 +/* 94*/ DWORD dwMaxLiveVideoStretch; // maximum live video stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 +/* 98*/ DWORD dwMinHwCodecStretch; // minimum hardware codec stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 +/* 9c*/ DWORD dwMaxHwCodecStretch; // maximum hardware codec stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 +/* a0*/ DWORD dwReserved1; // reserved +/* a4*/ DWORD dwReserved2; // reserved +/* a8*/ DWORD dwReserved3; // reserved +/* ac*/ DWORD dwSVBCaps; // driver specific capabilities for System->Vmem blts +/* b0*/ DWORD dwSVBCKeyCaps; // driver color key capabilities for System->Vmem blts +/* b4*/ DWORD dwSVBFXCaps; // driver FX capabilities for System->Vmem blts +/* b8*/ DWORD dwSVBRops[DD_ROP_SPACE];// ROPS supported for System->Vmem blts +/* d8*/ DWORD dwVSBCaps; // driver specific capabilities for Vmem->System blts +/* dc*/ DWORD dwVSBCKeyCaps; // driver color key capabilities for Vmem->System blts +/* e0*/ DWORD dwVSBFXCaps; // driver FX capabilities for Vmem->System blts +/* e4*/ DWORD dwVSBRops[DD_ROP_SPACE];// ROPS supported for Vmem->System blts +/*104*/ DWORD dwSSBCaps; // driver specific capabilities for System->System blts +/*108*/ DWORD dwSSBCKeyCaps; // driver color key capabilities for System->System blts +/*10c*/ DWORD dwSSBFXCaps; // driver FX capabilities for System->System blts +/*110*/ DWORD dwSSBRops[DD_ROP_SPACE];// ROPS supported for System->System blts +/*130*/ DWORD dwMaxVideoPorts; // maximum number of usable video ports +/*134*/ DWORD dwCurrVideoPorts; // current number of video ports used +/*138*/ DWORD dwSVBCaps2; // more driver specific capabilities for System->Vmem blts +/*13c*/ DWORD dwNLVBCaps; // driver specific capabilities for non-local->local vidmem blts +/*140*/ DWORD dwNLVBCaps2; // more driver specific capabilities non-local->local vidmem blts +/*144*/ DWORD dwNLVBCKeyCaps; // driver color key capabilities for non-local->local vidmem blts +/*148*/ DWORD dwNLVBFXCaps; // driver FX capabilities for non-local->local blts +/*14c*/ DWORD dwNLVBRops[DD_ROP_SPACE]; // ROPS supported for non-local->local blts +// Members added for DX6 release +/*16c*/ DDSCAPS2 ddsCaps; // Surface Caps +} DDCAPS_DX6; +typedef DDCAPS_DX6 FAR* LPDDCAPS_DX6; + +typedef struct _DDCAPS_DX7 +{ +/* 0*/ DWORD dwSize; // size of the DDDRIVERCAPS structure +/* 4*/ DWORD dwCaps; // driver specific capabilities +/* 8*/ DWORD dwCaps2; // more driver specific capabilites +/* c*/ DWORD dwCKeyCaps; // color key capabilities of the surface +/* 10*/ DWORD dwFXCaps; // driver specific stretching and effects capabilites +/* 14*/ DWORD dwFXAlphaCaps; // alpha driver specific capabilities +/* 18*/ DWORD dwPalCaps; // palette capabilities +/* 1c*/ DWORD dwSVCaps; // stereo vision capabilities +/* 20*/ DWORD dwAlphaBltConstBitDepths; // DDBD_2,4,8 +/* 24*/ DWORD dwAlphaBltPixelBitDepths; // DDBD_1,2,4,8 +/* 28*/ DWORD dwAlphaBltSurfaceBitDepths; // DDBD_1,2,4,8 +/* 2c*/ DWORD dwAlphaOverlayConstBitDepths; // DDBD_2,4,8 +/* 30*/ DWORD dwAlphaOverlayPixelBitDepths; // DDBD_1,2,4,8 +/* 34*/ DWORD dwAlphaOverlaySurfaceBitDepths; // DDBD_1,2,4,8 +/* 38*/ DWORD dwZBufferBitDepths; // DDBD_8,16,24,32 +/* 3c*/ DWORD dwVidMemTotal; // total amount of video memory +/* 40*/ DWORD dwVidMemFree; // amount of free video memory +/* 44*/ DWORD dwMaxVisibleOverlays; // maximum number of visible overlays +/* 48*/ DWORD dwCurrVisibleOverlays; // current number of visible overlays +/* 4c*/ DWORD dwNumFourCCCodes; // number of four cc codes +/* 50*/ DWORD dwAlignBoundarySrc; // source rectangle alignment +/* 54*/ DWORD dwAlignSizeSrc; // source rectangle byte size +/* 58*/ DWORD dwAlignBoundaryDest; // dest rectangle alignment +/* 5c*/ DWORD dwAlignSizeDest; // dest rectangle byte size +/* 60*/ DWORD dwAlignStrideAlign; // stride alignment +/* 64*/ DWORD dwRops[DD_ROP_SPACE]; // ROPS supported +/* 84*/ DDSCAPS ddsOldCaps; // Was DDSCAPS ddsCaps. ddsCaps is of type DDSCAPS2 for DX6 +/* 88*/ DWORD dwMinOverlayStretch; // minimum overlay stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 +/* 8c*/ DWORD dwMaxOverlayStretch; // maximum overlay stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 +/* 90*/ DWORD dwMinLiveVideoStretch; // minimum live video stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 +/* 94*/ DWORD dwMaxLiveVideoStretch; // maximum live video stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 +/* 98*/ DWORD dwMinHwCodecStretch; // minimum hardware codec stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 +/* 9c*/ DWORD dwMaxHwCodecStretch; // maximum hardware codec stretch factor multiplied by 1000, eg 1000 == 1.0, 1300 == 1.3 +/* a0*/ DWORD dwReserved1; // reserved +/* a4*/ DWORD dwReserved2; // reserved +/* a8*/ DWORD dwReserved3; // reserved +/* ac*/ DWORD dwSVBCaps; // driver specific capabilities for System->Vmem blts +/* b0*/ DWORD dwSVBCKeyCaps; // driver color key capabilities for System->Vmem blts +/* b4*/ DWORD dwSVBFXCaps; // driver FX capabilities for System->Vmem blts +/* b8*/ DWORD dwSVBRops[DD_ROP_SPACE];// ROPS supported for System->Vmem blts +/* d8*/ DWORD dwVSBCaps; // driver specific capabilities for Vmem->System blts +/* dc*/ DWORD dwVSBCKeyCaps; // driver color key capabilities for Vmem->System blts +/* e0*/ DWORD dwVSBFXCaps; // driver FX capabilities for Vmem->System blts +/* e4*/ DWORD dwVSBRops[DD_ROP_SPACE];// ROPS supported for Vmem->System blts +/*104*/ DWORD dwSSBCaps; // driver specific capabilities for System->System blts +/*108*/ DWORD dwSSBCKeyCaps; // driver color key capabilities for System->System blts +/*10c*/ DWORD dwSSBFXCaps; // driver FX capabilities for System->System blts +/*110*/ DWORD dwSSBRops[DD_ROP_SPACE];// ROPS supported for System->System blts +/*130*/ DWORD dwMaxVideoPorts; // maximum number of usable video ports +/*134*/ DWORD dwCurrVideoPorts; // current number of video ports used +/*138*/ DWORD dwSVBCaps2; // more driver specific capabilities for System->Vmem blts +/*13c*/ DWORD dwNLVBCaps; // driver specific capabilities for non-local->local vidmem blts +/*140*/ DWORD dwNLVBCaps2; // more driver specific capabilities non-local->local vidmem blts +/*144*/ DWORD dwNLVBCKeyCaps; // driver color key capabilities for non-local->local vidmem blts +/*148*/ DWORD dwNLVBFXCaps; // driver FX capabilities for non-local->local blts +/*14c*/ DWORD dwNLVBRops[DD_ROP_SPACE]; // ROPS supported for non-local->local blts +// Members added for DX6 release +/*16c*/ DDSCAPS2 ddsCaps; // Surface Caps +} DDCAPS_DX7; +typedef DDCAPS_DX7 FAR* LPDDCAPS_DX7; + + +#if DIRECTDRAW_VERSION <= 0x300 + typedef DDCAPS_DX3 DDCAPS; +#elif DIRECTDRAW_VERSION <= 0x500 + typedef DDCAPS_DX5 DDCAPS; +#elif DIRECTDRAW_VERSION <= 0x600 + typedef DDCAPS_DX6 DDCAPS; +#else + typedef DDCAPS_DX7 DDCAPS; +#endif + +typedef DDCAPS FAR* LPDDCAPS; + + + +/* + * DDPIXELFORMAT + */ +typedef struct _DDPIXELFORMAT +{ + DWORD dwSize; // size of structure + DWORD dwFlags; // pixel format flags + DWORD dwFourCC; // (FOURCC code) + union + { + DWORD dwRGBBitCount; // how many bits per pixel + DWORD dwYUVBitCount; // how many bits per pixel + DWORD dwZBufferBitDepth; // how many total bits/pixel in z buffer (including any stencil bits) + DWORD dwAlphaBitDepth; // how many bits for alpha channels + DWORD dwLuminanceBitCount; // how many bits per pixel + DWORD dwBumpBitCount; // how many bits per "buxel", total + DWORD dwPrivateFormatBitCount;// Bits per pixel of private driver formats. Only valid in texture + // format list and if DDPF_D3DFORMAT is set + } DUMMYUNIONNAMEN(1); + union + { + DWORD dwRBitMask; // mask for red bit + DWORD dwYBitMask; // mask for Y bits + DWORD dwStencilBitDepth; // how many stencil bits (note: dwZBufferBitDepth-dwStencilBitDepth is total Z-only bits) + DWORD dwLuminanceBitMask; // mask for luminance bits + DWORD dwBumpDuBitMask; // mask for bump map U delta bits + DWORD dwOperations; // DDPF_D3DFORMAT Operations + } DUMMYUNIONNAMEN(2); + union + { + DWORD dwGBitMask; // mask for green bits + DWORD dwUBitMask; // mask for U bits + DWORD dwZBitMask; // mask for Z bits + DWORD dwBumpDvBitMask; // mask for bump map V delta bits + struct + { + WORD wFlipMSTypes; // Multisample methods supported via flip for this D3DFORMAT + WORD wBltMSTypes; // Multisample methods supported via blt for this D3DFORMAT + } MultiSampleCaps; + + } DUMMYUNIONNAMEN(3); + union + { + DWORD dwBBitMask; // mask for blue bits + DWORD dwVBitMask; // mask for V bits + DWORD dwStencilBitMask; // mask for stencil bits + DWORD dwBumpLuminanceBitMask; // mask for luminance in bump map + } DUMMYUNIONNAMEN(4); + union + { + DWORD dwRGBAlphaBitMask; // mask for alpha channel + DWORD dwYUVAlphaBitMask; // mask for alpha channel + DWORD dwLuminanceAlphaBitMask;// mask for alpha channel + DWORD dwRGBZBitMask; // mask for Z channel + DWORD dwYUVZBitMask; // mask for Z channel + } DUMMYUNIONNAMEN(5); +} DDPIXELFORMAT; + +typedef DDPIXELFORMAT FAR* LPDDPIXELFORMAT; + +/* + * DDOVERLAYFX + */ +typedef struct _DDOVERLAYFX +{ + DWORD dwSize; // size of structure + DWORD dwAlphaEdgeBlendBitDepth; // Bit depth used to specify constant for alpha edge blend + DWORD dwAlphaEdgeBlend; // Constant to use as alpha for edge blend + DWORD dwReserved; + DWORD dwAlphaDestConstBitDepth; // Bit depth used to specify alpha constant for destination + union + { + DWORD dwAlphaDestConst; // Constant to use as alpha channel for dest + LPDIRECTDRAWSURFACE lpDDSAlphaDest; // Surface to use as alpha channel for dest + } DUMMYUNIONNAMEN(1); + DWORD dwAlphaSrcConstBitDepth; // Bit depth used to specify alpha constant for source + union + { + DWORD dwAlphaSrcConst; // Constant to use as alpha channel for src + LPDIRECTDRAWSURFACE lpDDSAlphaSrc; // Surface to use as alpha channel for src + } DUMMYUNIONNAMEN(2); + DDCOLORKEY dckDestColorkey; // DestColorkey override + DDCOLORKEY dckSrcColorkey; // DestColorkey override + DWORD dwDDFX; // Overlay FX + DWORD dwFlags; // flags +} DDOVERLAYFX; + +typedef DDOVERLAYFX FAR *LPDDOVERLAYFX; + + +/* + * DDBLTBATCH: BltBatch entry structure + */ +typedef struct _DDBLTBATCH +{ + LPRECT lprDest; + LPDIRECTDRAWSURFACE lpDDSSrc; + LPRECT lprSrc; + DWORD dwFlags; + LPDDBLTFX lpDDBltFx; +} DDBLTBATCH; + +typedef DDBLTBATCH FAR * LPDDBLTBATCH; + + +/* + * DDGAMMARAMP + */ +typedef struct _DDGAMMARAMP +{ + WORD red[256]; + WORD green[256]; + WORD blue[256]; +} DDGAMMARAMP; +typedef DDGAMMARAMP FAR * LPDDGAMMARAMP; + +/* + * This is the structure within which DirectDraw returns data about the current graphics driver and chipset + */ + +#define MAX_DDDEVICEID_STRING 512 + +typedef struct tagDDDEVICEIDENTIFIER +{ + /* + * These elements are for presentation to the user only. They should not be used to identify particular + * drivers, since this is unreliable and many different strings may be associated with the same + * device, and the same driver from different vendors. + */ + char szDriver[MAX_DDDEVICEID_STRING]; + char szDescription[MAX_DDDEVICEID_STRING]; + + /* + * This element is the version of the DirectDraw/3D driver. It is legal to do <, > comparisons + * on the whole 64 bits. Caution should be exercised if you use this element to identify problematic + * drivers. It is recommended that guidDeviceIdentifier is used for this purpose. + * + * This version has the form: + * wProduct = HIWORD(liDriverVersion.HighPart) + * wVersion = LOWORD(liDriverVersion.HighPart) + * wSubVersion = HIWORD(liDriverVersion.LowPart) + * wBuild = LOWORD(liDriverVersion.LowPart) + */ +#ifdef _WIN32 + LARGE_INTEGER liDriverVersion; /* Defined for applications and other 32 bit components */ +#else + DWORD dwDriverVersionLowPart; /* Defined for 16 bit driver components */ + DWORD dwDriverVersionHighPart; +#endif + + + /* + * These elements can be used to identify particular chipsets. Use with extreme caution. + * dwVendorId Identifies the manufacturer. May be zero if unknown. + * dwDeviceId Identifies the type of chipset. May be zero if unknown. + * dwSubSysId Identifies the subsystem, typically this means the particular board. May be zero if unknown. + * dwRevision Identifies the revision level of the chipset. May be zero if unknown. + */ + DWORD dwVendorId; + DWORD dwDeviceId; + DWORD dwSubSysId; + DWORD dwRevision; + + /* + * This element can be used to check changes in driver/chipset. This GUID is a unique identifier for the + * driver/chipset pair. Use this element if you wish to track changes to the driver/chipset in order to + * reprofile the graphics subsystem. + * This element can also be used to identify particular problematic drivers. + */ + GUID guidDeviceIdentifier; +} DDDEVICEIDENTIFIER, * LPDDDEVICEIDENTIFIER; + +typedef struct tagDDDEVICEIDENTIFIER2 +{ + /* + * These elements are for presentation to the user only. They should not be used to identify particular + * drivers, since this is unreliable and many different strings may be associated with the same + * device, and the same driver from different vendors. + */ + char szDriver[MAX_DDDEVICEID_STRING]; + char szDescription[MAX_DDDEVICEID_STRING]; + + /* + * This element is the version of the DirectDraw/3D driver. It is legal to do <, > comparisons + * on the whole 64 bits. Caution should be exercised if you use this element to identify problematic + * drivers. It is recommended that guidDeviceIdentifier is used for this purpose. + * + * This version has the form: + * wProduct = HIWORD(liDriverVersion.HighPart) + * wVersion = LOWORD(liDriverVersion.HighPart) + * wSubVersion = HIWORD(liDriverVersion.LowPart) + * wBuild = LOWORD(liDriverVersion.LowPart) + */ +#ifdef _WIN32 + LARGE_INTEGER liDriverVersion; /* Defined for applications and other 32 bit components */ +#else + DWORD dwDriverVersionLowPart; /* Defined for 16 bit driver components */ + DWORD dwDriverVersionHighPart; +#endif + + + /* + * These elements can be used to identify particular chipsets. Use with extreme caution. + * dwVendorId Identifies the manufacturer. May be zero if unknown. + * dwDeviceId Identifies the type of chipset. May be zero if unknown. + * dwSubSysId Identifies the subsystem, typically this means the particular board. May be zero if unknown. + * dwRevision Identifies the revision level of the chipset. May be zero if unknown. + */ + DWORD dwVendorId; + DWORD dwDeviceId; + DWORD dwSubSysId; + DWORD dwRevision; + + /* + * This element can be used to check changes in driver/chipset. This GUID is a unique identifier for the + * driver/chipset pair. Use this element if you wish to track changes to the driver/chipset in order to + * reprofile the graphics subsystem. + * This element can also be used to identify particular problematic drivers. + */ + GUID guidDeviceIdentifier; + + /* + * This element is used to determine the Windows Hardware Quality Lab (WHQL) + * certification level for this driver/device pair. + */ + DWORD dwWHQLLevel; + +} DDDEVICEIDENTIFIER2, * LPDDDEVICEIDENTIFIER2; + +/* + * Flags for the IDirectDraw4::GetDeviceIdentifier method + */ + +/* + * This flag causes GetDeviceIdentifier to return information about the host (typically 2D) adapter in a system equipped + * with a stacked secondary 3D adapter. Such an adapter appears to the application as if it were part of the + * host adapter, but is typically physcially located on a separate card. The stacked secondary's information is + * returned when GetDeviceIdentifier's dwFlags field is zero, since this most accurately reflects the qualities + * of the DirectDraw object involved. + */ +#define DDGDI_GETHOSTIDENTIFIER 0x00000001L + +/* + * Macros for interpretting DDEVICEIDENTIFIER2.dwWHQLLevel + */ +#define GET_WHQL_YEAR( dwWHQLLevel ) \ + ( (dwWHQLLevel) / 0x10000 ) +#define GET_WHQL_MONTH( dwWHQLLevel ) \ + ( ( (dwWHQLLevel) / 0x100 ) & 0x00ff ) +#define GET_WHQL_DAY( dwWHQLLevel ) \ + ( (dwWHQLLevel) & 0xff ) + + +/* + * callbacks + */ +typedef DWORD (FAR PASCAL *LPCLIPPERCALLBACK)(LPDIRECTDRAWCLIPPER lpDDClipper, HWND hWnd, DWORD code, LPVOID lpContext ); +#ifdef STREAMING +typedef DWORD (FAR PASCAL *LPSURFACESTREAMINGCALLBACK)(DWORD); +#endif + + +/* + * INTERACES FOLLOW: + * IDirectDraw + * IDirectDrawClipper + * IDirectDrawPalette + * IDirectDrawSurface + */ + +/* + * IDirectDraw + */ +#if defined( _WIN32 ) && !defined( _NO_COM ) +#undef INTERFACE +#define INTERFACE IDirectDraw +DECLARE_INTERFACE_( IDirectDraw, IUnknown ) +{ + /*** IUnknown methods ***/ + STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID FAR * ppvObj) PURE; + STDMETHOD_(ULONG,AddRef) (THIS) PURE; + STDMETHOD_(ULONG,Release) (THIS) PURE; + /*** IDirectDraw methods ***/ + STDMETHOD(Compact)(THIS) PURE; + STDMETHOD(CreateClipper)(THIS_ DWORD, LPDIRECTDRAWCLIPPER FAR*, IUnknown FAR * ) PURE; + STDMETHOD(CreatePalette)(THIS_ DWORD, LPPALETTEENTRY, LPDIRECTDRAWPALETTE FAR*, IUnknown FAR * ) PURE; + STDMETHOD(CreateSurface)(THIS_ LPDDSURFACEDESC, LPDIRECTDRAWSURFACE FAR *, IUnknown FAR *) PURE; + STDMETHOD(DuplicateSurface)( THIS_ LPDIRECTDRAWSURFACE, LPDIRECTDRAWSURFACE FAR * ) PURE; + STDMETHOD(EnumDisplayModes)( THIS_ DWORD, LPDDSURFACEDESC, LPVOID, LPDDENUMMODESCALLBACK ) PURE; + STDMETHOD(EnumSurfaces)(THIS_ DWORD, LPDDSURFACEDESC, LPVOID,LPDDENUMSURFACESCALLBACK ) PURE; + STDMETHOD(FlipToGDISurface)(THIS) PURE; + STDMETHOD(GetCaps)( THIS_ LPDDCAPS, LPDDCAPS) PURE; + STDMETHOD(GetDisplayMode)( THIS_ LPDDSURFACEDESC) PURE; + STDMETHOD(GetFourCCCodes)(THIS_ LPDWORD, LPDWORD ) PURE; + STDMETHOD(GetGDISurface)(THIS_ LPDIRECTDRAWSURFACE FAR *) PURE; + STDMETHOD(GetMonitorFrequency)(THIS_ LPDWORD) PURE; + STDMETHOD(GetScanLine)(THIS_ LPDWORD) PURE; + STDMETHOD(GetVerticalBlankStatus)(THIS_ LPBOOL ) PURE; + STDMETHOD(Initialize)(THIS_ GUID FAR *) PURE; + STDMETHOD(RestoreDisplayMode)(THIS) PURE; + STDMETHOD(SetCooperativeLevel)(THIS_ HWND, DWORD) PURE; + STDMETHOD(SetDisplayMode)(THIS_ DWORD, DWORD,DWORD) PURE; + STDMETHOD(WaitForVerticalBlank)(THIS_ DWORD, HANDLE ) PURE; +}; + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectDraw_QueryInterface(p, a, b) (p)->lpVtbl->QueryInterface(p, a, b) +#define IDirectDraw_AddRef(p) (p)->lpVtbl->AddRef(p) +#define IDirectDraw_Release(p) (p)->lpVtbl->Release(p) +#define IDirectDraw_Compact(p) (p)->lpVtbl->Compact(p) +#define IDirectDraw_CreateClipper(p, a, b, c) (p)->lpVtbl->CreateClipper(p, a, b, c) +#define IDirectDraw_CreatePalette(p, a, b, c, d) (p)->lpVtbl->CreatePalette(p, a, b, c, d) +#define IDirectDraw_CreateSurface(p, a, b, c) (p)->lpVtbl->CreateSurface(p, a, b, c) +#define IDirectDraw_DuplicateSurface(p, a, b) (p)->lpVtbl->DuplicateSurface(p, a, b) +#define IDirectDraw_EnumDisplayModes(p, a, b, c, d) (p)->lpVtbl->EnumDisplayModes(p, a, b, c, d) +#define IDirectDraw_EnumSurfaces(p, a, b, c, d) (p)->lpVtbl->EnumSurfaces(p, a, b, c, d) +#define IDirectDraw_FlipToGDISurface(p) (p)->lpVtbl->FlipToGDISurface(p) +#define IDirectDraw_GetCaps(p, a, b) (p)->lpVtbl->GetCaps(p, a, b) +#define IDirectDraw_GetDisplayMode(p, a) (p)->lpVtbl->GetDisplayMode(p, a) +#define IDirectDraw_GetFourCCCodes(p, a, b) (p)->lpVtbl->GetFourCCCodes(p, a, b) +#define IDirectDraw_GetGDISurface(p, a) (p)->lpVtbl->GetGDISurface(p, a) +#define IDirectDraw_GetMonitorFrequency(p, a) (p)->lpVtbl->GetMonitorFrequency(p, a) +#define IDirectDraw_GetScanLine(p, a) (p)->lpVtbl->GetScanLine(p, a) +#define IDirectDraw_GetVerticalBlankStatus(p, a) (p)->lpVtbl->GetVerticalBlankStatus(p, a) +#define IDirectDraw_Initialize(p, a) (p)->lpVtbl->Initialize(p, a) +#define IDirectDraw_RestoreDisplayMode(p) (p)->lpVtbl->RestoreDisplayMode(p) +#define IDirectDraw_SetCooperativeLevel(p, a, b) (p)->lpVtbl->SetCooperativeLevel(p, a, b) +#define IDirectDraw_SetDisplayMode(p, a, b, c) (p)->lpVtbl->SetDisplayMode(p, a, b, c) +#define IDirectDraw_WaitForVerticalBlank(p, a, b) (p)->lpVtbl->WaitForVerticalBlank(p, a, b) +#else +#define IDirectDraw_QueryInterface(p, a, b) (p)->QueryInterface(a, b) +#define IDirectDraw_AddRef(p) (p)->AddRef() +#define IDirectDraw_Release(p) (p)->Release() +#define IDirectDraw_Compact(p) (p)->Compact() +#define IDirectDraw_CreateClipper(p, a, b, c) (p)->CreateClipper(a, b, c) +#define IDirectDraw_CreatePalette(p, a, b, c, d) (p)->CreatePalette(a, b, c, d) +#define IDirectDraw_CreateSurface(p, a, b, c) (p)->CreateSurface(a, b, c) +#define IDirectDraw_DuplicateSurface(p, a, b) (p)->DuplicateSurface(a, b) +#define IDirectDraw_EnumDisplayModes(p, a, b, c, d) (p)->EnumDisplayModes(a, b, c, d) +#define IDirectDraw_EnumSurfaces(p, a, b, c, d) (p)->EnumSurfaces(a, b, c, d) +#define IDirectDraw_FlipToGDISurface(p) (p)->FlipToGDISurface() +#define IDirectDraw_GetCaps(p, a, b) (p)->GetCaps(a, b) +#define IDirectDraw_GetDisplayMode(p, a) (p)->GetDisplayMode(a) +#define IDirectDraw_GetFourCCCodes(p, a, b) (p)->GetFourCCCodes(a, b) +#define IDirectDraw_GetGDISurface(p, a) (p)->GetGDISurface(a) +#define IDirectDraw_GetMonitorFrequency(p, a) (p)->GetMonitorFrequency(a) +#define IDirectDraw_GetScanLine(p, a) (p)->GetScanLine(a) +#define IDirectDraw_GetVerticalBlankStatus(p, a) (p)->GetVerticalBlankStatus(a) +#define IDirectDraw_Initialize(p, a) (p)->Initialize(a) +#define IDirectDraw_RestoreDisplayMode(p) (p)->RestoreDisplayMode() +#define IDirectDraw_SetCooperativeLevel(p, a, b) (p)->SetCooperativeLevel(a, b) +#define IDirectDraw_SetDisplayMode(p, a, b, c) (p)->SetDisplayMode(a, b, c) +#define IDirectDraw_WaitForVerticalBlank(p, a, b) (p)->WaitForVerticalBlank(a, b) +#endif + +#endif + +#if defined( _WIN32 ) && !defined( _NO_COM ) +#undef INTERFACE +#define INTERFACE IDirectDraw2 +DECLARE_INTERFACE_( IDirectDraw2, IUnknown ) +{ + /*** IUnknown methods ***/ + STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID FAR * ppvObj) PURE; + STDMETHOD_(ULONG,AddRef) (THIS) PURE; + STDMETHOD_(ULONG,Release) (THIS) PURE; + /*** IDirectDraw methods ***/ + STDMETHOD(Compact)(THIS) PURE; + STDMETHOD(CreateClipper)(THIS_ DWORD, LPDIRECTDRAWCLIPPER FAR*, IUnknown FAR * ) PURE; + STDMETHOD(CreatePalette)(THIS_ DWORD, LPPALETTEENTRY, LPDIRECTDRAWPALETTE FAR*, IUnknown FAR * ) PURE; + STDMETHOD(CreateSurface)(THIS_ LPDDSURFACEDESC, LPDIRECTDRAWSURFACE FAR *, IUnknown FAR *) PURE; + STDMETHOD(DuplicateSurface)( THIS_ LPDIRECTDRAWSURFACE, LPDIRECTDRAWSURFACE FAR * ) PURE; + STDMETHOD(EnumDisplayModes)( THIS_ DWORD, LPDDSURFACEDESC, LPVOID, LPDDENUMMODESCALLBACK ) PURE; + STDMETHOD(EnumSurfaces)(THIS_ DWORD, LPDDSURFACEDESC, LPVOID,LPDDENUMSURFACESCALLBACK ) PURE; + STDMETHOD(FlipToGDISurface)(THIS) PURE; + STDMETHOD(GetCaps)( THIS_ LPDDCAPS, LPDDCAPS) PURE; + STDMETHOD(GetDisplayMode)( THIS_ LPDDSURFACEDESC) PURE; + STDMETHOD(GetFourCCCodes)(THIS_ LPDWORD, LPDWORD ) PURE; + STDMETHOD(GetGDISurface)(THIS_ LPDIRECTDRAWSURFACE FAR *) PURE; + STDMETHOD(GetMonitorFrequency)(THIS_ LPDWORD) PURE; + STDMETHOD(GetScanLine)(THIS_ LPDWORD) PURE; + STDMETHOD(GetVerticalBlankStatus)(THIS_ LPBOOL ) PURE; + STDMETHOD(Initialize)(THIS_ GUID FAR *) PURE; + STDMETHOD(RestoreDisplayMode)(THIS) PURE; + STDMETHOD(SetCooperativeLevel)(THIS_ HWND, DWORD) PURE; + STDMETHOD(SetDisplayMode)(THIS_ DWORD, DWORD,DWORD, DWORD, DWORD) PURE; + STDMETHOD(WaitForVerticalBlank)(THIS_ DWORD, HANDLE ) PURE; + /*** Added in the v2 interface ***/ + STDMETHOD(GetAvailableVidMem)(THIS_ LPDDSCAPS, LPDWORD, LPDWORD) PURE; +}; +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectDraw2_QueryInterface(p, a, b) (p)->lpVtbl->QueryInterface(p, a, b) +#define IDirectDraw2_AddRef(p) (p)->lpVtbl->AddRef(p) +#define IDirectDraw2_Release(p) (p)->lpVtbl->Release(p) +#define IDirectDraw2_Compact(p) (p)->lpVtbl->Compact(p) +#define IDirectDraw2_CreateClipper(p, a, b, c) (p)->lpVtbl->CreateClipper(p, a, b, c) +#define IDirectDraw2_CreatePalette(p, a, b, c, d) (p)->lpVtbl->CreatePalette(p, a, b, c, d) +#define IDirectDraw2_CreateSurface(p, a, b, c) (p)->lpVtbl->CreateSurface(p, a, b, c) +#define IDirectDraw2_DuplicateSurface(p, a, b) (p)->lpVtbl->DuplicateSurface(p, a, b) +#define IDirectDraw2_EnumDisplayModes(p, a, b, c, d) (p)->lpVtbl->EnumDisplayModes(p, a, b, c, d) +#define IDirectDraw2_EnumSurfaces(p, a, b, c, d) (p)->lpVtbl->EnumSurfaces(p, a, b, c, d) +#define IDirectDraw2_FlipToGDISurface(p) (p)->lpVtbl->FlipToGDISurface(p) +#define IDirectDraw2_GetCaps(p, a, b) (p)->lpVtbl->GetCaps(p, a, b) +#define IDirectDraw2_GetDisplayMode(p, a) (p)->lpVtbl->GetDisplayMode(p, a) +#define IDirectDraw2_GetFourCCCodes(p, a, b) (p)->lpVtbl->GetFourCCCodes(p, a, b) +#define IDirectDraw2_GetGDISurface(p, a) (p)->lpVtbl->GetGDISurface(p, a) +#define IDirectDraw2_GetMonitorFrequency(p, a) (p)->lpVtbl->GetMonitorFrequency(p, a) +#define IDirectDraw2_GetScanLine(p, a) (p)->lpVtbl->GetScanLine(p, a) +#define IDirectDraw2_GetVerticalBlankStatus(p, a) (p)->lpVtbl->GetVerticalBlankStatus(p, a) +#define IDirectDraw2_Initialize(p, a) (p)->lpVtbl->Initialize(p, a) +#define IDirectDraw2_RestoreDisplayMode(p) (p)->lpVtbl->RestoreDisplayMode(p) +#define IDirectDraw2_SetCooperativeLevel(p, a, b) (p)->lpVtbl->SetCooperativeLevel(p, a, b) +#define IDirectDraw2_SetDisplayMode(p, a, b, c, d, e) (p)->lpVtbl->SetDisplayMode(p, a, b, c, d, e) +#define IDirectDraw2_WaitForVerticalBlank(p, a, b) (p)->lpVtbl->WaitForVerticalBlank(p, a, b) +#define IDirectDraw2_GetAvailableVidMem(p, a, b, c) (p)->lpVtbl->GetAvailableVidMem(p, a, b, c) +#else +#define IDirectDraw2_QueryInterface(p, a, b) (p)->QueryInterface(a, b) +#define IDirectDraw2_AddRef(p) (p)->AddRef() +#define IDirectDraw2_Release(p) (p)->Release() +#define IDirectDraw2_Compact(p) (p)->Compact() +#define IDirectDraw2_CreateClipper(p, a, b, c) (p)->CreateClipper(a, b, c) +#define IDirectDraw2_CreatePalette(p, a, b, c, d) (p)->CreatePalette(a, b, c, d) +#define IDirectDraw2_CreateSurface(p, a, b, c) (p)->CreateSurface(a, b, c) +#define IDirectDraw2_DuplicateSurface(p, a, b) (p)->DuplicateSurface(a, b) +#define IDirectDraw2_EnumDisplayModes(p, a, b, c, d) (p)->EnumDisplayModes(a, b, c, d) +#define IDirectDraw2_EnumSurfaces(p, a, b, c, d) (p)->EnumSurfaces(a, b, c, d) +#define IDirectDraw2_FlipToGDISurface(p) (p)->FlipToGDISurface() +#define IDirectDraw2_GetCaps(p, a, b) (p)->GetCaps(a, b) +#define IDirectDraw2_GetDisplayMode(p, a) (p)->GetDisplayMode(a) +#define IDirectDraw2_GetFourCCCodes(p, a, b) (p)->GetFourCCCodes(a, b) +#define IDirectDraw2_GetGDISurface(p, a) (p)->GetGDISurface(a) +#define IDirectDraw2_GetMonitorFrequency(p, a) (p)->GetMonitorFrequency(a) +#define IDirectDraw2_GetScanLine(p, a) (p)->GetScanLine(a) +#define IDirectDraw2_GetVerticalBlankStatus(p, a) (p)->GetVerticalBlankStatus(a) +#define IDirectDraw2_Initialize(p, a) (p)->Initialize(a) +#define IDirectDraw2_RestoreDisplayMode(p) (p)->RestoreDisplayMode() +#define IDirectDraw2_SetCooperativeLevel(p, a, b) (p)->SetCooperativeLevel(a, b) +#define IDirectDraw2_SetDisplayMode(p, a, b, c, d, e) (p)->SetDisplayMode(a, b, c, d, e) +#define IDirectDraw2_WaitForVerticalBlank(p, a, b) (p)->WaitForVerticalBlank(a, b) +#define IDirectDraw2_GetAvailableVidMem(p, a, b, c) (p)->GetAvailableVidMem(a, b, c) +#endif + +#endif + +#if defined( _WIN32 ) && !defined( _NO_COM ) +#undef INTERFACE +#define INTERFACE IDirectDraw4 +DECLARE_INTERFACE_( IDirectDraw4, IUnknown ) +{ + /*** IUnknown methods ***/ + STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID FAR * ppvObj) PURE; + STDMETHOD_(ULONG,AddRef) (THIS) PURE; + STDMETHOD_(ULONG,Release) (THIS) PURE; + /*** IDirectDraw methods ***/ + STDMETHOD(Compact)(THIS) PURE; + STDMETHOD(CreateClipper)(THIS_ DWORD, LPDIRECTDRAWCLIPPER FAR*, IUnknown FAR * ) PURE; + STDMETHOD(CreatePalette)(THIS_ DWORD, LPPALETTEENTRY, LPDIRECTDRAWPALETTE FAR*, IUnknown FAR * ) PURE; + STDMETHOD(CreateSurface)(THIS_ LPDDSURFACEDESC2, LPDIRECTDRAWSURFACE4 FAR *, IUnknown FAR *) PURE; + STDMETHOD(DuplicateSurface)( THIS_ LPDIRECTDRAWSURFACE4, LPDIRECTDRAWSURFACE4 FAR * ) PURE; + STDMETHOD(EnumDisplayModes)( THIS_ DWORD, LPDDSURFACEDESC2, LPVOID, LPDDENUMMODESCALLBACK2 ) PURE; + STDMETHOD(EnumSurfaces)(THIS_ DWORD, LPDDSURFACEDESC2, LPVOID,LPDDENUMSURFACESCALLBACK2 ) PURE; + STDMETHOD(FlipToGDISurface)(THIS) PURE; + STDMETHOD(GetCaps)( THIS_ LPDDCAPS, LPDDCAPS) PURE; + STDMETHOD(GetDisplayMode)( THIS_ LPDDSURFACEDESC2) PURE; + STDMETHOD(GetFourCCCodes)(THIS_ LPDWORD, LPDWORD ) PURE; + STDMETHOD(GetGDISurface)(THIS_ LPDIRECTDRAWSURFACE4 FAR *) PURE; + STDMETHOD(GetMonitorFrequency)(THIS_ LPDWORD) PURE; + STDMETHOD(GetScanLine)(THIS_ LPDWORD) PURE; + STDMETHOD(GetVerticalBlankStatus)(THIS_ LPBOOL ) PURE; + STDMETHOD(Initialize)(THIS_ GUID FAR *) PURE; + STDMETHOD(RestoreDisplayMode)(THIS) PURE; + STDMETHOD(SetCooperativeLevel)(THIS_ HWND, DWORD) PURE; + STDMETHOD(SetDisplayMode)(THIS_ DWORD, DWORD,DWORD, DWORD, DWORD) PURE; + STDMETHOD(WaitForVerticalBlank)(THIS_ DWORD, HANDLE ) PURE; + /*** Added in the v2 interface ***/ + STDMETHOD(GetAvailableVidMem)(THIS_ LPDDSCAPS2, LPDWORD, LPDWORD) PURE; + /*** Added in the V4 Interface ***/ + STDMETHOD(GetSurfaceFromDC) (THIS_ HDC, LPDIRECTDRAWSURFACE4 *) PURE; + STDMETHOD(RestoreAllSurfaces)(THIS) PURE; + STDMETHOD(TestCooperativeLevel)(THIS) PURE; + STDMETHOD(GetDeviceIdentifier)(THIS_ LPDDDEVICEIDENTIFIER, DWORD ) PURE; +}; +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectDraw4_QueryInterface(p, a, b) (p)->lpVtbl->QueryInterface(p, a, b) +#define IDirectDraw4_AddRef(p) (p)->lpVtbl->AddRef(p) +#define IDirectDraw4_Release(p) (p)->lpVtbl->Release(p) +#define IDirectDraw4_Compact(p) (p)->lpVtbl->Compact(p) +#define IDirectDraw4_CreateClipper(p, a, b, c) (p)->lpVtbl->CreateClipper(p, a, b, c) +#define IDirectDraw4_CreatePalette(p, a, b, c, d) (p)->lpVtbl->CreatePalette(p, a, b, c, d) +#define IDirectDraw4_CreateSurface(p, a, b, c) (p)->lpVtbl->CreateSurface(p, a, b, c) +#define IDirectDraw4_DuplicateSurface(p, a, b) (p)->lpVtbl->DuplicateSurface(p, a, b) +#define IDirectDraw4_EnumDisplayModes(p, a, b, c, d) (p)->lpVtbl->EnumDisplayModes(p, a, b, c, d) +#define IDirectDraw4_EnumSurfaces(p, a, b, c, d) (p)->lpVtbl->EnumSurfaces(p, a, b, c, d) +#define IDirectDraw4_FlipToGDISurface(p) (p)->lpVtbl->FlipToGDISurface(p) +#define IDirectDraw4_GetCaps(p, a, b) (p)->lpVtbl->GetCaps(p, a, b) +#define IDirectDraw4_GetDisplayMode(p, a) (p)->lpVtbl->GetDisplayMode(p, a) +#define IDirectDraw4_GetFourCCCodes(p, a, b) (p)->lpVtbl->GetFourCCCodes(p, a, b) +#define IDirectDraw4_GetGDISurface(p, a) (p)->lpVtbl->GetGDISurface(p, a) +#define IDirectDraw4_GetMonitorFrequency(p, a) (p)->lpVtbl->GetMonitorFrequency(p, a) +#define IDirectDraw4_GetScanLine(p, a) (p)->lpVtbl->GetScanLine(p, a) +#define IDirectDraw4_GetVerticalBlankStatus(p, a) (p)->lpVtbl->GetVerticalBlankStatus(p, a) +#define IDirectDraw4_Initialize(p, a) (p)->lpVtbl->Initialize(p, a) +#define IDirectDraw4_RestoreDisplayMode(p) (p)->lpVtbl->RestoreDisplayMode(p) +#define IDirectDraw4_SetCooperativeLevel(p, a, b) (p)->lpVtbl->SetCooperativeLevel(p, a, b) +#define IDirectDraw4_SetDisplayMode(p, a, b, c, d, e) (p)->lpVtbl->SetDisplayMode(p, a, b, c, d, e) +#define IDirectDraw4_WaitForVerticalBlank(p, a, b) (p)->lpVtbl->WaitForVerticalBlank(p, a, b) +#define IDirectDraw4_GetAvailableVidMem(p, a, b, c) (p)->lpVtbl->GetAvailableVidMem(p, a, b, c) +#define IDirectDraw4_GetSurfaceFromDC(p, a, b) (p)->lpVtbl->GetSurfaceFromDC(p, a, b) +#define IDirectDraw4_RestoreAllSurfaces(p) (p)->lpVtbl->RestoreAllSurfaces(p) +#define IDirectDraw4_TestCooperativeLevel(p) (p)->lpVtbl->TestCooperativeLevel(p) +#define IDirectDraw4_GetDeviceIdentifier(p,a,b) (p)->lpVtbl->GetDeviceIdentifier(p,a,b) +#else +#define IDirectDraw4_QueryInterface(p, a, b) (p)->QueryInterface(a, b) +#define IDirectDraw4_AddRef(p) (p)->AddRef() +#define IDirectDraw4_Release(p) (p)->Release() +#define IDirectDraw4_Compact(p) (p)->Compact() +#define IDirectDraw4_CreateClipper(p, a, b, c) (p)->CreateClipper(a, b, c) +#define IDirectDraw4_CreatePalette(p, a, b, c, d) (p)->CreatePalette(a, b, c, d) +#define IDirectDraw4_CreateSurface(p, a, b, c) (p)->CreateSurface(a, b, c) +#define IDirectDraw4_DuplicateSurface(p, a, b) (p)->DuplicateSurface(a, b) +#define IDirectDraw4_EnumDisplayModes(p, a, b, c, d) (p)->EnumDisplayModes(a, b, c, d) +#define IDirectDraw4_EnumSurfaces(p, a, b, c, d) (p)->EnumSurfaces(a, b, c, d) +#define IDirectDraw4_FlipToGDISurface(p) (p)->FlipToGDISurface() +#define IDirectDraw4_GetCaps(p, a, b) (p)->GetCaps(a, b) +#define IDirectDraw4_GetDisplayMode(p, a) (p)->GetDisplayMode(a) +#define IDirectDraw4_GetFourCCCodes(p, a, b) (p)->GetFourCCCodes(a, b) +#define IDirectDraw4_GetGDISurface(p, a) (p)->GetGDISurface(a) +#define IDirectDraw4_GetMonitorFrequency(p, a) (p)->GetMonitorFrequency(a) +#define IDirectDraw4_GetScanLine(p, a) (p)->GetScanLine(a) +#define IDirectDraw4_GetVerticalBlankStatus(p, a) (p)->GetVerticalBlankStatus(a) +#define IDirectDraw4_Initialize(p, a) (p)->Initialize(a) +#define IDirectDraw4_RestoreDisplayMode(p) (p)->RestoreDisplayMode() +#define IDirectDraw4_SetCooperativeLevel(p, a, b) (p)->SetCooperativeLevel(a, b) +#define IDirectDraw4_SetDisplayMode(p, a, b, c, d, e) (p)->SetDisplayMode(a, b, c, d, e) +#define IDirectDraw4_WaitForVerticalBlank(p, a, b) (p)->WaitForVerticalBlank(a, b) +#define IDirectDraw4_GetAvailableVidMem(p, a, b, c) (p)->GetAvailableVidMem(a, b, c) +#define IDirectDraw4_GetSurfaceFromDC(p, a, b) (p)->GetSurfaceFromDC(a, b) +#define IDirectDraw4_RestoreAllSurfaces(p) (p)->RestoreAllSurfaces() +#define IDirectDraw4_TestCooperativeLevel(p) (p)->TestCooperativeLevel() +#define IDirectDraw4_GetDeviceIdentifier(p,a,b) (p)->GetDeviceIdentifier(a,b) +#endif + +#endif + +#if defined( _WIN32 ) && !defined( _NO_COM ) +#undef INTERFACE +#define INTERFACE IDirectDraw7 +DECLARE_INTERFACE_( IDirectDraw7, IUnknown ) +{ + /*** IUnknown methods ***/ + STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID FAR * ppvObj) PURE; + STDMETHOD_(ULONG,AddRef) (THIS) PURE; + STDMETHOD_(ULONG,Release) (THIS) PURE; + /*** IDirectDraw methods ***/ + STDMETHOD(Compact)(THIS) PURE; + STDMETHOD(CreateClipper)(THIS_ DWORD, LPDIRECTDRAWCLIPPER FAR*, IUnknown FAR * ) PURE; + STDMETHOD(CreatePalette)(THIS_ DWORD, LPPALETTEENTRY, LPDIRECTDRAWPALETTE FAR*, IUnknown FAR * ) PURE; + STDMETHOD(CreateSurface)(THIS_ LPDDSURFACEDESC2, LPDIRECTDRAWSURFACE7 FAR *, IUnknown FAR *) PURE; + STDMETHOD(DuplicateSurface)( THIS_ LPDIRECTDRAWSURFACE7, LPDIRECTDRAWSURFACE7 FAR * ) PURE; + STDMETHOD(EnumDisplayModes)( THIS_ DWORD, LPDDSURFACEDESC2, LPVOID, LPDDENUMMODESCALLBACK2 ) PURE; + STDMETHOD(EnumSurfaces)(THIS_ DWORD, LPDDSURFACEDESC2, LPVOID,LPDDENUMSURFACESCALLBACK7 ) PURE; + STDMETHOD(FlipToGDISurface)(THIS) PURE; + STDMETHOD(GetCaps)( THIS_ LPDDCAPS, LPDDCAPS) PURE; + STDMETHOD(GetDisplayMode)( THIS_ LPDDSURFACEDESC2) PURE; + STDMETHOD(GetFourCCCodes)(THIS_ LPDWORD, LPDWORD ) PURE; + STDMETHOD(GetGDISurface)(THIS_ LPDIRECTDRAWSURFACE7 FAR *) PURE; + STDMETHOD(GetMonitorFrequency)(THIS_ LPDWORD) PURE; + STDMETHOD(GetScanLine)(THIS_ LPDWORD) PURE; + STDMETHOD(GetVerticalBlankStatus)(THIS_ LPBOOL ) PURE; + STDMETHOD(Initialize)(THIS_ GUID FAR *) PURE; + STDMETHOD(RestoreDisplayMode)(THIS) PURE; + STDMETHOD(SetCooperativeLevel)(THIS_ HWND, DWORD) PURE; + STDMETHOD(SetDisplayMode)(THIS_ DWORD, DWORD,DWORD, DWORD, DWORD) PURE; + STDMETHOD(WaitForVerticalBlank)(THIS_ DWORD, HANDLE ) PURE; + /*** Added in the v2 interface ***/ + STDMETHOD(GetAvailableVidMem)(THIS_ LPDDSCAPS2, LPDWORD, LPDWORD) PURE; + /*** Added in the V4 Interface ***/ + STDMETHOD(GetSurfaceFromDC) (THIS_ HDC, LPDIRECTDRAWSURFACE7 *) PURE; + STDMETHOD(RestoreAllSurfaces)(THIS) PURE; + STDMETHOD(TestCooperativeLevel)(THIS) PURE; + STDMETHOD(GetDeviceIdentifier)(THIS_ LPDDDEVICEIDENTIFIER2, DWORD ) PURE; + STDMETHOD(StartModeTest)(THIS_ LPSIZE, DWORD, DWORD ) PURE; + STDMETHOD(EvaluateMode)(THIS_ DWORD, DWORD * ) PURE; +}; +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectDraw7_QueryInterface(p, a, b) (p)->lpVtbl->QueryInterface(p, a, b) +#define IDirectDraw7_AddRef(p) (p)->lpVtbl->AddRef(p) +#define IDirectDraw7_Release(p) (p)->lpVtbl->Release(p) +#define IDirectDraw7_Compact(p) (p)->lpVtbl->Compact(p) +#define IDirectDraw7_CreateClipper(p, a, b, c) (p)->lpVtbl->CreateClipper(p, a, b, c) +#define IDirectDraw7_CreatePalette(p, a, b, c, d) (p)->lpVtbl->CreatePalette(p, a, b, c, d) +#define IDirectDraw7_CreateSurface(p, a, b, c) (p)->lpVtbl->CreateSurface(p, a, b, c) +#define IDirectDraw7_DuplicateSurface(p, a, b) (p)->lpVtbl->DuplicateSurface(p, a, b) +#define IDirectDraw7_EnumDisplayModes(p, a, b, c, d) (p)->lpVtbl->EnumDisplayModes(p, a, b, c, d) +#define IDirectDraw7_EnumSurfaces(p, a, b, c, d) (p)->lpVtbl->EnumSurfaces(p, a, b, c, d) +#define IDirectDraw7_FlipToGDISurface(p) (p)->lpVtbl->FlipToGDISurface(p) +#define IDirectDraw7_GetCaps(p, a, b) (p)->lpVtbl->GetCaps(p, a, b) +#define IDirectDraw7_GetDisplayMode(p, a) (p)->lpVtbl->GetDisplayMode(p, a) +#define IDirectDraw7_GetFourCCCodes(p, a, b) (p)->lpVtbl->GetFourCCCodes(p, a, b) +#define IDirectDraw7_GetGDISurface(p, a) (p)->lpVtbl->GetGDISurface(p, a) +#define IDirectDraw7_GetMonitorFrequency(p, a) (p)->lpVtbl->GetMonitorFrequency(p, a) +#define IDirectDraw7_GetScanLine(p, a) (p)->lpVtbl->GetScanLine(p, a) +#define IDirectDraw7_GetVerticalBlankStatus(p, a) (p)->lpVtbl->GetVerticalBlankStatus(p, a) +#define IDirectDraw7_Initialize(p, a) (p)->lpVtbl->Initialize(p, a) +#define IDirectDraw7_RestoreDisplayMode(p) (p)->lpVtbl->RestoreDisplayMode(p) +#define IDirectDraw7_SetCooperativeLevel(p, a, b) (p)->lpVtbl->SetCooperativeLevel(p, a, b) +#define IDirectDraw7_SetDisplayMode(p, a, b, c, d, e) (p)->lpVtbl->SetDisplayMode(p, a, b, c, d, e) +#define IDirectDraw7_WaitForVerticalBlank(p, a, b) (p)->lpVtbl->WaitForVerticalBlank(p, a, b) +#define IDirectDraw7_GetAvailableVidMem(p, a, b, c) (p)->lpVtbl->GetAvailableVidMem(p, a, b, c) +#define IDirectDraw7_GetSurfaceFromDC(p, a, b) (p)->lpVtbl->GetSurfaceFromDC(p, a, b) +#define IDirectDraw7_RestoreAllSurfaces(p) (p)->lpVtbl->RestoreAllSurfaces(p) +#define IDirectDraw7_TestCooperativeLevel(p) (p)->lpVtbl->TestCooperativeLevel(p) +#define IDirectDraw7_GetDeviceIdentifier(p,a,b) (p)->lpVtbl->GetDeviceIdentifier(p,a,b) +#define IDirectDraw7_StartModeTest(p,a,b,c) (p)->lpVtbl->StartModeTest(p,a,b,c) +#define IDirectDraw7_EvaluateMode(p,a,b) (p)->lpVtbl->EvaluateMode(p,a,b) +#else +#define IDirectDraw7_QueryInterface(p, a, b) (p)->QueryInterface(a, b) +#define IDirectDraw7_AddRef(p) (p)->AddRef() +#define IDirectDraw7_Release(p) (p)->Release() +#define IDirectDraw7_Compact(p) (p)->Compact() +#define IDirectDraw7_CreateClipper(p, a, b, c) (p)->CreateClipper(a, b, c) +#define IDirectDraw7_CreatePalette(p, a, b, c, d) (p)->CreatePalette(a, b, c, d) +#define IDirectDraw7_CreateSurface(p, a, b, c) (p)->CreateSurface(a, b, c) +#define IDirectDraw7_DuplicateSurface(p, a, b) (p)->DuplicateSurface(a, b) +#define IDirectDraw7_EnumDisplayModes(p, a, b, c, d) (p)->EnumDisplayModes(a, b, c, d) +#define IDirectDraw7_EnumSurfaces(p, a, b, c, d) (p)->EnumSurfaces(a, b, c, d) +#define IDirectDraw7_FlipToGDISurface(p) (p)->FlipToGDISurface() +#define IDirectDraw7_GetCaps(p, a, b) (p)->GetCaps(a, b) +#define IDirectDraw7_GetDisplayMode(p, a) (p)->GetDisplayMode(a) +#define IDirectDraw7_GetFourCCCodes(p, a, b) (p)->GetFourCCCodes(a, b) +#define IDirectDraw7_GetGDISurface(p, a) (p)->GetGDISurface(a) +#define IDirectDraw7_GetMonitorFrequency(p, a) (p)->GetMonitorFrequency(a) +#define IDirectDraw7_GetScanLine(p, a) (p)->GetScanLine(a) +#define IDirectDraw7_GetVerticalBlankStatus(p, a) (p)->GetVerticalBlankStatus(a) +#define IDirectDraw7_Initialize(p, a) (p)->Initialize(a) +#define IDirectDraw7_RestoreDisplayMode(p) (p)->RestoreDisplayMode() +#define IDirectDraw7_SetCooperativeLevel(p, a, b) (p)->SetCooperativeLevel(a, b) +#define IDirectDraw7_SetDisplayMode(p, a, b, c, d, e) (p)->SetDisplayMode(a, b, c, d, e) +#define IDirectDraw7_WaitForVerticalBlank(p, a, b) (p)->WaitForVerticalBlank(a, b) +#define IDirectDraw7_GetAvailableVidMem(p, a, b, c) (p)->GetAvailableVidMem(a, b, c) +#define IDirectDraw7_GetSurfaceFromDC(p, a, b) (p)->GetSurfaceFromDC(a, b) +#define IDirectDraw7_RestoreAllSurfaces(p) (p)->RestoreAllSurfaces() +#define IDirectDraw7_TestCooperativeLevel(p) (p)->TestCooperativeLevel() +#define IDirectDraw7_GetDeviceIdentifier(p,a,b) (p)->GetDeviceIdentifier(a,b) +#define IDirectDraw7_StartModeTest(p,a,b,c) (p)->lpVtbl->StartModeTest(a,b,c) +#define IDirectDraw7_EvaluateMode(p,a,b) (p)->lpVtbl->EvaluateMode(a,b) +#endif + +#endif + + +/* + * IDirectDrawPalette + */ +#if defined( _WIN32 ) && !defined( _NO_COM ) +#undef INTERFACE +#define INTERFACE IDirectDrawPalette +DECLARE_INTERFACE_( IDirectDrawPalette, IUnknown ) +{ + /*** IUnknown methods ***/ + STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID FAR * ppvObj) PURE; + STDMETHOD_(ULONG,AddRef) (THIS) PURE; + STDMETHOD_(ULONG,Release) (THIS) PURE; + /*** IDirectDrawPalette methods ***/ + STDMETHOD(GetCaps)(THIS_ LPDWORD) PURE; + STDMETHOD(GetEntries)(THIS_ DWORD,DWORD,DWORD,LPPALETTEENTRY) PURE; + STDMETHOD(Initialize)(THIS_ LPDIRECTDRAW, DWORD, LPPALETTEENTRY) PURE; + STDMETHOD(SetEntries)(THIS_ DWORD,DWORD,DWORD,LPPALETTEENTRY) PURE; +}; + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectDrawPalette_QueryInterface(p, a, b) (p)->lpVtbl->QueryInterface(p, a, b) +#define IDirectDrawPalette_AddRef(p) (p)->lpVtbl->AddRef(p) +#define IDirectDrawPalette_Release(p) (p)->lpVtbl->Release(p) +#define IDirectDrawPalette_GetCaps(p, a) (p)->lpVtbl->GetCaps(p, a) +#define IDirectDrawPalette_GetEntries(p, a, b, c, d) (p)->lpVtbl->GetEntries(p, a, b, c, d) +#define IDirectDrawPalette_Initialize(p, a, b, c) (p)->lpVtbl->Initialize(p, a, b, c) +#define IDirectDrawPalette_SetEntries(p, a, b, c, d) (p)->lpVtbl->SetEntries(p, a, b, c, d) +#else +#define IDirectDrawPalette_QueryInterface(p, a, b) (p)->QueryInterface(a, b) +#define IDirectDrawPalette_AddRef(p) (p)->AddRef() +#define IDirectDrawPalette_Release(p) (p)->Release() +#define IDirectDrawPalette_GetCaps(p, a) (p)->GetCaps(a) +#define IDirectDrawPalette_GetEntries(p, a, b, c, d) (p)->GetEntries(a, b, c, d) +#define IDirectDrawPalette_Initialize(p, a, b, c) (p)->Initialize(a, b, c) +#define IDirectDrawPalette_SetEntries(p, a, b, c, d) (p)->SetEntries(a, b, c, d) +#endif + +#endif + + +/* + * IDirectDrawClipper + */ +#if defined( _WIN32 ) && !defined( _NO_COM ) +#undef INTERFACE +#define INTERFACE IDirectDrawClipper +DECLARE_INTERFACE_( IDirectDrawClipper, IUnknown ) +{ + /*** IUnknown methods ***/ + STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID FAR * ppvObj) PURE; + STDMETHOD_(ULONG,AddRef) (THIS) PURE; + STDMETHOD_(ULONG,Release) (THIS) PURE; + /*** IDirectDrawClipper methods ***/ + STDMETHOD(GetClipList)(THIS_ LPRECT, LPRGNDATA, LPDWORD) PURE; + STDMETHOD(GetHWnd)(THIS_ HWND FAR *) PURE; + STDMETHOD(Initialize)(THIS_ LPDIRECTDRAW, DWORD) PURE; + STDMETHOD(IsClipListChanged)(THIS_ BOOL FAR *) PURE; + STDMETHOD(SetClipList)(THIS_ LPRGNDATA,DWORD) PURE; + STDMETHOD(SetHWnd)(THIS_ DWORD, HWND ) PURE; +}; + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectDrawClipper_QueryInterface(p, a, b) (p)->lpVtbl->QueryInterface(p, a, b) +#define IDirectDrawClipper_AddRef(p) (p)->lpVtbl->AddRef(p) +#define IDirectDrawClipper_Release(p) (p)->lpVtbl->Release(p) +#define IDirectDrawClipper_GetClipList(p, a, b, c) (p)->lpVtbl->GetClipList(p, a, b, c) +#define IDirectDrawClipper_GetHWnd(p, a) (p)->lpVtbl->GetHWnd(p, a) +#define IDirectDrawClipper_Initialize(p, a, b) (p)->lpVtbl->Initialize(p, a, b) +#define IDirectDrawClipper_IsClipListChanged(p, a) (p)->lpVtbl->IsClipListChanged(p, a) +#define IDirectDrawClipper_SetClipList(p, a, b) (p)->lpVtbl->SetClipList(p, a, b) +#define IDirectDrawClipper_SetHWnd(p, a, b) (p)->lpVtbl->SetHWnd(p, a, b) +#else +#define IDirectDrawClipper_QueryInterface(p, a, b) (p)->QueryInterface(a, b) +#define IDirectDrawClipper_AddRef(p) (p)->AddRef() +#define IDirectDrawClipper_Release(p) (p)->Release() +#define IDirectDrawClipper_GetClipList(p, a, b, c) (p)->GetClipList(a, b, c) +#define IDirectDrawClipper_GetHWnd(p, a) (p)->GetHWnd(a) +#define IDirectDrawClipper_Initialize(p, a, b) (p)->Initialize(a, b) +#define IDirectDrawClipper_IsClipListChanged(p, a) (p)->IsClipListChanged(a) +#define IDirectDrawClipper_SetClipList(p, a, b) (p)->SetClipList(a, b) +#define IDirectDrawClipper_SetHWnd(p, a, b) (p)->SetHWnd(a, b) +#endif + +#endif + +/* + * IDirectDrawSurface and related interfaces + */ +#if defined( _WIN32 ) && !defined( _NO_COM ) +#undef INTERFACE +#define INTERFACE IDirectDrawSurface +DECLARE_INTERFACE_( IDirectDrawSurface, IUnknown ) +{ + /*** IUnknown methods ***/ + STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID FAR * ppvObj) PURE; + STDMETHOD_(ULONG,AddRef) (THIS) PURE; + STDMETHOD_(ULONG,Release) (THIS) PURE; + /*** IDirectDrawSurface methods ***/ + STDMETHOD(AddAttachedSurface)(THIS_ LPDIRECTDRAWSURFACE) PURE; + STDMETHOD(AddOverlayDirtyRect)(THIS_ LPRECT) PURE; + STDMETHOD(Blt)(THIS_ LPRECT,LPDIRECTDRAWSURFACE, LPRECT,DWORD, LPDDBLTFX) PURE; + STDMETHOD(BltBatch)(THIS_ LPDDBLTBATCH, DWORD, DWORD ) PURE; + STDMETHOD(BltFast)(THIS_ DWORD,DWORD,LPDIRECTDRAWSURFACE, LPRECT,DWORD) PURE; + STDMETHOD(DeleteAttachedSurface)(THIS_ DWORD,LPDIRECTDRAWSURFACE) PURE; + STDMETHOD(EnumAttachedSurfaces)(THIS_ LPVOID,LPDDENUMSURFACESCALLBACK) PURE; + STDMETHOD(EnumOverlayZOrders)(THIS_ DWORD,LPVOID,LPDDENUMSURFACESCALLBACK) PURE; + STDMETHOD(Flip)(THIS_ LPDIRECTDRAWSURFACE, DWORD) PURE; + STDMETHOD(GetAttachedSurface)(THIS_ LPDDSCAPS, LPDIRECTDRAWSURFACE FAR *) PURE; + STDMETHOD(GetBltStatus)(THIS_ DWORD) PURE; + STDMETHOD(GetCaps)(THIS_ LPDDSCAPS) PURE; + STDMETHOD(GetClipper)(THIS_ LPDIRECTDRAWCLIPPER FAR*) PURE; + STDMETHOD(GetColorKey)(THIS_ DWORD, LPDDCOLORKEY) PURE; + STDMETHOD(GetDC)(THIS_ HDC FAR *) PURE; + STDMETHOD(GetFlipStatus)(THIS_ DWORD) PURE; + STDMETHOD(GetOverlayPosition)(THIS_ LPLONG, LPLONG ) PURE; + STDMETHOD(GetPalette)(THIS_ LPDIRECTDRAWPALETTE FAR*) PURE; + STDMETHOD(GetPixelFormat)(THIS_ LPDDPIXELFORMAT) PURE; + STDMETHOD(GetSurfaceDesc)(THIS_ LPDDSURFACEDESC) PURE; + STDMETHOD(Initialize)(THIS_ LPDIRECTDRAW, LPDDSURFACEDESC) PURE; + STDMETHOD(IsLost)(THIS) PURE; + STDMETHOD(Lock)(THIS_ LPRECT,LPDDSURFACEDESC,DWORD,HANDLE) PURE; + STDMETHOD(ReleaseDC)(THIS_ HDC) PURE; + STDMETHOD(Restore)(THIS) PURE; + STDMETHOD(SetClipper)(THIS_ LPDIRECTDRAWCLIPPER) PURE; + STDMETHOD(SetColorKey)(THIS_ DWORD, LPDDCOLORKEY) PURE; + STDMETHOD(SetOverlayPosition)(THIS_ LONG, LONG ) PURE; + STDMETHOD(SetPalette)(THIS_ LPDIRECTDRAWPALETTE) PURE; + STDMETHOD(Unlock)(THIS_ LPVOID) PURE; + STDMETHOD(UpdateOverlay)(THIS_ LPRECT, LPDIRECTDRAWSURFACE,LPRECT,DWORD, LPDDOVERLAYFX) PURE; + STDMETHOD(UpdateOverlayDisplay)(THIS_ DWORD) PURE; + STDMETHOD(UpdateOverlayZOrder)(THIS_ DWORD, LPDIRECTDRAWSURFACE) PURE; +}; + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectDrawSurface_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) +#define IDirectDrawSurface_AddRef(p) (p)->lpVtbl->AddRef(p) +#define IDirectDrawSurface_Release(p) (p)->lpVtbl->Release(p) +#define IDirectDrawSurface_AddAttachedSurface(p,a) (p)->lpVtbl->AddAttachedSurface(p,a) +#define IDirectDrawSurface_AddOverlayDirtyRect(p,a) (p)->lpVtbl->AddOverlayDirtyRect(p,a) +#define IDirectDrawSurface_Blt(p,a,b,c,d,e) (p)->lpVtbl->Blt(p,a,b,c,d,e) +#define IDirectDrawSurface_BltBatch(p,a,b,c) (p)->lpVtbl->BltBatch(p,a,b,c) +#define IDirectDrawSurface_BltFast(p,a,b,c,d,e) (p)->lpVtbl->BltFast(p,a,b,c,d,e) +#define IDirectDrawSurface_DeleteAttachedSurface(p,a,b) (p)->lpVtbl->DeleteAttachedSurface(p,a,b) +#define IDirectDrawSurface_EnumAttachedSurfaces(p,a,b) (p)->lpVtbl->EnumAttachedSurfaces(p,a,b) +#define IDirectDrawSurface_EnumOverlayZOrders(p,a,b,c) (p)->lpVtbl->EnumOverlayZOrders(p,a,b,c) +#define IDirectDrawSurface_Flip(p,a,b) (p)->lpVtbl->Flip(p,a,b) +#define IDirectDrawSurface_GetAttachedSurface(p,a,b) (p)->lpVtbl->GetAttachedSurface(p,a,b) +#define IDirectDrawSurface_GetBltStatus(p,a) (p)->lpVtbl->GetBltStatus(p,a) +#define IDirectDrawSurface_GetCaps(p,b) (p)->lpVtbl->GetCaps(p,b) +#define IDirectDrawSurface_GetClipper(p,a) (p)->lpVtbl->GetClipper(p,a) +#define IDirectDrawSurface_GetColorKey(p,a,b) (p)->lpVtbl->GetColorKey(p,a,b) +#define IDirectDrawSurface_GetDC(p,a) (p)->lpVtbl->GetDC(p,a) +#define IDirectDrawSurface_GetFlipStatus(p,a) (p)->lpVtbl->GetFlipStatus(p,a) +#define IDirectDrawSurface_GetOverlayPosition(p,a,b) (p)->lpVtbl->GetOverlayPosition(p,a,b) +#define IDirectDrawSurface_GetPalette(p,a) (p)->lpVtbl->GetPalette(p,a) +#define IDirectDrawSurface_GetPixelFormat(p,a) (p)->lpVtbl->GetPixelFormat(p,a) +#define IDirectDrawSurface_GetSurfaceDesc(p,a) (p)->lpVtbl->GetSurfaceDesc(p,a) +#define IDirectDrawSurface_Initialize(p,a,b) (p)->lpVtbl->Initialize(p,a,b) +#define IDirectDrawSurface_IsLost(p) (p)->lpVtbl->IsLost(p) +#define IDirectDrawSurface_Lock(p,a,b,c,d) (p)->lpVtbl->Lock(p,a,b,c,d) +#define IDirectDrawSurface_ReleaseDC(p,a) (p)->lpVtbl->ReleaseDC(p,a) +#define IDirectDrawSurface_Restore(p) (p)->lpVtbl->Restore(p) +#define IDirectDrawSurface_SetClipper(p,a) (p)->lpVtbl->SetClipper(p,a) +#define IDirectDrawSurface_SetColorKey(p,a,b) (p)->lpVtbl->SetColorKey(p,a,b) +#define IDirectDrawSurface_SetOverlayPosition(p,a,b) (p)->lpVtbl->SetOverlayPosition(p,a,b) +#define IDirectDrawSurface_SetPalette(p,a) (p)->lpVtbl->SetPalette(p,a) +#define IDirectDrawSurface_Unlock(p,b) (p)->lpVtbl->Unlock(p,b) +#define IDirectDrawSurface_UpdateOverlay(p,a,b,c,d,e) (p)->lpVtbl->UpdateOverlay(p,a,b,c,d,e) +#define IDirectDrawSurface_UpdateOverlayDisplay(p,a) (p)->lpVtbl->UpdateOverlayDisplay(p,a) +#define IDirectDrawSurface_UpdateOverlayZOrder(p,a,b) (p)->lpVtbl->UpdateOverlayZOrder(p,a,b) +#else +#define IDirectDrawSurface_QueryInterface(p,a,b) (p)->QueryInterface(a,b) +#define IDirectDrawSurface_AddRef(p) (p)->AddRef() +#define IDirectDrawSurface_Release(p) (p)->Release() +#define IDirectDrawSurface_AddAttachedSurface(p,a) (p)->AddAttachedSurface(a) +#define IDirectDrawSurface_AddOverlayDirtyRect(p,a) (p)->AddOverlayDirtyRect(a) +#define IDirectDrawSurface_Blt(p,a,b,c,d,e) (p)->Blt(a,b,c,d,e) +#define IDirectDrawSurface_BltBatch(p,a,b,c) (p)->BltBatch(a,b,c) +#define IDirectDrawSurface_BltFast(p,a,b,c,d,e) (p)->BltFast(a,b,c,d,e) +#define IDirectDrawSurface_DeleteAttachedSurface(p,a,b) (p)->DeleteAttachedSurface(a,b) +#define IDirectDrawSurface_EnumAttachedSurfaces(p,a,b) (p)->EnumAttachedSurfaces(a,b) +#define IDirectDrawSurface_EnumOverlayZOrders(p,a,b,c) (p)->EnumOverlayZOrders(a,b,c) +#define IDirectDrawSurface_Flip(p,a,b) (p)->Flip(a,b) +#define IDirectDrawSurface_GetAttachedSurface(p,a,b) (p)->GetAttachedSurface(a,b) +#define IDirectDrawSurface_GetBltStatus(p,a) (p)->GetBltStatus(a) +#define IDirectDrawSurface_GetCaps(p,b) (p)->GetCaps(b) +#define IDirectDrawSurface_GetClipper(p,a) (p)->GetClipper(a) +#define IDirectDrawSurface_GetColorKey(p,a,b) (p)->GetColorKey(a,b) +#define IDirectDrawSurface_GetDC(p,a) (p)->GetDC(a) +#define IDirectDrawSurface_GetFlipStatus(p,a) (p)->GetFlipStatus(a) +#define IDirectDrawSurface_GetOverlayPosition(p,a,b) (p)->GetOverlayPosition(a,b) +#define IDirectDrawSurface_GetPalette(p,a) (p)->GetPalette(a) +#define IDirectDrawSurface_GetPixelFormat(p,a) (p)->GetPixelFormat(a) +#define IDirectDrawSurface_GetSurfaceDesc(p,a) (p)->GetSurfaceDesc(a) +#define IDirectDrawSurface_Initialize(p,a,b) (p)->Initialize(a,b) +#define IDirectDrawSurface_IsLost(p) (p)->IsLost() +#define IDirectDrawSurface_Lock(p,a,b,c,d) (p)->Lock(a,b,c,d) +#define IDirectDrawSurface_ReleaseDC(p,a) (p)->ReleaseDC(a) +#define IDirectDrawSurface_Restore(p) (p)->Restore() +#define IDirectDrawSurface_SetClipper(p,a) (p)->SetClipper(a) +#define IDirectDrawSurface_SetColorKey(p,a,b) (p)->SetColorKey(a,b) +#define IDirectDrawSurface_SetOverlayPosition(p,a,b) (p)->SetOverlayPosition(a,b) +#define IDirectDrawSurface_SetPalette(p,a) (p)->SetPalette(a) +#define IDirectDrawSurface_Unlock(p,b) (p)->Unlock(b) +#define IDirectDrawSurface_UpdateOverlay(p,a,b,c,d,e) (p)->UpdateOverlay(a,b,c,d,e) +#define IDirectDrawSurface_UpdateOverlayDisplay(p,a) (p)->UpdateOverlayDisplay(a) +#define IDirectDrawSurface_UpdateOverlayZOrder(p,a,b) (p)->UpdateOverlayZOrder(a,b) +#endif + +/* + * IDirectDrawSurface2 and related interfaces + */ +#undef INTERFACE +#define INTERFACE IDirectDrawSurface2 +DECLARE_INTERFACE_( IDirectDrawSurface2, IUnknown ) +{ + /*** IUnknown methods ***/ + STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID FAR * ppvObj) PURE; + STDMETHOD_(ULONG,AddRef) (THIS) PURE; + STDMETHOD_(ULONG,Release) (THIS) PURE; + /*** IDirectDrawSurface methods ***/ + STDMETHOD(AddAttachedSurface)(THIS_ LPDIRECTDRAWSURFACE2) PURE; + STDMETHOD(AddOverlayDirtyRect)(THIS_ LPRECT) PURE; + STDMETHOD(Blt)(THIS_ LPRECT,LPDIRECTDRAWSURFACE2, LPRECT,DWORD, LPDDBLTFX) PURE; + STDMETHOD(BltBatch)(THIS_ LPDDBLTBATCH, DWORD, DWORD ) PURE; + STDMETHOD(BltFast)(THIS_ DWORD,DWORD,LPDIRECTDRAWSURFACE2, LPRECT,DWORD) PURE; + STDMETHOD(DeleteAttachedSurface)(THIS_ DWORD,LPDIRECTDRAWSURFACE2) PURE; + STDMETHOD(EnumAttachedSurfaces)(THIS_ LPVOID,LPDDENUMSURFACESCALLBACK) PURE; + STDMETHOD(EnumOverlayZOrders)(THIS_ DWORD,LPVOID,LPDDENUMSURFACESCALLBACK) PURE; + STDMETHOD(Flip)(THIS_ LPDIRECTDRAWSURFACE2, DWORD) PURE; + STDMETHOD(GetAttachedSurface)(THIS_ LPDDSCAPS, LPDIRECTDRAWSURFACE2 FAR *) PURE; + STDMETHOD(GetBltStatus)(THIS_ DWORD) PURE; + STDMETHOD(GetCaps)(THIS_ LPDDSCAPS) PURE; + STDMETHOD(GetClipper)(THIS_ LPDIRECTDRAWCLIPPER FAR*) PURE; + STDMETHOD(GetColorKey)(THIS_ DWORD, LPDDCOLORKEY) PURE; + STDMETHOD(GetDC)(THIS_ HDC FAR *) PURE; + STDMETHOD(GetFlipStatus)(THIS_ DWORD) PURE; + STDMETHOD(GetOverlayPosition)(THIS_ LPLONG, LPLONG ) PURE; + STDMETHOD(GetPalette)(THIS_ LPDIRECTDRAWPALETTE FAR*) PURE; + STDMETHOD(GetPixelFormat)(THIS_ LPDDPIXELFORMAT) PURE; + STDMETHOD(GetSurfaceDesc)(THIS_ LPDDSURFACEDESC) PURE; + STDMETHOD(Initialize)(THIS_ LPDIRECTDRAW, LPDDSURFACEDESC) PURE; + STDMETHOD(IsLost)(THIS) PURE; + STDMETHOD(Lock)(THIS_ LPRECT,LPDDSURFACEDESC,DWORD,HANDLE) PURE; + STDMETHOD(ReleaseDC)(THIS_ HDC) PURE; + STDMETHOD(Restore)(THIS) PURE; + STDMETHOD(SetClipper)(THIS_ LPDIRECTDRAWCLIPPER) PURE; + STDMETHOD(SetColorKey)(THIS_ DWORD, LPDDCOLORKEY) PURE; + STDMETHOD(SetOverlayPosition)(THIS_ LONG, LONG ) PURE; + STDMETHOD(SetPalette)(THIS_ LPDIRECTDRAWPALETTE) PURE; + STDMETHOD(Unlock)(THIS_ LPVOID) PURE; + STDMETHOD(UpdateOverlay)(THIS_ LPRECT, LPDIRECTDRAWSURFACE2,LPRECT,DWORD, LPDDOVERLAYFX) PURE; + STDMETHOD(UpdateOverlayDisplay)(THIS_ DWORD) PURE; + STDMETHOD(UpdateOverlayZOrder)(THIS_ DWORD, LPDIRECTDRAWSURFACE2) PURE; + /*** Added in the v2 interface ***/ + STDMETHOD(GetDDInterface)(THIS_ LPVOID FAR *) PURE; + STDMETHOD(PageLock)(THIS_ DWORD) PURE; + STDMETHOD(PageUnlock)(THIS_ DWORD) PURE; +}; + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectDrawSurface2_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) +#define IDirectDrawSurface2_AddRef(p) (p)->lpVtbl->AddRef(p) +#define IDirectDrawSurface2_Release(p) (p)->lpVtbl->Release(p) +#define IDirectDrawSurface2_AddAttachedSurface(p,a) (p)->lpVtbl->AddAttachedSurface(p,a) +#define IDirectDrawSurface2_AddOverlayDirtyRect(p,a) (p)->lpVtbl->AddOverlayDirtyRect(p,a) +#define IDirectDrawSurface2_Blt(p,a,b,c,d,e) (p)->lpVtbl->Blt(p,a,b,c,d,e) +#define IDirectDrawSurface2_BltBatch(p,a,b,c) (p)->lpVtbl->BltBatch(p,a,b,c) +#define IDirectDrawSurface2_BltFast(p,a,b,c,d,e) (p)->lpVtbl->BltFast(p,a,b,c,d,e) +#define IDirectDrawSurface2_DeleteAttachedSurface(p,a,b) (p)->lpVtbl->DeleteAttachedSurface(p,a,b) +#define IDirectDrawSurface2_EnumAttachedSurfaces(p,a,b) (p)->lpVtbl->EnumAttachedSurfaces(p,a,b) +#define IDirectDrawSurface2_EnumOverlayZOrders(p,a,b,c) (p)->lpVtbl->EnumOverlayZOrders(p,a,b,c) +#define IDirectDrawSurface2_Flip(p,a,b) (p)->lpVtbl->Flip(p,a,b) +#define IDirectDrawSurface2_GetAttachedSurface(p,a,b) (p)->lpVtbl->GetAttachedSurface(p,a,b) +#define IDirectDrawSurface2_GetBltStatus(p,a) (p)->lpVtbl->GetBltStatus(p,a) +#define IDirectDrawSurface2_GetCaps(p,b) (p)->lpVtbl->GetCaps(p,b) +#define IDirectDrawSurface2_GetClipper(p,a) (p)->lpVtbl->GetClipper(p,a) +#define IDirectDrawSurface2_GetColorKey(p,a,b) (p)->lpVtbl->GetColorKey(p,a,b) +#define IDirectDrawSurface2_GetDC(p,a) (p)->lpVtbl->GetDC(p,a) +#define IDirectDrawSurface2_GetFlipStatus(p,a) (p)->lpVtbl->GetFlipStatus(p,a) +#define IDirectDrawSurface2_GetOverlayPosition(p,a,b) (p)->lpVtbl->GetOverlayPosition(p,a,b) +#define IDirectDrawSurface2_GetPalette(p,a) (p)->lpVtbl->GetPalette(p,a) +#define IDirectDrawSurface2_GetPixelFormat(p,a) (p)->lpVtbl->GetPixelFormat(p,a) +#define IDirectDrawSurface2_GetSurfaceDesc(p,a) (p)->lpVtbl->GetSurfaceDesc(p,a) +#define IDirectDrawSurface2_Initialize(p,a,b) (p)->lpVtbl->Initialize(p,a,b) +#define IDirectDrawSurface2_IsLost(p) (p)->lpVtbl->IsLost(p) +#define IDirectDrawSurface2_Lock(p,a,b,c,d) (p)->lpVtbl->Lock(p,a,b,c,d) +#define IDirectDrawSurface2_ReleaseDC(p,a) (p)->lpVtbl->ReleaseDC(p,a) +#define IDirectDrawSurface2_Restore(p) (p)->lpVtbl->Restore(p) +#define IDirectDrawSurface2_SetClipper(p,a) (p)->lpVtbl->SetClipper(p,a) +#define IDirectDrawSurface2_SetColorKey(p,a,b) (p)->lpVtbl->SetColorKey(p,a,b) +#define IDirectDrawSurface2_SetOverlayPosition(p,a,b) (p)->lpVtbl->SetOverlayPosition(p,a,b) +#define IDirectDrawSurface2_SetPalette(p,a) (p)->lpVtbl->SetPalette(p,a) +#define IDirectDrawSurface2_Unlock(p,b) (p)->lpVtbl->Unlock(p,b) +#define IDirectDrawSurface2_UpdateOverlay(p,a,b,c,d,e) (p)->lpVtbl->UpdateOverlay(p,a,b,c,d,e) +#define IDirectDrawSurface2_UpdateOverlayDisplay(p,a) (p)->lpVtbl->UpdateOverlayDisplay(p,a) +#define IDirectDrawSurface2_UpdateOverlayZOrder(p,a,b) (p)->lpVtbl->UpdateOverlayZOrder(p,a,b) +#define IDirectDrawSurface2_GetDDInterface(p,a) (p)->lpVtbl->GetDDInterface(p,a) +#define IDirectDrawSurface2_PageLock(p,a) (p)->lpVtbl->PageLock(p,a) +#define IDirectDrawSurface2_PageUnlock(p,a) (p)->lpVtbl->PageUnlock(p,a) +#else +#define IDirectDrawSurface2_QueryInterface(p,a,b) (p)->QueryInterface(a,b) +#define IDirectDrawSurface2_AddRef(p) (p)->AddRef() +#define IDirectDrawSurface2_Release(p) (p)->Release() +#define IDirectDrawSurface2_AddAttachedSurface(p,a) (p)->AddAttachedSurface(a) +#define IDirectDrawSurface2_AddOverlayDirtyRect(p,a) (p)->AddOverlayDirtyRect(a) +#define IDirectDrawSurface2_Blt(p,a,b,c,d,e) (p)->Blt(a,b,c,d,e) +#define IDirectDrawSurface2_BltBatch(p,a,b,c) (p)->BltBatch(a,b,c) +#define IDirectDrawSurface2_BltFast(p,a,b,c,d,e) (p)->BltFast(a,b,c,d,e) +#define IDirectDrawSurface2_DeleteAttachedSurface(p,a,b) (p)->DeleteAttachedSurface(a,b) +#define IDirectDrawSurface2_EnumAttachedSurfaces(p,a,b) (p)->EnumAttachedSurfaces(a,b) +#define IDirectDrawSurface2_EnumOverlayZOrders(p,a,b,c) (p)->EnumOverlayZOrders(a,b,c) +#define IDirectDrawSurface2_Flip(p,a,b) (p)->Flip(a,b) +#define IDirectDrawSurface2_GetAttachedSurface(p,a,b) (p)->GetAttachedSurface(a,b) +#define IDirectDrawSurface2_GetBltStatus(p,a) (p)->GetBltStatus(a) +#define IDirectDrawSurface2_GetCaps(p,b) (p)->GetCaps(b) +#define IDirectDrawSurface2_GetClipper(p,a) (p)->GetClipper(a) +#define IDirectDrawSurface2_GetColorKey(p,a,b) (p)->GetColorKey(a,b) +#define IDirectDrawSurface2_GetDC(p,a) (p)->GetDC(a) +#define IDirectDrawSurface2_GetFlipStatus(p,a) (p)->GetFlipStatus(a) +#define IDirectDrawSurface2_GetOverlayPosition(p,a,b) (p)->GetOverlayPosition(a,b) +#define IDirectDrawSurface2_GetPalette(p,a) (p)->GetPalette(a) +#define IDirectDrawSurface2_GetPixelFormat(p,a) (p)->GetPixelFormat(a) +#define IDirectDrawSurface2_GetSurfaceDesc(p,a) (p)->GetSurfaceDesc(a) +#define IDirectDrawSurface2_Initialize(p,a,b) (p)->Initialize(a,b) +#define IDirectDrawSurface2_IsLost(p) (p)->IsLost() +#define IDirectDrawSurface2_Lock(p,a,b,c,d) (p)->Lock(a,b,c,d) +#define IDirectDrawSurface2_ReleaseDC(p,a) (p)->ReleaseDC(a) +#define IDirectDrawSurface2_Restore(p) (p)->Restore() +#define IDirectDrawSurface2_SetClipper(p,a) (p)->SetClipper(a) +#define IDirectDrawSurface2_SetColorKey(p,a,b) (p)->SetColorKey(a,b) +#define IDirectDrawSurface2_SetOverlayPosition(p,a,b) (p)->SetOverlayPosition(a,b) +#define IDirectDrawSurface2_SetPalette(p,a) (p)->SetPalette(a) +#define IDirectDrawSurface2_Unlock(p,b) (p)->Unlock(b) +#define IDirectDrawSurface2_UpdateOverlay(p,a,b,c,d,e) (p)->UpdateOverlay(a,b,c,d,e) +#define IDirectDrawSurface2_UpdateOverlayDisplay(p,a) (p)->UpdateOverlayDisplay(a) +#define IDirectDrawSurface2_UpdateOverlayZOrder(p,a,b) (p)->UpdateOverlayZOrder(a,b) +#define IDirectDrawSurface2_GetDDInterface(p,a) (p)->GetDDInterface(a) +#define IDirectDrawSurface2_PageLock(p,a) (p)->PageLock(a) +#define IDirectDrawSurface2_PageUnlock(p,a) (p)->PageUnlock(a) +#endif + +/* + * IDirectDrawSurface3 and related interfaces + */ +#undef INTERFACE +#define INTERFACE IDirectDrawSurface3 +DECLARE_INTERFACE_( IDirectDrawSurface3, IUnknown ) +{ + /*** IUnknown methods ***/ + STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID FAR * ppvObj) PURE; + STDMETHOD_(ULONG,AddRef) (THIS) PURE; + STDMETHOD_(ULONG,Release) (THIS) PURE; + /*** IDirectDrawSurface methods ***/ + STDMETHOD(AddAttachedSurface)(THIS_ LPDIRECTDRAWSURFACE3) PURE; + STDMETHOD(AddOverlayDirtyRect)(THIS_ LPRECT) PURE; + STDMETHOD(Blt)(THIS_ LPRECT,LPDIRECTDRAWSURFACE3, LPRECT,DWORD, LPDDBLTFX) PURE; + STDMETHOD(BltBatch)(THIS_ LPDDBLTBATCH, DWORD, DWORD ) PURE; + STDMETHOD(BltFast)(THIS_ DWORD,DWORD,LPDIRECTDRAWSURFACE3, LPRECT,DWORD) PURE; + STDMETHOD(DeleteAttachedSurface)(THIS_ DWORD,LPDIRECTDRAWSURFACE3) PURE; + STDMETHOD(EnumAttachedSurfaces)(THIS_ LPVOID,LPDDENUMSURFACESCALLBACK) PURE; + STDMETHOD(EnumOverlayZOrders)(THIS_ DWORD,LPVOID,LPDDENUMSURFACESCALLBACK) PURE; + STDMETHOD(Flip)(THIS_ LPDIRECTDRAWSURFACE3, DWORD) PURE; + STDMETHOD(GetAttachedSurface)(THIS_ LPDDSCAPS, LPDIRECTDRAWSURFACE3 FAR *) PURE; + STDMETHOD(GetBltStatus)(THIS_ DWORD) PURE; + STDMETHOD(GetCaps)(THIS_ LPDDSCAPS) PURE; + STDMETHOD(GetClipper)(THIS_ LPDIRECTDRAWCLIPPER FAR*) PURE; + STDMETHOD(GetColorKey)(THIS_ DWORD, LPDDCOLORKEY) PURE; + STDMETHOD(GetDC)(THIS_ HDC FAR *) PURE; + STDMETHOD(GetFlipStatus)(THIS_ DWORD) PURE; + STDMETHOD(GetOverlayPosition)(THIS_ LPLONG, LPLONG ) PURE; + STDMETHOD(GetPalette)(THIS_ LPDIRECTDRAWPALETTE FAR*) PURE; + STDMETHOD(GetPixelFormat)(THIS_ LPDDPIXELFORMAT) PURE; + STDMETHOD(GetSurfaceDesc)(THIS_ LPDDSURFACEDESC) PURE; + STDMETHOD(Initialize)(THIS_ LPDIRECTDRAW, LPDDSURFACEDESC) PURE; + STDMETHOD(IsLost)(THIS) PURE; + STDMETHOD(Lock)(THIS_ LPRECT,LPDDSURFACEDESC,DWORD,HANDLE) PURE; + STDMETHOD(ReleaseDC)(THIS_ HDC) PURE; + STDMETHOD(Restore)(THIS) PURE; + STDMETHOD(SetClipper)(THIS_ LPDIRECTDRAWCLIPPER) PURE; + STDMETHOD(SetColorKey)(THIS_ DWORD, LPDDCOLORKEY) PURE; + STDMETHOD(SetOverlayPosition)(THIS_ LONG, LONG ) PURE; + STDMETHOD(SetPalette)(THIS_ LPDIRECTDRAWPALETTE) PURE; + STDMETHOD(Unlock)(THIS_ LPVOID) PURE; + STDMETHOD(UpdateOverlay)(THIS_ LPRECT, LPDIRECTDRAWSURFACE3,LPRECT,DWORD, LPDDOVERLAYFX) PURE; + STDMETHOD(UpdateOverlayDisplay)(THIS_ DWORD) PURE; + STDMETHOD(UpdateOverlayZOrder)(THIS_ DWORD, LPDIRECTDRAWSURFACE3) PURE; + /*** Added in the v2 interface ***/ + STDMETHOD(GetDDInterface)(THIS_ LPVOID FAR *) PURE; + STDMETHOD(PageLock)(THIS_ DWORD) PURE; + STDMETHOD(PageUnlock)(THIS_ DWORD) PURE; + /*** Added in the V3 interface ***/ + STDMETHOD(SetSurfaceDesc)(THIS_ LPDDSURFACEDESC, DWORD) PURE; +}; + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectDrawSurface3_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) +#define IDirectDrawSurface3_AddRef(p) (p)->lpVtbl->AddRef(p) +#define IDirectDrawSurface3_Release(p) (p)->lpVtbl->Release(p) +#define IDirectDrawSurface3_AddAttachedSurface(p,a) (p)->lpVtbl->AddAttachedSurface(p,a) +#define IDirectDrawSurface3_AddOverlayDirtyRect(p,a) (p)->lpVtbl->AddOverlayDirtyRect(p,a) +#define IDirectDrawSurface3_Blt(p,a,b,c,d,e) (p)->lpVtbl->Blt(p,a,b,c,d,e) +#define IDirectDrawSurface3_BltBatch(p,a,b,c) (p)->lpVtbl->BltBatch(p,a,b,c) +#define IDirectDrawSurface3_BltFast(p,a,b,c,d,e) (p)->lpVtbl->BltFast(p,a,b,c,d,e) +#define IDirectDrawSurface3_DeleteAttachedSurface(p,a,b) (p)->lpVtbl->DeleteAttachedSurface(p,a,b) +#define IDirectDrawSurface3_EnumAttachedSurfaces(p,a,b) (p)->lpVtbl->EnumAttachedSurfaces(p,a,b) +#define IDirectDrawSurface3_EnumOverlayZOrders(p,a,b,c) (p)->lpVtbl->EnumOverlayZOrders(p,a,b,c) +#define IDirectDrawSurface3_Flip(p,a,b) (p)->lpVtbl->Flip(p,a,b) +#define IDirectDrawSurface3_GetAttachedSurface(p,a,b) (p)->lpVtbl->GetAttachedSurface(p,a,b) +#define IDirectDrawSurface3_GetBltStatus(p,a) (p)->lpVtbl->GetBltStatus(p,a) +#define IDirectDrawSurface3_GetCaps(p,b) (p)->lpVtbl->GetCaps(p,b) +#define IDirectDrawSurface3_GetClipper(p,a) (p)->lpVtbl->GetClipper(p,a) +#define IDirectDrawSurface3_GetColorKey(p,a,b) (p)->lpVtbl->GetColorKey(p,a,b) +#define IDirectDrawSurface3_GetDC(p,a) (p)->lpVtbl->GetDC(p,a) +#define IDirectDrawSurface3_GetFlipStatus(p,a) (p)->lpVtbl->GetFlipStatus(p,a) +#define IDirectDrawSurface3_GetOverlayPosition(p,a,b) (p)->lpVtbl->GetOverlayPosition(p,a,b) +#define IDirectDrawSurface3_GetPalette(p,a) (p)->lpVtbl->GetPalette(p,a) +#define IDirectDrawSurface3_GetPixelFormat(p,a) (p)->lpVtbl->GetPixelFormat(p,a) +#define IDirectDrawSurface3_GetSurfaceDesc(p,a) (p)->lpVtbl->GetSurfaceDesc(p,a) +#define IDirectDrawSurface3_Initialize(p,a,b) (p)->lpVtbl->Initialize(p,a,b) +#define IDirectDrawSurface3_IsLost(p) (p)->lpVtbl->IsLost(p) +#define IDirectDrawSurface3_Lock(p,a,b,c,d) (p)->lpVtbl->Lock(p,a,b,c,d) +#define IDirectDrawSurface3_ReleaseDC(p,a) (p)->lpVtbl->ReleaseDC(p,a) +#define IDirectDrawSurface3_Restore(p) (p)->lpVtbl->Restore(p) +#define IDirectDrawSurface3_SetClipper(p,a) (p)->lpVtbl->SetClipper(p,a) +#define IDirectDrawSurface3_SetColorKey(p,a,b) (p)->lpVtbl->SetColorKey(p,a,b) +#define IDirectDrawSurface3_SetOverlayPosition(p,a,b) (p)->lpVtbl->SetOverlayPosition(p,a,b) +#define IDirectDrawSurface3_SetPalette(p,a) (p)->lpVtbl->SetPalette(p,a) +#define IDirectDrawSurface3_Unlock(p,b) (p)->lpVtbl->Unlock(p,b) +#define IDirectDrawSurface3_UpdateOverlay(p,a,b,c,d,e) (p)->lpVtbl->UpdateOverlay(p,a,b,c,d,e) +#define IDirectDrawSurface3_UpdateOverlayDisplay(p,a) (p)->lpVtbl->UpdateOverlayDisplay(p,a) +#define IDirectDrawSurface3_UpdateOverlayZOrder(p,a,b) (p)->lpVtbl->UpdateOverlayZOrder(p,a,b) +#define IDirectDrawSurface3_GetDDInterface(p,a) (p)->lpVtbl->GetDDInterface(p,a) +#define IDirectDrawSurface3_PageLock(p,a) (p)->lpVtbl->PageLock(p,a) +#define IDirectDrawSurface3_PageUnlock(p,a) (p)->lpVtbl->PageUnlock(p,a) +#define IDirectDrawSurface3_SetSurfaceDesc(p,a,b) (p)->lpVtbl->SetSurfaceDesc(p,a,b) +#else +#define IDirectDrawSurface3_QueryInterface(p,a,b) (p)->QueryInterface(a,b) +#define IDirectDrawSurface3_AddRef(p) (p)->AddRef() +#define IDirectDrawSurface3_Release(p) (p)->Release() +#define IDirectDrawSurface3_AddAttachedSurface(p,a) (p)->AddAttachedSurface(a) +#define IDirectDrawSurface3_AddOverlayDirtyRect(p,a) (p)->AddOverlayDirtyRect(a) +#define IDirectDrawSurface3_Blt(p,a,b,c,d,e) (p)->Blt(a,b,c,d,e) +#define IDirectDrawSurface3_BltBatch(p,a,b,c) (p)->BltBatch(a,b,c) +#define IDirectDrawSurface3_BltFast(p,a,b,c,d,e) (p)->BltFast(a,b,c,d,e) +#define IDirectDrawSurface3_DeleteAttachedSurface(p,a,b) (p)->DeleteAttachedSurface(a,b) +#define IDirectDrawSurface3_EnumAttachedSurfaces(p,a,b) (p)->EnumAttachedSurfaces(a,b) +#define IDirectDrawSurface3_EnumOverlayZOrders(p,a,b,c) (p)->EnumOverlayZOrders(a,b,c) +#define IDirectDrawSurface3_Flip(p,a,b) (p)->Flip(a,b) +#define IDirectDrawSurface3_GetAttachedSurface(p,a,b) (p)->GetAttachedSurface(a,b) +#define IDirectDrawSurface3_GetBltStatus(p,a) (p)->GetBltStatus(a) +#define IDirectDrawSurface3_GetCaps(p,b) (p)->GetCaps(b) +#define IDirectDrawSurface3_GetClipper(p,a) (p)->GetClipper(a) +#define IDirectDrawSurface3_GetColorKey(p,a,b) (p)->GetColorKey(a,b) +#define IDirectDrawSurface3_GetDC(p,a) (p)->GetDC(a) +#define IDirectDrawSurface3_GetFlipStatus(p,a) (p)->GetFlipStatus(a) +#define IDirectDrawSurface3_GetOverlayPosition(p,a,b) (p)->GetOverlayPosition(a,b) +#define IDirectDrawSurface3_GetPalette(p,a) (p)->GetPalette(a) +#define IDirectDrawSurface3_GetPixelFormat(p,a) (p)->GetPixelFormat(a) +#define IDirectDrawSurface3_GetSurfaceDesc(p,a) (p)->GetSurfaceDesc(a) +#define IDirectDrawSurface3_Initialize(p,a,b) (p)->Initialize(a,b) +#define IDirectDrawSurface3_IsLost(p) (p)->IsLost() +#define IDirectDrawSurface3_Lock(p,a,b,c,d) (p)->Lock(a,b,c,d) +#define IDirectDrawSurface3_ReleaseDC(p,a) (p)->ReleaseDC(a) +#define IDirectDrawSurface3_Restore(p) (p)->Restore() +#define IDirectDrawSurface3_SetClipper(p,a) (p)->SetClipper(a) +#define IDirectDrawSurface3_SetColorKey(p,a,b) (p)->SetColorKey(a,b) +#define IDirectDrawSurface3_SetOverlayPosition(p,a,b) (p)->SetOverlayPosition(a,b) +#define IDirectDrawSurface3_SetPalette(p,a) (p)->SetPalette(a) +#define IDirectDrawSurface3_Unlock(p,b) (p)->Unlock(b) +#define IDirectDrawSurface3_UpdateOverlay(p,a,b,c,d,e) (p)->UpdateOverlay(a,b,c,d,e) +#define IDirectDrawSurface3_UpdateOverlayDisplay(p,a) (p)->UpdateOverlayDisplay(a) +#define IDirectDrawSurface3_UpdateOverlayZOrder(p,a,b) (p)->UpdateOverlayZOrder(a,b) +#define IDirectDrawSurface3_GetDDInterface(p,a) (p)->GetDDInterface(a) +#define IDirectDrawSurface3_PageLock(p,a) (p)->PageLock(a) +#define IDirectDrawSurface3_PageUnlock(p,a) (p)->PageUnlock(a) +#define IDirectDrawSurface3_SetSurfaceDesc(p,a,b) (p)->SetSurfaceDesc(a,b) +#endif + +/* + * IDirectDrawSurface4 and related interfaces + */ +#undef INTERFACE +#define INTERFACE IDirectDrawSurface4 +DECLARE_INTERFACE_( IDirectDrawSurface4, IUnknown ) +{ + /*** IUnknown methods ***/ + STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID FAR * ppvObj) PURE; + STDMETHOD_(ULONG,AddRef) (THIS) PURE; + STDMETHOD_(ULONG,Release) (THIS) PURE; + /*** IDirectDrawSurface methods ***/ + STDMETHOD(AddAttachedSurface)(THIS_ LPDIRECTDRAWSURFACE4) PURE; + STDMETHOD(AddOverlayDirtyRect)(THIS_ LPRECT) PURE; + STDMETHOD(Blt)(THIS_ LPRECT,LPDIRECTDRAWSURFACE4, LPRECT,DWORD, LPDDBLTFX) PURE; + STDMETHOD(BltBatch)(THIS_ LPDDBLTBATCH, DWORD, DWORD ) PURE; + STDMETHOD(BltFast)(THIS_ DWORD,DWORD,LPDIRECTDRAWSURFACE4, LPRECT,DWORD) PURE; + STDMETHOD(DeleteAttachedSurface)(THIS_ DWORD,LPDIRECTDRAWSURFACE4) PURE; + STDMETHOD(EnumAttachedSurfaces)(THIS_ LPVOID,LPDDENUMSURFACESCALLBACK2) PURE; + STDMETHOD(EnumOverlayZOrders)(THIS_ DWORD,LPVOID,LPDDENUMSURFACESCALLBACK2) PURE; + STDMETHOD(Flip)(THIS_ LPDIRECTDRAWSURFACE4, DWORD) PURE; + STDMETHOD(GetAttachedSurface)(THIS_ LPDDSCAPS2, LPDIRECTDRAWSURFACE4 FAR *) PURE; + STDMETHOD(GetBltStatus)(THIS_ DWORD) PURE; + STDMETHOD(GetCaps)(THIS_ LPDDSCAPS2) PURE; + STDMETHOD(GetClipper)(THIS_ LPDIRECTDRAWCLIPPER FAR*) PURE; + STDMETHOD(GetColorKey)(THIS_ DWORD, LPDDCOLORKEY) PURE; + STDMETHOD(GetDC)(THIS_ HDC FAR *) PURE; + STDMETHOD(GetFlipStatus)(THIS_ DWORD) PURE; + STDMETHOD(GetOverlayPosition)(THIS_ LPLONG, LPLONG ) PURE; + STDMETHOD(GetPalette)(THIS_ LPDIRECTDRAWPALETTE FAR*) PURE; + STDMETHOD(GetPixelFormat)(THIS_ LPDDPIXELFORMAT) PURE; + STDMETHOD(GetSurfaceDesc)(THIS_ LPDDSURFACEDESC2) PURE; + STDMETHOD(Initialize)(THIS_ LPDIRECTDRAW, LPDDSURFACEDESC2) PURE; + STDMETHOD(IsLost)(THIS) PURE; + STDMETHOD(Lock)(THIS_ LPRECT,LPDDSURFACEDESC2,DWORD,HANDLE) PURE; + STDMETHOD(ReleaseDC)(THIS_ HDC) PURE; + STDMETHOD(Restore)(THIS) PURE; + STDMETHOD(SetClipper)(THIS_ LPDIRECTDRAWCLIPPER) PURE; + STDMETHOD(SetColorKey)(THIS_ DWORD, LPDDCOLORKEY) PURE; + STDMETHOD(SetOverlayPosition)(THIS_ LONG, LONG ) PURE; + STDMETHOD(SetPalette)(THIS_ LPDIRECTDRAWPALETTE) PURE; + STDMETHOD(Unlock)(THIS_ LPRECT) PURE; + STDMETHOD(UpdateOverlay)(THIS_ LPRECT, LPDIRECTDRAWSURFACE4,LPRECT,DWORD, LPDDOVERLAYFX) PURE; + STDMETHOD(UpdateOverlayDisplay)(THIS_ DWORD) PURE; + STDMETHOD(UpdateOverlayZOrder)(THIS_ DWORD, LPDIRECTDRAWSURFACE4) PURE; + /*** Added in the v2 interface ***/ + STDMETHOD(GetDDInterface)(THIS_ LPVOID FAR *) PURE; + STDMETHOD(PageLock)(THIS_ DWORD) PURE; + STDMETHOD(PageUnlock)(THIS_ DWORD) PURE; + /*** Added in the v3 interface ***/ + STDMETHOD(SetSurfaceDesc)(THIS_ LPDDSURFACEDESC2, DWORD) PURE; + /*** Added in the v4 interface ***/ + STDMETHOD(SetPrivateData)(THIS_ REFGUID, LPVOID, DWORD, DWORD) PURE; + STDMETHOD(GetPrivateData)(THIS_ REFGUID, LPVOID, LPDWORD) PURE; + STDMETHOD(FreePrivateData)(THIS_ REFGUID) PURE; + STDMETHOD(GetUniquenessValue)(THIS_ LPDWORD) PURE; + STDMETHOD(ChangeUniquenessValue)(THIS) PURE; +}; + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectDrawSurface4_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) +#define IDirectDrawSurface4_AddRef(p) (p)->lpVtbl->AddRef(p) +#define IDirectDrawSurface4_Release(p) (p)->lpVtbl->Release(p) +#define IDirectDrawSurface4_AddAttachedSurface(p,a) (p)->lpVtbl->AddAttachedSurface(p,a) +#define IDirectDrawSurface4_AddOverlayDirtyRect(p,a) (p)->lpVtbl->AddOverlayDirtyRect(p,a) +#define IDirectDrawSurface4_Blt(p,a,b,c,d,e) (p)->lpVtbl->Blt(p,a,b,c,d,e) +#define IDirectDrawSurface4_BltBatch(p,a,b,c) (p)->lpVtbl->BltBatch(p,a,b,c) +#define IDirectDrawSurface4_BltFast(p,a,b,c,d,e) (p)->lpVtbl->BltFast(p,a,b,c,d,e) +#define IDirectDrawSurface4_DeleteAttachedSurface(p,a,b) (p)->lpVtbl->DeleteAttachedSurface(p,a,b) +#define IDirectDrawSurface4_EnumAttachedSurfaces(p,a,b) (p)->lpVtbl->EnumAttachedSurfaces(p,a,b) +#define IDirectDrawSurface4_EnumOverlayZOrders(p,a,b,c) (p)->lpVtbl->EnumOverlayZOrders(p,a,b,c) +#define IDirectDrawSurface4_Flip(p,a,b) (p)->lpVtbl->Flip(p,a,b) +#define IDirectDrawSurface4_GetAttachedSurface(p,a,b) (p)->lpVtbl->GetAttachedSurface(p,a,b) +#define IDirectDrawSurface4_GetBltStatus(p,a) (p)->lpVtbl->GetBltStatus(p,a) +#define IDirectDrawSurface4_GetCaps(p,b) (p)->lpVtbl->GetCaps(p,b) +#define IDirectDrawSurface4_GetClipper(p,a) (p)->lpVtbl->GetClipper(p,a) +#define IDirectDrawSurface4_GetColorKey(p,a,b) (p)->lpVtbl->GetColorKey(p,a,b) +#define IDirectDrawSurface4_GetDC(p,a) (p)->lpVtbl->GetDC(p,a) +#define IDirectDrawSurface4_GetFlipStatus(p,a) (p)->lpVtbl->GetFlipStatus(p,a) +#define IDirectDrawSurface4_GetOverlayPosition(p,a,b) (p)->lpVtbl->GetOverlayPosition(p,a,b) +#define IDirectDrawSurface4_GetPalette(p,a) (p)->lpVtbl->GetPalette(p,a) +#define IDirectDrawSurface4_GetPixelFormat(p,a) (p)->lpVtbl->GetPixelFormat(p,a) +#define IDirectDrawSurface4_GetSurfaceDesc(p,a) (p)->lpVtbl->GetSurfaceDesc(p,a) +#define IDirectDrawSurface4_Initialize(p,a,b) (p)->lpVtbl->Initialize(p,a,b) +#define IDirectDrawSurface4_IsLost(p) (p)->lpVtbl->IsLost(p) +#define IDirectDrawSurface4_Lock(p,a,b,c,d) (p)->lpVtbl->Lock(p,a,b,c,d) +#define IDirectDrawSurface4_ReleaseDC(p,a) (p)->lpVtbl->ReleaseDC(p,a) +#define IDirectDrawSurface4_Restore(p) (p)->lpVtbl->Restore(p) +#define IDirectDrawSurface4_SetClipper(p,a) (p)->lpVtbl->SetClipper(p,a) +#define IDirectDrawSurface4_SetColorKey(p,a,b) (p)->lpVtbl->SetColorKey(p,a,b) +#define IDirectDrawSurface4_SetOverlayPosition(p,a,b) (p)->lpVtbl->SetOverlayPosition(p,a,b) +#define IDirectDrawSurface4_SetPalette(p,a) (p)->lpVtbl->SetPalette(p,a) +#define IDirectDrawSurface4_Unlock(p,b) (p)->lpVtbl->Unlock(p,b) +#define IDirectDrawSurface4_UpdateOverlay(p,a,b,c,d,e) (p)->lpVtbl->UpdateOverlay(p,a,b,c,d,e) +#define IDirectDrawSurface4_UpdateOverlayDisplay(p,a) (p)->lpVtbl->UpdateOverlayDisplay(p,a) +#define IDirectDrawSurface4_UpdateOverlayZOrder(p,a,b) (p)->lpVtbl->UpdateOverlayZOrder(p,a,b) +#define IDirectDrawSurface4_GetDDInterface(p,a) (p)->lpVtbl->GetDDInterface(p,a) +#define IDirectDrawSurface4_PageLock(p,a) (p)->lpVtbl->PageLock(p,a) +#define IDirectDrawSurface4_PageUnlock(p,a) (p)->lpVtbl->PageUnlock(p,a) +#define IDirectDrawSurface4_SetSurfaceDesc(p,a,b) (p)->lpVtbl->SetSurfaceDesc(p,a,b) +#define IDirectDrawSurface4_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d) +#define IDirectDrawSurface4_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c) +#define IDirectDrawSurface4_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a) +#define IDirectDrawSurface4_GetUniquenessValue(p, a) (p)->lpVtbl->GetUniquenessValue(p, a) +#define IDirectDrawSurface4_ChangeUniquenessValue(p) (p)->lpVtbl->ChangeUniquenessValue(p) +#else +#define IDirectDrawSurface4_QueryInterface(p,a,b) (p)->QueryInterface(a,b) +#define IDirectDrawSurface4_AddRef(p) (p)->AddRef() +#define IDirectDrawSurface4_Release(p) (p)->Release() +#define IDirectDrawSurface4_AddAttachedSurface(p,a) (p)->AddAttachedSurface(a) +#define IDirectDrawSurface4_AddOverlayDirtyRect(p,a) (p)->AddOverlayDirtyRect(a) +#define IDirectDrawSurface4_Blt(p,a,b,c,d,e) (p)->Blt(a,b,c,d,e) +#define IDirectDrawSurface4_BltBatch(p,a,b,c) (p)->BltBatch(a,b,c) +#define IDirectDrawSurface4_BltFast(p,a,b,c,d,e) (p)->BltFast(a,b,c,d,e) +#define IDirectDrawSurface4_DeleteAttachedSurface(p,a,b) (p)->DeleteAttachedSurface(a,b) +#define IDirectDrawSurface4_EnumAttachedSurfaces(p,a,b) (p)->EnumAttachedSurfaces(a,b) +#define IDirectDrawSurface4_EnumOverlayZOrders(p,a,b,c) (p)->EnumOverlayZOrders(a,b,c) +#define IDirectDrawSurface4_Flip(p,a,b) (p)->Flip(a,b) +#define IDirectDrawSurface4_GetAttachedSurface(p,a,b) (p)->GetAttachedSurface(a,b) +#define IDirectDrawSurface4_GetBltStatus(p,a) (p)->GetBltStatus(a) +#define IDirectDrawSurface4_GetCaps(p,b) (p)->GetCaps(b) +#define IDirectDrawSurface4_GetClipper(p,a) (p)->GetClipper(a) +#define IDirectDrawSurface4_GetColorKey(p,a,b) (p)->GetColorKey(a,b) +#define IDirectDrawSurface4_GetDC(p,a) (p)->GetDC(a) +#define IDirectDrawSurface4_GetFlipStatus(p,a) (p)->GetFlipStatus(a) +#define IDirectDrawSurface4_GetOverlayPosition(p,a,b) (p)->GetOverlayPosition(a,b) +#define IDirectDrawSurface4_GetPalette(p,a) (p)->GetPalette(a) +#define IDirectDrawSurface4_GetPixelFormat(p,a) (p)->GetPixelFormat(a) +#define IDirectDrawSurface4_GetSurfaceDesc(p,a) (p)->GetSurfaceDesc(a) +#define IDirectDrawSurface4_Initialize(p,a,b) (p)->Initialize(a,b) +#define IDirectDrawSurface4_IsLost(p) (p)->IsLost() +#define IDirectDrawSurface4_Lock(p,a,b,c,d) (p)->Lock(a,b,c,d) +#define IDirectDrawSurface4_ReleaseDC(p,a) (p)->ReleaseDC(a) +#define IDirectDrawSurface4_Restore(p) (p)->Restore() +#define IDirectDrawSurface4_SetClipper(p,a) (p)->SetClipper(a) +#define IDirectDrawSurface4_SetColorKey(p,a,b) (p)->SetColorKey(a,b) +#define IDirectDrawSurface4_SetOverlayPosition(p,a,b) (p)->SetOverlayPosition(a,b) +#define IDirectDrawSurface4_SetPalette(p,a) (p)->SetPalette(a) +#define IDirectDrawSurface4_Unlock(p,b) (p)->Unlock(b) +#define IDirectDrawSurface4_UpdateOverlay(p,a,b,c,d,e) (p)->UpdateOverlay(a,b,c,d,e) +#define IDirectDrawSurface4_UpdateOverlayDisplay(p,a) (p)->UpdateOverlayDisplay(a) +#define IDirectDrawSurface4_UpdateOverlayZOrder(p,a,b) (p)->UpdateOverlayZOrder(a,b) +#define IDirectDrawSurface4_GetDDInterface(p,a) (p)->GetDDInterface(a) +#define IDirectDrawSurface4_PageLock(p,a) (p)->PageLock(a) +#define IDirectDrawSurface4_PageUnlock(p,a) (p)->PageUnlock(a) +#define IDirectDrawSurface4_SetSurfaceDesc(p,a,b) (p)->SetSurfaceDesc(a,b) +#define IDirectDrawSurface4_SetPrivateData(p,a,b,c,d) (p)->SetPrivateData(a,b,c,d) +#define IDirectDrawSurface4_GetPrivateData(p,a,b,c) (p)->GetPrivateData(a,b,c) +#define IDirectDrawSurface4_FreePrivateData(p,a) (p)->FreePrivateData(a) +#define IDirectDrawSurface4_GetUniquenessValue(p, a) (p)->GetUniquenessValue(a) +#define IDirectDrawSurface4_ChangeUniquenessValue(p) (p)->ChangeUniquenessValue() +#endif + +/* + * IDirectDrawSurface7 and related interfaces + */ +#undef INTERFACE +#define INTERFACE IDirectDrawSurface7 +DECLARE_INTERFACE_( IDirectDrawSurface7, IUnknown ) +{ + /*** IUnknown methods ***/ + STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID FAR * ppvObj) PURE; + STDMETHOD_(ULONG,AddRef) (THIS) PURE; + STDMETHOD_(ULONG,Release) (THIS) PURE; + /*** IDirectDrawSurface methods ***/ + STDMETHOD(AddAttachedSurface)(THIS_ LPDIRECTDRAWSURFACE7) PURE; + STDMETHOD(AddOverlayDirtyRect)(THIS_ LPRECT) PURE; + STDMETHOD(Blt)(THIS_ LPRECT,LPDIRECTDRAWSURFACE7, LPRECT,DWORD, LPDDBLTFX) PURE; + STDMETHOD(BltBatch)(THIS_ LPDDBLTBATCH, DWORD, DWORD ) PURE; + STDMETHOD(BltFast)(THIS_ DWORD,DWORD,LPDIRECTDRAWSURFACE7, LPRECT,DWORD) PURE; + STDMETHOD(DeleteAttachedSurface)(THIS_ DWORD,LPDIRECTDRAWSURFACE7) PURE; + STDMETHOD(EnumAttachedSurfaces)(THIS_ LPVOID,LPDDENUMSURFACESCALLBACK7) PURE; + STDMETHOD(EnumOverlayZOrders)(THIS_ DWORD,LPVOID,LPDDENUMSURFACESCALLBACK7) PURE; + STDMETHOD(Flip)(THIS_ LPDIRECTDRAWSURFACE7, DWORD) PURE; + STDMETHOD(GetAttachedSurface)(THIS_ LPDDSCAPS2, LPDIRECTDRAWSURFACE7 FAR *) PURE; + STDMETHOD(GetBltStatus)(THIS_ DWORD) PURE; + STDMETHOD(GetCaps)(THIS_ LPDDSCAPS2) PURE; + STDMETHOD(GetClipper)(THIS_ LPDIRECTDRAWCLIPPER FAR*) PURE; + STDMETHOD(GetColorKey)(THIS_ DWORD, LPDDCOLORKEY) PURE; + STDMETHOD(GetDC)(THIS_ HDC FAR *) PURE; + STDMETHOD(GetFlipStatus)(THIS_ DWORD) PURE; + STDMETHOD(GetOverlayPosition)(THIS_ LPLONG, LPLONG ) PURE; + STDMETHOD(GetPalette)(THIS_ LPDIRECTDRAWPALETTE FAR*) PURE; + STDMETHOD(GetPixelFormat)(THIS_ LPDDPIXELFORMAT) PURE; + STDMETHOD(GetSurfaceDesc)(THIS_ LPDDSURFACEDESC2) PURE; + STDMETHOD(Initialize)(THIS_ LPDIRECTDRAW, LPDDSURFACEDESC2) PURE; + STDMETHOD(IsLost)(THIS) PURE; + STDMETHOD(Lock)(THIS_ LPRECT,LPDDSURFACEDESC2,DWORD,HANDLE) PURE; + STDMETHOD(ReleaseDC)(THIS_ HDC) PURE; + STDMETHOD(Restore)(THIS) PURE; + STDMETHOD(SetClipper)(THIS_ LPDIRECTDRAWCLIPPER) PURE; + STDMETHOD(SetColorKey)(THIS_ DWORD, LPDDCOLORKEY) PURE; + STDMETHOD(SetOverlayPosition)(THIS_ LONG, LONG ) PURE; + STDMETHOD(SetPalette)(THIS_ LPDIRECTDRAWPALETTE) PURE; + STDMETHOD(Unlock)(THIS_ LPRECT) PURE; + STDMETHOD(UpdateOverlay)(THIS_ LPRECT, LPDIRECTDRAWSURFACE7,LPRECT,DWORD, LPDDOVERLAYFX) PURE; + STDMETHOD(UpdateOverlayDisplay)(THIS_ DWORD) PURE; + STDMETHOD(UpdateOverlayZOrder)(THIS_ DWORD, LPDIRECTDRAWSURFACE7) PURE; + /*** Added in the v2 interface ***/ + STDMETHOD(GetDDInterface)(THIS_ LPVOID FAR *) PURE; + STDMETHOD(PageLock)(THIS_ DWORD) PURE; + STDMETHOD(PageUnlock)(THIS_ DWORD) PURE; + /*** Added in the v3 interface ***/ + STDMETHOD(SetSurfaceDesc)(THIS_ LPDDSURFACEDESC2, DWORD) PURE; + /*** Added in the v4 interface ***/ + STDMETHOD(SetPrivateData)(THIS_ REFGUID, LPVOID, DWORD, DWORD) PURE; + STDMETHOD(GetPrivateData)(THIS_ REFGUID, LPVOID, LPDWORD) PURE; + STDMETHOD(FreePrivateData)(THIS_ REFGUID) PURE; + STDMETHOD(GetUniquenessValue)(THIS_ LPDWORD) PURE; + STDMETHOD(ChangeUniquenessValue)(THIS) PURE; + /*** Moved Texture7 methods here ***/ + STDMETHOD(SetPriority)(THIS_ DWORD) PURE; + STDMETHOD(GetPriority)(THIS_ LPDWORD) PURE; + STDMETHOD(SetLOD)(THIS_ DWORD) PURE; + STDMETHOD(GetLOD)(THIS_ LPDWORD) PURE; +}; + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectDrawSurface7_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) +#define IDirectDrawSurface7_AddRef(p) (p)->lpVtbl->AddRef(p) +#define IDirectDrawSurface7_Release(p) (p)->lpVtbl->Release(p) +#define IDirectDrawSurface7_AddAttachedSurface(p,a) (p)->lpVtbl->AddAttachedSurface(p,a) +#define IDirectDrawSurface7_AddOverlayDirtyRect(p,a) (p)->lpVtbl->AddOverlayDirtyRect(p,a) +#define IDirectDrawSurface7_Blt(p,a,b,c,d,e) (p)->lpVtbl->Blt(p,a,b,c,d,e) +#define IDirectDrawSurface7_BltBatch(p,a,b,c) (p)->lpVtbl->BltBatch(p,a,b,c) +#define IDirectDrawSurface7_BltFast(p,a,b,c,d,e) (p)->lpVtbl->BltFast(p,a,b,c,d,e) +#define IDirectDrawSurface7_DeleteAttachedSurface(p,a,b) (p)->lpVtbl->DeleteAttachedSurface(p,a,b) +#define IDirectDrawSurface7_EnumAttachedSurfaces(p,a,b) (p)->lpVtbl->EnumAttachedSurfaces(p,a,b) +#define IDirectDrawSurface7_EnumOverlayZOrders(p,a,b,c) (p)->lpVtbl->EnumOverlayZOrders(p,a,b,c) +#define IDirectDrawSurface7_Flip(p,a,b) (p)->lpVtbl->Flip(p,a,b) +#define IDirectDrawSurface7_GetAttachedSurface(p,a,b) (p)->lpVtbl->GetAttachedSurface(p,a,b) +#define IDirectDrawSurface7_GetBltStatus(p,a) (p)->lpVtbl->GetBltStatus(p,a) +#define IDirectDrawSurface7_GetCaps(p,b) (p)->lpVtbl->GetCaps(p,b) +#define IDirectDrawSurface7_GetClipper(p,a) (p)->lpVtbl->GetClipper(p,a) +#define IDirectDrawSurface7_GetColorKey(p,a,b) (p)->lpVtbl->GetColorKey(p,a,b) +#define IDirectDrawSurface7_GetDC(p,a) (p)->lpVtbl->GetDC(p,a) +#define IDirectDrawSurface7_GetFlipStatus(p,a) (p)->lpVtbl->GetFlipStatus(p,a) +#define IDirectDrawSurface7_GetOverlayPosition(p,a,b) (p)->lpVtbl->GetOverlayPosition(p,a,b) +#define IDirectDrawSurface7_GetPalette(p,a) (p)->lpVtbl->GetPalette(p,a) +#define IDirectDrawSurface7_GetPixelFormat(p,a) (p)->lpVtbl->GetPixelFormat(p,a) +#define IDirectDrawSurface7_GetSurfaceDesc(p,a) (p)->lpVtbl->GetSurfaceDesc(p,a) +#define IDirectDrawSurface7_Initialize(p,a,b) (p)->lpVtbl->Initialize(p,a,b) +#define IDirectDrawSurface7_IsLost(p) (p)->lpVtbl->IsLost(p) +#define IDirectDrawSurface7_Lock(p,a,b,c,d) (p)->lpVtbl->Lock(p,a,b,c,d) +#define IDirectDrawSurface7_ReleaseDC(p,a) (p)->lpVtbl->ReleaseDC(p,a) +#define IDirectDrawSurface7_Restore(p) (p)->lpVtbl->Restore(p) +#define IDirectDrawSurface7_SetClipper(p,a) (p)->lpVtbl->SetClipper(p,a) +#define IDirectDrawSurface7_SetColorKey(p,a,b) (p)->lpVtbl->SetColorKey(p,a,b) +#define IDirectDrawSurface7_SetOverlayPosition(p,a,b) (p)->lpVtbl->SetOverlayPosition(p,a,b) +#define IDirectDrawSurface7_SetPalette(p,a) (p)->lpVtbl->SetPalette(p,a) +#define IDirectDrawSurface7_Unlock(p,b) (p)->lpVtbl->Unlock(p,b) +#define IDirectDrawSurface7_UpdateOverlay(p,a,b,c,d,e) (p)->lpVtbl->UpdateOverlay(p,a,b,c,d,e) +#define IDirectDrawSurface7_UpdateOverlayDisplay(p,a) (p)->lpVtbl->UpdateOverlayDisplay(p,a) +#define IDirectDrawSurface7_UpdateOverlayZOrder(p,a,b) (p)->lpVtbl->UpdateOverlayZOrder(p,a,b) +#define IDirectDrawSurface7_GetDDInterface(p,a) (p)->lpVtbl->GetDDInterface(p,a) +#define IDirectDrawSurface7_PageLock(p,a) (p)->lpVtbl->PageLock(p,a) +#define IDirectDrawSurface7_PageUnlock(p,a) (p)->lpVtbl->PageUnlock(p,a) +#define IDirectDrawSurface7_SetSurfaceDesc(p,a,b) (p)->lpVtbl->SetSurfaceDesc(p,a,b) +#define IDirectDrawSurface7_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d) +#define IDirectDrawSurface7_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c) +#define IDirectDrawSurface7_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a) +#define IDirectDrawSurface7_GetUniquenessValue(p, a) (p)->lpVtbl->GetUniquenessValue(p, a) +#define IDirectDrawSurface7_ChangeUniquenessValue(p) (p)->lpVtbl->ChangeUniquenessValue(p) +#define IDirectDrawSurface7_SetPriority(p,a) (p)->lpVtbl->SetPriority(p,a) +#define IDirectDrawSurface7_GetPriority(p,a) (p)->lpVtbl->GetPriority(p,a) +#define IDirectDrawSurface7_SetLOD(p,a) (p)->lpVtbl->SetLOD(p,a) +#define IDirectDrawSurface7_GetLOD(p,a) (p)->lpVtbl->GetLOD(p,a) +#else +#define IDirectDrawSurface7_QueryInterface(p,a,b) (p)->QueryInterface(a,b) +#define IDirectDrawSurface7_AddRef(p) (p)->AddRef() +#define IDirectDrawSurface7_Release(p) (p)->Release() +#define IDirectDrawSurface7_AddAttachedSurface(p,a) (p)->AddAttachedSurface(a) +#define IDirectDrawSurface7_AddOverlayDirtyRect(p,a) (p)->AddOverlayDirtyRect(a) +#define IDirectDrawSurface7_Blt(p,a,b,c,d,e) (p)->Blt(a,b,c,d,e) +#define IDirectDrawSurface7_BltBatch(p,a,b,c) (p)->BltBatch(a,b,c) +#define IDirectDrawSurface7_BltFast(p,a,b,c,d,e) (p)->BltFast(a,b,c,d,e) +#define IDirectDrawSurface7_DeleteAttachedSurface(p,a,b) (p)->DeleteAttachedSurface(a,b) +#define IDirectDrawSurface7_EnumAttachedSurfaces(p,a,b) (p)->EnumAttachedSurfaces(a,b) +#define IDirectDrawSurface7_EnumOverlayZOrders(p,a,b,c) (p)->EnumOverlayZOrders(a,b,c) +#define IDirectDrawSurface7_Flip(p,a,b) (p)->Flip(a,b) +#define IDirectDrawSurface7_GetAttachedSurface(p,a,b) (p)->GetAttachedSurface(a,b) +#define IDirectDrawSurface7_GetBltStatus(p,a) (p)->GetBltStatus(a) +#define IDirectDrawSurface7_GetCaps(p,b) (p)->GetCaps(b) +#define IDirectDrawSurface7_GetClipper(p,a) (p)->GetClipper(a) +#define IDirectDrawSurface7_GetColorKey(p,a,b) (p)->GetColorKey(a,b) +#define IDirectDrawSurface7_GetDC(p,a) (p)->GetDC(a) +#define IDirectDrawSurface7_GetFlipStatus(p,a) (p)->GetFlipStatus(a) +#define IDirectDrawSurface7_GetOverlayPosition(p,a,b) (p)->GetOverlayPosition(a,b) +#define IDirectDrawSurface7_GetPalette(p,a) (p)->GetPalette(a) +#define IDirectDrawSurface7_GetPixelFormat(p,a) (p)->GetPixelFormat(a) +#define IDirectDrawSurface7_GetSurfaceDesc(p,a) (p)->GetSurfaceDesc(a) +#define IDirectDrawSurface7_Initialize(p,a,b) (p)->Initialize(a,b) +#define IDirectDrawSurface7_IsLost(p) (p)->IsLost() +#define IDirectDrawSurface7_Lock(p,a,b,c,d) (p)->Lock(a,b,c,d) +#define IDirectDrawSurface7_ReleaseDC(p,a) (p)->ReleaseDC(a) +#define IDirectDrawSurface7_Restore(p) (p)->Restore() +#define IDirectDrawSurface7_SetClipper(p,a) (p)->SetClipper(a) +#define IDirectDrawSurface7_SetColorKey(p,a,b) (p)->SetColorKey(a,b) +#define IDirectDrawSurface7_SetOverlayPosition(p,a,b) (p)->SetOverlayPosition(a,b) +#define IDirectDrawSurface7_SetPalette(p,a) (p)->SetPalette(a) +#define IDirectDrawSurface7_Unlock(p,b) (p)->Unlock(b) +#define IDirectDrawSurface7_UpdateOverlay(p,a,b,c,d,e) (p)->UpdateOverlay(a,b,c,d,e) +#define IDirectDrawSurface7_UpdateOverlayDisplay(p,a) (p)->UpdateOverlayDisplay(a) +#define IDirectDrawSurface7_UpdateOverlayZOrder(p,a,b) (p)->UpdateOverlayZOrder(a,b) +#define IDirectDrawSurface7_GetDDInterface(p,a) (p)->GetDDInterface(a) +#define IDirectDrawSurface7_PageLock(p,a) (p)->PageLock(a) +#define IDirectDrawSurface7_PageUnlock(p,a) (p)->PageUnlock(a) +#define IDirectDrawSurface7_SetSurfaceDesc(p,a,b) (p)->SetSurfaceDesc(a,b) +#define IDirectDrawSurface7_SetPrivateData(p,a,b,c,d) (p)->SetPrivateData(a,b,c,d) +#define IDirectDrawSurface7_GetPrivateData(p,a,b,c) (p)->GetPrivateData(a,b,c) +#define IDirectDrawSurface7_FreePrivateData(p,a) (p)->FreePrivateData(a) +#define IDirectDrawSurface7_GetUniquenessValue(p, a) (p)->GetUniquenessValue(a) +#define IDirectDrawSurface7_ChangeUniquenessValue(p) (p)->ChangeUniquenessValue() +#define IDirectDrawSurface7_SetPriority(p,a) (p)->SetPriority(a) +#define IDirectDrawSurface7_GetPriority(p,a) (p)->GetPriority(a) +#define IDirectDrawSurface7_SetLOD(p,a) (p)->SetLOD(a) +#define IDirectDrawSurface7_GetLOD(p,a) (p)->GetLOD(a) +#endif + + +/* + * IDirectDrawColorControl + */ +#if defined( _WIN32 ) && !defined( _NO_COM ) +#undef INTERFACE +#define INTERFACE IDirectDrawColorControl +DECLARE_INTERFACE_( IDirectDrawColorControl, IUnknown ) +{ + /*** IUnknown methods ***/ + STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID FAR * ppvObj) PURE; + STDMETHOD_(ULONG,AddRef) (THIS) PURE; + STDMETHOD_(ULONG,Release) (THIS) PURE; + /*** IDirectDrawColorControl methods ***/ + STDMETHOD(GetColorControls)(THIS_ LPDDCOLORCONTROL) PURE; + STDMETHOD(SetColorControls)(THIS_ LPDDCOLORCONTROL) PURE; +}; + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectDrawColorControl_QueryInterface(p, a, b) (p)->lpVtbl->QueryInterface(p, a, b) +#define IDirectDrawColorControl_AddRef(p) (p)->lpVtbl->AddRef(p) +#define IDirectDrawColorControl_Release(p) (p)->lpVtbl->Release(p) +#define IDirectDrawColorControl_GetColorControls(p, a) (p)->lpVtbl->GetColorControls(p, a) +#define IDirectDrawColorControl_SetColorControls(p, a) (p)->lpVtbl->SetColorControls(p, a) +#else +#define IDirectDrawColorControl_QueryInterface(p, a, b) (p)->QueryInterface(a, b) +#define IDirectDrawColorControl_AddRef(p) (p)->AddRef() +#define IDirectDrawColorControl_Release(p) (p)->Release() +#define IDirectDrawColorControl_GetColorControls(p, a) (p)->GetColorControls(a) +#define IDirectDrawColorControl_SetColorControls(p, a) (p)->SetColorControls(a) +#endif + +#endif + + +/* + * IDirectDrawGammaControl + */ +#if defined( _WIN32 ) && !defined( _NO_COM ) +#undef INTERFACE +#define INTERFACE IDirectDrawGammaControl +DECLARE_INTERFACE_( IDirectDrawGammaControl, IUnknown ) +{ + /*** IUnknown methods ***/ + STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID FAR * ppvObj) PURE; + STDMETHOD_(ULONG,AddRef) (THIS) PURE; + STDMETHOD_(ULONG,Release) (THIS) PURE; + /*** IDirectDrawGammaControl methods ***/ + STDMETHOD(GetGammaRamp)(THIS_ DWORD, LPDDGAMMARAMP) PURE; + STDMETHOD(SetGammaRamp)(THIS_ DWORD, LPDDGAMMARAMP) PURE; +}; + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectDrawGammaControl_QueryInterface(p, a, b) (p)->lpVtbl->QueryInterface(p, a, b) +#define IDirectDrawGammaControl_AddRef(p) (p)->lpVtbl->AddRef(p) +#define IDirectDrawGammaControl_Release(p) (p)->lpVtbl->Release(p) +#define IDirectDrawGammaControl_GetGammaRamp(p, a, b) (p)->lpVtbl->GetGammaRamp(p, a, b) +#define IDirectDrawGammaControl_SetGammaRamp(p, a, b) (p)->lpVtbl->SetGammaRamp(p, a, b) +#else +#define IDirectDrawGammaControl_QueryInterface(p, a, b) (p)->QueryInterface(a, b) +#define IDirectDrawGammaControl_AddRef(p) (p)->AddRef() +#define IDirectDrawGammaControl_Release(p) (p)->Release() +#define IDirectDrawGammaControl_GetGammaRamp(p, a, b) (p)->GetGammaRamp(a, b) +#define IDirectDrawGammaControl_SetGammaRamp(p, a, b) (p)->SetGammaRamp(a, b) +#endif + +#endif + + + +#endif + + +/* + * DDSURFACEDESC + */ +typedef struct _DDSURFACEDESC +{ + DWORD dwSize; // size of the DDSURFACEDESC structure + DWORD dwFlags; // determines what fields are valid + DWORD dwHeight; // height of surface to be created + DWORD dwWidth; // width of input surface + union + { + LONG lPitch; // distance to start of next line (return value only) + DWORD dwLinearSize; // Formless late-allocated optimized surface size + } DUMMYUNIONNAMEN(1); + DWORD dwBackBufferCount; // number of back buffers requested + union + { + DWORD dwMipMapCount; // number of mip-map levels requested + DWORD dwZBufferBitDepth; // depth of Z buffer requested + DWORD dwRefreshRate; // refresh rate (used when display mode is described) + } DUMMYUNIONNAMEN(2); + DWORD dwAlphaBitDepth; // depth of alpha buffer requested + DWORD dwReserved; // reserved + LPVOID lpSurface; // pointer to the associated surface memory + DDCOLORKEY ddckCKDestOverlay; // color key for destination overlay use + DDCOLORKEY ddckCKDestBlt; // color key for destination blt use + DDCOLORKEY ddckCKSrcOverlay; // color key for source overlay use + DDCOLORKEY ddckCKSrcBlt; // color key for source blt use + DDPIXELFORMAT ddpfPixelFormat; // pixel format description of the surface + DDSCAPS ddsCaps; // direct draw surface capabilities +} DDSURFACEDESC; + +/* + * DDSURFACEDESC2 + */ +typedef struct _DDSURFACEDESC2 +{ + DWORD dwSize; // size of the DDSURFACEDESC structure + DWORD dwFlags; // determines what fields are valid + DWORD dwHeight; // height of surface to be created + DWORD dwWidth; // width of input surface + union + { + LONG lPitch; // distance to start of next line (return value only) + DWORD dwLinearSize; // Formless late-allocated optimized surface size + } DUMMYUNIONNAMEN(1); + union + { + DWORD dwBackBufferCount; // number of back buffers requested + DWORD dwDepth; // the depth if this is a volume texture + } DUMMYUNIONNAMEN(5); + union + { + DWORD dwMipMapCount; // number of mip-map levels requestde + // dwZBufferBitDepth removed, use ddpfPixelFormat one instead + DWORD dwRefreshRate; // refresh rate (used when display mode is described) + DWORD dwSrcVBHandle; // The source used in VB::Optimize + } DUMMYUNIONNAMEN(2); + DWORD dwAlphaBitDepth; // depth of alpha buffer requested + DWORD dwReserved; // reserved + LPVOID lpSurface; // pointer to the associated surface memory + union + { + DDCOLORKEY ddckCKDestOverlay; // color key for destination overlay use + DWORD dwEmptyFaceColor; // Physical color for empty cubemap faces + } DUMMYUNIONNAMEN(3); + DDCOLORKEY ddckCKDestBlt; // color key for destination blt use + DDCOLORKEY ddckCKSrcOverlay; // color key for source overlay use + DDCOLORKEY ddckCKSrcBlt; // color key for source blt use + union + { + DDPIXELFORMAT ddpfPixelFormat; // pixel format description of the surface + DWORD dwFVF; // vertex format description of vertex buffers + } DUMMYUNIONNAMEN(4); + DDSCAPS2 ddsCaps; // direct draw surface capabilities + DWORD dwTextureStage; // stage in multitexture cascade +} DDSURFACEDESC2; + +/* + * ddsCaps field is valid. + */ +#define DDSD_CAPS 0x00000001l // default + +/* + * dwHeight field is valid. + */ +#define DDSD_HEIGHT 0x00000002l + +/* + * dwWidth field is valid. + */ +#define DDSD_WIDTH 0x00000004l + +/* + * lPitch is valid. + */ +#define DDSD_PITCH 0x00000008l + +/* + * dwBackBufferCount is valid. + */ +#define DDSD_BACKBUFFERCOUNT 0x00000020l + +/* + * dwZBufferBitDepth is valid. (shouldnt be used in DDSURFACEDESC2) + */ +#define DDSD_ZBUFFERBITDEPTH 0x00000040l + +/* + * dwAlphaBitDepth is valid. + */ +#define DDSD_ALPHABITDEPTH 0x00000080l + + +/* + * lpSurface is valid. + */ +#define DDSD_LPSURFACE 0x00000800l + +/* + * ddpfPixelFormat is valid. + */ +#define DDSD_PIXELFORMAT 0x00001000l + +/* + * ddckCKDestOverlay is valid. + */ +#define DDSD_CKDESTOVERLAY 0x00002000l + +/* + * ddckCKDestBlt is valid. + */ +#define DDSD_CKDESTBLT 0x00004000l + +/* + * ddckCKSrcOverlay is valid. + */ +#define DDSD_CKSRCOVERLAY 0x00008000l + +/* + * ddckCKSrcBlt is valid. + */ +#define DDSD_CKSRCBLT 0x00010000l + +/* + * dwMipMapCount is valid. + */ +#define DDSD_MIPMAPCOUNT 0x00020000l + + /* + * dwRefreshRate is valid + */ +#define DDSD_REFRESHRATE 0x00040000l + +/* + * dwLinearSize is valid + */ +#define DDSD_LINEARSIZE 0x00080000l + +/* + * dwTextureStage is valid + */ +#define DDSD_TEXTURESTAGE 0x00100000l +/* + * dwFVF is valid + */ +#define DDSD_FVF 0x00200000l +/* + * dwSrcVBHandle is valid + */ +#define DDSD_SRCVBHANDLE 0x00400000l + +/* + * dwDepth is valid + */ +#define DDSD_DEPTH 0x00800000l + +/* + * All input fields are valid. + */ +#define DDSD_ALL 0x00fff9eel + +/* + * DDOPTSURFACEDESC + */ +typedef struct _DDOPTSURFACEDESC +{ + DWORD dwSize; // size of the DDOPTSURFACEDESC structure + DWORD dwFlags; // determines what fields are valid + DDSCAPS2 ddSCaps; // Common caps like: Memory type + DDOSCAPS ddOSCaps; // Common caps like: Memory type + GUID guid; // Compression technique GUID + DWORD dwCompressionRatio; // Compression ratio +} DDOPTSURFACEDESC; + +/* + * guid field is valid. + */ +#define DDOSD_GUID 0x00000001l + +/* + * dwCompressionRatio field is valid. + */ +#define DDOSD_COMPRESSION_RATIO 0x00000002l + +/* + * ddSCaps field is valid. + */ +#define DDOSD_SCAPS 0x00000004l + +/* + * ddOSCaps field is valid. + */ +#define DDOSD_OSCAPS 0x00000008l + +/* + * All input fields are valid. + */ +#define DDOSD_ALL 0x0000000fl + +/* + * The surface's optimized pixelformat is compressed + */ +#define DDOSDCAPS_OPTCOMPRESSED 0x00000001l + +/* + * The surface's optimized pixelformat is reordered + */ +#define DDOSDCAPS_OPTREORDERED 0x00000002l + +/* + * The opt surface is a monolithic mipmap + */ +#define DDOSDCAPS_MONOLITHICMIPMAP 0x00000004l + +/* + * The valid Surf caps: + * #define DDSCAPS_SYSTEMMEMORY 0x00000800l + * #define DDSCAPS_VIDEOMEMORY 0x00004000l + * #define DDSCAPS_LOCALVIDMEM 0x10000000l + * #define DDSCAPS_NONLOCALVIDMEM 0x20000000l + */ +#define DDOSDCAPS_VALIDSCAPS 0x30004800l + +/* + * The valid OptSurf caps + */ +#define DDOSDCAPS_VALIDOSCAPS 0x00000007l + + +/* + * DDCOLORCONTROL + */ +typedef struct _DDCOLORCONTROL +{ + DWORD dwSize; + DWORD dwFlags; + LONG lBrightness; + LONG lContrast; + LONG lHue; + LONG lSaturation; + LONG lSharpness; + LONG lGamma; + LONG lColorEnable; + DWORD dwReserved1; +} DDCOLORCONTROL; + + +/* + * lBrightness field is valid. + */ +#define DDCOLOR_BRIGHTNESS 0x00000001l + +/* + * lContrast field is valid. + */ +#define DDCOLOR_CONTRAST 0x00000002l + +/* + * lHue field is valid. + */ +#define DDCOLOR_HUE 0x00000004l + +/* + * lSaturation field is valid. + */ +#define DDCOLOR_SATURATION 0x00000008l + +/* + * lSharpness field is valid. + */ +#define DDCOLOR_SHARPNESS 0x00000010l + +/* + * lGamma field is valid. + */ +#define DDCOLOR_GAMMA 0x00000020l + +/* + * lColorEnable field is valid. + */ +#define DDCOLOR_COLORENABLE 0x00000040l + + + +/*============================================================================ + * + * Direct Draw Capability Flags + * + * These flags are used to describe the capabilities of a given Surface. + * All flags are bit flags. + * + *==========================================================================*/ + +/**************************************************************************** + * + * DIRECTDRAWSURFACE CAPABILITY FLAGS + * + ****************************************************************************/ + +/* + * This bit is reserved. It should not be specified. + */ +#define DDSCAPS_RESERVED1 0x00000001l + +/* + * Indicates that this surface contains alpha-only information. + * (To determine if a surface is RGBA/YUVA, the pixel format must be + * interrogated.) + */ +#define DDSCAPS_ALPHA 0x00000002l + +/* + * Indicates that this surface is a backbuffer. It is generally + * set by CreateSurface when the DDSCAPS_FLIP capability bit is set. + * It indicates that this surface is THE back buffer of a surface + * flipping structure. DirectDraw supports N surfaces in a + * surface flipping structure. Only the surface that immediately + * precedeces the DDSCAPS_FRONTBUFFER has this capability bit set. + * The other surfaces are identified as back buffers by the presence + * of the DDSCAPS_FLIP capability, their attachment order, and the + * absence of the DDSCAPS_FRONTBUFFER and DDSCAPS_BACKBUFFER + * capabilities. The bit is sent to CreateSurface when a standalone + * back buffer is being created. This surface could be attached to + * a front buffer and/or back buffers to form a flipping surface + * structure after the CreateSurface call. See AddAttachments for + * a detailed description of the behaviors in this case. + */ +#define DDSCAPS_BACKBUFFER 0x00000004l + +/* + * Indicates a complex surface structure is being described. A + * complex surface structure results in the creation of more than + * one surface. The additional surfaces are attached to the root + * surface. The complex structure can only be destroyed by + * destroying the root. + */ +#define DDSCAPS_COMPLEX 0x00000008l + +/* + * Indicates that this surface is a part of a surface flipping structure. + * When it is passed to CreateSurface the DDSCAPS_FRONTBUFFER and + * DDSCAP_BACKBUFFER bits are not set. They are set by CreateSurface + * on the resulting creations. The dwBackBufferCount field in the + * DDSURFACEDESC structure must be set to at least 1 in order for + * the CreateSurface call to succeed. The DDSCAPS_COMPLEX capability + * must always be set with creating multiple surfaces through CreateSurface. + */ +#define DDSCAPS_FLIP 0x00000010l + +/* + * Indicates that this surface is THE front buffer of a surface flipping + * structure. It is generally set by CreateSurface when the DDSCAPS_FLIP + * capability bit is set. + * If this capability is sent to CreateSurface then a standalonw front buffer + * is created. This surface will not have the DDSCAPS_FLIP capability. + * It can be attached to other back buffers to form a flipping structure. + * See AddAttachments for a detailed description of the behaviors in this + * case. + */ +#define DDSCAPS_FRONTBUFFER 0x00000020l + +/* + * Indicates that this surface is any offscreen surface that is not an overlay, + * texture, zbuffer, front buffer, back buffer, or alpha surface. It is used + * to identify plain vanilla surfaces. + */ +#define DDSCAPS_OFFSCREENPLAIN 0x00000040l + +/* + * Indicates that this surface is an overlay. It may or may not be directly visible + * depending on whether or not it is currently being overlayed onto the primary + * surface. DDSCAPS_VISIBLE can be used to determine whether or not it is being + * overlayed at the moment. + */ +#define DDSCAPS_OVERLAY 0x00000080l + +/* + * Indicates that unique DirectDrawPalette objects can be created and + * attached to this surface. + */ +#define DDSCAPS_PALETTE 0x00000100l + +/* + * Indicates that this surface is the primary surface. The primary + * surface represents what the user is seeing at the moment. + */ +#define DDSCAPS_PRIMARYSURFACE 0x00000200l + + +/* + * This flag used to be DDSCAPS_PRIMARYSURFACELEFT, which is now + * obsolete. + */ +#define DDSCAPS_RESERVED3 0x00000400l +#define DDSCAPS_PRIMARYSURFACELEFT 0x00000000l + +/* + * Indicates that this surface memory was allocated in system memory + */ +#define DDSCAPS_SYSTEMMEMORY 0x00000800l + +/* + * Indicates that this surface can be used as a 3D texture. It does not + * indicate whether or not the surface is being used for that purpose. + */ +#define DDSCAPS_TEXTURE 0x00001000l + +/* + * Indicates that a surface may be a destination for 3D rendering. This + * bit must be set in order to query for a Direct3D Device Interface + * from this surface. + */ +#define DDSCAPS_3DDEVICE 0x00002000l + +/* + * Indicates that this surface exists in video memory. + */ +#define DDSCAPS_VIDEOMEMORY 0x00004000l + +/* + * Indicates that changes made to this surface are immediately visible. + * It is always set for the primary surface and is set for overlays while + * they are being overlayed and texture maps while they are being textured. + */ +#define DDSCAPS_VISIBLE 0x00008000l + +/* + * Indicates that only writes are permitted to the surface. Read accesses + * from the surface may or may not generate a protection fault, but the + * results of a read from this surface will not be meaningful. READ ONLY. + */ +#define DDSCAPS_WRITEONLY 0x00010000l + +/* + * Indicates that this surface is a z buffer. A z buffer does not contain + * displayable information. Instead it contains bit depth information that is + * used to determine which pixels are visible and which are obscured. + */ +#define DDSCAPS_ZBUFFER 0x00020000l + +/* + * Indicates surface will have a DC associated long term + */ +#define DDSCAPS_OWNDC 0x00040000l + +/* + * Indicates surface should be able to receive live video + */ +#define DDSCAPS_LIVEVIDEO 0x00080000l + +/* + * Indicates surface should be able to have a stream decompressed + * to it by the hardware. + */ +#define DDSCAPS_HWCODEC 0x00100000l + +/* + * Surface is a ModeX surface. + * + */ +#define DDSCAPS_MODEX 0x00200000l + +/* + * Indicates surface is one level of a mip-map. This surface will + * be attached to other DDSCAPS_MIPMAP surfaces to form the mip-map. + * This can be done explicitly, by creating a number of surfaces and + * attaching them with AddAttachedSurface or by implicitly by CreateSurface. + * If this bit is set then DDSCAPS_TEXTURE must also be set. + */ +#define DDSCAPS_MIPMAP 0x00400000l + +/* + * This bit is reserved. It should not be specified. + */ +#define DDSCAPS_RESERVED2 0x00800000l + + +/* + * Indicates that memory for the surface is not allocated until the surface + * is loaded (via the Direct3D texture Load() function). + */ +#define DDSCAPS_ALLOCONLOAD 0x04000000l + +/* + * Indicates that the surface will recieve data from a video port. + */ +#define DDSCAPS_VIDEOPORT 0x08000000l + +/* + * Indicates that a video memory surface is resident in true, local video + * memory rather than non-local video memory. If this flag is specified then + * so must DDSCAPS_VIDEOMEMORY. This flag is mutually exclusive with + * DDSCAPS_NONLOCALVIDMEM. + */ +#define DDSCAPS_LOCALVIDMEM 0x10000000l + +/* + * Indicates that a video memory surface is resident in non-local video + * memory rather than true, local video memory. If this flag is specified + * then so must DDSCAPS_VIDEOMEMORY. This flag is mutually exclusive with + * DDSCAPS_LOCALVIDMEM. + */ +#define DDSCAPS_NONLOCALVIDMEM 0x20000000l + +/* + * Indicates that this surface is a standard VGA mode surface, and not a + * ModeX surface. (This flag will never be set in combination with the + * DDSCAPS_MODEX flag). + */ +#define DDSCAPS_STANDARDVGAMODE 0x40000000l + +/* + * Indicates that this surface will be an optimized surface. This flag is + * currently only valid in conjunction with the DDSCAPS_TEXTURE flag. The surface + * will be created without any underlying video memory until loaded. + */ +#define DDSCAPS_OPTIMIZED 0x80000000l + + + +/* + * This bit is reserved + */ +#define DDSCAPS2_RESERVED4 0x00000002L +#define DDSCAPS2_HARDWAREDEINTERLACE 0x00000000L + +/* + * Indicates to the driver that this surface will be locked very frequently + * (for procedural textures, dynamic lightmaps, etc). Surfaces with this cap + * set must also have DDSCAPS_TEXTURE. This cap cannot be used with + * DDSCAPS2_HINTSTATIC and DDSCAPS2_OPAQUE. + */ +#define DDSCAPS2_HINTDYNAMIC 0x00000004L + +/* + * Indicates to the driver that this surface can be re-ordered/retiled on + * load. This operation will not change the size of the texture. It is + * relatively fast and symmetrical, since the application may lock these + * bits (although it will take a performance hit when doing so). Surfaces + * with this cap set must also have DDSCAPS_TEXTURE. This cap cannot be + * used with DDSCAPS2_HINTDYNAMIC and DDSCAPS2_OPAQUE. + */ +#define DDSCAPS2_HINTSTATIC 0x00000008L + +/* + * Indicates that the client would like this texture surface to be managed by the + * DirectDraw/Direct3D runtime. Surfaces with this cap set must also have + * DDSCAPS_TEXTURE set. + */ +#define DDSCAPS2_TEXTUREMANAGE 0x00000010L + +/* + * These bits are reserved for internal use */ +#define DDSCAPS2_RESERVED1 0x00000020L +#define DDSCAPS2_RESERVED2 0x00000040L + +/* + * Indicates to the driver that this surface will never be locked again. + * The driver is free to optimize this surface via retiling and actual compression. + * All calls to Lock() or Blts from this surface will fail. Surfaces with this + * cap set must also have DDSCAPS_TEXTURE. This cap cannot be used with + * DDSCAPS2_HINTDYNAMIC and DDSCAPS2_HINTSTATIC. + */ +#define DDSCAPS2_OPAQUE 0x00000080L + +/* + * Applications should set this bit at CreateSurface time to indicate that they + * intend to use antialiasing. Only valid if DDSCAPS_3DDEVICE is also set. + */ +#define DDSCAPS2_HINTANTIALIASING 0x00000100L + + +/* + * This flag is used at CreateSurface time to indicate that this set of + * surfaces is a cubic environment map + */ +#define DDSCAPS2_CUBEMAP 0x00000200L + +/* + * These flags preform two functions: + * - At CreateSurface time, they define which of the six cube faces are + * required by the application. + * - After creation, each face in the cubemap will have exactly one of these + * bits set. + */ +#define DDSCAPS2_CUBEMAP_POSITIVEX 0x00000400L +#define DDSCAPS2_CUBEMAP_NEGATIVEX 0x00000800L +#define DDSCAPS2_CUBEMAP_POSITIVEY 0x00001000L +#define DDSCAPS2_CUBEMAP_NEGATIVEY 0x00002000L +#define DDSCAPS2_CUBEMAP_POSITIVEZ 0x00004000L +#define DDSCAPS2_CUBEMAP_NEGATIVEZ 0x00008000L + +/* + * This macro may be used to specify all faces of a cube map at CreateSurface time + */ +#define DDSCAPS2_CUBEMAP_ALLFACES ( DDSCAPS2_CUBEMAP_POSITIVEX |\ + DDSCAPS2_CUBEMAP_NEGATIVEX |\ + DDSCAPS2_CUBEMAP_POSITIVEY |\ + DDSCAPS2_CUBEMAP_NEGATIVEY |\ + DDSCAPS2_CUBEMAP_POSITIVEZ |\ + DDSCAPS2_CUBEMAP_NEGATIVEZ ) + + +/* + * This flag is an additional flag which is present on mipmap sublevels from DX7 onwards + * It enables easier use of GetAttachedSurface rather than EnumAttachedSurfaces for surface + * constructs such as Cube Maps, wherein there are more than one mipmap surface attached + * to the root surface. + * This caps bit is ignored by CreateSurface + */ +#define DDSCAPS2_MIPMAPSUBLEVEL 0x00010000L + +/* This flag indicates that the texture should be managed by D3D only */ +#define DDSCAPS2_D3DTEXTUREMANAGE 0x00020000L + +/* This flag indicates that the managed surface can be safely lost */ +#define DDSCAPS2_DONOTPERSIST 0x00040000L + +/* indicates that this surface is part of a stereo flipping chain */ +#define DDSCAPS2_STEREOSURFACELEFT 0x00080000L + + +/* + * Indicates that the surface is a volume. + * Can be combined with DDSCAPS_MIPMAP to indicate a multi-level volume + */ +#define DDSCAPS2_VOLUME 0x00200000L + +/* + * Indicates that the surface may be locked multiple times by the application. + * This cap cannot be used with DDSCAPS2_OPAQUE. + */ +#define DDSCAPS2_NOTUSERLOCKABLE 0x00400000L + +/* + * Indicates that the vertex buffer data can be used to render points and + * point sprites. + */ +#define DDSCAPS2_POINTS 0x00800000L + +/* + * Indicates that the vertex buffer data can be used to render rt pactches. + */ +#define DDSCAPS2_RTPATCHES 0x01000000L + +/* + * Indicates that the vertex buffer data can be used to render n patches. + */ +#define DDSCAPS2_NPATCHES 0x02000000L + +/* + * This bit is reserved for internal use + */ +#define DDSCAPS2_RESERVED3 0x04000000L + + +/* + * Indicates that the contents of the backbuffer do not have to be preserved + * the contents of the backbuffer after they are presented. + */ +#define DDSCAPS2_DISCARDBACKBUFFER 0x10000000L + +/* + * Indicates that all surfaces in this creation chain should be given an alpha channel. + * This flag will be set on primary surface chains that may have no explicit pixel format + * (and thus take on the format of the current display mode). + * The driver should infer that all these surfaces have a format having an alpha channel. + * (e.g. assume D3DFMT_A8R8G8B8 if the display mode is x888.) + */ +#define DDSCAPS2_ENABLEALPHACHANNEL 0x20000000L + +/* + * Indicates that all surfaces in this creation chain is extended primary surface format. + * This flag will be set on extended primary surface chains that always have explicit pixel + * format and the pixel format is typically GDI (Graphics Device Interface) couldn't handle, + * thus only used with fullscreen application. (e.g. D3DFMT_A2R10G10B10 format) + */ +#define DDSCAPS2_EXTENDEDFORMATPRIMARY 0x40000000L + +/* + * Indicates that all surfaces in this creation chain is additional primary surface. + * This flag will be set on primary surface chains which must present on the adapter + * id provided on dwCaps4. Typically this will be used to create secondary primary surface + * on DualView display adapter. + */ +#define DDSCAPS2_ADDITIONALPRIMARY 0x80000000L + +/* + * This is a mask that indicates the set of bits that may be set + * at createsurface time to indicate number of samples per pixel + * when multisampling + */ +#define DDSCAPS3_MULTISAMPLE_MASK 0x0000001FL + +/* + * This is a mask that indicates the set of bits that may be set + * at createsurface time to indicate the quality level of rendering + * for the current number of samples per pixel + */ +#define DDSCAPS3_MULTISAMPLE_QUALITY_MASK 0x000000E0L +#define DDSCAPS3_MULTISAMPLE_QUALITY_SHIFT 5 + +/* + * This bit is reserved for internal use + */ +#define DDSCAPS3_RESERVED1 0x00000100L + +/* + * This bit is reserved for internal use + */ +#define DDSCAPS3_RESERVED2 0x00000200L + +/* + * This indicates whether this surface has light-weight miplevels + */ +#define DDSCAPS3_LIGHTWEIGHTMIPMAP 0x00000400L + +/* + * This indicates that the mipsublevels for this surface are auto-generated + */ +#define DDSCAPS3_AUTOGENMIPMAP 0x00000800L + +/* + * This indicates that the mipsublevels for this surface are auto-generated + */ +#define DDSCAPS3_DMAP 0x00001000L + + + /**************************************************************************** + * + * DIRECTDRAW DRIVER CAPABILITY FLAGS + * + ****************************************************************************/ + +/* + * Display hardware has 3D acceleration. + */ +#define DDCAPS_3D 0x00000001l + +/* + * Indicates that DirectDraw will support only dest rectangles that are aligned + * on DIRECTDRAWCAPS.dwAlignBoundaryDest boundaries of the surface, respectively. + * READ ONLY. + */ +#define DDCAPS_ALIGNBOUNDARYDEST 0x00000002l + +/* + * Indicates that DirectDraw will support only source rectangles whose sizes in + * BYTEs are DIRECTDRAWCAPS.dwAlignSizeDest multiples, respectively. READ ONLY. + */ +#define DDCAPS_ALIGNSIZEDEST 0x00000004l +/* + * Indicates that DirectDraw will support only source rectangles that are aligned + * on DIRECTDRAWCAPS.dwAlignBoundarySrc boundaries of the surface, respectively. + * READ ONLY. + */ +#define DDCAPS_ALIGNBOUNDARYSRC 0x00000008l + +/* + * Indicates that DirectDraw will support only source rectangles whose sizes in + * BYTEs are DIRECTDRAWCAPS.dwAlignSizeSrc multiples, respectively. READ ONLY. + */ +#define DDCAPS_ALIGNSIZESRC 0x00000010l + +/* + * Indicates that DirectDraw will create video memory surfaces that have a stride + * alignment equal to DIRECTDRAWCAPS.dwAlignStride. READ ONLY. + */ +#define DDCAPS_ALIGNSTRIDE 0x00000020l + +/* + * Display hardware is capable of blt operations. + */ +#define DDCAPS_BLT 0x00000040l + +/* + * Display hardware is capable of asynchronous blt operations. + */ +#define DDCAPS_BLTQUEUE 0x00000080l + +/* + * Display hardware is capable of color space conversions during the blt operation. + */ +#define DDCAPS_BLTFOURCC 0x00000100l + +/* + * Display hardware is capable of stretching during blt operations. + */ +#define DDCAPS_BLTSTRETCH 0x00000200l + +/* + * Display hardware is shared with GDI. + */ +#define DDCAPS_GDI 0x00000400l + +/* + * Display hardware can overlay. + */ +#define DDCAPS_OVERLAY 0x00000800l + +/* + * Set if display hardware supports overlays but can not clip them. + */ +#define DDCAPS_OVERLAYCANTCLIP 0x00001000l + +/* + * Indicates that overlay hardware is capable of color space conversions during + * the overlay operation. + */ +#define DDCAPS_OVERLAYFOURCC 0x00002000l + +/* + * Indicates that stretching can be done by the overlay hardware. + */ +#define DDCAPS_OVERLAYSTRETCH 0x00004000l + +/* + * Indicates that unique DirectDrawPalettes can be created for DirectDrawSurfaces + * other than the primary surface. + */ +#define DDCAPS_PALETTE 0x00008000l + +/* + * Indicates that palette changes can be syncd with the veritcal refresh. + */ +#define DDCAPS_PALETTEVSYNC 0x00010000l + +/* + * Display hardware can return the current scan line. + */ +#define DDCAPS_READSCANLINE 0x00020000l + + +/* + * This flag used to bo DDCAPS_STEREOVIEW, which is now obsolete + */ +#define DDCAPS_RESERVED1 0x00040000l + +/* + * Display hardware is capable of generating a vertical blank interrupt. + */ +#define DDCAPS_VBI 0x00080000l + +/* + * Supports the use of z buffers with blt operations. + */ +#define DDCAPS_ZBLTS 0x00100000l + +/* + * Supports Z Ordering of overlays. + */ +#define DDCAPS_ZOVERLAYS 0x00200000l + +/* + * Supports color key + */ +#define DDCAPS_COLORKEY 0x00400000l + +/* + * Supports alpha surfaces + */ +#define DDCAPS_ALPHA 0x00800000l + +/* + * colorkey is hardware assisted(DDCAPS_COLORKEY will also be set) + */ +#define DDCAPS_COLORKEYHWASSIST 0x01000000l + +/* + * no hardware support at all + */ +#define DDCAPS_NOHARDWARE 0x02000000l + +/* + * Display hardware is capable of color fill with bltter + */ +#define DDCAPS_BLTCOLORFILL 0x04000000l + +/* + * Display hardware is bank switched, and potentially very slow at + * random access to VRAM. + */ +#define DDCAPS_BANKSWITCHED 0x08000000l + +/* + * Display hardware is capable of depth filling Z-buffers with bltter + */ +#define DDCAPS_BLTDEPTHFILL 0x10000000l + +/* + * Display hardware is capable of clipping while bltting. + */ +#define DDCAPS_CANCLIP 0x20000000l + +/* + * Display hardware is capable of clipping while stretch bltting. + */ +#define DDCAPS_CANCLIPSTRETCHED 0x40000000l + +/* + * Display hardware is capable of bltting to or from system memory + */ +#define DDCAPS_CANBLTSYSMEM 0x80000000l + + + /**************************************************************************** + * + * MORE DIRECTDRAW DRIVER CAPABILITY FLAGS (dwCaps2) + * + ****************************************************************************/ + +/* + * Display hardware is certified + */ +#define DDCAPS2_CERTIFIED 0x00000001l + +/* + * Driver cannot interleave 2D operations (lock and blt) to surfaces with + * Direct3D rendering operations between calls to BeginScene() and EndScene() + */ +#define DDCAPS2_NO2DDURING3DSCENE 0x00000002l + +/* + * Display hardware contains a video port + */ +#define DDCAPS2_VIDEOPORT 0x00000004l + +/* + * The overlay can be automatically flipped according to the video port + * VSYNCs, providing automatic doubled buffered display of video port + * data using an overlay + */ +#define DDCAPS2_AUTOFLIPOVERLAY 0x00000008l + +/* + * Overlay can display each field of interlaced data individually while + * it is interleaved in memory without causing jittery artifacts. + */ +#define DDCAPS2_CANBOBINTERLEAVED 0x00000010l + +/* + * Overlay can display each field of interlaced data individually while + * it is not interleaved in memory without causing jittery artifacts. + */ +#define DDCAPS2_CANBOBNONINTERLEAVED 0x00000020l + +/* + * The overlay surface contains color controls (brightness, sharpness, etc.) + */ +#define DDCAPS2_COLORCONTROLOVERLAY 0x00000040l + +/* + * The primary surface contains color controls (gamma, etc.) + */ +#define DDCAPS2_COLORCONTROLPRIMARY 0x00000080l + +/* + * RGBZ -> RGB supported for 16:16 RGB:Z + */ +#define DDCAPS2_CANDROPZ16BIT 0x00000100l + +/* + * Driver supports non-local video memory. + */ +#define DDCAPS2_NONLOCALVIDMEM 0x00000200l + +/* + * Dirver supports non-local video memory but has different capabilities for + * non-local video memory surfaces. If this bit is set then so must + * DDCAPS2_NONLOCALVIDMEM. + */ +#define DDCAPS2_NONLOCALVIDMEMCAPS 0x00000400l + +/* + * Driver neither requires nor prefers surfaces to be pagelocked when performing + * blts involving system memory surfaces + */ +#define DDCAPS2_NOPAGELOCKREQUIRED 0x00000800l + +/* + * Driver can create surfaces which are wider than the primary surface + */ +#define DDCAPS2_WIDESURFACES 0x00001000l + +/* + * Driver supports bob without using a video port by handling the + * DDFLIP_ODD and DDFLIP_EVEN flags specified in Flip. + */ +#define DDCAPS2_CANFLIPODDEVEN 0x00002000l + +/* + * Driver supports bob using hardware + */ +#define DDCAPS2_CANBOBHARDWARE 0x00004000l + +/* + * Driver supports bltting any FOURCC surface to another surface of the same FOURCC + */ +#define DDCAPS2_COPYFOURCC 0x00008000l + + +/* + * Driver supports loadable gamma ramps for the primary surface + */ +#define DDCAPS2_PRIMARYGAMMA 0x00020000l + +/* + * Driver can render in windowed mode. + */ +#define DDCAPS2_CANRENDERWINDOWED 0x00080000l + +/* + * A calibrator is available to adjust the gamma ramp according to the + * physical display properties so that the result will be identical on + * all calibrated systems. + */ +#define DDCAPS2_CANCALIBRATEGAMMA 0x00100000l + +/* + * Indicates that the driver will respond to DDFLIP_INTERVALn flags + */ +#define DDCAPS2_FLIPINTERVAL 0x00200000l + +/* + * Indicates that the driver will respond to DDFLIP_NOVSYNC + */ +#define DDCAPS2_FLIPNOVSYNC 0x00400000l + +/* + * Driver supports management of video memory, if this flag is ON, + * driver manages the texture if requested with DDSCAPS2_TEXTUREMANAGE on + * DirectX manages the texture if this flag is OFF and surface has DDSCAPS2_TEXTUREMANAGE on + */ +#define DDCAPS2_CANMANAGETEXTURE 0x00800000l + +/* + * The Direct3D texture manager uses this cap to decide whether to put managed + * surfaces in non-local video memory. If the cap is set, the texture manager will + * put managed surfaces in non-local vidmem. Drivers that cannot texture from + * local vidmem SHOULD NOT set this cap. + */ +#define DDCAPS2_TEXMANINNONLOCALVIDMEM 0x01000000l + +/* + * Indicates that the driver supports DX7 type of stereo in at least one mode (which may + * not necessarily be the current mode). Applications should use IDirectDraw7 (or higher) + * ::EnumDisplayModes and check the DDSURFACEDESC.ddsCaps.dwCaps2 field for the presence of + * DDSCAPS2_STEREOSURFACELEFT to check if a particular mode supports stereo. The application + * can also use IDirectDraw7(or higher)::GetDisplayMode to check the current mode. + */ +#define DDCAPS2_STEREO 0x02000000L + +/* + * This caps bit is intended for internal DirectDraw use. + * -It is only valid if DDCAPS2_NONLOCALVIDMEMCAPS is set. + * -If this bit is set, then DDCAPS_CANBLTSYSMEM MUST be set by the driver (and + * all the assoicated system memory blt caps must be correct). + * -It implies that the system->video blt caps in DDCAPS also apply to system to + * nonlocal blts. I.e. the dwSVBCaps, dwSVBCKeyCaps, dwSVBFXCaps and dwSVBRops + * members of DDCAPS (DDCORECAPS) are filled in correctly. + * -Any blt from system to nonlocal memory that matches these caps bits will + * be passed to the driver. + * + * NOTE: This is intended to enable the driver itself to do efficient reordering + * of textures. This is NOT meant to imply that hardware can write into AGP memory. + * This operation is not currently supported. + */ +#define DDCAPS2_SYSTONONLOCAL_AS_SYSTOLOCAL 0x04000000L + +/* + * was DDCAPS2_PUREHAL + */ +#define DDCAPS2_RESERVED1 0x08000000L + +/* + * Driver supports management of video memory, if this flag is ON, + * driver manages the resource if requested with DDSCAPS2_TEXTUREMANAGE on + * DirectX manages the resource if this flag is OFF and surface has DDSCAPS2_TEXTUREMANAGE on + */ +#define DDCAPS2_CANMANAGERESOURCE 0x10000000L + +/* + * Driver supports dynamic textures. This will allow the application to set + * D3DUSAGE_DYNAMIC (DDSCAPS2_HINTDYNAMIC for drivers) at texture create time. + * Video memory dynamic textures WILL be lockable by applications. It is + * expected that these locks will be very efficient (which implies that the + * driver should always maintain a linear copy, a pointer to which can be + * quickly handed out to the application). + */ +#define DDCAPS2_DYNAMICTEXTURES 0x20000000L + +/* + * Driver supports auto-generation of mipmaps. + */ +#define DDCAPS2_CANAUTOGENMIPMAP 0x40000000L + + +/**************************************************************************** + * + * DIRECTDRAW FX ALPHA CAPABILITY FLAGS + * + ****************************************************************************/ + +/* + * Supports alpha blending around the edge of a source color keyed surface. + * For Blt. + */ +#define DDFXALPHACAPS_BLTALPHAEDGEBLEND 0x00000001l + +/* + * Supports alpha information in the pixel format. The bit depth of alpha + * information in the pixel format can be 1,2,4, or 8. The alpha value becomes + * more opaque as the alpha value increases. (0 is transparent.) + * For Blt. + */ +#define DDFXALPHACAPS_BLTALPHAPIXELS 0x00000002l + +/* + * Supports alpha information in the pixel format. The bit depth of alpha + * information in the pixel format can be 1,2,4, or 8. The alpha value + * becomes more transparent as the alpha value increases. (0 is opaque.) + * This flag can only be set if DDCAPS_ALPHA is set. + * For Blt. + */ +#define DDFXALPHACAPS_BLTALPHAPIXELSNEG 0x00000004l + +/* + * Supports alpha only surfaces. The bit depth of an alpha only surface can be + * 1,2,4, or 8. The alpha value becomes more opaque as the alpha value increases. + * (0 is transparent.) + * For Blt. + */ +#define DDFXALPHACAPS_BLTALPHASURFACES 0x00000008l + +/* + * The depth of the alpha channel data can range can be 1,2,4, or 8. + * The NEG suffix indicates that this alpha channel becomes more transparent + * as the alpha value increases. (0 is opaque.) This flag can only be set if + * DDCAPS_ALPHA is set. + * For Blt. + */ +#define DDFXALPHACAPS_BLTALPHASURFACESNEG 0x00000010l + +/* + * Supports alpha blending around the edge of a source color keyed surface. + * For Overlays. + */ +#define DDFXALPHACAPS_OVERLAYALPHAEDGEBLEND 0x00000020l + +/* + * Supports alpha information in the pixel format. The bit depth of alpha + * information in the pixel format can be 1,2,4, or 8. The alpha value becomes + * more opaque as the alpha value increases. (0 is transparent.) + * For Overlays. + */ +#define DDFXALPHACAPS_OVERLAYALPHAPIXELS 0x00000040l + +/* + * Supports alpha information in the pixel format. The bit depth of alpha + * information in the pixel format can be 1,2,4, or 8. The alpha value + * becomes more transparent as the alpha value increases. (0 is opaque.) + * This flag can only be set if DDCAPS_ALPHA is set. + * For Overlays. + */ +#define DDFXALPHACAPS_OVERLAYALPHAPIXELSNEG 0x00000080l + +/* + * Supports alpha only surfaces. The bit depth of an alpha only surface can be + * 1,2,4, or 8. The alpha value becomes more opaque as the alpha value increases. + * (0 is transparent.) + * For Overlays. + */ +#define DDFXALPHACAPS_OVERLAYALPHASURFACES 0x00000100l + +/* + * The depth of the alpha channel data can range can be 1,2,4, or 8. + * The NEG suffix indicates that this alpha channel becomes more transparent + * as the alpha value increases. (0 is opaque.) This flag can only be set if + * DDCAPS_ALPHA is set. + * For Overlays. + */ +#define DDFXALPHACAPS_OVERLAYALPHASURFACESNEG 0x00000200l + +#if DIRECTDRAW_VERSION < 0x0600 +#endif //DIRECTDRAW_VERSION + + +/**************************************************************************** + * + * DIRECTDRAW FX CAPABILITY FLAGS + * + ****************************************************************************/ + +/* + * Uses arithmetic operations to stretch and shrink surfaces during blt + * rather than pixel doubling techniques. Along the Y axis. + */ +#define DDFXCAPS_BLTARITHSTRETCHY 0x00000020l + +/* + * Uses arithmetic operations to stretch during blt + * rather than pixel doubling techniques. Along the Y axis. Only + * works for x1, x2, etc. + */ +#define DDFXCAPS_BLTARITHSTRETCHYN 0x00000010l + +/* + * Supports mirroring left to right in blt. + */ +#define DDFXCAPS_BLTMIRRORLEFTRIGHT 0x00000040l + +/* + * Supports mirroring top to bottom in blt. + */ +#define DDFXCAPS_BLTMIRRORUPDOWN 0x00000080l + +/* + * Supports arbitrary rotation for blts. + */ +#define DDFXCAPS_BLTROTATION 0x00000100l + +/* + * Supports 90 degree rotations for blts. + */ +#define DDFXCAPS_BLTROTATION90 0x00000200l + +/* + * DirectDraw supports arbitrary shrinking of a surface along the + * x axis (horizontal direction) for blts. + */ +#define DDFXCAPS_BLTSHRINKX 0x00000400l + +/* + * DirectDraw supports integer shrinking (1x,2x,) of a surface + * along the x axis (horizontal direction) for blts. + */ +#define DDFXCAPS_BLTSHRINKXN 0x00000800l + +/* + * DirectDraw supports arbitrary shrinking of a surface along the + * y axis (horizontal direction) for blts. + */ +#define DDFXCAPS_BLTSHRINKY 0x00001000l + +/* + * DirectDraw supports integer shrinking (1x,2x,) of a surface + * along the y axis (vertical direction) for blts. + */ +#define DDFXCAPS_BLTSHRINKYN 0x00002000l + +/* + * DirectDraw supports arbitrary stretching of a surface along the + * x axis (horizontal direction) for blts. + */ +#define DDFXCAPS_BLTSTRETCHX 0x00004000l + +/* + * DirectDraw supports integer stretching (1x,2x,) of a surface + * along the x axis (horizontal direction) for blts. + */ +#define DDFXCAPS_BLTSTRETCHXN 0x00008000l + +/* + * DirectDraw supports arbitrary stretching of a surface along the + * y axis (horizontal direction) for blts. + */ +#define DDFXCAPS_BLTSTRETCHY 0x00010000l + +/* + * DirectDraw supports integer stretching (1x,2x,) of a surface + * along the y axis (vertical direction) for blts. + */ +#define DDFXCAPS_BLTSTRETCHYN 0x00020000l + +/* + * Uses arithmetic operations to stretch and shrink surfaces during + * overlay rather than pixel doubling techniques. Along the Y axis + * for overlays. + */ +#define DDFXCAPS_OVERLAYARITHSTRETCHY 0x00040000l + +/* + * Uses arithmetic operations to stretch surfaces during + * overlay rather than pixel doubling techniques. Along the Y axis + * for overlays. Only works for x1, x2, etc. + */ +#define DDFXCAPS_OVERLAYARITHSTRETCHYN 0x00000008l + +/* + * DirectDraw supports arbitrary shrinking of a surface along the + * x axis (horizontal direction) for overlays. + */ +#define DDFXCAPS_OVERLAYSHRINKX 0x00080000l + +/* + * DirectDraw supports integer shrinking (1x,2x,) of a surface + * along the x axis (horizontal direction) for overlays. + */ +#define DDFXCAPS_OVERLAYSHRINKXN 0x00100000l + +/* + * DirectDraw supports arbitrary shrinking of a surface along the + * y axis (horizontal direction) for overlays. + */ +#define DDFXCAPS_OVERLAYSHRINKY 0x00200000l + +/* + * DirectDraw supports integer shrinking (1x,2x,) of a surface + * along the y axis (vertical direction) for overlays. + */ +#define DDFXCAPS_OVERLAYSHRINKYN 0x00400000l + +/* + * DirectDraw supports arbitrary stretching of a surface along the + * x axis (horizontal direction) for overlays. + */ +#define DDFXCAPS_OVERLAYSTRETCHX 0x00800000l + +/* + * DirectDraw supports integer stretching (1x,2x,) of a surface + * along the x axis (horizontal direction) for overlays. + */ +#define DDFXCAPS_OVERLAYSTRETCHXN 0x01000000l + +/* + * DirectDraw supports arbitrary stretching of a surface along the + * y axis (horizontal direction) for overlays. + */ +#define DDFXCAPS_OVERLAYSTRETCHY 0x02000000l + +/* + * DirectDraw supports integer stretching (1x,2x,) of a surface + * along the y axis (vertical direction) for overlays. + */ +#define DDFXCAPS_OVERLAYSTRETCHYN 0x04000000l + +/* + * DirectDraw supports mirroring of overlays across the vertical axis + */ +#define DDFXCAPS_OVERLAYMIRRORLEFTRIGHT 0x08000000l + +/* + * DirectDraw supports mirroring of overlays across the horizontal axis + */ +#define DDFXCAPS_OVERLAYMIRRORUPDOWN 0x10000000l + +/* + * DirectDraw supports deinterlacing of overlay surfaces + */ +#define DDFXCAPS_OVERLAYDEINTERLACE 0x20000000l + +/* + * Driver can do alpha blending for blits. + */ +#define DDFXCAPS_BLTALPHA 0x00000001l + + +/* + * Driver can do surface-reconstruction filtering for warped blits. + */ +#define DDFXCAPS_BLTFILTER DDFXCAPS_BLTARITHSTRETCHY + +/* + * Driver can do alpha blending for overlays. + */ +#define DDFXCAPS_OVERLAYALPHA 0x00000004l + + +/* + * Driver can do surface-reconstruction filtering for warped overlays. + */ +#define DDFXCAPS_OVERLAYFILTER DDFXCAPS_OVERLAYARITHSTRETCHY + +/**************************************************************************** + * + * DIRECTDRAW STEREO VIEW CAPABILITIES + * + ****************************************************************************/ + +/* + * This flag used to be DDSVCAPS_ENIGMA, which is now obsolete + */ + +#define DDSVCAPS_RESERVED1 0x00000001l + +/* + * This flag used to be DDSVCAPS_FLICKER, which is now obsolete + */ +#define DDSVCAPS_RESERVED2 0x00000002l + +/* + * This flag used to be DDSVCAPS_REDBLUE, which is now obsolete + */ +#define DDSVCAPS_RESERVED3 0x00000004l + +/* + * This flag used to be DDSVCAPS_SPLIT, which is now obsolete + */ +#define DDSVCAPS_RESERVED4 0x00000008l + +/* + * The stereo view is accomplished with switching technology + */ + +#define DDSVCAPS_STEREOSEQUENTIAL 0x00000010L + + + +/**************************************************************************** + * + * DIRECTDRAWPALETTE CAPABILITIES + * + ****************************************************************************/ + +/* + * Index is 4 bits. There are sixteen color entries in the palette table. + */ +#define DDPCAPS_4BIT 0x00000001l + +/* + * Index is onto a 8 bit color index. This field is only valid with the + * DDPCAPS_1BIT, DDPCAPS_2BIT or DDPCAPS_4BIT capability and the target + * surface is in 8bpp. Each color entry is one byte long and is an index + * into destination surface's 8bpp palette. + */ +#define DDPCAPS_8BITENTRIES 0x00000002l + +/* + * Index is 8 bits. There are 256 color entries in the palette table. + */ +#define DDPCAPS_8BIT 0x00000004l + +/* + * Indicates that this DIRECTDRAWPALETTE should use the palette color array + * passed into the lpDDColorArray parameter to initialize the DIRECTDRAWPALETTE + * object. + * This flag is obsolete. DirectDraw always initializes the color array from + * the lpDDColorArray parameter. The definition remains for source-level + * compatibility. + */ +#define DDPCAPS_INITIALIZE 0x00000000l + +/* + * This palette is the one attached to the primary surface. Changing this + * table has immediate effect on the display unless DDPSETPAL_VSYNC is specified + * and supported. + */ +#define DDPCAPS_PRIMARYSURFACE 0x00000010l + +/* + * This palette is the one attached to the primary surface left. Changing + * this table has immediate effect on the display for the left eye unless + * DDPSETPAL_VSYNC is specified and supported. + */ +#define DDPCAPS_PRIMARYSURFACELEFT 0x00000020l + +/* + * This palette can have all 256 entries defined + */ +#define DDPCAPS_ALLOW256 0x00000040l + +/* + * This palette can have modifications to it synced with the monitors + * refresh rate. + */ +#define DDPCAPS_VSYNC 0x00000080l + +/* + * Index is 1 bit. There are two color entries in the palette table. + */ +#define DDPCAPS_1BIT 0x00000100l + +/* + * Index is 2 bit. There are four color entries in the palette table. + */ +#define DDPCAPS_2BIT 0x00000200l + +/* + * The peFlags member of PALETTEENTRY denotes an 8 bit alpha value + */ +#define DDPCAPS_ALPHA 0x00000400l + + +/**************************************************************************** + * + * DIRECTDRAWPALETTE SETENTRY CONSTANTS + * + ****************************************************************************/ + + +/**************************************************************************** + * + * DIRECTDRAWPALETTE GETENTRY CONSTANTS + * + ****************************************************************************/ + +/* 0 is the only legal value */ + +/**************************************************************************** + * + * DIRECTDRAWSURFACE SETPRIVATEDATA CONSTANTS + * + ****************************************************************************/ + +/* + * The passed pointer is an IUnknown ptr. The cbData argument to SetPrivateData + * must be set to sizeof(IUnknown*). DirectDraw will call AddRef through this + * pointer and Release when the private data is destroyed. This includes when + * the surface or palette is destroyed before such priovate data is destroyed. + */ +#define DDSPD_IUNKNOWNPOINTER 0x00000001L + +/* + * Private data is only valid for the current state of the object, + * as determined by the uniqueness value. + */ +#define DDSPD_VOLATILE 0x00000002L + + +/**************************************************************************** + * + * DIRECTDRAWSURFACE SETPALETTE CONSTANTS + * + ****************************************************************************/ + + +/**************************************************************************** + * + * DIRECTDRAW BITDEPTH CONSTANTS + * + * NOTE: These are only used to indicate supported bit depths. These + * are flags only, they are not to be used as an actual bit depth. The + * absolute numbers 1, 2, 4, 8, 16, 24 and 32 are used to indicate actual + * bit depths in a surface or for changing the display mode. + * + ****************************************************************************/ + +/* + * 1 bit per pixel. + */ +#define DDBD_1 0x00004000l + +/* + * 2 bits per pixel. + */ +#define DDBD_2 0x00002000l + +/* + * 4 bits per pixel. + */ +#define DDBD_4 0x00001000l + +/* + * 8 bits per pixel. + */ +#define DDBD_8 0x00000800l + +/* + * 16 bits per pixel. + */ +#define DDBD_16 0x00000400l + +/* + * 24 bits per pixel. + */ +#define DDBD_24 0X00000200l + +/* + * 32 bits per pixel. + */ +#define DDBD_32 0x00000100l + +/**************************************************************************** + * + * DIRECTDRAWSURFACE SET/GET COLOR KEY FLAGS + * + ****************************************************************************/ + +/* + * Set if the structure contains a color space. Not set if the structure + * contains a single color key. + */ +#define DDCKEY_COLORSPACE 0x00000001l + +/* + * Set if the structure specifies a color key or color space which is to be + * used as a destination color key for blt operations. + */ +#define DDCKEY_DESTBLT 0x00000002l + +/* + * Set if the structure specifies a color key or color space which is to be + * used as a destination color key for overlay operations. + */ +#define DDCKEY_DESTOVERLAY 0x00000004l + +/* + * Set if the structure specifies a color key or color space which is to be + * used as a source color key for blt operations. + */ +#define DDCKEY_SRCBLT 0x00000008l + +/* + * Set if the structure specifies a color key or color space which is to be + * used as a source color key for overlay operations. + */ +#define DDCKEY_SRCOVERLAY 0x00000010l + + +/**************************************************************************** + * + * DIRECTDRAW COLOR KEY CAPABILITY FLAGS + * + ****************************************************************************/ + +/* + * Supports transparent blting using a color key to identify the replaceable + * bits of the destination surface for RGB colors. + */ +#define DDCKEYCAPS_DESTBLT 0x00000001l + +/* + * Supports transparent blting using a color space to identify the replaceable + * bits of the destination surface for RGB colors. + */ +#define DDCKEYCAPS_DESTBLTCLRSPACE 0x00000002l + +/* + * Supports transparent blting using a color space to identify the replaceable + * bits of the destination surface for YUV colors. + */ +#define DDCKEYCAPS_DESTBLTCLRSPACEYUV 0x00000004l + +/* + * Supports transparent blting using a color key to identify the replaceable + * bits of the destination surface for YUV colors. + */ +#define DDCKEYCAPS_DESTBLTYUV 0x00000008l + +/* + * Supports overlaying using colorkeying of the replaceable bits of the surface + * being overlayed for RGB colors. + */ +#define DDCKEYCAPS_DESTOVERLAY 0x00000010l + +/* + * Supports a color space as the color key for the destination for RGB colors. + */ +#define DDCKEYCAPS_DESTOVERLAYCLRSPACE 0x00000020l + +/* + * Supports a color space as the color key for the destination for YUV colors. + */ +#define DDCKEYCAPS_DESTOVERLAYCLRSPACEYUV 0x00000040l + +/* + * Supports only one active destination color key value for visible overlay + * surfaces. + */ +#define DDCKEYCAPS_DESTOVERLAYONEACTIVE 0x00000080l + +/* + * Supports overlaying using colorkeying of the replaceable bits of the + * surface being overlayed for YUV colors. + */ +#define DDCKEYCAPS_DESTOVERLAYYUV 0x00000100l + +/* + * Supports transparent blting using the color key for the source with + * this surface for RGB colors. + */ +#define DDCKEYCAPS_SRCBLT 0x00000200l + +/* + * Supports transparent blting using a color space for the source with + * this surface for RGB colors. + */ +#define DDCKEYCAPS_SRCBLTCLRSPACE 0x00000400l + +/* + * Supports transparent blting using a color space for the source with + * this surface for YUV colors. + */ +#define DDCKEYCAPS_SRCBLTCLRSPACEYUV 0x00000800l + +/* + * Supports transparent blting using the color key for the source with + * this surface for YUV colors. + */ +#define DDCKEYCAPS_SRCBLTYUV 0x00001000l + +/* + * Supports overlays using the color key for the source with this + * overlay surface for RGB colors. + */ +#define DDCKEYCAPS_SRCOVERLAY 0x00002000l + +/* + * Supports overlays using a color space as the source color key for + * the overlay surface for RGB colors. + */ +#define DDCKEYCAPS_SRCOVERLAYCLRSPACE 0x00004000l + +/* + * Supports overlays using a color space as the source color key for + * the overlay surface for YUV colors. + */ +#define DDCKEYCAPS_SRCOVERLAYCLRSPACEYUV 0x00008000l + +/* + * Supports only one active source color key value for visible + * overlay surfaces. + */ +#define DDCKEYCAPS_SRCOVERLAYONEACTIVE 0x00010000l + +/* + * Supports overlays using the color key for the source with this + * overlay surface for YUV colors. + */ +#define DDCKEYCAPS_SRCOVERLAYYUV 0x00020000l + +/* + * there are no bandwidth trade-offs for using colorkey with an overlay + */ +#define DDCKEYCAPS_NOCOSTOVERLAY 0x00040000l + + +/**************************************************************************** + * + * DIRECTDRAW PIXELFORMAT FLAGS + * + ****************************************************************************/ + +/* + * The surface has alpha channel information in the pixel format. + */ +#define DDPF_ALPHAPIXELS 0x00000001l + +/* + * The pixel format contains alpha only information + */ +#define DDPF_ALPHA 0x00000002l + +/* + * The FourCC code is valid. + */ +#define DDPF_FOURCC 0x00000004l + +/* + * The surface is 4-bit color indexed. + */ +#define DDPF_PALETTEINDEXED4 0x00000008l + +/* + * The surface is indexed into a palette which stores indices + * into the destination surface's 8-bit palette. + */ +#define DDPF_PALETTEINDEXEDTO8 0x00000010l + +/* + * The surface is 8-bit color indexed. + */ +#define DDPF_PALETTEINDEXED8 0x00000020l + +/* + * The RGB data in the pixel format structure is valid. + */ +#define DDPF_RGB 0x00000040l + +/* + * The surface will accept pixel data in the format specified + * and compress it during the write. + */ +#define DDPF_COMPRESSED 0x00000080l + +/* + * The surface will accept RGB data and translate it during + * the write to YUV data. The format of the data to be written + * will be contained in the pixel format structure. The DDPF_RGB + * flag will be set. + */ +#define DDPF_RGBTOYUV 0x00000100l + +/* + * pixel format is YUV - YUV data in pixel format struct is valid + */ +#define DDPF_YUV 0x00000200l + +/* + * pixel format is a z buffer only surface + */ +#define DDPF_ZBUFFER 0x00000400l + +/* + * The surface is 1-bit color indexed. + */ +#define DDPF_PALETTEINDEXED1 0x00000800l + +/* + * The surface is 2-bit color indexed. + */ +#define DDPF_PALETTEINDEXED2 0x00001000l + +/* + * The surface contains Z information in the pixels + */ +#define DDPF_ZPIXELS 0x00002000l + +/* + * The surface contains stencil information along with Z + */ +#define DDPF_STENCILBUFFER 0x00004000l + +/* + * Premultiplied alpha format -- the color components have been + * premultiplied by the alpha component. + */ +#define DDPF_ALPHAPREMULT 0x00008000l + + +/* + * Luminance data in the pixel format is valid. + * Use this flag for luminance-only or luminance+alpha surfaces, + * the bit depth is then ddpf.dwLuminanceBitCount. + */ +#define DDPF_LUMINANCE 0x00020000l + +/* + * Luminance data in the pixel format is valid. + * Use this flag when hanging luminance off bumpmap surfaces, + * the bit mask for the luminance portion of the pixel is then + * ddpf.dwBumpLuminanceBitMask + */ +#define DDPF_BUMPLUMINANCE 0x00040000l + +/* + * Bump map dUdV data in the pixel format is valid. + */ +#define DDPF_BUMPDUDV 0x00080000l + + +/*=========================================================================== + * + * + * DIRECTDRAW CALLBACK FLAGS + * + * + *==========================================================================*/ + +/**************************************************************************** + * + * DIRECTDRAW ENUMSURFACES FLAGS + * + ****************************************************************************/ + +/* + * Enumerate all of the surfaces that meet the search criterion. + */ +#define DDENUMSURFACES_ALL 0x00000001l + +/* + * A search hit is a surface that matches the surface description. + */ +#define DDENUMSURFACES_MATCH 0x00000002l + +/* + * A search hit is a surface that does not match the surface description. + */ +#define DDENUMSURFACES_NOMATCH 0x00000004l + +/* + * Enumerate the first surface that can be created which meets the search criterion. + */ +#define DDENUMSURFACES_CANBECREATED 0x00000008l + +/* + * Enumerate the surfaces that already exist that meet the search criterion. + */ +#define DDENUMSURFACES_DOESEXIST 0x00000010l + + +/**************************************************************************** + * + * DIRECTDRAW SETDISPLAYMODE FLAGS + * + ****************************************************************************/ + +/* + * The desired mode is a standard VGA mode + */ +#define DDSDM_STANDARDVGAMODE 0x00000001l + + +/**************************************************************************** + * + * DIRECTDRAW ENUMDISPLAYMODES FLAGS + * + ****************************************************************************/ + +/* + * Enumerate Modes with different refresh rates. EnumDisplayModes guarantees + * that a particular mode will be enumerated only once. This flag specifies whether + * the refresh rate is taken into account when determining if a mode is unique. + */ +#define DDEDM_REFRESHRATES 0x00000001l + +/* + * Enumerate VGA modes. Specify this flag if you wish to enumerate supported VGA + * modes such as mode 0x13 in addition to the usual ModeX modes (which are always + * enumerated if the application has previously called SetCooperativeLevel with the + * DDSCL_ALLOWMODEX flag set). + */ +#define DDEDM_STANDARDVGAMODES 0x00000002L + + +/**************************************************************************** + * + * DIRECTDRAW SETCOOPERATIVELEVEL FLAGS + * + ****************************************************************************/ + +/* + * Exclusive mode owner will be responsible for the entire primary surface. + * GDI can be ignored. used with DD + */ +#define DDSCL_FULLSCREEN 0x00000001l + +/* + * allow CTRL_ALT_DEL to work while in fullscreen exclusive mode + */ +#define DDSCL_ALLOWREBOOT 0x00000002l + +/* + * prevents DDRAW from modifying the application window. + * prevents DDRAW from minimize/restore the application window on activation. + */ +#define DDSCL_NOWINDOWCHANGES 0x00000004l + +/* + * app wants to work as a regular Windows application + */ +#define DDSCL_NORMAL 0x00000008l + +/* + * app wants exclusive access + */ +#define DDSCL_EXCLUSIVE 0x00000010l + + +/* + * app can deal with non-windows display modes + */ +#define DDSCL_ALLOWMODEX 0x00000040l + +/* + * this window will receive the focus messages + */ +#define DDSCL_SETFOCUSWINDOW 0x00000080l + +/* + * this window is associated with the DDRAW object and will + * cover the screen in fullscreen mode + */ +#define DDSCL_SETDEVICEWINDOW 0x00000100l + +/* + * app wants DDRAW to create a window to be associated with the + * DDRAW object + */ +#define DDSCL_CREATEDEVICEWINDOW 0x00000200l + +/* + * App explicitly asks DDRAW/D3D to be multithread safe. This makes D3D + * take the global crtisec more frequently. + */ +#define DDSCL_MULTITHREADED 0x00000400l + +/* + * App specifies that it would like to keep the FPU set up for optimal Direct3D + * performance (single precision and exceptions disabled) so Direct3D + * does not need to explicitly set the FPU each time. This is assumed by + * default in DirectX 7. See also DDSCL_FPUPRESERVE + */ +#define DDSCL_FPUSETUP 0x00000800l + +/* + * App specifies that it needs either double precision FPU or FPU exceptions + * enabled. This makes Direct3D explicitly set the FPU state eah time it is + * called. Setting the flag will reduce Direct3D performance. The flag is + * assumed by default in DirectX 6 and earlier. See also DDSCL_FPUSETUP + */ +#define DDSCL_FPUPRESERVE 0x00001000l + + +/**************************************************************************** + * + * DIRECTDRAW BLT FLAGS + * + ****************************************************************************/ + +/* + * Use the alpha information in the pixel format or the alpha channel surface + * attached to the destination surface as the alpha channel for this blt. + */ +#define DDBLT_ALPHADEST 0x00000001l + +/* + * Use the dwConstAlphaDest field in the DDBLTFX structure as the alpha channel + * for the destination surface for this blt. + */ +#define DDBLT_ALPHADESTCONSTOVERRIDE 0x00000002l + +/* + * The NEG suffix indicates that the destination surface becomes more + * transparent as the alpha value increases. (0 is opaque) + */ +#define DDBLT_ALPHADESTNEG 0x00000004l + +/* + * Use the lpDDSAlphaDest field in the DDBLTFX structure as the alpha + * channel for the destination for this blt. + */ +#define DDBLT_ALPHADESTSURFACEOVERRIDE 0x00000008l + +/* + * Use the dwAlphaEdgeBlend field in the DDBLTFX structure as the alpha channel + * for the edges of the image that border the color key colors. + */ +#define DDBLT_ALPHAEDGEBLEND 0x00000010l + +/* + * Use the alpha information in the pixel format or the alpha channel surface + * attached to the source surface as the alpha channel for this blt. + */ +#define DDBLT_ALPHASRC 0x00000020l + +/* + * Use the dwConstAlphaSrc field in the DDBLTFX structure as the alpha channel + * for the source for this blt. + */ +#define DDBLT_ALPHASRCCONSTOVERRIDE 0x00000040l + +/* + * The NEG suffix indicates that the source surface becomes more transparent + * as the alpha value increases. (0 is opaque) + */ +#define DDBLT_ALPHASRCNEG 0x00000080l + +/* + * Use the lpDDSAlphaSrc field in the DDBLTFX structure as the alpha channel + * for the source for this blt. + */ +#define DDBLT_ALPHASRCSURFACEOVERRIDE 0x00000100l + +/* + * Do this blt asynchronously through the FIFO in the order received. If + * there is no room in the hardware FIFO fail the call. + */ +#define DDBLT_ASYNC 0x00000200l + +/* + * Uses the dwFillColor field in the DDBLTFX structure as the RGB color + * to fill the destination rectangle on the destination surface with. + */ +#define DDBLT_COLORFILL 0x00000400l + +/* + * Uses the dwDDFX field in the DDBLTFX structure to specify the effects + * to use for the blt. + */ +#define DDBLT_DDFX 0x00000800l + +/* + * Uses the dwDDROPS field in the DDBLTFX structure to specify the ROPS + * that are not part of the Win32 API. + */ +#define DDBLT_DDROPS 0x00001000l + +/* + * Use the color key associated with the destination surface. + */ +#define DDBLT_KEYDEST 0x00002000l + +/* + * Use the dckDestColorkey field in the DDBLTFX structure as the color key + * for the destination surface. + */ +#define DDBLT_KEYDESTOVERRIDE 0x00004000l + +/* + * Use the color key associated with the source surface. + */ +#define DDBLT_KEYSRC 0x00008000l + +/* + * Use the dckSrcColorkey field in the DDBLTFX structure as the color key + * for the source surface. + */ +#define DDBLT_KEYSRCOVERRIDE 0x00010000l + +/* + * Use the dwROP field in the DDBLTFX structure for the raster operation + * for this blt. These ROPs are the same as the ones defined in the Win32 API. + */ +#define DDBLT_ROP 0x00020000l + +/* + * Use the dwRotationAngle field in the DDBLTFX structure as the angle + * (specified in 1/100th of a degree) to rotate the surface. + */ +#define DDBLT_ROTATIONANGLE 0x00040000l + +/* + * Z-buffered blt using the z-buffers attached to the source and destination + * surfaces and the dwZBufferOpCode field in the DDBLTFX structure as the + * z-buffer opcode. + */ +#define DDBLT_ZBUFFER 0x00080000l + +/* + * Z-buffered blt using the dwConstDest Zfield and the dwZBufferOpCode field + * in the DDBLTFX structure as the z-buffer and z-buffer opcode respectively + * for the destination. + */ +#define DDBLT_ZBUFFERDESTCONSTOVERRIDE 0x00100000l + +/* + * Z-buffered blt using the lpDDSDestZBuffer field and the dwZBufferOpCode + * field in the DDBLTFX structure as the z-buffer and z-buffer opcode + * respectively for the destination. + */ +#define DDBLT_ZBUFFERDESTOVERRIDE 0x00200000l + +/* + * Z-buffered blt using the dwConstSrcZ field and the dwZBufferOpCode field + * in the DDBLTFX structure as the z-buffer and z-buffer opcode respectively + * for the source. + */ +#define DDBLT_ZBUFFERSRCCONSTOVERRIDE 0x00400000l + +/* + * Z-buffered blt using the lpDDSSrcZBuffer field and the dwZBufferOpCode + * field in the DDBLTFX structure as the z-buffer and z-buffer opcode + * respectively for the source. + */ +#define DDBLT_ZBUFFERSRCOVERRIDE 0x00800000l + +/* + * wait until the device is ready to handle the blt + * this will cause blt to not return DDERR_WASSTILLDRAWING + */ +#define DDBLT_WAIT 0x01000000l + +/* + * Uses the dwFillDepth field in the DDBLTFX structure as the depth value + * to fill the destination rectangle on the destination Z-buffer surface + * with. + */ +#define DDBLT_DEPTHFILL 0x02000000l + + +/* + * Return immediately (with DDERR_WASSTILLDRAWING) if the device is not + * ready to schedule the blt at the time Blt() is called. + */ +#define DDBLT_DONOTWAIT 0x08000000l + +/* + * These flags indicate a presentation blt (i.e. a blt + * that moves surface contents from an offscreen back buffer to the primary + * surface). The driver is not allowed to "queue" more than three such blts. + * The "end" of the presentation blt is indicated, since the + * blt may be clipped, in which case the runtime will call the driver with + * several blts. All blts (even if not clipped) are tagged with DDBLT_PRESENTATION + * and the last (even if not clipped) additionally with DDBLT_LAST_PRESENTATION. + * Thus the true rule is that the driver must not schedule a DDBLT_PRESENTATION + * blt if there are 3 or more DDBLT_PRESENTLAST blts in the hardware pipe. + * If there are such blts in the pipe, the driver should return DDERR_WASSTILLDRAWING + * until the oldest queued DDBLT_LAST_PRESENTATION blts has been retired (i.e. the + * pixels have been actually written to the primary surface). Once the oldest blt + * has been retired, the driver is free to schedule the current blt. + * The goal is to provide a mechanism whereby the device's hardware queue never + * gets more than 3 frames ahead of the frames being generated by the application. + * When excessive queueing occurs, applications become unusable because the application + * visibly lags user input, and such problems make windowed interactive applications impossible. + * Some drivers may not have sufficient knowledge of their hardware's FIFO to know + * when a certain blt has been retired. Such drivers should code cautiously, and + * simply not allow any frames to be queued at all. DDBLT_LAST_PRESENTATION should cause + * such drivers to return DDERR_WASSTILLDRAWING until the accelerator is completely + * finished- exactly as if the application had called Lock on the source surface + * before calling Blt. + * In other words, the driver is allowed and encouraged to + * generate as much latency as it can, but never more than 3 frames worth. + * Implementation detail: Drivers should count blts against the SOURCE surface, not + * against the primary surface. This enables multiple parallel windowed application + * to function more optimally. + * This flag is passed only to DX8 or higher drivers. + * + * APPLICATIONS DO NOT SET THESE FLAGS. THEY ARE SET BY THE DIRECTDRAW RUNTIME. + * + */ +#define DDBLT_PRESENTATION 0x10000000l +#define DDBLT_LAST_PRESENTATION 0x20000000l + +/* + * If DDBLT_EXTENDED_FLAGS is set, then the driver should re-interpret + * other flags according to the definitions that follow. + * For example, bit 0 (0x00000001L) means DDBLT_ALPHADEST, unless + * DDBLT_EXTENDED_FLAGS is also set, in which case bit 0 means + * DDBLT_EXTENDED_LINEAR_CONTENT. + * Only DirectX9 and higher drivers will be given extended blt flags. + * Only flags explicitly mentioned here should be re-interpreted. + * All other flags retain their original meanings. + * + * List of re-interpreted flags: + * + * Bit Hex value New meaning old meaning + * --------------------------------------------------------------- + * 2 0x00000004 DDBLT_EXTENDED_LINEAR_CONTENT DDBLT_ALPHADESTNEG + * 4 0x00000010 DDBLT_EXTENDED_PRESENTATION_STRETCHFACTOR DDBLT_ALPHAEDGEBLEND + * + * + * NOTE: APPLICATIONS SHOULD NOT SET THIS FLAG. THIS FLAG IS INTENDED + * FOR USE BY THE DIRECT3D RUNTIME. + */ +#define DDBLT_EXTENDED_FLAGS 0x40000000l + +/* + * EXTENDED FLAG. SEE DEFINITION OF DDBLT_EXTENDED_FLAGS. + * This flag indidcates that the source surface contains content in a + * linear color space. The driver may perform gamma correction to the + * desktop color space (i.e. sRGB, gamma 2.2) as part of this blt. + * If the device can perform such a conversion as part of the copy, + * the driver should also set D3DCAPS3_LINEAR_TO_SRGB_PRESENTATION + * + * NOTE: APPLICATIONS SHOULD NOT SET THIS FLAG. THIS FLAG IS INTENDED + * FOR USE BY THE DIRECT3D RUNTIME. Use IDirect3DSwapChain9::Present + * and specify D3DPRESENT_LINEAR_CONTENT in order to use this functionality. + */ +#define DDBLT_EXTENDED_LINEAR_CONTENT 0x00000004l + + +/**************************************************************************** + * + * BLTFAST FLAGS + * + ****************************************************************************/ + +#define DDBLTFAST_NOCOLORKEY 0x00000000 +#define DDBLTFAST_SRCCOLORKEY 0x00000001 +#define DDBLTFAST_DESTCOLORKEY 0x00000002 +#define DDBLTFAST_WAIT 0x00000010 +#define DDBLTFAST_DONOTWAIT 0x00000020 + +/**************************************************************************** + * + * FLIP FLAGS + * + ****************************************************************************/ + +#define DDFLIP_WAIT 0x00000001L + +/* + * Indicates that the target surface contains the even field of video data. + * This flag is only valid with an overlay surface. + */ +#define DDFLIP_EVEN 0x00000002L + +/* + * Indicates that the target surface contains the odd field of video data. + * This flag is only valid with an overlay surface. + */ +#define DDFLIP_ODD 0x00000004L + +/* + * Causes DirectDraw to perform the physical flip immediately and return + * to the application. Typically, what was the front buffer but is now the back + * buffer will still be visible (depending on timing) until the next vertical + * retrace. Subsequent operations involving the two flipped surfaces will + * not check to see if the physical flip has finished (i.e. will not return + * DDERR_WASSTILLDRAWING for that reason (but may for other reasons)). + * This allows an application to perform Flips at a higher frequency than the + * monitor refresh rate, but may introduce visible artifacts. + * Only effective if DDCAPS2_FLIPNOVSYNC is set. If that bit is not set, + * DDFLIP_NOVSYNC has no effect. + */ +#define DDFLIP_NOVSYNC 0x00000008L + + +/* + * Flip Interval Flags. These flags indicate how many vertical retraces to wait between + * each flip. The default is one. DirectDraw will return DDERR_WASSTILLDRAWING for each + * surface involved in the flip until the specified number of vertical retraces has + * ocurred. Only effective if DDCAPS2_FLIPINTERVAL is set. If that bit is not set, + * DDFLIP_INTERVALn has no effect. + */ + +/* + * DirectDraw will flip on every other vertical sync + */ +#define DDFLIP_INTERVAL2 0x02000000L + + +/* + * DirectDraw will flip on every third vertical sync + */ +#define DDFLIP_INTERVAL3 0x03000000L + + +/* + * DirectDraw will flip on every fourth vertical sync + */ +#define DDFLIP_INTERVAL4 0x04000000L + +/* + * DirectDraw will flip and display a main stereo surface + */ +#define DDFLIP_STEREO 0x00000010L + +/* + * On IDirectDrawSurface7 and higher interfaces, the default is DDFLIP_WAIT. If you wish + * to override the default and use time when the accelerator is busy (as denoted by + * the DDERR_WASSTILLDRAWING return code) then use DDFLIP_DONOTWAIT. + */ +#define DDFLIP_DONOTWAIT 0x00000020L + + +/**************************************************************************** + * + * DIRECTDRAW SURFACE OVERLAY FLAGS + * + ****************************************************************************/ + +/* + * Use the alpha information in the pixel format or the alpha channel surface + * attached to the destination surface as the alpha channel for the + * destination overlay. + */ +#define DDOVER_ALPHADEST 0x00000001l + +/* + * Use the dwConstAlphaDest field in the DDOVERLAYFX structure as the + * destination alpha channel for this overlay. + */ +#define DDOVER_ALPHADESTCONSTOVERRIDE 0x00000002l + +/* + * The NEG suffix indicates that the destination surface becomes more + * transparent as the alpha value increases. + */ +#define DDOVER_ALPHADESTNEG 0x00000004l + +/* + * Use the lpDDSAlphaDest field in the DDOVERLAYFX structure as the alpha + * channel destination for this overlay. + */ +#define DDOVER_ALPHADESTSURFACEOVERRIDE 0x00000008l + +/* + * Use the dwAlphaEdgeBlend field in the DDOVERLAYFX structure as the alpha + * channel for the edges of the image that border the color key colors. + */ +#define DDOVER_ALPHAEDGEBLEND 0x00000010l + +/* + * Use the alpha information in the pixel format or the alpha channel surface + * attached to the source surface as the source alpha channel for this overlay. + */ +#define DDOVER_ALPHASRC 0x00000020l + +/* + * Use the dwConstAlphaSrc field in the DDOVERLAYFX structure as the source + * alpha channel for this overlay. + */ +#define DDOVER_ALPHASRCCONSTOVERRIDE 0x00000040l + +/* + * The NEG suffix indicates that the source surface becomes more transparent + * as the alpha value increases. + */ +#define DDOVER_ALPHASRCNEG 0x00000080l + +/* + * Use the lpDDSAlphaSrc field in the DDOVERLAYFX structure as the alpha channel + * source for this overlay. + */ +#define DDOVER_ALPHASRCSURFACEOVERRIDE 0x00000100l + +/* + * Turn this overlay off. + */ +#define DDOVER_HIDE 0x00000200l + +/* + * Use the color key associated with the destination surface. + */ +#define DDOVER_KEYDEST 0x00000400l + +/* + * Use the dckDestColorkey field in the DDOVERLAYFX structure as the color key + * for the destination surface + */ +#define DDOVER_KEYDESTOVERRIDE 0x00000800l + +/* + * Use the color key associated with the source surface. + */ +#define DDOVER_KEYSRC 0x00001000l + +/* + * Use the dckSrcColorkey field in the DDOVERLAYFX structure as the color key + * for the source surface. + */ +#define DDOVER_KEYSRCOVERRIDE 0x00002000l + +/* + * Turn this overlay on. + */ +#define DDOVER_SHOW 0x00004000l + +/* + * Add a dirty rect to an emulated overlayed surface. + */ +#define DDOVER_ADDDIRTYRECT 0x00008000l + +/* + * Redraw all dirty rects on an emulated overlayed surface. + */ +#define DDOVER_REFRESHDIRTYRECTS 0x00010000l + +/* + * Redraw the entire surface on an emulated overlayed surface. + */ +#define DDOVER_REFRESHALL 0x00020000l + + +/* + * Use the overlay FX flags to define special overlay FX + */ +#define DDOVER_DDFX 0x00080000l + +/* + * Autoflip the overlay when ever the video port autoflips + */ +#define DDOVER_AUTOFLIP 0x00100000l + +/* + * Display each field of video port data individually without + * causing any jittery artifacts + */ +#define DDOVER_BOB 0x00200000l + +/* + * Indicates that bob/weave decisions should not be overridden by other + * interfaces. + */ +#define DDOVER_OVERRIDEBOBWEAVE 0x00400000l + +/* + * Indicates that the surface memory is composed of interleaved fields. + */ +#define DDOVER_INTERLEAVED 0x00800000l + +/* + * Indicates that bob will be performed using hardware rather than + * software or emulated. + */ +#define DDOVER_BOBHARDWARE 0x01000000l + +/* + * Indicates that overlay FX structure contains valid ARGB scaling factors. + */ +#define DDOVER_ARGBSCALEFACTORS 0x02000000l + +/* + * Indicates that ARGB scaling factors can be degraded to fit driver capabilities. + */ +#define DDOVER_DEGRADEARGBSCALING 0x04000000l + + +/**************************************************************************** + * + * DIRECTDRAWSURFACE LOCK FLAGS + * + ****************************************************************************/ + +/* + * The default. Set to indicate that Lock should return a valid memory pointer + * to the top of the specified rectangle. If no rectangle is specified then a + * pointer to the top of the surface is returned. + */ +#define DDLOCK_SURFACEMEMORYPTR 0x00000000L // default + +/* + * Set to indicate that Lock should wait until it can obtain a valid memory + * pointer before returning. If this bit is set, Lock will never return + * DDERR_WASSTILLDRAWING. + */ +#define DDLOCK_WAIT 0x00000001L + +/* + * Set if an event handle is being passed to Lock. Lock will trigger the event + * when it can return the surface memory pointer requested. + */ +#define DDLOCK_EVENT 0x00000002L + +/* + * Indicates that the surface being locked will only be read from. + */ +#define DDLOCK_READONLY 0x00000010L + +/* + * Indicates that the surface being locked will only be written to + */ +#define DDLOCK_WRITEONLY 0x00000020L + + +/* + * Indicates that a system wide lock should not be taken when this surface + * is locked. This has several advantages (cursor responsiveness, ability + * to call more Windows functions, easier debugging) when locking video + * memory surfaces. However, an application specifying this flag must + * comply with a number of conditions documented in the help file. + * Furthermore, this flag cannot be specified when locking the primary. + */ +#define DDLOCK_NOSYSLOCK 0x00000800L + +/* + * Used only with Direct3D Vertex Buffer Locks. Indicates that no vertices + * that were referred to in Draw*PrimtiveVB calls since the start of the + * frame (or the last lock without this flag) will be modified during the + * lock. This can be useful when one is only appending data to the vertex + * buffer + */ +#define DDLOCK_NOOVERWRITE 0x00001000L + +/* + * Indicates that no assumptions will be made about the contents of the + * surface or vertex buffer during this lock. + * This enables two things: + * - Direct3D or the driver may provide an alternative memory + * area as the vertex buffer. This is useful when one plans to clear the + * contents of the vertex buffer and fill in new data. + * - Drivers sometimes store surface data in a re-ordered format. + * When the application locks the surface, the driver is forced to un-re-order + * the surface data before allowing the application to see the surface contents. + * This flag is a hint to the driver that it can skip the un-re-ordering process + * since the application plans to overwrite every single pixel in the surface + * or locked rectangle (and so erase any un-re-ordered pixels anyway). + * Applications should always set this flag when they intend to overwrite the entire + * surface or locked rectangle. + */ +#define DDLOCK_DISCARDCONTENTS 0x00002000L + /* + * DDLOCK_OKTOSWAP is an older, less informative name for DDLOCK_DISCARDCONTENTS + */ +#define DDLOCK_OKTOSWAP 0x00002000L + +/* + * On IDirectDrawSurface7 and higher interfaces, the default is DDLOCK_WAIT. If you wish + * to override the default and use time when the accelerator is busy (as denoted by + * the DDERR_WASSTILLDRAWING return code) then use DDLOCK_DONOTWAIT. + */ +#define DDLOCK_DONOTWAIT 0x00004000L + +/* + * This indicates volume texture lock with front and back specified. + */ +#define DDLOCK_HASVOLUMETEXTUREBOXRECT 0x00008000L + +/* + * This indicates that the driver should not update dirty rect information for this lock. + */ +#define DDLOCK_NODIRTYUPDATE 0x00010000L + + +/**************************************************************************** + * + * DIRECTDRAWSURFACE PAGELOCK FLAGS + * + ****************************************************************************/ + +/* + * No flags defined at present + */ + + +/**************************************************************************** + * + * DIRECTDRAWSURFACE PAGEUNLOCK FLAGS + * + ****************************************************************************/ + +/* + * No flags defined at present + */ + + +/**************************************************************************** + * + * DIRECTDRAWSURFACE BLT FX FLAGS + * + ****************************************************************************/ + +/* + * If stretching, use arithmetic stretching along the Y axis for this blt. + */ +#define DDBLTFX_ARITHSTRETCHY 0x00000001l + +/* + * Do this blt mirroring the surface left to right. Spin the + * surface around its y-axis. + */ +#define DDBLTFX_MIRRORLEFTRIGHT 0x00000002l + +/* + * Do this blt mirroring the surface up and down. Spin the surface + * around its x-axis. + */ +#define DDBLTFX_MIRRORUPDOWN 0x00000004l + +/* + * Schedule this blt to avoid tearing. + */ +#define DDBLTFX_NOTEARING 0x00000008l + +/* + * Do this blt rotating the surface one hundred and eighty degrees. + */ +#define DDBLTFX_ROTATE180 0x00000010l + +/* + * Do this blt rotating the surface two hundred and seventy degrees. + */ +#define DDBLTFX_ROTATE270 0x00000020l + +/* + * Do this blt rotating the surface ninety degrees. + */ +#define DDBLTFX_ROTATE90 0x00000040l + +/* + * Do this z blt using dwZBufferLow and dwZBufferHigh as range values + * specified to limit the bits copied from the source surface. + */ +#define DDBLTFX_ZBUFFERRANGE 0x00000080l + +/* + * Do this z blt adding the dwZBufferBaseDest to each of the sources z values + * before comparing it with the desting z values. + */ +#define DDBLTFX_ZBUFFERBASEDEST 0x00000100l + +/**************************************************************************** + * + * DIRECTDRAWSURFACE OVERLAY FX FLAGS + * + ****************************************************************************/ + +/* + * If stretching, use arithmetic stretching along the Y axis for this overlay. + */ +#define DDOVERFX_ARITHSTRETCHY 0x00000001l + +/* + * Mirror the overlay across the vertical axis + */ +#define DDOVERFX_MIRRORLEFTRIGHT 0x00000002l + +/* + * Mirror the overlay across the horizontal axis + */ +#define DDOVERFX_MIRRORUPDOWN 0x00000004l + +/* + * Deinterlace the overlay, if possible + */ +#define DDOVERFX_DEINTERLACE 0x00000008l + + +/**************************************************************************** + * + * DIRECTDRAW WAITFORVERTICALBLANK FLAGS + * + ****************************************************************************/ + +/* + * return when the vertical blank interval begins + */ +#define DDWAITVB_BLOCKBEGIN 0x00000001l + +/* + * set up an event to trigger when the vertical blank begins + */ +#define DDWAITVB_BLOCKBEGINEVENT 0x00000002l + +/* + * return when the vertical blank interval ends and display begins + */ +#define DDWAITVB_BLOCKEND 0x00000004l + +/**************************************************************************** + * + * DIRECTDRAW GETFLIPSTATUS FLAGS + * + ****************************************************************************/ + +/* + * is it OK to flip now? + */ +#define DDGFS_CANFLIP 0x00000001l + +/* + * is the last flip finished? + */ +#define DDGFS_ISFLIPDONE 0x00000002l + +/**************************************************************************** + * + * DIRECTDRAW GETBLTSTATUS FLAGS + * + ****************************************************************************/ + +/* + * is it OK to blt now? + */ +#define DDGBS_CANBLT 0x00000001l + +/* + * is the blt to the surface finished? + */ +#define DDGBS_ISBLTDONE 0x00000002l + + +/**************************************************************************** + * + * DIRECTDRAW ENUMOVERLAYZORDER FLAGS + * + ****************************************************************************/ + +/* + * Enumerate overlays back to front. + */ +#define DDENUMOVERLAYZ_BACKTOFRONT 0x00000000l + +/* + * Enumerate overlays front to back + */ +#define DDENUMOVERLAYZ_FRONTTOBACK 0x00000001l + +/**************************************************************************** + * + * DIRECTDRAW UPDATEOVERLAYZORDER FLAGS + * + ****************************************************************************/ + +/* + * Send overlay to front + */ +#define DDOVERZ_SENDTOFRONT 0x00000000l + +/* + * Send overlay to back + */ +#define DDOVERZ_SENDTOBACK 0x00000001l + +/* + * Move Overlay forward + */ +#define DDOVERZ_MOVEFORWARD 0x00000002l + +/* + * Move Overlay backward + */ +#define DDOVERZ_MOVEBACKWARD 0x00000003l + +/* + * Move Overlay in front of relative surface + */ +#define DDOVERZ_INSERTINFRONTOF 0x00000004l + +/* + * Move Overlay in back of relative surface + */ +#define DDOVERZ_INSERTINBACKOF 0x00000005l + + +/**************************************************************************** + * + * DIRECTDRAW SETGAMMARAMP FLAGS + * + ****************************************************************************/ + +/* + * Request calibrator to adjust the gamma ramp according to the physical + * properties of the display so that the result should appear identical + * on all systems. + */ +#define DDSGR_CALIBRATE 0x00000001L + + +/**************************************************************************** + * + * DIRECTDRAW STARTMODETEST FLAGS + * + ****************************************************************************/ + +/* + * Indicates that the mode being tested has passed + */ +#define DDSMT_ISTESTREQUIRED 0x00000001L + + +/**************************************************************************** + * + * DIRECTDRAW EVALUATEMODE FLAGS + * + ****************************************************************************/ + +/* + * Indicates that the mode being tested has passed + */ +#define DDEM_MODEPASSED 0x00000001L + +/* + * Indicates that the mode being tested has failed + */ +#define DDEM_MODEFAILED 0x00000002L + + +/*=========================================================================== + * + * + * DIRECTDRAW RETURN CODES + * + * The return values from DirectDraw Commands and Surface that return an HRESULT + * are codes from DirectDraw concerning the results of the action + * requested by DirectDraw. + * + *==========================================================================*/ + +/* + * Status is OK + * + * Issued by: DirectDraw Commands and all callbacks + */ +#define DD_OK S_OK +#define DD_FALSE S_FALSE + +/**************************************************************************** + * + * DIRECTDRAW ENUMCALLBACK RETURN VALUES + * + * EnumCallback returns are used to control the flow of the DIRECTDRAW and + * DIRECTDRAWSURFACE object enumerations. They can only be returned by + * enumeration callback routines. + * + ****************************************************************************/ + +/* + * stop the enumeration + */ +#define DDENUMRET_CANCEL 0 + +/* + * continue the enumeration + */ +#define DDENUMRET_OK 1 + +/**************************************************************************** + * + * DIRECTDRAW ERRORS + * + * Errors are represented by negative values and cannot be combined. + * + ****************************************************************************/ + +/* + * This object is already initialized + */ +#define DDERR_ALREADYINITIALIZED MAKE_DDHRESULT( 5 ) + +/* + * This surface can not be attached to the requested surface. + */ +#define DDERR_CANNOTATTACHSURFACE MAKE_DDHRESULT( 10 ) + +/* + * This surface can not be detached from the requested surface. + */ +#define DDERR_CANNOTDETACHSURFACE MAKE_DDHRESULT( 20 ) + +/* + * Support is currently not available. + */ +#define DDERR_CURRENTLYNOTAVAIL MAKE_DDHRESULT( 40 ) + +/* + * An exception was encountered while performing the requested operation + */ +#define DDERR_EXCEPTION MAKE_DDHRESULT( 55 ) + +/* + * Generic failure. + */ +#define DDERR_GENERIC E_FAIL + +/* + * Height of rectangle provided is not a multiple of reqd alignment + */ +#define DDERR_HEIGHTALIGN MAKE_DDHRESULT( 90 ) + +/* + * Unable to match primary surface creation request with existing + * primary surface. + */ +#define DDERR_INCOMPATIBLEPRIMARY MAKE_DDHRESULT( 95 ) + +/* + * One or more of the caps bits passed to the callback are incorrect. + */ +#define DDERR_INVALIDCAPS MAKE_DDHRESULT( 100 ) + +/* + * DirectDraw does not support provided Cliplist. + */ +#define DDERR_INVALIDCLIPLIST MAKE_DDHRESULT( 110 ) + +/* + * DirectDraw does not support the requested mode + */ +#define DDERR_INVALIDMODE MAKE_DDHRESULT( 120 ) + +/* + * DirectDraw received a pointer that was an invalid DIRECTDRAW object. + */ +#define DDERR_INVALIDOBJECT MAKE_DDHRESULT( 130 ) + +/* + * One or more of the parameters passed to the callback function are + * incorrect. + */ +#define DDERR_INVALIDPARAMS E_INVALIDARG + +/* + * pixel format was invalid as specified + */ +#define DDERR_INVALIDPIXELFORMAT MAKE_DDHRESULT( 145 ) + +/* + * Rectangle provided was invalid. + */ +#define DDERR_INVALIDRECT MAKE_DDHRESULT( 150 ) + +/* + * Operation could not be carried out because one or more surfaces are locked + */ +#define DDERR_LOCKEDSURFACES MAKE_DDHRESULT( 160 ) + +/* + * There is no 3D present. + */ +#define DDERR_NO3D MAKE_DDHRESULT( 170 ) + +/* + * Operation could not be carried out because there is no alpha accleration + * hardware present or available. + */ +#define DDERR_NOALPHAHW MAKE_DDHRESULT( 180 ) + +/* + * Operation could not be carried out because there is no stereo + * hardware present or available. + */ +#define DDERR_NOSTEREOHARDWARE MAKE_DDHRESULT( 181 ) + +/* + * Operation could not be carried out because there is no hardware + * present which supports stereo surfaces + */ +#define DDERR_NOSURFACELEFT MAKE_DDHRESULT( 182 ) + + + +/* + * no clip list available + */ +#define DDERR_NOCLIPLIST MAKE_DDHRESULT( 205 ) + +/* + * Operation could not be carried out because there is no color conversion + * hardware present or available. + */ +#define DDERR_NOCOLORCONVHW MAKE_DDHRESULT( 210 ) + +/* + * Create function called without DirectDraw object method SetCooperativeLevel + * being called. + */ +#define DDERR_NOCOOPERATIVELEVELSET MAKE_DDHRESULT( 212 ) + +/* + * Surface doesn't currently have a color key + */ +#define DDERR_NOCOLORKEY MAKE_DDHRESULT( 215 ) + +/* + * Operation could not be carried out because there is no hardware support + * of the dest color key. + */ +#define DDERR_NOCOLORKEYHW MAKE_DDHRESULT( 220 ) + +/* + * No DirectDraw support possible with current display driver + */ +#define DDERR_NODIRECTDRAWSUPPORT MAKE_DDHRESULT( 222 ) + +/* + * Operation requires the application to have exclusive mode but the + * application does not have exclusive mode. + */ +#define DDERR_NOEXCLUSIVEMODE MAKE_DDHRESULT( 225 ) + +/* + * Flipping visible surfaces is not supported. + */ +#define DDERR_NOFLIPHW MAKE_DDHRESULT( 230 ) + +/* + * There is no GDI present. + */ +#define DDERR_NOGDI MAKE_DDHRESULT( 240 ) + +/* + * Operation could not be carried out because there is no hardware present + * or available. + */ +#define DDERR_NOMIRRORHW MAKE_DDHRESULT( 250 ) + +/* + * Requested item was not found + */ +#define DDERR_NOTFOUND MAKE_DDHRESULT( 255 ) + +/* + * Operation could not be carried out because there is no overlay hardware + * present or available. + */ +#define DDERR_NOOVERLAYHW MAKE_DDHRESULT( 260 ) + +/* + * Operation could not be carried out because the source and destination + * rectangles are on the same surface and overlap each other. + */ +#define DDERR_OVERLAPPINGRECTS MAKE_DDHRESULT( 270 ) + +/* + * Operation could not be carried out because there is no appropriate raster + * op hardware present or available. + */ +#define DDERR_NORASTEROPHW MAKE_DDHRESULT( 280 ) + +/* + * Operation could not be carried out because there is no rotation hardware + * present or available. + */ +#define DDERR_NOROTATIONHW MAKE_DDHRESULT( 290 ) + +/* + * Operation could not be carried out because there is no hardware support + * for stretching + */ +#define DDERR_NOSTRETCHHW MAKE_DDHRESULT( 310 ) + +/* + * DirectDrawSurface is not in 4 bit color palette and the requested operation + * requires 4 bit color palette. + */ +#define DDERR_NOT4BITCOLOR MAKE_DDHRESULT( 316 ) + +/* + * DirectDrawSurface is not in 4 bit color index palette and the requested + * operation requires 4 bit color index palette. + */ +#define DDERR_NOT4BITCOLORINDEX MAKE_DDHRESULT( 317 ) + +/* + * DirectDraw Surface is not in 8 bit color mode and the requested operation + * requires 8 bit color. + */ +#define DDERR_NOT8BITCOLOR MAKE_DDHRESULT( 320 ) + +/* + * Operation could not be carried out because there is no texture mapping + * hardware present or available. + */ +#define DDERR_NOTEXTUREHW MAKE_DDHRESULT( 330 ) + +/* + * Operation could not be carried out because there is no hardware support + * for vertical blank synchronized operations. + */ +#define DDERR_NOVSYNCHW MAKE_DDHRESULT( 335 ) + +/* + * Operation could not be carried out because there is no hardware support + * for zbuffer blting. + */ +#define DDERR_NOZBUFFERHW MAKE_DDHRESULT( 340 ) + +/* + * Overlay surfaces could not be z layered based on their BltOrder because + * the hardware does not support z layering of overlays. + */ +#define DDERR_NOZOVERLAYHW MAKE_DDHRESULT( 350 ) + +/* + * The hardware needed for the requested operation has already been + * allocated. + */ +#define DDERR_OUTOFCAPS MAKE_DDHRESULT( 360 ) + +/* + * DirectDraw does not have enough memory to perform the operation. + */ +#define DDERR_OUTOFMEMORY E_OUTOFMEMORY + +/* + * DirectDraw does not have enough memory to perform the operation. + */ +#define DDERR_OUTOFVIDEOMEMORY MAKE_DDHRESULT( 380 ) + +/* + * hardware does not support clipped overlays + */ +#define DDERR_OVERLAYCANTCLIP MAKE_DDHRESULT( 382 ) + +/* + * Can only have ony color key active at one time for overlays + */ +#define DDERR_OVERLAYCOLORKEYONLYONEACTIVE MAKE_DDHRESULT( 384 ) + +/* + * Access to this palette is being refused because the palette is already + * locked by another thread. + */ +#define DDERR_PALETTEBUSY MAKE_DDHRESULT( 387 ) + +/* + * No src color key specified for this operation. + */ +#define DDERR_COLORKEYNOTSET MAKE_DDHRESULT( 400 ) + +/* + * This surface is already attached to the surface it is being attached to. + */ +#define DDERR_SURFACEALREADYATTACHED MAKE_DDHRESULT( 410 ) + +/* + * This surface is already a dependency of the surface it is being made a + * dependency of. + */ +#define DDERR_SURFACEALREADYDEPENDENT MAKE_DDHRESULT( 420 ) + +/* + * Access to this surface is being refused because the surface is already + * locked by another thread. + */ +#define DDERR_SURFACEBUSY MAKE_DDHRESULT( 430 ) + +/* + * Access to this surface is being refused because no driver exists + * which can supply a pointer to the surface. + * This is most likely to happen when attempting to lock the primary + * surface when no DCI provider is present. + * Will also happen on attempts to lock an optimized surface. + */ +#define DDERR_CANTLOCKSURFACE MAKE_DDHRESULT( 435 ) + +/* + * Access to Surface refused because Surface is obscured. + */ +#define DDERR_SURFACEISOBSCURED MAKE_DDHRESULT( 440 ) + +/* + * Access to this surface is being refused because the surface is gone. + * The DIRECTDRAWSURFACE object representing this surface should + * have Restore called on it. + */ +#define DDERR_SURFACELOST MAKE_DDHRESULT( 450 ) + +/* + * The requested surface is not attached. + */ +#define DDERR_SURFACENOTATTACHED MAKE_DDHRESULT( 460 ) + +/* + * Height requested by DirectDraw is too large. + */ +#define DDERR_TOOBIGHEIGHT MAKE_DDHRESULT( 470 ) + +/* + * Size requested by DirectDraw is too large -- The individual height and + * width are OK. + */ +#define DDERR_TOOBIGSIZE MAKE_DDHRESULT( 480 ) + +/* + * Width requested by DirectDraw is too large. + */ +#define DDERR_TOOBIGWIDTH MAKE_DDHRESULT( 490 ) + +/* + * Action not supported. + */ +#define DDERR_UNSUPPORTED E_NOTIMPL + +/* + * Pixel format requested is unsupported by DirectDraw + */ +#define DDERR_UNSUPPORTEDFORMAT MAKE_DDHRESULT( 510 ) + +/* + * Bitmask in the pixel format requested is unsupported by DirectDraw + */ +#define DDERR_UNSUPPORTEDMASK MAKE_DDHRESULT( 520 ) + +/* + * The specified stream contains invalid data + */ +#define DDERR_INVALIDSTREAM MAKE_DDHRESULT( 521 ) + +/* + * vertical blank is in progress + */ +#define DDERR_VERTICALBLANKINPROGRESS MAKE_DDHRESULT( 537 ) + +/* + * Informs DirectDraw that the previous Blt which is transfering information + * to or from this Surface is incomplete. + */ +#define DDERR_WASSTILLDRAWING MAKE_DDHRESULT( 540 ) + + +/* + * The specified surface type requires specification of the COMPLEX flag + */ +#define DDERR_DDSCAPSCOMPLEXREQUIRED MAKE_DDHRESULT( 542 ) + + +/* + * Rectangle provided was not horizontally aligned on reqd. boundary + */ +#define DDERR_XALIGN MAKE_DDHRESULT( 560 ) + +/* + * The GUID passed to DirectDrawCreate is not a valid DirectDraw driver + * identifier. + */ +#define DDERR_INVALIDDIRECTDRAWGUID MAKE_DDHRESULT( 561 ) + +/* + * A DirectDraw object representing this driver has already been created + * for this process. + */ +#define DDERR_DIRECTDRAWALREADYCREATED MAKE_DDHRESULT( 562 ) + +/* + * A hardware only DirectDraw object creation was attempted but the driver + * did not support any hardware. + */ +#define DDERR_NODIRECTDRAWHW MAKE_DDHRESULT( 563 ) + +/* + * this process already has created a primary surface + */ +#define DDERR_PRIMARYSURFACEALREADYEXISTS MAKE_DDHRESULT( 564 ) + +/* + * software emulation not available. + */ +#define DDERR_NOEMULATION MAKE_DDHRESULT( 565 ) + +/* + * region passed to Clipper::GetClipList is too small. + */ +#define DDERR_REGIONTOOSMALL MAKE_DDHRESULT( 566 ) + +/* + * an attempt was made to set a clip list for a clipper objec that + * is already monitoring an hwnd. + */ +#define DDERR_CLIPPERISUSINGHWND MAKE_DDHRESULT( 567 ) + +/* + * No clipper object attached to surface object + */ +#define DDERR_NOCLIPPERATTACHED MAKE_DDHRESULT( 568 ) + +/* + * Clipper notification requires an HWND or + * no HWND has previously been set as the CooperativeLevel HWND. + */ +#define DDERR_NOHWND MAKE_DDHRESULT( 569 ) + +/* + * HWND used by DirectDraw CooperativeLevel has been subclassed, + * this prevents DirectDraw from restoring state. + */ +#define DDERR_HWNDSUBCLASSED MAKE_DDHRESULT( 570 ) + +/* + * The CooperativeLevel HWND has already been set. + * It can not be reset while the process has surfaces or palettes created. + */ +#define DDERR_HWNDALREADYSET MAKE_DDHRESULT( 571 ) + +/* + * No palette object attached to this surface. + */ +#define DDERR_NOPALETTEATTACHED MAKE_DDHRESULT( 572 ) + +/* + * No hardware support for 16 or 256 color palettes. + */ +#define DDERR_NOPALETTEHW MAKE_DDHRESULT( 573 ) + +/* + * If a clipper object is attached to the source surface passed into a + * BltFast call. + */ +#define DDERR_BLTFASTCANTCLIP MAKE_DDHRESULT( 574 ) + +/* + * No blter. + */ +#define DDERR_NOBLTHW MAKE_DDHRESULT( 575 ) + +/* + * No DirectDraw ROP hardware. + */ +#define DDERR_NODDROPSHW MAKE_DDHRESULT( 576 ) + +/* + * returned when GetOverlayPosition is called on a hidden overlay + */ +#define DDERR_OVERLAYNOTVISIBLE MAKE_DDHRESULT( 577 ) + +/* + * returned when GetOverlayPosition is called on a overlay that UpdateOverlay + * has never been called on to establish a destionation. + */ +#define DDERR_NOOVERLAYDEST MAKE_DDHRESULT( 578 ) + +/* + * returned when the position of the overlay on the destionation is no longer + * legal for that destionation. + */ +#define DDERR_INVALIDPOSITION MAKE_DDHRESULT( 579 ) + +/* + * returned when an overlay member is called for a non-overlay surface + */ +#define DDERR_NOTAOVERLAYSURFACE MAKE_DDHRESULT( 580 ) + +/* + * An attempt was made to set the cooperative level when it was already + * set to exclusive. + */ +#define DDERR_EXCLUSIVEMODEALREADYSET MAKE_DDHRESULT( 581 ) + +/* + * An attempt has been made to flip a surface that is not flippable. + */ +#define DDERR_NOTFLIPPABLE MAKE_DDHRESULT( 582 ) + +/* + * Can't duplicate primary & 3D surfaces, or surfaces that are implicitly + * created. + */ +#define DDERR_CANTDUPLICATE MAKE_DDHRESULT( 583 ) + +/* + * Surface was not locked. An attempt to unlock a surface that was not + * locked at all, or by this process, has been attempted. + */ +#define DDERR_NOTLOCKED MAKE_DDHRESULT( 584 ) + +/* + * Windows can not create any more DCs, or a DC was requested for a paltte-indexed + * surface when the surface had no palette AND the display mode was not palette-indexed + * (in this case DirectDraw cannot select a proper palette into the DC) + */ +#define DDERR_CANTCREATEDC MAKE_DDHRESULT( 585 ) + +/* + * No DC was ever created for this surface. + */ +#define DDERR_NODC MAKE_DDHRESULT( 586 ) + +/* + * This surface can not be restored because it was created in a different + * mode. + */ +#define DDERR_WRONGMODE MAKE_DDHRESULT( 587 ) + +/* + * This surface can not be restored because it is an implicitly created + * surface. + */ +#define DDERR_IMPLICITLYCREATED MAKE_DDHRESULT( 588 ) + +/* + * The surface being used is not a palette-based surface + */ +#define DDERR_NOTPALETTIZED MAKE_DDHRESULT( 589 ) + + +/* + * The display is currently in an unsupported mode + */ +#define DDERR_UNSUPPORTEDMODE MAKE_DDHRESULT( 590 ) + +/* + * Operation could not be carried out because there is no mip-map + * texture mapping hardware present or available. + */ +#define DDERR_NOMIPMAPHW MAKE_DDHRESULT( 591 ) + +/* + * The requested action could not be performed because the surface was of + * the wrong type. + */ +#define DDERR_INVALIDSURFACETYPE MAKE_DDHRESULT( 592 ) + + +/* + * Device does not support optimized surfaces, therefore no video memory optimized surfaces + */ +#define DDERR_NOOPTIMIZEHW MAKE_DDHRESULT( 600 ) + +/* + * Surface is an optimized surface, but has not yet been allocated any memory + */ +#define DDERR_NOTLOADED MAKE_DDHRESULT( 601 ) + +/* + * Attempt was made to create or set a device window without first setting + * the focus window + */ +#define DDERR_NOFOCUSWINDOW MAKE_DDHRESULT( 602 ) + +/* + * Attempt was made to set a palette on a mipmap sublevel + */ +#define DDERR_NOTONMIPMAPSUBLEVEL MAKE_DDHRESULT( 603 ) + +/* + * A DC has already been returned for this surface. Only one DC can be + * retrieved per surface. + */ +#define DDERR_DCALREADYCREATED MAKE_DDHRESULT( 620 ) + +/* + * An attempt was made to allocate non-local video memory from a device + * that does not support non-local video memory. + */ +#define DDERR_NONONLOCALVIDMEM MAKE_DDHRESULT( 630 ) + +/* + * The attempt to page lock a surface failed. + */ +#define DDERR_CANTPAGELOCK MAKE_DDHRESULT( 640 ) + + +/* + * The attempt to page unlock a surface failed. + */ +#define DDERR_CANTPAGEUNLOCK MAKE_DDHRESULT( 660 ) + +/* + * An attempt was made to page unlock a surface with no outstanding page locks. + */ +#define DDERR_NOTPAGELOCKED MAKE_DDHRESULT( 680 ) + +/* + * There is more data available than the specified buffer size could hold + */ +#define DDERR_MOREDATA MAKE_DDHRESULT( 690 ) + +/* + * The data has expired and is therefore no longer valid. + */ +#define DDERR_EXPIRED MAKE_DDHRESULT( 691 ) + +/* + * The mode test has finished executing. + */ +#define DDERR_TESTFINISHED MAKE_DDHRESULT( 692 ) + +/* + * The mode test has switched to a new mode. + */ +#define DDERR_NEWMODE MAKE_DDHRESULT( 693 ) + +/* + * D3D has not yet been initialized. + */ +#define DDERR_D3DNOTINITIALIZED MAKE_DDHRESULT( 694 ) + +/* + * The video port is not active + */ +#define DDERR_VIDEONOTACTIVE MAKE_DDHRESULT( 695 ) + +/* + * The monitor does not have EDID data. + */ +#define DDERR_NOMONITORINFORMATION MAKE_DDHRESULT( 696 ) + +/* + * The driver does not enumerate display mode refresh rates. + */ +#define DDERR_NODRIVERSUPPORT MAKE_DDHRESULT( 697 ) + +/* + * Surfaces created by one direct draw device cannot be used directly by + * another direct draw device. + */ +#define DDERR_DEVICEDOESNTOWNSURFACE MAKE_DDHRESULT( 699 ) + + + +/* + * An attempt was made to invoke an interface member of a DirectDraw object + * created by CoCreateInstance() before it was initialized. + */ +#define DDERR_NOTINITIALIZED CO_E_NOTINITIALIZED + + +/* Alpha bit depth constants */ + + +#ifdef __cplusplus +}; +#endif + +#ifdef ENABLE_NAMELESS_UNION_PRAGMA +#pragma warning(default:4201) +#endif + +#endif //__DDRAW_INCLUDED__ + + diff --git a/desmume/src/windows/directx/ddraw.lib b/src/windows/directx/ddraw.lib similarity index 100% rename from desmume/src/windows/directx/ddraw.lib rename to src/windows/directx/ddraw.lib diff --git a/desmume/src/windows/directx/dinput.h b/src/windows/directx/dinput.h similarity index 98% rename from desmume/src/windows/directx/dinput.h rename to src/windows/directx/dinput.h index 5aac25638..bf74e163c 100644 --- a/desmume/src/windows/directx/dinput.h +++ b/src/windows/directx/dinput.h @@ -1,4417 +1,4417 @@ -/**************************************************************************** - * - * Copyright (C) 1996-2000 Microsoft Corporation. All Rights Reserved. - * - * File: dinput.h - * Content: DirectInput include file - * - ****************************************************************************/ - -#ifndef __DINPUT_INCLUDED__ -#define __DINPUT_INCLUDED__ - -#ifndef DIJ_RINGZERO - -#ifdef _WIN32 -#define COM_NO_WINDOWS_H -#include -#endif - -#endif /* DIJ_RINGZERO */ - -#ifdef __cplusplus -extern "C" { -#endif - - - - - -/* - * To build applications for older versions of DirectInput - * - * #define DIRECTINPUT_VERSION [ 0x0300 | 0x0500 | 0x0700 ] - * - * before #include . By default, #include - * will produce a DirectX 8-compatible header file. - * - */ - -#define DIRECTINPUT_HEADER_VERSION 0x0800 -#ifndef DIRECTINPUT_VERSION -#define DIRECTINPUT_VERSION DIRECTINPUT_HEADER_VERSION -#pragma message(__FILE__ ": DIRECTINPUT_VERSION undefined. Defaulting to version 0x0800") -#endif - -#ifndef DIJ_RINGZERO - -/**************************************************************************** - * - * Class IDs - * - ****************************************************************************/ - -DEFINE_GUID(CLSID_DirectInput, 0x25E609E0,0xB259,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); -DEFINE_GUID(CLSID_DirectInputDevice, 0x25E609E1,0xB259,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); - -DEFINE_GUID(CLSID_DirectInput8, 0x25E609E4,0xB259,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); -DEFINE_GUID(CLSID_DirectInputDevice8,0x25E609E5,0xB259,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); - -/**************************************************************************** - * - * Interfaces - * - ****************************************************************************/ - -DEFINE_GUID(IID_IDirectInputA, 0x89521360,0xAA8A,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); -DEFINE_GUID(IID_IDirectInputW, 0x89521361,0xAA8A,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); -DEFINE_GUID(IID_IDirectInput2A, 0x5944E662,0xAA8A,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); -DEFINE_GUID(IID_IDirectInput2W, 0x5944E663,0xAA8A,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); -DEFINE_GUID(IID_IDirectInput7A, 0x9A4CB684,0x236D,0x11D3,0x8E,0x9D,0x00,0xC0,0x4F,0x68,0x44,0xAE); -DEFINE_GUID(IID_IDirectInput7W, 0x9A4CB685,0x236D,0x11D3,0x8E,0x9D,0x00,0xC0,0x4F,0x68,0x44,0xAE); -DEFINE_GUID(IID_IDirectInput8A, 0xBF798030,0x483A,0x4DA2,0xAA,0x99,0x5D,0x64,0xED,0x36,0x97,0x00); -DEFINE_GUID(IID_IDirectInput8W, 0xBF798031,0x483A,0x4DA2,0xAA,0x99,0x5D,0x64,0xED,0x36,0x97,0x00); -DEFINE_GUID(IID_IDirectInputDeviceA, 0x5944E680,0xC92E,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); -DEFINE_GUID(IID_IDirectInputDeviceW, 0x5944E681,0xC92E,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); -DEFINE_GUID(IID_IDirectInputDevice2A,0x5944E682,0xC92E,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); -DEFINE_GUID(IID_IDirectInputDevice2W,0x5944E683,0xC92E,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); -DEFINE_GUID(IID_IDirectInputDevice7A,0x57D7C6BC,0x2356,0x11D3,0x8E,0x9D,0x00,0xC0,0x4F,0x68,0x44,0xAE); -DEFINE_GUID(IID_IDirectInputDevice7W,0x57D7C6BD,0x2356,0x11D3,0x8E,0x9D,0x00,0xC0,0x4F,0x68,0x44,0xAE); -DEFINE_GUID(IID_IDirectInputDevice8A,0x54D41080,0xDC15,0x4833,0xA4,0x1B,0x74,0x8F,0x73,0xA3,0x81,0x79); -DEFINE_GUID(IID_IDirectInputDevice8W,0x54D41081,0xDC15,0x4833,0xA4,0x1B,0x74,0x8F,0x73,0xA3,0x81,0x79); -DEFINE_GUID(IID_IDirectInputEffect, 0xE7E1F7C0,0x88D2,0x11D0,0x9A,0xD0,0x00,0xA0,0xC9,0xA0,0x6E,0x35); - -/**************************************************************************** - * - * Predefined object types - * - ****************************************************************************/ - -DEFINE_GUID(GUID_XAxis, 0xA36D02E0,0xC9F3,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); -DEFINE_GUID(GUID_YAxis, 0xA36D02E1,0xC9F3,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); -DEFINE_GUID(GUID_ZAxis, 0xA36D02E2,0xC9F3,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); -DEFINE_GUID(GUID_RxAxis, 0xA36D02F4,0xC9F3,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); -DEFINE_GUID(GUID_RyAxis, 0xA36D02F5,0xC9F3,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); -DEFINE_GUID(GUID_RzAxis, 0xA36D02E3,0xC9F3,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); -DEFINE_GUID(GUID_Slider, 0xA36D02E4,0xC9F3,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); - -DEFINE_GUID(GUID_Button, 0xA36D02F0,0xC9F3,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); -DEFINE_GUID(GUID_Key, 0x55728220,0xD33C,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); - -DEFINE_GUID(GUID_POV, 0xA36D02F2,0xC9F3,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); - -DEFINE_GUID(GUID_Unknown, 0xA36D02F3,0xC9F3,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); - -/**************************************************************************** - * - * Predefined product GUIDs - * - ****************************************************************************/ - -DEFINE_GUID(GUID_SysMouse, 0x6F1D2B60,0xD5A0,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); -DEFINE_GUID(GUID_SysKeyboard,0x6F1D2B61,0xD5A0,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); -DEFINE_GUID(GUID_Joystick ,0x6F1D2B70,0xD5A0,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); -DEFINE_GUID(GUID_SysMouseEm, 0x6F1D2B80,0xD5A0,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); -DEFINE_GUID(GUID_SysMouseEm2,0x6F1D2B81,0xD5A0,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); -DEFINE_GUID(GUID_SysKeyboardEm, 0x6F1D2B82,0xD5A0,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); -DEFINE_GUID(GUID_SysKeyboardEm2,0x6F1D2B83,0xD5A0,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); - -/**************************************************************************** - * - * Predefined force feedback effects - * - ****************************************************************************/ - -DEFINE_GUID(GUID_ConstantForce, 0x13541C20,0x8E33,0x11D0,0x9A,0xD0,0x00,0xA0,0xC9,0xA0,0x6E,0x35); -DEFINE_GUID(GUID_RampForce, 0x13541C21,0x8E33,0x11D0,0x9A,0xD0,0x00,0xA0,0xC9,0xA0,0x6E,0x35); -DEFINE_GUID(GUID_Square, 0x13541C22,0x8E33,0x11D0,0x9A,0xD0,0x00,0xA0,0xC9,0xA0,0x6E,0x35); -DEFINE_GUID(GUID_Sine, 0x13541C23,0x8E33,0x11D0,0x9A,0xD0,0x00,0xA0,0xC9,0xA0,0x6E,0x35); -DEFINE_GUID(GUID_Triangle, 0x13541C24,0x8E33,0x11D0,0x9A,0xD0,0x00,0xA0,0xC9,0xA0,0x6E,0x35); -DEFINE_GUID(GUID_SawtoothUp, 0x13541C25,0x8E33,0x11D0,0x9A,0xD0,0x00,0xA0,0xC9,0xA0,0x6E,0x35); -DEFINE_GUID(GUID_SawtoothDown, 0x13541C26,0x8E33,0x11D0,0x9A,0xD0,0x00,0xA0,0xC9,0xA0,0x6E,0x35); -DEFINE_GUID(GUID_Spring, 0x13541C27,0x8E33,0x11D0,0x9A,0xD0,0x00,0xA0,0xC9,0xA0,0x6E,0x35); -DEFINE_GUID(GUID_Damper, 0x13541C28,0x8E33,0x11D0,0x9A,0xD0,0x00,0xA0,0xC9,0xA0,0x6E,0x35); -DEFINE_GUID(GUID_Inertia, 0x13541C29,0x8E33,0x11D0,0x9A,0xD0,0x00,0xA0,0xC9,0xA0,0x6E,0x35); -DEFINE_GUID(GUID_Friction, 0x13541C2A,0x8E33,0x11D0,0x9A,0xD0,0x00,0xA0,0xC9,0xA0,0x6E,0x35); -DEFINE_GUID(GUID_CustomForce, 0x13541C2B,0x8E33,0x11D0,0x9A,0xD0,0x00,0xA0,0xC9,0xA0,0x6E,0x35); - -#endif /* DIJ_RINGZERO */ - -/**************************************************************************** - * - * Interfaces and Structures... - * - ****************************************************************************/ - -#if(DIRECTINPUT_VERSION >= 0x0500) - -/**************************************************************************** - * - * IDirectInputEffect - * - ****************************************************************************/ - -#define DIEFT_ALL 0x00000000 - -#define DIEFT_CONSTANTFORCE 0x00000001 -#define DIEFT_RAMPFORCE 0x00000002 -#define DIEFT_PERIODIC 0x00000003 -#define DIEFT_CONDITION 0x00000004 -#define DIEFT_CUSTOMFORCE 0x00000005 -#define DIEFT_HARDWARE 0x000000FF -#define DIEFT_FFATTACK 0x00000200 -#define DIEFT_FFFADE 0x00000400 -#define DIEFT_SATURATION 0x00000800 -#define DIEFT_POSNEGCOEFFICIENTS 0x00001000 -#define DIEFT_POSNEGSATURATION 0x00002000 -#define DIEFT_DEADBAND 0x00004000 -#define DIEFT_STARTDELAY 0x00008000 -#define DIEFT_GETTYPE(n) LOBYTE(n) - -#define DI_DEGREES 100 -#define DI_FFNOMINALMAX 10000 -#define DI_SECONDS 1000000 - -typedef struct DICONSTANTFORCE { - LONG lMagnitude; -} DICONSTANTFORCE, *LPDICONSTANTFORCE; -typedef const DICONSTANTFORCE *LPCDICONSTANTFORCE; - -typedef struct DIRAMPFORCE { - LONG lStart; - LONG lEnd; -} DIRAMPFORCE, *LPDIRAMPFORCE; -typedef const DIRAMPFORCE *LPCDIRAMPFORCE; - -typedef struct DIPERIODIC { - DWORD dwMagnitude; - LONG lOffset; - DWORD dwPhase; - DWORD dwPeriod; -} DIPERIODIC, *LPDIPERIODIC; -typedef const DIPERIODIC *LPCDIPERIODIC; - -typedef struct DICONDITION { - LONG lOffset; - LONG lPositiveCoefficient; - LONG lNegativeCoefficient; - DWORD dwPositiveSaturation; - DWORD dwNegativeSaturation; - LONG lDeadBand; -} DICONDITION, *LPDICONDITION; -typedef const DICONDITION *LPCDICONDITION; - -typedef struct DICUSTOMFORCE { - DWORD cChannels; - DWORD dwSamplePeriod; - DWORD cSamples; - LPLONG rglForceData; -} DICUSTOMFORCE, *LPDICUSTOMFORCE; -typedef const DICUSTOMFORCE *LPCDICUSTOMFORCE; - - -typedef struct DIENVELOPE { - DWORD dwSize; /* sizeof(DIENVELOPE) */ - DWORD dwAttackLevel; - DWORD dwAttackTime; /* Microseconds */ - DWORD dwFadeLevel; - DWORD dwFadeTime; /* Microseconds */ -} DIENVELOPE, *LPDIENVELOPE; -typedef const DIENVELOPE *LPCDIENVELOPE; - - -/* This structure is defined for DirectX 5.0 compatibility */ -typedef struct DIEFFECT_DX5 { - DWORD dwSize; /* sizeof(DIEFFECT_DX5) */ - DWORD dwFlags; /* DIEFF_* */ - DWORD dwDuration; /* Microseconds */ - DWORD dwSamplePeriod; /* Microseconds */ - DWORD dwGain; - DWORD dwTriggerButton; /* or DIEB_NOTRIGGER */ - DWORD dwTriggerRepeatInterval; /* Microseconds */ - DWORD cAxes; /* Number of axes */ - LPDWORD rgdwAxes; /* Array of axes */ - LPLONG rglDirection; /* Array of directions */ - LPDIENVELOPE lpEnvelope; /* Optional */ - DWORD cbTypeSpecificParams; /* Size of params */ - LPVOID lpvTypeSpecificParams; /* Pointer to params */ -} DIEFFECT_DX5, *LPDIEFFECT_DX5; -typedef const DIEFFECT_DX5 *LPCDIEFFECT_DX5; - -typedef struct DIEFFECT { - DWORD dwSize; /* sizeof(DIEFFECT) */ - DWORD dwFlags; /* DIEFF_* */ - DWORD dwDuration; /* Microseconds */ - DWORD dwSamplePeriod; /* Microseconds */ - DWORD dwGain; - DWORD dwTriggerButton; /* or DIEB_NOTRIGGER */ - DWORD dwTriggerRepeatInterval; /* Microseconds */ - DWORD cAxes; /* Number of axes */ - LPDWORD rgdwAxes; /* Array of axes */ - LPLONG rglDirection; /* Array of directions */ - LPDIENVELOPE lpEnvelope; /* Optional */ - DWORD cbTypeSpecificParams; /* Size of params */ - LPVOID lpvTypeSpecificParams; /* Pointer to params */ -#if(DIRECTINPUT_VERSION >= 0x0600) - DWORD dwStartDelay; /* Microseconds */ -#endif /* DIRECTINPUT_VERSION >= 0x0600 */ -} DIEFFECT, *LPDIEFFECT; -typedef DIEFFECT DIEFFECT_DX6; -typedef LPDIEFFECT LPDIEFFECT_DX6; -typedef const DIEFFECT *LPCDIEFFECT; - - -#if(DIRECTINPUT_VERSION >= 0x0700) -#ifndef DIJ_RINGZERO -typedef struct DIFILEEFFECT{ - DWORD dwSize; - GUID GuidEffect; - LPCDIEFFECT lpDiEffect; - CHAR szFriendlyName[MAX_PATH]; -}DIFILEEFFECT, *LPDIFILEEFFECT; -typedef const DIFILEEFFECT *LPCDIFILEEFFECT; -typedef BOOL (FAR PASCAL * LPDIENUMEFFECTSINFILECALLBACK)(LPCDIFILEEFFECT , LPVOID); -#endif /* DIJ_RINGZERO */ -#endif /* DIRECTINPUT_VERSION >= 0x0700 */ - -#define DIEFF_OBJECTIDS 0x00000001 -#define DIEFF_OBJECTOFFSETS 0x00000002 -#define DIEFF_CARTESIAN 0x00000010 -#define DIEFF_POLAR 0x00000020 -#define DIEFF_SPHERICAL 0x00000040 - -#define DIEP_DURATION 0x00000001 -#define DIEP_SAMPLEPERIOD 0x00000002 -#define DIEP_GAIN 0x00000004 -#define DIEP_TRIGGERBUTTON 0x00000008 -#define DIEP_TRIGGERREPEATINTERVAL 0x00000010 -#define DIEP_AXES 0x00000020 -#define DIEP_DIRECTION 0x00000040 -#define DIEP_ENVELOPE 0x00000080 -#define DIEP_TYPESPECIFICPARAMS 0x00000100 -#if(DIRECTINPUT_VERSION >= 0x0600) -#define DIEP_STARTDELAY 0x00000200 -#define DIEP_ALLPARAMS_DX5 0x000001FF -#define DIEP_ALLPARAMS 0x000003FF -#else /* DIRECTINPUT_VERSION < 0x0600 */ -#define DIEP_ALLPARAMS 0x000001FF -#endif /* DIRECTINPUT_VERSION < 0x0600 */ -#define DIEP_START 0x20000000 -#define DIEP_NORESTART 0x40000000 -#define DIEP_NODOWNLOAD 0x80000000 -#define DIEB_NOTRIGGER 0xFFFFFFFF - -#define DIES_SOLO 0x00000001 -#define DIES_NODOWNLOAD 0x80000000 - -#define DIEGES_PLAYING 0x00000001 -#define DIEGES_EMULATED 0x00000002 - -typedef struct DIEFFESCAPE { - DWORD dwSize; - DWORD dwCommand; - LPVOID lpvInBuffer; - DWORD cbInBuffer; - LPVOID lpvOutBuffer; - DWORD cbOutBuffer; -} DIEFFESCAPE, *LPDIEFFESCAPE; - -#ifndef DIJ_RINGZERO - -#undef INTERFACE -#define INTERFACE IDirectInputEffect - -DECLARE_INTERFACE_(IDirectInputEffect, IUnknown) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID * ppvObj) PURE; - STDMETHOD_(ULONG,AddRef)(THIS) PURE; - STDMETHOD_(ULONG,Release)(THIS) PURE; - - /*** IDirectInputEffect methods ***/ - STDMETHOD(Initialize)(THIS_ HINSTANCE,DWORD,REFGUID) PURE; - STDMETHOD(GetEffectGuid)(THIS_ LPGUID) PURE; - STDMETHOD(GetParameters)(THIS_ LPDIEFFECT,DWORD) PURE; - STDMETHOD(SetParameters)(THIS_ LPCDIEFFECT,DWORD) PURE; - STDMETHOD(Start)(THIS_ DWORD,DWORD) PURE; - STDMETHOD(Stop)(THIS) PURE; - STDMETHOD(GetEffectStatus)(THIS_ LPDWORD) PURE; - STDMETHOD(Download)(THIS) PURE; - STDMETHOD(Unload)(THIS) PURE; - STDMETHOD(Escape)(THIS_ LPDIEFFESCAPE) PURE; -}; - -typedef struct IDirectInputEffect *LPDIRECTINPUTEFFECT; - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectInputEffect_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) -#define IDirectInputEffect_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirectInputEffect_Release(p) (p)->lpVtbl->Release(p) -#define IDirectInputEffect_Initialize(p,a,b,c) (p)->lpVtbl->Initialize(p,a,b,c) -#define IDirectInputEffect_GetEffectGuid(p,a) (p)->lpVtbl->GetEffectGuid(p,a) -#define IDirectInputEffect_GetParameters(p,a,b) (p)->lpVtbl->GetParameters(p,a,b) -#define IDirectInputEffect_SetParameters(p,a,b) (p)->lpVtbl->SetParameters(p,a,b) -#define IDirectInputEffect_Start(p,a,b) (p)->lpVtbl->Start(p,a,b) -#define IDirectInputEffect_Stop(p) (p)->lpVtbl->Stop(p) -#define IDirectInputEffect_GetEffectStatus(p,a) (p)->lpVtbl->GetEffectStatus(p,a) -#define IDirectInputEffect_Download(p) (p)->lpVtbl->Download(p) -#define IDirectInputEffect_Unload(p) (p)->lpVtbl->Unload(p) -#define IDirectInputEffect_Escape(p,a) (p)->lpVtbl->Escape(p,a) -#else -#define IDirectInputEffect_QueryInterface(p,a,b) (p)->QueryInterface(a,b) -#define IDirectInputEffect_AddRef(p) (p)->AddRef() -#define IDirectInputEffect_Release(p) (p)->Release() -#define IDirectInputEffect_Initialize(p,a,b,c) (p)->Initialize(a,b,c) -#define IDirectInputEffect_GetEffectGuid(p,a) (p)->GetEffectGuid(a) -#define IDirectInputEffect_GetParameters(p,a,b) (p)->GetParameters(a,b) -#define IDirectInputEffect_SetParameters(p,a,b) (p)->SetParameters(a,b) -#define IDirectInputEffect_Start(p,a,b) (p)->Start(a,b) -#define IDirectInputEffect_Stop(p) (p)->Stop() -#define IDirectInputEffect_GetEffectStatus(p,a) (p)->GetEffectStatus(a) -#define IDirectInputEffect_Download(p) (p)->Download() -#define IDirectInputEffect_Unload(p) (p)->Unload() -#define IDirectInputEffect_Escape(p,a) (p)->Escape(a) -#endif - -#endif /* DIJ_RINGZERO */ - -#endif /* DIRECTINPUT_VERSION >= 0x0500 */ - -/**************************************************************************** - * - * IDirectInputDevice - * - ****************************************************************************/ - -#if DIRECTINPUT_VERSION <= 0x700 -#define DIDEVTYPE_DEVICE 1 -#define DIDEVTYPE_MOUSE 2 -#define DIDEVTYPE_KEYBOARD 3 -#define DIDEVTYPE_JOYSTICK 4 - -#else -#define DI8DEVCLASS_ALL 0 -#define DI8DEVCLASS_DEVICE 1 -#define DI8DEVCLASS_POINTER 2 -#define DI8DEVCLASS_KEYBOARD 3 -#define DI8DEVCLASS_GAMECTRL 4 - -#define DI8DEVTYPE_DEVICE 0x11 -#define DI8DEVTYPE_MOUSE 0x12 -#define DI8DEVTYPE_KEYBOARD 0x13 -#define DI8DEVTYPE_JOYSTICK 0x14 -#define DI8DEVTYPE_GAMEPAD 0x15 -#define DI8DEVTYPE_DRIVING 0x16 -#define DI8DEVTYPE_FLIGHT 0x17 -#define DI8DEVTYPE_1STPERSON 0x18 -#define DI8DEVTYPE_DEVICECTRL 0x19 -#define DI8DEVTYPE_SCREENPOINTER 0x1A -#define DI8DEVTYPE_REMOTE 0x1B -#define DI8DEVTYPE_SUPPLEMENTAL 0x1C -#endif /* DIRECTINPUT_VERSION <= 0x700 */ - -#define DIDEVTYPE_HID 0x00010000 - -#if DIRECTINPUT_VERSION <= 0x700 -#define DIDEVTYPEMOUSE_UNKNOWN 1 -#define DIDEVTYPEMOUSE_TRADITIONAL 2 -#define DIDEVTYPEMOUSE_FINGERSTICK 3 -#define DIDEVTYPEMOUSE_TOUCHPAD 4 -#define DIDEVTYPEMOUSE_TRACKBALL 5 - -#define DIDEVTYPEKEYBOARD_UNKNOWN 0 -#define DIDEVTYPEKEYBOARD_PCXT 1 -#define DIDEVTYPEKEYBOARD_OLIVETTI 2 -#define DIDEVTYPEKEYBOARD_PCAT 3 -#define DIDEVTYPEKEYBOARD_PCENH 4 -#define DIDEVTYPEKEYBOARD_NOKIA1050 5 -#define DIDEVTYPEKEYBOARD_NOKIA9140 6 -#define DIDEVTYPEKEYBOARD_NEC98 7 -#define DIDEVTYPEKEYBOARD_NEC98LAPTOP 8 -#define DIDEVTYPEKEYBOARD_NEC98106 9 -#define DIDEVTYPEKEYBOARD_JAPAN106 10 -#define DIDEVTYPEKEYBOARD_JAPANAX 11 -#define DIDEVTYPEKEYBOARD_J3100 12 - -#define DIDEVTYPEJOYSTICK_UNKNOWN 1 -#define DIDEVTYPEJOYSTICK_TRADITIONAL 2 -#define DIDEVTYPEJOYSTICK_FLIGHTSTICK 3 -#define DIDEVTYPEJOYSTICK_GAMEPAD 4 -#define DIDEVTYPEJOYSTICK_RUDDER 5 -#define DIDEVTYPEJOYSTICK_WHEEL 6 -#define DIDEVTYPEJOYSTICK_HEADTRACKER 7 - -#else -#define DI8DEVTYPEMOUSE_UNKNOWN 1 -#define DI8DEVTYPEMOUSE_TRADITIONAL 2 -#define DI8DEVTYPEMOUSE_FINGERSTICK 3 -#define DI8DEVTYPEMOUSE_TOUCHPAD 4 -#define DI8DEVTYPEMOUSE_TRACKBALL 5 -#define DI8DEVTYPEMOUSE_ABSOLUTE 6 - -#define DI8DEVTYPEKEYBOARD_UNKNOWN 0 -#define DI8DEVTYPEKEYBOARD_PCXT 1 -#define DI8DEVTYPEKEYBOARD_OLIVETTI 2 -#define DI8DEVTYPEKEYBOARD_PCAT 3 -#define DI8DEVTYPEKEYBOARD_PCENH 4 -#define DI8DEVTYPEKEYBOARD_NOKIA1050 5 -#define DI8DEVTYPEKEYBOARD_NOKIA9140 6 -#define DI8DEVTYPEKEYBOARD_NEC98 7 -#define DI8DEVTYPEKEYBOARD_NEC98LAPTOP 8 -#define DI8DEVTYPEKEYBOARD_NEC98106 9 -#define DI8DEVTYPEKEYBOARD_JAPAN106 10 -#define DI8DEVTYPEKEYBOARD_JAPANAX 11 -#define DI8DEVTYPEKEYBOARD_J3100 12 - -#define DI8DEVTYPE_LIMITEDGAMESUBTYPE 1 - -#define DI8DEVTYPEJOYSTICK_LIMITED DI8DEVTYPE_LIMITEDGAMESUBTYPE -#define DI8DEVTYPEJOYSTICK_STANDARD 2 - -#define DI8DEVTYPEGAMEPAD_LIMITED DI8DEVTYPE_LIMITEDGAMESUBTYPE -#define DI8DEVTYPEGAMEPAD_STANDARD 2 -#define DI8DEVTYPEGAMEPAD_TILT 3 - -#define DI8DEVTYPEDRIVING_LIMITED DI8DEVTYPE_LIMITEDGAMESUBTYPE -#define DI8DEVTYPEDRIVING_COMBINEDPEDALS 2 -#define DI8DEVTYPEDRIVING_DUALPEDALS 3 -#define DI8DEVTYPEDRIVING_THREEPEDALS 4 -#define DI8DEVTYPEDRIVING_HANDHELD 5 - -#define DI8DEVTYPEFLIGHT_LIMITED DI8DEVTYPE_LIMITEDGAMESUBTYPE -#define DI8DEVTYPEFLIGHT_STICK 2 -#define DI8DEVTYPEFLIGHT_YOKE 3 -#define DI8DEVTYPEFLIGHT_RC 4 - -#define DI8DEVTYPE1STPERSON_LIMITED DI8DEVTYPE_LIMITEDGAMESUBTYPE -#define DI8DEVTYPE1STPERSON_UNKNOWN 2 -#define DI8DEVTYPE1STPERSON_SIXDOF 3 -#define DI8DEVTYPE1STPERSON_SHOOTER 4 - -#define DI8DEVTYPESCREENPTR_UNKNOWN 2 -#define DI8DEVTYPESCREENPTR_LIGHTGUN 3 -#define DI8DEVTYPESCREENPTR_LIGHTPEN 4 -#define DI8DEVTYPESCREENPTR_TOUCH 5 - -#define DI8DEVTYPEREMOTE_UNKNOWN 2 - -#define DI8DEVTYPEDEVICECTRL_UNKNOWN 2 -#define DI8DEVTYPEDEVICECTRL_COMMSSELECTION 3 -#define DI8DEVTYPEDEVICECTRL_COMMSSELECTION_HARDWIRED 4 - -#define DI8DEVTYPESUPPLEMENTAL_UNKNOWN 2 -#define DI8DEVTYPESUPPLEMENTAL_2NDHANDCONTROLLER 3 -#define DI8DEVTYPESUPPLEMENTAL_HEADTRACKER 4 -#define DI8DEVTYPESUPPLEMENTAL_HANDTRACKER 5 -#define DI8DEVTYPESUPPLEMENTAL_SHIFTSTICKGATE 6 -#define DI8DEVTYPESUPPLEMENTAL_SHIFTER 7 -#define DI8DEVTYPESUPPLEMENTAL_THROTTLE 8 -#define DI8DEVTYPESUPPLEMENTAL_SPLITTHROTTLE 9 -#define DI8DEVTYPESUPPLEMENTAL_COMBINEDPEDALS 10 -#define DI8DEVTYPESUPPLEMENTAL_DUALPEDALS 11 -#define DI8DEVTYPESUPPLEMENTAL_THREEPEDALS 12 -#define DI8DEVTYPESUPPLEMENTAL_RUDDERPEDALS 13 -#endif /* DIRECTINPUT_VERSION <= 0x700 */ - -#define GET_DIDEVICE_TYPE(dwDevType) LOBYTE(dwDevType) -#define GET_DIDEVICE_SUBTYPE(dwDevType) HIBYTE(dwDevType) - -#if(DIRECTINPUT_VERSION >= 0x0500) -/* This structure is defined for DirectX 3.0 compatibility */ -typedef struct DIDEVCAPS_DX3 { - DWORD dwSize; - DWORD dwFlags; - DWORD dwDevType; - DWORD dwAxes; - DWORD dwButtons; - DWORD dwPOVs; -} DIDEVCAPS_DX3, *LPDIDEVCAPS_DX3; -#endif /* DIRECTINPUT_VERSION >= 0x0500 */ - -typedef struct DIDEVCAPS { - DWORD dwSize; - DWORD dwFlags; - DWORD dwDevType; - DWORD dwAxes; - DWORD dwButtons; - DWORD dwPOVs; -#if(DIRECTINPUT_VERSION >= 0x0500) - DWORD dwFFSamplePeriod; - DWORD dwFFMinTimeResolution; - DWORD dwFirmwareRevision; - DWORD dwHardwareRevision; - DWORD dwFFDriverVersion; -#endif /* DIRECTINPUT_VERSION >= 0x0500 */ -} DIDEVCAPS, *LPDIDEVCAPS; - -#define DIDC_ATTACHED 0x00000001 -#define DIDC_POLLEDDEVICE 0x00000002 -#define DIDC_EMULATED 0x00000004 -#define DIDC_POLLEDDATAFORMAT 0x00000008 -#if(DIRECTINPUT_VERSION >= 0x0500) -#define DIDC_FORCEFEEDBACK 0x00000100 -#define DIDC_FFATTACK 0x00000200 -#define DIDC_FFFADE 0x00000400 -#define DIDC_SATURATION 0x00000800 -#define DIDC_POSNEGCOEFFICIENTS 0x00001000 -#define DIDC_POSNEGSATURATION 0x00002000 -#define DIDC_DEADBAND 0x00004000 -#endif /* DIRECTINPUT_VERSION >= 0x0500 */ -#define DIDC_STARTDELAY 0x00008000 -#if(DIRECTINPUT_VERSION >= 0x050a) -#define DIDC_ALIAS 0x00010000 -#define DIDC_PHANTOM 0x00020000 -#endif /* DIRECTINPUT_VERSION >= 0x050a */ -#if(DIRECTINPUT_VERSION >= 0x0800) -#define DIDC_HIDDEN 0x00040000 -#endif /* DIRECTINPUT_VERSION >= 0x0800 */ - -#define DIDFT_ALL 0x00000000 - -#define DIDFT_RELAXIS 0x00000001 -#define DIDFT_ABSAXIS 0x00000002 -#define DIDFT_AXIS 0x00000003 - -#define DIDFT_PSHBUTTON 0x00000004 -#define DIDFT_TGLBUTTON 0x00000008 -#define DIDFT_BUTTON 0x0000000C - -#define DIDFT_POV 0x00000010 -#define DIDFT_COLLECTION 0x00000040 -#define DIDFT_NODATA 0x00000080 - -#define DIDFT_ANYINSTANCE 0x00FFFF00 -#define DIDFT_INSTANCEMASK DIDFT_ANYINSTANCE -#define DIDFT_MAKEINSTANCE(n) ((WORD)(n) << 8) -#define DIDFT_GETTYPE(n) LOBYTE(n) -#define DIDFT_GETINSTANCE(n) LOWORD((n) >> 8) -#define DIDFT_FFACTUATOR 0x01000000 -#define DIDFT_FFEFFECTTRIGGER 0x02000000 -#if(DIRECTINPUT_VERSION >= 0x050a) -#define DIDFT_OUTPUT 0x10000000 -#define DIDFT_VENDORDEFINED 0x04000000 -#define DIDFT_ALIAS 0x08000000 -#endif /* DIRECTINPUT_VERSION >= 0x050a */ -#ifndef DIDFT_OPTIONAL -#define DIDFT_OPTIONAL 0x80000000 -#endif - -#define DIDFT_ENUMCOLLECTION(n) ((WORD)(n) << 8) -#define DIDFT_NOCOLLECTION 0x00FFFF00 - -#ifndef DIJ_RINGZERO - -typedef struct _DIOBJECTDATAFORMAT { - const GUID *pguid; - DWORD dwOfs; - DWORD dwType; - DWORD dwFlags; -} DIOBJECTDATAFORMAT, *LPDIOBJECTDATAFORMAT; -typedef const DIOBJECTDATAFORMAT *LPCDIOBJECTDATAFORMAT; - -typedef struct _DIDATAFORMAT { - DWORD dwSize; - DWORD dwObjSize; - DWORD dwFlags; - DWORD dwDataSize; - DWORD dwNumObjs; - LPDIOBJECTDATAFORMAT rgodf; -} DIDATAFORMAT, *LPDIDATAFORMAT; -typedef const DIDATAFORMAT *LPCDIDATAFORMAT; - -#define DIDF_ABSAXIS 0x00000001 -#define DIDF_RELAXIS 0x00000002 - -#ifdef __cplusplus -extern "C" { -#endif -extern const DIDATAFORMAT c_dfDIMouse; - -#if(DIRECTINPUT_VERSION >= 0x0700) -extern const DIDATAFORMAT c_dfDIMouse2; -#endif /* DIRECTINPUT_VERSION >= 0x0700 */ - -extern const DIDATAFORMAT c_dfDIKeyboard; - -#if(DIRECTINPUT_VERSION >= 0x0500) -extern const DIDATAFORMAT c_dfDIJoystick; -extern const DIDATAFORMAT c_dfDIJoystick2; -#endif /* DIRECTINPUT_VERSION >= 0x0500 */ - -#ifdef __cplusplus -}; -#endif - - -#if DIRECTINPUT_VERSION > 0x0700 - -typedef struct _DIACTIONA { - UINT_PTR uAppData; - DWORD dwSemantic; - OPTIONAL DWORD dwFlags; - OPTIONAL union { - LPCSTR lptszActionName; - UINT uResIdString; - }; - OPTIONAL GUID guidInstance; - OPTIONAL DWORD dwObjID; - OPTIONAL DWORD dwHow; -} DIACTIONA, *LPDIACTIONA ; -typedef struct _DIACTIONW { - UINT_PTR uAppData; - DWORD dwSemantic; - OPTIONAL DWORD dwFlags; - OPTIONAL union { - LPCWSTR lptszActionName; - UINT uResIdString; - }; - OPTIONAL GUID guidInstance; - OPTIONAL DWORD dwObjID; - OPTIONAL DWORD dwHow; -} DIACTIONW, *LPDIACTIONW ; -#ifdef UNICODE -typedef DIACTIONW DIACTION; -typedef LPDIACTIONW LPDIACTION; -#else -typedef DIACTIONA DIACTION; -typedef LPDIACTIONA LPDIACTION; -#endif // UNICODE - -typedef const DIACTIONA *LPCDIACTIONA; -typedef const DIACTIONW *LPCDIACTIONW; -#ifdef UNICODE -typedef DIACTIONW DIACTION; -typedef LPCDIACTIONW LPCDIACTION; -#else -typedef DIACTIONA DIACTION; -typedef LPCDIACTIONA LPCDIACTION; -#endif // UNICODE -typedef const DIACTION *LPCDIACTION; - - -#define DIA_FORCEFEEDBACK 0x00000001 -#define DIA_APPMAPPED 0x00000002 -#define DIA_APPNOMAP 0x00000004 -#define DIA_NORANGE 0x00000008 -#define DIA_APPFIXED 0x00000010 - -#define DIAH_UNMAPPED 0x00000000 -#define DIAH_USERCONFIG 0x00000001 -#define DIAH_APPREQUESTED 0x00000002 -#define DIAH_HWAPP 0x00000004 -#define DIAH_HWDEFAULT 0x00000008 -#define DIAH_DEFAULT 0x00000020 -#define DIAH_ERROR 0x80000000 - -typedef struct _DIACTIONFORMATA { - DWORD dwSize; - DWORD dwActionSize; - DWORD dwDataSize; - DWORD dwNumActions; - LPDIACTIONA rgoAction; - GUID guidActionMap; - DWORD dwGenre; - DWORD dwBufferSize; - OPTIONAL LONG lAxisMin; - OPTIONAL LONG lAxisMax; - OPTIONAL HINSTANCE hInstString; - FILETIME ftTimeStamp; - DWORD dwCRC; - CHAR tszActionMap[MAX_PATH]; -} DIACTIONFORMATA, *LPDIACTIONFORMATA; -typedef struct _DIACTIONFORMATW { - DWORD dwSize; - DWORD dwActionSize; - DWORD dwDataSize; - DWORD dwNumActions; - LPDIACTIONW rgoAction; - GUID guidActionMap; - DWORD dwGenre; - DWORD dwBufferSize; - OPTIONAL LONG lAxisMin; - OPTIONAL LONG lAxisMax; - OPTIONAL HINSTANCE hInstString; - FILETIME ftTimeStamp; - DWORD dwCRC; - WCHAR tszActionMap[MAX_PATH]; -} DIACTIONFORMATW, *LPDIACTIONFORMATW; -#ifdef UNICODE -typedef DIACTIONFORMATW DIACTIONFORMAT; -typedef LPDIACTIONFORMATW LPDIACTIONFORMAT; -#else -typedef DIACTIONFORMATA DIACTIONFORMAT; -typedef LPDIACTIONFORMATA LPDIACTIONFORMAT; -#endif // UNICODE -typedef const DIACTIONFORMATA *LPCDIACTIONFORMATA; -typedef const DIACTIONFORMATW *LPCDIACTIONFORMATW; -#ifdef UNICODE -typedef DIACTIONFORMATW DIACTIONFORMAT; -typedef LPCDIACTIONFORMATW LPCDIACTIONFORMAT; -#else -typedef DIACTIONFORMATA DIACTIONFORMAT; -typedef LPCDIACTIONFORMATA LPCDIACTIONFORMAT; -#endif // UNICODE -typedef const DIACTIONFORMAT *LPCDIACTIONFORMAT; - -#define DIAFTS_NEWDEVICELOW 0xFFFFFFFF -#define DIAFTS_NEWDEVICEHIGH 0xFFFFFFFF -#define DIAFTS_UNUSEDDEVICELOW 0x00000000 -#define DIAFTS_UNUSEDDEVICEHIGH 0x00000000 - -#define DIDBAM_DEFAULT 0x00000000 -#define DIDBAM_PRESERVE 0x00000001 -#define DIDBAM_INITIALIZE 0x00000002 -#define DIDBAM_HWDEFAULTS 0x00000004 - -#define DIDSAM_DEFAULT 0x00000000 -#define DIDSAM_NOUSER 0x00000001 -#define DIDSAM_FORCESAVE 0x00000002 - -#define DICD_DEFAULT 0x00000000 -#define DICD_EDIT 0x00000001 - -/* - * The following definition is normally defined in d3dtypes.h - */ -#ifndef D3DCOLOR_DEFINED -typedef DWORD D3DCOLOR; -#define D3DCOLOR_DEFINED -#endif - -typedef struct _DICOLORSET{ - DWORD dwSize; - D3DCOLOR cTextFore; - D3DCOLOR cTextHighlight; - D3DCOLOR cCalloutLine; - D3DCOLOR cCalloutHighlight; - D3DCOLOR cBorder; - D3DCOLOR cControlFill; - D3DCOLOR cHighlightFill; - D3DCOLOR cAreaFill; -} DICOLORSET, *LPDICOLORSET; -typedef const DICOLORSET *LPCDICOLORSET; - - -typedef struct _DICONFIGUREDEVICESPARAMSA{ - DWORD dwSize; - DWORD dwcUsers; - LPSTR lptszUserNames; - DWORD dwcFormats; - LPDIACTIONFORMATA lprgFormats; - HWND hwnd; - DICOLORSET dics; - IUnknown FAR * lpUnkDDSTarget; -} DICONFIGUREDEVICESPARAMSA, *LPDICONFIGUREDEVICESPARAMSA; -typedef struct _DICONFIGUREDEVICESPARAMSW{ - DWORD dwSize; - DWORD dwcUsers; - LPWSTR lptszUserNames; - DWORD dwcFormats; - LPDIACTIONFORMATW lprgFormats; - HWND hwnd; - DICOLORSET dics; - IUnknown FAR * lpUnkDDSTarget; -} DICONFIGUREDEVICESPARAMSW, *LPDICONFIGUREDEVICESPARAMSW; -#ifdef UNICODE -typedef DICONFIGUREDEVICESPARAMSW DICONFIGUREDEVICESPARAMS; -typedef LPDICONFIGUREDEVICESPARAMSW LPDICONFIGUREDEVICESPARAMS; -#else -typedef DICONFIGUREDEVICESPARAMSA DICONFIGUREDEVICESPARAMS; -typedef LPDICONFIGUREDEVICESPARAMSA LPDICONFIGUREDEVICESPARAMS; -#endif // UNICODE -typedef const DICONFIGUREDEVICESPARAMSA *LPCDICONFIGUREDEVICESPARAMSA; -typedef const DICONFIGUREDEVICESPARAMSW *LPCDICONFIGUREDEVICESPARAMSW; -#ifdef UNICODE -typedef DICONFIGUREDEVICESPARAMSW DICONFIGUREDEVICESPARAMS; -typedef LPCDICONFIGUREDEVICESPARAMSW LPCDICONFIGUREDEVICESPARAMS; -#else -typedef DICONFIGUREDEVICESPARAMSA DICONFIGUREDEVICESPARAMS; -typedef LPCDICONFIGUREDEVICESPARAMSA LPCDICONFIGUREDEVICESPARAMS; -#endif // UNICODE -typedef const DICONFIGUREDEVICESPARAMS *LPCDICONFIGUREDEVICESPARAMS; - - -#define DIDIFT_CONFIGURATION 0x00000001 -#define DIDIFT_OVERLAY 0x00000002 - -#define DIDAL_CENTERED 0x00000000 -#define DIDAL_LEFTALIGNED 0x00000001 -#define DIDAL_RIGHTALIGNED 0x00000002 -#define DIDAL_MIDDLE 0x00000000 -#define DIDAL_TOPALIGNED 0x00000004 -#define DIDAL_BOTTOMALIGNED 0x00000008 - -typedef struct _DIDEVICEIMAGEINFOA { - CHAR tszImagePath[MAX_PATH]; - DWORD dwFlags; - // These are valid if DIDIFT_OVERLAY is present in dwFlags. - DWORD dwViewID; - RECT rcOverlay; - DWORD dwObjID; - DWORD dwcValidPts; - POINT rgptCalloutLine[5]; - RECT rcCalloutRect; - DWORD dwTextAlign; -} DIDEVICEIMAGEINFOA, *LPDIDEVICEIMAGEINFOA; -typedef struct _DIDEVICEIMAGEINFOW { - WCHAR tszImagePath[MAX_PATH]; - DWORD dwFlags; - // These are valid if DIDIFT_OVERLAY is present in dwFlags. - DWORD dwViewID; - RECT rcOverlay; - DWORD dwObjID; - DWORD dwcValidPts; - POINT rgptCalloutLine[5]; - RECT rcCalloutRect; - DWORD dwTextAlign; -} DIDEVICEIMAGEINFOW, *LPDIDEVICEIMAGEINFOW; -#ifdef UNICODE -typedef DIDEVICEIMAGEINFOW DIDEVICEIMAGEINFO; -typedef LPDIDEVICEIMAGEINFOW LPDIDEVICEIMAGEINFO; -#else -typedef DIDEVICEIMAGEINFOA DIDEVICEIMAGEINFO; -typedef LPDIDEVICEIMAGEINFOA LPDIDEVICEIMAGEINFO; -#endif // UNICODE -typedef const DIDEVICEIMAGEINFOA *LPCDIDEVICEIMAGEINFOA; -typedef const DIDEVICEIMAGEINFOW *LPCDIDEVICEIMAGEINFOW; -#ifdef UNICODE -typedef DIDEVICEIMAGEINFOW DIDEVICEIMAGEINFO; -typedef LPCDIDEVICEIMAGEINFOW LPCDIDEVICEIMAGEINFO; -#else -typedef DIDEVICEIMAGEINFOA DIDEVICEIMAGEINFO; -typedef LPCDIDEVICEIMAGEINFOA LPCDIDEVICEIMAGEINFO; -#endif // UNICODE -typedef const DIDEVICEIMAGEINFO *LPCDIDEVICEIMAGEINFO; - -typedef struct _DIDEVICEIMAGEINFOHEADERA { - DWORD dwSize; - DWORD dwSizeImageInfo; - DWORD dwcViews; - DWORD dwcButtons; - DWORD dwcAxes; - DWORD dwcPOVs; - DWORD dwBufferSize; - DWORD dwBufferUsed; - LPDIDEVICEIMAGEINFOA lprgImageInfoArray; -} DIDEVICEIMAGEINFOHEADERA, *LPDIDEVICEIMAGEINFOHEADERA; -typedef struct _DIDEVICEIMAGEINFOHEADERW { - DWORD dwSize; - DWORD dwSizeImageInfo; - DWORD dwcViews; - DWORD dwcButtons; - DWORD dwcAxes; - DWORD dwcPOVs; - DWORD dwBufferSize; - DWORD dwBufferUsed; - LPDIDEVICEIMAGEINFOW lprgImageInfoArray; -} DIDEVICEIMAGEINFOHEADERW, *LPDIDEVICEIMAGEINFOHEADERW; -#ifdef UNICODE -typedef DIDEVICEIMAGEINFOHEADERW DIDEVICEIMAGEINFOHEADER; -typedef LPDIDEVICEIMAGEINFOHEADERW LPDIDEVICEIMAGEINFOHEADER; -#else -typedef DIDEVICEIMAGEINFOHEADERA DIDEVICEIMAGEINFOHEADER; -typedef LPDIDEVICEIMAGEINFOHEADERA LPDIDEVICEIMAGEINFOHEADER; -#endif // UNICODE -typedef const DIDEVICEIMAGEINFOHEADERA *LPCDIDEVICEIMAGEINFOHEADERA; -typedef const DIDEVICEIMAGEINFOHEADERW *LPCDIDEVICEIMAGEINFOHEADERW; -#ifdef UNICODE -typedef DIDEVICEIMAGEINFOHEADERW DIDEVICEIMAGEINFOHEADER; -typedef LPCDIDEVICEIMAGEINFOHEADERW LPCDIDEVICEIMAGEINFOHEADER; -#else -typedef DIDEVICEIMAGEINFOHEADERA DIDEVICEIMAGEINFOHEADER; -typedef LPCDIDEVICEIMAGEINFOHEADERA LPCDIDEVICEIMAGEINFOHEADER; -#endif // UNICODE -typedef const DIDEVICEIMAGEINFOHEADER *LPCDIDEVICEIMAGEINFOHEADER; - -#endif /* DIRECTINPUT_VERSION > 0x0700 */ - -#if(DIRECTINPUT_VERSION >= 0x0500) -/* These structures are defined for DirectX 3.0 compatibility */ - -typedef struct DIDEVICEOBJECTINSTANCE_DX3A { - DWORD dwSize; - GUID guidType; - DWORD dwOfs; - DWORD dwType; - DWORD dwFlags; - CHAR tszName[MAX_PATH]; -} DIDEVICEOBJECTINSTANCE_DX3A, *LPDIDEVICEOBJECTINSTANCE_DX3A; -typedef struct DIDEVICEOBJECTINSTANCE_DX3W { - DWORD dwSize; - GUID guidType; - DWORD dwOfs; - DWORD dwType; - DWORD dwFlags; - WCHAR tszName[MAX_PATH]; -} DIDEVICEOBJECTINSTANCE_DX3W, *LPDIDEVICEOBJECTINSTANCE_DX3W; -#ifdef UNICODE -typedef DIDEVICEOBJECTINSTANCE_DX3W DIDEVICEOBJECTINSTANCE_DX3; -typedef LPDIDEVICEOBJECTINSTANCE_DX3W LPDIDEVICEOBJECTINSTANCE_DX3; -#else -typedef DIDEVICEOBJECTINSTANCE_DX3A DIDEVICEOBJECTINSTANCE_DX3; -typedef LPDIDEVICEOBJECTINSTANCE_DX3A LPDIDEVICEOBJECTINSTANCE_DX3; -#endif // UNICODE -typedef const DIDEVICEOBJECTINSTANCE_DX3A *LPCDIDEVICEOBJECTINSTANCE_DX3A; -typedef const DIDEVICEOBJECTINSTANCE_DX3W *LPCDIDEVICEOBJECTINSTANCE_DX3W; -typedef const DIDEVICEOBJECTINSTANCE_DX3 *LPCDIDEVICEOBJECTINSTANCE_DX3; -#endif /* DIRECTINPUT_VERSION >= 0x0500 */ - -typedef struct DIDEVICEOBJECTINSTANCEA { - DWORD dwSize; - GUID guidType; - DWORD dwOfs; - DWORD dwType; - DWORD dwFlags; - CHAR tszName[MAX_PATH]; -#if(DIRECTINPUT_VERSION >= 0x0500) - DWORD dwFFMaxForce; - DWORD dwFFForceResolution; - WORD wCollectionNumber; - WORD wDesignatorIndex; - WORD wUsagePage; - WORD wUsage; - DWORD dwDimension; - WORD wExponent; - WORD wReportId; -#endif /* DIRECTINPUT_VERSION >= 0x0500 */ -} DIDEVICEOBJECTINSTANCEA, *LPDIDEVICEOBJECTINSTANCEA; -typedef struct DIDEVICEOBJECTINSTANCEW { - DWORD dwSize; - GUID guidType; - DWORD dwOfs; - DWORD dwType; - DWORD dwFlags; - WCHAR tszName[MAX_PATH]; -#if(DIRECTINPUT_VERSION >= 0x0500) - DWORD dwFFMaxForce; - DWORD dwFFForceResolution; - WORD wCollectionNumber; - WORD wDesignatorIndex; - WORD wUsagePage; - WORD wUsage; - DWORD dwDimension; - WORD wExponent; - WORD wReportId; -#endif /* DIRECTINPUT_VERSION >= 0x0500 */ -} DIDEVICEOBJECTINSTANCEW, *LPDIDEVICEOBJECTINSTANCEW; -#ifdef UNICODE -typedef DIDEVICEOBJECTINSTANCEW DIDEVICEOBJECTINSTANCE; -typedef LPDIDEVICEOBJECTINSTANCEW LPDIDEVICEOBJECTINSTANCE; -#else -typedef DIDEVICEOBJECTINSTANCEA DIDEVICEOBJECTINSTANCE; -typedef LPDIDEVICEOBJECTINSTANCEA LPDIDEVICEOBJECTINSTANCE; -#endif // UNICODE -typedef const DIDEVICEOBJECTINSTANCEA *LPCDIDEVICEOBJECTINSTANCEA; -typedef const DIDEVICEOBJECTINSTANCEW *LPCDIDEVICEOBJECTINSTANCEW; -typedef const DIDEVICEOBJECTINSTANCE *LPCDIDEVICEOBJECTINSTANCE; - -typedef BOOL (FAR PASCAL * LPDIENUMDEVICEOBJECTSCALLBACKA)(LPCDIDEVICEOBJECTINSTANCEA, LPVOID); -typedef BOOL (FAR PASCAL * LPDIENUMDEVICEOBJECTSCALLBACKW)(LPCDIDEVICEOBJECTINSTANCEW, LPVOID); -#ifdef UNICODE -#define LPDIENUMDEVICEOBJECTSCALLBACK LPDIENUMDEVICEOBJECTSCALLBACKW -#else -#define LPDIENUMDEVICEOBJECTSCALLBACK LPDIENUMDEVICEOBJECTSCALLBACKA -#endif // !UNICODE - -#if(DIRECTINPUT_VERSION >= 0x0500) -#define DIDOI_FFACTUATOR 0x00000001 -#define DIDOI_FFEFFECTTRIGGER 0x00000002 -#define DIDOI_POLLED 0x00008000 -#define DIDOI_ASPECTPOSITION 0x00000100 -#define DIDOI_ASPECTVELOCITY 0x00000200 -#define DIDOI_ASPECTACCEL 0x00000300 -#define DIDOI_ASPECTFORCE 0x00000400 -#define DIDOI_ASPECTMASK 0x00000F00 -#endif /* DIRECTINPUT_VERSION >= 0x0500 */ -#if(DIRECTINPUT_VERSION >= 0x050a) -#define DIDOI_GUIDISUSAGE 0x00010000 -#endif /* DIRECTINPUT_VERSION >= 0x050a */ - -typedef struct DIPROPHEADER { - DWORD dwSize; - DWORD dwHeaderSize; - DWORD dwObj; - DWORD dwHow; -} DIPROPHEADER, *LPDIPROPHEADER; -typedef const DIPROPHEADER *LPCDIPROPHEADER; - -#define DIPH_DEVICE 0 -#define DIPH_BYOFFSET 1 -#define DIPH_BYID 2 -#if(DIRECTINPUT_VERSION >= 0x050a) -#define DIPH_BYUSAGE 3 -#endif /* DIRECTINPUT_VERSION >= 0x050a */ - -#if(DIRECTINPUT_VERSION >= 0x050a) -#define DIMAKEUSAGEDWORD(UsagePage, Usage) \ - (DWORD)MAKELONG(Usage, UsagePage) -#endif /* DIRECTINPUT_VERSION >= 0x050a */ - -typedef struct DIPROPDWORD { - DIPROPHEADER diph; - DWORD dwData; -} DIPROPDWORD, *LPDIPROPDWORD; -typedef const DIPROPDWORD *LPCDIPROPDWORD; - -#if(DIRECTINPUT_VERSION >= 0x0800) -typedef struct DIPROPPOINTER { - DIPROPHEADER diph; - UINT_PTR uData; -} DIPROPPOINTER, *LPDIPROPPOINTER; -typedef const DIPROPPOINTER *LPCDIPROPPOINTER; -#endif /* DIRECTINPUT_VERSION >= 0x0800 */ - -typedef struct DIPROPRANGE { - DIPROPHEADER diph; - LONG lMin; - LONG lMax; -} DIPROPRANGE, *LPDIPROPRANGE; -typedef const DIPROPRANGE *LPCDIPROPRANGE; - -#define DIPROPRANGE_NOMIN ((LONG)0x80000000) -#define DIPROPRANGE_NOMAX ((LONG)0x7FFFFFFF) - -#if(DIRECTINPUT_VERSION >= 0x050a) -typedef struct DIPROPCAL { - DIPROPHEADER diph; - LONG lMin; - LONG lCenter; - LONG lMax; -} DIPROPCAL, *LPDIPROPCAL; -typedef const DIPROPCAL *LPCDIPROPCAL; - -typedef struct DIPROPCALPOV { - DIPROPHEADER diph; - LONG lMin[5]; - LONG lMax[5]; -} DIPROPCALPOV, *LPDIPROPCALPOV; -typedef const DIPROPCALPOV *LPCDIPROPCALPOV; - -typedef struct DIPROPGUIDANDPATH { - DIPROPHEADER diph; - GUID guidClass; - WCHAR wszPath[MAX_PATH]; -} DIPROPGUIDANDPATH, *LPDIPROPGUIDANDPATH; -typedef const DIPROPGUIDANDPATH *LPCDIPROPGUIDANDPATH; - -typedef struct DIPROPSTRING { - DIPROPHEADER diph; - WCHAR wsz[MAX_PATH]; -} DIPROPSTRING, *LPDIPROPSTRING; -typedef const DIPROPSTRING *LPCDIPROPSTRING; - -#endif /* DIRECTINPUT_VERSION >= 0x050a */ - -#if(DIRECTINPUT_VERSION >= 0x0800) -#define MAXCPOINTSNUM 8 - -typedef struct _CPOINT -{ - LONG lP; // raw value - DWORD dwLog; // logical_value / max_logical_value * 10000 -} CPOINT, *PCPOINT; - -typedef struct DIPROPCPOINTS { - DIPROPHEADER diph; - DWORD dwCPointsNum; - CPOINT cp[MAXCPOINTSNUM]; -} DIPROPCPOINTS, *LPDIPROPCPOINTS; -typedef const DIPROPCPOINTS *LPCDIPROPCPOINTS; -#endif /* DIRECTINPUT_VERSION >= 0x0800 */ - - -#ifdef __cplusplus -#define MAKEDIPROP(prop) (*(const GUID *)(prop)) -#else -#define MAKEDIPROP(prop) ((REFGUID)(prop)) -#endif - -#define DIPROP_BUFFERSIZE MAKEDIPROP(1) - -#define DIPROP_AXISMODE MAKEDIPROP(2) - -#define DIPROPAXISMODE_ABS 0 -#define DIPROPAXISMODE_REL 1 - -#define DIPROP_GRANULARITY MAKEDIPROP(3) - -#define DIPROP_RANGE MAKEDIPROP(4) - -#define DIPROP_DEADZONE MAKEDIPROP(5) - -#define DIPROP_SATURATION MAKEDIPROP(6) - -#define DIPROP_FFGAIN MAKEDIPROP(7) - -#define DIPROP_FFLOAD MAKEDIPROP(8) - -#define DIPROP_AUTOCENTER MAKEDIPROP(9) - -#define DIPROPAUTOCENTER_OFF 0 -#define DIPROPAUTOCENTER_ON 1 - -#define DIPROP_CALIBRATIONMODE MAKEDIPROP(10) - -#define DIPROPCALIBRATIONMODE_COOKED 0 -#define DIPROPCALIBRATIONMODE_RAW 1 - -#if(DIRECTINPUT_VERSION >= 0x050a) -#define DIPROP_CALIBRATION MAKEDIPROP(11) - -#define DIPROP_GUIDANDPATH MAKEDIPROP(12) - -#define DIPROP_INSTANCENAME MAKEDIPROP(13) - -#define DIPROP_PRODUCTNAME MAKEDIPROP(14) -#endif /* DIRECTINPUT_VERSION >= 0x050a */ - -#if(DIRECTINPUT_VERSION >= 0x05b2) -#define DIPROP_JOYSTICKID MAKEDIPROP(15) - -#define DIPROP_GETPORTDISPLAYNAME MAKEDIPROP(16) - -#endif /* DIRECTINPUT_VERSION >= 0x05b2 */ - -#if(DIRECTINPUT_VERSION >= 0x0700) -#define DIPROP_PHYSICALRANGE MAKEDIPROP(18) - -#define DIPROP_LOGICALRANGE MAKEDIPROP(19) -#endif /* DIRECTINPUT_VERSION >= 0x0700 */ - -#if(DIRECTINPUT_VERSION >= 0x0800) -#define DIPROP_KEYNAME MAKEDIPROP(20) - -#define DIPROP_CPOINTS MAKEDIPROP(21) - -#define DIPROP_APPDATA MAKEDIPROP(22) - -#define DIPROP_SCANCODE MAKEDIPROP(23) - -#define DIPROP_VIDPID MAKEDIPROP(24) - -#define DIPROP_USERNAME MAKEDIPROP(25) - -#define DIPROP_TYPENAME MAKEDIPROP(26) -#endif /* DIRECTINPUT_VERSION >= 0x0800 */ - - -typedef struct DIDEVICEOBJECTDATA_DX3 { - DWORD dwOfs; - DWORD dwData; - DWORD dwTimeStamp; - DWORD dwSequence; -} DIDEVICEOBJECTDATA_DX3, *LPDIDEVICEOBJECTDATA_DX3; -typedef const DIDEVICEOBJECTDATA_DX3 *LPCDIDEVICEOBJECTDATA_DX; - -typedef struct DIDEVICEOBJECTDATA { - DWORD dwOfs; - DWORD dwData; - DWORD dwTimeStamp; - DWORD dwSequence; -#if(DIRECTINPUT_VERSION >= 0x0800) - UINT_PTR uAppData; -#endif /* DIRECTINPUT_VERSION >= 0x0800 */ -} DIDEVICEOBJECTDATA, *LPDIDEVICEOBJECTDATA; -typedef const DIDEVICEOBJECTDATA *LPCDIDEVICEOBJECTDATA; - -#define DIGDD_PEEK 0x00000001 - -#define DISEQUENCE_COMPARE(dwSequence1, cmp, dwSequence2) \ - ((int)((dwSequence1) - (dwSequence2)) cmp 0) -#define DISCL_EXCLUSIVE 0x00000001 -#define DISCL_NONEXCLUSIVE 0x00000002 -#define DISCL_FOREGROUND 0x00000004 -#define DISCL_BACKGROUND 0x00000008 -#define DISCL_NOWINKEY 0x00000010 - -#if(DIRECTINPUT_VERSION >= 0x0500) -/* These structures are defined for DirectX 3.0 compatibility */ - -typedef struct DIDEVICEINSTANCE_DX3A { - DWORD dwSize; - GUID guidInstance; - GUID guidProduct; - DWORD dwDevType; - CHAR tszInstanceName[MAX_PATH]; - CHAR tszProductName[MAX_PATH]; -} DIDEVICEINSTANCE_DX3A, *LPDIDEVICEINSTANCE_DX3A; -typedef struct DIDEVICEINSTANCE_DX3W { - DWORD dwSize; - GUID guidInstance; - GUID guidProduct; - DWORD dwDevType; - WCHAR tszInstanceName[MAX_PATH]; - WCHAR tszProductName[MAX_PATH]; -} DIDEVICEINSTANCE_DX3W, *LPDIDEVICEINSTANCE_DX3W; -#ifdef UNICODE -typedef DIDEVICEINSTANCE_DX3W DIDEVICEINSTANCE_DX3; -typedef LPDIDEVICEINSTANCE_DX3W LPDIDEVICEINSTANCE_DX3; -#else -typedef DIDEVICEINSTANCE_DX3A DIDEVICEINSTANCE_DX3; -typedef LPDIDEVICEINSTANCE_DX3A LPDIDEVICEINSTANCE_DX3; -#endif // UNICODE -typedef const DIDEVICEINSTANCE_DX3A *LPCDIDEVICEINSTANCE_DX3A; -typedef const DIDEVICEINSTANCE_DX3W *LPCDIDEVICEINSTANCE_DX3W; -typedef const DIDEVICEINSTANCE_DX3 *LPCDIDEVICEINSTANCE_DX3; -#endif /* DIRECTINPUT_VERSION >= 0x0500 */ - -typedef struct DIDEVICEINSTANCEA { - DWORD dwSize; - GUID guidInstance; - GUID guidProduct; - DWORD dwDevType; - CHAR tszInstanceName[MAX_PATH]; - CHAR tszProductName[MAX_PATH]; -#if(DIRECTINPUT_VERSION >= 0x0500) - GUID guidFFDriver; - WORD wUsagePage; - WORD wUsage; -#endif /* DIRECTINPUT_VERSION >= 0x0500 */ -} DIDEVICEINSTANCEA, *LPDIDEVICEINSTANCEA; -typedef struct DIDEVICEINSTANCEW { - DWORD dwSize; - GUID guidInstance; - GUID guidProduct; - DWORD dwDevType; - WCHAR tszInstanceName[MAX_PATH]; - WCHAR tszProductName[MAX_PATH]; -#if(DIRECTINPUT_VERSION >= 0x0500) - GUID guidFFDriver; - WORD wUsagePage; - WORD wUsage; -#endif /* DIRECTINPUT_VERSION >= 0x0500 */ -} DIDEVICEINSTANCEW, *LPDIDEVICEINSTANCEW; -#ifdef UNICODE -typedef DIDEVICEINSTANCEW DIDEVICEINSTANCE; -typedef LPDIDEVICEINSTANCEW LPDIDEVICEINSTANCE; -#else -typedef DIDEVICEINSTANCEA DIDEVICEINSTANCE; -typedef LPDIDEVICEINSTANCEA LPDIDEVICEINSTANCE; -#endif // UNICODE - -typedef const DIDEVICEINSTANCEA *LPCDIDEVICEINSTANCEA; -typedef const DIDEVICEINSTANCEW *LPCDIDEVICEINSTANCEW; -#ifdef UNICODE -typedef DIDEVICEINSTANCEW DIDEVICEINSTANCE; -typedef LPCDIDEVICEINSTANCEW LPCDIDEVICEINSTANCE; -#else -typedef DIDEVICEINSTANCEA DIDEVICEINSTANCE; -typedef LPCDIDEVICEINSTANCEA LPCDIDEVICEINSTANCE; -#endif // UNICODE -typedef const DIDEVICEINSTANCE *LPCDIDEVICEINSTANCE; - -#undef INTERFACE -#define INTERFACE IDirectInputDeviceW - -DECLARE_INTERFACE_(IDirectInputDeviceW, IUnknown) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID * ppvObj) PURE; - STDMETHOD_(ULONG,AddRef)(THIS) PURE; - STDMETHOD_(ULONG,Release)(THIS) PURE; - - /*** IDirectInputDeviceW methods ***/ - STDMETHOD(GetCapabilities)(THIS_ LPDIDEVCAPS) PURE; - STDMETHOD(EnumObjects)(THIS_ LPDIENUMDEVICEOBJECTSCALLBACKW,LPVOID,DWORD) PURE; - STDMETHOD(GetProperty)(THIS_ REFGUID,LPDIPROPHEADER) PURE; - STDMETHOD(SetProperty)(THIS_ REFGUID,LPCDIPROPHEADER) PURE; - STDMETHOD(Acquire)(THIS) PURE; - STDMETHOD(Unacquire)(THIS) PURE; - STDMETHOD(GetDeviceState)(THIS_ DWORD,LPVOID) PURE; - STDMETHOD(GetDeviceData)(THIS_ DWORD,LPDIDEVICEOBJECTDATA,LPDWORD,DWORD) PURE; - STDMETHOD(SetDataFormat)(THIS_ LPCDIDATAFORMAT) PURE; - STDMETHOD(SetEventNotification)(THIS_ HANDLE) PURE; - STDMETHOD(SetCooperativeLevel)(THIS_ HWND,DWORD) PURE; - STDMETHOD(GetObjectInfo)(THIS_ LPDIDEVICEOBJECTINSTANCEW,DWORD,DWORD) PURE; - STDMETHOD(GetDeviceInfo)(THIS_ LPDIDEVICEINSTANCEW) PURE; - STDMETHOD(RunControlPanel)(THIS_ HWND,DWORD) PURE; - STDMETHOD(Initialize)(THIS_ HINSTANCE,DWORD,REFGUID) PURE; -}; - -typedef struct IDirectInputDeviceW *LPDIRECTINPUTDEVICEW; - -#undef INTERFACE -#define INTERFACE IDirectInputDeviceA - -DECLARE_INTERFACE_(IDirectInputDeviceA, IUnknown) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID * ppvObj) PURE; - STDMETHOD_(ULONG,AddRef)(THIS) PURE; - STDMETHOD_(ULONG,Release)(THIS) PURE; - - /*** IDirectInputDeviceA methods ***/ - STDMETHOD(GetCapabilities)(THIS_ LPDIDEVCAPS) PURE; - STDMETHOD(EnumObjects)(THIS_ LPDIENUMDEVICEOBJECTSCALLBACKA,LPVOID,DWORD) PURE; - STDMETHOD(GetProperty)(THIS_ REFGUID,LPDIPROPHEADER) PURE; - STDMETHOD(SetProperty)(THIS_ REFGUID,LPCDIPROPHEADER) PURE; - STDMETHOD(Acquire)(THIS) PURE; - STDMETHOD(Unacquire)(THIS) PURE; - STDMETHOD(GetDeviceState)(THIS_ DWORD,LPVOID) PURE; - STDMETHOD(GetDeviceData)(THIS_ DWORD,LPDIDEVICEOBJECTDATA,LPDWORD,DWORD) PURE; - STDMETHOD(SetDataFormat)(THIS_ LPCDIDATAFORMAT) PURE; - STDMETHOD(SetEventNotification)(THIS_ HANDLE) PURE; - STDMETHOD(SetCooperativeLevel)(THIS_ HWND,DWORD) PURE; - STDMETHOD(GetObjectInfo)(THIS_ LPDIDEVICEOBJECTINSTANCEA,DWORD,DWORD) PURE; - STDMETHOD(GetDeviceInfo)(THIS_ LPDIDEVICEINSTANCEA) PURE; - STDMETHOD(RunControlPanel)(THIS_ HWND,DWORD) PURE; - STDMETHOD(Initialize)(THIS_ HINSTANCE,DWORD,REFGUID) PURE; -}; - -typedef struct IDirectInputDeviceA *LPDIRECTINPUTDEVICEA; - -#ifdef UNICODE -#define IID_IDirectInputDevice IID_IDirectInputDeviceW -#define IDirectInputDevice IDirectInputDeviceW -#define IDirectInputDeviceVtbl IDirectInputDeviceWVtbl -#else -#define IID_IDirectInputDevice IID_IDirectInputDeviceA -#define IDirectInputDevice IDirectInputDeviceA -#define IDirectInputDeviceVtbl IDirectInputDeviceAVtbl -#endif -typedef struct IDirectInputDevice *LPDIRECTINPUTDEVICE; - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectInputDevice_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) -#define IDirectInputDevice_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirectInputDevice_Release(p) (p)->lpVtbl->Release(p) -#define IDirectInputDevice_GetCapabilities(p,a) (p)->lpVtbl->GetCapabilities(p,a) -#define IDirectInputDevice_EnumObjects(p,a,b,c) (p)->lpVtbl->EnumObjects(p,a,b,c) -#define IDirectInputDevice_GetProperty(p,a,b) (p)->lpVtbl->GetProperty(p,a,b) -#define IDirectInputDevice_SetProperty(p,a,b) (p)->lpVtbl->SetProperty(p,a,b) -#define IDirectInputDevice_Acquire(p) (p)->lpVtbl->Acquire(p) -#define IDirectInputDevice_Unacquire(p) (p)->lpVtbl->Unacquire(p) -#define IDirectInputDevice_GetDeviceState(p,a,b) (p)->lpVtbl->GetDeviceState(p,a,b) -#define IDirectInputDevice_GetDeviceData(p,a,b,c,d) (p)->lpVtbl->GetDeviceData(p,a,b,c,d) -#define IDirectInputDevice_SetDataFormat(p,a) (p)->lpVtbl->SetDataFormat(p,a) -#define IDirectInputDevice_SetEventNotification(p,a) (p)->lpVtbl->SetEventNotification(p,a) -#define IDirectInputDevice_SetCooperativeLevel(p,a,b) (p)->lpVtbl->SetCooperativeLevel(p,a,b) -#define IDirectInputDevice_GetObjectInfo(p,a,b,c) (p)->lpVtbl->GetObjectInfo(p,a,b,c) -#define IDirectInputDevice_GetDeviceInfo(p,a) (p)->lpVtbl->GetDeviceInfo(p,a) -#define IDirectInputDevice_RunControlPanel(p,a,b) (p)->lpVtbl->RunControlPanel(p,a,b) -#define IDirectInputDevice_Initialize(p,a,b,c) (p)->lpVtbl->Initialize(p,a,b,c) -#else -#define IDirectInputDevice_QueryInterface(p,a,b) (p)->QueryInterface(a,b) -#define IDirectInputDevice_AddRef(p) (p)->AddRef() -#define IDirectInputDevice_Release(p) (p)->Release() -#define IDirectInputDevice_GetCapabilities(p,a) (p)->GetCapabilities(a) -#define IDirectInputDevice_EnumObjects(p,a,b,c) (p)->EnumObjects(a,b,c) -#define IDirectInputDevice_GetProperty(p,a,b) (p)->GetProperty(a,b) -#define IDirectInputDevice_SetProperty(p,a,b) (p)->SetProperty(a,b) -#define IDirectInputDevice_Acquire(p) (p)->Acquire() -#define IDirectInputDevice_Unacquire(p) (p)->Unacquire() -#define IDirectInputDevice_GetDeviceState(p,a,b) (p)->GetDeviceState(a,b) -#define IDirectInputDevice_GetDeviceData(p,a,b,c,d) (p)->GetDeviceData(a,b,c,d) -#define IDirectInputDevice_SetDataFormat(p,a) (p)->SetDataFormat(a) -#define IDirectInputDevice_SetEventNotification(p,a) (p)->SetEventNotification(a) -#define IDirectInputDevice_SetCooperativeLevel(p,a,b) (p)->SetCooperativeLevel(a,b) -#define IDirectInputDevice_GetObjectInfo(p,a,b,c) (p)->GetObjectInfo(a,b,c) -#define IDirectInputDevice_GetDeviceInfo(p,a) (p)->GetDeviceInfo(a) -#define IDirectInputDevice_RunControlPanel(p,a,b) (p)->RunControlPanel(a,b) -#define IDirectInputDevice_Initialize(p,a,b,c) (p)->Initialize(a,b,c) -#endif - -#endif /* DIJ_RINGZERO */ - - -#if(DIRECTINPUT_VERSION >= 0x0500) - -#define DISFFC_RESET 0x00000001 -#define DISFFC_STOPALL 0x00000002 -#define DISFFC_PAUSE 0x00000004 -#define DISFFC_CONTINUE 0x00000008 -#define DISFFC_SETACTUATORSON 0x00000010 -#define DISFFC_SETACTUATORSOFF 0x00000020 - -#define DIGFFS_EMPTY 0x00000001 -#define DIGFFS_STOPPED 0x00000002 -#define DIGFFS_PAUSED 0x00000004 -#define DIGFFS_ACTUATORSON 0x00000010 -#define DIGFFS_ACTUATORSOFF 0x00000020 -#define DIGFFS_POWERON 0x00000040 -#define DIGFFS_POWEROFF 0x00000080 -#define DIGFFS_SAFETYSWITCHON 0x00000100 -#define DIGFFS_SAFETYSWITCHOFF 0x00000200 -#define DIGFFS_USERFFSWITCHON 0x00000400 -#define DIGFFS_USERFFSWITCHOFF 0x00000800 -#define DIGFFS_DEVICELOST 0x80000000 - -#ifndef DIJ_RINGZERO - -typedef struct DIEFFECTINFOA { - DWORD dwSize; - GUID guid; - DWORD dwEffType; - DWORD dwStaticParams; - DWORD dwDynamicParams; - CHAR tszName[MAX_PATH]; -} DIEFFECTINFOA, *LPDIEFFECTINFOA; -typedef struct DIEFFECTINFOW { - DWORD dwSize; - GUID guid; - DWORD dwEffType; - DWORD dwStaticParams; - DWORD dwDynamicParams; - WCHAR tszName[MAX_PATH]; -} DIEFFECTINFOW, *LPDIEFFECTINFOW; -#ifdef UNICODE -typedef DIEFFECTINFOW DIEFFECTINFO; -typedef LPDIEFFECTINFOW LPDIEFFECTINFO; -#else -typedef DIEFFECTINFOA DIEFFECTINFO; -typedef LPDIEFFECTINFOA LPDIEFFECTINFO; -#endif // UNICODE -typedef const DIEFFECTINFOA *LPCDIEFFECTINFOA; -typedef const DIEFFECTINFOW *LPCDIEFFECTINFOW; -typedef const DIEFFECTINFO *LPCDIEFFECTINFO; - -#define DISDD_CONTINUE 0x00000001 - -typedef BOOL (FAR PASCAL * LPDIENUMEFFECTSCALLBACKA)(LPCDIEFFECTINFOA, LPVOID); -typedef BOOL (FAR PASCAL * LPDIENUMEFFECTSCALLBACKW)(LPCDIEFFECTINFOW, LPVOID); -#ifdef UNICODE -#define LPDIENUMEFFECTSCALLBACK LPDIENUMEFFECTSCALLBACKW -#else -#define LPDIENUMEFFECTSCALLBACK LPDIENUMEFFECTSCALLBACKA -#endif // !UNICODE -typedef BOOL (FAR PASCAL * LPDIENUMCREATEDEFFECTOBJECTSCALLBACK)(LPDIRECTINPUTEFFECT, LPVOID); - -#undef INTERFACE -#define INTERFACE IDirectInputDevice2W - -DECLARE_INTERFACE_(IDirectInputDevice2W, IDirectInputDeviceW) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID * ppvObj) PURE; - STDMETHOD_(ULONG,AddRef)(THIS) PURE; - STDMETHOD_(ULONG,Release)(THIS) PURE; - - /*** IDirectInputDeviceW methods ***/ - STDMETHOD(GetCapabilities)(THIS_ LPDIDEVCAPS) PURE; - STDMETHOD(EnumObjects)(THIS_ LPDIENUMDEVICEOBJECTSCALLBACKW,LPVOID,DWORD) PURE; - STDMETHOD(GetProperty)(THIS_ REFGUID,LPDIPROPHEADER) PURE; - STDMETHOD(SetProperty)(THIS_ REFGUID,LPCDIPROPHEADER) PURE; - STDMETHOD(Acquire)(THIS) PURE; - STDMETHOD(Unacquire)(THIS) PURE; - STDMETHOD(GetDeviceState)(THIS_ DWORD,LPVOID) PURE; - STDMETHOD(GetDeviceData)(THIS_ DWORD,LPDIDEVICEOBJECTDATA,LPDWORD,DWORD) PURE; - STDMETHOD(SetDataFormat)(THIS_ LPCDIDATAFORMAT) PURE; - STDMETHOD(SetEventNotification)(THIS_ HANDLE) PURE; - STDMETHOD(SetCooperativeLevel)(THIS_ HWND,DWORD) PURE; - STDMETHOD(GetObjectInfo)(THIS_ LPDIDEVICEOBJECTINSTANCEW,DWORD,DWORD) PURE; - STDMETHOD(GetDeviceInfo)(THIS_ LPDIDEVICEINSTANCEW) PURE; - STDMETHOD(RunControlPanel)(THIS_ HWND,DWORD) PURE; - STDMETHOD(Initialize)(THIS_ HINSTANCE,DWORD,REFGUID) PURE; - - /*** IDirectInputDevice2W methods ***/ - STDMETHOD(CreateEffect)(THIS_ REFGUID,LPCDIEFFECT,LPDIRECTINPUTEFFECT *,LPUNKNOWN) PURE; - STDMETHOD(EnumEffects)(THIS_ LPDIENUMEFFECTSCALLBACKW,LPVOID,DWORD) PURE; - STDMETHOD(GetEffectInfo)(THIS_ LPDIEFFECTINFOW,REFGUID) PURE; - STDMETHOD(GetForceFeedbackState)(THIS_ LPDWORD) PURE; - STDMETHOD(SendForceFeedbackCommand)(THIS_ DWORD) PURE; - STDMETHOD(EnumCreatedEffectObjects)(THIS_ LPDIENUMCREATEDEFFECTOBJECTSCALLBACK,LPVOID,DWORD) PURE; - STDMETHOD(Escape)(THIS_ LPDIEFFESCAPE) PURE; - STDMETHOD(Poll)(THIS) PURE; - STDMETHOD(SendDeviceData)(THIS_ DWORD,LPCDIDEVICEOBJECTDATA,LPDWORD,DWORD) PURE; -}; - -typedef struct IDirectInputDevice2W *LPDIRECTINPUTDEVICE2W; - -#undef INTERFACE -#define INTERFACE IDirectInputDevice2A - -DECLARE_INTERFACE_(IDirectInputDevice2A, IDirectInputDeviceA) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID * ppvObj) PURE; - STDMETHOD_(ULONG,AddRef)(THIS) PURE; - STDMETHOD_(ULONG,Release)(THIS) PURE; - - /*** IDirectInputDeviceA methods ***/ - STDMETHOD(GetCapabilities)(THIS_ LPDIDEVCAPS) PURE; - STDMETHOD(EnumObjects)(THIS_ LPDIENUMDEVICEOBJECTSCALLBACKA,LPVOID,DWORD) PURE; - STDMETHOD(GetProperty)(THIS_ REFGUID,LPDIPROPHEADER) PURE; - STDMETHOD(SetProperty)(THIS_ REFGUID,LPCDIPROPHEADER) PURE; - STDMETHOD(Acquire)(THIS) PURE; - STDMETHOD(Unacquire)(THIS) PURE; - STDMETHOD(GetDeviceState)(THIS_ DWORD,LPVOID) PURE; - STDMETHOD(GetDeviceData)(THIS_ DWORD,LPDIDEVICEOBJECTDATA,LPDWORD,DWORD) PURE; - STDMETHOD(SetDataFormat)(THIS_ LPCDIDATAFORMAT) PURE; - STDMETHOD(SetEventNotification)(THIS_ HANDLE) PURE; - STDMETHOD(SetCooperativeLevel)(THIS_ HWND,DWORD) PURE; - STDMETHOD(GetObjectInfo)(THIS_ LPDIDEVICEOBJECTINSTANCEA,DWORD,DWORD) PURE; - STDMETHOD(GetDeviceInfo)(THIS_ LPDIDEVICEINSTANCEA) PURE; - STDMETHOD(RunControlPanel)(THIS_ HWND,DWORD) PURE; - STDMETHOD(Initialize)(THIS_ HINSTANCE,DWORD,REFGUID) PURE; - - /*** IDirectInputDevice2A methods ***/ - STDMETHOD(CreateEffect)(THIS_ REFGUID,LPCDIEFFECT,LPDIRECTINPUTEFFECT *,LPUNKNOWN) PURE; - STDMETHOD(EnumEffects)(THIS_ LPDIENUMEFFECTSCALLBACKA,LPVOID,DWORD) PURE; - STDMETHOD(GetEffectInfo)(THIS_ LPDIEFFECTINFOA,REFGUID) PURE; - STDMETHOD(GetForceFeedbackState)(THIS_ LPDWORD) PURE; - STDMETHOD(SendForceFeedbackCommand)(THIS_ DWORD) PURE; - STDMETHOD(EnumCreatedEffectObjects)(THIS_ LPDIENUMCREATEDEFFECTOBJECTSCALLBACK,LPVOID,DWORD) PURE; - STDMETHOD(Escape)(THIS_ LPDIEFFESCAPE) PURE; - STDMETHOD(Poll)(THIS) PURE; - STDMETHOD(SendDeviceData)(THIS_ DWORD,LPCDIDEVICEOBJECTDATA,LPDWORD,DWORD) PURE; -}; - -typedef struct IDirectInputDevice2A *LPDIRECTINPUTDEVICE2A; - -#ifdef UNICODE -#define IID_IDirectInputDevice2 IID_IDirectInputDevice2W -#define IDirectInputDevice2 IDirectInputDevice2W -#define IDirectInputDevice2Vtbl IDirectInputDevice2WVtbl -#else -#define IID_IDirectInputDevice2 IID_IDirectInputDevice2A -#define IDirectInputDevice2 IDirectInputDevice2A -#define IDirectInputDevice2Vtbl IDirectInputDevice2AVtbl -#endif -typedef struct IDirectInputDevice2 *LPDIRECTINPUTDEVICE2; - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectInputDevice2_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) -#define IDirectInputDevice2_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirectInputDevice2_Release(p) (p)->lpVtbl->Release(p) -#define IDirectInputDevice2_GetCapabilities(p,a) (p)->lpVtbl->GetCapabilities(p,a) -#define IDirectInputDevice2_EnumObjects(p,a,b,c) (p)->lpVtbl->EnumObjects(p,a,b,c) -#define IDirectInputDevice2_GetProperty(p,a,b) (p)->lpVtbl->GetProperty(p,a,b) -#define IDirectInputDevice2_SetProperty(p,a,b) (p)->lpVtbl->SetProperty(p,a,b) -#define IDirectInputDevice2_Acquire(p) (p)->lpVtbl->Acquire(p) -#define IDirectInputDevice2_Unacquire(p) (p)->lpVtbl->Unacquire(p) -#define IDirectInputDevice2_GetDeviceState(p,a,b) (p)->lpVtbl->GetDeviceState(p,a,b) -#define IDirectInputDevice2_GetDeviceData(p,a,b,c,d) (p)->lpVtbl->GetDeviceData(p,a,b,c,d) -#define IDirectInputDevice2_SetDataFormat(p,a) (p)->lpVtbl->SetDataFormat(p,a) -#define IDirectInputDevice2_SetEventNotification(p,a) (p)->lpVtbl->SetEventNotification(p,a) -#define IDirectInputDevice2_SetCooperativeLevel(p,a,b) (p)->lpVtbl->SetCooperativeLevel(p,a,b) -#define IDirectInputDevice2_GetObjectInfo(p,a,b,c) (p)->lpVtbl->GetObjectInfo(p,a,b,c) -#define IDirectInputDevice2_GetDeviceInfo(p,a) (p)->lpVtbl->GetDeviceInfo(p,a) -#define IDirectInputDevice2_RunControlPanel(p,a,b) (p)->lpVtbl->RunControlPanel(p,a,b) -#define IDirectInputDevice2_Initialize(p,a,b,c) (p)->lpVtbl->Initialize(p,a,b,c) -#define IDirectInputDevice2_CreateEffect(p,a,b,c,d) (p)->lpVtbl->CreateEffect(p,a,b,c,d) -#define IDirectInputDevice2_EnumEffects(p,a,b,c) (p)->lpVtbl->EnumEffects(p,a,b,c) -#define IDirectInputDevice2_GetEffectInfo(p,a,b) (p)->lpVtbl->GetEffectInfo(p,a,b) -#define IDirectInputDevice2_GetForceFeedbackState(p,a) (p)->lpVtbl->GetForceFeedbackState(p,a) -#define IDirectInputDevice2_SendForceFeedbackCommand(p,a) (p)->lpVtbl->SendForceFeedbackCommand(p,a) -#define IDirectInputDevice2_EnumCreatedEffectObjects(p,a,b,c) (p)->lpVtbl->EnumCreatedEffectObjects(p,a,b,c) -#define IDirectInputDevice2_Escape(p,a) (p)->lpVtbl->Escape(p,a) -#define IDirectInputDevice2_Poll(p) (p)->lpVtbl->Poll(p) -#define IDirectInputDevice2_SendDeviceData(p,a,b,c,d) (p)->lpVtbl->SendDeviceData(p,a,b,c,d) -#else -#define IDirectInputDevice2_QueryInterface(p,a,b) (p)->QueryInterface(a,b) -#define IDirectInputDevice2_AddRef(p) (p)->AddRef() -#define IDirectInputDevice2_Release(p) (p)->Release() -#define IDirectInputDevice2_GetCapabilities(p,a) (p)->GetCapabilities(a) -#define IDirectInputDevice2_EnumObjects(p,a,b,c) (p)->EnumObjects(a,b,c) -#define IDirectInputDevice2_GetProperty(p,a,b) (p)->GetProperty(a,b) -#define IDirectInputDevice2_SetProperty(p,a,b) (p)->SetProperty(a,b) -#define IDirectInputDevice2_Acquire(p) (p)->Acquire() -#define IDirectInputDevice2_Unacquire(p) (p)->Unacquire() -#define IDirectInputDevice2_GetDeviceState(p,a,b) (p)->GetDeviceState(a,b) -#define IDirectInputDevice2_GetDeviceData(p,a,b,c,d) (p)->GetDeviceData(a,b,c,d) -#define IDirectInputDevice2_SetDataFormat(p,a) (p)->SetDataFormat(a) -#define IDirectInputDevice2_SetEventNotification(p,a) (p)->SetEventNotification(a) -#define IDirectInputDevice2_SetCooperativeLevel(p,a,b) (p)->SetCooperativeLevel(a,b) -#define IDirectInputDevice2_GetObjectInfo(p,a,b,c) (p)->GetObjectInfo(a,b,c) -#define IDirectInputDevice2_GetDeviceInfo(p,a) (p)->GetDeviceInfo(a) -#define IDirectInputDevice2_RunControlPanel(p,a,b) (p)->RunControlPanel(a,b) -#define IDirectInputDevice2_Initialize(p,a,b,c) (p)->Initialize(a,b,c) -#define IDirectInputDevice2_CreateEffect(p,a,b,c,d) (p)->CreateEffect(a,b,c,d) -#define IDirectInputDevice2_EnumEffects(p,a,b,c) (p)->EnumEffects(a,b,c) -#define IDirectInputDevice2_GetEffectInfo(p,a,b) (p)->GetEffectInfo(a,b) -#define IDirectInputDevice2_GetForceFeedbackState(p,a) (p)->GetForceFeedbackState(a) -#define IDirectInputDevice2_SendForceFeedbackCommand(p,a) (p)->SendForceFeedbackCommand(a) -#define IDirectInputDevice2_EnumCreatedEffectObjects(p,a,b,c) (p)->EnumCreatedEffectObjects(a,b,c) -#define IDirectInputDevice2_Escape(p,a) (p)->Escape(a) -#define IDirectInputDevice2_Poll(p) (p)->Poll() -#define IDirectInputDevice2_SendDeviceData(p,a,b,c,d) (p)->SendDeviceData(a,b,c,d) -#endif - -#endif /* DIJ_RINGZERO */ - -#endif /* DIRECTINPUT_VERSION >= 0x0500 */ - -#if(DIRECTINPUT_VERSION >= 0x0700) -#define DIFEF_DEFAULT 0x00000000 -#define DIFEF_INCLUDENONSTANDARD 0x00000001 -#define DIFEF_MODIFYIFNEEDED 0x00000010 - -#ifndef DIJ_RINGZERO - -#undef INTERFACE -#define INTERFACE IDirectInputDevice7W - -DECLARE_INTERFACE_(IDirectInputDevice7W, IDirectInputDevice2W) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID * ppvObj) PURE; - STDMETHOD_(ULONG,AddRef)(THIS) PURE; - STDMETHOD_(ULONG,Release)(THIS) PURE; - - /*** IDirectInputDevice2W methods ***/ - STDMETHOD(GetCapabilities)(THIS_ LPDIDEVCAPS) PURE; - STDMETHOD(EnumObjects)(THIS_ LPDIENUMDEVICEOBJECTSCALLBACKW,LPVOID,DWORD) PURE; - STDMETHOD(GetProperty)(THIS_ REFGUID,LPDIPROPHEADER) PURE; - STDMETHOD(SetProperty)(THIS_ REFGUID,LPCDIPROPHEADER) PURE; - STDMETHOD(Acquire)(THIS) PURE; - STDMETHOD(Unacquire)(THIS) PURE; - STDMETHOD(GetDeviceState)(THIS_ DWORD,LPVOID) PURE; - STDMETHOD(GetDeviceData)(THIS_ DWORD,LPDIDEVICEOBJECTDATA,LPDWORD,DWORD) PURE; - STDMETHOD(SetDataFormat)(THIS_ LPCDIDATAFORMAT) PURE; - STDMETHOD(SetEventNotification)(THIS_ HANDLE) PURE; - STDMETHOD(SetCooperativeLevel)(THIS_ HWND,DWORD) PURE; - STDMETHOD(GetObjectInfo)(THIS_ LPDIDEVICEOBJECTINSTANCEW,DWORD,DWORD) PURE; - STDMETHOD(GetDeviceInfo)(THIS_ LPDIDEVICEINSTANCEW) PURE; - STDMETHOD(RunControlPanel)(THIS_ HWND,DWORD) PURE; - STDMETHOD(Initialize)(THIS_ HINSTANCE,DWORD,REFGUID) PURE; - STDMETHOD(CreateEffect)(THIS_ REFGUID,LPCDIEFFECT,LPDIRECTINPUTEFFECT *,LPUNKNOWN) PURE; - STDMETHOD(EnumEffects)(THIS_ LPDIENUMEFFECTSCALLBACKW,LPVOID,DWORD) PURE; - STDMETHOD(GetEffectInfo)(THIS_ LPDIEFFECTINFOW,REFGUID) PURE; - STDMETHOD(GetForceFeedbackState)(THIS_ LPDWORD) PURE; - STDMETHOD(SendForceFeedbackCommand)(THIS_ DWORD) PURE; - STDMETHOD(EnumCreatedEffectObjects)(THIS_ LPDIENUMCREATEDEFFECTOBJECTSCALLBACK,LPVOID,DWORD) PURE; - STDMETHOD(Escape)(THIS_ LPDIEFFESCAPE) PURE; - STDMETHOD(Poll)(THIS) PURE; - STDMETHOD(SendDeviceData)(THIS_ DWORD,LPCDIDEVICEOBJECTDATA,LPDWORD,DWORD) PURE; - - /*** IDirectInputDevice7W methods ***/ - STDMETHOD(EnumEffectsInFile)(THIS_ LPCWSTR,LPDIENUMEFFECTSINFILECALLBACK,LPVOID,DWORD) PURE; - STDMETHOD(WriteEffectToFile)(THIS_ LPCWSTR,DWORD,LPDIFILEEFFECT,DWORD) PURE; -}; - -typedef struct IDirectInputDevice7W *LPDIRECTINPUTDEVICE7W; - -#undef INTERFACE -#define INTERFACE IDirectInputDevice7A - -DECLARE_INTERFACE_(IDirectInputDevice7A, IDirectInputDevice2A) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID * ppvObj) PURE; - STDMETHOD_(ULONG,AddRef)(THIS) PURE; - STDMETHOD_(ULONG,Release)(THIS) PURE; - - /*** IDirectInputDevice2A methods ***/ - STDMETHOD(GetCapabilities)(THIS_ LPDIDEVCAPS) PURE; - STDMETHOD(EnumObjects)(THIS_ LPDIENUMDEVICEOBJECTSCALLBACKA,LPVOID,DWORD) PURE; - STDMETHOD(GetProperty)(THIS_ REFGUID,LPDIPROPHEADER) PURE; - STDMETHOD(SetProperty)(THIS_ REFGUID,LPCDIPROPHEADER) PURE; - STDMETHOD(Acquire)(THIS) PURE; - STDMETHOD(Unacquire)(THIS) PURE; - STDMETHOD(GetDeviceState)(THIS_ DWORD,LPVOID) PURE; - STDMETHOD(GetDeviceData)(THIS_ DWORD,LPDIDEVICEOBJECTDATA,LPDWORD,DWORD) PURE; - STDMETHOD(SetDataFormat)(THIS_ LPCDIDATAFORMAT) PURE; - STDMETHOD(SetEventNotification)(THIS_ HANDLE) PURE; - STDMETHOD(SetCooperativeLevel)(THIS_ HWND,DWORD) PURE; - STDMETHOD(GetObjectInfo)(THIS_ LPDIDEVICEOBJECTINSTANCEA,DWORD,DWORD) PURE; - STDMETHOD(GetDeviceInfo)(THIS_ LPDIDEVICEINSTANCEA) PURE; - STDMETHOD(RunControlPanel)(THIS_ HWND,DWORD) PURE; - STDMETHOD(Initialize)(THIS_ HINSTANCE,DWORD,REFGUID) PURE; - STDMETHOD(CreateEffect)(THIS_ REFGUID,LPCDIEFFECT,LPDIRECTINPUTEFFECT *,LPUNKNOWN) PURE; - STDMETHOD(EnumEffects)(THIS_ LPDIENUMEFFECTSCALLBACKA,LPVOID,DWORD) PURE; - STDMETHOD(GetEffectInfo)(THIS_ LPDIEFFECTINFOA,REFGUID) PURE; - STDMETHOD(GetForceFeedbackState)(THIS_ LPDWORD) PURE; - STDMETHOD(SendForceFeedbackCommand)(THIS_ DWORD) PURE; - STDMETHOD(EnumCreatedEffectObjects)(THIS_ LPDIENUMCREATEDEFFECTOBJECTSCALLBACK,LPVOID,DWORD) PURE; - STDMETHOD(Escape)(THIS_ LPDIEFFESCAPE) PURE; - STDMETHOD(Poll)(THIS) PURE; - STDMETHOD(SendDeviceData)(THIS_ DWORD,LPCDIDEVICEOBJECTDATA,LPDWORD,DWORD) PURE; - - /*** IDirectInputDevice7A methods ***/ - STDMETHOD(EnumEffectsInFile)(THIS_ LPCSTR,LPDIENUMEFFECTSINFILECALLBACK,LPVOID,DWORD) PURE; - STDMETHOD(WriteEffectToFile)(THIS_ LPCSTR,DWORD,LPDIFILEEFFECT,DWORD) PURE; -}; - -typedef struct IDirectInputDevice7A *LPDIRECTINPUTDEVICE7A; - -#ifdef UNICODE -#define IID_IDirectInputDevice7 IID_IDirectInputDevice7W -#define IDirectInputDevice7 IDirectInputDevice7W -#define IDirectInputDevice7Vtbl IDirectInputDevice7WVtbl -#else -#define IID_IDirectInputDevice7 IID_IDirectInputDevice7A -#define IDirectInputDevice7 IDirectInputDevice7A -#define IDirectInputDevice7Vtbl IDirectInputDevice7AVtbl -#endif -typedef struct IDirectInputDevice7 *LPDIRECTINPUTDEVICE7; - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectInputDevice7_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) -#define IDirectInputDevice7_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirectInputDevice7_Release(p) (p)->lpVtbl->Release(p) -#define IDirectInputDevice7_GetCapabilities(p,a) (p)->lpVtbl->GetCapabilities(p,a) -#define IDirectInputDevice7_EnumObjects(p,a,b,c) (p)->lpVtbl->EnumObjects(p,a,b,c) -#define IDirectInputDevice7_GetProperty(p,a,b) (p)->lpVtbl->GetProperty(p,a,b) -#define IDirectInputDevice7_SetProperty(p,a,b) (p)->lpVtbl->SetProperty(p,a,b) -#define IDirectInputDevice7_Acquire(p) (p)->lpVtbl->Acquire(p) -#define IDirectInputDevice7_Unacquire(p) (p)->lpVtbl->Unacquire(p) -#define IDirectInputDevice7_GetDeviceState(p,a,b) (p)->lpVtbl->GetDeviceState(p,a,b) -#define IDirectInputDevice7_GetDeviceData(p,a,b,c,d) (p)->lpVtbl->GetDeviceData(p,a,b,c,d) -#define IDirectInputDevice7_SetDataFormat(p,a) (p)->lpVtbl->SetDataFormat(p,a) -#define IDirectInputDevice7_SetEventNotification(p,a) (p)->lpVtbl->SetEventNotification(p,a) -#define IDirectInputDevice7_SetCooperativeLevel(p,a,b) (p)->lpVtbl->SetCooperativeLevel(p,a,b) -#define IDirectInputDevice7_GetObjectInfo(p,a,b,c) (p)->lpVtbl->GetObjectInfo(p,a,b,c) -#define IDirectInputDevice7_GetDeviceInfo(p,a) (p)->lpVtbl->GetDeviceInfo(p,a) -#define IDirectInputDevice7_RunControlPanel(p,a,b) (p)->lpVtbl->RunControlPanel(p,a,b) -#define IDirectInputDevice7_Initialize(p,a,b,c) (p)->lpVtbl->Initialize(p,a,b,c) -#define IDirectInputDevice7_CreateEffect(p,a,b,c,d) (p)->lpVtbl->CreateEffect(p,a,b,c,d) -#define IDirectInputDevice7_EnumEffects(p,a,b,c) (p)->lpVtbl->EnumEffects(p,a,b,c) -#define IDirectInputDevice7_GetEffectInfo(p,a,b) (p)->lpVtbl->GetEffectInfo(p,a,b) -#define IDirectInputDevice7_GetForceFeedbackState(p,a) (p)->lpVtbl->GetForceFeedbackState(p,a) -#define IDirectInputDevice7_SendForceFeedbackCommand(p,a) (p)->lpVtbl->SendForceFeedbackCommand(p,a) -#define IDirectInputDevice7_EnumCreatedEffectObjects(p,a,b,c) (p)->lpVtbl->EnumCreatedEffectObjects(p,a,b,c) -#define IDirectInputDevice7_Escape(p,a) (p)->lpVtbl->Escape(p,a) -#define IDirectInputDevice7_Poll(p) (p)->lpVtbl->Poll(p) -#define IDirectInputDevice7_SendDeviceData(p,a,b,c,d) (p)->lpVtbl->SendDeviceData(p,a,b,c,d) -#define IDirectInputDevice7_EnumEffectsInFile(p,a,b,c,d) (p)->lpVtbl->EnumEffectsInFile(p,a,b,c,d) -#define IDirectInputDevice7_WriteEffectToFile(p,a,b,c,d) (p)->lpVtbl->WriteEffectToFile(p,a,b,c,d) -#else -#define IDirectInputDevice7_QueryInterface(p,a,b) (p)->QueryInterface(a,b) -#define IDirectInputDevice7_AddRef(p) (p)->AddRef() -#define IDirectInputDevice7_Release(p) (p)->Release() -#define IDirectInputDevice7_GetCapabilities(p,a) (p)->GetCapabilities(a) -#define IDirectInputDevice7_EnumObjects(p,a,b,c) (p)->EnumObjects(a,b,c) -#define IDirectInputDevice7_GetProperty(p,a,b) (p)->GetProperty(a,b) -#define IDirectInputDevice7_SetProperty(p,a,b) (p)->SetProperty(a,b) -#define IDirectInputDevice7_Acquire(p) (p)->Acquire() -#define IDirectInputDevice7_Unacquire(p) (p)->Unacquire() -#define IDirectInputDevice7_GetDeviceState(p,a,b) (p)->GetDeviceState(a,b) -#define IDirectInputDevice7_GetDeviceData(p,a,b,c,d) (p)->GetDeviceData(a,b,c,d) -#define IDirectInputDevice7_SetDataFormat(p,a) (p)->SetDataFormat(a) -#define IDirectInputDevice7_SetEventNotification(p,a) (p)->SetEventNotification(a) -#define IDirectInputDevice7_SetCooperativeLevel(p,a,b) (p)->SetCooperativeLevel(a,b) -#define IDirectInputDevice7_GetObjectInfo(p,a,b,c) (p)->GetObjectInfo(a,b,c) -#define IDirectInputDevice7_GetDeviceInfo(p,a) (p)->GetDeviceInfo(a) -#define IDirectInputDevice7_RunControlPanel(p,a,b) (p)->RunControlPanel(a,b) -#define IDirectInputDevice7_Initialize(p,a,b,c) (p)->Initialize(a,b,c) -#define IDirectInputDevice7_CreateEffect(p,a,b,c,d) (p)->CreateEffect(a,b,c,d) -#define IDirectInputDevice7_EnumEffects(p,a,b,c) (p)->EnumEffects(a,b,c) -#define IDirectInputDevice7_GetEffectInfo(p,a,b) (p)->GetEffectInfo(a,b) -#define IDirectInputDevice7_GetForceFeedbackState(p,a) (p)->GetForceFeedbackState(a) -#define IDirectInputDevice7_SendForceFeedbackCommand(p,a) (p)->SendForceFeedbackCommand(a) -#define IDirectInputDevice7_EnumCreatedEffectObjects(p,a,b,c) (p)->EnumCreatedEffectObjects(a,b,c) -#define IDirectInputDevice7_Escape(p,a) (p)->Escape(a) -#define IDirectInputDevice7_Poll(p) (p)->Poll() -#define IDirectInputDevice7_SendDeviceData(p,a,b,c,d) (p)->SendDeviceData(a,b,c,d) -#define IDirectInputDevice7_EnumEffectsInFile(p,a,b,c,d) (p)->EnumEffectsInFile(a,b,c,d) -#define IDirectInputDevice7_WriteEffectToFile(p,a,b,c,d) (p)->WriteEffectToFile(a,b,c,d) -#endif - -#endif /* DIJ_RINGZERO */ - -#endif /* DIRECTINPUT_VERSION >= 0x0700 */ - -#if(DIRECTINPUT_VERSION >= 0x0800) - -#ifndef DIJ_RINGZERO - -#undef INTERFACE -#define INTERFACE IDirectInputDevice8W - -DECLARE_INTERFACE_(IDirectInputDevice8W, IUnknown) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID * ppvObj) PURE; - STDMETHOD_(ULONG,AddRef)(THIS) PURE; - STDMETHOD_(ULONG,Release)(THIS) PURE; - - /*** IDirectInputDevice8W methods ***/ - STDMETHOD(GetCapabilities)(THIS_ LPDIDEVCAPS) PURE; - STDMETHOD(EnumObjects)(THIS_ LPDIENUMDEVICEOBJECTSCALLBACKW,LPVOID,DWORD) PURE; - STDMETHOD(GetProperty)(THIS_ REFGUID,LPDIPROPHEADER) PURE; - STDMETHOD(SetProperty)(THIS_ REFGUID,LPCDIPROPHEADER) PURE; - STDMETHOD(Acquire)(THIS) PURE; - STDMETHOD(Unacquire)(THIS) PURE; - STDMETHOD(GetDeviceState)(THIS_ DWORD,LPVOID) PURE; - STDMETHOD(GetDeviceData)(THIS_ DWORD,LPDIDEVICEOBJECTDATA,LPDWORD,DWORD) PURE; - STDMETHOD(SetDataFormat)(THIS_ LPCDIDATAFORMAT) PURE; - STDMETHOD(SetEventNotification)(THIS_ HANDLE) PURE; - STDMETHOD(SetCooperativeLevel)(THIS_ HWND,DWORD) PURE; - STDMETHOD(GetObjectInfo)(THIS_ LPDIDEVICEOBJECTINSTANCEW,DWORD,DWORD) PURE; - STDMETHOD(GetDeviceInfo)(THIS_ LPDIDEVICEINSTANCEW) PURE; - STDMETHOD(RunControlPanel)(THIS_ HWND,DWORD) PURE; - STDMETHOD(Initialize)(THIS_ HINSTANCE,DWORD,REFGUID) PURE; - STDMETHOD(CreateEffect)(THIS_ REFGUID,LPCDIEFFECT,LPDIRECTINPUTEFFECT *,LPUNKNOWN) PURE; - STDMETHOD(EnumEffects)(THIS_ LPDIENUMEFFECTSCALLBACKW,LPVOID,DWORD) PURE; - STDMETHOD(GetEffectInfo)(THIS_ LPDIEFFECTINFOW,REFGUID) PURE; - STDMETHOD(GetForceFeedbackState)(THIS_ LPDWORD) PURE; - STDMETHOD(SendForceFeedbackCommand)(THIS_ DWORD) PURE; - STDMETHOD(EnumCreatedEffectObjects)(THIS_ LPDIENUMCREATEDEFFECTOBJECTSCALLBACK,LPVOID,DWORD) PURE; - STDMETHOD(Escape)(THIS_ LPDIEFFESCAPE) PURE; - STDMETHOD(Poll)(THIS) PURE; - STDMETHOD(SendDeviceData)(THIS_ DWORD,LPCDIDEVICEOBJECTDATA,LPDWORD,DWORD) PURE; - STDMETHOD(EnumEffectsInFile)(THIS_ LPCWSTR,LPDIENUMEFFECTSINFILECALLBACK,LPVOID,DWORD) PURE; - STDMETHOD(WriteEffectToFile)(THIS_ LPCWSTR,DWORD,LPDIFILEEFFECT,DWORD) PURE; - STDMETHOD(BuildActionMap)(THIS_ LPDIACTIONFORMATW,LPCWSTR,DWORD) PURE; - STDMETHOD(SetActionMap)(THIS_ LPDIACTIONFORMATW,LPCWSTR,DWORD) PURE; - STDMETHOD(GetImageInfo)(THIS_ LPDIDEVICEIMAGEINFOHEADERW) PURE; -}; - -typedef struct IDirectInputDevice8W *LPDIRECTINPUTDEVICE8W; - -#undef INTERFACE -#define INTERFACE IDirectInputDevice8A - -DECLARE_INTERFACE_(IDirectInputDevice8A, IUnknown) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID * ppvObj) PURE; - STDMETHOD_(ULONG,AddRef)(THIS) PURE; - STDMETHOD_(ULONG,Release)(THIS) PURE; - - /*** IDirectInputDevice8A methods ***/ - STDMETHOD(GetCapabilities)(THIS_ LPDIDEVCAPS) PURE; - STDMETHOD(EnumObjects)(THIS_ LPDIENUMDEVICEOBJECTSCALLBACKA,LPVOID,DWORD) PURE; - STDMETHOD(GetProperty)(THIS_ REFGUID,LPDIPROPHEADER) PURE; - STDMETHOD(SetProperty)(THIS_ REFGUID,LPCDIPROPHEADER) PURE; - STDMETHOD(Acquire)(THIS) PURE; - STDMETHOD(Unacquire)(THIS) PURE; - STDMETHOD(GetDeviceState)(THIS_ DWORD,LPVOID) PURE; - STDMETHOD(GetDeviceData)(THIS_ DWORD,LPDIDEVICEOBJECTDATA,LPDWORD,DWORD) PURE; - STDMETHOD(SetDataFormat)(THIS_ LPCDIDATAFORMAT) PURE; - STDMETHOD(SetEventNotification)(THIS_ HANDLE) PURE; - STDMETHOD(SetCooperativeLevel)(THIS_ HWND,DWORD) PURE; - STDMETHOD(GetObjectInfo)(THIS_ LPDIDEVICEOBJECTINSTANCEA,DWORD,DWORD) PURE; - STDMETHOD(GetDeviceInfo)(THIS_ LPDIDEVICEINSTANCEA) PURE; - STDMETHOD(RunControlPanel)(THIS_ HWND,DWORD) PURE; - STDMETHOD(Initialize)(THIS_ HINSTANCE,DWORD,REFGUID) PURE; - STDMETHOD(CreateEffect)(THIS_ REFGUID,LPCDIEFFECT,LPDIRECTINPUTEFFECT *,LPUNKNOWN) PURE; - STDMETHOD(EnumEffects)(THIS_ LPDIENUMEFFECTSCALLBACKA,LPVOID,DWORD) PURE; - STDMETHOD(GetEffectInfo)(THIS_ LPDIEFFECTINFOA,REFGUID) PURE; - STDMETHOD(GetForceFeedbackState)(THIS_ LPDWORD) PURE; - STDMETHOD(SendForceFeedbackCommand)(THIS_ DWORD) PURE; - STDMETHOD(EnumCreatedEffectObjects)(THIS_ LPDIENUMCREATEDEFFECTOBJECTSCALLBACK,LPVOID,DWORD) PURE; - STDMETHOD(Escape)(THIS_ LPDIEFFESCAPE) PURE; - STDMETHOD(Poll)(THIS) PURE; - STDMETHOD(SendDeviceData)(THIS_ DWORD,LPCDIDEVICEOBJECTDATA,LPDWORD,DWORD) PURE; - STDMETHOD(EnumEffectsInFile)(THIS_ LPCSTR,LPDIENUMEFFECTSINFILECALLBACK,LPVOID,DWORD) PURE; - STDMETHOD(WriteEffectToFile)(THIS_ LPCSTR,DWORD,LPDIFILEEFFECT,DWORD) PURE; - STDMETHOD(BuildActionMap)(THIS_ LPDIACTIONFORMATA,LPCSTR,DWORD) PURE; - STDMETHOD(SetActionMap)(THIS_ LPDIACTIONFORMATA,LPCSTR,DWORD) PURE; - STDMETHOD(GetImageInfo)(THIS_ LPDIDEVICEIMAGEINFOHEADERA) PURE; -}; - -typedef struct IDirectInputDevice8A *LPDIRECTINPUTDEVICE8A; - -#ifdef UNICODE -#define IID_IDirectInputDevice8 IID_IDirectInputDevice8W -#define IDirectInputDevice8 IDirectInputDevice8W -#define IDirectInputDevice8Vtbl IDirectInputDevice8WVtbl -#else -#define IID_IDirectInputDevice8 IID_IDirectInputDevice8A -#define IDirectInputDevice8 IDirectInputDevice8A -#define IDirectInputDevice8Vtbl IDirectInputDevice8AVtbl -#endif -typedef struct IDirectInputDevice8 *LPDIRECTINPUTDEVICE8; - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectInputDevice8_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) -#define IDirectInputDevice8_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirectInputDevice8_Release(p) (p)->lpVtbl->Release(p) -#define IDirectInputDevice8_GetCapabilities(p,a) (p)->lpVtbl->GetCapabilities(p,a) -#define IDirectInputDevice8_EnumObjects(p,a,b,c) (p)->lpVtbl->EnumObjects(p,a,b,c) -#define IDirectInputDevice8_GetProperty(p,a,b) (p)->lpVtbl->GetProperty(p,a,b) -#define IDirectInputDevice8_SetProperty(p,a,b) (p)->lpVtbl->SetProperty(p,a,b) -#define IDirectInputDevice8_Acquire(p) (p)->lpVtbl->Acquire(p) -#define IDirectInputDevice8_Unacquire(p) (p)->lpVtbl->Unacquire(p) -#define IDirectInputDevice8_GetDeviceState(p,a,b) (p)->lpVtbl->GetDeviceState(p,a,b) -#define IDirectInputDevice8_GetDeviceData(p,a,b,c,d) (p)->lpVtbl->GetDeviceData(p,a,b,c,d) -#define IDirectInputDevice8_SetDataFormat(p,a) (p)->lpVtbl->SetDataFormat(p,a) -#define IDirectInputDevice8_SetEventNotification(p,a) (p)->lpVtbl->SetEventNotification(p,a) -#define IDirectInputDevice8_SetCooperativeLevel(p,a,b) (p)->lpVtbl->SetCooperativeLevel(p,a,b) -#define IDirectInputDevice8_GetObjectInfo(p,a,b,c) (p)->lpVtbl->GetObjectInfo(p,a,b,c) -#define IDirectInputDevice8_GetDeviceInfo(p,a) (p)->lpVtbl->GetDeviceInfo(p,a) -#define IDirectInputDevice8_RunControlPanel(p,a,b) (p)->lpVtbl->RunControlPanel(p,a,b) -#define IDirectInputDevice8_Initialize(p,a,b,c) (p)->lpVtbl->Initialize(p,a,b,c) -#define IDirectInputDevice8_CreateEffect(p,a,b,c,d) (p)->lpVtbl->CreateEffect(p,a,b,c,d) -#define IDirectInputDevice8_EnumEffects(p,a,b,c) (p)->lpVtbl->EnumEffects(p,a,b,c) -#define IDirectInputDevice8_GetEffectInfo(p,a,b) (p)->lpVtbl->GetEffectInfo(p,a,b) -#define IDirectInputDevice8_GetForceFeedbackState(p,a) (p)->lpVtbl->GetForceFeedbackState(p,a) -#define IDirectInputDevice8_SendForceFeedbackCommand(p,a) (p)->lpVtbl->SendForceFeedbackCommand(p,a) -#define IDirectInputDevice8_EnumCreatedEffectObjects(p,a,b,c) (p)->lpVtbl->EnumCreatedEffectObjects(p,a,b,c) -#define IDirectInputDevice8_Escape(p,a) (p)->lpVtbl->Escape(p,a) -#define IDirectInputDevice8_Poll(p) (p)->lpVtbl->Poll(p) -#define IDirectInputDevice8_SendDeviceData(p,a,b,c,d) (p)->lpVtbl->SendDeviceData(p,a,b,c,d) -#define IDirectInputDevice8_EnumEffectsInFile(p,a,b,c,d) (p)->lpVtbl->EnumEffectsInFile(p,a,b,c,d) -#define IDirectInputDevice8_WriteEffectToFile(p,a,b,c,d) (p)->lpVtbl->WriteEffectToFile(p,a,b,c,d) -#define IDirectInputDevice8_BuildActionMap(p,a,b,c) (p)->lpVtbl->BuildActionMap(p,a,b,c) -#define IDirectInputDevice8_SetActionMap(p,a,b,c) (p)->lpVtbl->SetActionMap(p,a,b,c) -#define IDirectInputDevice8_GetImageInfo(p,a) (p)->lpVtbl->GetImageInfo(p,a) -#else -#define IDirectInputDevice8_QueryInterface(p,a,b) (p)->QueryInterface(a,b) -#define IDirectInputDevice8_AddRef(p) (p)->AddRef() -#define IDirectInputDevice8_Release(p) (p)->Release() -#define IDirectInputDevice8_GetCapabilities(p,a) (p)->GetCapabilities(a) -#define IDirectInputDevice8_EnumObjects(p,a,b,c) (p)->EnumObjects(a,b,c) -#define IDirectInputDevice8_GetProperty(p,a,b) (p)->GetProperty(a,b) -#define IDirectInputDevice8_SetProperty(p,a,b) (p)->SetProperty(a,b) -#define IDirectInputDevice8_Acquire(p) (p)->Acquire() -#define IDirectInputDevice8_Unacquire(p) (p)->Unacquire() -#define IDirectInputDevice8_GetDeviceState(p,a,b) (p)->GetDeviceState(a,b) -#define IDirectInputDevice8_GetDeviceData(p,a,b,c,d) (p)->GetDeviceData(a,b,c,d) -#define IDirectInputDevice8_SetDataFormat(p,a) (p)->SetDataFormat(a) -#define IDirectInputDevice8_SetEventNotification(p,a) (p)->SetEventNotification(a) -#define IDirectInputDevice8_SetCooperativeLevel(p,a,b) (p)->SetCooperativeLevel(a,b) -#define IDirectInputDevice8_GetObjectInfo(p,a,b,c) (p)->GetObjectInfo(a,b,c) -#define IDirectInputDevice8_GetDeviceInfo(p,a) (p)->GetDeviceInfo(a) -#define IDirectInputDevice8_RunControlPanel(p,a,b) (p)->RunControlPanel(a,b) -#define IDirectInputDevice8_Initialize(p,a,b,c) (p)->Initialize(a,b,c) -#define IDirectInputDevice8_CreateEffect(p,a,b,c,d) (p)->CreateEffect(a,b,c,d) -#define IDirectInputDevice8_EnumEffects(p,a,b,c) (p)->EnumEffects(a,b,c) -#define IDirectInputDevice8_GetEffectInfo(p,a,b) (p)->GetEffectInfo(a,b) -#define IDirectInputDevice8_GetForceFeedbackState(p,a) (p)->GetForceFeedbackState(a) -#define IDirectInputDevice8_SendForceFeedbackCommand(p,a) (p)->SendForceFeedbackCommand(a) -#define IDirectInputDevice8_EnumCreatedEffectObjects(p,a,b,c) (p)->EnumCreatedEffectObjects(a,b,c) -#define IDirectInputDevice8_Escape(p,a) (p)->Escape(a) -#define IDirectInputDevice8_Poll(p) (p)->Poll() -#define IDirectInputDevice8_SendDeviceData(p,a,b,c,d) (p)->SendDeviceData(a,b,c,d) -#define IDirectInputDevice8_EnumEffectsInFile(p,a,b,c,d) (p)->EnumEffectsInFile(a,b,c,d) -#define IDirectInputDevice8_WriteEffectToFile(p,a,b,c,d) (p)->WriteEffectToFile(a,b,c,d) -#define IDirectInputDevice8_BuildActionMap(p,a,b,c) (p)->BuildActionMap(a,b,c) -#define IDirectInputDevice8_SetActionMap(p,a,b,c) (p)->SetActionMap(a,b,c) -#define IDirectInputDevice8_GetImageInfo(p,a) (p)->GetImageInfo(a) -#endif - -#endif /* DIJ_RINGZERO */ - -#endif /* DIRECTINPUT_VERSION >= 0x0800 */ - -/**************************************************************************** - * - * Mouse - * - ****************************************************************************/ - -#ifndef DIJ_RINGZERO - -typedef struct _DIMOUSESTATE { - LONG lX; - LONG lY; - LONG lZ; - BYTE rgbButtons[4]; -} DIMOUSESTATE, *LPDIMOUSESTATE; - -#if DIRECTINPUT_VERSION >= 0x0700 -typedef struct _DIMOUSESTATE2 { - LONG lX; - LONG lY; - LONG lZ; - BYTE rgbButtons[8]; -} DIMOUSESTATE2, *LPDIMOUSESTATE2; -#endif - - -#define DIMOFS_X FIELD_OFFSET(DIMOUSESTATE, lX) -#define DIMOFS_Y FIELD_OFFSET(DIMOUSESTATE, lY) -#define DIMOFS_Z FIELD_OFFSET(DIMOUSESTATE, lZ) -#define DIMOFS_BUTTON0 (FIELD_OFFSET(DIMOUSESTATE, rgbButtons) + 0) -#define DIMOFS_BUTTON1 (FIELD_OFFSET(DIMOUSESTATE, rgbButtons) + 1) -#define DIMOFS_BUTTON2 (FIELD_OFFSET(DIMOUSESTATE, rgbButtons) + 2) -#define DIMOFS_BUTTON3 (FIELD_OFFSET(DIMOUSESTATE, rgbButtons) + 3) -#if (DIRECTINPUT_VERSION >= 0x0700) -#define DIMOFS_BUTTON4 (FIELD_OFFSET(DIMOUSESTATE2, rgbButtons) + 4) -#define DIMOFS_BUTTON5 (FIELD_OFFSET(DIMOUSESTATE2, rgbButtons) + 5) -#define DIMOFS_BUTTON6 (FIELD_OFFSET(DIMOUSESTATE2, rgbButtons) + 6) -#define DIMOFS_BUTTON7 (FIELD_OFFSET(DIMOUSESTATE2, rgbButtons) + 7) -#endif -#endif /* DIJ_RINGZERO */ - -/**************************************************************************** - * - * Keyboard - * - ****************************************************************************/ - -#ifndef DIJ_RINGZERO - -/**************************************************************************** - * - * DirectInput keyboard scan codes - * - ****************************************************************************/ -#define DIK_ESCAPE 0x01 -#define DIK_1 0x02 -#define DIK_2 0x03 -#define DIK_3 0x04 -#define DIK_4 0x05 -#define DIK_5 0x06 -#define DIK_6 0x07 -#define DIK_7 0x08 -#define DIK_8 0x09 -#define DIK_9 0x0A -#define DIK_0 0x0B -#define DIK_MINUS 0x0C /* - on main keyboard */ -#define DIK_EQUALS 0x0D -#define DIK_BACK 0x0E /* backspace */ -#define DIK_TAB 0x0F -#define DIK_Q 0x10 -#define DIK_W 0x11 -#define DIK_E 0x12 -#define DIK_R 0x13 -#define DIK_T 0x14 -#define DIK_Y 0x15 -#define DIK_U 0x16 -#define DIK_I 0x17 -#define DIK_O 0x18 -#define DIK_P 0x19 -#define DIK_LBRACKET 0x1A -#define DIK_RBRACKET 0x1B -#define DIK_RETURN 0x1C /* Enter on main keyboard */ -#define DIK_LCONTROL 0x1D -#define DIK_A 0x1E -#define DIK_S 0x1F -#define DIK_D 0x20 -#define DIK_F 0x21 -#define DIK_G 0x22 -#define DIK_H 0x23 -#define DIK_J 0x24 -#define DIK_K 0x25 -#define DIK_L 0x26 -#define DIK_SEMICOLON 0x27 -#define DIK_APOSTROPHE 0x28 -#define DIK_GRAVE 0x29 /* accent grave */ -#define DIK_LSHIFT 0x2A -#define DIK_BACKSLASH 0x2B -#define DIK_Z 0x2C -#define DIK_X 0x2D -#define DIK_C 0x2E -#define DIK_V 0x2F -#define DIK_B 0x30 -#define DIK_N 0x31 -#define DIK_M 0x32 -#define DIK_COMMA 0x33 -#define DIK_PERIOD 0x34 /* . on main keyboard */ -#define DIK_SLASH 0x35 /* / on main keyboard */ -#define DIK_RSHIFT 0x36 -#define DIK_MULTIPLY 0x37 /* * on numeric keypad */ -#define DIK_LMENU 0x38 /* left Alt */ -#define DIK_SPACE 0x39 -#define DIK_CAPITAL 0x3A -#define DIK_F1 0x3B -#define DIK_F2 0x3C -#define DIK_F3 0x3D -#define DIK_F4 0x3E -#define DIK_F5 0x3F -#define DIK_F6 0x40 -#define DIK_F7 0x41 -#define DIK_F8 0x42 -#define DIK_F9 0x43 -#define DIK_F10 0x44 -#define DIK_NUMLOCK 0x45 -#define DIK_SCROLL 0x46 /* Scroll Lock */ -#define DIK_NUMPAD7 0x47 -#define DIK_NUMPAD8 0x48 -#define DIK_NUMPAD9 0x49 -#define DIK_SUBTRACT 0x4A /* - on numeric keypad */ -#define DIK_NUMPAD4 0x4B -#define DIK_NUMPAD5 0x4C -#define DIK_NUMPAD6 0x4D -#define DIK_ADD 0x4E /* + on numeric keypad */ -#define DIK_NUMPAD1 0x4F -#define DIK_NUMPAD2 0x50 -#define DIK_NUMPAD3 0x51 -#define DIK_NUMPAD0 0x52 -#define DIK_DECIMAL 0x53 /* . on numeric keypad */ -#define DIK_OEM_102 0x56 /* <> or \| on RT 102-key keyboard (Non-U.S.) */ -#define DIK_F11 0x57 -#define DIK_F12 0x58 -#define DIK_F13 0x64 /* (NEC PC98) */ -#define DIK_F14 0x65 /* (NEC PC98) */ -#define DIK_F15 0x66 /* (NEC PC98) */ -#define DIK_KANA 0x70 /* (Japanese keyboard) */ -#define DIK_ABNT_C1 0x73 /* /? on Brazilian keyboard */ -#define DIK_CONVERT 0x79 /* (Japanese keyboard) */ -#define DIK_NOCONVERT 0x7B /* (Japanese keyboard) */ -#define DIK_YEN 0x7D /* (Japanese keyboard) */ -#define DIK_ABNT_C2 0x7E /* Numpad . on Brazilian keyboard */ -#define DIK_NUMPADEQUALS 0x8D /* = on numeric keypad (NEC PC98) */ -#define DIK_PREVTRACK 0x90 /* Previous Track (DIK_CIRCUMFLEX on Japanese keyboard) */ -#define DIK_AT 0x91 /* (NEC PC98) */ -#define DIK_COLON 0x92 /* (NEC PC98) */ -#define DIK_UNDERLINE 0x93 /* (NEC PC98) */ -#define DIK_KANJI 0x94 /* (Japanese keyboard) */ -#define DIK_STOP 0x95 /* (NEC PC98) */ -#define DIK_AX 0x96 /* (Japan AX) */ -#define DIK_UNLABELED 0x97 /* (J3100) */ -#define DIK_NEXTTRACK 0x99 /* Next Track */ -#define DIK_NUMPADENTER 0x9C /* Enter on numeric keypad */ -#define DIK_RCONTROL 0x9D -#define DIK_MUTE 0xA0 /* Mute */ -#define DIK_CALCULATOR 0xA1 /* Calculator */ -#define DIK_PLAYPAUSE 0xA2 /* Play / Pause */ -#define DIK_MEDIASTOP 0xA4 /* Media Stop */ -#define DIK_VOLUMEDOWN 0xAE /* Volume - */ -#define DIK_VOLUMEUP 0xB0 /* Volume + */ -#define DIK_WEBHOME 0xB2 /* Web home */ -#define DIK_NUMPADCOMMA 0xB3 /* , on numeric keypad (NEC PC98) */ -#define DIK_DIVIDE 0xB5 /* / on numeric keypad */ -#define DIK_SYSRQ 0xB7 -#define DIK_RMENU 0xB8 /* right Alt */ -#define DIK_PAUSE 0xC5 /* Pause */ -#define DIK_HOME 0xC7 /* Home on arrow keypad */ -#define DIK_UP 0xC8 /* UpArrow on arrow keypad */ -#define DIK_PRIOR 0xC9 /* PgUp on arrow keypad */ -#define DIK_LEFT 0xCB /* LeftArrow on arrow keypad */ -#define DIK_RIGHT 0xCD /* RightArrow on arrow keypad */ -#define DIK_END 0xCF /* End on arrow keypad */ -#define DIK_DOWN 0xD0 /* DownArrow on arrow keypad */ -#define DIK_NEXT 0xD1 /* PgDn on arrow keypad */ -#define DIK_INSERT 0xD2 /* Insert on arrow keypad */ -#define DIK_DELETE 0xD3 /* Delete on arrow keypad */ -#define DIK_LWIN 0xDB /* Left Windows key */ -#define DIK_RWIN 0xDC /* Right Windows key */ -#define DIK_APPS 0xDD /* AppMenu key */ -#define DIK_POWER 0xDE /* System Power */ -#define DIK_SLEEP 0xDF /* System Sleep */ -#define DIK_WAKE 0xE3 /* System Wake */ -#define DIK_WEBSEARCH 0xE5 /* Web Search */ -#define DIK_WEBFAVORITES 0xE6 /* Web Favorites */ -#define DIK_WEBREFRESH 0xE7 /* Web Refresh */ -#define DIK_WEBSTOP 0xE8 /* Web Stop */ -#define DIK_WEBFORWARD 0xE9 /* Web Forward */ -#define DIK_WEBBACK 0xEA /* Web Back */ -#define DIK_MYCOMPUTER 0xEB /* My Computer */ -#define DIK_MAIL 0xEC /* Mail */ -#define DIK_MEDIASELECT 0xED /* Media Select */ - -/* - * Alternate names for keys, to facilitate transition from DOS. - */ -#define DIK_BACKSPACE DIK_BACK /* backspace */ -#define DIK_NUMPADSTAR DIK_MULTIPLY /* * on numeric keypad */ -#define DIK_LALT DIK_LMENU /* left Alt */ -#define DIK_CAPSLOCK DIK_CAPITAL /* CapsLock */ -#define DIK_NUMPADMINUS DIK_SUBTRACT /* - on numeric keypad */ -#define DIK_NUMPADPLUS DIK_ADD /* + on numeric keypad */ -#define DIK_NUMPADPERIOD DIK_DECIMAL /* . on numeric keypad */ -#define DIK_NUMPADSLASH DIK_DIVIDE /* / on numeric keypad */ -#define DIK_RALT DIK_RMENU /* right Alt */ -#define DIK_UPARROW DIK_UP /* UpArrow on arrow keypad */ -#define DIK_PGUP DIK_PRIOR /* PgUp on arrow keypad */ -#define DIK_LEFTARROW DIK_LEFT /* LeftArrow on arrow keypad */ -#define DIK_RIGHTARROW DIK_RIGHT /* RightArrow on arrow keypad */ -#define DIK_DOWNARROW DIK_DOWN /* DownArrow on arrow keypad */ -#define DIK_PGDN DIK_NEXT /* PgDn on arrow keypad */ - -/* - * Alternate names for keys originally not used on US keyboards. - */ -#define DIK_CIRCUMFLEX DIK_PREVTRACK /* Japanese keyboard */ - -#endif /* DIJ_RINGZERO */ - -/**************************************************************************** - * - * Joystick - * - ****************************************************************************/ - -#ifndef DIJ_RINGZERO - -typedef struct DIJOYSTATE { - LONG lX; /* x-axis position */ - LONG lY; /* y-axis position */ - LONG lZ; /* z-axis position */ - LONG lRx; /* x-axis rotation */ - LONG lRy; /* y-axis rotation */ - LONG lRz; /* z-axis rotation */ - LONG rglSlider[2]; /* extra axes positions */ - DWORD rgdwPOV[4]; /* POV directions */ - BYTE rgbButtons[32]; /* 32 buttons */ -} DIJOYSTATE, *LPDIJOYSTATE; - -typedef struct DIJOYSTATE2 { - LONG lX; /* x-axis position */ - LONG lY; /* y-axis position */ - LONG lZ; /* z-axis position */ - LONG lRx; /* x-axis rotation */ - LONG lRy; /* y-axis rotation */ - LONG lRz; /* z-axis rotation */ - LONG rglSlider[2]; /* extra axes positions */ - DWORD rgdwPOV[4]; /* POV directions */ - BYTE rgbButtons[128]; /* 128 buttons */ - LONG lVX; /* x-axis velocity */ - LONG lVY; /* y-axis velocity */ - LONG lVZ; /* z-axis velocity */ - LONG lVRx; /* x-axis angular velocity */ - LONG lVRy; /* y-axis angular velocity */ - LONG lVRz; /* z-axis angular velocity */ - LONG rglVSlider[2]; /* extra axes velocities */ - LONG lAX; /* x-axis acceleration */ - LONG lAY; /* y-axis acceleration */ - LONG lAZ; /* z-axis acceleration */ - LONG lARx; /* x-axis angular acceleration */ - LONG lARy; /* y-axis angular acceleration */ - LONG lARz; /* z-axis angular acceleration */ - LONG rglASlider[2]; /* extra axes accelerations */ - LONG lFX; /* x-axis force */ - LONG lFY; /* y-axis force */ - LONG lFZ; /* z-axis force */ - LONG lFRx; /* x-axis torque */ - LONG lFRy; /* y-axis torque */ - LONG lFRz; /* z-axis torque */ - LONG rglFSlider[2]; /* extra axes forces */ -} DIJOYSTATE2, *LPDIJOYSTATE2; - -#define DIJOFS_X FIELD_OFFSET(DIJOYSTATE, lX) -#define DIJOFS_Y FIELD_OFFSET(DIJOYSTATE, lY) -#define DIJOFS_Z FIELD_OFFSET(DIJOYSTATE, lZ) -#define DIJOFS_RX FIELD_OFFSET(DIJOYSTATE, lRx) -#define DIJOFS_RY FIELD_OFFSET(DIJOYSTATE, lRy) -#define DIJOFS_RZ FIELD_OFFSET(DIJOYSTATE, lRz) -#define DIJOFS_SLIDER(n) (FIELD_OFFSET(DIJOYSTATE, rglSlider) + \ - (n) * sizeof(LONG)) -#define DIJOFS_POV(n) (FIELD_OFFSET(DIJOYSTATE, rgdwPOV) + \ - (n) * sizeof(DWORD)) -#define DIJOFS_BUTTON(n) (FIELD_OFFSET(DIJOYSTATE, rgbButtons) + (n)) -#define DIJOFS_BUTTON0 DIJOFS_BUTTON(0) -#define DIJOFS_BUTTON1 DIJOFS_BUTTON(1) -#define DIJOFS_BUTTON2 DIJOFS_BUTTON(2) -#define DIJOFS_BUTTON3 DIJOFS_BUTTON(3) -#define DIJOFS_BUTTON4 DIJOFS_BUTTON(4) -#define DIJOFS_BUTTON5 DIJOFS_BUTTON(5) -#define DIJOFS_BUTTON6 DIJOFS_BUTTON(6) -#define DIJOFS_BUTTON7 DIJOFS_BUTTON(7) -#define DIJOFS_BUTTON8 DIJOFS_BUTTON(8) -#define DIJOFS_BUTTON9 DIJOFS_BUTTON(9) -#define DIJOFS_BUTTON10 DIJOFS_BUTTON(10) -#define DIJOFS_BUTTON11 DIJOFS_BUTTON(11) -#define DIJOFS_BUTTON12 DIJOFS_BUTTON(12) -#define DIJOFS_BUTTON13 DIJOFS_BUTTON(13) -#define DIJOFS_BUTTON14 DIJOFS_BUTTON(14) -#define DIJOFS_BUTTON15 DIJOFS_BUTTON(15) -#define DIJOFS_BUTTON16 DIJOFS_BUTTON(16) -#define DIJOFS_BUTTON17 DIJOFS_BUTTON(17) -#define DIJOFS_BUTTON18 DIJOFS_BUTTON(18) -#define DIJOFS_BUTTON19 DIJOFS_BUTTON(19) -#define DIJOFS_BUTTON20 DIJOFS_BUTTON(20) -#define DIJOFS_BUTTON21 DIJOFS_BUTTON(21) -#define DIJOFS_BUTTON22 DIJOFS_BUTTON(22) -#define DIJOFS_BUTTON23 DIJOFS_BUTTON(23) -#define DIJOFS_BUTTON24 DIJOFS_BUTTON(24) -#define DIJOFS_BUTTON25 DIJOFS_BUTTON(25) -#define DIJOFS_BUTTON26 DIJOFS_BUTTON(26) -#define DIJOFS_BUTTON27 DIJOFS_BUTTON(27) -#define DIJOFS_BUTTON28 DIJOFS_BUTTON(28) -#define DIJOFS_BUTTON29 DIJOFS_BUTTON(29) -#define DIJOFS_BUTTON30 DIJOFS_BUTTON(30) -#define DIJOFS_BUTTON31 DIJOFS_BUTTON(31) - - -#endif /* DIJ_RINGZERO */ - -/**************************************************************************** - * - * IDirectInput - * - ****************************************************************************/ - -#ifndef DIJ_RINGZERO - -#define DIENUM_STOP 0 -#define DIENUM_CONTINUE 1 - -typedef BOOL (FAR PASCAL * LPDIENUMDEVICESCALLBACKA)(LPCDIDEVICEINSTANCEA, LPVOID); -typedef BOOL (FAR PASCAL * LPDIENUMDEVICESCALLBACKW)(LPCDIDEVICEINSTANCEW, LPVOID); -#ifdef UNICODE -#define LPDIENUMDEVICESCALLBACK LPDIENUMDEVICESCALLBACKW -#else -#define LPDIENUMDEVICESCALLBACK LPDIENUMDEVICESCALLBACKA -#endif // !UNICODE -typedef BOOL (FAR PASCAL * LPDICONFIGUREDEVICESCALLBACK)(IUnknown FAR *, LPVOID); - -#define DIEDFL_ALLDEVICES 0x00000000 -#define DIEDFL_ATTACHEDONLY 0x00000001 -#if(DIRECTINPUT_VERSION >= 0x0500) -#define DIEDFL_FORCEFEEDBACK 0x00000100 -#endif /* DIRECTINPUT_VERSION >= 0x0500 */ -#if(DIRECTINPUT_VERSION >= 0x050a) -#define DIEDFL_INCLUDEALIASES 0x00010000 -#define DIEDFL_INCLUDEPHANTOMS 0x00020000 -#endif /* DIRECTINPUT_VERSION >= 0x050a */ -#if(DIRECTINPUT_VERSION >= 0x0800) -#define DIEDFL_INCLUDEHIDDEN 0x00040000 -#endif /* DIRECTINPUT_VERSION >= 0x0800 */ - - -#if(DIRECTINPUT_VERSION >= 0x0800) -typedef BOOL (FAR PASCAL * LPDIENUMDEVICESBYSEMANTICSCBA)(LPCDIDEVICEINSTANCEA, LPDIRECTINPUTDEVICE8A, DWORD, DWORD, LPVOID); -typedef BOOL (FAR PASCAL * LPDIENUMDEVICESBYSEMANTICSCBW)(LPCDIDEVICEINSTANCEW, LPDIRECTINPUTDEVICE8W, DWORD, DWORD, LPVOID); -#ifdef UNICODE -#define LPDIENUMDEVICESBYSEMANTICSCB LPDIENUMDEVICESBYSEMANTICSCBW -#else -#define LPDIENUMDEVICESBYSEMANTICSCB LPDIENUMDEVICESBYSEMANTICSCBA -#endif // !UNICODE -#endif /* DIRECTINPUT_VERSION >= 0x0800 */ - -#if(DIRECTINPUT_VERSION >= 0x0800) -#define DIEDBS_MAPPEDPRI1 0x00000001 -#define DIEDBS_MAPPEDPRI2 0x00000002 -#define DIEDBS_RECENTDEVICE 0x00000010 -#define DIEDBS_NEWDEVICE 0x00000020 -#endif /* DIRECTINPUT_VERSION >= 0x0800 */ - -#if(DIRECTINPUT_VERSION >= 0x0800) -#define DIEDBSFL_ATTACHEDONLY 0x00000000 -#define DIEDBSFL_THISUSER 0x00000010 -#define DIEDBSFL_FORCEFEEDBACK DIEDFL_FORCEFEEDBACK -#define DIEDBSFL_AVAILABLEDEVICES 0x00001000 -#define DIEDBSFL_MULTIMICEKEYBOARDS 0x00002000 -#define DIEDBSFL_NONGAMINGDEVICES 0x00004000 -#define DIEDBSFL_VALID 0x00007110 -#endif /* DIRECTINPUT_VERSION >= 0x0800 */ - -#undef INTERFACE -#define INTERFACE IDirectInputW - -DECLARE_INTERFACE_(IDirectInputW, IUnknown) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID * ppvObj) PURE; - STDMETHOD_(ULONG,AddRef)(THIS) PURE; - STDMETHOD_(ULONG,Release)(THIS) PURE; - - /*** IDirectInputW methods ***/ - STDMETHOD(CreateDevice)(THIS_ REFGUID,LPDIRECTINPUTDEVICEW *,LPUNKNOWN) PURE; - STDMETHOD(EnumDevices)(THIS_ DWORD,LPDIENUMDEVICESCALLBACKW,LPVOID,DWORD) PURE; - STDMETHOD(GetDeviceStatus)(THIS_ REFGUID) PURE; - STDMETHOD(RunControlPanel)(THIS_ HWND,DWORD) PURE; - STDMETHOD(Initialize)(THIS_ HINSTANCE,DWORD) PURE; -}; - -typedef struct IDirectInputW *LPDIRECTINPUTW; - -#undef INTERFACE -#define INTERFACE IDirectInputA - -DECLARE_INTERFACE_(IDirectInputA, IUnknown) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID * ppvObj) PURE; - STDMETHOD_(ULONG,AddRef)(THIS) PURE; - STDMETHOD_(ULONG,Release)(THIS) PURE; - - /*** IDirectInputA methods ***/ - STDMETHOD(CreateDevice)(THIS_ REFGUID,LPDIRECTINPUTDEVICEA *,LPUNKNOWN) PURE; - STDMETHOD(EnumDevices)(THIS_ DWORD,LPDIENUMDEVICESCALLBACKA,LPVOID,DWORD) PURE; - STDMETHOD(GetDeviceStatus)(THIS_ REFGUID) PURE; - STDMETHOD(RunControlPanel)(THIS_ HWND,DWORD) PURE; - STDMETHOD(Initialize)(THIS_ HINSTANCE,DWORD) PURE; -}; - -typedef struct IDirectInputA *LPDIRECTINPUTA; - -#ifdef UNICODE -#define IID_IDirectInput IID_IDirectInputW -#define IDirectInput IDirectInputW -#define IDirectInputVtbl IDirectInputWVtbl -#else -#define IID_IDirectInput IID_IDirectInputA -#define IDirectInput IDirectInputA -#define IDirectInputVtbl IDirectInputAVtbl -#endif -typedef struct IDirectInput *LPDIRECTINPUT; - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectInput_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) -#define IDirectInput_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirectInput_Release(p) (p)->lpVtbl->Release(p) -#define IDirectInput_CreateDevice(p,a,b,c) (p)->lpVtbl->CreateDevice(p,a,b,c) -#define IDirectInput_EnumDevices(p,a,b,c,d) (p)->lpVtbl->EnumDevices(p,a,b,c,d) -#define IDirectInput_GetDeviceStatus(p,a) (p)->lpVtbl->GetDeviceStatus(p,a) -#define IDirectInput_RunControlPanel(p,a,b) (p)->lpVtbl->RunControlPanel(p,a,b) -#define IDirectInput_Initialize(p,a,b) (p)->lpVtbl->Initialize(p,a,b) -#else -#define IDirectInput_QueryInterface(p,a,b) (p)->QueryInterface(a,b) -#define IDirectInput_AddRef(p) (p)->AddRef() -#define IDirectInput_Release(p) (p)->Release() -#define IDirectInput_CreateDevice(p,a,b,c) (p)->CreateDevice(a,b,c) -#define IDirectInput_EnumDevices(p,a,b,c,d) (p)->EnumDevices(a,b,c,d) -#define IDirectInput_GetDeviceStatus(p,a) (p)->GetDeviceStatus(a) -#define IDirectInput_RunControlPanel(p,a,b) (p)->RunControlPanel(a,b) -#define IDirectInput_Initialize(p,a,b) (p)->Initialize(a,b) -#endif - -#undef INTERFACE -#define INTERFACE IDirectInput2W - -DECLARE_INTERFACE_(IDirectInput2W, IDirectInputW) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID * ppvObj) PURE; - STDMETHOD_(ULONG,AddRef)(THIS) PURE; - STDMETHOD_(ULONG,Release)(THIS) PURE; - - /*** IDirectInputW methods ***/ - STDMETHOD(CreateDevice)(THIS_ REFGUID,LPDIRECTINPUTDEVICEW *,LPUNKNOWN) PURE; - STDMETHOD(EnumDevices)(THIS_ DWORD,LPDIENUMDEVICESCALLBACKW,LPVOID,DWORD) PURE; - STDMETHOD(GetDeviceStatus)(THIS_ REFGUID) PURE; - STDMETHOD(RunControlPanel)(THIS_ HWND,DWORD) PURE; - STDMETHOD(Initialize)(THIS_ HINSTANCE,DWORD) PURE; - - /*** IDirectInput2W methods ***/ - STDMETHOD(FindDevice)(THIS_ REFGUID,LPCWSTR,LPGUID) PURE; -}; - -typedef struct IDirectInput2W *LPDIRECTINPUT2W; - -#undef INTERFACE -#define INTERFACE IDirectInput2A - -DECLARE_INTERFACE_(IDirectInput2A, IDirectInputA) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID * ppvObj) PURE; - STDMETHOD_(ULONG,AddRef)(THIS) PURE; - STDMETHOD_(ULONG,Release)(THIS) PURE; - - /*** IDirectInputA methods ***/ - STDMETHOD(CreateDevice)(THIS_ REFGUID,LPDIRECTINPUTDEVICEA *,LPUNKNOWN) PURE; - STDMETHOD(EnumDevices)(THIS_ DWORD,LPDIENUMDEVICESCALLBACKA,LPVOID,DWORD) PURE; - STDMETHOD(GetDeviceStatus)(THIS_ REFGUID) PURE; - STDMETHOD(RunControlPanel)(THIS_ HWND,DWORD) PURE; - STDMETHOD(Initialize)(THIS_ HINSTANCE,DWORD) PURE; - - /*** IDirectInput2A methods ***/ - STDMETHOD(FindDevice)(THIS_ REFGUID,LPCSTR,LPGUID) PURE; -}; - -typedef struct IDirectInput2A *LPDIRECTINPUT2A; - -#ifdef UNICODE -#define IID_IDirectInput2 IID_IDirectInput2W -#define IDirectInput2 IDirectInput2W -#define IDirectInput2Vtbl IDirectInput2WVtbl -#else -#define IID_IDirectInput2 IID_IDirectInput2A -#define IDirectInput2 IDirectInput2A -#define IDirectInput2Vtbl IDirectInput2AVtbl -#endif -typedef struct IDirectInput2 *LPDIRECTINPUT2; - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectInput2_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) -#define IDirectInput2_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirectInput2_Release(p) (p)->lpVtbl->Release(p) -#define IDirectInput2_CreateDevice(p,a,b,c) (p)->lpVtbl->CreateDevice(p,a,b,c) -#define IDirectInput2_EnumDevices(p,a,b,c,d) (p)->lpVtbl->EnumDevices(p,a,b,c,d) -#define IDirectInput2_GetDeviceStatus(p,a) (p)->lpVtbl->GetDeviceStatus(p,a) -#define IDirectInput2_RunControlPanel(p,a,b) (p)->lpVtbl->RunControlPanel(p,a,b) -#define IDirectInput2_Initialize(p,a,b) (p)->lpVtbl->Initialize(p,a,b) -#define IDirectInput2_FindDevice(p,a,b,c) (p)->lpVtbl->FindDevice(p,a,b,c) -#else -#define IDirectInput2_QueryInterface(p,a,b) (p)->QueryInterface(a,b) -#define IDirectInput2_AddRef(p) (p)->AddRef() -#define IDirectInput2_Release(p) (p)->Release() -#define IDirectInput2_CreateDevice(p,a,b,c) (p)->CreateDevice(a,b,c) -#define IDirectInput2_EnumDevices(p,a,b,c,d) (p)->EnumDevices(a,b,c,d) -#define IDirectInput2_GetDeviceStatus(p,a) (p)->GetDeviceStatus(a) -#define IDirectInput2_RunControlPanel(p,a,b) (p)->RunControlPanel(a,b) -#define IDirectInput2_Initialize(p,a,b) (p)->Initialize(a,b) -#define IDirectInput2_FindDevice(p,a,b,c) (p)->FindDevice(a,b,c) -#endif - - -#undef INTERFACE -#define INTERFACE IDirectInput7W - -DECLARE_INTERFACE_(IDirectInput7W, IDirectInput2W) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID * ppvObj) PURE; - STDMETHOD_(ULONG,AddRef)(THIS) PURE; - STDMETHOD_(ULONG,Release)(THIS) PURE; - - /*** IDirectInput2W methods ***/ - STDMETHOD(CreateDevice)(THIS_ REFGUID,LPDIRECTINPUTDEVICEW *,LPUNKNOWN) PURE; - STDMETHOD(EnumDevices)(THIS_ DWORD,LPDIENUMDEVICESCALLBACKW,LPVOID,DWORD) PURE; - STDMETHOD(GetDeviceStatus)(THIS_ REFGUID) PURE; - STDMETHOD(RunControlPanel)(THIS_ HWND,DWORD) PURE; - STDMETHOD(Initialize)(THIS_ HINSTANCE,DWORD) PURE; - STDMETHOD(FindDevice)(THIS_ REFGUID,LPCWSTR,LPGUID) PURE; - - /*** IDirectInput7W methods ***/ - STDMETHOD(CreateDeviceEx)(THIS_ REFGUID,REFIID,LPVOID *,LPUNKNOWN) PURE; -}; - -typedef struct IDirectInput7W *LPDIRECTINPUT7W; - -#undef INTERFACE -#define INTERFACE IDirectInput7A - -DECLARE_INTERFACE_(IDirectInput7A, IDirectInput2A) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID * ppvObj) PURE; - STDMETHOD_(ULONG,AddRef)(THIS) PURE; - STDMETHOD_(ULONG,Release)(THIS) PURE; - - /*** IDirectInput2A methods ***/ - STDMETHOD(CreateDevice)(THIS_ REFGUID,LPDIRECTINPUTDEVICEA *,LPUNKNOWN) PURE; - STDMETHOD(EnumDevices)(THIS_ DWORD,LPDIENUMDEVICESCALLBACKA,LPVOID,DWORD) PURE; - STDMETHOD(GetDeviceStatus)(THIS_ REFGUID) PURE; - STDMETHOD(RunControlPanel)(THIS_ HWND,DWORD) PURE; - STDMETHOD(Initialize)(THIS_ HINSTANCE,DWORD) PURE; - STDMETHOD(FindDevice)(THIS_ REFGUID,LPCSTR,LPGUID) PURE; - - /*** IDirectInput7A methods ***/ - STDMETHOD(CreateDeviceEx)(THIS_ REFGUID,REFIID,LPVOID *,LPUNKNOWN) PURE; -}; - -typedef struct IDirectInput7A *LPDIRECTINPUT7A; - -#ifdef UNICODE -#define IID_IDirectInput7 IID_IDirectInput7W -#define IDirectInput7 IDirectInput7W -#define IDirectInput7Vtbl IDirectInput7WVtbl -#else -#define IID_IDirectInput7 IID_IDirectInput7A -#define IDirectInput7 IDirectInput7A -#define IDirectInput7Vtbl IDirectInput7AVtbl -#endif -typedef struct IDirectInput7 *LPDIRECTINPUT7; - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectInput7_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) -#define IDirectInput7_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirectInput7_Release(p) (p)->lpVtbl->Release(p) -#define IDirectInput7_CreateDevice(p,a,b,c) (p)->lpVtbl->CreateDevice(p,a,b,c) -#define IDirectInput7_EnumDevices(p,a,b,c,d) (p)->lpVtbl->EnumDevices(p,a,b,c,d) -#define IDirectInput7_GetDeviceStatus(p,a) (p)->lpVtbl->GetDeviceStatus(p,a) -#define IDirectInput7_RunControlPanel(p,a,b) (p)->lpVtbl->RunControlPanel(p,a,b) -#define IDirectInput7_Initialize(p,a,b) (p)->lpVtbl->Initialize(p,a,b) -#define IDirectInput7_FindDevice(p,a,b,c) (p)->lpVtbl->FindDevice(p,a,b,c) -#define IDirectInput7_CreateDeviceEx(p,a,b,c,d) (p)->lpVtbl->CreateDeviceEx(p,a,b,c,d) -#else -#define IDirectInput7_QueryInterface(p,a,b) (p)->QueryInterface(a,b) -#define IDirectInput7_AddRef(p) (p)->AddRef() -#define IDirectInput7_Release(p) (p)->Release() -#define IDirectInput7_CreateDevice(p,a,b,c) (p)->CreateDevice(a,b,c) -#define IDirectInput7_EnumDevices(p,a,b,c,d) (p)->EnumDevices(a,b,c,d) -#define IDirectInput7_GetDeviceStatus(p,a) (p)->GetDeviceStatus(a) -#define IDirectInput7_RunControlPanel(p,a,b) (p)->RunControlPanel(a,b) -#define IDirectInput7_Initialize(p,a,b) (p)->Initialize(a,b) -#define IDirectInput7_FindDevice(p,a,b,c) (p)->FindDevice(a,b,c) -#define IDirectInput7_CreateDeviceEx(p,a,b,c,d) (p)->CreateDeviceEx(a,b,c,d) -#endif - -#if(DIRECTINPUT_VERSION >= 0x0800) -#undef INTERFACE -#define INTERFACE IDirectInput8W - -DECLARE_INTERFACE_(IDirectInput8W, IUnknown) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID * ppvObj) PURE; - STDMETHOD_(ULONG,AddRef)(THIS) PURE; - STDMETHOD_(ULONG,Release)(THIS) PURE; - - /*** IDirectInput8W methods ***/ - STDMETHOD(CreateDevice)(THIS_ REFGUID,LPDIRECTINPUTDEVICE8W *,LPUNKNOWN) PURE; - STDMETHOD(EnumDevices)(THIS_ DWORD,LPDIENUMDEVICESCALLBACKW,LPVOID,DWORD) PURE; - STDMETHOD(GetDeviceStatus)(THIS_ REFGUID) PURE; - STDMETHOD(RunControlPanel)(THIS_ HWND,DWORD) PURE; - STDMETHOD(Initialize)(THIS_ HINSTANCE,DWORD) PURE; - STDMETHOD(FindDevice)(THIS_ REFGUID,LPCWSTR,LPGUID) PURE; - STDMETHOD(EnumDevicesBySemantics)(THIS_ LPCWSTR,LPDIACTIONFORMATW,LPDIENUMDEVICESBYSEMANTICSCBW,LPVOID,DWORD) PURE; - STDMETHOD(ConfigureDevices)(THIS_ LPDICONFIGUREDEVICESCALLBACK,LPDICONFIGUREDEVICESPARAMSW,DWORD,LPVOID) PURE; -}; - -typedef struct IDirectInput8W *LPDIRECTINPUT8W; - -#undef INTERFACE -#define INTERFACE IDirectInput8A - -DECLARE_INTERFACE_(IDirectInput8A, IUnknown) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID * ppvObj) PURE; - STDMETHOD_(ULONG,AddRef)(THIS) PURE; - STDMETHOD_(ULONG,Release)(THIS) PURE; - - /*** IDirectInput8A methods ***/ - STDMETHOD(CreateDevice)(THIS_ REFGUID,LPDIRECTINPUTDEVICE8A *,LPUNKNOWN) PURE; - STDMETHOD(EnumDevices)(THIS_ DWORD,LPDIENUMDEVICESCALLBACKA,LPVOID,DWORD) PURE; - STDMETHOD(GetDeviceStatus)(THIS_ REFGUID) PURE; - STDMETHOD(RunControlPanel)(THIS_ HWND,DWORD) PURE; - STDMETHOD(Initialize)(THIS_ HINSTANCE,DWORD) PURE; - STDMETHOD(FindDevice)(THIS_ REFGUID,LPCSTR,LPGUID) PURE; - STDMETHOD(EnumDevicesBySemantics)(THIS_ LPCSTR,LPDIACTIONFORMATA,LPDIENUMDEVICESBYSEMANTICSCBA,LPVOID,DWORD) PURE; - STDMETHOD(ConfigureDevices)(THIS_ LPDICONFIGUREDEVICESCALLBACK,LPDICONFIGUREDEVICESPARAMSA,DWORD,LPVOID) PURE; -}; - -typedef struct IDirectInput8A *LPDIRECTINPUT8A; - -#ifdef UNICODE -#define IID_IDirectInput8 IID_IDirectInput8W -#define IDirectInput8 IDirectInput8W -#define IDirectInput8Vtbl IDirectInput8WVtbl -#else -#define IID_IDirectInput8 IID_IDirectInput8A -#define IDirectInput8 IDirectInput8A -#define IDirectInput8Vtbl IDirectInput8AVtbl -#endif -typedef struct IDirectInput8 *LPDIRECTINPUT8; - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectInput8_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) -#define IDirectInput8_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirectInput8_Release(p) (p)->lpVtbl->Release(p) -#define IDirectInput8_CreateDevice(p,a,b,c) (p)->lpVtbl->CreateDevice(p,a,b,c) -#define IDirectInput8_EnumDevices(p,a,b,c,d) (p)->lpVtbl->EnumDevices(p,a,b,c,d) -#define IDirectInput8_GetDeviceStatus(p,a) (p)->lpVtbl->GetDeviceStatus(p,a) -#define IDirectInput8_RunControlPanel(p,a,b) (p)->lpVtbl->RunControlPanel(p,a,b) -#define IDirectInput8_Initialize(p,a,b) (p)->lpVtbl->Initialize(p,a,b) -#define IDirectInput8_FindDevice(p,a,b,c) (p)->lpVtbl->FindDevice(p,a,b,c) -#define IDirectInput8_EnumDevicesBySemantics(p,a,b,c,d,e) (p)->lpVtbl->EnumDevicesBySemantics(p,a,b,c,d,e) -#define IDirectInput8_ConfigureDevices(p,a,b,c,d) (p)->lpVtbl->ConfigureDevices(p,a,b,c,d) -#else -#define IDirectInput8_QueryInterface(p,a,b) (p)->QueryInterface(a,b) -#define IDirectInput8_AddRef(p) (p)->AddRef() -#define IDirectInput8_Release(p) (p)->Release() -#define IDirectInput8_CreateDevice(p,a,b,c) (p)->CreateDevice(a,b,c) -#define IDirectInput8_EnumDevices(p,a,b,c,d) (p)->EnumDevices(a,b,c,d) -#define IDirectInput8_GetDeviceStatus(p,a) (p)->GetDeviceStatus(a) -#define IDirectInput8_RunControlPanel(p,a,b) (p)->RunControlPanel(a,b) -#define IDirectInput8_Initialize(p,a,b) (p)->Initialize(a,b) -#define IDirectInput8_FindDevice(p,a,b,c) (p)->FindDevice(a,b,c) -#define IDirectInput8_EnumDevicesBySemantics(p,a,b,c,d,e) (p)->EnumDevicesBySemantics(a,b,c,d,e) -#define IDirectInput8_ConfigureDevices(p,a,b,c,d) (p)->ConfigureDevices(a,b,c,d) -#endif -#endif /* DIRECTINPUT_VERSION >= 0x0800 */ - -#if DIRECTINPUT_VERSION > 0x0700 - -extern HRESULT WINAPI DirectInput8Create(HINSTANCE hinst, DWORD dwVersion, REFIID riidltf, LPVOID *ppvOut, LPUNKNOWN punkOuter); - -#else -extern HRESULT WINAPI DirectInputCreateA(HINSTANCE hinst, DWORD dwVersion, LPDIRECTINPUTA *ppDI, LPUNKNOWN punkOuter); -extern HRESULT WINAPI DirectInputCreateW(HINSTANCE hinst, DWORD dwVersion, LPDIRECTINPUTW *ppDI, LPUNKNOWN punkOuter); -#ifdef UNICODE -#define DirectInputCreate DirectInputCreateW -#else -#define DirectInputCreate DirectInputCreateA -#endif // !UNICODE - -extern HRESULT WINAPI DirectInputCreateEx(HINSTANCE hinst, DWORD dwVersion, REFIID riidltf, LPVOID *ppvOut, LPUNKNOWN punkOuter); - -#endif /* DIRECTINPUT_VERSION > 0x700 */ - -#endif /* DIJ_RINGZERO */ - - -/**************************************************************************** - * - * Return Codes - * - ****************************************************************************/ - -/* - * The operation completed successfully. - */ -#define DI_OK S_OK - -/* - * The device exists but is not currently attached. - */ -#define DI_NOTATTACHED S_FALSE - -/* - * The device buffer overflowed. Some input was lost. - */ -#define DI_BUFFEROVERFLOW S_FALSE - -/* - * The change in device properties had no effect. - */ -#define DI_PROPNOEFFECT S_FALSE - -/* - * The operation had no effect. - */ -#define DI_NOEFFECT S_FALSE - -/* - * The device is a polled device. As a result, device buffering - * will not collect any data and event notifications will not be - * signalled until GetDeviceState is called. - */ -#define DI_POLLEDDEVICE ((HRESULT)0x00000002L) - -/* - * The parameters of the effect were successfully updated by - * IDirectInputEffect::SetParameters, but the effect was not - * downloaded because the device is not exclusively acquired - * or because the DIEP_NODOWNLOAD flag was passed. - */ -#define DI_DOWNLOADSKIPPED ((HRESULT)0x00000003L) - -/* - * The parameters of the effect were successfully updated by - * IDirectInputEffect::SetParameters, but in order to change - * the parameters, the effect needed to be restarted. - */ -#define DI_EFFECTRESTARTED ((HRESULT)0x00000004L) - -/* - * The parameters of the effect were successfully updated by - * IDirectInputEffect::SetParameters, but some of them were - * beyond the capabilities of the device and were truncated. - */ -#define DI_TRUNCATED ((HRESULT)0x00000008L) - -/* - * The settings have been successfully applied but could not be - * persisted. - */ -#define DI_SETTINGSNOTSAVED ((HRESULT)0x0000000BL) - -/* - * Equal to DI_EFFECTRESTARTED | DI_TRUNCATED. - */ -#define DI_TRUNCATEDANDRESTARTED ((HRESULT)0x0000000CL) - -/* - * A SUCCESS code indicating that settings cannot be modified. - */ -#define DI_WRITEPROTECT ((HRESULT)0x00000013L) - -/* - * The application requires a newer version of DirectInput. - */ -#define DIERR_OLDDIRECTINPUTVERSION \ - MAKE_HRESULT(SEVERITY_ERROR, FACILITY_WIN32, ERROR_OLD_WIN_VERSION) - -/* - * The application was written for an unsupported prerelease version - * of DirectInput. - */ -#define DIERR_BETADIRECTINPUTVERSION \ - MAKE_HRESULT(SEVERITY_ERROR, FACILITY_WIN32, ERROR_RMODE_APP) - -/* - * The object could not be created due to an incompatible driver version - * or mismatched or incomplete driver components. - */ -#define DIERR_BADDRIVERVER \ - MAKE_HRESULT(SEVERITY_ERROR, FACILITY_WIN32, ERROR_BAD_DRIVER_LEVEL) - -/* - * The device or device instance or effect is not registered with DirectInput. - */ -#define DIERR_DEVICENOTREG REGDB_E_CLASSNOTREG - -/* - * The requested object does not exist. - */ -#define DIERR_NOTFOUND \ - MAKE_HRESULT(SEVERITY_ERROR, FACILITY_WIN32, ERROR_FILE_NOT_FOUND) - -/* - * The requested object does not exist. - */ -#define DIERR_OBJECTNOTFOUND \ - MAKE_HRESULT(SEVERITY_ERROR, FACILITY_WIN32, ERROR_FILE_NOT_FOUND) - -/* - * An invalid parameter was passed to the returning function, - * or the object was not in a state that admitted the function - * to be called. - */ -#define DIERR_INVALIDPARAM E_INVALIDARG - -/* - * The specified interface is not supported by the object - */ -#define DIERR_NOINTERFACE E_NOINTERFACE - -/* - * An undetermined error occured inside the DInput subsystem - */ -#define DIERR_GENERIC E_FAIL - -/* - * The DInput subsystem couldn't allocate sufficient memory to complete the - * caller's request. - */ -#define DIERR_OUTOFMEMORY E_OUTOFMEMORY - -/* - * The function called is not supported at this time - */ -#define DIERR_UNSUPPORTED E_NOTIMPL - -/* - * This object has not been initialized - */ -#define DIERR_NOTINITIALIZED \ - MAKE_HRESULT(SEVERITY_ERROR, FACILITY_WIN32, ERROR_NOT_READY) - -/* - * This object is already initialized - */ -#define DIERR_ALREADYINITIALIZED \ - MAKE_HRESULT(SEVERITY_ERROR, FACILITY_WIN32, ERROR_ALREADY_INITIALIZED) - -/* - * This object does not support aggregation - */ -#define DIERR_NOAGGREGATION CLASS_E_NOAGGREGATION - -/* - * Another app has a higher priority level, preventing this call from - * succeeding. - */ -#define DIERR_OTHERAPPHASPRIO E_ACCESSDENIED - -/* - * Access to the device has been lost. It must be re-acquired. - */ -#define DIERR_INPUTLOST \ - MAKE_HRESULT(SEVERITY_ERROR, FACILITY_WIN32, ERROR_READ_FAULT) - -/* - * The operation cannot be performed while the device is acquired. - */ -#define DIERR_ACQUIRED \ - MAKE_HRESULT(SEVERITY_ERROR, FACILITY_WIN32, ERROR_BUSY) - -/* - * The operation cannot be performed unless the device is acquired. - */ -#define DIERR_NOTACQUIRED \ - MAKE_HRESULT(SEVERITY_ERROR, FACILITY_WIN32, ERROR_INVALID_ACCESS) - -/* - * The specified property cannot be changed. - */ -#define DIERR_READONLY E_ACCESSDENIED - -/* - * The device already has an event notification associated with it. - */ -#define DIERR_HANDLEEXISTS E_ACCESSDENIED - -/* - * Data is not yet available. - */ -#ifndef E_PENDING -#define E_PENDING 0x8000000AL -#endif - -/* - * Unable to IDirectInputJoyConfig_Acquire because the user - * does not have sufficient privileges to change the joystick - * configuration. - */ -#define DIERR_INSUFFICIENTPRIVS 0x80040200L - -/* - * The device is full. - */ -#define DIERR_DEVICEFULL 0x80040201L - -/* - * Not all the requested information fit into the buffer. - */ -#define DIERR_MOREDATA 0x80040202L - -/* - * The effect is not downloaded. - */ -#define DIERR_NOTDOWNLOADED 0x80040203L - -/* - * The device cannot be reinitialized because there are still effects - * attached to it. - */ -#define DIERR_HASEFFECTS 0x80040204L - -/* - * The operation cannot be performed unless the device is acquired - * in DISCL_EXCLUSIVE mode. - */ -#define DIERR_NOTEXCLUSIVEACQUIRED 0x80040205L - -/* - * The effect could not be downloaded because essential information - * is missing. For example, no axes have been associated with the - * effect, or no type-specific information has been created. - */ -#define DIERR_INCOMPLETEEFFECT 0x80040206L - -/* - * Attempted to read buffered device data from a device that is - * not buffered. - */ -#define DIERR_NOTBUFFERED 0x80040207L - -/* - * An attempt was made to modify parameters of an effect while it is - * playing. Not all hardware devices support altering the parameters - * of an effect while it is playing. - */ -#define DIERR_EFFECTPLAYING 0x80040208L - -/* - * The operation could not be completed because the device is not - * plugged in. - */ -#define DIERR_UNPLUGGED 0x80040209L - -/* - * SendDeviceData failed because more information was requested - * to be sent than can be sent to the device. Some devices have - * restrictions on how much data can be sent to them. (For example, - * there might be a limit on the number of buttons that can be - * pressed at once.) - */ -#define DIERR_REPORTFULL 0x8004020AL - - -/* - * A mapper file function failed because reading or writing the user or IHV - * settings file failed. - */ -#define DIERR_MAPFILEFAIL 0x8004020BL - - -/*--- DINPUT Mapper Definitions: New for Dx8 ---*/ - - -/*--- Keyboard - Physical Keyboard Device ---*/ - -#define DIKEYBOARD_ESCAPE 0x81000401 -#define DIKEYBOARD_1 0x81000402 -#define DIKEYBOARD_2 0x81000403 -#define DIKEYBOARD_3 0x81000404 -#define DIKEYBOARD_4 0x81000405 -#define DIKEYBOARD_5 0x81000406 -#define DIKEYBOARD_6 0x81000407 -#define DIKEYBOARD_7 0x81000408 -#define DIKEYBOARD_8 0x81000409 -#define DIKEYBOARD_9 0x8100040A -#define DIKEYBOARD_0 0x8100040B -#define DIKEYBOARD_MINUS 0x8100040C /* - on main keyboard */ -#define DIKEYBOARD_EQUALS 0x8100040D -#define DIKEYBOARD_BACK 0x8100040E /* backspace */ -#define DIKEYBOARD_TAB 0x8100040F -#define DIKEYBOARD_Q 0x81000410 -#define DIKEYBOARD_W 0x81000411 -#define DIKEYBOARD_E 0x81000412 -#define DIKEYBOARD_R 0x81000413 -#define DIKEYBOARD_T 0x81000414 -#define DIKEYBOARD_Y 0x81000415 -#define DIKEYBOARD_U 0x81000416 -#define DIKEYBOARD_I 0x81000417 -#define DIKEYBOARD_O 0x81000418 -#define DIKEYBOARD_P 0x81000419 -#define DIKEYBOARD_LBRACKET 0x8100041A -#define DIKEYBOARD_RBRACKET 0x8100041B -#define DIKEYBOARD_RETURN 0x8100041C /* Enter on main keyboard */ -#define DIKEYBOARD_LCONTROL 0x8100041D -#define DIKEYBOARD_A 0x8100041E -#define DIKEYBOARD_S 0x8100041F -#define DIKEYBOARD_D 0x81000420 -#define DIKEYBOARD_F 0x81000421 -#define DIKEYBOARD_G 0x81000422 -#define DIKEYBOARD_H 0x81000423 -#define DIKEYBOARD_J 0x81000424 -#define DIKEYBOARD_K 0x81000425 -#define DIKEYBOARD_L 0x81000426 -#define DIKEYBOARD_SEMICOLON 0x81000427 -#define DIKEYBOARD_APOSTROPHE 0x81000428 -#define DIKEYBOARD_GRAVE 0x81000429 /* accent grave */ -#define DIKEYBOARD_LSHIFT 0x8100042A -#define DIKEYBOARD_BACKSLASH 0x8100042B -#define DIKEYBOARD_Z 0x8100042C -#define DIKEYBOARD_X 0x8100042D -#define DIKEYBOARD_C 0x8100042E -#define DIKEYBOARD_V 0x8100042F -#define DIKEYBOARD_B 0x81000430 -#define DIKEYBOARD_N 0x81000431 -#define DIKEYBOARD_M 0x81000432 -#define DIKEYBOARD_COMMA 0x81000433 -#define DIKEYBOARD_PERIOD 0x81000434 /* . on main keyboard */ -#define DIKEYBOARD_SLASH 0x81000435 /* / on main keyboard */ -#define DIKEYBOARD_RSHIFT 0x81000436 -#define DIKEYBOARD_MULTIPLY 0x81000437 /* * on numeric keypad */ -#define DIKEYBOARD_LMENU 0x81000438 /* left Alt */ -#define DIKEYBOARD_SPACE 0x81000439 -#define DIKEYBOARD_CAPITAL 0x8100043A -#define DIKEYBOARD_F1 0x8100043B -#define DIKEYBOARD_F2 0x8100043C -#define DIKEYBOARD_F3 0x8100043D -#define DIKEYBOARD_F4 0x8100043E -#define DIKEYBOARD_F5 0x8100043F -#define DIKEYBOARD_F6 0x81000440 -#define DIKEYBOARD_F7 0x81000441 -#define DIKEYBOARD_F8 0x81000442 -#define DIKEYBOARD_F9 0x81000443 -#define DIKEYBOARD_F10 0x81000444 -#define DIKEYBOARD_NUMLOCK 0x81000445 -#define DIKEYBOARD_SCROLL 0x81000446 /* Scroll Lock */ -#define DIKEYBOARD_NUMPAD7 0x81000447 -#define DIKEYBOARD_NUMPAD8 0x81000448 -#define DIKEYBOARD_NUMPAD9 0x81000449 -#define DIKEYBOARD_SUBTRACT 0x8100044A /* - on numeric keypad */ -#define DIKEYBOARD_NUMPAD4 0x8100044B -#define DIKEYBOARD_NUMPAD5 0x8100044C -#define DIKEYBOARD_NUMPAD6 0x8100044D -#define DIKEYBOARD_ADD 0x8100044E /* + on numeric keypad */ -#define DIKEYBOARD_NUMPAD1 0x8100044F -#define DIKEYBOARD_NUMPAD2 0x81000450 -#define DIKEYBOARD_NUMPAD3 0x81000451 -#define DIKEYBOARD_NUMPAD0 0x81000452 -#define DIKEYBOARD_DECIMAL 0x81000453 /* . on numeric keypad */ -#define DIKEYBOARD_OEM_102 0x81000456 /* <> or \| on RT 102-key keyboard (Non-U.S.) */ -#define DIKEYBOARD_F11 0x81000457 -#define DIKEYBOARD_F12 0x81000458 -#define DIKEYBOARD_F13 0x81000464 /* (NEC PC98) */ -#define DIKEYBOARD_F14 0x81000465 /* (NEC PC98) */ -#define DIKEYBOARD_F15 0x81000466 /* (NEC PC98) */ -#define DIKEYBOARD_KANA 0x81000470 /* (Japanese keyboard) */ -#define DIKEYBOARD_ABNT_C1 0x81000473 /* /? on Brazilian keyboard */ -#define DIKEYBOARD_CONVERT 0x81000479 /* (Japanese keyboard) */ -#define DIKEYBOARD_NOCONVERT 0x8100047B /* (Japanese keyboard) */ -#define DIKEYBOARD_YEN 0x8100047D /* (Japanese keyboard) */ -#define DIKEYBOARD_ABNT_C2 0x8100047E /* Numpad . on Brazilian keyboard */ -#define DIKEYBOARD_NUMPADEQUALS 0x8100048D /* = on numeric keypad (NEC PC98) */ -#define DIKEYBOARD_PREVTRACK 0x81000490 /* Previous Track (DIK_CIRCUMFLEX on Japanese keyboard) */ -#define DIKEYBOARD_AT 0x81000491 /* (NEC PC98) */ -#define DIKEYBOARD_COLON 0x81000492 /* (NEC PC98) */ -#define DIKEYBOARD_UNDERLINE 0x81000493 /* (NEC PC98) */ -#define DIKEYBOARD_KANJI 0x81000494 /* (Japanese keyboard) */ -#define DIKEYBOARD_STOP 0x81000495 /* (NEC PC98) */ -#define DIKEYBOARD_AX 0x81000496 /* (Japan AX) */ -#define DIKEYBOARD_UNLABELED 0x81000497 /* (J3100) */ -#define DIKEYBOARD_NEXTTRACK 0x81000499 /* Next Track */ -#define DIKEYBOARD_NUMPADENTER 0x8100049C /* Enter on numeric keypad */ -#define DIKEYBOARD_RCONTROL 0x8100049D -#define DIKEYBOARD_MUTE 0x810004A0 /* Mute */ -#define DIKEYBOARD_CALCULATOR 0x810004A1 /* Calculator */ -#define DIKEYBOARD_PLAYPAUSE 0x810004A2 /* Play / Pause */ -#define DIKEYBOARD_MEDIASTOP 0x810004A4 /* Media Stop */ -#define DIKEYBOARD_VOLUMEDOWN 0x810004AE /* Volume - */ -#define DIKEYBOARD_VOLUMEUP 0x810004B0 /* Volume + */ -#define DIKEYBOARD_WEBHOME 0x810004B2 /* Web home */ -#define DIKEYBOARD_NUMPADCOMMA 0x810004B3 /* , on numeric keypad (NEC PC98) */ -#define DIKEYBOARD_DIVIDE 0x810004B5 /* / on numeric keypad */ -#define DIKEYBOARD_SYSRQ 0x810004B7 -#define DIKEYBOARD_RMENU 0x810004B8 /* right Alt */ -#define DIKEYBOARD_PAUSE 0x810004C5 /* Pause */ -#define DIKEYBOARD_HOME 0x810004C7 /* Home on arrow keypad */ -#define DIKEYBOARD_UP 0x810004C8 /* UpArrow on arrow keypad */ -#define DIKEYBOARD_PRIOR 0x810004C9 /* PgUp on arrow keypad */ -#define DIKEYBOARD_LEFT 0x810004CB /* LeftArrow on arrow keypad */ -#define DIKEYBOARD_RIGHT 0x810004CD /* RightArrow on arrow keypad */ -#define DIKEYBOARD_END 0x810004CF /* End on arrow keypad */ -#define DIKEYBOARD_DOWN 0x810004D0 /* DownArrow on arrow keypad */ -#define DIKEYBOARD_NEXT 0x810004D1 /* PgDn on arrow keypad */ -#define DIKEYBOARD_INSERT 0x810004D2 /* Insert on arrow keypad */ -#define DIKEYBOARD_DELETE 0x810004D3 /* Delete on arrow keypad */ -#define DIKEYBOARD_LWIN 0x810004DB /* Left Windows key */ -#define DIKEYBOARD_RWIN 0x810004DC /* Right Windows key */ -#define DIKEYBOARD_APPS 0x810004DD /* AppMenu key */ -#define DIKEYBOARD_POWER 0x810004DE /* System Power */ -#define DIKEYBOARD_SLEEP 0x810004DF /* System Sleep */ -#define DIKEYBOARD_WAKE 0x810004E3 /* System Wake */ -#define DIKEYBOARD_WEBSEARCH 0x810004E5 /* Web Search */ -#define DIKEYBOARD_WEBFAVORITES 0x810004E6 /* Web Favorites */ -#define DIKEYBOARD_WEBREFRESH 0x810004E7 /* Web Refresh */ -#define DIKEYBOARD_WEBSTOP 0x810004E8 /* Web Stop */ -#define DIKEYBOARD_WEBFORWARD 0x810004E9 /* Web Forward */ -#define DIKEYBOARD_WEBBACK 0x810004EA /* Web Back */ -#define DIKEYBOARD_MYCOMPUTER 0x810004EB /* My Computer */ -#define DIKEYBOARD_MAIL 0x810004EC /* Mail */ -#define DIKEYBOARD_MEDIASELECT 0x810004ED /* Media Select */ - - -/*--- MOUSE - Physical Mouse Device ---*/ - -#define DIMOUSE_XAXISAB (0x82000200 |DIMOFS_X ) /* X Axis-absolute: Some mice natively report absolute coordinates */ -#define DIMOUSE_YAXISAB (0x82000200 |DIMOFS_Y ) /* Y Axis-absolute: Some mice natively report absolute coordinates */ -#define DIMOUSE_XAXIS (0x82000300 |DIMOFS_X ) /* X Axis */ -#define DIMOUSE_YAXIS (0x82000300 |DIMOFS_Y ) /* Y Axis */ -#define DIMOUSE_WHEEL (0x82000300 |DIMOFS_Z ) /* Z Axis */ -#define DIMOUSE_BUTTON0 (0x82000400 |DIMOFS_BUTTON0) /* Button 0 */ -#define DIMOUSE_BUTTON1 (0x82000400 |DIMOFS_BUTTON1) /* Button 1 */ -#define DIMOUSE_BUTTON2 (0x82000400 |DIMOFS_BUTTON2) /* Button 2 */ -#define DIMOUSE_BUTTON3 (0x82000400 |DIMOFS_BUTTON3) /* Button 3 */ -#define DIMOUSE_BUTTON4 (0x82000400 |DIMOFS_BUTTON4) /* Button 4 */ -#define DIMOUSE_BUTTON5 (0x82000400 |DIMOFS_BUTTON5) /* Button 5 */ -#define DIMOUSE_BUTTON6 (0x82000400 |DIMOFS_BUTTON6) /* Button 6 */ -#define DIMOUSE_BUTTON7 (0x82000400 |DIMOFS_BUTTON7) /* Button 7 */ - - -/*--- VOICE - Physical Dplay Voice Device ---*/ - -#define DIVOICE_CHANNEL1 0x83000401 -#define DIVOICE_CHANNEL2 0x83000402 -#define DIVOICE_CHANNEL3 0x83000403 -#define DIVOICE_CHANNEL4 0x83000404 -#define DIVOICE_CHANNEL5 0x83000405 -#define DIVOICE_CHANNEL6 0x83000406 -#define DIVOICE_CHANNEL7 0x83000407 -#define DIVOICE_CHANNEL8 0x83000408 -#define DIVOICE_TEAM 0x83000409 -#define DIVOICE_ALL 0x8300040A -#define DIVOICE_RECORDMUTE 0x8300040B -#define DIVOICE_PLAYBACKMUTE 0x8300040C -#define DIVOICE_TRANSMIT 0x8300040D - -#define DIVOICE_VOICECOMMAND 0x83000410 - - -/*--- Driving Simulator - Racing - Vehicle control is primary objective ---*/ -#define DIVIRTUAL_DRIVING_RACE 0x01000000 -#define DIAXIS_DRIVINGR_STEER 0x01008A01 /* Steering */ -#define DIAXIS_DRIVINGR_ACCELERATE 0x01039202 /* Accelerate */ -#define DIAXIS_DRIVINGR_BRAKE 0x01041203 /* Brake-Axis */ -#define DIBUTTON_DRIVINGR_SHIFTUP 0x01000C01 /* Shift to next higher gear */ -#define DIBUTTON_DRIVINGR_SHIFTDOWN 0x01000C02 /* Shift to next lower gear */ -#define DIBUTTON_DRIVINGR_VIEW 0x01001C03 /* Cycle through view options */ -#define DIBUTTON_DRIVINGR_MENU 0x010004FD /* Show menu options */ -/*--- Priority 2 controls ---*/ - -#define DIAXIS_DRIVINGR_ACCEL_AND_BRAKE 0x01014A04 /* Some devices combine accelerate and brake in a single axis */ -#define DIHATSWITCH_DRIVINGR_GLANCE 0x01004601 /* Look around */ -#define DIBUTTON_DRIVINGR_BRAKE 0x01004C04 /* Brake-button */ -#define DIBUTTON_DRIVINGR_DASHBOARD 0x01004405 /* Select next dashboard option */ -#define DIBUTTON_DRIVINGR_AIDS 0x01004406 /* Driver correction aids */ -#define DIBUTTON_DRIVINGR_MAP 0x01004407 /* Display Driving Map */ -#define DIBUTTON_DRIVINGR_BOOST 0x01004408 /* Turbo Boost */ -#define DIBUTTON_DRIVINGR_PIT 0x01004409 /* Pit stop notification */ -#define DIBUTTON_DRIVINGR_ACCELERATE_LINK 0x0103D4E0 /* Fallback Accelerate button */ -#define DIBUTTON_DRIVINGR_STEER_LEFT_LINK 0x0100CCE4 /* Fallback Steer Left button */ -#define DIBUTTON_DRIVINGR_STEER_RIGHT_LINK 0x0100CCEC /* Fallback Steer Right button */ -#define DIBUTTON_DRIVINGR_GLANCE_LEFT_LINK 0x0107C4E4 /* Fallback Glance Left button */ -#define DIBUTTON_DRIVINGR_GLANCE_RIGHT_LINK 0x0107C4EC /* Fallback Glance Right button */ -#define DIBUTTON_DRIVINGR_DEVICE 0x010044FE /* Show input device and controls */ -#define DIBUTTON_DRIVINGR_PAUSE 0x010044FC /* Start / Pause / Restart game */ - -/*--- Driving Simulator - Combat - Combat from within a vehicle is primary objective ---*/ -#define DIVIRTUAL_DRIVING_COMBAT 0x02000000 -#define DIAXIS_DRIVINGC_STEER 0x02008A01 /* Steering */ -#define DIAXIS_DRIVINGC_ACCELERATE 0x02039202 /* Accelerate */ -#define DIAXIS_DRIVINGC_BRAKE 0x02041203 /* Brake-axis */ -#define DIBUTTON_DRIVINGC_FIRE 0x02000C01 /* Fire */ -#define DIBUTTON_DRIVINGC_WEAPONS 0x02000C02 /* Select next weapon */ -#define DIBUTTON_DRIVINGC_TARGET 0x02000C03 /* Select next available target */ -#define DIBUTTON_DRIVINGC_MENU 0x020004FD /* Show menu options */ -/*--- Priority 2 controls ---*/ - -#define DIAXIS_DRIVINGC_ACCEL_AND_BRAKE 0x02014A04 /* Some devices combine accelerate and brake in a single axis */ -#define DIHATSWITCH_DRIVINGC_GLANCE 0x02004601 /* Look around */ -#define DIBUTTON_DRIVINGC_SHIFTUP 0x02004C04 /* Shift to next higher gear */ -#define DIBUTTON_DRIVINGC_SHIFTDOWN 0x02004C05 /* Shift to next lower gear */ -#define DIBUTTON_DRIVINGC_DASHBOARD 0x02004406 /* Select next dashboard option */ -#define DIBUTTON_DRIVINGC_AIDS 0x02004407 /* Driver correction aids */ -#define DIBUTTON_DRIVINGC_BRAKE 0x02004C08 /* Brake-button */ -#define DIBUTTON_DRIVINGC_FIRESECONDARY 0x02004C09 /* Alternative fire button */ -#define DIBUTTON_DRIVINGC_ACCELERATE_LINK 0x0203D4E0 /* Fallback Accelerate button */ -#define DIBUTTON_DRIVINGC_STEER_LEFT_LINK 0x0200CCE4 /* Fallback Steer Left button */ -#define DIBUTTON_DRIVINGC_STEER_RIGHT_LINK 0x0200CCEC /* Fallback Steer Right button */ -#define DIBUTTON_DRIVINGC_GLANCE_LEFT_LINK 0x0207C4E4 /* Fallback Glance Left button */ -#define DIBUTTON_DRIVINGC_GLANCE_RIGHT_LINK 0x0207C4EC /* Fallback Glance Right button */ -#define DIBUTTON_DRIVINGC_DEVICE 0x020044FE /* Show input device and controls */ -#define DIBUTTON_DRIVINGC_PAUSE 0x020044FC /* Start / Pause / Restart game */ - -/*--- Driving Simulator - Tank - Combat from withing a tank is primary objective ---*/ -#define DIVIRTUAL_DRIVING_TANK 0x03000000 -#define DIAXIS_DRIVINGT_STEER 0x03008A01 /* Turn tank left / right */ -#define DIAXIS_DRIVINGT_BARREL 0x03010202 /* Raise / lower barrel */ -#define DIAXIS_DRIVINGT_ACCELERATE 0x03039203 /* Accelerate */ -#define DIAXIS_DRIVINGT_ROTATE 0x03020204 /* Turn barrel left / right */ -#define DIBUTTON_DRIVINGT_FIRE 0x03000C01 /* Fire */ -#define DIBUTTON_DRIVINGT_WEAPONS 0x03000C02 /* Select next weapon */ -#define DIBUTTON_DRIVINGT_TARGET 0x03000C03 /* Selects next available target */ -#define DIBUTTON_DRIVINGT_MENU 0x030004FD /* Show menu options */ -/*--- Priority 2 controls ---*/ - -#define DIHATSWITCH_DRIVINGT_GLANCE 0x03004601 /* Look around */ -#define DIAXIS_DRIVINGT_BRAKE 0x03045205 /* Brake-axis */ -#define DIAXIS_DRIVINGT_ACCEL_AND_BRAKE 0x03014A06 /* Some devices combine accelerate and brake in a single axis */ -#define DIBUTTON_DRIVINGT_VIEW 0x03005C04 /* Cycle through view options */ -#define DIBUTTON_DRIVINGT_DASHBOARD 0x03005C05 /* Select next dashboard option */ -#define DIBUTTON_DRIVINGT_BRAKE 0x03004C06 /* Brake-button */ -#define DIBUTTON_DRIVINGT_FIRESECONDARY 0x03004C07 /* Alternative fire button */ -#define DIBUTTON_DRIVINGT_ACCELERATE_LINK 0x0303D4E0 /* Fallback Accelerate button */ -#define DIBUTTON_DRIVINGT_STEER_LEFT_LINK 0x0300CCE4 /* Fallback Steer Left button */ -#define DIBUTTON_DRIVINGT_STEER_RIGHT_LINK 0x0300CCEC /* Fallback Steer Right button */ -#define DIBUTTON_DRIVINGT_BARREL_UP_LINK 0x030144E0 /* Fallback Barrel up button */ -#define DIBUTTON_DRIVINGT_BARREL_DOWN_LINK 0x030144E8 /* Fallback Barrel down button */ -#define DIBUTTON_DRIVINGT_ROTATE_LEFT_LINK 0x030244E4 /* Fallback Rotate left button */ -#define DIBUTTON_DRIVINGT_ROTATE_RIGHT_LINK 0x030244EC /* Fallback Rotate right button */ -#define DIBUTTON_DRIVINGT_GLANCE_LEFT_LINK 0x0307C4E4 /* Fallback Glance Left button */ -#define DIBUTTON_DRIVINGT_GLANCE_RIGHT_LINK 0x0307C4EC /* Fallback Glance Right button */ -#define DIBUTTON_DRIVINGT_DEVICE 0x030044FE /* Show input device and controls */ -#define DIBUTTON_DRIVINGT_PAUSE 0x030044FC /* Start / Pause / Restart game */ - -/*--- Flight Simulator - Civilian - Plane control is the primary objective ---*/ -#define DIVIRTUAL_FLYING_CIVILIAN 0x04000000 -#define DIAXIS_FLYINGC_BANK 0x04008A01 /* Roll ship left / right */ -#define DIAXIS_FLYINGC_PITCH 0x04010A02 /* Nose up / down */ -#define DIAXIS_FLYINGC_THROTTLE 0x04039203 /* Throttle */ -#define DIBUTTON_FLYINGC_VIEW 0x04002401 /* Cycle through view options */ -#define DIBUTTON_FLYINGC_DISPLAY 0x04002402 /* Select next dashboard / heads up display option */ -#define DIBUTTON_FLYINGC_GEAR 0x04002C03 /* Gear up / down */ -#define DIBUTTON_FLYINGC_MENU 0x040004FD /* Show menu options */ -/*--- Priority 2 controls ---*/ - -#define DIHATSWITCH_FLYINGC_GLANCE 0x04004601 /* Look around */ -#define DIAXIS_FLYINGC_BRAKE 0x04046A04 /* Apply Brake */ -#define DIAXIS_FLYINGC_RUDDER 0x04025205 /* Yaw ship left/right */ -#define DIAXIS_FLYINGC_FLAPS 0x04055A06 /* Flaps */ -#define DIBUTTON_FLYINGC_FLAPSUP 0x04006404 /* Increment stepping up until fully retracted */ -#define DIBUTTON_FLYINGC_FLAPSDOWN 0x04006405 /* Decrement stepping down until fully extended */ -#define DIBUTTON_FLYINGC_BRAKE_LINK 0x04046CE0 /* Fallback brake button */ -#define DIBUTTON_FLYINGC_FASTER_LINK 0x0403D4E0 /* Fallback throttle up button */ -#define DIBUTTON_FLYINGC_SLOWER_LINK 0x0403D4E8 /* Fallback throttle down button */ -#define DIBUTTON_FLYINGC_GLANCE_LEFT_LINK 0x0407C4E4 /* Fallback Glance Left button */ -#define DIBUTTON_FLYINGC_GLANCE_RIGHT_LINK 0x0407C4EC /* Fallback Glance Right button */ -#define DIBUTTON_FLYINGC_GLANCE_UP_LINK 0x0407C4E0 /* Fallback Glance Up button */ -#define DIBUTTON_FLYINGC_GLANCE_DOWN_LINK 0x0407C4E8 /* Fallback Glance Down button */ -#define DIBUTTON_FLYINGC_DEVICE 0x040044FE /* Show input device and controls */ -#define DIBUTTON_FLYINGC_PAUSE 0x040044FC /* Start / Pause / Restart game */ - -/*--- Flight Simulator - Military - Aerial combat is the primary objective ---*/ -#define DIVIRTUAL_FLYING_MILITARY 0x05000000 -#define DIAXIS_FLYINGM_BANK 0x05008A01 /* Bank - Roll ship left / right */ -#define DIAXIS_FLYINGM_PITCH 0x05010A02 /* Pitch - Nose up / down */ -#define DIAXIS_FLYINGM_THROTTLE 0x05039203 /* Throttle - faster / slower */ -#define DIBUTTON_FLYINGM_FIRE 0x05000C01 /* Fire */ -#define DIBUTTON_FLYINGM_WEAPONS 0x05000C02 /* Select next weapon */ -#define DIBUTTON_FLYINGM_TARGET 0x05000C03 /* Selects next available target */ -#define DIBUTTON_FLYINGM_MENU 0x050004FD /* Show menu options */ -/*--- Priority 2 controls ---*/ - -#define DIHATSWITCH_FLYINGM_GLANCE 0x05004601 /* Look around */ -#define DIBUTTON_FLYINGM_COUNTER 0x05005C04 /* Activate counter measures */ -#define DIAXIS_FLYINGM_RUDDER 0x05024A04 /* Rudder - Yaw ship left/right */ -#define DIAXIS_FLYINGM_BRAKE 0x05046205 /* Brake-axis */ -#define DIBUTTON_FLYINGM_VIEW 0x05006405 /* Cycle through view options */ -#define DIBUTTON_FLYINGM_DISPLAY 0x05006406 /* Select next dashboard option */ -#define DIAXIS_FLYINGM_FLAPS 0x05055206 /* Flaps */ -#define DIBUTTON_FLYINGM_FLAPSUP 0x05005407 /* Increment stepping up until fully retracted */ -#define DIBUTTON_FLYINGM_FLAPSDOWN 0x05005408 /* Decrement stepping down until fully extended */ -#define DIBUTTON_FLYINGM_FIRESECONDARY 0x05004C09 /* Alternative fire button */ -#define DIBUTTON_FLYINGM_GEAR 0x0500640A /* Gear up / down */ -#define DIBUTTON_FLYINGM_BRAKE_LINK 0x050464E0 /* Fallback brake button */ -#define DIBUTTON_FLYINGM_FASTER_LINK 0x0503D4E0 /* Fallback throttle up button */ -#define DIBUTTON_FLYINGM_SLOWER_LINK 0x0503D4E8 /* Fallback throttle down button */ -#define DIBUTTON_FLYINGM_GLANCE_LEFT_LINK 0x0507C4E4 /* Fallback Glance Left button */ -#define DIBUTTON_FLYINGM_GLANCE_RIGHT_LINK 0x0507C4EC /* Fallback Glance Right button */ -#define DIBUTTON_FLYINGM_GLANCE_UP_LINK 0x0507C4E0 /* Fallback Glance Up button */ -#define DIBUTTON_FLYINGM_GLANCE_DOWN_LINK 0x0507C4E8 /* Fallback Glance Down button */ -#define DIBUTTON_FLYINGM_DEVICE 0x050044FE /* Show input device and controls */ -#define DIBUTTON_FLYINGM_PAUSE 0x050044FC /* Start / Pause / Restart game */ - -/*--- Flight Simulator - Combat Helicopter - Combat from helicopter is primary objective ---*/ -#define DIVIRTUAL_FLYING_HELICOPTER 0x06000000 -#define DIAXIS_FLYINGH_BANK 0x06008A01 /* Bank - Roll ship left / right */ -#define DIAXIS_FLYINGH_PITCH 0x06010A02 /* Pitch - Nose up / down */ -#define DIAXIS_FLYINGH_COLLECTIVE 0x06018A03 /* Collective - Blade pitch/power */ -#define DIBUTTON_FLYINGH_FIRE 0x06001401 /* Fire */ -#define DIBUTTON_FLYINGH_WEAPONS 0x06001402 /* Select next weapon */ -#define DIBUTTON_FLYINGH_TARGET 0x06001403 /* Selects next available target */ -#define DIBUTTON_FLYINGH_MENU 0x060004FD /* Show menu options */ -/*--- Priority 2 controls ---*/ - -#define DIHATSWITCH_FLYINGH_GLANCE 0x06004601 /* Look around */ -#define DIAXIS_FLYINGH_TORQUE 0x06025A04 /* Torque - Rotate ship around left / right axis */ -#define DIAXIS_FLYINGH_THROTTLE 0x0603DA05 /* Throttle */ -#define DIBUTTON_FLYINGH_COUNTER 0x06005404 /* Activate counter measures */ -#define DIBUTTON_FLYINGH_VIEW 0x06006405 /* Cycle through view options */ -#define DIBUTTON_FLYINGH_GEAR 0x06006406 /* Gear up / down */ -#define DIBUTTON_FLYINGH_FIRESECONDARY 0x06004C07 /* Alternative fire button */ -#define DIBUTTON_FLYINGH_FASTER_LINK 0x0603DCE0 /* Fallback throttle up button */ -#define DIBUTTON_FLYINGH_SLOWER_LINK 0x0603DCE8 /* Fallback throttle down button */ -#define DIBUTTON_FLYINGH_GLANCE_LEFT_LINK 0x0607C4E4 /* Fallback Glance Left button */ -#define DIBUTTON_FLYINGH_GLANCE_RIGHT_LINK 0x0607C4EC /* Fallback Glance Right button */ -#define DIBUTTON_FLYINGH_GLANCE_UP_LINK 0x0607C4E0 /* Fallback Glance Up button */ -#define DIBUTTON_FLYINGH_GLANCE_DOWN_LINK 0x0607C4E8 /* Fallback Glance Down button */ -#define DIBUTTON_FLYINGH_DEVICE 0x060044FE /* Show input device and controls */ -#define DIBUTTON_FLYINGH_PAUSE 0x060044FC /* Start / Pause / Restart game */ - -/*--- Space Simulator - Combat - Space Simulator with weapons ---*/ -#define DIVIRTUAL_SPACESIM 0x07000000 -#define DIAXIS_SPACESIM_LATERAL 0x07008201 /* Move ship left / right */ -#define DIAXIS_SPACESIM_MOVE 0x07010202 /* Move ship forward/backward */ -#define DIAXIS_SPACESIM_THROTTLE 0x07038203 /* Throttle - Engine speed */ -#define DIBUTTON_SPACESIM_FIRE 0x07000401 /* Fire */ -#define DIBUTTON_SPACESIM_WEAPONS 0x07000402 /* Select next weapon */ -#define DIBUTTON_SPACESIM_TARGET 0x07000403 /* Selects next available target */ -#define DIBUTTON_SPACESIM_MENU 0x070004FD /* Show menu options */ -/*--- Priority 2 controls ---*/ - -#define DIHATSWITCH_SPACESIM_GLANCE 0x07004601 /* Look around */ -#define DIAXIS_SPACESIM_CLIMB 0x0701C204 /* Climb - Pitch ship up/down */ -#define DIAXIS_SPACESIM_ROTATE 0x07024205 /* Rotate - Turn ship left/right */ -#define DIBUTTON_SPACESIM_VIEW 0x07004404 /* Cycle through view options */ -#define DIBUTTON_SPACESIM_DISPLAY 0x07004405 /* Select next dashboard / heads up display option */ -#define DIBUTTON_SPACESIM_RAISE 0x07004406 /* Raise ship while maintaining current pitch */ -#define DIBUTTON_SPACESIM_LOWER 0x07004407 /* Lower ship while maintaining current pitch */ -#define DIBUTTON_SPACESIM_GEAR 0x07004408 /* Gear up / down */ -#define DIBUTTON_SPACESIM_FIRESECONDARY 0x07004409 /* Alternative fire button */ -#define DIBUTTON_SPACESIM_LEFT_LINK 0x0700C4E4 /* Fallback move left button */ -#define DIBUTTON_SPACESIM_RIGHT_LINK 0x0700C4EC /* Fallback move right button */ -#define DIBUTTON_SPACESIM_FORWARD_LINK 0x070144E0 /* Fallback move forward button */ -#define DIBUTTON_SPACESIM_BACKWARD_LINK 0x070144E8 /* Fallback move backwards button */ -#define DIBUTTON_SPACESIM_FASTER_LINK 0x0703C4E0 /* Fallback throttle up button */ -#define DIBUTTON_SPACESIM_SLOWER_LINK 0x0703C4E8 /* Fallback throttle down button */ -#define DIBUTTON_SPACESIM_TURN_LEFT_LINK 0x070244E4 /* Fallback turn left button */ -#define DIBUTTON_SPACESIM_TURN_RIGHT_LINK 0x070244EC /* Fallback turn right button */ -#define DIBUTTON_SPACESIM_GLANCE_LEFT_LINK 0x0707C4E4 /* Fallback Glance Left button */ -#define DIBUTTON_SPACESIM_GLANCE_RIGHT_LINK 0x0707C4EC /* Fallback Glance Right button */ -#define DIBUTTON_SPACESIM_GLANCE_UP_LINK 0x0707C4E0 /* Fallback Glance Up button */ -#define DIBUTTON_SPACESIM_GLANCE_DOWN_LINK 0x0707C4E8 /* Fallback Glance Down button */ -#define DIBUTTON_SPACESIM_DEVICE 0x070044FE /* Show input device and controls */ -#define DIBUTTON_SPACESIM_PAUSE 0x070044FC /* Start / Pause / Restart game */ - -/*--- Fighting - First Person - Hand to Hand combat is primary objective ---*/ -#define DIVIRTUAL_FIGHTING_HAND2HAND 0x08000000 -#define DIAXIS_FIGHTINGH_LATERAL 0x08008201 /* Sidestep left/right */ -#define DIAXIS_FIGHTINGH_MOVE 0x08010202 /* Move forward/backward */ -#define DIBUTTON_FIGHTINGH_PUNCH 0x08000401 /* Punch */ -#define DIBUTTON_FIGHTINGH_KICK 0x08000402 /* Kick */ -#define DIBUTTON_FIGHTINGH_BLOCK 0x08000403 /* Block */ -#define DIBUTTON_FIGHTINGH_CROUCH 0x08000404 /* Crouch */ -#define DIBUTTON_FIGHTINGH_JUMP 0x08000405 /* Jump */ -#define DIBUTTON_FIGHTINGH_SPECIAL1 0x08000406 /* Apply first special move */ -#define DIBUTTON_FIGHTINGH_SPECIAL2 0x08000407 /* Apply second special move */ -#define DIBUTTON_FIGHTINGH_MENU 0x080004FD /* Show menu options */ -/*--- Priority 2 controls ---*/ - -#define DIBUTTON_FIGHTINGH_SELECT 0x08004408 /* Select special move */ -#define DIHATSWITCH_FIGHTINGH_SLIDE 0x08004601 /* Look around */ -#define DIBUTTON_FIGHTINGH_DISPLAY 0x08004409 /* Shows next on-screen display option */ -#define DIAXIS_FIGHTINGH_ROTATE 0x08024203 /* Rotate - Turn body left/right */ -#define DIBUTTON_FIGHTINGH_DODGE 0x0800440A /* Dodge */ -#define DIBUTTON_FIGHTINGH_LEFT_LINK 0x0800C4E4 /* Fallback left sidestep button */ -#define DIBUTTON_FIGHTINGH_RIGHT_LINK 0x0800C4EC /* Fallback right sidestep button */ -#define DIBUTTON_FIGHTINGH_FORWARD_LINK 0x080144E0 /* Fallback forward button */ -#define DIBUTTON_FIGHTINGH_BACKWARD_LINK 0x080144E8 /* Fallback backward button */ -#define DIBUTTON_FIGHTINGH_DEVICE 0x080044FE /* Show input device and controls */ -#define DIBUTTON_FIGHTINGH_PAUSE 0x080044FC /* Start / Pause / Restart game */ - -/*--- Fighting - First Person Shooting - Navigation and combat are primary objectives ---*/ -#define DIVIRTUAL_FIGHTING_FPS 0x09000000 -#define DIAXIS_FPS_ROTATE 0x09008201 /* Rotate character left/right */ -#define DIAXIS_FPS_MOVE 0x09010202 /* Move forward/backward */ -#define DIBUTTON_FPS_FIRE 0x09000401 /* Fire */ -#define DIBUTTON_FPS_WEAPONS 0x09000402 /* Select next weapon */ -#define DIBUTTON_FPS_APPLY 0x09000403 /* Use item */ -#define DIBUTTON_FPS_SELECT 0x09000404 /* Select next inventory item */ -#define DIBUTTON_FPS_CROUCH 0x09000405 /* Crouch/ climb down/ swim down */ -#define DIBUTTON_FPS_JUMP 0x09000406 /* Jump/ climb up/ swim up */ -#define DIAXIS_FPS_LOOKUPDOWN 0x09018203 /* Look up / down */ -#define DIBUTTON_FPS_STRAFE 0x09000407 /* Enable strafing while active */ -#define DIBUTTON_FPS_MENU 0x090004FD /* Show menu options */ -/*--- Priority 2 controls ---*/ - -#define DIHATSWITCH_FPS_GLANCE 0x09004601 /* Look around */ -#define DIBUTTON_FPS_DISPLAY 0x09004408 /* Shows next on-screen display option/ map */ -#define DIAXIS_FPS_SIDESTEP 0x09024204 /* Sidestep */ -#define DIBUTTON_FPS_DODGE 0x09004409 /* Dodge */ -#define DIBUTTON_FPS_GLANCEL 0x0900440A /* Glance Left */ -#define DIBUTTON_FPS_GLANCER 0x0900440B /* Glance Right */ -#define DIBUTTON_FPS_FIRESECONDARY 0x0900440C /* Alternative fire button */ -#define DIBUTTON_FPS_ROTATE_LEFT_LINK 0x0900C4E4 /* Fallback rotate left button */ -#define DIBUTTON_FPS_ROTATE_RIGHT_LINK 0x0900C4EC /* Fallback rotate right button */ -#define DIBUTTON_FPS_FORWARD_LINK 0x090144E0 /* Fallback forward button */ -#define DIBUTTON_FPS_BACKWARD_LINK 0x090144E8 /* Fallback backward button */ -#define DIBUTTON_FPS_GLANCE_UP_LINK 0x0901C4E0 /* Fallback look up button */ -#define DIBUTTON_FPS_GLANCE_DOWN_LINK 0x0901C4E8 /* Fallback look down button */ -#define DIBUTTON_FPS_STEP_LEFT_LINK 0x090244E4 /* Fallback step left button */ -#define DIBUTTON_FPS_STEP_RIGHT_LINK 0x090244EC /* Fallback step right button */ -#define DIBUTTON_FPS_DEVICE 0x090044FE /* Show input device and controls */ -#define DIBUTTON_FPS_PAUSE 0x090044FC /* Start / Pause / Restart game */ - -/*--- Fighting - Third Person action - Perspective of camera is behind the main character ---*/ -#define DIVIRTUAL_FIGHTING_THIRDPERSON 0x0A000000 -#define DIAXIS_TPS_TURN 0x0A020201 /* Turn left/right */ -#define DIAXIS_TPS_MOVE 0x0A010202 /* Move forward/backward */ -#define DIBUTTON_TPS_RUN 0x0A000401 /* Run or walk toggle switch */ -#define DIBUTTON_TPS_ACTION 0x0A000402 /* Action Button */ -#define DIBUTTON_TPS_SELECT 0x0A000403 /* Select next weapon */ -#define DIBUTTON_TPS_USE 0x0A000404 /* Use inventory item currently selected */ -#define DIBUTTON_TPS_JUMP 0x0A000405 /* Character Jumps */ -#define DIBUTTON_TPS_MENU 0x0A0004FD /* Show menu options */ -/*--- Priority 2 controls ---*/ - -#define DIHATSWITCH_TPS_GLANCE 0x0A004601 /* Look around */ -#define DIBUTTON_TPS_VIEW 0x0A004406 /* Select camera view */ -#define DIBUTTON_TPS_STEPLEFT 0x0A004407 /* Character takes a left step */ -#define DIBUTTON_TPS_STEPRIGHT 0x0A004408 /* Character takes a right step */ -#define DIAXIS_TPS_STEP 0x0A00C203 /* Character steps left/right */ -#define DIBUTTON_TPS_DODGE 0x0A004409 /* Character dodges or ducks */ -#define DIBUTTON_TPS_INVENTORY 0x0A00440A /* Cycle through inventory */ -#define DIBUTTON_TPS_TURN_LEFT_LINK 0x0A0244E4 /* Fallback turn left button */ -#define DIBUTTON_TPS_TURN_RIGHT_LINK 0x0A0244EC /* Fallback turn right button */ -#define DIBUTTON_TPS_FORWARD_LINK 0x0A0144E0 /* Fallback forward button */ -#define DIBUTTON_TPS_BACKWARD_LINK 0x0A0144E8 /* Fallback backward button */ -#define DIBUTTON_TPS_GLANCE_UP_LINK 0x0A07C4E0 /* Fallback look up button */ -#define DIBUTTON_TPS_GLANCE_DOWN_LINK 0x0A07C4E8 /* Fallback look down button */ -#define DIBUTTON_TPS_GLANCE_LEFT_LINK 0x0A07C4E4 /* Fallback glance up button */ -#define DIBUTTON_TPS_GLANCE_RIGHT_LINK 0x0A07C4EC /* Fallback glance right button */ -#define DIBUTTON_TPS_DEVICE 0x0A0044FE /* Show input device and controls */ -#define DIBUTTON_TPS_PAUSE 0x0A0044FC /* Start / Pause / Restart game */ - -/*--- Strategy - Role Playing - Navigation and problem solving are primary actions ---*/ -#define DIVIRTUAL_STRATEGY_ROLEPLAYING 0x0B000000 -#define DIAXIS_STRATEGYR_LATERAL 0x0B008201 /* sidestep - left/right */ -#define DIAXIS_STRATEGYR_MOVE 0x0B010202 /* move forward/backward */ -#define DIBUTTON_STRATEGYR_GET 0x0B000401 /* Acquire item */ -#define DIBUTTON_STRATEGYR_APPLY 0x0B000402 /* Use selected item */ -#define DIBUTTON_STRATEGYR_SELECT 0x0B000403 /* Select nextitem */ -#define DIBUTTON_STRATEGYR_ATTACK 0x0B000404 /* Attack */ -#define DIBUTTON_STRATEGYR_CAST 0x0B000405 /* Cast Spell */ -#define DIBUTTON_STRATEGYR_CROUCH 0x0B000406 /* Crouch */ -#define DIBUTTON_STRATEGYR_JUMP 0x0B000407 /* Jump */ -#define DIBUTTON_STRATEGYR_MENU 0x0B0004FD /* Show menu options */ -/*--- Priority 2 controls ---*/ - -#define DIHATSWITCH_STRATEGYR_GLANCE 0x0B004601 /* Look around */ -#define DIBUTTON_STRATEGYR_MAP 0x0B004408 /* Cycle through map options */ -#define DIBUTTON_STRATEGYR_DISPLAY 0x0B004409 /* Shows next on-screen display option */ -#define DIAXIS_STRATEGYR_ROTATE 0x0B024203 /* Turn body left/right */ -#define DIBUTTON_STRATEGYR_LEFT_LINK 0x0B00C4E4 /* Fallback sidestep left button */ -#define DIBUTTON_STRATEGYR_RIGHT_LINK 0x0B00C4EC /* Fallback sidestep right button */ -#define DIBUTTON_STRATEGYR_FORWARD_LINK 0x0B0144E0 /* Fallback move forward button */ -#define DIBUTTON_STRATEGYR_BACK_LINK 0x0B0144E8 /* Fallback move backward button */ -#define DIBUTTON_STRATEGYR_ROTATE_LEFT_LINK 0x0B0244E4 /* Fallback turn body left button */ -#define DIBUTTON_STRATEGYR_ROTATE_RIGHT_LINK 0x0B0244EC /* Fallback turn body right button */ -#define DIBUTTON_STRATEGYR_DEVICE 0x0B0044FE /* Show input device and controls */ -#define DIBUTTON_STRATEGYR_PAUSE 0x0B0044FC /* Start / Pause / Restart game */ - -/*--- Strategy - Turn based - Navigation and problem solving are primary actions ---*/ -#define DIVIRTUAL_STRATEGY_TURN 0x0C000000 -#define DIAXIS_STRATEGYT_LATERAL 0x0C008201 /* Sidestep left/right */ -#define DIAXIS_STRATEGYT_MOVE 0x0C010202 /* Move forward/backwards */ -#define DIBUTTON_STRATEGYT_SELECT 0x0C000401 /* Select unit or object */ -#define DIBUTTON_STRATEGYT_INSTRUCT 0x0C000402 /* Cycle through instructions */ -#define DIBUTTON_STRATEGYT_APPLY 0x0C000403 /* Apply selected instruction */ -#define DIBUTTON_STRATEGYT_TEAM 0x0C000404 /* Select next team / cycle through all */ -#define DIBUTTON_STRATEGYT_TURN 0x0C000405 /* Indicate turn over */ -#define DIBUTTON_STRATEGYT_MENU 0x0C0004FD /* Show menu options */ -/*--- Priority 2 controls ---*/ - -#define DIBUTTON_STRATEGYT_ZOOM 0x0C004406 /* Zoom - in / out */ -#define DIBUTTON_STRATEGYT_MAP 0x0C004407 /* cycle through map options */ -#define DIBUTTON_STRATEGYT_DISPLAY 0x0C004408 /* shows next on-screen display options */ -#define DIBUTTON_STRATEGYT_LEFT_LINK 0x0C00C4E4 /* Fallback sidestep left button */ -#define DIBUTTON_STRATEGYT_RIGHT_LINK 0x0C00C4EC /* Fallback sidestep right button */ -#define DIBUTTON_STRATEGYT_FORWARD_LINK 0x0C0144E0 /* Fallback move forward button */ -#define DIBUTTON_STRATEGYT_BACK_LINK 0x0C0144E8 /* Fallback move back button */ -#define DIBUTTON_STRATEGYT_DEVICE 0x0C0044FE /* Show input device and controls */ -#define DIBUTTON_STRATEGYT_PAUSE 0x0C0044FC /* Start / Pause / Restart game */ - -/*--- Sports - Hunting - Hunting ---*/ -#define DIVIRTUAL_SPORTS_HUNTING 0x0D000000 -#define DIAXIS_HUNTING_LATERAL 0x0D008201 /* sidestep left/right */ -#define DIAXIS_HUNTING_MOVE 0x0D010202 /* move forward/backwards */ -#define DIBUTTON_HUNTING_FIRE 0x0D000401 /* Fire selected weapon */ -#define DIBUTTON_HUNTING_AIM 0x0D000402 /* Select aim/move */ -#define DIBUTTON_HUNTING_WEAPON 0x0D000403 /* Select next weapon */ -#define DIBUTTON_HUNTING_BINOCULAR 0x0D000404 /* Look through Binoculars */ -#define DIBUTTON_HUNTING_CALL 0x0D000405 /* Make animal call */ -#define DIBUTTON_HUNTING_MAP 0x0D000406 /* View Map */ -#define DIBUTTON_HUNTING_SPECIAL 0x0D000407 /* Special game operation */ -#define DIBUTTON_HUNTING_MENU 0x0D0004FD /* Show menu options */ -/*--- Priority 2 controls ---*/ - -#define DIHATSWITCH_HUNTING_GLANCE 0x0D004601 /* Look around */ -#define DIBUTTON_HUNTING_DISPLAY 0x0D004408 /* show next on-screen display option */ -#define DIAXIS_HUNTING_ROTATE 0x0D024203 /* Turn body left/right */ -#define DIBUTTON_HUNTING_CROUCH 0x0D004409 /* Crouch/ Climb / Swim down */ -#define DIBUTTON_HUNTING_JUMP 0x0D00440A /* Jump/ Climb up / Swim up */ -#define DIBUTTON_HUNTING_FIRESECONDARY 0x0D00440B /* Alternative fire button */ -#define DIBUTTON_HUNTING_LEFT_LINK 0x0D00C4E4 /* Fallback sidestep left button */ -#define DIBUTTON_HUNTING_RIGHT_LINK 0x0D00C4EC /* Fallback sidestep right button */ -#define DIBUTTON_HUNTING_FORWARD_LINK 0x0D0144E0 /* Fallback move forward button */ -#define DIBUTTON_HUNTING_BACK_LINK 0x0D0144E8 /* Fallback move back button */ -#define DIBUTTON_HUNTING_ROTATE_LEFT_LINK 0x0D0244E4 /* Fallback turn body left button */ -#define DIBUTTON_HUNTING_ROTATE_RIGHT_LINK 0x0D0244EC /* Fallback turn body right button */ -#define DIBUTTON_HUNTING_DEVICE 0x0D0044FE /* Show input device and controls */ -#define DIBUTTON_HUNTING_PAUSE 0x0D0044FC /* Start / Pause / Restart game */ - -/*--- Sports - Fishing - Catching Fish is primary objective ---*/ -#define DIVIRTUAL_SPORTS_FISHING 0x0E000000 -#define DIAXIS_FISHING_LATERAL 0x0E008201 /* sidestep left/right */ -#define DIAXIS_FISHING_MOVE 0x0E010202 /* move forward/backwards */ -#define DIBUTTON_FISHING_CAST 0x0E000401 /* Cast line */ -#define DIBUTTON_FISHING_TYPE 0x0E000402 /* Select cast type */ -#define DIBUTTON_FISHING_BINOCULAR 0x0E000403 /* Look through Binocular */ -#define DIBUTTON_FISHING_BAIT 0x0E000404 /* Select type of Bait */ -#define DIBUTTON_FISHING_MAP 0x0E000405 /* View Map */ -#define DIBUTTON_FISHING_MENU 0x0E0004FD /* Show menu options */ -/*--- Priority 2 controls ---*/ - -#define DIHATSWITCH_FISHING_GLANCE 0x0E004601 /* Look around */ -#define DIBUTTON_FISHING_DISPLAY 0x0E004406 /* Show next on-screen display option */ -#define DIAXIS_FISHING_ROTATE 0x0E024203 /* Turn character left / right */ -#define DIBUTTON_FISHING_CROUCH 0x0E004407 /* Crouch/ Climb / Swim down */ -#define DIBUTTON_FISHING_JUMP 0x0E004408 /* Jump/ Climb up / Swim up */ -#define DIBUTTON_FISHING_LEFT_LINK 0x0E00C4E4 /* Fallback sidestep left button */ -#define DIBUTTON_FISHING_RIGHT_LINK 0x0E00C4EC /* Fallback sidestep right button */ -#define DIBUTTON_FISHING_FORWARD_LINK 0x0E0144E0 /* Fallback move forward button */ -#define DIBUTTON_FISHING_BACK_LINK 0x0E0144E8 /* Fallback move back button */ -#define DIBUTTON_FISHING_ROTATE_LEFT_LINK 0x0E0244E4 /* Fallback turn body left button */ -#define DIBUTTON_FISHING_ROTATE_RIGHT_LINK 0x0E0244EC /* Fallback turn body right button */ -#define DIBUTTON_FISHING_DEVICE 0x0E0044FE /* Show input device and controls */ -#define DIBUTTON_FISHING_PAUSE 0x0E0044FC /* Start / Pause / Restart game */ - -/*--- Sports - Baseball - Batting - Batter control is primary objective ---*/ -#define DIVIRTUAL_SPORTS_BASEBALL_BAT 0x0F000000 -#define DIAXIS_BASEBALLB_LATERAL 0x0F008201 /* Aim left / right */ -#define DIAXIS_BASEBALLB_MOVE 0x0F010202 /* Aim up / down */ -#define DIBUTTON_BASEBALLB_SELECT 0x0F000401 /* cycle through swing options */ -#define DIBUTTON_BASEBALLB_NORMAL 0x0F000402 /* normal swing */ -#define DIBUTTON_BASEBALLB_POWER 0x0F000403 /* swing for the fence */ -#define DIBUTTON_BASEBALLB_BUNT 0x0F000404 /* bunt */ -#define DIBUTTON_BASEBALLB_STEAL 0x0F000405 /* Base runner attempts to steal a base */ -#define DIBUTTON_BASEBALLB_BURST 0x0F000406 /* Base runner invokes burst of speed */ -#define DIBUTTON_BASEBALLB_SLIDE 0x0F000407 /* Base runner slides into base */ -#define DIBUTTON_BASEBALLB_CONTACT 0x0F000408 /* Contact swing */ -#define DIBUTTON_BASEBALLB_MENU 0x0F0004FD /* Show menu options */ -/*--- Priority 2 controls ---*/ - -#define DIBUTTON_BASEBALLB_NOSTEAL 0x0F004409 /* Base runner goes back to a base */ -#define DIBUTTON_BASEBALLB_BOX 0x0F00440A /* Enter or exit batting box */ -#define DIBUTTON_BASEBALLB_LEFT_LINK 0x0F00C4E4 /* Fallback sidestep left button */ -#define DIBUTTON_BASEBALLB_RIGHT_LINK 0x0F00C4EC /* Fallback sidestep right button */ -#define DIBUTTON_BASEBALLB_FORWARD_LINK 0x0F0144E0 /* Fallback move forward button */ -#define DIBUTTON_BASEBALLB_BACK_LINK 0x0F0144E8 /* Fallback move back button */ -#define DIBUTTON_BASEBALLB_DEVICE 0x0F0044FE /* Show input device and controls */ -#define DIBUTTON_BASEBALLB_PAUSE 0x0F0044FC /* Start / Pause / Restart game */ - -/*--- Sports - Baseball - Pitching - Pitcher control is primary objective ---*/ -#define DIVIRTUAL_SPORTS_BASEBALL_PITCH 0x10000000 -#define DIAXIS_BASEBALLP_LATERAL 0x10008201 /* Aim left / right */ -#define DIAXIS_BASEBALLP_MOVE 0x10010202 /* Aim up / down */ -#define DIBUTTON_BASEBALLP_SELECT 0x10000401 /* cycle through pitch selections */ -#define DIBUTTON_BASEBALLP_PITCH 0x10000402 /* throw pitch */ -#define DIBUTTON_BASEBALLP_BASE 0x10000403 /* select base to throw to */ -#define DIBUTTON_BASEBALLP_THROW 0x10000404 /* throw to base */ -#define DIBUTTON_BASEBALLP_FAKE 0x10000405 /* Fake a throw to a base */ -#define DIBUTTON_BASEBALLP_MENU 0x100004FD /* Show menu options */ -/*--- Priority 2 controls ---*/ - -#define DIBUTTON_BASEBALLP_WALK 0x10004406 /* Throw intentional walk / pitch out */ -#define DIBUTTON_BASEBALLP_LOOK 0x10004407 /* Look at runners on bases */ -#define DIBUTTON_BASEBALLP_LEFT_LINK 0x1000C4E4 /* Fallback sidestep left button */ -#define DIBUTTON_BASEBALLP_RIGHT_LINK 0x1000C4EC /* Fallback sidestep right button */ -#define DIBUTTON_BASEBALLP_FORWARD_LINK 0x100144E0 /* Fallback move forward button */ -#define DIBUTTON_BASEBALLP_BACK_LINK 0x100144E8 /* Fallback move back button */ -#define DIBUTTON_BASEBALLP_DEVICE 0x100044FE /* Show input device and controls */ -#define DIBUTTON_BASEBALLP_PAUSE 0x100044FC /* Start / Pause / Restart game */ - -/*--- Sports - Baseball - Fielding - Fielder control is primary objective ---*/ -#define DIVIRTUAL_SPORTS_BASEBALL_FIELD 0x11000000 -#define DIAXIS_BASEBALLF_LATERAL 0x11008201 /* Aim left / right */ -#define DIAXIS_BASEBALLF_MOVE 0x11010202 /* Aim up / down */ -#define DIBUTTON_BASEBALLF_NEAREST 0x11000401 /* Switch to fielder nearest to the ball */ -#define DIBUTTON_BASEBALLF_THROW1 0x11000402 /* Make conservative throw */ -#define DIBUTTON_BASEBALLF_THROW2 0x11000403 /* Make aggressive throw */ -#define DIBUTTON_BASEBALLF_BURST 0x11000404 /* Invoke burst of speed */ -#define DIBUTTON_BASEBALLF_JUMP 0x11000405 /* Jump to catch ball */ -#define DIBUTTON_BASEBALLF_DIVE 0x11000406 /* Dive to catch ball */ -#define DIBUTTON_BASEBALLF_MENU 0x110004FD /* Show menu options */ -/*--- Priority 2 controls ---*/ - -#define DIBUTTON_BASEBALLF_SHIFTIN 0x11004407 /* Shift the infield positioning */ -#define DIBUTTON_BASEBALLF_SHIFTOUT 0x11004408 /* Shift the outfield positioning */ -#define DIBUTTON_BASEBALLF_AIM_LEFT_LINK 0x1100C4E4 /* Fallback aim left button */ -#define DIBUTTON_BASEBALLF_AIM_RIGHT_LINK 0x1100C4EC /* Fallback aim right button */ -#define DIBUTTON_BASEBALLF_FORWARD_LINK 0x110144E0 /* Fallback move forward button */ -#define DIBUTTON_BASEBALLF_BACK_LINK 0x110144E8 /* Fallback move back button */ -#define DIBUTTON_BASEBALLF_DEVICE 0x110044FE /* Show input device and controls */ -#define DIBUTTON_BASEBALLF_PAUSE 0x110044FC /* Start / Pause / Restart game */ - -/*--- Sports - Basketball - Offense - Offense ---*/ -#define DIVIRTUAL_SPORTS_BASKETBALL_OFFENSE 0x12000000 -#define DIAXIS_BBALLO_LATERAL 0x12008201 /* left / right */ -#define DIAXIS_BBALLO_MOVE 0x12010202 /* up / down */ -#define DIBUTTON_BBALLO_SHOOT 0x12000401 /* shoot basket */ -#define DIBUTTON_BBALLO_DUNK 0x12000402 /* dunk basket */ -#define DIBUTTON_BBALLO_PASS 0x12000403 /* throw pass */ -#define DIBUTTON_BBALLO_FAKE 0x12000404 /* fake shot or pass */ -#define DIBUTTON_BBALLO_SPECIAL 0x12000405 /* apply special move */ -#define DIBUTTON_BBALLO_PLAYER 0x12000406 /* select next player */ -#define DIBUTTON_BBALLO_BURST 0x12000407 /* invoke burst */ -#define DIBUTTON_BBALLO_CALL 0x12000408 /* call for ball / pass to me */ -#define DIBUTTON_BBALLO_MENU 0x120004FD /* Show menu options */ -/*--- Priority 2 controls ---*/ - -#define DIHATSWITCH_BBALLO_GLANCE 0x12004601 /* scroll view */ -#define DIBUTTON_BBALLO_SCREEN 0x12004409 /* Call for screen */ -#define DIBUTTON_BBALLO_PLAY 0x1200440A /* Call for specific offensive play */ -#define DIBUTTON_BBALLO_JAB 0x1200440B /* Initiate fake drive to basket */ -#define DIBUTTON_BBALLO_POST 0x1200440C /* Perform post move */ -#define DIBUTTON_BBALLO_TIMEOUT 0x1200440D /* Time Out */ -#define DIBUTTON_BBALLO_SUBSTITUTE 0x1200440E /* substitute one player for another */ -#define DIBUTTON_BBALLO_LEFT_LINK 0x1200C4E4 /* Fallback sidestep left button */ -#define DIBUTTON_BBALLO_RIGHT_LINK 0x1200C4EC /* Fallback sidestep right button */ -#define DIBUTTON_BBALLO_FORWARD_LINK 0x120144E0 /* Fallback move forward button */ -#define DIBUTTON_BBALLO_BACK_LINK 0x120144E8 /* Fallback move back button */ -#define DIBUTTON_BBALLO_DEVICE 0x120044FE /* Show input device and controls */ -#define DIBUTTON_BBALLO_PAUSE 0x120044FC /* Start / Pause / Restart game */ - -/*--- Sports - Basketball - Defense - Defense ---*/ -#define DIVIRTUAL_SPORTS_BASKETBALL_DEFENSE 0x13000000 -#define DIAXIS_BBALLD_LATERAL 0x13008201 /* left / right */ -#define DIAXIS_BBALLD_MOVE 0x13010202 /* up / down */ -#define DIBUTTON_BBALLD_JUMP 0x13000401 /* jump to block shot */ -#define DIBUTTON_BBALLD_STEAL 0x13000402 /* attempt to steal ball */ -#define DIBUTTON_BBALLD_FAKE 0x13000403 /* fake block or steal */ -#define DIBUTTON_BBALLD_SPECIAL 0x13000404 /* apply special move */ -#define DIBUTTON_BBALLD_PLAYER 0x13000405 /* select next player */ -#define DIBUTTON_BBALLD_BURST 0x13000406 /* invoke burst */ -#define DIBUTTON_BBALLD_PLAY 0x13000407 /* call for specific defensive play */ -#define DIBUTTON_BBALLD_MENU 0x130004FD /* Show menu options */ -/*--- Priority 2 controls ---*/ - -#define DIHATSWITCH_BBALLD_GLANCE 0x13004601 /* scroll view */ -#define DIBUTTON_BBALLD_TIMEOUT 0x13004408 /* Time Out */ -#define DIBUTTON_BBALLD_SUBSTITUTE 0x13004409 /* substitute one player for another */ -#define DIBUTTON_BBALLD_LEFT_LINK 0x1300C4E4 /* Fallback sidestep left button */ -#define DIBUTTON_BBALLD_RIGHT_LINK 0x1300C4EC /* Fallback sidestep right button */ -#define DIBUTTON_BBALLD_FORWARD_LINK 0x130144E0 /* Fallback move forward button */ -#define DIBUTTON_BBALLD_BACK_LINK 0x130144E8 /* Fallback move back button */ -#define DIBUTTON_BBALLD_DEVICE 0x130044FE /* Show input device and controls */ -#define DIBUTTON_BBALLD_PAUSE 0x130044FC /* Start / Pause / Restart game */ - -/*--- Sports - Football - Play - Play selection ---*/ -#define DIVIRTUAL_SPORTS_FOOTBALL_FIELD 0x14000000 -#define DIBUTTON_FOOTBALLP_PLAY 0x14000401 /* cycle through available plays */ -#define DIBUTTON_FOOTBALLP_SELECT 0x14000402 /* select play */ -#define DIBUTTON_FOOTBALLP_HELP 0x14000403 /* Bring up pop-up help */ -#define DIBUTTON_FOOTBALLP_MENU 0x140004FD /* Show menu options */ -/*--- Priority 2 controls ---*/ - -#define DIBUTTON_FOOTBALLP_DEVICE 0x140044FE /* Show input device and controls */ -#define DIBUTTON_FOOTBALLP_PAUSE 0x140044FC /* Start / Pause / Restart game */ - -/*--- Sports - Football - QB - Offense: Quarterback / Kicker ---*/ -#define DIVIRTUAL_SPORTS_FOOTBALL_QBCK 0x15000000 -#define DIAXIS_FOOTBALLQ_LATERAL 0x15008201 /* Move / Aim: left / right */ -#define DIAXIS_FOOTBALLQ_MOVE 0x15010202 /* Move / Aim: up / down */ -#define DIBUTTON_FOOTBALLQ_SELECT 0x15000401 /* Select */ -#define DIBUTTON_FOOTBALLQ_SNAP 0x15000402 /* snap ball - start play */ -#define DIBUTTON_FOOTBALLQ_JUMP 0x15000403 /* jump over defender */ -#define DIBUTTON_FOOTBALLQ_SLIDE 0x15000404 /* Dive/Slide */ -#define DIBUTTON_FOOTBALLQ_PASS 0x15000405 /* throws pass to receiver */ -#define DIBUTTON_FOOTBALLQ_FAKE 0x15000406 /* pump fake pass or fake kick */ -#define DIBUTTON_FOOTBALLQ_MENU 0x150004FD /* Show menu options */ -/*--- Priority 2 controls ---*/ - -#define DIBUTTON_FOOTBALLQ_FAKESNAP 0x15004407 /* Fake snap */ -#define DIBUTTON_FOOTBALLQ_MOTION 0x15004408 /* Send receivers in motion */ -#define DIBUTTON_FOOTBALLQ_AUDIBLE 0x15004409 /* Change offensive play at line of scrimmage */ -#define DIBUTTON_FOOTBALLQ_LEFT_LINK 0x1500C4E4 /* Fallback sidestep left button */ -#define DIBUTTON_FOOTBALLQ_RIGHT_LINK 0x1500C4EC /* Fallback sidestep right button */ -#define DIBUTTON_FOOTBALLQ_FORWARD_LINK 0x150144E0 /* Fallback move forward button */ -#define DIBUTTON_FOOTBALLQ_BACK_LINK 0x150144E8 /* Fallback move back button */ -#define DIBUTTON_FOOTBALLQ_DEVICE 0x150044FE /* Show input device and controls */ -#define DIBUTTON_FOOTBALLQ_PAUSE 0x150044FC /* Start / Pause / Restart game */ - -/*--- Sports - Football - Offense - Offense - Runner ---*/ -#define DIVIRTUAL_SPORTS_FOOTBALL_OFFENSE 0x16000000 -#define DIAXIS_FOOTBALLO_LATERAL 0x16008201 /* Move / Aim: left / right */ -#define DIAXIS_FOOTBALLO_MOVE 0x16010202 /* Move / Aim: up / down */ -#define DIBUTTON_FOOTBALLO_JUMP 0x16000401 /* jump or hurdle over defender */ -#define DIBUTTON_FOOTBALLO_LEFTARM 0x16000402 /* holds out left arm */ -#define DIBUTTON_FOOTBALLO_RIGHTARM 0x16000403 /* holds out right arm */ -#define DIBUTTON_FOOTBALLO_THROW 0x16000404 /* throw pass or lateral ball to another runner */ -#define DIBUTTON_FOOTBALLO_SPIN 0x16000405 /* Spin to avoid defenders */ -#define DIBUTTON_FOOTBALLO_MENU 0x160004FD /* Show menu options */ -/*--- Priority 2 controls ---*/ - -#define DIBUTTON_FOOTBALLO_JUKE 0x16004406 /* Use special move to avoid defenders */ -#define DIBUTTON_FOOTBALLO_SHOULDER 0x16004407 /* Lower shoulder to run over defenders */ -#define DIBUTTON_FOOTBALLO_TURBO 0x16004408 /* Speed burst past defenders */ -#define DIBUTTON_FOOTBALLO_DIVE 0x16004409 /* Dive over defenders */ -#define DIBUTTON_FOOTBALLO_ZOOM 0x1600440A /* Zoom view in / out */ -#define DIBUTTON_FOOTBALLO_SUBSTITUTE 0x1600440B /* substitute one player for another */ -#define DIBUTTON_FOOTBALLO_LEFT_LINK 0x1600C4E4 /* Fallback sidestep left button */ -#define DIBUTTON_FOOTBALLO_RIGHT_LINK 0x1600C4EC /* Fallback sidestep right button */ -#define DIBUTTON_FOOTBALLO_FORWARD_LINK 0x160144E0 /* Fallback move forward button */ -#define DIBUTTON_FOOTBALLO_BACK_LINK 0x160144E8 /* Fallback move back button */ -#define DIBUTTON_FOOTBALLO_DEVICE 0x160044FE /* Show input device and controls */ -#define DIBUTTON_FOOTBALLO_PAUSE 0x160044FC /* Start / Pause / Restart game */ - -/*--- Sports - Football - Defense - Defense ---*/ -#define DIVIRTUAL_SPORTS_FOOTBALL_DEFENSE 0x17000000 -#define DIAXIS_FOOTBALLD_LATERAL 0x17008201 /* Move / Aim: left / right */ -#define DIAXIS_FOOTBALLD_MOVE 0x17010202 /* Move / Aim: up / down */ -#define DIBUTTON_FOOTBALLD_PLAY 0x17000401 /* cycle through available plays */ -#define DIBUTTON_FOOTBALLD_SELECT 0x17000402 /* select player closest to the ball */ -#define DIBUTTON_FOOTBALLD_JUMP 0x17000403 /* jump to intercept or block */ -#define DIBUTTON_FOOTBALLD_TACKLE 0x17000404 /* tackler runner */ -#define DIBUTTON_FOOTBALLD_FAKE 0x17000405 /* hold down to fake tackle or intercept */ -#define DIBUTTON_FOOTBALLD_SUPERTACKLE 0x17000406 /* Initiate special tackle */ -#define DIBUTTON_FOOTBALLD_MENU 0x170004FD /* Show menu options */ -/*--- Priority 2 controls ---*/ - -#define DIBUTTON_FOOTBALLD_SPIN 0x17004407 /* Spin to beat offensive line */ -#define DIBUTTON_FOOTBALLD_SWIM 0x17004408 /* Swim to beat the offensive line */ -#define DIBUTTON_FOOTBALLD_BULLRUSH 0x17004409 /* Bull rush the offensive line */ -#define DIBUTTON_FOOTBALLD_RIP 0x1700440A /* Rip the offensive line */ -#define DIBUTTON_FOOTBALLD_AUDIBLE 0x1700440B /* Change defensive play at the line of scrimmage */ -#define DIBUTTON_FOOTBALLD_ZOOM 0x1700440C /* Zoom view in / out */ -#define DIBUTTON_FOOTBALLD_SUBSTITUTE 0x1700440D /* substitute one player for another */ -#define DIBUTTON_FOOTBALLD_LEFT_LINK 0x1700C4E4 /* Fallback sidestep left button */ -#define DIBUTTON_FOOTBALLD_RIGHT_LINK 0x1700C4EC /* Fallback sidestep right button */ -#define DIBUTTON_FOOTBALLD_FORWARD_LINK 0x170144E0 /* Fallback move forward button */ -#define DIBUTTON_FOOTBALLD_BACK_LINK 0x170144E8 /* Fallback move back button */ -#define DIBUTTON_FOOTBALLD_DEVICE 0x170044FE /* Show input device and controls */ -#define DIBUTTON_FOOTBALLD_PAUSE 0x170044FC /* Start / Pause / Restart game */ - -/*--- Sports - Golf - ---*/ -#define DIVIRTUAL_SPORTS_GOLF 0x18000000 -#define DIAXIS_GOLF_LATERAL 0x18008201 /* Move / Aim: left / right */ -#define DIAXIS_GOLF_MOVE 0x18010202 /* Move / Aim: up / down */ -#define DIBUTTON_GOLF_SWING 0x18000401 /* swing club */ -#define DIBUTTON_GOLF_SELECT 0x18000402 /* cycle between: club / swing strength / ball arc / ball spin */ -#define DIBUTTON_GOLF_UP 0x18000403 /* increase selection */ -#define DIBUTTON_GOLF_DOWN 0x18000404 /* decrease selection */ -#define DIBUTTON_GOLF_TERRAIN 0x18000405 /* shows terrain detail */ -#define DIBUTTON_GOLF_FLYBY 0x18000406 /* view the hole via a flyby */ -#define DIBUTTON_GOLF_MENU 0x180004FD /* Show menu options */ -/*--- Priority 2 controls ---*/ - -#define DIHATSWITCH_GOLF_SCROLL 0x18004601 /* scroll view */ -#define DIBUTTON_GOLF_ZOOM 0x18004407 /* Zoom view in / out */ -#define DIBUTTON_GOLF_TIMEOUT 0x18004408 /* Call for time out */ -#define DIBUTTON_GOLF_SUBSTITUTE 0x18004409 /* substitute one player for another */ -#define DIBUTTON_GOLF_LEFT_LINK 0x1800C4E4 /* Fallback sidestep left button */ -#define DIBUTTON_GOLF_RIGHT_LINK 0x1800C4EC /* Fallback sidestep right button */ -#define DIBUTTON_GOLF_FORWARD_LINK 0x180144E0 /* Fallback move forward button */ -#define DIBUTTON_GOLF_BACK_LINK 0x180144E8 /* Fallback move back button */ -#define DIBUTTON_GOLF_DEVICE 0x180044FE /* Show input device and controls */ -#define DIBUTTON_GOLF_PAUSE 0x180044FC /* Start / Pause / Restart game */ - -/*--- Sports - Hockey - Offense - Offense ---*/ -#define DIVIRTUAL_SPORTS_HOCKEY_OFFENSE 0x19000000 -#define DIAXIS_HOCKEYO_LATERAL 0x19008201 /* Move / Aim: left / right */ -#define DIAXIS_HOCKEYO_MOVE 0x19010202 /* Move / Aim: up / down */ -#define DIBUTTON_HOCKEYO_SHOOT 0x19000401 /* Shoot */ -#define DIBUTTON_HOCKEYO_PASS 0x19000402 /* pass the puck */ -#define DIBUTTON_HOCKEYO_BURST 0x19000403 /* invoke speed burst */ -#define DIBUTTON_HOCKEYO_SPECIAL 0x19000404 /* invoke special move */ -#define DIBUTTON_HOCKEYO_FAKE 0x19000405 /* hold down to fake pass or kick */ -#define DIBUTTON_HOCKEYO_MENU 0x190004FD /* Show menu options */ -/*--- Priority 2 controls ---*/ - -#define DIHATSWITCH_HOCKEYO_SCROLL 0x19004601 /* scroll view */ -#define DIBUTTON_HOCKEYO_ZOOM 0x19004406 /* Zoom view in / out */ -#define DIBUTTON_HOCKEYO_STRATEGY 0x19004407 /* Invoke coaching menu for strategy help */ -#define DIBUTTON_HOCKEYO_TIMEOUT 0x19004408 /* Call for time out */ -#define DIBUTTON_HOCKEYO_SUBSTITUTE 0x19004409 /* substitute one player for another */ -#define DIBUTTON_HOCKEYO_LEFT_LINK 0x1900C4E4 /* Fallback sidestep left button */ -#define DIBUTTON_HOCKEYO_RIGHT_LINK 0x1900C4EC /* Fallback sidestep right button */ -#define DIBUTTON_HOCKEYO_FORWARD_LINK 0x190144E0 /* Fallback move forward button */ -#define DIBUTTON_HOCKEYO_BACK_LINK 0x190144E8 /* Fallback move back button */ -#define DIBUTTON_HOCKEYO_DEVICE 0x190044FE /* Show input device and controls */ -#define DIBUTTON_HOCKEYO_PAUSE 0x190044FC /* Start / Pause / Restart game */ - -/*--- Sports - Hockey - Defense - Defense ---*/ -#define DIVIRTUAL_SPORTS_HOCKEY_DEFENSE 0x1A000000 -#define DIAXIS_HOCKEYD_LATERAL 0x1A008201 /* Move / Aim: left / right */ -#define DIAXIS_HOCKEYD_MOVE 0x1A010202 /* Move / Aim: up / down */ -#define DIBUTTON_HOCKEYD_PLAYER 0x1A000401 /* control player closest to the puck */ -#define DIBUTTON_HOCKEYD_STEAL 0x1A000402 /* attempt steal */ -#define DIBUTTON_HOCKEYD_BURST 0x1A000403 /* speed burst or body check */ -#define DIBUTTON_HOCKEYD_BLOCK 0x1A000404 /* block puck */ -#define DIBUTTON_HOCKEYD_FAKE 0x1A000405 /* hold down to fake tackle or intercept */ -#define DIBUTTON_HOCKEYD_MENU 0x1A0004FD /* Show menu options */ -/*--- Priority 2 controls ---*/ - -#define DIHATSWITCH_HOCKEYD_SCROLL 0x1A004601 /* scroll view */ -#define DIBUTTON_HOCKEYD_ZOOM 0x1A004406 /* Zoom view in / out */ -#define DIBUTTON_HOCKEYD_STRATEGY 0x1A004407 /* Invoke coaching menu for strategy help */ -#define DIBUTTON_HOCKEYD_TIMEOUT 0x1A004408 /* Call for time out */ -#define DIBUTTON_HOCKEYD_SUBSTITUTE 0x1A004409 /* substitute one player for another */ -#define DIBUTTON_HOCKEYD_LEFT_LINK 0x1A00C4E4 /* Fallback sidestep left button */ -#define DIBUTTON_HOCKEYD_RIGHT_LINK 0x1A00C4EC /* Fallback sidestep right button */ -#define DIBUTTON_HOCKEYD_FORWARD_LINK 0x1A0144E0 /* Fallback move forward button */ -#define DIBUTTON_HOCKEYD_BACK_LINK 0x1A0144E8 /* Fallback move back button */ -#define DIBUTTON_HOCKEYD_DEVICE 0x1A0044FE /* Show input device and controls */ -#define DIBUTTON_HOCKEYD_PAUSE 0x1A0044FC /* Start / Pause / Restart game */ - -/*--- Sports - Hockey - Goalie - Goal tending ---*/ -#define DIVIRTUAL_SPORTS_HOCKEY_GOALIE 0x1B000000 -#define DIAXIS_HOCKEYG_LATERAL 0x1B008201 /* Move / Aim: left / right */ -#define DIAXIS_HOCKEYG_MOVE 0x1B010202 /* Move / Aim: up / down */ -#define DIBUTTON_HOCKEYG_PASS 0x1B000401 /* pass puck */ -#define DIBUTTON_HOCKEYG_POKE 0x1B000402 /* poke / check / hack */ -#define DIBUTTON_HOCKEYG_STEAL 0x1B000403 /* attempt steal */ -#define DIBUTTON_HOCKEYG_BLOCK 0x1B000404 /* block puck */ -#define DIBUTTON_HOCKEYG_MENU 0x1B0004FD /* Show menu options */ -/*--- Priority 2 controls ---*/ - -#define DIHATSWITCH_HOCKEYG_SCROLL 0x1B004601 /* scroll view */ -#define DIBUTTON_HOCKEYG_ZOOM 0x1B004405 /* Zoom view in / out */ -#define DIBUTTON_HOCKEYG_STRATEGY 0x1B004406 /* Invoke coaching menu for strategy help */ -#define DIBUTTON_HOCKEYG_TIMEOUT 0x1B004407 /* Call for time out */ -#define DIBUTTON_HOCKEYG_SUBSTITUTE 0x1B004408 /* substitute one player for another */ -#define DIBUTTON_HOCKEYG_LEFT_LINK 0x1B00C4E4 /* Fallback sidestep left button */ -#define DIBUTTON_HOCKEYG_RIGHT_LINK 0x1B00C4EC /* Fallback sidestep right button */ -#define DIBUTTON_HOCKEYG_FORWARD_LINK 0x1B0144E0 /* Fallback move forward button */ -#define DIBUTTON_HOCKEYG_BACK_LINK 0x1B0144E8 /* Fallback move back button */ -#define DIBUTTON_HOCKEYG_DEVICE 0x1B0044FE /* Show input device and controls */ -#define DIBUTTON_HOCKEYG_PAUSE 0x1B0044FC /* Start / Pause / Restart game */ - -/*--- Sports - Mountain Biking - ---*/ -#define DIVIRTUAL_SPORTS_BIKING_MOUNTAIN 0x1C000000 -#define DIAXIS_BIKINGM_TURN 0x1C008201 /* left / right */ -#define DIAXIS_BIKINGM_PEDAL 0x1C010202 /* Pedal faster / slower / brake */ -#define DIBUTTON_BIKINGM_JUMP 0x1C000401 /* jump over obstacle */ -#define DIBUTTON_BIKINGM_CAMERA 0x1C000402 /* switch camera view */ -#define DIBUTTON_BIKINGM_SPECIAL1 0x1C000403 /* perform first special move */ -#define DIBUTTON_BIKINGM_SELECT 0x1C000404 /* Select */ -#define DIBUTTON_BIKINGM_SPECIAL2 0x1C000405 /* perform second special move */ -#define DIBUTTON_BIKINGM_MENU 0x1C0004FD /* Show menu options */ -/*--- Priority 2 controls ---*/ - -#define DIHATSWITCH_BIKINGM_SCROLL 0x1C004601 /* scroll view */ -#define DIBUTTON_BIKINGM_ZOOM 0x1C004406 /* Zoom view in / out */ -#define DIAXIS_BIKINGM_BRAKE 0x1C044203 /* Brake axis */ -#define DIBUTTON_BIKINGM_LEFT_LINK 0x1C00C4E4 /* Fallback turn left button */ -#define DIBUTTON_BIKINGM_RIGHT_LINK 0x1C00C4EC /* Fallback turn right button */ -#define DIBUTTON_BIKINGM_FASTER_LINK 0x1C0144E0 /* Fallback pedal faster button */ -#define DIBUTTON_BIKINGM_SLOWER_LINK 0x1C0144E8 /* Fallback pedal slower button */ -#define DIBUTTON_BIKINGM_BRAKE_BUTTON_LINK 0x1C0444E8 /* Fallback brake button */ -#define DIBUTTON_BIKINGM_DEVICE 0x1C0044FE /* Show input device and controls */ -#define DIBUTTON_BIKINGM_PAUSE 0x1C0044FC /* Start / Pause / Restart game */ - -/*--- Sports: Skiing / Snowboarding / Skateboarding - ---*/ -#define DIVIRTUAL_SPORTS_SKIING 0x1D000000 -#define DIAXIS_SKIING_TURN 0x1D008201 /* left / right */ -#define DIAXIS_SKIING_SPEED 0x1D010202 /* faster / slower */ -#define DIBUTTON_SKIING_JUMP 0x1D000401 /* Jump */ -#define DIBUTTON_SKIING_CROUCH 0x1D000402 /* crouch down */ -#define DIBUTTON_SKIING_CAMERA 0x1D000403 /* switch camera view */ -#define DIBUTTON_SKIING_SPECIAL1 0x1D000404 /* perform first special move */ -#define DIBUTTON_SKIING_SELECT 0x1D000405 /* Select */ -#define DIBUTTON_SKIING_SPECIAL2 0x1D000406 /* perform second special move */ -#define DIBUTTON_SKIING_MENU 0x1D0004FD /* Show menu options */ -/*--- Priority 2 controls ---*/ - -#define DIHATSWITCH_SKIING_GLANCE 0x1D004601 /* scroll view */ -#define DIBUTTON_SKIING_ZOOM 0x1D004407 /* Zoom view in / out */ -#define DIBUTTON_SKIING_LEFT_LINK 0x1D00C4E4 /* Fallback turn left button */ -#define DIBUTTON_SKIING_RIGHT_LINK 0x1D00C4EC /* Fallback turn right button */ -#define DIBUTTON_SKIING_FASTER_LINK 0x1D0144E0 /* Fallback increase speed button */ -#define DIBUTTON_SKIING_SLOWER_LINK 0x1D0144E8 /* Fallback decrease speed button */ -#define DIBUTTON_SKIING_DEVICE 0x1D0044FE /* Show input device and controls */ -#define DIBUTTON_SKIING_PAUSE 0x1D0044FC /* Start / Pause / Restart game */ - -/*--- Sports - Soccer - Offense - Offense ---*/ -#define DIVIRTUAL_SPORTS_SOCCER_OFFENSE 0x1E000000 -#define DIAXIS_SOCCERO_LATERAL 0x1E008201 /* Move / Aim: left / right */ -#define DIAXIS_SOCCERO_MOVE 0x1E010202 /* Move / Aim: up / down */ -#define DIAXIS_SOCCERO_BEND 0x1E018203 /* Bend to soccer shot/pass */ -#define DIBUTTON_SOCCERO_SHOOT 0x1E000401 /* Shoot the ball */ -#define DIBUTTON_SOCCERO_PASS 0x1E000402 /* Pass */ -#define DIBUTTON_SOCCERO_FAKE 0x1E000403 /* Fake */ -#define DIBUTTON_SOCCERO_PLAYER 0x1E000404 /* Select next player */ -#define DIBUTTON_SOCCERO_SPECIAL1 0x1E000405 /* Apply special move */ -#define DIBUTTON_SOCCERO_SELECT 0x1E000406 /* Select special move */ -#define DIBUTTON_SOCCERO_MENU 0x1E0004FD /* Show menu options */ -/*--- Priority 2 controls ---*/ - -#define DIHATSWITCH_SOCCERO_GLANCE 0x1E004601 /* scroll view */ -#define DIBUTTON_SOCCERO_SUBSTITUTE 0x1E004407 /* Substitute one player for another */ -#define DIBUTTON_SOCCERO_SHOOTLOW 0x1E004408 /* Shoot the ball low */ -#define DIBUTTON_SOCCERO_SHOOTHIGH 0x1E004409 /* Shoot the ball high */ -#define DIBUTTON_SOCCERO_PASSTHRU 0x1E00440A /* Make a thru pass */ -#define DIBUTTON_SOCCERO_SPRINT 0x1E00440B /* Sprint / turbo boost */ -#define DIBUTTON_SOCCERO_CONTROL 0x1E00440C /* Obtain control of the ball */ -#define DIBUTTON_SOCCERO_HEAD 0x1E00440D /* Attempt to head the ball */ -#define DIBUTTON_SOCCERO_LEFT_LINK 0x1E00C4E4 /* Fallback sidestep left button */ -#define DIBUTTON_SOCCERO_RIGHT_LINK 0x1E00C4EC /* Fallback sidestep right button */ -#define DIBUTTON_SOCCERO_FORWARD_LINK 0x1E0144E0 /* Fallback move forward button */ -#define DIBUTTON_SOCCERO_BACK_LINK 0x1E0144E8 /* Fallback move back button */ -#define DIBUTTON_SOCCERO_DEVICE 0x1E0044FE /* Show input device and controls */ -#define DIBUTTON_SOCCERO_PAUSE 0x1E0044FC /* Start / Pause / Restart game */ - -/*--- Sports - Soccer - Defense - Defense ---*/ -#define DIVIRTUAL_SPORTS_SOCCER_DEFENSE 0x1F000000 -#define DIAXIS_SOCCERD_LATERAL 0x1F008201 /* Move / Aim: left / right */ -#define DIAXIS_SOCCERD_MOVE 0x1F010202 /* Move / Aim: up / down */ -#define DIBUTTON_SOCCERD_BLOCK 0x1F000401 /* Attempt to block shot */ -#define DIBUTTON_SOCCERD_STEAL 0x1F000402 /* Attempt to steal ball */ -#define DIBUTTON_SOCCERD_FAKE 0x1F000403 /* Fake a block or a steal */ -#define DIBUTTON_SOCCERD_PLAYER 0x1F000404 /* Select next player */ -#define DIBUTTON_SOCCERD_SPECIAL 0x1F000405 /* Apply special move */ -#define DIBUTTON_SOCCERD_SELECT 0x1F000406 /* Select special move */ -#define DIBUTTON_SOCCERD_SLIDE 0x1F000407 /* Attempt a slide tackle */ -#define DIBUTTON_SOCCERD_MENU 0x1F0004FD /* Show menu options */ -/*--- Priority 2 controls ---*/ - -#define DIHATSWITCH_SOCCERD_GLANCE 0x1F004601 /* scroll view */ -#define DIBUTTON_SOCCERD_FOUL 0x1F004408 /* Initiate a foul / hard-foul */ -#define DIBUTTON_SOCCERD_HEAD 0x1F004409 /* Attempt a Header */ -#define DIBUTTON_SOCCERD_CLEAR 0x1F00440A /* Attempt to clear the ball down the field */ -#define DIBUTTON_SOCCERD_GOALIECHARGE 0x1F00440B /* Make the goalie charge out of the box */ -#define DIBUTTON_SOCCERD_SUBSTITUTE 0x1F00440C /* Substitute one player for another */ -#define DIBUTTON_SOCCERD_LEFT_LINK 0x1F00C4E4 /* Fallback sidestep left button */ -#define DIBUTTON_SOCCERD_RIGHT_LINK 0x1F00C4EC /* Fallback sidestep right button */ -#define DIBUTTON_SOCCERD_FORWARD_LINK 0x1F0144E0 /* Fallback move forward button */ -#define DIBUTTON_SOCCERD_BACK_LINK 0x1F0144E8 /* Fallback move back button */ -#define DIBUTTON_SOCCERD_DEVICE 0x1F0044FE /* Show input device and controls */ -#define DIBUTTON_SOCCERD_PAUSE 0x1F0044FC /* Start / Pause / Restart game */ - -/*--- Sports - Racquet - Tennis - Table-Tennis - Squash ---*/ -#define DIVIRTUAL_SPORTS_RACQUET 0x20000000 -#define DIAXIS_RACQUET_LATERAL 0x20008201 /* Move / Aim: left / right */ -#define DIAXIS_RACQUET_MOVE 0x20010202 /* Move / Aim: up / down */ -#define DIBUTTON_RACQUET_SWING 0x20000401 /* Swing racquet */ -#define DIBUTTON_RACQUET_BACKSWING 0x20000402 /* Swing backhand */ -#define DIBUTTON_RACQUET_SMASH 0x20000403 /* Smash shot */ -#define DIBUTTON_RACQUET_SPECIAL 0x20000404 /* Special shot */ -#define DIBUTTON_RACQUET_SELECT 0x20000405 /* Select special shot */ -#define DIBUTTON_RACQUET_MENU 0x200004FD /* Show menu options */ -/*--- Priority 2 controls ---*/ - -#define DIHATSWITCH_RACQUET_GLANCE 0x20004601 /* scroll view */ -#define DIBUTTON_RACQUET_TIMEOUT 0x20004406 /* Call for time out */ -#define DIBUTTON_RACQUET_SUBSTITUTE 0x20004407 /* Substitute one player for another */ -#define DIBUTTON_RACQUET_LEFT_LINK 0x2000C4E4 /* Fallback sidestep left button */ -#define DIBUTTON_RACQUET_RIGHT_LINK 0x2000C4EC /* Fallback sidestep right button */ -#define DIBUTTON_RACQUET_FORWARD_LINK 0x200144E0 /* Fallback move forward button */ -#define DIBUTTON_RACQUET_BACK_LINK 0x200144E8 /* Fallback move back button */ -#define DIBUTTON_RACQUET_DEVICE 0x200044FE /* Show input device and controls */ -#define DIBUTTON_RACQUET_PAUSE 0x200044FC /* Start / Pause / Restart game */ - -/*--- Arcade- 2D - Side to Side movement ---*/ -#define DIVIRTUAL_ARCADE_SIDE2SIDE 0x21000000 -#define DIAXIS_ARCADES_LATERAL 0x21008201 /* left / right */ -#define DIAXIS_ARCADES_MOVE 0x21010202 /* up / down */ -#define DIBUTTON_ARCADES_THROW 0x21000401 /* throw object */ -#define DIBUTTON_ARCADES_CARRY 0x21000402 /* carry object */ -#define DIBUTTON_ARCADES_ATTACK 0x21000403 /* attack */ -#define DIBUTTON_ARCADES_SPECIAL 0x21000404 /* apply special move */ -#define DIBUTTON_ARCADES_SELECT 0x21000405 /* select special move */ -#define DIBUTTON_ARCADES_MENU 0x210004FD /* Show menu options */ -/*--- Priority 2 controls ---*/ - -#define DIHATSWITCH_ARCADES_VIEW 0x21004601 /* scroll view left / right / up / down */ -#define DIBUTTON_ARCADES_LEFT_LINK 0x2100C4E4 /* Fallback sidestep left button */ -#define DIBUTTON_ARCADES_RIGHT_LINK 0x2100C4EC /* Fallback sidestep right button */ -#define DIBUTTON_ARCADES_FORWARD_LINK 0x210144E0 /* Fallback move forward button */ -#define DIBUTTON_ARCADES_BACK_LINK 0x210144E8 /* Fallback move back button */ -#define DIBUTTON_ARCADES_VIEW_UP_LINK 0x2107C4E0 /* Fallback scroll view up button */ -#define DIBUTTON_ARCADES_VIEW_DOWN_LINK 0x2107C4E8 /* Fallback scroll view down button */ -#define DIBUTTON_ARCADES_VIEW_LEFT_LINK 0x2107C4E4 /* Fallback scroll view left button */ -#define DIBUTTON_ARCADES_VIEW_RIGHT_LINK 0x2107C4EC /* Fallback scroll view right button */ -#define DIBUTTON_ARCADES_DEVICE 0x210044FE /* Show input device and controls */ -#define DIBUTTON_ARCADES_PAUSE 0x210044FC /* Start / Pause / Restart game */ - -/*--- Arcade - Platform Game - Character moves around on screen ---*/ -#define DIVIRTUAL_ARCADE_PLATFORM 0x22000000 -#define DIAXIS_ARCADEP_LATERAL 0x22008201 /* Left / right */ -#define DIAXIS_ARCADEP_MOVE 0x22010202 /* Up / down */ -#define DIBUTTON_ARCADEP_JUMP 0x22000401 /* Jump */ -#define DIBUTTON_ARCADEP_FIRE 0x22000402 /* Fire */ -#define DIBUTTON_ARCADEP_CROUCH 0x22000403 /* Crouch */ -#define DIBUTTON_ARCADEP_SPECIAL 0x22000404 /* Apply special move */ -#define DIBUTTON_ARCADEP_SELECT 0x22000405 /* Select special move */ -#define DIBUTTON_ARCADEP_MENU 0x220004FD /* Show menu options */ -/*--- Priority 2 controls ---*/ - -#define DIHATSWITCH_ARCADEP_VIEW 0x22004601 /* Scroll view */ -#define DIBUTTON_ARCADEP_FIRESECONDARY 0x22004406 /* Alternative fire button */ -#define DIBUTTON_ARCADEP_LEFT_LINK 0x2200C4E4 /* Fallback sidestep left button */ -#define DIBUTTON_ARCADEP_RIGHT_LINK 0x2200C4EC /* Fallback sidestep right button */ -#define DIBUTTON_ARCADEP_FORWARD_LINK 0x220144E0 /* Fallback move forward button */ -#define DIBUTTON_ARCADEP_BACK_LINK 0x220144E8 /* Fallback move back button */ -#define DIBUTTON_ARCADEP_VIEW_UP_LINK 0x2207C4E0 /* Fallback scroll view up button */ -#define DIBUTTON_ARCADEP_VIEW_DOWN_LINK 0x2207C4E8 /* Fallback scroll view down button */ -#define DIBUTTON_ARCADEP_VIEW_LEFT_LINK 0x2207C4E4 /* Fallback scroll view left button */ -#define DIBUTTON_ARCADEP_VIEW_RIGHT_LINK 0x2207C4EC /* Fallback scroll view right button */ -#define DIBUTTON_ARCADEP_DEVICE 0x220044FE /* Show input device and controls */ -#define DIBUTTON_ARCADEP_PAUSE 0x220044FC /* Start / Pause / Restart game */ - -/*--- CAD - 2D Object Control - Controls to select and move objects in 2D ---*/ -#define DIVIRTUAL_CAD_2DCONTROL 0x23000000 -#define DIAXIS_2DCONTROL_LATERAL 0x23008201 /* Move view left / right */ -#define DIAXIS_2DCONTROL_MOVE 0x23010202 /* Move view up / down */ -#define DIAXIS_2DCONTROL_INOUT 0x23018203 /* Zoom - in / out */ -#define DIBUTTON_2DCONTROL_SELECT 0x23000401 /* Select Object */ -#define DIBUTTON_2DCONTROL_SPECIAL1 0x23000402 /* Do first special operation */ -#define DIBUTTON_2DCONTROL_SPECIAL 0x23000403 /* Select special operation */ -#define DIBUTTON_2DCONTROL_SPECIAL2 0x23000404 /* Do second special operation */ -#define DIBUTTON_2DCONTROL_MENU 0x230004FD /* Show menu options */ -/*--- Priority 2 controls ---*/ - -#define DIHATSWITCH_2DCONTROL_HATSWITCH 0x23004601 /* Hat switch */ -#define DIAXIS_2DCONTROL_ROTATEZ 0x23024204 /* Rotate view clockwise / counterclockwise */ -#define DIBUTTON_2DCONTROL_DISPLAY 0x23004405 /* Shows next on-screen display options */ -#define DIBUTTON_2DCONTROL_DEVICE 0x230044FE /* Show input device and controls */ -#define DIBUTTON_2DCONTROL_PAUSE 0x230044FC /* Start / Pause / Restart game */ - -/*--- CAD - 3D object control - Controls to select and move objects within a 3D environment ---*/ -#define DIVIRTUAL_CAD_3DCONTROL 0x24000000 -#define DIAXIS_3DCONTROL_LATERAL 0x24008201 /* Move view left / right */ -#define DIAXIS_3DCONTROL_MOVE 0x24010202 /* Move view up / down */ -#define DIAXIS_3DCONTROL_INOUT 0x24018203 /* Zoom - in / out */ -#define DIBUTTON_3DCONTROL_SELECT 0x24000401 /* Select Object */ -#define DIBUTTON_3DCONTROL_SPECIAL1 0x24000402 /* Do first special operation */ -#define DIBUTTON_3DCONTROL_SPECIAL 0x24000403 /* Select special operation */ -#define DIBUTTON_3DCONTROL_SPECIAL2 0x24000404 /* Do second special operation */ -#define DIBUTTON_3DCONTROL_MENU 0x240004FD /* Show menu options */ -/*--- Priority 2 controls ---*/ - -#define DIHATSWITCH_3DCONTROL_HATSWITCH 0x24004601 /* Hat switch */ -#define DIAXIS_3DCONTROL_ROTATEX 0x24034204 /* Rotate view forward or up / backward or down */ -#define DIAXIS_3DCONTROL_ROTATEY 0x2402C205 /* Rotate view clockwise / counterclockwise */ -#define DIAXIS_3DCONTROL_ROTATEZ 0x24024206 /* Rotate view left / right */ -#define DIBUTTON_3DCONTROL_DISPLAY 0x24004405 /* Show next on-screen display options */ -#define DIBUTTON_3DCONTROL_DEVICE 0x240044FE /* Show input device and controls */ -#define DIBUTTON_3DCONTROL_PAUSE 0x240044FC /* Start / Pause / Restart game */ - -/*--- CAD - 3D Navigation - Fly through - Controls for 3D modeling ---*/ -#define DIVIRTUAL_CAD_FLYBY 0x25000000 -#define DIAXIS_CADF_LATERAL 0x25008201 /* move view left / right */ -#define DIAXIS_CADF_MOVE 0x25010202 /* move view up / down */ -#define DIAXIS_CADF_INOUT 0x25018203 /* in / out */ -#define DIBUTTON_CADF_SELECT 0x25000401 /* Select Object */ -#define DIBUTTON_CADF_SPECIAL1 0x25000402 /* do first special operation */ -#define DIBUTTON_CADF_SPECIAL 0x25000403 /* Select special operation */ -#define DIBUTTON_CADF_SPECIAL2 0x25000404 /* do second special operation */ -#define DIBUTTON_CADF_MENU 0x250004FD /* Show menu options */ -/*--- Priority 2 controls ---*/ - -#define DIHATSWITCH_CADF_HATSWITCH 0x25004601 /* Hat switch */ -#define DIAXIS_CADF_ROTATEX 0x25034204 /* Rotate view forward or up / backward or down */ -#define DIAXIS_CADF_ROTATEY 0x2502C205 /* Rotate view clockwise / counterclockwise */ -#define DIAXIS_CADF_ROTATEZ 0x25024206 /* Rotate view left / right */ -#define DIBUTTON_CADF_DISPLAY 0x25004405 /* shows next on-screen display options */ -#define DIBUTTON_CADF_DEVICE 0x250044FE /* Show input device and controls */ -#define DIBUTTON_CADF_PAUSE 0x250044FC /* Start / Pause / Restart game */ - -/*--- CAD - 3D Model Control - Controls for 3D modeling ---*/ -#define DIVIRTUAL_CAD_MODEL 0x26000000 -#define DIAXIS_CADM_LATERAL 0x26008201 /* move view left / right */ -#define DIAXIS_CADM_MOVE 0x26010202 /* move view up / down */ -#define DIAXIS_CADM_INOUT 0x26018203 /* in / out */ -#define DIBUTTON_CADM_SELECT 0x26000401 /* Select Object */ -#define DIBUTTON_CADM_SPECIAL1 0x26000402 /* do first special operation */ -#define DIBUTTON_CADM_SPECIAL 0x26000403 /* Select special operation */ -#define DIBUTTON_CADM_SPECIAL2 0x26000404 /* do second special operation */ -#define DIBUTTON_CADM_MENU 0x260004FD /* Show menu options */ -/*--- Priority 2 controls ---*/ - -#define DIHATSWITCH_CADM_HATSWITCH 0x26004601 /* Hat switch */ -#define DIAXIS_CADM_ROTATEX 0x26034204 /* Rotate view forward or up / backward or down */ -#define DIAXIS_CADM_ROTATEY 0x2602C205 /* Rotate view clockwise / counterclockwise */ -#define DIAXIS_CADM_ROTATEZ 0x26024206 /* Rotate view left / right */ -#define DIBUTTON_CADM_DISPLAY 0x26004405 /* shows next on-screen display options */ -#define DIBUTTON_CADM_DEVICE 0x260044FE /* Show input device and controls */ -#define DIBUTTON_CADM_PAUSE 0x260044FC /* Start / Pause / Restart game */ - -/*--- Control - Media Equipment - Remote ---*/ -#define DIVIRTUAL_REMOTE_CONTROL 0x27000000 -#define DIAXIS_REMOTE_SLIDER 0x27050201 /* Slider for adjustment: volume / color / bass / etc */ -#define DIBUTTON_REMOTE_MUTE 0x27000401 /* Set volume on current device to zero */ -#define DIBUTTON_REMOTE_SELECT 0x27000402 /* Next/previous: channel/ track / chapter / picture / station */ -#define DIBUTTON_REMOTE_PLAY 0x27002403 /* Start or pause entertainment on current device */ -#define DIBUTTON_REMOTE_CUE 0x27002404 /* Move through current media */ -#define DIBUTTON_REMOTE_REVIEW 0x27002405 /* Move through current media */ -#define DIBUTTON_REMOTE_CHANGE 0x27002406 /* Select next device */ -#define DIBUTTON_REMOTE_RECORD 0x27002407 /* Start recording the current media */ -#define DIBUTTON_REMOTE_MENU 0x270004FD /* Show menu options */ -/*--- Priority 2 controls ---*/ - -#define DIAXIS_REMOTE_SLIDER2 0x27054202 /* Slider for adjustment: volume */ -#define DIBUTTON_REMOTE_TV 0x27005C08 /* Select TV */ -#define DIBUTTON_REMOTE_CABLE 0x27005C09 /* Select cable box */ -#define DIBUTTON_REMOTE_CD 0x27005C0A /* Select CD player */ -#define DIBUTTON_REMOTE_VCR 0x27005C0B /* Select VCR */ -#define DIBUTTON_REMOTE_TUNER 0x27005C0C /* Select tuner */ -#define DIBUTTON_REMOTE_DVD 0x27005C0D /* Select DVD player */ -#define DIBUTTON_REMOTE_ADJUST 0x27005C0E /* Enter device adjustment menu */ -#define DIBUTTON_REMOTE_DIGIT0 0x2700540F /* Digit 0 */ -#define DIBUTTON_REMOTE_DIGIT1 0x27005410 /* Digit 1 */ -#define DIBUTTON_REMOTE_DIGIT2 0x27005411 /* Digit 2 */ -#define DIBUTTON_REMOTE_DIGIT3 0x27005412 /* Digit 3 */ -#define DIBUTTON_REMOTE_DIGIT4 0x27005413 /* Digit 4 */ -#define DIBUTTON_REMOTE_DIGIT5 0x27005414 /* Digit 5 */ -#define DIBUTTON_REMOTE_DIGIT6 0x27005415 /* Digit 6 */ -#define DIBUTTON_REMOTE_DIGIT7 0x27005416 /* Digit 7 */ -#define DIBUTTON_REMOTE_DIGIT8 0x27005417 /* Digit 8 */ -#define DIBUTTON_REMOTE_DIGIT9 0x27005418 /* Digit 9 */ -#define DIBUTTON_REMOTE_DEVICE 0x270044FE /* Show input device and controls */ -#define DIBUTTON_REMOTE_PAUSE 0x270044FC /* Start / Pause / Restart game */ - -/*--- Control- Web - Help or Browser ---*/ -#define DIVIRTUAL_BROWSER_CONTROL 0x28000000 -#define DIAXIS_BROWSER_LATERAL 0x28008201 /* Move on screen pointer */ -#define DIAXIS_BROWSER_MOVE 0x28010202 /* Move on screen pointer */ -#define DIBUTTON_BROWSER_SELECT 0x28000401 /* Select current item */ -#define DIAXIS_BROWSER_VIEW 0x28018203 /* Move view up/down */ -#define DIBUTTON_BROWSER_REFRESH 0x28000402 /* Refresh */ -#define DIBUTTON_BROWSER_MENU 0x280004FD /* Show menu options */ -/*--- Priority 2 controls ---*/ - -#define DIBUTTON_BROWSER_SEARCH 0x28004403 /* Use search tool */ -#define DIBUTTON_BROWSER_STOP 0x28004404 /* Cease current update */ -#define DIBUTTON_BROWSER_HOME 0x28004405 /* Go directly to "home" location */ -#define DIBUTTON_BROWSER_FAVORITES 0x28004406 /* Mark current site as favorite */ -#define DIBUTTON_BROWSER_NEXT 0x28004407 /* Select Next page */ -#define DIBUTTON_BROWSER_PREVIOUS 0x28004408 /* Select Previous page */ -#define DIBUTTON_BROWSER_HISTORY 0x28004409 /* Show/Hide History */ -#define DIBUTTON_BROWSER_PRINT 0x2800440A /* Print current page */ -#define DIBUTTON_BROWSER_DEVICE 0x280044FE /* Show input device and controls */ -#define DIBUTTON_BROWSER_PAUSE 0x280044FC /* Start / Pause / Restart game */ - -/*--- Driving Simulator - Giant Walking Robot - Walking tank with weapons ---*/ -#define DIVIRTUAL_DRIVING_MECHA 0x29000000 -#define DIAXIS_MECHA_STEER 0x29008201 /* Turns mecha left/right */ -#define DIAXIS_MECHA_TORSO 0x29010202 /* Tilts torso forward/backward */ -#define DIAXIS_MECHA_ROTATE 0x29020203 /* Turns torso left/right */ -#define DIAXIS_MECHA_THROTTLE 0x29038204 /* Engine Speed */ -#define DIBUTTON_MECHA_FIRE 0x29000401 /* Fire */ -#define DIBUTTON_MECHA_WEAPONS 0x29000402 /* Select next weapon group */ -#define DIBUTTON_MECHA_TARGET 0x29000403 /* Select closest enemy available target */ -#define DIBUTTON_MECHA_REVERSE 0x29000404 /* Toggles throttle in/out of reverse */ -#define DIBUTTON_MECHA_ZOOM 0x29000405 /* Zoom in/out targeting reticule */ -#define DIBUTTON_MECHA_JUMP 0x29000406 /* Fires jump jets */ -#define DIBUTTON_MECHA_MENU 0x290004FD /* Show menu options */ -/*--- Priority 2 controls ---*/ - -#define DIBUTTON_MECHA_CENTER 0x29004407 /* Center torso to legs */ -#define DIHATSWITCH_MECHA_GLANCE 0x29004601 /* Look around */ -#define DIBUTTON_MECHA_VIEW 0x29004408 /* Cycle through view options */ -#define DIBUTTON_MECHA_FIRESECONDARY 0x29004409 /* Alternative fire button */ -#define DIBUTTON_MECHA_LEFT_LINK 0x2900C4E4 /* Fallback steer left button */ -#define DIBUTTON_MECHA_RIGHT_LINK 0x2900C4EC /* Fallback steer right button */ -#define DIBUTTON_MECHA_FORWARD_LINK 0x290144E0 /* Fallback tilt torso forward button */ -#define DIBUTTON_MECHA_BACK_LINK 0x290144E8 /* Fallback tilt toroso backward button */ -#define DIBUTTON_MECHA_ROTATE_LEFT_LINK 0x290244E4 /* Fallback rotate toroso right button */ -#define DIBUTTON_MECHA_ROTATE_RIGHT_LINK 0x290244EC /* Fallback rotate torso left button */ -#define DIBUTTON_MECHA_FASTER_LINK 0x2903C4E0 /* Fallback increase engine speed */ -#define DIBUTTON_MECHA_SLOWER_LINK 0x2903C4E8 /* Fallback decrease engine speed */ -#define DIBUTTON_MECHA_DEVICE 0x290044FE /* Show input device and controls */ -#define DIBUTTON_MECHA_PAUSE 0x290044FC /* Start / Pause / Restart game */ - -/* - * "ANY" semantics can be used as a last resort to get mappings for actions - * that match nothing in the chosen virtual genre. These semantics will be - * mapped at a lower priority that virtual genre semantics. Also, hardware - * vendors will not be able to provide sensible mappings for these unless - * they provide application specific mappings. - */ -#define DIAXIS_ANY_X_1 0xFF00C201 -#define DIAXIS_ANY_X_2 0xFF00C202 -#define DIAXIS_ANY_Y_1 0xFF014201 -#define DIAXIS_ANY_Y_2 0xFF014202 -#define DIAXIS_ANY_Z_1 0xFF01C201 -#define DIAXIS_ANY_Z_2 0xFF01C202 -#define DIAXIS_ANY_R_1 0xFF024201 -#define DIAXIS_ANY_R_2 0xFF024202 -#define DIAXIS_ANY_U_1 0xFF02C201 -#define DIAXIS_ANY_U_2 0xFF02C202 -#define DIAXIS_ANY_V_1 0xFF034201 -#define DIAXIS_ANY_V_2 0xFF034202 -#define DIAXIS_ANY_A_1 0xFF03C201 -#define DIAXIS_ANY_A_2 0xFF03C202 -#define DIAXIS_ANY_B_1 0xFF044201 -#define DIAXIS_ANY_B_2 0xFF044202 -#define DIAXIS_ANY_C_1 0xFF04C201 -#define DIAXIS_ANY_C_2 0xFF04C202 -#define DIAXIS_ANY_S_1 0xFF054201 -#define DIAXIS_ANY_S_2 0xFF054202 - -#define DIAXIS_ANY_1 0xFF004201 -#define DIAXIS_ANY_2 0xFF004202 -#define DIAXIS_ANY_3 0xFF004203 -#define DIAXIS_ANY_4 0xFF004204 - -#define DIPOV_ANY_1 0xFF004601 -#define DIPOV_ANY_2 0xFF004602 -#define DIPOV_ANY_3 0xFF004603 -#define DIPOV_ANY_4 0xFF004604 - -#define DIBUTTON_ANY(instance) ( 0xFF004400 | instance ) - - -#ifdef __cplusplus -}; -#endif - -#endif /* __DINPUT_INCLUDED__ */ - -/**************************************************************************** - * - * Definitions for non-IDirectInput (VJoyD) features defined more recently - * than the current sdk files - * - ****************************************************************************/ - -#ifdef _INC_MMSYSTEM -#ifndef MMNOJOY - -#ifndef __VJOYDX_INCLUDED__ -#define __VJOYDX_INCLUDED__ - -#ifdef __cplusplus -extern "C" { -#endif - -/* - * Flag to indicate that the dwReserved2 field of the JOYINFOEX structure - * contains mini-driver specific data to be passed by VJoyD to the mini- - * driver instead of doing a poll. - */ -#define JOY_PASSDRIVERDATA 0x10000000l - -/* - * Informs the joystick driver that the configuration has been changed - * and should be reloaded from the registery. - * dwFlags is reserved and should be set to zero - */ -WINMMAPI MMRESULT WINAPI joyConfigChanged( DWORD dwFlags ); - -#ifndef DIJ_RINGZERO -/* - * Invoke the joystick control panel directly, using the passed window handle - * as the parent of the dialog. This API is only supported for compatibility - * purposes; new applications should use the RunControlPanel method of a - * device interface for a game controller. - * The API is called by using the function pointer returned by - * GetProcAddress( hCPL, TEXT("ShowJoyCPL") ) where hCPL is a HMODULE returned - * by LoadLibrary( TEXT("joy.cpl") ). The typedef is provided to allow - * declaration and casting of an appropriately typed variable. - */ -void WINAPI ShowJoyCPL( HWND hWnd ); -typedef void (WINAPI* LPFNSHOWJOYCPL)( HWND hWnd ); -#endif /* DIJ_RINGZERO */ - - -/* - * Hardware Setting indicating that the device is a headtracker - */ -#define JOY_HWS_ISHEADTRACKER 0x02000000l - -/* - * Hardware Setting indicating that the VxD is used to replace - * the standard analog polling - */ -#define JOY_HWS_ISGAMEPORTDRIVER 0x04000000l - -/* - * Hardware Setting indicating that the driver needs a standard - * gameport in order to communicate with the device. - */ -#define JOY_HWS_ISANALOGPORTDRIVER 0x08000000l - -/* - * Hardware Setting indicating that VJoyD should not load this - * driver, it will be loaded externally and will register with - * VJoyD of it's own accord. - */ -#define JOY_HWS_AUTOLOAD 0x10000000l - -/* - * Hardware Setting indicating that the driver acquires any - * resources needed without needing a devnode through VJoyD. - */ -#define JOY_HWS_NODEVNODE 0x20000000l - - -/* - * Hardware Setting indicating that the device is a gameport bus - */ -#define JOY_HWS_ISGAMEPORTBUS 0x80000000l -#define JOY_HWS_GAMEPORTBUSBUSY 0x00000001l - -/* - * Usage Setting indicating that the settings are volatile and - * should be removed if still present on a reboot. - */ -#define JOY_US_VOLATILE 0x00000008L - -#ifdef __cplusplus -}; -#endif - -#endif /* __VJOYDX_INCLUDED__ */ - -#endif /* not MMNOJOY */ -#endif /* _INC_MMSYSTEM */ - -/**************************************************************************** - * - * Definitions for non-IDirectInput (VJoyD) features defined more recently - * than the current ddk files - * - ****************************************************************************/ - -#ifndef DIJ_RINGZERO - -#ifdef _INC_MMDDK -#ifndef MMNOJOYDEV - -#ifndef __VJOYDXD_INCLUDED__ -#define __VJOYDXD_INCLUDED__ -/* - * Poll type in which the do_other field of the JOYOEMPOLLDATA - * structure contains mini-driver specific data passed from an app. - */ -#define JOY_OEMPOLL_PASSDRIVERDATA 7 - -#endif /* __VJOYDXD_INCLUDED__ */ - -#endif /* not MMNOJOYDEV */ -#endif /* _INC_MMDDK */ - -#endif /* DIJ_RINGZERO */ - +/**************************************************************************** + * + * Copyright (C) 1996-2000 Microsoft Corporation. All Rights Reserved. + * + * File: dinput.h + * Content: DirectInput include file + * + ****************************************************************************/ + +#ifndef __DINPUT_INCLUDED__ +#define __DINPUT_INCLUDED__ + +#ifndef DIJ_RINGZERO + +#ifdef _WIN32 +#define COM_NO_WINDOWS_H +#include +#endif + +#endif /* DIJ_RINGZERO */ + +#ifdef __cplusplus +extern "C" { +#endif + + + + + +/* + * To build applications for older versions of DirectInput + * + * #define DIRECTINPUT_VERSION [ 0x0300 | 0x0500 | 0x0700 ] + * + * before #include . By default, #include + * will produce a DirectX 8-compatible header file. + * + */ + +#define DIRECTINPUT_HEADER_VERSION 0x0800 +#ifndef DIRECTINPUT_VERSION +#define DIRECTINPUT_VERSION DIRECTINPUT_HEADER_VERSION +#pragma message(__FILE__ ": DIRECTINPUT_VERSION undefined. Defaulting to version 0x0800") +#endif + +#ifndef DIJ_RINGZERO + +/**************************************************************************** + * + * Class IDs + * + ****************************************************************************/ + +DEFINE_GUID(CLSID_DirectInput, 0x25E609E0,0xB259,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); +DEFINE_GUID(CLSID_DirectInputDevice, 0x25E609E1,0xB259,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); + +DEFINE_GUID(CLSID_DirectInput8, 0x25E609E4,0xB259,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); +DEFINE_GUID(CLSID_DirectInputDevice8,0x25E609E5,0xB259,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); + +/**************************************************************************** + * + * Interfaces + * + ****************************************************************************/ + +DEFINE_GUID(IID_IDirectInputA, 0x89521360,0xAA8A,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); +DEFINE_GUID(IID_IDirectInputW, 0x89521361,0xAA8A,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); +DEFINE_GUID(IID_IDirectInput2A, 0x5944E662,0xAA8A,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); +DEFINE_GUID(IID_IDirectInput2W, 0x5944E663,0xAA8A,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); +DEFINE_GUID(IID_IDirectInput7A, 0x9A4CB684,0x236D,0x11D3,0x8E,0x9D,0x00,0xC0,0x4F,0x68,0x44,0xAE); +DEFINE_GUID(IID_IDirectInput7W, 0x9A4CB685,0x236D,0x11D3,0x8E,0x9D,0x00,0xC0,0x4F,0x68,0x44,0xAE); +DEFINE_GUID(IID_IDirectInput8A, 0xBF798030,0x483A,0x4DA2,0xAA,0x99,0x5D,0x64,0xED,0x36,0x97,0x00); +DEFINE_GUID(IID_IDirectInput8W, 0xBF798031,0x483A,0x4DA2,0xAA,0x99,0x5D,0x64,0xED,0x36,0x97,0x00); +DEFINE_GUID(IID_IDirectInputDeviceA, 0x5944E680,0xC92E,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); +DEFINE_GUID(IID_IDirectInputDeviceW, 0x5944E681,0xC92E,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); +DEFINE_GUID(IID_IDirectInputDevice2A,0x5944E682,0xC92E,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); +DEFINE_GUID(IID_IDirectInputDevice2W,0x5944E683,0xC92E,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); +DEFINE_GUID(IID_IDirectInputDevice7A,0x57D7C6BC,0x2356,0x11D3,0x8E,0x9D,0x00,0xC0,0x4F,0x68,0x44,0xAE); +DEFINE_GUID(IID_IDirectInputDevice7W,0x57D7C6BD,0x2356,0x11D3,0x8E,0x9D,0x00,0xC0,0x4F,0x68,0x44,0xAE); +DEFINE_GUID(IID_IDirectInputDevice8A,0x54D41080,0xDC15,0x4833,0xA4,0x1B,0x74,0x8F,0x73,0xA3,0x81,0x79); +DEFINE_GUID(IID_IDirectInputDevice8W,0x54D41081,0xDC15,0x4833,0xA4,0x1B,0x74,0x8F,0x73,0xA3,0x81,0x79); +DEFINE_GUID(IID_IDirectInputEffect, 0xE7E1F7C0,0x88D2,0x11D0,0x9A,0xD0,0x00,0xA0,0xC9,0xA0,0x6E,0x35); + +/**************************************************************************** + * + * Predefined object types + * + ****************************************************************************/ + +DEFINE_GUID(GUID_XAxis, 0xA36D02E0,0xC9F3,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); +DEFINE_GUID(GUID_YAxis, 0xA36D02E1,0xC9F3,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); +DEFINE_GUID(GUID_ZAxis, 0xA36D02E2,0xC9F3,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); +DEFINE_GUID(GUID_RxAxis, 0xA36D02F4,0xC9F3,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); +DEFINE_GUID(GUID_RyAxis, 0xA36D02F5,0xC9F3,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); +DEFINE_GUID(GUID_RzAxis, 0xA36D02E3,0xC9F3,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); +DEFINE_GUID(GUID_Slider, 0xA36D02E4,0xC9F3,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); + +DEFINE_GUID(GUID_Button, 0xA36D02F0,0xC9F3,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); +DEFINE_GUID(GUID_Key, 0x55728220,0xD33C,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); + +DEFINE_GUID(GUID_POV, 0xA36D02F2,0xC9F3,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); + +DEFINE_GUID(GUID_Unknown, 0xA36D02F3,0xC9F3,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); + +/**************************************************************************** + * + * Predefined product GUIDs + * + ****************************************************************************/ + +DEFINE_GUID(GUID_SysMouse, 0x6F1D2B60,0xD5A0,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); +DEFINE_GUID(GUID_SysKeyboard,0x6F1D2B61,0xD5A0,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); +DEFINE_GUID(GUID_Joystick ,0x6F1D2B70,0xD5A0,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); +DEFINE_GUID(GUID_SysMouseEm, 0x6F1D2B80,0xD5A0,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); +DEFINE_GUID(GUID_SysMouseEm2,0x6F1D2B81,0xD5A0,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); +DEFINE_GUID(GUID_SysKeyboardEm, 0x6F1D2B82,0xD5A0,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); +DEFINE_GUID(GUID_SysKeyboardEm2,0x6F1D2B83,0xD5A0,0x11CF,0xBF,0xC7,0x44,0x45,0x53,0x54,0x00,0x00); + +/**************************************************************************** + * + * Predefined force feedback effects + * + ****************************************************************************/ + +DEFINE_GUID(GUID_ConstantForce, 0x13541C20,0x8E33,0x11D0,0x9A,0xD0,0x00,0xA0,0xC9,0xA0,0x6E,0x35); +DEFINE_GUID(GUID_RampForce, 0x13541C21,0x8E33,0x11D0,0x9A,0xD0,0x00,0xA0,0xC9,0xA0,0x6E,0x35); +DEFINE_GUID(GUID_Square, 0x13541C22,0x8E33,0x11D0,0x9A,0xD0,0x00,0xA0,0xC9,0xA0,0x6E,0x35); +DEFINE_GUID(GUID_Sine, 0x13541C23,0x8E33,0x11D0,0x9A,0xD0,0x00,0xA0,0xC9,0xA0,0x6E,0x35); +DEFINE_GUID(GUID_Triangle, 0x13541C24,0x8E33,0x11D0,0x9A,0xD0,0x00,0xA0,0xC9,0xA0,0x6E,0x35); +DEFINE_GUID(GUID_SawtoothUp, 0x13541C25,0x8E33,0x11D0,0x9A,0xD0,0x00,0xA0,0xC9,0xA0,0x6E,0x35); +DEFINE_GUID(GUID_SawtoothDown, 0x13541C26,0x8E33,0x11D0,0x9A,0xD0,0x00,0xA0,0xC9,0xA0,0x6E,0x35); +DEFINE_GUID(GUID_Spring, 0x13541C27,0x8E33,0x11D0,0x9A,0xD0,0x00,0xA0,0xC9,0xA0,0x6E,0x35); +DEFINE_GUID(GUID_Damper, 0x13541C28,0x8E33,0x11D0,0x9A,0xD0,0x00,0xA0,0xC9,0xA0,0x6E,0x35); +DEFINE_GUID(GUID_Inertia, 0x13541C29,0x8E33,0x11D0,0x9A,0xD0,0x00,0xA0,0xC9,0xA0,0x6E,0x35); +DEFINE_GUID(GUID_Friction, 0x13541C2A,0x8E33,0x11D0,0x9A,0xD0,0x00,0xA0,0xC9,0xA0,0x6E,0x35); +DEFINE_GUID(GUID_CustomForce, 0x13541C2B,0x8E33,0x11D0,0x9A,0xD0,0x00,0xA0,0xC9,0xA0,0x6E,0x35); + +#endif /* DIJ_RINGZERO */ + +/**************************************************************************** + * + * Interfaces and Structures... + * + ****************************************************************************/ + +#if(DIRECTINPUT_VERSION >= 0x0500) + +/**************************************************************************** + * + * IDirectInputEffect + * + ****************************************************************************/ + +#define DIEFT_ALL 0x00000000 + +#define DIEFT_CONSTANTFORCE 0x00000001 +#define DIEFT_RAMPFORCE 0x00000002 +#define DIEFT_PERIODIC 0x00000003 +#define DIEFT_CONDITION 0x00000004 +#define DIEFT_CUSTOMFORCE 0x00000005 +#define DIEFT_HARDWARE 0x000000FF +#define DIEFT_FFATTACK 0x00000200 +#define DIEFT_FFFADE 0x00000400 +#define DIEFT_SATURATION 0x00000800 +#define DIEFT_POSNEGCOEFFICIENTS 0x00001000 +#define DIEFT_POSNEGSATURATION 0x00002000 +#define DIEFT_DEADBAND 0x00004000 +#define DIEFT_STARTDELAY 0x00008000 +#define DIEFT_GETTYPE(n) LOBYTE(n) + +#define DI_DEGREES 100 +#define DI_FFNOMINALMAX 10000 +#define DI_SECONDS 1000000 + +typedef struct DICONSTANTFORCE { + LONG lMagnitude; +} DICONSTANTFORCE, *LPDICONSTANTFORCE; +typedef const DICONSTANTFORCE *LPCDICONSTANTFORCE; + +typedef struct DIRAMPFORCE { + LONG lStart; + LONG lEnd; +} DIRAMPFORCE, *LPDIRAMPFORCE; +typedef const DIRAMPFORCE *LPCDIRAMPFORCE; + +typedef struct DIPERIODIC { + DWORD dwMagnitude; + LONG lOffset; + DWORD dwPhase; + DWORD dwPeriod; +} DIPERIODIC, *LPDIPERIODIC; +typedef const DIPERIODIC *LPCDIPERIODIC; + +typedef struct DICONDITION { + LONG lOffset; + LONG lPositiveCoefficient; + LONG lNegativeCoefficient; + DWORD dwPositiveSaturation; + DWORD dwNegativeSaturation; + LONG lDeadBand; +} DICONDITION, *LPDICONDITION; +typedef const DICONDITION *LPCDICONDITION; + +typedef struct DICUSTOMFORCE { + DWORD cChannels; + DWORD dwSamplePeriod; + DWORD cSamples; + LPLONG rglForceData; +} DICUSTOMFORCE, *LPDICUSTOMFORCE; +typedef const DICUSTOMFORCE *LPCDICUSTOMFORCE; + + +typedef struct DIENVELOPE { + DWORD dwSize; /* sizeof(DIENVELOPE) */ + DWORD dwAttackLevel; + DWORD dwAttackTime; /* Microseconds */ + DWORD dwFadeLevel; + DWORD dwFadeTime; /* Microseconds */ +} DIENVELOPE, *LPDIENVELOPE; +typedef const DIENVELOPE *LPCDIENVELOPE; + + +/* This structure is defined for DirectX 5.0 compatibility */ +typedef struct DIEFFECT_DX5 { + DWORD dwSize; /* sizeof(DIEFFECT_DX5) */ + DWORD dwFlags; /* DIEFF_* */ + DWORD dwDuration; /* Microseconds */ + DWORD dwSamplePeriod; /* Microseconds */ + DWORD dwGain; + DWORD dwTriggerButton; /* or DIEB_NOTRIGGER */ + DWORD dwTriggerRepeatInterval; /* Microseconds */ + DWORD cAxes; /* Number of axes */ + LPDWORD rgdwAxes; /* Array of axes */ + LPLONG rglDirection; /* Array of directions */ + LPDIENVELOPE lpEnvelope; /* Optional */ + DWORD cbTypeSpecificParams; /* Size of params */ + LPVOID lpvTypeSpecificParams; /* Pointer to params */ +} DIEFFECT_DX5, *LPDIEFFECT_DX5; +typedef const DIEFFECT_DX5 *LPCDIEFFECT_DX5; + +typedef struct DIEFFECT { + DWORD dwSize; /* sizeof(DIEFFECT) */ + DWORD dwFlags; /* DIEFF_* */ + DWORD dwDuration; /* Microseconds */ + DWORD dwSamplePeriod; /* Microseconds */ + DWORD dwGain; + DWORD dwTriggerButton; /* or DIEB_NOTRIGGER */ + DWORD dwTriggerRepeatInterval; /* Microseconds */ + DWORD cAxes; /* Number of axes */ + LPDWORD rgdwAxes; /* Array of axes */ + LPLONG rglDirection; /* Array of directions */ + LPDIENVELOPE lpEnvelope; /* Optional */ + DWORD cbTypeSpecificParams; /* Size of params */ + LPVOID lpvTypeSpecificParams; /* Pointer to params */ +#if(DIRECTINPUT_VERSION >= 0x0600) + DWORD dwStartDelay; /* Microseconds */ +#endif /* DIRECTINPUT_VERSION >= 0x0600 */ +} DIEFFECT, *LPDIEFFECT; +typedef DIEFFECT DIEFFECT_DX6; +typedef LPDIEFFECT LPDIEFFECT_DX6; +typedef const DIEFFECT *LPCDIEFFECT; + + +#if(DIRECTINPUT_VERSION >= 0x0700) +#ifndef DIJ_RINGZERO +typedef struct DIFILEEFFECT{ + DWORD dwSize; + GUID GuidEffect; + LPCDIEFFECT lpDiEffect; + CHAR szFriendlyName[MAX_PATH]; +}DIFILEEFFECT, *LPDIFILEEFFECT; +typedef const DIFILEEFFECT *LPCDIFILEEFFECT; +typedef BOOL (FAR PASCAL * LPDIENUMEFFECTSINFILECALLBACK)(LPCDIFILEEFFECT , LPVOID); +#endif /* DIJ_RINGZERO */ +#endif /* DIRECTINPUT_VERSION >= 0x0700 */ + +#define DIEFF_OBJECTIDS 0x00000001 +#define DIEFF_OBJECTOFFSETS 0x00000002 +#define DIEFF_CARTESIAN 0x00000010 +#define DIEFF_POLAR 0x00000020 +#define DIEFF_SPHERICAL 0x00000040 + +#define DIEP_DURATION 0x00000001 +#define DIEP_SAMPLEPERIOD 0x00000002 +#define DIEP_GAIN 0x00000004 +#define DIEP_TRIGGERBUTTON 0x00000008 +#define DIEP_TRIGGERREPEATINTERVAL 0x00000010 +#define DIEP_AXES 0x00000020 +#define DIEP_DIRECTION 0x00000040 +#define DIEP_ENVELOPE 0x00000080 +#define DIEP_TYPESPECIFICPARAMS 0x00000100 +#if(DIRECTINPUT_VERSION >= 0x0600) +#define DIEP_STARTDELAY 0x00000200 +#define DIEP_ALLPARAMS_DX5 0x000001FF +#define DIEP_ALLPARAMS 0x000003FF +#else /* DIRECTINPUT_VERSION < 0x0600 */ +#define DIEP_ALLPARAMS 0x000001FF +#endif /* DIRECTINPUT_VERSION < 0x0600 */ +#define DIEP_START 0x20000000 +#define DIEP_NORESTART 0x40000000 +#define DIEP_NODOWNLOAD 0x80000000 +#define DIEB_NOTRIGGER 0xFFFFFFFF + +#define DIES_SOLO 0x00000001 +#define DIES_NODOWNLOAD 0x80000000 + +#define DIEGES_PLAYING 0x00000001 +#define DIEGES_EMULATED 0x00000002 + +typedef struct DIEFFESCAPE { + DWORD dwSize; + DWORD dwCommand; + LPVOID lpvInBuffer; + DWORD cbInBuffer; + LPVOID lpvOutBuffer; + DWORD cbOutBuffer; +} DIEFFESCAPE, *LPDIEFFESCAPE; + +#ifndef DIJ_RINGZERO + +#undef INTERFACE +#define INTERFACE IDirectInputEffect + +DECLARE_INTERFACE_(IDirectInputEffect, IUnknown) +{ + /*** IUnknown methods ***/ + STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID * ppvObj) PURE; + STDMETHOD_(ULONG,AddRef)(THIS) PURE; + STDMETHOD_(ULONG,Release)(THIS) PURE; + + /*** IDirectInputEffect methods ***/ + STDMETHOD(Initialize)(THIS_ HINSTANCE,DWORD,REFGUID) PURE; + STDMETHOD(GetEffectGuid)(THIS_ LPGUID) PURE; + STDMETHOD(GetParameters)(THIS_ LPDIEFFECT,DWORD) PURE; + STDMETHOD(SetParameters)(THIS_ LPCDIEFFECT,DWORD) PURE; + STDMETHOD(Start)(THIS_ DWORD,DWORD) PURE; + STDMETHOD(Stop)(THIS) PURE; + STDMETHOD(GetEffectStatus)(THIS_ LPDWORD) PURE; + STDMETHOD(Download)(THIS) PURE; + STDMETHOD(Unload)(THIS) PURE; + STDMETHOD(Escape)(THIS_ LPDIEFFESCAPE) PURE; +}; + +typedef struct IDirectInputEffect *LPDIRECTINPUTEFFECT; + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectInputEffect_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) +#define IDirectInputEffect_AddRef(p) (p)->lpVtbl->AddRef(p) +#define IDirectInputEffect_Release(p) (p)->lpVtbl->Release(p) +#define IDirectInputEffect_Initialize(p,a,b,c) (p)->lpVtbl->Initialize(p,a,b,c) +#define IDirectInputEffect_GetEffectGuid(p,a) (p)->lpVtbl->GetEffectGuid(p,a) +#define IDirectInputEffect_GetParameters(p,a,b) (p)->lpVtbl->GetParameters(p,a,b) +#define IDirectInputEffect_SetParameters(p,a,b) (p)->lpVtbl->SetParameters(p,a,b) +#define IDirectInputEffect_Start(p,a,b) (p)->lpVtbl->Start(p,a,b) +#define IDirectInputEffect_Stop(p) (p)->lpVtbl->Stop(p) +#define IDirectInputEffect_GetEffectStatus(p,a) (p)->lpVtbl->GetEffectStatus(p,a) +#define IDirectInputEffect_Download(p) (p)->lpVtbl->Download(p) +#define IDirectInputEffect_Unload(p) (p)->lpVtbl->Unload(p) +#define IDirectInputEffect_Escape(p,a) (p)->lpVtbl->Escape(p,a) +#else +#define IDirectInputEffect_QueryInterface(p,a,b) (p)->QueryInterface(a,b) +#define IDirectInputEffect_AddRef(p) (p)->AddRef() +#define IDirectInputEffect_Release(p) (p)->Release() +#define IDirectInputEffect_Initialize(p,a,b,c) (p)->Initialize(a,b,c) +#define IDirectInputEffect_GetEffectGuid(p,a) (p)->GetEffectGuid(a) +#define IDirectInputEffect_GetParameters(p,a,b) (p)->GetParameters(a,b) +#define IDirectInputEffect_SetParameters(p,a,b) (p)->SetParameters(a,b) +#define IDirectInputEffect_Start(p,a,b) (p)->Start(a,b) +#define IDirectInputEffect_Stop(p) (p)->Stop() +#define IDirectInputEffect_GetEffectStatus(p,a) (p)->GetEffectStatus(a) +#define IDirectInputEffect_Download(p) (p)->Download() +#define IDirectInputEffect_Unload(p) (p)->Unload() +#define IDirectInputEffect_Escape(p,a) (p)->Escape(a) +#endif + +#endif /* DIJ_RINGZERO */ + +#endif /* DIRECTINPUT_VERSION >= 0x0500 */ + +/**************************************************************************** + * + * IDirectInputDevice + * + ****************************************************************************/ + +#if DIRECTINPUT_VERSION <= 0x700 +#define DIDEVTYPE_DEVICE 1 +#define DIDEVTYPE_MOUSE 2 +#define DIDEVTYPE_KEYBOARD 3 +#define DIDEVTYPE_JOYSTICK 4 + +#else +#define DI8DEVCLASS_ALL 0 +#define DI8DEVCLASS_DEVICE 1 +#define DI8DEVCLASS_POINTER 2 +#define DI8DEVCLASS_KEYBOARD 3 +#define DI8DEVCLASS_GAMECTRL 4 + +#define DI8DEVTYPE_DEVICE 0x11 +#define DI8DEVTYPE_MOUSE 0x12 +#define DI8DEVTYPE_KEYBOARD 0x13 +#define DI8DEVTYPE_JOYSTICK 0x14 +#define DI8DEVTYPE_GAMEPAD 0x15 +#define DI8DEVTYPE_DRIVING 0x16 +#define DI8DEVTYPE_FLIGHT 0x17 +#define DI8DEVTYPE_1STPERSON 0x18 +#define DI8DEVTYPE_DEVICECTRL 0x19 +#define DI8DEVTYPE_SCREENPOINTER 0x1A +#define DI8DEVTYPE_REMOTE 0x1B +#define DI8DEVTYPE_SUPPLEMENTAL 0x1C +#endif /* DIRECTINPUT_VERSION <= 0x700 */ + +#define DIDEVTYPE_HID 0x00010000 + +#if DIRECTINPUT_VERSION <= 0x700 +#define DIDEVTYPEMOUSE_UNKNOWN 1 +#define DIDEVTYPEMOUSE_TRADITIONAL 2 +#define DIDEVTYPEMOUSE_FINGERSTICK 3 +#define DIDEVTYPEMOUSE_TOUCHPAD 4 +#define DIDEVTYPEMOUSE_TRACKBALL 5 + +#define DIDEVTYPEKEYBOARD_UNKNOWN 0 +#define DIDEVTYPEKEYBOARD_PCXT 1 +#define DIDEVTYPEKEYBOARD_OLIVETTI 2 +#define DIDEVTYPEKEYBOARD_PCAT 3 +#define DIDEVTYPEKEYBOARD_PCENH 4 +#define DIDEVTYPEKEYBOARD_NOKIA1050 5 +#define DIDEVTYPEKEYBOARD_NOKIA9140 6 +#define DIDEVTYPEKEYBOARD_NEC98 7 +#define DIDEVTYPEKEYBOARD_NEC98LAPTOP 8 +#define DIDEVTYPEKEYBOARD_NEC98106 9 +#define DIDEVTYPEKEYBOARD_JAPAN106 10 +#define DIDEVTYPEKEYBOARD_JAPANAX 11 +#define DIDEVTYPEKEYBOARD_J3100 12 + +#define DIDEVTYPEJOYSTICK_UNKNOWN 1 +#define DIDEVTYPEJOYSTICK_TRADITIONAL 2 +#define DIDEVTYPEJOYSTICK_FLIGHTSTICK 3 +#define DIDEVTYPEJOYSTICK_GAMEPAD 4 +#define DIDEVTYPEJOYSTICK_RUDDER 5 +#define DIDEVTYPEJOYSTICK_WHEEL 6 +#define DIDEVTYPEJOYSTICK_HEADTRACKER 7 + +#else +#define DI8DEVTYPEMOUSE_UNKNOWN 1 +#define DI8DEVTYPEMOUSE_TRADITIONAL 2 +#define DI8DEVTYPEMOUSE_FINGERSTICK 3 +#define DI8DEVTYPEMOUSE_TOUCHPAD 4 +#define DI8DEVTYPEMOUSE_TRACKBALL 5 +#define DI8DEVTYPEMOUSE_ABSOLUTE 6 + +#define DI8DEVTYPEKEYBOARD_UNKNOWN 0 +#define DI8DEVTYPEKEYBOARD_PCXT 1 +#define DI8DEVTYPEKEYBOARD_OLIVETTI 2 +#define DI8DEVTYPEKEYBOARD_PCAT 3 +#define DI8DEVTYPEKEYBOARD_PCENH 4 +#define DI8DEVTYPEKEYBOARD_NOKIA1050 5 +#define DI8DEVTYPEKEYBOARD_NOKIA9140 6 +#define DI8DEVTYPEKEYBOARD_NEC98 7 +#define DI8DEVTYPEKEYBOARD_NEC98LAPTOP 8 +#define DI8DEVTYPEKEYBOARD_NEC98106 9 +#define DI8DEVTYPEKEYBOARD_JAPAN106 10 +#define DI8DEVTYPEKEYBOARD_JAPANAX 11 +#define DI8DEVTYPEKEYBOARD_J3100 12 + +#define DI8DEVTYPE_LIMITEDGAMESUBTYPE 1 + +#define DI8DEVTYPEJOYSTICK_LIMITED DI8DEVTYPE_LIMITEDGAMESUBTYPE +#define DI8DEVTYPEJOYSTICK_STANDARD 2 + +#define DI8DEVTYPEGAMEPAD_LIMITED DI8DEVTYPE_LIMITEDGAMESUBTYPE +#define DI8DEVTYPEGAMEPAD_STANDARD 2 +#define DI8DEVTYPEGAMEPAD_TILT 3 + +#define DI8DEVTYPEDRIVING_LIMITED DI8DEVTYPE_LIMITEDGAMESUBTYPE +#define DI8DEVTYPEDRIVING_COMBINEDPEDALS 2 +#define DI8DEVTYPEDRIVING_DUALPEDALS 3 +#define DI8DEVTYPEDRIVING_THREEPEDALS 4 +#define DI8DEVTYPEDRIVING_HANDHELD 5 + +#define DI8DEVTYPEFLIGHT_LIMITED DI8DEVTYPE_LIMITEDGAMESUBTYPE +#define DI8DEVTYPEFLIGHT_STICK 2 +#define DI8DEVTYPEFLIGHT_YOKE 3 +#define DI8DEVTYPEFLIGHT_RC 4 + +#define DI8DEVTYPE1STPERSON_LIMITED DI8DEVTYPE_LIMITEDGAMESUBTYPE +#define DI8DEVTYPE1STPERSON_UNKNOWN 2 +#define DI8DEVTYPE1STPERSON_SIXDOF 3 +#define DI8DEVTYPE1STPERSON_SHOOTER 4 + +#define DI8DEVTYPESCREENPTR_UNKNOWN 2 +#define DI8DEVTYPESCREENPTR_LIGHTGUN 3 +#define DI8DEVTYPESCREENPTR_LIGHTPEN 4 +#define DI8DEVTYPESCREENPTR_TOUCH 5 + +#define DI8DEVTYPEREMOTE_UNKNOWN 2 + +#define DI8DEVTYPEDEVICECTRL_UNKNOWN 2 +#define DI8DEVTYPEDEVICECTRL_COMMSSELECTION 3 +#define DI8DEVTYPEDEVICECTRL_COMMSSELECTION_HARDWIRED 4 + +#define DI8DEVTYPESUPPLEMENTAL_UNKNOWN 2 +#define DI8DEVTYPESUPPLEMENTAL_2NDHANDCONTROLLER 3 +#define DI8DEVTYPESUPPLEMENTAL_HEADTRACKER 4 +#define DI8DEVTYPESUPPLEMENTAL_HANDTRACKER 5 +#define DI8DEVTYPESUPPLEMENTAL_SHIFTSTICKGATE 6 +#define DI8DEVTYPESUPPLEMENTAL_SHIFTER 7 +#define DI8DEVTYPESUPPLEMENTAL_THROTTLE 8 +#define DI8DEVTYPESUPPLEMENTAL_SPLITTHROTTLE 9 +#define DI8DEVTYPESUPPLEMENTAL_COMBINEDPEDALS 10 +#define DI8DEVTYPESUPPLEMENTAL_DUALPEDALS 11 +#define DI8DEVTYPESUPPLEMENTAL_THREEPEDALS 12 +#define DI8DEVTYPESUPPLEMENTAL_RUDDERPEDALS 13 +#endif /* DIRECTINPUT_VERSION <= 0x700 */ + +#define GET_DIDEVICE_TYPE(dwDevType) LOBYTE(dwDevType) +#define GET_DIDEVICE_SUBTYPE(dwDevType) HIBYTE(dwDevType) + +#if(DIRECTINPUT_VERSION >= 0x0500) +/* This structure is defined for DirectX 3.0 compatibility */ +typedef struct DIDEVCAPS_DX3 { + DWORD dwSize; + DWORD dwFlags; + DWORD dwDevType; + DWORD dwAxes; + DWORD dwButtons; + DWORD dwPOVs; +} DIDEVCAPS_DX3, *LPDIDEVCAPS_DX3; +#endif /* DIRECTINPUT_VERSION >= 0x0500 */ + +typedef struct DIDEVCAPS { + DWORD dwSize; + DWORD dwFlags; + DWORD dwDevType; + DWORD dwAxes; + DWORD dwButtons; + DWORD dwPOVs; +#if(DIRECTINPUT_VERSION >= 0x0500) + DWORD dwFFSamplePeriod; + DWORD dwFFMinTimeResolution; + DWORD dwFirmwareRevision; + DWORD dwHardwareRevision; + DWORD dwFFDriverVersion; +#endif /* DIRECTINPUT_VERSION >= 0x0500 */ +} DIDEVCAPS, *LPDIDEVCAPS; + +#define DIDC_ATTACHED 0x00000001 +#define DIDC_POLLEDDEVICE 0x00000002 +#define DIDC_EMULATED 0x00000004 +#define DIDC_POLLEDDATAFORMAT 0x00000008 +#if(DIRECTINPUT_VERSION >= 0x0500) +#define DIDC_FORCEFEEDBACK 0x00000100 +#define DIDC_FFATTACK 0x00000200 +#define DIDC_FFFADE 0x00000400 +#define DIDC_SATURATION 0x00000800 +#define DIDC_POSNEGCOEFFICIENTS 0x00001000 +#define DIDC_POSNEGSATURATION 0x00002000 +#define DIDC_DEADBAND 0x00004000 +#endif /* DIRECTINPUT_VERSION >= 0x0500 */ +#define DIDC_STARTDELAY 0x00008000 +#if(DIRECTINPUT_VERSION >= 0x050a) +#define DIDC_ALIAS 0x00010000 +#define DIDC_PHANTOM 0x00020000 +#endif /* DIRECTINPUT_VERSION >= 0x050a */ +#if(DIRECTINPUT_VERSION >= 0x0800) +#define DIDC_HIDDEN 0x00040000 +#endif /* DIRECTINPUT_VERSION >= 0x0800 */ + +#define DIDFT_ALL 0x00000000 + +#define DIDFT_RELAXIS 0x00000001 +#define DIDFT_ABSAXIS 0x00000002 +#define DIDFT_AXIS 0x00000003 + +#define DIDFT_PSHBUTTON 0x00000004 +#define DIDFT_TGLBUTTON 0x00000008 +#define DIDFT_BUTTON 0x0000000C + +#define DIDFT_POV 0x00000010 +#define DIDFT_COLLECTION 0x00000040 +#define DIDFT_NODATA 0x00000080 + +#define DIDFT_ANYINSTANCE 0x00FFFF00 +#define DIDFT_INSTANCEMASK DIDFT_ANYINSTANCE +#define DIDFT_MAKEINSTANCE(n) ((WORD)(n) << 8) +#define DIDFT_GETTYPE(n) LOBYTE(n) +#define DIDFT_GETINSTANCE(n) LOWORD((n) >> 8) +#define DIDFT_FFACTUATOR 0x01000000 +#define DIDFT_FFEFFECTTRIGGER 0x02000000 +#if(DIRECTINPUT_VERSION >= 0x050a) +#define DIDFT_OUTPUT 0x10000000 +#define DIDFT_VENDORDEFINED 0x04000000 +#define DIDFT_ALIAS 0x08000000 +#endif /* DIRECTINPUT_VERSION >= 0x050a */ +#ifndef DIDFT_OPTIONAL +#define DIDFT_OPTIONAL 0x80000000 +#endif + +#define DIDFT_ENUMCOLLECTION(n) ((WORD)(n) << 8) +#define DIDFT_NOCOLLECTION 0x00FFFF00 + +#ifndef DIJ_RINGZERO + +typedef struct _DIOBJECTDATAFORMAT { + const GUID *pguid; + DWORD dwOfs; + DWORD dwType; + DWORD dwFlags; +} DIOBJECTDATAFORMAT, *LPDIOBJECTDATAFORMAT; +typedef const DIOBJECTDATAFORMAT *LPCDIOBJECTDATAFORMAT; + +typedef struct _DIDATAFORMAT { + DWORD dwSize; + DWORD dwObjSize; + DWORD dwFlags; + DWORD dwDataSize; + DWORD dwNumObjs; + LPDIOBJECTDATAFORMAT rgodf; +} DIDATAFORMAT, *LPDIDATAFORMAT; +typedef const DIDATAFORMAT *LPCDIDATAFORMAT; + +#define DIDF_ABSAXIS 0x00000001 +#define DIDF_RELAXIS 0x00000002 + +#ifdef __cplusplus +extern "C" { +#endif +extern const DIDATAFORMAT c_dfDIMouse; + +#if(DIRECTINPUT_VERSION >= 0x0700) +extern const DIDATAFORMAT c_dfDIMouse2; +#endif /* DIRECTINPUT_VERSION >= 0x0700 */ + +extern const DIDATAFORMAT c_dfDIKeyboard; + +#if(DIRECTINPUT_VERSION >= 0x0500) +extern const DIDATAFORMAT c_dfDIJoystick; +extern const DIDATAFORMAT c_dfDIJoystick2; +#endif /* DIRECTINPUT_VERSION >= 0x0500 */ + +#ifdef __cplusplus +}; +#endif + + +#if DIRECTINPUT_VERSION > 0x0700 + +typedef struct _DIACTIONA { + UINT_PTR uAppData; + DWORD dwSemantic; + OPTIONAL DWORD dwFlags; + OPTIONAL union { + LPCSTR lptszActionName; + UINT uResIdString; + }; + OPTIONAL GUID guidInstance; + OPTIONAL DWORD dwObjID; + OPTIONAL DWORD dwHow; +} DIACTIONA, *LPDIACTIONA ; +typedef struct _DIACTIONW { + UINT_PTR uAppData; + DWORD dwSemantic; + OPTIONAL DWORD dwFlags; + OPTIONAL union { + LPCWSTR lptszActionName; + UINT uResIdString; + }; + OPTIONAL GUID guidInstance; + OPTIONAL DWORD dwObjID; + OPTIONAL DWORD dwHow; +} DIACTIONW, *LPDIACTIONW ; +#ifdef UNICODE +typedef DIACTIONW DIACTION; +typedef LPDIACTIONW LPDIACTION; +#else +typedef DIACTIONA DIACTION; +typedef LPDIACTIONA LPDIACTION; +#endif // UNICODE + +typedef const DIACTIONA *LPCDIACTIONA; +typedef const DIACTIONW *LPCDIACTIONW; +#ifdef UNICODE +typedef DIACTIONW DIACTION; +typedef LPCDIACTIONW LPCDIACTION; +#else +typedef DIACTIONA DIACTION; +typedef LPCDIACTIONA LPCDIACTION; +#endif // UNICODE +typedef const DIACTION *LPCDIACTION; + + +#define DIA_FORCEFEEDBACK 0x00000001 +#define DIA_APPMAPPED 0x00000002 +#define DIA_APPNOMAP 0x00000004 +#define DIA_NORANGE 0x00000008 +#define DIA_APPFIXED 0x00000010 + +#define DIAH_UNMAPPED 0x00000000 +#define DIAH_USERCONFIG 0x00000001 +#define DIAH_APPREQUESTED 0x00000002 +#define DIAH_HWAPP 0x00000004 +#define DIAH_HWDEFAULT 0x00000008 +#define DIAH_DEFAULT 0x00000020 +#define DIAH_ERROR 0x80000000 + +typedef struct _DIACTIONFORMATA { + DWORD dwSize; + DWORD dwActionSize; + DWORD dwDataSize; + DWORD dwNumActions; + LPDIACTIONA rgoAction; + GUID guidActionMap; + DWORD dwGenre; + DWORD dwBufferSize; + OPTIONAL LONG lAxisMin; + OPTIONAL LONG lAxisMax; + OPTIONAL HINSTANCE hInstString; + FILETIME ftTimeStamp; + DWORD dwCRC; + CHAR tszActionMap[MAX_PATH]; +} DIACTIONFORMATA, *LPDIACTIONFORMATA; +typedef struct _DIACTIONFORMATW { + DWORD dwSize; + DWORD dwActionSize; + DWORD dwDataSize; + DWORD dwNumActions; + LPDIACTIONW rgoAction; + GUID guidActionMap; + DWORD dwGenre; + DWORD dwBufferSize; + OPTIONAL LONG lAxisMin; + OPTIONAL LONG lAxisMax; + OPTIONAL HINSTANCE hInstString; + FILETIME ftTimeStamp; + DWORD dwCRC; + WCHAR tszActionMap[MAX_PATH]; +} DIACTIONFORMATW, *LPDIACTIONFORMATW; +#ifdef UNICODE +typedef DIACTIONFORMATW DIACTIONFORMAT; +typedef LPDIACTIONFORMATW LPDIACTIONFORMAT; +#else +typedef DIACTIONFORMATA DIACTIONFORMAT; +typedef LPDIACTIONFORMATA LPDIACTIONFORMAT; +#endif // UNICODE +typedef const DIACTIONFORMATA *LPCDIACTIONFORMATA; +typedef const DIACTIONFORMATW *LPCDIACTIONFORMATW; +#ifdef UNICODE +typedef DIACTIONFORMATW DIACTIONFORMAT; +typedef LPCDIACTIONFORMATW LPCDIACTIONFORMAT; +#else +typedef DIACTIONFORMATA DIACTIONFORMAT; +typedef LPCDIACTIONFORMATA LPCDIACTIONFORMAT; +#endif // UNICODE +typedef const DIACTIONFORMAT *LPCDIACTIONFORMAT; + +#define DIAFTS_NEWDEVICELOW 0xFFFFFFFF +#define DIAFTS_NEWDEVICEHIGH 0xFFFFFFFF +#define DIAFTS_UNUSEDDEVICELOW 0x00000000 +#define DIAFTS_UNUSEDDEVICEHIGH 0x00000000 + +#define DIDBAM_DEFAULT 0x00000000 +#define DIDBAM_PRESERVE 0x00000001 +#define DIDBAM_INITIALIZE 0x00000002 +#define DIDBAM_HWDEFAULTS 0x00000004 + +#define DIDSAM_DEFAULT 0x00000000 +#define DIDSAM_NOUSER 0x00000001 +#define DIDSAM_FORCESAVE 0x00000002 + +#define DICD_DEFAULT 0x00000000 +#define DICD_EDIT 0x00000001 + +/* + * The following definition is normally defined in d3dtypes.h + */ +#ifndef D3DCOLOR_DEFINED +typedef DWORD D3DCOLOR; +#define D3DCOLOR_DEFINED +#endif + +typedef struct _DICOLORSET{ + DWORD dwSize; + D3DCOLOR cTextFore; + D3DCOLOR cTextHighlight; + D3DCOLOR cCalloutLine; + D3DCOLOR cCalloutHighlight; + D3DCOLOR cBorder; + D3DCOLOR cControlFill; + D3DCOLOR cHighlightFill; + D3DCOLOR cAreaFill; +} DICOLORSET, *LPDICOLORSET; +typedef const DICOLORSET *LPCDICOLORSET; + + +typedef struct _DICONFIGUREDEVICESPARAMSA{ + DWORD dwSize; + DWORD dwcUsers; + LPSTR lptszUserNames; + DWORD dwcFormats; + LPDIACTIONFORMATA lprgFormats; + HWND hwnd; + DICOLORSET dics; + IUnknown FAR * lpUnkDDSTarget; +} DICONFIGUREDEVICESPARAMSA, *LPDICONFIGUREDEVICESPARAMSA; +typedef struct _DICONFIGUREDEVICESPARAMSW{ + DWORD dwSize; + DWORD dwcUsers; + LPWSTR lptszUserNames; + DWORD dwcFormats; + LPDIACTIONFORMATW lprgFormats; + HWND hwnd; + DICOLORSET dics; + IUnknown FAR * lpUnkDDSTarget; +} DICONFIGUREDEVICESPARAMSW, *LPDICONFIGUREDEVICESPARAMSW; +#ifdef UNICODE +typedef DICONFIGUREDEVICESPARAMSW DICONFIGUREDEVICESPARAMS; +typedef LPDICONFIGUREDEVICESPARAMSW LPDICONFIGUREDEVICESPARAMS; +#else +typedef DICONFIGUREDEVICESPARAMSA DICONFIGUREDEVICESPARAMS; +typedef LPDICONFIGUREDEVICESPARAMSA LPDICONFIGUREDEVICESPARAMS; +#endif // UNICODE +typedef const DICONFIGUREDEVICESPARAMSA *LPCDICONFIGUREDEVICESPARAMSA; +typedef const DICONFIGUREDEVICESPARAMSW *LPCDICONFIGUREDEVICESPARAMSW; +#ifdef UNICODE +typedef DICONFIGUREDEVICESPARAMSW DICONFIGUREDEVICESPARAMS; +typedef LPCDICONFIGUREDEVICESPARAMSW LPCDICONFIGUREDEVICESPARAMS; +#else +typedef DICONFIGUREDEVICESPARAMSA DICONFIGUREDEVICESPARAMS; +typedef LPCDICONFIGUREDEVICESPARAMSA LPCDICONFIGUREDEVICESPARAMS; +#endif // UNICODE +typedef const DICONFIGUREDEVICESPARAMS *LPCDICONFIGUREDEVICESPARAMS; + + +#define DIDIFT_CONFIGURATION 0x00000001 +#define DIDIFT_OVERLAY 0x00000002 + +#define DIDAL_CENTERED 0x00000000 +#define DIDAL_LEFTALIGNED 0x00000001 +#define DIDAL_RIGHTALIGNED 0x00000002 +#define DIDAL_MIDDLE 0x00000000 +#define DIDAL_TOPALIGNED 0x00000004 +#define DIDAL_BOTTOMALIGNED 0x00000008 + +typedef struct _DIDEVICEIMAGEINFOA { + CHAR tszImagePath[MAX_PATH]; + DWORD dwFlags; + // These are valid if DIDIFT_OVERLAY is present in dwFlags. + DWORD dwViewID; + RECT rcOverlay; + DWORD dwObjID; + DWORD dwcValidPts; + POINT rgptCalloutLine[5]; + RECT rcCalloutRect; + DWORD dwTextAlign; +} DIDEVICEIMAGEINFOA, *LPDIDEVICEIMAGEINFOA; +typedef struct _DIDEVICEIMAGEINFOW { + WCHAR tszImagePath[MAX_PATH]; + DWORD dwFlags; + // These are valid if DIDIFT_OVERLAY is present in dwFlags. + DWORD dwViewID; + RECT rcOverlay; + DWORD dwObjID; + DWORD dwcValidPts; + POINT rgptCalloutLine[5]; + RECT rcCalloutRect; + DWORD dwTextAlign; +} DIDEVICEIMAGEINFOW, *LPDIDEVICEIMAGEINFOW; +#ifdef UNICODE +typedef DIDEVICEIMAGEINFOW DIDEVICEIMAGEINFO; +typedef LPDIDEVICEIMAGEINFOW LPDIDEVICEIMAGEINFO; +#else +typedef DIDEVICEIMAGEINFOA DIDEVICEIMAGEINFO; +typedef LPDIDEVICEIMAGEINFOA LPDIDEVICEIMAGEINFO; +#endif // UNICODE +typedef const DIDEVICEIMAGEINFOA *LPCDIDEVICEIMAGEINFOA; +typedef const DIDEVICEIMAGEINFOW *LPCDIDEVICEIMAGEINFOW; +#ifdef UNICODE +typedef DIDEVICEIMAGEINFOW DIDEVICEIMAGEINFO; +typedef LPCDIDEVICEIMAGEINFOW LPCDIDEVICEIMAGEINFO; +#else +typedef DIDEVICEIMAGEINFOA DIDEVICEIMAGEINFO; +typedef LPCDIDEVICEIMAGEINFOA LPCDIDEVICEIMAGEINFO; +#endif // UNICODE +typedef const DIDEVICEIMAGEINFO *LPCDIDEVICEIMAGEINFO; + +typedef struct _DIDEVICEIMAGEINFOHEADERA { + DWORD dwSize; + DWORD dwSizeImageInfo; + DWORD dwcViews; + DWORD dwcButtons; + DWORD dwcAxes; + DWORD dwcPOVs; + DWORD dwBufferSize; + DWORD dwBufferUsed; + LPDIDEVICEIMAGEINFOA lprgImageInfoArray; +} DIDEVICEIMAGEINFOHEADERA, *LPDIDEVICEIMAGEINFOHEADERA; +typedef struct _DIDEVICEIMAGEINFOHEADERW { + DWORD dwSize; + DWORD dwSizeImageInfo; + DWORD dwcViews; + DWORD dwcButtons; + DWORD dwcAxes; + DWORD dwcPOVs; + DWORD dwBufferSize; + DWORD dwBufferUsed; + LPDIDEVICEIMAGEINFOW lprgImageInfoArray; +} DIDEVICEIMAGEINFOHEADERW, *LPDIDEVICEIMAGEINFOHEADERW; +#ifdef UNICODE +typedef DIDEVICEIMAGEINFOHEADERW DIDEVICEIMAGEINFOHEADER; +typedef LPDIDEVICEIMAGEINFOHEADERW LPDIDEVICEIMAGEINFOHEADER; +#else +typedef DIDEVICEIMAGEINFOHEADERA DIDEVICEIMAGEINFOHEADER; +typedef LPDIDEVICEIMAGEINFOHEADERA LPDIDEVICEIMAGEINFOHEADER; +#endif // UNICODE +typedef const DIDEVICEIMAGEINFOHEADERA *LPCDIDEVICEIMAGEINFOHEADERA; +typedef const DIDEVICEIMAGEINFOHEADERW *LPCDIDEVICEIMAGEINFOHEADERW; +#ifdef UNICODE +typedef DIDEVICEIMAGEINFOHEADERW DIDEVICEIMAGEINFOHEADER; +typedef LPCDIDEVICEIMAGEINFOHEADERW LPCDIDEVICEIMAGEINFOHEADER; +#else +typedef DIDEVICEIMAGEINFOHEADERA DIDEVICEIMAGEINFOHEADER; +typedef LPCDIDEVICEIMAGEINFOHEADERA LPCDIDEVICEIMAGEINFOHEADER; +#endif // UNICODE +typedef const DIDEVICEIMAGEINFOHEADER *LPCDIDEVICEIMAGEINFOHEADER; + +#endif /* DIRECTINPUT_VERSION > 0x0700 */ + +#if(DIRECTINPUT_VERSION >= 0x0500) +/* These structures are defined for DirectX 3.0 compatibility */ + +typedef struct DIDEVICEOBJECTINSTANCE_DX3A { + DWORD dwSize; + GUID guidType; + DWORD dwOfs; + DWORD dwType; + DWORD dwFlags; + CHAR tszName[MAX_PATH]; +} DIDEVICEOBJECTINSTANCE_DX3A, *LPDIDEVICEOBJECTINSTANCE_DX3A; +typedef struct DIDEVICEOBJECTINSTANCE_DX3W { + DWORD dwSize; + GUID guidType; + DWORD dwOfs; + DWORD dwType; + DWORD dwFlags; + WCHAR tszName[MAX_PATH]; +} DIDEVICEOBJECTINSTANCE_DX3W, *LPDIDEVICEOBJECTINSTANCE_DX3W; +#ifdef UNICODE +typedef DIDEVICEOBJECTINSTANCE_DX3W DIDEVICEOBJECTINSTANCE_DX3; +typedef LPDIDEVICEOBJECTINSTANCE_DX3W LPDIDEVICEOBJECTINSTANCE_DX3; +#else +typedef DIDEVICEOBJECTINSTANCE_DX3A DIDEVICEOBJECTINSTANCE_DX3; +typedef LPDIDEVICEOBJECTINSTANCE_DX3A LPDIDEVICEOBJECTINSTANCE_DX3; +#endif // UNICODE +typedef const DIDEVICEOBJECTINSTANCE_DX3A *LPCDIDEVICEOBJECTINSTANCE_DX3A; +typedef const DIDEVICEOBJECTINSTANCE_DX3W *LPCDIDEVICEOBJECTINSTANCE_DX3W; +typedef const DIDEVICEOBJECTINSTANCE_DX3 *LPCDIDEVICEOBJECTINSTANCE_DX3; +#endif /* DIRECTINPUT_VERSION >= 0x0500 */ + +typedef struct DIDEVICEOBJECTINSTANCEA { + DWORD dwSize; + GUID guidType; + DWORD dwOfs; + DWORD dwType; + DWORD dwFlags; + CHAR tszName[MAX_PATH]; +#if(DIRECTINPUT_VERSION >= 0x0500) + DWORD dwFFMaxForce; + DWORD dwFFForceResolution; + WORD wCollectionNumber; + WORD wDesignatorIndex; + WORD wUsagePage; + WORD wUsage; + DWORD dwDimension; + WORD wExponent; + WORD wReportId; +#endif /* DIRECTINPUT_VERSION >= 0x0500 */ +} DIDEVICEOBJECTINSTANCEA, *LPDIDEVICEOBJECTINSTANCEA; +typedef struct DIDEVICEOBJECTINSTANCEW { + DWORD dwSize; + GUID guidType; + DWORD dwOfs; + DWORD dwType; + DWORD dwFlags; + WCHAR tszName[MAX_PATH]; +#if(DIRECTINPUT_VERSION >= 0x0500) + DWORD dwFFMaxForce; + DWORD dwFFForceResolution; + WORD wCollectionNumber; + WORD wDesignatorIndex; + WORD wUsagePage; + WORD wUsage; + DWORD dwDimension; + WORD wExponent; + WORD wReportId; +#endif /* DIRECTINPUT_VERSION >= 0x0500 */ +} DIDEVICEOBJECTINSTANCEW, *LPDIDEVICEOBJECTINSTANCEW; +#ifdef UNICODE +typedef DIDEVICEOBJECTINSTANCEW DIDEVICEOBJECTINSTANCE; +typedef LPDIDEVICEOBJECTINSTANCEW LPDIDEVICEOBJECTINSTANCE; +#else +typedef DIDEVICEOBJECTINSTANCEA DIDEVICEOBJECTINSTANCE; +typedef LPDIDEVICEOBJECTINSTANCEA LPDIDEVICEOBJECTINSTANCE; +#endif // UNICODE +typedef const DIDEVICEOBJECTINSTANCEA *LPCDIDEVICEOBJECTINSTANCEA; +typedef const DIDEVICEOBJECTINSTANCEW *LPCDIDEVICEOBJECTINSTANCEW; +typedef const DIDEVICEOBJECTINSTANCE *LPCDIDEVICEOBJECTINSTANCE; + +typedef BOOL (FAR PASCAL * LPDIENUMDEVICEOBJECTSCALLBACKA)(LPCDIDEVICEOBJECTINSTANCEA, LPVOID); +typedef BOOL (FAR PASCAL * LPDIENUMDEVICEOBJECTSCALLBACKW)(LPCDIDEVICEOBJECTINSTANCEW, LPVOID); +#ifdef UNICODE +#define LPDIENUMDEVICEOBJECTSCALLBACK LPDIENUMDEVICEOBJECTSCALLBACKW +#else +#define LPDIENUMDEVICEOBJECTSCALLBACK LPDIENUMDEVICEOBJECTSCALLBACKA +#endif // !UNICODE + +#if(DIRECTINPUT_VERSION >= 0x0500) +#define DIDOI_FFACTUATOR 0x00000001 +#define DIDOI_FFEFFECTTRIGGER 0x00000002 +#define DIDOI_POLLED 0x00008000 +#define DIDOI_ASPECTPOSITION 0x00000100 +#define DIDOI_ASPECTVELOCITY 0x00000200 +#define DIDOI_ASPECTACCEL 0x00000300 +#define DIDOI_ASPECTFORCE 0x00000400 +#define DIDOI_ASPECTMASK 0x00000F00 +#endif /* DIRECTINPUT_VERSION >= 0x0500 */ +#if(DIRECTINPUT_VERSION >= 0x050a) +#define DIDOI_GUIDISUSAGE 0x00010000 +#endif /* DIRECTINPUT_VERSION >= 0x050a */ + +typedef struct DIPROPHEADER { + DWORD dwSize; + DWORD dwHeaderSize; + DWORD dwObj; + DWORD dwHow; +} DIPROPHEADER, *LPDIPROPHEADER; +typedef const DIPROPHEADER *LPCDIPROPHEADER; + +#define DIPH_DEVICE 0 +#define DIPH_BYOFFSET 1 +#define DIPH_BYID 2 +#if(DIRECTINPUT_VERSION >= 0x050a) +#define DIPH_BYUSAGE 3 +#endif /* DIRECTINPUT_VERSION >= 0x050a */ + +#if(DIRECTINPUT_VERSION >= 0x050a) +#define DIMAKEUSAGEDWORD(UsagePage, Usage) \ + (DWORD)MAKELONG(Usage, UsagePage) +#endif /* DIRECTINPUT_VERSION >= 0x050a */ + +typedef struct DIPROPDWORD { + DIPROPHEADER diph; + DWORD dwData; +} DIPROPDWORD, *LPDIPROPDWORD; +typedef const DIPROPDWORD *LPCDIPROPDWORD; + +#if(DIRECTINPUT_VERSION >= 0x0800) +typedef struct DIPROPPOINTER { + DIPROPHEADER diph; + UINT_PTR uData; +} DIPROPPOINTER, *LPDIPROPPOINTER; +typedef const DIPROPPOINTER *LPCDIPROPPOINTER; +#endif /* DIRECTINPUT_VERSION >= 0x0800 */ + +typedef struct DIPROPRANGE { + DIPROPHEADER diph; + LONG lMin; + LONG lMax; +} DIPROPRANGE, *LPDIPROPRANGE; +typedef const DIPROPRANGE *LPCDIPROPRANGE; + +#define DIPROPRANGE_NOMIN ((LONG)0x80000000) +#define DIPROPRANGE_NOMAX ((LONG)0x7FFFFFFF) + +#if(DIRECTINPUT_VERSION >= 0x050a) +typedef struct DIPROPCAL { + DIPROPHEADER diph; + LONG lMin; + LONG lCenter; + LONG lMax; +} DIPROPCAL, *LPDIPROPCAL; +typedef const DIPROPCAL *LPCDIPROPCAL; + +typedef struct DIPROPCALPOV { + DIPROPHEADER diph; + LONG lMin[5]; + LONG lMax[5]; +} DIPROPCALPOV, *LPDIPROPCALPOV; +typedef const DIPROPCALPOV *LPCDIPROPCALPOV; + +typedef struct DIPROPGUIDANDPATH { + DIPROPHEADER diph; + GUID guidClass; + WCHAR wszPath[MAX_PATH]; +} DIPROPGUIDANDPATH, *LPDIPROPGUIDANDPATH; +typedef const DIPROPGUIDANDPATH *LPCDIPROPGUIDANDPATH; + +typedef struct DIPROPSTRING { + DIPROPHEADER diph; + WCHAR wsz[MAX_PATH]; +} DIPROPSTRING, *LPDIPROPSTRING; +typedef const DIPROPSTRING *LPCDIPROPSTRING; + +#endif /* DIRECTINPUT_VERSION >= 0x050a */ + +#if(DIRECTINPUT_VERSION >= 0x0800) +#define MAXCPOINTSNUM 8 + +typedef struct _CPOINT +{ + LONG lP; // raw value + DWORD dwLog; // logical_value / max_logical_value * 10000 +} CPOINT, *PCPOINT; + +typedef struct DIPROPCPOINTS { + DIPROPHEADER diph; + DWORD dwCPointsNum; + CPOINT cp[MAXCPOINTSNUM]; +} DIPROPCPOINTS, *LPDIPROPCPOINTS; +typedef const DIPROPCPOINTS *LPCDIPROPCPOINTS; +#endif /* DIRECTINPUT_VERSION >= 0x0800 */ + + +#ifdef __cplusplus +#define MAKEDIPROP(prop) (*(const GUID *)(prop)) +#else +#define MAKEDIPROP(prop) ((REFGUID)(prop)) +#endif + +#define DIPROP_BUFFERSIZE MAKEDIPROP(1) + +#define DIPROP_AXISMODE MAKEDIPROP(2) + +#define DIPROPAXISMODE_ABS 0 +#define DIPROPAXISMODE_REL 1 + +#define DIPROP_GRANULARITY MAKEDIPROP(3) + +#define DIPROP_RANGE MAKEDIPROP(4) + +#define DIPROP_DEADZONE MAKEDIPROP(5) + +#define DIPROP_SATURATION MAKEDIPROP(6) + +#define DIPROP_FFGAIN MAKEDIPROP(7) + +#define DIPROP_FFLOAD MAKEDIPROP(8) + +#define DIPROP_AUTOCENTER MAKEDIPROP(9) + +#define DIPROPAUTOCENTER_OFF 0 +#define DIPROPAUTOCENTER_ON 1 + +#define DIPROP_CALIBRATIONMODE MAKEDIPROP(10) + +#define DIPROPCALIBRATIONMODE_COOKED 0 +#define DIPROPCALIBRATIONMODE_RAW 1 + +#if(DIRECTINPUT_VERSION >= 0x050a) +#define DIPROP_CALIBRATION MAKEDIPROP(11) + +#define DIPROP_GUIDANDPATH MAKEDIPROP(12) + +#define DIPROP_INSTANCENAME MAKEDIPROP(13) + +#define DIPROP_PRODUCTNAME MAKEDIPROP(14) +#endif /* DIRECTINPUT_VERSION >= 0x050a */ + +#if(DIRECTINPUT_VERSION >= 0x05b2) +#define DIPROP_JOYSTICKID MAKEDIPROP(15) + +#define DIPROP_GETPORTDISPLAYNAME MAKEDIPROP(16) + +#endif /* DIRECTINPUT_VERSION >= 0x05b2 */ + +#if(DIRECTINPUT_VERSION >= 0x0700) +#define DIPROP_PHYSICALRANGE MAKEDIPROP(18) + +#define DIPROP_LOGICALRANGE MAKEDIPROP(19) +#endif /* DIRECTINPUT_VERSION >= 0x0700 */ + +#if(DIRECTINPUT_VERSION >= 0x0800) +#define DIPROP_KEYNAME MAKEDIPROP(20) + +#define DIPROP_CPOINTS MAKEDIPROP(21) + +#define DIPROP_APPDATA MAKEDIPROP(22) + +#define DIPROP_SCANCODE MAKEDIPROP(23) + +#define DIPROP_VIDPID MAKEDIPROP(24) + +#define DIPROP_USERNAME MAKEDIPROP(25) + +#define DIPROP_TYPENAME MAKEDIPROP(26) +#endif /* DIRECTINPUT_VERSION >= 0x0800 */ + + +typedef struct DIDEVICEOBJECTDATA_DX3 { + DWORD dwOfs; + DWORD dwData; + DWORD dwTimeStamp; + DWORD dwSequence; +} DIDEVICEOBJECTDATA_DX3, *LPDIDEVICEOBJECTDATA_DX3; +typedef const DIDEVICEOBJECTDATA_DX3 *LPCDIDEVICEOBJECTDATA_DX; + +typedef struct DIDEVICEOBJECTDATA { + DWORD dwOfs; + DWORD dwData; + DWORD dwTimeStamp; + DWORD dwSequence; +#if(DIRECTINPUT_VERSION >= 0x0800) + UINT_PTR uAppData; +#endif /* DIRECTINPUT_VERSION >= 0x0800 */ +} DIDEVICEOBJECTDATA, *LPDIDEVICEOBJECTDATA; +typedef const DIDEVICEOBJECTDATA *LPCDIDEVICEOBJECTDATA; + +#define DIGDD_PEEK 0x00000001 + +#define DISEQUENCE_COMPARE(dwSequence1, cmp, dwSequence2) \ + ((int)((dwSequence1) - (dwSequence2)) cmp 0) +#define DISCL_EXCLUSIVE 0x00000001 +#define DISCL_NONEXCLUSIVE 0x00000002 +#define DISCL_FOREGROUND 0x00000004 +#define DISCL_BACKGROUND 0x00000008 +#define DISCL_NOWINKEY 0x00000010 + +#if(DIRECTINPUT_VERSION >= 0x0500) +/* These structures are defined for DirectX 3.0 compatibility */ + +typedef struct DIDEVICEINSTANCE_DX3A { + DWORD dwSize; + GUID guidInstance; + GUID guidProduct; + DWORD dwDevType; + CHAR tszInstanceName[MAX_PATH]; + CHAR tszProductName[MAX_PATH]; +} DIDEVICEINSTANCE_DX3A, *LPDIDEVICEINSTANCE_DX3A; +typedef struct DIDEVICEINSTANCE_DX3W { + DWORD dwSize; + GUID guidInstance; + GUID guidProduct; + DWORD dwDevType; + WCHAR tszInstanceName[MAX_PATH]; + WCHAR tszProductName[MAX_PATH]; +} DIDEVICEINSTANCE_DX3W, *LPDIDEVICEINSTANCE_DX3W; +#ifdef UNICODE +typedef DIDEVICEINSTANCE_DX3W DIDEVICEINSTANCE_DX3; +typedef LPDIDEVICEINSTANCE_DX3W LPDIDEVICEINSTANCE_DX3; +#else +typedef DIDEVICEINSTANCE_DX3A DIDEVICEINSTANCE_DX3; +typedef LPDIDEVICEINSTANCE_DX3A LPDIDEVICEINSTANCE_DX3; +#endif // UNICODE +typedef const DIDEVICEINSTANCE_DX3A *LPCDIDEVICEINSTANCE_DX3A; +typedef const DIDEVICEINSTANCE_DX3W *LPCDIDEVICEINSTANCE_DX3W; +typedef const DIDEVICEINSTANCE_DX3 *LPCDIDEVICEINSTANCE_DX3; +#endif /* DIRECTINPUT_VERSION >= 0x0500 */ + +typedef struct DIDEVICEINSTANCEA { + DWORD dwSize; + GUID guidInstance; + GUID guidProduct; + DWORD dwDevType; + CHAR tszInstanceName[MAX_PATH]; + CHAR tszProductName[MAX_PATH]; +#if(DIRECTINPUT_VERSION >= 0x0500) + GUID guidFFDriver; + WORD wUsagePage; + WORD wUsage; +#endif /* DIRECTINPUT_VERSION >= 0x0500 */ +} DIDEVICEINSTANCEA, *LPDIDEVICEINSTANCEA; +typedef struct DIDEVICEINSTANCEW { + DWORD dwSize; + GUID guidInstance; + GUID guidProduct; + DWORD dwDevType; + WCHAR tszInstanceName[MAX_PATH]; + WCHAR tszProductName[MAX_PATH]; +#if(DIRECTINPUT_VERSION >= 0x0500) + GUID guidFFDriver; + WORD wUsagePage; + WORD wUsage; +#endif /* DIRECTINPUT_VERSION >= 0x0500 */ +} DIDEVICEINSTANCEW, *LPDIDEVICEINSTANCEW; +#ifdef UNICODE +typedef DIDEVICEINSTANCEW DIDEVICEINSTANCE; +typedef LPDIDEVICEINSTANCEW LPDIDEVICEINSTANCE; +#else +typedef DIDEVICEINSTANCEA DIDEVICEINSTANCE; +typedef LPDIDEVICEINSTANCEA LPDIDEVICEINSTANCE; +#endif // UNICODE + +typedef const DIDEVICEINSTANCEA *LPCDIDEVICEINSTANCEA; +typedef const DIDEVICEINSTANCEW *LPCDIDEVICEINSTANCEW; +#ifdef UNICODE +typedef DIDEVICEINSTANCEW DIDEVICEINSTANCE; +typedef LPCDIDEVICEINSTANCEW LPCDIDEVICEINSTANCE; +#else +typedef DIDEVICEINSTANCEA DIDEVICEINSTANCE; +typedef LPCDIDEVICEINSTANCEA LPCDIDEVICEINSTANCE; +#endif // UNICODE +typedef const DIDEVICEINSTANCE *LPCDIDEVICEINSTANCE; + +#undef INTERFACE +#define INTERFACE IDirectInputDeviceW + +DECLARE_INTERFACE_(IDirectInputDeviceW, IUnknown) +{ + /*** IUnknown methods ***/ + STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID * ppvObj) PURE; + STDMETHOD_(ULONG,AddRef)(THIS) PURE; + STDMETHOD_(ULONG,Release)(THIS) PURE; + + /*** IDirectInputDeviceW methods ***/ + STDMETHOD(GetCapabilities)(THIS_ LPDIDEVCAPS) PURE; + STDMETHOD(EnumObjects)(THIS_ LPDIENUMDEVICEOBJECTSCALLBACKW,LPVOID,DWORD) PURE; + STDMETHOD(GetProperty)(THIS_ REFGUID,LPDIPROPHEADER) PURE; + STDMETHOD(SetProperty)(THIS_ REFGUID,LPCDIPROPHEADER) PURE; + STDMETHOD(Acquire)(THIS) PURE; + STDMETHOD(Unacquire)(THIS) PURE; + STDMETHOD(GetDeviceState)(THIS_ DWORD,LPVOID) PURE; + STDMETHOD(GetDeviceData)(THIS_ DWORD,LPDIDEVICEOBJECTDATA,LPDWORD,DWORD) PURE; + STDMETHOD(SetDataFormat)(THIS_ LPCDIDATAFORMAT) PURE; + STDMETHOD(SetEventNotification)(THIS_ HANDLE) PURE; + STDMETHOD(SetCooperativeLevel)(THIS_ HWND,DWORD) PURE; + STDMETHOD(GetObjectInfo)(THIS_ LPDIDEVICEOBJECTINSTANCEW,DWORD,DWORD) PURE; + STDMETHOD(GetDeviceInfo)(THIS_ LPDIDEVICEINSTANCEW) PURE; + STDMETHOD(RunControlPanel)(THIS_ HWND,DWORD) PURE; + STDMETHOD(Initialize)(THIS_ HINSTANCE,DWORD,REFGUID) PURE; +}; + +typedef struct IDirectInputDeviceW *LPDIRECTINPUTDEVICEW; + +#undef INTERFACE +#define INTERFACE IDirectInputDeviceA + +DECLARE_INTERFACE_(IDirectInputDeviceA, IUnknown) +{ + /*** IUnknown methods ***/ + STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID * ppvObj) PURE; + STDMETHOD_(ULONG,AddRef)(THIS) PURE; + STDMETHOD_(ULONG,Release)(THIS) PURE; + + /*** IDirectInputDeviceA methods ***/ + STDMETHOD(GetCapabilities)(THIS_ LPDIDEVCAPS) PURE; + STDMETHOD(EnumObjects)(THIS_ LPDIENUMDEVICEOBJECTSCALLBACKA,LPVOID,DWORD) PURE; + STDMETHOD(GetProperty)(THIS_ REFGUID,LPDIPROPHEADER) PURE; + STDMETHOD(SetProperty)(THIS_ REFGUID,LPCDIPROPHEADER) PURE; + STDMETHOD(Acquire)(THIS) PURE; + STDMETHOD(Unacquire)(THIS) PURE; + STDMETHOD(GetDeviceState)(THIS_ DWORD,LPVOID) PURE; + STDMETHOD(GetDeviceData)(THIS_ DWORD,LPDIDEVICEOBJECTDATA,LPDWORD,DWORD) PURE; + STDMETHOD(SetDataFormat)(THIS_ LPCDIDATAFORMAT) PURE; + STDMETHOD(SetEventNotification)(THIS_ HANDLE) PURE; + STDMETHOD(SetCooperativeLevel)(THIS_ HWND,DWORD) PURE; + STDMETHOD(GetObjectInfo)(THIS_ LPDIDEVICEOBJECTINSTANCEA,DWORD,DWORD) PURE; + STDMETHOD(GetDeviceInfo)(THIS_ LPDIDEVICEINSTANCEA) PURE; + STDMETHOD(RunControlPanel)(THIS_ HWND,DWORD) PURE; + STDMETHOD(Initialize)(THIS_ HINSTANCE,DWORD,REFGUID) PURE; +}; + +typedef struct IDirectInputDeviceA *LPDIRECTINPUTDEVICEA; + +#ifdef UNICODE +#define IID_IDirectInputDevice IID_IDirectInputDeviceW +#define IDirectInputDevice IDirectInputDeviceW +#define IDirectInputDeviceVtbl IDirectInputDeviceWVtbl +#else +#define IID_IDirectInputDevice IID_IDirectInputDeviceA +#define IDirectInputDevice IDirectInputDeviceA +#define IDirectInputDeviceVtbl IDirectInputDeviceAVtbl +#endif +typedef struct IDirectInputDevice *LPDIRECTINPUTDEVICE; + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectInputDevice_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) +#define IDirectInputDevice_AddRef(p) (p)->lpVtbl->AddRef(p) +#define IDirectInputDevice_Release(p) (p)->lpVtbl->Release(p) +#define IDirectInputDevice_GetCapabilities(p,a) (p)->lpVtbl->GetCapabilities(p,a) +#define IDirectInputDevice_EnumObjects(p,a,b,c) (p)->lpVtbl->EnumObjects(p,a,b,c) +#define IDirectInputDevice_GetProperty(p,a,b) (p)->lpVtbl->GetProperty(p,a,b) +#define IDirectInputDevice_SetProperty(p,a,b) (p)->lpVtbl->SetProperty(p,a,b) +#define IDirectInputDevice_Acquire(p) (p)->lpVtbl->Acquire(p) +#define IDirectInputDevice_Unacquire(p) (p)->lpVtbl->Unacquire(p) +#define IDirectInputDevice_GetDeviceState(p,a,b) (p)->lpVtbl->GetDeviceState(p,a,b) +#define IDirectInputDevice_GetDeviceData(p,a,b,c,d) (p)->lpVtbl->GetDeviceData(p,a,b,c,d) +#define IDirectInputDevice_SetDataFormat(p,a) (p)->lpVtbl->SetDataFormat(p,a) +#define IDirectInputDevice_SetEventNotification(p,a) (p)->lpVtbl->SetEventNotification(p,a) +#define IDirectInputDevice_SetCooperativeLevel(p,a,b) (p)->lpVtbl->SetCooperativeLevel(p,a,b) +#define IDirectInputDevice_GetObjectInfo(p,a,b,c) (p)->lpVtbl->GetObjectInfo(p,a,b,c) +#define IDirectInputDevice_GetDeviceInfo(p,a) (p)->lpVtbl->GetDeviceInfo(p,a) +#define IDirectInputDevice_RunControlPanel(p,a,b) (p)->lpVtbl->RunControlPanel(p,a,b) +#define IDirectInputDevice_Initialize(p,a,b,c) (p)->lpVtbl->Initialize(p,a,b,c) +#else +#define IDirectInputDevice_QueryInterface(p,a,b) (p)->QueryInterface(a,b) +#define IDirectInputDevice_AddRef(p) (p)->AddRef() +#define IDirectInputDevice_Release(p) (p)->Release() +#define IDirectInputDevice_GetCapabilities(p,a) (p)->GetCapabilities(a) +#define IDirectInputDevice_EnumObjects(p,a,b,c) (p)->EnumObjects(a,b,c) +#define IDirectInputDevice_GetProperty(p,a,b) (p)->GetProperty(a,b) +#define IDirectInputDevice_SetProperty(p,a,b) (p)->SetProperty(a,b) +#define IDirectInputDevice_Acquire(p) (p)->Acquire() +#define IDirectInputDevice_Unacquire(p) (p)->Unacquire() +#define IDirectInputDevice_GetDeviceState(p,a,b) (p)->GetDeviceState(a,b) +#define IDirectInputDevice_GetDeviceData(p,a,b,c,d) (p)->GetDeviceData(a,b,c,d) +#define IDirectInputDevice_SetDataFormat(p,a) (p)->SetDataFormat(a) +#define IDirectInputDevice_SetEventNotification(p,a) (p)->SetEventNotification(a) +#define IDirectInputDevice_SetCooperativeLevel(p,a,b) (p)->SetCooperativeLevel(a,b) +#define IDirectInputDevice_GetObjectInfo(p,a,b,c) (p)->GetObjectInfo(a,b,c) +#define IDirectInputDevice_GetDeviceInfo(p,a) (p)->GetDeviceInfo(a) +#define IDirectInputDevice_RunControlPanel(p,a,b) (p)->RunControlPanel(a,b) +#define IDirectInputDevice_Initialize(p,a,b,c) (p)->Initialize(a,b,c) +#endif + +#endif /* DIJ_RINGZERO */ + + +#if(DIRECTINPUT_VERSION >= 0x0500) + +#define DISFFC_RESET 0x00000001 +#define DISFFC_STOPALL 0x00000002 +#define DISFFC_PAUSE 0x00000004 +#define DISFFC_CONTINUE 0x00000008 +#define DISFFC_SETACTUATORSON 0x00000010 +#define DISFFC_SETACTUATORSOFF 0x00000020 + +#define DIGFFS_EMPTY 0x00000001 +#define DIGFFS_STOPPED 0x00000002 +#define DIGFFS_PAUSED 0x00000004 +#define DIGFFS_ACTUATORSON 0x00000010 +#define DIGFFS_ACTUATORSOFF 0x00000020 +#define DIGFFS_POWERON 0x00000040 +#define DIGFFS_POWEROFF 0x00000080 +#define DIGFFS_SAFETYSWITCHON 0x00000100 +#define DIGFFS_SAFETYSWITCHOFF 0x00000200 +#define DIGFFS_USERFFSWITCHON 0x00000400 +#define DIGFFS_USERFFSWITCHOFF 0x00000800 +#define DIGFFS_DEVICELOST 0x80000000 + +#ifndef DIJ_RINGZERO + +typedef struct DIEFFECTINFOA { + DWORD dwSize; + GUID guid; + DWORD dwEffType; + DWORD dwStaticParams; + DWORD dwDynamicParams; + CHAR tszName[MAX_PATH]; +} DIEFFECTINFOA, *LPDIEFFECTINFOA; +typedef struct DIEFFECTINFOW { + DWORD dwSize; + GUID guid; + DWORD dwEffType; + DWORD dwStaticParams; + DWORD dwDynamicParams; + WCHAR tszName[MAX_PATH]; +} DIEFFECTINFOW, *LPDIEFFECTINFOW; +#ifdef UNICODE +typedef DIEFFECTINFOW DIEFFECTINFO; +typedef LPDIEFFECTINFOW LPDIEFFECTINFO; +#else +typedef DIEFFECTINFOA DIEFFECTINFO; +typedef LPDIEFFECTINFOA LPDIEFFECTINFO; +#endif // UNICODE +typedef const DIEFFECTINFOA *LPCDIEFFECTINFOA; +typedef const DIEFFECTINFOW *LPCDIEFFECTINFOW; +typedef const DIEFFECTINFO *LPCDIEFFECTINFO; + +#define DISDD_CONTINUE 0x00000001 + +typedef BOOL (FAR PASCAL * LPDIENUMEFFECTSCALLBACKA)(LPCDIEFFECTINFOA, LPVOID); +typedef BOOL (FAR PASCAL * LPDIENUMEFFECTSCALLBACKW)(LPCDIEFFECTINFOW, LPVOID); +#ifdef UNICODE +#define LPDIENUMEFFECTSCALLBACK LPDIENUMEFFECTSCALLBACKW +#else +#define LPDIENUMEFFECTSCALLBACK LPDIENUMEFFECTSCALLBACKA +#endif // !UNICODE +typedef BOOL (FAR PASCAL * LPDIENUMCREATEDEFFECTOBJECTSCALLBACK)(LPDIRECTINPUTEFFECT, LPVOID); + +#undef INTERFACE +#define INTERFACE IDirectInputDevice2W + +DECLARE_INTERFACE_(IDirectInputDevice2W, IDirectInputDeviceW) +{ + /*** IUnknown methods ***/ + STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID * ppvObj) PURE; + STDMETHOD_(ULONG,AddRef)(THIS) PURE; + STDMETHOD_(ULONG,Release)(THIS) PURE; + + /*** IDirectInputDeviceW methods ***/ + STDMETHOD(GetCapabilities)(THIS_ LPDIDEVCAPS) PURE; + STDMETHOD(EnumObjects)(THIS_ LPDIENUMDEVICEOBJECTSCALLBACKW,LPVOID,DWORD) PURE; + STDMETHOD(GetProperty)(THIS_ REFGUID,LPDIPROPHEADER) PURE; + STDMETHOD(SetProperty)(THIS_ REFGUID,LPCDIPROPHEADER) PURE; + STDMETHOD(Acquire)(THIS) PURE; + STDMETHOD(Unacquire)(THIS) PURE; + STDMETHOD(GetDeviceState)(THIS_ DWORD,LPVOID) PURE; + STDMETHOD(GetDeviceData)(THIS_ DWORD,LPDIDEVICEOBJECTDATA,LPDWORD,DWORD) PURE; + STDMETHOD(SetDataFormat)(THIS_ LPCDIDATAFORMAT) PURE; + STDMETHOD(SetEventNotification)(THIS_ HANDLE) PURE; + STDMETHOD(SetCooperativeLevel)(THIS_ HWND,DWORD) PURE; + STDMETHOD(GetObjectInfo)(THIS_ LPDIDEVICEOBJECTINSTANCEW,DWORD,DWORD) PURE; + STDMETHOD(GetDeviceInfo)(THIS_ LPDIDEVICEINSTANCEW) PURE; + STDMETHOD(RunControlPanel)(THIS_ HWND,DWORD) PURE; + STDMETHOD(Initialize)(THIS_ HINSTANCE,DWORD,REFGUID) PURE; + + /*** IDirectInputDevice2W methods ***/ + STDMETHOD(CreateEffect)(THIS_ REFGUID,LPCDIEFFECT,LPDIRECTINPUTEFFECT *,LPUNKNOWN) PURE; + STDMETHOD(EnumEffects)(THIS_ LPDIENUMEFFECTSCALLBACKW,LPVOID,DWORD) PURE; + STDMETHOD(GetEffectInfo)(THIS_ LPDIEFFECTINFOW,REFGUID) PURE; + STDMETHOD(GetForceFeedbackState)(THIS_ LPDWORD) PURE; + STDMETHOD(SendForceFeedbackCommand)(THIS_ DWORD) PURE; + STDMETHOD(EnumCreatedEffectObjects)(THIS_ LPDIENUMCREATEDEFFECTOBJECTSCALLBACK,LPVOID,DWORD) PURE; + STDMETHOD(Escape)(THIS_ LPDIEFFESCAPE) PURE; + STDMETHOD(Poll)(THIS) PURE; + STDMETHOD(SendDeviceData)(THIS_ DWORD,LPCDIDEVICEOBJECTDATA,LPDWORD,DWORD) PURE; +}; + +typedef struct IDirectInputDevice2W *LPDIRECTINPUTDEVICE2W; + +#undef INTERFACE +#define INTERFACE IDirectInputDevice2A + +DECLARE_INTERFACE_(IDirectInputDevice2A, IDirectInputDeviceA) +{ + /*** IUnknown methods ***/ + STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID * ppvObj) PURE; + STDMETHOD_(ULONG,AddRef)(THIS) PURE; + STDMETHOD_(ULONG,Release)(THIS) PURE; + + /*** IDirectInputDeviceA methods ***/ + STDMETHOD(GetCapabilities)(THIS_ LPDIDEVCAPS) PURE; + STDMETHOD(EnumObjects)(THIS_ LPDIENUMDEVICEOBJECTSCALLBACKA,LPVOID,DWORD) PURE; + STDMETHOD(GetProperty)(THIS_ REFGUID,LPDIPROPHEADER) PURE; + STDMETHOD(SetProperty)(THIS_ REFGUID,LPCDIPROPHEADER) PURE; + STDMETHOD(Acquire)(THIS) PURE; + STDMETHOD(Unacquire)(THIS) PURE; + STDMETHOD(GetDeviceState)(THIS_ DWORD,LPVOID) PURE; + STDMETHOD(GetDeviceData)(THIS_ DWORD,LPDIDEVICEOBJECTDATA,LPDWORD,DWORD) PURE; + STDMETHOD(SetDataFormat)(THIS_ LPCDIDATAFORMAT) PURE; + STDMETHOD(SetEventNotification)(THIS_ HANDLE) PURE; + STDMETHOD(SetCooperativeLevel)(THIS_ HWND,DWORD) PURE; + STDMETHOD(GetObjectInfo)(THIS_ LPDIDEVICEOBJECTINSTANCEA,DWORD,DWORD) PURE; + STDMETHOD(GetDeviceInfo)(THIS_ LPDIDEVICEINSTANCEA) PURE; + STDMETHOD(RunControlPanel)(THIS_ HWND,DWORD) PURE; + STDMETHOD(Initialize)(THIS_ HINSTANCE,DWORD,REFGUID) PURE; + + /*** IDirectInputDevice2A methods ***/ + STDMETHOD(CreateEffect)(THIS_ REFGUID,LPCDIEFFECT,LPDIRECTINPUTEFFECT *,LPUNKNOWN) PURE; + STDMETHOD(EnumEffects)(THIS_ LPDIENUMEFFECTSCALLBACKA,LPVOID,DWORD) PURE; + STDMETHOD(GetEffectInfo)(THIS_ LPDIEFFECTINFOA,REFGUID) PURE; + STDMETHOD(GetForceFeedbackState)(THIS_ LPDWORD) PURE; + STDMETHOD(SendForceFeedbackCommand)(THIS_ DWORD) PURE; + STDMETHOD(EnumCreatedEffectObjects)(THIS_ LPDIENUMCREATEDEFFECTOBJECTSCALLBACK,LPVOID,DWORD) PURE; + STDMETHOD(Escape)(THIS_ LPDIEFFESCAPE) PURE; + STDMETHOD(Poll)(THIS) PURE; + STDMETHOD(SendDeviceData)(THIS_ DWORD,LPCDIDEVICEOBJECTDATA,LPDWORD,DWORD) PURE; +}; + +typedef struct IDirectInputDevice2A *LPDIRECTINPUTDEVICE2A; + +#ifdef UNICODE +#define IID_IDirectInputDevice2 IID_IDirectInputDevice2W +#define IDirectInputDevice2 IDirectInputDevice2W +#define IDirectInputDevice2Vtbl IDirectInputDevice2WVtbl +#else +#define IID_IDirectInputDevice2 IID_IDirectInputDevice2A +#define IDirectInputDevice2 IDirectInputDevice2A +#define IDirectInputDevice2Vtbl IDirectInputDevice2AVtbl +#endif +typedef struct IDirectInputDevice2 *LPDIRECTINPUTDEVICE2; + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectInputDevice2_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) +#define IDirectInputDevice2_AddRef(p) (p)->lpVtbl->AddRef(p) +#define IDirectInputDevice2_Release(p) (p)->lpVtbl->Release(p) +#define IDirectInputDevice2_GetCapabilities(p,a) (p)->lpVtbl->GetCapabilities(p,a) +#define IDirectInputDevice2_EnumObjects(p,a,b,c) (p)->lpVtbl->EnumObjects(p,a,b,c) +#define IDirectInputDevice2_GetProperty(p,a,b) (p)->lpVtbl->GetProperty(p,a,b) +#define IDirectInputDevice2_SetProperty(p,a,b) (p)->lpVtbl->SetProperty(p,a,b) +#define IDirectInputDevice2_Acquire(p) (p)->lpVtbl->Acquire(p) +#define IDirectInputDevice2_Unacquire(p) (p)->lpVtbl->Unacquire(p) +#define IDirectInputDevice2_GetDeviceState(p,a,b) (p)->lpVtbl->GetDeviceState(p,a,b) +#define IDirectInputDevice2_GetDeviceData(p,a,b,c,d) (p)->lpVtbl->GetDeviceData(p,a,b,c,d) +#define IDirectInputDevice2_SetDataFormat(p,a) (p)->lpVtbl->SetDataFormat(p,a) +#define IDirectInputDevice2_SetEventNotification(p,a) (p)->lpVtbl->SetEventNotification(p,a) +#define IDirectInputDevice2_SetCooperativeLevel(p,a,b) (p)->lpVtbl->SetCooperativeLevel(p,a,b) +#define IDirectInputDevice2_GetObjectInfo(p,a,b,c) (p)->lpVtbl->GetObjectInfo(p,a,b,c) +#define IDirectInputDevice2_GetDeviceInfo(p,a) (p)->lpVtbl->GetDeviceInfo(p,a) +#define IDirectInputDevice2_RunControlPanel(p,a,b) (p)->lpVtbl->RunControlPanel(p,a,b) +#define IDirectInputDevice2_Initialize(p,a,b,c) (p)->lpVtbl->Initialize(p,a,b,c) +#define IDirectInputDevice2_CreateEffect(p,a,b,c,d) (p)->lpVtbl->CreateEffect(p,a,b,c,d) +#define IDirectInputDevice2_EnumEffects(p,a,b,c) (p)->lpVtbl->EnumEffects(p,a,b,c) +#define IDirectInputDevice2_GetEffectInfo(p,a,b) (p)->lpVtbl->GetEffectInfo(p,a,b) +#define IDirectInputDevice2_GetForceFeedbackState(p,a) (p)->lpVtbl->GetForceFeedbackState(p,a) +#define IDirectInputDevice2_SendForceFeedbackCommand(p,a) (p)->lpVtbl->SendForceFeedbackCommand(p,a) +#define IDirectInputDevice2_EnumCreatedEffectObjects(p,a,b,c) (p)->lpVtbl->EnumCreatedEffectObjects(p,a,b,c) +#define IDirectInputDevice2_Escape(p,a) (p)->lpVtbl->Escape(p,a) +#define IDirectInputDevice2_Poll(p) (p)->lpVtbl->Poll(p) +#define IDirectInputDevice2_SendDeviceData(p,a,b,c,d) (p)->lpVtbl->SendDeviceData(p,a,b,c,d) +#else +#define IDirectInputDevice2_QueryInterface(p,a,b) (p)->QueryInterface(a,b) +#define IDirectInputDevice2_AddRef(p) (p)->AddRef() +#define IDirectInputDevice2_Release(p) (p)->Release() +#define IDirectInputDevice2_GetCapabilities(p,a) (p)->GetCapabilities(a) +#define IDirectInputDevice2_EnumObjects(p,a,b,c) (p)->EnumObjects(a,b,c) +#define IDirectInputDevice2_GetProperty(p,a,b) (p)->GetProperty(a,b) +#define IDirectInputDevice2_SetProperty(p,a,b) (p)->SetProperty(a,b) +#define IDirectInputDevice2_Acquire(p) (p)->Acquire() +#define IDirectInputDevice2_Unacquire(p) (p)->Unacquire() +#define IDirectInputDevice2_GetDeviceState(p,a,b) (p)->GetDeviceState(a,b) +#define IDirectInputDevice2_GetDeviceData(p,a,b,c,d) (p)->GetDeviceData(a,b,c,d) +#define IDirectInputDevice2_SetDataFormat(p,a) (p)->SetDataFormat(a) +#define IDirectInputDevice2_SetEventNotification(p,a) (p)->SetEventNotification(a) +#define IDirectInputDevice2_SetCooperativeLevel(p,a,b) (p)->SetCooperativeLevel(a,b) +#define IDirectInputDevice2_GetObjectInfo(p,a,b,c) (p)->GetObjectInfo(a,b,c) +#define IDirectInputDevice2_GetDeviceInfo(p,a) (p)->GetDeviceInfo(a) +#define IDirectInputDevice2_RunControlPanel(p,a,b) (p)->RunControlPanel(a,b) +#define IDirectInputDevice2_Initialize(p,a,b,c) (p)->Initialize(a,b,c) +#define IDirectInputDevice2_CreateEffect(p,a,b,c,d) (p)->CreateEffect(a,b,c,d) +#define IDirectInputDevice2_EnumEffects(p,a,b,c) (p)->EnumEffects(a,b,c) +#define IDirectInputDevice2_GetEffectInfo(p,a,b) (p)->GetEffectInfo(a,b) +#define IDirectInputDevice2_GetForceFeedbackState(p,a) (p)->GetForceFeedbackState(a) +#define IDirectInputDevice2_SendForceFeedbackCommand(p,a) (p)->SendForceFeedbackCommand(a) +#define IDirectInputDevice2_EnumCreatedEffectObjects(p,a,b,c) (p)->EnumCreatedEffectObjects(a,b,c) +#define IDirectInputDevice2_Escape(p,a) (p)->Escape(a) +#define IDirectInputDevice2_Poll(p) (p)->Poll() +#define IDirectInputDevice2_SendDeviceData(p,a,b,c,d) (p)->SendDeviceData(a,b,c,d) +#endif + +#endif /* DIJ_RINGZERO */ + +#endif /* DIRECTINPUT_VERSION >= 0x0500 */ + +#if(DIRECTINPUT_VERSION >= 0x0700) +#define DIFEF_DEFAULT 0x00000000 +#define DIFEF_INCLUDENONSTANDARD 0x00000001 +#define DIFEF_MODIFYIFNEEDED 0x00000010 + +#ifndef DIJ_RINGZERO + +#undef INTERFACE +#define INTERFACE IDirectInputDevice7W + +DECLARE_INTERFACE_(IDirectInputDevice7W, IDirectInputDevice2W) +{ + /*** IUnknown methods ***/ + STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID * ppvObj) PURE; + STDMETHOD_(ULONG,AddRef)(THIS) PURE; + STDMETHOD_(ULONG,Release)(THIS) PURE; + + /*** IDirectInputDevice2W methods ***/ + STDMETHOD(GetCapabilities)(THIS_ LPDIDEVCAPS) PURE; + STDMETHOD(EnumObjects)(THIS_ LPDIENUMDEVICEOBJECTSCALLBACKW,LPVOID,DWORD) PURE; + STDMETHOD(GetProperty)(THIS_ REFGUID,LPDIPROPHEADER) PURE; + STDMETHOD(SetProperty)(THIS_ REFGUID,LPCDIPROPHEADER) PURE; + STDMETHOD(Acquire)(THIS) PURE; + STDMETHOD(Unacquire)(THIS) PURE; + STDMETHOD(GetDeviceState)(THIS_ DWORD,LPVOID) PURE; + STDMETHOD(GetDeviceData)(THIS_ DWORD,LPDIDEVICEOBJECTDATA,LPDWORD,DWORD) PURE; + STDMETHOD(SetDataFormat)(THIS_ LPCDIDATAFORMAT) PURE; + STDMETHOD(SetEventNotification)(THIS_ HANDLE) PURE; + STDMETHOD(SetCooperativeLevel)(THIS_ HWND,DWORD) PURE; + STDMETHOD(GetObjectInfo)(THIS_ LPDIDEVICEOBJECTINSTANCEW,DWORD,DWORD) PURE; + STDMETHOD(GetDeviceInfo)(THIS_ LPDIDEVICEINSTANCEW) PURE; + STDMETHOD(RunControlPanel)(THIS_ HWND,DWORD) PURE; + STDMETHOD(Initialize)(THIS_ HINSTANCE,DWORD,REFGUID) PURE; + STDMETHOD(CreateEffect)(THIS_ REFGUID,LPCDIEFFECT,LPDIRECTINPUTEFFECT *,LPUNKNOWN) PURE; + STDMETHOD(EnumEffects)(THIS_ LPDIENUMEFFECTSCALLBACKW,LPVOID,DWORD) PURE; + STDMETHOD(GetEffectInfo)(THIS_ LPDIEFFECTINFOW,REFGUID) PURE; + STDMETHOD(GetForceFeedbackState)(THIS_ LPDWORD) PURE; + STDMETHOD(SendForceFeedbackCommand)(THIS_ DWORD) PURE; + STDMETHOD(EnumCreatedEffectObjects)(THIS_ LPDIENUMCREATEDEFFECTOBJECTSCALLBACK,LPVOID,DWORD) PURE; + STDMETHOD(Escape)(THIS_ LPDIEFFESCAPE) PURE; + STDMETHOD(Poll)(THIS) PURE; + STDMETHOD(SendDeviceData)(THIS_ DWORD,LPCDIDEVICEOBJECTDATA,LPDWORD,DWORD) PURE; + + /*** IDirectInputDevice7W methods ***/ + STDMETHOD(EnumEffectsInFile)(THIS_ LPCWSTR,LPDIENUMEFFECTSINFILECALLBACK,LPVOID,DWORD) PURE; + STDMETHOD(WriteEffectToFile)(THIS_ LPCWSTR,DWORD,LPDIFILEEFFECT,DWORD) PURE; +}; + +typedef struct IDirectInputDevice7W *LPDIRECTINPUTDEVICE7W; + +#undef INTERFACE +#define INTERFACE IDirectInputDevice7A + +DECLARE_INTERFACE_(IDirectInputDevice7A, IDirectInputDevice2A) +{ + /*** IUnknown methods ***/ + STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID * ppvObj) PURE; + STDMETHOD_(ULONG,AddRef)(THIS) PURE; + STDMETHOD_(ULONG,Release)(THIS) PURE; + + /*** IDirectInputDevice2A methods ***/ + STDMETHOD(GetCapabilities)(THIS_ LPDIDEVCAPS) PURE; + STDMETHOD(EnumObjects)(THIS_ LPDIENUMDEVICEOBJECTSCALLBACKA,LPVOID,DWORD) PURE; + STDMETHOD(GetProperty)(THIS_ REFGUID,LPDIPROPHEADER) PURE; + STDMETHOD(SetProperty)(THIS_ REFGUID,LPCDIPROPHEADER) PURE; + STDMETHOD(Acquire)(THIS) PURE; + STDMETHOD(Unacquire)(THIS) PURE; + STDMETHOD(GetDeviceState)(THIS_ DWORD,LPVOID) PURE; + STDMETHOD(GetDeviceData)(THIS_ DWORD,LPDIDEVICEOBJECTDATA,LPDWORD,DWORD) PURE; + STDMETHOD(SetDataFormat)(THIS_ LPCDIDATAFORMAT) PURE; + STDMETHOD(SetEventNotification)(THIS_ HANDLE) PURE; + STDMETHOD(SetCooperativeLevel)(THIS_ HWND,DWORD) PURE; + STDMETHOD(GetObjectInfo)(THIS_ LPDIDEVICEOBJECTINSTANCEA,DWORD,DWORD) PURE; + STDMETHOD(GetDeviceInfo)(THIS_ LPDIDEVICEINSTANCEA) PURE; + STDMETHOD(RunControlPanel)(THIS_ HWND,DWORD) PURE; + STDMETHOD(Initialize)(THIS_ HINSTANCE,DWORD,REFGUID) PURE; + STDMETHOD(CreateEffect)(THIS_ REFGUID,LPCDIEFFECT,LPDIRECTINPUTEFFECT *,LPUNKNOWN) PURE; + STDMETHOD(EnumEffects)(THIS_ LPDIENUMEFFECTSCALLBACKA,LPVOID,DWORD) PURE; + STDMETHOD(GetEffectInfo)(THIS_ LPDIEFFECTINFOA,REFGUID) PURE; + STDMETHOD(GetForceFeedbackState)(THIS_ LPDWORD) PURE; + STDMETHOD(SendForceFeedbackCommand)(THIS_ DWORD) PURE; + STDMETHOD(EnumCreatedEffectObjects)(THIS_ LPDIENUMCREATEDEFFECTOBJECTSCALLBACK,LPVOID,DWORD) PURE; + STDMETHOD(Escape)(THIS_ LPDIEFFESCAPE) PURE; + STDMETHOD(Poll)(THIS) PURE; + STDMETHOD(SendDeviceData)(THIS_ DWORD,LPCDIDEVICEOBJECTDATA,LPDWORD,DWORD) PURE; + + /*** IDirectInputDevice7A methods ***/ + STDMETHOD(EnumEffectsInFile)(THIS_ LPCSTR,LPDIENUMEFFECTSINFILECALLBACK,LPVOID,DWORD) PURE; + STDMETHOD(WriteEffectToFile)(THIS_ LPCSTR,DWORD,LPDIFILEEFFECT,DWORD) PURE; +}; + +typedef struct IDirectInputDevice7A *LPDIRECTINPUTDEVICE7A; + +#ifdef UNICODE +#define IID_IDirectInputDevice7 IID_IDirectInputDevice7W +#define IDirectInputDevice7 IDirectInputDevice7W +#define IDirectInputDevice7Vtbl IDirectInputDevice7WVtbl +#else +#define IID_IDirectInputDevice7 IID_IDirectInputDevice7A +#define IDirectInputDevice7 IDirectInputDevice7A +#define IDirectInputDevice7Vtbl IDirectInputDevice7AVtbl +#endif +typedef struct IDirectInputDevice7 *LPDIRECTINPUTDEVICE7; + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectInputDevice7_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) +#define IDirectInputDevice7_AddRef(p) (p)->lpVtbl->AddRef(p) +#define IDirectInputDevice7_Release(p) (p)->lpVtbl->Release(p) +#define IDirectInputDevice7_GetCapabilities(p,a) (p)->lpVtbl->GetCapabilities(p,a) +#define IDirectInputDevice7_EnumObjects(p,a,b,c) (p)->lpVtbl->EnumObjects(p,a,b,c) +#define IDirectInputDevice7_GetProperty(p,a,b) (p)->lpVtbl->GetProperty(p,a,b) +#define IDirectInputDevice7_SetProperty(p,a,b) (p)->lpVtbl->SetProperty(p,a,b) +#define IDirectInputDevice7_Acquire(p) (p)->lpVtbl->Acquire(p) +#define IDirectInputDevice7_Unacquire(p) (p)->lpVtbl->Unacquire(p) +#define IDirectInputDevice7_GetDeviceState(p,a,b) (p)->lpVtbl->GetDeviceState(p,a,b) +#define IDirectInputDevice7_GetDeviceData(p,a,b,c,d) (p)->lpVtbl->GetDeviceData(p,a,b,c,d) +#define IDirectInputDevice7_SetDataFormat(p,a) (p)->lpVtbl->SetDataFormat(p,a) +#define IDirectInputDevice7_SetEventNotification(p,a) (p)->lpVtbl->SetEventNotification(p,a) +#define IDirectInputDevice7_SetCooperativeLevel(p,a,b) (p)->lpVtbl->SetCooperativeLevel(p,a,b) +#define IDirectInputDevice7_GetObjectInfo(p,a,b,c) (p)->lpVtbl->GetObjectInfo(p,a,b,c) +#define IDirectInputDevice7_GetDeviceInfo(p,a) (p)->lpVtbl->GetDeviceInfo(p,a) +#define IDirectInputDevice7_RunControlPanel(p,a,b) (p)->lpVtbl->RunControlPanel(p,a,b) +#define IDirectInputDevice7_Initialize(p,a,b,c) (p)->lpVtbl->Initialize(p,a,b,c) +#define IDirectInputDevice7_CreateEffect(p,a,b,c,d) (p)->lpVtbl->CreateEffect(p,a,b,c,d) +#define IDirectInputDevice7_EnumEffects(p,a,b,c) (p)->lpVtbl->EnumEffects(p,a,b,c) +#define IDirectInputDevice7_GetEffectInfo(p,a,b) (p)->lpVtbl->GetEffectInfo(p,a,b) +#define IDirectInputDevice7_GetForceFeedbackState(p,a) (p)->lpVtbl->GetForceFeedbackState(p,a) +#define IDirectInputDevice7_SendForceFeedbackCommand(p,a) (p)->lpVtbl->SendForceFeedbackCommand(p,a) +#define IDirectInputDevice7_EnumCreatedEffectObjects(p,a,b,c) (p)->lpVtbl->EnumCreatedEffectObjects(p,a,b,c) +#define IDirectInputDevice7_Escape(p,a) (p)->lpVtbl->Escape(p,a) +#define IDirectInputDevice7_Poll(p) (p)->lpVtbl->Poll(p) +#define IDirectInputDevice7_SendDeviceData(p,a,b,c,d) (p)->lpVtbl->SendDeviceData(p,a,b,c,d) +#define IDirectInputDevice7_EnumEffectsInFile(p,a,b,c,d) (p)->lpVtbl->EnumEffectsInFile(p,a,b,c,d) +#define IDirectInputDevice7_WriteEffectToFile(p,a,b,c,d) (p)->lpVtbl->WriteEffectToFile(p,a,b,c,d) +#else +#define IDirectInputDevice7_QueryInterface(p,a,b) (p)->QueryInterface(a,b) +#define IDirectInputDevice7_AddRef(p) (p)->AddRef() +#define IDirectInputDevice7_Release(p) (p)->Release() +#define IDirectInputDevice7_GetCapabilities(p,a) (p)->GetCapabilities(a) +#define IDirectInputDevice7_EnumObjects(p,a,b,c) (p)->EnumObjects(a,b,c) +#define IDirectInputDevice7_GetProperty(p,a,b) (p)->GetProperty(a,b) +#define IDirectInputDevice7_SetProperty(p,a,b) (p)->SetProperty(a,b) +#define IDirectInputDevice7_Acquire(p) (p)->Acquire() +#define IDirectInputDevice7_Unacquire(p) (p)->Unacquire() +#define IDirectInputDevice7_GetDeviceState(p,a,b) (p)->GetDeviceState(a,b) +#define IDirectInputDevice7_GetDeviceData(p,a,b,c,d) (p)->GetDeviceData(a,b,c,d) +#define IDirectInputDevice7_SetDataFormat(p,a) (p)->SetDataFormat(a) +#define IDirectInputDevice7_SetEventNotification(p,a) (p)->SetEventNotification(a) +#define IDirectInputDevice7_SetCooperativeLevel(p,a,b) (p)->SetCooperativeLevel(a,b) +#define IDirectInputDevice7_GetObjectInfo(p,a,b,c) (p)->GetObjectInfo(a,b,c) +#define IDirectInputDevice7_GetDeviceInfo(p,a) (p)->GetDeviceInfo(a) +#define IDirectInputDevice7_RunControlPanel(p,a,b) (p)->RunControlPanel(a,b) +#define IDirectInputDevice7_Initialize(p,a,b,c) (p)->Initialize(a,b,c) +#define IDirectInputDevice7_CreateEffect(p,a,b,c,d) (p)->CreateEffect(a,b,c,d) +#define IDirectInputDevice7_EnumEffects(p,a,b,c) (p)->EnumEffects(a,b,c) +#define IDirectInputDevice7_GetEffectInfo(p,a,b) (p)->GetEffectInfo(a,b) +#define IDirectInputDevice7_GetForceFeedbackState(p,a) (p)->GetForceFeedbackState(a) +#define IDirectInputDevice7_SendForceFeedbackCommand(p,a) (p)->SendForceFeedbackCommand(a) +#define IDirectInputDevice7_EnumCreatedEffectObjects(p,a,b,c) (p)->EnumCreatedEffectObjects(a,b,c) +#define IDirectInputDevice7_Escape(p,a) (p)->Escape(a) +#define IDirectInputDevice7_Poll(p) (p)->Poll() +#define IDirectInputDevice7_SendDeviceData(p,a,b,c,d) (p)->SendDeviceData(a,b,c,d) +#define IDirectInputDevice7_EnumEffectsInFile(p,a,b,c,d) (p)->EnumEffectsInFile(a,b,c,d) +#define IDirectInputDevice7_WriteEffectToFile(p,a,b,c,d) (p)->WriteEffectToFile(a,b,c,d) +#endif + +#endif /* DIJ_RINGZERO */ + +#endif /* DIRECTINPUT_VERSION >= 0x0700 */ + +#if(DIRECTINPUT_VERSION >= 0x0800) + +#ifndef DIJ_RINGZERO + +#undef INTERFACE +#define INTERFACE IDirectInputDevice8W + +DECLARE_INTERFACE_(IDirectInputDevice8W, IUnknown) +{ + /*** IUnknown methods ***/ + STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID * ppvObj) PURE; + STDMETHOD_(ULONG,AddRef)(THIS) PURE; + STDMETHOD_(ULONG,Release)(THIS) PURE; + + /*** IDirectInputDevice8W methods ***/ + STDMETHOD(GetCapabilities)(THIS_ LPDIDEVCAPS) PURE; + STDMETHOD(EnumObjects)(THIS_ LPDIENUMDEVICEOBJECTSCALLBACKW,LPVOID,DWORD) PURE; + STDMETHOD(GetProperty)(THIS_ REFGUID,LPDIPROPHEADER) PURE; + STDMETHOD(SetProperty)(THIS_ REFGUID,LPCDIPROPHEADER) PURE; + STDMETHOD(Acquire)(THIS) PURE; + STDMETHOD(Unacquire)(THIS) PURE; + STDMETHOD(GetDeviceState)(THIS_ DWORD,LPVOID) PURE; + STDMETHOD(GetDeviceData)(THIS_ DWORD,LPDIDEVICEOBJECTDATA,LPDWORD,DWORD) PURE; + STDMETHOD(SetDataFormat)(THIS_ LPCDIDATAFORMAT) PURE; + STDMETHOD(SetEventNotification)(THIS_ HANDLE) PURE; + STDMETHOD(SetCooperativeLevel)(THIS_ HWND,DWORD) PURE; + STDMETHOD(GetObjectInfo)(THIS_ LPDIDEVICEOBJECTINSTANCEW,DWORD,DWORD) PURE; + STDMETHOD(GetDeviceInfo)(THIS_ LPDIDEVICEINSTANCEW) PURE; + STDMETHOD(RunControlPanel)(THIS_ HWND,DWORD) PURE; + STDMETHOD(Initialize)(THIS_ HINSTANCE,DWORD,REFGUID) PURE; + STDMETHOD(CreateEffect)(THIS_ REFGUID,LPCDIEFFECT,LPDIRECTINPUTEFFECT *,LPUNKNOWN) PURE; + STDMETHOD(EnumEffects)(THIS_ LPDIENUMEFFECTSCALLBACKW,LPVOID,DWORD) PURE; + STDMETHOD(GetEffectInfo)(THIS_ LPDIEFFECTINFOW,REFGUID) PURE; + STDMETHOD(GetForceFeedbackState)(THIS_ LPDWORD) PURE; + STDMETHOD(SendForceFeedbackCommand)(THIS_ DWORD) PURE; + STDMETHOD(EnumCreatedEffectObjects)(THIS_ LPDIENUMCREATEDEFFECTOBJECTSCALLBACK,LPVOID,DWORD) PURE; + STDMETHOD(Escape)(THIS_ LPDIEFFESCAPE) PURE; + STDMETHOD(Poll)(THIS) PURE; + STDMETHOD(SendDeviceData)(THIS_ DWORD,LPCDIDEVICEOBJECTDATA,LPDWORD,DWORD) PURE; + STDMETHOD(EnumEffectsInFile)(THIS_ LPCWSTR,LPDIENUMEFFECTSINFILECALLBACK,LPVOID,DWORD) PURE; + STDMETHOD(WriteEffectToFile)(THIS_ LPCWSTR,DWORD,LPDIFILEEFFECT,DWORD) PURE; + STDMETHOD(BuildActionMap)(THIS_ LPDIACTIONFORMATW,LPCWSTR,DWORD) PURE; + STDMETHOD(SetActionMap)(THIS_ LPDIACTIONFORMATW,LPCWSTR,DWORD) PURE; + STDMETHOD(GetImageInfo)(THIS_ LPDIDEVICEIMAGEINFOHEADERW) PURE; +}; + +typedef struct IDirectInputDevice8W *LPDIRECTINPUTDEVICE8W; + +#undef INTERFACE +#define INTERFACE IDirectInputDevice8A + +DECLARE_INTERFACE_(IDirectInputDevice8A, IUnknown) +{ + /*** IUnknown methods ***/ + STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID * ppvObj) PURE; + STDMETHOD_(ULONG,AddRef)(THIS) PURE; + STDMETHOD_(ULONG,Release)(THIS) PURE; + + /*** IDirectInputDevice8A methods ***/ + STDMETHOD(GetCapabilities)(THIS_ LPDIDEVCAPS) PURE; + STDMETHOD(EnumObjects)(THIS_ LPDIENUMDEVICEOBJECTSCALLBACKA,LPVOID,DWORD) PURE; + STDMETHOD(GetProperty)(THIS_ REFGUID,LPDIPROPHEADER) PURE; + STDMETHOD(SetProperty)(THIS_ REFGUID,LPCDIPROPHEADER) PURE; + STDMETHOD(Acquire)(THIS) PURE; + STDMETHOD(Unacquire)(THIS) PURE; + STDMETHOD(GetDeviceState)(THIS_ DWORD,LPVOID) PURE; + STDMETHOD(GetDeviceData)(THIS_ DWORD,LPDIDEVICEOBJECTDATA,LPDWORD,DWORD) PURE; + STDMETHOD(SetDataFormat)(THIS_ LPCDIDATAFORMAT) PURE; + STDMETHOD(SetEventNotification)(THIS_ HANDLE) PURE; + STDMETHOD(SetCooperativeLevel)(THIS_ HWND,DWORD) PURE; + STDMETHOD(GetObjectInfo)(THIS_ LPDIDEVICEOBJECTINSTANCEA,DWORD,DWORD) PURE; + STDMETHOD(GetDeviceInfo)(THIS_ LPDIDEVICEINSTANCEA) PURE; + STDMETHOD(RunControlPanel)(THIS_ HWND,DWORD) PURE; + STDMETHOD(Initialize)(THIS_ HINSTANCE,DWORD,REFGUID) PURE; + STDMETHOD(CreateEffect)(THIS_ REFGUID,LPCDIEFFECT,LPDIRECTINPUTEFFECT *,LPUNKNOWN) PURE; + STDMETHOD(EnumEffects)(THIS_ LPDIENUMEFFECTSCALLBACKA,LPVOID,DWORD) PURE; + STDMETHOD(GetEffectInfo)(THIS_ LPDIEFFECTINFOA,REFGUID) PURE; + STDMETHOD(GetForceFeedbackState)(THIS_ LPDWORD) PURE; + STDMETHOD(SendForceFeedbackCommand)(THIS_ DWORD) PURE; + STDMETHOD(EnumCreatedEffectObjects)(THIS_ LPDIENUMCREATEDEFFECTOBJECTSCALLBACK,LPVOID,DWORD) PURE; + STDMETHOD(Escape)(THIS_ LPDIEFFESCAPE) PURE; + STDMETHOD(Poll)(THIS) PURE; + STDMETHOD(SendDeviceData)(THIS_ DWORD,LPCDIDEVICEOBJECTDATA,LPDWORD,DWORD) PURE; + STDMETHOD(EnumEffectsInFile)(THIS_ LPCSTR,LPDIENUMEFFECTSINFILECALLBACK,LPVOID,DWORD) PURE; + STDMETHOD(WriteEffectToFile)(THIS_ LPCSTR,DWORD,LPDIFILEEFFECT,DWORD) PURE; + STDMETHOD(BuildActionMap)(THIS_ LPDIACTIONFORMATA,LPCSTR,DWORD) PURE; + STDMETHOD(SetActionMap)(THIS_ LPDIACTIONFORMATA,LPCSTR,DWORD) PURE; + STDMETHOD(GetImageInfo)(THIS_ LPDIDEVICEIMAGEINFOHEADERA) PURE; +}; + +typedef struct IDirectInputDevice8A *LPDIRECTINPUTDEVICE8A; + +#ifdef UNICODE +#define IID_IDirectInputDevice8 IID_IDirectInputDevice8W +#define IDirectInputDevice8 IDirectInputDevice8W +#define IDirectInputDevice8Vtbl IDirectInputDevice8WVtbl +#else +#define IID_IDirectInputDevice8 IID_IDirectInputDevice8A +#define IDirectInputDevice8 IDirectInputDevice8A +#define IDirectInputDevice8Vtbl IDirectInputDevice8AVtbl +#endif +typedef struct IDirectInputDevice8 *LPDIRECTINPUTDEVICE8; + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectInputDevice8_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) +#define IDirectInputDevice8_AddRef(p) (p)->lpVtbl->AddRef(p) +#define IDirectInputDevice8_Release(p) (p)->lpVtbl->Release(p) +#define IDirectInputDevice8_GetCapabilities(p,a) (p)->lpVtbl->GetCapabilities(p,a) +#define IDirectInputDevice8_EnumObjects(p,a,b,c) (p)->lpVtbl->EnumObjects(p,a,b,c) +#define IDirectInputDevice8_GetProperty(p,a,b) (p)->lpVtbl->GetProperty(p,a,b) +#define IDirectInputDevice8_SetProperty(p,a,b) (p)->lpVtbl->SetProperty(p,a,b) +#define IDirectInputDevice8_Acquire(p) (p)->lpVtbl->Acquire(p) +#define IDirectInputDevice8_Unacquire(p) (p)->lpVtbl->Unacquire(p) +#define IDirectInputDevice8_GetDeviceState(p,a,b) (p)->lpVtbl->GetDeviceState(p,a,b) +#define IDirectInputDevice8_GetDeviceData(p,a,b,c,d) (p)->lpVtbl->GetDeviceData(p,a,b,c,d) +#define IDirectInputDevice8_SetDataFormat(p,a) (p)->lpVtbl->SetDataFormat(p,a) +#define IDirectInputDevice8_SetEventNotification(p,a) (p)->lpVtbl->SetEventNotification(p,a) +#define IDirectInputDevice8_SetCooperativeLevel(p,a,b) (p)->lpVtbl->SetCooperativeLevel(p,a,b) +#define IDirectInputDevice8_GetObjectInfo(p,a,b,c) (p)->lpVtbl->GetObjectInfo(p,a,b,c) +#define IDirectInputDevice8_GetDeviceInfo(p,a) (p)->lpVtbl->GetDeviceInfo(p,a) +#define IDirectInputDevice8_RunControlPanel(p,a,b) (p)->lpVtbl->RunControlPanel(p,a,b) +#define IDirectInputDevice8_Initialize(p,a,b,c) (p)->lpVtbl->Initialize(p,a,b,c) +#define IDirectInputDevice8_CreateEffect(p,a,b,c,d) (p)->lpVtbl->CreateEffect(p,a,b,c,d) +#define IDirectInputDevice8_EnumEffects(p,a,b,c) (p)->lpVtbl->EnumEffects(p,a,b,c) +#define IDirectInputDevice8_GetEffectInfo(p,a,b) (p)->lpVtbl->GetEffectInfo(p,a,b) +#define IDirectInputDevice8_GetForceFeedbackState(p,a) (p)->lpVtbl->GetForceFeedbackState(p,a) +#define IDirectInputDevice8_SendForceFeedbackCommand(p,a) (p)->lpVtbl->SendForceFeedbackCommand(p,a) +#define IDirectInputDevice8_EnumCreatedEffectObjects(p,a,b,c) (p)->lpVtbl->EnumCreatedEffectObjects(p,a,b,c) +#define IDirectInputDevice8_Escape(p,a) (p)->lpVtbl->Escape(p,a) +#define IDirectInputDevice8_Poll(p) (p)->lpVtbl->Poll(p) +#define IDirectInputDevice8_SendDeviceData(p,a,b,c,d) (p)->lpVtbl->SendDeviceData(p,a,b,c,d) +#define IDirectInputDevice8_EnumEffectsInFile(p,a,b,c,d) (p)->lpVtbl->EnumEffectsInFile(p,a,b,c,d) +#define IDirectInputDevice8_WriteEffectToFile(p,a,b,c,d) (p)->lpVtbl->WriteEffectToFile(p,a,b,c,d) +#define IDirectInputDevice8_BuildActionMap(p,a,b,c) (p)->lpVtbl->BuildActionMap(p,a,b,c) +#define IDirectInputDevice8_SetActionMap(p,a,b,c) (p)->lpVtbl->SetActionMap(p,a,b,c) +#define IDirectInputDevice8_GetImageInfo(p,a) (p)->lpVtbl->GetImageInfo(p,a) +#else +#define IDirectInputDevice8_QueryInterface(p,a,b) (p)->QueryInterface(a,b) +#define IDirectInputDevice8_AddRef(p) (p)->AddRef() +#define IDirectInputDevice8_Release(p) (p)->Release() +#define IDirectInputDevice8_GetCapabilities(p,a) (p)->GetCapabilities(a) +#define IDirectInputDevice8_EnumObjects(p,a,b,c) (p)->EnumObjects(a,b,c) +#define IDirectInputDevice8_GetProperty(p,a,b) (p)->GetProperty(a,b) +#define IDirectInputDevice8_SetProperty(p,a,b) (p)->SetProperty(a,b) +#define IDirectInputDevice8_Acquire(p) (p)->Acquire() +#define IDirectInputDevice8_Unacquire(p) (p)->Unacquire() +#define IDirectInputDevice8_GetDeviceState(p,a,b) (p)->GetDeviceState(a,b) +#define IDirectInputDevice8_GetDeviceData(p,a,b,c,d) (p)->GetDeviceData(a,b,c,d) +#define IDirectInputDevice8_SetDataFormat(p,a) (p)->SetDataFormat(a) +#define IDirectInputDevice8_SetEventNotification(p,a) (p)->SetEventNotification(a) +#define IDirectInputDevice8_SetCooperativeLevel(p,a,b) (p)->SetCooperativeLevel(a,b) +#define IDirectInputDevice8_GetObjectInfo(p,a,b,c) (p)->GetObjectInfo(a,b,c) +#define IDirectInputDevice8_GetDeviceInfo(p,a) (p)->GetDeviceInfo(a) +#define IDirectInputDevice8_RunControlPanel(p,a,b) (p)->RunControlPanel(a,b) +#define IDirectInputDevice8_Initialize(p,a,b,c) (p)->Initialize(a,b,c) +#define IDirectInputDevice8_CreateEffect(p,a,b,c,d) (p)->CreateEffect(a,b,c,d) +#define IDirectInputDevice8_EnumEffects(p,a,b,c) (p)->EnumEffects(a,b,c) +#define IDirectInputDevice8_GetEffectInfo(p,a,b) (p)->GetEffectInfo(a,b) +#define IDirectInputDevice8_GetForceFeedbackState(p,a) (p)->GetForceFeedbackState(a) +#define IDirectInputDevice8_SendForceFeedbackCommand(p,a) (p)->SendForceFeedbackCommand(a) +#define IDirectInputDevice8_EnumCreatedEffectObjects(p,a,b,c) (p)->EnumCreatedEffectObjects(a,b,c) +#define IDirectInputDevice8_Escape(p,a) (p)->Escape(a) +#define IDirectInputDevice8_Poll(p) (p)->Poll() +#define IDirectInputDevice8_SendDeviceData(p,a,b,c,d) (p)->SendDeviceData(a,b,c,d) +#define IDirectInputDevice8_EnumEffectsInFile(p,a,b,c,d) (p)->EnumEffectsInFile(a,b,c,d) +#define IDirectInputDevice8_WriteEffectToFile(p,a,b,c,d) (p)->WriteEffectToFile(a,b,c,d) +#define IDirectInputDevice8_BuildActionMap(p,a,b,c) (p)->BuildActionMap(a,b,c) +#define IDirectInputDevice8_SetActionMap(p,a,b,c) (p)->SetActionMap(a,b,c) +#define IDirectInputDevice8_GetImageInfo(p,a) (p)->GetImageInfo(a) +#endif + +#endif /* DIJ_RINGZERO */ + +#endif /* DIRECTINPUT_VERSION >= 0x0800 */ + +/**************************************************************************** + * + * Mouse + * + ****************************************************************************/ + +#ifndef DIJ_RINGZERO + +typedef struct _DIMOUSESTATE { + LONG lX; + LONG lY; + LONG lZ; + BYTE rgbButtons[4]; +} DIMOUSESTATE, *LPDIMOUSESTATE; + +#if DIRECTINPUT_VERSION >= 0x0700 +typedef struct _DIMOUSESTATE2 { + LONG lX; + LONG lY; + LONG lZ; + BYTE rgbButtons[8]; +} DIMOUSESTATE2, *LPDIMOUSESTATE2; +#endif + + +#define DIMOFS_X FIELD_OFFSET(DIMOUSESTATE, lX) +#define DIMOFS_Y FIELD_OFFSET(DIMOUSESTATE, lY) +#define DIMOFS_Z FIELD_OFFSET(DIMOUSESTATE, lZ) +#define DIMOFS_BUTTON0 (FIELD_OFFSET(DIMOUSESTATE, rgbButtons) + 0) +#define DIMOFS_BUTTON1 (FIELD_OFFSET(DIMOUSESTATE, rgbButtons) + 1) +#define DIMOFS_BUTTON2 (FIELD_OFFSET(DIMOUSESTATE, rgbButtons) + 2) +#define DIMOFS_BUTTON3 (FIELD_OFFSET(DIMOUSESTATE, rgbButtons) + 3) +#if (DIRECTINPUT_VERSION >= 0x0700) +#define DIMOFS_BUTTON4 (FIELD_OFFSET(DIMOUSESTATE2, rgbButtons) + 4) +#define DIMOFS_BUTTON5 (FIELD_OFFSET(DIMOUSESTATE2, rgbButtons) + 5) +#define DIMOFS_BUTTON6 (FIELD_OFFSET(DIMOUSESTATE2, rgbButtons) + 6) +#define DIMOFS_BUTTON7 (FIELD_OFFSET(DIMOUSESTATE2, rgbButtons) + 7) +#endif +#endif /* DIJ_RINGZERO */ + +/**************************************************************************** + * + * Keyboard + * + ****************************************************************************/ + +#ifndef DIJ_RINGZERO + +/**************************************************************************** + * + * DirectInput keyboard scan codes + * + ****************************************************************************/ +#define DIK_ESCAPE 0x01 +#define DIK_1 0x02 +#define DIK_2 0x03 +#define DIK_3 0x04 +#define DIK_4 0x05 +#define DIK_5 0x06 +#define DIK_6 0x07 +#define DIK_7 0x08 +#define DIK_8 0x09 +#define DIK_9 0x0A +#define DIK_0 0x0B +#define DIK_MINUS 0x0C /* - on main keyboard */ +#define DIK_EQUALS 0x0D +#define DIK_BACK 0x0E /* backspace */ +#define DIK_TAB 0x0F +#define DIK_Q 0x10 +#define DIK_W 0x11 +#define DIK_E 0x12 +#define DIK_R 0x13 +#define DIK_T 0x14 +#define DIK_Y 0x15 +#define DIK_U 0x16 +#define DIK_I 0x17 +#define DIK_O 0x18 +#define DIK_P 0x19 +#define DIK_LBRACKET 0x1A +#define DIK_RBRACKET 0x1B +#define DIK_RETURN 0x1C /* Enter on main keyboard */ +#define DIK_LCONTROL 0x1D +#define DIK_A 0x1E +#define DIK_S 0x1F +#define DIK_D 0x20 +#define DIK_F 0x21 +#define DIK_G 0x22 +#define DIK_H 0x23 +#define DIK_J 0x24 +#define DIK_K 0x25 +#define DIK_L 0x26 +#define DIK_SEMICOLON 0x27 +#define DIK_APOSTROPHE 0x28 +#define DIK_GRAVE 0x29 /* accent grave */ +#define DIK_LSHIFT 0x2A +#define DIK_BACKSLASH 0x2B +#define DIK_Z 0x2C +#define DIK_X 0x2D +#define DIK_C 0x2E +#define DIK_V 0x2F +#define DIK_B 0x30 +#define DIK_N 0x31 +#define DIK_M 0x32 +#define DIK_COMMA 0x33 +#define DIK_PERIOD 0x34 /* . on main keyboard */ +#define DIK_SLASH 0x35 /* / on main keyboard */ +#define DIK_RSHIFT 0x36 +#define DIK_MULTIPLY 0x37 /* * on numeric keypad */ +#define DIK_LMENU 0x38 /* left Alt */ +#define DIK_SPACE 0x39 +#define DIK_CAPITAL 0x3A +#define DIK_F1 0x3B +#define DIK_F2 0x3C +#define DIK_F3 0x3D +#define DIK_F4 0x3E +#define DIK_F5 0x3F +#define DIK_F6 0x40 +#define DIK_F7 0x41 +#define DIK_F8 0x42 +#define DIK_F9 0x43 +#define DIK_F10 0x44 +#define DIK_NUMLOCK 0x45 +#define DIK_SCROLL 0x46 /* Scroll Lock */ +#define DIK_NUMPAD7 0x47 +#define DIK_NUMPAD8 0x48 +#define DIK_NUMPAD9 0x49 +#define DIK_SUBTRACT 0x4A /* - on numeric keypad */ +#define DIK_NUMPAD4 0x4B +#define DIK_NUMPAD5 0x4C +#define DIK_NUMPAD6 0x4D +#define DIK_ADD 0x4E /* + on numeric keypad */ +#define DIK_NUMPAD1 0x4F +#define DIK_NUMPAD2 0x50 +#define DIK_NUMPAD3 0x51 +#define DIK_NUMPAD0 0x52 +#define DIK_DECIMAL 0x53 /* . on numeric keypad */ +#define DIK_OEM_102 0x56 /* <> or \| on RT 102-key keyboard (Non-U.S.) */ +#define DIK_F11 0x57 +#define DIK_F12 0x58 +#define DIK_F13 0x64 /* (NEC PC98) */ +#define DIK_F14 0x65 /* (NEC PC98) */ +#define DIK_F15 0x66 /* (NEC PC98) */ +#define DIK_KANA 0x70 /* (Japanese keyboard) */ +#define DIK_ABNT_C1 0x73 /* /? on Brazilian keyboard */ +#define DIK_CONVERT 0x79 /* (Japanese keyboard) */ +#define DIK_NOCONVERT 0x7B /* (Japanese keyboard) */ +#define DIK_YEN 0x7D /* (Japanese keyboard) */ +#define DIK_ABNT_C2 0x7E /* Numpad . on Brazilian keyboard */ +#define DIK_NUMPADEQUALS 0x8D /* = on numeric keypad (NEC PC98) */ +#define DIK_PREVTRACK 0x90 /* Previous Track (DIK_CIRCUMFLEX on Japanese keyboard) */ +#define DIK_AT 0x91 /* (NEC PC98) */ +#define DIK_COLON 0x92 /* (NEC PC98) */ +#define DIK_UNDERLINE 0x93 /* (NEC PC98) */ +#define DIK_KANJI 0x94 /* (Japanese keyboard) */ +#define DIK_STOP 0x95 /* (NEC PC98) */ +#define DIK_AX 0x96 /* (Japan AX) */ +#define DIK_UNLABELED 0x97 /* (J3100) */ +#define DIK_NEXTTRACK 0x99 /* Next Track */ +#define DIK_NUMPADENTER 0x9C /* Enter on numeric keypad */ +#define DIK_RCONTROL 0x9D +#define DIK_MUTE 0xA0 /* Mute */ +#define DIK_CALCULATOR 0xA1 /* Calculator */ +#define DIK_PLAYPAUSE 0xA2 /* Play / Pause */ +#define DIK_MEDIASTOP 0xA4 /* Media Stop */ +#define DIK_VOLUMEDOWN 0xAE /* Volume - */ +#define DIK_VOLUMEUP 0xB0 /* Volume + */ +#define DIK_WEBHOME 0xB2 /* Web home */ +#define DIK_NUMPADCOMMA 0xB3 /* , on numeric keypad (NEC PC98) */ +#define DIK_DIVIDE 0xB5 /* / on numeric keypad */ +#define DIK_SYSRQ 0xB7 +#define DIK_RMENU 0xB8 /* right Alt */ +#define DIK_PAUSE 0xC5 /* Pause */ +#define DIK_HOME 0xC7 /* Home on arrow keypad */ +#define DIK_UP 0xC8 /* UpArrow on arrow keypad */ +#define DIK_PRIOR 0xC9 /* PgUp on arrow keypad */ +#define DIK_LEFT 0xCB /* LeftArrow on arrow keypad */ +#define DIK_RIGHT 0xCD /* RightArrow on arrow keypad */ +#define DIK_END 0xCF /* End on arrow keypad */ +#define DIK_DOWN 0xD0 /* DownArrow on arrow keypad */ +#define DIK_NEXT 0xD1 /* PgDn on arrow keypad */ +#define DIK_INSERT 0xD2 /* Insert on arrow keypad */ +#define DIK_DELETE 0xD3 /* Delete on arrow keypad */ +#define DIK_LWIN 0xDB /* Left Windows key */ +#define DIK_RWIN 0xDC /* Right Windows key */ +#define DIK_APPS 0xDD /* AppMenu key */ +#define DIK_POWER 0xDE /* System Power */ +#define DIK_SLEEP 0xDF /* System Sleep */ +#define DIK_WAKE 0xE3 /* System Wake */ +#define DIK_WEBSEARCH 0xE5 /* Web Search */ +#define DIK_WEBFAVORITES 0xE6 /* Web Favorites */ +#define DIK_WEBREFRESH 0xE7 /* Web Refresh */ +#define DIK_WEBSTOP 0xE8 /* Web Stop */ +#define DIK_WEBFORWARD 0xE9 /* Web Forward */ +#define DIK_WEBBACK 0xEA /* Web Back */ +#define DIK_MYCOMPUTER 0xEB /* My Computer */ +#define DIK_MAIL 0xEC /* Mail */ +#define DIK_MEDIASELECT 0xED /* Media Select */ + +/* + * Alternate names for keys, to facilitate transition from DOS. + */ +#define DIK_BACKSPACE DIK_BACK /* backspace */ +#define DIK_NUMPADSTAR DIK_MULTIPLY /* * on numeric keypad */ +#define DIK_LALT DIK_LMENU /* left Alt */ +#define DIK_CAPSLOCK DIK_CAPITAL /* CapsLock */ +#define DIK_NUMPADMINUS DIK_SUBTRACT /* - on numeric keypad */ +#define DIK_NUMPADPLUS DIK_ADD /* + on numeric keypad */ +#define DIK_NUMPADPERIOD DIK_DECIMAL /* . on numeric keypad */ +#define DIK_NUMPADSLASH DIK_DIVIDE /* / on numeric keypad */ +#define DIK_RALT DIK_RMENU /* right Alt */ +#define DIK_UPARROW DIK_UP /* UpArrow on arrow keypad */ +#define DIK_PGUP DIK_PRIOR /* PgUp on arrow keypad */ +#define DIK_LEFTARROW DIK_LEFT /* LeftArrow on arrow keypad */ +#define DIK_RIGHTARROW DIK_RIGHT /* RightArrow on arrow keypad */ +#define DIK_DOWNARROW DIK_DOWN /* DownArrow on arrow keypad */ +#define DIK_PGDN DIK_NEXT /* PgDn on arrow keypad */ + +/* + * Alternate names for keys originally not used on US keyboards. + */ +#define DIK_CIRCUMFLEX DIK_PREVTRACK /* Japanese keyboard */ + +#endif /* DIJ_RINGZERO */ + +/**************************************************************************** + * + * Joystick + * + ****************************************************************************/ + +#ifndef DIJ_RINGZERO + +typedef struct DIJOYSTATE { + LONG lX; /* x-axis position */ + LONG lY; /* y-axis position */ + LONG lZ; /* z-axis position */ + LONG lRx; /* x-axis rotation */ + LONG lRy; /* y-axis rotation */ + LONG lRz; /* z-axis rotation */ + LONG rglSlider[2]; /* extra axes positions */ + DWORD rgdwPOV[4]; /* POV directions */ + BYTE rgbButtons[32]; /* 32 buttons */ +} DIJOYSTATE, *LPDIJOYSTATE; + +typedef struct DIJOYSTATE2 { + LONG lX; /* x-axis position */ + LONG lY; /* y-axis position */ + LONG lZ; /* z-axis position */ + LONG lRx; /* x-axis rotation */ + LONG lRy; /* y-axis rotation */ + LONG lRz; /* z-axis rotation */ + LONG rglSlider[2]; /* extra axes positions */ + DWORD rgdwPOV[4]; /* POV directions */ + BYTE rgbButtons[128]; /* 128 buttons */ + LONG lVX; /* x-axis velocity */ + LONG lVY; /* y-axis velocity */ + LONG lVZ; /* z-axis velocity */ + LONG lVRx; /* x-axis angular velocity */ + LONG lVRy; /* y-axis angular velocity */ + LONG lVRz; /* z-axis angular velocity */ + LONG rglVSlider[2]; /* extra axes velocities */ + LONG lAX; /* x-axis acceleration */ + LONG lAY; /* y-axis acceleration */ + LONG lAZ; /* z-axis acceleration */ + LONG lARx; /* x-axis angular acceleration */ + LONG lARy; /* y-axis angular acceleration */ + LONG lARz; /* z-axis angular acceleration */ + LONG rglASlider[2]; /* extra axes accelerations */ + LONG lFX; /* x-axis force */ + LONG lFY; /* y-axis force */ + LONG lFZ; /* z-axis force */ + LONG lFRx; /* x-axis torque */ + LONG lFRy; /* y-axis torque */ + LONG lFRz; /* z-axis torque */ + LONG rglFSlider[2]; /* extra axes forces */ +} DIJOYSTATE2, *LPDIJOYSTATE2; + +#define DIJOFS_X FIELD_OFFSET(DIJOYSTATE, lX) +#define DIJOFS_Y FIELD_OFFSET(DIJOYSTATE, lY) +#define DIJOFS_Z FIELD_OFFSET(DIJOYSTATE, lZ) +#define DIJOFS_RX FIELD_OFFSET(DIJOYSTATE, lRx) +#define DIJOFS_RY FIELD_OFFSET(DIJOYSTATE, lRy) +#define DIJOFS_RZ FIELD_OFFSET(DIJOYSTATE, lRz) +#define DIJOFS_SLIDER(n) (FIELD_OFFSET(DIJOYSTATE, rglSlider) + \ + (n) * sizeof(LONG)) +#define DIJOFS_POV(n) (FIELD_OFFSET(DIJOYSTATE, rgdwPOV) + \ + (n) * sizeof(DWORD)) +#define DIJOFS_BUTTON(n) (FIELD_OFFSET(DIJOYSTATE, rgbButtons) + (n)) +#define DIJOFS_BUTTON0 DIJOFS_BUTTON(0) +#define DIJOFS_BUTTON1 DIJOFS_BUTTON(1) +#define DIJOFS_BUTTON2 DIJOFS_BUTTON(2) +#define DIJOFS_BUTTON3 DIJOFS_BUTTON(3) +#define DIJOFS_BUTTON4 DIJOFS_BUTTON(4) +#define DIJOFS_BUTTON5 DIJOFS_BUTTON(5) +#define DIJOFS_BUTTON6 DIJOFS_BUTTON(6) +#define DIJOFS_BUTTON7 DIJOFS_BUTTON(7) +#define DIJOFS_BUTTON8 DIJOFS_BUTTON(8) +#define DIJOFS_BUTTON9 DIJOFS_BUTTON(9) +#define DIJOFS_BUTTON10 DIJOFS_BUTTON(10) +#define DIJOFS_BUTTON11 DIJOFS_BUTTON(11) +#define DIJOFS_BUTTON12 DIJOFS_BUTTON(12) +#define DIJOFS_BUTTON13 DIJOFS_BUTTON(13) +#define DIJOFS_BUTTON14 DIJOFS_BUTTON(14) +#define DIJOFS_BUTTON15 DIJOFS_BUTTON(15) +#define DIJOFS_BUTTON16 DIJOFS_BUTTON(16) +#define DIJOFS_BUTTON17 DIJOFS_BUTTON(17) +#define DIJOFS_BUTTON18 DIJOFS_BUTTON(18) +#define DIJOFS_BUTTON19 DIJOFS_BUTTON(19) +#define DIJOFS_BUTTON20 DIJOFS_BUTTON(20) +#define DIJOFS_BUTTON21 DIJOFS_BUTTON(21) +#define DIJOFS_BUTTON22 DIJOFS_BUTTON(22) +#define DIJOFS_BUTTON23 DIJOFS_BUTTON(23) +#define DIJOFS_BUTTON24 DIJOFS_BUTTON(24) +#define DIJOFS_BUTTON25 DIJOFS_BUTTON(25) +#define DIJOFS_BUTTON26 DIJOFS_BUTTON(26) +#define DIJOFS_BUTTON27 DIJOFS_BUTTON(27) +#define DIJOFS_BUTTON28 DIJOFS_BUTTON(28) +#define DIJOFS_BUTTON29 DIJOFS_BUTTON(29) +#define DIJOFS_BUTTON30 DIJOFS_BUTTON(30) +#define DIJOFS_BUTTON31 DIJOFS_BUTTON(31) + + +#endif /* DIJ_RINGZERO */ + +/**************************************************************************** + * + * IDirectInput + * + ****************************************************************************/ + +#ifndef DIJ_RINGZERO + +#define DIENUM_STOP 0 +#define DIENUM_CONTINUE 1 + +typedef BOOL (FAR PASCAL * LPDIENUMDEVICESCALLBACKA)(LPCDIDEVICEINSTANCEA, LPVOID); +typedef BOOL (FAR PASCAL * LPDIENUMDEVICESCALLBACKW)(LPCDIDEVICEINSTANCEW, LPVOID); +#ifdef UNICODE +#define LPDIENUMDEVICESCALLBACK LPDIENUMDEVICESCALLBACKW +#else +#define LPDIENUMDEVICESCALLBACK LPDIENUMDEVICESCALLBACKA +#endif // !UNICODE +typedef BOOL (FAR PASCAL * LPDICONFIGUREDEVICESCALLBACK)(IUnknown FAR *, LPVOID); + +#define DIEDFL_ALLDEVICES 0x00000000 +#define DIEDFL_ATTACHEDONLY 0x00000001 +#if(DIRECTINPUT_VERSION >= 0x0500) +#define DIEDFL_FORCEFEEDBACK 0x00000100 +#endif /* DIRECTINPUT_VERSION >= 0x0500 */ +#if(DIRECTINPUT_VERSION >= 0x050a) +#define DIEDFL_INCLUDEALIASES 0x00010000 +#define DIEDFL_INCLUDEPHANTOMS 0x00020000 +#endif /* DIRECTINPUT_VERSION >= 0x050a */ +#if(DIRECTINPUT_VERSION >= 0x0800) +#define DIEDFL_INCLUDEHIDDEN 0x00040000 +#endif /* DIRECTINPUT_VERSION >= 0x0800 */ + + +#if(DIRECTINPUT_VERSION >= 0x0800) +typedef BOOL (FAR PASCAL * LPDIENUMDEVICESBYSEMANTICSCBA)(LPCDIDEVICEINSTANCEA, LPDIRECTINPUTDEVICE8A, DWORD, DWORD, LPVOID); +typedef BOOL (FAR PASCAL * LPDIENUMDEVICESBYSEMANTICSCBW)(LPCDIDEVICEINSTANCEW, LPDIRECTINPUTDEVICE8W, DWORD, DWORD, LPVOID); +#ifdef UNICODE +#define LPDIENUMDEVICESBYSEMANTICSCB LPDIENUMDEVICESBYSEMANTICSCBW +#else +#define LPDIENUMDEVICESBYSEMANTICSCB LPDIENUMDEVICESBYSEMANTICSCBA +#endif // !UNICODE +#endif /* DIRECTINPUT_VERSION >= 0x0800 */ + +#if(DIRECTINPUT_VERSION >= 0x0800) +#define DIEDBS_MAPPEDPRI1 0x00000001 +#define DIEDBS_MAPPEDPRI2 0x00000002 +#define DIEDBS_RECENTDEVICE 0x00000010 +#define DIEDBS_NEWDEVICE 0x00000020 +#endif /* DIRECTINPUT_VERSION >= 0x0800 */ + +#if(DIRECTINPUT_VERSION >= 0x0800) +#define DIEDBSFL_ATTACHEDONLY 0x00000000 +#define DIEDBSFL_THISUSER 0x00000010 +#define DIEDBSFL_FORCEFEEDBACK DIEDFL_FORCEFEEDBACK +#define DIEDBSFL_AVAILABLEDEVICES 0x00001000 +#define DIEDBSFL_MULTIMICEKEYBOARDS 0x00002000 +#define DIEDBSFL_NONGAMINGDEVICES 0x00004000 +#define DIEDBSFL_VALID 0x00007110 +#endif /* DIRECTINPUT_VERSION >= 0x0800 */ + +#undef INTERFACE +#define INTERFACE IDirectInputW + +DECLARE_INTERFACE_(IDirectInputW, IUnknown) +{ + /*** IUnknown methods ***/ + STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID * ppvObj) PURE; + STDMETHOD_(ULONG,AddRef)(THIS) PURE; + STDMETHOD_(ULONG,Release)(THIS) PURE; + + /*** IDirectInputW methods ***/ + STDMETHOD(CreateDevice)(THIS_ REFGUID,LPDIRECTINPUTDEVICEW *,LPUNKNOWN) PURE; + STDMETHOD(EnumDevices)(THIS_ DWORD,LPDIENUMDEVICESCALLBACKW,LPVOID,DWORD) PURE; + STDMETHOD(GetDeviceStatus)(THIS_ REFGUID) PURE; + STDMETHOD(RunControlPanel)(THIS_ HWND,DWORD) PURE; + STDMETHOD(Initialize)(THIS_ HINSTANCE,DWORD) PURE; +}; + +typedef struct IDirectInputW *LPDIRECTINPUTW; + +#undef INTERFACE +#define INTERFACE IDirectInputA + +DECLARE_INTERFACE_(IDirectInputA, IUnknown) +{ + /*** IUnknown methods ***/ + STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID * ppvObj) PURE; + STDMETHOD_(ULONG,AddRef)(THIS) PURE; + STDMETHOD_(ULONG,Release)(THIS) PURE; + + /*** IDirectInputA methods ***/ + STDMETHOD(CreateDevice)(THIS_ REFGUID,LPDIRECTINPUTDEVICEA *,LPUNKNOWN) PURE; + STDMETHOD(EnumDevices)(THIS_ DWORD,LPDIENUMDEVICESCALLBACKA,LPVOID,DWORD) PURE; + STDMETHOD(GetDeviceStatus)(THIS_ REFGUID) PURE; + STDMETHOD(RunControlPanel)(THIS_ HWND,DWORD) PURE; + STDMETHOD(Initialize)(THIS_ HINSTANCE,DWORD) PURE; +}; + +typedef struct IDirectInputA *LPDIRECTINPUTA; + +#ifdef UNICODE +#define IID_IDirectInput IID_IDirectInputW +#define IDirectInput IDirectInputW +#define IDirectInputVtbl IDirectInputWVtbl +#else +#define IID_IDirectInput IID_IDirectInputA +#define IDirectInput IDirectInputA +#define IDirectInputVtbl IDirectInputAVtbl +#endif +typedef struct IDirectInput *LPDIRECTINPUT; + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectInput_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) +#define IDirectInput_AddRef(p) (p)->lpVtbl->AddRef(p) +#define IDirectInput_Release(p) (p)->lpVtbl->Release(p) +#define IDirectInput_CreateDevice(p,a,b,c) (p)->lpVtbl->CreateDevice(p,a,b,c) +#define IDirectInput_EnumDevices(p,a,b,c,d) (p)->lpVtbl->EnumDevices(p,a,b,c,d) +#define IDirectInput_GetDeviceStatus(p,a) (p)->lpVtbl->GetDeviceStatus(p,a) +#define IDirectInput_RunControlPanel(p,a,b) (p)->lpVtbl->RunControlPanel(p,a,b) +#define IDirectInput_Initialize(p,a,b) (p)->lpVtbl->Initialize(p,a,b) +#else +#define IDirectInput_QueryInterface(p,a,b) (p)->QueryInterface(a,b) +#define IDirectInput_AddRef(p) (p)->AddRef() +#define IDirectInput_Release(p) (p)->Release() +#define IDirectInput_CreateDevice(p,a,b,c) (p)->CreateDevice(a,b,c) +#define IDirectInput_EnumDevices(p,a,b,c,d) (p)->EnumDevices(a,b,c,d) +#define IDirectInput_GetDeviceStatus(p,a) (p)->GetDeviceStatus(a) +#define IDirectInput_RunControlPanel(p,a,b) (p)->RunControlPanel(a,b) +#define IDirectInput_Initialize(p,a,b) (p)->Initialize(a,b) +#endif + +#undef INTERFACE +#define INTERFACE IDirectInput2W + +DECLARE_INTERFACE_(IDirectInput2W, IDirectInputW) +{ + /*** IUnknown methods ***/ + STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID * ppvObj) PURE; + STDMETHOD_(ULONG,AddRef)(THIS) PURE; + STDMETHOD_(ULONG,Release)(THIS) PURE; + + /*** IDirectInputW methods ***/ + STDMETHOD(CreateDevice)(THIS_ REFGUID,LPDIRECTINPUTDEVICEW *,LPUNKNOWN) PURE; + STDMETHOD(EnumDevices)(THIS_ DWORD,LPDIENUMDEVICESCALLBACKW,LPVOID,DWORD) PURE; + STDMETHOD(GetDeviceStatus)(THIS_ REFGUID) PURE; + STDMETHOD(RunControlPanel)(THIS_ HWND,DWORD) PURE; + STDMETHOD(Initialize)(THIS_ HINSTANCE,DWORD) PURE; + + /*** IDirectInput2W methods ***/ + STDMETHOD(FindDevice)(THIS_ REFGUID,LPCWSTR,LPGUID) PURE; +}; + +typedef struct IDirectInput2W *LPDIRECTINPUT2W; + +#undef INTERFACE +#define INTERFACE IDirectInput2A + +DECLARE_INTERFACE_(IDirectInput2A, IDirectInputA) +{ + /*** IUnknown methods ***/ + STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID * ppvObj) PURE; + STDMETHOD_(ULONG,AddRef)(THIS) PURE; + STDMETHOD_(ULONG,Release)(THIS) PURE; + + /*** IDirectInputA methods ***/ + STDMETHOD(CreateDevice)(THIS_ REFGUID,LPDIRECTINPUTDEVICEA *,LPUNKNOWN) PURE; + STDMETHOD(EnumDevices)(THIS_ DWORD,LPDIENUMDEVICESCALLBACKA,LPVOID,DWORD) PURE; + STDMETHOD(GetDeviceStatus)(THIS_ REFGUID) PURE; + STDMETHOD(RunControlPanel)(THIS_ HWND,DWORD) PURE; + STDMETHOD(Initialize)(THIS_ HINSTANCE,DWORD) PURE; + + /*** IDirectInput2A methods ***/ + STDMETHOD(FindDevice)(THIS_ REFGUID,LPCSTR,LPGUID) PURE; +}; + +typedef struct IDirectInput2A *LPDIRECTINPUT2A; + +#ifdef UNICODE +#define IID_IDirectInput2 IID_IDirectInput2W +#define IDirectInput2 IDirectInput2W +#define IDirectInput2Vtbl IDirectInput2WVtbl +#else +#define IID_IDirectInput2 IID_IDirectInput2A +#define IDirectInput2 IDirectInput2A +#define IDirectInput2Vtbl IDirectInput2AVtbl +#endif +typedef struct IDirectInput2 *LPDIRECTINPUT2; + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectInput2_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) +#define IDirectInput2_AddRef(p) (p)->lpVtbl->AddRef(p) +#define IDirectInput2_Release(p) (p)->lpVtbl->Release(p) +#define IDirectInput2_CreateDevice(p,a,b,c) (p)->lpVtbl->CreateDevice(p,a,b,c) +#define IDirectInput2_EnumDevices(p,a,b,c,d) (p)->lpVtbl->EnumDevices(p,a,b,c,d) +#define IDirectInput2_GetDeviceStatus(p,a) (p)->lpVtbl->GetDeviceStatus(p,a) +#define IDirectInput2_RunControlPanel(p,a,b) (p)->lpVtbl->RunControlPanel(p,a,b) +#define IDirectInput2_Initialize(p,a,b) (p)->lpVtbl->Initialize(p,a,b) +#define IDirectInput2_FindDevice(p,a,b,c) (p)->lpVtbl->FindDevice(p,a,b,c) +#else +#define IDirectInput2_QueryInterface(p,a,b) (p)->QueryInterface(a,b) +#define IDirectInput2_AddRef(p) (p)->AddRef() +#define IDirectInput2_Release(p) (p)->Release() +#define IDirectInput2_CreateDevice(p,a,b,c) (p)->CreateDevice(a,b,c) +#define IDirectInput2_EnumDevices(p,a,b,c,d) (p)->EnumDevices(a,b,c,d) +#define IDirectInput2_GetDeviceStatus(p,a) (p)->GetDeviceStatus(a) +#define IDirectInput2_RunControlPanel(p,a,b) (p)->RunControlPanel(a,b) +#define IDirectInput2_Initialize(p,a,b) (p)->Initialize(a,b) +#define IDirectInput2_FindDevice(p,a,b,c) (p)->FindDevice(a,b,c) +#endif + + +#undef INTERFACE +#define INTERFACE IDirectInput7W + +DECLARE_INTERFACE_(IDirectInput7W, IDirectInput2W) +{ + /*** IUnknown methods ***/ + STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID * ppvObj) PURE; + STDMETHOD_(ULONG,AddRef)(THIS) PURE; + STDMETHOD_(ULONG,Release)(THIS) PURE; + + /*** IDirectInput2W methods ***/ + STDMETHOD(CreateDevice)(THIS_ REFGUID,LPDIRECTINPUTDEVICEW *,LPUNKNOWN) PURE; + STDMETHOD(EnumDevices)(THIS_ DWORD,LPDIENUMDEVICESCALLBACKW,LPVOID,DWORD) PURE; + STDMETHOD(GetDeviceStatus)(THIS_ REFGUID) PURE; + STDMETHOD(RunControlPanel)(THIS_ HWND,DWORD) PURE; + STDMETHOD(Initialize)(THIS_ HINSTANCE,DWORD) PURE; + STDMETHOD(FindDevice)(THIS_ REFGUID,LPCWSTR,LPGUID) PURE; + + /*** IDirectInput7W methods ***/ + STDMETHOD(CreateDeviceEx)(THIS_ REFGUID,REFIID,LPVOID *,LPUNKNOWN) PURE; +}; + +typedef struct IDirectInput7W *LPDIRECTINPUT7W; + +#undef INTERFACE +#define INTERFACE IDirectInput7A + +DECLARE_INTERFACE_(IDirectInput7A, IDirectInput2A) +{ + /*** IUnknown methods ***/ + STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID * ppvObj) PURE; + STDMETHOD_(ULONG,AddRef)(THIS) PURE; + STDMETHOD_(ULONG,Release)(THIS) PURE; + + /*** IDirectInput2A methods ***/ + STDMETHOD(CreateDevice)(THIS_ REFGUID,LPDIRECTINPUTDEVICEA *,LPUNKNOWN) PURE; + STDMETHOD(EnumDevices)(THIS_ DWORD,LPDIENUMDEVICESCALLBACKA,LPVOID,DWORD) PURE; + STDMETHOD(GetDeviceStatus)(THIS_ REFGUID) PURE; + STDMETHOD(RunControlPanel)(THIS_ HWND,DWORD) PURE; + STDMETHOD(Initialize)(THIS_ HINSTANCE,DWORD) PURE; + STDMETHOD(FindDevice)(THIS_ REFGUID,LPCSTR,LPGUID) PURE; + + /*** IDirectInput7A methods ***/ + STDMETHOD(CreateDeviceEx)(THIS_ REFGUID,REFIID,LPVOID *,LPUNKNOWN) PURE; +}; + +typedef struct IDirectInput7A *LPDIRECTINPUT7A; + +#ifdef UNICODE +#define IID_IDirectInput7 IID_IDirectInput7W +#define IDirectInput7 IDirectInput7W +#define IDirectInput7Vtbl IDirectInput7WVtbl +#else +#define IID_IDirectInput7 IID_IDirectInput7A +#define IDirectInput7 IDirectInput7A +#define IDirectInput7Vtbl IDirectInput7AVtbl +#endif +typedef struct IDirectInput7 *LPDIRECTINPUT7; + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectInput7_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) +#define IDirectInput7_AddRef(p) (p)->lpVtbl->AddRef(p) +#define IDirectInput7_Release(p) (p)->lpVtbl->Release(p) +#define IDirectInput7_CreateDevice(p,a,b,c) (p)->lpVtbl->CreateDevice(p,a,b,c) +#define IDirectInput7_EnumDevices(p,a,b,c,d) (p)->lpVtbl->EnumDevices(p,a,b,c,d) +#define IDirectInput7_GetDeviceStatus(p,a) (p)->lpVtbl->GetDeviceStatus(p,a) +#define IDirectInput7_RunControlPanel(p,a,b) (p)->lpVtbl->RunControlPanel(p,a,b) +#define IDirectInput7_Initialize(p,a,b) (p)->lpVtbl->Initialize(p,a,b) +#define IDirectInput7_FindDevice(p,a,b,c) (p)->lpVtbl->FindDevice(p,a,b,c) +#define IDirectInput7_CreateDeviceEx(p,a,b,c,d) (p)->lpVtbl->CreateDeviceEx(p,a,b,c,d) +#else +#define IDirectInput7_QueryInterface(p,a,b) (p)->QueryInterface(a,b) +#define IDirectInput7_AddRef(p) (p)->AddRef() +#define IDirectInput7_Release(p) (p)->Release() +#define IDirectInput7_CreateDevice(p,a,b,c) (p)->CreateDevice(a,b,c) +#define IDirectInput7_EnumDevices(p,a,b,c,d) (p)->EnumDevices(a,b,c,d) +#define IDirectInput7_GetDeviceStatus(p,a) (p)->GetDeviceStatus(a) +#define IDirectInput7_RunControlPanel(p,a,b) (p)->RunControlPanel(a,b) +#define IDirectInput7_Initialize(p,a,b) (p)->Initialize(a,b) +#define IDirectInput7_FindDevice(p,a,b,c) (p)->FindDevice(a,b,c) +#define IDirectInput7_CreateDeviceEx(p,a,b,c,d) (p)->CreateDeviceEx(a,b,c,d) +#endif + +#if(DIRECTINPUT_VERSION >= 0x0800) +#undef INTERFACE +#define INTERFACE IDirectInput8W + +DECLARE_INTERFACE_(IDirectInput8W, IUnknown) +{ + /*** IUnknown methods ***/ + STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID * ppvObj) PURE; + STDMETHOD_(ULONG,AddRef)(THIS) PURE; + STDMETHOD_(ULONG,Release)(THIS) PURE; + + /*** IDirectInput8W methods ***/ + STDMETHOD(CreateDevice)(THIS_ REFGUID,LPDIRECTINPUTDEVICE8W *,LPUNKNOWN) PURE; + STDMETHOD(EnumDevices)(THIS_ DWORD,LPDIENUMDEVICESCALLBACKW,LPVOID,DWORD) PURE; + STDMETHOD(GetDeviceStatus)(THIS_ REFGUID) PURE; + STDMETHOD(RunControlPanel)(THIS_ HWND,DWORD) PURE; + STDMETHOD(Initialize)(THIS_ HINSTANCE,DWORD) PURE; + STDMETHOD(FindDevice)(THIS_ REFGUID,LPCWSTR,LPGUID) PURE; + STDMETHOD(EnumDevicesBySemantics)(THIS_ LPCWSTR,LPDIACTIONFORMATW,LPDIENUMDEVICESBYSEMANTICSCBW,LPVOID,DWORD) PURE; + STDMETHOD(ConfigureDevices)(THIS_ LPDICONFIGUREDEVICESCALLBACK,LPDICONFIGUREDEVICESPARAMSW,DWORD,LPVOID) PURE; +}; + +typedef struct IDirectInput8W *LPDIRECTINPUT8W; + +#undef INTERFACE +#define INTERFACE IDirectInput8A + +DECLARE_INTERFACE_(IDirectInput8A, IUnknown) +{ + /*** IUnknown methods ***/ + STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID * ppvObj) PURE; + STDMETHOD_(ULONG,AddRef)(THIS) PURE; + STDMETHOD_(ULONG,Release)(THIS) PURE; + + /*** IDirectInput8A methods ***/ + STDMETHOD(CreateDevice)(THIS_ REFGUID,LPDIRECTINPUTDEVICE8A *,LPUNKNOWN) PURE; + STDMETHOD(EnumDevices)(THIS_ DWORD,LPDIENUMDEVICESCALLBACKA,LPVOID,DWORD) PURE; + STDMETHOD(GetDeviceStatus)(THIS_ REFGUID) PURE; + STDMETHOD(RunControlPanel)(THIS_ HWND,DWORD) PURE; + STDMETHOD(Initialize)(THIS_ HINSTANCE,DWORD) PURE; + STDMETHOD(FindDevice)(THIS_ REFGUID,LPCSTR,LPGUID) PURE; + STDMETHOD(EnumDevicesBySemantics)(THIS_ LPCSTR,LPDIACTIONFORMATA,LPDIENUMDEVICESBYSEMANTICSCBA,LPVOID,DWORD) PURE; + STDMETHOD(ConfigureDevices)(THIS_ LPDICONFIGUREDEVICESCALLBACK,LPDICONFIGUREDEVICESPARAMSA,DWORD,LPVOID) PURE; +}; + +typedef struct IDirectInput8A *LPDIRECTINPUT8A; + +#ifdef UNICODE +#define IID_IDirectInput8 IID_IDirectInput8W +#define IDirectInput8 IDirectInput8W +#define IDirectInput8Vtbl IDirectInput8WVtbl +#else +#define IID_IDirectInput8 IID_IDirectInput8A +#define IDirectInput8 IDirectInput8A +#define IDirectInput8Vtbl IDirectInput8AVtbl +#endif +typedef struct IDirectInput8 *LPDIRECTINPUT8; + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectInput8_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) +#define IDirectInput8_AddRef(p) (p)->lpVtbl->AddRef(p) +#define IDirectInput8_Release(p) (p)->lpVtbl->Release(p) +#define IDirectInput8_CreateDevice(p,a,b,c) (p)->lpVtbl->CreateDevice(p,a,b,c) +#define IDirectInput8_EnumDevices(p,a,b,c,d) (p)->lpVtbl->EnumDevices(p,a,b,c,d) +#define IDirectInput8_GetDeviceStatus(p,a) (p)->lpVtbl->GetDeviceStatus(p,a) +#define IDirectInput8_RunControlPanel(p,a,b) (p)->lpVtbl->RunControlPanel(p,a,b) +#define IDirectInput8_Initialize(p,a,b) (p)->lpVtbl->Initialize(p,a,b) +#define IDirectInput8_FindDevice(p,a,b,c) (p)->lpVtbl->FindDevice(p,a,b,c) +#define IDirectInput8_EnumDevicesBySemantics(p,a,b,c,d,e) (p)->lpVtbl->EnumDevicesBySemantics(p,a,b,c,d,e) +#define IDirectInput8_ConfigureDevices(p,a,b,c,d) (p)->lpVtbl->ConfigureDevices(p,a,b,c,d) +#else +#define IDirectInput8_QueryInterface(p,a,b) (p)->QueryInterface(a,b) +#define IDirectInput8_AddRef(p) (p)->AddRef() +#define IDirectInput8_Release(p) (p)->Release() +#define IDirectInput8_CreateDevice(p,a,b,c) (p)->CreateDevice(a,b,c) +#define IDirectInput8_EnumDevices(p,a,b,c,d) (p)->EnumDevices(a,b,c,d) +#define IDirectInput8_GetDeviceStatus(p,a) (p)->GetDeviceStatus(a) +#define IDirectInput8_RunControlPanel(p,a,b) (p)->RunControlPanel(a,b) +#define IDirectInput8_Initialize(p,a,b) (p)->Initialize(a,b) +#define IDirectInput8_FindDevice(p,a,b,c) (p)->FindDevice(a,b,c) +#define IDirectInput8_EnumDevicesBySemantics(p,a,b,c,d,e) (p)->EnumDevicesBySemantics(a,b,c,d,e) +#define IDirectInput8_ConfigureDevices(p,a,b,c,d) (p)->ConfigureDevices(a,b,c,d) +#endif +#endif /* DIRECTINPUT_VERSION >= 0x0800 */ + +#if DIRECTINPUT_VERSION > 0x0700 + +extern HRESULT WINAPI DirectInput8Create(HINSTANCE hinst, DWORD dwVersion, REFIID riidltf, LPVOID *ppvOut, LPUNKNOWN punkOuter); + +#else +extern HRESULT WINAPI DirectInputCreateA(HINSTANCE hinst, DWORD dwVersion, LPDIRECTINPUTA *ppDI, LPUNKNOWN punkOuter); +extern HRESULT WINAPI DirectInputCreateW(HINSTANCE hinst, DWORD dwVersion, LPDIRECTINPUTW *ppDI, LPUNKNOWN punkOuter); +#ifdef UNICODE +#define DirectInputCreate DirectInputCreateW +#else +#define DirectInputCreate DirectInputCreateA +#endif // !UNICODE + +extern HRESULT WINAPI DirectInputCreateEx(HINSTANCE hinst, DWORD dwVersion, REFIID riidltf, LPVOID *ppvOut, LPUNKNOWN punkOuter); + +#endif /* DIRECTINPUT_VERSION > 0x700 */ + +#endif /* DIJ_RINGZERO */ + + +/**************************************************************************** + * + * Return Codes + * + ****************************************************************************/ + +/* + * The operation completed successfully. + */ +#define DI_OK S_OK + +/* + * The device exists but is not currently attached. + */ +#define DI_NOTATTACHED S_FALSE + +/* + * The device buffer overflowed. Some input was lost. + */ +#define DI_BUFFEROVERFLOW S_FALSE + +/* + * The change in device properties had no effect. + */ +#define DI_PROPNOEFFECT S_FALSE + +/* + * The operation had no effect. + */ +#define DI_NOEFFECT S_FALSE + +/* + * The device is a polled device. As a result, device buffering + * will not collect any data and event notifications will not be + * signalled until GetDeviceState is called. + */ +#define DI_POLLEDDEVICE ((HRESULT)0x00000002L) + +/* + * The parameters of the effect were successfully updated by + * IDirectInputEffect::SetParameters, but the effect was not + * downloaded because the device is not exclusively acquired + * or because the DIEP_NODOWNLOAD flag was passed. + */ +#define DI_DOWNLOADSKIPPED ((HRESULT)0x00000003L) + +/* + * The parameters of the effect were successfully updated by + * IDirectInputEffect::SetParameters, but in order to change + * the parameters, the effect needed to be restarted. + */ +#define DI_EFFECTRESTARTED ((HRESULT)0x00000004L) + +/* + * The parameters of the effect were successfully updated by + * IDirectInputEffect::SetParameters, but some of them were + * beyond the capabilities of the device and were truncated. + */ +#define DI_TRUNCATED ((HRESULT)0x00000008L) + +/* + * The settings have been successfully applied but could not be + * persisted. + */ +#define DI_SETTINGSNOTSAVED ((HRESULT)0x0000000BL) + +/* + * Equal to DI_EFFECTRESTARTED | DI_TRUNCATED. + */ +#define DI_TRUNCATEDANDRESTARTED ((HRESULT)0x0000000CL) + +/* + * A SUCCESS code indicating that settings cannot be modified. + */ +#define DI_WRITEPROTECT ((HRESULT)0x00000013L) + +/* + * The application requires a newer version of DirectInput. + */ +#define DIERR_OLDDIRECTINPUTVERSION \ + MAKE_HRESULT(SEVERITY_ERROR, FACILITY_WIN32, ERROR_OLD_WIN_VERSION) + +/* + * The application was written for an unsupported prerelease version + * of DirectInput. + */ +#define DIERR_BETADIRECTINPUTVERSION \ + MAKE_HRESULT(SEVERITY_ERROR, FACILITY_WIN32, ERROR_RMODE_APP) + +/* + * The object could not be created due to an incompatible driver version + * or mismatched or incomplete driver components. + */ +#define DIERR_BADDRIVERVER \ + MAKE_HRESULT(SEVERITY_ERROR, FACILITY_WIN32, ERROR_BAD_DRIVER_LEVEL) + +/* + * The device or device instance or effect is not registered with DirectInput. + */ +#define DIERR_DEVICENOTREG REGDB_E_CLASSNOTREG + +/* + * The requested object does not exist. + */ +#define DIERR_NOTFOUND \ + MAKE_HRESULT(SEVERITY_ERROR, FACILITY_WIN32, ERROR_FILE_NOT_FOUND) + +/* + * The requested object does not exist. + */ +#define DIERR_OBJECTNOTFOUND \ + MAKE_HRESULT(SEVERITY_ERROR, FACILITY_WIN32, ERROR_FILE_NOT_FOUND) + +/* + * An invalid parameter was passed to the returning function, + * or the object was not in a state that admitted the function + * to be called. + */ +#define DIERR_INVALIDPARAM E_INVALIDARG + +/* + * The specified interface is not supported by the object + */ +#define DIERR_NOINTERFACE E_NOINTERFACE + +/* + * An undetermined error occured inside the DInput subsystem + */ +#define DIERR_GENERIC E_FAIL + +/* + * The DInput subsystem couldn't allocate sufficient memory to complete the + * caller's request. + */ +#define DIERR_OUTOFMEMORY E_OUTOFMEMORY + +/* + * The function called is not supported at this time + */ +#define DIERR_UNSUPPORTED E_NOTIMPL + +/* + * This object has not been initialized + */ +#define DIERR_NOTINITIALIZED \ + MAKE_HRESULT(SEVERITY_ERROR, FACILITY_WIN32, ERROR_NOT_READY) + +/* + * This object is already initialized + */ +#define DIERR_ALREADYINITIALIZED \ + MAKE_HRESULT(SEVERITY_ERROR, FACILITY_WIN32, ERROR_ALREADY_INITIALIZED) + +/* + * This object does not support aggregation + */ +#define DIERR_NOAGGREGATION CLASS_E_NOAGGREGATION + +/* + * Another app has a higher priority level, preventing this call from + * succeeding. + */ +#define DIERR_OTHERAPPHASPRIO E_ACCESSDENIED + +/* + * Access to the device has been lost. It must be re-acquired. + */ +#define DIERR_INPUTLOST \ + MAKE_HRESULT(SEVERITY_ERROR, FACILITY_WIN32, ERROR_READ_FAULT) + +/* + * The operation cannot be performed while the device is acquired. + */ +#define DIERR_ACQUIRED \ + MAKE_HRESULT(SEVERITY_ERROR, FACILITY_WIN32, ERROR_BUSY) + +/* + * The operation cannot be performed unless the device is acquired. + */ +#define DIERR_NOTACQUIRED \ + MAKE_HRESULT(SEVERITY_ERROR, FACILITY_WIN32, ERROR_INVALID_ACCESS) + +/* + * The specified property cannot be changed. + */ +#define DIERR_READONLY E_ACCESSDENIED + +/* + * The device already has an event notification associated with it. + */ +#define DIERR_HANDLEEXISTS E_ACCESSDENIED + +/* + * Data is not yet available. + */ +#ifndef E_PENDING +#define E_PENDING 0x8000000AL +#endif + +/* + * Unable to IDirectInputJoyConfig_Acquire because the user + * does not have sufficient privileges to change the joystick + * configuration. + */ +#define DIERR_INSUFFICIENTPRIVS 0x80040200L + +/* + * The device is full. + */ +#define DIERR_DEVICEFULL 0x80040201L + +/* + * Not all the requested information fit into the buffer. + */ +#define DIERR_MOREDATA 0x80040202L + +/* + * The effect is not downloaded. + */ +#define DIERR_NOTDOWNLOADED 0x80040203L + +/* + * The device cannot be reinitialized because there are still effects + * attached to it. + */ +#define DIERR_HASEFFECTS 0x80040204L + +/* + * The operation cannot be performed unless the device is acquired + * in DISCL_EXCLUSIVE mode. + */ +#define DIERR_NOTEXCLUSIVEACQUIRED 0x80040205L + +/* + * The effect could not be downloaded because essential information + * is missing. For example, no axes have been associated with the + * effect, or no type-specific information has been created. + */ +#define DIERR_INCOMPLETEEFFECT 0x80040206L + +/* + * Attempted to read buffered device data from a device that is + * not buffered. + */ +#define DIERR_NOTBUFFERED 0x80040207L + +/* + * An attempt was made to modify parameters of an effect while it is + * playing. Not all hardware devices support altering the parameters + * of an effect while it is playing. + */ +#define DIERR_EFFECTPLAYING 0x80040208L + +/* + * The operation could not be completed because the device is not + * plugged in. + */ +#define DIERR_UNPLUGGED 0x80040209L + +/* + * SendDeviceData failed because more information was requested + * to be sent than can be sent to the device. Some devices have + * restrictions on how much data can be sent to them. (For example, + * there might be a limit on the number of buttons that can be + * pressed at once.) + */ +#define DIERR_REPORTFULL 0x8004020AL + + +/* + * A mapper file function failed because reading or writing the user or IHV + * settings file failed. + */ +#define DIERR_MAPFILEFAIL 0x8004020BL + + +/*--- DINPUT Mapper Definitions: New for Dx8 ---*/ + + +/*--- Keyboard + Physical Keyboard Device ---*/ + +#define DIKEYBOARD_ESCAPE 0x81000401 +#define DIKEYBOARD_1 0x81000402 +#define DIKEYBOARD_2 0x81000403 +#define DIKEYBOARD_3 0x81000404 +#define DIKEYBOARD_4 0x81000405 +#define DIKEYBOARD_5 0x81000406 +#define DIKEYBOARD_6 0x81000407 +#define DIKEYBOARD_7 0x81000408 +#define DIKEYBOARD_8 0x81000409 +#define DIKEYBOARD_9 0x8100040A +#define DIKEYBOARD_0 0x8100040B +#define DIKEYBOARD_MINUS 0x8100040C /* - on main keyboard */ +#define DIKEYBOARD_EQUALS 0x8100040D +#define DIKEYBOARD_BACK 0x8100040E /* backspace */ +#define DIKEYBOARD_TAB 0x8100040F +#define DIKEYBOARD_Q 0x81000410 +#define DIKEYBOARD_W 0x81000411 +#define DIKEYBOARD_E 0x81000412 +#define DIKEYBOARD_R 0x81000413 +#define DIKEYBOARD_T 0x81000414 +#define DIKEYBOARD_Y 0x81000415 +#define DIKEYBOARD_U 0x81000416 +#define DIKEYBOARD_I 0x81000417 +#define DIKEYBOARD_O 0x81000418 +#define DIKEYBOARD_P 0x81000419 +#define DIKEYBOARD_LBRACKET 0x8100041A +#define DIKEYBOARD_RBRACKET 0x8100041B +#define DIKEYBOARD_RETURN 0x8100041C /* Enter on main keyboard */ +#define DIKEYBOARD_LCONTROL 0x8100041D +#define DIKEYBOARD_A 0x8100041E +#define DIKEYBOARD_S 0x8100041F +#define DIKEYBOARD_D 0x81000420 +#define DIKEYBOARD_F 0x81000421 +#define DIKEYBOARD_G 0x81000422 +#define DIKEYBOARD_H 0x81000423 +#define DIKEYBOARD_J 0x81000424 +#define DIKEYBOARD_K 0x81000425 +#define DIKEYBOARD_L 0x81000426 +#define DIKEYBOARD_SEMICOLON 0x81000427 +#define DIKEYBOARD_APOSTROPHE 0x81000428 +#define DIKEYBOARD_GRAVE 0x81000429 /* accent grave */ +#define DIKEYBOARD_LSHIFT 0x8100042A +#define DIKEYBOARD_BACKSLASH 0x8100042B +#define DIKEYBOARD_Z 0x8100042C +#define DIKEYBOARD_X 0x8100042D +#define DIKEYBOARD_C 0x8100042E +#define DIKEYBOARD_V 0x8100042F +#define DIKEYBOARD_B 0x81000430 +#define DIKEYBOARD_N 0x81000431 +#define DIKEYBOARD_M 0x81000432 +#define DIKEYBOARD_COMMA 0x81000433 +#define DIKEYBOARD_PERIOD 0x81000434 /* . on main keyboard */ +#define DIKEYBOARD_SLASH 0x81000435 /* / on main keyboard */ +#define DIKEYBOARD_RSHIFT 0x81000436 +#define DIKEYBOARD_MULTIPLY 0x81000437 /* * on numeric keypad */ +#define DIKEYBOARD_LMENU 0x81000438 /* left Alt */ +#define DIKEYBOARD_SPACE 0x81000439 +#define DIKEYBOARD_CAPITAL 0x8100043A +#define DIKEYBOARD_F1 0x8100043B +#define DIKEYBOARD_F2 0x8100043C +#define DIKEYBOARD_F3 0x8100043D +#define DIKEYBOARD_F4 0x8100043E +#define DIKEYBOARD_F5 0x8100043F +#define DIKEYBOARD_F6 0x81000440 +#define DIKEYBOARD_F7 0x81000441 +#define DIKEYBOARD_F8 0x81000442 +#define DIKEYBOARD_F9 0x81000443 +#define DIKEYBOARD_F10 0x81000444 +#define DIKEYBOARD_NUMLOCK 0x81000445 +#define DIKEYBOARD_SCROLL 0x81000446 /* Scroll Lock */ +#define DIKEYBOARD_NUMPAD7 0x81000447 +#define DIKEYBOARD_NUMPAD8 0x81000448 +#define DIKEYBOARD_NUMPAD9 0x81000449 +#define DIKEYBOARD_SUBTRACT 0x8100044A /* - on numeric keypad */ +#define DIKEYBOARD_NUMPAD4 0x8100044B +#define DIKEYBOARD_NUMPAD5 0x8100044C +#define DIKEYBOARD_NUMPAD6 0x8100044D +#define DIKEYBOARD_ADD 0x8100044E /* + on numeric keypad */ +#define DIKEYBOARD_NUMPAD1 0x8100044F +#define DIKEYBOARD_NUMPAD2 0x81000450 +#define DIKEYBOARD_NUMPAD3 0x81000451 +#define DIKEYBOARD_NUMPAD0 0x81000452 +#define DIKEYBOARD_DECIMAL 0x81000453 /* . on numeric keypad */ +#define DIKEYBOARD_OEM_102 0x81000456 /* <> or \| on RT 102-key keyboard (Non-U.S.) */ +#define DIKEYBOARD_F11 0x81000457 +#define DIKEYBOARD_F12 0x81000458 +#define DIKEYBOARD_F13 0x81000464 /* (NEC PC98) */ +#define DIKEYBOARD_F14 0x81000465 /* (NEC PC98) */ +#define DIKEYBOARD_F15 0x81000466 /* (NEC PC98) */ +#define DIKEYBOARD_KANA 0x81000470 /* (Japanese keyboard) */ +#define DIKEYBOARD_ABNT_C1 0x81000473 /* /? on Brazilian keyboard */ +#define DIKEYBOARD_CONVERT 0x81000479 /* (Japanese keyboard) */ +#define DIKEYBOARD_NOCONVERT 0x8100047B /* (Japanese keyboard) */ +#define DIKEYBOARD_YEN 0x8100047D /* (Japanese keyboard) */ +#define DIKEYBOARD_ABNT_C2 0x8100047E /* Numpad . on Brazilian keyboard */ +#define DIKEYBOARD_NUMPADEQUALS 0x8100048D /* = on numeric keypad (NEC PC98) */ +#define DIKEYBOARD_PREVTRACK 0x81000490 /* Previous Track (DIK_CIRCUMFLEX on Japanese keyboard) */ +#define DIKEYBOARD_AT 0x81000491 /* (NEC PC98) */ +#define DIKEYBOARD_COLON 0x81000492 /* (NEC PC98) */ +#define DIKEYBOARD_UNDERLINE 0x81000493 /* (NEC PC98) */ +#define DIKEYBOARD_KANJI 0x81000494 /* (Japanese keyboard) */ +#define DIKEYBOARD_STOP 0x81000495 /* (NEC PC98) */ +#define DIKEYBOARD_AX 0x81000496 /* (Japan AX) */ +#define DIKEYBOARD_UNLABELED 0x81000497 /* (J3100) */ +#define DIKEYBOARD_NEXTTRACK 0x81000499 /* Next Track */ +#define DIKEYBOARD_NUMPADENTER 0x8100049C /* Enter on numeric keypad */ +#define DIKEYBOARD_RCONTROL 0x8100049D +#define DIKEYBOARD_MUTE 0x810004A0 /* Mute */ +#define DIKEYBOARD_CALCULATOR 0x810004A1 /* Calculator */ +#define DIKEYBOARD_PLAYPAUSE 0x810004A2 /* Play / Pause */ +#define DIKEYBOARD_MEDIASTOP 0x810004A4 /* Media Stop */ +#define DIKEYBOARD_VOLUMEDOWN 0x810004AE /* Volume - */ +#define DIKEYBOARD_VOLUMEUP 0x810004B0 /* Volume + */ +#define DIKEYBOARD_WEBHOME 0x810004B2 /* Web home */ +#define DIKEYBOARD_NUMPADCOMMA 0x810004B3 /* , on numeric keypad (NEC PC98) */ +#define DIKEYBOARD_DIVIDE 0x810004B5 /* / on numeric keypad */ +#define DIKEYBOARD_SYSRQ 0x810004B7 +#define DIKEYBOARD_RMENU 0x810004B8 /* right Alt */ +#define DIKEYBOARD_PAUSE 0x810004C5 /* Pause */ +#define DIKEYBOARD_HOME 0x810004C7 /* Home on arrow keypad */ +#define DIKEYBOARD_UP 0x810004C8 /* UpArrow on arrow keypad */ +#define DIKEYBOARD_PRIOR 0x810004C9 /* PgUp on arrow keypad */ +#define DIKEYBOARD_LEFT 0x810004CB /* LeftArrow on arrow keypad */ +#define DIKEYBOARD_RIGHT 0x810004CD /* RightArrow on arrow keypad */ +#define DIKEYBOARD_END 0x810004CF /* End on arrow keypad */ +#define DIKEYBOARD_DOWN 0x810004D0 /* DownArrow on arrow keypad */ +#define DIKEYBOARD_NEXT 0x810004D1 /* PgDn on arrow keypad */ +#define DIKEYBOARD_INSERT 0x810004D2 /* Insert on arrow keypad */ +#define DIKEYBOARD_DELETE 0x810004D3 /* Delete on arrow keypad */ +#define DIKEYBOARD_LWIN 0x810004DB /* Left Windows key */ +#define DIKEYBOARD_RWIN 0x810004DC /* Right Windows key */ +#define DIKEYBOARD_APPS 0x810004DD /* AppMenu key */ +#define DIKEYBOARD_POWER 0x810004DE /* System Power */ +#define DIKEYBOARD_SLEEP 0x810004DF /* System Sleep */ +#define DIKEYBOARD_WAKE 0x810004E3 /* System Wake */ +#define DIKEYBOARD_WEBSEARCH 0x810004E5 /* Web Search */ +#define DIKEYBOARD_WEBFAVORITES 0x810004E6 /* Web Favorites */ +#define DIKEYBOARD_WEBREFRESH 0x810004E7 /* Web Refresh */ +#define DIKEYBOARD_WEBSTOP 0x810004E8 /* Web Stop */ +#define DIKEYBOARD_WEBFORWARD 0x810004E9 /* Web Forward */ +#define DIKEYBOARD_WEBBACK 0x810004EA /* Web Back */ +#define DIKEYBOARD_MYCOMPUTER 0x810004EB /* My Computer */ +#define DIKEYBOARD_MAIL 0x810004EC /* Mail */ +#define DIKEYBOARD_MEDIASELECT 0x810004ED /* Media Select */ + + +/*--- MOUSE + Physical Mouse Device ---*/ + +#define DIMOUSE_XAXISAB (0x82000200 |DIMOFS_X ) /* X Axis-absolute: Some mice natively report absolute coordinates */ +#define DIMOUSE_YAXISAB (0x82000200 |DIMOFS_Y ) /* Y Axis-absolute: Some mice natively report absolute coordinates */ +#define DIMOUSE_XAXIS (0x82000300 |DIMOFS_X ) /* X Axis */ +#define DIMOUSE_YAXIS (0x82000300 |DIMOFS_Y ) /* Y Axis */ +#define DIMOUSE_WHEEL (0x82000300 |DIMOFS_Z ) /* Z Axis */ +#define DIMOUSE_BUTTON0 (0x82000400 |DIMOFS_BUTTON0) /* Button 0 */ +#define DIMOUSE_BUTTON1 (0x82000400 |DIMOFS_BUTTON1) /* Button 1 */ +#define DIMOUSE_BUTTON2 (0x82000400 |DIMOFS_BUTTON2) /* Button 2 */ +#define DIMOUSE_BUTTON3 (0x82000400 |DIMOFS_BUTTON3) /* Button 3 */ +#define DIMOUSE_BUTTON4 (0x82000400 |DIMOFS_BUTTON4) /* Button 4 */ +#define DIMOUSE_BUTTON5 (0x82000400 |DIMOFS_BUTTON5) /* Button 5 */ +#define DIMOUSE_BUTTON6 (0x82000400 |DIMOFS_BUTTON6) /* Button 6 */ +#define DIMOUSE_BUTTON7 (0x82000400 |DIMOFS_BUTTON7) /* Button 7 */ + + +/*--- VOICE + Physical Dplay Voice Device ---*/ + +#define DIVOICE_CHANNEL1 0x83000401 +#define DIVOICE_CHANNEL2 0x83000402 +#define DIVOICE_CHANNEL3 0x83000403 +#define DIVOICE_CHANNEL4 0x83000404 +#define DIVOICE_CHANNEL5 0x83000405 +#define DIVOICE_CHANNEL6 0x83000406 +#define DIVOICE_CHANNEL7 0x83000407 +#define DIVOICE_CHANNEL8 0x83000408 +#define DIVOICE_TEAM 0x83000409 +#define DIVOICE_ALL 0x8300040A +#define DIVOICE_RECORDMUTE 0x8300040B +#define DIVOICE_PLAYBACKMUTE 0x8300040C +#define DIVOICE_TRANSMIT 0x8300040D + +#define DIVOICE_VOICECOMMAND 0x83000410 + + +/*--- Driving Simulator - Racing + Vehicle control is primary objective ---*/ +#define DIVIRTUAL_DRIVING_RACE 0x01000000 +#define DIAXIS_DRIVINGR_STEER 0x01008A01 /* Steering */ +#define DIAXIS_DRIVINGR_ACCELERATE 0x01039202 /* Accelerate */ +#define DIAXIS_DRIVINGR_BRAKE 0x01041203 /* Brake-Axis */ +#define DIBUTTON_DRIVINGR_SHIFTUP 0x01000C01 /* Shift to next higher gear */ +#define DIBUTTON_DRIVINGR_SHIFTDOWN 0x01000C02 /* Shift to next lower gear */ +#define DIBUTTON_DRIVINGR_VIEW 0x01001C03 /* Cycle through view options */ +#define DIBUTTON_DRIVINGR_MENU 0x010004FD /* Show menu options */ +/*--- Priority 2 controls ---*/ + +#define DIAXIS_DRIVINGR_ACCEL_AND_BRAKE 0x01014A04 /* Some devices combine accelerate and brake in a single axis */ +#define DIHATSWITCH_DRIVINGR_GLANCE 0x01004601 /* Look around */ +#define DIBUTTON_DRIVINGR_BRAKE 0x01004C04 /* Brake-button */ +#define DIBUTTON_DRIVINGR_DASHBOARD 0x01004405 /* Select next dashboard option */ +#define DIBUTTON_DRIVINGR_AIDS 0x01004406 /* Driver correction aids */ +#define DIBUTTON_DRIVINGR_MAP 0x01004407 /* Display Driving Map */ +#define DIBUTTON_DRIVINGR_BOOST 0x01004408 /* Turbo Boost */ +#define DIBUTTON_DRIVINGR_PIT 0x01004409 /* Pit stop notification */ +#define DIBUTTON_DRIVINGR_ACCELERATE_LINK 0x0103D4E0 /* Fallback Accelerate button */ +#define DIBUTTON_DRIVINGR_STEER_LEFT_LINK 0x0100CCE4 /* Fallback Steer Left button */ +#define DIBUTTON_DRIVINGR_STEER_RIGHT_LINK 0x0100CCEC /* Fallback Steer Right button */ +#define DIBUTTON_DRIVINGR_GLANCE_LEFT_LINK 0x0107C4E4 /* Fallback Glance Left button */ +#define DIBUTTON_DRIVINGR_GLANCE_RIGHT_LINK 0x0107C4EC /* Fallback Glance Right button */ +#define DIBUTTON_DRIVINGR_DEVICE 0x010044FE /* Show input device and controls */ +#define DIBUTTON_DRIVINGR_PAUSE 0x010044FC /* Start / Pause / Restart game */ + +/*--- Driving Simulator - Combat + Combat from within a vehicle is primary objective ---*/ +#define DIVIRTUAL_DRIVING_COMBAT 0x02000000 +#define DIAXIS_DRIVINGC_STEER 0x02008A01 /* Steering */ +#define DIAXIS_DRIVINGC_ACCELERATE 0x02039202 /* Accelerate */ +#define DIAXIS_DRIVINGC_BRAKE 0x02041203 /* Brake-axis */ +#define DIBUTTON_DRIVINGC_FIRE 0x02000C01 /* Fire */ +#define DIBUTTON_DRIVINGC_WEAPONS 0x02000C02 /* Select next weapon */ +#define DIBUTTON_DRIVINGC_TARGET 0x02000C03 /* Select next available target */ +#define DIBUTTON_DRIVINGC_MENU 0x020004FD /* Show menu options */ +/*--- Priority 2 controls ---*/ + +#define DIAXIS_DRIVINGC_ACCEL_AND_BRAKE 0x02014A04 /* Some devices combine accelerate and brake in a single axis */ +#define DIHATSWITCH_DRIVINGC_GLANCE 0x02004601 /* Look around */ +#define DIBUTTON_DRIVINGC_SHIFTUP 0x02004C04 /* Shift to next higher gear */ +#define DIBUTTON_DRIVINGC_SHIFTDOWN 0x02004C05 /* Shift to next lower gear */ +#define DIBUTTON_DRIVINGC_DASHBOARD 0x02004406 /* Select next dashboard option */ +#define DIBUTTON_DRIVINGC_AIDS 0x02004407 /* Driver correction aids */ +#define DIBUTTON_DRIVINGC_BRAKE 0x02004C08 /* Brake-button */ +#define DIBUTTON_DRIVINGC_FIRESECONDARY 0x02004C09 /* Alternative fire button */ +#define DIBUTTON_DRIVINGC_ACCELERATE_LINK 0x0203D4E0 /* Fallback Accelerate button */ +#define DIBUTTON_DRIVINGC_STEER_LEFT_LINK 0x0200CCE4 /* Fallback Steer Left button */ +#define DIBUTTON_DRIVINGC_STEER_RIGHT_LINK 0x0200CCEC /* Fallback Steer Right button */ +#define DIBUTTON_DRIVINGC_GLANCE_LEFT_LINK 0x0207C4E4 /* Fallback Glance Left button */ +#define DIBUTTON_DRIVINGC_GLANCE_RIGHT_LINK 0x0207C4EC /* Fallback Glance Right button */ +#define DIBUTTON_DRIVINGC_DEVICE 0x020044FE /* Show input device and controls */ +#define DIBUTTON_DRIVINGC_PAUSE 0x020044FC /* Start / Pause / Restart game */ + +/*--- Driving Simulator - Tank + Combat from withing a tank is primary objective ---*/ +#define DIVIRTUAL_DRIVING_TANK 0x03000000 +#define DIAXIS_DRIVINGT_STEER 0x03008A01 /* Turn tank left / right */ +#define DIAXIS_DRIVINGT_BARREL 0x03010202 /* Raise / lower barrel */ +#define DIAXIS_DRIVINGT_ACCELERATE 0x03039203 /* Accelerate */ +#define DIAXIS_DRIVINGT_ROTATE 0x03020204 /* Turn barrel left / right */ +#define DIBUTTON_DRIVINGT_FIRE 0x03000C01 /* Fire */ +#define DIBUTTON_DRIVINGT_WEAPONS 0x03000C02 /* Select next weapon */ +#define DIBUTTON_DRIVINGT_TARGET 0x03000C03 /* Selects next available target */ +#define DIBUTTON_DRIVINGT_MENU 0x030004FD /* Show menu options */ +/*--- Priority 2 controls ---*/ + +#define DIHATSWITCH_DRIVINGT_GLANCE 0x03004601 /* Look around */ +#define DIAXIS_DRIVINGT_BRAKE 0x03045205 /* Brake-axis */ +#define DIAXIS_DRIVINGT_ACCEL_AND_BRAKE 0x03014A06 /* Some devices combine accelerate and brake in a single axis */ +#define DIBUTTON_DRIVINGT_VIEW 0x03005C04 /* Cycle through view options */ +#define DIBUTTON_DRIVINGT_DASHBOARD 0x03005C05 /* Select next dashboard option */ +#define DIBUTTON_DRIVINGT_BRAKE 0x03004C06 /* Brake-button */ +#define DIBUTTON_DRIVINGT_FIRESECONDARY 0x03004C07 /* Alternative fire button */ +#define DIBUTTON_DRIVINGT_ACCELERATE_LINK 0x0303D4E0 /* Fallback Accelerate button */ +#define DIBUTTON_DRIVINGT_STEER_LEFT_LINK 0x0300CCE4 /* Fallback Steer Left button */ +#define DIBUTTON_DRIVINGT_STEER_RIGHT_LINK 0x0300CCEC /* Fallback Steer Right button */ +#define DIBUTTON_DRIVINGT_BARREL_UP_LINK 0x030144E0 /* Fallback Barrel up button */ +#define DIBUTTON_DRIVINGT_BARREL_DOWN_LINK 0x030144E8 /* Fallback Barrel down button */ +#define DIBUTTON_DRIVINGT_ROTATE_LEFT_LINK 0x030244E4 /* Fallback Rotate left button */ +#define DIBUTTON_DRIVINGT_ROTATE_RIGHT_LINK 0x030244EC /* Fallback Rotate right button */ +#define DIBUTTON_DRIVINGT_GLANCE_LEFT_LINK 0x0307C4E4 /* Fallback Glance Left button */ +#define DIBUTTON_DRIVINGT_GLANCE_RIGHT_LINK 0x0307C4EC /* Fallback Glance Right button */ +#define DIBUTTON_DRIVINGT_DEVICE 0x030044FE /* Show input device and controls */ +#define DIBUTTON_DRIVINGT_PAUSE 0x030044FC /* Start / Pause / Restart game */ + +/*--- Flight Simulator - Civilian + Plane control is the primary objective ---*/ +#define DIVIRTUAL_FLYING_CIVILIAN 0x04000000 +#define DIAXIS_FLYINGC_BANK 0x04008A01 /* Roll ship left / right */ +#define DIAXIS_FLYINGC_PITCH 0x04010A02 /* Nose up / down */ +#define DIAXIS_FLYINGC_THROTTLE 0x04039203 /* Throttle */ +#define DIBUTTON_FLYINGC_VIEW 0x04002401 /* Cycle through view options */ +#define DIBUTTON_FLYINGC_DISPLAY 0x04002402 /* Select next dashboard / heads up display option */ +#define DIBUTTON_FLYINGC_GEAR 0x04002C03 /* Gear up / down */ +#define DIBUTTON_FLYINGC_MENU 0x040004FD /* Show menu options */ +/*--- Priority 2 controls ---*/ + +#define DIHATSWITCH_FLYINGC_GLANCE 0x04004601 /* Look around */ +#define DIAXIS_FLYINGC_BRAKE 0x04046A04 /* Apply Brake */ +#define DIAXIS_FLYINGC_RUDDER 0x04025205 /* Yaw ship left/right */ +#define DIAXIS_FLYINGC_FLAPS 0x04055A06 /* Flaps */ +#define DIBUTTON_FLYINGC_FLAPSUP 0x04006404 /* Increment stepping up until fully retracted */ +#define DIBUTTON_FLYINGC_FLAPSDOWN 0x04006405 /* Decrement stepping down until fully extended */ +#define DIBUTTON_FLYINGC_BRAKE_LINK 0x04046CE0 /* Fallback brake button */ +#define DIBUTTON_FLYINGC_FASTER_LINK 0x0403D4E0 /* Fallback throttle up button */ +#define DIBUTTON_FLYINGC_SLOWER_LINK 0x0403D4E8 /* Fallback throttle down button */ +#define DIBUTTON_FLYINGC_GLANCE_LEFT_LINK 0x0407C4E4 /* Fallback Glance Left button */ +#define DIBUTTON_FLYINGC_GLANCE_RIGHT_LINK 0x0407C4EC /* Fallback Glance Right button */ +#define DIBUTTON_FLYINGC_GLANCE_UP_LINK 0x0407C4E0 /* Fallback Glance Up button */ +#define DIBUTTON_FLYINGC_GLANCE_DOWN_LINK 0x0407C4E8 /* Fallback Glance Down button */ +#define DIBUTTON_FLYINGC_DEVICE 0x040044FE /* Show input device and controls */ +#define DIBUTTON_FLYINGC_PAUSE 0x040044FC /* Start / Pause / Restart game */ + +/*--- Flight Simulator - Military + Aerial combat is the primary objective ---*/ +#define DIVIRTUAL_FLYING_MILITARY 0x05000000 +#define DIAXIS_FLYINGM_BANK 0x05008A01 /* Bank - Roll ship left / right */ +#define DIAXIS_FLYINGM_PITCH 0x05010A02 /* Pitch - Nose up / down */ +#define DIAXIS_FLYINGM_THROTTLE 0x05039203 /* Throttle - faster / slower */ +#define DIBUTTON_FLYINGM_FIRE 0x05000C01 /* Fire */ +#define DIBUTTON_FLYINGM_WEAPONS 0x05000C02 /* Select next weapon */ +#define DIBUTTON_FLYINGM_TARGET 0x05000C03 /* Selects next available target */ +#define DIBUTTON_FLYINGM_MENU 0x050004FD /* Show menu options */ +/*--- Priority 2 controls ---*/ + +#define DIHATSWITCH_FLYINGM_GLANCE 0x05004601 /* Look around */ +#define DIBUTTON_FLYINGM_COUNTER 0x05005C04 /* Activate counter measures */ +#define DIAXIS_FLYINGM_RUDDER 0x05024A04 /* Rudder - Yaw ship left/right */ +#define DIAXIS_FLYINGM_BRAKE 0x05046205 /* Brake-axis */ +#define DIBUTTON_FLYINGM_VIEW 0x05006405 /* Cycle through view options */ +#define DIBUTTON_FLYINGM_DISPLAY 0x05006406 /* Select next dashboard option */ +#define DIAXIS_FLYINGM_FLAPS 0x05055206 /* Flaps */ +#define DIBUTTON_FLYINGM_FLAPSUP 0x05005407 /* Increment stepping up until fully retracted */ +#define DIBUTTON_FLYINGM_FLAPSDOWN 0x05005408 /* Decrement stepping down until fully extended */ +#define DIBUTTON_FLYINGM_FIRESECONDARY 0x05004C09 /* Alternative fire button */ +#define DIBUTTON_FLYINGM_GEAR 0x0500640A /* Gear up / down */ +#define DIBUTTON_FLYINGM_BRAKE_LINK 0x050464E0 /* Fallback brake button */ +#define DIBUTTON_FLYINGM_FASTER_LINK 0x0503D4E0 /* Fallback throttle up button */ +#define DIBUTTON_FLYINGM_SLOWER_LINK 0x0503D4E8 /* Fallback throttle down button */ +#define DIBUTTON_FLYINGM_GLANCE_LEFT_LINK 0x0507C4E4 /* Fallback Glance Left button */ +#define DIBUTTON_FLYINGM_GLANCE_RIGHT_LINK 0x0507C4EC /* Fallback Glance Right button */ +#define DIBUTTON_FLYINGM_GLANCE_UP_LINK 0x0507C4E0 /* Fallback Glance Up button */ +#define DIBUTTON_FLYINGM_GLANCE_DOWN_LINK 0x0507C4E8 /* Fallback Glance Down button */ +#define DIBUTTON_FLYINGM_DEVICE 0x050044FE /* Show input device and controls */ +#define DIBUTTON_FLYINGM_PAUSE 0x050044FC /* Start / Pause / Restart game */ + +/*--- Flight Simulator - Combat Helicopter + Combat from helicopter is primary objective ---*/ +#define DIVIRTUAL_FLYING_HELICOPTER 0x06000000 +#define DIAXIS_FLYINGH_BANK 0x06008A01 /* Bank - Roll ship left / right */ +#define DIAXIS_FLYINGH_PITCH 0x06010A02 /* Pitch - Nose up / down */ +#define DIAXIS_FLYINGH_COLLECTIVE 0x06018A03 /* Collective - Blade pitch/power */ +#define DIBUTTON_FLYINGH_FIRE 0x06001401 /* Fire */ +#define DIBUTTON_FLYINGH_WEAPONS 0x06001402 /* Select next weapon */ +#define DIBUTTON_FLYINGH_TARGET 0x06001403 /* Selects next available target */ +#define DIBUTTON_FLYINGH_MENU 0x060004FD /* Show menu options */ +/*--- Priority 2 controls ---*/ + +#define DIHATSWITCH_FLYINGH_GLANCE 0x06004601 /* Look around */ +#define DIAXIS_FLYINGH_TORQUE 0x06025A04 /* Torque - Rotate ship around left / right axis */ +#define DIAXIS_FLYINGH_THROTTLE 0x0603DA05 /* Throttle */ +#define DIBUTTON_FLYINGH_COUNTER 0x06005404 /* Activate counter measures */ +#define DIBUTTON_FLYINGH_VIEW 0x06006405 /* Cycle through view options */ +#define DIBUTTON_FLYINGH_GEAR 0x06006406 /* Gear up / down */ +#define DIBUTTON_FLYINGH_FIRESECONDARY 0x06004C07 /* Alternative fire button */ +#define DIBUTTON_FLYINGH_FASTER_LINK 0x0603DCE0 /* Fallback throttle up button */ +#define DIBUTTON_FLYINGH_SLOWER_LINK 0x0603DCE8 /* Fallback throttle down button */ +#define DIBUTTON_FLYINGH_GLANCE_LEFT_LINK 0x0607C4E4 /* Fallback Glance Left button */ +#define DIBUTTON_FLYINGH_GLANCE_RIGHT_LINK 0x0607C4EC /* Fallback Glance Right button */ +#define DIBUTTON_FLYINGH_GLANCE_UP_LINK 0x0607C4E0 /* Fallback Glance Up button */ +#define DIBUTTON_FLYINGH_GLANCE_DOWN_LINK 0x0607C4E8 /* Fallback Glance Down button */ +#define DIBUTTON_FLYINGH_DEVICE 0x060044FE /* Show input device and controls */ +#define DIBUTTON_FLYINGH_PAUSE 0x060044FC /* Start / Pause / Restart game */ + +/*--- Space Simulator - Combat + Space Simulator with weapons ---*/ +#define DIVIRTUAL_SPACESIM 0x07000000 +#define DIAXIS_SPACESIM_LATERAL 0x07008201 /* Move ship left / right */ +#define DIAXIS_SPACESIM_MOVE 0x07010202 /* Move ship forward/backward */ +#define DIAXIS_SPACESIM_THROTTLE 0x07038203 /* Throttle - Engine speed */ +#define DIBUTTON_SPACESIM_FIRE 0x07000401 /* Fire */ +#define DIBUTTON_SPACESIM_WEAPONS 0x07000402 /* Select next weapon */ +#define DIBUTTON_SPACESIM_TARGET 0x07000403 /* Selects next available target */ +#define DIBUTTON_SPACESIM_MENU 0x070004FD /* Show menu options */ +/*--- Priority 2 controls ---*/ + +#define DIHATSWITCH_SPACESIM_GLANCE 0x07004601 /* Look around */ +#define DIAXIS_SPACESIM_CLIMB 0x0701C204 /* Climb - Pitch ship up/down */ +#define DIAXIS_SPACESIM_ROTATE 0x07024205 /* Rotate - Turn ship left/right */ +#define DIBUTTON_SPACESIM_VIEW 0x07004404 /* Cycle through view options */ +#define DIBUTTON_SPACESIM_DISPLAY 0x07004405 /* Select next dashboard / heads up display option */ +#define DIBUTTON_SPACESIM_RAISE 0x07004406 /* Raise ship while maintaining current pitch */ +#define DIBUTTON_SPACESIM_LOWER 0x07004407 /* Lower ship while maintaining current pitch */ +#define DIBUTTON_SPACESIM_GEAR 0x07004408 /* Gear up / down */ +#define DIBUTTON_SPACESIM_FIRESECONDARY 0x07004409 /* Alternative fire button */ +#define DIBUTTON_SPACESIM_LEFT_LINK 0x0700C4E4 /* Fallback move left button */ +#define DIBUTTON_SPACESIM_RIGHT_LINK 0x0700C4EC /* Fallback move right button */ +#define DIBUTTON_SPACESIM_FORWARD_LINK 0x070144E0 /* Fallback move forward button */ +#define DIBUTTON_SPACESIM_BACKWARD_LINK 0x070144E8 /* Fallback move backwards button */ +#define DIBUTTON_SPACESIM_FASTER_LINK 0x0703C4E0 /* Fallback throttle up button */ +#define DIBUTTON_SPACESIM_SLOWER_LINK 0x0703C4E8 /* Fallback throttle down button */ +#define DIBUTTON_SPACESIM_TURN_LEFT_LINK 0x070244E4 /* Fallback turn left button */ +#define DIBUTTON_SPACESIM_TURN_RIGHT_LINK 0x070244EC /* Fallback turn right button */ +#define DIBUTTON_SPACESIM_GLANCE_LEFT_LINK 0x0707C4E4 /* Fallback Glance Left button */ +#define DIBUTTON_SPACESIM_GLANCE_RIGHT_LINK 0x0707C4EC /* Fallback Glance Right button */ +#define DIBUTTON_SPACESIM_GLANCE_UP_LINK 0x0707C4E0 /* Fallback Glance Up button */ +#define DIBUTTON_SPACESIM_GLANCE_DOWN_LINK 0x0707C4E8 /* Fallback Glance Down button */ +#define DIBUTTON_SPACESIM_DEVICE 0x070044FE /* Show input device and controls */ +#define DIBUTTON_SPACESIM_PAUSE 0x070044FC /* Start / Pause / Restart game */ + +/*--- Fighting - First Person + Hand to Hand combat is primary objective ---*/ +#define DIVIRTUAL_FIGHTING_HAND2HAND 0x08000000 +#define DIAXIS_FIGHTINGH_LATERAL 0x08008201 /* Sidestep left/right */ +#define DIAXIS_FIGHTINGH_MOVE 0x08010202 /* Move forward/backward */ +#define DIBUTTON_FIGHTINGH_PUNCH 0x08000401 /* Punch */ +#define DIBUTTON_FIGHTINGH_KICK 0x08000402 /* Kick */ +#define DIBUTTON_FIGHTINGH_BLOCK 0x08000403 /* Block */ +#define DIBUTTON_FIGHTINGH_CROUCH 0x08000404 /* Crouch */ +#define DIBUTTON_FIGHTINGH_JUMP 0x08000405 /* Jump */ +#define DIBUTTON_FIGHTINGH_SPECIAL1 0x08000406 /* Apply first special move */ +#define DIBUTTON_FIGHTINGH_SPECIAL2 0x08000407 /* Apply second special move */ +#define DIBUTTON_FIGHTINGH_MENU 0x080004FD /* Show menu options */ +/*--- Priority 2 controls ---*/ + +#define DIBUTTON_FIGHTINGH_SELECT 0x08004408 /* Select special move */ +#define DIHATSWITCH_FIGHTINGH_SLIDE 0x08004601 /* Look around */ +#define DIBUTTON_FIGHTINGH_DISPLAY 0x08004409 /* Shows next on-screen display option */ +#define DIAXIS_FIGHTINGH_ROTATE 0x08024203 /* Rotate - Turn body left/right */ +#define DIBUTTON_FIGHTINGH_DODGE 0x0800440A /* Dodge */ +#define DIBUTTON_FIGHTINGH_LEFT_LINK 0x0800C4E4 /* Fallback left sidestep button */ +#define DIBUTTON_FIGHTINGH_RIGHT_LINK 0x0800C4EC /* Fallback right sidestep button */ +#define DIBUTTON_FIGHTINGH_FORWARD_LINK 0x080144E0 /* Fallback forward button */ +#define DIBUTTON_FIGHTINGH_BACKWARD_LINK 0x080144E8 /* Fallback backward button */ +#define DIBUTTON_FIGHTINGH_DEVICE 0x080044FE /* Show input device and controls */ +#define DIBUTTON_FIGHTINGH_PAUSE 0x080044FC /* Start / Pause / Restart game */ + +/*--- Fighting - First Person Shooting + Navigation and combat are primary objectives ---*/ +#define DIVIRTUAL_FIGHTING_FPS 0x09000000 +#define DIAXIS_FPS_ROTATE 0x09008201 /* Rotate character left/right */ +#define DIAXIS_FPS_MOVE 0x09010202 /* Move forward/backward */ +#define DIBUTTON_FPS_FIRE 0x09000401 /* Fire */ +#define DIBUTTON_FPS_WEAPONS 0x09000402 /* Select next weapon */ +#define DIBUTTON_FPS_APPLY 0x09000403 /* Use item */ +#define DIBUTTON_FPS_SELECT 0x09000404 /* Select next inventory item */ +#define DIBUTTON_FPS_CROUCH 0x09000405 /* Crouch/ climb down/ swim down */ +#define DIBUTTON_FPS_JUMP 0x09000406 /* Jump/ climb up/ swim up */ +#define DIAXIS_FPS_LOOKUPDOWN 0x09018203 /* Look up / down */ +#define DIBUTTON_FPS_STRAFE 0x09000407 /* Enable strafing while active */ +#define DIBUTTON_FPS_MENU 0x090004FD /* Show menu options */ +/*--- Priority 2 controls ---*/ + +#define DIHATSWITCH_FPS_GLANCE 0x09004601 /* Look around */ +#define DIBUTTON_FPS_DISPLAY 0x09004408 /* Shows next on-screen display option/ map */ +#define DIAXIS_FPS_SIDESTEP 0x09024204 /* Sidestep */ +#define DIBUTTON_FPS_DODGE 0x09004409 /* Dodge */ +#define DIBUTTON_FPS_GLANCEL 0x0900440A /* Glance Left */ +#define DIBUTTON_FPS_GLANCER 0x0900440B /* Glance Right */ +#define DIBUTTON_FPS_FIRESECONDARY 0x0900440C /* Alternative fire button */ +#define DIBUTTON_FPS_ROTATE_LEFT_LINK 0x0900C4E4 /* Fallback rotate left button */ +#define DIBUTTON_FPS_ROTATE_RIGHT_LINK 0x0900C4EC /* Fallback rotate right button */ +#define DIBUTTON_FPS_FORWARD_LINK 0x090144E0 /* Fallback forward button */ +#define DIBUTTON_FPS_BACKWARD_LINK 0x090144E8 /* Fallback backward button */ +#define DIBUTTON_FPS_GLANCE_UP_LINK 0x0901C4E0 /* Fallback look up button */ +#define DIBUTTON_FPS_GLANCE_DOWN_LINK 0x0901C4E8 /* Fallback look down button */ +#define DIBUTTON_FPS_STEP_LEFT_LINK 0x090244E4 /* Fallback step left button */ +#define DIBUTTON_FPS_STEP_RIGHT_LINK 0x090244EC /* Fallback step right button */ +#define DIBUTTON_FPS_DEVICE 0x090044FE /* Show input device and controls */ +#define DIBUTTON_FPS_PAUSE 0x090044FC /* Start / Pause / Restart game */ + +/*--- Fighting - Third Person action + Perspective of camera is behind the main character ---*/ +#define DIVIRTUAL_FIGHTING_THIRDPERSON 0x0A000000 +#define DIAXIS_TPS_TURN 0x0A020201 /* Turn left/right */ +#define DIAXIS_TPS_MOVE 0x0A010202 /* Move forward/backward */ +#define DIBUTTON_TPS_RUN 0x0A000401 /* Run or walk toggle switch */ +#define DIBUTTON_TPS_ACTION 0x0A000402 /* Action Button */ +#define DIBUTTON_TPS_SELECT 0x0A000403 /* Select next weapon */ +#define DIBUTTON_TPS_USE 0x0A000404 /* Use inventory item currently selected */ +#define DIBUTTON_TPS_JUMP 0x0A000405 /* Character Jumps */ +#define DIBUTTON_TPS_MENU 0x0A0004FD /* Show menu options */ +/*--- Priority 2 controls ---*/ + +#define DIHATSWITCH_TPS_GLANCE 0x0A004601 /* Look around */ +#define DIBUTTON_TPS_VIEW 0x0A004406 /* Select camera view */ +#define DIBUTTON_TPS_STEPLEFT 0x0A004407 /* Character takes a left step */ +#define DIBUTTON_TPS_STEPRIGHT 0x0A004408 /* Character takes a right step */ +#define DIAXIS_TPS_STEP 0x0A00C203 /* Character steps left/right */ +#define DIBUTTON_TPS_DODGE 0x0A004409 /* Character dodges or ducks */ +#define DIBUTTON_TPS_INVENTORY 0x0A00440A /* Cycle through inventory */ +#define DIBUTTON_TPS_TURN_LEFT_LINK 0x0A0244E4 /* Fallback turn left button */ +#define DIBUTTON_TPS_TURN_RIGHT_LINK 0x0A0244EC /* Fallback turn right button */ +#define DIBUTTON_TPS_FORWARD_LINK 0x0A0144E0 /* Fallback forward button */ +#define DIBUTTON_TPS_BACKWARD_LINK 0x0A0144E8 /* Fallback backward button */ +#define DIBUTTON_TPS_GLANCE_UP_LINK 0x0A07C4E0 /* Fallback look up button */ +#define DIBUTTON_TPS_GLANCE_DOWN_LINK 0x0A07C4E8 /* Fallback look down button */ +#define DIBUTTON_TPS_GLANCE_LEFT_LINK 0x0A07C4E4 /* Fallback glance up button */ +#define DIBUTTON_TPS_GLANCE_RIGHT_LINK 0x0A07C4EC /* Fallback glance right button */ +#define DIBUTTON_TPS_DEVICE 0x0A0044FE /* Show input device and controls */ +#define DIBUTTON_TPS_PAUSE 0x0A0044FC /* Start / Pause / Restart game */ + +/*--- Strategy - Role Playing + Navigation and problem solving are primary actions ---*/ +#define DIVIRTUAL_STRATEGY_ROLEPLAYING 0x0B000000 +#define DIAXIS_STRATEGYR_LATERAL 0x0B008201 /* sidestep - left/right */ +#define DIAXIS_STRATEGYR_MOVE 0x0B010202 /* move forward/backward */ +#define DIBUTTON_STRATEGYR_GET 0x0B000401 /* Acquire item */ +#define DIBUTTON_STRATEGYR_APPLY 0x0B000402 /* Use selected item */ +#define DIBUTTON_STRATEGYR_SELECT 0x0B000403 /* Select nextitem */ +#define DIBUTTON_STRATEGYR_ATTACK 0x0B000404 /* Attack */ +#define DIBUTTON_STRATEGYR_CAST 0x0B000405 /* Cast Spell */ +#define DIBUTTON_STRATEGYR_CROUCH 0x0B000406 /* Crouch */ +#define DIBUTTON_STRATEGYR_JUMP 0x0B000407 /* Jump */ +#define DIBUTTON_STRATEGYR_MENU 0x0B0004FD /* Show menu options */ +/*--- Priority 2 controls ---*/ + +#define DIHATSWITCH_STRATEGYR_GLANCE 0x0B004601 /* Look around */ +#define DIBUTTON_STRATEGYR_MAP 0x0B004408 /* Cycle through map options */ +#define DIBUTTON_STRATEGYR_DISPLAY 0x0B004409 /* Shows next on-screen display option */ +#define DIAXIS_STRATEGYR_ROTATE 0x0B024203 /* Turn body left/right */ +#define DIBUTTON_STRATEGYR_LEFT_LINK 0x0B00C4E4 /* Fallback sidestep left button */ +#define DIBUTTON_STRATEGYR_RIGHT_LINK 0x0B00C4EC /* Fallback sidestep right button */ +#define DIBUTTON_STRATEGYR_FORWARD_LINK 0x0B0144E0 /* Fallback move forward button */ +#define DIBUTTON_STRATEGYR_BACK_LINK 0x0B0144E8 /* Fallback move backward button */ +#define DIBUTTON_STRATEGYR_ROTATE_LEFT_LINK 0x0B0244E4 /* Fallback turn body left button */ +#define DIBUTTON_STRATEGYR_ROTATE_RIGHT_LINK 0x0B0244EC /* Fallback turn body right button */ +#define DIBUTTON_STRATEGYR_DEVICE 0x0B0044FE /* Show input device and controls */ +#define DIBUTTON_STRATEGYR_PAUSE 0x0B0044FC /* Start / Pause / Restart game */ + +/*--- Strategy - Turn based + Navigation and problem solving are primary actions ---*/ +#define DIVIRTUAL_STRATEGY_TURN 0x0C000000 +#define DIAXIS_STRATEGYT_LATERAL 0x0C008201 /* Sidestep left/right */ +#define DIAXIS_STRATEGYT_MOVE 0x0C010202 /* Move forward/backwards */ +#define DIBUTTON_STRATEGYT_SELECT 0x0C000401 /* Select unit or object */ +#define DIBUTTON_STRATEGYT_INSTRUCT 0x0C000402 /* Cycle through instructions */ +#define DIBUTTON_STRATEGYT_APPLY 0x0C000403 /* Apply selected instruction */ +#define DIBUTTON_STRATEGYT_TEAM 0x0C000404 /* Select next team / cycle through all */ +#define DIBUTTON_STRATEGYT_TURN 0x0C000405 /* Indicate turn over */ +#define DIBUTTON_STRATEGYT_MENU 0x0C0004FD /* Show menu options */ +/*--- Priority 2 controls ---*/ + +#define DIBUTTON_STRATEGYT_ZOOM 0x0C004406 /* Zoom - in / out */ +#define DIBUTTON_STRATEGYT_MAP 0x0C004407 /* cycle through map options */ +#define DIBUTTON_STRATEGYT_DISPLAY 0x0C004408 /* shows next on-screen display options */ +#define DIBUTTON_STRATEGYT_LEFT_LINK 0x0C00C4E4 /* Fallback sidestep left button */ +#define DIBUTTON_STRATEGYT_RIGHT_LINK 0x0C00C4EC /* Fallback sidestep right button */ +#define DIBUTTON_STRATEGYT_FORWARD_LINK 0x0C0144E0 /* Fallback move forward button */ +#define DIBUTTON_STRATEGYT_BACK_LINK 0x0C0144E8 /* Fallback move back button */ +#define DIBUTTON_STRATEGYT_DEVICE 0x0C0044FE /* Show input device and controls */ +#define DIBUTTON_STRATEGYT_PAUSE 0x0C0044FC /* Start / Pause / Restart game */ + +/*--- Sports - Hunting + Hunting ---*/ +#define DIVIRTUAL_SPORTS_HUNTING 0x0D000000 +#define DIAXIS_HUNTING_LATERAL 0x0D008201 /* sidestep left/right */ +#define DIAXIS_HUNTING_MOVE 0x0D010202 /* move forward/backwards */ +#define DIBUTTON_HUNTING_FIRE 0x0D000401 /* Fire selected weapon */ +#define DIBUTTON_HUNTING_AIM 0x0D000402 /* Select aim/move */ +#define DIBUTTON_HUNTING_WEAPON 0x0D000403 /* Select next weapon */ +#define DIBUTTON_HUNTING_BINOCULAR 0x0D000404 /* Look through Binoculars */ +#define DIBUTTON_HUNTING_CALL 0x0D000405 /* Make animal call */ +#define DIBUTTON_HUNTING_MAP 0x0D000406 /* View Map */ +#define DIBUTTON_HUNTING_SPECIAL 0x0D000407 /* Special game operation */ +#define DIBUTTON_HUNTING_MENU 0x0D0004FD /* Show menu options */ +/*--- Priority 2 controls ---*/ + +#define DIHATSWITCH_HUNTING_GLANCE 0x0D004601 /* Look around */ +#define DIBUTTON_HUNTING_DISPLAY 0x0D004408 /* show next on-screen display option */ +#define DIAXIS_HUNTING_ROTATE 0x0D024203 /* Turn body left/right */ +#define DIBUTTON_HUNTING_CROUCH 0x0D004409 /* Crouch/ Climb / Swim down */ +#define DIBUTTON_HUNTING_JUMP 0x0D00440A /* Jump/ Climb up / Swim up */ +#define DIBUTTON_HUNTING_FIRESECONDARY 0x0D00440B /* Alternative fire button */ +#define DIBUTTON_HUNTING_LEFT_LINK 0x0D00C4E4 /* Fallback sidestep left button */ +#define DIBUTTON_HUNTING_RIGHT_LINK 0x0D00C4EC /* Fallback sidestep right button */ +#define DIBUTTON_HUNTING_FORWARD_LINK 0x0D0144E0 /* Fallback move forward button */ +#define DIBUTTON_HUNTING_BACK_LINK 0x0D0144E8 /* Fallback move back button */ +#define DIBUTTON_HUNTING_ROTATE_LEFT_LINK 0x0D0244E4 /* Fallback turn body left button */ +#define DIBUTTON_HUNTING_ROTATE_RIGHT_LINK 0x0D0244EC /* Fallback turn body right button */ +#define DIBUTTON_HUNTING_DEVICE 0x0D0044FE /* Show input device and controls */ +#define DIBUTTON_HUNTING_PAUSE 0x0D0044FC /* Start / Pause / Restart game */ + +/*--- Sports - Fishing + Catching Fish is primary objective ---*/ +#define DIVIRTUAL_SPORTS_FISHING 0x0E000000 +#define DIAXIS_FISHING_LATERAL 0x0E008201 /* sidestep left/right */ +#define DIAXIS_FISHING_MOVE 0x0E010202 /* move forward/backwards */ +#define DIBUTTON_FISHING_CAST 0x0E000401 /* Cast line */ +#define DIBUTTON_FISHING_TYPE 0x0E000402 /* Select cast type */ +#define DIBUTTON_FISHING_BINOCULAR 0x0E000403 /* Look through Binocular */ +#define DIBUTTON_FISHING_BAIT 0x0E000404 /* Select type of Bait */ +#define DIBUTTON_FISHING_MAP 0x0E000405 /* View Map */ +#define DIBUTTON_FISHING_MENU 0x0E0004FD /* Show menu options */ +/*--- Priority 2 controls ---*/ + +#define DIHATSWITCH_FISHING_GLANCE 0x0E004601 /* Look around */ +#define DIBUTTON_FISHING_DISPLAY 0x0E004406 /* Show next on-screen display option */ +#define DIAXIS_FISHING_ROTATE 0x0E024203 /* Turn character left / right */ +#define DIBUTTON_FISHING_CROUCH 0x0E004407 /* Crouch/ Climb / Swim down */ +#define DIBUTTON_FISHING_JUMP 0x0E004408 /* Jump/ Climb up / Swim up */ +#define DIBUTTON_FISHING_LEFT_LINK 0x0E00C4E4 /* Fallback sidestep left button */ +#define DIBUTTON_FISHING_RIGHT_LINK 0x0E00C4EC /* Fallback sidestep right button */ +#define DIBUTTON_FISHING_FORWARD_LINK 0x0E0144E0 /* Fallback move forward button */ +#define DIBUTTON_FISHING_BACK_LINK 0x0E0144E8 /* Fallback move back button */ +#define DIBUTTON_FISHING_ROTATE_LEFT_LINK 0x0E0244E4 /* Fallback turn body left button */ +#define DIBUTTON_FISHING_ROTATE_RIGHT_LINK 0x0E0244EC /* Fallback turn body right button */ +#define DIBUTTON_FISHING_DEVICE 0x0E0044FE /* Show input device and controls */ +#define DIBUTTON_FISHING_PAUSE 0x0E0044FC /* Start / Pause / Restart game */ + +/*--- Sports - Baseball - Batting + Batter control is primary objective ---*/ +#define DIVIRTUAL_SPORTS_BASEBALL_BAT 0x0F000000 +#define DIAXIS_BASEBALLB_LATERAL 0x0F008201 /* Aim left / right */ +#define DIAXIS_BASEBALLB_MOVE 0x0F010202 /* Aim up / down */ +#define DIBUTTON_BASEBALLB_SELECT 0x0F000401 /* cycle through swing options */ +#define DIBUTTON_BASEBALLB_NORMAL 0x0F000402 /* normal swing */ +#define DIBUTTON_BASEBALLB_POWER 0x0F000403 /* swing for the fence */ +#define DIBUTTON_BASEBALLB_BUNT 0x0F000404 /* bunt */ +#define DIBUTTON_BASEBALLB_STEAL 0x0F000405 /* Base runner attempts to steal a base */ +#define DIBUTTON_BASEBALLB_BURST 0x0F000406 /* Base runner invokes burst of speed */ +#define DIBUTTON_BASEBALLB_SLIDE 0x0F000407 /* Base runner slides into base */ +#define DIBUTTON_BASEBALLB_CONTACT 0x0F000408 /* Contact swing */ +#define DIBUTTON_BASEBALLB_MENU 0x0F0004FD /* Show menu options */ +/*--- Priority 2 controls ---*/ + +#define DIBUTTON_BASEBALLB_NOSTEAL 0x0F004409 /* Base runner goes back to a base */ +#define DIBUTTON_BASEBALLB_BOX 0x0F00440A /* Enter or exit batting box */ +#define DIBUTTON_BASEBALLB_LEFT_LINK 0x0F00C4E4 /* Fallback sidestep left button */ +#define DIBUTTON_BASEBALLB_RIGHT_LINK 0x0F00C4EC /* Fallback sidestep right button */ +#define DIBUTTON_BASEBALLB_FORWARD_LINK 0x0F0144E0 /* Fallback move forward button */ +#define DIBUTTON_BASEBALLB_BACK_LINK 0x0F0144E8 /* Fallback move back button */ +#define DIBUTTON_BASEBALLB_DEVICE 0x0F0044FE /* Show input device and controls */ +#define DIBUTTON_BASEBALLB_PAUSE 0x0F0044FC /* Start / Pause / Restart game */ + +/*--- Sports - Baseball - Pitching + Pitcher control is primary objective ---*/ +#define DIVIRTUAL_SPORTS_BASEBALL_PITCH 0x10000000 +#define DIAXIS_BASEBALLP_LATERAL 0x10008201 /* Aim left / right */ +#define DIAXIS_BASEBALLP_MOVE 0x10010202 /* Aim up / down */ +#define DIBUTTON_BASEBALLP_SELECT 0x10000401 /* cycle through pitch selections */ +#define DIBUTTON_BASEBALLP_PITCH 0x10000402 /* throw pitch */ +#define DIBUTTON_BASEBALLP_BASE 0x10000403 /* select base to throw to */ +#define DIBUTTON_BASEBALLP_THROW 0x10000404 /* throw to base */ +#define DIBUTTON_BASEBALLP_FAKE 0x10000405 /* Fake a throw to a base */ +#define DIBUTTON_BASEBALLP_MENU 0x100004FD /* Show menu options */ +/*--- Priority 2 controls ---*/ + +#define DIBUTTON_BASEBALLP_WALK 0x10004406 /* Throw intentional walk / pitch out */ +#define DIBUTTON_BASEBALLP_LOOK 0x10004407 /* Look at runners on bases */ +#define DIBUTTON_BASEBALLP_LEFT_LINK 0x1000C4E4 /* Fallback sidestep left button */ +#define DIBUTTON_BASEBALLP_RIGHT_LINK 0x1000C4EC /* Fallback sidestep right button */ +#define DIBUTTON_BASEBALLP_FORWARD_LINK 0x100144E0 /* Fallback move forward button */ +#define DIBUTTON_BASEBALLP_BACK_LINK 0x100144E8 /* Fallback move back button */ +#define DIBUTTON_BASEBALLP_DEVICE 0x100044FE /* Show input device and controls */ +#define DIBUTTON_BASEBALLP_PAUSE 0x100044FC /* Start / Pause / Restart game */ + +/*--- Sports - Baseball - Fielding + Fielder control is primary objective ---*/ +#define DIVIRTUAL_SPORTS_BASEBALL_FIELD 0x11000000 +#define DIAXIS_BASEBALLF_LATERAL 0x11008201 /* Aim left / right */ +#define DIAXIS_BASEBALLF_MOVE 0x11010202 /* Aim up / down */ +#define DIBUTTON_BASEBALLF_NEAREST 0x11000401 /* Switch to fielder nearest to the ball */ +#define DIBUTTON_BASEBALLF_THROW1 0x11000402 /* Make conservative throw */ +#define DIBUTTON_BASEBALLF_THROW2 0x11000403 /* Make aggressive throw */ +#define DIBUTTON_BASEBALLF_BURST 0x11000404 /* Invoke burst of speed */ +#define DIBUTTON_BASEBALLF_JUMP 0x11000405 /* Jump to catch ball */ +#define DIBUTTON_BASEBALLF_DIVE 0x11000406 /* Dive to catch ball */ +#define DIBUTTON_BASEBALLF_MENU 0x110004FD /* Show menu options */ +/*--- Priority 2 controls ---*/ + +#define DIBUTTON_BASEBALLF_SHIFTIN 0x11004407 /* Shift the infield positioning */ +#define DIBUTTON_BASEBALLF_SHIFTOUT 0x11004408 /* Shift the outfield positioning */ +#define DIBUTTON_BASEBALLF_AIM_LEFT_LINK 0x1100C4E4 /* Fallback aim left button */ +#define DIBUTTON_BASEBALLF_AIM_RIGHT_LINK 0x1100C4EC /* Fallback aim right button */ +#define DIBUTTON_BASEBALLF_FORWARD_LINK 0x110144E0 /* Fallback move forward button */ +#define DIBUTTON_BASEBALLF_BACK_LINK 0x110144E8 /* Fallback move back button */ +#define DIBUTTON_BASEBALLF_DEVICE 0x110044FE /* Show input device and controls */ +#define DIBUTTON_BASEBALLF_PAUSE 0x110044FC /* Start / Pause / Restart game */ + +/*--- Sports - Basketball - Offense + Offense ---*/ +#define DIVIRTUAL_SPORTS_BASKETBALL_OFFENSE 0x12000000 +#define DIAXIS_BBALLO_LATERAL 0x12008201 /* left / right */ +#define DIAXIS_BBALLO_MOVE 0x12010202 /* up / down */ +#define DIBUTTON_BBALLO_SHOOT 0x12000401 /* shoot basket */ +#define DIBUTTON_BBALLO_DUNK 0x12000402 /* dunk basket */ +#define DIBUTTON_BBALLO_PASS 0x12000403 /* throw pass */ +#define DIBUTTON_BBALLO_FAKE 0x12000404 /* fake shot or pass */ +#define DIBUTTON_BBALLO_SPECIAL 0x12000405 /* apply special move */ +#define DIBUTTON_BBALLO_PLAYER 0x12000406 /* select next player */ +#define DIBUTTON_BBALLO_BURST 0x12000407 /* invoke burst */ +#define DIBUTTON_BBALLO_CALL 0x12000408 /* call for ball / pass to me */ +#define DIBUTTON_BBALLO_MENU 0x120004FD /* Show menu options */ +/*--- Priority 2 controls ---*/ + +#define DIHATSWITCH_BBALLO_GLANCE 0x12004601 /* scroll view */ +#define DIBUTTON_BBALLO_SCREEN 0x12004409 /* Call for screen */ +#define DIBUTTON_BBALLO_PLAY 0x1200440A /* Call for specific offensive play */ +#define DIBUTTON_BBALLO_JAB 0x1200440B /* Initiate fake drive to basket */ +#define DIBUTTON_BBALLO_POST 0x1200440C /* Perform post move */ +#define DIBUTTON_BBALLO_TIMEOUT 0x1200440D /* Time Out */ +#define DIBUTTON_BBALLO_SUBSTITUTE 0x1200440E /* substitute one player for another */ +#define DIBUTTON_BBALLO_LEFT_LINK 0x1200C4E4 /* Fallback sidestep left button */ +#define DIBUTTON_BBALLO_RIGHT_LINK 0x1200C4EC /* Fallback sidestep right button */ +#define DIBUTTON_BBALLO_FORWARD_LINK 0x120144E0 /* Fallback move forward button */ +#define DIBUTTON_BBALLO_BACK_LINK 0x120144E8 /* Fallback move back button */ +#define DIBUTTON_BBALLO_DEVICE 0x120044FE /* Show input device and controls */ +#define DIBUTTON_BBALLO_PAUSE 0x120044FC /* Start / Pause / Restart game */ + +/*--- Sports - Basketball - Defense + Defense ---*/ +#define DIVIRTUAL_SPORTS_BASKETBALL_DEFENSE 0x13000000 +#define DIAXIS_BBALLD_LATERAL 0x13008201 /* left / right */ +#define DIAXIS_BBALLD_MOVE 0x13010202 /* up / down */ +#define DIBUTTON_BBALLD_JUMP 0x13000401 /* jump to block shot */ +#define DIBUTTON_BBALLD_STEAL 0x13000402 /* attempt to steal ball */ +#define DIBUTTON_BBALLD_FAKE 0x13000403 /* fake block or steal */ +#define DIBUTTON_BBALLD_SPECIAL 0x13000404 /* apply special move */ +#define DIBUTTON_BBALLD_PLAYER 0x13000405 /* select next player */ +#define DIBUTTON_BBALLD_BURST 0x13000406 /* invoke burst */ +#define DIBUTTON_BBALLD_PLAY 0x13000407 /* call for specific defensive play */ +#define DIBUTTON_BBALLD_MENU 0x130004FD /* Show menu options */ +/*--- Priority 2 controls ---*/ + +#define DIHATSWITCH_BBALLD_GLANCE 0x13004601 /* scroll view */ +#define DIBUTTON_BBALLD_TIMEOUT 0x13004408 /* Time Out */ +#define DIBUTTON_BBALLD_SUBSTITUTE 0x13004409 /* substitute one player for another */ +#define DIBUTTON_BBALLD_LEFT_LINK 0x1300C4E4 /* Fallback sidestep left button */ +#define DIBUTTON_BBALLD_RIGHT_LINK 0x1300C4EC /* Fallback sidestep right button */ +#define DIBUTTON_BBALLD_FORWARD_LINK 0x130144E0 /* Fallback move forward button */ +#define DIBUTTON_BBALLD_BACK_LINK 0x130144E8 /* Fallback move back button */ +#define DIBUTTON_BBALLD_DEVICE 0x130044FE /* Show input device and controls */ +#define DIBUTTON_BBALLD_PAUSE 0x130044FC /* Start / Pause / Restart game */ + +/*--- Sports - Football - Play + Play selection ---*/ +#define DIVIRTUAL_SPORTS_FOOTBALL_FIELD 0x14000000 +#define DIBUTTON_FOOTBALLP_PLAY 0x14000401 /* cycle through available plays */ +#define DIBUTTON_FOOTBALLP_SELECT 0x14000402 /* select play */ +#define DIBUTTON_FOOTBALLP_HELP 0x14000403 /* Bring up pop-up help */ +#define DIBUTTON_FOOTBALLP_MENU 0x140004FD /* Show menu options */ +/*--- Priority 2 controls ---*/ + +#define DIBUTTON_FOOTBALLP_DEVICE 0x140044FE /* Show input device and controls */ +#define DIBUTTON_FOOTBALLP_PAUSE 0x140044FC /* Start / Pause / Restart game */ + +/*--- Sports - Football - QB + Offense: Quarterback / Kicker ---*/ +#define DIVIRTUAL_SPORTS_FOOTBALL_QBCK 0x15000000 +#define DIAXIS_FOOTBALLQ_LATERAL 0x15008201 /* Move / Aim: left / right */ +#define DIAXIS_FOOTBALLQ_MOVE 0x15010202 /* Move / Aim: up / down */ +#define DIBUTTON_FOOTBALLQ_SELECT 0x15000401 /* Select */ +#define DIBUTTON_FOOTBALLQ_SNAP 0x15000402 /* snap ball - start play */ +#define DIBUTTON_FOOTBALLQ_JUMP 0x15000403 /* jump over defender */ +#define DIBUTTON_FOOTBALLQ_SLIDE 0x15000404 /* Dive/Slide */ +#define DIBUTTON_FOOTBALLQ_PASS 0x15000405 /* throws pass to receiver */ +#define DIBUTTON_FOOTBALLQ_FAKE 0x15000406 /* pump fake pass or fake kick */ +#define DIBUTTON_FOOTBALLQ_MENU 0x150004FD /* Show menu options */ +/*--- Priority 2 controls ---*/ + +#define DIBUTTON_FOOTBALLQ_FAKESNAP 0x15004407 /* Fake snap */ +#define DIBUTTON_FOOTBALLQ_MOTION 0x15004408 /* Send receivers in motion */ +#define DIBUTTON_FOOTBALLQ_AUDIBLE 0x15004409 /* Change offensive play at line of scrimmage */ +#define DIBUTTON_FOOTBALLQ_LEFT_LINK 0x1500C4E4 /* Fallback sidestep left button */ +#define DIBUTTON_FOOTBALLQ_RIGHT_LINK 0x1500C4EC /* Fallback sidestep right button */ +#define DIBUTTON_FOOTBALLQ_FORWARD_LINK 0x150144E0 /* Fallback move forward button */ +#define DIBUTTON_FOOTBALLQ_BACK_LINK 0x150144E8 /* Fallback move back button */ +#define DIBUTTON_FOOTBALLQ_DEVICE 0x150044FE /* Show input device and controls */ +#define DIBUTTON_FOOTBALLQ_PAUSE 0x150044FC /* Start / Pause / Restart game */ + +/*--- Sports - Football - Offense + Offense - Runner ---*/ +#define DIVIRTUAL_SPORTS_FOOTBALL_OFFENSE 0x16000000 +#define DIAXIS_FOOTBALLO_LATERAL 0x16008201 /* Move / Aim: left / right */ +#define DIAXIS_FOOTBALLO_MOVE 0x16010202 /* Move / Aim: up / down */ +#define DIBUTTON_FOOTBALLO_JUMP 0x16000401 /* jump or hurdle over defender */ +#define DIBUTTON_FOOTBALLO_LEFTARM 0x16000402 /* holds out left arm */ +#define DIBUTTON_FOOTBALLO_RIGHTARM 0x16000403 /* holds out right arm */ +#define DIBUTTON_FOOTBALLO_THROW 0x16000404 /* throw pass or lateral ball to another runner */ +#define DIBUTTON_FOOTBALLO_SPIN 0x16000405 /* Spin to avoid defenders */ +#define DIBUTTON_FOOTBALLO_MENU 0x160004FD /* Show menu options */ +/*--- Priority 2 controls ---*/ + +#define DIBUTTON_FOOTBALLO_JUKE 0x16004406 /* Use special move to avoid defenders */ +#define DIBUTTON_FOOTBALLO_SHOULDER 0x16004407 /* Lower shoulder to run over defenders */ +#define DIBUTTON_FOOTBALLO_TURBO 0x16004408 /* Speed burst past defenders */ +#define DIBUTTON_FOOTBALLO_DIVE 0x16004409 /* Dive over defenders */ +#define DIBUTTON_FOOTBALLO_ZOOM 0x1600440A /* Zoom view in / out */ +#define DIBUTTON_FOOTBALLO_SUBSTITUTE 0x1600440B /* substitute one player for another */ +#define DIBUTTON_FOOTBALLO_LEFT_LINK 0x1600C4E4 /* Fallback sidestep left button */ +#define DIBUTTON_FOOTBALLO_RIGHT_LINK 0x1600C4EC /* Fallback sidestep right button */ +#define DIBUTTON_FOOTBALLO_FORWARD_LINK 0x160144E0 /* Fallback move forward button */ +#define DIBUTTON_FOOTBALLO_BACK_LINK 0x160144E8 /* Fallback move back button */ +#define DIBUTTON_FOOTBALLO_DEVICE 0x160044FE /* Show input device and controls */ +#define DIBUTTON_FOOTBALLO_PAUSE 0x160044FC /* Start / Pause / Restart game */ + +/*--- Sports - Football - Defense + Defense ---*/ +#define DIVIRTUAL_SPORTS_FOOTBALL_DEFENSE 0x17000000 +#define DIAXIS_FOOTBALLD_LATERAL 0x17008201 /* Move / Aim: left / right */ +#define DIAXIS_FOOTBALLD_MOVE 0x17010202 /* Move / Aim: up / down */ +#define DIBUTTON_FOOTBALLD_PLAY 0x17000401 /* cycle through available plays */ +#define DIBUTTON_FOOTBALLD_SELECT 0x17000402 /* select player closest to the ball */ +#define DIBUTTON_FOOTBALLD_JUMP 0x17000403 /* jump to intercept or block */ +#define DIBUTTON_FOOTBALLD_TACKLE 0x17000404 /* tackler runner */ +#define DIBUTTON_FOOTBALLD_FAKE 0x17000405 /* hold down to fake tackle or intercept */ +#define DIBUTTON_FOOTBALLD_SUPERTACKLE 0x17000406 /* Initiate special tackle */ +#define DIBUTTON_FOOTBALLD_MENU 0x170004FD /* Show menu options */ +/*--- Priority 2 controls ---*/ + +#define DIBUTTON_FOOTBALLD_SPIN 0x17004407 /* Spin to beat offensive line */ +#define DIBUTTON_FOOTBALLD_SWIM 0x17004408 /* Swim to beat the offensive line */ +#define DIBUTTON_FOOTBALLD_BULLRUSH 0x17004409 /* Bull rush the offensive line */ +#define DIBUTTON_FOOTBALLD_RIP 0x1700440A /* Rip the offensive line */ +#define DIBUTTON_FOOTBALLD_AUDIBLE 0x1700440B /* Change defensive play at the line of scrimmage */ +#define DIBUTTON_FOOTBALLD_ZOOM 0x1700440C /* Zoom view in / out */ +#define DIBUTTON_FOOTBALLD_SUBSTITUTE 0x1700440D /* substitute one player for another */ +#define DIBUTTON_FOOTBALLD_LEFT_LINK 0x1700C4E4 /* Fallback sidestep left button */ +#define DIBUTTON_FOOTBALLD_RIGHT_LINK 0x1700C4EC /* Fallback sidestep right button */ +#define DIBUTTON_FOOTBALLD_FORWARD_LINK 0x170144E0 /* Fallback move forward button */ +#define DIBUTTON_FOOTBALLD_BACK_LINK 0x170144E8 /* Fallback move back button */ +#define DIBUTTON_FOOTBALLD_DEVICE 0x170044FE /* Show input device and controls */ +#define DIBUTTON_FOOTBALLD_PAUSE 0x170044FC /* Start / Pause / Restart game */ + +/*--- Sports - Golf + ---*/ +#define DIVIRTUAL_SPORTS_GOLF 0x18000000 +#define DIAXIS_GOLF_LATERAL 0x18008201 /* Move / Aim: left / right */ +#define DIAXIS_GOLF_MOVE 0x18010202 /* Move / Aim: up / down */ +#define DIBUTTON_GOLF_SWING 0x18000401 /* swing club */ +#define DIBUTTON_GOLF_SELECT 0x18000402 /* cycle between: club / swing strength / ball arc / ball spin */ +#define DIBUTTON_GOLF_UP 0x18000403 /* increase selection */ +#define DIBUTTON_GOLF_DOWN 0x18000404 /* decrease selection */ +#define DIBUTTON_GOLF_TERRAIN 0x18000405 /* shows terrain detail */ +#define DIBUTTON_GOLF_FLYBY 0x18000406 /* view the hole via a flyby */ +#define DIBUTTON_GOLF_MENU 0x180004FD /* Show menu options */ +/*--- Priority 2 controls ---*/ + +#define DIHATSWITCH_GOLF_SCROLL 0x18004601 /* scroll view */ +#define DIBUTTON_GOLF_ZOOM 0x18004407 /* Zoom view in / out */ +#define DIBUTTON_GOLF_TIMEOUT 0x18004408 /* Call for time out */ +#define DIBUTTON_GOLF_SUBSTITUTE 0x18004409 /* substitute one player for another */ +#define DIBUTTON_GOLF_LEFT_LINK 0x1800C4E4 /* Fallback sidestep left button */ +#define DIBUTTON_GOLF_RIGHT_LINK 0x1800C4EC /* Fallback sidestep right button */ +#define DIBUTTON_GOLF_FORWARD_LINK 0x180144E0 /* Fallback move forward button */ +#define DIBUTTON_GOLF_BACK_LINK 0x180144E8 /* Fallback move back button */ +#define DIBUTTON_GOLF_DEVICE 0x180044FE /* Show input device and controls */ +#define DIBUTTON_GOLF_PAUSE 0x180044FC /* Start / Pause / Restart game */ + +/*--- Sports - Hockey - Offense + Offense ---*/ +#define DIVIRTUAL_SPORTS_HOCKEY_OFFENSE 0x19000000 +#define DIAXIS_HOCKEYO_LATERAL 0x19008201 /* Move / Aim: left / right */ +#define DIAXIS_HOCKEYO_MOVE 0x19010202 /* Move / Aim: up / down */ +#define DIBUTTON_HOCKEYO_SHOOT 0x19000401 /* Shoot */ +#define DIBUTTON_HOCKEYO_PASS 0x19000402 /* pass the puck */ +#define DIBUTTON_HOCKEYO_BURST 0x19000403 /* invoke speed burst */ +#define DIBUTTON_HOCKEYO_SPECIAL 0x19000404 /* invoke special move */ +#define DIBUTTON_HOCKEYO_FAKE 0x19000405 /* hold down to fake pass or kick */ +#define DIBUTTON_HOCKEYO_MENU 0x190004FD /* Show menu options */ +/*--- Priority 2 controls ---*/ + +#define DIHATSWITCH_HOCKEYO_SCROLL 0x19004601 /* scroll view */ +#define DIBUTTON_HOCKEYO_ZOOM 0x19004406 /* Zoom view in / out */ +#define DIBUTTON_HOCKEYO_STRATEGY 0x19004407 /* Invoke coaching menu for strategy help */ +#define DIBUTTON_HOCKEYO_TIMEOUT 0x19004408 /* Call for time out */ +#define DIBUTTON_HOCKEYO_SUBSTITUTE 0x19004409 /* substitute one player for another */ +#define DIBUTTON_HOCKEYO_LEFT_LINK 0x1900C4E4 /* Fallback sidestep left button */ +#define DIBUTTON_HOCKEYO_RIGHT_LINK 0x1900C4EC /* Fallback sidestep right button */ +#define DIBUTTON_HOCKEYO_FORWARD_LINK 0x190144E0 /* Fallback move forward button */ +#define DIBUTTON_HOCKEYO_BACK_LINK 0x190144E8 /* Fallback move back button */ +#define DIBUTTON_HOCKEYO_DEVICE 0x190044FE /* Show input device and controls */ +#define DIBUTTON_HOCKEYO_PAUSE 0x190044FC /* Start / Pause / Restart game */ + +/*--- Sports - Hockey - Defense + Defense ---*/ +#define DIVIRTUAL_SPORTS_HOCKEY_DEFENSE 0x1A000000 +#define DIAXIS_HOCKEYD_LATERAL 0x1A008201 /* Move / Aim: left / right */ +#define DIAXIS_HOCKEYD_MOVE 0x1A010202 /* Move / Aim: up / down */ +#define DIBUTTON_HOCKEYD_PLAYER 0x1A000401 /* control player closest to the puck */ +#define DIBUTTON_HOCKEYD_STEAL 0x1A000402 /* attempt steal */ +#define DIBUTTON_HOCKEYD_BURST 0x1A000403 /* speed burst or body check */ +#define DIBUTTON_HOCKEYD_BLOCK 0x1A000404 /* block puck */ +#define DIBUTTON_HOCKEYD_FAKE 0x1A000405 /* hold down to fake tackle or intercept */ +#define DIBUTTON_HOCKEYD_MENU 0x1A0004FD /* Show menu options */ +/*--- Priority 2 controls ---*/ + +#define DIHATSWITCH_HOCKEYD_SCROLL 0x1A004601 /* scroll view */ +#define DIBUTTON_HOCKEYD_ZOOM 0x1A004406 /* Zoom view in / out */ +#define DIBUTTON_HOCKEYD_STRATEGY 0x1A004407 /* Invoke coaching menu for strategy help */ +#define DIBUTTON_HOCKEYD_TIMEOUT 0x1A004408 /* Call for time out */ +#define DIBUTTON_HOCKEYD_SUBSTITUTE 0x1A004409 /* substitute one player for another */ +#define DIBUTTON_HOCKEYD_LEFT_LINK 0x1A00C4E4 /* Fallback sidestep left button */ +#define DIBUTTON_HOCKEYD_RIGHT_LINK 0x1A00C4EC /* Fallback sidestep right button */ +#define DIBUTTON_HOCKEYD_FORWARD_LINK 0x1A0144E0 /* Fallback move forward button */ +#define DIBUTTON_HOCKEYD_BACK_LINK 0x1A0144E8 /* Fallback move back button */ +#define DIBUTTON_HOCKEYD_DEVICE 0x1A0044FE /* Show input device and controls */ +#define DIBUTTON_HOCKEYD_PAUSE 0x1A0044FC /* Start / Pause / Restart game */ + +/*--- Sports - Hockey - Goalie + Goal tending ---*/ +#define DIVIRTUAL_SPORTS_HOCKEY_GOALIE 0x1B000000 +#define DIAXIS_HOCKEYG_LATERAL 0x1B008201 /* Move / Aim: left / right */ +#define DIAXIS_HOCKEYG_MOVE 0x1B010202 /* Move / Aim: up / down */ +#define DIBUTTON_HOCKEYG_PASS 0x1B000401 /* pass puck */ +#define DIBUTTON_HOCKEYG_POKE 0x1B000402 /* poke / check / hack */ +#define DIBUTTON_HOCKEYG_STEAL 0x1B000403 /* attempt steal */ +#define DIBUTTON_HOCKEYG_BLOCK 0x1B000404 /* block puck */ +#define DIBUTTON_HOCKEYG_MENU 0x1B0004FD /* Show menu options */ +/*--- Priority 2 controls ---*/ + +#define DIHATSWITCH_HOCKEYG_SCROLL 0x1B004601 /* scroll view */ +#define DIBUTTON_HOCKEYG_ZOOM 0x1B004405 /* Zoom view in / out */ +#define DIBUTTON_HOCKEYG_STRATEGY 0x1B004406 /* Invoke coaching menu for strategy help */ +#define DIBUTTON_HOCKEYG_TIMEOUT 0x1B004407 /* Call for time out */ +#define DIBUTTON_HOCKEYG_SUBSTITUTE 0x1B004408 /* substitute one player for another */ +#define DIBUTTON_HOCKEYG_LEFT_LINK 0x1B00C4E4 /* Fallback sidestep left button */ +#define DIBUTTON_HOCKEYG_RIGHT_LINK 0x1B00C4EC /* Fallback sidestep right button */ +#define DIBUTTON_HOCKEYG_FORWARD_LINK 0x1B0144E0 /* Fallback move forward button */ +#define DIBUTTON_HOCKEYG_BACK_LINK 0x1B0144E8 /* Fallback move back button */ +#define DIBUTTON_HOCKEYG_DEVICE 0x1B0044FE /* Show input device and controls */ +#define DIBUTTON_HOCKEYG_PAUSE 0x1B0044FC /* Start / Pause / Restart game */ + +/*--- Sports - Mountain Biking + ---*/ +#define DIVIRTUAL_SPORTS_BIKING_MOUNTAIN 0x1C000000 +#define DIAXIS_BIKINGM_TURN 0x1C008201 /* left / right */ +#define DIAXIS_BIKINGM_PEDAL 0x1C010202 /* Pedal faster / slower / brake */ +#define DIBUTTON_BIKINGM_JUMP 0x1C000401 /* jump over obstacle */ +#define DIBUTTON_BIKINGM_CAMERA 0x1C000402 /* switch camera view */ +#define DIBUTTON_BIKINGM_SPECIAL1 0x1C000403 /* perform first special move */ +#define DIBUTTON_BIKINGM_SELECT 0x1C000404 /* Select */ +#define DIBUTTON_BIKINGM_SPECIAL2 0x1C000405 /* perform second special move */ +#define DIBUTTON_BIKINGM_MENU 0x1C0004FD /* Show menu options */ +/*--- Priority 2 controls ---*/ + +#define DIHATSWITCH_BIKINGM_SCROLL 0x1C004601 /* scroll view */ +#define DIBUTTON_BIKINGM_ZOOM 0x1C004406 /* Zoom view in / out */ +#define DIAXIS_BIKINGM_BRAKE 0x1C044203 /* Brake axis */ +#define DIBUTTON_BIKINGM_LEFT_LINK 0x1C00C4E4 /* Fallback turn left button */ +#define DIBUTTON_BIKINGM_RIGHT_LINK 0x1C00C4EC /* Fallback turn right button */ +#define DIBUTTON_BIKINGM_FASTER_LINK 0x1C0144E0 /* Fallback pedal faster button */ +#define DIBUTTON_BIKINGM_SLOWER_LINK 0x1C0144E8 /* Fallback pedal slower button */ +#define DIBUTTON_BIKINGM_BRAKE_BUTTON_LINK 0x1C0444E8 /* Fallback brake button */ +#define DIBUTTON_BIKINGM_DEVICE 0x1C0044FE /* Show input device and controls */ +#define DIBUTTON_BIKINGM_PAUSE 0x1C0044FC /* Start / Pause / Restart game */ + +/*--- Sports: Skiing / Snowboarding / Skateboarding + ---*/ +#define DIVIRTUAL_SPORTS_SKIING 0x1D000000 +#define DIAXIS_SKIING_TURN 0x1D008201 /* left / right */ +#define DIAXIS_SKIING_SPEED 0x1D010202 /* faster / slower */ +#define DIBUTTON_SKIING_JUMP 0x1D000401 /* Jump */ +#define DIBUTTON_SKIING_CROUCH 0x1D000402 /* crouch down */ +#define DIBUTTON_SKIING_CAMERA 0x1D000403 /* switch camera view */ +#define DIBUTTON_SKIING_SPECIAL1 0x1D000404 /* perform first special move */ +#define DIBUTTON_SKIING_SELECT 0x1D000405 /* Select */ +#define DIBUTTON_SKIING_SPECIAL2 0x1D000406 /* perform second special move */ +#define DIBUTTON_SKIING_MENU 0x1D0004FD /* Show menu options */ +/*--- Priority 2 controls ---*/ + +#define DIHATSWITCH_SKIING_GLANCE 0x1D004601 /* scroll view */ +#define DIBUTTON_SKIING_ZOOM 0x1D004407 /* Zoom view in / out */ +#define DIBUTTON_SKIING_LEFT_LINK 0x1D00C4E4 /* Fallback turn left button */ +#define DIBUTTON_SKIING_RIGHT_LINK 0x1D00C4EC /* Fallback turn right button */ +#define DIBUTTON_SKIING_FASTER_LINK 0x1D0144E0 /* Fallback increase speed button */ +#define DIBUTTON_SKIING_SLOWER_LINK 0x1D0144E8 /* Fallback decrease speed button */ +#define DIBUTTON_SKIING_DEVICE 0x1D0044FE /* Show input device and controls */ +#define DIBUTTON_SKIING_PAUSE 0x1D0044FC /* Start / Pause / Restart game */ + +/*--- Sports - Soccer - Offense + Offense ---*/ +#define DIVIRTUAL_SPORTS_SOCCER_OFFENSE 0x1E000000 +#define DIAXIS_SOCCERO_LATERAL 0x1E008201 /* Move / Aim: left / right */ +#define DIAXIS_SOCCERO_MOVE 0x1E010202 /* Move / Aim: up / down */ +#define DIAXIS_SOCCERO_BEND 0x1E018203 /* Bend to soccer shot/pass */ +#define DIBUTTON_SOCCERO_SHOOT 0x1E000401 /* Shoot the ball */ +#define DIBUTTON_SOCCERO_PASS 0x1E000402 /* Pass */ +#define DIBUTTON_SOCCERO_FAKE 0x1E000403 /* Fake */ +#define DIBUTTON_SOCCERO_PLAYER 0x1E000404 /* Select next player */ +#define DIBUTTON_SOCCERO_SPECIAL1 0x1E000405 /* Apply special move */ +#define DIBUTTON_SOCCERO_SELECT 0x1E000406 /* Select special move */ +#define DIBUTTON_SOCCERO_MENU 0x1E0004FD /* Show menu options */ +/*--- Priority 2 controls ---*/ + +#define DIHATSWITCH_SOCCERO_GLANCE 0x1E004601 /* scroll view */ +#define DIBUTTON_SOCCERO_SUBSTITUTE 0x1E004407 /* Substitute one player for another */ +#define DIBUTTON_SOCCERO_SHOOTLOW 0x1E004408 /* Shoot the ball low */ +#define DIBUTTON_SOCCERO_SHOOTHIGH 0x1E004409 /* Shoot the ball high */ +#define DIBUTTON_SOCCERO_PASSTHRU 0x1E00440A /* Make a thru pass */ +#define DIBUTTON_SOCCERO_SPRINT 0x1E00440B /* Sprint / turbo boost */ +#define DIBUTTON_SOCCERO_CONTROL 0x1E00440C /* Obtain control of the ball */ +#define DIBUTTON_SOCCERO_HEAD 0x1E00440D /* Attempt to head the ball */ +#define DIBUTTON_SOCCERO_LEFT_LINK 0x1E00C4E4 /* Fallback sidestep left button */ +#define DIBUTTON_SOCCERO_RIGHT_LINK 0x1E00C4EC /* Fallback sidestep right button */ +#define DIBUTTON_SOCCERO_FORWARD_LINK 0x1E0144E0 /* Fallback move forward button */ +#define DIBUTTON_SOCCERO_BACK_LINK 0x1E0144E8 /* Fallback move back button */ +#define DIBUTTON_SOCCERO_DEVICE 0x1E0044FE /* Show input device and controls */ +#define DIBUTTON_SOCCERO_PAUSE 0x1E0044FC /* Start / Pause / Restart game */ + +/*--- Sports - Soccer - Defense + Defense ---*/ +#define DIVIRTUAL_SPORTS_SOCCER_DEFENSE 0x1F000000 +#define DIAXIS_SOCCERD_LATERAL 0x1F008201 /* Move / Aim: left / right */ +#define DIAXIS_SOCCERD_MOVE 0x1F010202 /* Move / Aim: up / down */ +#define DIBUTTON_SOCCERD_BLOCK 0x1F000401 /* Attempt to block shot */ +#define DIBUTTON_SOCCERD_STEAL 0x1F000402 /* Attempt to steal ball */ +#define DIBUTTON_SOCCERD_FAKE 0x1F000403 /* Fake a block or a steal */ +#define DIBUTTON_SOCCERD_PLAYER 0x1F000404 /* Select next player */ +#define DIBUTTON_SOCCERD_SPECIAL 0x1F000405 /* Apply special move */ +#define DIBUTTON_SOCCERD_SELECT 0x1F000406 /* Select special move */ +#define DIBUTTON_SOCCERD_SLIDE 0x1F000407 /* Attempt a slide tackle */ +#define DIBUTTON_SOCCERD_MENU 0x1F0004FD /* Show menu options */ +/*--- Priority 2 controls ---*/ + +#define DIHATSWITCH_SOCCERD_GLANCE 0x1F004601 /* scroll view */ +#define DIBUTTON_SOCCERD_FOUL 0x1F004408 /* Initiate a foul / hard-foul */ +#define DIBUTTON_SOCCERD_HEAD 0x1F004409 /* Attempt a Header */ +#define DIBUTTON_SOCCERD_CLEAR 0x1F00440A /* Attempt to clear the ball down the field */ +#define DIBUTTON_SOCCERD_GOALIECHARGE 0x1F00440B /* Make the goalie charge out of the box */ +#define DIBUTTON_SOCCERD_SUBSTITUTE 0x1F00440C /* Substitute one player for another */ +#define DIBUTTON_SOCCERD_LEFT_LINK 0x1F00C4E4 /* Fallback sidestep left button */ +#define DIBUTTON_SOCCERD_RIGHT_LINK 0x1F00C4EC /* Fallback sidestep right button */ +#define DIBUTTON_SOCCERD_FORWARD_LINK 0x1F0144E0 /* Fallback move forward button */ +#define DIBUTTON_SOCCERD_BACK_LINK 0x1F0144E8 /* Fallback move back button */ +#define DIBUTTON_SOCCERD_DEVICE 0x1F0044FE /* Show input device and controls */ +#define DIBUTTON_SOCCERD_PAUSE 0x1F0044FC /* Start / Pause / Restart game */ + +/*--- Sports - Racquet + Tennis - Table-Tennis - Squash ---*/ +#define DIVIRTUAL_SPORTS_RACQUET 0x20000000 +#define DIAXIS_RACQUET_LATERAL 0x20008201 /* Move / Aim: left / right */ +#define DIAXIS_RACQUET_MOVE 0x20010202 /* Move / Aim: up / down */ +#define DIBUTTON_RACQUET_SWING 0x20000401 /* Swing racquet */ +#define DIBUTTON_RACQUET_BACKSWING 0x20000402 /* Swing backhand */ +#define DIBUTTON_RACQUET_SMASH 0x20000403 /* Smash shot */ +#define DIBUTTON_RACQUET_SPECIAL 0x20000404 /* Special shot */ +#define DIBUTTON_RACQUET_SELECT 0x20000405 /* Select special shot */ +#define DIBUTTON_RACQUET_MENU 0x200004FD /* Show menu options */ +/*--- Priority 2 controls ---*/ + +#define DIHATSWITCH_RACQUET_GLANCE 0x20004601 /* scroll view */ +#define DIBUTTON_RACQUET_TIMEOUT 0x20004406 /* Call for time out */ +#define DIBUTTON_RACQUET_SUBSTITUTE 0x20004407 /* Substitute one player for another */ +#define DIBUTTON_RACQUET_LEFT_LINK 0x2000C4E4 /* Fallback sidestep left button */ +#define DIBUTTON_RACQUET_RIGHT_LINK 0x2000C4EC /* Fallback sidestep right button */ +#define DIBUTTON_RACQUET_FORWARD_LINK 0x200144E0 /* Fallback move forward button */ +#define DIBUTTON_RACQUET_BACK_LINK 0x200144E8 /* Fallback move back button */ +#define DIBUTTON_RACQUET_DEVICE 0x200044FE /* Show input device and controls */ +#define DIBUTTON_RACQUET_PAUSE 0x200044FC /* Start / Pause / Restart game */ + +/*--- Arcade- 2D + Side to Side movement ---*/ +#define DIVIRTUAL_ARCADE_SIDE2SIDE 0x21000000 +#define DIAXIS_ARCADES_LATERAL 0x21008201 /* left / right */ +#define DIAXIS_ARCADES_MOVE 0x21010202 /* up / down */ +#define DIBUTTON_ARCADES_THROW 0x21000401 /* throw object */ +#define DIBUTTON_ARCADES_CARRY 0x21000402 /* carry object */ +#define DIBUTTON_ARCADES_ATTACK 0x21000403 /* attack */ +#define DIBUTTON_ARCADES_SPECIAL 0x21000404 /* apply special move */ +#define DIBUTTON_ARCADES_SELECT 0x21000405 /* select special move */ +#define DIBUTTON_ARCADES_MENU 0x210004FD /* Show menu options */ +/*--- Priority 2 controls ---*/ + +#define DIHATSWITCH_ARCADES_VIEW 0x21004601 /* scroll view left / right / up / down */ +#define DIBUTTON_ARCADES_LEFT_LINK 0x2100C4E4 /* Fallback sidestep left button */ +#define DIBUTTON_ARCADES_RIGHT_LINK 0x2100C4EC /* Fallback sidestep right button */ +#define DIBUTTON_ARCADES_FORWARD_LINK 0x210144E0 /* Fallback move forward button */ +#define DIBUTTON_ARCADES_BACK_LINK 0x210144E8 /* Fallback move back button */ +#define DIBUTTON_ARCADES_VIEW_UP_LINK 0x2107C4E0 /* Fallback scroll view up button */ +#define DIBUTTON_ARCADES_VIEW_DOWN_LINK 0x2107C4E8 /* Fallback scroll view down button */ +#define DIBUTTON_ARCADES_VIEW_LEFT_LINK 0x2107C4E4 /* Fallback scroll view left button */ +#define DIBUTTON_ARCADES_VIEW_RIGHT_LINK 0x2107C4EC /* Fallback scroll view right button */ +#define DIBUTTON_ARCADES_DEVICE 0x210044FE /* Show input device and controls */ +#define DIBUTTON_ARCADES_PAUSE 0x210044FC /* Start / Pause / Restart game */ + +/*--- Arcade - Platform Game + Character moves around on screen ---*/ +#define DIVIRTUAL_ARCADE_PLATFORM 0x22000000 +#define DIAXIS_ARCADEP_LATERAL 0x22008201 /* Left / right */ +#define DIAXIS_ARCADEP_MOVE 0x22010202 /* Up / down */ +#define DIBUTTON_ARCADEP_JUMP 0x22000401 /* Jump */ +#define DIBUTTON_ARCADEP_FIRE 0x22000402 /* Fire */ +#define DIBUTTON_ARCADEP_CROUCH 0x22000403 /* Crouch */ +#define DIBUTTON_ARCADEP_SPECIAL 0x22000404 /* Apply special move */ +#define DIBUTTON_ARCADEP_SELECT 0x22000405 /* Select special move */ +#define DIBUTTON_ARCADEP_MENU 0x220004FD /* Show menu options */ +/*--- Priority 2 controls ---*/ + +#define DIHATSWITCH_ARCADEP_VIEW 0x22004601 /* Scroll view */ +#define DIBUTTON_ARCADEP_FIRESECONDARY 0x22004406 /* Alternative fire button */ +#define DIBUTTON_ARCADEP_LEFT_LINK 0x2200C4E4 /* Fallback sidestep left button */ +#define DIBUTTON_ARCADEP_RIGHT_LINK 0x2200C4EC /* Fallback sidestep right button */ +#define DIBUTTON_ARCADEP_FORWARD_LINK 0x220144E0 /* Fallback move forward button */ +#define DIBUTTON_ARCADEP_BACK_LINK 0x220144E8 /* Fallback move back button */ +#define DIBUTTON_ARCADEP_VIEW_UP_LINK 0x2207C4E0 /* Fallback scroll view up button */ +#define DIBUTTON_ARCADEP_VIEW_DOWN_LINK 0x2207C4E8 /* Fallback scroll view down button */ +#define DIBUTTON_ARCADEP_VIEW_LEFT_LINK 0x2207C4E4 /* Fallback scroll view left button */ +#define DIBUTTON_ARCADEP_VIEW_RIGHT_LINK 0x2207C4EC /* Fallback scroll view right button */ +#define DIBUTTON_ARCADEP_DEVICE 0x220044FE /* Show input device and controls */ +#define DIBUTTON_ARCADEP_PAUSE 0x220044FC /* Start / Pause / Restart game */ + +/*--- CAD - 2D Object Control + Controls to select and move objects in 2D ---*/ +#define DIVIRTUAL_CAD_2DCONTROL 0x23000000 +#define DIAXIS_2DCONTROL_LATERAL 0x23008201 /* Move view left / right */ +#define DIAXIS_2DCONTROL_MOVE 0x23010202 /* Move view up / down */ +#define DIAXIS_2DCONTROL_INOUT 0x23018203 /* Zoom - in / out */ +#define DIBUTTON_2DCONTROL_SELECT 0x23000401 /* Select Object */ +#define DIBUTTON_2DCONTROL_SPECIAL1 0x23000402 /* Do first special operation */ +#define DIBUTTON_2DCONTROL_SPECIAL 0x23000403 /* Select special operation */ +#define DIBUTTON_2DCONTROL_SPECIAL2 0x23000404 /* Do second special operation */ +#define DIBUTTON_2DCONTROL_MENU 0x230004FD /* Show menu options */ +/*--- Priority 2 controls ---*/ + +#define DIHATSWITCH_2DCONTROL_HATSWITCH 0x23004601 /* Hat switch */ +#define DIAXIS_2DCONTROL_ROTATEZ 0x23024204 /* Rotate view clockwise / counterclockwise */ +#define DIBUTTON_2DCONTROL_DISPLAY 0x23004405 /* Shows next on-screen display options */ +#define DIBUTTON_2DCONTROL_DEVICE 0x230044FE /* Show input device and controls */ +#define DIBUTTON_2DCONTROL_PAUSE 0x230044FC /* Start / Pause / Restart game */ + +/*--- CAD - 3D object control + Controls to select and move objects within a 3D environment ---*/ +#define DIVIRTUAL_CAD_3DCONTROL 0x24000000 +#define DIAXIS_3DCONTROL_LATERAL 0x24008201 /* Move view left / right */ +#define DIAXIS_3DCONTROL_MOVE 0x24010202 /* Move view up / down */ +#define DIAXIS_3DCONTROL_INOUT 0x24018203 /* Zoom - in / out */ +#define DIBUTTON_3DCONTROL_SELECT 0x24000401 /* Select Object */ +#define DIBUTTON_3DCONTROL_SPECIAL1 0x24000402 /* Do first special operation */ +#define DIBUTTON_3DCONTROL_SPECIAL 0x24000403 /* Select special operation */ +#define DIBUTTON_3DCONTROL_SPECIAL2 0x24000404 /* Do second special operation */ +#define DIBUTTON_3DCONTROL_MENU 0x240004FD /* Show menu options */ +/*--- Priority 2 controls ---*/ + +#define DIHATSWITCH_3DCONTROL_HATSWITCH 0x24004601 /* Hat switch */ +#define DIAXIS_3DCONTROL_ROTATEX 0x24034204 /* Rotate view forward or up / backward or down */ +#define DIAXIS_3DCONTROL_ROTATEY 0x2402C205 /* Rotate view clockwise / counterclockwise */ +#define DIAXIS_3DCONTROL_ROTATEZ 0x24024206 /* Rotate view left / right */ +#define DIBUTTON_3DCONTROL_DISPLAY 0x24004405 /* Show next on-screen display options */ +#define DIBUTTON_3DCONTROL_DEVICE 0x240044FE /* Show input device and controls */ +#define DIBUTTON_3DCONTROL_PAUSE 0x240044FC /* Start / Pause / Restart game */ + +/*--- CAD - 3D Navigation - Fly through + Controls for 3D modeling ---*/ +#define DIVIRTUAL_CAD_FLYBY 0x25000000 +#define DIAXIS_CADF_LATERAL 0x25008201 /* move view left / right */ +#define DIAXIS_CADF_MOVE 0x25010202 /* move view up / down */ +#define DIAXIS_CADF_INOUT 0x25018203 /* in / out */ +#define DIBUTTON_CADF_SELECT 0x25000401 /* Select Object */ +#define DIBUTTON_CADF_SPECIAL1 0x25000402 /* do first special operation */ +#define DIBUTTON_CADF_SPECIAL 0x25000403 /* Select special operation */ +#define DIBUTTON_CADF_SPECIAL2 0x25000404 /* do second special operation */ +#define DIBUTTON_CADF_MENU 0x250004FD /* Show menu options */ +/*--- Priority 2 controls ---*/ + +#define DIHATSWITCH_CADF_HATSWITCH 0x25004601 /* Hat switch */ +#define DIAXIS_CADF_ROTATEX 0x25034204 /* Rotate view forward or up / backward or down */ +#define DIAXIS_CADF_ROTATEY 0x2502C205 /* Rotate view clockwise / counterclockwise */ +#define DIAXIS_CADF_ROTATEZ 0x25024206 /* Rotate view left / right */ +#define DIBUTTON_CADF_DISPLAY 0x25004405 /* shows next on-screen display options */ +#define DIBUTTON_CADF_DEVICE 0x250044FE /* Show input device and controls */ +#define DIBUTTON_CADF_PAUSE 0x250044FC /* Start / Pause / Restart game */ + +/*--- CAD - 3D Model Control + Controls for 3D modeling ---*/ +#define DIVIRTUAL_CAD_MODEL 0x26000000 +#define DIAXIS_CADM_LATERAL 0x26008201 /* move view left / right */ +#define DIAXIS_CADM_MOVE 0x26010202 /* move view up / down */ +#define DIAXIS_CADM_INOUT 0x26018203 /* in / out */ +#define DIBUTTON_CADM_SELECT 0x26000401 /* Select Object */ +#define DIBUTTON_CADM_SPECIAL1 0x26000402 /* do first special operation */ +#define DIBUTTON_CADM_SPECIAL 0x26000403 /* Select special operation */ +#define DIBUTTON_CADM_SPECIAL2 0x26000404 /* do second special operation */ +#define DIBUTTON_CADM_MENU 0x260004FD /* Show menu options */ +/*--- Priority 2 controls ---*/ + +#define DIHATSWITCH_CADM_HATSWITCH 0x26004601 /* Hat switch */ +#define DIAXIS_CADM_ROTATEX 0x26034204 /* Rotate view forward or up / backward or down */ +#define DIAXIS_CADM_ROTATEY 0x2602C205 /* Rotate view clockwise / counterclockwise */ +#define DIAXIS_CADM_ROTATEZ 0x26024206 /* Rotate view left / right */ +#define DIBUTTON_CADM_DISPLAY 0x26004405 /* shows next on-screen display options */ +#define DIBUTTON_CADM_DEVICE 0x260044FE /* Show input device and controls */ +#define DIBUTTON_CADM_PAUSE 0x260044FC /* Start / Pause / Restart game */ + +/*--- Control - Media Equipment + Remote ---*/ +#define DIVIRTUAL_REMOTE_CONTROL 0x27000000 +#define DIAXIS_REMOTE_SLIDER 0x27050201 /* Slider for adjustment: volume / color / bass / etc */ +#define DIBUTTON_REMOTE_MUTE 0x27000401 /* Set volume on current device to zero */ +#define DIBUTTON_REMOTE_SELECT 0x27000402 /* Next/previous: channel/ track / chapter / picture / station */ +#define DIBUTTON_REMOTE_PLAY 0x27002403 /* Start or pause entertainment on current device */ +#define DIBUTTON_REMOTE_CUE 0x27002404 /* Move through current media */ +#define DIBUTTON_REMOTE_REVIEW 0x27002405 /* Move through current media */ +#define DIBUTTON_REMOTE_CHANGE 0x27002406 /* Select next device */ +#define DIBUTTON_REMOTE_RECORD 0x27002407 /* Start recording the current media */ +#define DIBUTTON_REMOTE_MENU 0x270004FD /* Show menu options */ +/*--- Priority 2 controls ---*/ + +#define DIAXIS_REMOTE_SLIDER2 0x27054202 /* Slider for adjustment: volume */ +#define DIBUTTON_REMOTE_TV 0x27005C08 /* Select TV */ +#define DIBUTTON_REMOTE_CABLE 0x27005C09 /* Select cable box */ +#define DIBUTTON_REMOTE_CD 0x27005C0A /* Select CD player */ +#define DIBUTTON_REMOTE_VCR 0x27005C0B /* Select VCR */ +#define DIBUTTON_REMOTE_TUNER 0x27005C0C /* Select tuner */ +#define DIBUTTON_REMOTE_DVD 0x27005C0D /* Select DVD player */ +#define DIBUTTON_REMOTE_ADJUST 0x27005C0E /* Enter device adjustment menu */ +#define DIBUTTON_REMOTE_DIGIT0 0x2700540F /* Digit 0 */ +#define DIBUTTON_REMOTE_DIGIT1 0x27005410 /* Digit 1 */ +#define DIBUTTON_REMOTE_DIGIT2 0x27005411 /* Digit 2 */ +#define DIBUTTON_REMOTE_DIGIT3 0x27005412 /* Digit 3 */ +#define DIBUTTON_REMOTE_DIGIT4 0x27005413 /* Digit 4 */ +#define DIBUTTON_REMOTE_DIGIT5 0x27005414 /* Digit 5 */ +#define DIBUTTON_REMOTE_DIGIT6 0x27005415 /* Digit 6 */ +#define DIBUTTON_REMOTE_DIGIT7 0x27005416 /* Digit 7 */ +#define DIBUTTON_REMOTE_DIGIT8 0x27005417 /* Digit 8 */ +#define DIBUTTON_REMOTE_DIGIT9 0x27005418 /* Digit 9 */ +#define DIBUTTON_REMOTE_DEVICE 0x270044FE /* Show input device and controls */ +#define DIBUTTON_REMOTE_PAUSE 0x270044FC /* Start / Pause / Restart game */ + +/*--- Control- Web + Help or Browser ---*/ +#define DIVIRTUAL_BROWSER_CONTROL 0x28000000 +#define DIAXIS_BROWSER_LATERAL 0x28008201 /* Move on screen pointer */ +#define DIAXIS_BROWSER_MOVE 0x28010202 /* Move on screen pointer */ +#define DIBUTTON_BROWSER_SELECT 0x28000401 /* Select current item */ +#define DIAXIS_BROWSER_VIEW 0x28018203 /* Move view up/down */ +#define DIBUTTON_BROWSER_REFRESH 0x28000402 /* Refresh */ +#define DIBUTTON_BROWSER_MENU 0x280004FD /* Show menu options */ +/*--- Priority 2 controls ---*/ + +#define DIBUTTON_BROWSER_SEARCH 0x28004403 /* Use search tool */ +#define DIBUTTON_BROWSER_STOP 0x28004404 /* Cease current update */ +#define DIBUTTON_BROWSER_HOME 0x28004405 /* Go directly to "home" location */ +#define DIBUTTON_BROWSER_FAVORITES 0x28004406 /* Mark current site as favorite */ +#define DIBUTTON_BROWSER_NEXT 0x28004407 /* Select Next page */ +#define DIBUTTON_BROWSER_PREVIOUS 0x28004408 /* Select Previous page */ +#define DIBUTTON_BROWSER_HISTORY 0x28004409 /* Show/Hide History */ +#define DIBUTTON_BROWSER_PRINT 0x2800440A /* Print current page */ +#define DIBUTTON_BROWSER_DEVICE 0x280044FE /* Show input device and controls */ +#define DIBUTTON_BROWSER_PAUSE 0x280044FC /* Start / Pause / Restart game */ + +/*--- Driving Simulator - Giant Walking Robot + Walking tank with weapons ---*/ +#define DIVIRTUAL_DRIVING_MECHA 0x29000000 +#define DIAXIS_MECHA_STEER 0x29008201 /* Turns mecha left/right */ +#define DIAXIS_MECHA_TORSO 0x29010202 /* Tilts torso forward/backward */ +#define DIAXIS_MECHA_ROTATE 0x29020203 /* Turns torso left/right */ +#define DIAXIS_MECHA_THROTTLE 0x29038204 /* Engine Speed */ +#define DIBUTTON_MECHA_FIRE 0x29000401 /* Fire */ +#define DIBUTTON_MECHA_WEAPONS 0x29000402 /* Select next weapon group */ +#define DIBUTTON_MECHA_TARGET 0x29000403 /* Select closest enemy available target */ +#define DIBUTTON_MECHA_REVERSE 0x29000404 /* Toggles throttle in/out of reverse */ +#define DIBUTTON_MECHA_ZOOM 0x29000405 /* Zoom in/out targeting reticule */ +#define DIBUTTON_MECHA_JUMP 0x29000406 /* Fires jump jets */ +#define DIBUTTON_MECHA_MENU 0x290004FD /* Show menu options */ +/*--- Priority 2 controls ---*/ + +#define DIBUTTON_MECHA_CENTER 0x29004407 /* Center torso to legs */ +#define DIHATSWITCH_MECHA_GLANCE 0x29004601 /* Look around */ +#define DIBUTTON_MECHA_VIEW 0x29004408 /* Cycle through view options */ +#define DIBUTTON_MECHA_FIRESECONDARY 0x29004409 /* Alternative fire button */ +#define DIBUTTON_MECHA_LEFT_LINK 0x2900C4E4 /* Fallback steer left button */ +#define DIBUTTON_MECHA_RIGHT_LINK 0x2900C4EC /* Fallback steer right button */ +#define DIBUTTON_MECHA_FORWARD_LINK 0x290144E0 /* Fallback tilt torso forward button */ +#define DIBUTTON_MECHA_BACK_LINK 0x290144E8 /* Fallback tilt toroso backward button */ +#define DIBUTTON_MECHA_ROTATE_LEFT_LINK 0x290244E4 /* Fallback rotate toroso right button */ +#define DIBUTTON_MECHA_ROTATE_RIGHT_LINK 0x290244EC /* Fallback rotate torso left button */ +#define DIBUTTON_MECHA_FASTER_LINK 0x2903C4E0 /* Fallback increase engine speed */ +#define DIBUTTON_MECHA_SLOWER_LINK 0x2903C4E8 /* Fallback decrease engine speed */ +#define DIBUTTON_MECHA_DEVICE 0x290044FE /* Show input device and controls */ +#define DIBUTTON_MECHA_PAUSE 0x290044FC /* Start / Pause / Restart game */ + +/* + * "ANY" semantics can be used as a last resort to get mappings for actions + * that match nothing in the chosen virtual genre. These semantics will be + * mapped at a lower priority that virtual genre semantics. Also, hardware + * vendors will not be able to provide sensible mappings for these unless + * they provide application specific mappings. + */ +#define DIAXIS_ANY_X_1 0xFF00C201 +#define DIAXIS_ANY_X_2 0xFF00C202 +#define DIAXIS_ANY_Y_1 0xFF014201 +#define DIAXIS_ANY_Y_2 0xFF014202 +#define DIAXIS_ANY_Z_1 0xFF01C201 +#define DIAXIS_ANY_Z_2 0xFF01C202 +#define DIAXIS_ANY_R_1 0xFF024201 +#define DIAXIS_ANY_R_2 0xFF024202 +#define DIAXIS_ANY_U_1 0xFF02C201 +#define DIAXIS_ANY_U_2 0xFF02C202 +#define DIAXIS_ANY_V_1 0xFF034201 +#define DIAXIS_ANY_V_2 0xFF034202 +#define DIAXIS_ANY_A_1 0xFF03C201 +#define DIAXIS_ANY_A_2 0xFF03C202 +#define DIAXIS_ANY_B_1 0xFF044201 +#define DIAXIS_ANY_B_2 0xFF044202 +#define DIAXIS_ANY_C_1 0xFF04C201 +#define DIAXIS_ANY_C_2 0xFF04C202 +#define DIAXIS_ANY_S_1 0xFF054201 +#define DIAXIS_ANY_S_2 0xFF054202 + +#define DIAXIS_ANY_1 0xFF004201 +#define DIAXIS_ANY_2 0xFF004202 +#define DIAXIS_ANY_3 0xFF004203 +#define DIAXIS_ANY_4 0xFF004204 + +#define DIPOV_ANY_1 0xFF004601 +#define DIPOV_ANY_2 0xFF004602 +#define DIPOV_ANY_3 0xFF004603 +#define DIPOV_ANY_4 0xFF004604 + +#define DIBUTTON_ANY(instance) ( 0xFF004400 | instance ) + + +#ifdef __cplusplus +}; +#endif + +#endif /* __DINPUT_INCLUDED__ */ + +/**************************************************************************** + * + * Definitions for non-IDirectInput (VJoyD) features defined more recently + * than the current sdk files + * + ****************************************************************************/ + +#ifdef _INC_MMSYSTEM +#ifndef MMNOJOY + +#ifndef __VJOYDX_INCLUDED__ +#define __VJOYDX_INCLUDED__ + +#ifdef __cplusplus +extern "C" { +#endif + +/* + * Flag to indicate that the dwReserved2 field of the JOYINFOEX structure + * contains mini-driver specific data to be passed by VJoyD to the mini- + * driver instead of doing a poll. + */ +#define JOY_PASSDRIVERDATA 0x10000000l + +/* + * Informs the joystick driver that the configuration has been changed + * and should be reloaded from the registery. + * dwFlags is reserved and should be set to zero + */ +WINMMAPI MMRESULT WINAPI joyConfigChanged( DWORD dwFlags ); + +#ifndef DIJ_RINGZERO +/* + * Invoke the joystick control panel directly, using the passed window handle + * as the parent of the dialog. This API is only supported for compatibility + * purposes; new applications should use the RunControlPanel method of a + * device interface for a game controller. + * The API is called by using the function pointer returned by + * GetProcAddress( hCPL, TEXT("ShowJoyCPL") ) where hCPL is a HMODULE returned + * by LoadLibrary( TEXT("joy.cpl") ). The typedef is provided to allow + * declaration and casting of an appropriately typed variable. + */ +void WINAPI ShowJoyCPL( HWND hWnd ); +typedef void (WINAPI* LPFNSHOWJOYCPL)( HWND hWnd ); +#endif /* DIJ_RINGZERO */ + + +/* + * Hardware Setting indicating that the device is a headtracker + */ +#define JOY_HWS_ISHEADTRACKER 0x02000000l + +/* + * Hardware Setting indicating that the VxD is used to replace + * the standard analog polling + */ +#define JOY_HWS_ISGAMEPORTDRIVER 0x04000000l + +/* + * Hardware Setting indicating that the driver needs a standard + * gameport in order to communicate with the device. + */ +#define JOY_HWS_ISANALOGPORTDRIVER 0x08000000l + +/* + * Hardware Setting indicating that VJoyD should not load this + * driver, it will be loaded externally and will register with + * VJoyD of it's own accord. + */ +#define JOY_HWS_AUTOLOAD 0x10000000l + +/* + * Hardware Setting indicating that the driver acquires any + * resources needed without needing a devnode through VJoyD. + */ +#define JOY_HWS_NODEVNODE 0x20000000l + + +/* + * Hardware Setting indicating that the device is a gameport bus + */ +#define JOY_HWS_ISGAMEPORTBUS 0x80000000l +#define JOY_HWS_GAMEPORTBUSBUSY 0x00000001l + +/* + * Usage Setting indicating that the settings are volatile and + * should be removed if still present on a reboot. + */ +#define JOY_US_VOLATILE 0x00000008L + +#ifdef __cplusplus +}; +#endif + +#endif /* __VJOYDX_INCLUDED__ */ + +#endif /* not MMNOJOY */ +#endif /* _INC_MMSYSTEM */ + +/**************************************************************************** + * + * Definitions for non-IDirectInput (VJoyD) features defined more recently + * than the current ddk files + * + ****************************************************************************/ + +#ifndef DIJ_RINGZERO + +#ifdef _INC_MMDDK +#ifndef MMNOJOYDEV + +#ifndef __VJOYDXD_INCLUDED__ +#define __VJOYDXD_INCLUDED__ +/* + * Poll type in which the do_other field of the JOYOEMPOLLDATA + * structure contains mini-driver specific data passed from an app. + */ +#define JOY_OEMPOLL_PASSDRIVERDATA 7 + +#endif /* __VJOYDXD_INCLUDED__ */ + +#endif /* not MMNOJOYDEV */ +#endif /* _INC_MMDDK */ + +#endif /* DIJ_RINGZERO */ + diff --git a/desmume/src/windows/directx/dinput8.lib b/src/windows/directx/dinput8.lib similarity index 100% rename from desmume/src/windows/directx/dinput8.lib rename to src/windows/directx/dinput8.lib diff --git a/desmume/src/windows/directx/dsound.h b/src/windows/directx/dsound.h similarity index 97% rename from desmume/src/windows/directx/dsound.h rename to src/windows/directx/dsound.h index 8020a660b..c088b63a3 100644 --- a/desmume/src/windows/directx/dsound.h +++ b/src/windows/directx/dsound.h @@ -1,2358 +1,2358 @@ -/*==========================================================================; - * - * Copyright (c) Microsoft Corporation. All rights reserved. - * - * File: dsound.h - * Content: DirectSound include file - * - **************************************************************************/ - -#define COM_NO_WINDOWS_H -#include -#include - -#ifndef DIRECTSOUND_VERSION -#define DIRECTSOUND_VERSION 0x0900 /* Version 9.0 */ -#endif - -#ifdef __cplusplus -extern "C" { -#endif // __cplusplus - -#ifndef __DSOUND_INCLUDED__ -#define __DSOUND_INCLUDED__ - -/* Type definitions shared with Direct3D */ - -#ifndef DX_SHARED_DEFINES - -typedef float D3DVALUE, *LPD3DVALUE; - -#ifndef D3DCOLOR_DEFINED -typedef DWORD D3DCOLOR; -#define D3DCOLOR_DEFINED -#endif - -#ifndef LPD3DCOLOR_DEFINED -typedef DWORD *LPD3DCOLOR; -#define LPD3DCOLOR_DEFINED -#endif - -#ifndef D3DVECTOR_DEFINED -typedef struct _D3DVECTOR { - float x; - float y; - float z; -} D3DVECTOR; -#define D3DVECTOR_DEFINED -#endif - -#ifndef LPD3DVECTOR_DEFINED -typedef D3DVECTOR *LPD3DVECTOR; -#define LPD3DVECTOR_DEFINED -#endif - -#define DX_SHARED_DEFINES -#endif // DX_SHARED_DEFINES - -#define _FACDS 0x878 /* DirectSound's facility code */ -#define MAKE_DSHRESULT(code) MAKE_HRESULT(1, _FACDS, code) - -// DirectSound Component GUID {47D4D946-62E8-11CF-93BC-444553540000} -DEFINE_GUID(CLSID_DirectSound, 0x47d4d946, 0x62e8, 0x11cf, 0x93, 0xbc, 0x44, 0x45, 0x53, 0x54, 0x0, 0x0); - -// DirectSound 8.0 Component GUID {3901CC3F-84B5-4FA4-BA35-AA8172B8A09B} -DEFINE_GUID(CLSID_DirectSound8, 0x3901cc3f, 0x84b5, 0x4fa4, 0xba, 0x35, 0xaa, 0x81, 0x72, 0xb8, 0xa0, 0x9b); - -// DirectSound Capture Component GUID {B0210780-89CD-11D0-AF08-00A0C925CD16} -DEFINE_GUID(CLSID_DirectSoundCapture, 0xb0210780, 0x89cd, 0x11d0, 0xaf, 0x8, 0x0, 0xa0, 0xc9, 0x25, 0xcd, 0x16); - -// DirectSound 8.0 Capture Component GUID {E4BCAC13-7F99-4908-9A8E-74E3BF24B6E1} -DEFINE_GUID(CLSID_DirectSoundCapture8, 0xe4bcac13, 0x7f99, 0x4908, 0x9a, 0x8e, 0x74, 0xe3, 0xbf, 0x24, 0xb6, 0xe1); - -// DirectSound Full Duplex Component GUID {FEA4300C-7959-4147-B26A-2377B9E7A91D} -DEFINE_GUID(CLSID_DirectSoundFullDuplex, 0xfea4300c, 0x7959, 0x4147, 0xb2, 0x6a, 0x23, 0x77, 0xb9, 0xe7, 0xa9, 0x1d); - - -// DirectSound default playback device GUID {DEF00000-9C6D-47ED-AAF1-4DDA8F2B5C03} -DEFINE_GUID(DSDEVID_DefaultPlayback, 0xdef00000, 0x9c6d, 0x47ed, 0xaa, 0xf1, 0x4d, 0xda, 0x8f, 0x2b, 0x5c, 0x03); - -// DirectSound default capture device GUID {DEF00001-9C6D-47ED-AAF1-4DDA8F2B5C03} -DEFINE_GUID(DSDEVID_DefaultCapture, 0xdef00001, 0x9c6d, 0x47ed, 0xaa, 0xf1, 0x4d, 0xda, 0x8f, 0x2b, 0x5c, 0x03); - -// DirectSound default device for voice playback {DEF00002-9C6D-47ED-AAF1-4DDA8F2B5C03} -DEFINE_GUID(DSDEVID_DefaultVoicePlayback, 0xdef00002, 0x9c6d, 0x47ed, 0xaa, 0xf1, 0x4d, 0xda, 0x8f, 0x2b, 0x5c, 0x03); - -// DirectSound default device for voice capture {DEF00003-9C6D-47ED-AAF1-4DDA8F2B5C03} -DEFINE_GUID(DSDEVID_DefaultVoiceCapture, 0xdef00003, 0x9c6d, 0x47ed, 0xaa, 0xf1, 0x4d, 0xda, 0x8f, 0x2b, 0x5c, 0x03); - - -// -// Forward declarations for interfaces. -// 'struct' not 'class' per the way DECLARE_INTERFACE_ is defined -// - -#ifdef __cplusplus -struct IDirectSound; -struct IDirectSoundBuffer; -struct IDirectSound3DListener; -struct IDirectSound3DBuffer; -struct IDirectSoundCapture; -struct IDirectSoundCaptureBuffer; -struct IDirectSoundNotify; -#endif // __cplusplus - - -// -// DirectSound 8.0 interfaces. -// - -#if DIRECTSOUND_VERSION >= 0x0800 - -#ifdef __cplusplus -struct IDirectSound8; -struct IDirectSoundBuffer8; -struct IDirectSoundCaptureBuffer8; -struct IDirectSoundFXGargle; -struct IDirectSoundFXChorus; -struct IDirectSoundFXFlanger; -struct IDirectSoundFXEcho; -struct IDirectSoundFXDistortion; -struct IDirectSoundFXCompressor; -struct IDirectSoundFXParamEq; -struct IDirectSoundFXWavesReverb; -struct IDirectSoundFXI3DL2Reverb; -struct IDirectSoundCaptureFXAec; -struct IDirectSoundCaptureFXNoiseSuppress; -struct IDirectSoundFullDuplex; -#endif // __cplusplus - -// IDirectSound8, IDirectSoundBuffer8 and IDirectSoundCaptureBuffer8 are the -// only DirectSound 7.0 interfaces with changed functionality in version 8.0. -// The other level 8 interfaces as equivalent to their level 7 counterparts: - -#define IDirectSoundCapture8 IDirectSoundCapture -#define IDirectSound3DListener8 IDirectSound3DListener -#define IDirectSound3DBuffer8 IDirectSound3DBuffer -#define IDirectSoundNotify8 IDirectSoundNotify -#define IDirectSoundFXGargle8 IDirectSoundFXGargle -#define IDirectSoundFXChorus8 IDirectSoundFXChorus -#define IDirectSoundFXFlanger8 IDirectSoundFXFlanger -#define IDirectSoundFXEcho8 IDirectSoundFXEcho -#define IDirectSoundFXDistortion8 IDirectSoundFXDistortion -#define IDirectSoundFXCompressor8 IDirectSoundFXCompressor -#define IDirectSoundFXParamEq8 IDirectSoundFXParamEq -#define IDirectSoundFXWavesReverb8 IDirectSoundFXWavesReverb -#define IDirectSoundFXI3DL2Reverb8 IDirectSoundFXI3DL2Reverb -#define IDirectSoundCaptureFXAec8 IDirectSoundCaptureFXAec -#define IDirectSoundCaptureFXNoiseSuppress8 IDirectSoundCaptureFXNoiseSuppress -#define IDirectSoundFullDuplex8 IDirectSoundFullDuplex - -#endif // DIRECTSOUND_VERSION >= 0x0800 - -typedef struct IDirectSound *LPDIRECTSOUND; -typedef struct IDirectSoundBuffer *LPDIRECTSOUNDBUFFER; -typedef struct IDirectSound3DListener *LPDIRECTSOUND3DLISTENER; -typedef struct IDirectSound3DBuffer *LPDIRECTSOUND3DBUFFER; -typedef struct IDirectSoundCapture *LPDIRECTSOUNDCAPTURE; -typedef struct IDirectSoundCaptureBuffer *LPDIRECTSOUNDCAPTUREBUFFER; -typedef struct IDirectSoundNotify *LPDIRECTSOUNDNOTIFY; - - -#if DIRECTSOUND_VERSION >= 0x0800 - -typedef struct IDirectSoundFXGargle *LPDIRECTSOUNDFXGARGLE; -typedef struct IDirectSoundFXChorus *LPDIRECTSOUNDFXCHORUS; -typedef struct IDirectSoundFXFlanger *LPDIRECTSOUNDFXFLANGER; -typedef struct IDirectSoundFXEcho *LPDIRECTSOUNDFXECHO; -typedef struct IDirectSoundFXDistortion *LPDIRECTSOUNDFXDISTORTION; -typedef struct IDirectSoundFXCompressor *LPDIRECTSOUNDFXCOMPRESSOR; -typedef struct IDirectSoundFXParamEq *LPDIRECTSOUNDFXPARAMEQ; -typedef struct IDirectSoundFXWavesReverb *LPDIRECTSOUNDFXWAVESREVERB; -typedef struct IDirectSoundFXI3DL2Reverb *LPDIRECTSOUNDFXI3DL2REVERB; -typedef struct IDirectSoundCaptureFXAec *LPDIRECTSOUNDCAPTUREFXAEC; -typedef struct IDirectSoundCaptureFXNoiseSuppress *LPDIRECTSOUNDCAPTUREFXNOISESUPPRESS; -typedef struct IDirectSoundFullDuplex *LPDIRECTSOUNDFULLDUPLEX; - -typedef struct IDirectSound8 *LPDIRECTSOUND8; -typedef struct IDirectSoundBuffer8 *LPDIRECTSOUNDBUFFER8; -typedef struct IDirectSound3DListener8 *LPDIRECTSOUND3DLISTENER8; -typedef struct IDirectSound3DBuffer8 *LPDIRECTSOUND3DBUFFER8; -typedef struct IDirectSoundCapture8 *LPDIRECTSOUNDCAPTURE8; -typedef struct IDirectSoundCaptureBuffer8 *LPDIRECTSOUNDCAPTUREBUFFER8; -typedef struct IDirectSoundNotify8 *LPDIRECTSOUNDNOTIFY8; -typedef struct IDirectSoundFXGargle8 *LPDIRECTSOUNDFXGARGLE8; -typedef struct IDirectSoundFXChorus8 *LPDIRECTSOUNDFXCHORUS8; -typedef struct IDirectSoundFXFlanger8 *LPDIRECTSOUNDFXFLANGER8; -typedef struct IDirectSoundFXEcho8 *LPDIRECTSOUNDFXECHO8; -typedef struct IDirectSoundFXDistortion8 *LPDIRECTSOUNDFXDISTORTION8; -typedef struct IDirectSoundFXCompressor8 *LPDIRECTSOUNDFXCOMPRESSOR8; -typedef struct IDirectSoundFXParamEq8 *LPDIRECTSOUNDFXPARAMEQ8; -typedef struct IDirectSoundFXWavesReverb8 *LPDIRECTSOUNDFXWAVESREVERB8; -typedef struct IDirectSoundFXI3DL2Reverb8 *LPDIRECTSOUNDFXI3DL2REVERB8; -typedef struct IDirectSoundCaptureFXAec8 *LPDIRECTSOUNDCAPTUREFXAEC8; -typedef struct IDirectSoundCaptureFXNoiseSuppress8 *LPDIRECTSOUNDCAPTUREFXNOISESUPPRESS8; -typedef struct IDirectSoundFullDuplex8 *LPDIRECTSOUNDFULLDUPLEX8; - -#endif // DIRECTSOUND_VERSION >= 0x0800 - -// -// IID definitions for the unchanged DirectSound 8.0 interfaces -// - -#if DIRECTSOUND_VERSION >= 0x0800 - -#define IID_IDirectSoundCapture8 IID_IDirectSoundCapture -#define IID_IDirectSound3DListener8 IID_IDirectSound3DListener -#define IID_IDirectSound3DBuffer8 IID_IDirectSound3DBuffer -#define IID_IDirectSoundNotify8 IID_IDirectSoundNotify -#define IID_IDirectSoundFXGargle8 IID_IDirectSoundFXGargle -#define IID_IDirectSoundFXChorus8 IID_IDirectSoundFXChorus -#define IID_IDirectSoundFXFlanger8 IID_IDirectSoundFXFlanger -#define IID_IDirectSoundFXEcho8 IID_IDirectSoundFXEcho -#define IID_IDirectSoundFXDistortion8 IID_IDirectSoundFXDistortion -#define IID_IDirectSoundFXCompressor8 IID_IDirectSoundFXCompressor -#define IID_IDirectSoundFXParamEq8 IID_IDirectSoundFXParamEq -#define IID_IDirectSoundFXWavesReverb8 IID_IDirectSoundFXWavesReverb -#define IID_IDirectSoundFXI3DL2Reverb8 IID_IDirectSoundFXI3DL2Reverb -#define IID_IDirectSoundCaptureFXAec8 IID_IDirectSoundCaptureFXAec -#define IID_IDirectSoundCaptureFXNoiseSuppress8 IID_IDirectSoundCaptureFXNoiseSuppress -#define IID_IDirectSoundFullDuplex8 IID_IDirectSoundFullDuplex - -#endif // DIRECTSOUND_VERSION >= 0x0800 - -// -// Compatibility typedefs -// - -#ifndef _LPCWAVEFORMATEX_DEFINED -#define _LPCWAVEFORMATEX_DEFINED -typedef const WAVEFORMATEX *LPCWAVEFORMATEX; -#endif // _LPCWAVEFORMATEX_DEFINED - -#ifndef __LPCGUID_DEFINED__ -#define __LPCGUID_DEFINED__ -typedef const GUID *LPCGUID; -#endif // __LPCGUID_DEFINED__ - -typedef LPDIRECTSOUND *LPLPDIRECTSOUND; -typedef LPDIRECTSOUNDBUFFER *LPLPDIRECTSOUNDBUFFER; -typedef LPDIRECTSOUND3DLISTENER *LPLPDIRECTSOUND3DLISTENER; -typedef LPDIRECTSOUND3DBUFFER *LPLPDIRECTSOUND3DBUFFER; -typedef LPDIRECTSOUNDCAPTURE *LPLPDIRECTSOUNDCAPTURE; -typedef LPDIRECTSOUNDCAPTUREBUFFER *LPLPDIRECTSOUNDCAPTUREBUFFER; -typedef LPDIRECTSOUNDNOTIFY *LPLPDIRECTSOUNDNOTIFY; - -#if DIRECTSOUND_VERSION >= 0x0800 -typedef LPDIRECTSOUND8 *LPLPDIRECTSOUND8; -typedef LPDIRECTSOUNDBUFFER8 *LPLPDIRECTSOUNDBUFFER8; -typedef LPDIRECTSOUNDCAPTURE8 *LPLPDIRECTSOUNDCAPTURE8; -typedef LPDIRECTSOUNDCAPTUREBUFFER8 *LPLPDIRECTSOUNDCAPTUREBUFFER8; -#endif // DIRECTSOUND_VERSION >= 0x0800 - -// -// Structures -// - -typedef struct _DSCAPS -{ - DWORD dwSize; - DWORD dwFlags; - DWORD dwMinSecondarySampleRate; - DWORD dwMaxSecondarySampleRate; - DWORD dwPrimaryBuffers; - DWORD dwMaxHwMixingAllBuffers; - DWORD dwMaxHwMixingStaticBuffers; - DWORD dwMaxHwMixingStreamingBuffers; - DWORD dwFreeHwMixingAllBuffers; - DWORD dwFreeHwMixingStaticBuffers; - DWORD dwFreeHwMixingStreamingBuffers; - DWORD dwMaxHw3DAllBuffers; - DWORD dwMaxHw3DStaticBuffers; - DWORD dwMaxHw3DStreamingBuffers; - DWORD dwFreeHw3DAllBuffers; - DWORD dwFreeHw3DStaticBuffers; - DWORD dwFreeHw3DStreamingBuffers; - DWORD dwTotalHwMemBytes; - DWORD dwFreeHwMemBytes; - DWORD dwMaxContigFreeHwMemBytes; - DWORD dwUnlockTransferRateHwBuffers; - DWORD dwPlayCpuOverheadSwBuffers; - DWORD dwReserved1; - DWORD dwReserved2; -} DSCAPS, *LPDSCAPS; - -typedef const DSCAPS *LPCDSCAPS; - -typedef struct _DSBCAPS -{ - DWORD dwSize; - DWORD dwFlags; - DWORD dwBufferBytes; - DWORD dwUnlockTransferRate; - DWORD dwPlayCpuOverhead; -} DSBCAPS, *LPDSBCAPS; - -typedef const DSBCAPS *LPCDSBCAPS; - -#if DIRECTSOUND_VERSION >= 0x0800 - - typedef struct _DSEFFECTDESC - { - DWORD dwSize; - DWORD dwFlags; - GUID guidDSFXClass; - DWORD_PTR dwReserved1; - DWORD_PTR dwReserved2; - } DSEFFECTDESC, *LPDSEFFECTDESC; - typedef const DSEFFECTDESC *LPCDSEFFECTDESC; - - #define DSFX_LOCHARDWARE 0x00000001 - #define DSFX_LOCSOFTWARE 0x00000002 - - enum - { - DSFXR_PRESENT, // 0 - DSFXR_LOCHARDWARE, // 1 - DSFXR_LOCSOFTWARE, // 2 - DSFXR_UNALLOCATED, // 3 - DSFXR_FAILED, // 4 - DSFXR_UNKNOWN, // 5 - DSFXR_SENDLOOP // 6 - }; - - typedef struct _DSCEFFECTDESC - { - DWORD dwSize; - DWORD dwFlags; - GUID guidDSCFXClass; - GUID guidDSCFXInstance; - DWORD dwReserved1; - DWORD dwReserved2; - } DSCEFFECTDESC, *LPDSCEFFECTDESC; - typedef const DSCEFFECTDESC *LPCDSCEFFECTDESC; - - #define DSCFX_LOCHARDWARE 0x00000001 - #define DSCFX_LOCSOFTWARE 0x00000002 - - #define DSCFXR_LOCHARDWARE 0x00000010 - #define DSCFXR_LOCSOFTWARE 0x00000020 - -#endif // DIRECTSOUND_VERSION >= 0x0800 - -typedef struct _DSBUFFERDESC -{ - DWORD dwSize; - DWORD dwFlags; - DWORD dwBufferBytes; - DWORD dwReserved; - LPWAVEFORMATEX lpwfxFormat; -#if DIRECTSOUND_VERSION >= 0x0700 - GUID guid3DAlgorithm; -#endif -} DSBUFFERDESC, *LPDSBUFFERDESC; - -typedef const DSBUFFERDESC *LPCDSBUFFERDESC; - -// Older version of this structure: - -typedef struct _DSBUFFERDESC1 -{ - DWORD dwSize; - DWORD dwFlags; - DWORD dwBufferBytes; - DWORD dwReserved; - LPWAVEFORMATEX lpwfxFormat; -} DSBUFFERDESC1, *LPDSBUFFERDESC1; - -typedef const DSBUFFERDESC1 *LPCDSBUFFERDESC1; - -typedef struct _DS3DBUFFER -{ - DWORD dwSize; - D3DVECTOR vPosition; - D3DVECTOR vVelocity; - DWORD dwInsideConeAngle; - DWORD dwOutsideConeAngle; - D3DVECTOR vConeOrientation; - LONG lConeOutsideVolume; - D3DVALUE flMinDistance; - D3DVALUE flMaxDistance; - DWORD dwMode; -} DS3DBUFFER, *LPDS3DBUFFER; - -typedef const DS3DBUFFER *LPCDS3DBUFFER; - -typedef struct _DS3DLISTENER -{ - DWORD dwSize; - D3DVECTOR vPosition; - D3DVECTOR vVelocity; - D3DVECTOR vOrientFront; - D3DVECTOR vOrientTop; - D3DVALUE flDistanceFactor; - D3DVALUE flRolloffFactor; - D3DVALUE flDopplerFactor; -} DS3DLISTENER, *LPDS3DLISTENER; - -typedef const DS3DLISTENER *LPCDS3DLISTENER; - -typedef struct _DSCCAPS -{ - DWORD dwSize; - DWORD dwFlags; - DWORD dwFormats; - DWORD dwChannels; -} DSCCAPS, *LPDSCCAPS; - -typedef const DSCCAPS *LPCDSCCAPS; - -typedef struct _DSCBUFFERDESC1 -{ - DWORD dwSize; - DWORD dwFlags; - DWORD dwBufferBytes; - DWORD dwReserved; - LPWAVEFORMATEX lpwfxFormat; -} DSCBUFFERDESC1, *LPDSCBUFFERDESC1; - -typedef struct _DSCBUFFERDESC -{ - DWORD dwSize; - DWORD dwFlags; - DWORD dwBufferBytes; - DWORD dwReserved; - LPWAVEFORMATEX lpwfxFormat; -#if DIRECTSOUND_VERSION >= 0x0800 - DWORD dwFXCount; - LPDSCEFFECTDESC lpDSCFXDesc; -#endif -} DSCBUFFERDESC, *LPDSCBUFFERDESC; - -typedef const DSCBUFFERDESC *LPCDSCBUFFERDESC; - -typedef struct _DSCBCAPS -{ - DWORD dwSize; - DWORD dwFlags; - DWORD dwBufferBytes; - DWORD dwReserved; -} DSCBCAPS, *LPDSCBCAPS; - -typedef const DSCBCAPS *LPCDSCBCAPS; - -typedef struct _DSBPOSITIONNOTIFY -{ - DWORD dwOffset; - HANDLE hEventNotify; -} DSBPOSITIONNOTIFY, *LPDSBPOSITIONNOTIFY; - -typedef const DSBPOSITIONNOTIFY *LPCDSBPOSITIONNOTIFY; - -// -// DirectSound API -// - -typedef BOOL (CALLBACK *LPDSENUMCALLBACKA)(LPGUID, LPCSTR, LPCSTR, LPVOID); -typedef BOOL (CALLBACK *LPDSENUMCALLBACKW)(LPGUID, LPCWSTR, LPCWSTR, LPVOID); - -extern HRESULT WINAPI DirectSoundCreate(LPCGUID pcGuidDevice, LPDIRECTSOUND *ppDS, LPUNKNOWN pUnkOuter); -extern HRESULT WINAPI DirectSoundEnumerateA(LPDSENUMCALLBACKA pDSEnumCallback, LPVOID pContext); -extern HRESULT WINAPI DirectSoundEnumerateW(LPDSENUMCALLBACKW pDSEnumCallback, LPVOID pContext); - -extern HRESULT WINAPI DirectSoundCaptureCreate(LPCGUID pcGuidDevice, LPDIRECTSOUNDCAPTURE *ppDSC, LPUNKNOWN pUnkOuter); -extern HRESULT WINAPI DirectSoundCaptureEnumerateA(LPDSENUMCALLBACKA pDSEnumCallback, LPVOID pContext); -extern HRESULT WINAPI DirectSoundCaptureEnumerateW(LPDSENUMCALLBACKW pDSEnumCallback, LPVOID pContext); - -#if DIRECTSOUND_VERSION >= 0x0800 -extern HRESULT WINAPI DirectSoundCreate8(LPCGUID pcGuidDevice, LPDIRECTSOUND8 *ppDS8, LPUNKNOWN pUnkOuter); -extern HRESULT WINAPI DirectSoundCaptureCreate8(LPCGUID pcGuidDevice, LPDIRECTSOUNDCAPTURE8 *ppDSC8, LPUNKNOWN pUnkOuter); -extern HRESULT WINAPI DirectSoundFullDuplexCreate(LPCGUID pcGuidCaptureDevice, LPCGUID pcGuidRenderDevice, - LPCDSCBUFFERDESC pcDSCBufferDesc, LPCDSBUFFERDESC pcDSBufferDesc, HWND hWnd, - DWORD dwLevel, LPDIRECTSOUNDFULLDUPLEX* ppDSFD, LPDIRECTSOUNDCAPTUREBUFFER8 *ppDSCBuffer8, - LPDIRECTSOUNDBUFFER8 *ppDSBuffer8, LPUNKNOWN pUnkOuter); -#define DirectSoundFullDuplexCreate8 DirectSoundFullDuplexCreate - -extern HRESULT WINAPI GetDeviceID(LPCGUID pGuidSrc, LPGUID pGuidDest); -#endif // DIRECTSOUND_VERSION >= 0x0800 - -#ifdef UNICODE -#define LPDSENUMCALLBACK LPDSENUMCALLBACKW -#define DirectSoundEnumerate DirectSoundEnumerateW -#define DirectSoundCaptureEnumerate DirectSoundCaptureEnumerateW -#else // UNICODE -#define LPDSENUMCALLBACK LPDSENUMCALLBACKA -#define DirectSoundEnumerate DirectSoundEnumerateA -#define DirectSoundCaptureEnumerate DirectSoundCaptureEnumerateA -#endif // UNICODE - -// -// IUnknown -// - -#if !defined(__cplusplus) || defined(CINTERFACE) -#ifndef IUnknown_QueryInterface -#define IUnknown_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) -#endif // IUnknown_QueryInterface -#ifndef IUnknown_AddRef -#define IUnknown_AddRef(p) (p)->lpVtbl->AddRef(p) -#endif // IUnknown_AddRef -#ifndef IUnknown_Release -#define IUnknown_Release(p) (p)->lpVtbl->Release(p) -#endif // IUnknown_Release -#else // !defined(__cplusplus) || defined(CINTERFACE) -#ifndef IUnknown_QueryInterface -#define IUnknown_QueryInterface(p,a,b) (p)->QueryInterface(a,b) -#endif // IUnknown_QueryInterface -#ifndef IUnknown_AddRef -#define IUnknown_AddRef(p) (p)->AddRef() -#endif // IUnknown_AddRef -#ifndef IUnknown_Release -#define IUnknown_Release(p) (p)->Release() -#endif // IUnknown_Release -#endif // !defined(__cplusplus) || defined(CINTERFACE) - -#ifndef __IReferenceClock_INTERFACE_DEFINED__ -#define __IReferenceClock_INTERFACE_DEFINED__ - -typedef LONGLONG REFERENCE_TIME; -typedef REFERENCE_TIME *LPREFERENCE_TIME; - -DEFINE_GUID(IID_IReferenceClock, 0x56a86897, 0x0ad4, 0x11ce, 0xb0, 0x3a, 0x00, 0x20, 0xaf, 0x0b, 0xa7, 0x70); - -#undef INTERFACE -#define INTERFACE IReferenceClock - -DECLARE_INTERFACE_(IReferenceClock, IUnknown) -{ - // IUnknown methods - STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE; - STDMETHOD_(ULONG,AddRef) (THIS) PURE; - STDMETHOD_(ULONG,Release) (THIS) PURE; - - // IReferenceClock methods - STDMETHOD(GetTime) (THIS_ REFERENCE_TIME *pTime) PURE; - STDMETHOD(AdviseTime) (THIS_ REFERENCE_TIME rtBaseTime, REFERENCE_TIME rtStreamTime, - HANDLE hEvent, LPDWORD pdwAdviseCookie) PURE; - STDMETHOD(AdvisePeriodic) (THIS_ REFERENCE_TIME rtStartTime, REFERENCE_TIME rtPeriodTime, - HANDLE hSemaphore, LPDWORD pdwAdviseCookie) PURE; - STDMETHOD(Unadvise) (THIS_ DWORD dwAdviseCookie) PURE; -}; - -#endif // __IReferenceClock_INTERFACE_DEFINED__ - -#ifndef IReferenceClock_QueryInterface - -#define IReferenceClock_QueryInterface(p,a,b) IUnknown_QueryInterface(p,a,b) -#define IReferenceClock_AddRef(p) IUnknown_AddRef(p) -#define IReferenceClock_Release(p) IUnknown_Release(p) - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IReferenceClock_GetTime(p,a) (p)->lpVtbl->GetTime(p,a) -#define IReferenceClock_AdviseTime(p,a,b,c,d) (p)->lpVtbl->AdviseTime(p,a,b,c,d) -#define IReferenceClock_AdvisePeriodic(p,a,b,c,d) (p)->lpVtbl->AdvisePeriodic(p,a,b,c,d) -#define IReferenceClock_Unadvise(p,a) (p)->lpVtbl->Unadvise(p,a) -#else // !defined(__cplusplus) || defined(CINTERFACE) -#define IReferenceClock_GetTime(p,a) (p)->GetTime(a) -#define IReferenceClock_AdviseTime(p,a,b,c,d) (p)->AdviseTime(a,b,c,d) -#define IReferenceClock_AdvisePeriodic(p,a,b,c,d) (p)->AdvisePeriodic(a,b,c,d) -#define IReferenceClock_Unadvise(p,a) (p)->Unadvise(a) -#endif // !defined(__cplusplus) || defined(CINTERFACE) - -#endif // IReferenceClock_QueryInterface - -// -// IDirectSound -// - -DEFINE_GUID(IID_IDirectSound, 0x279AFA83, 0x4981, 0x11CE, 0xA5, 0x21, 0x00, 0x20, 0xAF, 0x0B, 0xE5, 0x60); - -#undef INTERFACE -#define INTERFACE IDirectSound - -DECLARE_INTERFACE_(IDirectSound, IUnknown) -{ - // IUnknown methods - STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE; - STDMETHOD_(ULONG,AddRef) (THIS) PURE; - STDMETHOD_(ULONG,Release) (THIS) PURE; - - // IDirectSound methods - STDMETHOD(CreateSoundBuffer) (THIS_ LPCDSBUFFERDESC pcDSBufferDesc, LPDIRECTSOUNDBUFFER *ppDSBuffer, LPUNKNOWN pUnkOuter) PURE; - STDMETHOD(GetCaps) (THIS_ LPDSCAPS pDSCaps) PURE; - STDMETHOD(DuplicateSoundBuffer) (THIS_ LPDIRECTSOUNDBUFFER pDSBufferOriginal, LPDIRECTSOUNDBUFFER *ppDSBufferDuplicate) PURE; - STDMETHOD(SetCooperativeLevel) (THIS_ HWND hwnd, DWORD dwLevel) PURE; - STDMETHOD(Compact) (THIS) PURE; - STDMETHOD(GetSpeakerConfig) (THIS_ LPDWORD pdwSpeakerConfig) PURE; - STDMETHOD(SetSpeakerConfig) (THIS_ DWORD dwSpeakerConfig) PURE; - STDMETHOD(Initialize) (THIS_ LPCGUID pcGuidDevice) PURE; -}; - -#define IDirectSound_QueryInterface(p,a,b) IUnknown_QueryInterface(p,a,b) -#define IDirectSound_AddRef(p) IUnknown_AddRef(p) -#define IDirectSound_Release(p) IUnknown_Release(p) - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectSound_CreateSoundBuffer(p,a,b,c) (p)->lpVtbl->CreateSoundBuffer(p,a,b,c) -#define IDirectSound_GetCaps(p,a) (p)->lpVtbl->GetCaps(p,a) -#define IDirectSound_DuplicateSoundBuffer(p,a,b) (p)->lpVtbl->DuplicateSoundBuffer(p,a,b) -#define IDirectSound_SetCooperativeLevel(p,a,b) (p)->lpVtbl->SetCooperativeLevel(p,a,b) -#define IDirectSound_Compact(p) (p)->lpVtbl->Compact(p) -#define IDirectSound_GetSpeakerConfig(p,a) (p)->lpVtbl->GetSpeakerConfig(p,a) -#define IDirectSound_SetSpeakerConfig(p,b) (p)->lpVtbl->SetSpeakerConfig(p,b) -#define IDirectSound_Initialize(p,a) (p)->lpVtbl->Initialize(p,a) -#else // !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectSound_CreateSoundBuffer(p,a,b,c) (p)->CreateSoundBuffer(a,b,c) -#define IDirectSound_GetCaps(p,a) (p)->GetCaps(a) -#define IDirectSound_DuplicateSoundBuffer(p,a,b) (p)->DuplicateSoundBuffer(a,b) -#define IDirectSound_SetCooperativeLevel(p,a,b) (p)->SetCooperativeLevel(a,b) -#define IDirectSound_Compact(p) (p)->Compact() -#define IDirectSound_GetSpeakerConfig(p,a) (p)->GetSpeakerConfig(a) -#define IDirectSound_SetSpeakerConfig(p,b) (p)->SetSpeakerConfig(b) -#define IDirectSound_Initialize(p,a) (p)->Initialize(a) -#endif // !defined(__cplusplus) || defined(CINTERFACE) - -#if DIRECTSOUND_VERSION >= 0x0800 - -// -// IDirectSound8 -// - -DEFINE_GUID(IID_IDirectSound8, 0xC50A7E93, 0xF395, 0x4834, 0x9E, 0xF6, 0x7F, 0xA9, 0x9D, 0xE5, 0x09, 0x66); - -#undef INTERFACE -#define INTERFACE IDirectSound8 - -DECLARE_INTERFACE_(IDirectSound8, IDirectSound) -{ - // IUnknown methods - STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE; - STDMETHOD_(ULONG,AddRef) (THIS) PURE; - STDMETHOD_(ULONG,Release) (THIS) PURE; - - // IDirectSound methods - STDMETHOD(CreateSoundBuffer) (THIS_ LPCDSBUFFERDESC pcDSBufferDesc, LPDIRECTSOUNDBUFFER *ppDSBuffer, LPUNKNOWN pUnkOuter) PURE; - STDMETHOD(GetCaps) (THIS_ LPDSCAPS pDSCaps) PURE; - STDMETHOD(DuplicateSoundBuffer) (THIS_ LPDIRECTSOUNDBUFFER pDSBufferOriginal, LPDIRECTSOUNDBUFFER *ppDSBufferDuplicate) PURE; - STDMETHOD(SetCooperativeLevel) (THIS_ HWND hwnd, DWORD dwLevel) PURE; - STDMETHOD(Compact) (THIS) PURE; - STDMETHOD(GetSpeakerConfig) (THIS_ LPDWORD pdwSpeakerConfig) PURE; - STDMETHOD(SetSpeakerConfig) (THIS_ DWORD dwSpeakerConfig) PURE; - STDMETHOD(Initialize) (THIS_ LPCGUID pcGuidDevice) PURE; - - // IDirectSound8 methods - STDMETHOD(VerifyCertification) (THIS_ LPDWORD pdwCertified) PURE; -}; - -#define IDirectSound8_QueryInterface(p,a,b) IDirectSound_QueryInterface(p,a,b) -#define IDirectSound8_AddRef(p) IDirectSound_AddRef(p) -#define IDirectSound8_Release(p) IDirectSound_Release(p) -#define IDirectSound8_CreateSoundBuffer(p,a,b,c) IDirectSound_CreateSoundBuffer(p,a,b,c) -#define IDirectSound8_GetCaps(p,a) IDirectSound_GetCaps(p,a) -#define IDirectSound8_DuplicateSoundBuffer(p,a,b) IDirectSound_DuplicateSoundBuffer(p,a,b) -#define IDirectSound8_SetCooperativeLevel(p,a,b) IDirectSound_SetCooperativeLevel(p,a,b) -#define IDirectSound8_Compact(p) IDirectSound_Compact(p) -#define IDirectSound8_GetSpeakerConfig(p,a) IDirectSound_GetSpeakerConfig(p,a) -#define IDirectSound8_SetSpeakerConfig(p,a) IDirectSound_SetSpeakerConfig(p,a) -#define IDirectSound8_Initialize(p,a) IDirectSound_Initialize(p,a) - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectSound8_VerifyCertification(p,a) (p)->lpVtbl->VerifyCertification(p,a) -#else // !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectSound8_VerifyCertification(p,a) (p)->VerifyCertification(a) -#endif // !defined(__cplusplus) || defined(CINTERFACE) - -#endif // DIRECTSOUND_VERSION >= 0x0800 - -// -// IDirectSoundBuffer -// - -DEFINE_GUID(IID_IDirectSoundBuffer, 0x279AFA85, 0x4981, 0x11CE, 0xA5, 0x21, 0x00, 0x20, 0xAF, 0x0B, 0xE5, 0x60); - -#undef INTERFACE -#define INTERFACE IDirectSoundBuffer - -DECLARE_INTERFACE_(IDirectSoundBuffer, IUnknown) -{ - // IUnknown methods - STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE; - STDMETHOD_(ULONG,AddRef) (THIS) PURE; - STDMETHOD_(ULONG,Release) (THIS) PURE; - - // IDirectSoundBuffer methods - STDMETHOD(GetCaps) (THIS_ LPDSBCAPS pDSBufferCaps) PURE; - STDMETHOD(GetCurrentPosition) (THIS_ LPDWORD pdwCurrentPlayCursor, LPDWORD pdwCurrentWriteCursor) PURE; - STDMETHOD(GetFormat) (THIS_ LPWAVEFORMATEX pwfxFormat, DWORD dwSizeAllocated, LPDWORD pdwSizeWritten) PURE; - STDMETHOD(GetVolume) (THIS_ LPLONG plVolume) PURE; - STDMETHOD(GetPan) (THIS_ LPLONG plPan) PURE; - STDMETHOD(GetFrequency) (THIS_ LPDWORD pdwFrequency) PURE; - STDMETHOD(GetStatus) (THIS_ LPDWORD pdwStatus) PURE; - STDMETHOD(Initialize) (THIS_ LPDIRECTSOUND pDirectSound, LPCDSBUFFERDESC pcDSBufferDesc) PURE; - STDMETHOD(Lock) (THIS_ DWORD dwOffset, DWORD dwBytes, LPVOID *ppvAudioPtr1, LPDWORD pdwAudioBytes1, - LPVOID *ppvAudioPtr2, LPDWORD pdwAudioBytes2, DWORD dwFlags) PURE; - STDMETHOD(Play) (THIS_ DWORD dwReserved1, DWORD dwPriority, DWORD dwFlags) PURE; - STDMETHOD(SetCurrentPosition) (THIS_ DWORD dwNewPosition) PURE; - STDMETHOD(SetFormat) (THIS_ LPCWAVEFORMATEX pcfxFormat) PURE; - STDMETHOD(SetVolume) (THIS_ LONG lVolume) PURE; - STDMETHOD(SetPan) (THIS_ LONG lPan) PURE; - STDMETHOD(SetFrequency) (THIS_ DWORD dwFrequency) PURE; - STDMETHOD(Stop) (THIS) PURE; - STDMETHOD(Unlock) (THIS_ LPVOID pvAudioPtr1, DWORD dwAudioBytes1, LPVOID pvAudioPtr2, DWORD dwAudioBytes2) PURE; - STDMETHOD(Restore) (THIS) PURE; -}; - -#define IDirectSoundBuffer_QueryInterface(p,a,b) IUnknown_QueryInterface(p,a,b) -#define IDirectSoundBuffer_AddRef(p) IUnknown_AddRef(p) -#define IDirectSoundBuffer_Release(p) IUnknown_Release(p) - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectSoundBuffer_GetCaps(p,a) (p)->lpVtbl->GetCaps(p,a) -#define IDirectSoundBuffer_GetCurrentPosition(p,a,b) (p)->lpVtbl->GetCurrentPosition(p,a,b) -#define IDirectSoundBuffer_GetFormat(p,a,b,c) (p)->lpVtbl->GetFormat(p,a,b,c) -#define IDirectSoundBuffer_GetVolume(p,a) (p)->lpVtbl->GetVolume(p,a) -#define IDirectSoundBuffer_GetPan(p,a) (p)->lpVtbl->GetPan(p,a) -#define IDirectSoundBuffer_GetFrequency(p,a) (p)->lpVtbl->GetFrequency(p,a) -#define IDirectSoundBuffer_GetStatus(p,a) (p)->lpVtbl->GetStatus(p,a) -#define IDirectSoundBuffer_Initialize(p,a,b) (p)->lpVtbl->Initialize(p,a,b) -#define IDirectSoundBuffer_Lock(p,a,b,c,d,e,f,g) (p)->lpVtbl->Lock(p,a,b,c,d,e,f,g) -#define IDirectSoundBuffer_Play(p,a,b,c) (p)->lpVtbl->Play(p,a,b,c) -#define IDirectSoundBuffer_SetCurrentPosition(p,a) (p)->lpVtbl->SetCurrentPosition(p,a) -#define IDirectSoundBuffer_SetFormat(p,a) (p)->lpVtbl->SetFormat(p,a) -#define IDirectSoundBuffer_SetVolume(p,a) (p)->lpVtbl->SetVolume(p,a) -#define IDirectSoundBuffer_SetPan(p,a) (p)->lpVtbl->SetPan(p,a) -#define IDirectSoundBuffer_SetFrequency(p,a) (p)->lpVtbl->SetFrequency(p,a) -#define IDirectSoundBuffer_Stop(p) (p)->lpVtbl->Stop(p) -#define IDirectSoundBuffer_Unlock(p,a,b,c,d) (p)->lpVtbl->Unlock(p,a,b,c,d) -#define IDirectSoundBuffer_Restore(p) (p)->lpVtbl->Restore(p) -#else // !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectSoundBuffer_GetCaps(p,a) (p)->GetCaps(a) -#define IDirectSoundBuffer_GetCurrentPosition(p,a,b) (p)->GetCurrentPosition(a,b) -#define IDirectSoundBuffer_GetFormat(p,a,b,c) (p)->GetFormat(a,b,c) -#define IDirectSoundBuffer_GetVolume(p,a) (p)->GetVolume(a) -#define IDirectSoundBuffer_GetPan(p,a) (p)->GetPan(a) -#define IDirectSoundBuffer_GetFrequency(p,a) (p)->GetFrequency(a) -#define IDirectSoundBuffer_GetStatus(p,a) (p)->GetStatus(a) -#define IDirectSoundBuffer_Initialize(p,a,b) (p)->Initialize(a,b) -#define IDirectSoundBuffer_Lock(p,a,b,c,d,e,f,g) (p)->Lock(a,b,c,d,e,f,g) -#define IDirectSoundBuffer_Play(p,a,b,c) (p)->Play(a,b,c) -#define IDirectSoundBuffer_SetCurrentPosition(p,a) (p)->SetCurrentPosition(a) -#define IDirectSoundBuffer_SetFormat(p,a) (p)->SetFormat(a) -#define IDirectSoundBuffer_SetVolume(p,a) (p)->SetVolume(a) -#define IDirectSoundBuffer_SetPan(p,a) (p)->SetPan(a) -#define IDirectSoundBuffer_SetFrequency(p,a) (p)->SetFrequency(a) -#define IDirectSoundBuffer_Stop(p) (p)->Stop() -#define IDirectSoundBuffer_Unlock(p,a,b,c,d) (p)->Unlock(a,b,c,d) -#define IDirectSoundBuffer_Restore(p) (p)->Restore() -#endif // !defined(__cplusplus) || defined(CINTERFACE) - -#if DIRECTSOUND_VERSION >= 0x0800 - -// -// IDirectSoundBuffer8 -// - -DEFINE_GUID(IID_IDirectSoundBuffer8, 0x6825a449, 0x7524, 0x4d82, 0x92, 0x0f, 0x50, 0xe3, 0x6a, 0xb3, 0xab, 0x1e); - -#undef INTERFACE -#define INTERFACE IDirectSoundBuffer8 - -DECLARE_INTERFACE_(IDirectSoundBuffer8, IDirectSoundBuffer) -{ - // IUnknown methods - STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE; - STDMETHOD_(ULONG,AddRef) (THIS) PURE; - STDMETHOD_(ULONG,Release) (THIS) PURE; - - // IDirectSoundBuffer methods - STDMETHOD(GetCaps) (THIS_ LPDSBCAPS pDSBufferCaps) PURE; - STDMETHOD(GetCurrentPosition) (THIS_ LPDWORD pdwCurrentPlayCursor, LPDWORD pdwCurrentWriteCursor) PURE; - STDMETHOD(GetFormat) (THIS_ LPWAVEFORMATEX pwfxFormat, DWORD dwSizeAllocated, LPDWORD pdwSizeWritten) PURE; - STDMETHOD(GetVolume) (THIS_ LPLONG plVolume) PURE; - STDMETHOD(GetPan) (THIS_ LPLONG plPan) PURE; - STDMETHOD(GetFrequency) (THIS_ LPDWORD pdwFrequency) PURE; - STDMETHOD(GetStatus) (THIS_ LPDWORD pdwStatus) PURE; - STDMETHOD(Initialize) (THIS_ LPDIRECTSOUND pDirectSound, LPCDSBUFFERDESC pcDSBufferDesc) PURE; - STDMETHOD(Lock) (THIS_ DWORD dwOffset, DWORD dwBytes, LPVOID *ppvAudioPtr1, LPDWORD pdwAudioBytes1, - LPVOID *ppvAudioPtr2, LPDWORD pdwAudioBytes2, DWORD dwFlags) PURE; - STDMETHOD(Play) (THIS_ DWORD dwReserved1, DWORD dwPriority, DWORD dwFlags) PURE; - STDMETHOD(SetCurrentPosition) (THIS_ DWORD dwNewPosition) PURE; - STDMETHOD(SetFormat) (THIS_ LPCWAVEFORMATEX pcfxFormat) PURE; - STDMETHOD(SetVolume) (THIS_ LONG lVolume) PURE; - STDMETHOD(SetPan) (THIS_ LONG lPan) PURE; - STDMETHOD(SetFrequency) (THIS_ DWORD dwFrequency) PURE; - STDMETHOD(Stop) (THIS) PURE; - STDMETHOD(Unlock) (THIS_ LPVOID pvAudioPtr1, DWORD dwAudioBytes1, LPVOID pvAudioPtr2, DWORD dwAudioBytes2) PURE; - STDMETHOD(Restore) (THIS) PURE; - - // IDirectSoundBuffer8 methods - STDMETHOD(SetFX) (THIS_ DWORD dwEffectsCount, LPDSEFFECTDESC pDSFXDesc, LPDWORD pdwResultCodes) PURE; - STDMETHOD(AcquireResources) (THIS_ DWORD dwFlags, DWORD dwEffectsCount, LPDWORD pdwResultCodes) PURE; - STDMETHOD(GetObjectInPath) (THIS_ REFGUID rguidObject, DWORD dwIndex, REFGUID rguidInterface, LPVOID *ppObject) PURE; -}; - -// Special GUID meaning "select all objects" for use in GetObjectInPath() -DEFINE_GUID(GUID_All_Objects, 0xaa114de5, 0xc262, 0x4169, 0xa1, 0xc8, 0x23, 0xd6, 0x98, 0xcc, 0x73, 0xb5); - -#define IDirectSoundBuffer8_QueryInterface(p,a,b) IUnknown_QueryInterface(p,a,b) -#define IDirectSoundBuffer8_AddRef(p) IUnknown_AddRef(p) -#define IDirectSoundBuffer8_Release(p) IUnknown_Release(p) - -#define IDirectSoundBuffer8_GetCaps(p,a) IDirectSoundBuffer_GetCaps(p,a) -#define IDirectSoundBuffer8_GetCurrentPosition(p,a,b) IDirectSoundBuffer_GetCurrentPosition(p,a,b) -#define IDirectSoundBuffer8_GetFormat(p,a,b,c) IDirectSoundBuffer_GetFormat(p,a,b,c) -#define IDirectSoundBuffer8_GetVolume(p,a) IDirectSoundBuffer_GetVolume(p,a) -#define IDirectSoundBuffer8_GetPan(p,a) IDirectSoundBuffer_GetPan(p,a) -#define IDirectSoundBuffer8_GetFrequency(p,a) IDirectSoundBuffer_GetFrequency(p,a) -#define IDirectSoundBuffer8_GetStatus(p,a) IDirectSoundBuffer_GetStatus(p,a) -#define IDirectSoundBuffer8_Initialize(p,a,b) IDirectSoundBuffer_Initialize(p,a,b) -#define IDirectSoundBuffer8_Lock(p,a,b,c,d,e,f,g) IDirectSoundBuffer_Lock(p,a,b,c,d,e,f,g) -#define IDirectSoundBuffer8_Play(p,a,b,c) IDirectSoundBuffer_Play(p,a,b,c) -#define IDirectSoundBuffer8_SetCurrentPosition(p,a) IDirectSoundBuffer_SetCurrentPosition(p,a) -#define IDirectSoundBuffer8_SetFormat(p,a) IDirectSoundBuffer_SetFormat(p,a) -#define IDirectSoundBuffer8_SetVolume(p,a) IDirectSoundBuffer_SetVolume(p,a) -#define IDirectSoundBuffer8_SetPan(p,a) IDirectSoundBuffer_SetPan(p,a) -#define IDirectSoundBuffer8_SetFrequency(p,a) IDirectSoundBuffer_SetFrequency(p,a) -#define IDirectSoundBuffer8_Stop(p) IDirectSoundBuffer_Stop(p) -#define IDirectSoundBuffer8_Unlock(p,a,b,c,d) IDirectSoundBuffer_Unlock(p,a,b,c,d) -#define IDirectSoundBuffer8_Restore(p) IDirectSoundBuffer_Restore(p) - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectSoundBuffer8_SetFX(p,a,b,c) (p)->lpVtbl->SetFX(p,a,b,c) -#define IDirectSoundBuffer8_AcquireResources(p,a,b,c) (p)->lpVtbl->AcquireResources(p,a,b,c) -#define IDirectSoundBuffer8_GetObjectInPath(p,a,b,c,d) (p)->lpVtbl->GetObjectInPath(p,a,b,c,d) -#else // !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectSoundBuffer8_SetFX(p,a,b,c) (p)->SetFX(a,b,c) -#define IDirectSoundBuffer8_AcquireResources(p,a,b,c) (p)->AcquireResources(a,b,c) -#define IDirectSoundBuffer8_GetObjectInPath(p,a,b,c,d) (p)->GetObjectInPath(a,b,c,d) -#endif // !defined(__cplusplus) || defined(CINTERFACE) - -#endif // DIRECTSOUND_VERSION >= 0x0800 - -// -// IDirectSound3DListener -// - -DEFINE_GUID(IID_IDirectSound3DListener, 0x279AFA84, 0x4981, 0x11CE, 0xA5, 0x21, 0x00, 0x20, 0xAF, 0x0B, 0xE5, 0x60); - -#undef INTERFACE -#define INTERFACE IDirectSound3DListener - -DECLARE_INTERFACE_(IDirectSound3DListener, IUnknown) -{ - // IUnknown methods - STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE; - STDMETHOD_(ULONG,AddRef) (THIS) PURE; - STDMETHOD_(ULONG,Release) (THIS) PURE; - - // IDirectSound3DListener methods - STDMETHOD(GetAllParameters) (THIS_ LPDS3DLISTENER pListener) PURE; - STDMETHOD(GetDistanceFactor) (THIS_ D3DVALUE* pflDistanceFactor) PURE; - STDMETHOD(GetDopplerFactor) (THIS_ D3DVALUE* pflDopplerFactor) PURE; - STDMETHOD(GetOrientation) (THIS_ D3DVECTOR* pvOrientFront, D3DVECTOR* pvOrientTop) PURE; - STDMETHOD(GetPosition) (THIS_ D3DVECTOR* pvPosition) PURE; - STDMETHOD(GetRolloffFactor) (THIS_ D3DVALUE* pflRolloffFactor) PURE; - STDMETHOD(GetVelocity) (THIS_ D3DVECTOR* pvVelocity) PURE; - STDMETHOD(SetAllParameters) (THIS_ LPCDS3DLISTENER pcListener, DWORD dwApply) PURE; - STDMETHOD(SetDistanceFactor) (THIS_ D3DVALUE flDistanceFactor, DWORD dwApply) PURE; - STDMETHOD(SetDopplerFactor) (THIS_ D3DVALUE flDopplerFactor, DWORD dwApply) PURE; - STDMETHOD(SetOrientation) (THIS_ D3DVALUE xFront, D3DVALUE yFront, D3DVALUE zFront, - D3DVALUE xTop, D3DVALUE yTop, D3DVALUE zTop, DWORD dwApply) PURE; - STDMETHOD(SetPosition) (THIS_ D3DVALUE x, D3DVALUE y, D3DVALUE z, DWORD dwApply) PURE; - STDMETHOD(SetRolloffFactor) (THIS_ D3DVALUE flRolloffFactor, DWORD dwApply) PURE; - STDMETHOD(SetVelocity) (THIS_ D3DVALUE x, D3DVALUE y, D3DVALUE z, DWORD dwApply) PURE; - STDMETHOD(CommitDeferredSettings) (THIS) PURE; -}; - -#define IDirectSound3DListener_QueryInterface(p,a,b) IUnknown_QueryInterface(p,a,b) -#define IDirectSound3DListener_AddRef(p) IUnknown_AddRef(p) -#define IDirectSound3DListener_Release(p) IUnknown_Release(p) - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectSound3DListener_GetAllParameters(p,a) (p)->lpVtbl->GetAllParameters(p,a) -#define IDirectSound3DListener_GetDistanceFactor(p,a) (p)->lpVtbl->GetDistanceFactor(p,a) -#define IDirectSound3DListener_GetDopplerFactor(p,a) (p)->lpVtbl->GetDopplerFactor(p,a) -#define IDirectSound3DListener_GetOrientation(p,a,b) (p)->lpVtbl->GetOrientation(p,a,b) -#define IDirectSound3DListener_GetPosition(p,a) (p)->lpVtbl->GetPosition(p,a) -#define IDirectSound3DListener_GetRolloffFactor(p,a) (p)->lpVtbl->GetRolloffFactor(p,a) -#define IDirectSound3DListener_GetVelocity(p,a) (p)->lpVtbl->GetVelocity(p,a) -#define IDirectSound3DListener_SetAllParameters(p,a,b) (p)->lpVtbl->SetAllParameters(p,a,b) -#define IDirectSound3DListener_SetDistanceFactor(p,a,b) (p)->lpVtbl->SetDistanceFactor(p,a,b) -#define IDirectSound3DListener_SetDopplerFactor(p,a,b) (p)->lpVtbl->SetDopplerFactor(p,a,b) -#define IDirectSound3DListener_SetOrientation(p,a,b,c,d,e,f,g) (p)->lpVtbl->SetOrientation(p,a,b,c,d,e,f,g) -#define IDirectSound3DListener_SetPosition(p,a,b,c,d) (p)->lpVtbl->SetPosition(p,a,b,c,d) -#define IDirectSound3DListener_SetRolloffFactor(p,a,b) (p)->lpVtbl->SetRolloffFactor(p,a,b) -#define IDirectSound3DListener_SetVelocity(p,a,b,c,d) (p)->lpVtbl->SetVelocity(p,a,b,c,d) -#define IDirectSound3DListener_CommitDeferredSettings(p) (p)->lpVtbl->CommitDeferredSettings(p) -#else // !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectSound3DListener_GetAllParameters(p,a) (p)->GetAllParameters(a) -#define IDirectSound3DListener_GetDistanceFactor(p,a) (p)->GetDistanceFactor(a) -#define IDirectSound3DListener_GetDopplerFactor(p,a) (p)->GetDopplerFactor(a) -#define IDirectSound3DListener_GetOrientation(p,a,b) (p)->GetOrientation(a,b) -#define IDirectSound3DListener_GetPosition(p,a) (p)->GetPosition(a) -#define IDirectSound3DListener_GetRolloffFactor(p,a) (p)->GetRolloffFactor(a) -#define IDirectSound3DListener_GetVelocity(p,a) (p)->GetVelocity(a) -#define IDirectSound3DListener_SetAllParameters(p,a,b) (p)->SetAllParameters(a,b) -#define IDirectSound3DListener_SetDistanceFactor(p,a,b) (p)->SetDistanceFactor(a,b) -#define IDirectSound3DListener_SetDopplerFactor(p,a,b) (p)->SetDopplerFactor(a,b) -#define IDirectSound3DListener_SetOrientation(p,a,b,c,d,e,f,g) (p)->SetOrientation(a,b,c,d,e,f,g) -#define IDirectSound3DListener_SetPosition(p,a,b,c,d) (p)->SetPosition(a,b,c,d) -#define IDirectSound3DListener_SetRolloffFactor(p,a,b) (p)->SetRolloffFactor(a,b) -#define IDirectSound3DListener_SetVelocity(p,a,b,c,d) (p)->SetVelocity(a,b,c,d) -#define IDirectSound3DListener_CommitDeferredSettings(p) (p)->CommitDeferredSettings() -#endif // !defined(__cplusplus) || defined(CINTERFACE) - -// -// IDirectSound3DBuffer -// - -DEFINE_GUID(IID_IDirectSound3DBuffer, 0x279AFA86, 0x4981, 0x11CE, 0xA5, 0x21, 0x00, 0x20, 0xAF, 0x0B, 0xE5, 0x60); - -#undef INTERFACE -#define INTERFACE IDirectSound3DBuffer - -DECLARE_INTERFACE_(IDirectSound3DBuffer, IUnknown) -{ - // IUnknown methods - STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE; - STDMETHOD_(ULONG,AddRef) (THIS) PURE; - STDMETHOD_(ULONG,Release) (THIS) PURE; - - // IDirectSound3DBuffer methods - STDMETHOD(GetAllParameters) (THIS_ LPDS3DBUFFER pDs3dBuffer) PURE; - STDMETHOD(GetConeAngles) (THIS_ LPDWORD pdwInsideConeAngle, LPDWORD pdwOutsideConeAngle) PURE; - STDMETHOD(GetConeOrientation) (THIS_ D3DVECTOR* pvOrientation) PURE; - STDMETHOD(GetConeOutsideVolume) (THIS_ LPLONG plConeOutsideVolume) PURE; - STDMETHOD(GetMaxDistance) (THIS_ D3DVALUE* pflMaxDistance) PURE; - STDMETHOD(GetMinDistance) (THIS_ D3DVALUE* pflMinDistance) PURE; - STDMETHOD(GetMode) (THIS_ LPDWORD pdwMode) PURE; - STDMETHOD(GetPosition) (THIS_ D3DVECTOR* pvPosition) PURE; - STDMETHOD(GetVelocity) (THIS_ D3DVECTOR* pvVelocity) PURE; - STDMETHOD(SetAllParameters) (THIS_ LPCDS3DBUFFER pcDs3dBuffer, DWORD dwApply) PURE; - STDMETHOD(SetConeAngles) (THIS_ DWORD dwInsideConeAngle, DWORD dwOutsideConeAngle, DWORD dwApply) PURE; - STDMETHOD(SetConeOrientation) (THIS_ D3DVALUE x, D3DVALUE y, D3DVALUE z, DWORD dwApply) PURE; - STDMETHOD(SetConeOutsideVolume) (THIS_ LONG lConeOutsideVolume, DWORD dwApply) PURE; - STDMETHOD(SetMaxDistance) (THIS_ D3DVALUE flMaxDistance, DWORD dwApply) PURE; - STDMETHOD(SetMinDistance) (THIS_ D3DVALUE flMinDistance, DWORD dwApply) PURE; - STDMETHOD(SetMode) (THIS_ DWORD dwMode, DWORD dwApply) PURE; - STDMETHOD(SetPosition) (THIS_ D3DVALUE x, D3DVALUE y, D3DVALUE z, DWORD dwApply) PURE; - STDMETHOD(SetVelocity) (THIS_ D3DVALUE x, D3DVALUE y, D3DVALUE z, DWORD dwApply) PURE; -}; - -#define IDirectSound3DBuffer_QueryInterface(p,a,b) IUnknown_QueryInterface(p,a,b) -#define IDirectSound3DBuffer_AddRef(p) IUnknown_AddRef(p) -#define IDirectSound3DBuffer_Release(p) IUnknown_Release(p) - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectSound3DBuffer_GetAllParameters(p,a) (p)->lpVtbl->GetAllParameters(p,a) -#define IDirectSound3DBuffer_GetConeAngles(p,a,b) (p)->lpVtbl->GetConeAngles(p,a,b) -#define IDirectSound3DBuffer_GetConeOrientation(p,a) (p)->lpVtbl->GetConeOrientation(p,a) -#define IDirectSound3DBuffer_GetConeOutsideVolume(p,a) (p)->lpVtbl->GetConeOutsideVolume(p,a) -#define IDirectSound3DBuffer_GetPosition(p,a) (p)->lpVtbl->GetPosition(p,a) -#define IDirectSound3DBuffer_GetMinDistance(p,a) (p)->lpVtbl->GetMinDistance(p,a) -#define IDirectSound3DBuffer_GetMaxDistance(p,a) (p)->lpVtbl->GetMaxDistance(p,a) -#define IDirectSound3DBuffer_GetMode(p,a) (p)->lpVtbl->GetMode(p,a) -#define IDirectSound3DBuffer_GetVelocity(p,a) (p)->lpVtbl->GetVelocity(p,a) -#define IDirectSound3DBuffer_SetAllParameters(p,a,b) (p)->lpVtbl->SetAllParameters(p,a,b) -#define IDirectSound3DBuffer_SetConeAngles(p,a,b,c) (p)->lpVtbl->SetConeAngles(p,a,b,c) -#define IDirectSound3DBuffer_SetConeOrientation(p,a,b,c,d) (p)->lpVtbl->SetConeOrientation(p,a,b,c,d) -#define IDirectSound3DBuffer_SetConeOutsideVolume(p,a,b) (p)->lpVtbl->SetConeOutsideVolume(p,a,b) -#define IDirectSound3DBuffer_SetPosition(p,a,b,c,d) (p)->lpVtbl->SetPosition(p,a,b,c,d) -#define IDirectSound3DBuffer_SetMinDistance(p,a,b) (p)->lpVtbl->SetMinDistance(p,a,b) -#define IDirectSound3DBuffer_SetMaxDistance(p,a,b) (p)->lpVtbl->SetMaxDistance(p,a,b) -#define IDirectSound3DBuffer_SetMode(p,a,b) (p)->lpVtbl->SetMode(p,a,b) -#define IDirectSound3DBuffer_SetVelocity(p,a,b,c,d) (p)->lpVtbl->SetVelocity(p,a,b,c,d) -#else // !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectSound3DBuffer_GetAllParameters(p,a) (p)->GetAllParameters(a) -#define IDirectSound3DBuffer_GetConeAngles(p,a,b) (p)->GetConeAngles(a,b) -#define IDirectSound3DBuffer_GetConeOrientation(p,a) (p)->GetConeOrientation(a) -#define IDirectSound3DBuffer_GetConeOutsideVolume(p,a) (p)->GetConeOutsideVolume(a) -#define IDirectSound3DBuffer_GetPosition(p,a) (p)->GetPosition(a) -#define IDirectSound3DBuffer_GetMinDistance(p,a) (p)->GetMinDistance(a) -#define IDirectSound3DBuffer_GetMaxDistance(p,a) (p)->GetMaxDistance(a) -#define IDirectSound3DBuffer_GetMode(p,a) (p)->GetMode(a) -#define IDirectSound3DBuffer_GetVelocity(p,a) (p)->GetVelocity(a) -#define IDirectSound3DBuffer_SetAllParameters(p,a,b) (p)->SetAllParameters(a,b) -#define IDirectSound3DBuffer_SetConeAngles(p,a,b,c) (p)->SetConeAngles(a,b,c) -#define IDirectSound3DBuffer_SetConeOrientation(p,a,b,c,d) (p)->SetConeOrientation(a,b,c,d) -#define IDirectSound3DBuffer_SetConeOutsideVolume(p,a,b) (p)->SetConeOutsideVolume(a,b) -#define IDirectSound3DBuffer_SetPosition(p,a,b,c,d) (p)->SetPosition(a,b,c,d) -#define IDirectSound3DBuffer_SetMinDistance(p,a,b) (p)->SetMinDistance(a,b) -#define IDirectSound3DBuffer_SetMaxDistance(p,a,b) (p)->SetMaxDistance(a,b) -#define IDirectSound3DBuffer_SetMode(p,a,b) (p)->SetMode(a,b) -#define IDirectSound3DBuffer_SetVelocity(p,a,b,c,d) (p)->SetVelocity(a,b,c,d) -#endif // !defined(__cplusplus) || defined(CINTERFACE) - -// -// IDirectSoundCapture -// - -DEFINE_GUID(IID_IDirectSoundCapture, 0xb0210781, 0x89cd, 0x11d0, 0xaf, 0x8, 0x0, 0xa0, 0xc9, 0x25, 0xcd, 0x16); - -#undef INTERFACE -#define INTERFACE IDirectSoundCapture - -DECLARE_INTERFACE_(IDirectSoundCapture, IUnknown) -{ - // IUnknown methods - STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE; - STDMETHOD_(ULONG,AddRef) (THIS) PURE; - STDMETHOD_(ULONG,Release) (THIS) PURE; - - // IDirectSoundCapture methods - STDMETHOD(CreateCaptureBuffer) (THIS_ LPCDSCBUFFERDESC pcDSCBufferDesc, LPDIRECTSOUNDCAPTUREBUFFER *ppDSCBuffer, LPUNKNOWN pUnkOuter) PURE; - STDMETHOD(GetCaps) (THIS_ LPDSCCAPS pDSCCaps) PURE; - STDMETHOD(Initialize) (THIS_ LPCGUID pcGuidDevice) PURE; -}; - -#define IDirectSoundCapture_QueryInterface(p,a,b) IUnknown_QueryInterface(p,a,b) -#define IDirectSoundCapture_AddRef(p) IUnknown_AddRef(p) -#define IDirectSoundCapture_Release(p) IUnknown_Release(p) - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectSoundCapture_CreateCaptureBuffer(p,a,b,c) (p)->lpVtbl->CreateCaptureBuffer(p,a,b,c) -#define IDirectSoundCapture_GetCaps(p,a) (p)->lpVtbl->GetCaps(p,a) -#define IDirectSoundCapture_Initialize(p,a) (p)->lpVtbl->Initialize(p,a) -#else // !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectSoundCapture_CreateCaptureBuffer(p,a,b,c) (p)->CreateCaptureBuffer(a,b,c) -#define IDirectSoundCapture_GetCaps(p,a) (p)->GetCaps(a) -#define IDirectSoundCapture_Initialize(p,a) (p)->Initialize(a) -#endif // !defined(__cplusplus) || defined(CINTERFACE) - -// -// IDirectSoundCaptureBuffer -// - -DEFINE_GUID(IID_IDirectSoundCaptureBuffer, 0xb0210782, 0x89cd, 0x11d0, 0xaf, 0x8, 0x0, 0xa0, 0xc9, 0x25, 0xcd, 0x16); - -#undef INTERFACE -#define INTERFACE IDirectSoundCaptureBuffer - -DECLARE_INTERFACE_(IDirectSoundCaptureBuffer, IUnknown) -{ - // IUnknown methods - STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE; - STDMETHOD_(ULONG,AddRef) (THIS) PURE; - STDMETHOD_(ULONG,Release) (THIS) PURE; - - // IDirectSoundCaptureBuffer methods - STDMETHOD(GetCaps) (THIS_ LPDSCBCAPS pDSCBCaps) PURE; - STDMETHOD(GetCurrentPosition) (THIS_ LPDWORD pdwCapturePosition, LPDWORD pdwReadPosition) PURE; - STDMETHOD(GetFormat) (THIS_ LPWAVEFORMATEX pwfxFormat, DWORD dwSizeAllocated, LPDWORD pdwSizeWritten) PURE; - STDMETHOD(GetStatus) (THIS_ LPDWORD pdwStatus) PURE; - STDMETHOD(Initialize) (THIS_ LPDIRECTSOUNDCAPTURE pDirectSoundCapture, LPCDSCBUFFERDESC pcDSCBufferDesc) PURE; - STDMETHOD(Lock) (THIS_ DWORD dwOffset, DWORD dwBytes, LPVOID *ppvAudioPtr1, LPDWORD pdwAudioBytes1, - LPVOID *ppvAudioPtr2, LPDWORD pdwAudioBytes2, DWORD dwFlags) PURE; - STDMETHOD(Start) (THIS_ DWORD dwFlags) PURE; - STDMETHOD(Stop) (THIS) PURE; - STDMETHOD(Unlock) (THIS_ LPVOID pvAudioPtr1, DWORD dwAudioBytes1, LPVOID pvAudioPtr2, DWORD dwAudioBytes2) PURE; -}; - -#define IDirectSoundCaptureBuffer_QueryInterface(p,a,b) IUnknown_QueryInterface(p,a,b) -#define IDirectSoundCaptureBuffer_AddRef(p) IUnknown_AddRef(p) -#define IDirectSoundCaptureBuffer_Release(p) IUnknown_Release(p) - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectSoundCaptureBuffer_GetCaps(p,a) (p)->lpVtbl->GetCaps(p,a) -#define IDirectSoundCaptureBuffer_GetCurrentPosition(p,a,b) (p)->lpVtbl->GetCurrentPosition(p,a,b) -#define IDirectSoundCaptureBuffer_GetFormat(p,a,b,c) (p)->lpVtbl->GetFormat(p,a,b,c) -#define IDirectSoundCaptureBuffer_GetStatus(p,a) (p)->lpVtbl->GetStatus(p,a) -#define IDirectSoundCaptureBuffer_Initialize(p,a,b) (p)->lpVtbl->Initialize(p,a,b) -#define IDirectSoundCaptureBuffer_Lock(p,a,b,c,d,e,f,g) (p)->lpVtbl->Lock(p,a,b,c,d,e,f,g) -#define IDirectSoundCaptureBuffer_Start(p,a) (p)->lpVtbl->Start(p,a) -#define IDirectSoundCaptureBuffer_Stop(p) (p)->lpVtbl->Stop(p) -#define IDirectSoundCaptureBuffer_Unlock(p,a,b,c,d) (p)->lpVtbl->Unlock(p,a,b,c,d) -#else // !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectSoundCaptureBuffer_GetCaps(p,a) (p)->GetCaps(a) -#define IDirectSoundCaptureBuffer_GetCurrentPosition(p,a,b) (p)->GetCurrentPosition(a,b) -#define IDirectSoundCaptureBuffer_GetFormat(p,a,b,c) (p)->GetFormat(a,b,c) -#define IDirectSoundCaptureBuffer_GetStatus(p,a) (p)->GetStatus(a) -#define IDirectSoundCaptureBuffer_Initialize(p,a,b) (p)->Initialize(a,b) -#define IDirectSoundCaptureBuffer_Lock(p,a,b,c,d,e,f,g) (p)->Lock(a,b,c,d,e,f,g) -#define IDirectSoundCaptureBuffer_Start(p,a) (p)->Start(a) -#define IDirectSoundCaptureBuffer_Stop(p) (p)->Stop() -#define IDirectSoundCaptureBuffer_Unlock(p,a,b,c,d) (p)->Unlock(a,b,c,d) -#endif // !defined(__cplusplus) || defined(CINTERFACE) - - -#if DIRECTSOUND_VERSION >= 0x0800 - -// -// IDirectSoundCaptureBuffer8 -// - -DEFINE_GUID(IID_IDirectSoundCaptureBuffer8, 0x990df4, 0xdbb, 0x4872, 0x83, 0x3e, 0x6d, 0x30, 0x3e, 0x80, 0xae, 0xb6); - -#undef INTERFACE -#define INTERFACE IDirectSoundCaptureBuffer8 - -DECLARE_INTERFACE_(IDirectSoundCaptureBuffer8, IDirectSoundCaptureBuffer) -{ - // IUnknown methods - STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE; - STDMETHOD_(ULONG,AddRef) (THIS) PURE; - STDMETHOD_(ULONG,Release) (THIS) PURE; - - // IDirectSoundCaptureBuffer methods - STDMETHOD(GetCaps) (THIS_ LPDSCBCAPS pDSCBCaps) PURE; - STDMETHOD(GetCurrentPosition) (THIS_ LPDWORD pdwCapturePosition, LPDWORD pdwReadPosition) PURE; - STDMETHOD(GetFormat) (THIS_ LPWAVEFORMATEX pwfxFormat, DWORD dwSizeAllocated, LPDWORD pdwSizeWritten) PURE; - STDMETHOD(GetStatus) (THIS_ LPDWORD pdwStatus) PURE; - STDMETHOD(Initialize) (THIS_ LPDIRECTSOUNDCAPTURE pDirectSoundCapture, LPCDSCBUFFERDESC pcDSCBufferDesc) PURE; - STDMETHOD(Lock) (THIS_ DWORD dwOffset, DWORD dwBytes, LPVOID *ppvAudioPtr1, LPDWORD pdwAudioBytes1, - LPVOID *ppvAudioPtr2, LPDWORD pdwAudioBytes2, DWORD dwFlags) PURE; - STDMETHOD(Start) (THIS_ DWORD dwFlags) PURE; - STDMETHOD(Stop) (THIS) PURE; - STDMETHOD(Unlock) (THIS_ LPVOID pvAudioPtr1, DWORD dwAudioBytes1, LPVOID pvAudioPtr2, DWORD dwAudioBytes2) PURE; - - // IDirectSoundCaptureBuffer8 methods - STDMETHOD(GetObjectInPath) (THIS_ REFGUID rguidObject, DWORD dwIndex, REFGUID rguidInterface, LPVOID *ppObject) PURE; - STDMETHOD(GetFXStatus) (DWORD dwFXCount, LPDWORD pdwFXStatus) PURE; -}; - -#define IDirectSoundCaptureBuffer8_QueryInterface(p,a,b) IUnknown_QueryInterface(p,a,b) -#define IDirectSoundCaptureBuffer8_AddRef(p) IUnknown_AddRef(p) -#define IDirectSoundCaptureBuffer8_Release(p) IUnknown_Release(p) - -#define IDirectSoundCaptureBuffer8_GetCaps(p,a) IDirectSoundCaptureBuffer_GetCaps(p,a) -#define IDirectSoundCaptureBuffer8_GetCurrentPosition(p,a,b) IDirectSoundCaptureBuffer_GetCurrentPosition(p,a,b) -#define IDirectSoundCaptureBuffer8_GetFormat(p,a,b,c) IDirectSoundCaptureBuffer_GetFormat(p,a,b,c) -#define IDirectSoundCaptureBuffer8_GetStatus(p,a) IDirectSoundCaptureBuffer_GetStatus(p,a) -#define IDirectSoundCaptureBuffer8_Initialize(p,a,b) IDirectSoundCaptureBuffer_Initialize(p,a,b) -#define IDirectSoundCaptureBuffer8_Lock(p,a,b,c,d,e,f,g) IDirectSoundCaptureBuffer_Lock(p,a,b,c,d,e,f,g) -#define IDirectSoundCaptureBuffer8_Start(p,a) IDirectSoundCaptureBuffer_Start(p,a) -#define IDirectSoundCaptureBuffer8_Stop(p) IDirectSoundCaptureBuffer_Stop(p)) -#define IDirectSoundCaptureBuffer8_Unlock(p,a,b,c,d) IDirectSoundCaptureBuffer_Unlock(p,a,b,c,d) - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectSoundCaptureBuffer8_GetObjectInPath(p,a,b,c,d) (p)->lpVtbl->GetObjectInPath(p,a,b,c,d) -#define IDirectSoundCaptureBuffer8_GetFXStatus(p,a,b) (p)->lpVtbl->GetFXStatus(p,a,b) -#else // !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectSoundCaptureBuffer8_GetObjectInPath(p,a,b,c,d) (p)->GetObjectInPath(a,b,c,d) -#define IDirectSoundCaptureBuffer8_GetFXStatus(p,a,b) (p)->GetFXStatus(a,b) -#endif // !defined(__cplusplus) || defined(CINTERFACE) - -#endif // DIRECTSOUND_VERSION >= 0x0800 - -// -// IDirectSoundNotify -// - -DEFINE_GUID(IID_IDirectSoundNotify, 0xb0210783, 0x89cd, 0x11d0, 0xaf, 0x8, 0x0, 0xa0, 0xc9, 0x25, 0xcd, 0x16); - -#undef INTERFACE -#define INTERFACE IDirectSoundNotify - -DECLARE_INTERFACE_(IDirectSoundNotify, IUnknown) -{ - // IUnknown methods - STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE; - STDMETHOD_(ULONG,AddRef) (THIS) PURE; - STDMETHOD_(ULONG,Release) (THIS) PURE; - - // IDirectSoundNotify methods - STDMETHOD(SetNotificationPositions) (THIS_ DWORD dwPositionNotifies, LPCDSBPOSITIONNOTIFY pcPositionNotifies) PURE; -}; - -#define IDirectSoundNotify_QueryInterface(p,a,b) IUnknown_QueryInterface(p,a,b) -#define IDirectSoundNotify_AddRef(p) IUnknown_AddRef(p) -#define IDirectSoundNotify_Release(p) IUnknown_Release(p) - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectSoundNotify_SetNotificationPositions(p,a,b) (p)->lpVtbl->SetNotificationPositions(p,a,b) -#else // !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectSoundNotify_SetNotificationPositions(p,a,b) (p)->SetNotificationPositions(a,b) -#endif // !defined(__cplusplus) || defined(CINTERFACE) - -// -// IKsPropertySet -// - -#ifndef _IKsPropertySet_ -#define _IKsPropertySet_ - -#ifdef __cplusplus -// 'struct' not 'class' per the way DECLARE_INTERFACE_ is defined -struct IKsPropertySet; -#endif // __cplusplus - -typedef struct IKsPropertySet *LPKSPROPERTYSET; - -#define KSPROPERTY_SUPPORT_GET 0x00000001 -#define KSPROPERTY_SUPPORT_SET 0x00000002 - -DEFINE_GUID(IID_IKsPropertySet, 0x31efac30, 0x515c, 0x11d0, 0xa9, 0xaa, 0x00, 0xaa, 0x00, 0x61, 0xbe, 0x93); - -#undef INTERFACE -#define INTERFACE IKsPropertySet - -DECLARE_INTERFACE_(IKsPropertySet, IUnknown) -{ - // IUnknown methods - STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE; - STDMETHOD_(ULONG,AddRef) (THIS) PURE; - STDMETHOD_(ULONG,Release) (THIS) PURE; - - // IKsPropertySet methods - STDMETHOD(Get) (THIS_ REFGUID rguidPropSet, ULONG ulId, LPVOID pInstanceData, ULONG ulInstanceLength, - LPVOID pPropertyData, ULONG ulDataLength, PULONG pulBytesReturned) PURE; - STDMETHOD(Set) (THIS_ REFGUID rguidPropSet, ULONG ulId, LPVOID pInstanceData, ULONG ulInstanceLength, - LPVOID pPropertyData, ULONG ulDataLength) PURE; - STDMETHOD(QuerySupport) (THIS_ REFGUID rguidPropSet, ULONG ulId, PULONG pulTypeSupport) PURE; -}; - -#define IKsPropertySet_QueryInterface(p,a,b) IUnknown_QueryInterface(p,a,b) -#define IKsPropertySet_AddRef(p) IUnknown_AddRef(p) -#define IKsPropertySet_Release(p) IUnknown_Release(p) - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IKsPropertySet_Get(p,a,b,c,d,e,f,g) (p)->lpVtbl->Get(p,a,b,c,d,e,f,g) -#define IKsPropertySet_Set(p,a,b,c,d,e,f) (p)->lpVtbl->Set(p,a,b,c,d,e,f) -#define IKsPropertySet_QuerySupport(p,a,b,c) (p)->lpVtbl->QuerySupport(p,a,b,c) -#else // !defined(__cplusplus) || defined(CINTERFACE) -#define IKsPropertySet_Get(p,a,b,c,d,e,f,g) (p)->Get(a,b,c,d,e,f,g) -#define IKsPropertySet_Set(p,a,b,c,d,e,f) (p)->Set(a,b,c,d,e,f) -#define IKsPropertySet_QuerySupport(p,a,b,c) (p)->QuerySupport(a,b,c) -#endif // !defined(__cplusplus) || defined(CINTERFACE) - -#endif // _IKsPropertySet_ - -#if DIRECTSOUND_VERSION >= 0x0800 - -// -// IDirectSoundFXGargle -// - -DEFINE_GUID(IID_IDirectSoundFXGargle, 0xd616f352, 0xd622, 0x11ce, 0xaa, 0xc5, 0x00, 0x20, 0xaf, 0x0b, 0x99, 0xa3); - -typedef struct _DSFXGargle -{ - DWORD dwRateHz; // Rate of modulation in hz - DWORD dwWaveShape; // DSFXGARGLE_WAVE_xxx -} DSFXGargle, *LPDSFXGargle; - -#define DSFXGARGLE_WAVE_TRIANGLE 0 -#define DSFXGARGLE_WAVE_SQUARE 1 - -typedef const DSFXGargle *LPCDSFXGargle; - -#define DSFXGARGLE_RATEHZ_MIN 1 -#define DSFXGARGLE_RATEHZ_MAX 1000 - -#undef INTERFACE -#define INTERFACE IDirectSoundFXGargle - -DECLARE_INTERFACE_(IDirectSoundFXGargle, IUnknown) -{ - // IUnknown methods - STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE; - STDMETHOD_(ULONG,AddRef) (THIS) PURE; - STDMETHOD_(ULONG,Release) (THIS) PURE; - - // IDirectSoundFXGargle methods - STDMETHOD(SetAllParameters) (THIS_ LPCDSFXGargle pcDsFxGargle) PURE; - STDMETHOD(GetAllParameters) (THIS_ LPDSFXGargle pDsFxGargle) PURE; -}; - -#define IDirectSoundFXGargle_QueryInterface(p,a,b) IUnknown_QueryInterface(p,a,b) -#define IDirectSoundFXGargle_AddRef(p) IUnknown_AddRef(p) -#define IDirectSoundFXGargle_Release(p) IUnknown_Release(p) - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectSoundFXGargle_SetAllParameters(p,a) (p)->lpVtbl->SetAllParameters(p,a) -#define IDirectSoundFXGargle_GetAllParameters(p,a) (p)->lpVtbl->GetAllParameters(p,a) -#else // !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectSoundFXGargle_SetAllParameters(p,a) (p)->SetAllParameters(a) -#define IDirectSoundFXGargle_GetAllParameters(p,a) (p)->GetAllParameters(a) -#endif // !defined(__cplusplus) || defined(CINTERFACE) - -// -// IDirectSoundFXChorus -// - -DEFINE_GUID(IID_IDirectSoundFXChorus, 0x880842e3, 0x145f, 0x43e6, 0xa9, 0x34, 0xa7, 0x18, 0x06, 0xe5, 0x05, 0x47); - -typedef struct _DSFXChorus -{ - FLOAT fWetDryMix; - FLOAT fDepth; - FLOAT fFeedback; - FLOAT fFrequency; - LONG lWaveform; // LFO shape; DSFXCHORUS_WAVE_xxx - FLOAT fDelay; - LONG lPhase; -} DSFXChorus, *LPDSFXChorus; - -typedef const DSFXChorus *LPCDSFXChorus; - -#define DSFXCHORUS_WAVE_TRIANGLE 0 -#define DSFXCHORUS_WAVE_SIN 1 - -#define DSFXCHORUS_WETDRYMIX_MIN 0.0f -#define DSFXCHORUS_WETDRYMIX_MAX 100.0f -#define DSFXCHORUS_DEPTH_MIN 0.0f -#define DSFXCHORUS_DEPTH_MAX 100.0f -#define DSFXCHORUS_FEEDBACK_MIN -99.0f -#define DSFXCHORUS_FEEDBACK_MAX 99.0f -#define DSFXCHORUS_FREQUENCY_MIN 0.0f -#define DSFXCHORUS_FREQUENCY_MAX 10.0f -#define DSFXCHORUS_DELAY_MIN 0.0f -#define DSFXCHORUS_DELAY_MAX 20.0f -#define DSFXCHORUS_PHASE_MIN 0 -#define DSFXCHORUS_PHASE_MAX 4 - -#define DSFXCHORUS_PHASE_NEG_180 0 -#define DSFXCHORUS_PHASE_NEG_90 1 -#define DSFXCHORUS_PHASE_ZERO 2 -#define DSFXCHORUS_PHASE_90 3 -#define DSFXCHORUS_PHASE_180 4 - -#undef INTERFACE -#define INTERFACE IDirectSoundFXChorus - -DECLARE_INTERFACE_(IDirectSoundFXChorus, IUnknown) -{ - // IUnknown methods - STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE; - STDMETHOD_(ULONG,AddRef) (THIS) PURE; - STDMETHOD_(ULONG,Release) (THIS) PURE; - - // IDirectSoundFXChorus methods - STDMETHOD(SetAllParameters) (THIS_ LPCDSFXChorus pcDsFxChorus) PURE; - STDMETHOD(GetAllParameters) (THIS_ LPDSFXChorus pDsFxChorus) PURE; -}; - -#define IDirectSoundFXChorus_QueryInterface(p,a,b) IUnknown_QueryInterface(p,a,b) -#define IDirectSoundFXChorus_AddRef(p) IUnknown_AddRef(p) -#define IDirectSoundFXChorus_Release(p) IUnknown_Release(p) - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectSoundFXChorus_SetAllParameters(p,a) (p)->lpVtbl->SetAllParameters(p,a) -#define IDirectSoundFXChorus_GetAllParameters(p,a) (p)->lpVtbl->GetAllParameters(p,a) -#else // !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectSoundFXChorus_SetAllParameters(p,a) (p)->SetAllParameters(a) -#define IDirectSoundFXChorus_GetAllParameters(p,a) (p)->GetAllParameters(a) -#endif // !defined(__cplusplus) || defined(CINTERFACE) - -// -// IDirectSoundFXFlanger -// - -DEFINE_GUID(IID_IDirectSoundFXFlanger, 0x903e9878, 0x2c92, 0x4072, 0x9b, 0x2c, 0xea, 0x68, 0xf5, 0x39, 0x67, 0x83); - -typedef struct _DSFXFlanger -{ - FLOAT fWetDryMix; - FLOAT fDepth; - FLOAT fFeedback; - FLOAT fFrequency; - LONG lWaveform; - FLOAT fDelay; - LONG lPhase; -} DSFXFlanger, *LPDSFXFlanger; - -typedef const DSFXFlanger *LPCDSFXFlanger; - -#define DSFXFLANGER_WAVE_TRIANGLE 0 -#define DSFXFLANGER_WAVE_SIN 1 - -#define DSFXFLANGER_WETDRYMIX_MIN 0.0f -#define DSFXFLANGER_WETDRYMIX_MAX 100.0f -#define DSFXFLANGER_FREQUENCY_MIN 0.0f -#define DSFXFLANGER_FREQUENCY_MAX 10.0f -#define DSFXFLANGER_DEPTH_MIN 0.0f -#define DSFXFLANGER_DEPTH_MAX 100.0f -#define DSFXFLANGER_PHASE_MIN 0 -#define DSFXFLANGER_PHASE_MAX 4 -#define DSFXFLANGER_FEEDBACK_MIN -99.0f -#define DSFXFLANGER_FEEDBACK_MAX 99.0f -#define DSFXFLANGER_DELAY_MIN 0.0f -#define DSFXFLANGER_DELAY_MAX 4.0f - -#define DSFXFLANGER_PHASE_NEG_180 0 -#define DSFXFLANGER_PHASE_NEG_90 1 -#define DSFXFLANGER_PHASE_ZERO 2 -#define DSFXFLANGER_PHASE_90 3 -#define DSFXFLANGER_PHASE_180 4 - -#undef INTERFACE -#define INTERFACE IDirectSoundFXFlanger - -DECLARE_INTERFACE_(IDirectSoundFXFlanger, IUnknown) -{ - // IUnknown methods - STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE; - STDMETHOD_(ULONG,AddRef) (THIS) PURE; - STDMETHOD_(ULONG,Release) (THIS) PURE; - - // IDirectSoundFXFlanger methods - STDMETHOD(SetAllParameters) (THIS_ LPCDSFXFlanger pcDsFxFlanger) PURE; - STDMETHOD(GetAllParameters) (THIS_ LPDSFXFlanger pDsFxFlanger) PURE; -}; - -#define IDirectSoundFXFlanger_QueryInterface(p,a,b) IUnknown_QueryInterface(p,a,b) -#define IDirectSoundFXFlanger_AddRef(p) IUnknown_AddRef(p) -#define IDirectSoundFXFlanger_Release(p) IUnknown_Release(p) - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectSoundFXFlanger_SetAllParameters(p,a) (p)->lpVtbl->SetAllParameters(p,a) -#define IDirectSoundFXFlanger_GetAllParameters(p,a) (p)->lpVtbl->GetAllParameters(p,a) -#else // !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectSoundFXFlanger_SetAllParameters(p,a) (p)->SetAllParameters(a) -#define IDirectSoundFXFlanger_GetAllParameters(p,a) (p)->GetAllParameters(a) -#endif // !defined(__cplusplus) || defined(CINTERFACE) - -// -// IDirectSoundFXEcho -// - -DEFINE_GUID(IID_IDirectSoundFXEcho, 0x8bd28edf, 0x50db, 0x4e92, 0xa2, 0xbd, 0x44, 0x54, 0x88, 0xd1, 0xed, 0x42); - -typedef struct _DSFXEcho -{ - FLOAT fWetDryMix; - FLOAT fFeedback; - FLOAT fLeftDelay; - FLOAT fRightDelay; - LONG lPanDelay; -} DSFXEcho, *LPDSFXEcho; - -typedef const DSFXEcho *LPCDSFXEcho; - -#define DSFXECHO_WETDRYMIX_MIN 0.0f -#define DSFXECHO_WETDRYMIX_MAX 100.0f -#define DSFXECHO_FEEDBACK_MIN 0.0f -#define DSFXECHO_FEEDBACK_MAX 100.0f -#define DSFXECHO_LEFTDELAY_MIN 1.0f -#define DSFXECHO_LEFTDELAY_MAX 2000.0f -#define DSFXECHO_RIGHTDELAY_MIN 1.0f -#define DSFXECHO_RIGHTDELAY_MAX 2000.0f -#define DSFXECHO_PANDELAY_MIN 0 -#define DSFXECHO_PANDELAY_MAX 1 - -#undef INTERFACE -#define INTERFACE IDirectSoundFXEcho - -DECLARE_INTERFACE_(IDirectSoundFXEcho, IUnknown) -{ - // IUnknown methods - STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE; - STDMETHOD_(ULONG,AddRef) (THIS) PURE; - STDMETHOD_(ULONG,Release) (THIS) PURE; - - // IDirectSoundFXEcho methods - STDMETHOD(SetAllParameters) (THIS_ LPCDSFXEcho pcDsFxEcho) PURE; - STDMETHOD(GetAllParameters) (THIS_ LPDSFXEcho pDsFxEcho) PURE; -}; - -#define IDirectSoundFXEcho_QueryInterface(p,a,b) IUnknown_QueryInterface(p,a,b) -#define IDirectSoundFXEcho_AddRef(p) IUnknown_AddRef(p) -#define IDirectSoundFXEcho_Release(p) IUnknown_Release(p) - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectSoundFXEcho_SetAllParameters(p,a) (p)->lpVtbl->SetAllParameters(p,a) -#define IDirectSoundFXEcho_GetAllParameters(p,a) (p)->lpVtbl->GetAllParameters(p,a) -#else // !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectSoundFXEcho_SetAllParameters(p,a) (p)->SetAllParameters(a) -#define IDirectSoundFXEcho_GetAllParameters(p,a) (p)->GetAllParameters(a) -#endif // !defined(__cplusplus) || defined(CINTERFACE) - -// -// IDirectSoundFXDistortion -// - -DEFINE_GUID(IID_IDirectSoundFXDistortion, 0x8ecf4326, 0x455f, 0x4d8b, 0xbd, 0xa9, 0x8d, 0x5d, 0x3e, 0x9e, 0x3e, 0x0b); - -typedef struct _DSFXDistortion -{ - FLOAT fGain; - FLOAT fEdge; - FLOAT fPostEQCenterFrequency; - FLOAT fPostEQBandwidth; - FLOAT fPreLowpassCutoff; -} DSFXDistortion, *LPDSFXDistortion; - -typedef const DSFXDistortion *LPCDSFXDistortion; - -#define DSFXDISTORTION_GAIN_MIN -60.0f -#define DSFXDISTORTION_GAIN_MAX 0.0f -#define DSFXDISTORTION_EDGE_MIN 0.0f -#define DSFXDISTORTION_EDGE_MAX 100.0f -#define DSFXDISTORTION_POSTEQCENTERFREQUENCY_MIN 100.0f -#define DSFXDISTORTION_POSTEQCENTERFREQUENCY_MAX 8000.0f -#define DSFXDISTORTION_POSTEQBANDWIDTH_MIN 100.0f -#define DSFXDISTORTION_POSTEQBANDWIDTH_MAX 8000.0f -#define DSFXDISTORTION_PRELOWPASSCUTOFF_MIN 100.0f -#define DSFXDISTORTION_PRELOWPASSCUTOFF_MAX 8000.0f - -#undef INTERFACE -#define INTERFACE IDirectSoundFXDistortion - -DECLARE_INTERFACE_(IDirectSoundFXDistortion, IUnknown) -{ - // IUnknown methods - STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE; - STDMETHOD_(ULONG,AddRef) (THIS) PURE; - STDMETHOD_(ULONG,Release) (THIS) PURE; - - // IDirectSoundFXDistortion methods - STDMETHOD(SetAllParameters) (THIS_ LPCDSFXDistortion pcDsFxDistortion) PURE; - STDMETHOD(GetAllParameters) (THIS_ LPDSFXDistortion pDsFxDistortion) PURE; -}; - -#define IDirectSoundFXDistortion_QueryInterface(p,a,b) IUnknown_QueryInterface(p,a,b) -#define IDirectSoundFXDistortion_AddRef(p) IUnknown_AddRef(p) -#define IDirectSoundFXDistortion_Release(p) IUnknown_Release(p) - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectSoundFXDistortion_SetAllParameters(p,a) (p)->lpVtbl->SetAllParameters(p,a) -#define IDirectSoundFXDistortion_GetAllParameters(p,a) (p)->lpVtbl->GetAllParameters(p,a) -#else // !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectSoundFXDistortion_SetAllParameters(p,a) (p)->SetAllParameters(a) -#define IDirectSoundFXDistortion_GetAllParameters(p,a) (p)->GetAllParameters(a) -#endif // !defined(__cplusplus) || defined(CINTERFACE) - -// -// IDirectSoundFXCompressor -// - -DEFINE_GUID(IID_IDirectSoundFXCompressor, 0x4bbd1154, 0x62f6, 0x4e2c, 0xa1, 0x5c, 0xd3, 0xb6, 0xc4, 0x17, 0xf7, 0xa0); - -typedef struct _DSFXCompressor -{ - FLOAT fGain; - FLOAT fAttack; - FLOAT fRelease; - FLOAT fThreshold; - FLOAT fRatio; - FLOAT fPredelay; -} DSFXCompressor, *LPDSFXCompressor; - -typedef const DSFXCompressor *LPCDSFXCompressor; - -#define DSFXCOMPRESSOR_GAIN_MIN -60.0f -#define DSFXCOMPRESSOR_GAIN_MAX 60.0f -#define DSFXCOMPRESSOR_ATTACK_MIN 0.01f -#define DSFXCOMPRESSOR_ATTACK_MAX 500.0f -#define DSFXCOMPRESSOR_RELEASE_MIN 50.0f -#define DSFXCOMPRESSOR_RELEASE_MAX 3000.0f -#define DSFXCOMPRESSOR_THRESHOLD_MIN -60.0f -#define DSFXCOMPRESSOR_THRESHOLD_MAX 0.0f -#define DSFXCOMPRESSOR_RATIO_MIN 1.0f -#define DSFXCOMPRESSOR_RATIO_MAX 100.0f -#define DSFXCOMPRESSOR_PREDELAY_MIN 0.0f -#define DSFXCOMPRESSOR_PREDELAY_MAX 4.0f - -#undef INTERFACE -#define INTERFACE IDirectSoundFXCompressor - -DECLARE_INTERFACE_(IDirectSoundFXCompressor, IUnknown) -{ - // IUnknown methods - STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE; - STDMETHOD_(ULONG,AddRef) (THIS) PURE; - STDMETHOD_(ULONG,Release) (THIS) PURE; - - // IDirectSoundFXCompressor methods - STDMETHOD(SetAllParameters) (THIS_ LPCDSFXCompressor pcDsFxCompressor) PURE; - STDMETHOD(GetAllParameters) (THIS_ LPDSFXCompressor pDsFxCompressor) PURE; -}; - -#define IDirectSoundFXCompressor_QueryInterface(p,a,b) IUnknown_QueryInterface(p,a,b) -#define IDirectSoundFXCompressor_AddRef(p) IUnknown_AddRef(p) -#define IDirectSoundFXCompressor_Release(p) IUnknown_Release(p) - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectSoundFXCompressor_SetAllParameters(p,a) (p)->lpVtbl->SetAllParameters(p,a) -#define IDirectSoundFXCompressor_GetAllParameters(p,a) (p)->lpVtbl->GetAllParameters(p,a) -#else // !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectSoundFXCompressor_SetAllParameters(p,a) (p)->SetAllParameters(a) -#define IDirectSoundFXCompressor_GetAllParameters(p,a) (p)->GetAllParameters(a) -#endif // !defined(__cplusplus) || defined(CINTERFACE) - -// -// IDirectSoundFXParamEq -// - -DEFINE_GUID(IID_IDirectSoundFXParamEq, 0xc03ca9fe, 0xfe90, 0x4204, 0x80, 0x78, 0x82, 0x33, 0x4c, 0xd1, 0x77, 0xda); - -typedef struct _DSFXParamEq -{ - FLOAT fCenter; - FLOAT fBandwidth; - FLOAT fGain; -} DSFXParamEq, *LPDSFXParamEq; - -typedef const DSFXParamEq *LPCDSFXParamEq; - -#define DSFXPARAMEQ_CENTER_MIN 80.0f -#define DSFXPARAMEQ_CENTER_MAX 16000.0f -#define DSFXPARAMEQ_BANDWIDTH_MIN 1.0f -#define DSFXPARAMEQ_BANDWIDTH_MAX 36.0f -#define DSFXPARAMEQ_GAIN_MIN -15.0f -#define DSFXPARAMEQ_GAIN_MAX 15.0f - -#undef INTERFACE -#define INTERFACE IDirectSoundFXParamEq - -DECLARE_INTERFACE_(IDirectSoundFXParamEq, IUnknown) -{ - // IUnknown methods - STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE; - STDMETHOD_(ULONG,AddRef) (THIS) PURE; - STDMETHOD_(ULONG,Release) (THIS) PURE; - - // IDirectSoundFXParamEq methods - STDMETHOD(SetAllParameters) (THIS_ LPCDSFXParamEq pcDsFxParamEq) PURE; - STDMETHOD(GetAllParameters) (THIS_ LPDSFXParamEq pDsFxParamEq) PURE; -}; - -#define IDirectSoundFXParamEq_QueryInterface(p,a,b) IUnknown_QueryInterface(p,a,b) -#define IDirectSoundFXParamEq_AddRef(p) IUnknown_AddRef(p) -#define IDirectSoundFXParamEq_Release(p) IUnknown_Release(p) - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectSoundFXParamEq_SetAllParameters(p,a) (p)->lpVtbl->SetAllParameters(p,a) -#define IDirectSoundFXParamEq_GetAllParameters(p,a) (p)->lpVtbl->GetAllParameters(p,a) -#else // !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectSoundFXParamEq_SetAllParameters(p,a) (p)->SetAllParameters(a) -#define IDirectSoundFXParamEq_GetAllParameters(p,a) (p)->GetAllParameters(a) -#endif // !defined(__cplusplus) || defined(CINTERFACE) - -// -// IDirectSoundFXI3DL2Reverb -// - -DEFINE_GUID(IID_IDirectSoundFXI3DL2Reverb, 0x4b166a6a, 0x0d66, 0x43f3, 0x80, 0xe3, 0xee, 0x62, 0x80, 0xde, 0xe1, 0xa4); - -typedef struct _DSFXI3DL2Reverb -{ - LONG lRoom; // [-10000, 0] default: -1000 mB - LONG lRoomHF; // [-10000, 0] default: 0 mB - FLOAT flRoomRolloffFactor; // [0.0, 10.0] default: 0.0 - FLOAT flDecayTime; // [0.1, 20.0] default: 1.49s - FLOAT flDecayHFRatio; // [0.1, 2.0] default: 0.83 - LONG lReflections; // [-10000, 1000] default: -2602 mB - FLOAT flReflectionsDelay; // [0.0, 0.3] default: 0.007 s - LONG lReverb; // [-10000, 2000] default: 200 mB - FLOAT flReverbDelay; // [0.0, 0.1] default: 0.011 s - FLOAT flDiffusion; // [0.0, 100.0] default: 100.0 % - FLOAT flDensity; // [0.0, 100.0] default: 100.0 % - FLOAT flHFReference; // [20.0, 20000.0] default: 5000.0 Hz -} DSFXI3DL2Reverb, *LPDSFXI3DL2Reverb; - -typedef const DSFXI3DL2Reverb *LPCDSFXI3DL2Reverb; - -#define DSFX_I3DL2REVERB_ROOM_MIN (-10000) -#define DSFX_I3DL2REVERB_ROOM_MAX 0 -#define DSFX_I3DL2REVERB_ROOM_DEFAULT (-1000) - -#define DSFX_I3DL2REVERB_ROOMHF_MIN (-10000) -#define DSFX_I3DL2REVERB_ROOMHF_MAX 0 -#define DSFX_I3DL2REVERB_ROOMHF_DEFAULT (-100) - -#define DSFX_I3DL2REVERB_ROOMROLLOFFFACTOR_MIN 0.0f -#define DSFX_I3DL2REVERB_ROOMROLLOFFFACTOR_MAX 10.0f -#define DSFX_I3DL2REVERB_ROOMROLLOFFFACTOR_DEFAULT 0.0f - -#define DSFX_I3DL2REVERB_DECAYTIME_MIN 0.1f -#define DSFX_I3DL2REVERB_DECAYTIME_MAX 20.0f -#define DSFX_I3DL2REVERB_DECAYTIME_DEFAULT 1.49f - -#define DSFX_I3DL2REVERB_DECAYHFRATIO_MIN 0.1f -#define DSFX_I3DL2REVERB_DECAYHFRATIO_MAX 2.0f -#define DSFX_I3DL2REVERB_DECAYHFRATIO_DEFAULT 0.83f - -#define DSFX_I3DL2REVERB_REFLECTIONS_MIN (-10000) -#define DSFX_I3DL2REVERB_REFLECTIONS_MAX 1000 -#define DSFX_I3DL2REVERB_REFLECTIONS_DEFAULT (-2602) - -#define DSFX_I3DL2REVERB_REFLECTIONSDELAY_MIN 0.0f -#define DSFX_I3DL2REVERB_REFLECTIONSDELAY_MAX 0.3f -#define DSFX_I3DL2REVERB_REFLECTIONSDELAY_DEFAULT 0.007f - -#define DSFX_I3DL2REVERB_REVERB_MIN (-10000) -#define DSFX_I3DL2REVERB_REVERB_MAX 2000 -#define DSFX_I3DL2REVERB_REVERB_DEFAULT (200) - -#define DSFX_I3DL2REVERB_REVERBDELAY_MIN 0.0f -#define DSFX_I3DL2REVERB_REVERBDELAY_MAX 0.1f -#define DSFX_I3DL2REVERB_REVERBDELAY_DEFAULT 0.011f - -#define DSFX_I3DL2REVERB_DIFFUSION_MIN 0.0f -#define DSFX_I3DL2REVERB_DIFFUSION_MAX 100.0f -#define DSFX_I3DL2REVERB_DIFFUSION_DEFAULT 100.0f - -#define DSFX_I3DL2REVERB_DENSITY_MIN 0.0f -#define DSFX_I3DL2REVERB_DENSITY_MAX 100.0f -#define DSFX_I3DL2REVERB_DENSITY_DEFAULT 100.0f - -#define DSFX_I3DL2REVERB_HFREFERENCE_MIN 20.0f -#define DSFX_I3DL2REVERB_HFREFERENCE_MAX 20000.0f -#define DSFX_I3DL2REVERB_HFREFERENCE_DEFAULT 5000.0f - -#define DSFX_I3DL2REVERB_QUALITY_MIN 0 -#define DSFX_I3DL2REVERB_QUALITY_MAX 3 -#define DSFX_I3DL2REVERB_QUALITY_DEFAULT 2 - -#undef INTERFACE -#define INTERFACE IDirectSoundFXI3DL2Reverb - -DECLARE_INTERFACE_(IDirectSoundFXI3DL2Reverb, IUnknown) -{ - // IUnknown methods - STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE; - STDMETHOD_(ULONG,AddRef) (THIS) PURE; - STDMETHOD_(ULONG,Release) (THIS) PURE; - - // IDirectSoundFXI3DL2Reverb methods - STDMETHOD(SetAllParameters) (THIS_ LPCDSFXI3DL2Reverb pcDsFxI3DL2Reverb) PURE; - STDMETHOD(GetAllParameters) (THIS_ LPDSFXI3DL2Reverb pDsFxI3DL2Reverb) PURE; - STDMETHOD(SetPreset) (THIS_ DWORD dwPreset) PURE; - STDMETHOD(GetPreset) (THIS_ LPDWORD pdwPreset) PURE; - STDMETHOD(SetQuality) (THIS_ LONG lQuality) PURE; - STDMETHOD(GetQuality) (THIS_ LONG *plQuality) PURE; -}; - -#define IDirectSoundFXI3DL2Reverb_QueryInterface(p,a,b) IUnknown_QueryInterface(p,a,b) -#define IDirectSoundFXI3DL2Reverb_AddRef(p) IUnknown_AddRef(p) -#define IDirectSoundFXI3DL2Reverb_Release(p) IUnknown_Release(p) - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectSoundFXI3DL2Reverb_SetAllParameters(p,a) (p)->lpVtbl->SetAllParameters(p,a) -#define IDirectSoundFXI3DL2Reverb_GetAllParameters(p,a) (p)->lpVtbl->GetAllParameters(p,a) -#define IDirectSoundFXI3DL2Reverb_SetPreset(p,a) (p)->lpVtbl->SetPreset(p,a) -#define IDirectSoundFXI3DL2Reverb_GetPreset(p,a) (p)->lpVtbl->GetPreset(p,a) -#else // !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectSoundFXI3DL2Reverb_SetAllParameters(p,a) (p)->SetAllParameters(a) -#define IDirectSoundFXI3DL2Reverb_GetAllParameters(p,a) (p)->GetAllParameters(a) -#define IDirectSoundFXI3DL2Reverb_SetPreset(p,a) (p)->SetPreset(a) -#define IDirectSoundFXI3DL2Reverb_GetPreset(p,a) (p)->GetPreset(a) -#endif // !defined(__cplusplus) || defined(CINTERFACE) - -// -// IDirectSoundFXWavesReverb -// - -DEFINE_GUID(IID_IDirectSoundFXWavesReverb,0x46858c3a,0x0dc6,0x45e3,0xb7,0x60,0xd4,0xee,0xf1,0x6c,0xb3,0x25); - -typedef struct _DSFXWavesReverb -{ - FLOAT fInGain; // [-96.0,0.0] default: 0.0 dB - FLOAT fReverbMix; // [-96.0,0.0] default: 0.0 db - FLOAT fReverbTime; // [0.001,3000.0] default: 1000.0 ms - FLOAT fHighFreqRTRatio; // [0.001,0.999] default: 0.001 -} DSFXWavesReverb, *LPDSFXWavesReverb; - -typedef const DSFXWavesReverb *LPCDSFXWavesReverb; - -#define DSFX_WAVESREVERB_INGAIN_MIN -96.0f -#define DSFX_WAVESREVERB_INGAIN_MAX 0.0f -#define DSFX_WAVESREVERB_INGAIN_DEFAULT 0.0f -#define DSFX_WAVESREVERB_REVERBMIX_MIN -96.0f -#define DSFX_WAVESREVERB_REVERBMIX_MAX 0.0f -#define DSFX_WAVESREVERB_REVERBMIX_DEFAULT 0.0f -#define DSFX_WAVESREVERB_REVERBTIME_MIN 0.001f -#define DSFX_WAVESREVERB_REVERBTIME_MAX 3000.0f -#define DSFX_WAVESREVERB_REVERBTIME_DEFAULT 1000.0f -#define DSFX_WAVESREVERB_HIGHFREQRTRATIO_MIN 0.001f -#define DSFX_WAVESREVERB_HIGHFREQRTRATIO_MAX 0.999f -#define DSFX_WAVESREVERB_HIGHFREQRTRATIO_DEFAULT 0.001f - -#undef INTERFACE -#define INTERFACE IDirectSoundFXWavesReverb - -DECLARE_INTERFACE_(IDirectSoundFXWavesReverb, IUnknown) -{ - // IUnknown methods - STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE; - STDMETHOD_(ULONG,AddRef) (THIS) PURE; - STDMETHOD_(ULONG,Release) (THIS) PURE; - - // IDirectSoundFXWavesReverb methods - STDMETHOD(SetAllParameters) (THIS_ LPCDSFXWavesReverb pcDsFxWavesReverb) PURE; - STDMETHOD(GetAllParameters) (THIS_ LPDSFXWavesReverb pDsFxWavesReverb) PURE; -}; - -#define IDirectSoundFXWavesReverb_QueryInterface(p,a,b) IUnknown_QueryInterface(p,a,b) -#define IDirectSoundFXWavesReverb_AddRef(p) IUnknown_AddRef(p) -#define IDirectSoundFXWavesReverb_Release(p) IUnknown_Release(p) - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectSoundFXWavesReverb_SetAllParameters(p,a) (p)->lpVtbl->SetAllParameters(p,a) -#define IDirectSoundFXWavesReverb_GetAllParameters(p,a) (p)->lpVtbl->GetAllParameters(p,a) -#else // !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectSoundFXWavesReverb_SetAllParameters(p,a) (p)->SetAllParameters(a) -#define IDirectSoundFXWavesReverb_GetAllParameters(p,a) (p)->GetAllParameters(a) -#endif // !defined(__cplusplus) || defined(CINTERFACE) - -// -// IDirectSoundCaptureFXAec -// - -DEFINE_GUID(IID_IDirectSoundCaptureFXAec, 0xad74143d, 0x903d, 0x4ab7, 0x80, 0x66, 0x28, 0xd3, 0x63, 0x03, 0x6d, 0x65); - -typedef struct _DSCFXAec -{ - BOOL fEnable; - BOOL fNoiseFill; - DWORD dwMode; -} DSCFXAec, *LPDSCFXAec; - -typedef const DSCFXAec *LPCDSCFXAec; - -// These match the AEC_MODE_* constants in the DDK's ksmedia.h file -#define DSCFX_AEC_MODE_PASS_THROUGH 0x0 -#define DSCFX_AEC_MODE_HALF_DUPLEX 0x1 -#define DSCFX_AEC_MODE_FULL_DUPLEX 0x2 - -// These match the AEC_STATUS_* constants in ksmedia.h -#define DSCFX_AEC_STATUS_HISTORY_UNINITIALIZED 0x0 -#define DSCFX_AEC_STATUS_HISTORY_CONTINUOUSLY_CONVERGED 0x1 -#define DSCFX_AEC_STATUS_HISTORY_PREVIOUSLY_DIVERGED 0x2 -#define DSCFX_AEC_STATUS_CURRENTLY_CONVERGED 0x8 - -#undef INTERFACE -#define INTERFACE IDirectSoundCaptureFXAec - -DECLARE_INTERFACE_(IDirectSoundCaptureFXAec, IUnknown) -{ - // IUnknown methods - STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE; - STDMETHOD_(ULONG,AddRef) (THIS) PURE; - STDMETHOD_(ULONG,Release) (THIS) PURE; - - // IDirectSoundCaptureFXAec methods - STDMETHOD(SetAllParameters) (THIS_ LPCDSCFXAec pDscFxAec) PURE; - STDMETHOD(GetAllParameters) (THIS_ LPDSCFXAec pDscFxAec) PURE; - STDMETHOD(GetStatus) (THIS_ PDWORD pdwStatus) PURE; - STDMETHOD(Reset) (THIS) PURE; -}; - -#define IDirectSoundCaptureFXAec_QueryInterface(p,a,b) IUnknown_QueryInterface(p,a,b) -#define IDirectSoundCaptureFXAec_AddRef(p) IUnknown_AddRef(p) -#define IDirectSoundCaptureFXAec_Release(p) IUnknown_Release(p) - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectSoundCaptureFXAec_SetAllParameters(p,a) (p)->lpVtbl->SetAllParameters(p,a) -#define IDirectSoundCaptureFXAec_GetAllParameters(p,a) (p)->lpVtbl->GetAllParameters(p,a) -#else // !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectSoundCaptureFXAec_SetAllParameters(p,a) (p)->SetAllParameters(a) -#define IDirectSoundCaptureFXAec_GetAllParameters(p,a) (p)->GetAllParameters(a) -#endif // !defined(__cplusplus) || defined(CINTERFACE) - - -// -// IDirectSoundCaptureFXNoiseSuppress -// - -DEFINE_GUID(IID_IDirectSoundCaptureFXNoiseSuppress, 0xed311e41, 0xfbae, 0x4175, 0x96, 0x25, 0xcd, 0x8, 0x54, 0xf6, 0x93, 0xca); - -typedef struct _DSCFXNoiseSuppress -{ - BOOL fEnable; -} DSCFXNoiseSuppress, *LPDSCFXNoiseSuppress; - -typedef const DSCFXNoiseSuppress *LPCDSCFXNoiseSuppress; - -#undef INTERFACE -#define INTERFACE IDirectSoundCaptureFXNoiseSuppress - -DECLARE_INTERFACE_(IDirectSoundCaptureFXNoiseSuppress, IUnknown) -{ - // IUnknown methods - STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE; - STDMETHOD_(ULONG,AddRef) (THIS) PURE; - STDMETHOD_(ULONG,Release) (THIS) PURE; - - // IDirectSoundCaptureFXNoiseSuppress methods - STDMETHOD(SetAllParameters) (THIS_ LPCDSCFXNoiseSuppress pcDscFxNoiseSuppress) PURE; - STDMETHOD(GetAllParameters) (THIS_ LPDSCFXNoiseSuppress pDscFxNoiseSuppress) PURE; - STDMETHOD(Reset) (THIS) PURE; -}; - -#define IDirectSoundCaptureFXNoiseSuppress_QueryInterface(p,a,b) IUnknown_QueryInterface(p,a,b) -#define IDirectSoundCaptureFXNoiseSuppress_AddRef(p) IUnknown_AddRef(p) -#define IDirectSoundCaptureFXNoiseSuppress_Release(p) IUnknown_Release(p) - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectSoundCaptureFXNoiseSuppress_SetAllParameters(p,a) (p)->lpVtbl->SetAllParameters(p,a) -#define IDirectSoundCaptureFXNoiseSuppress_GetAllParameters(p,a) (p)->lpVtbl->GetAllParameters(p,a) -#else // !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectSoundCaptureFXNoiseSuppress_SetAllParameters(p,a) (p)->SetAllParameters(a) -#define IDirectSoundCaptureFXNoiseSuppress_GetAllParameters(p,a) (p)->GetAllParameters(a) -#endif // !defined(__cplusplus) || defined(CINTERFACE) - - -// -// IDirectSoundFullDuplex -// - -#ifndef _IDirectSoundFullDuplex_ -#define _IDirectSoundFullDuplex_ - -#ifdef __cplusplus -// 'struct' not 'class' per the way DECLARE_INTERFACE_ is defined -struct IDirectSoundFullDuplex; -#endif // __cplusplus - -typedef struct IDirectSoundFullDuplex *LPDIRECTSOUNDFULLDUPLEX; - -DEFINE_GUID(IID_IDirectSoundFullDuplex, 0xedcb4c7a, 0xdaab, 0x4216, 0xa4, 0x2e, 0x6c, 0x50, 0x59, 0x6d, 0xdc, 0x1d); - -#undef INTERFACE -#define INTERFACE IDirectSoundFullDuplex - -DECLARE_INTERFACE_(IDirectSoundFullDuplex, IUnknown) -{ - // IUnknown methods - STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE; - STDMETHOD_(ULONG,AddRef) (THIS) PURE; - STDMETHOD_(ULONG,Release) (THIS) PURE; - - // IDirectSoundFullDuplex methods - STDMETHOD(Initialize) (THIS_ LPCGUID pCaptureGuid, LPCGUID pRenderGuid, LPCDSCBUFFERDESC lpDscBufferDesc, LPCDSBUFFERDESC lpDsBufferDesc, HWND hWnd, DWORD dwLevel, LPLPDIRECTSOUNDCAPTUREBUFFER8 lplpDirectSoundCaptureBuffer8, LPLPDIRECTSOUNDBUFFER8 lplpDirectSoundBuffer8) PURE; -}; - -#define IDirectSoundFullDuplex_QueryInterface(p,a,b) IUnknown_QueryInterface(p,a,b) -#define IDirectSoundFullDuplex_AddRef(p) IUnknown_AddRef(p) -#define IDirectSoundFullDuplex_Release(p) IUnknown_Release(p) - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectSoundFullDuplex_Initialize(p,a,b,c,d,e,f,g,h) (p)->lpVtbl->Initialize(p,a,b,c,d,e,f,g,h) -#else // !defined(__cplusplus) || defined(CINTERFACE) -#define IDirectSoundFullDuplex_Initialize(p,a,b,c,d,e,f,g,h) (p)->Initialize(a,b,c,d,e,f,g,h) -#endif // !defined(__cplusplus) || defined(CINTERFACE) - -#endif // _IDirectSoundFullDuplex_ - -#endif // DIRECTSOUND_VERSION >= 0x0800 - -// -// Return Codes -// - -// The function completed successfully -#define DS_OK S_OK - -// The call succeeded, but we had to substitute the 3D algorithm -#define DS_NO_VIRTUALIZATION MAKE_HRESULT(0, _FACDS, 10) - -// The call failed because resources (such as a priority level) -// were already being used by another caller -#define DSERR_ALLOCATED MAKE_DSHRESULT(10) - -// The control (vol, pan, etc.) requested by the caller is not available -#define DSERR_CONTROLUNAVAIL MAKE_DSHRESULT(30) - -// An invalid parameter was passed to the returning function -#define DSERR_INVALIDPARAM E_INVALIDARG - -// This call is not valid for the current state of this object -#define DSERR_INVALIDCALL MAKE_DSHRESULT(50) - -// An undetermined error occurred inside the DirectSound subsystem -#define DSERR_GENERIC E_FAIL - -// The caller does not have the priority level required for the function to -// succeed -#define DSERR_PRIOLEVELNEEDED MAKE_DSHRESULT(70) - -// Not enough free memory is available to complete the operation -#define DSERR_OUTOFMEMORY E_OUTOFMEMORY - -// The specified WAVE format is not supported -#define DSERR_BADFORMAT MAKE_DSHRESULT(100) - -// The function called is not supported at this time -#define DSERR_UNSUPPORTED E_NOTIMPL - -// No sound driver is available for use -#define DSERR_NODRIVER MAKE_DSHRESULT(120) - -// This object is already initialized -#define DSERR_ALREADYINITIALIZED MAKE_DSHRESULT(130) - -// This object does not support aggregation -#define DSERR_NOAGGREGATION CLASS_E_NOAGGREGATION - -// The buffer memory has been lost, and must be restored -#define DSERR_BUFFERLOST MAKE_DSHRESULT(150) - -// Another app has a higher priority level, preventing this call from -// succeeding -#define DSERR_OTHERAPPHASPRIO MAKE_DSHRESULT(160) - -// This object has not been initialized -#define DSERR_UNINITIALIZED MAKE_DSHRESULT(170) - -// The requested COM interface is not available -#define DSERR_NOINTERFACE E_NOINTERFACE - -// Access is denied -#define DSERR_ACCESSDENIED E_ACCESSDENIED - -// Tried to create a DSBCAPS_CTRLFX buffer shorter than DSBSIZE_FX_MIN milliseconds -#define DSERR_BUFFERTOOSMALL MAKE_DSHRESULT(180) - -// Attempt to use DirectSound 8 functionality on an older DirectSound object -#define DSERR_DS8_REQUIRED MAKE_DSHRESULT(190) - -// A circular loop of send effects was detected -#define DSERR_SENDLOOP MAKE_DSHRESULT(200) - -// The GUID specified in an audiopath file does not match a valid MIXIN buffer -#define DSERR_BADSENDBUFFERGUID MAKE_DSHRESULT(210) - -// The object requested was not found (numerically equal to DMUS_E_NOT_FOUND) -#define DSERR_OBJECTNOTFOUND MAKE_DSHRESULT(4449) - -// The effects requested could not be found on the system, or they were found -// but in the wrong order, or in the wrong hardware/software locations. -#define DSERR_FXUNAVAILABLE MAKE_DSHRESULT(220) - -// -// Flags -// - -#define DSCAPS_PRIMARYMONO 0x00000001 -#define DSCAPS_PRIMARYSTEREO 0x00000002 -#define DSCAPS_PRIMARY8BIT 0x00000004 -#define DSCAPS_PRIMARY16BIT 0x00000008 -#define DSCAPS_CONTINUOUSRATE 0x00000010 -#define DSCAPS_EMULDRIVER 0x00000020 -#define DSCAPS_CERTIFIED 0x00000040 -#define DSCAPS_SECONDARYMONO 0x00000100 -#define DSCAPS_SECONDARYSTEREO 0x00000200 -#define DSCAPS_SECONDARY8BIT 0x00000400 -#define DSCAPS_SECONDARY16BIT 0x00000800 - -#define DSSCL_NORMAL 0x00000001 -#define DSSCL_PRIORITY 0x00000002 -#define DSSCL_EXCLUSIVE 0x00000003 -#define DSSCL_WRITEPRIMARY 0x00000004 - -#define DSSPEAKER_DIRECTOUT 0x00000000 -#define DSSPEAKER_HEADPHONE 0x00000001 -#define DSSPEAKER_MONO 0x00000002 -#define DSSPEAKER_QUAD 0x00000003 -#define DSSPEAKER_STEREO 0x00000004 -#define DSSPEAKER_SURROUND 0x00000005 -#define DSSPEAKER_5POINT1 0x00000006 -#define DSSPEAKER_7POINT1 0x00000007 - -#define DSSPEAKER_GEOMETRY_MIN 0x00000005 // 5 degrees -#define DSSPEAKER_GEOMETRY_NARROW 0x0000000A // 10 degrees -#define DSSPEAKER_GEOMETRY_WIDE 0x00000014 // 20 degrees -#define DSSPEAKER_GEOMETRY_MAX 0x000000B4 // 180 degrees - -#define DSSPEAKER_COMBINED(c, g) ((DWORD)(((BYTE)(c)) | ((DWORD)((BYTE)(g))) << 16)) -#define DSSPEAKER_CONFIG(a) ((BYTE)(a)) -#define DSSPEAKER_GEOMETRY(a) ((BYTE)(((DWORD)(a) >> 16) & 0x00FF)) - -#define DSBCAPS_PRIMARYBUFFER 0x00000001 -#define DSBCAPS_STATIC 0x00000002 -#define DSBCAPS_LOCHARDWARE 0x00000004 -#define DSBCAPS_LOCSOFTWARE 0x00000008 -#define DSBCAPS_CTRL3D 0x00000010 -#define DSBCAPS_CTRLFREQUENCY 0x00000020 -#define DSBCAPS_CTRLPAN 0x00000040 -#define DSBCAPS_CTRLVOLUME 0x00000080 -#define DSBCAPS_CTRLPOSITIONNOTIFY 0x00000100 -#define DSBCAPS_CTRLFX 0x00000200 -#define DSBCAPS_STICKYFOCUS 0x00004000 -#define DSBCAPS_GLOBALFOCUS 0x00008000 -#define DSBCAPS_GETCURRENTPOSITION2 0x00010000 -#define DSBCAPS_MUTE3DATMAXDISTANCE 0x00020000 -#define DSBCAPS_LOCDEFER 0x00040000 - -#define DSBPLAY_LOOPING 0x00000001 -#define DSBPLAY_LOCHARDWARE 0x00000002 -#define DSBPLAY_LOCSOFTWARE 0x00000004 -#define DSBPLAY_TERMINATEBY_TIME 0x00000008 -#define DSBPLAY_TERMINATEBY_DISTANCE 0x000000010 -#define DSBPLAY_TERMINATEBY_PRIORITY 0x000000020 - -#define DSBSTATUS_PLAYING 0x00000001 -#define DSBSTATUS_BUFFERLOST 0x00000002 -#define DSBSTATUS_LOOPING 0x00000004 -#define DSBSTATUS_LOCHARDWARE 0x00000008 -#define DSBSTATUS_LOCSOFTWARE 0x00000010 -#define DSBSTATUS_TERMINATED 0x00000020 - -#define DSBLOCK_FROMWRITECURSOR 0x00000001 -#define DSBLOCK_ENTIREBUFFER 0x00000002 - -#define DSBFREQUENCY_ORIGINAL 0 -#define DSBFREQUENCY_MIN 100 -#if DIRECTSOUND_VERSION >= 0x0900 -#define DSBFREQUENCY_MAX 200000 -#else -#define DSBFREQUENCY_MAX 100000 -#endif - -#define DSBPAN_LEFT -10000 -#define DSBPAN_CENTER 0 -#define DSBPAN_RIGHT 10000 - -#define DSBVOLUME_MIN -10000 -#define DSBVOLUME_MAX 0 - -#define DSBSIZE_MIN 4 -#define DSBSIZE_MAX 0x0FFFFFFF -#define DSBSIZE_FX_MIN 150 // NOTE: Milliseconds, not bytes - -#define DS3DMODE_NORMAL 0x00000000 -#define DS3DMODE_HEADRELATIVE 0x00000001 -#define DS3DMODE_DISABLE 0x00000002 - -#define DS3D_IMMEDIATE 0x00000000 -#define DS3D_DEFERRED 0x00000001 - -#define DS3D_MINDISTANCEFACTOR FLT_MIN -#define DS3D_MAXDISTANCEFACTOR FLT_MAX -#define DS3D_DEFAULTDISTANCEFACTOR 1.0f - -#define DS3D_MINROLLOFFFACTOR 0.0f -#define DS3D_MAXROLLOFFFACTOR 10.0f -#define DS3D_DEFAULTROLLOFFFACTOR 1.0f - -#define DS3D_MINDOPPLERFACTOR 0.0f -#define DS3D_MAXDOPPLERFACTOR 10.0f -#define DS3D_DEFAULTDOPPLERFACTOR 1.0f - -#define DS3D_DEFAULTMINDISTANCE 1.0f -#define DS3D_DEFAULTMAXDISTANCE 1000000000.0f - -#define DS3D_MINCONEANGLE 0 -#define DS3D_MAXCONEANGLE 360 -#define DS3D_DEFAULTCONEANGLE 360 - -#define DS3D_DEFAULTCONEOUTSIDEVOLUME DSBVOLUME_MAX - -// IDirectSoundCapture attributes - -#define DSCCAPS_EMULDRIVER DSCAPS_EMULDRIVER -#define DSCCAPS_CERTIFIED DSCAPS_CERTIFIED -#define DSCCAPS_MULTIPLECAPTURE 0x00000001 - -// IDirectSoundCaptureBuffer attributes - -#define DSCBCAPS_WAVEMAPPED 0x80000000 - -#if DIRECTSOUND_VERSION >= 0x0800 -#define DSCBCAPS_CTRLFX 0x00000200 -#endif - - -#define DSCBLOCK_ENTIREBUFFER 0x00000001 - -#define DSCBSTATUS_CAPTURING 0x00000001 -#define DSCBSTATUS_LOOPING 0x00000002 - -#define DSCBSTART_LOOPING 0x00000001 - -#define DSBPN_OFFSETSTOP 0xFFFFFFFF - -#define DS_CERTIFIED 0x00000000 -#define DS_UNCERTIFIED 0x00000001 - - -// -// Flags for the I3DL2 effects -// - -// -// I3DL2 Material Presets -// - -enum -{ - DSFX_I3DL2_MATERIAL_PRESET_SINGLEWINDOW, - DSFX_I3DL2_MATERIAL_PRESET_DOUBLEWINDOW, - DSFX_I3DL2_MATERIAL_PRESET_THINDOOR, - DSFX_I3DL2_MATERIAL_PRESET_THICKDOOR, - DSFX_I3DL2_MATERIAL_PRESET_WOODWALL, - DSFX_I3DL2_MATERIAL_PRESET_BRICKWALL, - DSFX_I3DL2_MATERIAL_PRESET_STONEWALL, - DSFX_I3DL2_MATERIAL_PRESET_CURTAIN -}; - -#define I3DL2_MATERIAL_PRESET_SINGLEWINDOW -2800,0.71f -#define I3DL2_MATERIAL_PRESET_DOUBLEWINDOW -5000,0.40f -#define I3DL2_MATERIAL_PRESET_THINDOOR -1800,0.66f -#define I3DL2_MATERIAL_PRESET_THICKDOOR -4400,0.64f -#define I3DL2_MATERIAL_PRESET_WOODWALL -4000,0.50f -#define I3DL2_MATERIAL_PRESET_BRICKWALL -5000,0.60f -#define I3DL2_MATERIAL_PRESET_STONEWALL -6000,0.68f -#define I3DL2_MATERIAL_PRESET_CURTAIN -1200,0.15f - -enum -{ - DSFX_I3DL2_ENVIRONMENT_PRESET_DEFAULT, - DSFX_I3DL2_ENVIRONMENT_PRESET_GENERIC, - DSFX_I3DL2_ENVIRONMENT_PRESET_PADDEDCELL, - DSFX_I3DL2_ENVIRONMENT_PRESET_ROOM, - DSFX_I3DL2_ENVIRONMENT_PRESET_BATHROOM, - DSFX_I3DL2_ENVIRONMENT_PRESET_LIVINGROOM, - DSFX_I3DL2_ENVIRONMENT_PRESET_STONEROOM, - DSFX_I3DL2_ENVIRONMENT_PRESET_AUDITORIUM, - DSFX_I3DL2_ENVIRONMENT_PRESET_CONCERTHALL, - DSFX_I3DL2_ENVIRONMENT_PRESET_CAVE, - DSFX_I3DL2_ENVIRONMENT_PRESET_ARENA, - DSFX_I3DL2_ENVIRONMENT_PRESET_HANGAR, - DSFX_I3DL2_ENVIRONMENT_PRESET_CARPETEDHALLWAY, - DSFX_I3DL2_ENVIRONMENT_PRESET_HALLWAY, - DSFX_I3DL2_ENVIRONMENT_PRESET_STONECORRIDOR, - DSFX_I3DL2_ENVIRONMENT_PRESET_ALLEY, - DSFX_I3DL2_ENVIRONMENT_PRESET_FOREST, - DSFX_I3DL2_ENVIRONMENT_PRESET_CITY, - DSFX_I3DL2_ENVIRONMENT_PRESET_MOUNTAINS, - DSFX_I3DL2_ENVIRONMENT_PRESET_QUARRY, - DSFX_I3DL2_ENVIRONMENT_PRESET_PLAIN, - DSFX_I3DL2_ENVIRONMENT_PRESET_PARKINGLOT, - DSFX_I3DL2_ENVIRONMENT_PRESET_SEWERPIPE, - DSFX_I3DL2_ENVIRONMENT_PRESET_UNDERWATER, - DSFX_I3DL2_ENVIRONMENT_PRESET_SMALLROOM, - DSFX_I3DL2_ENVIRONMENT_PRESET_MEDIUMROOM, - DSFX_I3DL2_ENVIRONMENT_PRESET_LARGEROOM, - DSFX_I3DL2_ENVIRONMENT_PRESET_MEDIUMHALL, - DSFX_I3DL2_ENVIRONMENT_PRESET_LARGEHALL, - DSFX_I3DL2_ENVIRONMENT_PRESET_PLATE -}; - -// -// I3DL2 Reverberation Presets Values -// - -#define I3DL2_ENVIRONMENT_PRESET_DEFAULT -1000, -100, 0.0f, 1.49f, 0.83f, -2602, 0.007f, 200, 0.011f, 100.0f, 100.0f, 5000.0f -#define I3DL2_ENVIRONMENT_PRESET_GENERIC -1000, -100, 0.0f, 1.49f, 0.83f, -2602, 0.007f, 200, 0.011f, 100.0f, 100.0f, 5000.0f -#define I3DL2_ENVIRONMENT_PRESET_PADDEDCELL -1000,-6000, 0.0f, 0.17f, 0.10f, -1204, 0.001f, 207, 0.002f, 100.0f, 100.0f, 5000.0f -#define I3DL2_ENVIRONMENT_PRESET_ROOM -1000, -454, 0.0f, 0.40f, 0.83f, -1646, 0.002f, 53, 0.003f, 100.0f, 100.0f, 5000.0f -#define I3DL2_ENVIRONMENT_PRESET_BATHROOM -1000,-1200, 0.0f, 1.49f, 0.54f, -370, 0.007f, 1030, 0.011f, 100.0f, 60.0f, 5000.0f -#define I3DL2_ENVIRONMENT_PRESET_LIVINGROOM -1000,-6000, 0.0f, 0.50f, 0.10f, -1376, 0.003f, -1104, 0.004f, 100.0f, 100.0f, 5000.0f -#define I3DL2_ENVIRONMENT_PRESET_STONEROOM -1000, -300, 0.0f, 2.31f, 0.64f, -711, 0.012f, 83, 0.017f, 100.0f, 100.0f, 5000.0f -#define I3DL2_ENVIRONMENT_PRESET_AUDITORIUM -1000, -476, 0.0f, 4.32f, 0.59f, -789, 0.020f, -289, 0.030f, 100.0f, 100.0f, 5000.0f -#define I3DL2_ENVIRONMENT_PRESET_CONCERTHALL -1000, -500, 0.0f, 3.92f, 0.70f, -1230, 0.020f, -2, 0.029f, 100.0f, 100.0f, 5000.0f -#define I3DL2_ENVIRONMENT_PRESET_CAVE -1000, 0, 0.0f, 2.91f, 1.30f, -602, 0.015f, -302, 0.022f, 100.0f, 100.0f, 5000.0f -#define I3DL2_ENVIRONMENT_PRESET_ARENA -1000, -698, 0.0f, 7.24f, 0.33f, -1166, 0.020f, 16, 0.030f, 100.0f, 100.0f, 5000.0f -#define I3DL2_ENVIRONMENT_PRESET_HANGAR -1000,-1000, 0.0f,10.05f, 0.23f, -602, 0.020f, 198, 0.030f, 100.0f, 100.0f, 5000.0f -#define I3DL2_ENVIRONMENT_PRESET_CARPETEDHALLWAY -1000,-4000, 0.0f, 0.30f, 0.10f, -1831, 0.002f, -1630, 0.030f, 100.0f, 100.0f, 5000.0f -#define I3DL2_ENVIRONMENT_PRESET_HALLWAY -1000, -300, 0.0f, 1.49f, 0.59f, -1219, 0.007f, 441, 0.011f, 100.0f, 100.0f, 5000.0f -#define I3DL2_ENVIRONMENT_PRESET_STONECORRIDOR -1000, -237, 0.0f, 2.70f, 0.79f, -1214, 0.013f, 395, 0.020f, 100.0f, 100.0f, 5000.0f -#define I3DL2_ENVIRONMENT_PRESET_ALLEY -1000, -270, 0.0f, 1.49f, 0.86f, -1204, 0.007f, -4, 0.011f, 100.0f, 100.0f, 5000.0f -#define I3DL2_ENVIRONMENT_PRESET_FOREST -1000,-3300, 0.0f, 1.49f, 0.54f, -2560, 0.162f, -613, 0.088f, 79.0f, 100.0f, 5000.0f -#define I3DL2_ENVIRONMENT_PRESET_CITY -1000, -800, 0.0f, 1.49f, 0.67f, -2273, 0.007f, -2217, 0.011f, 50.0f, 100.0f, 5000.0f -#define I3DL2_ENVIRONMENT_PRESET_MOUNTAINS -1000,-2500, 0.0f, 1.49f, 0.21f, -2780, 0.300f, -2014, 0.100f, 27.0f, 100.0f, 5000.0f -#define I3DL2_ENVIRONMENT_PRESET_QUARRY -1000,-1000, 0.0f, 1.49f, 0.83f,-10000, 0.061f, 500, 0.025f, 100.0f, 100.0f, 5000.0f -#define I3DL2_ENVIRONMENT_PRESET_PLAIN -1000,-2000, 0.0f, 1.49f, 0.50f, -2466, 0.179f, -2514, 0.100f, 21.0f, 100.0f, 5000.0f -#define I3DL2_ENVIRONMENT_PRESET_PARKINGLOT -1000, 0, 0.0f, 1.65f, 1.50f, -1363, 0.008f, -1153, 0.012f, 100.0f, 100.0f, 5000.0f -#define I3DL2_ENVIRONMENT_PRESET_SEWERPIPE -1000,-1000, 0.0f, 2.81f, 0.14f, 429, 0.014f, 648, 0.021f, 80.0f, 60.0f, 5000.0f -#define I3DL2_ENVIRONMENT_PRESET_UNDERWATER -1000,-4000, 0.0f, 1.49f, 0.10f, -449, 0.007f, 1700, 0.011f, 100.0f, 100.0f, 5000.0f - -// -// Examples simulating 'musical' reverb presets -// -// Name Decay time Description -// Small Room 1.1s A small size room with a length of 5m or so. -// Medium Room 1.3s A medium size room with a length of 10m or so. -// Large Room 1.5s A large size room suitable for live performances. -// Medium Hall 1.8s A medium size concert hall. -// Large Hall 1.8s A large size concert hall suitable for a full orchestra. -// Plate 1.3s A plate reverb simulation. -// - -#define I3DL2_ENVIRONMENT_PRESET_SMALLROOM -1000, -600, 0.0f, 1.10f, 0.83f, -400, 0.005f, 500, 0.010f, 100.0f, 100.0f, 5000.0f -#define I3DL2_ENVIRONMENT_PRESET_MEDIUMROOM -1000, -600, 0.0f, 1.30f, 0.83f, -1000, 0.010f, -200, 0.020f, 100.0f, 100.0f, 5000.0f -#define I3DL2_ENVIRONMENT_PRESET_LARGEROOM -1000, -600, 0.0f, 1.50f, 0.83f, -1600, 0.020f, -1000, 0.040f, 100.0f, 100.0f, 5000.0f -#define I3DL2_ENVIRONMENT_PRESET_MEDIUMHALL -1000, -600, 0.0f, 1.80f, 0.70f, -1300, 0.015f, -800, 0.030f, 100.0f, 100.0f, 5000.0f -#define I3DL2_ENVIRONMENT_PRESET_LARGEHALL -1000, -600, 0.0f, 1.80f, 0.70f, -2000, 0.030f, -1400, 0.060f, 100.0f, 100.0f, 5000.0f -#define I3DL2_ENVIRONMENT_PRESET_PLATE -1000, -200, 0.0f, 1.30f, 0.90f, 0, 0.002f, 0, 0.010f, 100.0f, 75.0f, 5000.0f - -// -// DirectSound3D Algorithms -// - -// Default DirectSound3D algorithm {00000000-0000-0000-0000-000000000000} -#define DS3DALG_DEFAULT GUID_NULL - -// No virtualization (Pan3D) {C241333F-1C1B-11d2-94F5-00C04FC28ACA} -DEFINE_GUID(DS3DALG_NO_VIRTUALIZATION, 0xc241333f, 0x1c1b, 0x11d2, 0x94, 0xf5, 0x0, 0xc0, 0x4f, 0xc2, 0x8a, 0xca); - -// High-quality HRTF algorithm {C2413340-1C1B-11d2-94F5-00C04FC28ACA} -DEFINE_GUID(DS3DALG_HRTF_FULL, 0xc2413340, 0x1c1b, 0x11d2, 0x94, 0xf5, 0x0, 0xc0, 0x4f, 0xc2, 0x8a, 0xca); - -// Lower-quality HRTF algorithm {C2413342-1C1B-11d2-94F5-00C04FC28ACA} -DEFINE_GUID(DS3DALG_HRTF_LIGHT, 0xc2413342, 0x1c1b, 0x11d2, 0x94, 0xf5, 0x0, 0xc0, 0x4f, 0xc2, 0x8a, 0xca); - - -#if DIRECTSOUND_VERSION >= 0x0800 - -// -// DirectSound Internal Effect Algorithms -// - - -// Gargle {DAFD8210-5711-4B91-9FE3-F75B7AE279BF} -DEFINE_GUID(GUID_DSFX_STANDARD_GARGLE, 0xdafd8210, 0x5711, 0x4b91, 0x9f, 0xe3, 0xf7, 0x5b, 0x7a, 0xe2, 0x79, 0xbf); - -// Chorus {EFE6629C-81F7-4281-BD91-C9D604A95AF6} -DEFINE_GUID(GUID_DSFX_STANDARD_CHORUS, 0xefe6629c, 0x81f7, 0x4281, 0xbd, 0x91, 0xc9, 0xd6, 0x04, 0xa9, 0x5a, 0xf6); - -// Flanger {EFCA3D92-DFD8-4672-A603-7420894BAD98} -DEFINE_GUID(GUID_DSFX_STANDARD_FLANGER, 0xefca3d92, 0xdfd8, 0x4672, 0xa6, 0x03, 0x74, 0x20, 0x89, 0x4b, 0xad, 0x98); - -// Echo/Delay {EF3E932C-D40B-4F51-8CCF-3F98F1B29D5D} -DEFINE_GUID(GUID_DSFX_STANDARD_ECHO, 0xef3e932c, 0xd40b, 0x4f51, 0x8c, 0xcf, 0x3f, 0x98, 0xf1, 0xb2, 0x9d, 0x5d); - -// Distortion {EF114C90-CD1D-484E-96E5-09CFAF912A21} -DEFINE_GUID(GUID_DSFX_STANDARD_DISTORTION, 0xef114c90, 0xcd1d, 0x484e, 0x96, 0xe5, 0x09, 0xcf, 0xaf, 0x91, 0x2a, 0x21); - -// Compressor/Limiter {EF011F79-4000-406D-87AF-BFFB3FC39D57} -DEFINE_GUID(GUID_DSFX_STANDARD_COMPRESSOR, 0xef011f79, 0x4000, 0x406d, 0x87, 0xaf, 0xbf, 0xfb, 0x3f, 0xc3, 0x9d, 0x57); - -// Parametric Equalization {120CED89-3BF4-4173-A132-3CB406CF3231} -DEFINE_GUID(GUID_DSFX_STANDARD_PARAMEQ, 0x120ced89, 0x3bf4, 0x4173, 0xa1, 0x32, 0x3c, 0xb4, 0x06, 0xcf, 0x32, 0x31); - -// I3DL2 Environmental Reverberation: Reverb (Listener) Effect {EF985E71-D5C7-42D4-BA4D-2D073E2E96F4} -DEFINE_GUID(GUID_DSFX_STANDARD_I3DL2REVERB, 0xef985e71, 0xd5c7, 0x42d4, 0xba, 0x4d, 0x2d, 0x07, 0x3e, 0x2e, 0x96, 0xf4); - -// Waves Reverberation {87FC0268-9A55-4360-95AA-004A1D9DE26C} -DEFINE_GUID(GUID_DSFX_WAVES_REVERB, 0x87fc0268, 0x9a55, 0x4360, 0x95, 0xaa, 0x00, 0x4a, 0x1d, 0x9d, 0xe2, 0x6c); - -// -// DirectSound Capture Effect Algorithms -// - - -// Acoustic Echo Canceller {BF963D80-C559-11D0-8A2B-00A0C9255AC1} -// Matches KSNODETYPE_ACOUSTIC_ECHO_CANCEL in ksmedia.h -DEFINE_GUID(GUID_DSCFX_CLASS_AEC, 0xBF963D80L, 0xC559, 0x11D0, 0x8A, 0x2B, 0x00, 0xA0, 0xC9, 0x25, 0x5A, 0xC1); - -// Microsoft AEC {CDEBB919-379A-488a-8765-F53CFD36DE40} -DEFINE_GUID(GUID_DSCFX_MS_AEC, 0xcdebb919, 0x379a, 0x488a, 0x87, 0x65, 0xf5, 0x3c, 0xfd, 0x36, 0xde, 0x40); - -// System AEC {1C22C56D-9879-4f5b-A389-27996DDC2810} -DEFINE_GUID(GUID_DSCFX_SYSTEM_AEC, 0x1c22c56d, 0x9879, 0x4f5b, 0xa3, 0x89, 0x27, 0x99, 0x6d, 0xdc, 0x28, 0x10); - -// Noise Supression {E07F903F-62FD-4e60-8CDD-DEA7236665B5} -// Matches KSNODETYPE_NOISE_SUPPRESS in post Windows ME DDK's ksmedia.h -DEFINE_GUID(GUID_DSCFX_CLASS_NS, 0xe07f903f, 0x62fd, 0x4e60, 0x8c, 0xdd, 0xde, 0xa7, 0x23, 0x66, 0x65, 0xb5); - -// Microsoft Noise Suppresion {11C5C73B-66E9-4ba1-A0BA-E814C6EED92D} -DEFINE_GUID(GUID_DSCFX_MS_NS, 0x11c5c73b, 0x66e9, 0x4ba1, 0xa0, 0xba, 0xe8, 0x14, 0xc6, 0xee, 0xd9, 0x2d); - -// System Noise Suppresion {5AB0882E-7274-4516-877D-4EEE99BA4FD0} -DEFINE_GUID(GUID_DSCFX_SYSTEM_NS, 0x5ab0882e, 0x7274, 0x4516, 0x87, 0x7d, 0x4e, 0xee, 0x99, 0xba, 0x4f, 0xd0); - -#endif // DIRECTSOUND_VERSION >= 0x0800 - -#endif // __DSOUND_INCLUDED__ - - - -#ifdef __cplusplus -}; -#endif // __cplusplus - - +/*==========================================================================; + * + * Copyright (c) Microsoft Corporation. All rights reserved. + * + * File: dsound.h + * Content: DirectSound include file + * + **************************************************************************/ + +#define COM_NO_WINDOWS_H +#include +#include + +#ifndef DIRECTSOUND_VERSION +#define DIRECTSOUND_VERSION 0x0900 /* Version 9.0 */ +#endif + +#ifdef __cplusplus +extern "C" { +#endif // __cplusplus + +#ifndef __DSOUND_INCLUDED__ +#define __DSOUND_INCLUDED__ + +/* Type definitions shared with Direct3D */ + +#ifndef DX_SHARED_DEFINES + +typedef float D3DVALUE, *LPD3DVALUE; + +#ifndef D3DCOLOR_DEFINED +typedef DWORD D3DCOLOR; +#define D3DCOLOR_DEFINED +#endif + +#ifndef LPD3DCOLOR_DEFINED +typedef DWORD *LPD3DCOLOR; +#define LPD3DCOLOR_DEFINED +#endif + +#ifndef D3DVECTOR_DEFINED +typedef struct _D3DVECTOR { + float x; + float y; + float z; +} D3DVECTOR; +#define D3DVECTOR_DEFINED +#endif + +#ifndef LPD3DVECTOR_DEFINED +typedef D3DVECTOR *LPD3DVECTOR; +#define LPD3DVECTOR_DEFINED +#endif + +#define DX_SHARED_DEFINES +#endif // DX_SHARED_DEFINES + +#define _FACDS 0x878 /* DirectSound's facility code */ +#define MAKE_DSHRESULT(code) MAKE_HRESULT(1, _FACDS, code) + +// DirectSound Component GUID {47D4D946-62E8-11CF-93BC-444553540000} +DEFINE_GUID(CLSID_DirectSound, 0x47d4d946, 0x62e8, 0x11cf, 0x93, 0xbc, 0x44, 0x45, 0x53, 0x54, 0x0, 0x0); + +// DirectSound 8.0 Component GUID {3901CC3F-84B5-4FA4-BA35-AA8172B8A09B} +DEFINE_GUID(CLSID_DirectSound8, 0x3901cc3f, 0x84b5, 0x4fa4, 0xba, 0x35, 0xaa, 0x81, 0x72, 0xb8, 0xa0, 0x9b); + +// DirectSound Capture Component GUID {B0210780-89CD-11D0-AF08-00A0C925CD16} +DEFINE_GUID(CLSID_DirectSoundCapture, 0xb0210780, 0x89cd, 0x11d0, 0xaf, 0x8, 0x0, 0xa0, 0xc9, 0x25, 0xcd, 0x16); + +// DirectSound 8.0 Capture Component GUID {E4BCAC13-7F99-4908-9A8E-74E3BF24B6E1} +DEFINE_GUID(CLSID_DirectSoundCapture8, 0xe4bcac13, 0x7f99, 0x4908, 0x9a, 0x8e, 0x74, 0xe3, 0xbf, 0x24, 0xb6, 0xe1); + +// DirectSound Full Duplex Component GUID {FEA4300C-7959-4147-B26A-2377B9E7A91D} +DEFINE_GUID(CLSID_DirectSoundFullDuplex, 0xfea4300c, 0x7959, 0x4147, 0xb2, 0x6a, 0x23, 0x77, 0xb9, 0xe7, 0xa9, 0x1d); + + +// DirectSound default playback device GUID {DEF00000-9C6D-47ED-AAF1-4DDA8F2B5C03} +DEFINE_GUID(DSDEVID_DefaultPlayback, 0xdef00000, 0x9c6d, 0x47ed, 0xaa, 0xf1, 0x4d, 0xda, 0x8f, 0x2b, 0x5c, 0x03); + +// DirectSound default capture device GUID {DEF00001-9C6D-47ED-AAF1-4DDA8F2B5C03} +DEFINE_GUID(DSDEVID_DefaultCapture, 0xdef00001, 0x9c6d, 0x47ed, 0xaa, 0xf1, 0x4d, 0xda, 0x8f, 0x2b, 0x5c, 0x03); + +// DirectSound default device for voice playback {DEF00002-9C6D-47ED-AAF1-4DDA8F2B5C03} +DEFINE_GUID(DSDEVID_DefaultVoicePlayback, 0xdef00002, 0x9c6d, 0x47ed, 0xaa, 0xf1, 0x4d, 0xda, 0x8f, 0x2b, 0x5c, 0x03); + +// DirectSound default device for voice capture {DEF00003-9C6D-47ED-AAF1-4DDA8F2B5C03} +DEFINE_GUID(DSDEVID_DefaultVoiceCapture, 0xdef00003, 0x9c6d, 0x47ed, 0xaa, 0xf1, 0x4d, 0xda, 0x8f, 0x2b, 0x5c, 0x03); + + +// +// Forward declarations for interfaces. +// 'struct' not 'class' per the way DECLARE_INTERFACE_ is defined +// + +#ifdef __cplusplus +struct IDirectSound; +struct IDirectSoundBuffer; +struct IDirectSound3DListener; +struct IDirectSound3DBuffer; +struct IDirectSoundCapture; +struct IDirectSoundCaptureBuffer; +struct IDirectSoundNotify; +#endif // __cplusplus + + +// +// DirectSound 8.0 interfaces. +// + +#if DIRECTSOUND_VERSION >= 0x0800 + +#ifdef __cplusplus +struct IDirectSound8; +struct IDirectSoundBuffer8; +struct IDirectSoundCaptureBuffer8; +struct IDirectSoundFXGargle; +struct IDirectSoundFXChorus; +struct IDirectSoundFXFlanger; +struct IDirectSoundFXEcho; +struct IDirectSoundFXDistortion; +struct IDirectSoundFXCompressor; +struct IDirectSoundFXParamEq; +struct IDirectSoundFXWavesReverb; +struct IDirectSoundFXI3DL2Reverb; +struct IDirectSoundCaptureFXAec; +struct IDirectSoundCaptureFXNoiseSuppress; +struct IDirectSoundFullDuplex; +#endif // __cplusplus + +// IDirectSound8, IDirectSoundBuffer8 and IDirectSoundCaptureBuffer8 are the +// only DirectSound 7.0 interfaces with changed functionality in version 8.0. +// The other level 8 interfaces as equivalent to their level 7 counterparts: + +#define IDirectSoundCapture8 IDirectSoundCapture +#define IDirectSound3DListener8 IDirectSound3DListener +#define IDirectSound3DBuffer8 IDirectSound3DBuffer +#define IDirectSoundNotify8 IDirectSoundNotify +#define IDirectSoundFXGargle8 IDirectSoundFXGargle +#define IDirectSoundFXChorus8 IDirectSoundFXChorus +#define IDirectSoundFXFlanger8 IDirectSoundFXFlanger +#define IDirectSoundFXEcho8 IDirectSoundFXEcho +#define IDirectSoundFXDistortion8 IDirectSoundFXDistortion +#define IDirectSoundFXCompressor8 IDirectSoundFXCompressor +#define IDirectSoundFXParamEq8 IDirectSoundFXParamEq +#define IDirectSoundFXWavesReverb8 IDirectSoundFXWavesReverb +#define IDirectSoundFXI3DL2Reverb8 IDirectSoundFXI3DL2Reverb +#define IDirectSoundCaptureFXAec8 IDirectSoundCaptureFXAec +#define IDirectSoundCaptureFXNoiseSuppress8 IDirectSoundCaptureFXNoiseSuppress +#define IDirectSoundFullDuplex8 IDirectSoundFullDuplex + +#endif // DIRECTSOUND_VERSION >= 0x0800 + +typedef struct IDirectSound *LPDIRECTSOUND; +typedef struct IDirectSoundBuffer *LPDIRECTSOUNDBUFFER; +typedef struct IDirectSound3DListener *LPDIRECTSOUND3DLISTENER; +typedef struct IDirectSound3DBuffer *LPDIRECTSOUND3DBUFFER; +typedef struct IDirectSoundCapture *LPDIRECTSOUNDCAPTURE; +typedef struct IDirectSoundCaptureBuffer *LPDIRECTSOUNDCAPTUREBUFFER; +typedef struct IDirectSoundNotify *LPDIRECTSOUNDNOTIFY; + + +#if DIRECTSOUND_VERSION >= 0x0800 + +typedef struct IDirectSoundFXGargle *LPDIRECTSOUNDFXGARGLE; +typedef struct IDirectSoundFXChorus *LPDIRECTSOUNDFXCHORUS; +typedef struct IDirectSoundFXFlanger *LPDIRECTSOUNDFXFLANGER; +typedef struct IDirectSoundFXEcho *LPDIRECTSOUNDFXECHO; +typedef struct IDirectSoundFXDistortion *LPDIRECTSOUNDFXDISTORTION; +typedef struct IDirectSoundFXCompressor *LPDIRECTSOUNDFXCOMPRESSOR; +typedef struct IDirectSoundFXParamEq *LPDIRECTSOUNDFXPARAMEQ; +typedef struct IDirectSoundFXWavesReverb *LPDIRECTSOUNDFXWAVESREVERB; +typedef struct IDirectSoundFXI3DL2Reverb *LPDIRECTSOUNDFXI3DL2REVERB; +typedef struct IDirectSoundCaptureFXAec *LPDIRECTSOUNDCAPTUREFXAEC; +typedef struct IDirectSoundCaptureFXNoiseSuppress *LPDIRECTSOUNDCAPTUREFXNOISESUPPRESS; +typedef struct IDirectSoundFullDuplex *LPDIRECTSOUNDFULLDUPLEX; + +typedef struct IDirectSound8 *LPDIRECTSOUND8; +typedef struct IDirectSoundBuffer8 *LPDIRECTSOUNDBUFFER8; +typedef struct IDirectSound3DListener8 *LPDIRECTSOUND3DLISTENER8; +typedef struct IDirectSound3DBuffer8 *LPDIRECTSOUND3DBUFFER8; +typedef struct IDirectSoundCapture8 *LPDIRECTSOUNDCAPTURE8; +typedef struct IDirectSoundCaptureBuffer8 *LPDIRECTSOUNDCAPTUREBUFFER8; +typedef struct IDirectSoundNotify8 *LPDIRECTSOUNDNOTIFY8; +typedef struct IDirectSoundFXGargle8 *LPDIRECTSOUNDFXGARGLE8; +typedef struct IDirectSoundFXChorus8 *LPDIRECTSOUNDFXCHORUS8; +typedef struct IDirectSoundFXFlanger8 *LPDIRECTSOUNDFXFLANGER8; +typedef struct IDirectSoundFXEcho8 *LPDIRECTSOUNDFXECHO8; +typedef struct IDirectSoundFXDistortion8 *LPDIRECTSOUNDFXDISTORTION8; +typedef struct IDirectSoundFXCompressor8 *LPDIRECTSOUNDFXCOMPRESSOR8; +typedef struct IDirectSoundFXParamEq8 *LPDIRECTSOUNDFXPARAMEQ8; +typedef struct IDirectSoundFXWavesReverb8 *LPDIRECTSOUNDFXWAVESREVERB8; +typedef struct IDirectSoundFXI3DL2Reverb8 *LPDIRECTSOUNDFXI3DL2REVERB8; +typedef struct IDirectSoundCaptureFXAec8 *LPDIRECTSOUNDCAPTUREFXAEC8; +typedef struct IDirectSoundCaptureFXNoiseSuppress8 *LPDIRECTSOUNDCAPTUREFXNOISESUPPRESS8; +typedef struct IDirectSoundFullDuplex8 *LPDIRECTSOUNDFULLDUPLEX8; + +#endif // DIRECTSOUND_VERSION >= 0x0800 + +// +// IID definitions for the unchanged DirectSound 8.0 interfaces +// + +#if DIRECTSOUND_VERSION >= 0x0800 + +#define IID_IDirectSoundCapture8 IID_IDirectSoundCapture +#define IID_IDirectSound3DListener8 IID_IDirectSound3DListener +#define IID_IDirectSound3DBuffer8 IID_IDirectSound3DBuffer +#define IID_IDirectSoundNotify8 IID_IDirectSoundNotify +#define IID_IDirectSoundFXGargle8 IID_IDirectSoundFXGargle +#define IID_IDirectSoundFXChorus8 IID_IDirectSoundFXChorus +#define IID_IDirectSoundFXFlanger8 IID_IDirectSoundFXFlanger +#define IID_IDirectSoundFXEcho8 IID_IDirectSoundFXEcho +#define IID_IDirectSoundFXDistortion8 IID_IDirectSoundFXDistortion +#define IID_IDirectSoundFXCompressor8 IID_IDirectSoundFXCompressor +#define IID_IDirectSoundFXParamEq8 IID_IDirectSoundFXParamEq +#define IID_IDirectSoundFXWavesReverb8 IID_IDirectSoundFXWavesReverb +#define IID_IDirectSoundFXI3DL2Reverb8 IID_IDirectSoundFXI3DL2Reverb +#define IID_IDirectSoundCaptureFXAec8 IID_IDirectSoundCaptureFXAec +#define IID_IDirectSoundCaptureFXNoiseSuppress8 IID_IDirectSoundCaptureFXNoiseSuppress +#define IID_IDirectSoundFullDuplex8 IID_IDirectSoundFullDuplex + +#endif // DIRECTSOUND_VERSION >= 0x0800 + +// +// Compatibility typedefs +// + +#ifndef _LPCWAVEFORMATEX_DEFINED +#define _LPCWAVEFORMATEX_DEFINED +typedef const WAVEFORMATEX *LPCWAVEFORMATEX; +#endif // _LPCWAVEFORMATEX_DEFINED + +#ifndef __LPCGUID_DEFINED__ +#define __LPCGUID_DEFINED__ +typedef const GUID *LPCGUID; +#endif // __LPCGUID_DEFINED__ + +typedef LPDIRECTSOUND *LPLPDIRECTSOUND; +typedef LPDIRECTSOUNDBUFFER *LPLPDIRECTSOUNDBUFFER; +typedef LPDIRECTSOUND3DLISTENER *LPLPDIRECTSOUND3DLISTENER; +typedef LPDIRECTSOUND3DBUFFER *LPLPDIRECTSOUND3DBUFFER; +typedef LPDIRECTSOUNDCAPTURE *LPLPDIRECTSOUNDCAPTURE; +typedef LPDIRECTSOUNDCAPTUREBUFFER *LPLPDIRECTSOUNDCAPTUREBUFFER; +typedef LPDIRECTSOUNDNOTIFY *LPLPDIRECTSOUNDNOTIFY; + +#if DIRECTSOUND_VERSION >= 0x0800 +typedef LPDIRECTSOUND8 *LPLPDIRECTSOUND8; +typedef LPDIRECTSOUNDBUFFER8 *LPLPDIRECTSOUNDBUFFER8; +typedef LPDIRECTSOUNDCAPTURE8 *LPLPDIRECTSOUNDCAPTURE8; +typedef LPDIRECTSOUNDCAPTUREBUFFER8 *LPLPDIRECTSOUNDCAPTUREBUFFER8; +#endif // DIRECTSOUND_VERSION >= 0x0800 + +// +// Structures +// + +typedef struct _DSCAPS +{ + DWORD dwSize; + DWORD dwFlags; + DWORD dwMinSecondarySampleRate; + DWORD dwMaxSecondarySampleRate; + DWORD dwPrimaryBuffers; + DWORD dwMaxHwMixingAllBuffers; + DWORD dwMaxHwMixingStaticBuffers; + DWORD dwMaxHwMixingStreamingBuffers; + DWORD dwFreeHwMixingAllBuffers; + DWORD dwFreeHwMixingStaticBuffers; + DWORD dwFreeHwMixingStreamingBuffers; + DWORD dwMaxHw3DAllBuffers; + DWORD dwMaxHw3DStaticBuffers; + DWORD dwMaxHw3DStreamingBuffers; + DWORD dwFreeHw3DAllBuffers; + DWORD dwFreeHw3DStaticBuffers; + DWORD dwFreeHw3DStreamingBuffers; + DWORD dwTotalHwMemBytes; + DWORD dwFreeHwMemBytes; + DWORD dwMaxContigFreeHwMemBytes; + DWORD dwUnlockTransferRateHwBuffers; + DWORD dwPlayCpuOverheadSwBuffers; + DWORD dwReserved1; + DWORD dwReserved2; +} DSCAPS, *LPDSCAPS; + +typedef const DSCAPS *LPCDSCAPS; + +typedef struct _DSBCAPS +{ + DWORD dwSize; + DWORD dwFlags; + DWORD dwBufferBytes; + DWORD dwUnlockTransferRate; + DWORD dwPlayCpuOverhead; +} DSBCAPS, *LPDSBCAPS; + +typedef const DSBCAPS *LPCDSBCAPS; + +#if DIRECTSOUND_VERSION >= 0x0800 + + typedef struct _DSEFFECTDESC + { + DWORD dwSize; + DWORD dwFlags; + GUID guidDSFXClass; + DWORD_PTR dwReserved1; + DWORD_PTR dwReserved2; + } DSEFFECTDESC, *LPDSEFFECTDESC; + typedef const DSEFFECTDESC *LPCDSEFFECTDESC; + + #define DSFX_LOCHARDWARE 0x00000001 + #define DSFX_LOCSOFTWARE 0x00000002 + + enum + { + DSFXR_PRESENT, // 0 + DSFXR_LOCHARDWARE, // 1 + DSFXR_LOCSOFTWARE, // 2 + DSFXR_UNALLOCATED, // 3 + DSFXR_FAILED, // 4 + DSFXR_UNKNOWN, // 5 + DSFXR_SENDLOOP // 6 + }; + + typedef struct _DSCEFFECTDESC + { + DWORD dwSize; + DWORD dwFlags; + GUID guidDSCFXClass; + GUID guidDSCFXInstance; + DWORD dwReserved1; + DWORD dwReserved2; + } DSCEFFECTDESC, *LPDSCEFFECTDESC; + typedef const DSCEFFECTDESC *LPCDSCEFFECTDESC; + + #define DSCFX_LOCHARDWARE 0x00000001 + #define DSCFX_LOCSOFTWARE 0x00000002 + + #define DSCFXR_LOCHARDWARE 0x00000010 + #define DSCFXR_LOCSOFTWARE 0x00000020 + +#endif // DIRECTSOUND_VERSION >= 0x0800 + +typedef struct _DSBUFFERDESC +{ + DWORD dwSize; + DWORD dwFlags; + DWORD dwBufferBytes; + DWORD dwReserved; + LPWAVEFORMATEX lpwfxFormat; +#if DIRECTSOUND_VERSION >= 0x0700 + GUID guid3DAlgorithm; +#endif +} DSBUFFERDESC, *LPDSBUFFERDESC; + +typedef const DSBUFFERDESC *LPCDSBUFFERDESC; + +// Older version of this structure: + +typedef struct _DSBUFFERDESC1 +{ + DWORD dwSize; + DWORD dwFlags; + DWORD dwBufferBytes; + DWORD dwReserved; + LPWAVEFORMATEX lpwfxFormat; +} DSBUFFERDESC1, *LPDSBUFFERDESC1; + +typedef const DSBUFFERDESC1 *LPCDSBUFFERDESC1; + +typedef struct _DS3DBUFFER +{ + DWORD dwSize; + D3DVECTOR vPosition; + D3DVECTOR vVelocity; + DWORD dwInsideConeAngle; + DWORD dwOutsideConeAngle; + D3DVECTOR vConeOrientation; + LONG lConeOutsideVolume; + D3DVALUE flMinDistance; + D3DVALUE flMaxDistance; + DWORD dwMode; +} DS3DBUFFER, *LPDS3DBUFFER; + +typedef const DS3DBUFFER *LPCDS3DBUFFER; + +typedef struct _DS3DLISTENER +{ + DWORD dwSize; + D3DVECTOR vPosition; + D3DVECTOR vVelocity; + D3DVECTOR vOrientFront; + D3DVECTOR vOrientTop; + D3DVALUE flDistanceFactor; + D3DVALUE flRolloffFactor; + D3DVALUE flDopplerFactor; +} DS3DLISTENER, *LPDS3DLISTENER; + +typedef const DS3DLISTENER *LPCDS3DLISTENER; + +typedef struct _DSCCAPS +{ + DWORD dwSize; + DWORD dwFlags; + DWORD dwFormats; + DWORD dwChannels; +} DSCCAPS, *LPDSCCAPS; + +typedef const DSCCAPS *LPCDSCCAPS; + +typedef struct _DSCBUFFERDESC1 +{ + DWORD dwSize; + DWORD dwFlags; + DWORD dwBufferBytes; + DWORD dwReserved; + LPWAVEFORMATEX lpwfxFormat; +} DSCBUFFERDESC1, *LPDSCBUFFERDESC1; + +typedef struct _DSCBUFFERDESC +{ + DWORD dwSize; + DWORD dwFlags; + DWORD dwBufferBytes; + DWORD dwReserved; + LPWAVEFORMATEX lpwfxFormat; +#if DIRECTSOUND_VERSION >= 0x0800 + DWORD dwFXCount; + LPDSCEFFECTDESC lpDSCFXDesc; +#endif +} DSCBUFFERDESC, *LPDSCBUFFERDESC; + +typedef const DSCBUFFERDESC *LPCDSCBUFFERDESC; + +typedef struct _DSCBCAPS +{ + DWORD dwSize; + DWORD dwFlags; + DWORD dwBufferBytes; + DWORD dwReserved; +} DSCBCAPS, *LPDSCBCAPS; + +typedef const DSCBCAPS *LPCDSCBCAPS; + +typedef struct _DSBPOSITIONNOTIFY +{ + DWORD dwOffset; + HANDLE hEventNotify; +} DSBPOSITIONNOTIFY, *LPDSBPOSITIONNOTIFY; + +typedef const DSBPOSITIONNOTIFY *LPCDSBPOSITIONNOTIFY; + +// +// DirectSound API +// + +typedef BOOL (CALLBACK *LPDSENUMCALLBACKA)(LPGUID, LPCSTR, LPCSTR, LPVOID); +typedef BOOL (CALLBACK *LPDSENUMCALLBACKW)(LPGUID, LPCWSTR, LPCWSTR, LPVOID); + +extern HRESULT WINAPI DirectSoundCreate(LPCGUID pcGuidDevice, LPDIRECTSOUND *ppDS, LPUNKNOWN pUnkOuter); +extern HRESULT WINAPI DirectSoundEnumerateA(LPDSENUMCALLBACKA pDSEnumCallback, LPVOID pContext); +extern HRESULT WINAPI DirectSoundEnumerateW(LPDSENUMCALLBACKW pDSEnumCallback, LPVOID pContext); + +extern HRESULT WINAPI DirectSoundCaptureCreate(LPCGUID pcGuidDevice, LPDIRECTSOUNDCAPTURE *ppDSC, LPUNKNOWN pUnkOuter); +extern HRESULT WINAPI DirectSoundCaptureEnumerateA(LPDSENUMCALLBACKA pDSEnumCallback, LPVOID pContext); +extern HRESULT WINAPI DirectSoundCaptureEnumerateW(LPDSENUMCALLBACKW pDSEnumCallback, LPVOID pContext); + +#if DIRECTSOUND_VERSION >= 0x0800 +extern HRESULT WINAPI DirectSoundCreate8(LPCGUID pcGuidDevice, LPDIRECTSOUND8 *ppDS8, LPUNKNOWN pUnkOuter); +extern HRESULT WINAPI DirectSoundCaptureCreate8(LPCGUID pcGuidDevice, LPDIRECTSOUNDCAPTURE8 *ppDSC8, LPUNKNOWN pUnkOuter); +extern HRESULT WINAPI DirectSoundFullDuplexCreate(LPCGUID pcGuidCaptureDevice, LPCGUID pcGuidRenderDevice, + LPCDSCBUFFERDESC pcDSCBufferDesc, LPCDSBUFFERDESC pcDSBufferDesc, HWND hWnd, + DWORD dwLevel, LPDIRECTSOUNDFULLDUPLEX* ppDSFD, LPDIRECTSOUNDCAPTUREBUFFER8 *ppDSCBuffer8, + LPDIRECTSOUNDBUFFER8 *ppDSBuffer8, LPUNKNOWN pUnkOuter); +#define DirectSoundFullDuplexCreate8 DirectSoundFullDuplexCreate + +extern HRESULT WINAPI GetDeviceID(LPCGUID pGuidSrc, LPGUID pGuidDest); +#endif // DIRECTSOUND_VERSION >= 0x0800 + +#ifdef UNICODE +#define LPDSENUMCALLBACK LPDSENUMCALLBACKW +#define DirectSoundEnumerate DirectSoundEnumerateW +#define DirectSoundCaptureEnumerate DirectSoundCaptureEnumerateW +#else // UNICODE +#define LPDSENUMCALLBACK LPDSENUMCALLBACKA +#define DirectSoundEnumerate DirectSoundEnumerateA +#define DirectSoundCaptureEnumerate DirectSoundCaptureEnumerateA +#endif // UNICODE + +// +// IUnknown +// + +#if !defined(__cplusplus) || defined(CINTERFACE) +#ifndef IUnknown_QueryInterface +#define IUnknown_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) +#endif // IUnknown_QueryInterface +#ifndef IUnknown_AddRef +#define IUnknown_AddRef(p) (p)->lpVtbl->AddRef(p) +#endif // IUnknown_AddRef +#ifndef IUnknown_Release +#define IUnknown_Release(p) (p)->lpVtbl->Release(p) +#endif // IUnknown_Release +#else // !defined(__cplusplus) || defined(CINTERFACE) +#ifndef IUnknown_QueryInterface +#define IUnknown_QueryInterface(p,a,b) (p)->QueryInterface(a,b) +#endif // IUnknown_QueryInterface +#ifndef IUnknown_AddRef +#define IUnknown_AddRef(p) (p)->AddRef() +#endif // IUnknown_AddRef +#ifndef IUnknown_Release +#define IUnknown_Release(p) (p)->Release() +#endif // IUnknown_Release +#endif // !defined(__cplusplus) || defined(CINTERFACE) + +#ifndef __IReferenceClock_INTERFACE_DEFINED__ +#define __IReferenceClock_INTERFACE_DEFINED__ + +typedef LONGLONG REFERENCE_TIME; +typedef REFERENCE_TIME *LPREFERENCE_TIME; + +DEFINE_GUID(IID_IReferenceClock, 0x56a86897, 0x0ad4, 0x11ce, 0xb0, 0x3a, 0x00, 0x20, 0xaf, 0x0b, 0xa7, 0x70); + +#undef INTERFACE +#define INTERFACE IReferenceClock + +DECLARE_INTERFACE_(IReferenceClock, IUnknown) +{ + // IUnknown methods + STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE; + STDMETHOD_(ULONG,AddRef) (THIS) PURE; + STDMETHOD_(ULONG,Release) (THIS) PURE; + + // IReferenceClock methods + STDMETHOD(GetTime) (THIS_ REFERENCE_TIME *pTime) PURE; + STDMETHOD(AdviseTime) (THIS_ REFERENCE_TIME rtBaseTime, REFERENCE_TIME rtStreamTime, + HANDLE hEvent, LPDWORD pdwAdviseCookie) PURE; + STDMETHOD(AdvisePeriodic) (THIS_ REFERENCE_TIME rtStartTime, REFERENCE_TIME rtPeriodTime, + HANDLE hSemaphore, LPDWORD pdwAdviseCookie) PURE; + STDMETHOD(Unadvise) (THIS_ DWORD dwAdviseCookie) PURE; +}; + +#endif // __IReferenceClock_INTERFACE_DEFINED__ + +#ifndef IReferenceClock_QueryInterface + +#define IReferenceClock_QueryInterface(p,a,b) IUnknown_QueryInterface(p,a,b) +#define IReferenceClock_AddRef(p) IUnknown_AddRef(p) +#define IReferenceClock_Release(p) IUnknown_Release(p) + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IReferenceClock_GetTime(p,a) (p)->lpVtbl->GetTime(p,a) +#define IReferenceClock_AdviseTime(p,a,b,c,d) (p)->lpVtbl->AdviseTime(p,a,b,c,d) +#define IReferenceClock_AdvisePeriodic(p,a,b,c,d) (p)->lpVtbl->AdvisePeriodic(p,a,b,c,d) +#define IReferenceClock_Unadvise(p,a) (p)->lpVtbl->Unadvise(p,a) +#else // !defined(__cplusplus) || defined(CINTERFACE) +#define IReferenceClock_GetTime(p,a) (p)->GetTime(a) +#define IReferenceClock_AdviseTime(p,a,b,c,d) (p)->AdviseTime(a,b,c,d) +#define IReferenceClock_AdvisePeriodic(p,a,b,c,d) (p)->AdvisePeriodic(a,b,c,d) +#define IReferenceClock_Unadvise(p,a) (p)->Unadvise(a) +#endif // !defined(__cplusplus) || defined(CINTERFACE) + +#endif // IReferenceClock_QueryInterface + +// +// IDirectSound +// + +DEFINE_GUID(IID_IDirectSound, 0x279AFA83, 0x4981, 0x11CE, 0xA5, 0x21, 0x00, 0x20, 0xAF, 0x0B, 0xE5, 0x60); + +#undef INTERFACE +#define INTERFACE IDirectSound + +DECLARE_INTERFACE_(IDirectSound, IUnknown) +{ + // IUnknown methods + STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE; + STDMETHOD_(ULONG,AddRef) (THIS) PURE; + STDMETHOD_(ULONG,Release) (THIS) PURE; + + // IDirectSound methods + STDMETHOD(CreateSoundBuffer) (THIS_ LPCDSBUFFERDESC pcDSBufferDesc, LPDIRECTSOUNDBUFFER *ppDSBuffer, LPUNKNOWN pUnkOuter) PURE; + STDMETHOD(GetCaps) (THIS_ LPDSCAPS pDSCaps) PURE; + STDMETHOD(DuplicateSoundBuffer) (THIS_ LPDIRECTSOUNDBUFFER pDSBufferOriginal, LPDIRECTSOUNDBUFFER *ppDSBufferDuplicate) PURE; + STDMETHOD(SetCooperativeLevel) (THIS_ HWND hwnd, DWORD dwLevel) PURE; + STDMETHOD(Compact) (THIS) PURE; + STDMETHOD(GetSpeakerConfig) (THIS_ LPDWORD pdwSpeakerConfig) PURE; + STDMETHOD(SetSpeakerConfig) (THIS_ DWORD dwSpeakerConfig) PURE; + STDMETHOD(Initialize) (THIS_ LPCGUID pcGuidDevice) PURE; +}; + +#define IDirectSound_QueryInterface(p,a,b) IUnknown_QueryInterface(p,a,b) +#define IDirectSound_AddRef(p) IUnknown_AddRef(p) +#define IDirectSound_Release(p) IUnknown_Release(p) + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectSound_CreateSoundBuffer(p,a,b,c) (p)->lpVtbl->CreateSoundBuffer(p,a,b,c) +#define IDirectSound_GetCaps(p,a) (p)->lpVtbl->GetCaps(p,a) +#define IDirectSound_DuplicateSoundBuffer(p,a,b) (p)->lpVtbl->DuplicateSoundBuffer(p,a,b) +#define IDirectSound_SetCooperativeLevel(p,a,b) (p)->lpVtbl->SetCooperativeLevel(p,a,b) +#define IDirectSound_Compact(p) (p)->lpVtbl->Compact(p) +#define IDirectSound_GetSpeakerConfig(p,a) (p)->lpVtbl->GetSpeakerConfig(p,a) +#define IDirectSound_SetSpeakerConfig(p,b) (p)->lpVtbl->SetSpeakerConfig(p,b) +#define IDirectSound_Initialize(p,a) (p)->lpVtbl->Initialize(p,a) +#else // !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectSound_CreateSoundBuffer(p,a,b,c) (p)->CreateSoundBuffer(a,b,c) +#define IDirectSound_GetCaps(p,a) (p)->GetCaps(a) +#define IDirectSound_DuplicateSoundBuffer(p,a,b) (p)->DuplicateSoundBuffer(a,b) +#define IDirectSound_SetCooperativeLevel(p,a,b) (p)->SetCooperativeLevel(a,b) +#define IDirectSound_Compact(p) (p)->Compact() +#define IDirectSound_GetSpeakerConfig(p,a) (p)->GetSpeakerConfig(a) +#define IDirectSound_SetSpeakerConfig(p,b) (p)->SetSpeakerConfig(b) +#define IDirectSound_Initialize(p,a) (p)->Initialize(a) +#endif // !defined(__cplusplus) || defined(CINTERFACE) + +#if DIRECTSOUND_VERSION >= 0x0800 + +// +// IDirectSound8 +// + +DEFINE_GUID(IID_IDirectSound8, 0xC50A7E93, 0xF395, 0x4834, 0x9E, 0xF6, 0x7F, 0xA9, 0x9D, 0xE5, 0x09, 0x66); + +#undef INTERFACE +#define INTERFACE IDirectSound8 + +DECLARE_INTERFACE_(IDirectSound8, IDirectSound) +{ + // IUnknown methods + STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE; + STDMETHOD_(ULONG,AddRef) (THIS) PURE; + STDMETHOD_(ULONG,Release) (THIS) PURE; + + // IDirectSound methods + STDMETHOD(CreateSoundBuffer) (THIS_ LPCDSBUFFERDESC pcDSBufferDesc, LPDIRECTSOUNDBUFFER *ppDSBuffer, LPUNKNOWN pUnkOuter) PURE; + STDMETHOD(GetCaps) (THIS_ LPDSCAPS pDSCaps) PURE; + STDMETHOD(DuplicateSoundBuffer) (THIS_ LPDIRECTSOUNDBUFFER pDSBufferOriginal, LPDIRECTSOUNDBUFFER *ppDSBufferDuplicate) PURE; + STDMETHOD(SetCooperativeLevel) (THIS_ HWND hwnd, DWORD dwLevel) PURE; + STDMETHOD(Compact) (THIS) PURE; + STDMETHOD(GetSpeakerConfig) (THIS_ LPDWORD pdwSpeakerConfig) PURE; + STDMETHOD(SetSpeakerConfig) (THIS_ DWORD dwSpeakerConfig) PURE; + STDMETHOD(Initialize) (THIS_ LPCGUID pcGuidDevice) PURE; + + // IDirectSound8 methods + STDMETHOD(VerifyCertification) (THIS_ LPDWORD pdwCertified) PURE; +}; + +#define IDirectSound8_QueryInterface(p,a,b) IDirectSound_QueryInterface(p,a,b) +#define IDirectSound8_AddRef(p) IDirectSound_AddRef(p) +#define IDirectSound8_Release(p) IDirectSound_Release(p) +#define IDirectSound8_CreateSoundBuffer(p,a,b,c) IDirectSound_CreateSoundBuffer(p,a,b,c) +#define IDirectSound8_GetCaps(p,a) IDirectSound_GetCaps(p,a) +#define IDirectSound8_DuplicateSoundBuffer(p,a,b) IDirectSound_DuplicateSoundBuffer(p,a,b) +#define IDirectSound8_SetCooperativeLevel(p,a,b) IDirectSound_SetCooperativeLevel(p,a,b) +#define IDirectSound8_Compact(p) IDirectSound_Compact(p) +#define IDirectSound8_GetSpeakerConfig(p,a) IDirectSound_GetSpeakerConfig(p,a) +#define IDirectSound8_SetSpeakerConfig(p,a) IDirectSound_SetSpeakerConfig(p,a) +#define IDirectSound8_Initialize(p,a) IDirectSound_Initialize(p,a) + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectSound8_VerifyCertification(p,a) (p)->lpVtbl->VerifyCertification(p,a) +#else // !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectSound8_VerifyCertification(p,a) (p)->VerifyCertification(a) +#endif // !defined(__cplusplus) || defined(CINTERFACE) + +#endif // DIRECTSOUND_VERSION >= 0x0800 + +// +// IDirectSoundBuffer +// + +DEFINE_GUID(IID_IDirectSoundBuffer, 0x279AFA85, 0x4981, 0x11CE, 0xA5, 0x21, 0x00, 0x20, 0xAF, 0x0B, 0xE5, 0x60); + +#undef INTERFACE +#define INTERFACE IDirectSoundBuffer + +DECLARE_INTERFACE_(IDirectSoundBuffer, IUnknown) +{ + // IUnknown methods + STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE; + STDMETHOD_(ULONG,AddRef) (THIS) PURE; + STDMETHOD_(ULONG,Release) (THIS) PURE; + + // IDirectSoundBuffer methods + STDMETHOD(GetCaps) (THIS_ LPDSBCAPS pDSBufferCaps) PURE; + STDMETHOD(GetCurrentPosition) (THIS_ LPDWORD pdwCurrentPlayCursor, LPDWORD pdwCurrentWriteCursor) PURE; + STDMETHOD(GetFormat) (THIS_ LPWAVEFORMATEX pwfxFormat, DWORD dwSizeAllocated, LPDWORD pdwSizeWritten) PURE; + STDMETHOD(GetVolume) (THIS_ LPLONG plVolume) PURE; + STDMETHOD(GetPan) (THIS_ LPLONG plPan) PURE; + STDMETHOD(GetFrequency) (THIS_ LPDWORD pdwFrequency) PURE; + STDMETHOD(GetStatus) (THIS_ LPDWORD pdwStatus) PURE; + STDMETHOD(Initialize) (THIS_ LPDIRECTSOUND pDirectSound, LPCDSBUFFERDESC pcDSBufferDesc) PURE; + STDMETHOD(Lock) (THIS_ DWORD dwOffset, DWORD dwBytes, LPVOID *ppvAudioPtr1, LPDWORD pdwAudioBytes1, + LPVOID *ppvAudioPtr2, LPDWORD pdwAudioBytes2, DWORD dwFlags) PURE; + STDMETHOD(Play) (THIS_ DWORD dwReserved1, DWORD dwPriority, DWORD dwFlags) PURE; + STDMETHOD(SetCurrentPosition) (THIS_ DWORD dwNewPosition) PURE; + STDMETHOD(SetFormat) (THIS_ LPCWAVEFORMATEX pcfxFormat) PURE; + STDMETHOD(SetVolume) (THIS_ LONG lVolume) PURE; + STDMETHOD(SetPan) (THIS_ LONG lPan) PURE; + STDMETHOD(SetFrequency) (THIS_ DWORD dwFrequency) PURE; + STDMETHOD(Stop) (THIS) PURE; + STDMETHOD(Unlock) (THIS_ LPVOID pvAudioPtr1, DWORD dwAudioBytes1, LPVOID pvAudioPtr2, DWORD dwAudioBytes2) PURE; + STDMETHOD(Restore) (THIS) PURE; +}; + +#define IDirectSoundBuffer_QueryInterface(p,a,b) IUnknown_QueryInterface(p,a,b) +#define IDirectSoundBuffer_AddRef(p) IUnknown_AddRef(p) +#define IDirectSoundBuffer_Release(p) IUnknown_Release(p) + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectSoundBuffer_GetCaps(p,a) (p)->lpVtbl->GetCaps(p,a) +#define IDirectSoundBuffer_GetCurrentPosition(p,a,b) (p)->lpVtbl->GetCurrentPosition(p,a,b) +#define IDirectSoundBuffer_GetFormat(p,a,b,c) (p)->lpVtbl->GetFormat(p,a,b,c) +#define IDirectSoundBuffer_GetVolume(p,a) (p)->lpVtbl->GetVolume(p,a) +#define IDirectSoundBuffer_GetPan(p,a) (p)->lpVtbl->GetPan(p,a) +#define IDirectSoundBuffer_GetFrequency(p,a) (p)->lpVtbl->GetFrequency(p,a) +#define IDirectSoundBuffer_GetStatus(p,a) (p)->lpVtbl->GetStatus(p,a) +#define IDirectSoundBuffer_Initialize(p,a,b) (p)->lpVtbl->Initialize(p,a,b) +#define IDirectSoundBuffer_Lock(p,a,b,c,d,e,f,g) (p)->lpVtbl->Lock(p,a,b,c,d,e,f,g) +#define IDirectSoundBuffer_Play(p,a,b,c) (p)->lpVtbl->Play(p,a,b,c) +#define IDirectSoundBuffer_SetCurrentPosition(p,a) (p)->lpVtbl->SetCurrentPosition(p,a) +#define IDirectSoundBuffer_SetFormat(p,a) (p)->lpVtbl->SetFormat(p,a) +#define IDirectSoundBuffer_SetVolume(p,a) (p)->lpVtbl->SetVolume(p,a) +#define IDirectSoundBuffer_SetPan(p,a) (p)->lpVtbl->SetPan(p,a) +#define IDirectSoundBuffer_SetFrequency(p,a) (p)->lpVtbl->SetFrequency(p,a) +#define IDirectSoundBuffer_Stop(p) (p)->lpVtbl->Stop(p) +#define IDirectSoundBuffer_Unlock(p,a,b,c,d) (p)->lpVtbl->Unlock(p,a,b,c,d) +#define IDirectSoundBuffer_Restore(p) (p)->lpVtbl->Restore(p) +#else // !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectSoundBuffer_GetCaps(p,a) (p)->GetCaps(a) +#define IDirectSoundBuffer_GetCurrentPosition(p,a,b) (p)->GetCurrentPosition(a,b) +#define IDirectSoundBuffer_GetFormat(p,a,b,c) (p)->GetFormat(a,b,c) +#define IDirectSoundBuffer_GetVolume(p,a) (p)->GetVolume(a) +#define IDirectSoundBuffer_GetPan(p,a) (p)->GetPan(a) +#define IDirectSoundBuffer_GetFrequency(p,a) (p)->GetFrequency(a) +#define IDirectSoundBuffer_GetStatus(p,a) (p)->GetStatus(a) +#define IDirectSoundBuffer_Initialize(p,a,b) (p)->Initialize(a,b) +#define IDirectSoundBuffer_Lock(p,a,b,c,d,e,f,g) (p)->Lock(a,b,c,d,e,f,g) +#define IDirectSoundBuffer_Play(p,a,b,c) (p)->Play(a,b,c) +#define IDirectSoundBuffer_SetCurrentPosition(p,a) (p)->SetCurrentPosition(a) +#define IDirectSoundBuffer_SetFormat(p,a) (p)->SetFormat(a) +#define IDirectSoundBuffer_SetVolume(p,a) (p)->SetVolume(a) +#define IDirectSoundBuffer_SetPan(p,a) (p)->SetPan(a) +#define IDirectSoundBuffer_SetFrequency(p,a) (p)->SetFrequency(a) +#define IDirectSoundBuffer_Stop(p) (p)->Stop() +#define IDirectSoundBuffer_Unlock(p,a,b,c,d) (p)->Unlock(a,b,c,d) +#define IDirectSoundBuffer_Restore(p) (p)->Restore() +#endif // !defined(__cplusplus) || defined(CINTERFACE) + +#if DIRECTSOUND_VERSION >= 0x0800 + +// +// IDirectSoundBuffer8 +// + +DEFINE_GUID(IID_IDirectSoundBuffer8, 0x6825a449, 0x7524, 0x4d82, 0x92, 0x0f, 0x50, 0xe3, 0x6a, 0xb3, 0xab, 0x1e); + +#undef INTERFACE +#define INTERFACE IDirectSoundBuffer8 + +DECLARE_INTERFACE_(IDirectSoundBuffer8, IDirectSoundBuffer) +{ + // IUnknown methods + STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE; + STDMETHOD_(ULONG,AddRef) (THIS) PURE; + STDMETHOD_(ULONG,Release) (THIS) PURE; + + // IDirectSoundBuffer methods + STDMETHOD(GetCaps) (THIS_ LPDSBCAPS pDSBufferCaps) PURE; + STDMETHOD(GetCurrentPosition) (THIS_ LPDWORD pdwCurrentPlayCursor, LPDWORD pdwCurrentWriteCursor) PURE; + STDMETHOD(GetFormat) (THIS_ LPWAVEFORMATEX pwfxFormat, DWORD dwSizeAllocated, LPDWORD pdwSizeWritten) PURE; + STDMETHOD(GetVolume) (THIS_ LPLONG plVolume) PURE; + STDMETHOD(GetPan) (THIS_ LPLONG plPan) PURE; + STDMETHOD(GetFrequency) (THIS_ LPDWORD pdwFrequency) PURE; + STDMETHOD(GetStatus) (THIS_ LPDWORD pdwStatus) PURE; + STDMETHOD(Initialize) (THIS_ LPDIRECTSOUND pDirectSound, LPCDSBUFFERDESC pcDSBufferDesc) PURE; + STDMETHOD(Lock) (THIS_ DWORD dwOffset, DWORD dwBytes, LPVOID *ppvAudioPtr1, LPDWORD pdwAudioBytes1, + LPVOID *ppvAudioPtr2, LPDWORD pdwAudioBytes2, DWORD dwFlags) PURE; + STDMETHOD(Play) (THIS_ DWORD dwReserved1, DWORD dwPriority, DWORD dwFlags) PURE; + STDMETHOD(SetCurrentPosition) (THIS_ DWORD dwNewPosition) PURE; + STDMETHOD(SetFormat) (THIS_ LPCWAVEFORMATEX pcfxFormat) PURE; + STDMETHOD(SetVolume) (THIS_ LONG lVolume) PURE; + STDMETHOD(SetPan) (THIS_ LONG lPan) PURE; + STDMETHOD(SetFrequency) (THIS_ DWORD dwFrequency) PURE; + STDMETHOD(Stop) (THIS) PURE; + STDMETHOD(Unlock) (THIS_ LPVOID pvAudioPtr1, DWORD dwAudioBytes1, LPVOID pvAudioPtr2, DWORD dwAudioBytes2) PURE; + STDMETHOD(Restore) (THIS) PURE; + + // IDirectSoundBuffer8 methods + STDMETHOD(SetFX) (THIS_ DWORD dwEffectsCount, LPDSEFFECTDESC pDSFXDesc, LPDWORD pdwResultCodes) PURE; + STDMETHOD(AcquireResources) (THIS_ DWORD dwFlags, DWORD dwEffectsCount, LPDWORD pdwResultCodes) PURE; + STDMETHOD(GetObjectInPath) (THIS_ REFGUID rguidObject, DWORD dwIndex, REFGUID rguidInterface, LPVOID *ppObject) PURE; +}; + +// Special GUID meaning "select all objects" for use in GetObjectInPath() +DEFINE_GUID(GUID_All_Objects, 0xaa114de5, 0xc262, 0x4169, 0xa1, 0xc8, 0x23, 0xd6, 0x98, 0xcc, 0x73, 0xb5); + +#define IDirectSoundBuffer8_QueryInterface(p,a,b) IUnknown_QueryInterface(p,a,b) +#define IDirectSoundBuffer8_AddRef(p) IUnknown_AddRef(p) +#define IDirectSoundBuffer8_Release(p) IUnknown_Release(p) + +#define IDirectSoundBuffer8_GetCaps(p,a) IDirectSoundBuffer_GetCaps(p,a) +#define IDirectSoundBuffer8_GetCurrentPosition(p,a,b) IDirectSoundBuffer_GetCurrentPosition(p,a,b) +#define IDirectSoundBuffer8_GetFormat(p,a,b,c) IDirectSoundBuffer_GetFormat(p,a,b,c) +#define IDirectSoundBuffer8_GetVolume(p,a) IDirectSoundBuffer_GetVolume(p,a) +#define IDirectSoundBuffer8_GetPan(p,a) IDirectSoundBuffer_GetPan(p,a) +#define IDirectSoundBuffer8_GetFrequency(p,a) IDirectSoundBuffer_GetFrequency(p,a) +#define IDirectSoundBuffer8_GetStatus(p,a) IDirectSoundBuffer_GetStatus(p,a) +#define IDirectSoundBuffer8_Initialize(p,a,b) IDirectSoundBuffer_Initialize(p,a,b) +#define IDirectSoundBuffer8_Lock(p,a,b,c,d,e,f,g) IDirectSoundBuffer_Lock(p,a,b,c,d,e,f,g) +#define IDirectSoundBuffer8_Play(p,a,b,c) IDirectSoundBuffer_Play(p,a,b,c) +#define IDirectSoundBuffer8_SetCurrentPosition(p,a) IDirectSoundBuffer_SetCurrentPosition(p,a) +#define IDirectSoundBuffer8_SetFormat(p,a) IDirectSoundBuffer_SetFormat(p,a) +#define IDirectSoundBuffer8_SetVolume(p,a) IDirectSoundBuffer_SetVolume(p,a) +#define IDirectSoundBuffer8_SetPan(p,a) IDirectSoundBuffer_SetPan(p,a) +#define IDirectSoundBuffer8_SetFrequency(p,a) IDirectSoundBuffer_SetFrequency(p,a) +#define IDirectSoundBuffer8_Stop(p) IDirectSoundBuffer_Stop(p) +#define IDirectSoundBuffer8_Unlock(p,a,b,c,d) IDirectSoundBuffer_Unlock(p,a,b,c,d) +#define IDirectSoundBuffer8_Restore(p) IDirectSoundBuffer_Restore(p) + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectSoundBuffer8_SetFX(p,a,b,c) (p)->lpVtbl->SetFX(p,a,b,c) +#define IDirectSoundBuffer8_AcquireResources(p,a,b,c) (p)->lpVtbl->AcquireResources(p,a,b,c) +#define IDirectSoundBuffer8_GetObjectInPath(p,a,b,c,d) (p)->lpVtbl->GetObjectInPath(p,a,b,c,d) +#else // !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectSoundBuffer8_SetFX(p,a,b,c) (p)->SetFX(a,b,c) +#define IDirectSoundBuffer8_AcquireResources(p,a,b,c) (p)->AcquireResources(a,b,c) +#define IDirectSoundBuffer8_GetObjectInPath(p,a,b,c,d) (p)->GetObjectInPath(a,b,c,d) +#endif // !defined(__cplusplus) || defined(CINTERFACE) + +#endif // DIRECTSOUND_VERSION >= 0x0800 + +// +// IDirectSound3DListener +// + +DEFINE_GUID(IID_IDirectSound3DListener, 0x279AFA84, 0x4981, 0x11CE, 0xA5, 0x21, 0x00, 0x20, 0xAF, 0x0B, 0xE5, 0x60); + +#undef INTERFACE +#define INTERFACE IDirectSound3DListener + +DECLARE_INTERFACE_(IDirectSound3DListener, IUnknown) +{ + // IUnknown methods + STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE; + STDMETHOD_(ULONG,AddRef) (THIS) PURE; + STDMETHOD_(ULONG,Release) (THIS) PURE; + + // IDirectSound3DListener methods + STDMETHOD(GetAllParameters) (THIS_ LPDS3DLISTENER pListener) PURE; + STDMETHOD(GetDistanceFactor) (THIS_ D3DVALUE* pflDistanceFactor) PURE; + STDMETHOD(GetDopplerFactor) (THIS_ D3DVALUE* pflDopplerFactor) PURE; + STDMETHOD(GetOrientation) (THIS_ D3DVECTOR* pvOrientFront, D3DVECTOR* pvOrientTop) PURE; + STDMETHOD(GetPosition) (THIS_ D3DVECTOR* pvPosition) PURE; + STDMETHOD(GetRolloffFactor) (THIS_ D3DVALUE* pflRolloffFactor) PURE; + STDMETHOD(GetVelocity) (THIS_ D3DVECTOR* pvVelocity) PURE; + STDMETHOD(SetAllParameters) (THIS_ LPCDS3DLISTENER pcListener, DWORD dwApply) PURE; + STDMETHOD(SetDistanceFactor) (THIS_ D3DVALUE flDistanceFactor, DWORD dwApply) PURE; + STDMETHOD(SetDopplerFactor) (THIS_ D3DVALUE flDopplerFactor, DWORD dwApply) PURE; + STDMETHOD(SetOrientation) (THIS_ D3DVALUE xFront, D3DVALUE yFront, D3DVALUE zFront, + D3DVALUE xTop, D3DVALUE yTop, D3DVALUE zTop, DWORD dwApply) PURE; + STDMETHOD(SetPosition) (THIS_ D3DVALUE x, D3DVALUE y, D3DVALUE z, DWORD dwApply) PURE; + STDMETHOD(SetRolloffFactor) (THIS_ D3DVALUE flRolloffFactor, DWORD dwApply) PURE; + STDMETHOD(SetVelocity) (THIS_ D3DVALUE x, D3DVALUE y, D3DVALUE z, DWORD dwApply) PURE; + STDMETHOD(CommitDeferredSettings) (THIS) PURE; +}; + +#define IDirectSound3DListener_QueryInterface(p,a,b) IUnknown_QueryInterface(p,a,b) +#define IDirectSound3DListener_AddRef(p) IUnknown_AddRef(p) +#define IDirectSound3DListener_Release(p) IUnknown_Release(p) + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectSound3DListener_GetAllParameters(p,a) (p)->lpVtbl->GetAllParameters(p,a) +#define IDirectSound3DListener_GetDistanceFactor(p,a) (p)->lpVtbl->GetDistanceFactor(p,a) +#define IDirectSound3DListener_GetDopplerFactor(p,a) (p)->lpVtbl->GetDopplerFactor(p,a) +#define IDirectSound3DListener_GetOrientation(p,a,b) (p)->lpVtbl->GetOrientation(p,a,b) +#define IDirectSound3DListener_GetPosition(p,a) (p)->lpVtbl->GetPosition(p,a) +#define IDirectSound3DListener_GetRolloffFactor(p,a) (p)->lpVtbl->GetRolloffFactor(p,a) +#define IDirectSound3DListener_GetVelocity(p,a) (p)->lpVtbl->GetVelocity(p,a) +#define IDirectSound3DListener_SetAllParameters(p,a,b) (p)->lpVtbl->SetAllParameters(p,a,b) +#define IDirectSound3DListener_SetDistanceFactor(p,a,b) (p)->lpVtbl->SetDistanceFactor(p,a,b) +#define IDirectSound3DListener_SetDopplerFactor(p,a,b) (p)->lpVtbl->SetDopplerFactor(p,a,b) +#define IDirectSound3DListener_SetOrientation(p,a,b,c,d,e,f,g) (p)->lpVtbl->SetOrientation(p,a,b,c,d,e,f,g) +#define IDirectSound3DListener_SetPosition(p,a,b,c,d) (p)->lpVtbl->SetPosition(p,a,b,c,d) +#define IDirectSound3DListener_SetRolloffFactor(p,a,b) (p)->lpVtbl->SetRolloffFactor(p,a,b) +#define IDirectSound3DListener_SetVelocity(p,a,b,c,d) (p)->lpVtbl->SetVelocity(p,a,b,c,d) +#define IDirectSound3DListener_CommitDeferredSettings(p) (p)->lpVtbl->CommitDeferredSettings(p) +#else // !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectSound3DListener_GetAllParameters(p,a) (p)->GetAllParameters(a) +#define IDirectSound3DListener_GetDistanceFactor(p,a) (p)->GetDistanceFactor(a) +#define IDirectSound3DListener_GetDopplerFactor(p,a) (p)->GetDopplerFactor(a) +#define IDirectSound3DListener_GetOrientation(p,a,b) (p)->GetOrientation(a,b) +#define IDirectSound3DListener_GetPosition(p,a) (p)->GetPosition(a) +#define IDirectSound3DListener_GetRolloffFactor(p,a) (p)->GetRolloffFactor(a) +#define IDirectSound3DListener_GetVelocity(p,a) (p)->GetVelocity(a) +#define IDirectSound3DListener_SetAllParameters(p,a,b) (p)->SetAllParameters(a,b) +#define IDirectSound3DListener_SetDistanceFactor(p,a,b) (p)->SetDistanceFactor(a,b) +#define IDirectSound3DListener_SetDopplerFactor(p,a,b) (p)->SetDopplerFactor(a,b) +#define IDirectSound3DListener_SetOrientation(p,a,b,c,d,e,f,g) (p)->SetOrientation(a,b,c,d,e,f,g) +#define IDirectSound3DListener_SetPosition(p,a,b,c,d) (p)->SetPosition(a,b,c,d) +#define IDirectSound3DListener_SetRolloffFactor(p,a,b) (p)->SetRolloffFactor(a,b) +#define IDirectSound3DListener_SetVelocity(p,a,b,c,d) (p)->SetVelocity(a,b,c,d) +#define IDirectSound3DListener_CommitDeferredSettings(p) (p)->CommitDeferredSettings() +#endif // !defined(__cplusplus) || defined(CINTERFACE) + +// +// IDirectSound3DBuffer +// + +DEFINE_GUID(IID_IDirectSound3DBuffer, 0x279AFA86, 0x4981, 0x11CE, 0xA5, 0x21, 0x00, 0x20, 0xAF, 0x0B, 0xE5, 0x60); + +#undef INTERFACE +#define INTERFACE IDirectSound3DBuffer + +DECLARE_INTERFACE_(IDirectSound3DBuffer, IUnknown) +{ + // IUnknown methods + STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE; + STDMETHOD_(ULONG,AddRef) (THIS) PURE; + STDMETHOD_(ULONG,Release) (THIS) PURE; + + // IDirectSound3DBuffer methods + STDMETHOD(GetAllParameters) (THIS_ LPDS3DBUFFER pDs3dBuffer) PURE; + STDMETHOD(GetConeAngles) (THIS_ LPDWORD pdwInsideConeAngle, LPDWORD pdwOutsideConeAngle) PURE; + STDMETHOD(GetConeOrientation) (THIS_ D3DVECTOR* pvOrientation) PURE; + STDMETHOD(GetConeOutsideVolume) (THIS_ LPLONG plConeOutsideVolume) PURE; + STDMETHOD(GetMaxDistance) (THIS_ D3DVALUE* pflMaxDistance) PURE; + STDMETHOD(GetMinDistance) (THIS_ D3DVALUE* pflMinDistance) PURE; + STDMETHOD(GetMode) (THIS_ LPDWORD pdwMode) PURE; + STDMETHOD(GetPosition) (THIS_ D3DVECTOR* pvPosition) PURE; + STDMETHOD(GetVelocity) (THIS_ D3DVECTOR* pvVelocity) PURE; + STDMETHOD(SetAllParameters) (THIS_ LPCDS3DBUFFER pcDs3dBuffer, DWORD dwApply) PURE; + STDMETHOD(SetConeAngles) (THIS_ DWORD dwInsideConeAngle, DWORD dwOutsideConeAngle, DWORD dwApply) PURE; + STDMETHOD(SetConeOrientation) (THIS_ D3DVALUE x, D3DVALUE y, D3DVALUE z, DWORD dwApply) PURE; + STDMETHOD(SetConeOutsideVolume) (THIS_ LONG lConeOutsideVolume, DWORD dwApply) PURE; + STDMETHOD(SetMaxDistance) (THIS_ D3DVALUE flMaxDistance, DWORD dwApply) PURE; + STDMETHOD(SetMinDistance) (THIS_ D3DVALUE flMinDistance, DWORD dwApply) PURE; + STDMETHOD(SetMode) (THIS_ DWORD dwMode, DWORD dwApply) PURE; + STDMETHOD(SetPosition) (THIS_ D3DVALUE x, D3DVALUE y, D3DVALUE z, DWORD dwApply) PURE; + STDMETHOD(SetVelocity) (THIS_ D3DVALUE x, D3DVALUE y, D3DVALUE z, DWORD dwApply) PURE; +}; + +#define IDirectSound3DBuffer_QueryInterface(p,a,b) IUnknown_QueryInterface(p,a,b) +#define IDirectSound3DBuffer_AddRef(p) IUnknown_AddRef(p) +#define IDirectSound3DBuffer_Release(p) IUnknown_Release(p) + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectSound3DBuffer_GetAllParameters(p,a) (p)->lpVtbl->GetAllParameters(p,a) +#define IDirectSound3DBuffer_GetConeAngles(p,a,b) (p)->lpVtbl->GetConeAngles(p,a,b) +#define IDirectSound3DBuffer_GetConeOrientation(p,a) (p)->lpVtbl->GetConeOrientation(p,a) +#define IDirectSound3DBuffer_GetConeOutsideVolume(p,a) (p)->lpVtbl->GetConeOutsideVolume(p,a) +#define IDirectSound3DBuffer_GetPosition(p,a) (p)->lpVtbl->GetPosition(p,a) +#define IDirectSound3DBuffer_GetMinDistance(p,a) (p)->lpVtbl->GetMinDistance(p,a) +#define IDirectSound3DBuffer_GetMaxDistance(p,a) (p)->lpVtbl->GetMaxDistance(p,a) +#define IDirectSound3DBuffer_GetMode(p,a) (p)->lpVtbl->GetMode(p,a) +#define IDirectSound3DBuffer_GetVelocity(p,a) (p)->lpVtbl->GetVelocity(p,a) +#define IDirectSound3DBuffer_SetAllParameters(p,a,b) (p)->lpVtbl->SetAllParameters(p,a,b) +#define IDirectSound3DBuffer_SetConeAngles(p,a,b,c) (p)->lpVtbl->SetConeAngles(p,a,b,c) +#define IDirectSound3DBuffer_SetConeOrientation(p,a,b,c,d) (p)->lpVtbl->SetConeOrientation(p,a,b,c,d) +#define IDirectSound3DBuffer_SetConeOutsideVolume(p,a,b) (p)->lpVtbl->SetConeOutsideVolume(p,a,b) +#define IDirectSound3DBuffer_SetPosition(p,a,b,c,d) (p)->lpVtbl->SetPosition(p,a,b,c,d) +#define IDirectSound3DBuffer_SetMinDistance(p,a,b) (p)->lpVtbl->SetMinDistance(p,a,b) +#define IDirectSound3DBuffer_SetMaxDistance(p,a,b) (p)->lpVtbl->SetMaxDistance(p,a,b) +#define IDirectSound3DBuffer_SetMode(p,a,b) (p)->lpVtbl->SetMode(p,a,b) +#define IDirectSound3DBuffer_SetVelocity(p,a,b,c,d) (p)->lpVtbl->SetVelocity(p,a,b,c,d) +#else // !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectSound3DBuffer_GetAllParameters(p,a) (p)->GetAllParameters(a) +#define IDirectSound3DBuffer_GetConeAngles(p,a,b) (p)->GetConeAngles(a,b) +#define IDirectSound3DBuffer_GetConeOrientation(p,a) (p)->GetConeOrientation(a) +#define IDirectSound3DBuffer_GetConeOutsideVolume(p,a) (p)->GetConeOutsideVolume(a) +#define IDirectSound3DBuffer_GetPosition(p,a) (p)->GetPosition(a) +#define IDirectSound3DBuffer_GetMinDistance(p,a) (p)->GetMinDistance(a) +#define IDirectSound3DBuffer_GetMaxDistance(p,a) (p)->GetMaxDistance(a) +#define IDirectSound3DBuffer_GetMode(p,a) (p)->GetMode(a) +#define IDirectSound3DBuffer_GetVelocity(p,a) (p)->GetVelocity(a) +#define IDirectSound3DBuffer_SetAllParameters(p,a,b) (p)->SetAllParameters(a,b) +#define IDirectSound3DBuffer_SetConeAngles(p,a,b,c) (p)->SetConeAngles(a,b,c) +#define IDirectSound3DBuffer_SetConeOrientation(p,a,b,c,d) (p)->SetConeOrientation(a,b,c,d) +#define IDirectSound3DBuffer_SetConeOutsideVolume(p,a,b) (p)->SetConeOutsideVolume(a,b) +#define IDirectSound3DBuffer_SetPosition(p,a,b,c,d) (p)->SetPosition(a,b,c,d) +#define IDirectSound3DBuffer_SetMinDistance(p,a,b) (p)->SetMinDistance(a,b) +#define IDirectSound3DBuffer_SetMaxDistance(p,a,b) (p)->SetMaxDistance(a,b) +#define IDirectSound3DBuffer_SetMode(p,a,b) (p)->SetMode(a,b) +#define IDirectSound3DBuffer_SetVelocity(p,a,b,c,d) (p)->SetVelocity(a,b,c,d) +#endif // !defined(__cplusplus) || defined(CINTERFACE) + +// +// IDirectSoundCapture +// + +DEFINE_GUID(IID_IDirectSoundCapture, 0xb0210781, 0x89cd, 0x11d0, 0xaf, 0x8, 0x0, 0xa0, 0xc9, 0x25, 0xcd, 0x16); + +#undef INTERFACE +#define INTERFACE IDirectSoundCapture + +DECLARE_INTERFACE_(IDirectSoundCapture, IUnknown) +{ + // IUnknown methods + STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE; + STDMETHOD_(ULONG,AddRef) (THIS) PURE; + STDMETHOD_(ULONG,Release) (THIS) PURE; + + // IDirectSoundCapture methods + STDMETHOD(CreateCaptureBuffer) (THIS_ LPCDSCBUFFERDESC pcDSCBufferDesc, LPDIRECTSOUNDCAPTUREBUFFER *ppDSCBuffer, LPUNKNOWN pUnkOuter) PURE; + STDMETHOD(GetCaps) (THIS_ LPDSCCAPS pDSCCaps) PURE; + STDMETHOD(Initialize) (THIS_ LPCGUID pcGuidDevice) PURE; +}; + +#define IDirectSoundCapture_QueryInterface(p,a,b) IUnknown_QueryInterface(p,a,b) +#define IDirectSoundCapture_AddRef(p) IUnknown_AddRef(p) +#define IDirectSoundCapture_Release(p) IUnknown_Release(p) + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectSoundCapture_CreateCaptureBuffer(p,a,b,c) (p)->lpVtbl->CreateCaptureBuffer(p,a,b,c) +#define IDirectSoundCapture_GetCaps(p,a) (p)->lpVtbl->GetCaps(p,a) +#define IDirectSoundCapture_Initialize(p,a) (p)->lpVtbl->Initialize(p,a) +#else // !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectSoundCapture_CreateCaptureBuffer(p,a,b,c) (p)->CreateCaptureBuffer(a,b,c) +#define IDirectSoundCapture_GetCaps(p,a) (p)->GetCaps(a) +#define IDirectSoundCapture_Initialize(p,a) (p)->Initialize(a) +#endif // !defined(__cplusplus) || defined(CINTERFACE) + +// +// IDirectSoundCaptureBuffer +// + +DEFINE_GUID(IID_IDirectSoundCaptureBuffer, 0xb0210782, 0x89cd, 0x11d0, 0xaf, 0x8, 0x0, 0xa0, 0xc9, 0x25, 0xcd, 0x16); + +#undef INTERFACE +#define INTERFACE IDirectSoundCaptureBuffer + +DECLARE_INTERFACE_(IDirectSoundCaptureBuffer, IUnknown) +{ + // IUnknown methods + STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE; + STDMETHOD_(ULONG,AddRef) (THIS) PURE; + STDMETHOD_(ULONG,Release) (THIS) PURE; + + // IDirectSoundCaptureBuffer methods + STDMETHOD(GetCaps) (THIS_ LPDSCBCAPS pDSCBCaps) PURE; + STDMETHOD(GetCurrentPosition) (THIS_ LPDWORD pdwCapturePosition, LPDWORD pdwReadPosition) PURE; + STDMETHOD(GetFormat) (THIS_ LPWAVEFORMATEX pwfxFormat, DWORD dwSizeAllocated, LPDWORD pdwSizeWritten) PURE; + STDMETHOD(GetStatus) (THIS_ LPDWORD pdwStatus) PURE; + STDMETHOD(Initialize) (THIS_ LPDIRECTSOUNDCAPTURE pDirectSoundCapture, LPCDSCBUFFERDESC pcDSCBufferDesc) PURE; + STDMETHOD(Lock) (THIS_ DWORD dwOffset, DWORD dwBytes, LPVOID *ppvAudioPtr1, LPDWORD pdwAudioBytes1, + LPVOID *ppvAudioPtr2, LPDWORD pdwAudioBytes2, DWORD dwFlags) PURE; + STDMETHOD(Start) (THIS_ DWORD dwFlags) PURE; + STDMETHOD(Stop) (THIS) PURE; + STDMETHOD(Unlock) (THIS_ LPVOID pvAudioPtr1, DWORD dwAudioBytes1, LPVOID pvAudioPtr2, DWORD dwAudioBytes2) PURE; +}; + +#define IDirectSoundCaptureBuffer_QueryInterface(p,a,b) IUnknown_QueryInterface(p,a,b) +#define IDirectSoundCaptureBuffer_AddRef(p) IUnknown_AddRef(p) +#define IDirectSoundCaptureBuffer_Release(p) IUnknown_Release(p) + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectSoundCaptureBuffer_GetCaps(p,a) (p)->lpVtbl->GetCaps(p,a) +#define IDirectSoundCaptureBuffer_GetCurrentPosition(p,a,b) (p)->lpVtbl->GetCurrentPosition(p,a,b) +#define IDirectSoundCaptureBuffer_GetFormat(p,a,b,c) (p)->lpVtbl->GetFormat(p,a,b,c) +#define IDirectSoundCaptureBuffer_GetStatus(p,a) (p)->lpVtbl->GetStatus(p,a) +#define IDirectSoundCaptureBuffer_Initialize(p,a,b) (p)->lpVtbl->Initialize(p,a,b) +#define IDirectSoundCaptureBuffer_Lock(p,a,b,c,d,e,f,g) (p)->lpVtbl->Lock(p,a,b,c,d,e,f,g) +#define IDirectSoundCaptureBuffer_Start(p,a) (p)->lpVtbl->Start(p,a) +#define IDirectSoundCaptureBuffer_Stop(p) (p)->lpVtbl->Stop(p) +#define IDirectSoundCaptureBuffer_Unlock(p,a,b,c,d) (p)->lpVtbl->Unlock(p,a,b,c,d) +#else // !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectSoundCaptureBuffer_GetCaps(p,a) (p)->GetCaps(a) +#define IDirectSoundCaptureBuffer_GetCurrentPosition(p,a,b) (p)->GetCurrentPosition(a,b) +#define IDirectSoundCaptureBuffer_GetFormat(p,a,b,c) (p)->GetFormat(a,b,c) +#define IDirectSoundCaptureBuffer_GetStatus(p,a) (p)->GetStatus(a) +#define IDirectSoundCaptureBuffer_Initialize(p,a,b) (p)->Initialize(a,b) +#define IDirectSoundCaptureBuffer_Lock(p,a,b,c,d,e,f,g) (p)->Lock(a,b,c,d,e,f,g) +#define IDirectSoundCaptureBuffer_Start(p,a) (p)->Start(a) +#define IDirectSoundCaptureBuffer_Stop(p) (p)->Stop() +#define IDirectSoundCaptureBuffer_Unlock(p,a,b,c,d) (p)->Unlock(a,b,c,d) +#endif // !defined(__cplusplus) || defined(CINTERFACE) + + +#if DIRECTSOUND_VERSION >= 0x0800 + +// +// IDirectSoundCaptureBuffer8 +// + +DEFINE_GUID(IID_IDirectSoundCaptureBuffer8, 0x990df4, 0xdbb, 0x4872, 0x83, 0x3e, 0x6d, 0x30, 0x3e, 0x80, 0xae, 0xb6); + +#undef INTERFACE +#define INTERFACE IDirectSoundCaptureBuffer8 + +DECLARE_INTERFACE_(IDirectSoundCaptureBuffer8, IDirectSoundCaptureBuffer) +{ + // IUnknown methods + STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE; + STDMETHOD_(ULONG,AddRef) (THIS) PURE; + STDMETHOD_(ULONG,Release) (THIS) PURE; + + // IDirectSoundCaptureBuffer methods + STDMETHOD(GetCaps) (THIS_ LPDSCBCAPS pDSCBCaps) PURE; + STDMETHOD(GetCurrentPosition) (THIS_ LPDWORD pdwCapturePosition, LPDWORD pdwReadPosition) PURE; + STDMETHOD(GetFormat) (THIS_ LPWAVEFORMATEX pwfxFormat, DWORD dwSizeAllocated, LPDWORD pdwSizeWritten) PURE; + STDMETHOD(GetStatus) (THIS_ LPDWORD pdwStatus) PURE; + STDMETHOD(Initialize) (THIS_ LPDIRECTSOUNDCAPTURE pDirectSoundCapture, LPCDSCBUFFERDESC pcDSCBufferDesc) PURE; + STDMETHOD(Lock) (THIS_ DWORD dwOffset, DWORD dwBytes, LPVOID *ppvAudioPtr1, LPDWORD pdwAudioBytes1, + LPVOID *ppvAudioPtr2, LPDWORD pdwAudioBytes2, DWORD dwFlags) PURE; + STDMETHOD(Start) (THIS_ DWORD dwFlags) PURE; + STDMETHOD(Stop) (THIS) PURE; + STDMETHOD(Unlock) (THIS_ LPVOID pvAudioPtr1, DWORD dwAudioBytes1, LPVOID pvAudioPtr2, DWORD dwAudioBytes2) PURE; + + // IDirectSoundCaptureBuffer8 methods + STDMETHOD(GetObjectInPath) (THIS_ REFGUID rguidObject, DWORD dwIndex, REFGUID rguidInterface, LPVOID *ppObject) PURE; + STDMETHOD(GetFXStatus) (DWORD dwFXCount, LPDWORD pdwFXStatus) PURE; +}; + +#define IDirectSoundCaptureBuffer8_QueryInterface(p,a,b) IUnknown_QueryInterface(p,a,b) +#define IDirectSoundCaptureBuffer8_AddRef(p) IUnknown_AddRef(p) +#define IDirectSoundCaptureBuffer8_Release(p) IUnknown_Release(p) + +#define IDirectSoundCaptureBuffer8_GetCaps(p,a) IDirectSoundCaptureBuffer_GetCaps(p,a) +#define IDirectSoundCaptureBuffer8_GetCurrentPosition(p,a,b) IDirectSoundCaptureBuffer_GetCurrentPosition(p,a,b) +#define IDirectSoundCaptureBuffer8_GetFormat(p,a,b,c) IDirectSoundCaptureBuffer_GetFormat(p,a,b,c) +#define IDirectSoundCaptureBuffer8_GetStatus(p,a) IDirectSoundCaptureBuffer_GetStatus(p,a) +#define IDirectSoundCaptureBuffer8_Initialize(p,a,b) IDirectSoundCaptureBuffer_Initialize(p,a,b) +#define IDirectSoundCaptureBuffer8_Lock(p,a,b,c,d,e,f,g) IDirectSoundCaptureBuffer_Lock(p,a,b,c,d,e,f,g) +#define IDirectSoundCaptureBuffer8_Start(p,a) IDirectSoundCaptureBuffer_Start(p,a) +#define IDirectSoundCaptureBuffer8_Stop(p) IDirectSoundCaptureBuffer_Stop(p)) +#define IDirectSoundCaptureBuffer8_Unlock(p,a,b,c,d) IDirectSoundCaptureBuffer_Unlock(p,a,b,c,d) + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectSoundCaptureBuffer8_GetObjectInPath(p,a,b,c,d) (p)->lpVtbl->GetObjectInPath(p,a,b,c,d) +#define IDirectSoundCaptureBuffer8_GetFXStatus(p,a,b) (p)->lpVtbl->GetFXStatus(p,a,b) +#else // !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectSoundCaptureBuffer8_GetObjectInPath(p,a,b,c,d) (p)->GetObjectInPath(a,b,c,d) +#define IDirectSoundCaptureBuffer8_GetFXStatus(p,a,b) (p)->GetFXStatus(a,b) +#endif // !defined(__cplusplus) || defined(CINTERFACE) + +#endif // DIRECTSOUND_VERSION >= 0x0800 + +// +// IDirectSoundNotify +// + +DEFINE_GUID(IID_IDirectSoundNotify, 0xb0210783, 0x89cd, 0x11d0, 0xaf, 0x8, 0x0, 0xa0, 0xc9, 0x25, 0xcd, 0x16); + +#undef INTERFACE +#define INTERFACE IDirectSoundNotify + +DECLARE_INTERFACE_(IDirectSoundNotify, IUnknown) +{ + // IUnknown methods + STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE; + STDMETHOD_(ULONG,AddRef) (THIS) PURE; + STDMETHOD_(ULONG,Release) (THIS) PURE; + + // IDirectSoundNotify methods + STDMETHOD(SetNotificationPositions) (THIS_ DWORD dwPositionNotifies, LPCDSBPOSITIONNOTIFY pcPositionNotifies) PURE; +}; + +#define IDirectSoundNotify_QueryInterface(p,a,b) IUnknown_QueryInterface(p,a,b) +#define IDirectSoundNotify_AddRef(p) IUnknown_AddRef(p) +#define IDirectSoundNotify_Release(p) IUnknown_Release(p) + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectSoundNotify_SetNotificationPositions(p,a,b) (p)->lpVtbl->SetNotificationPositions(p,a,b) +#else // !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectSoundNotify_SetNotificationPositions(p,a,b) (p)->SetNotificationPositions(a,b) +#endif // !defined(__cplusplus) || defined(CINTERFACE) + +// +// IKsPropertySet +// + +#ifndef _IKsPropertySet_ +#define _IKsPropertySet_ + +#ifdef __cplusplus +// 'struct' not 'class' per the way DECLARE_INTERFACE_ is defined +struct IKsPropertySet; +#endif // __cplusplus + +typedef struct IKsPropertySet *LPKSPROPERTYSET; + +#define KSPROPERTY_SUPPORT_GET 0x00000001 +#define KSPROPERTY_SUPPORT_SET 0x00000002 + +DEFINE_GUID(IID_IKsPropertySet, 0x31efac30, 0x515c, 0x11d0, 0xa9, 0xaa, 0x00, 0xaa, 0x00, 0x61, 0xbe, 0x93); + +#undef INTERFACE +#define INTERFACE IKsPropertySet + +DECLARE_INTERFACE_(IKsPropertySet, IUnknown) +{ + // IUnknown methods + STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE; + STDMETHOD_(ULONG,AddRef) (THIS) PURE; + STDMETHOD_(ULONG,Release) (THIS) PURE; + + // IKsPropertySet methods + STDMETHOD(Get) (THIS_ REFGUID rguidPropSet, ULONG ulId, LPVOID pInstanceData, ULONG ulInstanceLength, + LPVOID pPropertyData, ULONG ulDataLength, PULONG pulBytesReturned) PURE; + STDMETHOD(Set) (THIS_ REFGUID rguidPropSet, ULONG ulId, LPVOID pInstanceData, ULONG ulInstanceLength, + LPVOID pPropertyData, ULONG ulDataLength) PURE; + STDMETHOD(QuerySupport) (THIS_ REFGUID rguidPropSet, ULONG ulId, PULONG pulTypeSupport) PURE; +}; + +#define IKsPropertySet_QueryInterface(p,a,b) IUnknown_QueryInterface(p,a,b) +#define IKsPropertySet_AddRef(p) IUnknown_AddRef(p) +#define IKsPropertySet_Release(p) IUnknown_Release(p) + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IKsPropertySet_Get(p,a,b,c,d,e,f,g) (p)->lpVtbl->Get(p,a,b,c,d,e,f,g) +#define IKsPropertySet_Set(p,a,b,c,d,e,f) (p)->lpVtbl->Set(p,a,b,c,d,e,f) +#define IKsPropertySet_QuerySupport(p,a,b,c) (p)->lpVtbl->QuerySupport(p,a,b,c) +#else // !defined(__cplusplus) || defined(CINTERFACE) +#define IKsPropertySet_Get(p,a,b,c,d,e,f,g) (p)->Get(a,b,c,d,e,f,g) +#define IKsPropertySet_Set(p,a,b,c,d,e,f) (p)->Set(a,b,c,d,e,f) +#define IKsPropertySet_QuerySupport(p,a,b,c) (p)->QuerySupport(a,b,c) +#endif // !defined(__cplusplus) || defined(CINTERFACE) + +#endif // _IKsPropertySet_ + +#if DIRECTSOUND_VERSION >= 0x0800 + +// +// IDirectSoundFXGargle +// + +DEFINE_GUID(IID_IDirectSoundFXGargle, 0xd616f352, 0xd622, 0x11ce, 0xaa, 0xc5, 0x00, 0x20, 0xaf, 0x0b, 0x99, 0xa3); + +typedef struct _DSFXGargle +{ + DWORD dwRateHz; // Rate of modulation in hz + DWORD dwWaveShape; // DSFXGARGLE_WAVE_xxx +} DSFXGargle, *LPDSFXGargle; + +#define DSFXGARGLE_WAVE_TRIANGLE 0 +#define DSFXGARGLE_WAVE_SQUARE 1 + +typedef const DSFXGargle *LPCDSFXGargle; + +#define DSFXGARGLE_RATEHZ_MIN 1 +#define DSFXGARGLE_RATEHZ_MAX 1000 + +#undef INTERFACE +#define INTERFACE IDirectSoundFXGargle + +DECLARE_INTERFACE_(IDirectSoundFXGargle, IUnknown) +{ + // IUnknown methods + STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE; + STDMETHOD_(ULONG,AddRef) (THIS) PURE; + STDMETHOD_(ULONG,Release) (THIS) PURE; + + // IDirectSoundFXGargle methods + STDMETHOD(SetAllParameters) (THIS_ LPCDSFXGargle pcDsFxGargle) PURE; + STDMETHOD(GetAllParameters) (THIS_ LPDSFXGargle pDsFxGargle) PURE; +}; + +#define IDirectSoundFXGargle_QueryInterface(p,a,b) IUnknown_QueryInterface(p,a,b) +#define IDirectSoundFXGargle_AddRef(p) IUnknown_AddRef(p) +#define IDirectSoundFXGargle_Release(p) IUnknown_Release(p) + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectSoundFXGargle_SetAllParameters(p,a) (p)->lpVtbl->SetAllParameters(p,a) +#define IDirectSoundFXGargle_GetAllParameters(p,a) (p)->lpVtbl->GetAllParameters(p,a) +#else // !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectSoundFXGargle_SetAllParameters(p,a) (p)->SetAllParameters(a) +#define IDirectSoundFXGargle_GetAllParameters(p,a) (p)->GetAllParameters(a) +#endif // !defined(__cplusplus) || defined(CINTERFACE) + +// +// IDirectSoundFXChorus +// + +DEFINE_GUID(IID_IDirectSoundFXChorus, 0x880842e3, 0x145f, 0x43e6, 0xa9, 0x34, 0xa7, 0x18, 0x06, 0xe5, 0x05, 0x47); + +typedef struct _DSFXChorus +{ + FLOAT fWetDryMix; + FLOAT fDepth; + FLOAT fFeedback; + FLOAT fFrequency; + LONG lWaveform; // LFO shape; DSFXCHORUS_WAVE_xxx + FLOAT fDelay; + LONG lPhase; +} DSFXChorus, *LPDSFXChorus; + +typedef const DSFXChorus *LPCDSFXChorus; + +#define DSFXCHORUS_WAVE_TRIANGLE 0 +#define DSFXCHORUS_WAVE_SIN 1 + +#define DSFXCHORUS_WETDRYMIX_MIN 0.0f +#define DSFXCHORUS_WETDRYMIX_MAX 100.0f +#define DSFXCHORUS_DEPTH_MIN 0.0f +#define DSFXCHORUS_DEPTH_MAX 100.0f +#define DSFXCHORUS_FEEDBACK_MIN -99.0f +#define DSFXCHORUS_FEEDBACK_MAX 99.0f +#define DSFXCHORUS_FREQUENCY_MIN 0.0f +#define DSFXCHORUS_FREQUENCY_MAX 10.0f +#define DSFXCHORUS_DELAY_MIN 0.0f +#define DSFXCHORUS_DELAY_MAX 20.0f +#define DSFXCHORUS_PHASE_MIN 0 +#define DSFXCHORUS_PHASE_MAX 4 + +#define DSFXCHORUS_PHASE_NEG_180 0 +#define DSFXCHORUS_PHASE_NEG_90 1 +#define DSFXCHORUS_PHASE_ZERO 2 +#define DSFXCHORUS_PHASE_90 3 +#define DSFXCHORUS_PHASE_180 4 + +#undef INTERFACE +#define INTERFACE IDirectSoundFXChorus + +DECLARE_INTERFACE_(IDirectSoundFXChorus, IUnknown) +{ + // IUnknown methods + STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE; + STDMETHOD_(ULONG,AddRef) (THIS) PURE; + STDMETHOD_(ULONG,Release) (THIS) PURE; + + // IDirectSoundFXChorus methods + STDMETHOD(SetAllParameters) (THIS_ LPCDSFXChorus pcDsFxChorus) PURE; + STDMETHOD(GetAllParameters) (THIS_ LPDSFXChorus pDsFxChorus) PURE; +}; + +#define IDirectSoundFXChorus_QueryInterface(p,a,b) IUnknown_QueryInterface(p,a,b) +#define IDirectSoundFXChorus_AddRef(p) IUnknown_AddRef(p) +#define IDirectSoundFXChorus_Release(p) IUnknown_Release(p) + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectSoundFXChorus_SetAllParameters(p,a) (p)->lpVtbl->SetAllParameters(p,a) +#define IDirectSoundFXChorus_GetAllParameters(p,a) (p)->lpVtbl->GetAllParameters(p,a) +#else // !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectSoundFXChorus_SetAllParameters(p,a) (p)->SetAllParameters(a) +#define IDirectSoundFXChorus_GetAllParameters(p,a) (p)->GetAllParameters(a) +#endif // !defined(__cplusplus) || defined(CINTERFACE) + +// +// IDirectSoundFXFlanger +// + +DEFINE_GUID(IID_IDirectSoundFXFlanger, 0x903e9878, 0x2c92, 0x4072, 0x9b, 0x2c, 0xea, 0x68, 0xf5, 0x39, 0x67, 0x83); + +typedef struct _DSFXFlanger +{ + FLOAT fWetDryMix; + FLOAT fDepth; + FLOAT fFeedback; + FLOAT fFrequency; + LONG lWaveform; + FLOAT fDelay; + LONG lPhase; +} DSFXFlanger, *LPDSFXFlanger; + +typedef const DSFXFlanger *LPCDSFXFlanger; + +#define DSFXFLANGER_WAVE_TRIANGLE 0 +#define DSFXFLANGER_WAVE_SIN 1 + +#define DSFXFLANGER_WETDRYMIX_MIN 0.0f +#define DSFXFLANGER_WETDRYMIX_MAX 100.0f +#define DSFXFLANGER_FREQUENCY_MIN 0.0f +#define DSFXFLANGER_FREQUENCY_MAX 10.0f +#define DSFXFLANGER_DEPTH_MIN 0.0f +#define DSFXFLANGER_DEPTH_MAX 100.0f +#define DSFXFLANGER_PHASE_MIN 0 +#define DSFXFLANGER_PHASE_MAX 4 +#define DSFXFLANGER_FEEDBACK_MIN -99.0f +#define DSFXFLANGER_FEEDBACK_MAX 99.0f +#define DSFXFLANGER_DELAY_MIN 0.0f +#define DSFXFLANGER_DELAY_MAX 4.0f + +#define DSFXFLANGER_PHASE_NEG_180 0 +#define DSFXFLANGER_PHASE_NEG_90 1 +#define DSFXFLANGER_PHASE_ZERO 2 +#define DSFXFLANGER_PHASE_90 3 +#define DSFXFLANGER_PHASE_180 4 + +#undef INTERFACE +#define INTERFACE IDirectSoundFXFlanger + +DECLARE_INTERFACE_(IDirectSoundFXFlanger, IUnknown) +{ + // IUnknown methods + STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE; + STDMETHOD_(ULONG,AddRef) (THIS) PURE; + STDMETHOD_(ULONG,Release) (THIS) PURE; + + // IDirectSoundFXFlanger methods + STDMETHOD(SetAllParameters) (THIS_ LPCDSFXFlanger pcDsFxFlanger) PURE; + STDMETHOD(GetAllParameters) (THIS_ LPDSFXFlanger pDsFxFlanger) PURE; +}; + +#define IDirectSoundFXFlanger_QueryInterface(p,a,b) IUnknown_QueryInterface(p,a,b) +#define IDirectSoundFXFlanger_AddRef(p) IUnknown_AddRef(p) +#define IDirectSoundFXFlanger_Release(p) IUnknown_Release(p) + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectSoundFXFlanger_SetAllParameters(p,a) (p)->lpVtbl->SetAllParameters(p,a) +#define IDirectSoundFXFlanger_GetAllParameters(p,a) (p)->lpVtbl->GetAllParameters(p,a) +#else // !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectSoundFXFlanger_SetAllParameters(p,a) (p)->SetAllParameters(a) +#define IDirectSoundFXFlanger_GetAllParameters(p,a) (p)->GetAllParameters(a) +#endif // !defined(__cplusplus) || defined(CINTERFACE) + +// +// IDirectSoundFXEcho +// + +DEFINE_GUID(IID_IDirectSoundFXEcho, 0x8bd28edf, 0x50db, 0x4e92, 0xa2, 0xbd, 0x44, 0x54, 0x88, 0xd1, 0xed, 0x42); + +typedef struct _DSFXEcho +{ + FLOAT fWetDryMix; + FLOAT fFeedback; + FLOAT fLeftDelay; + FLOAT fRightDelay; + LONG lPanDelay; +} DSFXEcho, *LPDSFXEcho; + +typedef const DSFXEcho *LPCDSFXEcho; + +#define DSFXECHO_WETDRYMIX_MIN 0.0f +#define DSFXECHO_WETDRYMIX_MAX 100.0f +#define DSFXECHO_FEEDBACK_MIN 0.0f +#define DSFXECHO_FEEDBACK_MAX 100.0f +#define DSFXECHO_LEFTDELAY_MIN 1.0f +#define DSFXECHO_LEFTDELAY_MAX 2000.0f +#define DSFXECHO_RIGHTDELAY_MIN 1.0f +#define DSFXECHO_RIGHTDELAY_MAX 2000.0f +#define DSFXECHO_PANDELAY_MIN 0 +#define DSFXECHO_PANDELAY_MAX 1 + +#undef INTERFACE +#define INTERFACE IDirectSoundFXEcho + +DECLARE_INTERFACE_(IDirectSoundFXEcho, IUnknown) +{ + // IUnknown methods + STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE; + STDMETHOD_(ULONG,AddRef) (THIS) PURE; + STDMETHOD_(ULONG,Release) (THIS) PURE; + + // IDirectSoundFXEcho methods + STDMETHOD(SetAllParameters) (THIS_ LPCDSFXEcho pcDsFxEcho) PURE; + STDMETHOD(GetAllParameters) (THIS_ LPDSFXEcho pDsFxEcho) PURE; +}; + +#define IDirectSoundFXEcho_QueryInterface(p,a,b) IUnknown_QueryInterface(p,a,b) +#define IDirectSoundFXEcho_AddRef(p) IUnknown_AddRef(p) +#define IDirectSoundFXEcho_Release(p) IUnknown_Release(p) + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectSoundFXEcho_SetAllParameters(p,a) (p)->lpVtbl->SetAllParameters(p,a) +#define IDirectSoundFXEcho_GetAllParameters(p,a) (p)->lpVtbl->GetAllParameters(p,a) +#else // !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectSoundFXEcho_SetAllParameters(p,a) (p)->SetAllParameters(a) +#define IDirectSoundFXEcho_GetAllParameters(p,a) (p)->GetAllParameters(a) +#endif // !defined(__cplusplus) || defined(CINTERFACE) + +// +// IDirectSoundFXDistortion +// + +DEFINE_GUID(IID_IDirectSoundFXDistortion, 0x8ecf4326, 0x455f, 0x4d8b, 0xbd, 0xa9, 0x8d, 0x5d, 0x3e, 0x9e, 0x3e, 0x0b); + +typedef struct _DSFXDistortion +{ + FLOAT fGain; + FLOAT fEdge; + FLOAT fPostEQCenterFrequency; + FLOAT fPostEQBandwidth; + FLOAT fPreLowpassCutoff; +} DSFXDistortion, *LPDSFXDistortion; + +typedef const DSFXDistortion *LPCDSFXDistortion; + +#define DSFXDISTORTION_GAIN_MIN -60.0f +#define DSFXDISTORTION_GAIN_MAX 0.0f +#define DSFXDISTORTION_EDGE_MIN 0.0f +#define DSFXDISTORTION_EDGE_MAX 100.0f +#define DSFXDISTORTION_POSTEQCENTERFREQUENCY_MIN 100.0f +#define DSFXDISTORTION_POSTEQCENTERFREQUENCY_MAX 8000.0f +#define DSFXDISTORTION_POSTEQBANDWIDTH_MIN 100.0f +#define DSFXDISTORTION_POSTEQBANDWIDTH_MAX 8000.0f +#define DSFXDISTORTION_PRELOWPASSCUTOFF_MIN 100.0f +#define DSFXDISTORTION_PRELOWPASSCUTOFF_MAX 8000.0f + +#undef INTERFACE +#define INTERFACE IDirectSoundFXDistortion + +DECLARE_INTERFACE_(IDirectSoundFXDistortion, IUnknown) +{ + // IUnknown methods + STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE; + STDMETHOD_(ULONG,AddRef) (THIS) PURE; + STDMETHOD_(ULONG,Release) (THIS) PURE; + + // IDirectSoundFXDistortion methods + STDMETHOD(SetAllParameters) (THIS_ LPCDSFXDistortion pcDsFxDistortion) PURE; + STDMETHOD(GetAllParameters) (THIS_ LPDSFXDistortion pDsFxDistortion) PURE; +}; + +#define IDirectSoundFXDistortion_QueryInterface(p,a,b) IUnknown_QueryInterface(p,a,b) +#define IDirectSoundFXDistortion_AddRef(p) IUnknown_AddRef(p) +#define IDirectSoundFXDistortion_Release(p) IUnknown_Release(p) + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectSoundFXDistortion_SetAllParameters(p,a) (p)->lpVtbl->SetAllParameters(p,a) +#define IDirectSoundFXDistortion_GetAllParameters(p,a) (p)->lpVtbl->GetAllParameters(p,a) +#else // !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectSoundFXDistortion_SetAllParameters(p,a) (p)->SetAllParameters(a) +#define IDirectSoundFXDistortion_GetAllParameters(p,a) (p)->GetAllParameters(a) +#endif // !defined(__cplusplus) || defined(CINTERFACE) + +// +// IDirectSoundFXCompressor +// + +DEFINE_GUID(IID_IDirectSoundFXCompressor, 0x4bbd1154, 0x62f6, 0x4e2c, 0xa1, 0x5c, 0xd3, 0xb6, 0xc4, 0x17, 0xf7, 0xa0); + +typedef struct _DSFXCompressor +{ + FLOAT fGain; + FLOAT fAttack; + FLOAT fRelease; + FLOAT fThreshold; + FLOAT fRatio; + FLOAT fPredelay; +} DSFXCompressor, *LPDSFXCompressor; + +typedef const DSFXCompressor *LPCDSFXCompressor; + +#define DSFXCOMPRESSOR_GAIN_MIN -60.0f +#define DSFXCOMPRESSOR_GAIN_MAX 60.0f +#define DSFXCOMPRESSOR_ATTACK_MIN 0.01f +#define DSFXCOMPRESSOR_ATTACK_MAX 500.0f +#define DSFXCOMPRESSOR_RELEASE_MIN 50.0f +#define DSFXCOMPRESSOR_RELEASE_MAX 3000.0f +#define DSFXCOMPRESSOR_THRESHOLD_MIN -60.0f +#define DSFXCOMPRESSOR_THRESHOLD_MAX 0.0f +#define DSFXCOMPRESSOR_RATIO_MIN 1.0f +#define DSFXCOMPRESSOR_RATIO_MAX 100.0f +#define DSFXCOMPRESSOR_PREDELAY_MIN 0.0f +#define DSFXCOMPRESSOR_PREDELAY_MAX 4.0f + +#undef INTERFACE +#define INTERFACE IDirectSoundFXCompressor + +DECLARE_INTERFACE_(IDirectSoundFXCompressor, IUnknown) +{ + // IUnknown methods + STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE; + STDMETHOD_(ULONG,AddRef) (THIS) PURE; + STDMETHOD_(ULONG,Release) (THIS) PURE; + + // IDirectSoundFXCompressor methods + STDMETHOD(SetAllParameters) (THIS_ LPCDSFXCompressor pcDsFxCompressor) PURE; + STDMETHOD(GetAllParameters) (THIS_ LPDSFXCompressor pDsFxCompressor) PURE; +}; + +#define IDirectSoundFXCompressor_QueryInterface(p,a,b) IUnknown_QueryInterface(p,a,b) +#define IDirectSoundFXCompressor_AddRef(p) IUnknown_AddRef(p) +#define IDirectSoundFXCompressor_Release(p) IUnknown_Release(p) + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectSoundFXCompressor_SetAllParameters(p,a) (p)->lpVtbl->SetAllParameters(p,a) +#define IDirectSoundFXCompressor_GetAllParameters(p,a) (p)->lpVtbl->GetAllParameters(p,a) +#else // !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectSoundFXCompressor_SetAllParameters(p,a) (p)->SetAllParameters(a) +#define IDirectSoundFXCompressor_GetAllParameters(p,a) (p)->GetAllParameters(a) +#endif // !defined(__cplusplus) || defined(CINTERFACE) + +// +// IDirectSoundFXParamEq +// + +DEFINE_GUID(IID_IDirectSoundFXParamEq, 0xc03ca9fe, 0xfe90, 0x4204, 0x80, 0x78, 0x82, 0x33, 0x4c, 0xd1, 0x77, 0xda); + +typedef struct _DSFXParamEq +{ + FLOAT fCenter; + FLOAT fBandwidth; + FLOAT fGain; +} DSFXParamEq, *LPDSFXParamEq; + +typedef const DSFXParamEq *LPCDSFXParamEq; + +#define DSFXPARAMEQ_CENTER_MIN 80.0f +#define DSFXPARAMEQ_CENTER_MAX 16000.0f +#define DSFXPARAMEQ_BANDWIDTH_MIN 1.0f +#define DSFXPARAMEQ_BANDWIDTH_MAX 36.0f +#define DSFXPARAMEQ_GAIN_MIN -15.0f +#define DSFXPARAMEQ_GAIN_MAX 15.0f + +#undef INTERFACE +#define INTERFACE IDirectSoundFXParamEq + +DECLARE_INTERFACE_(IDirectSoundFXParamEq, IUnknown) +{ + // IUnknown methods + STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE; + STDMETHOD_(ULONG,AddRef) (THIS) PURE; + STDMETHOD_(ULONG,Release) (THIS) PURE; + + // IDirectSoundFXParamEq methods + STDMETHOD(SetAllParameters) (THIS_ LPCDSFXParamEq pcDsFxParamEq) PURE; + STDMETHOD(GetAllParameters) (THIS_ LPDSFXParamEq pDsFxParamEq) PURE; +}; + +#define IDirectSoundFXParamEq_QueryInterface(p,a,b) IUnknown_QueryInterface(p,a,b) +#define IDirectSoundFXParamEq_AddRef(p) IUnknown_AddRef(p) +#define IDirectSoundFXParamEq_Release(p) IUnknown_Release(p) + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectSoundFXParamEq_SetAllParameters(p,a) (p)->lpVtbl->SetAllParameters(p,a) +#define IDirectSoundFXParamEq_GetAllParameters(p,a) (p)->lpVtbl->GetAllParameters(p,a) +#else // !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectSoundFXParamEq_SetAllParameters(p,a) (p)->SetAllParameters(a) +#define IDirectSoundFXParamEq_GetAllParameters(p,a) (p)->GetAllParameters(a) +#endif // !defined(__cplusplus) || defined(CINTERFACE) + +// +// IDirectSoundFXI3DL2Reverb +// + +DEFINE_GUID(IID_IDirectSoundFXI3DL2Reverb, 0x4b166a6a, 0x0d66, 0x43f3, 0x80, 0xe3, 0xee, 0x62, 0x80, 0xde, 0xe1, 0xa4); + +typedef struct _DSFXI3DL2Reverb +{ + LONG lRoom; // [-10000, 0] default: -1000 mB + LONG lRoomHF; // [-10000, 0] default: 0 mB + FLOAT flRoomRolloffFactor; // [0.0, 10.0] default: 0.0 + FLOAT flDecayTime; // [0.1, 20.0] default: 1.49s + FLOAT flDecayHFRatio; // [0.1, 2.0] default: 0.83 + LONG lReflections; // [-10000, 1000] default: -2602 mB + FLOAT flReflectionsDelay; // [0.0, 0.3] default: 0.007 s + LONG lReverb; // [-10000, 2000] default: 200 mB + FLOAT flReverbDelay; // [0.0, 0.1] default: 0.011 s + FLOAT flDiffusion; // [0.0, 100.0] default: 100.0 % + FLOAT flDensity; // [0.0, 100.0] default: 100.0 % + FLOAT flHFReference; // [20.0, 20000.0] default: 5000.0 Hz +} DSFXI3DL2Reverb, *LPDSFXI3DL2Reverb; + +typedef const DSFXI3DL2Reverb *LPCDSFXI3DL2Reverb; + +#define DSFX_I3DL2REVERB_ROOM_MIN (-10000) +#define DSFX_I3DL2REVERB_ROOM_MAX 0 +#define DSFX_I3DL2REVERB_ROOM_DEFAULT (-1000) + +#define DSFX_I3DL2REVERB_ROOMHF_MIN (-10000) +#define DSFX_I3DL2REVERB_ROOMHF_MAX 0 +#define DSFX_I3DL2REVERB_ROOMHF_DEFAULT (-100) + +#define DSFX_I3DL2REVERB_ROOMROLLOFFFACTOR_MIN 0.0f +#define DSFX_I3DL2REVERB_ROOMROLLOFFFACTOR_MAX 10.0f +#define DSFX_I3DL2REVERB_ROOMROLLOFFFACTOR_DEFAULT 0.0f + +#define DSFX_I3DL2REVERB_DECAYTIME_MIN 0.1f +#define DSFX_I3DL2REVERB_DECAYTIME_MAX 20.0f +#define DSFX_I3DL2REVERB_DECAYTIME_DEFAULT 1.49f + +#define DSFX_I3DL2REVERB_DECAYHFRATIO_MIN 0.1f +#define DSFX_I3DL2REVERB_DECAYHFRATIO_MAX 2.0f +#define DSFX_I3DL2REVERB_DECAYHFRATIO_DEFAULT 0.83f + +#define DSFX_I3DL2REVERB_REFLECTIONS_MIN (-10000) +#define DSFX_I3DL2REVERB_REFLECTIONS_MAX 1000 +#define DSFX_I3DL2REVERB_REFLECTIONS_DEFAULT (-2602) + +#define DSFX_I3DL2REVERB_REFLECTIONSDELAY_MIN 0.0f +#define DSFX_I3DL2REVERB_REFLECTIONSDELAY_MAX 0.3f +#define DSFX_I3DL2REVERB_REFLECTIONSDELAY_DEFAULT 0.007f + +#define DSFX_I3DL2REVERB_REVERB_MIN (-10000) +#define DSFX_I3DL2REVERB_REVERB_MAX 2000 +#define DSFX_I3DL2REVERB_REVERB_DEFAULT (200) + +#define DSFX_I3DL2REVERB_REVERBDELAY_MIN 0.0f +#define DSFX_I3DL2REVERB_REVERBDELAY_MAX 0.1f +#define DSFX_I3DL2REVERB_REVERBDELAY_DEFAULT 0.011f + +#define DSFX_I3DL2REVERB_DIFFUSION_MIN 0.0f +#define DSFX_I3DL2REVERB_DIFFUSION_MAX 100.0f +#define DSFX_I3DL2REVERB_DIFFUSION_DEFAULT 100.0f + +#define DSFX_I3DL2REVERB_DENSITY_MIN 0.0f +#define DSFX_I3DL2REVERB_DENSITY_MAX 100.0f +#define DSFX_I3DL2REVERB_DENSITY_DEFAULT 100.0f + +#define DSFX_I3DL2REVERB_HFREFERENCE_MIN 20.0f +#define DSFX_I3DL2REVERB_HFREFERENCE_MAX 20000.0f +#define DSFX_I3DL2REVERB_HFREFERENCE_DEFAULT 5000.0f + +#define DSFX_I3DL2REVERB_QUALITY_MIN 0 +#define DSFX_I3DL2REVERB_QUALITY_MAX 3 +#define DSFX_I3DL2REVERB_QUALITY_DEFAULT 2 + +#undef INTERFACE +#define INTERFACE IDirectSoundFXI3DL2Reverb + +DECLARE_INTERFACE_(IDirectSoundFXI3DL2Reverb, IUnknown) +{ + // IUnknown methods + STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE; + STDMETHOD_(ULONG,AddRef) (THIS) PURE; + STDMETHOD_(ULONG,Release) (THIS) PURE; + + // IDirectSoundFXI3DL2Reverb methods + STDMETHOD(SetAllParameters) (THIS_ LPCDSFXI3DL2Reverb pcDsFxI3DL2Reverb) PURE; + STDMETHOD(GetAllParameters) (THIS_ LPDSFXI3DL2Reverb pDsFxI3DL2Reverb) PURE; + STDMETHOD(SetPreset) (THIS_ DWORD dwPreset) PURE; + STDMETHOD(GetPreset) (THIS_ LPDWORD pdwPreset) PURE; + STDMETHOD(SetQuality) (THIS_ LONG lQuality) PURE; + STDMETHOD(GetQuality) (THIS_ LONG *plQuality) PURE; +}; + +#define IDirectSoundFXI3DL2Reverb_QueryInterface(p,a,b) IUnknown_QueryInterface(p,a,b) +#define IDirectSoundFXI3DL2Reverb_AddRef(p) IUnknown_AddRef(p) +#define IDirectSoundFXI3DL2Reverb_Release(p) IUnknown_Release(p) + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectSoundFXI3DL2Reverb_SetAllParameters(p,a) (p)->lpVtbl->SetAllParameters(p,a) +#define IDirectSoundFXI3DL2Reverb_GetAllParameters(p,a) (p)->lpVtbl->GetAllParameters(p,a) +#define IDirectSoundFXI3DL2Reverb_SetPreset(p,a) (p)->lpVtbl->SetPreset(p,a) +#define IDirectSoundFXI3DL2Reverb_GetPreset(p,a) (p)->lpVtbl->GetPreset(p,a) +#else // !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectSoundFXI3DL2Reverb_SetAllParameters(p,a) (p)->SetAllParameters(a) +#define IDirectSoundFXI3DL2Reverb_GetAllParameters(p,a) (p)->GetAllParameters(a) +#define IDirectSoundFXI3DL2Reverb_SetPreset(p,a) (p)->SetPreset(a) +#define IDirectSoundFXI3DL2Reverb_GetPreset(p,a) (p)->GetPreset(a) +#endif // !defined(__cplusplus) || defined(CINTERFACE) + +// +// IDirectSoundFXWavesReverb +// + +DEFINE_GUID(IID_IDirectSoundFXWavesReverb,0x46858c3a,0x0dc6,0x45e3,0xb7,0x60,0xd4,0xee,0xf1,0x6c,0xb3,0x25); + +typedef struct _DSFXWavesReverb +{ + FLOAT fInGain; // [-96.0,0.0] default: 0.0 dB + FLOAT fReverbMix; // [-96.0,0.0] default: 0.0 db + FLOAT fReverbTime; // [0.001,3000.0] default: 1000.0 ms + FLOAT fHighFreqRTRatio; // [0.001,0.999] default: 0.001 +} DSFXWavesReverb, *LPDSFXWavesReverb; + +typedef const DSFXWavesReverb *LPCDSFXWavesReverb; + +#define DSFX_WAVESREVERB_INGAIN_MIN -96.0f +#define DSFX_WAVESREVERB_INGAIN_MAX 0.0f +#define DSFX_WAVESREVERB_INGAIN_DEFAULT 0.0f +#define DSFX_WAVESREVERB_REVERBMIX_MIN -96.0f +#define DSFX_WAVESREVERB_REVERBMIX_MAX 0.0f +#define DSFX_WAVESREVERB_REVERBMIX_DEFAULT 0.0f +#define DSFX_WAVESREVERB_REVERBTIME_MIN 0.001f +#define DSFX_WAVESREVERB_REVERBTIME_MAX 3000.0f +#define DSFX_WAVESREVERB_REVERBTIME_DEFAULT 1000.0f +#define DSFX_WAVESREVERB_HIGHFREQRTRATIO_MIN 0.001f +#define DSFX_WAVESREVERB_HIGHFREQRTRATIO_MAX 0.999f +#define DSFX_WAVESREVERB_HIGHFREQRTRATIO_DEFAULT 0.001f + +#undef INTERFACE +#define INTERFACE IDirectSoundFXWavesReverb + +DECLARE_INTERFACE_(IDirectSoundFXWavesReverb, IUnknown) +{ + // IUnknown methods + STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE; + STDMETHOD_(ULONG,AddRef) (THIS) PURE; + STDMETHOD_(ULONG,Release) (THIS) PURE; + + // IDirectSoundFXWavesReverb methods + STDMETHOD(SetAllParameters) (THIS_ LPCDSFXWavesReverb pcDsFxWavesReverb) PURE; + STDMETHOD(GetAllParameters) (THIS_ LPDSFXWavesReverb pDsFxWavesReverb) PURE; +}; + +#define IDirectSoundFXWavesReverb_QueryInterface(p,a,b) IUnknown_QueryInterface(p,a,b) +#define IDirectSoundFXWavesReverb_AddRef(p) IUnknown_AddRef(p) +#define IDirectSoundFXWavesReverb_Release(p) IUnknown_Release(p) + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectSoundFXWavesReverb_SetAllParameters(p,a) (p)->lpVtbl->SetAllParameters(p,a) +#define IDirectSoundFXWavesReverb_GetAllParameters(p,a) (p)->lpVtbl->GetAllParameters(p,a) +#else // !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectSoundFXWavesReverb_SetAllParameters(p,a) (p)->SetAllParameters(a) +#define IDirectSoundFXWavesReverb_GetAllParameters(p,a) (p)->GetAllParameters(a) +#endif // !defined(__cplusplus) || defined(CINTERFACE) + +// +// IDirectSoundCaptureFXAec +// + +DEFINE_GUID(IID_IDirectSoundCaptureFXAec, 0xad74143d, 0x903d, 0x4ab7, 0x80, 0x66, 0x28, 0xd3, 0x63, 0x03, 0x6d, 0x65); + +typedef struct _DSCFXAec +{ + BOOL fEnable; + BOOL fNoiseFill; + DWORD dwMode; +} DSCFXAec, *LPDSCFXAec; + +typedef const DSCFXAec *LPCDSCFXAec; + +// These match the AEC_MODE_* constants in the DDK's ksmedia.h file +#define DSCFX_AEC_MODE_PASS_THROUGH 0x0 +#define DSCFX_AEC_MODE_HALF_DUPLEX 0x1 +#define DSCFX_AEC_MODE_FULL_DUPLEX 0x2 + +// These match the AEC_STATUS_* constants in ksmedia.h +#define DSCFX_AEC_STATUS_HISTORY_UNINITIALIZED 0x0 +#define DSCFX_AEC_STATUS_HISTORY_CONTINUOUSLY_CONVERGED 0x1 +#define DSCFX_AEC_STATUS_HISTORY_PREVIOUSLY_DIVERGED 0x2 +#define DSCFX_AEC_STATUS_CURRENTLY_CONVERGED 0x8 + +#undef INTERFACE +#define INTERFACE IDirectSoundCaptureFXAec + +DECLARE_INTERFACE_(IDirectSoundCaptureFXAec, IUnknown) +{ + // IUnknown methods + STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE; + STDMETHOD_(ULONG,AddRef) (THIS) PURE; + STDMETHOD_(ULONG,Release) (THIS) PURE; + + // IDirectSoundCaptureFXAec methods + STDMETHOD(SetAllParameters) (THIS_ LPCDSCFXAec pDscFxAec) PURE; + STDMETHOD(GetAllParameters) (THIS_ LPDSCFXAec pDscFxAec) PURE; + STDMETHOD(GetStatus) (THIS_ PDWORD pdwStatus) PURE; + STDMETHOD(Reset) (THIS) PURE; +}; + +#define IDirectSoundCaptureFXAec_QueryInterface(p,a,b) IUnknown_QueryInterface(p,a,b) +#define IDirectSoundCaptureFXAec_AddRef(p) IUnknown_AddRef(p) +#define IDirectSoundCaptureFXAec_Release(p) IUnknown_Release(p) + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectSoundCaptureFXAec_SetAllParameters(p,a) (p)->lpVtbl->SetAllParameters(p,a) +#define IDirectSoundCaptureFXAec_GetAllParameters(p,a) (p)->lpVtbl->GetAllParameters(p,a) +#else // !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectSoundCaptureFXAec_SetAllParameters(p,a) (p)->SetAllParameters(a) +#define IDirectSoundCaptureFXAec_GetAllParameters(p,a) (p)->GetAllParameters(a) +#endif // !defined(__cplusplus) || defined(CINTERFACE) + + +// +// IDirectSoundCaptureFXNoiseSuppress +// + +DEFINE_GUID(IID_IDirectSoundCaptureFXNoiseSuppress, 0xed311e41, 0xfbae, 0x4175, 0x96, 0x25, 0xcd, 0x8, 0x54, 0xf6, 0x93, 0xca); + +typedef struct _DSCFXNoiseSuppress +{ + BOOL fEnable; +} DSCFXNoiseSuppress, *LPDSCFXNoiseSuppress; + +typedef const DSCFXNoiseSuppress *LPCDSCFXNoiseSuppress; + +#undef INTERFACE +#define INTERFACE IDirectSoundCaptureFXNoiseSuppress + +DECLARE_INTERFACE_(IDirectSoundCaptureFXNoiseSuppress, IUnknown) +{ + // IUnknown methods + STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE; + STDMETHOD_(ULONG,AddRef) (THIS) PURE; + STDMETHOD_(ULONG,Release) (THIS) PURE; + + // IDirectSoundCaptureFXNoiseSuppress methods + STDMETHOD(SetAllParameters) (THIS_ LPCDSCFXNoiseSuppress pcDscFxNoiseSuppress) PURE; + STDMETHOD(GetAllParameters) (THIS_ LPDSCFXNoiseSuppress pDscFxNoiseSuppress) PURE; + STDMETHOD(Reset) (THIS) PURE; +}; + +#define IDirectSoundCaptureFXNoiseSuppress_QueryInterface(p,a,b) IUnknown_QueryInterface(p,a,b) +#define IDirectSoundCaptureFXNoiseSuppress_AddRef(p) IUnknown_AddRef(p) +#define IDirectSoundCaptureFXNoiseSuppress_Release(p) IUnknown_Release(p) + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectSoundCaptureFXNoiseSuppress_SetAllParameters(p,a) (p)->lpVtbl->SetAllParameters(p,a) +#define IDirectSoundCaptureFXNoiseSuppress_GetAllParameters(p,a) (p)->lpVtbl->GetAllParameters(p,a) +#else // !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectSoundCaptureFXNoiseSuppress_SetAllParameters(p,a) (p)->SetAllParameters(a) +#define IDirectSoundCaptureFXNoiseSuppress_GetAllParameters(p,a) (p)->GetAllParameters(a) +#endif // !defined(__cplusplus) || defined(CINTERFACE) + + +// +// IDirectSoundFullDuplex +// + +#ifndef _IDirectSoundFullDuplex_ +#define _IDirectSoundFullDuplex_ + +#ifdef __cplusplus +// 'struct' not 'class' per the way DECLARE_INTERFACE_ is defined +struct IDirectSoundFullDuplex; +#endif // __cplusplus + +typedef struct IDirectSoundFullDuplex *LPDIRECTSOUNDFULLDUPLEX; + +DEFINE_GUID(IID_IDirectSoundFullDuplex, 0xedcb4c7a, 0xdaab, 0x4216, 0xa4, 0x2e, 0x6c, 0x50, 0x59, 0x6d, 0xdc, 0x1d); + +#undef INTERFACE +#define INTERFACE IDirectSoundFullDuplex + +DECLARE_INTERFACE_(IDirectSoundFullDuplex, IUnknown) +{ + // IUnknown methods + STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE; + STDMETHOD_(ULONG,AddRef) (THIS) PURE; + STDMETHOD_(ULONG,Release) (THIS) PURE; + + // IDirectSoundFullDuplex methods + STDMETHOD(Initialize) (THIS_ LPCGUID pCaptureGuid, LPCGUID pRenderGuid, LPCDSCBUFFERDESC lpDscBufferDesc, LPCDSBUFFERDESC lpDsBufferDesc, HWND hWnd, DWORD dwLevel, LPLPDIRECTSOUNDCAPTUREBUFFER8 lplpDirectSoundCaptureBuffer8, LPLPDIRECTSOUNDBUFFER8 lplpDirectSoundBuffer8) PURE; +}; + +#define IDirectSoundFullDuplex_QueryInterface(p,a,b) IUnknown_QueryInterface(p,a,b) +#define IDirectSoundFullDuplex_AddRef(p) IUnknown_AddRef(p) +#define IDirectSoundFullDuplex_Release(p) IUnknown_Release(p) + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectSoundFullDuplex_Initialize(p,a,b,c,d,e,f,g,h) (p)->lpVtbl->Initialize(p,a,b,c,d,e,f,g,h) +#else // !defined(__cplusplus) || defined(CINTERFACE) +#define IDirectSoundFullDuplex_Initialize(p,a,b,c,d,e,f,g,h) (p)->Initialize(a,b,c,d,e,f,g,h) +#endif // !defined(__cplusplus) || defined(CINTERFACE) + +#endif // _IDirectSoundFullDuplex_ + +#endif // DIRECTSOUND_VERSION >= 0x0800 + +// +// Return Codes +// + +// The function completed successfully +#define DS_OK S_OK + +// The call succeeded, but we had to substitute the 3D algorithm +#define DS_NO_VIRTUALIZATION MAKE_HRESULT(0, _FACDS, 10) + +// The call failed because resources (such as a priority level) +// were already being used by another caller +#define DSERR_ALLOCATED MAKE_DSHRESULT(10) + +// The control (vol, pan, etc.) requested by the caller is not available +#define DSERR_CONTROLUNAVAIL MAKE_DSHRESULT(30) + +// An invalid parameter was passed to the returning function +#define DSERR_INVALIDPARAM E_INVALIDARG + +// This call is not valid for the current state of this object +#define DSERR_INVALIDCALL MAKE_DSHRESULT(50) + +// An undetermined error occurred inside the DirectSound subsystem +#define DSERR_GENERIC E_FAIL + +// The caller does not have the priority level required for the function to +// succeed +#define DSERR_PRIOLEVELNEEDED MAKE_DSHRESULT(70) + +// Not enough free memory is available to complete the operation +#define DSERR_OUTOFMEMORY E_OUTOFMEMORY + +// The specified WAVE format is not supported +#define DSERR_BADFORMAT MAKE_DSHRESULT(100) + +// The function called is not supported at this time +#define DSERR_UNSUPPORTED E_NOTIMPL + +// No sound driver is available for use +#define DSERR_NODRIVER MAKE_DSHRESULT(120) + +// This object is already initialized +#define DSERR_ALREADYINITIALIZED MAKE_DSHRESULT(130) + +// This object does not support aggregation +#define DSERR_NOAGGREGATION CLASS_E_NOAGGREGATION + +// The buffer memory has been lost, and must be restored +#define DSERR_BUFFERLOST MAKE_DSHRESULT(150) + +// Another app has a higher priority level, preventing this call from +// succeeding +#define DSERR_OTHERAPPHASPRIO MAKE_DSHRESULT(160) + +// This object has not been initialized +#define DSERR_UNINITIALIZED MAKE_DSHRESULT(170) + +// The requested COM interface is not available +#define DSERR_NOINTERFACE E_NOINTERFACE + +// Access is denied +#define DSERR_ACCESSDENIED E_ACCESSDENIED + +// Tried to create a DSBCAPS_CTRLFX buffer shorter than DSBSIZE_FX_MIN milliseconds +#define DSERR_BUFFERTOOSMALL MAKE_DSHRESULT(180) + +// Attempt to use DirectSound 8 functionality on an older DirectSound object +#define DSERR_DS8_REQUIRED MAKE_DSHRESULT(190) + +// A circular loop of send effects was detected +#define DSERR_SENDLOOP MAKE_DSHRESULT(200) + +// The GUID specified in an audiopath file does not match a valid MIXIN buffer +#define DSERR_BADSENDBUFFERGUID MAKE_DSHRESULT(210) + +// The object requested was not found (numerically equal to DMUS_E_NOT_FOUND) +#define DSERR_OBJECTNOTFOUND MAKE_DSHRESULT(4449) + +// The effects requested could not be found on the system, or they were found +// but in the wrong order, or in the wrong hardware/software locations. +#define DSERR_FXUNAVAILABLE MAKE_DSHRESULT(220) + +// +// Flags +// + +#define DSCAPS_PRIMARYMONO 0x00000001 +#define DSCAPS_PRIMARYSTEREO 0x00000002 +#define DSCAPS_PRIMARY8BIT 0x00000004 +#define DSCAPS_PRIMARY16BIT 0x00000008 +#define DSCAPS_CONTINUOUSRATE 0x00000010 +#define DSCAPS_EMULDRIVER 0x00000020 +#define DSCAPS_CERTIFIED 0x00000040 +#define DSCAPS_SECONDARYMONO 0x00000100 +#define DSCAPS_SECONDARYSTEREO 0x00000200 +#define DSCAPS_SECONDARY8BIT 0x00000400 +#define DSCAPS_SECONDARY16BIT 0x00000800 + +#define DSSCL_NORMAL 0x00000001 +#define DSSCL_PRIORITY 0x00000002 +#define DSSCL_EXCLUSIVE 0x00000003 +#define DSSCL_WRITEPRIMARY 0x00000004 + +#define DSSPEAKER_DIRECTOUT 0x00000000 +#define DSSPEAKER_HEADPHONE 0x00000001 +#define DSSPEAKER_MONO 0x00000002 +#define DSSPEAKER_QUAD 0x00000003 +#define DSSPEAKER_STEREO 0x00000004 +#define DSSPEAKER_SURROUND 0x00000005 +#define DSSPEAKER_5POINT1 0x00000006 +#define DSSPEAKER_7POINT1 0x00000007 + +#define DSSPEAKER_GEOMETRY_MIN 0x00000005 // 5 degrees +#define DSSPEAKER_GEOMETRY_NARROW 0x0000000A // 10 degrees +#define DSSPEAKER_GEOMETRY_WIDE 0x00000014 // 20 degrees +#define DSSPEAKER_GEOMETRY_MAX 0x000000B4 // 180 degrees + +#define DSSPEAKER_COMBINED(c, g) ((DWORD)(((BYTE)(c)) | ((DWORD)((BYTE)(g))) << 16)) +#define DSSPEAKER_CONFIG(a) ((BYTE)(a)) +#define DSSPEAKER_GEOMETRY(a) ((BYTE)(((DWORD)(a) >> 16) & 0x00FF)) + +#define DSBCAPS_PRIMARYBUFFER 0x00000001 +#define DSBCAPS_STATIC 0x00000002 +#define DSBCAPS_LOCHARDWARE 0x00000004 +#define DSBCAPS_LOCSOFTWARE 0x00000008 +#define DSBCAPS_CTRL3D 0x00000010 +#define DSBCAPS_CTRLFREQUENCY 0x00000020 +#define DSBCAPS_CTRLPAN 0x00000040 +#define DSBCAPS_CTRLVOLUME 0x00000080 +#define DSBCAPS_CTRLPOSITIONNOTIFY 0x00000100 +#define DSBCAPS_CTRLFX 0x00000200 +#define DSBCAPS_STICKYFOCUS 0x00004000 +#define DSBCAPS_GLOBALFOCUS 0x00008000 +#define DSBCAPS_GETCURRENTPOSITION2 0x00010000 +#define DSBCAPS_MUTE3DATMAXDISTANCE 0x00020000 +#define DSBCAPS_LOCDEFER 0x00040000 + +#define DSBPLAY_LOOPING 0x00000001 +#define DSBPLAY_LOCHARDWARE 0x00000002 +#define DSBPLAY_LOCSOFTWARE 0x00000004 +#define DSBPLAY_TERMINATEBY_TIME 0x00000008 +#define DSBPLAY_TERMINATEBY_DISTANCE 0x000000010 +#define DSBPLAY_TERMINATEBY_PRIORITY 0x000000020 + +#define DSBSTATUS_PLAYING 0x00000001 +#define DSBSTATUS_BUFFERLOST 0x00000002 +#define DSBSTATUS_LOOPING 0x00000004 +#define DSBSTATUS_LOCHARDWARE 0x00000008 +#define DSBSTATUS_LOCSOFTWARE 0x00000010 +#define DSBSTATUS_TERMINATED 0x00000020 + +#define DSBLOCK_FROMWRITECURSOR 0x00000001 +#define DSBLOCK_ENTIREBUFFER 0x00000002 + +#define DSBFREQUENCY_ORIGINAL 0 +#define DSBFREQUENCY_MIN 100 +#if DIRECTSOUND_VERSION >= 0x0900 +#define DSBFREQUENCY_MAX 200000 +#else +#define DSBFREQUENCY_MAX 100000 +#endif + +#define DSBPAN_LEFT -10000 +#define DSBPAN_CENTER 0 +#define DSBPAN_RIGHT 10000 + +#define DSBVOLUME_MIN -10000 +#define DSBVOLUME_MAX 0 + +#define DSBSIZE_MIN 4 +#define DSBSIZE_MAX 0x0FFFFFFF +#define DSBSIZE_FX_MIN 150 // NOTE: Milliseconds, not bytes + +#define DS3DMODE_NORMAL 0x00000000 +#define DS3DMODE_HEADRELATIVE 0x00000001 +#define DS3DMODE_DISABLE 0x00000002 + +#define DS3D_IMMEDIATE 0x00000000 +#define DS3D_DEFERRED 0x00000001 + +#define DS3D_MINDISTANCEFACTOR FLT_MIN +#define DS3D_MAXDISTANCEFACTOR FLT_MAX +#define DS3D_DEFAULTDISTANCEFACTOR 1.0f + +#define DS3D_MINROLLOFFFACTOR 0.0f +#define DS3D_MAXROLLOFFFACTOR 10.0f +#define DS3D_DEFAULTROLLOFFFACTOR 1.0f + +#define DS3D_MINDOPPLERFACTOR 0.0f +#define DS3D_MAXDOPPLERFACTOR 10.0f +#define DS3D_DEFAULTDOPPLERFACTOR 1.0f + +#define DS3D_DEFAULTMINDISTANCE 1.0f +#define DS3D_DEFAULTMAXDISTANCE 1000000000.0f + +#define DS3D_MINCONEANGLE 0 +#define DS3D_MAXCONEANGLE 360 +#define DS3D_DEFAULTCONEANGLE 360 + +#define DS3D_DEFAULTCONEOUTSIDEVOLUME DSBVOLUME_MAX + +// IDirectSoundCapture attributes + +#define DSCCAPS_EMULDRIVER DSCAPS_EMULDRIVER +#define DSCCAPS_CERTIFIED DSCAPS_CERTIFIED +#define DSCCAPS_MULTIPLECAPTURE 0x00000001 + +// IDirectSoundCaptureBuffer attributes + +#define DSCBCAPS_WAVEMAPPED 0x80000000 + +#if DIRECTSOUND_VERSION >= 0x0800 +#define DSCBCAPS_CTRLFX 0x00000200 +#endif + + +#define DSCBLOCK_ENTIREBUFFER 0x00000001 + +#define DSCBSTATUS_CAPTURING 0x00000001 +#define DSCBSTATUS_LOOPING 0x00000002 + +#define DSCBSTART_LOOPING 0x00000001 + +#define DSBPN_OFFSETSTOP 0xFFFFFFFF + +#define DS_CERTIFIED 0x00000000 +#define DS_UNCERTIFIED 0x00000001 + + +// +// Flags for the I3DL2 effects +// + +// +// I3DL2 Material Presets +// + +enum +{ + DSFX_I3DL2_MATERIAL_PRESET_SINGLEWINDOW, + DSFX_I3DL2_MATERIAL_PRESET_DOUBLEWINDOW, + DSFX_I3DL2_MATERIAL_PRESET_THINDOOR, + DSFX_I3DL2_MATERIAL_PRESET_THICKDOOR, + DSFX_I3DL2_MATERIAL_PRESET_WOODWALL, + DSFX_I3DL2_MATERIAL_PRESET_BRICKWALL, + DSFX_I3DL2_MATERIAL_PRESET_STONEWALL, + DSFX_I3DL2_MATERIAL_PRESET_CURTAIN +}; + +#define I3DL2_MATERIAL_PRESET_SINGLEWINDOW -2800,0.71f +#define I3DL2_MATERIAL_PRESET_DOUBLEWINDOW -5000,0.40f +#define I3DL2_MATERIAL_PRESET_THINDOOR -1800,0.66f +#define I3DL2_MATERIAL_PRESET_THICKDOOR -4400,0.64f +#define I3DL2_MATERIAL_PRESET_WOODWALL -4000,0.50f +#define I3DL2_MATERIAL_PRESET_BRICKWALL -5000,0.60f +#define I3DL2_MATERIAL_PRESET_STONEWALL -6000,0.68f +#define I3DL2_MATERIAL_PRESET_CURTAIN -1200,0.15f + +enum +{ + DSFX_I3DL2_ENVIRONMENT_PRESET_DEFAULT, + DSFX_I3DL2_ENVIRONMENT_PRESET_GENERIC, + DSFX_I3DL2_ENVIRONMENT_PRESET_PADDEDCELL, + DSFX_I3DL2_ENVIRONMENT_PRESET_ROOM, + DSFX_I3DL2_ENVIRONMENT_PRESET_BATHROOM, + DSFX_I3DL2_ENVIRONMENT_PRESET_LIVINGROOM, + DSFX_I3DL2_ENVIRONMENT_PRESET_STONEROOM, + DSFX_I3DL2_ENVIRONMENT_PRESET_AUDITORIUM, + DSFX_I3DL2_ENVIRONMENT_PRESET_CONCERTHALL, + DSFX_I3DL2_ENVIRONMENT_PRESET_CAVE, + DSFX_I3DL2_ENVIRONMENT_PRESET_ARENA, + DSFX_I3DL2_ENVIRONMENT_PRESET_HANGAR, + DSFX_I3DL2_ENVIRONMENT_PRESET_CARPETEDHALLWAY, + DSFX_I3DL2_ENVIRONMENT_PRESET_HALLWAY, + DSFX_I3DL2_ENVIRONMENT_PRESET_STONECORRIDOR, + DSFX_I3DL2_ENVIRONMENT_PRESET_ALLEY, + DSFX_I3DL2_ENVIRONMENT_PRESET_FOREST, + DSFX_I3DL2_ENVIRONMENT_PRESET_CITY, + DSFX_I3DL2_ENVIRONMENT_PRESET_MOUNTAINS, + DSFX_I3DL2_ENVIRONMENT_PRESET_QUARRY, + DSFX_I3DL2_ENVIRONMENT_PRESET_PLAIN, + DSFX_I3DL2_ENVIRONMENT_PRESET_PARKINGLOT, + DSFX_I3DL2_ENVIRONMENT_PRESET_SEWERPIPE, + DSFX_I3DL2_ENVIRONMENT_PRESET_UNDERWATER, + DSFX_I3DL2_ENVIRONMENT_PRESET_SMALLROOM, + DSFX_I3DL2_ENVIRONMENT_PRESET_MEDIUMROOM, + DSFX_I3DL2_ENVIRONMENT_PRESET_LARGEROOM, + DSFX_I3DL2_ENVIRONMENT_PRESET_MEDIUMHALL, + DSFX_I3DL2_ENVIRONMENT_PRESET_LARGEHALL, + DSFX_I3DL2_ENVIRONMENT_PRESET_PLATE +}; + +// +// I3DL2 Reverberation Presets Values +// + +#define I3DL2_ENVIRONMENT_PRESET_DEFAULT -1000, -100, 0.0f, 1.49f, 0.83f, -2602, 0.007f, 200, 0.011f, 100.0f, 100.0f, 5000.0f +#define I3DL2_ENVIRONMENT_PRESET_GENERIC -1000, -100, 0.0f, 1.49f, 0.83f, -2602, 0.007f, 200, 0.011f, 100.0f, 100.0f, 5000.0f +#define I3DL2_ENVIRONMENT_PRESET_PADDEDCELL -1000,-6000, 0.0f, 0.17f, 0.10f, -1204, 0.001f, 207, 0.002f, 100.0f, 100.0f, 5000.0f +#define I3DL2_ENVIRONMENT_PRESET_ROOM -1000, -454, 0.0f, 0.40f, 0.83f, -1646, 0.002f, 53, 0.003f, 100.0f, 100.0f, 5000.0f +#define I3DL2_ENVIRONMENT_PRESET_BATHROOM -1000,-1200, 0.0f, 1.49f, 0.54f, -370, 0.007f, 1030, 0.011f, 100.0f, 60.0f, 5000.0f +#define I3DL2_ENVIRONMENT_PRESET_LIVINGROOM -1000,-6000, 0.0f, 0.50f, 0.10f, -1376, 0.003f, -1104, 0.004f, 100.0f, 100.0f, 5000.0f +#define I3DL2_ENVIRONMENT_PRESET_STONEROOM -1000, -300, 0.0f, 2.31f, 0.64f, -711, 0.012f, 83, 0.017f, 100.0f, 100.0f, 5000.0f +#define I3DL2_ENVIRONMENT_PRESET_AUDITORIUM -1000, -476, 0.0f, 4.32f, 0.59f, -789, 0.020f, -289, 0.030f, 100.0f, 100.0f, 5000.0f +#define I3DL2_ENVIRONMENT_PRESET_CONCERTHALL -1000, -500, 0.0f, 3.92f, 0.70f, -1230, 0.020f, -2, 0.029f, 100.0f, 100.0f, 5000.0f +#define I3DL2_ENVIRONMENT_PRESET_CAVE -1000, 0, 0.0f, 2.91f, 1.30f, -602, 0.015f, -302, 0.022f, 100.0f, 100.0f, 5000.0f +#define I3DL2_ENVIRONMENT_PRESET_ARENA -1000, -698, 0.0f, 7.24f, 0.33f, -1166, 0.020f, 16, 0.030f, 100.0f, 100.0f, 5000.0f +#define I3DL2_ENVIRONMENT_PRESET_HANGAR -1000,-1000, 0.0f,10.05f, 0.23f, -602, 0.020f, 198, 0.030f, 100.0f, 100.0f, 5000.0f +#define I3DL2_ENVIRONMENT_PRESET_CARPETEDHALLWAY -1000,-4000, 0.0f, 0.30f, 0.10f, -1831, 0.002f, -1630, 0.030f, 100.0f, 100.0f, 5000.0f +#define I3DL2_ENVIRONMENT_PRESET_HALLWAY -1000, -300, 0.0f, 1.49f, 0.59f, -1219, 0.007f, 441, 0.011f, 100.0f, 100.0f, 5000.0f +#define I3DL2_ENVIRONMENT_PRESET_STONECORRIDOR -1000, -237, 0.0f, 2.70f, 0.79f, -1214, 0.013f, 395, 0.020f, 100.0f, 100.0f, 5000.0f +#define I3DL2_ENVIRONMENT_PRESET_ALLEY -1000, -270, 0.0f, 1.49f, 0.86f, -1204, 0.007f, -4, 0.011f, 100.0f, 100.0f, 5000.0f +#define I3DL2_ENVIRONMENT_PRESET_FOREST -1000,-3300, 0.0f, 1.49f, 0.54f, -2560, 0.162f, -613, 0.088f, 79.0f, 100.0f, 5000.0f +#define I3DL2_ENVIRONMENT_PRESET_CITY -1000, -800, 0.0f, 1.49f, 0.67f, -2273, 0.007f, -2217, 0.011f, 50.0f, 100.0f, 5000.0f +#define I3DL2_ENVIRONMENT_PRESET_MOUNTAINS -1000,-2500, 0.0f, 1.49f, 0.21f, -2780, 0.300f, -2014, 0.100f, 27.0f, 100.0f, 5000.0f +#define I3DL2_ENVIRONMENT_PRESET_QUARRY -1000,-1000, 0.0f, 1.49f, 0.83f,-10000, 0.061f, 500, 0.025f, 100.0f, 100.0f, 5000.0f +#define I3DL2_ENVIRONMENT_PRESET_PLAIN -1000,-2000, 0.0f, 1.49f, 0.50f, -2466, 0.179f, -2514, 0.100f, 21.0f, 100.0f, 5000.0f +#define I3DL2_ENVIRONMENT_PRESET_PARKINGLOT -1000, 0, 0.0f, 1.65f, 1.50f, -1363, 0.008f, -1153, 0.012f, 100.0f, 100.0f, 5000.0f +#define I3DL2_ENVIRONMENT_PRESET_SEWERPIPE -1000,-1000, 0.0f, 2.81f, 0.14f, 429, 0.014f, 648, 0.021f, 80.0f, 60.0f, 5000.0f +#define I3DL2_ENVIRONMENT_PRESET_UNDERWATER -1000,-4000, 0.0f, 1.49f, 0.10f, -449, 0.007f, 1700, 0.011f, 100.0f, 100.0f, 5000.0f + +// +// Examples simulating 'musical' reverb presets +// +// Name Decay time Description +// Small Room 1.1s A small size room with a length of 5m or so. +// Medium Room 1.3s A medium size room with a length of 10m or so. +// Large Room 1.5s A large size room suitable for live performances. +// Medium Hall 1.8s A medium size concert hall. +// Large Hall 1.8s A large size concert hall suitable for a full orchestra. +// Plate 1.3s A plate reverb simulation. +// + +#define I3DL2_ENVIRONMENT_PRESET_SMALLROOM -1000, -600, 0.0f, 1.10f, 0.83f, -400, 0.005f, 500, 0.010f, 100.0f, 100.0f, 5000.0f +#define I3DL2_ENVIRONMENT_PRESET_MEDIUMROOM -1000, -600, 0.0f, 1.30f, 0.83f, -1000, 0.010f, -200, 0.020f, 100.0f, 100.0f, 5000.0f +#define I3DL2_ENVIRONMENT_PRESET_LARGEROOM -1000, -600, 0.0f, 1.50f, 0.83f, -1600, 0.020f, -1000, 0.040f, 100.0f, 100.0f, 5000.0f +#define I3DL2_ENVIRONMENT_PRESET_MEDIUMHALL -1000, -600, 0.0f, 1.80f, 0.70f, -1300, 0.015f, -800, 0.030f, 100.0f, 100.0f, 5000.0f +#define I3DL2_ENVIRONMENT_PRESET_LARGEHALL -1000, -600, 0.0f, 1.80f, 0.70f, -2000, 0.030f, -1400, 0.060f, 100.0f, 100.0f, 5000.0f +#define I3DL2_ENVIRONMENT_PRESET_PLATE -1000, -200, 0.0f, 1.30f, 0.90f, 0, 0.002f, 0, 0.010f, 100.0f, 75.0f, 5000.0f + +// +// DirectSound3D Algorithms +// + +// Default DirectSound3D algorithm {00000000-0000-0000-0000-000000000000} +#define DS3DALG_DEFAULT GUID_NULL + +// No virtualization (Pan3D) {C241333F-1C1B-11d2-94F5-00C04FC28ACA} +DEFINE_GUID(DS3DALG_NO_VIRTUALIZATION, 0xc241333f, 0x1c1b, 0x11d2, 0x94, 0xf5, 0x0, 0xc0, 0x4f, 0xc2, 0x8a, 0xca); + +// High-quality HRTF algorithm {C2413340-1C1B-11d2-94F5-00C04FC28ACA} +DEFINE_GUID(DS3DALG_HRTF_FULL, 0xc2413340, 0x1c1b, 0x11d2, 0x94, 0xf5, 0x0, 0xc0, 0x4f, 0xc2, 0x8a, 0xca); + +// Lower-quality HRTF algorithm {C2413342-1C1B-11d2-94F5-00C04FC28ACA} +DEFINE_GUID(DS3DALG_HRTF_LIGHT, 0xc2413342, 0x1c1b, 0x11d2, 0x94, 0xf5, 0x0, 0xc0, 0x4f, 0xc2, 0x8a, 0xca); + + +#if DIRECTSOUND_VERSION >= 0x0800 + +// +// DirectSound Internal Effect Algorithms +// + + +// Gargle {DAFD8210-5711-4B91-9FE3-F75B7AE279BF} +DEFINE_GUID(GUID_DSFX_STANDARD_GARGLE, 0xdafd8210, 0x5711, 0x4b91, 0x9f, 0xe3, 0xf7, 0x5b, 0x7a, 0xe2, 0x79, 0xbf); + +// Chorus {EFE6629C-81F7-4281-BD91-C9D604A95AF6} +DEFINE_GUID(GUID_DSFX_STANDARD_CHORUS, 0xefe6629c, 0x81f7, 0x4281, 0xbd, 0x91, 0xc9, 0xd6, 0x04, 0xa9, 0x5a, 0xf6); + +// Flanger {EFCA3D92-DFD8-4672-A603-7420894BAD98} +DEFINE_GUID(GUID_DSFX_STANDARD_FLANGER, 0xefca3d92, 0xdfd8, 0x4672, 0xa6, 0x03, 0x74, 0x20, 0x89, 0x4b, 0xad, 0x98); + +// Echo/Delay {EF3E932C-D40B-4F51-8CCF-3F98F1B29D5D} +DEFINE_GUID(GUID_DSFX_STANDARD_ECHO, 0xef3e932c, 0xd40b, 0x4f51, 0x8c, 0xcf, 0x3f, 0x98, 0xf1, 0xb2, 0x9d, 0x5d); + +// Distortion {EF114C90-CD1D-484E-96E5-09CFAF912A21} +DEFINE_GUID(GUID_DSFX_STANDARD_DISTORTION, 0xef114c90, 0xcd1d, 0x484e, 0x96, 0xe5, 0x09, 0xcf, 0xaf, 0x91, 0x2a, 0x21); + +// Compressor/Limiter {EF011F79-4000-406D-87AF-BFFB3FC39D57} +DEFINE_GUID(GUID_DSFX_STANDARD_COMPRESSOR, 0xef011f79, 0x4000, 0x406d, 0x87, 0xaf, 0xbf, 0xfb, 0x3f, 0xc3, 0x9d, 0x57); + +// Parametric Equalization {120CED89-3BF4-4173-A132-3CB406CF3231} +DEFINE_GUID(GUID_DSFX_STANDARD_PARAMEQ, 0x120ced89, 0x3bf4, 0x4173, 0xa1, 0x32, 0x3c, 0xb4, 0x06, 0xcf, 0x32, 0x31); + +// I3DL2 Environmental Reverberation: Reverb (Listener) Effect {EF985E71-D5C7-42D4-BA4D-2D073E2E96F4} +DEFINE_GUID(GUID_DSFX_STANDARD_I3DL2REVERB, 0xef985e71, 0xd5c7, 0x42d4, 0xba, 0x4d, 0x2d, 0x07, 0x3e, 0x2e, 0x96, 0xf4); + +// Waves Reverberation {87FC0268-9A55-4360-95AA-004A1D9DE26C} +DEFINE_GUID(GUID_DSFX_WAVES_REVERB, 0x87fc0268, 0x9a55, 0x4360, 0x95, 0xaa, 0x00, 0x4a, 0x1d, 0x9d, 0xe2, 0x6c); + +// +// DirectSound Capture Effect Algorithms +// + + +// Acoustic Echo Canceller {BF963D80-C559-11D0-8A2B-00A0C9255AC1} +// Matches KSNODETYPE_ACOUSTIC_ECHO_CANCEL in ksmedia.h +DEFINE_GUID(GUID_DSCFX_CLASS_AEC, 0xBF963D80L, 0xC559, 0x11D0, 0x8A, 0x2B, 0x00, 0xA0, 0xC9, 0x25, 0x5A, 0xC1); + +// Microsoft AEC {CDEBB919-379A-488a-8765-F53CFD36DE40} +DEFINE_GUID(GUID_DSCFX_MS_AEC, 0xcdebb919, 0x379a, 0x488a, 0x87, 0x65, 0xf5, 0x3c, 0xfd, 0x36, 0xde, 0x40); + +// System AEC {1C22C56D-9879-4f5b-A389-27996DDC2810} +DEFINE_GUID(GUID_DSCFX_SYSTEM_AEC, 0x1c22c56d, 0x9879, 0x4f5b, 0xa3, 0x89, 0x27, 0x99, 0x6d, 0xdc, 0x28, 0x10); + +// Noise Supression {E07F903F-62FD-4e60-8CDD-DEA7236665B5} +// Matches KSNODETYPE_NOISE_SUPPRESS in post Windows ME DDK's ksmedia.h +DEFINE_GUID(GUID_DSCFX_CLASS_NS, 0xe07f903f, 0x62fd, 0x4e60, 0x8c, 0xdd, 0xde, 0xa7, 0x23, 0x66, 0x65, 0xb5); + +// Microsoft Noise Suppresion {11C5C73B-66E9-4ba1-A0BA-E814C6EED92D} +DEFINE_GUID(GUID_DSCFX_MS_NS, 0x11c5c73b, 0x66e9, 0x4ba1, 0xa0, 0xba, 0xe8, 0x14, 0xc6, 0xee, 0xd9, 0x2d); + +// System Noise Suppresion {5AB0882E-7274-4516-877D-4EEE99BA4FD0} +DEFINE_GUID(GUID_DSCFX_SYSTEM_NS, 0x5ab0882e, 0x7274, 0x4516, 0x87, 0x7d, 0x4e, 0xee, 0x99, 0xba, 0x4f, 0xd0); + +#endif // DIRECTSOUND_VERSION >= 0x0800 + +#endif // __DSOUND_INCLUDED__ + + + +#ifdef __cplusplus +}; +#endif // __cplusplus + + diff --git a/desmume/src/windows/directx/dsound.lib b/src/windows/directx/dsound.lib similarity index 100% rename from desmume/src/windows/directx/dsound.lib rename to src/windows/directx/dsound.lib diff --git a/desmume/src/windows/directx/dxerr8.h b/src/windows/directx/dxerr8.h similarity index 96% rename from desmume/src/windows/directx/dxerr8.h rename to src/windows/directx/dxerr8.h index 4f4d84806..c2744306e 100644 --- a/desmume/src/windows/directx/dxerr8.h +++ b/src/windows/directx/dxerr8.h @@ -1,99 +1,99 @@ -/*==========================================================================; - * - * - * File: dxerr8.h - * Content: DirectX Error Library Include File - * - ****************************************************************************/ - -#ifndef _DXERR8_H_ -#define _DXERR8_H_ - -#ifdef __cplusplus -extern "C" { -#endif //__cplusplus - -// -// DXGetErrorString8 -// -// Desc: Converts a DirectX HRESULT to a string -// -// Args: HRESULT hr Can be any error code from -// D3D8 D3DX8 DDRAW DPLAY8 DMUSIC DSOUND DINPUT DSHOW -// -// Return: Converted string -// -const char* WINAPI DXGetErrorString8A(HRESULT hr); -const WCHAR* WINAPI DXGetErrorString8W(HRESULT hr); - -#ifdef UNICODE -#define DXGetErrorString8 DXGetErrorString8W -#else -#define DXGetErrorString8 DXGetErrorString8A -#endif - - -// -// DXGetErrorDescription8 -// -// Desc: Returns a string description of a DirectX HRESULT -// -// Args: HRESULT hr Can be any error code from -// D3D8 D3DX8 DDRAW DPLAY8 DMUSIC DSOUND DINPUT DSHOW -// -// Return: String description -// -const char* WINAPI DXGetErrorDescription8A(HRESULT hr); -const WCHAR* WINAPI DXGetErrorDescription8W(HRESULT hr); - -#ifdef UNICODE - #define DXGetErrorDescription8 DXGetErrorDescription8W -#else - #define DXGetErrorDescription8 DXGetErrorDescription8A -#endif - - -// -// DXTrace -// -// Desc: Outputs a formatted error message to the debug stream -// -// Args: CHAR* strFile The current file, typically passed in using the -// __FILE__ macro. -// DWORD dwLine The current line number, typically passed in using the -// __LINE__ macro. -// HRESULT hr An HRESULT that will be traced to the debug stream. -// CHAR* strMsg A string that will be traced to the debug stream (may be NULL) -// BOOL bPopMsgBox If TRUE, then a message box will popup also containing the passed info. -// -// Return: The hr that was passed in. -// -HRESULT WINAPI DXTraceA( const char* strFile, DWORD dwLine, HRESULT hr, const char* strMsg, BOOL bPopMsgBox ); -HRESULT WINAPI DXTraceW( const char* strFile, DWORD dwLine, HRESULT hr, const WCHAR* strMsg, BOOL bPopMsgBox ); - -#ifdef UNICODE -#define DXTrace DXTraceW -#else -#define DXTrace DXTraceA -#endif - - -// -// Helper macros -// -#if defined(DEBUG) | defined(_DEBUG) -#define DXTRACE_MSG(str) DXTrace( __FILE__, (DWORD)__LINE__, 0, str, FALSE ) -#define DXTRACE_ERR(str,hr) DXTrace( __FILE__, (DWORD)__LINE__, hr, str, TRUE ) -#define DXTRACE_ERR_NOMSGBOX(str,hr) DXTrace( __FILE__, (DWORD)__LINE__, hr, str, FALSE ) -#else -#define DXTRACE_MSG(str) (0L) -#define DXTRACE_ERR(str,hr) (hr) -#define DXTRACE_ERR_NOMSGBOX(str,hr) (hr) -#endif - - -#ifdef __cplusplus -} -#endif //__cplusplus - -#endif // _DXERR8_H_ +/*==========================================================================; + * + * + * File: dxerr8.h + * Content: DirectX Error Library Include File + * + ****************************************************************************/ + +#ifndef _DXERR8_H_ +#define _DXERR8_H_ + +#ifdef __cplusplus +extern "C" { +#endif //__cplusplus + +// +// DXGetErrorString8 +// +// Desc: Converts a DirectX HRESULT to a string +// +// Args: HRESULT hr Can be any error code from +// D3D8 D3DX8 DDRAW DPLAY8 DMUSIC DSOUND DINPUT DSHOW +// +// Return: Converted string +// +const char* WINAPI DXGetErrorString8A(HRESULT hr); +const WCHAR* WINAPI DXGetErrorString8W(HRESULT hr); + +#ifdef UNICODE +#define DXGetErrorString8 DXGetErrorString8W +#else +#define DXGetErrorString8 DXGetErrorString8A +#endif + + +// +// DXGetErrorDescription8 +// +// Desc: Returns a string description of a DirectX HRESULT +// +// Args: HRESULT hr Can be any error code from +// D3D8 D3DX8 DDRAW DPLAY8 DMUSIC DSOUND DINPUT DSHOW +// +// Return: String description +// +const char* WINAPI DXGetErrorDescription8A(HRESULT hr); +const WCHAR* WINAPI DXGetErrorDescription8W(HRESULT hr); + +#ifdef UNICODE + #define DXGetErrorDescription8 DXGetErrorDescription8W +#else + #define DXGetErrorDescription8 DXGetErrorDescription8A +#endif + + +// +// DXTrace +// +// Desc: Outputs a formatted error message to the debug stream +// +// Args: CHAR* strFile The current file, typically passed in using the +// __FILE__ macro. +// DWORD dwLine The current line number, typically passed in using the +// __LINE__ macro. +// HRESULT hr An HRESULT that will be traced to the debug stream. +// CHAR* strMsg A string that will be traced to the debug stream (may be NULL) +// BOOL bPopMsgBox If TRUE, then a message box will popup also containing the passed info. +// +// Return: The hr that was passed in. +// +HRESULT WINAPI DXTraceA( const char* strFile, DWORD dwLine, HRESULT hr, const char* strMsg, BOOL bPopMsgBox ); +HRESULT WINAPI DXTraceW( const char* strFile, DWORD dwLine, HRESULT hr, const WCHAR* strMsg, BOOL bPopMsgBox ); + +#ifdef UNICODE +#define DXTrace DXTraceW +#else +#define DXTrace DXTraceA +#endif + + +// +// Helper macros +// +#if defined(DEBUG) | defined(_DEBUG) +#define DXTRACE_MSG(str) DXTrace( __FILE__, (DWORD)__LINE__, 0, str, FALSE ) +#define DXTRACE_ERR(str,hr) DXTrace( __FILE__, (DWORD)__LINE__, hr, str, TRUE ) +#define DXTRACE_ERR_NOMSGBOX(str,hr) DXTrace( __FILE__, (DWORD)__LINE__, hr, str, FALSE ) +#else +#define DXTRACE_MSG(str) (0L) +#define DXTRACE_ERR(str,hr) (hr) +#define DXTRACE_ERR_NOMSGBOX(str,hr) (hr) +#endif + + +#ifdef __cplusplus +} +#endif //__cplusplus + +#endif // _DXERR8_H_ diff --git a/desmume/src/windows/directx/dxguid.lib b/src/windows/directx/dxguid.lib similarity index 100% rename from desmume/src/windows/directx/dxguid.lib rename to src/windows/directx/dxguid.lib diff --git a/desmume/src/windows/disView.cpp b/src/windows/disView.cpp similarity index 100% rename from desmume/src/windows/disView.cpp rename to src/windows/disView.cpp diff --git a/desmume/src/windows/disView.h b/src/windows/disView.h similarity index 97% rename from desmume/src/windows/disView.h rename to src/windows/disView.h index ad2edc913..494cb5689 100644 --- a/desmume/src/windows/disView.h +++ b/src/windows/disView.h @@ -1,35 +1,35 @@ -/* Copyright (C) 2006 yopyop - yopyop156@ifrance.com - yopyop156.ifrance.com - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#ifndef DISVIEW_H -#define DISVIEW_H - -#include "../common.h" - -extern BOOL CALLBACK ViewDisasm_ARM7Proc (HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam); -extern LRESULT CALLBACK ViewDisasm_ARM7BoxProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam); - -extern BOOL CALLBACK ViewDisasm_ARM9Proc (HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam); -extern LRESULT CALLBACK ViewDisasm_ARM9BoxProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam); - -template void FORCEINLINE DisassemblerTools_Refresh(); - -#endif +/* Copyright (C) 2006 yopyop + yopyop156@ifrance.com + yopyop156.ifrance.com + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#ifndef DISVIEW_H +#define DISVIEW_H + +#include "../common.h" + +extern BOOL CALLBACK ViewDisasm_ARM7Proc (HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam); +extern LRESULT CALLBACK ViewDisasm_ARM7BoxProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam); + +extern BOOL CALLBACK ViewDisasm_ARM9Proc (HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam); +extern LRESULT CALLBACK ViewDisasm_ARM9BoxProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam); + +template void FORCEINLINE DisassemblerTools_Refresh(); + +#endif diff --git a/desmume/src/windows/gbaslot_config.cpp b/src/windows/gbaslot_config.cpp similarity index 68% rename from desmume/src/windows/gbaslot_config.cpp rename to src/windows/gbaslot_config.cpp index 79e05940e..e170cb276 100644 --- a/desmume/src/windows/gbaslot_config.cpp +++ b/src/windows/gbaslot_config.cpp @@ -27,23 +27,19 @@ #include "debug.h" #include "../addons.h" #include "../NDSSystem.h" -#include "inputdx.h" #include WNDCLASSEX wc; -HWND wndConfig = NULL; +HWND wndConfig; u8 temp_type = 0; -u8 last_type = 0; -char tmp_cflash_filename[MAX_PATH] = { 0 }; -char tmp_cflash_path[MAX_PATH] = { 0 }; -char tmp_gbagame_filename[MAX_PATH] = { 0 }; -ADDON_CFLASH_MODE tmp_CFlashMode = ADDON_CFLASH_MODE_RomPath; +u8 last_type; +char tmp_cflash_filename[MAX_PATH]; +char tmp_cflash_path[MAX_PATH]; +char tmp_gbagame_filename[MAX_PATH]; +u8 tmp_CFlashUsePath; +u8 tmp_CFlashUseRomPath; HWND OKbutton = NULL; bool _OKbutton = false; -SGuitar tmp_Guitar; -bool needReset = true; - -std::string CFlashPath, CFlashName; BOOL CALLBACK GbaSlotNone(HWND dialog, UINT msg,WPARAM wparam,LPARAM lparam) { @@ -66,37 +62,32 @@ BOOL CALLBACK GbaSlotCFlash(HWND dialog, UINT msg,WPARAM wparam,LPARAM lparam) { SetWindowText(GetDlgItem(dialog, IDC_PATHIMG), tmp_cflash_filename); SetWindowText(GetDlgItem(dialog, IDC_PATH), tmp_cflash_path); - switch (tmp_CFlashMode) + if (tmp_CFlashUsePath) { - case ADDON_CFLASH_MODE_Path: - CheckDlgButton(dialog, IDC_RFOLDER, BST_CHECKED); - EnableWindow(GetDlgItem(dialog, IDC_PATH), TRUE); - EnableWindow(GetDlgItem(dialog, IDC_BBROWSE2), TRUE); - EnableWindow(GetDlgItem(dialog, IDC_PATHIMG), FALSE); - EnableWindow(GetDlgItem(dialog, IDC_BBROWSE), FALSE); - if (strlen(tmp_cflash_path)) _OKbutton = TRUE; - break; - - case ADDON_CFLASH_MODE_File: - CheckDlgButton(dialog, IDC_RFILE, BST_CHECKED); - EnableWindow(GetDlgItem(dialog, IDC_PATHIMG), TRUE); - EnableWindow(GetDlgItem(dialog, IDC_BBROWSE), TRUE); - EnableWindow(GetDlgItem(dialog, IDC_BBROWSE2), FALSE); - EnableWindow(GetDlgItem(dialog, IDC_PATH), FALSE); - if (strlen(tmp_cflash_filename)) _OKbutton = TRUE; - break; - - case ADDON_CFLASH_MODE_RomPath: + if (tmp_CFlashUseRomPath) + { CheckDlgButton(dialog, IDC_PATHDESMUME, BST_CHECKED); EnableWindow(GetDlgItem(dialog, IDC_PATH), FALSE); EnableWindow(GetDlgItem(dialog, IDC_BBROWSE2), FALSE); - EnableWindow(GetDlgItem(dialog, IDC_PATHIMG), FALSE); - EnableWindow(GetDlgItem(dialog, IDC_BBROWSE), FALSE); _OKbutton = TRUE; - break; - default: - return FALSE; - + } + else + { + EnableWindow(GetDlgItem(dialog, IDC_PATH), TRUE); + EnableWindow(GetDlgItem(dialog, IDC_BBROWSE2), TRUE); + if (strlen(tmp_cflash_path)) _OKbutton = TRUE; + } + EnableWindow(GetDlgItem(dialog, IDC_PATHIMG), FALSE); + EnableWindow(GetDlgItem(dialog, IDC_BBROWSE), FALSE); + CheckDlgButton(dialog, IDC_RFOLDER, BST_CHECKED); + } + else + { + EnableWindow(GetDlgItem(dialog, IDC_BBROWSE2), FALSE); + EnableWindow(GetDlgItem(dialog, IDC_PATHDESMUME), FALSE); + EnableWindow(GetDlgItem(dialog, IDC_PATH), FALSE); + if (strlen(tmp_cflash_filename)) _OKbutton = TRUE; + CheckDlgButton(dialog, IDC_RFILE, BST_CHECKED); } return TRUE; } @@ -171,11 +162,12 @@ BOOL CALLBACK GbaSlotCFlash(HWND dialog, UINT msg,WPARAM wparam,LPARAM lparam) { if (HIWORD(wparam) == BN_CLICKED) { - tmp_CFlashMode = ADDON_CFLASH_MODE_File; + tmp_CFlashUsePath = FALSE; EnableWindow(GetDlgItem(dialog, IDC_PATHIMG), TRUE); EnableWindow(GetDlgItem(dialog, IDC_BBROWSE), TRUE); EnableWindow(GetDlgItem(dialog, IDC_BBROWSE2), FALSE); + EnableWindow(GetDlgItem(dialog, IDC_PATHDESMUME), FALSE); EnableWindow(GetDlgItem(dialog, IDC_PATH), FALSE); if (!strlen(tmp_cflash_filename)) @@ -188,30 +180,48 @@ BOOL CALLBACK GbaSlotCFlash(HWND dialog, UINT msg,WPARAM wparam,LPARAM lparam) { if (HIWORD(wparam) == BN_CLICKED) { - tmp_CFlashMode = ADDON_CFLASH_MODE_Path; + tmp_CFlashUsePath = TRUE; EnableWindow(GetDlgItem(dialog, IDC_PATHIMG), FALSE); EnableWindow(GetDlgItem(dialog, IDC_BBROWSE), FALSE); - EnableWindow(GetDlgItem(dialog, IDC_BBROWSE2), TRUE); - EnableWindow(GetDlgItem(dialog, IDC_PATH), TRUE); - if (!strlen(tmp_cflash_path)) - EnableWindow(OKbutton, FALSE); + if (IsDlgButtonChecked(dialog, IDC_PATHDESMUME)) + { + tmp_CFlashUseRomPath = TRUE; + EnableWindow(GetDlgItem(dialog, IDC_BBROWSE2), FALSE); + EnableWindow(GetDlgItem(dialog, IDC_PATH), FALSE); + EnableWindow(OKbutton, TRUE); + } + else + { + tmp_CFlashUseRomPath = FALSE; + EnableWindow(GetDlgItem(dialog, IDC_BBROWSE2), TRUE); + EnableWindow(GetDlgItem(dialog, IDC_PATH), TRUE); + } + + EnableWindow(GetDlgItem(dialog, IDC_PATHDESMUME), TRUE); } break; } case IDC_PATHDESMUME: { - if (HIWORD(wparam) == BN_CLICKED) + if (IsDlgButtonChecked(dialog, IDC_PATHDESMUME)) { - tmp_CFlashMode = ADDON_CFLASH_MODE_RomPath; - EnableWindow(GetDlgItem(dialog, IDC_PATHIMG), FALSE); - EnableWindow(GetDlgItem(dialog, IDC_BBROWSE), FALSE); - + tmp_CFlashUseRomPath = TRUE; EnableWindow(GetDlgItem(dialog, IDC_BBROWSE2), FALSE); EnableWindow(GetDlgItem(dialog, IDC_PATH), FALSE); EnableWindow(OKbutton, TRUE); } + else + { + tmp_CFlashUseRomPath = FALSE; + EnableWindow(GetDlgItem(dialog, IDC_BBROWSE2), TRUE); + EnableWindow(GetDlgItem(dialog, IDC_PATH), TRUE); + if (strlen(tmp_cflash_path)) + EnableWindow(OKbutton, TRUE); + else + EnableWindow(OKbutton, FALSE); + } break; } } @@ -290,80 +300,18 @@ BOOL CALLBACK GbaSlotGBAgame(HWND dialog, UINT msg,WPARAM wparam,LPARAM lparam) return FALSE; } -BOOL CALLBACK GbaSlotGuitarGrip(HWND dialog, UINT msg,WPARAM wparam,LPARAM lparam) -{ - int which = 0; - - switch(msg) - { - case WM_INITDIALOG: - { - _OKbutton = TRUE; - SendDlgItemMessage(dialog,IDC_GGREEN,WM_USER+44,tmp_Guitar.GREEN,0); - SendDlgItemMessage(dialog,IDC_GRED,WM_USER+44,tmp_Guitar.RED,0); - SendDlgItemMessage(dialog,IDC_GYELLOW,WM_USER+44,tmp_Guitar.YELLOW,0); - SendDlgItemMessage(dialog,IDC_GBLUE,WM_USER+44,tmp_Guitar.BLUE,0); - if (temp_type != addon_type) - needReset = true; - else - needReset = false; - - return TRUE; - } - - case WM_USER+46: - SendDlgItemMessage(dialog,IDC_GGREEN,WM_USER+44,tmp_Guitar.GREEN,0); - SendDlgItemMessage(dialog,IDC_GRED,WM_USER+44,tmp_Guitar.RED,0); - SendDlgItemMessage(dialog,IDC_GYELLOW,WM_USER+44,tmp_Guitar.YELLOW,0); - SendDlgItemMessage(dialog,IDC_GBLUE,WM_USER+44,tmp_Guitar.BLUE,0); - return TRUE; - - case WM_USER+43: - //MessageBox(hDlg,"USER+43 CAUGHT","moo",MB_OK); - which = GetDlgCtrlID((HWND)lparam); - switch(which) - { - case IDC_GGREEN: - tmp_Guitar.GREEN = wparam; - - break; - case IDC_GRED: - tmp_Guitar.RED = wparam; - - break; - case IDC_GYELLOW: - tmp_Guitar.YELLOW = wparam; - - break; - case IDC_GBLUE: - tmp_Guitar.BLUE = wparam; - break; - } - - SendDlgItemMessage(dialog,IDC_GGREEN,WM_USER+44,tmp_Guitar.GREEN,0); - SendDlgItemMessage(dialog,IDC_GRED,WM_USER+44,tmp_Guitar.RED,0); - SendDlgItemMessage(dialog,IDC_GYELLOW,WM_USER+44,tmp_Guitar.YELLOW,0); - SendDlgItemMessage(dialog,IDC_GBLUE,WM_USER+44,tmp_Guitar.BLUE,0); - PostMessage(dialog,WM_NEXTDLGCTL,0,0); - return true; - } - return FALSE; -} - u32 GBAslot_IDDs[NDS_ADDON_COUNT] = { IDD_GBASLOT_NONE, IDD_GBASLOT_CFLASH, IDD_GBASLOT_RUMBLEPAK, - IDD_GBASLOT_GBAGAME, - IDD_GBASLOT_GUITARGRIP + IDD_GBASLOT_GBAGAME }; DLGPROC GBAslot_Procs[NDS_ADDON_COUNT] = { GbaSlotNone, GbaSlotCFlash, GbaSlotRumblePak, - GbaSlotGBAgame, - GbaSlotGuitarGrip + GbaSlotGBAgame }; @@ -399,9 +347,9 @@ BOOL CALLBACK GbaSlotBox_Proc(HWND dialog, UINT msg,WPARAM wparam,LPARAM lparam) case IDOK: { int Msg = IDYES; - if (romloaded && (needReset || (temp_type!=addon_type)) ) + if (romloaded) { - Msg = MessageBox(dialog, + int Msg = MessageBox(dialog, "After change GBA slot pak game will reset!\nAre you sure to continue?", "DeSmuME", MB_YESNO|MB_ICONQUESTION|MB_DEFBUTTON2); } @@ -450,71 +398,50 @@ void GBAslotDialog(HWND hwnd) { temp_type = addon_type; last_type = temp_type; - strcpy(tmp_cflash_filename, CFlashName.c_str()); - strcpy(tmp_cflash_path, CFlashPath.c_str()); + strcpy(tmp_cflash_filename, CFlashName); + strcpy(tmp_cflash_path, CFlashPath); strcpy(tmp_gbagame_filename, GBAgameName); - memcpy(&tmp_Guitar, &Guitar, sizeof(Guitar)); - tmp_CFlashMode = CFlash_Mode; + tmp_CFlashUseRomPath = CFlashUseRomPath; + tmp_CFlashUsePath = CFlashUsePath; _OKbutton = false; - needReset = true; u32 res=DialogBox(hAppInst, MAKEINTRESOURCE(IDD_GBASLOT), hwnd, (DLGPROC) GbaSlotBox_Proc); if (res) { switch (temp_type) { case NDS_ADDON_NONE: - if (temp_type != addon_type) - needReset = true; - else - needReset = false; break; case NDS_ADDON_CFLASH: - CFlash_Mode = tmp_CFlashMode; - WritePrivateProfileInt("GBAslot.CFlash","fileMode",CFlash_Mode,IniName); - WritePrivateProfileString("GBAslot.CFlash","path",tmp_cflash_path,IniName); - WritePrivateProfileString("GBAslot.CFlash","filename",tmp_cflash_filename,IniName); - if(CFlash_Mode == ADDON_CFLASH_MODE_Path) - CFlash_Path = tmp_cflash_path; - else if(CFlash_Mode == ADDON_CFLASH_MODE_RomPath) - CFlash_Path = ""; - else - CFlash_Path = tmp_cflash_filename; - needReset = true; + CFlashUsePath = tmp_CFlashUsePath; + WritePrivateProfileInt("GBAslot.CFlash","usePath",CFlashUsePath,IniName); + if (tmp_CFlashUsePath) + { + if (tmp_CFlashUseRomPath) + { + CFlashUseRomPath = tmp_CFlashUseRomPath; + WritePrivateProfileInt("GBAslot.CFlash","useRomPath",CFlashUseRomPath,IniName); + break; + } + strcpy(CFlashPath, tmp_cflash_path); + WritePrivateProfileString("GBAslot.CFlash","path",CFlashPath,IniName); + break; + } + strcpy(CFlashName, tmp_cflash_filename); + WritePrivateProfileString("GBAslot.CFlash","filename",CFlashName,IniName); break; case NDS_ADDON_RUMBLEPAK: - if (temp_type != addon_type) - needReset = true; - else - needReset = false; break; case NDS_ADDON_GBAGAME: strcpy(GBAgameName, tmp_gbagame_filename); WritePrivateProfileString("GBAslot.GBAgame","filename",GBAgameName,IniName); - needReset = true; - break; - case NDS_ADDON_GUITARGRIP: - memcpy(&Guitar, &tmp_Guitar, sizeof(tmp_Guitar)); - Guitar.Enabled = true; - WritePrivateProfileInt("GBAslot.GuitarGrip","green",Guitar.GREEN,IniName); - WritePrivateProfileInt("GBAslot.GuitarGrip","red",Guitar.RED,IniName); - WritePrivateProfileInt("GBAslot.GuitarGrip","yellow",Guitar.YELLOW,IniName); - WritePrivateProfileInt("GBAslot.GuitarGrip","blue",Guitar.BLUE,IniName); - if (temp_type != addon_type) - needReset = true; - else - needReset = false; break; default: return; } - if (temp_type!=NDS_ADDON_GUITARGRIP) - Guitar.Enabled = false; WritePrivateProfileInt("GBAslot","type",temp_type,IniName); - addon_type = temp_type; addonsChangePak(addon_type); - if (romloaded && needReset) + if (romloaded) NDS_Reset(); - return; } } \ No newline at end of file diff --git a/desmume/src/windows/gbaslot_config.h b/src/windows/gbaslot_config.h similarity index 93% rename from desmume/src/windows/gbaslot_config.h rename to src/windows/gbaslot_config.h index 59f1092a0..6b7b1c286 100644 --- a/desmume/src/windows/gbaslot_config.h +++ b/src/windows/gbaslot_config.h @@ -1,30 +1,26 @@ -/* - Copyright (C) 2008 shash - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#ifndef __GBASLOT_CONFIG_H_ -#define __GBASLOT_CONFIG_H_ -#include "../common.h" -#include - -extern std::string CFlashPath, CFlashName; - -extern void GBAslotDialog(HWND hwnd); - -#endif +/* + Copyright (C) 2008 shash + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#ifndef __GBASLOT_CONFIG_H_ +#define __GBASLOT_CONFIG_H_ +#include "../common.h" + +extern void GBAslotDialog(HWND hwnd); +#endif diff --git a/desmume/src/windows/ginfo.cpp b/src/windows/ginfo.cpp similarity index 96% rename from desmume/src/windows/ginfo.cpp rename to src/windows/ginfo.cpp index 717dc8edc..9d7d98d80 100644 --- a/desmume/src/windows/ginfo.cpp +++ b/src/windows/ginfo.cpp @@ -1,346 +1,346 @@ -/* Copyright (C) 2006 yopyop - yopyop156@ifrance.com - yopyop156.ifrance.com - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#include "resource.h" -#include "common.h" -#include "../MMU.h" -#include "../NDSSystem.h" -#include "FirmConfig.h" -#include -#include -#include -#include "ginfo.h" - -////////////////////////////////////////////////////////////////////////////// - -BOOL GInfo_Init() -{ - WNDCLASSEX wc; - - wc.cbSize = sizeof(wc); - wc.lpszClassName = "GInfo_IconBox"; - wc.hInstance = hAppInst; - wc.lpfnWndProc = GInfo_IconBoxProc; - wc.hCursor = LoadCursor(NULL, IDC_ARROW); - wc.hIcon = 0; - wc.lpszMenuName = 0; - wc.hbrBackground = GetSysColorBrush(COLOR_BTNFACE); - wc.style = 0; - wc.cbClsExtra = 0; - wc.cbWndExtra = 0; - wc.hIconSm = 0; - - RegisterClassEx(&wc); - - return 1; -} - -void GInfo_DeInit() -{ - UnregisterClass("GInfo_IconBox", hAppInst); -} - -////////////////////////////////////////////////////////////////////////////// - -BOOL GInfo_DlgOpen(HWND hParentWnd) -{ - HWND hDlg; - - hDlg = CreateDialog(hAppInst, MAKEINTRESOURCE(IDD_GAME_INFO), hParentWnd, GInfo_DlgProc); - if(hDlg == NULL) - return 0; - - ShowWindow(hDlg, SW_SHOW); - UpdateWindow(hDlg); - - return 1; -} - -////////////////////////////////////////////////////////////////////////////// - -LRESULT GInfo_Paint(HWND hDlg, WPARAM wParam, LPARAM lParam) -{ - HDC hdc; - PAINTSTRUCT ps; - char text[80]; - u32 icontitleOffset; - wchar_t *utf16text; - u32 val; - - hdc = BeginPaint(hDlg, &ps); - - icontitleOffset = T1ReadLong(MMU.CART_ROM, 0x68); - - if(icontitleOffset >= 0x8000) - { - utf16text = (wchar_t*)(MMU.CART_ROM + icontitleOffset + 0x240 + (0x100 * win_fw_config.language)); - sprintf(text, "%ws", utf16text); - SetWindowText(GetDlgItem(hDlg, IDC_GI_TITLE), text); - - utf16text = (wchar_t*)(MMU.CART_ROM + icontitleOffset + 0x240); - sprintf(text, "%ws", utf16text); - SetWindowText(GetDlgItem(hDlg, IDC_GI_TITLEJP), text); - - utf16text = (wchar_t*)(MMU.CART_ROM + icontitleOffset + 0x340); - sprintf(text, "%ws", utf16text); - SetWindowText(GetDlgItem(hDlg, IDC_GI_TITLEEN), text); - - utf16text = (wchar_t*)(MMU.CART_ROM + icontitleOffset + 0x440); - sprintf(text, "%ws", utf16text); - SetWindowText(GetDlgItem(hDlg, IDC_GI_TITLEFR), text); - - utf16text = (wchar_t*)(MMU.CART_ROM + icontitleOffset + 0x540); - sprintf(text, "%ws", utf16text); - SetWindowText(GetDlgItem(hDlg, IDC_GI_TITLEGE), text); - - utf16text = (wchar_t*)(MMU.CART_ROM + icontitleOffset + 0x640); - sprintf(text, "%ws", utf16text); - SetWindowText(GetDlgItem(hDlg, IDC_GI_TITLEIT), text); - - utf16text = (wchar_t*)(MMU.CART_ROM + icontitleOffset + 0x740); - sprintf(text, "%ws", utf16text); - SetWindowText(GetDlgItem(hDlg, IDC_GI_TITLESP), text); - } - else - { - SetWindowText(GetDlgItem(hDlg, IDC_GI_TITLE), "\nNo title\n"); - - SetWindowText(GetDlgItem(hDlg, IDC_GI_TITLEJP), "None"); - SetWindowText(GetDlgItem(hDlg, IDC_GI_TITLEEN), "None"); - SetWindowText(GetDlgItem(hDlg, IDC_GI_TITLEFR), "None"); - SetWindowText(GetDlgItem(hDlg, IDC_GI_TITLEGE), "None"); - SetWindowText(GetDlgItem(hDlg, IDC_GI_TITLEIT), "None"); - SetWindowText(GetDlgItem(hDlg, IDC_GI_TITLESP), "None"); - } - - - memcpy(text, MMU.CART_ROM, 12); - text[12] = '\0'; - SetWindowText(GetDlgItem(hDlg, IDC_GI_GAMETITLE), text); - - memcpy(text, (MMU.CART_ROM+0xC), 4); - text[4] = '\0'; - SetWindowText(GetDlgItem(hDlg, IDC_GI_GAMECODE), text); - - memcpy(text, (MMU.CART_ROM+0x10), 2); - text[2] = '\0'; - SetWindowText(GetDlgItem(hDlg, IDC_GI_MAKERCODE), text); - - val = T1ReadByte(MMU.CART_ROM, 0x14); - sprintf(text, "%i kilobytes", (0x80 << val)); - SetWindowText(GetDlgItem(hDlg, IDC_GI_CHIPSIZE), text); - - - val = T1ReadLong(MMU.CART_ROM, 0x20); - sprintf(text, "0x%08X", val); - SetWindowText(GetDlgItem(hDlg, IDC_GI_ARM9ROM), text); - - val = T1ReadLong(MMU.CART_ROM, 0x24); - sprintf(text, "0x%08X", val); - SetWindowText(GetDlgItem(hDlg, IDC_GI_ARM9ENTRY), text); - - val = T1ReadLong(MMU.CART_ROM, 0x28); - sprintf(text, "0x%08X", val); - SetWindowText(GetDlgItem(hDlg, IDC_GI_ARM9START), text); - - val = T1ReadLong(MMU.CART_ROM, 0x2C); - sprintf(text, "%i bytes", val); - SetWindowText(GetDlgItem(hDlg, IDC_GI_ARM9SIZE), text); - - val = T1ReadLong(MMU.CART_ROM, 0x30); - sprintf(text, "0x%08X", val); - SetWindowText(GetDlgItem(hDlg, IDC_GI_ARM7ROM), text); - - val = T1ReadLong(MMU.CART_ROM, 0x34); - sprintf(text, "0x%08X", val); - SetWindowText(GetDlgItem(hDlg, IDC_GI_ARM7ENTRY), text); - - val = T1ReadLong(MMU.CART_ROM, 0x38); - sprintf(text, "0x%08X", val); - SetWindowText(GetDlgItem(hDlg, IDC_GI_ARM7START), text); - - val = T1ReadLong(MMU.CART_ROM, 0x3C); - sprintf(text, "%i bytes", val); - SetWindowText(GetDlgItem(hDlg, IDC_GI_ARM7SIZE), text); - - - val = T1ReadLong(MMU.CART_ROM, 0x40); - sprintf(text, "0x%08X", val); - SetWindowText(GetDlgItem(hDlg, IDC_GI_FNTOFS), text); - - val = T1ReadLong(MMU.CART_ROM, 0x44); - sprintf(text, "%i bytes", val); - SetWindowText(GetDlgItem(hDlg, IDC_GI_FNTSIZE), text); - - val = T1ReadLong(MMU.CART_ROM, 0x48); - sprintf(text, "0x%08X", val); - SetWindowText(GetDlgItem(hDlg, IDC_GI_FATOFS), text); - - val = T1ReadLong(MMU.CART_ROM, 0x4C); - sprintf(text, "%i bytes", val); - SetWindowText(GetDlgItem(hDlg, IDC_GI_FATSIZE), text); - - - sprintf(text, "0x%08X", icontitleOffset); - SetWindowText(GetDlgItem(hDlg, IDC_GI_ICONTITLEOFS), text); - - val = T1ReadLong(MMU.CART_ROM, 0x80); - sprintf(text, "0x%08X", val); - SetWindowText(GetDlgItem(hDlg, IDC_GI_USEDROMSIZE), text); - - - EndPaint(hDlg, &ps); - - return 0; -} - -BOOL CALLBACK GInfo_DlgProc(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam) -{ - switch(uMsg) - { - case WM_INITDIALOG: - return 1; - - case WM_CLOSE: - EndDialog(hDlg, 0); - return 1; - - case WM_PAINT: - GInfo_Paint(hDlg, wParam, lParam); - return 1; - - case WM_COMMAND: - switch(LOWORD(wParam)) - { - case IDCANCEL: - EndDialog(hDlg, 0); - return 1; - } - return 0; - } - - return 0; -} - -////////////////////////////////////////////////////////////////////////////// - -LRESULT GInfo_IconBoxPaint(HWND hCtl, WPARAM wParam, LPARAM lParam) -{ - HDC hdc; - PAINTSTRUCT ps; - RECT rc; - int w, h; - SIZE fontsize; - HDC mem_hdc; - HBITMAP mem_bmp; - BITMAPV4HEADER bmph; - u32 icontitleOffset; - u16 icon[32 * 32]; - int x, y; - - GetClientRect(hCtl, &rc); - w = (rc.right - rc.left); - h = (rc.bottom - rc.top); - - hdc = BeginPaint(hCtl, &ps); - - mem_hdc = CreateCompatibleDC(hdc); - mem_bmp = CreateCompatibleBitmap(hdc, w, h); - SelectObject(mem_hdc, mem_bmp); - - FillRect(mem_hdc, &rc, (HBRUSH)GetStockObject(WHITE_BRUSH)); - - ZeroMemory(&bmph, sizeof(bmph)); - bmph.bV4Size = sizeof(bmph); - bmph.bV4Planes = 1; - bmph.bV4BitCount = 16; - bmph.bV4V4Compression = BI_BITFIELDS; - bmph.bV4RedMask = 0x001F; - bmph.bV4GreenMask = 0x03E0; - bmph.bV4BlueMask = 0x7C00; - bmph.bV4Width = 32; - bmph.bV4Height = -32; - - icontitleOffset = T1ReadLong(MMU.CART_ROM, 0x68); - - if(icontitleOffset >= 0x8000) - { - for(y = 0; y < 32; y++) - { - for(x = 0; x < 32; x++) - { - int tilenum = (((y / 8) * 4) + (x / 8)); - int tilex = (x % 8); - int tiley = (y % 8); - int mapoffset = ((tilenum * 64) + (tiley * 8) + tilex); - - u8 val = T1ReadByte(MMU.CART_ROM, (icontitleOffset + 0x20 + (mapoffset>>1))); - - if(mapoffset & 1) - val = ((val >> 4) & 0xF); - else - val = (val & 0xF); - - icon[(y * 32) + x] = T1ReadWord(MMU.CART_ROM, (icontitleOffset + 0x220 + (val<<1))); - } - } - - SetDIBitsToDevice(mem_hdc, ((w/2) - 16), ((h/2) - 16), 32, 32, 0, 0, 0, 32, icon, (BITMAPINFO*)&bmph, DIB_RGB_COLORS); - } - else - { - char *noicon = "No icon"; - GetTextExtentPoint32(mem_hdc, noicon, strlen(noicon), &fontsize); - TextOut(mem_hdc, ((w/2) - (fontsize.cx/2)), ((h/2) - (fontsize.cy/2)), noicon, strlen(noicon)); - } - - BitBlt(hdc, 0, 0, w, h, mem_hdc, 0, 0, SRCCOPY); - - DeleteDC(mem_hdc); - DeleteObject(mem_bmp); - - EndPaint(hCtl, &ps); - - return 0; -} - -LRESULT CALLBACK GInfo_IconBoxProc(HWND hCtl, UINT uMsg, WPARAM wParam, LPARAM lParam) -{ - switch(uMsg) - { - case WM_NCCREATE: - return 1; - - case WM_NCDESTROY: - return 1; - - case WM_ERASEBKGND: - return 1; - - case WM_PAINT: - GInfo_IconBoxPaint(hCtl, wParam, lParam); - return 1; - } - - return DefWindowProc(hCtl, uMsg, wParam, lParam); -} - -////////////////////////////////////////////////////////////////////////////// +/* Copyright (C) 2006 yopyop + yopyop156@ifrance.com + yopyop156.ifrance.com + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#include "resource.h" +#include "common.h" +#include "../MMU.h" +#include "../NDSSystem.h" +#include "FirmConfig.h" +#include +#include +#include +#include "ginfo.h" + +////////////////////////////////////////////////////////////////////////////// + +BOOL GInfo_Init() +{ + WNDCLASSEX wc; + + wc.cbSize = sizeof(wc); + wc.lpszClassName = "GInfo_IconBox"; + wc.hInstance = hAppInst; + wc.lpfnWndProc = GInfo_IconBoxProc; + wc.hCursor = LoadCursor(NULL, IDC_ARROW); + wc.hIcon = 0; + wc.lpszMenuName = 0; + wc.hbrBackground = GetSysColorBrush(COLOR_BTNFACE); + wc.style = 0; + wc.cbClsExtra = 0; + wc.cbWndExtra = 0; + wc.hIconSm = 0; + + RegisterClassEx(&wc); + + return 1; +} + +void GInfo_DeInit() +{ + UnregisterClass("GInfo_IconBox", hAppInst); +} + +////////////////////////////////////////////////////////////////////////////// + +BOOL GInfo_DlgOpen(HWND hParentWnd) +{ + HWND hDlg; + + hDlg = CreateDialog(hAppInst, MAKEINTRESOURCE(IDD_GAME_INFO), hParentWnd, GInfo_DlgProc); + if(hDlg == NULL) + return 0; + + ShowWindow(hDlg, SW_SHOW); + UpdateWindow(hDlg); + + return 1; +} + +////////////////////////////////////////////////////////////////////////////// + +LRESULT GInfo_Paint(HWND hDlg, WPARAM wParam, LPARAM lParam) +{ + HDC hdc; + PAINTSTRUCT ps; + char text[80]; + u32 icontitleOffset; + wchar_t *utf16text; + u32 val; + + hdc = BeginPaint(hDlg, &ps); + + icontitleOffset = T1ReadLong(MMU.CART_ROM, 0x68); + + if(icontitleOffset >= 0x8000) + { + utf16text = (wchar_t*)(MMU.CART_ROM + icontitleOffset + 0x240 + (0x100 * win_fw_config.language)); + sprintf(text, "%ws", utf16text); + SetWindowText(GetDlgItem(hDlg, IDC_GI_TITLE), text); + + utf16text = (wchar_t*)(MMU.CART_ROM + icontitleOffset + 0x240); + sprintf(text, "%ws", utf16text); + SetWindowText(GetDlgItem(hDlg, IDC_GI_TITLEJP), text); + + utf16text = (wchar_t*)(MMU.CART_ROM + icontitleOffset + 0x340); + sprintf(text, "%ws", utf16text); + SetWindowText(GetDlgItem(hDlg, IDC_GI_TITLEEN), text); + + utf16text = (wchar_t*)(MMU.CART_ROM + icontitleOffset + 0x440); + sprintf(text, "%ws", utf16text); + SetWindowText(GetDlgItem(hDlg, IDC_GI_TITLEFR), text); + + utf16text = (wchar_t*)(MMU.CART_ROM + icontitleOffset + 0x540); + sprintf(text, "%ws", utf16text); + SetWindowText(GetDlgItem(hDlg, IDC_GI_TITLEGE), text); + + utf16text = (wchar_t*)(MMU.CART_ROM + icontitleOffset + 0x640); + sprintf(text, "%ws", utf16text); + SetWindowText(GetDlgItem(hDlg, IDC_GI_TITLEIT), text); + + utf16text = (wchar_t*)(MMU.CART_ROM + icontitleOffset + 0x740); + sprintf(text, "%ws", utf16text); + SetWindowText(GetDlgItem(hDlg, IDC_GI_TITLESP), text); + } + else + { + SetWindowText(GetDlgItem(hDlg, IDC_GI_TITLE), "\nNo title\n"); + + SetWindowText(GetDlgItem(hDlg, IDC_GI_TITLEJP), "None"); + SetWindowText(GetDlgItem(hDlg, IDC_GI_TITLEEN), "None"); + SetWindowText(GetDlgItem(hDlg, IDC_GI_TITLEFR), "None"); + SetWindowText(GetDlgItem(hDlg, IDC_GI_TITLEGE), "None"); + SetWindowText(GetDlgItem(hDlg, IDC_GI_TITLEIT), "None"); + SetWindowText(GetDlgItem(hDlg, IDC_GI_TITLESP), "None"); + } + + + memcpy(text, MMU.CART_ROM, 12); + text[12] = '\0'; + SetWindowText(GetDlgItem(hDlg, IDC_GI_GAMETITLE), text); + + memcpy(text, (MMU.CART_ROM+0xC), 4); + text[4] = '\0'; + SetWindowText(GetDlgItem(hDlg, IDC_GI_GAMECODE), text); + + memcpy(text, (MMU.CART_ROM+0x10), 2); + text[2] = '\0'; + SetWindowText(GetDlgItem(hDlg, IDC_GI_MAKERCODE), text); + + val = T1ReadByte(MMU.CART_ROM, 0x14); + sprintf(text, "%i kilobytes", (0x80 << val)); + SetWindowText(GetDlgItem(hDlg, IDC_GI_CHIPSIZE), text); + + + val = T1ReadLong(MMU.CART_ROM, 0x20); + sprintf(text, "0x%08X", val); + SetWindowText(GetDlgItem(hDlg, IDC_GI_ARM9ROM), text); + + val = T1ReadLong(MMU.CART_ROM, 0x24); + sprintf(text, "0x%08X", val); + SetWindowText(GetDlgItem(hDlg, IDC_GI_ARM9ENTRY), text); + + val = T1ReadLong(MMU.CART_ROM, 0x28); + sprintf(text, "0x%08X", val); + SetWindowText(GetDlgItem(hDlg, IDC_GI_ARM9START), text); + + val = T1ReadLong(MMU.CART_ROM, 0x2C); + sprintf(text, "%i bytes", val); + SetWindowText(GetDlgItem(hDlg, IDC_GI_ARM9SIZE), text); + + val = T1ReadLong(MMU.CART_ROM, 0x30); + sprintf(text, "0x%08X", val); + SetWindowText(GetDlgItem(hDlg, IDC_GI_ARM7ROM), text); + + val = T1ReadLong(MMU.CART_ROM, 0x34); + sprintf(text, "0x%08X", val); + SetWindowText(GetDlgItem(hDlg, IDC_GI_ARM7ENTRY), text); + + val = T1ReadLong(MMU.CART_ROM, 0x38); + sprintf(text, "0x%08X", val); + SetWindowText(GetDlgItem(hDlg, IDC_GI_ARM7START), text); + + val = T1ReadLong(MMU.CART_ROM, 0x3C); + sprintf(text, "%i bytes", val); + SetWindowText(GetDlgItem(hDlg, IDC_GI_ARM7SIZE), text); + + + val = T1ReadLong(MMU.CART_ROM, 0x40); + sprintf(text, "0x%08X", val); + SetWindowText(GetDlgItem(hDlg, IDC_GI_FNTOFS), text); + + val = T1ReadLong(MMU.CART_ROM, 0x44); + sprintf(text, "%i bytes", val); + SetWindowText(GetDlgItem(hDlg, IDC_GI_FNTSIZE), text); + + val = T1ReadLong(MMU.CART_ROM, 0x48); + sprintf(text, "0x%08X", val); + SetWindowText(GetDlgItem(hDlg, IDC_GI_FATOFS), text); + + val = T1ReadLong(MMU.CART_ROM, 0x4C); + sprintf(text, "%i bytes", val); + SetWindowText(GetDlgItem(hDlg, IDC_GI_FATSIZE), text); + + + sprintf(text, "0x%08X", icontitleOffset); + SetWindowText(GetDlgItem(hDlg, IDC_GI_ICONTITLEOFS), text); + + val = T1ReadLong(MMU.CART_ROM, 0x80); + sprintf(text, "0x%08X", val); + SetWindowText(GetDlgItem(hDlg, IDC_GI_USEDROMSIZE), text); + + + EndPaint(hDlg, &ps); + + return 0; +} + +BOOL CALLBACK GInfo_DlgProc(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam) +{ + switch(uMsg) + { + case WM_INITDIALOG: + return 1; + + case WM_CLOSE: + EndDialog(hDlg, 0); + return 1; + + case WM_PAINT: + GInfo_Paint(hDlg, wParam, lParam); + return 1; + + case WM_COMMAND: + switch(LOWORD(wParam)) + { + case IDCANCEL: + EndDialog(hDlg, 0); + return 1; + } + return 0; + } + + return 0; +} + +////////////////////////////////////////////////////////////////////////////// + +LRESULT GInfo_IconBoxPaint(HWND hCtl, WPARAM wParam, LPARAM lParam) +{ + HDC hdc; + PAINTSTRUCT ps; + RECT rc; + int w, h; + SIZE fontsize; + HDC mem_hdc; + HBITMAP mem_bmp; + BITMAPV4HEADER bmph; + u32 icontitleOffset; + u16 icon[32 * 32]; + int x, y; + + GetClientRect(hCtl, &rc); + w = (rc.right - rc.left); + h = (rc.bottom - rc.top); + + hdc = BeginPaint(hCtl, &ps); + + mem_hdc = CreateCompatibleDC(hdc); + mem_bmp = CreateCompatibleBitmap(hdc, w, h); + SelectObject(mem_hdc, mem_bmp); + + FillRect(mem_hdc, &rc, (HBRUSH)GetStockObject(WHITE_BRUSH)); + + ZeroMemory(&bmph, sizeof(bmph)); + bmph.bV4Size = sizeof(bmph); + bmph.bV4Planes = 1; + bmph.bV4BitCount = 16; + bmph.bV4V4Compression = BI_BITFIELDS; + bmph.bV4RedMask = 0x001F; + bmph.bV4GreenMask = 0x03E0; + bmph.bV4BlueMask = 0x7C00; + bmph.bV4Width = 32; + bmph.bV4Height = -32; + + icontitleOffset = T1ReadLong(MMU.CART_ROM, 0x68); + + if(icontitleOffset >= 0x8000) + { + for(y = 0; y < 32; y++) + { + for(x = 0; x < 32; x++) + { + int tilenum = (((y / 8) * 4) + (x / 8)); + int tilex = (x % 8); + int tiley = (y % 8); + int mapoffset = ((tilenum * 64) + (tiley * 8) + tilex); + + u8 val = T1ReadByte(MMU.CART_ROM, (icontitleOffset + 0x20 + (mapoffset>>1))); + + if(mapoffset & 1) + val = ((val >> 4) & 0xF); + else + val = (val & 0xF); + + icon[(y * 32) + x] = T1ReadWord(MMU.CART_ROM, (icontitleOffset + 0x220 + (val<<1))); + } + } + + SetDIBitsToDevice(mem_hdc, ((w/2) - 16), ((h/2) - 16), 32, 32, 0, 0, 0, 32, icon, (BITMAPINFO*)&bmph, DIB_RGB_COLORS); + } + else + { + char *noicon = "No icon"; + GetTextExtentPoint32(mem_hdc, noicon, strlen(noicon), &fontsize); + TextOut(mem_hdc, ((w/2) - (fontsize.cx/2)), ((h/2) - (fontsize.cy/2)), noicon, strlen(noicon)); + } + + BitBlt(hdc, 0, 0, w, h, mem_hdc, 0, 0, SRCCOPY); + + DeleteDC(mem_hdc); + DeleteObject(mem_bmp); + + EndPaint(hCtl, &ps); + + return 0; +} + +LRESULT CALLBACK GInfo_IconBoxProc(HWND hCtl, UINT uMsg, WPARAM wParam, LPARAM lParam) +{ + switch(uMsg) + { + case WM_NCCREATE: + return 1; + + case WM_NCDESTROY: + return 1; + + case WM_ERASEBKGND: + return 1; + + case WM_PAINT: + GInfo_IconBoxPaint(hCtl, wParam, lParam); + return 1; + } + + return DefWindowProc(hCtl, uMsg, wParam, lParam); +} + +////////////////////////////////////////////////////////////////////////////// diff --git a/desmume/src/windows/ginfo.h b/src/windows/ginfo.h similarity index 97% rename from desmume/src/windows/ginfo.h rename to src/windows/ginfo.h index 5b9855f69..09dfa4a9e 100644 --- a/desmume/src/windows/ginfo.h +++ b/src/windows/ginfo.h @@ -1,33 +1,33 @@ -/* Copyright (C) 2006 yopyop - yopyop156@ifrance.com - yopyop156.ifrance.com - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#ifndef GINFO_H -#define GINFO_H - -BOOL GInfo_Init(); -void GInfo_DeInit(); - -BOOL GInfo_DlgOpen(HWND hParentWnd); - -BOOL CALLBACK GInfo_DlgProc(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam); -LRESULT CALLBACK GInfo_IconBoxProc(HWND hCtl, UINT uMsg, WPARAM wParam, LPARAM lParam); - -#endif +/* Copyright (C) 2006 yopyop + yopyop156@ifrance.com + yopyop156.ifrance.com + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#ifndef GINFO_H +#define GINFO_H + +BOOL GInfo_Init(); +void GInfo_DeInit(); + +BOOL GInfo_DlgOpen(HWND hParentWnd); + +BOOL CALLBACK GInfo_DlgProc(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam); +LRESULT CALLBACK GInfo_IconBoxProc(HWND hCtl, UINT uMsg, WPARAM wParam, LPARAM lParam); + +#endif diff --git a/desmume/src/windows/glib-2.20.1/build/dependencies/proxy-libintl-20080918/include/libintl.h b/src/windows/glib-2.20.1/build/dependencies/proxy-libintl-20080918/include/libintl.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/dependencies/proxy-libintl-20080918/include/libintl.h rename to src/windows/glib-2.20.1/build/dependencies/proxy-libintl-20080918/include/libintl.h diff --git a/desmume/src/windows/glib-2.20.1/build/dirent/README b/src/windows/glib-2.20.1/build/dirent/README similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/dirent/README rename to src/windows/glib-2.20.1/build/dirent/README diff --git a/desmume/src/windows/glib-2.20.1/build/dirent/dirent.c b/src/windows/glib-2.20.1/build/dirent/dirent.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/dirent/dirent.c rename to src/windows/glib-2.20.1/build/dirent/dirent.c diff --git a/desmume/src/windows/glib-2.20.1/build/dirent/dirent.h b/src/windows/glib-2.20.1/build/dirent/dirent.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/dirent/dirent.h rename to src/windows/glib-2.20.1/build/dirent/dirent.h diff --git a/desmume/src/windows/glib-2.20.1/build/dirent/wdirent.c b/src/windows/glib-2.20.1/build/dirent/wdirent.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/dirent/wdirent.c rename to src/windows/glib-2.20.1/build/dirent/wdirent.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/config.h b/src/windows/glib-2.20.1/build/glib/config.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/config.h rename to src/windows/glib-2.20.1/build/glib/config.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/galias.h b/src/windows/glib-2.20.1/build/glib/galias.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/galias.h rename to src/windows/glib-2.20.1/build/glib/galias.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/galiasdef.c b/src/windows/glib-2.20.1/build/glib/galiasdef.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/galiasdef.c rename to src/windows/glib-2.20.1/build/glib/galiasdef.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/galloca.h b/src/windows/glib-2.20.1/build/glib/galloca.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/galloca.h rename to src/windows/glib-2.20.1/build/glib/galloca.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/garray.c b/src/windows/glib-2.20.1/build/glib/garray.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/garray.c rename to src/windows/glib-2.20.1/build/glib/garray.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/garray.h b/src/windows/glib-2.20.1/build/glib/garray.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/garray.h rename to src/windows/glib-2.20.1/build/glib/garray.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gasyncqueue.c b/src/windows/glib-2.20.1/build/glib/gasyncqueue.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gasyncqueue.c rename to src/windows/glib-2.20.1/build/glib/gasyncqueue.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gasyncqueue.h b/src/windows/glib-2.20.1/build/glib/gasyncqueue.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gasyncqueue.h rename to src/windows/glib-2.20.1/build/glib/gasyncqueue.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gatomic.c b/src/windows/glib-2.20.1/build/glib/gatomic.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gatomic.c rename to src/windows/glib-2.20.1/build/glib/gatomic.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gatomic.h b/src/windows/glib-2.20.1/build/glib/gatomic.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gatomic.h rename to src/windows/glib-2.20.1/build/glib/gatomic.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gbacktrace.c b/src/windows/glib-2.20.1/build/glib/gbacktrace.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gbacktrace.c rename to src/windows/glib-2.20.1/build/glib/gbacktrace.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gbacktrace.h b/src/windows/glib-2.20.1/build/glib/gbacktrace.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gbacktrace.h rename to src/windows/glib-2.20.1/build/glib/gbacktrace.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gbase64.c b/src/windows/glib-2.20.1/build/glib/gbase64.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gbase64.c rename to src/windows/glib-2.20.1/build/glib/gbase64.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gbase64.h b/src/windows/glib-2.20.1/build/glib/gbase64.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gbase64.h rename to src/windows/glib-2.20.1/build/glib/gbase64.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gbookmarkfile.c b/src/windows/glib-2.20.1/build/glib/gbookmarkfile.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gbookmarkfile.c rename to src/windows/glib-2.20.1/build/glib/gbookmarkfile.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gbookmarkfile.h b/src/windows/glib-2.20.1/build/glib/gbookmarkfile.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gbookmarkfile.h rename to src/windows/glib-2.20.1/build/glib/gbookmarkfile.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gbsearcharray.h b/src/windows/glib-2.20.1/build/glib/gbsearcharray.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gbsearcharray.h rename to src/windows/glib-2.20.1/build/glib/gbsearcharray.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gcache.c b/src/windows/glib-2.20.1/build/glib/gcache.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gcache.c rename to src/windows/glib-2.20.1/build/glib/gcache.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gcache.h b/src/windows/glib-2.20.1/build/glib/gcache.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gcache.h rename to src/windows/glib-2.20.1/build/glib/gcache.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gchecksum.c b/src/windows/glib-2.20.1/build/glib/gchecksum.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gchecksum.c rename to src/windows/glib-2.20.1/build/glib/gchecksum.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gchecksum.h b/src/windows/glib-2.20.1/build/glib/gchecksum.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gchecksum.h rename to src/windows/glib-2.20.1/build/glib/gchecksum.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gcompletion.c b/src/windows/glib-2.20.1/build/glib/gcompletion.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gcompletion.c rename to src/windows/glib-2.20.1/build/glib/gcompletion.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gcompletion.h b/src/windows/glib-2.20.1/build/glib/gcompletion.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gcompletion.h rename to src/windows/glib-2.20.1/build/glib/gcompletion.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gconvert.c b/src/windows/glib-2.20.1/build/glib/gconvert.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gconvert.c rename to src/windows/glib-2.20.1/build/glib/gconvert.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gconvert.h b/src/windows/glib-2.20.1/build/glib/gconvert.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gconvert.h rename to src/windows/glib-2.20.1/build/glib/gconvert.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gdataset.c b/src/windows/glib-2.20.1/build/glib/gdataset.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gdataset.c rename to src/windows/glib-2.20.1/build/glib/gdataset.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gdataset.h b/src/windows/glib-2.20.1/build/glib/gdataset.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gdataset.h rename to src/windows/glib-2.20.1/build/glib/gdataset.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gdatasetprivate.h b/src/windows/glib-2.20.1/build/glib/gdatasetprivate.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gdatasetprivate.h rename to src/windows/glib-2.20.1/build/glib/gdatasetprivate.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gdate.c b/src/windows/glib-2.20.1/build/glib/gdate.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gdate.c rename to src/windows/glib-2.20.1/build/glib/gdate.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gdate.h b/src/windows/glib-2.20.1/build/glib/gdate.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gdate.h rename to src/windows/glib-2.20.1/build/glib/gdate.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gdebug.h b/src/windows/glib-2.20.1/build/glib/gdebug.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gdebug.h rename to src/windows/glib-2.20.1/build/glib/gdebug.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gdir.c b/src/windows/glib-2.20.1/build/glib/gdir.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gdir.c rename to src/windows/glib-2.20.1/build/glib/gdir.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gdir.h b/src/windows/glib-2.20.1/build/glib/gdir.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gdir.h rename to src/windows/glib-2.20.1/build/glib/gdir.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gerror.c b/src/windows/glib-2.20.1/build/glib/gerror.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gerror.c rename to src/windows/glib-2.20.1/build/glib/gerror.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gerror.h b/src/windows/glib-2.20.1/build/glib/gerror.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gerror.h rename to src/windows/glib-2.20.1/build/glib/gerror.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gfileutils.c b/src/windows/glib-2.20.1/build/glib/gfileutils.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gfileutils.c rename to src/windows/glib-2.20.1/build/glib/gfileutils.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gfileutils.h b/src/windows/glib-2.20.1/build/glib/gfileutils.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gfileutils.h rename to src/windows/glib-2.20.1/build/glib/gfileutils.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/ghash.c b/src/windows/glib-2.20.1/build/glib/ghash.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/ghash.c rename to src/windows/glib-2.20.1/build/glib/ghash.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/ghash.h b/src/windows/glib-2.20.1/build/glib/ghash.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/ghash.h rename to src/windows/glib-2.20.1/build/glib/ghash.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/ghook.c b/src/windows/glib-2.20.1/build/glib/ghook.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/ghook.c rename to src/windows/glib-2.20.1/build/glib/ghook.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/ghook.h b/src/windows/glib-2.20.1/build/glib/ghook.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/ghook.h rename to src/windows/glib-2.20.1/build/glib/ghook.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gi18n-lib.h b/src/windows/glib-2.20.1/build/glib/gi18n-lib.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gi18n-lib.h rename to src/windows/glib-2.20.1/build/glib/gi18n-lib.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gi18n.h b/src/windows/glib-2.20.1/build/glib/gi18n.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gi18n.h rename to src/windows/glib-2.20.1/build/glib/gi18n.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/giochannel.c b/src/windows/glib-2.20.1/build/glib/giochannel.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/giochannel.c rename to src/windows/glib-2.20.1/build/glib/giochannel.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/giochannel.h b/src/windows/glib-2.20.1/build/glib/giochannel.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/giochannel.h rename to src/windows/glib-2.20.1/build/glib/giochannel.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/giounix.c b/src/windows/glib-2.20.1/build/glib/giounix.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/giounix.c rename to src/windows/glib-2.20.1/build/glib/giounix.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/giowin32.c b/src/windows/glib-2.20.1/build/glib/giowin32.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/giowin32.c rename to src/windows/glib-2.20.1/build/glib/giowin32.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gkeyfile.c b/src/windows/glib-2.20.1/build/glib/gkeyfile.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gkeyfile.c rename to src/windows/glib-2.20.1/build/glib/gkeyfile.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gkeyfile.h b/src/windows/glib-2.20.1/build/glib/gkeyfile.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gkeyfile.h rename to src/windows/glib-2.20.1/build/glib/gkeyfile.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/glib-object.h b/src/windows/glib-2.20.1/build/glib/glib-object.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/glib-object.h rename to src/windows/glib-2.20.1/build/glib/glib-object.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/glib.h b/src/windows/glib-2.20.1/build/glib/glib.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/glib.h rename to src/windows/glib-2.20.1/build/glib/glib.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/glibintl.h b/src/windows/glib-2.20.1/build/glib/glibintl.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/glibintl.h rename to src/windows/glib-2.20.1/build/glib/glibintl.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/glist.c b/src/windows/glib-2.20.1/build/glib/glist.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/glist.c rename to src/windows/glib-2.20.1/build/glib/glist.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/glist.h b/src/windows/glib-2.20.1/build/glib/glist.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/glist.h rename to src/windows/glib-2.20.1/build/glib/glist.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gmacros.h b/src/windows/glib-2.20.1/build/glib/gmacros.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gmacros.h rename to src/windows/glib-2.20.1/build/glib/gmacros.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gmain.c b/src/windows/glib-2.20.1/build/glib/gmain.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gmain.c rename to src/windows/glib-2.20.1/build/glib/gmain.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gmain.h b/src/windows/glib-2.20.1/build/glib/gmain.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gmain.h rename to src/windows/glib-2.20.1/build/glib/gmain.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gmappedfile.c b/src/windows/glib-2.20.1/build/glib/gmappedfile.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gmappedfile.c rename to src/windows/glib-2.20.1/build/glib/gmappedfile.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gmappedfile.h b/src/windows/glib-2.20.1/build/glib/gmappedfile.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gmappedfile.h rename to src/windows/glib-2.20.1/build/glib/gmappedfile.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gmarkup.c b/src/windows/glib-2.20.1/build/glib/gmarkup.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gmarkup.c rename to src/windows/glib-2.20.1/build/glib/gmarkup.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gmarkup.h b/src/windows/glib-2.20.1/build/glib/gmarkup.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gmarkup.h rename to src/windows/glib-2.20.1/build/glib/gmarkup.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gmem.c b/src/windows/glib-2.20.1/build/glib/gmem.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gmem.c rename to src/windows/glib-2.20.1/build/glib/gmem.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gmem.h b/src/windows/glib-2.20.1/build/glib/gmem.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gmem.h rename to src/windows/glib-2.20.1/build/glib/gmem.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gmessages.c b/src/windows/glib-2.20.1/build/glib/gmessages.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gmessages.c rename to src/windows/glib-2.20.1/build/glib/gmessages.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gmessages.h b/src/windows/glib-2.20.1/build/glib/gmessages.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gmessages.h rename to src/windows/glib-2.20.1/build/glib/gmessages.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gmirroringtable.h b/src/windows/glib-2.20.1/build/glib/gmirroringtable.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gmirroringtable.h rename to src/windows/glib-2.20.1/build/glib/gmirroringtable.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gnode.c b/src/windows/glib-2.20.1/build/glib/gnode.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gnode.c rename to src/windows/glib-2.20.1/build/glib/gnode.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gnode.h b/src/windows/glib-2.20.1/build/glib/gnode.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gnode.h rename to src/windows/glib-2.20.1/build/glib/gnode.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gnulib/README b/src/windows/glib-2.20.1/build/glib/gnulib/README similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gnulib/README rename to src/windows/glib-2.20.1/build/glib/gnulib/README diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gnulib/asnprintf.c b/src/windows/glib-2.20.1/build/glib/gnulib/asnprintf.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gnulib/asnprintf.c rename to src/windows/glib-2.20.1/build/glib/gnulib/asnprintf.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gnulib/g-gnulib.h b/src/windows/glib-2.20.1/build/glib/gnulib/g-gnulib.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gnulib/g-gnulib.h rename to src/windows/glib-2.20.1/build/glib/gnulib/g-gnulib.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gnulib/printf-args.c b/src/windows/glib-2.20.1/build/glib/gnulib/printf-args.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gnulib/printf-args.c rename to src/windows/glib-2.20.1/build/glib/gnulib/printf-args.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gnulib/printf-args.h b/src/windows/glib-2.20.1/build/glib/gnulib/printf-args.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gnulib/printf-args.h rename to src/windows/glib-2.20.1/build/glib/gnulib/printf-args.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gnulib/printf-parse.c b/src/windows/glib-2.20.1/build/glib/gnulib/printf-parse.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gnulib/printf-parse.c rename to src/windows/glib-2.20.1/build/glib/gnulib/printf-parse.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gnulib/printf-parse.h b/src/windows/glib-2.20.1/build/glib/gnulib/printf-parse.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gnulib/printf-parse.h rename to src/windows/glib-2.20.1/build/glib/gnulib/printf-parse.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gnulib/printf.c b/src/windows/glib-2.20.1/build/glib/gnulib/printf.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gnulib/printf.c rename to src/windows/glib-2.20.1/build/glib/gnulib/printf.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gnulib/printf.h b/src/windows/glib-2.20.1/build/glib/gnulib/printf.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gnulib/printf.h rename to src/windows/glib-2.20.1/build/glib/gnulib/printf.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gnulib/vasnprintf.c b/src/windows/glib-2.20.1/build/glib/gnulib/vasnprintf.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gnulib/vasnprintf.c rename to src/windows/glib-2.20.1/build/glib/gnulib/vasnprintf.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gnulib/vasnprintf.h b/src/windows/glib-2.20.1/build/glib/gnulib/vasnprintf.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gnulib/vasnprintf.h rename to src/windows/glib-2.20.1/build/glib/gnulib/vasnprintf.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/goption.c b/src/windows/glib-2.20.1/build/glib/goption.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/goption.c rename to src/windows/glib-2.20.1/build/glib/goption.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/goption.h b/src/windows/glib-2.20.1/build/glib/goption.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/goption.h rename to src/windows/glib-2.20.1/build/glib/goption.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gpattern.c b/src/windows/glib-2.20.1/build/glib/gpattern.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gpattern.c rename to src/windows/glib-2.20.1/build/glib/gpattern.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gpattern.h b/src/windows/glib-2.20.1/build/glib/gpattern.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gpattern.h rename to src/windows/glib-2.20.1/build/glib/gpattern.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gpoll.c b/src/windows/glib-2.20.1/build/glib/gpoll.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gpoll.c rename to src/windows/glib-2.20.1/build/glib/gpoll.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gpoll.h b/src/windows/glib-2.20.1/build/glib/gpoll.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gpoll.h rename to src/windows/glib-2.20.1/build/glib/gpoll.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gprimes.c b/src/windows/glib-2.20.1/build/glib/gprimes.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gprimes.c rename to src/windows/glib-2.20.1/build/glib/gprimes.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gprimes.h b/src/windows/glib-2.20.1/build/glib/gprimes.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gprimes.h rename to src/windows/glib-2.20.1/build/glib/gprimes.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gprintf.c b/src/windows/glib-2.20.1/build/glib/gprintf.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gprintf.c rename to src/windows/glib-2.20.1/build/glib/gprintf.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gprintf.h b/src/windows/glib-2.20.1/build/glib/gprintf.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gprintf.h rename to src/windows/glib-2.20.1/build/glib/gprintf.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gprintfint.h b/src/windows/glib-2.20.1/build/glib/gprintfint.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gprintfint.h rename to src/windows/glib-2.20.1/build/glib/gprintfint.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gqsort.c b/src/windows/glib-2.20.1/build/glib/gqsort.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gqsort.c rename to src/windows/glib-2.20.1/build/glib/gqsort.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gqsort.h b/src/windows/glib-2.20.1/build/glib/gqsort.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gqsort.h rename to src/windows/glib-2.20.1/build/glib/gqsort.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gquark.h b/src/windows/glib-2.20.1/build/glib/gquark.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gquark.h rename to src/windows/glib-2.20.1/build/glib/gquark.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gqueue.c b/src/windows/glib-2.20.1/build/glib/gqueue.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gqueue.c rename to src/windows/glib-2.20.1/build/glib/gqueue.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gqueue.h b/src/windows/glib-2.20.1/build/glib/gqueue.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gqueue.h rename to src/windows/glib-2.20.1/build/glib/gqueue.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/grand.c b/src/windows/glib-2.20.1/build/glib/grand.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/grand.c rename to src/windows/glib-2.20.1/build/glib/grand.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/grand.h b/src/windows/glib-2.20.1/build/glib/grand.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/grand.h rename to src/windows/glib-2.20.1/build/glib/grand.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gregex.c b/src/windows/glib-2.20.1/build/glib/gregex.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gregex.c rename to src/windows/glib-2.20.1/build/glib/gregex.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gregex.h b/src/windows/glib-2.20.1/build/glib/gregex.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gregex.h rename to src/windows/glib-2.20.1/build/glib/gregex.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/grel.c b/src/windows/glib-2.20.1/build/glib/grel.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/grel.c rename to src/windows/glib-2.20.1/build/glib/grel.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/grel.h b/src/windows/glib-2.20.1/build/glib/grel.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/grel.h rename to src/windows/glib-2.20.1/build/glib/grel.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gscanner.c b/src/windows/glib-2.20.1/build/glib/gscanner.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gscanner.c rename to src/windows/glib-2.20.1/build/glib/gscanner.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gscanner.h b/src/windows/glib-2.20.1/build/glib/gscanner.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gscanner.h rename to src/windows/glib-2.20.1/build/glib/gscanner.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gscripttable.h b/src/windows/glib-2.20.1/build/glib/gscripttable.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gscripttable.h rename to src/windows/glib-2.20.1/build/glib/gscripttable.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gsequence.c b/src/windows/glib-2.20.1/build/glib/gsequence.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gsequence.c rename to src/windows/glib-2.20.1/build/glib/gsequence.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gsequence.h b/src/windows/glib-2.20.1/build/glib/gsequence.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gsequence.h rename to src/windows/glib-2.20.1/build/glib/gsequence.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gshell.c b/src/windows/glib-2.20.1/build/glib/gshell.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gshell.c rename to src/windows/glib-2.20.1/build/glib/gshell.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gshell.h b/src/windows/glib-2.20.1/build/glib/gshell.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gshell.h rename to src/windows/glib-2.20.1/build/glib/gshell.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gslice.c b/src/windows/glib-2.20.1/build/glib/gslice.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gslice.c rename to src/windows/glib-2.20.1/build/glib/gslice.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gslice.h b/src/windows/glib-2.20.1/build/glib/gslice.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gslice.h rename to src/windows/glib-2.20.1/build/glib/gslice.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gslist.c b/src/windows/glib-2.20.1/build/glib/gslist.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gslist.c rename to src/windows/glib-2.20.1/build/glib/gslist.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gslist.h b/src/windows/glib-2.20.1/build/glib/gslist.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gslist.h rename to src/windows/glib-2.20.1/build/glib/gslist.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gspawn-win32-helper-console.c b/src/windows/glib-2.20.1/build/glib/gspawn-win32-helper-console.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gspawn-win32-helper-console.c rename to src/windows/glib-2.20.1/build/glib/gspawn-win32-helper-console.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gspawn-win32-helper.c b/src/windows/glib-2.20.1/build/glib/gspawn-win32-helper.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gspawn-win32-helper.c rename to src/windows/glib-2.20.1/build/glib/gspawn-win32-helper.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gspawn-win32.c b/src/windows/glib-2.20.1/build/glib/gspawn-win32.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gspawn-win32.c rename to src/windows/glib-2.20.1/build/glib/gspawn-win32.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gspawn-win64-helper-console.c b/src/windows/glib-2.20.1/build/glib/gspawn-win64-helper-console.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gspawn-win64-helper-console.c rename to src/windows/glib-2.20.1/build/glib/gspawn-win64-helper-console.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gspawn-win64-helper.c b/src/windows/glib-2.20.1/build/glib/gspawn-win64-helper.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gspawn-win64-helper.c rename to src/windows/glib-2.20.1/build/glib/gspawn-win64-helper.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gspawn.c b/src/windows/glib-2.20.1/build/glib/gspawn.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gspawn.c rename to src/windows/glib-2.20.1/build/glib/gspawn.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gspawn.h b/src/windows/glib-2.20.1/build/glib/gspawn.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gspawn.h rename to src/windows/glib-2.20.1/build/glib/gspawn.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gstdio.c b/src/windows/glib-2.20.1/build/glib/gstdio.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gstdio.c rename to src/windows/glib-2.20.1/build/glib/gstdio.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gstdio.h b/src/windows/glib-2.20.1/build/glib/gstdio.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gstdio.h rename to src/windows/glib-2.20.1/build/glib/gstdio.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gstrfuncs.c b/src/windows/glib-2.20.1/build/glib/gstrfuncs.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gstrfuncs.c rename to src/windows/glib-2.20.1/build/glib/gstrfuncs.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gstrfuncs.h b/src/windows/glib-2.20.1/build/glib/gstrfuncs.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gstrfuncs.h rename to src/windows/glib-2.20.1/build/glib/gstrfuncs.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gstring.c b/src/windows/glib-2.20.1/build/glib/gstring.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gstring.c rename to src/windows/glib-2.20.1/build/glib/gstring.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gstring.h b/src/windows/glib-2.20.1/build/glib/gstring.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gstring.h rename to src/windows/glib-2.20.1/build/glib/gstring.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gtester.c b/src/windows/glib-2.20.1/build/glib/gtester.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gtester.c rename to src/windows/glib-2.20.1/build/glib/gtester.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gtestutils.c b/src/windows/glib-2.20.1/build/glib/gtestutils.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gtestutils.c rename to src/windows/glib-2.20.1/build/glib/gtestutils.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gtestutils.h b/src/windows/glib-2.20.1/build/glib/gtestutils.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gtestutils.h rename to src/windows/glib-2.20.1/build/glib/gtestutils.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gthread.c b/src/windows/glib-2.20.1/build/glib/gthread.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gthread.c rename to src/windows/glib-2.20.1/build/glib/gthread.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gthread.h b/src/windows/glib-2.20.1/build/glib/gthread.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gthread.h rename to src/windows/glib-2.20.1/build/glib/gthread.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gthreadpool.c b/src/windows/glib-2.20.1/build/glib/gthreadpool.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gthreadpool.c rename to src/windows/glib-2.20.1/build/glib/gthreadpool.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gthreadpool.h b/src/windows/glib-2.20.1/build/glib/gthreadpool.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gthreadpool.h rename to src/windows/glib-2.20.1/build/glib/gthreadpool.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gthreadprivate.h b/src/windows/glib-2.20.1/build/glib/gthreadprivate.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gthreadprivate.h rename to src/windows/glib-2.20.1/build/glib/gthreadprivate.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gtimer.c b/src/windows/glib-2.20.1/build/glib/gtimer.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gtimer.c rename to src/windows/glib-2.20.1/build/glib/gtimer.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gtimer.h b/src/windows/glib-2.20.1/build/glib/gtimer.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gtimer.h rename to src/windows/glib-2.20.1/build/glib/gtimer.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gtree.c b/src/windows/glib-2.20.1/build/glib/gtree.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gtree.c rename to src/windows/glib-2.20.1/build/glib/gtree.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gtree.h b/src/windows/glib-2.20.1/build/glib/gtree.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gtree.h rename to src/windows/glib-2.20.1/build/glib/gtree.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gtypes.h b/src/windows/glib-2.20.1/build/glib/gtypes.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gtypes.h rename to src/windows/glib-2.20.1/build/glib/gtypes.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gunibreak.c b/src/windows/glib-2.20.1/build/glib/gunibreak.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gunibreak.c rename to src/windows/glib-2.20.1/build/glib/gunibreak.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gunibreak.h b/src/windows/glib-2.20.1/build/glib/gunibreak.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gunibreak.h rename to src/windows/glib-2.20.1/build/glib/gunibreak.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gunichartables.h b/src/windows/glib-2.20.1/build/glib/gunichartables.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gunichartables.h rename to src/windows/glib-2.20.1/build/glib/gunichartables.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gunicode.h b/src/windows/glib-2.20.1/build/glib/gunicode.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gunicode.h rename to src/windows/glib-2.20.1/build/glib/gunicode.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gunicodeprivate.h b/src/windows/glib-2.20.1/build/glib/gunicodeprivate.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gunicodeprivate.h rename to src/windows/glib-2.20.1/build/glib/gunicodeprivate.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gunicollate.c b/src/windows/glib-2.20.1/build/glib/gunicollate.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gunicollate.c rename to src/windows/glib-2.20.1/build/glib/gunicollate.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gunicomp.h b/src/windows/glib-2.20.1/build/glib/gunicomp.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gunicomp.h rename to src/windows/glib-2.20.1/build/glib/gunicomp.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gunidecomp.c b/src/windows/glib-2.20.1/build/glib/gunidecomp.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gunidecomp.c rename to src/windows/glib-2.20.1/build/glib/gunidecomp.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gunidecomp.h b/src/windows/glib-2.20.1/build/glib/gunidecomp.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gunidecomp.h rename to src/windows/glib-2.20.1/build/glib/gunidecomp.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/guniprop.c b/src/windows/glib-2.20.1/build/glib/guniprop.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/guniprop.c rename to src/windows/glib-2.20.1/build/glib/guniprop.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gurifuncs.c b/src/windows/glib-2.20.1/build/glib/gurifuncs.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gurifuncs.c rename to src/windows/glib-2.20.1/build/glib/gurifuncs.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gurifuncs.h b/src/windows/glib-2.20.1/build/glib/gurifuncs.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gurifuncs.h rename to src/windows/glib-2.20.1/build/glib/gurifuncs.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gutf8.c b/src/windows/glib-2.20.1/build/glib/gutf8.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gutf8.c rename to src/windows/glib-2.20.1/build/glib/gutf8.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gutils.c b/src/windows/glib-2.20.1/build/glib/gutils.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gutils.c rename to src/windows/glib-2.20.1/build/glib/gutils.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gutils.h b/src/windows/glib-2.20.1/build/glib/gutils.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gutils.h rename to src/windows/glib-2.20.1/build/glib/gutils.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gwin32.c b/src/windows/glib-2.20.1/build/glib/gwin32.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gwin32.c rename to src/windows/glib-2.20.1/build/glib/gwin32.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/gwin32.h b/src/windows/glib-2.20.1/build/glib/gwin32.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/gwin32.h rename to src/windows/glib-2.20.1/build/glib/gwin32.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/libcharset/README b/src/windows/glib-2.20.1/build/glib/libcharset/README similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/libcharset/README rename to src/windows/glib-2.20.1/build/glib/libcharset/README diff --git a/desmume/src/windows/glib-2.20.1/build/glib/libcharset/libcharset.h b/src/windows/glib-2.20.1/build/glib/libcharset/libcharset.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/libcharset/libcharset.h rename to src/windows/glib-2.20.1/build/glib/libcharset/libcharset.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/libcharset/localcharset.c b/src/windows/glib-2.20.1/build/glib/libcharset/localcharset.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/libcharset/localcharset.c rename to src/windows/glib-2.20.1/build/glib/libcharset/localcharset.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/libcharset/localcharset.h b/src/windows/glib-2.20.1/build/glib/libcharset/localcharset.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/libcharset/localcharset.h rename to src/windows/glib-2.20.1/build/glib/libcharset/localcharset.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/libintl.h b/src/windows/glib-2.20.1/build/glib/libintl.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/libintl.h rename to src/windows/glib-2.20.1/build/glib/libintl.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/msvc_recommended_pragmas.h b/src/windows/glib-2.20.1/build/glib/msvc_recommended_pragmas.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/msvc_recommended_pragmas.h rename to src/windows/glib-2.20.1/build/glib/msvc_recommended_pragmas.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/pcre/COPYING b/src/windows/glib-2.20.1/build/glib/pcre/COPYING similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/pcre/COPYING rename to src/windows/glib-2.20.1/build/glib/pcre/COPYING diff --git a/desmume/src/windows/glib-2.20.1/build/glib/pcre/pcre.h b/src/windows/glib-2.20.1/build/glib/pcre/pcre.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/pcre/pcre.h rename to src/windows/glib-2.20.1/build/glib/pcre/pcre.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/pcre/pcre_chartables.c b/src/windows/glib-2.20.1/build/glib/pcre/pcre_chartables.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/pcre/pcre_chartables.c rename to src/windows/glib-2.20.1/build/glib/pcre/pcre_chartables.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/pcre/pcre_compile.c b/src/windows/glib-2.20.1/build/glib/pcre/pcre_compile.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/pcre/pcre_compile.c rename to src/windows/glib-2.20.1/build/glib/pcre/pcre_compile.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/pcre/pcre_config.c b/src/windows/glib-2.20.1/build/glib/pcre/pcre_config.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/pcre/pcre_config.c rename to src/windows/glib-2.20.1/build/glib/pcre/pcre_config.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/pcre/pcre_dfa_exec.c b/src/windows/glib-2.20.1/build/glib/pcre/pcre_dfa_exec.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/pcre/pcre_dfa_exec.c rename to src/windows/glib-2.20.1/build/glib/pcre/pcre_dfa_exec.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/pcre/pcre_exec.c b/src/windows/glib-2.20.1/build/glib/pcre/pcre_exec.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/pcre/pcre_exec.c rename to src/windows/glib-2.20.1/build/glib/pcre/pcre_exec.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/pcre/pcre_fullinfo.c b/src/windows/glib-2.20.1/build/glib/pcre/pcre_fullinfo.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/pcre/pcre_fullinfo.c rename to src/windows/glib-2.20.1/build/glib/pcre/pcre_fullinfo.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/pcre/pcre_get.c b/src/windows/glib-2.20.1/build/glib/pcre/pcre_get.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/pcre/pcre_get.c rename to src/windows/glib-2.20.1/build/glib/pcre/pcre_get.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/pcre/pcre_globals.c b/src/windows/glib-2.20.1/build/glib/pcre/pcre_globals.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/pcre/pcre_globals.c rename to src/windows/glib-2.20.1/build/glib/pcre/pcre_globals.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/pcre/pcre_info.c b/src/windows/glib-2.20.1/build/glib/pcre/pcre_info.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/pcre/pcre_info.c rename to src/windows/glib-2.20.1/build/glib/pcre/pcre_info.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/pcre/pcre_internal.h b/src/windows/glib-2.20.1/build/glib/pcre/pcre_internal.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/pcre/pcre_internal.h rename to src/windows/glib-2.20.1/build/glib/pcre/pcre_internal.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/pcre/pcre_maketables.c b/src/windows/glib-2.20.1/build/glib/pcre/pcre_maketables.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/pcre/pcre_maketables.c rename to src/windows/glib-2.20.1/build/glib/pcre/pcre_maketables.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/pcre/pcre_newline.c b/src/windows/glib-2.20.1/build/glib/pcre/pcre_newline.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/pcre/pcre_newline.c rename to src/windows/glib-2.20.1/build/glib/pcre/pcre_newline.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/pcre/pcre_ord2utf8.c b/src/windows/glib-2.20.1/build/glib/pcre/pcre_ord2utf8.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/pcre/pcre_ord2utf8.c rename to src/windows/glib-2.20.1/build/glib/pcre/pcre_ord2utf8.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/pcre/pcre_refcount.c b/src/windows/glib-2.20.1/build/glib/pcre/pcre_refcount.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/pcre/pcre_refcount.c rename to src/windows/glib-2.20.1/build/glib/pcre/pcre_refcount.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/pcre/pcre_study.c b/src/windows/glib-2.20.1/build/glib/pcre/pcre_study.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/pcre/pcre_study.c rename to src/windows/glib-2.20.1/build/glib/pcre/pcre_study.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/pcre/pcre_tables.c b/src/windows/glib-2.20.1/build/glib/pcre/pcre_tables.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/pcre/pcre_tables.c rename to src/windows/glib-2.20.1/build/glib/pcre/pcre_tables.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/pcre/pcre_try_flipped.c b/src/windows/glib-2.20.1/build/glib/pcre/pcre_try_flipped.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/pcre/pcre_try_flipped.c rename to src/windows/glib-2.20.1/build/glib/pcre/pcre_try_flipped.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/pcre/pcre_ucp_searchfuncs.c b/src/windows/glib-2.20.1/build/glib/pcre/pcre_ucp_searchfuncs.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/pcre/pcre_ucp_searchfuncs.c rename to src/windows/glib-2.20.1/build/glib/pcre/pcre_ucp_searchfuncs.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/pcre/pcre_valid_utf8.c b/src/windows/glib-2.20.1/build/glib/pcre/pcre_valid_utf8.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/pcre/pcre_valid_utf8.c rename to src/windows/glib-2.20.1/build/glib/pcre/pcre_valid_utf8.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/pcre/pcre_version.c b/src/windows/glib-2.20.1/build/glib/pcre/pcre_version.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/pcre/pcre_version.c rename to src/windows/glib-2.20.1/build/glib/pcre/pcre_version.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/pcre/pcre_xclass.c b/src/windows/glib-2.20.1/build/glib/pcre/pcre_xclass.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/pcre/pcre_xclass.c rename to src/windows/glib-2.20.1/build/glib/pcre/pcre_xclass.c diff --git a/desmume/src/windows/glib-2.20.1/build/glib/pcre/ucp.h b/src/windows/glib-2.20.1/build/glib/pcre/ucp.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/pcre/ucp.h rename to src/windows/glib-2.20.1/build/glib/pcre/ucp.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/pcre/ucpinternal.h b/src/windows/glib-2.20.1/build/glib/pcre/ucpinternal.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/pcre/ucpinternal.h rename to src/windows/glib-2.20.1/build/glib/pcre/ucpinternal.h diff --git a/desmume/src/windows/glib-2.20.1/build/glib/win_iconv.c b/src/windows/glib-2.20.1/build/glib/win_iconv.c similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glib/win_iconv.c rename to src/windows/glib-2.20.1/build/glib/win_iconv.c diff --git a/desmume/src/windows/glib-2.20.1/build/glibconfig.h b/src/windows/glib-2.20.1/build/glibconfig.h similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/glibconfig.h rename to src/windows/glib-2.20.1/build/glibconfig.h diff --git a/desmume/src/windows/glib-2.20.1/build/vs8/README b/src/windows/glib-2.20.1/build/vs8/README similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/vs8/README rename to src/windows/glib-2.20.1/build/vs8/README diff --git a/desmume/src/windows/glib-2.20.1/build/vs8/gio.vcproj b/src/windows/glib-2.20.1/build/vs8/gio.vcproj similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/vs8/gio.vcproj rename to src/windows/glib-2.20.1/build/vs8/gio.vcproj diff --git a/desmume/src/windows/glib-2.20.1/build/vs8/glib.sln b/src/windows/glib-2.20.1/build/vs8/glib.sln similarity index 100% rename from desmume/src/windows/glib-2.20.1/build/vs8/glib.sln rename to src/windows/glib-2.20.1/build/vs8/glib.sln diff --git a/desmume/src/windows/glib-2.20.1/build/vs8/glib.vcproj b/src/windows/glib-2.20.1/build/vs8/glib.vcproj similarity index 88% rename from desmume/src/windows/glib-2.20.1/build/vs8/glib.vcproj rename to src/windows/glib-2.20.1/build/vs8/glib.vcproj index 64129dd90..0a261c6a4 100644 --- a/desmume/src/windows/glib-2.20.1/build/vs8/glib.vcproj +++ b/src/windows/glib-2.20.1/build/vs8/glib.vcproj @@ -45,7 +45,7 @@ FavorSizeOrSpeed="0" OmitFramePointers="false" AdditionalIncludeDirectories="..;../glib" - PreprocessorDefinitions="WIN32;_DEBUG;_WINDOWS;_USRDLL;GLIB_STATIC_COMPILATION;GLIB_COMPILATION;DLL_EXPORT;HAVE_CONFIG_H;G_LOG_DOMAIN=\"Glib\";G_ENABLE_DEBUG;G_DISABLE_DEPRECATED;PCRE_STATIC;LINK_SIZE=2;MAX_NAME_SIZE=32;MAX_NAME_COUNT=10000;NEWLINE=-1;POSIX_MALLOC_THRESHOLD=10;MATCH_LIMIT=10000000;MATCH_LIMIT_RECURSION=10000000" + PreprocessorDefinitions="WIN32;_DEBUG;_WINDOWS;_USRDLL;GLIB_COMPILATION;DLL_EXPORT;HAVE_CONFIG_H;G_LOG_DOMAIN=\"Glib\";G_ENABLE_DEBUG;G_DISABLE_DEPRECATED;PCRE_STATIC;LINK_SIZE=2;MAX_NAME_SIZE=32;MAX_NAME_COUNT=10000;NEWLINE=-1;POSIX_MALLOC_THRESHOLD=10;MATCH_LIMIT=10000000;MATCH_LIMIT_RECURSION=10000000" StringPooling="true" MinimalRebuild="false" ExceptionHandling="0" @@ -121,7 +121,7 @@ OmitFramePointers="true" WholeProgramOptimization="false" AdditionalIncludeDirectories="..;../glib" - PreprocessorDefinitions="WIN32;NDEBUG;_WINDOWS;_USRDLL;GLIB_STATIC_COMPILATION;GLIB_COMPILATION;DLL_EXPORT;HAVE_CONFIG_H;G_LOG_DOMAIN=\"Glib\";G_DISABLE_DEPRECATED;PCRE_STATIC;LINK_SIZE=2;MAX_NAME_SIZE=32;MAX_NAME_COUNT=10000;NEWLINE=-1;POSIX_MALLOC_THRESHOLD=10;MATCH_LIMIT=10000000;MATCH_LIMIT_RECURSION=10000000" + PreprocessorDefinitions="WIN32;NDEBUG;_WINDOWS;_USRDLL;GLIB_COMPILATION;DLL_EXPORT;HAVE_CONFIG_H;G_LOG_DOMAIN=\"Glib\";G_DISABLE_DEPRECATED;PCRE_STATIC;LINK_SIZE=2;MAX_NAME_SIZE=32;MAX_NAME_COUNT=10000;NEWLINE=-1;POSIX_MALLOC_THRESHOLD=10;MATCH_LIMIT=10000000;MATCH_LIMIT_RECURSION=10000000" StringPooling="true" ExceptionHandling="0" RuntimeLibrary="0" @@ -300,14 +300,6 @@ > - - - - diff --git a/src/windows/glib-2.20.1/lib/glib-2.20.1-x86.lib b/src/windows/glib-2.20.1/lib/glib-2.20.1-x86.lib new file mode 100644 index 0000000000000000000000000000000000000000..495ae9be11bdc0c08ff33f9570989ef4d9a20210 GIT binary patch literal 1818038 zcmeFaON?#ZcHdPJ4%gR!6WiC1#2r9Zgdl=buX9eBkXmc6_ulK}^YFcnPkVcd=0148;;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Fd^LFJwgt}b7(k{!dIURccP{)U>12IT^pYR5v6Q4pLCeQ VSCY^)UrD}p7KDGDj8$Uv_getHWnd(); ofn.lpstrFilter = "png file (*.png)\0*.png\0Bmp file (*.bmp)\0*.bmp\0Any file (*.*)\0*.*\0\0"; ofn.lpstrTitle = "Print Screen Save As"; ofn.nMaxFile = MAX_PATH; - ofn.lpstrFile = outFilename; ofn.Flags = OFN_OVERWRITEPROMPT; - std::string filename = path.getpath(path.SCREENSHOTS); + ZeroMemory(filename, sizeof(filename)); +// GetPathFor(SCREENSHOTS, filename, MAX_PATH); char file[MAX_PATH]; ZeroMemory(file, sizeof(file)); - path.formatname(file); - filename += file; + FormatName(file, MAX_PATH); + strcat(filename, file); + int len = strlen(filename); + if(len > MAX_PATH - 4) + filename[MAX_PATH - 4] = '\0'; - if(path.imageformat() == path.PNG) + ImageFormat format = GetImageFormatType(); + if(format == PNG) { - filename += ".png"; + strcat(filename, ".png"); ofn.lpstrDefExt = "png"; ofn.nFilterIndex = 1; } - else if(path.imageformat() == path.BMP) + else if(format == BMP) { - filename += ".bmp"; + strcat(filename, ".bmp"); ofn.lpstrDefExt = "bmp"; ofn.nFilterIndex = 2; } - strcpy(outFilename,filename.c_str()); - if(!GetSaveFileName(&ofn)) - return; - filename = outFilename; + ofn.lpstrFile = filename; + GetSaveFileName(&ofn); - if(toupper(strright(filename,4)) == ".PNG") - NDS_WritePNG(filename.c_str()); - else if(toupper(strright(filename,4)) == ".BMP") - NDS_WriteBMP(filename.c_str()); + char *ptr = strrchr(filename,'.');//look for the last . in the filename + + if ( ptr != 0 ) { + if (( strcmp ( ptr, ".BMP" ) == 0 ) || + ( strcmp ( ptr, ".bmp" ) == 0 )) + { + NDS_WriteBMP(filename); + } + if (( strcmp ( ptr, ".PNG" ) == 0 ) || + ( strcmp ( ptr, ".png" ) == 0 )) + { + NDS_WritePNG(filename); + } + } } void HK_StateSaveSlot(int num) @@ -139,6 +148,7 @@ void HK_StateSaveSlot(int num) else savestate_slot(num); //Savestate + lastSaveState = num; //Set last savestate used LoadSaveStateInfo(); } } @@ -191,13 +201,13 @@ void HK_AutoHoldClearKeyDown(int) { void HK_Reset(int) {ResetGame();} -void HK_RecordAVI(int) { if (AVI_IsRecording()) AviEnd(); else AviRecordTo(); } -void HK_RecordWAV(int) { if (WAV_IsRecording()) WavEnd(); else WavRecordTo(); } +void HK_RecordAVI(int) { if (DRV_AviIsRecording()) AviEnd(); else AviRecordTo(); } +void HK_RecordWAV(int) { if (DRV_WavIsRecording()) WavEnd(); else WavRecordTo(); } -void HK_ToggleFrame(int) {CommonSettings.hud.FrameCounterDisplay ^= true;} -void HK_ToggleFPS(int) {CommonSettings.hud.FpsDisplay ^= true;} -void HK_ToggleInput(int) {CommonSettings.hud.ShowInputDisplay ^= true;} -void HK_ToggleLag(int) {CommonSettings.hud.ShowLagFrameCounter ^= true;} +void HK_ToggleFrame(int) {frameCounterDisplay ^= true;} +void HK_ToggleFPS(int) {FpsDisplay ^= true;} +void HK_ToggleInput(int) {ShowInputDisplay ^= true;} +void HK_ToggleLag(int) {ShowLagFrameCounter ^= true;} void HK_ResetLagCounter(int) { lagframecounter=0; LagFrameFlag=0; @@ -222,12 +232,6 @@ void HK_PlayMovie(int) } } -bool rewinding = false; - -void HK_RewindKeyDown(int) {rewinding = true;} - -void HK_RewindKeyUp(int){rewinding = false;} - void HK_RecordMovie(int) { if (romloaded) @@ -574,13 +578,6 @@ void InitCustomKeys (SCustomKeys *keys) keys->TurboStart.page = HOTKEY_PAGE_TURBO; keys->TurboStart.key = NULL; - keys->Rewind.handleKeyDown = HK_RewindKeyDown; - keys->Rewind.handleKeyUp = HK_RewindKeyUp; - keys->Rewind.code = "Rewind"; - keys->Rewind.name = L"Rewind"; - keys->Rewind.page = HOTKEY_PAGE_MOVIE; - keys->Rewind.key = NULL; - keys->NextSaveSlot.handleKeyDown = HK_NextSaveSlot; keys->NextSaveSlot.code = "NextSaveSlot"; keys->NextSaveSlot.name = L"Next Save Slot"; diff --git a/desmume/src/windows/hotkey.h b/src/windows/hotkey.h similarity index 99% rename from desmume/src/windows/hotkey.h rename to src/windows/hotkey.h index 490c91bc6..1b4a836fc 100644 --- a/desmume/src/windows/hotkey.h +++ b/src/windows/hotkey.h @@ -80,8 +80,6 @@ struct SCustomKeys SCustomKey RecordWAV, RecordAVI; - SCustomKey Rewind; - SCustomKey ToggleFrameCounter; SCustomKey ToggleFPS; SCustomKey ToggleInput; diff --git a/desmume/src/windows/inputdx.cpp b/src/windows/inputdx.cpp similarity index 94% rename from desmume/src/windows/inputdx.cpp rename to src/windows/inputdx.cpp index 4795ecd42..70ea99a8d 100644 --- a/desmume/src/windows/inputdx.cpp +++ b/src/windows/inputdx.cpp @@ -198,11 +198,9 @@ static TCHAR szClassName[] = _T("InputCustom"); static TCHAR szHotkeysClassName[] = _T("InputCustomHot"); -static TCHAR szGuitarClassName[] = _T("InputCustomGuitar"); static LRESULT CALLBACK InputCustomWndProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam); static LRESULT CALLBACK HotInputCustomWndProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam); -static LRESULT CALLBACK GuitarInputCustomWndProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam); SJoyState Joystick [16]; SJoyState JoystickF [16]; @@ -241,11 +239,6 @@ SJoypad DefaultJoypad[16] = { SJoypad Joypad[16]; -SGuitar DefaultGuitar = { false, 'E', 'R', 'T', 'Y' }; - -SGuitar Guitar; -u8 guitarState = 0; - extern volatile BOOL paused; #define MAXKEYPAD 15 @@ -352,15 +345,6 @@ static void ReadHotkey(const char* name, WORD& output) } } -static void ReadGuitarControl(const char* name, WORD& output) -{ - UINT temp; - temp = GetPrivateProfileInt("GBAslot.GuitarGrip",name,-1,IniName); - if(temp != -1) { - output = temp; - } -} - static void LoadHotkeyConfig() { SCustomKey *key = &CustomKeys.key(0); @@ -385,19 +369,6 @@ static void SaveHotkeyConfig() } } -static void LoadGuitarConfig() -{ - memcpy(&Guitar,&DefaultGuitar,sizeof(Guitar)); - - //Guitar.Enabled = true; -#define DO(X) ReadControl(#X,Guitar.X); - DO(GREEN); - DO(RED); - DO(YELLOW); - DO(BLUE); -#undef DO -} - static void LoadInputConfig() { memcpy(&Joypad,&DefaultJoypad,sizeof(Joypad)); @@ -1169,21 +1140,6 @@ static void InitCustomControls() RegisterClassEx(&wc); - wc.cbSize = sizeof(wc); - wc.lpszClassName = szGuitarClassName; - wc.hInstance = GetModuleHandle(0); - wc.lpfnWndProc = GuitarInputCustomWndProc; - wc.hCursor = LoadCursor (NULL, IDC_ARROW); - wc.hIcon = 0; - wc.lpszMenuName = 0; - wc.hbrBackground = (HBRUSH)GetSysColorBrush(COLOR_BTNFACE); - wc.style = 0; - wc.cbClsExtra = 0; - wc.cbWndExtra = sizeof(InputCust *); - wc.hIconSm = 0; - - - RegisterClassEx(&wc); } InputCust * GetInputCustom(HWND hwnd) @@ -1385,148 +1341,6 @@ static LRESULT CALLBACK InputCustomWndProc(HWND hwnd, UINT msg, WPARAM wParam, L return DefWindowProc(hwnd, msg, wParam, lParam); } -static LRESULT CALLBACK GuitarInputCustomWndProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam) -{ - // retrieve the custom structure POINTER for THIS window - InputCust *icp = GetInputCustom(hwnd); - HWND pappy = (HWND__ *)GetWindowLongPtr(hwnd,GWL_HWNDPARENT); - funky= hwnd; - - static HWND selectedItem = NULL; - - char temp[100]; - COLORREF col; - switch(msg) - { - - case WM_GETDLGCODE: - return DLGC_WANTARROWS|DLGC_WANTALLKEYS|DLGC_WANTCHARS; - break; - - - case WM_NCCREATE: - - // Allocate a new CustCtrl structure for this window. - icp = (InputCust *) malloc( sizeof(InputCust) ); - - // Failed to allocate, stop window creation. - if(icp == NULL) return FALSE; - - // Initialize the CustCtrl structure. - icp->hwnd = hwnd; - icp->crForeGnd = GetSysColor(COLOR_WINDOWTEXT); - icp->crBackGnd = GetSysColor(COLOR_WINDOW); - icp->hFont = (HFONT__ *) GetStockObject(DEFAULT_GUI_FONT); - - // Assign the window text specified in the call to CreateWindow. - SetWindowText(hwnd, ((CREATESTRUCT *)lParam)->lpszName); - - // Attach custom structure to this window. - SetInputCustom(hwnd, icp); - - InvalidateRect(icp->hwnd, NULL, FALSE); - UpdateWindow(icp->hwnd); - - selectedItem = NULL; - - SetTimer(hwnd,777,125,NULL); - - // Continue with window creation. - return TRUE; - - // Clean up when the window is destroyed. - case WM_NCDESTROY: - free(icp); - break; - case WM_PAINT: - return InputCustom_OnPaint(icp,wParam,lParam); - break; - case WM_ERASEBKGND: - return 1; - case WM_USER+45: - case WM_KEYDOWN: - TranslateKey(wParam,temp); - col = CheckButtonKey(wParam); - - icp->crForeGnd = ((~col) & 0x00ffffff); - icp->crBackGnd = col; - SetWindowText(hwnd,temp); - InvalidateRect(icp->hwnd, NULL, FALSE); - UpdateWindow(icp->hwnd); - SendMessage(pappy,WM_USER+43,wParam,(LPARAM)hwnd); - - break; - case WM_USER+44: - - TranslateKey(wParam,temp); - if(IsWindowEnabled(hwnd)) - { - col = CheckButtonKey(wParam); - } - else - { - col = RGB( 192,192,192); - } - icp->crForeGnd = ((~col) & 0x00ffffff); - icp->crBackGnd = col; - SetWindowText(hwnd,temp); - InvalidateRect(icp->hwnd, NULL, FALSE); - UpdateWindow(icp->hwnd); - - break; - - case WM_SETFOCUS: - { - selectedItem = hwnd; - col = RGB( 0,255,0); - icp->crForeGnd = ((~col) & 0x00ffffff); - icp->crBackGnd = col; - InvalidateRect(icp->hwnd, NULL, FALSE); - UpdateWindow(icp->hwnd); -// tid = wParam; - - break; - } - case WM_KILLFOCUS: - { - selectedItem = NULL; - SendMessage(pappy,WM_USER+46,wParam,(LPARAM)hwnd); // refresh fields on deselect - break; - } - - case WM_TIMER: - if(hwnd == selectedItem) - { - FunkyJoyStickTimer(); - } - SetTimer(hwnd,777,125,NULL); - break; - case WM_LBUTTONDOWN: - SetFocus(hwnd); - break; - case WM_ENABLE: - COLORREF col; - if(wParam) - { - col = RGB( 255,255,255); - icp->crForeGnd = ((~col) & 0x00ffffff); - icp->crBackGnd = col; - } - else - { - col = RGB( 192,192,192); - icp->crForeGnd = ((~col) & 0x00ffffff); - icp->crBackGnd = col; - } - InvalidateRect(icp->hwnd, NULL, FALSE); - UpdateWindow(icp->hwnd); - return true; - default: - break; - } - return DefWindowProc(hwnd, msg, wParam, lParam); -} - static void TranslateKeyWithModifiers(int wParam, int modifiers, char * outStr) { @@ -2205,6 +2019,10 @@ void S9xWinScanJoypads () // auto-hold AND regular key/joystick presses if(S9xGetState(Joypad[J+8].Left)) { + if(!S9xGetState(Joypad[J].Start)) + { + int zzz=9; + } PadState ^= (!S9xGetState(Joypad[J].R)||!S9xGetState(Joypad[J+8].R)) ? R_MASK : 0; PadState ^= (!S9xGetState(Joypad[J].L)||!S9xGetState(Joypad[J+8].L)) ? L_MASK : 0; PadState ^= (!S9xGetState(Joypad[J].X)||!S9xGetState(Joypad[J+8].X)) ? X_MASK : 0; @@ -2353,7 +2171,6 @@ void input_init() LoadInputConfig(); LoadHotkeyConfig(); - LoadGuitarConfig(); di_init(); FeedbackON = input_feedback; @@ -2396,14 +2213,6 @@ void input_process() NDS_setPad( R, L, D, U, T, S, B, A, Y, X, W, E, G, F); - if (Guitar.Enabled) - { - bool gG=!S9xGetState(Guitar.GREEN); - bool gR=!S9xGetState(Guitar.RED); - bool gY=!S9xGetState(Guitar.YELLOW); - bool gB=!S9xGetState(Guitar.BLUE); - guitarGrip_setKey(gG, gR, gY, gB); - } } static void set_hotkeyinfo(HWND hDlg) diff --git a/desmume/src/windows/inputdx.h b/src/windows/inputdx.h similarity index 96% rename from desmume/src/windows/inputdx.h rename to src/windows/inputdx.h index 2aa559e98..64adafc8c 100644 --- a/desmume/src/windows/inputdx.h +++ b/src/windows/inputdx.h @@ -1,286 +1,276 @@ -///* This file is part of DeSmuME, derived from several files in Snes9x 1.51 which are -// licensed under the terms supplied at the end of this file (for the terms are very long!) -// Differences from that baseline version are: -// -// Copyright (C) 2009 DeSmuME team -// -// DeSmuME is free software; you can redistribute it and/or modify -// it under the terms of the GNU General Public License as published by -// the Free Software Foundation; either version 2 of the License, or -// (at your option) any later version. -// -// DeSmuME is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with DeSmuME; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -//*/ - - -#ifndef INPUTDX_INCLUDED -#define INPUTDX_INCLUDED - -typedef struct -{ - COLORREF crForeGnd; // Foreground text colour - COLORREF crBackGnd; // Background text colour - HFONT hFont; // The font - HWND hwnd; // The control's window handle -} InputCust; -COLORREF CheckButtonKey( WORD Key); -COLORREF CheckHotKey( WORD Key, int modifiers); -InputCust * GetInputCustom(HWND hwnd); - -#define CUSTKEY_ALT_MASK 0x01 -#define CUSTKEY_CTRL_MASK 0x02 -#define CUSTKEY_SHIFT_MASK 0x04 - -struct SJoypad { - BOOL Enabled; - WORD Left; - WORD Right; - WORD Up; - WORD Down; - WORD Left_Up; - WORD Left_Down; - WORD Right_Up; - WORD Right_Down; - WORD Start; - WORD Select; - WORD Lid; - WORD Debug; - WORD A; - WORD B; - WORD X; - WORD Y; - WORD L; - WORD R; -}; - -#define LEFT_MASK 0x0001 -#define RIGHT_MASK 0x0002 -#define UP_MASK 0x0004 -#define DOWN_MASK 0x0008 -#define START_MASK 0x0010 -#define SELECT_MASK 0x0020 -#define LID_MASK 0x0040 -#define DEBUG_MASK 0x0080 -#define A_MASK 0x0100 -#define B_MASK 0x0200 -#define X_MASK 0x0400 -#define Y_MASK 0x0800 -#define L_MASK 0x1000 -#define R_MASK 0x2000 - - -struct SJoyState{ - bool Attached; - //JOYCAPS Caps; - int Threshold; - bool Left; - bool Right; - bool Up; - bool Down; - bool PovLeft; - bool PovRight; - bool PovUp; - bool PovDown; - bool PovDnLeft; - bool PovDnRight; - bool PovUpLeft; - bool PovUpRight; - bool RUp; - bool RDown; - bool UUp; - bool UDown; - bool VUp; - bool VDown; - bool ZUp; - bool ZDown; - bool Button[32]; -}; - -extern SJoypad Joypad[16]; -extern SJoypad ToggleJoypadStorage[8]; -//extern SCustomKeys CustomKeys; -extern SJoypad TurboToggleJoypadStorage[8]; - -void RunInputConfig(); -void RunHotkeyConfig(); -void input_process(); - -struct SGuitar { - BOOL Enabled; - WORD GREEN; - WORD RED; - WORD YELLOW; - WORD BLUE; -}; - -extern SGuitar Guitar; - -#endif - - -/********************************************************************************** - Snes9x - Portable Super Nintendo Entertainment System (TM) emulator. - - (c) Copyright 1996 - 2002 Gary Henderson (gary.henderson@ntlworld.com), - Jerremy Koot (jkoot@snes9x.com) - - (c) Copyright 2002 - 2004 Matthew Kendora - - (c) Copyright 2002 - 2005 Peter Bortas (peter@bortas.org) - - (c) Copyright 2004 - 2005 Joel Yliluoma (http://iki.fi/bisqwit/) - - (c) Copyright 2001 - 2006 John Weidman (jweidman@slip.net) - - (c) Copyright 2002 - 2006 funkyass (funkyass@spam.shaw.ca), - Kris Bleakley (codeviolation@hotmail.com) - - (c) Copyright 2002 - 2007 Brad Jorsch (anomie@users.sourceforge.net), - Nach (n-a-c-h@users.sourceforge.net), - zones (kasumitokoduck@yahoo.com) - - (c) Copyright 2006 - 2007 nitsuja - - - BS-X C emulator code - (c) Copyright 2005 - 2006 Dreamer Nom, - zones - - C4 x86 assembler and some C emulation code - (c) Copyright 2000 - 2003 _Demo_ (_demo_@zsnes.com), - Nach, - zsKnight (zsknight@zsnes.com) - - C4 C++ code - (c) Copyright 2003 - 2006 Brad Jorsch, - Nach - - DSP-1 emulator code - (c) Copyright 1998 - 2006 _Demo_, - Andreas Naive (andreasnaive@gmail.com) - Gary Henderson, - Ivar (ivar@snes9x.com), - John Weidman, - Kris Bleakley, - Matthew Kendora, - Nach, - neviksti (neviksti@hotmail.com) - - DSP-2 emulator code - (c) Copyright 2003 John Weidman, - Kris Bleakley, - Lord Nightmare (lord_nightmare@users.sourceforge.net), - Matthew Kendora, - neviksti - - - DSP-3 emulator code - (c) Copyright 2003 - 2006 John Weidman, - Kris Bleakley, - Lancer, - z80 gaiden - - DSP-4 emulator code - (c) Copyright 2004 - 2006 Dreamer Nom, - John Weidman, - Kris Bleakley, - Nach, - z80 gaiden - - OBC1 emulator code - (c) Copyright 2001 - 2004 zsKnight, - pagefault (pagefault@zsnes.com), - Kris Bleakley, - Ported from x86 assembler to C by sanmaiwashi - - SPC7110 and RTC C++ emulator code - (c) Copyright 2002 Matthew Kendora with research by - zsKnight, - John Weidman, - Dark Force - - S-DD1 C emulator code - (c) Copyright 2003 Brad Jorsch with research by - Andreas Naive, - John Weidman - - S-RTC C emulator code - (c) Copyright 2001-2006 byuu, - John Weidman - - ST010 C++ emulator code - (c) Copyright 2003 Feather, - John Weidman, - Kris Bleakley, - Matthew Kendora - - Super FX x86 assembler emulator code - (c) Copyright 1998 - 2003 _Demo_, - pagefault, - zsKnight, - - Super FX C emulator code - (c) Copyright 1997 - 1999 Ivar, - Gary Henderson, - John Weidman - - Sound DSP emulator code is derived from SNEeSe and OpenSPC: - (c) Copyright 1998 - 2003 Brad Martin - (c) Copyright 1998 - 2006 Charles Bilyue' - - SH assembler code partly based on x86 assembler code - (c) Copyright 2002 - 2004 Marcus Comstedt (marcus@mc.pp.se) - - 2xSaI filter - (c) Copyright 1999 - 2001 Derek Liauw Kie Fa - - HQ2x, HQ3x, HQ4x filters - (c) Copyright 2003 Maxim Stepin (maxim@hiend3d.com) - - Win32 GUI code - (c) Copyright 2003 - 2006 blip, - funkyass, - Matthew Kendora, - Nach, - nitsuja - - Mac OS GUI code - (c) Copyright 1998 - 2001 John Stiles - (c) Copyright 2001 - 2007 zones - - - Specific ports contains the works of other authors. See headers in - individual files. - - - Snes9x homepage: http://www.snes9x.com - - Permission to use, copy, modify and/or distribute Snes9x in both binary - and source form, for non-commercial purposes, is hereby granted without - fee, providing that this license information and copyright notice appear - with all copies and any derived work. - - This software is provided 'as-is', without any express or implied - warranty. In no event shall the authors be held liable for any damages - arising from the use of this software or it's derivatives. - - Snes9x is freeware for PERSONAL USE only. Commercial users should - seek permission of the copyright holders first. Commercial use includes, - but is not limited to, charging money for Snes9x or software derived from - Snes9x, including Snes9x or derivatives in commercial game bundles, and/or - using Snes9x as a promotion for your commercial product. - - The copyright holders request that bug fixes and improvements to the code - should be forwarded to them so everyone can benefit from the modifications - in future versions. - - Super NES and Super Nintendo Entertainment System are trademarks of - Nintendo Co., Limited and its subsidiary companies. -**********************************************************************************/ +///* This file is part of DeSmuME, derived from several files in Snes9x 1.51 which are +// licensed under the terms supplied at the end of this file (for the terms are very long!) +// Differences from that baseline version are: +// +// Copyright (C) 2009 DeSmuME team +// +// DeSmuME is free software; you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation; either version 2 of the License, or +// (at your option) any later version. +// +// DeSmuME is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with DeSmuME; if not, write to the Free Software +// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +//*/ + + +#ifndef INPUTDX_INCLUDED +#define INPUTDX_INCLUDED + +typedef struct +{ + COLORREF crForeGnd; // Foreground text colour + COLORREF crBackGnd; // Background text colour + HFONT hFont; // The font + HWND hwnd; // The control's window handle +} InputCust; +COLORREF CheckButtonKey( WORD Key); +COLORREF CheckHotKey( WORD Key, int modifiers); +InputCust * GetInputCustom(HWND hwnd); + +#define CUSTKEY_ALT_MASK 0x01 +#define CUSTKEY_CTRL_MASK 0x02 +#define CUSTKEY_SHIFT_MASK 0x04 + +struct SJoypad { + BOOL Enabled; + WORD Left; + WORD Right; + WORD Up; + WORD Down; + WORD Left_Up; + WORD Left_Down; + WORD Right_Up; + WORD Right_Down; + WORD Start; + WORD Select; + WORD Lid; + WORD Debug; + WORD A; + WORD B; + WORD X; + WORD Y; + WORD L; + WORD R; +}; + +#define LEFT_MASK 0x0001 +#define RIGHT_MASK 0x0002 +#define UP_MASK 0x0004 +#define DOWN_MASK 0x0008 +#define START_MASK 0x0010 +#define SELECT_MASK 0x0020 +#define LID_MASK 0x0040 +#define DEBUG_MASK 0x0080 +#define A_MASK 0x0100 +#define B_MASK 0x0200 +#define X_MASK 0x0400 +#define Y_MASK 0x0800 +#define L_MASK 0x1000 +#define R_MASK 0x2000 + + +struct SJoyState{ + bool Attached; + //JOYCAPS Caps; + int Threshold; + bool Left; + bool Right; + bool Up; + bool Down; + bool PovLeft; + bool PovRight; + bool PovUp; + bool PovDown; + bool PovDnLeft; + bool PovDnRight; + bool PovUpLeft; + bool PovUpRight; + bool RUp; + bool RDown; + bool UUp; + bool UDown; + bool VUp; + bool VDown; + bool ZUp; + bool ZDown; + bool Button[32]; +}; + +extern SJoypad Joypad[16]; +extern SJoypad ToggleJoypadStorage[8]; +//extern SCustomKeys CustomKeys; +extern SJoypad TurboToggleJoypadStorage[8]; + +void RunInputConfig(); +void RunHotkeyConfig(); +void input_process(); + +#endif + + +/********************************************************************************** + Snes9x - Portable Super Nintendo Entertainment System (TM) emulator. + + (c) Copyright 1996 - 2002 Gary Henderson (gary.henderson@ntlworld.com), + Jerremy Koot (jkoot@snes9x.com) + + (c) Copyright 2002 - 2004 Matthew Kendora + + (c) Copyright 2002 - 2005 Peter Bortas (peter@bortas.org) + + (c) Copyright 2004 - 2005 Joel Yliluoma (http://iki.fi/bisqwit/) + + (c) Copyright 2001 - 2006 John Weidman (jweidman@slip.net) + + (c) Copyright 2002 - 2006 funkyass (funkyass@spam.shaw.ca), + Kris Bleakley (codeviolation@hotmail.com) + + (c) Copyright 2002 - 2007 Brad Jorsch (anomie@users.sourceforge.net), + Nach (n-a-c-h@users.sourceforge.net), + zones (kasumitokoduck@yahoo.com) + + (c) Copyright 2006 - 2007 nitsuja + + + BS-X C emulator code + (c) Copyright 2005 - 2006 Dreamer Nom, + zones + + C4 x86 assembler and some C emulation code + (c) Copyright 2000 - 2003 _Demo_ (_demo_@zsnes.com), + Nach, + zsKnight (zsknight@zsnes.com) + + C4 C++ code + (c) Copyright 2003 - 2006 Brad Jorsch, + Nach + + DSP-1 emulator code + (c) Copyright 1998 - 2006 _Demo_, + Andreas Naive (andreasnaive@gmail.com) + Gary Henderson, + Ivar (ivar@snes9x.com), + John Weidman, + Kris Bleakley, + Matthew Kendora, + Nach, + neviksti (neviksti@hotmail.com) + + DSP-2 emulator code + (c) Copyright 2003 John Weidman, + Kris Bleakley, + Lord Nightmare (lord_nightmare@users.sourceforge.net), + Matthew Kendora, + neviksti + + + DSP-3 emulator code + (c) Copyright 2003 - 2006 John Weidman, + Kris Bleakley, + Lancer, + z80 gaiden + + DSP-4 emulator code + (c) Copyright 2004 - 2006 Dreamer Nom, + John Weidman, + Kris Bleakley, + Nach, + z80 gaiden + + OBC1 emulator code + (c) Copyright 2001 - 2004 zsKnight, + pagefault (pagefault@zsnes.com), + Kris Bleakley, + Ported from x86 assembler to C by sanmaiwashi + + SPC7110 and RTC C++ emulator code + (c) Copyright 2002 Matthew Kendora with research by + zsKnight, + John Weidman, + Dark Force + + S-DD1 C emulator code + (c) Copyright 2003 Brad Jorsch with research by + Andreas Naive, + John Weidman + + S-RTC C emulator code + (c) Copyright 2001-2006 byuu, + John Weidman + + ST010 C++ emulator code + (c) Copyright 2003 Feather, + John Weidman, + Kris Bleakley, + Matthew Kendora + + Super FX x86 assembler emulator code + (c) Copyright 1998 - 2003 _Demo_, + pagefault, + zsKnight, + + Super FX C emulator code + (c) Copyright 1997 - 1999 Ivar, + Gary Henderson, + John Weidman + + Sound DSP emulator code is derived from SNEeSe and OpenSPC: + (c) Copyright 1998 - 2003 Brad Martin + (c) Copyright 1998 - 2006 Charles Bilyue' + + SH assembler code partly based on x86 assembler code + (c) Copyright 2002 - 2004 Marcus Comstedt (marcus@mc.pp.se) + + 2xSaI filter + (c) Copyright 1999 - 2001 Derek Liauw Kie Fa + + HQ2x, HQ3x, HQ4x filters + (c) Copyright 2003 Maxim Stepin (maxim@hiend3d.com) + + Win32 GUI code + (c) Copyright 2003 - 2006 blip, + funkyass, + Matthew Kendora, + Nach, + nitsuja + + Mac OS GUI code + (c) Copyright 1998 - 2001 John Stiles + (c) Copyright 2001 - 2007 zones + + + Specific ports contains the works of other authors. See headers in + individual files. + + + Snes9x homepage: http://www.snes9x.com + + Permission to use, copy, modify and/or distribute Snes9x in both binary + and source form, for non-commercial purposes, is hereby granted without + fee, providing that this license information and copyright notice appear + with all copies and any derived work. + + This software is provided 'as-is', without any express or implied + warranty. In no event shall the authors be held liable for any damages + arising from the use of this software or it's derivatives. + + Snes9x is freeware for PERSONAL USE only. Commercial users should + seek permission of the copyright holders first. Commercial use includes, + but is not limited to, charging money for Snes9x or software derived from + Snes9x, including Snes9x or derivatives in commercial game bundles, and/or + using Snes9x as a promotion for your commercial product. + + The copyright holders request that bug fixes and improvements to the code + should be forwarded to them so everyone can benefit from the modifications + in future versions. + + Super NES and Super Nintendo Entertainment System are trademarks of + Nintendo Co., Limited and its subsidiary companies. +**********************************************************************************/ diff --git a/desmume/src/windows/langs/build_utils/gettextlib.dll b/src/windows/langs/build_utils/gettextlib.dll similarity index 100% rename from desmume/src/windows/langs/build_utils/gettextlib.dll rename to src/windows/langs/build_utils/gettextlib.dll diff --git a/desmume/src/windows/langs/build_utils/gettextpo.dll b/src/windows/langs/build_utils/gettextpo.dll similarity index 100% rename from desmume/src/windows/langs/build_utils/gettextpo.dll rename to src/windows/langs/build_utils/gettextpo.dll diff --git a/desmume/src/windows/langs/build_utils/gettextsrc.dll b/src/windows/langs/build_utils/gettextsrc.dll similarity index 100% rename from desmume/src/windows/langs/build_utils/gettextsrc.dll rename to src/windows/langs/build_utils/gettextsrc.dll diff --git a/desmume/src/windows/langs/build_utils/iconv.dll b/src/windows/langs/build_utils/iconv.dll similarity index 100% rename from desmume/src/windows/langs/build_utils/iconv.dll rename to src/windows/langs/build_utils/iconv.dll diff --git a/desmume/src/windows/langs/build_utils/intl.dll b/src/windows/langs/build_utils/intl.dll similarity index 100% rename from desmume/src/windows/langs/build_utils/intl.dll rename to src/windows/langs/build_utils/intl.dll diff --git a/desmume/src/windows/langs/build_utils/libiconv-2.dll b/src/windows/langs/build_utils/libiconv-2.dll similarity index 100% rename from desmume/src/windows/langs/build_utils/libiconv-2.dll rename to src/windows/langs/build_utils/libiconv-2.dll diff --git a/desmume/src/windows/langs/build_utils/msgfmt.exe b/src/windows/langs/build_utils/msgfmt.exe similarity index 100% rename from desmume/src/windows/langs/build_utils/msgfmt.exe rename to src/windows/langs/build_utils/msgfmt.exe diff --git a/desmume/src/windows/langs/fr_FR.mo b/src/windows/langs/fr_FR.mo similarity index 100% rename from desmume/src/windows/langs/fr_FR.mo rename to src/windows/langs/fr_FR.mo diff --git a/desmume/src/windows/lightView.cpp b/src/windows/lightView.cpp similarity index 96% rename from desmume/src/windows/lightView.cpp rename to src/windows/lightView.cpp index 6894ef32b..0b6b04a9f 100644 --- a/desmume/src/windows/lightView.cpp +++ b/src/windows/lightView.cpp @@ -1,184 +1,184 @@ -/* Copyright (C) 2007 Acid Burn - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#include "lightView.h" -#include "commctrl.h" -#include "colorctrl.h" -#include "gfx3d.h" -#include "resource.h" -#include "debug.h" - -// Convert B5G5R5 color format into R8G8B8 color format -unsigned int ColorConv_B5R5R5ToR8G8B8(const unsigned int color) -{ - return (((color&31)<<16)<<3) | // red - ((((color>>5)&31)<<8)<<3) | // green - (((color>>10)&31)<<3); // blue -} - -typedef struct -{ - u32 autoup_secs; - bool autoup; -} lightsview_struct; - -lightsview_struct *LightsView = NULL; - -void LightView_OnPaintLight(HWND hwnd, int index) -{ - const int idcDir[4] = - { - IDC_LIGHT_VIEWER_LIGHT0VECTOR_EDIT, IDC_LIGHT_VIEWER_LIGHT1VECTOR_EDIT, - IDC_LIGHT_VIEWER_LIGHT2VECTOR_EDIT, IDC_LIGHT_VIEWER_LIGHT3VECTOR_EDIT - }; - - const int idcColorEdit[4] = - { - IDC_LIGHT_VIEWER_LIGHT0COLOR_EDIT, IDC_LIGHT_VIEWER_LIGHT1COLOR_EDIT, - IDC_LIGHT_VIEWER_LIGHT2COLOR_EDIT, IDC_LIGHT_VIEWER_LIGHT3COLOR_EDIT - }; - - const int idcColorCtrl[4] = - { - IDC_LIGHT_VIEWER_LIGHT0COLOR_COLORCTRL, IDC_LIGHT_VIEWER_LIGHT1COLOR_COLORCTRL, - IDC_LIGHT_VIEWER_LIGHT2COLOR_COLORCTRL, IDC_LIGHT_VIEWER_LIGHT3COLOR_COLORCTRL - }; - - unsigned int color; - unsigned int direction; - ColorCtrl* colorCtrl; - char buffer[128]; - - // Get necessary information from gfx3d module - gfx3d_glGetLightColor(index, &color); - gfx3d_glGetLightDirection(index, &direction); - - // Print Light Direction - sprintf(buffer, "%.8x", direction); - SetWindowText(GetDlgItem(hwnd, idcDir[index]), buffer); - - // Print Light Color - sprintf(buffer, "%.4x", color); - SetWindowText(GetDlgItem(hwnd, idcColorEdit[index]), buffer); - - // Set Light Color in ColorDisplay component - ColorCtrl_SetColor(GetDlgItem(hwnd, idcColorCtrl[index]), ColorConv_B5R5R5ToR8G8B8(color)); -} - -////////////////////////////////////////////////////////////////////////////// - -BOOL LightView_OnPaint(HWND hwnd, WPARAM wParam, LPARAM lParam) -{ - HDC hdc; - PAINTSTRUCT ps; - - hdc = BeginPaint(hwnd, &ps); - - LightView_OnPaintLight(hwnd, 0); - LightView_OnPaintLight(hwnd, 1); - LightView_OnPaintLight(hwnd, 2); - LightView_OnPaintLight(hwnd, 3); - - EndPaint(hwnd, &ps); - - return TRUE; -} - -BOOL CALLBACK ViewLightsProc (HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam) -{ - switch (message) - { - case WM_INITDIALOG: - LightsView = new lightsview_struct; - memset(LightsView, 0, sizeof(lightsview_struct)); - LightsView->autoup_secs = 1; - SendMessage(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SPIN), - UDM_SETRANGE, 0, MAKELONG(99, 1)); - SendMessage(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SPIN), - UDM_SETPOS32, 0, LightsView->autoup_secs); - break; - - case WM_CLOSE: - if(LightsView->autoup) - { - KillTimer(hwnd, IDT_VIEW_LIGHTS); - LightsView->autoup = false; - } - - if (LightsView!=NULL) - { - delete LightsView; - LightsView = NULL; - } - //INFO("Close lights viewer dialog\n"); - PostQuitMessage(0); - break; - - case WM_PAINT: - LightView_OnPaint(hwnd, wParam, lParam); - break; - - case WM_TIMER: - SendMessage(hwnd, WM_COMMAND, IDC_REFRESH, 0); - return 1; - - case WM_COMMAND: - switch (LOWORD (wParam)) - { - case IDOK: - SendMessage(hwnd, WM_CLOSE, 0, 0); - return 1; - case IDC_AUTO_UPDATE : - if(LightsView->autoup) - { - EnableWindow(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SECS), false); - EnableWindow(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SPIN), false); - KillTimer(hwnd, IDT_VIEW_LIGHTS); - LightsView->autoup = FALSE; - return 1; - } - EnableWindow(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SECS), true); - EnableWindow(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SPIN), true); - LightsView->autoup = TRUE; - SetTimer(hwnd, IDT_VIEW_LIGHTS, LightsView->autoup_secs*20, (TIMERPROC) NULL); - return 1; - case IDC_AUTO_UPDATE_SECS: - { - int t = GetDlgItemInt(hwnd, IDC_AUTO_UPDATE_SECS, FALSE, TRUE); - if (!LightsView) - { - SendMessage(hwnd, WM_INITDIALOG, 0, 0); - } - if (t != LightsView->autoup_secs) - { - LightsView->autoup_secs = t; - if (LightsView->autoup) - SetTimer(hwnd, IDT_VIEW_LIGHTS, - LightsView->autoup_secs*20, (TIMERPROC) NULL); - } - } - return 1; - case IDC_REFRESH: - InvalidateRect(hwnd, NULL, FALSE); - return 1; - } - return 0; - } - return FALSE; -} +/* Copyright (C) 2007 Acid Burn + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#include "lightView.h" +#include "commctrl.h" +#include "colorctrl.h" +#include "gfx3d.h" +#include "resource.h" +#include "debug.h" + +// Convert B5G5R5 color format into R8G8B8 color format +unsigned int ColorConv_B5R5R5ToR8G8B8(const unsigned int color) +{ + return (((color&31)<<16)<<3) | // red + ((((color>>5)&31)<<8)<<3) | // green + (((color>>10)&31)<<3); // blue +} + +typedef struct +{ + u32 autoup_secs; + bool autoup; +} lightsview_struct; + +lightsview_struct *LightsView = NULL; + +void LightView_OnPaintLight(HWND hwnd, int index) +{ + const int idcDir[4] = + { + IDC_LIGHT_VIEWER_LIGHT0VECTOR_EDIT, IDC_LIGHT_VIEWER_LIGHT1VECTOR_EDIT, + IDC_LIGHT_VIEWER_LIGHT2VECTOR_EDIT, IDC_LIGHT_VIEWER_LIGHT3VECTOR_EDIT + }; + + const int idcColorEdit[4] = + { + IDC_LIGHT_VIEWER_LIGHT0COLOR_EDIT, IDC_LIGHT_VIEWER_LIGHT1COLOR_EDIT, + IDC_LIGHT_VIEWER_LIGHT2COLOR_EDIT, IDC_LIGHT_VIEWER_LIGHT3COLOR_EDIT + }; + + const int idcColorCtrl[4] = + { + IDC_LIGHT_VIEWER_LIGHT0COLOR_COLORCTRL, IDC_LIGHT_VIEWER_LIGHT1COLOR_COLORCTRL, + IDC_LIGHT_VIEWER_LIGHT2COLOR_COLORCTRL, IDC_LIGHT_VIEWER_LIGHT3COLOR_COLORCTRL + }; + + unsigned int color; + unsigned int direction; + ColorCtrl* colorCtrl; + char buffer[128]; + + // Get necessary information from gfx3d module + gfx3d_glGetLightColor(index, &color); + gfx3d_glGetLightDirection(index, &direction); + + // Print Light Direction + sprintf(buffer, "%.8x", direction); + SetWindowText(GetDlgItem(hwnd, idcDir[index]), buffer); + + // Print Light Color + sprintf(buffer, "%.4x", color); + SetWindowText(GetDlgItem(hwnd, idcColorEdit[index]), buffer); + + // Set Light Color in ColorDisplay component + ColorCtrl_SetColor(GetDlgItem(hwnd, idcColorCtrl[index]), ColorConv_B5R5R5ToR8G8B8(color)); +} + +////////////////////////////////////////////////////////////////////////////// + +BOOL LightView_OnPaint(HWND hwnd, WPARAM wParam, LPARAM lParam) +{ + HDC hdc; + PAINTSTRUCT ps; + + hdc = BeginPaint(hwnd, &ps); + + LightView_OnPaintLight(hwnd, 0); + LightView_OnPaintLight(hwnd, 1); + LightView_OnPaintLight(hwnd, 2); + LightView_OnPaintLight(hwnd, 3); + + EndPaint(hwnd, &ps); + + return TRUE; +} + +BOOL CALLBACK ViewLightsProc (HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam) +{ + switch (message) + { + case WM_INITDIALOG: + LightsView = new lightsview_struct; + memset(LightsView, 0, sizeof(lightsview_struct)); + LightsView->autoup_secs = 1; + SendMessage(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SPIN), + UDM_SETRANGE, 0, MAKELONG(99, 1)); + SendMessage(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SPIN), + UDM_SETPOS32, 0, LightsView->autoup_secs); + break; + + case WM_CLOSE: + if(LightsView->autoup) + { + KillTimer(hwnd, IDT_VIEW_LIGHTS); + LightsView->autoup = false; + } + + if (LightsView!=NULL) + { + delete LightsView; + LightsView = NULL; + } + //INFO("Close lights viewer dialog\n"); + PostQuitMessage(0); + break; + + case WM_PAINT: + LightView_OnPaint(hwnd, wParam, lParam); + break; + + case WM_TIMER: + SendMessage(hwnd, WM_COMMAND, IDC_REFRESH, 0); + return 1; + + case WM_COMMAND: + switch (LOWORD (wParam)) + { + case IDOK: + SendMessage(hwnd, WM_CLOSE, 0, 0); + return 1; + case IDC_AUTO_UPDATE : + if(LightsView->autoup) + { + EnableWindow(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SECS), false); + EnableWindow(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SPIN), false); + KillTimer(hwnd, IDT_VIEW_LIGHTS); + LightsView->autoup = FALSE; + return 1; + } + EnableWindow(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SECS), true); + EnableWindow(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SPIN), true); + LightsView->autoup = TRUE; + SetTimer(hwnd, IDT_VIEW_LIGHTS, LightsView->autoup_secs*20, (TIMERPROC) NULL); + return 1; + case IDC_AUTO_UPDATE_SECS: + { + int t = GetDlgItemInt(hwnd, IDC_AUTO_UPDATE_SECS, FALSE, TRUE); + if (!LightsView) + { + SendMessage(hwnd, WM_INITDIALOG, 0, 0); + } + if (t != LightsView->autoup_secs) + { + LightsView->autoup_secs = t; + if (LightsView->autoup) + SetTimer(hwnd, IDT_VIEW_LIGHTS, + LightsView->autoup_secs*20, (TIMERPROC) NULL); + } + } + return 1; + case IDC_REFRESH: + InvalidateRect(hwnd, NULL, FALSE); + return 1; + } + return 0; + } + return FALSE; +} diff --git a/desmume/src/windows/lightView.h b/src/windows/lightView.h similarity index 96% rename from desmume/src/windows/lightView.h rename to src/windows/lightView.h index 9dd1cf69a..4778b05cd 100644 --- a/desmume/src/windows/lightView.h +++ b/src/windows/lightView.h @@ -1,27 +1,27 @@ -/* Copyright (C) 2007 Acid Burn - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#ifndef LIGHTVIEW_H -#define LIGHTVIEW_H - -#include "../common.h" - -extern BOOL CALLBACK ViewLightsProc (HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam); - +/* Copyright (C) 2007 Acid Burn + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#ifndef LIGHTVIEW_H +#define LIGHTVIEW_H + +#include "../common.h" + +extern BOOL CALLBACK ViewLightsProc (HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam); + #endif \ No newline at end of file diff --git a/desmume/src/windows/lua/lib/lua-5.1.4-x86.lib b/src/windows/lua/lib/lua-5.1.4-x86.lib similarity index 100% rename from desmume/src/windows/lua/lib/lua-5.1.4-x86.lib rename to src/windows/lua/lib/lua-5.1.4-x86.lib diff --git a/desmume/src/windows/lua/lua-5.1.4/COPYRIGHT b/src/windows/lua/lua-5.1.4/COPYRIGHT similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/COPYRIGHT rename to src/windows/lua/lua-5.1.4/COPYRIGHT diff --git a/desmume/src/windows/lua/lua-5.1.4/src/Makefile b/src/windows/lua/lua-5.1.4/src/Makefile similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/Makefile rename to src/windows/lua/lua-5.1.4/src/Makefile diff --git a/desmume/src/windows/lua/lua-5.1.4/src/lapi.c b/src/windows/lua/lua-5.1.4/src/lapi.c similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/lapi.c rename to src/windows/lua/lua-5.1.4/src/lapi.c diff --git a/desmume/src/windows/lua/lua-5.1.4/src/lapi.h b/src/windows/lua/lua-5.1.4/src/lapi.h similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/lapi.h rename to src/windows/lua/lua-5.1.4/src/lapi.h diff --git a/desmume/src/windows/lua/lua-5.1.4/src/lauxlib.c b/src/windows/lua/lua-5.1.4/src/lauxlib.c similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/lauxlib.c rename to src/windows/lua/lua-5.1.4/src/lauxlib.c diff --git a/desmume/src/windows/lua/lua-5.1.4/src/lauxlib.h b/src/windows/lua/lua-5.1.4/src/lauxlib.h similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/lauxlib.h rename to src/windows/lua/lua-5.1.4/src/lauxlib.h diff --git a/desmume/src/windows/lua/lua-5.1.4/src/lbaselib.c b/src/windows/lua/lua-5.1.4/src/lbaselib.c similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/lbaselib.c rename to src/windows/lua/lua-5.1.4/src/lbaselib.c diff --git a/desmume/src/windows/lua/lua-5.1.4/src/lcode.c b/src/windows/lua/lua-5.1.4/src/lcode.c similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/lcode.c rename to src/windows/lua/lua-5.1.4/src/lcode.c diff --git a/desmume/src/windows/lua/lua-5.1.4/src/lcode.h b/src/windows/lua/lua-5.1.4/src/lcode.h similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/lcode.h rename to src/windows/lua/lua-5.1.4/src/lcode.h diff --git a/desmume/src/windows/lua/lua-5.1.4/src/ldblib.c b/src/windows/lua/lua-5.1.4/src/ldblib.c similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/ldblib.c rename to src/windows/lua/lua-5.1.4/src/ldblib.c diff --git a/desmume/src/windows/lua/lua-5.1.4/src/ldebug.c b/src/windows/lua/lua-5.1.4/src/ldebug.c similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/ldebug.c rename to src/windows/lua/lua-5.1.4/src/ldebug.c diff --git a/desmume/src/windows/lua/lua-5.1.4/src/ldebug.h b/src/windows/lua/lua-5.1.4/src/ldebug.h similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/ldebug.h rename to src/windows/lua/lua-5.1.4/src/ldebug.h diff --git a/desmume/src/windows/lua/lua-5.1.4/src/ldo.c b/src/windows/lua/lua-5.1.4/src/ldo.c similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/ldo.c rename to src/windows/lua/lua-5.1.4/src/ldo.c diff --git a/desmume/src/windows/lua/lua-5.1.4/src/ldo.h b/src/windows/lua/lua-5.1.4/src/ldo.h similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/ldo.h rename to src/windows/lua/lua-5.1.4/src/ldo.h diff --git a/desmume/src/windows/lua/lua-5.1.4/src/ldump.c b/src/windows/lua/lua-5.1.4/src/ldump.c similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/ldump.c rename to src/windows/lua/lua-5.1.4/src/ldump.c diff --git a/desmume/src/windows/lua/lua-5.1.4/src/lfunc.c b/src/windows/lua/lua-5.1.4/src/lfunc.c similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/lfunc.c rename to src/windows/lua/lua-5.1.4/src/lfunc.c diff --git a/desmume/src/windows/lua/lua-5.1.4/src/lfunc.h b/src/windows/lua/lua-5.1.4/src/lfunc.h similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/lfunc.h rename to src/windows/lua/lua-5.1.4/src/lfunc.h diff --git a/desmume/src/windows/lua/lua-5.1.4/src/lgc.c b/src/windows/lua/lua-5.1.4/src/lgc.c similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/lgc.c rename to src/windows/lua/lua-5.1.4/src/lgc.c diff --git a/desmume/src/windows/lua/lua-5.1.4/src/lgc.h b/src/windows/lua/lua-5.1.4/src/lgc.h similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/lgc.h rename to src/windows/lua/lua-5.1.4/src/lgc.h diff --git a/desmume/src/windows/lua/lua-5.1.4/src/linit.c b/src/windows/lua/lua-5.1.4/src/linit.c similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/linit.c rename to src/windows/lua/lua-5.1.4/src/linit.c diff --git a/desmume/src/windows/lua/lua-5.1.4/src/liolib.c b/src/windows/lua/lua-5.1.4/src/liolib.c similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/liolib.c rename to src/windows/lua/lua-5.1.4/src/liolib.c diff --git a/desmume/src/windows/lua/lua-5.1.4/src/llex.c b/src/windows/lua/lua-5.1.4/src/llex.c similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/llex.c rename to src/windows/lua/lua-5.1.4/src/llex.c diff --git a/desmume/src/windows/lua/lua-5.1.4/src/llex.h b/src/windows/lua/lua-5.1.4/src/llex.h similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/llex.h rename to src/windows/lua/lua-5.1.4/src/llex.h diff --git a/desmume/src/windows/lua/lua-5.1.4/src/llimits.h b/src/windows/lua/lua-5.1.4/src/llimits.h similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/llimits.h rename to src/windows/lua/lua-5.1.4/src/llimits.h diff --git a/desmume/src/windows/lua/lua-5.1.4/src/lmathlib.c b/src/windows/lua/lua-5.1.4/src/lmathlib.c similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/lmathlib.c rename to src/windows/lua/lua-5.1.4/src/lmathlib.c diff --git a/desmume/src/windows/lua/lua-5.1.4/src/lmem.c b/src/windows/lua/lua-5.1.4/src/lmem.c similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/lmem.c rename to src/windows/lua/lua-5.1.4/src/lmem.c diff --git a/desmume/src/windows/lua/lua-5.1.4/src/lmem.h b/src/windows/lua/lua-5.1.4/src/lmem.h similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/lmem.h rename to src/windows/lua/lua-5.1.4/src/lmem.h diff --git a/desmume/src/windows/lua/lua-5.1.4/src/loadlib.c b/src/windows/lua/lua-5.1.4/src/loadlib.c similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/loadlib.c rename to src/windows/lua/lua-5.1.4/src/loadlib.c diff --git a/desmume/src/windows/lua/lua-5.1.4/src/lobject.c b/src/windows/lua/lua-5.1.4/src/lobject.c similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/lobject.c rename to src/windows/lua/lua-5.1.4/src/lobject.c diff --git a/desmume/src/windows/lua/lua-5.1.4/src/lobject.h b/src/windows/lua/lua-5.1.4/src/lobject.h similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/lobject.h rename to src/windows/lua/lua-5.1.4/src/lobject.h diff --git a/desmume/src/windows/lua/lua-5.1.4/src/lopcodes.c b/src/windows/lua/lua-5.1.4/src/lopcodes.c similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/lopcodes.c rename to src/windows/lua/lua-5.1.4/src/lopcodes.c diff --git a/desmume/src/windows/lua/lua-5.1.4/src/lopcodes.h b/src/windows/lua/lua-5.1.4/src/lopcodes.h similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/lopcodes.h rename to src/windows/lua/lua-5.1.4/src/lopcodes.h diff --git a/desmume/src/windows/lua/lua-5.1.4/src/loslib.c b/src/windows/lua/lua-5.1.4/src/loslib.c similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/loslib.c rename to src/windows/lua/lua-5.1.4/src/loslib.c diff --git a/desmume/src/windows/lua/lua-5.1.4/src/lparser.c b/src/windows/lua/lua-5.1.4/src/lparser.c similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/lparser.c rename to src/windows/lua/lua-5.1.4/src/lparser.c diff --git a/desmume/src/windows/lua/lua-5.1.4/src/lparser.h b/src/windows/lua/lua-5.1.4/src/lparser.h similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/lparser.h rename to src/windows/lua/lua-5.1.4/src/lparser.h diff --git a/desmume/src/windows/lua/lua-5.1.4/src/lstate.c b/src/windows/lua/lua-5.1.4/src/lstate.c similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/lstate.c rename to src/windows/lua/lua-5.1.4/src/lstate.c diff --git a/desmume/src/windows/lua/lua-5.1.4/src/lstate.h b/src/windows/lua/lua-5.1.4/src/lstate.h similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/lstate.h rename to src/windows/lua/lua-5.1.4/src/lstate.h diff --git a/desmume/src/windows/lua/lua-5.1.4/src/lstring.c b/src/windows/lua/lua-5.1.4/src/lstring.c similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/lstring.c rename to src/windows/lua/lua-5.1.4/src/lstring.c diff --git a/desmume/src/windows/lua/lua-5.1.4/src/lstring.h b/src/windows/lua/lua-5.1.4/src/lstring.h similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/lstring.h rename to src/windows/lua/lua-5.1.4/src/lstring.h diff --git a/desmume/src/windows/lua/lua-5.1.4/src/lstrlib.c b/src/windows/lua/lua-5.1.4/src/lstrlib.c similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/lstrlib.c rename to src/windows/lua/lua-5.1.4/src/lstrlib.c diff --git a/desmume/src/windows/lua/lua-5.1.4/src/ltable.c b/src/windows/lua/lua-5.1.4/src/ltable.c similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/ltable.c rename to src/windows/lua/lua-5.1.4/src/ltable.c diff --git a/desmume/src/windows/lua/lua-5.1.4/src/ltable.h b/src/windows/lua/lua-5.1.4/src/ltable.h similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/ltable.h rename to src/windows/lua/lua-5.1.4/src/ltable.h diff --git a/desmume/src/windows/lua/lua-5.1.4/src/ltablib.c b/src/windows/lua/lua-5.1.4/src/ltablib.c similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/ltablib.c rename to src/windows/lua/lua-5.1.4/src/ltablib.c diff --git a/desmume/src/windows/lua/lua-5.1.4/src/ltm.c b/src/windows/lua/lua-5.1.4/src/ltm.c similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/ltm.c rename to src/windows/lua/lua-5.1.4/src/ltm.c diff --git a/desmume/src/windows/lua/lua-5.1.4/src/ltm.h b/src/windows/lua/lua-5.1.4/src/ltm.h similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/ltm.h rename to src/windows/lua/lua-5.1.4/src/ltm.h diff --git a/desmume/src/windows/lua/lua-5.1.4/src/lua.c b/src/windows/lua/lua-5.1.4/src/lua.c similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/lua.c rename to src/windows/lua/lua-5.1.4/src/lua.c diff --git a/desmume/src/windows/lua/lua-5.1.4/src/lua.h b/src/windows/lua/lua-5.1.4/src/lua.h similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/lua.h rename to src/windows/lua/lua-5.1.4/src/lua.h diff --git a/desmume/src/windows/lua/lua-5.1.4/src/luac.c b/src/windows/lua/lua-5.1.4/src/luac.c similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/luac.c rename to src/windows/lua/lua-5.1.4/src/luac.c diff --git a/desmume/src/windows/lua/lua-5.1.4/src/luaconf.h b/src/windows/lua/lua-5.1.4/src/luaconf.h similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/luaconf.h rename to src/windows/lua/lua-5.1.4/src/luaconf.h diff --git a/desmume/src/windows/lua/lua-5.1.4/src/lualib.h b/src/windows/lua/lua-5.1.4/src/lualib.h similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/lualib.h rename to src/windows/lua/lua-5.1.4/src/lualib.h diff --git a/desmume/src/windows/lua/lua-5.1.4/src/lundump.c b/src/windows/lua/lua-5.1.4/src/lundump.c similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/lundump.c rename to src/windows/lua/lua-5.1.4/src/lundump.c diff --git a/desmume/src/windows/lua/lua-5.1.4/src/lundump.h b/src/windows/lua/lua-5.1.4/src/lundump.h similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/lundump.h rename to src/windows/lua/lua-5.1.4/src/lundump.h diff --git a/desmume/src/windows/lua/lua-5.1.4/src/lvm.c b/src/windows/lua/lua-5.1.4/src/lvm.c similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/lvm.c rename to src/windows/lua/lua-5.1.4/src/lvm.c diff --git a/desmume/src/windows/lua/lua-5.1.4/src/lvm.h b/src/windows/lua/lua-5.1.4/src/lvm.h similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/lvm.h rename to src/windows/lua/lua-5.1.4/src/lvm.h diff --git a/desmume/src/windows/lua/lua-5.1.4/src/lzio.c b/src/windows/lua/lua-5.1.4/src/lzio.c similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/lzio.c rename to src/windows/lua/lua-5.1.4/src/lzio.c diff --git a/desmume/src/windows/lua/lua-5.1.4/src/lzio.h b/src/windows/lua/lua-5.1.4/src/lzio.h similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/lzio.h rename to src/windows/lua/lua-5.1.4/src/lzio.h diff --git a/desmume/src/windows/lua/lua-5.1.4/src/print.c b/src/windows/lua/lua-5.1.4/src/print.c similarity index 100% rename from desmume/src/windows/lua/lua-5.1.4/src/print.c rename to src/windows/lua/lua-5.1.4/src/print.c diff --git a/desmume/src/windows/lua/vs8/lua.sln b/src/windows/lua/vs8/lua.sln similarity index 100% rename from desmume/src/windows/lua/vs8/lua.sln rename to src/windows/lua/vs8/lua.sln diff --git a/desmume/src/windows/lua/vs8/lua.vcproj b/src/windows/lua/vs8/lua.vcproj similarity index 100% rename from desmume/src/windows/lua/vs8/lua.vcproj rename to src/windows/lua/vs8/lua.vcproj diff --git a/desmume/src/windows/luaconsole.cpp b/src/windows/luaconsole.cpp similarity index 96% rename from desmume/src/windows/luaconsole.cpp rename to src/windows/luaconsole.cpp index 8daa2429a..f9c0edcc3 100644 --- a/desmume/src/windows/luaconsole.cpp +++ b/src/windows/luaconsole.cpp @@ -1,710 +1,710 @@ -#include "resource.h" -#include -#include -#include -#include -#include -#include - -#include "OpenArchive.h" - +#include "resource.h" +#include +#include +#include +#include +#include +#include + +#include "OpenArchive.h" + #ifdef WIN32 #include "common.h" #include "main.h" #include "driver.h" -#endif -#include "..\lua-engine.h" - -#define MAX_RECENT_SCRIPTS 15 - -static char Str_Tmp [1024]; // shadow added because the global one is completely unreliable - -char Recent_Scripts[MAX_RECENT_SCRIPTS][1024]; - -struct ControlLayoutInfo -{ - int controlID; - - enum LayoutType // what to do when the containing window resizes - { - NONE, // leave the control where it was - RESIZE_END, // resize the control - MOVE_START, // move the control - }; - LayoutType horizontalLayout; - LayoutType verticalLayout; -}; -struct ControlLayoutState -{ - int x,y,width,height; - bool valid; - ControlLayoutState() : valid(false) {} -}; - -static ControlLayoutInfo controlLayoutInfos [] = { - {IDC_LUACONSOLE, ControlLayoutInfo::RESIZE_END, ControlLayoutInfo::RESIZE_END}, - {IDC_EDIT_LUAPATH, ControlLayoutInfo::RESIZE_END, ControlLayoutInfo::NONE}, - {IDC_BUTTON_LUARUN, ControlLayoutInfo::MOVE_START, ControlLayoutInfo::NONE}, - {IDC_BUTTON_LUASTOP, ControlLayoutInfo::MOVE_START, ControlLayoutInfo::NONE}, -}; -static const int numControlLayoutInfos = sizeof(controlLayoutInfos)/sizeof(*controlLayoutInfos); - - -extern std::vector LuaScriptHWnds; -struct LuaPerWindowInfo { - std::string filename; - HANDLE fileWatcherThread; - bool started; - bool closeOnStop; - bool subservient; - int width; int height; - ControlLayoutState layoutState [numControlLayoutInfos]; - LuaPerWindowInfo() : fileWatcherThread(NULL), started(false), closeOnStop(false), subservient(false), width(405), height(244) {} -}; -std::map LuaWindowInfo; -static char Lua_Dir[1024]=""; - -int WINAPI FileSysWatcher (LPVOID arg) -{ - HWND hDlg = (HWND)arg; - LuaPerWindowInfo& info = LuaWindowInfo[hDlg]; - - while(true) - { - char filename [1024], directory [1024]; - - strncpy(filename, info.filename.c_str(), 1024); - filename[1023] = 0; - strcpy(directory, filename); - char* slash = strrchr(directory, '/'); - slash = std::max(slash, strrchr(directory, '\\')); - if(slash) - *slash = 0; - - char* bar = strchr(filename, '|'); - if(bar) *bar = '\0'; - - WIN32_FILE_ATTRIBUTE_DATA origData; - GetFileAttributesEx (filename, GetFileExInfoStandard, (LPVOID)&origData); - - HANDLE hNotify = FindFirstChangeNotification(directory, FALSE, FILE_NOTIFY_CHANGE_LAST_WRITE); - - if(hNotify) - { - DWORD dwWaitResult = WaitForSingleObject(hNotify, 500); - - if(dwWaitResult != STATUS_TIMEOUT) - { - if(dwWaitResult == WAIT_ABANDONED) - return dwWaitResult; - - WIN32_FILE_ATTRIBUTE_DATA data; - GetFileAttributesEx (filename, GetFileExInfoStandard, (LPVOID)&data); - - // at this point it could be any file in the directory that changed - // so check to make sure it was the file we care about - if(memcmp(&origData.ftLastWriteTime, &data.ftLastWriteTime, sizeof(FILETIME))) - { - RequestAbortLuaScript((int)hDlg, "terminated to reload the script"); - PostMessage(hDlg, WM_COMMAND, IDC_BUTTON_LUARUN, 0); - } - } - - //FindNextChangeNotification(hNotify); // let's not try to reuse it... - FindCloseChangeNotification(hNotify); // but let's at least make sure to release it! - } - else - { - Sleep(500); - } - } - - return 0; -} - -void RegisterWatcherThread (HWND hDlg) -{ - HANDLE thread = CreateThread(NULL, 0, (LPTHREAD_START_ROUTINE) FileSysWatcher, (LPVOID) hDlg, CREATE_SUSPENDED, NULL); - SetThreadPriority(thread, THREAD_PRIORITY_LOWEST); - - LuaPerWindowInfo& info = LuaWindowInfo[hDlg]; - info.fileWatcherThread = thread; - - ResumeThread(thread); -} -void KillWatcherThread (HWND hDlg) -{ - LuaPerWindowInfo& info = LuaWindowInfo[hDlg]; - TerminateThread(info.fileWatcherThread, 0); - info.fileWatcherThread = NULL; -} - - -// some extensions that might commonly be near lua files that almost certainly aren't lua files. -static const char* s_nonLuaExtensions [] = {"txt", "nfo", "htm", "html", "jpg", "jpeg", "png", "bmp", "gif", "mp3", "wav", "lnk", "exe", "bat", "gmv", "gm2", "luasav", "sav", "srm", "brm", "cfg", "wch", "gs*", "bin","smd","gen","32x","cue","iso","raw"}; - - -void Update_Recent_Script(const char* Path, bool dontPutAtTop) -{ - char LogicalName[1024], PhysicalName[1024]; - bool exists = ObtainFile(Path, LogicalName, PhysicalName, "luacheck", s_nonLuaExtensions, sizeof(s_nonLuaExtensions)/sizeof(*s_nonLuaExtensions)); - ReleaseTempFileCategory("luacheck"); // delete the temporary (physical) file if any - - if(!exists) - return; - - int i; - - for(i = 0; i < MAX_RECENT_SCRIPTS; i++) - { - if (!(strcmp(Recent_Scripts[i], Path))) - { - // move recent item to the top of the list - if(i == 0 || dontPutAtTop) - return; - char temp [1024]; - strcpy(temp, Recent_Scripts[i]); - int j; - for(j = i; j > 0; j--) - strcpy(Recent_Scripts[j], Recent_Scripts[j-1]); - strcpy(Recent_Scripts[0], temp); -// MustUpdateMenu = 1; - return; - } - } - - if(!dontPutAtTop) - { - // add to start of recent list - for(i = MAX_RECENT_SCRIPTS-1; i > 0; i--) - strcpy(Recent_Scripts[i], Recent_Scripts[i - 1]); - - strcpy(Recent_Scripts[0], Path); - } - else - { - // add to end of recent list - for(i = 0; i < MAX_RECENT_SCRIPTS; i++) - { - if(!*Recent_Scripts[i]) - { - strcpy(Recent_Scripts[i], Path); - break; - } - } - } - -// MustUpdateMenu = 1; -} - -HWND IsScriptFileOpen(const char* Path) -{ - for(std::map::iterator iter = LuaWindowInfo.begin(); iter != LuaWindowInfo.end(); ++iter) - { - LuaPerWindowInfo& info = iter->second; - const char* filename = info.filename.c_str(); - const char* pathPtr = Path; - - // case-insensitive slash-direction-insensitive compare - bool same = true; - while(*filename || *pathPtr) - { - if((*filename == '/' || *filename == '\\') && (*pathPtr == '/' || *pathPtr == '\\')) - { - do {filename++;} while(*filename == '/' || *filename == '\\'); - do {pathPtr++;} while(*pathPtr == '/' || *pathPtr == '\\'); - } - else if(tolower(*filename) != tolower(*pathPtr)) - { - same = false; - break; - } - else - { - filename++; - pathPtr++; - } - } - - if(same) - return iter->first; - } - return NULL; -} - - -void PrintToWindowConsole(int hDlgAsInt, const char* str) -{ - HWND hDlg = (HWND)hDlgAsInt; - HWND hConsole = GetDlgItem(hDlg, IDC_LUACONSOLE); - - int length = GetWindowTextLength(hConsole); - if(length >= 250000) - { - // discard first half of text if it's getting too long - SendMessage(hConsole, EM_SETSEL, 0, length/2); - SendMessage(hConsole, EM_REPLACESEL, false, (LPARAM)""); - length = GetWindowTextLength(hConsole); - } - SendMessage(hConsole, EM_SETSEL, length, length); - - LuaPerWindowInfo& info = LuaWindowInfo[hDlg]; - - { - SendMessage(hConsole, EM_REPLACESEL, false, (LPARAM)str); - } -} - -extern int Show_Genesis_Screen(HWND hWnd); -void OnStart(int hDlgAsInt) -{ - HWND hDlg = (HWND)hDlgAsInt; - LuaPerWindowInfo& info = LuaWindowInfo[hDlg]; - info.started = true; - EnableWindow(GetDlgItem(hDlg, IDC_BUTTON_LUABROWSE), false); // disable browse while running because it misbehaves if clicked in a frameadvance loop - EnableWindow(GetDlgItem(hDlg, IDC_BUTTON_LUASTOP), true); - SetWindowText(GetDlgItem(hDlg, IDC_BUTTON_LUARUN), "Restart"); - SetWindowText(GetDlgItem(hDlg, IDC_LUACONSOLE), ""); // clear the console -// Show_Genesis_Screen(HWnd); // otherwise we might never show the first thing the script draws -} - -void OnStop(int hDlgAsInt, bool statusOK) -{ - HWND hDlg = (HWND)hDlgAsInt; - LuaPerWindowInfo& info = LuaWindowInfo[hDlg]; - - HWND prevWindow = GetActiveWindow(); - SetActiveWindow(hDlg); // bring to front among other script/secondary windows, since a stopped script will have some message for the user that would be easier to miss otherwise - if(prevWindow == MainWindow->getHWnd()) SetActiveWindow(prevWindow); - - info.started = false; - EnableWindow(GetDlgItem(hDlg, IDC_BUTTON_LUABROWSE), true); - EnableWindow(GetDlgItem(hDlg, IDC_BUTTON_LUASTOP), false); - SetWindowText(GetDlgItem(hDlg, IDC_BUTTON_LUARUN), "Run"); -// if(statusOK) -// Show_Genesis_Screen(MainWindow->getHWnd()); // otherwise we might never show the last thing the script draws - if(info.closeOnStop) - PostMessage(hDlg, WM_CLOSE, 0, 0); -} - -const char* MakeScriptPathAbsolute(const char* filename, const char* extraDirToCheck); - -void UpdateFileEntered(HWND hDlg) -{ - char local_str_tmp [1024]; - SendDlgItemMessage(hDlg,IDC_EDIT_LUAPATH,WM_GETTEXT,(WPARAM)512,(LPARAM)local_str_tmp); - - // if it exists, make sure we're using an absolute path to it - const char* filename = local_str_tmp; - FILE* file = fopen(filename, "rb"); - if(file) - { - fclose(file); - filename = MakeScriptPathAbsolute(local_str_tmp, NULL); - if(filename != local_str_tmp && stricmp(filename, local_str_tmp)) - { - SendDlgItemMessage(hDlg,IDC_EDIT_LUAPATH,WM_SETTEXT,(WPARAM)512,(LPARAM)filename); - SendDlgItemMessage(hDlg,IDC_EDIT_LUAPATH,EM_SETSEL,0,-1); - SendDlgItemMessage(hDlg,IDC_EDIT_LUAPATH,EM_SETSEL,-1,-1); - return; - } - } - - // use ObtainFile to support opening files within archives - char LogicalName[1024], PhysicalName[1024]; - bool exists = ObtainFile(filename, LogicalName, PhysicalName, "luacheck", s_nonLuaExtensions, sizeof(s_nonLuaExtensions)/sizeof(*s_nonLuaExtensions)); - bool readonly = exists ? ((GetFileAttributes(PhysicalName) & FILE_ATTRIBUTE_READONLY) != 0) : (strchr(LogicalName, '|') != NULL || strchr(filename, '|') != NULL); - ReleaseTempFileCategory("luacheck"); // delete the temporary (physical) file if any - - if(exists) - { - LuaPerWindowInfo& info = LuaWindowInfo[hDlg]; - info.filename = LogicalName; - - char* slash = strrchr(LogicalName, '/'); - slash = std::max(slash, strrchr(LogicalName, '\\')); - if(slash) - slash++; - else - slash = LogicalName; - SetWindowText(hDlg, slash); -// Build_Main_Menu(); - - PostMessage(hDlg, WM_COMMAND, IDC_BUTTON_LUARUN, 0); - } - - const char* ext = strrchr(LogicalName, '.'); - bool isLuaFile = ext && !_stricmp(ext, ".lua"); - if(exists) - { - SetWindowText(GetDlgItem(hDlg, IDC_BUTTON_LUAEDIT), isLuaFile ? (readonly ? "View" : "Edit") : "Open"); - EnableWindow(GetDlgItem(hDlg, IDC_BUTTON_LUAEDIT), true); - } - else - { - SetWindowText(GetDlgItem(hDlg, IDC_BUTTON_LUAEDIT), "Create"); - EnableWindow(GetDlgItem(hDlg, IDC_BUTTON_LUAEDIT), isLuaFile && !readonly); - } -} - -//extern "C" int Clear_Sound_Buffer(void); - -static int Change_File_L(char *Dest, char *Dir, char *Titre, char *Filter, char *Ext, HWND hwnd) -{ - OPENFILENAME ofn; - -// SetCurrentDirectory(Desmume_Path); - - if (!strcmp(Dest, "")) - { - strcpy(Dest, "default."); - strcat(Dest, Ext); - } - - memset(&ofn, 0, sizeof(OPENFILENAME)); - - ofn.lStructSize = sizeof(OPENFILENAME); - ofn.hwndOwner = hwnd; - ofn.hInstance = hAppInst; - ofn.lpstrFile = Dest; - ofn.nMaxFile = 2047; - ofn.lpstrFilter = Filter; - ofn.nFilterIndex = 1; - ofn.lpstrInitialDir = Dir; - ofn.lpstrTitle = Titre; - ofn.lpstrDefExt = Ext; - ofn.Flags = OFN_FILEMUSTEXIST | OFN_HIDEREADONLY; - - if (GetOpenFileName(&ofn)) return 1; - - return 0; -} - -LRESULT CALLBACK LuaScriptProc(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam) -{ - RECT r; - RECT r2; - int dx1, dy1, dx2, dy2; - - switch(uMsg) - { - case WM_INITDIALOG: { - if(std::find(LuaScriptHWnds.begin(), LuaScriptHWnds.end(), hDlg) == LuaScriptHWnds.end()) - { - LuaScriptHWnds.push_back(hDlg); -// Build_Main_Menu(); - } -// if (Full_Screen) -// { -// while (ShowCursor(false) >= 0); -// while (ShowCursor(true) < 0); -// } - -// HANDLE hIcon = LoadIcon(GetModuleHandle(NULL), MAKEINTRESOURCE(IDI_LUA)); -// SendMessage(hDlg, WM_SETICON, ICON_BIG, (LPARAM)hIcon); - - // remove the 30000 character limit from the console control - SendMessage(GetDlgItem(hDlg, IDC_LUACONSOLE),EM_LIMITTEXT,0,0); - - GetWindowRect(MainWindow->getHWnd(), &r); - dx1 = (r.right - r.left) / 2; - dy1 = (r.bottom - r.top) / 2; - - GetWindowRect(hDlg, &r2); - dx2 = (r2.right - r2.left) / 2; - dy2 = (r2.bottom - r2.top) / 2; - - int windowIndex = std::find(LuaScriptHWnds.begin(), LuaScriptHWnds.end(), hDlg) - LuaScriptHWnds.begin(); - int staggerOffset = windowIndex * 24; - r.left += staggerOffset; - r.right += staggerOffset; - r.top += staggerOffset; - r.bottom += staggerOffset; - - // push it away from the main window if we can - const int width = (r.right-r.left); - const int width2 = (r2.right-r2.left); - if(r.left+width2 + width < GetSystemMetrics(SM_CXSCREEN)) - { - r.right += width; - r.left += width; - } - else if((int)r.left - (int)width2 > 0) - { - r.right -= width2; - r.left -= width2; - } - - SetWindowPos(hDlg, NULL, r.left, r.top, NULL, NULL, SWP_NOSIZE | SWP_NOZORDER | SWP_SHOWWINDOW); - - LuaPerWindowInfo info; - { - RECT r3; - GetClientRect(hDlg, &r3); - info.width = r3.right - r3.left; - info.height = r3.bottom - r3.top; - } - LuaWindowInfo[hDlg] = info; - RegisterWatcherThread(hDlg); - - OpenLuaContext((int)hDlg, PrintToWindowConsole, OnStart, OnStop); - - DragAcceptFiles(hDlg, TRUE); - - return true; - } break; - - case WM_MENUSELECT: - case WM_ENTERSIZEMOVE: -// Clear_Sound_Buffer(); - break; - - case WM_SIZING: - { - // enforce a minimum window size - - LPRECT r = (LPRECT) lParam; - int minimumWidth = 333; - int minimumHeight = 117; - if(r->right - r->left < minimumWidth) - if(wParam == WMSZ_LEFT || wParam == WMSZ_TOPLEFT || wParam == WMSZ_BOTTOMLEFT) - r->left = r->right - minimumWidth; - else - r->right = r->left + minimumWidth; - if(r->bottom - r->top < minimumHeight) - if(wParam == WMSZ_TOP || wParam == WMSZ_TOPLEFT || wParam == WMSZ_TOPRIGHT) - r->top = r->bottom - minimumHeight; - else - r->bottom = r->top + minimumHeight; - } - return TRUE; - - case WM_SIZE: - { - // resize or move controls in the window as necessary when the window is resized - - LuaPerWindowInfo& windowInfo = LuaWindowInfo[hDlg]; - int prevDlgWidth = windowInfo.width; - int prevDlgHeight = windowInfo.height; - - int dlgWidth = LOWORD(lParam); - int dlgHeight = HIWORD(lParam); - - int deltaWidth = dlgWidth - prevDlgWidth; - int deltaHeight = dlgHeight - prevDlgHeight; - - for(int i = 0; i < numControlLayoutInfos; i++) - { - ControlLayoutInfo layoutInfo = controlLayoutInfos[i]; - ControlLayoutState& layoutState = windowInfo.layoutState[i]; - - HWND hCtrl = GetDlgItem(hDlg,layoutInfo.controlID); - - int x,y,width,height; - if(layoutState.valid) - { - x = layoutState.x; - y = layoutState.y; - width = layoutState.width; - height = layoutState.height; - } - else - { - RECT r; - GetWindowRect(hCtrl, &r); - POINT p = {r.left, r.top}; - ScreenToClient(hDlg, &p); - x = p.x; - y = p.y; - width = r.right - r.left; - height = r.bottom - r.top; - } - - switch(layoutInfo.horizontalLayout) - { - case ControlLayoutInfo::RESIZE_END: width += deltaWidth; break; - case ControlLayoutInfo::MOVE_START: x += deltaWidth; break; - default: break; - } - switch(layoutInfo.verticalLayout) - { - case ControlLayoutInfo::RESIZE_END: height += deltaHeight; break; - case ControlLayoutInfo::MOVE_START: y += deltaHeight; break; - default: break; - } - - SetWindowPos(hCtrl, 0, x,y, width,height, 0); - - layoutState.x = x; - layoutState.y = y; - layoutState.width = width; - layoutState.height = height; - layoutState.valid = true; - } - - windowInfo.width = dlgWidth; - windowInfo.height = dlgHeight; - - RedrawWindow(hDlg, NULL, NULL, RDW_INVALIDATE); - } - break; - - case WM_COMMAND: - { - switch(LOWORD(wParam)) - { - case IDC_BUTTON_LUABROWSE: - { - LuaPerWindowInfo& info = LuaWindowInfo[hDlg]; - char Str_Tmp [1024]; // shadow added because the global one is unreliable - strcpy(Str_Tmp,info.filename.c_str()); - SendDlgItemMessage(hDlg,IDC_EDIT_LUAPATH,WM_GETTEXT,(WPARAM)512,(LPARAM)Str_Tmp); - char* bar = strchr(Str_Tmp, '|'); - if(bar) *bar = '\0'; -// DialogsOpen++; -// Clear_Sound_Buffer(); - if(Change_File_L(Str_Tmp, Lua_Dir, "Load Lua Script", "Lua Script\0*.lua*\0All Files\0*.*\0\0", "lua", hDlg)) - { - SendDlgItemMessage(hDlg,IDC_EDIT_LUAPATH,WM_SETTEXT,0,(LPARAM)Str_Tmp); - } -// DialogsOpen--; - - } break; - case IDC_BUTTON_LUAEDIT: - { - LuaPerWindowInfo& info = LuaWindowInfo[hDlg]; - char Str_Tmp [1024]; // shadow added because the global one is unreliable - strcpy(Str_Tmp,info.filename.c_str()); - SendDlgItemMessage(hDlg,IDC_EDIT_LUAPATH,WM_GETTEXT,(WPARAM)512,(LPARAM)Str_Tmp); - char LogicalName[1024], PhysicalName[1024]; - bool exists = ObtainFile(Str_Tmp, LogicalName, PhysicalName, "luaview", s_nonLuaExtensions, sizeof(s_nonLuaExtensions)/sizeof(*s_nonLuaExtensions)); - bool created = false; - if(!exists) - { - FILE* file = fopen(Str_Tmp, "r"); - if(!file) - { - file = fopen(Str_Tmp, "w"); - if(file) - { - created = true; - exists = true; - strcpy(PhysicalName, Str_Tmp); - } - } - if(file) - fclose(file); - } - if(exists) - { - // tell the OS to open the file with its associated editor, - // without blocking on it or leaving a command window open. - ShellExecute(NULL, "open", PhysicalName, NULL, NULL, SW_SHOWNORMAL); - } - if(created) - { - UpdateFileEntered(hDlg); - } - } break; - case IDC_EDIT_LUAPATH: - { - switch(HIWORD(wParam)) - { - case EN_CHANGE: - { - UpdateFileEntered(hDlg); - } break; - } - } break; - case IDC_BUTTON_LUARUN: - { - HWND focus = GetFocus(); - HWND textbox = GetDlgItem(hDlg, IDC_EDIT_LUAPATH); - if(focus != textbox) - SetActiveWindow(MainWindow->getHWnd()); - - LuaPerWindowInfo& info = LuaWindowInfo[hDlg]; - strcpy(Str_Tmp,info.filename.c_str()); - char LogicalName[1024], PhysicalName[1024]; - bool exists = ObtainFile(Str_Tmp, LogicalName, PhysicalName, "luarun", s_nonLuaExtensions, sizeof(s_nonLuaExtensions)/sizeof(*s_nonLuaExtensions)); - Update_Recent_Script(LogicalName, info.subservient); - RunLuaScriptFile((int)hDlg, PhysicalName); - } break; - case IDC_BUTTON_LUASTOP: - { - PrintToWindowConsole((int)hDlg, "user clicked stop button\r\n"); - SetActiveWindow(MainWindow->getHWnd()); - StopLuaScript((int)hDlg); - } break; - case IDC_NOTIFY_SUBSERVIENT: - { - LuaPerWindowInfo& info = LuaWindowInfo[hDlg]; - info.subservient = lParam ? true : false; - } break; - //case IDOK: - case IDCANCEL: - { LuaPerWindowInfo& info = LuaWindowInfo[hDlg]; - if(info.filename.empty()) - { -// if (Full_Screen) -// { -// while (ShowCursor(true) < 0); -// while (ShowCursor(false) >= 0); -// } -// DialogsOpen--; - DragAcceptFiles(hDlg, FALSE); - KillWatcherThread(hDlg); - LuaScriptHWnds.erase(remove(LuaScriptHWnds.begin(), LuaScriptHWnds.end(), hDlg), LuaScriptHWnds.end()); - LuaWindowInfo.erase(hDlg); - CloseLuaContext((int)hDlg); -// Build_Main_Menu(); - EndDialog(hDlg, true); - } - } return true; - } - - return false; - } break; - - case WM_CLOSE: - { - LuaPerWindowInfo& info = LuaWindowInfo[hDlg]; - - PrintToWindowConsole((int)hDlg, "user closed script window\r\n"); - StopLuaScript((int)hDlg); - if(info.started) - { - // not stopped yet, wait to close until we are, otherwise we'll crash - info.closeOnStop = true; - return false; - } - -// if (Full_Screen) -// { -// while (ShowCursor(true) < 0); -// while (ShowCursor(false) >= 0); -// } -// DialogsOpen--; - DragAcceptFiles(hDlg, FALSE); - KillWatcherThread(hDlg); - LuaScriptHWnds.erase(remove(LuaScriptHWnds.begin(), LuaScriptHWnds.end(), hDlg), LuaScriptHWnds.end()); - LuaWindowInfo.erase(hDlg); - CloseLuaContext((int)hDlg); -// Build_Main_Menu(); - EndDialog(hDlg, true); - } return true; - - case WM_DROPFILES: - { - HDROP hDrop = (HDROP)wParam; - DragQueryFile(hDrop, 0, Str_Tmp, 1024); - DragFinish(hDrop); - SendDlgItemMessage(hDlg,IDC_EDIT_LUAPATH,WM_SETTEXT,0,(LPARAM)Str_Tmp ); - UpdateFileEntered(hDlg); - } return true; - - } - - return false; -} - +#endif +#include "..\lua-engine.h" + +#define MAX_RECENT_SCRIPTS 15 + +static char Str_Tmp [1024]; // shadow added because the global one is completely unreliable + +char Recent_Scripts[MAX_RECENT_SCRIPTS][1024]; + +struct ControlLayoutInfo +{ + int controlID; + + enum LayoutType // what to do when the containing window resizes + { + NONE, // leave the control where it was + RESIZE_END, // resize the control + MOVE_START, // move the control + }; + LayoutType horizontalLayout; + LayoutType verticalLayout; +}; +struct ControlLayoutState +{ + int x,y,width,height; + bool valid; + ControlLayoutState() : valid(false) {} +}; + +static ControlLayoutInfo controlLayoutInfos [] = { + {IDC_LUACONSOLE, ControlLayoutInfo::RESIZE_END, ControlLayoutInfo::RESIZE_END}, + {IDC_EDIT_LUAPATH, ControlLayoutInfo::RESIZE_END, ControlLayoutInfo::NONE}, + {IDC_BUTTON_LUARUN, ControlLayoutInfo::MOVE_START, ControlLayoutInfo::NONE}, + {IDC_BUTTON_LUASTOP, ControlLayoutInfo::MOVE_START, ControlLayoutInfo::NONE}, +}; +static const int numControlLayoutInfos = sizeof(controlLayoutInfos)/sizeof(*controlLayoutInfos); + + +extern std::vector LuaScriptHWnds; +struct LuaPerWindowInfo { + std::string filename; + HANDLE fileWatcherThread; + bool started; + bool closeOnStop; + bool subservient; + int width; int height; + ControlLayoutState layoutState [numControlLayoutInfos]; + LuaPerWindowInfo() : fileWatcherThread(NULL), started(false), closeOnStop(false), subservient(false), width(405), height(244) {} +}; +std::map LuaWindowInfo; +static char Lua_Dir[1024]=""; + +int WINAPI FileSysWatcher (LPVOID arg) +{ + HWND hDlg = (HWND)arg; + LuaPerWindowInfo& info = LuaWindowInfo[hDlg]; + + while(true) + { + char filename [1024], directory [1024]; + + strncpy(filename, info.filename.c_str(), 1024); + filename[1023] = 0; + strcpy(directory, filename); + char* slash = strrchr(directory, '/'); + slash = std::max(slash, strrchr(directory, '\\')); + if(slash) + *slash = 0; + + char* bar = strchr(filename, '|'); + if(bar) *bar = '\0'; + + WIN32_FILE_ATTRIBUTE_DATA origData; + GetFileAttributesEx (filename, GetFileExInfoStandard, (LPVOID)&origData); + + HANDLE hNotify = FindFirstChangeNotification(directory, FALSE, FILE_NOTIFY_CHANGE_LAST_WRITE); + + if(hNotify) + { + DWORD dwWaitResult = WaitForSingleObject(hNotify, 500); + + if(dwWaitResult != STATUS_TIMEOUT) + { + if(dwWaitResult == WAIT_ABANDONED) + return dwWaitResult; + + WIN32_FILE_ATTRIBUTE_DATA data; + GetFileAttributesEx (filename, GetFileExInfoStandard, (LPVOID)&data); + + // at this point it could be any file in the directory that changed + // so check to make sure it was the file we care about + if(memcmp(&origData.ftLastWriteTime, &data.ftLastWriteTime, sizeof(FILETIME))) + { + RequestAbortLuaScript((int)hDlg, "terminated to reload the script"); + PostMessage(hDlg, WM_COMMAND, IDC_BUTTON_LUARUN, 0); + } + } + + //FindNextChangeNotification(hNotify); // let's not try to reuse it... + FindCloseChangeNotification(hNotify); // but let's at least make sure to release it! + } + else + { + Sleep(500); + } + } + + return 0; +} + +void RegisterWatcherThread (HWND hDlg) +{ + HANDLE thread = CreateThread(NULL, 0, (LPTHREAD_START_ROUTINE) FileSysWatcher, (LPVOID) hDlg, CREATE_SUSPENDED, NULL); + SetThreadPriority(thread, THREAD_PRIORITY_LOWEST); + + LuaPerWindowInfo& info = LuaWindowInfo[hDlg]; + info.fileWatcherThread = thread; + + ResumeThread(thread); +} +void KillWatcherThread (HWND hDlg) +{ + LuaPerWindowInfo& info = LuaWindowInfo[hDlg]; + TerminateThread(info.fileWatcherThread, 0); + info.fileWatcherThread = NULL; +} + + +// some extensions that might commonly be near lua files that almost certainly aren't lua files. +static const char* s_nonLuaExtensions [] = {"txt", "nfo", "htm", "html", "jpg", "jpeg", "png", "bmp", "gif", "mp3", "wav", "lnk", "exe", "bat", "gmv", "gm2", "luasav", "sav", "srm", "brm", "cfg", "wch", "gs*", "bin","smd","gen","32x","cue","iso","raw"}; + + +void Update_Recent_Script(const char* Path, bool dontPutAtTop) +{ + char LogicalName[1024], PhysicalName[1024]; + bool exists = ObtainFile(Path, LogicalName, PhysicalName, "luacheck", s_nonLuaExtensions, sizeof(s_nonLuaExtensions)/sizeof(*s_nonLuaExtensions)); + ReleaseTempFileCategory("luacheck"); // delete the temporary (physical) file if any + + if(!exists) + return; + + int i; + + for(i = 0; i < MAX_RECENT_SCRIPTS; i++) + { + if (!(strcmp(Recent_Scripts[i], Path))) + { + // move recent item to the top of the list + if(i == 0 || dontPutAtTop) + return; + char temp [1024]; + strcpy(temp, Recent_Scripts[i]); + int j; + for(j = i; j > 0; j--) + strcpy(Recent_Scripts[j], Recent_Scripts[j-1]); + strcpy(Recent_Scripts[0], temp); +// MustUpdateMenu = 1; + return; + } + } + + if(!dontPutAtTop) + { + // add to start of recent list + for(i = MAX_RECENT_SCRIPTS-1; i > 0; i--) + strcpy(Recent_Scripts[i], Recent_Scripts[i - 1]); + + strcpy(Recent_Scripts[0], Path); + } + else + { + // add to end of recent list + for(i = 0; i < MAX_RECENT_SCRIPTS; i++) + { + if(!*Recent_Scripts[i]) + { + strcpy(Recent_Scripts[i], Path); + break; + } + } + } + +// MustUpdateMenu = 1; +} + +HWND IsScriptFileOpen(const char* Path) +{ + for(std::map::iterator iter = LuaWindowInfo.begin(); iter != LuaWindowInfo.end(); ++iter) + { + LuaPerWindowInfo& info = iter->second; + const char* filename = info.filename.c_str(); + const char* pathPtr = Path; + + // case-insensitive slash-direction-insensitive compare + bool same = true; + while(*filename || *pathPtr) + { + if((*filename == '/' || *filename == '\\') && (*pathPtr == '/' || *pathPtr == '\\')) + { + do {filename++;} while(*filename == '/' || *filename == '\\'); + do {pathPtr++;} while(*pathPtr == '/' || *pathPtr == '\\'); + } + else if(tolower(*filename) != tolower(*pathPtr)) + { + same = false; + break; + } + else + { + filename++; + pathPtr++; + } + } + + if(same) + return iter->first; + } + return NULL; +} + + +void PrintToWindowConsole(int hDlgAsInt, const char* str) +{ + HWND hDlg = (HWND)hDlgAsInt; + HWND hConsole = GetDlgItem(hDlg, IDC_LUACONSOLE); + + int length = GetWindowTextLength(hConsole); + if(length >= 250000) + { + // discard first half of text if it's getting too long + SendMessage(hConsole, EM_SETSEL, 0, length/2); + SendMessage(hConsole, EM_REPLACESEL, false, (LPARAM)""); + length = GetWindowTextLength(hConsole); + } + SendMessage(hConsole, EM_SETSEL, length, length); + + LuaPerWindowInfo& info = LuaWindowInfo[hDlg]; + + { + SendMessage(hConsole, EM_REPLACESEL, false, (LPARAM)str); + } +} + +extern int Show_Genesis_Screen(HWND hWnd); +void OnStart(int hDlgAsInt) +{ + HWND hDlg = (HWND)hDlgAsInt; + LuaPerWindowInfo& info = LuaWindowInfo[hDlg]; + info.started = true; + EnableWindow(GetDlgItem(hDlg, IDC_BUTTON_LUABROWSE), false); // disable browse while running because it misbehaves if clicked in a frameadvance loop + EnableWindow(GetDlgItem(hDlg, IDC_BUTTON_LUASTOP), true); + SetWindowText(GetDlgItem(hDlg, IDC_BUTTON_LUARUN), "Restart"); + SetWindowText(GetDlgItem(hDlg, IDC_LUACONSOLE), ""); // clear the console +// Show_Genesis_Screen(HWnd); // otherwise we might never show the first thing the script draws +} + +void OnStop(int hDlgAsInt, bool statusOK) +{ + HWND hDlg = (HWND)hDlgAsInt; + LuaPerWindowInfo& info = LuaWindowInfo[hDlg]; + + HWND prevWindow = GetActiveWindow(); + SetActiveWindow(hDlg); // bring to front among other script/secondary windows, since a stopped script will have some message for the user that would be easier to miss otherwise + if(prevWindow == MainWindow->getHWnd()) SetActiveWindow(prevWindow); + + info.started = false; + EnableWindow(GetDlgItem(hDlg, IDC_BUTTON_LUABROWSE), true); + EnableWindow(GetDlgItem(hDlg, IDC_BUTTON_LUASTOP), false); + SetWindowText(GetDlgItem(hDlg, IDC_BUTTON_LUARUN), "Run"); +// if(statusOK) +// Show_Genesis_Screen(MainWindow->getHWnd()); // otherwise we might never show the last thing the script draws + if(info.closeOnStop) + PostMessage(hDlg, WM_CLOSE, 0, 0); +} + +const char* MakeScriptPathAbsolute(const char* filename, const char* extraDirToCheck); + +void UpdateFileEntered(HWND hDlg) +{ + char local_str_tmp [1024]; + SendDlgItemMessage(hDlg,IDC_EDIT_LUAPATH,WM_GETTEXT,(WPARAM)512,(LPARAM)local_str_tmp); + + // if it exists, make sure we're using an absolute path to it + const char* filename = local_str_tmp; + FILE* file = fopen(filename, "rb"); + if(file) + { + fclose(file); + filename = MakeScriptPathAbsolute(local_str_tmp, NULL); + if(filename != local_str_tmp && stricmp(filename, local_str_tmp)) + { + SendDlgItemMessage(hDlg,IDC_EDIT_LUAPATH,WM_SETTEXT,(WPARAM)512,(LPARAM)filename); + SendDlgItemMessage(hDlg,IDC_EDIT_LUAPATH,EM_SETSEL,0,-1); + SendDlgItemMessage(hDlg,IDC_EDIT_LUAPATH,EM_SETSEL,-1,-1); + return; + } + } + + // use ObtainFile to support opening files within archives + char LogicalName[1024], PhysicalName[1024]; + bool exists = ObtainFile(filename, LogicalName, PhysicalName, "luacheck", s_nonLuaExtensions, sizeof(s_nonLuaExtensions)/sizeof(*s_nonLuaExtensions)); + bool readonly = exists ? ((GetFileAttributes(PhysicalName) & FILE_ATTRIBUTE_READONLY) != 0) : (strchr(LogicalName, '|') != NULL || strchr(filename, '|') != NULL); + ReleaseTempFileCategory("luacheck"); // delete the temporary (physical) file if any + + if(exists) + { + LuaPerWindowInfo& info = LuaWindowInfo[hDlg]; + info.filename = LogicalName; + + char* slash = strrchr(LogicalName, '/'); + slash = std::max(slash, strrchr(LogicalName, '\\')); + if(slash) + slash++; + else + slash = LogicalName; + SetWindowText(hDlg, slash); +// Build_Main_Menu(); + + PostMessage(hDlg, WM_COMMAND, IDC_BUTTON_LUARUN, 0); + } + + const char* ext = strrchr(LogicalName, '.'); + bool isLuaFile = ext && !_stricmp(ext, ".lua"); + if(exists) + { + SetWindowText(GetDlgItem(hDlg, IDC_BUTTON_LUAEDIT), isLuaFile ? (readonly ? "View" : "Edit") : "Open"); + EnableWindow(GetDlgItem(hDlg, IDC_BUTTON_LUAEDIT), true); + } + else + { + SetWindowText(GetDlgItem(hDlg, IDC_BUTTON_LUAEDIT), "Create"); + EnableWindow(GetDlgItem(hDlg, IDC_BUTTON_LUAEDIT), isLuaFile && !readonly); + } +} + +//extern "C" int Clear_Sound_Buffer(void); + +static int Change_File_L(char *Dest, char *Dir, char *Titre, char *Filter, char *Ext, HWND hwnd) +{ + OPENFILENAME ofn; + +// SetCurrentDirectory(Desmume_Path); + + if (!strcmp(Dest, "")) + { + strcpy(Dest, "default."); + strcat(Dest, Ext); + } + + memset(&ofn, 0, sizeof(OPENFILENAME)); + + ofn.lStructSize = sizeof(OPENFILENAME); + ofn.hwndOwner = hwnd; + ofn.hInstance = hAppInst; + ofn.lpstrFile = Dest; + ofn.nMaxFile = 2047; + ofn.lpstrFilter = Filter; + ofn.nFilterIndex = 1; + ofn.lpstrInitialDir = Dir; + ofn.lpstrTitle = Titre; + ofn.lpstrDefExt = Ext; + ofn.Flags = OFN_FILEMUSTEXIST | OFN_HIDEREADONLY; + + if (GetOpenFileName(&ofn)) return 1; + + return 0; +} + +LRESULT CALLBACK LuaScriptProc(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam) +{ + RECT r; + RECT r2; + int dx1, dy1, dx2, dy2; + + switch(uMsg) + { + case WM_INITDIALOG: { + if(std::find(LuaScriptHWnds.begin(), LuaScriptHWnds.end(), hDlg) == LuaScriptHWnds.end()) + { + LuaScriptHWnds.push_back(hDlg); +// Build_Main_Menu(); + } +// if (Full_Screen) +// { +// while (ShowCursor(false) >= 0); +// while (ShowCursor(true) < 0); +// } + +// HANDLE hIcon = LoadIcon(GetModuleHandle(NULL), MAKEINTRESOURCE(IDI_LUA)); +// SendMessage(hDlg, WM_SETICON, ICON_BIG, (LPARAM)hIcon); + + // remove the 30000 character limit from the console control + SendMessage(GetDlgItem(hDlg, IDC_LUACONSOLE),EM_LIMITTEXT,0,0); + + GetWindowRect(MainWindow->getHWnd(), &r); + dx1 = (r.right - r.left) / 2; + dy1 = (r.bottom - r.top) / 2; + + GetWindowRect(hDlg, &r2); + dx2 = (r2.right - r2.left) / 2; + dy2 = (r2.bottom - r2.top) / 2; + + int windowIndex = std::find(LuaScriptHWnds.begin(), LuaScriptHWnds.end(), hDlg) - LuaScriptHWnds.begin(); + int staggerOffset = windowIndex * 24; + r.left += staggerOffset; + r.right += staggerOffset; + r.top += staggerOffset; + r.bottom += staggerOffset; + + // push it away from the main window if we can + const int width = (r.right-r.left); + const int width2 = (r2.right-r2.left); + if(r.left+width2 + width < GetSystemMetrics(SM_CXSCREEN)) + { + r.right += width; + r.left += width; + } + else if((int)r.left - (int)width2 > 0) + { + r.right -= width2; + r.left -= width2; + } + + SetWindowPos(hDlg, NULL, r.left, r.top, NULL, NULL, SWP_NOSIZE | SWP_NOZORDER | SWP_SHOWWINDOW); + + LuaPerWindowInfo info; + { + RECT r3; + GetClientRect(hDlg, &r3); + info.width = r3.right - r3.left; + info.height = r3.bottom - r3.top; + } + LuaWindowInfo[hDlg] = info; + RegisterWatcherThread(hDlg); + + OpenLuaContext((int)hDlg, PrintToWindowConsole, OnStart, OnStop); + + DragAcceptFiles(hDlg, TRUE); + + return true; + } break; + + case WM_MENUSELECT: + case WM_ENTERSIZEMOVE: +// Clear_Sound_Buffer(); + break; + + case WM_SIZING: + { + // enforce a minimum window size + + LPRECT r = (LPRECT) lParam; + int minimumWidth = 333; + int minimumHeight = 117; + if(r->right - r->left < minimumWidth) + if(wParam == WMSZ_LEFT || wParam == WMSZ_TOPLEFT || wParam == WMSZ_BOTTOMLEFT) + r->left = r->right - minimumWidth; + else + r->right = r->left + minimumWidth; + if(r->bottom - r->top < minimumHeight) + if(wParam == WMSZ_TOP || wParam == WMSZ_TOPLEFT || wParam == WMSZ_TOPRIGHT) + r->top = r->bottom - minimumHeight; + else + r->bottom = r->top + minimumHeight; + } + return TRUE; + + case WM_SIZE: + { + // resize or move controls in the window as necessary when the window is resized + + LuaPerWindowInfo& windowInfo = LuaWindowInfo[hDlg]; + int prevDlgWidth = windowInfo.width; + int prevDlgHeight = windowInfo.height; + + int dlgWidth = LOWORD(lParam); + int dlgHeight = HIWORD(lParam); + + int deltaWidth = dlgWidth - prevDlgWidth; + int deltaHeight = dlgHeight - prevDlgHeight; + + for(int i = 0; i < numControlLayoutInfos; i++) + { + ControlLayoutInfo layoutInfo = controlLayoutInfos[i]; + ControlLayoutState& layoutState = windowInfo.layoutState[i]; + + HWND hCtrl = GetDlgItem(hDlg,layoutInfo.controlID); + + int x,y,width,height; + if(layoutState.valid) + { + x = layoutState.x; + y = layoutState.y; + width = layoutState.width; + height = layoutState.height; + } + else + { + RECT r; + GetWindowRect(hCtrl, &r); + POINT p = {r.left, r.top}; + ScreenToClient(hDlg, &p); + x = p.x; + y = p.y; + width = r.right - r.left; + height = r.bottom - r.top; + } + + switch(layoutInfo.horizontalLayout) + { + case ControlLayoutInfo::RESIZE_END: width += deltaWidth; break; + case ControlLayoutInfo::MOVE_START: x += deltaWidth; break; + default: break; + } + switch(layoutInfo.verticalLayout) + { + case ControlLayoutInfo::RESIZE_END: height += deltaHeight; break; + case ControlLayoutInfo::MOVE_START: y += deltaHeight; break; + default: break; + } + + SetWindowPos(hCtrl, 0, x,y, width,height, 0); + + layoutState.x = x; + layoutState.y = y; + layoutState.width = width; + layoutState.height = height; + layoutState.valid = true; + } + + windowInfo.width = dlgWidth; + windowInfo.height = dlgHeight; + + RedrawWindow(hDlg, NULL, NULL, RDW_INVALIDATE); + } + break; + + case WM_COMMAND: + { + switch(LOWORD(wParam)) + { + case IDC_BUTTON_LUABROWSE: + { + LuaPerWindowInfo& info = LuaWindowInfo[hDlg]; + char Str_Tmp [1024]; // shadow added because the global one is unreliable + strcpy(Str_Tmp,info.filename.c_str()); + SendDlgItemMessage(hDlg,IDC_EDIT_LUAPATH,WM_GETTEXT,(WPARAM)512,(LPARAM)Str_Tmp); + char* bar = strchr(Str_Tmp, '|'); + if(bar) *bar = '\0'; +// DialogsOpen++; +// Clear_Sound_Buffer(); + if(Change_File_L(Str_Tmp, Lua_Dir, "Load Lua Script", "Lua Script\0*.lua*\0All Files\0*.*\0\0", "lua", hDlg)) + { + SendDlgItemMessage(hDlg,IDC_EDIT_LUAPATH,WM_SETTEXT,0,(LPARAM)Str_Tmp); + } +// DialogsOpen--; + + } break; + case IDC_BUTTON_LUAEDIT: + { + LuaPerWindowInfo& info = LuaWindowInfo[hDlg]; + char Str_Tmp [1024]; // shadow added because the global one is unreliable + strcpy(Str_Tmp,info.filename.c_str()); + SendDlgItemMessage(hDlg,IDC_EDIT_LUAPATH,WM_GETTEXT,(WPARAM)512,(LPARAM)Str_Tmp); + char LogicalName[1024], PhysicalName[1024]; + bool exists = ObtainFile(Str_Tmp, LogicalName, PhysicalName, "luaview", s_nonLuaExtensions, sizeof(s_nonLuaExtensions)/sizeof(*s_nonLuaExtensions)); + bool created = false; + if(!exists) + { + FILE* file = fopen(Str_Tmp, "r"); + if(!file) + { + file = fopen(Str_Tmp, "w"); + if(file) + { + created = true; + exists = true; + strcpy(PhysicalName, Str_Tmp); + } + } + if(file) + fclose(file); + } + if(exists) + { + // tell the OS to open the file with its associated editor, + // without blocking on it or leaving a command window open. + ShellExecute(NULL, "open", PhysicalName, NULL, NULL, SW_SHOWNORMAL); + } + if(created) + { + UpdateFileEntered(hDlg); + } + } break; + case IDC_EDIT_LUAPATH: + { + switch(HIWORD(wParam)) + { + case EN_CHANGE: + { + UpdateFileEntered(hDlg); + } break; + } + } break; + case IDC_BUTTON_LUARUN: + { + HWND focus = GetFocus(); + HWND textbox = GetDlgItem(hDlg, IDC_EDIT_LUAPATH); + if(focus != textbox) + SetActiveWindow(MainWindow->getHWnd()); + + LuaPerWindowInfo& info = LuaWindowInfo[hDlg]; + strcpy(Str_Tmp,info.filename.c_str()); + char LogicalName[1024], PhysicalName[1024]; + bool exists = ObtainFile(Str_Tmp, LogicalName, PhysicalName, "luarun", s_nonLuaExtensions, sizeof(s_nonLuaExtensions)/sizeof(*s_nonLuaExtensions)); + Update_Recent_Script(LogicalName, info.subservient); + RunLuaScriptFile((int)hDlg, PhysicalName); + } break; + case IDC_BUTTON_LUASTOP: + { + PrintToWindowConsole((int)hDlg, "user clicked stop button\r\n"); + SetActiveWindow(MainWindow->getHWnd()); + StopLuaScript((int)hDlg); + } break; + case IDC_NOTIFY_SUBSERVIENT: + { + LuaPerWindowInfo& info = LuaWindowInfo[hDlg]; + info.subservient = lParam ? true : false; + } break; + //case IDOK: + case IDCANCEL: + { LuaPerWindowInfo& info = LuaWindowInfo[hDlg]; + if(info.filename.empty()) + { +// if (Full_Screen) +// { +// while (ShowCursor(true) < 0); +// while (ShowCursor(false) >= 0); +// } +// DialogsOpen--; + DragAcceptFiles(hDlg, FALSE); + KillWatcherThread(hDlg); + LuaScriptHWnds.erase(remove(LuaScriptHWnds.begin(), LuaScriptHWnds.end(), hDlg), LuaScriptHWnds.end()); + LuaWindowInfo.erase(hDlg); + CloseLuaContext((int)hDlg); +// Build_Main_Menu(); + EndDialog(hDlg, true); + } + } return true; + } + + return false; + } break; + + case WM_CLOSE: + { + LuaPerWindowInfo& info = LuaWindowInfo[hDlg]; + + PrintToWindowConsole((int)hDlg, "user closed script window\r\n"); + StopLuaScript((int)hDlg); + if(info.started) + { + // not stopped yet, wait to close until we are, otherwise we'll crash + info.closeOnStop = true; + return false; + } + +// if (Full_Screen) +// { +// while (ShowCursor(true) < 0); +// while (ShowCursor(false) >= 0); +// } +// DialogsOpen--; + DragAcceptFiles(hDlg, FALSE); + KillWatcherThread(hDlg); + LuaScriptHWnds.erase(remove(LuaScriptHWnds.begin(), LuaScriptHWnds.end(), hDlg), LuaScriptHWnds.end()); + LuaWindowInfo.erase(hDlg); + CloseLuaContext((int)hDlg); +// Build_Main_Menu(); + EndDialog(hDlg, true); + } return true; + + case WM_DROPFILES: + { + HDROP hDrop = (HDROP)wParam; + DragQueryFile(hDrop, 0, Str_Tmp, 1024); + DragFinish(hDrop); + SendDlgItemMessage(hDlg,IDC_EDIT_LUAPATH,WM_SETTEXT,0,(LPARAM)Str_Tmp ); + UpdateFileEntered(hDlg); + } return true; + + } + + return false; +} + diff --git a/desmume/src/windows/main.cpp b/src/windows/main.cpp similarity index 82% rename from desmume/src/windows/main.cpp rename to src/windows/main.cpp index 618579404..f436e3c3f 100644 --- a/desmume/src/windows/main.cpp +++ b/src/windows/main.cpp @@ -1,25 +1,25 @@ -/* main.cpp +/* Copyright (C) 2006 yopyop +yopyop156@ifrance.com +yopyop156.ifrance.com - Copyright 2006 Theo Berkau - Copyright (C) 2006-2009 DeSmuME team +Copyright 2006 Theo Berkau - This file is part of DeSmuME +This file is part of DeSmuME - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. +DeSmuME is free software; you can redistribute it and/or modify +it under the terms of the GNU General Public License as published by +the Free Software Foundation; either version 2 of the License, or +(at your option) any later version. - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. +DeSmuME is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA +You should have received a copy of the GNU General Public License +along with DeSmuME; if not, write to the Free Software +Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ - #include "windriver.h" #include #include @@ -34,17 +34,18 @@ #include #include #include -#include "gthread.h" -#include "version.h" #include "CWindow.h" #include "../MMU.h" #include "../armcpu.h" #include "../NDSSystem.h" #include "../debug.h" #include "../saves.h" +#ifndef EXPERIMENTAL_GBASLOT +#include "../cflash.h" +#else #include "../addons.h" +#endif #include "resource.h" -#include "GPU_osd.h" #include "memView.h" #include "disView.h" #include "ginfo.h" @@ -79,18 +80,15 @@ #include "ramwatch.h" #include "ram_search.h" #include "aviout.h" +#include "wavout.h" #include "soundView.h" #include "commandline.h" #include "../lua-engine.h" #include "7zip.h" #include "pathsettings.h" #include "utils/xstring.h" -#include "directx/ddraw.h" -#include "video.h" -#include "path.h" -#include "aggdraw.h" -#include "agg2d.h" +#include "directx/ddraw.h" using namespace std; @@ -101,8 +99,6 @@ using namespace std; #include #include //uh? -VideoInfo video; - //#define WX_STUB #ifdef WX_STUB @@ -140,8 +136,13 @@ void wxTest() { #endif +#ifdef EXPERIMENTAL_GBASLOT static BOOL OpenCore(const char* filename); +#else +static BOOL OpenCore(const char * filename, const char *cflash_disk_image); +#endif +unsigned int lastSaveState = 0; //Keeps track of last savestate used for quick save/load functions //----Recent ROMs menu globals---------- vector RecentRoms; //The list of recent ROM filenames const unsigned int MAX_RECENT_ROMS = 10; //To change the recent rom max, simply change this number @@ -158,7 +159,6 @@ DWORD hKeyInputTimer; extern LRESULT CALLBACK RamSearchProc(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam); void InitRamSearch(); -void FilterUpdate(HWND hwnd, bool user=true); CRITICAL_SECTION win_sync; @@ -179,6 +179,12 @@ LPDIRECTDRAWCLIPPER lpDDClipBack=NULL; #define WM_CUSTKEYDOWN (WM_USER+50) #define WM_CUSTKEYUP (WM_USER+51) +#ifndef EXPERIMENTAL_GBASLOT +/* The compact flash disk image file */ +static const char *bad_glob_cflash_disk_image_file; +static char cflash_filename_buffer[512]; +#endif + /* Declare Windows procedure */ LRESULT CALLBACK WindowProcedure (HWND, UINT, WPARAM, LPARAM); @@ -201,6 +207,7 @@ RECT MainScreenSrcRect, SubScreenSrcRect; int WndX = 0; int WndY = 0; +int ScreenGap = 0; extern HWND RamSearchHWnd; static BOOL lostFocusPause = TRUE; static BOOL lastPauseFromLostFocus = FALSE; @@ -227,6 +234,8 @@ volatile BOOL paused = TRUE; volatile BOOL pausedByMinimize = FALSE; u32 glock = 0; +BOOL click = FALSE; + BOOL finished = FALSE; BOOL romloaded = FALSE; @@ -247,6 +256,7 @@ int sndvolume=100; SoundInterface_struct *SNDCoreList[] = { &SNDDummy, + &SNDFile, &SNDDIRECTX, NULL }; @@ -261,13 +271,132 @@ GPU3DInterface *core3DList[] = { int autoframeskipenab=0; int frameskiprate=0; int emu_paused = 0; +int backupmemorytype=MC_TYPE_AUTODETECT; +u32 backupmemorysize=1; bool frameAdvance = false; -bool staterewindingenabled = false; - +bool frameCounterDisplay = false; +bool FpsDisplay = false; +bool ShowLagFrameCounter = false; +bool ShowMicrophone = false; bool HudEditorMode = false; bool UseMicSample = false; unsigned short windowSize = 0; +struct HudCoordinates{ + int x; + int y; + int xsize; + int ysize; + int storedx; + int storedy; + int clicked; +}; + +struct HudStruct { + + HudCoordinates FpsDisplay; + HudCoordinates FrameCounter; + HudCoordinates InputDisplay; + HudCoordinates LagFrameCounter; + HudCoordinates Microphone; + HudCoordinates Dummy; + + HudCoordinates &hud(int i) { return ((HudCoordinates*)this)[i]; } +}; + +void SetHudDummy (HudCoordinates *hud) +{ + hud->x=666; + hud->y=666; +} + +bool IsHudDummy (HudCoordinates *hud) +{ + return (hud->x == 666 && hud->y == 666); +} + +HudStruct Hud; + +void EditHud(s32 x, s32 y, HudStruct *hudstruct) { + + UINT i = 0; + + while (!IsHudDummy(&hudstruct->hud(i))) { + HudCoordinates &hud = hudstruct->hud(i); + + //reset + if(!hud.clicked) { + hud.storedx=0; + hud.storedy=0; + } + + if((x >= hud.x && x <= hud.x + hud.xsize) && + (y >= hud.y && y <= hud.y + hud.ysize) && !hud.clicked ) { + + hud.clicked=1; + hud.storedx = x - hud.x; + hud.storedy = y - hud.y; + } + + if(hud.clicked) { + hud.x = x - hud.storedx; + hud.y = y - hud.storedy; + } + + //sanity checks + if(hud.x < 0) hud.x = 0; + if(hud.y < 0) hud.y = 0; + if(hud.x > 245)hud.x = 245; //margins + if(hud.y > 180)hud.y = 180; + + if(hud.clicked) + break;//prevent items from grouping together + + i++; + } +} + +void HudClickRelease(HudStruct *hudstruct) { + + UINT i = 0; + + while (!IsHudDummy(&hudstruct->hud(i))) { + HudCoordinates &hud = hudstruct->hud(i); + hud.clicked=0; + i++; + } +} + +void ResetHud(HudStruct *hudstruct) { + + hudstruct->FpsDisplay.x=0; + hudstruct->FpsDisplay.y=5; + hudstruct->FpsDisplay.xsize=120; + hudstruct->FpsDisplay.ysize=10; + + hudstruct->FrameCounter.x=0; + hudstruct->FrameCounter.y=25; + hudstruct->FrameCounter.xsize=60; + hudstruct->FrameCounter.ysize=10; + + hudstruct->InputDisplay.x=0; + hudstruct->InputDisplay.y=45; + hudstruct->InputDisplay.xsize=120; + hudstruct->InputDisplay.ysize=10; + + hudstruct->LagFrameCounter.x=0; + hudstruct->LagFrameCounter.y=65; + hudstruct->LagFrameCounter.xsize=30; + hudstruct->LagFrameCounter.ysize=10; + + hudstruct->Microphone.x=0; + hudstruct->Microphone.y=85; + hudstruct->Microphone.xsize=20; + hudstruct->Microphone.ysize=10; + + SetHudDummy(&hudstruct->Dummy); +} + /* the firmware settings */ struct NDS_fw_config_data win_fw_config; @@ -386,28 +515,127 @@ VOID CALLBACK KeyInputTimer( UINT idEvent, UINT uMsg, DWORD_PTR dwUser, DWORD_PT // } } +//static void +//init_configured_features( struct configured_features *config) { +// config->arm9_gdb_port = 0; +// config->arm7_gdb_port = 0; +// +// config->cflash_disk_image_file = NULL; +//} +// +// +//static int +//fill_configured_features( struct configured_features *config, LPSTR lpszArgument) { +// int good_args = 0; +// LPTSTR cmd_line; +// LPWSTR *argv; +// int argc; +// +// argv = CommandLineToArgvW( GetCommandLineW(), &argc); +// +// if ( argv != NULL) { +// int i; +// good_args = 1; +// for ( i = 1; i < argc && good_args; i++) { +// if ( wcsncmp( argv[i], L"--arm9gdb=", 10) == 0) { +// wchar_t *end_char; +// unsigned long port_num = wcstoul( &argv[i][10], &end_char, 10); +// +// if ( port_num > 0 && port_num < 65536) { +// config->arm9_gdb_port = port_num; +// } +// else { +// MessageBox(NULL,"ARM9 GDB stub port must be in the range 1 to 65535","Error",MB_OK); +// good_args = 0; +// } +// } +// else if ( wcsncmp( argv[i], L"--arm7gdb=", 10) == 0) { +// wchar_t *end_char; +// unsigned long port_num = wcstoul( &argv[i][10], &end_char, 10); +// +// if ( port_num > 0 && port_num < 65536) { +// config->arm7_gdb_port = port_num; +// } +// else { +// MessageBox(NULL,"ARM9 GDB stub port must be in the range 1 to 65535","Error",MB_OK); +// good_args = 0; +// } +// } +// +//#ifdef EXPERIMENTAL_GBASLOT +// else if ( wcsncmp( argv[i], L"--cflash=", 9) == 0) +// { +// char buf[512]; +// size_t convert_count = wcstombs(&buf[0], &argv[i][9], 512); +// if (convert_count > 0) +// { +// addon_type = NDS_ADDON_CFLASH; +// CFlashUsePath = FALSE; +// strcpy(CFlashName, buf); +// } +// } +// else if ( wcsncmp( argv[i], L"--gbagame=", 10) == 0) +// { +// char buf[512]; +// size_t convert_count = wcstombs(&buf[0], &argv[i][9], 512); +// if (convert_count > 0) +// { +// addon_type = NDS_ADDON_GBAGAME; +// strcpy(GBAgameName, buf); +// } +// } +// else if ( wcsncmp( argv[i], L"--rumble", 8) == 0) +// { +// addon_type = NDS_ADDON_RUMBLEPAK; +// } +//#else +// else if ( wcsncmp( argv[i], L"--cflash=", 9) == 0) { +// if ( config->cflash_disk_image_file == NULL) { +// size_t convert_count = wcstombs( &cflash_filename_buffer[0], &argv[i][9], 512); +// if ( convert_count > 0) { +// config->cflash_disk_image_file = cflash_filename_buffer; +// } +// } +// else { +// MessageBox(NULL,"CFlash disk image file already set","Error",MB_OK); +// good_args = 0; +// } +// } +//#endif +// } +// LocalFree( argv); +// } +// +// return good_args; +//} + +// Rotation definitions +short GPU_rotation = 0; +DWORD GPU_width = 256; +DWORD GPU_height = 192*2; +DWORD rotationstartscan = 192; +DWORD rotationscanlines = 192*2; + void ScaleScreen(float factor) { - if(windowSize == 0) + if(factor==65535) + factor = 1.5f; + else if(factor==65534) + factor = 2.5f; + if((GPU_rotation == 90) || (GPU_rotation == 270)) { - int w = GetPrivateProfileInt("Video", "Window width", 256, IniName); - int h = GetPrivateProfileInt("Video", "Window height", 384, IniName); - MainWindow->setClientSize(w, h); + MainWindow->setClientSize(((384 + ScreenGap) * factor), (256 * factor)); } else { - if(factor==65535) - factor = 1.5f; - else if(factor==65534) - factor = 2.5f; - MainWindow->setClientSize((int)(video.rotatedwidthgap() * factor), (int)(video.rotatedheightgap() * factor)); + MainWindow->setClientSize((256 * factor), ((384 + ScreenGap) * factor)); } } void translateXY(s32& x, s32& y) { s32 tx=x, ty=y; - switch(video.rotation) + switch(GPU_rotation) { case 90: x = ty; @@ -420,10 +648,10 @@ void translateXY(s32& x, s32& y) break; case 270: x = 255-ty; - y = (tx-192-(video.screengap/video.ratio())); + y = (tx-192-ScreenGap); break; } -} +} // END Rotation definitions void UpdateRecentRomsMenu() @@ -637,8 +865,17 @@ int CreateDDrawBuffers() ddsd.dwFlags = DDSD_CAPS | DDSD_HEIGHT | DDSD_WIDTH; ddsd.ddsCaps.dwCaps = DDSCAPS_OFFSCREENPLAIN; - ddsd.dwWidth = video.rotatedwidth(); - ddsd.dwHeight = video.rotatedheight(); + if ( (GPU_rotation == 0) || (GPU_rotation == 180) ) + { + ddsd.dwWidth = 256; + ddsd.dwHeight = 384; + } + else + if ( (GPU_rotation == 90) || (GPU_rotation == 270) ) + { + ddsd.dwWidth = 384; + ddsd.dwHeight = 256; + } if (IDirectDraw7_CreateSurface(lpDDraw, &ddsd, &lpBackSurface, NULL) != DD_OK) return -2; @@ -650,84 +887,7 @@ int CreateDDrawBuffers() return 1; } -template static T convert(u16 val) -{ - switch(bpp) - { - case 24: case 32: - return RGB15TO24_REVERSE(val); - case 16: return RGB15TO16_REVERSE(val); - default: - return 0; - } -} - -template static void doRotate(void* dst) -{ - u8* buffer = (u8*)dst; - int size = video.size(); - u16* src = video.finalBuffer(); - switch(video.rotation) - { - case 0: - case 180: - { - if(ddsd.lPitch == 1024) - { - if(video.rotation==180) - for(int i = 0, j=size-1; j>=0; i++,j--) - ((T*)buffer)[i] = convert((src)[j]); - else - for(int i = 0; i < size; i++) - ((T*)buffer)[i] = convert(src[i]); - } - else - { - if(video.rotation==180) - for(int y = 0; y < video.height; y++) - { - for(int x = 0; x < video.width; x++) - ((T*)buffer)[x] = convert(src[video.height*video.width - (y * video.width) - x - 1]); - - buffer += ddsd.lPitch; - } - else - for(int y = 0; y < video.height; y++) - { - for(int x = 0; x < video.width; x++) - ((T*)buffer)[x] = convert(src[(y * video.width) + x]); - - buffer += ddsd.lPitch; - } - } - } - break; - case 90: - case 270: - { - if(video.rotation == 90) - for(int y = 0; y < video.width; y++) - { - for(int x = 0; x < video.height; x++) - ((T*)buffer)[x] = convert(src[(((video.height-1)-x) * video.width) + y]); - - buffer += ddsd.lPitch; - } - else - for(int y = 0; y < video.width; y++) - { - for(int x = 0; x < video.height; x++) - ((T*)buffer)[x] = convert(src[((x) * video.width) + (video.width-1) - y]); - - buffer += ddsd.lPitch; - } - } - break; - } -} - -//the directdraw final presentation portion of display, including rotating -static void DD_DoDisplay() +void Display() { int res; memset(&ddsd, 0, sizeof(ddsd)); @@ -735,156 +895,166 @@ static void DD_DoDisplay() ddsd.dwFlags=DDSD_ALL; res = lpBackSurface->Lock(NULL, &ddsd, DDLOCK_WAIT, NULL); - if (res==DDERR_SURFACELOST) + if (res == DD_OK) { - LOG("DirectDraw buffers is lost\n"); - if (IDirectDrawSurface7_Restore(lpPrimarySurface)==DD_OK) - IDirectDrawSurface7_Restore(lpBackSurface); - } else if(res != DD_OK) - return; + char* buffer = (char*)ddsd.lpSurface; - char* buffer = (char*)ddsd.lpSurface; - - switch(ddsd.ddpfPixelFormat.dwRGBBitCount) - { - case 32: doRotate(ddsd.lpSurface); break; - case 24: doRotate(ddsd.lpSurface); break; - case 16: doRotate(ddsd.lpSurface); break; - default: + int i, j, sz=256*sizeof(u32); + switch(ddsd.ddpfPixelFormat.dwRGBBitCount) { - INFO("Unsupported color depth: %i bpp\n", ddsd.ddpfPixelFormat.dwRGBBitCount); - emu_halt(); + case 24: + case 32: + { + switch(GPU_rotation) + { + case 0: + case 180: + { + if(ddsd.lPitch == 1024) + { + for(int i = 0; i < 98304; i++) + ((u32*)buffer)[i] = RGB15TO24_REVERSE(((u16*)GPU_screen)[i]); + } + else + { + for(int y = 0; y < 384; y++) + { + for(int x = 0; x < 256; x++) + ((u32*)buffer)[x] = RGB15TO24_REVERSE(((u16*)GPU_screen)[(y * 384) + x]); + + buffer += ddsd.lPitch; + } + } + } + break; + case 90: + case 270: + { + if(ddsd.lPitch == 1536) + { + for(int i = 0; i < 98304; i++) + ((u32*)buffer)[i] = RGB15TO24_REVERSE(((u16*)GPU_screen)[i]); + } + else + { + for(int y = 0; y < 256; y++) + { + for(int x = 0; x < 384; x++) + ((u32*)buffer)[x] = RGB15TO24_REVERSE(((u16*)GPU_screen)[(y * 256) + x]); + + buffer += ddsd.lPitch; + } + } + } + break; + } + } + break; + + case 16: + { + switch(GPU_rotation) + { + case 0: + case 180: + { + if(ddsd.lPitch == 512) + { + for(int i = 0; i < 98304; i++) + ((u16*)buffer)[i] = RGB15TO16_REVERSE(((u16*)GPU_screen)[i]); + } + else + { + for(int y = 0; y < 384; y++) + { + for(int x = 0; x < 256; x++) + ((u16*)buffer)[x] = RGB15TO16_REVERSE(((u16*)GPU_screen)[(y * 384) + x]); + + buffer += ddsd.lPitch; + } + } + } + break; + case 90: + case 270: + { + if(ddsd.lPitch == 768) + { + for(int i = 0; i < 98304; i++) + ((u16*)buffer)[i] = RGB15TO16_REVERSE(((u16*)GPU_screen)[i]); + } + else + { + for(int y = 0; y < 256; y++) + { + for(int x = 0; x < 384; x++) + ((u16*)buffer)[x] = RGB15TO16_REVERSE(((u16*)GPU_screen)[(y * 256) + x]); + + buffer += ddsd.lPitch; + } + } + } + break; + } + } + break; + + default: + { + INFO("Unsupported color depth: %i bpp\n", ddsd.ddpfPixelFormat.dwRGBBitCount); + emu_halt(); + } + break; + } + + lpBackSurface->Unlock((LPRECT)ddsd.lpSurface); + + // Main screen + if(lpPrimarySurface->Blt(&MainScreenRect, lpBackSurface, &MainScreenSrcRect, DDBLT_WAIT, 0) == DDERR_SURFACELOST) + { + LOG("DirectDraw buffers is lost\n"); + if(IDirectDrawSurface7_Restore(lpPrimarySurface) == DD_OK) + IDirectDrawSurface7_Restore(lpBackSurface); + } + + // Sub screen + if(lpPrimarySurface->Blt(&SubScreenRect, lpBackSurface, &SubScreenSrcRect, DDBLT_WAIT, 0) == DDERR_SURFACELOST) + { + LOG("DirectDraw buffers is lost\n"); + if(IDirectDrawSurface7_Restore(lpPrimarySurface) == DD_OK) + IDirectDrawSurface7_Restore(lpBackSurface); + } + + // Gap + if(ScreenGap > 0) + { + //u32 color = gapColors[win_fw_config.fav_colour]; + //u32 color_rev = (((color & 0xFF) << 16) | (color & 0xFF00) | ((color & 0xFF0000) >> 16)); + u32 color_rev = 0xFFFFFF; + + HDC dc; + HBRUSH brush; + + dc = GetDC(MainWindow->getHWnd()); + brush = CreateSolidBrush(color_rev); + + FillRect(dc, &GapRect, brush); + + DeleteObject((HGDIOBJ)brush); + ReleaseDC(MainWindow->getHWnd(), dc); } - break; } - - - lpBackSurface->Unlock((LPRECT)ddsd.lpSurface); - - // Main screen - if(lpPrimarySurface->Blt(&MainScreenRect, lpBackSurface, &MainScreenSrcRect, DDBLT_WAIT, 0) == DDERR_SURFACELOST) + else { - LOG("DirectDraw buffers is lost\n"); - if(IDirectDrawSurface7_Restore(lpPrimarySurface) == DD_OK) - IDirectDrawSurface7_Restore(lpBackSurface); - } - - // Sub screen - if(lpPrimarySurface->Blt(&SubScreenRect, lpBackSurface, &SubScreenSrcRect, DDBLT_WAIT, 0) == DDERR_SURFACELOST) - { - LOG("DirectDraw buffers is lost\n"); - if(IDirectDrawSurface7_Restore(lpPrimarySurface) == DD_OK) - IDirectDrawSurface7_Restore(lpBackSurface); - } - - // Gap - if(video.screengap > 0) - { - //u32 color = gapColors[win_fw_config.fav_colour]; - //u32 color_rev = (((color & 0xFF) << 16) | (color & 0xFF00) | ((color & 0xFF0000) >> 16)); - u32 color_rev = 0xFFFFFF; - - HDC dc; - HBRUSH brush; - - dc = GetDC(MainWindow->getHWnd()); - brush = CreateSolidBrush(color_rev); - - FillRect(dc, &GapRect, brush); - - DeleteObject((HGDIOBJ)brush); - ReleaseDC(MainWindow->getHWnd(), dc); + if (res==DDERR_SURFACELOST) + { + LOG("DirectDraw buffers is lost\n"); + if (IDirectDrawSurface7_Restore(lpPrimarySurface)==DD_OK) + IDirectDrawSurface7_Restore(lpBackSurface); + } } } -//tripple buffering logic -u16 displayBuffers[3][256*192*4]; -int currDisplayBuffer=-1; -int newestDisplayBuffer=-2; -GMutex *display_mutex = NULL; -GThread *display_thread = NULL; - -//does a single display work unit. only to be used from the display thread -static void DoDisplay() -{ - osd->update(); - DrawHUD(); - video.filter(); - DD_DoDisplay(); - osd->clear(); -} - -void displayProc() -{ - g_mutex_lock(display_mutex); - - //find a buffer to display - int todo = newestDisplayBuffer; - bool alreadyDisplayed = (todo == currDisplayBuffer); - - g_mutex_unlock(display_mutex); - - //nothing to display. give up. - if(alreadyDisplayed) return; - - //start displaying a new buffer - currDisplayBuffer = todo; - - video.srcBuffer = (u8*)displayBuffers[currDisplayBuffer]; - - aggDraw.hud->attach(video.srcBuffer, 256, 384, 512); - - DoDisplay(); -} - - -void displayThread(void*) -{ - for(;;) { - displayProc(); - Sleep(10); //don't be greedy and use a whole cpu core, but leave room for 60fps - } -} - -void Display() -{ - if(display_thread == NULL) - { - display_mutex = g_mutex_new(); - display_thread = g_thread_create( (GThreadFunc)displayThread, - NULL, - TRUE, - NULL); - } - - g_mutex_lock(display_mutex); - - //huh... i wonder if there is a less ugly way to do this - if(currDisplayBuffer == 0) - if(newestDisplayBuffer == 1) - newestDisplayBuffer = 2; - else newestDisplayBuffer = 1; - else if(currDisplayBuffer == 1) - if(newestDisplayBuffer == 2) - newestDisplayBuffer = 0; - else newestDisplayBuffer = 2; - else //if(currDisplayBuffer == 1) - if(newestDisplayBuffer == 0) - newestDisplayBuffer = 1; - else newestDisplayBuffer = 0; - - memcpy(displayBuffers[newestDisplayBuffer],GPU_screen,256*192*4); - - g_mutex_unlock(display_mutex); - - //the no-multithreading codepath - //but based on my research, this runs just fine on a single core system due to the generous - //sleep in the display loop - //video.srcBuffer = (u8*)GPU_screen; - //doDisplay(); -} - - void CheckMessages() { MSG msg; @@ -941,7 +1111,7 @@ DWORD WINAPI run() InitSpeedThrottle(); - osd->setRotate(video.rotation); + osd->setRotate(GPU_rotation); if (DirectDrawCreateEx(NULL, (LPVOID*)&lpDDraw, IID_IDirectDraw7, NULL) != DD_OK) { @@ -973,33 +1143,50 @@ DWORD WINAPI run() CallRegisteredLuaFunctions(LUACALL_BEFOREEMULATION); FCEUMOV_AddInputState(); + if (ShowInputDisplay) osd->addFixed(Hud.InputDisplay.x, Hud.InputDisplay.y, "%s",InputDisplayString.c_str()); + { Lock lock; - NDS_exec(); + NDS_exec(0); win_sound_samplecounter = 735; } DRV_AviVideoUpdate((u16*)GPU_screen); +#if !(defined(WIN32) && defined(G_NEW_SPU_TIMING)) + SPU_Emulate_core(); - extern void rewindsave(); - extern bool rewinding; - extern void dorewind(); + //avi writing + DRV_AviSoundUpdate(SPU_core->outbuf,spu_core_samples); + //wav writing + DRV_WavSoundUpdate(SPU_core->outbuf,spu_core_samples); +#endif + //we are driving the dsound output from another thread + //but there is no thread for the filewriter. so we need to do it here + if(sndcoretype == SNDCORE_FILEWRITE) + SPU_Emulate_user(); - if (staterewindingenabled) { - - if(rewinding) - dorewind(); - else - rewindsave(); - } + // if (!skipnextframe) + // { CallRegisteredLuaFunctions(LUACALL_AFTEREMULATION); static int fps3d = 0; - Hud.fps = fps; - Hud.fps3d = fps3d; + if (FpsDisplay) osd->addFixed(Hud.FpsDisplay.x, Hud.FpsDisplay.y, "Fps:%02d/%02d", fps, fps3d); + if (frameCounterDisplay) + { + if (movieMode == MOVIEMODE_PLAY) + osd->addFixed(Hud.FrameCounter.x, Hud.FrameCounter.y, "%d/%d",currFrameCounter,currMovieData.records.size()); + else if(movieMode == MOVIEMODE_RECORD) + osd->addFixed(Hud.FrameCounter.x, Hud.FrameCounter.y, "%d",currFrameCounter); + else + osd->addFixed(Hud.FrameCounter.x, Hud.FrameCounter.y, "%d (no movie)",currFrameCounter); + } + if (ShowLagFrameCounter) osd->addFixed(Hud.LagFrameCounter.x, Hud.LagFrameCounter.y, "%d",TotalLagFrames); + if (ShowMicrophone) osd->addFixed(Hud.Microphone.x, Hud.Microphone.y, "%d",MicDisplay); + if(!DRV_AviIsRecording()) osd->update(); Display(); + osd->clear(); gfx3d.frameCtrRaw++; if(gfx3d.frameCtrRaw == 60) { @@ -1042,12 +1229,13 @@ DWORD WINAPI run() for(int i=0;i<16;i++) load = load/8 + nds.runCycleCollector[(i+nds.idleFrameCounter)&15]*7/8; load = std::min(100,std::max(0,(int)(load*100/1120380))); - //sprintf(txt,"(%02d%%) %s", load, DESMUME_NAME_AND_VERSION); - SetWindowText(hwnd, DESMUME_NAME_AND_VERSION); + sprintf(txt,"(%02d%%) %s", load, DESMUME_NAME_AND_VERSION); + SetWindowText(hwnd, txt); } if(!skipnextframe) { + framesskipped = 0; if (framestoskip > 0) @@ -1117,7 +1305,6 @@ DWORD WINAPI run() } // DisplayMessage(); CheckMessages(); - } paused = TRUE; @@ -1212,19 +1399,33 @@ void LoadSaveStateInfo() } } + + +#ifdef EXPERIMENTAL_GBASLOT static BOOL LoadROM(const char * filename, const char * logicalName) +#else +static BOOL LoadROM(const char * filename, const char * logicalName, const char *cflash_disk_image) +#endif { ResetSaveStateTimes(); NDS_Pause(); //if (strcmp(filename,"")!=0) INFO("Attempting to load ROM: %s\n",filename); - if (NDS_LoadROM(filename, logicalName) > 0) + //extract the internal part of the logical rom name + std::vector parts = tokenize_str(logicalName,"|"); + SetRomName(parts[parts.size()-1].c_str()); + +#ifdef EXPERIMENTAL_GBASLOT + if (NDS_LoadROM(filename, backupmemorytype, backupmemorysize) > 0, logicalName) +#else + if (NDS_LoadROM(filename, backupmemorytype, backupmemorysize, cflash_disk_image) > 0, logicalName) +#endif { INFO("Loading %s was successful\n",logicalName); LoadSaveStateInfo(); lagframecounter=0; UpdateRecentRoms(logicalName); - osd->setRotate(video.rotation); + osd->setRotate(GPU_rotation); if (AutoRWLoad) { //Open Ram Watch if its auto-load setting is checked @@ -1325,7 +1526,7 @@ void SaveLanguage(int langid) void CheckLanguage(UINT id) { int i; - for (i = IDC_LANGENGLISH; i < IDC_LANG_CHINESE_SIMPLIFIED+1; i++) + for (i = IDC_LANGENGLISH; i < IDC_LANGDANISH+1; i++) MainWindow->checkMenu(i, MF_BYCOMMAND | MF_UNCHECKED); MainWindow->checkMenu(id, MF_BYCOMMAND | MF_CHECKED); @@ -1363,6 +1564,8 @@ static void ExitRunLoop() emu_halt(); } +BOOL AVI_IsRecording(); +BOOL WAV_IsRecording(); class WinDriver : public BaseDriver { virtual bool WIFI_Host_InitSystem() { @@ -1376,7 +1579,7 @@ class WinDriver : public BaseDriver FreeLibrary(temp); return true; #else - return false ; + return false; #endif } virtual void WIFI_Host_ShutdownSystem() { @@ -1394,25 +1597,14 @@ class WinDriver : public BaseDriver virtual void USR_InfoMessage(const char *message) { - LOG("%s\n", message); + LOG("%s\n", message); osd->addLine(message); } - - virtual void AVI_SoundUpdate(void* soundData, int soundLen) { - ::DRV_AviSoundUpdate(soundData, soundLen); - } }; -std::string GetPrivateProfileStdString(LPCSTR lpAppName,LPCSTR lpKeyName,LPCSTR lpDefault) -{ - static char buf[65536]; - GetPrivateProfileString(lpAppName, lpKeyName, lpDefault, buf, 65536, IniName); - return buf; -} int _main() { - Desmume_InitOnce(); InitDecoder(); #ifdef WX_STUB @@ -1440,29 +1632,39 @@ int _main() char text[80]; GetINIPath(); - +#ifdef EXPERIMENTAL_GBASLOT addon_type = GetPrivateProfileInt("GBAslot", "type", NDS_ADDON_NONE, IniName); - UINT CFlashFileMode = GetPrivateProfileInt("GBAslot.CFlash", "fileMode", 2, IniName); - - CFlashPath = GetPrivateProfileStdString("GBAslot.CFlash", "path", ""); - CFlashName = GetPrivateProfileStdString("GBAslot.CFlash", "filename", ""); + CFlashUsePath = GetPrivateProfileInt("GBAslot.CFlash", "usePath", 1, IniName); + CFlashUseRomPath = GetPrivateProfileInt("GBAslot.CFlash", "useRomPath", 1, IniName); + GetPrivateProfileString("GBAslot.CFlash", "path", "", CFlashPath, MAX_PATH, IniName); + GetPrivateProfileString("GBAslot.CFlash", "filename", "", CFlashName, MAX_PATH, IniName); GetPrivateProfileString("GBAslot.GBAgame", "filename", "", GBAgameName, MAX_PATH, IniName); - if(CFlashFileMode==ADDON_CFLASH_MODE_Path) + switch (addon_type) { - CFlash_Mode = ADDON_CFLASH_MODE_Path; - } - else - if(CFlashFileMode==ADDON_CFLASH_MODE_File) + case NDS_ADDON_NONE: + break; + case NDS_ADDON_CFLASH: + if (!strlen(CFlashPath)) CFlashUseRomPath = TRUE; + if (!strlen(CFlashName)) CFlashUsePath = TRUE; + // TODO: check for file exist + break; + case NDS_ADDON_RUMBLEPAK: + break; + case NDS_ADDON_GBAGAME: + if (!strlen(GBAgameName)) { - CFlash_Path = CFlashName; - CFlash_Mode = ADDON_CFLASH_MODE_File; + addon_type = NDS_ADDON_NONE; + break; } - else - { - CFlash_Path = ""; - CFlash_Mode = ADDON_CFLASH_MODE_RomPath; - } + // TODO: check for file exist + break; + default: + addon_type = NDS_ADDON_NONE; + break; + } + addonsChangePak(addon_type); +#endif //init_configured_features( &my_config); /*if ( !fill_configured_features( &my_config, lpszArgument)) { @@ -1478,20 +1680,16 @@ int _main() } windowSize = GetPrivateProfileInt("Video","Window Size", 0, IniName); - video.rotation = GetPrivateProfileInt("Video","Window Rotate", 0, IniName); + GPU_rotation = GetPrivateProfileInt("Video","Window Rotate", 0, IniName); ForceRatio = GetPrivateProfileInt("Video","Window Force Ratio", 1, IniName); + FpsDisplay = GetPrivateProfileInt("Display","Display Fps", 0, IniName); WndX = GetPrivateProfileInt("Video","WindowPosX", CW_USEDEFAULT, IniName); WndY = GetPrivateProfileInt("Video","WindowPosY", CW_USEDEFAULT, IniName); - video.width = GetPrivateProfileInt("Video", "Width", 256, IniName); - video.height = GetPrivateProfileInt("Video", "Height", 384, IniName); - - CommonSettings.hud.FpsDisplay = GetPrivateProfileBool("Display","Display Fps", 0, IniName); - CommonSettings.hud.FrameCounterDisplay = GetPrivateProfileBool("Display","FrameCounter", 0, IniName); - CommonSettings.hud.ShowInputDisplay = GetPrivateProfileBool("Display","Display Input", 0, IniName); - CommonSettings.hud.ShowLagFrameCounter = GetPrivateProfileBool("Display","Display Lag Counter", 0, IniName); - CommonSettings.hud.ShowMicrophone = GetPrivateProfileBool("Display","Display Microphone", 0, IniName); - - video.screengap = GetPrivateProfileInt("Display", "ScreenGap", 0, IniName); + frameCounterDisplay = GetPrivateProfileInt("Display","FrameCounter", 0, IniName); + ShowInputDisplay = GetPrivateProfileInt("Display","Display Input", 0, IniName); + ShowLagFrameCounter = GetPrivateProfileInt("Display","Display Lag Counter", 0, IniName); + ShowMicrophone = GetPrivateProfileInt("Display","Display Microphone", 0, IniName); + ScreenGap = GetPrivateProfileInt("Display", "ScreenGap", 0, IniName); FrameLimit = GetPrivateProfileInt("FrameLimit", "FrameLimit", 1, IniName); CommonSettings.showGpu.main = GetPrivateProfileInt("Display", "MainGpu", 1, IniName) != 0; CommonSettings.showGpu.sub = GetPrivateProfileInt("Display", "SubGpu", 1, IniName) != 0; @@ -1518,13 +1716,10 @@ int _main() return 1; } - if(cmdline.single_core) - SetProcessAffinityMask(GetCurrentProcess(),1); - //sprintf(text, "%s", DESMUME_NAME_AND_VERSION); MainWindow = new WINCLASS(CLASSNAME, hAppInst); DWORD dwStyle = WS_CAPTION| WS_SYSMENU | WS_SIZEBOX | WS_MINIMIZEBOX | WS_CLIPCHILDREN | WS_CLIPSIBLINGS; - if (!MainWindow->create(DESMUME_NAME_AND_VERSION, WndX/*CW_USEDEFAULT*/, WndY/*CW_USEDEFAULT*/, video.width,video.height+video.screengap, + if (!MainWindow->create(DESMUME_NAME_AND_VERSION, WndX/*CW_USEDEFAULT*/, WndY/*CW_USEDEFAULT*/, 256,384+ScreenGap, WS_CAPTION| WS_SYSMENU | WS_SIZEBOX | WS_MINIMIZEBOX | WS_CLIPCHILDREN | WS_CLIPSIBLINGS, NULL)) { @@ -1533,7 +1728,7 @@ int _main() exit(-1); } - gpu_SetRotateScreen(video.rotation); + gpu_SetRotateScreen(GPU_rotation); /* default the firmware settings, they may get changed later */ NDS_FillDefaultFirmwareConfigData( &win_fw_config); @@ -1541,8 +1736,14 @@ int _main() GetPrivateProfileString("General", "Language", "0", text, 80, IniName); SetLanguage(atoi(text)); +#ifndef EXPERIMENTAL_GBASLOT + bad_glob_cflash_disk_image_file = my_config.cflash_disk_image_file; +#endif + //hAccel = LoadAccelerators(hAppInst, MAKEINTRESOURCE(IDR_MAIN_ACCEL)); //Now that we have a hotkey system we down need the Accel table. Not deleting just yet though + + if(MenuInit() == 0) { MessageBox(NULL, "Error creating main menu", "DeSmuME", MB_OK); @@ -1550,12 +1751,34 @@ int _main() exit(-1); } - MainWindow->setMinSize(video.rotatedwidthgap(), video.rotatedheightgap()); + if((GPU_rotation == 90) || (GPU_rotation == 270)) + { + MainWindow->setMinSize(384+ScreenGap, 256); + } + else + { + MainWindow->setMinSize(256, 384+ScreenGap); + } - ScaleScreen(windowSize); + { + if(windowSize == 0) + { + int w = GetPrivateProfileInt("Video", "Window width", 256, IniName); + int h = GetPrivateProfileInt("Video", "Window height", 384, IniName); + MainWindow->setClientSize(w, h); + } + else + { + ScaleScreen(windowSize); + } + } DragAcceptFiles(MainWindow->getHWnd(), TRUE); +#ifndef EXPERIMENTAL_GBASLOT + EnableMenuItem(mainMenu, IDM_GBASLOT, MF_GRAYED); +#endif + #ifdef EXPERIMENTAL_WIFI EnableMenuItem(mainMenu, IDM_WIFISETTINGS, MF_ENABLED); #endif @@ -1567,8 +1790,6 @@ int _main() void input_init(); input_init(); - if (addon_type == NDS_ADDON_GUITARGRIP) Guitar.Enabled = true; - LOG("Init NDS\n"); GInfo_Init(); @@ -1588,43 +1809,6 @@ int _main() ViewMatrices = new TOOLSCLASS(hAppInst, IDD_MATRIX_VIEWER, (DLGPROC) ViewMatricesProc); ViewLights = new TOOLSCLASS(hAppInst, IDD_LIGHT_VIEWER, (DLGPROC) ViewLightsProc); - - cmdline.process_addonCommands(); - if(cmdline.is_cflash_configured) - { - addon_type = NDS_ADDON_CFLASH; - //push the commandline-provided options into the current config slots - if(CFlash_Mode == ADDON_CFLASH_MODE_Path) - CFlashPath = CFlash_Path; - else - CFlashName = CFlash_Path; - } - - - switch (addon_type) - { - case NDS_ADDON_NONE: - break; - case NDS_ADDON_CFLASH: - break; - case NDS_ADDON_RUMBLEPAK: - break; - case NDS_ADDON_GBAGAME: - if (!strlen(GBAgameName)) - { - addon_type = NDS_ADDON_NONE; - break; - } - // TODO: check for file exist - break; - case NDS_ADDON_GUITARGRIP: - break; - default: - addon_type = NDS_ADDON_NONE; - break; - } - addonsChangePak(addon_type); - #ifdef GDB_STUB if ( cmdline.arm9_gdb_port != 0) { arm9_gdb_stub = createStub_gdb( cmdline.arm9_gdb_port, @@ -1696,7 +1880,7 @@ int _main() EnableMenuItem (mainMenu, IDM_SUBMITBUGREPORT, MF_GRAYED); #endif LOG("Init sound core\n"); - sndcoretype = GetPrivateProfileInt("Sound","SoundCore2", SNDCORE_DIRECTX, IniName); + sndcoretype = GetPrivateProfileInt("Sound","SoundCore", SNDCORE_DIRECTX, IniName); sndbuffersize = GetPrivateProfileInt("Sound","SoundBufferSize", 735 * 4, IniName); CommonSettings.spuInterpolationMode = (SPUInterpolationMode)GetPrivateProfileInt("Sound","SPUInterpolation", 1, IniName); CommonSettings.spuAdpcmCache = GetPrivateProfileInt("Sound","SPUAdpcmCache",0,IniName)!=0; @@ -1725,9 +1909,6 @@ int _main() CommonSettings.wifiBridgeAdapterNum = GetPrivateProfileInt("Wifi", "BridgeAdapter", 0, IniName); - video.currentfilter = GetPrivateProfileInt("Video", "Filter", video.NONE, IniName); - FilterUpdate(MainWindow->getHWnd(),false); - /* Read the firmware settings from the init file */ win_fw_config.fav_colour = GetPrivateProfileInt("Firmware","favColor", 10, IniName); win_fw_config.birth_month = GetPrivateProfileInt("Firmware","bMonth", 7, IniName); @@ -1766,15 +1947,25 @@ int _main() if (cmdline.nds_file != "") { +#ifdef EXPERIMENTAL_GBASLOT if(OpenCore(cmdline.nds_file.c_str())) +#else + if(OpenCore(cmdline.nds_file.c_str(), bad_glob_cflash_disk_image_file)) +#endif { romloaded = TRUE; - if(!cmdline.start_paused) - NDS_UnPause(); + NDS_UnPause(); } } - cmdline.process_movieCommands(); + if(cmdline.play_movie_file != "") + { + FCEUI_LoadMovie(cmdline.play_movie_file.c_str(),true,false,-1); + } + else if(cmdline.record_movie_file != "") + { + FCEUI_SaveMovie(cmdline.record_movie_file.c_str(), L""); + } if(cmdline.load_slot != 0) { @@ -1786,7 +1977,7 @@ int _main() SaveRecentRoms(); NDS_DeInit(); DRV_AviEnd(); - WAV_End(); + DRV_WavEnd(); //------SHUTDOWN @@ -1829,14 +2020,13 @@ int WINAPI WinMain (HINSTANCE hThisInstance, { timeBeginPeriod(1); - g_thread_init (NULL); hAppInst=hThisInstance; OpenConsole(); // Init debug console int ret = _main(); CloseConsole(); - + return ret; } @@ -1846,13 +2036,13 @@ void UpdateWndRects(HWND hwnd) RECT rc; int wndWidth, wndHeight; - int defHeight = (video.height + video.screengap); + int defHeight = (384 + ScreenGap); float ratio; int oneScreenHeight, gapHeight; GetClientRect(hwnd, &rc); - if((video.rotation == 90) || (video.rotation == 270)) + if((GPU_rotation == 90) || (GPU_rotation == 270)) { wndWidth = (rc.bottom - rc.top); wndHeight = (rc.right - rc.left); @@ -1864,10 +2054,10 @@ void UpdateWndRects(HWND hwnd) } ratio = ((float)wndHeight / (float)defHeight); - oneScreenHeight = (int)((video.height/2) * ratio); + oneScreenHeight = (192 * ratio); gapHeight = (wndHeight - (oneScreenHeight * 2)); - if((video.rotation == 90) || (video.rotation == 270)) + if((GPU_rotation == 90) || (GPU_rotation == 270)) { // Main screen ptClient.x = rc.left; @@ -1882,7 +2072,7 @@ void UpdateWndRects(HWND hwnd) MainScreenRect.bottom = ptClient.y; //if there was no specified screen gap, extend the top screen to cover the extra column - if(video.screengap == 0) MainScreenRect.right += gapHeight; + if(ScreenGap == 0) MainScreenRect.right += gapHeight; // Sub screen ptClient.x = (rc.left + oneScreenHeight + gapHeight); @@ -1917,7 +2107,7 @@ void UpdateWndRects(HWND hwnd) MainScreenRect.bottom = ptClient.y; //if there was no specified screen gap, extend the top screen to cover the extra row - if(video.screengap == 0) MainScreenRect.bottom += gapHeight; + if(ScreenGap == 0) MainScreenRect.bottom += gapHeight; // Sub screen ptClient.x = rc.left; @@ -1941,53 +2131,72 @@ void UpdateWndRects(HWND hwnd) void UpdateScreenRects() { - if((video.rotation == 90) || (video.rotation == 270)) + if((GPU_rotation == 90) || (GPU_rotation == 270)) { // Main screen MainScreenSrcRect.left = 0; MainScreenSrcRect.top = 0; - MainScreenSrcRect.right = video.height/2; - MainScreenSrcRect.bottom = video.width; + MainScreenSrcRect.right = 192; + MainScreenSrcRect.bottom = 256; // Sub screen - SubScreenSrcRect.left = video.height/2; + SubScreenSrcRect.left = 192; SubScreenSrcRect.top = 0; - SubScreenSrcRect.right = video.height; - SubScreenSrcRect.bottom = video.width; + SubScreenSrcRect.right = 384; + SubScreenSrcRect.bottom = 256; } else { // Main screen MainScreenSrcRect.left = 0; MainScreenSrcRect.top = 0; - MainScreenSrcRect.right = video.width; - MainScreenSrcRect.bottom = video.height/2; + MainScreenSrcRect.right = 256; + MainScreenSrcRect.bottom = 192; // Sub screen SubScreenSrcRect.left = 0; - SubScreenSrcRect.top = video.height/2; - SubScreenSrcRect.right = video.width; - SubScreenSrcRect.bottom = video.height; + SubScreenSrcRect.top = 192; + SubScreenSrcRect.right = 256; + SubScreenSrcRect.bottom = 384; } } void SetScreenGap(int gap) { + RECT rc; + int height, width; + int oldgap, diff; - video.screengap = gap; - MainWindow->setMinSize(video.rotatedwidthgap(), video.rotatedheightgap()); - MainWindow->setClientSize(video.rotatedwidthgap(), video.rotatedheightgap()); + GetClientRect(MainWindow->getHWnd(), &rc); + width = (rc.right - rc.left); + height = (rc.bottom - rc.top); + + oldgap = ScreenGap; + ScreenGap = gap; + + if((GPU_rotation == 90) || (GPU_rotation == 270)) + { + diff = ((gap - oldgap) * (height / 256.0f)); + MainWindow->setMinSize((384 + gap), 256); + MainWindow->setClientSize(width+diff, height); + } + else + { + diff = ((gap - oldgap) * (width / 256.0f)); + MainWindow->setMinSize(256, (384 + gap)); + MainWindow->setClientSize(width, height+diff); + } } //======================================================================================== void SetRotate(HWND hwnd, int rot) { RECT rc; - int oldrot = video.rotation; + int oldrot = GPU_rotation; int oldheight, oldwidth; int newheight, newwidth; - video.rotation = rot; + GPU_rotation = rot; GetClientRect(hwnd, &rc); oldwidth = (rc.right - rc.left); @@ -2022,7 +2231,43 @@ void SetRotate(HWND hwnd, int rot) osd->setRotate(rot); - MainWindow->setMinSize((video.rotatedwidthgap()), video.rotatedheightgap()); + switch (rot) + { + case 0: + GPU_width = 256; + GPU_height = 192*2; + rotationstartscan = 192; + rotationscanlines = 192*2; + MainWindow->setMinSize(GPU_width, (GPU_height + ScreenGap)); + break; + + case 90: + GPU_rotation = 90; + GPU_width = 192*2; + GPU_height = 256; + rotationstartscan = 0; + rotationscanlines = 256; + MainWindow->setMinSize((GPU_width + ScreenGap), GPU_height); + break; + + case 180: + GPU_rotation = 180; + GPU_width = 256; + GPU_height = 192*2; + rotationstartscan = 0; + rotationscanlines = 192*2; + MainWindow->setMinSize(GPU_width, (GPU_height + ScreenGap)); + break; + + case 270: + GPU_rotation = 270; + GPU_width = 192*2; + GPU_height = 256; + rotationstartscan = 0; + rotationscanlines = 256; + MainWindow->setMinSize((GPU_width + ScreenGap), GPU_height); + break; + } MainWindow->setClientSize(newwidth, newheight); @@ -2035,15 +2280,15 @@ void SetRotate(HWND hwnd, int rot) ddsd.dwSize = sizeof(ddsd); ddsd.dwFlags = DDSD_CAPS | DDSD_HEIGHT | DDSD_WIDTH; ddsd.ddsCaps.dwCaps = DDSCAPS_OFFSCREENPLAIN; - ddsd.dwWidth = video.rotatedwidth(); - ddsd.dwHeight = video.rotatedheight(); + ddsd.dwWidth = GPU_width; + ddsd.dwHeight = GPU_height; IDirectDraw7_CreateSurface(lpDDraw, &ddsd, &lpBackSurface, NULL); } - WritePrivateProfileInt("Video","Window Rotate",video.rotation,IniName); + WritePrivateProfileInt("Video","Window Rotate",GPU_rotation,IniName); - gpu_SetRotateScreen(video.rotation); + gpu_SetRotateScreen(GPU_rotation); UpdateScreenRects(); } @@ -2093,11 +2338,11 @@ void AviRecordTo() char folder[MAX_PATH]; ZeroMemory(folder, sizeof(folder)); - path.getpath(path.AVI_FILES, folder); + GetPathFor(AVI_FILES, folder, MAX_PATH); char file[MAX_PATH]; ZeroMemory(file, sizeof(file)); - path.formatname(file); + FormatName(file, MAX_PATH); strcat(folder, file); int len = strlen(folder); @@ -2122,7 +2367,7 @@ void AviRecordTo() void WavEnd() { NDS_Pause(); - WAV_End(); + DRV_WavEnd(); NDS_UnPause(); } @@ -2169,7 +2414,7 @@ void WavRecordTo() if(GetSaveFileName(&ofn)) { - WAV_Begin(szChoice); + DRV_WavBegin(szChoice); } NDS_UnPause(); @@ -2181,7 +2426,11 @@ void OpenRecentROM(int listNum) char filename[MAX_PATH]; strcpy(filename, RecentRoms[listNum].c_str()); //LOG("Attempting to load %s\n",filename); +#ifdef EXPERIMENTAL_GBASLOT if(OpenCore(filename)) +#else + if(OpenCore(filename, bad_glob_cflash_disk_image_file)) +#endif { romloaded = TRUE; } @@ -2203,8 +2452,19 @@ void OpenRecentROM(int listNum) #include "OpenArchive.h" #include "utils/xstring.h" +#ifdef EXPERIMENTAL_GBASLOT static BOOL OpenCore(const char* filename) +#else +static BOOL OpenCore(const char * filename, const char *cflash_disk_image) +#endif { + if(!strcmp(getExtension(filename).c_str(), "gz") || !strcmp(getExtension(filename).c_str(), "nds.gz")) { + if(LoadROM(filename,filename)) { + NDS_UnPause(); + return FALSE; + } + } + char LogicalName[1024], PhysicalName[1024]; const char* s_nonRomExtensions [] = {"txt", "nfo", "htm", "html", "jpg", "jpeg", "png", "bmp", "gif", "mp3", "wav", "lnk", "exe", "bat", "gmv", "gm2", "lua", "luasav", "sav", "srm", "brm", "cfg", "wch", "gs*"}; @@ -2212,7 +2472,7 @@ static BOOL OpenCore(const char* filename) if(!ObtainFile(filename, LogicalName, PhysicalName, "rom", s_nonRomExtensions, ARRAY_SIZE(s_nonRomExtensions))) return FALSE; - if(LoadROM(filename, LogicalName)) + if(LoadROM(PhysicalName, LogicalName)) { romloaded = TRUE; NDS_UnPause(); @@ -2270,7 +2530,7 @@ LRESULT OpenFile() char buffer[MAX_PATH]; ZeroMemory(buffer, sizeof(buffer)); - path.getpath(path.ROMS, buffer); + GetPathFor(ROMS, buffer, MAX_PATH); ofn.lpstrInitialDir = buffer; @@ -2279,7 +2539,7 @@ LRESULT OpenFile() return 0; } else { - if(path.savelastromvisit) + if(SavePathForRomVisit()) { char *lchr, buffer[MAX_PATH]; ZeroMemory(buffer, sizeof(buffer)); @@ -2287,12 +2547,16 @@ LRESULT OpenFile() lchr = strrchr(filename, '\\'); strncpy(buffer, filename, strlen(filename) - strlen(lchr)); - path.setpath(path.ROMS, buffer); + SetPathFor(ROMS, buffer); WritePathSettings(); } } +#ifdef EXPERIMENTAL_GBASLOT if(!OpenCore(filename)) +#else + if(!OpenCore(filename, bad_glob_cflash_disk_image_file)) +#endif return 0; // if(!GetOpenFileName(&ofn)) @@ -2472,18 +2736,6 @@ void RunConfig(CONFIGSCREEN which) NDS_UnPause(); } -void FilterUpdate (HWND hwnd, bool user){ - UpdateScreenRects(); - UpdateWndRects(hwnd); - SetScreenGap(video.screengap); - SetRotate(hwnd, video.rotation); - if(user && windowSize==0) {} - else ScaleScreen(windowSize); - WritePrivateProfileInt("Video", "Filter", video.currentfilter, IniName); - WritePrivateProfileInt("Video", "Width", video.width, IniName); - WritePrivateProfileInt("Video", "Height", video.height, IniName); -} - //======================================================================================== LRESULT CALLBACK WindowProcedure (HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam) { @@ -2500,11 +2752,11 @@ LRESULT CALLBACK WindowProcedure (HWND hwnd, UINT message, WPARAM wParam, LPARAM //Check if AVI is recording mii.cbSize = sizeof(MENUITEMINFO); mii.fMask = MIIM_STRING; - LoadString(hAppInst, !AVI_IsRecording() ? IDM_FILE_RECORDAVI : IDM_FILE_STOPAVI, menuItemString, 256); + LoadString(hAppInst, !DRV_AviIsRecording() ? IDM_FILE_RECORDAVI : IDM_FILE_STOPAVI, menuItemString, 256); mii.dwTypeData = menuItemString; SetMenuItemInfo(mainMenu, IDM_FILE_RECORDAVI, FALSE, &mii); //Check if WAV is recording - LoadString(hAppInst, !WAV_IsRecording() ? IDM_FILE_RECORDWAV : IDM_FILE_STOPWAV, menuItemString, 256); + LoadString(hAppInst, !DRV_WavIsRecording() ? IDM_FILE_RECORDWAV : IDM_FILE_STOPWAV, menuItemString, 256); SetMenuItemInfo(mainMenu, IDM_FILE_RECORDWAV, FALSE, &mii); //Menu items dependent on a ROM loaded @@ -2546,10 +2798,10 @@ LRESULT CALLBACK WindowProcedure (HWND hwnd, UINT message, WPARAM wParam, LPARAM //Force Maintain Ratio MainWindow->checkMenu(IDC_FORCERATIO, MF_BYCOMMAND | ((ForceRatio)?MF_CHECKED:MF_UNCHECKED)); //Screen rotation - MainWindow->checkMenu(IDC_ROTATE0, MF_BYCOMMAND | ((video.rotation==0)?MF_CHECKED:MF_UNCHECKED)); - MainWindow->checkMenu(IDC_ROTATE90, MF_BYCOMMAND | ((video.rotation==90)?MF_CHECKED:MF_UNCHECKED)); - MainWindow->checkMenu(IDC_ROTATE180, MF_BYCOMMAND | ((video.rotation==180)?MF_CHECKED:MF_UNCHECKED)); - MainWindow->checkMenu(IDC_ROTATE270, MF_BYCOMMAND | ((video.rotation==270)?MF_CHECKED:MF_UNCHECKED)); + MainWindow->checkMenu(IDC_ROTATE0, MF_BYCOMMAND | ((GPU_rotation==0)?MF_CHECKED:MF_UNCHECKED)); + MainWindow->checkMenu(IDC_ROTATE90, MF_BYCOMMAND | ((GPU_rotation==90)?MF_CHECKED:MF_UNCHECKED)); + MainWindow->checkMenu(IDC_ROTATE180, MF_BYCOMMAND | ((GPU_rotation==180)?MF_CHECKED:MF_UNCHECKED)); + MainWindow->checkMenu(IDC_ROTATE270, MF_BYCOMMAND | ((GPU_rotation==270)?MF_CHECKED:MF_UNCHECKED)); //Window Size MainWindow->checkMenu(IDC_WINDOW1X, MF_BYCOMMAND | ((windowSize==1)?MF_CHECKED:MF_UNCHECKED)); @@ -2560,16 +2812,16 @@ LRESULT CALLBACK WindowProcedure (HWND hwnd, UINT message, WPARAM wParam, LPARAM MainWindow->checkMenu(IDC_WINDOW4X, MF_BYCOMMAND | ((windowSize==4)?MF_CHECKED:MF_UNCHECKED)); //Screen Separation - MainWindow->checkMenu(IDM_SCREENSEP_NONE, MF_BYCOMMAND | ((video.screengap==0)? MF_CHECKED:MF_UNCHECKED)); - MainWindow->checkMenu(IDM_SCREENSEP_BORDER, MF_BYCOMMAND | ((video.screengap==5)? MF_CHECKED:MF_UNCHECKED)); - MainWindow->checkMenu(IDM_SCREENSEP_NDSGAP, MF_BYCOMMAND | ((video.screengap==64)?MF_CHECKED:MF_UNCHECKED)); + MainWindow->checkMenu(IDM_SCREENSEP_NONE, MF_BYCOMMAND | ((ScreenGap==0)? MF_CHECKED:MF_UNCHECKED)); + MainWindow->checkMenu(IDM_SCREENSEP_BORDER, MF_BYCOMMAND | ((ScreenGap==5)? MF_CHECKED:MF_UNCHECKED)); + MainWindow->checkMenu(IDM_SCREENSEP_NDSGAP, MF_BYCOMMAND | ((ScreenGap==64)?MF_CHECKED:MF_UNCHECKED)); //Counters / Etc. - MainWindow->checkMenu(ID_VIEW_FRAMECOUNTER, MF_BYCOMMAND | ((CommonSettings.hud.FrameCounterDisplay)?MF_CHECKED:MF_UNCHECKED)); - MainWindow->checkMenu(ID_VIEW_DISPLAYFPS, MF_BYCOMMAND | ((CommonSettings.hud.FpsDisplay) ?MF_CHECKED:MF_UNCHECKED)); - MainWindow->checkMenu(ID_VIEW_DISPLAYINPUT, MF_BYCOMMAND | ((CommonSettings.hud.ShowInputDisplay) ?MF_CHECKED:MF_UNCHECKED)); - MainWindow->checkMenu(ID_VIEW_DISPLAYLAG, MF_BYCOMMAND | ((CommonSettings.hud.ShowLagFrameCounter)?MF_CHECKED:MF_UNCHECKED)); - MainWindow->checkMenu(ID_VIEW_DISPLAYMICROPHONE, MF_BYCOMMAND | ((CommonSettings.hud.ShowMicrophone)?MF_CHECKED:MF_UNCHECKED)); + MainWindow->checkMenu(ID_VIEW_FRAMECOUNTER, MF_BYCOMMAND | ((frameCounterDisplay)?MF_CHECKED:MF_UNCHECKED)); + MainWindow->checkMenu(ID_VIEW_DISPLAYFPS, MF_BYCOMMAND | ((FpsDisplay) ?MF_CHECKED:MF_UNCHECKED)); + MainWindow->checkMenu(ID_VIEW_DISPLAYINPUT, MF_BYCOMMAND | ((ShowInputDisplay) ?MF_CHECKED:MF_UNCHECKED)); + MainWindow->checkMenu(ID_VIEW_DISPLAYLAG, MF_BYCOMMAND | ((ShowLagFrameCounter)?MF_CHECKED:MF_UNCHECKED)); + MainWindow->checkMenu(ID_VIEW_DISPLAYMICROPHONE, MF_BYCOMMAND | ((ShowMicrophone)?MF_CHECKED:MF_UNCHECKED)); MainWindow->checkMenu(ID_VIEW_HUDEDITOR, MF_BYCOMMAND | ((HudEditorMode) ?MF_CHECKED:MF_UNCHECKED)); MainWindow->checkMenu(IDC_FRAMELIMIT, MF_BYCOMMAND | ((FrameLimit) ?MF_CHECKED:MF_UNCHECKED)); @@ -2590,27 +2842,12 @@ LRESULT CALLBACK WindowProcedure (HWND hwnd, UINT message, WPARAM wParam, LPARAM MainWindow->checkMenu(IDM_MGPU, MF_BYCOMMAND | CommonSettings.showGpu.main ? MF_CHECKED:MF_UNCHECKED); MainWindow->checkMenu(IDM_SGPU, MF_BYCOMMAND | CommonSettings.showGpu.sub ? MF_CHECKED:MF_UNCHECKED); - //Filters - - MainWindow->checkMenu(IDM_RENDER_NORMAL, MF_BYCOMMAND | video.currentfilter == video.NONE ? MF_CHECKED:MF_UNCHECKED); - MainWindow->checkMenu(IDM_RENDER_HQ2X, MF_BYCOMMAND | video.currentfilter == video.HQ2X ? MF_CHECKED:MF_UNCHECKED); - MainWindow->checkMenu(IDM_RENDER_2XSAI, MF_BYCOMMAND | video.currentfilter == video._2XSAI ? MF_CHECKED:MF_UNCHECKED); - MainWindow->checkMenu(IDM_RENDER_SUPER2XSAI, MF_BYCOMMAND | video.currentfilter == video.SUPER2XSAI ? MF_CHECKED:MF_UNCHECKED); - MainWindow->checkMenu(IDM_RENDER_SUPEREAGLE, MF_BYCOMMAND | video.currentfilter == video.SUPEREAGLE ? MF_CHECKED:MF_UNCHECKED); - MainWindow->checkMenu(IDM_RENDER_SCANLINE, MF_BYCOMMAND | video.currentfilter == video.SCANLINE ? MF_CHECKED:MF_UNCHECKED); - MainWindow->checkMenu(IDM_RENDER_BILINEAR, MF_BYCOMMAND | video.currentfilter == video.BILINEAR ? MF_CHECKED:MF_UNCHECKED); - - MainWindow->checkMenu(IDC_STATEREWINDING, MF_BYCOMMAND | staterewindingenabled == 1 ? MF_CHECKED:MF_UNCHECKED); - //Language selection MainWindow->checkMenu(IDC_BACKGROUNDPAUSE, MF_BYCOMMAND | ((lostFocusPause)?MF_CHECKED:MF_UNCHECKED)); //Save type - const int savelist[] = {IDC_SAVETYPE1,IDC_SAVETYPE2,IDC_SAVETYPE3,IDC_SAVETYPE4,IDC_SAVETYPE5,IDC_SAVETYPE6,IDC_SAVETYPE7}; - for(int i=0;i<7;i++) MainWindow->checkMenu(savelist[i], MF_BYCOMMAND | MF_UNCHECKED); - MainWindow->checkMenu(savelist[CommonSettings.manualBackupType], MF_BYCOMMAND | MF_CHECKED); - + MainWindow->checkMenu(IDC_SAVETYPE1, MF_BYCOMMAND | MF_CHECKED); return 0; } @@ -2622,7 +2859,7 @@ LRESULT CALLBACK WindowProcedure (HWND hwnd, UINT message, WPARAM wParam, LPARAM case WM_CREATE: { - path.ReadPathSettings(); + ReadPathSettings(); pausedByMinimize = FALSE; UpdateScreenRects(); return 0; @@ -2650,8 +2887,8 @@ LRESULT CALLBACK WindowProcedure (HWND hwnd, UINT message, WPARAM wParam, LPARAM WritePrivateProfileInt("Video", "WindowPosY", WndY/*MainWindowRect.top*/, IniName); //Save frame counter status - WritePrivateProfileInt("Display", "FrameCounter", CommonSettings.hud.FrameCounterDisplay, IniName); - WritePrivateProfileInt("Display", "ScreenGap", video.screengap, IniName); + WritePrivateProfileInt("Display", "FrameCounter", frameCounterDisplay, IniName); + WritePrivateProfileInt("Display", "ScreenGap", ScreenGap, IniName); //Save Ram Watch information WritePrivateProfileInt("RamWatch", "SaveWindowPos", RWSaveWindowPos, IniName); @@ -2771,7 +3008,9 @@ LRESULT CALLBACK WindowProcedure (HWND hwnd, UINT message, WPARAM wParam, LPARAM hdc = BeginPaint(hwnd, &ps); + osd->update(); Display(); + osd->clear(); EndPaint(hwnd, &ps); } @@ -2781,7 +3020,11 @@ LRESULT CALLBACK WindowProcedure (HWND hwnd, UINT message, WPARAM wParam, LPARAM char filename[MAX_PATH] = ""; DragQueryFile((HDROP)wParam,0,filename,MAX_PATH); DragFinish((HDROP)wParam); +#ifdef EXPERIMENTAL_GBASLOT if(OpenCore(filename)) +#else + if(OpenCore(filename, bad_glob_cflash_disk_image_file)) +#endif { romloaded = TRUE; } @@ -2797,12 +3040,11 @@ LRESULT CALLBACK WindowProcedure (HWND hwnd, UINT message, WPARAM wParam, LPARAM s32 x = (s32)((s16)LOWORD(lParam)); s32 y = (s32)((s16)HIWORD(lParam)); GetClientRect(hwnd,&r); - SetCapture(hwnd); - int defwidth = video.width, defheight = (video.height+video.screengap); + int defwidth = 256, defheight = (384+ScreenGap); int winwidth = (r.right-r.left), winheight = (r.bottom-r.top); // translate from scaling (screen resolution to 256x384 or 512x192) - switch (video.rotation) + switch (GPU_rotation) { case 0: case 180: @@ -2816,19 +3058,15 @@ LRESULT CALLBACK WindowProcedure (HWND hwnd, UINT message, WPARAM wParam, LPARAM break ; } - x = x/video.ratio(); - y = y/video.ratio(); - if(HudEditorMode) { EditHud(x,y, &Hud); } else { //translate for rotation - if (video.rotation != 0) + if (GPU_rotation != 0) translateXY(x,y); else - y-=192+(video.screengap/video.ratio()); - + y-=(192+ScreenGap); if(x<0) x = 0; else if(x>255) x = 255; if(y<0) y = 0; else if(y>192) y = 192; NDS_setTouchPos(x, y); @@ -2839,8 +3077,8 @@ LRESULT CALLBACK WindowProcedure (HWND hwnd, UINT message, WPARAM wParam, LPARAM return 0; case WM_LBUTTONUP: - - ReleaseCapture(); + if(click) + ReleaseCapture(); NDS_releaseTouch(); HudClickRelease(&Hud); return 0; @@ -2889,25 +3127,25 @@ LRESULT CALLBACK WindowProcedure (HWND hwnd, UINT message, WPARAM wParam, LPARAM { char buffer[MAX_PATH]; ZeroMemory(buffer, sizeof(buffer)); - path.getpath(path.SCREENSHOTS, buffer); + GetPathFor(SCREENSHOTS, buffer, MAX_PATH); char file[MAX_PATH]; ZeroMemory(file, sizeof(file)); - path.formatname(file); + FormatName(file, MAX_PATH); strcat(buffer, file); if( strlen(buffer) > (MAX_PATH - 4)) buffer[MAX_PATH - 4] = '\0'; - switch(path.imageformat()) + switch(GetImageFormatType()) { - case path.PNG: + case PNG: { strcat(buffer, ".png"); NDS_WritePNG(buffer); } break; - case path.BMP: + case BMP: { strcat(buffer, ".bmp"); NDS_WriteBMP(buffer); @@ -2917,48 +3155,17 @@ LRESULT CALLBACK WindowProcedure (HWND hwnd, UINT message, WPARAM wParam, LPARAM } return 0; case IDM_FILE_RECORDAVI: - if (AVI_IsRecording()) + if (DRV_AviIsRecording()) AviEnd(); else AviRecordTo(); break; case IDM_FILE_RECORDWAV: - if (WAV_IsRecording()) - WAV_End(); + if (DRV_WavIsRecording()) + WavEnd(); else WavRecordTo(); break; - case IDC_STATEREWINDING: - if(staterewindingenabled) staterewindingenabled = false; - else staterewindingenabled = true; - case IDM_RENDER_NORMAL: - video.setfilter(video.NONE); - FilterUpdate(hwnd); - break; - case IDM_RENDER_HQ2X: - video.setfilter(video.HQ2X); - FilterUpdate(hwnd); - break; - case IDM_RENDER_2XSAI: - video.setfilter(video._2XSAI); - FilterUpdate(hwnd); - break; - case IDM_RENDER_SUPER2XSAI: - video.setfilter(video.SUPER2XSAI); - FilterUpdate(hwnd); - break; - case IDM_RENDER_SUPEREAGLE: - video.setfilter(video.SUPEREAGLE); - FilterUpdate(hwnd); - break; - case IDM_RENDER_SCANLINE: - video.setfilter(video.SCANLINE); - FilterUpdate(hwnd); - break; - case IDM_RENDER_BILINEAR: - video.setfilter(video.BILINEAR); - FilterUpdate(hwnd); - break; case IDM_STATE_LOAD: { OPENFILENAME ofn; @@ -2974,7 +3181,7 @@ LRESULT CALLBACK WindowProcedure (HWND hwnd, UINT message, WPARAM wParam, LPARAM char buffer[MAX_PATH]; ZeroMemory(buffer, sizeof(buffer)); - path.getpath(path.STATES, buffer); + GetPathFor(STATES, buffer, MAX_PATH); ofn.lpstrInitialDir = buffer; if(!GetOpenFileName(&ofn)) @@ -3004,7 +3211,7 @@ LRESULT CALLBACK WindowProcedure (HWND hwnd, UINT message, WPARAM wParam, LPARAM char buffer[MAX_PATH]; ZeroMemory(buffer, sizeof(buffer)); - path.getpath(path.STATES, buffer); + GetPathFor(STATES, buffer, MAX_PATH); ofn.lpstrInitialDir = buffer; if(!GetSaveFileName(&ofn)) @@ -3067,7 +3274,7 @@ LRESULT CALLBACK WindowProcedure (HWND hwnd, UINT message, WPARAM wParam, LPARAM ZeroMemory(&ofn, sizeof(ofn)); ofn.lStructSize = sizeof(ofn); ofn.hwndOwner = hwnd; - ofn.lpstrFilter = "All supported types\0*.duc;*.sav\0Action Replay DS Save (*.duc)\0*.duc\0Raw Save format (*.sav)\0*.sav\0\0"; + ofn.lpstrFilter = "All supported types\0*.duc;*.sav\0Action Replay DS Save (*.duc)\0*.duc\0DS-Xtreme Save (*.sav)\0*.sav\0\0"; ofn.nFilterIndex = 1; ofn.lpstrFile = ImportSavName; ofn.nMaxFile = MAX_PATH; @@ -3075,7 +3282,7 @@ LRESULT CALLBACK WindowProcedure (HWND hwnd, UINT message, WPARAM wParam, LPARAM char buffer[MAX_PATH]; ZeroMemory(buffer, sizeof(buffer)); - path.getpath(path.BATTERY, buffer); + GetPathFor(BATTERY, buffer, MAX_PATH); ofn.lpstrInitialDir = buffer; if(!GetOpenFileName(&ofn)) @@ -3335,29 +3542,28 @@ LRESULT CALLBACK WindowProcedure (HWND hwnd, UINT message, WPARAM wParam, LPARAM FCEUI_StopMovie(); return 0; case ID_VIEW_FRAMECOUNTER: - CommonSettings.hud.FrameCounterDisplay ^= true; - MainWindow->checkMenu(ID_VIEW_FRAMECOUNTER, CommonSettings.hud.FrameCounterDisplay ? MF_CHECKED : MF_UNCHECKED); - WritePrivateProfileBool("Display", "Display Fps", CommonSettings.hud.FpsDisplay, IniName); + frameCounterDisplay ^= 1; + MainWindow->checkMenu(ID_VIEW_FRAMECOUNTER, frameCounterDisplay ? MF_CHECKED : MF_UNCHECKED); return 0; case ID_VIEW_DISPLAYFPS: - CommonSettings.hud.FpsDisplay ^= true; - MainWindow->checkMenu(ID_VIEW_DISPLAYFPS, CommonSettings.hud.FpsDisplay ? MF_CHECKED : MF_UNCHECKED); - WritePrivateProfileBool("Display", "Display Fps", CommonSettings.hud.FpsDisplay, IniName); + FpsDisplay ^= 1; + MainWindow->checkMenu(ID_VIEW_DISPLAYFPS, FpsDisplay ? MF_CHECKED : MF_UNCHECKED); + WritePrivateProfileInt("Display", "Display Fps", FpsDisplay, IniName); osd->clear(); return 0; case ID_VIEW_DISPLAYINPUT: - CommonSettings.hud.ShowInputDisplay ^= true; - MainWindow->checkMenu(ID_VIEW_DISPLAYINPUT, CommonSettings.hud.ShowInputDisplay ? MF_CHECKED : MF_UNCHECKED); - WritePrivateProfileBool("Display", "Display Input", CommonSettings.hud.ShowInputDisplay, IniName); + ShowInputDisplay ^= 1; + MainWindow->checkMenu(ID_VIEW_DISPLAYINPUT, ShowInputDisplay ? MF_CHECKED : MF_UNCHECKED); + WritePrivateProfileInt("Display", "Display Input", ShowInputDisplay, IniName); osd->clear(); return 0; case ID_VIEW_DISPLAYLAG: - CommonSettings.hud.ShowLagFrameCounter ^= true; - MainWindow->checkMenu(ID_VIEW_DISPLAYLAG, CommonSettings.hud.ShowLagFrameCounter ? MF_CHECKED : MF_UNCHECKED); - WritePrivateProfileBool("Display", "Display Lag Counter", CommonSettings.hud.ShowLagFrameCounter, IniName); + ShowLagFrameCounter ^= 1; + MainWindow->checkMenu(ID_VIEW_DISPLAYLAG, ShowLagFrameCounter ? MF_CHECKED : MF_UNCHECKED); + WritePrivateProfileInt("Display", "Display Lag Counter", ShowLagFrameCounter, IniName); osd->clear(); return 0; @@ -3369,9 +3575,9 @@ LRESULT CALLBACK WindowProcedure (HWND hwnd, UINT message, WPARAM wParam, LPARAM return 0; case ID_VIEW_DISPLAYMICROPHONE: - CommonSettings.hud.ShowMicrophone ^= true; - MainWindow->checkMenu(ID_VIEW_DISPLAYMICROPHONE, CommonSettings.hud.ShowMicrophone ? MF_CHECKED : MF_UNCHECKED); - WritePrivateProfileBool("Display", "Display Microphone", CommonSettings.hud.ShowMicrophone, IniName); + ShowMicrophone ^= 1; + MainWindow->checkMenu(ID_VIEW_DISPLAYMICROPHONE, ShowMicrophone ? MF_CHECKED : MF_UNCHECKED); + WritePrivateProfileInt("Display", "Display Microphone", ShowMicrophone, IniName); osd->clear(); return 0; @@ -3400,13 +3606,53 @@ LRESULT CALLBACK WindowProcedure (HWND hwnd, UINT message, WPARAM wParam, LPARAM WritePrivateProfileInt("Focus", "BackgroundPause", (int)lostFocusPause, IniName); return 0; - case IDC_SAVETYPE1: backup_setManualBackupType(0); return 0; - case IDC_SAVETYPE2: backup_setManualBackupType(1); return 0; - case IDC_SAVETYPE3: backup_setManualBackupType(2); return 0; - case IDC_SAVETYPE4: backup_setManualBackupType(3); return 0; - case IDC_SAVETYPE5: backup_setManualBackupType(4); return 0; - case IDC_SAVETYPE6: backup_setManualBackupType(5); return 0; - case IDC_SAVETYPE7: backup_setManualBackupType(6); return 0; +#define clearsaver() \ + MainWindow->checkMenu(IDC_SAVETYPE1, MF_BYCOMMAND | MF_UNCHECKED); \ + MainWindow->checkMenu(IDC_SAVETYPE2, MF_BYCOMMAND | MF_UNCHECKED); \ + MainWindow->checkMenu(IDC_SAVETYPE3, MF_BYCOMMAND | MF_UNCHECKED); \ + MainWindow->checkMenu(IDC_SAVETYPE4, MF_BYCOMMAND | MF_UNCHECKED); \ + MainWindow->checkMenu(IDC_SAVETYPE5, MF_BYCOMMAND | MF_UNCHECKED); \ + MainWindow->checkMenu(IDC_SAVETYPE6, MF_BYCOMMAND | MF_UNCHECKED); \ + MainWindow->checkMenu(IDC_SAVETYPE7, MF_BYCOMMAND | MF_UNCHECKED); + +#define saver(one) \ + MainWindow->checkMenu(one, MF_BYCOMMAND | MF_CHECKED); + + case IDC_SAVETYPE1: + clearsaver(); + saver(IDC_SAVETYPE1); + mmu_select_savetype(0,&backupmemorytype,&backupmemorysize); + return 0; + case IDC_SAVETYPE2: + clearsaver(); + saver(IDC_SAVETYPE2); + mmu_select_savetype(1,&backupmemorytype,&backupmemorysize); + return 0; + case IDC_SAVETYPE3: + clearsaver(); + saver(IDC_SAVETYPE3); + mmu_select_savetype(2,&backupmemorytype,&backupmemorysize); + return 0; + case IDC_SAVETYPE4: + clearsaver(); + saver(IDC_SAVETYPE4); + mmu_select_savetype(3,&backupmemorytype,&backupmemorysize); + return 0; + case IDC_SAVETYPE5: + clearsaver(); + saver(IDC_SAVETYPE5); + mmu_select_savetype(4,&backupmemorytype,&backupmemorysize); + return 0; + case IDC_SAVETYPE6: + clearsaver(); + saver(IDC_SAVETYPE6); + mmu_select_savetype(5,&backupmemorytype,&backupmemorysize); + return 0; + case IDC_SAVETYPE7: + clearsaver(); + saver(IDC_SAVETYPE7); + mmu_select_savetype(6,&backupmemorytype,&backupmemorysize); + return 0; case IDM_RESET: ResetGame(); @@ -3470,17 +3716,16 @@ LRESULT CALLBACK WindowProcedure (HWND hwnd, UINT message, WPARAM wParam, LPARAM ChangeLanguage(1); CheckLanguage(LOWORD(wParam)); return 0; + case IDC_LANGDANISH: + SaveLanguage(2); + ChangeLanguage(2); + CheckLanguage(LOWORD(wParam)); + return 0; case IDC_LANG_CHINESE_SIMPLIFIED: SaveLanguage(3); ChangeLanguage(3); CheckLanguage(LOWORD(wParam)); return 0; - - case IDC_LANGDANISH: - SaveLanguage(2); - ChangeLanguage(2); - CheckLanguage(LOWORD(wParam)); - return 0; case IDC_FRAMELIMIT: FrameLimit ^= 1; @@ -3846,7 +4091,7 @@ LRESULT CALLBACK EmulationSettingsDlgProc(HWND hDlg, UINT uMsg, WPARAM wParam, L char buffer[MAX_PATH]; ZeroMemory(buffer, sizeof(buffer)); - path.getpath(path.FIRMWARE, buffer); + GetPathFor(FIRMWARE, buffer, MAX_PATH); ofn.lpstrInitialDir = buffer; if(GetOpenFileName(&ofn)) @@ -3913,14 +4158,7 @@ LRESULT CALLBACK MicrophoneSettingsDlgProc(HWND hDlg, UINT uMsg, WPARAM wParam, WritePrivateProfileInt("Use Mic Sample", "UseMicSample", ((UseMicSample == true) ? 1 : 0), IniName); WritePrivateProfileString("Use Mic Sample", "MicSampleFile", MicSampleName, IniName); - - if (UseMicSample) - { - if (!LoadSample(MicSampleName)) - { - MessageBox(hDlg, "Unable to read the sample", "DeSmuME", (MB_OK | MB_ICONEXCLAMATION)); - } - } + LoadSample(MicSampleName); } } case IDCANCEL: @@ -3958,7 +4196,7 @@ LRESULT CALLBACK MicrophoneSettingsDlgProc(HWND hDlg, UINT uMsg, WPARAM wParam, char buffer[MAX_PATH]; ZeroMemory(buffer, sizeof(buffer)); - path.getpath(path.SOUNDS, buffer); + GetPathFor(SOUNDS, buffer, MAX_PATH); ofn.lpstrInitialDir = buffer; if(GetOpenFileName(&ofn)) @@ -4119,7 +4357,7 @@ LRESULT CALLBACK SoundSettingsDlgProc(HWND hDlg, UINT uMsg, WPARAM wParam, LPARA // Write Sound core type sndcoretype = SNDCoreList[SendDlgItemMessage(hDlg, IDC_SOUNDCORECB, CB_GETCURSEL, 0, 0)]->id; sprintf(tempstr, "%d", sndcoretype); - WritePrivateProfileString("Sound", "SoundCore2", tempstr, IniName); + WritePrivateProfileString("Sound", "SoundCore", tempstr, IniName); // Write Sound Buffer size GetDlgItemText(hDlg, IDC_SOUNDBUFFERET, tempstr, 6); diff --git a/desmume/src/windows/main.h b/src/windows/main.h similarity index 94% rename from desmume/src/windows/main.h rename to src/windows/main.h index 1ff526d05..4396346fd 100644 --- a/desmume/src/windows/main.h +++ b/src/windows/main.h @@ -7,6 +7,7 @@ extern WINCLASS *MainWindow; extern volatile BOOL execute, paused; void NDS_Pause(); void NDS_UnPause(); +extern unsigned int lastSaveState; void LoadSaveStateInfo(); void Display(); void Pause(); diff --git a/src/windows/mapView.cpp b/src/windows/mapView.cpp new file mode 100644 index 000000000..55f499047 --- /dev/null +++ b/src/windows/mapView.cpp @@ -0,0 +1,298 @@ +/* Copyright (C) 2006 yopyop + yopyop156@ifrance.com + yopyop156.ifrance.com + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#include "mapView.h" +#include "resource.h" + +#include +#include "../MMU.h" +#include "../NDSSystem.h" +#include "debug.h" +#include "windriver.h" + +using namespace GPU_EXT; + +struct mapview_struct +{ + u32 autoup_secs; + bool autoup; + + u16 map; + u16 lcd; + u16 bitmap[1024*1024]; + + void render() + { + //we're going to make a copy of the gpu so that we don't wreck affine scroll params + //hopefully we won't mess up anything else + GPU *realGpu; + if(lcd) realGpu = SubScreen.gpu; + else realGpu = MainScreen.gpu; + GPU &gpu = *realGpu; + + //forgive the gyrations, some of this junk in here is to remind us of gyrations we might have to go + //through to avoid breaking the gpu struct + + gpu.currBgNum = map; + gpu.debug = true; + + for(u32 i = 0; i < gpu.BGSize[map][1]; ++i) + { + gpu.currDst = (u8 *)bitmap + i*gpu.BGSize[map][0]*2; + gpu.currLine = i; + gpu.modeRender(map); + } + gpu.debug = false; + + } +}; + +mapview_struct *MapView = NULL; + + +LRESULT MapView_OnPaint(mapview_struct * win, HWND hwnd, WPARAM wParam, LPARAM lParam) +{ + Lock lock; + + HDC hdc; + PAINTSTRUCT ps; + char text[80]; + u32 dispcnt = ((volatile u32 *)ARM9Mem.ARM9_REG)[(win->lcd*0x400)]; + u32 bgcnt = ((volatile u16 *)ARM9Mem.ARM9_REG)[(8 + (win->map<<1) + (win->lcd*0x1000))>>1]; + BITMAPV4HEADER bmi; + u16 lg; + u16 ht; + BGxPARMS * parms; + + //CreateBitmapIndirect(&bmi); + memset(&bmi, 0, sizeof(bmi)); + bmi.bV4Size = sizeof(bmi); + bmi.bV4Planes = 1; + bmi.bV4BitCount = 16; + bmi.bV4V4Compression = BI_RGB|BI_BITFIELDS; + bmi.bV4RedMask = 0x001F; + bmi.bV4GreenMask = 0x03E0; + bmi.bV4BlueMask = 0x7C00; + + if(win->lcd) + { + lg = SubScreen.gpu->BGSize[win->map][0]; + ht = SubScreen.gpu->BGSize[win->map][1]; + } + else + { + lg = MainScreen.gpu->BGSize[win->map][0]; + ht = MainScreen.gpu->BGSize[win->map][1]; + } + bmi.bV4Width = lg; + bmi.bV4Height = -ht; + + hdc = BeginPaint(hwnd, &ps); + + sprintf(text, "%d %08X, %08X", (int)(dispcnt&7), (int)dispcnt, (int)bgcnt); + SetWindowText(GetDlgItem(hwnd, IDC_MODE), text); + + if(!(bgcnt&(1<<7))) + sprintf(text, "normal 16"); + else + { + if(!(dispcnt&(1<<30))) + sprintf(text, "normal 256"); + else + { + switch(win->map) + { + case 0 : + sprintf(text, "extended slot %d", (bgcnt&(1<<13))?2:0); + break; + case 1 : + sprintf(text, "extended slot %d", (bgcnt&(1<<13))?3:1); + break; + default : + sprintf(text, "extended slot %d", MainScreen.gpu->BGExtPalSlot[win->map]); + break; + } + } + } + SetWindowText(GetDlgItem(hwnd, IDC_PAL), text); + + sprintf(text, "%d", (int)(bgcnt&3)); + SetWindowText(GetDlgItem(hwnd, IDC_PRIO), text); + + + if((dispcnt>>8>>win->map)&1) + SetWindowText(GetDlgItem(hwnd, IDC_VISIBLE), "true"); + else + SetWindowText(GetDlgItem(hwnd, IDC_VISIBLE), "false"); + + sprintf(text, "0x%08X", (int)(0x6000000 + ((bgcnt>>2)&0xF)*0x4000 + win->lcd*0x200000 +((dispcnt>>24)&7)*0x10000)); + SetWindowText(GetDlgItem(hwnd, IDC_CHAR), text); + + sprintf(text, "0x%08X", (int)(0x6000000 + 0x800*((bgcnt>>8)&0x1F) + win->lcd*0x200000 + ((dispcnt>>27)&7)*0x10000)); + SetWindowText(GetDlgItem(hwnd, IDC_SCR), text); + + //sprintf(text, "%d x %d", MainScreen.gpu->BGPA[win->map], MainScreen.gpu->BGPB[win->map]); + sprintf(text, "%d x %d", (int)MainScreen.gpu->BGSize[win->map][0], (int)MainScreen.gpu->BGSize[win->map][1]); + SetWindowText(GetDlgItem(hwnd, IDC_MSIZE), text); + + if (win->map==2) { + parms = &(MainScreen.gpu->dispx_st)->dispx_BG2PARMS; + } else { + parms = &(MainScreen.gpu->dispx_st)->dispx_BG3PARMS; + } + sprintf(text, "%d x %d", parms->BGxPC, parms->BGxPD); + SetWindowText(GetDlgItem(hwnd, IDC_SCROLL), text); + + for(int i = 0; i < (1024*1024); i++) + win->bitmap[i] = 0x7C1F; + + win->render(); + + SetDIBitsToDevice(hdc, 200, 4, lg, ht, 0, 0, 0, ht, win->bitmap, (BITMAPINFO*)&bmi, DIB_RGB_COLORS); + + EndPaint(hwnd, &ps); + + return 0; +} + +BOOL CALLBACK ViewMapsProc (HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam) +{ + //bail out early if the dialog isnt initialized + if(!MapView && message != WM_INITDIALOG) + return false; + + switch (message) + { + case WM_INITDIALOG : + { + MapView = new mapview_struct; + memset(MapView, 0, sizeof(MapView)); + MapView->autoup_secs = 1; + SendMessage(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SPIN), + UDM_SETRANGE, 0, MAKELONG(99, 1)); + SendMessage(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SPIN), + UDM_SETPOS32, 0, MapView->autoup_secs); + HWND combo = GetDlgItem(hwnd, IDC_BG_SELECT); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Main BackGround 0"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Main BackGround 1"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Main BackGround 2"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Main BackGround 3"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Sub BackGround 0"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Sub BackGround 1"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Sub BackGround 2"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Sub BackGround 3"); + SendMessage(combo, CB_SETCURSEL, 0, 0); + } + return 1; + case WM_CLOSE : + { + if(MapView->autoup) + { + KillTimer(hwnd, IDT_VIEW_MAP); + MapView->autoup = false; + } + if (MapView!=NULL) + { + delete MapView; + MapView = NULL; + } + //INFO("Close Map view dialog\n"); + PostQuitMessage(0); + return 0; + } + case WM_PAINT: + MapView_OnPaint(MapView, hwnd, wParam, lParam); + return 1; + case WM_TIMER: + SendMessage(hwnd, WM_COMMAND, IDC_REFRESH, 0); + return 1; + case WM_COMMAND : + switch (LOWORD (wParam)) + { + case IDC_FERMER : + SendMessage(hwnd, WM_CLOSE, 0, 0); + return 1; + case IDC_AUTO_UPDATE : + if(MapView->autoup) + { + EnableWindow(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SECS), false); + EnableWindow(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SPIN), false); + KillTimer(hwnd, IDT_VIEW_MAP); + MapView->autoup = FALSE; + return 1; + } + EnableWindow(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SECS), true); + EnableWindow(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SPIN), true); + MapView->autoup = TRUE; + SetTimer(hwnd, IDT_VIEW_MAP, MapView->autoup_secs*20, (TIMERPROC) NULL); + return 1; + case IDC_AUTO_UPDATE_SECS: + { + int t = GetDlgItemInt(hwnd, IDC_AUTO_UPDATE_SECS, FALSE, TRUE); + if (!MapView) + { + SendMessage(hwnd, WM_INITDIALOG, 0, 0); + } + if (t != MapView->autoup_secs) + { + MapView->autoup_secs = t; + if (MapView->autoup) + SetTimer(hwnd, IDT_VIEW_MAP, + MapView->autoup_secs*20, (TIMERPROC) NULL); + } + } + return 1; + case IDC_REFRESH: + InvalidateRect(hwnd, NULL, FALSE); + return 1; + case IDC_BG_SELECT : + switch(HIWORD(wParam)) + { + case CBN_SELCHANGE : + case CBN_CLOSEUP : + { + u32 sel= SendMessage(GetDlgItem(hwnd, IDC_BG_SELECT), CB_GETCURSEL, 0, 0); + switch(sel) + { + case 0 : + case 1 : + case 2 : + case 3 : + MapView->map = sel; + MapView->lcd = 0; + break; + case 4 : + case 5 : + case 6 : + case 7 : + MapView->map = sel-4; + MapView->lcd = 1; + break; + } + } + InvalidateRect(hwnd, NULL, FALSE); + return 1; + }//switch et case + }//switch + return 1; + } + return false; +} diff --git a/desmume/src/windows/mapView.h b/src/windows/mapView.h similarity index 96% rename from desmume/src/windows/mapView.h rename to src/windows/mapView.h index ca12ed9cf..124dae2f9 100644 --- a/desmume/src/windows/mapView.h +++ b/src/windows/mapView.h @@ -1,29 +1,29 @@ -/* Copyright (C) 2006 yopyop - yopyop156@ifrance.com - yopyop156.ifrance.com - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#ifndef MAPVIEW_H -#define MAPVIEW_H - -#include "../common.h" - -extern BOOL CALLBACK ViewMapsProc (HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam); - +/* Copyright (C) 2006 yopyop + yopyop156@ifrance.com + yopyop156.ifrance.com + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#ifndef MAPVIEW_H +#define MAPVIEW_H + +#include "../common.h" + +extern BOOL CALLBACK ViewMapsProc (HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam); + #endif \ No newline at end of file diff --git a/desmume/src/windows/matrixView.cpp b/src/windows/matrixView.cpp similarity index 97% rename from desmume/src/windows/matrixView.cpp rename to src/windows/matrixView.cpp index 47893fd65..12ee73150 100644 --- a/desmume/src/windows/matrixView.cpp +++ b/src/windows/matrixView.cpp @@ -1,256 +1,256 @@ -/* Copyright (C) 2007 Acid Burn - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#include "matrixView.h" -#include -#include "debug.h" -#include "resource.h" -#include "gfx3d.h" - -typedef struct -{ - u32 autoup_secs; - bool autoup; -} matrixview_struct; - -matrixview_struct *MatrixView = NULL; - -void MatrixView_SetMatrix(HWND hwnd, const int* idcs, float* matrix) -{ - int n; - char buffer[64]; - - for(n = 0; n < 16; n++) - { - sprintf(buffer, "%.4f", matrix[n]); - //sprintf(buffer, "%.8x", (int)(matrix[n]*4096)); - SetWindowText(GetDlgItem(hwnd, idcs[n]), buffer); - } -} - -void MatrixView_OnPaintPositionMatrix(HWND hwnd) -{ - // IDC for each matrix coefficient - const int idcGroup[16] = - { - IDC_MATRIX_VIEWER_COORD_11_EDIT, IDC_MATRIX_VIEWER_COORD_12_EDIT, IDC_MATRIX_VIEWER_COORD_13_EDIT, IDC_MATRIX_VIEWER_COORD_14_EDIT, - IDC_MATRIX_VIEWER_COORD_21_EDIT, IDC_MATRIX_VIEWER_COORD_22_EDIT, IDC_MATRIX_VIEWER_COORD_23_EDIT, IDC_MATRIX_VIEWER_COORD_24_EDIT, - IDC_MATRIX_VIEWER_COORD_31_EDIT, IDC_MATRIX_VIEWER_COORD_32_EDIT, IDC_MATRIX_VIEWER_COORD_33_EDIT, IDC_MATRIX_VIEWER_COORD_34_EDIT, - IDC_MATRIX_VIEWER_COORD_41_EDIT, IDC_MATRIX_VIEWER_COORD_42_EDIT, IDC_MATRIX_VIEWER_COORD_43_EDIT, IDC_MATRIX_VIEWER_COORD_44_EDIT - }; - - float matrix[16]; - HWND hStackCombo = GetDlgItem(hwnd, IDC_MATRIX_VIEWER_COORD_COMBO); - int stackIndex; - - stackIndex = SendMessage(hStackCombo, CB_GETCURSEL, 0, 0) - 1; - - gfx3d_glGetMatrix(1, stackIndex, matrix); - MatrixView_SetMatrix(hwnd, idcGroup, matrix); -} - -////////////////////////////////////////////////////////////////////////////// - -void MatrixView_OnPaintDirectionMatrix(HWND hwnd) -{ - // IDC for each matrix coefficient - const int idcGroup[16] = - { - IDC_MATRIX_VIEWER_DIR_11_EDIT, IDC_MATRIX_VIEWER_DIR_12_EDIT, IDC_MATRIX_VIEWER_DIR_13_EDIT, IDC_MATRIX_VIEWER_DIR_14_EDIT, - IDC_MATRIX_VIEWER_DIR_21_EDIT, IDC_MATRIX_VIEWER_DIR_22_EDIT, IDC_MATRIX_VIEWER_DIR_23_EDIT, IDC_MATRIX_VIEWER_DIR_24_EDIT, - IDC_MATRIX_VIEWER_DIR_31_EDIT, IDC_MATRIX_VIEWER_DIR_32_EDIT, IDC_MATRIX_VIEWER_DIR_33_EDIT, IDC_MATRIX_VIEWER_DIR_34_EDIT, - IDC_MATRIX_VIEWER_DIR_41_EDIT, IDC_MATRIX_VIEWER_DIR_42_EDIT, IDC_MATRIX_VIEWER_DIR_43_EDIT, IDC_MATRIX_VIEWER_DIR_44_EDIT - }; - - float matrix[16]; - HWND hStackCombo = GetDlgItem(hwnd, IDC_MATRIX_VIEWER_DIR_COMBO); - int stackIndex; - - stackIndex = SendMessage(hStackCombo, CB_GETCURSEL, 0, 0) - 1; - - gfx3d_glGetMatrix(2, stackIndex, matrix); - MatrixView_SetMatrix(hwnd, idcGroup, matrix); -} - -////////////////////////////////////////////////////////////////////////////// - -void MatrixView_OnPaintProjectionMatrix(HWND hwnd) -{ - // IDC for each matrix coefficient - const int idcGroup[16] = - { - IDC_MATRIX_VIEWER_PROJ_11_EDIT, IDC_MATRIX_VIEWER_PROJ_12_EDIT, IDC_MATRIX_VIEWER_PROJ_13_EDIT, IDC_MATRIX_VIEWER_PROJ_14_EDIT, - IDC_MATRIX_VIEWER_PROJ_21_EDIT, IDC_MATRIX_VIEWER_PROJ_22_EDIT, IDC_MATRIX_VIEWER_PROJ_23_EDIT, IDC_MATRIX_VIEWER_PROJ_24_EDIT, - IDC_MATRIX_VIEWER_PROJ_31_EDIT, IDC_MATRIX_VIEWER_PROJ_32_EDIT, IDC_MATRIX_VIEWER_PROJ_33_EDIT, IDC_MATRIX_VIEWER_PROJ_34_EDIT, - IDC_MATRIX_VIEWER_PROJ_41_EDIT, IDC_MATRIX_VIEWER_PROJ_42_EDIT, IDC_MATRIX_VIEWER_PROJ_43_EDIT, IDC_MATRIX_VIEWER_PROJ_44_EDIT - }; - - float mat[16]; - - gfx3d_glGetMatrix(0, -1, mat); - MatrixView_SetMatrix(hwnd, idcGroup, mat); -} - -////////////////////////////////////////////////////////////////////////////// - -void MatrixView_OnPaintTextureMatrix(HWND hwnd) -{ - // IDC for each matrix coefficient - const int idcGroup[16] = - { - IDC_MATRIX_VIEWER_TEX_11_EDIT, IDC_MATRIX_VIEWER_TEX_12_EDIT, IDC_MATRIX_VIEWER_TEX_13_EDIT, IDC_MATRIX_VIEWER_TEX_14_EDIT, - IDC_MATRIX_VIEWER_TEX_21_EDIT, IDC_MATRIX_VIEWER_TEX_22_EDIT, IDC_MATRIX_VIEWER_TEX_23_EDIT, IDC_MATRIX_VIEWER_TEX_24_EDIT, - IDC_MATRIX_VIEWER_TEX_31_EDIT, IDC_MATRIX_VIEWER_TEX_32_EDIT, IDC_MATRIX_VIEWER_TEX_33_EDIT, IDC_MATRIX_VIEWER_TEX_34_EDIT, - IDC_MATRIX_VIEWER_TEX_41_EDIT, IDC_MATRIX_VIEWER_TEX_42_EDIT, IDC_MATRIX_VIEWER_TEX_43_EDIT, IDC_MATRIX_VIEWER_TEX_44_EDIT - }; - - float mat[16]; - - gfx3d_glGetMatrix(3, -1, mat); - MatrixView_SetMatrix(hwnd, idcGroup, mat); -} - -BOOL MatrixView_OnPaint( HWND hwnd, WPARAM wParam, LPARAM lParam) -{ - HDC hdc; - PAINTSTRUCT ps; - - hdc = BeginPaint(hwnd, &ps); - - MatrixView_OnPaintProjectionMatrix(hwnd); - MatrixView_OnPaintPositionMatrix(hwnd); - MatrixView_OnPaintDirectionMatrix(hwnd); - MatrixView_OnPaintTextureMatrix(hwnd); - - EndPaint(hwnd, &ps); - - return TRUE; -} - -BOOL CALLBACK ViewMatricesProc (HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam) -{ - switch (message) - { - case WM_INITDIALOG: - { - MatrixView = new matrixview_struct; - memset(MatrixView, 0, sizeof(matrixview_struct)); - MatrixView->autoup_secs = 1; - SendMessage(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SPIN), - UDM_SETRANGE, 0, MAKELONG(99, 1)); - SendMessage(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SPIN), - UDM_SETPOS32, 0, MatrixView->autoup_secs); - int n; - HWND hPosCombo = GetDlgItem(hwnd, IDC_MATRIX_VIEWER_COORD_COMBO); - HWND hDirCombo = GetDlgItem(hwnd, IDC_MATRIX_VIEWER_DIR_COMBO); - - // Setup position and direction matrix comboboxes with stack indices - SendMessage(hPosCombo, CB_ADDSTRING, 0,(LPARAM)"Current"); - SendMessage(hDirCombo, CB_ADDSTRING, 0,(LPARAM)"Current"); - - for(n = 0; n < 32; n++) - { - char buffer[4]; - - sprintf(buffer, "%d", n); - SendMessage(hPosCombo, CB_ADDSTRING, 0,(LPARAM)buffer); - SendMessage(hDirCombo, CB_ADDSTRING, 0,(LPARAM)buffer); - } - - SendMessage(hPosCombo, CB_SETCURSEL, 0, 0); - SendMessage(hDirCombo, CB_SETCURSEL, 0, 0); - return 1; - } - - case WM_CLOSE: - { - if(MatrixView->autoup) - { - KillTimer(hwnd, IDT_VIEW_MATRIX); - MatrixView->autoup = false; - } - - if (MatrixView!=NULL) - { - delete MatrixView; - MatrixView = NULL; - } - //INFO("Close Matrix view dialog\n"); - PostQuitMessage(0); - return 0; - } - - case WM_PAINT: - MatrixView_OnPaint(hwnd, wParam, lParam); - return 1; - case WM_TIMER: - SendMessage(hwnd, WM_COMMAND, IDC_REFRESH, 0); - return 1; - - case WM_COMMAND: - switch (LOWORD (wParam)) - { - case IDOK: - SendMessage(hwnd, WM_CLOSE, 0, 0); - return 1; - - case IDC_AUTO_UPDATE : - if(MatrixView->autoup) - { - EnableWindow(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SECS), false); - EnableWindow(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SPIN), false); - KillTimer(hwnd, IDT_VIEW_MATRIX); - MatrixView->autoup = FALSE; - return 1; - } - EnableWindow(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SECS), true); - EnableWindow(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SPIN), true); - MatrixView->autoup = TRUE; - SetTimer(hwnd, IDT_VIEW_MATRIX, MatrixView->autoup_secs*20, (TIMERPROC) NULL); - return 1; - case IDC_AUTO_UPDATE_SECS: - { - int t = GetDlgItemInt(hwnd, IDC_AUTO_UPDATE_SECS, FALSE, TRUE); - if (!MatrixView) - { - SendMessage(hwnd, WM_INITDIALOG, 0, 0); - } - if (t != MatrixView->autoup_secs) - { - MatrixView->autoup_secs = t; - if (MatrixView->autoup) - SetTimer(hwnd, IDT_VIEW_MATRIX, - MatrixView->autoup_secs*20, (TIMERPROC) NULL); - } - } - return 1; - case IDC_REFRESH: - InvalidateRect(hwnd, NULL, FALSE); - return 1; - - case IDC_MATRIX_VIEWER_DIR_COMBO: - case IDC_MATRIX_VIEWER_COORD_COMBO: - InvalidateRect(hwnd, NULL, FALSE); - return 1; - } - return 0; - } - - return false; -} +/* Copyright (C) 2007 Acid Burn + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#include "matrixView.h" +#include +#include "debug.h" +#include "resource.h" +#include "gfx3d.h" + +typedef struct +{ + u32 autoup_secs; + bool autoup; +} matrixview_struct; + +matrixview_struct *MatrixView = NULL; + +void MatrixView_SetMatrix(HWND hwnd, const int* idcs, float* matrix) +{ + int n; + char buffer[64]; + + for(n = 0; n < 16; n++) + { + sprintf(buffer, "%.4f", matrix[n]); + //sprintf(buffer, "%.8x", (int)(matrix[n]*4096)); + SetWindowText(GetDlgItem(hwnd, idcs[n]), buffer); + } +} + +void MatrixView_OnPaintPositionMatrix(HWND hwnd) +{ + // IDC for each matrix coefficient + const int idcGroup[16] = + { + IDC_MATRIX_VIEWER_COORD_11_EDIT, IDC_MATRIX_VIEWER_COORD_12_EDIT, IDC_MATRIX_VIEWER_COORD_13_EDIT, IDC_MATRIX_VIEWER_COORD_14_EDIT, + IDC_MATRIX_VIEWER_COORD_21_EDIT, IDC_MATRIX_VIEWER_COORD_22_EDIT, IDC_MATRIX_VIEWER_COORD_23_EDIT, IDC_MATRIX_VIEWER_COORD_24_EDIT, + IDC_MATRIX_VIEWER_COORD_31_EDIT, IDC_MATRIX_VIEWER_COORD_32_EDIT, IDC_MATRIX_VIEWER_COORD_33_EDIT, IDC_MATRIX_VIEWER_COORD_34_EDIT, + IDC_MATRIX_VIEWER_COORD_41_EDIT, IDC_MATRIX_VIEWER_COORD_42_EDIT, IDC_MATRIX_VIEWER_COORD_43_EDIT, IDC_MATRIX_VIEWER_COORD_44_EDIT + }; + + float matrix[16]; + HWND hStackCombo = GetDlgItem(hwnd, IDC_MATRIX_VIEWER_COORD_COMBO); + int stackIndex; + + stackIndex = SendMessage(hStackCombo, CB_GETCURSEL, 0, 0) - 1; + + gfx3d_glGetMatrix(1, stackIndex, matrix); + MatrixView_SetMatrix(hwnd, idcGroup, matrix); +} + +////////////////////////////////////////////////////////////////////////////// + +void MatrixView_OnPaintDirectionMatrix(HWND hwnd) +{ + // IDC for each matrix coefficient + const int idcGroup[16] = + { + IDC_MATRIX_VIEWER_DIR_11_EDIT, IDC_MATRIX_VIEWER_DIR_12_EDIT, IDC_MATRIX_VIEWER_DIR_13_EDIT, IDC_MATRIX_VIEWER_DIR_14_EDIT, + IDC_MATRIX_VIEWER_DIR_21_EDIT, IDC_MATRIX_VIEWER_DIR_22_EDIT, IDC_MATRIX_VIEWER_DIR_23_EDIT, IDC_MATRIX_VIEWER_DIR_24_EDIT, + IDC_MATRIX_VIEWER_DIR_31_EDIT, IDC_MATRIX_VIEWER_DIR_32_EDIT, IDC_MATRIX_VIEWER_DIR_33_EDIT, IDC_MATRIX_VIEWER_DIR_34_EDIT, + IDC_MATRIX_VIEWER_DIR_41_EDIT, IDC_MATRIX_VIEWER_DIR_42_EDIT, IDC_MATRIX_VIEWER_DIR_43_EDIT, IDC_MATRIX_VIEWER_DIR_44_EDIT + }; + + float matrix[16]; + HWND hStackCombo = GetDlgItem(hwnd, IDC_MATRIX_VIEWER_DIR_COMBO); + int stackIndex; + + stackIndex = SendMessage(hStackCombo, CB_GETCURSEL, 0, 0) - 1; + + gfx3d_glGetMatrix(2, stackIndex, matrix); + MatrixView_SetMatrix(hwnd, idcGroup, matrix); +} + +////////////////////////////////////////////////////////////////////////////// + +void MatrixView_OnPaintProjectionMatrix(HWND hwnd) +{ + // IDC for each matrix coefficient + const int idcGroup[16] = + { + IDC_MATRIX_VIEWER_PROJ_11_EDIT, IDC_MATRIX_VIEWER_PROJ_12_EDIT, IDC_MATRIX_VIEWER_PROJ_13_EDIT, IDC_MATRIX_VIEWER_PROJ_14_EDIT, + IDC_MATRIX_VIEWER_PROJ_21_EDIT, IDC_MATRIX_VIEWER_PROJ_22_EDIT, IDC_MATRIX_VIEWER_PROJ_23_EDIT, IDC_MATRIX_VIEWER_PROJ_24_EDIT, + IDC_MATRIX_VIEWER_PROJ_31_EDIT, IDC_MATRIX_VIEWER_PROJ_32_EDIT, IDC_MATRIX_VIEWER_PROJ_33_EDIT, IDC_MATRIX_VIEWER_PROJ_34_EDIT, + IDC_MATRIX_VIEWER_PROJ_41_EDIT, IDC_MATRIX_VIEWER_PROJ_42_EDIT, IDC_MATRIX_VIEWER_PROJ_43_EDIT, IDC_MATRIX_VIEWER_PROJ_44_EDIT + }; + + float mat[16]; + + gfx3d_glGetMatrix(0, -1, mat); + MatrixView_SetMatrix(hwnd, idcGroup, mat); +} + +////////////////////////////////////////////////////////////////////////////// + +void MatrixView_OnPaintTextureMatrix(HWND hwnd) +{ + // IDC for each matrix coefficient + const int idcGroup[16] = + { + IDC_MATRIX_VIEWER_TEX_11_EDIT, IDC_MATRIX_VIEWER_TEX_12_EDIT, IDC_MATRIX_VIEWER_TEX_13_EDIT, IDC_MATRIX_VIEWER_TEX_14_EDIT, + IDC_MATRIX_VIEWER_TEX_21_EDIT, IDC_MATRIX_VIEWER_TEX_22_EDIT, IDC_MATRIX_VIEWER_TEX_23_EDIT, IDC_MATRIX_VIEWER_TEX_24_EDIT, + IDC_MATRIX_VIEWER_TEX_31_EDIT, IDC_MATRIX_VIEWER_TEX_32_EDIT, IDC_MATRIX_VIEWER_TEX_33_EDIT, IDC_MATRIX_VIEWER_TEX_34_EDIT, + IDC_MATRIX_VIEWER_TEX_41_EDIT, IDC_MATRIX_VIEWER_TEX_42_EDIT, IDC_MATRIX_VIEWER_TEX_43_EDIT, IDC_MATRIX_VIEWER_TEX_44_EDIT + }; + + float mat[16]; + + gfx3d_glGetMatrix(3, -1, mat); + MatrixView_SetMatrix(hwnd, idcGroup, mat); +} + +BOOL MatrixView_OnPaint( HWND hwnd, WPARAM wParam, LPARAM lParam) +{ + HDC hdc; + PAINTSTRUCT ps; + + hdc = BeginPaint(hwnd, &ps); + + MatrixView_OnPaintProjectionMatrix(hwnd); + MatrixView_OnPaintPositionMatrix(hwnd); + MatrixView_OnPaintDirectionMatrix(hwnd); + MatrixView_OnPaintTextureMatrix(hwnd); + + EndPaint(hwnd, &ps); + + return TRUE; +} + +BOOL CALLBACK ViewMatricesProc (HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam) +{ + switch (message) + { + case WM_INITDIALOG: + { + MatrixView = new matrixview_struct; + memset(MatrixView, 0, sizeof(matrixview_struct)); + MatrixView->autoup_secs = 1; + SendMessage(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SPIN), + UDM_SETRANGE, 0, MAKELONG(99, 1)); + SendMessage(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SPIN), + UDM_SETPOS32, 0, MatrixView->autoup_secs); + int n; + HWND hPosCombo = GetDlgItem(hwnd, IDC_MATRIX_VIEWER_COORD_COMBO); + HWND hDirCombo = GetDlgItem(hwnd, IDC_MATRIX_VIEWER_DIR_COMBO); + + // Setup position and direction matrix comboboxes with stack indices + SendMessage(hPosCombo, CB_ADDSTRING, 0,(LPARAM)"Current"); + SendMessage(hDirCombo, CB_ADDSTRING, 0,(LPARAM)"Current"); + + for(n = 0; n < 32; n++) + { + char buffer[4]; + + sprintf(buffer, "%d", n); + SendMessage(hPosCombo, CB_ADDSTRING, 0,(LPARAM)buffer); + SendMessage(hDirCombo, CB_ADDSTRING, 0,(LPARAM)buffer); + } + + SendMessage(hPosCombo, CB_SETCURSEL, 0, 0); + SendMessage(hDirCombo, CB_SETCURSEL, 0, 0); + return 1; + } + + case WM_CLOSE: + { + if(MatrixView->autoup) + { + KillTimer(hwnd, IDT_VIEW_MATRIX); + MatrixView->autoup = false; + } + + if (MatrixView!=NULL) + { + delete MatrixView; + MatrixView = NULL; + } + //INFO("Close Matrix view dialog\n"); + PostQuitMessage(0); + return 0; + } + + case WM_PAINT: + MatrixView_OnPaint(hwnd, wParam, lParam); + return 1; + case WM_TIMER: + SendMessage(hwnd, WM_COMMAND, IDC_REFRESH, 0); + return 1; + + case WM_COMMAND: + switch (LOWORD (wParam)) + { + case IDOK: + SendMessage(hwnd, WM_CLOSE, 0, 0); + return 1; + + case IDC_AUTO_UPDATE : + if(MatrixView->autoup) + { + EnableWindow(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SECS), false); + EnableWindow(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SPIN), false); + KillTimer(hwnd, IDT_VIEW_MATRIX); + MatrixView->autoup = FALSE; + return 1; + } + EnableWindow(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SECS), true); + EnableWindow(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SPIN), true); + MatrixView->autoup = TRUE; + SetTimer(hwnd, IDT_VIEW_MATRIX, MatrixView->autoup_secs*20, (TIMERPROC) NULL); + return 1; + case IDC_AUTO_UPDATE_SECS: + { + int t = GetDlgItemInt(hwnd, IDC_AUTO_UPDATE_SECS, FALSE, TRUE); + if (!MatrixView) + { + SendMessage(hwnd, WM_INITDIALOG, 0, 0); + } + if (t != MatrixView->autoup_secs) + { + MatrixView->autoup_secs = t; + if (MatrixView->autoup) + SetTimer(hwnd, IDT_VIEW_MATRIX, + MatrixView->autoup_secs*20, (TIMERPROC) NULL); + } + } + return 1; + case IDC_REFRESH: + InvalidateRect(hwnd, NULL, FALSE); + return 1; + + case IDC_MATRIX_VIEWER_DIR_COMBO: + case IDC_MATRIX_VIEWER_COORD_COMBO: + InvalidateRect(hwnd, NULL, FALSE); + return 1; + } + return 0; + } + + return false; +} diff --git a/desmume/src/windows/matrixView.h b/src/windows/matrixView.h similarity index 96% rename from desmume/src/windows/matrixView.h rename to src/windows/matrixView.h index fb3480061..6f5f16c91 100644 --- a/desmume/src/windows/matrixView.h +++ b/src/windows/matrixView.h @@ -1,27 +1,27 @@ -/* Copyright (C) 2007 Acid Burn - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#ifndef MATRIXVIEW_H -#define MATRIXVIEW_H - -#include "../common.h" - -extern BOOL CALLBACK ViewMatricesProc (HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam); - +/* Copyright (C) 2007 Acid Burn + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#ifndef MATRIXVIEW_H +#define MATRIXVIEW_H + +#include "../common.h" + +extern BOOL CALLBACK ViewMatricesProc (HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam); + #endif \ No newline at end of file diff --git a/desmume/src/windows/memView.cpp b/src/windows/memView.cpp similarity index 95% rename from desmume/src/windows/memView.cpp rename to src/windows/memView.cpp index d7d794cb3..5e3dde0e3 100644 --- a/desmume/src/windows/memView.cpp +++ b/src/windows/memView.cpp @@ -1,813 +1,813 @@ -/* Copyright (C) 2006 yopyop - yopyop156@ifrance.com - yopyop156.ifrance.com - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - - -#include "../MMU.h" -#include "debug.h" -#include "resource.h" -#include "common.h" -#include -#include -#include -#include -#include "memView.h" - -using namespace std; - -////////////////////////////////////////////////////////////////////////////// - -typedef struct MemView_DataStruct -{ - MemView_DataStruct(u8 CPU) : cpu(CPU), address(0x02000000), viewMode(0), sel(FALSE), selPart(0), selAddress(0x00000000), selNewVal(0x000000000) - { - } - - HWND hDlg; - - u8 cpu; - u32 address; - u8 viewMode; - - BOOL sel; - u8 selPart; - u32 selAddress; - u32 selNewVal; -} MemView_DataStruct; - -MemView_DataStruct * MemView_Data[2] = {NULL, NULL}; - -////////////////////////////////////////////////////////////////////////////// - -BOOL MemView_Init() -{ - WNDCLASSEX wc; - - wc.cbSize = sizeof(wc); - wc.lpszClassName = "MemView_ViewBox"; - wc.hInstance = hAppInst; - wc.lpfnWndProc = MemView_ViewBoxProc; - wc.hCursor = LoadCursor(NULL, IDC_ARROW); - wc.hIcon = 0; - wc.lpszMenuName = 0; - wc.hbrBackground = GetSysColorBrush(COLOR_BTNFACE); - wc.style = 0; - wc.cbClsExtra = 0; - wc.cbWndExtra = sizeof(MemView_DataStruct); - wc.hIconSm = 0; - - RegisterClassEx(&wc); - - return 1; -} - -void MemView_DeInit() -{ - UnregisterClass("MemView_ViewBox", hAppInst); -} - -////////////////////////////////////////////////////////////////////////////// - -BOOL MemView_DlgOpen(HWND hParentWnd, char *Title, u8 CPU) -{ - HWND hDlg; - - MemView_Data[CPU] = new MemView_DataStruct(CPU); - if(MemView_Data[CPU] == NULL) - return 0; - - hDlg = CreateDialogParam(hAppInst, MAKEINTRESOURCE(IDD_MEM_VIEW), hParentWnd, MemView_DlgProc, (LPARAM)MemView_Data[CPU]); - if(hDlg == NULL) - { - delete MemView_Data[CPU]; - MemView_Data[CPU] = NULL; - return 0; - } - - MemView_Data[CPU]->hDlg = hDlg; - - SetWindowText(hDlg, Title); - - ShowWindow(hDlg, SW_SHOW); - UpdateWindow(hDlg); - - return 1; -} - -void MemView_DlgClose(u8 CPU) -{ - if(MemView_Data[CPU] != NULL) - { - DestroyWindow(MemView_Data[CPU]->hDlg); - delete MemView_Data[CPU]; - MemView_Data[CPU] = NULL; - } -} - -BOOL MemView_IsOpened(u8 CPU) -{ - return (MemView_Data[CPU] != NULL); -} - -void MemView_Refresh(u8 CPU) -{ - InvalidateRect(MemView_Data[CPU]->hDlg, NULL, FALSE); - UpdateWindow(MemView_Data[CPU]->hDlg); -} - -////////////////////////////////////////////////////////////////////////////// - -LRESULT MemView_DlgPaint(HWND hDlg, MemView_DataStruct *data, WPARAM wParam, LPARAM lParam) -{ - HDC hdc; - PAINTSTRUCT ps; - - hdc = BeginPaint(hDlg, &ps); - - EndPaint(hDlg, &ps); - - return 0; -} - -BOOL CALLBACK MemView_DlgProc(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam) -{ - MemView_DataStruct *data = (MemView_DataStruct*)GetWindowLong(hDlg, DWL_USER); - if((data == NULL) && (uMsg != WM_INITDIALOG)) - return 0; - - switch(uMsg) - { - case WM_INITDIALOG: - { - if(data == NULL) - { - data = (MemView_DataStruct*)lParam; - SetWindowLong(hDlg, DWL_USER, (LONG)data); - } - - CheckRadioButton(hDlg, IDC_8_BIT, IDC_32_BIT, IDC_8_BIT); - - SendMessage(GetDlgItem(hDlg, IDC_ADDRESS), EM_SETLIMITTEXT, 8, 0); - SetWindowText(GetDlgItem(hDlg, IDC_ADDRESS), "02000000"); - - SetWindowLong(GetDlgItem(hDlg, IDC_MEMVIEWBOX), DWL_USER, (LONG)data); - - InvalidateRect(hDlg, NULL, FALSE); UpdateWindow(hDlg); - } - return 1; - - case WM_CLOSE: - case WM_DESTROY: - MemView_DlgClose(data->cpu); - return 1; - - case WM_PAINT: - MemView_DlgPaint(hDlg, data, wParam, lParam); - return 1; - - case WM_COMMAND: - switch(LOWORD(wParam)) - { - case IDCANCEL: - MemView_DlgClose(data->cpu); - return 1; - - case IDC_8_BIT: - case IDC_16_BIT: - case IDC_32_BIT: - data->sel = FALSE; - data->selAddress = 0x00000000; - data->selPart = 0; - data->selNewVal = 0x00000000; - CheckRadioButton(hDlg, IDC_8_BIT, IDC_32_BIT, LOWORD(wParam)); - data->viewMode = (LOWORD(wParam) - IDC_8_BIT); - InvalidateRect(hDlg, NULL, FALSE); UpdateWindow(hDlg); - return 1; - - case IDC_GO: - { - char addrstr[9]; - int len; - int i; - int shift; - BOOL error = FALSE; - u32 address = 0x00000000; - - len = GetWindowText(GetDlgItem(hDlg, IDC_ADDRESS), addrstr, 9); - - for(i = 0; i < len; i++) - { - char ch = addrstr[i]; - - if((ch >= '0') && (ch <= '9')) - continue; - - if((ch >= 'A') && (ch <= 'F')) - continue; - - if((ch >= 'a') && (ch <= 'f')) - continue; - - if(ch == '\0') - break; - - error = TRUE; - break; - } - - if(error) - { - MessageBox(hDlg, "Error:\nInvalid address specified.\nThe address must be an hexadecimal value.", "DeSmuME", (MB_OK | MB_ICONERROR)); - SetWindowText(GetDlgItem(hDlg, IDC_ADDRESS), ""); - return 1; - } - - for(i = (len-1), shift = 0; i >= 0; i--, shift += 4) - { - char ch = addrstr[i]; - - if((ch >= '0') && (ch <= '9')) - address |= ((ch - '0') << shift); - else if((ch >= 'A') && (ch <= 'F')) - address |= ((ch - 'A' + 0xA) << shift); - else if((ch >= 'a') && (ch <= 'f')) - address |= ((ch - 'a' + 0xA) << shift); - } - - data->sel = FALSE; - data->selAddress = 0x00000000; - data->selPart = 0; - data->selNewVal = 0x00000000; - - data->address = min((u32)0xFFFFFF00, (address & 0xFFFFFFF0)); - SetScrollPos(GetDlgItem(hDlg, IDC_MEMVIEWBOX), SB_VERT, ((data->address >> 4) & 0x000FFFFF), TRUE); - InvalidateRect(hDlg, NULL, FALSE); UpdateWindow(hDlg); - } - return 1; - - case IDC_TEXTDUMP: - { - char fileName[256] = ""; - OPENFILENAME ofn; - - ZeroMemory(&ofn, sizeof(ofn)); - ofn.lStructSize = sizeof(ofn); - ofn.hwndOwner = hDlg; - ofn.lpstrFilter = "Text file (*.txt)\0*.txt\0Any file (*.*)\0*.*\0\0"; - ofn.nFilterIndex = 1; - ofn.lpstrFile = fileName; - ofn.nMaxFile = 256; - ofn.lpstrDefExt = "txt"; - ofn.Flags = OFN_NOCHANGEDIR; - - if(GetSaveFileName(&ofn)) - { - FILE *f; - u8 memory[0x100]; - int line; - - MMU_DumpMemBlock(data->cpu, data->address, 0x100, memory); - - f = fopen(fileName, "a"); - - for(line = 0; line < 16; line++) - { - int i; - - fprintf(f, "%08X\t\t", (data->address + (line << 4))); - - switch(data->viewMode) - { - case 0: - { - for(i = 0; i < 16; i++) - { - fprintf(f, "%02X ", T1ReadByte(memory, ((line << 4) + i))); - } - fprintf(f, "\t"); - } - break; - - case 1: - { - for(i = 0; i < 16; i += 2) - { - fprintf(f, "%04X ", T1ReadWord(memory, ((line << 4) + i))); - } - fprintf(f, "\t\t"); - } - break; - - case 2: - { - for(i = 0; i < 16; i += 4) - { - fprintf(f, "%08X ", T1ReadLong(memory, ((line << 4) + i))); - } - fprintf(f, "\t\t\t"); - } - break; - } - - for(i = 0; i < 16; i++) - { - u8 val = T1ReadByte(memory, ((line << 4) + i)); - - if((val >= 32) && (val <= 127)) - fprintf(f, "%c", (char)val); - else - fprintf(f, "."); - } - fprintf(f, "\n"); - } - - fclose(f); - } - } - return 1; - - case IDC_RAWDUMP: - { - char fileName[256] = ""; - OPENFILENAME ofn; - - ZeroMemory(&ofn, sizeof(ofn)); - ofn.lStructSize = sizeof(ofn); - ofn.hwndOwner = hDlg; - ofn.lpstrFilter = "Binary file (*.bin)\0*.bin\0Any file (*.*)\0*.*\0\0"; - ofn.nFilterIndex = 1; - ofn.lpstrFile = fileName; - ofn.nMaxFile = 256; - ofn.lpstrDefExt = "bin"; - ofn.Flags = OFN_NOCHANGEDIR; - - if(GetSaveFileName(&ofn)) - { - FILE *f; - u8 memory[0x100]; - int line; - - MMU_DumpMemBlock(data->cpu, data->address, 0x100, memory); - - f = fopen(fileName, "ab"); - - fwrite(memory, 0x100, 1, f); - - fclose(f); - } - } - return 1; - } - return 0; - } - - return 0; -} - -////////////////////////////////////////////////////////////////////////////// - -LRESULT MemView_ViewBoxPaint(HWND hCtl, MemView_DataStruct *data, WPARAM wParam, LPARAM lParam) -{ - HDC hdc; - PAINTSTRUCT ps; - RECT rc; - int w, h; - SIZE fontsize; - int fontwidth, fontheight; - HDC mem_hdc; - HBITMAP mem_bmp; - - GetClientRect(hCtl, &rc); - w = (rc.right - rc.left); - h = (rc.bottom - rc.top); - - hdc = BeginPaint(hCtl, &ps); - - mem_hdc = CreateCompatibleDC(hdc); - mem_bmp = CreateCompatibleBitmap(hdc, w, h); - SelectObject(mem_hdc, mem_bmp); - - SelectObject(mem_hdc, GetStockObject(SYSTEM_FIXED_FONT)); - - SetBkMode(mem_hdc, OPAQUE); - SetBkColor(mem_hdc, RGB(255, 255, 255)); - SetTextColor(mem_hdc, RGB(0, 0, 0)); - - GetTextExtentPoint32(mem_hdc, " ", 1, &fontsize); - fontwidth = fontsize.cx; - fontheight = fontsize.cy; - - FillRect(mem_hdc, &rc, (HBRUSH)GetStockObject(WHITE_BRUSH)); - - if(data != NULL) - { - u32 addr = data->address; - u8 memory[0x100]; - char text[80]; - int startx; - int curx, cury; - int line; - - startx = 0; - curx = 0; - cury = 0; - - startx = ((fontwidth * 8) + 5); - cury = (fontheight + 3); - - MoveToEx(mem_hdc, ((fontwidth * 8) + 2), 0, NULL); - LineTo(mem_hdc, ((fontwidth * 8) + 2), h); - - MoveToEx(mem_hdc, 0, (fontheight + 1), NULL); - LineTo(mem_hdc, w, (fontheight + 1)); - - switch(data->viewMode) - { - case 0: - { - sprintf(text, " 0 1 2 3 4 5 6 7 8 9 A B C D E F 0123456789ABCDEF"); - TextOut(mem_hdc, startx, 0, text, strlen(text)); - } - break; - - case 1: - { - sprintf(text, " 0 1 2 3 4 5 6 7 8 9 A B C D E F 0123456789ABCDEF"); - TextOut(mem_hdc, startx, 0, text, strlen(text)); - } - break; - - case 2: - { - sprintf(text, " 0 1 2 3 4 5 6 7 8 9 A B C D E F 0123456789ABCDEF"); - TextOut(mem_hdc, startx, 0, text, strlen(text)); - } - break; - } - - MMU_DumpMemBlock(data->cpu, data->address, 0x100, memory); - - for(line = 0; line < 16; line++, addr += 0x10) - { - int i; - - sprintf(text, "%08X", addr); - TextOut(mem_hdc, 0, cury, text, strlen(text)); - - curx = startx; - - switch(data->viewMode) - { - case 0: - { - curx += (fontwidth * 2); - for(i = 0; i < 16; i++) - { - u8 val = T1ReadByte(memory, ((line << 4) + i)); - if(data->sel && (data->selAddress == (addr + i))) - { - SetBkColor(mem_hdc, GetSysColor(COLOR_HIGHLIGHT)); - SetTextColor(mem_hdc, GetSysColor(COLOR_HIGHLIGHTTEXT)); - - switch(data->selPart) - { - case 0: sprintf(text, "%02X", val); break; - case 1: sprintf(text, "%01X.", data->selNewVal); break; - } - } - else - { - SetBkColor(mem_hdc, RGB(255, 255, 255)); - SetTextColor(mem_hdc, RGB(0, 0, 0)); - - sprintf(text, "%02X", val); - } - - TextOut(mem_hdc, curx, cury, text, strlen(text)); - curx += (fontwidth * (2+1)); - } - curx += (fontwidth * 2); - } - break; - - case 1: - { - curx += (fontwidth * 6); - for(i = 0; i < 16; i += 2) - { - u16 val = T1ReadWord(memory, ((line << 4) + i)); - if(data->sel && (data->selAddress == (addr + i))) - { - SetBkColor(mem_hdc, GetSysColor(COLOR_HIGHLIGHT)); - SetTextColor(mem_hdc, GetSysColor(COLOR_HIGHLIGHTTEXT)); - - switch(data->selPart) - { - case 0: sprintf(text, "%04X", val); break; - case 1: sprintf(text, "%01X...", data->selNewVal); break; - case 2: sprintf(text, "%02X..", data->selNewVal); break; - case 3: sprintf(text, "%03X.", data->selNewVal); break; - } - } - else - { - SetBkColor(mem_hdc, RGB(255, 255, 255)); - SetTextColor(mem_hdc, RGB(0, 0, 0)); - - sprintf(text, "%04X", val); - } - - TextOut(mem_hdc, curx, cury, text, strlen(text)); - curx += (fontwidth * (4+1)); - } - curx += (fontwidth * 6); - } - break; - - case 2: - { - curx += (fontwidth * 8); - for(i = 0; i < 16; i += 4) - { - u32 val = T1ReadLong(memory, ((line << 4) + i)); - if(data->sel && (data->selAddress == (addr + i))) - { - SetBkColor(mem_hdc, GetSysColor(COLOR_HIGHLIGHT)); - SetTextColor(mem_hdc, GetSysColor(COLOR_HIGHLIGHTTEXT)); - - switch(data->selPart) - { - case 0: sprintf(text, "%08X", val); break; - case 1: sprintf(text, "%01X.......", data->selNewVal); break; - case 2: sprintf(text, "%02X......", data->selNewVal); break; - case 3: sprintf(text, "%03X.....", data->selNewVal); break; - case 4: sprintf(text, "%04X....", data->selNewVal); break; - case 5: sprintf(text, "%05X...", data->selNewVal); break; - case 6: sprintf(text, "%06X..", data->selNewVal); break; - case 7: sprintf(text, "%07X.", data->selNewVal); break; - } - } - else - { - SetBkColor(mem_hdc, RGB(255, 255, 255)); - SetTextColor(mem_hdc, RGB(0, 0, 0)); - - sprintf(text, "%08X", val); - } - - TextOut(mem_hdc, curx, cury, text, strlen(text)); - curx += (fontwidth * (8+1)); - } - curx += (fontwidth * 8); - } - break; - } - - SetBkColor(mem_hdc, RGB(255, 255, 255)); - SetTextColor(mem_hdc, RGB(0, 0, 0)); - - for(i = 0; i < 16; i++) - { - u8 val = T1ReadByte(memory, ((line << 4) + i)); - - if((val >= 32) && (val <= 127)) - text[i] = (char)val; - else - text[i] = '.'; - } - text[16] = '\0'; - TextOut(mem_hdc, curx, cury, text, strlen(text)); - - cury += fontheight; - } - } - - BitBlt(hdc, 0, 0, w, h, mem_hdc, 0, 0, SRCCOPY); - - DeleteDC(mem_hdc); - DeleteObject(mem_bmp); - - EndPaint(hCtl, &ps); - - return 0; -} - -LRESULT CALLBACK MemView_ViewBoxProc(HWND hCtl, UINT uMsg, WPARAM wParam, LPARAM lParam) -{ - MemView_DataStruct *data = (MemView_DataStruct*)GetWindowLong(hCtl, DWL_USER); - - switch(uMsg) - { - case WM_NCCREATE: - SetScrollRange(hCtl, SB_VERT, 0x00000000, 0x000FFFF0, TRUE); - SetScrollPos(hCtl, SB_VERT, 0x00000000, TRUE); - return 1; - - case WM_NCDESTROY: - return 1; - - case WM_ERASEBKGND: - return 1; - - case WM_PAINT: - MemView_ViewBoxPaint(hCtl, data, wParam, lParam); - return 1; - - case WM_LBUTTONDOWN: - { - HDC hdc; - HFONT font; - SIZE fontsize; - int x, y; - - data->sel = FALSE; - data->selAddress = 0x00000000; - data->selPart = 0; - data->selNewVal = 0x00000000; - - hdc = GetDC(hCtl); - font = (HFONT)SelectObject(hdc, GetStockObject(SYSTEM_FIXED_FONT)); - GetTextExtentPoint32(hdc, " ", 1, &fontsize); - - x = LOWORD(lParam); - y = HIWORD(lParam); - - if((x >= ((fontsize.cx * 8) + 5)) && (y >= (fontsize.cy + 3))) - { - int line, col; - - x -= ((fontsize.cx * 8) + 5); - y -= (fontsize.cy + 3); - - line = (y / fontsize.cy); - - switch(data->viewMode) - { - case 0: - { - if((x < (fontsize.cx * 2)) || (x >= (fontsize.cx * (2 + ((2+1) * 16))))) - break; - - col = ((x - (fontsize.cx * 2)) / (fontsize.cx * (2+1))); - - data->sel = TRUE; - - } - break; - - case 1: - { - if((x < (fontsize.cx * 6)) || (x >= (fontsize.cx * (6 + ((4+1) * 8))))) - break; - - col = ((x - (fontsize.cx * 6)) / (fontsize.cx * (4+1)) * 2); - - data->sel = TRUE; - - } - break; - - case 2: - { - if((x < (fontsize.cx * 8)) || (x >= (fontsize.cx * (8 + ((8+1) * 4))))) - break; - - col = ((x - (fontsize.cx * 8)) / (fontsize.cx * (8+1)) * 4); - - data->sel = TRUE; - - } - break; - } - - data->selAddress = (data->address + (line << 4) + col); - data->selPart = 0; - data->selNewVal = 0x00000000; - } - - SelectObject(hdc, font); - ReleaseDC(hCtl, hdc); - - SetFocus(hCtl); /* Required to receive keyboard messages */ - InvalidateRect(hCtl, NULL, FALSE); UpdateWindow(hCtl); - } - return 1; - - case WM_CHAR: - { - char ch = (char)wParam; - - if(((ch >= '0') && (ch <= '9')) || ((ch >= 'A') && (ch <= 'F')) || ((ch >= 'a') && (ch <= 'f'))) - { - u8 maxSelPart[3] = {2, 4, 8}; - - data->selNewVal <<= 4; - data->selPart++; - - if((ch >= '0') && (ch <= '9')) - data->selNewVal |= (ch - '0'); - else if((ch >= 'A') && (ch <= 'F')) - data->selNewVal |= (ch - 'A' + 0xA); - else if((ch >= 'a') && (ch <= 'f')) - data->selNewVal |= (ch - 'a' + 0xA); - - if(data->selPart >= maxSelPart[data->viewMode]) - { - switch(data->viewMode) - { - case 0: MMU_write8(data->cpu, data->selAddress, (u8)data->selNewVal); data->selAddress++; break; - case 1: MMU_write16(data->cpu, data->selAddress, (u16)data->selNewVal); data->selAddress += 2; break; - case 2: MMU_write32(data->cpu, data->selAddress, data->selNewVal); data->selAddress += 4; break; - } - data->selPart = 0; - data->selNewVal = 0x00000000; - - if(data->selAddress == 0x00000000) - { - data->sel = FALSE; - } - else if(data->selAddress >= (data->address + 0x100)) - { - data->address = min((u32)0xFFFFFF00, (data->address + 0x10)); - SetScrollPos(hCtl, SB_VERT, ((data->address >> 4) & 0x000FFFFF), TRUE); - } - } - } - - InvalidateRect(hCtl, NULL, FALSE); UpdateWindow(hCtl); - } - return 1; - - case WM_VSCROLL: - { - int firstpos = GetScrollPos(hCtl, SB_VERT); - - switch(LOWORD(wParam)) - { - case SB_LINEUP: - data->address = (u32)max(0x00000000, ((int)data->address - 0x10)); - break; - - case SB_LINEDOWN: - data->address = min((u32)0xFFFFFF00, (data->address + 0x10)); - break; - - case SB_PAGEUP: - data->address = (u32)max(0x00000000, ((int)data->address - 0x100)); - break; - - case SB_PAGEDOWN: - data->address = min((u32)0xFFFFFF00, (data->address + 0x100)); - break; - - case SB_THUMBTRACK: - case SB_THUMBPOSITION: - { - SCROLLINFO si; - - ZeroMemory(&si, sizeof(si)); - si.cbSize = sizeof(si); - si.fMask = SIF_TRACKPOS; - - GetScrollInfo(hCtl, SB_VERT, &si); - - data->address = min((u32)0xFFFFFF00, (data->address + ((si.nTrackPos - firstpos) * 16))); - } - break; - } - - if((data->selAddress < data->address) || (data->selAddress >= (data->address + 0x100))) - { - data->sel = FALSE; - data->selAddress = 0x00000000; - data->selPart = 0; - data->selNewVal = 0x00000000; - } - - SetScrollPos(hCtl, SB_VERT, ((data->address >> 4) & 0x000FFFFF), TRUE); - InvalidateRect(hCtl, NULL, FALSE); UpdateWindow(hCtl); - } - return 1; - } - - return DefWindowProc(hCtl, uMsg, wParam, lParam); -} - -////////////////////////////////////////////////////////////////////////////// +/* Copyright (C) 2006 yopyop + yopyop156@ifrance.com + yopyop156.ifrance.com + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + + +#include "../MMU.h" +#include "debug.h" +#include "resource.h" +#include "common.h" +#include +#include +#include +#include +#include "memView.h" + +using namespace std; + +////////////////////////////////////////////////////////////////////////////// + +typedef struct MemView_DataStruct +{ + MemView_DataStruct(u8 CPU) : cpu(CPU), address(0x02000000), viewMode(0), sel(FALSE), selPart(0), selAddress(0x00000000), selNewVal(0x000000000) + { + } + + HWND hDlg; + + u8 cpu; + u32 address; + u8 viewMode; + + BOOL sel; + u8 selPart; + u32 selAddress; + u32 selNewVal; +} MemView_DataStruct; + +MemView_DataStruct * MemView_Data[2] = {NULL, NULL}; + +////////////////////////////////////////////////////////////////////////////// + +BOOL MemView_Init() +{ + WNDCLASSEX wc; + + wc.cbSize = sizeof(wc); + wc.lpszClassName = "MemView_ViewBox"; + wc.hInstance = hAppInst; + wc.lpfnWndProc = MemView_ViewBoxProc; + wc.hCursor = LoadCursor(NULL, IDC_ARROW); + wc.hIcon = 0; + wc.lpszMenuName = 0; + wc.hbrBackground = GetSysColorBrush(COLOR_BTNFACE); + wc.style = 0; + wc.cbClsExtra = 0; + wc.cbWndExtra = sizeof(MemView_DataStruct); + wc.hIconSm = 0; + + RegisterClassEx(&wc); + + return 1; +} + +void MemView_DeInit() +{ + UnregisterClass("MemView_ViewBox", hAppInst); +} + +////////////////////////////////////////////////////////////////////////////// + +BOOL MemView_DlgOpen(HWND hParentWnd, char *Title, u8 CPU) +{ + HWND hDlg; + + MemView_Data[CPU] = new MemView_DataStruct(CPU); + if(MemView_Data[CPU] == NULL) + return 0; + + hDlg = CreateDialogParam(hAppInst, MAKEINTRESOURCE(IDD_MEM_VIEW), hParentWnd, MemView_DlgProc, (LPARAM)MemView_Data[CPU]); + if(hDlg == NULL) + { + delete MemView_Data[CPU]; + MemView_Data[CPU] = NULL; + return 0; + } + + MemView_Data[CPU]->hDlg = hDlg; + + SetWindowText(hDlg, Title); + + ShowWindow(hDlg, SW_SHOW); + UpdateWindow(hDlg); + + return 1; +} + +void MemView_DlgClose(u8 CPU) +{ + if(MemView_Data[CPU] != NULL) + { + DestroyWindow(MemView_Data[CPU]->hDlg); + delete MemView_Data[CPU]; + MemView_Data[CPU] = NULL; + } +} + +BOOL MemView_IsOpened(u8 CPU) +{ + return (MemView_Data[CPU] != NULL); +} + +void MemView_Refresh(u8 CPU) +{ + InvalidateRect(MemView_Data[CPU]->hDlg, NULL, FALSE); + UpdateWindow(MemView_Data[CPU]->hDlg); +} + +////////////////////////////////////////////////////////////////////////////// + +LRESULT MemView_DlgPaint(HWND hDlg, MemView_DataStruct *data, WPARAM wParam, LPARAM lParam) +{ + HDC hdc; + PAINTSTRUCT ps; + + hdc = BeginPaint(hDlg, &ps); + + EndPaint(hDlg, &ps); + + return 0; +} + +BOOL CALLBACK MemView_DlgProc(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam) +{ + MemView_DataStruct *data = (MemView_DataStruct*)GetWindowLong(hDlg, DWL_USER); + if((data == NULL) && (uMsg != WM_INITDIALOG)) + return 0; + + switch(uMsg) + { + case WM_INITDIALOG: + { + if(data == NULL) + { + data = (MemView_DataStruct*)lParam; + SetWindowLong(hDlg, DWL_USER, (LONG)data); + } + + CheckRadioButton(hDlg, IDC_8_BIT, IDC_32_BIT, IDC_8_BIT); + + SendMessage(GetDlgItem(hDlg, IDC_ADDRESS), EM_SETLIMITTEXT, 8, 0); + SetWindowText(GetDlgItem(hDlg, IDC_ADDRESS), "02000000"); + + SetWindowLong(GetDlgItem(hDlg, IDC_MEMVIEWBOX), DWL_USER, (LONG)data); + + InvalidateRect(hDlg, NULL, FALSE); UpdateWindow(hDlg); + } + return 1; + + case WM_CLOSE: + case WM_DESTROY: + MemView_DlgClose(data->cpu); + return 1; + + case WM_PAINT: + MemView_DlgPaint(hDlg, data, wParam, lParam); + return 1; + + case WM_COMMAND: + switch(LOWORD(wParam)) + { + case IDCANCEL: + MemView_DlgClose(data->cpu); + return 1; + + case IDC_8_BIT: + case IDC_16_BIT: + case IDC_32_BIT: + data->sel = FALSE; + data->selAddress = 0x00000000; + data->selPart = 0; + data->selNewVal = 0x00000000; + CheckRadioButton(hDlg, IDC_8_BIT, IDC_32_BIT, LOWORD(wParam)); + data->viewMode = (LOWORD(wParam) - IDC_8_BIT); + InvalidateRect(hDlg, NULL, FALSE); UpdateWindow(hDlg); + return 1; + + case IDC_GO: + { + char addrstr[9]; + int len; + int i; + int shift; + BOOL error = FALSE; + u32 address = 0x00000000; + + len = GetWindowText(GetDlgItem(hDlg, IDC_ADDRESS), addrstr, 9); + + for(i = 0; i < len; i++) + { + char ch = addrstr[i]; + + if((ch >= '0') && (ch <= '9')) + continue; + + if((ch >= 'A') && (ch <= 'F')) + continue; + + if((ch >= 'a') && (ch <= 'f')) + continue; + + if(ch == '\0') + break; + + error = TRUE; + break; + } + + if(error) + { + MessageBox(hDlg, "Error:\nInvalid address specified.\nThe address must be an hexadecimal value.", "DeSmuME", (MB_OK | MB_ICONERROR)); + SetWindowText(GetDlgItem(hDlg, IDC_ADDRESS), ""); + return 1; + } + + for(i = (len-1), shift = 0; i >= 0; i--, shift += 4) + { + char ch = addrstr[i]; + + if((ch >= '0') && (ch <= '9')) + address |= ((ch - '0') << shift); + else if((ch >= 'A') && (ch <= 'F')) + address |= ((ch - 'A' + 0xA) << shift); + else if((ch >= 'a') && (ch <= 'f')) + address |= ((ch - 'a' + 0xA) << shift); + } + + data->sel = FALSE; + data->selAddress = 0x00000000; + data->selPart = 0; + data->selNewVal = 0x00000000; + + data->address = min((u32)0xFFFFFF00, (address & 0xFFFFFFF0)); + SetScrollPos(GetDlgItem(hDlg, IDC_MEMVIEWBOX), SB_VERT, ((data->address >> 4) & 0x000FFFFF), TRUE); + InvalidateRect(hDlg, NULL, FALSE); UpdateWindow(hDlg); + } + return 1; + + case IDC_TEXTDUMP: + { + char fileName[256] = ""; + OPENFILENAME ofn; + + ZeroMemory(&ofn, sizeof(ofn)); + ofn.lStructSize = sizeof(ofn); + ofn.hwndOwner = hDlg; + ofn.lpstrFilter = "Text file (*.txt)\0*.txt\0Any file (*.*)\0*.*\0\0"; + ofn.nFilterIndex = 1; + ofn.lpstrFile = fileName; + ofn.nMaxFile = 256; + ofn.lpstrDefExt = "txt"; + ofn.Flags = OFN_NOCHANGEDIR; + + if(GetSaveFileName(&ofn)) + { + FILE *f; + u8 memory[0x100]; + int line; + + MMU_DumpMemBlock(data->cpu, data->address, 0x100, memory); + + f = fopen(fileName, "a"); + + for(line = 0; line < 16; line++) + { + int i; + + fprintf(f, "%08X\t\t", (data->address + (line << 4))); + + switch(data->viewMode) + { + case 0: + { + for(i = 0; i < 16; i++) + { + fprintf(f, "%02X ", T1ReadByte(memory, ((line << 4) + i))); + } + fprintf(f, "\t"); + } + break; + + case 1: + { + for(i = 0; i < 16; i += 2) + { + fprintf(f, "%04X ", T1ReadWord(memory, ((line << 4) + i))); + } + fprintf(f, "\t\t"); + } + break; + + case 2: + { + for(i = 0; i < 16; i += 4) + { + fprintf(f, "%08X ", T1ReadLong(memory, ((line << 4) + i))); + } + fprintf(f, "\t\t\t"); + } + break; + } + + for(i = 0; i < 16; i++) + { + u8 val = T1ReadByte(memory, ((line << 4) + i)); + + if((val >= 32) && (val <= 127)) + fprintf(f, "%c", (char)val); + else + fprintf(f, "."); + } + fprintf(f, "\n"); + } + + fclose(f); + } + } + return 1; + + case IDC_RAWDUMP: + { + char fileName[256] = ""; + OPENFILENAME ofn; + + ZeroMemory(&ofn, sizeof(ofn)); + ofn.lStructSize = sizeof(ofn); + ofn.hwndOwner = hDlg; + ofn.lpstrFilter = "Binary file (*.bin)\0*.bin\0Any file (*.*)\0*.*\0\0"; + ofn.nFilterIndex = 1; + ofn.lpstrFile = fileName; + ofn.nMaxFile = 256; + ofn.lpstrDefExt = "bin"; + ofn.Flags = OFN_NOCHANGEDIR; + + if(GetSaveFileName(&ofn)) + { + FILE *f; + u8 memory[0x2000]; + int line; + + MMU_DumpMemBlock(data->cpu, data->address, 0x2000, memory); + + f = fopen(fileName, "ab"); + + fwrite(memory, 0x2000, 1, f); + + fclose(f); + } + } + return 1; + } + return 0; + } + + return 0; +} + +////////////////////////////////////////////////////////////////////////////// + +LRESULT MemView_ViewBoxPaint(HWND hCtl, MemView_DataStruct *data, WPARAM wParam, LPARAM lParam) +{ + HDC hdc; + PAINTSTRUCT ps; + RECT rc; + int w, h; + SIZE fontsize; + int fontwidth, fontheight; + HDC mem_hdc; + HBITMAP mem_bmp; + + GetClientRect(hCtl, &rc); + w = (rc.right - rc.left); + h = (rc.bottom - rc.top); + + hdc = BeginPaint(hCtl, &ps); + + mem_hdc = CreateCompatibleDC(hdc); + mem_bmp = CreateCompatibleBitmap(hdc, w, h); + SelectObject(mem_hdc, mem_bmp); + + SelectObject(mem_hdc, GetStockObject(SYSTEM_FIXED_FONT)); + + SetBkMode(mem_hdc, OPAQUE); + SetBkColor(mem_hdc, RGB(255, 255, 255)); + SetTextColor(mem_hdc, RGB(0, 0, 0)); + + GetTextExtentPoint32(mem_hdc, " ", 1, &fontsize); + fontwidth = fontsize.cx; + fontheight = fontsize.cy; + + FillRect(mem_hdc, &rc, (HBRUSH)GetStockObject(WHITE_BRUSH)); + + if(data != NULL) + { + u32 addr = data->address; + u8 memory[0x100]; + char text[80]; + int startx; + int curx, cury; + int line; + + startx = 0; + curx = 0; + cury = 0; + + startx = ((fontwidth * 8) + 5); + cury = (fontheight + 3); + + MoveToEx(mem_hdc, ((fontwidth * 8) + 2), 0, NULL); + LineTo(mem_hdc, ((fontwidth * 8) + 2), h); + + MoveToEx(mem_hdc, 0, (fontheight + 1), NULL); + LineTo(mem_hdc, w, (fontheight + 1)); + + switch(data->viewMode) + { + case 0: + { + sprintf(text, " 0 1 2 3 4 5 6 7 8 9 A B C D E F 0123456789ABCDEF"); + TextOut(mem_hdc, startx, 0, text, strlen(text)); + } + break; + + case 1: + { + sprintf(text, " 0 1 2 3 4 5 6 7 8 9 A B C D E F 0123456789ABCDEF"); + TextOut(mem_hdc, startx, 0, text, strlen(text)); + } + break; + + case 2: + { + sprintf(text, " 0 1 2 3 4 5 6 7 8 9 A B C D E F 0123456789ABCDEF"); + TextOut(mem_hdc, startx, 0, text, strlen(text)); + } + break; + } + + MMU_DumpMemBlock(data->cpu, data->address, 0x100, memory); + + for(line = 0; line < 16; line++, addr += 0x10) + { + int i; + + sprintf(text, "%08X", addr); + TextOut(mem_hdc, 0, cury, text, strlen(text)); + + curx = startx; + + switch(data->viewMode) + { + case 0: + { + curx += (fontwidth * 2); + for(i = 0; i < 16; i++) + { + u8 val = T1ReadByte(memory, ((line << 4) + i)); + if(data->sel && (data->selAddress == (addr + i))) + { + SetBkColor(mem_hdc, GetSysColor(COLOR_HIGHLIGHT)); + SetTextColor(mem_hdc, GetSysColor(COLOR_HIGHLIGHTTEXT)); + + switch(data->selPart) + { + case 0: sprintf(text, "%02X", val); break; + case 1: sprintf(text, "%01X.", data->selNewVal); break; + } + } + else + { + SetBkColor(mem_hdc, RGB(255, 255, 255)); + SetTextColor(mem_hdc, RGB(0, 0, 0)); + + sprintf(text, "%02X", val); + } + + TextOut(mem_hdc, curx, cury, text, strlen(text)); + curx += (fontwidth * (2+1)); + } + curx += (fontwidth * 2); + } + break; + + case 1: + { + curx += (fontwidth * 6); + for(i = 0; i < 16; i += 2) + { + u16 val = T1ReadWord(memory, ((line << 4) + i)); + if(data->sel && (data->selAddress == (addr + i))) + { + SetBkColor(mem_hdc, GetSysColor(COLOR_HIGHLIGHT)); + SetTextColor(mem_hdc, GetSysColor(COLOR_HIGHLIGHTTEXT)); + + switch(data->selPart) + { + case 0: sprintf(text, "%04X", val); break; + case 1: sprintf(text, "%01X...", data->selNewVal); break; + case 2: sprintf(text, "%02X..", data->selNewVal); break; + case 3: sprintf(text, "%03X.", data->selNewVal); break; + } + } + else + { + SetBkColor(mem_hdc, RGB(255, 255, 255)); + SetTextColor(mem_hdc, RGB(0, 0, 0)); + + sprintf(text, "%04X", val); + } + + TextOut(mem_hdc, curx, cury, text, strlen(text)); + curx += (fontwidth * (4+1)); + } + curx += (fontwidth * 6); + } + break; + + case 2: + { + curx += (fontwidth * 8); + for(i = 0; i < 16; i += 4) + { + u32 val = T1ReadLong(memory, ((line << 4) + i)); + if(data->sel && (data->selAddress == (addr + i))) + { + SetBkColor(mem_hdc, GetSysColor(COLOR_HIGHLIGHT)); + SetTextColor(mem_hdc, GetSysColor(COLOR_HIGHLIGHTTEXT)); + + switch(data->selPart) + { + case 0: sprintf(text, "%08X", val); break; + case 1: sprintf(text, "%01X.......", data->selNewVal); break; + case 2: sprintf(text, "%02X......", data->selNewVal); break; + case 3: sprintf(text, "%03X.....", data->selNewVal); break; + case 4: sprintf(text, "%04X....", data->selNewVal); break; + case 5: sprintf(text, "%05X...", data->selNewVal); break; + case 6: sprintf(text, "%06X..", data->selNewVal); break; + case 7: sprintf(text, "%07X.", data->selNewVal); break; + } + } + else + { + SetBkColor(mem_hdc, RGB(255, 255, 255)); + SetTextColor(mem_hdc, RGB(0, 0, 0)); + + sprintf(text, "%08X", val); + } + + TextOut(mem_hdc, curx, cury, text, strlen(text)); + curx += (fontwidth * (8+1)); + } + curx += (fontwidth * 8); + } + break; + } + + SetBkColor(mem_hdc, RGB(255, 255, 255)); + SetTextColor(mem_hdc, RGB(0, 0, 0)); + + for(i = 0; i < 16; i++) + { + u8 val = T1ReadByte(memory, ((line << 4) + i)); + + if((val >= 32) && (val <= 127)) + text[i] = (char)val; + else + text[i] = '.'; + } + text[16] = '\0'; + TextOut(mem_hdc, curx, cury, text, strlen(text)); + + cury += fontheight; + } + } + + BitBlt(hdc, 0, 0, w, h, mem_hdc, 0, 0, SRCCOPY); + + DeleteDC(mem_hdc); + DeleteObject(mem_bmp); + + EndPaint(hCtl, &ps); + + return 0; +} + +LRESULT CALLBACK MemView_ViewBoxProc(HWND hCtl, UINT uMsg, WPARAM wParam, LPARAM lParam) +{ + MemView_DataStruct *data = (MemView_DataStruct*)GetWindowLong(hCtl, DWL_USER); + + switch(uMsg) + { + case WM_NCCREATE: + SetScrollRange(hCtl, SB_VERT, 0x00000000, 0x000FFFF0, TRUE); + SetScrollPos(hCtl, SB_VERT, 0x00000000, TRUE); + return 1; + + case WM_NCDESTROY: + return 1; + + case WM_ERASEBKGND: + return 1; + + case WM_PAINT: + MemView_ViewBoxPaint(hCtl, data, wParam, lParam); + return 1; + + case WM_LBUTTONDOWN: + { + HDC hdc; + HFONT font; + SIZE fontsize; + int x, y; + + data->sel = FALSE; + data->selAddress = 0x00000000; + data->selPart = 0; + data->selNewVal = 0x00000000; + + hdc = GetDC(hCtl); + font = (HFONT)SelectObject(hdc, GetStockObject(SYSTEM_FIXED_FONT)); + GetTextExtentPoint32(hdc, " ", 1, &fontsize); + + x = LOWORD(lParam); + y = HIWORD(lParam); + + if((x >= ((fontsize.cx * 8) + 5)) && (y >= (fontsize.cy + 3))) + { + int line, col; + + x -= ((fontsize.cx * 8) + 5); + y -= (fontsize.cy + 3); + + line = (y / fontsize.cy); + + switch(data->viewMode) + { + case 0: + { + if((x < (fontsize.cx * 2)) || (x >= (fontsize.cx * (2 + ((2+1) * 16))))) + break; + + col = ((x - (fontsize.cx * 2)) / (fontsize.cx * (2+1))); + + data->sel = TRUE; + + } + break; + + case 1: + { + if((x < (fontsize.cx * 6)) || (x >= (fontsize.cx * (6 + ((4+1) * 8))))) + break; + + col = ((x - (fontsize.cx * 6)) / (fontsize.cx * (4+1)) * 2); + + data->sel = TRUE; + + } + break; + + case 2: + { + if((x < (fontsize.cx * 8)) || (x >= (fontsize.cx * (8 + ((8+1) * 4))))) + break; + + col = ((x - (fontsize.cx * 8)) / (fontsize.cx * (8+1)) * 4); + + data->sel = TRUE; + + } + break; + } + + data->selAddress = (data->address + (line << 4) + col); + data->selPart = 0; + data->selNewVal = 0x00000000; + } + + SelectObject(hdc, font); + ReleaseDC(hCtl, hdc); + + SetFocus(hCtl); /* Required to receive keyboard messages */ + InvalidateRect(hCtl, NULL, FALSE); UpdateWindow(hCtl); + } + return 1; + + case WM_CHAR: + { + char ch = (char)wParam; + + if(((ch >= '0') && (ch <= '9')) || ((ch >= 'A') && (ch <= 'F')) || ((ch >= 'a') && (ch <= 'f'))) + { + u8 maxSelPart[3] = {2, 4, 8}; + + data->selNewVal <<= 4; + data->selPart++; + + if((ch >= '0') && (ch <= '9')) + data->selNewVal |= (ch - '0'); + else if((ch >= 'A') && (ch <= 'F')) + data->selNewVal |= (ch - 'A' + 0xA); + else if((ch >= 'a') && (ch <= 'f')) + data->selNewVal |= (ch - 'a' + 0xA); + + if(data->selPart >= maxSelPart[data->viewMode]) + { + switch(data->viewMode) + { + case 0: MMU_write8(data->cpu, data->selAddress, (u8)data->selNewVal); data->selAddress++; break; + case 1: MMU_write16(data->cpu, data->selAddress, (u16)data->selNewVal); data->selAddress += 2; break; + case 2: MMU_write32(data->cpu, data->selAddress, data->selNewVal); data->selAddress += 4; break; + } + data->selPart = 0; + data->selNewVal = 0x00000000; + + if(data->selAddress == 0x00000000) + { + data->sel = FALSE; + } + else if(data->selAddress >= (data->address + 0x100)) + { + data->address = min((u32)0xFFFFFF00, (data->address + 0x10)); + SetScrollPos(hCtl, SB_VERT, ((data->address >> 4) & 0x000FFFFF), TRUE); + } + } + } + + InvalidateRect(hCtl, NULL, FALSE); UpdateWindow(hCtl); + } + return 1; + + case WM_VSCROLL: + { + int firstpos = GetScrollPos(hCtl, SB_VERT); + + switch(LOWORD(wParam)) + { + case SB_LINEUP: + data->address = (u32)max(0x00000000, ((int)data->address - 0x10)); + break; + + case SB_LINEDOWN: + data->address = min((u32)0xFFFFFF00, (data->address + 0x10)); + break; + + case SB_PAGEUP: + data->address = (u32)max(0x00000000, ((int)data->address - 0x100)); + break; + + case SB_PAGEDOWN: + data->address = min((u32)0xFFFFFF00, (data->address + 0x100)); + break; + + case SB_THUMBTRACK: + case SB_THUMBPOSITION: + { + SCROLLINFO si; + + ZeroMemory(&si, sizeof(si)); + si.cbSize = sizeof(si); + si.fMask = SIF_TRACKPOS; + + GetScrollInfo(hCtl, SB_VERT, &si); + + data->address = min((u32)0xFFFFFF00, (data->address + ((si.nTrackPos - firstpos) * 16))); + } + break; + } + + if((data->selAddress < data->address) || (data->selAddress >= (data->address + 0x100))) + { + data->sel = FALSE; + data->selAddress = 0x00000000; + data->selPart = 0; + data->selNewVal = 0x00000000; + } + + SetScrollPos(hCtl, SB_VERT, ((data->address >> 4) & 0x000FFFFF), TRUE); + InvalidateRect(hCtl, NULL, FALSE); UpdateWindow(hCtl); + } + return 1; + } + + return DefWindowProc(hCtl, uMsg, wParam, lParam); +} + +////////////////////////////////////////////////////////////////////////////// diff --git a/desmume/src/windows/memView.h b/src/windows/memView.h similarity index 96% rename from desmume/src/windows/memView.h rename to src/windows/memView.h index d324dc05b..97e61bcc0 100644 --- a/desmume/src/windows/memView.h +++ b/src/windows/memView.h @@ -1,36 +1,36 @@ -/* Copyright (C) 2006 yopyop - yopyop156@ifrance.com - yopyop156.ifrance.com - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#ifndef MEM_VIEW_H -#define MEM_VIEW_H - -BOOL MemView_Init(); -void MemView_DeInit(); - -BOOL MemView_DlgOpen(HWND hParentWnd, char *Title, u8 CPU); -void MemView_DlgClose(u8 CPU); -BOOL MemView_IsOpened(u8 CPU); -void MemView_Refresh(u8 CPU); - -BOOL CALLBACK MemView_DlgProc(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam); -LRESULT CALLBACK MemView_ViewBoxProc(HWND hCtl, UINT uMsg, WPARAM wParam, LPARAM lParam); - +/* Copyright (C) 2006 yopyop + yopyop156@ifrance.com + yopyop156.ifrance.com + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#ifndef MEM_VIEW_H +#define MEM_VIEW_H + +BOOL MemView_Init(); +void MemView_DeInit(); + +BOOL MemView_DlgOpen(HWND hParentWnd, char *Title, u8 CPU); +void MemView_DlgClose(u8 CPU); +BOOL MemView_IsOpened(u8 CPU); +void MemView_Refresh(u8 CPU); + +BOOL CALLBACK MemView_DlgProc(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam); +LRESULT CALLBACK MemView_ViewBoxProc(HWND hCtl, UINT uMsg, WPARAM wParam, LPARAM lParam); + #endif \ No newline at end of file diff --git a/desmume/src/windows/mic.cpp b/src/windows/mic.cpp similarity index 91% rename from desmume/src/windows/mic.cpp rename to src/windows/mic.cpp index 319583293..a282831c9 100644 --- a/desmume/src/windows/mic.cpp +++ b/src/windows/mic.cpp @@ -57,36 +57,23 @@ static int CALLBACK waveInProc(HWAVEIN wavein, UINT msg, DWORD instance, DWORD p return 0; } -static char* samplebuffer = NULL; -static int samplebuffersize = 0; -static FILE* fp = NULL; +static char* samplebuffer; +static int samplebuffersize; +static FILE* fp; -bool LoadSample(const char *name) +char* LoadSample(const char *name) { + std::ifstream fl(name); - - if (!fl.is_open()) - { - return false; - } - fl.seekg( 0, std::ios::end ); size_t len = fl.tellg(); - - // Avoid mem leaks - if (samplebuffer != NULL) - delete[] samplebuffer; - - samplebuffersize = len; - samplebuffer = new char[len]; - + samplebuffersize=len; + char *ret = new char[len]; fl.seekg(0, std::ios::beg); - fl.read (samplebuffer, len); - fl.close(); - + fl.read(ret, len); + samplebuffer=ret; SampleLoaded=1; - - return true; + return ret; } BOOL Mic_Init() { diff --git a/desmume/src/windows/oamView.cpp b/src/windows/oamView.cpp similarity index 97% rename from desmume/src/windows/oamView.cpp rename to src/windows/oamView.cpp index 6f38b00f3..9603d1d18 100644 --- a/desmume/src/windows/oamView.cpp +++ b/src/windows/oamView.cpp @@ -1,348 +1,348 @@ -/* Copyright (C) 2006 yopyop - yopyop156@ifrance.com - yopyop156.ifrance.com - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#include "oamView.h" -#include -#include "debug.h" -#include "resource.h" -#include "../MMU.h" -#include "../GPU.h" -#include "../NDSSystem.h" -#include "windriver.h" - -typedef struct -{ - u32 autoup_secs; - bool autoup; - - s16 num; - OAM *oam; - GPU *gpu; -} oamview_struct; - -oamview_struct *OAMView = NULL; - -const char dimm[4][4][8] = -{ - {"8 x 8", "16 x 8", "8 x 16", "- x -"}, - {"16 x 16", "32 x 8", "8 x 32", "- x -"}, - {"32 x 32", "32 x 16", "16 x 32", "- x -"}, - {"64 x 64", "64 x 32", "32 x 64", "- x -"}, -}; - -LRESULT OAMViewBox_OnPaint(HWND hwnd, WPARAM wParam, LPARAM lParam) -{ - Lock lock; - - //HWND hwnd = GetDlgItem(win->hwnd, IDC_OAM_BOX); - HDC hdc; - PAINTSTRUCT ps; -// TCHAR text[80]; - RECT rect; - int lg; - int ht; - HDC mem_dc; - HBITMAP mem_bmp; - - GetClientRect(hwnd, &rect); - lg = rect.right - rect.left; - ht = rect.bottom - rect.top; - - hdc = BeginPaint(hwnd, &ps); - - mem_dc = CreateCompatibleDC(hdc); - mem_bmp = CreateCompatibleBitmap(hdc, lg, ht); - SelectObject(mem_dc, mem_bmp); - - FillRect(mem_dc, &rect, (HBRUSH)GetStockObject(WHITE_BRUSH)); - - BitBlt(hdc, 0, 0, lg, ht, mem_dc, 0, 0, SRCCOPY); - - DeleteDC(mem_dc); - DeleteObject(mem_bmp); - - EndPaint(hwnd, &ps); - - return 0; -} - -LRESULT OamView_OnPaint(HWND hwnd, oamview_struct *win, WPARAM wParam, LPARAM lParam) -{ - HDC hdc; - PAINTSTRUCT ps; - OAM * oam = &win->oam[win->num]; - char text[80]; - u16 bitmap[256*192]; - u8 bitmap_alpha[256*192]; - u8 type[256*192]; - u8 prio[256*192]; - BITMAPV4HEADER bmi; - u16 i; - s16 x; - - //CreateBitmapIndirect(&bmi); - memset(&bmi, 0, sizeof(bmi)); - bmi.bV4Size = sizeof(bmi); - bmi.bV4Planes = 1; - bmi.bV4BitCount = 16; - bmi.bV4V4Compression = BI_RGB|BI_BITFIELDS; - bmi.bV4RedMask = 0x001F; - bmi.bV4GreenMask = 0x03E0; - bmi.bV4BlueMask = 0x7C00; - bmi.bV4Width = 256; - bmi.bV4Height = -192; - - for(i = 0; i < 256*192; ++i) - { - bitmap[i] = 0x7F0F; - bitmap_alpha[i] = 0; - type[i] = 0; - prio[i] = 4; - } - - hdc = BeginPaint(hwnd, &ps); - - sprintf(text, "OAM : %d", win->num); - SetWindowText(GetDlgItem(hwnd, IDC_OAMNUM), text); - - switch(oam->attr0&(3<<10)) - { - case 0 : - SetWindowText(GetDlgItem(hwnd, IDC_MODE), "Normal"); - break; - case (1<<10) : - SetWindowText(GetDlgItem(hwnd, IDC_MODE), "Smi-transp"); - break; - case (2<<10) : - SetWindowText(GetDlgItem(hwnd, IDC_MODE), "OBJ Window"); - break; - case (3<<10) : - SetWindowText(GetDlgItem(hwnd, IDC_MODE), "Bitmap"); - } - - sprintf(text, "0x%08X", oam->attr0/*oam->attr2&0x3FF*/); - SetWindowText(GetDlgItem(hwnd, IDC_TILE), text); - - sprintf(text, "0x%08X", oam->attr1/*oam->attr2&0x3FF*/); - SetWindowText(GetDlgItem(hwnd, IDC_PAL), text); - - //SetWindowText(GetDlgItem(hwnd, IDC_PAL), (oam->attr0&(1<<13))?"256 couleurs": "16 couleurs"); - - sprintf(text, "%d 0x%08X", (oam->attr2>>10)&3, oam->attr2); - SetWindowText(GetDlgItem(hwnd, IDC_PRIO), text); - - x = oam->attr1&0x1FF; - x = ((s16)(x<<7)>>7); - sprintf(text, "%d x %d", x, oam->attr0&0xFF); - SetWindowText(GetDlgItem(hwnd, IDC_COOR), text); - - SetWindowText(GetDlgItem(hwnd, IDC_DIM), dimm[oam->attr1>>14][oam->attr0>>14]); - - SetWindowText(GetDlgItem(hwnd, IDC_ROT), oam->attr0&(1<<8)?"ON" : "OFF"); - - SetWindowText(GetDlgItem(hwnd, IDC_MOS), oam->attr0&(1<<12)?"ON" : "OFF"); - - if(oam->attr0&(1<<8)) - { - sprintf(text, "Rot param : %d", (oam->attr1>>9)&0x1F); - SetWindowText(GetDlgItem(hwnd, IDC_PROP0), text); - - SetWindowText(GetDlgItem(hwnd, IDC_PROP1), (oam->attr0&(1<<9))?"Double size": ""); - } - else - { - if(oam->attr0&(1<<9)) - sprintf(text, "INVISIBLE"); - else - sprintf(text, "%s %s", oam->attr0&(1<<12)?"H FLIP":"", oam->attr0&(1<<13)?"V FLIP":""); - - SetWindowText(GetDlgItem(hwnd, IDC_PROP0), text); - - SetWindowText(GetDlgItem(hwnd, IDC_PROP1), ""); - } - - GPU copy = *win->gpu; - for(i = 0; i < 192; ++i) - { - copy.currLine = i; - copy.spriteRender((u8*)(bitmap + i*256), bitmap_alpha + i*256, type + i*256, prio + i*256); - } - - SetDIBitsToDevice(hdc, 180, 4, 256, 192, 0, 0, 0, 192, bitmap, (BITMAPINFO*)&bmi, DIB_RGB_COLORS); - - EndPaint(hwnd, &ps); - - return 0; -} - -LRESULT CALLBACK ViewOAMBoxProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam) -{ - switch(msg) - { - case WM_NCCREATE: - return 1; - case WM_NCDESTROY: - return 1; - case WM_PAINT: - OAMViewBox_OnPaint(hwnd, wParam, lParam); - return 1; - case WM_ERASEBKGND: - return 1; - default: - break; - } - return DefWindowProc(hwnd, msg, wParam, lParam); -} - -BOOL CALLBACK ViewOAMProc (HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam) -{ - //bail out early if the dialog isnt initialized - if(!OAMView && message != WM_INITDIALOG) - return false; - - switch (message) - { - case WM_INITDIALOG : - { - OAMView = new oamview_struct; - memset(OAMView, 0, sizeof(oamview_struct)); - OAMView->oam = (OAM *)(ARM9Mem.ARM9_OAM); - OAMView->gpu = MainScreen.gpu; - - OAMView->autoup_secs = 1; - SendMessage(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SPIN), - UDM_SETRANGE, 0, MAKELONG(99, 1)); - SendMessage(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SPIN), - UDM_SETPOS32, 0, OAMView->autoup_secs); - - HWND combo = GetDlgItem(hwnd, IDC_SCR_SELECT); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Main screen sprite"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Sub screen sprite"); - SendMessage(combo, CB_SETCURSEL, 0, 0); - } - return 1; - case WM_CLOSE : - { - if(OAMView->autoup) - { - KillTimer(hwnd, IDT_VIEW_OAM); - OAMView->autoup = false; - } - - if (OAMView!=NULL) - { - delete OAMView; - OAMView = NULL; - } - //INFO("Close OAM viewer dialog\n"); - PostQuitMessage(0); - return 0; - } - case WM_PAINT: - OamView_OnPaint(hwnd, OAMView, wParam, lParam); - return 1; - case WM_TIMER: - SendMessage(hwnd, WM_COMMAND, IDC_REFRESH, 0); - return 1; - case WM_HSCROLL : - switch LOWORD(wParam) - { - case SB_LINERIGHT : - ++(OAMView->num); - if(OAMView->num>127) - OAMView->num = 127; - break; - case SB_LINELEFT : - --(OAMView->num); - if(OAMView->num<0) - OAMView->num = 0; - break; - } - InvalidateRect(hwnd, NULL, FALSE); - return 1; - case WM_COMMAND : - switch (LOWORD (wParam)) - { - case IDC_FERMER : - SendMessage(hwnd, WM_CLOSE, 0, 0); - return 1; - case IDC_AUTO_UPDATE : - if(OAMView->autoup) - { - EnableWindow(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SECS), false); - EnableWindow(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SPIN), false); - KillTimer(hwnd, IDT_VIEW_OAM); - OAMView->autoup = FALSE; - return 1; - } - EnableWindow(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SECS), true); - EnableWindow(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SPIN), true); - OAMView->autoup = TRUE; - SetTimer(hwnd, IDT_VIEW_OAM, OAMView->autoup_secs*20, (TIMERPROC) NULL); - return 1; - case IDC_AUTO_UPDATE_SECS: - { - int t = GetDlgItemInt(hwnd, IDC_AUTO_UPDATE_SECS, FALSE, TRUE); - if (!OAMView) - { - SendMessage(hwnd, WM_INITDIALOG, 0, 0); - } - if (t != OAMView->autoup_secs) - { - OAMView->autoup_secs = t; - if (OAMView->autoup) - SetTimer(hwnd, IDT_VIEW_OAM, - OAMView->autoup_secs*20, (TIMERPROC) NULL); - } - } - return 1; - case IDC_REFRESH: - InvalidateRect(hwnd, NULL, FALSE); - return 1; - case IDC_SCR_SELECT : - switch(HIWORD(wParam)) - { - case CBN_SELCHANGE : - { - u32 sel = SendMessage(GetDlgItem(hwnd, IDC_SCR_SELECT), CB_GETCURSEL, 0, 0); - switch(sel) - { - case 0 : - OAMView->oam = (OAM *)ARM9Mem.ARM9_OAM; - OAMView->num = 0; - OAMView->gpu = MainScreen.gpu; - break; - case 1 : - OAMView->oam = (OAM *)(ARM9Mem.ARM9_OAM+0x400); - OAMView->num = 0; - OAMView->gpu = SubScreen.gpu; - break; - } - } - InvalidateRect(hwnd, NULL, FALSE); - return 1; - } - return 1; - } - return 0; - } - return FALSE; -} +/* Copyright (C) 2006 yopyop + yopyop156@ifrance.com + yopyop156.ifrance.com + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#include "oamView.h" +#include +#include "debug.h" +#include "resource.h" +#include "../MMU.h" +#include "../GPU.h" +#include "../NDSSystem.h" +#include "windriver.h" + +typedef struct +{ + u32 autoup_secs; + bool autoup; + + s16 num; + OAM *oam; + GPU *gpu; +} oamview_struct; + +oamview_struct *OAMView = NULL; + +const char dimm[4][4][8] = +{ + {"8 x 8", "16 x 8", "8 x 16", "- x -"}, + {"16 x 16", "32 x 8", "8 x 32", "- x -"}, + {"32 x 32", "32 x 16", "16 x 32", "- x -"}, + {"64 x 64", "64 x 32", "32 x 64", "- x -"}, +}; + +LRESULT OAMViewBox_OnPaint(HWND hwnd, WPARAM wParam, LPARAM lParam) +{ + Lock lock; + + //HWND hwnd = GetDlgItem(win->hwnd, IDC_OAM_BOX); + HDC hdc; + PAINTSTRUCT ps; +// TCHAR text[80]; + RECT rect; + int lg; + int ht; + HDC mem_dc; + HBITMAP mem_bmp; + + GetClientRect(hwnd, &rect); + lg = rect.right - rect.left; + ht = rect.bottom - rect.top; + + hdc = BeginPaint(hwnd, &ps); + + mem_dc = CreateCompatibleDC(hdc); + mem_bmp = CreateCompatibleBitmap(hdc, lg, ht); + SelectObject(mem_dc, mem_bmp); + + FillRect(mem_dc, &rect, (HBRUSH)GetStockObject(WHITE_BRUSH)); + + BitBlt(hdc, 0, 0, lg, ht, mem_dc, 0, 0, SRCCOPY); + + DeleteDC(mem_dc); + DeleteObject(mem_bmp); + + EndPaint(hwnd, &ps); + + return 0; +} + +LRESULT OamView_OnPaint(HWND hwnd, oamview_struct *win, WPARAM wParam, LPARAM lParam) +{ + HDC hdc; + PAINTSTRUCT ps; + OAM * oam = &win->oam[win->num]; + char text[80]; + u16 bitmap[256*192]; + u8 bitmap_alpha[256*192]; + u8 type[256*192]; + u8 prio[256*192]; + BITMAPV4HEADER bmi; + u16 i; + s16 x; + + //CreateBitmapIndirect(&bmi); + memset(&bmi, 0, sizeof(bmi)); + bmi.bV4Size = sizeof(bmi); + bmi.bV4Planes = 1; + bmi.bV4BitCount = 16; + bmi.bV4V4Compression = BI_RGB|BI_BITFIELDS; + bmi.bV4RedMask = 0x001F; + bmi.bV4GreenMask = 0x03E0; + bmi.bV4BlueMask = 0x7C00; + bmi.bV4Width = 256; + bmi.bV4Height = -192; + + for(i = 0; i < 256*192; ++i) + { + bitmap[i] = 0x7F0F; + bitmap_alpha[i] = 0; + type[i] = 0; + prio[i] = 4; + } + + hdc = BeginPaint(hwnd, &ps); + + sprintf(text, "OAM : %d", win->num); + SetWindowText(GetDlgItem(hwnd, IDC_OAMNUM), text); + + switch(oam->attr0&(3<<10)) + { + case 0 : + SetWindowText(GetDlgItem(hwnd, IDC_MODE), "Normal"); + break; + case (1<<10) : + SetWindowText(GetDlgItem(hwnd, IDC_MODE), "Smi-transp"); + break; + case (2<<10) : + SetWindowText(GetDlgItem(hwnd, IDC_MODE), "OBJ Window"); + break; + case (3<<10) : + SetWindowText(GetDlgItem(hwnd, IDC_MODE), "Bitmap"); + } + + sprintf(text, "0x%08X", oam->attr0/*oam->attr2&0x3FF*/); + SetWindowText(GetDlgItem(hwnd, IDC_TILE), text); + + sprintf(text, "0x%08X", oam->attr1/*oam->attr2&0x3FF*/); + SetWindowText(GetDlgItem(hwnd, IDC_PAL), text); + + //SetWindowText(GetDlgItem(hwnd, IDC_PAL), (oam->attr0&(1<<13))?"256 couleurs": "16 couleurs"); + + sprintf(text, "%d 0x%08X", (oam->attr2>>10)&3, oam->attr2); + SetWindowText(GetDlgItem(hwnd, IDC_PRIO), text); + + x = oam->attr1&0x1FF; + x = ((s16)(x<<7)>>7); + sprintf(text, "%d x %d", x, oam->attr0&0xFF); + SetWindowText(GetDlgItem(hwnd, IDC_COOR), text); + + SetWindowText(GetDlgItem(hwnd, IDC_DIM), dimm[oam->attr1>>14][oam->attr0>>14]); + + SetWindowText(GetDlgItem(hwnd, IDC_ROT), oam->attr0&(1<<8)?"ON" : "OFF"); + + SetWindowText(GetDlgItem(hwnd, IDC_MOS), oam->attr0&(1<<12)?"ON" : "OFF"); + + if(oam->attr0&(1<<8)) + { + sprintf(text, "Rot param : %d", (oam->attr1>>9)&0x1F); + SetWindowText(GetDlgItem(hwnd, IDC_PROP0), text); + + SetWindowText(GetDlgItem(hwnd, IDC_PROP1), (oam->attr0&(1<<9))?"Double size": ""); + } + else + { + if(oam->attr0&(1<<9)) + sprintf(text, "INVISIBLE"); + else + sprintf(text, "%s %s", oam->attr0&(1<<12)?"H FLIP":"", oam->attr0&(1<<13)?"V FLIP":""); + + SetWindowText(GetDlgItem(hwnd, IDC_PROP0), text); + + SetWindowText(GetDlgItem(hwnd, IDC_PROP1), ""); + } + + GPU copy = *win->gpu; + for(i = 0; i < 192; ++i) + { + copy.currLine = i; + copy.spriteRender((u8*)(bitmap + i*256), bitmap_alpha + i*256, type + i*256, prio + i*256); + } + + SetDIBitsToDevice(hdc, 180, 4, 256, 192, 0, 0, 0, 192, bitmap, (BITMAPINFO*)&bmi, DIB_RGB_COLORS); + + EndPaint(hwnd, &ps); + + return 0; +} + +LRESULT CALLBACK ViewOAMBoxProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam) +{ + switch(msg) + { + case WM_NCCREATE: + return 1; + case WM_NCDESTROY: + return 1; + case WM_PAINT: + OAMViewBox_OnPaint(hwnd, wParam, lParam); + return 1; + case WM_ERASEBKGND: + return 1; + default: + break; + } + return DefWindowProc(hwnd, msg, wParam, lParam); +} + +BOOL CALLBACK ViewOAMProc (HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam) +{ + //bail out early if the dialog isnt initialized + if(!OAMView && message != WM_INITDIALOG) + return false; + + switch (message) + { + case WM_INITDIALOG : + { + OAMView = new oamview_struct; + memset(OAMView, 0, sizeof(oamview_struct)); + OAMView->oam = (OAM *)(ARM9Mem.ARM9_OAM); + OAMView->gpu = MainScreen.gpu; + + OAMView->autoup_secs = 1; + SendMessage(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SPIN), + UDM_SETRANGE, 0, MAKELONG(99, 1)); + SendMessage(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SPIN), + UDM_SETPOS32, 0, OAMView->autoup_secs); + + HWND combo = GetDlgItem(hwnd, IDC_SCR_SELECT); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Main screen sprite"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Sub screen sprite"); + SendMessage(combo, CB_SETCURSEL, 0, 0); + } + return 1; + case WM_CLOSE : + { + if(OAMView->autoup) + { + KillTimer(hwnd, IDT_VIEW_OAM); + OAMView->autoup = false; + } + + if (OAMView!=NULL) + { + delete OAMView; + OAMView = NULL; + } + //INFO("Close OAM viewer dialog\n"); + PostQuitMessage(0); + return 0; + } + case WM_PAINT: + OamView_OnPaint(hwnd, OAMView, wParam, lParam); + return 1; + case WM_TIMER: + SendMessage(hwnd, WM_COMMAND, IDC_REFRESH, 0); + return 1; + case WM_HSCROLL : + switch LOWORD(wParam) + { + case SB_LINERIGHT : + ++(OAMView->num); + if(OAMView->num>127) + OAMView->num = 127; + break; + case SB_LINELEFT : + --(OAMView->num); + if(OAMView->num<0) + OAMView->num = 0; + break; + } + InvalidateRect(hwnd, NULL, FALSE); + return 1; + case WM_COMMAND : + switch (LOWORD (wParam)) + { + case IDC_FERMER : + SendMessage(hwnd, WM_CLOSE, 0, 0); + return 1; + case IDC_AUTO_UPDATE : + if(OAMView->autoup) + { + EnableWindow(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SECS), false); + EnableWindow(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SPIN), false); + KillTimer(hwnd, IDT_VIEW_OAM); + OAMView->autoup = FALSE; + return 1; + } + EnableWindow(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SECS), true); + EnableWindow(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SPIN), true); + OAMView->autoup = TRUE; + SetTimer(hwnd, IDT_VIEW_OAM, OAMView->autoup_secs*20, (TIMERPROC) NULL); + return 1; + case IDC_AUTO_UPDATE_SECS: + { + int t = GetDlgItemInt(hwnd, IDC_AUTO_UPDATE_SECS, FALSE, TRUE); + if (!OAMView) + { + SendMessage(hwnd, WM_INITDIALOG, 0, 0); + } + if (t != OAMView->autoup_secs) + { + OAMView->autoup_secs = t; + if (OAMView->autoup) + SetTimer(hwnd, IDT_VIEW_OAM, + OAMView->autoup_secs*20, (TIMERPROC) NULL); + } + } + return 1; + case IDC_REFRESH: + InvalidateRect(hwnd, NULL, FALSE); + return 1; + case IDC_SCR_SELECT : + switch(HIWORD(wParam)) + { + case CBN_SELCHANGE : + { + u32 sel = SendMessage(GetDlgItem(hwnd, IDC_SCR_SELECT), CB_GETCURSEL, 0, 0); + switch(sel) + { + case 0 : + OAMView->oam = (OAM *)ARM9Mem.ARM9_OAM; + OAMView->num = 0; + OAMView->gpu = MainScreen.gpu; + break; + case 1 : + OAMView->oam = (OAM *)(ARM9Mem.ARM9_OAM+0x400); + OAMView->num = 0; + OAMView->gpu = SubScreen.gpu; + break; + } + } + InvalidateRect(hwnd, NULL, FALSE); + return 1; + } + return 1; + } + return 0; + } + return FALSE; +} diff --git a/desmume/src/windows/oamView.h b/src/windows/oamView.h similarity index 97% rename from desmume/src/windows/oamView.h rename to src/windows/oamView.h index ac5d3ba6a..dbb4eab60 100644 --- a/desmume/src/windows/oamView.h +++ b/src/windows/oamView.h @@ -1,30 +1,30 @@ -/* Copyright (C) 2006 yopyop - yopyop156@ifrance.com - yopyop156.ifrance.com - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#ifndef OAMVIEW_H -#define OAMVIEW_H - -#include "../common.h" - -extern LRESULT CALLBACK ViewOAMBoxProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam); -extern BOOL CALLBACK ViewOAMProc (HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam); - -#endif +/* Copyright (C) 2006 yopyop + yopyop156@ifrance.com + yopyop156.ifrance.com + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#ifndef OAMVIEW_H +#define OAMVIEW_H + +#include "../common.h" + +extern LRESULT CALLBACK ViewOAMBoxProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam); +extern BOOL CALLBACK ViewOAMProc (HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam); + +#endif diff --git a/desmume/src/windows/ogl.cpp b/src/windows/ogl.cpp similarity index 69% rename from desmume/src/windows/ogl.cpp rename to src/windows/ogl.cpp index 0449997f0..fcb8da749 100644 --- a/desmume/src/windows/ogl.cpp +++ b/src/windows/ogl.cpp @@ -1,98 +1,98 @@ -/* ogl.cpp - - Copyright (C) 2006-2009 DeSmuME team - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -*/ - -#define WIN32_LEAN_AND_MEAN -#include "../common.h" -#include "../debug.h" -#include -#include -#include "console.h" -#include "CWindow.h" - -extern WINCLASS *MainWindow; - -static bool oglAlreadyInit = false; - -int CheckHardwareSupport(HDC hdc) -{ - int PixelFormat = GetPixelFormat(hdc); - PIXELFORMATDESCRIPTOR pfd; - - DescribePixelFormat(hdc,PixelFormat,sizeof(PIXELFORMATDESCRIPTOR),&pfd); - if ((pfd.dwFlags & PFD_GENERIC_FORMAT) && !(pfd.dwFlags & PFD_GENERIC_ACCELERATED)) - return 0; // Software acceleration OpenGL - - else if ((pfd.dwFlags & PFD_GENERIC_FORMAT) && (pfd.dwFlags & PFD_GENERIC_ACCELERATED)) - return 1; // Half hardware acceleration OpenGL (MCD driver) - - else if ( !(pfd.dwFlags & PFD_GENERIC_FORMAT) && !(pfd.dwFlags & PFD_GENERIC_ACCELERATED)) - return 2; // Full hardware acceleration OpenGL - return -1; // check error -} - -bool windows_opengl_init() -{ - HDC oglDC = NULL; - HGLRC hRC = NULL; - int pixelFormat; - PIXELFORMATDESCRIPTOR pfd; - int res; - char *opengl_modes[3]={"software","half hardware (MCD driver)","hardware"}; - - if(oglAlreadyInit == true) return true; - - oglDC = GetDC (MainWindow->getHWnd()); - - memset(&pfd,0, sizeof(PIXELFORMATDESCRIPTOR)); - pfd.nSize = sizeof(PIXELFORMATDESCRIPTOR); - pfd.nVersion = 1; - pfd.dwFlags = PFD_DRAW_TO_BITMAP | PFD_SUPPORT_OPENGL | PFD_DOUBLEBUFFER; - pfd.iPixelType = PFD_TYPE_RGBA; - pfd.cColorBits = 24; - pfd.cDepthBits = 24; - pfd.cAlphaBits = 8; - pfd.cStencilBits = 8; - pfd.iLayerType = PFD_MAIN_PLANE ; - - pixelFormat = ChoosePixelFormat(oglDC, &pfd); - if (pixelFormat == 0) - return false; - - if(!SetPixelFormat(oglDC, pixelFormat, &pfd)) - return false; - - hRC = wglCreateContext(oglDC); - if (!hRC) - return false; - - if(!wglMakeCurrent(oglDC, hRC)) - return false; - - res=CheckHardwareSupport(oglDC); - if (res>=0&&res<=2) - INFO("OpenGL mode: %s\n",opengl_modes[res]); - else - INFO("OpenGL mode: uknown\n"); - - oglAlreadyInit = true; - - return true; -} +/* ogl.cpp + * + * Copyright (C) 2006-2008 Zeromus + * + * This file is part of DeSmuME + * + * DeSmuME is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * DeSmuME is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with DeSmuME; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA +*/ + +#define WIN32_LEAN_AND_MEAN +#include "../common.h" +#include "../debug.h" +#include +#include +#include "console.h" +#include "CWindow.h" + +extern WINCLASS *MainWindow; + +static bool oglAlreadyInit = false; + +int CheckHardwareSupport(HDC hdc) +{ + int PixelFormat = GetPixelFormat(hdc); + PIXELFORMATDESCRIPTOR pfd; + + DescribePixelFormat(hdc,PixelFormat,sizeof(PIXELFORMATDESCRIPTOR),&pfd); + if ((pfd.dwFlags & PFD_GENERIC_FORMAT) && !(pfd.dwFlags & PFD_GENERIC_ACCELERATED)) + return 0; // Software acceleration OpenGL + + else if ((pfd.dwFlags & PFD_GENERIC_FORMAT) && (pfd.dwFlags & PFD_GENERIC_ACCELERATED)) + return 1; // Half hardware acceleration OpenGL (MCD driver) + + else if ( !(pfd.dwFlags & PFD_GENERIC_FORMAT) && !(pfd.dwFlags & PFD_GENERIC_ACCELERATED)) + return 2; // Full hardware acceleration OpenGL + return -1; // check error +} + +bool windows_opengl_init() +{ + HDC oglDC = NULL; + HGLRC hRC = NULL; + int pixelFormat; + PIXELFORMATDESCRIPTOR pfd; + int res; + char *opengl_modes[3]={"software","half hardware (MCD driver)","hardware"}; + + if(oglAlreadyInit == true) return true; + + oglDC = GetDC (MainWindow->getHWnd()); + + memset(&pfd,0, sizeof(PIXELFORMATDESCRIPTOR)); + pfd.nSize = sizeof(PIXELFORMATDESCRIPTOR); + pfd.nVersion = 1; + pfd.dwFlags = PFD_DRAW_TO_BITMAP | PFD_SUPPORT_OPENGL | PFD_DOUBLEBUFFER; + pfd.iPixelType = PFD_TYPE_RGBA; + pfd.cColorBits = 24; + pfd.cDepthBits = 24; + pfd.cAlphaBits = 8; + pfd.cStencilBits = 8; + pfd.iLayerType = PFD_MAIN_PLANE ; + + pixelFormat = ChoosePixelFormat(oglDC, &pfd); + if (pixelFormat == 0) + return false; + + if(!SetPixelFormat(oglDC, pixelFormat, &pfd)) + return false; + + hRC = wglCreateContext(oglDC); + if (!hRC) + return false; + + if(!wglMakeCurrent(oglDC, hRC)) + return false; + + res=CheckHardwareSupport(oglDC); + if (res>=0&&res<=2) + INFO("OpenGL mode: %s\n",opengl_modes[res]); + else + INFO("OpenGL mode: uknown\n"); + + oglAlreadyInit = true; + + return true; +} diff --git a/desmume/src/windows/palView.cpp b/src/windows/palView.cpp similarity index 97% rename from desmume/src/windows/palView.cpp rename to src/windows/palView.cpp index 73db477c0..0e2dcf2ae 100644 --- a/desmume/src/windows/palView.cpp +++ b/src/windows/palView.cpp @@ -1,295 +1,295 @@ -/* Copyright (C) 2006 yopyop - yopyop156@ifrance.com - yopyop156.ifrance.com - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#include "palView.h" -#include -#include "debug.h" -#include "resource.h" -#include "../MMU.h" - -typedef struct -{ - u32 autoup_secs; - bool autoup; - - u16 *adr; - s16 palnum; -} palview_struct; - -palview_struct *PalView = NULL; - -LRESULT PalView_OnPaint(const u16 * adr, u16 num, HWND hwnd, WPARAM wParam, LPARAM lParam) -{ - HDC hdc; - PAINTSTRUCT ps; - RECT rect; - HBRUSH brush; - u16 c; - char tmp[80]; - - rect.left = 3; - rect.top = 55; - rect.right = 13; - rect.bottom = 65; - hdc = BeginPaint(hwnd, &ps); - - if(adr) - { - u32 y; - - for(y = 0; y < 16; ++y) - { - u32 x; - - for(x = 0; x < 16; ++x) - { - c = adr[(y<<4)+x+0x100*num]; - brush = CreateSolidBrush(RGB((c&0x1F)<<3, (c&0x3E0)>>2, (c&0x7C00)>>7)); - FillRect(hdc, &rect, brush); - DeleteObject(brush); - rect.left += 11; - rect.right += 11; - } - rect.top += 11; - rect.bottom += 11; - rect.left = 3; - rect.right = 13; - } - sprintf(tmp, "Pal : %d", num); - SetWindowText(GetDlgItem(hwnd, IDC_PALNUM), tmp); - } - else - TextOut(hdc, 3, 55, "Pas de palette", 14); - EndPaint(hwnd, &ps); - - return 0; -} - -BOOL CALLBACK ViewPalProc (HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam) -{ - //bail out early if the dialog isnt initialized - if(!PalView && message != WM_INITDIALOG) - return false; - - switch (message) - { - case WM_INITDIALOG : - { - PalView = new palview_struct; - memset(PalView, 0, sizeof(palview_struct)); - PalView->adr = (u16 *)ARM9Mem.ARM9_VMEM; - PalView->autoup_secs = 1; - SendMessage(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SPIN), - UDM_SETRANGE, 0, MAKELONG(99, 1)); - SendMessage(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SPIN), - UDM_SETPOS32, 0, PalView->autoup_secs); - - HWND combo = GetDlgItem(hwnd, IDC_PAL_SELECT); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Main screen BG PAL"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Sub screen BG PAL"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Main screen SPR PAL"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Sub screen SPR PAL"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Main screen ExtPAL 0"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Main screen ExtPAL 1"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Main screen ExtPAL 2"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Main screen ExtPAL 3"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Sub screen ExtPAL 0"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Sub screen ExtPAL 1"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Sub screen ExtPAL 2"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Sub screen ExtPAL 3"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Main spr ExtPAL 0"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Main spr ExtPAL 1"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Sub spr ExtPAL 0"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Sub spr ExtPAL 1"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Texture pal 0"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Texture pal 1"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Texture pal 2"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Texture pal 3"); - SendMessage(combo, CB_SETCURSEL, 0, 0); - ShowWindow(GetDlgItem(hwnd, IDC_SCROLLER), SW_HIDE); - EnableWindow(GetDlgItem(hwnd, IDC_SCROLLER), FALSE); - } - return 1; - case WM_CLOSE : - { - if(PalView->autoup) - { - KillTimer(hwnd, IDT_VIEW_DISASM7); - PalView->autoup = false; - } - - if (PalView!=NULL) - { - delete PalView; - PalView = NULL; - } - //INFO("Close Palette view dialog\n"); - PostQuitMessage(0); - return 0; - } - case WM_PAINT: - PalView_OnPaint(PalView->adr, PalView->palnum, hwnd, wParam, lParam); - return 1; - case WM_TIMER: - SendMessage(hwnd, WM_COMMAND, IDC_REFRESH, 0); - return 1; - case WM_HSCROLL : - switch LOWORD(wParam) - { - case SB_LINERIGHT : - ++(PalView->palnum); - if(PalView->palnum>15) - PalView->palnum = 15; - break; - case SB_LINELEFT : - --(PalView->palnum); - if(PalView->palnum<0) - PalView->palnum = 0; - break; - } - InvalidateRect(hwnd, NULL, FALSE); - return 1; - case WM_COMMAND : - switch (LOWORD (wParam)) - { - case IDC_FERMER : - SendMessage(hwnd, WM_CLOSE, 0, 0); - return 1; - case IDC_AUTO_UPDATE : - if(PalView->autoup) - { - EnableWindow(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SECS), false); - EnableWindow(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SPIN), false); - KillTimer(hwnd, IDT_VIEW_PAL); - PalView->autoup = FALSE; - return 1; - } - EnableWindow(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SECS), true); - EnableWindow(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SPIN), true); - PalView->autoup = TRUE; - SetTimer(hwnd, IDT_VIEW_PAL, PalView->autoup_secs*20, (TIMERPROC) NULL); - return 1; - case IDC_AUTO_UPDATE_SECS: - { - int t = GetDlgItemInt(hwnd, IDC_AUTO_UPDATE_SECS, FALSE, TRUE); - if (!PalView) - { - SendMessage(hwnd, WM_INITDIALOG, 0, 0); - } - if (t != PalView->autoup_secs) - { - PalView->autoup_secs = t; - if (PalView->autoup) - SetTimer(hwnd, IDT_VIEW_PAL, - PalView->autoup_secs*20, (TIMERPROC) NULL); - } - } - return 1; - case IDC_REFRESH: - InvalidateRect(hwnd, NULL, FALSE); - return 1; - case IDC_PAL_SELECT : - switch(HIWORD(wParam)) - { - case CBN_SELCHANGE : - case CBN_CLOSEUP : - { - u32 sel = SendMessage(GetDlgItem(hwnd, IDC_PAL_SELECT), CB_GETCURSEL, 0, 0); - switch(sel) - { - case 0 : - PalView->adr = (u16 *)ARM9Mem.ARM9_VMEM; - PalView->palnum = 0; - ShowWindow(GetDlgItem(hwnd, IDC_SCROLLER), SW_HIDE); - EnableWindow(GetDlgItem(hwnd, IDC_SCROLLER), FALSE); - break; - case 1 : - PalView->adr = ((u16 *)ARM9Mem.ARM9_VMEM) + 0x200; - PalView->palnum = 0; - ShowWindow(GetDlgItem(hwnd, IDC_SCROLLER), SW_HIDE); - EnableWindow(GetDlgItem(hwnd, IDC_SCROLLER), FALSE); - break; - case 2 : - PalView->adr = (u16 *)ARM9Mem.ARM9_VMEM + 0x100; - PalView->palnum = 0; - ShowWindow(GetDlgItem(hwnd, IDC_SCROLLER), SW_HIDE); - EnableWindow(GetDlgItem(hwnd, IDC_SCROLLER), FALSE); - break; - case 3 : - PalView->adr = ((u16 *)ARM9Mem.ARM9_VMEM) + 0x300; - PalView->palnum = 0; - ShowWindow(GetDlgItem(hwnd, IDC_SCROLLER), SW_HIDE); - EnableWindow(GetDlgItem(hwnd, IDC_SCROLLER), FALSE); - break; - case 4 : - case 5 : - case 6 : - case 7 : - PalView->adr = ((u16 *)(ARM9Mem.ExtPal[0][sel-4])); - PalView->palnum = 0; - ShowWindow(GetDlgItem(hwnd, IDC_SCROLLER), SW_SHOW); - EnableWindow(GetDlgItem(hwnd, IDC_SCROLLER), TRUE); - break; - case 8 : - case 9 : - case 10 : - case 11 : - PalView->adr = ((u16 *)(ARM9Mem.ExtPal[1][sel-8])); - PalView->palnum = 0; - ShowWindow(GetDlgItem(hwnd, IDC_SCROLLER), SW_SHOW); - EnableWindow(GetDlgItem(hwnd, IDC_SCROLLER), TRUE); - break; - case 12 : - case 13 : - PalView->adr = ((u16 *)(ARM9Mem.ObjExtPal[0][sel-12])); - PalView->palnum = 0; - ShowWindow(GetDlgItem(hwnd, IDC_SCROLLER), SW_SHOW); - EnableWindow(GetDlgItem(hwnd, IDC_SCROLLER), TRUE); - break; - case 14 : - case 15 : - PalView->adr = ((u16 *)(ARM9Mem.ObjExtPal[1][sel-14])); - PalView->palnum = 0; - ShowWindow(GetDlgItem(hwnd, IDC_SCROLLER), SW_SHOW); - EnableWindow(GetDlgItem(hwnd, IDC_SCROLLER), TRUE); - break; - case 16 : - case 17 : - case 18 : - case 19 : - PalView->adr = ((u16 *)(ARM9Mem.texInfo.texPalSlot[sel-16])); - PalView->palnum = 0; - ShowWindow(GetDlgItem(hwnd, IDC_SCROLLER), SW_SHOW); - EnableWindow(GetDlgItem(hwnd, IDC_SCROLLER), TRUE); - break; - default : - return 1; - } - InvalidateRect(hwnd, NULL, FALSE); - return 1; - } - } - return 1; - } - return 0; - } - return false; -} +/* Copyright (C) 2006 yopyop + yopyop156@ifrance.com + yopyop156.ifrance.com + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#include "palView.h" +#include +#include "debug.h" +#include "resource.h" +#include "../MMU.h" + +typedef struct +{ + u32 autoup_secs; + bool autoup; + + u16 *adr; + s16 palnum; +} palview_struct; + +palview_struct *PalView = NULL; + +LRESULT PalView_OnPaint(const u16 * adr, u16 num, HWND hwnd, WPARAM wParam, LPARAM lParam) +{ + HDC hdc; + PAINTSTRUCT ps; + RECT rect; + HBRUSH brush; + u16 c; + char tmp[80]; + + rect.left = 3; + rect.top = 55; + rect.right = 13; + rect.bottom = 65; + hdc = BeginPaint(hwnd, &ps); + + if(adr) + { + u32 y; + + for(y = 0; y < 16; ++y) + { + u32 x; + + for(x = 0; x < 16; ++x) + { + c = adr[(y<<4)+x+0x100*num]; + brush = CreateSolidBrush(RGB((c&0x1F)<<3, (c&0x3E0)>>2, (c&0x7C00)>>7)); + FillRect(hdc, &rect, brush); + DeleteObject(brush); + rect.left += 11; + rect.right += 11; + } + rect.top += 11; + rect.bottom += 11; + rect.left = 3; + rect.right = 13; + } + sprintf(tmp, "Pal : %d", num); + SetWindowText(GetDlgItem(hwnd, IDC_PALNUM), tmp); + } + else + TextOut(hdc, 3, 55, "Pas de palette", 14); + EndPaint(hwnd, &ps); + + return 0; +} + +BOOL CALLBACK ViewPalProc (HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam) +{ + //bail out early if the dialog isnt initialized + if(!PalView && message != WM_INITDIALOG) + return false; + + switch (message) + { + case WM_INITDIALOG : + { + PalView = new palview_struct; + memset(PalView, 0, sizeof(palview_struct)); + PalView->adr = (u16 *)ARM9Mem.ARM9_VMEM; + PalView->autoup_secs = 1; + SendMessage(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SPIN), + UDM_SETRANGE, 0, MAKELONG(99, 1)); + SendMessage(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SPIN), + UDM_SETPOS32, 0, PalView->autoup_secs); + + HWND combo = GetDlgItem(hwnd, IDC_PAL_SELECT); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Main screen BG PAL"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Sub screen BG PAL"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Main screen SPR PAL"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Sub screen SPR PAL"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Main screen ExtPAL 0"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Main screen ExtPAL 1"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Main screen ExtPAL 2"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Main screen ExtPAL 3"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Sub screen ExtPAL 0"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Sub screen ExtPAL 1"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Sub screen ExtPAL 2"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Sub screen ExtPAL 3"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Main spr ExtPAL 0"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Main spr ExtPAL 1"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Sub spr ExtPAL 0"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Sub spr ExtPAL 1"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Texture pal 0"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Texture pal 1"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Texture pal 2"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Texture pal 3"); + SendMessage(combo, CB_SETCURSEL, 0, 0); + ShowWindow(GetDlgItem(hwnd, IDC_SCROLLER), SW_HIDE); + EnableWindow(GetDlgItem(hwnd, IDC_SCROLLER), FALSE); + } + return 1; + case WM_CLOSE : + { + if(PalView->autoup) + { + KillTimer(hwnd, IDT_VIEW_DISASM7); + PalView->autoup = false; + } + + if (PalView!=NULL) + { + delete PalView; + PalView = NULL; + } + //INFO("Close Palette view dialog\n"); + PostQuitMessage(0); + return 0; + } + case WM_PAINT: + PalView_OnPaint(PalView->adr, PalView->palnum, hwnd, wParam, lParam); + return 1; + case WM_TIMER: + SendMessage(hwnd, WM_COMMAND, IDC_REFRESH, 0); + return 1; + case WM_HSCROLL : + switch LOWORD(wParam) + { + case SB_LINERIGHT : + ++(PalView->palnum); + if(PalView->palnum>15) + PalView->palnum = 15; + break; + case SB_LINELEFT : + --(PalView->palnum); + if(PalView->palnum<0) + PalView->palnum = 0; + break; + } + InvalidateRect(hwnd, NULL, FALSE); + return 1; + case WM_COMMAND : + switch (LOWORD (wParam)) + { + case IDC_FERMER : + SendMessage(hwnd, WM_CLOSE, 0, 0); + return 1; + case IDC_AUTO_UPDATE : + if(PalView->autoup) + { + EnableWindow(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SECS), false); + EnableWindow(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SPIN), false); + KillTimer(hwnd, IDT_VIEW_PAL); + PalView->autoup = FALSE; + return 1; + } + EnableWindow(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SECS), true); + EnableWindow(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SPIN), true); + PalView->autoup = TRUE; + SetTimer(hwnd, IDT_VIEW_PAL, PalView->autoup_secs*20, (TIMERPROC) NULL); + return 1; + case IDC_AUTO_UPDATE_SECS: + { + int t = GetDlgItemInt(hwnd, IDC_AUTO_UPDATE_SECS, FALSE, TRUE); + if (!PalView) + { + SendMessage(hwnd, WM_INITDIALOG, 0, 0); + } + if (t != PalView->autoup_secs) + { + PalView->autoup_secs = t; + if (PalView->autoup) + SetTimer(hwnd, IDT_VIEW_PAL, + PalView->autoup_secs*20, (TIMERPROC) NULL); + } + } + return 1; + case IDC_REFRESH: + InvalidateRect(hwnd, NULL, FALSE); + return 1; + case IDC_PAL_SELECT : + switch(HIWORD(wParam)) + { + case CBN_SELCHANGE : + case CBN_CLOSEUP : + { + u32 sel = SendMessage(GetDlgItem(hwnd, IDC_PAL_SELECT), CB_GETCURSEL, 0, 0); + switch(sel) + { + case 0 : + PalView->adr = (u16 *)ARM9Mem.ARM9_VMEM; + PalView->palnum = 0; + ShowWindow(GetDlgItem(hwnd, IDC_SCROLLER), SW_HIDE); + EnableWindow(GetDlgItem(hwnd, IDC_SCROLLER), FALSE); + break; + case 1 : + PalView->adr = ((u16 *)ARM9Mem.ARM9_VMEM) + 0x200; + PalView->palnum = 0; + ShowWindow(GetDlgItem(hwnd, IDC_SCROLLER), SW_HIDE); + EnableWindow(GetDlgItem(hwnd, IDC_SCROLLER), FALSE); + break; + case 2 : + PalView->adr = (u16 *)ARM9Mem.ARM9_VMEM + 0x100; + PalView->palnum = 0; + ShowWindow(GetDlgItem(hwnd, IDC_SCROLLER), SW_HIDE); + EnableWindow(GetDlgItem(hwnd, IDC_SCROLLER), FALSE); + break; + case 3 : + PalView->adr = ((u16 *)ARM9Mem.ARM9_VMEM) + 0x300; + PalView->palnum = 0; + ShowWindow(GetDlgItem(hwnd, IDC_SCROLLER), SW_HIDE); + EnableWindow(GetDlgItem(hwnd, IDC_SCROLLER), FALSE); + break; + case 4 : + case 5 : + case 6 : + case 7 : + PalView->adr = ((u16 *)(ARM9Mem.ExtPal[0][sel-4])); + PalView->palnum = 0; + ShowWindow(GetDlgItem(hwnd, IDC_SCROLLER), SW_SHOW); + EnableWindow(GetDlgItem(hwnd, IDC_SCROLLER), TRUE); + break; + case 8 : + case 9 : + case 10 : + case 11 : + PalView->adr = ((u16 *)(ARM9Mem.ExtPal[1][sel-8])); + PalView->palnum = 0; + ShowWindow(GetDlgItem(hwnd, IDC_SCROLLER), SW_SHOW); + EnableWindow(GetDlgItem(hwnd, IDC_SCROLLER), TRUE); + break; + case 12 : + case 13 : + PalView->adr = ((u16 *)(ARM9Mem.ObjExtPal[0][sel-12])); + PalView->palnum = 0; + ShowWindow(GetDlgItem(hwnd, IDC_SCROLLER), SW_SHOW); + EnableWindow(GetDlgItem(hwnd, IDC_SCROLLER), TRUE); + break; + case 14 : + case 15 : + PalView->adr = ((u16 *)(ARM9Mem.ObjExtPal[1][sel-14])); + PalView->palnum = 0; + ShowWindow(GetDlgItem(hwnd, IDC_SCROLLER), SW_SHOW); + EnableWindow(GetDlgItem(hwnd, IDC_SCROLLER), TRUE); + break; + case 16 : + case 17 : + case 18 : + case 19 : + PalView->adr = ((u16 *)(ARM9Mem.texInfo.texPalSlot[sel-16])); + PalView->palnum = 0; + ShowWindow(GetDlgItem(hwnd, IDC_SCROLLER), SW_SHOW); + EnableWindow(GetDlgItem(hwnd, IDC_SCROLLER), TRUE); + break; + default : + return 1; + } + InvalidateRect(hwnd, NULL, FALSE); + return 1; + } + } + return 1; + } + return 0; + } + return false; +} diff --git a/desmume/src/windows/palView.h b/src/windows/palView.h similarity index 96% rename from desmume/src/windows/palView.h rename to src/windows/palView.h index faef7d93c..6a8193bb7 100644 --- a/desmume/src/windows/palView.h +++ b/src/windows/palView.h @@ -1,30 +1,30 @@ -/* Copyright (C) 2006 yopyop - yopyop156@ifrance.com - yopyop156.ifrance.com - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#ifndef PALVIEW_H -#define PALVIEW_H - -#include "../common.h" -#include - -extern BOOL CALLBACK ViewPalProc (HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam); - +/* Copyright (C) 2006 yopyop + yopyop156@ifrance.com + yopyop156.ifrance.com + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#ifndef PALVIEW_H +#define PALVIEW_H + +#include "../common.h" +#include + +extern BOOL CALLBACK ViewPalProc (HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam); + #endif \ No newline at end of file diff --git a/src/windows/pathsettings.cpp b/src/windows/pathsettings.cpp new file mode 100644 index 000000000..1975d1ea9 --- /dev/null +++ b/src/windows/pathsettings.cpp @@ -0,0 +1,615 @@ +/* + Copyright (C) 2007 Hicoder + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ +/* notes: will not save paths for current session if IDCANCEL is sent it +will only change paths for that session + +the only way paths will be saved is if IDOK is sent + +the default paths are saved on first load +*/ + +#include "../common.h" +#include +#include +#include +#include +#include +#include "main.h" +#include "NDSSystem.h" +#include "pathSettings.h" +#include "../debug.h" +#include "common.h" + +/*macros to forward messages +the dialog procedure was getting long and confusing for me +*/ +#define HANDLE_DLGMSG(hwnd, message, fn) \ + case (message): return (SetDlgMsgResult(hDlg, uMsg, \ + HANDLE_##message( (hwnd), (wParam), (lParam), (fn) ) ) ) + + +/*variable declaration*/ + +char pathToRoms[MAX_PATH]; +char pathToBattery[MAX_PATH]; +char pathToStates[MAX_PATH]; +char pathToScreenshots[MAX_PATH]; +char pathToAviFiles[MAX_PATH]; +char pathToCheats[MAX_PATH]; +char pathToSounds[MAX_PATH]; +char pathToFirmware[MAX_PATH]; +char pathToModule[MAX_PATH]; +char pathToLua[MAX_PATH]; +char screenshotFormat[MAX_FORMAT]; + +char *currentSelection = 0; +char *currentKey = 0; + +BOOL romsLastVisit = FALSE; +BOOL needsSaving = FALSE; + +ImageFormat defaultFormat = PNG; + +/* end variable declaration*/ + +/*private functions*/ + +void ReadKey(char *pathToRead, const char *key) +{ + ZeroMemory(pathToRead, sizeof(pathToRead)); + GetPrivateProfileString(SECTION, key, key, pathToRead, MAX_PATH, IniName); + if(strcmp(pathToRead, key) == 0) + //since the variables are all intialized in this file they all use MAX_PATH + GetDefaultPath(pathToRead, key, MAX_PATH); +} + +int InitialFolder(HWND hwnd, UINT uMsg, LPARAM lParam, LPARAM lpData) +{ + if(uMsg == BFFM_INITIALIZED) + { + SendMessage(hwnd, BFFM_SETSELECTION, (WPARAM)TRUE, lpData); + } + return 0; +} + +BOOL BrowseForPath(char *pathToBrowse) +{ + LPMALLOC shMalloc; + BOOL changed = false; + LPITEMIDLIST idList; + BROWSEINFO bi; + + //stupid shell + if(SHGetMalloc( &shMalloc) != S_OK) + return FALSE; + + ZeroMemory(&idList, sizeof(idList)); + ZeroMemory(&bi, sizeof(bi)); + + char tmp[MAX_PATH]; + strncpy(tmp, pathToBrowse, MAX_PATH); + + bi.hwndOwner = MainWindow->getHWnd(); + bi.lpszTitle = "Choose a Folder"; + bi.ulFlags = BIF_NONEWFOLDERBUTTON; + + /*wanted to add a callback function for the folder initialization but it crashes everytime i do + bi.lpfn = (BFFCALLBACK)InitialFolder; + bi.lParam = (LPARAM)pathToBrowse; + */ + + if( (idList = SHBrowseForFolder(&bi)) ) + { + changed = true; + SHGetPathFromIDList(idList, pathToBrowse); +// shMalloc->Free(&idList); + } + + return changed; +} + +void LoadModulePath() +{ + //stolen from common.cpp GetINIPath + char *p; + ZeroMemory(pathToModule, sizeof(pathToModule)); + GetModuleFileName(NULL, pathToModule, sizeof(pathToModule)); + p = pathToModule + lstrlen(pathToModule); + while (p >= pathToModule && *p != '\\') p--; + if (++p >= pathToModule) *p = 0; +} + +void SwitchPath(Action action, KnownPath path, char * buffer, int maxCount) +{ + char *pathToCopy = 0; + switch(path) + { + case ROMS: + pathToCopy = pathToRoms; + break; + case BATTERY: + pathToCopy = pathToBattery; + break; + case STATES: + pathToCopy = pathToStates; + break; + case SCREENSHOTS: + pathToCopy = pathToScreenshots; + break; + case AVI_FILES: + pathToCopy = pathToAviFiles; + break; + case CHEATS: + pathToCopy = pathToCheats; + break; + case SOUNDS: + pathToCopy = pathToSounds; + break; + case FIRMWARE: + pathToCopy = pathToFirmware; + break; + case MODULE: + pathToCopy = pathToModule; + break; + } + + if(action == GET) + { + strncpy(buffer, pathToCopy, maxCount); + int len = strlen(buffer)-1; + if(buffer[len] != '\\') + strcat(buffer, "\\"); + } + else if(action == SET) + { + int len = strlen(buffer)-1; + if(buffer[len] == '\\') + buffer[len] = '\0'; + + strncpy(pathToCopy, buffer, MAX_PATH); + } +} + +/* end private functions */ + +/* public functions */ + +//returns "filename" +void GetFilename(char *buffer, int maxCount) +{ + strcpy(buffer,GetRomNameWithoutExtension().c_str()); +} + +void GetFullPathNoExt(KnownPath path, char *buffer, int maxCount) +{ + GetPathFor(path, buffer, maxCount); + char filename[MAX_PATH]; + ZeroMemory(filename, sizeof(filename)); + GetFilename(filename, MAX_PATH); + strcat(buffer, filename); +} + +void GetPathFor(KnownPath path, char *buffer, int maxCount) +{ + SwitchPath(GET, path, buffer, maxCount); +} + +void SetPathFor(KnownPath path, char *buffer) +{ + SwitchPath(SET, path, buffer, 0); +} + +void GetDefaultPath(char *pathToDefault, const char *key, int maxCount) +{ + strncpy(pathToDefault, pathToModule, maxCount); +// strcat(pathToDefault, key); + +// if(GetFileAttributes(pathToDefault) == INVALID_FILE_ATTRIBUTES) +// CreateDirectory(pathToDefault, NULL); +} + +void WritePathSettings() +{ + WritePrivateProfileString(SECTION, ROMKEY, pathToRoms, IniName); + WritePrivateProfileString(SECTION, BATTERYKEY, pathToBattery, IniName); + WritePrivateProfileString(SECTION, STATEKEY, pathToStates, IniName); + WritePrivateProfileString(SECTION, SCREENSHOTKEY, pathToScreenshots, IniName); + WritePrivateProfileString(SECTION, AVIKEY, pathToAviFiles, IniName); + WritePrivateProfileString(SECTION, CHEATKEY, pathToCheats, IniName); + WritePrivateProfileString(SECTION, SOUNDKEY, pathToSounds, IniName); + WritePrivateProfileString(SECTION, FIRMWAREKEY, pathToFirmware, IniName); + WritePrivateProfileString(SECTION, LUAKEY, pathToLua, IniName); + + WritePrivateProfileString(SECTION, FORMATKEY, screenshotFormat, IniName); + + WritePrivateProfileInt(SECTION, LASTVISITKEY, romsLastVisit, IniName); + WritePrivateProfileInt(SECTION, DEFAULTFORMATKEY, defaultFormat, IniName); + WritePrivateProfileInt(SECTION, NEEDSSAVINGKEY, needsSaving, IniName); +} + +void ReadPathSettings() +{ + if( ( strcmp(pathToModule, "") == 0) || !pathToModule) + LoadModulePath(); + + ReadKey(pathToRoms, ROMKEY); + ReadKey(pathToBattery, BATTERYKEY); + ReadKey(pathToStates, STATEKEY); + ReadKey(pathToScreenshots, SCREENSHOTKEY); + ReadKey(pathToAviFiles, AVIKEY); + ReadKey(pathToCheats, CHEATKEY); + ReadKey(pathToSounds, SOUNDKEY); + ReadKey(pathToFirmware, FIRMWAREKEY); + ReadKey(pathToLua, LUAKEY); + + GetPrivateProfileString(SECTION, FORMATKEY, "%f_%s_%r", screenshotFormat, MAX_FORMAT, IniName); + + romsLastVisit = GetPrivateProfileInt(SECTION, LASTVISITKEY, TRUE, IniName); + defaultFormat = (ImageFormat)GetPrivateProfileInt(SECTION, DEFAULTFORMATKEY, PNG, IniName); + + needsSaving = GetPrivateProfileInt(SECTION, NEEDSSAVINGKEY, TRUE, IniName); + if(needsSaving) + { + needsSaving = FALSE; + WritePathSettings(); + } +} + +ImageFormat GetImageFormatType() +{ + return defaultFormat; +} + +void FormatName(char *output, int maxCount) +{ + char file[MAX_PATH]; + ZeroMemory(file, sizeof(file)); + time_t now = time(NULL); + tm *time_struct = localtime(&now); + srand(now); + + for(int i = 0; i < MAX_FORMAT;i++) + { + char *c = &screenshotFormat[i]; + char tmp[MAX_PATH]; + ZeroMemory(tmp, sizeof(tmp)); + + if(*c == '%') + { + c = &screenshotFormat[++i]; + switch(*c) + { + case 'f': + GetFilename(tmp, MAX_PATH); + break; + case 'D': + strftime(tmp, MAX_PATH, "%d", time_struct); + break; + case 'M': + strftime(tmp, MAX_PATH, "%m", time_struct); + break; + case 'Y': + strftime(tmp, MAX_PATH, "%Y", time_struct); + break; + case 'h': + strftime(tmp, MAX_PATH, "%H", time_struct); + break; + case 'm': + strftime(tmp, MAX_PATH, "%M", time_struct); + break; + case 's': + strftime(tmp, MAX_PATH, "%S", time_struct); + break; + case 'r': + sprintf(tmp, "%d", rand() % RAND_MAX); + break; + } + } + else + { + int j; + for(j=i;j 2) ? SRAM_End - SRAM_Start : 0) -#define BRAM_SIZE ((8 << BRAM_Ex_Size) * 1024)*/ -//#define GENESIS_RAM_SIZE (_68K_RAM_SIZE + Z80_RAM_SIZE) - -//_32X_Ram[] -//#define _32X_RAM_SIZE 256*1024 - -//512k in Ram_Prg, 256k in Ram_Word_1M and Ram_Word_2M -//(docs say 6Mbit of ram, but I'm not sure what's used when) -//#define SEGACD_RAM_PRG_SIZE 512*1024 -//#define SEGACD_1M_RAM_SIZE 256*1024 -//#define SEGACD_2M_RAM_SIZE 256*1024 -//#define SEGACD_RAM_SIZE (SEGACD_RAM_PRG_SIZE + SEGACD_2M_RAM_SIZE) - - -//#define MAX_RAM_SIZE (0x112000) -//#define MAX_RAM_SIZE (0xD2000) -#define MAX_RAM_SIZE (0x400000) - -extern char rs_type_size; -extern int ResultCount; - -unsigned int sizeConv(unsigned int index,char size, char *prevSize = &rs_type_size, bool usePrev = false); -unsigned int GetRamValue(unsigned int Addr,char Size); -void prune(char Search, char Operater, char Type, int Value, int OperatorParameter); -void CompactAddrs(); -void reset_address_info(); -void signal_new_frame(); -void signal_new_size(); -void UpdateRamSearchTitleBar(int percent = 0); -void Update_RAM_Search(); -void SetRamSearchUndoType(HWND hDlg, int type); -unsigned int ReadValueAtHardwareAddress(unsigned int address, unsigned int size); -bool WriteValueAtHardwareRAMAddress(unsigned int address, unsigned int value, unsigned int size, bool hookless=false); -bool IsHardwareRAMAddressValid(unsigned int address); -extern int curr_ram_size; -extern bool noMisalign; -extern bool littleEndian; - - -#endif - +//RamSearch dialog was copied and adapted from GENS11: http://code.google.com/p/gens-rerecording/ +//Authors: Upthorn, Nitsuja, adelikat + +#ifndef RAM_SEARCH_H +#define RAM_SEARCH_H + + +//64k in Ram_68k[], 8k in Ram_Z80[] +//#define _68K_RAM_SIZE 64*1024 +//#define Z80_RAM_SIZE 8*1024 +/*#define SRAM_SIZE (((SRAM_End - SRAM_Start) > 2) ? SRAM_End - SRAM_Start : 0) +#define BRAM_SIZE ((8 << BRAM_Ex_Size) * 1024)*/ +//#define GENESIS_RAM_SIZE (_68K_RAM_SIZE + Z80_RAM_SIZE) + +//_32X_Ram[] +//#define _32X_RAM_SIZE 256*1024 + +//512k in Ram_Prg, 256k in Ram_Word_1M and Ram_Word_2M +//(docs say 6Mbit of ram, but I'm not sure what's used when) +//#define SEGACD_RAM_PRG_SIZE 512*1024 +//#define SEGACD_1M_RAM_SIZE 256*1024 +//#define SEGACD_2M_RAM_SIZE 256*1024 +//#define SEGACD_RAM_SIZE (SEGACD_RAM_PRG_SIZE + SEGACD_2M_RAM_SIZE) + + +//#define MAX_RAM_SIZE (0x112000) +//#define MAX_RAM_SIZE (0xD2000) +#define MAX_RAM_SIZE (0x400000) + +extern char rs_type_size; +extern int ResultCount; + +unsigned int sizeConv(unsigned int index,char size, char *prevSize = &rs_type_size, bool usePrev = false); +unsigned int GetRamValue(unsigned int Addr,char Size); +void prune(char Search, char Operater, char Type, int Value, int OperatorParameter); +void CompactAddrs(); +void reset_address_info(); +void signal_new_frame(); +void signal_new_size(); +void UpdateRamSearchTitleBar(int percent = 0); +void Update_RAM_Search(); +void SetRamSearchUndoType(HWND hDlg, int type); +unsigned int ReadValueAtHardwareAddress(unsigned int address, unsigned int size); +bool WriteValueAtHardwareRAMAddress(unsigned int address, unsigned int value, unsigned int size, bool hookless=false); +bool IsHardwareRAMAddressValid(unsigned int address); +extern int curr_ram_size; +extern bool noMisalign; +extern bool littleEndian; + + +#endif + diff --git a/desmume/src/windows/ramwatch.cpp b/src/windows/ramwatch.cpp similarity index 99% rename from desmume/src/windows/ramwatch.cpp rename to src/windows/ramwatch.cpp index e217ad785..a0bb7df40 100644 --- a/desmume/src/windows/ramwatch.cpp +++ b/src/windows/ramwatch.cpp @@ -1,7 +1,7 @@ //RamWatch dialog was copied and adapted from GENS11: http://code.google.com/p/gens-rerecording/ //Authors: Upthorn, Nitsuja, adelikat -#include "main.h" +//#include "main.h" #include "resource.h" #include "common.h" #include "NDSSystem.h" @@ -11,7 +11,6 @@ #include #include #include -#include "path.h" HWND RamWatchHWnd = NULL; @@ -452,7 +451,7 @@ int Change_File_S(char *Dest, char *Dir, char *Titre, char *Filter, char *Ext, H bool Save_Watches() { - Rom_Name = path.GetRomName(); + Rom_Name = GetRomName(); strncpy(Str_Tmp,Rom_Name.c_str(),512); strcat(Str_Tmp,".wch"); if(Change_File_S(Str_Tmp, Gens_Path, "Save Watches", "GENs Watchlist\0*.wch\0All Files\0*.*\0\0", "wch", RamWatchHWnd)) @@ -586,7 +585,7 @@ static int Change_File_L(char *Dest, char *Dir, char *Titre, char *Filter, char bool Load_Watches(bool clear) { - Rom_Name = path.GetRomName(); + Rom_Name = GetRomName(); strncpy(Str_Tmp,Rom_Name.c_str(),512); strcat(Str_Tmp,".wch"); if(Change_File_L(Str_Tmp, Watch_Dir, "Load Watches", "GENs Watchlist\0*.wch\0All Files\0*.*\0\0", "wch", RamWatchHWnd)) diff --git a/desmume/src/windows/ramwatch.h b/src/windows/ramwatch.h similarity index 96% rename from desmume/src/windows/ramwatch.h rename to src/windows/ramwatch.h index 385223b6b..0272b8ebb 100644 --- a/desmume/src/windows/ramwatch.h +++ b/src/windows/ramwatch.h @@ -1,42 +1,42 @@ -//RamWatch dialog was copied and adapted from GENS11: http://code.google.com/p/gens-rerecording/ -//Authors: Upthorn, Nitsuja, adelikat - -#ifndef RAMWATCH_H -#define RAMWATCH_H -#include "windows.h" -bool ResetWatches(); -void OpenRWRecentFile(int memwRFileNumber); -extern bool AutoRWLoad; -extern bool RWSaveWindowPos; -#define MAX_RECENT_WATCHES 5 -extern char rw_recent_files[MAX_RECENT_WATCHES][1024]; -extern bool AskSave(); -extern int ramw_x; -extern int ramw_y; -extern bool RWfileChanged; - -// AddressWatcher is self-contained now -struct AddressWatcher -{ - unsigned int Address; // hardware address - char Size; - char Type; - char* comment; // NULL means no comment, non-NULL means allocated comment - bool WrongEndian; - unsigned int CurValue; -}; -#define MAX_WATCH_COUNT 256 -extern AddressWatcher rswatches[MAX_WATCH_COUNT]; -extern int WatchCount; // number of valid items in rswatches - -extern char Watch_Dir[1024]; - -bool InsertWatch(const AddressWatcher& Watch, char *Comment); -bool InsertWatch(const AddressWatcher& Watch, HWND parent=NULL); // asks user for comment -void Update_RAM_Watch(); -bool Load_Watches(bool clear, const char* filename); - -LRESULT CALLBACK RamWatchProc(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam); -extern HWND RamWatchHWnd; - -#endif +//RamWatch dialog was copied and adapted from GENS11: http://code.google.com/p/gens-rerecording/ +//Authors: Upthorn, Nitsuja, adelikat + +#ifndef RAMWATCH_H +#define RAMWATCH_H +#include "windows.h" +bool ResetWatches(); +void OpenRWRecentFile(int memwRFileNumber); +extern bool AutoRWLoad; +extern bool RWSaveWindowPos; +#define MAX_RECENT_WATCHES 5 +extern char rw_recent_files[MAX_RECENT_WATCHES][1024]; +extern bool AskSave(); +extern int ramw_x; +extern int ramw_y; +extern bool RWfileChanged; + +// AddressWatcher is self-contained now +struct AddressWatcher +{ + unsigned int Address; // hardware address + char Size; + char Type; + char* comment; // NULL means no comment, non-NULL means allocated comment + bool WrongEndian; + unsigned int CurValue; +}; +#define MAX_WATCH_COUNT 256 +extern AddressWatcher rswatches[MAX_WATCH_COUNT]; +extern int WatchCount; // number of valid items in rswatches + +extern char Watch_Dir[1024]; + +bool InsertWatch(const AddressWatcher& Watch, char *Comment); +bool InsertWatch(const AddressWatcher& Watch, HWND parent=NULL); // asks user for comment +void Update_RAM_Watch(); +bool Load_Watches(bool clear, const char* filename); + +LRESULT CALLBACK RamWatchProc(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam); +extern HWND RamWatchHWnd; + +#endif diff --git a/desmume/src/windows/replay.cpp b/src/windows/replay.cpp similarity index 75% rename from desmume/src/windows/replay.cpp rename to src/windows/replay.cpp index bcf9c49c9..911da6088 100644 --- a/desmume/src/windows/replay.cpp +++ b/src/windows/replay.cpp @@ -37,8 +37,8 @@ void Describe(HWND hwndDlg) u32 num_frames = md.records.size(); double tempCount = num_frames / (33513982.0/6/355/263); - int num_seconds = (int)tempCount; - int fraction = ((int)tempCount - num_seconds) * 100; + int num_seconds = tempCount; + int fraction = (tempCount - num_seconds) * 100; int seconds = num_seconds % 60; int minutes = (num_seconds / 60) % 60; int hours = (num_seconds / 60 / 60) % 60; @@ -110,8 +110,6 @@ BOOL CALLBACK ReplayDialogProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lP return false; } -int flag=0; -std::string sramfname; //Record movie dialog static BOOL CALLBACK RecordDialogProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lParam) @@ -123,7 +121,6 @@ static BOOL CALLBACK RecordDialogProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LP switch(uMsg) { case WM_INITDIALOG: - CheckDlgButton(hwndDlg, IDC_START_FROM_SRAM, ((flag == 1) ? BST_CHECKED : BST_UNCHECKED)); return false; case WM_COMMAND: @@ -134,7 +131,7 @@ static BOOL CALLBACK RecordDialogProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LP fname = GetDlgItemText(hwndDlg,IDC_EDIT_FILENAME); if (fname.length()) { - FCEUI_SaveMovie(fname.c_str(), author, flag, sramfname); + FCEUI_SaveMovie(fname.c_str(), author); EndDialog(hwndDlg, 0); } return true; @@ -173,47 +170,11 @@ static BOOL CALLBACK RecordDialogProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LP return true; } - case IDC_BUTTON_BROWSESRAM: - { - OPENFILENAME ofn; - char szChoice[MAX_PATH]={0}; - // browse button - ZeroMemory(&ofn, sizeof(ofn)); - ofn.lStructSize = sizeof(ofn); - ofn.hwndOwner = MainWindow->getHWnd(); - ofn.lpstrFilter = "Desmume SRAM File (*.dsv)\0*.dsv\0All files(*.*)\0*.*\0\0"; - ofn.lpstrFile = szChoice; - ofn.lpstrTitle = "Choose SRAM"; - ofn.lpstrDefExt = "dsv"; - ofn.nMaxFile = MAX_PATH; - ofn.Flags = OFN_HIDEREADONLY | OFN_OVERWRITEPROMPT; - GetOpenFileName(&ofn); - - //If user did not specify an extension, add .dsm for them - fname = szChoice; - x = fname.find_last_of("."); - if (x < 0) - fname.append(".dsv"); - - SetDlgItemText(hwndDlg, IDC_EDIT_SRAMFILENAME, fname.c_str()); - sramfname=(std::string)fname; - //if(GetSaveFileName(&ofn)) - // UpdateRecordDialogPath(hwndDlg,szChoice); - - return true; - } } + } - - HWND cur = GetDlgItem(hwndDlg, IDC_EDIT_SRAMFILENAME); - IsDlgButtonChecked(hwndDlg, IDC_START_FROM_SRAM) ? flag=1 : flag=0; - IsDlgButtonChecked(hwndDlg, IDC_START_FROM_SRAM) ? EnableWindow(cur, TRUE) : EnableWindow(cur, FALSE); - - cur = GetDlgItem(hwndDlg, IDC_BUTTON_BROWSESRAM); - IsDlgButtonChecked(hwndDlg, IDC_START_FROM_SRAM) ? EnableWindow(cur, TRUE) : EnableWindow(cur, FALSE); - return false; } diff --git a/desmume/src/windows/replay.h b/src/windows/replay.h similarity index 95% rename from desmume/src/windows/replay.h rename to src/windows/replay.h index d721b31b5..6a0880b94 100644 --- a/desmume/src/windows/replay.h +++ b/src/windows/replay.h @@ -1,2 +1,2 @@ -void Replay_LoadMovie(); -void MovieRecordTo(); +void Replay_LoadMovie(); +void MovieRecordTo(); diff --git a/desmume/src/windows/resource.h b/src/windows/resource.h similarity index 94% rename from desmume/src/windows/resource.h rename to src/windows/resource.h index c08994851..7900b6090 100644 --- a/desmume/src/windows/resource.h +++ b/src/windows/resource.h @@ -120,24 +120,23 @@ #define IDC_PNG 325 #define IDC_BMP 326 #define IDC_FORMATSTATIC 327 -#define IDM_PATHSETTINGS 350 -#define IDC_ROMPATHEDIT 351 -#define IDC_BROWSEROMS 352 -#define IDC_PATHDEFAULTS 353 -#define IDC_SAVERAMPATHEDIT 354 -#define IDC_BROWSESRAM 355 -#define IDC_STATEPATHEDIT 356 -#define IDC_BROWSESTATES 357 -#define IDC_SCREENSHOTPATHEDIT 358 -#define IDC_BROWSESCREENSHOTS 359 -#define IDC_AVIPATHEDIT 360 -#define IDC_BROWSEAVI 361 -#define IDC_CHEATPATHEDIT 362 -#define IDC_BROWSECHEATS 363 -#define IDC_LUAPATHEDIT 364 -#define IDC_BROWSELUA 365 -#define IDD_PATHSETTINGS 366 -#define IDC_STATEREWINDING 367 +#define IDM_PATHSETTINGS 350 +#define IDC_ROMPATHEDIT 351 +#define IDC_BROWSEROMS 352 +#define IDC_PATHDEFAULTS 353 +#define IDC_SAVERAMPATHEDIT 354 +#define IDC_BROWSESRAM 355 +#define IDC_STATEPATHEDIT 356 +#define IDC_BROWSESTATES 357 +#define IDC_SCREENSHOTPATHEDIT 358 +#define IDC_BROWSESCREENSHOTS 359 +#define IDC_AVIPATHEDIT 360 +#define IDC_BROWSEAVI 361 +#define IDC_CHEATPATHEDIT 362 +#define IDC_BROWSECHEATS 363 +#define IDC_LUAPATHEDIT 364 +#define IDC_BROWSELUA 365 +#define IDD_PATHSETTINGS 366 #define IDC_DES_BOX 402 #define IDC_R0 403 #define IDC_R1 404 @@ -163,13 +162,6 @@ #define IDC_TMP 424 #define IDD_GAME_INFO 501 #define ID_RAM_WATCH 550 -#define IDM_RENDER_NORMAL 551 -#define IDM_RENDER_HQ2X 552 -#define IDM_RENDER_2XSAI 553 -#define IDM_RENDER_SUPER2XSAI 554 -#define IDM_RENDER_SUPEREAGLE 555 -#define IDM_RENDER_SCANLINE 556 -#define IDM_RENDER_BILINEAR 557 #define IDD_IO_REG 601 #define IDM_RECORD_MOVIE 602 #define IDM_PLAY_MOVIE 603 @@ -305,17 +297,13 @@ #define IDC_EDIT07 1005 #define IDC_MROM 1005 #define IDC_ROTATE180 1005 -#define IDC_GGREEN 1005 #define IDC_EDIT12 1006 #define IDC_ROTATE270 1006 #define IDC_SPU_CACHE 1006 -#define IDC_GRED 1006 #define IDC_ARM7BIOSBROWSE 1007 #define IDC_EDIT06 1007 -#define IDC_GYELLOW 1007 #define IDC_EDIT09 1008 #define IDC_MEMVIEWBOX 1008 -#define IDC_GBLUE 1008 #define IDC_ADDRESS 1009 #define IDC_BIOSSWIS 1009 #define IDC_EDIT10 1009 @@ -403,15 +391,6 @@ #define IDC_LIST 1069 #define IDC_SNUMBER 1071 #define IDC_CHECK1 1074 -#define IDC_CHECK2 1075 - -#define IDC_CHECK3 1076 - -#define IDC_CHECK4 1077 -#define IDC_CHECK6 1080 -#define IDC_CHECK7 1082 -#define IDC_CHECK8 1083 -#define IDC_CHECK9 1088 #define IDM_FIRMSETTINGS 1100 #define IDD_FIRMSETTINGS 1101 #define IDC_EDIT1 1102 @@ -625,14 +604,6 @@ #define IDC_SOUND5POSLEN 1451 #define IDC_SOUND6POSLEN 1452 #define IDC_SOUND7POSLEN 1453 -#define IDC_SOUND0MUTE 2001 -#define IDC_SOUND1MUTE 2002 -#define IDC_SOUND2MUTE 2003 -#define IDC_SOUND3MUTE 2004 -#define IDC_SOUND4MUTE 2005 -#define IDC_SOUND5MUTE 2006 -#define IDC_SOUND6MUTE 2007 -#define IDC_SOUND7MUTE 2008 #define IDC_GI_FATOFS 4464 #define IDC_INTERPOLATECOLOR 4464 #define IDC_GI_FATSIZE 4465 @@ -673,7 +644,6 @@ #define IDD_IOREG_VIEW_DMA 10006 #define IDD_IOREG_VIEW_TIMERS 10007 #define IDD_IOREG_VIEW_IPC_ROM 10008 -#define IDD_GBASLOT_GUITARGRIP 10009 #define IDM_FILE_STOPAVI 40000 #define IDM_SCREENSEP_NONE 40000 #define IDM_FILE_STOPWAV 40001 @@ -798,7 +768,7 @@ #ifndef APSTUDIO_READONLY_SYMBOLS #define _APS_NEXT_RESOURCE_VALUE 105 #define _APS_NEXT_COMMAND_VALUE 40008 -#define _APS_NEXT_CONTROL_VALUE 1006 +#define _APS_NEXT_CONTROL_VALUE 1005 #define _APS_NEXT_SYMED_VALUE 101 #endif #endif diff --git a/desmume/src/windows/resources.rc b/src/windows/resources.rc similarity index 99% rename from desmume/src/windows/resources.rc rename to src/windows/resources.rc index 579d1e946838eef67268d0cd1044c319dedda136..3bed6fd5801eaf86aed1e77f8eccd5b4006ce833 100644 GIT binary patch delta 413 zcmbWyze@sP90u@v@4b6_y)>GV&ODD(Dvu*f>6b_~v^3e0Lr9ZT5YbPY;)LiVqO2Rf zi^D%|%d9RVp0`a$g_Mkz zY^ONVo!|^^l8d_ys7d|yRZeAJ1E^O(qfnSY^AI}`9kx7777&<=q7J1~B;YwN4eLP^ zf@GL@Q5*^fGzj{&M`F`4LXnk=xZznYg8Mev(K*$pz{!gmG|QA&wK`_Cx=;&4tBn=A zysv@$gLL>y8=eIDc5d$g#)Nohk*YO!5RNUa!xK&u4 z5d%<6iC$1tVz@ZpA8wqB!`nR`17nbAtf7(eKYdom*GX5$Nu3O2cklyTSo97a^Y{$f qMXIyCU0g-*dPpysaZKOSU_Rp)R$7s=m?b}`*>7ce56kjWW%~zV@Q1+w delta 2215 zcmai0T})GF7=91mIj86FQ%guKr6~PzfTY`KkxIp6MJbg8p#_O<7h_DE;tzkKn-|+y zyr>t>NlxO6iBVVNfyi)jm!YxFF6K-L7{I*A+m8IYIu<}7HJjpiU zC^A_Ojj)F@e{R4#rdwPmI$+%@vl57suIj^7Pi{?0)hTAAQAs zOByW~=8TnBQbxRXg}e(duw1=og565_{PJy@^4QfBC0edCQUBsQ_G1cj^G2HYkDGJ6 z=BYIAC?m8QA*$64TlM2M;S~XU&Z_2|h;a}m(ao6usp=rZ0Sbx-JAh*kvsS2n z2vW!TVGZV=Rri=UPZ;VK2b+@MDtvHO-Io`E*9qE0R|{-i+#$tY4Ss`NjnLdRk?Qbs z;QMYVwhF4OHUSm(*ZRhAhq1?ZETv zB-vC==U%A7;UBUJv{0AZlvZN+bJhUVaDSUNyU$&ckteF&PU^XCs$sH@U9ew^?Jmiy zg0d~70%pIaTH=M}GA)x{SgsstXFd`a>tnsT>gfafronq*lsR=WV|ZDRwTn6rHD7wpQ6~w(_i3)5ZHIkm{o#_J72DR2yQ|hW~X* zoN+Ba?qy~Axx=hf(1#8ypEcu~$E6A!{ZbT7J77EP0Ux?Xn4N8gc6`vPw5v%eR2RIy zp4p7w#HY})GtZ)HcsZ6p6Ss|8C(WM2*?n|TPb}dvb1s8Fg{KZ%8b7fRA9xP`pH~;+ zgOtam^yJ@o7Vjth&xtsZfnUbsr5QK=L-1B~#U&S-@3L$9-*=Uti&0rFo3Y0xnDP9q cvJRuOO0h&Z8pQrt#S>3FR`kSU_40xL0em1Bq5uE@ diff --git a/src/windows/snddx.cpp b/src/windows/snddx.cpp new file mode 100644 index 000000000..25f07ce80 --- /dev/null +++ b/src/windows/snddx.cpp @@ -0,0 +1,319 @@ +/* Copyright (C) 2005-2007 Theo Berkau + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#include +#include +#include "directx/dsound.h" +#ifdef __MINGW32__ +// I have to do this because for some reason because the dxerr8.h header is fubared +const char* __stdcall DXGetErrorString8A(HRESULT hr); +#define DXGetErrorString8 DXGetErrorString8A +const char* __stdcall DXGetErrorDescription8A(HRESULT hr); +#define DXGetErrorDescription8 DXGetErrorDescription8A +#else +#include "directx/dxerr8.h" +#endif +#include "SPU.h" +#include "snddx.h" +#include "CWindow.h" +#include "windriver.h" + +int SNDDXInit(int buffersize); +void SNDDXDeInit(); +void SNDDXUpdateAudio(s16 *buffer, u32 num_samples); +u32 SNDDXGetAudioSpace(); +void SNDDXMuteAudio(); +void SNDDXUnMuteAudio(); +void SNDDXSetVolume(int volume); + +SoundInterface_struct SNDDIRECTX = { +SNDCORE_DIRECTX, +"Direct Sound Interface", +SNDDXInit, +SNDDXDeInit, +SNDDXUpdateAudio, +SNDDXGetAudioSpace, +SNDDXMuteAudio, +SNDDXUnMuteAudio, +SNDDXSetVolume +}; + +LPDIRECTSOUND8 lpDS8; +LPDIRECTSOUNDBUFFER lpDSB, lpDSB2; + +extern WINCLASS *MainWindow; + +static s16 *stereodata16; +static u32 soundoffset=0; +static u32 soundbufsize; +static LONG soundvolume; +static int issoundmuted; + +////////////////////////////////////////////////////////////////////////////// + +static volatile bool doterminate; +static volatile bool terminated; + +extern CRITICAL_SECTION win_sync; +extern volatile int win_sound_samplecounter; + +DWORD WINAPI SNDDXThread( LPVOID ) +{ + for(;;) { + if(doterminate) break; + { + Lock lock; + SPU_Emulate_user(); + } + Sleep(10); + } + terminated = true; + return 0; +} + +int SNDDXInit(int buffersize) +{ + DSBUFFERDESC dsbdesc; + WAVEFORMATEX wfx; + HRESULT ret; + char tempstr[512]; + + if ((ret = DirectSoundCreate8(NULL, &lpDS8, NULL)) != DS_OK) + { + sprintf(tempstr, "DirectSound8Create error: %s - %s", DXGetErrorString8(ret), DXGetErrorDescription8(ret)); + MessageBox (NULL, tempstr, "Error", MB_OK | MB_ICONINFORMATION); + return -1; + } + + if ((ret = IDirectSound8_SetCooperativeLevel(lpDS8, MainWindow->getHWnd(), DSSCL_PRIORITY)) != DS_OK) + { + sprintf(tempstr, "IDirectSound8_SetCooperativeLevel error: %s - %s", DXGetErrorString8(ret), DXGetErrorDescription8(ret)); + MessageBox (NULL, tempstr, "Error", MB_OK | MB_ICONINFORMATION); + return -1; + } + + memset(&dsbdesc, 0, sizeof(dsbdesc)); + dsbdesc.dwSize = sizeof(DSBUFFERDESC); + dsbdesc.dwFlags = DSBCAPS_PRIMARYBUFFER; + dsbdesc.dwBufferBytes = 0; + dsbdesc.lpwfxFormat = NULL; + + if ((ret = IDirectSound8_CreateSoundBuffer(lpDS8, &dsbdesc, &lpDSB, NULL)) != DS_OK) + { + sprintf(tempstr, "Error when creating primary sound buffer: %s - %s", DXGetErrorString8(ret), DXGetErrorDescription8(ret)); + MessageBox (NULL, tempstr, "Error", MB_OK | MB_ICONINFORMATION); + return -1; + } + + soundbufsize = buffersize * 2 * 2; + + memset(&wfx, 0, sizeof(wfx)); + wfx.wFormatTag = WAVE_FORMAT_PCM; + wfx.nChannels = 2; + wfx.nSamplesPerSec = 44100; + wfx.wBitsPerSample = 16; + wfx.nBlockAlign = (wfx.wBitsPerSample / 8) * wfx.nChannels; + wfx.nAvgBytesPerSec = wfx.nSamplesPerSec * wfx.nBlockAlign; + + if ((ret = IDirectSoundBuffer8_SetFormat(lpDSB, &wfx)) != DS_OK) + { + sprintf(tempstr, "IDirectSoundBuffer8_SetFormat error: %s - %s", DXGetErrorString8(ret), DXGetErrorDescription8(ret)); + MessageBox (NULL, tempstr, "Error", MB_OK | MB_ICONINFORMATION); + return -1; + } + + memset(&dsbdesc, 0, sizeof(dsbdesc)); + dsbdesc.dwSize = sizeof(DSBUFFERDESC); + dsbdesc.dwFlags = DSBCAPS_GLOBALFOCUS | DSBCAPS_STICKYFOCUS | + DSBCAPS_CTRLVOLUME | DSBCAPS_GETCURRENTPOSITION2 | + DSBCAPS_LOCHARDWARE; + dsbdesc.dwBufferBytes = soundbufsize; + dsbdesc.lpwfxFormat = &wfx; + + if ((ret = IDirectSound8_CreateSoundBuffer(lpDS8, &dsbdesc, &lpDSB2, NULL)) != DS_OK) + { + if (ret == DSERR_CONTROLUNAVAIL || + ret == DSERR_INVALIDCALL || + ret == E_FAIL || + ret == E_NOTIMPL) + { + // Try using a software buffer instead + dsbdesc.dwFlags = DSBCAPS_GLOBALFOCUS | DSBCAPS_STICKYFOCUS | + DSBCAPS_CTRLVOLUME | DSBCAPS_GETCURRENTPOSITION2 | + DSBCAPS_LOCSOFTWARE; + + if ((ret = IDirectSound8_CreateSoundBuffer(lpDS8, &dsbdesc, &lpDSB2, NULL)) != DS_OK) + { + sprintf(tempstr, "Error when creating secondary sound buffer: %s - %s", DXGetErrorString8(ret), DXGetErrorDescription8(ret)); + MessageBox (NULL, tempstr, "Error", MB_OK | MB_ICONINFORMATION); + return -1; + } + } + else + { + sprintf(tempstr, "Error when creating secondary sound buffer: %s - %s", DXGetErrorString8(ret), DXGetErrorDescription8(ret)); + MessageBox (NULL, tempstr, "Error", MB_OK | MB_ICONINFORMATION); + return -1; + } + } + + IDirectSoundBuffer8_Play(lpDSB2, 0, 0, DSBPLAY_LOOPING); + + if ((stereodata16 = (s16 *)malloc(soundbufsize)) == NULL) + return -1; + + memset(stereodata16, 0, soundbufsize); + + soundvolume = DSBVOLUME_MAX; + issoundmuted = 0; + + doterminate = false; + terminated = false; + CreateThread(0,0,SNDDXThread,0,0,0); + + return 0; +} + +////////////////////////////////////////////////////////////////////////////// + +void SNDDXDeInit() +{ + DWORD status=0; + + doterminate = true; + while(!terminated) { + Sleep(1); + } + + if (lpDSB2) + { + IDirectSoundBuffer8_GetStatus(lpDSB2, &status); + + if(status == DSBSTATUS_PLAYING) + IDirectSoundBuffer8_Stop(lpDSB2); + + IDirectSoundBuffer8_Release(lpDSB2); + lpDSB2 = NULL; + } + + if (lpDSB) + { + IDirectSoundBuffer8_Release(lpDSB); + lpDSB = NULL; + } + + if (lpDS8) + { + IDirectSound8_Release(lpDS8); + lpDS8 = NULL; + } +} + +////////////////////////////////////////////////////////////////////////////// + +void SNDDXUpdateAudio(s16 *buffer, u32 num_samples) +{ + LPVOID buffer1; + LPVOID buffer2; + DWORD buffer1_size, buffer2_size; + DWORD status; + + int samplecounter; + { + Lock lock; + samplecounter = win_sound_samplecounter -= num_samples; + } + + bool silence = (samplecounter<-44100*15/60); //behind by more than a quarter second -> silence + + IDirectSoundBuffer8_GetStatus(lpDSB2, &status); + + if (status & DSBSTATUS_BUFFERLOST) + return; // fix me + + IDirectSoundBuffer8_Lock(lpDSB2, soundoffset, num_samples * sizeof(s16) * 2, &buffer1, &buffer1_size, &buffer2, &buffer2_size, 0); + + if(silence) { + memset(buffer1, 0, buffer1_size); + if(buffer2) + memset(buffer2, 0, buffer2_size); + } + else + { + memcpy(buffer1, buffer, buffer1_size); + if (buffer2) + memcpy(buffer2, ((u8 *)buffer)+buffer1_size, buffer2_size); + } + + soundoffset += buffer1_size + buffer2_size; + soundoffset %= soundbufsize; + + IDirectSoundBuffer8_Unlock(lpDSB2, buffer1, buffer1_size, buffer2, buffer2_size); +} + +////////////////////////////////////////////////////////////////////////////// + +u32 SNDDXGetAudioSpace() +{ + DWORD playcursor, writecursor; + u32 freespace=0; + + if (IDirectSoundBuffer8_GetCurrentPosition (lpDSB2, &playcursor, &writecursor) != DS_OK) + return 0; + + if (soundoffset > playcursor) + freespace = soundbufsize - soundoffset + playcursor; + else + freespace = playcursor - soundoffset; + +// if (freespace > 512) + return (freespace / 2 / 2); +// else +// return 0; +} + +////////////////////////////////////////////////////////////////////////////// + +void SNDDXMuteAudio() +{ + issoundmuted = 1; + IDirectSoundBuffer8_SetVolume (lpDSB2, DSBVOLUME_MIN); +} + +////////////////////////////////////////////////////////////////////////////// + +void SNDDXUnMuteAudio() +{ + issoundmuted = 0; + IDirectSoundBuffer8_SetVolume (lpDSB2, soundvolume); +} + +////////////////////////////////////////////////////////////////////////////// + +void SNDDXSetVolume(int volume) +{ + if (!lpDSB2) return ; /* might happen when changing sounddevice on the fly, caused a gpf */ + soundvolume = (((LONG)volume) - 100) * 100; + if (!issoundmuted) + IDirectSoundBuffer8_SetVolume (lpDSB2, soundvolume); +} + +////////////////////////////////////////////////////////////////////////////// + + diff --git a/desmume/src/windows/snddx.h b/src/windows/snddx.h old mode 100755 new mode 100644 similarity index 97% rename from desmume/src/windows/snddx.h rename to src/windows/snddx.h index bb75bc086..245411751 --- a/desmume/src/windows/snddx.h +++ b/src/windows/snddx.h @@ -1,25 +1,25 @@ -/* Copyright (C) 2006 Theo Berkau - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#ifndef SNDDX_H -#define SNDDX_H -#define SNDCORE_DIRECTX 2 - -extern SoundInterface_struct SNDDIRECTX; -#endif +/* Copyright (C) 2006 Theo Berkau + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#ifndef SNDDX_H +#define SNDDX_H +#define SNDCORE_DIRECTX 2 + +extern SoundInterface_struct SNDDIRECTX; +#endif diff --git a/desmume/src/windows/soundView.cpp b/src/windows/soundView.cpp similarity index 83% rename from desmume/src/windows/soundView.cpp rename to src/windows/soundView.cpp index 128568ad8..70cdf2bd1 100644 --- a/desmume/src/windows/soundView.cpp +++ b/src/windows/soundView.cpp @@ -1,323 +1,285 @@ -/* Copyright (C) 2006 yopyop - yopyop156@ifrance.com - yopyop156.ifrance.com - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - - -#include "../SPU.h" -#include "../debug.h" -#include "../common.h" -#include "../matrix.h" -#include "resource.h" -#include "NDSSystem.h" -#include -#include -#include -#include -#include "soundView.h" - -#include - -using namespace std; - -////////////////////////////////////////////////////////////////////////////// - -typedef struct SoundView_DataStruct -{ - SoundView_DataStruct() - : viewFirst8Channels(TRUE) - , volModeAlternate(FALSE) - { - } - - HWND hDlg; - - BOOL viewFirst8Channels; - BOOL volModeAlternate; -} SoundView_DataStruct; - -SoundView_DataStruct * SoundView_Data = NULL; - -////////////////////////////////////////////////////////////////////////////// - -BOOL SoundView_Init() -{ - return 1; -} - -void SoundView_DeInit() -{ -} - -////////////////////////////////////////////////////////////////////////////// - -inline int chanOfs() -{ - return SoundView_Data->viewFirst8Channels ? 0 : 8; -} - -BOOL SoundView_DlgOpen(HWND hParentWnd) -{ - HWND hDlg; - - SoundView_Data = new SoundView_DataStruct(); - if(SoundView_Data == NULL) - return 0; - - hDlg = CreateDialogParam(hAppInst, MAKEINTRESOURCE(IDD_SOUND_VIEW), hParentWnd, SoundView_DlgProc, (LPARAM)SoundView_Data); - if(hDlg == NULL) - { - delete SoundView_Data; - SoundView_Data = NULL; - return 0; - } - - //SoundView_Data->hDlg = hDlg; - - ShowWindow(hDlg, SW_SHOW); - UpdateWindow(hDlg); - - return 1; -} - -void SoundView_DlgClose() -{ - if(SoundView_Data != NULL) - { - DestroyWindow(SoundView_Data->hDlg); - delete SoundView_Data; - SoundView_Data = NULL; - } -} - -BOOL SoundView_IsOpened() -{ - return (SoundView_Data != NULL); -} - -HWND SoundView_GetHWnd() -{ - return SoundView_Data ? SoundView_Data->hDlg : NULL; -} - -void SoundView_Refresh() -{ - if(SoundView_Data == NULL || SPU_core == NULL) - return; - - char buf[256]; - HWND hDlg = SoundView_Data->hDlg; - static const int format_shift[] = { 2, 1, 3, 0 }; - static const double ARM7_CLOCK = 33513982; - for(int chanId = 0; chanId < 8; chanId++) { - int chan = chanId + chanOfs(); - channel_struct &thischan = SPU_core->channels[chan]; - - SendDlgItemMessage(hDlg, IDC_SOUND0PANBAR+chanId, PBM_SETPOS, (WPARAM)spumuldiv7(128, thischan.pan), (LPARAM)0); - if(thischan.status != CHANSTAT_STOPPED) - { - s32 vol = spumuldiv7(128, thischan.vol) >> thischan.datashift; - SendDlgItemMessage(hDlg, IDC_SOUND0VOLBAR+chanId, PBM_SETPOS, - (WPARAM)vol, (LPARAM)0); - - if(SoundView_Data->volModeAlternate) - sprintf(buf, "%d/%d", thischan.vol, 1 << thischan.datashift); - else - sprintf(buf, "%d", vol); - SetDlgItemText(hDlg, IDC_SOUND0VOL+chanId, buf); - - if (thischan.pan == 0) - strcpy(buf, "L"); - else if (thischan.pan == 64) - strcpy(buf, "C"); - else if (thischan.pan == 127) - strcpy(buf, "R"); - else if (thischan.pan < 64) - sprintf(buf, "L%d", 64 - thischan.pan); - else //if (thischan.pan > 64) - sprintf(buf, "R%d", thischan.pan - 64); - SetDlgItemText(hDlg, IDC_SOUND0PAN+chanId, buf); - - sprintf(buf, "%d", thischan.hold); - SetDlgItemText(hDlg, IDC_SOUND0HOLD+chanId, buf); - - sprintf(buf, "%d", thischan.status); - SetDlgItemText(hDlg, IDC_SOUND0BUSY+chanId, buf); - - const char* modes[] = { "Manual", "Loop Infinite", "One-Shot", "Prohibited" }; - sprintf(buf, "%d (%s)", thischan.repeat, modes[thischan.repeat]); - SetDlgItemText(hDlg, IDC_SOUND0REPEATMODE+chanId, buf); - - if(thischan.format != 3) { - const char* formats[] = { "PCM8", "PCM16", "IMA-ADPCM" }; - sprintf(buf, "%d (%s)", thischan.format, formats[thischan.format]); - SetDlgItemText(hDlg, IDC_SOUND0FORMAT+chanId, buf); - } - else { - if (chan < 8) - sprintf(buf, "%d (PSG/Noise?)", thischan.format); - else if (chan < 14) - sprintf(buf, "%d (%.1f% Square)", thischan.format, (float)thischan.waveduty/8); - else - sprintf(buf, "%d (Noise)", thischan.format); - } - - sprintf(buf, "$%07X", thischan.addr); - SetDlgItemText(hDlg, IDC_SOUND0SAD+chanId, buf); - - sprintf(buf, "samp #%d", thischan.loopstart << format_shift[thischan.format]); - SetDlgItemText(hDlg, IDC_SOUND0PNT+chanId, buf); - - sprintf(buf, "$%04X (%.1f Hz)", thischan.timer, (ARM7_CLOCK/2) / (double)(0x10000 - thischan.timer)); - SetDlgItemText(hDlg, IDC_SOUND0TMR+chanId, buf); - - sprintf(buf, "samp #%d / #%d", sputrunc(thischan.sampcnt), thischan.totlength << format_shift[thischan.format]); - SetDlgItemText(hDlg, IDC_SOUND0POSLEN+chanId, buf); - } - else { - SendDlgItemMessage(hDlg, IDC_SOUND0VOLBAR+chanId, PBM_SETPOS, (WPARAM)0, (LPARAM)0); - strcpy(buf, "---"); - SetDlgItemText(hDlg, IDC_SOUND0VOL+chanId, buf); - SetDlgItemText(hDlg, IDC_SOUND0PAN+chanId, buf); - SetDlgItemText(hDlg, IDC_SOUND0HOLD+chanId, buf); - SetDlgItemText(hDlg, IDC_SOUND0BUSY+chanId, buf); - SetDlgItemText(hDlg, IDC_SOUND0REPEATMODE+chanId, buf); - SetDlgItemText(hDlg, IDC_SOUND0FORMAT+chanId, buf); - SetDlgItemText(hDlg, IDC_SOUND0SAD+chanId, buf); - SetDlgItemText(hDlg, IDC_SOUND0PNT+chanId, buf); - SetDlgItemText(hDlg, IDC_SOUND0TMR+chanId, buf); - SetDlgItemText(hDlg, IDC_SOUND0POSLEN+chanId, buf); - } - } -} - -////////////////////////////////////////////////////////////////////////////// - - -static void updateMute_toSettings(HWND hDlg, int chan) -{ - for(int chanId = 0; chanId < 8; chanId++) - CommonSettings.spu_muteChannels[chanId+chanOfs()] = IsDlgButtonChecked(hDlg, IDC_SOUND0MUTE+chanId) == BST_CHECKED; -} - -static void updateMute_fromSettings(HWND hDlg) -{ - for(int chanId = 0; chanId < 8; chanId++) - SendDlgItemMessage(hDlg, IDC_SOUND0MUTE+chanId, BM_SETCHECK, - CommonSettings.spu_muteChannels[chanId+chanOfs()] ? TRUE : FALSE, - 0); -} -static void SoundView_SwitchChanOfs(SoundView_DataStruct *data) -{ - if (data == NULL) - return; - - HWND hDlg = data->hDlg; - data->viewFirst8Channels = !data->viewFirst8Channels; - SetWindowText(GetDlgItem(hDlg, IDC_SOUNDVIEW_CHANSWITCH), - data->viewFirst8Channels ? "V" : "^"); - - char buf[256]; - for(int chanId = 0; chanId < 8; chanId++) { - int chan = chanId + chanOfs(); - sprintf(buf, "#%02d", chan); - SetDlgItemText(hDlg, IDC_SOUND0ID+chanId, buf); - } - - updateMute_fromSettings(hDlg); - - SoundView_Refresh(); -} - - -static BOOL CALLBACK SoundView_DlgProc(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam) -{ - SoundView_DataStruct *data = (SoundView_DataStruct*)GetWindowLong(hDlg, DWL_USER); - if((data == NULL) && (uMsg != WM_INITDIALOG)) - return 0; - - switch(uMsg) - { - case WM_INITDIALOG: - { - for(int chanId = 0; chanId < 8; chanId++) { - SendDlgItemMessage(hDlg, IDC_SOUND0VOLBAR+chanId, PBM_SETRANGE, (WPARAM)0, MAKELPARAM(0, 128)); - SendDlgItemMessage(hDlg, IDC_SOUND0PANBAR+chanId, PBM_SETRANGE, (WPARAM)0, MAKELPARAM(0, 128)); - } - - for(int chanId = 0; chanId < 8; chanId++) { - if(CommonSettings.spu_muteChannels[chanId]) - SendDlgItemMessage(hDlg, IDC_SOUND0MUTE+chanId, BM_SETCHECK, TRUE, 0); - } - - if(data == NULL) - { - data = (SoundView_DataStruct*)lParam; - SetWindowLong(hDlg, DWL_USER, (LONG)data); - } - data->hDlg = hDlg; - - data->viewFirst8Channels = !data->viewFirst8Channels; - SoundView_SwitchChanOfs(data); - //SoundView_Refresh(); - //InvalidateRect(hDlg, NULL, FALSE); UpdateWindow(hDlg); - } - return 1; - - case WM_CLOSE: - case WM_DESTROY: - SoundView_DlgClose(); - return 1; - - case WM_COMMAND: - switch(LOWORD(wParam)) - { - case IDOK: - case IDCANCEL: - SoundView_DlgClose(); - return 1; - case IDC_BUTTON_VOLMODE: - data->volModeAlternate = IsDlgButtonChecked(hDlg, IDC_BUTTON_VOLMODE); - return 1; - - case IDC_SOUND0MUTE+0: - case IDC_SOUND0MUTE+1: - case IDC_SOUND0MUTE+2: - case IDC_SOUND0MUTE+3: - case IDC_SOUND0MUTE+4: - case IDC_SOUND0MUTE+5: - case IDC_SOUND0MUTE+6: - case IDC_SOUND0MUTE+7: - updateMute_toSettings(hDlg,LOWORD(wParam)-IDC_SOUND0MUTE); - return 1; - - - case IDC_SOUNDVIEW_CHANSWITCH: - { - SoundView_SwitchChanOfs(data); - } - return 1; - } - return 0; - } - - return 0; -} - -////////////////////////////////////////////////////////////////////////////// +/* Copyright (C) 2006 yopyop + yopyop156@ifrance.com + yopyop156.ifrance.com + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + + +#include "../SPU.h" +#include "../debug.h" +#include "../common.h" +#include "../matrix.h" +#include "resource.h" +#include +#include +#include +#include +#include "soundView.h" + +#include + +using namespace std; + +////////////////////////////////////////////////////////////////////////////// + +typedef struct SoundView_DataStruct +{ + SoundView_DataStruct() + : viewFirst8Channels(TRUE) + , volModeAlternate(FALSE) + { + } + + HWND hDlg; + + BOOL viewFirst8Channels; + BOOL volModeAlternate; +} SoundView_DataStruct; + +SoundView_DataStruct * SoundView_Data = NULL; + +////////////////////////////////////////////////////////////////////////////// + +BOOL SoundView_Init() +{ + return 1; +} + +void SoundView_DeInit() +{ +} + +////////////////////////////////////////////////////////////////////////////// + +BOOL SoundView_DlgOpen(HWND hParentWnd) +{ + HWND hDlg; + + SoundView_Data = new SoundView_DataStruct(); + if(SoundView_Data == NULL) + return 0; + + hDlg = CreateDialogParam(hAppInst, MAKEINTRESOURCE(IDD_SOUND_VIEW), hParentWnd, SoundView_DlgProc, (LPARAM)SoundView_Data); + if(hDlg == NULL) + { + delete SoundView_Data; + SoundView_Data = NULL; + return 0; + } + + //SoundView_Data->hDlg = hDlg; + + ShowWindow(hDlg, SW_SHOW); + UpdateWindow(hDlg); + + return 1; +} + +void SoundView_DlgClose() +{ + if(SoundView_Data != NULL) + { + DestroyWindow(SoundView_Data->hDlg); + delete SoundView_Data; + SoundView_Data = NULL; + } +} + +BOOL SoundView_IsOpened() +{ + return (SoundView_Data != NULL); +} + +HWND SoundView_GetHWnd() +{ + return SoundView_Data ? SoundView_Data->hDlg : NULL; +} + +void SoundView_Refresh() +{ + if(SoundView_Data == NULL || SPU_core == NULL) + return; + + char buf[256]; + HWND hDlg = SoundView_Data->hDlg; + int chanOfs = SoundView_Data->viewFirst8Channels ? 0 : 8; + static const int format_shift[] = { 2, 1, 3, 0 }; + static const double ARM7_CLOCK = 33513982; + for(int chanId = 0; chanId < 8; chanId++) { + int chan = chanId + chanOfs; + channel_struct &thischan = SPU_core->channels[chan]; + + SendDlgItemMessage(hDlg, IDC_SOUND0PANBAR+chanId, PBM_SETPOS, (WPARAM)spumuldiv7(128, thischan.pan), (LPARAM)0); + if(thischan.status != CHANSTAT_STOPPED) + { + s32 vol = spumuldiv7(128, thischan.vol) >> thischan.datashift; + SendDlgItemMessage(hDlg, IDC_SOUND0VOLBAR+chanId, PBM_SETPOS, + (WPARAM)vol, (LPARAM)0); + + if(SoundView_Data->volModeAlternate) + sprintf(buf, "%d/%d", thischan.vol, 1 << thischan.datashift); + else + sprintf(buf, "%d", vol); + SetDlgItemText(hDlg, IDC_SOUND0VOL+chanId, buf); + + if (thischan.pan == 0) + strcpy(buf, "L"); + else if (thischan.pan == 64) + strcpy(buf, "C"); + else if (thischan.pan == 127) + strcpy(buf, "R"); + else if (thischan.pan < 64) + sprintf(buf, "L%d", 64 - thischan.pan); + else //if (thischan.pan > 64) + sprintf(buf, "R%d", thischan.pan - 64); + SetDlgItemText(hDlg, IDC_SOUND0PAN+chanId, buf); + + sprintf(buf, "%d", thischan.hold); + SetDlgItemText(hDlg, IDC_SOUND0HOLD+chanId, buf); + + sprintf(buf, "%d", thischan.status); + SetDlgItemText(hDlg, IDC_SOUND0BUSY+chanId, buf); + + const char* modes[] = { "Manual", "Loop Infinite", "One-Shot", "Prohibited" }; + sprintf(buf, "%d (%s)", thischan.repeat, modes[thischan.repeat]); + SetDlgItemText(hDlg, IDC_SOUND0REPEATMODE+chanId, buf); + + if(thischan.format != 3) { + const char* formats[] = { "PCM8", "PCM16", "IMA-ADPCM" }; + sprintf(buf, "%d (%s)", thischan.format, formats[thischan.format]); + SetDlgItemText(hDlg, IDC_SOUND0FORMAT+chanId, buf); + } + else { + if (chan < 8) + sprintf(buf, "%d (PSG/Noise?)", thischan.format); + else if (chan < 14) + sprintf(buf, "%d (%.1f% Square)", thischan.format, (float)thischan.waveduty/8); + else + sprintf(buf, "%d (Noise)", thischan.format); + } + + sprintf(buf, "$%07X", thischan.addr); + SetDlgItemText(hDlg, IDC_SOUND0SAD+chanId, buf); + + sprintf(buf, "samp #%d", thischan.loopstart << format_shift[thischan.format]); + SetDlgItemText(hDlg, IDC_SOUND0PNT+chanId, buf); + + sprintf(buf, "$%04X (%.1f Hz)", thischan.timer, (ARM7_CLOCK/2) / (double)(0x10000 - thischan.timer)); + SetDlgItemText(hDlg, IDC_SOUND0TMR+chanId, buf); + + sprintf(buf, "samp #%d / #%d", sputrunc(thischan.sampcnt), thischan.totlength << format_shift[thischan.format]); + SetDlgItemText(hDlg, IDC_SOUND0POSLEN+chanId, buf); + } + else { + SendDlgItemMessage(hDlg, IDC_SOUND0VOLBAR+chanId, PBM_SETPOS, (WPARAM)0, (LPARAM)0); + strcpy(buf, "---"); + SetDlgItemText(hDlg, IDC_SOUND0VOL+chanId, buf); + SetDlgItemText(hDlg, IDC_SOUND0PAN+chanId, buf); + SetDlgItemText(hDlg, IDC_SOUND0HOLD+chanId, buf); + SetDlgItemText(hDlg, IDC_SOUND0BUSY+chanId, buf); + SetDlgItemText(hDlg, IDC_SOUND0REPEATMODE+chanId, buf); + SetDlgItemText(hDlg, IDC_SOUND0FORMAT+chanId, buf); + SetDlgItemText(hDlg, IDC_SOUND0SAD+chanId, buf); + SetDlgItemText(hDlg, IDC_SOUND0PNT+chanId, buf); + SetDlgItemText(hDlg, IDC_SOUND0TMR+chanId, buf); + SetDlgItemText(hDlg, IDC_SOUND0POSLEN+chanId, buf); + } + } +} + +////////////////////////////////////////////////////////////////////////////// + +static void SoundView_SwitchChanOfs(SoundView_DataStruct *data) +{ + if (data == NULL) + return; + + HWND hDlg = data->hDlg; + data->viewFirst8Channels = !data->viewFirst8Channels; + SetWindowText(GetDlgItem(hDlg, IDC_SOUNDVIEW_CHANSWITCH), + data->viewFirst8Channels ? "V" : "^"); + + char buf[256]; + int chanOfs = SoundView_Data->viewFirst8Channels ? 0 : 8; + for(int chanId = 0; chanId < 8; chanId++) { + int chan = chanId + chanOfs; + sprintf(buf, "#%02d", chan); + SetDlgItemText(hDlg, IDC_SOUND0ID+chanId, buf); + } + + SoundView_Refresh(); +} + +BOOL CALLBACK SoundView_DlgProc(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam) +{ + SoundView_DataStruct *data = (SoundView_DataStruct*)GetWindowLong(hDlg, DWL_USER); + if((data == NULL) && (uMsg != WM_INITDIALOG)) + return 0; + + switch(uMsg) + { + case WM_INITDIALOG: + { + for(int chanId = 0; chanId < 8; chanId++) { + SendDlgItemMessage(hDlg, IDC_SOUND0VOLBAR+chanId, PBM_SETRANGE, (WPARAM)0, MAKELPARAM(0, 128)); + SendDlgItemMessage(hDlg, IDC_SOUND0PANBAR+chanId, PBM_SETRANGE, (WPARAM)0, MAKELPARAM(0, 128)); + } + + if(data == NULL) + { + data = (SoundView_DataStruct*)lParam; + SetWindowLong(hDlg, DWL_USER, (LONG)data); + } + data->hDlg = hDlg; + + data->viewFirst8Channels = !data->viewFirst8Channels; + SoundView_SwitchChanOfs(data); + //SoundView_Refresh(); + //InvalidateRect(hDlg, NULL, FALSE); UpdateWindow(hDlg); + } + return 1; + + case WM_CLOSE: + case WM_DESTROY: + SoundView_DlgClose(); + return 1; + + case WM_COMMAND: + switch(LOWORD(wParam)) + { + case IDOK: + case IDCANCEL: + SoundView_DlgClose(); + return 1; + case IDC_BUTTON_VOLMODE: + data->volModeAlternate = IsDlgButtonChecked(hDlg, IDC_BUTTON_VOLMODE); + return 1; + + case IDC_SOUNDVIEW_CHANSWITCH: + { + SoundView_SwitchChanOfs(data); + } + return 1; + } + return 0; + } + + return 0; +} + +////////////////////////////////////////////////////////////////////////////// diff --git a/desmume/src/windows/soundView.h b/src/windows/soundView.h similarity index 100% rename from desmume/src/windows/soundView.h rename to src/windows/soundView.h diff --git a/desmume/src/windows/throttle.cpp b/src/windows/throttle.cpp similarity index 94% rename from desmume/src/windows/throttle.cpp rename to src/windows/throttle.cpp index dc1f85302..81ac96c6a 100644 --- a/desmume/src/windows/throttle.cpp +++ b/src/windows/throttle.cpp @@ -1,109 +1,109 @@ -//THIS SPEED THROTTLE IS TAKEN FROM FCEUX. -//Copyright (C) 2002 Xodnizel - -#include "../common.h" -#include "../types.h" -#include "../debug.h" -#include "../console.h" -#include - -int FastForward=0; -static u64 tmethod,tfreq; -static const u64 core_desiredfps = 3920763; //59.8261 -static u64 desiredfps = core_desiredfps; -static u64 desiredFpsScaler = 256; - -void IncreaseSpeed(void) { - - desiredFpsScaler*=2; - desiredfps = core_desiredfps * desiredFpsScaler / 256; - printf("Throttle fps scaling increased to: %f\n",desiredFpsScaler/256.0); -} - -void DecreaseSpeed(void) { - - desiredFpsScaler/=2; - desiredfps = core_desiredfps * desiredFpsScaler / 256; - printf("Throttle fps scaling decreased to: %f\n",desiredFpsScaler/256.0); -} - -static u64 GetCurTime(void) -{ - if(tmethod) - { - u64 tmp; - - /* Practically, LARGE_INTEGER and u64 differ only by signness and name. */ - QueryPerformanceCounter((LARGE_INTEGER*)&tmp); - - return(tmp); - } - else - return((u64)GetTickCount()); - -} - -void InitSpeedThrottle(void) -{ - tmethod=0; - if(QueryPerformanceFrequency((LARGE_INTEGER*)&tfreq)) - { - tmethod=1; - } - else - tfreq=1000; - tfreq<<=16; /* Adjustment for fps returned from FCEUI_GetDesiredFPS(). */ -} - -static bool behind=false; -bool ThrottleIsBehind() { - return behind; -} - -int SpeedThrottle(void) -{ - static u64 ttime,ltime; - - if(FastForward) - return (0); - - behind = false; - -waiter: - - ttime=GetCurTime(); - - - if( (ttime-ltime) < (tfreq/desiredfps) ) - { - u64 sleepy; - sleepy=(tfreq/desiredfps)-(ttime-ltime); - sleepy*=1000; - if(tfreq>=65536) - sleepy/=tfreq>>16; - else - sleepy=0; - if(sleepy>100) - { - // block for a max of 100ms to - // keep the gui responsive - Sleep(100); - return 1; - } - Sleep(sleepy); - goto waiter; - } - if( (ttime-ltime) >= (tfreq*4/desiredfps)) - ltime=ttime; - else - { - ltime+=tfreq/desiredfps; - - if( (ttime-ltime) >= (tfreq/desiredfps) ) // Oops, we're behind! - { - behind = true; - return 0; - } - } - return(0); -} +//THIS SPEED THROTTLE IS TAKEN FROM FCEUX. +//Copyright (C) 2002 Xodnizel + +#include "../common.h" +#include "../types.h" +#include "../debug.h" +#include "../console.h" +#include + +int FastForward=0; +static u64 tmethod,tfreq; +static const u64 core_desiredfps = 3920763; //59.8261 +static u64 desiredfps = core_desiredfps; +static u64 desiredFpsScaler = 256; + +void IncreaseSpeed(void) { + + desiredFpsScaler*=2; + desiredfps = core_desiredfps * desiredFpsScaler / 256; + printf("Throttle fps scaling increased to: %f\n",desiredFpsScaler/256.0); +} + +void DecreaseSpeed(void) { + + desiredFpsScaler/=2; + desiredfps = core_desiredfps * desiredFpsScaler / 256; + printf("Throttle fps scaling decreased to: %f\n",desiredFpsScaler/256.0); +} + +static u64 GetCurTime(void) +{ + if(tmethod) + { + u64 tmp; + + /* Practically, LARGE_INTEGER and u64 differ only by signness and name. */ + QueryPerformanceCounter((LARGE_INTEGER*)&tmp); + + return(tmp); + } + else + return((u64)GetTickCount()); + +} + +void InitSpeedThrottle(void) +{ + tmethod=0; + if(QueryPerformanceFrequency((LARGE_INTEGER*)&tfreq)) + { + tmethod=1; + } + else + tfreq=1000; + tfreq<<=16; /* Adjustment for fps returned from FCEUI_GetDesiredFPS(). */ +} + +static bool behind=false; +bool ThrottleIsBehind() { + return behind; +} + +int SpeedThrottle(void) +{ + static u64 ttime,ltime; + + if(FastForward) + return (0); + + behind = false; + +waiter: + + ttime=GetCurTime(); + + + if( (ttime-ltime) < (tfreq/desiredfps) ) + { + u64 sleepy; + sleepy=(tfreq/desiredfps)-(ttime-ltime); + sleepy*=1000; + if(tfreq>=65536) + sleepy/=tfreq>>16; + else + sleepy=0; + if(sleepy>100) + { + // block for a max of 100ms to + // keep the gui responsive + Sleep(100); + return 1; + } + Sleep(sleepy); + goto waiter; + } + if( (ttime-ltime) >= (tfreq*4/desiredfps)) + ltime=ttime; + else + { + ltime+=tfreq/desiredfps; + + if( (ttime-ltime) >= (tfreq/desiredfps) ) // Oops, we're behind! + { + behind = true; + return 0; + } + } + return(0); +} diff --git a/desmume/src/windows/throttle.h b/src/windows/throttle.h similarity index 94% rename from desmume/src/windows/throttle.h rename to src/windows/throttle.h index b2d3103e3..c30e8f07f 100644 --- a/desmume/src/windows/throttle.h +++ b/src/windows/throttle.h @@ -1,11 +1,11 @@ -#ifndef _THROTTLE_H_ -#define _THROTTLE_H_ - -void InitSpeedThrottle(); -int SpeedThrottle(); -bool ThrottleIsBehind(); -extern int FastForward; -void IncreaseSpeed(); -void DecreaseSpeed(); - -#endif +#ifndef _THROTTLE_H_ +#define _THROTTLE_H_ + +void InitSpeedThrottle(); +int SpeedThrottle(); +bool ThrottleIsBehind(); +extern int FastForward; +void IncreaseSpeed(); +void DecreaseSpeed(); + +#endif diff --git a/desmume/src/windows/tileView.cpp b/src/windows/tileView.cpp similarity index 97% rename from desmume/src/windows/tileView.cpp rename to src/windows/tileView.cpp index a798bd134..93152dad7 100644 --- a/desmume/src/windows/tileView.cpp +++ b/src/windows/tileView.cpp @@ -1,658 +1,658 @@ -/* Copyright (C) 2006 yopyop - yopyop156@ifrance.com - yopyop156.ifrance.com - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#include "tileView.h" -#include "commctrl.h" -#include "resource.h" -#include "debug.h" -#include "../MMU.h" -#include "../gpu.h" - -typedef struct -{ - u32 autoup_secs; - bool autoup; - - HWND hwnd; - u32 target; - u16 * pal; - s16 palnum; - u16 tilenum; - u8 coul; - u32 x; - u32 y; -} tileview_struct; - -tileview_struct *TileView = NULL; - -LRESULT TileViewBox_Direct(HWND hwnd, tileview_struct * win, WPARAM wParam, LPARAM lParam) -{ - HDC hdc; - PAINTSTRUCT ps; -// SIZE fontsize; -// TCHAR text[80]; - BITMAPV4HEADER bmi; - RECT rect; - HDC mem_dc; - HBITMAP mem_bmp; - int lg; - int ht; - - memset(&bmi, 0, sizeof(bmi)); - bmi.bV4Size = sizeof(bmi); - bmi.bV4Planes = 1; - bmi.bV4BitCount = 16; - bmi.bV4V4Compression = BI_RGB|BI_BITFIELDS; - bmi.bV4RedMask = 0x001F; - bmi.bV4GreenMask = 0x03E0; - bmi.bV4BlueMask = 0x7C00; - bmi.bV4Width = 256; - bmi.bV4Height = -256; - - GetClientRect(hwnd, &rect); - lg = rect.right - rect.left; - ht = rect.bottom - rect.top; - - hdc = BeginPaint(hwnd, &ps); - - mem_dc = CreateCompatibleDC(hdc); - mem_bmp = CreateCompatibleBitmap(hdc, lg, ht); - SelectObject(mem_dc, mem_bmp); - - FillRect(mem_dc, &rect, (HBRUSH)GetStockObject(WHITE_BRUSH)); - - u8* mem; - if(win->target >= ARM9MEM_LCDC) - mem = ARM9Mem.ARM9_LCD + win->target - ARM9MEM_LCDC; - else - mem = (u8*)MMU_gpu_map(win->target); - if(mem) - SetDIBitsToDevice(mem_dc, 0, 0, 256, 256, 0, 0, 0, 256, mem, (BITMAPINFO*)&bmi, DIB_RGB_COLORS); - - BitBlt(hdc, 0, 0, lg, ht, mem_dc, 0, 0, SRCCOPY); - - DeleteDC(mem_dc); - DeleteObject(mem_bmp); - - EndPaint(hwnd, &ps); - return 0; -} - -////////////////////////////////////////////////////////////////////////////// - -LRESULT TileViewBox_Pal256(HWND hwnd, tileview_struct * win, WPARAM wParam, LPARAM lParam) -{ - HDC hdc; - PAINTSTRUCT ps; -// SIZE fontsize; - TCHAR text[80]; - u16 bitmap[256*256]; - u16 * pal = ((u16 *)win->pal) + win->palnum*256; - BITMAPV4HEADER bmi; - RECT rect; - int lg; - int ht; - HDC mem_dc; - HBITMAP mem_bmp; - - memset(&bmi, 0, sizeof(bmi)); - bmi.bV4Size = sizeof(bmi); - bmi.bV4Planes = 1; - bmi.bV4BitCount = 16; - bmi.bV4V4Compression = BI_RGB|BI_BITFIELDS; - bmi.bV4RedMask = 0x001F; - bmi.bV4GreenMask = 0x03E0; - bmi.bV4BlueMask = 0x7C00; - bmi.bV4Width = 256; - bmi.bV4Height = -256; - - GetClientRect(hwnd, &rect); - lg = rect.right - rect.left; - ht = rect.bottom - rect.top; - - hdc = BeginPaint(hwnd, &ps); - - mem_dc = CreateCompatibleDC(hdc); - mem_bmp = CreateCompatibleBitmap(hdc, lg, ht); - SelectObject(mem_dc, mem_bmp); - - FillRect(mem_dc, &rect, (HBRUSH)GetStockObject(WHITE_BRUSH)); - - if(win->pal) - { - u32 i, num2, num, y, x; - - u8* mem; - if(win->target >= ARM9MEM_LCDC) - mem = ARM9Mem.ARM9_LCD + win->target - ARM9MEM_LCDC; - else - mem = (u8*)MMU_gpu_map(win->target); - if(mem) - { - for(num2 = 0; num2<32; ++num2) - for(num = 0; num<32; ++num) - for(y = 0; y<8; ++y) - for(x = 0; x<8; ++x) - bitmap[x + (y*256) + (num*8) +(num2*256*8)] = pal[mem[x + (y*8) + (num*64) +(num2*2048)]]; - SetDIBitsToDevice(mem_dc, 0, 0, 256, 256, 0, 0, 0, 256, bitmap, (BITMAPINFO*)&bmi, DIB_RGB_COLORS); - } - sprintf(text, "Pal : %d", win->palnum); - SetWindowText(GetDlgItem(hwnd, IDC_PALNUM), text); - } - else - TextOut(mem_dc, 3, 3, "Il n'y a pas de palette", 23); - - BitBlt(hdc, 0, 0, lg, ht, mem_dc, 0, 0, SRCCOPY); - - DeleteDC(mem_dc); - DeleteObject(mem_bmp); - - EndPaint(hwnd, &ps); - return 0; -} - -////////////////////////////////////////////////////////////////////////////// - -LRESULT TileViewBox_Pal16(HWND hwnd, tileview_struct * win, WPARAM wParam, LPARAM lParam) -{ - HDC hdc; - PAINTSTRUCT ps; -// SIZE fontsize; - TCHAR text[80]; - u16 bitmap[512*512]; - u16 * pal = ((u16 *)win->pal) + win->palnum*16; - BITMAPV4HEADER bmi; - RECT rect; - int lg; - int ht; - HDC mem_dc; - HBITMAP mem_bmp; - - memset(&bmi, 0, sizeof(bmi)); - bmi.bV4Size = sizeof(bmi); - bmi.bV4Planes = 1; - bmi.bV4BitCount = 16; - bmi.bV4V4Compression = BI_RGB|BI_BITFIELDS; - bmi.bV4RedMask = 0x001F; - bmi.bV4GreenMask = 0x03E0; - bmi.bV4BlueMask = 0x7C00; - bmi.bV4Width = 512; - bmi.bV4Height = -256; - - GetClientRect(hwnd, &rect); - lg = rect.right - rect.left; - ht = rect.bottom - rect.top; - - hdc = BeginPaint(hwnd, &ps); - - mem_dc = CreateCompatibleDC(hdc); - mem_bmp = CreateCompatibleBitmap(hdc, 512, 256); - SelectObject(mem_dc, mem_bmp); - - FillRect(mem_dc, &rect, (HBRUSH)GetStockObject(WHITE_BRUSH)); - - if(win->pal) - { - u8* mem; - if(win->target >= ARM9MEM_LCDC) - mem = ARM9Mem.ARM9_LCD + win->target - ARM9MEM_LCDC; - else - mem = (u8*)MMU_gpu_map(win->target); - - if(mem) - { - u32 num2, num, y, x; - for(num2 = 0; num2<32; ++num2) - for(num = 0; num<64; ++num) - for(y = 0; y<8; ++y) - for(x = 0; x<4; ++x) - { - bitmap[(x<<1) + (y*512) + (num*8) +(num2*512*8)] = pal[mem[x + (y*4) + (num*32) +(num2*2048)]&0xF]; - bitmap[(x<<1)+1 + (y*512) + (num*8) +(num2*512*8)] = pal[mem[x + (y*4) + (num*32) +(num2*2048)]>>4]; - } - SetDIBitsToDevice(mem_dc, 0, 0, 512, 256, 0, 0, 0, 256, bitmap, (BITMAPINFO*)&bmi, DIB_RGB_COLORS); - } - sprintf(text, "Pal : %d", win->palnum); - SetWindowText(GetDlgItem(hwnd, IDC_PALNUM), text); - } - else - TextOut(mem_dc, 3, 3, "Il n'y a pas de palette", 23); - - BitBlt(hdc, 0, 0, lg, ht, mem_dc, 0, 0, SRCCOPY); - - DeleteDC(mem_dc); - DeleteObject(mem_bmp); - - EndPaint(hwnd, &ps); - return 0; -} - -////////////////////////////////////////////////////////////////////////////// - -LRESULT CALLBACK TileViewBoxProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam) -{ - switch(msg) - { - case WM_INITDIALOG: - return 1; - case WM_NCCREATE: - return 1; - case WM_NCDESTROY: - return 1; - case WM_PAINT: - switch(TileView->coul) - { - case 0 : - TileViewBox_Direct(hwnd, TileView, wParam, lParam); - break; - case 1 : - TileViewBox_Pal256(hwnd, TileView, wParam, lParam); - break; - case 2 : - TileViewBox_Pal16(hwnd, TileView, wParam, lParam); - break; - } - break; - case WM_LBUTTONDOWN : - switch(TileView->coul) - { - case 0 : - case 1 : - if(LOWORD(lParam)<(32*8)) - { - TileView->x = ((LOWORD(lParam)>>3)<<3); - TileView->y = (HIWORD(lParam)>>3)<<3; - TileView->tilenum = (LOWORD(lParam)>>3) + (HIWORD(lParam)>>3)*32; - } - break; - case 2 : - TileView->x = ((LOWORD(lParam)>>3)<<3); - TileView->y = (HIWORD(lParam)>>3)<<3; - TileView->tilenum = (LOWORD(lParam)>>3) + (HIWORD(lParam)>>3)*64; - break; - } - InvalidateRect(GetDlgItem(hwnd, IDC_MINI_TILE), NULL, FALSE); - return 1; - case WM_ERASEBKGND: - return 1; - } - return DefWindowProc(hwnd, msg, wParam, lParam); -} - -LRESULT MiniTileViewBox_Paint(HWND hwnd, tileview_struct * win, WPARAM wParam, LPARAM lParam) -{ - HWND hwnd_src = GetDlgItem(GetParent(hwnd), IDC_Tile_BOX); - HDC hdc_src; - HDC hdc_dst; - char txt[80]; - - PAINTSTRUCT ps; - - hdc_dst = BeginPaint(hwnd, &ps); - hdc_src = GetDC(hwnd_src); - StretchBlt(hdc_dst, 0, 0, 80, 80, hdc_src, win->x, win->y, 8, 8, SRCCOPY); - sprintf(txt, "Tile num : 0x%X", win->tilenum); - SetWindowText(GetDlgItem(win->hwnd, IDC_TILENUM), txt); - EndPaint(hwnd, &ps); - return 0; -} - -LRESULT CALLBACK MiniTileViewBoxProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam) -{ - switch(msg) - { - case WM_NCCREATE: - return 1; - case WM_NCDESTROY: - return 1; - case WM_PAINT : - MiniTileViewBox_Paint(hwnd, TileView, wParam, lParam); - break; - case WM_ERASEBKGND: - return 1; - default: - break; - } - return DefWindowProc(hwnd, msg, wParam, lParam); -} - -BOOL CALLBACK ViewTilesProc (HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam) -{ - //bail out early if the dialog isnt initialized - if(!TileView && message != WM_INITDIALOG) - return false; - - switch (message) - { - case WM_INITDIALOG : - { - TileView = new tileview_struct; - memset(TileView, 0, sizeof(tileview_struct)); - TileView->hwnd = hwnd; - TileView->target = ARM9MEM_ABG; - TileView->pal = ((u16 *)ARM9Mem.ARM9_VMEM); - TileView->autoup_secs = 1; - SendMessage(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SPIN), - UDM_SETRANGE, 0, MAKELONG(99, 1)); - SendMessage(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SPIN), - UDM_SETPOS32, 0, TileView->autoup_secs); - - HWND combo = GetDlgItem(hwnd, IDC_PAL_SELECT); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Main screen BG PAL"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Sub screen BG PAL"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Main screen SPR PAL"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Sub screen SPR PAL"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Main screen ExtPAL 0"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Main screen ExtPAL 1"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Main screen ExtPAL 2"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Main screen ExtPAL 3"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Sub screen ExtPAL 0"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Sub screen ExtPAL 1"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Sub screen ExtPAL 2"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Sub screen ExtPAL 3"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Main spr ExtPAL 0"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Main spr ExtPAL 1"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Sub spr ExtPAL 0"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Sub spr ExtPAL 1"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Texture PAL 0"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Texture PAL 1"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Texture PAL 2"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Texture PAL 3"); - SendMessage(combo, CB_SETCURSEL, 0, 0); - - combo = GetDlgItem(hwnd, IDC_MEM_SELECT); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"A-BG - 0x6000000"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"A-BG - 0x6010000"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"A-BG - 0x6020000"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"A-BG - 0x6030000"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"A-BG - 0x6040000"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"A-BG - 0x6050000"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"A-BG - 0x6060000"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"A-BG - 0x6070000"); - - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"B-BG - 0x6200000"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"B-BG - 0x6210000"); - - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"A-OBJ- 0x6400000"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"A-OBJ- 0x6410000"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"A-OBJ- 0x6420000"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"A-OBJ- 0x6430000"); - - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"B-OBJ- 0x6600000"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"B-OBJ- 0x6610000"); - - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"LCD - 0x6800000"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"LCD - 0x6810000"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"LCD - 0x6820000"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"LCD - 0x6830000"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"LCD - 0x6840000"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"LCD - 0x6850000"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"LCD - 0x6860000"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"LCD - 0x6870000"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"LCD - 0x6880000"); - SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"LCD - 0x6890000"); - SendMessage(combo, CB_SETCURSEL, 0, 0); - SendMessage(GetDlgItem(hwnd, IDC_BITMAP), BM_SETCHECK, TRUE, 0); - } - return 1; - case WM_CLOSE : - if(TileView->autoup) - { - KillTimer(hwnd, IDT_VIEW_TILE); - TileView->autoup = false; - } - if (TileView!=NULL) - { - delete TileView; - TileView = NULL; - } - //INFO("Close Tile view dialog\n"); - PostQuitMessage(0); - return 1; - case WM_TIMER: - SendMessage(hwnd, WM_COMMAND, IDC_REFRESH, 0); - return 1; - case WM_HSCROLL : - switch LOWORD(wParam) - { - case SB_LINERIGHT : - ++(TileView->palnum); - if(TileView->palnum>15) - TileView->palnum = 15; - break; - case SB_LINELEFT : - --(TileView->palnum); - if(TileView->palnum<0) - TileView->palnum = 0; - break; - } - InvalidateRect(hwnd, NULL, FALSE); - return 1; - case WM_COMMAND : - switch (LOWORD (wParam)) - { - case IDC_FERMER : - SendMessage(hwnd, WM_CLOSE, 0, 0); - return 1; - case IDC_AUTO_UPDATE : - if(TileView->autoup) - { - EnableWindow(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SECS), false); - EnableWindow(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SPIN), false); - KillTimer(hwnd, IDT_VIEW_TILE); - TileView->autoup = FALSE; - return 1; - } - EnableWindow(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SECS), true); - EnableWindow(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SPIN), true); - TileView->autoup = TRUE; - SetTimer(hwnd, IDT_VIEW_TILE, TileView->autoup_secs*20, (TIMERPROC) NULL); - return 1; - case IDC_AUTO_UPDATE_SECS: - { - int t = GetDlgItemInt(hwnd, IDC_AUTO_UPDATE_SECS, FALSE, TRUE); - if (!TileView) - { - SendMessage(hwnd, WM_INITDIALOG, 0, 0); - } - if (t != TileView->autoup_secs) - { - TileView->autoup_secs = t; - if (TileView->autoup) - SetTimer(hwnd, IDT_VIEW_TILE, - TileView->autoup_secs*20, (TIMERPROC) NULL); - } - } - return 1; - case IDC_REFRESH: - InvalidateRect(hwnd, NULL, FALSE); - return 1; - case IDC_BITMAP : - TileView->coul = 0; - InvalidateRect(hwnd, NULL, FALSE); - return 1; - case IDC_256COUL : - TileView->coul = 1; - InvalidateRect(hwnd, NULL, FALSE); - return 1; - case IDC_16COUL : - TileView->coul = 2; - InvalidateRect(hwnd, NULL, FALSE); - return 1; - case IDC_MEM_SELECT : - switch(HIWORD(wParam)) - { - case CBN_SELCHANGE : - case CBN_CLOSEUP : - { - u32 sel = SendMessage(GetDlgItem(hwnd, IDC_MEM_SELECT), CB_GETCURSEL, 0, 0); - switch(sel) - { - case 0 : - case 1 : - case 2 : - case 3 : - case 4 : - case 5 : - case 6 : - case 7 : - TileView->target = ARM9MEM_ABG + 0x10000*sel; - break; - case 8 : - case 9 : - TileView->target = ARM9MEM_BBG + 0x10000*(sel-8); - break; - case 10 : - case 11 : - case 12 : - case 13 : - TileView->target = ARM9MEM_AOBJ + 0x10000*(sel-10); - break; - case 14 : - case 15 : - TileView->target = ARM9MEM_BOBJ + 0x10000*(sel-14); - break; - case 16 : - case 17 : - case 18 : - case 19 : - case 20 : - case 21 : - case 22 : - case 23 : - case 24 : - case 25 : - TileView->target = ARM9MEM_LCDC + 0x10000*(sel-16); - break; - default : - return 1; - } - InvalidateRect(hwnd, NULL, FALSE); - return 1; - } - } - return 1; - case IDC_PAL_SELECT : - switch(HIWORD(wParam)) - { - case CBN_SELCHANGE : - case CBN_CLOSEUP : - { - u32 sel = SendMessage(GetDlgItem(hwnd, IDC_PAL_SELECT), CB_GETCURSEL, 0, 0); - switch(sel) - { - case 0 : - TileView->pal = (u16 *)ARM9Mem.ARM9_VMEM; - TileView->palnum = 0; - ShowWindow(GetDlgItem(hwnd, IDC_16COUL), SW_SHOW); - EnableWindow(GetDlgItem(hwnd, IDC_16COUL), TRUE); - break; - case 1 : - TileView->pal = ((u16 *)ARM9Mem.ARM9_VMEM) + 0x200; - TileView->palnum = 0; - ShowWindow(GetDlgItem(hwnd, IDC_16COUL), SW_SHOW); - EnableWindow(GetDlgItem(hwnd, IDC_16COUL), TRUE); - break; - case 2 : - TileView->pal = (u16 *)ARM9Mem.ARM9_VMEM + 0x100; - TileView->palnum = 0; - ShowWindow(GetDlgItem(hwnd, IDC_16COUL), SW_SHOW); - EnableWindow(GetDlgItem(hwnd, IDC_16COUL), TRUE); - break; - case 3 : - TileView->pal = ((u16 *)ARM9Mem.ARM9_VMEM) + 0x300; - TileView->palnum = 0; - ShowWindow(GetDlgItem(hwnd, IDC_16COUL), SW_SHOW); - EnableWindow(GetDlgItem(hwnd, IDC_16COUL), TRUE); - break; - case 4 : - case 5 : - case 6 : - case 7 : - TileView->pal = ((u16 *)(ARM9Mem.ExtPal[0][sel-4])); - TileView->palnum = 0; - ShowWindow(GetDlgItem(hwnd, IDC_16COUL), SW_HIDE); - EnableWindow(GetDlgItem(hwnd, IDC_16COUL), FALSE); - if(TileView->coul == 2) - { - SendMessage(GetDlgItem(hwnd, IDC_256COUL), BM_SETCHECK, TRUE, 0); - SendMessage(GetDlgItem(hwnd, IDC_16COUL), BM_SETCHECK, FALSE, 0); - TileView->coul = 1; - } - break; - case 8 : - case 9 : - case 10 : - case 11 : - TileView->pal = ((u16 *)(ARM9Mem.ExtPal[1][sel-8])); - TileView->palnum = 0; - ShowWindow(GetDlgItem(hwnd, IDC_16COUL), SW_HIDE); - EnableWindow(GetDlgItem(hwnd, IDC_16COUL), FALSE); - if(TileView->coul == 2) - { - SendMessage(GetDlgItem(hwnd, IDC_256COUL), BM_SETCHECK, TRUE, 0); - SendMessage(GetDlgItem(hwnd, IDC_16COUL), BM_SETCHECK, FALSE, 0); - TileView->coul = 1; - } - break; - case 12 : - case 13 : - TileView->pal = ((u16 *)(ARM9Mem.ObjExtPal[0][sel-12])); - TileView->palnum = 0; - if(TileView->coul == 2) - { - SendMessage(GetDlgItem(hwnd, IDC_256COUL), BM_SETCHECK, TRUE, 0); - SendMessage(GetDlgItem(hwnd, IDC_16COUL), BM_SETCHECK, FALSE, 0); - TileView->coul = 1; - } - break; - case 14 : - case 15 : - TileView->pal = ((u16 *)(ARM9Mem.ObjExtPal[1][sel-14])); - TileView->palnum = 0; - if(TileView->coul == 2) - { - SendMessage(GetDlgItem(hwnd, IDC_256COUL), BM_SETCHECK, TRUE, 0); - SendMessage(GetDlgItem(hwnd, IDC_16COUL), BM_SETCHECK, FALSE, 0); - TileView->coul = 1; - } - break; - case 16 : - case 17 : - case 18 : - case 19 : - TileView->pal = ((u16 *)(ARM9Mem.texInfo.texPalSlot[sel-16])); - TileView->palnum = 0; - ShowWindow(GetDlgItem(hwnd, IDC_16COUL), SW_SHOW); - EnableWindow(GetDlgItem(hwnd, IDC_16COUL), TRUE); - break; - default : - return 1; - } - InvalidateRect(hwnd, NULL, FALSE); - return 1; - } - } - } - return 0; - } - return FALSE; -} +/* Copyright (C) 2006 yopyop + yopyop156@ifrance.com + yopyop156.ifrance.com + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#include "tileView.h" +#include "commctrl.h" +#include "resource.h" +#include "debug.h" +#include "../MMU.h" +#include "../gpu.h" + +typedef struct +{ + u32 autoup_secs; + bool autoup; + + HWND hwnd; + u32 target; + u16 * pal; + s16 palnum; + u16 tilenum; + u8 coul; + u32 x; + u32 y; +} tileview_struct; + +tileview_struct *TileView = NULL; + +LRESULT TileViewBox_Direct(HWND hwnd, tileview_struct * win, WPARAM wParam, LPARAM lParam) +{ + HDC hdc; + PAINTSTRUCT ps; +// SIZE fontsize; +// TCHAR text[80]; + BITMAPV4HEADER bmi; + RECT rect; + HDC mem_dc; + HBITMAP mem_bmp; + int lg; + int ht; + + memset(&bmi, 0, sizeof(bmi)); + bmi.bV4Size = sizeof(bmi); + bmi.bV4Planes = 1; + bmi.bV4BitCount = 16; + bmi.bV4V4Compression = BI_RGB|BI_BITFIELDS; + bmi.bV4RedMask = 0x001F; + bmi.bV4GreenMask = 0x03E0; + bmi.bV4BlueMask = 0x7C00; + bmi.bV4Width = 256; + bmi.bV4Height = -256; + + GetClientRect(hwnd, &rect); + lg = rect.right - rect.left; + ht = rect.bottom - rect.top; + + hdc = BeginPaint(hwnd, &ps); + + mem_dc = CreateCompatibleDC(hdc); + mem_bmp = CreateCompatibleBitmap(hdc, lg, ht); + SelectObject(mem_dc, mem_bmp); + + FillRect(mem_dc, &rect, (HBRUSH)GetStockObject(WHITE_BRUSH)); + + u8* mem; + if(win->target >= ARM9MEM_LCDC) + mem = ARM9Mem.ARM9_LCD + win->target - ARM9MEM_LCDC; + else + mem = MMU_RenderMapToLCD(win->target); + if(mem) + SetDIBitsToDevice(mem_dc, 0, 0, 256, 256, 0, 0, 0, 256, mem, (BITMAPINFO*)&bmi, DIB_RGB_COLORS); + + BitBlt(hdc, 0, 0, lg, ht, mem_dc, 0, 0, SRCCOPY); + + DeleteDC(mem_dc); + DeleteObject(mem_bmp); + + EndPaint(hwnd, &ps); + return 0; +} + +////////////////////////////////////////////////////////////////////////////// + +LRESULT TileViewBox_Pal256(HWND hwnd, tileview_struct * win, WPARAM wParam, LPARAM lParam) +{ + HDC hdc; + PAINTSTRUCT ps; +// SIZE fontsize; + TCHAR text[80]; + u16 bitmap[256*256]; + u16 * pal = ((u16 *)win->pal) + win->palnum*256; + BITMAPV4HEADER bmi; + RECT rect; + int lg; + int ht; + HDC mem_dc; + HBITMAP mem_bmp; + + memset(&bmi, 0, sizeof(bmi)); + bmi.bV4Size = sizeof(bmi); + bmi.bV4Planes = 1; + bmi.bV4BitCount = 16; + bmi.bV4V4Compression = BI_RGB|BI_BITFIELDS; + bmi.bV4RedMask = 0x001F; + bmi.bV4GreenMask = 0x03E0; + bmi.bV4BlueMask = 0x7C00; + bmi.bV4Width = 256; + bmi.bV4Height = -256; + + GetClientRect(hwnd, &rect); + lg = rect.right - rect.left; + ht = rect.bottom - rect.top; + + hdc = BeginPaint(hwnd, &ps); + + mem_dc = CreateCompatibleDC(hdc); + mem_bmp = CreateCompatibleBitmap(hdc, lg, ht); + SelectObject(mem_dc, mem_bmp); + + FillRect(mem_dc, &rect, (HBRUSH)GetStockObject(WHITE_BRUSH)); + + if(win->pal) + { + u32 i, num2, num, y, x; + + u8* mem; + if(win->target >= ARM9MEM_LCDC) + mem = ARM9Mem.ARM9_LCD + win->target - ARM9MEM_LCDC; + else + mem = MMU_RenderMapToLCD(win->target); + if(mem) + { + for(num2 = 0; num2<32; ++num2) + for(num = 0; num<32; ++num) + for(y = 0; y<8; ++y) + for(x = 0; x<8; ++x) + bitmap[x + (y*256) + (num*8) +(num2*256*8)] = pal[mem[x + (y*8) + (num*64) +(num2*2048)]]; + SetDIBitsToDevice(mem_dc, 0, 0, 256, 256, 0, 0, 0, 256, bitmap, (BITMAPINFO*)&bmi, DIB_RGB_COLORS); + } + sprintf(text, "Pal : %d", win->palnum); + SetWindowText(GetDlgItem(hwnd, IDC_PALNUM), text); + } + else + TextOut(mem_dc, 3, 3, "Il n'y a pas de palette", 23); + + BitBlt(hdc, 0, 0, lg, ht, mem_dc, 0, 0, SRCCOPY); + + DeleteDC(mem_dc); + DeleteObject(mem_bmp); + + EndPaint(hwnd, &ps); + return 0; +} + +////////////////////////////////////////////////////////////////////////////// + +LRESULT TileViewBox_Pal16(HWND hwnd, tileview_struct * win, WPARAM wParam, LPARAM lParam) +{ + HDC hdc; + PAINTSTRUCT ps; +// SIZE fontsize; + TCHAR text[80]; + u16 bitmap[512*512]; + u16 * pal = ((u16 *)win->pal) + win->palnum*16; + BITMAPV4HEADER bmi; + RECT rect; + int lg; + int ht; + HDC mem_dc; + HBITMAP mem_bmp; + + memset(&bmi, 0, sizeof(bmi)); + bmi.bV4Size = sizeof(bmi); + bmi.bV4Planes = 1; + bmi.bV4BitCount = 16; + bmi.bV4V4Compression = BI_RGB|BI_BITFIELDS; + bmi.bV4RedMask = 0x001F; + bmi.bV4GreenMask = 0x03E0; + bmi.bV4BlueMask = 0x7C00; + bmi.bV4Width = 512; + bmi.bV4Height = -256; + + GetClientRect(hwnd, &rect); + lg = rect.right - rect.left; + ht = rect.bottom - rect.top; + + hdc = BeginPaint(hwnd, &ps); + + mem_dc = CreateCompatibleDC(hdc); + mem_bmp = CreateCompatibleBitmap(hdc, 512, 256); + SelectObject(mem_dc, mem_bmp); + + FillRect(mem_dc, &rect, (HBRUSH)GetStockObject(WHITE_BRUSH)); + + if(win->pal) + { + u8* mem; + if(win->target >= ARM9MEM_LCDC) + mem = ARM9Mem.ARM9_LCD + win->target - ARM9MEM_LCDC; + else + mem = MMU_RenderMapToLCD(win->target); + + if(mem) + { + u32 num2, num, y, x; + for(num2 = 0; num2<32; ++num2) + for(num = 0; num<64; ++num) + for(y = 0; y<8; ++y) + for(x = 0; x<4; ++x) + { + bitmap[(x<<1) + (y*512) + (num*8) +(num2*512*8)] = pal[mem[x + (y*4) + (num*32) +(num2*2048)]&0xF]; + bitmap[(x<<1)+1 + (y*512) + (num*8) +(num2*512*8)] = pal[mem[x + (y*4) + (num*32) +(num2*2048)]>>4]; + } + SetDIBitsToDevice(mem_dc, 0, 0, 512, 256, 0, 0, 0, 256, bitmap, (BITMAPINFO*)&bmi, DIB_RGB_COLORS); + } + sprintf(text, "Pal : %d", win->palnum); + SetWindowText(GetDlgItem(hwnd, IDC_PALNUM), text); + } + else + TextOut(mem_dc, 3, 3, "Il n'y a pas de palette", 23); + + BitBlt(hdc, 0, 0, lg, ht, mem_dc, 0, 0, SRCCOPY); + + DeleteDC(mem_dc); + DeleteObject(mem_bmp); + + EndPaint(hwnd, &ps); + return 0; +} + +////////////////////////////////////////////////////////////////////////////// + +LRESULT CALLBACK TileViewBoxProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam) +{ + switch(msg) + { + case WM_INITDIALOG: + return 1; + case WM_NCCREATE: + return 1; + case WM_NCDESTROY: + return 1; + case WM_PAINT: + switch(TileView->coul) + { + case 0 : + TileViewBox_Direct(hwnd, TileView, wParam, lParam); + break; + case 1 : + TileViewBox_Pal256(hwnd, TileView, wParam, lParam); + break; + case 2 : + TileViewBox_Pal16(hwnd, TileView, wParam, lParam); + break; + } + break; + case WM_LBUTTONDOWN : + switch(TileView->coul) + { + case 0 : + case 1 : + if(LOWORD(lParam)<(32*8)) + { + TileView->x = ((LOWORD(lParam)>>3)<<3); + TileView->y = (HIWORD(lParam)>>3)<<3; + TileView->tilenum = (LOWORD(lParam)>>3) + (HIWORD(lParam)>>3)*32; + } + break; + case 2 : + TileView->x = ((LOWORD(lParam)>>3)<<3); + TileView->y = (HIWORD(lParam)>>3)<<3; + TileView->tilenum = (LOWORD(lParam)>>3) + (HIWORD(lParam)>>3)*64; + break; + } + InvalidateRect(GetDlgItem(hwnd, IDC_MINI_TILE), NULL, FALSE); + return 1; + case WM_ERASEBKGND: + return 1; + } + return DefWindowProc(hwnd, msg, wParam, lParam); +} + +LRESULT MiniTileViewBox_Paint(HWND hwnd, tileview_struct * win, WPARAM wParam, LPARAM lParam) +{ + HWND hwnd_src = GetDlgItem(GetParent(hwnd), IDC_Tile_BOX); + HDC hdc_src; + HDC hdc_dst; + char txt[80]; + + PAINTSTRUCT ps; + + hdc_dst = BeginPaint(hwnd, &ps); + hdc_src = GetDC(hwnd_src); + StretchBlt(hdc_dst, 0, 0, 80, 80, hdc_src, win->x, win->y, 8, 8, SRCCOPY); + sprintf(txt, "Tile num : 0x%X", win->tilenum); + SetWindowText(GetDlgItem(win->hwnd, IDC_TILENUM), txt); + EndPaint(hwnd, &ps); + return 0; +} + +LRESULT CALLBACK MiniTileViewBoxProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam) +{ + switch(msg) + { + case WM_NCCREATE: + return 1; + case WM_NCDESTROY: + return 1; + case WM_PAINT : + MiniTileViewBox_Paint(hwnd, TileView, wParam, lParam); + break; + case WM_ERASEBKGND: + return 1; + default: + break; + } + return DefWindowProc(hwnd, msg, wParam, lParam); +} + +BOOL CALLBACK ViewTilesProc (HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam) +{ + //bail out early if the dialog isnt initialized + if(!TileView && message != WM_INITDIALOG) + return false; + + switch (message) + { + case WM_INITDIALOG : + { + TileView = new tileview_struct; + memset(TileView, 0, sizeof(tileview_struct)); + TileView->hwnd = hwnd; + TileView->target = ARM9MEM_ABG; + TileView->pal = ((u16 *)ARM9Mem.ARM9_VMEM); + TileView->autoup_secs = 1; + SendMessage(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SPIN), + UDM_SETRANGE, 0, MAKELONG(99, 1)); + SendMessage(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SPIN), + UDM_SETPOS32, 0, TileView->autoup_secs); + + HWND combo = GetDlgItem(hwnd, IDC_PAL_SELECT); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Main screen BG PAL"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Sub screen BG PAL"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Main screen SPR PAL"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Sub screen SPR PAL"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Main screen ExtPAL 0"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Main screen ExtPAL 1"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Main screen ExtPAL 2"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Main screen ExtPAL 3"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Sub screen ExtPAL 0"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Sub screen ExtPAL 1"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Sub screen ExtPAL 2"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Sub screen ExtPAL 3"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Main spr ExtPAL 0"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Main spr ExtPAL 1"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Sub spr ExtPAL 0"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Sub spr ExtPAL 1"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Texture PAL 0"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Texture PAL 1"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Texture PAL 2"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"Texture PAL 3"); + SendMessage(combo, CB_SETCURSEL, 0, 0); + + combo = GetDlgItem(hwnd, IDC_MEM_SELECT); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"A-BG - 0x6000000"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"A-BG - 0x6010000"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"A-BG - 0x6020000"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"A-BG - 0x6030000"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"A-BG - 0x6040000"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"A-BG - 0x6050000"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"A-BG - 0x6060000"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"A-BG - 0x6070000"); + + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"B-BG - 0x6200000"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"B-BG - 0x6210000"); + + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"A-OBJ- 0x6400000"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"A-OBJ- 0x6410000"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"A-OBJ- 0x6420000"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"A-OBJ- 0x6430000"); + + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"B-OBJ- 0x6600000"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"B-OBJ- 0x6610000"); + + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"LCD - 0x6800000"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"LCD - 0x6810000"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"LCD - 0x6820000"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"LCD - 0x6830000"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"LCD - 0x6840000"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"LCD - 0x6850000"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"LCD - 0x6860000"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"LCD - 0x6870000"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"LCD - 0x6880000"); + SendMessage(combo, CB_ADDSTRING, 0,(LPARAM)"LCD - 0x6890000"); + SendMessage(combo, CB_SETCURSEL, 0, 0); + SendMessage(GetDlgItem(hwnd, IDC_BITMAP), BM_SETCHECK, TRUE, 0); + } + return 1; + case WM_CLOSE : + if(TileView->autoup) + { + KillTimer(hwnd, IDT_VIEW_TILE); + TileView->autoup = false; + } + if (TileView!=NULL) + { + delete TileView; + TileView = NULL; + } + //INFO("Close Tile view dialog\n"); + PostQuitMessage(0); + return 1; + case WM_TIMER: + SendMessage(hwnd, WM_COMMAND, IDC_REFRESH, 0); + return 1; + case WM_HSCROLL : + switch LOWORD(wParam) + { + case SB_LINERIGHT : + ++(TileView->palnum); + if(TileView->palnum>15) + TileView->palnum = 15; + break; + case SB_LINELEFT : + --(TileView->palnum); + if(TileView->palnum<0) + TileView->palnum = 0; + break; + } + InvalidateRect(hwnd, NULL, FALSE); + return 1; + case WM_COMMAND : + switch (LOWORD (wParam)) + { + case IDC_FERMER : + SendMessage(hwnd, WM_CLOSE, 0, 0); + return 1; + case IDC_AUTO_UPDATE : + if(TileView->autoup) + { + EnableWindow(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SECS), false); + EnableWindow(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SPIN), false); + KillTimer(hwnd, IDT_VIEW_TILE); + TileView->autoup = FALSE; + return 1; + } + EnableWindow(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SECS), true); + EnableWindow(GetDlgItem(hwnd, IDC_AUTO_UPDATE_SPIN), true); + TileView->autoup = TRUE; + SetTimer(hwnd, IDT_VIEW_TILE, TileView->autoup_secs*20, (TIMERPROC) NULL); + return 1; + case IDC_AUTO_UPDATE_SECS: + { + int t = GetDlgItemInt(hwnd, IDC_AUTO_UPDATE_SECS, FALSE, TRUE); + if (!TileView) + { + SendMessage(hwnd, WM_INITDIALOG, 0, 0); + } + if (t != TileView->autoup_secs) + { + TileView->autoup_secs = t; + if (TileView->autoup) + SetTimer(hwnd, IDT_VIEW_TILE, + TileView->autoup_secs*20, (TIMERPROC) NULL); + } + } + return 1; + case IDC_REFRESH: + InvalidateRect(hwnd, NULL, FALSE); + return 1; + case IDC_BITMAP : + TileView->coul = 0; + InvalidateRect(hwnd, NULL, FALSE); + return 1; + case IDC_256COUL : + TileView->coul = 1; + InvalidateRect(hwnd, NULL, FALSE); + return 1; + case IDC_16COUL : + TileView->coul = 2; + InvalidateRect(hwnd, NULL, FALSE); + return 1; + case IDC_MEM_SELECT : + switch(HIWORD(wParam)) + { + case CBN_SELCHANGE : + case CBN_CLOSEUP : + { + u32 sel = SendMessage(GetDlgItem(hwnd, IDC_MEM_SELECT), CB_GETCURSEL, 0, 0); + switch(sel) + { + case 0 : + case 1 : + case 2 : + case 3 : + case 4 : + case 5 : + case 6 : + case 7 : + TileView->target = ARM9MEM_ABG + 0x10000*sel; + break; + case 8 : + case 9 : + TileView->target = ARM9MEM_BBG + 0x10000*(sel-8); + break; + case 10 : + case 11 : + case 12 : + case 13 : + TileView->target = ARM9MEM_AOBJ + 0x10000*(sel-10); + break; + case 14 : + case 15 : + TileView->target = ARM9MEM_BOBJ + 0x10000*(sel-14); + break; + case 16 : + case 17 : + case 18 : + case 19 : + case 20 : + case 21 : + case 22 : + case 23 : + case 24 : + case 25 : + TileView->target = ARM9MEM_LCDC + 0x10000*(sel-16); + break; + default : + return 1; + } + InvalidateRect(hwnd, NULL, FALSE); + return 1; + } + } + return 1; + case IDC_PAL_SELECT : + switch(HIWORD(wParam)) + { + case CBN_SELCHANGE : + case CBN_CLOSEUP : + { + u32 sel = SendMessage(GetDlgItem(hwnd, IDC_PAL_SELECT), CB_GETCURSEL, 0, 0); + switch(sel) + { + case 0 : + TileView->pal = (u16 *)ARM9Mem.ARM9_VMEM; + TileView->palnum = 0; + ShowWindow(GetDlgItem(hwnd, IDC_16COUL), SW_SHOW); + EnableWindow(GetDlgItem(hwnd, IDC_16COUL), TRUE); + break; + case 1 : + TileView->pal = ((u16 *)ARM9Mem.ARM9_VMEM) + 0x200; + TileView->palnum = 0; + ShowWindow(GetDlgItem(hwnd, IDC_16COUL), SW_SHOW); + EnableWindow(GetDlgItem(hwnd, IDC_16COUL), TRUE); + break; + case 2 : + TileView->pal = (u16 *)ARM9Mem.ARM9_VMEM + 0x100; + TileView->palnum = 0; + ShowWindow(GetDlgItem(hwnd, IDC_16COUL), SW_SHOW); + EnableWindow(GetDlgItem(hwnd, IDC_16COUL), TRUE); + break; + case 3 : + TileView->pal = ((u16 *)ARM9Mem.ARM9_VMEM) + 0x300; + TileView->palnum = 0; + ShowWindow(GetDlgItem(hwnd, IDC_16COUL), SW_SHOW); + EnableWindow(GetDlgItem(hwnd, IDC_16COUL), TRUE); + break; + case 4 : + case 5 : + case 6 : + case 7 : + TileView->pal = ((u16 *)(ARM9Mem.ExtPal[0][sel-4])); + TileView->palnum = 0; + ShowWindow(GetDlgItem(hwnd, IDC_16COUL), SW_HIDE); + EnableWindow(GetDlgItem(hwnd, IDC_16COUL), FALSE); + if(TileView->coul == 2) + { + SendMessage(GetDlgItem(hwnd, IDC_256COUL), BM_SETCHECK, TRUE, 0); + SendMessage(GetDlgItem(hwnd, IDC_16COUL), BM_SETCHECK, FALSE, 0); + TileView->coul = 1; + } + break; + case 8 : + case 9 : + case 10 : + case 11 : + TileView->pal = ((u16 *)(ARM9Mem.ExtPal[1][sel-8])); + TileView->palnum = 0; + ShowWindow(GetDlgItem(hwnd, IDC_16COUL), SW_HIDE); + EnableWindow(GetDlgItem(hwnd, IDC_16COUL), FALSE); + if(TileView->coul == 2) + { + SendMessage(GetDlgItem(hwnd, IDC_256COUL), BM_SETCHECK, TRUE, 0); + SendMessage(GetDlgItem(hwnd, IDC_16COUL), BM_SETCHECK, FALSE, 0); + TileView->coul = 1; + } + break; + case 12 : + case 13 : + TileView->pal = ((u16 *)(ARM9Mem.ObjExtPal[0][sel-12])); + TileView->palnum = 0; + if(TileView->coul == 2) + { + SendMessage(GetDlgItem(hwnd, IDC_256COUL), BM_SETCHECK, TRUE, 0); + SendMessage(GetDlgItem(hwnd, IDC_16COUL), BM_SETCHECK, FALSE, 0); + TileView->coul = 1; + } + break; + case 14 : + case 15 : + TileView->pal = ((u16 *)(ARM9Mem.ObjExtPal[1][sel-14])); + TileView->palnum = 0; + if(TileView->coul == 2) + { + SendMessage(GetDlgItem(hwnd, IDC_256COUL), BM_SETCHECK, TRUE, 0); + SendMessage(GetDlgItem(hwnd, IDC_16COUL), BM_SETCHECK, FALSE, 0); + TileView->coul = 1; + } + break; + case 16 : + case 17 : + case 18 : + case 19 : + TileView->pal = ((u16 *)(ARM9Mem.texInfo.texPalSlot[sel-16])); + TileView->palnum = 0; + ShowWindow(GetDlgItem(hwnd, IDC_16COUL), SW_SHOW); + EnableWindow(GetDlgItem(hwnd, IDC_16COUL), TRUE); + break; + default : + return 1; + } + InvalidateRect(hwnd, NULL, FALSE); + return 1; + } + } + } + return 0; + } + return FALSE; +} diff --git a/desmume/src/windows/tileView.h b/src/windows/tileView.h similarity index 97% rename from desmume/src/windows/tileView.h rename to src/windows/tileView.h index 2a53ba6eb..f8be7e555 100644 --- a/desmume/src/windows/tileView.h +++ b/src/windows/tileView.h @@ -1,32 +1,32 @@ -/* Copyright (C) 2006 yopyop - yopyop156@ifrance.com - yopyop156.ifrance.com - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -*/ - -#ifndef TILEVIEW_H -#define TILEVIEW_H - -#include "../common.h" -#include - -extern LRESULT CALLBACK TileViewBoxProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam); -extern LRESULT CALLBACK MiniTileViewBoxProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam); -extern BOOL CALLBACK ViewTilesProc (HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam); - -#endif +/* Copyright (C) 2006 yopyop + yopyop156@ifrance.com + yopyop156.ifrance.com + + This file is part of DeSmuME + + DeSmuME is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + DeSmuME is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with DeSmuME; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#ifndef TILEVIEW_H +#define TILEVIEW_H + +#include "../common.h" +#include + +extern LRESULT CALLBACK TileViewBoxProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam); +extern LRESULT CALLBACK MiniTileViewBoxProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam); +extern BOOL CALLBACK ViewTilesProc (HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam); + +#endif diff --git a/src/windows/wavout.cpp b/src/windows/wavout.cpp new file mode 100644 index 000000000..bd036ced3 --- /dev/null +++ b/src/windows/wavout.cpp @@ -0,0 +1,204 @@ +/* wavout.cpp + * + * Copyright (C) 2006-2008 Zeromus + * + * This file is part of DeSmuME + * + * DeSmuME is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * DeSmuME is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with DeSmuME; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA +*/ +#include "main.h" //I added this so that this file could gain access to SetMessageToDisplay. +#include "types.h" +#include "windriver.h" +#include "console.h" +#include "gfx3d.h" +#include "wavout.h" +#include "../GPU_osd.h" + +#include +#include +#include + +#include "debug.h" + +static void EMU_PrintError(const char* msg) { + LOG(msg); +} + +static void EMU_PrintMessage(const char* msg) { + LOG(msg); +} + +bool DRV_WavBegin(const char* fname); +void DRV_WavEnd(); +void DRV_WavSoundUpdate(void* soundData, int soundLen); +bool DRV_WavIsRecording(); + +static struct WAVFile +{ + bool valid; + + WAVEFORMATEX wav_format_master; + WAVEFORMATEX wav_format; + HMMIO wav_file; + + MMCKINFO waveChunk; + MMCKINFO fmtChunk; + MMCKINFO dataChunk; +} *wav_file = NULL; + +static void wav_create(struct WAVFile** wav_out) +{ + *wav_out = (struct WAVFile*)malloc(sizeof(struct WAVFile)); + memset(*wav_out, 0, sizeof(struct WAVFile)); +} + +static void wav_destroy(struct WAVFile** wav_out) +{ + if(!(*wav_out)) + return; + + if((*wav_out)->wav_file) + { + mmioAscend((*wav_out)->wav_file, &(*wav_out)->dataChunk, 0); + mmioAscend((*wav_out)->wav_file, &(*wav_out)->waveChunk, 0); +// mmioFlush((*wav_out)->wav_file, 0); + mmioClose((*wav_out)->wav_file, 0); + (*wav_out)->wav_file = NULL; + } + + free(*wav_out); + *wav_out = NULL; +} + +static void set_sound_format(const WAVEFORMATEX* wave_format, struct WAVFile* wav_out) +{ + memcpy(&((*wav_out).wav_format_master), wave_format, sizeof(WAVEFORMATEX)); +} + +static int wav_open(const char* filename, const WAVEFORMATEX* pwfex) +{ + int error = 1; + int result = 0; + + do + { + // close existing first + DRV_WavEnd(); + + // create the object + wav_create(&wav_file); + if(!wav_file) + break; + + // add audio format + set_sound_format(pwfex, wav_file); + + // open the file + if(!(wav_file->wav_file = mmioOpen((LPSTR)filename, NULL, MMIO_CREATE|MMIO_WRITE))) + break; + + // create WAVE chunk + wav_file->waveChunk.fccType = mmioFOURCC('W', 'A', 'V', 'E'); + mmioCreateChunk(wav_file->wav_file, &wav_file->waveChunk, MMIO_CREATERIFF); + + // create Format chunk + wav_file->fmtChunk.ckid = mmioFOURCC('f', 'm', 't', ' '); + mmioCreateChunk(wav_file->wav_file, &wav_file->fmtChunk, 0); + // then write header + memcpy(&wav_file->wav_format, &wav_file->wav_format_master, sizeof(WAVEFORMATEX)); + wav_file->wav_format.cbSize = 0; + mmioWrite(wav_file->wav_file, (HPSTR) &wav_file->wav_format, sizeof(WAVEFORMATEX)); + mmioAscend(wav_file->wav_file, &wav_file->fmtChunk, 0); + + // create Data chunk + wav_file->dataChunk.ckid = mmioFOURCC('d', 'a', 't', 'a'); + mmioCreateChunk(wav_file->wav_file, &wav_file->dataChunk, 0); + + // success + error = 0; + result = 1; + wav_file->valid = true; + + } while(false); + + if(!result) + { + wav_destroy(&wav_file); + if(error) + EMU_PrintError("Error writing WAV file"); + } + + return result; +} + + +bool DRV_WavBegin(const char* fname) +{ + DRV_WavEnd(); + + WAVEFORMATEX wf; + wf.cbSize = sizeof(WAVEFORMATEX); + wf.nAvgBytesPerSec = 44100 * 4; + wf.nBlockAlign = 4; + wf.nChannels = 2; + wf.nSamplesPerSec = 44100; + wf.wBitsPerSample = 16; + wf.wFormatTag = WAVE_FORMAT_PCM; + WAVEFORMATEX* pwf = &wf; + + if(!wav_open(fname, pwf)) + return 0; + + EMU_PrintMessage("WAV recording started."); + osd->addLine("WAV recording started."); + + return 1; +} + +BOOL WAV_IsRecording() +{ + return wav_file && wav_file->valid; +} +void DRV_WavSoundUpdate(void* soundData, int soundLen) +{ + int nBytes; + + if(!WAV_IsRecording()) + return; + + nBytes = soundLen * wav_file->wav_format.nBlockAlign; + // assumes mmio system has been opened data chunk + mmioWrite(wav_file->wav_file, (HPSTR) soundData, nBytes); +// mmioFlush(wav_file->wav_file, 0); +} + +void DRV_WavEnd() +{ + if(!wav_file) + return; + + EMU_PrintMessage("WAV recording ended."); + osd->addLine("WAV recording ended."); + + wav_destroy(&wav_file); +} + +bool DRV_WavIsRecording() +{ + if(wav_file) + return true; + + return false; +} diff --git a/src/windows/wavout.h b/src/windows/wavout.h new file mode 100644 index 000000000..5d8565cb5 --- /dev/null +++ b/src/windows/wavout.h @@ -0,0 +1,4 @@ +bool DRV_WavBegin(const char* fname); +void DRV_WavEnd(); +void DRV_WavSoundUpdate(void* soundData, int soundLen); +bool DRV_WavIsRecording(); \ No newline at end of file diff --git a/desmume/src/windows/windriver.h b/src/windows/windriver.h similarity index 57% rename from desmume/src/windows/windriver.h rename to src/windows/windriver.h index 5f12daad0..2f528809f 100644 --- a/desmume/src/windows/windriver.h +++ b/src/windows/windriver.h @@ -1,55 +1,34 @@ -/* windriver.h - - Copyright (C) 2008-2009 DeSmuME team - - This file is part of DeSmuME - - DeSmuME is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - DeSmuME is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with DeSmuME; if not, write to the Free Software - Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -*/ - -#ifndef _WINDRIVER_H_ -#define _WINDRIVER_H_ - -#define WIN32_LEAN_AND_MEAN -#include "../common.h" -#include "CWindow.h" - -#ifdef EXPERIMENTAL_WIFI -#include -#include //uh? - -//because the pcap headers are written poorly, we need to declare these as cdecl -//this may cause the code to fail to compile on non-windows platforms; -//we may have to use a macro to call these functions which chooses whether to call them -//through the namespace -namespace PCAP { - extern "C" __declspec(dllexport) int __cdecl pcap_findalldevs_ex(char *source, struct pcap_rmtauth *auth, pcap_if_t **alldevs, char *errbuf); - extern "C" __declspec(dllexport) int __cdecl pcap_sendpacket(pcap_t *, const u_char *, int); - extern "C" __declspec(dllexport) void __cdecl pcap_close(pcap_t *); - extern "C" __declspec(dllexport) pcap_t* __cdecl pcap_open(const char *source, int snaplen, int flags, int read_timeout, struct pcap_rmtauth *auth, char *errbuf); - extern "C" __declspec(dllexport) void __cdecl pcap_freealldevs(pcap_if_t *); -} - -#endif - -extern WINCLASS *MainWindow; - -class Lock { -public: - Lock(); - ~Lock(); -}; - +#ifndef _WINDRIVER_H_ +#define _WINDRIVER_H_ + +#define WIN32_LEAN_AND_MEAN +#include "../common.h" +#include "CWindow.h" + +#ifdef EXPERIMENTAL_WIFI +#include +#include //uh? + +//because the pcap headers are written poorly, we need to declare these as cdecl +//this may cause the code to fail to compile on non-windows platforms; +//we may have to use a macro to call these functions which chooses whether to call them +//through the namespace +namespace PCAP { + extern "C" __declspec(dllexport) int __cdecl pcap_findalldevs_ex(char *source, struct pcap_rmtauth *auth, pcap_if_t **alldevs, char *errbuf); + extern "C" __declspec(dllexport) int __cdecl pcap_sendpacket(pcap_t *, const u_char *, int); + extern "C" __declspec(dllexport) void __cdecl pcap_close(pcap_t *); + extern "C" __declspec(dllexport) pcap_t* __cdecl pcap_open(const char *source, int snaplen, int flags, int read_timeout, struct pcap_rmtauth *auth, char *errbuf); + extern "C" __declspec(dllexport) void __cdecl pcap_freealldevs(pcap_if_t *); +} + +#endif + +extern WINCLASS *MainWindow; + +class Lock { +public: + Lock(); + ~Lock(); +}; + #endif \ No newline at end of file diff --git a/desmume/src/windows/winpcap/Devioctl.h b/src/windows/winpcap/Devioctl.h similarity index 97% rename from desmume/src/windows/winpcap/Devioctl.h rename to src/windows/winpcap/Devioctl.h index 661fda029..af8784bfd 100644 --- a/desmume/src/windows/winpcap/Devioctl.h +++ b/src/windows/winpcap/Devioctl.h @@ -1,90 +1,90 @@ -/*++ BUILD Version: 0004 // Increment this if a change has global effects - Copyright (c) 1992-1993 Microsoft Corporation - Module Name: - devioctl.h - Revision History: - -- */ -// begin_winioctl -#ifndef _DEVIOCTL_ -#define _DEVIOCTL_ -// begin_ntddk begin_nthal begin_ntifs -// -// Define the various device type values. Note that values used by Microsoft -// Corporation are in the range 0-32767, and 32768-65535 are reserved for use -// by customers. -// -#define DEVICE_TYPE ULONG -#define FILE_DEVICE_BEEP 0x00000001 -#define FILE_DEVICE_CD_ROM 0x00000002 -#define FILE_DEVICE_CD_ROM_FILE_SYSTEM 0x00000003 -#define FILE_DEVICE_CONTROLLER 0x00000004 -#define FILE_DEVICE_DATALINK 0x00000005 -#define FILE_DEVICE_DFS 0x00000006 -#define FILE_DEVICE_DISK 0x00000007 -#define FILE_DEVICE_DISK_FILE_SYSTEM 0x00000008 -#define FILE_DEVICE_FILE_SYSTEM 0x00000009 -#define FILE_DEVICE_INPORT_PORT 0x0000000a -#define FILE_DEVICE_KEYBOARD 0x0000000b -#define FILE_DEVICE_MAILSLOT 0x0000000c -#define FILE_DEVICE_MIDI_IN 0x0000000d -#define FILE_DEVICE_MIDI_OUT 0x0000000e -#define FILE_DEVICE_MOUSE 0x0000000f -#define FILE_DEVICE_MULTI_UNC_PROVIDER 0x00000010 -#define FILE_DEVICE_NAMED_PIPE 0x00000011 -#define FILE_DEVICE_NETWORK 0x00000012 -#define FILE_DEVICE_NETWORK_BROWSER 0x00000013 -#define FILE_DEVICE_NETWORK_FILE_SYSTEM 0x00000014 -#define FILE_DEVICE_NULL 0x00000015 -#define FILE_DEVICE_PARALLEL_PORT 0x00000016 -#define FILE_DEVICE_PHYSICAL_NETCARD 0x00000017 -#define FILE_DEVICE_PRINTER 0x00000018 -#define FILE_DEVICE_SCANNER 0x00000019 -#define FILE_DEVICE_SERIAL_MOUSE_PORT 0x0000001a -#define FILE_DEVICE_SERIAL_PORT 0x0000001b -#define FILE_DEVICE_SCREEN 0x0000001c -#define FILE_DEVICE_SOUND 0x0000001d -#define FILE_DEVICE_STREAMS 0x0000001e -#define FILE_DEVICE_TAPE 0x0000001f -#define FILE_DEVICE_TAPE_FILE_SYSTEM 0x00000020 -#define FILE_DEVICE_TRANSPORT 0x00000021 -#define FILE_DEVICE_UNKNOWN 0x00000022 -#define FILE_DEVICE_VIDEO 0x00000023 -#define FILE_DEVICE_VIRTUAL_DISK 0x00000024 -#define FILE_DEVICE_WAVE_IN 0x00000025 -#define FILE_DEVICE_WAVE_OUT 0x00000026 -#define FILE_DEVICE_8042_PORT 0x00000027 -#define FILE_DEVICE_NETWORK_REDIRECTOR 0x00000028 -#define FILE_DEVICE_BATTERY 0x00000029 -#define FILE_DEVICE_BUS_EXTENDER 0x0000002a -#define FILE_DEVICE_MODEM 0x0000002b -#define FILE_DEVICE_VDM 0x0000002c -#define FILE_DEVICE_MASS_STORAGE 0x0000002d -// -// Macro definition for defining IOCTL and FSCTL function control codes. Note -// that function codes 0-2047 are reserved for Microsoft Corporation, and -// 2048-4095 are reserved for customers. -// -#define CTL_CODE( DeviceType, Function, Method, Access ) ( \ - ((DeviceType) << 16) | ((Access) << 14) | ((Function) << 2) | (Method) \ -) -// -// Define the method codes for how buffers are passed for I/O and FS controls -// -#define METHOD_BUFFERED 0 -#define METHOD_IN_DIRECT 1 -#define METHOD_OUT_DIRECT 2 -#define METHOD_NEITHER 3 -// -// Define the access check value for any access -// -// -// The FILE_READ_ACCESS and FILE_WRITE_ACCESS constants are also defined in -// ntioapi.h as FILE_READ_DATA and FILE_WRITE_DATA. The values for these -// constants *MUST* always be in sync. -// -#define FILE_ANY_ACCESS 0 -#define FILE_READ_ACCESS ( 0x0001 ) // file & pipe -#define FILE_WRITE_ACCESS ( 0x0002 ) // file & pipe -// end_ntddk end_nthal end_ntifs -#endif // _DEVIOCTL_ -// end_winioctl +/*++ BUILD Version: 0004 // Increment this if a change has global effects + Copyright (c) 1992-1993 Microsoft Corporation + Module Name: + devioctl.h + Revision History: + -- */ +// begin_winioctl +#ifndef _DEVIOCTL_ +#define _DEVIOCTL_ +// begin_ntddk begin_nthal begin_ntifs +// +// Define the various device type values. Note that values used by Microsoft +// Corporation are in the range 0-32767, and 32768-65535 are reserved for use +// by customers. +// +#define DEVICE_TYPE ULONG +#define FILE_DEVICE_BEEP 0x00000001 +#define FILE_DEVICE_CD_ROM 0x00000002 +#define FILE_DEVICE_CD_ROM_FILE_SYSTEM 0x00000003 +#define FILE_DEVICE_CONTROLLER 0x00000004 +#define FILE_DEVICE_DATALINK 0x00000005 +#define FILE_DEVICE_DFS 0x00000006 +#define FILE_DEVICE_DISK 0x00000007 +#define FILE_DEVICE_DISK_FILE_SYSTEM 0x00000008 +#define FILE_DEVICE_FILE_SYSTEM 0x00000009 +#define FILE_DEVICE_INPORT_PORT 0x0000000a +#define FILE_DEVICE_KEYBOARD 0x0000000b +#define FILE_DEVICE_MAILSLOT 0x0000000c +#define FILE_DEVICE_MIDI_IN 0x0000000d +#define FILE_DEVICE_MIDI_OUT 0x0000000e +#define FILE_DEVICE_MOUSE 0x0000000f +#define FILE_DEVICE_MULTI_UNC_PROVIDER 0x00000010 +#define FILE_DEVICE_NAMED_PIPE 0x00000011 +#define FILE_DEVICE_NETWORK 0x00000012 +#define FILE_DEVICE_NETWORK_BROWSER 0x00000013 +#define FILE_DEVICE_NETWORK_FILE_SYSTEM 0x00000014 +#define FILE_DEVICE_NULL 0x00000015 +#define FILE_DEVICE_PARALLEL_PORT 0x00000016 +#define FILE_DEVICE_PHYSICAL_NETCARD 0x00000017 +#define FILE_DEVICE_PRINTER 0x00000018 +#define FILE_DEVICE_SCANNER 0x00000019 +#define FILE_DEVICE_SERIAL_MOUSE_PORT 0x0000001a +#define FILE_DEVICE_SERIAL_PORT 0x0000001b +#define FILE_DEVICE_SCREEN 0x0000001c +#define FILE_DEVICE_SOUND 0x0000001d +#define FILE_DEVICE_STREAMS 0x0000001e +#define FILE_DEVICE_TAPE 0x0000001f +#define FILE_DEVICE_TAPE_FILE_SYSTEM 0x00000020 +#define FILE_DEVICE_TRANSPORT 0x00000021 +#define FILE_DEVICE_UNKNOWN 0x00000022 +#define FILE_DEVICE_VIDEO 0x00000023 +#define FILE_DEVICE_VIRTUAL_DISK 0x00000024 +#define FILE_DEVICE_WAVE_IN 0x00000025 +#define FILE_DEVICE_WAVE_OUT 0x00000026 +#define FILE_DEVICE_8042_PORT 0x00000027 +#define FILE_DEVICE_NETWORK_REDIRECTOR 0x00000028 +#define FILE_DEVICE_BATTERY 0x00000029 +#define FILE_DEVICE_BUS_EXTENDER 0x0000002a +#define FILE_DEVICE_MODEM 0x0000002b +#define FILE_DEVICE_VDM 0x0000002c +#define FILE_DEVICE_MASS_STORAGE 0x0000002d +// +// Macro definition for defining IOCTL and FSCTL function control codes. Note +// that function codes 0-2047 are reserved for Microsoft Corporation, and +// 2048-4095 are reserved for customers. +// +#define CTL_CODE( DeviceType, Function, Method, Access ) ( \ + ((DeviceType) << 16) | ((Access) << 14) | ((Function) << 2) | (Method) \ +) +// +// Define the method codes for how buffers are passed for I/O and FS controls +// +#define METHOD_BUFFERED 0 +#define METHOD_IN_DIRECT 1 +#define METHOD_OUT_DIRECT 2 +#define METHOD_NEITHER 3 +// +// Define the access check value for any access +// +// +// The FILE_READ_ACCESS and FILE_WRITE_ACCESS constants are also defined in +// ntioapi.h as FILE_READ_DATA and FILE_WRITE_DATA. The values for these +// constants *MUST* always be in sync. +// +#define FILE_ANY_ACCESS 0 +#define FILE_READ_ACCESS ( 0x0001 ) // file & pipe +#define FILE_WRITE_ACCESS ( 0x0002 ) // file & pipe +// end_ntddk end_nthal end_ntifs +#endif // _DEVIOCTL_ +// end_winioctl diff --git a/desmume/src/windows/winpcap/Gnuc.h b/src/windows/winpcap/Gnuc.h similarity index 94% rename from desmume/src/windows/winpcap/Gnuc.h rename to src/windows/winpcap/Gnuc.h index b05890f9e..b7cfb59c7 100644 --- a/desmume/src/windows/winpcap/Gnuc.h +++ b/src/windows/winpcap/Gnuc.h @@ -1,46 +1,46 @@ -/* @(#) $Header: /tcpdump/master/libpcap/Win32/Include/Gnuc.h,v 1.1 2002/08/01 08:33:05 risso Exp $ (LBL) */ - -/* Define __P() macro, if necessary */ - -#ifndef __P -#if __STDC__ -#define __P(protos) protos -#else -#define __P(protos) () -#endif -#endif - -/* inline foo */ -#ifndef __cplusplus -#ifdef __GNUC__ -#define inline __inline -#else -#define inline -#endif -#endif - -/* - * Handle new and old "dead" routine prototypes - * - * For example: - * - * __dead void foo(void) __attribute__((volatile)); - * - */ -#ifdef __GNUC__ -#ifndef __dead -#define __dead volatile -#endif -#if __GNUC__ < 2 || (__GNUC__ == 2 && __GNUC_MINOR__ < 5) -#ifndef __attribute__ -#define __attribute__(args) -#endif -#endif -#else -#ifndef __dead -#define __dead -#endif -#ifndef __attribute__ -#define __attribute__(args) -#endif -#endif +/* @(#) $Header: /tcpdump/master/libpcap/Win32/Include/Gnuc.h,v 1.1 2002/08/01 08:33:05 risso Exp $ (LBL) */ + +/* Define __P() macro, if necessary */ + +#ifndef __P +#if __STDC__ +#define __P(protos) protos +#else +#define __P(protos) () +#endif +#endif + +/* inline foo */ +#ifndef __cplusplus +#ifdef __GNUC__ +#define inline __inline +#else +#define inline +#endif +#endif + +/* + * Handle new and old "dead" routine prototypes + * + * For example: + * + * __dead void foo(void) __attribute__((volatile)); + * + */ +#ifdef __GNUC__ +#ifndef __dead +#define __dead volatile +#endif +#if __GNUC__ < 2 || (__GNUC__ == 2 && __GNUC_MINOR__ < 5) +#ifndef __attribute__ +#define __attribute__(args) +#endif +#endif +#else +#ifndef __dead +#define __dead +#endif +#ifndef __attribute__ +#define __attribute__(args) +#endif +#endif diff --git a/desmume/src/windows/winpcap/Ntddndis.h b/src/windows/winpcap/Ntddndis.h similarity index 97% rename from desmume/src/windows/winpcap/Ntddndis.h rename to src/windows/winpcap/Ntddndis.h index 77a53d7af..0b6298069 100644 --- a/desmume/src/windows/winpcap/Ntddndis.h +++ b/src/windows/winpcap/Ntddndis.h @@ -1,1400 +1,1400 @@ -/*++ BUILD Version: 0001 // Increment this if a change has global effects - Copyright (c) 1990-1993 Microsoft Corporation - Module Name: - ntddndis.h - Abstract: - This is the include file that defines all constants and types for - accessing the Network driver interface device. - Author: - Steve Wood (stevewo) 27-May-1990 - Revision History: - Adam Barr (adamba) 04-Nov-1992 added the correct values for NDIS 3.0. - Jameel Hyder (jameelh) 01-Aug-95 added Pnp IoCTLs and structures - Kyle Brandon (kyleb) 09/24/96 added general co ndis oids. - -- */ -#ifndef _NTDDNDIS_ -#define _NTDDNDIS_ -// -// Device Name - this string is the name of the device. It is the name -// that should be passed to NtOpenFile when accessing the device. -// -// Note: For devices that support multiple units, it should be suffixed -// with the Ascii representation of the unit number. -// -#define DD_NDIS_DEVICE_NAME "\\Device\\UNKNOWN" -// -// NtDeviceIoControlFile IoControlCode values for this device. -// -// Warning: Remember that the low two bits of the code specify how the -// buffers are passed to the driver! -// -#define _NDIS_CONTROL_CODE(request,method) \ - CTL_CODE(FILE_DEVICE_PHYSICAL_NETCARD, request, method, FILE_ANY_ACCESS) -#define IOCTL_NDIS_QUERY_GLOBAL_STATS _NDIS_CONTROL_CODE( 0, METHOD_OUT_DIRECT ) -#define IOCTL_NDIS_QUERY_ALL_STATS _NDIS_CONTROL_CODE( 1, METHOD_OUT_DIRECT ) -#define IOCTL_NDIS_ADD_DEVICE _NDIS_CONTROL_CODE( 2, METHOD_BUFFERED ) -#define IOCTL_NDIS_DELETE_DEVICE _NDIS_CONTROL_CODE( 3, METHOD_BUFFERED ) -#define IOCTL_NDIS_TRANSLATE_NAME _NDIS_CONTROL_CODE( 4, METHOD_BUFFERED ) -#define IOCTL_NDIS_ADD_TDI_DEVICE _NDIS_CONTROL_CODE( 5, METHOD_BUFFERED ) -#define IOCTL_NDIS_NOTIFY_PROTOCOL _NDIS_CONTROL_CODE( 6, METHOD_BUFFERED ) -#define IOCTL_NDIS_GET_LOG_DATA _NDIS_CONTROL_CODE( 7, METHOD_OUT_DIRECT ) -// -// NtDeviceIoControlFile InputBuffer/OutputBuffer record structures for -// this device. -// -// -// This is the type of an NDIS OID value. -// -typedef ULONG NDIS_OID, *PNDIS_OID; -// -// IOCTL_NDIS_QUERY_ALL_STATS returns a sequence of these, packed -// together (no padding is required since statistics all have -// four or eight bytes of data). -// -typedef struct _NDIS_STATISTICS_VALUE { - NDIS_OID Oid; - ULONG DataLength; - UCHAR Data[1]; // variable length - -} NDIS_STATISTICS_VALUE, *PNDIS_STATISTICS_VALUE; - -// -// Structure used by TRANSLATE_NAME IOCTL -// -typedef struct _NET_PNP_ID { - ULONG ClassId; - ULONG Token; -} NET_PNP_ID, *PNET_PNP_ID; - -typedef struct _NET_PNP_TRANSLATE_LIST { - ULONG BytesNeeded; - NET_PNP_ID IdArray[ANYSIZE_ARRAY]; -} NET_PNP_TRANSLATE_LIST, *PNET_PNP_TRANSLATE_LIST; - -// -// Structure used to define a self-contained variable data structure -// -typedef struct _NDIS_VAR_DATA_DESC { - USHORT Length; // # of octects of data - - USHORT MaximumLength; // # of octects available - - LONG Offset; // Offset of data relative to the descriptor - -} NDIS_VAR_DATA_DESC, *PNDIS_VAR_DATA_DESC; - -// -// Object Identifiers used by NdisRequest Query/Set Information -// -// -// General Objects -// -#define OID_GEN_SUPPORTED_LIST 0x00010101 -#define OID_GEN_HARDWARE_STATUS 0x00010102 -#define OID_GEN_MEDIA_SUPPORTED 0x00010103 -#define OID_GEN_MEDIA_IN_USE 0x00010104 -#define OID_GEN_MAXIMUM_LOOKAHEAD 0x00010105 -#define OID_GEN_MAXIMUM_FRAME_SIZE 0x00010106 -#define OID_GEN_LINK_SPEED 0x00010107 -#define OID_GEN_TRANSMIT_BUFFER_SPACE 0x00010108 -#define OID_GEN_RECEIVE_BUFFER_SPACE 0x00010109 -#define OID_GEN_TRANSMIT_BLOCK_SIZE 0x0001010A -#define OID_GEN_RECEIVE_BLOCK_SIZE 0x0001010B -#define OID_GEN_VENDOR_ID 0x0001010C -#define OID_GEN_VENDOR_DESCRIPTION 0x0001010D -#define OID_GEN_CURRENT_PACKET_FILTER 0x0001010E -#define OID_GEN_CURRENT_LOOKAHEAD 0x0001010F -#define OID_GEN_DRIVER_VERSION 0x00010110 -#define OID_GEN_MAXIMUM_TOTAL_SIZE 0x00010111 -#define OID_GEN_PROTOCOL_OPTIONS 0x00010112 -#define OID_GEN_MAC_OPTIONS 0x00010113 -#define OID_GEN_MEDIA_CONNECT_STATUS 0x00010114 -#define OID_GEN_MAXIMUM_SEND_PACKETS 0x00010115 -#define OID_GEN_VENDOR_DRIVER_VERSION 0x00010116 -#define OID_GEN_XMIT_OK 0x00020101 -#define OID_GEN_RCV_OK 0x00020102 -#define OID_GEN_XMIT_ERROR 0x00020103 -#define OID_GEN_RCV_ERROR 0x00020104 -#define OID_GEN_RCV_NO_BUFFER 0x00020105 -#define OID_GEN_DIRECTED_BYTES_XMIT 0x00020201 -#define OID_GEN_DIRECTED_FRAMES_XMIT 0x00020202 -#define OID_GEN_MULTICAST_BYTES_XMIT 0x00020203 -#define OID_GEN_MULTICAST_FRAMES_XMIT 0x00020204 -#define OID_GEN_BROADCAST_BYTES_XMIT 0x00020205 -#define OID_GEN_BROADCAST_FRAMES_XMIT 0x00020206 -#define OID_GEN_DIRECTED_BYTES_RCV 0x00020207 -#define OID_GEN_DIRECTED_FRAMES_RCV 0x00020208 -#define OID_GEN_MULTICAST_BYTES_RCV 0x00020209 -#define OID_GEN_MULTICAST_FRAMES_RCV 0x0002020A -#define OID_GEN_BROADCAST_BYTES_RCV 0x0002020B -#define OID_GEN_BROADCAST_FRAMES_RCV 0x0002020C -#define OID_GEN_RCV_CRC_ERROR 0x0002020D -#define OID_GEN_TRANSMIT_QUEUE_LENGTH 0x0002020E -#define OID_GEN_GET_TIME_CAPS 0x0002020F -#define OID_GEN_GET_NETCARD_TIME 0x00020210 -// -// These are connection-oriented general OIDs. -// These replace the above OIDs for connection-oriented media. -// -#define OID_GEN_CO_SUPPORTED_LIST 0x00010101 -#define OID_GEN_CO_HARDWARE_STATUS 0x00010102 -#define OID_GEN_CO_MEDIA_SUPPORTED 0x00010103 -#define OID_GEN_CO_MEDIA_IN_USE 0x00010104 -#define OID_GEN_CO_LINK_SPEED 0x00010105 -#define OID_GEN_CO_VENDOR_ID 0x00010106 -#define OID_GEN_CO_VENDOR_DESCRIPTION 0x00010107 -#define OID_GEN_CO_DRIVER_VERSION 0x00010108 -#define OID_GEN_CO_PROTOCOL_OPTIONS 0x00010109 -#define OID_GEN_CO_MAC_OPTIONS 0x0001010A -#define OID_GEN_CO_MEDIA_CONNECT_STATUS 0x0001010B -#define OID_GEN_CO_VENDOR_DRIVER_VERSION 0x0001010C -#define OID_GEN_CO_MINIMUM_LINK_SPEED 0x0001010D -#define OID_GEN_CO_GET_TIME_CAPS 0x00010201 -#define OID_GEN_CO_GET_NETCARD_TIME 0x00010202 -// -// These are connection-oriented statistics OIDs. -// -#define OID_GEN_CO_XMIT_PDUS_OK 0x00020101 -#define OID_GEN_CO_RCV_PDUS_OK 0x00020102 -#define OID_GEN_CO_XMIT_PDUS_ERROR 0x00020103 -#define OID_GEN_CO_RCV_PDUS_ERROR 0x00020104 -#define OID_GEN_CO_RCV_PDUS_NO_BUFFER 0x00020105 -#define OID_GEN_CO_RCV_CRC_ERROR 0x00020201 -#define OID_GEN_CO_TRANSMIT_QUEUE_LENGTH 0x00020202 -#define OID_GEN_CO_BYTES_XMIT 0x00020203 -#define OID_GEN_CO_BYTES_RCV 0x00020204 -#define OID_GEN_CO_BYTES_XMIT_OUTSTANDING 0x00020205 -#define OID_GEN_CO_NETCARD_LOAD 0x00020206 -// -// These are objects for Connection-oriented media call-managers and are not -// valid for ndis drivers. Under construction. -// -#define OID_CO_ADD_PVC 0xFF000001 -#define OID_CO_DELETE_PVC 0xFF000002 -#define OID_CO_GET_CALL_INFORMATION 0xFF000003 -#define OID_CO_ADD_ADDRESS 0xFF000004 -#define OID_CO_DELETE_ADDRESS 0xFF000005 -#define OID_CO_GET_ADDRESSES 0xFF000006 -#define OID_CO_ADDRESS_CHANGE 0xFF000007 -#define OID_CO_SIGNALING_ENABLED 0xFF000008 -#define OID_CO_SIGNALING_DISABLED 0xFF000009 -// -// 802.3 Objects (Ethernet) -// -#define OID_802_3_PERMANENT_ADDRESS 0x01010101 -#define OID_802_3_CURRENT_ADDRESS 0x01010102 -#define OID_802_3_MULTICAST_LIST 0x01010103 -#define OID_802_3_MAXIMUM_LIST_SIZE 0x01010104 -#define OID_802_3_MAC_OPTIONS 0x01010105 -// -// -#define NDIS_802_3_MAC_OPTION_PRIORITY 0x00000001 -#define OID_802_3_RCV_ERROR_ALIGNMENT 0x01020101 -#define OID_802_3_XMIT_ONE_COLLISION 0x01020102 -#define OID_802_3_XMIT_MORE_COLLISIONS 0x01020103 -#define OID_802_3_XMIT_DEFERRED 0x01020201 -#define OID_802_3_XMIT_MAX_COLLISIONS 0x01020202 -#define OID_802_3_RCV_OVERRUN 0x01020203 -#define OID_802_3_XMIT_UNDERRUN 0x01020204 -#define OID_802_3_XMIT_HEARTBEAT_FAILURE 0x01020205 -#define OID_802_3_XMIT_TIMES_CRS_LOST 0x01020206 -#define OID_802_3_XMIT_LATE_COLLISIONS 0x01020207 -// -// 802.5 Objects (Token-Ring) -// -#define OID_802_5_PERMANENT_ADDRESS 0x02010101 -#define OID_802_5_CURRENT_ADDRESS 0x02010102 -#define OID_802_5_CURRENT_FUNCTIONAL 0x02010103 -#define OID_802_5_CURRENT_GROUP 0x02010104 -#define OID_802_5_LAST_OPEN_STATUS 0x02010105 -#define OID_802_5_CURRENT_RING_STATUS 0x02010106 -#define OID_802_5_CURRENT_RING_STATE 0x02010107 -#define OID_802_5_LINE_ERRORS 0x02020101 -#define OID_802_5_LOST_FRAMES 0x02020102 -#define OID_802_5_BURST_ERRORS 0x02020201 -#define OID_802_5_AC_ERRORS 0x02020202 -#define OID_802_5_ABORT_DELIMETERS 0x02020203 -#define OID_802_5_FRAME_COPIED_ERRORS 0x02020204 -#define OID_802_5_FREQUENCY_ERRORS 0x02020205 -#define OID_802_5_TOKEN_ERRORS 0x02020206 -#define OID_802_5_INTERNAL_ERRORS 0x02020207 -// -// FDDI Objects -// -#define OID_FDDI_LONG_PERMANENT_ADDR 0x03010101 -#define OID_FDDI_LONG_CURRENT_ADDR 0x03010102 -#define OID_FDDI_LONG_MULTICAST_LIST 0x03010103 -#define OID_FDDI_LONG_MAX_LIST_SIZE 0x03010104 -#define OID_FDDI_SHORT_PERMANENT_ADDR 0x03010105 -#define OID_FDDI_SHORT_CURRENT_ADDR 0x03010106 -#define OID_FDDI_SHORT_MULTICAST_LIST 0x03010107 -#define OID_FDDI_SHORT_MAX_LIST_SIZE 0x03010108 -#define OID_FDDI_ATTACHMENT_TYPE 0x03020101 -#define OID_FDDI_UPSTREAM_NODE_LONG 0x03020102 -#define OID_FDDI_DOWNSTREAM_NODE_LONG 0x03020103 -#define OID_FDDI_FRAME_ERRORS 0x03020104 -#define OID_FDDI_FRAMES_LOST 0x03020105 -#define OID_FDDI_RING_MGT_STATE 0x03020106 -#define OID_FDDI_LCT_FAILURES 0x03020107 -#define OID_FDDI_LEM_REJECTS 0x03020108 -#define OID_FDDI_LCONNECTION_STATE 0x03020109 -#define OID_FDDI_SMT_STATION_ID 0x03030201 -#define OID_FDDI_SMT_OP_VERSION_ID 0x03030202 -#define OID_FDDI_SMT_HI_VERSION_ID 0x03030203 -#define OID_FDDI_SMT_LO_VERSION_ID 0x03030204 -#define OID_FDDI_SMT_MANUFACTURER_DATA 0x03030205 -#define OID_FDDI_SMT_USER_DATA 0x03030206 -#define OID_FDDI_SMT_MIB_VERSION_ID 0x03030207 -#define OID_FDDI_SMT_MAC_CT 0x03030208 -#define OID_FDDI_SMT_NON_MASTER_CT 0x03030209 -#define OID_FDDI_SMT_MASTER_CT 0x0303020A -#define OID_FDDI_SMT_AVAILABLE_PATHS 0x0303020B -#define OID_FDDI_SMT_CONFIG_CAPABILITIES 0x0303020C -#define OID_FDDI_SMT_CONFIG_POLICY 0x0303020D -#define OID_FDDI_SMT_CONNECTION_POLICY 0x0303020E -#define OID_FDDI_SMT_T_NOTIFY 0x0303020F -#define OID_FDDI_SMT_STAT_RPT_POLICY 0x03030210 -#define OID_FDDI_SMT_TRACE_MAX_EXPIRATION 0x03030211 -#define OID_FDDI_SMT_PORT_INDEXES 0x03030212 -#define OID_FDDI_SMT_MAC_INDEXES 0x03030213 -#define OID_FDDI_SMT_BYPASS_PRESENT 0x03030214 -#define OID_FDDI_SMT_ECM_STATE 0x03030215 -#define OID_FDDI_SMT_CF_STATE 0x03030216 -#define OID_FDDI_SMT_HOLD_STATE 0x03030217 -#define OID_FDDI_SMT_REMOTE_DISCONNECT_FLAG 0x03030218 -#define OID_FDDI_SMT_STATION_STATUS 0x03030219 -#define OID_FDDI_SMT_PEER_WRAP_FLAG 0x0303021A -#define OID_FDDI_SMT_MSG_TIME_STAMP 0x0303021B -#define OID_FDDI_SMT_TRANSITION_TIME_STAMP 0x0303021C -#define OID_FDDI_SMT_SET_COUNT 0x0303021D -#define OID_FDDI_SMT_LAST_SET_STATION_ID 0x0303021E -#define OID_FDDI_MAC_FRAME_STATUS_FUNCTIONS 0x0303021F -#define OID_FDDI_MAC_BRIDGE_FUNCTIONS 0x03030220 -#define OID_FDDI_MAC_T_MAX_CAPABILITY 0x03030221 -#define OID_FDDI_MAC_TVX_CAPABILITY 0x03030222 -#define OID_FDDI_MAC_AVAILABLE_PATHS 0x03030223 -#define OID_FDDI_MAC_CURRENT_PATH 0x03030224 -#define OID_FDDI_MAC_UPSTREAM_NBR 0x03030225 -#define OID_FDDI_MAC_DOWNSTREAM_NBR 0x03030226 -#define OID_FDDI_MAC_OLD_UPSTREAM_NBR 0x03030227 -#define OID_FDDI_MAC_OLD_DOWNSTREAM_NBR 0x03030228 -#define OID_FDDI_MAC_DUP_ADDRESS_TEST 0x03030229 -#define OID_FDDI_MAC_REQUESTED_PATHS 0x0303022A -#define OID_FDDI_MAC_DOWNSTREAM_PORT_TYPE 0x0303022B -#define OID_FDDI_MAC_INDEX 0x0303022C -#define OID_FDDI_MAC_SMT_ADDRESS 0x0303022D -#define OID_FDDI_MAC_LONG_GRP_ADDRESS 0x0303022E -#define OID_FDDI_MAC_SHORT_GRP_ADDRESS 0x0303022F -#define OID_FDDI_MAC_T_REQ 0x03030230 -#define OID_FDDI_MAC_T_NEG 0x03030231 -#define OID_FDDI_MAC_T_MAX 0x03030232 -#define OID_FDDI_MAC_TVX_VALUE 0x03030233 -#define OID_FDDI_MAC_T_PRI0 0x03030234 -#define OID_FDDI_MAC_T_PRI1 0x03030235 -#define OID_FDDI_MAC_T_PRI2 0x03030236 -#define OID_FDDI_MAC_T_PRI3 0x03030237 -#define OID_FDDI_MAC_T_PRI4 0x03030238 -#define OID_FDDI_MAC_T_PRI5 0x03030239 -#define OID_FDDI_MAC_T_PRI6 0x0303023A -#define OID_FDDI_MAC_FRAME_CT 0x0303023B -#define OID_FDDI_MAC_COPIED_CT 0x0303023C -#define OID_FDDI_MAC_TRANSMIT_CT 0x0303023D -#define OID_FDDI_MAC_TOKEN_CT 0x0303023E -#define OID_FDDI_MAC_ERROR_CT 0x0303023F -#define OID_FDDI_MAC_LOST_CT 0x03030240 -#define OID_FDDI_MAC_TVX_EXPIRED_CT 0x03030241 -#define OID_FDDI_MAC_NOT_COPIED_CT 0x03030242 -#define OID_FDDI_MAC_LATE_CT 0x03030243 -#define OID_FDDI_MAC_RING_OP_CT 0x03030244 -#define OID_FDDI_MAC_FRAME_ERROR_THRESHOLD 0x03030245 -#define OID_FDDI_MAC_FRAME_ERROR_RATIO 0x03030246 -#define OID_FDDI_MAC_NOT_COPIED_THRESHOLD 0x03030247 -#define OID_FDDI_MAC_NOT_COPIED_RATIO 0x03030248 -#define OID_FDDI_MAC_RMT_STATE 0x03030249 -#define OID_FDDI_MAC_DA_FLAG 0x0303024A -#define OID_FDDI_MAC_UNDA_FLAG 0x0303024B -#define OID_FDDI_MAC_FRAME_ERROR_FLAG 0x0303024C -#define OID_FDDI_MAC_NOT_COPIED_FLAG 0x0303024D -#define OID_FDDI_MAC_MA_UNITDATA_AVAILABLE 0x0303024E -#define OID_FDDI_MAC_HARDWARE_PRESENT 0x0303024F -#define OID_FDDI_MAC_MA_UNITDATA_ENABLE 0x03030250 -#define OID_FDDI_PATH_INDEX 0x03030251 -#define OID_FDDI_PATH_RING_LATENCY 0x03030252 -#define OID_FDDI_PATH_TRACE_STATUS 0x03030253 -#define OID_FDDI_PATH_SBA_PAYLOAD 0x03030254 -#define OID_FDDI_PATH_SBA_OVERHEAD 0x03030255 -#define OID_FDDI_PATH_CONFIGURATION 0x03030256 -#define OID_FDDI_PATH_T_R_MODE 0x03030257 -#define OID_FDDI_PATH_SBA_AVAILABLE 0x03030258 -#define OID_FDDI_PATH_TVX_LOWER_BOUND 0x03030259 -#define OID_FDDI_PATH_T_MAX_LOWER_BOUND 0x0303025A -#define OID_FDDI_PATH_MAX_T_REQ 0x0303025B -#define OID_FDDI_PORT_MY_TYPE 0x0303025C -#define OID_FDDI_PORT_NEIGHBOR_TYPE 0x0303025D -#define OID_FDDI_PORT_CONNECTION_POLICIES 0x0303025E -#define OID_FDDI_PORT_MAC_INDICATED 0x0303025F -#define OID_FDDI_PORT_CURRENT_PATH 0x03030260 -#define OID_FDDI_PORT_REQUESTED_PATHS 0x03030261 -#define OID_FDDI_PORT_MAC_PLACEMENT 0x03030262 -#define OID_FDDI_PORT_AVAILABLE_PATHS 0x03030263 -#define OID_FDDI_PORT_MAC_LOOP_TIME 0x03030264 -#define OID_FDDI_PORT_PMD_CLASS 0x03030265 -#define OID_FDDI_PORT_CONNECTION_CAPABILITIES 0x03030266 -#define OID_FDDI_PORT_INDEX 0x03030267 -#define OID_FDDI_PORT_MAINT_LS 0x03030268 -#define OID_FDDI_PORT_BS_FLAG 0x03030269 -#define OID_FDDI_PORT_PC_LS 0x0303026A -#define OID_FDDI_PORT_EB_ERROR_CT 0x0303026B -#define OID_FDDI_PORT_LCT_FAIL_CT 0x0303026C -#define OID_FDDI_PORT_LER_ESTIMATE 0x0303026D -#define OID_FDDI_PORT_LEM_REJECT_CT 0x0303026E -#define OID_FDDI_PORT_LEM_CT 0x0303026F -#define OID_FDDI_PORT_LER_CUTOFF 0x03030270 -#define OID_FDDI_PORT_LER_ALARM 0x03030271 -#define OID_FDDI_PORT_CONNNECT_STATE 0x03030272 -#define OID_FDDI_PORT_PCM_STATE 0x03030273 -#define OID_FDDI_PORT_PC_WITHHOLD 0x03030274 -#define OID_FDDI_PORT_LER_FLAG 0x03030275 -#define OID_FDDI_PORT_HARDWARE_PRESENT 0x03030276 -#define OID_FDDI_SMT_STATION_ACTION 0x03030277 -#define OID_FDDI_PORT_ACTION 0x03030278 -#define OID_FDDI_IF_DESCR 0x03030279 -#define OID_FDDI_IF_TYPE 0x0303027A -#define OID_FDDI_IF_MTU 0x0303027B -#define OID_FDDI_IF_SPEED 0x0303027C -#define OID_FDDI_IF_PHYS_ADDRESS 0x0303027D -#define OID_FDDI_IF_ADMIN_STATUS 0x0303027E -#define OID_FDDI_IF_OPER_STATUS 0x0303027F -#define OID_FDDI_IF_LAST_CHANGE 0x03030280 -#define OID_FDDI_IF_IN_OCTETS 0x03030281 -#define OID_FDDI_IF_IN_UCAST_PKTS 0x03030282 -#define OID_FDDI_IF_IN_NUCAST_PKTS 0x03030283 -#define OID_FDDI_IF_IN_DISCARDS 0x03030284 -#define OID_FDDI_IF_IN_ERRORS 0x03030285 -#define OID_FDDI_IF_IN_UNKNOWN_PROTOS 0x03030286 -#define OID_FDDI_IF_OUT_OCTETS 0x03030287 -#define OID_FDDI_IF_OUT_UCAST_PKTS 0x03030288 -#define OID_FDDI_IF_OUT_NUCAST_PKTS 0x03030289 -#define OID_FDDI_IF_OUT_DISCARDS 0x0303028A -#define OID_FDDI_IF_OUT_ERRORS 0x0303028B -#define OID_FDDI_IF_OUT_QLEN 0x0303028C -#define OID_FDDI_IF_SPECIFIC 0x0303028D -// -// WAN objects -// -#define OID_WAN_PERMANENT_ADDRESS 0x04010101 -#define OID_WAN_CURRENT_ADDRESS 0x04010102 -#define OID_WAN_QUALITY_OF_SERVICE 0x04010103 -#define OID_WAN_PROTOCOL_TYPE 0x04010104 -#define OID_WAN_MEDIUM_SUBTYPE 0x04010105 -#define OID_WAN_HEADER_FORMAT 0x04010106 -#define OID_WAN_GET_INFO 0x04010107 -#define OID_WAN_SET_LINK_INFO 0x04010108 -#define OID_WAN_GET_LINK_INFO 0x04010109 -#define OID_WAN_LINE_COUNT 0x0401010A -#define OID_WAN_GET_BRIDGE_INFO 0x0401020A -#define OID_WAN_SET_BRIDGE_INFO 0x0401020B -#define OID_WAN_GET_COMP_INFO 0x0401020C -#define OID_WAN_SET_COMP_INFO 0x0401020D -#define OID_WAN_GET_STATS_INFO 0x0401020E -// -// LocalTalk objects -// -#define OID_LTALK_CURRENT_NODE_ID 0x05010102 -#define OID_LTALK_IN_BROADCASTS 0x05020101 -#define OID_LTALK_IN_LENGTH_ERRORS 0x05020102 -#define OID_LTALK_OUT_NO_HANDLERS 0x05020201 -#define OID_LTALK_COLLISIONS 0x05020202 -#define OID_LTALK_DEFERS 0x05020203 -#define OID_LTALK_NO_DATA_ERRORS 0x05020204 -#define OID_LTALK_RANDOM_CTS_ERRORS 0x05020205 -#define OID_LTALK_FCS_ERRORS 0x05020206 -// -// Arcnet objects -// -#define OID_ARCNET_PERMANENT_ADDRESS 0x06010101 -#define OID_ARCNET_CURRENT_ADDRESS 0x06010102 -#define OID_ARCNET_RECONFIGURATIONS 0x06020201 -// -// TAPI objects -// -#define OID_TAPI_ACCEPT 0x07030101 -#define OID_TAPI_ANSWER 0x07030102 -#define OID_TAPI_CLOSE 0x07030103 -#define OID_TAPI_CLOSE_CALL 0x07030104 -#define OID_TAPI_CONDITIONAL_MEDIA_DETECTION 0x07030105 -#define OID_TAPI_CONFIG_DIALOG 0x07030106 -#define OID_TAPI_DEV_SPECIFIC 0x07030107 -#define OID_TAPI_DIAL 0x07030108 -#define OID_TAPI_DROP 0x07030109 -#define OID_TAPI_GET_ADDRESS_CAPS 0x0703010A -#define OID_TAPI_GET_ADDRESS_ID 0x0703010B -#define OID_TAPI_GET_ADDRESS_STATUS 0x0703010C -#define OID_TAPI_GET_CALL_ADDRESS_ID 0x0703010D -#define OID_TAPI_GET_CALL_INFO 0x0703010E -#define OID_TAPI_GET_CALL_STATUS 0x0703010F -#define OID_TAPI_GET_DEV_CAPS 0x07030110 -#define OID_TAPI_GET_DEV_CONFIG 0x07030111 -#define OID_TAPI_GET_EXTENSION_ID 0x07030112 -#define OID_TAPI_GET_ID 0x07030113 -#define OID_TAPI_GET_LINE_DEV_STATUS 0x07030114 -#define OID_TAPI_MAKE_CALL 0x07030115 -#define OID_TAPI_NEGOTIATE_EXT_VERSION 0x07030116 -#define OID_TAPI_OPEN 0x07030117 -#define OID_TAPI_PROVIDER_INITIALIZE 0x07030118 -#define OID_TAPI_PROVIDER_SHUTDOWN 0x07030119 -#define OID_TAPI_SECURE_CALL 0x0703011A -#define OID_TAPI_SELECT_EXT_VERSION 0x0703011B -#define OID_TAPI_SEND_USER_USER_INFO 0x0703011C -#define OID_TAPI_SET_APP_SPECIFIC 0x0703011D -#define OID_TAPI_SET_CALL_PARAMS 0x0703011E -#define OID_TAPI_SET_DEFAULT_MEDIA_DETECTION 0x0703011F -#define OID_TAPI_SET_DEV_CONFIG 0x07030120 -#define OID_TAPI_SET_MEDIA_MODE 0x07030121 -#define OID_TAPI_SET_STATUS_MESSAGES 0x07030122 -// -// ATM Connection Oriented Ndis -// -#define OID_ATM_SUPPORTED_VC_RATES 0x08010101 -#define OID_ATM_SUPPORTED_SERVICE_CATEGORY 0x08010102 -#define OID_ATM_SUPPORTED_AAL_TYPES 0x08010103 -#define OID_ATM_HW_CURRENT_ADDRESS 0x08010104 -#define OID_ATM_MAX_ACTIVE_VCS 0x08010105 -#define OID_ATM_MAX_ACTIVE_VCI_BITS 0x08010106 -#define OID_ATM_MAX_ACTIVE_VPI_BITS 0x08010107 -#define OID_ATM_MAX_AAL0_PACKET_SIZE 0x08010108 -#define OID_ATM_MAX_AAL1_PACKET_SIZE 0x08010109 -#define OID_ATM_MAX_AAL34_PACKET_SIZE 0x0801010A -#define OID_ATM_MAX_AAL5_PACKET_SIZE 0x0801010B -#define OID_ATM_SIGNALING_VPIVCI 0x08010201 -#define OID_ATM_ASSIGNED_VPI 0x08010202 -#define OID_ATM_ACQUIRE_ACCESS_NET_RESOURCES 0x08010203 -#define OID_ATM_RELEASE_ACCESS_NET_RESOURCES 0x08010204 -#define OID_ATM_ILMI_VPIVCI 0x08010205 -#define OID_ATM_DIGITAL_BROADCAST_VPIVCI 0x08010206 -#define OID_ATM_GET_NEAREST_FLOW 0x08010207 -#define OID_ATM_ALIGNMENT_REQUIRED 0x08010208 -// -// ATM specific statistics OIDs. -// -#define OID_ATM_RCV_CELLS_OK 0x08020101 -#define OID_ATM_XMIT_CELLS_OK 0x08020102 -#define OID_ATM_RCV_CELLS_DROPPED 0x08020103 -#define OID_ATM_RCV_INVALID_VPI_VCI 0x08020201 -#define OID_ATM_CELLS_HEC_ERROR 0x08020202 -#define OID_ATM_RCV_REASSEMBLY_ERROR 0x08020203 -// -// PCCA (Wireless) object -// -// -// All WirelessWAN devices must support the following OIDs -// -#define OID_WW_GEN_NETWORK_TYPES_SUPPORTED 0x09010101 -#define OID_WW_GEN_NETWORK_TYPE_IN_USE 0x09010102 -#define OID_WW_GEN_HEADER_FORMATS_SUPPORTED 0x09010103 -#define OID_WW_GEN_HEADER_FORMAT_IN_USE 0x09010104 -#define OID_WW_GEN_INDICATION_REQUEST 0x09010105 -#define OID_WW_GEN_DEVICE_INFO 0x09010106 -#define OID_WW_GEN_OPERATION_MODE 0x09010107 -#define OID_WW_GEN_LOCK_STATUS 0x09010108 -#define OID_WW_GEN_DISABLE_TRANSMITTER 0x09010109 -#define OID_WW_GEN_NETWORK_ID 0x0901010A -#define OID_WW_GEN_PERMANENT_ADDRESS 0x0901010B -#define OID_WW_GEN_CURRENT_ADDRESS 0x0901010C -#define OID_WW_GEN_SUSPEND_DRIVER 0x0901010D -#define OID_WW_GEN_BASESTATION_ID 0x0901010E -#define OID_WW_GEN_CHANNEL_ID 0x0901010F -#define OID_WW_GEN_ENCRYPTION_SUPPORTED 0x09010110 -#define OID_WW_GEN_ENCRYPTION_IN_USE 0x09010111 -#define OID_WW_GEN_ENCRYPTION_STATE 0x09010112 -#define OID_WW_GEN_CHANNEL_QUALITY 0x09010113 -#define OID_WW_GEN_REGISTRATION_STATUS 0x09010114 -#define OID_WW_GEN_RADIO_LINK_SPEED 0x09010115 -#define OID_WW_GEN_LATENCY 0x09010116 -#define OID_WW_GEN_BATTERY_LEVEL 0x09010117 -#define OID_WW_GEN_EXTERNAL_POWER 0x09010118 -// -// Network Dependent OIDs - Mobitex: -// -#define OID_WW_MBX_SUBADDR 0x09050101 -// OID 0x09050102 is reserved and may not be used -#define OID_WW_MBX_FLEXLIST 0x09050103 -#define OID_WW_MBX_GROUPLIST 0x09050104 -#define OID_WW_MBX_TRAFFIC_AREA 0x09050105 -#define OID_WW_MBX_LIVE_DIE 0x09050106 -#define OID_WW_MBX_TEMP_DEFAULTLIST 0x09050107 -// -// Network Dependent OIDs - Pinpoint: -// -#define OID_WW_PIN_LOC_AUTHORIZE 0x09090101 -#define OID_WW_PIN_LAST_LOCATION 0x09090102 -#define OID_WW_PIN_LOC_FIX 0x09090103 -// -// Network Dependent - CDPD: -// -#define OID_WW_CDPD_SPNI 0x090D0101 -#define OID_WW_CDPD_WASI 0x090D0102 -#define OID_WW_CDPD_AREA_COLOR 0x090D0103 -#define OID_WW_CDPD_TX_POWER_LEVEL 0x090D0104 -#define OID_WW_CDPD_EID 0x090D0105 -#define OID_WW_CDPD_HEADER_COMPRESSION 0x090D0106 -#define OID_WW_CDPD_DATA_COMPRESSION 0x090D0107 -#define OID_WW_CDPD_CHANNEL_SELECT 0x090D0108 -#define OID_WW_CDPD_CHANNEL_STATE 0x090D0109 -#define OID_WW_CDPD_NEI 0x090D010A -#define OID_WW_CDPD_NEI_STATE 0x090D010B -#define OID_WW_CDPD_SERVICE_PROVIDER_IDENTIFIER 0x090D010C -#define OID_WW_CDPD_SLEEP_MODE 0x090D010D -#define OID_WW_CDPD_CIRCUIT_SWITCHED 0x090D010E -#define OID_WW_CDPD_TEI 0x090D010F -#define OID_WW_CDPD_RSSI 0x090D0110 -// -// Network Dependent - Ardis: -// -#define OID_WW_ARD_SNDCP 0x09110101 -#define OID_WW_ARD_TMLY_MSG 0x09110102 -#define OID_WW_ARD_DATAGRAM 0x09110103 -// -// Network Dependent - DataTac: -// -#define OID_WW_TAC_COMPRESSION 0x09150101 -#define OID_WW_TAC_SET_CONFIG 0x09150102 -#define OID_WW_TAC_GET_STATUS 0x09150103 -#define OID_WW_TAC_USER_HEADER 0x09150104 -// -// Network Dependent - Metricom: -// -#define OID_WW_MET_FUNCTION 0x09190101 -// -// IRDA objects -// -#define OID_IRDA_RECEIVING 0x0A010100 -#define OID_IRDA_TURNAROUND_TIME 0x0A010101 -#define OID_IRDA_SUPPORTED_SPEEDS 0x0A010102 -#define OID_IRDA_LINK_SPEED 0x0A010103 -#define OID_IRDA_MEDIA_BUSY 0x0A010104 -#define OID_IRDA_EXTRA_RCV_BOFS 0x0A010200 -#define OID_IRDA_RATE_SNIFF 0x0A010201 -#define OID_IRDA_UNICAST_LIST 0x0A010202 -#define OID_IRDA_MAX_UNICAST_LIST_SIZE 0x0A010203 -#define OID_IRDA_MAX_RECEIVE_WINDOW_SIZE 0x0A010204 -#define OID_IRDA_MAX_SEND_WINDOW_SIZE 0x0A010205 -// -// Medium the Ndis Driver is running on (OID_GEN_MEDIA_SUPPORTED/ -// OID_GEN_MEDIA_IN_USE). -// -typedef enum _NDIS_MEDIUM { - NdisMedium802_3, - NdisMedium802_5, - NdisMediumFddi, - NdisMediumWan, - NdisMediumLocalTalk, - NdisMediumDix, // defined for convenience, not a real medium - NdisMediumArcnetRaw, - NdisMediumArcnet878_2, - NdisMediumAtm, - NdisMediumWirelessWan, - NdisMediumIrda, - NdisMediumMax // Not a real medium, defined as an upper-bound -} NDIS_MEDIUM, *PNDIS_MEDIUM; - -// -// Hardware status codes (OID_GEN_HARDWARE_STATUS). -// -typedef enum _NDIS_HARDWARE_STATUS { - NdisHardwareStatusReady, - NdisHardwareStatusInitializing, - NdisHardwareStatusReset, - NdisHardwareStatusClosing, - NdisHardwareStatusNotReady -} NDIS_HARDWARE_STATUS, *PNDIS_HARDWARE_STATUS; - -// -// this is the type passed in the OID_GEN_GET_TIME_CAPS request -// -typedef struct _GEN_GET_TIME_CAPS { - ULONG Flags; // Bits defined below - - ULONG ClockPrecision; -} GEN_GET_TIME_CAPS, *PGEN_GET_TIME_CAPS; - -#define READABLE_LOCAL_CLOCK 0x000000001 -#define CLOCK_NETWORK_DERIVED 0x000000002 -#define CLOCK_PRECISION 0x000000004 -#define RECEIVE_TIME_INDICATION_CAPABLE 0x000000008 -#define TIMED_SEND_CAPABLE 0x000000010 -#define TIME_STAMP_CAPABLE 0x000000020 -// -// -// this is the type passed in the OID_GEN_GET_NETCARD_TIME request -// -typedef struct _GEN_GET_NETCARD_TIME { - ULONG ReadTime; -} GEN_GET_NETCARD_TIME, *PGEN_GET_NETCARD_TIME; - -// -// Defines the attachment types for FDDI (OID_FDDI_ATTACHMENT_TYPE). -// -typedef enum _NDIS_FDDI_ATTACHMENT_TYPE { - NdisFddiTypeIsolated = 1, - NdisFddiTypeLocalA, - NdisFddiTypeLocalB, - NdisFddiTypeLocalAB, - NdisFddiTypeLocalS, - NdisFddiTypeWrapA, - NdisFddiTypeWrapB, - NdisFddiTypeWrapAB, - NdisFddiTypeWrapS, - NdisFddiTypeCWrapA, - NdisFddiTypeCWrapB, - NdisFddiTypeCWrapS, - NdisFddiTypeThrough -} NDIS_FDDI_ATTACHMENT_TYPE, *PNDIS_FDDI_ATTACHMENT_TYPE; - -// -// Defines the ring management states for FDDI (OID_FDDI_RING_MGT_STATE). -// -typedef enum _NDIS_FDDI_RING_MGT_STATE { - NdisFddiRingIsolated = 1, - NdisFddiRingNonOperational, - NdisFddiRingOperational, - NdisFddiRingDetect, - NdisFddiRingNonOperationalDup, - NdisFddiRingOperationalDup, - NdisFddiRingDirected, - NdisFddiRingTrace -} NDIS_FDDI_RING_MGT_STATE, *PNDIS_FDDI_RING_MGT_STATE; - -// -// Defines the Lconnection state for FDDI (OID_FDDI_LCONNECTION_STATE). -// -typedef enum _NDIS_FDDI_LCONNECTION_STATE { - NdisFddiStateOff = 1, - NdisFddiStateBreak, - NdisFddiStateTrace, - NdisFddiStateConnect, - NdisFddiStateNext, - NdisFddiStateSignal, - NdisFddiStateJoin, - NdisFddiStateVerify, - NdisFddiStateActive, - NdisFddiStateMaintenance -} NDIS_FDDI_LCONNECTION_STATE, *PNDIS_FDDI_LCONNECTION_STATE; - -// -// Defines the medium subtypes for WAN medium (OID_WAN_MEDIUM_SUBTYPE). -// -typedef enum _NDIS_WAN_MEDIUM_SUBTYPE { - NdisWanMediumHub, - NdisWanMediumX_25, - NdisWanMediumIsdn, - NdisWanMediumSerial, - NdisWanMediumFrameRelay, - NdisWanMediumAtm, - NdisWanMediumSonet, - NdisWanMediumSW56K -} NDIS_WAN_MEDIUM_SUBTYPE, *PNDIS_WAN_MEDIUM_SUBTYPE; - -// -// Defines the header format for WAN medium (OID_WAN_HEADER_FORMAT). -// -typedef enum _NDIS_WAN_HEADER_FORMAT { - NdisWanHeaderNative, // src/dest based on subtype, followed by NLPID - NdisWanHeaderEthernet // emulation of ethernet header -} NDIS_WAN_HEADER_FORMAT, *PNDIS_WAN_HEADER_FORMAT; - -// -// Defines the line quality on a WAN line (OID_WAN_QUALITY_OF_SERVICE). -// -typedef enum _NDIS_WAN_QUALITY { - NdisWanRaw, - NdisWanErrorControl, - NdisWanReliable -} NDIS_WAN_QUALITY, *PNDIS_WAN_QUALITY; - -// -// Defines the state of a token-ring adapter (OID_802_5_CURRENT_RING_STATE). -// -typedef enum _NDIS_802_5_RING_STATE { - NdisRingStateOpened = 1, - NdisRingStateClosed, - NdisRingStateOpening, - NdisRingStateClosing, - NdisRingStateOpenFailure, - NdisRingStateRingFailure -} NDIS_802_5_RING_STATE, *PNDIS_802_5_RING_STATE; - -// -// Defines the state of the LAN media -// -typedef enum _NDIS_MEDIA_STATE { - NdisMediaStateConnected, - NdisMediaStateDisconnected -} NDIS_MEDIA_STATE, *PNDIS_MEDIA_STATE; - -// -// The following is set on a per-packet basis as OOB data with NdisClass802_3Priority -// -typedef ULONG Priority_802_3; // 0-7 priority levels -// -// The following structure is used to query OID_GEN_CO_LINK_SPEED and -// OID_GEN_CO_MINIMUM_LINK_SPEED. The first OID will return the current -// link speed of the adapter. The second will return the minimum link speed -// the adapter is capable of. -// - -typedef struct _NDIS_CO_LINK_SPEED { - ULONG Outbound; - ULONG Inbound; -} NDIS_CO_LINK_SPEED, - -*PNDIS_CO_LINK_SPEED; -// -// Ndis Packet Filter Bits (OID_GEN_CURRENT_PACKET_FILTER). -// -#define NDIS_PACKET_TYPE_DIRECTED 0x0001 -#define NDIS_PACKET_TYPE_MULTICAST 0x0002 -#define NDIS_PACKET_TYPE_ALL_MULTICAST 0x0004 -#define NDIS_PACKET_TYPE_BROADCAST 0x0008 -#define NDIS_PACKET_TYPE_SOURCE_ROUTING 0x0010 -#define NDIS_PACKET_TYPE_PROMISCUOUS 0x0020 -#define NDIS_PACKET_TYPE_SMT 0x0040 -#define NDIS_PACKET_TYPE_ALL_LOCAL 0x0080 -#define NDIS_PACKET_TYPE_MAC_FRAME 0x8000 -#define NDIS_PACKET_TYPE_FUNCTIONAL 0x4000 -#define NDIS_PACKET_TYPE_ALL_FUNCTIONAL 0x2000 -#define NDIS_PACKET_TYPE_GROUP 0x1000 -// -// Ndis Token-Ring Ring Status Codes (OID_802_5_CURRENT_RING_STATUS). -// -#define NDIS_RING_SIGNAL_LOSS 0x00008000 -#define NDIS_RING_HARD_ERROR 0x00004000 -#define NDIS_RING_SOFT_ERROR 0x00002000 -#define NDIS_RING_TRANSMIT_BEACON 0x00001000 -#define NDIS_RING_LOBE_WIRE_FAULT 0x00000800 -#define NDIS_RING_AUTO_REMOVAL_ERROR 0x00000400 -#define NDIS_RING_REMOVE_RECEIVED 0x00000200 -#define NDIS_RING_COUNTER_OVERFLOW 0x00000100 -#define NDIS_RING_SINGLE_STATION 0x00000080 -#define NDIS_RING_RING_RECOVERY 0x00000040 -// -// Ndis protocol option bits (OID_GEN_PROTOCOL_OPTIONS). -// -#define NDIS_PROT_OPTION_ESTIMATED_LENGTH 0x00000001 -#define NDIS_PROT_OPTION_NO_LOOPBACK 0x00000002 -#define NDIS_PROT_OPTION_NO_RSVD_ON_RCVPKT 0x00000004 -// -// Ndis MAC option bits (OID_GEN_MAC_OPTIONS). -// -#define NDIS_MAC_OPTION_COPY_LOOKAHEAD_DATA 0x00000001 -#define NDIS_MAC_OPTION_RECEIVE_SERIALIZED 0x00000002 -#define NDIS_MAC_OPTION_TRANSFERS_NOT_PEND 0x00000004 -#define NDIS_MAC_OPTION_NO_LOOPBACK 0x00000008 -#define NDIS_MAC_OPTION_FULL_DUPLEX 0x00000010 -#define NDIS_MAC_OPTION_EOTX_INDICATION 0x00000020 -#define NDIS_MAC_OPTION_RESERVED 0x80000000 -// -// NDIS MAC option bits for OID_GEN_CO_MAC_OPTIONS. -// -#define NDIS_CO_MAC_OPTION_DYNAMIC_LINK_SPEED 0x00000001 -#ifdef IRDA -// -// The following is set on a per-packet basis as OOB data with NdisClassIrdaPacketInfo -// This is the per-packet info specified on a per-packet basis -// -typedef struct _NDIS_IRDA_PACKET_INFO { - UINT ExtraBOFs; - UINT MinTurnAroundTime; -} NDIS_IRDA_PACKET_INFO, *PNDIS_IRDA_PACKET_INFO; - -#endif -#ifdef WIRELESS_WAN -// -// Wireless WAN structure definitions -// -// -// currently defined Wireless network subtypes -// -typedef enum _NDIS_WW_NETWORK_TYPE { - NdisWWGeneric, - NdisWWMobitex, - NdisWWPinpoint, - NdisWWCDPD, - NdisWWArdis, - NdisWWDataTAC, - NdisWWMetricom, - NdisWWGSM, - NdisWWCDMA, - NdisWWTDMA, - NdisWWAMPS, - NdisWWInmarsat, - NdisWWpACT -} NDIS_WW_NETWORK_TYPE; - -// -// currently defined header formats -// -typedef enum _NDIS_WW_HEADER_FORMAT { - NdisWWDIXEthernetFrames, - NdisWWMPAKFrames, - NdisWWRDLAPFrames, - NdisWWMDC4800Frames -} NDIS_WW_HEADER_FORMAT; - -// -// currently defined encryption types -// -typedef enum _NDIS_WW_ENCRYPTION_TYPE { - NdisWWUnknownEncryption = -1, - NdisWWNoEncryption, - NdisWWDefaultEncryption -} NDIS_WW_ENCRYPTION_TYPE, *PNDIS_WW_ENCRYPTION_TYPE; - -// -// OID_WW_GEN_INDICATION_REQUEST -// -typedef struct _NDIS_WW_INDICATION_REQUEST { - NDIS_OID Oid; // IN - - UINT uIndicationFlag; // IN - - UINT uApplicationToken; // IN OUT - - HANDLE hIndicationHandle; // IN OUT - - INT iPollingInterval; // IN OUT - - NDIS_VAR_DATA_DESC InitialValue; // IN OUT - - NDIS_VAR_DATA_DESC OIDIndicationValue; // OUT - only valid after indication - - NDIS_VAR_DATA_DESC TriggerValue; // IN - -} NDIS_WW_INDICATION_REQUEST, *PNDIS_WW_INDICATION_REQUEST; - -#define OID_INDICATION_REQUEST_ENABLE 0x0000 -#define OID_INDICATION_REQUEST_CANCEL 0x0001 -// -// OID_WW_GEN_DEVICE_INFO -// -typedef struct _WW_DEVICE_INFO { - NDIS_VAR_DATA_DESC Manufacturer; - NDIS_VAR_DATA_DESC ModelNum; - NDIS_VAR_DATA_DESC SWVersionNum; - NDIS_VAR_DATA_DESC SerialNum; -} WW_DEVICE_INFO, *PWW_DEVICE_INFO; - -// -// OID_WW_GEN_OPERATION_MODE -// -typedef INT WW_OPERATION_MODE; // 0 = Normal mode - // 1 = Power saving mode - // -1 = mode unknown -// -// OID_WW_GEN_LOCK_STATUS -// - -typedef INT WW_LOCK_STATUS; // 0 = unlocked - // 1 = locked - // -1 = unknown lock status -// -// OID_WW_GEN_DISABLE_TRANSMITTER -// - -typedef INT WW_DISABLE_TRANSMITTER; // 0 = transmitter enabled - // 1 = transmitter disabled - // -1 = unknown value -// -// OID_WW_GEN_NETWORK_ID -// - -typedef NDIS_VAR_DATA_DESC WW_NETWORK_ID; -// -// OID_WW_GEN_PERMANENT_ADDRESS -// -typedef NDIS_VAR_DATA_DESC WW_PERMANENT_ADDRESS; -// -// OID_WW_GEN_CURRENT_ADDRESS -// -typedef struct _WW_CURRENT_ADDRESS { - NDIS_WW_HEADER_FORMAT Format; - NDIS_VAR_DATA_DESC Address; -} WW_CURRENT_ADDRESS, *PWW_CURRENT_ADDRESS; - -// -// OID_WW_GEN_SUSPEND_DRIVER -// -typedef BOOLEAN WW_SUSPEND_DRIVER; // 0 = driver operational - // 1 = driver suspended -// -// OID_WW_GEN_BASESTATION_ID -// - -typedef NDIS_VAR_DATA_DESC WW_BASESTATION_ID; -// -// OID_WW_GEN_CHANNEL_ID -// -typedef NDIS_VAR_DATA_DESC WW_CHANNEL_ID; -// -// OID_WW_GEN_ENCRYPTION_STATE -// -typedef BOOLEAN WW_ENCRYPTION_STATE; // 0 = if encryption is disabled - // 1 = if encryption is enabled -// -// OID_WW_GEN_CHANNEL_QUALITY -// - -typedef INT WW_CHANNEL_QUALITY; // 0 = Not in network contact, - // 1-100 = Quality of Channel (100 is highest quality). - // -1 = channel quality is unknown -// -// OID_WW_GEN_REGISTRATION_STATUS -// - -typedef INT WW_REGISTRATION_STATUS; // 0 = Registration denied - // 1 = Registration pending - // 2 = Registered - // -1 = unknown registration status -// -// OID_WW_GEN_RADIO_LINK_SPEED -// - -typedef UINT WW_RADIO_LINK_SPEED; // Bits per second. -// -// OID_WW_GEN_LATENCY -// - -typedef UINT WW_LATENCY; // milliseconds -// -// OID_WW_GEN_BATTERY_LEVEL -// - -typedef INT WW_BATTERY_LEVEL; // 0-100 = battery level in percentage - // (100=fully charged) - // -1 = unknown battery level. -// -// OID_WW_GEN_EXTERNAL_POWER -// - -typedef INT WW_EXTERNAL_POWER; // 0 = no external power connected - // 1 = external power connected - // -1 = unknown -// -// OID_WW_MET_FUNCTION -// - -typedef NDIS_VAR_DATA_DESC WW_MET_FUNCTION; -// -// OID_WW_TAC_COMPRESSION -// -typedef BOOLEAN WW_TAC_COMPRESSION; // Determines whether or not network level compression - // is being used. -// -// OID_WW_TAC_SET_CONFIG -// - -typedef struct _WW_TAC_SETCONFIG { - NDIS_VAR_DATA_DESC RCV_MODE; - NDIS_VAR_DATA_DESC TX_CONTROL; - NDIS_VAR_DATA_DESC RX_CONTROL; - NDIS_VAR_DATA_DESC FLOW_CONTROL; - NDIS_VAR_DATA_DESC RESET_CNF; - NDIS_VAR_DATA_DESC READ_CNF; -} WW_TAC_SETCONFIG, *PWW_TAC_SETCONFIG; - -// -// OID_WW_TAC_GET_STATUS -// -typedef struct _WW_TAC_GETSTATUS { - BOOLEAN Action; // Set = Execute command. - - NDIS_VAR_DATA_DESC Command; - NDIS_VAR_DATA_DESC Option; - NDIS_VAR_DATA_DESC Response; // The response to the requested command - // - max. length of string is 256 octets. - -} WW_TAC_GETSTATUS, *PWW_TAC_GETSTATUS; - -// -// OID_WW_TAC_USER_HEADER -// -typedef NDIS_VAR_DATA_DESC WW_TAC_USERHEADER; // This will hold the user header - Max. 64 octets. -// -// OID_WW_ARD_SNDCP -// - -typedef struct _WW_ARD_SNDCP { - NDIS_VAR_DATA_DESC Version; // The version of SNDCP protocol supported. - - INT BlockSize; // The block size used for SNDCP - - INT Window; // The window size used in SNDCP - -} WW_ARD_SNDCP, *PWW_ARD_SNDCP; - -// -// OID_WW_ARD_TMLY_MSG -// -typedef BOOLEAN WW_ARD_CHANNEL_STATUS; // The current status of the inbound RF Channel. -// -// OID_WW_ARD_DATAGRAM -// - -typedef struct _WW_ARD_DATAGRAM { - BOOLEAN LoadLevel; // Byte that contains the load level info. - - INT SessionTime; // Datagram session time remaining. - - NDIS_VAR_DATA_DESC HostAddr; // Host address. - - NDIS_VAR_DATA_DESC THostAddr; // Test host address. - -} WW_ARD_DATAGRAM, *PWW_ARD_DATAGRAM; - -// -// OID_WW_CDPD_SPNI -// -typedef struct _WW_CDPD_SPNI { - UINT SPNI[10]; //10 16-bit service provider network IDs - - INT OperatingMode; // 0 = ignore SPNI, - // 1 = require SPNI from list, - // 2 = prefer SPNI from list. - // 3 = exclude SPNI from list. - -} WW_CDPD_SPNI, *PWW_CDPD_SPNI; - -// -// OID_WW_CDPD_WASI -// -typedef struct _WW_CDPD_WIDE_AREA_SERVICE_ID { - UINT WASI[10]; //10 16-bit wide area service IDs - - INT OperatingMode; // 0 = ignore WASI, - // 1 = Require WASI from list, - // 2 = prefer WASI from list - // 3 = exclude WASI from list. - -} WW_CDPD_WIDE_AREA_SERVICE_ID, *PWW_CDPD_WIDE_AREA_SERVICE_ID; - -// -// OID_WW_CDPD_AREA_COLOR -// -typedef INT WW_CDPD_AREA_COLOR; -// -// OID_WW_CDPD_TX_POWER_LEVEL -// -typedef UINT WW_CDPD_TX_POWER_LEVEL; -// -// OID_WW_CDPD_EID -// -typedef NDIS_VAR_DATA_DESC WW_CDPD_EID; -// -// OID_WW_CDPD_HEADER_COMPRESSION -// -typedef INT WW_CDPD_HEADER_COMPRESSION; // 0 = no header compression, - // 1 = always compress headers, - // 2 = compress headers if MD-IS does - // -1 = unknown -// -// OID_WW_CDPD_DATA_COMPRESSION -// - -typedef INT WW_CDPD_DATA_COMPRESSION; // 0 = no data compression, - // 1 = data compression enabled - // -1 = unknown -// -// OID_WW_CDPD_CHANNEL_SELECT -// - -typedef struct _WW_CDPD_CHANNEL_SELECT { - UINT ChannelID; // channel number - - UINT fixedDuration; // duration in seconds - -} WW_CDPD_CHANNEL_SELECT, *PWW_CDPD_CHANNEL_SELECT; - -// -// OID_WW_CDPD_CHANNEL_STATE -// -typedef enum _WW_CDPD_CHANNEL_STATE { - CDPDChannelNotAvail, - CDPDChannelScanning, - CDPDChannelInitAcquired, - CDPDChannelAcquired, - CDPDChannelSleeping, - CDPDChannelWaking, - CDPDChannelCSDialing, - CDPDChannelCSRedial, - CDPDChannelCSAnswering, - CDPDChannelCSConnected, - CDPDChannelCSSuspended -} WW_CDPD_CHANNEL_STATE, *PWW_CDPD_CHANNEL_STATE; - -// -// OID_WW_CDPD_NEI -// -typedef enum _WW_CDPD_NEI_FORMAT { - CDPDNeiIPv4, - CDPDNeiCLNP, - CDPDNeiIPv6 -} WW_CDPD_NEI_FORMAT, *PWW_CDPD_NEI_FORMAT; -typedef enum _WW_CDPD_NEI_TYPE { - CDPDNeiIndividual, - CDPDNeiMulticast, - CDPDNeiBroadcast -} WW_CDPD_NEI_TYPE; -typedef struct _WW_CDPD_NEI { - UINT uNeiIndex; - WW_CDPD_NEI_FORMAT NeiFormat; - WW_CDPD_NEI_TYPE NeiType; - WORD NeiGmid; // group member identifier, only - // meaningful if NeiType == - // CDPDNeiMulticast - - NDIS_VAR_DATA_DESC NeiAddress; -} WW_CDPD_NEI; - -// -// OID_WW_CDPD_NEI_STATE -// -typedef enum _WW_CDPD_NEI_STATE { - CDPDUnknown, - CDPDRegistered, - CDPDDeregistered -} WW_CDPD_NEI_STATE, *PWW_CDPD_NEI_STATE; -typedef enum _WW_CDPD_NEI_SUB_STATE { - CDPDPending, // Registration pending - CDPDNoReason, // Registration denied - no reason given - CDPDMDISNotCapable, // Registration denied - MD-IS not capable of - // handling M-ES at this time - CDPDNEINotAuthorized, // Registration denied - NEI is not authorized to - // use this subnetwork - CDPDInsufficientAuth, // Registration denied - M-ES gave insufficient - // authentication credentials - CDPDUnsupportedAuth, // Registration denied - M-ES gave unsupported - // authentication credentials - CDPDUsageExceeded, // Registration denied - NEI has exceeded usage - // limitations - CDPDDeniedThisNetwork // Registration denied on this network, service - // may be obtained on alternate Service Provider - // network -} WW_CDPD_NEI_SUB_STATE; -typedef struct _WW_CDPD_NEI_REG_STATE { - UINT uNeiIndex; - WW_CDPD_NEI_STATE NeiState; - WW_CDPD_NEI_SUB_STATE NeiSubState; -} WW_CDPD_NEI_REG_STATE, *PWW_CDPD_NEI_REG_STATE; - -// -// OID_WW_CDPD_SERVICE_PROVIDER_IDENTIFIER -// -typedef struct _WW_CDPD_SERVICE_PROVIDER_ID { - UINT SPI[10]; //10 16-bit service provider IDs - - INT OperatingMode; // 0 = ignore SPI, - // 1 = require SPI from list, - // 2 = prefer SPI from list. - // 3 = exclude SPI from list. - -} WW_CDPD_SERVICE_PROVIDER_ID, *PWW_CDPD_SERVICE_PROVIDER_ID; - -// -// OID_WW_CDPD_SLEEP_MODE -// -typedef INT WW_CDPD_SLEEP_MODE; -// -// OID_WW_CDPD_TEI -// -typedef ULONG WW_CDPD_TEI; -// -// OID_WW_CDPD_CIRCUIT_SWITCHED -// -typedef struct _WW_CDPD_CIRCUIT_SWITCHED { - INT service_preference; // -1 = unknown, - // 0 = always use packet switched CDPD, - // 1 = always use CS CDPD via AMPS, - // 2 = always use CS CDPD via PSTN, - // 3 = use circuit switched via AMPS only - // when packet switched is not available. - // 4 = use packet switched only when circuit - // switched via AMPS is not available. - // 5 = device manuf. defined service - // preference. - // 6 = device manuf. defined service - // preference. - - INT service_status; // -1 = unknown, - // 0 = packet switched CDPD, - // 1 = circuit switched CDPD via AMPS, - // 2 = circuit switched CDPD via PSTN. - - INT connect_rate; // CS connection bit rate (bits per second). - // 0 = no active connection, - // -1 = unknown - // Dial code last used to dial. - - NDIS_VAR_DATA_DESC dial_code[20]; - - UINT sid; // Current AMPS system ID - - INT a_b_side_selection; // -1 = unknown, - // 0 = no AMPS service - // 1 = AMPS "A" side channels selected - // 2 = AMPS "B" side channels selected - - INT AMPS_channel; // -1= unknown - // 0 = no AMPS service. - // 1-1023 = AMPS channel number in use - - UINT action; // 0 = no action - // 1 = suspend (hangup) - // 2 = dial - - // Default dial code for CS CDPD service - // encoded as specified in the CS CDPD - // implementor guidelines. - NDIS_VAR_DATA_DESC default_dial[20]; - - // Number for the CS CDPD network to call - // back the mobile, encoded as specified in - // the CS CDPD implementor guidelines. - NDIS_VAR_DATA_DESC call_back[20]; - - UINT sid_list[10]; // List of 10 16-bit preferred AMPS - // system IDs for CS CDPD. - - UINT inactivity_timer; // Wait time after last data before dropping - // call. - // 0-65535 = inactivity time limit (seconds). - - UINT receive_timer; // secs. per CS-CDPD Implementor Guidelines. - - UINT conn_resp_timer; // secs. per CS-CDPD Implementor Guidelines. - - UINT reconn_resp_timer; // secs. per CS-CDPD Implementor Guidelines. - - UINT disconn_timer; // secs. per CS-CDPD Implementor Guidelines. - - UINT NEI_reg_timer; // secs. per CS-CDPD Implementor Guidelines. - - UINT reconn_retry_timer; // secs. per CS-CDPD Implementor Guidelines. - - UINT link_reset_timer; // secs. per CS-CDPD Implementor Guidelines. - - UINT link_reset_ack_timer; // secs. per CS-CDPD Implementor Guidelines. - - UINT n401_retry_limit; // per CS-CDPD Implementor Guidelines. - - UINT n402_retry_limit; // per CS-CDPD Implementor Guidelines. - - UINT n404_retry_limit; // per CS-CDPD Implementor Guidelines. - - UINT n405_retry_limit; // per CS-CDPD Implementor Guidelines. - -} WW_CDPD_CIRCUIT_SWITCHED, *WW_PCDPD_CIRCUIT_SWITCHED; -typedef UINT WW_CDPD_RSSI; -// -// OID_WW_PIN_LOC_AUTHORIZE -// -typedef INT WW_PIN_AUTHORIZED; // 0 = unauthorized - // 1 = authorized - // -1 = unknown -// -// OID_WW_PIN_LAST_LOCATION -// OID_WW_PIN_LOC_FIX -// - -typedef struct _WW_PIN_LOCATION { - INT Latitude; // Latitude in hundredths of a second - - INT Longitude; // Longitude in hundredths of a second - - INT Altitude; // Altitude in feet - - INT FixTime; // Time of the location fix, since midnight, local time (of the - // current day), in tenths of a second - - INT NetTime; // Current local network time of the current day, since midnight, - // in tenths of a second - - INT LocQuality; // 0-100 = location quality - - INT LatReg; // Latitude registration offset, in hundredths of a second - - INT LongReg; // Longitude registration offset, in hundredths of a second - - INT GMTOffset; // Offset in minutes of the local time zone from GMT - -} WW_PIN_LOCATION, *PWW_PIN_LOCATION; - -// -// The following is set on a per-packet basis as OOB data with NdisClassWirelessWanMbxMailbox -// -typedef ULONG WW_MBX_MAILBOX_FLAG; // 1 = set mailbox flag, 0 = do not set mailbox flag -// -// OID_WW_MBX_SUBADDR -// - -typedef struct _WW_MBX_PMAN { - BOOLEAN ACTION; // 0 = Login PMAN, 1 = Logout PMAN - - UINT MAN; - UCHAR PASSWORD[8]; // Password should be null for Logout and indications. - // Maximum length of password is 8 chars. - -} WW_MBX_PMAN, *PWW_MBX_PMAN; - -// -// OID_WW_MBX_FLEXLIST -// -typedef struct _WW_MBX_FLEXLIST { - INT count; // Number of MAN entries used. - // -1=unknown. - - UINT MAN[7]; // List of MANs. - -} WW_MBX_FLEXLIST; - -// -// OID_WW_MBX_GROUPLIST -// -typedef struct _WW_MBX_GROUPLIST { - INT count; // Number of MAN entries used. - // -1=unknown. - - UINT MAN[15]; // List of MANs. - -} WW_MBX_GROUPLIST; - -// -// OID_WW_MBX_TRAFFIC_AREA -// -typedef enum _WW_MBX_TRAFFIC_AREA { - unknown_traffic_area, // The driver has no information about the current traffic area. - in_traffic_area, // Mobile unit has entered a subscribed traffic area. - in_auth_traffic_area, // Mobile unit is outside traffic area but is authorized. - unauth_traffic_area // Mobile unit is outside traffic area but is un-authorized. -} WW_MBX_TRAFFIC_AREA; - -// -// OID_WW_MBX_LIVE_DIE -// -typedef INT WW_MBX_LIVE_DIE; // 0 = DIE last received - // 1 = LIVE last received - // -1 = unknown -// -// OID_WW_MBX_TEMP_DEFAULTLIST -// - -typedef struct _WW_MBX_CHANNEL_PAIR { - UINT Mobile_Tx; - UINT Mobile_Rx; -} WW_MBX_CHANNEL_PAIR, *PWW_MBX_CHANNEL_PAIR; -typedef struct _WW_MBX_TEMPDEFAULTLIST { - UINT Length; - WW_MBX_CHANNEL_PAIR ChannelPair[1]; -} WW_MBX_TEMPDEFAULTLIST, *WW_PMBX_TEMPDEFAULTLIST; - -#endif // WIRELESS_WAN -#endif // _NTDDNDIS_ +/*++ BUILD Version: 0001 // Increment this if a change has global effects + Copyright (c) 1990-1993 Microsoft Corporation + Module Name: + ntddndis.h + Abstract: + This is the include file that defines all constants and types for + accessing the Network driver interface device. + Author: + Steve Wood (stevewo) 27-May-1990 + Revision History: + Adam Barr (adamba) 04-Nov-1992 added the correct values for NDIS 3.0. + Jameel Hyder (jameelh) 01-Aug-95 added Pnp IoCTLs and structures + Kyle Brandon (kyleb) 09/24/96 added general co ndis oids. + -- */ +#ifndef _NTDDNDIS_ +#define _NTDDNDIS_ +// +// Device Name - this string is the name of the device. It is the name +// that should be passed to NtOpenFile when accessing the device. +// +// Note: For devices that support multiple units, it should be suffixed +// with the Ascii representation of the unit number. +// +#define DD_NDIS_DEVICE_NAME "\\Device\\UNKNOWN" +// +// NtDeviceIoControlFile IoControlCode values for this device. +// +// Warning: Remember that the low two bits of the code specify how the +// buffers are passed to the driver! +// +#define _NDIS_CONTROL_CODE(request,method) \ + CTL_CODE(FILE_DEVICE_PHYSICAL_NETCARD, request, method, FILE_ANY_ACCESS) +#define IOCTL_NDIS_QUERY_GLOBAL_STATS _NDIS_CONTROL_CODE( 0, METHOD_OUT_DIRECT ) +#define IOCTL_NDIS_QUERY_ALL_STATS _NDIS_CONTROL_CODE( 1, METHOD_OUT_DIRECT ) +#define IOCTL_NDIS_ADD_DEVICE _NDIS_CONTROL_CODE( 2, METHOD_BUFFERED ) +#define IOCTL_NDIS_DELETE_DEVICE _NDIS_CONTROL_CODE( 3, METHOD_BUFFERED ) +#define IOCTL_NDIS_TRANSLATE_NAME _NDIS_CONTROL_CODE( 4, METHOD_BUFFERED ) +#define IOCTL_NDIS_ADD_TDI_DEVICE _NDIS_CONTROL_CODE( 5, METHOD_BUFFERED ) +#define IOCTL_NDIS_NOTIFY_PROTOCOL _NDIS_CONTROL_CODE( 6, METHOD_BUFFERED ) +#define IOCTL_NDIS_GET_LOG_DATA _NDIS_CONTROL_CODE( 7, METHOD_OUT_DIRECT ) +// +// NtDeviceIoControlFile InputBuffer/OutputBuffer record structures for +// this device. +// +// +// This is the type of an NDIS OID value. +// +typedef ULONG NDIS_OID, *PNDIS_OID; +// +// IOCTL_NDIS_QUERY_ALL_STATS returns a sequence of these, packed +// together (no padding is required since statistics all have +// four or eight bytes of data). +// +typedef struct _NDIS_STATISTICS_VALUE { + NDIS_OID Oid; + ULONG DataLength; + UCHAR Data[1]; // variable length + +} NDIS_STATISTICS_VALUE, *PNDIS_STATISTICS_VALUE; + +// +// Structure used by TRANSLATE_NAME IOCTL +// +typedef struct _NET_PNP_ID { + ULONG ClassId; + ULONG Token; +} NET_PNP_ID, *PNET_PNP_ID; + +typedef struct _NET_PNP_TRANSLATE_LIST { + ULONG BytesNeeded; + NET_PNP_ID IdArray[ANYSIZE_ARRAY]; +} NET_PNP_TRANSLATE_LIST, *PNET_PNP_TRANSLATE_LIST; + +// +// Structure used to define a self-contained variable data structure +// +typedef struct _NDIS_VAR_DATA_DESC { + USHORT Length; // # of octects of data + + USHORT MaximumLength; // # of octects available + + LONG Offset; // Offset of data relative to the descriptor + +} NDIS_VAR_DATA_DESC, *PNDIS_VAR_DATA_DESC; + +// +// Object Identifiers used by NdisRequest Query/Set Information +// +// +// General Objects +// +#define OID_GEN_SUPPORTED_LIST 0x00010101 +#define OID_GEN_HARDWARE_STATUS 0x00010102 +#define OID_GEN_MEDIA_SUPPORTED 0x00010103 +#define OID_GEN_MEDIA_IN_USE 0x00010104 +#define OID_GEN_MAXIMUM_LOOKAHEAD 0x00010105 +#define OID_GEN_MAXIMUM_FRAME_SIZE 0x00010106 +#define OID_GEN_LINK_SPEED 0x00010107 +#define OID_GEN_TRANSMIT_BUFFER_SPACE 0x00010108 +#define OID_GEN_RECEIVE_BUFFER_SPACE 0x00010109 +#define OID_GEN_TRANSMIT_BLOCK_SIZE 0x0001010A +#define OID_GEN_RECEIVE_BLOCK_SIZE 0x0001010B +#define OID_GEN_VENDOR_ID 0x0001010C +#define OID_GEN_VENDOR_DESCRIPTION 0x0001010D +#define OID_GEN_CURRENT_PACKET_FILTER 0x0001010E +#define OID_GEN_CURRENT_LOOKAHEAD 0x0001010F +#define OID_GEN_DRIVER_VERSION 0x00010110 +#define OID_GEN_MAXIMUM_TOTAL_SIZE 0x00010111 +#define OID_GEN_PROTOCOL_OPTIONS 0x00010112 +#define OID_GEN_MAC_OPTIONS 0x00010113 +#define OID_GEN_MEDIA_CONNECT_STATUS 0x00010114 +#define OID_GEN_MAXIMUM_SEND_PACKETS 0x00010115 +#define OID_GEN_VENDOR_DRIVER_VERSION 0x00010116 +#define OID_GEN_XMIT_OK 0x00020101 +#define OID_GEN_RCV_OK 0x00020102 +#define OID_GEN_XMIT_ERROR 0x00020103 +#define OID_GEN_RCV_ERROR 0x00020104 +#define OID_GEN_RCV_NO_BUFFER 0x00020105 +#define OID_GEN_DIRECTED_BYTES_XMIT 0x00020201 +#define OID_GEN_DIRECTED_FRAMES_XMIT 0x00020202 +#define OID_GEN_MULTICAST_BYTES_XMIT 0x00020203 +#define OID_GEN_MULTICAST_FRAMES_XMIT 0x00020204 +#define OID_GEN_BROADCAST_BYTES_XMIT 0x00020205 +#define OID_GEN_BROADCAST_FRAMES_XMIT 0x00020206 +#define OID_GEN_DIRECTED_BYTES_RCV 0x00020207 +#define OID_GEN_DIRECTED_FRAMES_RCV 0x00020208 +#define OID_GEN_MULTICAST_BYTES_RCV 0x00020209 +#define OID_GEN_MULTICAST_FRAMES_RCV 0x0002020A +#define OID_GEN_BROADCAST_BYTES_RCV 0x0002020B +#define OID_GEN_BROADCAST_FRAMES_RCV 0x0002020C +#define OID_GEN_RCV_CRC_ERROR 0x0002020D +#define OID_GEN_TRANSMIT_QUEUE_LENGTH 0x0002020E +#define OID_GEN_GET_TIME_CAPS 0x0002020F +#define OID_GEN_GET_NETCARD_TIME 0x00020210 +// +// These are connection-oriented general OIDs. +// These replace the above OIDs for connection-oriented media. +// +#define OID_GEN_CO_SUPPORTED_LIST 0x00010101 +#define OID_GEN_CO_HARDWARE_STATUS 0x00010102 +#define OID_GEN_CO_MEDIA_SUPPORTED 0x00010103 +#define OID_GEN_CO_MEDIA_IN_USE 0x00010104 +#define OID_GEN_CO_LINK_SPEED 0x00010105 +#define OID_GEN_CO_VENDOR_ID 0x00010106 +#define OID_GEN_CO_VENDOR_DESCRIPTION 0x00010107 +#define OID_GEN_CO_DRIVER_VERSION 0x00010108 +#define OID_GEN_CO_PROTOCOL_OPTIONS 0x00010109 +#define OID_GEN_CO_MAC_OPTIONS 0x0001010A +#define OID_GEN_CO_MEDIA_CONNECT_STATUS 0x0001010B +#define OID_GEN_CO_VENDOR_DRIVER_VERSION 0x0001010C +#define OID_GEN_CO_MINIMUM_LINK_SPEED 0x0001010D +#define OID_GEN_CO_GET_TIME_CAPS 0x00010201 +#define OID_GEN_CO_GET_NETCARD_TIME 0x00010202 +// +// These are connection-oriented statistics OIDs. +// +#define OID_GEN_CO_XMIT_PDUS_OK 0x00020101 +#define OID_GEN_CO_RCV_PDUS_OK 0x00020102 +#define OID_GEN_CO_XMIT_PDUS_ERROR 0x00020103 +#define OID_GEN_CO_RCV_PDUS_ERROR 0x00020104 +#define OID_GEN_CO_RCV_PDUS_NO_BUFFER 0x00020105 +#define OID_GEN_CO_RCV_CRC_ERROR 0x00020201 +#define OID_GEN_CO_TRANSMIT_QUEUE_LENGTH 0x00020202 +#define OID_GEN_CO_BYTES_XMIT 0x00020203 +#define OID_GEN_CO_BYTES_RCV 0x00020204 +#define OID_GEN_CO_BYTES_XMIT_OUTSTANDING 0x00020205 +#define OID_GEN_CO_NETCARD_LOAD 0x00020206 +// +// These are objects for Connection-oriented media call-managers and are not +// valid for ndis drivers. Under construction. +// +#define OID_CO_ADD_PVC 0xFF000001 +#define OID_CO_DELETE_PVC 0xFF000002 +#define OID_CO_GET_CALL_INFORMATION 0xFF000003 +#define OID_CO_ADD_ADDRESS 0xFF000004 +#define OID_CO_DELETE_ADDRESS 0xFF000005 +#define OID_CO_GET_ADDRESSES 0xFF000006 +#define OID_CO_ADDRESS_CHANGE 0xFF000007 +#define OID_CO_SIGNALING_ENABLED 0xFF000008 +#define OID_CO_SIGNALING_DISABLED 0xFF000009 +// +// 802.3 Objects (Ethernet) +// +#define OID_802_3_PERMANENT_ADDRESS 0x01010101 +#define OID_802_3_CURRENT_ADDRESS 0x01010102 +#define OID_802_3_MULTICAST_LIST 0x01010103 +#define OID_802_3_MAXIMUM_LIST_SIZE 0x01010104 +#define OID_802_3_MAC_OPTIONS 0x01010105 +// +// +#define NDIS_802_3_MAC_OPTION_PRIORITY 0x00000001 +#define OID_802_3_RCV_ERROR_ALIGNMENT 0x01020101 +#define OID_802_3_XMIT_ONE_COLLISION 0x01020102 +#define OID_802_3_XMIT_MORE_COLLISIONS 0x01020103 +#define OID_802_3_XMIT_DEFERRED 0x01020201 +#define OID_802_3_XMIT_MAX_COLLISIONS 0x01020202 +#define OID_802_3_RCV_OVERRUN 0x01020203 +#define OID_802_3_XMIT_UNDERRUN 0x01020204 +#define OID_802_3_XMIT_HEARTBEAT_FAILURE 0x01020205 +#define OID_802_3_XMIT_TIMES_CRS_LOST 0x01020206 +#define OID_802_3_XMIT_LATE_COLLISIONS 0x01020207 +// +// 802.5 Objects (Token-Ring) +// +#define OID_802_5_PERMANENT_ADDRESS 0x02010101 +#define OID_802_5_CURRENT_ADDRESS 0x02010102 +#define OID_802_5_CURRENT_FUNCTIONAL 0x02010103 +#define OID_802_5_CURRENT_GROUP 0x02010104 +#define OID_802_5_LAST_OPEN_STATUS 0x02010105 +#define OID_802_5_CURRENT_RING_STATUS 0x02010106 +#define OID_802_5_CURRENT_RING_STATE 0x02010107 +#define OID_802_5_LINE_ERRORS 0x02020101 +#define OID_802_5_LOST_FRAMES 0x02020102 +#define OID_802_5_BURST_ERRORS 0x02020201 +#define OID_802_5_AC_ERRORS 0x02020202 +#define OID_802_5_ABORT_DELIMETERS 0x02020203 +#define OID_802_5_FRAME_COPIED_ERRORS 0x02020204 +#define OID_802_5_FREQUENCY_ERRORS 0x02020205 +#define OID_802_5_TOKEN_ERRORS 0x02020206 +#define OID_802_5_INTERNAL_ERRORS 0x02020207 +// +// FDDI Objects +// +#define OID_FDDI_LONG_PERMANENT_ADDR 0x03010101 +#define OID_FDDI_LONG_CURRENT_ADDR 0x03010102 +#define OID_FDDI_LONG_MULTICAST_LIST 0x03010103 +#define OID_FDDI_LONG_MAX_LIST_SIZE 0x03010104 +#define OID_FDDI_SHORT_PERMANENT_ADDR 0x03010105 +#define OID_FDDI_SHORT_CURRENT_ADDR 0x03010106 +#define OID_FDDI_SHORT_MULTICAST_LIST 0x03010107 +#define OID_FDDI_SHORT_MAX_LIST_SIZE 0x03010108 +#define OID_FDDI_ATTACHMENT_TYPE 0x03020101 +#define OID_FDDI_UPSTREAM_NODE_LONG 0x03020102 +#define OID_FDDI_DOWNSTREAM_NODE_LONG 0x03020103 +#define OID_FDDI_FRAME_ERRORS 0x03020104 +#define OID_FDDI_FRAMES_LOST 0x03020105 +#define OID_FDDI_RING_MGT_STATE 0x03020106 +#define OID_FDDI_LCT_FAILURES 0x03020107 +#define OID_FDDI_LEM_REJECTS 0x03020108 +#define OID_FDDI_LCONNECTION_STATE 0x03020109 +#define OID_FDDI_SMT_STATION_ID 0x03030201 +#define OID_FDDI_SMT_OP_VERSION_ID 0x03030202 +#define OID_FDDI_SMT_HI_VERSION_ID 0x03030203 +#define OID_FDDI_SMT_LO_VERSION_ID 0x03030204 +#define OID_FDDI_SMT_MANUFACTURER_DATA 0x03030205 +#define OID_FDDI_SMT_USER_DATA 0x03030206 +#define OID_FDDI_SMT_MIB_VERSION_ID 0x03030207 +#define OID_FDDI_SMT_MAC_CT 0x03030208 +#define OID_FDDI_SMT_NON_MASTER_CT 0x03030209 +#define OID_FDDI_SMT_MASTER_CT 0x0303020A +#define OID_FDDI_SMT_AVAILABLE_PATHS 0x0303020B +#define OID_FDDI_SMT_CONFIG_CAPABILITIES 0x0303020C +#define OID_FDDI_SMT_CONFIG_POLICY 0x0303020D +#define OID_FDDI_SMT_CONNECTION_POLICY 0x0303020E +#define OID_FDDI_SMT_T_NOTIFY 0x0303020F +#define OID_FDDI_SMT_STAT_RPT_POLICY 0x03030210 +#define OID_FDDI_SMT_TRACE_MAX_EXPIRATION 0x03030211 +#define OID_FDDI_SMT_PORT_INDEXES 0x03030212 +#define OID_FDDI_SMT_MAC_INDEXES 0x03030213 +#define OID_FDDI_SMT_BYPASS_PRESENT 0x03030214 +#define OID_FDDI_SMT_ECM_STATE 0x03030215 +#define OID_FDDI_SMT_CF_STATE 0x03030216 +#define OID_FDDI_SMT_HOLD_STATE 0x03030217 +#define OID_FDDI_SMT_REMOTE_DISCONNECT_FLAG 0x03030218 +#define OID_FDDI_SMT_STATION_STATUS 0x03030219 +#define OID_FDDI_SMT_PEER_WRAP_FLAG 0x0303021A +#define OID_FDDI_SMT_MSG_TIME_STAMP 0x0303021B +#define OID_FDDI_SMT_TRANSITION_TIME_STAMP 0x0303021C +#define OID_FDDI_SMT_SET_COUNT 0x0303021D +#define OID_FDDI_SMT_LAST_SET_STATION_ID 0x0303021E +#define OID_FDDI_MAC_FRAME_STATUS_FUNCTIONS 0x0303021F +#define OID_FDDI_MAC_BRIDGE_FUNCTIONS 0x03030220 +#define OID_FDDI_MAC_T_MAX_CAPABILITY 0x03030221 +#define OID_FDDI_MAC_TVX_CAPABILITY 0x03030222 +#define OID_FDDI_MAC_AVAILABLE_PATHS 0x03030223 +#define OID_FDDI_MAC_CURRENT_PATH 0x03030224 +#define OID_FDDI_MAC_UPSTREAM_NBR 0x03030225 +#define OID_FDDI_MAC_DOWNSTREAM_NBR 0x03030226 +#define OID_FDDI_MAC_OLD_UPSTREAM_NBR 0x03030227 +#define OID_FDDI_MAC_OLD_DOWNSTREAM_NBR 0x03030228 +#define OID_FDDI_MAC_DUP_ADDRESS_TEST 0x03030229 +#define OID_FDDI_MAC_REQUESTED_PATHS 0x0303022A +#define OID_FDDI_MAC_DOWNSTREAM_PORT_TYPE 0x0303022B +#define OID_FDDI_MAC_INDEX 0x0303022C +#define OID_FDDI_MAC_SMT_ADDRESS 0x0303022D +#define OID_FDDI_MAC_LONG_GRP_ADDRESS 0x0303022E +#define OID_FDDI_MAC_SHORT_GRP_ADDRESS 0x0303022F +#define OID_FDDI_MAC_T_REQ 0x03030230 +#define OID_FDDI_MAC_T_NEG 0x03030231 +#define OID_FDDI_MAC_T_MAX 0x03030232 +#define OID_FDDI_MAC_TVX_VALUE 0x03030233 +#define OID_FDDI_MAC_T_PRI0 0x03030234 +#define OID_FDDI_MAC_T_PRI1 0x03030235 +#define OID_FDDI_MAC_T_PRI2 0x03030236 +#define OID_FDDI_MAC_T_PRI3 0x03030237 +#define OID_FDDI_MAC_T_PRI4 0x03030238 +#define OID_FDDI_MAC_T_PRI5 0x03030239 +#define OID_FDDI_MAC_T_PRI6 0x0303023A +#define OID_FDDI_MAC_FRAME_CT 0x0303023B +#define OID_FDDI_MAC_COPIED_CT 0x0303023C +#define OID_FDDI_MAC_TRANSMIT_CT 0x0303023D +#define OID_FDDI_MAC_TOKEN_CT 0x0303023E +#define OID_FDDI_MAC_ERROR_CT 0x0303023F +#define OID_FDDI_MAC_LOST_CT 0x03030240 +#define OID_FDDI_MAC_TVX_EXPIRED_CT 0x03030241 +#define OID_FDDI_MAC_NOT_COPIED_CT 0x03030242 +#define OID_FDDI_MAC_LATE_CT 0x03030243 +#define OID_FDDI_MAC_RING_OP_CT 0x03030244 +#define OID_FDDI_MAC_FRAME_ERROR_THRESHOLD 0x03030245 +#define OID_FDDI_MAC_FRAME_ERROR_RATIO 0x03030246 +#define OID_FDDI_MAC_NOT_COPIED_THRESHOLD 0x03030247 +#define OID_FDDI_MAC_NOT_COPIED_RATIO 0x03030248 +#define OID_FDDI_MAC_RMT_STATE 0x03030249 +#define OID_FDDI_MAC_DA_FLAG 0x0303024A +#define OID_FDDI_MAC_UNDA_FLAG 0x0303024B +#define OID_FDDI_MAC_FRAME_ERROR_FLAG 0x0303024C +#define OID_FDDI_MAC_NOT_COPIED_FLAG 0x0303024D +#define OID_FDDI_MAC_MA_UNITDATA_AVAILABLE 0x0303024E +#define OID_FDDI_MAC_HARDWARE_PRESENT 0x0303024F +#define OID_FDDI_MAC_MA_UNITDATA_ENABLE 0x03030250 +#define OID_FDDI_PATH_INDEX 0x03030251 +#define OID_FDDI_PATH_RING_LATENCY 0x03030252 +#define OID_FDDI_PATH_TRACE_STATUS 0x03030253 +#define OID_FDDI_PATH_SBA_PAYLOAD 0x03030254 +#define OID_FDDI_PATH_SBA_OVERHEAD 0x03030255 +#define OID_FDDI_PATH_CONFIGURATION 0x03030256 +#define OID_FDDI_PATH_T_R_MODE 0x03030257 +#define OID_FDDI_PATH_SBA_AVAILABLE 0x03030258 +#define OID_FDDI_PATH_TVX_LOWER_BOUND 0x03030259 +#define OID_FDDI_PATH_T_MAX_LOWER_BOUND 0x0303025A +#define OID_FDDI_PATH_MAX_T_REQ 0x0303025B +#define OID_FDDI_PORT_MY_TYPE 0x0303025C +#define OID_FDDI_PORT_NEIGHBOR_TYPE 0x0303025D +#define OID_FDDI_PORT_CONNECTION_POLICIES 0x0303025E +#define OID_FDDI_PORT_MAC_INDICATED 0x0303025F +#define OID_FDDI_PORT_CURRENT_PATH 0x03030260 +#define OID_FDDI_PORT_REQUESTED_PATHS 0x03030261 +#define OID_FDDI_PORT_MAC_PLACEMENT 0x03030262 +#define OID_FDDI_PORT_AVAILABLE_PATHS 0x03030263 +#define OID_FDDI_PORT_MAC_LOOP_TIME 0x03030264 +#define OID_FDDI_PORT_PMD_CLASS 0x03030265 +#define OID_FDDI_PORT_CONNECTION_CAPABILITIES 0x03030266 +#define OID_FDDI_PORT_INDEX 0x03030267 +#define OID_FDDI_PORT_MAINT_LS 0x03030268 +#define OID_FDDI_PORT_BS_FLAG 0x03030269 +#define OID_FDDI_PORT_PC_LS 0x0303026A +#define OID_FDDI_PORT_EB_ERROR_CT 0x0303026B +#define OID_FDDI_PORT_LCT_FAIL_CT 0x0303026C +#define OID_FDDI_PORT_LER_ESTIMATE 0x0303026D +#define OID_FDDI_PORT_LEM_REJECT_CT 0x0303026E +#define OID_FDDI_PORT_LEM_CT 0x0303026F +#define OID_FDDI_PORT_LER_CUTOFF 0x03030270 +#define OID_FDDI_PORT_LER_ALARM 0x03030271 +#define OID_FDDI_PORT_CONNNECT_STATE 0x03030272 +#define OID_FDDI_PORT_PCM_STATE 0x03030273 +#define OID_FDDI_PORT_PC_WITHHOLD 0x03030274 +#define OID_FDDI_PORT_LER_FLAG 0x03030275 +#define OID_FDDI_PORT_HARDWARE_PRESENT 0x03030276 +#define OID_FDDI_SMT_STATION_ACTION 0x03030277 +#define OID_FDDI_PORT_ACTION 0x03030278 +#define OID_FDDI_IF_DESCR 0x03030279 +#define OID_FDDI_IF_TYPE 0x0303027A +#define OID_FDDI_IF_MTU 0x0303027B +#define OID_FDDI_IF_SPEED 0x0303027C +#define OID_FDDI_IF_PHYS_ADDRESS 0x0303027D +#define OID_FDDI_IF_ADMIN_STATUS 0x0303027E +#define OID_FDDI_IF_OPER_STATUS 0x0303027F +#define OID_FDDI_IF_LAST_CHANGE 0x03030280 +#define OID_FDDI_IF_IN_OCTETS 0x03030281 +#define OID_FDDI_IF_IN_UCAST_PKTS 0x03030282 +#define OID_FDDI_IF_IN_NUCAST_PKTS 0x03030283 +#define OID_FDDI_IF_IN_DISCARDS 0x03030284 +#define OID_FDDI_IF_IN_ERRORS 0x03030285 +#define OID_FDDI_IF_IN_UNKNOWN_PROTOS 0x03030286 +#define OID_FDDI_IF_OUT_OCTETS 0x03030287 +#define OID_FDDI_IF_OUT_UCAST_PKTS 0x03030288 +#define OID_FDDI_IF_OUT_NUCAST_PKTS 0x03030289 +#define OID_FDDI_IF_OUT_DISCARDS 0x0303028A +#define OID_FDDI_IF_OUT_ERRORS 0x0303028B +#define OID_FDDI_IF_OUT_QLEN 0x0303028C +#define OID_FDDI_IF_SPECIFIC 0x0303028D +// +// WAN objects +// +#define OID_WAN_PERMANENT_ADDRESS 0x04010101 +#define OID_WAN_CURRENT_ADDRESS 0x04010102 +#define OID_WAN_QUALITY_OF_SERVICE 0x04010103 +#define OID_WAN_PROTOCOL_TYPE 0x04010104 +#define OID_WAN_MEDIUM_SUBTYPE 0x04010105 +#define OID_WAN_HEADER_FORMAT 0x04010106 +#define OID_WAN_GET_INFO 0x04010107 +#define OID_WAN_SET_LINK_INFO 0x04010108 +#define OID_WAN_GET_LINK_INFO 0x04010109 +#define OID_WAN_LINE_COUNT 0x0401010A +#define OID_WAN_GET_BRIDGE_INFO 0x0401020A +#define OID_WAN_SET_BRIDGE_INFO 0x0401020B +#define OID_WAN_GET_COMP_INFO 0x0401020C +#define OID_WAN_SET_COMP_INFO 0x0401020D +#define OID_WAN_GET_STATS_INFO 0x0401020E +// +// LocalTalk objects +// +#define OID_LTALK_CURRENT_NODE_ID 0x05010102 +#define OID_LTALK_IN_BROADCASTS 0x05020101 +#define OID_LTALK_IN_LENGTH_ERRORS 0x05020102 +#define OID_LTALK_OUT_NO_HANDLERS 0x05020201 +#define OID_LTALK_COLLISIONS 0x05020202 +#define OID_LTALK_DEFERS 0x05020203 +#define OID_LTALK_NO_DATA_ERRORS 0x05020204 +#define OID_LTALK_RANDOM_CTS_ERRORS 0x05020205 +#define OID_LTALK_FCS_ERRORS 0x05020206 +// +// Arcnet objects +// +#define OID_ARCNET_PERMANENT_ADDRESS 0x06010101 +#define OID_ARCNET_CURRENT_ADDRESS 0x06010102 +#define OID_ARCNET_RECONFIGURATIONS 0x06020201 +// +// TAPI objects +// +#define OID_TAPI_ACCEPT 0x07030101 +#define OID_TAPI_ANSWER 0x07030102 +#define OID_TAPI_CLOSE 0x07030103 +#define OID_TAPI_CLOSE_CALL 0x07030104 +#define OID_TAPI_CONDITIONAL_MEDIA_DETECTION 0x07030105 +#define OID_TAPI_CONFIG_DIALOG 0x07030106 +#define OID_TAPI_DEV_SPECIFIC 0x07030107 +#define OID_TAPI_DIAL 0x07030108 +#define OID_TAPI_DROP 0x07030109 +#define OID_TAPI_GET_ADDRESS_CAPS 0x0703010A +#define OID_TAPI_GET_ADDRESS_ID 0x0703010B +#define OID_TAPI_GET_ADDRESS_STATUS 0x0703010C +#define OID_TAPI_GET_CALL_ADDRESS_ID 0x0703010D +#define OID_TAPI_GET_CALL_INFO 0x0703010E +#define OID_TAPI_GET_CALL_STATUS 0x0703010F +#define OID_TAPI_GET_DEV_CAPS 0x07030110 +#define OID_TAPI_GET_DEV_CONFIG 0x07030111 +#define OID_TAPI_GET_EXTENSION_ID 0x07030112 +#define OID_TAPI_GET_ID 0x07030113 +#define OID_TAPI_GET_LINE_DEV_STATUS 0x07030114 +#define OID_TAPI_MAKE_CALL 0x07030115 +#define OID_TAPI_NEGOTIATE_EXT_VERSION 0x07030116 +#define OID_TAPI_OPEN 0x07030117 +#define OID_TAPI_PROVIDER_INITIALIZE 0x07030118 +#define OID_TAPI_PROVIDER_SHUTDOWN 0x07030119 +#define OID_TAPI_SECURE_CALL 0x0703011A +#define OID_TAPI_SELECT_EXT_VERSION 0x0703011B +#define OID_TAPI_SEND_USER_USER_INFO 0x0703011C +#define OID_TAPI_SET_APP_SPECIFIC 0x0703011D +#define OID_TAPI_SET_CALL_PARAMS 0x0703011E +#define OID_TAPI_SET_DEFAULT_MEDIA_DETECTION 0x0703011F +#define OID_TAPI_SET_DEV_CONFIG 0x07030120 +#define OID_TAPI_SET_MEDIA_MODE 0x07030121 +#define OID_TAPI_SET_STATUS_MESSAGES 0x07030122 +// +// ATM Connection Oriented Ndis +// +#define OID_ATM_SUPPORTED_VC_RATES 0x08010101 +#define OID_ATM_SUPPORTED_SERVICE_CATEGORY 0x08010102 +#define OID_ATM_SUPPORTED_AAL_TYPES 0x08010103 +#define OID_ATM_HW_CURRENT_ADDRESS 0x08010104 +#define OID_ATM_MAX_ACTIVE_VCS 0x08010105 +#define OID_ATM_MAX_ACTIVE_VCI_BITS 0x08010106 +#define OID_ATM_MAX_ACTIVE_VPI_BITS 0x08010107 +#define OID_ATM_MAX_AAL0_PACKET_SIZE 0x08010108 +#define OID_ATM_MAX_AAL1_PACKET_SIZE 0x08010109 +#define OID_ATM_MAX_AAL34_PACKET_SIZE 0x0801010A +#define OID_ATM_MAX_AAL5_PACKET_SIZE 0x0801010B +#define OID_ATM_SIGNALING_VPIVCI 0x08010201 +#define OID_ATM_ASSIGNED_VPI 0x08010202 +#define OID_ATM_ACQUIRE_ACCESS_NET_RESOURCES 0x08010203 +#define OID_ATM_RELEASE_ACCESS_NET_RESOURCES 0x08010204 +#define OID_ATM_ILMI_VPIVCI 0x08010205 +#define OID_ATM_DIGITAL_BROADCAST_VPIVCI 0x08010206 +#define OID_ATM_GET_NEAREST_FLOW 0x08010207 +#define OID_ATM_ALIGNMENT_REQUIRED 0x08010208 +// +// ATM specific statistics OIDs. +// +#define OID_ATM_RCV_CELLS_OK 0x08020101 +#define OID_ATM_XMIT_CELLS_OK 0x08020102 +#define OID_ATM_RCV_CELLS_DROPPED 0x08020103 +#define OID_ATM_RCV_INVALID_VPI_VCI 0x08020201 +#define OID_ATM_CELLS_HEC_ERROR 0x08020202 +#define OID_ATM_RCV_REASSEMBLY_ERROR 0x08020203 +// +// PCCA (Wireless) object +// +// +// All WirelessWAN devices must support the following OIDs +// +#define OID_WW_GEN_NETWORK_TYPES_SUPPORTED 0x09010101 +#define OID_WW_GEN_NETWORK_TYPE_IN_USE 0x09010102 +#define OID_WW_GEN_HEADER_FORMATS_SUPPORTED 0x09010103 +#define OID_WW_GEN_HEADER_FORMAT_IN_USE 0x09010104 +#define OID_WW_GEN_INDICATION_REQUEST 0x09010105 +#define OID_WW_GEN_DEVICE_INFO 0x09010106 +#define OID_WW_GEN_OPERATION_MODE 0x09010107 +#define OID_WW_GEN_LOCK_STATUS 0x09010108 +#define OID_WW_GEN_DISABLE_TRANSMITTER 0x09010109 +#define OID_WW_GEN_NETWORK_ID 0x0901010A +#define OID_WW_GEN_PERMANENT_ADDRESS 0x0901010B +#define OID_WW_GEN_CURRENT_ADDRESS 0x0901010C +#define OID_WW_GEN_SUSPEND_DRIVER 0x0901010D +#define OID_WW_GEN_BASESTATION_ID 0x0901010E +#define OID_WW_GEN_CHANNEL_ID 0x0901010F +#define OID_WW_GEN_ENCRYPTION_SUPPORTED 0x09010110 +#define OID_WW_GEN_ENCRYPTION_IN_USE 0x09010111 +#define OID_WW_GEN_ENCRYPTION_STATE 0x09010112 +#define OID_WW_GEN_CHANNEL_QUALITY 0x09010113 +#define OID_WW_GEN_REGISTRATION_STATUS 0x09010114 +#define OID_WW_GEN_RADIO_LINK_SPEED 0x09010115 +#define OID_WW_GEN_LATENCY 0x09010116 +#define OID_WW_GEN_BATTERY_LEVEL 0x09010117 +#define OID_WW_GEN_EXTERNAL_POWER 0x09010118 +// +// Network Dependent OIDs - Mobitex: +// +#define OID_WW_MBX_SUBADDR 0x09050101 +// OID 0x09050102 is reserved and may not be used +#define OID_WW_MBX_FLEXLIST 0x09050103 +#define OID_WW_MBX_GROUPLIST 0x09050104 +#define OID_WW_MBX_TRAFFIC_AREA 0x09050105 +#define OID_WW_MBX_LIVE_DIE 0x09050106 +#define OID_WW_MBX_TEMP_DEFAULTLIST 0x09050107 +// +// Network Dependent OIDs - Pinpoint: +// +#define OID_WW_PIN_LOC_AUTHORIZE 0x09090101 +#define OID_WW_PIN_LAST_LOCATION 0x09090102 +#define OID_WW_PIN_LOC_FIX 0x09090103 +// +// Network Dependent - CDPD: +// +#define OID_WW_CDPD_SPNI 0x090D0101 +#define OID_WW_CDPD_WASI 0x090D0102 +#define OID_WW_CDPD_AREA_COLOR 0x090D0103 +#define OID_WW_CDPD_TX_POWER_LEVEL 0x090D0104 +#define OID_WW_CDPD_EID 0x090D0105 +#define OID_WW_CDPD_HEADER_COMPRESSION 0x090D0106 +#define OID_WW_CDPD_DATA_COMPRESSION 0x090D0107 +#define OID_WW_CDPD_CHANNEL_SELECT 0x090D0108 +#define OID_WW_CDPD_CHANNEL_STATE 0x090D0109 +#define OID_WW_CDPD_NEI 0x090D010A +#define OID_WW_CDPD_NEI_STATE 0x090D010B +#define OID_WW_CDPD_SERVICE_PROVIDER_IDENTIFIER 0x090D010C +#define OID_WW_CDPD_SLEEP_MODE 0x090D010D +#define OID_WW_CDPD_CIRCUIT_SWITCHED 0x090D010E +#define OID_WW_CDPD_TEI 0x090D010F +#define OID_WW_CDPD_RSSI 0x090D0110 +// +// Network Dependent - Ardis: +// +#define OID_WW_ARD_SNDCP 0x09110101 +#define OID_WW_ARD_TMLY_MSG 0x09110102 +#define OID_WW_ARD_DATAGRAM 0x09110103 +// +// Network Dependent - DataTac: +// +#define OID_WW_TAC_COMPRESSION 0x09150101 +#define OID_WW_TAC_SET_CONFIG 0x09150102 +#define OID_WW_TAC_GET_STATUS 0x09150103 +#define OID_WW_TAC_USER_HEADER 0x09150104 +// +// Network Dependent - Metricom: +// +#define OID_WW_MET_FUNCTION 0x09190101 +// +// IRDA objects +// +#define OID_IRDA_RECEIVING 0x0A010100 +#define OID_IRDA_TURNAROUND_TIME 0x0A010101 +#define OID_IRDA_SUPPORTED_SPEEDS 0x0A010102 +#define OID_IRDA_LINK_SPEED 0x0A010103 +#define OID_IRDA_MEDIA_BUSY 0x0A010104 +#define OID_IRDA_EXTRA_RCV_BOFS 0x0A010200 +#define OID_IRDA_RATE_SNIFF 0x0A010201 +#define OID_IRDA_UNICAST_LIST 0x0A010202 +#define OID_IRDA_MAX_UNICAST_LIST_SIZE 0x0A010203 +#define OID_IRDA_MAX_RECEIVE_WINDOW_SIZE 0x0A010204 +#define OID_IRDA_MAX_SEND_WINDOW_SIZE 0x0A010205 +// +// Medium the Ndis Driver is running on (OID_GEN_MEDIA_SUPPORTED/ +// OID_GEN_MEDIA_IN_USE). +// +typedef enum _NDIS_MEDIUM { + NdisMedium802_3, + NdisMedium802_5, + NdisMediumFddi, + NdisMediumWan, + NdisMediumLocalTalk, + NdisMediumDix, // defined for convenience, not a real medium + NdisMediumArcnetRaw, + NdisMediumArcnet878_2, + NdisMediumAtm, + NdisMediumWirelessWan, + NdisMediumIrda, + NdisMediumMax // Not a real medium, defined as an upper-bound +} NDIS_MEDIUM, *PNDIS_MEDIUM; + +// +// Hardware status codes (OID_GEN_HARDWARE_STATUS). +// +typedef enum _NDIS_HARDWARE_STATUS { + NdisHardwareStatusReady, + NdisHardwareStatusInitializing, + NdisHardwareStatusReset, + NdisHardwareStatusClosing, + NdisHardwareStatusNotReady +} NDIS_HARDWARE_STATUS, *PNDIS_HARDWARE_STATUS; + +// +// this is the type passed in the OID_GEN_GET_TIME_CAPS request +// +typedef struct _GEN_GET_TIME_CAPS { + ULONG Flags; // Bits defined below + + ULONG ClockPrecision; +} GEN_GET_TIME_CAPS, *PGEN_GET_TIME_CAPS; + +#define READABLE_LOCAL_CLOCK 0x000000001 +#define CLOCK_NETWORK_DERIVED 0x000000002 +#define CLOCK_PRECISION 0x000000004 +#define RECEIVE_TIME_INDICATION_CAPABLE 0x000000008 +#define TIMED_SEND_CAPABLE 0x000000010 +#define TIME_STAMP_CAPABLE 0x000000020 +// +// +// this is the type passed in the OID_GEN_GET_NETCARD_TIME request +// +typedef struct _GEN_GET_NETCARD_TIME { + ULONG ReadTime; +} GEN_GET_NETCARD_TIME, *PGEN_GET_NETCARD_TIME; + +// +// Defines the attachment types for FDDI (OID_FDDI_ATTACHMENT_TYPE). +// +typedef enum _NDIS_FDDI_ATTACHMENT_TYPE { + NdisFddiTypeIsolated = 1, + NdisFddiTypeLocalA, + NdisFddiTypeLocalB, + NdisFddiTypeLocalAB, + NdisFddiTypeLocalS, + NdisFddiTypeWrapA, + NdisFddiTypeWrapB, + NdisFddiTypeWrapAB, + NdisFddiTypeWrapS, + NdisFddiTypeCWrapA, + NdisFddiTypeCWrapB, + NdisFddiTypeCWrapS, + NdisFddiTypeThrough +} NDIS_FDDI_ATTACHMENT_TYPE, *PNDIS_FDDI_ATTACHMENT_TYPE; + +// +// Defines the ring management states for FDDI (OID_FDDI_RING_MGT_STATE). +// +typedef enum _NDIS_FDDI_RING_MGT_STATE { + NdisFddiRingIsolated = 1, + NdisFddiRingNonOperational, + NdisFddiRingOperational, + NdisFddiRingDetect, + NdisFddiRingNonOperationalDup, + NdisFddiRingOperationalDup, + NdisFddiRingDirected, + NdisFddiRingTrace +} NDIS_FDDI_RING_MGT_STATE, *PNDIS_FDDI_RING_MGT_STATE; + +// +// Defines the Lconnection state for FDDI (OID_FDDI_LCONNECTION_STATE). +// +typedef enum _NDIS_FDDI_LCONNECTION_STATE { + NdisFddiStateOff = 1, + NdisFddiStateBreak, + NdisFddiStateTrace, + NdisFddiStateConnect, + NdisFddiStateNext, + NdisFddiStateSignal, + NdisFddiStateJoin, + NdisFddiStateVerify, + NdisFddiStateActive, + NdisFddiStateMaintenance +} NDIS_FDDI_LCONNECTION_STATE, *PNDIS_FDDI_LCONNECTION_STATE; + +// +// Defines the medium subtypes for WAN medium (OID_WAN_MEDIUM_SUBTYPE). +// +typedef enum _NDIS_WAN_MEDIUM_SUBTYPE { + NdisWanMediumHub, + NdisWanMediumX_25, + NdisWanMediumIsdn, + NdisWanMediumSerial, + NdisWanMediumFrameRelay, + NdisWanMediumAtm, + NdisWanMediumSonet, + NdisWanMediumSW56K +} NDIS_WAN_MEDIUM_SUBTYPE, *PNDIS_WAN_MEDIUM_SUBTYPE; + +// +// Defines the header format for WAN medium (OID_WAN_HEADER_FORMAT). +// +typedef enum _NDIS_WAN_HEADER_FORMAT { + NdisWanHeaderNative, // src/dest based on subtype, followed by NLPID + NdisWanHeaderEthernet // emulation of ethernet header +} NDIS_WAN_HEADER_FORMAT, *PNDIS_WAN_HEADER_FORMAT; + +// +// Defines the line quality on a WAN line (OID_WAN_QUALITY_OF_SERVICE). +// +typedef enum _NDIS_WAN_QUALITY { + NdisWanRaw, + NdisWanErrorControl, + NdisWanReliable +} NDIS_WAN_QUALITY, *PNDIS_WAN_QUALITY; + +// +// Defines the state of a token-ring adapter (OID_802_5_CURRENT_RING_STATE). +// +typedef enum _NDIS_802_5_RING_STATE { + NdisRingStateOpened = 1, + NdisRingStateClosed, + NdisRingStateOpening, + NdisRingStateClosing, + NdisRingStateOpenFailure, + NdisRingStateRingFailure +} NDIS_802_5_RING_STATE, *PNDIS_802_5_RING_STATE; + +// +// Defines the state of the LAN media +// +typedef enum _NDIS_MEDIA_STATE { + NdisMediaStateConnected, + NdisMediaStateDisconnected +} NDIS_MEDIA_STATE, *PNDIS_MEDIA_STATE; + +// +// The following is set on a per-packet basis as OOB data with NdisClass802_3Priority +// +typedef ULONG Priority_802_3; // 0-7 priority levels +// +// The following structure is used to query OID_GEN_CO_LINK_SPEED and +// OID_GEN_CO_MINIMUM_LINK_SPEED. The first OID will return the current +// link speed of the adapter. The second will return the minimum link speed +// the adapter is capable of. +// + +typedef struct _NDIS_CO_LINK_SPEED { + ULONG Outbound; + ULONG Inbound; +} NDIS_CO_LINK_SPEED, + +*PNDIS_CO_LINK_SPEED; +// +// Ndis Packet Filter Bits (OID_GEN_CURRENT_PACKET_FILTER). +// +#define NDIS_PACKET_TYPE_DIRECTED 0x0001 +#define NDIS_PACKET_TYPE_MULTICAST 0x0002 +#define NDIS_PACKET_TYPE_ALL_MULTICAST 0x0004 +#define NDIS_PACKET_TYPE_BROADCAST 0x0008 +#define NDIS_PACKET_TYPE_SOURCE_ROUTING 0x0010 +#define NDIS_PACKET_TYPE_PROMISCUOUS 0x0020 +#define NDIS_PACKET_TYPE_SMT 0x0040 +#define NDIS_PACKET_TYPE_ALL_LOCAL 0x0080 +#define NDIS_PACKET_TYPE_MAC_FRAME 0x8000 +#define NDIS_PACKET_TYPE_FUNCTIONAL 0x4000 +#define NDIS_PACKET_TYPE_ALL_FUNCTIONAL 0x2000 +#define NDIS_PACKET_TYPE_GROUP 0x1000 +// +// Ndis Token-Ring Ring Status Codes (OID_802_5_CURRENT_RING_STATUS). +// +#define NDIS_RING_SIGNAL_LOSS 0x00008000 +#define NDIS_RING_HARD_ERROR 0x00004000 +#define NDIS_RING_SOFT_ERROR 0x00002000 +#define NDIS_RING_TRANSMIT_BEACON 0x00001000 +#define NDIS_RING_LOBE_WIRE_FAULT 0x00000800 +#define NDIS_RING_AUTO_REMOVAL_ERROR 0x00000400 +#define NDIS_RING_REMOVE_RECEIVED 0x00000200 +#define NDIS_RING_COUNTER_OVERFLOW 0x00000100 +#define NDIS_RING_SINGLE_STATION 0x00000080 +#define NDIS_RING_RING_RECOVERY 0x00000040 +// +// Ndis protocol option bits (OID_GEN_PROTOCOL_OPTIONS). +// +#define NDIS_PROT_OPTION_ESTIMATED_LENGTH 0x00000001 +#define NDIS_PROT_OPTION_NO_LOOPBACK 0x00000002 +#define NDIS_PROT_OPTION_NO_RSVD_ON_RCVPKT 0x00000004 +// +// Ndis MAC option bits (OID_GEN_MAC_OPTIONS). +// +#define NDIS_MAC_OPTION_COPY_LOOKAHEAD_DATA 0x00000001 +#define NDIS_MAC_OPTION_RECEIVE_SERIALIZED 0x00000002 +#define NDIS_MAC_OPTION_TRANSFERS_NOT_PEND 0x00000004 +#define NDIS_MAC_OPTION_NO_LOOPBACK 0x00000008 +#define NDIS_MAC_OPTION_FULL_DUPLEX 0x00000010 +#define NDIS_MAC_OPTION_EOTX_INDICATION 0x00000020 +#define NDIS_MAC_OPTION_RESERVED 0x80000000 +// +// NDIS MAC option bits for OID_GEN_CO_MAC_OPTIONS. +// +#define NDIS_CO_MAC_OPTION_DYNAMIC_LINK_SPEED 0x00000001 +#ifdef IRDA +// +// The following is set on a per-packet basis as OOB data with NdisClassIrdaPacketInfo +// This is the per-packet info specified on a per-packet basis +// +typedef struct _NDIS_IRDA_PACKET_INFO { + UINT ExtraBOFs; + UINT MinTurnAroundTime; +} NDIS_IRDA_PACKET_INFO, *PNDIS_IRDA_PACKET_INFO; + +#endif +#ifdef WIRELESS_WAN +// +// Wireless WAN structure definitions +// +// +// currently defined Wireless network subtypes +// +typedef enum _NDIS_WW_NETWORK_TYPE { + NdisWWGeneric, + NdisWWMobitex, + NdisWWPinpoint, + NdisWWCDPD, + NdisWWArdis, + NdisWWDataTAC, + NdisWWMetricom, + NdisWWGSM, + NdisWWCDMA, + NdisWWTDMA, + NdisWWAMPS, + NdisWWInmarsat, + NdisWWpACT +} NDIS_WW_NETWORK_TYPE; + +// +// currently defined header formats +// +typedef enum _NDIS_WW_HEADER_FORMAT { + NdisWWDIXEthernetFrames, + NdisWWMPAKFrames, + NdisWWRDLAPFrames, + NdisWWMDC4800Frames +} NDIS_WW_HEADER_FORMAT; + +// +// currently defined encryption types +// +typedef enum _NDIS_WW_ENCRYPTION_TYPE { + NdisWWUnknownEncryption = -1, + NdisWWNoEncryption, + NdisWWDefaultEncryption +} NDIS_WW_ENCRYPTION_TYPE, *PNDIS_WW_ENCRYPTION_TYPE; + +// +// OID_WW_GEN_INDICATION_REQUEST +// +typedef struct _NDIS_WW_INDICATION_REQUEST { + NDIS_OID Oid; // IN + + UINT uIndicationFlag; // IN + + UINT uApplicationToken; // IN OUT + + HANDLE hIndicationHandle; // IN OUT + + INT iPollingInterval; // IN OUT + + NDIS_VAR_DATA_DESC InitialValue; // IN OUT + + NDIS_VAR_DATA_DESC OIDIndicationValue; // OUT - only valid after indication + + NDIS_VAR_DATA_DESC TriggerValue; // IN + +} NDIS_WW_INDICATION_REQUEST, *PNDIS_WW_INDICATION_REQUEST; + +#define OID_INDICATION_REQUEST_ENABLE 0x0000 +#define OID_INDICATION_REQUEST_CANCEL 0x0001 +// +// OID_WW_GEN_DEVICE_INFO +// +typedef struct _WW_DEVICE_INFO { + NDIS_VAR_DATA_DESC Manufacturer; + NDIS_VAR_DATA_DESC ModelNum; + NDIS_VAR_DATA_DESC SWVersionNum; + NDIS_VAR_DATA_DESC SerialNum; +} WW_DEVICE_INFO, *PWW_DEVICE_INFO; + +// +// OID_WW_GEN_OPERATION_MODE +// +typedef INT WW_OPERATION_MODE; // 0 = Normal mode + // 1 = Power saving mode + // -1 = mode unknown +// +// OID_WW_GEN_LOCK_STATUS +// + +typedef INT WW_LOCK_STATUS; // 0 = unlocked + // 1 = locked + // -1 = unknown lock status +// +// OID_WW_GEN_DISABLE_TRANSMITTER +// + +typedef INT WW_DISABLE_TRANSMITTER; // 0 = transmitter enabled + // 1 = transmitter disabled + // -1 = unknown value +// +// OID_WW_GEN_NETWORK_ID +// + +typedef NDIS_VAR_DATA_DESC WW_NETWORK_ID; +// +// OID_WW_GEN_PERMANENT_ADDRESS +// +typedef NDIS_VAR_DATA_DESC WW_PERMANENT_ADDRESS; +// +// OID_WW_GEN_CURRENT_ADDRESS +// +typedef struct _WW_CURRENT_ADDRESS { + NDIS_WW_HEADER_FORMAT Format; + NDIS_VAR_DATA_DESC Address; +} WW_CURRENT_ADDRESS, *PWW_CURRENT_ADDRESS; + +// +// OID_WW_GEN_SUSPEND_DRIVER +// +typedef BOOLEAN WW_SUSPEND_DRIVER; // 0 = driver operational + // 1 = driver suspended +// +// OID_WW_GEN_BASESTATION_ID +// + +typedef NDIS_VAR_DATA_DESC WW_BASESTATION_ID; +// +// OID_WW_GEN_CHANNEL_ID +// +typedef NDIS_VAR_DATA_DESC WW_CHANNEL_ID; +// +// OID_WW_GEN_ENCRYPTION_STATE +// +typedef BOOLEAN WW_ENCRYPTION_STATE; // 0 = if encryption is disabled + // 1 = if encryption is enabled +// +// OID_WW_GEN_CHANNEL_QUALITY +// + +typedef INT WW_CHANNEL_QUALITY; // 0 = Not in network contact, + // 1-100 = Quality of Channel (100 is highest quality). + // -1 = channel quality is unknown +// +// OID_WW_GEN_REGISTRATION_STATUS +// + +typedef INT WW_REGISTRATION_STATUS; // 0 = Registration denied + // 1 = Registration pending + // 2 = Registered + // -1 = unknown registration status +// +// OID_WW_GEN_RADIO_LINK_SPEED +// + +typedef UINT WW_RADIO_LINK_SPEED; // Bits per second. +// +// OID_WW_GEN_LATENCY +// + +typedef UINT WW_LATENCY; // milliseconds +// +// OID_WW_GEN_BATTERY_LEVEL +// + +typedef INT WW_BATTERY_LEVEL; // 0-100 = battery level in percentage + // (100=fully charged) + // -1 = unknown battery level. +// +// OID_WW_GEN_EXTERNAL_POWER +// + +typedef INT WW_EXTERNAL_POWER; // 0 = no external power connected + // 1 = external power connected + // -1 = unknown +// +// OID_WW_MET_FUNCTION +// + +typedef NDIS_VAR_DATA_DESC WW_MET_FUNCTION; +// +// OID_WW_TAC_COMPRESSION +// +typedef BOOLEAN WW_TAC_COMPRESSION; // Determines whether or not network level compression + // is being used. +// +// OID_WW_TAC_SET_CONFIG +// + +typedef struct _WW_TAC_SETCONFIG { + NDIS_VAR_DATA_DESC RCV_MODE; + NDIS_VAR_DATA_DESC TX_CONTROL; + NDIS_VAR_DATA_DESC RX_CONTROL; + NDIS_VAR_DATA_DESC FLOW_CONTROL; + NDIS_VAR_DATA_DESC RESET_CNF; + NDIS_VAR_DATA_DESC READ_CNF; +} WW_TAC_SETCONFIG, *PWW_TAC_SETCONFIG; + +// +// OID_WW_TAC_GET_STATUS +// +typedef struct _WW_TAC_GETSTATUS { + BOOLEAN Action; // Set = Execute command. + + NDIS_VAR_DATA_DESC Command; + NDIS_VAR_DATA_DESC Option; + NDIS_VAR_DATA_DESC Response; // The response to the requested command + // - max. length of string is 256 octets. + +} WW_TAC_GETSTATUS, *PWW_TAC_GETSTATUS; + +// +// OID_WW_TAC_USER_HEADER +// +typedef NDIS_VAR_DATA_DESC WW_TAC_USERHEADER; // This will hold the user header - Max. 64 octets. +// +// OID_WW_ARD_SNDCP +// + +typedef struct _WW_ARD_SNDCP { + NDIS_VAR_DATA_DESC Version; // The version of SNDCP protocol supported. + + INT BlockSize; // The block size used for SNDCP + + INT Window; // The window size used in SNDCP + +} WW_ARD_SNDCP, *PWW_ARD_SNDCP; + +// +// OID_WW_ARD_TMLY_MSG +// +typedef BOOLEAN WW_ARD_CHANNEL_STATUS; // The current status of the inbound RF Channel. +// +// OID_WW_ARD_DATAGRAM +// + +typedef struct _WW_ARD_DATAGRAM { + BOOLEAN LoadLevel; // Byte that contains the load level info. + + INT SessionTime; // Datagram session time remaining. + + NDIS_VAR_DATA_DESC HostAddr; // Host address. + + NDIS_VAR_DATA_DESC THostAddr; // Test host address. + +} WW_ARD_DATAGRAM, *PWW_ARD_DATAGRAM; + +// +// OID_WW_CDPD_SPNI +// +typedef struct _WW_CDPD_SPNI { + UINT SPNI[10]; //10 16-bit service provider network IDs + + INT OperatingMode; // 0 = ignore SPNI, + // 1 = require SPNI from list, + // 2 = prefer SPNI from list. + // 3 = exclude SPNI from list. + +} WW_CDPD_SPNI, *PWW_CDPD_SPNI; + +// +// OID_WW_CDPD_WASI +// +typedef struct _WW_CDPD_WIDE_AREA_SERVICE_ID { + UINT WASI[10]; //10 16-bit wide area service IDs + + INT OperatingMode; // 0 = ignore WASI, + // 1 = Require WASI from list, + // 2 = prefer WASI from list + // 3 = exclude WASI from list. + +} WW_CDPD_WIDE_AREA_SERVICE_ID, *PWW_CDPD_WIDE_AREA_SERVICE_ID; + +// +// OID_WW_CDPD_AREA_COLOR +// +typedef INT WW_CDPD_AREA_COLOR; +// +// OID_WW_CDPD_TX_POWER_LEVEL +// +typedef UINT WW_CDPD_TX_POWER_LEVEL; +// +// OID_WW_CDPD_EID +// +typedef NDIS_VAR_DATA_DESC WW_CDPD_EID; +// +// OID_WW_CDPD_HEADER_COMPRESSION +// +typedef INT WW_CDPD_HEADER_COMPRESSION; // 0 = no header compression, + // 1 = always compress headers, + // 2 = compress headers if MD-IS does + // -1 = unknown +// +// OID_WW_CDPD_DATA_COMPRESSION +// + +typedef INT WW_CDPD_DATA_COMPRESSION; // 0 = no data compression, + // 1 = data compression enabled + // -1 = unknown +// +// OID_WW_CDPD_CHANNEL_SELECT +// + +typedef struct _WW_CDPD_CHANNEL_SELECT { + UINT ChannelID; // channel number + + UINT fixedDuration; // duration in seconds + +} WW_CDPD_CHANNEL_SELECT, *PWW_CDPD_CHANNEL_SELECT; + +// +// OID_WW_CDPD_CHANNEL_STATE +// +typedef enum _WW_CDPD_CHANNEL_STATE { + CDPDChannelNotAvail, + CDPDChannelScanning, + CDPDChannelInitAcquired, + CDPDChannelAcquired, + CDPDChannelSleeping, + CDPDChannelWaking, + CDPDChannelCSDialing, + CDPDChannelCSRedial, + CDPDChannelCSAnswering, + CDPDChannelCSConnected, + CDPDChannelCSSuspended +} WW_CDPD_CHANNEL_STATE, *PWW_CDPD_CHANNEL_STATE; + +// +// OID_WW_CDPD_NEI +// +typedef enum _WW_CDPD_NEI_FORMAT { + CDPDNeiIPv4, + CDPDNeiCLNP, + CDPDNeiIPv6 +} WW_CDPD_NEI_FORMAT, *PWW_CDPD_NEI_FORMAT; +typedef enum _WW_CDPD_NEI_TYPE { + CDPDNeiIndividual, + CDPDNeiMulticast, + CDPDNeiBroadcast +} WW_CDPD_NEI_TYPE; +typedef struct _WW_CDPD_NEI { + UINT uNeiIndex; + WW_CDPD_NEI_FORMAT NeiFormat; + WW_CDPD_NEI_TYPE NeiType; + WORD NeiGmid; // group member identifier, only + // meaningful if NeiType == + // CDPDNeiMulticast + + NDIS_VAR_DATA_DESC NeiAddress; +} WW_CDPD_NEI; + +// +// OID_WW_CDPD_NEI_STATE +// +typedef enum _WW_CDPD_NEI_STATE { + CDPDUnknown, + CDPDRegistered, + CDPDDeregistered +} WW_CDPD_NEI_STATE, *PWW_CDPD_NEI_STATE; +typedef enum _WW_CDPD_NEI_SUB_STATE { + CDPDPending, // Registration pending + CDPDNoReason, // Registration denied - no reason given + CDPDMDISNotCapable, // Registration denied - MD-IS not capable of + // handling M-ES at this time + CDPDNEINotAuthorized, // Registration denied - NEI is not authorized to + // use this subnetwork + CDPDInsufficientAuth, // Registration denied - M-ES gave insufficient + // authentication credentials + CDPDUnsupportedAuth, // Registration denied - M-ES gave unsupported + // authentication credentials + CDPDUsageExceeded, // Registration denied - NEI has exceeded usage + // limitations + CDPDDeniedThisNetwork // Registration denied on this network, service + // may be obtained on alternate Service Provider + // network +} WW_CDPD_NEI_SUB_STATE; +typedef struct _WW_CDPD_NEI_REG_STATE { + UINT uNeiIndex; + WW_CDPD_NEI_STATE NeiState; + WW_CDPD_NEI_SUB_STATE NeiSubState; +} WW_CDPD_NEI_REG_STATE, *PWW_CDPD_NEI_REG_STATE; + +// +// OID_WW_CDPD_SERVICE_PROVIDER_IDENTIFIER +// +typedef struct _WW_CDPD_SERVICE_PROVIDER_ID { + UINT SPI[10]; //10 16-bit service provider IDs + + INT OperatingMode; // 0 = ignore SPI, + // 1 = require SPI from list, + // 2 = prefer SPI from list. + // 3 = exclude SPI from list. + +} WW_CDPD_SERVICE_PROVIDER_ID, *PWW_CDPD_SERVICE_PROVIDER_ID; + +// +// OID_WW_CDPD_SLEEP_MODE +// +typedef INT WW_CDPD_SLEEP_MODE; +// +// OID_WW_CDPD_TEI +// +typedef ULONG WW_CDPD_TEI; +// +// OID_WW_CDPD_CIRCUIT_SWITCHED +// +typedef struct _WW_CDPD_CIRCUIT_SWITCHED { + INT service_preference; // -1 = unknown, + // 0 = always use packet switched CDPD, + // 1 = always use CS CDPD via AMPS, + // 2 = always use CS CDPD via PSTN, + // 3 = use circuit switched via AMPS only + // when packet switched is not available. + // 4 = use packet switched only when circuit + // switched via AMPS is not available. + // 5 = device manuf. defined service + // preference. + // 6 = device manuf. defined service + // preference. + + INT service_status; // -1 = unknown, + // 0 = packet switched CDPD, + // 1 = circuit switched CDPD via AMPS, + // 2 = circuit switched CDPD via PSTN. + + INT connect_rate; // CS connection bit rate (bits per second). + // 0 = no active connection, + // -1 = unknown + // Dial code last used to dial. + + NDIS_VAR_DATA_DESC dial_code[20]; + + UINT sid; // Current AMPS system ID + + INT a_b_side_selection; // -1 = unknown, + // 0 = no AMPS service + // 1 = AMPS "A" side channels selected + // 2 = AMPS "B" side channels selected + + INT AMPS_channel; // -1= unknown + // 0 = no AMPS service. + // 1-1023 = AMPS channel number in use + + UINT action; // 0 = no action + // 1 = suspend (hangup) + // 2 = dial + + // Default dial code for CS CDPD service + // encoded as specified in the CS CDPD + // implementor guidelines. + NDIS_VAR_DATA_DESC default_dial[20]; + + // Number for the CS CDPD network to call + // back the mobile, encoded as specified in + // the CS CDPD implementor guidelines. + NDIS_VAR_DATA_DESC call_back[20]; + + UINT sid_list[10]; // List of 10 16-bit preferred AMPS + // system IDs for CS CDPD. + + UINT inactivity_timer; // Wait time after last data before dropping + // call. + // 0-65535 = inactivity time limit (seconds). + + UINT receive_timer; // secs. per CS-CDPD Implementor Guidelines. + + UINT conn_resp_timer; // secs. per CS-CDPD Implementor Guidelines. + + UINT reconn_resp_timer; // secs. per CS-CDPD Implementor Guidelines. + + UINT disconn_timer; // secs. per CS-CDPD Implementor Guidelines. + + UINT NEI_reg_timer; // secs. per CS-CDPD Implementor Guidelines. + + UINT reconn_retry_timer; // secs. per CS-CDPD Implementor Guidelines. + + UINT link_reset_timer; // secs. per CS-CDPD Implementor Guidelines. + + UINT link_reset_ack_timer; // secs. per CS-CDPD Implementor Guidelines. + + UINT n401_retry_limit; // per CS-CDPD Implementor Guidelines. + + UINT n402_retry_limit; // per CS-CDPD Implementor Guidelines. + + UINT n404_retry_limit; // per CS-CDPD Implementor Guidelines. + + UINT n405_retry_limit; // per CS-CDPD Implementor Guidelines. + +} WW_CDPD_CIRCUIT_SWITCHED, *WW_PCDPD_CIRCUIT_SWITCHED; +typedef UINT WW_CDPD_RSSI; +// +// OID_WW_PIN_LOC_AUTHORIZE +// +typedef INT WW_PIN_AUTHORIZED; // 0 = unauthorized + // 1 = authorized + // -1 = unknown +// +// OID_WW_PIN_LAST_LOCATION +// OID_WW_PIN_LOC_FIX +// + +typedef struct _WW_PIN_LOCATION { + INT Latitude; // Latitude in hundredths of a second + + INT Longitude; // Longitude in hundredths of a second + + INT Altitude; // Altitude in feet + + INT FixTime; // Time of the location fix, since midnight, local time (of the + // current day), in tenths of a second + + INT NetTime; // Current local network time of the current day, since midnight, + // in tenths of a second + + INT LocQuality; // 0-100 = location quality + + INT LatReg; // Latitude registration offset, in hundredths of a second + + INT LongReg; // Longitude registration offset, in hundredths of a second + + INT GMTOffset; // Offset in minutes of the local time zone from GMT + +} WW_PIN_LOCATION, *PWW_PIN_LOCATION; + +// +// The following is set on a per-packet basis as OOB data with NdisClassWirelessWanMbxMailbox +// +typedef ULONG WW_MBX_MAILBOX_FLAG; // 1 = set mailbox flag, 0 = do not set mailbox flag +// +// OID_WW_MBX_SUBADDR +// + +typedef struct _WW_MBX_PMAN { + BOOLEAN ACTION; // 0 = Login PMAN, 1 = Logout PMAN + + UINT MAN; + UCHAR PASSWORD[8]; // Password should be null for Logout and indications. + // Maximum length of password is 8 chars. + +} WW_MBX_PMAN, *PWW_MBX_PMAN; + +// +// OID_WW_MBX_FLEXLIST +// +typedef struct _WW_MBX_FLEXLIST { + INT count; // Number of MAN entries used. + // -1=unknown. + + UINT MAN[7]; // List of MANs. + +} WW_MBX_FLEXLIST; + +// +// OID_WW_MBX_GROUPLIST +// +typedef struct _WW_MBX_GROUPLIST { + INT count; // Number of MAN entries used. + // -1=unknown. + + UINT MAN[15]; // List of MANs. + +} WW_MBX_GROUPLIST; + +// +// OID_WW_MBX_TRAFFIC_AREA +// +typedef enum _WW_MBX_TRAFFIC_AREA { + unknown_traffic_area, // The driver has no information about the current traffic area. + in_traffic_area, // Mobile unit has entered a subscribed traffic area. + in_auth_traffic_area, // Mobile unit is outside traffic area but is authorized. + unauth_traffic_area // Mobile unit is outside traffic area but is un-authorized. +} WW_MBX_TRAFFIC_AREA; + +// +// OID_WW_MBX_LIVE_DIE +// +typedef INT WW_MBX_LIVE_DIE; // 0 = DIE last received + // 1 = LIVE last received + // -1 = unknown +// +// OID_WW_MBX_TEMP_DEFAULTLIST +// + +typedef struct _WW_MBX_CHANNEL_PAIR { + UINT Mobile_Tx; + UINT Mobile_Rx; +} WW_MBX_CHANNEL_PAIR, *PWW_MBX_CHANNEL_PAIR; +typedef struct _WW_MBX_TEMPDEFAULTLIST { + UINT Length; + WW_MBX_CHANNEL_PAIR ChannelPair[1]; +} WW_MBX_TEMPDEFAULTLIST, *WW_PMBX_TEMPDEFAULTLIST; + +#endif // WIRELESS_WAN +#endif // _NTDDNDIS_ diff --git a/desmume/src/windows/winpcap/Ntddpack.h b/src/windows/winpcap/Ntddpack.h similarity index 97% rename from desmume/src/windows/winpcap/Ntddpack.h rename to src/windows/winpcap/Ntddpack.h index 87eac60ed..30945c1ef 100644 --- a/desmume/src/windows/winpcap/Ntddpack.h +++ b/src/windows/winpcap/Ntddpack.h @@ -1,26 +1,26 @@ - -#ifndef __NTDDPACKET -#define __NTDDPACKET 1 -#include "devioctl.h" -/*#include */ -struct _PACKET_OID_DATA { - ULONG Oid; - ULONG Length; - UCHAR Data[1]; -}; - -typedef struct _PACKET_OID_DATA PACKET_OID_DATA, *PPACKET_OID_DATA; - -/*#include */ -#define FILE_DEVICE_PROTOCOL 0x8000 -#define IOCTL_PROTOCOL_QUERY_OID CTL_CODE(FILE_DEVICE_PROTOCOL, 0 , METHOD_BUFFERED, FILE_ANY_ACCESS) -#define IOCTL_PROTOCOL_SET_OID CTL_CODE(FILE_DEVICE_PROTOCOL, 1 , METHOD_BUFFERED, FILE_ANY_ACCESS) -#define IOCTL_PROTOCOL_STATISTICS CTL_CODE(FILE_DEVICE_PROTOCOL, 2 , METHOD_BUFFERED, FILE_ANY_ACCESS) -#define IOCTL_PROTOCOL_RESET CTL_CODE(FILE_DEVICE_PROTOCOL, 3 , METHOD_BUFFERED, FILE_ANY_ACCESS) -#define IOCTL_PROTOCOL_READ CTL_CODE(FILE_DEVICE_PROTOCOL, 4 , METHOD_BUFFERED, FILE_ANY_ACCESS) -#define IOCTL_PROTOCOL_WRITE CTL_CODE(FILE_DEVICE_PROTOCOL, 5 , METHOD_BUFFERED, FILE_ANY_ACCESS) -#define IOCTL_PROTOCOL_MACNAME CTL_CODE(FILE_DEVICE_PROTOCOL, 6 , METHOD_BUFFERED, FILE_ANY_ACCESS) -#define IOCTL_OPEN CTL_CODE(FILE_DEVICE_PROTOCOL, 7 , METHOD_BUFFERED, FILE_ANY_ACCESS) -#define IOCTL_CLOSE CTL_CODE(FILE_DEVICE_PROTOCOL, 8 , METHOD_BUFFERED, FILE_ANY_ACCESS) - -#endif + +#ifndef __NTDDPACKET +#define __NTDDPACKET 1 +#include "devioctl.h" +/*#include */ +struct _PACKET_OID_DATA { + ULONG Oid; + ULONG Length; + UCHAR Data[1]; +}; + +typedef struct _PACKET_OID_DATA PACKET_OID_DATA, *PPACKET_OID_DATA; + +/*#include */ +#define FILE_DEVICE_PROTOCOL 0x8000 +#define IOCTL_PROTOCOL_QUERY_OID CTL_CODE(FILE_DEVICE_PROTOCOL, 0 , METHOD_BUFFERED, FILE_ANY_ACCESS) +#define IOCTL_PROTOCOL_SET_OID CTL_CODE(FILE_DEVICE_PROTOCOL, 1 , METHOD_BUFFERED, FILE_ANY_ACCESS) +#define IOCTL_PROTOCOL_STATISTICS CTL_CODE(FILE_DEVICE_PROTOCOL, 2 , METHOD_BUFFERED, FILE_ANY_ACCESS) +#define IOCTL_PROTOCOL_RESET CTL_CODE(FILE_DEVICE_PROTOCOL, 3 , METHOD_BUFFERED, FILE_ANY_ACCESS) +#define IOCTL_PROTOCOL_READ CTL_CODE(FILE_DEVICE_PROTOCOL, 4 , METHOD_BUFFERED, FILE_ANY_ACCESS) +#define IOCTL_PROTOCOL_WRITE CTL_CODE(FILE_DEVICE_PROTOCOL, 5 , METHOD_BUFFERED, FILE_ANY_ACCESS) +#define IOCTL_PROTOCOL_MACNAME CTL_CODE(FILE_DEVICE_PROTOCOL, 6 , METHOD_BUFFERED, FILE_ANY_ACCESS) +#define IOCTL_OPEN CTL_CODE(FILE_DEVICE_PROTOCOL, 7 , METHOD_BUFFERED, FILE_ANY_ACCESS) +#define IOCTL_CLOSE CTL_CODE(FILE_DEVICE_PROTOCOL, 8 , METHOD_BUFFERED, FILE_ANY_ACCESS) + +#endif diff --git a/desmume/src/windows/winpcap/Packet.lib b/src/windows/winpcap/Packet.lib similarity index 100% rename from desmume/src/windows/winpcap/Packet.lib rename to src/windows/winpcap/Packet.lib diff --git a/desmume/src/windows/winpcap/Packet32.h b/src/windows/winpcap/Packet32.h similarity index 98% rename from desmume/src/windows/winpcap/Packet32.h rename to src/windows/winpcap/Packet32.h index 2d989b99f..04630a0ee 100644 --- a/desmume/src/windows/winpcap/Packet32.h +++ b/src/windows/winpcap/Packet32.h @@ -1,405 +1,405 @@ -/* - * Copyright (c) 1999 - 2005 NetGroup, Politecnico di Torino (Italy) - * Copyright (c) 2005 - 2006 CACE Technologies, Davis (California) - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * 3. Neither the name of the Politecnico di Torino, CACE Technologies - * nor the names of its contributors may be used to endorse or promote - * products derived from this software without specific prior written - * permission. - * - * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS - * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT - * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR - * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT - * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, - * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY - * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT - * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE - * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * - */ - -/** @ingroup packetapi - * @{ - */ - -/** @defgroup packet32h Packet.dll definitions and data structures - * Packet32.h contains the data structures and the definitions used by packet.dll. - * The file is used both by the Win9x and the WinNTx versions of packet.dll, and can be included - * by the applications that use the functions of this library - * @{ - */ - -#ifndef __PACKET32 -#define __PACKET32 - -#include - -#include "devioctl.h" - -#ifdef HAVE_AIRPCAP_API -#include -#else -#if !defined(AIRPCAP_HANDLE__EAE405F5_0171_9592_B3C2_C19EC426AD34__DEFINED_) -#define AIRPCAP_HANDLE__EAE405F5_0171_9592_B3C2_C19EC426AD34__DEFINED_ -typedef struct _AirpcapHandle *PAirpcapHandle; -#endif /* AIRPCAP_HANDLE__EAE405F5_0171_9592_B3C2_C19EC426AD34__DEFINED_ */ -#endif /* HAVE_AIRPCAP_API */ - -#ifdef HAVE_DAG_API -#include -#endif /* HAVE_DAG_API */ - -// Working modes -#define PACKET_MODE_CAPT 0x0 ///< Capture mode -#define PACKET_MODE_STAT 0x1 ///< Statistical mode -#define PACKET_MODE_MON 0x2 ///< Monitoring mode -#define PACKET_MODE_DUMP 0x10 ///< Dump mode -#define PACKET_MODE_STAT_DUMP MODE_DUMP | MODE_STAT ///< Statistical dump Mode - -// ioctls -#define FILE_DEVICE_PROTOCOL 0x8000 - -#define IOCTL_PROTOCOL_STATISTICS CTL_CODE(FILE_DEVICE_PROTOCOL, 2 , METHOD_BUFFERED, FILE_ANY_ACCESS) -#define IOCTL_PROTOCOL_RESET CTL_CODE(FILE_DEVICE_PROTOCOL, 3 , METHOD_BUFFERED, FILE_ANY_ACCESS) -#define IOCTL_PROTOCOL_READ CTL_CODE(FILE_DEVICE_PROTOCOL, 4 , METHOD_BUFFERED, FILE_ANY_ACCESS) -#define IOCTL_PROTOCOL_WRITE CTL_CODE(FILE_DEVICE_PROTOCOL, 5 , METHOD_BUFFERED, FILE_ANY_ACCESS) -#define IOCTL_PROTOCOL_MACNAME CTL_CODE(FILE_DEVICE_PROTOCOL, 6 , METHOD_BUFFERED, FILE_ANY_ACCESS) -#define IOCTL_OPEN CTL_CODE(FILE_DEVICE_PROTOCOL, 7 , METHOD_BUFFERED, FILE_ANY_ACCESS) -#define IOCTL_CLOSE CTL_CODE(FILE_DEVICE_PROTOCOL, 8 , METHOD_BUFFERED, FILE_ANY_ACCESS) - -#define pBIOCSETBUFFERSIZE 9592 ///< IOCTL code: set kernel buffer size. -#define pBIOCSETF 9030 ///< IOCTL code: set packet filtering program. -#define pBIOCGSTATS 9031 ///< IOCTL code: get the capture stats. -#define pBIOCSRTIMEOUT 7416 ///< IOCTL code: set the read timeout. -#define pBIOCSMODE 7412 ///< IOCTL code: set working mode. -#define pBIOCSWRITEREP 7413 ///< IOCTL code: set number of physical repetions of every packet written by the app. -#define pBIOCSMINTOCOPY 7414 ///< IOCTL code: set minimum amount of data in the kernel buffer that unlocks a read call. -#define pBIOCSETOID 2147483648U ///< IOCTL code: set an OID value. -#define pBIOCQUERYOID 2147483652U ///< IOCTL code: get an OID value. -#define pATTACHPROCESS 7117 ///< IOCTL code: attach a process to the driver. Used in Win9x only. -#define pDETACHPROCESS 7118 ///< IOCTL code: detach a process from the driver. Used in Win9x only. -#define pBIOCSETDUMPFILENAME 9029 ///< IOCTL code: set the name of a the file used by kernel dump mode. -#define pBIOCEVNAME 7415 ///< IOCTL code: get the name of the event that the driver signals when some data is present in the buffer. -#define pBIOCSENDPACKETSNOSYNC 9032 ///< IOCTL code: Send a buffer containing multiple packets to the network, ignoring the timestamps associated with the packets. -#define pBIOCSENDPACKETSSYNC 9033 ///< IOCTL code: Send a buffer containing multiple packets to the network, respecting the timestamps associated with the packets. -#define pBIOCSETDUMPLIMITS 9034 ///< IOCTL code: Set the dump file limits. See the PacketSetDumpLimits() function. -#define pBIOCISDUMPENDED 7411 ///< IOCTL code: Get the status of the kernel dump process. See the PacketIsDumpEnded() function. -#define pBIOCISETLOBBEH 7410 ///< IOCTL code: Set the loopback behavior of the driver with packets sent by itself: capture or drop. -#define pBIOCSETEVENTHANDLE 7920 ///< IOCTL code: Passes the read event HANDLE allocated by the user (packet.dll) to the kernel level driver. - -#define pBIOCSTIMEZONE 7471 ///< IOCTL code: set time zone. Used in Win9x only. - - -/// Alignment macro. Defines the alignment size. -#define Packet_ALIGNMENT sizeof(int) -/// Alignment macro. Rounds up to the next even multiple of Packet_ALIGNMENT. -#define Packet_WORDALIGN(x) (((x)+(Packet_ALIGNMENT-1))&~(Packet_ALIGNMENT-1)) - -#define NdisMediumNull -1 ///< Custom linktype: NDIS doesn't provide an equivalent -#define NdisMediumCHDLC -2 ///< Custom linktype: NDIS doesn't provide an equivalent -#define NdisMediumPPPSerial -3 ///< Custom linktype: NDIS doesn't provide an equivalent -#define NdisMediumBare80211 -4 ///< Custom linktype: NDIS doesn't provide an equivalent -#define NdisMediumRadio80211 -5 ///< Custom linktype: NDIS doesn't provide an equivalent - -// Loopback behaviour definitions -#define NPF_DISABLE_LOOPBACK 1 ///< Drop the packets sent by the NPF driver -#define NPF_ENABLE_LOOPBACK 2 ///< Capture the packets sent by the NPF driver - -/*! - \brief Network type structure. - - This structure is used by the PacketGetNetType() function to return information on the current adapter's type and speed. -*/ -typedef struct NetType -{ - UINT LinkType; ///< The MAC of the current network adapter (see function PacketGetNetType() for more information) - ULONGLONG LinkSpeed; ///< The speed of the network in bits per second -}NetType; - - -//some definitions stolen from libpcap - -#ifndef BPF_MAJOR_VERSION - -/*! - \brief A BPF pseudo-assembly program. - - The program will be injected in the kernel by the PacketSetBPF() function and applied to every incoming packet. -*/ -struct bpf_program -{ - UINT bf_len; ///< Indicates the number of instructions of the program, i.e. the number of struct bpf_insn that will follow. - struct bpf_insn *bf_insns; ///< A pointer to the first instruction of the program. -}; - -/*! - \brief A single BPF pseudo-instruction. - - bpf_insn contains a single instruction for the BPF register-machine. It is used to send a filter program to the driver. -*/ -struct bpf_insn -{ - USHORT code; ///< Instruction type and addressing mode. - UCHAR jt; ///< Jump if true - UCHAR jf; ///< Jump if false - int k; ///< Generic field used for various purposes. -}; - -/*! - \brief Structure that contains a couple of statistics values on the current capture. - - It is used by packet.dll to return statistics about a capture session. -*/ -struct bpf_stat -{ - UINT bs_recv; ///< Number of packets that the driver received from the network adapter - ///< from the beginning of the current capture. This value includes the packets - ///< lost by the driver. - UINT bs_drop; ///< number of packets that the driver lost from the beginning of a capture. - ///< Basically, a packet is lost when the the buffer of the driver is full. - ///< In this situation the packet cannot be stored and the driver rejects it. - UINT ps_ifdrop; ///< drops by interface. XXX not yet supported - UINT bs_capt; ///< number of packets that pass the filter, find place in the kernel buffer and - ///< thus reach the application. -}; - -/*! - \brief Packet header. - - This structure defines the header associated with every packet delivered to the application. -*/ -struct bpf_hdr -{ - struct timeval bh_tstamp; ///< The timestamp associated with the captured packet. - ///< It is stored in a TimeVal structure. - UINT bh_caplen; ///< Length of captured portion. The captured portion can be different - ///< from the original packet, because it is possible (with a proper filter) - ///< to instruct the driver to capture only a portion of the packets. - UINT bh_datalen; ///< Original length of packet - USHORT bh_hdrlen; ///< Length of bpf header (this struct plus alignment padding). In some cases, - ///< a padding could be added between the end of this structure and the packet - ///< data for performance reasons. This filed can be used to retrieve the actual data - ///< of the packet. -}; - -/*! - \brief Dump packet header. - - This structure defines the header associated with the packets in a buffer to be used with PacketSendPackets(). - It is simpler than the bpf_hdr, because it corresponds to the header associated by WinPcap and libpcap to a - packet in a dump file. This makes straightforward sending WinPcap dump files to the network. -*/ -struct dump_bpf_hdr{ - struct timeval ts; ///< Time stamp of the packet - UINT caplen; ///< Length of captured portion. The captured portion can smaller than the - ///< the original packet, because it is possible (with a proper filter) to - ///< instruct the driver to capture only a portion of the packets. - UINT len; ///< Length of the original packet (off wire). -}; - - -#endif - -struct bpf_stat; - -#define DOSNAMEPREFIX TEXT("Packet_") ///< Prefix added to the adapters device names to create the WinPcap devices -#define MAX_LINK_NAME_LENGTH 64 //< Maximum length of the devices symbolic links -#define NMAX_PACKET 65535 - -/*! - \brief Addresses of a network adapter. - - This structure is used by the PacketGetNetInfoEx() function to return the IP addresses associated with - an adapter. -*/ -typedef struct npf_if_addr { - struct sockaddr_storage IPAddress; ///< IP address. - struct sockaddr_storage SubnetMask; ///< Netmask for that address. - struct sockaddr_storage Broadcast; ///< Broadcast address. -}npf_if_addr; - - -#define ADAPTER_NAME_LENGTH 256 + 12 ///< Maximum length for the name of an adapter. The value is the same used by the IP Helper API. -#define ADAPTER_DESC_LENGTH 128 ///< Maximum length for the description of an adapter. The value is the same used by the IP Helper API. -#define MAX_MAC_ADDR_LENGTH 8 ///< Maximum length for the link layer address of an adapter. The value is the same used by the IP Helper API. -#define MAX_NETWORK_ADDRESSES 16 ///< Maximum length for the link layer address of an adapter. The value is the same used by the IP Helper API. - - -typedef struct WAN_ADAPTER_INT WAN_ADAPTER; ///< Describes an opened wan (dialup, VPN...) network adapter using the NetMon API -typedef WAN_ADAPTER *PWAN_ADAPTER; ///< Describes an opened wan (dialup, VPN...) network adapter using the NetMon API - -#define INFO_FLAG_NDIS_ADAPTER 0 ///< Flag for ADAPTER_INFO: this is a traditional ndis adapter -#define INFO_FLAG_NDISWAN_ADAPTER 1 ///< Flag for ADAPTER_INFO: this is a NdisWan adapter, and it's managed by WANPACKET -#define INFO_FLAG_DAG_CARD 2 ///< Flag for ADAPTER_INFO: this is a DAG card -#define INFO_FLAG_DAG_FILE 6 ///< Flag for ADAPTER_INFO: this is a DAG file -#define INFO_FLAG_DONT_EXPORT 8 ///< Flag for ADAPTER_INFO: when this flag is set, the adapter will not be listed or openend by winpcap. This allows to prevent exporting broken network adapters, like for example FireWire ones. -#define INFO_FLAG_AIRPCAP_CARD 16 ///< Flag for ADAPTER_INFO: this is an airpcap card -#define INFO_FLAG_NPFIM_DEVICE 32 -/*! - \brief Contains comprehensive information about a network adapter. - - This structure is filled with all the accessory information that the user can need about an adapter installed - on his system. -*/ -typedef struct _ADAPTER_INFO -{ - struct _ADAPTER_INFO *Next; ///< Pointer to the next adapter in the list. - CHAR Name[ADAPTER_NAME_LENGTH + 1]; ///< Name of the device representing the adapter. - CHAR Description[ADAPTER_DESC_LENGTH + 1]; ///< Human understandable description of the adapter - UINT MacAddressLen; ///< Length of the link layer address. - UCHAR MacAddress[MAX_MAC_ADDR_LENGTH]; ///< Link layer address. - NetType LinkLayer; ///< Physical characteristics of this adapter. This NetType structure contains the link type and the speed of the adapter. - INT NNetworkAddresses; ///< Number of network layer addresses of this adapter. - npf_if_addr *NetworkAddresses; ///< Pointer to an array of npf_if_addr, each of which specifies a network address of this adapter. - UINT Flags; ///< Adapter's flags. Tell if this adapter must be treated in a different way, using the Netmon API or the dagc API. -} -ADAPTER_INFO, *PADAPTER_INFO; - -/*! - \brief Describes an opened network adapter. - - This structure is the most important for the functioning of packet.dll, but the great part of its fields - should be ignored by the user, since the library offers functions that avoid to cope with low-level parameters -*/ -typedef struct _ADAPTER { - HANDLE hFile; ///< \internal Handle to an open instance of the NPF driver. - CHAR SymbolicLink[MAX_LINK_NAME_LENGTH]; ///< \internal A string containing the name of the network adapter currently opened. - int NumWrites; ///< \internal Number of times a packets written on this adapter will be repeated - ///< on the wire. - HANDLE ReadEvent; ///< A notification event associated with the read calls on the adapter. - ///< It can be passed to standard Win32 functions (like WaitForSingleObject - ///< or WaitForMultipleObjects) to wait until the driver's buffer contains some - ///< data. It is particularly useful in GUI applications that need to wait - ///< concurrently on several events. In Windows NT/2000 the PacketSetMinToCopy() - ///< function can be used to define the minimum amount of data in the kernel buffer - ///< that will cause the event to be signalled. - - UINT ReadTimeOut; ///< \internal The amount of time after which a read on the driver will be released and - ///< ReadEvent will be signaled, also if no packets were captured - CHAR Name[ADAPTER_NAME_LENGTH]; - PWAN_ADAPTER pWanAdapter; - UINT Flags; ///< Adapter's flags. Tell if this adapter must be treated in a different way, using the Netmon API or the dagc API. - -#ifdef HAVE_AIRPCAP_API - PAirpcapHandle AirpcapAd; -#endif // HAVE_AIRPCAP_API - -#ifdef HAVE_NPFIM_API - void* NpfImHandle; -#endif // HAVE_NPFIM_API - -#ifdef HAVE_DAG_API - dagc_t *pDagCard; ///< Pointer to the dagc API adapter descriptor for this adapter - PCHAR DagBuffer; ///< Pointer to the buffer with the packets that is received from the DAG card - struct timeval DagReadTimeout; ///< Read timeout. The dagc API requires a timeval structure - unsigned DagFcsLen; ///< Length of the frame check sequence attached to any packet by the card. Obtained from the registry - DWORD DagFastProcess; ///< True if the user requests fast capture processing on this card. Higher level applications can use this value to provide a faster but possibly unprecise capture (for example, libpcap doesn't convert the timestamps). -#endif // HAVE_DAG_API -} ADAPTER, *LPADAPTER; - -/*! - \brief Structure that contains a group of packets coming from the driver. - - This structure defines the header associated with every packet delivered to the application. -*/ -typedef struct _PACKET { - HANDLE hEvent; ///< \deprecated Still present for compatibility with old applications. - OVERLAPPED OverLapped; ///< \deprecated Still present for compatibility with old applications. - PVOID Buffer; ///< Buffer with containing the packets. See the PacketReceivePacket() for - ///< details about the organization of the data in this buffer - UINT Length; ///< Length of the buffer - DWORD ulBytesReceived; ///< Number of valid bytes present in the buffer, i.e. amount of data - ///< received by the last call to PacketReceivePacket() - BOOLEAN bIoComplete; ///< \deprecated Still present for compatibility with old applications. -} PACKET, *LPPACKET; - -/*! - \brief Structure containing an OID request. - - It is used by the PacketRequest() function to send an OID to the interface card driver. - It can be used, for example, to retrieve the status of the error counters on the adapter, its MAC address, - the list of the multicast groups defined on it, and so on. -*/ -struct _PACKET_OID_DATA { - ULONG Oid; ///< OID code. See the Microsoft DDK documentation or the file ntddndis.h - ///< for a complete list of valid codes. - ULONG Length; ///< Length of the data field - UCHAR Data[1]; ///< variable-lenght field that contains the information passed to or received - ///< from the adapter. -}; -typedef struct _PACKET_OID_DATA PACKET_OID_DATA, *PPACKET_OID_DATA; - -#ifdef __cplusplus -extern "C" { -#endif - -/** - * @} - */ - -/* -BOOLEAN QueryWinPcapRegistryStringA(CHAR *SubKeyName, - CHAR *Value, - UINT *pValueLen, - CHAR *DefaultVal); - -BOOLEAN QueryWinPcapRegistryStringW(WCHAR *SubKeyName, - WCHAR *Value, - UINT *pValueLen, - WCHAR *DefaultVal); -*/ - -//--------------------------------------------------------------------------- -// EXPORTED FUNCTIONS -//--------------------------------------------------------------------------- - -PCHAR PacketGetVersion(); -PCHAR PacketGetDriverVersion(); -BOOLEAN PacketSetMinToCopy(LPADAPTER AdapterObject,int nbytes); -BOOLEAN PacketSetNumWrites(LPADAPTER AdapterObject,int nwrites); -BOOLEAN PacketSetMode(LPADAPTER AdapterObject,int mode); -BOOLEAN PacketSetReadTimeout(LPADAPTER AdapterObject,int timeout); -BOOLEAN PacketSetBpf(LPADAPTER AdapterObject,struct bpf_program *fp); -BOOLEAN PacketSetLoopbackBehavior(LPADAPTER AdapterObject, UINT LoopbackBehavior); -INT PacketSetSnapLen(LPADAPTER AdapterObject,int snaplen); -BOOLEAN PacketGetStats(LPADAPTER AdapterObject,struct bpf_stat *s); -BOOLEAN PacketGetStatsEx(LPADAPTER AdapterObject,struct bpf_stat *s); -BOOLEAN PacketSetBuff(LPADAPTER AdapterObject,int dim); -BOOLEAN PacketGetNetType (LPADAPTER AdapterObject,NetType *type); -LPADAPTER PacketOpenAdapter(PCHAR AdapterName); -BOOLEAN PacketSendPacket(LPADAPTER AdapterObject,LPPACKET pPacket,BOOLEAN Sync); -INT PacketSendPackets(LPADAPTER AdapterObject,PVOID PacketBuff,ULONG Size, BOOLEAN Sync); -LPPACKET PacketAllocatePacket(void); -VOID PacketInitPacket(LPPACKET lpPacket,PVOID Buffer,UINT Length); -VOID PacketFreePacket(LPPACKET lpPacket); -BOOLEAN PacketReceivePacket(LPADAPTER AdapterObject,LPPACKET lpPacket,BOOLEAN Sync); -BOOLEAN PacketSetHwFilter(LPADAPTER AdapterObject,ULONG Filter); -BOOLEAN PacketGetAdapterNames(PTSTR pStr,PULONG BufferSize); -BOOLEAN PacketGetNetInfoEx(PCHAR AdapterName, npf_if_addr* buffer, PLONG NEntries); -BOOLEAN PacketRequest(LPADAPTER AdapterObject,BOOLEAN Set,PPACKET_OID_DATA OidData); -HANDLE PacketGetReadEvent(LPADAPTER AdapterObject); -BOOLEAN PacketSetDumpName(LPADAPTER AdapterObject, void *name, int len); -BOOLEAN PacketSetDumpLimits(LPADAPTER AdapterObject, UINT maxfilesize, UINT maxnpacks); -BOOLEAN PacketIsDumpEnded(LPADAPTER AdapterObject, BOOLEAN sync); -BOOL PacketStopDriver(); -VOID PacketCloseAdapter(LPADAPTER lpAdapter); -BOOLEAN PacketStartOem(PCHAR errorString, UINT errorStringLength); -PAirpcapHandle PacketGetAirPcapHandle(LPADAPTER AdapterObject); -#ifdef __cplusplus -} -#endif - -#endif //__PACKET32 +/* + * Copyright (c) 1999 - 2005 NetGroup, Politecnico di Torino (Italy) + * Copyright (c) 2005 - 2006 CACE Technologies, Davis (California) + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. Neither the name of the Politecnico di Torino, CACE Technologies + * nor the names of its contributors may be used to endorse or promote + * products derived from this software without specific prior written + * permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR + * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT + * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE + * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ + +/** @ingroup packetapi + * @{ + */ + +/** @defgroup packet32h Packet.dll definitions and data structures + * Packet32.h contains the data structures and the definitions used by packet.dll. + * The file is used both by the Win9x and the WinNTx versions of packet.dll, and can be included + * by the applications that use the functions of this library + * @{ + */ + +#ifndef __PACKET32 +#define __PACKET32 + +#include + +#include "devioctl.h" + +#ifdef HAVE_AIRPCAP_API +#include +#else +#if !defined(AIRPCAP_HANDLE__EAE405F5_0171_9592_B3C2_C19EC426AD34__DEFINED_) +#define AIRPCAP_HANDLE__EAE405F5_0171_9592_B3C2_C19EC426AD34__DEFINED_ +typedef struct _AirpcapHandle *PAirpcapHandle; +#endif /* AIRPCAP_HANDLE__EAE405F5_0171_9592_B3C2_C19EC426AD34__DEFINED_ */ +#endif /* HAVE_AIRPCAP_API */ + +#ifdef HAVE_DAG_API +#include +#endif /* HAVE_DAG_API */ + +// Working modes +#define PACKET_MODE_CAPT 0x0 ///< Capture mode +#define PACKET_MODE_STAT 0x1 ///< Statistical mode +#define PACKET_MODE_MON 0x2 ///< Monitoring mode +#define PACKET_MODE_DUMP 0x10 ///< Dump mode +#define PACKET_MODE_STAT_DUMP MODE_DUMP | MODE_STAT ///< Statistical dump Mode + +// ioctls +#define FILE_DEVICE_PROTOCOL 0x8000 + +#define IOCTL_PROTOCOL_STATISTICS CTL_CODE(FILE_DEVICE_PROTOCOL, 2 , METHOD_BUFFERED, FILE_ANY_ACCESS) +#define IOCTL_PROTOCOL_RESET CTL_CODE(FILE_DEVICE_PROTOCOL, 3 , METHOD_BUFFERED, FILE_ANY_ACCESS) +#define IOCTL_PROTOCOL_READ CTL_CODE(FILE_DEVICE_PROTOCOL, 4 , METHOD_BUFFERED, FILE_ANY_ACCESS) +#define IOCTL_PROTOCOL_WRITE CTL_CODE(FILE_DEVICE_PROTOCOL, 5 , METHOD_BUFFERED, FILE_ANY_ACCESS) +#define IOCTL_PROTOCOL_MACNAME CTL_CODE(FILE_DEVICE_PROTOCOL, 6 , METHOD_BUFFERED, FILE_ANY_ACCESS) +#define IOCTL_OPEN CTL_CODE(FILE_DEVICE_PROTOCOL, 7 , METHOD_BUFFERED, FILE_ANY_ACCESS) +#define IOCTL_CLOSE CTL_CODE(FILE_DEVICE_PROTOCOL, 8 , METHOD_BUFFERED, FILE_ANY_ACCESS) + +#define pBIOCSETBUFFERSIZE 9592 ///< IOCTL code: set kernel buffer size. +#define pBIOCSETF 9030 ///< IOCTL code: set packet filtering program. +#define pBIOCGSTATS 9031 ///< IOCTL code: get the capture stats. +#define pBIOCSRTIMEOUT 7416 ///< IOCTL code: set the read timeout. +#define pBIOCSMODE 7412 ///< IOCTL code: set working mode. +#define pBIOCSWRITEREP 7413 ///< IOCTL code: set number of physical repetions of every packet written by the app. +#define pBIOCSMINTOCOPY 7414 ///< IOCTL code: set minimum amount of data in the kernel buffer that unlocks a read call. +#define pBIOCSETOID 2147483648U ///< IOCTL code: set an OID value. +#define pBIOCQUERYOID 2147483652U ///< IOCTL code: get an OID value. +#define pATTACHPROCESS 7117 ///< IOCTL code: attach a process to the driver. Used in Win9x only. +#define pDETACHPROCESS 7118 ///< IOCTL code: detach a process from the driver. Used in Win9x only. +#define pBIOCSETDUMPFILENAME 9029 ///< IOCTL code: set the name of a the file used by kernel dump mode. +#define pBIOCEVNAME 7415 ///< IOCTL code: get the name of the event that the driver signals when some data is present in the buffer. +#define pBIOCSENDPACKETSNOSYNC 9032 ///< IOCTL code: Send a buffer containing multiple packets to the network, ignoring the timestamps associated with the packets. +#define pBIOCSENDPACKETSSYNC 9033 ///< IOCTL code: Send a buffer containing multiple packets to the network, respecting the timestamps associated with the packets. +#define pBIOCSETDUMPLIMITS 9034 ///< IOCTL code: Set the dump file limits. See the PacketSetDumpLimits() function. +#define pBIOCISDUMPENDED 7411 ///< IOCTL code: Get the status of the kernel dump process. See the PacketIsDumpEnded() function. +#define pBIOCISETLOBBEH 7410 ///< IOCTL code: Set the loopback behavior of the driver with packets sent by itself: capture or drop. +#define pBIOCSETEVENTHANDLE 7920 ///< IOCTL code: Passes the read event HANDLE allocated by the user (packet.dll) to the kernel level driver. + +#define pBIOCSTIMEZONE 7471 ///< IOCTL code: set time zone. Used in Win9x only. + + +/// Alignment macro. Defines the alignment size. +#define Packet_ALIGNMENT sizeof(int) +/// Alignment macro. Rounds up to the next even multiple of Packet_ALIGNMENT. +#define Packet_WORDALIGN(x) (((x)+(Packet_ALIGNMENT-1))&~(Packet_ALIGNMENT-1)) + +#define NdisMediumNull -1 ///< Custom linktype: NDIS doesn't provide an equivalent +#define NdisMediumCHDLC -2 ///< Custom linktype: NDIS doesn't provide an equivalent +#define NdisMediumPPPSerial -3 ///< Custom linktype: NDIS doesn't provide an equivalent +#define NdisMediumBare80211 -4 ///< Custom linktype: NDIS doesn't provide an equivalent +#define NdisMediumRadio80211 -5 ///< Custom linktype: NDIS doesn't provide an equivalent + +// Loopback behaviour definitions +#define NPF_DISABLE_LOOPBACK 1 ///< Drop the packets sent by the NPF driver +#define NPF_ENABLE_LOOPBACK 2 ///< Capture the packets sent by the NPF driver + +/*! + \brief Network type structure. + + This structure is used by the PacketGetNetType() function to return information on the current adapter's type and speed. +*/ +typedef struct NetType +{ + UINT LinkType; ///< The MAC of the current network adapter (see function PacketGetNetType() for more information) + ULONGLONG LinkSpeed; ///< The speed of the network in bits per second +}NetType; + + +//some definitions stolen from libpcap + +#ifndef BPF_MAJOR_VERSION + +/*! + \brief A BPF pseudo-assembly program. + + The program will be injected in the kernel by the PacketSetBPF() function and applied to every incoming packet. +*/ +struct bpf_program +{ + UINT bf_len; ///< Indicates the number of instructions of the program, i.e. the number of struct bpf_insn that will follow. + struct bpf_insn *bf_insns; ///< A pointer to the first instruction of the program. +}; + +/*! + \brief A single BPF pseudo-instruction. + + bpf_insn contains a single instruction for the BPF register-machine. It is used to send a filter program to the driver. +*/ +struct bpf_insn +{ + USHORT code; ///< Instruction type and addressing mode. + UCHAR jt; ///< Jump if true + UCHAR jf; ///< Jump if false + int k; ///< Generic field used for various purposes. +}; + +/*! + \brief Structure that contains a couple of statistics values on the current capture. + + It is used by packet.dll to return statistics about a capture session. +*/ +struct bpf_stat +{ + UINT bs_recv; ///< Number of packets that the driver received from the network adapter + ///< from the beginning of the current capture. This value includes the packets + ///< lost by the driver. + UINT bs_drop; ///< number of packets that the driver lost from the beginning of a capture. + ///< Basically, a packet is lost when the the buffer of the driver is full. + ///< In this situation the packet cannot be stored and the driver rejects it. + UINT ps_ifdrop; ///< drops by interface. XXX not yet supported + UINT bs_capt; ///< number of packets that pass the filter, find place in the kernel buffer and + ///< thus reach the application. +}; + +/*! + \brief Packet header. + + This structure defines the header associated with every packet delivered to the application. +*/ +struct bpf_hdr +{ + struct timeval bh_tstamp; ///< The timestamp associated with the captured packet. + ///< It is stored in a TimeVal structure. + UINT bh_caplen; ///< Length of captured portion. The captured portion can be different + ///< from the original packet, because it is possible (with a proper filter) + ///< to instruct the driver to capture only a portion of the packets. + UINT bh_datalen; ///< Original length of packet + USHORT bh_hdrlen; ///< Length of bpf header (this struct plus alignment padding). In some cases, + ///< a padding could be added between the end of this structure and the packet + ///< data for performance reasons. This filed can be used to retrieve the actual data + ///< of the packet. +}; + +/*! + \brief Dump packet header. + + This structure defines the header associated with the packets in a buffer to be used with PacketSendPackets(). + It is simpler than the bpf_hdr, because it corresponds to the header associated by WinPcap and libpcap to a + packet in a dump file. This makes straightforward sending WinPcap dump files to the network. +*/ +struct dump_bpf_hdr{ + struct timeval ts; ///< Time stamp of the packet + UINT caplen; ///< Length of captured portion. The captured portion can smaller than the + ///< the original packet, because it is possible (with a proper filter) to + ///< instruct the driver to capture only a portion of the packets. + UINT len; ///< Length of the original packet (off wire). +}; + + +#endif + +struct bpf_stat; + +#define DOSNAMEPREFIX TEXT("Packet_") ///< Prefix added to the adapters device names to create the WinPcap devices +#define MAX_LINK_NAME_LENGTH 64 //< Maximum length of the devices symbolic links +#define NMAX_PACKET 65535 + +/*! + \brief Addresses of a network adapter. + + This structure is used by the PacketGetNetInfoEx() function to return the IP addresses associated with + an adapter. +*/ +typedef struct npf_if_addr { + struct sockaddr_storage IPAddress; ///< IP address. + struct sockaddr_storage SubnetMask; ///< Netmask for that address. + struct sockaddr_storage Broadcast; ///< Broadcast address. +}npf_if_addr; + + +#define ADAPTER_NAME_LENGTH 256 + 12 ///< Maximum length for the name of an adapter. The value is the same used by the IP Helper API. +#define ADAPTER_DESC_LENGTH 128 ///< Maximum length for the description of an adapter. The value is the same used by the IP Helper API. +#define MAX_MAC_ADDR_LENGTH 8 ///< Maximum length for the link layer address of an adapter. The value is the same used by the IP Helper API. +#define MAX_NETWORK_ADDRESSES 16 ///< Maximum length for the link layer address of an adapter. The value is the same used by the IP Helper API. + + +typedef struct WAN_ADAPTER_INT WAN_ADAPTER; ///< Describes an opened wan (dialup, VPN...) network adapter using the NetMon API +typedef WAN_ADAPTER *PWAN_ADAPTER; ///< Describes an opened wan (dialup, VPN...) network adapter using the NetMon API + +#define INFO_FLAG_NDIS_ADAPTER 0 ///< Flag for ADAPTER_INFO: this is a traditional ndis adapter +#define INFO_FLAG_NDISWAN_ADAPTER 1 ///< Flag for ADAPTER_INFO: this is a NdisWan adapter, and it's managed by WANPACKET +#define INFO_FLAG_DAG_CARD 2 ///< Flag for ADAPTER_INFO: this is a DAG card +#define INFO_FLAG_DAG_FILE 6 ///< Flag for ADAPTER_INFO: this is a DAG file +#define INFO_FLAG_DONT_EXPORT 8 ///< Flag for ADAPTER_INFO: when this flag is set, the adapter will not be listed or openend by winpcap. This allows to prevent exporting broken network adapters, like for example FireWire ones. +#define INFO_FLAG_AIRPCAP_CARD 16 ///< Flag for ADAPTER_INFO: this is an airpcap card +#define INFO_FLAG_NPFIM_DEVICE 32 +/*! + \brief Contains comprehensive information about a network adapter. + + This structure is filled with all the accessory information that the user can need about an adapter installed + on his system. +*/ +typedef struct _ADAPTER_INFO +{ + struct _ADAPTER_INFO *Next; ///< Pointer to the next adapter in the list. + CHAR Name[ADAPTER_NAME_LENGTH + 1]; ///< Name of the device representing the adapter. + CHAR Description[ADAPTER_DESC_LENGTH + 1]; ///< Human understandable description of the adapter + UINT MacAddressLen; ///< Length of the link layer address. + UCHAR MacAddress[MAX_MAC_ADDR_LENGTH]; ///< Link layer address. + NetType LinkLayer; ///< Physical characteristics of this adapter. This NetType structure contains the link type and the speed of the adapter. + INT NNetworkAddresses; ///< Number of network layer addresses of this adapter. + npf_if_addr *NetworkAddresses; ///< Pointer to an array of npf_if_addr, each of which specifies a network address of this adapter. + UINT Flags; ///< Adapter's flags. Tell if this adapter must be treated in a different way, using the Netmon API or the dagc API. +} +ADAPTER_INFO, *PADAPTER_INFO; + +/*! + \brief Describes an opened network adapter. + + This structure is the most important for the functioning of packet.dll, but the great part of its fields + should be ignored by the user, since the library offers functions that avoid to cope with low-level parameters +*/ +typedef struct _ADAPTER { + HANDLE hFile; ///< \internal Handle to an open instance of the NPF driver. + CHAR SymbolicLink[MAX_LINK_NAME_LENGTH]; ///< \internal A string containing the name of the network adapter currently opened. + int NumWrites; ///< \internal Number of times a packets written on this adapter will be repeated + ///< on the wire. + HANDLE ReadEvent; ///< A notification event associated with the read calls on the adapter. + ///< It can be passed to standard Win32 functions (like WaitForSingleObject + ///< or WaitForMultipleObjects) to wait until the driver's buffer contains some + ///< data. It is particularly useful in GUI applications that need to wait + ///< concurrently on several events. In Windows NT/2000 the PacketSetMinToCopy() + ///< function can be used to define the minimum amount of data in the kernel buffer + ///< that will cause the event to be signalled. + + UINT ReadTimeOut; ///< \internal The amount of time after which a read on the driver will be released and + ///< ReadEvent will be signaled, also if no packets were captured + CHAR Name[ADAPTER_NAME_LENGTH]; + PWAN_ADAPTER pWanAdapter; + UINT Flags; ///< Adapter's flags. Tell if this adapter must be treated in a different way, using the Netmon API or the dagc API. + +#ifdef HAVE_AIRPCAP_API + PAirpcapHandle AirpcapAd; +#endif // HAVE_AIRPCAP_API + +#ifdef HAVE_NPFIM_API + void* NpfImHandle; +#endif // HAVE_NPFIM_API + +#ifdef HAVE_DAG_API + dagc_t *pDagCard; ///< Pointer to the dagc API adapter descriptor for this adapter + PCHAR DagBuffer; ///< Pointer to the buffer with the packets that is received from the DAG card + struct timeval DagReadTimeout; ///< Read timeout. The dagc API requires a timeval structure + unsigned DagFcsLen; ///< Length of the frame check sequence attached to any packet by the card. Obtained from the registry + DWORD DagFastProcess; ///< True if the user requests fast capture processing on this card. Higher level applications can use this value to provide a faster but possibly unprecise capture (for example, libpcap doesn't convert the timestamps). +#endif // HAVE_DAG_API +} ADAPTER, *LPADAPTER; + +/*! + \brief Structure that contains a group of packets coming from the driver. + + This structure defines the header associated with every packet delivered to the application. +*/ +typedef struct _PACKET { + HANDLE hEvent; ///< \deprecated Still present for compatibility with old applications. + OVERLAPPED OverLapped; ///< \deprecated Still present for compatibility with old applications. + PVOID Buffer; ///< Buffer with containing the packets. See the PacketReceivePacket() for + ///< details about the organization of the data in this buffer + UINT Length; ///< Length of the buffer + DWORD ulBytesReceived; ///< Number of valid bytes present in the buffer, i.e. amount of data + ///< received by the last call to PacketReceivePacket() + BOOLEAN bIoComplete; ///< \deprecated Still present for compatibility with old applications. +} PACKET, *LPPACKET; + +/*! + \brief Structure containing an OID request. + + It is used by the PacketRequest() function to send an OID to the interface card driver. + It can be used, for example, to retrieve the status of the error counters on the adapter, its MAC address, + the list of the multicast groups defined on it, and so on. +*/ +struct _PACKET_OID_DATA { + ULONG Oid; ///< OID code. See the Microsoft DDK documentation or the file ntddndis.h + ///< for a complete list of valid codes. + ULONG Length; ///< Length of the data field + UCHAR Data[1]; ///< variable-lenght field that contains the information passed to or received + ///< from the adapter. +}; +typedef struct _PACKET_OID_DATA PACKET_OID_DATA, *PPACKET_OID_DATA; + +#ifdef __cplusplus +extern "C" { +#endif + +/** + * @} + */ + +/* +BOOLEAN QueryWinPcapRegistryStringA(CHAR *SubKeyName, + CHAR *Value, + UINT *pValueLen, + CHAR *DefaultVal); + +BOOLEAN QueryWinPcapRegistryStringW(WCHAR *SubKeyName, + WCHAR *Value, + UINT *pValueLen, + WCHAR *DefaultVal); +*/ + +//--------------------------------------------------------------------------- +// EXPORTED FUNCTIONS +//--------------------------------------------------------------------------- + +PCHAR PacketGetVersion(); +PCHAR PacketGetDriverVersion(); +BOOLEAN PacketSetMinToCopy(LPADAPTER AdapterObject,int nbytes); +BOOLEAN PacketSetNumWrites(LPADAPTER AdapterObject,int nwrites); +BOOLEAN PacketSetMode(LPADAPTER AdapterObject,int mode); +BOOLEAN PacketSetReadTimeout(LPADAPTER AdapterObject,int timeout); +BOOLEAN PacketSetBpf(LPADAPTER AdapterObject,struct bpf_program *fp); +BOOLEAN PacketSetLoopbackBehavior(LPADAPTER AdapterObject, UINT LoopbackBehavior); +INT PacketSetSnapLen(LPADAPTER AdapterObject,int snaplen); +BOOLEAN PacketGetStats(LPADAPTER AdapterObject,struct bpf_stat *s); +BOOLEAN PacketGetStatsEx(LPADAPTER AdapterObject,struct bpf_stat *s); +BOOLEAN PacketSetBuff(LPADAPTER AdapterObject,int dim); +BOOLEAN PacketGetNetType (LPADAPTER AdapterObject,NetType *type); +LPADAPTER PacketOpenAdapter(PCHAR AdapterName); +BOOLEAN PacketSendPacket(LPADAPTER AdapterObject,LPPACKET pPacket,BOOLEAN Sync); +INT PacketSendPackets(LPADAPTER AdapterObject,PVOID PacketBuff,ULONG Size, BOOLEAN Sync); +LPPACKET PacketAllocatePacket(void); +VOID PacketInitPacket(LPPACKET lpPacket,PVOID Buffer,UINT Length); +VOID PacketFreePacket(LPPACKET lpPacket); +BOOLEAN PacketReceivePacket(LPADAPTER AdapterObject,LPPACKET lpPacket,BOOLEAN Sync); +BOOLEAN PacketSetHwFilter(LPADAPTER AdapterObject,ULONG Filter); +BOOLEAN PacketGetAdapterNames(PTSTR pStr,PULONG BufferSize); +BOOLEAN PacketGetNetInfoEx(PCHAR AdapterName, npf_if_addr* buffer, PLONG NEntries); +BOOLEAN PacketRequest(LPADAPTER AdapterObject,BOOLEAN Set,PPACKET_OID_DATA OidData); +HANDLE PacketGetReadEvent(LPADAPTER AdapterObject); +BOOLEAN PacketSetDumpName(LPADAPTER AdapterObject, void *name, int len); +BOOLEAN PacketSetDumpLimits(LPADAPTER AdapterObject, UINT maxfilesize, UINT maxnpacks); +BOOLEAN PacketIsDumpEnded(LPADAPTER AdapterObject, BOOLEAN sync); +BOOL PacketStopDriver(); +VOID PacketCloseAdapter(LPADAPTER lpAdapter); +BOOLEAN PacketStartOem(PCHAR errorString, UINT errorStringLength); +PAirpcapHandle PacketGetAirPcapHandle(LPADAPTER AdapterObject); +#ifdef __cplusplus +} +#endif + +#endif //__PACKET32 diff --git a/desmume/src/windows/winpcap/Win32-Extensions.h b/src/windows/winpcap/Win32-Extensions.h similarity index 97% rename from desmume/src/windows/winpcap/Win32-Extensions.h rename to src/windows/winpcap/Win32-Extensions.h index ad3be25cf..d3b063b0f 100644 --- a/desmume/src/windows/winpcap/Win32-Extensions.h +++ b/src/windows/winpcap/Win32-Extensions.h @@ -1,113 +1,113 @@ -/* - * Copyright (c) 1999 - 2005 NetGroup, Politecnico di Torino (Italy) - * Copyright (c) 2005 - 2006 CACE Technologies, Davis (California) - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * 3. Neither the name of the Politecnico di Torino, CACE Technologies - * nor the names of its contributors may be used to endorse or promote - * products derived from this software without specific prior written - * permission. - * - * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS - * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT - * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR - * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT - * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, - * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY - * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT - * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE - * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * - */ - -#ifndef __WIN32_EXTENSIONS_H__ -#define __WIN32_EXTENSIONS_H__ - -#ifdef __cplusplus -extern "C" { -#endif - -/* Definitions */ - -/*! - \brief A queue of raw packets that will be sent to the network with pcap_sendqueue_transmit(). -*/ -struct pcap_send_queue -{ - u_int maxlen; ///< Maximum size of the the queue, in bytes. This variable contains the size of the buffer field. - u_int len; ///< Current size of the queue, in bytes. - char *buffer; ///< Buffer containing the packets to be sent. -}; - -typedef struct pcap_send_queue pcap_send_queue; - -/*! - \brief This typedef is a support for the pcap_get_airpcap_handle() function -*/ -#if !defined(AIRPCAP_HANDLE__EAE405F5_0171_9592_B3C2_C19EC426AD34__DEFINED_) -#define AIRPCAP_HANDLE__EAE405F5_0171_9592_B3C2_C19EC426AD34__DEFINED_ -typedef struct _AirpcapHandle *PAirpcapHandle; -#endif - -#define BPF_MEM_EX_IMM 0xc0 -#define BPF_MEM_EX_IND 0xe0 - -/*used for ST*/ -#define BPF_MEM_EX 0xc0 -#define BPF_TME 0x08 - -#define BPF_LOOKUP 0x90 -#define BPF_EXECUTE 0xa0 -#define BPF_INIT 0xb0 -#define BPF_VALIDATE 0xc0 -#define BPF_SET_ACTIVE 0xd0 -#define BPF_RESET 0xe0 -#define BPF_SET_MEMORY 0x80 -#define BPF_GET_REGISTER_VALUE 0x70 -#define BPF_SET_REGISTER_VALUE 0x60 -#define BPF_SET_WORKING 0x50 -#define BPF_SET_ACTIVE_READ 0x40 -#define BPF_SET_AUTODELETION 0x30 -#define BPF_SEPARATION 0xff - -/* Prototypes */ -pcap_send_queue* pcap_sendqueue_alloc(u_int memsize); - -void pcap_sendqueue_destroy(pcap_send_queue* queue); - -int pcap_sendqueue_queue(pcap_send_queue* queue, const struct pcap_pkthdr *pkt_header, const u_char *pkt_data); - -u_int pcap_sendqueue_transmit(pcap_t *p, pcap_send_queue* queue, int sync); - -HANDLE pcap_getevent(pcap_t *p); - -struct pcap_stat *pcap_stats_ex(pcap_t *p, int *pcap_stat_size); - -int pcap_setuserbuffer(pcap_t *p, int size); - -int pcap_live_dump(pcap_t *p, char *filename, int maxsize, int maxpacks); - -int pcap_live_dump_ended(pcap_t *p, int sync); - -int pcap_offline_filter(struct bpf_program *prog, const struct pcap_pkthdr *header, const u_char *pkt_data); - -int pcap_start_oem(char* err_str, int flags); - -PAirpcapHandle pcap_get_airpcap_handle(pcap_t *p); - -#ifdef __cplusplus -} -#endif - -#endif //__WIN32_EXTENSIONS_H__ +/* + * Copyright (c) 1999 - 2005 NetGroup, Politecnico di Torino (Italy) + * Copyright (c) 2005 - 2006 CACE Technologies, Davis (California) + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. Neither the name of the Politecnico di Torino, CACE Technologies + * nor the names of its contributors may be used to endorse or promote + * products derived from this software without specific prior written + * permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR + * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT + * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE + * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ + +#ifndef __WIN32_EXTENSIONS_H__ +#define __WIN32_EXTENSIONS_H__ + +#ifdef __cplusplus +extern "C" { +#endif + +/* Definitions */ + +/*! + \brief A queue of raw packets that will be sent to the network with pcap_sendqueue_transmit(). +*/ +struct pcap_send_queue +{ + u_int maxlen; ///< Maximum size of the the queue, in bytes. This variable contains the size of the buffer field. + u_int len; ///< Current size of the queue, in bytes. + char *buffer; ///< Buffer containing the packets to be sent. +}; + +typedef struct pcap_send_queue pcap_send_queue; + +/*! + \brief This typedef is a support for the pcap_get_airpcap_handle() function +*/ +#if !defined(AIRPCAP_HANDLE__EAE405F5_0171_9592_B3C2_C19EC426AD34__DEFINED_) +#define AIRPCAP_HANDLE__EAE405F5_0171_9592_B3C2_C19EC426AD34__DEFINED_ +typedef struct _AirpcapHandle *PAirpcapHandle; +#endif + +#define BPF_MEM_EX_IMM 0xc0 +#define BPF_MEM_EX_IND 0xe0 + +/*used for ST*/ +#define BPF_MEM_EX 0xc0 +#define BPF_TME 0x08 + +#define BPF_LOOKUP 0x90 +#define BPF_EXECUTE 0xa0 +#define BPF_INIT 0xb0 +#define BPF_VALIDATE 0xc0 +#define BPF_SET_ACTIVE 0xd0 +#define BPF_RESET 0xe0 +#define BPF_SET_MEMORY 0x80 +#define BPF_GET_REGISTER_VALUE 0x70 +#define BPF_SET_REGISTER_VALUE 0x60 +#define BPF_SET_WORKING 0x50 +#define BPF_SET_ACTIVE_READ 0x40 +#define BPF_SET_AUTODELETION 0x30 +#define BPF_SEPARATION 0xff + +/* Prototypes */ +pcap_send_queue* pcap_sendqueue_alloc(u_int memsize); + +void pcap_sendqueue_destroy(pcap_send_queue* queue); + +int pcap_sendqueue_queue(pcap_send_queue* queue, const struct pcap_pkthdr *pkt_header, const u_char *pkt_data); + +u_int pcap_sendqueue_transmit(pcap_t *p, pcap_send_queue* queue, int sync); + +HANDLE pcap_getevent(pcap_t *p); + +struct pcap_stat *pcap_stats_ex(pcap_t *p, int *pcap_stat_size); + +int pcap_setuserbuffer(pcap_t *p, int size); + +int pcap_live_dump(pcap_t *p, char *filename, int maxsize, int maxpacks); + +int pcap_live_dump_ended(pcap_t *p, int sync); + +int pcap_offline_filter(struct bpf_program *prog, const struct pcap_pkthdr *header, const u_char *pkt_data); + +int pcap_start_oem(char* err_str, int flags); + +PAirpcapHandle pcap_get_airpcap_handle(pcap_t *p); + +#ifdef __cplusplus +} +#endif + +#endif //__WIN32_EXTENSIONS_H__ diff --git a/desmume/src/windows/winpcap/bittypes.h b/src/windows/winpcap/bittypes.h similarity index 96% rename from desmume/src/windows/winpcap/bittypes.h rename to src/windows/winpcap/bittypes.h index c84077af3..1a2611d84 100644 --- a/desmume/src/windows/winpcap/bittypes.h +++ b/src/windows/winpcap/bittypes.h @@ -1,135 +1,135 @@ -/* - * Copyright (C) 1999 WIDE Project. - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * 3. Neither the name of the project nor the names of its contributors - * may be used to endorse or promote products derived from this software - * without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE PROJECT AND CONTRIBUTORS ``AS IS'' AND - * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE - * ARE DISCLAIMED. IN NO EVENT SHALL THE PROJECT OR CONTRIBUTORS BE LIABLE - * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS - * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) - * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY - * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - */ -#ifndef _BITTYPES_H -#define _BITTYPES_H - -#ifndef HAVE_U_INT8_T - -#if SIZEOF_CHAR == 1 -typedef unsigned char u_int8_t; -typedef signed char int8_t; -#elif SIZEOF_INT == 1 -typedef unsigned int u_int8_t; -typedef signed int int8_t; -#else /* XXX */ -#error "there's no appropriate type for u_int8_t" -#endif -#define HAVE_U_INT8_T 1 -#define HAVE_INT8_T 1 - -#endif /* HAVE_U_INT8_T */ - -#ifndef HAVE_U_INT16_T - -#if SIZEOF_SHORT == 2 -typedef unsigned short u_int16_t; -typedef signed short int16_t; -#elif SIZEOF_INT == 2 -typedef unsigned int u_int16_t; -typedef signed int int16_t; -#elif SIZEOF_CHAR == 2 -typedef unsigned char u_int16_t; -typedef signed char int16_t; -#else /* XXX */ -#error "there's no appropriate type for u_int16_t" -#endif -#define HAVE_U_INT16_T 1 -#define HAVE_INT16_T 1 - -#endif /* HAVE_U_INT16_T */ - -#ifndef HAVE_U_INT32_T - -#if SIZEOF_INT == 4 -typedef unsigned int u_int32_t; -typedef signed int int32_t; -#elif SIZEOF_LONG == 4 -typedef unsigned long u_int32_t; -typedef signed long int32_t; -#elif SIZEOF_SHORT == 4 -typedef unsigned short u_int32_t; -typedef signed short int32_t; -#else /* XXX */ -#error "there's no appropriate type for u_int32_t" -#endif -#define HAVE_U_INT32_T 1 -#define HAVE_INT32_T 1 - -#endif /* HAVE_U_INT32_T */ - -#ifndef HAVE_U_INT64_T -#if SIZEOF_LONG_LONG == 8 -typedef unsigned long long u_int64_t; -#elif defined(_MSC_EXTENSIONS) -typedef unsigned _int64 u_int64_t; -#elif SIZEOF_INT == 8 -typedef unsigned int u_int64_t; -#elif SIZEOF_LONG == 8 -typedef unsigned long u_int64_t; -#elif SIZEOF_SHORT == 8 -typedef unsigned short u_int64_t; -#else /* XXX */ -#error "there's no appropriate type for u_int64_t" -#endif - -#endif /* HAVE_U_INT64_T */ - -#ifndef PRId64 -#ifdef _MSC_EXTENSIONS -#define PRId64 "I64d" -#else /* _MSC_EXTENSIONS */ -#define PRId64 "lld" -#endif /* _MSC_EXTENSIONS */ -#endif /* PRId64 */ - -#ifndef PRIo64 -#ifdef _MSC_EXTENSIONS -#define PRIo64 "I64o" -#else /* _MSC_EXTENSIONS */ -#define PRIo64 "llo" -#endif /* _MSC_EXTENSIONS */ -#endif /* PRIo64 */ - -#ifndef PRIx64 -#ifdef _MSC_EXTENSIONS -#define PRIx64 "I64x" -#else /* _MSC_EXTENSIONS */ -#define PRIx64 "llx" -#endif /* _MSC_EXTENSIONS */ -#endif /* PRIx64 */ - -#ifndef PRIu64 -#ifdef _MSC_EXTENSIONS -#define PRIu64 "I64u" -#else /* _MSC_EXTENSIONS */ -#define PRIu64 "llu" -#endif /* _MSC_EXTENSIONS */ -#endif /* PRIu64 */ - -#endif /* _BITTYPES_H */ +/* + * Copyright (C) 1999 WIDE Project. + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. Neither the name of the project nor the names of its contributors + * may be used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE PROJECT AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE PROJECT OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + */ +#ifndef _BITTYPES_H +#define _BITTYPES_H + +#ifndef HAVE_U_INT8_T + +#if SIZEOF_CHAR == 1 +typedef unsigned char u_int8_t; +typedef signed char int8_t; +#elif SIZEOF_INT == 1 +typedef unsigned int u_int8_t; +typedef signed int int8_t; +#else /* XXX */ +#error "there's no appropriate type for u_int8_t" +#endif +#define HAVE_U_INT8_T 1 +#define HAVE_INT8_T 1 + +#endif /* HAVE_U_INT8_T */ + +#ifndef HAVE_U_INT16_T + +#if SIZEOF_SHORT == 2 +typedef unsigned short u_int16_t; +typedef signed short int16_t; +#elif SIZEOF_INT == 2 +typedef unsigned int u_int16_t; +typedef signed int int16_t; +#elif SIZEOF_CHAR == 2 +typedef unsigned char u_int16_t; +typedef signed char int16_t; +#else /* XXX */ +#error "there's no appropriate type for u_int16_t" +#endif +#define HAVE_U_INT16_T 1 +#define HAVE_INT16_T 1 + +#endif /* HAVE_U_INT16_T */ + +#ifndef HAVE_U_INT32_T + +#if SIZEOF_INT == 4 +typedef unsigned int u_int32_t; +typedef signed int int32_t; +#elif SIZEOF_LONG == 4 +typedef unsigned long u_int32_t; +typedef signed long int32_t; +#elif SIZEOF_SHORT == 4 +typedef unsigned short u_int32_t; +typedef signed short int32_t; +#else /* XXX */ +#error "there's no appropriate type for u_int32_t" +#endif +#define HAVE_U_INT32_T 1 +#define HAVE_INT32_T 1 + +#endif /* HAVE_U_INT32_T */ + +#ifndef HAVE_U_INT64_T +#if SIZEOF_LONG_LONG == 8 +typedef unsigned long long u_int64_t; +#elif defined(_MSC_EXTENSIONS) +typedef unsigned _int64 u_int64_t; +#elif SIZEOF_INT == 8 +typedef unsigned int u_int64_t; +#elif SIZEOF_LONG == 8 +typedef unsigned long u_int64_t; +#elif SIZEOF_SHORT == 8 +typedef unsigned short u_int64_t; +#else /* XXX */ +#error "there's no appropriate type for u_int64_t" +#endif + +#endif /* HAVE_U_INT64_T */ + +#ifndef PRId64 +#ifdef _MSC_EXTENSIONS +#define PRId64 "I64d" +#else /* _MSC_EXTENSIONS */ +#define PRId64 "lld" +#endif /* _MSC_EXTENSIONS */ +#endif /* PRId64 */ + +#ifndef PRIo64 +#ifdef _MSC_EXTENSIONS +#define PRIo64 "I64o" +#else /* _MSC_EXTENSIONS */ +#define PRIo64 "llo" +#endif /* _MSC_EXTENSIONS */ +#endif /* PRIo64 */ + +#ifndef PRIx64 +#ifdef _MSC_EXTENSIONS +#define PRIx64 "I64x" +#else /* _MSC_EXTENSIONS */ +#define PRIx64 "llx" +#endif /* _MSC_EXTENSIONS */ +#endif /* PRIx64 */ + +#ifndef PRIu64 +#ifdef _MSC_EXTENSIONS +#define PRIu64 "I64u" +#else /* _MSC_EXTENSIONS */ +#define PRIu64 "llu" +#endif /* _MSC_EXTENSIONS */ +#endif /* PRIu64 */ + +#endif /* _BITTYPES_H */ diff --git a/desmume/src/windows/winpcap/bucket_lookup.h b/src/windows/winpcap/bucket_lookup.h similarity index 97% rename from desmume/src/windows/winpcap/bucket_lookup.h rename to src/windows/winpcap/bucket_lookup.h index e614e45d9..b17843694 100644 --- a/desmume/src/windows/winpcap/bucket_lookup.h +++ b/src/windows/winpcap/bucket_lookup.h @@ -1,54 +1,54 @@ -/* - * Copyright (c) 2001 - 2003 - * NetGroup, Politecnico di Torino (Italy) - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * 3. Neither the name of the Politecnico di Torino nor the names of its - * contributors may be used to endorse or promote products derived from - * this software without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS - * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT - * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR - * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT - * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, - * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY - * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT - * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE - * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * - */ - -#ifndef __bucket_lookup -#define __bucket_lookup -#ifdef WIN32 -#include "tme.h" -#endif - -#ifdef __FreeBSD__ - -#ifdef _KERNEL -#include -#else -#include -#endif - -#endif - -#define BUCKET_LOOKUP_INSERT 0x00000011 -uint32 bucket_lookup_insert(uint8 *key, TME_DATA *data, MEM_TYPE *mem_ex, struct time_conv *time_ref); -#define BUCKET_LOOKUP 0x00000010 -uint32 bucket_lookup(uint8 *key, TME_DATA *data, MEM_TYPE *mem_ex, struct time_conv *time_ref); - +/* + * Copyright (c) 2001 - 2003 + * NetGroup, Politecnico di Torino (Italy) + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. Neither the name of the Politecnico di Torino nor the names of its + * contributors may be used to endorse or promote products derived from + * this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR + * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT + * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE + * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ + +#ifndef __bucket_lookup +#define __bucket_lookup +#ifdef WIN32 +#include "tme.h" +#endif + +#ifdef __FreeBSD__ + +#ifdef _KERNEL +#include +#else +#include +#endif + +#endif + +#define BUCKET_LOOKUP_INSERT 0x00000011 +uint32 bucket_lookup_insert(uint8 *key, TME_DATA *data, MEM_TYPE *mem_ex, struct time_conv *time_ref); +#define BUCKET_LOOKUP 0x00000010 +uint32 bucket_lookup(uint8 *key, TME_DATA *data, MEM_TYPE *mem_ex, struct time_conv *time_ref); + #endif \ No newline at end of file diff --git a/desmume/src/windows/winpcap/count_packets.h b/src/windows/winpcap/count_packets.h similarity index 97% rename from desmume/src/windows/winpcap/count_packets.h rename to src/windows/winpcap/count_packets.h index 2cd1af597..9853bda34 100644 --- a/desmume/src/windows/winpcap/count_packets.h +++ b/src/windows/winpcap/count_packets.h @@ -1,62 +1,62 @@ -/* - * Copyright (c) 2001 - 2003 - * NetGroup, Politecnico di Torino (Italy) - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * 3. Neither the name of the Politecnico di Torino nor the names of its - * contributors may be used to endorse or promote products derived from - * this software without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS - * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT - * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR - * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT - * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, - * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY - * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT - * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE - * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * - */ - -#ifndef __count_packets -#define __count_packets - -#ifdef WIN32 -#include "tme.h" -#endif - -#ifdef __FreeBSD__ - -#ifdef _KERNEL -#include -#else -#include -#endif - -#endif - -typedef struct __c_p_data -{ - struct timeval timestamp; - uint64 packets; - uint64 bytes; -} - c_p_data; - -#define COUNT_PACKETS 0x00000000 -uint32 count_packets(uint8 *block, uint32 pkt_size, TME_DATA *data, MEM_TYPE *mem_ex, uint8 *mem_data); - -#endif - +/* + * Copyright (c) 2001 - 2003 + * NetGroup, Politecnico di Torino (Italy) + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. Neither the name of the Politecnico di Torino nor the names of its + * contributors may be used to endorse or promote products derived from + * this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR + * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT + * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE + * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ + +#ifndef __count_packets +#define __count_packets + +#ifdef WIN32 +#include "tme.h" +#endif + +#ifdef __FreeBSD__ + +#ifdef _KERNEL +#include +#else +#include +#endif + +#endif + +typedef struct __c_p_data +{ + struct timeval timestamp; + uint64 packets; + uint64 bytes; +} + c_p_data; + +#define COUNT_PACKETS 0x00000000 +uint32 count_packets(uint8 *block, uint32 pkt_size, TME_DATA *data, MEM_TYPE *mem_ex, uint8 *mem_data); + +#endif + diff --git a/desmume/src/windows/winpcap/ip6_misc.h b/src/windows/winpcap/ip6_misc.h similarity index 97% rename from desmume/src/windows/winpcap/ip6_misc.h rename to src/windows/winpcap/ip6_misc.h index 6ff3dd548..fb02e40a6 100644 --- a/desmume/src/windows/winpcap/ip6_misc.h +++ b/src/windows/winpcap/ip6_misc.h @@ -1,165 +1,165 @@ -/* - * Copyright (c) 1993, 1994, 1997 - * The Regents of the University of California. All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that: (1) source code distributions - * retain the above copyright notice and this paragraph in its entirety, (2) - * distributions including binary code include the above copyright notice and - * this paragraph in its entirety in the documentation or other materials - * provided with the distribution, and (3) all advertising materials mentioning - * features or use of this software display the following acknowledgement: - * ``This product includes software developed by the University of California, - * Lawrence Berkeley Laboratory and its contributors.'' Neither the name of - * the University nor the names of its contributors may be used to endorse - * or promote products derived from this software without specific prior - * written permission. - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR IMPLIED - * WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF - * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. - * - * @(#) $Header: /tcpdump/master/libpcap/Win32/Include/ip6_misc.h,v 1.4.2.1 2006/01/22 18:13:47 gianluca Exp $ (LBL) - */ - -/* - * This file contains a collage of declarations for IPv6 from FreeBSD not present in Windows - */ - -#include - -#ifndef __MINGW32__ -#include -#endif /* __MINGW32__ */ - -#ifndef __MINGW32__ -#define IN_MULTICAST(a) IN_CLASSD(a) -#endif - -#define IN_EXPERIMENTAL(a) ((((u_int32_t) (a)) & 0xf0000000) == 0xf0000000) - -#define IN_LOOPBACKNET 127 - -#ifdef __MINGW32__ -/* IPv6 address */ -struct in6_addr - { - union - { - u_int8_t u6_addr8[16]; - u_int16_t u6_addr16[8]; - u_int32_t u6_addr32[4]; - } in6_u; -#define s6_addr in6_u.u6_addr8 -#define s6_addr16 in6_u.u6_addr16 -#define s6_addr32 in6_u.u6_addr32 -#define s6_addr64 in6_u.u6_addr64 - }; - -#define IN6ADDR_ANY_INIT { 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 } -#define IN6ADDR_LOOPBACK_INIT { 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1 } -#endif /* __MINGW32__ */ - - -#if (defined WIN32) || (defined __MINGW32__) -typedef unsigned short sa_family_t; -#endif - - -#ifdef __MINGW32__ - -#define __SOCKADDR_COMMON(sa_prefix) \ - sa_family_t sa_prefix##family - -/* Ditto, for IPv6. */ -struct sockaddr_in6 - { - __SOCKADDR_COMMON (sin6_); - u_int16_t sin6_port; /* Transport layer port # */ - u_int32_t sin6_flowinfo; /* IPv6 flow information */ - struct in6_addr sin6_addr; /* IPv6 address */ - }; - -#define IN6_IS_ADDR_V4MAPPED(a) \ - ((((u_int32_t *) (a))[0] == 0) && (((u_int32_t *) (a))[1] == 0) && \ - (((u_int32_t *) (a))[2] == htonl (0xffff))) - -#define IN6_IS_ADDR_MULTICAST(a) (((u_int8_t *) (a))[0] == 0xff) - -#define IN6_IS_ADDR_LINKLOCAL(a) \ - ((((u_int32_t *) (a))[0] & htonl (0xffc00000)) == htonl (0xfe800000)) - -#define IN6_IS_ADDR_LOOPBACK(a) \ - (((u_int32_t *) (a))[0] == 0 && ((u_int32_t *) (a))[1] == 0 && \ - ((u_int32_t *) (a))[2] == 0 && ((u_int32_t *) (a))[3] == htonl (1)) -#endif /* __MINGW32__ */ - -#define ip6_vfc ip6_ctlun.ip6_un2_vfc -#define ip6_flow ip6_ctlun.ip6_un1.ip6_un1_flow -#define ip6_plen ip6_ctlun.ip6_un1.ip6_un1_plen -#define ip6_nxt ip6_ctlun.ip6_un1.ip6_un1_nxt -#define ip6_hlim ip6_ctlun.ip6_un1.ip6_un1_hlim -#define ip6_hops ip6_ctlun.ip6_un1.ip6_un1_hlim - -#define nd_rd_type nd_rd_hdr.icmp6_type -#define nd_rd_code nd_rd_hdr.icmp6_code -#define nd_rd_cksum nd_rd_hdr.icmp6_cksum -#define nd_rd_reserved nd_rd_hdr.icmp6_data32[0] - -/* - * IPV6 extension headers - */ -#define IPPROTO_HOPOPTS 0 /* IPv6 hop-by-hop options */ -#define IPPROTO_IPV6 41 /* IPv6 header. */ -#define IPPROTO_ROUTING 43 /* IPv6 routing header */ -#define IPPROTO_FRAGMENT 44 /* IPv6 fragmentation header */ -#define IPPROTO_ESP 50 /* encapsulating security payload */ -#define IPPROTO_AH 51 /* authentication header */ -#define IPPROTO_ICMPV6 58 /* ICMPv6 */ -#define IPPROTO_NONE 59 /* IPv6 no next header */ -#define IPPROTO_DSTOPTS 60 /* IPv6 destination options */ -#define IPPROTO_PIM 103 /* Protocol Independent Multicast. */ - -#define IPV6_RTHDR_TYPE_0 0 - -/* Option types and related macros */ -#define IP6OPT_PAD1 0x00 /* 00 0 00000 */ -#define IP6OPT_PADN 0x01 /* 00 0 00001 */ -#define IP6OPT_JUMBO 0xC2 /* 11 0 00010 = 194 */ -#define IP6OPT_JUMBO_LEN 6 -#define IP6OPT_ROUTER_ALERT 0x05 /* 00 0 00101 */ - -#define IP6OPT_RTALERT_LEN 4 -#define IP6OPT_RTALERT_MLD 0 /* Datagram contains an MLD message */ -#define IP6OPT_RTALERT_RSVP 1 /* Datagram contains an RSVP message */ -#define IP6OPT_RTALERT_ACTNET 2 /* contains an Active Networks msg */ -#define IP6OPT_MINLEN 2 - -#define IP6OPT_BINDING_UPDATE 0xc6 /* 11 0 00110 */ -#define IP6OPT_BINDING_ACK 0x07 /* 00 0 00111 */ -#define IP6OPT_BINDING_REQ 0x08 /* 00 0 01000 */ -#define IP6OPT_HOME_ADDRESS 0xc9 /* 11 0 01001 */ -#define IP6OPT_EID 0x8a /* 10 0 01010 */ - -#define IP6OPT_TYPE(o) ((o) & 0xC0) -#define IP6OPT_TYPE_SKIP 0x00 -#define IP6OPT_TYPE_DISCARD 0x40 -#define IP6OPT_TYPE_FORCEICMP 0x80 -#define IP6OPT_TYPE_ICMP 0xC0 - -#define IP6OPT_MUTABLE 0x20 - - -#ifdef __MINGW32__ -#ifndef EAI_ADDRFAMILY -struct addrinfo { - int ai_flags; /* AI_PASSIVE, AI_CANONNAME */ - int ai_family; /* PF_xxx */ - int ai_socktype; /* SOCK_xxx */ - int ai_protocol; /* 0 or IPPROTO_xxx for IPv4 and IPv6 */ - size_t ai_addrlen; /* length of ai_addr */ - char *ai_canonname; /* canonical name for hostname */ - struct sockaddr *ai_addr; /* binary address */ - struct addrinfo *ai_next; /* next structure in linked list */ -}; -#endif -#endif /* __MINGW32__ */ +/* + * Copyright (c) 1993, 1994, 1997 + * The Regents of the University of California. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that: (1) source code distributions + * retain the above copyright notice and this paragraph in its entirety, (2) + * distributions including binary code include the above copyright notice and + * this paragraph in its entirety in the documentation or other materials + * provided with the distribution, and (3) all advertising materials mentioning + * features or use of this software display the following acknowledgement: + * ``This product includes software developed by the University of California, + * Lawrence Berkeley Laboratory and its contributors.'' Neither the name of + * the University nor the names of its contributors may be used to endorse + * or promote products derived from this software without specific prior + * written permission. + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. + * + * @(#) $Header: /tcpdump/master/libpcap/Win32/Include/ip6_misc.h,v 1.4.2.1 2006/01/22 18:13:47 gianluca Exp $ (LBL) + */ + +/* + * This file contains a collage of declarations for IPv6 from FreeBSD not present in Windows + */ + +#include + +#ifndef __MINGW32__ +#include +#endif /* __MINGW32__ */ + +#ifndef __MINGW32__ +#define IN_MULTICAST(a) IN_CLASSD(a) +#endif + +#define IN_EXPERIMENTAL(a) ((((u_int32_t) (a)) & 0xf0000000) == 0xf0000000) + +#define IN_LOOPBACKNET 127 + +#ifdef __MINGW32__ +/* IPv6 address */ +struct in6_addr + { + union + { + u_int8_t u6_addr8[16]; + u_int16_t u6_addr16[8]; + u_int32_t u6_addr32[4]; + } in6_u; +#define s6_addr in6_u.u6_addr8 +#define s6_addr16 in6_u.u6_addr16 +#define s6_addr32 in6_u.u6_addr32 +#define s6_addr64 in6_u.u6_addr64 + }; + +#define IN6ADDR_ANY_INIT { 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 } +#define IN6ADDR_LOOPBACK_INIT { 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1 } +#endif /* __MINGW32__ */ + + +#if (defined WIN32) || (defined __MINGW32__) +typedef unsigned short sa_family_t; +#endif + + +#ifdef __MINGW32__ + +#define __SOCKADDR_COMMON(sa_prefix) \ + sa_family_t sa_prefix##family + +/* Ditto, for IPv6. */ +struct sockaddr_in6 + { + __SOCKADDR_COMMON (sin6_); + u_int16_t sin6_port; /* Transport layer port # */ + u_int32_t sin6_flowinfo; /* IPv6 flow information */ + struct in6_addr sin6_addr; /* IPv6 address */ + }; + +#define IN6_IS_ADDR_V4MAPPED(a) \ + ((((u_int32_t *) (a))[0] == 0) && (((u_int32_t *) (a))[1] == 0) && \ + (((u_int32_t *) (a))[2] == htonl (0xffff))) + +#define IN6_IS_ADDR_MULTICAST(a) (((u_int8_t *) (a))[0] == 0xff) + +#define IN6_IS_ADDR_LINKLOCAL(a) \ + ((((u_int32_t *) (a))[0] & htonl (0xffc00000)) == htonl (0xfe800000)) + +#define IN6_IS_ADDR_LOOPBACK(a) \ + (((u_int32_t *) (a))[0] == 0 && ((u_int32_t *) (a))[1] == 0 && \ + ((u_int32_t *) (a))[2] == 0 && ((u_int32_t *) (a))[3] == htonl (1)) +#endif /* __MINGW32__ */ + +#define ip6_vfc ip6_ctlun.ip6_un2_vfc +#define ip6_flow ip6_ctlun.ip6_un1.ip6_un1_flow +#define ip6_plen ip6_ctlun.ip6_un1.ip6_un1_plen +#define ip6_nxt ip6_ctlun.ip6_un1.ip6_un1_nxt +#define ip6_hlim ip6_ctlun.ip6_un1.ip6_un1_hlim +#define ip6_hops ip6_ctlun.ip6_un1.ip6_un1_hlim + +#define nd_rd_type nd_rd_hdr.icmp6_type +#define nd_rd_code nd_rd_hdr.icmp6_code +#define nd_rd_cksum nd_rd_hdr.icmp6_cksum +#define nd_rd_reserved nd_rd_hdr.icmp6_data32[0] + +/* + * IPV6 extension headers + */ +#define IPPROTO_HOPOPTS 0 /* IPv6 hop-by-hop options */ +#define IPPROTO_IPV6 41 /* IPv6 header. */ +#define IPPROTO_ROUTING 43 /* IPv6 routing header */ +#define IPPROTO_FRAGMENT 44 /* IPv6 fragmentation header */ +#define IPPROTO_ESP 50 /* encapsulating security payload */ +#define IPPROTO_AH 51 /* authentication header */ +#define IPPROTO_ICMPV6 58 /* ICMPv6 */ +#define IPPROTO_NONE 59 /* IPv6 no next header */ +#define IPPROTO_DSTOPTS 60 /* IPv6 destination options */ +#define IPPROTO_PIM 103 /* Protocol Independent Multicast. */ + +#define IPV6_RTHDR_TYPE_0 0 + +/* Option types and related macros */ +#define IP6OPT_PAD1 0x00 /* 00 0 00000 */ +#define IP6OPT_PADN 0x01 /* 00 0 00001 */ +#define IP6OPT_JUMBO 0xC2 /* 11 0 00010 = 194 */ +#define IP6OPT_JUMBO_LEN 6 +#define IP6OPT_ROUTER_ALERT 0x05 /* 00 0 00101 */ + +#define IP6OPT_RTALERT_LEN 4 +#define IP6OPT_RTALERT_MLD 0 /* Datagram contains an MLD message */ +#define IP6OPT_RTALERT_RSVP 1 /* Datagram contains an RSVP message */ +#define IP6OPT_RTALERT_ACTNET 2 /* contains an Active Networks msg */ +#define IP6OPT_MINLEN 2 + +#define IP6OPT_BINDING_UPDATE 0xc6 /* 11 0 00110 */ +#define IP6OPT_BINDING_ACK 0x07 /* 00 0 00111 */ +#define IP6OPT_BINDING_REQ 0x08 /* 00 0 01000 */ +#define IP6OPT_HOME_ADDRESS 0xc9 /* 11 0 01001 */ +#define IP6OPT_EID 0x8a /* 10 0 01010 */ + +#define IP6OPT_TYPE(o) ((o) & 0xC0) +#define IP6OPT_TYPE_SKIP 0x00 +#define IP6OPT_TYPE_DISCARD 0x40 +#define IP6OPT_TYPE_FORCEICMP 0x80 +#define IP6OPT_TYPE_ICMP 0xC0 + +#define IP6OPT_MUTABLE 0x20 + + +#ifdef __MINGW32__ +#ifndef EAI_ADDRFAMILY +struct addrinfo { + int ai_flags; /* AI_PASSIVE, AI_CANONNAME */ + int ai_family; /* PF_xxx */ + int ai_socktype; /* SOCK_xxx */ + int ai_protocol; /* 0 or IPPROTO_xxx for IPv4 and IPv6 */ + size_t ai_addrlen; /* length of ai_addr */ + char *ai_canonname; /* canonical name for hostname */ + struct sockaddr *ai_addr; /* binary address */ + struct addrinfo *ai_next; /* next structure in linked list */ +}; +#endif +#endif /* __MINGW32__ */ diff --git a/desmume/src/windows/winpcap/memory_t.h b/src/windows/winpcap/memory_t.h similarity index 96% rename from desmume/src/windows/winpcap/memory_t.h rename to src/windows/winpcap/memory_t.h index b4200168a..3f3fb526b 100644 --- a/desmume/src/windows/winpcap/memory_t.h +++ b/src/windows/winpcap/memory_t.h @@ -1,133 +1,133 @@ -/* - * Copyright (c) 2001 - 2005 NetGroup, Politecnico di Torino (Italy) - * Copyright (c) 2005 - 2006 CACE Technologies, Davis (California) - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * 3. Neither the name of the Politecnico di Torino, CACE Technologies - * nor the names of its contributors may be used to endorse or promote - * products derived from this software without specific prior written - * permission. - * - * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS - * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT - * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR - * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT - * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, - * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY - * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT - * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE - * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * - */ - -#ifndef __memory_t -#define __memory_t - -#define uint8 UCHAR -#define int8 CHAR -#define uint16 USHORT -#define int16 SHORT -#define uint32 ULONG -#define int32 LONG -#define uint64 ULONGLONG -#define int64 LONGLONG - -/*memory type*/ -typedef struct __MEM_TYPE -{ - uint8 *buffer; - uint32 size; -} MEM_TYPE, *PMEM_TYPE; - -#define LONG_AT(base,offset) (*(int32*)((uint8*)base+(uint32)offset)) - -#define ULONG_AT(base,offset) (*(uint32*)((uint8*)base+(uint32)offset)) - -#define SHORT_AT(base,offset) (*(int16*)((uint8*)base+(uint32)offset)) - -#define USHORT_AT(base,offset) (*(uint16*)((uint8*)base+(uint32)offset)) - -__inline int32 SW_LONG_AT(void *b, uint32 c) -{ - return ((int32)*((uint8 *)b+c)<<24| - (int32)*((uint8 *)b+c+1)<<16| - (int32)*((uint8 *)b+c+2)<<8| - (int32)*((uint8 *)b+c+3)<<0); -} - - -__inline uint32 SW_ULONG_AT(void *b, uint32 c) -{ - return ((uint32)*((uint8 *)b+c)<<24| - (uint32)*((uint8 *)b+c+1)<<16| - (uint32)*((uint8 *)b+c+2)<<8| - (uint32)*((uint8 *)b+c+3)<<0); -} - -__inline int16 SW_SHORT_AT(void *b, uint32 os) -{ - return ((int16) - ((int16)*((uint8 *)b+os+0)<<8| - (int16)*((uint8 *)b+os+1)<<0)); -} - -__inline uint16 SW_USHORT_AT(void *b, uint32 os) -{ - return ((uint16) - ((uint16)*((uint8 *)b+os+0)<<8| - (uint16)*((uint8 *)b+os+1)<<0)); -} - -__inline VOID SW_ULONG_ASSIGN(void *dst, uint32 src) -{ - *((uint8*)dst+0)=*((uint8*)&src+3); - *((uint8*)dst+1)=*((uint8*)&src+2); - *((uint8*)dst+2)=*((uint8*)&src+1); - *((uint8*)dst+3)=*((uint8*)&src+0); - -} - -#ifdef WIN_NT_DRIVER - -#define ALLOCATE_MEMORY(dest,type,amount) \ - (dest)=ExAllocatePoolWithTag(NonPagedPool,sizeof(type)*(amount), '0TWA'); -#define ALLOCATE_ZERO_MEMORY(dest,type,amount) \ - { \ - (dest)=ExAllocatePoolWithTag(NonPagedPool,sizeof(type)*(amount), '1TWA'); \ - if ((dest)!=NULL) \ - RtlZeroMemory((dest),sizeof(type)*(amount)); \ - } - -#define FREE_MEMORY(dest) ExFreePool(dest); -#define ZERO_MEMORY(dest,amount) RtlZeroMemory(dest,amount); -#define COPY_MEMORY(dest,src,amount) RtlCopyMemory(dest,src,amount); - -#else - -#define ALLOCATE_MEMORY(dest,type,amount) \ - (dest)=(type*)GlobalAlloc(GPTR, sizeof(type)*(amount)); -#define ALLOCATE_ZERO_MEMORY(dest,type,amount) \ - (dest)=(type*)GlobalAlloc(GPTR, sizeof(type)*(amount)); - -#define FREE_MEMORY(dest) GlobalFree(dest); -#define ZERO_MEMORY(dest,amount) RtlZeroMemory(dest,amount); -#define COPY_MEMORY(dest,src,amount) RtlCopyMemory(dest,src,amount); - - -#endif /*WIN_NT_DRIVER*/ - - - -#endif - +/* + * Copyright (c) 2001 - 2005 NetGroup, Politecnico di Torino (Italy) + * Copyright (c) 2005 - 2006 CACE Technologies, Davis (California) + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. Neither the name of the Politecnico di Torino, CACE Technologies + * nor the names of its contributors may be used to endorse or promote + * products derived from this software without specific prior written + * permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR + * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT + * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE + * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ + +#ifndef __memory_t +#define __memory_t + +#define uint8 UCHAR +#define int8 CHAR +#define uint16 USHORT +#define int16 SHORT +#define uint32 ULONG +#define int32 LONG +#define uint64 ULONGLONG +#define int64 LONGLONG + +/*memory type*/ +typedef struct __MEM_TYPE +{ + uint8 *buffer; + uint32 size; +} MEM_TYPE, *PMEM_TYPE; + +#define LONG_AT(base,offset) (*(int32*)((uint8*)base+(uint32)offset)) + +#define ULONG_AT(base,offset) (*(uint32*)((uint8*)base+(uint32)offset)) + +#define SHORT_AT(base,offset) (*(int16*)((uint8*)base+(uint32)offset)) + +#define USHORT_AT(base,offset) (*(uint16*)((uint8*)base+(uint32)offset)) + +__inline int32 SW_LONG_AT(void *b, uint32 c) +{ + return ((int32)*((uint8 *)b+c)<<24| + (int32)*((uint8 *)b+c+1)<<16| + (int32)*((uint8 *)b+c+2)<<8| + (int32)*((uint8 *)b+c+3)<<0); +} + + +__inline uint32 SW_ULONG_AT(void *b, uint32 c) +{ + return ((uint32)*((uint8 *)b+c)<<24| + (uint32)*((uint8 *)b+c+1)<<16| + (uint32)*((uint8 *)b+c+2)<<8| + (uint32)*((uint8 *)b+c+3)<<0); +} + +__inline int16 SW_SHORT_AT(void *b, uint32 os) +{ + return ((int16) + ((int16)*((uint8 *)b+os+0)<<8| + (int16)*((uint8 *)b+os+1)<<0)); +} + +__inline uint16 SW_USHORT_AT(void *b, uint32 os) +{ + return ((uint16) + ((uint16)*((uint8 *)b+os+0)<<8| + (uint16)*((uint8 *)b+os+1)<<0)); +} + +__inline VOID SW_ULONG_ASSIGN(void *dst, uint32 src) +{ + *((uint8*)dst+0)=*((uint8*)&src+3); + *((uint8*)dst+1)=*((uint8*)&src+2); + *((uint8*)dst+2)=*((uint8*)&src+1); + *((uint8*)dst+3)=*((uint8*)&src+0); + +} + +#ifdef WIN_NT_DRIVER + +#define ALLOCATE_MEMORY(dest,type,amount) \ + (dest)=ExAllocatePoolWithTag(NonPagedPool,sizeof(type)*(amount), '0TWA'); +#define ALLOCATE_ZERO_MEMORY(dest,type,amount) \ + { \ + (dest)=ExAllocatePoolWithTag(NonPagedPool,sizeof(type)*(amount), '1TWA'); \ + if ((dest)!=NULL) \ + RtlZeroMemory((dest),sizeof(type)*(amount)); \ + } + +#define FREE_MEMORY(dest) ExFreePool(dest); +#define ZERO_MEMORY(dest,amount) RtlZeroMemory(dest,amount); +#define COPY_MEMORY(dest,src,amount) RtlCopyMemory(dest,src,amount); + +#else + +#define ALLOCATE_MEMORY(dest,type,amount) \ + (dest)=(type*)GlobalAlloc(GPTR, sizeof(type)*(amount)); +#define ALLOCATE_ZERO_MEMORY(dest,type,amount) \ + (dest)=(type*)GlobalAlloc(GPTR, sizeof(type)*(amount)); + +#define FREE_MEMORY(dest) GlobalFree(dest); +#define ZERO_MEMORY(dest,amount) RtlZeroMemory(dest,amount); +#define COPY_MEMORY(dest,src,amount) RtlCopyMemory(dest,src,amount); + + +#endif /*WIN_NT_DRIVER*/ + + + +#endif + diff --git a/desmume/src/windows/winpcap/normal_lookup.h b/src/windows/winpcap/normal_lookup.h similarity index 97% rename from desmume/src/windows/winpcap/normal_lookup.h rename to src/windows/winpcap/normal_lookup.h index 62e75f467..f9fb00bf9 100644 --- a/desmume/src/windows/winpcap/normal_lookup.h +++ b/src/windows/winpcap/normal_lookup.h @@ -1,56 +1,56 @@ -/* - * Copyright (c) 2001 - 2003 - * NetGroup, Politecnico di Torino (Italy) - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * 3. Neither the name of the Politecnico di Torino nor the names of its - * contributors may be used to endorse or promote products derived from - * this software without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS - * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT - * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR - * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT - * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, - * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY - * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT - * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE - * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * - */ - -#ifndef __normal_lookup -#define __normal_lookup - -#ifdef WIN32 -#include "tme.h" -#endif - -#ifdef __FreeBSD__ - -#ifdef _KERNEL -#include -#else -#include -#endif - -#endif - -#define NORMAL_LUT_W_INSERT 0x00000000 -uint32 normal_lut_w_insert(uint8 *key, TME_DATA *data, MEM_TYPE *mem_ex, struct time_conv *time_ref); -#define NORMAL_LUT_WO_INSERT 0x00000001 -uint32 normal_lut_wo_insert(uint8 *key, TME_DATA *data, MEM_TYPE *mem_ex, struct time_conv *time_ref); -#define DUMMY_INSERT 1234 - +/* + * Copyright (c) 2001 - 2003 + * NetGroup, Politecnico di Torino (Italy) + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. Neither the name of the Politecnico di Torino nor the names of its + * contributors may be used to endorse or promote products derived from + * this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR + * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT + * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE + * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ + +#ifndef __normal_lookup +#define __normal_lookup + +#ifdef WIN32 +#include "tme.h" +#endif + +#ifdef __FreeBSD__ + +#ifdef _KERNEL +#include +#else +#include +#endif + +#endif + +#define NORMAL_LUT_W_INSERT 0x00000000 +uint32 normal_lut_w_insert(uint8 *key, TME_DATA *data, MEM_TYPE *mem_ex, struct time_conv *time_ref); +#define NORMAL_LUT_WO_INSERT 0x00000001 +uint32 normal_lut_wo_insert(uint8 *key, TME_DATA *data, MEM_TYPE *mem_ex, struct time_conv *time_ref); +#define DUMMY_INSERT 1234 + #endif \ No newline at end of file diff --git a/desmume/src/windows/winpcap/pcap-bpf.h b/src/windows/winpcap/pcap-bpf.h similarity index 96% rename from desmume/src/windows/winpcap/pcap-bpf.h rename to src/windows/winpcap/pcap-bpf.h index 542976701..175fa73df 100644 --- a/desmume/src/windows/winpcap/pcap-bpf.h +++ b/src/windows/winpcap/pcap-bpf.h @@ -1,736 +1,736 @@ -/*- - * Copyright (c) 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997 - * The Regents of the University of California. All rights reserved. - * - * This code is derived from the Stanford/CMU enet packet filter, - * (net/enet.c) distributed as part of 4.3BSD, and code contributed - * to Berkeley by Steven McCanne and Van Jacobson both of Lawrence - * Berkeley Laboratory. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * 3. All advertising materials mentioning features or use of this software - * must display the following acknowledgement: - * This product includes software developed by the University of - * California, Berkeley and its contributors. - * 4. Neither the name of the University nor the names of its contributors - * may be used to endorse or promote products derived from this software - * without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND - * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE - * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE - * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS - * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) - * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY - * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * - * @(#)bpf.h 7.1 (Berkeley) 5/7/91 - * - * @(#) $Header: /tcpdump/master/libpcap/pcap-bpf.h,v 1.34.2.11 2006/07/27 21:06:17 gianluca Exp $ (LBL) - */ - -/* - * This is libpcap's cut-down version of bpf.h; it includes only - * the stuff needed for the code generator and the userland BPF - * interpreter, and the libpcap APIs for setting filters, etc.. - * - * "pcap-bpf.c" will include the native OS version, as it deals with - * the OS's BPF implementation. - * - * XXX - should this all just be moved to "pcap.h"? - */ - -#ifndef BPF_MAJOR_VERSION - -#ifdef __cplusplus -extern "C" { -#endif - -/* BSD style release date */ -#define BPF_RELEASE 199606 - -#ifdef MSDOS /* must be 32-bit */ -typedef long bpf_int32; -typedef unsigned long bpf_u_int32; -#else -typedef int bpf_int32; -typedef u_int bpf_u_int32; -#endif - -/* - * Alignment macros. BPF_WORDALIGN rounds up to the next - * even multiple of BPF_ALIGNMENT. - */ -#ifndef __NetBSD__ -#define BPF_ALIGNMENT sizeof(bpf_int32) -#else -#define BPF_ALIGNMENT sizeof(long) -#endif -#define BPF_WORDALIGN(x) (((x)+(BPF_ALIGNMENT-1))&~(BPF_ALIGNMENT-1)) - -#define BPF_MAXINSNS 512 -#define BPF_MAXBUFSIZE 0x8000 -#define BPF_MINBUFSIZE 32 - -/* - * Structure for "pcap_compile()", "pcap_setfilter()", etc.. - */ -struct bpf_program { - u_int bf_len; - struct bpf_insn *bf_insns; -}; - -/* - * Struct return by BIOCVERSION. This represents the version number of - * the filter language described by the instruction encodings below. - * bpf understands a program iff kernel_major == filter_major && - * kernel_minor >= filter_minor, that is, if the value returned by the - * running kernel has the same major number and a minor number equal - * equal to or less than the filter being downloaded. Otherwise, the - * results are undefined, meaning an error may be returned or packets - * may be accepted haphazardly. - * It has nothing to do with the source code version. - */ -struct bpf_version { - u_short bv_major; - u_short bv_minor; -}; -/* Current version number of filter architecture. */ -#define BPF_MAJOR_VERSION 1 -#define BPF_MINOR_VERSION 1 - -/* - * Data-link level type codes. - * - * Do *NOT* add new values to this list without asking - * "tcpdump-workers@tcpdump.org" for a value. Otherwise, you run the - * risk of using a value that's already being used for some other purpose, - * and of having tools that read libpcap-format captures not being able - * to handle captures with your new DLT_ value, with no hope that they - * will ever be changed to do so (as that would destroy their ability - * to read captures using that value for that other purpose). - */ - -/* - * These are the types that are the same on all platforms, and that - * have been defined by for ages. - */ -#define DLT_NULL 0 /* BSD loopback encapsulation */ -#define DLT_EN10MB 1 /* Ethernet (10Mb) */ -#define DLT_EN3MB 2 /* Experimental Ethernet (3Mb) */ -#define DLT_AX25 3 /* Amateur Radio AX.25 */ -#define DLT_PRONET 4 /* Proteon ProNET Token Ring */ -#define DLT_CHAOS 5 /* Chaos */ -#define DLT_IEEE802 6 /* IEEE 802 Networks */ -#define DLT_ARCNET 7 /* ARCNET, with BSD-style header */ -#define DLT_SLIP 8 /* Serial Line IP */ -#define DLT_PPP 9 /* Point-to-point Protocol */ -#define DLT_FDDI 10 /* FDDI */ - -/* - * These are types that are different on some platforms, and that - * have been defined by for ages. We use #ifdefs to - * detect the BSDs that define them differently from the traditional - * libpcap - * - * XXX - DLT_ATM_RFC1483 is 13 in BSD/OS, and DLT_RAW is 14 in BSD/OS, - * but I don't know what the right #define is for BSD/OS. - */ -#define DLT_ATM_RFC1483 11 /* LLC-encapsulated ATM */ - -#ifdef __OpenBSD__ -#define DLT_RAW 14 /* raw IP */ -#else -#define DLT_RAW 12 /* raw IP */ -#endif - -/* - * Given that the only OS that currently generates BSD/OS SLIP or PPP - * is, well, BSD/OS, arguably everybody should have chosen its values - * for DLT_SLIP_BSDOS and DLT_PPP_BSDOS, which are 15 and 16, but they - * didn't. So it goes. - */ -#if defined(__NetBSD__) || defined(__FreeBSD__) -#ifndef DLT_SLIP_BSDOS -#define DLT_SLIP_BSDOS 13 /* BSD/OS Serial Line IP */ -#define DLT_PPP_BSDOS 14 /* BSD/OS Point-to-point Protocol */ -#endif -#else -#define DLT_SLIP_BSDOS 15 /* BSD/OS Serial Line IP */ -#define DLT_PPP_BSDOS 16 /* BSD/OS Point-to-point Protocol */ -#endif - -/* - * 17 is used for DLT_OLD_PFLOG in OpenBSD; - * OBSOLETE: DLT_PFLOG is 117 in OpenBSD now as well. See below. - * 18 is used for DLT_PFSYNC in OpenBSD; don't use it for anything else. - */ - -#define DLT_ATM_CLIP 19 /* Linux Classical-IP over ATM */ - -/* - * Apparently Redback uses this for its SmartEdge 400/800. I hope - * nobody else decided to use it, too. - */ -#define DLT_REDBACK_SMARTEDGE 32 - -/* - * These values are defined by NetBSD; other platforms should refrain from - * using them for other purposes, so that NetBSD savefiles with link - * types of 50 or 51 can be read as this type on all platforms. - */ -#define DLT_PPP_SERIAL 50 /* PPP over serial with HDLC encapsulation */ -#define DLT_PPP_ETHER 51 /* PPP over Ethernet */ - -/* - * The Axent Raptor firewall - now the Symantec Enterprise Firewall - uses - * a link-layer type of 99 for the tcpdump it supplies. The link-layer - * header has 6 bytes of unknown data, something that appears to be an - * Ethernet type, and 36 bytes that appear to be 0 in at least one capture - * I've seen. - */ -#define DLT_SYMANTEC_FIREWALL 99 - -/* - * Values between 100 and 103 are used in capture file headers as - * link-layer types corresponding to DLT_ types that differ - * between platforms; don't use those values for new DLT_ new types. - */ - -/* - * This value was defined by libpcap 0.5; platforms that have defined - * it with a different value should define it here with that value - - * a link type of 104 in a save file will be mapped to DLT_C_HDLC, - * whatever value that happens to be, so programs will correctly - * handle files with that link type regardless of the value of - * DLT_C_HDLC. - * - * The name DLT_C_HDLC was used by BSD/OS; we use that name for source - * compatibility with programs written for BSD/OS. - * - * libpcap 0.5 defined it as DLT_CHDLC; we define DLT_CHDLC as well, - * for source compatibility with programs written for libpcap 0.5. - */ -#define DLT_C_HDLC 104 /* Cisco HDLC */ -#define DLT_CHDLC DLT_C_HDLC - -#define DLT_IEEE802_11 105 /* IEEE 802.11 wireless */ - -/* - * 106 is reserved for Linux Classical IP over ATM; it's like DLT_RAW, - * except when it isn't. (I.e., sometimes it's just raw IP, and - * sometimes it isn't.) We currently handle it as DLT_LINUX_SLL, - * so that we don't have to worry about the link-layer header.) - */ - -/* - * Frame Relay; BSD/OS has a DLT_FR with a value of 11, but that collides - * with other values. - * DLT_FR and DLT_FRELAY packets start with the Q.922 Frame Relay header - * (DLCI, etc.). - */ -#define DLT_FRELAY 107 - -/* - * OpenBSD DLT_LOOP, for loopback devices; it's like DLT_NULL, except - * that the AF_ type in the link-layer header is in network byte order. - * - * OpenBSD defines it as 12, but that collides with DLT_RAW, so we - * define it as 108 here. If OpenBSD picks up this file, it should - * define DLT_LOOP as 12 in its version, as per the comment above - - * and should not use 108 as a DLT_ value. - */ -#define DLT_LOOP 108 - -/* - * Encapsulated packets for IPsec; DLT_ENC is 13 in OpenBSD, but that's - * DLT_SLIP_BSDOS in NetBSD, so we don't use 13 for it in OSes other - * than OpenBSD. - */ -#ifdef __OpenBSD__ -#define DLT_ENC 13 -#else -#define DLT_ENC 109 -#endif - -/* - * Values between 110 and 112 are reserved for use in capture file headers - * as link-layer types corresponding to DLT_ types that might differ - * between platforms; don't use those values for new DLT_ types - * other than the corresponding DLT_ types. - */ - -/* - * This is for Linux cooked sockets. - */ -#define DLT_LINUX_SLL 113 - -/* - * Apple LocalTalk hardware. - */ -#define DLT_LTALK 114 - -/* - * Acorn Econet. - */ -#define DLT_ECONET 115 - -/* - * Reserved for use with OpenBSD ipfilter. - */ -#define DLT_IPFILTER 116 - -/* - * OpenBSD DLT_PFLOG; DLT_PFLOG is 17 in OpenBSD, but that's DLT_LANE8023 - * in SuSE 6.3, so we can't use 17 for it in capture-file headers. - * - * XXX: is there a conflict with DLT_PFSYNC 18 as well? - */ -#ifdef __OpenBSD__ -#define DLT_OLD_PFLOG 17 -#define DLT_PFSYNC 18 -#endif -#define DLT_PFLOG 117 - -/* - * Registered for Cisco-internal use. - */ -#define DLT_CISCO_IOS 118 - -/* - * For 802.11 cards using the Prism II chips, with a link-layer - * header including Prism monitor mode information plus an 802.11 - * header. - */ -#define DLT_PRISM_HEADER 119 - -/* - * Reserved for Aironet 802.11 cards, with an Aironet link-layer header - * (see Doug Ambrisko's FreeBSD patches). - */ -#define DLT_AIRONET_HEADER 120 - -/* - * Reserved for Siemens HiPath HDLC. - */ -#define DLT_HHDLC 121 - -/* - * This is for RFC 2625 IP-over-Fibre Channel. - * - * This is not for use with raw Fibre Channel, where the link-layer - * header starts with a Fibre Channel frame header; it's for IP-over-FC, - * where the link-layer header starts with an RFC 2625 Network_Header - * field. - */ -#define DLT_IP_OVER_FC 122 - -/* - * This is for Full Frontal ATM on Solaris with SunATM, with a - * pseudo-header followed by an AALn PDU. - * - * There may be other forms of Full Frontal ATM on other OSes, - * with different pseudo-headers. - * - * If ATM software returns a pseudo-header with VPI/VCI information - * (and, ideally, packet type information, e.g. signalling, ILMI, - * LANE, LLC-multiplexed traffic, etc.), it should not use - * DLT_ATM_RFC1483, but should get a new DLT_ value, so tcpdump - * and the like don't have to infer the presence or absence of a - * pseudo-header and the form of the pseudo-header. - */ -#define DLT_SUNATM 123 /* Solaris+SunATM */ - -/* - * Reserved as per request from Kent Dahlgren - * for private use. - */ -#define DLT_RIO 124 /* RapidIO */ -#define DLT_PCI_EXP 125 /* PCI Express */ -#define DLT_AURORA 126 /* Xilinx Aurora link layer */ - -/* - * Header for 802.11 plus a number of bits of link-layer information - * including radio information, used by some recent BSD drivers as - * well as the madwifi Atheros driver for Linux. - */ -#define DLT_IEEE802_11_RADIO 127 /* 802.11 plus radiotap radio header */ - -/* - * Reserved for the TZSP encapsulation, as per request from - * Chris Waters - * TZSP is a generic encapsulation for any other link type, - * which includes a means to include meta-information - * with the packet, e.g. signal strength and channel - * for 802.11 packets. - */ -#define DLT_TZSP 128 /* Tazmen Sniffer Protocol */ - -/* - * BSD's ARCNET headers have the source host, destination host, - * and type at the beginning of the packet; that's what's handed - * up to userland via BPF. - * - * Linux's ARCNET headers, however, have a 2-byte offset field - * between the host IDs and the type; that's what's handed up - * to userland via PF_PACKET sockets. - * - * We therefore have to have separate DLT_ values for them. - */ -#define DLT_ARCNET_LINUX 129 /* ARCNET */ - -/* - * Juniper-private data link types, as per request from - * Hannes Gredler . The DLT_s are used - * for passing on chassis-internal metainformation such as - * QOS profiles, etc.. - */ -#define DLT_JUNIPER_MLPPP 130 -#define DLT_JUNIPER_MLFR 131 -#define DLT_JUNIPER_ES 132 -#define DLT_JUNIPER_GGSN 133 -#define DLT_JUNIPER_MFR 134 -#define DLT_JUNIPER_ATM2 135 -#define DLT_JUNIPER_SERVICES 136 -#define DLT_JUNIPER_ATM1 137 - -/* - * Apple IP-over-IEEE 1394, as per a request from Dieter Siegmund - * . The header that's presented is an Ethernet-like - * header: - * - * #define FIREWIRE_EUI64_LEN 8 - * struct firewire_header { - * u_char firewire_dhost[FIREWIRE_EUI64_LEN]; - * u_char firewire_shost[FIREWIRE_EUI64_LEN]; - * u_short firewire_type; - * }; - * - * with "firewire_type" being an Ethernet type value, rather than, - * for example, raw GASP frames being handed up. - */ -#define DLT_APPLE_IP_OVER_IEEE1394 138 - -/* - * Various SS7 encapsulations, as per a request from Jeff Morriss - * and subsequent discussions. - */ -#define DLT_MTP2_WITH_PHDR 139 /* pseudo-header with various info, followed by MTP2 */ -#define DLT_MTP2 140 /* MTP2, without pseudo-header */ -#define DLT_MTP3 141 /* MTP3, without pseudo-header or MTP2 */ -#define DLT_SCCP 142 /* SCCP, without pseudo-header or MTP2 or MTP3 */ - -/* - * DOCSIS MAC frames. - */ -#define DLT_DOCSIS 143 - -/* - * Linux-IrDA packets. Protocol defined at http://www.irda.org. - * Those packets include IrLAP headers and above (IrLMP...), but - * don't include Phy framing (SOF/EOF/CRC & byte stuffing), because Phy - * framing can be handled by the hardware and depend on the bitrate. - * This is exactly the format you would get capturing on a Linux-IrDA - * interface (irdaX), but not on a raw serial port. - * Note the capture is done in "Linux-cooked" mode, so each packet include - * a fake packet header (struct sll_header). This is because IrDA packet - * decoding is dependant on the direction of the packet (incomming or - * outgoing). - * When/if other platform implement IrDA capture, we may revisit the - * issue and define a real DLT_IRDA... - * Jean II - */ -#define DLT_LINUX_IRDA 144 - -/* - * Reserved for IBM SP switch and IBM Next Federation switch. - */ -#define DLT_IBM_SP 145 -#define DLT_IBM_SN 146 - -/* - * Reserved for private use. If you have some link-layer header type - * that you want to use within your organization, with the capture files - * using that link-layer header type not ever be sent outside your - * organization, you can use these values. - * - * No libpcap release will use these for any purpose, nor will any - * tcpdump release use them, either. - * - * Do *NOT* use these in capture files that you expect anybody not using - * your private versions of capture-file-reading tools to read; in - * particular, do *NOT* use them in products, otherwise you may find that - * people won't be able to use tcpdump, or snort, or Ethereal, or... to - * read capture files from your firewall/intrusion detection/traffic - * monitoring/etc. appliance, or whatever product uses that DLT_ value, - * and you may also find that the developers of those applications will - * not accept patches to let them read those files. - * - * Also, do not use them if somebody might send you a capture using them - * for *their* private type and tools using them for *your* private type - * would have to read them. - * - * Instead, ask "tcpdump-workers@tcpdump.org" for a new DLT_ value, - * as per the comment above, and use the type you're given. - */ -#define DLT_USER0 147 -#define DLT_USER1 148 -#define DLT_USER2 149 -#define DLT_USER3 150 -#define DLT_USER4 151 -#define DLT_USER5 152 -#define DLT_USER6 153 -#define DLT_USER7 154 -#define DLT_USER8 155 -#define DLT_USER9 156 -#define DLT_USER10 157 -#define DLT_USER11 158 -#define DLT_USER12 159 -#define DLT_USER13 160 -#define DLT_USER14 161 -#define DLT_USER15 162 - -/* - * For future use with 802.11 captures - defined by AbsoluteValue - * Systems to store a number of bits of link-layer information - * including radio information: - * - * http://www.shaftnet.org/~pizza/software/capturefrm.txt - * - * but it might be used by some non-AVS drivers now or in the - * future. - */ -#define DLT_IEEE802_11_RADIO_AVS 163 /* 802.11 plus AVS radio header */ - -/* - * Juniper-private data link type, as per request from - * Hannes Gredler . The DLT_s are used - * for passing on chassis-internal metainformation such as - * QOS profiles, etc.. - */ -#define DLT_JUNIPER_MONITOR 164 - -/* - * Reserved for BACnet MS/TP. - */ -#define DLT_BACNET_MS_TP 165 - -/* - * Another PPP variant as per request from Karsten Keil . - * - * This is used in some OSes to allow a kernel socket filter to distinguish - * between incoming and outgoing packets, on a socket intended to - * supply pppd with outgoing packets so it can do dial-on-demand and - * hangup-on-lack-of-demand; incoming packets are filtered out so they - * don't cause pppd to hold the connection up (you don't want random - * input packets such as port scans, packets from old lost connections, - * etc. to force the connection to stay up). - * - * The first byte of the PPP header (0xff03) is modified to accomodate - * the direction - 0x00 = IN, 0x01 = OUT. - */ -#define DLT_PPP_PPPD 166 - -/* - * Names for backwards compatibility with older versions of some PPP - * software; new software should use DLT_PPP_PPPD. - */ -#define DLT_PPP_WITH_DIRECTION DLT_PPP_PPPD -#define DLT_LINUX_PPP_WITHDIRECTION DLT_PPP_PPPD - -/* - * Juniper-private data link type, as per request from - * Hannes Gredler . The DLT_s are used - * for passing on chassis-internal metainformation such as - * QOS profiles, cookies, etc.. - */ -#define DLT_JUNIPER_PPPOE 167 -#define DLT_JUNIPER_PPPOE_ATM 168 - -#define DLT_GPRS_LLC 169 /* GPRS LLC */ -#define DLT_GPF_T 170 /* GPF-T (ITU-T G.7041/Y.1303) */ -#define DLT_GPF_F 171 /* GPF-F (ITU-T G.7041/Y.1303) */ - -/* - * Requested by Oolan Zimmer for use in Gcom's T1/E1 line - * monitoring equipment. - */ -#define DLT_GCOM_T1E1 172 -#define DLT_GCOM_SERIAL 173 - -/* - * Juniper-private data link type, as per request from - * Hannes Gredler . The DLT_ is used - * for internal communication to Physical Interface Cards (PIC) - */ -#define DLT_JUNIPER_PIC_PEER 174 - -/* - * Link types requested by Gregor Maier of Endace - * Measurement Systems. They add an ERF header (see - * http://www.endace.com/support/EndaceRecordFormat.pdf) in front of - * the link-layer header. - */ -#define DLT_ERF_ETH 175 /* Ethernet */ -#define DLT_ERF_POS 176 /* Packet-over-SONET */ - -/* - * Requested by Daniele Orlandi for raw LAPD - * for vISDN (http://www.orlandi.com/visdn/). Its link-layer header - * includes additional information before the LAPD header, so it's - * not necessarily a generic LAPD header. - */ -#define DLT_LINUX_LAPD 177 - -/* - * Juniper-private data link type, as per request from - * Hannes Gredler . - * The DLT_ are used for prepending meta-information - * like interface index, interface name - * before standard Ethernet, PPP, Frelay & C-HDLC Frames - */ -#define DLT_JUNIPER_ETHER 178 -#define DLT_JUNIPER_PPP 179 -#define DLT_JUNIPER_FRELAY 180 -#define DLT_JUNIPER_CHDLC 181 - -/* - * Multi Link Frame Relay (FRF.16) - */ -#define DLT_MFR 182 - -/* - * Juniper-private data link type, as per request from - * Hannes Gredler . - * The DLT_ is used for internal communication with a - * voice Adapter Card (PIC) - */ -#define DLT_JUNIPER_VP 183 - -/* - * Arinc 429 frames. - * DLT_ requested by Gianluca Varenni . - * Every frame contains a 32bit A429 label. - * More documentation on Arinc 429 can be found at - * http://www.condoreng.com/support/downloads/tutorials/ARINCTutorial.pdf - */ -#define DLT_A429 184 - -/* - * Arinc 653 Interpartition Communication messages. - * DLT_ requested by Gianluca Varenni . - * Please refer to the A653-1 standard for more information. - */ -#define DLT_A653_ICM 185 - -/* - * Controller Area Network (CAN) v. 2.0B packets. - * DLT_ requested by Gianluca Varenni . - * Used to dump CAN packets coming from a CAN Vector board. - * More documentation on the CAN v2.0B frames can be found at - * http://www.can-cia.org/downloads/?269 - */ -#define DLT_CAN20B 190 - - -/* - * The instruction encodings. - */ -/* instruction classes */ -#define BPF_CLASS(code) ((code) & 0x07) -#define BPF_LD 0x00 -#define BPF_LDX 0x01 -#define BPF_ST 0x02 -#define BPF_STX 0x03 -#define BPF_ALU 0x04 -#define BPF_JMP 0x05 -#define BPF_RET 0x06 -#define BPF_MISC 0x07 - -/* ld/ldx fields */ -#define BPF_SIZE(code) ((code) & 0x18) -#define BPF_W 0x00 -#define BPF_H 0x08 -#define BPF_B 0x10 -#define BPF_MODE(code) ((code) & 0xe0) -#define BPF_IMM 0x00 -#define BPF_ABS 0x20 -#define BPF_IND 0x40 -#define BPF_MEM 0x60 -#define BPF_LEN 0x80 -#define BPF_MSH 0xa0 - -/* alu/jmp fields */ -#define BPF_OP(code) ((code) & 0xf0) -#define BPF_ADD 0x00 -#define BPF_SUB 0x10 -#define BPF_MUL 0x20 -#define BPF_DIV 0x30 -#define BPF_OR 0x40 -#define BPF_AND 0x50 -#define BPF_LSH 0x60 -#define BPF_RSH 0x70 -#define BPF_NEG 0x80 -#define BPF_JA 0x00 -#define BPF_JEQ 0x10 -#define BPF_JGT 0x20 -#define BPF_JGE 0x30 -#define BPF_JSET 0x40 -#define BPF_SRC(code) ((code) & 0x08) -#define BPF_K 0x00 -#define BPF_X 0x08 - -/* ret - BPF_K and BPF_X also apply */ -#define BPF_RVAL(code) ((code) & 0x18) -#define BPF_A 0x10 - -/* misc */ -#define BPF_MISCOP(code) ((code) & 0xf8) -#define BPF_TAX 0x00 -#define BPF_TXA 0x80 - -/* - * The instruction data structure. - */ -struct bpf_insn { - u_short code; - u_char jt; - u_char jf; - bpf_int32 k; -}; - -/* - * Macros for insn array initializers. - */ -#define BPF_STMT(code, k) { (u_short)(code), 0, 0, k } -#define BPF_JUMP(code, k, jt, jf) { (u_short)(code), jt, jf, k } - -#if __STDC__ || defined(__cplusplus) -extern int bpf_validate(struct bpf_insn *, int); -extern u_int bpf_filter(struct bpf_insn *, u_char *, u_int, u_int); -#else -extern int bpf_validate(); -extern u_int bpf_filter(); -#endif - -/* - * Number of scratch memory words (for BPF_LD|BPF_MEM and BPF_ST). - */ -#define BPF_MEMWORDS 16 - -#ifdef __cplusplus -} -#endif - -#endif +/*- + * Copyright (c) 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997 + * The Regents of the University of California. All rights reserved. + * + * This code is derived from the Stanford/CMU enet packet filter, + * (net/enet.c) distributed as part of 4.3BSD, and code contributed + * to Berkeley by Steven McCanne and Van Jacobson both of Lawrence + * Berkeley Laboratory. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. All advertising materials mentioning features or use of this software + * must display the following acknowledgement: + * This product includes software developed by the University of + * California, Berkeley and its contributors. + * 4. Neither the name of the University nor the names of its contributors + * may be used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * + * @(#)bpf.h 7.1 (Berkeley) 5/7/91 + * + * @(#) $Header: /tcpdump/master/libpcap/pcap-bpf.h,v 1.34.2.11 2006/07/27 21:06:17 gianluca Exp $ (LBL) + */ + +/* + * This is libpcap's cut-down version of bpf.h; it includes only + * the stuff needed for the code generator and the userland BPF + * interpreter, and the libpcap APIs for setting filters, etc.. + * + * "pcap-bpf.c" will include the native OS version, as it deals with + * the OS's BPF implementation. + * + * XXX - should this all just be moved to "pcap.h"? + */ + +#ifndef BPF_MAJOR_VERSION + +#ifdef __cplusplus +extern "C" { +#endif + +/* BSD style release date */ +#define BPF_RELEASE 199606 + +#ifdef MSDOS /* must be 32-bit */ +typedef long bpf_int32; +typedef unsigned long bpf_u_int32; +#else +typedef int bpf_int32; +typedef u_int bpf_u_int32; +#endif + +/* + * Alignment macros. BPF_WORDALIGN rounds up to the next + * even multiple of BPF_ALIGNMENT. + */ +#ifndef __NetBSD__ +#define BPF_ALIGNMENT sizeof(bpf_int32) +#else +#define BPF_ALIGNMENT sizeof(long) +#endif +#define BPF_WORDALIGN(x) (((x)+(BPF_ALIGNMENT-1))&~(BPF_ALIGNMENT-1)) + +#define BPF_MAXINSNS 512 +#define BPF_MAXBUFSIZE 0x8000 +#define BPF_MINBUFSIZE 32 + +/* + * Structure for "pcap_compile()", "pcap_setfilter()", etc.. + */ +struct bpf_program { + u_int bf_len; + struct bpf_insn *bf_insns; +}; + +/* + * Struct return by BIOCVERSION. This represents the version number of + * the filter language described by the instruction encodings below. + * bpf understands a program iff kernel_major == filter_major && + * kernel_minor >= filter_minor, that is, if the value returned by the + * running kernel has the same major number and a minor number equal + * equal to or less than the filter being downloaded. Otherwise, the + * results are undefined, meaning an error may be returned or packets + * may be accepted haphazardly. + * It has nothing to do with the source code version. + */ +struct bpf_version { + u_short bv_major; + u_short bv_minor; +}; +/* Current version number of filter architecture. */ +#define BPF_MAJOR_VERSION 1 +#define BPF_MINOR_VERSION 1 + +/* + * Data-link level type codes. + * + * Do *NOT* add new values to this list without asking + * "tcpdump-workers@tcpdump.org" for a value. Otherwise, you run the + * risk of using a value that's already being used for some other purpose, + * and of having tools that read libpcap-format captures not being able + * to handle captures with your new DLT_ value, with no hope that they + * will ever be changed to do so (as that would destroy their ability + * to read captures using that value for that other purpose). + */ + +/* + * These are the types that are the same on all platforms, and that + * have been defined by for ages. + */ +#define DLT_NULL 0 /* BSD loopback encapsulation */ +#define DLT_EN10MB 1 /* Ethernet (10Mb) */ +#define DLT_EN3MB 2 /* Experimental Ethernet (3Mb) */ +#define DLT_AX25 3 /* Amateur Radio AX.25 */ +#define DLT_PRONET 4 /* Proteon ProNET Token Ring */ +#define DLT_CHAOS 5 /* Chaos */ +#define DLT_IEEE802 6 /* IEEE 802 Networks */ +#define DLT_ARCNET 7 /* ARCNET, with BSD-style header */ +#define DLT_SLIP 8 /* Serial Line IP */ +#define DLT_PPP 9 /* Point-to-point Protocol */ +#define DLT_FDDI 10 /* FDDI */ + +/* + * These are types that are different on some platforms, and that + * have been defined by for ages. We use #ifdefs to + * detect the BSDs that define them differently from the traditional + * libpcap + * + * XXX - DLT_ATM_RFC1483 is 13 in BSD/OS, and DLT_RAW is 14 in BSD/OS, + * but I don't know what the right #define is for BSD/OS. + */ +#define DLT_ATM_RFC1483 11 /* LLC-encapsulated ATM */ + +#ifdef __OpenBSD__ +#define DLT_RAW 14 /* raw IP */ +#else +#define DLT_RAW 12 /* raw IP */ +#endif + +/* + * Given that the only OS that currently generates BSD/OS SLIP or PPP + * is, well, BSD/OS, arguably everybody should have chosen its values + * for DLT_SLIP_BSDOS and DLT_PPP_BSDOS, which are 15 and 16, but they + * didn't. So it goes. + */ +#if defined(__NetBSD__) || defined(__FreeBSD__) +#ifndef DLT_SLIP_BSDOS +#define DLT_SLIP_BSDOS 13 /* BSD/OS Serial Line IP */ +#define DLT_PPP_BSDOS 14 /* BSD/OS Point-to-point Protocol */ +#endif +#else +#define DLT_SLIP_BSDOS 15 /* BSD/OS Serial Line IP */ +#define DLT_PPP_BSDOS 16 /* BSD/OS Point-to-point Protocol */ +#endif + +/* + * 17 is used for DLT_OLD_PFLOG in OpenBSD; + * OBSOLETE: DLT_PFLOG is 117 in OpenBSD now as well. See below. + * 18 is used for DLT_PFSYNC in OpenBSD; don't use it for anything else. + */ + +#define DLT_ATM_CLIP 19 /* Linux Classical-IP over ATM */ + +/* + * Apparently Redback uses this for its SmartEdge 400/800. I hope + * nobody else decided to use it, too. + */ +#define DLT_REDBACK_SMARTEDGE 32 + +/* + * These values are defined by NetBSD; other platforms should refrain from + * using them for other purposes, so that NetBSD savefiles with link + * types of 50 or 51 can be read as this type on all platforms. + */ +#define DLT_PPP_SERIAL 50 /* PPP over serial with HDLC encapsulation */ +#define DLT_PPP_ETHER 51 /* PPP over Ethernet */ + +/* + * The Axent Raptor firewall - now the Symantec Enterprise Firewall - uses + * a link-layer type of 99 for the tcpdump it supplies. The link-layer + * header has 6 bytes of unknown data, something that appears to be an + * Ethernet type, and 36 bytes that appear to be 0 in at least one capture + * I've seen. + */ +#define DLT_SYMANTEC_FIREWALL 99 + +/* + * Values between 100 and 103 are used in capture file headers as + * link-layer types corresponding to DLT_ types that differ + * between platforms; don't use those values for new DLT_ new types. + */ + +/* + * This value was defined by libpcap 0.5; platforms that have defined + * it with a different value should define it here with that value - + * a link type of 104 in a save file will be mapped to DLT_C_HDLC, + * whatever value that happens to be, so programs will correctly + * handle files with that link type regardless of the value of + * DLT_C_HDLC. + * + * The name DLT_C_HDLC was used by BSD/OS; we use that name for source + * compatibility with programs written for BSD/OS. + * + * libpcap 0.5 defined it as DLT_CHDLC; we define DLT_CHDLC as well, + * for source compatibility with programs written for libpcap 0.5. + */ +#define DLT_C_HDLC 104 /* Cisco HDLC */ +#define DLT_CHDLC DLT_C_HDLC + +#define DLT_IEEE802_11 105 /* IEEE 802.11 wireless */ + +/* + * 106 is reserved for Linux Classical IP over ATM; it's like DLT_RAW, + * except when it isn't. (I.e., sometimes it's just raw IP, and + * sometimes it isn't.) We currently handle it as DLT_LINUX_SLL, + * so that we don't have to worry about the link-layer header.) + */ + +/* + * Frame Relay; BSD/OS has a DLT_FR with a value of 11, but that collides + * with other values. + * DLT_FR and DLT_FRELAY packets start with the Q.922 Frame Relay header + * (DLCI, etc.). + */ +#define DLT_FRELAY 107 + +/* + * OpenBSD DLT_LOOP, for loopback devices; it's like DLT_NULL, except + * that the AF_ type in the link-layer header is in network byte order. + * + * OpenBSD defines it as 12, but that collides with DLT_RAW, so we + * define it as 108 here. If OpenBSD picks up this file, it should + * define DLT_LOOP as 12 in its version, as per the comment above - + * and should not use 108 as a DLT_ value. + */ +#define DLT_LOOP 108 + +/* + * Encapsulated packets for IPsec; DLT_ENC is 13 in OpenBSD, but that's + * DLT_SLIP_BSDOS in NetBSD, so we don't use 13 for it in OSes other + * than OpenBSD. + */ +#ifdef __OpenBSD__ +#define DLT_ENC 13 +#else +#define DLT_ENC 109 +#endif + +/* + * Values between 110 and 112 are reserved for use in capture file headers + * as link-layer types corresponding to DLT_ types that might differ + * between platforms; don't use those values for new DLT_ types + * other than the corresponding DLT_ types. + */ + +/* + * This is for Linux cooked sockets. + */ +#define DLT_LINUX_SLL 113 + +/* + * Apple LocalTalk hardware. + */ +#define DLT_LTALK 114 + +/* + * Acorn Econet. + */ +#define DLT_ECONET 115 + +/* + * Reserved for use with OpenBSD ipfilter. + */ +#define DLT_IPFILTER 116 + +/* + * OpenBSD DLT_PFLOG; DLT_PFLOG is 17 in OpenBSD, but that's DLT_LANE8023 + * in SuSE 6.3, so we can't use 17 for it in capture-file headers. + * + * XXX: is there a conflict with DLT_PFSYNC 18 as well? + */ +#ifdef __OpenBSD__ +#define DLT_OLD_PFLOG 17 +#define DLT_PFSYNC 18 +#endif +#define DLT_PFLOG 117 + +/* + * Registered for Cisco-internal use. + */ +#define DLT_CISCO_IOS 118 + +/* + * For 802.11 cards using the Prism II chips, with a link-layer + * header including Prism monitor mode information plus an 802.11 + * header. + */ +#define DLT_PRISM_HEADER 119 + +/* + * Reserved for Aironet 802.11 cards, with an Aironet link-layer header + * (see Doug Ambrisko's FreeBSD patches). + */ +#define DLT_AIRONET_HEADER 120 + +/* + * Reserved for Siemens HiPath HDLC. + */ +#define DLT_HHDLC 121 + +/* + * This is for RFC 2625 IP-over-Fibre Channel. + * + * This is not for use with raw Fibre Channel, where the link-layer + * header starts with a Fibre Channel frame header; it's for IP-over-FC, + * where the link-layer header starts with an RFC 2625 Network_Header + * field. + */ +#define DLT_IP_OVER_FC 122 + +/* + * This is for Full Frontal ATM on Solaris with SunATM, with a + * pseudo-header followed by an AALn PDU. + * + * There may be other forms of Full Frontal ATM on other OSes, + * with different pseudo-headers. + * + * If ATM software returns a pseudo-header with VPI/VCI information + * (and, ideally, packet type information, e.g. signalling, ILMI, + * LANE, LLC-multiplexed traffic, etc.), it should not use + * DLT_ATM_RFC1483, but should get a new DLT_ value, so tcpdump + * and the like don't have to infer the presence or absence of a + * pseudo-header and the form of the pseudo-header. + */ +#define DLT_SUNATM 123 /* Solaris+SunATM */ + +/* + * Reserved as per request from Kent Dahlgren + * for private use. + */ +#define DLT_RIO 124 /* RapidIO */ +#define DLT_PCI_EXP 125 /* PCI Express */ +#define DLT_AURORA 126 /* Xilinx Aurora link layer */ + +/* + * Header for 802.11 plus a number of bits of link-layer information + * including radio information, used by some recent BSD drivers as + * well as the madwifi Atheros driver for Linux. + */ +#define DLT_IEEE802_11_RADIO 127 /* 802.11 plus radiotap radio header */ + +/* + * Reserved for the TZSP encapsulation, as per request from + * Chris Waters + * TZSP is a generic encapsulation for any other link type, + * which includes a means to include meta-information + * with the packet, e.g. signal strength and channel + * for 802.11 packets. + */ +#define DLT_TZSP 128 /* Tazmen Sniffer Protocol */ + +/* + * BSD's ARCNET headers have the source host, destination host, + * and type at the beginning of the packet; that's what's handed + * up to userland via BPF. + * + * Linux's ARCNET headers, however, have a 2-byte offset field + * between the host IDs and the type; that's what's handed up + * to userland via PF_PACKET sockets. + * + * We therefore have to have separate DLT_ values for them. + */ +#define DLT_ARCNET_LINUX 129 /* ARCNET */ + +/* + * Juniper-private data link types, as per request from + * Hannes Gredler . The DLT_s are used + * for passing on chassis-internal metainformation such as + * QOS profiles, etc.. + */ +#define DLT_JUNIPER_MLPPP 130 +#define DLT_JUNIPER_MLFR 131 +#define DLT_JUNIPER_ES 132 +#define DLT_JUNIPER_GGSN 133 +#define DLT_JUNIPER_MFR 134 +#define DLT_JUNIPER_ATM2 135 +#define DLT_JUNIPER_SERVICES 136 +#define DLT_JUNIPER_ATM1 137 + +/* + * Apple IP-over-IEEE 1394, as per a request from Dieter Siegmund + * . The header that's presented is an Ethernet-like + * header: + * + * #define FIREWIRE_EUI64_LEN 8 + * struct firewire_header { + * u_char firewire_dhost[FIREWIRE_EUI64_LEN]; + * u_char firewire_shost[FIREWIRE_EUI64_LEN]; + * u_short firewire_type; + * }; + * + * with "firewire_type" being an Ethernet type value, rather than, + * for example, raw GASP frames being handed up. + */ +#define DLT_APPLE_IP_OVER_IEEE1394 138 + +/* + * Various SS7 encapsulations, as per a request from Jeff Morriss + * and subsequent discussions. + */ +#define DLT_MTP2_WITH_PHDR 139 /* pseudo-header with various info, followed by MTP2 */ +#define DLT_MTP2 140 /* MTP2, without pseudo-header */ +#define DLT_MTP3 141 /* MTP3, without pseudo-header or MTP2 */ +#define DLT_SCCP 142 /* SCCP, without pseudo-header or MTP2 or MTP3 */ + +/* + * DOCSIS MAC frames. + */ +#define DLT_DOCSIS 143 + +/* + * Linux-IrDA packets. Protocol defined at http://www.irda.org. + * Those packets include IrLAP headers and above (IrLMP...), but + * don't include Phy framing (SOF/EOF/CRC & byte stuffing), because Phy + * framing can be handled by the hardware and depend on the bitrate. + * This is exactly the format you would get capturing on a Linux-IrDA + * interface (irdaX), but not on a raw serial port. + * Note the capture is done in "Linux-cooked" mode, so each packet include + * a fake packet header (struct sll_header). This is because IrDA packet + * decoding is dependant on the direction of the packet (incomming or + * outgoing). + * When/if other platform implement IrDA capture, we may revisit the + * issue and define a real DLT_IRDA... + * Jean II + */ +#define DLT_LINUX_IRDA 144 + +/* + * Reserved for IBM SP switch and IBM Next Federation switch. + */ +#define DLT_IBM_SP 145 +#define DLT_IBM_SN 146 + +/* + * Reserved for private use. If you have some link-layer header type + * that you want to use within your organization, with the capture files + * using that link-layer header type not ever be sent outside your + * organization, you can use these values. + * + * No libpcap release will use these for any purpose, nor will any + * tcpdump release use them, either. + * + * Do *NOT* use these in capture files that you expect anybody not using + * your private versions of capture-file-reading tools to read; in + * particular, do *NOT* use them in products, otherwise you may find that + * people won't be able to use tcpdump, or snort, or Ethereal, or... to + * read capture files from your firewall/intrusion detection/traffic + * monitoring/etc. appliance, or whatever product uses that DLT_ value, + * and you may also find that the developers of those applications will + * not accept patches to let them read those files. + * + * Also, do not use them if somebody might send you a capture using them + * for *their* private type and tools using them for *your* private type + * would have to read them. + * + * Instead, ask "tcpdump-workers@tcpdump.org" for a new DLT_ value, + * as per the comment above, and use the type you're given. + */ +#define DLT_USER0 147 +#define DLT_USER1 148 +#define DLT_USER2 149 +#define DLT_USER3 150 +#define DLT_USER4 151 +#define DLT_USER5 152 +#define DLT_USER6 153 +#define DLT_USER7 154 +#define DLT_USER8 155 +#define DLT_USER9 156 +#define DLT_USER10 157 +#define DLT_USER11 158 +#define DLT_USER12 159 +#define DLT_USER13 160 +#define DLT_USER14 161 +#define DLT_USER15 162 + +/* + * For future use with 802.11 captures - defined by AbsoluteValue + * Systems to store a number of bits of link-layer information + * including radio information: + * + * http://www.shaftnet.org/~pizza/software/capturefrm.txt + * + * but it might be used by some non-AVS drivers now or in the + * future. + */ +#define DLT_IEEE802_11_RADIO_AVS 163 /* 802.11 plus AVS radio header */ + +/* + * Juniper-private data link type, as per request from + * Hannes Gredler . The DLT_s are used + * for passing on chassis-internal metainformation such as + * QOS profiles, etc.. + */ +#define DLT_JUNIPER_MONITOR 164 + +/* + * Reserved for BACnet MS/TP. + */ +#define DLT_BACNET_MS_TP 165 + +/* + * Another PPP variant as per request from Karsten Keil . + * + * This is used in some OSes to allow a kernel socket filter to distinguish + * between incoming and outgoing packets, on a socket intended to + * supply pppd with outgoing packets so it can do dial-on-demand and + * hangup-on-lack-of-demand; incoming packets are filtered out so they + * don't cause pppd to hold the connection up (you don't want random + * input packets such as port scans, packets from old lost connections, + * etc. to force the connection to stay up). + * + * The first byte of the PPP header (0xff03) is modified to accomodate + * the direction - 0x00 = IN, 0x01 = OUT. + */ +#define DLT_PPP_PPPD 166 + +/* + * Names for backwards compatibility with older versions of some PPP + * software; new software should use DLT_PPP_PPPD. + */ +#define DLT_PPP_WITH_DIRECTION DLT_PPP_PPPD +#define DLT_LINUX_PPP_WITHDIRECTION DLT_PPP_PPPD + +/* + * Juniper-private data link type, as per request from + * Hannes Gredler . The DLT_s are used + * for passing on chassis-internal metainformation such as + * QOS profiles, cookies, etc.. + */ +#define DLT_JUNIPER_PPPOE 167 +#define DLT_JUNIPER_PPPOE_ATM 168 + +#define DLT_GPRS_LLC 169 /* GPRS LLC */ +#define DLT_GPF_T 170 /* GPF-T (ITU-T G.7041/Y.1303) */ +#define DLT_GPF_F 171 /* GPF-F (ITU-T G.7041/Y.1303) */ + +/* + * Requested by Oolan Zimmer for use in Gcom's T1/E1 line + * monitoring equipment. + */ +#define DLT_GCOM_T1E1 172 +#define DLT_GCOM_SERIAL 173 + +/* + * Juniper-private data link type, as per request from + * Hannes Gredler . The DLT_ is used + * for internal communication to Physical Interface Cards (PIC) + */ +#define DLT_JUNIPER_PIC_PEER 174 + +/* + * Link types requested by Gregor Maier of Endace + * Measurement Systems. They add an ERF header (see + * http://www.endace.com/support/EndaceRecordFormat.pdf) in front of + * the link-layer header. + */ +#define DLT_ERF_ETH 175 /* Ethernet */ +#define DLT_ERF_POS 176 /* Packet-over-SONET */ + +/* + * Requested by Daniele Orlandi for raw LAPD + * for vISDN (http://www.orlandi.com/visdn/). Its link-layer header + * includes additional information before the LAPD header, so it's + * not necessarily a generic LAPD header. + */ +#define DLT_LINUX_LAPD 177 + +/* + * Juniper-private data link type, as per request from + * Hannes Gredler . + * The DLT_ are used for prepending meta-information + * like interface index, interface name + * before standard Ethernet, PPP, Frelay & C-HDLC Frames + */ +#define DLT_JUNIPER_ETHER 178 +#define DLT_JUNIPER_PPP 179 +#define DLT_JUNIPER_FRELAY 180 +#define DLT_JUNIPER_CHDLC 181 + +/* + * Multi Link Frame Relay (FRF.16) + */ +#define DLT_MFR 182 + +/* + * Juniper-private data link type, as per request from + * Hannes Gredler . + * The DLT_ is used for internal communication with a + * voice Adapter Card (PIC) + */ +#define DLT_JUNIPER_VP 183 + +/* + * Arinc 429 frames. + * DLT_ requested by Gianluca Varenni . + * Every frame contains a 32bit A429 label. + * More documentation on Arinc 429 can be found at + * http://www.condoreng.com/support/downloads/tutorials/ARINCTutorial.pdf + */ +#define DLT_A429 184 + +/* + * Arinc 653 Interpartition Communication messages. + * DLT_ requested by Gianluca Varenni . + * Please refer to the A653-1 standard for more information. + */ +#define DLT_A653_ICM 185 + +/* + * Controller Area Network (CAN) v. 2.0B packets. + * DLT_ requested by Gianluca Varenni . + * Used to dump CAN packets coming from a CAN Vector board. + * More documentation on the CAN v2.0B frames can be found at + * http://www.can-cia.org/downloads/?269 + */ +#define DLT_CAN20B 190 + + +/* + * The instruction encodings. + */ +/* instruction classes */ +#define BPF_CLASS(code) ((code) & 0x07) +#define BPF_LD 0x00 +#define BPF_LDX 0x01 +#define BPF_ST 0x02 +#define BPF_STX 0x03 +#define BPF_ALU 0x04 +#define BPF_JMP 0x05 +#define BPF_RET 0x06 +#define BPF_MISC 0x07 + +/* ld/ldx fields */ +#define BPF_SIZE(code) ((code) & 0x18) +#define BPF_W 0x00 +#define BPF_H 0x08 +#define BPF_B 0x10 +#define BPF_MODE(code) ((code) & 0xe0) +#define BPF_IMM 0x00 +#define BPF_ABS 0x20 +#define BPF_IND 0x40 +#define BPF_MEM 0x60 +#define BPF_LEN 0x80 +#define BPF_MSH 0xa0 + +/* alu/jmp fields */ +#define BPF_OP(code) ((code) & 0xf0) +#define BPF_ADD 0x00 +#define BPF_SUB 0x10 +#define BPF_MUL 0x20 +#define BPF_DIV 0x30 +#define BPF_OR 0x40 +#define BPF_AND 0x50 +#define BPF_LSH 0x60 +#define BPF_RSH 0x70 +#define BPF_NEG 0x80 +#define BPF_JA 0x00 +#define BPF_JEQ 0x10 +#define BPF_JGT 0x20 +#define BPF_JGE 0x30 +#define BPF_JSET 0x40 +#define BPF_SRC(code) ((code) & 0x08) +#define BPF_K 0x00 +#define BPF_X 0x08 + +/* ret - BPF_K and BPF_X also apply */ +#define BPF_RVAL(code) ((code) & 0x18) +#define BPF_A 0x10 + +/* misc */ +#define BPF_MISCOP(code) ((code) & 0xf8) +#define BPF_TAX 0x00 +#define BPF_TXA 0x80 + +/* + * The instruction data structure. + */ +struct bpf_insn { + u_short code; + u_char jt; + u_char jf; + bpf_int32 k; +}; + +/* + * Macros for insn array initializers. + */ +#define BPF_STMT(code, k) { (u_short)(code), 0, 0, k } +#define BPF_JUMP(code, k, jt, jf) { (u_short)(code), jt, jf, k } + +#if __STDC__ || defined(__cplusplus) +extern int bpf_validate(struct bpf_insn *, int); +extern u_int bpf_filter(struct bpf_insn *, u_char *, u_int, u_int); +#else +extern int bpf_validate(); +extern u_int bpf_filter(); +#endif + +/* + * Number of scratch memory words (for BPF_LD|BPF_MEM and BPF_ST). + */ +#define BPF_MEMWORDS 16 + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/desmume/src/windows/winpcap/pcap-int.h b/src/windows/winpcap/pcap-int.h similarity index 97% rename from desmume/src/windows/winpcap/pcap-int.h rename to src/windows/winpcap/pcap-int.h index 7aefa191f..784797046 100644 --- a/desmume/src/windows/winpcap/pcap-int.h +++ b/src/windows/winpcap/pcap-int.h @@ -1,373 +1,373 @@ -/* - * Copyright (c) 1994, 1995, 1996 - * The Regents of the University of California. All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * 3. All advertising materials mentioning features or use of this software - * must display the following acknowledgement: - * This product includes software developed by the Computer Systems - * Engineering Group at Lawrence Berkeley Laboratory. - * 4. Neither the name of the University nor of the Laboratory may be used - * to endorse or promote products derived from this software without - * specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND - * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE - * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE - * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS - * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) - * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY - * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * - * @(#) $Header: /tcpdump/master/libpcap/pcap-int.h,v 1.68.2.9 2006/02/22 17:09:54 gianluca Exp $ (LBL) - */ - -#ifndef pcap_int_h -#define pcap_int_h - -#ifdef __cplusplus -extern "C" { -#endif - -#include - -#ifdef WIN32 -#include -#endif /* WIN32 */ - -#ifdef MSDOS -#include -#include -#endif - -/* - * Savefile - */ -typedef enum { - NOT_SWAPPED, - SWAPPED, - MAYBE_SWAPPED -} swapped_type_t; - -struct pcap_sf { - FILE *rfile; - int swapped; - int hdrsize; - swapped_type_t lengths_swapped; - int version_major; - int version_minor; - u_char *base; -}; - -struct pcap_md { - struct pcap_stat stat; - /*XXX*/ - int use_bpf; /* using kernel filter */ - u_long TotPkts; /* can't oflow for 79 hrs on ether */ - u_long TotAccepted; /* count accepted by filter */ - u_long TotDrops; /* count of dropped packets */ - long TotMissed; /* missed by i/f during this run */ - long OrigMissed; /* missed by i/f before this run */ - char *device; /* device name */ -#ifdef linux - int sock_packet; /* using Linux 2.0 compatible interface */ - int timeout; /* timeout specified to pcap_open_live */ - int clear_promisc; /* must clear promiscuous mode when we close */ - int cooked; /* using SOCK_DGRAM rather than SOCK_RAW */ - int ifindex; /* interface index of device we're bound to */ - int lo_ifindex; /* interface index of the loopback device */ - struct pcap *next; /* list of open promiscuous sock_packet pcaps */ - u_int packets_read; /* count of packets read with recvfrom() */ -#endif - -#ifdef HAVE_DAG_API -#ifdef HAVE_DAG_STREAMS_API - u_char *dag_mem_bottom; /* DAG card current memory bottom pointer */ - u_char *dag_mem_top; /* DAG card current memory top pointer */ -#else - void *dag_mem_base; /* DAG card memory base address */ - u_int dag_mem_bottom; /* DAG card current memory bottom offset */ - u_int dag_mem_top; /* DAG card current memory top offset */ -#endif /* HAVE_DAG_STREAMS_API */ - int dag_fcs_bits; /* Number of checksum bits from link layer */ - int dag_offset_flags; /* Flags to pass to dag_offset(). */ - int dag_stream; /* DAG stream number */ - int dag_timeout; /* timeout specified to pcap_open_live. - * Same as in linux above, introduce - * generally? */ -#endif /* HAVE_DAG_API */ - -#ifdef HAVE_REMOTE -/*! - There is really a mess with previous variables, and it seems to me that they are not used - (they are used in pcap_pf.c only). I think we have to start using them. - The meaning is the following: - - - TotPkts: the amount of packets received by the bpf filter, *before* applying the filter - - TotAccepted: the amount of packets that satisfies the filter - - TotDrops: the amount of packet that were dropped into the kernel buffer because of lack of space - - TotMissed: the amount of packets that were dropped by the physical interface; it is basically - the value of the hardware counter into the card. This number is never put to zero, so this number - takes into account the *total* number of interface drops starting from the interface power-on. - - OrigMissed: the amount of packets that were dropped by the interface *when the capture begins*. - This value is used to detect the number of packets dropped by the interface *during the present - capture*, so that (ps_ifdrops= TotMissed - OrigMissed). -*/ - unsigned int TotNetDrops; //!< keeps the number of packets that have been dropped by the network -/*! - \brief It keeps the number of packets that have been received by the application. - - Packets dropped by the kernel buffer are not counted in this variable. The variable is always - equal to (TotAccepted - TotDrops), exept for the case of remote capture, in which we have also - packets in fligh, i.e. that have been transmitted by the remote host, but that have not been - received (yet) from the client. In this case, (TotAccepted - TotDrops - TotNetDrops) gives a - wrong result, since this number does not corresponds always to the number of packet received by - the application. For this reason, in the remote capture we need another variable that takes - into account of the number of packets actually received by the application. -*/ - unsigned int TotCapt; -#endif /* HAVE_REMOTE */ -}; - -/* - * Ultrix, DEC OSF/1^H^H^H^H^H^H^H^H^HDigital UNIX^H^H^H^H^H^H^H^H^H^H^H^H - * Tru64 UNIX, and NetBSD pad to make everything line up on a nice boundary. - */ -#if defined(ultrix) || defined(__osf__) || (defined(__NetBSD__) && __NetBSD_Version__ > 106000000) -#define PCAP_FDDIPAD 3 -#endif - -struct pcap { -#ifdef WIN32 - ADAPTER *adapter; - LPPACKET Packet; - int timeout; - int nonblock; -#else - int fd; - int selectable_fd; - int send_fd; -#endif /* WIN32 */ - int snapshot; - int linktype; - int tzoff; /* timezone offset */ - int offset; /* offset for proper alignment */ - - int break_loop; /* flag set to force break from packet-reading loop */ - -#ifdef PCAP_FDDIPAD - int fddipad; -#endif - -#ifdef MSDOS - int inter_packet_wait; /* offline: wait between packets */ - void (*wait_proc)(void); /* call proc while waiting */ -#endif - - struct pcap_sf sf; - struct pcap_md md; - - /* - * Read buffer. - */ - int bufsize; - u_char *buffer; - u_char *bp; - int cc; - - /* - * Place holder for pcap_next(). - */ - u_char *pkt; - - /* We're accepting only packets in this direction/these directions. */ - pcap_direction_t direction; - - /* - * Methods. - */ - int (*read_op)(pcap_t *, int cnt, pcap_handler, u_char *); - int (*inject_op)(pcap_t *, const void *, size_t); - int (*setfilter_op)(pcap_t *, struct bpf_program *); - int (*setdirection_op)(pcap_t *, pcap_direction_t); - int (*set_datalink_op)(pcap_t *, int); - int (*getnonblock_op)(pcap_t *, char *); - int (*setnonblock_op)(pcap_t *, int, char *); - int (*stats_op)(pcap_t *, struct pcap_stat *); - void (*close_op)(pcap_t *); - - /* - * Placeholder for filter code if bpf not in kernel. - */ - struct bpf_program fcode; - - char errbuf[PCAP_ERRBUF_SIZE + 1]; - int dlt_count; - u_int *dlt_list; - - struct pcap_pkthdr pcap_header; /* This is needed for the pcap_next_ex() to work */ - -#ifdef HAVE_REMOTE -#ifndef WIN32 // Win32 already defines 'timeout' - int timeout; //!< timeout to be used in the pcap_open() -#endif - /*! \brief '1' if we're the network client; needed by several functions (like pcap_setfilter() ) to know if - they have to use the socket or they have to open the local adapter. */ - int rmt_clientside; - - SOCKET rmt_sockctrl; //!< socket ID of the socket used for the control connection - SOCKET rmt_sockdata; //!< socket ID of the socket used for the data connection - int rmt_flags; //!< we have to save flags, since they are passed by the pcap_open_live(), but they are used by the pcap_startcapture() - int rmt_capstarted; //!< 'true' if the capture is already started (needed to knoe if we have to call the pcap_startcapture() - struct pcap_samp rmt_samp; //!< Keeps the parameters related to the sampling process. - char *currentfilter; //!< Pointer to a buffer (allocated at run-time) that stores the current filter. Needed when flag PCAP_OPENFLAG_NOCAPTURE_RPCAP is turned on. -#endif /* HAVE_REMOTE */ -}; - -/* - * This is a timeval as stored in a savefile. - * It has to use the same types everywhere, independent of the actual - * `struct timeval'; `struct timeval' has 32-bit tv_sec values on some - * platforms and 64-bit tv_sec values on other platforms, and writing - * out native `struct timeval' values would mean files could only be - * read on systems with the same tv_sec size as the system on which - * the file was written. - */ - -struct pcap_timeval { - bpf_int32 tv_sec; /* seconds */ - bpf_int32 tv_usec; /* microseconds */ -}; - -/* - * This is a `pcap_pkthdr' as actually stored in a savefile. - * - * Do not change the format of this structure, in any way (this includes - * changes that only affect the length of fields in this structure), - * and do not make the time stamp anything other than seconds and - * microseconds (e.g., seconds and nanoseconds). Instead: - * - * introduce a new structure for the new format; - * - * send mail to "tcpdump-workers@tcpdump.org", requesting a new - * magic number for your new capture file format, and, when - * you get the new magic number, put it in "savefile.c"; - * - * use that magic number for save files with the changed record - * header; - * - * make the code in "savefile.c" capable of reading files with - * the old record header as well as files with the new record header - * (using the magic number to determine the header format). - * - * Then supply the changes to "patches@tcpdump.org", so that future - * versions of libpcap and programs that use it (such as tcpdump) will - * be able to read your new capture file format. - */ - -struct pcap_sf_pkthdr { - struct pcap_timeval ts; /* time stamp */ - bpf_u_int32 caplen; /* length of portion present */ - bpf_u_int32 len; /* length this packet (off wire) */ -}; - -/* - * How a `pcap_pkthdr' is actually stored in savefiles written - * by some patched versions of libpcap (e.g. the ones in Red - * Hat Linux 6.1 and 6.2). - * - * Do not change the format of this structure, in any way (this includes - * changes that only affect the length of fields in this structure). - * Instead, introduce a new structure, as per the above. - */ - -struct pcap_sf_patched_pkthdr { - struct pcap_timeval ts; /* time stamp */ - bpf_u_int32 caplen; /* length of portion present */ - bpf_u_int32 len; /* length this packet (off wire) */ - int index; - unsigned short protocol; - unsigned char pkt_type; -}; - -int yylex(void); - -#ifndef min -#define min(a, b) ((a) > (b) ? (b) : (a)) -#endif - -/* XXX should these be in pcap.h? */ -int pcap_offline_read(pcap_t *, int, pcap_handler, u_char *); -int pcap_read(pcap_t *, int cnt, pcap_handler, u_char *); - -#ifndef HAVE_STRLCPY -#define strlcpy(x, y, z) \ - (strncpy((x), (y), (z)), \ - ((z) <= 0 ? 0 : ((x)[(z) - 1] = '\0')), \ - strlen((y))) -#endif - -#include - -#if !defined(HAVE_SNPRINTF) -#define snprintf pcap_snprintf -extern int snprintf (char *, size_t, const char *, ...); -#endif - -#if !defined(HAVE_VSNPRINTF) -#define vsnprintf pcap_vsnprintf -extern int vsnprintf (char *, size_t, const char *, va_list ap); -#endif - -/* - * Routines that most pcap implementations can use for non-blocking mode. - */ -#if !defined(WIN32) && !defined(MSDOS) -int pcap_getnonblock_fd(pcap_t *, char *); -int pcap_setnonblock_fd(pcap_t *p, int, char *); -#endif - -void pcap_close_common(pcap_t *); - -/* - * Internal interfaces for "pcap_findalldevs()". - * - * "pcap_platform_finddevs()" is a platform-dependent routine to - * add devices not found by the "standard" mechanisms (SIOCGIFCONF, - * "getifaddrs()", etc.. - * - * "pcap_add_if()" adds an interface to the list of interfaces. - */ -int pcap_platform_finddevs(pcap_if_t **, char *); -int add_addr_to_iflist(pcap_if_t **, const char *, u_int, struct sockaddr *, - size_t, struct sockaddr *, size_t, struct sockaddr *, size_t, - struct sockaddr *, size_t, char *); -int pcap_add_if(pcap_if_t **, const char *, u_int, const char *, char *); -struct sockaddr *dup_sockaddr(struct sockaddr *, size_t); -int add_or_find_if(pcap_if_t **, pcap_if_t **, const char *, u_int, - const char *, char *); - -#ifdef WIN32 -char *pcap_win32strerror(void); -#endif - -int install_bpf_program(pcap_t *, struct bpf_program *); - -int pcap_strcasecmp(const char *, const char *); - -#ifdef __cplusplus -} -#endif - -#endif +/* + * Copyright (c) 1994, 1995, 1996 + * The Regents of the University of California. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. All advertising materials mentioning features or use of this software + * must display the following acknowledgement: + * This product includes software developed by the Computer Systems + * Engineering Group at Lawrence Berkeley Laboratory. + * 4. Neither the name of the University nor of the Laboratory may be used + * to endorse or promote products derived from this software without + * specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * + * @(#) $Header: /tcpdump/master/libpcap/pcap-int.h,v 1.68.2.9 2006/02/22 17:09:54 gianluca Exp $ (LBL) + */ + +#ifndef pcap_int_h +#define pcap_int_h + +#ifdef __cplusplus +extern "C" { +#endif + +#include + +#ifdef WIN32 +#include +#endif /* WIN32 */ + +#ifdef MSDOS +#include +#include +#endif + +/* + * Savefile + */ +typedef enum { + NOT_SWAPPED, + SWAPPED, + MAYBE_SWAPPED +} swapped_type_t; + +struct pcap_sf { + FILE *rfile; + int swapped; + int hdrsize; + swapped_type_t lengths_swapped; + int version_major; + int version_minor; + u_char *base; +}; + +struct pcap_md { + struct pcap_stat stat; + /*XXX*/ + int use_bpf; /* using kernel filter */ + u_long TotPkts; /* can't oflow for 79 hrs on ether */ + u_long TotAccepted; /* count accepted by filter */ + u_long TotDrops; /* count of dropped packets */ + long TotMissed; /* missed by i/f during this run */ + long OrigMissed; /* missed by i/f before this run */ + char *device; /* device name */ +#ifdef linux + int sock_packet; /* using Linux 2.0 compatible interface */ + int timeout; /* timeout specified to pcap_open_live */ + int clear_promisc; /* must clear promiscuous mode when we close */ + int cooked; /* using SOCK_DGRAM rather than SOCK_RAW */ + int ifindex; /* interface index of device we're bound to */ + int lo_ifindex; /* interface index of the loopback device */ + struct pcap *next; /* list of open promiscuous sock_packet pcaps */ + u_int packets_read; /* count of packets read with recvfrom() */ +#endif + +#ifdef HAVE_DAG_API +#ifdef HAVE_DAG_STREAMS_API + u_char *dag_mem_bottom; /* DAG card current memory bottom pointer */ + u_char *dag_mem_top; /* DAG card current memory top pointer */ +#else + void *dag_mem_base; /* DAG card memory base address */ + u_int dag_mem_bottom; /* DAG card current memory bottom offset */ + u_int dag_mem_top; /* DAG card current memory top offset */ +#endif /* HAVE_DAG_STREAMS_API */ + int dag_fcs_bits; /* Number of checksum bits from link layer */ + int dag_offset_flags; /* Flags to pass to dag_offset(). */ + int dag_stream; /* DAG stream number */ + int dag_timeout; /* timeout specified to pcap_open_live. + * Same as in linux above, introduce + * generally? */ +#endif /* HAVE_DAG_API */ + +#ifdef HAVE_REMOTE +/*! + There is really a mess with previous variables, and it seems to me that they are not used + (they are used in pcap_pf.c only). I think we have to start using them. + The meaning is the following: + + - TotPkts: the amount of packets received by the bpf filter, *before* applying the filter + - TotAccepted: the amount of packets that satisfies the filter + - TotDrops: the amount of packet that were dropped into the kernel buffer because of lack of space + - TotMissed: the amount of packets that were dropped by the physical interface; it is basically + the value of the hardware counter into the card. This number is never put to zero, so this number + takes into account the *total* number of interface drops starting from the interface power-on. + - OrigMissed: the amount of packets that were dropped by the interface *when the capture begins*. + This value is used to detect the number of packets dropped by the interface *during the present + capture*, so that (ps_ifdrops= TotMissed - OrigMissed). +*/ + unsigned int TotNetDrops; //!< keeps the number of packets that have been dropped by the network +/*! + \brief It keeps the number of packets that have been received by the application. + + Packets dropped by the kernel buffer are not counted in this variable. The variable is always + equal to (TotAccepted - TotDrops), exept for the case of remote capture, in which we have also + packets in fligh, i.e. that have been transmitted by the remote host, but that have not been + received (yet) from the client. In this case, (TotAccepted - TotDrops - TotNetDrops) gives a + wrong result, since this number does not corresponds always to the number of packet received by + the application. For this reason, in the remote capture we need another variable that takes + into account of the number of packets actually received by the application. +*/ + unsigned int TotCapt; +#endif /* HAVE_REMOTE */ +}; + +/* + * Ultrix, DEC OSF/1^H^H^H^H^H^H^H^H^HDigital UNIX^H^H^H^H^H^H^H^H^H^H^H^H + * Tru64 UNIX, and NetBSD pad to make everything line up on a nice boundary. + */ +#if defined(ultrix) || defined(__osf__) || (defined(__NetBSD__) && __NetBSD_Version__ > 106000000) +#define PCAP_FDDIPAD 3 +#endif + +struct pcap { +#ifdef WIN32 + ADAPTER *adapter; + LPPACKET Packet; + int timeout; + int nonblock; +#else + int fd; + int selectable_fd; + int send_fd; +#endif /* WIN32 */ + int snapshot; + int linktype; + int tzoff; /* timezone offset */ + int offset; /* offset for proper alignment */ + + int break_loop; /* flag set to force break from packet-reading loop */ + +#ifdef PCAP_FDDIPAD + int fddipad; +#endif + +#ifdef MSDOS + int inter_packet_wait; /* offline: wait between packets */ + void (*wait_proc)(void); /* call proc while waiting */ +#endif + + struct pcap_sf sf; + struct pcap_md md; + + /* + * Read buffer. + */ + int bufsize; + u_char *buffer; + u_char *bp; + int cc; + + /* + * Place holder for pcap_next(). + */ + u_char *pkt; + + /* We're accepting only packets in this direction/these directions. */ + pcap_direction_t direction; + + /* + * Methods. + */ + int (*read_op)(pcap_t *, int cnt, pcap_handler, u_char *); + int (*inject_op)(pcap_t *, const void *, size_t); + int (*setfilter_op)(pcap_t *, struct bpf_program *); + int (*setdirection_op)(pcap_t *, pcap_direction_t); + int (*set_datalink_op)(pcap_t *, int); + int (*getnonblock_op)(pcap_t *, char *); + int (*setnonblock_op)(pcap_t *, int, char *); + int (*stats_op)(pcap_t *, struct pcap_stat *); + void (*close_op)(pcap_t *); + + /* + * Placeholder for filter code if bpf not in kernel. + */ + struct bpf_program fcode; + + char errbuf[PCAP_ERRBUF_SIZE + 1]; + int dlt_count; + u_int *dlt_list; + + struct pcap_pkthdr pcap_header; /* This is needed for the pcap_next_ex() to work */ + +#ifdef HAVE_REMOTE +#ifndef WIN32 // Win32 already defines 'timeout' + int timeout; //!< timeout to be used in the pcap_open() +#endif + /*! \brief '1' if we're the network client; needed by several functions (like pcap_setfilter() ) to know if + they have to use the socket or they have to open the local adapter. */ + int rmt_clientside; + + SOCKET rmt_sockctrl; //!< socket ID of the socket used for the control connection + SOCKET rmt_sockdata; //!< socket ID of the socket used for the data connection + int rmt_flags; //!< we have to save flags, since they are passed by the pcap_open_live(), but they are used by the pcap_startcapture() + int rmt_capstarted; //!< 'true' if the capture is already started (needed to knoe if we have to call the pcap_startcapture() + struct pcap_samp rmt_samp; //!< Keeps the parameters related to the sampling process. + char *currentfilter; //!< Pointer to a buffer (allocated at run-time) that stores the current filter. Needed when flag PCAP_OPENFLAG_NOCAPTURE_RPCAP is turned on. +#endif /* HAVE_REMOTE */ +}; + +/* + * This is a timeval as stored in a savefile. + * It has to use the same types everywhere, independent of the actual + * `struct timeval'; `struct timeval' has 32-bit tv_sec values on some + * platforms and 64-bit tv_sec values on other platforms, and writing + * out native `struct timeval' values would mean files could only be + * read on systems with the same tv_sec size as the system on which + * the file was written. + */ + +struct pcap_timeval { + bpf_int32 tv_sec; /* seconds */ + bpf_int32 tv_usec; /* microseconds */ +}; + +/* + * This is a `pcap_pkthdr' as actually stored in a savefile. + * + * Do not change the format of this structure, in any way (this includes + * changes that only affect the length of fields in this structure), + * and do not make the time stamp anything other than seconds and + * microseconds (e.g., seconds and nanoseconds). Instead: + * + * introduce a new structure for the new format; + * + * send mail to "tcpdump-workers@tcpdump.org", requesting a new + * magic number for your new capture file format, and, when + * you get the new magic number, put it in "savefile.c"; + * + * use that magic number for save files with the changed record + * header; + * + * make the code in "savefile.c" capable of reading files with + * the old record header as well as files with the new record header + * (using the magic number to determine the header format). + * + * Then supply the changes to "patches@tcpdump.org", so that future + * versions of libpcap and programs that use it (such as tcpdump) will + * be able to read your new capture file format. + */ + +struct pcap_sf_pkthdr { + struct pcap_timeval ts; /* time stamp */ + bpf_u_int32 caplen; /* length of portion present */ + bpf_u_int32 len; /* length this packet (off wire) */ +}; + +/* + * How a `pcap_pkthdr' is actually stored in savefiles written + * by some patched versions of libpcap (e.g. the ones in Red + * Hat Linux 6.1 and 6.2). + * + * Do not change the format of this structure, in any way (this includes + * changes that only affect the length of fields in this structure). + * Instead, introduce a new structure, as per the above. + */ + +struct pcap_sf_patched_pkthdr { + struct pcap_timeval ts; /* time stamp */ + bpf_u_int32 caplen; /* length of portion present */ + bpf_u_int32 len; /* length this packet (off wire) */ + int index; + unsigned short protocol; + unsigned char pkt_type; +}; + +int yylex(void); + +#ifndef min +#define min(a, b) ((a) > (b) ? (b) : (a)) +#endif + +/* XXX should these be in pcap.h? */ +int pcap_offline_read(pcap_t *, int, pcap_handler, u_char *); +int pcap_read(pcap_t *, int cnt, pcap_handler, u_char *); + +#ifndef HAVE_STRLCPY +#define strlcpy(x, y, z) \ + (strncpy((x), (y), (z)), \ + ((z) <= 0 ? 0 : ((x)[(z) - 1] = '\0')), \ + strlen((y))) +#endif + +#include + +#if !defined(HAVE_SNPRINTF) +#define snprintf pcap_snprintf +extern int snprintf (char *, size_t, const char *, ...); +#endif + +#if !defined(HAVE_VSNPRINTF) +#define vsnprintf pcap_vsnprintf +extern int vsnprintf (char *, size_t, const char *, va_list ap); +#endif + +/* + * Routines that most pcap implementations can use for non-blocking mode. + */ +#if !defined(WIN32) && !defined(MSDOS) +int pcap_getnonblock_fd(pcap_t *, char *); +int pcap_setnonblock_fd(pcap_t *p, int, char *); +#endif + +void pcap_close_common(pcap_t *); + +/* + * Internal interfaces for "pcap_findalldevs()". + * + * "pcap_platform_finddevs()" is a platform-dependent routine to + * add devices not found by the "standard" mechanisms (SIOCGIFCONF, + * "getifaddrs()", etc.. + * + * "pcap_add_if()" adds an interface to the list of interfaces. + */ +int pcap_platform_finddevs(pcap_if_t **, char *); +int add_addr_to_iflist(pcap_if_t **, const char *, u_int, struct sockaddr *, + size_t, struct sockaddr *, size_t, struct sockaddr *, size_t, + struct sockaddr *, size_t, char *); +int pcap_add_if(pcap_if_t **, const char *, u_int, const char *, char *); +struct sockaddr *dup_sockaddr(struct sockaddr *, size_t); +int add_or_find_if(pcap_if_t **, pcap_if_t **, const char *, u_int, + const char *, char *); + +#ifdef WIN32 +char *pcap_win32strerror(void); +#endif + +int install_bpf_program(pcap_t *, struct bpf_program *); + +int pcap_strcasecmp(const char *, const char *); + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/desmume/src/windows/winpcap/pcap-stdinc.h b/src/windows/winpcap/pcap-stdinc.h similarity index 97% rename from desmume/src/windows/winpcap/pcap-stdinc.h rename to src/windows/winpcap/pcap-stdinc.h index 12810247e..0d8bd6d4b 100644 --- a/desmume/src/windows/winpcap/pcap-stdinc.h +++ b/src/windows/winpcap/pcap-stdinc.h @@ -1,64 +1,64 @@ -/* - * Copyright (c) 2002 - 2003 - * NetGroup, Politecnico di Torino (Italy) - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * 3. Neither the name of the Politecnico di Torino nor the names of its - * contributors may be used to endorse or promote products derived from - * this software without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS - * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT - * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR - * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT - * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, - * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY - * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT - * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE - * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * - */ - -#define SIZEOF_CHAR 1 -#define SIZEOF_SHORT 2 -#define SIZEOF_INT 4 -#ifndef _MSC_EXTENSIONS -#define SIZEOF_LONG_LONG 8 -#endif - -/* - * Avoids a compiler warning in case this was already defined - * (someone defined _WINSOCKAPI_ when including 'windows.h', in order - * to prevent it from including 'winsock.h') - */ -#ifdef _WINSOCKAPI_ -#undef _WINSOCKAPI_ -#endif -#include - -#include - -#include "bittypes.h" -#include -#include - -#ifndef __MINGW32__ -#include "IP6_misc.h" -#endif - -#define caddr_t char* - -#define snprintf _snprintf -#define vsnprintf _vsnprintf -#define inline __inline +/* + * Copyright (c) 2002 - 2003 + * NetGroup, Politecnico di Torino (Italy) + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. Neither the name of the Politecnico di Torino nor the names of its + * contributors may be used to endorse or promote products derived from + * this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR + * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT + * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE + * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ + +#define SIZEOF_CHAR 1 +#define SIZEOF_SHORT 2 +#define SIZEOF_INT 4 +#ifndef _MSC_EXTENSIONS +#define SIZEOF_LONG_LONG 8 +#endif + +/* + * Avoids a compiler warning in case this was already defined + * (someone defined _WINSOCKAPI_ when including 'windows.h', in order + * to prevent it from including 'winsock.h') + */ +#ifdef _WINSOCKAPI_ +#undef _WINSOCKAPI_ +#endif +#include + +#include + +#include "bittypes.h" +#include +#include + +#ifndef __MINGW32__ +#include "IP6_misc.h" +#endif + +#define caddr_t char* + +#define snprintf _snprintf +#define vsnprintf _vsnprintf +#define inline __inline diff --git a/desmume/src/windows/winpcap/pcap.h b/src/windows/winpcap/pcap.h similarity index 97% rename from desmume/src/windows/winpcap/pcap.h rename to src/windows/winpcap/pcap.h index c8a57119c..cbb0f06f6 100644 --- a/desmume/src/windows/winpcap/pcap.h +++ b/src/windows/winpcap/pcap.h @@ -1,344 +1,344 @@ -/* -*- Mode: c; tab-width: 8; indent-tabs-mode: 1; c-basic-offset: 8; -*- */ -/* - * Copyright (c) 1993, 1994, 1995, 1996, 1997 - * The Regents of the University of California. All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * 3. All advertising materials mentioning features or use of this software - * must display the following acknowledgement: - * This product includes software developed by the Computer Systems - * Engineering Group at Lawrence Berkeley Laboratory. - * 4. Neither the name of the University nor of the Laboratory may be used - * to endorse or promote products derived from this software without - * specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND - * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE - * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE - * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS - * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) - * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY - * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * - * @(#) $Header: /tcpdump/master/libpcap/pcap.h,v 1.52.2.6 2006/02/09 22:26:49 guy Exp $ (LBL) - */ - -#ifndef lib_pcap_h -#define lib_pcap_h - -#if defined(WIN32) - #include -#elif defined(MSDOS) - #include - #include /* u_int, u_char etc. */ -#else /* UN*X */ - #include - #include -#endif /* WIN32/MSDOS/UN*X */ - -#ifndef PCAP_DONT_INCLUDE_PCAP_BPF_H -#include -#endif - -#include - -#ifdef HAVE_REMOTE - // We have to define the SOCKET here, although it has been defined in sockutils.h - // This is to avoid the distribution of the 'sockutils.h' file around - // (for example in the WinPcap developer's pack) - #ifndef SOCKET - #ifdef WIN32 - #define SOCKET unsigned int - #else - #define SOCKET int - #endif - #endif -#endif - -#ifdef __cplusplus -extern "C" { -#endif - -#define PCAP_VERSION_MAJOR 2 -#define PCAP_VERSION_MINOR 4 - -#define PCAP_ERRBUF_SIZE 256 - -/* - * Compatibility for systems that have a bpf.h that - * predates the bpf typedefs for 64-bit support. - */ -#if BPF_RELEASE - 0 < 199406 -typedef int bpf_int32; -typedef u_int bpf_u_int32; -#endif - -typedef struct pcap pcap_t; -typedef struct pcap_dumper pcap_dumper_t; -typedef struct pcap_if pcap_if_t; -typedef struct pcap_addr pcap_addr_t; - -/* - * The first record in the file contains saved values for some - * of the flags used in the printout phases of tcpdump. - * Many fields here are 32 bit ints so compilers won't insert unwanted - * padding; these files need to be interchangeable across architectures. - * - * Do not change the layout of this structure, in any way (this includes - * changes that only affect the length of fields in this structure). - * - * Also, do not change the interpretation of any of the members of this - * structure, in any way (this includes using values other than - * LINKTYPE_ values, as defined in "savefile.c", in the "linktype" - * field). - * - * Instead: - * - * introduce a new structure for the new format, if the layout - * of the structure changed; - * - * send mail to "tcpdump-workers@tcpdump.org", requesting a new - * magic number for your new capture file format, and, when - * you get the new magic number, put it in "savefile.c"; - * - * use that magic number for save files with the changed file - * header; - * - * make the code in "savefile.c" capable of reading files with - * the old file header as well as files with the new file header - * (using the magic number to determine the header format). - * - * Then supply the changes to "patches@tcpdump.org", so that future - * versions of libpcap and programs that use it (such as tcpdump) will - * be able to read your new capture file format. - */ -struct pcap_file_header { - bpf_u_int32 magic; - u_short version_major; - u_short version_minor; - bpf_int32 thiszone; /* gmt to local correction */ - bpf_u_int32 sigfigs; /* accuracy of timestamps */ - bpf_u_int32 snaplen; /* max length saved portion of each pkt */ - bpf_u_int32 linktype; /* data link type (LINKTYPE_*) */ -}; - -typedef enum { - PCAP_D_INOUT = 0, - PCAP_D_IN, - PCAP_D_OUT -} pcap_direction_t; - -/* - * Generic per-packet information, as supplied by libpcap. - * - * The time stamp can and should be a "struct timeval", regardless of - * whether your system supports 32-bit tv_sec in "struct timeval", - * 64-bit tv_sec in "struct timeval", or both if it supports both 32-bit - * and 64-bit applications. The on-disk format of savefiles uses 32-bit - * tv_sec (and tv_usec); this structure is irrelevant to that. 32-bit - * and 64-bit versions of libpcap, even if they're on the same platform, - * should supply the appropriate version of "struct timeval", even if - * that's not what the underlying packet capture mechanism supplies. - */ -struct pcap_pkthdr { - struct timeval ts; /* time stamp */ - bpf_u_int32 caplen; /* length of portion present */ - bpf_u_int32 len; /* length this packet (off wire) */ -}; - -/* - * As returned by the pcap_stats() - */ -struct pcap_stat { - u_int ps_recv; /* number of packets received */ - u_int ps_drop; /* number of packets dropped */ - u_int ps_ifdrop; /* drops by interface XXX not yet supported */ -#ifdef HAVE_REMOTE - u_int ps_capt; /* number of packets that are received by the application; please get rid off the Win32 ifdef */ - u_int ps_sent; /* number of packets sent by the server on the network */ - u_int ps_netdrop; /* number of packets lost on the network */ -#endif /* HAVE_REMOTE */ -}; - -#ifdef MSDOS -/* - * As returned by the pcap_stats_ex() - */ -struct pcap_stat_ex { - u_long rx_packets; /* total packets received */ - u_long tx_packets; /* total packets transmitted */ - u_long rx_bytes; /* total bytes received */ - u_long tx_bytes; /* total bytes transmitted */ - u_long rx_errors; /* bad packets received */ - u_long tx_errors; /* packet transmit problems */ - u_long rx_dropped; /* no space in Rx buffers */ - u_long tx_dropped; /* no space available for Tx */ - u_long multicast; /* multicast packets received */ - u_long collisions; - - /* detailed rx_errors: */ - u_long rx_length_errors; - u_long rx_over_errors; /* receiver ring buff overflow */ - u_long rx_crc_errors; /* recv'd pkt with crc error */ - u_long rx_frame_errors; /* recv'd frame alignment error */ - u_long rx_fifo_errors; /* recv'r fifo overrun */ - u_long rx_missed_errors; /* recv'r missed packet */ - - /* detailed tx_errors */ - u_long tx_aborted_errors; - u_long tx_carrier_errors; - u_long tx_fifo_errors; - u_long tx_heartbeat_errors; - u_long tx_window_errors; - }; -#endif - -/* - * Item in a list of interfaces. - */ -struct pcap_if { - struct pcap_if *next; - char *name; /* name to hand to "pcap_open_live()" */ - char *description; /* textual description of interface, or NULL */ - struct pcap_addr *addresses; - bpf_u_int32 flags; /* PCAP_IF_ interface flags */ -}; - -#define PCAP_IF_LOOPBACK 0x00000001 /* interface is loopback */ - -/* - * Representation of an interface address. - */ -struct pcap_addr { - struct pcap_addr *next; - struct sockaddr *addr; /* address */ - struct sockaddr *netmask; /* netmask for that address */ - struct sockaddr *broadaddr; /* broadcast address for that address */ - struct sockaddr *dstaddr; /* P2P destination address for that address */ -}; - -typedef void (*pcap_handler)(u_char *, const struct pcap_pkthdr *, - const u_char *); - -char *pcap_lookupdev(char *); -int pcap_lookupnet(const char *, bpf_u_int32 *, bpf_u_int32 *, char *); -pcap_t *pcap_open_live(const char *, int, int, int, char *); -pcap_t *pcap_open_dead(int, int); -pcap_t *pcap_open_offline(const char *, char *); -pcap_t *pcap_fopen_offline(FILE *, char *); -void pcap_close(pcap_t *); -int pcap_loop(pcap_t *, int, pcap_handler, u_char *); -int pcap_dispatch(pcap_t *, int, pcap_handler, u_char *); -const u_char* - pcap_next(pcap_t *, struct pcap_pkthdr *); -int pcap_next_ex(pcap_t *, struct pcap_pkthdr **, const u_char **); -void pcap_breakloop(pcap_t *); -int pcap_stats(pcap_t *, struct pcap_stat *); -int pcap_setfilter(pcap_t *, struct bpf_program *); -int pcap_setdirection(pcap_t *, pcap_direction_t); -int pcap_getnonblock(pcap_t *, char *); -int pcap_setnonblock(pcap_t *, int, char *); -void pcap_perror(pcap_t *, char *); -int pcap_inject(pcap_t *, const void *, size_t); -int pcap_sendpacket(pcap_t *, const u_char *, int); -char *pcap_strerror(int); -char *pcap_geterr(pcap_t *); -int pcap_compile(pcap_t *, struct bpf_program *, char *, int, - bpf_u_int32); -int pcap_compile_nopcap(int, int, struct bpf_program *, - char *, int, bpf_u_int32); -void pcap_freecode(struct bpf_program *); -int pcap_datalink(pcap_t *); -int pcap_list_datalinks(pcap_t *, int **); -int pcap_set_datalink(pcap_t *, int); -int pcap_datalink_name_to_val(const char *); -const char *pcap_datalink_val_to_name(int); -const char *pcap_datalink_val_to_description(int); -int pcap_snapshot(pcap_t *); -int pcap_is_swapped(pcap_t *); -int pcap_major_version(pcap_t *); -int pcap_minor_version(pcap_t *); - -/* XXX */ -FILE *pcap_file(pcap_t *); -int pcap_fileno(pcap_t *); - -pcap_dumper_t *pcap_dump_open(pcap_t *, const char *); -pcap_dumper_t *pcap_dump_fopen(pcap_t *, FILE *fp); -FILE *pcap_dump_file(pcap_dumper_t *); -long pcap_dump_ftell(pcap_dumper_t *); -int pcap_dump_flush(pcap_dumper_t *); -void pcap_dump_close(pcap_dumper_t *); -void pcap_dump(u_char *, const struct pcap_pkthdr *, const u_char *); - -int pcap_findalldevs(pcap_if_t **, char *); -void pcap_freealldevs(pcap_if_t *); - -const char *pcap_lib_version(void); - -/* XXX this guy lives in the bpf tree */ -u_int bpf_filter(struct bpf_insn *, u_char *, u_int, u_int); -int bpf_validate(struct bpf_insn *f, int len); -char *bpf_image(struct bpf_insn *, int); -void bpf_dump(struct bpf_program *, int); - -#if defined(WIN32) - -/* - * Win32 definitions - */ - -int pcap_setbuff(pcap_t *p, int dim); -int pcap_setmode(pcap_t *p, int mode); -int pcap_setmintocopy(pcap_t *p, int size); - -#ifdef WPCAP -/* Include file with the wpcap-specific extensions */ -#include -#endif /* WPCAP */ - -#define MODE_CAPT 0 -#define MODE_STAT 1 -#define MODE_MON 2 - -#elif defined(MSDOS) - -/* - * MS-DOS definitions - */ - -int pcap_stats_ex (pcap_t *, struct pcap_stat_ex *); -void pcap_set_wait (pcap_t *p, void (*yield)(void), int wait); -u_long pcap_mac_packets (void); - -#else /* UN*X */ - -/* - * UN*X definitions - */ - -int pcap_get_selectable_fd(pcap_t *); - -#endif /* WIN32/MSDOS/UN*X */ - -#ifdef HAVE_REMOTE -/* Includes most of the public stuff that is needed for the remote capture */ -#include "remote-ext.h" -#endif /* HAVE_REMOTE */ - -#ifdef __cplusplus -} -#endif - -#endif +/* -*- Mode: c; tab-width: 8; indent-tabs-mode: 1; c-basic-offset: 8; -*- */ +/* + * Copyright (c) 1993, 1994, 1995, 1996, 1997 + * The Regents of the University of California. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. All advertising materials mentioning features or use of this software + * must display the following acknowledgement: + * This product includes software developed by the Computer Systems + * Engineering Group at Lawrence Berkeley Laboratory. + * 4. Neither the name of the University nor of the Laboratory may be used + * to endorse or promote products derived from this software without + * specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * + * @(#) $Header: /tcpdump/master/libpcap/pcap.h,v 1.52.2.6 2006/02/09 22:26:49 guy Exp $ (LBL) + */ + +#ifndef lib_pcap_h +#define lib_pcap_h + +#if defined(WIN32) + #include +#elif defined(MSDOS) + #include + #include /* u_int, u_char etc. */ +#else /* UN*X */ + #include + #include +#endif /* WIN32/MSDOS/UN*X */ + +#ifndef PCAP_DONT_INCLUDE_PCAP_BPF_H +#include +#endif + +#include + +#ifdef HAVE_REMOTE + // We have to define the SOCKET here, although it has been defined in sockutils.h + // This is to avoid the distribution of the 'sockutils.h' file around + // (for example in the WinPcap developer's pack) + #ifndef SOCKET + #ifdef WIN32 + #define SOCKET unsigned int + #else + #define SOCKET int + #endif + #endif +#endif + +#ifdef __cplusplus +extern "C" { +#endif + +#define PCAP_VERSION_MAJOR 2 +#define PCAP_VERSION_MINOR 4 + +#define PCAP_ERRBUF_SIZE 256 + +/* + * Compatibility for systems that have a bpf.h that + * predates the bpf typedefs for 64-bit support. + */ +#if BPF_RELEASE - 0 < 199406 +typedef int bpf_int32; +typedef u_int bpf_u_int32; +#endif + +typedef struct pcap pcap_t; +typedef struct pcap_dumper pcap_dumper_t; +typedef struct pcap_if pcap_if_t; +typedef struct pcap_addr pcap_addr_t; + +/* + * The first record in the file contains saved values for some + * of the flags used in the printout phases of tcpdump. + * Many fields here are 32 bit ints so compilers won't insert unwanted + * padding; these files need to be interchangeable across architectures. + * + * Do not change the layout of this structure, in any way (this includes + * changes that only affect the length of fields in this structure). + * + * Also, do not change the interpretation of any of the members of this + * structure, in any way (this includes using values other than + * LINKTYPE_ values, as defined in "savefile.c", in the "linktype" + * field). + * + * Instead: + * + * introduce a new structure for the new format, if the layout + * of the structure changed; + * + * send mail to "tcpdump-workers@tcpdump.org", requesting a new + * magic number for your new capture file format, and, when + * you get the new magic number, put it in "savefile.c"; + * + * use that magic number for save files with the changed file + * header; + * + * make the code in "savefile.c" capable of reading files with + * the old file header as well as files with the new file header + * (using the magic number to determine the header format). + * + * Then supply the changes to "patches@tcpdump.org", so that future + * versions of libpcap and programs that use it (such as tcpdump) will + * be able to read your new capture file format. + */ +struct pcap_file_header { + bpf_u_int32 magic; + u_short version_major; + u_short version_minor; + bpf_int32 thiszone; /* gmt to local correction */ + bpf_u_int32 sigfigs; /* accuracy of timestamps */ + bpf_u_int32 snaplen; /* max length saved portion of each pkt */ + bpf_u_int32 linktype; /* data link type (LINKTYPE_*) */ +}; + +typedef enum { + PCAP_D_INOUT = 0, + PCAP_D_IN, + PCAP_D_OUT +} pcap_direction_t; + +/* + * Generic per-packet information, as supplied by libpcap. + * + * The time stamp can and should be a "struct timeval", regardless of + * whether your system supports 32-bit tv_sec in "struct timeval", + * 64-bit tv_sec in "struct timeval", or both if it supports both 32-bit + * and 64-bit applications. The on-disk format of savefiles uses 32-bit + * tv_sec (and tv_usec); this structure is irrelevant to that. 32-bit + * and 64-bit versions of libpcap, even if they're on the same platform, + * should supply the appropriate version of "struct timeval", even if + * that's not what the underlying packet capture mechanism supplies. + */ +struct pcap_pkthdr { + struct timeval ts; /* time stamp */ + bpf_u_int32 caplen; /* length of portion present */ + bpf_u_int32 len; /* length this packet (off wire) */ +}; + +/* + * As returned by the pcap_stats() + */ +struct pcap_stat { + u_int ps_recv; /* number of packets received */ + u_int ps_drop; /* number of packets dropped */ + u_int ps_ifdrop; /* drops by interface XXX not yet supported */ +#ifdef HAVE_REMOTE + u_int ps_capt; /* number of packets that are received by the application; please get rid off the Win32 ifdef */ + u_int ps_sent; /* number of packets sent by the server on the network */ + u_int ps_netdrop; /* number of packets lost on the network */ +#endif /* HAVE_REMOTE */ +}; + +#ifdef MSDOS +/* + * As returned by the pcap_stats_ex() + */ +struct pcap_stat_ex { + u_long rx_packets; /* total packets received */ + u_long tx_packets; /* total packets transmitted */ + u_long rx_bytes; /* total bytes received */ + u_long tx_bytes; /* total bytes transmitted */ + u_long rx_errors; /* bad packets received */ + u_long tx_errors; /* packet transmit problems */ + u_long rx_dropped; /* no space in Rx buffers */ + u_long tx_dropped; /* no space available for Tx */ + u_long multicast; /* multicast packets received */ + u_long collisions; + + /* detailed rx_errors: */ + u_long rx_length_errors; + u_long rx_over_errors; /* receiver ring buff overflow */ + u_long rx_crc_errors; /* recv'd pkt with crc error */ + u_long rx_frame_errors; /* recv'd frame alignment error */ + u_long rx_fifo_errors; /* recv'r fifo overrun */ + u_long rx_missed_errors; /* recv'r missed packet */ + + /* detailed tx_errors */ + u_long tx_aborted_errors; + u_long tx_carrier_errors; + u_long tx_fifo_errors; + u_long tx_heartbeat_errors; + u_long tx_window_errors; + }; +#endif + +/* + * Item in a list of interfaces. + */ +struct pcap_if { + struct pcap_if *next; + char *name; /* name to hand to "pcap_open_live()" */ + char *description; /* textual description of interface, or NULL */ + struct pcap_addr *addresses; + bpf_u_int32 flags; /* PCAP_IF_ interface flags */ +}; + +#define PCAP_IF_LOOPBACK 0x00000001 /* interface is loopback */ + +/* + * Representation of an interface address. + */ +struct pcap_addr { + struct pcap_addr *next; + struct sockaddr *addr; /* address */ + struct sockaddr *netmask; /* netmask for that address */ + struct sockaddr *broadaddr; /* broadcast address for that address */ + struct sockaddr *dstaddr; /* P2P destination address for that address */ +}; + +typedef void (*pcap_handler)(u_char *, const struct pcap_pkthdr *, + const u_char *); + +char *pcap_lookupdev(char *); +int pcap_lookupnet(const char *, bpf_u_int32 *, bpf_u_int32 *, char *); +pcap_t *pcap_open_live(const char *, int, int, int, char *); +pcap_t *pcap_open_dead(int, int); +pcap_t *pcap_open_offline(const char *, char *); +pcap_t *pcap_fopen_offline(FILE *, char *); +void pcap_close(pcap_t *); +int pcap_loop(pcap_t *, int, pcap_handler, u_char *); +int pcap_dispatch(pcap_t *, int, pcap_handler, u_char *); +const u_char* + pcap_next(pcap_t *, struct pcap_pkthdr *); +int pcap_next_ex(pcap_t *, struct pcap_pkthdr **, const u_char **); +void pcap_breakloop(pcap_t *); +int pcap_stats(pcap_t *, struct pcap_stat *); +int pcap_setfilter(pcap_t *, struct bpf_program *); +int pcap_setdirection(pcap_t *, pcap_direction_t); +int pcap_getnonblock(pcap_t *, char *); +int pcap_setnonblock(pcap_t *, int, char *); +void pcap_perror(pcap_t *, char *); +int pcap_inject(pcap_t *, const void *, size_t); +int pcap_sendpacket(pcap_t *, const u_char *, int); +char *pcap_strerror(int); +char *pcap_geterr(pcap_t *); +int pcap_compile(pcap_t *, struct bpf_program *, char *, int, + bpf_u_int32); +int pcap_compile_nopcap(int, int, struct bpf_program *, + char *, int, bpf_u_int32); +void pcap_freecode(struct bpf_program *); +int pcap_datalink(pcap_t *); +int pcap_list_datalinks(pcap_t *, int **); +int pcap_set_datalink(pcap_t *, int); +int pcap_datalink_name_to_val(const char *); +const char *pcap_datalink_val_to_name(int); +const char *pcap_datalink_val_to_description(int); +int pcap_snapshot(pcap_t *); +int pcap_is_swapped(pcap_t *); +int pcap_major_version(pcap_t *); +int pcap_minor_version(pcap_t *); + +/* XXX */ +FILE *pcap_file(pcap_t *); +int pcap_fileno(pcap_t *); + +pcap_dumper_t *pcap_dump_open(pcap_t *, const char *); +pcap_dumper_t *pcap_dump_fopen(pcap_t *, FILE *fp); +FILE *pcap_dump_file(pcap_dumper_t *); +long pcap_dump_ftell(pcap_dumper_t *); +int pcap_dump_flush(pcap_dumper_t *); +void pcap_dump_close(pcap_dumper_t *); +void pcap_dump(u_char *, const struct pcap_pkthdr *, const u_char *); + +int pcap_findalldevs(pcap_if_t **, char *); +void pcap_freealldevs(pcap_if_t *); + +const char *pcap_lib_version(void); + +/* XXX this guy lives in the bpf tree */ +u_int bpf_filter(struct bpf_insn *, u_char *, u_int, u_int); +int bpf_validate(struct bpf_insn *f, int len); +char *bpf_image(struct bpf_insn *, int); +void bpf_dump(struct bpf_program *, int); + +#if defined(WIN32) + +/* + * Win32 definitions + */ + +int pcap_setbuff(pcap_t *p, int dim); +int pcap_setmode(pcap_t *p, int mode); +int pcap_setmintocopy(pcap_t *p, int size); + +#ifdef WPCAP +/* Include file with the wpcap-specific extensions */ +#include +#endif /* WPCAP */ + +#define MODE_CAPT 0 +#define MODE_STAT 1 +#define MODE_MON 2 + +#elif defined(MSDOS) + +/* + * MS-DOS definitions + */ + +int pcap_stats_ex (pcap_t *, struct pcap_stat_ex *); +void pcap_set_wait (pcap_t *p, void (*yield)(void), int wait); +u_long pcap_mac_packets (void); + +#else /* UN*X */ + +/* + * UN*X definitions + */ + +int pcap_get_selectable_fd(pcap_t *); + +#endif /* WIN32/MSDOS/UN*X */ + +#ifdef HAVE_REMOTE +/* Includes most of the public stuff that is needed for the remote capture */ +#include "remote-ext.h" +#endif /* HAVE_REMOTE */ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/desmume/src/windows/winpcap/remote-ext.h b/src/windows/winpcap/remote-ext.h similarity index 97% rename from desmume/src/windows/winpcap/remote-ext.h rename to src/windows/winpcap/remote-ext.h index b3884c9c8..9db8055f9 100644 --- a/desmume/src/windows/winpcap/remote-ext.h +++ b/src/windows/winpcap/remote-ext.h @@ -1,441 +1,441 @@ -/* - * Copyright (c) 2002 - 2003 - * NetGroup, Politecnico di Torino (Italy) - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * 3. Neither the name of the Politecnico di Torino nor the names of its - * contributors may be used to endorse or promote products derived from - * this software without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS - * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT - * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR - * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT - * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, - * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY - * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT - * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE - * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * - */ - - -#ifndef __REMOTE_EXT_H__ -#define __REMOTE_EXT_H__ - - - -// Definition for Microsoft Visual Studio -#if _MSC_VER > 1000 -#pragma once -#endif - -#ifdef __cplusplus -extern "C" { -#endif - -/*! - \file remote-ext.h - - The goal of this file it to include most of the new definitions that should be - placed into the pcap.h file. - - It includes all new definitions (structures and functions like pcap_open(). - Some of the functions are not really a remote feature, but, right now, - they are placed here. -*/ - - - -// All this stuff is public -/*! \addtogroup remote_struct - \{ -*/ - - - - -/*! - \brief Defines the maximum buffer size in which address, port, interface names are kept. - - In case the adapter name or such is larger than this value, it is truncated. - This is not used by the user; however it must be aware that an hostname / interface - name longer than this value will be truncated. -*/ -#define PCAP_BUF_SIZE 1024 - - -/*! \addtogroup remote_source_ID - \{ -*/ - - -/*! - \brief Internal representation of the type of source in use (file, - remote/local interface). - - This indicates a file, i.e. the user want to open a capture from a local file. -*/ -#define PCAP_SRC_FILE 2 -/*! - \brief Internal representation of the type of source in use (file, - remote/local interface). - - This indicates a local interface, i.e. the user want to open a capture from - a local interface. This does not involve the RPCAP protocol. -*/ -#define PCAP_SRC_IFLOCAL 3 -/*! - \brief Internal representation of the type of source in use (file, - remote/local interface). - - This indicates a remote interface, i.e. the user want to open a capture from - an interface on a remote host. This does involve the RPCAP protocol. -*/ -#define PCAP_SRC_IFREMOTE 4 - -/*! - \} -*/ - - - -/*! \addtogroup remote_source_string - - The formats allowed by the pcap_open() are the following: - - file://path_and_filename [opens a local file] - - rpcap://devicename [opens the selected device devices available on the local host, without using the RPCAP protocol] - - rpcap://host/devicename [opens the selected device available on a remote host] - - rpcap://host:port/devicename [opens the selected device available on a remote host, using a non-standard port for RPCAP] - - adaptername [to open a local adapter; kept for compability, but it is strongly discouraged] - - (NULL) [to open the first local adapter; kept for compability, but it is strongly discouraged] - - The formats allowed by the pcap_findalldevs_ex() are the following: - - file://folder/ [lists all the files in the given folder] - - rpcap:// [lists all local adapters] - - rpcap://host:port/ [lists the devices available on a remote host] - - Referring to the 'host' and 'port' paramters, they can be either numeric or literal. Since - IPv6 is fully supported, these are the allowed formats: - - - host (literal): e.g. host.foo.bar - - host (numeric IPv4): e.g. 10.11.12.13 - - host (numeric IPv4, IPv6 style): e.g. [10.11.12.13] - - host (numeric IPv6): e.g. [1:2:3::4] - - port: can be either numeric (e.g. '80') or literal (e.g. 'http') - - Here you find some allowed examples: - - rpcap://host.foo.bar/devicename [everything literal, no port number] - - rpcap://host.foo.bar:1234/devicename [everything literal, with port number] - - rpcap://10.11.12.13/devicename [IPv4 numeric, no port number] - - rpcap://10.11.12.13:1234/devicename [IPv4 numeric, with port number] - - rpcap://[10.11.12.13]:1234/devicename [IPv4 numeric with IPv6 format, with port number] - - rpcap://[1:2:3::4]/devicename [IPv6 numeric, no port number] - - rpcap://[1:2:3::4]:1234/devicename [IPv6 numeric, with port number] - - rpcap://[1:2:3::4]:http/devicename [IPv6 numeric, with literal port number] - - \{ -*/ - - -/*! - \brief String that will be used to determine the type of source in use (file, - remote/local interface). - - This string will be prepended to the interface name in order to create a string - that contains all the information required to open the source. - - This string indicates that the user wants to open a capture from a local file. -*/ -#define PCAP_SRC_FILE_STRING "file://" -/*! - \brief String that will be used to determine the type of source in use (file, - remote/local interface). - - This string will be prepended to the interface name in order to create a string - that contains all the information required to open the source. - - This string indicates that the user wants to open a capture from a network interface. - This string does not necessarily involve the use of the RPCAP protocol. If the - interface required resides on the local host, the RPCAP protocol is not involved - and the local functions are used. -*/ -#define PCAP_SRC_IF_STRING "rpcap://" - -/*! - \} -*/ - - - - - -/*! - \addtogroup remote_open_flags - \{ -*/ - -/*! - \brief Defines if the adapter has to go in promiscuous mode. - - It is '1' if you have to open the adapter in promiscuous mode, '0' otherwise. - Note that even if this parameter is false, the interface could well be in promiscuous - mode for some other reason (for example because another capture process with - promiscuous mode enabled is currently using that interface). - On on Linux systems with 2.2 or later kernels (that have the "any" device), this - flag does not work on the "any" device; if an argument of "any" is supplied, - the 'promisc' flag is ignored. -*/ -#define PCAP_OPENFLAG_PROMISCUOUS 1 - -/*! - \brief Defines if the data trasfer (in case of a remote - capture) has to be done with UDP protocol. - - If it is '1' if you want a UDP data connection, '0' if you want - a TCP data connection; control connection is always TCP-based. - A UDP connection is much lighter, but it does not guarantee that all - the captured packets arrive to the client workstation. Moreover, - it could be harmful in case of network congestion. - This flag is meaningless if the source is not a remote interface. - In that case, it is simply ignored. -*/ -#define PCAP_OPENFLAG_DATATX_UDP 2 - - -/*! - \brief Defines if the remote probe will capture its own generated traffic. - - In case the remote probe uses the same interface to capture traffic and to send - data back to the caller, the captured traffic includes the RPCAP traffic as well. - If this flag is turned on, the RPCAP traffic is excluded from the capture, so that - the trace returned back to the collector is does not include this traffic. -*/ -#define PCAP_OPENFLAG_NOCAPTURE_RPCAP 4 - -/*! - \brief Defines if the local adapter will capture its own generated traffic. - - This flag tells the underlying capture driver to drop the packets that were sent by itself. - This is usefult when building applications like bridges, that should ignore the traffic - they just sent. -*/ -#define PCAP_OPENFLAG_NOCAPTURE_LOCAL 8 - -/*! - \brief This flag configures the adapter for maximum responsiveness. - - In presence of a large value for nbytes, WinPcap waits for the arrival of several packets before - copying the data to the user. This guarantees a low number of system calls, i.e. lower processor usage, - i.e. better performance, which is good for applications like sniffers. If the user sets the - PCAP_OPENFLAG_MAX_RESPONSIVENESS flag, the capture driver will copy the packets as soon as the application - is ready to receive them. This is suggested for real time applications (like, for example, a bridge) - that need the best responsiveness.*/ -#define PCAP_OPENFLAG_MAX_RESPONSIVENESS 16 - -/*! - \} -*/ - - -/*! - \addtogroup remote_samp_methods - \{ -*/ - -/*! - \brief No sampling has to be done on the current capture. - - In this case, no sampling algorithms are applied to the current capture. -*/ -#define PCAP_SAMP_NOSAMP 0 - -/*! - \brief It defines that only 1 out of N packets must be returned to the user. - - In this case, the 'value' field of the 'pcap_samp' structure indicates the - number of packets (minus 1) that must be discarded before one packet got accepted. - In other words, if 'value = 10', the first packet is returned to the caller, while - the following 9 are discarded. -*/ -#define PCAP_SAMP_1_EVERY_N 1 - -/*! - \brief It defines that we have to return 1 packet every N milliseconds. - - In this case, the 'value' field of the 'pcap_samp' structure indicates the 'waiting - time' in milliseconds before one packet got accepted. - In other words, if 'value = 10', the first packet is returned to the caller; the next - returned one will be the first packet that arrives when 10ms have elapsed. -*/ -#define PCAP_SAMP_FIRST_AFTER_N_MS 2 - -/*! - \} -*/ - - -/*! - \addtogroup remote_auth_methods - \{ -*/ - -/*! - \brief It defines the NULL authentication. - - This value has to be used within the 'type' member of the pcap_rmtauth structure. - The 'NULL' authentication has to be equal to 'zero', so that old applications - can just put every field of struct pcap_rmtauth to zero, and it does work. -*/ -#define RPCAP_RMTAUTH_NULL 0 -/*! - \brief It defines the username/password authentication. - - With this type of authentication, the RPCAP protocol will use the username/ - password provided to authenticate the user on the remote machine. If the - authentication is successful (and the user has the right to open network devices) - the RPCAP connection will continue; otherwise it will be dropped. - - This value has to be used within the 'type' member of the pcap_rmtauth structure. -*/ -#define RPCAP_RMTAUTH_PWD 1 - -/*! - \} -*/ - - - - -/*! - - \brief This structure keeps the information needed to autheticate - the user on a remote machine. - - The remote machine can either grant or refuse the access according - to the information provided. - In case the NULL authentication is required, both 'username' and - 'password' can be NULL pointers. - - This structure is meaningless if the source is not a remote interface; - in that case, the functions which requires such a structure can accept - a NULL pointer as well. -*/ -struct pcap_rmtauth -{ - /*! - \brief Type of the authentication required. - - In order to provide maximum flexibility, we can support different types - of authentication based on the value of this 'type' variable. The currently - supported authentication methods are defined into the - \link remote_auth_methods Remote Authentication Methods Section\endlink. - - */ - int type; - /*! - \brief Zero-terminated string containing the username that has to be - used on the remote machine for authentication. - - This field is meaningless in case of the RPCAP_RMTAUTH_NULL authentication - and it can be NULL. - */ - char *username; - /*! - \brief Zero-terminated string containing the password that has to be - used on the remote machine for authentication. - - This field is meaningless in case of the RPCAP_RMTAUTH_NULL authentication - and it can be NULL. - */ - char *password; -}; - - -/*! - \brief This structure defines the information related to sampling. - - In case the sampling is requested, the capturing device should read - only a subset of the packets coming from the source. The returned packets depend - on the sampling parameters. - - \warning The sampling process is applied after the filtering process. - In other words, packets are filtered first, then the sampling process selects a - subset of the 'filtered' packets and it returns them to the caller. -*/ -struct pcap_samp -{ - /*! - Method used for sampling. Currently, the supported methods are listed in the - \link remote_samp_methods Sampling Methods Section\endlink. - */ - int method; - - /*! - This value depends on the sampling method defined. For its meaning, please check - at the \link remote_samp_methods Sampling Methods Section\endlink. - */ - int value; -}; - - - - -//! Maximum lenght of an host name (needed for the RPCAP active mode) -#define RPCAP_HOSTLIST_SIZE 1024 - - -/*! - \} -*/ // end of public documentation - - -// Exported functions - - - -/** \name New WinPcap functions - - This section lists the new functions that are able to help considerably in writing - WinPcap programs because of their easiness of use. - */ -//\{ -pcap_t *pcap_open(const char *source, int snaplen, int flags, int read_timeout, struct pcap_rmtauth *auth, char *errbuf); -int pcap_createsrcstr(char *source, int type, const char *host, const char *port, const char *name, char *errbuf); -int pcap_parsesrcstr(const char *source, int *type, char *host, char *port, char *name, char *errbuf); -int pcap_findalldevs_ex(char *source, struct pcap_rmtauth *auth, pcap_if_t **alldevs, char *errbuf); -struct pcap_samp *pcap_setsampling(pcap_t *p); - -//\} -// End of new winpcap functions - - - -/** \name Remote Capture functions - */ -//\{ -SOCKET pcap_remoteact_accept(const char *address, const char *port, const char *hostlist, char *connectinghost, struct pcap_rmtauth *auth, char *errbuf); -int pcap_remoteact_list(char *hostlist, char sep, int size, char *errbuf); -int pcap_remoteact_close(const char *host, char *errbuf); -void pcap_remoteact_cleanup(); -//\} -// End of remote capture functions - -#ifdef __cplusplus -} -#endif - - -#endif - +/* + * Copyright (c) 2002 - 2003 + * NetGroup, Politecnico di Torino (Italy) + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. Neither the name of the Politecnico di Torino nor the names of its + * contributors may be used to endorse or promote products derived from + * this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR + * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT + * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE + * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ + + +#ifndef __REMOTE_EXT_H__ +#define __REMOTE_EXT_H__ + + + +// Definition for Microsoft Visual Studio +#if _MSC_VER > 1000 +#pragma once +#endif + +#ifdef __cplusplus +extern "C" { +#endif + +/*! + \file remote-ext.h + + The goal of this file it to include most of the new definitions that should be + placed into the pcap.h file. + + It includes all new definitions (structures and functions like pcap_open(). + Some of the functions are not really a remote feature, but, right now, + they are placed here. +*/ + + + +// All this stuff is public +/*! \addtogroup remote_struct + \{ +*/ + + + + +/*! + \brief Defines the maximum buffer size in which address, port, interface names are kept. + + In case the adapter name or such is larger than this value, it is truncated. + This is not used by the user; however it must be aware that an hostname / interface + name longer than this value will be truncated. +*/ +#define PCAP_BUF_SIZE 1024 + + +/*! \addtogroup remote_source_ID + \{ +*/ + + +/*! + \brief Internal representation of the type of source in use (file, + remote/local interface). + + This indicates a file, i.e. the user want to open a capture from a local file. +*/ +#define PCAP_SRC_FILE 2 +/*! + \brief Internal representation of the type of source in use (file, + remote/local interface). + + This indicates a local interface, i.e. the user want to open a capture from + a local interface. This does not involve the RPCAP protocol. +*/ +#define PCAP_SRC_IFLOCAL 3 +/*! + \brief Internal representation of the type of source in use (file, + remote/local interface). + + This indicates a remote interface, i.e. the user want to open a capture from + an interface on a remote host. This does involve the RPCAP protocol. +*/ +#define PCAP_SRC_IFREMOTE 4 + +/*! + \} +*/ + + + +/*! \addtogroup remote_source_string + + The formats allowed by the pcap_open() are the following: + - file://path_and_filename [opens a local file] + - rpcap://devicename [opens the selected device devices available on the local host, without using the RPCAP protocol] + - rpcap://host/devicename [opens the selected device available on a remote host] + - rpcap://host:port/devicename [opens the selected device available on a remote host, using a non-standard port for RPCAP] + - adaptername [to open a local adapter; kept for compability, but it is strongly discouraged] + - (NULL) [to open the first local adapter; kept for compability, but it is strongly discouraged] + + The formats allowed by the pcap_findalldevs_ex() are the following: + - file://folder/ [lists all the files in the given folder] + - rpcap:// [lists all local adapters] + - rpcap://host:port/ [lists the devices available on a remote host] + + Referring to the 'host' and 'port' paramters, they can be either numeric or literal. Since + IPv6 is fully supported, these are the allowed formats: + + - host (literal): e.g. host.foo.bar + - host (numeric IPv4): e.g. 10.11.12.13 + - host (numeric IPv4, IPv6 style): e.g. [10.11.12.13] + - host (numeric IPv6): e.g. [1:2:3::4] + - port: can be either numeric (e.g. '80') or literal (e.g. 'http') + + Here you find some allowed examples: + - rpcap://host.foo.bar/devicename [everything literal, no port number] + - rpcap://host.foo.bar:1234/devicename [everything literal, with port number] + - rpcap://10.11.12.13/devicename [IPv4 numeric, no port number] + - rpcap://10.11.12.13:1234/devicename [IPv4 numeric, with port number] + - rpcap://[10.11.12.13]:1234/devicename [IPv4 numeric with IPv6 format, with port number] + - rpcap://[1:2:3::4]/devicename [IPv6 numeric, no port number] + - rpcap://[1:2:3::4]:1234/devicename [IPv6 numeric, with port number] + - rpcap://[1:2:3::4]:http/devicename [IPv6 numeric, with literal port number] + + \{ +*/ + + +/*! + \brief String that will be used to determine the type of source in use (file, + remote/local interface). + + This string will be prepended to the interface name in order to create a string + that contains all the information required to open the source. + + This string indicates that the user wants to open a capture from a local file. +*/ +#define PCAP_SRC_FILE_STRING "file://" +/*! + \brief String that will be used to determine the type of source in use (file, + remote/local interface). + + This string will be prepended to the interface name in order to create a string + that contains all the information required to open the source. + + This string indicates that the user wants to open a capture from a network interface. + This string does not necessarily involve the use of the RPCAP protocol. If the + interface required resides on the local host, the RPCAP protocol is not involved + and the local functions are used. +*/ +#define PCAP_SRC_IF_STRING "rpcap://" + +/*! + \} +*/ + + + + + +/*! + \addtogroup remote_open_flags + \{ +*/ + +/*! + \brief Defines if the adapter has to go in promiscuous mode. + + It is '1' if you have to open the adapter in promiscuous mode, '0' otherwise. + Note that even if this parameter is false, the interface could well be in promiscuous + mode for some other reason (for example because another capture process with + promiscuous mode enabled is currently using that interface). + On on Linux systems with 2.2 or later kernels (that have the "any" device), this + flag does not work on the "any" device; if an argument of "any" is supplied, + the 'promisc' flag is ignored. +*/ +#define PCAP_OPENFLAG_PROMISCUOUS 1 + +/*! + \brief Defines if the data trasfer (in case of a remote + capture) has to be done with UDP protocol. + + If it is '1' if you want a UDP data connection, '0' if you want + a TCP data connection; control connection is always TCP-based. + A UDP connection is much lighter, but it does not guarantee that all + the captured packets arrive to the client workstation. Moreover, + it could be harmful in case of network congestion. + This flag is meaningless if the source is not a remote interface. + In that case, it is simply ignored. +*/ +#define PCAP_OPENFLAG_DATATX_UDP 2 + + +/*! + \brief Defines if the remote probe will capture its own generated traffic. + + In case the remote probe uses the same interface to capture traffic and to send + data back to the caller, the captured traffic includes the RPCAP traffic as well. + If this flag is turned on, the RPCAP traffic is excluded from the capture, so that + the trace returned back to the collector is does not include this traffic. +*/ +#define PCAP_OPENFLAG_NOCAPTURE_RPCAP 4 + +/*! + \brief Defines if the local adapter will capture its own generated traffic. + + This flag tells the underlying capture driver to drop the packets that were sent by itself. + This is usefult when building applications like bridges, that should ignore the traffic + they just sent. +*/ +#define PCAP_OPENFLAG_NOCAPTURE_LOCAL 8 + +/*! + \brief This flag configures the adapter for maximum responsiveness. + + In presence of a large value for nbytes, WinPcap waits for the arrival of several packets before + copying the data to the user. This guarantees a low number of system calls, i.e. lower processor usage, + i.e. better performance, which is good for applications like sniffers. If the user sets the + PCAP_OPENFLAG_MAX_RESPONSIVENESS flag, the capture driver will copy the packets as soon as the application + is ready to receive them. This is suggested for real time applications (like, for example, a bridge) + that need the best responsiveness.*/ +#define PCAP_OPENFLAG_MAX_RESPONSIVENESS 16 + +/*! + \} +*/ + + +/*! + \addtogroup remote_samp_methods + \{ +*/ + +/*! + \brief No sampling has to be done on the current capture. + + In this case, no sampling algorithms are applied to the current capture. +*/ +#define PCAP_SAMP_NOSAMP 0 + +/*! + \brief It defines that only 1 out of N packets must be returned to the user. + + In this case, the 'value' field of the 'pcap_samp' structure indicates the + number of packets (minus 1) that must be discarded before one packet got accepted. + In other words, if 'value = 10', the first packet is returned to the caller, while + the following 9 are discarded. +*/ +#define PCAP_SAMP_1_EVERY_N 1 + +/*! + \brief It defines that we have to return 1 packet every N milliseconds. + + In this case, the 'value' field of the 'pcap_samp' structure indicates the 'waiting + time' in milliseconds before one packet got accepted. + In other words, if 'value = 10', the first packet is returned to the caller; the next + returned one will be the first packet that arrives when 10ms have elapsed. +*/ +#define PCAP_SAMP_FIRST_AFTER_N_MS 2 + +/*! + \} +*/ + + +/*! + \addtogroup remote_auth_methods + \{ +*/ + +/*! + \brief It defines the NULL authentication. + + This value has to be used within the 'type' member of the pcap_rmtauth structure. + The 'NULL' authentication has to be equal to 'zero', so that old applications + can just put every field of struct pcap_rmtauth to zero, and it does work. +*/ +#define RPCAP_RMTAUTH_NULL 0 +/*! + \brief It defines the username/password authentication. + + With this type of authentication, the RPCAP protocol will use the username/ + password provided to authenticate the user on the remote machine. If the + authentication is successful (and the user has the right to open network devices) + the RPCAP connection will continue; otherwise it will be dropped. + + This value has to be used within the 'type' member of the pcap_rmtauth structure. +*/ +#define RPCAP_RMTAUTH_PWD 1 + +/*! + \} +*/ + + + + +/*! + + \brief This structure keeps the information needed to autheticate + the user on a remote machine. + + The remote machine can either grant or refuse the access according + to the information provided. + In case the NULL authentication is required, both 'username' and + 'password' can be NULL pointers. + + This structure is meaningless if the source is not a remote interface; + in that case, the functions which requires such a structure can accept + a NULL pointer as well. +*/ +struct pcap_rmtauth +{ + /*! + \brief Type of the authentication required. + + In order to provide maximum flexibility, we can support different types + of authentication based on the value of this 'type' variable. The currently + supported authentication methods are defined into the + \link remote_auth_methods Remote Authentication Methods Section\endlink. + + */ + int type; + /*! + \brief Zero-terminated string containing the username that has to be + used on the remote machine for authentication. + + This field is meaningless in case of the RPCAP_RMTAUTH_NULL authentication + and it can be NULL. + */ + char *username; + /*! + \brief Zero-terminated string containing the password that has to be + used on the remote machine for authentication. + + This field is meaningless in case of the RPCAP_RMTAUTH_NULL authentication + and it can be NULL. + */ + char *password; +}; + + +/*! + \brief This structure defines the information related to sampling. + + In case the sampling is requested, the capturing device should read + only a subset of the packets coming from the source. The returned packets depend + on the sampling parameters. + + \warning The sampling process is applied after the filtering process. + In other words, packets are filtered first, then the sampling process selects a + subset of the 'filtered' packets and it returns them to the caller. +*/ +struct pcap_samp +{ + /*! + Method used for sampling. Currently, the supported methods are listed in the + \link remote_samp_methods Sampling Methods Section\endlink. + */ + int method; + + /*! + This value depends on the sampling method defined. For its meaning, please check + at the \link remote_samp_methods Sampling Methods Section\endlink. + */ + int value; +}; + + + + +//! Maximum lenght of an host name (needed for the RPCAP active mode) +#define RPCAP_HOSTLIST_SIZE 1024 + + +/*! + \} +*/ // end of public documentation + + +// Exported functions + + + +/** \name New WinPcap functions + + This section lists the new functions that are able to help considerably in writing + WinPcap programs because of their easiness of use. + */ +//\{ +pcap_t *pcap_open(const char *source, int snaplen, int flags, int read_timeout, struct pcap_rmtauth *auth, char *errbuf); +int pcap_createsrcstr(char *source, int type, const char *host, const char *port, const char *name, char *errbuf); +int pcap_parsesrcstr(const char *source, int *type, char *host, char *port, char *name, char *errbuf); +int pcap_findalldevs_ex(char *source, struct pcap_rmtauth *auth, pcap_if_t **alldevs, char *errbuf); +struct pcap_samp *pcap_setsampling(pcap_t *p); + +//\} +// End of new winpcap functions + + + +/** \name Remote Capture functions + */ +//\{ +SOCKET pcap_remoteact_accept(const char *address, const char *port, const char *hostlist, char *connectinghost, struct pcap_rmtauth *auth, char *errbuf); +int pcap_remoteact_list(char *hostlist, char sep, int size, char *errbuf); +int pcap_remoteact_close(const char *host, char *errbuf); +void pcap_remoteact_cleanup(); +//\} +// End of remote capture functions + +#ifdef __cplusplus +} +#endif + + +#endif + diff --git a/desmume/src/windows/winpcap/tcp_session.h b/src/windows/winpcap/tcp_session.h similarity index 96% rename from desmume/src/windows/winpcap/tcp_session.h rename to src/windows/winpcap/tcp_session.h index 73d6bc357..c7fb69a6b 100644 --- a/desmume/src/windows/winpcap/tcp_session.h +++ b/src/windows/winpcap/tcp_session.h @@ -1,96 +1,96 @@ -/* - * Copyright (c) 2001 - 2003 - * NetGroup, Politecnico di Torino (Italy) - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * 3. Neither the name of the Politecnico di Torino nor the names of its - * contributors may be used to endorse or promote products derived from - * this software without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS - * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT - * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR - * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT - * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, - * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY - * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT - * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE - * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * - */ - -#ifndef __tcp_session -#define __tcp_session - -#ifdef WIN32 -#include "tme.h" -#endif - -#ifdef __FreeBSD__ - -#ifdef _KERNEL -#include -#else -#include -#endif - -#endif - -#define UNKNOWN 0 -#define SYN_RCV 1 -#define SYN_ACK_RCV 2 -#define ESTABLISHED 3 -#define CLOSED_RST 4 -#define FIN_CLN_RCV 5 -#define FIN_SRV_RCV 6 -#define CLOSED_FIN 7 -#define ERROR_TCP 8 -#define FIRST_IS_CLN 0 -#define FIRST_IS_SRV 0xffffffff -#define FIN_CLN 1 -#define FIN_SRV 2 - -#define MAX_WINDOW 65536 - -typedef struct __tcp_data -{ - struct timeval timestamp_block; /*DO NOT MOVE THIS VALUE*/ - struct timeval syn_timestamp; - struct timeval last_timestamp; - struct timeval syn_ack_timestamp; - uint32 direction; - uint32 seq_n_0_srv; - uint32 seq_n_0_cln; - uint32 ack_srv; /* acknowledge of (data sent by server) */ - uint32 ack_cln; /* acknowledge of (data sent by client) */ - uint32 status; - uint32 pkts_cln_to_srv; - uint32 pkts_srv_to_cln; - uint32 bytes_srv_to_cln; - uint32 bytes_cln_to_srv; - uint32 close_state; -} - tcp_data; - -#define FIN 1 -#define SYN 2 -#define RST 4 -#define PSH 8 -#define ACK 16 -#define URG 32 - -#define TCP_SESSION 0x00000800 -uint32 tcp_session(uint8 *block, uint32 pkt_size, TME_DATA *data, MEM_TYPE *mem_ex, uint8 *mem_data); - +/* + * Copyright (c) 2001 - 2003 + * NetGroup, Politecnico di Torino (Italy) + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. Neither the name of the Politecnico di Torino nor the names of its + * contributors may be used to endorse or promote products derived from + * this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR + * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT + * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE + * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ + +#ifndef __tcp_session +#define __tcp_session + +#ifdef WIN32 +#include "tme.h" +#endif + +#ifdef __FreeBSD__ + +#ifdef _KERNEL +#include +#else +#include +#endif + +#endif + +#define UNKNOWN 0 +#define SYN_RCV 1 +#define SYN_ACK_RCV 2 +#define ESTABLISHED 3 +#define CLOSED_RST 4 +#define FIN_CLN_RCV 5 +#define FIN_SRV_RCV 6 +#define CLOSED_FIN 7 +#define ERROR_TCP 8 +#define FIRST_IS_CLN 0 +#define FIRST_IS_SRV 0xffffffff +#define FIN_CLN 1 +#define FIN_SRV 2 + +#define MAX_WINDOW 65536 + +typedef struct __tcp_data +{ + struct timeval timestamp_block; /*DO NOT MOVE THIS VALUE*/ + struct timeval syn_timestamp; + struct timeval last_timestamp; + struct timeval syn_ack_timestamp; + uint32 direction; + uint32 seq_n_0_srv; + uint32 seq_n_0_cln; + uint32 ack_srv; /* acknowledge of (data sent by server) */ + uint32 ack_cln; /* acknowledge of (data sent by client) */ + uint32 status; + uint32 pkts_cln_to_srv; + uint32 pkts_srv_to_cln; + uint32 bytes_srv_to_cln; + uint32 bytes_cln_to_srv; + uint32 close_state; +} + tcp_data; + +#define FIN 1 +#define SYN 2 +#define RST 4 +#define PSH 8 +#define ACK 16 +#define URG 32 + +#define TCP_SESSION 0x00000800 +uint32 tcp_session(uint8 *block, uint32 pkt_size, TME_DATA *data, MEM_TYPE *mem_ex, uint8 *mem_data); + #endif \ No newline at end of file diff --git a/desmume/src/windows/winpcap/time_calls.h b/src/windows/winpcap/time_calls.h similarity index 96% rename from desmume/src/windows/winpcap/time_calls.h rename to src/windows/winpcap/time_calls.h index 11aab8529..09a6d6959 100644 --- a/desmume/src/windows/winpcap/time_calls.h +++ b/src/windows/winpcap/time_calls.h @@ -1,485 +1,485 @@ -/* - * Copyright (c) 2001 - 2005 NetGroup, Politecnico di Torino (Italy) - * Copyright (c) 2005 - 2006 CACE Technologies, Davis (California) - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * 3. Neither the name of the Politecnico di Torino, CACE Technologies - * nor the names of its contributors may be used to endorse or promote - * products derived from this software without specific prior written - * permission. - * - * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS - * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT - * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR - * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT - * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, - * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY - * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT - * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE - * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * - */ - -#ifndef _time_calls -#define _time_calls - -#ifdef WIN_NT_DRIVER - -#include "debug.h" -#include "ndis.h" - -#define DEFAULT_TIMESTAMPMODE 0 - -#define TIMESTAMPMODE_SINGLE_SYNCHRONIZATION 0 -#define TIMESTAMPMODE_SYNCHRONIZATION_ON_CPU_WITH_FIXUP 1 -#define TIMESTAMPMODE_QUERYSYSTEMTIME 2 -#define TIMESTAMPMODE_RDTSC 3 - -#define TIMESTAMPMODE_SYNCHRONIZATION_ON_CPU_NO_FIXUP 99 - -#define TIMESTAMPMODE_REGKEY L"TimestampMode" - -extern ULONG TimestampMode; - -/*! - \brief A microsecond precise timestamp. - - included in the sf_pkthdr or the bpf_hdr that NPF associates with every packet. -*/ - -struct timeval { - long tv_sec; ///< seconds - long tv_usec; ///< microseconds -}; - -#endif /*WIN_NT_DRIVER*/ - -struct time_conv -{ - ULONGLONG reference; - struct timeval start[32]; -}; - -#ifdef WIN_NT_DRIVER - -__inline void TIME_DESYNCHRONIZE(struct time_conv *data) -{ - data->reference = 0; -// data->start.tv_sec = 0; -// data->start.tv_usec = 0; -} - - -__inline void ReadTimeStampModeFromRegistry(PUNICODE_STRING RegistryPath) -{ - ULONG NewLength; - PWSTR NullTerminatedString; - RTL_QUERY_REGISTRY_TABLE Queries[2]; - ULONG DefaultTimestampMode = DEFAULT_TIMESTAMPMODE; - - NewLength = RegistryPath->Length/2; - - NullTerminatedString = ExAllocatePoolWithTag(PagedPool, (NewLength+1) *sizeof(WCHAR), '2TWA'); - - if (NullTerminatedString != NULL) - { - RtlCopyMemory(NullTerminatedString, RegistryPath->Buffer, RegistryPath->Length); - - NullTerminatedString[NewLength]=0; - - RtlZeroMemory(Queries, sizeof(Queries)); - - Queries[0].Flags = RTL_QUERY_REGISTRY_DIRECT; - Queries[0].Name = TIMESTAMPMODE_REGKEY; - Queries[0].EntryContext = &TimestampMode; - Queries[0].DefaultType = REG_DWORD; - Queries[0].DefaultData = &DefaultTimestampMode; - Queries[0].DefaultLength = sizeof(ULONG); - - if(RtlQueryRegistryValues(RTL_REGISTRY_ABSOLUTE, NullTerminatedString, Queries, NULL, NULL) != STATUS_SUCCESS) - { - TimestampMode = DEFAULT_TIMESTAMPMODE; - } - - RtlWriteRegistryValue( RTL_REGISTRY_ABSOLUTE, NullTerminatedString, TIMESTAMPMODE_REGKEY, REG_DWORD, &TimestampMode,sizeof(ULONG)); - ExFreePool(NullTerminatedString); - } - else - TimestampMode = DEFAULT_TIMESTAMPMODE; -} - -#pragma optimize ("g",off) //Due to some weird behaviour of the optimizer of DDK build 2600 - -/* KeQueryPerformanceCounter TimeStamps */ -__inline void SynchronizeOnCpu(struct timeval *start) -{ -// struct timeval *start = (struct timeval*)Data; - - struct timeval tmp; - LARGE_INTEGER SystemTime; - LARGE_INTEGER i; - ULONG tmp2; - LARGE_INTEGER TimeFreq,PTime; - - // get the absolute value of the system boot time. - - PTime = KeQueryPerformanceCounter(&TimeFreq); - KeQuerySystemTime(&SystemTime); - - start->tv_sec = (LONG)(SystemTime.QuadPart/10000000-11644473600); - - start->tv_usec = (LONG)((SystemTime.QuadPart%10000000)/10); - - start->tv_sec -= (ULONG)(PTime.QuadPart/TimeFreq.QuadPart); - - start->tv_usec -= (LONG)((PTime.QuadPart%TimeFreq.QuadPart)*1000000/TimeFreq.QuadPart); - - if (start->tv_usec < 0) - { - start->tv_sec --; - start->tv_usec += 1000000; - } -} - -// -// inline assembler is not supported with the current AMD64 compilers -// At the moment we simply disable this timestamping mode on AMD64. -// A solution would be to allocate a small memory from the non-paged -// pool, dump the instructions on that buffer, and then execute them. -// The non paged pool is needed since it's the only area of kernel -// data memory that is not subject to the NX protection. -// Or use some lower level trick, like using an assembler to assemble -// a small function for this. -// - -#ifdef _X86_ -/*RDTSC timestamps */ -/* callers must be at IRQL=PASSIVE_LEVEL*/ -__inline VOID TimeSynchronizeRDTSC(struct time_conv *data) -{ - struct timeval tmp; - LARGE_INTEGER system_time; - ULONGLONG curr_ticks; - KIRQL old; - LARGE_INTEGER start_kqpc,stop_kqpc,start_freq,stop_freq; - ULONGLONG start_ticks,stop_ticks; - ULONGLONG delta,delta2; - KEVENT event; - LARGE_INTEGER i; - ULONGLONG reference; - - if (data->reference!=0) - return; - - KeInitializeEvent(&event,NotificationEvent,FALSE); - - i.QuadPart=-3500000; - - KeRaiseIrql(HIGH_LEVEL,&old); - start_kqpc=KeQueryPerformanceCounter(&start_freq); - __asm - { - push eax - push edx - push ecx - rdtsc - lea ecx, start_ticks - mov [ecx+4], edx - mov [ecx], eax - pop ecx - pop edx - pop eax - } - - KeLowerIrql(old); - - KeWaitForSingleObject(&event,UserRequest,KernelMode,TRUE ,&i); - - KeRaiseIrql(HIGH_LEVEL,&old); - stop_kqpc=KeQueryPerformanceCounter(&stop_freq); - __asm - { - push eax - push edx - push ecx - rdtsc - lea ecx, stop_ticks - mov [ecx+4], edx - mov [ecx], eax - pop ecx - pop edx - pop eax - } - KeLowerIrql(old); - - delta=stop_ticks-start_ticks; - delta2=stop_kqpc.QuadPart-start_kqpc.QuadPart; - if (delta>10000000000) - { - delta/=16; - delta2/=16; - } - - reference=delta*(start_freq.QuadPart)/delta2; - - data->reference=reference/1000; - - if (reference%1000>500) - data->reference++; - - data->reference*=1000; - - reference=data->reference; - - KeQuerySystemTime(&system_time); - - __asm - { - push eax - push edx - push ecx - rdtsc - lea ecx, curr_ticks - mov [ecx+4], edx - mov [ecx], eax - pop ecx - pop edx - pop eax - } - - tmp.tv_sec=-(LONG)(curr_ticks/reference); - - tmp.tv_usec=-(LONG)((curr_ticks%reference)*1000000/reference); - - system_time.QuadPart-=116444736000000000; - - tmp.tv_sec+=(LONG)(system_time.QuadPart/10000000); - tmp.tv_usec+=(LONG)((system_time.QuadPart%10000000)/10); - - if (tmp.tv_usec<0) - { - tmp.tv_sec--; - tmp.tv_usec+=1000000; - } - - data->start[0] = tmp; - - IF_LOUD(DbgPrint("Frequency %I64u MHz\n",data->reference);) -} -#endif //_X86_ - -#pragma optimize ("g",on) //Due to some weird behaviour of the optimizer of DDK build 2600 - -__inline VOID TIME_SYNCHRONIZE(struct time_conv *data) -{ - ULONG NumberOfCpus, i; - KAFFINITY AffinityMask; - - if (data->reference != 0) - return; - - NumberOfCpus = NdisSystemProcessorCount(); - - if ( TimestampMode == TIMESTAMPMODE_SYNCHRONIZATION_ON_CPU_WITH_FIXUP || TimestampMode == TIMESTAMPMODE_SYNCHRONIZATION_ON_CPU_NO_FIXUP) - { - for (i = 0 ; i < NumberOfCpus ; i++ ) - { - AffinityMask = (1 << i); - ZwSetInformationThread(NtCurrentThread(), ThreadAffinityMask, &AffinityMask, sizeof(KAFFINITY)); - SynchronizeOnCpu(&(data->start[i])); - } - AffinityMask = 0xFFFFFFFF; - ZwSetInformationThread(NtCurrentThread(), ThreadAffinityMask, &AffinityMask, sizeof(KAFFINITY)); - data->reference = 1; - } - else - if ( TimestampMode == TIMESTAMPMODE_QUERYSYSTEMTIME ) - { - //do nothing - data->reference = 1; - } - else -// -// This timestamp mode is supported on x86 (32 bit) only -// -#ifdef _X86_ - if ( TimestampMode == TIMESTAMPMODE_RDTSC ) - { - TimeSynchronizeRDTSC(data); - } - else -#endif // _X86_ - { //it should be only the normal case i.e. TIMESTAMPMODE_SINGLESYNCHRONIZATION - SynchronizeOnCpu(data->start); - data->reference = 1; - } - return; -} - - -#pragma optimize ("g",off) //Due to some weird behaviour of the optimizer of DDK build 2600 - -__inline void GetTimeKQPC(struct timeval *dst, struct time_conv *data) -{ - LARGE_INTEGER PTime, TimeFreq; - LONG tmp; - ULONG CurrentCpu; - static struct timeval old_ts={0,0}; - - - PTime = KeQueryPerformanceCounter(&TimeFreq); - tmp = (LONG)(PTime.QuadPart/TimeFreq.QuadPart); - - if (TimestampMode == TIMESTAMPMODE_SYNCHRONIZATION_ON_CPU_WITH_FIXUP || TimestampMode == TIMESTAMPMODE_SYNCHRONIZATION_ON_CPU_NO_FIXUP) - { - //actually this code is ok only if we are guaranteed that no thread scheduling will take place. - CurrentCpu = KeGetCurrentProcessorNumber(); - - dst->tv_sec = data->start[CurrentCpu].tv_sec + tmp; - dst->tv_usec = data->start[CurrentCpu].tv_usec + (LONG)((PTime.QuadPart%TimeFreq.QuadPart)*1000000/TimeFreq.QuadPart); - - if (dst->tv_usec >= 1000000) - { - dst->tv_sec ++; - dst->tv_usec -= 1000000; - } - - if (TimestampMode == TIMESTAMPMODE_SYNCHRONIZATION_ON_CPU_WITH_FIXUP) - { - if (old_ts.tv_sec > dst->tv_sec || (old_ts.tv_sec == dst->tv_sec && old_ts.tv_usec > dst->tv_usec) ) - *dst = old_ts; - - else - old_ts = *dst; - } - } - else - { //it should be only the normal case i.e. TIMESTAMPMODE_SINGLESYNCHRONIZATION - dst->tv_sec = data->start[0].tv_sec + tmp; - dst->tv_usec = data->start[0].tv_usec + (LONG)((PTime.QuadPart%TimeFreq.QuadPart)*1000000/TimeFreq.QuadPart); - - if (dst->tv_usec >= 1000000) - { - dst->tv_sec ++; - dst->tv_usec -= 1000000; - } - } -} - -// -// inline assembler is not supported with the current AMD64 compilers -// At the moment we simply disable this timestamping mode on AMD64. -// A solution would be to allocate a small memory from the non-paged -// pool, dump the instructions on that buffer, and then execute them. -// The non paged pool is needed since it's the only area of kernel -// data memory that is not subject to the NX protection. -// Or use some lower level trick, like using an assembler to assemble -// a small function for this. -// - -#ifdef _X86_ -__inline void GetTimeRDTSC(struct timeval *dst, struct time_conv *data) -{ - - ULONGLONG tmp = 0; - __asm - { - push eax - push edx - push ecx - rdtsc - lea ecx, tmp - mov [ecx+4], edx - mov [ecx], eax - pop ecx - pop edx - pop eax - } - - if (data->reference==0) - { - return; - } - dst->tv_sec=(LONG)(tmp/data->reference); - - dst->tv_usec=(LONG)((tmp-dst->tv_sec*data->reference)*1000000/data->reference); - - dst->tv_sec+=data->start[0].tv_sec; - - dst->tv_usec+=data->start[0].tv_usec; - - if (dst->tv_usec>=1000000) - { - dst->tv_sec++; - dst->tv_usec-=1000000; - } - - -} -#endif //_X86_ - -__inline void GetTimeQST(struct timeval *dst, struct time_conv *data) -{ - LARGE_INTEGER SystemTime; - - KeQuerySystemTime(&SystemTime); - - dst->tv_sec = (LONG)(SystemTime.QuadPart/10000000-11644473600); - dst->tv_usec = (LONG)((SystemTime.QuadPart%10000000)/10); - -} - -#pragma optimize ("g",on) //Due to some weird behaviour of the optimizer of DDK build 2600 - - -__inline void GET_TIME(struct timeval *dst, struct time_conv *data) -{ - -// -// This timestamp mode is supported on x86 (32 bit) only -// -#ifdef _X86_ - if ( TimestampMode == TIMESTAMPMODE_RDTSC ) - { - GetTimeRDTSC(dst,data); - } - else -#endif // _X86_ - if ( TimestampMode == TIMESTAMPMODE_QUERYSYSTEMTIME ) - { - GetTimeQST(dst,data); - } - else - { - GetTimeKQPC(dst,data); - } -} - - -#else /*WIN_NT_DRIVER*/ - -__inline void FORCE_TIME(struct timeval *src, struct time_conv *dest) -{ - dest->start[0]=*src; -} - -__inline void GET_TIME(struct timeval *dst, struct time_conv *data) -{ - *dst=data->start[0]; -} - -#endif /*WIN_NT_DRIVER*/ - - -#endif /*_time_calls*/ +/* + * Copyright (c) 2001 - 2005 NetGroup, Politecnico di Torino (Italy) + * Copyright (c) 2005 - 2006 CACE Technologies, Davis (California) + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. Neither the name of the Politecnico di Torino, CACE Technologies + * nor the names of its contributors may be used to endorse or promote + * products derived from this software without specific prior written + * permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR + * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT + * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE + * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ + +#ifndef _time_calls +#define _time_calls + +#ifdef WIN_NT_DRIVER + +#include "debug.h" +#include "ndis.h" + +#define DEFAULT_TIMESTAMPMODE 0 + +#define TIMESTAMPMODE_SINGLE_SYNCHRONIZATION 0 +#define TIMESTAMPMODE_SYNCHRONIZATION_ON_CPU_WITH_FIXUP 1 +#define TIMESTAMPMODE_QUERYSYSTEMTIME 2 +#define TIMESTAMPMODE_RDTSC 3 + +#define TIMESTAMPMODE_SYNCHRONIZATION_ON_CPU_NO_FIXUP 99 + +#define TIMESTAMPMODE_REGKEY L"TimestampMode" + +extern ULONG TimestampMode; + +/*! + \brief A microsecond precise timestamp. + + included in the sf_pkthdr or the bpf_hdr that NPF associates with every packet. +*/ + +struct timeval { + long tv_sec; ///< seconds + long tv_usec; ///< microseconds +}; + +#endif /*WIN_NT_DRIVER*/ + +struct time_conv +{ + ULONGLONG reference; + struct timeval start[32]; +}; + +#ifdef WIN_NT_DRIVER + +__inline void TIME_DESYNCHRONIZE(struct time_conv *data) +{ + data->reference = 0; +// data->start.tv_sec = 0; +// data->start.tv_usec = 0; +} + + +__inline void ReadTimeStampModeFromRegistry(PUNICODE_STRING RegistryPath) +{ + ULONG NewLength; + PWSTR NullTerminatedString; + RTL_QUERY_REGISTRY_TABLE Queries[2]; + ULONG DefaultTimestampMode = DEFAULT_TIMESTAMPMODE; + + NewLength = RegistryPath->Length/2; + + NullTerminatedString = ExAllocatePoolWithTag(PagedPool, (NewLength+1) *sizeof(WCHAR), '2TWA'); + + if (NullTerminatedString != NULL) + { + RtlCopyMemory(NullTerminatedString, RegistryPath->Buffer, RegistryPath->Length); + + NullTerminatedString[NewLength]=0; + + RtlZeroMemory(Queries, sizeof(Queries)); + + Queries[0].Flags = RTL_QUERY_REGISTRY_DIRECT; + Queries[0].Name = TIMESTAMPMODE_REGKEY; + Queries[0].EntryContext = &TimestampMode; + Queries[0].DefaultType = REG_DWORD; + Queries[0].DefaultData = &DefaultTimestampMode; + Queries[0].DefaultLength = sizeof(ULONG); + + if(RtlQueryRegistryValues(RTL_REGISTRY_ABSOLUTE, NullTerminatedString, Queries, NULL, NULL) != STATUS_SUCCESS) + { + TimestampMode = DEFAULT_TIMESTAMPMODE; + } + + RtlWriteRegistryValue( RTL_REGISTRY_ABSOLUTE, NullTerminatedString, TIMESTAMPMODE_REGKEY, REG_DWORD, &TimestampMode,sizeof(ULONG)); + ExFreePool(NullTerminatedString); + } + else + TimestampMode = DEFAULT_TIMESTAMPMODE; +} + +#pragma optimize ("g",off) //Due to some weird behaviour of the optimizer of DDK build 2600 + +/* KeQueryPerformanceCounter TimeStamps */ +__inline void SynchronizeOnCpu(struct timeval *start) +{ +// struct timeval *start = (struct timeval*)Data; + + struct timeval tmp; + LARGE_INTEGER SystemTime; + LARGE_INTEGER i; + ULONG tmp2; + LARGE_INTEGER TimeFreq,PTime; + + // get the absolute value of the system boot time. + + PTime = KeQueryPerformanceCounter(&TimeFreq); + KeQuerySystemTime(&SystemTime); + + start->tv_sec = (LONG)(SystemTime.QuadPart/10000000-11644473600); + + start->tv_usec = (LONG)((SystemTime.QuadPart%10000000)/10); + + start->tv_sec -= (ULONG)(PTime.QuadPart/TimeFreq.QuadPart); + + start->tv_usec -= (LONG)((PTime.QuadPart%TimeFreq.QuadPart)*1000000/TimeFreq.QuadPart); + + if (start->tv_usec < 0) + { + start->tv_sec --; + start->tv_usec += 1000000; + } +} + +// +// inline assembler is not supported with the current AMD64 compilers +// At the moment we simply disable this timestamping mode on AMD64. +// A solution would be to allocate a small memory from the non-paged +// pool, dump the instructions on that buffer, and then execute them. +// The non paged pool is needed since it's the only area of kernel +// data memory that is not subject to the NX protection. +// Or use some lower level trick, like using an assembler to assemble +// a small function for this. +// + +#ifdef _X86_ +/*RDTSC timestamps */ +/* callers must be at IRQL=PASSIVE_LEVEL*/ +__inline VOID TimeSynchronizeRDTSC(struct time_conv *data) +{ + struct timeval tmp; + LARGE_INTEGER system_time; + ULONGLONG curr_ticks; + KIRQL old; + LARGE_INTEGER start_kqpc,stop_kqpc,start_freq,stop_freq; + ULONGLONG start_ticks,stop_ticks; + ULONGLONG delta,delta2; + KEVENT event; + LARGE_INTEGER i; + ULONGLONG reference; + + if (data->reference!=0) + return; + + KeInitializeEvent(&event,NotificationEvent,FALSE); + + i.QuadPart=-3500000; + + KeRaiseIrql(HIGH_LEVEL,&old); + start_kqpc=KeQueryPerformanceCounter(&start_freq); + __asm + { + push eax + push edx + push ecx + rdtsc + lea ecx, start_ticks + mov [ecx+4], edx + mov [ecx], eax + pop ecx + pop edx + pop eax + } + + KeLowerIrql(old); + + KeWaitForSingleObject(&event,UserRequest,KernelMode,TRUE ,&i); + + KeRaiseIrql(HIGH_LEVEL,&old); + stop_kqpc=KeQueryPerformanceCounter(&stop_freq); + __asm + { + push eax + push edx + push ecx + rdtsc + lea ecx, stop_ticks + mov [ecx+4], edx + mov [ecx], eax + pop ecx + pop edx + pop eax + } + KeLowerIrql(old); + + delta=stop_ticks-start_ticks; + delta2=stop_kqpc.QuadPart-start_kqpc.QuadPart; + if (delta>10000000000) + { + delta/=16; + delta2/=16; + } + + reference=delta*(start_freq.QuadPart)/delta2; + + data->reference=reference/1000; + + if (reference%1000>500) + data->reference++; + + data->reference*=1000; + + reference=data->reference; + + KeQuerySystemTime(&system_time); + + __asm + { + push eax + push edx + push ecx + rdtsc + lea ecx, curr_ticks + mov [ecx+4], edx + mov [ecx], eax + pop ecx + pop edx + pop eax + } + + tmp.tv_sec=-(LONG)(curr_ticks/reference); + + tmp.tv_usec=-(LONG)((curr_ticks%reference)*1000000/reference); + + system_time.QuadPart-=116444736000000000; + + tmp.tv_sec+=(LONG)(system_time.QuadPart/10000000); + tmp.tv_usec+=(LONG)((system_time.QuadPart%10000000)/10); + + if (tmp.tv_usec<0) + { + tmp.tv_sec--; + tmp.tv_usec+=1000000; + } + + data->start[0] = tmp; + + IF_LOUD(DbgPrint("Frequency %I64u MHz\n",data->reference);) +} +#endif //_X86_ + +#pragma optimize ("g",on) //Due to some weird behaviour of the optimizer of DDK build 2600 + +__inline VOID TIME_SYNCHRONIZE(struct time_conv *data) +{ + ULONG NumberOfCpus, i; + KAFFINITY AffinityMask; + + if (data->reference != 0) + return; + + NumberOfCpus = NdisSystemProcessorCount(); + + if ( TimestampMode == TIMESTAMPMODE_SYNCHRONIZATION_ON_CPU_WITH_FIXUP || TimestampMode == TIMESTAMPMODE_SYNCHRONIZATION_ON_CPU_NO_FIXUP) + { + for (i = 0 ; i < NumberOfCpus ; i++ ) + { + AffinityMask = (1 << i); + ZwSetInformationThread(NtCurrentThread(), ThreadAffinityMask, &AffinityMask, sizeof(KAFFINITY)); + SynchronizeOnCpu(&(data->start[i])); + } + AffinityMask = 0xFFFFFFFF; + ZwSetInformationThread(NtCurrentThread(), ThreadAffinityMask, &AffinityMask, sizeof(KAFFINITY)); + data->reference = 1; + } + else + if ( TimestampMode == TIMESTAMPMODE_QUERYSYSTEMTIME ) + { + //do nothing + data->reference = 1; + } + else +// +// This timestamp mode is supported on x86 (32 bit) only +// +#ifdef _X86_ + if ( TimestampMode == TIMESTAMPMODE_RDTSC ) + { + TimeSynchronizeRDTSC(data); + } + else +#endif // _X86_ + { //it should be only the normal case i.e. TIMESTAMPMODE_SINGLESYNCHRONIZATION + SynchronizeOnCpu(data->start); + data->reference = 1; + } + return; +} + + +#pragma optimize ("g",off) //Due to some weird behaviour of the optimizer of DDK build 2600 + +__inline void GetTimeKQPC(struct timeval *dst, struct time_conv *data) +{ + LARGE_INTEGER PTime, TimeFreq; + LONG tmp; + ULONG CurrentCpu; + static struct timeval old_ts={0,0}; + + + PTime = KeQueryPerformanceCounter(&TimeFreq); + tmp = (LONG)(PTime.QuadPart/TimeFreq.QuadPart); + + if (TimestampMode == TIMESTAMPMODE_SYNCHRONIZATION_ON_CPU_WITH_FIXUP || TimestampMode == TIMESTAMPMODE_SYNCHRONIZATION_ON_CPU_NO_FIXUP) + { + //actually this code is ok only if we are guaranteed that no thread scheduling will take place. + CurrentCpu = KeGetCurrentProcessorNumber(); + + dst->tv_sec = data->start[CurrentCpu].tv_sec + tmp; + dst->tv_usec = data->start[CurrentCpu].tv_usec + (LONG)((PTime.QuadPart%TimeFreq.QuadPart)*1000000/TimeFreq.QuadPart); + + if (dst->tv_usec >= 1000000) + { + dst->tv_sec ++; + dst->tv_usec -= 1000000; + } + + if (TimestampMode == TIMESTAMPMODE_SYNCHRONIZATION_ON_CPU_WITH_FIXUP) + { + if (old_ts.tv_sec > dst->tv_sec || (old_ts.tv_sec == dst->tv_sec && old_ts.tv_usec > dst->tv_usec) ) + *dst = old_ts; + + else + old_ts = *dst; + } + } + else + { //it should be only the normal case i.e. TIMESTAMPMODE_SINGLESYNCHRONIZATION + dst->tv_sec = data->start[0].tv_sec + tmp; + dst->tv_usec = data->start[0].tv_usec + (LONG)((PTime.QuadPart%TimeFreq.QuadPart)*1000000/TimeFreq.QuadPart); + + if (dst->tv_usec >= 1000000) + { + dst->tv_sec ++; + dst->tv_usec -= 1000000; + } + } +} + +// +// inline assembler is not supported with the current AMD64 compilers +// At the moment we simply disable this timestamping mode on AMD64. +// A solution would be to allocate a small memory from the non-paged +// pool, dump the instructions on that buffer, and then execute them. +// The non paged pool is needed since it's the only area of kernel +// data memory that is not subject to the NX protection. +// Or use some lower level trick, like using an assembler to assemble +// a small function for this. +// + +#ifdef _X86_ +__inline void GetTimeRDTSC(struct timeval *dst, struct time_conv *data) +{ + + ULONGLONG tmp = 0; + __asm + { + push eax + push edx + push ecx + rdtsc + lea ecx, tmp + mov [ecx+4], edx + mov [ecx], eax + pop ecx + pop edx + pop eax + } + + if (data->reference==0) + { + return; + } + dst->tv_sec=(LONG)(tmp/data->reference); + + dst->tv_usec=(LONG)((tmp-dst->tv_sec*data->reference)*1000000/data->reference); + + dst->tv_sec+=data->start[0].tv_sec; + + dst->tv_usec+=data->start[0].tv_usec; + + if (dst->tv_usec>=1000000) + { + dst->tv_sec++; + dst->tv_usec-=1000000; + } + + +} +#endif //_X86_ + +__inline void GetTimeQST(struct timeval *dst, struct time_conv *data) +{ + LARGE_INTEGER SystemTime; + + KeQuerySystemTime(&SystemTime); + + dst->tv_sec = (LONG)(SystemTime.QuadPart/10000000-11644473600); + dst->tv_usec = (LONG)((SystemTime.QuadPart%10000000)/10); + +} + +#pragma optimize ("g",on) //Due to some weird behaviour of the optimizer of DDK build 2600 + + +__inline void GET_TIME(struct timeval *dst, struct time_conv *data) +{ + +// +// This timestamp mode is supported on x86 (32 bit) only +// +#ifdef _X86_ + if ( TimestampMode == TIMESTAMPMODE_RDTSC ) + { + GetTimeRDTSC(dst,data); + } + else +#endif // _X86_ + if ( TimestampMode == TIMESTAMPMODE_QUERYSYSTEMTIME ) + { + GetTimeQST(dst,data); + } + else + { + GetTimeKQPC(dst,data); + } +} + + +#else /*WIN_NT_DRIVER*/ + +__inline void FORCE_TIME(struct timeval *src, struct time_conv *dest) +{ + dest->start[0]=*src; +} + +__inline void GET_TIME(struct timeval *dst, struct time_conv *data) +{ + *dst=data->start[0]; +} + +#endif /*WIN_NT_DRIVER*/ + + +#endif /*_time_calls*/ diff --git a/desmume/src/windows/winpcap/tme.h b/src/windows/winpcap/tme.h similarity index 97% rename from desmume/src/windows/winpcap/tme.h rename to src/windows/winpcap/tme.h index 41e46326b..446903c5d 100644 --- a/desmume/src/windows/winpcap/tme.h +++ b/src/windows/winpcap/tme.h @@ -1,176 +1,176 @@ -/* - * Copyright (c) 2001 - 2003 - * NetGroup, Politecnico di Torino (Italy) - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * 3. Neither the name of the Politecnico di Torino nor the names of its - * contributors may be used to endorse or promote products derived from - * this software without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS - * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT - * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR - * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT - * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, - * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY - * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT - * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE - * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * - */ - -#ifndef __tme_include_ -#define __tme_include_ - -#ifdef WIN_NT_DRIVER -#include "ndis.h" -#else -#include -#endif /*WIN_NT_DRIVER*/ - -#include "memory_t.h" -#include "time_calls.h" - - -/* error codes */ -#define TME_ERROR 0 -#define TME_SUCCESS 1 -#define TME_TRUE 2 -#define TME_FALSE 3 - -/* some constants */ -#define DEFAULT_MEM_EX_SIZE 65536 -#define MAX_TME_DATA_BLOCKS 4 -#define TME_NONE_ACTIVE 0xffffffff -#define DELTA_READ 2 /* secs */ - -#define TME_LUT_ENTRIES 0x00000000 -#define TME_MAX_FILL_STATE 0x00000001 /*potrebbe servire per un thread a passive level!?!?! */ -#define TME_REHASHING_VALUE 0x00000002 -#define TME_KEY_LEN 0x00000003 -#define TME_SHARED_MEMORY_BLOCKS 0x00000004 -#define TME_FILLED_ENTRIES 0x00000005 -#define TME_BLOCK_SIZE 0x00000006 -#define TME_EXTRA_SEGMENT_SIZE 0x00000007 -#define TME_LOOKUP_CODE 0x00000008 -#define TME_OUT_LUT_EXEC 0x00000009 -#define TME_FILLED_BLOCKS 0x0000000a -#define TME_DEFAULT_EXEC 0x0000000b -#define TME_LUT_BASE_ADDRESS 0x0000000c -#define TME_SHARED_MEMORY_BASE_ADDRESS 0x0000000d -#define TME_EXTRA_SEGMENT_BASE_ADDRESS 0x0000000e -#define TME_LAST_FOUND 0x0000000f /* contains the offset of the last found entry */ -#define TME_LAST_FOUND_BLOCK 0x00000010 -/* TME default values */ -#define TME_LUT_ENTRIES_DEFAULT 32007 -#define TME_REHASHING_VALUE_DEFAULT 1 -#define TME_SHARED_MEMORY_BLOCKS_DEFAULT 16000 -#define TME_BLOCK_SIZE_DEFAULT 64 -#define TME_EXTRA_SEGMENT_SIZE_DEFAULT 0 -#define TME_LOOKUP_CODE_DEFAULT 0 -#define TME_OUT_LUT_EXEC_DEFAULT 0 -#define TME_DEFAULT_EXEC_DEFAULT 0 -#define TME_MAX_FILL_STATE_DEFAULT 15000 - -#define IS_VALIDATED(src,index) (src&(1<tv_sec=0x7fffffff; - -struct __TME_DATA; - -/* TME callback prototypes */ -typedef uint32 (*lut_fcn)(uint8 *key, struct __TME_DATA *data,MEM_TYPE *mem_ex, struct time_conv *time_ref ); -typedef uint32 (*exec_fcn)(uint8 *block, uint32 pkt_size, struct __TME_DATA *data, MEM_TYPE *mem_ex, uint8 *mem_data); - -/* DO NOT MODIFY THIS STRUCTURE!!!! GV */ -typedef struct __RECORD - -{ - uint32 block; - uint32 exec_fcn; -} - RECORD, *PRECORD; - -/* TME data registers */ -struct __TME_DATA -{ - uint32 lut_entries; - uint32 max_fill_state; - uint32 rehashing_value; - uint32 key_len; - uint32 shared_memory_blocks; - uint32 filled_entries; - uint32 block_size; - uint32 extra_segment_size; - uint32 filled_blocks; - lut_fcn lookup_code; - uint32 default_exec; - uint32 out_lut_exec; - uint8 *lut_base_address; - uint8 *shared_memory_base_address; - uint8 *extra_segment_base_address; - struct timeval last_read; - uint32 enable_deletion; - uint8 *last_found; -}; - -typedef struct __TME_DATA TME_DATA,*PTME_DATA; - - - -/* TME core */ -typedef struct __TME_CORE -{ - uint32 working; - uint32 active; - uint32 validated_blocks; - TME_DATA block_data[MAX_TME_DATA_BLOCKS]; - uint32 active_read; - -} TME_CORE, *PTME_CORE; - -static __inline int32 IS_DELETABLE(void *timestamp, TME_DATA *data) -{ - struct timeval *ts=(struct timeval*)timestamp; - - if (data->enable_deletion==FALSE) - return FALSE; - if (data->filled_entriesmax_fill_state) - return FALSE; - if ((ts->tv_sec+DELTA_READ)last_read.tv_sec) - return TRUE; - return FALSE; -} - -/* functions to manage TME */ -uint32 init_tme_block(TME_CORE *tme, uint32 block); -uint32 validate_tme_block(MEM_TYPE *mem_ex, TME_CORE *tme, uint32 block, uint32 mem_ex_offset); -uint32 lookup_frontend(MEM_TYPE *mem_ex, TME_CORE *tme,uint32 mem_ex_offset, struct time_conv *time_ref); -uint32 execute_frontend(MEM_TYPE *mem_ex, TME_CORE *tme, uint32 pkt_size,uint32 offset); -uint32 set_active_tme_block(TME_CORE *tme, uint32 block); -uint32 init_extended_memory(uint32 size, MEM_TYPE *mem_ex); -uint32 reset_tme(TME_CORE *tme); -uint32 get_tme_block_register(TME_DATA *data,MEM_TYPE *mem_ex,uint32 rgstr,uint32 *rval); -uint32 set_tme_block_register(TME_DATA *data,MEM_TYPE *mem_ex,uint32 rgstr,uint32 value, int32 init); -uint32 set_active_read_tme_block(TME_CORE *tme, uint32 block); -uint32 set_autodeletion(TME_DATA *data, uint32 value); - -/* function mappers */ -lut_fcn lut_fcn_mapper(uint32 index); -exec_fcn exec_fcn_mapper(uint32 index); - +/* + * Copyright (c) 2001 - 2003 + * NetGroup, Politecnico di Torino (Italy) + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. Neither the name of the Politecnico di Torino nor the names of its + * contributors may be used to endorse or promote products derived from + * this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR + * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT + * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE + * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ + +#ifndef __tme_include_ +#define __tme_include_ + +#ifdef WIN_NT_DRIVER +#include "ndis.h" +#else +#include +#endif /*WIN_NT_DRIVER*/ + +#include "memory_t.h" +#include "time_calls.h" + + +/* error codes */ +#define TME_ERROR 0 +#define TME_SUCCESS 1 +#define TME_TRUE 2 +#define TME_FALSE 3 + +/* some constants */ +#define DEFAULT_MEM_EX_SIZE 65536 +#define MAX_TME_DATA_BLOCKS 4 +#define TME_NONE_ACTIVE 0xffffffff +#define DELTA_READ 2 /* secs */ + +#define TME_LUT_ENTRIES 0x00000000 +#define TME_MAX_FILL_STATE 0x00000001 /*potrebbe servire per un thread a passive level!?!?! */ +#define TME_REHASHING_VALUE 0x00000002 +#define TME_KEY_LEN 0x00000003 +#define TME_SHARED_MEMORY_BLOCKS 0x00000004 +#define TME_FILLED_ENTRIES 0x00000005 +#define TME_BLOCK_SIZE 0x00000006 +#define TME_EXTRA_SEGMENT_SIZE 0x00000007 +#define TME_LOOKUP_CODE 0x00000008 +#define TME_OUT_LUT_EXEC 0x00000009 +#define TME_FILLED_BLOCKS 0x0000000a +#define TME_DEFAULT_EXEC 0x0000000b +#define TME_LUT_BASE_ADDRESS 0x0000000c +#define TME_SHARED_MEMORY_BASE_ADDRESS 0x0000000d +#define TME_EXTRA_SEGMENT_BASE_ADDRESS 0x0000000e +#define TME_LAST_FOUND 0x0000000f /* contains the offset of the last found entry */ +#define TME_LAST_FOUND_BLOCK 0x00000010 +/* TME default values */ +#define TME_LUT_ENTRIES_DEFAULT 32007 +#define TME_REHASHING_VALUE_DEFAULT 1 +#define TME_SHARED_MEMORY_BLOCKS_DEFAULT 16000 +#define TME_BLOCK_SIZE_DEFAULT 64 +#define TME_EXTRA_SEGMENT_SIZE_DEFAULT 0 +#define TME_LOOKUP_CODE_DEFAULT 0 +#define TME_OUT_LUT_EXEC_DEFAULT 0 +#define TME_DEFAULT_EXEC_DEFAULT 0 +#define TME_MAX_FILL_STATE_DEFAULT 15000 + +#define IS_VALIDATED(src,index) (src&(1<tv_sec=0x7fffffff; + +struct __TME_DATA; + +/* TME callback prototypes */ +typedef uint32 (*lut_fcn)(uint8 *key, struct __TME_DATA *data,MEM_TYPE *mem_ex, struct time_conv *time_ref ); +typedef uint32 (*exec_fcn)(uint8 *block, uint32 pkt_size, struct __TME_DATA *data, MEM_TYPE *mem_ex, uint8 *mem_data); + +/* DO NOT MODIFY THIS STRUCTURE!!!! GV */ +typedef struct __RECORD + +{ + uint32 block; + uint32 exec_fcn; +} + RECORD, *PRECORD; + +/* TME data registers */ +struct __TME_DATA +{ + uint32 lut_entries; + uint32 max_fill_state; + uint32 rehashing_value; + uint32 key_len; + uint32 shared_memory_blocks; + uint32 filled_entries; + uint32 block_size; + uint32 extra_segment_size; + uint32 filled_blocks; + lut_fcn lookup_code; + uint32 default_exec; + uint32 out_lut_exec; + uint8 *lut_base_address; + uint8 *shared_memory_base_address; + uint8 *extra_segment_base_address; + struct timeval last_read; + uint32 enable_deletion; + uint8 *last_found; +}; + +typedef struct __TME_DATA TME_DATA,*PTME_DATA; + + + +/* TME core */ +typedef struct __TME_CORE +{ + uint32 working; + uint32 active; + uint32 validated_blocks; + TME_DATA block_data[MAX_TME_DATA_BLOCKS]; + uint32 active_read; + +} TME_CORE, *PTME_CORE; + +static __inline int32 IS_DELETABLE(void *timestamp, TME_DATA *data) +{ + struct timeval *ts=(struct timeval*)timestamp; + + if (data->enable_deletion==FALSE) + return FALSE; + if (data->filled_entriesmax_fill_state) + return FALSE; + if ((ts->tv_sec+DELTA_READ)last_read.tv_sec) + return TRUE; + return FALSE; +} + +/* functions to manage TME */ +uint32 init_tme_block(TME_CORE *tme, uint32 block); +uint32 validate_tme_block(MEM_TYPE *mem_ex, TME_CORE *tme, uint32 block, uint32 mem_ex_offset); +uint32 lookup_frontend(MEM_TYPE *mem_ex, TME_CORE *tme,uint32 mem_ex_offset, struct time_conv *time_ref); +uint32 execute_frontend(MEM_TYPE *mem_ex, TME_CORE *tme, uint32 pkt_size,uint32 offset); +uint32 set_active_tme_block(TME_CORE *tme, uint32 block); +uint32 init_extended_memory(uint32 size, MEM_TYPE *mem_ex); +uint32 reset_tme(TME_CORE *tme); +uint32 get_tme_block_register(TME_DATA *data,MEM_TYPE *mem_ex,uint32 rgstr,uint32 *rval); +uint32 set_tme_block_register(TME_DATA *data,MEM_TYPE *mem_ex,uint32 rgstr,uint32 value, int32 init); +uint32 set_active_read_tme_block(TME_CORE *tme, uint32 block); +uint32 set_autodeletion(TME_DATA *data, uint32 value); + +/* function mappers */ +lut_fcn lut_fcn_mapper(uint32 index); +exec_fcn exec_fcn_mapper(uint32 index); + #endif \ No newline at end of file diff --git a/desmume/src/windows/winpcap/wpcap.lib b/src/windows/winpcap/wpcap.lib similarity index 100% rename from desmume/src/windows/winpcap/wpcap.lib rename to src/windows/winpcap/wpcap.lib diff --git a/desmume/src/windows/winres.h b/src/windows/winres.h similarity index 100% rename from desmume/src/windows/winres.h rename to src/windows/winres.h diff --git a/desmume/src/windows/zlib123/README b/src/windows/zlib123/README similarity index 100% rename from desmume/src/windows/zlib123/README rename to src/windows/zlib123/README diff --git a/desmume/src/windows/zlib123/zconf.h b/src/windows/zlib123/zconf.h similarity index 96% rename from desmume/src/windows/zlib123/zconf.h rename to src/windows/zlib123/zconf.h index ec69ca940..ff5e7481b 100644 --- a/desmume/src/windows/zlib123/zconf.h +++ b/src/windows/zlib123/zconf.h @@ -1,332 +1,332 @@ -/* zconf.h -- configuration of the zlib compression library - * Copyright (C) 1995-2005 Jean-loup Gailly. - * For conditions of distribution and use, see copyright notice in zlib.h - */ - -/* @(#) $Id: zconf.h,v 1.1 2008-08-03 18:36:12 mtabachenko Exp $ */ - -#ifndef ZCONF_H -#define ZCONF_H - -/* - * If you *really* need a unique prefix for all types and library functions, - * compile with -DZ_PREFIX. The "standard" zlib should be compiled without it. - */ -#ifdef Z_PREFIX -# define deflateInit_ z_deflateInit_ -# define deflate z_deflate -# define deflateEnd z_deflateEnd -# define inflateInit_ z_inflateInit_ -# define inflate z_inflate -# define inflateEnd z_inflateEnd -# define deflateInit2_ z_deflateInit2_ -# define deflateSetDictionary z_deflateSetDictionary -# define deflateCopy z_deflateCopy -# define deflateReset z_deflateReset -# define deflateParams z_deflateParams -# define deflateBound z_deflateBound -# define deflatePrime z_deflatePrime -# define inflateInit2_ z_inflateInit2_ -# define inflateSetDictionary z_inflateSetDictionary -# define inflateSync z_inflateSync -# define inflateSyncPoint z_inflateSyncPoint -# define inflateCopy z_inflateCopy -# define inflateReset z_inflateReset -# define inflateBack z_inflateBack -# define inflateBackEnd z_inflateBackEnd -# define compress z_compress -# define compress2 z_compress2 -# define compressBound z_compressBound -# define uncompress z_uncompress -# define adler32 z_adler32 -# define crc32 z_crc32 -# define get_crc_table z_get_crc_table -# define zError z_zError - -# define alloc_func z_alloc_func -# define free_func z_free_func -# define in_func z_in_func -# define out_func z_out_func -# define Byte z_Byte -# define uInt z_uInt -# define uLong z_uLong -# define Bytef z_Bytef -# define charf z_charf -# define intf z_intf -# define uIntf z_uIntf -# define uLongf z_uLongf -# define voidpf z_voidpf -# define voidp z_voidp -#endif - -#if defined(__MSDOS__) && !defined(MSDOS) -# define MSDOS -#endif -#if (defined(OS_2) || defined(__OS2__)) && !defined(OS2) -# define OS2 -#endif -#if defined(_WINDOWS) && !defined(WINDOWS) -# define WINDOWS -#endif -#if defined(_WIN32) || defined(_WIN32_WCE) || defined(__WIN32__) -# ifndef WIN32 -# define WIN32 -# endif -#endif -#if (defined(MSDOS) || defined(OS2) || defined(WINDOWS)) && !defined(WIN32) -# if !defined(__GNUC__) && !defined(__FLAT__) && !defined(__386__) -# ifndef SYS16BIT -# define SYS16BIT -# endif -# endif -#endif - -/* - * Compile with -DMAXSEG_64K if the alloc function cannot allocate more - * than 64k bytes at a time (needed on systems with 16-bit int). - */ -#ifdef SYS16BIT -# define MAXSEG_64K -#endif -#ifdef MSDOS -# define UNALIGNED_OK -#endif - -#ifdef __STDC_VERSION__ -# ifndef STDC -# define STDC -# endif -# if __STDC_VERSION__ >= 199901L -# ifndef STDC99 -# define STDC99 -# endif -# endif -#endif -#if !defined(STDC) && (defined(__STDC__) || defined(__cplusplus)) -# define STDC -#endif -#if !defined(STDC) && (defined(__GNUC__) || defined(__BORLANDC__)) -# define STDC -#endif -#if !defined(STDC) && (defined(MSDOS) || defined(WINDOWS) || defined(WIN32)) -# define STDC -#endif -#if !defined(STDC) && (defined(OS2) || defined(__HOS_AIX__)) -# define STDC -#endif - -#if defined(__OS400__) && !defined(STDC) /* iSeries (formerly AS/400). */ -# define STDC -#endif - -#ifndef STDC -# ifndef const /* cannot use !defined(STDC) && !defined(const) on Mac */ -# define const /* note: need a more gentle solution here */ -# endif -#endif - -/* Some Mac compilers merge all .h files incorrectly: */ -#if defined(__MWERKS__)||defined(applec)||defined(THINK_C)||defined(__SC__) -# define NO_DUMMY_DECL -#endif - -/* Maximum value for memLevel in deflateInit2 */ -#ifndef MAX_MEM_LEVEL -# ifdef MAXSEG_64K -# define MAX_MEM_LEVEL 8 -# else -# define MAX_MEM_LEVEL 9 -# endif -#endif - -/* Maximum value for windowBits in deflateInit2 and inflateInit2. - * WARNING: reducing MAX_WBITS makes minigzip unable to extract .gz files - * created by gzip. (Files created by minigzip can still be extracted by - * gzip.) - */ -#ifndef MAX_WBITS -# define MAX_WBITS 15 /* 32K LZ77 window */ -#endif - -/* The memory requirements for deflate are (in bytes): - (1 << (windowBits+2)) + (1 << (memLevel+9)) - that is: 128K for windowBits=15 + 128K for memLevel = 8 (default values) - plus a few kilobytes for small objects. For example, if you want to reduce - the default memory requirements from 256K to 128K, compile with - make CFLAGS="-O -DMAX_WBITS=14 -DMAX_MEM_LEVEL=7" - Of course this will generally degrade compression (there's no free lunch). - - The memory requirements for inflate are (in bytes) 1 << windowBits - that is, 32K for windowBits=15 (default value) plus a few kilobytes - for small objects. -*/ - - /* Type declarations */ - -#ifndef OF /* function prototypes */ -# ifdef STDC -# define OF(args) args -# else -# define OF(args) () -# endif -#endif - -/* The following definitions for FAR are needed only for MSDOS mixed - * model programming (small or medium model with some far allocations). - * This was tested only with MSC; for other MSDOS compilers you may have - * to define NO_MEMCPY in zutil.h. If you don't need the mixed model, - * just define FAR to be empty. - */ -#ifdef SYS16BIT -# if defined(M_I86SM) || defined(M_I86MM) - /* MSC small or medium model */ -# define SMALL_MEDIUM -# ifdef _MSC_VER -# define FAR _far -# else -# define FAR far -# endif -# endif -# if (defined(__SMALL__) || defined(__MEDIUM__)) - /* Turbo C small or medium model */ -# define SMALL_MEDIUM -# ifdef __BORLANDC__ -# define FAR _far -# else -# define FAR far -# endif -# endif -#endif - -#if defined(WINDOWS) || defined(WIN32) - /* If building or using zlib as a DLL, define ZLIB_DLL. - * This is not mandatory, but it offers a little performance increase. - */ -# ifdef ZLIB_DLL -# if defined(WIN32) && (!defined(__BORLANDC__) || (__BORLANDC__ >= 0x500)) -# ifdef ZLIB_INTERNAL -# define ZEXTERN extern __declspec(dllexport) -# else -# define ZEXTERN extern __declspec(dllimport) -# endif -# endif -# endif /* ZLIB_DLL */ - /* If building or using zlib with the WINAPI/WINAPIV calling convention, - * define ZLIB_WINAPI. - * Caution: the standard ZLIB1.DLL is NOT compiled using ZLIB_WINAPI. - */ -# ifdef ZLIB_WINAPI -# ifdef FAR -# undef FAR -# endif -# include - /* No need for _export, use ZLIB.DEF instead. */ - /* For complete Windows compatibility, use WINAPI, not __stdcall. */ -# define ZEXPORT WINAPI -# ifdef WIN32 -# define ZEXPORTVA WINAPIV -# else -# define ZEXPORTVA FAR CDECL -# endif -# endif -#endif - -#if defined (__BEOS__) -# ifdef ZLIB_DLL -# ifdef ZLIB_INTERNAL -# define ZEXPORT __declspec(dllexport) -# define ZEXPORTVA __declspec(dllexport) -# else -# define ZEXPORT __declspec(dllimport) -# define ZEXPORTVA __declspec(dllimport) -# endif -# endif -#endif - -#ifndef ZEXTERN -# define ZEXTERN extern -#endif -#ifndef ZEXPORT -# define ZEXPORT __cdecl -#endif -#ifndef ZEXPORTVA -# define ZEXPORTVA -#endif - -#ifndef FAR -# define FAR -#endif - -#if !defined(__MACTYPES__) -typedef unsigned char Byte; /* 8 bits */ -#endif -typedef unsigned int uInt; /* 16 bits or more */ -typedef unsigned long uLong; /* 32 bits or more */ - -#ifdef SMALL_MEDIUM - /* Borland C/C++ and some old MSC versions ignore FAR inside typedef */ -# define Bytef Byte FAR -#else - typedef Byte FAR Bytef; -#endif -typedef char FAR charf; -typedef int FAR intf; -typedef uInt FAR uIntf; -typedef uLong FAR uLongf; - -#ifdef STDC - typedef void const *voidpc; - typedef void FAR *voidpf; - typedef void *voidp; -#else - typedef Byte const *voidpc; - typedef Byte FAR *voidpf; - typedef Byte *voidp; -#endif - -#if 0 /* HAVE_UNISTD_H -- this line is updated by ./configure */ -# include /* for off_t */ -# include /* for SEEK_* and off_t */ -# ifdef VMS -# include /* for off_t */ -# endif -# define z_off_t off_t -#endif -#ifndef SEEK_SET -# define SEEK_SET 0 /* Seek from beginning of file. */ -# define SEEK_CUR 1 /* Seek from current position. */ -# define SEEK_END 2 /* Set file pointer to EOF plus "offset" */ -#endif -#ifndef z_off_t -# define z_off_t long -#endif - -#if defined(__OS400__) -# define NO_vsnprintf -#endif - -#if defined(__MVS__) -# define NO_vsnprintf -# ifdef FAR -# undef FAR -# endif -#endif - -/* MVS linker does not support external names larger than 8 bytes */ -#if defined(__MVS__) -# pragma map(deflateInit_,"DEIN") -# pragma map(deflateInit2_,"DEIN2") -# pragma map(deflateEnd,"DEEND") -# pragma map(deflateBound,"DEBND") -# pragma map(inflateInit_,"ININ") -# pragma map(inflateInit2_,"ININ2") -# pragma map(inflateEnd,"INEND") -# pragma map(inflateSync,"INSY") -# pragma map(inflateSetDictionary,"INSEDI") -# pragma map(compressBound,"CMBND") -# pragma map(inflate_table,"INTABL") -# pragma map(inflate_fast,"INFA") -# pragma map(inflate_copyright,"INCOPY") -#endif - -#endif /* ZCONF_H */ +/* zconf.h -- configuration of the zlib compression library + * Copyright (C) 1995-2005 Jean-loup Gailly. + * For conditions of distribution and use, see copyright notice in zlib.h + */ + +/* @(#) $Id: zconf.h,v 1.1 2008-08-03 18:36:12 mtabachenko Exp $ */ + +#ifndef ZCONF_H +#define ZCONF_H + +/* + * If you *really* need a unique prefix for all types and library functions, + * compile with -DZ_PREFIX. The "standard" zlib should be compiled without it. + */ +#ifdef Z_PREFIX +# define deflateInit_ z_deflateInit_ +# define deflate z_deflate +# define deflateEnd z_deflateEnd +# define inflateInit_ z_inflateInit_ +# define inflate z_inflate +# define inflateEnd z_inflateEnd +# define deflateInit2_ z_deflateInit2_ +# define deflateSetDictionary z_deflateSetDictionary +# define deflateCopy z_deflateCopy +# define deflateReset z_deflateReset +# define deflateParams z_deflateParams +# define deflateBound z_deflateBound +# define deflatePrime z_deflatePrime +# define inflateInit2_ z_inflateInit2_ +# define inflateSetDictionary z_inflateSetDictionary +# define inflateSync z_inflateSync +# define inflateSyncPoint z_inflateSyncPoint +# define inflateCopy z_inflateCopy +# define inflateReset z_inflateReset +# define inflateBack z_inflateBack +# define inflateBackEnd z_inflateBackEnd +# define compress z_compress +# define compress2 z_compress2 +# define compressBound z_compressBound +# define uncompress z_uncompress +# define adler32 z_adler32 +# define crc32 z_crc32 +# define get_crc_table z_get_crc_table +# define zError z_zError + +# define alloc_func z_alloc_func +# define free_func z_free_func +# define in_func z_in_func +# define out_func z_out_func +# define Byte z_Byte +# define uInt z_uInt +# define uLong z_uLong +# define Bytef z_Bytef +# define charf z_charf +# define intf z_intf +# define uIntf z_uIntf +# define uLongf z_uLongf +# define voidpf z_voidpf +# define voidp z_voidp +#endif + +#if defined(__MSDOS__) && !defined(MSDOS) +# define MSDOS +#endif +#if (defined(OS_2) || defined(__OS2__)) && !defined(OS2) +# define OS2 +#endif +#if defined(_WINDOWS) && !defined(WINDOWS) +# define WINDOWS +#endif +#if defined(_WIN32) || defined(_WIN32_WCE) || defined(__WIN32__) +# ifndef WIN32 +# define WIN32 +# endif +#endif +#if (defined(MSDOS) || defined(OS2) || defined(WINDOWS)) && !defined(WIN32) +# if !defined(__GNUC__) && !defined(__FLAT__) && !defined(__386__) +# ifndef SYS16BIT +# define SYS16BIT +# endif +# endif +#endif + +/* + * Compile with -DMAXSEG_64K if the alloc function cannot allocate more + * than 64k bytes at a time (needed on systems with 16-bit int). + */ +#ifdef SYS16BIT +# define MAXSEG_64K +#endif +#ifdef MSDOS +# define UNALIGNED_OK +#endif + +#ifdef __STDC_VERSION__ +# ifndef STDC +# define STDC +# endif +# if __STDC_VERSION__ >= 199901L +# ifndef STDC99 +# define STDC99 +# endif +# endif +#endif +#if !defined(STDC) && (defined(__STDC__) || defined(__cplusplus)) +# define STDC +#endif +#if !defined(STDC) && (defined(__GNUC__) || defined(__BORLANDC__)) +# define STDC +#endif +#if !defined(STDC) && (defined(MSDOS) || defined(WINDOWS) || defined(WIN32)) +# define STDC +#endif +#if !defined(STDC) && (defined(OS2) || defined(__HOS_AIX__)) +# define STDC +#endif + +#if defined(__OS400__) && !defined(STDC) /* iSeries (formerly AS/400). */ +# define STDC +#endif + +#ifndef STDC +# ifndef const /* cannot use !defined(STDC) && !defined(const) on Mac */ +# define const /* note: need a more gentle solution here */ +# endif +#endif + +/* Some Mac compilers merge all .h files incorrectly: */ +#if defined(__MWERKS__)||defined(applec)||defined(THINK_C)||defined(__SC__) +# define NO_DUMMY_DECL +#endif + +/* Maximum value for memLevel in deflateInit2 */ +#ifndef MAX_MEM_LEVEL +# ifdef MAXSEG_64K +# define MAX_MEM_LEVEL 8 +# else +# define MAX_MEM_LEVEL 9 +# endif +#endif + +/* Maximum value for windowBits in deflateInit2 and inflateInit2. + * WARNING: reducing MAX_WBITS makes minigzip unable to extract .gz files + * created by gzip. (Files created by minigzip can still be extracted by + * gzip.) + */ +#ifndef MAX_WBITS +# define MAX_WBITS 15 /* 32K LZ77 window */ +#endif + +/* The memory requirements for deflate are (in bytes): + (1 << (windowBits+2)) + (1 << (memLevel+9)) + that is: 128K for windowBits=15 + 128K for memLevel = 8 (default values) + plus a few kilobytes for small objects. For example, if you want to reduce + the default memory requirements from 256K to 128K, compile with + make CFLAGS="-O -DMAX_WBITS=14 -DMAX_MEM_LEVEL=7" + Of course this will generally degrade compression (there's no free lunch). + + The memory requirements for inflate are (in bytes) 1 << windowBits + that is, 32K for windowBits=15 (default value) plus a few kilobytes + for small objects. +*/ + + /* Type declarations */ + +#ifndef OF /* function prototypes */ +# ifdef STDC +# define OF(args) args +# else +# define OF(args) () +# endif +#endif + +/* The following definitions for FAR are needed only for MSDOS mixed + * model programming (small or medium model with some far allocations). + * This was tested only with MSC; for other MSDOS compilers you may have + * to define NO_MEMCPY in zutil.h. If you don't need the mixed model, + * just define FAR to be empty. + */ +#ifdef SYS16BIT +# if defined(M_I86SM) || defined(M_I86MM) + /* MSC small or medium model */ +# define SMALL_MEDIUM +# ifdef _MSC_VER +# define FAR _far +# else +# define FAR far +# endif +# endif +# if (defined(__SMALL__) || defined(__MEDIUM__)) + /* Turbo C small or medium model */ +# define SMALL_MEDIUM +# ifdef __BORLANDC__ +# define FAR _far +# else +# define FAR far +# endif +# endif +#endif + +#if defined(WINDOWS) || defined(WIN32) + /* If building or using zlib as a DLL, define ZLIB_DLL. + * This is not mandatory, but it offers a little performance increase. + */ +# ifdef ZLIB_DLL +# if defined(WIN32) && (!defined(__BORLANDC__) || (__BORLANDC__ >= 0x500)) +# ifdef ZLIB_INTERNAL +# define ZEXTERN extern __declspec(dllexport) +# else +# define ZEXTERN extern __declspec(dllimport) +# endif +# endif +# endif /* ZLIB_DLL */ + /* If building or using zlib with the WINAPI/WINAPIV calling convention, + * define ZLIB_WINAPI. + * Caution: the standard ZLIB1.DLL is NOT compiled using ZLIB_WINAPI. + */ +# ifdef ZLIB_WINAPI +# ifdef FAR +# undef FAR +# endif +# include + /* No need for _export, use ZLIB.DEF instead. */ + /* For complete Windows compatibility, use WINAPI, not __stdcall. */ +# define ZEXPORT WINAPI +# ifdef WIN32 +# define ZEXPORTVA WINAPIV +# else +# define ZEXPORTVA FAR CDECL +# endif +# endif +#endif + +#if defined (__BEOS__) +# ifdef ZLIB_DLL +# ifdef ZLIB_INTERNAL +# define ZEXPORT __declspec(dllexport) +# define ZEXPORTVA __declspec(dllexport) +# else +# define ZEXPORT __declspec(dllimport) +# define ZEXPORTVA __declspec(dllimport) +# endif +# endif +#endif + +#ifndef ZEXTERN +# define ZEXTERN extern +#endif +#ifndef ZEXPORT +# define ZEXPORT __cdecl +#endif +#ifndef ZEXPORTVA +# define ZEXPORTVA +#endif + +#ifndef FAR +# define FAR +#endif + +#if !defined(__MACTYPES__) +typedef unsigned char Byte; /* 8 bits */ +#endif +typedef unsigned int uInt; /* 16 bits or more */ +typedef unsigned long uLong; /* 32 bits or more */ + +#ifdef SMALL_MEDIUM + /* Borland C/C++ and some old MSC versions ignore FAR inside typedef */ +# define Bytef Byte FAR +#else + typedef Byte FAR Bytef; +#endif +typedef char FAR charf; +typedef int FAR intf; +typedef uInt FAR uIntf; +typedef uLong FAR uLongf; + +#ifdef STDC + typedef void const *voidpc; + typedef void FAR *voidpf; + typedef void *voidp; +#else + typedef Byte const *voidpc; + typedef Byte FAR *voidpf; + typedef Byte *voidp; +#endif + +#if 0 /* HAVE_UNISTD_H -- this line is updated by ./configure */ +# include /* for off_t */ +# include /* for SEEK_* and off_t */ +# ifdef VMS +# include /* for off_t */ +# endif +# define z_off_t off_t +#endif +#ifndef SEEK_SET +# define SEEK_SET 0 /* Seek from beginning of file. */ +# define SEEK_CUR 1 /* Seek from current position. */ +# define SEEK_END 2 /* Set file pointer to EOF plus "offset" */ +#endif +#ifndef z_off_t +# define z_off_t long +#endif + +#if defined(__OS400__) +# define NO_vsnprintf +#endif + +#if defined(__MVS__) +# define NO_vsnprintf +# ifdef FAR +# undef FAR +# endif +#endif + +/* MVS linker does not support external names larger than 8 bytes */ +#if defined(__MVS__) +# pragma map(deflateInit_,"DEIN") +# pragma map(deflateInit2_,"DEIN2") +# pragma map(deflateEnd,"DEEND") +# pragma map(deflateBound,"DEBND") +# pragma map(inflateInit_,"ININ") +# pragma map(inflateInit2_,"ININ2") +# pragma map(inflateEnd,"INEND") +# pragma map(inflateSync,"INSY") +# pragma map(inflateSetDictionary,"INSEDI") +# pragma map(compressBound,"CMBND") +# pragma map(inflate_table,"INTABL") +# pragma map(inflate_fast,"INFA") +# pragma map(inflate_copyright,"INCOPY") +#endif + +#endif /* ZCONF_H */ diff --git a/desmume/src/windows/zlib123/zlib-2005-x32.lib b/src/windows/zlib123/zlib-2005-x32.lib similarity index 100% rename from desmume/src/windows/zlib123/zlib-2005-x32.lib rename to src/windows/zlib123/zlib-2005-x32.lib diff --git a/desmume/src/windows/zlib123/zlib-2005-x64.lib b/src/windows/zlib123/zlib-2005-x64.lib similarity index 100% rename from desmume/src/windows/zlib123/zlib-2005-x64.lib rename to src/windows/zlib123/zlib-2005-x64.lib diff --git a/desmume/src/windows/zlib123/zlib-2008-x32.lib b/src/windows/zlib123/zlib-2008-x32.lib similarity index 100% rename from desmume/src/windows/zlib123/zlib-2008-x32.lib rename to src/windows/zlib123/zlib-2008-x32.lib diff --git a/desmume/src/windows/zlib123/zlib-2008-x64.lib b/src/windows/zlib123/zlib-2008-x64.lib similarity index 100% rename from desmume/src/windows/zlib123/zlib-2008-x64.lib rename to src/windows/zlib123/zlib-2008-x64.lib diff --git a/desmume/src/windows/zlib123/zlib.h b/src/windows/zlib123/zlib.h similarity index 97% rename from desmume/src/windows/zlib123/zlib.h rename to src/windows/zlib123/zlib.h index 022817927..62d0e4675 100644 --- a/desmume/src/windows/zlib123/zlib.h +++ b/src/windows/zlib123/zlib.h @@ -1,1357 +1,1357 @@ -/* zlib.h -- interface of the 'zlib' general purpose compression library - version 1.2.3, July 18th, 2005 - - Copyright (C) 1995-2005 Jean-loup Gailly and Mark Adler - - This software is provided 'as-is', without any express or implied - warranty. In no event will the authors be held liable for any damages - arising from the use of this software. - - Permission is granted to anyone to use this software for any purpose, - including commercial applications, and to alter it and redistribute it - freely, subject to the following restrictions: - - 1. The origin of this software must not be misrepresented; you must not - claim that you wrote the original software. If you use this software - in a product, an acknowledgment in the product documentation would be - appreciated but is not required. - 2. Altered source versions must be plainly marked as such, and must not be - misrepresented as being the original software. - 3. This notice may not be removed or altered from any source distribution. - - Jean-loup Gailly Mark Adler - jloup@gzip.org madler@alumni.caltech.edu - - - The data format used by the zlib library is described by RFCs (Request for - Comments) 1950 to 1952 in the files http://www.ietf.org/rfc/rfc1950.txt - (zlib format), rfc1951.txt (deflate format) and rfc1952.txt (gzip format). -*/ - -#ifndef ZLIB_H -#define ZLIB_H - -#include "zconf.h" - -#ifdef __cplusplus -extern "C" { -#endif - -#define ZLIB_VERSION "1.2.3" -#define ZLIB_VERNUM 0x1230 - -/* - The 'zlib' compression library provides in-memory compression and - decompression functions, including integrity checks of the uncompressed - data. This version of the library supports only one compression method - (deflation) but other algorithms will be added later and will have the same - stream interface. - - Compression can be done in a single step if the buffers are large - enough (for example if an input file is mmap'ed), or can be done by - repeated calls of the compression function. In the latter case, the - application must provide more input and/or consume the output - (providing more output space) before each call. - - The compressed data format used by default by the in-memory functions is - the zlib format, which is a zlib wrapper documented in RFC 1950, wrapped - around a deflate stream, which is itself documented in RFC 1951. - - The library also supports reading and writing files in gzip (.gz) format - with an interface similar to that of stdio using the functions that start - with "gz". The gzip format is different from the zlib format. gzip is a - gzip wrapper, documented in RFC 1952, wrapped around a deflate stream. - - This library can optionally read and write gzip streams in memory as well. - - The zlib format was designed to be compact and fast for use in memory - and on communications channels. The gzip format was designed for single- - file compression on file systems, has a larger header than zlib to maintain - directory information, and uses a different, slower check method than zlib. - - The library does not install any signal handler. The decoder checks - the consistency of the compressed data, so the library should never - crash even in case of corrupted input. -*/ - -typedef voidpf (*alloc_func) OF((voidpf opaque, uInt items, uInt size)); -typedef void (*free_func) OF((voidpf opaque, voidpf address)); - -struct internal_state; - -typedef struct z_stream_s { - Bytef *next_in; /* next input byte */ - uInt avail_in; /* number of bytes available at next_in */ - uLong total_in; /* total nb of input bytes read so far */ - - Bytef *next_out; /* next output byte should be put there */ - uInt avail_out; /* remaining free space at next_out */ - uLong total_out; /* total nb of bytes output so far */ - - char *msg; /* last error message, NULL if no error */ - struct internal_state FAR *state; /* not visible by applications */ - - alloc_func zalloc; /* used to allocate the internal state */ - free_func zfree; /* used to free the internal state */ - voidpf opaque; /* private data object passed to zalloc and zfree */ - - int data_type; /* best guess about the data type: binary or text */ - uLong adler; /* adler32 value of the uncompressed data */ - uLong reserved; /* reserved for future use */ -} z_stream; - -typedef z_stream FAR *z_streamp; - -/* - gzip header information passed to and from zlib routines. See RFC 1952 - for more details on the meanings of these fields. -*/ -typedef struct gz_header_s { - int text; /* true if compressed data believed to be text */ - uLong time; /* modification time */ - int xflags; /* extra flags (not used when writing a gzip file) */ - int os; /* operating system */ - Bytef *extra; /* pointer to extra field or Z_NULL if none */ - uInt extra_len; /* extra field length (valid if extra != Z_NULL) */ - uInt extra_max; /* space at extra (only when reading header) */ - Bytef *name; /* pointer to zero-terminated file name or Z_NULL */ - uInt name_max; /* space at name (only when reading header) */ - Bytef *comment; /* pointer to zero-terminated comment or Z_NULL */ - uInt comm_max; /* space at comment (only when reading header) */ - int hcrc; /* true if there was or will be a header crc */ - int done; /* true when done reading gzip header (not used - when writing a gzip file) */ -} gz_header; - -typedef gz_header FAR *gz_headerp; - -/* - The application must update next_in and avail_in when avail_in has - dropped to zero. It must update next_out and avail_out when avail_out - has dropped to zero. The application must initialize zalloc, zfree and - opaque before calling the init function. All other fields are set by the - compression library and must not be updated by the application. - - The opaque value provided by the application will be passed as the first - parameter for calls of zalloc and zfree. This can be useful for custom - memory management. The compression library attaches no meaning to the - opaque value. - - zalloc must return Z_NULL if there is not enough memory for the object. - If zlib is used in a multi-threaded application, zalloc and zfree must be - thread safe. - - On 16-bit systems, the functions zalloc and zfree must be able to allocate - exactly 65536 bytes, but will not be required to allocate more than this - if the symbol MAXSEG_64K is defined (see zconf.h). WARNING: On MSDOS, - pointers returned by zalloc for objects of exactly 65536 bytes *must* - have their offset normalized to zero. The default allocation function - provided by this library ensures this (see zutil.c). To reduce memory - requirements and avoid any allocation of 64K objects, at the expense of - compression ratio, compile the library with -DMAX_WBITS=14 (see zconf.h). - - The fields total_in and total_out can be used for statistics or - progress reports. After compression, total_in holds the total size of - the uncompressed data and may be saved for use in the decompressor - (particularly if the decompressor wants to decompress everything in - a single step). -*/ - - /* constants */ - -#define Z_NO_FLUSH 0 -#define Z_PARTIAL_FLUSH 1 /* will be removed, use Z_SYNC_FLUSH instead */ -#define Z_SYNC_FLUSH 2 -#define Z_FULL_FLUSH 3 -#define Z_FINISH 4 -#define Z_BLOCK 5 -/* Allowed flush values; see deflate() and inflate() below for details */ - -#define Z_OK 0 -#define Z_STREAM_END 1 -#define Z_NEED_DICT 2 -#define Z_ERRNO (-1) -#define Z_STREAM_ERROR (-2) -#define Z_DATA_ERROR (-3) -#define Z_MEM_ERROR (-4) -#define Z_BUF_ERROR (-5) -#define Z_VERSION_ERROR (-6) -/* Return codes for the compression/decompression functions. Negative - * values are errors, positive values are used for special but normal events. - */ - -#define Z_NO_COMPRESSION 0 -#define Z_BEST_SPEED 1 -#define Z_BEST_COMPRESSION 9 -#define Z_DEFAULT_COMPRESSION (-1) -/* compression levels */ - -#define Z_FILTERED 1 -#define Z_HUFFMAN_ONLY 2 -#define Z_RLE 3 -#define Z_FIXED 4 -#define Z_DEFAULT_STRATEGY 0 -/* compression strategy; see deflateInit2() below for details */ - -#define Z_BINARY 0 -#define Z_TEXT 1 -#define Z_ASCII Z_TEXT /* for compatibility with 1.2.2 and earlier */ -#define Z_UNKNOWN 2 -/* Possible values of the data_type field (though see inflate()) */ - -#define Z_DEFLATED 8 -/* The deflate compression method (the only one supported in this version) */ - -#define Z_NULL 0 /* for initializing zalloc, zfree, opaque */ - -#define zlib_version zlibVersion() -/* for compatibility with versions < 1.0.2 */ - - /* basic functions */ - -ZEXTERN const char * ZEXPORT zlibVersion OF((void)); -/* The application can compare zlibVersion and ZLIB_VERSION for consistency. - If the first character differs, the library code actually used is - not compatible with the zlib.h header file used by the application. - This check is automatically made by deflateInit and inflateInit. - */ - -/* -ZEXTERN int ZEXPORT deflateInit OF((z_streamp strm, int level)); - - Initializes the internal stream state for compression. The fields - zalloc, zfree and opaque must be initialized before by the caller. - If zalloc and zfree are set to Z_NULL, deflateInit updates them to - use default allocation functions. - - The compression level must be Z_DEFAULT_COMPRESSION, or between 0 and 9: - 1 gives best speed, 9 gives best compression, 0 gives no compression at - all (the input data is simply copied a block at a time). - Z_DEFAULT_COMPRESSION requests a default compromise between speed and - compression (currently equivalent to level 6). - - deflateInit returns Z_OK if success, Z_MEM_ERROR if there was not - enough memory, Z_STREAM_ERROR if level is not a valid compression level, - Z_VERSION_ERROR if the zlib library version (zlib_version) is incompatible - with the version assumed by the caller (ZLIB_VERSION). - msg is set to null if there is no error message. deflateInit does not - perform any compression: this will be done by deflate(). -*/ - - -ZEXTERN int ZEXPORT deflate OF((z_streamp strm, int flush)); -/* - deflate compresses as much data as possible, and stops when the input - buffer becomes empty or the output buffer becomes full. It may introduce some - output latency (reading input without producing any output) except when - forced to flush. - - The detailed semantics are as follows. deflate performs one or both of the - following actions: - - - Compress more input starting at next_in and update next_in and avail_in - accordingly. If not all input can be processed (because there is not - enough room in the output buffer), next_in and avail_in are updated and - processing will resume at this point for the next call of deflate(). - - - Provide more output starting at next_out and update next_out and avail_out - accordingly. This action is forced if the parameter flush is non zero. - Forcing flush frequently degrades the compression ratio, so this parameter - should be set only when necessary (in interactive applications). - Some output may be provided even if flush is not set. - - Before the call of deflate(), the application should ensure that at least - one of the actions is possible, by providing more input and/or consuming - more output, and updating avail_in or avail_out accordingly; avail_out - should never be zero before the call. The application can consume the - compressed output when it wants, for example when the output buffer is full - (avail_out == 0), or after each call of deflate(). If deflate returns Z_OK - and with zero avail_out, it must be called again after making room in the - output buffer because there might be more output pending. - - Normally the parameter flush is set to Z_NO_FLUSH, which allows deflate to - decide how much data to accumualte before producing output, in order to - maximize compression. - - If the parameter flush is set to Z_SYNC_FLUSH, all pending output is - flushed to the output buffer and the output is aligned on a byte boundary, so - that the decompressor can get all input data available so far. (In particular - avail_in is zero after the call if enough output space has been provided - before the call.) Flushing may degrade compression for some compression - algorithms and so it should be used only when necessary. - - If flush is set to Z_FULL_FLUSH, all output is flushed as with - Z_SYNC_FLUSH, and the compression state is reset so that decompression can - restart from this point if previous compressed data has been damaged or if - random access is desired. Using Z_FULL_FLUSH too often can seriously degrade - compression. - - If deflate returns with avail_out == 0, this function must be called again - with the same value of the flush parameter and more output space (updated - avail_out), until the flush is complete (deflate returns with non-zero - avail_out). In the case of a Z_FULL_FLUSH or Z_SYNC_FLUSH, make sure that - avail_out is greater than six to avoid repeated flush markers due to - avail_out == 0 on return. - - If the parameter flush is set to Z_FINISH, pending input is processed, - pending output is flushed and deflate returns with Z_STREAM_END if there - was enough output space; if deflate returns with Z_OK, this function must be - called again with Z_FINISH and more output space (updated avail_out) but no - more input data, until it returns with Z_STREAM_END or an error. After - deflate has returned Z_STREAM_END, the only possible operations on the - stream are deflateReset or deflateEnd. - - Z_FINISH can be used immediately after deflateInit if all the compression - is to be done in a single step. In this case, avail_out must be at least - the value returned by deflateBound (see below). If deflate does not return - Z_STREAM_END, then it must be called again as described above. - - deflate() sets strm->adler to the adler32 checksum of all input read - so far (that is, total_in bytes). - - deflate() may update strm->data_type if it can make a good guess about - the input data type (Z_BINARY or Z_TEXT). In doubt, the data is considered - binary. This field is only for information purposes and does not affect - the compression algorithm in any manner. - - deflate() returns Z_OK if some progress has been made (more input - processed or more output produced), Z_STREAM_END if all input has been - consumed and all output has been produced (only when flush is set to - Z_FINISH), Z_STREAM_ERROR if the stream state was inconsistent (for example - if next_in or next_out was NULL), Z_BUF_ERROR if no progress is possible - (for example avail_in or avail_out was zero). Note that Z_BUF_ERROR is not - fatal, and deflate() can be called again with more input and more output - space to continue compressing. -*/ - - -ZEXTERN int ZEXPORT deflateEnd OF((z_streamp strm)); -/* - All dynamically allocated data structures for this stream are freed. - This function discards any unprocessed input and does not flush any - pending output. - - deflateEnd returns Z_OK if success, Z_STREAM_ERROR if the - stream state was inconsistent, Z_DATA_ERROR if the stream was freed - prematurely (some input or output was discarded). In the error case, - msg may be set but then points to a static string (which must not be - deallocated). -*/ - - -/* -ZEXTERN int ZEXPORT inflateInit OF((z_streamp strm)); - - Initializes the internal stream state for decompression. The fields - next_in, avail_in, zalloc, zfree and opaque must be initialized before by - the caller. If next_in is not Z_NULL and avail_in is large enough (the exact - value depends on the compression method), inflateInit determines the - compression method from the zlib header and allocates all data structures - accordingly; otherwise the allocation will be deferred to the first call of - inflate. If zalloc and zfree are set to Z_NULL, inflateInit updates them to - use default allocation functions. - - inflateInit returns Z_OK if success, Z_MEM_ERROR if there was not enough - memory, Z_VERSION_ERROR if the zlib library version is incompatible with the - version assumed by the caller. msg is set to null if there is no error - message. inflateInit does not perform any decompression apart from reading - the zlib header if present: this will be done by inflate(). (So next_in and - avail_in may be modified, but next_out and avail_out are unchanged.) -*/ - - -ZEXTERN int ZEXPORT inflate OF((z_streamp strm, int flush)); -/* - inflate decompresses as much data as possible, and stops when the input - buffer becomes empty or the output buffer becomes full. It may introduce - some output latency (reading input without producing any output) except when - forced to flush. - - The detailed semantics are as follows. inflate performs one or both of the - following actions: - - - Decompress more input starting at next_in and update next_in and avail_in - accordingly. If not all input can be processed (because there is not - enough room in the output buffer), next_in is updated and processing - will resume at this point for the next call of inflate(). - - - Provide more output starting at next_out and update next_out and avail_out - accordingly. inflate() provides as much output as possible, until there - is no more input data or no more space in the output buffer (see below - about the flush parameter). - - Before the call of inflate(), the application should ensure that at least - one of the actions is possible, by providing more input and/or consuming - more output, and updating the next_* and avail_* values accordingly. - The application can consume the uncompressed output when it wants, for - example when the output buffer is full (avail_out == 0), or after each - call of inflate(). If inflate returns Z_OK and with zero avail_out, it - must be called again after making room in the output buffer because there - might be more output pending. - - The flush parameter of inflate() can be Z_NO_FLUSH, Z_SYNC_FLUSH, - Z_FINISH, or Z_BLOCK. Z_SYNC_FLUSH requests that inflate() flush as much - output as possible to the output buffer. Z_BLOCK requests that inflate() stop - if and when it gets to the next deflate block boundary. When decoding the - zlib or gzip format, this will cause inflate() to return immediately after - the header and before the first block. When doing a raw inflate, inflate() - will go ahead and process the first block, and will return when it gets to - the end of that block, or when it runs out of data. - - The Z_BLOCK option assists in appending to or combining deflate streams. - Also to assist in this, on return inflate() will set strm->data_type to the - number of unused bits in the last byte taken from strm->next_in, plus 64 - if inflate() is currently decoding the last block in the deflate stream, - plus 128 if inflate() returned immediately after decoding an end-of-block - code or decoding the complete header up to just before the first byte of the - deflate stream. The end-of-block will not be indicated until all of the - uncompressed data from that block has been written to strm->next_out. The - number of unused bits may in general be greater than seven, except when - bit 7 of data_type is set, in which case the number of unused bits will be - less than eight. - - inflate() should normally be called until it returns Z_STREAM_END or an - error. However if all decompression is to be performed in a single step - (a single call of inflate), the parameter flush should be set to - Z_FINISH. In this case all pending input is processed and all pending - output is flushed; avail_out must be large enough to hold all the - uncompressed data. (The size of the uncompressed data may have been saved - by the compressor for this purpose.) The next operation on this stream must - be inflateEnd to deallocate the decompression state. The use of Z_FINISH - is never required, but can be used to inform inflate that a faster approach - may be used for the single inflate() call. - - In this implementation, inflate() always flushes as much output as - possible to the output buffer, and always uses the faster approach on the - first call. So the only effect of the flush parameter in this implementation - is on the return value of inflate(), as noted below, or when it returns early - because Z_BLOCK is used. - - If a preset dictionary is needed after this call (see inflateSetDictionary - below), inflate sets strm->adler to the adler32 checksum of the dictionary - chosen by the compressor and returns Z_NEED_DICT; otherwise it sets - strm->adler to the adler32 checksum of all output produced so far (that is, - total_out bytes) and returns Z_OK, Z_STREAM_END or an error code as described - below. At the end of the stream, inflate() checks that its computed adler32 - checksum is equal to that saved by the compressor and returns Z_STREAM_END - only if the checksum is correct. - - inflate() will decompress and check either zlib-wrapped or gzip-wrapped - deflate data. The header type is detected automatically. Any information - contained in the gzip header is not retained, so applications that need that - information should instead use raw inflate, see inflateInit2() below, or - inflateBack() and perform their own processing of the gzip header and - trailer. - - inflate() returns Z_OK if some progress has been made (more input processed - or more output produced), Z_STREAM_END if the end of the compressed data has - been reached and all uncompressed output has been produced, Z_NEED_DICT if a - preset dictionary is needed at this point, Z_DATA_ERROR if the input data was - corrupted (input stream not conforming to the zlib format or incorrect check - value), Z_STREAM_ERROR if the stream structure was inconsistent (for example - if next_in or next_out was NULL), Z_MEM_ERROR if there was not enough memory, - Z_BUF_ERROR if no progress is possible or if there was not enough room in the - output buffer when Z_FINISH is used. Note that Z_BUF_ERROR is not fatal, and - inflate() can be called again with more input and more output space to - continue decompressing. If Z_DATA_ERROR is returned, the application may then - call inflateSync() to look for a good compression block if a partial recovery - of the data is desired. -*/ - - -ZEXTERN int ZEXPORT inflateEnd OF((z_streamp strm)); -/* - All dynamically allocated data structures for this stream are freed. - This function discards any unprocessed input and does not flush any - pending output. - - inflateEnd returns Z_OK if success, Z_STREAM_ERROR if the stream state - was inconsistent. In the error case, msg may be set but then points to a - static string (which must not be deallocated). -*/ - - /* Advanced functions */ - -/* - The following functions are needed only in some special applications. -*/ - -/* -ZEXTERN int ZEXPORT deflateInit2 OF((z_streamp strm, - int level, - int method, - int windowBits, - int memLevel, - int strategy)); - - This is another version of deflateInit with more compression options. The - fields next_in, zalloc, zfree and opaque must be initialized before by - the caller. - - The method parameter is the compression method. It must be Z_DEFLATED in - this version of the library. - - The windowBits parameter is the base two logarithm of the window size - (the size of the history buffer). It should be in the range 8..15 for this - version of the library. Larger values of this parameter result in better - compression at the expense of memory usage. The default value is 15 if - deflateInit is used instead. - - windowBits can also be -8..-15 for raw deflate. In this case, -windowBits - determines the window size. deflate() will then generate raw deflate data - with no zlib header or trailer, and will not compute an adler32 check value. - - windowBits can also be greater than 15 for optional gzip encoding. Add - 16 to windowBits to write a simple gzip header and trailer around the - compressed data instead of a zlib wrapper. The gzip header will have no - file name, no extra data, no comment, no modification time (set to zero), - no header crc, and the operating system will be set to 255 (unknown). If a - gzip stream is being written, strm->adler is a crc32 instead of an adler32. - - The memLevel parameter specifies how much memory should be allocated - for the internal compression state. memLevel=1 uses minimum memory but - is slow and reduces compression ratio; memLevel=9 uses maximum memory - for optimal speed. The default value is 8. See zconf.h for total memory - usage as a function of windowBits and memLevel. - - The strategy parameter is used to tune the compression algorithm. Use the - value Z_DEFAULT_STRATEGY for normal data, Z_FILTERED for data produced by a - filter (or predictor), Z_HUFFMAN_ONLY to force Huffman encoding only (no - string match), or Z_RLE to limit match distances to one (run-length - encoding). Filtered data consists mostly of small values with a somewhat - random distribution. In this case, the compression algorithm is tuned to - compress them better. The effect of Z_FILTERED is to force more Huffman - coding and less string matching; it is somewhat intermediate between - Z_DEFAULT and Z_HUFFMAN_ONLY. Z_RLE is designed to be almost as fast as - Z_HUFFMAN_ONLY, but give better compression for PNG image data. The strategy - parameter only affects the compression ratio but not the correctness of the - compressed output even if it is not set appropriately. Z_FIXED prevents the - use of dynamic Huffman codes, allowing for a simpler decoder for special - applications. - - deflateInit2 returns Z_OK if success, Z_MEM_ERROR if there was not enough - memory, Z_STREAM_ERROR if a parameter is invalid (such as an invalid - method). msg is set to null if there is no error message. deflateInit2 does - not perform any compression: this will be done by deflate(). -*/ - -ZEXTERN int ZEXPORT deflateSetDictionary OF((z_streamp strm, - const Bytef *dictionary, - uInt dictLength)); -/* - Initializes the compression dictionary from the given byte sequence - without producing any compressed output. This function must be called - immediately after deflateInit, deflateInit2 or deflateReset, before any - call of deflate. The compressor and decompressor must use exactly the same - dictionary (see inflateSetDictionary). - - The dictionary should consist of strings (byte sequences) that are likely - to be encountered later in the data to be compressed, with the most commonly - used strings preferably put towards the end of the dictionary. Using a - dictionary is most useful when the data to be compressed is short and can be - predicted with good accuracy; the data can then be compressed better than - with the default empty dictionary. - - Depending on the size of the compression data structures selected by - deflateInit or deflateInit2, a part of the dictionary may in effect be - discarded, for example if the dictionary is larger than the window size in - deflate or deflate2. Thus the strings most likely to be useful should be - put at the end of the dictionary, not at the front. In addition, the - current implementation of deflate will use at most the window size minus - 262 bytes of the provided dictionary. - - Upon return of this function, strm->adler is set to the adler32 value - of the dictionary; the decompressor may later use this value to determine - which dictionary has been used by the compressor. (The adler32 value - applies to the whole dictionary even if only a subset of the dictionary is - actually used by the compressor.) If a raw deflate was requested, then the - adler32 value is not computed and strm->adler is not set. - - deflateSetDictionary returns Z_OK if success, or Z_STREAM_ERROR if a - parameter is invalid (such as NULL dictionary) or the stream state is - inconsistent (for example if deflate has already been called for this stream - or if the compression method is bsort). deflateSetDictionary does not - perform any compression: this will be done by deflate(). -*/ - -ZEXTERN int ZEXPORT deflateCopy OF((z_streamp dest, - z_streamp source)); -/* - Sets the destination stream as a complete copy of the source stream. - - This function can be useful when several compression strategies will be - tried, for example when there are several ways of pre-processing the input - data with a filter. The streams that will be discarded should then be freed - by calling deflateEnd. Note that deflateCopy duplicates the internal - compression state which can be quite large, so this strategy is slow and - can consume lots of memory. - - deflateCopy returns Z_OK if success, Z_MEM_ERROR if there was not - enough memory, Z_STREAM_ERROR if the source stream state was inconsistent - (such as zalloc being NULL). msg is left unchanged in both source and - destination. -*/ - -ZEXTERN int ZEXPORT deflateReset OF((z_streamp strm)); -/* - This function is equivalent to deflateEnd followed by deflateInit, - but does not free and reallocate all the internal compression state. - The stream will keep the same compression level and any other attributes - that may have been set by deflateInit2. - - deflateReset returns Z_OK if success, or Z_STREAM_ERROR if the source - stream state was inconsistent (such as zalloc or state being NULL). -*/ - -ZEXTERN int ZEXPORT deflateParams OF((z_streamp strm, - int level, - int strategy)); -/* - Dynamically update the compression level and compression strategy. The - interpretation of level and strategy is as in deflateInit2. This can be - used to switch between compression and straight copy of the input data, or - to switch to a different kind of input data requiring a different - strategy. If the compression level is changed, the input available so far - is compressed with the old level (and may be flushed); the new level will - take effect only at the next call of deflate(). - - Before the call of deflateParams, the stream state must be set as for - a call of deflate(), since the currently available input may have to - be compressed and flushed. In particular, strm->avail_out must be non-zero. - - deflateParams returns Z_OK if success, Z_STREAM_ERROR if the source - stream state was inconsistent or if a parameter was invalid, Z_BUF_ERROR - if strm->avail_out was zero. -*/ - -ZEXTERN int ZEXPORT deflateTune OF((z_streamp strm, - int good_length, - int max_lazy, - int nice_length, - int max_chain)); -/* - Fine tune deflate's internal compression parameters. This should only be - used by someone who understands the algorithm used by zlib's deflate for - searching for the best matching string, and even then only by the most - fanatic optimizer trying to squeeze out the last compressed bit for their - specific input data. Read the deflate.c source code for the meaning of the - max_lazy, good_length, nice_length, and max_chain parameters. - - deflateTune() can be called after deflateInit() or deflateInit2(), and - returns Z_OK on success, or Z_STREAM_ERROR for an invalid deflate stream. - */ - -ZEXTERN uLong ZEXPORT deflateBound OF((z_streamp strm, - uLong sourceLen)); -/* - deflateBound() returns an upper bound on the compressed size after - deflation of sourceLen bytes. It must be called after deflateInit() - or deflateInit2(). This would be used to allocate an output buffer - for deflation in a single pass, and so would be called before deflate(). -*/ - -ZEXTERN int ZEXPORT deflatePrime OF((z_streamp strm, - int bits, - int value)); -/* - deflatePrime() inserts bits in the deflate output stream. The intent - is that this function is used to start off the deflate output with the - bits leftover from a previous deflate stream when appending to it. As such, - this function can only be used for raw deflate, and must be used before the - first deflate() call after a deflateInit2() or deflateReset(). bits must be - less than or equal to 16, and that many of the least significant bits of - value will be inserted in the output. - - deflatePrime returns Z_OK if success, or Z_STREAM_ERROR if the source - stream state was inconsistent. -*/ - -ZEXTERN int ZEXPORT deflateSetHeader OF((z_streamp strm, - gz_headerp head)); -/* - deflateSetHeader() provides gzip header information for when a gzip - stream is requested by deflateInit2(). deflateSetHeader() may be called - after deflateInit2() or deflateReset() and before the first call of - deflate(). The text, time, os, extra field, name, and comment information - in the provided gz_header structure are written to the gzip header (xflag is - ignored -- the extra flags are set according to the compression level). The - caller must assure that, if not Z_NULL, name and comment are terminated with - a zero byte, and that if extra is not Z_NULL, that extra_len bytes are - available there. If hcrc is true, a gzip header crc is included. Note that - the current versions of the command-line version of gzip (up through version - 1.3.x) do not support header crc's, and will report that it is a "multi-part - gzip file" and give up. - - If deflateSetHeader is not used, the default gzip header has text false, - the time set to zero, and os set to 255, with no extra, name, or comment - fields. The gzip header is returned to the default state by deflateReset(). - - deflateSetHeader returns Z_OK if success, or Z_STREAM_ERROR if the source - stream state was inconsistent. -*/ - -/* -ZEXTERN int ZEXPORT inflateInit2 OF((z_streamp strm, - int windowBits)); - - This is another version of inflateInit with an extra parameter. The - fields next_in, avail_in, zalloc, zfree and opaque must be initialized - before by the caller. - - The windowBits parameter is the base two logarithm of the maximum window - size (the size of the history buffer). It should be in the range 8..15 for - this version of the library. The default value is 15 if inflateInit is used - instead. windowBits must be greater than or equal to the windowBits value - provided to deflateInit2() while compressing, or it must be equal to 15 if - deflateInit2() was not used. If a compressed stream with a larger window - size is given as input, inflate() will return with the error code - Z_DATA_ERROR instead of trying to allocate a larger window. - - windowBits can also be -8..-15 for raw inflate. In this case, -windowBits - determines the window size. inflate() will then process raw deflate data, - not looking for a zlib or gzip header, not generating a check value, and not - looking for any check values for comparison at the end of the stream. This - is for use with other formats that use the deflate compressed data format - such as zip. Those formats provide their own check values. If a custom - format is developed using the raw deflate format for compressed data, it is - recommended that a check value such as an adler32 or a crc32 be applied to - the uncompressed data as is done in the zlib, gzip, and zip formats. For - most applications, the zlib format should be used as is. Note that comments - above on the use in deflateInit2() applies to the magnitude of windowBits. - - windowBits can also be greater than 15 for optional gzip decoding. Add - 32 to windowBits to enable zlib and gzip decoding with automatic header - detection, or add 16 to decode only the gzip format (the zlib format will - return a Z_DATA_ERROR). If a gzip stream is being decoded, strm->adler is - a crc32 instead of an adler32. - - inflateInit2 returns Z_OK if success, Z_MEM_ERROR if there was not enough - memory, Z_STREAM_ERROR if a parameter is invalid (such as a null strm). msg - is set to null if there is no error message. inflateInit2 does not perform - any decompression apart from reading the zlib header if present: this will - be done by inflate(). (So next_in and avail_in may be modified, but next_out - and avail_out are unchanged.) -*/ - -ZEXTERN int ZEXPORT inflateSetDictionary OF((z_streamp strm, - const Bytef *dictionary, - uInt dictLength)); -/* - Initializes the decompression dictionary from the given uncompressed byte - sequence. This function must be called immediately after a call of inflate, - if that call returned Z_NEED_DICT. The dictionary chosen by the compressor - can be determined from the adler32 value returned by that call of inflate. - The compressor and decompressor must use exactly the same dictionary (see - deflateSetDictionary). For raw inflate, this function can be called - immediately after inflateInit2() or inflateReset() and before any call of - inflate() to set the dictionary. The application must insure that the - dictionary that was used for compression is provided. - - inflateSetDictionary returns Z_OK if success, Z_STREAM_ERROR if a - parameter is invalid (such as NULL dictionary) or the stream state is - inconsistent, Z_DATA_ERROR if the given dictionary doesn't match the - expected one (incorrect adler32 value). inflateSetDictionary does not - perform any decompression: this will be done by subsequent calls of - inflate(). -*/ - -ZEXTERN int ZEXPORT inflateSync OF((z_streamp strm)); -/* - Skips invalid compressed data until a full flush point (see above the - description of deflate with Z_FULL_FLUSH) can be found, or until all - available input is skipped. No output is provided. - - inflateSync returns Z_OK if a full flush point has been found, Z_BUF_ERROR - if no more input was provided, Z_DATA_ERROR if no flush point has been found, - or Z_STREAM_ERROR if the stream structure was inconsistent. In the success - case, the application may save the current current value of total_in which - indicates where valid compressed data was found. In the error case, the - application may repeatedly call inflateSync, providing more input each time, - until success or end of the input data. -*/ - -ZEXTERN int ZEXPORT inflateCopy OF((z_streamp dest, - z_streamp source)); -/* - Sets the destination stream as a complete copy of the source stream. - - This function can be useful when randomly accessing a large stream. The - first pass through the stream can periodically record the inflate state, - allowing restarting inflate at those points when randomly accessing the - stream. - - inflateCopy returns Z_OK if success, Z_MEM_ERROR if there was not - enough memory, Z_STREAM_ERROR if the source stream state was inconsistent - (such as zalloc being NULL). msg is left unchanged in both source and - destination. -*/ - -ZEXTERN int ZEXPORT inflateReset OF((z_streamp strm)); -/* - This function is equivalent to inflateEnd followed by inflateInit, - but does not free and reallocate all the internal decompression state. - The stream will keep attributes that may have been set by inflateInit2. - - inflateReset returns Z_OK if success, or Z_STREAM_ERROR if the source - stream state was inconsistent (such as zalloc or state being NULL). -*/ - -ZEXTERN int ZEXPORT inflatePrime OF((z_streamp strm, - int bits, - int value)); -/* - This function inserts bits in the inflate input stream. The intent is - that this function is used to start inflating at a bit position in the - middle of a byte. The provided bits will be used before any bytes are used - from next_in. This function should only be used with raw inflate, and - should be used before the first inflate() call after inflateInit2() or - inflateReset(). bits must be less than or equal to 16, and that many of the - least significant bits of value will be inserted in the input. - - inflatePrime returns Z_OK if success, or Z_STREAM_ERROR if the source - stream state was inconsistent. -*/ - -ZEXTERN int ZEXPORT inflateGetHeader OF((z_streamp strm, - gz_headerp head)); -/* - inflateGetHeader() requests that gzip header information be stored in the - provided gz_header structure. inflateGetHeader() may be called after - inflateInit2() or inflateReset(), and before the first call of inflate(). - As inflate() processes the gzip stream, head->done is zero until the header - is completed, at which time head->done is set to one. If a zlib stream is - being decoded, then head->done is set to -1 to indicate that there will be - no gzip header information forthcoming. Note that Z_BLOCK can be used to - force inflate() to return immediately after header processing is complete - and before any actual data is decompressed. - - The text, time, xflags, and os fields are filled in with the gzip header - contents. hcrc is set to true if there is a header CRC. (The header CRC - was valid if done is set to one.) If extra is not Z_NULL, then extra_max - contains the maximum number of bytes to write to extra. Once done is true, - extra_len contains the actual extra field length, and extra contains the - extra field, or that field truncated if extra_max is less than extra_len. - If name is not Z_NULL, then up to name_max characters are written there, - terminated with a zero unless the length is greater than name_max. If - comment is not Z_NULL, then up to comm_max characters are written there, - terminated with a zero unless the length is greater than comm_max. When - any of extra, name, or comment are not Z_NULL and the respective field is - not present in the header, then that field is set to Z_NULL to signal its - absence. This allows the use of deflateSetHeader() with the returned - structure to duplicate the header. However if those fields are set to - allocated memory, then the application will need to save those pointers - elsewhere so that they can be eventually freed. - - If inflateGetHeader is not used, then the header information is simply - discarded. The header is always checked for validity, including the header - CRC if present. inflateReset() will reset the process to discard the header - information. The application would need to call inflateGetHeader() again to - retrieve the header from the next gzip stream. - - inflateGetHeader returns Z_OK if success, or Z_STREAM_ERROR if the source - stream state was inconsistent. -*/ - -/* -ZEXTERN int ZEXPORT inflateBackInit OF((z_streamp strm, int windowBits, - unsigned char FAR *window)); - - Initialize the internal stream state for decompression using inflateBack() - calls. The fields zalloc, zfree and opaque in strm must be initialized - before the call. If zalloc and zfree are Z_NULL, then the default library- - derived memory allocation routines are used. windowBits is the base two - logarithm of the window size, in the range 8..15. window is a caller - supplied buffer of that size. Except for special applications where it is - assured that deflate was used with small window sizes, windowBits must be 15 - and a 32K byte window must be supplied to be able to decompress general - deflate streams. - - See inflateBack() for the usage of these routines. - - inflateBackInit will return Z_OK on success, Z_STREAM_ERROR if any of - the paramaters are invalid, Z_MEM_ERROR if the internal state could not - be allocated, or Z_VERSION_ERROR if the version of the library does not - match the version of the header file. -*/ - -typedef unsigned (*in_func) OF((void FAR *, unsigned char FAR * FAR *)); -typedef int (*out_func) OF((void FAR *, unsigned char FAR *, unsigned)); - -ZEXTERN int ZEXPORT inflateBack OF((z_streamp strm, - in_func in, void FAR *in_desc, - out_func out, void FAR *out_desc)); -/* - inflateBack() does a raw inflate with a single call using a call-back - interface for input and output. This is more efficient than inflate() for - file i/o applications in that it avoids copying between the output and the - sliding window by simply making the window itself the output buffer. This - function trusts the application to not change the output buffer passed by - the output function, at least until inflateBack() returns. - - inflateBackInit() must be called first to allocate the internal state - and to initialize the state with the user-provided window buffer. - inflateBack() may then be used multiple times to inflate a complete, raw - deflate stream with each call. inflateBackEnd() is then called to free - the allocated state. - - A raw deflate stream is one with no zlib or gzip header or trailer. - This routine would normally be used in a utility that reads zip or gzip - files and writes out uncompressed files. The utility would decode the - header and process the trailer on its own, hence this routine expects - only the raw deflate stream to decompress. This is different from the - normal behavior of inflate(), which expects either a zlib or gzip header and - trailer around the deflate stream. - - inflateBack() uses two subroutines supplied by the caller that are then - called by inflateBack() for input and output. inflateBack() calls those - routines until it reads a complete deflate stream and writes out all of the - uncompressed data, or until it encounters an error. The function's - parameters and return types are defined above in the in_func and out_func - typedefs. inflateBack() will call in(in_desc, &buf) which should return the - number of bytes of provided input, and a pointer to that input in buf. If - there is no input available, in() must return zero--buf is ignored in that - case--and inflateBack() will return a buffer error. inflateBack() will call - out(out_desc, buf, len) to write the uncompressed data buf[0..len-1]. out() - should return zero on success, or non-zero on failure. If out() returns - non-zero, inflateBack() will return with an error. Neither in() nor out() - are permitted to change the contents of the window provided to - inflateBackInit(), which is also the buffer that out() uses to write from. - The length written by out() will be at most the window size. Any non-zero - amount of input may be provided by in(). - - For convenience, inflateBack() can be provided input on the first call by - setting strm->next_in and strm->avail_in. If that input is exhausted, then - in() will be called. Therefore strm->next_in must be initialized before - calling inflateBack(). If strm->next_in is Z_NULL, then in() will be called - immediately for input. If strm->next_in is not Z_NULL, then strm->avail_in - must also be initialized, and then if strm->avail_in is not zero, input will - initially be taken from strm->next_in[0 .. strm->avail_in - 1]. - - The in_desc and out_desc parameters of inflateBack() is passed as the - first parameter of in() and out() respectively when they are called. These - descriptors can be optionally used to pass any information that the caller- - supplied in() and out() functions need to do their job. - - On return, inflateBack() will set strm->next_in and strm->avail_in to - pass back any unused input that was provided by the last in() call. The - return values of inflateBack() can be Z_STREAM_END on success, Z_BUF_ERROR - if in() or out() returned an error, Z_DATA_ERROR if there was a format - error in the deflate stream (in which case strm->msg is set to indicate the - nature of the error), or Z_STREAM_ERROR if the stream was not properly - initialized. In the case of Z_BUF_ERROR, an input or output error can be - distinguished using strm->next_in which will be Z_NULL only if in() returned - an error. If strm->next is not Z_NULL, then the Z_BUF_ERROR was due to - out() returning non-zero. (in() will always be called before out(), so - strm->next_in is assured to be defined if out() returns non-zero.) Note - that inflateBack() cannot return Z_OK. -*/ - -ZEXTERN int ZEXPORT inflateBackEnd OF((z_streamp strm)); -/* - All memory allocated by inflateBackInit() is freed. - - inflateBackEnd() returns Z_OK on success, or Z_STREAM_ERROR if the stream - state was inconsistent. -*/ - -ZEXTERN uLong ZEXPORT zlibCompileFlags OF((void)); -/* Return flags indicating compile-time options. - - Type sizes, two bits each, 00 = 16 bits, 01 = 32, 10 = 64, 11 = other: - 1.0: size of uInt - 3.2: size of uLong - 5.4: size of voidpf (pointer) - 7.6: size of z_off_t - - Compiler, assembler, and debug options: - 8: DEBUG - 9: ASMV or ASMINF -- use ASM code - 10: ZLIB_WINAPI -- exported functions use the WINAPI calling convention - 11: 0 (reserved) - - One-time table building (smaller code, but not thread-safe if true): - 12: BUILDFIXED -- build static block decoding tables when needed - 13: DYNAMIC_CRC_TABLE -- build CRC calculation tables when needed - 14,15: 0 (reserved) - - Library content (indicates missing functionality): - 16: NO_GZCOMPRESS -- gz* functions cannot compress (to avoid linking - deflate code when not needed) - 17: NO_GZIP -- deflate can't write gzip streams, and inflate can't detect - and decode gzip streams (to avoid linking crc code) - 18-19: 0 (reserved) - - Operation variations (changes in library functionality): - 20: PKZIP_BUG_WORKAROUND -- slightly more permissive inflate - 21: FASTEST -- deflate algorithm with only one, lowest compression level - 22,23: 0 (reserved) - - The sprintf variant used by gzprintf (zero is best): - 24: 0 = vs*, 1 = s* -- 1 means limited to 20 arguments after the format - 25: 0 = *nprintf, 1 = *printf -- 1 means gzprintf() not secure! - 26: 0 = returns value, 1 = void -- 1 means inferred string length returned - - Remainder: - 27-31: 0 (reserved) - */ - - - /* utility functions */ - -/* - The following utility functions are implemented on top of the - basic stream-oriented functions. To simplify the interface, some - default options are assumed (compression level and memory usage, - standard memory allocation functions). The source code of these - utility functions can easily be modified if you need special options. -*/ - -ZEXTERN int ZEXPORT compress OF((Bytef *dest, uLongf *destLen, - const Bytef *source, uLong sourceLen)); -/* - Compresses the source buffer into the destination buffer. sourceLen is - the byte length of the source buffer. Upon entry, destLen is the total - size of the destination buffer, which must be at least the value returned - by compressBound(sourceLen). Upon exit, destLen is the actual size of the - compressed buffer. - This function can be used to compress a whole file at once if the - input file is mmap'ed. - compress returns Z_OK if success, Z_MEM_ERROR if there was not - enough memory, Z_BUF_ERROR if there was not enough room in the output - buffer. -*/ - -ZEXTERN int ZEXPORT compress2 OF((Bytef *dest, uLongf *destLen, - const Bytef *source, uLong sourceLen, - int level)); -/* - Compresses the source buffer into the destination buffer. The level - parameter has the same meaning as in deflateInit. sourceLen is the byte - length of the source buffer. Upon entry, destLen is the total size of the - destination buffer, which must be at least the value returned by - compressBound(sourceLen). Upon exit, destLen is the actual size of the - compressed buffer. - - compress2 returns Z_OK if success, Z_MEM_ERROR if there was not enough - memory, Z_BUF_ERROR if there was not enough room in the output buffer, - Z_STREAM_ERROR if the level parameter is invalid. -*/ - -ZEXTERN uLong ZEXPORT compressBound OF((uLong sourceLen)); -/* - compressBound() returns an upper bound on the compressed size after - compress() or compress2() on sourceLen bytes. It would be used before - a compress() or compress2() call to allocate the destination buffer. -*/ - -ZEXTERN int ZEXPORT uncompress OF((Bytef *dest, uLongf *destLen, - const Bytef *source, uLong sourceLen)); -/* - Decompresses the source buffer into the destination buffer. sourceLen is - the byte length of the source buffer. Upon entry, destLen is the total - size of the destination buffer, which must be large enough to hold the - entire uncompressed data. (The size of the uncompressed data must have - been saved previously by the compressor and transmitted to the decompressor - by some mechanism outside the scope of this compression library.) - Upon exit, destLen is the actual size of the compressed buffer. - This function can be used to decompress a whole file at once if the - input file is mmap'ed. - - uncompress returns Z_OK if success, Z_MEM_ERROR if there was not - enough memory, Z_BUF_ERROR if there was not enough room in the output - buffer, or Z_DATA_ERROR if the input data was corrupted or incomplete. -*/ - - -typedef voidp gzFile; - -ZEXTERN gzFile ZEXPORT gzopen OF((const char *path, const char *mode)); -/* - Opens a gzip (.gz) file for reading or writing. The mode parameter - is as in fopen ("rb" or "wb") but can also include a compression level - ("wb9") or a strategy: 'f' for filtered data as in "wb6f", 'h' for - Huffman only compression as in "wb1h", or 'R' for run-length encoding - as in "wb1R". (See the description of deflateInit2 for more information - about the strategy parameter.) - - gzopen can be used to read a file which is not in gzip format; in this - case gzread will directly read from the file without decompression. - - gzopen returns NULL if the file could not be opened or if there was - insufficient memory to allocate the (de)compression state; errno - can be checked to distinguish the two cases (if errno is zero, the - zlib error is Z_MEM_ERROR). */ - -ZEXTERN gzFile ZEXPORT gzdopen OF((int fd, const char *mode)); -/* - gzdopen() associates a gzFile with the file descriptor fd. File - descriptors are obtained from calls like open, dup, creat, pipe or - fileno (in the file has been previously opened with fopen). - The mode parameter is as in gzopen. - The next call of gzclose on the returned gzFile will also close the - file descriptor fd, just like fclose(fdopen(fd), mode) closes the file - descriptor fd. If you want to keep fd open, use gzdopen(dup(fd), mode). - gzdopen returns NULL if there was insufficient memory to allocate - the (de)compression state. -*/ - -ZEXTERN int ZEXPORT gzsetparams OF((gzFile file, int level, int strategy)); -/* - Dynamically update the compression level or strategy. See the description - of deflateInit2 for the meaning of these parameters. - gzsetparams returns Z_OK if success, or Z_STREAM_ERROR if the file was not - opened for writing. -*/ - -ZEXTERN int ZEXPORT gzread OF((gzFile file, voidp buf, unsigned len)); -/* - Reads the given number of uncompressed bytes from the compressed file. - If the input file was not in gzip format, gzread copies the given number - of bytes into the buffer. - gzread returns the number of uncompressed bytes actually read (0 for - end of file, -1 for error). */ - -ZEXTERN int ZEXPORT gzwrite OF((gzFile file, - voidpc buf, unsigned len)); -/* - Writes the given number of uncompressed bytes into the compressed file. - gzwrite returns the number of uncompressed bytes actually written - (0 in case of error). -*/ - -ZEXTERN int ZEXPORTVA gzprintf OF((gzFile file, const char *format, ...)); -/* - Converts, formats, and writes the args to the compressed file under - control of the format string, as in fprintf. gzprintf returns the number of - uncompressed bytes actually written (0 in case of error). The number of - uncompressed bytes written is limited to 4095. The caller should assure that - this limit is not exceeded. If it is exceeded, then gzprintf() will return - return an error (0) with nothing written. In this case, there may also be a - buffer overflow with unpredictable consequences, which is possible only if - zlib was compiled with the insecure functions sprintf() or vsprintf() - because the secure snprintf() or vsnprintf() functions were not available. -*/ - -ZEXTERN int ZEXPORT gzputs OF((gzFile file, const char *s)); -/* - Writes the given null-terminated string to the compressed file, excluding - the terminating null character. - gzputs returns the number of characters written, or -1 in case of error. -*/ - -ZEXTERN char * ZEXPORT gzgets OF((gzFile file, char *buf, int len)); -/* - Reads bytes from the compressed file until len-1 characters are read, or - a newline character is read and transferred to buf, or an end-of-file - condition is encountered. The string is then terminated with a null - character. - gzgets returns buf, or Z_NULL in case of error. -*/ - -ZEXTERN int ZEXPORT gzputc OF((gzFile file, int c)); -/* - Writes c, converted to an unsigned char, into the compressed file. - gzputc returns the value that was written, or -1 in case of error. -*/ - -ZEXTERN int ZEXPORT gzgetc OF((gzFile file)); -/* - Reads one byte from the compressed file. gzgetc returns this byte - or -1 in case of end of file or error. -*/ - -ZEXTERN int ZEXPORT gzungetc OF((int c, gzFile file)); -/* - Push one character back onto the stream to be read again later. - Only one character of push-back is allowed. gzungetc() returns the - character pushed, or -1 on failure. gzungetc() will fail if a - character has been pushed but not read yet, or if c is -1. The pushed - character will be discarded if the stream is repositioned with gzseek() - or gzrewind(). -*/ - -ZEXTERN int ZEXPORT gzflush OF((gzFile file, int flush)); -/* - Flushes all pending output into the compressed file. The parameter - flush is as in the deflate() function. The return value is the zlib - error number (see function gzerror below). gzflush returns Z_OK if - the flush parameter is Z_FINISH and all output could be flushed. - gzflush should be called only when strictly necessary because it can - degrade compression. -*/ - -ZEXTERN z_off_t ZEXPORT gzseek OF((gzFile file, - z_off_t offset, int whence)); -/* - Sets the starting position for the next gzread or gzwrite on the - given compressed file. The offset represents a number of bytes in the - uncompressed data stream. The whence parameter is defined as in lseek(2); - the value SEEK_END is not supported. - If the file is opened for reading, this function is emulated but can be - extremely slow. If the file is opened for writing, only forward seeks are - supported; gzseek then compresses a sequence of zeroes up to the new - starting position. - - gzseek returns the resulting offset location as measured in bytes from - the beginning of the uncompressed stream, or -1 in case of error, in - particular if the file is opened for writing and the new starting position - would be before the current position. -*/ - -ZEXTERN int ZEXPORT gzrewind OF((gzFile file)); -/* - Rewinds the given file. This function is supported only for reading. - - gzrewind(file) is equivalent to (int)gzseek(file, 0L, SEEK_SET) -*/ - -ZEXTERN z_off_t ZEXPORT gztell OF((gzFile file)); -/* - Returns the starting position for the next gzread or gzwrite on the - given compressed file. This position represents a number of bytes in the - uncompressed data stream. - - gztell(file) is equivalent to gzseek(file, 0L, SEEK_CUR) -*/ - -ZEXTERN int ZEXPORT gzeof OF((gzFile file)); -/* - Returns 1 when EOF has previously been detected reading the given - input stream, otherwise zero. -*/ - -ZEXTERN int ZEXPORT gzdirect OF((gzFile file)); -/* - Returns 1 if file is being read directly without decompression, otherwise - zero. -*/ - -ZEXTERN int ZEXPORT gzclose OF((gzFile file)); -/* - Flushes all pending output if necessary, closes the compressed file - and deallocates all the (de)compression state. The return value is the zlib - error number (see function gzerror below). -*/ - -ZEXTERN const char * ZEXPORT gzerror OF((gzFile file, int *errnum)); -/* - Returns the error message for the last error which occurred on the - given compressed file. errnum is set to zlib error number. If an - error occurred in the file system and not in the compression library, - errnum is set to Z_ERRNO and the application may consult errno - to get the exact error code. -*/ - -ZEXTERN void ZEXPORT gzclearerr OF((gzFile file)); -/* - Clears the error and end-of-file flags for file. This is analogous to the - clearerr() function in stdio. This is useful for continuing to read a gzip - file that is being written concurrently. -*/ - - /* checksum functions */ - -/* - These functions are not related to compression but are exported - anyway because they might be useful in applications using the - compression library. -*/ - -ZEXTERN uLong ZEXPORT adler32 OF((uLong adler, const Bytef *buf, uInt len)); -/* - Update a running Adler-32 checksum with the bytes buf[0..len-1] and - return the updated checksum. If buf is NULL, this function returns - the required initial value for the checksum. - An Adler-32 checksum is almost as reliable as a CRC32 but can be computed - much faster. Usage example: - - uLong adler = adler32(0L, Z_NULL, 0); - - while (read_buffer(buffer, length) != EOF) { - adler = adler32(adler, buffer, length); - } - if (adler != original_adler) error(); -*/ - -ZEXTERN uLong ZEXPORT adler32_combine OF((uLong adler1, uLong adler2, - z_off_t len2)); -/* - Combine two Adler-32 checksums into one. For two sequences of bytes, seq1 - and seq2 with lengths len1 and len2, Adler-32 checksums were calculated for - each, adler1 and adler2. adler32_combine() returns the Adler-32 checksum of - seq1 and seq2 concatenated, requiring only adler1, adler2, and len2. -*/ - -ZEXTERN uLong ZEXPORT crc32 OF((uLong crc, const Bytef *buf, uInt len)); -/* - Update a running CRC-32 with the bytes buf[0..len-1] and return the - updated CRC-32. If buf is NULL, this function returns the required initial - value for the for the crc. Pre- and post-conditioning (one's complement) is - performed within this function so it shouldn't be done by the application. - Usage example: - - uLong crc = crc32(0L, Z_NULL, 0); - - while (read_buffer(buffer, length) != EOF) { - crc = crc32(crc, buffer, length); - } - if (crc != original_crc) error(); -*/ - -ZEXTERN uLong ZEXPORT crc32_combine OF((uLong crc1, uLong crc2, z_off_t len2)); - -/* - Combine two CRC-32 check values into one. For two sequences of bytes, - seq1 and seq2 with lengths len1 and len2, CRC-32 check values were - calculated for each, crc1 and crc2. crc32_combine() returns the CRC-32 - check value of seq1 and seq2 concatenated, requiring only crc1, crc2, and - len2. -*/ - - - /* various hacks, don't look :) */ - -/* deflateInit and inflateInit are macros to allow checking the zlib version - * and the compiler's view of z_stream: - */ -ZEXTERN int ZEXPORT deflateInit_ OF((z_streamp strm, int level, - const char *version, int stream_size)); -ZEXTERN int ZEXPORT inflateInit_ OF((z_streamp strm, - const char *version, int stream_size)); -ZEXTERN int ZEXPORT deflateInit2_ OF((z_streamp strm, int level, int method, - int windowBits, int memLevel, - int strategy, const char *version, - int stream_size)); -ZEXTERN int ZEXPORT inflateInit2_ OF((z_streamp strm, int windowBits, - const char *version, int stream_size)); -ZEXTERN int ZEXPORT inflateBackInit_ OF((z_streamp strm, int windowBits, - unsigned char FAR *window, - const char *version, - int stream_size)); -#define deflateInit(strm, level) \ - deflateInit_((strm), (level), ZLIB_VERSION, sizeof(z_stream)) -#define inflateInit(strm) \ - inflateInit_((strm), ZLIB_VERSION, sizeof(z_stream)) -#define deflateInit2(strm, level, method, windowBits, memLevel, strategy) \ - deflateInit2_((strm),(level),(method),(windowBits),(memLevel),\ - (strategy), ZLIB_VERSION, sizeof(z_stream)) -#define inflateInit2(strm, windowBits) \ - inflateInit2_((strm), (windowBits), ZLIB_VERSION, sizeof(z_stream)) -#define inflateBackInit(strm, windowBits, window) \ - inflateBackInit_((strm), (windowBits), (window), \ - ZLIB_VERSION, sizeof(z_stream)) - - -#if !defined(ZUTIL_H) && !defined(NO_DUMMY_DECL) - struct internal_state {int dummy;}; /* hack for buggy compilers */ -#endif - -ZEXTERN const char * ZEXPORT zError OF((int)); -ZEXTERN int ZEXPORT inflateSyncPoint OF((z_streamp z)); -ZEXTERN const uLongf * ZEXPORT get_crc_table OF((void)); - -#ifdef __cplusplus -} -#endif - -#endif /* ZLIB_H */ +/* zlib.h -- interface of the 'zlib' general purpose compression library + version 1.2.3, July 18th, 2005 + + Copyright (C) 1995-2005 Jean-loup Gailly and Mark Adler + + This software is provided 'as-is', without any express or implied + warranty. In no event will the authors be held liable for any damages + arising from the use of this software. + + Permission is granted to anyone to use this software for any purpose, + including commercial applications, and to alter it and redistribute it + freely, subject to the following restrictions: + + 1. The origin of this software must not be misrepresented; you must not + claim that you wrote the original software. If you use this software + in a product, an acknowledgment in the product documentation would be + appreciated but is not required. + 2. Altered source versions must be plainly marked as such, and must not be + misrepresented as being the original software. + 3. This notice may not be removed or altered from any source distribution. + + Jean-loup Gailly Mark Adler + jloup@gzip.org madler@alumni.caltech.edu + + + The data format used by the zlib library is described by RFCs (Request for + Comments) 1950 to 1952 in the files http://www.ietf.org/rfc/rfc1950.txt + (zlib format), rfc1951.txt (deflate format) and rfc1952.txt (gzip format). +*/ + +#ifndef ZLIB_H +#define ZLIB_H + +#include "zconf.h" + +#ifdef __cplusplus +extern "C" { +#endif + +#define ZLIB_VERSION "1.2.3" +#define ZLIB_VERNUM 0x1230 + +/* + The 'zlib' compression library provides in-memory compression and + decompression functions, including integrity checks of the uncompressed + data. This version of the library supports only one compression method + (deflation) but other algorithms will be added later and will have the same + stream interface. + + Compression can be done in a single step if the buffers are large + enough (for example if an input file is mmap'ed), or can be done by + repeated calls of the compression function. In the latter case, the + application must provide more input and/or consume the output + (providing more output space) before each call. + + The compressed data format used by default by the in-memory functions is + the zlib format, which is a zlib wrapper documented in RFC 1950, wrapped + around a deflate stream, which is itself documented in RFC 1951. + + The library also supports reading and writing files in gzip (.gz) format + with an interface similar to that of stdio using the functions that start + with "gz". The gzip format is different from the zlib format. gzip is a + gzip wrapper, documented in RFC 1952, wrapped around a deflate stream. + + This library can optionally read and write gzip streams in memory as well. + + The zlib format was designed to be compact and fast for use in memory + and on communications channels. The gzip format was designed for single- + file compression on file systems, has a larger header than zlib to maintain + directory information, and uses a different, slower check method than zlib. + + The library does not install any signal handler. The decoder checks + the consistency of the compressed data, so the library should never + crash even in case of corrupted input. +*/ + +typedef voidpf (*alloc_func) OF((voidpf opaque, uInt items, uInt size)); +typedef void (*free_func) OF((voidpf opaque, voidpf address)); + +struct internal_state; + +typedef struct z_stream_s { + Bytef *next_in; /* next input byte */ + uInt avail_in; /* number of bytes available at next_in */ + uLong total_in; /* total nb of input bytes read so far */ + + Bytef *next_out; /* next output byte should be put there */ + uInt avail_out; /* remaining free space at next_out */ + uLong total_out; /* total nb of bytes output so far */ + + char *msg; /* last error message, NULL if no error */ + struct internal_state FAR *state; /* not visible by applications */ + + alloc_func zalloc; /* used to allocate the internal state */ + free_func zfree; /* used to free the internal state */ + voidpf opaque; /* private data object passed to zalloc and zfree */ + + int data_type; /* best guess about the data type: binary or text */ + uLong adler; /* adler32 value of the uncompressed data */ + uLong reserved; /* reserved for future use */ +} z_stream; + +typedef z_stream FAR *z_streamp; + +/* + gzip header information passed to and from zlib routines. See RFC 1952 + for more details on the meanings of these fields. +*/ +typedef struct gz_header_s { + int text; /* true if compressed data believed to be text */ + uLong time; /* modification time */ + int xflags; /* extra flags (not used when writing a gzip file) */ + int os; /* operating system */ + Bytef *extra; /* pointer to extra field or Z_NULL if none */ + uInt extra_len; /* extra field length (valid if extra != Z_NULL) */ + uInt extra_max; /* space at extra (only when reading header) */ + Bytef *name; /* pointer to zero-terminated file name or Z_NULL */ + uInt name_max; /* space at name (only when reading header) */ + Bytef *comment; /* pointer to zero-terminated comment or Z_NULL */ + uInt comm_max; /* space at comment (only when reading header) */ + int hcrc; /* true if there was or will be a header crc */ + int done; /* true when done reading gzip header (not used + when writing a gzip file) */ +} gz_header; + +typedef gz_header FAR *gz_headerp; + +/* + The application must update next_in and avail_in when avail_in has + dropped to zero. It must update next_out and avail_out when avail_out + has dropped to zero. The application must initialize zalloc, zfree and + opaque before calling the init function. All other fields are set by the + compression library and must not be updated by the application. + + The opaque value provided by the application will be passed as the first + parameter for calls of zalloc and zfree. This can be useful for custom + memory management. The compression library attaches no meaning to the + opaque value. + + zalloc must return Z_NULL if there is not enough memory for the object. + If zlib is used in a multi-threaded application, zalloc and zfree must be + thread safe. + + On 16-bit systems, the functions zalloc and zfree must be able to allocate + exactly 65536 bytes, but will not be required to allocate more than this + if the symbol MAXSEG_64K is defined (see zconf.h). WARNING: On MSDOS, + pointers returned by zalloc for objects of exactly 65536 bytes *must* + have their offset normalized to zero. The default allocation function + provided by this library ensures this (see zutil.c). To reduce memory + requirements and avoid any allocation of 64K objects, at the expense of + compression ratio, compile the library with -DMAX_WBITS=14 (see zconf.h). + + The fields total_in and total_out can be used for statistics or + progress reports. After compression, total_in holds the total size of + the uncompressed data and may be saved for use in the decompressor + (particularly if the decompressor wants to decompress everything in + a single step). +*/ + + /* constants */ + +#define Z_NO_FLUSH 0 +#define Z_PARTIAL_FLUSH 1 /* will be removed, use Z_SYNC_FLUSH instead */ +#define Z_SYNC_FLUSH 2 +#define Z_FULL_FLUSH 3 +#define Z_FINISH 4 +#define Z_BLOCK 5 +/* Allowed flush values; see deflate() and inflate() below for details */ + +#define Z_OK 0 +#define Z_STREAM_END 1 +#define Z_NEED_DICT 2 +#define Z_ERRNO (-1) +#define Z_STREAM_ERROR (-2) +#define Z_DATA_ERROR (-3) +#define Z_MEM_ERROR (-4) +#define Z_BUF_ERROR (-5) +#define Z_VERSION_ERROR (-6) +/* Return codes for the compression/decompression functions. Negative + * values are errors, positive values are used for special but normal events. + */ + +#define Z_NO_COMPRESSION 0 +#define Z_BEST_SPEED 1 +#define Z_BEST_COMPRESSION 9 +#define Z_DEFAULT_COMPRESSION (-1) +/* compression levels */ + +#define Z_FILTERED 1 +#define Z_HUFFMAN_ONLY 2 +#define Z_RLE 3 +#define Z_FIXED 4 +#define Z_DEFAULT_STRATEGY 0 +/* compression strategy; see deflateInit2() below for details */ + +#define Z_BINARY 0 +#define Z_TEXT 1 +#define Z_ASCII Z_TEXT /* for compatibility with 1.2.2 and earlier */ +#define Z_UNKNOWN 2 +/* Possible values of the data_type field (though see inflate()) */ + +#define Z_DEFLATED 8 +/* The deflate compression method (the only one supported in this version) */ + +#define Z_NULL 0 /* for initializing zalloc, zfree, opaque */ + +#define zlib_version zlibVersion() +/* for compatibility with versions < 1.0.2 */ + + /* basic functions */ + +ZEXTERN const char * ZEXPORT zlibVersion OF((void)); +/* The application can compare zlibVersion and ZLIB_VERSION for consistency. + If the first character differs, the library code actually used is + not compatible with the zlib.h header file used by the application. + This check is automatically made by deflateInit and inflateInit. + */ + +/* +ZEXTERN int ZEXPORT deflateInit OF((z_streamp strm, int level)); + + Initializes the internal stream state for compression. The fields + zalloc, zfree and opaque must be initialized before by the caller. + If zalloc and zfree are set to Z_NULL, deflateInit updates them to + use default allocation functions. + + The compression level must be Z_DEFAULT_COMPRESSION, or between 0 and 9: + 1 gives best speed, 9 gives best compression, 0 gives no compression at + all (the input data is simply copied a block at a time). + Z_DEFAULT_COMPRESSION requests a default compromise between speed and + compression (currently equivalent to level 6). + + deflateInit returns Z_OK if success, Z_MEM_ERROR if there was not + enough memory, Z_STREAM_ERROR if level is not a valid compression level, + Z_VERSION_ERROR if the zlib library version (zlib_version) is incompatible + with the version assumed by the caller (ZLIB_VERSION). + msg is set to null if there is no error message. deflateInit does not + perform any compression: this will be done by deflate(). +*/ + + +ZEXTERN int ZEXPORT deflate OF((z_streamp strm, int flush)); +/* + deflate compresses as much data as possible, and stops when the input + buffer becomes empty or the output buffer becomes full. It may introduce some + output latency (reading input without producing any output) except when + forced to flush. + + The detailed semantics are as follows. deflate performs one or both of the + following actions: + + - Compress more input starting at next_in and update next_in and avail_in + accordingly. If not all input can be processed (because there is not + enough room in the output buffer), next_in and avail_in are updated and + processing will resume at this point for the next call of deflate(). + + - Provide more output starting at next_out and update next_out and avail_out + accordingly. This action is forced if the parameter flush is non zero. + Forcing flush frequently degrades the compression ratio, so this parameter + should be set only when necessary (in interactive applications). + Some output may be provided even if flush is not set. + + Before the call of deflate(), the application should ensure that at least + one of the actions is possible, by providing more input and/or consuming + more output, and updating avail_in or avail_out accordingly; avail_out + should never be zero before the call. The application can consume the + compressed output when it wants, for example when the output buffer is full + (avail_out == 0), or after each call of deflate(). If deflate returns Z_OK + and with zero avail_out, it must be called again after making room in the + output buffer because there might be more output pending. + + Normally the parameter flush is set to Z_NO_FLUSH, which allows deflate to + decide how much data to accumualte before producing output, in order to + maximize compression. + + If the parameter flush is set to Z_SYNC_FLUSH, all pending output is + flushed to the output buffer and the output is aligned on a byte boundary, so + that the decompressor can get all input data available so far. (In particular + avail_in is zero after the call if enough output space has been provided + before the call.) Flushing may degrade compression for some compression + algorithms and so it should be used only when necessary. + + If flush is set to Z_FULL_FLUSH, all output is flushed as with + Z_SYNC_FLUSH, and the compression state is reset so that decompression can + restart from this point if previous compressed data has been damaged or if + random access is desired. Using Z_FULL_FLUSH too often can seriously degrade + compression. + + If deflate returns with avail_out == 0, this function must be called again + with the same value of the flush parameter and more output space (updated + avail_out), until the flush is complete (deflate returns with non-zero + avail_out). In the case of a Z_FULL_FLUSH or Z_SYNC_FLUSH, make sure that + avail_out is greater than six to avoid repeated flush markers due to + avail_out == 0 on return. + + If the parameter flush is set to Z_FINISH, pending input is processed, + pending output is flushed and deflate returns with Z_STREAM_END if there + was enough output space; if deflate returns with Z_OK, this function must be + called again with Z_FINISH and more output space (updated avail_out) but no + more input data, until it returns with Z_STREAM_END or an error. After + deflate has returned Z_STREAM_END, the only possible operations on the + stream are deflateReset or deflateEnd. + + Z_FINISH can be used immediately after deflateInit if all the compression + is to be done in a single step. In this case, avail_out must be at least + the value returned by deflateBound (see below). If deflate does not return + Z_STREAM_END, then it must be called again as described above. + + deflate() sets strm->adler to the adler32 checksum of all input read + so far (that is, total_in bytes). + + deflate() may update strm->data_type if it can make a good guess about + the input data type (Z_BINARY or Z_TEXT). In doubt, the data is considered + binary. This field is only for information purposes and does not affect + the compression algorithm in any manner. + + deflate() returns Z_OK if some progress has been made (more input + processed or more output produced), Z_STREAM_END if all input has been + consumed and all output has been produced (only when flush is set to + Z_FINISH), Z_STREAM_ERROR if the stream state was inconsistent (for example + if next_in or next_out was NULL), Z_BUF_ERROR if no progress is possible + (for example avail_in or avail_out was zero). Note that Z_BUF_ERROR is not + fatal, and deflate() can be called again with more input and more output + space to continue compressing. +*/ + + +ZEXTERN int ZEXPORT deflateEnd OF((z_streamp strm)); +/* + All dynamically allocated data structures for this stream are freed. + This function discards any unprocessed input and does not flush any + pending output. + + deflateEnd returns Z_OK if success, Z_STREAM_ERROR if the + stream state was inconsistent, Z_DATA_ERROR if the stream was freed + prematurely (some input or output was discarded). In the error case, + msg may be set but then points to a static string (which must not be + deallocated). +*/ + + +/* +ZEXTERN int ZEXPORT inflateInit OF((z_streamp strm)); + + Initializes the internal stream state for decompression. The fields + next_in, avail_in, zalloc, zfree and opaque must be initialized before by + the caller. If next_in is not Z_NULL and avail_in is large enough (the exact + value depends on the compression method), inflateInit determines the + compression method from the zlib header and allocates all data structures + accordingly; otherwise the allocation will be deferred to the first call of + inflate. If zalloc and zfree are set to Z_NULL, inflateInit updates them to + use default allocation functions. + + inflateInit returns Z_OK if success, Z_MEM_ERROR if there was not enough + memory, Z_VERSION_ERROR if the zlib library version is incompatible with the + version assumed by the caller. msg is set to null if there is no error + message. inflateInit does not perform any decompression apart from reading + the zlib header if present: this will be done by inflate(). (So next_in and + avail_in may be modified, but next_out and avail_out are unchanged.) +*/ + + +ZEXTERN int ZEXPORT inflate OF((z_streamp strm, int flush)); +/* + inflate decompresses as much data as possible, and stops when the input + buffer becomes empty or the output buffer becomes full. It may introduce + some output latency (reading input without producing any output) except when + forced to flush. + + The detailed semantics are as follows. inflate performs one or both of the + following actions: + + - Decompress more input starting at next_in and update next_in and avail_in + accordingly. If not all input can be processed (because there is not + enough room in the output buffer), next_in is updated and processing + will resume at this point for the next call of inflate(). + + - Provide more output starting at next_out and update next_out and avail_out + accordingly. inflate() provides as much output as possible, until there + is no more input data or no more space in the output buffer (see below + about the flush parameter). + + Before the call of inflate(), the application should ensure that at least + one of the actions is possible, by providing more input and/or consuming + more output, and updating the next_* and avail_* values accordingly. + The application can consume the uncompressed output when it wants, for + example when the output buffer is full (avail_out == 0), or after each + call of inflate(). If inflate returns Z_OK and with zero avail_out, it + must be called again after making room in the output buffer because there + might be more output pending. + + The flush parameter of inflate() can be Z_NO_FLUSH, Z_SYNC_FLUSH, + Z_FINISH, or Z_BLOCK. Z_SYNC_FLUSH requests that inflate() flush as much + output as possible to the output buffer. Z_BLOCK requests that inflate() stop + if and when it gets to the next deflate block boundary. When decoding the + zlib or gzip format, this will cause inflate() to return immediately after + the header and before the first block. When doing a raw inflate, inflate() + will go ahead and process the first block, and will return when it gets to + the end of that block, or when it runs out of data. + + The Z_BLOCK option assists in appending to or combining deflate streams. + Also to assist in this, on return inflate() will set strm->data_type to the + number of unused bits in the last byte taken from strm->next_in, plus 64 + if inflate() is currently decoding the last block in the deflate stream, + plus 128 if inflate() returned immediately after decoding an end-of-block + code or decoding the complete header up to just before the first byte of the + deflate stream. The end-of-block will not be indicated until all of the + uncompressed data from that block has been written to strm->next_out. The + number of unused bits may in general be greater than seven, except when + bit 7 of data_type is set, in which case the number of unused bits will be + less than eight. + + inflate() should normally be called until it returns Z_STREAM_END or an + error. However if all decompression is to be performed in a single step + (a single call of inflate), the parameter flush should be set to + Z_FINISH. In this case all pending input is processed and all pending + output is flushed; avail_out must be large enough to hold all the + uncompressed data. (The size of the uncompressed data may have been saved + by the compressor for this purpose.) The next operation on this stream must + be inflateEnd to deallocate the decompression state. The use of Z_FINISH + is never required, but can be used to inform inflate that a faster approach + may be used for the single inflate() call. + + In this implementation, inflate() always flushes as much output as + possible to the output buffer, and always uses the faster approach on the + first call. So the only effect of the flush parameter in this implementation + is on the return value of inflate(), as noted below, or when it returns early + because Z_BLOCK is used. + + If a preset dictionary is needed after this call (see inflateSetDictionary + below), inflate sets strm->adler to the adler32 checksum of the dictionary + chosen by the compressor and returns Z_NEED_DICT; otherwise it sets + strm->adler to the adler32 checksum of all output produced so far (that is, + total_out bytes) and returns Z_OK, Z_STREAM_END or an error code as described + below. At the end of the stream, inflate() checks that its computed adler32 + checksum is equal to that saved by the compressor and returns Z_STREAM_END + only if the checksum is correct. + + inflate() will decompress and check either zlib-wrapped or gzip-wrapped + deflate data. The header type is detected automatically. Any information + contained in the gzip header is not retained, so applications that need that + information should instead use raw inflate, see inflateInit2() below, or + inflateBack() and perform their own processing of the gzip header and + trailer. + + inflate() returns Z_OK if some progress has been made (more input processed + or more output produced), Z_STREAM_END if the end of the compressed data has + been reached and all uncompressed output has been produced, Z_NEED_DICT if a + preset dictionary is needed at this point, Z_DATA_ERROR if the input data was + corrupted (input stream not conforming to the zlib format or incorrect check + value), Z_STREAM_ERROR if the stream structure was inconsistent (for example + if next_in or next_out was NULL), Z_MEM_ERROR if there was not enough memory, + Z_BUF_ERROR if no progress is possible or if there was not enough room in the + output buffer when Z_FINISH is used. Note that Z_BUF_ERROR is not fatal, and + inflate() can be called again with more input and more output space to + continue decompressing. If Z_DATA_ERROR is returned, the application may then + call inflateSync() to look for a good compression block if a partial recovery + of the data is desired. +*/ + + +ZEXTERN int ZEXPORT inflateEnd OF((z_streamp strm)); +/* + All dynamically allocated data structures for this stream are freed. + This function discards any unprocessed input and does not flush any + pending output. + + inflateEnd returns Z_OK if success, Z_STREAM_ERROR if the stream state + was inconsistent. In the error case, msg may be set but then points to a + static string (which must not be deallocated). +*/ + + /* Advanced functions */ + +/* + The following functions are needed only in some special applications. +*/ + +/* +ZEXTERN int ZEXPORT deflateInit2 OF((z_streamp strm, + int level, + int method, + int windowBits, + int memLevel, + int strategy)); + + This is another version of deflateInit with more compression options. The + fields next_in, zalloc, zfree and opaque must be initialized before by + the caller. + + The method parameter is the compression method. It must be Z_DEFLATED in + this version of the library. + + The windowBits parameter is the base two logarithm of the window size + (the size of the history buffer). It should be in the range 8..15 for this + version of the library. Larger values of this parameter result in better + compression at the expense of memory usage. The default value is 15 if + deflateInit is used instead. + + windowBits can also be -8..-15 for raw deflate. In this case, -windowBits + determines the window size. deflate() will then generate raw deflate data + with no zlib header or trailer, and will not compute an adler32 check value. + + windowBits can also be greater than 15 for optional gzip encoding. Add + 16 to windowBits to write a simple gzip header and trailer around the + compressed data instead of a zlib wrapper. The gzip header will have no + file name, no extra data, no comment, no modification time (set to zero), + no header crc, and the operating system will be set to 255 (unknown). If a + gzip stream is being written, strm->adler is a crc32 instead of an adler32. + + The memLevel parameter specifies how much memory should be allocated + for the internal compression state. memLevel=1 uses minimum memory but + is slow and reduces compression ratio; memLevel=9 uses maximum memory + for optimal speed. The default value is 8. See zconf.h for total memory + usage as a function of windowBits and memLevel. + + The strategy parameter is used to tune the compression algorithm. Use the + value Z_DEFAULT_STRATEGY for normal data, Z_FILTERED for data produced by a + filter (or predictor), Z_HUFFMAN_ONLY to force Huffman encoding only (no + string match), or Z_RLE to limit match distances to one (run-length + encoding). Filtered data consists mostly of small values with a somewhat + random distribution. In this case, the compression algorithm is tuned to + compress them better. The effect of Z_FILTERED is to force more Huffman + coding and less string matching; it is somewhat intermediate between + Z_DEFAULT and Z_HUFFMAN_ONLY. Z_RLE is designed to be almost as fast as + Z_HUFFMAN_ONLY, but give better compression for PNG image data. The strategy + parameter only affects the compression ratio but not the correctness of the + compressed output even if it is not set appropriately. Z_FIXED prevents the + use of dynamic Huffman codes, allowing for a simpler decoder for special + applications. + + deflateInit2 returns Z_OK if success, Z_MEM_ERROR if there was not enough + memory, Z_STREAM_ERROR if a parameter is invalid (such as an invalid + method). msg is set to null if there is no error message. deflateInit2 does + not perform any compression: this will be done by deflate(). +*/ + +ZEXTERN int ZEXPORT deflateSetDictionary OF((z_streamp strm, + const Bytef *dictionary, + uInt dictLength)); +/* + Initializes the compression dictionary from the given byte sequence + without producing any compressed output. This function must be called + immediately after deflateInit, deflateInit2 or deflateReset, before any + call of deflate. The compressor and decompressor must use exactly the same + dictionary (see inflateSetDictionary). + + The dictionary should consist of strings (byte sequences) that are likely + to be encountered later in the data to be compressed, with the most commonly + used strings preferably put towards the end of the dictionary. Using a + dictionary is most useful when the data to be compressed is short and can be + predicted with good accuracy; the data can then be compressed better than + with the default empty dictionary. + + Depending on the size of the compression data structures selected by + deflateInit or deflateInit2, a part of the dictionary may in effect be + discarded, for example if the dictionary is larger than the window size in + deflate or deflate2. Thus the strings most likely to be useful should be + put at the end of the dictionary, not at the front. In addition, the + current implementation of deflate will use at most the window size minus + 262 bytes of the provided dictionary. + + Upon return of this function, strm->adler is set to the adler32 value + of the dictionary; the decompressor may later use this value to determine + which dictionary has been used by the compressor. (The adler32 value + applies to the whole dictionary even if only a subset of the dictionary is + actually used by the compressor.) If a raw deflate was requested, then the + adler32 value is not computed and strm->adler is not set. + + deflateSetDictionary returns Z_OK if success, or Z_STREAM_ERROR if a + parameter is invalid (such as NULL dictionary) or the stream state is + inconsistent (for example if deflate has already been called for this stream + or if the compression method is bsort). deflateSetDictionary does not + perform any compression: this will be done by deflate(). +*/ + +ZEXTERN int ZEXPORT deflateCopy OF((z_streamp dest, + z_streamp source)); +/* + Sets the destination stream as a complete copy of the source stream. + + This function can be useful when several compression strategies will be + tried, for example when there are several ways of pre-processing the input + data with a filter. The streams that will be discarded should then be freed + by calling deflateEnd. Note that deflateCopy duplicates the internal + compression state which can be quite large, so this strategy is slow and + can consume lots of memory. + + deflateCopy returns Z_OK if success, Z_MEM_ERROR if there was not + enough memory, Z_STREAM_ERROR if the source stream state was inconsistent + (such as zalloc being NULL). msg is left unchanged in both source and + destination. +*/ + +ZEXTERN int ZEXPORT deflateReset OF((z_streamp strm)); +/* + This function is equivalent to deflateEnd followed by deflateInit, + but does not free and reallocate all the internal compression state. + The stream will keep the same compression level and any other attributes + that may have been set by deflateInit2. + + deflateReset returns Z_OK if success, or Z_STREAM_ERROR if the source + stream state was inconsistent (such as zalloc or state being NULL). +*/ + +ZEXTERN int ZEXPORT deflateParams OF((z_streamp strm, + int level, + int strategy)); +/* + Dynamically update the compression level and compression strategy. The + interpretation of level and strategy is as in deflateInit2. This can be + used to switch between compression and straight copy of the input data, or + to switch to a different kind of input data requiring a different + strategy. If the compression level is changed, the input available so far + is compressed with the old level (and may be flushed); the new level will + take effect only at the next call of deflate(). + + Before the call of deflateParams, the stream state must be set as for + a call of deflate(), since the currently available input may have to + be compressed and flushed. In particular, strm->avail_out must be non-zero. + + deflateParams returns Z_OK if success, Z_STREAM_ERROR if the source + stream state was inconsistent or if a parameter was invalid, Z_BUF_ERROR + if strm->avail_out was zero. +*/ + +ZEXTERN int ZEXPORT deflateTune OF((z_streamp strm, + int good_length, + int max_lazy, + int nice_length, + int max_chain)); +/* + Fine tune deflate's internal compression parameters. This should only be + used by someone who understands the algorithm used by zlib's deflate for + searching for the best matching string, and even then only by the most + fanatic optimizer trying to squeeze out the last compressed bit for their + specific input data. Read the deflate.c source code for the meaning of the + max_lazy, good_length, nice_length, and max_chain parameters. + + deflateTune() can be called after deflateInit() or deflateInit2(), and + returns Z_OK on success, or Z_STREAM_ERROR for an invalid deflate stream. + */ + +ZEXTERN uLong ZEXPORT deflateBound OF((z_streamp strm, + uLong sourceLen)); +/* + deflateBound() returns an upper bound on the compressed size after + deflation of sourceLen bytes. It must be called after deflateInit() + or deflateInit2(). This would be used to allocate an output buffer + for deflation in a single pass, and so would be called before deflate(). +*/ + +ZEXTERN int ZEXPORT deflatePrime OF((z_streamp strm, + int bits, + int value)); +/* + deflatePrime() inserts bits in the deflate output stream. The intent + is that this function is used to start off the deflate output with the + bits leftover from a previous deflate stream when appending to it. As such, + this function can only be used for raw deflate, and must be used before the + first deflate() call after a deflateInit2() or deflateReset(). bits must be + less than or equal to 16, and that many of the least significant bits of + value will be inserted in the output. + + deflatePrime returns Z_OK if success, or Z_STREAM_ERROR if the source + stream state was inconsistent. +*/ + +ZEXTERN int ZEXPORT deflateSetHeader OF((z_streamp strm, + gz_headerp head)); +/* + deflateSetHeader() provides gzip header information for when a gzip + stream is requested by deflateInit2(). deflateSetHeader() may be called + after deflateInit2() or deflateReset() and before the first call of + deflate(). The text, time, os, extra field, name, and comment information + in the provided gz_header structure are written to the gzip header (xflag is + ignored -- the extra flags are set according to the compression level). The + caller must assure that, if not Z_NULL, name and comment are terminated with + a zero byte, and that if extra is not Z_NULL, that extra_len bytes are + available there. If hcrc is true, a gzip header crc is included. Note that + the current versions of the command-line version of gzip (up through version + 1.3.x) do not support header crc's, and will report that it is a "multi-part + gzip file" and give up. + + If deflateSetHeader is not used, the default gzip header has text false, + the time set to zero, and os set to 255, with no extra, name, or comment + fields. The gzip header is returned to the default state by deflateReset(). + + deflateSetHeader returns Z_OK if success, or Z_STREAM_ERROR if the source + stream state was inconsistent. +*/ + +/* +ZEXTERN int ZEXPORT inflateInit2 OF((z_streamp strm, + int windowBits)); + + This is another version of inflateInit with an extra parameter. The + fields next_in, avail_in, zalloc, zfree and opaque must be initialized + before by the caller. + + The windowBits parameter is the base two logarithm of the maximum window + size (the size of the history buffer). It should be in the range 8..15 for + this version of the library. The default value is 15 if inflateInit is used + instead. windowBits must be greater than or equal to the windowBits value + provided to deflateInit2() while compressing, or it must be equal to 15 if + deflateInit2() was not used. If a compressed stream with a larger window + size is given as input, inflate() will return with the error code + Z_DATA_ERROR instead of trying to allocate a larger window. + + windowBits can also be -8..-15 for raw inflate. In this case, -windowBits + determines the window size. inflate() will then process raw deflate data, + not looking for a zlib or gzip header, not generating a check value, and not + looking for any check values for comparison at the end of the stream. This + is for use with other formats that use the deflate compressed data format + such as zip. Those formats provide their own check values. If a custom + format is developed using the raw deflate format for compressed data, it is + recommended that a check value such as an adler32 or a crc32 be applied to + the uncompressed data as is done in the zlib, gzip, and zip formats. For + most applications, the zlib format should be used as is. Note that comments + above on the use in deflateInit2() applies to the magnitude of windowBits. + + windowBits can also be greater than 15 for optional gzip decoding. Add + 32 to windowBits to enable zlib and gzip decoding with automatic header + detection, or add 16 to decode only the gzip format (the zlib format will + return a Z_DATA_ERROR). If a gzip stream is being decoded, strm->adler is + a crc32 instead of an adler32. + + inflateInit2 returns Z_OK if success, Z_MEM_ERROR if there was not enough + memory, Z_STREAM_ERROR if a parameter is invalid (such as a null strm). msg + is set to null if there is no error message. inflateInit2 does not perform + any decompression apart from reading the zlib header if present: this will + be done by inflate(). (So next_in and avail_in may be modified, but next_out + and avail_out are unchanged.) +*/ + +ZEXTERN int ZEXPORT inflateSetDictionary OF((z_streamp strm, + const Bytef *dictionary, + uInt dictLength)); +/* + Initializes the decompression dictionary from the given uncompressed byte + sequence. This function must be called immediately after a call of inflate, + if that call returned Z_NEED_DICT. The dictionary chosen by the compressor + can be determined from the adler32 value returned by that call of inflate. + The compressor and decompressor must use exactly the same dictionary (see + deflateSetDictionary). For raw inflate, this function can be called + immediately after inflateInit2() or inflateReset() and before any call of + inflate() to set the dictionary. The application must insure that the + dictionary that was used for compression is provided. + + inflateSetDictionary returns Z_OK if success, Z_STREAM_ERROR if a + parameter is invalid (such as NULL dictionary) or the stream state is + inconsistent, Z_DATA_ERROR if the given dictionary doesn't match the + expected one (incorrect adler32 value). inflateSetDictionary does not + perform any decompression: this will be done by subsequent calls of + inflate(). +*/ + +ZEXTERN int ZEXPORT inflateSync OF((z_streamp strm)); +/* + Skips invalid compressed data until a full flush point (see above the + description of deflate with Z_FULL_FLUSH) can be found, or until all + available input is skipped. No output is provided. + + inflateSync returns Z_OK if a full flush point has been found, Z_BUF_ERROR + if no more input was provided, Z_DATA_ERROR if no flush point has been found, + or Z_STREAM_ERROR if the stream structure was inconsistent. In the success + case, the application may save the current current value of total_in which + indicates where valid compressed data was found. In the error case, the + application may repeatedly call inflateSync, providing more input each time, + until success or end of the input data. +*/ + +ZEXTERN int ZEXPORT inflateCopy OF((z_streamp dest, + z_streamp source)); +/* + Sets the destination stream as a complete copy of the source stream. + + This function can be useful when randomly accessing a large stream. The + first pass through the stream can periodically record the inflate state, + allowing restarting inflate at those points when randomly accessing the + stream. + + inflateCopy returns Z_OK if success, Z_MEM_ERROR if there was not + enough memory, Z_STREAM_ERROR if the source stream state was inconsistent + (such as zalloc being NULL). msg is left unchanged in both source and + destination. +*/ + +ZEXTERN int ZEXPORT inflateReset OF((z_streamp strm)); +/* + This function is equivalent to inflateEnd followed by inflateInit, + but does not free and reallocate all the internal decompression state. + The stream will keep attributes that may have been set by inflateInit2. + + inflateReset returns Z_OK if success, or Z_STREAM_ERROR if the source + stream state was inconsistent (such as zalloc or state being NULL). +*/ + +ZEXTERN int ZEXPORT inflatePrime OF((z_streamp strm, + int bits, + int value)); +/* + This function inserts bits in the inflate input stream. The intent is + that this function is used to start inflating at a bit position in the + middle of a byte. The provided bits will be used before any bytes are used + from next_in. This function should only be used with raw inflate, and + should be used before the first inflate() call after inflateInit2() or + inflateReset(). bits must be less than or equal to 16, and that many of the + least significant bits of value will be inserted in the input. + + inflatePrime returns Z_OK if success, or Z_STREAM_ERROR if the source + stream state was inconsistent. +*/ + +ZEXTERN int ZEXPORT inflateGetHeader OF((z_streamp strm, + gz_headerp head)); +/* + inflateGetHeader() requests that gzip header information be stored in the + provided gz_header structure. inflateGetHeader() may be called after + inflateInit2() or inflateReset(), and before the first call of inflate(). + As inflate() processes the gzip stream, head->done is zero until the header + is completed, at which time head->done is set to one. If a zlib stream is + being decoded, then head->done is set to -1 to indicate that there will be + no gzip header information forthcoming. Note that Z_BLOCK can be used to + force inflate() to return immediately after header processing is complete + and before any actual data is decompressed. + + The text, time, xflags, and os fields are filled in with the gzip header + contents. hcrc is set to true if there is a header CRC. (The header CRC + was valid if done is set to one.) If extra is not Z_NULL, then extra_max + contains the maximum number of bytes to write to extra. Once done is true, + extra_len contains the actual extra field length, and extra contains the + extra field, or that field truncated if extra_max is less than extra_len. + If name is not Z_NULL, then up to name_max characters are written there, + terminated with a zero unless the length is greater than name_max. If + comment is not Z_NULL, then up to comm_max characters are written there, + terminated with a zero unless the length is greater than comm_max. When + any of extra, name, or comment are not Z_NULL and the respective field is + not present in the header, then that field is set to Z_NULL to signal its + absence. This allows the use of deflateSetHeader() with the returned + structure to duplicate the header. However if those fields are set to + allocated memory, then the application will need to save those pointers + elsewhere so that they can be eventually freed. + + If inflateGetHeader is not used, then the header information is simply + discarded. The header is always checked for validity, including the header + CRC if present. inflateReset() will reset the process to discard the header + information. The application would need to call inflateGetHeader() again to + retrieve the header from the next gzip stream. + + inflateGetHeader returns Z_OK if success, or Z_STREAM_ERROR if the source + stream state was inconsistent. +*/ + +/* +ZEXTERN int ZEXPORT inflateBackInit OF((z_streamp strm, int windowBits, + unsigned char FAR *window)); + + Initialize the internal stream state for decompression using inflateBack() + calls. The fields zalloc, zfree and opaque in strm must be initialized + before the call. If zalloc and zfree are Z_NULL, then the default library- + derived memory allocation routines are used. windowBits is the base two + logarithm of the window size, in the range 8..15. window is a caller + supplied buffer of that size. Except for special applications where it is + assured that deflate was used with small window sizes, windowBits must be 15 + and a 32K byte window must be supplied to be able to decompress general + deflate streams. + + See inflateBack() for the usage of these routines. + + inflateBackInit will return Z_OK on success, Z_STREAM_ERROR if any of + the paramaters are invalid, Z_MEM_ERROR if the internal state could not + be allocated, or Z_VERSION_ERROR if the version of the library does not + match the version of the header file. +*/ + +typedef unsigned (*in_func) OF((void FAR *, unsigned char FAR * FAR *)); +typedef int (*out_func) OF((void FAR *, unsigned char FAR *, unsigned)); + +ZEXTERN int ZEXPORT inflateBack OF((z_streamp strm, + in_func in, void FAR *in_desc, + out_func out, void FAR *out_desc)); +/* + inflateBack() does a raw inflate with a single call using a call-back + interface for input and output. This is more efficient than inflate() for + file i/o applications in that it avoids copying between the output and the + sliding window by simply making the window itself the output buffer. This + function trusts the application to not change the output buffer passed by + the output function, at least until inflateBack() returns. + + inflateBackInit() must be called first to allocate the internal state + and to initialize the state with the user-provided window buffer. + inflateBack() may then be used multiple times to inflate a complete, raw + deflate stream with each call. inflateBackEnd() is then called to free + the allocated state. + + A raw deflate stream is one with no zlib or gzip header or trailer. + This routine would normally be used in a utility that reads zip or gzip + files and writes out uncompressed files. The utility would decode the + header and process the trailer on its own, hence this routine expects + only the raw deflate stream to decompress. This is different from the + normal behavior of inflate(), which expects either a zlib or gzip header and + trailer around the deflate stream. + + inflateBack() uses two subroutines supplied by the caller that are then + called by inflateBack() for input and output. inflateBack() calls those + routines until it reads a complete deflate stream and writes out all of the + uncompressed data, or until it encounters an error. The function's + parameters and return types are defined above in the in_func and out_func + typedefs. inflateBack() will call in(in_desc, &buf) which should return the + number of bytes of provided input, and a pointer to that input in buf. If + there is no input available, in() must return zero--buf is ignored in that + case--and inflateBack() will return a buffer error. inflateBack() will call + out(out_desc, buf, len) to write the uncompressed data buf[0..len-1]. out() + should return zero on success, or non-zero on failure. If out() returns + non-zero, inflateBack() will return with an error. Neither in() nor out() + are permitted to change the contents of the window provided to + inflateBackInit(), which is also the buffer that out() uses to write from. + The length written by out() will be at most the window size. Any non-zero + amount of input may be provided by in(). + + For convenience, inflateBack() can be provided input on the first call by + setting strm->next_in and strm->avail_in. If that input is exhausted, then + in() will be called. Therefore strm->next_in must be initialized before + calling inflateBack(). If strm->next_in is Z_NULL, then in() will be called + immediately for input. If strm->next_in is not Z_NULL, then strm->avail_in + must also be initialized, and then if strm->avail_in is not zero, input will + initially be taken from strm->next_in[0 .. strm->avail_in - 1]. + + The in_desc and out_desc parameters of inflateBack() is passed as the + first parameter of in() and out() respectively when they are called. These + descriptors can be optionally used to pass any information that the caller- + supplied in() and out() functions need to do their job. + + On return, inflateBack() will set strm->next_in and strm->avail_in to + pass back any unused input that was provided by the last in() call. The + return values of inflateBack() can be Z_STREAM_END on success, Z_BUF_ERROR + if in() or out() returned an error, Z_DATA_ERROR if there was a format + error in the deflate stream (in which case strm->msg is set to indicate the + nature of the error), or Z_STREAM_ERROR if the stream was not properly + initialized. In the case of Z_BUF_ERROR, an input or output error can be + distinguished using strm->next_in which will be Z_NULL only if in() returned + an error. If strm->next is not Z_NULL, then the Z_BUF_ERROR was due to + out() returning non-zero. (in() will always be called before out(), so + strm->next_in is assured to be defined if out() returns non-zero.) Note + that inflateBack() cannot return Z_OK. +*/ + +ZEXTERN int ZEXPORT inflateBackEnd OF((z_streamp strm)); +/* + All memory allocated by inflateBackInit() is freed. + + inflateBackEnd() returns Z_OK on success, or Z_STREAM_ERROR if the stream + state was inconsistent. +*/ + +ZEXTERN uLong ZEXPORT zlibCompileFlags OF((void)); +/* Return flags indicating compile-time options. + + Type sizes, two bits each, 00 = 16 bits, 01 = 32, 10 = 64, 11 = other: + 1.0: size of uInt + 3.2: size of uLong + 5.4: size of voidpf (pointer) + 7.6: size of z_off_t + + Compiler, assembler, and debug options: + 8: DEBUG + 9: ASMV or ASMINF -- use ASM code + 10: ZLIB_WINAPI -- exported functions use the WINAPI calling convention + 11: 0 (reserved) + + One-time table building (smaller code, but not thread-safe if true): + 12: BUILDFIXED -- build static block decoding tables when needed + 13: DYNAMIC_CRC_TABLE -- build CRC calculation tables when needed + 14,15: 0 (reserved) + + Library content (indicates missing functionality): + 16: NO_GZCOMPRESS -- gz* functions cannot compress (to avoid linking + deflate code when not needed) + 17: NO_GZIP -- deflate can't write gzip streams, and inflate can't detect + and decode gzip streams (to avoid linking crc code) + 18-19: 0 (reserved) + + Operation variations (changes in library functionality): + 20: PKZIP_BUG_WORKAROUND -- slightly more permissive inflate + 21: FASTEST -- deflate algorithm with only one, lowest compression level + 22,23: 0 (reserved) + + The sprintf variant used by gzprintf (zero is best): + 24: 0 = vs*, 1 = s* -- 1 means limited to 20 arguments after the format + 25: 0 = *nprintf, 1 = *printf -- 1 means gzprintf() not secure! + 26: 0 = returns value, 1 = void -- 1 means inferred string length returned + + Remainder: + 27-31: 0 (reserved) + */ + + + /* utility functions */ + +/* + The following utility functions are implemented on top of the + basic stream-oriented functions. To simplify the interface, some + default options are assumed (compression level and memory usage, + standard memory allocation functions). The source code of these + utility functions can easily be modified if you need special options. +*/ + +ZEXTERN int ZEXPORT compress OF((Bytef *dest, uLongf *destLen, + const Bytef *source, uLong sourceLen)); +/* + Compresses the source buffer into the destination buffer. sourceLen is + the byte length of the source buffer. Upon entry, destLen is the total + size of the destination buffer, which must be at least the value returned + by compressBound(sourceLen). Upon exit, destLen is the actual size of the + compressed buffer. + This function can be used to compress a whole file at once if the + input file is mmap'ed. + compress returns Z_OK if success, Z_MEM_ERROR if there was not + enough memory, Z_BUF_ERROR if there was not enough room in the output + buffer. +*/ + +ZEXTERN int ZEXPORT compress2 OF((Bytef *dest, uLongf *destLen, + const Bytef *source, uLong sourceLen, + int level)); +/* + Compresses the source buffer into the destination buffer. The level + parameter has the same meaning as in deflateInit. sourceLen is the byte + length of the source buffer. Upon entry, destLen is the total size of the + destination buffer, which must be at least the value returned by + compressBound(sourceLen). Upon exit, destLen is the actual size of the + compressed buffer. + + compress2 returns Z_OK if success, Z_MEM_ERROR if there was not enough + memory, Z_BUF_ERROR if there was not enough room in the output buffer, + Z_STREAM_ERROR if the level parameter is invalid. +*/ + +ZEXTERN uLong ZEXPORT compressBound OF((uLong sourceLen)); +/* + compressBound() returns an upper bound on the compressed size after + compress() or compress2() on sourceLen bytes. It would be used before + a compress() or compress2() call to allocate the destination buffer. +*/ + +ZEXTERN int ZEXPORT uncompress OF((Bytef *dest, uLongf *destLen, + const Bytef *source, uLong sourceLen)); +/* + Decompresses the source buffer into the destination buffer. sourceLen is + the byte length of the source buffer. Upon entry, destLen is the total + size of the destination buffer, which must be large enough to hold the + entire uncompressed data. (The size of the uncompressed data must have + been saved previously by the compressor and transmitted to the decompressor + by some mechanism outside the scope of this compression library.) + Upon exit, destLen is the actual size of the compressed buffer. + This function can be used to decompress a whole file at once if the + input file is mmap'ed. + + uncompress returns Z_OK if success, Z_MEM_ERROR if there was not + enough memory, Z_BUF_ERROR if there was not enough room in the output + buffer, or Z_DATA_ERROR if the input data was corrupted or incomplete. +*/ + + +typedef voidp gzFile; + +ZEXTERN gzFile ZEXPORT gzopen OF((const char *path, const char *mode)); +/* + Opens a gzip (.gz) file for reading or writing. The mode parameter + is as in fopen ("rb" or "wb") but can also include a compression level + ("wb9") or a strategy: 'f' for filtered data as in "wb6f", 'h' for + Huffman only compression as in "wb1h", or 'R' for run-length encoding + as in "wb1R". (See the description of deflateInit2 for more information + about the strategy parameter.) + + gzopen can be used to read a file which is not in gzip format; in this + case gzread will directly read from the file without decompression. + + gzopen returns NULL if the file could not be opened or if there was + insufficient memory to allocate the (de)compression state; errno + can be checked to distinguish the two cases (if errno is zero, the + zlib error is Z_MEM_ERROR). */ + +ZEXTERN gzFile ZEXPORT gzdopen OF((int fd, const char *mode)); +/* + gzdopen() associates a gzFile with the file descriptor fd. File + descriptors are obtained from calls like open, dup, creat, pipe or + fileno (in the file has been previously opened with fopen). + The mode parameter is as in gzopen. + The next call of gzclose on the returned gzFile will also close the + file descriptor fd, just like fclose(fdopen(fd), mode) closes the file + descriptor fd. If you want to keep fd open, use gzdopen(dup(fd), mode). + gzdopen returns NULL if there was insufficient memory to allocate + the (de)compression state. +*/ + +ZEXTERN int ZEXPORT gzsetparams OF((gzFile file, int level, int strategy)); +/* + Dynamically update the compression level or strategy. See the description + of deflateInit2 for the meaning of these parameters. + gzsetparams returns Z_OK if success, or Z_STREAM_ERROR if the file was not + opened for writing. +*/ + +ZEXTERN int ZEXPORT gzread OF((gzFile file, voidp buf, unsigned len)); +/* + Reads the given number of uncompressed bytes from the compressed file. + If the input file was not in gzip format, gzread copies the given number + of bytes into the buffer. + gzread returns the number of uncompressed bytes actually read (0 for + end of file, -1 for error). */ + +ZEXTERN int ZEXPORT gzwrite OF((gzFile file, + voidpc buf, unsigned len)); +/* + Writes the given number of uncompressed bytes into the compressed file. + gzwrite returns the number of uncompressed bytes actually written + (0 in case of error). +*/ + +ZEXTERN int ZEXPORTVA gzprintf OF((gzFile file, const char *format, ...)); +/* + Converts, formats, and writes the args to the compressed file under + control of the format string, as in fprintf. gzprintf returns the number of + uncompressed bytes actually written (0 in case of error). The number of + uncompressed bytes written is limited to 4095. The caller should assure that + this limit is not exceeded. If it is exceeded, then gzprintf() will return + return an error (0) with nothing written. In this case, there may also be a + buffer overflow with unpredictable consequences, which is possible only if + zlib was compiled with the insecure functions sprintf() or vsprintf() + because the secure snprintf() or vsnprintf() functions were not available. +*/ + +ZEXTERN int ZEXPORT gzputs OF((gzFile file, const char *s)); +/* + Writes the given null-terminated string to the compressed file, excluding + the terminating null character. + gzputs returns the number of characters written, or -1 in case of error. +*/ + +ZEXTERN char * ZEXPORT gzgets OF((gzFile file, char *buf, int len)); +/* + Reads bytes from the compressed file until len-1 characters are read, or + a newline character is read and transferred to buf, or an end-of-file + condition is encountered. The string is then terminated with a null + character. + gzgets returns buf, or Z_NULL in case of error. +*/ + +ZEXTERN int ZEXPORT gzputc OF((gzFile file, int c)); +/* + Writes c, converted to an unsigned char, into the compressed file. + gzputc returns the value that was written, or -1 in case of error. +*/ + +ZEXTERN int ZEXPORT gzgetc OF((gzFile file)); +/* + Reads one byte from the compressed file. gzgetc returns this byte + or -1 in case of end of file or error. +*/ + +ZEXTERN int ZEXPORT gzungetc OF((int c, gzFile file)); +/* + Push one character back onto the stream to be read again later. + Only one character of push-back is allowed. gzungetc() returns the + character pushed, or -1 on failure. gzungetc() will fail if a + character has been pushed but not read yet, or if c is -1. The pushed + character will be discarded if the stream is repositioned with gzseek() + or gzrewind(). +*/ + +ZEXTERN int ZEXPORT gzflush OF((gzFile file, int flush)); +/* + Flushes all pending output into the compressed file. The parameter + flush is as in the deflate() function. The return value is the zlib + error number (see function gzerror below). gzflush returns Z_OK if + the flush parameter is Z_FINISH and all output could be flushed. + gzflush should be called only when strictly necessary because it can + degrade compression. +*/ + +ZEXTERN z_off_t ZEXPORT gzseek OF((gzFile file, + z_off_t offset, int whence)); +/* + Sets the starting position for the next gzread or gzwrite on the + given compressed file. The offset represents a number of bytes in the + uncompressed data stream. The whence parameter is defined as in lseek(2); + the value SEEK_END is not supported. + If the file is opened for reading, this function is emulated but can be + extremely slow. If the file is opened for writing, only forward seeks are + supported; gzseek then compresses a sequence of zeroes up to the new + starting position. + + gzseek returns the resulting offset location as measured in bytes from + the beginning of the uncompressed stream, or -1 in case of error, in + particular if the file is opened for writing and the new starting position + would be before the current position. +*/ + +ZEXTERN int ZEXPORT gzrewind OF((gzFile file)); +/* + Rewinds the given file. This function is supported only for reading. + + gzrewind(file) is equivalent to (int)gzseek(file, 0L, SEEK_SET) +*/ + +ZEXTERN z_off_t ZEXPORT gztell OF((gzFile file)); +/* + Returns the starting position for the next gzread or gzwrite on the + given compressed file. This position represents a number of bytes in the + uncompressed data stream. + + gztell(file) is equivalent to gzseek(file, 0L, SEEK_CUR) +*/ + +ZEXTERN int ZEXPORT gzeof OF((gzFile file)); +/* + Returns 1 when EOF has previously been detected reading the given + input stream, otherwise zero. +*/ + +ZEXTERN int ZEXPORT gzdirect OF((gzFile file)); +/* + Returns 1 if file is being read directly without decompression, otherwise + zero. +*/ + +ZEXTERN int ZEXPORT gzclose OF((gzFile file)); +/* + Flushes all pending output if necessary, closes the compressed file + and deallocates all the (de)compression state. The return value is the zlib + error number (see function gzerror below). +*/ + +ZEXTERN const char * ZEXPORT gzerror OF((gzFile file, int *errnum)); +/* + Returns the error message for the last error which occurred on the + given compressed file. errnum is set to zlib error number. If an + error occurred in the file system and not in the compression library, + errnum is set to Z_ERRNO and the application may consult errno + to get the exact error code. +*/ + +ZEXTERN void ZEXPORT gzclearerr OF((gzFile file)); +/* + Clears the error and end-of-file flags for file. This is analogous to the + clearerr() function in stdio. This is useful for continuing to read a gzip + file that is being written concurrently. +*/ + + /* checksum functions */ + +/* + These functions are not related to compression but are exported + anyway because they might be useful in applications using the + compression library. +*/ + +ZEXTERN uLong ZEXPORT adler32 OF((uLong adler, const Bytef *buf, uInt len)); +/* + Update a running Adler-32 checksum with the bytes buf[0..len-1] and + return the updated checksum. If buf is NULL, this function returns + the required initial value for the checksum. + An Adler-32 checksum is almost as reliable as a CRC32 but can be computed + much faster. Usage example: + + uLong adler = adler32(0L, Z_NULL, 0); + + while (read_buffer(buffer, length) != EOF) { + adler = adler32(adler, buffer, length); + } + if (adler != original_adler) error(); +*/ + +ZEXTERN uLong ZEXPORT adler32_combine OF((uLong adler1, uLong adler2, + z_off_t len2)); +/* + Combine two Adler-32 checksums into one. For two sequences of bytes, seq1 + and seq2 with lengths len1 and len2, Adler-32 checksums were calculated for + each, adler1 and adler2. adler32_combine() returns the Adler-32 checksum of + seq1 and seq2 concatenated, requiring only adler1, adler2, and len2. +*/ + +ZEXTERN uLong ZEXPORT crc32 OF((uLong crc, const Bytef *buf, uInt len)); +/* + Update a running CRC-32 with the bytes buf[0..len-1] and return the + updated CRC-32. If buf is NULL, this function returns the required initial + value for the for the crc. Pre- and post-conditioning (one's complement) is + performed within this function so it shouldn't be done by the application. + Usage example: + + uLong crc = crc32(0L, Z_NULL, 0); + + while (read_buffer(buffer, length) != EOF) { + crc = crc32(crc, buffer, length); + } + if (crc != original_crc) error(); +*/ + +ZEXTERN uLong ZEXPORT crc32_combine OF((uLong crc1, uLong crc2, z_off_t len2)); + +/* + Combine two CRC-32 check values into one. For two sequences of bytes, + seq1 and seq2 with lengths len1 and len2, CRC-32 check values were + calculated for each, crc1 and crc2. crc32_combine() returns the CRC-32 + check value of seq1 and seq2 concatenated, requiring only crc1, crc2, and + len2. +*/ + + + /* various hacks, don't look :) */ + +/* deflateInit and inflateInit are macros to allow checking the zlib version + * and the compiler's view of z_stream: + */ +ZEXTERN int ZEXPORT deflateInit_ OF((z_streamp strm, int level, + const char *version, int stream_size)); +ZEXTERN int ZEXPORT inflateInit_ OF((z_streamp strm, + const char *version, int stream_size)); +ZEXTERN int ZEXPORT deflateInit2_ OF((z_streamp strm, int level, int method, + int windowBits, int memLevel, + int strategy, const char *version, + int stream_size)); +ZEXTERN int ZEXPORT inflateInit2_ OF((z_streamp strm, int windowBits, + const char *version, int stream_size)); +ZEXTERN int ZEXPORT inflateBackInit_ OF((z_streamp strm, int windowBits, + unsigned char FAR *window, + const char *version, + int stream_size)); +#define deflateInit(strm, level) \ + deflateInit_((strm), (level), ZLIB_VERSION, sizeof(z_stream)) +#define inflateInit(strm) \ + inflateInit_((strm), ZLIB_VERSION, sizeof(z_stream)) +#define deflateInit2(strm, level, method, windowBits, memLevel, strategy) \ + deflateInit2_((strm),(level),(method),(windowBits),(memLevel),\ + (strategy), ZLIB_VERSION, sizeof(z_stream)) +#define inflateInit2(strm, windowBits) \ + inflateInit2_((strm), (windowBits), ZLIB_VERSION, sizeof(z_stream)) +#define inflateBackInit(strm, windowBits, window) \ + inflateBackInit_((strm), (windowBits), (window), \ + ZLIB_VERSION, sizeof(z_stream)) + + +#if !defined(ZUTIL_H) && !defined(NO_DUMMY_DECL) + struct internal_state {int dummy;}; /* hack for buggy compilers */ +#endif + +ZEXTERN const char * ZEXPORT zError OF((int)); +ZEXTERN int ZEXPORT inflateSyncPoint OF((z_streamp z)); +ZEXTERN const uLongf * ZEXPORT get_crc_table OF((void)); + +#ifdef __cplusplus +} +#endif + +#endif /* ZLIB_H */ diff --git a/desmume/src/windows/zlib123/zutil.h b/src/windows/zlib123/zutil.h similarity index 96% rename from desmume/src/windows/zlib123/zutil.h rename to src/windows/zlib123/zutil.h index 520d6041e..c0fb9c1f5 100644 --- a/desmume/src/windows/zlib123/zutil.h +++ b/src/windows/zlib123/zutil.h @@ -1,269 +1,269 @@ -/* zutil.h -- internal interface and configuration of the compression library - * Copyright (C) 1995-2005 Jean-loup Gailly. - * For conditions of distribution and use, see copyright notice in zlib.h - */ - -/* WARNING: this file should *not* be used by applications. It is - part of the implementation of the compression library and is - subject to change. Applications should only use zlib.h. - */ - -/* @(#) $Id: zutil.h,v 1.1 2008-08-03 18:36:13 mtabachenko Exp $ */ - -#ifndef ZUTIL_H -#define ZUTIL_H - -#define ZLIB_INTERNAL -#include "zlib.h" - -#ifdef STDC -# ifndef _WIN32_WCE -# include -# endif -# include -# include -#endif -#ifdef NO_ERRNO_H -# ifdef _WIN32_WCE - /* The Microsoft C Run-Time Library for Windows CE doesn't have - * errno. We define it as a global variable to simplify porting. - * Its value is always 0 and should not be used. We rename it to - * avoid conflict with other libraries that use the same workaround. - */ -# define errno z_errno -# endif - extern int errno; -#else -# ifndef _WIN32_WCE -# include -# endif -#endif - -#ifndef local -# define local static -#endif -/* compile with -Dlocal if your debugger can't find static symbols */ - -typedef unsigned char uch; -typedef uch FAR uchf; -typedef unsigned short ush; -typedef ush FAR ushf; -typedef unsigned long ulg; - -extern const char * const z_errmsg[10]; /* indexed by 2-zlib_error */ -/* (size given to avoid silly warnings with Visual C++) */ - -#define ERR_MSG(err) z_errmsg[Z_NEED_DICT-(err)] - -#define ERR_RETURN(strm,err) \ - return (strm->msg = (char*)ERR_MSG(err), (err)) -/* To be used only when the state is known to be valid */ - - /* common constants */ - -#ifndef DEF_WBITS -# define DEF_WBITS MAX_WBITS -#endif -/* default windowBits for decompression. MAX_WBITS is for compression only */ - -#if MAX_MEM_LEVEL >= 8 -# define DEF_MEM_LEVEL 8 -#else -# define DEF_MEM_LEVEL MAX_MEM_LEVEL -#endif -/* default memLevel */ - -#define STORED_BLOCK 0 -#define STATIC_TREES 1 -#define DYN_TREES 2 -/* The three kinds of block type */ - -#define MIN_MATCH 3 -#define MAX_MATCH 258 -/* The minimum and maximum match lengths */ - -#define PRESET_DICT 0x20 /* preset dictionary flag in zlib header */ - - /* target dependencies */ - -#if defined(MSDOS) || (defined(WINDOWS) && !defined(WIN32)) -# define OS_CODE 0x00 -# if defined(__TURBOC__) || defined(__BORLANDC__) -# if(__STDC__ == 1) && (defined(__LARGE__) || defined(__COMPACT__)) - /* Allow compilation with ANSI keywords only enabled */ - void _Cdecl farfree( void *block ); - void *_Cdecl farmalloc( unsigned long nbytes ); -# else -# include -# endif -# else /* MSC or DJGPP */ -# include -# endif -#endif - -#ifdef AMIGA -# define OS_CODE 0x01 -#endif - -#if defined(VAXC) || defined(VMS) -# define OS_CODE 0x02 -# define F_OPEN(name, mode) \ - fopen((name), (mode), "mbc=60", "ctx=stm", "rfm=fix", "mrs=512") -#endif - -#if defined(ATARI) || defined(atarist) -# define OS_CODE 0x05 -#endif - -#ifdef OS2 -# define OS_CODE 0x06 -# ifdef M_I86 - #include -# endif -#endif - -#if defined(MACOS) || defined(TARGET_OS_MAC) -# define OS_CODE 0x07 -# if defined(__MWERKS__) && __dest_os != __be_os && __dest_os != __win32_os -# include /* for fdopen */ -# else -# ifndef fdopen -# define fdopen(fd,mode) NULL /* No fdopen() */ -# endif -# endif -#endif - -#ifdef TOPS20 -# define OS_CODE 0x0a -#endif - -#ifdef WIN32 -# ifndef __CYGWIN__ /* Cygwin is Unix, not Win32 */ -# define OS_CODE 0x0b -# endif -#endif - -#ifdef __50SERIES /* Prime/PRIMOS */ -# define OS_CODE 0x0f -#endif - -#if defined(_BEOS_) || defined(RISCOS) -# define fdopen(fd,mode) NULL /* No fdopen() */ -#endif - -#if (defined(_MSC_VER) && (_MSC_VER > 600)) -# if defined(_WIN32_WCE) -# define fdopen(fd,mode) NULL /* No fdopen() */ -# ifndef _PTRDIFF_T_DEFINED - typedef int ptrdiff_t; -# define _PTRDIFF_T_DEFINED -# endif -# else -# define fdopen(fd,type) _fdopen(fd,type) -# endif -#endif - - /* common defaults */ - -#ifndef OS_CODE -# define OS_CODE 0x03 /* assume Unix */ -#endif - -#ifndef F_OPEN -# define F_OPEN(name, mode) fopen((name), (mode)) -#endif - - /* functions */ - -#if defined(STDC99) || (defined(__TURBOC__) && __TURBOC__ >= 0x550) -# ifndef HAVE_VSNPRINTF -# define HAVE_VSNPRINTF -# endif -#endif -#if defined(__CYGWIN__) -# ifndef HAVE_VSNPRINTF -# define HAVE_VSNPRINTF -# endif -#endif -#ifndef HAVE_VSNPRINTF -# ifdef MSDOS - /* vsnprintf may exist on some MS-DOS compilers (DJGPP?), - but for now we just assume it doesn't. */ -# define NO_vsnprintf -# endif -# ifdef __TURBOC__ -# define NO_vsnprintf -# endif -# ifdef WIN32 - /* In Win32, vsnprintf is available as the "non-ANSI" _vsnprintf. */ -# if !defined(vsnprintf) && !defined(NO_vsnprintf) -# define vsnprintf _vsnprintf -# endif -# endif -# ifdef __SASC -# define NO_vsnprintf -# endif -#endif -#ifdef VMS -# define NO_vsnprintf -#endif - -#if defined(pyr) -# define NO_MEMCPY -#endif -#if defined(SMALL_MEDIUM) && !defined(_MSC_VER) && !defined(__SC__) - /* Use our own functions for small and medium model with MSC <= 5.0. - * You may have to use the same strategy for Borland C (untested). - * The __SC__ check is for Symantec. - */ -# define NO_MEMCPY -#endif -#if defined(STDC) && !defined(HAVE_MEMCPY) && !defined(NO_MEMCPY) -# define HAVE_MEMCPY -#endif -#ifdef HAVE_MEMCPY -# ifdef SMALL_MEDIUM /* MSDOS small or medium model */ -# define zmemcpy _fmemcpy -# define zmemcmp _fmemcmp -# define zmemzero(dest, len) _fmemset(dest, 0, len) -# else -# define zmemcpy memcpy -# define zmemcmp memcmp -# define zmemzero(dest, len) memset(dest, 0, len) -# endif -#else - extern void zmemcpy OF((Bytef* dest, const Bytef* source, uInt len)); - extern int zmemcmp OF((const Bytef* s1, const Bytef* s2, uInt len)); - extern void zmemzero OF((Bytef* dest, uInt len)); -#endif - -/* Diagnostic functions */ -#ifdef DEBUG -# include - extern int z_verbose; - extern void z_error OF((char *m)); -# define Assert(cond,msg) {if(!(cond)) z_error(msg);} -# define Trace(x) {if (z_verbose>=0) fprintf x ;} -# define Tracev(x) {if (z_verbose>0) fprintf x ;} -# define Tracevv(x) {if (z_verbose>1) fprintf x ;} -# define Tracec(c,x) {if (z_verbose>0 && (c)) fprintf x ;} -# define Tracecv(c,x) {if (z_verbose>1 && (c)) fprintf x ;} -#else -# define Assert(cond,msg) -# define Trace(x) -# define Tracev(x) -# define Tracevv(x) -# define Tracec(c,x) -# define Tracecv(c,x) -#endif - - -voidpf zcalloc OF((voidpf opaque, unsigned items, unsigned size)); -void zcfree OF((voidpf opaque, voidpf ptr)); - -#define ZALLOC(strm, items, size) \ - (*((strm)->zalloc))((strm)->opaque, (items), (size)) -#define ZFREE(strm, addr) (*((strm)->zfree))((strm)->opaque, (voidpf)(addr)) -#define TRY_FREE(s, p) {if (p) ZFREE(s, p);} - -#endif /* ZUTIL_H */ +/* zutil.h -- internal interface and configuration of the compression library + * Copyright (C) 1995-2005 Jean-loup Gailly. + * For conditions of distribution and use, see copyright notice in zlib.h + */ + +/* WARNING: this file should *not* be used by applications. It is + part of the implementation of the compression library and is + subject to change. Applications should only use zlib.h. + */ + +/* @(#) $Id: zutil.h,v 1.1 2008-08-03 18:36:13 mtabachenko Exp $ */ + +#ifndef ZUTIL_H +#define ZUTIL_H + +#define ZLIB_INTERNAL +#include "zlib.h" + +#ifdef STDC +# ifndef _WIN32_WCE +# include +# endif +# include +# include +#endif +#ifdef NO_ERRNO_H +# ifdef _WIN32_WCE + /* The Microsoft C Run-Time Library for Windows CE doesn't have + * errno. We define it as a global variable to simplify porting. + * Its value is always 0 and should not be used. We rename it to + * avoid conflict with other libraries that use the same workaround. + */ +# define errno z_errno +# endif + extern int errno; +#else +# ifndef _WIN32_WCE +# include +# endif +#endif + +#ifndef local +# define local static +#endif +/* compile with -Dlocal if your debugger can't find static symbols */ + +typedef unsigned char uch; +typedef uch FAR uchf; +typedef unsigned short ush; +typedef ush FAR ushf; +typedef unsigned long ulg; + +extern const char * const z_errmsg[10]; /* indexed by 2-zlib_error */ +/* (size given to avoid silly warnings with Visual C++) */ + +#define ERR_MSG(err) z_errmsg[Z_NEED_DICT-(err)] + +#define ERR_RETURN(strm,err) \ + return (strm->msg = (char*)ERR_MSG(err), (err)) +/* To be used only when the state is known to be valid */ + + /* common constants */ + +#ifndef DEF_WBITS +# define DEF_WBITS MAX_WBITS +#endif +/* default windowBits for decompression. MAX_WBITS is for compression only */ + +#if MAX_MEM_LEVEL >= 8 +# define DEF_MEM_LEVEL 8 +#else +# define DEF_MEM_LEVEL MAX_MEM_LEVEL +#endif +/* default memLevel */ + +#define STORED_BLOCK 0 +#define STATIC_TREES 1 +#define DYN_TREES 2 +/* The three kinds of block type */ + +#define MIN_MATCH 3 +#define MAX_MATCH 258 +/* The minimum and maximum match lengths */ + +#define PRESET_DICT 0x20 /* preset dictionary flag in zlib header */ + + /* target dependencies */ + +#if defined(MSDOS) || (defined(WINDOWS) && !defined(WIN32)) +# define OS_CODE 0x00 +# if defined(__TURBOC__) || defined(__BORLANDC__) +# if(__STDC__ == 1) && (defined(__LARGE__) || defined(__COMPACT__)) + /* Allow compilation with ANSI keywords only enabled */ + void _Cdecl farfree( void *block ); + void *_Cdecl farmalloc( unsigned long nbytes ); +# else +# include +# endif +# else /* MSC or DJGPP */ +# include +# endif +#endif + +#ifdef AMIGA +# define OS_CODE 0x01 +#endif + +#if defined(VAXC) || defined(VMS) +# define OS_CODE 0x02 +# define F_OPEN(name, mode) \ + fopen((name), (mode), "mbc=60", "ctx=stm", "rfm=fix", "mrs=512") +#endif + +#if defined(ATARI) || defined(atarist) +# define OS_CODE 0x05 +#endif + +#ifdef OS2 +# define OS_CODE 0x06 +# ifdef M_I86 + #include +# endif +#endif + +#if defined(MACOS) || defined(TARGET_OS_MAC) +# define OS_CODE 0x07 +# if defined(__MWERKS__) && __dest_os != __be_os && __dest_os != __win32_os +# include /* for fdopen */ +# else +# ifndef fdopen +# define fdopen(fd,mode) NULL /* No fdopen() */ +# endif +# endif +#endif + +#ifdef TOPS20 +# define OS_CODE 0x0a +#endif + +#ifdef WIN32 +# ifndef __CYGWIN__ /* Cygwin is Unix, not Win32 */ +# define OS_CODE 0x0b +# endif +#endif + +#ifdef __50SERIES /* Prime/PRIMOS */ +# define OS_CODE 0x0f +#endif + +#if defined(_BEOS_) || defined(RISCOS) +# define fdopen(fd,mode) NULL /* No fdopen() */ +#endif + +#if (defined(_MSC_VER) && (_MSC_VER > 600)) +# if defined(_WIN32_WCE) +# define fdopen(fd,mode) NULL /* No fdopen() */ +# ifndef _PTRDIFF_T_DEFINED + typedef int ptrdiff_t; +# define _PTRDIFF_T_DEFINED +# endif +# else +# define fdopen(fd,type) _fdopen(fd,type) +# endif +#endif + + /* common defaults */ + +#ifndef OS_CODE +# define OS_CODE 0x03 /* assume Unix */ +#endif + +#ifndef F_OPEN +# define F_OPEN(name, mode) fopen((name), (mode)) +#endif + + /* functions */ + +#if defined(STDC99) || (defined(__TURBOC__) && __TURBOC__ >= 0x550) +# ifndef HAVE_VSNPRINTF +# define HAVE_VSNPRINTF +# endif +#endif +#if defined(__CYGWIN__) +# ifndef HAVE_VSNPRINTF +# define HAVE_VSNPRINTF +# endif +#endif +#ifndef HAVE_VSNPRINTF +# ifdef MSDOS + /* vsnprintf may exist on some MS-DOS compilers (DJGPP?), + but for now we just assume it doesn't. */ +# define NO_vsnprintf +# endif +# ifdef __TURBOC__ +# define NO_vsnprintf +# endif +# ifdef WIN32 + /* In Win32, vsnprintf is available as the "non-ANSI" _vsnprintf. */ +# if !defined(vsnprintf) && !defined(NO_vsnprintf) +# define vsnprintf _vsnprintf +# endif +# endif +# ifdef __SASC +# define NO_vsnprintf +# endif +#endif +#ifdef VMS +# define NO_vsnprintf +#endif + +#if defined(pyr) +# define NO_MEMCPY +#endif +#if defined(SMALL_MEDIUM) && !defined(_MSC_VER) && !defined(__SC__) + /* Use our own functions for small and medium model with MSC <= 5.0. + * You may have to use the same strategy for Borland C (untested). + * The __SC__ check is for Symantec. + */ +# define NO_MEMCPY +#endif +#if defined(STDC) && !defined(HAVE_MEMCPY) && !defined(NO_MEMCPY) +# define HAVE_MEMCPY +#endif +#ifdef HAVE_MEMCPY +# ifdef SMALL_MEDIUM /* MSDOS small or medium model */ +# define zmemcpy _fmemcpy +# define zmemcmp _fmemcmp +# define zmemzero(dest, len) _fmemset(dest, 0, len) +# else +# define zmemcpy memcpy +# define zmemcmp memcmp +# define zmemzero(dest, len) memset(dest, 0, len) +# endif +#else + extern void zmemcpy OF((Bytef* dest, const Bytef* source, uInt len)); + extern int zmemcmp OF((const Bytef* s1, const Bytef* s2, uInt len)); + extern void zmemzero OF((Bytef* dest, uInt len)); +#endif + +/* Diagnostic functions */ +#ifdef DEBUG +# include + extern int z_verbose; + extern void z_error OF((char *m)); +# define Assert(cond,msg) {if(!(cond)) z_error(msg);} +# define Trace(x) {if (z_verbose>=0) fprintf x ;} +# define Tracev(x) {if (z_verbose>0) fprintf x ;} +# define Tracevv(x) {if (z_verbose>1) fprintf x ;} +# define Tracec(c,x) {if (z_verbose>0 && (c)) fprintf x ;} +# define Tracecv(c,x) {if (z_verbose>1 && (c)) fprintf x ;} +#else +# define Assert(cond,msg) +# define Trace(x) +# define Tracev(x) +# define Tracevv(x) +# define Tracec(c,x) +# define Tracecv(c,x) +#endif + + +voidpf zcalloc OF((voidpf opaque, unsigned items, unsigned size)); +void zcfree OF((voidpf opaque, voidpf ptr)); + +#define ZALLOC(strm, items, size) \ + (*((strm)->zalloc))((strm)->opaque, (items), (size)) +#define ZFREE(strm, addr) (*((strm)->zfree))((strm)->opaque, (voidpf)(addr)) +#define TRY_FREE(s, p) {if (p) ZFREE(s, p);} + +#endif /* ZUTIL_H */ diff --git a/desmume/src/windows/zziplib/README b/src/windows/zziplib/README similarity index 100% rename from desmume/src/windows/zziplib/README rename to src/windows/zziplib/README diff --git a/desmume/src/windows/zziplib/zzip/_msvc.h b/src/windows/zziplib/zzip/_msvc.h similarity index 96% rename from desmume/src/windows/zziplib/zzip/_msvc.h rename to src/windows/zziplib/zzip/_msvc.h index 81adb6a4a..4d3c50552 100644 --- a/desmume/src/windows/zziplib/zzip/_msvc.h +++ b/src/windows/zziplib/zzip/_msvc.h @@ -1,213 +1,213 @@ -#ifndef _ZZIP__MSVC_H -#define _ZZIP__MSVC_H 1 - -#define _zzip_calltype __cdecl - -/* zzip/_msvc.h. Generated automatically at end of configure. */ -/* config.h.in. Generated from configure.ac by autoheader. */ - -/* Define to 1 if you have the header file. */ -/* #undef ZZIP_HAVE_BYTESWAP_H */ - -/* Define to 1 if you have the header file. */ -#ifndef ZZIP_HAVE_DIRECT_H -#define ZZIP_HAVE_DIRECT_H 1 -#endif - -/* Define to 1 if you have the header file, and it defines `DIR'. - */ -/* #undef ZZIP_HAVE_DIRENT_H */ - -/* Define to 1 if you have the header file. */ -/* #undef ZZIP_HAVE_DLFCN_H */ - -/* Define to 1 if you have the header file. */ -/* #undef ZZIP_HAVE_FNMATCH_H */ - -/* Define to 1 if you have the header file. */ -/* #undef ZZIP_HAVE_INTTYPES_H */ - -/* Define to 1 if you have the header file. */ -#ifndef ZZIP_HAVE_IO_H -#define ZZIP_HAVE_IO_H 1 -#endif - -/* Define to 1 if you have the header file. */ -#ifndef ZZIP_HAVE_MEMORY_H -#define ZZIP_HAVE_MEMORY_H 1 -#endif - -/* Define to 1 if you have the header file, and it defines `DIR'. */ -/* #undef ZZIP_HAVE_NDIR_H */ - -/* Define to 1 if you have the header file. */ -/* #undef ZZIP_HAVE_STDINT_H */ - -/* Define to 1 if you have the header file. */ -#ifndef ZZIP_HAVE_STDLIB_H -#define ZZIP_HAVE_STDLIB_H 1 -#endif - -/* Define to 1 if you have the `strcasecmp' function. */ -/* #undef ZZIP_HAVE_STRCASECMP */ - -/* Define to 1 if you have the header file. */ -/* #undef ZZIP_HAVE_STRINGS_H */ - -/* Define to 1 if you have the header file. */ -#ifndef ZZIP_HAVE_STRING_H -#define ZZIP_HAVE_STRING_H 1 -#endif - -/* Define to 1 if you have the `strndup' function. */ -/* #undef ZZIP_HAVE_STRNDUP */ - -/* Define to 1 if you have the header file, and it defines `DIR'. - */ -/* #undef ZZIP_HAVE_SYS_DIR_H */ - -/* Define to 1 if you have the header file. */ -/* #undef ZZIP_HAVE_SYS_INT_TYPES_H */ - -/* Define to 1 if you have the header file. */ -/* #undef ZZIP_HAVE_SYS_MMAN_H */ - -/* Define to 1 if you have the header file, and it defines `DIR'. - */ -/* #undef ZZIP_HAVE_SYS_NDIR_H */ - -/* Define to 1 if you have the header file. */ -/* #undef ZZIP_HAVE_SYS_PARAM_H */ - -/* Define to 1 if you have the header file. */ -#ifndef ZZIP_HAVE_SYS_STAT_H -#define ZZIP_HAVE_SYS_STAT_H 1 -#endif - -/* Define to 1 if you have the header file. */ -#ifndef ZZIP_HAVE_SYS_TYPES_H -#define ZZIP_HAVE_SYS_TYPES_H 1 -#endif - -/* Define to 1 if you have the header file. */ -/* #undef ZZIP_HAVE_UNISTD_H */ - -/* Define to 1 if you have the header file. */ -#ifndef ZZIP_HAVE_WINBASE_H -#define ZZIP_HAVE_WINBASE_H 1 /* hmm, is that win32 ? */ -#endif - -/* Define to 1 if you have the header file. */ -#ifndef ZZIP_HAVE_WINDOWS_H -#define ZZIP_HAVE_WINDOWS_H 1 /* yes, this is windows */ -#endif - -/* Define to 1 if you have the header file. */ -#ifndef ZZIP_HAVE_WINNT_H -#define ZZIP_HAVE_WINNT_H 1 /* is that always true? */ -#endif - -/* Define to 1 if you have the header file. */ -#ifndef ZZIP_HAVE_ZLIB_H -#define ZZIP_HAVE_ZLIB_H 1 /* you do have it, right? */ -#endif - -/* whether the system defaults to 32bit off_t but can do 64bit when requested - */ -/* #undef ZZIP_LARGEFILE_SENSITIVE */ - -/* Name of package */ -#ifndef ZZIP_PACKAGE -#define ZZIP_PACKAGE "zziplib-msvc" /* yes, make it known */ -#endif - -/* Define to the address where bug reports for this package should be sent. */ -/* #undef ZZIP_PACKAGE_BUGREPORT */ - -/* Define to the full name of this package. */ -/* #undef ZZIP_PACKAGE_NAME */ - -/* Define to the full name and version of this package. */ -/* #undef ZZIP_PACKAGE_STRING */ - -/* Define to the one symbol short name of this package. */ -/* #undef ZZIP_PACKAGE_TARNAME */ - -/* Define to the version of this package. */ -/* #undef ZZIP_PACKAGE_VERSION */ - -/* The number of bytes in type int */ -#ifndef ZZIP_SIZEOF_INT -#define ZZIP_SIZEOF_INT 4 -#endif - -/* The number of bytes in type long */ -#ifndef ZZIP_SIZEOF_LONG -#define ZZIP_SIZEOF_LONG 4 -#endif - -/* The number of bytes in type short */ -#ifndef ZZIP_SIZEOF_SHORT -#define ZZIP_SIZEOF_SHORT 2 -#endif - -/* Define to 1 if you have the ANSI C header files. */ -#ifndef ZZIP_STDC_HEADERS -#define ZZIP_STDC_HEADERS 1 -#endif - -/* Version number of package */ -#ifndef ZZIP_VERSION -#define ZZIP_VERSION "0.13.x" -#endif - -/* Define to 1 if your processor stores words with the most significant byte - first (like Motorola and SPARC, unlike Intel and VAX). */ -/* #undef ZZIP_WORDS_BIGENDIAN */ - -/* Number of bits in a file offset, on hosts where this is settable. */ -/* #undef ZZIP__FILE_OFFSET_BITS */ - -/* Define for large files, on AIX-style hosts. */ -/* #undef ZZIP__LARGE_FILES */ - -/* Define to `long long' if does not define. */ -/* #undef ZZIP___int64 */ - -/* Define to empty if `const' does not conform to ANSI C. */ -/* #undef _zzip_const */ - -/* Define to `__inline__' or `__inline' if that's what the C compiler - calls it, or to nothing if 'inline' is not supported under any name. */ -#ifndef __cplusplus -#ifndef _zzip_inline -#define _zzip_inline __inline -#endif -#endif - -/* Define to `_zzip_off_t' if does not define. */ -#ifndef _zzip_off64_t -#define _zzip_off64_t __int64 -#endif - -/* Define to `long' if does not define. */ -#ifndef _zzip_off_t -#define _zzip_off_t long -#endif - -/* Define to equivalent of C99 restrict keyword, or to nothing if this is not - supported. Do not define if restrict is supported directly. */ -#ifndef _zzip_restrict -#define _zzip_restrict -#endif - -/* Define to `unsigned' if does not define. */ -/* #undef _zzip_size_t */ - -/* Define to `int' if does not define. */ -#ifndef _zzip_ssize_t -#define _zzip_ssize_t int -#endif - -/* once: _ZZIP__MSVC_H */ -#endif +#ifndef _ZZIP__MSVC_H +#define _ZZIP__MSVC_H 1 + +#define _zzip_calltype __cdecl + +/* zzip/_msvc.h. Generated automatically at end of configure. */ +/* config.h.in. Generated from configure.ac by autoheader. */ + +/* Define to 1 if you have the header file. */ +/* #undef ZZIP_HAVE_BYTESWAP_H */ + +/* Define to 1 if you have the header file. */ +#ifndef ZZIP_HAVE_DIRECT_H +#define ZZIP_HAVE_DIRECT_H 1 +#endif + +/* Define to 1 if you have the header file, and it defines `DIR'. + */ +/* #undef ZZIP_HAVE_DIRENT_H */ + +/* Define to 1 if you have the header file. */ +/* #undef ZZIP_HAVE_DLFCN_H */ + +/* Define to 1 if you have the header file. */ +/* #undef ZZIP_HAVE_FNMATCH_H */ + +/* Define to 1 if you have the header file. */ +/* #undef ZZIP_HAVE_INTTYPES_H */ + +/* Define to 1 if you have the header file. */ +#ifndef ZZIP_HAVE_IO_H +#define ZZIP_HAVE_IO_H 1 +#endif + +/* Define to 1 if you have the header file. */ +#ifndef ZZIP_HAVE_MEMORY_H +#define ZZIP_HAVE_MEMORY_H 1 +#endif + +/* Define to 1 if you have the header file, and it defines `DIR'. */ +/* #undef ZZIP_HAVE_NDIR_H */ + +/* Define to 1 if you have the header file. */ +/* #undef ZZIP_HAVE_STDINT_H */ + +/* Define to 1 if you have the header file. */ +#ifndef ZZIP_HAVE_STDLIB_H +#define ZZIP_HAVE_STDLIB_H 1 +#endif + +/* Define to 1 if you have the `strcasecmp' function. */ +/* #undef ZZIP_HAVE_STRCASECMP */ + +/* Define to 1 if you have the header file. */ +/* #undef ZZIP_HAVE_STRINGS_H */ + +/* Define to 1 if you have the header file. */ +#ifndef ZZIP_HAVE_STRING_H +#define ZZIP_HAVE_STRING_H 1 +#endif + +/* Define to 1 if you have the `strndup' function. */ +/* #undef ZZIP_HAVE_STRNDUP */ + +/* Define to 1 if you have the header file, and it defines `DIR'. + */ +/* #undef ZZIP_HAVE_SYS_DIR_H */ + +/* Define to 1 if you have the header file. */ +/* #undef ZZIP_HAVE_SYS_INT_TYPES_H */ + +/* Define to 1 if you have the header file. */ +/* #undef ZZIP_HAVE_SYS_MMAN_H */ + +/* Define to 1 if you have the header file, and it defines `DIR'. + */ +/* #undef ZZIP_HAVE_SYS_NDIR_H */ + +/* Define to 1 if you have the header file. */ +/* #undef ZZIP_HAVE_SYS_PARAM_H */ + +/* Define to 1 if you have the header file. */ +#ifndef ZZIP_HAVE_SYS_STAT_H +#define ZZIP_HAVE_SYS_STAT_H 1 +#endif + +/* Define to 1 if you have the header file. */ +#ifndef ZZIP_HAVE_SYS_TYPES_H +#define ZZIP_HAVE_SYS_TYPES_H 1 +#endif + +/* Define to 1 if you have the header file. */ +/* #undef ZZIP_HAVE_UNISTD_H */ + +/* Define to 1 if you have the header file. */ +#ifndef ZZIP_HAVE_WINBASE_H +#define ZZIP_HAVE_WINBASE_H 1 /* hmm, is that win32 ? */ +#endif + +/* Define to 1 if you have the header file. */ +#ifndef ZZIP_HAVE_WINDOWS_H +#define ZZIP_HAVE_WINDOWS_H 1 /* yes, this is windows */ +#endif + +/* Define to 1 if you have the header file. */ +#ifndef ZZIP_HAVE_WINNT_H +#define ZZIP_HAVE_WINNT_H 1 /* is that always true? */ +#endif + +/* Define to 1 if you have the header file. */ +#ifndef ZZIP_HAVE_ZLIB_H +#define ZZIP_HAVE_ZLIB_H 1 /* you do have it, right? */ +#endif + +/* whether the system defaults to 32bit off_t but can do 64bit when requested + */ +/* #undef ZZIP_LARGEFILE_SENSITIVE */ + +/* Name of package */ +#ifndef ZZIP_PACKAGE +#define ZZIP_PACKAGE "zziplib-msvc" /* yes, make it known */ +#endif + +/* Define to the address where bug reports for this package should be sent. */ +/* #undef ZZIP_PACKAGE_BUGREPORT */ + +/* Define to the full name of this package. */ +/* #undef ZZIP_PACKAGE_NAME */ + +/* Define to the full name and version of this package. */ +/* #undef ZZIP_PACKAGE_STRING */ + +/* Define to the one symbol short name of this package. */ +/* #undef ZZIP_PACKAGE_TARNAME */ + +/* Define to the version of this package. */ +/* #undef ZZIP_PACKAGE_VERSION */ + +/* The number of bytes in type int */ +#ifndef ZZIP_SIZEOF_INT +#define ZZIP_SIZEOF_INT 4 +#endif + +/* The number of bytes in type long */ +#ifndef ZZIP_SIZEOF_LONG +#define ZZIP_SIZEOF_LONG 4 +#endif + +/* The number of bytes in type short */ +#ifndef ZZIP_SIZEOF_SHORT +#define ZZIP_SIZEOF_SHORT 2 +#endif + +/* Define to 1 if you have the ANSI C header files. */ +#ifndef ZZIP_STDC_HEADERS +#define ZZIP_STDC_HEADERS 1 +#endif + +/* Version number of package */ +#ifndef ZZIP_VERSION +#define ZZIP_VERSION "0.13.x" +#endif + +/* Define to 1 if your processor stores words with the most significant byte + first (like Motorola and SPARC, unlike Intel and VAX). */ +/* #undef ZZIP_WORDS_BIGENDIAN */ + +/* Number of bits in a file offset, on hosts where this is settable. */ +/* #undef ZZIP__FILE_OFFSET_BITS */ + +/* Define for large files, on AIX-style hosts. */ +/* #undef ZZIP__LARGE_FILES */ + +/* Define to `long long' if does not define. */ +/* #undef ZZIP___int64 */ + +/* Define to empty if `const' does not conform to ANSI C. */ +/* #undef _zzip_const */ + +/* Define to `__inline__' or `__inline' if that's what the C compiler + calls it, or to nothing if 'inline' is not supported under any name. */ +#ifndef __cplusplus +#ifndef _zzip_inline +#define _zzip_inline __inline +#endif +#endif + +/* Define to `_zzip_off_t' if does not define. */ +#ifndef _zzip_off64_t +#define _zzip_off64_t __int64 +#endif + +/* Define to `long' if does not define. */ +#ifndef _zzip_off_t +#define _zzip_off_t long +#endif + +/* Define to equivalent of C99 restrict keyword, or to nothing if this is not + supported. Do not define if restrict is supported directly. */ +#ifndef _zzip_restrict +#define _zzip_restrict +#endif + +/* Define to `unsigned' if does not define. */ +/* #undef _zzip_size_t */ + +/* Define to `int' if does not define. */ +#ifndef _zzip_ssize_t +#define _zzip_ssize_t int +#endif + +/* once: _ZZIP__MSVC_H */ +#endif diff --git a/desmume/src/windows/zziplib/zzip/conf.h b/src/windows/zziplib/zzip/conf.h similarity index 92% rename from desmume/src/windows/zziplib/zzip/conf.h rename to src/windows/zziplib/zzip/conf.h index 640b0d9d0..7c3b2d89c 100644 --- a/desmume/src/windows/zziplib/zzip/conf.h +++ b/src/windows/zziplib/zzip/conf.h @@ -1,540 +1,540 @@ -/* - - * Here we postprocess autoconf generated prefix-config.h entries. - - * This is generally for things like "off_t" which is left undefined - - * in plain config.h if the host system does already have it but we do - - * need the prefix variant - so we add here a #define _zzip_off_t off_t - - * - - * This file is supposed to only carry '#define's. - - * See for definitions that might be seen by the compiler. - - * - - * Author: - - * Guido Draheim - - * - - * Copyright (c) 2001,2002,2003,2004 Guido Draheim - - * All rights reserved, - - * use under the restrictions of the - - * Lesser GNU General Public License - - * or alternatively the restrictions - - * of the Mozilla Public License 1.1 - - */ - - - -#ifndef _ZZIP_CONF_H - -#define _ZZIP_CONF_H 1 - - - -#if !defined ZZIP_OMIT_CONFIG_H - -# if defined _MSC_VER || defined __BORLANDC__ || defined __WATCOMC__ - -# include - -# elif defined ZZIP_1_H - -# include "zzip-1.h" - -# elif defined ZZIP_2_H - -# include "zzip-2.h" - -# elif defined ZZIP_3_H - -# include "zzip-3.h" - -# elif defined ZZIP_4_H - -# include "zzip-4.h" - -# elif defined ZZIP_5_H - -# include "zzip-5.h" - -# else /* autoconf generated */ - -# include - -# endif - -#endif - - - -/* especially win32 platforms do not declare off_t so far - see zzip-msvc.h */ - -#ifndef _zzip_off_t - -#ifdef ZZIP_off_t - -#define _zzip_off_t ZZIP_off_t - -#else - -#define _zzip_off_t off_t - -#endif - -#endif - - - -#ifndef _zzip_off64_t - -#ifdef ZZIP_off64_t - -#define _zzip_off64_t ZZIP_off64_t - -#else - -#define _zzip_off64_t off64_t - -#endif - -#endif - - - -/* currently unused, all current zziplib-users do have ansi-C94 compilers. */ - -#ifndef _zzip_const - -#ifdef ZZIP_const - -#define _zzip_const ZZIP_const - -#else - -#define _zzip_const const - -#endif - -#endif - -#ifndef _zzip_inline - -#ifdef ZZIP_inline - -#define _zzip_inline ZZIP_inline - -#else - -#define _zzip_inline inline - -#endif - -#endif - -#ifndef _zzip_restrict - -#ifdef ZZIP_restrict - -#define _zzip_restrict ZZIP_restrict - -#else - -#define _zzip_restrict restrict - -#endif - -#endif - -#if defined __linux__ && __GNUC__+0 >= 4 - -#define zzip__new__ __attribute__((malloc)) - -#elif defined __linux__ && __GNUC__+0 >= 3 && __GNUC_MINOR_+0 >= 3 - -#define zzip__new__ __attribute__((malloc)) - -#else - -#define zzip__new__ - -#endif - - - -#ifndef _zzip_size_t - -#ifdef ZZIP_size_t - -#define _zzip_size_t ZZIP_size_t - -#else - -#define _zzip_size_t size_t - -#endif - -#endif - -#ifndef _zzip_ssize_t - -#ifdef ZZIP_ssize_t - -#define _zzip_ssize_t ZZIP_ssize_t - -#else - -#define _zzip_ssize_t ssize_t - -#endif - -#endif - -#ifndef _zzip___int64 - -#ifdef ZZIP___int64 - -#define _zzip___int64 ZZIP___int64 - -#else - -#define _zzip___int64 long long - -#endif - -#endif - - - -/* whether this library shall use a 64bit off_t largefile variant in 64on32: */ - -/* (some exported names must be renamed to avoid bad calls after linking) */ - -#if defined ZZIP_LARGEFILE_SENSITIVE - -# if _FILE_OFFSET_BITS+0 == 64 - -# define ZZIP_LARGEFILE_RENAME - -# elif defined _LARGE_FILES /* used on older AIX to get at 64bit off_t */ - -# define ZZIP_LARGEFILE_RENAME - -# elif defined _ZZIP_LARGEFILE /* or simply use this one for zzip64 runs */ - -# define ZZIP_LARGEFILE_RENAME - -# endif - -#endif - - - -/* if the environment did not setup these for 64bit off_t largefile... */ - -#ifdef ZZIP_LARGEFILE_RENAME - -# ifndef _FILE_OFFSET_BITS - -# ifdef ZZIP__FILE_OFFSET_BITS /* == 64 */ - -# define _FILE_OFFSET_BITS ZZIP__FILE_OFFSET_BITS - -# endif - -# endif - -# ifndef _LARGE_FILES - -# ifdef ZZIP__LARGE_FILES /* == 1 */ - -# define _LARGE_FILES ZZIP__LARGE_FILES - -# endif - -# endif - -# ifndef _LARGEFILE_SOURCE - -# ifdef ZZIP__LARGEFILE_SOURCE /* == 1 */ - -# define _LARGEFILE_SOURCE ZZIP__LARGEFILE_SOURCE - -# endif - -# endif - -#endif - - - -#include - - - -/* mingw32msvc errno : would be in winsock.h */ - -#ifndef EREMOTE - -#define EREMOTE ESPIPE - -#endif - - - -#ifndef ELOOP - -#if defined EILSEQ - -#define ELOOP EILSEQ - -#else - -#define ELOOP ENOEXEC - -#endif - -#endif - - - -#if defined __WATCOMC__ - -#undef _zzip_inline - -#define _zzip_inline static - -#endif - - - -#if defined _MSC_VER || defined __WATCOMC__ - -#include - -#endif - - - -#ifdef _MSC_VER - -# if !__STDC__ - -# ifndef _zzip_lseek - -# define _zzip_lseek _lseek - -# endif - -# ifndef _zzip_read - -# define _zzip_read _read - -# endif - -# ifndef _zzip_write - -# define _zzip_write _write - -# endif - -# if 0 - -# ifndef _zzip_stat - -# define _zzip_stat _stat - -# endif - -# endif - -# endif /* !__STDC__ */ - -#endif - - /*MSVC*/ - - - -#if defined _MSC_VER || defined __WATCOMC__ - -# ifndef strcasecmp - -# define strcasecmp _stricmp - -# endif - -#endif - - - -# ifndef _zzip_lseek - -# define _zzip_lseek lseek - -# endif - - - -# ifndef _zzip_read - -# define _zzip_read read - -# endif - - - -# ifndef _zzip_write - -# define _zzip_write write - -# endif - - - -# if 0 - -# ifndef _zzip_stat - -# define _zzip_stat stat - -# endif - -# endif - - - - - -#if defined __GNUC__ || defined __attribute__ - -#define __zzip_attribute__(X) __attribute__(X) - -#else - -#define __zzip_attribute__(X) - -#endif - - - -#if defined ZZIP_EXPORTS || defined ZZIPLIB_EXPORTS - -# undef ZZIP_DLL - -#define ZZIP_DLL 1 - -#endif - - - -/* based on zconf.h : */ - -/* compile with -DZZIP_DLL for Windows DLL support */ - -#if defined ZZIP_DLL - -# if defined _WINDOWS || defined WINDOWS || defined _WIN32 - -/*# include */ - -# endif - -# if !defined _zzip_export && defined _MSC_VER && (defined WIN32 || defined _WIN32) - -# define _zzip_export __declspec(dllexport) /*WINAPI*/ - -# endif - -# if !defined _zzip_export && defined __BORLANDC__ - -# if __BORLANDC__ >= 0x0500 && defined WIN32 - -# include - -# define _zzip_export __declspec(dllexport) /*WINAPI*/ - -# else - -# if defined _Windows && defined __DLL__ - -# define _zzip_export _export - -# endif - -# endif - -# endif - -# if !defined _zzip_export && defined __GNUC__ - -# if defined __declspec - -# define _zzip_export extern __declspec(dllexport) - -# else - -# define _zzip_export extern - -# endif - -# endif - -# if !defined _zzip_export && defined __BEOS__ - -# define _zzip_export extern __declspec(export) - -# endif - -# if !defined _zzip_export && defined __WATCOMC__ - -# define _zzip_export extern __declspec(dllexport) - -# define ZEXPORT __syscall - -# define ZEXTERN extern - -# endif - -#endif - - - -#if !defined _zzip_export - -# if defined __GNUC__ /* || !defined HAVE_LIBZZIP */ - -# define _zzip_export extern - -# elif defined __declspec || (defined _MSC_VER && defined ZZIP_DLL) - -# define _zzip_export extern __declspec(dllimport) - -# else - -# define _zzip_export extern - -# endif - -#endif - - - -#endif - - - - - +/* + + * Here we postprocess autoconf generated prefix-config.h entries. + + * This is generally for things like "off_t" which is left undefined + + * in plain config.h if the host system does already have it but we do + + * need the prefix variant - so we add here a #define _zzip_off_t off_t + + * + + * This file is supposed to only carry '#define's. + + * See for definitions that might be seen by the compiler. + + * + + * Author: + + * Guido Draheim + + * + + * Copyright (c) 2001,2002,2003,2004 Guido Draheim + + * All rights reserved, + + * use under the restrictions of the + + * Lesser GNU General Public License + + * or alternatively the restrictions + + * of the Mozilla Public License 1.1 + + */ + + + +#ifndef _ZZIP_CONF_H + +#define _ZZIP_CONF_H 1 + + + +#if !defined ZZIP_OMIT_CONFIG_H + +# if defined _MSC_VER || defined __BORLANDC__ || defined __WATCOMC__ + +# include + +# elif defined ZZIP_1_H + +# include "zzip-1.h" + +# elif defined ZZIP_2_H + +# include "zzip-2.h" + +# elif defined ZZIP_3_H + +# include "zzip-3.h" + +# elif defined ZZIP_4_H + +# include "zzip-4.h" + +# elif defined ZZIP_5_H + +# include "zzip-5.h" + +# else /* autoconf generated */ + +# include + +# endif + +#endif + + + +/* especially win32 platforms do not declare off_t so far - see zzip-msvc.h */ + +#ifndef _zzip_off_t + +#ifdef ZZIP_off_t + +#define _zzip_off_t ZZIP_off_t + +#else + +#define _zzip_off_t off_t + +#endif + +#endif + + + +#ifndef _zzip_off64_t + +#ifdef ZZIP_off64_t + +#define _zzip_off64_t ZZIP_off64_t + +#else + +#define _zzip_off64_t off64_t + +#endif + +#endif + + + +/* currently unused, all current zziplib-users do have ansi-C94 compilers. */ + +#ifndef _zzip_const + +#ifdef ZZIP_const + +#define _zzip_const ZZIP_const + +#else + +#define _zzip_const const + +#endif + +#endif + +#ifndef _zzip_inline + +#ifdef ZZIP_inline + +#define _zzip_inline ZZIP_inline + +#else + +#define _zzip_inline inline + +#endif + +#endif + +#ifndef _zzip_restrict + +#ifdef ZZIP_restrict + +#define _zzip_restrict ZZIP_restrict + +#else + +#define _zzip_restrict restrict + +#endif + +#endif + +#if defined __linux__ && __GNUC__+0 >= 4 + +#define zzip__new__ __attribute__((malloc)) + +#elif defined __linux__ && __GNUC__+0 >= 3 && __GNUC_MINOR_+0 >= 3 + +#define zzip__new__ __attribute__((malloc)) + +#else + +#define zzip__new__ + +#endif + + + +#ifndef _zzip_size_t + +#ifdef ZZIP_size_t + +#define _zzip_size_t ZZIP_size_t + +#else + +#define _zzip_size_t size_t + +#endif + +#endif + +#ifndef _zzip_ssize_t + +#ifdef ZZIP_ssize_t + +#define _zzip_ssize_t ZZIP_ssize_t + +#else + +#define _zzip_ssize_t ssize_t + +#endif + +#endif + +#ifndef _zzip___int64 + +#ifdef ZZIP___int64 + +#define _zzip___int64 ZZIP___int64 + +#else + +#define _zzip___int64 long long + +#endif + +#endif + + + +/* whether this library shall use a 64bit off_t largefile variant in 64on32: */ + +/* (some exported names must be renamed to avoid bad calls after linking) */ + +#if defined ZZIP_LARGEFILE_SENSITIVE + +# if _FILE_OFFSET_BITS+0 == 64 + +# define ZZIP_LARGEFILE_RENAME + +# elif defined _LARGE_FILES /* used on older AIX to get at 64bit off_t */ + +# define ZZIP_LARGEFILE_RENAME + +# elif defined _ZZIP_LARGEFILE /* or simply use this one for zzip64 runs */ + +# define ZZIP_LARGEFILE_RENAME + +# endif + +#endif + + + +/* if the environment did not setup these for 64bit off_t largefile... */ + +#ifdef ZZIP_LARGEFILE_RENAME + +# ifndef _FILE_OFFSET_BITS + +# ifdef ZZIP__FILE_OFFSET_BITS /* == 64 */ + +# define _FILE_OFFSET_BITS ZZIP__FILE_OFFSET_BITS + +# endif + +# endif + +# ifndef _LARGE_FILES + +# ifdef ZZIP__LARGE_FILES /* == 1 */ + +# define _LARGE_FILES ZZIP__LARGE_FILES + +# endif + +# endif + +# ifndef _LARGEFILE_SOURCE + +# ifdef ZZIP__LARGEFILE_SOURCE /* == 1 */ + +# define _LARGEFILE_SOURCE ZZIP__LARGEFILE_SOURCE + +# endif + +# endif + +#endif + + + +#include + + + +/* mingw32msvc errno : would be in winsock.h */ + +#ifndef EREMOTE + +#define EREMOTE ESPIPE + +#endif + + + +#ifndef ELOOP + +#if defined EILSEQ + +#define ELOOP EILSEQ + +#else + +#define ELOOP ENOEXEC + +#endif + +#endif + + + +#if defined __WATCOMC__ + +#undef _zzip_inline + +#define _zzip_inline static + +#endif + + + +#if defined _MSC_VER || defined __WATCOMC__ + +#include + +#endif + + + +#ifdef _MSC_VER + +# if !__STDC__ + +# ifndef _zzip_lseek + +# define _zzip_lseek _lseek + +# endif + +# ifndef _zzip_read + +# define _zzip_read _read + +# endif + +# ifndef _zzip_write + +# define _zzip_write _write + +# endif + +# if 0 + +# ifndef _zzip_stat + +# define _zzip_stat _stat + +# endif + +# endif + +# endif /* !__STDC__ */ + +#endif + + /*MSVC*/ + + + +#if defined _MSC_VER || defined __WATCOMC__ + +# ifndef strcasecmp + +# define strcasecmp _stricmp + +# endif + +#endif + + + +# ifndef _zzip_lseek + +# define _zzip_lseek lseek + +# endif + + + +# ifndef _zzip_read + +# define _zzip_read read + +# endif + + + +# ifndef _zzip_write + +# define _zzip_write write + +# endif + + + +# if 0 + +# ifndef _zzip_stat + +# define _zzip_stat stat + +# endif + +# endif + + + + + +#if defined __GNUC__ || defined __attribute__ + +#define __zzip_attribute__(X) __attribute__(X) + +#else + +#define __zzip_attribute__(X) + +#endif + + + +#if defined ZZIP_EXPORTS || defined ZZIPLIB_EXPORTS + +# undef ZZIP_DLL + +#define ZZIP_DLL 1 + +#endif + + + +/* based on zconf.h : */ + +/* compile with -DZZIP_DLL for Windows DLL support */ + +#if defined ZZIP_DLL + +# if defined _WINDOWS || defined WINDOWS || defined _WIN32 + +/*# include */ + +# endif + +# if !defined _zzip_export && defined _MSC_VER && (defined WIN32 || defined _WIN32) + +# define _zzip_export __declspec(dllexport) /*WINAPI*/ + +# endif + +# if !defined _zzip_export && defined __BORLANDC__ + +# if __BORLANDC__ >= 0x0500 && defined WIN32 + +# include + +# define _zzip_export __declspec(dllexport) /*WINAPI*/ + +# else + +# if defined _Windows && defined __DLL__ + +# define _zzip_export _export + +# endif + +# endif + +# endif + +# if !defined _zzip_export && defined __GNUC__ + +# if defined __declspec + +# define _zzip_export extern __declspec(dllexport) + +# else + +# define _zzip_export extern + +# endif + +# endif + +# if !defined _zzip_export && defined __BEOS__ + +# define _zzip_export extern __declspec(export) + +# endif + +# if !defined _zzip_export && defined __WATCOMC__ + +# define _zzip_export extern __declspec(dllexport) + +# define ZEXPORT __syscall + +# define ZEXTERN extern + +# endif + +#endif + + + +#if !defined _zzip_export + +# if defined __GNUC__ /* || !defined HAVE_LIBZZIP */ + +# define _zzip_export extern + +# elif defined __declspec || (defined _MSC_VER && defined ZZIP_DLL) + +# define _zzip_export extern __declspec(dllimport) + +# else + +# define _zzip_export extern + +# endif + +#endif + + + +#endif + + + + + diff --git a/desmume/src/windows/zziplib/zzip/types.h b/src/windows/zziplib/zzip/types.h similarity index 97% rename from desmume/src/windows/zziplib/zzip/types.h rename to src/windows/zziplib/zzip/types.h index 6f9c6e6f9..0f570e2b4 100644 --- a/desmume/src/windows/zziplib/zzip/types.h +++ b/src/windows/zziplib/zzip/types.h @@ -1,57 +1,57 @@ -/* - * unlike in we are allowed to make up typedefs here, - * while over there only #defines are allowed - * - * Author: - * Guido Draheim - * - * Copyright (c) 2003,2004 Guido Draheim - * All rights reserved, - * usage allowed under the restrictions of the - * Lesser GNU General Public License - * or alternatively the restrictions - * of the Mozilla Public License 1.1 - * - * This file is usually the first to define some real symbols. If you do - * see some errors here then it is most likely the includepath is wrong - * or some includeheader is missing / unreadable on your system. - * (a) we include local headers with a "zzip/" prefix just to be sure - * to not actually get the wrong one. Consider to add `-I..` somewhere - * and especially VC/IDE users (who make up their own workspace files) - * should include the root source directory of this project. - * (b) size_t and ssize_t are sometimes found be `configure` but they are - * not in the usual places (ANSI C = stddef.h; UNIX = sys/types.h), so - * be sure to look for them and add the respective header as an #include. - */ - -#ifndef _ZZIP_TYPES_H_ -#define _ZZIP_TYPES_H_ - -#include -#include -#include /* size_t and friends */ -#ifdef ZZIP_HAVE_SYS_TYPES_H -#include /* bsd (mac) has size_t here */ -#endif -/* msvc6 has neither ssize_t (we assume "int") nor off_t (assume "long") */ - -typedef unsigned char zzip_byte_t; // especially zlib decoding data - -typedef _zzip_off64_t zzip_off64_t; -typedef _zzip_off_t zzip_off_t; -typedef _zzip_size_t zzip_size_t; /* Some error here? */ -typedef _zzip_ssize_t zzip_ssize_t; /* See notes above! */ - -/* in */ -typedef struct zzip_disk64_trailer ZZIP_DISK64_TRAILER; -typedef struct zzip_disk_trailer ZZIP_DISK_TRAILER; -typedef struct zzip_file_trailer ZZIP_FILE_TRAILER; -typedef struct zzip_root_dirent ZZIP_ROOT_DIRENT; -typedef struct zzip_file_header ZZIP_FILE_HEADER; -typedef struct zzip_disk_entry ZZIP_DISK_ENTRY; -typedef struct zzip_extra_block ZZIP_EXTRA_BLOCK; - - - -#endif - +/* + * unlike in we are allowed to make up typedefs here, + * while over there only #defines are allowed + * + * Author: + * Guido Draheim + * + * Copyright (c) 2003,2004 Guido Draheim + * All rights reserved, + * usage allowed under the restrictions of the + * Lesser GNU General Public License + * or alternatively the restrictions + * of the Mozilla Public License 1.1 + * + * This file is usually the first to define some real symbols. If you do + * see some errors here then it is most likely the includepath is wrong + * or some includeheader is missing / unreadable on your system. + * (a) we include local headers with a "zzip/" prefix just to be sure + * to not actually get the wrong one. Consider to add `-I..` somewhere + * and especially VC/IDE users (who make up their own workspace files) + * should include the root source directory of this project. + * (b) size_t and ssize_t are sometimes found be `configure` but they are + * not in the usual places (ANSI C = stddef.h; UNIX = sys/types.h), so + * be sure to look for them and add the respective header as an #include. + */ + +#ifndef _ZZIP_TYPES_H_ +#define _ZZIP_TYPES_H_ + +#include +#include +#include /* size_t and friends */ +#ifdef ZZIP_HAVE_SYS_TYPES_H +#include /* bsd (mac) has size_t here */ +#endif +/* msvc6 has neither ssize_t (we assume "int") nor off_t (assume "long") */ + +typedef unsigned char zzip_byte_t; // especially zlib decoding data + +typedef _zzip_off64_t zzip_off64_t; +typedef _zzip_off_t zzip_off_t; +typedef _zzip_size_t zzip_size_t; /* Some error here? */ +typedef _zzip_ssize_t zzip_ssize_t; /* See notes above! */ + +/* in */ +typedef struct zzip_disk64_trailer ZZIP_DISK64_TRAILER; +typedef struct zzip_disk_trailer ZZIP_DISK_TRAILER; +typedef struct zzip_file_trailer ZZIP_FILE_TRAILER; +typedef struct zzip_root_dirent ZZIP_ROOT_DIRENT; +typedef struct zzip_file_header ZZIP_FILE_HEADER; +typedef struct zzip_disk_entry ZZIP_DISK_ENTRY; +typedef struct zzip_extra_block ZZIP_EXTRA_BLOCK; + + + +#endif + diff --git a/desmume/src/windows/zziplib/zzip/zzip.h b/src/windows/zziplib/zzip/zzip.h similarity index 96% rename from desmume/src/windows/zziplib/zzip/zzip.h rename to src/windows/zziplib/zzip/zzip.h index 80cfc0cec..94adc49f7 100644 --- a/desmume/src/windows/zziplib/zzip/zzip.h +++ b/src/windows/zziplib/zzip/zzip.h @@ -1,268 +1,268 @@ -/* - * Author: - * Guido Draheim - * Tomi Ollila - * - * Copyright (c) 1999,2000,2001,2002,2003,2004 Guido Draheim - * All rights reserved, - * usage allowed under the restrictions of the - * Lesser GNU General Public License - * or alternatively the restrictions - * of the Mozilla Public License 1.1 - * - * if you see "unknown symbol" errors, check first that `-I ..` is part of - * your compiler options - a special hint to VC/IDE users who tend to make up - * their own workspace files. All includes look like #include , so - * you need to add an include path to the dir containing (!!) the ./zzip/ dir - */ - -#ifndef _ZZIP_ZZIP_H /* zziplib.h */ -#define _ZZIP_ZZIP_H - -#include - -#ifdef __cplusplus -extern "C" { -#endif - -/* the zzip_error_t is also used to pass back ZLIB errors... */ -#define ZZIP_ERROR -4096 - -typedef enum -{ - ZZIP_NO_ERROR = 0, /* no error, may be used if user sets it. */ - ZZIP_OUTOFMEM = ZZIP_ERROR-20, /* out of memory */ - ZZIP_DIR_OPEN = ZZIP_ERROR-21, /* failed to open zipfile, see errno for details */ - ZZIP_DIR_STAT = ZZIP_ERROR-22, /* failed to fstat zipfile, see errno for details */ - ZZIP_DIR_SEEK = ZZIP_ERROR-23, /* failed to lseek zipfile, see errno for details */ - ZZIP_DIR_READ = ZZIP_ERROR-24, /* failed to read zipfile, see errno for details */ - ZZIP_DIR_TOO_SHORT = ZZIP_ERROR-25, - ZZIP_DIR_EDH_MISSING = ZZIP_ERROR-26, - ZZIP_DIRSIZE = ZZIP_ERROR-27, - ZZIP_ENOENT = ZZIP_ERROR-28, - ZZIP_UNSUPP_COMPR = ZZIP_ERROR-29, - ZZIP_CORRUPTED = ZZIP_ERROR-31, - ZZIP_UNDEF = ZZIP_ERROR-32, - ZZIP_DIR_LARGEFILE = ZZIP_ERROR-33 -} zzip_error_t; - -/* - * zzip_open flags. - */ -#define ZZIP_CASEINSENSITIVE O_APPEND /* do not use anymore. use CASLESS */ -#define ZZIP_IGNOREPATH O_TRUNC /* do not use anymore. use NOPATHS */ -#define ZZIP_EXTRAFLAGS (ZZIP_CASEINSENSITIVE|ZZIP_IGNOREPATH) - -/* zzip_open_ext_io o_modes flags : new style. use these from now on! */ -#define ZZIP_CASELESS (1<<12) /* ignore filename case inside zips */ -#define ZZIP_NOPATHS (1<<13) /* ignore subdir paths, just filename*/ -#define ZZIP_PREFERZIP (1<<14) /* try first zipped file, then real*/ -#define ZZIP_ONLYZIP (1<<16) /* try _only_ zipped file, skip real*/ -#define ZZIP_FACTORY (1<<17) /* old file handle is not closed */ -#define ZZIP_ALLOWREAL (1<<18) /* real files use default_io (magic) */ -#define ZZIP_THREADED (1<<19) /* try to be safe for multithreading */ - -/* - * zzip largefile renames - */ -#ifdef ZZIP_LARGEFILE_RENAME -#define zzip_telldir zzip_telldir64 -#define zzip_seekdir zzip_seekdir64 -#endif - -/* - * zzip typedefs - */ -/* zzip_strings_t ext[] = { ".zip", ".jar", ".pk3", 0 } */ -typedef char _zzip_const * _zzip_const zzip_strings_t; -typedef char _zzip_const zzip_char_t; -typedef struct zzip_dir ZZIP_DIR; -typedef struct zzip_file ZZIP_FILE; -typedef struct zzip_dirent ZZIP_DIRENT; -typedef struct zzip_dirent ZZIP_STAT; - -struct zzip_dirent -{ - int d_compr; /* compression method */ - int d_csize; /* compressed size */ - int st_size; /* file size / decompressed size */ - char * d_name; /* file name / strdupped name */ -}; - -/* - * Getting error strings - * zzip/err.c - */ -_zzip_export /* error in _opendir : */ -zzip_char_t* _zzip_calltype zzip_strerror(int errcode); -_zzip_export /* error in other functions : */ -zzip_char_t* _zzip_calltype zzip_strerror_of(ZZIP_DIR * dir); -_zzip_export /* error mapped to errno.h defines : */ -int zzip_errno(int errcode); - - -/* - * Functions to grab information from ZZIP_DIR/ZZIP_FILE structure - * (if ever needed) - * zzip/info.c - */ -_zzip_export -int _zzip_calltype zzip_error(ZZIP_DIR * dir); -_zzip_export -void _zzip_calltype zzip_seterror(ZZIP_DIR * dir, int errcode); -_zzip_export -zzip_char_t* zzip_compr_str(int compr); - -_zzip_export -ZZIP_DIR * _zzip_calltype zzip_dirhandle(ZZIP_FILE * fp); -_zzip_export -int _zzip_calltype zzip_dirfd(ZZIP_DIR * dir); -_zzip_export -int _zzip_calltype zzip_dir_real(ZZIP_DIR * dir); -_zzip_export -int _zzip_calltype zzip_file_real(ZZIP_FILE * fp); -_zzip_export -void* _zzip_calltype zzip_realdir(ZZIP_DIR * dir); -_zzip_export -int _zzip_calltype zzip_realfd(ZZIP_FILE * fp); - -/* - * zip handle management - * zzip/zip.c - */ -_zzip_export -ZZIP_DIR * _zzip_calltype zzip_dir_alloc(zzip_strings_t* fileext); -_zzip_export -int _zzip_calltype zzip_dir_free(ZZIP_DIR *); - -/* - * Opening/closing a zip archive - * zzip-zip.c - */ -_zzip_export -ZZIP_DIR * _zzip_calltype zzip_dir_fdopen(int fd, zzip_error_t * errcode_p); -_zzip_export -ZZIP_DIR * _zzip_calltype zzip_dir_open(zzip_char_t* filename, zzip_error_t * errcode_p); -_zzip_export -int _zzip_calltype zzip_dir_close(ZZIP_DIR * dir); -_zzip_export -int _zzip_calltype zzip_dir_read(ZZIP_DIR * dir, ZZIP_DIRENT * dirent); - - -/* - * Scanning files in zip archive - * zzip/dir.c - * zzip/zip.c - */ -_zzip_export -ZZIP_DIR * _zzip_calltype zzip_opendir(zzip_char_t* filename); -_zzip_export -int _zzip_calltype zzip_closedir(ZZIP_DIR * dir); -_zzip_export -ZZIP_DIRENT * _zzip_calltype zzip_readdir(ZZIP_DIR * dir); -_zzip_export -void _zzip_calltype zzip_rewinddir(ZZIP_DIR * dir); -_zzip_export -zzip_off_t _zzip_calltype zzip_telldir(ZZIP_DIR * dir); -_zzip_export -void _zzip_calltype zzip_seekdir(ZZIP_DIR * dir, zzip_off_t offset); - -/* - * 'opening', 'closing' and reading invidual files in zip archive. - * zzip/file.c - */ -_zzip_export -ZZIP_FILE * _zzip_calltype zzip_file_open(ZZIP_DIR * dir, zzip_char_t* name, int flags); -_zzip_export -int _zzip_calltype zzip_file_close(ZZIP_FILE * fp); -_zzip_export -zzip_ssize_t _zzip_calltype zzip_file_read(ZZIP_FILE * fp, void* buf, zzip_size_t len); - -_zzip_export -ZZIP_FILE * _zzip_calltype zzip_open(zzip_char_t* name, int flags); -_zzip_export -int _zzip_calltype zzip_close(ZZIP_FILE * fp); -_zzip_export -zzip_ssize_t _zzip_calltype zzip_read(ZZIP_FILE * fp, void * buf, zzip_size_t len); - -/* - * the stdc variant to open/read/close files. - Take note of the freopen() - * call as it may reuse an existing preparsed copy of a zip central directory - */ -_zzip_export -ZZIP_FILE* _zzip_calltype zzip_freopen(zzip_char_t* name, zzip_char_t* mode, ZZIP_FILE*); -_zzip_export -ZZIP_FILE* _zzip_calltype zzip_fopen(zzip_char_t* name, zzip_char_t* mode); -_zzip_export -zzip_size_t _zzip_calltype zzip_fread(void *ptr, zzip_size_t size, zzip_size_t nmemb, - ZZIP_FILE * file); -_zzip_export -int zzip_fclose(ZZIP_FILE * fp); - -/* - * seek and tell functions - */ -_zzip_export -int _zzip_calltype zzip_rewind(ZZIP_FILE *fp); -_zzip_export -zzip_off_t _zzip_calltype zzip_seek(ZZIP_FILE * fp, zzip_off_t offset, int whence); -_zzip_export -zzip_off_t _zzip_calltype zzip_tell(ZZIP_FILE * fp); - -/* - * reading info of a single file - * zzip/stat.c - */ -_zzip_export -int _zzip_calltype zzip_dir_stat(ZZIP_DIR * dir, zzip_char_t* name, - ZZIP_STAT * zs, int flags); -_zzip_export -int _zzip_calltype zzip_file_stat(ZZIP_FILE * fp, ZZIP_STAT * zs); -_zzip_export -int _zzip_calltype zzip_fstat(ZZIP_FILE * fp, ZZIP_STAT * zs); - -#ifdef ZZIP_LARGEFILE_RENAME -#define zzip_open_shared_io zzip_open_shared_io64 -#define zzip_open_ext_io zzip_open_ext_io64 -#define zzip_opendir_ext_io zzip_opendir_ext_io64 -#define zzip_dir_open_ext_io zzip_dir_open_ext_io64 -#define zzip_plugin_io_t zzip_plugin_io64_t -#endif - -/* - * all ext_io functions can be called with a default of ext/io == zero/zero - * which will default to a ".zip" extension and posix io of the system. - */ -typedef union _zzip_plugin_io _zzip_const * zzip_plugin_io_t; - -_zzip_export -ZZIP_FILE * _zzip_calltype zzip_open_shared_io(ZZIP_FILE* stream, - zzip_char_t* name, int o_flags, int o_modes, - zzip_strings_t* ext, zzip_plugin_io_t io); - -_zzip_export -ZZIP_FILE * _zzip_calltype zzip_open_ext_io(zzip_char_t* name, int o_flags, int o_modes, - zzip_strings_t* ext, zzip_plugin_io_t io); - -_zzip_export -ZZIP_DIR * _zzip_calltype zzip_opendir_ext_io(zzip_char_t* name, int o_modes, - zzip_strings_t* ext, zzip_plugin_io_t io); - -_zzip_export -ZZIP_DIR * _zzip_calltype zzip_dir_open_ext_io(zzip_char_t* filename, - zzip_error_t* errcode_p, - zzip_strings_t* ext, zzip_plugin_io_t io); - -/* zzip_file_open_ext_io => zzip_dir_open_ext_io + zzip_file_open */ - -#ifdef __cplusplus -}; -#endif - -#endif /* _ZZIPLIB_H */ - -/* - * Local variables: - * c-file-style: "stroustrup" - * End: - */ +/* + * Author: + * Guido Draheim + * Tomi Ollila + * + * Copyright (c) 1999,2000,2001,2002,2003,2004 Guido Draheim + * All rights reserved, + * usage allowed under the restrictions of the + * Lesser GNU General Public License + * or alternatively the restrictions + * of the Mozilla Public License 1.1 + * + * if you see "unknown symbol" errors, check first that `-I ..` is part of + * your compiler options - a special hint to VC/IDE users who tend to make up + * their own workspace files. All includes look like #include , so + * you need to add an include path to the dir containing (!!) the ./zzip/ dir + */ + +#ifndef _ZZIP_ZZIP_H /* zziplib.h */ +#define _ZZIP_ZZIP_H + +#include + +#ifdef __cplusplus +extern "C" { +#endif + +/* the zzip_error_t is also used to pass back ZLIB errors... */ +#define ZZIP_ERROR -4096 + +typedef enum +{ + ZZIP_NO_ERROR = 0, /* no error, may be used if user sets it. */ + ZZIP_OUTOFMEM = ZZIP_ERROR-20, /* out of memory */ + ZZIP_DIR_OPEN = ZZIP_ERROR-21, /* failed to open zipfile, see errno for details */ + ZZIP_DIR_STAT = ZZIP_ERROR-22, /* failed to fstat zipfile, see errno for details */ + ZZIP_DIR_SEEK = ZZIP_ERROR-23, /* failed to lseek zipfile, see errno for details */ + ZZIP_DIR_READ = ZZIP_ERROR-24, /* failed to read zipfile, see errno for details */ + ZZIP_DIR_TOO_SHORT = ZZIP_ERROR-25, + ZZIP_DIR_EDH_MISSING = ZZIP_ERROR-26, + ZZIP_DIRSIZE = ZZIP_ERROR-27, + ZZIP_ENOENT = ZZIP_ERROR-28, + ZZIP_UNSUPP_COMPR = ZZIP_ERROR-29, + ZZIP_CORRUPTED = ZZIP_ERROR-31, + ZZIP_UNDEF = ZZIP_ERROR-32, + ZZIP_DIR_LARGEFILE = ZZIP_ERROR-33 +} zzip_error_t; + +/* + * zzip_open flags. + */ +#define ZZIP_CASEINSENSITIVE O_APPEND /* do not use anymore. use CASLESS */ +#define ZZIP_IGNOREPATH O_TRUNC /* do not use anymore. use NOPATHS */ +#define ZZIP_EXTRAFLAGS (ZZIP_CASEINSENSITIVE|ZZIP_IGNOREPATH) + +/* zzip_open_ext_io o_modes flags : new style. use these from now on! */ +#define ZZIP_CASELESS (1<<12) /* ignore filename case inside zips */ +#define ZZIP_NOPATHS (1<<13) /* ignore subdir paths, just filename*/ +#define ZZIP_PREFERZIP (1<<14) /* try first zipped file, then real*/ +#define ZZIP_ONLYZIP (1<<16) /* try _only_ zipped file, skip real*/ +#define ZZIP_FACTORY (1<<17) /* old file handle is not closed */ +#define ZZIP_ALLOWREAL (1<<18) /* real files use default_io (magic) */ +#define ZZIP_THREADED (1<<19) /* try to be safe for multithreading */ + +/* + * zzip largefile renames + */ +#ifdef ZZIP_LARGEFILE_RENAME +#define zzip_telldir zzip_telldir64 +#define zzip_seekdir zzip_seekdir64 +#endif + +/* + * zzip typedefs + */ +/* zzip_strings_t ext[] = { ".zip", ".jar", ".pk3", 0 } */ +typedef char _zzip_const * _zzip_const zzip_strings_t; +typedef char _zzip_const zzip_char_t; +typedef struct zzip_dir ZZIP_DIR; +typedef struct zzip_file ZZIP_FILE; +typedef struct zzip_dirent ZZIP_DIRENT; +typedef struct zzip_dirent ZZIP_STAT; + +struct zzip_dirent +{ + int d_compr; /* compression method */ + int d_csize; /* compressed size */ + int st_size; /* file size / decompressed size */ + char * d_name; /* file name / strdupped name */ +}; + +/* + * Getting error strings + * zzip/err.c + */ +_zzip_export /* error in _opendir : */ +zzip_char_t* _zzip_calltype zzip_strerror(int errcode); +_zzip_export /* error in other functions : */ +zzip_char_t* _zzip_calltype zzip_strerror_of(ZZIP_DIR * dir); +_zzip_export /* error mapped to errno.h defines : */ +int zzip_errno(int errcode); + + +/* + * Functions to grab information from ZZIP_DIR/ZZIP_FILE structure + * (if ever needed) + * zzip/info.c + */ +_zzip_export +int _zzip_calltype zzip_error(ZZIP_DIR * dir); +_zzip_export +void _zzip_calltype zzip_seterror(ZZIP_DIR * dir, int errcode); +_zzip_export +zzip_char_t* zzip_compr_str(int compr); + +_zzip_export +ZZIP_DIR * _zzip_calltype zzip_dirhandle(ZZIP_FILE * fp); +_zzip_export +int _zzip_calltype zzip_dirfd(ZZIP_DIR * dir); +_zzip_export +int _zzip_calltype zzip_dir_real(ZZIP_DIR * dir); +_zzip_export +int _zzip_calltype zzip_file_real(ZZIP_FILE * fp); +_zzip_export +void* _zzip_calltype zzip_realdir(ZZIP_DIR * dir); +_zzip_export +int _zzip_calltype zzip_realfd(ZZIP_FILE * fp); + +/* + * zip handle management + * zzip/zip.c + */ +_zzip_export +ZZIP_DIR * _zzip_calltype zzip_dir_alloc(zzip_strings_t* fileext); +_zzip_export +int _zzip_calltype zzip_dir_free(ZZIP_DIR *); + +/* + * Opening/closing a zip archive + * zzip-zip.c + */ +_zzip_export +ZZIP_DIR * _zzip_calltype zzip_dir_fdopen(int fd, zzip_error_t * errcode_p); +_zzip_export +ZZIP_DIR * _zzip_calltype zzip_dir_open(zzip_char_t* filename, zzip_error_t * errcode_p); +_zzip_export +int _zzip_calltype zzip_dir_close(ZZIP_DIR * dir); +_zzip_export +int _zzip_calltype zzip_dir_read(ZZIP_DIR * dir, ZZIP_DIRENT * dirent); + + +/* + * Scanning files in zip archive + * zzip/dir.c + * zzip/zip.c + */ +_zzip_export +ZZIP_DIR * _zzip_calltype zzip_opendir(zzip_char_t* filename); +_zzip_export +int _zzip_calltype zzip_closedir(ZZIP_DIR * dir); +_zzip_export +ZZIP_DIRENT * _zzip_calltype zzip_readdir(ZZIP_DIR * dir); +_zzip_export +void _zzip_calltype zzip_rewinddir(ZZIP_DIR * dir); +_zzip_export +zzip_off_t _zzip_calltype zzip_telldir(ZZIP_DIR * dir); +_zzip_export +void _zzip_calltype zzip_seekdir(ZZIP_DIR * dir, zzip_off_t offset); + +/* + * 'opening', 'closing' and reading invidual files in zip archive. + * zzip/file.c + */ +_zzip_export +ZZIP_FILE * _zzip_calltype zzip_file_open(ZZIP_DIR * dir, zzip_char_t* name, int flags); +_zzip_export +int _zzip_calltype zzip_file_close(ZZIP_FILE * fp); +_zzip_export +zzip_ssize_t _zzip_calltype zzip_file_read(ZZIP_FILE * fp, void* buf, zzip_size_t len); + +_zzip_export +ZZIP_FILE * _zzip_calltype zzip_open(zzip_char_t* name, int flags); +_zzip_export +int _zzip_calltype zzip_close(ZZIP_FILE * fp); +_zzip_export +zzip_ssize_t _zzip_calltype zzip_read(ZZIP_FILE * fp, void * buf, zzip_size_t len); + +/* + * the stdc variant to open/read/close files. - Take note of the freopen() + * call as it may reuse an existing preparsed copy of a zip central directory + */ +_zzip_export +ZZIP_FILE* _zzip_calltype zzip_freopen(zzip_char_t* name, zzip_char_t* mode, ZZIP_FILE*); +_zzip_export +ZZIP_FILE* _zzip_calltype zzip_fopen(zzip_char_t* name, zzip_char_t* mode); +_zzip_export +zzip_size_t _zzip_calltype zzip_fread(void *ptr, zzip_size_t size, zzip_size_t nmemb, + ZZIP_FILE * file); +_zzip_export +int zzip_fclose(ZZIP_FILE * fp); + +/* + * seek and tell functions + */ +_zzip_export +int _zzip_calltype zzip_rewind(ZZIP_FILE *fp); +_zzip_export +zzip_off_t _zzip_calltype zzip_seek(ZZIP_FILE * fp, zzip_off_t offset, int whence); +_zzip_export +zzip_off_t _zzip_calltype zzip_tell(ZZIP_FILE * fp); + +/* + * reading info of a single file + * zzip/stat.c + */ +_zzip_export +int _zzip_calltype zzip_dir_stat(ZZIP_DIR * dir, zzip_char_t* name, + ZZIP_STAT * zs, int flags); +_zzip_export +int _zzip_calltype zzip_file_stat(ZZIP_FILE * fp, ZZIP_STAT * zs); +_zzip_export +int _zzip_calltype zzip_fstat(ZZIP_FILE * fp, ZZIP_STAT * zs); + +#ifdef ZZIP_LARGEFILE_RENAME +#define zzip_open_shared_io zzip_open_shared_io64 +#define zzip_open_ext_io zzip_open_ext_io64 +#define zzip_opendir_ext_io zzip_opendir_ext_io64 +#define zzip_dir_open_ext_io zzip_dir_open_ext_io64 +#define zzip_plugin_io_t zzip_plugin_io64_t +#endif + +/* + * all ext_io functions can be called with a default of ext/io == zero/zero + * which will default to a ".zip" extension and posix io of the system. + */ +typedef union _zzip_plugin_io _zzip_const * zzip_plugin_io_t; + +_zzip_export +ZZIP_FILE * _zzip_calltype zzip_open_shared_io(ZZIP_FILE* stream, + zzip_char_t* name, int o_flags, int o_modes, + zzip_strings_t* ext, zzip_plugin_io_t io); + +_zzip_export +ZZIP_FILE * _zzip_calltype zzip_open_ext_io(zzip_char_t* name, int o_flags, int o_modes, + zzip_strings_t* ext, zzip_plugin_io_t io); + +_zzip_export +ZZIP_DIR * _zzip_calltype zzip_opendir_ext_io(zzip_char_t* name, int o_modes, + zzip_strings_t* ext, zzip_plugin_io_t io); + +_zzip_export +ZZIP_DIR * _zzip_calltype zzip_dir_open_ext_io(zzip_char_t* filename, + zzip_error_t* errcode_p, + zzip_strings_t* ext, zzip_plugin_io_t io); + +/* zzip_file_open_ext_io => zzip_dir_open_ext_io + zzip_file_open */ + +#ifdef __cplusplus +}; +#endif + +#endif /* _ZZIPLIB_H */ + +/* + * Local variables: + * c-file-style: "stroustrup" + * End: + */ diff --git a/desmume/src/windows/zziplib/zziplib-2005-x32.lib b/src/windows/zziplib/zziplib-2005-x32.lib similarity index 100% rename from desmume/src/windows/zziplib/zziplib-2005-x32.lib rename to src/windows/zziplib/zziplib-2005-x32.lib diff --git a/desmume/src/windows/zziplib/zziplib-2005-x64.lib b/src/windows/zziplib/zziplib-2005-x64.lib similarity index 100% rename from desmume/src/windows/zziplib/zziplib-2005-x64.lib rename to src/windows/zziplib/zziplib-2005-x64.lib diff --git a/desmume/src/windows/zziplib/zziplib-2008-x32.lib b/src/windows/zziplib/zziplib-2008-x32.lib similarity index 100% rename from desmume/src/windows/zziplib/zziplib-2008-x32.lib rename to src/windows/zziplib/zziplib-2008-x32.lib diff --git a/desmume/src/windows/zziplib/zziplib-2008-x64.lib b/src/windows/zziplib/zziplib-2008-x64.lib similarity index 100% rename from desmume/src/windows/zziplib/zziplib-2008-x64.lib rename to src/windows/zziplib/zziplib-2008-x64.lib