update to Mednafen 0.9.39-unstable : psx, sio

This commit is contained in:
zeromus 2020-04-05 23:19:05 -04:00
parent 827115ee9f
commit aff26ee02e
6 changed files with 102 additions and 42 deletions

View File

@ -102,4 +102,7 @@
[OK] psx/input/* : (c) [OK] psx/input/* : (c)
[OK] psx/irq : (c) [OK] psx/irq : (c)
[OK] psx/masmem : (c) [OK] psx/masmem : (c)
[OK] psx/mdec : [OK] psx/mdec : (c), opts,
[NO] psx/psx : cheats support
[OK] psx/psx : (c), cnf parse
[OK] psx/sio : (c)

View File

@ -340,12 +340,8 @@ class PS_GPU
int32 *LineWidths; int32 *LineWidths;
int LineVisFirst, LineVisLast; int LineVisFirst, LineVisLast;
int32 hmc_to_visible; int32 hmc_to_visible;
const bool HardwarePALType;
uint32 OutputLUT[384]; uint32 OutputLUT[384];
//
//
// Y, X
uint16 GPURAM[512][1024];
void ReorderRGB_Var(uint32 out_Rshift, uint32 out_Gshift, uint32 out_Bshift, bool bpp24, const uint16 *src, uint32 *dest, const int32 dx_start, const int32 dx_end, int32 fb_x); void ReorderRGB_Var(uint32 out_Rshift, uint32 out_Gshift, uint32 out_Bshift, bool bpp24, const uint16 *src, uint32 *dest, const int32 dx_start, const int32 dx_end, int32 fb_x);
template<uint32 out_Rshift, uint32 out_Gshift, uint32 out_Bshift> template<uint32 out_Rshift, uint32 out_Gshift, uint32 out_Bshift>
@ -355,6 +351,10 @@ class PS_GPU
uint32 GetVertStart() { return VertStart; } uint32 GetVertStart() { return VertStart; }
uint32 GetVertEnd() { return VertEnd; } uint32 GetVertEnd() { return VertEnd; }
int FirstLine; int FirstLine;
const bool HardwarePALType;
// Y, X
uint16 GPURAM[512][1024];
}; };
} }

View File

@ -1,18 +1,22 @@
/* Mednafen - Multi-system Emulator /******************************************************************************/
* /* Mednafen Sony PS1 Emulation Module */
* This program is free software; you can redistribute it and/or modify /******************************************************************************/
* it under the terms of the GNU General Public License as published by /* psx.cpp:
* the Free Software Foundation; either version 2 of the License, or ** Copyright (C) 2011-2016 Mednafen Team
* (at your option) any later version. **
* ** This program is free software; you can redistribute it and/or
* This program is distributed in the hope that it will be useful, ** modify it under the terms of the GNU General Public License
* but WITHOUT ANY WARRANTY; without even the implied warranty of ** as published by the Free Software Foundation; either version 2
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ** of the License, or (at your option) any later version.
* GNU General Public License for more details. **
* ** This program is distributed in the hope that it will be useful,
* You should have received a copy of the GNU General Public License ** but WITHOUT ANY WARRANTY; without even the implied warranty of
* along with this program; if not, write to the Free Software ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA ** GNU General Public License for more details.
**
** You should have received a copy of the GNU General Public License
** along with this program; if not, write to the Free Software Foundation, Inc.,
** 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*/ */
#include "octoshock.h" #include "octoshock.h"
@ -2423,7 +2427,7 @@ EW_EXPORT s32 shock_AnalyzeDisc(ShockDiscRef* disc, ShockDiscInfo* info)
fp->seek((int64)rdel * 2048, SEEK_SET); fp->seek((int64)rdel * 2048, SEEK_SET);
//printf("%08x, %08x\n", rdel * 2048, rdel_len); //printf("%08x, %08x\n", rdel * 2048, rdel_len);
//I think this loop is scanning directory entries until it finds system.cnf and if it never finishes we'll jsut fall out //I think this loop is scanning directory entries until it finds system.cnf and if it never finishes we'll just fall out
while(fp->tell() < (((int64)rdel * 2048) + rdel_len)) while(fp->tell() < (((int64)rdel * 2048) + rdel_len))
{ {
uint8 len_dr = fp->get_u8(); uint8 len_dr = fp->get_u8();
@ -2457,11 +2461,18 @@ EW_EXPORT s32 shock_AnalyzeDisc(ShockDiscRef* disc, ShockDiscInfo* info)
{ {
bootpos++; bootpos++;
while(*bootpos == ' ' || *bootpos == '\t') bootpos++; while(*bootpos == ' ' || *bootpos == '\t') bootpos++;
if(!strncasecmp(bootpos, "cdrom:\\", 7)) if(!strncasecmp(bootpos, "cdrom:", 6))
{ {
bootpos += 7;
char* tmp; char* tmp;
bootpos += 6;
// strrchr() way will pick up Tekken 3, but only enable if needed due to possibility of regressions.
//if((tmp = strrchr(bootpos, '\\')))
// bootpos = tmp + 1;
while(*bootpos == '\\')
bootpos++;
if((tmp = strchr(bootpos, '_'))) *tmp = 0; if((tmp = strchr(bootpos, '_'))) *tmp = 0;
if((tmp = strchr(bootpos, '.'))) *tmp = 0; if((tmp = strchr(bootpos, '.'))) *tmp = 0;
if((tmp = strchr(bootpos, ';'))) *tmp = 0; if((tmp = strchr(bootpos, ';'))) *tmp = 0;

View File

@ -1,3 +1,24 @@
/******************************************************************************/
/* Mednafen Sony PS1 Emulation Module */
/******************************************************************************/
/* psx.h:
** Copyright (C) 2011-2016 Mednafen Team
**
** This program is free software; you can redistribute it and/or
** modify it under the terms of the GNU General Public License
** as published by the Free Software Foundation; either version 2
** 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 General Public License for more details.
**
** You should have received a copy of the GNU General Public License
** along with this program; if not, write to the Free Software Foundation, Inc.,
** 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*/
#pragma once #pragma once
#include "octoshock.h" #include "octoshock.h"

View File

@ -1,18 +1,22 @@
/* Mednafen - Multi-system Emulator /******************************************************************************/
* /* Mednafen Sony PS1 Emulation Module */
* This program is free software; you can redistribute it and/or modify /******************************************************************************/
* it under the terms of the GNU General Public License as published by /* sio.cpp:
* the Free Software Foundation; either version 2 of the License, or ** Copyright (C) 2011-2016 Mednafen Team
* (at your option) any later version. **
* ** This program is free software; you can redistribute it and/or
* This program is distributed in the hope that it will be useful, ** modify it under the terms of the GNU General Public License
* but WITHOUT ANY WARRANTY; without even the implied warranty of ** as published by the Free Software Foundation; either version 2
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ** of the License, or (at your option) any later version.
* GNU General Public License for more details. **
* ** This program is distributed in the hope that it will be useful,
* You should have received a copy of the GNU General Public License ** but WITHOUT ANY WARRANTY; without even the implied warranty of
* along with this program; if not, write to the Free Software ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA ** GNU General Public License for more details.
**
** You should have received a copy of the GNU General Public License
** along with this program; if not, write to the Free Software Foundation, Inc.,
** 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*/ */
#include "psx.h" #include "psx.h"

View File

@ -1,3 +1,24 @@
/******************************************************************************/
/* Mednafen Sony PS1 Emulation Module */
/******************************************************************************/
/* sio.h:
** Copyright (C) 2011-2016 Mednafen Team
**
** This program is free software; you can redistribute it and/or
** modify it under the terms of the GNU General Public License
** as published by the Free Software Foundation; either version 2
** 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 General Public License for more details.
**
** You should have received a copy of the GNU General Public License
** along with this program; if not, write to the Free Software Foundation, Inc.,
** 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*/
#ifndef __MDFN_PSX_SIO_H #ifndef __MDFN_PSX_SIO_H
#define __MDFN_PSX_SIO_H #define __MDFN_PSX_SIO_H