mirror of
https://github.com/libretro/scummvm.git
synced 2025-02-26 14:27:14 +00:00
fix warnings
svn-id: r12504
This commit is contained in:
parent
aa0ad9b491
commit
2c3dd03d26
@ -84,7 +84,7 @@ Memory *FontRenderer::makeTextSprite(uint8 *sentence, uint16 maxWidth, uint8 pen
|
||||
|
||||
// allocate memory for array of lineInfo structures
|
||||
|
||||
line = _vm->_memory->allocMemory(MAX_LINES * sizeof(LineInfo), MEM_locked, UID_temp);
|
||||
line = _vm->_memory->allocMemory(MAX_LINES * sizeof(LineInfo), MEM_locked, (uint32)UID_temp);
|
||||
|
||||
// get details of sentence breakdown into array of LineInfo structures
|
||||
// and get the no of lines involved
|
||||
@ -210,7 +210,7 @@ Memory *FontRenderer::buildTextSprite(uint8 *sentence, uint32 fontRes, uint8 pen
|
||||
|
||||
// allocate memory for sprite, and lock it ready for use
|
||||
// NB. 'textSprite' is the given pointer to the handle to be used
|
||||
textSprite = _vm->_memory->allocMemory(sizeof(FrameHeader) + sizeOfSprite, MEM_locked, UID_text_sprite);
|
||||
textSprite = _vm->_memory->allocMemory(sizeof(FrameHeader) + sizeOfSprite, MEM_locked, (uint32)UID_text_sprite);
|
||||
|
||||
// the handle (*textSprite) now points to UNMOVABLE memory block
|
||||
// set up the frame header
|
||||
|
@ -72,7 +72,7 @@ MemoryManager::MemoryManager(Sword2Engine *vm) : _vm(vm) {
|
||||
_memList[0].size = _totalFreeMemory;
|
||||
_memList[0].parent = -1; // we are base - for now
|
||||
_memList[0].child = -1; // we are the end as well
|
||||
_memList[0].uid = UID_memman; // init id
|
||||
_memList[0].uid = (uint32)UID_memman; // init id
|
||||
|
||||
_baseMemBlock = 0; // for now
|
||||
}
|
||||
@ -205,7 +205,7 @@ Memory *MemoryManager::lowLevelAlloc(uint32 size, uint32 type, uint32 unique_id)
|
||||
}
|
||||
|
||||
_memList[spawn].state = MEM_free; // new block is free
|
||||
_memList[spawn].uid = UID_memman; // a memman created bloc
|
||||
_memList[spawn].uid = (uint32)UID_memman; // a memman created bloc
|
||||
|
||||
// size of the existing parent free block minus the size of the new
|
||||
// space Talloc'ed.
|
||||
@ -252,7 +252,7 @@ void MemoryManager::freeMemory(Memory *block) {
|
||||
// once you've done this the memory may be recycled
|
||||
|
||||
block->state = MEM_free;
|
||||
block->uid = UID_memman; // belongs to the memory manager again
|
||||
block->uid = (uint32)UID_memman; // belongs to the memory manager again
|
||||
|
||||
#ifdef MEMDEBUG
|
||||
debugMemory();
|
||||
|
@ -82,7 +82,7 @@ ResourceManager::ResourceManager(Sword2Engine *vm) {
|
||||
end = file.size();
|
||||
|
||||
//get some space for the incoming resource file - soon to be trashed
|
||||
temp = _vm->_memory->allocMemory(end, MEM_locked, UID_temp);
|
||||
temp = _vm->_memory->allocMemory(end, MEM_locked, (uint32)UID_temp);
|
||||
|
||||
if (file.read(temp->ad, end) != end) {
|
||||
file.close();
|
||||
|
@ -106,7 +106,7 @@ void Router::allocateRouteMem(void) {
|
||||
if (_routeSlots[slotNo])
|
||||
freeRouteMem();
|
||||
|
||||
_routeSlots[slotNo] = _vm->_memory->allocMemory(sizeof(WalkData) * O_WALKANIM_SIZE, MEM_locked, UID_walk_anim);
|
||||
_routeSlots[slotNo] = _vm->_memory->allocMemory(sizeof(WalkData) * O_WALKANIM_SIZE, MEM_locked, (uint32)UID_walk_anim);
|
||||
|
||||
// 12000 bytes were used for this in Sword1 mega compacts, based on
|
||||
// 20 bytes per 'WalkData' frame
|
||||
|
@ -94,7 +94,7 @@ uint32 Sword2Engine::saveGame(uint16 slotNo, uint8 *desc) {
|
||||
// allocate the savegame buffer
|
||||
|
||||
bufferSize = findBufferSize();
|
||||
saveBufferMem = _memory->allocMemory(bufferSize, MEM_locked, UID_savegame_buffer);
|
||||
saveBufferMem = _memory->allocMemory(bufferSize, MEM_locked, (uint32)UID_savegame_buffer);
|
||||
|
||||
fillSaveBuffer(saveBufferMem, bufferSize, desc);
|
||||
|
||||
@ -224,7 +224,7 @@ uint32 Sword2Engine::restoreGame(uint16 slotNo) {
|
||||
// allocate the savegame buffer
|
||||
|
||||
bufferSize = findBufferSize();
|
||||
saveBufferMem = _memory->allocMemory(bufferSize, MEM_locked, UID_savegame_buffer);
|
||||
saveBufferMem = _memory->allocMemory(bufferSize, MEM_locked, (uint32)UID_savegame_buffer);
|
||||
|
||||
// read the savegame file into our buffer
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user