Skip to content

Commit

Permalink
GUI: channel status, part 6
Browse files Browse the repository at this point in the history
PC Engine
  • Loading branch information
tildearrow committed Oct 28, 2023
1 parent d4b392a commit bd88639
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 0 deletions.
14 changes: 14 additions & 0 deletions src/engine/platform/pce.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@

#include "pce.h"
#include "../engine.h"
// TODO: move this away
#include "../../src/gui/furIcons.h"
#include <math.h>

//#define rWrite(a,v) pendingWrites[a]=v;
Expand Down Expand Up @@ -512,6 +514,18 @@ unsigned short DivPlatformPCE::getPan(int ch) {
return ((chan[ch].pan&0xf0)<<4)|(chan[ch].pan&15);
}

DivChannelModeHints DivPlatformPCE::getModeHints(int ch) {
DivChannelModeHints ret;
if (ch<4) return ret;
ret.count=1;
ret.hint[0]=ICON_FUR_NOISE;
ret.type[0]=0;

if (chan[ch].noise) ret.type[0]=4;

return ret;
}

DivSamplePos DivPlatformPCE::getSamplePos(int ch) {
if (ch>=6) return DivSamplePos();
if (!chan[ch].pcm) return DivSamplePos();
Expand Down
1 change: 1 addition & 0 deletions src/engine/platform/pce.h
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,7 @@ class DivPlatformPCE: public DivDispatch {
void* getChanState(int chan);
DivMacroInt* getChanMacroInt(int ch);
unsigned short getPan(int chan);
DivChannelModeHints getModeHints(int chan);
DivSamplePos getSamplePos(int ch);
DivDispatchOscBuffer* getOscBuffer(int chan);
unsigned char* getRegisterPool();
Expand Down

0 comments on commit bd88639

Please sign in to comment.