Publish VCC Plus OSS source distribution for 3.6.2 build 60

This commit is contained in:
Brian Holman committed 2026-11-13 00:14:03 -07:00
commit c652a5276d
1192 files changed
+272368

No files matched your search

+148
View File
@@ -0,0 +1,148 @@
/*
Copyright 2015 by Joseph Forgione
This file is part of VCC (Virtual Color Computer).
VCC (Virtual Color Computer) 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 3 of the License, or
(at your option) any later version.
VCC (Virtual Color Computer) 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 VCC (Virtual Color Computer). If not, see <http://www.gnu.org/licenses/>.
*/
//==========================================================================
// Orch90 is perhaps the simplest pak, it uses PakSampleAudio() to simulate
// two 8-bit digital-to-analog converters.
//==========================================================================
#include <Windows.h>
#include <stdio.h>
#include "resource.h"
#include <vcc/util/FileOps.h>
#include <vcc/bus/cpak_cartridge_definitions.h>
#include <vcc/util/limits.h>
#include <vcc/util/logger.h>
static HINSTANCE gModuleInstance;
static slot_id_type gSlotId {};
static PakAssertCartridgeLineHostCallback PakSetCart = nullptr;
static unsigned char LeftChannel=0,RightChannel=0;
static unsigned char Rom[8192];
bool LoadRom();
// DLL exports
extern "C"
{
__declspec(dllexport) const char* PakGetName()
{
static char string_buffer[MAX_LOADSTRING];
strcpy(string_buffer, "Orchestra-90");
return string_buffer;
}
__declspec(dllexport) const char* PakGetCatalogId()
{
static char string_buffer[MAX_LOADSTRING];
LoadString(gModuleInstance, IDS_CATNUMBER, string_buffer, MAX_LOADSTRING);
return string_buffer;
}
__declspec(dllexport) const char* PakGetDescription()
{
static char string_buffer[MAX_LOADSTRING];
LoadString(gModuleInstance, IDS_DESCRIPTION, string_buffer, MAX_LOADSTRING);
return string_buffer;
}
__declspec(dllexport) void PakInitialize(
slot_id_type SlotId,
const char* const /*configuration_path*/,
HWND hVccWnd,
const cpak_callbacks* const callbacks)
{
DLOG_C("orch90 init\n");
gSlotId = SlotId;
PakSetCart = callbacks->assert_cartridge_line;
}
__declspec(dllexport) void PakWritePort(unsigned char Port,unsigned char Data)
{
switch (Port)
{
case 0x7A:
RightChannel=Data;
break;
case 0x7B:
LeftChannel=Data;
break;
}
return;
}
__declspec(dllexport) unsigned char PakReadPort(unsigned char /*Port*/)
{
return 0;
}
__declspec(dllexport) void PakReset()
{
DLOG_C("orch90 reset\n");
if (LoadRom()) PakSetCart(gSlotId, 1);
}
__declspec(dllexport) unsigned char PakReadMemoryByte(unsigned short Address)
{
return(Rom[Address & 8191]);
}
__declspec(dllexport) unsigned short PakSampleAudio()
{
//This is called every scan line 262 Lines * 60 Frames = 15780 Hz 15720
return((LeftChannel<<8) | RightChannel) ;
}
}
// DLLMain
BOOL WINAPI DllMain(
HINSTANCE hinstDLL, // handle to DLL module
DWORD fdwReason, // reason for calling function
LPVOID lpReserved ) // reserved
{
if (fdwReason == DLL_PROCESS_ATTACH)
gModuleInstance = hinstDLL;
return TRUE;
}
//Load orch90.rom
bool LoadRom()
{
memset(Rom, 0xff, 8192);
// Assume rom is in same directory as orch90.dll
char RomPath[MAX_PATH];
GetModuleFileName(nullptr, RomPath, MAX_PATH);
PathRemoveFileSpec(RomPath);
strcpy(RomPath, "ORCH90.ROM");
FILE *rom_handle = fopen(RomPath, "rb");
if (rom_handle == nullptr) return false;
unsigned short index = 0;
while ((feof(rom_handle) == 0) & (index<8192))
Rom[index++] = fgetc(rom_handle);
fclose(rom_handle);
return true;
}
+123
View File
@@ -0,0 +1,123 @@
//Microsoft Developer Studio generated resource script.
//
#include "resource.h"
#define APSTUDIO_READONLY_SYMBOLS
/////////////////////////////////////////////////////////////////////////////
//
// Generated from the TEXTINCLUDE 2 resource.
//
#include "winres.h"
/////////////////////////////////////////////////////////////////////////////
#undef APSTUDIO_READONLY_SYMBOLS
/////////////////////////////////////////////////////////////////////////////
// English (U.S.) resources
#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU)
#ifdef _WIN32
LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US
#pragma code_page(1252)
#endif //_WIN32
#ifdef APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// TEXTINCLUDE
//
1 TEXTINCLUDE DISCARDABLE
BEGIN
"resource.h\0"
END
2 TEXTINCLUDE DISCARDABLE
BEGIN
"#include ""winres.h""\r\n"
"\0"
END
3 TEXTINCLUDE DISCARDABLE
BEGIN
"\r\n"
"\0"
END
#endif // APSTUDIO_INVOKED
#ifndef _MAC
/////////////////////////////////////////////////////////////////////////////
//
// Version
//
VS_VERSION_INFO VERSIONINFO
FILEVERSION 2,1,8,1
PRODUCTVERSION 2,1,8,1
FILEFLAGSMASK 0x3fL
#ifdef _DEBUG
FILEFLAGS 0x21L
#else
FILEFLAGS 0x20L
#endif
FILEOS 0x40004L
FILETYPE 0x2L
FILESUBTYPE 0x0L
BEGIN
BLOCK "StringFileInfo"
BEGIN
BLOCK "040904b0"
BEGIN
VALUE "Comments", "Tandy Orchestra 90-CC Stereo Sound Pak\0"
VALUE "CompanyName", "BitRot Software.\0"
VALUE "FileDescription", "Orchestra 90-CC \0"
VALUE "FileVersion", "2.1.8.1\0"
VALUE "InternalName", "orch90\0"
VALUE "LegalCopyright", "Copyright � 2006\0"
VALUE "LegalTrademarks", "\0"
VALUE "OriginalFilename", "orch90.dll\0"
VALUE "PrivateBuild", "\0"
VALUE "ProductName", "Orchestra 90-CC\0"
VALUE "ProductVersion", "26-3143\0"
VALUE "SpecialBuild", "Tandy Orchestra-90-CC\0"
END
END
BLOCK "VarFileInfo"
BEGIN
VALUE "Translation", 0x409, 1200
END
END
#endif // !_MAC
/////////////////////////////////////////////////////////////////////////////
//
// String Table
//
STRINGTABLE DISCARDABLE
BEGIN
IDS_MODULE_NAME "Orchestra-90"
IDS_CATNUMBER "26-3143"
IDS_VERSION "1.30"
IDS_DESCRIPTION "Emulates Tandy Orchestra-90 CC Stereo Music Synthesizer cart with rom. The rom supports six octave ranges and up to five simultaneous voices. It can transfer music to/from tape or from a floppy mounted in drive zero. Either FD502 or SDC must be inserted in mpi slot 4 for floppy support."
END
#endif // English (U.S.) resources
/////////////////////////////////////////////////////////////////////////////
#ifndef APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// Generated from the TEXTINCLUDE 3 resource.
//
/////////////////////////////////////////////////////////////////////////////
#endif // not APSTUDIO_INVOKED
+112
View File
@@ -0,0 +1,112 @@
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup Label="ProjectConfigurations">
<ProjectConfiguration Include="Debug|Win32">
<Configuration>Debug</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Legacy|Win32">
<Configuration>Legacy</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|Win32">
<Configuration>Release</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
</ItemGroup>
<PropertyGroup Label="Globals">
<SccProjectName />
<SccLocalPath />
<ProjectGuid>{89C050F1-9427-4C5F-B260-C5F9EB43E915}</ProjectGuid>
<WindowsTargetPlatformVersion>10.0</WindowsTargetPlatformVersion>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Legacy|Win32'" Label="Configuration">
<ConfigurationType>DynamicLibrary</ConfigurationType>
<CharacterSet>MultiByte</CharacterSet>
<PlatformToolset>v141_xp</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
<ConfigurationType>DynamicLibrary</ConfigurationType>
<CharacterSet>MultiByte</CharacterSet>
<PlatformToolset>v143</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
<ConfigurationType>DynamicLibrary</ConfigurationType>
<CharacterSet>MultiByte</CharacterSet>
<PlatformToolset>v143</PlatformToolset>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
<ImportGroup Label="ExtensionSettings">
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Legacy|Win32'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
<Import Project="..\vcc-base.props" />
<Import Project="..\vcc-legacy.props" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
<Import Project="..\vcc-base.props" />
<Import Project="..\vcc-release.props" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
<Import Project="..\vcc-base.props" />
<Import Project="..\vcc-debug.props" />
</ImportGroup>
<PropertyGroup Label="UserMacros" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Legacy|Win32'">
<LibraryPath>C:\Program Files %28x86%29\Windows Kits\8.1\Lib\winv6.3\um\x86;$(LibraryPath)</LibraryPath>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" />
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<ClCompile>
<PreprocessorDefinitions>WIN32;ORCH90_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
</ClCompile>
<ResourceCompile />
<Link>
<LinkDLL>true</LinkDLL>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Legacy|Win32'">
<ClCompile>
<PreprocessorDefinitions>WIN32;_USRDLL;ORCH90_EXPORTS;_LEGACY_VCC;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<AdditionalOptions>/arch:SSE</AdditionalOptions>
</ClCompile>
<ResourceCompile>
<Culture>0x0409</Culture>
<PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
</ResourceCompile>
<Link>
<LinkDLL>true</LinkDLL>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<ClCompile>
<PreprocessorDefinitions>WIN32;ORCH90_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<AdditionalOptions>/arch:SSE</AdditionalOptions>
</ClCompile>
<ResourceCompile />
<Link>
<LinkDLL>true</LinkDLL>
</Link>
</ItemDefinitionGroup>
<ItemGroup>
<ClCompile Include="orch90.cpp" />
</ItemGroup>
<ItemGroup>
<ClInclude Include="resource.h" />
</ItemGroup>
<ItemGroup>
<ResourceCompile Include="orch90.rc" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\libcommon\libcommon.vcxproj">
<Project>{e0aa25bd-5527-475f-8d8b-b549a6311b0c}</Project>
</ProjectReference>
</ItemGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets">
</ImportGroup>
</Project>
+19
View File
@@ -0,0 +1,19 @@
//{{NO_DEPENDENCIES}}
// Microsoft Developer Studio generated include file.
// Used by orch90.rc
//
#define IDS_MODULE_NAME 1
#define IDS_CATNUMBER 2
#define IDS_VERSION 3
#define IDS_DESCRIPTION 4
// Next default values for new objects
//
#ifdef APSTUDIO_INVOKED
#ifndef APSTUDIO_READONLY_SYMBOLS
#define _APS_NEXT_RESOURCE_VALUE 101
#define _APS_NEXT_COMMAND_VALUE 40001
#define _APS_NEXT_CONTROL_VALUE 1000
#define _APS_NEXT_SYMED_VALUE 101
#endif
#endif