mirror of
https://github.com/86Box/86Box.git
synced 2026-02-25 21:43:16 -07:00
Merge pull request #1330 from dhrdlicka/feature/utf8
Rewrite the emulator to use UTF-8 internally
This commit is contained in:
@@ -34,10 +34,10 @@
|
||||
|
||||
|
||||
#if defined(DEV_BRANCH) && defined(USE_VGAWONDER)
|
||||
#define BIOS_ROM_PATH_WONDER L"roms/video/ati18800/VGA_Wonder_V3-1.02.bin"
|
||||
#define BIOS_ROM_PATH_WONDER "roms/video/ati18800/VGA_Wonder_V3-1.02.bin"
|
||||
#endif
|
||||
#define BIOS_ROM_PATH_VGA88 L"roms/video/ati18800/vga88.bin"
|
||||
#define BIOS_ROM_PATH_EDGE16 L"roms/video/ati18800/vgaedge16.vbi"
|
||||
#define BIOS_ROM_PATH_VGA88 "roms/video/ati18800/vga88.bin"
|
||||
#define BIOS_ROM_PATH_EDGE16 "roms/video/ati18800/vgaedge16.vbi"
|
||||
|
||||
enum {
|
||||
#if defined(DEV_BRANCH) && defined(USE_VGAWONDER)
|
||||
@@ -230,7 +230,7 @@ static void *ati18800_init(const device_t *info)
|
||||
|
||||
ati18800->svga.miscout = 1;
|
||||
|
||||
ati_eeprom_load(&ati18800->eeprom, L"ati18800.nvr", 0);
|
||||
ati_eeprom_load(&ati18800->eeprom, "ati18800.nvr", 0);
|
||||
|
||||
return ati18800;
|
||||
}
|
||||
|
||||
@@ -42,23 +42,23 @@
|
||||
#define VGAWONDERXL24 2
|
||||
#endif
|
||||
|
||||
#define BIOS_ATIKOR_PATH L"roms/video/ati28800/atikorvga.bin"
|
||||
#define BIOS_ATIKOR_4620P_PATH_L L"roms/machines/spc4620p/31005h.u8"
|
||||
#define BIOS_ATIKOR_4620P_PATH_H L"roms/machines/spc4620p/31005h.u10"
|
||||
#define BIOS_ATIKOR_6033P_PATH L"roms/machines/spc6033p/phoenix.bin"
|
||||
#define FONT_ATIKOR_PATH L"roms/video/ati28800/ati_ksc5601.rom"
|
||||
#define FONT_ATIKOR_4620P_PATH L"roms/machines/spc4620p/svb6120a_font.rom"
|
||||
#define FONT_ATIKOR_6033P_PATH L"roms/machines/spc6033p/svb6120a_font.rom"
|
||||
#define BIOS_ATIKOR_PATH "roms/video/ati28800/atikorvga.bin"
|
||||
#define BIOS_ATIKOR_4620P_PATH_L "roms/machines/spc4620p/31005h.u8"
|
||||
#define BIOS_ATIKOR_4620P_PATH_H "roms/machines/spc4620p/31005h.u10"
|
||||
#define BIOS_ATIKOR_6033P_PATH "roms/machines/spc6033p/phoenix.bin"
|
||||
#define FONT_ATIKOR_PATH "roms/video/ati28800/ati_ksc5601.rom"
|
||||
#define FONT_ATIKOR_4620P_PATH "roms/machines/spc4620p/svb6120a_font.rom"
|
||||
#define FONT_ATIKOR_6033P_PATH "roms/machines/spc6033p/svb6120a_font.rom"
|
||||
|
||||
#define BIOS_VGAXL_EVEN_PATH L"roms/video/ati28800/xleven.bin"
|
||||
#define BIOS_VGAXL_ODD_PATH L"roms/video/ati28800/xlodd.bin"
|
||||
#define BIOS_VGAXL_EVEN_PATH "roms/video/ati28800/xleven.bin"
|
||||
#define BIOS_VGAXL_ODD_PATH "roms/video/ati28800/xlodd.bin"
|
||||
|
||||
#if defined(DEV_BRANCH) && defined(USE_XL24)
|
||||
#define BIOS_XL24_EVEN_PATH L"roms/video/ati28800/112-14318-102.bin"
|
||||
#define BIOS_XL24_ODD_PATH L"roms/video/ati28800/112-14319-102.bin"
|
||||
#define BIOS_XL24_EVEN_PATH "roms/video/ati28800/112-14318-102.bin"
|
||||
#define BIOS_XL24_ODD_PATH "roms/video/ati28800/112-14319-102.bin"
|
||||
#endif
|
||||
|
||||
#define BIOS_ROM_PATH L"roms/video/ati28800/bios.bin"
|
||||
#define BIOS_ROM_PATH "roms/video/ati28800/bios.bin"
|
||||
|
||||
|
||||
typedef struct ati28800_t
|
||||
@@ -517,7 +517,7 @@ ati28800k_init(const device_t *info)
|
||||
ati28800->svga.ksc5601_swap_mode = 0;
|
||||
ati28800->svga.ksc5601_english_font_type = 0;
|
||||
|
||||
ati_eeprom_load(&ati28800->eeprom, L"atikorvga.nvr", 0);
|
||||
ati_eeprom_load(&ati28800->eeprom, "atikorvga.nvr", 0);
|
||||
|
||||
return ati28800;
|
||||
}
|
||||
@@ -583,17 +583,17 @@ ati28800_init(const device_t *info)
|
||||
|
||||
switch (info->local) {
|
||||
case VGAWONDERXL:
|
||||
ati_eeprom_load(&ati28800->eeprom, L"ati28800xl.nvr", 0);
|
||||
ati_eeprom_load(&ati28800->eeprom, "ati28800xl.nvr", 0);
|
||||
break;
|
||||
|
||||
#if defined(DEV_BRANCH) && defined(USE_XL24)
|
||||
case VGAWONDERXL24:
|
||||
ati_eeprom_load(&ati28800->eeprom, L"ati28800xl24.nvr", 0);
|
||||
ati_eeprom_load(&ati28800->eeprom, "ati28800xl24.nvr", 0);
|
||||
break;
|
||||
#endif
|
||||
|
||||
default:
|
||||
ati_eeprom_load(&ati28800->eeprom, L"ati28800.nvr", 0);
|
||||
ati_eeprom_load(&ati28800->eeprom, "ati28800.nvr", 0);
|
||||
break;
|
||||
}
|
||||
|
||||
|
||||
@@ -28,16 +28,13 @@
|
||||
#include <86box/vid_ati_eeprom.h>
|
||||
|
||||
|
||||
void ati_eeprom_load(ati_eeprom_t *eeprom, wchar_t *fn, int type)
|
||||
void ati_eeprom_load(ati_eeprom_t *eeprom, char *fn, int type)
|
||||
{
|
||||
FILE *f;
|
||||
int size;
|
||||
eeprom->type = type;
|
||||
if (wcslen(fn) <= 256)
|
||||
wcscpy(eeprom->fn, fn);
|
||||
else
|
||||
wcsncpy(eeprom->fn, fn, 256);
|
||||
f = nvr_fopen(eeprom->fn, L"rb");
|
||||
strncpy(eeprom->fn, fn, sizeof(eeprom->fn) - 1);
|
||||
f = nvr_fopen(eeprom->fn, "rb");
|
||||
size = eeprom->type ? 512 : 128;
|
||||
if (!f) {
|
||||
memset(eeprom->data, 0xff, size);
|
||||
@@ -50,7 +47,7 @@ void ati_eeprom_load(ati_eeprom_t *eeprom, wchar_t *fn, int type)
|
||||
|
||||
void ati_eeprom_save(ati_eeprom_t *eeprom)
|
||||
{
|
||||
FILE *f = nvr_fopen(eeprom->fn, L"wb");
|
||||
FILE *f = nvr_fopen(eeprom->fn, "wb");
|
||||
if (!f) return;
|
||||
fwrite(eeprom->data, 1, eeprom->type ? 512 : 128, f);
|
||||
fclose(f);
|
||||
|
||||
@@ -42,10 +42,10 @@
|
||||
#undef CLAMP
|
||||
#endif
|
||||
|
||||
#define BIOS_ROM_PATH L"roms/video/mach64/bios.bin"
|
||||
#define BIOS_ISA_ROM_PATH L"roms/video/mach64/M64-1994.VBI"
|
||||
#define BIOS_VLB_ROM_PATH L"roms/video/mach64/mach64_vlb_vram.bin"
|
||||
#define BIOS_ROMVT2_PATH L"roms/video/mach64/atimach64vt2pci.bin"
|
||||
#define BIOS_ROM_PATH "roms/video/mach64/bios.bin"
|
||||
#define BIOS_ISA_ROM_PATH "roms/video/mach64/M64-1994.VBI"
|
||||
#define BIOS_VLB_ROM_PATH "roms/video/mach64/mach64_vlb_vram.bin"
|
||||
#define BIOS_ROMVT2_PATH "roms/video/mach64/atimach64vt2pci.bin"
|
||||
|
||||
|
||||
#define FIFO_SIZE 65536
|
||||
@@ -3388,7 +3388,7 @@ static void *mach64gx_init(const device_t *info)
|
||||
else if ((info->flags & DEVICE_VLB) || (info->flags & DEVICE_ISA))
|
||||
mach64->config_stat0 |= 1; /*VLB, 256Kx16 DRAM*/
|
||||
|
||||
ati_eeprom_load(&mach64->eeprom, L"mach64.nvr", 1);
|
||||
ati_eeprom_load(&mach64->eeprom, "mach64.nvr", 1);
|
||||
|
||||
if (info->flags & DEVICE_PCI)
|
||||
rom_init(&mach64->bios_rom, BIOS_ROM_PATH, 0xc0000, 0x8000, 0x7fff, 0, MEM_MAPPING_EXTERNAL);
|
||||
@@ -3417,7 +3417,7 @@ static void *mach64vt2_init(const device_t *info)
|
||||
mach64->config_stat0 = 4;
|
||||
mach64->use_block_decoded_io = 4;
|
||||
|
||||
ati_eeprom_load(&mach64->eeprom, L"mach64vt.nvr", 1);
|
||||
ati_eeprom_load(&mach64->eeprom, "mach64vt.nvr", 1);
|
||||
|
||||
rom_init(&mach64->bios_rom, BIOS_ROMVT2_PATH, 0xc0000, 0x8000, 0x7fff, 0, MEM_MAPPING_EXTERNAL);
|
||||
|
||||
|
||||
@@ -40,23 +40,23 @@
|
||||
#include <86box/vid_svga.h>
|
||||
#include <86box/vid_svga_render.h>
|
||||
|
||||
#define BIOS_GD5401_PATH L"roms/video/cirruslogic/avga1.rom"
|
||||
#define BIOS_GD5402_PATH L"roms/video/cirruslogic/avga2.rom"
|
||||
#define BIOS_GD5402_ONBOARD_PATH L"roms/machines/cbm_sl386sx25/c000.rom"
|
||||
#define BIOS_GD5420_PATH L"roms/video/cirruslogic/5420.vbi"
|
||||
#define BIOS_GD5422_PATH L"roms/video/cirruslogic/cl5422.bin"
|
||||
#define BIOS_GD5426_PATH L"roms/video/cirruslogic/Diamond SpeedStar PRO VLB v3.04.bin"
|
||||
#define BIOS_GD5428_ISA_PATH L"roms/video/cirruslogic/5428.bin"
|
||||
#define BIOS_GD5428_PATH L"roms/video/cirruslogic/vlbusjapan.BIN"
|
||||
#define BIOS_GD5429_PATH L"roms/video/cirruslogic/5429.vbi"
|
||||
#define BIOS_GD5430_VLB_PATH L"roms/video/cirruslogic/diamondvlbus.bin"
|
||||
#define BIOS_GD5430_PCI_PATH L"roms/video/cirruslogic/pci.bin"
|
||||
#define BIOS_GD5434_PATH L"roms/video/cirruslogic/gd5434.bin"
|
||||
#define BIOS_GD5436_PATH L"roms/video/cirruslogic/5436.vbi"
|
||||
#define BIOS_GD5440_PATH L"roms/video/cirruslogic/BIOS.BIN"
|
||||
#define BIOS_GD5446_PATH L"roms/video/cirruslogic/5446BV.VBI"
|
||||
#define BIOS_GD5446_STB_PATH L"roms/video/cirruslogic/stb nitro64v.BIN"
|
||||
#define BIOS_GD5480_PATH L"roms/video/cirruslogic/clgd5480.rom"
|
||||
#define BIOS_GD5401_PATH "roms/video/cirruslogic/avga1.rom"
|
||||
#define BIOS_GD5402_PATH "roms/video/cirruslogic/avga2.rom"
|
||||
#define BIOS_GD5402_ONBOARD_PATH "roms/machines/cbm_sl386sx25/c000.rom"
|
||||
#define BIOS_GD5420_PATH "roms/video/cirruslogic/5420.vbi"
|
||||
#define BIOS_GD5422_PATH "roms/video/cirruslogic/cl5422.bin"
|
||||
#define BIOS_GD5426_PATH "roms/video/cirruslogic/Diamond SpeedStar PRO VLB v3.04.bin"
|
||||
#define BIOS_GD5428_ISA_PATH "roms/video/cirruslogic/5428.bin"
|
||||
#define BIOS_GD5428_PATH "roms/video/cirruslogic/vlbusjapan.BIN"
|
||||
#define BIOS_GD5429_PATH "roms/video/cirruslogic/5429.vbi"
|
||||
#define BIOS_GD5430_VLB_PATH "roms/video/cirruslogic/diamondvlbus.bin"
|
||||
#define BIOS_GD5430_PCI_PATH "roms/video/cirruslogic/pci.bin"
|
||||
#define BIOS_GD5434_PATH "roms/video/cirruslogic/gd5434.bin"
|
||||
#define BIOS_GD5436_PATH "roms/video/cirruslogic/5436.vbi"
|
||||
#define BIOS_GD5440_PATH "roms/video/cirruslogic/BIOS.BIN"
|
||||
#define BIOS_GD5446_PATH "roms/video/cirruslogic/5446BV.VBI"
|
||||
#define BIOS_GD5446_STB_PATH "roms/video/cirruslogic/stb nitro64v.BIN"
|
||||
#define BIOS_GD5480_PATH "roms/video/cirruslogic/clgd5480.rom"
|
||||
|
||||
#define CIRRUS_ID_CLGD5401 0x88
|
||||
#define CIRRUS_ID_CLGD5402 0x89
|
||||
@@ -3711,7 +3711,7 @@ static void
|
||||
svga_t *svga = &gd54xx->svga;
|
||||
int id = info->local & 0xff;
|
||||
int vram;
|
||||
wchar_t *romfn = NULL;
|
||||
char *romfn = NULL;
|
||||
memset(gd54xx, 0, sizeof(gd54xx_t));
|
||||
|
||||
gd54xx->pci = !!(info->flags & DEVICE_PCI);
|
||||
|
||||
@@ -38,12 +38,12 @@
|
||||
void ega_doblit(int y1, int y2, int wx, int wy, ega_t *ega);
|
||||
|
||||
|
||||
#define BIOS_IBM_PATH L"roms/video/ega/ibm_6277356_ega_card_u44_27128.bin"
|
||||
#define BIOS_CPQ_PATH L"roms/video/ega/108281-001.bin"
|
||||
#define BIOS_SEGA_PATH L"roms/video/ega/lega.vbi"
|
||||
#define BIOS_ATIEGA_PATH L"roms/video/ega/ATI EGA Wonder 800+ N1.00.BIN"
|
||||
#define BIOS_ISKRA_PATH L"roms/video/ega/143-02.bin", L"roms/video/ega/143-03.bin"
|
||||
#define BIOS_TSENG_PATH L"roms/video/ega/EGA ET2000.BIN"
|
||||
#define BIOS_IBM_PATH "roms/video/ega/ibm_6277356_ega_card_u44_27128.bin"
|
||||
#define BIOS_CPQ_PATH "roms/video/ega/108281-001.bin"
|
||||
#define BIOS_SEGA_PATH "roms/video/ega/lega.vbi"
|
||||
#define BIOS_ATIEGA_PATH "roms/video/ega/ATI EGA Wonder 800+ N1.00.BIN"
|
||||
#define BIOS_ISKRA_PATH "roms/video/ega/143-02.bin", "roms/video/ega/143-03.bin"
|
||||
#define BIOS_TSENG_PATH "roms/video/ega/EGA ET2000.BIN"
|
||||
|
||||
|
||||
enum {
|
||||
@@ -1086,7 +1086,7 @@ ega_standalone_init(const device_t *info)
|
||||
io_sethandler(0x01ce, 0x0002, ega_in, NULL, NULL, ega_out, NULL, NULL, ega);
|
||||
ega->eeprom = malloc(sizeof(ati_eeprom_t));
|
||||
memset(ega->eeprom, 0, sizeof(ati_eeprom_t));
|
||||
ati_eeprom_load((ati_eeprom_t *) ega->eeprom, L"egawonder800.nvr", 0);
|
||||
ati_eeprom_load((ati_eeprom_t *) ega->eeprom, "egawonder800.nvr", 0);
|
||||
}
|
||||
|
||||
return ega;
|
||||
@@ -1124,7 +1124,7 @@ atiega_standalone_available(void)
|
||||
static int
|
||||
iskra_ega_standalone_available(void)
|
||||
{
|
||||
return rom_present(L"roms/video/ega/143-02.bin") && rom_present(L"roms/video/ega/143-03.bin");
|
||||
return rom_present("roms/video/ega/143-02.bin") && rom_present("roms/video/ega/143-03.bin");
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -54,11 +54,11 @@
|
||||
#include <86box/vid_svga_render.h>
|
||||
|
||||
|
||||
#define BIOS_ROM_PATH L"roms/video/et4000/et4000.bin"
|
||||
#define KOREAN_BIOS_ROM_PATH L"roms/video/et4000/tgkorvga.bin"
|
||||
#define KOREAN_FONT_ROM_PATH L"roms/video/et4000/tg_ksc5601.rom"
|
||||
#define KASAN_BIOS_ROM_PATH L"roms/video/et4000/et4000_kasan16.bin"
|
||||
#define KASAN_FONT_ROM_PATH L"roms/video/et4000/kasan_ksc5601.rom"
|
||||
#define BIOS_ROM_PATH "roms/video/et4000/et4000.bin"
|
||||
#define KOREAN_BIOS_ROM_PATH "roms/video/et4000/tgkorvga.bin"
|
||||
#define KOREAN_FONT_ROM_PATH "roms/video/et4000/tg_ksc5601.rom"
|
||||
#define KASAN_BIOS_ROM_PATH "roms/video/et4000/et4000_kasan16.bin"
|
||||
#define KASAN_FONT_ROM_PATH "roms/video/et4000/kasan_ksc5601.rom"
|
||||
|
||||
typedef struct {
|
||||
const char *name;
|
||||
@@ -638,7 +638,7 @@ et4000_mca_feedb(void *priv)
|
||||
static void *
|
||||
et4000_init(const device_t *info)
|
||||
{
|
||||
const wchar_t *fn;
|
||||
const char *fn;
|
||||
et4000_t *dev;
|
||||
int i;
|
||||
|
||||
@@ -737,7 +737,7 @@ et4000_init(const device_t *info)
|
||||
|
||||
dev->vram_mask = dev->vram_size - 1;
|
||||
|
||||
rom_init(&dev->bios_rom, (wchar_t *) fn,
|
||||
rom_init(&dev->bios_rom, (char *) fn,
|
||||
0xc0000, 0x8000, 0x7fff, 0, MEM_MAPPING_EXTERNAL);
|
||||
|
||||
dev->svga.translate_address = get_et4000_addr;
|
||||
|
||||
@@ -38,13 +38,13 @@
|
||||
#include <86box/vid_svga_render.h>
|
||||
|
||||
|
||||
#define BIOS_ROM_PATH_DIAMOND L"roms/video/et4000w32/et4000w32.bin"
|
||||
#define BIOS_ROM_PATH_CARDEX L"roms/video/et4000w32/cardex.vbi"
|
||||
#define BIOS_ROM_PATH_W32 L"roms/video/et4000w32/ET4000W32VLB_bios_MX27C512.BIN"
|
||||
#define BIOS_ROM_PATH_W32I_ISA L"roms/video/et4000w32/ET4KW32I.VBI"
|
||||
#define BIOS_ROM_PATH_W32I_VLB L"roms/video/et4000w32/tseng.u41.bin"
|
||||
#define BIOS_ROM_PATH_W32P L"roms/video/et4000w32/ET4K_W32.BIN"
|
||||
#define BIOS_ROM_PATH_W32P_REVC L"roms/video/et4000w32/et4000w32pcardex.BIN"
|
||||
#define BIOS_ROM_PATH_DIAMOND "roms/video/et4000w32/et4000w32.bin"
|
||||
#define BIOS_ROM_PATH_CARDEX "roms/video/et4000w32/cardex.vbi"
|
||||
#define BIOS_ROM_PATH_W32 "roms/video/et4000w32/ET4000W32VLB_bios_MX27C512.BIN"
|
||||
#define BIOS_ROM_PATH_W32I_ISA "roms/video/et4000w32/ET4KW32I.VBI"
|
||||
#define BIOS_ROM_PATH_W32I_VLB "roms/video/et4000w32/tseng.u41.bin"
|
||||
#define BIOS_ROM_PATH_W32P "roms/video/et4000w32/ET4K_W32.BIN"
|
||||
#define BIOS_ROM_PATH_W32P_REVC "roms/video/et4000w32/et4000w32pcardex.BIN"
|
||||
|
||||
#define FIFO_SIZE 65536
|
||||
#define FIFO_MASK (FIFO_SIZE - 1)
|
||||
|
||||
@@ -33,7 +33,7 @@
|
||||
#include <86box/video.h>
|
||||
|
||||
|
||||
#define BIOS_ROM_PATH L"roms/video/genius/8x12.bin"
|
||||
#define BIOS_ROM_PATH "roms/video/genius/8x12.bin"
|
||||
|
||||
|
||||
#define GENIUS_XSIZE 728
|
||||
|
||||
@@ -94,9 +94,9 @@ void ht216_out(uint16_t addr, uint8_t val, void *p);
|
||||
uint8_t ht216_in(uint16_t addr, void *p);
|
||||
|
||||
|
||||
#define BIOS_G2_GC205_PATH L"roms/video/video7/BIOS.BIN"
|
||||
#define BIOS_VIDEO7_VGA_1024I_PATH L"roms/video/video7/Video Seven VGA 1024i - BIOS - v2.19 - 435-0062-05 - U17 - 27C256.BIN"
|
||||
#define BIOS_HT216_32_PATH L"roms/video/video7/HT21632.BIN"
|
||||
#define BIOS_G2_GC205_PATH "roms/video/video7/BIOS.BIN"
|
||||
#define BIOS_VIDEO7_VGA_1024I_PATH "roms/video/video7/Video Seven VGA 1024i - BIOS - v2.19 - 435-0062-05 - U17 - 27C256.BIN"
|
||||
#define BIOS_HT216_32_PATH "roms/video/video7/HT21632.BIN"
|
||||
|
||||
static video_timings_t timing_v7vga_isa = {VIDEO_ISA, 3, 3, 6, 5, 5, 10};
|
||||
static video_timings_t timing_v7vga_vlb = {VIDEO_BUS, 5, 5, 9, 20, 20, 30};
|
||||
|
||||
@@ -66,7 +66,7 @@
|
||||
#include <86box/vid_pgc.h>
|
||||
|
||||
|
||||
#define BIOS_ROM_PATH L"roms/video/im1024/im1024font.bin"
|
||||
#define BIOS_ROM_PATH "roms/video/im1024/im1024font.bin"
|
||||
|
||||
|
||||
typedef struct {
|
||||
|
||||
@@ -34,8 +34,8 @@
|
||||
#include <86box/vid_svga_render.h>
|
||||
|
||||
|
||||
#define ROM_MYSTIQUE L"roms/video/matrox/MYSTIQUE.VBI"
|
||||
#define ROM_MYSTIQUE_220 L"roms/video/matrox/Myst220_66-99mhz.vbi"
|
||||
#define ROM_MYSTIQUE "roms/video/matrox/MYSTIQUE.VBI"
|
||||
#define ROM_MYSTIQUE_220 "roms/video/matrox/Myst220_66-99mhz.vbi"
|
||||
|
||||
#define FIFO_SIZE 65536
|
||||
#define FIFO_MASK (FIFO_SIZE - 1)
|
||||
@@ -4917,7 +4917,7 @@ mystique_init(const device_t *info)
|
||||
{
|
||||
int c;
|
||||
mystique_t *mystique = malloc(sizeof(mystique_t));
|
||||
wchar_t *romfn;
|
||||
char *romfn;
|
||||
|
||||
memset(mystique, 0, sizeof(mystique_t));
|
||||
|
||||
|
||||
@@ -566,7 +566,7 @@ nga_init(const device_t *info)
|
||||
|
||||
charset = device_get_config_int("charset");
|
||||
|
||||
loadfont_ex(L"roms/video/nga/ncr_nga_35122.bin", 1, 4096 * charset);
|
||||
loadfont_ex("roms/video/nga/ncr_nga_35122.bin", 1, 4096 * charset);
|
||||
|
||||
nga->cga.composite = 0;
|
||||
nga->cga.snow_enabled = device_get_config_int("snow_enabled");
|
||||
|
||||
@@ -29,11 +29,11 @@
|
||||
#include <86box/video.h>
|
||||
#include <86box/vid_svga.h>
|
||||
|
||||
#define BIOS_037C_PATH L"roms/video/oti/bios.bin"
|
||||
#define BIOS_067_AMA932J_PATH L"roms/machines/ama932j/oti067.bin"
|
||||
#define BIOS_067_M300_08_PATH L"roms/machines/olivetti_m300_08/EVC_BIOS.ROM"
|
||||
#define BIOS_067_M300_15_PATH L"roms/machines/olivetti_m300_15/EVC_BIOS.ROM"
|
||||
#define BIOS_077_PATH L"roms/video/oti/oti077.vbi"
|
||||
#define BIOS_037C_PATH "roms/video/oti/bios.bin"
|
||||
#define BIOS_067_AMA932J_PATH "roms/machines/ama932j/oti067.bin"
|
||||
#define BIOS_067_M300_08_PATH "roms/machines/olivetti_m300_08/EVC_BIOS.ROM"
|
||||
#define BIOS_067_M300_15_PATH "roms/machines/olivetti_m300_15/EVC_BIOS.ROM"
|
||||
#define BIOS_077_PATH "roms/video/oti/oti077.vbi"
|
||||
|
||||
|
||||
enum {
|
||||
@@ -340,7 +340,7 @@ static void *
|
||||
oti_init(const device_t *info)
|
||||
{
|
||||
oti_t *oti = malloc(sizeof(oti_t));
|
||||
wchar_t *romfn = NULL;
|
||||
char *romfn = NULL;
|
||||
|
||||
memset(oti, 0x00, sizeof(oti_t));
|
||||
oti->chip_id = info->local;
|
||||
|
||||
@@ -603,7 +603,7 @@ ogc_init(const device_t *info)
|
||||
memset(ogc, 0x00, sizeof(ogc_t));
|
||||
video_inform(VIDEO_FLAG_TYPE_CGA, &timing_ogc);
|
||||
|
||||
loadfont(L"roms/video/ogc/ogc graphics board go380 258 pqbq.bin", 1);
|
||||
loadfont("roms/video/ogc/ogc graphics board go380 258 pqbq.bin", 1);
|
||||
|
||||
/* composite is not working yet */
|
||||
// display_type = device_get_config_int("display_type");
|
||||
|
||||
@@ -357,7 +357,7 @@ static void *paradise_pvga1a_ncr3302_init(const device_t *info)
|
||||
paradise_t *paradise = paradise_init(info, 1 << 18);
|
||||
|
||||
if (paradise)
|
||||
rom_init(¶dise->bios_rom, L"roms/machines/ncr_3302/c000-wd_1987-1989-740011-003058-019c.bin", 0xc0000, 0x8000, 0x7fff, 0, MEM_MAPPING_EXTERNAL);
|
||||
rom_init(¶dise->bios_rom, "roms/machines/ncr_3302/c000-wd_1987-1989-740011-003058-019c.bin", 0xc0000, 0x8000, 0x7fff, 0, MEM_MAPPING_EXTERNAL);
|
||||
|
||||
return paradise;
|
||||
}
|
||||
@@ -367,7 +367,7 @@ static void *paradise_pvga1a_pc2086_init(const device_t *info)
|
||||
paradise_t *paradise = paradise_init(info, 1 << 18);
|
||||
|
||||
if (paradise)
|
||||
rom_init(¶dise->bios_rom, L"roms/machines/pc2086/40186.ic171", 0xc0000, 0x8000, 0x7fff, 0, MEM_MAPPING_EXTERNAL);
|
||||
rom_init(¶dise->bios_rom, "roms/machines/pc2086/40186.ic171", 0xc0000, 0x8000, 0x7fff, 0, MEM_MAPPING_EXTERNAL);
|
||||
|
||||
return paradise;
|
||||
}
|
||||
@@ -377,7 +377,7 @@ static void *paradise_pvga1a_pc3086_init(const device_t *info)
|
||||
paradise_t *paradise = paradise_init(info, 1 << 18);
|
||||
|
||||
if (paradise)
|
||||
rom_init(¶dise->bios_rom, L"roms/machines/pc3086/c000.bin", 0xc0000, 0x8000, 0x7fff, 0, MEM_MAPPING_EXTERNAL);
|
||||
rom_init(¶dise->bios_rom, "roms/machines/pc3086/c000.bin", 0xc0000, 0x8000, 0x7fff, 0, MEM_MAPPING_EXTERNAL);
|
||||
|
||||
return paradise;
|
||||
}
|
||||
@@ -393,14 +393,14 @@ static void *paradise_pvga1a_standalone_init(const device_t *info)
|
||||
paradise = paradise_init(info, memory);
|
||||
|
||||
if (paradise)
|
||||
rom_init(¶dise->bios_rom, L"roms/video/pvga1a/BIOS.BIN", 0xc0000, 0x8000, 0x7fff, 0, MEM_MAPPING_EXTERNAL);
|
||||
rom_init(¶dise->bios_rom, "roms/video/pvga1a/BIOS.BIN", 0xc0000, 0x8000, 0x7fff, 0, MEM_MAPPING_EXTERNAL);
|
||||
|
||||
return paradise;
|
||||
}
|
||||
|
||||
static int paradise_pvga1a_standalone_available(void)
|
||||
{
|
||||
return rom_present(L"roms/video/pvga1a/BIOS.BIN");
|
||||
return rom_present("roms/video/pvga1a/BIOS.BIN");
|
||||
}
|
||||
|
||||
static void *paradise_wd90c11_megapc_init(const device_t *info)
|
||||
@@ -409,8 +409,8 @@ static void *paradise_wd90c11_megapc_init(const device_t *info)
|
||||
|
||||
if (paradise)
|
||||
rom_init_interleaved(¶dise->bios_rom,
|
||||
L"roms/machines/megapc/41651-bios lo.u18",
|
||||
L"roms/machines/megapc/211253-bios hi.u19",
|
||||
"roms/machines/megapc/41651-bios lo.u18",
|
||||
"roms/machines/megapc/211253-bios hi.u19",
|
||||
0xc0000, 0x8000, 0x7fff, 0, MEM_MAPPING_EXTERNAL);
|
||||
|
||||
return paradise;
|
||||
@@ -421,14 +421,14 @@ static void *paradise_wd90c11_standalone_init(const device_t *info)
|
||||
paradise_t *paradise = paradise_init(info, 0);
|
||||
|
||||
if (paradise)
|
||||
rom_init(¶dise->bios_rom, L"roms/video/wd90c11/WD90C11.VBI", 0xc0000, 0x8000, 0x7fff, 0, MEM_MAPPING_EXTERNAL);
|
||||
rom_init(¶dise->bios_rom, "roms/video/wd90c11/WD90C11.VBI", 0xc0000, 0x8000, 0x7fff, 0, MEM_MAPPING_EXTERNAL);
|
||||
|
||||
return paradise;
|
||||
}
|
||||
|
||||
static int paradise_wd90c11_standalone_available(void)
|
||||
{
|
||||
return rom_present(L"roms/video/wd90c11/WD90C11.VBI");
|
||||
return rom_present("roms/video/wd90c11/WD90C11.VBI");
|
||||
}
|
||||
|
||||
static void *paradise_wd90c30_standalone_init(const device_t *info)
|
||||
@@ -442,14 +442,14 @@ static void *paradise_wd90c30_standalone_init(const device_t *info)
|
||||
paradise = paradise_init(info, memory);
|
||||
|
||||
if (paradise)
|
||||
rom_init(¶dise->bios_rom, L"roms/video/wd90c30/90C30-LR.VBI", 0xc0000, 0x8000, 0x7fff, 0, MEM_MAPPING_EXTERNAL);
|
||||
rom_init(¶dise->bios_rom, "roms/video/wd90c30/90C30-LR.VBI", 0xc0000, 0x8000, 0x7fff, 0, MEM_MAPPING_EXTERNAL);
|
||||
|
||||
return paradise;
|
||||
}
|
||||
|
||||
static int paradise_wd90c30_standalone_available(void)
|
||||
{
|
||||
return rom_present(L"roms/video/wd90c30/90C30-LR.VBI");
|
||||
return rom_present("roms/video/wd90c30/90C30-LR.VBI");
|
||||
}
|
||||
|
||||
void paradise_close(void *p)
|
||||
|
||||
@@ -37,25 +37,25 @@
|
||||
#include <86box/vid_svga_render.h>
|
||||
#include "cpu.h"
|
||||
|
||||
#define ROM_ORCHID_86C911 L"roms/video/s3/BIOS.BIN"
|
||||
#define ROM_DIAMOND_STEALTH_VRAM L"roms/video/s3/Diamond Stealth VRAM BIOS v2.31 U14.BIN"
|
||||
#define ROM_AMI_86C924 L"roms/video/s3/S3924AMI.BIN"
|
||||
#define ROM_METHEUS_86C928 L"roms/video/s3/928.vbi"
|
||||
#define ROM_V7MIRAGE_86C801 L"roms/video/s3/v7mirage.vbi"
|
||||
#define ROM_PHOENIX_86C805 L"roms/video/s3/805.vbi"
|
||||
#define ROM_PARADISE_BAHAMAS64 L"roms/video/s3/bahamas64.bin"
|
||||
#define ROM_PHOENIX_VISION864 L"roms/video/s3/86c864p.bin"
|
||||
#define ROM_DIAMOND_STEALTH64_964 L"roms/video/s3/964_107h.rom"
|
||||
#define ROM_PHOENIX_TRIO32 L"roms/video/s3/86c732p.bin"
|
||||
#define ROM_NUMBER9_9FX L"roms/video/s3/s3_764.bin"
|
||||
#define ROM_PHOENIX_TRIO64 L"roms/video/s3/86c764x1.bin"
|
||||
#define ROM_DIAMOND_STEALTH64_764 L"roms/video/s3/stealt64.bin"
|
||||
#define ROM_TRIO64V2_DX_VBE20 L"roms/video/s3/86c775_2.bin"
|
||||
#define ROM_PHOENIX_TRIO64VPLUS L"roms/video/s3/64V1506.ROM"
|
||||
#define ROM_DIAMOND_STEALTH_SE L"roms/video/s3/DiamondStealthSE.VBI"
|
||||
#define ROM_ELSAWIN2KPROX_964 L"roms/video/s3/elsaw20004m.BIN"
|
||||
#define ROM_ELSAWIN2KPROX L"roms/video/s3/elsaw20008m.BIN"
|
||||
#define ROM_PHOENIX_VISION868 L"roms/video/s3/1-DSV3868.BIN"
|
||||
#define ROM_ORCHID_86C911 "roms/video/s3/BIOS.BIN"
|
||||
#define ROM_DIAMOND_STEALTH_VRAM "roms/video/s3/Diamond Stealth VRAM BIOS v2.31 U14.BIN"
|
||||
#define ROM_AMI_86C924 "roms/video/s3/S3924AMI.BIN"
|
||||
#define ROM_METHEUS_86C928 "roms/video/s3/928.vbi"
|
||||
#define ROM_V7MIRAGE_86C801 "roms/video/s3/v7mirage.vbi"
|
||||
#define ROM_PHOENIX_86C805 "roms/video/s3/805.vbi"
|
||||
#define ROM_PARADISE_BAHAMAS64 "roms/video/s3/bahamas64.bin"
|
||||
#define ROM_PHOENIX_VISION864 "roms/video/s3/86c864p.bin"
|
||||
#define ROM_DIAMOND_STEALTH64_964 "roms/video/s3/964_107h.rom"
|
||||
#define ROM_PHOENIX_TRIO32 "roms/video/s3/86c732p.bin"
|
||||
#define ROM_NUMBER9_9FX "roms/video/s3/s3_764.bin"
|
||||
#define ROM_PHOENIX_TRIO64 "roms/video/s3/86c764x1.bin"
|
||||
#define ROM_DIAMOND_STEALTH64_764 "roms/video/s3/stealt64.bin"
|
||||
#define ROM_TRIO64V2_DX_VBE20 "roms/video/s3/86c775_2.bin"
|
||||
#define ROM_PHOENIX_TRIO64VPLUS "roms/video/s3/64V1506.ROM"
|
||||
#define ROM_DIAMOND_STEALTH_SE "roms/video/s3/DiamondStealthSE.VBI"
|
||||
#define ROM_ELSAWIN2KPROX_964 "roms/video/s3/elsaw20004m.BIN"
|
||||
#define ROM_ELSAWIN2KPROX "roms/video/s3/elsaw20008m.BIN"
|
||||
#define ROM_PHOENIX_VISION868 "roms/video/s3/1-DSV3868.BIN"
|
||||
|
||||
enum
|
||||
{
|
||||
@@ -5577,7 +5577,7 @@ static int vram_sizes[] =
|
||||
|
||||
static void *s3_init(const device_t *info)
|
||||
{
|
||||
const wchar_t *bios_fn;
|
||||
const char *bios_fn;
|
||||
int chip, stepping;
|
||||
s3_t *s3 = malloc(sizeof(s3_t));
|
||||
svga_t *svga = &s3->svga;
|
||||
@@ -5752,7 +5752,7 @@ static void *s3_init(const device_t *info)
|
||||
|
||||
s3->has_bios = (bios_fn != NULL);
|
||||
if (s3->has_bios) {
|
||||
rom_init(&s3->bios_rom, (wchar_t *) bios_fn, 0xc0000, 0x8000, 0x7fff, 0, MEM_MAPPING_EXTERNAL);
|
||||
rom_init(&s3->bios_rom, (char *) bios_fn, 0xc0000, 0x8000, 0x7fff, 0, MEM_MAPPING_EXTERNAL);
|
||||
if (info->flags & DEVICE_PCI)
|
||||
mem_mapping_disable(&s3->bios_rom.mapping);
|
||||
}
|
||||
|
||||
@@ -66,13 +66,13 @@ static int dither[4][4] =
|
||||
#define FIFO_TYPE 0xff000000
|
||||
#define FIFO_ADDR 0x00ffffff
|
||||
|
||||
#define ROM_VIRGE_325 L"roms/video/s3virge/86c325.bin"
|
||||
#define ROM_DIAMOND_STEALTH3D_2000 L"roms/video/s3virge/s3virge.bin"
|
||||
#define ROM_DIAMOND_STEALTH3D_3000 L"roms/video/s3virge/diamondstealth3000.vbi"
|
||||
#define ROM_VIRGE_DX L"roms/video/s3virge/86c375_1.bin"
|
||||
#define ROM_VIRGE_DX_VBE20 L"roms/video/s3virge/86c375_4.bin"
|
||||
#define ROM_VIRGE_325 "roms/video/s3virge/86c325.bin"
|
||||
#define ROM_DIAMOND_STEALTH3D_2000 "roms/video/s3virge/s3virge.bin"
|
||||
#define ROM_DIAMOND_STEALTH3D_3000 "roms/video/s3virge/diamondstealth3000.vbi"
|
||||
#define ROM_VIRGE_DX "roms/video/s3virge/86c375_1.bin"
|
||||
#define ROM_VIRGE_DX_VBE20 "roms/video/s3virge/86c375_4.bin"
|
||||
#if defined(DEV_BRANCH) && defined(USE_S3TRIO3D2X)
|
||||
#define ROM_TRIO3D_2X L"roms/video/s3virge/TRIO3D2X_8mbsdr.VBI"
|
||||
#define ROM_TRIO3D_2X "roms/video/s3virge/TRIO3D2X_8mbsdr.VBI"
|
||||
#endif
|
||||
|
||||
enum
|
||||
@@ -3684,7 +3684,7 @@ static void s3_virge_pci_write(int func, int addr, uint8_t val, void *p)
|
||||
|
||||
static void *s3_virge_init(const device_t *info)
|
||||
{
|
||||
const wchar_t *bios_fn;
|
||||
const char *bios_fn;
|
||||
virge_t *virge = malloc(sizeof(virge_t));
|
||||
|
||||
memset(virge, 0, sizeof(virge_t));
|
||||
@@ -3728,7 +3728,7 @@ static void *s3_virge_init(const device_t *info)
|
||||
|
||||
virge->pci = !!(info->flags & DEVICE_PCI);
|
||||
|
||||
rom_init(&virge->bios_rom, (wchar_t *) bios_fn, 0xc0000, 0x8000, 0x7fff, 0, MEM_MAPPING_EXTERNAL);
|
||||
rom_init(&virge->bios_rom, (char *) bios_fn, 0xc0000, 0x8000, 0x7fff, 0, MEM_MAPPING_EXTERNAL);
|
||||
if (info->flags & DEVICE_PCI)
|
||||
mem_mapping_disable(&virge->bios_rom.mapping);
|
||||
|
||||
|
||||
@@ -31,8 +31,8 @@
|
||||
#include <86box/video.h>
|
||||
|
||||
|
||||
#define ROM_SIGMA_FONT L"roms/video/sigma/sigma400_font.rom"
|
||||
#define ROM_SIGMA_BIOS L"roms/video/sigma/sigma400_bios.rom"
|
||||
#define ROM_SIGMA_FONT "roms/video/sigma/sigma400_font.rom"
|
||||
#define ROM_SIGMA_BIOS "roms/video/sigma/sigma400_bios.rom"
|
||||
|
||||
/* The Sigma Designs Color 400 is a video card from 1985, presumably intended
|
||||
* as an EGA competitor.
|
||||
|
||||
@@ -238,7 +238,7 @@ video_reset(int card)
|
||||
vid_table_log("VIDEO: reset (gfxcard=%d, internal=%d)\n",
|
||||
card, (machines[machine].flags & MACHINE_VIDEO)?1:0);
|
||||
|
||||
loadfont(L"roms/video/mda/mda.rom", 0);
|
||||
loadfont("roms/video/mda/mda.rom", 0);
|
||||
|
||||
/* Reset (deallocate) the video font arrays. */
|
||||
if (fontdatksc5601) {
|
||||
|
||||
@@ -106,8 +106,8 @@
|
||||
writes out 16 bytes. I don't think the access size or host data has any affect,
|
||||
but the Windows 3.1 driver always reads bytes and write words of 0xffff.*/
|
||||
|
||||
#define ROM_TGUI_9400CXI L"roms/video/tgui9440/9400CXI.vbi"
|
||||
#define ROM_TGUI_9440 L"roms/video/tgui9440/9440.vbi"
|
||||
#define ROM_TGUI_9400CXI "roms/video/tgui9440/9400CXI.vbi"
|
||||
#define ROM_TGUI_9440 "roms/video/tgui9440/9440.vbi"
|
||||
|
||||
#define EXT_CTRL_16BIT 0x01
|
||||
#define EXT_CTRL_MONO_EXPANSION 0x02
|
||||
@@ -1685,7 +1685,7 @@ void tgui_accel_write_fb_l(uint32_t addr, uint32_t val, void *p)
|
||||
|
||||
static void *tgui_init(const device_t *info)
|
||||
{
|
||||
const wchar_t *bios_fn;
|
||||
const char *bios_fn;
|
||||
int type = info->local;
|
||||
|
||||
tgui_t *tgui = malloc(sizeof(tgui_t));
|
||||
@@ -1710,7 +1710,7 @@ static void *tgui_init(const device_t *info)
|
||||
return NULL;
|
||||
}
|
||||
|
||||
rom_init(&tgui->bios_rom, (wchar_t *) bios_fn, 0xc0000, 0x8000, 0x7fff, 0, MEM_MAPPING_EXTERNAL);
|
||||
rom_init(&tgui->bios_rom, (char *) bios_fn, 0xc0000, 0x8000, 0x7fff, 0, MEM_MAPPING_EXTERNAL);
|
||||
|
||||
if (info->flags & DEVICE_PCI)
|
||||
video_inform(VIDEO_FLAG_TYPE_SPECIAL, &timing_tgui_pci);
|
||||
@@ -1749,12 +1749,12 @@ static void *tgui_init(const device_t *info)
|
||||
|
||||
static int tgui9400cxi_available()
|
||||
{
|
||||
return rom_present(L"roms/video/tgui9440/9400CXI.vbi");
|
||||
return rom_present("roms/video/tgui9440/9400CXI.vbi");
|
||||
}
|
||||
|
||||
static int tgui9440_available()
|
||||
{
|
||||
return rom_present(L"roms/video/tgui9440/9440.vbi");
|
||||
return rom_present("roms/video/tgui9440/9440.vbi");
|
||||
}
|
||||
|
||||
void tgui_close(void *p)
|
||||
|
||||
@@ -35,9 +35,9 @@
|
||||
#define TVGA9000B_ID 0x23
|
||||
#define TVGA8900CLD_ID 0x33
|
||||
|
||||
#define ROM_TVGA_8900B L"roms/video/tvga/tvga8900B.VBI"
|
||||
#define ROM_TVGA_8900CLD L"roms/video/tvga/trident.bin"
|
||||
#define ROM_TVGA_9000B L"roms/video/tvga/tvga9000b.bin"
|
||||
#define ROM_TVGA_8900B "roms/video/tvga/tvga8900B.VBI"
|
||||
#define ROM_TVGA_8900CLD "roms/video/tvga/trident.bin"
|
||||
#define ROM_TVGA_9000B "roms/video/tvga/tvga9000b.bin"
|
||||
|
||||
typedef struct tvga_t
|
||||
{
|
||||
@@ -351,7 +351,7 @@ void tvga_recalctimings(svga_t *svga)
|
||||
|
||||
static void *tvga_init(const device_t *info)
|
||||
{
|
||||
const wchar_t *bios_fn;
|
||||
const char *bios_fn;
|
||||
tvga_t *tvga = malloc(sizeof(tvga_t));
|
||||
memset(tvga, 0, sizeof(tvga_t));
|
||||
|
||||
@@ -383,7 +383,7 @@ static void *tvga_init(const device_t *info)
|
||||
return NULL;
|
||||
}
|
||||
|
||||
rom_init(&tvga->bios_rom, (wchar_t *) bios_fn, 0xc0000, 0x8000, 0x7fff, 0, MEM_MAPPING_EXTERNAL);
|
||||
rom_init(&tvga->bios_rom, (char *) bios_fn, 0xc0000, 0x8000, 0x7fff, 0, MEM_MAPPING_EXTERNAL);
|
||||
|
||||
svga_init(info, &tvga->svga, tvga, tvga->vram_size,
|
||||
tvga_recalctimings,
|
||||
|
||||
@@ -116,7 +116,7 @@ static void *vga_init(const device_t *info)
|
||||
vga_t *vga = malloc(sizeof(vga_t));
|
||||
memset(vga, 0, sizeof(vga_t));
|
||||
|
||||
rom_init(&vga->bios_rom, L"roms/video/vga/ibm_vga.bin", 0xc0000, 0x8000, 0x7fff, 0x2000, MEM_MAPPING_EXTERNAL);
|
||||
rom_init(&vga->bios_rom, "roms/video/vga/ibm_vga.bin", 0xc0000, 0x8000, 0x7fff, 0x2000, MEM_MAPPING_EXTERNAL);
|
||||
|
||||
video_inform(VIDEO_FLAG_TYPE_SPECIAL, &timing_vga);
|
||||
|
||||
@@ -162,7 +162,7 @@ void *ps1vga_init(const device_t *info)
|
||||
|
||||
static int vga_available(void)
|
||||
{
|
||||
return rom_present(L"roms/video/vga/ibm_vga.bin");
|
||||
return rom_present("roms/video/vga/ibm_vga.bin");
|
||||
}
|
||||
|
||||
void vga_close(void *p)
|
||||
|
||||
@@ -1229,12 +1229,12 @@ void voodoo_card_close(voodoo_t *voodoo)
|
||||
int c;
|
||||
|
||||
/* #ifndef RELEASE_BUILD
|
||||
f = rom_fopen(L"texram.dmp", L"wb");
|
||||
f = rom_fopen("texram.dmp", "wb");
|
||||
fwrite(voodoo->tex_mem[0], voodoo->texture_size*1024*1024, 1, f);
|
||||
fclose(f);
|
||||
if (voodoo->dual_tmus)
|
||||
{
|
||||
f = rom_fopen(L"texram2.dmp", L"wb");
|
||||
f = rom_fopen("texram2.dmp", "wb");
|
||||
fwrite(voodoo->tex_mem[1], voodoo->texture_size*1024*1024, 1, f);
|
||||
fclose(f);
|
||||
}
|
||||
|
||||
@@ -2706,7 +2706,7 @@ static const device_config_t banshee_sdram_config[] =
|
||||
}
|
||||
};
|
||||
|
||||
static void *banshee_init_common(const device_t *info, wchar_t *fn, int has_sgram, int type, int voodoo_type, int agp)
|
||||
static void *banshee_init_common(const device_t *info, char *fn, int has_sgram, int type, int voodoo_type, int agp)
|
||||
{
|
||||
int mem_size;
|
||||
banshee_t *banshee = malloc(sizeof(banshee_t));
|
||||
@@ -2836,19 +2836,19 @@ static void *banshee_init_common(const device_t *info, wchar_t *fn, int has_sgra
|
||||
|
||||
static void *banshee_init(const device_t *info)
|
||||
{
|
||||
return banshee_init_common(info, L"roms/video/voodoo/Pci_sg.rom", 1, TYPE_BANSHEE, VOODOO_BANSHEE, 0);
|
||||
return banshee_init_common(info, "roms/video/voodoo/Pci_sg.rom", 1, TYPE_BANSHEE, VOODOO_BANSHEE, 0);
|
||||
}
|
||||
static void *creative_banshee_init(const device_t *info)
|
||||
{
|
||||
return banshee_init_common(info, L"roms/video/voodoo/BlasterPCI.rom", 0, TYPE_BANSHEE, VOODOO_BANSHEE, 0);
|
||||
return banshee_init_common(info, "roms/video/voodoo/BlasterPCI.rom", 0, TYPE_BANSHEE, VOODOO_BANSHEE, 0);
|
||||
}
|
||||
static void *v3_2000_init(const device_t *info)
|
||||
{
|
||||
return banshee_init_common(info, L"roms/video/voodoo/2k11sd.rom", 0, TYPE_V3_2000, VOODOO_3, 0);
|
||||
return banshee_init_common(info, "roms/video/voodoo/2k11sd.rom", 0, TYPE_V3_2000, VOODOO_3, 0);
|
||||
}
|
||||
static void *v3_2000_agp_init(const device_t *info)
|
||||
{
|
||||
return banshee_init_common(info, L"roms/video/voodoo/2k11sd.rom", 0, TYPE_V3_2000, VOODOO_3, 1);
|
||||
return banshee_init_common(info, "roms/video/voodoo/2k11sd.rom", 0, TYPE_V3_2000, VOODOO_3, 1);
|
||||
}
|
||||
static void *v3_2000_agp_onboard_init(const device_t *info)
|
||||
{
|
||||
@@ -2856,29 +2856,29 @@ static void *v3_2000_agp_onboard_init(const device_t *info)
|
||||
}
|
||||
static void *v3_3000_init(const device_t *info)
|
||||
{
|
||||
return banshee_init_common(info, L"roms/video/voodoo/3k12sd.rom", 0, TYPE_V3_3000, VOODOO_3, 0);
|
||||
return banshee_init_common(info, "roms/video/voodoo/3k12sd.rom", 0, TYPE_V3_3000, VOODOO_3, 0);
|
||||
}
|
||||
static void *v3_3000_agp_init(const device_t *info)
|
||||
{
|
||||
return banshee_init_common(info, L"roms/video/voodoo/3k12sd.rom", 0, TYPE_V3_3000, VOODOO_3, 1);
|
||||
return banshee_init_common(info, "roms/video/voodoo/3k12sd.rom", 0, TYPE_V3_3000, VOODOO_3, 1);
|
||||
}
|
||||
|
||||
static int banshee_available(void)
|
||||
{
|
||||
return rom_present(L"roms/video/voodoo/Pci_sg.rom");
|
||||
return rom_present("roms/video/voodoo/Pci_sg.rom");
|
||||
}
|
||||
static int creative_banshee_available(void)
|
||||
{
|
||||
return rom_present(L"roms/video/voodoo/BlasterPCI.rom");
|
||||
return rom_present("roms/video/voodoo/BlasterPCI.rom");
|
||||
}
|
||||
static int v3_2000_available(void)
|
||||
{
|
||||
return rom_present(L"roms/video/voodoo/2k11sd.rom");
|
||||
return rom_present("roms/video/voodoo/2k11sd.rom");
|
||||
}
|
||||
#define v3_2000_agp_available v3_2000_available
|
||||
static int v3_3000_available(void)
|
||||
{
|
||||
return rom_present(L"roms/video/voodoo/3k12sd.rom");
|
||||
return rom_present("roms/video/voodoo/3k12sd.rom");
|
||||
}
|
||||
#define v3_3000_agp_available v3_3000_available
|
||||
|
||||
|
||||
@@ -906,7 +906,7 @@ void *wy700_init(const device_t *info)
|
||||
/* 128k video RAM */
|
||||
wy700->vram = malloc(0x20000);
|
||||
|
||||
loadfont(L"roms/video/wyse700/wy700.rom", 3);
|
||||
loadfont("roms/video/wyse700/wy700.rom", 3);
|
||||
|
||||
timer_add(&wy700->timer, wy700_poll, wy700, 1);
|
||||
|
||||
|
||||
@@ -317,7 +317,7 @@ static png_infop info_ptr;
|
||||
|
||||
|
||||
static void
|
||||
video_take_screenshot(const wchar_t *fn, int startx, int starty, int y1, int y2, int w, int h)
|
||||
video_take_screenshot(const char *fn, int startx, int starty, int y1, int y2, int w, int h)
|
||||
{
|
||||
int i, x, y;
|
||||
png_bytep *b_rgb = NULL;
|
||||
@@ -325,9 +325,9 @@ video_take_screenshot(const wchar_t *fn, int startx, int starty, int y1, int y2,
|
||||
uint32_t temp = 0x00000000;
|
||||
|
||||
/* create file */
|
||||
fp = plat_fopen((wchar_t *) fn, (wchar_t *) L"wb");
|
||||
fp = plat_fopen((char *) fn, (char *) "wb");
|
||||
if (!fp) {
|
||||
video_log("[video_take_screenshot] File %ls could not be opened for writing", fn);
|
||||
video_log("[video_take_screenshot] File %s could not be opened for writing", fn);
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -390,7 +390,7 @@ video_take_screenshot(const wchar_t *fn, int startx, int starty, int y1, int y2,
|
||||
static void
|
||||
video_screenshot(int x, int y, int y1, int y2, int w, int h)
|
||||
{
|
||||
wchar_t path[1024], fn[128];
|
||||
char path[1024], fn[128];
|
||||
|
||||
memset(fn, 0, sizeof(fn));
|
||||
memset(path, 0, sizeof(path));
|
||||
@@ -400,14 +400,14 @@ video_screenshot(int x, int y, int y1, int y2, int w, int h)
|
||||
if (! plat_dir_check(path))
|
||||
plat_dir_create(path);
|
||||
|
||||
wcscat(path, L"\\");
|
||||
plat_path_slash(path);
|
||||
|
||||
plat_tempfile(fn, NULL, L".png");
|
||||
wcscat(path, fn);
|
||||
plat_tempfile(fn, NULL, ".png");
|
||||
strcat(path, fn);
|
||||
|
||||
video_log("taking screenshot to: %S\n", path);
|
||||
video_log("taking screenshot to: %s\n", path);
|
||||
|
||||
video_take_screenshot((const wchar_t *) path, x, y, y1, y2, w, h);
|
||||
video_take_screenshot((const char *) path, x, y, y1, y2, w, h);
|
||||
png_destroy_write_struct(&png_ptr, &info_ptr);
|
||||
}
|
||||
|
||||
@@ -1051,11 +1051,11 @@ loadfont_common(FILE *f, int format)
|
||||
}
|
||||
|
||||
void
|
||||
loadfont_ex(wchar_t *s, int format, int offset)
|
||||
loadfont_ex(char *s, int format, int offset)
|
||||
{
|
||||
FILE *f;
|
||||
|
||||
f = rom_fopen(s, L"rb");
|
||||
f = rom_fopen(s, "rb");
|
||||
if (f == NULL)
|
||||
return;
|
||||
|
||||
@@ -1065,7 +1065,7 @@ loadfont_ex(wchar_t *s, int format, int offset)
|
||||
}
|
||||
|
||||
void
|
||||
loadfont(wchar_t *s, int format)
|
||||
loadfont(char *s, int format)
|
||||
{
|
||||
loadfont_ex(s, format, 0);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user