unsigned int p32x_event_times[P32X_EVENT_COUNT];
static unsigned int event_time_next;
static event_cb *p32x_event_cbs[P32X_EVENT_COUNT] = {
- [P32X_EVENT_PWM] = p32x_pwm_irq_event,
- [P32X_EVENT_FILLEND] = fillend_event,
- [P32X_EVENT_HINT] = hint_event,
+ p32x_pwm_irq_event, // P32X_EVENT_PWM
+ fillend_event, // P32X_EVENT_FILLEND
+ hint_event, // P32X_EVENT_HINT
};
// schedule event at some time 'after', in m68k clocks
for (l = 0; l < lines; l++) {
if (have_scan) {
PicoScan32xBegin(l + offs);
- dst = Pico.est.DrawLineDest + poffs;
+ dst = (unsigned short *)Pico.est.DrawLineDest + poffs;
}
for (p = 0; p < plen; p += 4) {
dst[p + 0] = pal[*pmd++];
PICO_INTERNAL void PicoPowerMCD(void)
{
+ int fmt_size;
+
SekCycleCntS68k = SekCycleAimS68k = 0;
- int fmt_size = sizeof(formatted_bram);
+ fmt_size = sizeof(formatted_bram);
memset(Pico_mcd->prg_ram, 0, sizeof(Pico_mcd->prg_ram));
memset(Pico_mcd->word_ram2M, 0, sizeof(Pico_mcd->word_ram2M));
memset(Pico_mcd->pcm_ram, 0, sizeof(Pico_mcd->pcm_ram));
unsigned int pcd_event_times[PCD_EVENT_COUNT];
static unsigned int event_time_next;
static event_cb *pcd_event_cbs[PCD_EVENT_COUNT] = {
- [PCD_EVENT_CDC] = pcd_cdc_event,
- [PCD_EVENT_TIMER3] = pcd_int3_timer_event,
- [PCD_EVENT_GFX] = gfx_update,
- [PCD_EVENT_DMA] = pcd_dma_event,
+ pcd_cdc_event, // PCD_EVENT_CDC
+ pcd_int3_timer_event, // PCD_EVENT_TIMER3
+ gfx_update, // PCD_EVENT_GFX
+ pcd_dma_event, // PCD_EVENT_DMA
};
void pcd_event_schedule(unsigned int now, enum pcd_event event, int after)
{\r
DrawLineDestBase = dest;\r
DrawLineDestIncrement = increment;\r
- Pico.est.DrawLineDest = DrawLineDestBase + Pico.est.DrawScanline * increment;\r
+ Pico.est.DrawLineDest = (char *)DrawLineDestBase + Pico.est.DrawScanline * increment;\r
}\r
\r
void PicoDrawSetInternalBuf(void *dest, int increment)\r
#define ALIGNED(n)
#endif
+#ifdef _MSC_VER
+#define snprintf _snprintf
+#define strcasecmp _stricmp
+#define strncasecmp _strnicmp
+#define strdup _strdup
+#endif
+
#endif // PICO_PORT_INCLUDED
void emu_video_mode_change(int start_line, int line_count, int is_32cols)
{
+ struct retro_system_av_info av_info;
+
memset(vout_buf, 0, 320 * 240 * 2);
vout_width = is_32cols ? 256 : 320;
PicoDrawSetOutBuf(vout_buf, vout_width * 2);
vout_offset = vout_width * start_line;
// Update the geometry
- struct retro_system_av_info av_info;
retro_get_system_av_info(&av_info);
environ_cb(RETRO_ENVIRONMENT_SET_GEOMETRY, &av_info);
}
void retro_get_system_av_info(struct retro_system_av_info *info)
{
+ float common_width;
+
memset(info, 0, sizeof(*info));
info->timing.fps = Pico.m.pal ? 50 : 60;
info->timing.sample_rate = 44100;
info->geometry.max_width = vout_width;
info->geometry.max_height = vout_height;
- float common_width = vout_width;
+ common_width = vout_width;
if (user_vout_width != 0)
common_width = user_vout_width;
static void update_variables(void)
{
struct retro_variable var;
+ int OldPicoRegionOverride;
+ float old_user_vout_width;
var.value = NULL;
var.key = "picodrive_input1";
PicoOpt &= ~POPT_EN_MCD_RAMCART;
}
- int OldPicoRegionOverride = PicoRegionOverride;
+ OldPicoRegionOverride = PicoRegionOverride;
var.value = NULL;
var.key = "picodrive_region";
if (environ_cb(RETRO_ENVIRONMENT_GET_VARIABLE, &var) && var.value) {
PsndRerate(1);
}
- float old_user_vout_width = user_vout_width;
+ old_user_vout_width = user_vout_width;
var.value = NULL;
var.key = "picodrive_aspect";
if (environ_cb(RETRO_ENVIRONMENT_GET_VARIABLE, &var) && var.value) {
</PrecompiledHeader>\r
<WarningLevel>Level3</WarningLevel>\r
<Optimization>Disabled</Optimization>\r
- <PreprocessorDefinitions>WIN32;_DEBUG;_WINDOWS;_USRDLL;MSVC2010_EXPORTS;%(PreprocessorDefinitions);INLINE=_inline;_CRT_SECURE_NO_WARNINGS;EMU_F68K;_USE_CZ80;NO_ZLIB;FAMEC_NO_GOTOS</PreprocessorDefinitions>\r
+ <PreprocessorDefinitions>WIN32;_DEBUG;_WINDOWS;_USRDLL;MSVC2010_EXPORTS;%(PreprocessorDefinitions);_CRT_SECURE_NO_WARNINGS;EMU_F68K;_USE_CZ80;FAMEC_NO_GOTOS</PreprocessorDefinitions>\r
<CompileAs>CompileAsC</CompileAs>\r
- <AdditionalIncludeDirectories>$(SolutionDir)\..\..\..\;$(SolutionDIr)\..\..\..\pico;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>\r
+ <AdditionalIncludeDirectories>$(SolutionDir)\..\..\..\;$(SolutionDIr)\..\..\..\pico;$(SolutionDIr)\..\..\..\zlib;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>\r
+ <DisableSpecificWarnings>4018;4090;4101;4146;4244</DisableSpecificWarnings>\r
</ClCompile>\r
<Link>\r
<SubSystem>Windows</SubSystem>\r
<Optimization>MaxSpeed</Optimization>\r
<FunctionLevelLinking>true</FunctionLevelLinking>\r
<IntrinsicFunctions>true</IntrinsicFunctions>\r
- <PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;MSVC2010_EXPORTS;%(PreprocessorDefinitions);INLINE=_inline;_CRT_SECURE_NO_WARNINGS;EMU_F68K;_USE_CZ80;NO_ZLIB;FAMEC_NO_GOTOS</PreprocessorDefinitions>\r
+ <PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;MSVC2010_EXPORTS;%(PreprocessorDefinitions);_CRT_SECURE_NO_WARNINGS;EMU_F68K;_USE_CZ80;FAMEC_NO_GOTOS</PreprocessorDefinitions>\r
<CompileAs>CompileAsC</CompileAs>\r
- <AdditionalIncludeDirectories>$(SolutionDir)\..\..\..\;$(SolutionDIr)\..\..\..\pico;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>\r
+ <AdditionalIncludeDirectories>$(SolutionDir)\..\..\..\;$(SolutionDIr)\..\..\..\pico;$(SolutionDIr)\..\..\..\zlib;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>\r
+ <DisableSpecificWarnings>4018;4090;4101;4146;4244</DisableSpecificWarnings>\r
</ClCompile>\r
<Link>\r
<SubSystem>Windows</SubSystem>\r
<ClCompile Include="..\..\..\..\cpu\sh2\mame\sh2pico.c" />\r
<ClCompile Include="..\..\..\..\cpu\sh2\sh2.c" />\r
<ClCompile Include="..\..\..\..\pico\32x\32x.c" />\r
- <ClCompile Include="..\..\..\..\pico\32x\32x_draw.c" />\r
- <ClCompile Include="..\..\..\..\pico\32x\32x_memory.c" />\r
+ <ClCompile Include="..\..\..\..\pico\32x\draw.c">\r
+ <ObjectFileName Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(IntDir)\32x\</ObjectFileName>\r
+ <ObjectFileName Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(IntDir)\32x\</ObjectFileName>\r
+ </ClCompile>\r
+ <ClCompile Include="..\..\..\..\pico\32x\memory.c">\r
+ <ObjectFileName Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(IntDir)\32x\</ObjectFileName>\r
+ <ObjectFileName Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(IntDir)\32x\</ObjectFileName>\r
+ </ClCompile>\r
<ClCompile Include="..\..\..\..\pico\32x\pwm.c" />\r
<ClCompile Include="..\..\..\..\pico\32x\sh2soc.c" />\r
<ClCompile Include="..\..\..\..\pico\cart.c" />\r
<ClCompile Include="..\..\..\..\pico\carthw\carthw.c" />\r
- <ClCompile Include="..\..\..\..\pico\carthw\svp\svp_memory.c" />\r
+ <ClCompile Include="..\..\..\..\pico\carthw\eeprom_spi.c" />\r
+ <ClCompile Include="..\..\..\..\pico\carthw\svp\memory.c">\r
+ <ObjectFileName Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(IntDir)\svp\</ObjectFileName>\r
+ <ObjectFileName Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(IntDir)\svp\</ObjectFileName>\r
+ </ClCompile>\r
<ClCompile Include="..\..\..\..\pico\carthw\svp\ssp16.c" />\r
<ClCompile Include="..\..\..\..\pico\carthw\svp\svp.c" />\r
<ClCompile Include="..\..\..\..\pico\carthw_cfg.c" />\r
<ClCompile Include="..\..\..\..\pico\cd\gfx.c" />\r
<ClCompile Include="..\..\..\..\pico\cd\gfx_dma.c" />\r
<ClCompile Include="..\..\..\..\pico\cd\mcd.c" />\r
- <ClCompile Include="..\..\..\..\pico\cd\cd_memory.c" />\r
- <ClCompile Include="..\..\..\..\pico\cd\cd_misc.c" />\r
+ <ClCompile Include="..\..\..\..\pico\cd\memory.c">\r
+ <ObjectFileName Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(IntDir)\cd\</ObjectFileName>\r
+ <ObjectFileName Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(IntDir)\cd\</ObjectFileName>\r
+ </ClCompile>\r
+ <ClCompile Include="..\..\..\..\pico\cd\misc.c">\r
+ <ObjectFileName Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(IntDir)\cd\</ObjectFileName>\r
+ <ObjectFileName Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(IntDir)\cd\</ObjectFileName>\r
+ </ClCompile>\r
<ClCompile Include="..\..\..\..\pico\cd\pcm.c" />\r
- <ClCompile Include="..\..\..\..\pico\cd\cd_sek.c" />\r
+ <ClCompile Include="..\..\..\..\pico\cd\sek.c">\r
+ <ObjectFileName Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(IntDir)\cd\</ObjectFileName>\r
+ <ObjectFileName Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(IntDir)\cd\</ObjectFileName>\r
+ </ClCompile>\r
<ClCompile Include="..\..\..\..\pico\debug.c" />\r
<ClCompile Include="..\..\..\..\pico\draw.c" />\r
<ClCompile Include="..\..\..\..\pico\draw2.c" />\r
<ClCompile Include="..\..\..\..\pico\mode4.c" />\r
<ClCompile Include="..\..\..\..\pico\patch.c" />\r
<ClCompile Include="..\..\..\..\pico\pico.c" />\r
- <ClCompile Include="..\..\..\..\pico\pico\pico_memory.c" />\r
- <ClCompile Include="..\..\..\..\pico\pico\pico_pico.c" />\r
+ <ClCompile Include="..\..\..\..\pico\pico\memory.c">\r
+ <ObjectFileName Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(IntDir)\pico\</ObjectFileName>\r
+ <ObjectFileName Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(IntDir)\pico\</ObjectFileName>\r
+ </ClCompile>\r
+ <ClCompile Include="..\..\..\..\pico\pico\pico.c">\r
+ <ObjectFileName Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(IntDir)\pico\</ObjectFileName>\r
+ <ObjectFileName Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(IntDir)\pico\</ObjectFileName>\r
+ </ClCompile>\r
<ClCompile Include="..\..\..\..\pico\pico\xpcm.c" />\r
<ClCompile Include="..\..\..\..\pico\sek.c" />\r
<ClCompile Include="..\..\..\..\pico\sms.c" />\r
<ClCompile Include="..\..\..\..\pico\videoport.c" />\r
<ClCompile Include="..\..\..\..\pico\z80if.c" />\r
<ClCompile Include="..\..\..\..\unzip\unzip.c" />\r
- <ClCompile Include="..\..\..\..\unzip\unzip_stream.c" />\r
<ClCompile Include="..\..\..\..\zlib\adler32.c" />\r
<ClCompile Include="..\..\..\..\zlib\compress.c" />\r
<ClCompile Include="..\..\..\..\zlib\crc32.c" />\r
<ClCompile Include="..\..\..\..\unzip\unzip.c">\r
<Filter>Source Files\unzip</Filter>\r
</ClCompile>\r
- <ClCompile Include="..\..\..\..\unzip\unzip_stream.c">\r
- <Filter>Source Files\unzip</Filter>\r
- </ClCompile>\r
<ClCompile Include="..\..\..\..\pico\cart.c">\r
<Filter>Source Files\pico</Filter>\r
</ClCompile>\r
<ClCompile Include="..\..\..\..\pico\cd\mcd.c">\r
<Filter>Source Files\pico\cd</Filter>\r
</ClCompile>\r
- <ClCompile Include="..\..\..\..\pico\cd\cd_memory.c">\r
+ <ClCompile Include="..\..\..\..\pico\cd\memory.c">\r
<Filter>Source Files\pico\cd</Filter>\r
</ClCompile>\r
- <ClCompile Include="..\..\..\..\pico\cd\cd_misc.c">\r
+ <ClCompile Include="..\..\..\..\pico\cd\misc.c">\r
<Filter>Source Files\pico\cd</Filter>\r
</ClCompile>\r
<ClCompile Include="..\..\..\..\pico\cd\pcm.c">\r
<Filter>Source Files\pico\cd</Filter>\r
</ClCompile>\r
- <ClCompile Include="..\..\..\..\pico\cd\cd_sek.c">\r
+ <ClCompile Include="..\..\..\..\pico\cd\sek.c">\r
<Filter>Source Files\pico\cd</Filter>\r
</ClCompile>\r
<ClCompile Include="..\..\..\..\pico\32x\32x.c">\r
<Filter>Source Files\pico\32x</Filter>\r
</ClCompile>\r
- <ClCompile Include="..\..\..\..\pico\32x\32x_memory.c">\r
+ <ClCompile Include="..\..\..\..\pico\32x\memory.c">\r
<Filter>Source Files\pico\32x</Filter>\r
</ClCompile>\r
<ClCompile Include="..\..\..\..\pico\32x\pwm.c">\r
<ClCompile Include="..\..\..\..\pico\carthw\carthw.c">\r
<Filter>Source Files\pico\carthw</Filter>\r
</ClCompile>\r
- <ClCompile Include="..\..\..\..\pico\carthw\svp\svp_memory.c">\r
+ <ClCompile Include="..\..\..\..\pico\carthw\eeprom_spi.c">\r
+ <Filter>Source Files\pico\carthw</Filter>\r
+ </ClCompile>\r
+ <ClCompile Include="..\..\..\..\pico\carthw\svp\memory.c">\r
<Filter>Source Files\pico\carthw\svp</Filter>\r
</ClCompile>\r
<ClCompile Include="..\..\..\..\pico\carthw\svp\ssp16.c">\r
<ClCompile Include="..\..\..\..\cpu\sh2\mame\sh2pico.c">\r
<Filter>Source Files\cpu\sh2\mame</Filter>\r
</ClCompile>\r
- <ClCompile Include="..\..\..\..\pico\32x\32x_draw.c">\r
- <Filter>Source Files</Filter>\r
- </ClCompile>\r
- <ClCompile Include="..\..\..\..\pico\pico\pico_memory.c">\r
+ <ClCompile Include="..\..\..\..\pico\pico\xpcm.c">\r
<Filter>Source Files\pico\pico</Filter>\r
</ClCompile>\r
- <ClCompile Include="..\..\..\..\pico\pico\pico_pico.c">\r
+ <ClCompile Include="..\..\..\..\pico\pico\pico.c">\r
<Filter>Source Files\pico\pico</Filter>\r
</ClCompile>\r
- <ClCompile Include="..\..\..\..\pico\pico\xpcm.c">\r
+ <ClCompile Include="..\..\..\..\pico\pico\memory.c">\r
<Filter>Source Files\pico\pico</Filter>\r
</ClCompile>\r
+ <ClCompile Include="..\..\..\..\pico\32x\draw.c">\r
+ <Filter>Source Files\pico\32x</Filter>\r
+ </ClCompile>\r
</ItemGroup>\r
</Project>
\ No newline at end of file