ScummVM API documentation
Freescape Namespace Reference

Classes

struct  AmigaDmaSample
 
struct  AmigaSfxEntry
 
struct  AnimationOpcode
 
class  Area
 
class  AreaConnections
 
struct  C64SFXData
 
class  CastleEngine
 
struct  CGAPaletteEntry
 
class  DarkEngine
 
class  DarkSideC64MusicPlayer
 
class  DarkSideC64SFXPlayer
 
class  Debugger
 
class  DrillerC64SFXPlayer
 
class  DrillerEngine
 
class  DrillerSIDPlayer
 
struct  ECD
 
class  EclipseAYMusicPlayer
 
class  EclipseC64MusicPlayer
 
class  EclipseC64SFXPlayer
 
class  EclipseEngine
 
class  EclipseOPLMusicPlayer
 
class  Entrance
 
class  EventManagerWrapper
 
class  FCLInstruction
 
class  Font
 
class  FreescapeEngine
 
class  GeometricObject
 
class  GlobalStructure
 
class  Group
 
class  Object
 
class  OpenGLShaderRenderer
 
class  OpenGLTexture
 
class  Renderer
 
struct  Riddle
 
struct  RiddleText
 
class  Sensor
 
class  SizedPCSpeaker
 
struct  soundFx
 
struct  soundSpeakerFx
 
struct  soundUnitZX
 
class  Texture
 
class  TinyGL2DTexture
 
class  TinyGL3DTexture
 
class  TinyGLRenderer
 
struct  Token
 
struct  WBTableOffsets
 

Typedefs

typedef Common::HashMap< uint16, Object * > ObjectMap
 
typedef Common::Array< Object * > ObjectArray
 
typedef Common::HashMap< uint16, Area * > AreaMap
 
typedef Common::Array< byte * > ColorMap
 
typedef Common::HashMap< uint16, int32 > StateVars
 
typedef Common::HashMap< int, int > ColorReMap
 
typedef Common::Array< FCLInstructionFCLInstructionVector
 

Enumerations

enum  CameraMovement { kForwardMovement, kBackwardMovement, kLeftMovement, kRightMovement }
 
enum  FreescapeAction {
  kActionNone, kActionEscape, kActionSave, kActionLoad,
  kActionToggleSound, kActionMoveUp, kActionMoveDown, kActionMoveLeft,
  kActionMoveRight, kActionShoot, kActionActivate, kActionIncreaseAngle,
  kActionDecreaseAngle, kActionChangeStepSize, kActionToggleRiseLower, kActionRiseOrFlyUp,
  kActionLowerOrFlyDown, kActionChangeMode, kActionSkip, kActionFaceForward,
  kActionRotateUp, kActionRotateDown, kActionRotateLeft, kActionRotateRight,
  kActionTurnBack, kActionInfoMenu, kActionIncreaseStepSize, kActionDecreaseStepSize,
  kActionToggleFlyMode, kActionToggleClipMode, kActionDeployDrillingRig, kActionCollectDrillingRig,
  kActionRollLeft, kActionRollRight, kActionRest, kActionRunMode,
  kActionWalkMode, kActionCrawlMode, kActionRunModifier, kActionSelectPrince,
  kActionSelectPrincess, kActionQuit, kActionToggleFlashlight, kActionUnknownKey,
  kActionWait
}
 
enum  {
  kFreescapeDebugMove = 1, kFreescapeDebugParser, kFreescapeDebugCode, kFreescapeDebugMedia,
  kFreescapeDebugGroup
}
 
enum  { kFreescapeDefaultVolume = 192 }
 
enum  GameStateControl {
  kFreescapeGameStateStart, kFreescapeGameStatePlaying, kFreescapeGameStateDemo, kFreescapeGameStateEnd,
  kFreescapeGameStateRestart
}
 
enum  GameReleaseFlags {
  GF_AMIGA_RETAIL = (1 << 0), GF_AMIGA_BUDGET = (1 << 1), GF_ZX_RETAIL = (1 << 2), GF_ZX_BUDGET = (1 << 3),
  GF_ZX_DISC = (1 << 4), GF_CPC_RETAIL = (1 << 5), GF_CPC_RETAIL_ALT = (1 << 6), GF_CPC_BUDGET = (1 << 7),
  GF_CPC_VIRTUALWORLDS = (1 << 8), GF_ATARI_RETAIL = (1 << 9), GF_ATARI_BUDGET = (1 << 10), GF_C64_TAPE = (1 << 11),
  GF_C64_DISC = (1 << 12)
}
 
enum  { kVariableDarkEnding = 28, kVariableDarkECD = 29, kVariableActiveECDs = 60 }
 
enum  { kDarkEndingEvathDestroyed = 1, kDarkEndingECDsDestroyed = 2 }
 
enum  DarkFontSize { kDarkFontSmall, kDarkFontMedium, kDarkFontBig }
 
enum  DrillerFontSize { kDrillerFontSmall, kDrillerFontNormal }
 
enum  DrillerReleaseFlags { GF_AMIGA_MAGAZINE_DEMO = (1 << 0), GF_ATARI_MAGAZINE_DEMO = (1 << 1) }
 
enum  EclipseReleaseFlags { GF_ZX_DEMO_CRASH = (1 << 0), GF_ZX_DEMO_MICROHOBBY = (1 << 1) }
 
enum  { kVariableEclipse2SphinxParts = 1, kVariableEclipseAnkhs = 32 }
 
enum  { k8bitGameBitTravelRock = 30 }
 
enum  {
  k8bitVariableCrawling = 30, k8bitVariableSpiritsDestroyed = 28, k8bitVariableEnergy = 62, k8bitVariableScore = 61,
  k8bitVariableShieldDrillerTank = 60, k8bitVariableEnergyDrillerTank = 59, k8bitVariableShieldDrillerJet = 58, k8bitVariableEnergyDrillerJet = 57,
  k8bitMaxVariable = 64
}
 
enum  { kConditionalShot = 1 << 0, kConditionalTimeout = 1 << 1, kConditionalCollided = 1 << 2, kConditionalActivated = 1 << 3 }
 
enum  ObjectType {
  kEntranceType = 0, kCubeType = 1, kSensorType = 2, kRectangleType = 3,
  kEastPyramidType = 4, kWestPyramidType = 5, kUpPyramidType = 6, kDownPyramidType = 7,
  kNorthPyramidType = 8, kSouthPyramidType = 9, kLineType = 10, kTriangleType = 11,
  kQuadrilateralType = 12, kPentagonType = 13, kHexagonType = 14, kGroupType = 15
}
 
enum  SIDRegs {
  kSIDV1FreqLo = 0x00, kSIDV1FreqHi = 0x01, kSIDV1PwLo = 0x02, kSIDV1PwHi = 0x03,
  kSIDV1Ctrl = 0x04, kSIDV1AD = 0x05, kSIDV1SR = 0x06, kSIDV2FreqLo = 0x07,
  kSIDV2FreqHi = 0x08, kSIDV2PwLo = 0x09, kSIDV2PwHi = 0x0A, kSIDV2Ctrl = 0x0B,
  kSIDV2AD = 0x0C, kSIDV2SR = 0x0D, kSIDV3FreqLo = 0x0E, kSIDV3FreqHi = 0x0F,
  kSIDV3PwLo = 0x10, kSIDV3PwHi = 0x11, kSIDV3Ctrl = 0x12, kSIDV3AD = 0x13,
  kSIDV3SR = 0x14, kSIDFilterLo = 0x15, kSIDFilterHi = 0x16, kSIDFilterCtrl = 0x17,
  kSIDVolume = 0x18
}
 

Functions

bool isEncodedCPCDirectColor (uint8 index)
 
uint8 encodeCPCDirectColor (uint8 index)
 
uint8 decodeCPCDirectColor (uint8 index)
 
Common::String shiftStr (const Common::String &str, int shift)
 
Common::String centerAndPadString (const Common::String &str, int size)
 
Graphics::ManagedSurfacereadCPCImage (Common::SeekableReadStream *file, bool mode1)
 
const Graphics::PixelFormat getRGBAPixelFormat ()
 
byte getCPCPixelMode1 (byte cpc_byte, int index)
 
byte getCPCPixelMode0 (byte cpc_byte, int index)
 
byte getCPCPixel (byte cpc_byte, int index, bool mode1)
 
Graphics::RendererType determinateRenderType ()
 
RendererCreateGfxOpenGL (int screenW, int screenH, Common::RenderMode renderMode, bool authenticGraphics)
 
RendererCreateGfxOpenGLShader (int screenW, int screenH, Common::RenderMode renderMode, bool authenticGraphics)
 
RendererCreateGfxTinyGL (int screenW, int screenH, Common::RenderMode renderMode)
 
RenderercreateRenderer (int screenW, int screenH, Common::RenderMode renderMode, bool authenticGraphics)
 
Common::String detokenise8bitCondition (Common::Array< uint16 > &tokenisedCondition, FCLInstructionVector &instructions, bool enableActivated)
 
FCLInstructionVectorduplicateCondition (FCLInstructionVector *condition)
 
Math::AABB createPlayerAABB (Math::Vector3d const position, int playerHeight, float reductionHeight=0.0f)
 
float sweepAABB (Math::AABB const &a, Math::AABB const &b, Math::Vector3d const &direction, Math::Vector3d &normal)
 
Audio::AudioStreammakeWallyBebenStream (const byte *data, uint32 dataSize, int songNum=1, int rate=44100, bool stereo=true, const WBTableOffsets *offsets=nullptr)
 

Variables

byte kEGADefaultPalette [16][3]
 
byte kCGAPaletteRedGreen [4][3]
 
byte kCGAPalettePinkBlue [4][3]
 
byte kCGAPalettePinkBlueBright [4][3]
 
byte kCGAPaletteRedGreenBright [4][3]
 
byte kHerculesPaletteGreen [2][3]
 
FreescapeEngineg_freescape
 
Debuggerg_debugger
 
uint8 k8bitVariableShield
 

Detailed Description

Shared music data for Total Eclipse backported music players.

Song data extracted from the C64 version's Wally Beben music engine. The shared instrument table strips SID-only pulse-width fields, but the original pulse-width values are kept below for ports that can use them. This header is included by both the AY and OPL player implementations.

Function Documentation

◆ makeWallyBebenStream()

Audio::AudioStream* Freescape::makeWallyBebenStream ( const byte *  data,
uint32  dataSize,
int  songNum = 1,
int  rate = 44100,
bool  stereo = true,
const WBTableOffsets offsets = nullptr 
)

Create a music stream for the Wally Beben custom music engine used in the Amiga versions of Dark Side and Total Eclipse.

Parameters
dataRaw TEXT segment data (after 0x1C GEMDOS header)
dataSizeSize of the TEXT segment
songNumSong number to play (1 or 2)
rateOutput sample rate
stereoWhether to produce stereo output
offsetsTable offsets (nullptr = Dark Side defaults)
Returns
A new AudioStream, or nullptr on error