Skip to content

Commit 092ff59

Browse files
author
kldavis
committed
no message
1 parent fe3d639 commit 092ff59

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

41 files changed

+1408
-635
lines changed

Bliss.suo

0 Bytes
Binary file not shown.

Bliss/Bliss.vcproj

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
<VisualStudioProject
33
ProjectType="Visual C++"
44
Version="7.10"
5-
Name="Bliss.Mfc"
5+
Name="Bliss"
66
ProjectGUID="{124CF7CF-B0BE-478D-AC37-D90056856807}"
77
Keyword="MFCProj">
88
<Platforms>
@@ -449,12 +449,6 @@
449449
<File
450450
RelativePath=".\core\video\GRAM.h">
451451
</File>
452-
<File
453-
RelativePath=".\core\video\GROM.cpp">
454-
</File>
455-
<File
456-
RelativePath=".\core\video\GROM.h">
457-
</File>
458452
<File
459453
RelativePath=".\core\video\GTIA.cpp">
460454
</File>

Bliss/ToDo.txt

Lines changed: 11 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,21 @@
11
FOR NEXT RELEASE
2-
- video
3-
- fix the video niggles along the seam between the triangles
4-
- the "/fullscreen" command line option is not working for the version downloaded in the .zip
5-
file; we should probably also check to see if a cart passed on the command line is broken
6-
in the .zip version as well.
7-
- missiles in Astrosmash go straight through meteors, but they should be destroyed
2+
- do more robust lost device handling when device is lost due to window focus in fullscreen mode
3+
emulator should pause instead of constantly trying to re-obtain the device, forcing the user back
4+
into the Bliss window
5+
- when the emulator is paused and the user switches between windowed and full-screen, the emulator
6+
output does not redraw correctly, probably due to graphics on the texture that need to be
7+
reloaded
8+
- correctly select the first item in the tree when the options window is displayed
9+
- make the options window resizable
10+
- bind a control combination (&&) or more than one control (||) to an input; some of this is
11+
there, but still need to resolve how to save such complex input configurations in the registry
812

913
LONG TERM VISION
1014
- video
15+
- display the window menu in fullscreen mode
1116
- offer the ability to display the overlays somehow, maybe as a toggle display for the
1217
lower left and right sides of the screen
13-
- display the window menu in fullscreen mode
1418
- input
15-
- bind a control combination (&&) or more than one control (||) to an input
16-
- allow user to unbind an input configuration
1719
- enable user to configure the ENTER or SPACE keyboard keys
1820
- allow the user to custom-bind different controls to different games
1921
- saving and loading
@@ -23,15 +25,6 @@ LONG TERM VISION
2325
- record audio
2426
- record video
2527
- other stuff
26-
- change .bin/.int support so that it is not file-extension specific, but instead is the
27-
last fallback method of loading the selected file (?)
2828
- allow user to start ECS without a cartridge
29-
- support ability to pause; this will enable more robust lost device handling
3029
- ROMBanker is being saved as a RAM block in Rip::SaveRip(); need a more comprehensive ROM
3130
banking solution
32-
33-
INPUT CONFIGURATION
34-
- add a new binding (single button push or combination)
35-
- remove an existing binding
36-
- clear all bindings
37-
- edit bindings for a particular game

Bliss/core/Emulator.cpp

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,6 @@
11

22
#include "Emulator.h"
33
#include "drivers/intv/Intellivision.h"
4-
#include "drivers/a5200/Atari5200.h"
5-
6-
#define NUM_EMULATORS 1
74

85
extern UINT32 systemIDs[NUM_EMULATORS];
96
extern Emulator* emus[NUM_EMULATORS];
@@ -202,15 +199,14 @@ void Emulator::FlushAudio()
202199
audioMixer.flushAudio();
203200
}
204201

205-
UINT32 systemIDs[NUM_EMULATORS] = {
202+
UINT32 Emulator::systemIDs[NUM_EMULATORS] = {
206203
// 0xE4453A0B,
207204
0x4AC771F8,
208205
};
209206

210-
Intellivision inty;
211-
//Atari5200 a5200;
207+
Intellivision Emulator::inty;
212208

213-
Emulator* emus[] = {
209+
Emulator* Emulator::emus[] = {
214210
// &a5200,
215211
&inty,
216212
};

Bliss/core/Emulator.h

Lines changed: 19 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -20,25 +20,35 @@
2020
#include "core/memory/MemoryBus.h"
2121
#include "core/memory/Memory.h"
2222

23+
class Intellivision;
24+
//class Atari5200;
25+
2326
#define MAX_PERIPHERALS 16
27+
#define NUM_EMULATORS 1
2428

29+
/**
30+
*
31+
*/
2532
class Emulator : public Peripheral
2633
{
2734
public:
35+
void AddPeripheral(Peripheral* p);
36+
UINT32 GetPeripheralCount();
37+
Peripheral* GetPeripheral(UINT32);
38+
39+
void UsePeripheral(UINT32, BOOL);
40+
41+
void SetRip(Rip* rip);
42+
2843
void InitVideo(IDirect3DDevice9* direct3DDevice);
2944
void ReleaseVideo();
3045
void InitAudio(IDirectSoundBuffer8* directSoundBuffer);
3146
void ReleaseAudio();
3247

3348
void Reset();
3449
void Run();
35-
void Render();
3650
void FlushAudio();
37-
void SetRip(Rip* rip);
38-
39-
UINT32 GetPeripheralCount();
40-
Peripheral* GetPeripheral(UINT32);
41-
void UsePeripheral(UINT32, BOOL);
51+
void Render();
4252

4353
static UINT32 GetEmulatorCount();
4454
static Emulator* GetEmulator(UINT32 i);
@@ -47,8 +57,6 @@ class Emulator : public Peripheral
4757
protected:
4858
Emulator(const char* name);
4959

50-
void AddPeripheral(Peripheral* p);
51-
5260
MemoryBus memoryBus;
5361

5462
private:
@@ -66,6 +74,9 @@ class Emulator : public Peripheral
6674
BOOL usePeripheralIndicators[MAX_PERIPHERALS];
6775
INT32 peripheralCount;
6876

77+
static UINT32 systemIDs[NUM_EMULATORS];
78+
static Emulator* emus[NUM_EMULATORS];
79+
static Intellivision inty;
6980

7081
};
7182

Bliss/core/Peripheral.h

Lines changed: 157 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -12,43 +12,167 @@
1212
#define MAX_COMPONENTS 16
1313

1414
/**
15-
* A peripheral represents a device that contains emulated components, including
16-
* processors, memory units, video producers, audio producers, and input consumers.
17-
*
18-
* Each peripheral must to describe the components it contains and the system
19-
* ROMs it needs.
15+
* A peripheral represents a device that contains emulated hardware components, including
16+
* processors and memory units. Each processor or memory unit may optionally also be a
17+
* video producer, audio producer, and/or input consumer. However, some input consumers are
18+
* neither processors or memory units.
2019
*/
2120
class Peripheral
2221
{
2322
public:
23+
/**
24+
* Gets the name of this peripheral.
25+
*
26+
* @return the peripheral name
27+
*/
2428
const char* GetName() { return peripheralName; }
29+
30+
/**
31+
* Gets the short name of this peripheral.
32+
*
33+
* @return the short peripheral name
34+
*/
2535
const char* GetShortName() { return peripheralShortName; }
2636

27-
void AddProcessor(Processor*);
37+
/**
38+
* Adds a processor to this peripheral.
39+
*
40+
* @param processor the processor to add
41+
*/
42+
void AddProcessor(Processor* processor);
43+
44+
/**
45+
* Gets the number of processors in this peripheral.
46+
*
47+
* @return the number of processors
48+
*/
2849
UINT16 GetProcessorCount();
29-
Processor* GetProcessor(UINT16 i);
3050

31-
void AddRAM(RAM*);
51+
/**
52+
* Gets a pointer to the processor indicated by an index.
53+
*
54+
* @param index the index of the processor to return
55+
* @return a pointer to the processor
56+
*/
57+
Processor* GetProcessor(UINT16 index);
58+
59+
/**
60+
* Adds a RAM unit to this peripheral.
61+
*
62+
* @param ram the RAM unit to add
63+
*/
64+
void AddRAM(RAM* ram);
65+
66+
/**
67+
* Gets the number of RAM units in this peripheral.
68+
*
69+
* @return the number of RAM units
70+
*/
3271
UINT16 GetRAMCount();
33-
RAM* GetRAM(UINT16 i);
3472

35-
void AddROM(ROM*);
73+
/**
74+
* Gets a pointer to the RAM unit indicated by an index.
75+
*
76+
* @param index the index of the RAM unit to return
77+
* @return a pointer to the RAM unit
78+
*/
79+
RAM* GetRAM(UINT16 index);
80+
81+
/**
82+
* Adds a ROM unit to this peripheral.
83+
*
84+
* @param rom the ROM unit to add
85+
*/
86+
void AddROM(ROM* rom);
87+
88+
/**
89+
* Gets the number of ROM units in this peripheral.
90+
*
91+
* @return the number of ROM units
92+
*/
3693
UINT16 GetROMCount();
37-
ROM* GetROM(UINT16 i);
3894

39-
void AddVideoProducer(VideoProducer*);
95+
/**
96+
* Gets a pointer to the ROM unit indicated by an index.
97+
*
98+
* @param index the index of the ROM unit to return
99+
* @return a pointer to the ROM unit
100+
*/
101+
ROM* GetROM(UINT16 index);
102+
103+
/**
104+
* Adds a video producer to this peripheral.
105+
*
106+
* @param vp the video producer to add
107+
*/
108+
void AddVideoProducer(VideoProducer* vp);
109+
110+
/**
111+
* Gets the number of video producers in this peripheral.
112+
*
113+
* @return the number of video producers
114+
*/
40115
UINT16 GetVideoProducerCount();
41-
VideoProducer* GetVideoProducer(UINT16 i);
42116

43-
void AddAudioProducer(AudioProducer*);
117+
/**
118+
* Gets a pointer to the video producer indicated by an index.
119+
*
120+
* @param index the index of the video producer to return
121+
* @return a pointer to the video producer
122+
*/
123+
VideoProducer* GetVideoProducer(UINT16 index);
124+
125+
/**
126+
* Adds an audio producer to this peripheral.
127+
*
128+
* @param ap the audio producer to add
129+
*/
130+
void AddAudioProducer(AudioProducer* ap);
131+
132+
/**
133+
* Gets the number of audio producers in this peripheral.
134+
*
135+
* @return the number of audio producers
136+
*/
44137
UINT16 GetAudioProducerCount();
45-
AudioProducer* GetAudioProducer(UINT16 i);
46138

139+
/**
140+
* Gets a pointer to the audio producer indicated by an index.
141+
*
142+
* @param index the index of the audio producer to return
143+
* @return a pointer to the audio producer
144+
*/
145+
AudioProducer* GetAudioProducer(UINT16 index);
146+
147+
/**
148+
* Adds an input consumer to this peripheral.
149+
*
150+
* @param ic the input consumer to add
151+
*/
47152
void AddInputConsumer(InputConsumer*);
153+
154+
/**
155+
* Gets the number of input consumers in this peripheral.
156+
*
157+
* @return the number of input consumers
158+
*/
48159
UINT16 GetInputConsumerCount();
49-
InputConsumer* GetInputConsumer(UINT16 i);
160+
161+
/**
162+
* Gets a pointer to the input consumer indicated by an index.
163+
*
164+
* @param index the index of the input consumer to return
165+
* @return a pointer to the input consumer
166+
*/
167+
InputConsumer* GetInputConsumer(UINT16 index);
50168

51169
protected:
170+
/**
171+
* Constructs a peripheral.
172+
*
173+
* @param name the name of the peripheral
174+
* @param shortName the short name of the peripheral
175+
*/
52176
Peripheral(const CHAR* name, const CHAR* shortName)
53177
: processorCount(0),
54178
videoProducerCount(0),
@@ -58,23 +182,30 @@ class Peripheral
58182
romCount(0),
59183
peripheralName(NULL),
60184
peripheralShortName(NULL)
61-
{
62-
if (name) {
63-
peripheralName = new CHAR[strlen(name)+1];
64-
strcpy(peripheralName, name);
65-
}
66-
if (shortName) {
67-
peripheralShortName = new CHAR[strlen(shortName)+1];
68-
strcpy(peripheralShortName, shortName);
69-
}
185+
{
186+
if (name) {
187+
peripheralName = new CHAR[strlen(name)+1];
188+
strcpy(peripheralName, name);
70189
}
190+
if (shortName) {
191+
peripheralShortName = new CHAR[strlen(shortName)+1];
192+
strcpy(peripheralShortName, shortName);
193+
}
194+
}
195+
196+
/**
197+
* Destroys the peripheral.
198+
*/
71199
~Peripheral()
72200
{
73201
delete[] peripheralShortName;
74202
delete[] peripheralName;
75203
}
76204

77-
//rip exposes peripheral name as mutable, so we leave it protected here
205+
/**
206+
* The peripheral name. The Rip class exposes the periphal name as mutable, so we leave
207+
* it exposed as protected access here. This will probably change in the future.
208+
*/
78209
char* peripheralName;
79210

80211
private:

0 commit comments

Comments
 (0)