From: Shamus Hammons Date: Fri, 22 Jul 2011 23:24:54 +0000 (+0000) Subject: Small code cleanups, file picker now grabs everything it knows about by X-Git-Tag: 2.0.0~8 X-Git-Url: http://shamusworld.gotdns.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=828059a53ae8bfb03ade4acd1e62c8de9be89775;p=virtualjaguar Small code cleanups, file picker now grabs everything it knows about by default. To look at even stuff VJ *doesn't* understand can be overridden by a config option. --- diff --git a/docs/INSTALL b/docs/INSTALL index 6947f49..299e206 100644 --- a/docs/INSTALL +++ b/docs/INSTALL @@ -17,10 +17,6 @@ The minimum requirements for compiling Virtual Jaguar from source are: o supported OS (BeOS, Linux, FreeBSD and WIN32 through mingw, MacOS); other OSs may work to but you may need to change some items in the Makefile. -Optionally you'll need an Atari Jaguar boot ROM (and/or CD boot ROM) which is -available on the Internet. We can't include the boot ROM since it's still -copyrighted. - COMPILING: ---------- @@ -31,15 +27,12 @@ decompressed the source: make -Optionally you can manually strip vj[.exe] to downsize the binary. If you have -upx in your path somewhere, you can uncomment the line in the makefile that -executes upx so that you'll end up with a somewhat smaller binary. +Optionally you can manually strip virtualjaguar[.exe] to downsize the binary. +You can also run upx on the binary as well and you'll end up with a somewhat +smaller binary. That's it! You can now start the emulator with ./virtualjaguar. See the output for more details (or stdout.txt on Win32) or consult the README file for more info. -For even more info, go to http://sdlemu.ngemu.com or send use an e-mail to the -following e-mail address: sdlemu AT ngemu DOT com. - -SDLEMU +For even more info, go to http://icculus.org/virtualjaguar. diff --git a/docs/README b/docs/README index 30c8477..da59ae4 100644 --- a/docs/README +++ b/docs/README @@ -15,11 +15,10 @@ software requirements. The use of this software is entirely at your own risk. While it won't rape your dog, it might do other nasty things. We can't be held responsible for -damage done to you hardware and/or software. You have been warned! This -software may require the use of the Atari Jaguar boot ROMs and/or Commercial -ROM images. You may only use the ROM images if you own the cartridges itself. -The use of Commercial ROMs without owning the original cartridge is illegal in -most countries and could result in fines and/or legal actions. +damage done to you hardware and/or software. You have been warned! You may only +use the ROM images if you own the cartridges itself. The use of Commercial ROMs +without owning the original cartridge is illegal in most countries and could +result in fines and/or legal actions. This software is released under the GPL v3 or later. For more information I direct you to the GPLv3 file. You may hack/change the code anyway you like. You @@ -113,13 +112,11 @@ games. These games are distributed on cartridges and can therefore cannot be used on a PC (we're still waiting for that Jaguar-on-a-PCI-card that you plug into your late model PC, complete with cartridge slot and controller connectors ;-). To use these games on Virtual Jaguar GCC/Qt you need to get ROM images. -Besides the ROM images from commercial games, you may also need to obtain the -Atari Jaguar boot ROM (and/or CD boot ROM) which you must copy to the BIOS -directory. For legal issues concerning ROM images please consult the DISCLAIMER -at the beginning of this file. +For legal issues concerning ROM images please consult the DISCLAIMER at the +beginning of this file. -After obtaining the Atari Jaguar boot ROM (and/or CD boot ROM) and several game -ROMs you can now use Virtual Jaguar using the following command: +After obtaining several game ROMs you can now use Virtual Jaguar using the +following command: ./virtualjaguar [romfile] [-switches] diff --git a/docs/TODO b/docs/TODO index 04d0a4e..484709d 100644 --- a/docs/TODO +++ b/docs/TODO @@ -3,8 +3,6 @@ Stuff to add/fix for the next release of Virtual Jaguar - Fix DSP code so that it doesn't hang in a spinlock waiting for the sound buffer to empty. Probably a CS lock contention issue. [Shamus] -- Make sure that VJ doesn't crash if the useJaguarBIOS key is set to 1 and the - BIOS file isn't available. [Shamus] - Create an EEPROMs directory (or whatever is in EEPROMPath[]) if it doesn't already exist. [Shamus] - It would be nice to have the emulator pick up where you last left off, or at @@ -15,22 +13,26 @@ Stuff to add/fix for the next release of Virtual Jaguar - Cycle accuracy for GPU/DSP/OP/Blitter. [Shamus] - Need to propagate blitter fixes in the A1 <- A2 direction to the A1 -> A2 direction and the GPU fixes to various instructions to the DSP. [Shamus] -- Need to fix PAL mode to work with the virtual screen code. [Shamus] -- There are a few ROMs that use some "quasi-illegal" 68K instructions. Need - to patch the 68K core to deal with these in a better way than they are - now. [Shamus] -- Would also be nice to be able to dynamically change the keybindings for - the various keys on the emulated Jaguar controller while inside the emulator. - [Shamus] - Blitter needs fixing. [Shamus] -- We need a comprehensive way of determining what gets written where and - by whom (i.e., blitter wrote to range $F03000-$F03230) in order to figure - out the remaining problems with various ROMs. [Shamus] Stuff that was added/fixed -------------------------- +- Need to fix PAL mode to work with the virtual screen code. [DONE--Shamus] +- There are a few ROMs that use some "quasi-illegal" 68K instructions. Need + to patch the 68K core to deal with these in a better way than they are + now. [DONE--Shamus] + NOTE: This behavior was verified on Rayman, the problem was due to attempting + to press both left & right at the same time! +- We need a comprehensive way of determining what gets written where and + by whom (i.e., blitter wrote to range $F03000-$F03230) in order to figure + out the remaining problems with various ROMs. [DONE--Shamus] +- Would also be nice to be able to dynamically change the keybindings for + the various keys on the emulated Jaguar controller while inside the emulator. + [DONE--Shamus] +- Make sure that VJ doesn't crash if the useJaguarBIOS key is set to 1 and the + BIOS file isn't available. [DONE--Shamus] - There is a bug either with the GPU or the blitter (most likely the latter) which causes the spinning "A"s in the BIOS startup code to be corrupted when they are showing their backsides. [Shamus] [DONE--Shamus] diff --git a/docs/WHATSNEW b/docs/WHATSNEW index e77cad0..6d5d3a6 100644 --- a/docs/WHATSNEW +++ b/docs/WHATSNEW @@ -6,6 +6,8 @@ Virtual Jaguar v2.0.0 GCC/Qt means is that now you can have other goodies inside of your ROM ZIP like labels, box art, and overlays. See README for details. [Shamus] * Various usability improvements, too many to list here. ;-) [Shamus] +* Various compatibility improvemnents to the Jaguar core, too many to list + here. ;-) [Shamus] Virtual Jaguar v1.1.0 GCC/SDL (r299 - Never officially released) diff --git a/src/filedb.cpp b/src/filedb.cpp index 50105b9..2e80818 100644 --- a/src/filedb.cpp +++ b/src/filedb.cpp @@ -81,7 +81,7 @@ RomIdentifier romList[] = { { 0x83A3FB5D, "Towers II", FF_ROM | FF_VERIFIED }, { 0x892BC67C, "Flip Out! (World)", FF_ROM | FF_VERIFIED }, { 0x8975F48B, "Zool 2 (World)", FF_ROM | FF_VERIFIED }, - { 0x89DA21FF, "Phase Zero", FF_ALPINE | FF_VERIFIED }, + { 0x89DA21FF, "Phase Zero", FF_ALPINE | FF_VERIFIED | FF_REQ_DSP }, { 0x8D15DBC6, "[BIOS] Atari Jaguar Stubulator '94 (World)", FF_BIOS }, { 0x8FEA5AB0, "Dragon - The Bruce Lee Story (World)", FF_ROM | FF_VERIFIED }, { 0x91095DD3, "Brett Hull Hockey", FF_ROM | FF_VERIFIED }, @@ -117,7 +117,7 @@ RomIdentifier romList[] = { { 0xE28756DE, "Atari Karts (World)", FF_ROM | FF_VERIFIED }, { 0xE60277BB, "[BIOS] Atari Jaguar Stubulator '93 (World)", FF_BIOS }, { 0xE91BD644, "Wolfenstein 3D (World)", FF_ROM | FF_VERIFIED }, - { 0xEA9B3FA7, "Phase Zero", FF_ROM }, + { 0xEA9B3FA7, "Phase Zero", FF_ROM | FF_REQ_DSP }, { 0xEC22F572, "SuperCross 3D (World)", FF_ROM | FF_VERIFIED }, { 0xECF854E7, "Cybermorph (World) (Rev 2)", FF_ROM | FF_REQ_DSP }, { 0xEEE8D61D, "Club Drive (World)", FF_ROM | FF_VERIFIED }, diff --git a/src/gui/controllerwidget.cpp b/src/gui/controllerwidget.cpp index c5167b1..1125929 100644 --- a/src/gui/controllerwidget.cpp +++ b/src/gui/controllerwidget.cpp @@ -132,13 +132,13 @@ void ControllerWidget::paintEvent(QPaintEvent * /*event*/) } } -void ControllerWidget::mousePressEvent(QMouseEvent * event) +void ControllerWidget::mousePressEvent(QMouseEvent * /*event*/) { mouseDown = true; update(); } -void ControllerWidget::mouseReleaseEvent(QMouseEvent * event) +void ControllerWidget::mouseReleaseEvent(QMouseEvent * /*event*/) { mouseDown = false; // Spawning the keygrabber causes leaveEvent() to be called, so we need to save this @@ -164,7 +164,6 @@ void ControllerWidget::mouseMoveEvent(QMouseEvent * event) // Save the current closest item int keyToHighlightOld = keyToHighlight; // Set up closest distance (this should be large enough) -// uint32_t closestX = 100000, closestY = 100000; double closest = 1e9; for(int i=BUTTON_FIRST; i<=BUTTON_LAST; i++) @@ -188,7 +187,6 @@ void ControllerWidget::mouseMoveEvent(QMouseEvent * event) void ControllerWidget::leaveEvent(QEvent * /*event*/) { keyToHighlight = -1; -// mouseDown = false; update(); } diff --git a/src/gui/filepicker.cpp b/src/gui/filepicker.cpp index f6b546d..2082ee9 100644 --- a/src/gui/filepicker.cpp +++ b/src/gui/filepicker.cpp @@ -108,7 +108,9 @@ printf("VSB size: %u, %u\n", sbSize3.width(), sbSize3.height()); // fileList->verticalScrollBar()->setSizePolicy(QSizePolicy::Minimum, QSizePolicy::Preferred); // (488/4) + 4 is the width of the object in the filelistmodel. Dunno why the QListView // isn't picking that up. :-( - fileList->setFixedWidth((488/4) + 4 + sbWidth);//ick + // 488/4 + 4 = 126 + // 126 + 17 + 4 = 147 <-- correct width + fileList->setFixedWidth((488/4) + 4 + sbWidth2 + sbWidth5 + 1);//ick // fileList->setFixedWidth((488/4) + 4 + 17 + 4);//sbWidth);//ick // fileList->setSpacing(4); @@ -153,9 +155,9 @@ printf("VSB size: %u, %u\n", sbSize3.width(), sbSize3.height()); dataLayout->addWidget(labels); data = new QLabel(QString(tr( "?MB Cartridge
" - "????????
" - "???
" - "???" + "00000000
" + "?
" + "?" ))); data->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Preferred); dataLayout->addWidget(data); diff --git a/src/gui/filethread.cpp b/src/gui/filethread.cpp index 30aeae8..3b8793c 100644 --- a/src/gui/filethread.cpp +++ b/src/gui/filethread.cpp @@ -140,9 +140,9 @@ void FileThread::HandleFile(QFileInfo fileInfo) uint32 index = FindCRCIndexInFileList(crc); delete[] buffer; - // Here we filter out files *not* in the DB (if configured that way) and - // BIOS files. - if (index == 0xFFFFFFFF) + // Here we filter out files that are *not* in the DB and of unknown type, + // and BIOS files. If desired, this can be overriden with a config option. + if ((index == 0xFFFFFFFF) && (fileType == JST_NONE)) { // If we allow unknown software, we pass the (-1) index on, otherwise... if (!allowUnknownSoftware) diff --git a/src/gui/generaltab.cpp b/src/gui/generaltab.cpp index 777fbaf..a9f824a 100644 --- a/src/gui/generaltab.cpp +++ b/src/gui/generaltab.cpp @@ -56,7 +56,7 @@ GeneralTab::GeneralTab(QWidget * parent/*= 0*/): QWidget(parent) useBIOS = new QCheckBox(tr("Enable Jaguar BIOS")); useDSP = new QCheckBox(tr("Enable DSP")); useHostAudio = new QCheckBox(tr("Enable audio playback (requires DSP)")); - useUnknownSoftware = new QCheckBox(tr("Allow unknown software in file chooser")); + useUnknownSoftware = new QCheckBox(tr("Show all files in file chooser")); layout4->addWidget(useBIOS); layout4->addWidget(useDSP); diff --git a/src/gui/mainwin.cpp b/src/gui/mainwin.cpp index 892fb1f..5c0f1b4 100644 --- a/src/gui/mainwin.cpp +++ b/src/gui/mainwin.cpp @@ -635,7 +635,7 @@ void MainWin::ReadSettings(void) pos = settings.value("cartLoadPos", QPoint(200, 200)).toPoint(); filePickWin->move(pos); - zoomLevel = settings.value("zoom", 1).toInt(); + zoomLevel = settings.value("zoom", 2).toInt(); allowUnknownSoftware = settings.value("showUnknownSoftware", false).toBool(); vjs.useJoystick = settings.value("useJoystick", false).toBool(); @@ -648,7 +648,7 @@ void MainWin::ReadSettings(void) vjs.usePipelinedDSP = settings.value("usePipelinedDSP", false).toBool(); vjs.fullscreen = settings.value("fullscreen", false).toBool(); vjs.useOpenGL = settings.value("useOpenGL", true).toBool(); - vjs.glFilter = settings.value("glFilterType", 0).toInt(); + vjs.glFilter = settings.value("glFilterType", 1).toInt(); vjs.renderType = settings.value("renderType", 0).toInt(); vjs.allowWritesToROM = settings.value("writeROM", false).toBool(); // strcpy(vjs.jagBootPath, settings.value("JagBootROM", "./bios/[BIOS] Atari Jaguar (USA, Europe).zip").toString().toAscii().data()); @@ -666,15 +666,15 @@ WriteLog("AlpineROMPath = \"%s\"\n", vjs.alpineROMPath); WriteLog(" absROMPath = \"%s\"\n", vjs.absROMPath); // Keybindings in order of U, D, L, R, C, B, A, Op, Pa, 0-9, #, * - vjs.p1KeyBindings[BUTTON_U] = settings.value("p1k_up", Qt::Key_Up).toInt(); - vjs.p1KeyBindings[BUTTON_D] = settings.value("p1k_down", Qt::Key_Down).toInt(); - vjs.p1KeyBindings[BUTTON_L] = settings.value("p1k_left", Qt::Key_Left).toInt(); - vjs.p1KeyBindings[BUTTON_R] = settings.value("p1k_right", Qt::Key_Right).toInt(); - vjs.p1KeyBindings[BUTTON_C] = settings.value("p1k_c", Qt::Key_Z).toInt(); - vjs.p1KeyBindings[BUTTON_B] = settings.value("p1k_b", Qt::Key_X).toInt(); - vjs.p1KeyBindings[BUTTON_A] = settings.value("p1k_a", Qt::Key_C).toInt(); - vjs.p1KeyBindings[BUTTON_OPTION] = settings.value("p1k_option", Qt::Key_Apostrophe).toInt(); - vjs.p1KeyBindings[BUTTON_PAUSE] = settings.value("p1k_pause", Qt::Key_Return).toInt(); + vjs.p1KeyBindings[BUTTON_U] = settings.value("p1k_up", Qt::Key_S).toInt(); + vjs.p1KeyBindings[BUTTON_D] = settings.value("p1k_down", Qt::Key_X).toInt(); + vjs.p1KeyBindings[BUTTON_L] = settings.value("p1k_left", Qt::Key_A).toInt(); + vjs.p1KeyBindings[BUTTON_R] = settings.value("p1k_right", Qt::Key_D).toInt(); + vjs.p1KeyBindings[BUTTON_C] = settings.value("p1k_c", Qt::Key_J).toInt(); + vjs.p1KeyBindings[BUTTON_B] = settings.value("p1k_b", Qt::Key_K).toInt(); + vjs.p1KeyBindings[BUTTON_A] = settings.value("p1k_a", Qt::Key_L).toInt(); + vjs.p1KeyBindings[BUTTON_OPTION] = settings.value("p1k_option", Qt::Key_O).toInt(); + vjs.p1KeyBindings[BUTTON_PAUSE] = settings.value("p1k_pause", Qt::Key_P).toInt(); vjs.p1KeyBindings[BUTTON_0] = settings.value("p1k_0", Qt::Key_0).toInt(); vjs.p1KeyBindings[BUTTON_1] = settings.value("p1k_1", Qt::Key_1).toInt(); vjs.p1KeyBindings[BUTTON_2] = settings.value("p1k_2", Qt::Key_2).toInt(); @@ -685,8 +685,8 @@ WriteLog(" absROMPath = \"%s\"\n", vjs.absROMPath); vjs.p1KeyBindings[BUTTON_7] = settings.value("p1k_7", Qt::Key_7).toInt(); vjs.p1KeyBindings[BUTTON_8] = settings.value("p1k_8", Qt::Key_8).toInt(); vjs.p1KeyBindings[BUTTON_9] = settings.value("p1k_9", Qt::Key_9).toInt(); - vjs.p1KeyBindings[BUTTON_d] = settings.value("p1k_pound", Qt::Key_Slash).toInt(); - vjs.p1KeyBindings[BUTTON_s] = settings.value("p1k_star", Qt::Key_Asterisk).toInt(); + vjs.p1KeyBindings[BUTTON_d] = settings.value("p1k_pound", Qt::Key_Minus).toInt(); + vjs.p1KeyBindings[BUTTON_s] = settings.value("p1k_star", Qt::Key_Equal).toInt(); vjs.p2KeyBindings[BUTTON_U] = settings.value("p2k_up", Qt::Key_Up).toInt(); vjs.p2KeyBindings[BUTTON_D] = settings.value("p2k_down", Qt::Key_Down).toInt();