diff --git a/AppleWinExpress2010.sln b/AppleWinExpress2010.sln deleted file mode 100644 index dcc5f672..00000000 --- a/AppleWinExpress2010.sln +++ /dev/null @@ -1,59 +0,0 @@ - -Microsoft Visual Studio Solution File, Format Version 11.00 -# Visual Studio 2010 -Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "AppleWin", "AppleWinExpress2010.vcxproj", "{1DA0C491-B5F4-4EC8-B1D2-CF6BE635DADC}" - ProjectSection(ProjectDependencies) = postProject - {5CE8051A-3F0C-4C39-B1C0-3338E48BA60F} = {5CE8051A-3F0C-4C39-B1C0-3338E48BA60F} - EndProjectSection -EndProject -Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "zlib", "zlib\zlib-Express2010.vcxproj", "{7935B998-C713-42AE-8F6D-9FF9080A1B1B}" -EndProject -Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "zip_lib", "zip_lib\zip_lib2010.vcxproj", "{709278B8-C583-4BD8-90DE-4E4F35A3BD8B}" -EndProject -Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "yaml", "libyaml\win32\yaml2010.vcxproj", "{5CE8051A-3F0C-4C39-B1C0-3338E48BA60F}" -EndProject -Global - GlobalSection(SolutionConfigurationPlatforms) = preSolution - Debug NoDX|Win32 = Debug NoDX|Win32 - Debug|Win32 = Debug|Win32 - Release NoDX|Win32 = Release NoDX|Win32 - Release|Win32 = Release|Win32 - EndGlobalSection - GlobalSection(ProjectConfigurationPlatforms) = postSolution - {1DA0C491-B5F4-4EC8-B1D2-CF6BE635DADC}.Debug NoDX|Win32.ActiveCfg = Debug NoDX|Win32 - {1DA0C491-B5F4-4EC8-B1D2-CF6BE635DADC}.Debug NoDX|Win32.Build.0 = Debug NoDX|Win32 - {1DA0C491-B5F4-4EC8-B1D2-CF6BE635DADC}.Debug|Win32.ActiveCfg = Debug|Win32 - {1DA0C491-B5F4-4EC8-B1D2-CF6BE635DADC}.Debug|Win32.Build.0 = Debug|Win32 - {1DA0C491-B5F4-4EC8-B1D2-CF6BE635DADC}.Release NoDX|Win32.ActiveCfg = Release NoDX|Win32 - {1DA0C491-B5F4-4EC8-B1D2-CF6BE635DADC}.Release NoDX|Win32.Build.0 = Release NoDX|Win32 - {1DA0C491-B5F4-4EC8-B1D2-CF6BE635DADC}.Release|Win32.ActiveCfg = Release|Win32 - {1DA0C491-B5F4-4EC8-B1D2-CF6BE635DADC}.Release|Win32.Build.0 = Release|Win32 - {7935B998-C713-42AE-8F6D-9FF9080A1B1B}.Debug NoDX|Win32.ActiveCfg = Debug NoDX|Win32 - {7935B998-C713-42AE-8F6D-9FF9080A1B1B}.Debug NoDX|Win32.Build.0 = Debug NoDX|Win32 - {7935B998-C713-42AE-8F6D-9FF9080A1B1B}.Debug|Win32.ActiveCfg = Debug|Win32 - {7935B998-C713-42AE-8F6D-9FF9080A1B1B}.Debug|Win32.Build.0 = Debug|Win32 - {7935B998-C713-42AE-8F6D-9FF9080A1B1B}.Release NoDX|Win32.ActiveCfg = Release NoDX|Win32 - {7935B998-C713-42AE-8F6D-9FF9080A1B1B}.Release NoDX|Win32.Build.0 = Release NoDX|Win32 - {7935B998-C713-42AE-8F6D-9FF9080A1B1B}.Release|Win32.ActiveCfg = Release|Win32 - {7935B998-C713-42AE-8F6D-9FF9080A1B1B}.Release|Win32.Build.0 = Release|Win32 - {709278B8-C583-4BD8-90DE-4E4F35A3BD8B}.Debug NoDX|Win32.ActiveCfg = Debug NoDX|Win32 - {709278B8-C583-4BD8-90DE-4E4F35A3BD8B}.Debug NoDX|Win32.Build.0 = Debug NoDX|Win32 - {709278B8-C583-4BD8-90DE-4E4F35A3BD8B}.Debug|Win32.ActiveCfg = Debug|Win32 - {709278B8-C583-4BD8-90DE-4E4F35A3BD8B}.Debug|Win32.Build.0 = Debug|Win32 - {709278B8-C583-4BD8-90DE-4E4F35A3BD8B}.Release NoDX|Win32.ActiveCfg = Release NoDX|Win32 - {709278B8-C583-4BD8-90DE-4E4F35A3BD8B}.Release NoDX|Win32.Build.0 = Release NoDX|Win32 - {709278B8-C583-4BD8-90DE-4E4F35A3BD8B}.Release|Win32.ActiveCfg = Release|Win32 - {709278B8-C583-4BD8-90DE-4E4F35A3BD8B}.Release|Win32.Build.0 = Release|Win32 - {5CE8051A-3F0C-4C39-B1C0-3338E48BA60F}.Debug NoDX|Win32.ActiveCfg = Debug|Win32 - {5CE8051A-3F0C-4C39-B1C0-3338E48BA60F}.Debug NoDX|Win32.Build.0 = Debug|Win32 - {5CE8051A-3F0C-4C39-B1C0-3338E48BA60F}.Debug|Win32.ActiveCfg = Debug|Win32 - {5CE8051A-3F0C-4C39-B1C0-3338E48BA60F}.Debug|Win32.Build.0 = Debug|Win32 - {5CE8051A-3F0C-4C39-B1C0-3338E48BA60F}.Release NoDX|Win32.ActiveCfg = Release|Win32 - {5CE8051A-3F0C-4C39-B1C0-3338E48BA60F}.Release NoDX|Win32.Build.0 = Release|Win32 - {5CE8051A-3F0C-4C39-B1C0-3338E48BA60F}.Release|Win32.ActiveCfg = Release|Win32 - {5CE8051A-3F0C-4C39-B1C0-3338E48BA60F}.Release|Win32.Build.0 = Release|Win32 - EndGlobalSection - GlobalSection(SolutionProperties) = preSolution - HideSolutionNode = FALSE - EndGlobalSection -EndGlobal diff --git a/AppleWinExpress2010.vcxproj b/AppleWinExpress2010.vcxproj deleted file mode 100644 index 447777fb..00000000 --- a/AppleWinExpress2010.vcxproj +++ /dev/null @@ -1,568 +0,0 @@ - - - - - Debug NoDX - Win32 - - - Debug - Win32 - - - Release NoDX - Win32 - - - Release - Win32 - - - - AppleWin - {1DA0C491-B5F4-4EC8-B1D2-CF6BE635DADC} - AppleWin - - - - Application - false - - - Application - false - - - Application - false - - - Application - false - - - - - - - - - - - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - false - false - true - true - - - - NDEBUG;%(PreprocessorDefinitions) - true - true - Win32 - .\Release/AppleWin.tlb - - - - - /Zm200 %(AdditionalOptions) - MaxSpeed - AnySuitable - true - Speed - true - true - source\cpu;source\emulator;source\debugger;zlib;zip_lib;libyaml\include;%(AdditionalIncludeDirectories) - WIN32;NDEBUG;_WINDOWS;_CRT_SECURE_NO_DEPRECATE;NO_DSHOW_STRSAFE;YAML_DECLARE_STATIC;%(PreprocessorDefinitions) - true - MultiThreaded - true - StreamingSIMDExtensions - Fast - Use - Level3 - true - ProgramDatabase - 4819;4996;%(DisableSpecificWarnings) - - - NDEBUG;%(PreprocessorDefinitions) - 0x0409 - - - htmlhelp.lib;comctl32.lib;ddraw.lib;winmm.lib;dsound.lib;dxguid.lib;version.lib;strmiids.lib;dinput8.lib;user32.lib;gdi32.lib;Advapi32.lib;shell32.lib;Comdlg32.lib;ole32.lib;wsock32.lib;%(AdditionalDependencies) - true - type=%27Win32%27 name=%27Microsoft.Windows.Common-Controls%27 version=%276.0.0.0%27 processorArchitecture=%27X86%27 publicKeyToken=%276595b64144ccf1df%27 language=%27*%27;%(AdditionalManifestDependencies) - true - Windows - UseLinkTimeCodeGeneration - false - - - MachineX86 - $(MSBuildProjectDirectory)\ddraw_lib\x86; - - - - - NDEBUG;%(PreprocessorDefinitions) - true - true - Win32 - .\Release/AppleWin.tlb - - - - - /Zm200 %(AdditionalOptions) - MaxSpeed - AnySuitable - true - Speed - true - true - source\cpu;source\emulator;source\debugger;zlib;zip_lib;libyaml\include;%(AdditionalIncludeDirectories) - WIN32;NDEBUG;_WINDOWS;_CRT_SECURE_NO_DEPRECATE;NO_DSHOW_STRSAFE;NO_DIRECT_X;%(PreprocessorDefinitions) - true - MultiThreaded - true - StreamingSIMDExtensions - Fast - Use - Level3 - true - ProgramDatabase - 4819;4996;%(DisableSpecificWarnings) - - - NDEBUG;%(PreprocessorDefinitions) - 0x0409 - - - htmlhelp.lib;comctl32.lib;winmm.lib;dsound.lib;version.lib;strmiids.lib;user32.lib;gdi32.lib;Advapi32.lib;shell32.lib;Comdlg32.lib;ole32.lib;wsock32.lib;%(AdditionalDependencies) - true - type=%27Win32%27 name=%27Microsoft.Windows.Common-Controls%27 version=%276.0.0.0%27 processorArchitecture=%27X86%27 publicKeyToken=%276595b64144ccf1df%27 language=%27*%27;%(AdditionalManifestDependencies) - true - Windows - UseLinkTimeCodeGeneration - false - - - MachineX86 - $(MSBuildProjectDirectory)\ddraw_lib\x86; - - - - - _DEBUG;%(PreprocessorDefinitions) - true - true - Win32 - .\Debug/AppleWin.tlb - - - - - /Zm200 %(AdditionalOptions) - Disabled - source\cpu;source\emulator;source\debugger;zlib;zip_lib;libyaml\include;%(AdditionalIncludeDirectories) - WIN32;_DEBUG;_WINDOWS;_CRT_SECURE_NO_DEPRECATE;NO_DSHOW_STRSAFE;YAML_DECLARE_STATIC;%(PreprocessorDefinitions) - true - MultiThreadedDebug - Use - true - Level3 - true - EditAndContinue - 4819;4996;%(DisableSpecificWarnings) - - - _DEBUG;%(PreprocessorDefinitions) - 0x0409 - - - htmlhelp.lib;comctl32.lib;ddraw.lib;winmm.lib;dsound.lib;dxguid.lib;version.lib;strmiids.lib;dinput8.lib;user32.lib;gdi32.lib;Advapi32.lib;shell32.lib;Comdlg32.lib;ole32.lib;wsock32.lib;%(AdditionalDependencies) - true - type=%27Win32%27 name=%27Microsoft.Windows.Common-Controls%27 version=%276.0.0.0%27 processorArchitecture=%27X86%27 publicKeyToken=%276595b64144ccf1df%27 language=%27*%27;%(AdditionalManifestDependencies) - true - Windows - false - - - MachineX86 - $(MSBuildProjectDirectory)\ddraw_lib\x86; - - - - - _DEBUG;%(PreprocessorDefinitions) - true - true - Win32 - .\Debug/AppleWin.tlb - - - - - /Zm200 %(AdditionalOptions) - Disabled - source\cpu;source\emulator;source\debugger;zlib;zip_lib;libyaml\include;%(AdditionalIncludeDirectories) - WIN32;_DEBUG;_WINDOWS;_CRT_SECURE_NO_DEPRECATE;NO_DSHOW_STRSAFE;NO_DIRECT_X;%(PreprocessorDefinitions) - true - MultiThreadedDebug - Use - true - Level3 - true - EditAndContinue - 4819;4996;%(DisableSpecificWarnings) - - - _DEBUG;%(PreprocessorDefinitions) - 0x0409 - - - htmlhelp.lib;comctl32.lib;winmm.lib;dsound.lib;version.lib;strmiids.lib;user32.lib;gdi32.lib;Advapi32.lib;shell32.lib;Comdlg32.lib;ole32.lib;wsock32.lib;%(AdditionalDependencies) - true - type=%27Win32%27 name=%27Microsoft.Windows.Common-Controls%27 version=%276.0.0.0%27 processorArchitecture=%27X86%27 publicKeyToken=%276595b64144ccf1df%27 language=%27*%27;%(AdditionalManifestDependencies) - true - Windows - false - - - MachineX86 - $(MSBuildProjectDirectory)\ddraw_lib\x86; - - - - - Use - Use - Use - Use - - - - - - - - - - - - - - - - - - Create - Create - Create - Create - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - %(PreprocessorDefinitions) - %(PreprocessorDefinitions) - RESOURCE;%(AdditionalIncludeDirectories) - RESOURCE;%(AdditionalIncludeDirectories) - %(PreprocessorDefinitions) - %(PreprocessorDefinitions) - RESOURCE;%(AdditionalIncludeDirectories) - RESOURCE;%(AdditionalIncludeDirectories) - - - - - {709278b8-c583-4bd8-90de-4e4f35a3bd8b} - false - - - {7935b998-c713-42ae-8f6d-9ff9080a1b1b} - false - - - {5CE8051A-3F0C-4C39-B1C0-3338E48BA60F} - - - - - - - - - \ No newline at end of file diff --git a/AppleWinExpress2010.vcxproj.filters b/AppleWinExpress2010.vcxproj.filters deleted file mode 100644 index 5511b4a4..00000000 --- a/AppleWinExpress2010.vcxproj.filters +++ /dev/null @@ -1,667 +0,0 @@ - - - - - {74e2a597-413f-447d-bcca-b755f3924e86} - .cpp - - - {7ec93303-838c-4cb5-a54b-d694078abacf} - - - {5895ee90-26c2-495f-b3d9-ec71379490bc} - - - {0a1a9684-44b6-4a75-932b-bd5ad687b71a} - - - {53d31f58-9328-4ff3-97e6-af038f620b03} - - - {330ce46b-9563-4908-836b-9f3a276fb741} - - - {9a51cc1a-a03e-4d1d-aa92-7742b7efe6f9} - - - {fb24dc7c-547e-41e6-990b-6d206564e70b} - - - {d136990f-68f2-478d-a8df-3f9458f50c2b} - - - {b777c079-2523-4d07-8819-27df18e56500} - - - {7537bc07-cf56-4c40-986c-3c2e05d23eec} - - - {6ecaa432-46b0-4795-a848-fc9a6f4f3706} - - - {b003a70c-a1f1-4502-a959-bbc35def32be} - .txt,.ico,.bmp,.rc - - - - - Source - - - Source\Debugger - - - Source\Debugger - - - Source\Debugger - - - Source\Debugger - - - Source\Debugger - - - Source\Debugger - - - Source\Debugger - - - Source\Debugger - - - Source\Debugger - - - Source\Debugger - - - Source\Debugger - - - Source\Debugger - - - Source\Uthernet - - - Source\Uthernet - - - Source\Uthernet - - - Source\Uthernet - - - Source\Z80VICE - - - Source\Z80VICE - - - Source\Z80VICE - - - Source\Emulator - - - Source\Emulator - - - Source\Emulator - - - Source\Emulator - - - Source\Emulator - - - Source\Emulator - - - Source\Emulator - - - Source\Emulator - - - Source\Emulator - - - Source\Emulator - - - Source\Emulator - - - Source\Emulator - - - Source\Emulator - - - Source\Emulator - - - Source\Emulator - - - Source\Emulator - - - Source\Emulator - - - Source\Emulator - - - Source\Emulator - - - Source\CPU - - - Source\Disk - - - Source\Disk - - - Source\Disk - - - Source\Disk - - - Source\Video - - - Source\Video - - - Source\Configuration - - - Source\Configuration - - - Source\Configuration - - - Source\Configuration - - - Source\Configuration - - - Source\Configuration - - - Source\Configuration - - - Source\Configuration - - - Source\Configuration - - - Source - - - Source\Video - - - Source\Video - - - Source\Emulator - - - - - - - Source - - - Source\Debugger - - - Source\Debugger - - - Source\Debugger - - - Source\Debugger - - - Source\Debugger - - - Source\Debugger - - - Source\Debugger - - - Source\Debugger - - - Source\Debugger - - - Source\Debugger - - - Source\Debugger - - - Source\Debugger - - - Source\Uthernet - - - Source\Uthernet - - - Source\Uthernet - - - Source\Uthernet - - - Source\Uthernet - - - Source\Uthernet - - - Source\Uthernet - - - Source\Uthernet - - - Source\Uthernet - - - Source\Z80VICE - - - Source\Z80VICE - - - Source\Z80VICE - - - Source\Z80VICE - - - Source\CommonVICE - - - Source\CommonVICE - - - Source\CommonVICE - - - Source\CommonVICE - - - Source\CommonVICE - - - Source\Emulator - - - Source\Emulator - - - Source\Emulator - - - Source\Emulator - - - Source\Emulator - - - Source\Emulator - - - Source\Emulator - - - Source\Emulator - - - Source\Emulator - - - Source\Emulator - - - Source\Emulator - - - Source\Emulator - - - Source\Emulator - - - Source\Emulator - - - Source\Emulator - - - Source\Emulator - - - Source\Emulator - - - Source\Emulator - - - Source\Emulator - - - Source\_Headers - - - Source\_Headers - - - Source\_Headers - - - Source\_Headers - - - Source\CPU - - - Source\CPU - - - Source\CPU - - - Source\CPU - - - Source\Disk - - - Source\Disk - - - Source\Disk - - - Source\Disk - - - Source\Video - - - Source\Video - - - Source\Configuration - - - Source\Configuration - - - Source\Configuration - - - Source\Configuration - - - Source\Configuration - - - Source\Configuration - - - Source\Configuration - - - Source\Configuration - - - Source\Configuration - - - Source\Configuration - - - Source\Configuration - - - Source\Configuration - - - Source\Configuration - - - Resources - - - Source - - - Source\Video - - - - - Source\Video - - - - - Source\CPU - - - Source\CPU - - - Docs - - - Docs - - - Docs - - - Docs - - - Docs - - - Docs - - - Docs - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - Resources - - - - - Resources - - - diff --git a/bin/DELREG.INF b/bin/DELREG.INF index e5ec28cf..e5074ed3 100644 --- a/bin/DELREG.INF +++ b/bin/DELREG.INF @@ -8,11 +8,11 @@ DelReg=RegChange DelReg=RegChange [RegChange] -HKCR,.bin HKCR,.do HKCR,.dsk HKCR,.nib HKCR,.po +HKCR,.woz HKCR,DiskImage HKCU,Software\AppleWin HKLM,Software\AppleWin diff --git a/bin/History.txt b/bin/History.txt index d5f9454c..fff3b89f 100644 --- a/bin/History.txt +++ b/bin/History.txt @@ -8,6 +8,13 @@ https://github.com/AppleWin/AppleWin/issues/new Tom Charlesworth +1.29.1.0 - 27 Jul 2019 +---------------------- +. [Bug #662] Fixed WOZ 'Wizardry III' not booting. +. [Bug #669] Fixed WOZ 'Space Quest I' not booting reliably. +. [Bug #670] Fixed PAGE2 not displaying correctly when in full-speed mode (regression introduced at 1.28.8.0). + + 1.29.0.0 - 8 Jul 2019 --------------------- . [Change #544] Support for .woz disk images. diff --git a/help/ddi-load.html b/help/ddi-load.html index 95ed4042..1dd339e1 100644 --- a/help/ddi-load.html +++ b/help/ddi-load.html @@ -15,16 +15,16 @@ Disk Images
-

AppleWin registers the +

AppleWin registers1 the following file types as "Disk -Images": *.do, *.dsk, *.nib, and *.po.  Double-clicking -a disk image in the Windows Explorer will automatically load and boot +Images": *.do, *.dsk, *.nib, *.po and *.woz.  Double-clicking +a disk image in Windows Explorer will automatically load and boot the disk. While older versions of AppleWin started a new instance of the emulator for every disk started in this manner, current versions -of the emulator will simply replace the current disk if there is an +of the emulator will simply replace the current disk (and reboot) if there is an instance of the emulator already running.

@@ -49,5 +49,9 @@ long to read in the Toolbar, simply pause the mouse cursor over a drive button to get a tool-tip with the full name.

+

1 To register the file types in Windows Vista, Windows 7 and Windows 10, +you will need to run AppleWin with elevated privileges. This only needs to be done once. +Right click the AppleWin.exe icon and select 'Run as Administrator'.

+ diff --git a/libyaml/win32/yaml2010.vcxproj b/libyaml/win32/yaml2010.vcxproj deleted file mode 100644 index ba677389..00000000 --- a/libyaml/win32/yaml2010.vcxproj +++ /dev/null @@ -1,98 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - yaml - {5CE8051A-3F0C-4C39-B1C0-3338E48BA60F} - yaml - Win32Proj - - - - StaticLibrary - NotSet - - - StaticLibrary - NotSet - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - Output\Debug\lib\ - Build\Debug\lib\ - Output\Release\lib\ - Build\Release\lib\ - - - - Disabled - .;../include;%(AdditionalIncludeDirectories) - HAVE_CONFIG_H;YAML_DECLARE_STATIC;_CRT_SECURE_NO_WARNINGS;%(PreprocessorDefinitions) - true - EnableFastChecks - MultiThreadedDebug - - - Level3 - EditAndContinue - - - $(OutDir)yaml.lib - - - - - $(ProjectDir)..\include;$(ProjectDir)..\src;$(ProjectDir);%(AdditionalIncludeDirectories) - HAVE_CONFIG_H;YAML_DECLARE_STATIC;_CRT_SECURE_NO_WARNINGS;%(PreprocessorDefinitions) - MultiThreaded - - - Level3 - ProgramDatabase - - - $(OutDir)yaml.lib - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/libyaml/win32/yaml2010.vcxproj.filters b/libyaml/win32/yaml2010.vcxproj.filters deleted file mode 100644 index f1399f2b..00000000 --- a/libyaml/win32/yaml2010.vcxproj.filters +++ /dev/null @@ -1,54 +0,0 @@ - - - - - {4FC737F1-C7A5-4376-A066-2A32D752A2FF} - cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx - - - {93995380-89BD-4b04-88EB-625FBE52EBFB} - h;hh;hpp;hxx;hm;inl;inc;xsd - - - - - - - - - Header Files - - - Header Files - - - Header Files - - - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - \ No newline at end of file diff --git a/resource/version.h b/resource/version.h index 327790e8..cbc2f529 100644 --- a/resource/version.h +++ b/resource/version.h @@ -1,4 +1,4 @@ -#define APPLEWIN_VERSION 1,29,0,0 +#define APPLEWIN_VERSION 1,29,1,0 #define xstr(a) str(a) #define str(a) #a diff --git a/source/Applewin.cpp b/source/Applewin.cpp index 9b9cd088..6a988215 100644 --- a/source/Applewin.cpp +++ b/source/Applewin.cpp @@ -773,11 +773,6 @@ bool SetCurrentImageDir(const char* pszImageDir) // TODO: Added dialog option of which file extensions to registry static bool g_bRegisterFileTypes = true; -//static bool g_bRegistryFileBin = false; -static bool g_bRegistryFileDo = true; -static bool g_bRegistryFileDsk = true; -static bool g_bRegistryFileNib = true; -static bool g_bRegistryFilePo = true; void RegisterExtensions(void) @@ -785,14 +780,6 @@ void RegisterExtensions(void) TCHAR szCommandTmp[MAX_PATH]; GetModuleFileName((HMODULE)0,szCommandTmp,MAX_PATH); -#ifdef TEST_REG_BUG - TCHAR command[MAX_PATH]; - wsprintf(command, "%s", szCommandTmp); // Wrap path & filename in quotes & null terminate - - TCHAR icon[MAX_PATH]; - wsprintf(icon,TEXT("\"%s,1\""),(LPCTSTR)command); -#endif - TCHAR command[MAX_PATH]; wsprintf(command, "\"%s\"", szCommandTmp); // Wrap path & filename in quotes & null terminate @@ -803,46 +790,80 @@ void RegisterExtensions(void) // _tcscat(command,TEXT("-d1 %1\"")); // Append "%1" // sprintf(command, "\"%s\" \"-d1 %%1\"", szCommandTmp); // Wrap path & filename in quotes & null terminate + // NB. Registry access to HKLM typically results in ErrorCode 5(ACCESS DENIED), as UAC requires elevated permissions (Run as administrator). + // . HKEY_CLASSES_ROOT\CLSID is a merged view of HKLM\SOFTWARE\Classes and HKCU\SOFTWARE\Classes + // NB. Reflect extensions in DELREG.INF // RegSetValue(HKEY_CLASSES_ROOT,".bin",REG_SZ,"DiskImage",0); // Removed as .bin is too generic - long Res = RegDeleteValue(HKEY_CLASSES_ROOT, ".bin"); // TODO: This isn't working :-/ - RegSetValue(HKEY_CLASSES_ROOT,".do" ,REG_SZ,"DiskImage",0); - RegSetValue(HKEY_CLASSES_ROOT,".dsk",REG_SZ,"DiskImage",0); - RegSetValue(HKEY_CLASSES_ROOT,".nib",REG_SZ,"DiskImage",0); - RegSetValue(HKEY_CLASSES_ROOT,".po" ,REG_SZ,"DiskImage",0); + const char* pValueName = ".bin"; + LSTATUS res = RegDeleteValue(HKEY_CLASSES_ROOT, pValueName); + if (res != NOERROR && res != ERROR_FILE_NOT_FOUND) LogFileOutput("RegDeleteValue(%s) failed (0x%08X)\n", pValueName, res); + + pValueName = ".do"; + res = RegSetValue(HKEY_CLASSES_ROOT, pValueName ,REG_SZ,"DiskImage",0); + if (res != NOERROR) LogFileOutput("RegSetValue(%s) failed (0x%08X)\n", pValueName, res); + + pValueName = ".dsk"; + res = RegSetValue(HKEY_CLASSES_ROOT, pValueName, REG_SZ,"DiskImage",0); + if (res != NOERROR) LogFileOutput("RegSetValue(%s) failed (0x%08X)\n", pValueName, res); + + pValueName = ".nib"; + res = RegSetValue(HKEY_CLASSES_ROOT, pValueName, REG_SZ,"DiskImage",0); + if (res != NOERROR) LogFileOutput("RegSetValue(%s) failed (0x%08X)\n", pValueName, res); + + pValueName = ".po"; + res = RegSetValue(HKEY_CLASSES_ROOT, pValueName, REG_SZ,"DiskImage",0); + if (res != NOERROR) LogFileOutput("RegSetValue(%s) failed (0x%08X)\n", pValueName, res); + + pValueName = ".woz"; + res = RegSetValue(HKEY_CLASSES_ROOT, pValueName, REG_SZ,"DiskImage",0); + if (res != NOERROR) LogFileOutput("RegSetValue(%s) failed (0x%08X)\n", pValueName, res); + // RegSetValue(HKEY_CLASSES_ROOT,".2mg",REG_SZ,"DiskImage",0); // Don't grab this, as not all .2mg images are supported (so defer to CiderPress) // RegSetValue(HKEY_CLASSES_ROOT,".2img",REG_SZ,"DiskImage",0); // Don't grab this, as not all .2mg images are supported (so defer to CiderPress) -// RegSetValue(HKEY_CLASSES_ROOT,".aws",REG_SZ,"DiskImage",0); // TO DO +// RegSetValue(HKEY_CLASSES_ROOT,".aws.yaml",REG_SZ,"DiskImage",0); // NB. Can't grab this extension (even though it returns 0!) with embedded period (and .yaml is too generic) - GH#548 // RegSetValue(HKEY_CLASSES_ROOT,".hdv",REG_SZ,"DiskImage",0); // TO DO - RegSetValue(HKEY_CLASSES_ROOT, - "DiskImage", + pValueName = "DiskImage"; + res = RegSetValue(HKEY_CLASSES_ROOT, + pValueName, REG_SZ,"Disk Image",0); + if (res != NOERROR) LogFileOutput("RegSetValue(%s) failed (0x%08X)\n", pValueName, res); - RegSetValue(HKEY_CLASSES_ROOT, - "DiskImage\\DefaultIcon", + pValueName = "DiskImage\\DefaultIcon"; + res = RegSetValue(HKEY_CLASSES_ROOT, + pValueName, REG_SZ,icon,0); + if (res != NOERROR) LogFileOutput("RegSetValue(%s) failed (0x%08X)\n", pValueName, res); // This key can interfere.... // HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\FileExt\.dsk - RegSetValue(HKEY_CLASSES_ROOT, - "DiskImage\\shell\\open\\command", + pValueName = "DiskImage\\shell\\open\\command"; + res = RegSetValue(HKEY_CLASSES_ROOT, + pValueName, REG_SZ,command,_tcslen(command)+1); + if (res != NOERROR) LogFileOutput("RegSetValue(%s) failed (0x%08X)\n", pValueName, res); - RegSetValue(HKEY_CLASSES_ROOT, - "DiskImage\\shell\\open\\ddeexec", + pValueName = "DiskImage\\shell\\open\\ddeexec"; + res = RegSetValue(HKEY_CLASSES_ROOT, + pValueName, REG_SZ,"%1",3); + if (res != NOERROR) LogFileOutput("RegSetValue(%s) failed (0x%08X)\n", pValueName, res); - RegSetValue(HKEY_CLASSES_ROOT, - "DiskImage\\shell\\open\\ddeexec\\application", + pValueName = "DiskImage\\shell\\open\\ddeexec\\application"; + res = RegSetValue(HKEY_CLASSES_ROOT, + pValueName, REG_SZ,"applewin",_tcslen("applewin")+1); // REG_SZ,szCommandTmp,_tcslen(szCommandTmp)+1); + if (res != NOERROR) LogFileOutput("RegSetValue(%s) failed (0x%08X)\n", pValueName, res); - RegSetValue(HKEY_CLASSES_ROOT, - "DiskImage\\shell\\open\\ddeexec\\topic", + pValueName = "DiskImage\\shell\\open\\ddeexec\\topic"; + res = RegSetValue(HKEY_CLASSES_ROOT, + pValueName, REG_SZ,"system",_tcslen("system")+1); + if (res != NOERROR) LogFileOutput("RegSetValue(%s) failed (0x%08X)\n", pValueName, res); } //=========================================================================== diff --git a/source/Disk.cpp b/source/Disk.cpp index 4ac08a95..8f88fbc7 100644 --- a/source/Disk.cpp +++ b/source/Disk.cpp @@ -1046,7 +1046,7 @@ void Disk2InterfaceCard::UpdateBitStreamOffsets(FloppyDisk& floppy) floppy.m_bitMask = 1 << remainder; } -void __stdcall Disk2InterfaceCard::ReadWriteWOZ(WORD pc, WORD addr, BYTE bWrite, BYTE d, ULONG uExecutedCycles) +void __stdcall Disk2InterfaceCard::DataLatchReadWriteWOZ(WORD pc, WORD addr, BYTE bWrite, BYTE d, ULONG uExecutedCycles) { /* m_floppyLoadMode = 0; */ FloppyDrive& drive = m_floppyDrive[m_currDrive]; @@ -1095,120 +1095,272 @@ void __stdcall Disk2InterfaceCard::ReadWriteWOZ(WORD pc, WORD addr, BYTE bWrite, m_diskLastCycle = g_nCumulativeCycles; - // - - if (!m_floppyWriteMode) - { - // m_diskLastReadLatchCycle = g_nCumulativeCycles; // Not used by WOZ (only by NIB) -#if LOG_DISK_NIBBLES_READ - bool newLatchData = false; -#endif - - for (UINT i = 0; i < bitCellRemainder; i++) - { - BYTE n = floppy.m_trackimage[floppy.m_byte]; - - drive.m_headWindow <<= 1; - drive.m_headWindow |= (n & floppy.m_bitMask) ? 1 : 0; - BYTE outputBit = (drive.m_headWindow & 0xf) ? (drive.m_headWindow >> 1) & 1 - : rand() & 1; - - floppy.m_bitMask >>= 1; - if (!floppy.m_bitMask) - { - floppy.m_bitMask = 1 << 7; - floppy.m_byte++; - } - - floppy.m_bitOffset++; - if (floppy.m_bitOffset == floppy.m_bitCount) - { - floppy.m_bitMask = 1 << 7; - floppy.m_bitOffset = 0; - floppy.m_byte = 0; - } - - if (m_resetSequencer) - { - m_resetSequencer = false; // LSS takes some cycles to reset (ref?) - continue; - } - - // - - m_shiftReg <<= 1; - m_shiftReg |= outputBit; - - if (m_latchDelay) - { - m_latchDelay -= 4; - if (m_latchDelay < 0) - m_latchDelay = 0; - - if (m_shiftReg) - { - m_dbgLatchDelayedCnt = 0; - } - else // m_shiftReg==0 - { - m_latchDelay += 4; // extend by 4us (so 7us again) - GH#662 - - m_dbgLatchDelayedCnt++; -#if LOG_DISK_NIBBLES_READ - if (m_dbgLatchDelayedCnt >= 3) - { - LOG_DISK("read: latch held due to 0: PC=%04X, cnt=%02X\r\n", regs.pc, m_dbgLatchDelayedCnt); - } -#endif - } - } - - if (!m_latchDelay) - { -#if LOG_DISK_NIBBLES_READ - if (newLatchData) - { - LOG_DISK("read skipped latch data: %04X = %02X\r\n", floppy.m_byte, m_floppyLatch); - newLatchData = false; - } -#endif - m_floppyLatch = m_shiftReg; - - if (m_shiftReg & 0x80) - { - m_latchDelay = 7; - m_shiftReg = 0; -#if LOG_DISK_NIBBLES_READ - // May not actually be read by 6502 (eg. Prologue's CHKSUM 4&4 nibble pair), but still pass to the log's nibble reader - m_formatTrack.DecodeLatchNibbleRead(m_floppyLatch); - newLatchData = true; -#endif - } - } - } - -#if LOG_DISK_NIBBLES_READ - if (m_floppyLatch & 0x80) - { - #if LOG_DISK_NIBBLES_USE_RUNTIME_VAR - if (m_bLogDisk_NibblesRW) - #endif - { - LOG_DISK("read %04X = %02X\r\n", floppy.m_byte, m_floppyLatch); - } - } -#endif - } - else if (!floppy.m_bWriteProtected) // && m_floppyWriteMode - { - //TODO - } + if (!bWrite) + DataLatchReadWOZ(pc, addr, bitCellRemainder); + else + DataLatchWriteWOZ(pc, addr, d, bitCellRemainder); // Show track status (GH#201) - NB. Prevent flooding of forcing UI to redraw!!! if ((floppy.m_byte & 0xFF) == 0) - FrameDrawDiskStatus( (HDC)0 ); + FrameDrawDiskStatus((HDC)0); } +void Disk2InterfaceCard::DataLatchReadWOZ(WORD pc, WORD addr, UINT bitCellRemainder) +{ + // m_diskLastReadLatchCycle = g_nCumulativeCycles; // Not used by WOZ (only by NIB) + +#if LOG_DISK_NIBBLES_READ + bool newLatchData = false; +#endif + + FloppyDrive& drive = m_floppyDrive[m_currDrive]; + FloppyDisk& floppy = drive.m_disk; + +#if _DEBUG + static int dbgWOZ = 0; + if (dbgWOZ) + { + DumpSectorWOZ(floppy); + //DumpTrackWOZ(floppy); // Enable as necessary + } +#endif + + for (UINT i = 0; i < bitCellRemainder; i++) + { + BYTE n = floppy.m_trackimage[floppy.m_byte]; + + drive.m_headWindow <<= 1; + drive.m_headWindow |= (n & floppy.m_bitMask) ? 1 : 0; + BYTE outputBit = (drive.m_headWindow & 0xf) ? (drive.m_headWindow >> 1) & 1 + : rand() & 1; + + floppy.m_bitMask >>= 1; + if (!floppy.m_bitMask) + { + floppy.m_bitMask = 1 << 7; + floppy.m_byte++; + } + + floppy.m_bitOffset++; + if (floppy.m_bitOffset == floppy.m_bitCount) + { + floppy.m_bitMask = 1 << 7; + floppy.m_bitOffset = 0; + floppy.m_byte = 0; + } + + if (m_resetSequencer) + { + m_resetSequencer = false; // LSS takes some cycles to reset (ref?) + continue; + } + + // + + m_shiftReg <<= 1; + m_shiftReg |= outputBit; + + if (m_latchDelay) + { + m_latchDelay -= 4; + if (m_latchDelay < 0) + m_latchDelay = 0; + + if (m_shiftReg) + { + m_dbgLatchDelayedCnt = 0; + } + else // m_shiftReg==0 + { + m_latchDelay += 4; // extend by 4us (so 7us again) - GH#662 + + m_dbgLatchDelayedCnt++; +#if LOG_DISK_NIBBLES_READ + if (m_dbgLatchDelayedCnt >= 3) + { + LOG_DISK("read: latch held due to 0: PC=%04X, cnt=%02X\r\n", regs.pc, m_dbgLatchDelayedCnt); + } +#endif + } + } + + if (!m_latchDelay) + { +#if LOG_DISK_NIBBLES_READ + if (newLatchData) + { + LOG_DISK("read skipped latch data: %04X = %02X\r\n", floppy.m_byte, m_floppyLatch); + newLatchData = false; + } +#endif + m_floppyLatch = m_shiftReg; + + if (m_shiftReg & 0x80) + { + m_latchDelay = 7; + m_shiftReg = 0; +#if LOG_DISK_NIBBLES_READ + // May not actually be read by 6502 (eg. Prologue's CHKSUM 4&4 nibble pair), but still pass to the log's nibble reader + m_formatTrack.DecodeLatchNibbleRead(m_floppyLatch); + newLatchData = true; +#endif + } + } + } + +#if LOG_DISK_NIBBLES_READ + if (m_floppyLatch & 0x80) + { +#if LOG_DISK_NIBBLES_USE_RUNTIME_VAR + if (m_bLogDisk_NibblesRW) +#endif + { + LOG_DISK("read %04X = %02X\r\n", floppy.m_byte, m_floppyLatch); + } + } +#endif +} + +void Disk2InterfaceCard::DataLatchWriteWOZ(WORD pc, WORD addr, BYTE d, UINT bitCellRemainder) +{ + _ASSERT(m_floppyWriteMode); + + FloppyDrive& drive = m_floppyDrive[m_currDrive]; + FloppyDisk& floppy = drive.m_disk; + + if (!floppy.m_bWriteProtected) + { + //TODO + } +} + +//=========================================================================== + +#ifdef _DEBUG +// Dump nibbles from current position until 0xDEAA (ie. data epilogue) +void Disk2InterfaceCard::DumpSectorWOZ(FloppyDisk floppy) // pass a copy of m_floppy +{ + BYTE shiftReg = 0; + UINT32 lastNibbles = 0; + UINT zeroCount = 0; + UINT nibbleCount = 0; + + while (1) + { + BYTE n = floppy.m_trackimage[floppy.m_byte]; + BYTE outputBit = (n & floppy.m_bitMask) ? 1 : 0; + + floppy.m_bitMask >>= 1; + if (!floppy.m_bitMask) + { + floppy.m_bitMask = 1 << 7; + floppy.m_byte++; + } + + floppy.m_bitOffset++; + if (floppy.m_bitOffset == floppy.m_bitCount) + { + floppy.m_bitMask = 1 << 7; + floppy.m_bitOffset = 0; + floppy.m_byte = 0; + } + + if (shiftReg == 0 && outputBit == 0) + { + zeroCount++; + continue; + } + + shiftReg <<= 1; + shiftReg |= outputBit; + + if ((shiftReg & 0x80) == 0) + continue; + + nibbleCount++; + + char str[10]; + sprintf(str, "%02X ", shiftReg); + OutputDebugString(str); + if ((nibbleCount & 0xf) == 0) + OutputDebugString("\n"); + + lastNibbles <<= 8; + lastNibbles |= shiftReg; + + if ((lastNibbles & 0xffff) == 0xDEAA) + break; + + shiftReg = 0; + zeroCount = 0; + } +} + +// Dump nibbles from current position bitstream wraps to same position +void Disk2InterfaceCard::DumpTrackWOZ(FloppyDisk floppy) // pass a copy of m_floppy +{ +#ifdef LOG_DISK_NIBBLES_READ + FormatTrack formatTrack; +#endif + + BYTE shiftReg = 0; + UINT nibbleCount = 0; + + floppy.m_bitMask = 1 << 7; + floppy.m_bitOffset = 0; + floppy.m_byte = 0; + + const UINT startBitOffset = floppy.m_bitOffset; + + while (1) + { + BYTE n = floppy.m_trackimage[floppy.m_byte]; + BYTE outputBit = (n & floppy.m_bitMask) ? 1 : 0; + + floppy.m_bitMask >>= 1; + if (!floppy.m_bitMask) + { + floppy.m_bitMask = 1 << 7; + floppy.m_byte++; + } + + floppy.m_bitOffset++; + if (floppy.m_bitOffset == floppy.m_bitCount) + { + floppy.m_bitMask = 1 << 7; + floppy.m_bitOffset = 0; + floppy.m_byte = 0; + } + + if (startBitOffset == floppy.m_bitOffset) + break; + + if (shiftReg == 0 && outputBit == 0) + continue; + + shiftReg <<= 1; + shiftReg |= outputBit; + + if ((shiftReg & 0x80) == 0) + continue; + + nibbleCount++; + + char str[10]; + sprintf(str, "%02X ", shiftReg); + OutputDebugString(str); + if ((nibbleCount % 32) == 0) + OutputDebugString("\n"); + +#ifdef LOG_DISK_NIBBLES_READ + formatTrack.DecodeLatchNibbleRead(shiftReg); +#endif + + shiftReg = 0; + } +} +#endif + //=========================================================================== void Disk2InterfaceCard::Reset(const bool bIsPowerCycle/*=false*/) @@ -1516,9 +1668,7 @@ BYTE __stdcall Disk2InterfaceCard::IORead(WORD pc, WORD addr, BYTE bWrite, BYTE case 0x9: pCard->ControlMotor(pc, addr, bWrite, d, nExecutedCycles); break; case 0xA: pCard->Enable(pc, addr, bWrite, d, nExecutedCycles); break; case 0xB: pCard->Enable(pc, addr, bWrite, d, nExecutedCycles); break; - case 0xC: if (!isWOZ) pCard->ReadWrite(pc, addr, bWrite, d, nExecutedCycles); - else pCard->ReadWriteWOZ(pc, addr, bWrite, d, nExecutedCycles); - break; + case 0xC: if (!isWOZ) pCard->ReadWrite(pc, addr, bWrite, d, nExecutedCycles); break; case 0xD: pCard->LoadWriteProtect(pc, addr, bWrite, d, nExecutedCycles); break; case 0xE: pCard->SetReadMode(pc, addr, bWrite, d, nExecutedCycles); break; case 0xF: pCard->SetWriteMode(pc, addr, bWrite, d, nExecutedCycles); break; @@ -1526,9 +1676,14 @@ BYTE __stdcall Disk2InterfaceCard::IORead(WORD pc, WORD addr, BYTE bWrite, BYTE // only even addresses return the latch (UTAIIe Table 9.1) if (!(addr & 1)) + { + if (isWOZ) + pCard->DataLatchReadWriteWOZ(pc, addr, bWrite, d, nExecutedCycles); + return pCard->m_floppyLatch; - else - return MemReadFloatingBus(nExecutedCycles); + } + + return MemReadFloatingBus(nExecutedCycles); } BYTE __stdcall Disk2InterfaceCard::IOWrite(WORD pc, WORD addr, BYTE bWrite, BYTE d, ULONG nExecutedCycles) @@ -1553,9 +1708,7 @@ BYTE __stdcall Disk2InterfaceCard::IOWrite(WORD pc, WORD addr, BYTE bWrite, BYTE case 0x9: pCard->ControlMotor(pc, addr, bWrite, d, nExecutedCycles); break; case 0xA: pCard->Enable(pc, addr, bWrite, d, nExecutedCycles); break; case 0xB: pCard->Enable(pc, addr, bWrite, d, nExecutedCycles); break; - case 0xC: if (!isWOZ) pCard->ReadWrite(pc, addr, bWrite, d, nExecutedCycles); - else pCard->ReadWriteWOZ(pc, addr, bWrite, d, nExecutedCycles); - break; + case 0xC: if (!isWOZ) pCard->ReadWrite(pc, addr, bWrite, d, nExecutedCycles); break; case 0xD: pCard->LoadWriteProtect(pc, addr, bWrite, d, nExecutedCycles); break; case 0xE: pCard->SetReadMode(pc, addr, bWrite, d, nExecutedCycles); break; case 0xF: pCard->SetWriteMode(pc, addr, bWrite, d, nExecutedCycles); break; @@ -1565,7 +1718,11 @@ BYTE __stdcall Disk2InterfaceCard::IOWrite(WORD pc, WORD addr, BYTE bWrite, BYTE if (pCard->m_floppyWriteMode /* && m_floppyLoadMode */) { pCard->m_floppyLatch = d; + + if (isWOZ) + pCard->DataLatchReadWriteWOZ(pc, addr, bWrite, d, nExecutedCycles); } + return 0; } diff --git a/source/Disk.h b/source/Disk.h index 6a2aacc3..03b0f02d 100644 --- a/source/Disk.h +++ b/source/Disk.h @@ -188,6 +188,11 @@ private: UINT GetBitCellDelta(const BYTE optimalBitTiming); void UpdateBitStreamPosition(FloppyDisk& floppy, const ULONG bitCellDelta); void UpdateBitStreamOffsets(FloppyDisk& floppy); + void DataLatchReadWOZ(WORD pc, WORD addr, UINT bitCellRemainder); + void DataLatchWriteWOZ(WORD pc, WORD addr, BYTE d, UINT bitCellRemainder); + void DumpSectorWOZ(FloppyDisk floppy); + void DumpTrackWOZ(FloppyDisk floppy); + void SaveSnapshotFloppy(YamlSaveHelper& yamlSaveHelper, UINT unit); void SaveSnapshotDriveUnit(YamlSaveHelper& yamlSaveHelper, UINT unit); bool LoadSnapshotFloppy(YamlLoadHelper& yamlLoadHelper, UINT unit, UINT version, std::vector& track); @@ -199,7 +204,7 @@ private: void __stdcall ControlMotor(WORD, WORD address, BYTE, BYTE, ULONG uExecutedCycles); void __stdcall Enable(WORD, WORD address, BYTE, BYTE, ULONG uExecutedCycles); void __stdcall ReadWrite(WORD pc, WORD addr, BYTE bWrite, BYTE d, ULONG uExecutedCycles); - void __stdcall ReadWriteWOZ(WORD pc, WORD addr, BYTE bWrite, BYTE d, ULONG uExecutedCycles); + void __stdcall DataLatchReadWriteWOZ(WORD pc, WORD addr, BYTE bWrite, BYTE d, ULONG uExecutedCycles); void __stdcall LoadWriteProtect(WORD, WORD, BYTE write, BYTE value, ULONG); void __stdcall SetReadMode(WORD, WORD, BYTE, BYTE, ULONG); void __stdcall SetWriteMode(WORD, WORD, BYTE, BYTE, ULONG uExecutedCycles); diff --git a/source/NTSC.cpp b/source/NTSC.cpp index 0d2eb052..2b8c97b1 100644 --- a/source/NTSC.cpp +++ b/source/NTSC.cpp @@ -624,7 +624,7 @@ inline void updateFlashRate() // TODO: Flash rate should be constant (regardless inline void updateFramebufferColorTVSingleScanline( uint16_t signal, bgra_t *pTable ) { /* */ uint32_t *pLine0Address = getScanlineThis0Address(); - /* */ uint32_t *pLine1Address = getScanlinePrev1Address(); + /* */ uint32_t *pLine1Address = getScanlinePrev1Address(); // NB. TV mode uses previous 2 lines /* */ uint32_t *pLine2Address = getScanlinePrev2Address(); const uint32_t color0 = getScanlineColor( signal, pTable ); @@ -650,7 +650,7 @@ inline void updateFramebufferColorTVSingleScanline( uint16_t signal, bgra_t *pTa inline void updateFramebufferColorTVDoubleScanline( uint16_t signal, bgra_t *pTable ) { /* */ uint32_t *pLine0Address = getScanlineThis0Address(); - /* */ uint32_t *pLine1Address = getScanlinePrev1Address(); + /* */ uint32_t *pLine1Address = getScanlinePrev1Address(); // NB. TV mode uses previous 2 lines const uint32_t *pLine2Address = getScanlinePrev2Address(); const uint32_t color0 = getScanlineColor( signal, pTable ); @@ -666,7 +666,7 @@ inline void updateFramebufferColorTVDoubleScanline( uint16_t signal, bgra_t *pTa inline void updateFramebufferMonitorSingleScanline( uint16_t signal, bgra_t *pTable ) { /* */ uint32_t *pLine0Address = getScanlineThis0Address(); - /* */ uint32_t *pLine1Address = getScanlineNext1Address(); + /* */ uint32_t *pLine1Address = getScanlineNext1Address(); // NB. Monitor mode just uses next line const uint32_t color0 = getScanlineColor( signal, pTable ); const uint32_t color1 = 0; // Remove blending for consistent DHGR MIX mode (GH#631) // const uint32_t color1 = ((color0 & 0x00fcfcfc) >> 2); // 25% Blend (original) @@ -680,7 +680,7 @@ inline void updateFramebufferMonitorSingleScanline( uint16_t signal, bgra_t *pTa inline void updateFramebufferMonitorDoubleScanline( uint16_t signal, bgra_t *pTable ) { /* */ uint32_t *pLine0Address = getScanlineThis0Address(); - /* */ uint32_t *pLine1Address = getScanlineNext1Address(); + /* */ uint32_t *pLine1Address = getScanlineNext1Address(); // NB. Monitor mode just uses next line const uint32_t color0 = getScanlineColor( signal, pTable ); /* */ *pLine1Address = color0; @@ -1895,8 +1895,10 @@ void NTSC_SetVideoTextMode( int cols ) //=========================================================================== void NTSC_SetVideoMode( uint32_t uVideoModeFlags, bool bDelay/*=false*/ ) { - if (bDelay) + if (bDelay && !g_bFullSpeed) { + // (GH#670) NB. if g_bFullSpeed then NTSC_VideoUpdateCycles() won't be called on the next 6502 opcode. + // - Instead it's called when !g_bFullSpeed (eg. drive motor off), then the stale g_uNewVideoModeFlags will get used for NTSC_SetVideoMode()! g_bDelayVideoMode = true; g_uNewVideoModeFlags = uVideoModeFlags; return; @@ -1976,6 +1978,15 @@ void NTSC_SetVideoMode( uint32_t uVideoModeFlags, bool bDelay/*=false*/ ) } //=========================================================================== + +// TV modes don't write to the last line, so when switching from another (Monitor) mode there may be stale data left behind +void ClearLastLine(void) +{ + uint32_t* p = (uint32_t*)g_pScanLines[VIDEO_SCANNER_Y_DISPLAY * 2 - 1]; + for (UINT x = 0; x < NTSC_GetFrameBufferBorderlessWidth(); x++) + p[x] = 0; +} + void NTSC_SetVideoStyle() // (int v, int s) { int half = IsVideoStyle(VS_HALF_SCANLINES); @@ -1997,6 +2008,7 @@ void NTSC_SetVideoStyle() // (int v, int s) g_pFuncUpdateBnWPixel = updatePixelBnWColorTVDoubleScanline; g_pFuncUpdateHuePixel = updatePixelHueColorTVDoubleScanline; } + ClearLastLine(); break; case VT_COLOR_MONITOR_NTSC: @@ -2028,6 +2040,7 @@ void NTSC_SetVideoStyle() // (int v, int s) else { g_pFuncUpdateBnWPixel = g_pFuncUpdateHuePixel = updatePixelBnWColorTVDoubleScanline; } + ClearLastLine(); break; case VT_MONO_AMBER: diff --git a/source/Video.cpp b/source/Video.cpp index a5229d6d..3999cd58 100644 --- a/source/Video.cpp +++ b/source/Video.cpp @@ -556,25 +556,6 @@ void VideoRedrawScreen (void) //=========================================================================== -// TC: Hacky-fix for GH#341 - better to draw to the correct position in the framebuffer to start with! (in NTSC.cpp) -// . NB. Now the dx is corrected in NTSC.cpp, updateVideoScannerAddress() -static void VideoFrameBufferAdjust(int& xSrc, int& ySrc, bool bInvertY=false) -{ - int dx=0, dy=0; - - if (g_eVideoType == VT_MONO_TV || g_eVideoType == VT_COLOR_TV) - { - // Adjust the src locations for the NTSC video modes - dy = -1; - } - - if (bInvertY) - dy =- dy; - - xSrc += dx; - ySrc += dy; -} - void VideoRefreshScreen ( uint32_t uRedrawWholeScreenVideoMode /* =0*/, bool bRedrawWholeScreen /* =false*/ ) { if (bRedrawWholeScreen || g_nAppMode == MODE_PAUSED) @@ -593,7 +574,6 @@ void VideoRefreshScreen ( uint32_t uRedrawWholeScreenVideoMode /* =0*/, bool bRe { int xSrc = GetFrameBufferBorderWidth(); int ySrc = GetFrameBufferBorderHeight(); - VideoFrameBufferAdjust(xSrc, ySrc); // TC: Hacky-fix for GH#341 int xdest = IsFullScreen() ? GetFullScreenOffsetX() : 0; int ydest = IsFullScreen() ? GetFullScreenOffsetY() : 0; @@ -1085,8 +1065,6 @@ static void Video_MakeScreenShot(FILE *pFile, const VideoScreenShot_e ScreenShot int xSrc = GetFrameBufferBorderWidth(); int ySrc = GetFrameBufferBorderHeight(); - VideoFrameBufferAdjust(xSrc, ySrc, true); // TC: Hacky-fix for GH#341 & GH#356 - // Lines stored in reverse, so invert the y-adjust value pSrc += xSrc; // Skip left border pSrc += ySrc * GetFrameBufferWidth(); // Skip top border diff --git a/zip_lib/zip_lib2010.vcxproj b/zip_lib/zip_lib2010.vcxproj deleted file mode 100644 index a49535ec..00000000 --- a/zip_lib/zip_lib2010.vcxproj +++ /dev/null @@ -1,141 +0,0 @@ - - - - - Debug NoDX - Win32 - - - Debug - Win32 - - - Release NoDX - Win32 - - - Release - Win32 - - - - {709278B8-C583-4BD8-90DE-4E4F35A3BD8B} - zip_lib - Win32Proj - - - - StaticLibrary - NotSet - true - - - StaticLibrary - NotSet - true - - - StaticLibrary - NotSet - - - StaticLibrary - NotSet - - - - - - - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - - - - Disabled - ..\zlib;%(AdditionalIncludeDirectories) - _CRT_SECURE_NO_WARNINGS;%(PreprocessorDefinitions) - true - EnableFastChecks - MultiThreadedDebug - - - Level3 - ProgramDatabase - - - - - Disabled - ..\zlib;%(AdditionalIncludeDirectories) - _CRT_SECURE_NO_WARNINGS;%(PreprocessorDefinitions) - true - EnableFastChecks - MultiThreadedDebug - - - Level3 - ProgramDatabase - - - - - MaxSpeed - true - ..\zlib;%(AdditionalIncludeDirectories) - _CRT_SECURE_NO_WARNINGS;%(PreprocessorDefinitions) - MultiThreaded - true - - - Level3 - ProgramDatabase - - - - - MaxSpeed - true - ..\zlib;%(AdditionalIncludeDirectories) - _CRT_SECURE_NO_WARNINGS;%(PreprocessorDefinitions) - MultiThreaded - true - - - Level3 - ProgramDatabase - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/zip_lib/zip_lib2010.vcxproj.filters b/zip_lib/zip_lib2010.vcxproj.filters deleted file mode 100644 index c88fb0b8..00000000 --- a/zip_lib/zip_lib2010.vcxproj.filters +++ /dev/null @@ -1,49 +0,0 @@ - - - - - {4FC737F1-C7A5-4376-A066-2A32D752A2FF} - cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx - - - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - - - - \ No newline at end of file diff --git a/zlib/zlib-Express2010.vcxproj b/zlib/zlib-Express2010.vcxproj deleted file mode 100644 index e827ecf9..00000000 --- a/zlib/zlib-Express2010.vcxproj +++ /dev/null @@ -1,161 +0,0 @@ - - - - - Debug NoDX - Win32 - - - Debug - Win32 - - - Release NoDX - Win32 - - - Release - Win32 - - - - zlib - {7935B998-C713-42AE-8F6D-9FF9080A1B1B} - zlib - Win32Proj - - - - StaticLibrary - NotSet - true - - - StaticLibrary - NotSet - true - - - StaticLibrary - NotSet - - - StaticLibrary - NotSet - - - - - - - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - $(SolutionDir)$(Configuration)\ - $(SolutionDir)$(Configuration)\ - $(Configuration)\ - $(Configuration)\ - $(SolutionDir)$(Configuration)\ - $(SolutionDir)$(Configuration)\ - $(Configuration)\ - $(Configuration)\ - - - - Disabled - _CRT_SECURE_NO_WARNINGS;%(PreprocessorDefinitions) - true - Default - MultiThreadedDebug - - - Level3 - ProgramDatabase - - - - - Disabled - _CRT_SECURE_NO_WARNINGS;%(PreprocessorDefinitions) - true - Default - MultiThreadedDebug - - - Level3 - ProgramDatabase - - - - - MaxSpeed - true - _CRT_SECURE_NO_WARNINGS;%(PreprocessorDefinitions) - MultiThreaded - true - - - Level3 - ProgramDatabase - - - - - MaxSpeed - true - _CRT_SECURE_NO_WARNINGS;%(PreprocessorDefinitions) - MultiThreaded - true - - - Level3 - ProgramDatabase - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/zlib/zlib-Express2010.vcxproj.filters b/zlib/zlib-Express2010.vcxproj.filters deleted file mode 100644 index e717042c..00000000 --- a/zlib/zlib-Express2010.vcxproj.filters +++ /dev/null @@ -1,94 +0,0 @@ - - - - - {4FC737F1-C7A5-4376-A066-2A32D752A2FF} - cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx - - - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - - - - \ No newline at end of file