aboutsummaryrefslogtreecommitdiff
path: root/engines
diff options
context:
space:
mode:
authorMax Horn2010-04-21 21:22:43 +0000
committerMax Horn2010-04-21 21:22:43 +0000
commit37b7be45194ba118f039a9268e42beed895ea9ba (patch)
tree21e03079f491d026efed4ebbd4bd5f4d8a9826d4 /engines
parent3edc151c5bde78eaa810a7ddc6092e9c920fb9c6 (diff)
downloadscummvm-rg350-37b7be45194ba118f039a9268e42beed895ea9ba.tar.gz
scummvm-rg350-37b7be45194ba118f039a9268e42beed895ea9ba.tar.bz2
scummvm-rg350-37b7be45194ba118f039a9268e42beed895ea9ba.zip
CINE: Change Doxygen commands to match our CFC
svn-id: r48764
Diffstat (limited to 'engines')
-rw-r--r--engines/cine/anim.cpp178
-rw-r--r--engines/cine/bg_list.cpp25
-rw-r--r--engines/cine/cine.cpp7
-rw-r--r--engines/cine/gfx.cpp366
-rw-r--r--engines/cine/gfx.h13
-rw-r--r--engines/cine/object.cpp37
-rw-r--r--engines/cine/object.h2
-rw-r--r--engines/cine/pal.cpp6
-rw-r--r--engines/cine/pal.h130
-rw-r--r--engines/cine/part.cpp2
-rw-r--r--engines/cine/prc.cpp5
-rw-r--r--engines/cine/rel.cpp5
-rw-r--r--engines/cine/saveload.cpp30
-rw-r--r--engines/cine/script.h35
-rw-r--r--engines/cine/script_fw.cpp318
-rw-r--r--engines/cine/script_os.cpp127
-rw-r--r--engines/cine/texte.cpp16
-rw-r--r--engines/cine/various.cpp34
18 files changed, 770 insertions, 566 deletions
diff --git a/engines/cine/anim.cpp b/engines/cine/anim.cpp
index 049f22e7cf..5ddc5d625f 100644
--- a/engines/cine/anim.cpp
+++ b/engines/cine/anim.cpp
@@ -23,8 +23,8 @@
*
*/
-/*! \file
- * \todo Make resource manager class and make load* functions its members
+/** \file
+ * @todo Make resource manager class and make load* functions its members
*/
#include "common/endian.h"
@@ -195,7 +195,8 @@ AnimData::AnimData() : _width(0), _height(0), _bpp(0), _var1(0), _data(NULL),
memset(_name, 0, sizeof(_name));
}
-/*! \brief Copy constructor
+/**
+ * Copy constructor
*/
AnimData::AnimData(const AnimData &src) : _width(src._width),
_height(src._height), _bpp(src._bpp), _var1(src._var1),
@@ -218,13 +219,15 @@ AnimData::AnimData(const AnimData &src) : _width(src._width),
strcpy(_name, src._name);
}
-/*! \brief Destructor
+/**
+ * Destructor
*/
AnimData::~AnimData() {
clear();
}
-/*! \brief Assingment operator
+/**
+ * Assingment operator
*/
AnimData &AnimData::operator=(const AnimData &src) {
AnimData tmp = src;
@@ -261,15 +264,16 @@ byte AnimData::getColor(int x, int y) {
return _data[x + y * _realWidth];
}
-/*! \brief Load and decode image frame
- * \param d Encoded image data
- * \param type Encoding type
- * \param w Image width
- * \param h Image height
- * \param file Data file index in bundle
- * \param frame Image frame index
- * \param n Part name
- * \param transparent Transparent color (for ANIM_MASKSPRITE)
+/**
+ * Load and decode image frame
+ * @param d Encoded image data
+ * @param type Encoding type
+ * @param w Image width
+ * @param h Image height
+ * @param file Data file index in bundle
+ * @param frame Image frame index
+ * @param n Part name
+ * @param transparent Transparent color (for ANIM_MASKSPRITE)
*/
void AnimData::load(byte *d, int type, uint16 w, uint16 h, int16 file,
int16 frame, const char *n, byte transparent) {
@@ -354,7 +358,8 @@ void AnimData::load(byte *d, int type, uint16 w, uint16 h, int16 file,
}
}
-/*! \brief Reset image
+/**
+ * Reset image
*/
void AnimData::clear() {
delete[] _data;
@@ -372,8 +377,9 @@ void AnimData::clear() {
_size = 0;
}
-/*! \brief Write image identifiers to savefile
- * \param fHandle Savefile open for writing
+/**
+ * Write image identifiers to savefile
+ * @param fHandle Savefile open for writing
*/
void AnimData::save(Common::OutSaveFile &fHandle) const {
fHandle.writeUint16BE(_width);
@@ -387,9 +393,10 @@ void AnimData::save(Common::OutSaveFile &fHandle) const {
fHandle.write(_name, sizeof(_name));
}
-/*! \brief Clear part of animDataTable
- * \param startIdx First image frame to be cleared
- * \param numIdx Number of image frames to be cleared
+/**
+ * Clear part of animDataTable
+ * @param startIdx First image frame to be cleared
+ * @param numIdx Number of image frames to be cleared
*/
void freeAnimDataRange(byte startIdx, byte numIdx) {
for (byte i = 0; i < numIdx; i++) {
@@ -397,14 +404,16 @@ void freeAnimDataRange(byte startIdx, byte numIdx) {
}
}
-/*! \brief Clear whole animDataTable
+/**
+ * Clear whole animDataTable
*/
void freeAnimDataTable() {
freeAnimDataRange(0, NUM_MAX_ANIMDATA);
}
-/*! \brief Find transparent color index for image
- * \brief animName Image file name
+/**
+ * Find transparent color index for image
+ * @param animName Image file name
*/
static byte getAnimTransparentColor(const char *animName) {
char name[15];
@@ -419,11 +428,12 @@ static byte getAnimTransparentColor(const char *animName) {
return 0;
}
-/*! \brief Generate mask for image
- * \param[in] sprite Image data
- * \param[out] mask Image mask
- * \param size Image data length
- * \param transparency Transparent color index
+/**
+ * Generate mask for image
+ * @param[in] sprite Image data
+ * @param[out] mask Image mask
+ * @param size Image data length
+ * @param transparency Transparent color index
*/
void generateMask(const byte *sprite, byte *mask, uint16 size, byte transparency) {
for (uint16 i = 0; i < size; i++) {
@@ -435,11 +445,12 @@ void generateMask(const byte *sprite, byte *mask, uint16 size, byte transparency
}
}
-/*! \brief Decode 1bpp mask
- * \param[out] dest Decoded mask
- * \param[in] source Encoded mask
- * \param width Mask width
- * \param height Mask height
+/**
+ * Decode 1bpp mask
+ * @param[out] dest Decoded mask
+ * @param[in] source Encoded mask
+ * @param width Mask width
+ * @param height Mask height
*/
void convertMask(byte *dest, const byte *source, int16 width, int16 height) {
int16 i, j;
@@ -454,11 +465,12 @@ void convertMask(byte *dest, const byte *source, int16 width, int16 height) {
}
}
-/*! \brief Decode 4bpp sprite
- * \param[out] dest Decoded image
- * \param[in] source Encoded image
- * \param width Image width
- * \param height Image height
+/**
+ * Decode 4bpp sprite
+ * @param[out] dest Decoded image
+ * @param[in] source Encoded image
+ * @param width Image width
+ * @param height Image height
*/
void convert4BBP(byte *dest, const byte *source, int16 width, int16 height) {
byte maskEntry;
@@ -470,9 +482,10 @@ void convert4BBP(byte *dest, const byte *source, int16 width, int16 height) {
}
}
-/*! \brief Read image header
- * \param[out] animHeader Image header reference
- * \param readS Input stream open for reading
+/**
+ * Read image header
+ * @param[out] animHeader Image header reference
+ * @param readS Input stream open for reading
*/
void loadAnimHeader(AnimHeaderStruct &animHeader, Common::MemoryReadStream readS) {
animHeader.field_0 = readS.readByte();
@@ -495,8 +508,9 @@ void loadAnimHeader(AnimHeaderStruct &animHeader, Common::MemoryReadStream readS
animHeader.field_14 = readS.readUint16BE();
}
-/*! \brief Find next empty space animDataTable
- * \param start First index to check
+/**
+ * Find next empty space animDataTable
+ * @param start First index to check
*/
int emptyAnimSpace(int start = 0) {
for (; start < NUM_MAX_ANIMDATA; start++) {
@@ -508,10 +522,11 @@ int emptyAnimSpace(int start = 0) {
return -1;
}
-/*! \brief Load SPL data into animDataTable
- * \param resourceName SPL filename
- * \param idx Target index in animDataTable (-1 if any empty space will do)
- * \return The number of the animDataTable entry after the loaded SPL data (-1 if error)
+/**
+ * Load SPL data into animDataTable
+ * @param resourceName SPL filename
+ * @param idx Target index in animDataTable (-1 if any empty space will do)
+ * @return The number of the animDataTable entry after the loaded SPL data (-1 if error)
*/
int loadSpl(const char *resourceName, int16 idx) {
int16 foundFileIdx = findFileInBundle(resourceName);
@@ -531,10 +546,11 @@ int loadSpl(const char *resourceName, int16 idx) {
return entry + 1;
}
-/*! \brief Load 1bpp mask
- * \param resourceName Mask filename
- * \param idx Target index in animDataTable (-1 if any empty space will do)
- * \return The number of the animDataTable entry after the loaded mask (-1 if error)
+/**
+ * Load 1bpp mask
+ * @param resourceName Mask filename
+ * @param idx Target index in animDataTable (-1 if any empty space will do)
+ * @return The number of the animDataTable entry after the loaded mask (-1 if error)
*/
int loadMsk(const char *resourceName, int16 idx) {
int16 foundFileIdx = findFileInBundle(resourceName);
@@ -562,10 +578,11 @@ int loadMsk(const char *resourceName, int16 idx) {
return entry;
}
-/*! \brief Load animation
- * \param resourceName Animation filename
- * \param idx Target index in animDataTable (-1 if any empty space will do)
- * \return The number of the animDataTable entry after the loaded animation (-1 if error)
+/**
+ * Load animation
+ * @param resourceName Animation filename
+ * @param idx Target index in animDataTable (-1 if any empty space will do)
+ * @return The number of the animDataTable entry after the loaded animation (-1 if error)
*/
int loadAni(const char *resourceName, int16 idx) {
int16 foundFileIdx = findFileInBundle(resourceName);
@@ -612,11 +629,12 @@ int loadAni(const char *resourceName, int16 idx) {
return entry;
}
-/*! \brief Decode 16 color image with palette
- * \param[out] dest Decoded image
- * \param[in] source Encoded image
- * \param width Image width
- * \param height Image height
+/**
+ * Decode 16 color image with palette
+ * @param[out] dest Decoded image
+ * @param[in] source Encoded image
+ * @param width Image width
+ * @param height Image height
*/
void convert8BBP(byte *dest, const byte *source, int16 width, int16 height) {
const byte *table = source;
@@ -632,11 +650,12 @@ void convert8BBP(byte *dest, const byte *source, int16 width, int16 height) {
}
}
-/*! \brief Decode 8bit image
- * \param[out] dest Decoded image
- * \param[in] source Encoded image
- * \param width Image width
- * \param height Image height
+/**
+ * Decode 8bit image
+ * @param[out] dest Decoded image
+ * @param[in] source Encoded image
+ * @param width Image width
+ * @param height Image height
* \attention Data in source are destroyed during decoding
*/
void convert8BBP2(byte *dest, byte *source, int16 width, int16 height) {
@@ -663,10 +682,11 @@ void convert8BBP2(byte *dest, byte *source, int16 width, int16 height) {
} // end j
}
-/*! \brief Load image set
- * \param resourceName Image set filename
- * \param idx Target index in animDataTable (-1 if any empty space will do)
- * \return The number of the animDataTable entry after the loaded image set (-1 if error)
+/**
+ * Load image set
+ * @param resourceName Image set filename
+ * @param idx Target index in animDataTable (-1 if any empty space will do)
+ * @return The number of the animDataTable entry after the loaded image set (-1 if error)
*/
int loadSet(const char *resourceName, int16 idx) {
AnimHeader2Struct header2;
@@ -724,10 +744,11 @@ int loadSet(const char *resourceName, int16 idx) {
return entry;
}
-/*! \brief Load SEQ data into animDataTable
- * \param resourceName SEQ data filename
- * \param idx Target index in animDataTable (-1 if any empty space will do)
- * \return The number of the animDataTable entry after the loaded SEQ data (-1 if error)
+/**
+ * Load SEQ data into animDataTable
+ * @param resourceName SEQ data filename
+ * @param idx Target index in animDataTable (-1 if any empty space will do)
+ * @return The number of the animDataTable entry after the loaded SEQ data (-1 if error)
*/
int loadSeq(const char *resourceName, int16 idx) {
int16 foundFileIdx = findFileInBundle(resourceName);
@@ -743,11 +764,12 @@ int loadSeq(const char *resourceName, int16 idx) {
return entry + 1;
}
-/*! \brief Load a resource into animDataTable
- * \param resourceName Resource's filename
- * \param idx Target index in animDataTable (-1 if any empty space will do)
- * \return The number of the animDataTable entry after the loaded resource (-1 if error)
- * \todo Implement loading of all resource types
+/**
+ * Load a resource into animDataTable
+ * @param resourceName Resource's filename
+ * @param idx Target index in animDataTable (-1 if any empty space will do)
+ * @return The number of the animDataTable entry after the loaded resource (-1 if error)
+ * @todo Implement loading of all resource types
*/
int loadResource(const char *resourceName, int16 idx) {
int result = -1; // Return an error by default
diff --git a/engines/cine/bg_list.cpp b/engines/cine/bg_list.cpp
index e7c0993066..26351becf1 100644
--- a/engines/cine/bg_list.cpp
+++ b/engines/cine/bg_list.cpp
@@ -38,8 +38,9 @@ namespace Cine {
uint32 var8;
Common::List<BGIncrust> bgIncrustList;
-/*! \brief Add masked sprite to the background
- * \param objIdx Sprite description
+/**
+ * Add masked sprite to the background
+ * @param objIdx Sprite description
*/
void addToBGList(int16 objIdx) {
renderer->incrustSprite(objectTable[objIdx]);
@@ -47,8 +48,9 @@ void addToBGList(int16 objIdx) {
createBgIncrustListElement(objIdx, 0);
}
-/*! \brief Add filled sprite to the background
- * \param objIdx Sprite description
+/**
+ * Add filled sprite to the background
+ * @param objIdx Sprite description
*/
void addSpriteFilledToBGList(int16 objIdx) {
renderer->incrustMask(objectTable[objIdx]);
@@ -56,9 +58,10 @@ void addSpriteFilledToBGList(int16 objIdx) {
createBgIncrustListElement(objIdx, 1);
}
-/*! \brief Add new element to incrust list
- * \param objIdx Element description
- * \param param Type of element
+/**
+ * Add new element to incrust list
+ * @param objIdx Element description
+ * @param param Type of element
*/
void createBgIncrustListElement(int16 objIdx, int16 param) {
BGIncrust tmp;
@@ -74,14 +77,16 @@ void createBgIncrustListElement(int16 objIdx, int16 param) {
bgIncrustList.push_back(tmp);
}
-/*! \brief Reset var8 (probably something related to bgIncrustList)
+/**
+ * Reset var8 (probably something related to bgIncrustList)
*/
void resetBgIncrustList() {
var8 = 0;
}
-/*! \brief Restore incrust list from savefile
- * \param fHandle Savefile open for reading
+/**
+ * Restore incrust list from savefile
+ * @param fHandle Savefile open for reading
*/
void loadBgIncrustFromSave(Common::SeekableReadStream &fHandle) {
BGIncrust tmp;
diff --git a/engines/cine/cine.cpp b/engines/cine/cine.cpp
index 0b5e3f4057..0d684ba715 100644
--- a/engines/cine/cine.cpp
+++ b/engines/cine/cine.cpp
@@ -103,9 +103,10 @@ int CineEngine::getTimerDelay() const {
return (10923000 * _timerDelayMultiplier) / 1193180;
}
-/*! \brief Modify game speed
- * \param speedChange Negative values slow game down, positive values speed it up, zero does nothing
- * \return Timer delay multiplier's value after the game speed change
+/**
+ * Modify game speed
+ * @param speedChange Negative values slow game down, positive values speed it up, zero does nothing
+ * @return Timer delay multiplier's value after the game speed change
*/
int CineEngine::modifyGameSpeed(int speedChange) {
// If we want more speed we decrement the timer delay multiplier and vice versa.
diff --git a/engines/cine/gfx.cpp b/engines/cine/gfx.cpp
index f55cae1277..9392636b39 100644
--- a/engines/cine/gfx.cpp
+++ b/engines/cine/gfx.cpp
@@ -88,7 +88,8 @@ static const byte cursorPalette[] = {
0xff, 0xff, 0xff, 0xff
};
-/*! \brief Initialize renderer
+/**
+ * Initialize renderer
*/
FWRenderer::FWRenderer() : _background(NULL), _backupPal(), _cmd(""),
_cmdY(0), _messageBg(0), _backBuffer(new byte[_screenSize]),
@@ -100,7 +101,9 @@ FWRenderer::FWRenderer() : _background(NULL), _backupPal(), _cmd(""),
memset(_bgName, 0, sizeof (_bgName));
}
-/* \brief Destroy renderer
+
+/**
+ * Destroy renderer
*/
FWRenderer::~FWRenderer() {
delete[] _background;
@@ -114,7 +117,9 @@ bool FWRenderer::initialize() {
return true;
}
-/* \brief Reset renderer state
+
+/**
+ * Reset renderer state
*/
void FWRenderer::clear() {
delete[] _background;
@@ -132,9 +137,10 @@ void FWRenderer::clear() {
_showCollisionPage = false;
}
-/*! \brief Draw 1bpp sprite using selected color
- * \param obj Object info
- * \param fillColor Sprite color
+/**
+ * Draw 1bpp sprite using selected color
+ * @param obj Object info
+ * @param fillColor Sprite color
*/
void FWRenderer::fillSprite(const ObjectStruct &obj, uint8 color) {
const byte *data = animDataTable[obj.frame].data();
@@ -148,9 +154,10 @@ void FWRenderer::fillSprite(const ObjectStruct &obj, uint8 color) {
gfxFillSprite(data, width, height, _backBuffer, x, y, color);
}
-/*! \brief Draw 1bpp sprite using selected color on background
- * \param obj Object info
- * \param fillColor Sprite color
+/**
+ * Draw 1bpp sprite using selected color on background
+ * @param obj Object info
+ * @param fillColor Sprite color
*/
void FWRenderer::incrustMask(const ObjectStruct &obj, uint8 color) {
const byte *data = animDataTable[obj.frame].data();
@@ -164,9 +171,10 @@ void FWRenderer::incrustMask(const ObjectStruct &obj, uint8 color) {
gfxFillSprite(data, width, height, _background, x, y, color);
}
-/*! \brief Draw color sprite using with external mask
- * \param obj Object info
- * \param mask External mask
+/**
+ * Draw color sprite using with external mask
+ * @param obj Object info
+ * @param mask External mask
*/
void FWRenderer::drawMaskedSprite(const ObjectStruct &obj, const byte *mask) {
const byte *data = animDataTable[obj.frame].data();
@@ -182,16 +190,18 @@ void FWRenderer::drawMaskedSprite(const ObjectStruct &obj, const byte *mask) {
drawSpriteRaw(data, mask, width, height, _backBuffer, x, y);
}
-/*! \brief Draw color sprite
- * \param obj Object info
+/**
+ * Draw color sprite
+ * @param obj Object info
*/
void FWRenderer::drawSprite(const ObjectStruct &obj) {
const byte *mask = animDataTable[obj.frame].mask();
drawMaskedSprite(obj, mask);
}
-/*! \brief Draw color sprite on background
- * \param obj Object info
+/**
+ * Draw color sprite on background
+ * @param obj Object info
*/
void FWRenderer::incrustSprite(const ObjectStruct &obj) {
const byte *data = animDataTable[obj.frame].data();
@@ -214,7 +224,8 @@ void FWRenderer::incrustSprite(const ObjectStruct &obj) {
}
}
-/*! \brief Draw command box on screen
+/**
+ * Draw command box on screen
*/
void FWRenderer::drawCommand() {
unsigned int i;
@@ -231,13 +242,14 @@ void FWRenderer::drawCommand() {
}
}
-/*! \brief Draw message in a box
- * \param str Message to draw
- * \param x Top left message box corner coordinate
- * \param y Top left message box corner coordinate
- * \param width Message box width
- * \param color Message box background color (Or if negative draws only the text)
- * \note Negative colors are used in Operation Stealth's timed cutscenes
+/**
+ * Draw message in a box
+ * @param str Message to draw
+ * @param x Top left message box corner coordinate
+ * @param y Top left message box corner coordinate
+ * @param width Message box width
+ * @param color Message box background color (Or if negative draws only the text)
+ * @note Negative colors are used in Operation Stealth's timed cutscenes
* (e.g. when first meeting The Movement for the Liberation of Santa Paragua).
*/
void FWRenderer::drawMessage(const char *str, int x, int y, int width, int color) {
@@ -303,14 +315,15 @@ void FWRenderer::drawMessage(const char *str, int x, int y, int width, int color
}
}
-/*! \brief Draw rectangle on screen
- * \param x Top left corner coordinate
- * \param y Top left corner coordinate
- * \param width Rectangle width (Negative values draw the box horizontally flipped)
- * \param height Rectangle height (Negative values draw the box vertically flipped)
- * \param color Fill color
- * \note An on-screen rectangle's drawn width is always at least one.
- * \note An on-screen rectangle's drawn height is always at least one.
+/**
+ * Draw rectangle on screen
+ * @param x Top left corner coordinate
+ * @param y Top left corner coordinate
+ * @param width Rectangle width (Negative values draw the box horizontally flipped)
+ * @param height Rectangle height (Negative values draw the box vertically flipped)
+ * @param color Fill color
+ * @note An on-screen rectangle's drawn width is always at least one.
+ * @note An on-screen rectangle's drawn height is always at least one.
*/
void FWRenderer::drawPlainBox(int x, int y, int width, int height, byte color) {
// Make width's and height's absolute values at least one
@@ -378,12 +391,13 @@ void FWRenderer::drawTransparentBox(int x, int y, int width, int height) {
}
}
-/*! \brief Draw empty rectangle
- * \param x Top left corner coordinate
- * \param y Top left corner coordinate
- * \param width Rectangle width
- * \param height Rectangle height
- * \param color Line color
+/**
+ * Draw empty rectangle
+ * @param x Top left corner coordinate
+ * @param y Top left corner coordinate
+ * @param width Rectangle width
+ * @param height Rectangle height
+ * @param color Line color
*/
void FWRenderer::drawBorder(int x, int y, int width, int height, byte color) {
drawLine(x, y, width, 1, color);
@@ -392,22 +406,24 @@ void FWRenderer::drawBorder(int x, int y, int width, int height, byte color) {
drawLine(x + width, y, 1, height + 1, color);
}
-/*! \brief Draw empty 2 color rectangle (inner line color is black)
- * \param x Top left corner coordinate
- * \param y Top left corner coordinate
- * \param width Rectangle width
- * \param height Rectangle height
- * \param color Outter line color
+/**
+ * Draw empty 2 color rectangle (inner line color is black)
+ * @param x Top left corner coordinate
+ * @param y Top left corner coordinate
+ * @param width Rectangle width
+ * @param height Rectangle height
+ * @param color Outter line color
*/
void FWRenderer::drawDoubleBorder(int x, int y, int width, int height, byte color) {
drawBorder(x + 1, y + 1, width - 2, height - 2, 0);
drawBorder(x, y, width, height, color);
}
-/*! \brief Draw text character on screen
- * \param character Character to draw
- * \param x Character coordinate
- * \param y Character coordinate
+/**
+ * Draw text character on screen
+ * @param character Character to draw
+ * @param x Character coordinate
+ * @param y Character coordinate
*/
int FWRenderer::drawChar(char character, int x, int y) {
int width, idx;
@@ -423,22 +439,24 @@ int FWRenderer::drawChar(char character, int x, int y) {
return x;
}
-/*! \brief Draw Line
- * \param x Line end coordinate
- * \param y Line end coordinate
- * \param width Horizontal line length
- * \param height Vertical line length
- * \param color Line color
- * \note Either width or height must be equal to 1
+/**
+ * Draw Line
+ * @param x Line end coordinate
+ * @param y Line end coordinate
+ * @param width Horizontal line length
+ * @param height Vertical line length
+ * @param color Line color
+ * @note Either width or height must be equal to 1
*/
void FWRenderer::drawLine(int x, int y, int width, int height, byte color) {
// this line is a special case of rectangle ;-)
drawPlainBox(x, y, width, height, color);
}
-/*! \brief Hide invisible parts of the sprite
- * \param[in,out] mask Mask to be updated
- * \param it Overlay info from overlayList
+/**
+ * Hide invisible parts of the sprite
+ * @param[in,out] mask Mask to be updated
+ * @param it Overlay info from overlayList
*/
void FWRenderer::remaskSprite(byte *mask, Common::List<overlay>::iterator it) {
AnimData &sprite = animDataTable[objectTable[it->objIdx].frame];
@@ -465,15 +483,17 @@ void FWRenderer::remaskSprite(byte *mask, Common::List<overlay>::iterator it) {
}
}
-/*! \brief Draw background to backbuffer
+/**
+ * Draw background to backbuffer
*/
void FWRenderer::drawBackground() {
assert(_background);
memcpy(_backBuffer, _background, _screenSize);
}
-/*! \brief Draw one overlay
- * \param it Overlay info
+/**
+ * Draw one overlay
+ * @param it Overlay info
*/
void FWRenderer::renderOverlay(const Common::List<overlay>::iterator &it) {
int idx, len, width;
@@ -537,7 +557,8 @@ void FWRenderer::renderOverlay(const Common::List<overlay>::iterator &it) {
}
}
-/*! \brief Draw overlays
+/**
+ * Draw overlays
*/
void FWRenderer::drawOverlays() {
Common::List<overlay>::iterator it;
@@ -547,7 +568,8 @@ void FWRenderer::drawOverlays() {
}
}
-/*! \brief Draw another frame
+/**
+ * Draw another frame
*/
void FWRenderer::drawFrame() {
drawBackground();
@@ -568,16 +590,17 @@ void FWRenderer::drawFrame() {
blit();
}
-/*!
- * \brief Turn on or off the showing of the collision page.
+/**
+ * Turn on or off the showing of the collision page.
* If turned on the blitting routine shows the collision page instead of the back buffer.
- * \note Useful for debugging collision page related problems.
+ * @note Useful for debugging collision page related problems.
*/
void FWRenderer::showCollisionPage(bool state) {
_showCollisionPage = state;
}
-/*! \brief Update screen
+/**
+ * Update screen
*/
void FWRenderer::blit() {
// Show the back buffer or the collision page. Normally the back
@@ -586,14 +609,16 @@ void FWRenderer::blit() {
g_system->copyRectToScreen(source, 320, 0, 0, 320, 200);
}
-/*! \brief Set player command string
- * \param cmd New command string
+/**
+ * Set player command string
+ * @param cmd New command string
*/
void FWRenderer::setCommand(Common::String cmd) {
_cmd = cmd;
}
-/*! \brief Refresh current palette
+/**
+ * Refresh current palette
*/
void FWRenderer::refreshPalette() {
assert(_activePal.isValid() && !_activePal.empty());
@@ -601,7 +626,8 @@ void FWRenderer::refreshPalette() {
_changePal = 0;
}
-/*! \brief Load palette of current background
+/**
+ * Load palette of current background
*/
void FWRenderer::reloadPalette() {
assert(_backupPal.isValid() && !_backupPal.empty());
@@ -609,9 +635,10 @@ void FWRenderer::reloadPalette() {
_changePal = 1;
}
-/*! \brief Load background into renderer
- * \param bg Raw background data
- * \todo Combine with OSRenderer's version of loadBg16
+/**
+ * Load background into renderer
+ * @param bg Raw background data
+ * @todo Combine with OSRenderer's version of loadBg16
*/
void FWRenderer::loadBg16(const byte *bg, const char *name, unsigned int idx) {
assert(idx == 0);
@@ -633,49 +660,57 @@ void FWRenderer::loadBg16(const byte *bg, const char *name, unsigned int idx) {
gfxConvertSpriteToRaw(_background, bg, 160, 200);
}
-/*! \brief Placeholder for Operation Stealth implementation
+/**
+ * Placeholder for Operation Stealth implementation
*/
void FWRenderer::loadCt16(const byte *ct, const char *name) {
error("Future Wars renderer doesn't support multiple backgrounds");
}
-/*! \brief Placeholder for Operation Stealth implementation
+/**
+ * Placeholder for Operation Stealth implementation
*/
void FWRenderer::loadBg256(const byte *bg, const char *name, unsigned int idx) {
error("Future Wars renderer doesn't support multiple backgrounds");
}
-/*! \brief Placeholder for Operation Stealth implementation
+/**
+ * Placeholder for Operation Stealth implementation
*/
void FWRenderer::loadCt256(const byte *ct, const char *name) {
error("Future Wars renderer doesn't support multiple backgrounds");
}
-/*! \brief Placeholder for Operation Stealth implementation
+/**
+ * Placeholder for Operation Stealth implementation
*/
void FWRenderer::selectBg(unsigned int idx) {
error("Future Wars renderer doesn't support multiple backgrounds");
}
-/*! \brief Placeholder for Operation Stealth implementation
+/**
+ * Placeholder for Operation Stealth implementation
*/
void FWRenderer::selectScrollBg(unsigned int idx) {
error("Future Wars renderer doesn't support multiple backgrounds");
}
-/*! \brief Placeholder for Operation Stealth implementation
+/**
+ * Placeholder for Operation Stealth implementation
*/
void FWRenderer::setScroll(unsigned int shift) {
error("Future Wars renderer doesn't support multiple backgrounds");
}
-/*! \brief Future Wars has no scrolling backgrounds so scroll value is always zero.
+/**
+ * Future Wars has no scrolling backgrounds so scroll value is always zero.
*/
uint FWRenderer::getScroll() const {
return 0;
}
-/*! \brief Placeholder for Operation Stealth implementation
+/**
+ * Placeholder for Operation Stealth implementation
*/
void FWRenderer::removeBg(unsigned int idx) {
error("Future Wars renderer doesn't support multiple backgrounds");
@@ -690,8 +725,9 @@ const char *FWRenderer::getBgName(uint idx) const {
return _bgName;
}
-/*! \brief Restore active and backup palette from save
- * \param fHandle Savefile open for reading
+/**
+ * Restore active and backup palette from save
+ * @param fHandle Savefile open for reading
*/
void FWRenderer::restorePalette(Common::SeekableReadStream &fHandle) {
byte buf[kLowPalNumBytes];
@@ -707,8 +743,9 @@ void FWRenderer::restorePalette(Common::SeekableReadStream &fHandle) {
_changePal = 1;
}
-/*! \brief Write active and backup palette to save
- * \param fHandle Savefile open for writing
+/**
+ * Write active and backup palette to save
+ * @param fHandle Savefile open for writing
*/
void FWRenderer::savePalette(Common::OutSaveFile &fHandle) {
byte buf[kLowPalNumBytes];
@@ -730,9 +767,10 @@ void FWRenderer::savePalette(Common::OutSaveFile &fHandle) {
fHandle.write(buf, kLowPalNumBytes);
}
-/*! \brief Write active and backup palette to save
- * \param fHandle Savefile open for writing
- * \todo Add support for saving the palette in the 16 color version of Operation Stealth.
+/**
+ * Write active and backup palette to save
+ * @param fHandle Savefile open for writing
+ * @todo Add support for saving the palette in the 16 color version of Operation Stealth.
* Possibly combine with FWRenderer's savePalette-method?
*/
void OSRenderer::savePalette(Common::OutSaveFile &fHandle) {
@@ -751,8 +789,9 @@ void OSRenderer::savePalette(Common::OutSaveFile &fHandle) {
fHandle.write(buf, kHighPalNumBytes);
}
-/*! \brief Restore active and backup palette from save
- * \param fHandle Savefile open for reading
+/**
+ * Restore active and backup palette from save
+ * @param fHandle Savefile open for reading
*/
void OSRenderer::restorePalette(Common::SeekableReadStream &fHandle) {
byte buf[kHighPalNumBytes];
@@ -768,22 +807,24 @@ void OSRenderer::restorePalette(Common::SeekableReadStream &fHandle) {
_changePal = 1;
}
-/*! \brief Rotate active palette
- * \param a First color to rotate
- * \param b Last color to rotate
- * \param c Possibly rotation step, must be 0 or 1 at the moment
+/**
+ * Rotate active palette
+ * @param a First color to rotate
+ * @param b Last color to rotate
+ * @param c Possibly rotation step, must be 0 or 1 at the moment
*/
void FWRenderer::rotatePalette(int a, int b, int c) {
_activePal.rotateRight(a, b, c);
refreshPalette();
}
-/*! \brief Copy part of backup palette to active palette and transform
- * \param first First color to transform
- * \param last Last color to transform
- * \param r Red channel transformation
- * \param g Green channel transformation
- * \param b Blue channel transformation
+/**
+ * Copy part of backup palette to active palette and transform
+ * @param first First color to transform
+ * @param last Last color to transform
+ * @param r Red channel transformation
+ * @param g Green channel transformation
+ * @param b Blue channel transformation
*/
void FWRenderer::transformPalette(int first, int last, int r, int g, int b) {
if (!_activePal.isValid() || _activePal.empty()) {
@@ -794,7 +835,8 @@ void FWRenderer::transformPalette(int first, int last, int r, int g, int b) {
refreshPalette();
}
-/*! \brief Fade to black
+/**
+ * Fade to black
* \bug Operation Stealth sometimes seems to fade to black using
* transformPalette resulting in double fadeout
*/
@@ -988,7 +1030,8 @@ void TextInputMenu::drawMenu(FWRenderer &r, bool top) {
// -------------------
-/*! \brief Initialize Operation Stealth renderer
+/**
+ * Initialize Operation Stealth renderer
*/
OSRenderer::OSRenderer() : FWRenderer(), _bgTable(), _currentBg(0), _scrollBg(0),
_bgShift(0) {
@@ -996,7 +1039,8 @@ OSRenderer::OSRenderer() : FWRenderer(), _bgTable(), _currentBg(0), _scrollBg(0)
_bgTable.resize(9); // Resize the background table to its required size
}
-/*! \brief Destroy Operation Stealth renderer
+/**
+ * Destroy Operation Stealth renderer
*/
OSRenderer::~OSRenderer() {
for (uint i = 0; i < _bgTable.size(); i++) {
@@ -1009,7 +1053,8 @@ bool OSRenderer::initialize() {
return true;
}
-/*! \brief Reset Operation Stealth renderer state
+/**
+ * Reset Operation Stealth renderer state
*/
void OSRenderer::clear() {
for (uint i = 0; i < _bgTable.size(); i++) {
@@ -1023,9 +1068,10 @@ void OSRenderer::clear() {
FWRenderer::clear();
}
-/*! \brief Draw 1bpp sprite using selected color on backgrounds
- * \param obj Object info
- * \param fillColor Sprite color
+/**
+ * Draw 1bpp sprite using selected color on backgrounds
+ * @param obj Object info
+ * @param fillColor Sprite color
*/
void OSRenderer::incrustMask(const ObjectStruct &obj, uint8 color) {
const byte *data = animDataTable[obj.frame].data();
@@ -1041,8 +1087,9 @@ void OSRenderer::incrustMask(const ObjectStruct &obj, uint8 color) {
}
}
-/*! \brief Draw color sprite
- * \param obj Object info
+/**
+ * Draw color sprite
+ * @param obj Object info
*/
void OSRenderer::drawSprite(const ObjectStruct &obj) {
const byte *data = animDataTable[obj.frame].data();
@@ -1057,8 +1104,9 @@ void OSRenderer::drawSprite(const ObjectStruct &obj) {
drawSpriteRaw2(data, transColor, width, height, _backBuffer, x, y);
}
-/*! \brief Draw color sprite
- * \param obj Object info
+/**
+ * Draw color sprite
+ * @param obj Object info
*/
void OSRenderer::incrustSprite(const ObjectStruct &obj) {
const byte *data = animDataTable[obj.frame].data();
@@ -1075,10 +1123,11 @@ void OSRenderer::incrustSprite(const ObjectStruct &obj) {
}
}
-/*! \brief Draw text character on screen
- * \param character Character to draw
- * \param x Character coordinate
- * \param y Character coordinate
+/**
+ * Draw text character on screen
+ * @param character Character to draw
+ * @param x Character coordinate
+ * @param y Character coordinate
*/
int OSRenderer::drawChar(char character, int x, int y) {
int width, idx;
@@ -1094,7 +1143,8 @@ int OSRenderer::drawChar(char character, int x, int y) {
return x;
}
-/*! \brief Draw background to backbuffer
+/**
+ * Draw background to backbuffer
*/
void OSRenderer::drawBackground() {
byte *main;
@@ -1120,9 +1170,10 @@ void OSRenderer::drawBackground() {
}
}
-/*! \brief Draw one overlay
- * \param it Overlay info
- * \todo Add handling of type 22 overlays
+/**
+ * Draw one overlay
+ * @param it Overlay info
+ * @todo Add handling of type 22 overlays
*/
void OSRenderer::renderOverlay(const Common::List<overlay>::iterator &it) {
int len, idx, width, height;
@@ -1220,7 +1271,8 @@ void OSRenderer::renderOverlay(const Common::List<overlay>::iterator &it) {
}
}
-/*! \brief Load palette of current background
+/**
+ * Load palette of current background
*/
void OSRenderer::reloadPalette() {
// selected background in plane takeoff scene has swapped colors 12
@@ -1233,12 +1285,13 @@ void OSRenderer::reloadPalette() {
_changePal = 1;
}
-/*! \brief Copy part of backup palette to active palette and transform
- * \param first First color to transform
- * \param last Last color to transform
- * \param r Red channel transformation
- * \param g Green channel transformation
- * \param b Blue channel transformation
+/**
+ * Copy part of backup palette to active palette and transform
+ * @param first First color to transform
+ * @param last Last color to transform
+ * @param r Red channel transformation
+ * @param g Green channel transformation
+ * @param b Blue channel transformation
*/
void OSRenderer::transformPalette(int first, int last, int r, int g, int b) {
palBg *bg = _bgShift ? &_bgTable[_scrollBg] : &_bgTable[_currentBg];
@@ -1252,11 +1305,12 @@ void OSRenderer::transformPalette(int first, int last, int r, int g, int b) {
refreshPalette();
}
-/*! \brief Load 16 color background into renderer
- * \param bg Raw background data
- * \param name Background filename
- * \param pos Background index
- * \todo Combine with FWRenderer's version of loadBg16
+/**
+ * Load 16 color background into renderer
+ * @param bg Raw background data
+ * @param name Background filename
+ * @param pos Background index
+ * @todo Combine with FWRenderer's version of loadBg16
*/
void OSRenderer::loadBg16(const byte *bg, const char *name, unsigned int idx) {
assert(idx < 9);
@@ -1278,9 +1332,10 @@ void OSRenderer::loadBg16(const byte *bg, const char *name, unsigned int idx) {
gfxConvertSpriteToRaw(_bgTable[idx].bg, bg, 160, 200);
}
-/*! \brief Load 16 color CT data as background into renderer
- * \param ct Raw CT data
- * \param name Background filename
+/**
+ * Load 16 color CT data as background into renderer
+ * @param ct Raw CT data
+ * @param name Background filename
*/
void OSRenderer::loadCt16(const byte *ct, const char *name) {
// Make the 9th background point directly to the collision page
@@ -1289,10 +1344,11 @@ void OSRenderer::loadCt16(const byte *ct, const char *name) {
loadBg16(ct, name, kCollisionPageBgIdxAlias);
}
-/*! \brief Load 256 color background into renderer
- * \param bg Raw background data
- * \param name Background filename
- * \param pos Background index
+/**
+ * Load 256 color background into renderer
+ * @param bg Raw background data
+ * @param name Background filename
+ * @param pos Background index
*/
void OSRenderer::loadBg256(const byte *bg, const char *name, unsigned int idx) {
assert(idx < 9);
@@ -1308,9 +1364,10 @@ void OSRenderer::loadBg256(const byte *bg, const char *name, unsigned int idx) {
memcpy(_bgTable[idx].bg, bg + kHighPalNumBytes, _screenSize);
}
-/*! \brief Load 256 color CT data as background into renderer
- * \param ct Raw CT data
- * \param name Background filename
+/**
+ * Load 256 color CT data as background into renderer
+ * @param ct Raw CT data
+ * @param name Background filename
*/
void OSRenderer::loadCt256(const byte *ct, const char *name) {
// Make the 9th background point directly to the collision page
@@ -1319,8 +1376,9 @@ void OSRenderer::loadCt256(const byte *ct, const char *name) {
loadBg256(ct, name, kCollisionPageBgIdxAlias);
}
-/*! \brief Select active background and load its palette
- * \param idx Background index
+/**
+ * Select active background and load its palette
+ * @param idx Background index
*/
void OSRenderer::selectBg(unsigned int idx) {
assert(idx < 9 && _bgTable[idx].bg);
@@ -1330,8 +1388,9 @@ void OSRenderer::selectBg(unsigned int idx) {
reloadPalette();
}
-/*! \brief Select scroll background
- * \param idx Scroll background index
+/**
+ * Select scroll background
+ * @param idx Scroll background index
*/
void OSRenderer::selectScrollBg(unsigned int idx) {
assert(idx < 9);
@@ -1342,8 +1401,9 @@ void OSRenderer::selectScrollBg(unsigned int idx) {
reloadPalette();
}
-/*! \brief Set background scroll
- * \param shift Background scroll in pixels
+/**
+ * Set background scroll
+ * @param shift Background scroll in pixels
*/
void OSRenderer::setScroll(unsigned int shift) {
assert(shift <= 200);
@@ -1351,15 +1411,17 @@ void OSRenderer::setScroll(unsigned int shift) {
_bgShift = shift;
}
-/*! \brief Get background scroll
- * \return Background scroll in pixels
+/**
+ * Get background scroll
+ * @return Background scroll in pixels
*/
uint OSRenderer::getScroll() const {
return _bgShift;
}
-/*! \brief Unload background from renderer
- * \param idx Background to unload
+/**
+ * Unload background from renderer
+ * @param idx Background to unload
*/
void OSRenderer::removeBg(unsigned int idx) {
assert(idx > 0 && idx < 9);
diff --git a/engines/cine/gfx.h b/engines/cine/gfx.h
index 64e9730720..beb347a746 100644
--- a/engines/cine/gfx.h
+++ b/engines/cine/gfx.h
@@ -36,7 +36,8 @@ namespace Cine {
extern byte *collisionPage;
static const int kCollisionPageBgIdxAlias = 8;
-/*! \brief Background with palette
+/**
+ * Background with palette
*/
struct palBg {
byte *bg; ///< Background data
@@ -115,7 +116,8 @@ private:
int _cursor;
};
-/*! \brief Future Wars renderer
+/**
+ * Future Wars renderer
*
* Screen backbuffer is not cleared between frames.
*/
@@ -169,7 +171,7 @@ public:
virtual bool initialize();
- /*! \brief Test if renderer is ready to draw */
+ /** Test if renderer is ready to draw */
virtual bool ready() { return _background != NULL; }
virtual void clear();
@@ -207,7 +209,8 @@ public:
void showCollisionPage(bool state);
};
-/*! \brief Operation Stealth renderer
+/**
+ * Operation Stealth renderer
*/
class OSRenderer : public FWRenderer {
private:
@@ -229,7 +232,7 @@ public:
bool initialize();
- /*! \brief Test if renderer is ready to draw */
+ /** Test if renderer is ready to draw */
bool ready() { return _bgTable[_currentBg].bg != NULL; }
void clear();
diff --git a/engines/cine/object.cpp b/engines/cine/object.cpp
index 7fde7ee1e6..116b57c267 100644
--- a/engines/cine/object.cpp
+++ b/engines/cine/object.cpp
@@ -38,7 +38,7 @@ namespace Cine {
Common::Array<ObjectStruct> objectTable;
Common::List<overlay> overlayList;
-/*! \brief Resets all elements in the object table. */
+/** Resets all elements in the object table. */
void resetObjectTable() {
for (Common::Array<ObjectStruct>::iterator it = objectTable.begin(); it != objectTable.end(); ++it) {
it->clear();
@@ -87,9 +87,10 @@ void loadObject(char *pObjectName) {
free(dataPtr);
}
-/*! \brief Remove overlay sprite from the list
- * \param objIdx Remove overlay associated with this object
- * \param param Remove overlay of this type
+/**
+ * Remove overlay sprite from the list
+ * @param objIdx Remove overlay associated with this object
+ * @param param Remove overlay of this type
*/
int removeOverlay(uint16 objIdx, uint16 param) {
Common::List<overlay>::iterator it;
@@ -104,10 +105,11 @@ int removeOverlay(uint16 objIdx, uint16 param) {
return 0;
}
-/*! \brief Add new overlay sprite to the list
- * \param objIdx Associate the overlay with this object
- * \param type Type of new overlay
- * \todo Why are x, y, width and color left uninitialized?
+/**
+ * Add new overlay sprite to the list
+ * @param objIdx Associate the overlay with this object
+ * @param type Type of new overlay
+ * @todo Why are x, y, width and color left uninitialized?
*/
void addOverlay(uint16 objIdx, uint16 type) {
Common::List<overlay>::iterator it;
@@ -140,9 +142,10 @@ void addOverlay(uint16 objIdx, uint16 type) {
overlayList.insert(it, tmp);
}
-/*! \brief Add new background mask overlay
- * \param objIdx Associate the overlay with this object
- * \param param source background index
+/**
+ * Add new background mask overlay
+ * @param objIdx Associate the overlay with this object
+ * @param param source background index
*/
void addGfxElement(int16 objIdx, int16 param, int16 type) {
Common::List<overlay>::iterator it;
@@ -168,10 +171,11 @@ void addGfxElement(int16 objIdx, int16 param, int16 type) {
overlayList.insert(it, tmp);
}
-/*! \brief Remove background mask overlay
- * \param objIdx Remove overlay associated with this object
- * \param param Remove overlay using this background
- * \todo Check that it works
+/**
+ * Remove background mask overlay
+ * @param objIdx Remove overlay associated with this object
+ * @param param Remove overlay using this background
+ * @todo Check that it works
*/
void removeGfxElement(int16 objIdx, int16 param, int16 type) {
Common::List<overlay>::iterator it;
@@ -286,7 +290,8 @@ uint16 compareObjectParam(byte objIdx, byte type, int16 value) {
return compareResult;
}
-/*! \bug In Operation Stealth, if you try to go downstairs to the sea in the
+/**
+ * @bug In Operation Stealth, if you try to go downstairs to the sea in the
* location between bank and hotel, getObjectParam is called with paramIdx 16
* and crashes
*/
diff --git a/engines/cine/object.h b/engines/cine/object.h
index e7c5144441..daf515bf0f 100644
--- a/engines/cine/object.h
+++ b/engines/cine/object.h
@@ -39,7 +39,7 @@ struct ObjectStruct {
char name[20];
uint16 part;
- /*! \brief Sets all member variables to zero. */
+ /** Sets all member variables to zero. */
void clear() {
this->x = 0;
this->y = 0;
diff --git a/engines/cine/pal.cpp b/engines/cine/pal.cpp
index 460c3431d3..6da121a0f2 100644
--- a/engines/cine/pal.cpp
+++ b/engines/cine/pal.cpp
@@ -104,7 +104,7 @@ void loadRelatedPalette(const char *fileName) {
}
namespace {
-/*! \brief Is given endian type big endian? (Handles native endian type too, otherwise this would be trivial). */
+/** Is given endian type big endian? (Handles native endian type too, otherwise this would be trivial). */
bool isBigEndian(const EndianType endian) {
assert(endian == CINE_NATIVE_ENDIAN || endian == CINE_LITTLE_ENDIAN || endian == CINE_BIG_ENDIAN);
@@ -123,7 +123,7 @@ bool isBigEndian(const EndianType endian) {
#endif
}
-/*! \brief Calculate byte position of given bit position in a multibyte variable using defined endianness. */
+/** Calculate byte position of given bit position in a multibyte variable using defined endianness. */
int bytePos(const int bitPos, const int numBytes, const bool bigEndian) {
if (bigEndian)
return (numBytes - 1) - (bitPos / 8);
@@ -131,7 +131,7 @@ int bytePos(const int bitPos, const int numBytes, const bool bigEndian) {
return bitPos / 8;
}
-/*! \brief Calculate the value of "base" to the power of "power". */
+/** Calculate the value of "base" to the power of "power". */
int power(int base, int power) {
int result = 1;
while (power--)
diff --git a/engines/cine/pal.h b/engines/cine/pal.h
index bbfaf54ab2..e5bb8db78f 100644
--- a/engines/cine/pal.h
+++ b/engines/cine/pal.h
@@ -35,7 +35,7 @@ namespace Cine {
#define kLowPalNumColors 16
#define kLowPalNumBytes ((kLowPalNumColors) * (kLowPalBytesPerColor))
-/*! \brief Low resolution (9-bit) color format used in Cine's 16-color modes. */
+/** Low resolution (9-bit) color format used in Cine's 16-color modes. */
static const Graphics::PixelFormat kLowPalFormat(kLowPalBytesPerColor, 3, 3, 3, 0, 8, 4, 0, 0);
@@ -44,13 +44,14 @@ static const Graphics::PixelFormat kLowPalFormat(kLowPalBytesPerColor, 3, 3, 3,
#define kHighPalNumColors 256
#define kHighPalNumBytes ((kHighPalNumColors) * (kHighPalBytesPerColor))
-/*! \brief High resolution (24-bit) color format used in Cine's 256-color modes. */
+/** High resolution (24-bit) color format used in Cine's 256-color modes. */
static const Graphics::PixelFormat kHighPalFormat(kHighPalBytesPerColor, 8, 8, 8, 0, 0, 8, 16, 0);
-/*! \brief The color format used by OSystem's setPalette-function. */
+/** The color format used by OSystem's setPalette-function. */
static const Graphics::PixelFormat kSystemPalFormat(4, 8, 8, 8, 0, 0, 8, 16, 0);
-/*! \brief Endian types. Used at least by Palette class's load and save functions.
+/**
+ * Endian types. Used at least by Palette class's load and save functions.
* TODO: Move somewhere more general as this is definitely not Cine-engine specific
*
* NOTE: It seems LITTLE_ENDIAN and/or BIG_ENDIAN were defined already on some platforms so
@@ -74,86 +75,97 @@ void loadPal(const char *fileName);
void loadRelatedPalette(const char *fileName);
-// A class for handling Cine-engine's palettes.
-// TODO: Test a bit more
+/**
+ * A class for handling Cine-engine's palettes.
+ * TODO: Test a bit more
+ */
class Palette {
public:
struct Color {
uint8 r, g, b;
};
- /*! \brief Create an initially black palette with the given color format and number of colors.
- * \param format Color format
- * \param numColors Number of colors
- * \note For the default constructed object (i.e. no parameters given) this will hold: empty() && !isValid()
+ /**
+ * Create an initially black palette with the given color format and number of colors.
+ * @param format Color format
+ * @param numColors Number of colors
+ * @note For the default constructed object (i.e. no parameters given) this will hold: empty() && !isValid()
*/
Palette(const Graphics::PixelFormat format = Graphics::PixelFormat(), const uint numColors = 0);
- /*! \brief Clear the palette (Set color count to zero, release memory, overwrite color format with default value).
- * \note This is very different from using fillWithBlack-function which fills the palette with black.
+ /**
+ * Clear the palette (Set color count to zero, release memory, overwrite color format with default value).
+ * @note This is very different from using fillWithBlack-function which fills the palette with black.
*/
Palette &clear();
- /*! \brief Load palette from buffer with given color format, endianness and number of colors.
- * \param buf Input buffer
- * \param size Input buffer size in bytes
- * \param format Input color format
- * \param numColors Number of colors to load
- * \param endian The endianness of the colors in the input buffer
+ /**
+ * Load palette from buffer with given color format, endianness and number of colors.
+ * @param buf Input buffer
+ * @param size Input buffer size in bytes
+ * @param format Input color format
+ * @param numColors Number of colors to load
+ * @param endian The endianness of the colors in the input buffer
*/
Palette &load(const byte *buf, const uint size, const Graphics::PixelFormat format, const uint numColors, const EndianType endian);
- /*! \brief Save the whole palette to buffer in original color format using defined endianness.
- * \param buf Output buffer
- * \param size Output buffer size in bytes
- * \param endian The endian type to use
+ /**
+ * Save the whole palette to buffer in original color format using defined endianness.
+ * @param buf Output buffer
+ * @param size Output buffer size in bytes
+ * @param endian The endian type to use
*/
byte *save(byte *buf, const uint size, const EndianType endian) const;
- /*! \brief Save the whole palette to buffer in given color format using defined endianness.
- * \param buf Output buffer
- * \param size Output buffer size in bytes
- * \param format Output color format
- * \param endian The endian type to use
+ /**
+ * Save the whole palette to buffer in given color format using defined endianness.
+ * @param buf Output buffer
+ * @param size Output buffer size in bytes
+ * @param format Output color format
+ * @param endian The endian type to use
*/
byte *save(byte *buf, const uint size, const Graphics::PixelFormat format, const EndianType endian) const;
- /*! \brief Save (partial) palette to buffer in given color format using defined endianness.
- * \param buf Output buffer
- * \param size Output buffer size in bytes
- * \param format Output color format
- * \param numColors Number of colors to save
- * \param endian The endian type to use
- * \param firstIndex Starting color index (from which onwards to save the colors)
+ /**
+ * Save (partial) palette to buffer in given color format using defined endianness.
+ * @param buf Output buffer
+ * @param size Output buffer size in bytes
+ * @param format Output color format
+ * @param numColors Number of colors to save
+ * @param endian The endian type to use
+ * @param firstIndex Starting color index (from which onwards to save the colors)
*/
byte *save(byte *buf, const uint size, const Graphics::PixelFormat format, const uint numColors, const EndianType endian, const byte firstIndex = 0) const;
- /*! \brief Rotate the palette in color range [firstIndex, lastIndex] to the right by the specified rotation amount.
- * \param rotationAmount Amount to rotate the sub-palette to the right. Only values 0 and 1 are currently supported!
+ /**
+ * Rotate the palette in color range [firstIndex, lastIndex] to the right by the specified rotation amount.
+ * @param rotationAmount Amount to rotate the sub-palette to the right. Only values 0 and 1 are currently supported!
*/
Palette &rotateRight(byte firstIndex, byte lastIndex, signed rotationAmount = 1);
Palette &saturatedAddColor(Palette &output, byte firstIndex, byte lastIndex, signed r, signed g, signed b) const;
- /*! \brief Saturated add an RGB color in given color format to current palette's subset and save the modified colors in the given output palette.
- * \param output The output palette (Only this palette is modified)
- * \param firstIndex First color index of the palette's subset (Inclusive range)
- * \param lastIndex Last color index of the palette's subset (Inclusive range)
- * \param rSource The red color component in the source color format
- * \param gSource The green color component in the source color format
- * \param bSource The blue color component in the source color format
- * \param sourceFormat The source color format (i.e. the color format of the given RGB color)
- * \note This function basically converts the given color to the palette's internal color format
+ /**
+ * Saturated add an RGB color in given color format to current palette's subset and save the modified colors in the given output palette.
+ * @param output The output palette (Only this palette is modified)
+ * @param firstIndex First color index of the palette's subset (Inclusive range)
+ * @param lastIndex Last color index of the palette's subset (Inclusive range)
+ * @param rSource The red color component in the source color format
+ * @param gSource The green color component in the source color format
+ * @param bSource The blue color component in the source color format
+ * @param sourceFormat The source color format (i.e. the color format of the given RGB color)
+ * @note This function basically converts the given color to the palette's internal color format
* and adds that using the normal saturatedAddColor-function.
*/
Palette &saturatedAddColor(Palette &output, byte firstIndex, byte lastIndex, signed rSource, signed gSource, signed bSource, const Graphics::PixelFormat &sourceFormat) const;
- /*! \brief Saturated add a normalized gray value to current palette's subset and save the modified colors in the given output palette.
- * \param output The output palette (Only this palette is modified)
- * \param firstIndex First color index of the palette's subset (Inclusive range)
- * \param lastIndex Last color index of the palette's subset (Inclusive range)
- * \param grayDividend Dividend of the normalized gray value
- * \param grayDenominator Denominator of the normalized gray value
- * \note The normalized gray value (i.e. in range [-1, +1]) is given as a fractional number
+ /**
+ * Saturated add a normalized gray value to current palette's subset and save the modified colors in the given output palette.
+ * @param output The output palette (Only this palette is modified)
+ * @param firstIndex First color index of the palette's subset (Inclusive range)
+ * @param lastIndex Last color index of the palette's subset (Inclusive range)
+ * @param grayDividend Dividend of the normalized gray value
+ * @param grayDenominator Denominator of the normalized gray value
+ * @note The normalized gray value (i.e. in range [-1, +1]) is given as a fractional number
* (i.e. the normalized gray value is calculated by dividing grayDividend by grayDenominator).
*/
Palette &saturatedAddNormalizedGray(Palette &output, byte firstIndex, byte lastIndex, signed grayDividend, signed grayDenominator) const;
@@ -163,25 +175,25 @@ public:
Palette &fillWithBlack();
- /*! \brief Is the palette valid? (Mostly just checks the color format for correctness) */
+ /** Is the palette valid? (Mostly just checks the color format for correctness) */
bool isValid() const;
- /*! \brief The original color format in which this palette was loaded. */
+ /** The original color format in which this palette was loaded. */
const Graphics::PixelFormat &colorFormat() const;
- /*! \brief Sets current palette to global OSystem's palette using g_system->setPalette. */
+ /** Sets current palette to global OSystem's palette using g_system->setPalette. */
void setGlobalOSystemPalette() const;
- /*! \brief Get the color at the given palette index. */
+ /** Get the color at the given palette index. */
Color getColor(byte index) const;
- /*! \brief Get the red color component of the color at the given palette index. */
+ /** Get the red color component of the color at the given palette index. */
uint8 getR(byte index) const;
- /*! \brief Get the green color component of the color at the given palette index. */
+ /** Get the green color component of the color at the given palette index. */
uint8 getG(byte index) const;
- /*! \brief Get the blue color component of the color at the given palette index. */
+ /** Get the blue color component of the color at the given palette index. */
uint8 getB(byte index) const;
private:
diff --git a/engines/cine/part.cpp b/engines/cine/part.cpp
index f47433e709..ad5aaf54b0 100644
--- a/engines/cine/part.cpp
+++ b/engines/cine/part.cpp
@@ -264,7 +264,7 @@ byte *readBundleSoundFile(const char *entryName, uint32 *size) {
return data;
}
-/*! \brief Rotate byte value to the left by n bits */
+/** Rotate byte value to the left by n bits */
byte rolByte(byte value, uint n) {
n %= 8;
return (byte) ((value << n) | (value >> (8 - n)));
diff --git a/engines/cine/prc.cpp b/engines/cine/prc.cpp
index 487b8b60a4..e1ef14bbbf 100644
--- a/engines/cine/prc.cpp
+++ b/engines/cine/prc.cpp
@@ -40,8 +40,9 @@ ScriptList objectScripts;
//char currentPrcName[20];
-/*! \todo Is script size of 0 valid?
- * \todo Fix script dump code
+/**
+ * @todo Is script size of 0 valid?
+ * @todo Fix script dump code
* @return Was the loading successful?
*/
bool loadPrc(const char *pPrcName) {
diff --git a/engines/cine/rel.cpp b/engines/cine/rel.cpp
index dd2d0f68b6..17ab14bfe5 100644
--- a/engines/cine/rel.cpp
+++ b/engines/cine/rel.cpp
@@ -33,8 +33,9 @@ namespace Cine {
RawObjectScriptArray relTable; ///< Object script bytecode table
-/*! \todo Is script size of 0 valid?
- * \todo Fix script dump code
+/**
+ * @todo Is script size of 0 valid?
+ * @todo Fix script dump code
*/
void loadRel(char *pRelName) {
uint16 numEntry;
diff --git a/engines/cine/saveload.cpp b/engines/cine/saveload.cpp
index 57908b25a2..2bb9f634f5 100644
--- a/engines/cine/saveload.cpp
+++ b/engines/cine/saveload.cpp
@@ -52,9 +52,10 @@ bool loadChunkHeader(Common::SeekableReadStream &in, ChunkHeader &header) {
return !(in.eos() || in.err());
}
-/*! \brief Savegame format detector
- * \param fHandle Savefile to check
- * \return Savegame format on success, ANIMSIZE_UNKNOWN on failure
+/**
+ * Savegame format detector
+ * @param fHandle Savefile to check
+ * @return Savegame format on success, ANIMSIZE_UNKNOWN on failure
*
* This function seeks through the savefile and tries to determine the
* savegame format it uses. There's a miniscule chance that the detection
@@ -174,9 +175,10 @@ enum CineSaveGameFormat detectSaveGameFormat(Common::SeekableReadStream &fHandle
return result;
}
-/*! \brief Restore script list item from savefile
- * \param fHandle Savefile handle open for reading
- * \param isGlobal Restore object or global script?
+/**
+ * Restore script list item from savefile
+ * @param fHandle Savefile handle open for reading
+ * @param isGlobal Restore object or global script?
*/
void loadScriptFromSave(Common::SeekableReadStream &fHandle, bool isGlobal) {
ScriptVars localVars, labels;
@@ -208,8 +210,9 @@ void loadScriptFromSave(Common::SeekableReadStream &fHandle, bool isGlobal) {
}
}
-/*! \brief Restore overlay sprites from savefile
- * \param fHandle Savefile open for reading
+/**
+ * Restore overlay sprites from savefile
+ * @param fHandle Savefile open for reading
*/
void loadOverlayFromSave(Common::SeekableReadStream &fHandle) {
overlay tmp;
@@ -349,7 +352,7 @@ void saveCommandVariables(Common::OutSaveFile &out) {
}
}
-/*! \brief Save the 80 bytes long command buffer padded to that length with zeroes. */
+/** Save the 80 bytes long command buffer padded to that length with zeroes. */
void saveCommandBuffer(Common::OutSaveFile &out) {
// Let's make sure there's space for the trailing zero
// (That's why we subtract one from the maximum command buffer size here).
@@ -983,10 +986,11 @@ void CineEngine::makeSave(char *saveFileName) {
setMouseCursor(MOUSE_CURSOR_NORMAL);
}
-/*! \brief Load animDataTable from save
- * \param fHandle Savefile open for reading
- * \param saveGameFormat The used savegame format
- * \todo Add Operation Stealth savefile support
+/**
+ * Load animDataTable from save
+ * @param fHandle Savefile open for reading
+ * @param saveGameFormat The used savegame format
+ * @todo Add Operation Stealth savefile support
*
* Unlike the old code, this one actually rebuilds the table one frame
* at a time.
diff --git a/engines/cine/script.h b/engines/cine/script.h
index 40b7023930..1c3b496375 100644
--- a/engines/cine/script.h
+++ b/engines/cine/script.h
@@ -36,7 +36,8 @@ namespace Cine {
#define SCRIPT_STACK_SIZE 50
#define LOCAL_VARS_SIZE 50
-/*! \brief Fixed size array of script variables.
+/**
+ * Fixed size array of script variables.
*
* Array size can be set in constructors, once the instance is created,
* it cannot be changed directly.
@@ -51,7 +52,8 @@ struct Opcode {
const char *args;
};
-/*! \brief Fixed size array for script variables
+/**
+ * Fixed size array for script variables
*/
class ScriptVars {
private:
@@ -78,7 +80,8 @@ public:
class FWScriptInfo;
-/*! \brief Script bytecode and initial labels, ScriptStruct replacement.
+/**
+ * Script bytecode and initial labels, ScriptStruct replacement.
*
* _data is one byte longer to make sure strings in bytecode are properly
* terminated
@@ -103,9 +106,6 @@ public:
RawScript &operator=(const RawScript &src);
void setData(const FWScriptInfo &info, const byte *data);
- /*! \brief Size of script
- * \return Size of script
- */
const ScriptVars &labels() const;
byte getByte(unsigned int pos) const;
uint16 getWord(unsigned int pos) const;
@@ -113,7 +113,8 @@ public:
uint16 getLabel(const FWScriptInfo &info, byte index, uint16 offset) const;
};
-/*! \brief Object script class, RelObjectScript replacement
+/**
+ * Object script class, RelObjectScript replacement
*
* Script parameters are not used, this class is required by different
* script initialization of object scripts
@@ -128,13 +129,16 @@ public:
RawObjectScript(uint16 size, uint16 p1, uint16 p2, uint16 p3);
RawObjectScript(const FWScriptInfo &info, const byte *data, uint16 size, uint16 p1, uint16 p2, uint16 p3);
- /// \brief Run the script one more time
- /// \return Run count before incrementation
+ /**
+ * Run the script one more time.
+ * @return Run count before incrementation
+ */
int16 run() { return _runCount++; }
};
-/*! \brief Future Wars script, prcLinkedListStruct replacement
- * \todo Rewrite _globalVars initialization
+/**
+ * Future Wars script, prcLinkedListStruct replacement.
+ * @todo Rewrite _globalVars initialization
*/
class FWScript {
private:
@@ -296,7 +300,8 @@ public:
friend class OSScript;
};
-/*! \brief Operation Stealth script, prcLinkedListStruct replacement
+/**
+ * Operation Stealth script, prcLinkedListStruct replacement
*/
class OSScript : public FWScript {
private:
@@ -316,7 +321,8 @@ public:
friend class OSScriptInfo;
};
-/*! \brief Future Wars script factory and info
+/**
+ * Future Wars script factory and info
*/
class FWScriptInfo {
protected:
@@ -334,7 +340,8 @@ public:
friend class FWScript;
};
-/*! \brief Operation Stealth script factory and info
+/**
+ * Operation Stealth script factory and info
*/
class OSScriptInfo : public FWScriptInfo {
protected:
diff --git a/engines/cine/script_fw.cpp b/engines/cine/script_fw.cpp
index 7dffa5fd1e..e71fec8898 100644
--- a/engines/cine/script_fw.cpp
+++ b/engines/cine/script_fw.cpp
@@ -23,7 +23,7 @@
*
*/
-/*! \file
+/** \file
* Future Wars script interpreter file
*/
@@ -218,7 +218,8 @@ void FWScript::setupTable() {
FWScriptInfo *scriptInfo; ///< Script factory
RawScriptArray scriptTable; ///< Table of script bytecode
-/*! \todo: replace with script subsystem
+/**
+ * @todo replace with script subsystem
*/
void setupOpcodes() {
static FWScriptInfo fw;
@@ -232,8 +233,9 @@ void setupOpcodes() {
}
}
-/*! \brief Allocate empty array
- * \param len Size of array
+/**
+ * Allocate empty array
+ * @param len Size of array
*
* Explicit to prevent var=0 instead of var[i]=0 typos.
*/
@@ -242,9 +244,10 @@ ScriptVars::ScriptVars(unsigned int len) : _size(len), _vars(new int16[len]) {
reset();
}
-/*! \brief Allocate array and read contents from savefile
- * \param fHandle Savefile open for reading
- * \param len Size of array
+/**
+ * Allocate array and read contents from savefile
+ * @param fHandle Savefile open for reading
+ * @param len Size of array
*/
ScriptVars::ScriptVars(Common::SeekableReadStream &fHandle, unsigned int len)
: _size(len), _vars(new int16[len]) {
@@ -254,20 +257,23 @@ ScriptVars::ScriptVars(Common::SeekableReadStream &fHandle, unsigned int len)
load(fHandle);
}
-/*! \brief Copy constructor
+/**
+ * Copy constructor
*/
ScriptVars::ScriptVars(const ScriptVars &src) : _size(src._size), _vars(new int16[_size]) {
assert(_vars);
memcpy(_vars, src._vars, _size * sizeof(int16));
}
-/*! \brief Destructor
+/**
+ * Destructor
*/
ScriptVars::~ScriptVars() {
delete[] _vars;
}
-/*! \brief Assignment operator
+/**
+ * Assignment operator
*/
ScriptVars &ScriptVars::operator=(const ScriptVars &src) {
ScriptVars tmp(src);
@@ -280,9 +286,10 @@ ScriptVars &ScriptVars::operator=(const ScriptVars &src) {
return *this;
}
-/*! \brief Direct array item access
- * \param idx Item index
- * \return Reference to item
+/**
+ * Direct array item access.
+ * @param idx Item index
+ * @return Reference to item
*/
int16 &ScriptVars::operator[](unsigned int idx) {
debug(6, "assert(%d < %d)", idx, _size);
@@ -290,9 +297,10 @@ int16 &ScriptVars::operator[](unsigned int idx) {
return _vars[idx];
}
-/*! \brief Direct read-only array item access
- * \param idx Item index
- * \return Copy of item
+/**
+ * Direct read-only array item access.
+ * @param idx Item index
+ * @return Copy of item
*/
int16 ScriptVars::operator[](unsigned int idx) const {
debug(6, "assert(%d < %d)", idx, _size);
@@ -300,16 +308,18 @@ int16 ScriptVars::operator[](unsigned int idx) const {
return _vars[idx];
}
-/*! \brief Savefile writer
- * \param fHandle Savefile open for writing
+/**
+ * Savefile writer
+ * @param fHandle Savefile open for writing
*/
void ScriptVars::save(Common::OutSaveFile &fHandle) const {
save(fHandle, _size);
}
-/*! \brief Savefile writer with data length limit
- * \param fHandle Savefile open for writing
- * \param len Length of data to be written (len <= _size)
+/**
+ * Savefile writer with data length limit
+ * @param fHandle Savefile open for writing
+ * @param len Length of data to be written (len <= _size)
*/
void ScriptVars::save(Common::OutSaveFile &fHandle, unsigned int len) const {
debug(6, "assert(%d <= %d)", len, _size);
@@ -319,16 +329,18 @@ void ScriptVars::save(Common::OutSaveFile &fHandle, unsigned int len) const {
}
}
-/*! \brief Restore array from savefile
- * \param fHandle Savefile open for reading
+/**
+ * Restore array from savefile
+ * @param fHandle Savefile open for reading
*/
void ScriptVars::load(Common::SeekableReadStream &fHandle) {
load(fHandle, _size);
}
-/*! \brief Restore part of array from savefile
- * \param fHandle Savefile open for reading
- * \param len Length of data to be read
+/**
+ * Restore part of array from savefile
+ * @param fHandle Savefile open for reading
+ * @param len Length of data to be read
*/
void ScriptVars::load(Common::SeekableReadStream &fHandle, unsigned int len) {
debug(6, "assert(%d <= %d)", len, _size);
@@ -338,14 +350,16 @@ void ScriptVars::load(Common::SeekableReadStream &fHandle, unsigned int len) {
}
}
-/*! \brief Reset all values to 0
+/**
+ * Reset all values to 0
*/
void ScriptVars::reset() {
memset( _vars, 0, _size * sizeof(int16));
}
-/*! \brief Constructor for partial loading
- * \param s Size of bytecode which will be added later
+/**
+ * Constructor for partial loading
+ * @param s Size of bytecode which will be added later
*
* This constructor _MUST_ be followed by setdata() method call before the
* instance can be used. It leaves the instance in partially invalid state.
@@ -353,9 +367,10 @@ void ScriptVars::reset() {
RawScript::RawScript(uint16 s) : _size(s), _data(NULL),
_labels(SCRIPT_STACK_SIZE) { }
-/*! \brief Complete constructor
- * \param data Script bytecode
- * \param s Bytecode length
+/**
+ * Complete constructor
+ * @param data Script bytecode
+ * @param s Bytecode length
*/
RawScript::RawScript(const FWScriptInfo &info, const byte *data, uint16 s) :
_size(s), _data(NULL), _labels(SCRIPT_STACK_SIZE) {
@@ -363,7 +378,8 @@ RawScript::RawScript(const FWScriptInfo &info, const byte *data, uint16 s) :
setData(info, data);
}
-/*! \brief Copy constructor
+/**
+ * Copy constructor
*/
RawScript::RawScript(const RawScript &src) : _size(src._size),
_data(new byte[_size+1]), _labels(src._labels) {
@@ -372,13 +388,15 @@ RawScript::RawScript(const RawScript &src) : _size(src._size),
memcpy(_data, src._data, _size+1);
}
-/*! \brief Destructor
+/**
+ * Destructor
*/
RawScript::~RawScript() {
delete[] _data;
}
-/*! \brief Assignment operator
+/**
+ * Assignment operator
*/
RawScript &RawScript::operator=(const RawScript &src) {
assert(src._data);
@@ -396,10 +414,11 @@ RawScript &RawScript::operator=(const RawScript &src) {
return *this;
}
-/*! \brief Get the next label in bytecode
- * \param info Script info instance
- * \param offset Starting offset
- * \return Index of the next label in bytecode or _size on end of bytecode
+/**
+ * Get the next label in bytecode
+ * @param info Script info instance
+ * @param offset Starting offset
+ * @return Index of the next label in bytecode or _size on end of bytecode
*
* computeScriptStackSub replacement
*/
@@ -449,8 +468,9 @@ int RawScript::getNextLabel(const FWScriptInfo &info, int offset) const {
return _size;
}
-/*! \brief Calculate initial script labels
- * \param info Script info instance
+/**
+ * Calculate initial script labels
+ * @param info Script info instance
*
* computeScriptStack replacement
*/
@@ -471,11 +491,12 @@ void RawScript::computeLabels(const FWScriptInfo &info) {
}
}
-/*! \brief find the next label from current position
- * \param info Script info instance
- * \param index Label index to look for
- * \param offset Current position in script
- * \return Position of next instruction following the label
+/**
+ * find the next label from current position
+ * @param info Script info instance
+ * @param index Label index to look for
+ * @param offset Current position in script
+ * @return Position of next instruction following the label
*
* computeScriptStackFromScript replacement
*/
@@ -494,8 +515,9 @@ uint16 RawScript::getLabel(const FWScriptInfo &info, byte index, uint16 offset)
return -pos - 1;
}
-/*! \brief Copy bytecode and calculate labels
- * \param data Bytecode to copy, must be _size long
+/**
+ * Copy bytecode and calculate labels
+ * @param data Bytecode to copy, must be _size long
*/
void RawScript::setData(const FWScriptInfo &info, const byte *data) {
assert(!_data); // this function should be called only once per instance
@@ -508,17 +530,19 @@ void RawScript::setData(const FWScriptInfo &info, const byte *data) {
computeLabels(info);
}
-/*! \brief Initial script labels
- * \return Precalculated script labels
+/**
+ * Initial script labels
+ * @return Precalculated script labels
*/
const ScriptVars &RawScript::labels() const {
assert(_data);
return _labels;
}
-/*! \brief One byte of bytecode
- * \param pos Index in bytecode
- * \return Byte from bytecode
+/**
+ * One byte of bytecode
+ * @param pos Index in bytecode
+ * @return Byte from bytecode
*/
byte RawScript::getByte(unsigned int pos) const {
assert(_data && pos < _size);
@@ -526,9 +550,10 @@ byte RawScript::getByte(unsigned int pos) const {
return _data[pos];
}
-/*! \brief One word of bytecode
- * \param pos Index of the first byte in bytecode
- * \return Word of bytecode
+/**
+ * One word of bytecode
+ * @param pos Index of the first byte in bytecode
+ * @return Word of bytecode
*/
uint16 RawScript::getWord(unsigned int pos) const {
assert(_data && pos+1 < _size);
@@ -536,9 +561,10 @@ uint16 RawScript::getWord(unsigned int pos) const {
return READ_BE_UINT16(_data + pos);
}
-/*! \brief String in bytecode
- * \param pos Index of the first char in string
- * \return Pointer to part of bytecode
+/**
+ * String in bytecode
+ * @param pos Index of the first char in string
+ * @return Pointer to part of bytecode
*/
const char *RawScript::getString(unsigned int pos) const {
assert(_data && pos < _size);
@@ -546,11 +572,12 @@ const char *RawScript::getString(unsigned int pos) const {
return (const char*)(_data+pos);
}
-/*! \brief Constructor for partial loading
- * \param size Size of bytecode which will be added later
- * \param p1 First object script parameter
- * \param p2 Second object script parameter
- * \param p3 Third object script parameter
+/**
+ * Constructor for partial loading
+ * @param size Size of bytecode which will be added later
+ * @param p1 First object script parameter
+ * @param p2 Second object script parameter
+ * @param p3 Third object script parameter
*
* This constructor _MUST_ be followed by setdata() method call before the
* instance can be used. It leaves the instance in partially invalid state.
@@ -559,45 +586,50 @@ RawObjectScript::RawObjectScript(uint16 s, uint16 p1, uint16 p2, uint16 p3)
: RawScript(s), _runCount(0), _param1(p1), _param2(p2), _param3(p3)
{ }
-/*! \brief Complete constructor
- * \param data Script bytecode
- * \param s Bytecode length
- * \param p1 First object script parameter
- * \param p2 Second object script parameter
- * \param p3 Third object script parameter
+/**
+ * Complete constructor
+ * @param data Script bytecode
+ * @param s Bytecode length
+ * @param p1 First object script parameter
+ * @param p2 Second object script parameter
+ * @param p3 Third object script parameter
*/
RawObjectScript::RawObjectScript(const FWScriptInfo &info, const byte *data,
uint16 s, uint16 p1, uint16 p2, uint16 p3) : RawScript(info, data, s),
_runCount(0), _param1(p1), _param2(p2), _param3(p3) { }
-/*! \brief Contructor for global scripts
- * \param script Script bytecode reference
- * \param idx Script bytecode index
+/**
+ * Contructor for global scripts
+ * @param script Script bytecode reference
+ * @param idx Script bytecode index
*/
FWScript::FWScript(const RawScript &script, int16 idx) : _script(script),
_pos(0), _line(0), _compare(0), _index(idx),
_labels(script.labels()), _localVars(LOCAL_VARS_SIZE),
_globalVars(globalVars), _info(new FWScriptInfo) { }
-/*! \brief Copy constructor
+/**
+ * Copy constructor
*/
FWScript::FWScript(const FWScript &src) : _script(src._script), _pos(src._pos),
_line(src._line), _compare(src._compare), _index(src._index),
_labels(src._labels), _localVars(src._localVars),
_globalVars(src._globalVars), _info(new FWScriptInfo) { }
-/*! \brief Contructor for global scripts in derived classes
- * \param script Script bytecode reference
- * \param idx Script bytecode index
+/**
+ * Contructor for global scripts in derived classes
+ * @param script Script bytecode reference
+ * @param idx Script bytecode index
*/
FWScript::FWScript(const RawScript &script, int16 idx, FWScriptInfo *info) :
_script(script), _pos(0), _line(0), _compare(0), _index(idx),
_labels(script.labels()), _localVars(LOCAL_VARS_SIZE),
_globalVars(globalVars), _info(info) { }
-/*! \brief Constructor for object scripts in derived classes
- * \param script Script bytecode reference
- * \param idx Script bytecode index
+/**
+ * Constructor for object scripts in derived classes
+ * @param script Script bytecode reference
+ * @param idx Script bytecode index
*/
FWScript::FWScript(RawObjectScript &script, int16 idx, FWScriptInfo *info) :
_script(script), _pos(0), _line(0), _compare(0), _index(idx),
@@ -607,7 +639,8 @@ FWScript::FWScript(RawObjectScript &script, int16 idx, FWScriptInfo *info) :
_localVars[0] = script.run();
}
-/*! \brief Copy constructor for derived classes
+/**
+ * Copy constructor for derived classes
*/
FWScript::FWScript(const FWScript &src, FWScriptInfo *info) :
_script(src._script), _pos(src._pos), _line(src._line),
@@ -618,8 +651,9 @@ FWScript::~FWScript() {
delete _info;
}
-/*! \brief Read next byte from bytecode
- * \return Byte from bytecode
+/**
+ * Read next byte from bytecode
+ * @return Byte from bytecode
*/
byte FWScript::getNextByte() {
byte val = _script.getByte(_pos);
@@ -627,8 +661,9 @@ byte FWScript::getNextByte() {
return val;
}
-/*! \brief Read next word from bytecode
- * \return Word from bytecode
+/**
+ * Read next word from bytecode
+ * @return Word from bytecode
*/
uint16 FWScript::getNextWord() {
uint16 val = _script.getWord(_pos);
@@ -636,8 +671,9 @@ uint16 FWScript::getNextWord() {
return val;
}
-/*! \brief Read next string from bytecode
- * \return Pointer to string
+/**
+ * Read next string from bytecode
+ * @return Pointer to string
*/
const char *FWScript::getNextString() {
const char *val = _script.getString(_pos);
@@ -645,11 +681,12 @@ const char *FWScript::getNextString() {
return val;
}
-/*! \brief Restore script state from savefile
- * \param labels Restored script labels
- * \param local Restored local script variables
- * \param compare Restored last comparison result
- * \param pos Restored script position
+/**
+ * Restore script state from savefile
+ * @param labels Restored script labels
+ * @param local Restored local script variables
+ * @param compare Restored last comparison result
+ * @param pos Restored script position
*/
void FWScript::load(const ScriptVars &labels, const ScriptVars &local, uint16 compare, uint16 pos) {
assert(pos < _script._size);
@@ -659,8 +696,9 @@ void FWScript::load(const ScriptVars &labels, const ScriptVars &local, uint16 co
_pos = _line = pos;
}
-/*! \brief Execute script
- * \return <0 on script termination, >0 on script pause
+/**
+ * Execute script
+ * @return <0 on script termination, >0 on script pause
*
* executeScript replacement.
* Instruction handler must return 0 if the script should continue or
@@ -682,8 +720,9 @@ int FWScript::execute() {
return ret;
}
-/*! \brief Save script to savefile
- * \param fHandle Savefile handle
+/**
+ * Save script to savefile
+ * @param fHandle Savefile handle
*/
void FWScript::save(Common::OutSaveFile &fHandle) const {
_labels.save(fHandle);
@@ -694,8 +733,9 @@ void FWScript::save(Common::OutSaveFile &fHandle) const {
fHandle.writeUint16BE(_index);
}
-/*! \brief Get opcode info string
- * \param opcode Opcode to look for in opcode table
+/**
+ * Get opcode info string
+ * @param opcode Opcode to look for in opcode table
*/
const char *FWScriptInfo::opcodeInfo(byte opcode) const {
if (opcode == 0 || opcode > FWScript::_numOpcodes) {
@@ -710,8 +750,9 @@ const char *FWScriptInfo::opcodeInfo(byte opcode) const {
return FWScript::_opcodeTable[opcode - 1].args;
}
-/*! \brief Get opcode handler pointer
- * \param opcode Opcode to look for in opcode table
+/**
+ * Get opcode handler pointer
+ * @param opcode Opcode to look for in opcode table
*/
OpFunc FWScriptInfo::opcodeHandler(byte opcode) const {
if (opcode == 0 || opcode > FWScript::_numOpcodes) {
@@ -726,29 +767,32 @@ OpFunc FWScriptInfo::opcodeHandler(byte opcode) const {
return FWScript::_opcodeTable[opcode - 1].proc;
}
-/*! \brief Create new FWScript instance
- * \param script Script bytecode
- * \param index Bytecode index
+/**
+ * Create new FWScript instance
+ * @param script Script bytecode
+ * @param index Bytecode index
*/
FWScript *FWScriptInfo::create(const RawScript &script, int16 index) const {
return new FWScript(script, index);
}
-/*! \brief Create new FWScript instance
- * \param script Object script bytecode
- * \param index Bytecode index
+/**
+ * Create new FWScript instance
+ * @param script Object script bytecode
+ * @param index Bytecode index
*/
FWScript *FWScriptInfo::create(const RawObjectScript &script, int16 index) const {
return new FWScript(script, index);
}
-/*! \brief Load saved FWScript instance
- * \param script Script bytecode
- * \param index Bytecode index
- * \param local Local variables
- * \param labels Script labels
- * \param compare Last compare result
- * \param pos Position in script
+/**
+ * Load saved FWScript instance
+ * @param script Script bytecode
+ * @param index Bytecode index
+ * @param local Local variables
+ * @param labels Script labels
+ * @param compare Last compare result
+ * @param pos Position in script
*/
FWScript *FWScriptInfo::create(const RawScript &script, int16 index, const ScriptVars &labels, const ScriptVars &local, uint16 compare, uint16 pos) const {
FWScript *tmp = new FWScript(script, index);
@@ -757,13 +801,14 @@ FWScript *FWScriptInfo::create(const RawScript &script, int16 index, const Scrip
return tmp;
}
-/*! \brief Load saved FWScript instance
- * \param script Object script bytecode
- * \param index Bytecode index
- * \param local Local variables
- * \param labels Script labels
- * \param compare Last compare result
- * \param pos Position in script
+/**
+ * Load saved FWScript instance
+ * @param script Object script bytecode
+ * @param index Bytecode index
+ * @param local Local variables
+ * @param labels Script labels
+ * @param compare Last compare result
+ * @param pos Position in script
*/
FWScript *FWScriptInfo::create(const RawObjectScript &script, int16 index, const ScriptVars &labels, const ScriptVars &local, uint16 compare, uint16 pos) const {
FWScript *tmp = new FWScript(script, index);
@@ -1329,7 +1374,7 @@ int FWScript::o1_loadBg() {
return 0;
}
-/*! \brief Load collision table data */
+/** Load collision table data */
int FWScript::o1_loadCt() {
const char *param = getNextString();
@@ -1437,8 +1482,9 @@ int FWScript::o1_palRotate() {
return 0;
}
-/*!\brief Pause script
- * \todo Make sure it works
+/**
+ * Pause script.
+ * @todo Make sure it works
*/
int FWScript::o1_break() {
debugC(5, kCineDebugScript, "Line: %d: break", _line);
@@ -1478,8 +1524,9 @@ int FWScript::o1_break() {
return 1;
}
-/*! \brief Terminate script
- * \todo Make sure it works
+/**
+ * Terminate script
+ * @todo Make sure it works
*/
int FWScript::o1_endScript() {
debugC(5, kCineDebugScript, "Line: %d: endScript", _line);
@@ -1584,7 +1631,8 @@ int FWScript::o1_unloadAllMasks() {
return 0;
}
-/*! \todo Implement this instruction
+/**
+ * @todo Implement this instruction
*/
int FWScript::o1_setScreenDimensions() {
uint16 a = getNextWord();
@@ -1596,7 +1644,8 @@ int FWScript::o1_setScreenDimensions() {
return 0;
}
-/*! \todo Implement this instruction
+/**
+ * @todo Implement this instruction
*/
int FWScript::o1_displayBackground() {
warning("STUB: o1_displayBackground()");
@@ -1698,7 +1747,8 @@ int FWScript::o1_stopSample() {
return 0;
}
-/*! \todo Implement this instruction's Amiga part (PC part already done)
+/**
+ * @todo Implement this instruction's Amiga part (PC part already done)
* In PC versions of Future Wars and Operation Stealth this instruction does nothing else but read the parameters.
*/
int FWScript::o1_op71() {
@@ -1708,7 +1758,8 @@ int FWScript::o1_op71() {
return 0;
}
-/*! \todo Implement this instruction's Amiga part (PC part already done)
+/**
+ * @todo Implement this instruction's Amiga part (PC part already done)
* In PC versions of Future Wars and Operation Stealth this instruction does nothing else but read the parameters.
*/
int FWScript::o1_op72() {
@@ -1719,7 +1770,8 @@ int FWScript::o1_op72() {
return 0;
}
-/*! \todo Implement this instruction's Amiga part (PC part already done)
+/**
+ * @todo Implement this instruction's Amiga part (PC part already done)
* In PC versions of Future Wars and Operation Stealth this instruction does nothing else but read the parameters.
*/
int FWScript::o1_op73() {
@@ -1938,13 +1990,15 @@ void executeGlobalScripts() {
}
}
-/*! \todo Remove object scripts with script index of -1 (Not script position, but script index!).
+/**
+ * @todo Remove object scripts with script index of -1 (Not script position, but script index!).
* This would seem to be valid for both Future Wars and Operation Stealth.
*/
void purgeObjectScripts() {
}
-/*! \todo Remove global scripts with script index of -1 (Not script position, but script index!).
+/**
+ * @todo Remove global scripts with script index of -1 (Not script position, but script index!).
* This would seem to be valid for both Future Wars and Operation Stealth.
*/
void purgeGlobalScripts() {
diff --git a/engines/cine/script_os.cpp b/engines/cine/script_os.cpp
index 293fabd669..d03b118443 100644
--- a/engines/cine/script_os.cpp
+++ b/engines/cine/script_os.cpp
@@ -23,7 +23,7 @@
*
*/
-/*! \file
+/** \file
* Operation Stealth script interpreter file
*/
@@ -261,36 +261,41 @@ void OSScript::setupTable() {
OSScript::_numOpcodes = ARRAYSIZE(opcodeTable);
}
-/*! \brief Contructor for global scripts
- * \param script Script bytecode reference
- * \param idx Script bytecode index
+/**
+ * Contructor for global scripts
+ * @param script Script bytecode reference
+ * @param idx Script bytecode index
*/
OSScript::OSScript(const RawScript &script, int16 idx) :
FWScript(script, idx, new OSScriptInfo) {}
-/*! \brief Constructor for object scripts
- * \param script Script bytecode reference
- * \param idx Script bytecode index
+/**
+ * Constructor for object scripts
+ * @param script Script bytecode reference
+ * @param idx Script bytecode index
*/
OSScript::OSScript(RawObjectScript &script, int16 idx) :
FWScript(script, idx, new OSScriptInfo) {}
-/*! \brief Copy constructor
+/**
+ * Copy constructor
*/
OSScript::OSScript(const OSScript &src) : FWScript(src, new OSScriptInfo) {}
-/*! \brief Restore script state from savefile
- * \param labels Restored script labels
- * \param local Restored local script variables
- * \param compare Restored last comparison result
- * \param pos Restored script position
+/**
+ * Restore script state from savefile
+ * @param labels Restored script labels
+ * @param local Restored local script variables
+ * @param compare Restored last comparison result
+ * @param pos Restored script position
*/
void OSScript::load(const ScriptVars &labels, const ScriptVars &local, uint16 compare, uint16 pos) {
FWScript::load(labels, local, compare, pos);
}
-/*! \brief Get opcode info string
- * \param opcode Opcode to look for in opcode table
+/**
+ * Get opcode info string
+ * @param opcode Opcode to look for in opcode table
*/
const char *OSScriptInfo::opcodeInfo(byte opcode) const {
if (opcode == 0 || opcode > OSScript::_numOpcodes) {
@@ -305,8 +310,9 @@ const char *OSScriptInfo::opcodeInfo(byte opcode) const {
return OSScript::_opcodeTable[opcode - 1].args;
}
-/*! \brief Get opcode handler pointer
- * \param opcode Opcode to look for in opcode table
+/**
+ * Get opcode handler pointer
+ * @param opcode Opcode to look for in opcode table
*/
OpFunc OSScriptInfo::opcodeHandler(byte opcode) const {
if (opcode == 0 || opcode > OSScript::_numOpcodes) {
@@ -321,29 +327,32 @@ OpFunc OSScriptInfo::opcodeHandler(byte opcode) const {
return OSScript::_opcodeTable[opcode - 1].proc;
}
-/*! \brief Create new OSScript instance
- * \param script Script bytecode
- * \param index Bytecode index
+/**
+ * Create new OSScript instance
+ * @param script Script bytecode
+ * @param index Bytecode index
*/
FWScript *OSScriptInfo::create(const RawScript &script, int16 index) const {
return new OSScript(script, index);
}
-/*! \brief Create new OSScript instance
- * \param script Object script bytecode
- * \param index Bytecode index
+/**
+ * Create new OSScript instance
+ * @param script Object script bytecode
+ * @param index Bytecode index
*/
FWScript *OSScriptInfo::create(const RawObjectScript &script, int16 index) const {
return new OSScript(script, index);
}
-/*! \brief Load saved OSScript instance
- * \param script Script bytecode
- * \param index Bytecode index
- * \param local Local variables
- * \param labels Script labels
- * \param compare Last compare result
- * \param pos Position in script
+/**
+ * Load saved OSScript instance
+ * @param script Script bytecode
+ * @param index Bytecode index
+ * @param local Local variables
+ * @param labels Script labels
+ * @param compare Last compare result
+ * @param pos Position in script
*/
FWScript *OSScriptInfo::create(const RawScript &script, int16 index, const ScriptVars &labels, const ScriptVars &local, uint16 compare, uint16 pos) const {
OSScript *tmp = new OSScript(script, index);
@@ -352,13 +361,14 @@ FWScript *OSScriptInfo::create(const RawScript &script, int16 index, const Scrip
return tmp;
}
-/*! \brief Load saved OSScript instance
- * \param script Object script bytecode
- * \param index Bytecode index
- * \param local Local variables
- * \param labels Script labels
- * \param compare Last compare result
- * \param pos Position in script
+/**
+ * Load saved OSScript instance
+ * @param script Object script bytecode
+ * @param index Bytecode index
+ * @param local Local variables
+ * @param labels Script labels
+ * @param compare Last compare result
+ * @param pos Position in script
*/
FWScript *OSScriptInfo::create(const RawObjectScript &script, int16 index, const ScriptVars &labels, const ScriptVars &local, uint16 compare, uint16 pos) const {
OSScript *tmp = new OSScript(script, index);
@@ -371,7 +381,7 @@ FWScript *OSScriptInfo::create(const RawObjectScript &script, int16 index, const
// OPERATION STEALTH opcodes
// ------------------------------------------------------------------------
-/*! \brief Load collision table data */
+/** Load collision table data */
int FWScript::o2_loadCt() {
const char *param = getNextString();
@@ -448,8 +458,9 @@ int FWScript::o2_removeSeq() {
return 0;
}
-/*! \todo Implement this instruction
- * \note According to the scripts' opcode usage comparison this opcode isn't used at all.
+/**
+ * @todo Implement this instruction
+ * @note According to the scripts' opcode usage comparison this opcode isn't used at all.
*/
int FWScript::o2_op81() {
warning("STUB: o2_op81()");
@@ -469,7 +480,8 @@ int FWScript::o2_modifySeqListElement() {
return 0;
}
-/*! \todo Check whether this opcode's name is backwards (i.e. should it be o2_isSeqNotRunning?)
+/**
+ * @todo Check whether this opcode's name is backwards (i.e. should it be o2_isSeqNotRunning?)
*/
int FWScript::o2_isSeqRunning() {
byte a = getNextByte();
@@ -485,7 +497,8 @@ int FWScript::o2_isSeqRunning() {
return 0;
}
-/*! \todo The assert may produce false positives and requires testing
+/**
+ * @todo The assert may produce false positives and requires testing
*/
int FWScript::o2_gotoIfSupNearest() {
byte labelIdx = getNextByte();
@@ -501,7 +514,8 @@ int FWScript::o2_gotoIfSupNearest() {
return 0;
}
-/*! \todo The assert may produce false positives and requires testing
+/**
+ * @todo The assert may produce false positives and requires testing
*/
int FWScript::o2_gotoIfSupEquNearest() {
byte labelIdx = getNextByte();
@@ -517,7 +531,8 @@ int FWScript::o2_gotoIfSupEquNearest() {
return 0;
}
-/*! \todo The assert may produce false positives and requires testing
+/**
+ * @todo The assert may produce false positives and requires testing
*/
int FWScript::o2_gotoIfInfNearest() {
byte labelIdx = getNextByte();
@@ -533,7 +548,8 @@ int FWScript::o2_gotoIfInfNearest() {
return 0;
}
-/*! \todo The assert may produce false positives and requires testing
+/**
+ * @todo The assert may produce false positives and requires testing
*/
int FWScript::o2_gotoIfInfEquNearest() {
byte labelIdx = getNextByte();
@@ -549,7 +565,8 @@ int FWScript::o2_gotoIfInfEquNearest() {
return 0;
}
-/*! \todo The assert may produce false positives and requires testing
+/**
+ * @todo The assert may produce false positives and requires testing
*/
int FWScript::o2_gotoIfEquNearest() {
byte labelIdx = getNextByte();
@@ -565,7 +582,8 @@ int FWScript::o2_gotoIfEquNearest() {
return 0;
}
-/*! \todo The assert may produce false positives and requires testing
+/**
+ * @todo The assert may produce false positives and requires testing
*/
int FWScript::o2_gotoIfDiffNearest() {
byte labelIdx = getNextByte();
@@ -686,8 +704,9 @@ int FWScript::o2_wasZoneChecked() {
return 0;
}
-/*! \todo Implement this instruction
- * \note According to the scripts' opcode usage comparison this opcode isn't used at all.
+/**
+ * @todo Implement this instruction
+ * @note According to the scripts' opcode usage comparison this opcode isn't used at all.
*/
int FWScript::o2_op9B() {
uint16 a = getNextWord();
@@ -702,8 +721,9 @@ int FWScript::o2_op9B() {
return 0;
}
-/*! \todo Implement this instruction
- * \note According to the scripts' opcode usage comparison this opcode isn't used at all.
+/**
+ * @todo Implement this instruction
+ * @note According to the scripts' opcode usage comparison this opcode isn't used at all.
*/
int FWScript::o2_op9C() {
uint16 a = getNextWord();
@@ -742,8 +762,9 @@ int FWScript::o2_setAdditionalBgVScroll() {
return 0;
}
-/*! \todo Implement this instruction
- * \note According to the scripts' opcode usage comparison this opcode isn't used at all.
+/**
+ * @todo Implement this instruction
+ * @note According to the scripts' opcode usage comparison this opcode isn't used at all.
*/
int FWScript::o2_op9F() {
warning("o2_op9F()");
diff --git a/engines/cine/texte.cpp b/engines/cine/texte.cpp
index 3dceae2fa4..a9252f71e8 100644
--- a/engines/cine/texte.cpp
+++ b/engines/cine/texte.cpp
@@ -37,7 +37,8 @@ const char **otherMessages;
const char *defaultCommandPreposition;
const char **commandPrepositionTable;
-/*! \brief Loads font data from the given file.
+/**
+ * Loads font data from the given file.
* The number of characters used in the font varies between game versions:
* 78 (Most PC, Amiga and Atari ST versions of Future Wars, but also Operation Stealth's Amiga demo),
* 85 (All observed versions of German Future Wars (Amiga and PC), possibly Spanish Future Wars too),
@@ -639,12 +640,13 @@ void loadPoldatDat(const char *fname) {
}
}
-/*! \brief Fit a substring of text into one line of fixed width text box
- * \param str Text to fit
- * \param maxWidth Text box width
- * \param[out] words Number of words that fit
- * \param[out] width Total width of nonblank characters that fit
- * \return Length of substring which fits
+/**
+ * Fit a substring of text into one line of fixed width text box
+ * @param str Text to fit
+ * @param maxWidth Text box width
+ * @param[out] words Number of words that fit
+ * @param[out] width Total width of nonblank characters that fit
+ * @return Length of substring which fits
*/
int fitLine(const char *str, int maxWidth, int &words, int &width) {
int i, bkpWords = 0, bkpWidth = 0, bkpLen = 0;
diff --git a/engines/cine/various.cpp b/engines/cine/various.cpp
index 756baf240c..3f9d739673 100644
--- a/engines/cine/various.cpp
+++ b/engines/cine/various.cpp
@@ -93,7 +93,8 @@ uint16 musicIsPlaying;
byte isInPause = 0;
-/*! \brief Bit masks for mouse buttons' states
+/**
+ * Bit masks for mouse buttons' states
* Bit on = mouse button down
* Bit off = mouse button up
*/
@@ -103,14 +104,14 @@ enum MouseButtonState
kRightMouseButton = (1 << 1)
};
-/*! \brief Values used by the xMoveKeyb variable */
+/** Values used by the xMoveKeyb variable */
enum xMoveKeybEnums {
kKeybMoveCenterX = 0,
kKeybMoveRight = 1,
kKeybMoveLeft = 2
};
-/*! \brief Values used by the yMoveKeyb variable */
+/** Values used by the yMoveKeyb variable */
enum yMoveKeybEnums {
kKeybMoveCenterY = 0,
kKeybMoveDown = 1,
@@ -135,9 +136,10 @@ int16 objListTab[20];
Common::Array<uint16> zoneData;
Common::Array<uint16> zoneQuery; ///< Only exists in Operation Stealth
-/*! \brief Move the player character using the keyboard
- * \param x Negative values move left, positive right, zero not at all
- * \param y Negative values move down, positive up, zero not at all
+/**
+ * Move the player character using the keyboard
+ * @param x Negative values move left, positive right, zero not at all
+ * @param y Negative values move down, positive up, zero not at all
* NOTE: If both x and y are zero then the character stops
* FIXME: This seems to only work in Operation Stealth. May need code changes somewhere else...
*/
@@ -173,9 +175,10 @@ void runObjectScript(int16 entryIdx) {
objectScripts.push_back(tmp);
}
-/*! \brief Add action result message to overlay list
- * \param cmd Message description
- * \todo Why are x, y, width and color left uninitialized?
+/**
+ * Add action result message to overlay list
+ * @param cmd Message description
+ * @todo Why are x, y, width and color left uninitialized?
*/
void addPlayerCommandMessage(int16 cmd) {
overlay tmp;
@@ -208,10 +211,11 @@ int16 getRelEntryForObject(uint16 param1, uint16 param2, SelectedObjStruct *pSel
return found;
}
-/*! \brief Find index of the object under cursor
- * \param x Mouse cursor coordinate
- * \param y Mouse cursor coordinate
- * \todo Fix displaced type 1 objects
+/**
+ * Find index of the object under cursor
+ * @param x Mouse cursor coordinate
+ * @param y Mouse cursor coordinate
+ * @todo Fix displaced type 1 objects
*/
int16 getObjectUnderCursor(uint16 x, uint16 y) {
Common::List<overlay>::iterator it;
@@ -1458,9 +1462,9 @@ uint16 addAni(uint16 param1, uint16 objIdx, const int8 *ptr, SeqListElement &ele
return 1;
}
-/*!
+/**
* Permutates the overlay list into a different order according to some logic.
- * \todo Check this function for correctness (Wasn't very easy to reverse engineer so there may be errors)
+ * @todo Check this function for correctness (Wasn't very easy to reverse engineer so there may be errors)
*/
void resetGfxEntityEntry(uint16 objIdx) {
Common::List<overlay>::iterator it, bObjsCutPoint;