diff options
Diffstat (limited to 'backends/platform')
367 files changed, 4264 insertions, 1684 deletions
diff --git a/backends/platform/android/android.cpp b/backends/platform/android/android.cpp index 5e3d1d0db6..3ff1b939ef 100644 --- a/backends/platform/android/android.cpp +++ b/backends/platform/android/android.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/android/android.h b/backends/platform/android/android.h index 704ce12f60..28016f5e3e 100644 --- a/backends/platform/android/android.h +++ b/backends/platform/android/android.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/android/android.mk b/backends/platform/android/android.mk index 915bf8ac60..7c4fe01d54 100644 --- a/backends/platform/android/android.mk +++ b/backends/platform/android/android.mk @@ -7,6 +7,7 @@ ANDROID_PLUGIN_VERSIONCODE = 6 JAVA_FILES = \ ScummVM.java \ ScummVMEvents.java \ + ScummVMEventsHoneycomb.java \ ScummVMApplication.java \ ScummVMActivity.java \ EditableSurfaceView.java \ diff --git a/backends/platform/android/asset-archive.cpp b/backends/platform/android/asset-archive.cpp index da378fb082..52c2c084bd 100644 --- a/backends/platform/android/asset-archive.cpp +++ b/backends/platform/android/asset-archive.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/android/asset-archive.h b/backends/platform/android/asset-archive.h index c5e43555e0..6a0033d24e 100644 --- a/backends/platform/android/asset-archive.h +++ b/backends/platform/android/asset-archive.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/android/events.cpp b/backends/platform/android/events.cpp index 5c42db9347..c60626ec36 100644 --- a/backends/platform/android/events.cpp +++ b/backends/platform/android/events.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/android/gfx.cpp b/backends/platform/android/gfx.cpp index 882dcff9a4..d7713f99d8 100644 --- a/backends/platform/android/gfx.cpp +++ b/backends/platform/android/gfx.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. @@ -94,6 +94,7 @@ Common::List<Graphics::PixelFormat> OSystem_Android::getSupportedFormats() const Common::List<Graphics::PixelFormat> res; res.push_back(GLES565Texture::pixelFormat()); res.push_back(GLES5551Texture::pixelFormat()); + res.push_back(GLES8888Texture::pixelFormat()); res.push_back(GLES4444Texture::pixelFormat()); res.push_back(Graphics::PixelFormat::createFormatCLUT8()); @@ -147,6 +148,8 @@ void OSystem_Android::initTexture(GLESBaseTexture **texture, *texture = new GLES565Texture(); else if (format_new == GLES5551Texture::pixelFormat()) *texture = new GLES5551Texture(); + else if (format_new == GLES8888Texture::pixelFormat()) + *texture = new GLES8888Texture(); else if (format_new == GLES4444Texture::pixelFormat()) *texture = new GLES4444Texture(); else { @@ -233,7 +236,7 @@ void OSystem_Android::initViewport() { GLCALL(glHint(GL_PERSPECTIVE_CORRECTION_HINT, GL_FASTEST)); GLCALL(glEnable(GL_BLEND)); - GLCALL(glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA)); + GLCALL(glBlendFunc(GL_ONE, GL_ONE_MINUS_SRC_ALPHA)); GLCALL(glEnableClientState(GL_VERTEX_ARRAY)); GLCALL(glEnableClientState(GL_TEXTURE_COORD_ARRAY)); @@ -726,7 +729,7 @@ void OSystem_Android::setMouseCursor(const void *buf, uint w, uint h, _mouse_keycolor = keycolor; p = _mouse_texture_palette->palette() + _mouse_keycolor * 2; - WRITE_UINT16(p, READ_UINT16(p) & ~1); + WRITE_UINT16(p, 0); } if (w == 0 || h == 0) @@ -752,12 +755,12 @@ void OSystem_Android::setMouseCursor(const void *buf, uint w, uint h, return; } - uint16 *s = (uint16 *)buf; + const uint16 *s = (const uint16 *)buf; uint16 *d = (uint16 *)tmp; for (uint16 y = 0; y < h; ++y, d += pitch / 2 - w) for (uint16 x = 0; x < w; ++x, d++) - if (*s++ != (keycolor & 0xffff)) - *d |= 1; + if (*s++ == (keycolor & 0xffff)) + *d = 0; _mouse_texture->updateBuffer(0, 0, w, h, tmp, pitch); @@ -779,7 +782,7 @@ void OSystem_Android::setCursorPaletteInternal(const byte *colors, WRITE_UINT16(p, pf.RGBToColor(colors[0], colors[1], colors[2])); p = _mouse_texture_palette->palette() + _mouse_keycolor * 2; - WRITE_UINT16(p, READ_UINT16(p) & ~1); + WRITE_UINT16(p, 0); } void OSystem_Android::setCursorPalette(const byte *colors, @@ -821,7 +824,7 @@ void OSystem_Android::disableCursorPalette() { } byte *p = _mouse_texture_palette->palette() + _mouse_keycolor * 2; - WRITE_UINT16(p, READ_UINT16(p) & ~1); + WRITE_UINT16(p, 0); } } diff --git a/backends/platform/android/jni.cpp b/backends/platform/android/jni.cpp index 2b738dd63f..764c84ce1c 100644 --- a/backends/platform/android/jni.cpp +++ b/backends/platform/android/jni.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/android/jni.h b/backends/platform/android/jni.h index 52698e0f35..326869b1ee 100644 --- a/backends/platform/android/jni.h +++ b/backends/platform/android/jni.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/android/org/scummvm/scummvm/ScummVM.java b/backends/platform/android/org/scummvm/scummvm/ScummVM.java index 3a25b54eeb..5047502e61 100644 --- a/backends/platform/android/org/scummvm/scummvm/ScummVM.java +++ b/backends/platform/android/org/scummvm/scummvm/ScummVM.java @@ -86,13 +86,15 @@ public abstract class ScummVM implements SurfaceHolder.Callback, Runnable { Log.d(LOG_TAG, String.format("surfaceChanged: %dx%d (%d)", width, height, format)); + // store values for the native code + // make sure to do it before notifying the lock + // as it leads to a race condition otherwise + setSurface(width, height); + synchronized(_sem_surface) { _surface_holder = holder; _sem_surface.notifyAll(); } - - // store values for the native code - setSurface(width, height); } // SurfaceHolder callback diff --git a/backends/platform/android/org/scummvm/scummvm/ScummVMActivity.java b/backends/platform/android/org/scummvm/scummvm/ScummVMActivity.java index 5d041dafd2..5964d5bfde 100644 --- a/backends/platform/android/org/scummvm/scummvm/ScummVMActivity.java +++ b/backends/platform/android/org/scummvm/scummvm/ScummVMActivity.java @@ -4,6 +4,7 @@ import android.app.Activity; import android.app.AlertDialog; import android.content.DialogInterface; import android.media.AudioManager; +import android.os.Build; import android.os.Bundle; import android.os.Environment; import android.util.DisplayMetrics; @@ -169,7 +170,14 @@ public class ScummVMActivity extends Activity { _mouseHelper.attach(main_surface); } - _events = new ScummVMEvents(this, _scummvm, _mouseHelper); + if (Build.VERSION.SDK_INT < Build.VERSION_CODES.HONEYCOMB_MR1) + { + _events = new ScummVMEvents(this, _scummvm, _mouseHelper); + } + else + { + _events = new ScummVMEventsHoneycomb(this, _scummvm, _mouseHelper); + } main_surface.setOnKeyListener(_events); main_surface.setOnTouchListener(_events); diff --git a/backends/platform/android/org/scummvm/scummvm/ScummVMEvents.java b/backends/platform/android/org/scummvm/scummvm/ScummVMEvents.java index 702215341b..32c65d3395 100644 --- a/backends/platform/android/org/scummvm/scummvm/ScummVMEvents.java +++ b/backends/platform/android/org/scummvm/scummvm/ScummVMEvents.java @@ -68,15 +68,7 @@ public class ScummVMEvents implements return true; } - public boolean onGenericMotionEvent(final MotionEvent e) { - if((e.getSource() & InputDevice.SOURCE_CLASS_JOYSTICK) != 0) { - _scummvm.pushEvent(JE_JOYSTICK, e.getAction(), - (int)(e.getAxisValue(MotionEvent.AXIS_X)*100), - (int)(e.getAxisValue(MotionEvent.AXIS_Y)*100), - 0, 0); - return true; - } - + public boolean onGenericMotionEvent(MotionEvent e) { return false; } diff --git a/backends/platform/android/org/scummvm/scummvm/ScummVMEventsHoneycomb.java b/backends/platform/android/org/scummvm/scummvm/ScummVMEventsHoneycomb.java new file mode 100644 index 0000000000..ab85429040 --- /dev/null +++ b/backends/platform/android/org/scummvm/scummvm/ScummVMEventsHoneycomb.java @@ -0,0 +1,25 @@ +package org.scummvm.scummvm; + +import android.content.Context; +import android.view.MotionEvent; +import android.view.InputDevice; + +public class ScummVMEventsHoneycomb extends ScummVMEvents { + + public ScummVMEventsHoneycomb(Context context, ScummVM scummvm, MouseHelper mouseHelper) { + super(context, scummvm, mouseHelper); + } + + @Override + public boolean onGenericMotionEvent(MotionEvent e) { + if((e.getSource() & InputDevice.SOURCE_CLASS_JOYSTICK) != 0) { + _scummvm.pushEvent(JE_JOYSTICK, e.getAction(), + (int)(e.getAxisValue(MotionEvent.AXIS_X)*100), + (int)(e.getAxisValue(MotionEvent.AXIS_Y)*100), + 0, 0); + return true; + } + + return false; + } +} diff --git a/backends/platform/android/texture.cpp b/backends/platform/android/texture.cpp index cc41c0d8a6..165396b82b 100644 --- a/backends/platform/android/texture.cpp +++ b/backends/platform/android/texture.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. @@ -259,11 +259,15 @@ void GLESTexture::fillBuffer(uint32 color) { assert(_surface.getPixels()); if (_pixelFormat.bytesPerPixel == 1 || - ((color & 0xff) == ((color >> 8) & 0xff))) + (_pixelFormat.bytesPerPixel == 2 && + ((color & 0xff) == ((color >> 8) & 0xff)))) memset(_pixels, color & 0xff, _surface.pitch * _surface.h); - else - Common::fill(_pixels, _pixels + _surface.pitch * _surface.h, + else if (_pixelFormat.bytesPerPixel == 2) + Common::fill((uint16 *)_pixels, (uint16 *)(_pixels + _surface.pitch * _surface.h), (uint16)color); + else + Common::fill((uint32 *)_pixels, (uint32 *)(_pixels + _surface.pitch * _surface.h), + color); setDirty(); } @@ -334,6 +338,13 @@ GLES565Texture::GLES565Texture() : GLES565Texture::~GLES565Texture() { } +GLES8888Texture::GLES8888Texture() : + GLESTexture(GL_RGBA, GL_UNSIGNED_BYTE, pixelFormat()) { +} + +GLES8888Texture::~GLES8888Texture() { +} + GLESFakePaletteTexture::GLESFakePaletteTexture(GLenum glFormat, GLenum glType, Graphics::PixelFormat pixelFormat) : GLESBaseTexture(glFormat, glType, pixelFormat), diff --git a/backends/platform/android/texture.h b/backends/platform/android/texture.h index 4307b5a1bc..4b05dfd5d4 100644 --- a/backends/platform/android/texture.h +++ b/backends/platform/android/texture.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. @@ -224,6 +224,18 @@ public: } }; +// RGBA8888 texture +class GLES8888Texture : public GLESTexture { +public: + GLES8888Texture(); + virtual ~GLES8888Texture(); + + static inline Graphics::PixelFormat pixelFormat() { + // We assume LE since all Android platforms are LE. + return Graphics::PixelFormat(4, 8, 8, 8, 8, 0, 8, 16, 24); + } +}; + class GLESFakePaletteTexture : public GLESBaseTexture { protected: GLESFakePaletteTexture(GLenum glFormat, GLenum glType, diff --git a/backends/platform/dc/DCLauncherDialog.h b/backends/platform/dc/DCLauncherDialog.h index 519524222f..5131482cb6 100644 --- a/backends/platform/dc/DCLauncherDialog.h +++ b/backends/platform/dc/DCLauncherDialog.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/dc/audio.cpp b/backends/platform/dc/audio.cpp index 4f01531486..4759ddb799 100644 --- a/backends/platform/dc/audio.cpp +++ b/backends/platform/dc/audio.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/dc/dc-fs.cpp b/backends/platform/dc/dc-fs.cpp index 36f5a1465c..77fe4143dd 100644 --- a/backends/platform/dc/dc-fs.cpp +++ b/backends/platform/dc/dc-fs.cpp @@ -17,6 +17,7 @@ * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * */ #define FORBIDDEN_SYMBOL_ALLOW_ALL @@ -27,7 +28,9 @@ #include <ronin/cdfs.h> #include <stdio.h> +#define usleep usleep_unistd #include <unistd.h> +#undef usleep /** * Implementation of the ScummVM file system API based on Ronin. diff --git a/backends/platform/dc/dc.h b/backends/platform/dc/dc.h index d62ced02e1..d8ab549c3a 100644 --- a/backends/platform/dc/dc.h +++ b/backends/platform/dc/dc.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. @@ -43,7 +43,9 @@ class Interactive public: virtual int key(int k, byte &shiftFlags) = 0; virtual void mouse(int x, int y) = 0; + virtual ~Interactive() = 0; }; +inline Interactive::~Interactive() { } #include "softkbd.h" diff --git a/backends/platform/dc/dcloader.cpp b/backends/platform/dc/dcloader.cpp index 56193c282a..bc5e3a733b 100644 --- a/backends/platform/dc/dcloader.cpp +++ b/backends/platform/dc/dcloader.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/dc/dcloader.h b/backends/platform/dc/dcloader.h index 1782467acd..074ae7aa29 100644 --- a/backends/platform/dc/dcloader.h +++ b/backends/platform/dc/dcloader.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/dc/dcmain.cpp b/backends/platform/dc/dcmain.cpp index bec1fdae3a..eede796991 100644 --- a/backends/platform/dc/dcmain.cpp +++ b/backends/platform/dc/dcmain.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. @@ -79,13 +79,14 @@ static bool find_track(int track, int &first_sec, int &last_sec) if (first < 1 || last > 99 || first > last) return false; for (i=first; i<=last; i++) - if (!(TOC_CTRL(toc->entry[i-1])&4)) + if (!(TOC_CTRL(toc->entry[i-1])&4)) { if (track==1) { first_sec = TOC_LBA(toc->entry[i-1]); last_sec = TOC_LBA(toc->entry[i]); return true; } else --track; + } return false; } @@ -281,7 +282,7 @@ namespace DC_Flash { if((r = syscall_read_flash(info[0] + (bmb++ << 6), bm, 64))<0) return r; } - if(!(bm[(b>>3)&63] & (0x80>>(b&7)))) + if(!(bm[(b>>3)&63] & (0x80>>(b&7)))) { if((r = syscall_read_flash(info[0] + ((b+1) << 6), buf, 64))<0) return r; else if((s=*(unsigned short *)(buf+0)) == sec && @@ -289,6 +290,7 @@ namespace DC_Flash { memcpy(dst+(s-sec)*60, buf+2, 60); got=1; } + } } return got; } diff --git a/backends/platform/dc/display.cpp b/backends/platform/dc/display.cpp index 54ee6000ed..1785c3c416 100644 --- a/backends/platform/dc/display.cpp +++ b/backends/platform/dc/display.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/dc/icon.cpp b/backends/platform/dc/icon.cpp index cf7afc82e0..ba621883a9 100644 --- a/backends/platform/dc/icon.cpp +++ b/backends/platform/dc/icon.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. @@ -47,8 +47,8 @@ void Icon::create_vmicon(void *buffer) void Icon::create_texture() { - static char tt[16] = { 0, 1, 4, 5, 16, 17, 20, 21, - 64, 65, 68, 69, 80, 81, 84, 85 }; + static unsigned char tt[16] = { 0, 1, 4, 5, 16, 17, 20, 21, + 64, 65, 68, 69, 80, 81, 84, 85 }; unsigned short *tex = (unsigned short *)ta_txalloc(512); unsigned short *linebase; unsigned char *src = bitmap+sizeof(bitmap)-17; diff --git a/backends/platform/dc/icon.h b/backends/platform/dc/icon.h index e412e67a84..253455fe30 100644 --- a/backends/platform/dc/icon.h +++ b/backends/platform/dc/icon.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/dc/input.cpp b/backends/platform/dc/input.cpp index 7b21c76efa..a69bb3b78f 100644 --- a/backends/platform/dc/input.cpp +++ b/backends/platform/dc/input.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. @@ -50,10 +50,10 @@ int handleInput(struct mapledev *pad, int &mouse_x, int &mouse_y, else if (!(buttons & 512)) newkey = ' '; else if (!(buttons & 1024)) newkey = numpadmap[(buttons>>4)&15]; - if (!(buttons & 128)) if (inter) newkey = 1001; else mouse_x++; - if (!(buttons & 64)) if (inter) newkey = 1002; else mouse_x--; - if (!(buttons & 32)) if (inter) newkey = 1003; else mouse_y++; - if (!(buttons & 16)) if (inter) newkey = 1004; else mouse_y--; + if (!(buttons & 128)) { if (inter) newkey = 1001; else mouse_x++; } + if (!(buttons & 64)) { if (inter) newkey = 1002; else mouse_x--; } + if (!(buttons & 32)) { if (inter) newkey = 1003; else mouse_y++; } + if (!(buttons & 16)) { if (inter) newkey = 1004; else mouse_y--; } mouse_x += ((int)pad->cond.controller.joyx-128)>>4; mouse_y += ((int)pad->cond.controller.joyy-128)>>4; @@ -157,7 +157,7 @@ int handleInput(struct mapledev *pad, int &mouse_x, int &mouse_y, return -Common::EVENT_RBUTTONUP; } - if (mouse_wheel != lastwheel) + if (mouse_wheel != lastwheel) { if (((int8)(mouse_wheel - lastwheel)) > 0) { lastwheel++; return -Common::EVENT_WHEELDOWN; @@ -165,6 +165,7 @@ int handleInput(struct mapledev *pad, int &mouse_x, int &mouse_y, --lastwheel; return -Common::EVENT_WHEELUP; } + } if (newkey && inter && newkey != lastkey) { int transkey = inter->key(newkey, shiftFlags); diff --git a/backends/platform/dc/ip.txt.in b/backends/platform/dc/ip.txt.in index 23424e0950..539d29dd1e 100644 --- a/backends/platform/dc/ip.txt.in +++ b/backends/platform/dc/ip.txt.in @@ -7,5 +7,5 @@ Product No : T0000 Version : @VERSION@ Release Date : @DATE@ Boot Filename : SCUMMVM.BIN -SW Maker Name : The ScummVM team +SW Maker Name : The ScummVM Team Game Title : ScummVM diff --git a/backends/platform/dc/label.cpp b/backends/platform/dc/label.cpp index 5db031958f..46bff0db11 100644 --- a/backends/platform/dc/label.cpp +++ b/backends/platform/dc/label.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/dc/label.h b/backends/platform/dc/label.h index 6b96175d29..2a7e7b35ea 100644 --- a/backends/platform/dc/label.h +++ b/backends/platform/dc/label.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/dc/plugins.cpp b/backends/platform/dc/plugins.cpp index 2942a4f155..93689157f3 100644 --- a/backends/platform/dc/plugins.cpp +++ b/backends/platform/dc/plugins.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/dc/portdefs.h b/backends/platform/dc/portdefs.h index 1f5c8f566a..191bbea09c 100644 --- a/backends/platform/dc/portdefs.h +++ b/backends/platform/dc/portdefs.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/dc/selector.cpp b/backends/platform/dc/selector.cpp index 4026c7dde6..6717ca494b 100644 --- a/backends/platform/dc/selector.cpp +++ b/backends/platform/dc/selector.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/dc/softkbd.cpp b/backends/platform/dc/softkbd.cpp index 076f826d1c..19f7b409a1 100644 --- a/backends/platform/dc/softkbd.cpp +++ b/backends/platform/dc/softkbd.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/dc/softkbd.h b/backends/platform/dc/softkbd.h index 8f87d12baa..c7c4357a44 100644 --- a/backends/platform/dc/softkbd.h +++ b/backends/platform/dc/softkbd.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. @@ -40,6 +40,7 @@ class SoftKeyboard : public Interactive public: SoftKeyboard(const OSystem_Dreamcast *os); + virtual ~SoftKeyboard() {} void draw(float x, float y, int transp = 0); int key(int k, byte &shiftFlags); diff --git a/backends/platform/dc/time.cpp b/backends/platform/dc/time.cpp index 1e5f44ec85..ada53bf755 100644 --- a/backends/platform/dc/time.cpp +++ b/backends/platform/dc/time.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/dc/vmsave.cpp b/backends/platform/dc/vmsave.cpp index ba3b787942..5f5cdff24f 100644 --- a/backends/platform/dc/vmsave.cpp +++ b/backends/platform/dc/vmsave.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/dingux/dingux.cpp b/backends/platform/dingux/dingux.cpp index 674c2ea780..2f11dd31ad 100644 --- a/backends/platform/dingux/dingux.cpp +++ b/backends/platform/dingux/dingux.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/dingux/dingux.h b/backends/platform/dingux/dingux.h index 2a07a8a46a..add74fa039 100644 --- a/backends/platform/dingux/dingux.h +++ b/backends/platform/dingux/dingux.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/dingux/main.cpp b/backends/platform/dingux/main.cpp index 4fc67d874f..98b5058c06 100644 --- a/backends/platform/dingux/main.cpp +++ b/backends/platform/dingux/main.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/ds/arm7/source/main.cpp b/backends/platform/ds/arm7/source/main.cpp index 6e714b22fa..c4a22b8f68 100644 --- a/backends/platform/ds/arm7/source/main.cpp +++ b/backends/platform/ds/arm7/source/main.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/ds/arm9/source/blitters.cpp b/backends/platform/ds/arm9/source/blitters.cpp index ef2dc9c3b8..44de0ed0f6 100644 --- a/backends/platform/ds/arm9/source/blitters.cpp +++ b/backends/platform/ds/arm9/source/blitters.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/ds/arm9/source/blitters.h b/backends/platform/ds/arm9/source/blitters.h index de6e218778..602cde4755 100644 --- a/backends/platform/ds/arm9/source/blitters.h +++ b/backends/platform/ds/arm9/source/blitters.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/ds/arm9/source/cdaudio.cpp b/backends/platform/ds/arm9/source/cdaudio.cpp index 277e1f4ae7..c963f4d8bd 100644 --- a/backends/platform/ds/arm9/source/cdaudio.cpp +++ b/backends/platform/ds/arm9/source/cdaudio.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/ds/arm9/source/cdaudio.h b/backends/platform/ds/arm9/source/cdaudio.h index 8a0e0c5174..77766bae8e 100644 --- a/backends/platform/ds/arm9/source/cdaudio.h +++ b/backends/platform/ds/arm9/source/cdaudio.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/ds/arm9/source/dsmain.cpp b/backends/platform/ds/arm9/source/dsmain.cpp index 9dc66e80d7..b7c9c108a6 100644 --- a/backends/platform/ds/arm9/source/dsmain.cpp +++ b/backends/platform/ds/arm9/source/dsmain.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/ds/arm9/source/dsmain.h b/backends/platform/ds/arm9/source/dsmain.h index 5e91fae13a..fec97d878e 100644 --- a/backends/platform/ds/arm9/source/dsmain.h +++ b/backends/platform/ds/arm9/source/dsmain.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/ds/arm9/source/dsoptions.cpp b/backends/platform/ds/arm9/source/dsoptions.cpp index ac552bd826..733592e958 100644 --- a/backends/platform/ds/arm9/source/dsoptions.cpp +++ b/backends/platform/ds/arm9/source/dsoptions.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/ds/arm9/source/dsoptions.h b/backends/platform/ds/arm9/source/dsoptions.h index 9949b8b7d2..35e30a87d5 100644 --- a/backends/platform/ds/arm9/source/dsoptions.h +++ b/backends/platform/ds/arm9/source/dsoptions.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/ds/arm9/source/gbampsave.cpp b/backends/platform/ds/arm9/source/gbampsave.cpp index 3192e2d277..ef6091e2a2 100644 --- a/backends/platform/ds/arm9/source/gbampsave.cpp +++ b/backends/platform/ds/arm9/source/gbampsave.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/ds/arm9/source/gbampsave.h b/backends/platform/ds/arm9/source/gbampsave.h index 0d9d9aca8c..d86db2ec70 100644 --- a/backends/platform/ds/arm9/source/gbampsave.h +++ b/backends/platform/ds/arm9/source/gbampsave.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/ds/arm9/source/keys.h b/backends/platform/ds/arm9/source/keys.h index 9d6b41c746..d118b37f28 100644 --- a/backends/platform/ds/arm9/source/keys.h +++ b/backends/platform/ds/arm9/source/keys.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/ds/arm9/source/osystem_ds.cpp b/backends/platform/ds/arm9/source/osystem_ds.cpp index f109983fbc..c53f57523d 100644 --- a/backends/platform/ds/arm9/source/osystem_ds.cpp +++ b/backends/platform/ds/arm9/source/osystem_ds.cpp @@ -16,7 +16,8 @@ * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * */ diff --git a/backends/platform/ds/arm9/source/osystem_ds.h b/backends/platform/ds/arm9/source/osystem_ds.h index 4550e22b2c..f4dbac66f7 100644 --- a/backends/platform/ds/arm9/source/osystem_ds.h +++ b/backends/platform/ds/arm9/source/osystem_ds.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/ds/arm9/source/portdefs.h b/backends/platform/ds/arm9/source/portdefs.h index e40849a513..0a20c459ab 100644 --- a/backends/platform/ds/arm9/source/portdefs.h +++ b/backends/platform/ds/arm9/source/portdefs.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/ds/arm9/source/scummhelp.cpp b/backends/platform/ds/arm9/source/scummhelp.cpp index a3fdaacfaa..a0fb9bd0ab 100644 --- a/backends/platform/ds/arm9/source/scummhelp.cpp +++ b/backends/platform/ds/arm9/source/scummhelp.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/ds/arm9/source/scummhelp.h b/backends/platform/ds/arm9/source/scummhelp.h index 41fc8f9c91..4e8d709c4f 100644 --- a/backends/platform/ds/arm9/source/scummhelp.h +++ b/backends/platform/ds/arm9/source/scummhelp.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/ds/arm9/source/touchkeyboard.cpp b/backends/platform/ds/arm9/source/touchkeyboard.cpp index 77da9cc22a..30c46dbf06 100644 --- a/backends/platform/ds/arm9/source/touchkeyboard.cpp +++ b/backends/platform/ds/arm9/source/touchkeyboard.cpp @@ -16,9 +16,10 @@ * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. * */ + #include <nds.h> #include "NDS/scummvm_ipc.h" #include "touchkeyboard.h" diff --git a/backends/platform/ds/arm9/source/touchkeyboard.h b/backends/platform/ds/arm9/source/touchkeyboard.h index dc20601023..f64d531b82 100644 --- a/backends/platform/ds/arm9/source/touchkeyboard.h +++ b/backends/platform/ds/arm9/source/touchkeyboard.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/ds/arm9/source/wordcompletion.cpp b/backends/platform/ds/arm9/source/wordcompletion.cpp index 51f93df7ff..36fa31247c 100644 --- a/backends/platform/ds/arm9/source/wordcompletion.cpp +++ b/backends/platform/ds/arm9/source/wordcompletion.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/ds/arm9/source/wordcompletion.h b/backends/platform/ds/arm9/source/wordcompletion.h index c355d29293..d6e7224186 100644 --- a/backends/platform/ds/arm9/source/wordcompletion.h +++ b/backends/platform/ds/arm9/source/wordcompletion.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/ds/arm9/source/zipreader.cpp b/backends/platform/ds/arm9/source/zipreader.cpp index 49552a86b2..0de2b0c981 100644 --- a/backends/platform/ds/arm9/source/zipreader.cpp +++ b/backends/platform/ds/arm9/source/zipreader.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/ds/arm9/source/zipreader.h b/backends/platform/ds/arm9/source/zipreader.h index 70f000eb4b..0078919d5f 100644 --- a/backends/platform/ds/arm9/source/zipreader.h +++ b/backends/platform/ds/arm9/source/zipreader.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/ds/commoninclude/NDS/scummvm_ipc.h b/backends/platform/ds/commoninclude/NDS/scummvm_ipc.h index 360b7b03dc..540348ca0b 100644 --- a/backends/platform/ds/commoninclude/NDS/scummvm_ipc.h +++ b/backends/platform/ds/commoninclude/NDS/scummvm_ipc.h @@ -17,6 +17,7 @@ * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * */ #ifndef SCUMMVM_IPC_INCLUDE diff --git a/backends/platform/gph/gph-backend.cpp b/backends/platform/gph/gph-backend.cpp index 485780b472..d033191d54 100644 --- a/backends/platform/gph/gph-backend.cpp +++ b/backends/platform/gph/gph-backend.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. @@ -172,7 +172,7 @@ void OSystem_GPH::initSDL() { // Check if SDL has not been initialized if (!_initedSDL) { - uint32 sdlFlags = SDL_INIT_EVENTTHREAD; + uint32 sdlFlags = SDL_INIT_EVENTTHREAD | SDL_INIT_VIDEO; if (ConfMan.hasKey("disable_sdl_parachute")) sdlFlags |= SDL_INIT_NOPARACHUTE; diff --git a/backends/platform/gph/gph-hw.cpp b/backends/platform/gph/gph-hw.cpp index cde50dc6b4..7b004f1739 100644 --- a/backends/platform/gph/gph-hw.cpp +++ b/backends/platform/gph/gph-hw.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/gph/gph-hw.h b/backends/platform/gph/gph-hw.h index f9584ca37e..c6d0094cf1 100644 --- a/backends/platform/gph/gph-hw.h +++ b/backends/platform/gph/gph-hw.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/gph/gph-main.cpp b/backends/platform/gph/gph-main.cpp index 876de0f358..5fce37179e 100644 --- a/backends/platform/gph/gph-main.cpp +++ b/backends/platform/gph/gph-main.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/gph/gph.h b/backends/platform/gph/gph.h index 90a798154f..d7004f1582 100644 --- a/backends/platform/gph/gph.h +++ b/backends/platform/gph/gph.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/iphone/iphone_common.h b/backends/platform/iphone/iphone_common.h index 9c45a240cb..59dca84b85 100644 --- a/backends/platform/iphone/iphone_common.h +++ b/backends/platform/iphone/iphone_common.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/iphone/iphone_keyboard.h b/backends/platform/iphone/iphone_keyboard.h index 2d1238c92f..d54df9ac96 100644 --- a/backends/platform/iphone/iphone_keyboard.h +++ b/backends/platform/iphone/iphone_keyboard.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/iphone/iphone_keyboard.mm b/backends/platform/iphone/iphone_keyboard.mm index b00930ab31..39d68aff81 100644 --- a/backends/platform/iphone/iphone_keyboard.mm +++ b/backends/platform/iphone/iphone_keyboard.mm @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. @@ -39,7 +39,7 @@ @implementation TextInputHandler -- (id)initWithKeyboard:(SoftKeyboard *)keyboard; { +- (id)initWithKeyboard:(SoftKeyboard *)keyboard { self = [super initWithFrame:CGRectMake(0.0f, 0.0f, 0.0f, 0.0f)]; softKeyboard = keyboard; diff --git a/backends/platform/iphone/iphone_main.mm b/backends/platform/iphone/iphone_main.mm index e76ffe866e..3707f10a29 100644 --- a/backends/platform/iphone/iphone_main.mm +++ b/backends/platform/iphone/iphone_main.mm @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/iphone/iphone_video.h b/backends/platform/iphone/iphone_video.h index 6b8c25ebcf..7dbf3c57ab 100644 --- a/backends/platform/iphone/iphone_video.h +++ b/backends/platform/iphone/iphone_video.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. @@ -70,6 +70,7 @@ GLfloat _mouseScaleX, _mouseScaleY; int _scaledShakeOffsetY; + CGFloat _contentScaleFactor; UITouch *_firstTouch; UITouch *_secondTouch; diff --git a/backends/platform/iphone/iphone_video.mm b/backends/platform/iphone/iphone_video.mm index f2c1527658..5048b57328 100644 --- a/backends/platform/iphone/iphone_video.mm +++ b/backends/platform/iphone/iphone_video.mm @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. @@ -161,9 +161,23 @@ const char *iPhone_getDocumentsDir() { - (id)initWithFrame:(struct CGRect)frame { self = [super initWithFrame: frame]; + _contentScaleFactor = 1; if ([[UIScreen mainScreen] respondsToSelector:@selector(scale)]) { if ([self respondsToSelector:@selector(setContentScaleFactor:)]) { - [self setContentScaleFactor:[[UIScreen mainScreen] scale]]; + // Horrible and crazy method to get the proper return value of + // scale when the SDK used for building does not know anything + // about the selector scale... + NSMethodSignature *scaleSignature = [UIScreen instanceMethodSignatureForSelector:@selector(scale)]; + NSInvocation *scaleInvocation = [NSInvocation invocationWithMethodSignature:scaleSignature]; + [scaleInvocation setTarget:[UIScreen mainScreen]]; + [scaleInvocation setSelector:@selector(scale)]; + [scaleInvocation invoke]; + + NSInteger returnLength = [[scaleInvocation methodSignature] methodReturnLength]; + if (returnLength == sizeof(CGFloat)) { + [scaleInvocation getReturnValue:&_contentScaleFactor]; + [self setContentScaleFactor:_contentScaleFactor]; + } } } @@ -613,6 +627,11 @@ const char *iPhone_getDocumentsDir() { } - (bool)getMouseCoords:(CGPoint)point eventX:(int *)x eventY:(int *)y { + // We scale the input according to our scale factor to get actual screen + // cooridnates. + point.x *= _contentScaleFactor; + point.y *= _contentScaleFactor; + if (![self convertToRotatedCoords:point result:&point]) return false; diff --git a/backends/platform/iphone/osys_events.cpp b/backends/platform/iphone/osys_events.cpp index 9cfca0836e..95ca25a2d2 100644 --- a/backends/platform/iphone/osys_events.cpp +++ b/backends/platform/iphone/osys_events.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/iphone/osys_main.cpp b/backends/platform/iphone/osys_main.cpp index a814495b80..0ce21b44c1 100644 --- a/backends/platform/iphone/osys_main.cpp +++ b/backends/platform/iphone/osys_main.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/iphone/osys_main.h b/backends/platform/iphone/osys_main.h index 811a8ddb2e..0159eee1be 100644 --- a/backends/platform/iphone/osys_main.h +++ b/backends/platform/iphone/osys_main.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/iphone/osys_sound.cpp b/backends/platform/iphone/osys_sound.cpp index 405543e380..bfee06c6f2 100644 --- a/backends/platform/iphone/osys_sound.cpp +++ b/backends/platform/iphone/osys_sound.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/iphone/osys_video.mm b/backends/platform/iphone/osys_video.mm index ce7f94f5bd..c76f432dda 100644 --- a/backends/platform/iphone/osys_video.mm +++ b/backends/platform/iphone/osys_video.mm @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/linuxmoto/hardwarekeys.cpp b/backends/platform/linuxmoto/hardwarekeys.cpp index e1a5757430..70e55c86c0 100644 --- a/backends/platform/linuxmoto/hardwarekeys.cpp +++ b/backends/platform/linuxmoto/hardwarekeys.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/linuxmoto/linuxmoto-main.cpp b/backends/platform/linuxmoto/linuxmoto-main.cpp index 835ccb03ef..507be9fa95 100644 --- a/backends/platform/linuxmoto/linuxmoto-main.cpp +++ b/backends/platform/linuxmoto/linuxmoto-main.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/linuxmoto/linuxmoto-sdl.cpp b/backends/platform/linuxmoto/linuxmoto-sdl.cpp index 844bd19a83..a0310079de 100644 --- a/backends/platform/linuxmoto/linuxmoto-sdl.cpp +++ b/backends/platform/linuxmoto/linuxmoto-sdl.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/linuxmoto/linuxmoto-sdl.h b/backends/platform/linuxmoto/linuxmoto-sdl.h index 27f4e744bc..b0bf7b4df7 100644 --- a/backends/platform/linuxmoto/linuxmoto-sdl.h +++ b/backends/platform/linuxmoto/linuxmoto-sdl.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/maemo/maemo-common.h b/backends/platform/maemo/maemo-common.h index 0442b9c0ae..6d3c64402a 100644 --- a/backends/platform/maemo/maemo-common.h +++ b/backends/platform/maemo/maemo-common.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/maemo/maemo.cpp b/backends/platform/maemo/maemo.cpp index 6bd229177b..e81a208f7b 100644 --- a/backends/platform/maemo/maemo.cpp +++ b/backends/platform/maemo/maemo.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/maemo/maemo.h b/backends/platform/maemo/maemo.h index 43bc262ade..532a2de08c 100644 --- a/backends/platform/maemo/maemo.h +++ b/backends/platform/maemo/maemo.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/maemo/main.cpp b/backends/platform/maemo/main.cpp index 7e8a316eb5..4735ae30ed 100644 --- a/backends/platform/maemo/main.cpp +++ b/backends/platform/maemo/main.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/n64/framfs_save_manager.cpp b/backends/platform/n64/framfs_save_manager.cpp index 78f5333f2e..de645223e9 100644 --- a/backends/platform/n64/framfs_save_manager.cpp +++ b/backends/platform/n64/framfs_save_manager.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/n64/framfs_save_manager.h b/backends/platform/n64/framfs_save_manager.h index 0a88c8666b..a066854aab 100644 --- a/backends/platform/n64/framfs_save_manager.h +++ b/backends/platform/n64/framfs_save_manager.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/n64/nintendo64.cpp b/backends/platform/n64/nintendo64.cpp index bc416157e6..a3e8c016f4 100644 --- a/backends/platform/n64/nintendo64.cpp +++ b/backends/platform/n64/nintendo64.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/n64/osys_n64.h b/backends/platform/n64/osys_n64.h index 10138b230a..ad49c2981f 100644 --- a/backends/platform/n64/osys_n64.h +++ b/backends/platform/n64/osys_n64.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/n64/osys_n64_base.cpp b/backends/platform/n64/osys_n64_base.cpp index 36e5085764..16eeae5b7e 100644 --- a/backends/platform/n64/osys_n64_base.cpp +++ b/backends/platform/n64/osys_n64_base.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/n64/osys_n64_events.cpp b/backends/platform/n64/osys_n64_events.cpp index c83eb194ac..2aa228cab0 100644 --- a/backends/platform/n64/osys_n64_events.cpp +++ b/backends/platform/n64/osys_n64_events.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/n64/osys_n64_utilities.cpp b/backends/platform/n64/osys_n64_utilities.cpp index f007a1bd25..b3b6d50667 100644 --- a/backends/platform/n64/osys_n64_utilities.cpp +++ b/backends/platform/n64/osys_n64_utilities.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/n64/pakfs_save_manager.cpp b/backends/platform/n64/pakfs_save_manager.cpp index bf2fe8b1bc..5a83dab9d8 100644 --- a/backends/platform/n64/pakfs_save_manager.cpp +++ b/backends/platform/n64/pakfs_save_manager.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/n64/pakfs_save_manager.h b/backends/platform/n64/pakfs_save_manager.h index 6e67fb0f5f..ec66c80b73 100644 --- a/backends/platform/n64/pakfs_save_manager.h +++ b/backends/platform/n64/pakfs_save_manager.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/n64/portdefs.h b/backends/platform/n64/portdefs.h index 10f5ed6488..63ec989a8d 100644 --- a/backends/platform/n64/portdefs.h +++ b/backends/platform/n64/portdefs.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/null/null.cpp b/backends/platform/null/null.cpp index 9e05539799..a5eea06f7a 100644 --- a/backends/platform/null/null.cpp +++ b/backends/platform/null/null.cpp @@ -8,24 +8,35 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. * */ +// We use some stdio.h functionality here thus we need to allow some +// symbols. Alternatively, we could simply allow everything by defining +// FORBIDDEN_SYMBOL_ALLOW_ALL +#define FORBIDDEN_SYMBOL_EXCEPTION_FILE +#define FORBIDDEN_SYMBOL_EXCEPTION_stdout +#define FORBIDDEN_SYMBOL_EXCEPTION_stderr +#define FORBIDDEN_SYMBOL_EXCEPTION_fputs + #include "backends/modular-backend.h" #include "base/main.h" #if defined(USE_NULL_DRIVER) #include "backends/saves/default/default-saves.h" #include "backends/timer/default/default-timer.h" +#include "backends/events/default/default-events.h" +#include "backends/mutex/null/null-mutex.h" +#include "backends/graphics/null/null-graphics.h" #include "audio/mixer_intern.h" #include "common/scummsys.h" @@ -40,13 +51,14 @@ #include "backends/fs/windows/windows-fs-factory.h" #endif -class OSystem_NULL : public ModularBackend { +class OSystem_NULL : public ModularBackend, Common::EventSource { public: OSystem_NULL(); virtual ~OSystem_NULL(); virtual void initBackend(); + virtual Common::EventSource *getDefaultEventSource() { return this; } virtual bool pollEvent(Common::Event &event); virtual uint32 getMillis(bool skipRecord = false); @@ -92,7 +104,7 @@ bool OSystem_NULL::pollEvent(Common::Event &event) { return false; } -uint32 OSystem_NULL::getMillis() { +uint32 OSystem_NULL::getMillis(bool skipRecord) { return 0; } diff --git a/backends/platform/openpandora/op-backend.cpp b/backends/platform/openpandora/op-backend.cpp index 354aa24b24..abe288f5d7 100644 --- a/backends/platform/openpandora/op-backend.cpp +++ b/backends/platform/openpandora/op-backend.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. @@ -160,7 +160,7 @@ void OSystem_OP::initSDL() { // Check if SDL has not been initialized if (!_initedSDL) { - uint32 sdlFlags = SDL_INIT_EVENTTHREAD; + uint32 sdlFlags = SDL_INIT_EVENTTHREAD | SDL_INIT_VIDEO; if (ConfMan.hasKey("disable_sdl_parachute")) sdlFlags |= SDL_INIT_NOPARACHUTE; diff --git a/backends/platform/openpandora/op-main.cpp b/backends/platform/openpandora/op-main.cpp index ebe018f570..99026b89f6 100644 --- a/backends/platform/openpandora/op-main.cpp +++ b/backends/platform/openpandora/op-main.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/openpandora/op-options.cpp b/backends/platform/openpandora/op-options.cpp index 005a76b76c..d2e7860962 100644 --- a/backends/platform/openpandora/op-options.cpp +++ b/backends/platform/openpandora/op-options.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/openpandora/op-options.h b/backends/platform/openpandora/op-options.h index 919d217f4b..8eae420af2 100644 --- a/backends/platform/openpandora/op-options.h +++ b/backends/platform/openpandora/op-options.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/openpandora/op-sdl.h b/backends/platform/openpandora/op-sdl.h index 1eddad5c4a..dd239e58f8 100644 --- a/backends/platform/openpandora/op-sdl.h +++ b/backends/platform/openpandora/op-sdl.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/ps2/DmaPipe.cpp b/backends/platform/ps2/DmaPipe.cpp index a346a67566..a4bcf6299e 100644 --- a/backends/platform/ps2/DmaPipe.cpp +++ b/backends/platform/ps2/DmaPipe.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. @@ -50,7 +50,7 @@ DmaPipe::DmaPipe(uint32 size) { size &= ~0x1F; _buf = (uint64 *)memalign(64, size); _curPipe = 0; - _pipes[0] = new SinglePipe(_buf, size >> 4); + _pipes[0] = new SinglePipe(_buf, size >> 4); _pipes[1] = new SinglePipe(_buf + (size >> 4), size >> 4); // reset DMAC Channel 2 @@ -80,7 +80,7 @@ void DmaPipe::uploadTex(uint32 dest, uint16 bufWidth, uint16 destOfsX, uint16 de *(_pipes[_curPipe]->_chainHead) |= (1 << 28); _pipes[_curPipe]->setGifLoopTag(4); _pipes[_curPipe]->setReg(GPR_BITBLTBUF, GS_SET_DEST_BLTBUF((dest/256) & 0x3fff, (bufWidth/64) & 0x3f, pixelFmt & 0x3f)); - _pipes[_curPipe]->setReg( GPR_TRXPOS, GS_SET_DEST_TRXPOS(destOfsX, destOfsY)); + _pipes[_curPipe]->setReg( GPR_TRXPOS, GS_SET_DEST_TRXPOS(destOfsX, destOfsY)); _pipes[_curPipe]->setReg( GPR_TRXREG, GS_SET_TRXREG(width, height)); _pipes[_curPipe]->setReg( GPR_TRXDIR, 0); @@ -194,7 +194,7 @@ void DmaPipe::setConfig(uint8 prModeCont, uint8 dither, uint8 colClamp) { // set some defaults // alpha blending formula: (A-B) * C + D - // set: A = dest pixel, b = 0, C = source alpha, D = source pixel, fix = don't care + // set: A = dest pixel, b = 0, C = source alpha, D = source pixel, fix = don't care _pipes[_curPipe]->setReg(GPR_ALPHA_1, GS_SET_ALPHA(DEST_COLOR, ZERO_COLOR, SOURCE_ALPHA, SOURCE_COLOR, 0)); _pipes[_curPipe]->setReg( GPR_PRIM, 0); @@ -279,7 +279,7 @@ void SinglePipe::appendChain(uint64 dmaTag) { void SinglePipe::setReg(uint64 reg, uint64 value) { *_bufPos++ = value; *_bufPos++ = reg; - (*_chainSize)++; + (*_chainSize)++; } void SinglePipe::setListReg(uint64 value1, uint64 value2) { diff --git a/backends/platform/ps2/DmaPipe.h b/backends/platform/ps2/DmaPipe.h index c99da1c395..ad5993923e 100644 --- a/backends/platform/ps2/DmaPipe.h +++ b/backends/platform/ps2/DmaPipe.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/ps2/Gs2dScreen.cpp b/backends/platform/ps2/Gs2dScreen.cpp index 58667c0230..a4ec23329a 100644 --- a/backends/platform/ps2/Gs2dScreen.cpp +++ b/backends/platform/ps2/Gs2dScreen.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. @@ -32,6 +32,7 @@ #include "DmaPipe.h" #include "GsDefs.h" #include "graphics/surface.h" +#include "graphics/colormasks.h" #include "backends/platform/ps2/ps2debug.h" extern void *_gp; @@ -43,12 +44,49 @@ enum Buffers { PRINTF }; +/* + Supported modes: + + Mode #1 = SDTV progressive (NTSC: 224p / PAL: 256p) + Mode #2 = SDTV interlaced (NTSC: 448i / PAL: 512i) <- default + Mode #3 = EDTV progressive (NTSC: 480p / PAL: 576p) + Mode #4 = HDTV progressive (720p) + Mode #5 = HDTV interlaced (1080i) + Mode #6 = VESA (640x480@60) + Mode #7 = VESA (800x600@60) + Mode #8 = VESA (1024x768@60) +*/ + +static ps2_mode_t ps2_mode[] = { + + // -> w, h, interlaced, pitch, mode, vck, magh, magv, dx, dy + + /* #1 : SDTV - progressive */ + { 640, 224, 0, 640, 0x02, 2560, 4, 0, 160 /*158*/, 25 /*22*/ }, /* NTSC */ + { 640, 256, 0, 640, 0x03, 2560, 4, 0, 170 /*163*/, 35 /*36*/ }, /* PAL */ + + /* #2 : SDTV - interlaced */ + { 640, 448, 1, 640, 0x02, 2560, 4, 0, 156 /*158*/, 50 /*45*/ }, /* NTSC */ + { 640, 512, 1, 640, 0x03, 2560, 4, 0, 170 /*163*/, 70 /*72*/ }, /* PAL */ + + /* #3 : EDTV */ + { 720, 480, 0, 768, 0x50, 1440, 2, 0, 58, 35 }, /* NTSC */ + /* { 720, 576, 0, 768, 0x53, 1440, 2, 0, 62, 45 }, */ /* PAL : full */ + /* { 656, 576, 0, 704, 0x53, 1312, 2, 0, 62, 45 }, */ /* PAL : redux @ (0,0) */ + { 656, 576, 0, 704, 0x53, 1312, 2, 0, 78 /*314*/, 45 }, /* PAL : redux @ center'd */ + + /* #4/#5 : HDTV */ + { 1280, 720, 0, 1280, 0x52, 1280, 1, 0, 76 /*302*/, 24 }, + { 1920, 1080, 1, 1920, 0x51, 1920, 1, 0, 60 /*236*/ /*238*/, 40 }, + + /* #6/#7/#8 : VESA 4:3 @ 60Hz */ + { 640, 480, 0, 640, 0x1A, 1280, 2, 0, 70 /*276*/, 34 }, + { 800, 600, 0, 832, 0x2B, 1600, 2, 0, 105 /*420*/, 26 }, + { 1024, 768, 0, 1024, 0x3B, 2048, 2, 0, 144 /*580*/, 34 } +}; + #define ANIM_STACK_SIZE (1024 * 32) -#define DEFAULT_PAL_X 175 -#define DEFAULT_PAL_Y 72 // 60 -#define DEFAULT_NTSC_X 165 -#define DEFAULT_NTSC_Y 45 #define ORG_X 256 #define ORG_Y 256 #define ORIGIN_X (ORG_X << 4) @@ -77,7 +115,7 @@ void runAnimThread(Gs2dScreen *param); int vblankStartHandler(int cause) { // start of VBlank period - if (g_VblankCmd) { // is there a new image waiting? + if (g_VblankCmd) { // is there a new image waiting? GS_DISPFB1 = g_VblankCmd; // show it. g_VblankCmd = 0; iSignalSema(g_VblankSema); @@ -87,8 +125,8 @@ int vblankStartHandler(int cause) { int dmacHandler(int channel) { if (g_DmacCmd && (channel == 2)) { // GS DMA transfer finished, - g_VblankCmd = g_DmacCmd; // we want to show the image - g_DmacCmd = 0; // when the next vblank occurs + g_VblankCmd = g_DmacCmd; // we want to show the image + g_DmacCmd = 0; // when the next vblank occurs iSignalSema(g_DmacSema); } return 0; @@ -102,7 +140,8 @@ int vblankEndHandler(int cause) { void createAnimThread(Gs2dScreen *screen); -Gs2dScreen::Gs2dScreen(uint16 width, uint16 height, TVMode mode) { +Gs2dScreen::Gs2dScreen(uint16 width, uint16 height) { + _systemQuit = false; ee_sema_t newSema; newSema.init_count = 1; @@ -125,12 +164,15 @@ Gs2dScreen::Gs2dScreen(uint16 width, uint16 height, TVMode mode) { EnableIntc(INT_VBLANK_END); EnableDmac(2); + _tvMode = 0; // force detection + _gfxMode = 0; + _width = width; _height = height; _pitch = (width + 127) & ~127; _screenBuf = (uint8 *)memalign(64, _width * _height); - _overlayBuf = (uint16 *)memalign(64, _width * _height * 2); + _overlayBuf = (uint16 *)memalign(64, _pitch * _height * 2); _clut = (uint32 *)memalign(64, 256 * 4); memset(_screenBuf, 0, _width * _height); @@ -138,32 +180,102 @@ Gs2dScreen::Gs2dScreen(uint16 width, uint16 height, TVMode mode) { _clut[1] = GS_RGBA(0xC0, 0xC0, 0xC0, 0); clearOverlay(); - if (mode == TV_DONT_CARE) { -#if 1 char romver[8]; + uint16 biosver; int fd = fioOpen("rom0:ROMVER", O_RDONLY); fioRead(fd, &romver, 8); fioClose(fd); + biosver=atoi(romver); + printf("ROMVER = %s\n", romver); + printf("ver = %d\n", atoi(romver)); + + if (!_tvMode) { // determine TV standard first + if (ConfMan.hasKey("tv_mode", "PlayStation2")) { + const char *tvname = ConfMan.get("tv_mode", "PlayStation2").c_str(); + + if (strcmp("ntsc", tvname) == 0) { + _tvMode = 2; + } + else if (strcmp("pal", tvname) == 0) { + _tvMode = 1; + } + else + _tvMode = 0; + } + + if (!_tvMode) { + if (romver[4] == 'E') + _tvMode = TV_PAL; + else + _tvMode = TV_NTSC; + + printf("Auto-detect TV mode: PSX:%c PS2:%c\n", *(char *)(0x1FC7FF52), romver[4]); + } + } - if (romver[4] == 'E') - _tvMode = TV_PAL; - else - _tvMode = TV_NTSC; -#else - if (PAL_NTSC_FLAG == 'E') - _tvMode = TV_PAL; + uint8 mode; + if (!_gfxMode) { // determine GFX mode next + if (ConfMan.hasKey("gfx_mode", "PlayStation2")) { + _gfxMode = ConfMan.getInt("gfx_mode", "PlayStation2"); + // TODO: free more video mem to support these modes + if (_gfxMode == 4 || _gfxMode == 5) { + printf("Not enough video mem: using EDTV (3)\n"); + _gfxMode = 3; + } + else + if (_gfxMode == 7 || _gfxMode == 8) { + printf("Not enough video mem: using VGA (6)\n"); + _gfxMode = 6; + } + + if (_gfxMode < 1 || _gfxMode > 8) _gfxMode = 2; + else + if (_gfxMode == 4 || _gfxMode == 5) _tvMode = TV_HDTV; + else + if (_gfxMode > 5) _tvMode = TV_VESA; + } else - _tvMode = TV_NTSC; -#endif - } else - _tvMode = mode; + _gfxMode = 2; + } + + // Remap Mode Index + mode = _gfxMode; + if (_tvMode == TV_NTSC) { + mode = (mode * 2) - 1; + } + else if (_tvMode == TV_PAL) { + mode = (mode * 2); + } + else if (_tvMode == TV_HDTV) { + mode += 3; + } + else /* VESA */ { + _tvMode = TV_VESA; + mode += 3; + } + mode--; + + switch (_tvMode) { + case TV_NTSC: + printf("Setting up TV mode: NTSC\n"); + break; + case TV_PAL: + printf("Setting up TV mode: PAL\n"); + break; + case TV_HDTV: + printf("Setting up TV mode: HDTV\n"); + break; + case TV_VESA: + printf("Setting up TV mode: VESA\n"); + break; + } + + _tvWidth = ps2_mode[mode].w; + _tvHeight = ps2_mode[mode].h; + _tvPitch = ps2_mode[mode].pitch; - // _tvMode = TV_NTSC; - printf("Setting up %s mode\n", (_tvMode == TV_PAL) ? "PAL" : "NTSC"); + printf("Setting up GFX mode: %d x %d\n", _tvWidth, _tvHeight); - // set screen size, 640x512 for pal, 640x448 for ntsc - _tvWidth = 640; - _tvHeight = ((_tvMode == TV_PAL) ? 512 /*544*/ : 448); kFullScreen[0].z = kFullScreen[1].z = 0; kFullScreen[0].x = ORIGIN_X; kFullScreen[0].y = ORIGIN_Y; @@ -176,7 +288,7 @@ Gs2dScreen::Gs2dScreen(uint16 width, uint16 height, TVMode mode) { _texCoords[1].u = SCALE(_width); _texCoords[1].v = SCALE(_height); - uint32 tvFrameSize = _tvWidth * _tvHeight * 4; // 32 bits per pixel + uint32 tvFrameSize = _tvPitch * _tvHeight * 4; // 32 bits per pixel // setup frame buffer pointers _frameBufPtr[0] = 0; @@ -186,7 +298,7 @@ Gs2dScreen::Gs2dScreen(uint16 width, uint16 height, TVMode mode) { _clutPtrs[TEXT] = _clutPtrs[SCREEN] + 0x2000; _texPtrs[SCREEN] = _clutPtrs[SCREEN] + 0x3000; _texPtrs[TEXT] = 0; // these buffers are stored in the alpha gaps of the frame buffers - _texPtrs[MOUSE] = 128 * 256 * 4; + _texPtrs[MOUSE] = 128 * 256 * 4; _texPtrs[PRINTF] = _texPtrs[MOUSE] + M_SIZE * M_SIZE * 4; _showOverlay = false; @@ -202,12 +314,12 @@ Gs2dScreen::Gs2dScreen(uint16 width, uint16 height, TVMode mode) { _overlayFormat.rLoss = 3; _overlayFormat.gLoss = 3; _overlayFormat.bLoss = 3; - _overlayFormat.aLoss = 7; + _overlayFormat.aLoss = 8; // 7 _overlayFormat.rShift = 0; _overlayFormat.gShift = 5; _overlayFormat.bShift = 10; - _overlayFormat.aShift = 15; + _overlayFormat.aShift = 0; // 15 // setup hardware now. GS_CSR = CSR_RESET; // Reset GS @@ -215,22 +327,39 @@ Gs2dScreen::Gs2dScreen(uint16 width, uint16 height, TVMode mode) { GS_CSR = 0; GsPutIMR(0x7F00); - uint16 dispPosX, dispPosY; - if (_tvMode == TV_PAL) { - SetGsCrt(GS_INTERLACED, 3, 0); - dispPosX = DEFAULT_PAL_X; - dispPosY = DEFAULT_PAL_Y; - } else { - SetGsCrt(GS_INTERLACED, 2, 0); - dispPosX = DEFAULT_NTSC_X; - dispPosY = DEFAULT_NTSC_Y; + if (biosver < 220 && ps2_mode[mode].mode == 0x53) { // EDTV PAL : mode not in BIOS < 2.20 + // no worries... we work in magic ;-) + /* 720x576p */ + asm ("di"); + asm ("sync.l; sync.p"); + GS_PMODE = 0; + asm ("sync.l; sync.p"); + GS_SMODE1 = 0x1742890504; + asm ("sync.l; sync.p"); + GS_SMODE2 = 0; + GS_SYNCH1 = 0x402E02003C827; + asm ("sync.l; sync.p"); + GS_SYNCH2 = 0x19CA67; + asm ("sync.l; sync.p"); + GS_SYNCV = 0xA9000002700005; + asm ("sync.l; sync.p"); + GS_SRFSH = 4; + asm ("sync.l; sync.p"); + GS_SMODE1 = 0x1742880504; + asm ("sync.l; sync.p"); + asm ("sync.l; sync.p"); + GS_SMODE2 = 0; + asm("ei"); + } + else { // BIOS + SetGsCrt(ps2_mode[mode].interlaced, ps2_mode[mode].mode, 0); // ps2_mode[mode].interlaced); } asm("di"); GS_PMODE = GS_SET_PMODE(1, 0, 1, 1, 0, 255); GS_BGCOLOUR = GS_RGBA(0, 0, 0, 0); - GS_DISPLAY1 = GS_SET_DISPLAY(_tvWidth, _tvHeight, dispPosX, dispPosY); + GS_DISPLAY1 = GS_SET_DISPLAY_MODE(ps2_mode[mode]); asm("ei"); _curDrawBuf = 0; @@ -238,7 +367,7 @@ Gs2dScreen::Gs2dScreen(uint16 width, uint16 height, TVMode mode) { _dmaPipe->setOrigin(ORIGIN_X, ORIGIN_Y); _dmaPipe->setConfig(1, 0, 1); _dmaPipe->setScissorRect(0, 0, _tvWidth - 1, _tvHeight - 1); - _dmaPipe->setDrawBuffer(_frameBufPtr[_curDrawBuf], _tvWidth, GS_PSMCT24, 0); + _dmaPipe->setDrawBuffer(_frameBufPtr[_curDrawBuf], _tvPitch, GS_PSMCT24, 0); _dmaPipe->flush(); _clutChanged = _screenChanged = _overlayChanged = true; @@ -249,24 +378,33 @@ Gs2dScreen::Gs2dScreen(uint16 width, uint16 height, TVMode mode) { createAnimTextures(); // create animation thread - ee_thread_t animationThread, thisThread; + #ifdef __NEW_PS2SDK__ + ee_thread_t animThread; + ee_thread_status_t thisThread; + #else + ee_thread_t animThread, thisThread; + #endif ReferThreadStatus(GetThreadId(), &thisThread); - _animStack = malloc(ANIM_STACK_SIZE); - animationThread.initial_priority = thisThread.current_priority - 3; - animationThread.stack = _animStack; - animationThread.stack_size = ANIM_STACK_SIZE; - animationThread.func = (void *)runAnimThread; - animationThread.gp_reg = &_gp; + _animStack = memalign(64, ANIM_STACK_SIZE); + animThread.initial_priority = thisThread.current_priority - 3; + animThread.stack = _animStack; + animThread.stack_size = ANIM_STACK_SIZE; + animThread.func = (void *)runAnimThread; + animThread.gp_reg = &_gp; - _animTid = CreateThread(&animationThread); + _animTid = CreateThread(&animThread); assert(_animTid >= 0); StartThread(_animTid, this); } void Gs2dScreen::quit(void) { _systemQuit = true; + #ifdef __NEW_PS2SDK__ + ee_thread_status_t statAnim; + #else ee_thread_t statAnim; + #endif do { // wait until thread called ExitThread() SignalSema(g_AnimSema); ReferThreadStatus(_animTid, &statAnim); @@ -296,15 +434,15 @@ void Gs2dScreen::createAnimTextures(void) { for (int i = 0; i < 16; i++) { uint32 *destPos = (uint32 *)buf; for (int ch = 15; ch >= 0; ch--) { - const uint32 *src = (const uint32*)(_binaryData + ((_binaryPattern[i] >> ch) & 1) * 4 * 14); + const uint32 *src = (const uint32 *)(_binaryData + ((_binaryPattern[i] >> ch) & 1) * 4 * 14); for (int line = 0; line < 14; line++) destPos[line << 4] = src[line]; destPos++; } if (!(i & 1)) - _dmaPipe->uploadTex( vramDest, 128, 0, 0, GS_PSMT4HH, buf, 128, 16); + _dmaPipe->uploadTex( vramDest, 128, 0, 0, GS_PSMT4HH, buf, 128, 16); else { - _dmaPipe->uploadTex( vramDest, 128, 0, 0, GS_PSMT4HL, buf, 128, 16); + _dmaPipe->uploadTex( vramDest, 128, 0, 0, GS_PSMT4HL, buf, 128, 16); vramDest += 128 * 16 * 4; } _dmaPipe->flush(); @@ -506,10 +644,10 @@ void Gs2dScreen::updateScreen(void) { WaitSema(g_DmacSema); // wait for dma transfer, if there's one running WaitSema(g_VblankSema); // wait if there's already an image waiting for vblank - g_DmacCmd = GS_SET_DISPFB(_frameBufPtr[_curDrawBuf], _tvWidth, GS_PSMCT24); // put it here for dmac/vblank handler + g_DmacCmd = GS_SET_DISPFB(_frameBufPtr[_curDrawBuf], _tvPitch, GS_PSMCT24); // put it here for dmac/vblank handler _dmaPipe->flush(); _curDrawBuf ^= 1; - _dmaPipe->setDrawBuffer(_frameBufPtr[_curDrawBuf], _tvWidth, GS_PSMCT24, 0); + _dmaPipe->setDrawBuffer(_frameBufPtr[_curDrawBuf], _tvPitch, GS_PSMCT24, 0); } else _dmaPipe->flush(); SignalSema(_screenSema); @@ -527,6 +665,7 @@ void Gs2dScreen::hideOverlay(void) { Graphics::PixelFormat Gs2dScreen::getOverlayFormat(void) { return _overlayFormat; + // return Graphics::createPixelFormat<1555>(); } int16 Gs2dScreen::getOverlayWidth(void) { @@ -633,11 +772,11 @@ void Gs2dScreen::setMouseXy(int16 x, int16 y) { _mouseX = x; _mouseY = y; } - +/* uint8 Gs2dScreen::tvMode(void) { return _tvMode; } - +*/ uint16 Gs2dScreen::getWidth(void) { return _width; } @@ -655,7 +794,7 @@ void Gs2dScreen::wantAnim(bool runIt) { #define V 1000 #define Z_TRANSL 65 -void Gs2dScreen::animThread(void) { +void Gs2dScreen::playAnim(void) { // animate zeros and ones while game accesses memory card, etc. g_RunAnim = false; float yPos = 0.0; @@ -750,10 +889,10 @@ void Gs2dScreen::animThread(void) { drawY += LINE_SPACE; } - g_DmacCmd = GS_SET_DISPFB(_frameBufPtr[_curDrawBuf], _tvWidth, GS_PSMCT24); // put it here for dmac/vblank handler + g_DmacCmd = GS_SET_DISPFB(_frameBufPtr[_curDrawBuf], _tvPitch, GS_PSMCT24); // put it here for dmac/vblank handler _dmaPipe->flush(); _curDrawBuf ^= 1; - _dmaPipe->setDrawBuffer(_frameBufPtr[_curDrawBuf], _tvWidth, GS_PSMCT24, 0); + _dmaPipe->setDrawBuffer(_frameBufPtr[_curDrawBuf], _tvPitch, GS_PSMCT24, 0); _dmaPipe->setAlphaBlend(DEST_COLOR, ZERO_COLOR, SOURCE_ALPHA, SOURCE_COLOR, 0); SignalSema(_screenSema); @@ -763,7 +902,7 @@ void Gs2dScreen::animThread(void) { } void runAnimThread(Gs2dScreen *param) { - param->animThread(); + param->playAnim(); } // data for the animated zeros and ones... diff --git a/backends/platform/ps2/Gs2dScreen.h b/backends/platform/ps2/Gs2dScreen.h index 1a70dad170..ea2b1e5f78 100644 --- a/backends/platform/ps2/Gs2dScreen.h +++ b/backends/platform/ps2/Gs2dScreen.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. @@ -25,6 +25,7 @@ #include "sysdefs.h" #include "backends/base-backend.h" +#include "common/config-manager.h" #include "backends/platform/ps2/DmaPipe.h" #include "graphics/surface.h" @@ -32,7 +33,9 @@ enum TVMode { TV_DONT_CARE = 0, TV_PAL, - TV_NTSC + TV_NTSC, + TV_HDTV, /* internal */ + TV_VESA /* internal */ }; enum GsInterlace { @@ -42,14 +45,14 @@ enum GsInterlace { class Gs2dScreen { public: - Gs2dScreen(uint16 width, uint16 height, TVMode mode); + Gs2dScreen(uint16 width, uint16 height); ~Gs2dScreen(void); void newScreenSize(uint16 width, uint16 height); - uint8 tvMode(void); + // uint8 tvMode(void); uint16 getWidth(void); uint16 getHeight(void); - void copyPrintfOverlay(const uint8* buf); + void copyPrintfOverlay(const uint8 *buf); void clearPrintfOverlay(void); Graphics::Surface *lockScreen(); @@ -75,7 +78,7 @@ public: void setMouseXy(int16 x, int16 y); void setShakePos(int shake); - void animThread(void); + void playAnim(void); void wantAnim(bool runIt); void quit(void); @@ -85,8 +88,10 @@ private: void createAnimTextures(void); DmaPipe *_dmaPipe; + uint8 _gfxMode; uint8 _tvMode; uint16 _tvWidth, _tvHeight; + uint16 _tvPitch; GsVertex _blitCoords[2]; TexVertex _texCoords[2]; diff --git a/backends/platform/ps2/GsDefs.h b/backends/platform/ps2/GsDefs.h index fab0c40b35..9adf6acfcc 100644 --- a/backends/platform/ps2/GsDefs.h +++ b/backends/platform/ps2/GsDefs.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. @@ -27,16 +27,23 @@ // Gs2dScreen defines: -#define PAL_NTSC_FLAG (*(volatile uint8*)0x1FC7FF52) +#define PAL_NTSC_FLAG (*(volatile uint8 *)0x1FC7FF52) -#define GS_PMODE *((volatile uint64*)0x12000000) -#define GS_CSR *((volatile uint64*)0x12001000) -#define GS_DISPFB1 *((volatile uint64*)0x12000070) -#define GS_DISPLAY1 *((volatile uint64*)0x12000080) -#define GS_BGCOLOUR *((volatile uint64*)0x120000E0) +#define GS_PMODE *((volatile uint64 *)0x12000000) +#define GS_CSR *((volatile uint64 *)0x12001000) +#define GS_DISPFB1 *((volatile uint64 *)0x12000070) +#define GS_DISPLAY1 *((volatile uint64 *)0x12000080) +#define GS_BGCOLOUR *((volatile uint64 *)0x120000E0) + +#define GS_SMODE1 *((volatile uint64 *)0x12000010) +#define GS_SMODE2 *((volatile uint64 *)0x12000020) +#define GS_SYNCH1 *((volatile uint64 *)0x12000040) +#define GS_SYNCH2 *((volatile uint64 *)0x12000050) +#define GS_SYNCV *((volatile uint64 *)0x12000060) +#define GS_SRFSH *((volatile uint64 *)0x12000030) enum GS_CSR_FIELDS { - CSR_SIGNAL = 1 << 0, + CSR_SIGNAL = 1 << 0, CSR_FINISH = 1 << 1, CSR_HSYNC = 1 << 2, CSR_VSYNC = 1 << 3, @@ -44,6 +51,19 @@ enum GS_CSR_FIELDS { CSR_RESET = 1 << 9 }; +typedef struct { + u16 w; + u16 h; + u16 interlaced; + u16 pitch; + u16 mode; + u16 vclk; + u16 magh; + u16 magv; + u16 dx; + u16 dy; +} ps2_mode_t; + #define GS_SET_PMODE(readC1, readC2, alphaSel, alphaOut, alphaBlend, alphaFixed) \ ((readC1) | ((readC2) << 1) | ((alphaSel) << 5) | ((alphaOut) << 6) | ((alphaBlend) << 7) | ((alphaFixed) << 8)) @@ -52,6 +72,10 @@ enum GS_CSR_FIELDS { ((((2560 + (width - 1)) / width) - 1)<<23) | \ (ypos << 12) | (xpos * (2560 / width))) +#define GS_SET_DISPLAY_MODE(mode) \ + (((uint64)(mode.h - 1) << 44) | ((uint64)(mode.vclk - 1) << 32) | \ + ((mode.magh - 1) << 23) | (mode.dy << 12) | (mode.dx << 2)) + #define GS_SET_DISPFB(frameBufPtr, frameBufWidth, psm) \ (((frameBufPtr) / 8192) | (((frameBufWidth) / 64) << 9) | ((psm) << 15)) @@ -61,63 +85,63 @@ enum GS_CSR_FIELDS { //DmaPipe defines: enum GsRegs { - GPR_PRIM = 0x00, // Select and configure current drawing primitive - GPR_RGBAQ, // Setup current vertex color - GPR_ST, // ... - GPR_UV, // Specify Vertex Texture Coordinates - GPR_XYZF2, // Set vertex coordinate - GPR_XYZ2, // Set vertex coordinate and 'kick' drawing - GPR_TEX0_1, // Texture Buffer Setup (Context 1) - GPR_TEX0_2, // Texture Buffer Setup (Context 2) - GPR_CLAMP_1, // ... - GPR_CLAMP_2, // ... - GPR_FOG, // ... - - GPR_XYZF3 = 0x0C, // ... - GPR_XYZ3, // ... - - GPR_TEX1_1 = 0x14, // ... - GPR_TEX1_2, // ... - GPR_TEX2_1, // ... - GPR_TEX2_2, // ... - GPR_XYOFFSET_1, // Mapping from Primitive to Window coordinate system (Context 1) - GPR_XYOFFSET_2, // Mapping from Primitive to Window coordinate system (Context 2) - GPR_PRMODECONT, // ... - GPR_PRMODE, // ... - GPR_TEXCLUT, // ... - - GPR_SCANMSK = 0x22, // ... - - GPR_MIPTBP1_1 = 0x34, // ... - GPR_MIPTBP1_2, // ... - GPR_MIPTBP2_1, // ... - GPR_MIPTBP2_2, // ... - - GPR_TEXA = 0x3b, // ... - - GPR_FOGCOL = 0x3d, // ... - - GPR_TEXFLUSH = 0x3f,// Write to this register before using newly loaded texture - GPR_SCISSOR_1, // Setup clipping rectangle (Context 1) - GPR_SCISSOR_2, // Setup clipping rectangle (Context 2) - GPR_ALPHA_1, // Setup Alpha Blending Parameters (Context 1) - GPR_ALPHA_2, // Setup Alpha Blending Parameters (Context 2) - GPR_DIMX, // ... - GPR_DTHE, // ... - GPR_COLCLAMP, // ... - GPR_TEST_1, // ... - GPR_TEST_2, // ... - GPR_PABE, // ... - GPR_FBA_1, // ... - GPR_FBA_2, // ... - GPR_FRAME_1, // Frame buffer settings (Context 1) - GPR_FRAME_2, // Frame buffer settings (Context 2) - GPR_ZBUF_1, // ... - GPR_ZBUF_2, // ... - GPR_BITBLTBUF, // Setup Image Transfer Between EE and GS - GPR_TRXPOS, // Setup Image Transfer Coordinates - GPR_TRXREG, // Setup Image Transfer Size - GPR_TRXDIR, // Set Image Transfer Directon + Start Transfer + GPR_PRIM = 0x00, // Select and configure current drawing primitive + GPR_RGBAQ, // Setup current vertex color + GPR_ST, // ... + GPR_UV, // Specify Vertex Texture Coordinates + GPR_XYZF2, // Set vertex coordinate + GPR_XYZ2, // Set vertex coordinate and 'kick' drawing + GPR_TEX0_1, // Texture Buffer Setup (Context 1) + GPR_TEX0_2, // Texture Buffer Setup (Context 2) + GPR_CLAMP_1, // ... + GPR_CLAMP_2, // ... + GPR_FOG, // ... + + GPR_XYZF3 = 0x0C, // ... + GPR_XYZ3, // ... + + GPR_TEX1_1 = 0x14, // ... + GPR_TEX1_2, // ... + GPR_TEX2_1, // ... + GPR_TEX2_2, // ... + GPR_XYOFFSET_1, // Mapping from Primitive to Window coordinate system (Context 1) + GPR_XYOFFSET_2, // Mapping from Primitive to Window coordinate system (Context 2) + GPR_PRMODECONT, // ... + GPR_PRMODE, // ... + GPR_TEXCLUT, // ... + + GPR_SCANMSK = 0x22, // ... + + GPR_MIPTBP1_1 = 0x34, // ... + GPR_MIPTBP1_2, // ... + GPR_MIPTBP2_1, // ... + GPR_MIPTBP2_2, // ... + + GPR_TEXA = 0x3b, // ... + + GPR_FOGCOL = 0x3d, // ... + + GPR_TEXFLUSH = 0x3f, // Write to this register before using newly loaded texture + GPR_SCISSOR_1, // Setup clipping rectangle (Context 1) + GPR_SCISSOR_2, // Setup clipping rectangle (Context 2) + GPR_ALPHA_1, // Setup Alpha Blending Parameters (Context 1) + GPR_ALPHA_2, // Setup Alpha Blending Parameters (Context 2) + GPR_DIMX, // ... + GPR_DTHE, // ... + GPR_COLCLAMP, // ... + GPR_TEST_1, // ... + GPR_TEST_2, // ... + GPR_PABE, // ... + GPR_FBA_1, // ... + GPR_FBA_2, // ... + GPR_FRAME_1, // Frame buffer settings (Context 1) + GPR_FRAME_2, // Frame buffer settings (Context 2) + GPR_ZBUF_1, // ... + GPR_ZBUF_2, // ... + GPR_BITBLTBUF, // Setup Image Transfer Between EE and GS + GPR_TRXPOS, // Setup Image Transfer Coordinates + GPR_TRXREG, // Setup Image Transfer Size + GPR_TRXDIR, // Set Image Transfer Directon + Start Transfer GPR_HWREG, GPR_SIGNAL = 0x60, @@ -135,15 +159,15 @@ enum PrimTypes { PR_SPRITE }; -#define GS_PSMCT32 0x00 -#define GS_PSMCT24 0x01 -#define GS_PSMCT16 0x02 -#define GS_PSMCT16S 0x0A -#define GS_PSMT8 0x13 -#define GS_PSMT4 0x14 -#define GS_PSMT4HL 0x24 -#define GS_PSMT4HH 0x2C -#define GS_PSMT8H 0x1B +#define GS_PSMCT32 0x00 +#define GS_PSMCT24 0x01 +#define GS_PSMCT16 0x02 +#define GS_PSMCT16S 0x0A +#define GS_PSMT8 0x13 +#define GS_PSMT4 0x14 +#define GS_PSMT4HL 0x24 +#define GS_PSMT4HH 0x2C +#define GS_PSMT8H 0x1B /*#define GS_SET_BITBLTBUF(sbp, sbw, spsm, dbp, dbw, dpsm) \ ((uint64)(sbp) | ((uint64)(sbw) << 16) | \ @@ -210,7 +234,7 @@ enum AlphaBlendColor { enum AlphaBlendAlpha { SOURCE_ALPHA = 0, DEST_ALPHA, - FIXED_ALPHA + FIXED_ALPHA }; #define GS_SET_ALPHA(a, b, c, d, fix) \ diff --git a/backends/platform/ps2/Makefile.gdb b/backends/platform/ps2/Makefile.gdb deleted file mode 100644 index 8ca47cd9f1..0000000000 --- a/backends/platform/ps2/Makefile.gdb +++ /dev/null @@ -1,104 +0,0 @@ -# $Header: Exp $ - include $(PS2SDK)/Defs.make - -PS2_EXTRA = /works/devel/ps2/sdk-extra -PS2_EXTRA_INCS = /zlib/include /libmad/ee/include /SjPcm/ee/src /tremor -PS2_EXTRA_LIBS = /zlib/lib /libmad/ee/lib /SjPcm/ee/lib /tremor/tremor - -ENABLED=STATIC_PLUGIN - -ENABLE_SCUMM = $(ENABLED) -ENABLE_SCUMM_7_8 = $(ENABLED) -# ENABLE_HE = $(ENABLED) -# ENABLE_AGI = $(ENABLED) -# ENABLE_AGOS = $(ENABLED) -# ENABLE_AGOS2 = $(ENABLED) -# ENABLE_CINE = $(ENABLED) -# ENABLE_CRUISE = $(ENABLED) -# ENABLE_DRACI = $(ENABLED) -# ENABLE_DRASCULA = $(ENABLED) -# ENABLE_GOB = $(ENABLED) -# ENABLE_GROOVIE = $(ENABLED) -## ENABLE_GROOVIE2 = $(ENABLED) -# ENABLE_HUGO = $(ENABLED) -# ENABLE_IHNM = $(ENABLED) -# ENABLE_KYRA = $(ENABLED) -## ENABLE_LOL = $(ENABLED) -# ENABLE_LURE = $(ENABLED) -## ENABLE_M4 = $(ENABLED) -# ENABLE_MADE = $(ENABLED) -# ENABLE_MOHAWK = $(ENABLED) -# ENABLE_PARALLACTION = $(ENABLED) -# ENABLE_QUEEN = $(ENABLED) -# ENABLE_SAGA = $(ENABLED) -# ENABLE_SAGA2 = $(ENABLED) -# ENABLE_SCI = $(ENABLED) -## ENABLE_SCI32 = $(ENABLED) -# ENABLE_SKY = $(ENABLED) -# ENABLE_SWORD1 = $(ENABLED) -# ENABLE_SWORD2 = $(ENABLED) -# ENABLE_TEENAGENT = $(ENABLED) -# ENABLE_TINSEL = $(ENABLED) -# ENABLE_TOON = $(ENABLED) -# ENABLE_TOUCHE = $(ENABLED) -# ENABLE_TUCKER = $(ENABLED) - - -HAVE_GCC3 = true - -CC = ee-gcc -CXX = ee-g++ -AS = ee-gcc -LD = ee-gcc -AR = ee-ar cru -RANLIB = ee-ranlib -STRIP = ee-strip -MKDIR = mkdir -p -RM = rm -f - -srcdir = ../../.. -VPATH = $(srcdir) -INCDIR = ../../../ -# DEPDIR = .deps - -DEFINES = -DUSE_VORBIS -DUSE_TREMOR -DUSE_MAD -DUSE_ZLIB -DFORCE_RTL -DDISABLE_SAVEGAME_SORTING -D_EE -D__PLAYSTATION2__ -D__PS2_DEBUG__ -g -Wall -Wno-multichar -fno-rtti -fno-exceptions # -DNO_ADAPTOR -# for release builds: -#DEFINES += -DRELEASE_BUILD - -INCLUDES = $(addprefix -I$(PS2_EXTRA),$(PS2_EXTRA_INCS)) -INCLUDES += -I $(PS2GDB)/ee -I $(PS2SDK)/ee/include -I $(PS2SDK)/common/include -I ./common -I . -I $(srcdir) -I $(srcdir)/engines - -CXX_UPDATE_DEP_FLAG = -Wp,-MMD,"$(*D)/$(DEPDIR)/$(*F).d",-MQ,"$@",-MP - -TARGET = elf/scummvm.elf - -OBJS := $(srcdir)/backends/platform/ps2/DmaPipe.o \ - $(srcdir)/backends/platform/ps2/Gs2dScreen.o \ - $(srcdir)/backends/platform/ps2/irxboot.o \ - $(srcdir)/backends/platform/ps2/ps2input.o \ - $(srcdir)/backends/platform/ps2/ps2pad.o \ - $(srcdir)/backends/platform/ps2/savefilemgr.o \ - $(srcdir)/backends/platform/ps2/fileio.o \ - $(srcdir)/backends/platform/ps2/asyncfio.o \ - $(srcdir)/backends/platform/ps2/icon.o \ - $(srcdir)/backends/platform/ps2/cd.o \ - $(srcdir)/backends/platform/ps2/eecodyvdfs.o \ - $(srcdir)/backends/platform/ps2/rpckbd.o \ - $(srcdir)/backends/platform/ps2/systemps2.o \ - $(srcdir)/backends/platform/ps2/ps2mutex.o \ - $(srcdir)/backends/platform/ps2/ps2time.o \ - $(srcdir)/backends/platform/ps2/ps2debug.o - -MODULE_DIRS += . - -include $(srcdir)/Makefile.common - -LDFLAGS += -mno-crt0 $(PS2SDK)/ee/startup/crt0.o -T $(PS2SDK)/ee/startup/linkfile -LDFLAGS += -L $(PS2GDB)/lib -L $(PS2SDK)/ee/lib -L . -LDFLAGS += $(addprefix -L$(PS2_EXTRA),$(PS2_EXTRA_LIBS)) -LDFLAGS += -lmc -lpad -lmouse -lhdd -lpoweroff -lsjpcm -lmad -ltremor -lz -lm -lc -lfileXio -lps2gdbStub -lps2ip -ldebug -lkernel -lstdc++ - -all: $(TARGET) - -$(TARGET): $(OBJS) - $(LD) $^ $(LDFLAGS) -o $@ diff --git a/backends/platform/ps2/Makefile.ps2 b/backends/platform/ps2/Makefile.ps2 index d6ce08ae84..3631c653f6 100644 --- a/backends/platform/ps2/Makefile.ps2 +++ b/backends/platform/ps2/Makefile.ps2 @@ -1,107 +1,217 @@ -# $Header: Exp $ - include $(PS2SDK)/Defs.make +# SCUMMVM-PS2 MakeFile -PS2_EXTRA = /works/devel/ps2/sdk-extra -PS2_EXTRA_INCS = /zlib/include /libmad/ee/include /SjPcm/ee/src /tremor -PS2_EXTRA_LIBS = /zlib/lib /libmad/ee/lib /SjPcm/ee/lib /tremor/tremor -ENABLED=STATIC_PLUGIN +# Use only this section to modify how the makefile behaves ------------ -ENABLE_SCUMM = $(ENABLED) -ENABLE_SCUMM_7_8 = $(ENABLED) -ENABLE_HE = $(ENABLED) +# Scummvm engine config: choose which engines are enabled ENABLE_AGI = $(ENABLED) ENABLE_AGOS = $(ENABLED) -ENABLE_AGOS2 = $(ENABLED) +ENABLE_AGOS2 = 1 +# ENABLE_AVALANCHE = $(ENABLED) +ENABLE_CGE = $(ENABLED) ENABLE_CINE = $(ENABLED) +ENABLE_COMPOSER = $(ENABLED) ENABLE_CRUISE = $(ENABLED) ENABLE_DRACI = $(ENABLED) ENABLE_DRASCULA = $(ENABLED) +ENABLE_DREAMWEB = $(ENABLED) +# ENABLE_FULLPIPE = $(ENABLED) ENABLE_GOB = $(ENABLED) ENABLE_GROOVIE = $(ENABLED) # ENABLE_GROOVIE2 = $(ENABLED) +# ENABLE_HOPKINS = $(ENABLED) ENABLE_HUGO = $(ENABLED) -ENABLE_IHNM = $(ENABLED) ENABLE_KYRA = $(ENABLED) -# ENABLE_LOL = $(ENABLED) +ENABLE_LOL = 1 +ENABLE_EOB = 1 +# ENABLE_LASTEXPRESS = $(ENABLED) ENABLE_LURE = $(ENABLED) -# ENABLE_M4 = $(ENABLED) ENABLE_MADE = $(ENABLED) ENABLE_MOHAWK = $(ENABLED) +# ENABLE_CSTIME = $(ENABLED) +# ENABLE_RIVEN = $(ENABLED) +# ENABLE_MYST = $(ENABLED) +ENABLE_MORTEVIELLE = $(ENABLED) +ENABLE_NEVERHOOD = $(ENABLED) ENABLE_PARALLACTION = $(ENABLED) +# ENABLE_PEGASUS = $(ENABLED) ENABLE_QUEEN = $(ENABLED) ENABLE_SAGA = $(ENABLED) +ENABLE_IHNM = 1 # ENABLE_SAGA2 = $(ENABLED) ENABLE_SCI = $(ENABLED) # ENABLE_SCI32 = $(ENABLED) +ENABLE_SCUMM = $(ENABLED) +ENABLE_SCUMM_7_8 = 1 +ENABLE_HE = 1 ENABLE_SKY = $(ENABLED) ENABLE_SWORD1 = $(ENABLED) ENABLE_SWORD2 = $(ENABLED) +# ENABLE_SWORD25 = $(ENABLED) ENABLE_TEENAGENT = $(ENABLED) +# ENABLE_TESTBED = $(ENABLED) ENABLE_TINSEL = $(ENABLED) +ENABLE_TOLTECS = $(ENABLED) +# ENABLE_TONY = $(ENABLED) ENABLE_TOON = $(ENABLED) ENABLE_TOUCHE = $(ENABLED) +ENABLE_TSAGE = $(ENABLED) ENABLE_TUCKER = $(ENABLED) - - -HAVE_GCC3 = true - -CC = ee-gcc -CXX = ee-g++ -AS = ee-gcc -LD = ee-gcc +# ENABLE_WINTERMUTE = $(ENABLED) +# ENABLE_ZVISION = $(ENABLED) + +# Set to 1 to enable seeing the commands to gcc +VERBOSE_BUILD = 0 +# Set to 1 to enable, 0 to disable dynamic modules +DYNAMIC_MODULES = 1 +# Set to 1 to enable debugging +ENABLE_DEBUG = 0 +# Set to 1 to enable profiling +ENABLE_PROFILING = 0 +# Set to 1 to disable HDD+NET +DISABLE_NETWORK = 0 +# Set to 1 to enable, 0 to disable libmad and libogg +USE_LIBMAD = 1 +USE_LIBOGG = 1 + +# --------------------------------------------------------------------- + + +# General variables +srcdir = ../../.. +VPATH = $(srcdir) +TARGET = scummvm.elf +# PS2 SDK location variables +# PS2SDK = /works/tools/devel/ps2/sdk + +# Check PS2SDK presence +ifeq ($(PS2SDK),) +$(error $$(PS2SDK) needs to be set.) +endif + +# Variables for common Scummvm makefile +CC = ee-gcc +CXX = ee-g++ +FLAGS = -pedantic -Wall -W +FLAGS += -Wcast-qual -Wconversion -Wpointer-arith -Wshadow -Wwrite-strings +FLAGS += -Wno-long-long -Wno-multichar -Wno-unknown-pragmas -Wno-unused-parameter +CFLAGS = $(FLAGS) -std=c99 +CXXFLAGS = $(FLAGS) -Wnon-virtual-dtor -Wno-reorder -fno-exceptions -fno-rtti + +DEFINES = -D_EE -D__PLAYSTATION2__ -D__NEW_PS2SDK__ -DUSE_ZLIB -DFORCE_RTL -DDATA_PATH=\"host:data\" +DEFINES += -DDISABLE_SAVEGAME_SORTING -DDISABLE_TEXT_CONSOLE -DDISABLE_COMMAND_LINE -DDISABLE_DOSBOX_OPL -DDISABLE_SID -DDISABLE_NES_APU +# DEFINES += -DLOGORRHEIC + +INCDIR := $(PS2SDK)/ee/include $(PS2SDK)/common/include $(PS2SDK)/ports/include . $(srcdir) $(srcdir)/engines +INCLUDES := $(addprefix -I, $(INCDIR)) +DEPDIR = .deps +MODULE_DIRS += ./ +MKDIR = mkdir -p +RM = rm -f +RM_REC = rm -rf AR = ee-ar cru RANLIB = ee-ranlib STRIP = ee-strip -MKDIR = mkdir -p -RM = rm -f - -srcdir = ../../.. -VPATH = $(srcdir) -INCDIR = ../../../ -# DEPDIR = .deps - -DEFINES = -DUSE_VORBIS -DUSE_TREMOR -DUSE_MAD -DUSE_ZLIB -DFORCE_RTL -DDISABLE_SAVEGAME_SORTING -D_EE -D__PLAYSTATION2__ -G2 -O2 -Wall -Wno-multichar -fno-rtti -fno-exceptions # -DNO_ADAPTOR -# for release builds: -#DEFINES += -DRELEASE_BUILD - -INCLUDES = $(addprefix -I$(PS2_EXTRA),$(PS2_EXTRA_INCS)) -INCLUDES += -I $(PS2SDK)/ee/include -I $(PS2SDK)/common/include -I ./common -I . -I $(srcdir) -I $(srcdir)/engines - -CXX_UPDATE_DEP_FLAG = -Wp,-MMD,"$(*D)/$(DEPDIR)/$(*F).d",-MQ,"$@",-MP - -TARGET = elf/scummvm.elf +AS = ee-gcc +LD = ee-gcc +HAVE_GCC3 = true +CXX_UPDATE_DEP_FLAG = -MMD -MF "$(*D)/$(DEPDIR)/$(*F).d" -MQ "$@" -MP + +# Variables for dynamic plugin building +PLUGIN_PREFIX = +PLUGIN_SUFFIX = .plg +PLUGIN_EXTRA_DEPS = $(TARGET) +PLUGIN_LDFLAGS = -nostartfiles $(srcdir)/backends/plugins/elf/version.o -Wl,-q,--just-symbols,$(TARGET),--retain-symbols-file,$(srcdir)/backends/plugins/elf/plugin.syms +PLUGIN_LDFLAGS += -mno-crt0 $(PS2SDK)/ee/startup/crt0.o -Wl,-T$(srcdir)/backends/plugins/ps2/plugin.ld -lstdc++ -lc + +# Test for adding different libs +ifeq ($(USE_LIBMAD),1) +DEFINES += -DUSE_MAD +LIBS += -lmad +endif +ifeq ($(USE_LIBOGG), 1) +DEFINES += -DUSE_VORBIS -DUSE_TREMOR +LIBS += -ltremor +endif + +# Test for dynamic plugins +ifeq ($(DYNAMIC_MODULES),1) +ENABLED = DYNAMIC_PLUGIN +DEFINES += -DDYNAMIC_MODULES -DUSE_ELF_LOADER -DMIPS_TARGET -DUNCACHED_PLUGINS -DPLUGIN_DIRECTORY=\"host:plugins\" +PRE_OBJS_FLAGS = -Wl,--whole-archive +POST_OBJS_FLAGS = -Wl,--no-whole-archive +else +ENABLED = STATIC_PLUGIN +endif + +# Test for debug +ifeq ($(ENABLE_DEBUG),1) +DEFINES += -D__PS2_DEBUG__ +FLAGS += -G2 -g +LIBS += -lps2gdbStub -lps2ip -ldebug +else +DEFINES += -DRELEASE_BUILD +FLAGS += -G2 -O2 -s -Wuninitialized +# LDFLAGS += -s +endif + +# Test for profiling +ifeq ($(ENABLE_PROFILING),1) +DEFINES += -DENABLE_PROFILING +FLAGS += -G2 -pg -g +LDFLAGS += -pg +endif + +# Test for net support +ifeq ($(DISABLE_NETWORK),1) +DEFINES += -DNO_ADAPTOR +endif + +# PS2 LIBS +PS2LIBS = -lmc -lpad -lmouse -lhdd -lpoweroff -lsjpcm -lz -lm -lc -lfileXio -lkernel -lstdc++ + +# Add in PS2SDK includes and libraries. +LIBS += $(PS2LIBS) OBJS := $(srcdir)/backends/platform/ps2/DmaPipe.o \ - $(srcdir)/backends/platform/ps2/Gs2dScreen.o \ - $(srcdir)/backends/platform/ps2/irxboot.o \ - $(srcdir)/backends/platform/ps2/ps2input.o \ - $(srcdir)/backends/platform/ps2/ps2pad.o \ - $(srcdir)/backends/platform/ps2/savefilemgr.o \ - $(srcdir)/backends/platform/ps2/fileio.o \ - $(srcdir)/backends/platform/ps2/asyncfio.o \ - $(srcdir)/backends/platform/ps2/icon.o \ - $(srcdir)/backends/platform/ps2/cd.o \ - $(srcdir)/backends/platform/ps2/eecodyvdfs.o \ - $(srcdir)/backends/platform/ps2/rpckbd.o \ - $(srcdir)/backends/platform/ps2/systemps2.o \ - $(srcdir)/backends/platform/ps2/ps2mutex.o \ - $(srcdir)/backends/platform/ps2/ps2time.o \ - $(srcdir)/backends/platform/ps2/ps2debug.o - -MODULE_DIRS += . + $(srcdir)/backends/platform/ps2/Gs2dScreen.o \ + $(srcdir)/backends/platform/ps2/irxboot.o \ + $(srcdir)/backends/platform/ps2/ps2input.o \ + $(srcdir)/backends/platform/ps2/ps2pad.o \ + $(srcdir)/backends/platform/ps2/savefilemgr.o \ + $(srcdir)/backends/platform/ps2/fileio.o \ + $(srcdir)/backends/platform/ps2/asyncfio.o \ + $(srcdir)/backends/platform/ps2/icon.o \ + $(srcdir)/backends/platform/ps2/cd.o \ + $(srcdir)/backends/platform/ps2/eecodyvdfs.o \ + $(srcdir)/backends/platform/ps2/rpckbd.o \ + $(srcdir)/backends/platform/ps2/systemps2.o \ + $(srcdir)/backends/platform/ps2/ps2mutex.o \ + $(srcdir)/backends/platform/ps2/ps2time.o \ + $(srcdir)/backends/platform/ps2/ps2debug.o + +ifeq ($(DYNAMIC_MODULES),1) +OBJS += $(srcdir)/backends/plugins/elf/elf-loader.o \ + $(srcdir)/backends/plugins/elf/elf-provider.o \ + $(srcdir)/backends/plugins/elf/shorts-segment-manager.o \ + $(srcdir)/backends/plugins/elf/memory-manager.o \ + $(srcdir)/backends/plugins/elf/mips-loader.o \ + $(srcdir)/backends/plugins/elf/version.o +endif BACKEND := ps2 +# Include common Scummvm makefile include $(srcdir)/Makefile.common +LDFLAGS += -L$(PS2SDK)/ee/lib -L$(PS2SDK)/ports/lib +ifeq ($(DYNAMIC_MODULES),1) +LDFLAGS += -mno-crt0 $(PS2SDK)/ee/startup/crt0.o -Wl,-T$(srcdir)/backends/plugins/ps2/main_prog.ld +else LDFLAGS += -mno-crt0 $(PS2SDK)/ee/startup/crt0.o -T $(PS2SDK)/ee/startup/linkfile -LDFLAGS += -L $(PS2SDK)/ee/lib -L . -LDFLAGS += $(addprefix -L$(PS2_EXTRA),$(PS2_EXTRA_LIBS)) -LDFLAGS += -lmc -lpad -lmouse -lhdd -lpoweroff -lsjpcm -lmad -ltremor -lz -lm -lc -lfileXio -lkernel -lstdc++ -LDFLAGS += -s +endif all: $(TARGET) $(TARGET): $(OBJS) - $(LD) $^ $(LDFLAGS) -o $@ + $(LD) $(PRE_OBJS_FLAGS) $(OBJS) $(POST_OBJS_FLAGS) $(LDFLAGS) $(LIBS) -o $@ diff --git a/backends/platform/ps2/Makefile.ps2.dev b/backends/platform/ps2/Makefile.ps2.dev new file mode 100644 index 0000000000..cd9432e2df --- /dev/null +++ b/backends/platform/ps2/Makefile.ps2.dev @@ -0,0 +1,170 @@ +# SCUMMVM-PS2 MakeFile + + +# Use only this section to modify how the makefile behaves ------------ + +# Scummvm engine config: choose which engines are enabled +ENABLE_SCUMM = $(ENABLED) +ENABLE_SCUMM_7_8 = 1 +# ENABLE_HE = 1 +ENABLE_SCI = $(ENABLED) +# ENABLE_SCI32 = $(ENABLED) +# ENABLE_SKY = $(ENABLED) +# ENABLE_SWORD1 = $(ENABLED) +# ENABLE_SWORD2 = $(ENABLED) + +# Set to 1 to enable seeing the commands to gcc +VERBOSE_BUILD = 1 +# Set to 1 to enable, 0 to disable dynamic modules +DYNAMIC_MODULES = 0 +# Set to 1 to enable debugging +ENABLE_DEBUG = 0 +# Set to 1 to enable profiling +ENABLE_PROFILING = 1 +# Set to 1 to disable HDD+NET +DISABLE_NETWORK = 0 +# Set to 1 to enable, 0 to disable libmad and libogg +USE_LIBMAD = 1 +USE_LIBOGG = 1 + +# --------------------------------------------------------------------- + + +# General variables +srcdir = ../../.. +VPATH = $(srcdir) +TARGET = scummvm.elf +# PS2 SDK location variables +# PS2SDK = /works/tools/devel/ps2/sdk + +# Check PS2SDK presence +ifeq ($(PS2SDK),) +$(error $$(PS2SDK) needs to be set.) +endif + +# Variables for common Scummvm makefile +CC = ee-gcc +CXX = ee-g++ +FLAGS = -pedantic -Wall -W +FLAGS += -Wcast-qual -Wconversion -Wpointer-arith -Wshadow -Wwrite-strings +FLAGS += -Wno-long-long -Wno-multichar -Wno-unknown-pragmas -Wno-unused-parameter +CFLAGS = $(FLAGS) -std=c99 +CXXFLAGS = $(FLAGS) -Wnon-virtual-dtor -Wno-reorder -fno-exceptions -fno-rtti + +DEFINES = -D_EE -D__PLAYSTATION2__ -D__NEW_PS2SDK__ -DUSE_ZLIB -DFORCE_RTL -DDATA_PATH=\"host:data\" +DEFINES += -DDISABLE_SAVEGAME_SORTING -DDISABLE_TEXT_CONSOLE -DDISABLE_COMMAND_LINE -DDISABLE_DOSBOX_OPL -DDISABLE_SID -DDISABLE_NES_APU +# DEFINES += -DLOGORRHEIC + +INCDIR := $(PS2SDK)/ee/include $(PS2SDK)/common/include $(PS2SDK)/ports/include . $(srcdir) $(srcdir)/engines +INCLUDES := $(addprefix -I, $(INCDIR)) +DEPDIR = .deps +MODULE_DIRS += ./ +MKDIR = mkdir -p +RM = rm -f +RM_REC = rm -rf +AR = ee-ar cru +RANLIB = ee-ranlib +STRIP = ee-strip +AS = ee-gcc +LD = ee-gcc +HAVE_GCC3 = true +CXX_UPDATE_DEP_FLAG = -MMD -MF "$(*D)/$(DEPDIR)/$(*F).d" -MQ "$@" -MP + +# Variables for dynamic plugin building +PLUGIN_PREFIX = +PLUGIN_SUFFIX = .plg +PLUGIN_EXTRA_DEPS = $(TARGET) +PLUGIN_LDFLAGS = -nostartfiles $(srcdir)/backends/plugins/elf/version.o -Wl,-q,--just-symbols,$(TARGET),--retain-symbols-file,$(srcdir)/backends/plugins/elf/plugin.syms +PLUGIN_LDFLAGS += -mno-crt0 $(PS2SDK)/ee/startup/crt0.o -Wl,-T$(srcdir)/backends/plugins/ps2/plugin.ld -lstdc++ -lc + +# Test for adding different libs +ifeq ($(USE_LIBMAD),1) +DEFINES += -DUSE_MAD +LIBS += -lmad +endif +ifeq ($(USE_LIBOGG), 1) +DEFINES += -DUSE_VORBIS -DUSE_TREMOR +LIBS += -ltremor +endif + +# Test for dynamic plugins +ifeq ($(DYNAMIC_MODULES),1) +ENABLED = DYNAMIC_PLUGIN +DEFINES += -DDYNAMIC_MODULES -DUSE_ELF_LOADER -DMIPS_TARGET -DUNCACHED_PLUGINS -DPLUGIN_DIRECTORY=\"host:plugins\" +PRE_OBJS_FLAGS = -Wl,--whole-archive +POST_OBJS_FLAGS = -Wl,--no-whole-archive +else +ENABLED = STATIC_PLUGIN +endif + +# Test for debug +ifeq ($(ENABLE_DEBUG),1) +DEFINES += -D__PS2_DEBUG__ +FLAGS += -G2 -g +LIBS += -lps2gdbStub -lps2ip -ldebug +else +DEFINES += -DRELEASE_BUILD +FLAGS += -G2 -O2 -s -Wuninitialized +# LDFLAGS += -s +endif + +# Test for profiling +ifeq ($(ENABLE_PROFILING),1) +DEFINES += -DENABLE_PROFILING +FLAGS += -G2 -pg -g +LDFLAGS += -pg +endif + +# Test for net support +ifeq ($(DISABLE_NETWORK),1) +DEFINES += -DNO_ADAPTOR +endif + +# PS2 LIBS +PS2LIBS = -lmc -lpad -lmouse -lhdd -lpoweroff -lsjpcm -lz -lm -lc -lfileXio -lkernel -lstdc++ + +# Add in PS2SDK includes and libraries. +LIBS += $(PS2LIBS) + +OBJS := $(srcdir)/backends/platform/ps2/DmaPipe.o \ + $(srcdir)/backends/platform/ps2/Gs2dScreen.o \ + $(srcdir)/backends/platform/ps2/irxboot.o \ + $(srcdir)/backends/platform/ps2/ps2input.o \ + $(srcdir)/backends/platform/ps2/ps2pad.o \ + $(srcdir)/backends/platform/ps2/savefilemgr.o \ + $(srcdir)/backends/platform/ps2/fileio.o \ + $(srcdir)/backends/platform/ps2/asyncfio.o \ + $(srcdir)/backends/platform/ps2/icon.o \ + $(srcdir)/backends/platform/ps2/cd.o \ + $(srcdir)/backends/platform/ps2/eecodyvdfs.o \ + $(srcdir)/backends/platform/ps2/rpckbd.o \ + $(srcdir)/backends/platform/ps2/systemps2.o \ + $(srcdir)/backends/platform/ps2/ps2mutex.o \ + $(srcdir)/backends/platform/ps2/ps2time.o \ + $(srcdir)/backends/platform/ps2/ps2debug.o + +ifeq ($(DYNAMIC_MODULES),1) +OBJS += $(srcdir)/backends/plugins/elf/elf-loader.o \ + $(srcdir)/backends/plugins/elf/elf-provider.o \ + $(srcdir)/backends/plugins/elf/shorts-segment-manager.o \ + $(srcdir)/backends/plugins/elf/memory-manager.o \ + $(srcdir)/backends/plugins/elf/mips-loader.o \ + $(srcdir)/backends/plugins/elf/version.o +endif + +BACKEND := ps2 + +# Include common Scummvm makefile +include $(srcdir)/Makefile.common + +LDFLAGS += -L$(PS2SDK)/ee/lib -L$(PS2SDK)/ports/lib +ifeq ($(DYNAMIC_MODULES),1) +LDFLAGS += -mno-crt0 $(PS2SDK)/ee/startup/crt0.o -Wl,-T$(srcdir)/backends/plugins/ps2/main_prog.ld +else +LDFLAGS += -mno-crt0 $(PS2SDK)/ee/startup/crt0.o -T $(PS2SDK)/ee/startup/linkfile +endif + +all: $(TARGET) + +$(TARGET): $(OBJS) + $(LD) $(PRE_OBJS_FLAGS) $(OBJS) $(POST_OBJS_FLAGS) $(LDFLAGS) $(LIBS) -o $@ diff --git a/backends/platform/ps2/README.PS2 b/backends/platform/ps2/README.PS2 new file mode 100644 index 0000000000..141a79eaca --- /dev/null +++ b/backends/platform/ps2/README.PS2 @@ -0,0 +1,189 @@ +Dear PS2 ScummVM enthusiast user, + +here you will find the latest and the greatest PS2 backend ever! + + + *** Release Notes *** + +Released 2 builds: SCUMMVM.ELF and SCUMMVM-S.ELF. The latter has engine +modules statically linked into (that's what the "-S" is for), the former +uses dynamic modules (uncached). The dynamic one is much faster to start +and has more resources available for the games. The catch is that games +detection, when you are adding a new one, is painstakingly slow... +(as it needs to load, test, unload the plugins one by one). + +Until we have an optimization for that in place I would suggest you add +new games with "SCUMMVM-S.ELF", and when you are done adding you then +play them with "SCUMMVM.ELF", as this will give you the best of both. + +We no longer have a separate ELF build with hdd & net adapter disabled, +as we now do it in the smart way, allowing users to disable it in their +ScummVM.ini. See under in "Configuration" for details. + +We also have an improved Makefile.ps2 in ps2 folder which will allow +you to create: static, dynamic, profile and debug build version. + +You can now also cleanly compile using "configure" and specifying: + +./configure --backend=ps2 --host=ps2 ... + + + *** Installation *** + +Some media drivers require all capitalized letter, so to be on the +safe side store the files (SCUMMVM.ELF and *.IRX) in upper case. + +Here comes a full list of the required *.IRX (don't worry they are all +provided pre-compiled in the binary release ;-) + + IOMANX.IRX + FILEXIO.IRX + CODYVDFS.IRX + SJPCM.IRX + USBD.IRX + USB_MASS.IRX + PS2MOUSE.IRX + RPCKBD.IRX + POWEROFF.IRX + PS2DEV9.IRX + PS2ATAD.IRX + PS2HDD.IRX + PS2FS.IRX + PS2IP.IRX + PS2SMAP.IRX + PS2HOST.IRX + +Make sure they are all stored in the folder that contains your SCUMMVM.ELF! + +If you are starting ScummVM from CD/DVD then it will look for ScummVM.ini +a ScummVM.ini on the media folder from where you started SCUMMVM.ELF. + +Notes: + + - depending on the media you install Scummvm/PS2 onto, it might be + picky about files cases, so I'd leave those *.IRX uppercase and + scummmodern.zip lower ;0) + + - make sure you selected a save path before you start playing! + + - we added PS2IPS.IRX in case you wanted to test a debug build + (use Makefile.gdb) + + + *** Configuration *** + +There is now a [PlayStation2] section in ScummVM.ini which can be used +to make your wildest dreams come true ;-) + +It accepts these entries: + +tv_mode = [pal] [ntsc] +gfx_mode = [mode number] [*] +hdd_part = [partition name] [disable] +net_addr = [PS2 IP addr] [**] +usb_mass = [0] [disable] + +[*] Currently supported gfx modes are: + + # 1 -> SDTV progressive (NTSC: 224p / PAL: 256p) + # 2 -> SDTV interlaced (NTSC: 448i / PAL: 512i) <- default + # 3 -> EDTV progressive (NTSC: 480p / PAL: 576p) + # 6 -> VESA (640x480@60) + +If no tv_mode is specified it will be autodected based on PS2 model. + +The non-interlaced (progressive) modes look much better and sharper. +You can check the difference starting COMI and choosing About from +the GMM (press "start" then choose "about"). You can easily see the +difference between progressive and interlaced in scrolling text. + +You can use mode 6 (VGA 640x480) if you are connecting your PS2 to +a RGB monitor. Some TVs also supports this signal. + +We also do some bad-ass things, like detecting the BIOS version and +setting the GS registers by hand, for console models where a mode +is not supported ;-) + +If SCUMMVM.ELF hangs at start for you try disabling the adapter by +setting in ScummVM.ini + +hdd_part = 0 +net_addr = 0 + +You can now also choose the hdd partition used for ScummVM games +(default "+ScummVM") passing it as an argument to hdd_part: + +hdd_part = MyPartition (witout the "+") + +If you have an adapter with hdd & net, but you don't use them you +can just set both to 0 to disable, and have a leaner and meaner +ScummVM booting much faster! + +[**] TODO + + *** Remote *** + +You will need "PS2IP.IRX", "PS2SMAP.IRX" and "PS2HOST.IRX" drivers too +in the folder where you are starting SCUMMVM.ELF if you want to use +the remote capability. + +The IP 192.168.1.20 (ps2link default) is hardcoded in the source as +"netArg" in irxboot.cpp, feel free to modify it to match your network +configuration. + +In a future release you will be able to set in ScummVM.ini using + +net_addr = xxx.yyy.zzz.www + +If you are starting SCUMMVM.ELF over the net using ps2client then you +are already set. If you are starting it in any other way, then you +will have to "export" the folder where you are storing ScummVM games +and data by starting ps2client from inside that folder. Eg. from a +terminal: + +> ./ps2client -h [your ps2 ip] listen + +Do this -after- ScummVM is up and running otherwise it will fail to +establish a connection. + + + *** Gamepad *** + +The mapping is: + +Start Button - GMM +R1 - 'y' +L1 - 'n' +R2 - '.' +L2 - Numpad 0 +Triangle - Escape +Square - Enter +Cross - Left mouse button +Circle - Right mouse button + + + *** Bugs *** + +Though we made our best to make this release as bug free as possible +there are still a few bugs left: + + - file handling speed : (not really a bug, but a nuisance) : there + is probably space for some more optimization in the current file + management. The only case when it really bogs me it's when you + try to select a saved game and there is some lag. + + Some game will start faster too when this is optimized. + + - feel free to add your bug, suggestion, secret wish to this list! + + - SCI games have smooth audio and intro, but moving the pointer + and in-game animation speed might be a challenge. + + - it has been reported USB media greater than 8 GB might not work + +Now enough reading, rush to your PlayStation2 and start playing! + +Are you still reading? + +Have a lot of fun, + -Max Lingua diff --git a/backends/platform/ps2/asyncfio.cpp b/backends/platform/ps2/asyncfio.cpp index 3f20349107..6f15dcc628 100644 --- a/backends/platform/ps2/asyncfio.cpp +++ b/backends/platform/ps2/asyncfio.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. @@ -33,7 +33,7 @@ AsyncFio::AsyncFio(void) { _runningOp = NULL; - memset((int *)_ioSlots, 0, MAX_HANDLES * sizeof(int)); + memset(const_cast<int *>(_ioSlots), 0, MAX_HANDLES * sizeof(int)); ee_sema_t newSema; newSema.init_count = 1; newSema.max_count = 1; @@ -63,7 +63,7 @@ int AsyncFio::open(const char *name, int ioMode, int mode) { fileXioWaitAsync(FXIO_WAIT, &res); SignalSema(_ioSema); // dbg_printf("FIO: open ext(%s, %d, %d) => %d", name, ioMode, mode, res); - return res; + return res; } void AsyncFio::close(int handle) { @@ -80,7 +80,7 @@ void AsyncFio::close(int handle) { void AsyncFio::checkSync(void) { if (_runningOp) { - fileXioWaitAsync(FXIO_WAIT, (int *)_runningOp); + fileXioWaitAsync(FXIO_WAIT, const_cast<int *>(_runningOp)); _runningOp = NULL; } } @@ -90,7 +90,7 @@ void AsyncFio::read(int fd, void *dest, unsigned int len) { checkSync(); assert(fd < MAX_HANDLES); _runningOp = _ioSlots + fd; - fileXioRead(fd, (unsigned char*)dest, len); + fileXioRead(fd, (unsigned char *)dest, len); SignalSema(_ioSema); } @@ -99,7 +99,7 @@ void AsyncFio::write(int fd, const void *src, unsigned int len) { checkSync(); assert(fd < MAX_HANDLES); _runningOp = _ioSlots + fd; - fileXioWrite(fd, (unsigned char*)src, len); + fileXioWrite(fd, (unsigned char *)const_cast<void *>(src), len); SignalSema(_ioSema); } @@ -210,7 +210,7 @@ bool AsyncFio::poll(int fd) { bool retVal = false; if (PollSema(_ioSema) >= 0) { if (_runningOp == _ioSlots + fd) { - if (fileXioWaitAsync(FXIO_NOWAIT, (int *)_runningOp) == FXIO_COMPLETE) { + if (fileXioWaitAsync(FXIO_NOWAIT, const_cast<int *>(_runningOp)) == FXIO_COMPLETE) { _runningOp = NULL; retVal = true; } else @@ -226,7 +226,7 @@ bool AsyncFio::fioAvail(void) { bool retVal = false; if (PollSema(_ioSema) > 0) { if (_runningOp) { - if (fileXioWaitAsync(FXIO_NOWAIT, (int *)_runningOp) == FXIO_COMPLETE) { + if (fileXioWaitAsync(FXIO_NOWAIT, const_cast<int *>(_runningOp)) == FXIO_COMPLETE) { _runningOp = NULL; retVal = true; } else diff --git a/backends/platform/ps2/asyncfio.h b/backends/platform/ps2/asyncfio.h index 31684d4349..6f84742da0 100644 --- a/backends/platform/ps2/asyncfio.h +++ b/backends/platform/ps2/asyncfio.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. @@ -23,6 +23,9 @@ #define MAX_HANDLES 32 #include <sys/stat.h> +#undef chdir // we define our own +#undef mkdir + class AsyncFio { public: AsyncFio(void); diff --git a/backends/platform/ps2/cd.c b/backends/platform/ps2/cd.c index cd44b3d034..e08437d34f 100644 --- a/backends/platform/ps2/cd.c +++ b/backends/platform/ps2/cd.c @@ -19,35 +19,35 @@ int cdvdInitialised = 0; void cdvdExit(void) { - cdvdInitialised = 0; + cdvdInitialised = 0; } int cdvdInit(int mode) { int i=0,len=0,ret=0; - u8 *pkt; - - cdvdCd.server = NULL; - - do { - if ((ret = SifBindRpc(&cdvdCd, CDVD_INIT_BIND_RPC, 0)) < 0) { - return -1; - } - if (!cdvdCd.server) { - nopdelay(); - } - } + u8 *pkt; + + cdvdCd.server = NULL; + + do { + if ((ret = SifBindRpc(&cdvdCd, (signed)CDVD_INIT_BIND_RPC, 0)) < 0) { + return -1; + } + if (!cdvdCd.server) { + nopdelay(); + } + } while(!cdvdCd.server); - pkt = sendBuffer; - PUSHDATA( int, pkt, mode, i); - pkt += i; len += i; + pkt = (unsigned char *)sendBuffer; + PUSHDATA(int, pkt, mode, i); + pkt += i; len += i; if ((ret = SifCallRpc(&cdvdCd, 0, 0, sendBuffer, len, NULL, 0, 0, 0)) < 0) - return -1; + return -1; - cdvdInitialised = 1; + cdvdInitialised = 1; - return 0; + return 0; } diff --git a/backends/platform/ps2/eecodyvdfs.h b/backends/platform/ps2/eecodyvdfs.h index 1d43fb662f..f439c42125 100644 --- a/backends/platform/ps2/eecodyvdfs.h +++ b/backends/platform/ps2/eecodyvdfs.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. @@ -40,7 +40,7 @@ struct CdClock { #ifdef __cplusplus extern "C" { #endif - int initCdvdFs(void); + int initCdvdFs(void); void readRTC(struct CdClock *dest); int driveStop(void); int driveStandby(void); diff --git a/backends/platform/ps2/fileio.cpp b/backends/platform/ps2/fileio.cpp index 1ec16a3817..205a688438 100644 --- a/backends/platform/ps2/fileio.cpp +++ b/backends/platform/ps2/fileio.cpp @@ -8,20 +8,21 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. * */ -// Disable symbol overrides so that we can use system headers. -#define FORBIDDEN_SYMBOL_ALLOW_ALL +// Disable symbol overrides so that we can use "FILE" +#define FORBIDDEN_SYMBOL_EXCEPTION_FILE +#define FORBIDDEN_SYMBOL_EXCEPTION_printf #include "backends/platform/ps2/fileio.h" @@ -78,12 +79,12 @@ Ps2File::~Ps2File() { fio.seek(_fd, 0, SEEK_SET); fio.write(_fd, _cacheBuf, _filePos); w = fio.sync(_fd); - printf("flushed wbuf: %x of %x\n", w, _filePos); + dbg_printf("flushed wbuf: %x of %x\n", w, _filePos); } fio.close(_fd); uint32 r = fio.sync(_fd); - printf("close [%d] - sync'd = %d\n", _fd, r); + dbg_printf("close [%d] - sync'd = %d\n", _fd, r); } free(_cacheBuf); @@ -97,7 +98,7 @@ bool Ps2File::open(const char *name, int mode) { #if 1 _fd = fio.open(name, mode); - printf("open %s [%d]\n", name, _fd); + dbg_printf("open %s [%d]\n", name, _fd); if (_fd >= 0) { _mode = mode; @@ -110,9 +111,9 @@ bool Ps2File::open(const char *name, int mode) { else _fileSize = 0; - printf(" _mode = %x\n", _mode); - printf(" _fileSize = %d\n", _fileSize); - // printf(" _filePos = %d\n", _filePos); + dbg_printf(" _mode = %x\n", _mode); + dbg_printf(" _fileSize = %d\n", _fileSize); + // dbg_printf(" _filePos = %d\n", _filePos); return true; } @@ -130,7 +131,7 @@ bool Ps2File::open(const char *name, int mode) { if (_fileSize && mode != O_RDONLY) { fio.read(_fd, _cacheBuf, _fileSize); r = fio.sync(_fd); - printf(" sz=%d, read=%d\n", _fileSize, r); + dbg_printf(" sz=%d, read=%d\n", _fileSize, r); assert(r == _fileSize); } @@ -141,7 +142,7 @@ bool Ps2File::open(const char *name, int mode) { _fd = fio.open(name, mode); - printf("open %s [%d]\n", name, _fd); + dbg_printf("open %s [%d]\n", name, _fd); if (_fd >= 0) { _mode = mode; @@ -160,16 +161,16 @@ bool Ps2File::open(const char *name, int mode) { if (mode != O_RDONLY) { fio.read(_fd, _cacheBuf, _fileSize); r = fio.sync(_fd); - printf(" sz=%d, read=%d\n", _fileSize, r); + dbg_printf(" sz=%d, read=%d\n", _fileSize, r); assert(r == _fileSize); // _fileSize = fio.seek(_fd, 0, SEEK_END); } #endif } - printf(" _mode = %x\n", _mode); - printf(" _fileSize = %d\n", _fileSize); - printf(" _filePos = %d\n", _filePos); + dbg_printf(" _mode = %x\n", _mode); + dbg_printf(" _fileSize = %d\n", _fileSize); + dbg_printf(" _filePos = %d\n", _filePos); return true; } else @@ -208,7 +209,7 @@ bool Ps2File::eof() { #ifdef __PS2_FILE_SEMA__ SignalSema(_sema); - // printf(" EOF [%d] : %d of %d -> %d\n", _fd, _filePos, _fileSize, res); + // dbg_printf(" EOF [%d] : %d of %d -> %d\n", _fd, _filePos, _fileSize, res); #endif return res; } @@ -255,8 +256,8 @@ int Ps2File::seek(int32 offset, int origin) { _eof = true; } - // printf("seek [%d] %d %d\n", _fd, offset, origin); - // printf(" res = %d\n", res); + // dbg_printf("seek [%d] %d %d\n", _fd, offset, origin); + // dbg_printf(" res = %d\n", res); #ifdef __PS2_FILE_SEMA__ SignalSema(_sema); @@ -338,8 +339,8 @@ uint32 Ps2File::read(void *dest, uint32 len) { #endif #ifdef __PS2_FILE_DEBUG__ - printf("read (1) : _filePos = %d\n", _filePos); - printf("read (1) : _cachePos = %d\n", _cachePos); + dbg_printf("read (1) : _filePos = %d\n", _filePos); + dbg_printf("read (1) : _cachePos = %d\n", _cachePos); #endif if (len == 0) { @@ -409,7 +410,10 @@ uint32 Ps2File::read(void *dest, uint32 len) { break; // EOF } } +#ifndef ENABLE_PROFILING + // doesn't play nice with -pg cacheReadAhead(); +#endif #ifdef __PS2_FILE_SEMA__ SignalSema(_sema); #endif @@ -473,7 +477,7 @@ uint32 PS2FileStream::write(const void *ptr, uint32 len) { } bool PS2FileStream::flush() { - // printf("flush not implemented\n"); + // dbg_printf("flush not implemented\n"); return true; } @@ -481,7 +485,7 @@ bool PS2FileStream::err() const { bool errVal = _handle->getErr(); if (errVal) { - printf("ferror -> %d\n", errVal); + dbg_printf("ferror -> %d\n", errVal); } return errVal; @@ -501,7 +505,7 @@ FILE *ps2_fopen(const char *fname, const char *mode) { Ps2File *file = new Ps2File(); int _mode = O_RDONLY; - printf("fopen(%s, %s)\n", fname, mode); + dbg_printf("fopen(%s, %s)\n", fname, mode); if (mode[0] == 'r' && mode [1] == 'w') _mode = O_RDWR; diff --git a/backends/platform/ps2/fileio.h b/backends/platform/ps2/fileio.h index afa2ca1f24..16eb7f212a 100644 --- a/backends/platform/ps2/fileio.h +++ b/backends/platform/ps2/fileio.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. @@ -30,13 +30,13 @@ #include "common/stream.h" enum { - CACHE_SIZE = 2048 * 32, - MAX_READ_STEP = 2048 * 16, - MAX_CACHED_FILES = 6, - CACHE_READ_THRESHOLD = 16 * 2048, - CACHE_FILL_MIN = 2048 * 24, - READ_ALIGN = 64, // align all reads to the size of an EE cache line - READ_ALIGN_MASK = READ_ALIGN - 1 + CACHE_SIZE = 2048 * 32, + MAX_READ_STEP = 2048 * 16, + MAX_CACHED_FILES = 6, + CACHE_READ_THRESHOLD = 16 * 2048, + CACHE_FILL_MIN = 2048 * 24, + READ_ALIGN = 64, // align all reads to the size of an EE cache line + READ_ALIGN_MASK = READ_ALIGN - 1 }; // TODO: Make this a subclass of SeekableReadStream & WriteStream diff --git a/backends/platform/ps2/icon.cpp b/backends/platform/ps2/icon.cpp index bda4843647..9319d9f4d9 100644 --- a/backends/platform/ps2/icon.cpp +++ b/backends/platform/ps2/icon.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. @@ -937,7 +937,7 @@ uint16 PS2Icon::decompressData(uint16 **data) { uint16 inPos = 1; const uint16 *rleData = (const uint16 *)_rleIcoData; uint16 resSize = rleData[0]; - uint16 *resData = (uint16 *)malloc(resSize * sizeof(uint16)); + uint16 *resData = (uint16 *)memalign(64, resSize * sizeof(uint16)); uint16 outPos = 0; while (outPos < resSize) { diff --git a/backends/platform/ps2/icon.h b/backends/platform/ps2/icon.h index 3ad19910d3..9413b8466c 100644 --- a/backends/platform/ps2/icon.h +++ b/backends/platform/ps2/icon.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/ps2/iop/CoDyVDfs/common/codyvdirx.h b/backends/platform/ps2/iop/CoDyVDfs/common/codyvdirx.h index e94e7dc8d6..6ac5a0bb65 100644 --- a/backends/platform/ps2/iop/CoDyVDfs/common/codyvdirx.h +++ b/backends/platform/ps2/iop/CoDyVDfs/common/codyvdirx.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. @@ -26,13 +26,13 @@ #define CDVDFS_IRX_ID 0xD004352 // commands: -#define READ_RTC 0 -#define SET_READ_SPEED 1 -#define DRIVE_STOP 2 -#define DRIVE_STANDBY 3 +#define READ_RTC 0 +#define SET_READ_SPEED 1 +#define DRIVE_STOP 2 +#define DRIVE_STANDBY 3 -#define CdTrayOpen 0 -#define CdTrayClose 1 -#define CdTrayCheck 2 +#define CdTrayOpen 0 +#define CdTrayClose 1 +#define CdTrayCheck 2 #endif // CDVDFS_COMMON_H diff --git a/backends/platform/ps2/iop/CoDyVDfs/iop/cdtypes.h b/backends/platform/ps2/iop/CoDyVDfs/iop/cdtypes.h index ad86631cfd..d9bd5287c6 100644 --- a/backends/platform/ps2/iop/CoDyVDfs/iop/cdtypes.h +++ b/backends/platform/ps2/iop/CoDyVDfs/iop/cdtypes.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. @@ -39,24 +39,24 @@ typedef struct { } ISOPathTableRecord __attribute__ ((packed)); typedef struct { - uint8 year; // Number of years since 1900 - uint8 month; // Month of the year from 1 to 12 - uint8 day; // Day of the Month from 1 to 31 - uint8 hour; // Hour of the day from 0 to 23 - uint8 min; // Minute of the hour from 0 to 59 - uint8 sec; // second of the minute from 0 to 59 - uint8 gmtOff; // Offset from Greenwich Mean Time in number of 15 minute intervals from -48(West) to +52(East) + uint8 year; // Number of years since 1900 + uint8 month; // Month of the year from 1 to 12 + uint8 day; // Day of the Month from 1 to 31 + uint8 hour; // Hour of the day from 0 to 23 + uint8 min; // Minute of the hour from 0 to 59 + uint8 sec; // second of the minute from 0 to 59 + uint8 gmtOff; // Offset from Greenwich Mean Time in number of 15 minute intervals from -48(West) to +52(East) uint8 padding[10]; } ISOTime __attribute__ ((packed)); typedef struct { - uint8 year; // Number of years since 1900 - uint8 month; // Month of the year from 1 to 12 - uint8 day; // Day of the Month from 1 to 31 - uint8 hour; // Hour of the day from 0 to 23 - uint8 min; // Minute of the hour from 0 to 59 - uint8 sec; // second of the minute from 0 to 59 - uint8 gmtOff; // Offset from Greenwich Mean Time in number of 15 minute intervals from -48(West) to +52(East) + uint8 year; // Number of years since 1900 + uint8 month; // Month of the year from 1 to 12 + uint8 day; // Day of the Month from 1 to 31 + uint8 hour; // Hour of the day from 0 to 23 + uint8 min; // Minute of the hour from 0 to 59 + uint8 sec; // second of the minute from 0 to 59 + uint8 gmtOff; // Offset from Greenwich Mean Time in number of 15 minute intervals from -48(West) to +52(East) //uint8 padding[10]; } ISOFileTime __attribute__ ((packed)); @@ -96,38 +96,38 @@ typedef struct { uint8 reserved[6]; uint8 reserved2; uint8 reserved3; -} ISORoot __attribute__((packed)); // 0x22 +} ISORoot __attribute__((packed)); // 0x22 typedef struct { - uint8 type; // 0x00 - char identifier[5]; // 0x01 - uint8 version; // 0x06 - uint8 reserved1; // 0x07 - char systemIdentifier[32]; // 0x08 + uint8 type; // 0x00 + char identifier[5]; // 0x01 + uint8 version; // 0x06 + uint8 reserved1; // 0x07 + char systemIdentifier[32]; // 0x08 char volumeIdentifier[32]; // 0x28 - uint8 reserved2[8]; // 0x48 - uint32 volumeSpaceSize; // 0x50 - uint32 volumeSpaceSizeBE; // 0x54 - char reserved3[32]; // 0x58 - uint32 volumeSetSize; // 0x78 - uint32 volumeSequenceNumber; // 0x7C - uint32 logicalBlockSize; // 0x80 - uint32 pathTableSize; // 0x84 - uint32 pathTableSizeBE; // 0x88 - uint32 pathTablePos; // 0x8C - uint32 pathTable2Pos; // 0x90 - uint32 pathTablePosBE; // 0x94 - uint32 pathTable2PosBE; // 0x98 - ISORoot rootDir; // 0x9C - ISOIds ids; // 0xBE - ISOTime creation; // 0x32D - ISOTime modification; // 0x33E - ISOTime expiration; // 0x34F - ISOTime effective; // 0x360 - uint8 fileStructureVersion; // 0x371 - uint8 reserved4; // 0x372 - uint8 applicationUse[512]; // 0x373 - uint8 reserved5[653]; // 0x573 -} ISOPvd __attribute__ ((packed)); // 0x800 + uint8 reserved2[8]; // 0x48 + uint32 volumeSpaceSize; // 0x50 + uint32 volumeSpaceSizeBE; // 0x54 + char reserved3[32]; // 0x58 + uint32 volumeSetSize; // 0x78 + uint32 volumeSequenceNumber; // 0x7C + uint32 logicalBlockSize; // 0x80 + uint32 pathTableSize; // 0x84 + uint32 pathTableSizeBE; // 0x88 + uint32 pathTablePos; // 0x8C + uint32 pathTable2Pos; // 0x90 + uint32 pathTablePosBE; // 0x94 + uint32 pathTable2PosBE; // 0x98 + ISORoot rootDir; // 0x9C + ISOIds ids; // 0xBE + ISOTime creation; // 0x32D + ISOTime modification; // 0x33E + ISOTime expiration; // 0x34F + ISOTime effective; // 0x360 + uint8 fileStructureVersion; // 0x371 + uint8 reserved4; // 0x372 + uint8 applicationUse[512]; // 0x373 + uint8 reserved5[653]; // 0x573 +} ISOPvd __attribute__ ((packed)); // 0x800 #endif // __CDTYPES_H__ diff --git a/backends/platform/ps2/iop/CoDyVDfs/iop/codyvdfs.c b/backends/platform/ps2/iop/CoDyVDfs/iop/codyvdfs.c index e55e62853b..2a94560843 100644 --- a/backends/platform/ps2/iop/CoDyVDfs/iop/codyvdfs.c +++ b/backends/platform/ps2/iop/CoDyVDfs/iop/codyvdfs.c @@ -59,7 +59,7 @@ int verifyDriveReady(void) { return -1; // drive still not ready } } - if (mediaType == DISC_NONE) + if (mediaType == DISC_NONE) return -1; return 0; } @@ -72,14 +72,14 @@ int cacheEnterDir(ISODirectoryRecord *dir) { cachedDirOfs = 0; cacheName = cachedDir + strlen(cachedDir); memcpy(cacheName, dir->name, dir->len_fi); - cacheName[dir->len_fi] = '/'; + cacheName[dir->len_fi] = '/'; cacheName[dir->len_fi + 1] = '\0'; return cdReadSectors(cachedDirLba, 1, cacheBuf, &rmode); } int initRootCache(void) { CdRMode rmode = { 16, 0, CdSect2048, 0 }; - ISODirectoryRecord *root = (ISODirectoryRecord*)cacheBuf; + ISODirectoryRecord *root = (ISODirectoryRecord *)cacheBuf; if (cdReadSectors(fsRootLba, 1, cacheBuf, &rmode) == 0) { cachedDir[0] = '\0'; @@ -104,10 +104,10 @@ ISODirectoryRecord *findEntryInCache(const char *name, int nameLen) { if (i != cachedDirOfs) { if (cdReadSectors(cachedDirLba + i, 1, cacheBuf, &rmode) < 0) return NULL; - cachedDirOfs = i; + cachedDirOfs = i; } - while (entry->len_dr && ((uint8*)entry < cacheBuf + SECTOR_SIZE)) { + while (entry->len_dr && ((uint8 *)entry < cacheBuf + SECTOR_SIZE)) { if ((entry->len_fi > 2) && (entry->name[entry->len_fi - 2] == ';') && (entry->name[entry->len_fi - 1] == '1')) { if ((nameLen == entry->len_fi - 2) && (strnicmp(name, entry->name, entry->len_fi - 2) == 0)) return entry; @@ -115,10 +115,10 @@ ISODirectoryRecord *findEntryInCache(const char *name, int nameLen) { if ((nameLen == entry->len_fi) && (strnicmp(name, entry->name, entry->len_fi) == 0)) return entry; } - entry = (ISODirectoryRecord *)( (uint8*)entry + entry->len_dr ); + entry = (ISODirectoryRecord *)( (uint8 *)entry + entry->len_dr ); } } - return NULL; + return NULL; } ISODirectoryRecord *findPath(const char *path) { @@ -225,12 +225,12 @@ int initDisc(void) { case 1: discType = DISC_MODE1; printf("Disc: Mode1\n"); - pvd = (ISOPvd*)(cacheBuf + 4); + pvd = (ISOPvd *)(cacheBuf + 4); break; case 2: discType = DISC_MODE2; printf("Disc: Mode2\n"); - pvd = (ISOPvd*)(cacheBuf + 12); + pvd = (ISOPvd *)(cacheBuf + 12); break; default: DBG_PRINTF("Unknown Sector Type %02X\n", cacheBuf[3]); @@ -257,7 +257,7 @@ int initDisc(void) { mediaType = discType; DBG_PRINTF("Root directory in sector %d\n", fsRootLba); - return initRootCache(); + return initRootCache(); } } } @@ -290,46 +290,46 @@ int cd_init(iop_device_t *dev) { } iop_device_ops_t FS_ops = { - (void *) cd_init, - (void *) cd_dummy, - (void *) cd_dummy, - (void *) cd_open, - (void *) cd_close, - (void *) cd_read, - (void *) cd_dummy, - (void *) cd_lseek, - (void *) cd_dummy, - (void *) cd_dummy, - (void *) cd_dummy, - (void *) cd_dummy, - (void *) cd_dopen, - (void *) cd_dclose, - (void *) cd_dread, - (void *) cd_dummy, - (void *) cd_dummy, + (void *) cd_init, + (void *) cd_dummy, + (void *) cd_dummy, + (void *) cd_open, + (void *) cd_close, + (void *) cd_read, + (void *) cd_dummy, + (void *) cd_lseek, + (void *) cd_dummy, + (void *) cd_dummy, + (void *) cd_dummy, + (void *) cd_dummy, + (void *) cd_dopen, + (void *) cd_dclose, + (void *) cd_dread, + (void *) cd_dummy, + (void *) cd_dummy, }; #define FS_NAME "cdfs" #define FS_DESC "CD-ROM" iop_device_t fsdriver = { - FS_NAME, - IOP_DT_FS | IOP_DT_FSEXT, - 1, - FS_DESC, - &FS_ops + FS_NAME, + IOP_DT_FS | IOP_DT_FSEXT, + 1, + FS_DESC, + &FS_ops }; int _start(void) { - printf("CoDyVDfs v0.01\n"); + printf("CoDyVDfs v0.01\n"); CdInit(1); - DelDrv(FS_NAME); - AddDrv(&fsdriver); + DelDrv(FS_NAME); + AddDrv(&fsdriver); initRpc(); initFio(); - return(0); + return(0); } int strnicmp(const char *s1, const char *s2, int n) { diff --git a/backends/platform/ps2/iop/CoDyVDfs/iop/codyvdfs.h b/backends/platform/ps2/iop/CoDyVDfs/iop/codyvdfs.h index b9f1edc194..cc903ea841 100644 --- a/backends/platform/ps2/iop/CoDyVDfs/iop/codyvdfs.h +++ b/backends/platform/ps2/iop/CoDyVDfs/iop/codyvdfs.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. @@ -51,20 +51,20 @@ enum ReadModes { }; enum { - CdDiskNone = 0x00, - CdDiskDetect, // 0x01 - CdDiskDetectCD, // 0x02 - CdDiskDetectDVD, // 0x03 - CdDiskDetectUnk = 0x05, - CdDiskCDPS1 = 0x10, - CdDiskCDDAPS1 = 0x11, - CdDiskCDPS2 = 0x12, - CdDiskCDDAPS2 = 0x13, - CdDiskDVDPS2 = 0x14, - CdDiskDVDV2 = 0xFC, - CdDiskCDDA = 0xFD, - CdDiskDVDV = 0xFE, - CdDiskIllegal = 0xFF + CdDiskNone = 0x00, + CdDiskDetect, // 0x01 + CdDiskDetectCD, // 0x02 + CdDiskDetectDVD, // 0x03 + CdDiskDetectUnk = 0x05, + CdDiskCDPS1 = 0x10, + CdDiskCDDAPS1 = 0x11, + CdDiskCDPS2 = 0x12, + CdDiskCDDAPS2 = 0x13, + CdDiskDVDPS2 = 0x14, + CdDiskDVDV2 = 0xFC, + CdDiskCDDA = 0xFD, + CdDiskDVDV = 0xFE, + CdDiskIllegal = 0xFF }; #define DISC_NOT_READY(type) ((type > CdDiskNone) && (type < CdDiskCDPS1) && (type != CdDiskDetectUnk)) diff --git a/backends/platform/ps2/iop/CoDyVDfs/iop/fiofs.c b/backends/platform/ps2/iop/CoDyVDfs/iop/fiofs.c index f0a06f927b..611211a715 100644 --- a/backends/platform/ps2/iop/CoDyVDfs/iop/fiofs.c +++ b/backends/platform/ps2/iop/CoDyVDfs/iop/fiofs.c @@ -104,7 +104,7 @@ int cd_open(iop_file_t *handle, const char *name, int mode) { fd->pos = 0; fd->cachedLba = 0; - handle->privdata = (void*)fdSlot; + handle->privdata = (void *)fdSlot; return 0; } @@ -135,7 +135,7 @@ int cd_read(iop_file_t *handle, void *dest, int length) { FioHandle *fd = fioHandles + (int)handle->privdata; CdRMode rmode = { 16, 0, CdSect2048, 0 }; int readLba, readPos, bytesLeft; - uint8 *destPos = (uint8*)dest; + uint8 *destPos = (uint8 *)dest; int doCopy; int numLba; readLba = fd->lba + (fd->pos >> 11); @@ -171,13 +171,13 @@ int cd_read(iop_file_t *handle, void *dest, int length) { numLba = bytesLeft >> 11; if (cdReadSectors(readLba, numLba, destPos, &rmode) != 0) break; - readLba += numLba; + readLba += numLba; fd->pos += numLba << 11; destPos += numLba << 11; bytesLeft &= 0x7FF; } } - return destPos - (uint8*)dest; + return destPos - (uint8 *)dest; } int cd_close(iop_file_t *handle) { @@ -219,7 +219,7 @@ int cd_dopen(iop_file_t *handle, const char *path) { } dioHandles[fdSlot].curOfs = 0; dioHandles[fdSlot].lbaOfs = 0; - handle->privdata = (void*)fdSlot; + handle->privdata = (void *)fdSlot; return fdSlot; } @@ -252,7 +252,7 @@ int cd_dread(iop_file_t *handle, iox_dirent_t *buf) { } } } - return 0; + return 0; } int cd_dclose(iop_file_t *handle) { diff --git a/backends/platform/ps2/iop/CoDyVDfs/iop/fiofs.h b/backends/platform/ps2/iop/CoDyVDfs/iop/fiofs.h index db942b0b7e..058594a126 100644 --- a/backends/platform/ps2/iop/CoDyVDfs/iop/fiofs.h +++ b/backends/platform/ps2/iop/CoDyVDfs/iop/fiofs.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/ps2/iop/CoDyVDfs/iop/irx_imports.h b/backends/platform/ps2/iop/CoDyVDfs/iop/irx_imports.h index 69bbc012f8..393a7ee9a5 100644 --- a/backends/platform/ps2/iop/CoDyVDfs/iop/irx_imports.h +++ b/backends/platform/ps2/iop/CoDyVDfs/iop/irx_imports.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/ps2/iop/CoDyVDfs/iop/rpcfs.c b/backends/platform/ps2/iop/CoDyVDfs/iop/rpcfs.c index 5b760faa06..983ae38716 100644 --- a/backends/platform/ps2/iop/CoDyVDfs/iop/rpcfs.c +++ b/backends/platform/ps2/iop/CoDyVDfs/iop/rpcfs.c @@ -69,11 +69,11 @@ void *rpcReadClock(void *data) { void *driveStop(void *data) { if (CdStop() == 1) { if (CdSync(0) == 0) { - *(int*)data = CdGetError(); + *(int *)data = CdGetError(); } else - *(int*)data = -0x100; + *(int *)data = -0x100; } else - *(int*)data = -0x101; + *(int *)data = -0x101; return data; } @@ -81,11 +81,11 @@ void *driveStandby(void *data) { int type; if (CdStandby() == 1) { if (CdSync(0) == 0) { - *(int*)data = CdGetError(); + *(int *)data = CdGetError(); } else - *(int*)data = -0x100; + *(int *)data = -0x100; } else - *(int*)data = -0x101; + *(int *)data = -0x101; do { // wait until drive detected disc type type = CdGetDiskType(); diff --git a/backends/platform/ps2/iop/rpckbd/include/ps2kbd.h b/backends/platform/ps2/iop/rpckbd/include/ps2kbd.h index 07d9c3d7f9..6bef7caefa 100644 --- a/backends/platform/ps2/iop/rpckbd/include/ps2kbd.h +++ b/backends/platform/ps2/iop/rpckbd/include/ps2kbd.h @@ -87,8 +87,8 @@ typedef struct _kbd_keymap #define KBD_RPC_SETSPECIALMAP 7 /* Sets the special key mapping */ #define KBD_RPC_FLUSHBUFFER 9 /* Flush the internal buffer, probably best after a keymap change */ #define KBD_RPC_RESETKEYMAP 10 /* Reset keymaps to default states */ -#define KBD_RPC_READKEY 11 -#define KBD_RPC_READRAW 12 +#define KBD_RPC_READKEY 11 +#define KBD_RPC_READRAW 12 /* Note on keymaps. In normal keymap a 0 would indicate no key */ /* Key maps are represented by 3 256*8bit tables. First table maps USB key to a char when not shifted */ diff --git a/backends/platform/ps2/iop/rpckbd/src/irx_imports.h b/backends/platform/ps2/iop/rpckbd/src/irx_imports.h index f7d0656bda..193db4f02a 100644 --- a/backends/platform/ps2/iop/rpckbd/src/irx_imports.h +++ b/backends/platform/ps2/iop/rpckbd/src/irx_imports.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/ps2/iop/rpckbd/src/ps2kbd.c b/backends/platform/ps2/iop/rpckbd/src/ps2kbd.c index 7266afdce5..838ce9fe85 100644 --- a/backends/platform/ps2/iop/rpckbd/src/ps2kbd.c +++ b/backends/platform/ps2/iop/rpckbd/src/ps2kbd.c @@ -1089,7 +1089,7 @@ void *ps2kbd_rpc_server(int fno, void *data, int size) { ps2kbd_rpc_flushbuffer(); break; case KBD_RPC_SETLEDS: - ps2kbd_rpc_setleds(*(u8*) data); + ps2kbd_rpc_setleds(*(u8 *) data); break; case KBD_RPC_RESETKEYMAP: ps2kbd_rpc_resetkeymap(); @@ -1129,7 +1129,7 @@ int ps2kbd_init_rpc(void) { int th; param.attr = 0x02000000; - param.thread = (void*)ps2kbd_start_rpc; + param.thread = (void *)ps2kbd_start_rpc; param.priority = 40; param.stacksize = 0x800; param.option = 0; diff --git a/backends/platform/ps2/irxboot.cpp b/backends/platform/ps2/irxboot.cpp index aa904d4f5b..0e05047c6e 100644 --- a/backends/platform/ps2/irxboot.cpp +++ b/backends/platform/ps2/irxboot.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. @@ -34,37 +34,65 @@ static const char hddArg[] = "-o" "\0" "8" "\0" "-n" "\0" "20"; static const char pfsArg[] = "-m" "\0" "2" "\0" "-o" "\0" "32" "\0" "-n" "\0" "72"; // "\0" "-debug"; -static const char netArg[] = "192.168.0.10" "\0" "255.255.255.0" "\0" "192.168.0.1"; - -IrxFile irxFiles[] = { - { "SIO2MAN", BIOS, NOTHING, NULL, 0 }, - { "MCMAN", BIOS, NOTHING, NULL, 0 }, - { "MCSERV", BIOS, NOTHING, NULL, 0 }, - { "PADMAN", BIOS, NOTHING, NULL, 0 }, - { "LIBSD", BIOS, NOTHING, NULL, 0 }, - - { "IOMANX.IRX", SYSTEM, NOTHING, NULL, 0 }, - { "FILEXIO.IRX", SYSTEM, NOTHING, NULL, 0 }, - { "CODYVDFS.IRX", SYSTEM, NOTHING, NULL, 0 }, +static const char netArg[] = "192.168.1.20" "\0" "255.255.255.0" "\0" "192.168.1.1"; // TODO: set in ScummVM.ini + +IrxFile irxCore[] = { // core modules + // Memory Card + { "SIO2MAN", BIOS, NOTHING, NULL, 0 }, + { "MCMAN", BIOS, NOTHING, NULL, 0 }, + { "MCSERV", BIOS, NOTHING, NULL, 0 }, + // Joypad + { "PADMAN", BIOS, NOTHING, NULL, 0 }, + // Sound + { "LIBSD", BIOS, NOTHING, NULL, 0 }, { "SJPCM.IRX", SYSTEM, NOTHING, NULL, 0 }, + // Files I/O + { "IOMANX.IRX", SYSTEM, NOTHING, NULL, 0 }, + { "FILEXIO.IRX", SYSTEM, NOTHING, NULL, 0 } +}; + +IrxFile irxCdrom[] = { // cdrom modules + // CD-Rom FS + { "CODYVDFS.IRX", SYSTEM, CD_DRIVER, NULL, 0 } +}; +IrxFile irxUSB[] = { // USB mass + // USB drv & key { "USBD.IRX", USB | OPTIONAL | DEPENDANCY, USB_DRIVER, NULL, 0 }, - { "USB_MASS.IRX", USB | OPTIONAL, MASS_DRIVER, NULL, 0 }, + { "USB_MASS.IRX", USB | OPTIONAL, MASS_DRIVER, NULL, 0 } +}; + +IrxFile irxInput[] = { // USB input + // USB mouse & kbd { "PS2MOUSE.IRX", USB | OPTIONAL, MOUSE_DRIVER, NULL, 0 }, - { "RPCKBD.IRX", USB | OPTIONAL, KBD_DRIVER, NULL, 0 }, -#ifndef NO_ADAPTOR + { "RPCKBD.IRX", USB | OPTIONAL, KBD_DRIVER, NULL, 0 } +}; + +IrxFile irxHDD[] = { // modules to support HDD + // hdd modules { "POWEROFF.IRX", HDD | OPTIONAL | NOT_HOST | DEPENDANCY, HDD_DRIVER, NULL, 0 }, { "PS2DEV9.IRX", HDD | OPTIONAL | NOT_HOST | DEPENDANCY, HDD_DRIVER, NULL, 0 }, { "PS2ATAD.IRX", HDD | OPTIONAL | DEPENDANCY, HDD_DRIVER, NULL, 0 }, { "PS2HDD.IRX", HDD | OPTIONAL | DEPENDANCY, HDD_DRIVER, hddArg, sizeof(hddArg) }, - { "PS2FS.IRX", HDD | OPTIONAL | DEPENDANCY, HDD_DRIVER, pfsArg, sizeof(pfsArg) }, + { "PS2FS.IRX", HDD | OPTIONAL | DEPENDANCY, HDD_DRIVER, pfsArg, sizeof(pfsArg) } +}; + +IrxFile irxNet[] = { // modules to support NET + // net modules { "PS2IP.IRX", NET | OPTIONAL | NOT_HOST | DEPENDANCY, NET_DRIVER, NULL, 0 }, { "PS2SMAP.IRX", NET | OPTIONAL | NOT_HOST | DEPENDANCY, NET_DRIVER, netArg, sizeof(netArg) }, { "PS2HOST.IRX", NET | OPTIONAL | NOT_HOST | DEPENDANCY, NET_DRIVER, NULL, 0 } -#endif }; -static const int numIrxFiles = sizeof(irxFiles) / sizeof(irxFiles[0]); +IrxFile *irxType[IRX_MAX] = { irxCore, irxCdrom, irxUSB, irxInput, irxHDD, irxNet }; + +static const int numIrx[IRX_MAX] = { sizeof(irxCore) / sizeof(IrxFile), + sizeof(irxCdrom) / sizeof(IrxFile), + sizeof(irxUSB) / sizeof(IrxFile), + sizeof(irxInput) / sizeof(IrxFile), + sizeof(irxHDD) / sizeof(IrxFile), + sizeof(irxNet) / sizeof(IrxFile) +}; PS2Device detectBootPath(const char *elfPath, char *bootPath) { @@ -113,19 +141,26 @@ PS2Device detectBootPath(const char *elfPath, char *bootPath) { return device; } -int loadIrxModules(int device, const char *irxPath, IrxReference **modules) { +int loadIrxModules(int device, const char *irxPath, IrxReference **modules, IrxType type) { + + IrxReference *resModules; + IrxReference *curModule; + IrxFile *irxFiles; + int numFiles; - IrxReference *resModules = (IrxReference *)malloc(numIrxFiles * sizeof(IrxReference)); - IrxReference *curModule = resModules; + irxFiles = irxType[type]; + numFiles = numIrx[type]; + resModules = (IrxReference *)memalign(64, numFiles * sizeof(IrxReference)); + curModule = resModules; - for (int i = 0; i < numIrxFiles; i++) { + for (int i = 0; i < numFiles; i++) { curModule->fileRef = irxFiles + i; if ((device == HOST_DEV) && (irxFiles[i].flags & NOT_HOST)) continue; if ((irxFiles[i].flags & TYPEMASK) == BIOS) { curModule->loc = IRX_FILE; - curModule->path = (char *)malloc(32); + curModule->path = (char *)memalign(64, 32); sprintf(curModule->path, "rom0:%s", irxFiles[i].name); curModule->buffer = NULL; curModule->size = 0; @@ -134,7 +169,7 @@ int loadIrxModules(int device, const char *irxPath, IrxReference **modules) { curModule->errorCode = 0; } else { curModule->loc = IRX_BUFFER; - curModule->path = (char *)malloc(256); + curModule->path = (char *)memalign(64, 256); sprintf(curModule->path, "%s%s%s", irxPath, irxFiles[i].name, (device == CD_DEV) ? ";1" : ""); int fd = fioOpen(curModule->path, O_RDONLY); @@ -191,7 +226,7 @@ int loadIrxModules(int device, const char *irxPath, IrxReference **modules) { pos++; } // and skip any remaining modules that depend on the missing one, too. - while ((i < numIrxFiles - 1) && ((irxFiles[i + 1].flags & TYPEMASK) == (curModule->fileRef->flags & TYPEMASK))) + while ((i < numFiles - 1) && ((irxFiles[i + 1].flags & TYPEMASK) == (curModule->fileRef->flags & TYPEMASK))) i++; // the module that actually failed (curModule) is kept in the array for displaying an error message } diff --git a/backends/platform/ps2/irxboot.h b/backends/platform/ps2/irxboot.h index 81b47a37c6..487d335553 100644 --- a/backends/platform/ps2/irxboot.h +++ b/backends/platform/ps2/irxboot.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. @@ -25,6 +25,16 @@ #include "common/scummsys.h" +enum IrxType { + IRX_CORE = 0, + IRX_CDROM, + IRX_USB, + IRX_INPUT, + IRX_HDD, + IRX_NET, + IRX_MAX +}; + enum IrxFlags { BIOS = 0, SYSTEM = 1, @@ -40,6 +50,7 @@ enum IrxFlags { enum IrxPurpose { NOTHING, + CD_DRIVER, HDD_DRIVER, USB_DRIVER, MOUSE_DRIVER, @@ -81,6 +92,6 @@ struct IrxReference { int errorCode; }; -int loadIrxModules(int device, const char *irxPath, IrxReference **modules); +int loadIrxModules(int device, const char *irxPath, IrxReference **modules, IrxType type); #endif // __IRXBOOT_H__ diff --git a/backends/platform/ps2/module.mk b/backends/platform/ps2/module.mk index bf95a5501d..7bcc60e58d 100644 --- a/backends/platform/ps2/module.mk +++ b/backends/platform/ps2/module.mk @@ -2,20 +2,20 @@ MODULE := backends/platform/ps2 MODULE_OBJS := \ DmaPipe.o \ - Gs2dScreen.o \ - irxboot.o \ + Gs2dScreen.o \ + irxboot.o \ ps2input.o \ ps2pad.o \ savefilemgr.o \ - fileio.o \ - asyncfio.o \ + fileio.o \ + asyncfio.o \ icon.o \ - cd.o \ - eecodyvdfs.o \ - rpckbd.o \ - systemps2.o \ - ps2mutex.o \ - ps2time.o \ + cd.o \ + eecodyvdfs.o \ + rpckbd.o \ + systemps2.o \ + ps2mutex.o \ + ps2time.o \ ps2debug.o # We don't use rules.mk but rather manually update OBJS and MODULE_DIRS. diff --git a/backends/platform/ps2/ps2debug.cpp b/backends/platform/ps2/ps2debug.cpp index 300e18316f..84c3649faf 100644 --- a/backends/platform/ps2/ps2debug.cpp +++ b/backends/platform/ps2/ps2debug.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. @@ -22,10 +22,10 @@ #include "ps2debug.h" #include <stdio.h> -#include <stdlib.h> #include <sio.h> void sioprintf(const char *zFormat, ...) { + #if 0 // doesn't seem to work with ps2link... va_list ap; char resStr[2048]; @@ -43,4 +43,5 @@ void sioprintf(const char *zFormat, ...) { sio_putc(*pos); pos++; } + #endif } diff --git a/backends/platform/ps2/ps2debug.h b/backends/platform/ps2/ps2debug.h index 02831e0623..45db850ebf 100644 --- a/backends/platform/ps2/ps2debug.h +++ b/backends/platform/ps2/ps2debug.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. @@ -23,7 +23,13 @@ #ifndef __PS2DEBUG_H__ #define __PS2DEBUG_H__ -#define dbg_printf printf +#ifdef LOGORRHEIC + #define FORBIDDEN_SYMBOL_EXCEPTION_printf + // #define dbg_printf sio_printf + #define dbg_printf printf +#else + #define dbg_printf(...) /* ... */ +#endif void sioprintf(const char *zFormat, ...); diff --git a/backends/platform/ps2/ps2input.cpp b/backends/platform/ps2/ps2input.cpp index 6f36c5ff90..636176e06c 100644 --- a/backends/platform/ps2/ps2input.cpp +++ b/backends/platform/ps2/ps2input.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. @@ -170,7 +170,7 @@ bool Ps2Input::pollEvent(Common::Event *event) { } if (checkPadMouse || checkPadKbd) { // no usb mouse, simulate it using the pad - uint16 buttons; + uint16 buttons; int16 joyh, joyv; _pad->readPad(&buttons, &joyh, &joyv); uint16 btnChange = buttons ^ _padLastButtons; @@ -474,11 +474,11 @@ const Common::KeyCode Ps2Input::_usbToSdlk[0x100] = { /* DD */ Common::KEYCODE_INVALID, /* DE */ Common::KEYCODE_INVALID, /* DF */ Common::KEYCODE_INVALID, - /* E0 */ Common::KEYCODE_LCTRL, + /* E0 */ Common::KEYCODE_LCTRL, /* E1 */ Common::KEYCODE_LSHIFT, /* E2 */ Common::KEYCODE_LALT, /* E3 */ Common::KEYCODE_INVALID, - /* E4 */ Common::KEYCODE_RCTRL, + /* E4 */ Common::KEYCODE_RCTRL, /* E5 */ Common::KEYCODE_RSHIFT, /* E6 */ Common::KEYCODE_RALT, /* E7 */ Common::KEYCODE_INVALID, @@ -509,39 +509,39 @@ const Common::KeyCode Ps2Input::_usbToSdlk[0x100] = { }; const Common::KeyCode Ps2Input::_padCodes[16] = { - Common::KEYCODE_1, // Select - Common::KEYCODE_INVALID, // L3 - Common::KEYCODE_INVALID, // R3 - Common::KEYCODE_F5, // Start - Common::KEYCODE_INVALID, // Up - Common::KEYCODE_INVALID, // Right - Common::KEYCODE_INVALID, // Down - Common::KEYCODE_INVALID, // Left - Common::KEYCODE_KP0, // L2 - Common::KEYCODE_PERIOD, // R2 - Common::KEYCODE_n, // L1 - Common::KEYCODE_y, // R1 - Common::KEYCODE_ESCAPE, // Triangle - Common::KEYCODE_INVALID, // Circle => Right mouse button - Common::KEYCODE_INVALID, // Cross => Left mouse button - Common::KEYCODE_RETURN // Square + Common::KEYCODE_1, // Select + Common::KEYCODE_INVALID, // L3 + Common::KEYCODE_INVALID, // R3 + Common::KEYCODE_F5, // Start + Common::KEYCODE_INVALID, // Up + Common::KEYCODE_INVALID, // Right + Common::KEYCODE_INVALID, // Down + Common::KEYCODE_INVALID, // Left + Common::KEYCODE_KP0, // L2 + Common::KEYCODE_PERIOD, // R2 + Common::KEYCODE_n, // L1 + Common::KEYCODE_y, // R1 + Common::KEYCODE_ESCAPE, // Triangle + Common::KEYCODE_INVALID, // Circle => Right mouse button + Common::KEYCODE_INVALID, // Cross => Left mouse button + Common::KEYCODE_RETURN // Square }; const Common::KeyCode Ps2Input::_padFlags[16] = { - Common::KEYCODE_INVALID, // Select - Common::KEYCODE_INVALID, // L3 - Common::KEYCODE_INVALID, // R3 - Common::KEYCODE_INVALID, // Start - Common::KEYCODE_INVALID, // Up - Common::KEYCODE_INVALID, // Right - Common::KEYCODE_INVALID, // Down - Common::KEYCODE_INVALID, // Left - Common::KEYCODE_INVALID, // L2 - Common::KEYCODE_INVALID, // R2 - Common::KEYCODE_INVALID, // L1 - Common::KEYCODE_INVALID, // R1 - Common::KEYCODE_INVALID, // Triangle - Common::KEYCODE_INVALID, // Circle - Common::KEYCODE_INVALID, // Cross - Common::KEYCODE_INVALID // Square + Common::KEYCODE_INVALID, // Select + Common::KEYCODE_INVALID, // L3 + Common::KEYCODE_INVALID, // R3 + Common::KEYCODE_INVALID, // Start + Common::KEYCODE_INVALID, // Up + Common::KEYCODE_INVALID, // Right + Common::KEYCODE_INVALID, // Down + Common::KEYCODE_INVALID, // Left + Common::KEYCODE_INVALID, // L2 + Common::KEYCODE_INVALID, // R2 + Common::KEYCODE_INVALID, // L1 + Common::KEYCODE_INVALID, // R1 + Common::KEYCODE_INVALID, // Triangle + Common::KEYCODE_INVALID, // Circle + Common::KEYCODE_INVALID, // Cross + Common::KEYCODE_INVALID // Square }; diff --git a/backends/platform/ps2/ps2input.h b/backends/platform/ps2/ps2input.h index b97daac042..af413d262c 100644 --- a/backends/platform/ps2/ps2input.h +++ b/backends/platform/ps2/ps2input.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. @@ -44,7 +44,7 @@ private: int mapKey(int key, int mod); bool getKeyEvent(Common::Event *event, uint16 buttonCode, bool down); OSystem_PS2 *_system; - Ps2Pad *_pad; + Ps2Pad *_pad; uint16 _minx, _maxx, _miny, _maxy; diff --git a/backends/platform/ps2/ps2mutex.cpp b/backends/platform/ps2/ps2mutex.cpp index ae63fe5724..440a7e2cce 100644 --- a/backends/platform/ps2/ps2mutex.cpp +++ b/backends/platform/ps2/ps2mutex.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/ps2/ps2pad.cpp b/backends/platform/ps2/ps2pad.cpp index 607b614691..d990690331 100644 --- a/backends/platform/ps2/ps2pad.cpp +++ b/backends/platform/ps2/ps2pad.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. @@ -34,7 +34,7 @@ Ps2Pad::Ps2Pad(OSystem_PS2 *system) { _padStatus = STAT_NONE; padInit(0); // initialize library - _port = _slot = 0; // first controller, no multitap + _port = _slot = 0; // first controller, no multitap initPad(); } @@ -51,9 +51,6 @@ void Ps2Pad::initPad(void) { } else { if (checkPadReady(_port, _slot)) { switch (_padStatus) { - case STAT_NONE: - printf("Pad Status is None. Shouldn't happen\n"); - break; case STAT_OPEN: _padStatus = STAT_DETECT; break; @@ -104,7 +101,8 @@ void Ps2Pad::initPad(void) { _padStatus = STAT_OKAY; break; case STAT_OKAY: - // pad is already initialized + case STAT_NONE: + // pad is already initialized (or not there) break; } } else { diff --git a/backends/platform/ps2/ps2pad.h b/backends/platform/ps2/ps2pad.h index aebb3c6339..0457cd46bb 100644 --- a/backends/platform/ps2/ps2pad.h +++ b/backends/platform/ps2/ps2pad.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/ps2/ps2temp.h b/backends/platform/ps2/ps2temp.h index afffc6de2b..acfd3c7800 100644 --- a/backends/platform/ps2/ps2temp.h +++ b/backends/platform/ps2/ps2temp.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/ps2/ps2time.cpp b/backends/platform/ps2/ps2time.cpp index 1cddd230a0..e072ce9483 100644 --- a/backends/platform/ps2/ps2time.cpp +++ b/backends/platform/ps2/ps2time.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. @@ -30,9 +30,9 @@ #define FROM_BCD(a) ((a >> 4) * 10 + (a & 0xF)) -static int g_timeSecs; -static int g_day, g_month, g_year; -static int g_lastTimeCheck; +static int g_timeSecs; +static int g_day, g_month, g_year; +static int g_lastTimeCheck; extern volatile uint32 msecCount; void buildNewDate(int dayDiff) { diff --git a/backends/platform/ps2/rpckbd.c b/backends/platform/ps2/rpckbd.c index 0bb45208f5..e7975ab484 100644 --- a/backends/platform/ps2/rpckbd.c +++ b/backends/platform/ps2/rpckbd.c @@ -17,7 +17,7 @@ #include <string.h> #include "backends/platform/ps2/rpckbd.h" -static int curr_readmode = PS2KBD_READMODE_NORMAL; +static unsigned int curr_readmode = PS2KBD_READMODE_NORMAL; static int kbdRpcSema = -1; static int kbdInitialized = 0; diff --git a/backends/platform/ps2/rpckbd.h b/backends/platform/ps2/rpckbd.h index bffd8e5be5..22cbbb4d21 100644 --- a/backends/platform/ps2/rpckbd.h +++ b/backends/platform/ps2/rpckbd.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/ps2/savefilemgr.cpp b/backends/platform/ps2/savefilemgr.cpp index 46af42e193..4fd2b1c72b 100644 --- a/backends/platform/ps2/savefilemgr.cpp +++ b/backends/platform/ps2/savefilemgr.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. @@ -21,8 +21,6 @@ */ #define FORBIDDEN_SYMBOL_EXCEPTION_printf -#define FORBIDDEN_SYMBOL_EXCEPTION_mkdir -#define FORBIDDEN_SYMBOL_EXCEPTION_unistd_h #include "common/config-manager.h" #include "common/zlib.h" @@ -37,6 +35,7 @@ #include "savefilemgr.h" #include "Gs2dScreen.h" #include "ps2temp.h" +#include "ps2debug.h" extern AsyncFio fio; @@ -57,20 +56,20 @@ bool Ps2SaveFileManager::mcCheck(const char *path) { // int res; - printf("mcCheck\n"); + dbg_printf("mcCheck\n"); if (!dir.exists()) { - printf("! exist -> create : "); + dbg_printf("! exist -> create : "); #ifdef __USE_LIBMC__ - printf("%s\n", path+4); + dbg_printf("%s\n", path+4); // WaitSema(_sema); mcSync(0, NULL, NULL); mcMkDir(0 /*port*/, 0 /*slot*/, path+4); mcSync(0, NULL, &res); - printf("sync : %d\n", res); + dbg_printf("sync : %d\n", res); // SignalSema(_sema); #else - printf("%s\n", path); + dbg_printf("%s\n", path); fio.mkdir(path); #endif } @@ -108,7 +107,7 @@ Common::InSaveFile *Ps2SaveFileManager::openForLoading(const Common::String &fil } else { char temp[32]; - printf("MC : filename = %s\n", filename.c_str()); + dbg_printf("MC : filename = %s\n", filename.c_str()); strcpy(temp, filename.c_str()); // mcSplit(temp, game, ext); @@ -149,7 +148,7 @@ Common::OutSaveFile *Ps2SaveFileManager::openForSaving(const Common::String &fil Common::FSNode savePath(ConfMan.get("savepath")); // TODO: is this fast? Common::WriteStream *sf; - printf("openForSaving : %s\n", filename.c_str()); + dbg_printf("openForSaving : %s\n", filename.c_str()); if (!savePath.exists() || !savePath.isDirectory()) return NULL; @@ -166,10 +165,10 @@ Common::OutSaveFile *Ps2SaveFileManager::openForSaving(const Common::String &fil sprintf(path, "mc0:ScummVM/indy4/iq-points"); } // FIXME : hack for bs1 saved games - else if (filename == "SAVEGAME.INF") { - mcCheck("mc0:ScummVM/sword1"); - sprintf(path, "mc0:ScummVM/sword1/SAVEGAME.INF"); - } + else if (filename == "SAVEGAME.INF") { + mcCheck("mc0:ScummVM/sword1"); + sprintf(path, "mc0:ScummVM/sword1/SAVEGAME.INF"); + } else { char temp[32]; strcpy(temp, filename.c_str()); @@ -240,7 +239,7 @@ Common::StringArray Ps2SaveFileManager::listSavefiles(const Common::String &patt if (!savePath.exists() || !savePath.isDirectory()) return Common::StringArray(); - printf("listSavefiles = %s\n", pattern.c_str()); + dbg_printf("listSavefiles = %s\n", pattern.c_str()); if (_mc) { strcpy(temp, pattern.c_str()); @@ -263,7 +262,7 @@ Common::StringArray Ps2SaveFileManager::listSavefiles(const Common::String &patt Common::ArchiveMemberList savefiles; Common::StringArray results; - printf("dir = %s --- reg = %s\n", _dir.c_str(), search.c_str()); + dbg_printf("dir = %s --- reg = %s\n", _dir.c_str(), search.c_str()); if (dir.listMatchingMembers(savefiles, search) > 0) { for (Common::ArchiveMemberList::const_iterator file = savefiles.begin(); file != savefiles.end(); ++file) { @@ -272,11 +271,11 @@ Common::StringArray Ps2SaveFileManager::listSavefiles(const Common::String &patt temp[3] = '\0'; sprintf(path, "%s.%s", game, temp); results.push_back(path); - printf(" --> found = %s -> %s\n", (*file)->getName().c_str(), path); + dbg_printf(" --> found = %s -> %s\n", (*file)->getName().c_str(), path); } else { results.push_back((*file)->getName()); - printf(" --> found = %s\n", (*file)->getName().c_str()); + dbg_printf(" --> found = %s\n", (*file)->getName().c_str()); } } } diff --git a/backends/platform/ps2/savefilemgr.h b/backends/platform/ps2/savefilemgr.h index 163706eace..547f16fa77 100644 --- a/backends/platform/ps2/savefilemgr.h +++ b/backends/platform/ps2/savefilemgr.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/ps2/sysdefs.h b/backends/platform/ps2/sysdefs.h index 0114402233..c886d70eef 100644 --- a/backends/platform/ps2/sysdefs.h +++ b/backends/platform/ps2/sysdefs.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. @@ -40,30 +40,30 @@ enum Interrupts { }; // dma 2 registers -#define D2_CHCR (*(volatile uint32*)0x1000A000) -#define D2_QWC (*(volatile uint32*)0x1000A020) -#define D2_TADR (*(volatile uint32*)0x1000A030) -#define D2_MADR (*(volatile uint32*)0x1000A010) -#define D2_ASR1 (*(volatile uint32*)0x1000A050) -#define D2_ASR0 (*(volatile uint32*)0x1000A040) +#define D2_CHCR (*(volatile uint32 *)0x1000A000) +#define D2_QWC (*(volatile uint32 *)0x1000A020) +#define D2_TADR (*(volatile uint32 *)0x1000A030) +#define D2_MADR (*(volatile uint32 *)0x1000A010) +#define D2_ASR1 (*(volatile uint32 *)0x1000A050) +#define D2_ASR0 (*(volatile uint32 *)0x1000A040) -#define D_CTRL (*(volatile uint32*)0x1000E000) -#define D_STAT (*(volatile uint32*)0x1000E010) -#define D_PCR (*(volatile uint32*)0x1000E020) -#define D_SQWC (*(volatile uint32*)0x1000E030) -#define D_RBSR (*(volatile uint32*)0x1000E040) -#define D_RBOR (*(volatile uint32*)0x1000E050) -#define D_STADR (*(volatile uint32*)0x1000E060) +#define D_CTRL (*(volatile uint32 *)0x1000E000) +#define D_STAT (*(volatile uint32 *)0x1000E010) +#define D_PCR (*(volatile uint32 *)0x1000E020) +#define D_SQWC (*(volatile uint32 *)0x1000E030) +#define D_RBSR (*(volatile uint32 *)0x1000E040) +#define D_RBOR (*(volatile uint32 *)0x1000E050) +#define D_STADR (*(volatile uint32 *)0x1000E060) #define CIM2 (1 << 18) #define CIS2 (1 << 2) // timer 0 registers -#define T0_COUNT (*(volatile uint32*)0x10000000) -#define T0_MODE (*(volatile uint32*)0x10000010) -#define T0_COMP (*(volatile uint32*)0x10000020) -#define T0_HOLD (*(volatile uint32*)0x10000030) +#define T0_COUNT (*(volatile uint32 *)0x10000000) +#define T0_MODE (*(volatile uint32 *)0x10000010) +#define T0_COMP (*(volatile uint32 *)0x10000020) +#define T0_HOLD (*(volatile uint32 *)0x10000030) #define TIMER_MODE(clks, gate, gates, gatem, zeroret, cue, cmpe, ovfe, equf, ovff) \ ((clks) | ((gate) << 2) | ((gates) << 3) | ((gatem) << 4) | ((zeroret) << 6) | \ diff --git a/backends/platform/ps2/systemps2.cpp b/backends/platform/ps2/systemps2.cpp index a7d782b07c..1aa74b7d9b 100644 --- a/backends/platform/ps2/systemps2.cpp +++ b/backends/platform/ps2/systemps2.cpp @@ -8,20 +8,21 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. * */ -// Disable symbol overrides so that we can use system headers. -#define FORBIDDEN_SYMBOL_ALLOW_ALL +// Disable symbol overrides so that we can use "FILE" +#define FORBIDDEN_SYMBOL_EXCEPTION_FILE +#define FORBIDDEN_SYMBOL_EXCEPTION_printf #include <kernel.h> #include <stdio.h> @@ -50,7 +51,6 @@ #include "backends/platform/ps2/cd.h" #include "backends/platform/ps2/fileio.h" #include "backends/platform/ps2/Gs2dScreen.h" -#include "backends/platform/ps2/irxboot.h" #include "backends/platform/ps2/ps2debug.h" #include "backends/platform/ps2/ps2input.h" #include "backends/platform/ps2/savefilemgr.h" @@ -112,7 +112,11 @@ extern "C" int scummvm_main(int argc, char *argv[]); extern "C" int main(int argc, char *argv[]) { SifInitRpc(0); + #ifdef __NEW_PS2SDK__ + ee_thread_status_t thisThread; + #else ee_thread_t thisThread; + #endif int tid = GetThreadId(); ReferThreadStatus(tid, &thisThread); @@ -147,6 +151,10 @@ extern "C" int main(int argc, char *argv[]) { g_systemPs2->quit(); +#ifdef ENABLE_PROFILING + // make sure we can flush "gmon.out" + fileXioSetBlockMode(FXIO_WAIT); +#endif // control never gets here return res; } @@ -184,13 +192,11 @@ void systemSoundThread(OSystem_PS2 *system) { } void gluePowerOffCallback(void *system) { - ((OSystem_PS2*)system)->powerOffCallback(); + ((OSystem_PS2 *)system)->powerOffCallback(); } void OSystem_PS2::startIrxModules(int numModules, IrxReference *modules) { - _usbMassLoaded = _useMouse = _useKbd = _useHdd = _useNet = false; - int res = 0, rv = 0; for (int i = 0; i < numModules; i++) { if (modules[i].loc == IRX_FILE) { @@ -216,6 +222,9 @@ void OSystem_PS2::startIrxModules(int numModules, IrxReference *modules) { case KBD_DRIVER: _useKbd = true; break; + case CD_DRIVER: + _useCd = true; + break; case HDD_DRIVER: _useHdd = true; break; @@ -241,20 +250,79 @@ void OSystem_PS2::startIrxModules(int numModules, IrxReference *modules) { } if (modules[i].buffer) - free(modules[i].buffer); + ; // free(modules[i].buffer); } else { sioprintf("module %d of %d damaged, loc %d, path %s\n", i, numModules, modules[i].loc, modules[i].path); } - free(modules[i].path); + // free(modules[i].path); } - free(modules); + // free(modules); sioprintf("done\n"); sioprintf("UsbMass: %sloaded\n", _usbMassLoaded ? "" : "not "); sioprintf("Mouse: %sloaded\n", _useMouse ? "" : "not "); sioprintf("Kbd: %sloaded\n", _useKbd ? "" : "not "); + sioprintf("Cd: %sloaded\n", _useCd ? "" : "not "); sioprintf("Hdd: %sloaded\n", _useHdd ? "" : "not "); } +bool OSystem_PS2::loadDrivers(IrxType type) +{ + IrxReference *modules; + int numModules; + int res; + + numModules = loadIrxModules(_bootDevice, _bootPath, &modules, type); + // TODO: for IRX_NET allows override IP addr + startIrxModules(numModules, modules); + + switch (type) { + case IRX_CORE: + /* Init I/O */ + if ((res = fileXioInit()) < 0) { + msgPrintf(FOREVER, "FXIO init failed: %d", res); + quit(); + } + /* Init sound */ + if ((res = SjPCM_Init(0)) < 0) { + msgPrintf(FOREVER, "SjPCM bind failed: %d\n", res); + quit(); + } + break; + + case IRX_CDROM: + /* Init CDROM & RTC Clock */ + if ((res = initCdvdFs()) < 0) { + msgPrintf(FOREVER, "CoDyVDfs bind failed: %d", res); + quit(); + } + sioprintf("Reading RTC\n"); + readRtcTime(); /* depends on CDROM driver! */ + break; + + case IRX_HDD: + /* Check HD is available and formatted */ + if ((hddCheckPresent() < 0) || (hddCheckFormatted() < 0)) { + _useHdd = false; + } + else { + poweroffInit(); + poweroffSetCallback(gluePowerOffCallback, this); + } + break; + + case IRX_NET: + if (_bootDevice == HOST_DEV) // net is pre-loaded on host + _useNet = true; // so we need to set by hand + break; + + default: + /* zzz */ + break; + } + + return true; +} + OSystem_PS2::OSystem_PS2(const char *elfPath) { _soundStack = _timerStack = NULL; _printY = 0; @@ -262,20 +330,19 @@ OSystem_PS2::OSystem_PS2(const char *elfPath) { _systemQuit = false; _modeChanged = false; _screenChangeCount = 0; + _mouseVisible = false; - _screen = new Gs2dScreen(320, 200, TV_DONT_CARE); + // _screen = new Gs2dScreen(320, 200, TV_DONT_CARE); // moved to ::initSize sioprintf("Initializing system...\n"); - _screen->wantAnim(true); + // _screen->wantAnim(true); - _bootPath = (char *)malloc(128); + _bootPath = (char *)memalign(64, 128); _bootDevice = detectBootPath(elfPath, _bootPath); - IrxReference *modules; - int numModules = loadIrxModules(_bootDevice, _bootPath, &modules); - if (_bootDevice != HOST_DEV) { + // TODO: reset funx sioprintf("Resetting IOP.\n"); cdvdInit(CDVD_EXIT); cdvdExit(); @@ -298,50 +365,12 @@ OSystem_PS2::OSystem_PS2(const char *elfPath) { // TODO: ps2link 1.46 will stall on "poweroff" init / cb } - startIrxModules(numModules, modules); - - int res; - if ((res = fileXioInit()) < 0) { - msgPrintf(FOREVER, "FXIO Init failed: %d", res); - quit(); - } - - if ((res = initCdvdFs()) < 0) { - msgPrintf(FOREVER, "CoDyVDfs bind failed: %d", res); - quit(); - } - - if ((res = SjPCM_Init(0)) < 0) { - msgPrintf(FOREVER, "SjPCM Bind failed: %d\n", res); - quit(); - } - - if (_useHdd) { - if ((hddCheckPresent() < 0) || (hddCheckFormatted() < 0)) - _useHdd = false; - - //hddPreparePoweroff(); - poweroffInit(); + _usbMassLoaded = _useMouse = _useKbd = _useCd = _useHdd = _useNet = false; - //hddSetUserPoweroffCallback(gluePowerOffCallback, this); - poweroffSetCallback(gluePowerOffCallback, this); - } + loadDrivers(IRX_CORE); + loadDrivers(IRX_CDROM); // consider CDROM as "core", as RTC depends on it fileXioSetBlockMode(FXIO_NOWAIT); - - _mouseVisible = false; - - sioprintf("reading RTC\n"); - readRtcTime(); - - if (_useHdd) { - // TODO : make partition path configurable - if (fio.mount("pfs0:", "hdd0:+ScummVM", 0) >= 0) - printf("Successfully mounted!\n"); - else - _useHdd = false; - } - initMutexes(); } @@ -356,14 +385,67 @@ void OSystem_PS2::init(void) { sioprintf("Starting SavefileManager\n"); _savefileManager = new Ps2SaveFileManager(this, _screen); - sioprintf("Initializing ps2Input\n"); - _input = new Ps2Input(this, _useMouse, _useKbd); - prepMC(); makeConfigPath(); - _screen->wantAnim(false); - fillScreen(0); + // _screen->wantAnim(false); + // fillScreen(0); +} + +void OSystem_PS2::config(void) { + #ifndef NO_ADAPTOR + if (ConfMan.hasKey("hdd_part", "PlayStation2")) { // "hdd" ? + const char *hdd = ConfMan.get("hdd_part", "PlayStation2").c_str(); + + if ( !strcmp(hdd, "0") || !strcmp(hdd, "no") || !strcmp(hdd, "disable") ) { + _useHdd = false; + } + else { + loadDrivers(IRX_HDD); + hddMount(hdd); + } + } + else { // check for HDD and assume partition is +ScummVM + loadDrivers(IRX_HDD); + hddMount("ScummVM"); + } + + if (ConfMan.hasKey("net_addr", "PlayStation2")) { // "net" ? + const char *net = ConfMan.get("net_addr", "PlayStation2").c_str(); + + if ( !strcmp(net, "0") || !strcmp(net, "no") || !strcmp(net, "disable") ) { + _useNet = false; + } + else { + loadDrivers(IRX_NET); + // TODO: netInit("xxx.xxx.xxx.xxx"); + } + } + else { // setup net - IP hardcoded 192.168.1.20 + loadDrivers(IRX_NET); + } + #endif + + // why USB drivers only load correctly post HDD ? + if (ConfMan.hasKey("usb_mass", "PlayStation2")) { // "usb" ? + const char *usb = ConfMan.get("usb_mass", "PlayStation2").c_str(); + + if ( !strcmp(usb, "0") || !strcmp(usb, "no") || !strcmp(usb, "disable") ) { + _usbMassLoaded = false; + } + else { + loadDrivers(IRX_USB); + loadDrivers(IRX_INPUT); + sioprintf("Initializing ps2Input\n"); + _input = new Ps2Input(this, _useMouse, _useKbd); + } + } + else { // load USB drivers (mass & input( + loadDrivers(IRX_USB); + loadDrivers(IRX_INPUT); + sioprintf("Initializing ps2Input\n"); + _input = new Ps2Input(this, _useMouse, _useKbd); + } } OSystem_PS2::~OSystem_PS2(void) { @@ -380,26 +462,40 @@ void OSystem_PS2::initTimer(void) { g_TimerThreadSema = CreateSema(&threadSema); g_SoundThreadSema = CreateSema(&threadSema); assert((g_TimerThreadSema >= 0) && (g_SoundThreadSema >= 0)); - + #ifdef __NEW_PS2SDK__ + ee_thread_t timerThread, soundThread; + ee_thread_status_t thisThread; + #else ee_thread_t timerThread, soundThread, thisThread; + #endif ReferThreadStatus(GetThreadId(), &thisThread); - _timerStack = (uint8 *)malloc(TIMER_STACK_SIZE); - _soundStack = (uint8 *)malloc(SOUND_STACK_SIZE); + _timerStack = (uint8 *)memalign(64, TIMER_STACK_SIZE); + _soundStack = (uint8 *)memalign(64, SOUND_STACK_SIZE); + // gprof doesn't cope with higher thread priority too well + #ifdef ENABLE_PROFILING + timerThread.initial_priority = thisThread.current_priority; + #else // give timer thread a higher priority than main thread timerThread.initial_priority = thisThread.current_priority - 1; + #endif timerThread.stack = _timerStack; timerThread.stack_size = TIMER_STACK_SIZE; timerThread.func = (void *)systemTimerThread; - timerThread.gp_reg = &_gp; + timerThread.gp_reg = &_gp; + // gprof doesn't cope with higher thread priority too well + #ifdef ENABLE_PROFILING + soundThread.initial_priority = thisThread.current_priority; + #else // soundthread's priority is higher than main- and timerthread soundThread.initial_priority = thisThread.current_priority - 2; + #endif soundThread.stack = _soundStack; soundThread.stack_size = SOUND_STACK_SIZE; soundThread.func = (void *)systemSoundThread; - soundThread.gp_reg = &_gp; + soundThread.gp_reg = &_gp; _timerTid = CreateThread(&timerThread); _soundTid = CreateThread(&soundThread); @@ -459,39 +555,39 @@ void OSystem_PS2::soundThreadCallback(void) { // demux data into 2 buffers, L and R __asm__ ( - "move $t2, %1\n\t" // dest buffer right - "move $t3, %0\n\t" // dest buffer left - "lui $t8, 0x7000\n\t" // muxed buffer, fixed at 0x70000000 - "addiu $t9, $0, 100\n\t" // number of loops - "mtsab $0, 2\n\t" // set qword shift = 2 byte + "move $t2, %1\n\t" // dest buffer right + "move $t3, %0\n\t" // dest buffer left + "lui $t8, 0x7000\n\t" // muxed buffer, fixed at 0x70000000 + "addiu $t9, $0, 100\n\t" // number of loops + "mtsab $0, 2\n\t" // set qword shift = 2 byte "loop:\n\t" - " lq $t4, 0($t8)\n\t" // load 8 muxed samples - " lq $t5, 16($t8)\n\t" // load 8 more muxed samples + " lq $t4, 0($t8)\n\t" // load 8 muxed samples + " lq $t5, 16($t8)\n\t" // load 8 more muxed samples - " qfsrv $t6, $0, $t4\n\t" // shift right for second - " qfsrv $t7, $0, $t5\n\t" // packing step (right channel) + " qfsrv $t6, $0, $t4\n\t" // shift right for second + " qfsrv $t7, $0, $t5\n\t" // packing step (right channel) - " ppach $t4, $t5, $t4\n\t" // combine left channel data - " ppach $t6, $t7, $t6\n\t" // right channel data + " ppach $t4, $t5, $t4\n\t" // combine left channel data + " ppach $t6, $t7, $t6\n\t" // right channel data - " sq $t4, 0($t3)\n\t" // write back - " sq $t6, 0($t2)\n\t" // + " sq $t4, 0($t3)\n\t" // write back + " sq $t6, 0($t2)\n\t" // - " addiu $t9, -1\n\t" // decrement loop counter - " addiu $t2, 16\n\t" // increment pointers + " addiu $t9, -1\n\t" // decrement loop counter + " addiu $t2, 16\n\t" // increment pointers " addiu $t3, 16\n\t" " addiu $t8, 32\n\t" - " bnez $t9, loop\n\t" // loop + " bnez $t9, loop\n\t" // loop : // outputs : "r"(soundBufL), "r"(soundBufR) // inputs - // : "$t2", "$t3", "$t4", "$t5", "$t6", "$t7", "$t8", "$t9" // destroyed + // : "$t2", "$t3", "$t4", "$t5", "$t6", "$t7", "$t8", "$t9" // destroyed : "$10", "$11", "$12", "$13", "$14", "$15", "$24", "$25" // destroyed ); // and feed it into the SPU // non-blocking call, the function will return before the buffer's content // was transferred. - SjPCM_Enqueue((short int*)soundBufL, (short int*)soundBufR, SMP_PER_BLOCK, 0); + SjPCM_Enqueue((short int *)soundBufL, (short int *)soundBufR, SMP_PER_BLOCK, 0); bufferedSamples += SMP_PER_BLOCK; } } @@ -510,6 +606,10 @@ bool OSystem_PS2::mcPresent(void) { return false; } +bool OSystem_PS2::cdPresent(void) { + return _useCd; +} + bool OSystem_PS2::hddPresent(void) { return _useHdd; } @@ -528,11 +628,39 @@ bool OSystem_PS2::usbMassPresent(void) { } bool OSystem_PS2::netPresent(void) { - return _useNet; + if (_useNet) + return true; + + return false; +} + +bool OSystem_PS2::hddMount(const char *partition) { + char name[64] = "hdd0:+ScummVM"; + + if (partition) + strcpy(name+6, partition); + + if (fio.mount("pfs0:", name, 0) >= 0) { + dbg_printf("Successfully mounted (%s)!\n", name); + return true; + } + else { + dbg_printf("Failed to mount (%s).\n", name); + _useHdd = false; + return false; + } } void OSystem_PS2::initSize(uint width, uint height, const Graphics::PixelFormat *format) { - printf("initializing new size: (%d/%d)...", width, height); + dbg_printf("initializing new size: (%d/%d)...", width, height); + + /* ugly hack: we know we can parse ScummVM.ini now */ + if (!_screenChangeCount) { // first round + config(); + _screen = new Gs2dScreen(width, height); + fillScreen(0); + } + _screen->newScreenSize(width, height); _screen->setMouseXy(width / 2, height / 2); _input->newRange(0, 0, width - 1, height - 1); @@ -543,7 +671,7 @@ void OSystem_PS2::initSize(uint width, uint height, const Graphics::PixelFormat _modeChanged = true; _screenChangeCount++; - printf("done\n"); + dbg_printf("done\n"); } void OSystem_PS2::setPalette(const byte *colors, uint start, uint num) { @@ -555,7 +683,7 @@ void OSystem_PS2::grabPalette(byte *colors, uint start, uint num) { } void OSystem_PS2::copyRectToScreen(const void *buf, int pitch, int x, int y, int w, int h) { - _screen->copyScreenRect((const uint8*)buf, pitch, x, y, w, h); + _screen->copyScreenRect((const uint8 *)buf, pitch, x, y, w, h); } void OSystem_PS2::updateScreen(void) { @@ -568,7 +696,7 @@ void OSystem_PS2::updateScreen(void) { void OSystem_PS2::displayMessageOnOSD(const char *msg) { /* TODO : check */ - printf("displayMessageOnOSD: %s\n", msg); + dbg_printf("displayMessageOnOSD: %s\n", msg); } uint32 OSystem_PS2::getMillis(bool skipRecord) { @@ -666,7 +794,7 @@ void OSystem_PS2::unlockScreen(void) { const OSystem::GraphicsMode OSystem_PS2::_graphicsMode = { NULL, NULL, 0 }; const OSystem::GraphicsMode *OSystem_PS2::getSupportedGraphicsModes(void) const { - return &_graphicsMode; + return &_graphicsMode; } bool OSystem_PS2::setGraphicsMode(int mode) { @@ -735,7 +863,7 @@ void OSystem_PS2::msgPrintf(int millis, const char *format, ...) { Graphics::g_sysfont.drawString(&surf, str, posX, posY, 300 - posX, 1); posY += 14; - lnSta = lnEnd + 1; + lnSta = lnEnd + 1; } uint8 *scrBuf = (uint8 *)memalign(64, 320 * 200); @@ -768,12 +896,14 @@ void OSystem_PS2::powerOffCallback(void) { } void OSystem_PS2::quit(void) { - printf("OSystem_PS2::quit called\n"); + dbg_printf("OSystem_PS2::quit called\n"); if (_bootDevice == HOST_DEV) { - printf("OSystem_PS2::quit (HOST)\n"); + dbg_printf("OSystem_PS2::quit (HOST)\n"); + #ifndef ENABLE_PROFILING SleepThread(); + #endif } else { - printf("OSystem_PS2::quit (bootdev=%d)\n", _bootDevice); + dbg_printf("OSystem_PS2::quit (bootdev=%d)\n", _bootDevice); if (_useHdd) { driveStandby(); fio.umount("pfs0:"); @@ -781,18 +911,22 @@ void OSystem_PS2::quit(void) { //setTimerCallback(NULL, 0); _screen->wantAnim(false); _systemQuit = true; + #ifdef __NEW_PS2SDK__ + ee_thread_status_t statSound, statTimer; + #else ee_thread_t statSound, statTimer; - printf("Waiting for timer and sound thread to end\n"); + #endif + dbg_printf("Waiting for timer and sound thread to end\n"); do { // wait until both threads called ExitThread() ReferThreadStatus(_timerTid, &statTimer); ReferThreadStatus(_soundTid, &statSound); } while ((statSound.status != 0x10) || (statTimer.status != 0x10)); - printf("Done\n"); + dbg_printf("Done\n"); DeleteThread(_timerTid); DeleteThread(_soundTid); free(_timerStack); free(_soundStack); - printf("Stopping timer\n"); + dbg_printf("Stopping timer\n"); DisableIntc(INT_TIMER0); RemoveIntcHandler(INT_TIMER0, _intrId); @@ -801,7 +935,7 @@ void OSystem_PS2::quit(void) { padEnd(); // stop pad library cdvdInit(CDVD_EXIT); - printf("resetting iop\n"); + dbg_printf("resetting iop\n"); SifIopReset(NULL, 0); SifExitRpc(); while (!SifIopSync()); @@ -829,7 +963,7 @@ void OSystem_PS2::quit(void) { " li $3, 0x04;" " syscall;" " nop;" - ); + ); */ /* @@ -839,7 +973,7 @@ void OSystem_PS2::quit(void) { */ #else // reset + load ELF from CD - printf("Restarting ScummVM\n"); + dbg_printf("Restarting ScummVM\n"); LoadExecPS2("cdrom0:\\SCUMMVM.ELF", 0, NULL); #endif } @@ -856,12 +990,12 @@ bool OSystem_PS2::prepMC() { if (!mcPresent()) return prep; - printf("prepMC 0\n"); + dbg_printf("prepMC 0\n"); // Common::String str("mc0:ScummVM/") // Common::FSNode scumDir(str); Common::FSNode scumDir("mc0:ScummVM/"); - printf("prepMC 00\n"); + dbg_printf("prepMC 00\n"); if (!scumDir.exists()) { uint16 *data, size; @@ -869,11 +1003,11 @@ bool OSystem_PS2::prepMC() { PS2Icon _ico; mcIcon icon; - printf("prepMC I\n"); + dbg_printf("prepMC I\n"); size = _ico.decompressData(&data); - printf("prepMC II\n"); + dbg_printf("prepMC II\n"); _ico.setup(&icon); @@ -888,21 +1022,21 @@ bool OSystem_PS2::prepMC() { fio.mkdir("mc0:ScummVM"); f = ps2_fopen("mc0:ScummVM/scummvm.icn", "w"); - printf("f = %p\n", (const void *)f); + dbg_printf("f = %p\n", (const void *)f); ps2_fwrite(data, size, 2, f); ps2_fclose(f); f = ps2_fopen("mc0:ScummVM/icon.sys", "w"); - printf("f = %p\n", (const void *)f); + dbg_printf("f = %p\n", (const void *)f); ps2_fwrite(&icon, sizeof(icon), 1, f); ps2_fclose(f); #endif free(data); - printf("prepMC II\n"); + dbg_printf("prepMC II\n"); prep = true; } @@ -911,7 +1045,7 @@ bool OSystem_PS2::prepMC() { } void OSystem_PS2::makeConfigPath() { - FILE *src, *dst; + FILE *src, *dst; char path[128], *buf; int32 size; @@ -926,7 +1060,7 @@ void OSystem_PS2::makeConfigPath() { src = ps2_fopen("cdfs:ScummVM.ini", "r"); if (src) { size = ((Ps2File *)src)->size(); - buf = (char *)malloc(size); + buf = (char *)memalign(64, size); ps2_fread(buf, size, 1, src); ps2_fclose(src); @@ -970,6 +1104,5 @@ Common::String OSystem_PS2::getDefaultConfigFileName() { } void OSystem_PS2::logMessage(LogMessageType::Type type, const char *message) { - printf("%s", message); - sioprintf("%s", message); + dbg_printf("%s", message); } diff --git a/backends/platform/ps2/systemps2.h b/backends/platform/ps2/systemps2.h index 3ba40a70f9..45b7dfae36 100644 --- a/backends/platform/ps2/systemps2.h +++ b/backends/platform/ps2/systemps2.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. @@ -25,6 +25,7 @@ #include "common/system.h" #include "backends/base-backend.h" +#include "backends/platform/ps2/irxboot.h" #include "graphics/palette.h" class Gs2dScreen; @@ -51,6 +52,7 @@ public: virtual void initSize(uint width, uint height, const Graphics::PixelFormat *format); void init(void); + void config(void); virtual int16 getHeight(void); virtual int16 getWidth(void); @@ -119,14 +121,17 @@ public: void powerOffCallback(void); bool mcPresent(void); + bool cdPresent(void); bool hddPresent(void); bool usbMassPresent(void); bool netPresent(void); + bool hddMount(const char *partition); bool runningFromHost(void); int getBootDevice() { return _bootDevice; } private: + bool loadDrivers(IrxType type); void startIrxModules(int numModules, IrxReference *modules); void initMutexes(void); @@ -136,28 +141,28 @@ private: Audio::MixerImpl *_scummMixer; bool _mouseVisible; - bool _useMouse, _useKbd, _useHdd, _usbMassLoaded, _useNet; + bool _useMouse, _useKbd, _useCd, _useHdd, _usbMassLoaded, _useNet; - Gs2dScreen *_screen; - Ps2Input *_input; - uint16 _oldMouseX, _oldMouseY; - uint32 _msgClearTime; - uint16 _printY; + Gs2dScreen *_screen; + Ps2Input *_input; + uint16 _oldMouseX, _oldMouseY; + uint32 _msgClearTime; + uint16 _printY; bool _modeChanged; int _screenChangeCount; - int _mutexSema; - Ps2Mutex _mutex[MAX_MUTEXES]; + int _mutexSema; + Ps2Mutex _mutex[MAX_MUTEXES]; - uint8 *_timerStack, *_soundStack; - int _timerTid, _soundTid; - int _intrId; + uint8 *_timerStack, *_soundStack; + int _timerTid, _soundTid; + int _intrId; volatile bool _systemQuit; static const GraphicsMode _graphicsMode; - int _bootDevice; - char *_bootPath; - char *_configFile; + int _bootDevice; + char *_bootPath; + char *_configFile; }; #endif // SYSTEMPS2_H diff --git a/backends/platform/psp/audio.cpp b/backends/platform/psp/audio.cpp index dcbf0b2239..53423b6bbb 100644 --- a/backends/platform/psp/audio.cpp +++ b/backends/platform/psp/audio.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/psp/audio.h b/backends/platform/psp/audio.h index 34ded5c638..04f8954840 100644 --- a/backends/platform/psp/audio.h +++ b/backends/platform/psp/audio.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/psp/cursor.cpp b/backends/platform/psp/cursor.cpp index b295507de1..0760bd1354 100644 --- a/backends/platform/psp/cursor.cpp +++ b/backends/platform/psp/cursor.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/psp/cursor.h b/backends/platform/psp/cursor.h index f79968243b..85a6cbcc34 100644 --- a/backends/platform/psp/cursor.h +++ b/backends/platform/psp/cursor.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/psp/default_display_client.cpp b/backends/platform/psp/default_display_client.cpp index 6d6eb641f7..f2d8a7c03c 100644 --- a/backends/platform/psp/default_display_client.cpp +++ b/backends/platform/psp/default_display_client.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/psp/default_display_client.h b/backends/platform/psp/default_display_client.h index 95c52e2352..d46b7f1a8a 100644 --- a/backends/platform/psp/default_display_client.h +++ b/backends/platform/psp/default_display_client.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/psp/display_client.cpp b/backends/platform/psp/display_client.cpp index bc29166895..b238631e62 100644 --- a/backends/platform/psp/display_client.cpp +++ b/backends/platform/psp/display_client.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/psp/display_client.h b/backends/platform/psp/display_client.h index e384bfb82b..5e81947e20 100644 --- a/backends/platform/psp/display_client.h +++ b/backends/platform/psp/display_client.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/psp/display_manager.cpp b/backends/platform/psp/display_manager.cpp index c2ff84c7f5..2e995c809e 100644 --- a/backends/platform/psp/display_manager.cpp +++ b/backends/platform/psp/display_manager.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/psp/display_manager.h b/backends/platform/psp/display_manager.h index 38c43d60a3..b1b748a68c 100644 --- a/backends/platform/psp/display_manager.h +++ b/backends/platform/psp/display_manager.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/psp/dummy.cpp b/backends/platform/psp/dummy.cpp index 998ecf1488..240a1e25b5 100644 --- a/backends/platform/psp/dummy.cpp +++ b/backends/platform/psp/dummy.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/psp/image_viewer.cpp b/backends/platform/psp/image_viewer.cpp index 98205ddee9..8a1a256469 100644 --- a/backends/platform/psp/image_viewer.cpp +++ b/backends/platform/psp/image_viewer.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/psp/image_viewer.h b/backends/platform/psp/image_viewer.h index 91a70b85cc..66b640b6f3 100644 --- a/backends/platform/psp/image_viewer.h +++ b/backends/platform/psp/image_viewer.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/psp/input.cpp b/backends/platform/psp/input.cpp index 5e20fb1e43..4d7577eb94 100644 --- a/backends/platform/psp/input.cpp +++ b/backends/platform/psp/input.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/psp/input.h b/backends/platform/psp/input.h index ef2e1b84a4..05b575e0b0 100644 --- a/backends/platform/psp/input.h +++ b/backends/platform/psp/input.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/psp/memory.cpp b/backends/platform/psp/memory.cpp index 5419d60eb3..72a526c0ff 100644 --- a/backends/platform/psp/memory.cpp +++ b/backends/platform/psp/memory.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/psp/memory.h b/backends/platform/psp/memory.h index 5b728460fc..d7c5420d64 100644 --- a/backends/platform/psp/memory.h +++ b/backends/platform/psp/memory.h @@ -9,12 +9,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/psp/mp3.cpp b/backends/platform/psp/mp3.cpp index 3dbf31112a..6db2a73a4b 100644 --- a/backends/platform/psp/mp3.cpp +++ b/backends/platform/psp/mp3.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/psp/mp3.h b/backends/platform/psp/mp3.h index f7bfdda254..86dfc4c37d 100644 --- a/backends/platform/psp/mp3.h +++ b/backends/platform/psp/mp3.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/psp/osys_psp.cpp b/backends/platform/psp/osys_psp.cpp index 8559066e53..67cb72d9d4 100644 --- a/backends/platform/psp/osys_psp.cpp +++ b/backends/platform/psp/osys_psp.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/psp/osys_psp.h b/backends/platform/psp/osys_psp.h index f4591e476d..6f9238b84e 100644 --- a/backends/platform/psp/osys_psp.h +++ b/backends/platform/psp/osys_psp.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/psp/png_loader.cpp b/backends/platform/psp/png_loader.cpp index 4de13d1e73..e54541b75d 100644 --- a/backends/platform/psp/png_loader.cpp +++ b/backends/platform/psp/png_loader.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/psp/png_loader.h b/backends/platform/psp/png_loader.h index 48a3220d78..b84bef4efe 100644 --- a/backends/platform/psp/png_loader.h +++ b/backends/platform/psp/png_loader.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/psp/portdefs.h b/backends/platform/psp/portdefs.h index 620a27a601..3e7b559666 100644 --- a/backends/platform/psp/portdefs.h +++ b/backends/platform/psp/portdefs.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/psp/powerman.cpp b/backends/platform/psp/powerman.cpp index b72d05809d..3cd663e3c7 100644 --- a/backends/platform/psp/powerman.cpp +++ b/backends/platform/psp/powerman.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/psp/powerman.h b/backends/platform/psp/powerman.h index e62b1ada8e..77cfb26720 100644 --- a/backends/platform/psp/powerman.h +++ b/backends/platform/psp/powerman.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/psp/psp_main.cpp b/backends/platform/psp/psp_main.cpp index a83a5bae71..8901f4ecd3 100644 --- a/backends/platform/psp/psp_main.cpp +++ b/backends/platform/psp/psp_main.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/psp/pspkeyboard.cpp b/backends/platform/psp/pspkeyboard.cpp index 66efe9145d..7b5637e52f 100644 --- a/backends/platform/psp/pspkeyboard.cpp +++ b/backends/platform/psp/pspkeyboard.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/psp/pspkeyboard.h b/backends/platform/psp/pspkeyboard.h index bd270da26f..ece769e0ce 100644 --- a/backends/platform/psp/pspkeyboard.h +++ b/backends/platform/psp/pspkeyboard.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/psp/psppixelformat.cpp b/backends/platform/psp/psppixelformat.cpp index e1649791a1..2d7d524b45 100644 --- a/backends/platform/psp/psppixelformat.cpp +++ b/backends/platform/psp/psppixelformat.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/psp/psppixelformat.h b/backends/platform/psp/psppixelformat.h index ca85e76211..ede5a97d6f 100644 --- a/backends/platform/psp/psppixelformat.h +++ b/backends/platform/psp/psppixelformat.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/psp/rtc.cpp b/backends/platform/psp/rtc.cpp index 4f15e45535..d01bd8f83a 100644 --- a/backends/platform/psp/rtc.cpp +++ b/backends/platform/psp/rtc.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/psp/rtc.h b/backends/platform/psp/rtc.h index d2689681dd..58d70f4ab2 100644 --- a/backends/platform/psp/rtc.h +++ b/backends/platform/psp/rtc.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/psp/tests.cpp b/backends/platform/psp/tests.cpp index 5c5ebb7a80..92a18e58d0 100644 --- a/backends/platform/psp/tests.cpp +++ b/backends/platform/psp/tests.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/psp/tests.h b/backends/platform/psp/tests.h index 3779cb6bb2..718287b9dd 100644 --- a/backends/platform/psp/tests.h +++ b/backends/platform/psp/tests.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/psp/thread.cpp b/backends/platform/psp/thread.cpp index 57370f7685..669a682c21 100644 --- a/backends/platform/psp/thread.cpp +++ b/backends/platform/psp/thread.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/psp/thread.h b/backends/platform/psp/thread.h index ca94b8c82c..a0d53e8638 100644 --- a/backends/platform/psp/thread.h +++ b/backends/platform/psp/thread.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/psp/trace.cpp b/backends/platform/psp/trace.cpp index 008b508b7e..50459dcea5 100644 --- a/backends/platform/psp/trace.cpp +++ b/backends/platform/psp/trace.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/psp/trace.h b/backends/platform/psp/trace.h index e27d06d8d3..43ccaea52a 100644 --- a/backends/platform/psp/trace.h +++ b/backends/platform/psp/trace.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/samsungtv/main.cpp b/backends/platform/samsungtv/main.cpp index 8274bb00a2..a390bd0f0b 100644 --- a/backends/platform/samsungtv/main.cpp +++ b/backends/platform/samsungtv/main.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/samsungtv/samsungtv.cpp b/backends/platform/samsungtv/samsungtv.cpp index 9718eed1fe..a1d15930f2 100644 --- a/backends/platform/samsungtv/samsungtv.cpp +++ b/backends/platform/samsungtv/samsungtv.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/samsungtv/samsungtv.h b/backends/platform/samsungtv/samsungtv.h index b7a78a96cd..fdd1015c8a 100644 --- a/backends/platform/samsungtv/samsungtv.h +++ b/backends/platform/samsungtv/samsungtv.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/sdl/amigaos/amigaos-main.cpp b/backends/platform/sdl/amigaos/amigaos-main.cpp index da83756a40..0743b3f9a0 100644 --- a/backends/platform/sdl/amigaos/amigaos-main.cpp +++ b/backends/platform/sdl/amigaos/amigaos-main.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/sdl/amigaos/amigaos.cpp b/backends/platform/sdl/amigaos/amigaos.cpp index 94daacfd14..fdd26cd256 100644 --- a/backends/platform/sdl/amigaos/amigaos.cpp +++ b/backends/platform/sdl/amigaos/amigaos.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/sdl/amigaos/amigaos.h b/backends/platform/sdl/amigaos/amigaos.h index 391a0bfa9a..76cc656364 100644 --- a/backends/platform/sdl/amigaos/amigaos.h +++ b/backends/platform/sdl/amigaos/amigaos.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/sdl/macosx/appmenu_osx.h b/backends/platform/sdl/macosx/appmenu_osx.h index 005414b789..22088184fb 100644 --- a/backends/platform/sdl/macosx/appmenu_osx.h +++ b/backends/platform/sdl/macosx/appmenu_osx.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/sdl/macosx/appmenu_osx.mm b/backends/platform/sdl/macosx/appmenu_osx.mm index 0d2a2ab7f2..d083fb8483 100644 --- a/backends/platform/sdl/macosx/appmenu_osx.mm +++ b/backends/platform/sdl/macosx/appmenu_osx.mm @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/sdl/macosx/macosx-main.cpp b/backends/platform/sdl/macosx/macosx-main.cpp index b89264f9e9..1b9fc1b82c 100644 --- a/backends/platform/sdl/macosx/macosx-main.cpp +++ b/backends/platform/sdl/macosx/macosx-main.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/sdl/macosx/macosx.cpp b/backends/platform/sdl/macosx/macosx.cpp index 85342d62fd..c48076c42f 100644 --- a/backends/platform/sdl/macosx/macosx.cpp +++ b/backends/platform/sdl/macosx/macosx.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. @@ -31,6 +31,7 @@ #include "backends/mixer/doublebuffersdl/doublebuffersdl-mixer.h" #include "backends/platform/sdl/macosx/appmenu_osx.h" #include "backends/updates/macosx/macosx-updates.h" +#include "backends/taskbar/macosx/macosx-taskbar.h" #include "common/archive.h" #include "common/config-manager.h" @@ -45,6 +46,16 @@ OSystem_MacOSX::OSystem_MacOSX() OSystem_POSIX("Library/Preferences/ScummVM Preferences") { } +void OSystem_MacOSX::init() { +#if defined(USE_TASKBAR) + // Initialize taskbar manager + _taskbarManager = new MacOSXTaskbarManager(); +#endif + + // Invoke parent implementation of this method + OSystem_POSIX::init(); +} + void OSystem_MacOSX::initBackend() { // Create the mixer manager if (_mixer == 0) { @@ -134,7 +145,7 @@ Common::String OSystem_MacOSX::getSystemLanguage() const { for (CFIndex i = 0 ; i < localizationsSize ; ++i) { CFStringRef language = (CFStringRef)CFArrayGetValueAtIndex(preferredLocalizations, i); char buffer[10]; - CFStringGetCString(language, buffer, 50, kCFStringEncodingASCII); + CFStringGetCString(language, buffer, sizeof(buffer), kCFStringEncodingASCII); int32 languageId = TransMan.findMatchingLanguage(buffer); if (languageId != -1) { CFRelease(preferredLocalizations); @@ -145,7 +156,7 @@ Common::String OSystem_MacOSX::getSystemLanguage() const { if (localizationsSize > 0) { CFStringRef language = (CFStringRef)CFArrayGetValueAtIndex(preferredLocalizations, 0); char buffer[10]; - CFStringGetCString(language, buffer, 50, kCFStringEncodingASCII); + CFStringGetCString(language, buffer, sizeof(buffer), kCFStringEncodingASCII); CFRelease(preferredLocalizations); return buffer; } diff --git a/backends/platform/sdl/macosx/macosx.h b/backends/platform/sdl/macosx/macosx.h index d9cb28b973..50cef60353 100644 --- a/backends/platform/sdl/macosx/macosx.h +++ b/backends/platform/sdl/macosx/macosx.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. @@ -35,6 +35,7 @@ public: virtual Common::String getSystemLanguage() const; + virtual void init(); virtual void initBackend(); virtual void addSysArchivesToSearchSet(Common::SearchSet &s, int priority = 0); virtual void setupIcon(); diff --git a/backends/platform/sdl/posix/posix-main.cpp b/backends/platform/sdl/posix/posix-main.cpp index 5f0914e04f..d07db11b0c 100644 --- a/backends/platform/sdl/posix/posix-main.cpp +++ b/backends/platform/sdl/posix/posix-main.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/sdl/posix/posix.cpp b/backends/platform/sdl/posix/posix.cpp index 7a8b1e7b70..a711c3a96b 100644 --- a/backends/platform/sdl/posix/posix.cpp +++ b/backends/platform/sdl/posix/posix.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. @@ -50,7 +50,7 @@ void OSystem_POSIX::init() { // Initialze File System Factory _fsFactory = new POSIXFilesystemFactory(); -#if defined(USE_TASKBAR) && defined(USE_TASKBAR_UNITY) +#if defined(USE_TASKBAR) && defined(USE_UNITY) // Initialize taskbar manager _taskbarManager = new UnityTaskbarManager(); #endif @@ -67,7 +67,7 @@ void OSystem_POSIX::initBackend() { // Invoke parent implementation of this method OSystem_SDL::initBackend(); -#if defined(USE_TASKBAR) && defined(USE_TASKBAR_UNITY) +#if defined(USE_TASKBAR) && defined(USE_UNITY) // Register the taskbar manager as an event source (this is necessary for the glib event loop to be run) _eventManager->getEventDispatcher()->registerSource((UnityTaskbarManager *)_taskbarManager, false); #endif @@ -80,15 +80,16 @@ bool OSystem_POSIX::hasFeature(Feature f) { } Common::String OSystem_POSIX::getDefaultConfigFileName() { - char configFile[MAXPATHLEN]; + Common::String configFile; // On POSIX type systems, by default we store the config file inside // to the HOME directory of the user. const char *home = getenv("HOME"); - if (home != NULL && strlen(home) < MAXPATHLEN) - snprintf(configFile, MAXPATHLEN, "%s/%s", home, _baseConfigName.c_str()); - else - strcpy(configFile, _baseConfigName.c_str()); + if (home != NULL && (strlen(home) + 1 + _baseConfigName.size()) < MAXPATHLEN) { + configFile = Common::String::format("%s/%s", home, _baseConfigName.c_str()); + } else { + configFile = _baseConfigName; + } return configFile; } diff --git a/backends/platform/sdl/posix/posix.h b/backends/platform/sdl/posix/posix.h index 59909a958f..01a01528cd 100644 --- a/backends/platform/sdl/posix/posix.h +++ b/backends/platform/sdl/posix/posix.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/sdl/ps3/ps3-main.cpp b/backends/platform/sdl/ps3/ps3-main.cpp index ba548a3749..92c4a02865 100644 --- a/backends/platform/sdl/ps3/ps3-main.cpp +++ b/backends/platform/sdl/ps3/ps3-main.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/sdl/ps3/ps3.cpp b/backends/platform/sdl/ps3/ps3.cpp index 33586ce693..f111379794 100644 --- a/backends/platform/sdl/ps3/ps3.cpp +++ b/backends/platform/sdl/ps3/ps3.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/sdl/ps3/ps3.h b/backends/platform/sdl/ps3/ps3.h index daed7599a9..d812a13548 100644 --- a/backends/platform/sdl/ps3/ps3.h +++ b/backends/platform/sdl/ps3/ps3.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/sdl/sdl-sys.h b/backends/platform/sdl/sdl-sys.h index eccf73815d..eec3741ed6 100644 --- a/backends/platform/sdl/sdl-sys.h +++ b/backends/platform/sdl/sdl-sys.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/sdl/sdl.cpp b/backends/platform/sdl/sdl.cpp index 7ab367d4a4..41610dc0c7 100644 --- a/backends/platform/sdl/sdl.cpp +++ b/backends/platform/sdl/sdl.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. @@ -65,10 +65,13 @@ OSystem_SDL::OSystem_SDL() : #ifdef USE_OPENGL - _graphicsModes(0), + _desktopWidth(0), + _desktopHeight(0), + _graphicsModes(), _graphicsMode(0), - _sdlModesCount(0), - _glModesCount(0), + _firstGLMode(0), + _defaultSDLMode(0), + _defaultGLMode(0), #endif _inited(false), _initedSDL(false), @@ -87,6 +90,9 @@ OSystem_SDL::~OSystem_SDL() { // Hence, we perform the destruction on our own. delete _savefileManager; _savefileManager = 0; + if (_graphicsManager) { + dynamic_cast<SdlGraphicsManager *>(_graphicsManager)->deactivateManager(); + } delete _graphicsManager; _graphicsManager = 0; delete _eventManager; @@ -110,10 +116,6 @@ OSystem_SDL::~OSystem_SDL() { delete _mutexManager; _mutexManager = 0; -#ifdef USE_OPENGL - delete[] _graphicsModes; -#endif - delete _logger; _logger = 0; @@ -124,6 +126,12 @@ void OSystem_SDL::init() { // Initialize SDL initSDL(); + // Enable unicode support if possible + SDL_EnableUNICODE(1); + + // Disable OS cursor + SDL_ShowCursor(SDL_DISABLE); + if (!_logger) _logger = new Backends::Log::Log(this); @@ -144,50 +152,60 @@ void OSystem_SDL::init() { _taskbarManager = new Common::TaskbarManager(); #endif -#ifdef USE_OPENGL - // Setup a list with both SDL and OpenGL graphics modes - setupGraphicsModes(); -#endif } void OSystem_SDL::initBackend() { // Check if backend has not been initialized assert(!_inited); + const int maxNameLen = 20; + char sdlDriverName[maxNameLen]; + sdlDriverName[0] = '\0'; + SDL_VideoDriverName(sdlDriverName, maxNameLen); + // Using printf rather than debug() here as debug()/logging + // is not active by this point. + debug(1, "Using SDL Video Driver \"%s\"", sdlDriverName); + // Create the default event source, in case a custom backend // manager didn't provide one yet. if (_eventSource == 0) _eventSource = new SdlEventSource(); - int graphicsManagerType = 0; +#ifdef USE_OPENGL + // Query the desktop resolution. We simply hope nothing tried to change + // the resolution so far. + const SDL_VideoInfo *videoInfo = SDL_GetVideoInfo(); + if (videoInfo && videoInfo->current_w > 0 && videoInfo->current_h > 0) { + _desktopWidth = videoInfo->current_w; + _desktopHeight = videoInfo->current_h; + } +#endif if (_graphicsManager == 0) { #ifdef USE_OPENGL + // Setup a list with both SDL and OpenGL graphics modes. We only do + // this whenever the subclass did not already set up an graphics + // manager yet. This is because we don't know the type of the graphics + // manager of the subclass, thus we cannot easily switch between the + // OpenGL one and the set up one. It also is to be expected that the + // subclass does not want any switching of graphics managers anyway. + setupGraphicsModes(); + if (ConfMan.hasKey("gfx_mode")) { + // If the gfx_mode is from OpenGL, create the OpenGL graphics manager Common::String gfxMode(ConfMan.get("gfx_mode")); - bool use_opengl = false; - const OSystem::GraphicsMode *mode = OpenGLSdlGraphicsManager::supportedGraphicsModes(); - int i = 0; - while (mode->name) { - if (scumm_stricmp(mode->name, gfxMode.c_str()) == 0) { - _graphicsMode = i + _sdlModesCount; - use_opengl = true; + for (uint i = _firstGLMode; i < _graphicsModeIds.size(); ++i) { + if (!scumm_stricmp(_graphicsModes[i].name, gfxMode.c_str())) { + _graphicsManager = new OpenGLSdlGraphicsManager(_desktopWidth, _desktopHeight, _eventSource); + _graphicsMode = i; + break; } - - mode++; - ++i; - } - - // If the gfx_mode is from OpenGL, create the OpenGL graphics manager - if (use_opengl) { - _graphicsManager = new OpenGLSdlGraphicsManager(_eventSource); - graphicsManagerType = 1; } } #endif + if (_graphicsManager == 0) { _graphicsManager = new SurfaceSdlGraphicsManager(_eventSource); - graphicsManagerType = 0; } } @@ -230,13 +248,7 @@ void OSystem_SDL::initBackend() { // so the virtual keyboard can be initialized, but we have to add the // graphics manager as an event observer after initializing the event // manager. - if (graphicsManagerType == 0) - ((SurfaceSdlGraphicsManager *)_graphicsManager)->initEventObserver(); -#ifdef USE_OPENGL - else if (graphicsManagerType == 1) - ((OpenGLSdlGraphicsManager *)_graphicsManager)->initEventObserver(); -#endif - + dynamic_cast<SdlGraphicsManager *>(_graphicsManager)->activateManager(); } #if defined(USE_TASKBAR) @@ -257,22 +269,19 @@ void OSystem_SDL::engineDone() { void OSystem_SDL::initSDL() { // Check if SDL has not been initialized if (!_initedSDL) { - uint32 sdlFlags = 0; + // We always initialize the video subsystem because we will need it to + // be initialized before the graphics managers to retrieve the desktop + // resolution, for example. WebOS also requires this initialization + // or otherwise the application won't start. + uint32 sdlFlags = SDL_INIT_VIDEO; + if (ConfMan.hasKey("disable_sdl_parachute")) sdlFlags |= SDL_INIT_NOPARACHUTE; -#ifdef WEBOS - // WebOS needs this flag or otherwise the application won't start - sdlFlags |= SDL_INIT_VIDEO; -#endif - // Initialize SDL (SDL Subsystems are initiliazed in the corresponding sdl managers) if (SDL_Init(sdlFlags) == -1) error("Could not initialize SDL: %s", SDL_GetError()); - // Enable unicode support if possible - SDL_EnableUNICODE(1); - _initedSDL = true; } } @@ -368,17 +377,6 @@ Common::String OSystem_SDL::getSystemLanguage() const { const LCID languageIdentifier = GetThreadLocale(); - // GetLocalInfo is only supported starting from Windows 2000, according to this: - // http://msdn.microsoft.com/en-us/library/dd318101%28VS.85%29.aspx - // On the other hand the locale constants used, seem to exist on Windows 98 too, - // check this for that: http://msdn.microsoft.com/en-us/library/dd464799%28v=VS.85%29.aspx - // - // I am not exactly sure what is the truth now, it might be very well that this breaks - // support for systems older than Windows 2000.... - // - // TODO: Check whether this (or ScummVM at all ;-) works on a system with Windows 98 for - // example and if it does not and we still want Windows 9x support, we should definitly - // think of another solution. if (GetLocaleInfo(languageIdentifier, LOCALE_SISO639LANGNAME, langName, sizeof(langName)) != 0 && GetLocaleInfo(languageIdentifier, LOCALE_SISO3166CTRYNAME, ctryName, sizeof(ctryName)) != 0) { Common::String localeName = langName; @@ -391,10 +389,15 @@ Common::String OSystem_SDL::getSystemLanguage() const { } #else // WIN32 // Activating current locale settings - const char *locale = setlocale(LC_ALL, ""); + const Common::String locale = setlocale(LC_ALL, ""); + + // Restore default C locale to prevent issues with + // portability of sscanf(), atof(), etc. + // See bug #3615148 + setlocale(LC_ALL, "C"); // Detect the language from the locale - if (!locale) { + if (locale.empty()) { return ModularBackend::getSystemLanguage(); } else { int length = 0; @@ -403,14 +406,14 @@ Common::String OSystem_SDL::getSystemLanguage() const { // ".UTF-8" or the like. We do this, since // our translation languages are usually // specified without any charset information. - for (int i = 0; locale[i]; ++i, ++length) { + for (int size = locale.size(); length < size; ++length) { // TODO: Check whether "@" should really be checked // here. - if (locale[i] == '.' || locale[i] == ' ' || locale[i] == '@') + if (locale[length] == '.' || locale[length] == ' ' || locale[length] == '@') break; } - return Common::String(locale, length); + return Common::String(locale.c_str(), length); } #endif // WIN32 #else // USE_DETECTLANG @@ -535,28 +538,33 @@ Common::TimerManager *OSystem_SDL::getTimerManager() { #ifdef USE_OPENGL const OSystem::GraphicsMode *OSystem_SDL::getSupportedGraphicsModes() const { - return _graphicsModes; + if (_graphicsModes.empty()) { + return _graphicsManager->getSupportedGraphicsModes(); + } else { + return _graphicsModes.begin(); + } } int OSystem_SDL::getDefaultGraphicsMode() const { - // Return the default graphics mode from the current graphics manager - if (_graphicsMode < _sdlModesCount) + if (_graphicsModes.empty()) { return _graphicsManager->getDefaultGraphicsMode(); - else - return _graphicsManager->getDefaultGraphicsMode() + _sdlModesCount; + } else { + // Return the default graphics mode from the current graphics manager + if (_graphicsMode < _firstGLMode) + return _defaultSDLMode; + else + return _defaultGLMode; + } } bool OSystem_SDL::setGraphicsMode(int mode) { - const OSystem::GraphicsMode *srcMode; - int i; + if (_graphicsModes.empty()) { + return _graphicsManager->setGraphicsMode(mode); + } - // Check if mode is from SDL or OpenGL - if (mode < _sdlModesCount) { - srcMode = SurfaceSdlGraphicsManager::supportedGraphicsModes(); - i = 0; - } else { - srcMode = OpenGLSdlGraphicsManager::supportedGraphicsModes(); - i = _sdlModesCount; + // Check whether a invalid mode is requested. + if (mode < 0 || (uint)mode >= _graphicsModeIds.size()) { + return false; } // Very hacky way to set up the old graphics manager state, in case we @@ -575,113 +583,121 @@ bool OSystem_SDL::setGraphicsMode(int mode) { bool switchedManager = false; - // Loop through modes - while (srcMode->name) { - if (i == mode) { - // If the new mode and the current mode are not from the same graphics - // manager, delete and create the new mode graphics manager - if (_graphicsMode >= _sdlModesCount && mode < _sdlModesCount) { - debug(1, "switching to plain SDL graphics"); - delete _graphicsManager; - _graphicsManager = new SurfaceSdlGraphicsManager(_eventSource); - ((SurfaceSdlGraphicsManager *)_graphicsManager)->initEventObserver(); - _graphicsManager->beginGFXTransaction(); - - switchedManager = true; - } else if (_graphicsMode < _sdlModesCount && mode >= _sdlModesCount) { - debug(1, "switching to OpenGL graphics"); - delete _graphicsManager; - _graphicsManager = new OpenGLSdlGraphicsManager(_eventSource); - ((OpenGLSdlGraphicsManager *)_graphicsManager)->initEventObserver(); - _graphicsManager->beginGFXTransaction(); - - switchedManager = true; - } + // If the new mode and the current mode are not from the same graphics + // manager, delete and create the new mode graphics manager + if (_graphicsMode >= _firstGLMode && mode < _firstGLMode) { + debug(1, "switching to plain SDL graphics"); + dynamic_cast<SdlGraphicsManager *>(_graphicsManager)->deactivateManager(); + delete _graphicsManager; + _graphicsManager = new SurfaceSdlGraphicsManager(_eventSource); + + switchedManager = true; + } else if (_graphicsMode < _firstGLMode && mode >= _firstGLMode) { + debug(1, "switching to OpenGL graphics"); + dynamic_cast<SdlGraphicsManager *>(_graphicsManager)->deactivateManager(); + delete _graphicsManager; + _graphicsManager = new OpenGLSdlGraphicsManager(_desktopWidth, _desktopHeight, _eventSource); + + switchedManager = true; + } - _graphicsMode = mode; + _graphicsMode = mode; - if (switchedManager) { + if (switchedManager) { + dynamic_cast<SdlGraphicsManager *>(_graphicsManager)->activateManager(); + + _graphicsManager->beginGFXTransaction(); #ifdef USE_RGB_COLOR - _graphicsManager->initSize(screenWidth, screenHeight, &pixelFormat); + _graphicsManager->initSize(screenWidth, screenHeight, &pixelFormat); #else - _graphicsManager->initSize(screenWidth, screenHeight, 0); + _graphicsManager->initSize(screenWidth, screenHeight, 0); #endif - _graphicsManager->setFeatureState(kFeatureAspectRatioCorrection, arState); - _graphicsManager->setFeatureState(kFeatureFullscreenMode, fullscreen); - _graphicsManager->setFeatureState(kFeatureCursorPalette, cursorPalette); + _graphicsManager->setFeatureState(kFeatureAspectRatioCorrection, arState); + _graphicsManager->setFeatureState(kFeatureFullscreenMode, fullscreen); + _graphicsManager->setFeatureState(kFeatureCursorPalette, cursorPalette); - // Worst part about this right now, tell the cursor manager to - // resetup the cursor + cursor palette if necessarily + // Worst part about this right now, tell the cursor manager to + // resetup the cursor + cursor palette if necessarily - // First we need to try to setup the old state on the new manager... - if (_graphicsManager->endGFXTransaction() != kTransactionSuccess) { - // Oh my god if this failed the client code might just explode. - return false; - } + // First we need to try to setup the old state on the new manager... + if (_graphicsManager->endGFXTransaction() != kTransactionSuccess) { + // Oh my god if this failed the client code might just explode. + return false; + } - // Next setup the cursor again - CursorMan.pushCursor(0, 0, 0, 0, 0, 0); - CursorMan.popCursor(); + // Next setup the cursor again + CursorMan.pushCursor(0, 0, 0, 0, 0, 0); + CursorMan.popCursor(); - // Next setup cursor palette if needed - if (cursorPalette) { - CursorMan.pushCursorPalette(0, 0, 0); - CursorMan.popCursorPalette(); - } - - _graphicsManager->beginGFXTransaction(); - // Oh my god if this failed the client code might just explode. - return _graphicsManager->setGraphicsMode(srcMode->id); - } else { - return _graphicsManager->setGraphicsMode(srcMode->id); - } + // Next setup cursor palette if needed + if (cursorPalette) { + CursorMan.pushCursorPalette(0, 0, 0); + CursorMan.popCursorPalette(); } - i++; - srcMode++; + _graphicsManager->beginGFXTransaction(); + // Oh my god if this failed the client code might just explode. + return _graphicsManager->setGraphicsMode(_graphicsModeIds[mode]); + } else { + return _graphicsManager->setGraphicsMode(_graphicsModeIds[mode]); } - - return false; } int OSystem_SDL::getGraphicsMode() const { - return _graphicsMode; + if (_graphicsModes.empty()) { + return _graphicsManager->getGraphicsMode(); + } else { + return _graphicsMode; + } } void OSystem_SDL::setupGraphicsModes() { - const OSystem::GraphicsMode *sdlGraphicsModes = SurfaceSdlGraphicsManager::supportedGraphicsModes(); - const OSystem::GraphicsMode *openglGraphicsModes = OpenGLSdlGraphicsManager::supportedGraphicsModes(); - _sdlModesCount = 0; - _glModesCount = 0; + _graphicsModes.clear(); + _graphicsModeIds.clear(); + _defaultSDLMode = _defaultGLMode = -1; // Count the number of graphics modes - const OSystem::GraphicsMode *srcMode = sdlGraphicsModes; + const OSystem::GraphicsMode *srcMode; + int defaultMode; + + GraphicsManager *manager = new SurfaceSdlGraphicsManager(_eventSource); + srcMode = manager->getSupportedGraphicsModes(); + defaultMode = manager->getDefaultGraphicsMode(); while (srcMode->name) { - _sdlModesCount++; + if (defaultMode == srcMode->id) { + _defaultSDLMode = _graphicsModes.size(); + } + _graphicsModes.push_back(*srcMode); srcMode++; } - srcMode = openglGraphicsModes; + delete manager; + assert(_defaultSDLMode != -1); + + _firstGLMode = _graphicsModes.size(); + manager = new OpenGLSdlGraphicsManager(_desktopWidth, _desktopHeight, _eventSource); + srcMode = manager->getSupportedGraphicsModes(); + defaultMode = manager->getDefaultGraphicsMode(); while (srcMode->name) { - _glModesCount++; + if (defaultMode == srcMode->id) { + _defaultGLMode = _graphicsModes.size(); + } + _graphicsModes.push_back(*srcMode); srcMode++; } - - // Allocate enough space for merged array of modes - _graphicsModes = new OSystem::GraphicsMode[_glModesCount + _sdlModesCount + 1]; - - // Copy SDL graphics modes - memcpy((void *)_graphicsModes, sdlGraphicsModes, _sdlModesCount * sizeof(OSystem::GraphicsMode)); - - // Copy OpenGL graphics modes - memcpy((void *)(_graphicsModes + _sdlModesCount), openglGraphicsModes, _glModesCount * sizeof(OSystem::GraphicsMode)); + delete manager; + manager = nullptr; + assert(_defaultGLMode != -1); // Set a null mode at the end - memset((void *)(_graphicsModes + _sdlModesCount + _glModesCount), 0, sizeof(OSystem::GraphicsMode)); + GraphicsMode nullMode; + memset(&nullMode, 0, sizeof(nullMode)); + _graphicsModes.push_back(nullMode); // Set new internal ids for all modes int i = 0; - OSystem::GraphicsMode *mode = _graphicsModes; + OSystem::GraphicsMode *mode = _graphicsModes.begin(); while (mode->name) { + _graphicsModeIds.push_back(mode->id); mode->id = i++; mode++; } diff --git a/backends/platform/sdl/sdl.h b/backends/platform/sdl/sdl.h index 840e73ff09..5dcc269e55 100644 --- a/backends/platform/sdl/sdl.h +++ b/backends/platform/sdl/sdl.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. @@ -30,6 +30,8 @@ #include "backends/events/sdl/sdl-events.h" #include "backends/log/log.h" +#include "common/array.h" + /** * Base OSystem class for all SDL ports. */ @@ -106,15 +108,20 @@ protected: Backends::Log::Log *_logger; #ifdef USE_OPENGL - OSystem::GraphicsMode *_graphicsModes; + int _desktopWidth, _desktopHeight; + + typedef Common::Array<GraphicsMode> GraphicsModeArray; + GraphicsModeArray _graphicsModes; + Common::Array<int> _graphicsModeIds; int _graphicsMode; - int _sdlModesCount; - int _glModesCount; + int _firstGLMode; + int _defaultSDLMode; + int _defaultGLMode; /** * Creates the merged graphics modes list */ - virtual void setupGraphicsModes(); + void setupGraphicsModes(); virtual const OSystem::GraphicsMode *getSupportedGraphicsModes() const; virtual int getDefaultGraphicsMode() const; diff --git a/backends/platform/sdl/win32/win32-main.cpp b/backends/platform/sdl/win32/win32-main.cpp index 2b3e18e9f0..e5b26c3ff0 100644 --- a/backends/platform/sdl/win32/win32-main.cpp +++ b/backends/platform/sdl/win32/win32-main.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/sdl/win32/win32.cpp b/backends/platform/sdl/win32/win32.cpp index 453d566c7b..5f860ad32d 100644 --- a/backends/platform/sdl/win32/win32.cpp +++ b/backends/platform/sdl/win32/win32.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/sdl/win32/win32.h b/backends/platform/sdl/win32/win32.h index b56997a63b..d72d80bc26 100644 --- a/backends/platform/sdl/win32/win32.h +++ b/backends/platform/sdl/win32/win32.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/symbian/AdaptAllMMPs.pl b/backends/platform/symbian/AdaptAllMMPs.pl index ffc4e88aff..18a464b580 100644 --- a/backends/platform/symbian/AdaptAllMMPs.pl +++ b/backends/platform/symbian/AdaptAllMMPs.pl @@ -14,36 +14,48 @@ chdir("../../../"); "mmp/scummvm_cine.mmp", "mmp/scummvm_composer.mmp", "mmp/scummvm_cruise.mmp", + "mmp/scummvm_draci.mmp", "mmp/scummvm_drascula.mmp", "mmp/scummvm_gob.mmp", "mmp/scummvm_groovie.mmp", + "mmp/scummvm_hopkins.mmp", + "mmp/scummvm_hugo.mmp", "mmp/scummvm_kyra.mmp", "mmp/scummvm_lure.mmp", "mmp/scummvm_m4.mmp", "mmp/scummvm_made.mmp", + "mmp/scummvm_mohawk.mmp", + "mmp/scummvm_neverhood.mmp", "mmp/scummvm_parallaction.mmp", + "mmp/scummvm_pegasus.mmp", "mmp/scummvm_queen.mmp", "mmp/scummvm_saga.mmp", + "mmp/scummvm_sci.mmp", "mmp/scummvm_scumm.mmp", "mmp/scummvm_sky.mmp", "mmp/scummvm_sword1.mmp", "mmp/scummvm_sword2.mmp", - "mmp/scummvm_touche.mmp", - "mmp/scummvm_tinsel.mmp", - "mmp/scummvm_tucker.mmp", - "mmp/scummvm_sci.mmp", - "mmp/scummvm_draci.mmp", "mmp/scummvm_teenagent.mmp", - "mmp/scummvm_mohawk.mmp", - "mmp/scummvm_hugo.mmp", + "mmp/scummvm_tinsel.mmp", + "mmp/scummvm_toltecs.mmp", + "mmp/scummvm_tony.mmp", "mmp/scummvm_toon.mmp", - "mmp/scummvm_lastexpress.mmp", + "mmp/scummvm_touche.mmp", "mmp/scummvm_tsage.mmp", - "mmp/scummvm_tony.mmp", - "mmp/scummvm_hopkins.mmp", - "mmp/scummvm_toltecs.mmp", - "mmp/scummvm_pegasus.mmp", + "mmp/scummvm_tucker.mmp", "mmp/scummvm_wintermute.mmp", + # New engines + "mmp/scummvm_avalanche.mmp", + "mmp/scummvm_bbvs.mmp", + "mmp/scummvm_dreamweb.mmp", + "mmp/scummvm_fullpipe.mmp", + "mmp/scummvm_lastexpress.mmp", + "mmp/scummvm_mads.mmp", + "mmp/scummvm_mortevielle.mmp", + "mmp/scummvm_sword25.mmp", + "mmp/scummvm_testbed.mmp", + "mmp/scummvm_zvision.mmp", + "mmp/scummvm_voyeur.mmp", # Target Platform Project Files "S60/ScummVM_S60.mmp", "S60v3/ScummVM_S60v3.mmp", @@ -79,10 +91,14 @@ Preparing to update all the Symbian MMP project files with objects from module.m # some modules.mk files have #ifndef ENABLE_XXXX blocks: my @section_empty = (""); # section standard: no #ifdef's in module.mk files -my @sections_scumm = ("", "ENABLE_SCUMM_7_8", "ENABLE_HE"); # special sections for engine SCUMM -my @sections_saga = ("", "ENABLE_IHNM", "ENABLE_SAGA2"); # special sections for engine SAGA -my @sections_kyra = ("", "ENABLE_LOL","ENABLE_EOB"); # special sections for engine KYRA my @sections_agos = ("", "ENABLE_AGOS2"); # special sections for engine AGOS +my @section_video = ("", "USE_BINK"); # special sections for engine VIDEO ###, "USE_THEORADEC" +my @sections_groovie = ("", "ENABLE_GROOVIE2"); # special sections for engine GROOVIE +my @sections_kyra = ("", "ENABLE_LOL","ENABLE_EOB"); # special sections for engine KYRA +my @sections_mohawk = ("", "ENABLE_CSTIME", "ENABLE_MYST", "ENABLE_RIVEN"); # special sections for engine MOHAWK +my @sections_saga = ("", "ENABLE_IHNM", "ENABLE_SAGA2"); # special sections for engine SAGA +my @sections_sci = ("", "ENABLE_SCI32"); # special sections for engine SCI +my @sections_scumm = ("", "ENABLE_SCUMM_7_8", "ENABLE_HE"); # special sections for engine SCUMM # files excluded from build, case insensitive, will be matched in filename string only my @excludes_snd = ( @@ -126,20 +142,21 @@ my @excludes_scumm = ( ); -#arseModule(mmpStr, dirStr, ifdefArray, [exclusionsArray]) +#ParseModule(mmpStr, dirStr, ifdefArray, [exclusionsArray]) ParseModule("_base", "base", \@section_empty); # now in ./TRG/ScummVM_TRG.mmp, these never change anyways... ParseModule("_base", "common", \@section_empty); ParseModule("_base", "gui", \@section_empty, \@excludes_gui); ParseModule("_base", "graphics", \@section_empty, \@excludes_graphics); +ParseModule("_base", "image", \@section_empty); ParseModule("_base", "audio", \@section_empty, \@excludes_snd); -ParseModule("_base", "video", \@section_empty); +ParseModule("_base", "video", \@section_video); # chdir("engines/"); ParseModule("_scumm", "scumm", \@sections_scumm, \@excludes_scumm ); ParseModule("_queen", "queen", \@section_empty); ParseModule("_agos", "agos", \@sections_agos); -ParseModule("_sky", "sky", \@section_empty); -ParseModule("_gob", "gob", \@section_empty); +ParseModule("_sky", "sky", \@section_empty); +ParseModule("_gob", "gob", \@section_empty); ParseModule("_saga", "saga", \@sections_saga); ParseModule("_kyra", "kyra", \@sections_kyra); ParseModule("_sword1", "sword1", \@section_empty); @@ -148,29 +165,41 @@ ParseModule("_lure", "lure", \@section_empty); ParseModule("_cine", "cine", \@section_empty); ParseModule("_cge", "cge", \@section_empty); ParseModule("_composer","composer", \@section_empty); -ParseModule("_agi", "agi", \@section_empty); +ParseModule("_agi", "agi", \@section_empty); ParseModule("_touche", "touche", \@section_empty); ParseModule("_parallaction","parallaction",\@section_empty); ParseModule("_cruise", "cruise", \@section_empty); ParseModule("_drascula","drascula", \@section_empty); ParseModule("_made", "made", \@section_empty); -ParseModule("_m4", "m4", \@section_empty); +ParseModule("_m4", "m4", \@section_empty); ParseModule("_tinsel", "tinsel", \@section_empty); -ParseModule("_groovie", "groovie", \@section_empty); +ParseModule("_groovie", "groovie", \@sections_groovie); ParseModule("_tucker", "tucker", \@section_empty); -ParseModule("_sci", "sci", \@section_empty); +ParseModule("_sci", "sci", \@sections_sci); ParseModule("_draci", "draci", \@section_empty); ParseModule("_teenagent","teenagent", \@section_empty); -ParseModule("_mohawk" ,"mohawk", \@section_empty); +ParseModule("_mohawk" ,"mohawk", \@sections_mohawk); ParseModule("_hugo" ,"hugo", \@section_empty); ParseModule("_toon" ,"toon", \@section_empty); ParseModule("_lastexpress","lastexpress", \@section_empty); -ParseModule("_tsage","tsage", \@section_empty); -ParseModule("_tony","tony", \@section_empty); +ParseModule("_tsage", "tsage", \@section_empty); +ParseModule("_tony", "tony", \@section_empty); ParseModule("_toltecs","toltecs", \@section_empty); ParseModule("_hopkins","hopkins", \@section_empty); ParseModule("_pegasus","pegasus", \@section_empty); ParseModule("_wintermute","wintermute", \@section_empty); +##### new engines +ParseModule("_avalanche" ,"avalanche", \@section_empty); +ParseModule("_dreamweb" ,"dreamweb", \@section_empty); +ParseModule("_fullpipe" ,"fullpipe", \@section_empty); +ParseModule("_mads" ,"mads", \@section_empty); +ParseModule("_mortevielle" ,"mortevielle", \@section_empty); +ParseModule("_neverhood" ,"neverhood", \@section_empty); +ParseModule("_sword25" ,"sword25", \@section_empty); +ParseModule("_testbed" ,"testbed", \@section_empty); +ParseModule("_zvision" ,"zvision", \@section_empty); +ParseModule("_voyeur" ,"voyeur", \@section_empty); +ParseModule("_bbvs" ,"bbvs", \@section_empty); print " ======================================================================================= Done. Enjoy :P diff --git a/backends/platform/symbian/BuildPackageUpload_AllVersions.pl b/backends/platform/symbian/BuildPackageUpload_AllVersions.pl index 3062068852..a038bd90f8 100644 --- a/backends/platform/symbian/BuildPackageUpload_AllVersions.pl +++ b/backends/platform/symbian/BuildPackageUpload_AllVersions.pl @@ -1,6 +1,7 @@ use Cwd; use Switch; +#use feature "switch"; system("cls"); require "BuildPackageUpload_LocalSettings.pl"; @@ -59,9 +60,14 @@ $ftp_url = "FTP://$FTP_User\@$FTP_Host/$FTP_Dir/"; # these macros are always defined: $ExtraMacros = "MACRO NONSTANDARD_PORT\n"; -$ExtraMacros .= "MACRO ENABLE_VKEYBD\n"; +$ExtraMacros .= "MACRO ENABLE_VKEYBD\n"; $ExtraMacros .= "MACRO DISABLE_FANCY_THEMES\n"; $ExtraMacros .= "MACRO USE_TRANSLATION\n"; +$ExtraMacros .= "MACRO USE_BINK\n"; +#$ExtraMacros .= "MACRO USE_THEORADEC\n"; +#$ExtraMacros .= "MACRO USE_MPEG2\n"; +# $ExtraMacros .= "MACRO \n"; +# candidates are : , USE_TIMIDITY, # prep nice list of SDKs #while( ($SDK, $RootDir) = each(%SDK_RootDirs) ) diff --git a/backends/platform/symbian/BuildPackageUpload_LocalSettings.pl b/backends/platform/symbian/BuildPackageUpload_LocalSettings.pl index ded4ef198f..12fc2668e3 100644 --- a/backends/platform/symbian/BuildPackageUpload_LocalSettings.pl +++ b/backends/platform/symbian/BuildPackageUpload_LocalSettings.pl @@ -2,24 +2,33 @@ ################################################################################################################## @WorkingEngines = qw( - scumm agos sky queen gob groovie saga drascula - kyra lure agi touche parallaction cine - cruise made tinsel tucker sword1 sword2 draci sci teenagent mohawk hugo toon lastexpress tsage cge - composer toltecs tony wintermute pegasus + agos agi bbvs cine cge composer cruise draci + drascula hugo gob groovie kyra lastexpress + lure made mohawk parallaction pegasus queen + saga sci scumm sky sword1 sword2 teenagent tinsel + toltecs tony toon touche tsage tucker wintermute + dreamweb fullpipe hopkins mortevielle mads + neverhood testbed avalanche zvision voyeur ); +#### New engines +#### sword25 @WorkingEngines_1st = qw( - scumm queen groovie saga drascula - touche parallaction cine -? cruise made tucker lastexpress composer wintermute + cine composer cruise drascula groovie + lastexpress made parallaction queen + saga scumm touche tucker wintermute + avalanche zvision voyeur ); @WorkingEngines_2nd = qw( - agos sky gob kyra lure - agi tinsel sword1 sword2 - draci sci teenagent hugo toon - tsage cge toltecs tony pegasus + agi agos bbvs cge draci gob hopkins + hugo kyra lure mohawk pegasus sci + sky sword1 sword2 teenagent mads + tinsel tsage toltecs tony toon + dreamweb fullpipe mortevielle + neverhood testbed ); +#### sword25 @TestingEngines = qw( @@ -34,20 +43,34 @@ lol agos2 eob + cstime + myst + riven + saga2 + sci32 + groovie2 ); #disabled subengines lol saga2 personal nightmare + # see configure.engines %UseableFeatures = ( - 'zlib' => 'zlib.lib', + 'freetype2' => 'freetype.lib', + 'faad' => 'libFAAD2.lib', + 'flac' => 'libflacdec.lib', + 'jpeg' => 'libjpeg.lib', 'mad' => 'libmad.lib', + 'mpeg2' => 'libmpeg2.lib', + 'png' => 'libpng.lib', 'tremor' => 'libtremor.lib', - 'flac' => 'libflac.lib' + 'theoradec' => 'theora.lib', + 'zlib' => 'zlib.lib' ); # these are normally enabled for each variation #$DefaultFeatures = qw(zlib,mad); - $DefaultFeatures = qw(zlib,mad,tremor,flac); + #$DefaultFeatures = qw(zlib,mad,tremor,); + $DefaultFeatures = qw(faad,flac,freetype2,jpeg,mad,mpeg2,png,theoradec,tremor,zlib,); ################################################################################################################## ## @@ -64,7 +87,8 @@ $HaltOnError = 0; $SkipExistingPackages = 0; $ReallyQuiet = 0; - $DevBase = "C:\\S"; + $DevBase = "D:\\Symbian"; + $Compiler = "D:\\Program/ Files\\CodeSourcery\\Sourcery/ G++ Lite"; # specify an optional FTP server to upload to after each Build+Package (can leave empty) #$FTP_Host = "host.com"; @@ -77,14 +101,14 @@ # Note1: the \epoc32 directory needs to be in these rootdirs # Note2: these paths do NOT end in a backslash! # $SDK_RootDirs{'UIQ2'} = "$DevBase\\UIQ_21"; - $SDK_RootDirs{'UIQ3'} = "$DevBase\\UIQ3"; + # $SDK_RootDirs{'UIQ3'} = "$DevBase\\UIQ3"; # $SDK_RootDirs{'S60v1'} = "$DevBase\\S60v1"; # $SDK_RootDirs{'S60v2'} = "$DevBase\\S60v2"; - $SDK_RootDirs{'S60v3'} = "$DevBase\\S60v3"; + $SDK_RootDirs{'S60v3'} = "$DevBase\\S60v5"; # $SDK_RootDirs{'S80'} = "$DevBase\\S80"; # $SDK_RootDirs{'S90'} = "$DevBase\\S90"; - $SDK_ToolchainDirs{'S60v3'} = "$DevBase\\arm-symbianelf\\bin"; + $SDK_ToolchainDirs{'S60v3'} = "$Compiler\\arm-symbianelf\\bin"; $SDK_ToolchainDirs{'UIQ2'} = "$DevBase\\ECompXL\\bin"; # only needed for UIQ2/UIQ3 $SDK_ToolchainDirs{'UIQ3'} = "$DevBase\\ECompXL\\bin"; # only needed for UIQ2/UIQ3 @@ -94,14 +118,14 @@ { ## Standard libraries $SDK_LibraryDirs{'ALL'}{'zlib.lib'} = "$DevBase\\zlib-1.2.2\\epoc"; - #$SDK_LibraryDirs{'ALL'}{'libmad.lib'} = "$DevBase\\libmad-0.15.1b\\group"; + $SDK_LibraryDirs{'ALL'}{'libmad.lib'} = "$DevBase\\libmad-0.15.1b\\group"; $SDK_LibraryDirs{'ALL'}{'libtremor.lib'}= "$DevBase\\tremor\\epoc"; ## SDL 1.2.12 / AnotherGuest / Symbian version my $SdlBase = "$DevBase\\SDL-1.2.12-ag\\Symbian"; #$SDK_LibraryDirs{'S60v1'}{'esdl.lib'} = "$SdlBase\\S60"; // unsupported? #$SDK_LibraryDirs{'S60v2'}{'esdl.lib'} = "$SdlBase\\S60v2"; - $SDK_LibraryDirs{'S60v3'}{'esdl.lib'} = "$SdlBase\\S60v3"; + $SDK_LibraryDirs{'S60v3'}{'esdl.lib'} = "$SdlBase\\S60v5"; #$SDK_LibraryDirs{'S80'}{'esdl.lib'} = "$SdlBase\\S80"; #$SDK_LibraryDirs{'S90'}{'esdl.lib'} = "$SdlBase\\S90"; #$SDK_LibraryDirs{'UIQ2'}{'esdl.lib'} = "$SdlBase\\UIQ2" @@ -186,7 +210,7 @@ # now you can add $VariationSets only built on this PC below this line :) } - elsif ($ENV{'COMPUTERNAME'} eq "EMBEDDEV-LAPE") ################################################################# + elsif ($ENV{'COMPUTERNAME'} eq "EMBEDDEV-VAIO2") ################################################################# { $Producer = "AnotherGuest"; $RedirectSTDERR = 1; @@ -206,7 +230,7 @@ $SDK_RootDirs{'S60v3'}= "G:\\S60v3"; #$SDK_RootDirs{'S80'}= "D:\\S80"; #$SDK_RootDirs{'S90'}= "D:\\S90"; - $ECompXL_BinDir= "D:\\ECompXL\\"; + #$ECompXL_BinDir= "D:\\ECompXL\\"; if (0) # so we can turn them on/off easily { # $SDK_LibraryDirs{'ALL'}{'zlib.lib'} = "C:\\S\\zlib-1.2.2\\epoc"; @@ -223,38 +247,42 @@ # now you can add $VariationSets only built on this PC below this line :) } - elsif ($ENV{'COMPUTERNAME'} eq "EMBEDDEV_VAIO1") ################################################################# + elsif ($ENV{'COMPUTERNAME'} eq "FEDOR4EVER") ################################################################# { - $Producer = "AnotherGuest"; + $Producer = "Fedor"; $RedirectSTDERR = 1; $HaltOnError = 0; - $SkipExistingPackages = 1; - $ReallyQuiet = 1; + $SkipExistingPackages = 0; + $ReallyQuiet = 0; + $Compiler = "D:\\Program/ Files\\CodeSourcery\\Sourcery/ G++/ Lite"; #$FTP_Host = "host.com"; #$FTP_User = "ag@host.com"; #$FTP_Pass = "password"; #$FTP_Dir = "cvsbuilds"; - #$SDK_RootDirs{'UIQ2'}= "D:\\UIQ2"; - $SDK_RootDirs{'UIQ3'}= "G:\\UIQ3"; - #$SDK_RootDirs{'S60v1'}= "D:\\S60v1"; - #$SDK_RootDirs{'S60v2'}= "D:\\S60v2"; - $SDK_RootDirs{'S60v3'}= "G:\\S60v3"; - #$SDK_RootDirs{'S80'}= "D:\\S80"; - #$SDK_RootDirs{'S90'}= "D:\\S90"; - #$ECompXL_BinDir= "D:\\ECompXL\\"; + #$SDK_RootDirs{'UIQ2'}= "C:\\UIQ2"; + #$SDK_RootDirs{'UIQ3'}= "C:\\UIQ3"; + #$SDK_RootDirs{'S60v1'}= "C:\\S60v1"; + #$SDK_RootDirs{'S60v2'}= "C:\\S60v2"; + #$SDK_RootDirs{'S80'}= "C:\\S80"; + #$SDK_RootDirs{'S90'}= "C:\\S90"; + #$ECompXL_BinDir= "C:\\ECompXL\\"; + + $SDK_RootDirs{'S60v3'}= "D:\\Symbian\\S60_5th_Edition_SDK_v1.0"; + $SDK_ToolchainDirs{'S60v3'} = "$Compiler\\arm-symbianelf\\bin"; + + # these supporting libraries get built first, then all the Variations + # Note: the string {'xxx.lib'} is used in checking in build success: so needs to be accurate! if (0) # so we can turn them on/off easily { # $SDK_LibraryDirs{'ALL'}{'zlib.lib'} = "C:\\S\\zlib-1.2.2\\epoc"; -# $SDK_LibraryDirs{'ALL'}{'libmad.lib'} = "C:\\S\\libmad-0.15.1b\\group"; -# $SDK_LibraryDirs{'ALL'}{'libtremor.lib'}= "C:\\tremor\\epoc"; - $SDK_LibraryDirs{'UIQ2'}{'esdl.lib'} = "E:\\WICKED\\ESDL\\epoc\\UIQ"; - $SDK_LibraryDirs{'S60v1'}{'esdl.lib'} = $SDK_LibraryDirs{'S60v2'}{'esdl.lib'} = "E:\\WICKED\\ESDL\\epoc\\S60"; - $SDK_LibraryDirs{'S80'}{'esdl.lib'} = "E:\\WICKED\\ESDL\\epoc\\S80"; - $SDK_LibraryDirs{'S90'}{'esdl.lib'} = "E:\\WICKED\\ESDL\\epoc\\S90"; - $SDK_LibraryDirs{'S60v3'}{'esdl.lib'} = "E:\\WICKED\\ESDL\\epoc\\S60\\S60V3"; - $SDK_LibraryDirs{'UIQ3'}{'esdl.lib'} = "E:\\WICKED\\ESDL\\epoc\\UIQ\\UIQ3"; + $SDK_LibraryDirs{'ALL'}{'libmad.lib'} = "D:\\Symbian\\Projects\\SDL\\libs\\libmad-0.15.1b\\epoc"; +# $SDK_LibraryDirs{'ALL'}{'libtremor.lib'}= "D:\\Symbian\\Projects\\SDL\\libs\\Tremor\\epoc"; +# $SDK_LibraryDirs{'UIQ2'}{'esdl.lib'} = $SDK_LibraryDirs{'UIQ3'}{'esdl.lib'} = "C:\\S\\ESDL\\epoc\\UIQ"; +# $SDK_LibraryDirs{'S60v1'}{'esdl.lib'} = $SDK_LibraryDirs{'S60v2'}{'esdl.lib'} = $SDK_LibraryDirs{'S60v3'}{'esdl.lib'} = "C:\\S\\ESDL\\epoc\\S60"; +# $SDK_LibraryDirs{'S80'}{'esdl.lib'} = "C:\\S\\ESDL\\epoc\\S80"; +# $SDK_LibraryDirs{'S90'}{'esdl.lib'} = "C:\\S\\ESDL\\epoc\\S90"; } # now you can add $VariationSets only built on this PC below this line :) @@ -297,9 +325,10 @@ { # the first one includes all SDKs & release-ready engines - $VariationSets{'ALL'}{'all'} = "$DefaultFeatures @WorkingEngines @EnablableSubEngines"; -# $VariationSets{'ALL'}{'1St'} = "$DefaultFeatures @WorkingEngines_1st @EnablableSubEngines"; -# $VariationSets{'ALL'}{'2nd'} = "$DefaultFeatures @WorkingEngines_2nd @EnablableSubEngines"; + # $VariationSets{'ALL'}{'all'} = "$DefaultFeatures @WorkingEngines @EnablableSubEngines"; + $VariationSets{'ALL'}{'split'} = "$DefaultFeatures @WorkingEngines @EnablableSubEngines"; + # $VariationSets{'ALL'}{'1St'} = "$DefaultFeatures @WorkingEngines_1st @EnablableSubEngines"; + # $VariationSets{'ALL'}{'2nd'} = "$DefaultFeatures @WorkingEngines_2nd @EnablableSubEngines"; # now one for each ready-for-release engine if (0) { diff --git a/backends/platform/symbian/README b/backends/platform/symbian/README index 58cbc7814a..8a44e9399d 100644 --- a/backends/platform/symbian/README +++ b/backends/platform/symbian/README @@ -1,8 +1,9 @@ ScummVM - ScummVM ported to EPOC/SymbianOS - Copyright (C) 2008-2013 ScummVM Team - Copyright (C) 2003-2008 Lars 'AnotherGuest' Persson + Copyright (C) 2008-2014 ScummVM Team + Copyright (C) 2013-2013 Fedor Strizhniou aka zanac + Copyright (C) 2003-2013 Lars 'AnotherGuest' Persson Copyright (C) 2002-2008 Jurgen 'SumthinWicked' Braam Copyright (C) 2003-2005 Andreas 'Sprawl' Karlsson @@ -24,6 +25,15 @@ About ScummVM Jurgen and Lars have successfully transfered all needed changes into CVS/SVN, with additional helpful tools for Symbian OS Release History: +Release version: 1.7.0 + * Nothing significant in the Symbian port, except SDL improvements (new SDL version used) + +Release version: 1.6.0 + * Nothing significant in the Symbian port, except SDL improvements (new SDL version used) + + Release version: 1.5.0 + * Nothing significant in the Symbian port, except SDL improvements (new SDL version used) + Release version: 1.4.0 * Nothing significant in the Symbian port, except SDL improvements (new SDL version used) * See main readme for general ScummVM improvements, major update diff --git a/backends/platform/symbian/S60/ScummVM_S60.mmp.in b/backends/platform/symbian/S60/ScummVM_S60.mmp.in index 28bd11dec6..ca2ec7f930 100644 --- a/backends/platform/symbian/S60/ScummVM_S60.mmp.in +++ b/backends/platform/symbian/S60/ScummVM_S60.mmp.in @@ -2,7 +2,7 @@ * Copyright (C) 2003-2005 Andreas 'Sprawl' Karlsson - Original EPOC port, ESDL * Copyright (C) 2003-2005 Lars 'AnotherGuest' Persson - Original EPOC port, Audio System * Copyright (C) 2005 Jurgen 'SumthinWicked' Braam - EPOC/CVS maintainer - * Copyright (C) 2005-2013 The ScummVM project + * Copyright (C) 2005-2014 The ScummVM Team * * ScummVM is the legal property of its developers, whose names * are too numerous to list here. Please refer to the COPYRIGHT diff --git a/backends/platform/symbian/S60/ScummVM_S60_App.mmp b/backends/platform/symbian/S60/ScummVM_S60_App.mmp index 38d6f19590..2fc39c6838 100644 --- a/backends/platform/symbian/S60/ScummVM_S60_App.mmp +++ b/backends/platform/symbian/S60/ScummVM_S60_App.mmp @@ -2,7 +2,7 @@ * Copyright (C) 2003-2005 Andreas 'Sprawl' Karlsson - Original EPOC port, ESDL * Copyright (C) 2003-2005 Lars 'AnotherGuest' Persson - Original EPOC port, Audio System * Copyright (C) 2005 Jurgen 'SumthinWicked' Braam - EPOC/CVS maintainer - * Copyright (C) 2005-2013 The ScummVM project + * Copyright (C) 2005-2014 The ScummVM Team * * ScummVM is the legal property of its developers, whose names * are too numerous to list here. Please refer to the COPYRIGHT diff --git a/backends/platform/symbian/S60v3/BLD.INF.in b/backends/platform/symbian/S60v3/BLD.INF.in index 78d130cb08..e21bcc7d01 100644 --- a/backends/platform/symbian/S60v3/BLD.INF.in +++ b/backends/platform/symbian/S60v3/BLD.INF.in @@ -8,5 +8,6 @@ PRJ_MMPFILES //STOP_AUTO_PROJECTS// gnumakefile icons.mk +gnumakefile ..\help\build_help.mk .\ScummVM_A0000658_S60v3.mmp .\ScummVM_S60v3.mmp diff --git a/backends/platform/symbian/S60v3/ScummVM_A0000658_S60v3.mmp.in b/backends/platform/symbian/S60v3/ScummVM_A0000658_S60v3.mmp.in index 99b89efba8..cbb9679340 100644 --- a/backends/platform/symbian/S60v3/ScummVM_A0000658_S60v3.mmp.in +++ b/backends/platform/symbian/S60v3/ScummVM_A0000658_S60v3.mmp.in @@ -34,6 +34,8 @@ TARGET ScummVM_A0000658.exe TARGETPATH sys\bin TARGETTYPE exe OPTION GCCE -Wno-multichar -Wno-reorder -Wno-unused -Wno-format -fsigned-char +// fixes error "section .data loaded at [...] overlaps section .text loaded at [...]" +LINKEROPTION GCCE -Tdata 0xAA00000 UID 0x100039ce 0xA0000658 @@ -90,9 +92,15 @@ STATICLIBRARY esdl.lib USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\engines USERINCLUDE ..\..\..\..\backends\fs ..\src ..\..\..\..\backends\platform\sdl ..\..\..\..\audio +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png SYSTEMINCLUDE \epoc32\include\ESDL SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor SYSTEMINCLUDE \epoc32\include SYSTEMINCLUDE \epoc32\include\mw SYSTEMINCLUDE \epoc32\include\platform diff --git a/backends/platform/symbian/S60v3/ScummVM_S60v3.mmp.in b/backends/platform/symbian/S60v3/ScummVM_S60v3.mmp.in index 1e0f282bc4..899d10dbe3 100644 --- a/backends/platform/symbian/S60v3/ScummVM_S60v3.mmp.in +++ b/backends/platform/symbian/S60v3/ScummVM_S60v3.mmp.in @@ -35,6 +35,9 @@ TARGETPATH sys\bin TARGETTYPE exe OPTION GCCE -Wno-multichar -Wno-reorder -Wno-unused -Wno-format -fsigned-char +// fixes error "section .data loaded at [...] overlaps section .text loaded at [...]" +LINKEROPTION GCCE -Tdata 0xAA00000 + UID 0x100039ce 0xA0000657 START RESOURCE ScummVM_reg.rss @@ -90,9 +93,15 @@ STATICLIBRARY esdl.lib USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\engines USERINCLUDE ..\..\..\..\backends\fs ..\src ..\..\..\..\backends\platform\sdl ..\..\..\..\audio +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png SYSTEMINCLUDE \epoc32\include\ESDL SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor SYSTEMINCLUDE \epoc32\include SYSTEMINCLUDE \epoc32\include\mw SYSTEMINCLUDE \epoc32\include\platform @@ -140,7 +149,7 @@ source engines\obsolete.cpp LIBRARY cone.lib eikcore.lib LIBRARY euser.lib apparc.lib fbscli.lib LIBRARY estlib.lib apgrfx.lib -LIBRARY gdi.lib hal.lib bitgdi.lib +LIBRARY gdi.lib hal.lib bitgdi.lib esock.lib LIBRARY mediaclientaudiostream.lib efsrv.lib ws32.lib library avkon.lib bafl.lib remconcoreapi.lib remconinterfacebase.lib diff --git a/backends/platform/symbian/S60v3/scummvm-CVS-SymbianS60v3.pkg b/backends/platform/symbian/S60v3/scummvm-CVS-SymbianS60v3.pkg index 4c6b1b05f8..5f74bee1c7 100644 --- a/backends/platform/symbian/S60v3/scummvm-CVS-SymbianS60v3.pkg +++ b/backends/platform/symbian/S60v3/scummvm-CVS-SymbianS60v3.pkg @@ -33,7 +33,7 @@ :"ScummVM" ; UID is the app's UID -#{"ScummVM S60v3"},(0xA0000657),1,60,0 +#{"ScummVM S60v3"},(0xA0000657),1,70,0 ;Supports Series 60 v 3.0 [0x101F7961], 0, 0, 0, {"Series60ProductID"} @@ -57,16 +57,22 @@ "..\..\..\..\README"-"!:\resource\apps\scummvm\README" "..\..\..\..\NEWS"-"!:\resource\apps\scummvm\NEWS" +; Scummvm help +"..\help\ScummVM.hlp"-"!:\resource\help\ScummVM.hlp" + ; Common datafiles needed for some games -"..\..\..\..\dists\engine-data\kyra.dat"-"c:\data\scummvm\kyra.dat" -"..\..\..\..\dists\engine-data\sky.cpt"-"c:\data\scummvm\sky.cpt" +"..\..\..\..\dists\engine-data\drascula.dat"-"c:\data\scummvm\drascula.dat" "..\..\..\..\dists\engine-data\hugo.dat"-"c:\data\scummvm\hugo.dat" +"..\..\..\..\dists\engine-data\kyra.dat"-"c:\data\scummvm\kyra.dat" "..\..\..\..\dists\engine-data\lure.dat"-"c:\data\scummvm\lure.dat" -"..\..\..\..\dists\engine-data\drascula.dat"-"c:\data\scummvm\drascula.dat" +"..\..\..\..\dists\engine-data\mort.dat"-"c:\data\scummvm\mort.dat" +"..\..\..\..\dists\engine-data\neverhood.dat"-"c:\data\scummvm\neverhood.dat" +"..\..\..\..\dists\engine-data\queen.tbl"-"c:\data\scummvm\queen.tbl" +"..\..\..\..\dists\engine-data\sky.cpt"-"c:\data\scummvm\sky.cpt" "..\..\..\..\dists\engine-data\teenagent.dat"-"c:\data\scummvm\teenagent.dat" +"..\..\..\..\dists\engine-data\tony.dat"-"c:\data\scummvm\tony.dat" "..\..\..\..\dists\engine-data\toon.dat"-"c:\data\scummvm\toon.dat" "..\..\..\..\dists\engine-data\wintermute.zip"-"c:\data\scummvm\wintermute.zip" -"..\..\..\..\dists\engine-data\tony.dat"-"c:\data\scummvm\tony.dat" "..\..\..\vkeybd\packs\vkeybd_default.zip"-"c:\data\scummvm\vkeybd_default.zip" "..\..\..\..\gui\themes\translations.dat"-"c:\data\scummvm\translations.dat" "..\..\..\..\gui\themes\scummmodern.zip"-"c:\data\scummvm\scummmodern.zip" diff --git a/backends/platform/symbian/S60v3/scummvm-CVS-SymbianS60v3_split.pkg b/backends/platform/symbian/S60v3/scummvm-CVS-SymbianS60v3_split.pkg index d3fd0450fa..4ef085d600 100644 --- a/backends/platform/symbian/S60v3/scummvm-CVS-SymbianS60v3_split.pkg +++ b/backends/platform/symbian/S60v3/scummvm-CVS-SymbianS60v3_split.pkg @@ -36,7 +36,7 @@ :"ScummVM" ; UID is the app's UID -#{"ScummVM S60v3"},(0xA0000657),1,60,0 +#{"ScummVM S60v3"},(0xA0000657),1,70,6 ;Supports Series 60 v 3.0 [0x101F7961], 0, 0, 0, {"Series60ProductID"} @@ -65,16 +65,22 @@ "..\..\..\..\README"-"!:\resource\apps\scummvm\README" "..\..\..\..\NEWS"-"!:\resource\apps\scummvm\NEWS" +; Scummvm help +"..\help\ScummVM.hlp"-"!:\resource\help\ScummVM.hlp" + ; Common datafiles needed for some games -"..\..\..\..\dists\engine-data\kyra.dat"-"c:\data\scummvm\kyra.dat" -"..\..\..\..\dists\engine-data\sky.cpt"-"c:\data\scummvm\sky.cpt" +"..\..\..\..\dists\engine-data\drascula.dat"-"c:\data\scummvm\drascula.dat" "..\..\..\..\dists\engine-data\hugo.dat"-"c:\data\scummvm\hugo.dat" +"..\..\..\..\dists\engine-data\kyra.dat"-"c:\data\scummvm\kyra.dat" "..\..\..\..\dists\engine-data\lure.dat"-"c:\data\scummvm\lure.dat" -"..\..\..\..\dists\engine-data\drascula.dat"-"c:\data\scummvm\drascula.dat" +"..\..\..\..\dists\engine-data\mort.dat"-"c:\data\scummvm\mort.dat" +"..\..\..\..\dists\engine-data\neverhood.dat"-"c:\data\scummvm\neverhood.dat" +"..\..\..\..\dists\engine-data\queen.tbl"-"c:\data\scummvm\queen.tbl" +"..\..\..\..\dists\engine-data\sky.cpt"-"c:\data\scummvm\sky.cpt" "..\..\..\..\dists\engine-data\teenagent.dat"-"c:\data\scummvm\teenagent.dat" +"..\..\..\..\dists\engine-data\tony.dat"-"c:\data\scummvm\tony.dat" "..\..\..\..\dists\engine-data\toon.dat"-"c:\data\scummvm\toon.dat" -"..\..\..\..\dists\engine-data\wintermute.zip-"c:\data\scummvm\wintermute.zip" -"..\..\..\..\dists\engine-data\tony.dat-"c:\data\scummvm\tony.dat" +"..\..\..\..\dists\engine-data\wintermute.zip"-"c:\data\scummvm\wintermute.zip" "..\..\..\vkeybd\packs\vkeybd_default.zip"-"c:\data\scummvm\vkeybd_default.zip" "..\..\..\..\gui\themes\translations.dat"-"c:\data\scummvm\translations.dat" "..\..\..\..\gui\themes\scummmodern.zip"-"c:\data\scummvm\scummmodern.zip" diff --git a/backends/platform/symbian/S80/ScummVM_S80.mmp.in b/backends/platform/symbian/S80/ScummVM_S80.mmp.in index d9b9a5c948..34d1979fe5 100644 --- a/backends/platform/symbian/S80/ScummVM_S80.mmp.in +++ b/backends/platform/symbian/S80/ScummVM_S80.mmp.in @@ -2,7 +2,7 @@ * Copyright (C) 2003-2005 Andreas 'Sprawl' Karlsson - Original EPOC port, ESDL * Copyright (C) 2003-2005 Lars 'AnotherGuest' Persson - Original EPOC port, Audio System * Copyright (C) 2005 Jurgen 'SumthinWicked' Braam - EPOC/CVS maintainer - * Copyright (C) 2005-2013 The ScummVM project + * Copyright (C) 2005-2014 The ScummVM Team * * ScummVM is the legal property of its developers, whose names * are too numerous to list here. Please refer to the COPYRIGHT diff --git a/backends/platform/symbian/S80/ScummVM_S80_App.mmp b/backends/platform/symbian/S80/ScummVM_S80_App.mmp index 30b1c3f58b..de96963d80 100644 --- a/backends/platform/symbian/S80/ScummVM_S80_App.mmp +++ b/backends/platform/symbian/S80/ScummVM_S80_App.mmp @@ -2,7 +2,7 @@ * Copyright (C) 2003-2005 Andreas 'Sprawl' Karlsson - Original EPOC port, ESDL * Copyright (C) 2003-2005 Lars 'AnotherGuest' Persson - Original EPOC port, Audio System * Copyright (C) 2005 Jurgen 'SumthinWicked' Braam - EPOC/CVS maintainer - * Copyright (C) 2005-2013 The ScummVM project + * Copyright (C) 2005-2014 The ScummVM Team * * ScummVM is the legal property of its developers, whose names * are too numerous to list here. Please refer to the COPYRIGHT diff --git a/backends/platform/symbian/S90/Scummvm_S90.mmp.in b/backends/platform/symbian/S90/Scummvm_S90.mmp.in index 790dca14f0..e65397b145 100644 --- a/backends/platform/symbian/S90/Scummvm_S90.mmp.in +++ b/backends/platform/symbian/S90/Scummvm_S90.mmp.in @@ -2,7 +2,7 @@ * Copyright (C) 2003-2005 Andreas 'Sprawl' Karlsson - Original EPOC port, ESDL * Copyright (C) 2003-2005 Lars 'AnotherGuest' Persson - Original EPOC port, Audio System * Copyright (C) 2005 Jurgen 'SumthinWicked' Braam - EPOC/CVS maintainer - * Copyright (C) 2005-2013 The ScummVM project + * Copyright (C) 2005-2014 The ScummVM Team * * ScummVM is the legal property of its developers, whose names * are too numerous to list here. Please refer to the COPYRIGHT diff --git a/backends/platform/symbian/S90/Scummvm_S90_App.mmp b/backends/platform/symbian/S90/Scummvm_S90_App.mmp index cf17f103ef..88a3e4d221 100644 --- a/backends/platform/symbian/S90/Scummvm_S90_App.mmp +++ b/backends/platform/symbian/S90/Scummvm_S90_App.mmp @@ -2,7 +2,7 @@ * Copyright (C) 2003-2005 Andreas 'Sprawl' Karlsson - Original EPOC port, ESDL * Copyright (C) 2003-2005 Lars 'AnotherGuest' Persson - Original EPOC port, Audio System * Copyright (C) 2005 Jurgen 'SumthinWicked' Braam - EPOC/CVS maintainer - * Copyright (C) 2005-2013 The ScummVM project + * Copyright (C) 2005-2014 The ScummVM Team * * ScummVM is the legal property of its developers, whose names * are too numerous to list here. Please refer to the COPYRIGHT diff --git a/backends/platform/symbian/UIQ2/ScummVM.rss b/backends/platform/symbian/UIQ2/ScummVM.rss index bfdd07e898..2e02f1da1d 100644 --- a/backends/platform/symbian/UIQ2/ScummVM.rss +++ b/backends/platform/symbian/UIQ2/ScummVM.rss @@ -2,7 +2,7 @@ * Copyright (C) 2003-2005 Andreas 'Sprawl' Karlsson - Original EPOC port, ESDL * Copyright (C) 2003-2005 Lars 'AnotherGuest' Persson - Original EPOC port, Audio System * Copyright (C) 2005 Jurgen 'SumthinWicked' Braam - EPOC/CVS maintainer - * Copyright (C) 2005-2013 The ScummVM project + * Copyright (C) 2005-2014 The ScummVM Team * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License diff --git a/backends/platform/symbian/UIQ2/ScummVM_UIQ2.mmp.in b/backends/platform/symbian/UIQ2/ScummVM_UIQ2.mmp.in index 80ba37d694..68f5bd0cab 100644 --- a/backends/platform/symbian/UIQ2/ScummVM_UIQ2.mmp.in +++ b/backends/platform/symbian/UIQ2/ScummVM_UIQ2.mmp.in @@ -2,7 +2,7 @@ * Copyright (C) 2003-2005 Andreas 'Sprawl' Karlsson - Original EPOC port, ESDL * Copyright (C) 2003-2005 Lars 'AnotherGuest' Persson - Original EPOC port, Audio System * Copyright (C) 2005 Jurgen 'SumthinWicked' Braam - EPOC/CVS maintainer - * Copyright (C) 2005-2006 The ScummVM project + * Copyright (C) 2005-2006 The ScummVM Team * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License diff --git a/backends/platform/symbian/UIQ3/ScummVM.rss b/backends/platform/symbian/UIQ3/ScummVM.rss index b7f0a17113..11cc767671 100644 --- a/backends/platform/symbian/UIQ3/ScummVM.rss +++ b/backends/platform/symbian/UIQ3/ScummVM.rss @@ -2,7 +2,7 @@ * Copyright (C) 2003-2005 Andreas 'Sprawl' Karlsson - Original EPOC port, ESDL * Copyright (C) 2003-2005 Lars 'AnotherGuest' Persson - Original EPOC port, Audio System * Copyright (C) 2005 Jurgen 'SumthinWicked' Braam - EPOC/CVS maintainer - * Copyright (C) 2005-2013 The ScummVM project + * Copyright (C) 2005-2014 The ScummVM Team * * ScummVM is the legal property of its developers, whose names * are too numerous to list here. Please refer to the COPYRIGHT diff --git a/backends/platform/symbian/UIQ3/ScummVM_A0000658.rss b/backends/platform/symbian/UIQ3/ScummVM_A0000658.rss index b7f0a17113..11cc767671 100644 --- a/backends/platform/symbian/UIQ3/ScummVM_A0000658.rss +++ b/backends/platform/symbian/UIQ3/ScummVM_A0000658.rss @@ -2,7 +2,7 @@ * Copyright (C) 2003-2005 Andreas 'Sprawl' Karlsson - Original EPOC port, ESDL * Copyright (C) 2003-2005 Lars 'AnotherGuest' Persson - Original EPOC port, Audio System * Copyright (C) 2005 Jurgen 'SumthinWicked' Braam - EPOC/CVS maintainer - * Copyright (C) 2005-2013 The ScummVM project + * Copyright (C) 2005-2014 The ScummVM Team * * ScummVM is the legal property of its developers, whose names * are too numerous to list here. Please refer to the COPYRIGHT diff --git a/backends/platform/symbian/UIQ3/ScummVM_A0000658_UIQ3.mmp.in b/backends/platform/symbian/UIQ3/ScummVM_A0000658_UIQ3.mmp.in index fac178ad15..7c9e9032d4 100644 --- a/backends/platform/symbian/UIQ3/ScummVM_A0000658_UIQ3.mmp.in +++ b/backends/platform/symbian/UIQ3/ScummVM_A0000658_UIQ3.mmp.in @@ -2,7 +2,7 @@ * Copyright (C) 2003-2005 Andreas 'Sprawl' Karlsson - Original EPOC port, ESDL * Copyright (C) 2003-2009 Lars 'AnotherGuest' Persson - Original EPOC port, Audio System * Copyright (C) 2009 Jurgen 'SumthinWicked' Braam - EPOC/CVS maintainer - * Copyright (C) 2005-2013 The ScummVM project + * Copyright (C) 2005-2014 The ScummVM Team * * ScummVM is the legal property of its developers, whose names * are too numerous to list here. Please refer to the COPYRIGHT @@ -35,6 +35,9 @@ TARGETPATH sys\bin TARGETTYPE exe OPTION GCCE -Wno-multichar -Wno-reorder -Wno-unused -Wno-format -fsigned-char +// fixes error "section .data loaded at [...] overlaps section .text loaded at [...]" +// in future simple add 'a' +LINKEROPTION GCCE -Tdata 0xAA00000 UID 0x100039ce 0xA0000658 diff --git a/backends/platform/symbian/UIQ3/ScummVM_UIQ3.mmp.in b/backends/platform/symbian/UIQ3/ScummVM_UIQ3.mmp.in index 0f1ec7f60f..ab2956af55 100644 --- a/backends/platform/symbian/UIQ3/ScummVM_UIQ3.mmp.in +++ b/backends/platform/symbian/UIQ3/ScummVM_UIQ3.mmp.in @@ -2,7 +2,7 @@ * Copyright (C) 2003-2005 Andreas 'Sprawl' Karlsson - Original EPOC port, ESDL * Copyright (C) 2003-2005 Lars 'AnotherGuest' Persson - Original EPOC port, Audio System * Copyright (C) 2005 Jurgen 'SumthinWicked' Braam - EPOC/CVS maintainer - * Copyright (C) 2005-2013 The ScummVM project + * Copyright (C) 2005-2014 The ScummVM Team * * ScummVM is the legal property of its developers, whose names * are too numerous to list here. Please refer to the COPYRIGHT @@ -35,6 +35,9 @@ TARGETPATH sys\bin TARGETTYPE exe OPTION GCCE -Wno-multichar -Wno-reorder -Wno-unused -Wno-format -fsigned-char +// fixes error "section .data loaded at [...] overlaps section .text loaded at [...]" +// in future simple add 'a' +LINKEROPTION GCCE -Tdata 0xAA00000 UID 0x100039ce 0xA0000657 diff --git a/backends/platform/symbian/UIQ3/scummvm-CVS-SymbianUIQ3.pkg b/backends/platform/symbian/UIQ3/scummvm-CVS-SymbianUIQ3.pkg index c62d25dafa..b4f1cfdd5c 100644 --- a/backends/platform/symbian/UIQ3/scummvm-CVS-SymbianUIQ3.pkg +++ b/backends/platform/symbian/UIQ3/scummvm-CVS-SymbianUIQ3.pkg @@ -32,7 +32,7 @@ :"ScummVM" ; UID is the app's UID -#{"ScummVM UIQ3"},(0xA0000657),1,60,0 +#{"ScummVM UIQ3"},(0xA0000657),1,70,0 ; ProductID for UIQ 3.0 ; Product/platform version UID, Major, Minor, Build, Product ID diff --git a/backends/platform/symbian/UIQ3/scummvm-CVS-SymbianUIQ3_split.pkg b/backends/platform/symbian/UIQ3/scummvm-CVS-SymbianUIQ3_split.pkg index a37e0b0533..722e23a1b8 100644 --- a/backends/platform/symbian/UIQ3/scummvm-CVS-SymbianUIQ3_split.pkg +++ b/backends/platform/symbian/UIQ3/scummvm-CVS-SymbianUIQ3_split.pkg @@ -35,7 +35,7 @@ :"ScummVM" ; UID is the app's UID -#{"ScummVM UIQ3"},(0xA0000657),1,60,0 +#{"ScummVM UIQ3"},(0xA0000657),1,70,0 ; ProductID for UIQ 3.0 ; Product/platform version UID, Major, Minor, Build, Product ID diff --git a/backends/platform/symbian/UIQ3/scummvm_A0000658_loc.rss b/backends/platform/symbian/UIQ3/scummvm_A0000658_loc.rss index 47e7c44642..f54bcc24d3 100644 --- a/backends/platform/symbian/UIQ3/scummvm_A0000658_loc.rss +++ b/backends/platform/symbian/UIQ3/scummvm_A0000658_loc.rss @@ -2,7 +2,7 @@ * Copyright (C) 2003-2005 Andreas 'Sprawl' Karlsson - Original EPOC port, ESDL * Copyright (C) 2003-2005 Lars 'AnotherGuest' Persson - Original EPOC port, Audio System * Copyright (C) 2005 Jurgen 'SumthinWicked' Braam - EPOC/CVS maintainer - * Copyright (C) 2005-2013 The ScummVM project + * Copyright (C) 2005-2014 The ScummVM Team * * ScummVM is the legal property of its developers, whose names * are too numerous to list here. Please refer to the COPYRIGHT diff --git a/backends/platform/symbian/help/Custom.xml b/backends/platform/symbian/help/Custom.xml new file mode 100644 index 0000000000..8bc518e036 --- /dev/null +++ b/backends/platform/symbian/help/Custom.xml @@ -0,0 +1,18 @@ +<?xml version="1.0"?> +<!DOCTYPE cshcust SYSTEM "/cshlpcmp/dtd/CSHcust.dtd"> +<?xml:stylesheet href="/cshlpcmp/xsl/cshcust.xsl" title="CS-Help customization" type="text/xsl"?> +<cshcust> +<parastyle name="body" font="sansserif" size="10"/> +<parastyle name="tip" font="sansserif" size="10" left="20"></parastyle> +<parastyle name="note" font="sansserif" size="10" left="20"></parastyle> +<parastyle name="important" font="sansserif" size="10" left="20"></parastyle> +<body style="body"/> +<titlestyle fontstyle="sansserif" size="10"/> +<listbullet1style bulletchar="8226"/> +<listbullet2style bulletchar="8226"/> +<lists leftindent="20"/> +</cshcust> + + + + diff --git a/backends/platform/symbian/help/ScummVM.rtf b/backends/platform/symbian/help/ScummVM.rtf new file mode 100644 index 0000000000..352e2e8776 --- /dev/null +++ b/backends/platform/symbian/help/ScummVM.rtf @@ -0,0 +1,341 @@ +{\rtf1\ansi\ansicpg1251\uc1 \deff1\deflang1049\deflangfe1049{\fonttbl{\f0\froman\fcharset204\fprq2{\*\panose 02020603050405020304}Times New Roman;}{\f1\fswiss\fcharset204\fprq2{\*\panose 020b0604020202020204}Arial;} +{\f2\fmodern\fcharset204\fprq1{\*\panose 02070309020205020404}Courier New;}{\f3\froman\fcharset2\fprq2{\*\panose 05050102010706020507}Symbol;}{\f8\froman\fcharset0\fprq2{\*\panose 00000000000000000000}Tms Rmn;} +{\f14\fnil\fcharset2\fprq2{\*\panose 05000000000000000000}Wingdings;}{\f28\fswiss\fcharset204\fprq2{\*\panose 020b0604020202020204}Arial CYR;}{\f29\fmodern\fcharset204\fprq1{\*\panose 02070309020205020404}Courier New CYR;} +{\f30\froman\fcharset2\fprq2{\*\panose 05030102010509060703}Webdings;}{\f31\fswiss\fcharset204\fprq2{\*\panose 020b0506020202030204}Arial Narrow;}{\f44\froman\fcharset0\fprq2 Times New Roman;}{\f42\froman\fcharset238\fprq2 Times New Roman CE;} +{\f45\froman\fcharset161\fprq2 Times New Roman Greek;}{\f46\froman\fcharset162\fprq2 Times New Roman Tur;}{\f47\froman\fcharset177\fprq2 Times New Roman (Hebrew);}{\f48\froman\fcharset178\fprq2 Times New Roman (Arabic);} +{\f49\froman\fcharset186\fprq2 Times New Roman Baltic;}{\f52\fswiss\fcharset0\fprq2 Arial;}{\f50\fswiss\fcharset238\fprq2 Arial CE;}{\f53\fswiss\fcharset161\fprq2 Arial Greek;}{\f54\fswiss\fcharset162\fprq2 Arial Tur;} +{\f55\fswiss\fcharset177\fprq2 Arial (Hebrew);}{\f56\fswiss\fcharset178\fprq2 Arial (Arabic);}{\f57\fswiss\fcharset186\fprq2 Arial Baltic;}{\f60\fmodern\fcharset0\fprq1 Courier New;}{\f58\fmodern\fcharset238\fprq1 Courier New CE;} +{\f61\fmodern\fcharset161\fprq1 Courier New Greek;}{\f62\fmodern\fcharset162\fprq1 Courier New Tur;}{\f63\fmodern\fcharset177\fprq1 Courier New (Hebrew);}{\f64\fmodern\fcharset178\fprq1 Courier New (Arabic);} +{\f65\fmodern\fcharset186\fprq1 Courier New Baltic;}{\f268\fswiss\fcharset0\fprq2 Arial CYR;}{\f266\fswiss\fcharset238\fprq2 Arial CYR CE;}{\f269\fswiss\fcharset161\fprq2 Arial CYR Greek;}{\f270\fswiss\fcharset162\fprq2 Arial CYR Tur;} +{\f271\fswiss\fcharset177\fprq2 Arial CYR (Hebrew);}{\f272\fswiss\fcharset178\fprq2 Arial CYR (Arabic);}{\f273\fswiss\fcharset186\fprq2 Arial CYR Baltic;}{\f276\fmodern\fcharset0\fprq1 Courier New CYR;}{\f274\fmodern\fcharset238\fprq1 Courier New CYR CE;} +{\f277\fmodern\fcharset161\fprq1 Courier New CYR Greek;}{\f278\fmodern\fcharset162\fprq1 Courier New CYR Tur;}{\f279\fmodern\fcharset177\fprq1 Courier New CYR (Hebrew);}{\f280\fmodern\fcharset178\fprq1 Courier New CYR (Arabic);} +{\f281\fmodern\fcharset186\fprq1 Courier New CYR Baltic;}{\f292\fswiss\fcharset0\fprq2 Arial Narrow;}{\f290\fswiss\fcharset238\fprq2 Arial Narrow CE;}{\f293\fswiss\fcharset161\fprq2 Arial Narrow Greek;}{\f294\fswiss\fcharset162\fprq2 Arial Narrow Tur;} +{\f297\fswiss\fcharset186\fprq2 Arial Narrow Baltic;}}{\colortbl;\red0\green0\blue0;\red0\green0\blue255;\red0\green255\blue255;\red0\green255\blue0;\red255\green0\blue255;\red255\green0\blue0;\red255\green255\blue0;\red255\green255\blue255; +\red0\green0\blue128;\red0\green128\blue128;\red0\green128\blue0;\red128\green0\blue128;\red128\green0\blue0;\red128\green128\blue0;\red128\green128\blue128;\red192\green192\blue192;}{\stylesheet{ +\ql \li0\ri0\sa120\widctlpar\nooverflow\faroman\rin0\lin0\itap0 \f1\fs20\lang2057\langfe1033\cgrid\langnp2057\langfenp1033 \snext0 Normal;}{\s1\ql \li0\ri0\sb360\sa240\keepn\widctlpar\nooverflow\faroman\rin0\lin0\itap0 +\b\f1\fs32\lang2057\langfe1033\kerning28\cgrid\langnp2057\langfenp1033 \sbasedon0 \snext0 heading 1;}{\s2\ql \li0\ri0\sb120\sa120\keepn\widctlpar\brdrt\brdrs\brdrw30\brsp20 \brdrb\brdrs\brdrw30\brsp20 \tqr\tx9072\nooverflow\faroman\rin0\lin0\itap0 +\b\f1\fs24\lang2057\langfe1033\cgrid\langnp2057\langfenp1033 \sbasedon0 \snext0 heading 2;}{\s3\ql \li0\ri0\sb120\sa120\keepn\widctlpar\brdrt\brdrs\brdrw30\brsp20 \tqr\tx9072\nooverflow\faroman\rin0\lin0\itap0 +\b\f1\fs28\lang2057\langfe1033\cgrid\langnp2057\langfenp1033 \sbasedon0 \snext0 heading 3;}{\s4\ql \li0\ri0\sb120\sa120\keepn\widctlpar\brdrt\brdrs\brdrw15\brsp20 \tqr\tx9072\nooverflow\faroman\rin0\lin0\itap0 +\b\f1\fs24\lang2057\langfe1033\cgrid\langnp2057\langfenp1033 \sbasedon0 \snext0 heading 4;}{\s5\ql \li0\ri0\sa120\keepn\widctlpar\nooverflow\faroman\rin0\lin0\itap0 \b\f1\fs20\lang2057\langfe1033\cgrid\langnp2057\langfenp1033 \sbasedon0 \snext0 +heading 5;}{\s6\ql \li0\ri0\sb240\sa60\widctlpar\nooverflow\faroman\rin0\lin0\itap0 \i\f1\fs22\lang2057\langfe1033\cgrid\langnp2057\langfenp1033 \sbasedon0 \snext0 heading 6;}{\s7\ql \li0\ri0\sb240\sa60\widctlpar\nooverflow\faroman\rin0\lin0\itap0 +\f1\fs20\lang2057\langfe1033\cgrid\langnp2057\langfenp1033 \sbasedon0 \snext0 heading 7;}{\s8\ql \li0\ri0\sb240\sa60\widctlpar\nooverflow\faroman\rin0\lin0\itap0 \i\f1\fs20\lang2057\langfe1033\cgrid\langnp2057\langfenp1033 \sbasedon0 \snext0 heading 8;}{ +\s9\ql \li0\ri0\sb240\sa60\widctlpar\nooverflow\faroman\rin0\lin0\itap0 \i\f1\fs18\lang2057\langfe1033\cgrid\langnp2057\langfenp1033 \sbasedon0 \snext0 heading 9;}{\*\cs10 \additive Default Paragraph Font;}{\*\cs15 \additive \b\f1\fs20 \sbasedon10 +App Text;}{\s16\ql \li0\ri0\sb360\sa240\keepn\widctlpar\nooverflow\faroman\rin0\lin0\itap0 \b\f1\fs32\cf9\lang2057\langfe1033\kerning28\cgrid\langnp2057\langfenp1033 \sbasedon0 \snext16 Category UID;}{ +\s17\ql \li0\ri0\sa120\widctlpar\nooverflow\faroman\rin0\lin0\itap0 \i\f1\fs20\lang2057\langfe1033\cgrid\langnp2057\langfenp1033 \sbasedon0 \snext17 Comment;}{\s18\ql \fi-283\li283\ri0\sa120\widctlpar\brdrb\brdrs\brdrw15\brsp20 {\*\pn +\pnlvlblt\ilvl10\ls2047\pnrnot0\pnf30\pnstart1\pnindent283\pnhang{\pntxtb \'a2}}\nooverflow\faroman\ls2047\ilvl10\rin0\lin283\itap0 \f1\fs20\lang2057\langfe1033\cgrid\langnp2057\langfenp1033 \sbasedon0 \snext18 Context;}{\*\cs19 \additive +\i\f1\fs20\ulnone\cf0\nosupersub \sbasedon10 Context Comment;}{\s20\ql \li0\ri0\sa120\widctlpar\nooverflow\faroman\rin0\lin0\itap0 \f1\fs20\cf11\lang2057\langfe1033\cgrid\langnp2057\langfenp1033 \sbasedon0 \snext20 Definition Term;}{ +\s21\ql \li0\ri0\sa120\widctlpar\nooverflow\faroman\rin0\lin0\itap0 \f1\fs20\cf11\lang2057\langfe1033\cgrid\langnp2057\langfenp1033 \sbasedon20 \snext21 Definition Definition;}{\*\cs22 \additive \scaps\f31\fs20\cf13 \sbasedon10 Graphic Link;}{ +\s23\ql \fi-283\li283\ri0\sa120\widctlpar{\*\pn \pnlvlblt\ilvl10\ls2047\pnrnot0\pnf14\pnstart1\pnindent283\pnhang{\pntxtb F}}\nooverflow\faroman\ls2047\ilvl10\rin0\lin283\itap0 \f1\fs20\lang2057\langfe1033\cgrid\langnp2057\langfenp1033 +\sbasedon0 \snext23 Tip;}{\s24\ql \fi-283\li283\ri0\sa120\widctlpar{\*\pn \pnlvlblt\ilvl10\ls2047\pnrnot0\pnf14\pnstart1\pnindent283\pnhang{\pntxtb ?}}\nooverflow\faroman\ls2047\ilvl10\rin0\lin283\itap0 +\f1\fs20\lang2057\langfe1033\cgrid\langnp2057\langfenp1033 \sbasedon23 \snext24 Note;}{\s25\ql \fi-283\li283\ri0\sa120\widctlpar{\*\pn \pnlvlblt\ilvl10\ls2047\pnrnot0\pnf30\pnstart1\pnindent283\pnhang{\pntxtb ~}} +\nooverflow\faroman\ls2047\ilvl10\rin0\lin283\itap0 \f1\fs20\lang2057\langfe1033\cgrid\langnp2057\langfenp1033 \sbasedon24 \snext25 Important;}{\s26\ql \fi-283\li283\ri0\sa120\widctlpar\brdrb\brdrs\brdrw15\brsp20 {\*\pn \pnlvlblt\ilvl10\ls2047\pnrnot0 +\pnf30\pnstart1\pnindent283\pnhang{\pntxtb i}}\nooverflow\faroman\ls2047\ilvl10\rin0\lin283\itap0 \f1\fs20\lang2057\langfe1033\cgrid\langnp2057\langfenp1033 \sbasedon0 \snext26 Index;}{\*\cs27 \additive \b\f2\fs20 \sbasedon10 Key Name;}{ +\s28\ql \fi-284\li284\ri0\sa120\widctlpar{\*\pn \pnlvlbody\ilvl11\ls2047\pnrnot0\pndec\pnstart1\pnindent283\pnhang{\pntxta .}}\nooverflow\faroman\ls2047\ilvl11\rin0\lin284\itap0 \f1\fs20\lang2057\langfe1033\cgrid\langnp2057\langfenp1033 +\sbasedon0 \snext28 List Number;}{\s29\ql \fi-284\li284\ri0\sa120\widctlpar\tx284{\*\pn \pnlvlbody\ilvl0\ls2047\pnrnot0\pndec\pnf8 }\nooverflow\faroman\ls2047\rin0\lin284\itap0 \f1\fs20\lang2057\langfe1033\cgrid\langnp2057\langfenp1033 +\sbasedon28 \snext29 List Manual;}{\s30\ql \fi-284\li568\ri0\sa120\widctlpar{\*\pn \pnlvlbody\ilvl11\ls2047\pnrnot0\pndec\pnstart1\pnindent283\pnhang{\pntxta .}}\nooverflow\faroman\ls2047\ilvl11\rin0\lin568\itap0 +\f1\fs20\lang2057\langfe1033\cgrid\langnp2057\langfenp1033 \sbasedon0 \snext30 List Number 2;}{\s31\ql \fi-284\li568\ri0\sa120\widctlpar\tx284{\*\pn \pnlvlbody\ilvl0\ls2047\pnrnot0\pndec\pnf8 }\nooverflow\faroman\ls2047\rin0\lin568\itap0 +\f1\fs20\lang2057\langfe1033\cgrid\langnp2057\langfenp1033 \sbasedon30 \snext31 List Manual 2;}{\s32\ql \li0\ri0\sa120\widctlpar\nooverflow\faroman\rin0\lin0\itap0 \f1\fs20\cf13\lang2057\langfe1033\cgrid\langnp2057\langfenp1033 \sbasedon0 \snext32 +Synonyms;}{\*\cs33 \additive \super \sbasedon10 endnote reference;}{\s34\ql \fi-284\li284\ri0\sa120\widctlpar\tx284{\*\pn \pnlvlblt\ilvl10\ls2047\pnrnot0\pnf3\pnstart1\pnindent283\pnhang{\pntxtb \'b7}}\nooverflow\faroman\ls2047\ilvl10\rin0\lin284\itap0 +\f1\fs20\lang2057\langfe1033\cgrid\langnp2057\langfenp1033 \sbasedon0 \snext34 \sautoupd List Bullet;}{\s35\ql \fi-284\li568\ri0\sa120\widctlpar{\*\pn \pnlvlblt\ilvl10\ls2047\pnrnot0\pnf3\pnstart1\pnindent283\pnhang{\pntxtb \'b7}} +\nooverflow\faroman\ls2047\ilvl10\rin0\lin568\itap0 \f1\fs20\lang2057\langfe1033\cgrid\langnp2057\langfenp1033 \sbasedon0 \snext35 \sautoupd List Bullet 2;}{\s36\ql \li0\ri0\sa120\widctlpar\tqc\tx4153\tqr\tx8306\nooverflow\faroman\rin0\lin0\itap0 +\f1\fs20\lang2057\langfe1033\cgrid\langnp2057\langfenp1033 \sbasedon0 \snext36 footer;}{\s37\ql \li284\ri0\sa120\widctlpar\nooverflow\faroman\rin0\lin284\itap0 \f1\fs20\lang2057\langfe1033\cgrid\langnp2057\langfenp1033 \sbasedon0 \snext37 List Continue;}{ +\s38\ql \li566\ri0\sa120\widctlpar\nooverflow\faroman\rin0\lin566\itap0 \f1\fs20\lang2057\langfe1033\cgrid\langnp2057\langfenp1033 \sbasedon0 \snext38 List Continue 2;}}{\*\listtable{\list\listtemplateid-737142542\listsimple{\listlevel\levelnfc0 +\levelnfcn0\leveljc0\leveljcn0\levelfollow0\levelstartat1\levelspace0\levelindent0{\leveltext\'02\'00.;}{\levelnumbers\'01;}\chbrdr\brdrnone\brdrcf1 \chshdng0\chcfpat1\chcbpat1 \fi-360\li643\jclisttab\tx643 }{\listname ;}\listid-129} +{\list\listtemplateid1907811784\listsimple{\listlevel\levelnfc23\levelnfcn23\leveljc0\leveljcn0\levelfollow0\levelstartat1\levelspace0\levelindent0{\leveltext\'01\u-3913 ?;}{\levelnumbers;}\f3\chbrdr\brdrnone\brdrcf1 \chshdng0\chcfpat1\chcbpat1\fbias0 +\fi-360\li643\jclisttab\tx643 }{\listname ;}\listid-125}{\list\listtemplateid1912741052\listsimple{\listlevel\levelnfc0\levelnfcn0\leveljc0\leveljcn0\levelfollow0\levelstartat1\levelspace0\levelindent0{\leveltext\'02\'00.;}{\levelnumbers\'01;}\chbrdr +\brdrnone\brdrcf1 \chshdng0\chcfpat1\chcbpat1 \fi-360\li360\jclisttab\tx360 }{\listname ;}\listid-120}{\list\listtemplateid-51363132\listsimple{\listlevel\levelnfc23\levelnfcn23\leveljc0\leveljcn0\levelfollow0\levelstartat1\levelspace0\levelindent0 +{\leveltext\'01\u-3913 ?;}{\levelnumbers;}\f3\chbrdr\brdrnone\brdrcf1 \chshdng0\chcfpat1\chcbpat1\fbias0 \fi-360\li360\jclisttab\tx360 }{\listname ;}\listid-119}{\list\listtemplateid947971744\listsimple{\listlevel\levelnfc0\levelnfcn0\leveljc0\leveljcn0 +\levelfollow0\levelstartat0\levelspace0\levelindent0{\leveltext\'01*;}{\levelnumbers;}\chbrdr\brdrnone\brdrcf1 \chshdng0\chcfpat1\chcbpat1 }{\listname ;}\listid-2}}{\*\listoverridetable{\listoverride\listid-120\listoverridecount0\ls1} +{\listoverride\listid-129\listoverridecount0\ls2}{\listoverride\listid-119\listoverridecount0\ls3}{\listoverride\listid-125\listoverridecount0\ls4}{\listoverride\listid-120\listoverridecount0\ls5}{\listoverride\listid-129\listoverridecount0\ls6} +{\listoverride\listid-119\listoverridecount0\ls7}{\listoverride\listid-125\listoverridecount0\ls8}{\listoverride\listid-120\listoverridecount0\ls9}{\listoverride\listid-129\listoverridecount0\ls10}{\listoverride\listid-119\listoverridecount0\ls11} +{\listoverride\listid-125\listoverridecount0\ls12}{\listoverride\listid-120\listoverridecount0\ls13}{\listoverride\listid-129\listoverridecount0\ls14}{\listoverride\listid-119\listoverridecount0\ls15}{\listoverride\listid-125\listoverridecount0\ls16} +{\listoverride\listid-120\listoverridecount0\ls17}{\listoverride\listid-129\listoverridecount0\ls18}{\listoverride\listid-119\listoverridecount0\ls19}{\listoverride\listid-125\listoverridecount0\ls20}{\listoverride\listid-2\listoverridecount1{\lfolevel +\listoverrideformat{\listlevel\levelnfc23\levelnfcn23\leveljc0\leveljcn0\levelfollow0\levelstartat1\levelold\levelspace0\levelindent283{\leveltext\'01\u-3991 ?;}{\levelnumbers;}\f30\chbrdr\brdrnone\brdrcf1 \chshdng0\chcfpat1\chcbpat1\fbias0 \fi-283\li283 +}}\ls21}{\listoverride\listid-2\listoverridecount1{\lfolevel\listoverrideformat{\listlevel\levelnfc23\levelnfcn23\leveljc0\leveljcn0\levelfollow0\levelstartat1\levelold\levelspace0\levelindent283{\leveltext\'01\u-3991 ?;}{\levelnumbers;}\f30\chbrdr +\brdrnone\brdrcf1 \chshdng0\chcfpat1\chcbpat1\fbias0 \fi-283\li283 }}\ls22}}{\info{\author Fedor}{\operator Fedor}{\creatim\yr2013\mo11\dy30\hr23\min4}{\revtim\yr2014\mo5\dy28\hr12\min17}{\version97}{\edmins91}{\nofpages8}{\nofwords1514}{\nofchars8634} +{\*\company DEV}{\nofcharsws0}{\vern8249}}\margl1701\margr850\margt1134\margb1134 \deftab708\widowctrl\ftnbj\aenddoc\noxlattoyen\expshrtn\noultrlspc\dntblnsbdb\nospaceforul\hyphcaps0\horzdoc\dghspace120\dgvspace120\dghorigin1701\dgvorigin1984\dghshow0 +\dgvshow3\jcompress\viewkind4\viewscale100\nolnhtadjtbl \fet0{\*\template E:\\Documents and Settings\\Administrator\\Application Data\\Microsoft\\\'d8\'e0\'e1\'eb\'ee\'ed\'fb\\cshelp2000.dot}\sectd \linex0\sectdefaultcl {\*\pnseclvl1 +\pnucrm\pnstart1\pnindent720\pnhang{\pntxta .}}{\*\pnseclvl2\pnucltr\pnstart1\pnindent720\pnhang{\pntxta .}}{\*\pnseclvl3\pndec\pnstart1\pnindent720\pnhang{\pntxta .}}{\*\pnseclvl4\pnlcltr\pnstart1\pnindent720\pnhang{\pntxta )}}{\*\pnseclvl5 +\pndec\pnstart1\pnindent720\pnhang{\pntxtb (}{\pntxta )}}{\*\pnseclvl6\pnlcltr\pnstart1\pnindent720\pnhang{\pntxtb (}{\pntxta )}}{\*\pnseclvl7\pnlcrm\pnstart1\pnindent720\pnhang{\pntxtb (}{\pntxta )}}{\*\pnseclvl8\pnlcltr\pnstart1\pnindent720\pnhang +{\pntxtb (}{\pntxta )}}{\*\pnseclvl9\pnlcrm\pnstart1\pnindent720\pnhang{\pntxtb (}{\pntxta )}}\pard\plain \s17\ql \li0\ri0\sa120\widctlpar\nooverflow\faroman\rin0\lin0\itap0 \i\f1\fs20\lang2057\langfe1033\cgrid\langnp2057\langfenp1033 { +\lang1033\langfe1033\langnp1033 Author: Fedor Strizhniou.}{\f28 +\par }{\lang1033\langfe1033\langnp1033 Date: November 2013}{\f28 +\par }{\lang1033\langfe1033\langnp1033 Version: 1.7.0 +\par }\pard\plain \s1\ql \li0\ri0\sb360\sa240\keepn\widctlpar\nooverflow\faroman\outlinelevel0\rin0\lin0\itap0 \b\f1\fs32\lang2057\langfe1033\kerning28\cgrid\langnp2057\langfenp1033 {ScummVM Help +\par }\pard\plain \s16\ql \li0\ri0\sb360\sa240\keepn\widctlpar\nooverflow\faroman\rin0\lin0\itap0 \b\f1\fs32\cf9\lang2057\langfe1033\kerning28\cgrid\langnp2057\langfenp1033 {\lang1033\langfe1033\langnp1033 0x100039ce}{\lang1059\langfe1033\langnp1059 +\par }\pard\plain \ql \li0\ri0\sa120\widctlpar\nooverflow\faroman\rin0\lin0\itap0 \f1\fs20\lang2057\langfe1033\cgrid\langnp2057\langfenp1033 {\f28 +\par }\pard\plain \s2\ql \li0\ri0\sb120\sa120\keepn\widctlpar\brdrt\brdrs\brdrw30\brsp20 \brdrb\brdrs\brdrw30\brsp20 \tqr\tx9072\nooverflow\faroman\outlinelevel1\rin0\lin0\itap0 \b\f1\fs24\lang2057\langfe1033\cgrid\langnp2057\langfenp1033 {\b0\f28 +About ScummVM Help +\par {\pntext\pard\plain\s26 \f30\fs20\lang2057\langfe1033\langnp2057\langfenp1033 \loch\af30\dbch\af0\hich\f30 \'69\tab}}\pard\plain \s26\ql \fi-283\li283\ri0\sa120\widctlpar\brdrb\brdrs\brdrw15\brsp20 {\*\pn \pnlvlblt\ilvl0\ls21\pnrnot0 +\pnf30\pnstart1\pnindent283\pnhang{\pntxtb i}}\nooverflow\faroman\ls21\rin0\lin283\itap0 \f1\fs20\lang2057\langfe1033\cgrid\langnp2057\langfenp1033 {About ScummVM Help +\par }\pard\plain \ql \li0\ri0\sa120\widctlpar{\*\pn \pnlvlcont\ilvl0\ls0\pnrnot0\pndec }\nooverflow\faroman\rin0\lin0\itap0 \f1\fs20\lang2057\langfe1033\cgrid\langnp2057\langfenp1033 {\f28 +\par }{ +This help file based on ScummVM forum thread with some elaborations(in Anotherguest section) and text correction. If you wish add some text or translate you may download and modify source document from https://sourceforge.net/projects/scummvms60git/ and t +hen send me to fedor_qd@mail.ru +\par Feel free to replace, merge or write you own instead 1st, 2nd and 3rd guides. Other sections require strict translations. And don\rquote t forget add your name :-) +\par First guide contain help by Anotherguest, second - VincentJ, third - murgo. This doc created by Fedor Strizhniou. +\par Enjoys, cheers! Always yours =)}{\lang1059\langfe1033\langnp1059 +\par }{\f29 +\par }\pard\plain \s2\ql \li0\ri0\sb120\sa120\keepn\widctlpar\brdrt\brdrs\brdrw30\brsp20 \brdrb\brdrs\brdrw30\brsp20 \tqr\tx9072{\*\pn \pnlvlcont\ilvl0\ls0\pnrnot0\pndec }\nooverflow\faroman\outlinelevel1\rin0\lin0\itap0 +\b\f1\fs24\lang2057\langfe1033\cgrid\langnp2057\langfenp1033 {\b0\f28 1st guide +\par {\pntext\pard\plain\s26 \f30\fs20\lang2057\langfe1033\langnp2057\langfenp1033 \loch\af30\dbch\af0\hich\f30 \'69\tab}}\pard\plain \s26\ql \fi-283\li283\ri0\sa120\widctlpar\brdrb\brdrs\brdrw15\brsp20 {\*\pn \pnlvlblt\ilvl0\ls21\pnrnot0 +\pnf30\pnstart1\pnindent283\pnhang{\pntxtb i}}\nooverflow\faroman\ls21\rin0\lin283\itap0 \f1\fs20\lang2057\langfe1033\cgrid\langnp2057\langfenp1033 {Controls, Virtual keyboard, Shortcuts, ScummVM, Tips, S60, UIQ, UIQ3, S80, s80, S90, s90 +\par }\pard\plain \ql \li0\ri0\sa120\widctlpar{\*\pn \pnlvlcont\ilvl0\ls0\pnrnot0\pndec }\nooverflow\faroman\rin0\lin0\itap0 \f1\fs20\lang2057\langfe1033\cgrid\langnp2057\langfenp1033 {\f28 +\par }{UIQ3 devices: To the top right (holding the phone portrait) you four icons, from the top they are +\par +\par * Toggle control mode, in control mode you can change text input , screen orientation and screen scaling +\par * Mouse button, toggles between left, right and no button when tapping the screen. If no button is selected, 7 & Space works as left mouse button and 9 & Enter works as the right mouse button. +\par * Esc, tap this to simulate ESC key being pressed. Same functionally on devices with 'C' key. +\par * Virtual keyboard toggle, toggles the virtual keyboard, if not enabled when selecting '1'/'7' in control mode. +\par * When Virtual keyboard is enabled you have more onscreen keys available +\par * Enter key +\par * Backspace +\par * Arrow Up/Down to scroll the keys available +\par * Virtual keyboard, tap letters to simulate key presses. +\par +\par S60 and UIQ3 devices: (Control Key = Green Phone key, to activate/deactivate control mode in SDL) +\par }{\f29 +\par }{* 1 = change Input Mode: Joystick | Keyboard | Cursor +\par * 2,'p' = change Video Mode: Landscape | Portrait +\par * 3,'f' = change Orientation Mode for Landscape: 90\'b0 Left | 90\'b0 Right +\par * 4,'s' = Toggle between stretched and non-stretched modes +\par * 5 = Toggle between interpolating stretch or not +\par * 7,'t' = Text/Multitap input +\par * 8,'c' = Cursor input +\par * 9,'j' = Joystick input +\par * 0,'m' = Mouse input +\par * Up/Down = Alter global volume when not in 1-1 VGA mode. Pan around in VGA 1-1 Mode +\par * # = On/Off screen keyboard transparency in some games +\par +\par S80 devices: +\par +\par * Side key 1 = Fire Joystick 1 button (JoyMode) +\par * Side key 2 = Fire Joystick 2 button (JoyMode) or change Video Mode: Upscaled | Normal (CursorMode) +\par * Side key 3 = change Input Mode: Joystick | Cursor +\par +\par S90 devices: (Control Key = OK, pressed simultaneously with other keys to activate the mode changes in SDL) +\par +\par * OK+1 = change Input Mode: Joystick | Cursor +\par * OK+2 = change Video Mode: Upscaled | Normal +\par +\par What are these Joystick, Keyboard and Cursor modes anyway? +\par }{\f28 +\par }{Joystick mode sends SDL joystick events to ScummVM which acts as a mouse control in ScummVM. Cursor mode sends keyboard arrows instead, so for example it can be used to navigate +through directorylist (one hand use perhaps!?) or save games etc. Keyboard mode is only available for S60 and enables multi-tap to enter text characters in save dialogs. These modes are implemented at the underlying SDL level, so this determines the types + of events that ScummVM receives from SDL. +\par What are these Shrinked, Zoomed and Upscaled modes anyway? +\par +\par Shrink displays the game on your screen but in a shrinked way, either in Portrait or Landscape mode, so not all the pixels can be seen. Zoom mode uses the maximum resolution of your phone displaying a smaller part of the game zoomed at 1:1 pixels. For scr +olling in S60 Zoom mode: 0+Cursor keys to scroll around, 0+Ok button to center view. Upscale tries to fill the larger screens on S80/S90 devices in a better way for low resolution games. Currently it uses a pixel interpolation upscaling routine. +\par +\par You can also use a bluetooth mouse with S60v3 devices to control your game. You need the bluetooth hid library from Hinkka http://koti.mbnet.fi/hinkka/Download.html to get it to work properly. +\par }{\f29 +\par +\par }\pard\plain \s2\ql \li0\ri0\sb120\sa120\keepn\widctlpar\brdrt\brdrs\brdrw30\brsp20 \brdrb\brdrs\brdrw30\brsp20 \tqr\tx9072{\*\pn \pnlvlcont\ilvl0\ls0\pnrnot0\pndec }\nooverflow\faroman\outlinelevel1\rin0\lin0\itap0 +\b\f1\fs24\lang2057\langfe1033\cgrid\langnp2057\langfenp1033 {\b0\f28 2nd guide +\par {\pntext\pard\plain\s26 \f30\fs20\lang2057\langfe1033\langnp2057\langfenp1033 \loch\af30\dbch\af0\hich\f30 \'69\tab}}\pard\plain \s26\ql \fi-283\li283\ri0\sa120\widctlpar\brdrb\brdrs\brdrw15\brsp20 {\*\pn \pnlvlblt\ilvl0\ls21\pnrnot0 +\pnf30\pnstart1\pnindent283\pnhang{\pntxtb i}}\nooverflow\faroman\ls21\rin0\lin283\itap0 \f1\fs20\lang2057\langfe1033\cgrid\langnp2057\langfenp1033 {Controls, Virtual keyboard, Shortcuts, ScummVM, Tips, S60, s60 +\par }\pard\plain \ql \li0\ri0\sa120\widctlpar{\*\pn \pnlvlcont\ilvl0\ls0\pnrnot0\pndec }\nooverflow\faroman\rin0\lin0\itap0 \f1\fs20\lang2057\langfe1033\cgrid\langnp2057\langfenp1033 {\f28 +\par +\par }{More user-friendly guide for Nokia phones (based on N96 but should apply to most phones) +\par +\par Left Soft Key - Left Click +\par }{\f28 +\par }{Right Soft Key - Right Click +\par }{\f28 +\par }{Navigation buttons - Move pointer on screen +\par }{\f28 +\par }{"C" or "Delete Key" - Space Bar (i.e. skip dialogue/cutscene) +\par }{\f28 +\par }{* - Bring up Menu (to Save, Load and change the game's options e.g. enable subtitles, speech etc. Varies from game to game) +\par +\par The <> is a toggling left right mode. I.e. first click is left, next is right, next is left etc. +\par +\par Call Button - Enter/Exit Configuration Mode +\par }{\f28 +\par }{Configuration Mode, when activated, shows the word "CTRL" in green in the upper right corner of the screen. It allows to quickly switch between various functions of ScummVM. The following buttons on your keypad are activated when "CTRL" is displayed : + +\par }{\f29 +\par }{1 - Change Input. +\par This is the option you'll probably use the most. There are three settings; A,C and J. +\par +\par A - This is the "Text Input" mode. It allows you to type directl +y into ScummVM as if you were using a keyboard. Type the same way you would when sending a text message off of your phone. Please note that the pointer is disabled when in this mode. Don't forget to exit Configuration Mode before typing! +\par +\par C - This is the "Cursor" mode. This emulates the arrow keys of the keyboard. Some games require using this instead of the mouse (e.g. the destruction derby section towards the end of Full Throttle). +\par +\par J - This is the "Joystick/Mouse" mode. Simply put, it allows you to use the navigation buttons to move the pointer around the screen. The left and right mouse buttons are used by the left and right Soft keys. +\par +\par The "C" button emulates the space bar, i.e. skip line of dialogue, skip cutscene or pause game (depending on the game, some games simply use the left mouse button to skip dialogue in which case it will pause the game instead) +\par }{\f29 +\par }{2 - Toggle Landscape and Portrait +\par Switches the screen output between having the phone held normally (Portrait) or on its side (Landscape). You'll probably never take it off Landscape mode as it offers the better display area. +\par +\par 3 - Change Landscape Orientation +\par Only applies to Landscape mode, simply swaps the screen output between having the phone tilted on its left side or on its right side. +\par +\par 4 - Toggle Zoom On and Off +\par Zooms in on a portion of the screen. Handy for when you are looking through a screen for items or having trouble reading subtitles. Use the navigation buttons for panning around the play area. Don't forget you'll have to exit out of Confi +guration Mode before you can move the pointer again. Exiting Configuration Mode does not reset the zoom level. +\par }{\f29 +\par }{5 & 6 - Unused +\par +\par 7 - "Text Input" mode. Shortcut for entering "Text Input" mode directly instead of cycling through the other input types using the "1" key. +\par +\par 8 - "Cursor" mode. Shortcut for entering "Cursor" mode directly instead of cycling through the other input types using the "1" key. +\par +\par 9 - "Joystick/Mouse" mode. Shortcut for entering "Joystick/Mouse" mode directly instead of cycling through the other input types using the +\par +\par "1" key. +\par +\par 0 & * - Unused (The "*" Menu is disabled in Configuration Mode") +\par +\par Up Navigation Button - Increase ScummVM sound volume. Note that the game itself may have its own independent sound settings (usually found under the * menu) +\par +\par Down Navigation Button - Decrease ScummVM sound volume. Note that the game itself may have its own independent sound settings (usually found under the * menu) +\par }{\f29 +\par +\par }\pard\plain \s2\ql \li0\ri0\sb120\sa120\keepn\widctlpar\brdrt\brdrs\brdrw30\brsp20 \brdrb\brdrs\brdrw30\brsp20 \tqr\tx9072{\*\pn \pnlvlcont\ilvl0\ls0\pnrnot0\pndec }\nooverflow\faroman\outlinelevel1\rin0\lin0\itap0 +\b\f1\fs24\lang2057\langfe1033\cgrid\langnp2057\langfenp1033 {\b0\f28 3rd guide +\par {\pntext\pard\plain\s26 \f30\fs20\lang2057\langfe1033\langnp2057\langfenp1033 \loch\af30\dbch\af0\hich\f30 \'69\tab}}\pard\plain \s26\ql \fi-283\li283\ri0\sa120\widctlpar\brdrb\brdrs\brdrw15\brsp20 {\*\pn \pnlvlblt\ilvl0\ls21\pnrnot0 +\pnf30\pnstart1\pnindent283\pnhang{\pntxtb i}}\nooverflow\faroman\ls21\rin0\lin283\itap0 \f1\fs20\lang2057\langfe1033\cgrid\langnp2057\langfenp1033 {Controls, Virtual keyboard, Shortcuts, ScummVM, Tips, S60, s60 +\par }\pard\plain \ql \li0\ri0\sa120\widctlpar{\*\pn \pnlvlcont\ilvl0\ls0\pnrnot0\pndec }\nooverflow\faroman\rin0\lin0\itap0 \f1\fs20\lang2057\langfe1033\cgrid\langnp2057\langfenp1033 {\f28 +\par +\par }{ScummVM keys on Nokia e71 (most likely on any other qwerty-device, too), tested on version 0.14.0svn (Feb. 18 2009 + 05:56:07). Number keys are inserted by first pressing fn-key (leftmost key at bottom row on E71) and then pressing correct key (e.g. 5 is fn+g). You don't have to press both keys simultaneously. +\par +\par Basic keys: +\par +\par Joystick -- Move cursor (in joystick mode) / arrow keys (in keyboard / cursor mode) +\par Joystick button -- Skip text +\par Left soft key -- Left mouse button +\par Right soft key -- Right mouse button (context sensitive actions in Lucas Arts' games, something else in others) +\par Backspace -- Esc / Skips demos / Removes selected action +\par * (fn+u) -- Menu +\par Space -- Pause +\par Enter -- Enter (usually same as left soft key) +\par +\par In main menu: +\par Shift -- Shift (can be used to mass-add games) +\par You can press the first letter of the game name to jump there in the games list. +\par +\par CTRL-keys: +\par To use these, first click on green answer key once, so that text CTRL shows up in the northwest corner of the screen, then click the key. +\par +\par p / 2 -- Screen orientation +\par s / 5 -- Screen size +\par k / 7 -- Input mode: keyboard +\par c / 8 -- Input mode: cursor +\par j / 9 -- Input mode: joystick +\par joystick up -- Volume up +\par joystick down -- Volume down +\par 1 -- Toggle input mode +\par +\par Game specific: +\par Most games have some specific keys (the same as in desktop model of ScummVM?). For instance in Day of the Tentacle: +\par +\par w -- Walk to +\par l -- Look at +\par p -- Pick up +\par c -- Close +\par o -- Open +\par g -- Give +\par t -- Talk to +\par s -- Push +\par y -- Pull +\par }{\f29 +\par }{and in Full Throttle (from the top of my head): +\par +\par k -- kick (foot) +\par t -- talk (mouth) +\par l -- look (eyes) +\par p -- punch (hand) +\par +\par AGI games (King's Quest, Police Quest etc.): +\par The games work beautifully on the E71, but there's some stupid bugs (in input). I recall finding some debug keys and "last sentence" / "inventory" -keys in earlier version, but I can't find them any more. Also you can't turn on sirens in Police Quest, whi +ch kinda makes it unplayable. +\par +\par There's good side and bad side to each input mode: +\par Keyboard (I use this primarily) +\par }{\f29 +\par }{* goes to menu +\par + you can erase text +\par + moving is relatively easy +\par - you can't type in UPPER CASE +\par - you can't type numbers +\par - worthless 'current key' -display on left top corner +\par +\par Joystick / Cursor: +\par }{\f29 +\par }{+ you can access menus +\par + you can type numbers (just make sure f-letter in left top corner is red before clicking "numbers". It works kinda funnily, but you'll get hang of it.) +\par - you move mouse cursor which makes walking harder (joystick mode) +\par - you can't erase text +\par }{\f28 +\par }\pard\plain \s2\ql \li0\ri0\sb120\sa120\keepn\widctlpar\brdrt\brdrs\brdrw30\brsp20 \brdrb\brdrs\brdrw30\brsp20 \tqr\tx9072{\*\pn \pnlvlcont\ilvl0\ls0\pnrnot0\pndec }\nooverflow\faroman\outlinelevel1\rin0\lin0\itap0 +\b\f1\fs24\lang2057\langfe1033\cgrid\langnp2057\langfenp1033 {ScummVM1 engines list +\par {\pntext\pard\plain\s26 \f30\fs20\lang2057\langfe1033\langnp2057\langfenp1033 \loch\af30\dbch\af0\hich\f30 \'69\tab}}\pard\plain \s26\ql \fi-283\li283\ri0\sa120\widctlpar\brdrb\brdrs\brdrw15\brsp20 {\*\pn \pnlvlblt\ilvl0\ls22\pnrnot0 +\pnf30\pnstart1\pnindent283\pnhang{\pntxtb i}}\nooverflow\faroman\ls22\rin0\lin283\itap0 \f1\fs20\lang2057\langfe1033\cgrid\langnp2057\langfenp1033 {Supported engines +\par }\pard\plain \ql \li0\ri0\sa120\widctlpar{\*\pn \pnlvlcont\ilvl0\ls0\pnrnot0\pndec }\nooverflow\faroman\rin0\lin0\itap0 \f1\fs20\lang2057\langfe1033\cgrid\langnp2057\langfenp1033 {agi +\par agos +\par \tab AGOS2 +\par cine +\par composer +\par cruise +\par drascula +\par gob +\par groovie +\par \tab GROOVIE2 +\par kyra +\par \tab EOB +\par \tab LOL +\par lastexpress +\par made +\par neverhood +\par parallaction +\par queen +\par saga +\par \tab IHNM +\par \tab SAGA2 +\par scumm +\par \tab HE +\par \tab SCUMM_7_8 +\par touche +\par tucker +\par wintermute +\par +\par }\pard\plain \s2\ql \li0\ri0\sb120\sa120\keepn\widctlpar\brdrt\brdrs\brdrw30\brsp20 \brdrb\brdrs\brdrw30\brsp20 \tqr\tx9072{\*\pn \pnlvlcont\ilvl0\ls0\pnrnot0\pndec }\nooverflow\faroman\outlinelevel1\rin0\lin0\itap0 +\b\f1\fs24\lang2057\langfe1033\cgrid\langnp2057\langfenp1033 {ScummVM2 engines list +\par {\pntext\pard\plain\s26 \f30\fs20\lang2057\langfe1033\langnp2057\langfenp1033 \loch\af30\dbch\af0\hich\f30 \'69\tab}}\pard\plain \s26\ql \fi-283\li283\ri0\sa120\widctlpar\brdrb\brdrs\brdrw15\brsp20 {\*\pn \pnlvlblt\ilvl0\ls22\pnrnot0 +\pnf30\pnstart1\pnindent283\pnhang{\pntxtb i}}\nooverflow\faroman\ls22\rin0\lin283\itap0 \f1\fs20\lang2057\langfe1033\cgrid\langnp2057\langfenp1033 {Supported engines +\par }\pard\plain \ql \li0\ri0\sa120\widctlpar\nooverflow\faroman\rin0\lin0\itap0 \f1\fs20\lang2057\langfe1033\cgrid\langnp2057\langfenp1033 {avalanche +\par cge +\par composer +\par draci +\par dreamweb +\par fullpipe +\par hopkins +\par hugo +\par lure +\par mads +\par mohawk +\par \tab CSTIME +\par \tab MYST +\par \tab RIVEN +\par mortevielle +\par pegasus +\par sci +\par \tab SCI32 +\par sky +\par sword1 +\par sword2 +\par sword25(Not supported) +\par teenagent +\par testbed +\par tinsel +\par toltecs +\par tony +\par toon +\par tsage +\par zvision +\par }}
\ No newline at end of file diff --git a/backends/platform/symbian/help/ScummVM.xml b/backends/platform/symbian/help/ScummVM.xml new file mode 100644 index 0000000000..a1a787012a --- /dev/null +++ b/backends/platform/symbian/help/ScummVM.xml @@ -0,0 +1,19 @@ +<?xml version="1.0" encoding="UTF-8"?> +<?xml:stylesheet href="\epoc32\tools\cshlpcmp\xsl\CSHproj.xsl" title="CS Help project" type="text/xsl"?> +<!DOCTYPE cshproj SYSTEM "\epoc32\tools\cshlpcmp\dtd\CSHproj.dtd"> + +<cshproj> + <helpfileUID>0x100039ce</helpfileUID> <!-- From help file --> + <directories> + <input></input> + <output></output> + <working></working> + </directories> + <files> + <source> + <file>ScummVM.rtf</file> + </source> + <destination>ScummVM.hlp</destination> + <customization>custom.xml</customization> + </files> +</cshproj> diff --git a/backends/platform/symbian/help/build_help.mk b/backends/platform/symbian/help/build_help.mk new file mode 100644 index 0000000000..7a18ad8252 --- /dev/null +++ b/backends/platform/symbian/help/build_help.mk @@ -0,0 +1,29 @@ +# ============================================================================ +# Name : help.mk +# Part of : ScummVM +# +# Description: This is file for creating .hlp file +# +# ============================================================================ + + +makmake : + cshlpcmp ScummVM.xml + +ifeq (WINS,$(findstring WINS, $(PLATFORM))) + copy ScummVM.hlp $(EPOCROOT)epoc32\$(PLATFORM)\c\resource\help +endif + +clean : + del ScummVM.hlp + del ScummVM.hlp.hrh + +bld : + cshlpcmp ScummVM.xml + +ifeq (WINS,$(findstring WINS, $(PLATFORM))) + copy ScummVM.hlp $(EPOCROOT)epoc32\$(PLATFORM)\c\resource\help +endif + +freeze lib cleanlib final resource savespace releasables : + diff --git a/backends/platform/symbian/mmp/scummvm_agi.mmp.in b/backends/platform/symbian/mmp/scummvm_agi.mmp.in index 892ed57732..d6f9e54b7d 100644 --- a/backends/platform/symbian/mmp/scummvm_agi.mmp.in +++ b/backends/platform/symbian/mmp/scummvm_agi.mmp.in @@ -57,5 +57,15 @@ SOURCEPATH ..\..\..\..\engines\agi USERINCLUDE ..\..\..\..\engines USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\audio ..\src + +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png +SYSTEMINCLUDE \epoc32\include\ESDL SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version -SYSTEMINCLUDE \epoc32\include \epoc32\include\libc ..\src +SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor +SYSTEMINCLUDE \epoc32\include +SYSTEMINCLUDE ..\src // for portdefs.h diff --git a/backends/platform/symbian/mmp/scummvm_agos.mmp.in b/backends/platform/symbian/mmp/scummvm_agos.mmp.in index d3bc84ed51..d2b1329a24 100644 --- a/backends/platform/symbian/mmp/scummvm_agos.mmp.in +++ b/backends/platform/symbian/mmp/scummvm_agos.mmp.in @@ -63,5 +63,15 @@ SOURCEPATH ..\..\..\..\engines\agos USERINCLUDE ..\..\..\..\engines USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\audio ..\src + +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png +SYSTEMINCLUDE \epoc32\include\ESDL SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version -SYSTEMINCLUDE \epoc32\include \epoc32\include\libc ..\src +SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor +SYSTEMINCLUDE \epoc32\include +SYSTEMINCLUDE ..\src // for portdefs.h diff --git a/backends/platform/symbian/mmp/scummvm_avalanche.mmp.in b/backends/platform/symbian/mmp/scummvm_avalanche.mmp.in new file mode 100644 index 0000000000..5260edc79d --- /dev/null +++ b/backends/platform/symbian/mmp/scummvm_avalanche.mmp.in @@ -0,0 +1,72 @@ +/* ScummVM - Graphic Adventure Engine + * Copyright (C) 2003-2005 Andreas 'Sprawl' Karlsson - Original EPOC port, ESDL + * Copyright (C) 2003-2005 Lars 'AnotherGuest' Persson - Original EPOC port, Audio System + * Copyright (C) 2005 Jurgen 'SumthinWicked' Braam - EPOC/CVS maintainer + * Copyright (C) 2005-2013 The ScummVM project + * Copyright (C) 2013 Strizniou Fedor + * + * ScummVM is the legal property of its developers, whose names + * are too numerous to list here. Please refer to the COPYRIGHT + * file distributed with this source distribution. + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + */ + +// +// EPOC MMP makefile project for ScummVM +// + +// *** Definitions + +TARGET scummvm_avalanche.lib +TARGETTYPE lib +OPTION MSVC /QIfist /Ob1 /Oy /GF // /QIfist disables use of __ftol2 to avoid linker probs with MS libc: http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vccore/html/vcrefQIfistSuppress_ftol.asp +OPTION GCC -Wno-multichar -Wno-reorder // don't optimize for ARM, platform way too sensitive for that :( just turn off some common warnings +OPTION GCCE -Wno-multichar -Wno-reorder -Wno-unused -Wno-format -fsigned-char +ALWAYS_BUILD_AS_ARM + +//START_AUTO_MACROS_SLAVE// + + // empty base file, will be updated by Perl build scripts + +//STOP_AUTO_MACROS_SLAVE// + +// *** SOURCE files + +SOURCEPATH ..\..\..\..\engines\avalanche + +//START_AUTO_OBJECTS_AVALANCHE_// + + // empty base file, will be updated by Perl build scripts + +//STOP_AUTO_OBJECTS_AVALANCHE_// + +// *** Include paths + +USERINCLUDE ..\..\..\..\engines +USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\audio ..\src + +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png +SYSTEMINCLUDE \epoc32\include\ESDL +SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version +SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor +SYSTEMINCLUDE \epoc32\include +SYSTEMINCLUDE ..\src // for portdefs.h diff --git a/backends/platform/symbian/mmp/scummvm_base.mmp.in b/backends/platform/symbian/mmp/scummvm_base.mmp.in index d6dfafd014..37c68bf237 100644 --- a/backends/platform/symbian/mmp/scummvm_base.mmp.in +++ b/backends/platform/symbian/mmp/scummvm_base.mmp.in @@ -34,7 +34,9 @@ TARGET scummvm_base.lib TARGETTYPE lib OPTION MSVC /QIfist /Ob1 /Oy /GF // /QIfist disables use of __ftol2 to avoid linker probs with MS libc: http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vccore/html/vcrefQIfistSuppress_ftol.asp OPTION GCC -Wno-multichar -Wno-reorder // don't optimize for ARM, platform way too sensitive for that :( just turn off some common warnings -OPTION GCCE -Wno-multichar -Wno-reorder -Wno-unused -Wno-format -fsigned-char +// using option -Wno-psabi to supress warning "note: the mangling of 'va_list' has changed in GCC 4.4" +// compiler must use png.h from libpng.lib instead ScummVM's +OPTION GCCE -Wno-multichar -Wno-reorder -Wno-unused -Wno-format -fsigned-char -Wno-psabi -I'/Symbian/S60_5th_Edition_SDK_v1.0/epoc32/include/png' ALWAYS_BUILD_AS_ARM // Note: the LIB:*.lib statements are used by AdaptAllMMPs.pl, so don't remove them! @@ -50,15 +52,18 @@ ALWAYS_BUILD_AS_ARM USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\audio USERINCLUDE ..\..\..\..\backends\fs ..\src ..\..\..\..\backends\platform\sdl +USERINCLUDE \epoc32\include\mpeg2dec //\epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png SYSTEMINCLUDE \epoc32\include\ESDL SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora SYSTEMINCLUDE \epoc32\include\tremor SYSTEMINCLUDE \epoc32\include -SYSTEMINCLUDE \epoc32\include\mw -SYSTEMINCLUDE \epoc32\include\platform -SYSTEMINCLUDE \epoc32\include\platform\mw SYSTEMINCLUDE ..\src // for portdefs.h // *** SOURCE files @@ -80,6 +85,14 @@ SOURCEPATH ..\..\..\..\graphics //STOP_AUTO_OBJECTS_GRAPHICS_// +SOURCEPATH ..\..\..\..\image +//START_AUTO_OBJECTS_IMAGE_// + + // empty base file, will be updated by Perl build scripts + +//STOP_AUTO_OBJECTS_IMAGE_// + + SOURCEPATH ..\..\..\..\gui //START_AUTO_OBJECTS_GUI_// @@ -115,6 +128,11 @@ SOURCEPATH ..\..\..\..\video //STOP_AUTO_OBJECTS_VIDEO_// // add a few files manually, since they are not parsed from modules.mk files +SOURCE theora_decoder.cpp +SOURCE bink_decoder.cpp +// add a few files manually, since they are not parsed from modules.mk files +SOURCE codecs\mpeg.cpp + SOURCEPATH ..\..\..\.. SOURCE backends\events\default\default-events.cpp SOURCE backends\timer\default\default-timer.cpp @@ -156,4 +174,5 @@ SOURCE backends\vkeybd\virtual-keyboard.cpp // Downscaler SOURCE graphics\scaler\downscaler.cpp +SOURCE graphics\scaler\downscalerARM.s MACRO SDL_BACKEND diff --git a/backends/platform/symbian/mmp/scummvm_bbvs.mmp.in b/backends/platform/symbian/mmp/scummvm_bbvs.mmp.in new file mode 100644 index 0000000000..b4981e6eec --- /dev/null +++ b/backends/platform/symbian/mmp/scummvm_bbvs.mmp.in @@ -0,0 +1,72 @@ +/* ScummVM - Graphic Adventure Engine + * Copyright (C) 2003-2005 Andreas 'Sprawl' Karlsson - Original EPOC port, ESDL + * Copyright (C) 2003-2005 Lars 'AnotherGuest' Persson - Original EPOC port, Audio System + * Copyright (C) 2005 Jurgen 'SumthinWicked' Braam - EPOC/CVS maintainer + * Copyright (C) 2005-2014 The ScummVM Team + * Copyright (C) 2014 Fedor Strizhniou - Epoc project file + * + * ScummVM is the legal property of its developers, whose names + * are too numerous to list here. Please refer to the COPYRIGHT + * file distributed with this source distribution. + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + */ + +// +// EPOC MMP makefile project for ScummVM +// + +// *** Definitions + +TARGET scummvm_bbvs.lib +TARGETTYPE lib +OPTION MSVC /QIfist /Ob1 /Oy /GF // /QIfist disables use of __ftol2 to avoid linker probs with MS libc: http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vccore/html/vcrefQIfistSuppress_ftol.asp +OPTION GCC -Wno-multichar -Wno-reorder // don't optimize for ARM, platform way too sensitive for that :( just turn off some common warnings +OPTION GCCE -Wno-multichar -Wno-reorder -Wno-unused -Wno-format -fsigned-char +ALWAYS_BUILD_AS_ARM + +//START_AUTO_MACROS_SLAVE// + + // empty base file, will be updated by Perl build scripts + +//STOP_AUTO_MACROS_SLAVE// + +// *** SOURCE files + +SOURCEPATH ..\..\..\..\engines\bbvs + +//START_AUTO_OBJECTS_BBVS_// + + // empty base file, will be updated by Perl build scripts + +//STOP_AUTO_OBJECTS_BBVS_// + +// *** Include paths + +USERINCLUDE ..\..\..\..\engines +USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\audio ..\src + +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png +SYSTEMINCLUDE \epoc32\include\ESDL +SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version +SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor +SYSTEMINCLUDE \epoc32\include +SYSTEMINCLUDE ..\src // for portdefs.h diff --git a/backends/platform/symbian/mmp/scummvm_cge.mmp.in b/backends/platform/symbian/mmp/scummvm_cge.mmp.in index 66a689efd8..35cb0f2f98 100644 --- a/backends/platform/symbian/mmp/scummvm_cge.mmp.in +++ b/backends/platform/symbian/mmp/scummvm_cge.mmp.in @@ -57,5 +57,15 @@ SOURCEPATH ..\..\..\..\engines\cge USERINCLUDE ..\..\..\..\engines USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\audio ..\src + +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png +SYSTEMINCLUDE \epoc32\include\ESDL SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version -SYSTEMINCLUDE \epoc32\include \epoc32\include\libc ..\src +SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor +SYSTEMINCLUDE \epoc32\include +SYSTEMINCLUDE ..\src // for portdefs.h diff --git a/backends/platform/symbian/mmp/scummvm_cine.mmp.in b/backends/platform/symbian/mmp/scummvm_cine.mmp.in index cb7143b837..99b45cddb8 100644 --- a/backends/platform/symbian/mmp/scummvm_cine.mmp.in +++ b/backends/platform/symbian/mmp/scummvm_cine.mmp.in @@ -57,4 +57,15 @@ SOURCEPATH ..\..\..\..\engines\cine USERINCLUDE ..\..\..\..\engines USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\audio ..\src -SYSTEMINCLUDE \epoc32\include \epoc32\include\libc ..\src + +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png +SYSTEMINCLUDE \epoc32\include\ESDL +SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version +SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor +SYSTEMINCLUDE \epoc32\include +SYSTEMINCLUDE ..\src // for portdefs.h diff --git a/backends/platform/symbian/mmp/scummvm_composer.mmp.in b/backends/platform/symbian/mmp/scummvm_composer.mmp.in index 19215f65a6..5a215f2d8d 100644 --- a/backends/platform/symbian/mmp/scummvm_composer.mmp.in +++ b/backends/platform/symbian/mmp/scummvm_composer.mmp.in @@ -57,5 +57,15 @@ SOURCEPATH ..\..\..\..\engines\COMPOSER USERINCLUDE ..\..\..\..\engines USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\audio ..\src + +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png +SYSTEMINCLUDE \epoc32\include\ESDL SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version -SYSTEMINCLUDE \epoc32\include \epoc32\include\libc ..\src +SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor +SYSTEMINCLUDE \epoc32\include +SYSTEMINCLUDE ..\src // for portdefs.h diff --git a/backends/platform/symbian/mmp/scummvm_cruise.mmp.in b/backends/platform/symbian/mmp/scummvm_cruise.mmp.in index c26e93dedc..21a674dc1f 100644 --- a/backends/platform/symbian/mmp/scummvm_cruise.mmp.in +++ b/backends/platform/symbian/mmp/scummvm_cruise.mmp.in @@ -57,4 +57,15 @@ SOURCEPATH ..\..\..\..\engines\cruise USERINCLUDE ..\..\..\..\engines USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\audio ..\src -SYSTEMINCLUDE \epoc32\include \epoc32\include\libc ..\src + +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png +SYSTEMINCLUDE \epoc32\include\ESDL +SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version +SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor +SYSTEMINCLUDE \epoc32\include +SYSTEMINCLUDE ..\src // for portdefs.h diff --git a/backends/platform/symbian/mmp/scummvm_draci.mmp.in b/backends/platform/symbian/mmp/scummvm_draci.mmp.in index 52f862bc6f..fe899a91ff 100644 --- a/backends/platform/symbian/mmp/scummvm_draci.mmp.in +++ b/backends/platform/symbian/mmp/scummvm_draci.mmp.in @@ -57,5 +57,15 @@ SOURCEPATH ..\..\..\..\engines\draci USERINCLUDE ..\..\..\..\engines USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\audio ..\src + +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png +SYSTEMINCLUDE \epoc32\include\ESDL SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version -SYSTEMINCLUDE \epoc32\include \epoc32\include\libc ..\src +SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor +SYSTEMINCLUDE \epoc32\include +SYSTEMINCLUDE ..\src // for portdefs.h diff --git a/backends/platform/symbian/mmp/scummvm_drascula.mmp.in b/backends/platform/symbian/mmp/scummvm_drascula.mmp.in index 9ea02fefe8..8f532d4498 100644 --- a/backends/platform/symbian/mmp/scummvm_drascula.mmp.in +++ b/backends/platform/symbian/mmp/scummvm_drascula.mmp.in @@ -57,4 +57,15 @@ SOURCEPATH ..\..\..\..\engines\drascula USERINCLUDE ..\..\..\..\engines USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\audio ..\src -SYSTEMINCLUDE \epoc32\include \epoc32\include\libc ..\src + +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png +SYSTEMINCLUDE \epoc32\include\ESDL +SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version +SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor +SYSTEMINCLUDE \epoc32\include +SYSTEMINCLUDE ..\src // for portdefs.h diff --git a/backends/platform/symbian/mmp/scummvm_dreamweb.mmp.in b/backends/platform/symbian/mmp/scummvm_dreamweb.mmp.in new file mode 100644 index 0000000000..89ffd23ebd --- /dev/null +++ b/backends/platform/symbian/mmp/scummvm_dreamweb.mmp.in @@ -0,0 +1,72 @@ +/* ScummVM - Graphic Adventure Engine + * Copyright (C) 2003-2005 Andreas 'Sprawl' Karlsson - Original EPOC port, ESDL + * Copyright (C) 2003-2005 Lars 'AnotherGuest' Persson - Original EPOC port, Audio System + * Copyright (C) 2005 Jurgen 'SumthinWicked' Braam - EPOC/CVS maintainer + * Copyright (C) 2005-2013 The ScummVM project + * Copyright (C) 2013 Strizniou Fedor + * + * ScummVM is the legal property of its developers, whose names + * are too numerous to list here. Please refer to the COPYRIGHT + * file distributed with this source distribution. + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + */ + +// +// EPOC MMP makefile project for ScummVM +// + +// *** Definitions + +TARGET scummvm_dreamweb.lib +TARGETTYPE lib +OPTION MSVC /QIfist /Ob1 /Oy /GF // /QIfist disables use of __ftol2 to avoid linker probs with MS libc: http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vccore/html/vcrefQIfistSuppress_ftol.asp +OPTION GCC -Wno-multichar -Wno-reorder // don't optimize for ARM, platform way too sensitive for that :( just turn off some common warnings +OPTION GCCE -Wno-multichar -Wno-reorder -Wno-unused -Wno-format -fsigned-char +ALWAYS_BUILD_AS_ARM + +//START_AUTO_MACROS_SLAVE// + + // empty base file, will be updated by Perl build scripts + +//STOP_AUTO_MACROS_SLAVE// + +// *** SOURCE files + +SOURCEPATH ..\..\..\..\engines\dreamweb + +//START_AUTO_OBJECTS_DREAMWEB_// + + // empty base file, will be updated by Perl build scripts + +//STOP_AUTO_OBJECTS_DREAMWEB_// + +// *** Include paths + +USERINCLUDE ..\..\..\..\engines +USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\audio ..\src + +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png +SYSTEMINCLUDE \epoc32\include\ESDL +SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version +SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor +SYSTEMINCLUDE \epoc32\include +SYSTEMINCLUDE ..\src // for portdefs.h diff --git a/backends/platform/symbian/mmp/scummvm_fullpipe.mmp.in b/backends/platform/symbian/mmp/scummvm_fullpipe.mmp.in new file mode 100644 index 0000000000..7612ad2bae --- /dev/null +++ b/backends/platform/symbian/mmp/scummvm_fullpipe.mmp.in @@ -0,0 +1,72 @@ +/* ScummVM - Graphic Adventure Engine + * Copyright (C) 2003-2005 Andreas 'Sprawl' Karlsson - Original EPOC port, ESDL + * Copyright (C) 2003-2005 Lars 'AnotherGuest' Persson - Original EPOC port, Audio System + * Copyright (C) 2005 Jurgen 'SumthinWicked' Braam - EPOC/CVS maintainer + * Copyright (C) 2005-2013 The ScummVM project + * Copyright (C) 2013 Strizniou Fedor + * + * ScummVM is the legal property of its developers, whose names + * are too numerous to list here. Please refer to the COPYRIGHT + * file distributed with this source distribution. + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + */ + +// +// EPOC MMP makefile project for ScummVM +// + +// *** Definitions + +TARGET scummvm_fullpipe.lib +TARGETTYPE lib +OPTION MSVC /QIfist /Ob1 /Oy /GF // /QIfist disables use of __ftol2 to avoid linker probs with MS libc: http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vccore/html/vcrefQIfistSuppress_ftol.asp +OPTION GCC -Wno-multichar -Wno-reorder // don't optimize for ARM, platform way too sensitive for that :( just turn off some common warnings +OPTION GCCE -Wno-multichar -Wno-reorder -Wno-unused -Wno-format -fsigned-char +ALWAYS_BUILD_AS_ARM + +//START_AUTO_MACROS_SLAVE// + + // empty base file, will be updated by Perl build scripts + +//STOP_AUTO_MACROS_SLAVE// + +// *** SOURCE files + +SOURCEPATH ..\..\..\..\engines\fullpipe + +//START_AUTO_OBJECTS_FULLPIPE_// + + // empty base file, will be updated by Perl build scripts + +//STOP_AUTO_OBJECTS_FULLPIPE_// + +// *** Include paths + +USERINCLUDE ..\..\..\..\engines +USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\audio ..\src + +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png +SYSTEMINCLUDE \epoc32\include\ESDL +SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version +SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor +SYSTEMINCLUDE \epoc32\include +SYSTEMINCLUDE ..\src // for portdefs.h diff --git a/backends/platform/symbian/mmp/scummvm_gob.mmp.in b/backends/platform/symbian/mmp/scummvm_gob.mmp.in index 906d54b487..884b06c61a 100644 --- a/backends/platform/symbian/mmp/scummvm_gob.mmp.in +++ b/backends/platform/symbian/mmp/scummvm_gob.mmp.in @@ -57,4 +57,15 @@ SOURCEPATH ..\..\..\..\engines\gob USERINCLUDE ..\..\..\..\engines USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\audio ..\src -SYSTEMINCLUDE \epoc32\include \epoc32\include\libc ..\src + +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png +SYSTEMINCLUDE \epoc32\include\ESDL +SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version +SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor +SYSTEMINCLUDE \epoc32\include +SYSTEMINCLUDE ..\src // for portdefs.h diff --git a/backends/platform/symbian/mmp/scummvm_groovie.mmp.in b/backends/platform/symbian/mmp/scummvm_groovie.mmp.in index e7f70bc110..53fb33fef0 100644 --- a/backends/platform/symbian/mmp/scummvm_groovie.mmp.in +++ b/backends/platform/symbian/mmp/scummvm_groovie.mmp.in @@ -52,10 +52,21 @@ SOURCEPATH ..\..\..\..\engines\groovie // empty base file, will be updated by Perl build scripts //STOP_AUTO_OBJECTS_GROOVIE_// +SOURCE roq.cpp // *** Include paths USERINCLUDE ..\..\..\..\engines USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\audio ..\src + +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png +SYSTEMINCLUDE \epoc32\include\ESDL SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version -SYSTEMINCLUDE \epoc32\include \epoc32\include\libc ..\src +SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor +SYSTEMINCLUDE \epoc32\include +SYSTEMINCLUDE ..\src // for portdefs.h diff --git a/backends/platform/symbian/mmp/scummvm_hopkins.mmp.in b/backends/platform/symbian/mmp/scummvm_hopkins.mmp.in index 4509026b6c..bafc11e65f 100644 --- a/backends/platform/symbian/mmp/scummvm_hopkins.mmp.in +++ b/backends/platform/symbian/mmp/scummvm_hopkins.mmp.in @@ -57,5 +57,15 @@ SOURCEPATH ..\..\..\..\engines\HOPKINS USERINCLUDE ..\..\..\..\engines USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\audio ..\src + +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png +SYSTEMINCLUDE \epoc32\include\ESDL SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version -SYSTEMINCLUDE \epoc32\include \epoc32\include\libc ..\src +SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor +SYSTEMINCLUDE \epoc32\include +SYSTEMINCLUDE ..\src // for portdefs.h
\ No newline at end of file diff --git a/backends/platform/symbian/mmp/scummvm_hugo.mmp.in b/backends/platform/symbian/mmp/scummvm_hugo.mmp.in index 13dd7efa1e..58622a83fd 100644 --- a/backends/platform/symbian/mmp/scummvm_hugo.mmp.in +++ b/backends/platform/symbian/mmp/scummvm_hugo.mmp.in @@ -57,5 +57,15 @@ SOURCEPATH ..\..\..\..\engines\hugo USERINCLUDE ..\..\..\..\engines USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\audio ..\src + +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png +SYSTEMINCLUDE \epoc32\include\ESDL SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version -SYSTEMINCLUDE \epoc32\include \epoc32\include\libc ..\src +SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor +SYSTEMINCLUDE \epoc32\include +SYSTEMINCLUDE ..\src // for portdefs.h
\ No newline at end of file diff --git a/backends/platform/symbian/mmp/scummvm_kyra.mmp.in b/backends/platform/symbian/mmp/scummvm_kyra.mmp.in index 5772bfaad0..3fa05e856d 100644 --- a/backends/platform/symbian/mmp/scummvm_kyra.mmp.in +++ b/backends/platform/symbian/mmp/scummvm_kyra.mmp.in @@ -59,8 +59,26 @@ SOURCEPATH ..\..\..\..\engines\kyra //STOP_AUTO_OBJECTS_KYRA_ENABLE_LOL// + +//START_AUTO_OBJECTS_KYRA_ENABLE_EOB// + + // empty base file, will be updated by Perl build scripts + +//STOP_AUTO_OBJECTS_KYRA_ENABLE_EOB// + // *** Include paths USERINCLUDE ..\..\..\..\engines USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\audio ..\src -SYSTEMINCLUDE \epoc32\include \epoc32\include\libc ..\src + +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png +SYSTEMINCLUDE \epoc32\include\ESDL +SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version +SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor +SYSTEMINCLUDE \epoc32\include +SYSTEMINCLUDE ..\src // for portdefs.h diff --git a/backends/platform/symbian/mmp/scummvm_lastexpress.mmp.in b/backends/platform/symbian/mmp/scummvm_lastexpress.mmp.in index b8db95ea0c..8e0b3026c7 100644 --- a/backends/platform/symbian/mmp/scummvm_lastexpress.mmp.in +++ b/backends/platform/symbian/mmp/scummvm_lastexpress.mmp.in @@ -57,5 +57,15 @@ SOURCEPATH ..\..\..\..\engines\lastexpress USERINCLUDE ..\..\..\..\engines USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\audio ..\src + +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png +SYSTEMINCLUDE \epoc32\include\ESDL SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version -SYSTEMINCLUDE \epoc32\include \epoc32\include\libc ..\src +SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor +SYSTEMINCLUDE \epoc32\include +SYSTEMINCLUDE ..\src // for portdefs.h diff --git a/backends/platform/symbian/mmp/scummvm_lure.mmp.in b/backends/platform/symbian/mmp/scummvm_lure.mmp.in index 84c3eecd5e..89c93d058d 100644 --- a/backends/platform/symbian/mmp/scummvm_lure.mmp.in +++ b/backends/platform/symbian/mmp/scummvm_lure.mmp.in @@ -57,4 +57,15 @@ SOURCEPATH ..\..\..\..\engines\lure USERINCLUDE ..\..\..\..\engines USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\audio ..\src -SYSTEMINCLUDE \epoc32\include \epoc32\include\libc ..\src + +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png +SYSTEMINCLUDE \epoc32\include\ESDL +SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version +SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor +SYSTEMINCLUDE \epoc32\include +SYSTEMINCLUDE ..\src // for portdefs.h diff --git a/backends/platform/symbian/mmp/scummvm_m4.mmp.in b/backends/platform/symbian/mmp/scummvm_m4.mmp.in index e69b40ceb0..b3024c93c3 100644 --- a/backends/platform/symbian/mmp/scummvm_m4.mmp.in +++ b/backends/platform/symbian/mmp/scummvm_m4.mmp.in @@ -57,5 +57,15 @@ SOURCEPATH ..\..\..\..\engines\m4 USERINCLUDE ..\..\..\..\engines USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\audio ..\src + +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png +SYSTEMINCLUDE \epoc32\include\ESDL SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version -SYSTEMINCLUDE \epoc32\include \epoc32\include\libc ..\src +SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor +SYSTEMINCLUDE \epoc32\include +SYSTEMINCLUDE ..\src // for portdefs.h diff --git a/backends/platform/symbian/mmp/scummvm_made.mmp.in b/backends/platform/symbian/mmp/scummvm_made.mmp.in index b52d9cc6cb..d4a63f8d87 100644 --- a/backends/platform/symbian/mmp/scummvm_made.mmp.in +++ b/backends/platform/symbian/mmp/scummvm_made.mmp.in @@ -57,5 +57,16 @@ SOURCEPATH ..\..\..\..\engines\made USERINCLUDE ..\..\..\..\engines USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\audio ..\src + +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png +SYSTEMINCLUDE \epoc32\include\ESDL SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version -SYSTEMINCLUDE \epoc32\include \epoc32\include\libc ..\src +SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor +SYSTEMINCLUDE \epoc32\include +SYSTEMINCLUDE ..\src // for portdefs.h + diff --git a/backends/platform/symbian/mmp/scummvm_mads.mmp.in b/backends/platform/symbian/mmp/scummvm_mads.mmp.in new file mode 100644 index 0000000000..d0d6091f83 --- /dev/null +++ b/backends/platform/symbian/mmp/scummvm_mads.mmp.in @@ -0,0 +1,72 @@ +/* ScummVM - Graphic Adventure Engine + * Copyright (C) 2003-2005 Andreas 'Sprawl' Karlsson - Original EPOC port, ESDL + * Copyright (C) 2003-2005 Lars 'AnotherGuest' Persson - Original EPOC port, Audio System + * Copyright (C) 2005 Jurgen 'SumthinWicked' Braam - EPOC/CVS maintainer + * Copyright (C) 2005-2013 The ScummVM project + * Copyright (C) 2014 Fedor Strizhniou - Epoc project file + * + * ScummVM is the legal property of its developers, whose names + * are too numerous to list here. Please refer to the COPYRIGHT + * file distributed with this source distribution. + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + */ + +// +// EPOC MMP makefile project for ScummVM +// + +// *** Definitions + +TARGET scummvm_mads.lib +TARGETTYPE lib +OPTION MSVC /QIfist /Ob1 /Oy /GF // /QIfist disables use of __ftol2 to avoid linker probs with MS libc: http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vccore/html/vcrefQIfistSuppress_ftol.asp +OPTION GCC -Wno-multichar -Wno-reorder // don't optimize for ARM, platform way too sensitive for that :( just turn off some common warnings +OPTION GCCE -Wno-multichar -Wno-reorder -Wno-unused -Wno-format -fsigned-char +ALWAYS_BUILD_AS_ARM + +//START_AUTO_MACROS_SLAVE// + + // empty base file, will be updated by Perl build scripts + +//STOP_AUTO_MACROS_SLAVE// + +// *** SOURCE files + +SOURCEPATH ..\..\..\..\engines\mads + +//START_AUTO_OBJECTS_MADS_// + + // empty base file, will be updated by Perl build scripts + +//STOP_AUTO_OBJECTS_MADS_// + +// *** Include paths + +USERINCLUDE ..\..\..\..\engines +USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\audio ..\src + +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png +SYSTEMINCLUDE \epoc32\include\ESDL +SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version +SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor +SYSTEMINCLUDE \epoc32\include +SYSTEMINCLUDE ..\src // for portdefs.h diff --git a/backends/platform/symbian/mmp/scummvm_mohawk.mmp.in b/backends/platform/symbian/mmp/scummvm_mohawk.mmp.in index 5f7bd4e144..e9175593ec 100644 --- a/backends/platform/symbian/mmp/scummvm_mohawk.mmp.in +++ b/backends/platform/symbian/mmp/scummvm_mohawk.mmp.in @@ -53,9 +53,38 @@ SOURCEPATH ..\..\..\..\engines\mohawk //STOP_AUTO_OBJECTS_MOHAWK_// + +//START_AUTO_OBJECTS_MOHAWK_ENABLE_MYST// + + // empty base file, will be updated by Perl build scripts + +//STOP_AUTO_OBJECTS_MOHAWK_ENABLE_MYST// + +//START_AUTO_OBJECTS_MOHAWK_ENABLE_RIVEN// + + // empty base file, will be updated by Perl build scripts + +//STOP_AUTO_OBJECTS_MOHAWK_ENABLE_RIVEN// + +//START_AUTO_OBJECTS_MOHAWK_ENABLE_CSTIME// + + // empty base file, will be updated by Perl build scripts + +//STOP_AUTO_OBJECTS_MOHAWK_ENABLE_CSTIME// + // *** Include paths USERINCLUDE ..\..\..\..\engines USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\audio ..\src + +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png +SYSTEMINCLUDE \epoc32\include\ESDL SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version -SYSTEMINCLUDE \epoc32\include \epoc32\include\libc ..\src +SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor +SYSTEMINCLUDE \epoc32\include +SYSTEMINCLUDE ..\src // for portdefs.h diff --git a/backends/platform/symbian/mmp/scummvm_mortevielle.mmp.in b/backends/platform/symbian/mmp/scummvm_mortevielle.mmp.in new file mode 100644 index 0000000000..f118ddbef0 --- /dev/null +++ b/backends/platform/symbian/mmp/scummvm_mortevielle.mmp.in @@ -0,0 +1,72 @@ +/* ScummVM - Graphic Adventure Engine + * Copyright (C) 2003-2005 Andreas 'Sprawl' Karlsson - Original EPOC port, ESDL + * Copyright (C) 2003-2005 Lars 'AnotherGuest' Persson - Original EPOC port, Audio System + * Copyright (C) 2005 Jurgen 'SumthinWicked' Braam - EPOC/CVS maintainer + * Copyright (C) 2005-2013 The ScummVM project + * Copyright (C) 2013 Strizniou Fedor + * + * ScummVM is the legal property of its developers, whose names + * are too numerous to list here. Please refer to the COPYRIGHT + * file distributed with this source distribution. + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + */ + +// +// EPOC MMP makefile project for ScummVM +// + +// *** Definitions + +TARGET scummvm_mortevielle.lib +TARGETTYPE lib +OPTION MSVC /QIfist /Ob1 /Oy /GF // /QIfist disables use of __ftol2 to avoid linker probs with MS libc: http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vccore/html/vcrefQIfistSuppress_ftol.asp +OPTION GCC -Wno-multichar -Wno-reorder // don't optimize for ARM, platform way too sensitive for that :( just turn off some common warnings +OPTION GCCE -Wno-multichar -Wno-reorder -Wno-unused -Wno-format -fsigned-char +ALWAYS_BUILD_AS_ARM + +//START_AUTO_MACROS_SLAVE// + + // empty base file, will be updated by Perl build scripts + +//STOP_AUTO_MACROS_SLAVE// + +// *** SOURCE files + +SOURCEPATH ..\..\..\..\engines\mortevielle + +//START_AUTO_OBJECTS_MORTEVIELLE_// + + // empty base file, will be updated by Perl build scripts + +//STOP_AUTO_OBJECTS_MORTEVIELLE_// + +// *** Include paths + +USERINCLUDE ..\..\..\..\engines +USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\audio ..\src + +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png +SYSTEMINCLUDE \epoc32\include\ESDL +SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version +SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor +SYSTEMINCLUDE \epoc32\include +SYSTEMINCLUDE ..\src // for portdefs.h diff --git a/backends/platform/symbian/mmp/scummvm_neverhood.mmp.in b/backends/platform/symbian/mmp/scummvm_neverhood.mmp.in new file mode 100644 index 0000000000..a57161577f --- /dev/null +++ b/backends/platform/symbian/mmp/scummvm_neverhood.mmp.in @@ -0,0 +1,71 @@ +/* ScummVM - Graphic Adventure Engine + * Copyright (C) 2003-2005 Andreas 'Sprawl' Karlsson - Original EPOC port, ESDL + * Copyright (C) 2003-2005 Lars 'AnotherGuest' Persson - Original EPOC port, Audio System + * Copyright (C) 2005 Jurgen 'SumthinWicked' Braam - EPOC/CVS maintainer + * Copyright (C) 2005-2013 The ScummVM project + * + * ScummVM is the legal property of its developers, whose names + * are too numerous to list here. Please refer to the COPYRIGHT + * file distributed with this source distribution. + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + */ + +// +// EPOC MMP makefile project for ScummVM +// + +// *** Definitions + +TARGET scummvm_neverhood.lib +TARGETTYPE lib +OPTION MSVC /QIfist /Ob1 /Oy /GF // /QIfist disables use of __ftol2 to avoid linker probs with MS libc: http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vccore/html/vcrefQIfistSuppress_ftol.asp +OPTION GCC -Wno-multichar -Wno-reorder // don't optimize for ARM, platform way too sensitive for that :( just turn off some common warnings +OPTION GCCE -Wno-multichar -Wno-reorder -Wno-unused -Wno-format -fsigned-char +ALWAYS_BUILD_AS_ARM + +//START_AUTO_MACROS_SLAVE// + + // empty base file, will be updated by Perl build scripts + +//STOP_AUTO_MACROS_SLAVE// + +// *** SOURCE files + +SOURCEPATH ..\..\..\..\engines\neverhood + +//START_AUTO_OBJECTS_NEVERHOOD_// + + // empty base file, will be updated by Perl build scripts + +//STOP_AUTO_OBJECTS_NEVERHOOD_// + +// *** Include paths + +USERINCLUDE ..\..\..\..\engines +USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\audio ..\src + +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png +SYSTEMINCLUDE \epoc32\include\ESDL +SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version +SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor +SYSTEMINCLUDE \epoc32\include +SYSTEMINCLUDE ..\src // for portdefs.h diff --git a/backends/platform/symbian/mmp/scummvm_parallaction.mmp.in b/backends/platform/symbian/mmp/scummvm_parallaction.mmp.in index f8ee389577..cefdd1b282 100644 --- a/backends/platform/symbian/mmp/scummvm_parallaction.mmp.in +++ b/backends/platform/symbian/mmp/scummvm_parallaction.mmp.in @@ -57,5 +57,15 @@ SOURCEPATH ..\..\..\..\engines\parallaction USERINCLUDE ..\..\..\..\engines USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\audio ..\src + +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png +SYSTEMINCLUDE \epoc32\include\ESDL SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version -SYSTEMINCLUDE \epoc32\include \epoc32\include\libc ..\src +SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor +SYSTEMINCLUDE \epoc32\include +SYSTEMINCLUDE ..\src // for portdefs.h diff --git a/backends/platform/symbian/mmp/scummvm_pegasus.mmp.in b/backends/platform/symbian/mmp/scummvm_pegasus.mmp.in index fefc63e936..68b2c12774 100644 --- a/backends/platform/symbian/mmp/scummvm_pegasus.mmp.in +++ b/backends/platform/symbian/mmp/scummvm_pegasus.mmp.in @@ -57,5 +57,15 @@ SOURCEPATH ..\..\..\..\engines\PEGASUS USERINCLUDE ..\..\..\..\engines USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\audio ..\src + +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png +SYSTEMINCLUDE \epoc32\include\ESDL SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version -SYSTEMINCLUDE \epoc32\include \epoc32\include\libc ..\src +SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor +SYSTEMINCLUDE \epoc32\include +SYSTEMINCLUDE ..\src // for portdefs.h
\ No newline at end of file diff --git a/backends/platform/symbian/mmp/scummvm_queen.mmp.in b/backends/platform/symbian/mmp/scummvm_queen.mmp.in index f507f482f9..94835aae90 100644 --- a/backends/platform/symbian/mmp/scummvm_queen.mmp.in +++ b/backends/platform/symbian/mmp/scummvm_queen.mmp.in @@ -57,4 +57,15 @@ SOURCEPATH ..\..\..\..\engines\queen USERINCLUDE ..\..\..\..\engines USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\audio ..\src -SYSTEMINCLUDE \epoc32\include \epoc32\include\libc ..\src + +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png +SYSTEMINCLUDE \epoc32\include\ESDL +SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version +SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor +SYSTEMINCLUDE \epoc32\include +SYSTEMINCLUDE ..\src // for portdefs.h diff --git a/backends/platform/symbian/mmp/scummvm_saga.mmp.in b/backends/platform/symbian/mmp/scummvm_saga.mmp.in index cd158556dc..77bf839efe 100644 --- a/backends/platform/symbian/mmp/scummvm_saga.mmp.in +++ b/backends/platform/symbian/mmp/scummvm_saga.mmp.in @@ -69,4 +69,15 @@ SOURCEPATH ..\..\..\..\engines\saga USERINCLUDE ..\..\..\..\engines USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\audio ..\src -SYSTEMINCLUDE \epoc32\include \epoc32\include\libc ..\src + +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png +SYSTEMINCLUDE \epoc32\include\ESDL +SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version +SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor +SYSTEMINCLUDE \epoc32\include +SYSTEMINCLUDE ..\src // for portdefs.h diff --git a/backends/platform/symbian/mmp/scummvm_sci.mmp.in b/backends/platform/symbian/mmp/scummvm_sci.mmp.in index 5749c66e10..d08501e471 100644 --- a/backends/platform/symbian/mmp/scummvm_sci.mmp.in +++ b/backends/platform/symbian/mmp/scummvm_sci.mmp.in @@ -53,9 +53,27 @@ SOURCEPATH ..\..\..\..\engines\sci //STOP_AUTO_OBJECTS_SCI_// + +//START_AUTO_OBJECTS_SCI_ENABLE_SCI32// + + // empty base file, will be updated by Perl build scripts + +//STOP_AUTO_OBJECTS_SCI_ENABLE_SCI32// + + // *** Include paths USERINCLUDE ..\..\..\..\engines USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\audio ..\src + +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png +SYSTEMINCLUDE \epoc32\include\ESDL SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version -SYSTEMINCLUDE \epoc32\include \epoc32\include\libc ..\src +SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor +SYSTEMINCLUDE \epoc32\include +SYSTEMINCLUDE ..\src // for portdefs.h diff --git a/backends/platform/symbian/mmp/scummvm_scumm.mmp.in b/backends/platform/symbian/mmp/scummvm_scumm.mmp.in index c07725e002..a11dd071d3 100644 --- a/backends/platform/symbian/mmp/scummvm_scumm.mmp.in +++ b/backends/platform/symbian/mmp/scummvm_scumm.mmp.in @@ -81,7 +81,14 @@ SOURCE smush/codec47ARM.s // ARM version: add ASM routines USERINCLUDE ..\..\..\..\engines ..\..\..\..\engines\scumm\smush ..\..\..\..\engines\scumm\insane USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\audio ..\src +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png +SYSTEMINCLUDE \epoc32\include\ESDL SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor SYSTEMINCLUDE \epoc32\include SYSTEMINCLUDE ..\src // for portdefs.h diff --git a/backends/platform/symbian/mmp/scummvm_sky.mmp.in b/backends/platform/symbian/mmp/scummvm_sky.mmp.in index b5048106dc..37fdc89f99 100644 --- a/backends/platform/symbian/mmp/scummvm_sky.mmp.in +++ b/backends/platform/symbian/mmp/scummvm_sky.mmp.in @@ -57,4 +57,15 @@ SOURCEPATH ..\..\..\..\engines\sky USERINCLUDE ..\..\..\..\engines ..\..\..\..\engines\sky\music USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\audio ..\src -SYSTEMINCLUDE \epoc32\include \epoc32\include\libc ..\src + +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png +SYSTEMINCLUDE \epoc32\include\ESDL +SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version +SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor +SYSTEMINCLUDE \epoc32\include +SYSTEMINCLUDE ..\src // for portdefs.h diff --git a/backends/platform/symbian/mmp/scummvm_sword1.mmp.in b/backends/platform/symbian/mmp/scummvm_sword1.mmp.in index 578839e8c4..352cbe59f0 100644 --- a/backends/platform/symbian/mmp/scummvm_sword1.mmp.in +++ b/backends/platform/symbian/mmp/scummvm_sword1.mmp.in @@ -57,4 +57,15 @@ SOURCEPATH ..\..\..\..\engines\sword1 USERINCLUDE ..\..\..\..\engines USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\audio ..\src -SYSTEMINCLUDE \epoc32\include \epoc32\include\libc ..\src + +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png +SYSTEMINCLUDE \epoc32\include\ESDL +SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version +SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor +SYSTEMINCLUDE \epoc32\include +SYSTEMINCLUDE ..\src // for portdefs.h diff --git a/backends/platform/symbian/mmp/scummvm_sword2.mmp.in b/backends/platform/symbian/mmp/scummvm_sword2.mmp.in index 23a055c99c..7b79bf7f5c 100644 --- a/backends/platform/symbian/mmp/scummvm_sword2.mmp.in +++ b/backends/platform/symbian/mmp/scummvm_sword2.mmp.in @@ -57,4 +57,15 @@ SOURCEPATH ..\..\..\..\engines\sword2 USERINCLUDE ..\..\..\..\engines USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\audio ..\src -SYSTEMINCLUDE \epoc32\include \epoc32\include\libc ..\src + +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png +SYSTEMINCLUDE \epoc32\include\ESDL +SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version +SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor +SYSTEMINCLUDE \epoc32\include +SYSTEMINCLUDE ..\src // for portdefs.h diff --git a/backends/platform/symbian/mmp/scummvm_sword25.mmp.in b/backends/platform/symbian/mmp/scummvm_sword25.mmp.in new file mode 100644 index 0000000000..4159350bce --- /dev/null +++ b/backends/platform/symbian/mmp/scummvm_sword25.mmp.in @@ -0,0 +1,73 @@ +/* ScummVM - Graphic Adventure Engine + * Copyright (C) 2003-2005 Andreas 'Sprawl' Karlsson - Original EPOC port, ESDL + * Copyright (C) 2003-2005 Lars 'AnotherGuest' Persson - Original EPOC port, Audio System + * Copyright (C) 2005 Jurgen 'SumthinWicked' Braam - EPOC/CVS maintainer + * Copyright (C) 2005-2013 The ScummVM project + * Copyright (C) 2013 Strizniou Fedor + * + * ScummVM is the legal property of its developers, whose names + * are too numerous to list here. Please refer to the COPYRIGHT + * file distributed with this source distribution. + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + */ + +// +// EPOC MMP makefile project for ScummVM +// + +// *** Definitions + +TARGET scummvm_sword25.lib +TARGETTYPE lib +OPTION MSVC /QIfist /Ob1 /Oy /GF // /QIfist disables use of __ftol2 to avoid linker probs with MS libc: http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vccore/html/vcrefQIfistSuppress_ftol.asp +OPTION GCC -Wno-multichar -Wno-reorder // don't optimize for ARM, platform way too sensitive for that :( just turn off some common warnings +OPTION GCCE -Wno-multichar -Wno-reorder -Wno-unused -Wno-format -fsigned-char +ALWAYS_BUILD_AS_ARM + +//START_AUTO_MACROS_SLAVE// + + // empty base file, will be updated by Perl build scripts + +//STOP_AUTO_MACROS_SLAVE// + +// *** SOURCE files + +SOURCEPATH ..\..\..\..\engines\sword25 + +//START_AUTO_OBJECTS_SWORD25_// + + // empty base file, will be updated by Perl build scripts + +//STOP_AUTO_OBJECTS_SWORD25_// + +// *** Include paths + +USERINCLUDE ..\..\..\..\engines +USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\audio ..\src +USERINCLUDE ..\..\..\..\engines\sword25\util\lua ..\..\..\..\engines\sword25\util\pluto + +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png +SYSTEMINCLUDE \epoc32\include\ESDL +SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version +SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor +SYSTEMINCLUDE \epoc32\include +SYSTEMINCLUDE ..\src // for portdefs.h diff --git a/backends/platform/symbian/mmp/scummvm_teenagent.mmp.in b/backends/platform/symbian/mmp/scummvm_teenagent.mmp.in index 58bfa4c337..332b9f20ac 100644 --- a/backends/platform/symbian/mmp/scummvm_teenagent.mmp.in +++ b/backends/platform/symbian/mmp/scummvm_teenagent.mmp.in @@ -57,5 +57,15 @@ SOURCEPATH ..\..\..\..\engines\teenagent USERINCLUDE ..\..\..\..\engines USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\audio ..\src + +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png +SYSTEMINCLUDE \epoc32\include\ESDL SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version -SYSTEMINCLUDE \epoc32\include \epoc32\include\libc ..\src +SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor +SYSTEMINCLUDE \epoc32\include +SYSTEMINCLUDE ..\src // for portdefs.h diff --git a/backends/platform/symbian/mmp/scummvm_testbed.mmp.in b/backends/platform/symbian/mmp/scummvm_testbed.mmp.in new file mode 100644 index 0000000000..20d3789a31 --- /dev/null +++ b/backends/platform/symbian/mmp/scummvm_testbed.mmp.in @@ -0,0 +1,72 @@ +/* ScummVM - Graphic Adventure Engine + * Copyright (C) 2003-2005 Andreas 'Sprawl' Karlsson - Original EPOC port, ESDL + * Copyright (C) 2003-2005 Lars 'AnotherGuest' Persson - Original EPOC port, Audio System + * Copyright (C) 2005 Jurgen 'SumthinWicked' Braam - EPOC/CVS maintainer + * Copyright (C) 2005-2013 The ScummVM project + * Copyright (C) 2013 Strizniou Fedor + * + * ScummVM is the legal property of its developers, whose names + * are too numerous to list here. Please refer to the COPYRIGHT + * file distributed with this source distribution. + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + */ + +// +// EPOC MMP makefile project for ScummVM +// + +// *** Definitions + +TARGET scummvm_testbed.lib +TARGETTYPE lib +OPTION MSVC /QIfist /Ob1 /Oy /GF // /QIfist disables use of __ftol2 to avoid linker probs with MS libc: http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vccore/html/vcrefQIfistSuppress_ftol.asp +OPTION GCC -Wno-multichar -Wno-reorder // don't optimize for ARM, platform way too sensitive for that :( just turn off some common warnings +OPTION GCCE -Wno-multichar -Wno-reorder -Wno-unused -Wno-format -fsigned-char +ALWAYS_BUILD_AS_ARM + +//START_AUTO_MACROS_SLAVE// + + // empty base file, will be updated by Perl build scripts + +//STOP_AUTO_MACROS_SLAVE// + +// *** SOURCE files + +SOURCEPATH ..\..\..\..\engines\testbed + +//START_AUTO_OBJECTS_TESTBED_// + + // empty base file, will be updated by Perl build scripts + +//STOP_AUTO_OBJECTS_TESTBED_// + +// *** Include paths + +USERINCLUDE ..\..\..\..\engines +USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\audio ..\src + +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png +SYSTEMINCLUDE \epoc32\include\ESDL +SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version +SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor +SYSTEMINCLUDE \epoc32\include +SYSTEMINCLUDE ..\src // for portdefs.h diff --git a/backends/platform/symbian/mmp/scummvm_tinsel.mmp.in b/backends/platform/symbian/mmp/scummvm_tinsel.mmp.in index 4cdd0bd774..15c5850cee 100644 --- a/backends/platform/symbian/mmp/scummvm_tinsel.mmp.in +++ b/backends/platform/symbian/mmp/scummvm_tinsel.mmp.in @@ -57,4 +57,15 @@ SOURCEPATH ..\..\..\..\engines\tinsel USERINCLUDE ..\..\..\..\engines USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\audio ..\src -SYSTEMINCLUDE \epoc32\include \epoc32\include\libc ..\src + +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png +SYSTEMINCLUDE \epoc32\include\ESDL +SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version +SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor +SYSTEMINCLUDE \epoc32\include +SYSTEMINCLUDE ..\src // for portdefs.h
\ No newline at end of file diff --git a/backends/platform/symbian/mmp/scummvm_toltecs.mmp.in b/backends/platform/symbian/mmp/scummvm_toltecs.mmp.in index 9f9d1c1dda..df75290d81 100644 --- a/backends/platform/symbian/mmp/scummvm_toltecs.mmp.in +++ b/backends/platform/symbian/mmp/scummvm_toltecs.mmp.in @@ -57,5 +57,15 @@ SOURCEPATH ..\..\..\..\engines\TOLTECS USERINCLUDE ..\..\..\..\engines USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\audio ..\src + +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png +SYSTEMINCLUDE \epoc32\include\ESDL SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version -SYSTEMINCLUDE \epoc32\include \epoc32\include\libc ..\src +SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor +SYSTEMINCLUDE \epoc32\include +SYSTEMINCLUDE ..\src // for portdefs.h diff --git a/backends/platform/symbian/mmp/scummvm_tony.mmp.in b/backends/platform/symbian/mmp/scummvm_tony.mmp.in index d80d82a9c5..bcdbc1c979 100644 --- a/backends/platform/symbian/mmp/scummvm_tony.mmp.in +++ b/backends/platform/symbian/mmp/scummvm_tony.mmp.in @@ -57,5 +57,15 @@ SOURCEPATH ..\..\..\..\engines\TONY USERINCLUDE ..\..\..\..\engines USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\audio ..\src + +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png +SYSTEMINCLUDE \epoc32\include\ESDL SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version -SYSTEMINCLUDE \epoc32\include \epoc32\include\libc ..\src +SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor +SYSTEMINCLUDE \epoc32\include +SYSTEMINCLUDE ..\src // for portdefs.h diff --git a/backends/platform/symbian/mmp/scummvm_toon.mmp.in b/backends/platform/symbian/mmp/scummvm_toon.mmp.in index 00f84d2bec..7bfec38dc5 100644 --- a/backends/platform/symbian/mmp/scummvm_toon.mmp.in +++ b/backends/platform/symbian/mmp/scummvm_toon.mmp.in @@ -57,5 +57,15 @@ SOURCEPATH ..\..\..\..\engines\toon USERINCLUDE ..\..\..\..\engines USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\audio ..\src + +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png +SYSTEMINCLUDE \epoc32\include\ESDL SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version -SYSTEMINCLUDE \epoc32\include \epoc32\include\libc ..\src +SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor +SYSTEMINCLUDE \epoc32\include +SYSTEMINCLUDE ..\src // for portdefs.h diff --git a/backends/platform/symbian/mmp/scummvm_touche.mmp.in b/backends/platform/symbian/mmp/scummvm_touche.mmp.in index e59dd0cd00..407e275ae3 100644 --- a/backends/platform/symbian/mmp/scummvm_touche.mmp.in +++ b/backends/platform/symbian/mmp/scummvm_touche.mmp.in @@ -57,5 +57,15 @@ SOURCEPATH ..\..\..\..\engines\touche USERINCLUDE ..\..\..\..\engines USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\audio ..\src + +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png +SYSTEMINCLUDE \epoc32\include\ESDL SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version -SYSTEMINCLUDE \epoc32\include \epoc32\include\libc ..\src +SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor +SYSTEMINCLUDE \epoc32\include +SYSTEMINCLUDE ..\src // for portdefs.h diff --git a/backends/platform/symbian/mmp/scummvm_tsage.mmp.in b/backends/platform/symbian/mmp/scummvm_tsage.mmp.in index cd4aa158dc..c0705d7aad 100644 --- a/backends/platform/symbian/mmp/scummvm_tsage.mmp.in +++ b/backends/platform/symbian/mmp/scummvm_tsage.mmp.in @@ -34,7 +34,8 @@ TARGET scummvm_tsage.lib TARGETTYPE lib OPTION MSVC /QIfist /Ob1 /Oy /GF // /QIfist disables use of __ftol2 to avoid linker probs with MS libc: http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vccore/html/vcrefQIfistSuppress_ftol.asp OPTION GCC -Wno-multichar -Wno-reorder // don't optimize for ARM, platform way too sensitive for that :( just turn off some common warnings -OPTION GCCE -Wno-multichar -Wno-reorder -Wno-unused -Wno-format -fsigned-char +// -Wno-psabi turn off "note: the mangling of 'va_list' has changed in GCC 4.4" +OPTION GCCE -Wno-multichar -Wno-reorder -Wno-unused -Wno-format -fsigned-char -Wno-psabi ALWAYS_BUILD_AS_ARM //START_AUTO_MACROS_SLAVE// @@ -57,5 +58,15 @@ SOURCEPATH ..\..\..\..\engines\tsage USERINCLUDE ..\..\..\..\engines USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\audio ..\src + +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png +SYSTEMINCLUDE \epoc32\include\ESDL SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version -SYSTEMINCLUDE \epoc32\include \epoc32\include\libc ..\src +SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor +SYSTEMINCLUDE \epoc32\include +SYSTEMINCLUDE ..\src // for portdefs.h diff --git a/backends/platform/symbian/mmp/scummvm_tucker.mmp.in b/backends/platform/symbian/mmp/scummvm_tucker.mmp.in index 0ff8eb9920..c457dd4083 100644 --- a/backends/platform/symbian/mmp/scummvm_tucker.mmp.in +++ b/backends/platform/symbian/mmp/scummvm_tucker.mmp.in @@ -57,5 +57,15 @@ SOURCEPATH ..\..\..\..\engines\tucker USERINCLUDE ..\..\..\..\engines USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\audio ..\src + +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png +SYSTEMINCLUDE \epoc32\include\ESDL SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version -SYSTEMINCLUDE \epoc32\include \epoc32\include\libc ..\src +SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor +SYSTEMINCLUDE \epoc32\include +SYSTEMINCLUDE ..\src // for portdefs.h diff --git a/backends/platform/symbian/mmp/scummvm_voyeur.mmp.in b/backends/platform/symbian/mmp/scummvm_voyeur.mmp.in new file mode 100644 index 0000000000..86dc32b3f8 --- /dev/null +++ b/backends/platform/symbian/mmp/scummvm_voyeur.mmp.in @@ -0,0 +1,71 @@ +/* ScummVM - Graphic Adventure Engine + * Copyright (C) 2003-2005 Andreas 'Sprawl' Karlsson - Original EPOC port, ESDL + * Copyright (C) 2003-2005 Lars 'AnotherGuest' Persson - Original EPOC port, Audio System + * Copyright (C) 2005 Jurgen 'SumthinWicked' Braam - EPOC/CVS maintainer + * Copyright (C) 2005-2014 The ScummVM Team + * + * ScummVM is the legal property of its developers, whose names + * are too numerous to list here. Please refer to the COPYRIGHT + * file distributed with this source distribution. + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + */ + +// +// EPOC MMP makefile project for ScummVM +// + +// *** Definitions + +TARGET scummvm_voyeur.lib +TARGETTYPE lib +OPTION MSVC /QIfist /Ob1 /Oy /GF // /QIfist disables use of __ftol2 to avoid linker probs with MS libc: http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vccore/html/vcrefQIfistSuppress_ftol.asp +OPTION GCC -Wno-multichar -Wno-reorder // don't optimize for ARM, platform way too sensitive for that :( just turn off some common warnings +OPTION GCCE -Wno-multichar -Wno-reorder -Wno-unused -Wno-format -fsigned-char +ALWAYS_BUILD_AS_ARM + +//START_AUTO_MACROS_SLAVE// + +// empty base file, will be updated by Perl build scripts + +//STOP_AUTO_MACROS_SLAVE// + +// *** SOURCE files + +SOURCEPATH ..\..\..\..\engines\voyeur + +//START_AUTO_OBJECTS_VOYEUR_// + + // empty base file, will be updated by Perl build scripts + +//STOP_AUTO_OBJECTS_VOYEUR_// + +// *** Include paths + +USERINCLUDE ..\..\..\..\engines +USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\audio ..\src + +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png +SYSTEMINCLUDE \epoc32\include\ESDL +SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version +SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor +SYSTEMINCLUDE \epoc32\include +SYSTEMINCLUDE ..\src // for portdefs.h diff --git a/backends/platform/symbian/mmp/scummvm_wintermute.mmp.in b/backends/platform/symbian/mmp/scummvm_wintermute.mmp.in index ebe762fe36..63dd7d39d8 100644 --- a/backends/platform/symbian/mmp/scummvm_wintermute.mmp.in +++ b/backends/platform/symbian/mmp/scummvm_wintermute.mmp.in @@ -34,7 +34,8 @@ TARGET scummvm_wintermute.lib TARGETTYPE lib OPTION MSVC /QIfist /Ob1 /Oy /GF // /QIfist disables use of __ftol2 to avoid linker probs with MS libc: http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vccore/html/vcrefQIfistSuppress_ftol.asp OPTION GCC -Wno-multichar -Wno-reorder // don't optimize for ARM, platform way too sensitive for that :( just turn off some common warnings -OPTION GCCE -Wno-multichar -Wno-reorder -Wno-unused -Wno-format -fsigned-char +// -Wno-psabi turn off "note: the mangling of 'va_list' has changed in GCC 4.4" +OPTION GCCE -Wno-multichar -Wno-reorder -Wno-unused -Wno-format -fsigned-char -Wno-psabi ALWAYS_BUILD_AS_ARM //START_AUTO_MACROS_SLAVE// @@ -57,5 +58,15 @@ SOURCEPATH ..\..\..\..\engines\wintermute USERINCLUDE ..\..\..\..\engines USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\audio ..\src + +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png +SYSTEMINCLUDE \epoc32\include\ESDL SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version -SYSTEMINCLUDE \epoc32\include \epoc32\include\libc ..\src +SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor +SYSTEMINCLUDE \epoc32\include +SYSTEMINCLUDE ..\src // for portdefs.h diff --git a/backends/platform/symbian/mmp/scummvm_zvision.mmp.in b/backends/platform/symbian/mmp/scummvm_zvision.mmp.in new file mode 100644 index 0000000000..642f659551 --- /dev/null +++ b/backends/platform/symbian/mmp/scummvm_zvision.mmp.in @@ -0,0 +1,71 @@ +/* ScummVM - Graphic Adventure Engine + * Copyright (C) 2003-2005 Andreas 'Sprawl' Karlsson - Original EPOC port, ESDL + * Copyright (C) 2003-2005 Lars 'AnotherGuest' Persson - Original EPOC port, Audio System + * Copyright (C) 2005 Jurgen 'SumthinWicked' Braam - EPOC/CVS maintainer + * Copyright (C) 2005-2013 The ScummVM project + * Copyright (C) 2013 Strizniou Fedor - Epoc project file + * + * ScummVM is the legal property of its developers, whose names + * are too numerous to list here. Please refer to the COPYRIGHT + * file distributed with this source distribution. + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + */ + +// +// EPOC MMP makefile project for ScummVM +// + +// *** Definitions + +TARGET scummvm_zvision.lib +TARGETTYPE lib +OPTION MSVC /QIfist /Ob1 /Oy /GF // /QIfist disables use of __ftol2 to avoid linker probs with MS libc: http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vccore/html/vcrefQIfistSuppress_ftol.asp +OPTION GCC -Wno-multichar -Wno-reorder // don't optimize for ARM, platform way too sensitive for that :( just turn off some common warnings +OPTION GCCE -Wno-multichar -Wno-reorder -Wno-unused -Wno-format -fsigned-char +ALWAYS_BUILD_AS_ARM + +//START_AUTO_MACROS_SLAVE// + + // empty base file, will be updated by Perl build scripts + +//STOP_AUTO_MACROS_SLAVE// + +// *** SOURCE files + +SOURCEPATH ..\..\..\..\engines\zvision + +//START_AUTO_OBJECTS_ZVISION_// + + // empty base file, will be updated by Perl build scripts + +//STOP_AUTO_OBJECTS_ZVISION_// + +// *** Include paths + +USERINCLUDE ..\..\..\..\engines +USERINCLUDE ..\..\..\.. ..\..\..\..\gui ..\..\..\..\audio ..\src +SYSTEMINCLUDE \epoc32\include\freetype +SYSTEMINCLUDE \epoc32\include\mpeg2dec +SYSTEMINCLUDE \epoc32\include\jpeg +SYSTEMINCLUDE \epoc32\include\png +SYSTEMINCLUDE \epoc32\include\ESDL +SYSTEMINCLUDE \epoc32\include\ZLIB // before \epoc32\include because symbian already has older version +SYSTEMINCLUDE \epoc32\include\libc +SYSTEMINCLUDE \epoc32\include\theora +SYSTEMINCLUDE \epoc32\include\tremor +SYSTEMINCLUDE \epoc32\include +SYSTEMINCLUDE ..\src // for portdefs.h diff --git a/backends/platform/symbian/res/ScummVmAif.rss b/backends/platform/symbian/res/ScummVmAif.rss index fab2cadbb8..2dbf436a8f 100644 --- a/backends/platform/symbian/res/ScummVmAif.rss +++ b/backends/platform/symbian/res/ScummVmAif.rss @@ -2,7 +2,7 @@ * Copyright (C) 2003-2005 Andreas 'Sprawl' Karlsson - Original EPOC port, ESDL * Copyright (C) 2003-2005 Lars 'AnotherGuest' Persson - Original EPOC port, Audio System * Copyright (C) 2005 Jurgen 'SumthinWicked' Braam - EPOC/CVS maintainer - * Copyright (C) 2005-2013 The ScummVM project + * Copyright (C) 2005-2014 The ScummVM Team * * ScummVM is the legal property of its developers, whose names * are too numerous to list here. Please refer to the COPYRIGHT diff --git a/backends/platform/symbian/res/scummvm.rss b/backends/platform/symbian/res/scummvm.rss index 7e667f1cf3..6a0ab24ff0 100644 --- a/backends/platform/symbian/res/scummvm.rss +++ b/backends/platform/symbian/res/scummvm.rss @@ -2,7 +2,7 @@ * Copyright (C) 2003-2005 Andreas 'Sprawl' Karlsson - Original EPOC port, ESDL * Copyright (C) 2003-2005 Lars 'AnotherGuest' Persson - Original EPOC port, Audio System * Copyright (C) 2005 Jurgen 'SumthinWicked' Braam - EPOC/CVS maintainer - * Copyright (C) 2005-2013 The ScummVM project + * Copyright (C) 2005-2014 The ScummVM Team * * ScummVM is the legal property of its developers, whose names * are too numerous to list here. Please refer to the COPYRIGHT diff --git a/backends/platform/symbian/res/scummvm_A0000658.rss b/backends/platform/symbian/res/scummvm_A0000658.rss index 3325d72249..562fef54c6 100644 --- a/backends/platform/symbian/res/scummvm_A0000658.rss +++ b/backends/platform/symbian/res/scummvm_A0000658.rss @@ -2,7 +2,7 @@ * Copyright (C) 2003-2005 Andreas 'Sprawl' Karlsson - Original EPOC port, ESDL * Copyright (C) 2003-2005 Lars 'AnotherGuest' Persson - Original EPOC port, Audio System * Copyright (C) 2005 Jurgen 'SumthinWicked' Braam - EPOC/CVS maintainer - * Copyright (C) 2005-2013 The ScummVM project + * Copyright (C) 2005-2014 The ScummVM Team * * ScummVM is the legal property of its developers, whose names * are too numerous to list here. Please refer to the COPYRIGHT diff --git a/backends/platform/symbian/src/ScummApp.cpp b/backends/platform/symbian/src/ScummApp.cpp index b952177f9a..5256c81dcc 100644 --- a/backends/platform/symbian/src/ScummApp.cpp +++ b/backends/platform/symbian/src/ScummApp.cpp @@ -17,6 +17,7 @@ * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * */ #include "backends/platform/symbian/src/ScummApp.h" diff --git a/backends/platform/symbian/src/ScummApp.h b/backends/platform/symbian/src/ScummApp.h index 00d03e6d7b..db643f61b6 100644 --- a/backends/platform/symbian/src/ScummApp.h +++ b/backends/platform/symbian/src/ScummApp.h @@ -17,6 +17,7 @@ * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * */ #ifndef SCUMMAPP_H diff --git a/backends/platform/symbian/src/ScummVm.hrh b/backends/platform/symbian/src/ScummVm.hrh index c43a9da118..316e4d08f6 100644 --- a/backends/platform/symbian/src/ScummVm.hrh +++ b/backends/platform/symbian/src/ScummVm.hrh @@ -2,7 +2,7 @@ * Copyright (C) 2003-2005 Andreas 'Sprawl' Karlsson - Original EPOC port, ESDL * Copyright (C) 2003-2005 Lars 'AnotherGuest' Persson - Original EPOC port, Audio System * Copyright (C) 2005 Jurgen 'SumthinWicked' Braam - EPOC/CVS maintainer - * Copyright (C) 2005-2013 The ScummVM project + * Copyright (C) 2005-2014 The ScummVM Team * * ScummVM is the legal property of its developers, whose names * are too numerous to list here. Please refer to the COPYRIGHT diff --git a/backends/platform/symbian/src/SymbianActions.cpp b/backends/platform/symbian/src/SymbianActions.cpp index c47bd93772..0810b382d2 100644 --- a/backends/platform/symbian/src/SymbianActions.cpp +++ b/backends/platform/symbian/src/SymbianActions.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/symbian/src/SymbianActions.h b/backends/platform/symbian/src/SymbianActions.h index 2b65c6c950..fc68091c74 100644 --- a/backends/platform/symbian/src/SymbianActions.h +++ b/backends/platform/symbian/src/SymbianActions.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/symbian/src/SymbianMain.cpp b/backends/platform/symbian/src/SymbianMain.cpp index 8da2b239f4..d7ad26d769 100644 --- a/backends/platform/symbian/src/SymbianMain.cpp +++ b/backends/platform/symbian/src/SymbianMain.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/symbian/src/SymbianOS.cpp b/backends/platform/symbian/src/SymbianOS.cpp index b1bd976f9e..1fca7f5df5 100644 --- a/backends/platform/symbian/src/SymbianOS.cpp +++ b/backends/platform/symbian/src/SymbianOS.cpp @@ -17,6 +17,7 @@ * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * */ #include <sdlapp.h> // for CSDLApp::GetExecutablePathCStr() @ Symbian::GetExecutablePath() @@ -197,3 +198,8 @@ void* scumm_bsearch(const void *key, const void *base, size_t nmemb, size_t size return NULL; } + +int remove(const char *path) +{ + return unlink(path); +} diff --git a/backends/platform/symbian/src/SymbianOS.h b/backends/platform/symbian/src/SymbianOS.h index 74a102dc15..57a471f1a9 100644 --- a/backends/platform/symbian/src/SymbianOS.h +++ b/backends/platform/symbian/src/SymbianOS.h @@ -17,6 +17,7 @@ * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * */ #ifndef PLATFORM_SDL_SYMBIAN_H diff --git a/backends/platform/symbian/src/portdefs.h b/backends/platform/symbian/src/portdefs.h index 1f9128a54f..1fb941963b 100644 --- a/backends/platform/symbian/src/portdefs.h +++ b/backends/platform/symbian/src/portdefs.h @@ -17,6 +17,7 @@ * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * */ #ifndef SYMBIAN_PORTDEFS_H @@ -60,6 +61,8 @@ typedef signed long int int32; #define SMALL_SCREEN_DEVICE #define DISABLE_COMMAND_LINE +#define USE_RGB_COLOR +int remove(const char *path); #if defined(USE_TREMOR) && !defined(USE_VORBIS) #define USE_VORBIS // make sure this one is defined together with USE_TREMOR! diff --git a/backends/platform/tizen/application.cpp b/backends/platform/tizen/application.cpp index a73efacf58..d7832ca1da 100644 --- a/backends/platform/tizen/application.cpp +++ b/backends/platform/tizen/application.cpp @@ -11,7 +11,7 @@ * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License diff --git a/backends/platform/tizen/application.h b/backends/platform/tizen/application.h index f18ccb175b..c46684eafb 100644 --- a/backends/platform/tizen/application.h +++ b/backends/platform/tizen/application.h @@ -11,7 +11,7 @@ * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License diff --git a/backends/platform/tizen/audio.cpp b/backends/platform/tizen/audio.cpp index f9ac80a583..b2e061baef 100644 --- a/backends/platform/tizen/audio.cpp +++ b/backends/platform/tizen/audio.cpp @@ -11,7 +11,7 @@ * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License diff --git a/backends/platform/tizen/audio.h b/backends/platform/tizen/audio.h index a304231578..de4724eb3c 100644 --- a/backends/platform/tizen/audio.h +++ b/backends/platform/tizen/audio.h @@ -11,7 +11,7 @@ * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License diff --git a/backends/platform/tizen/form.cpp b/backends/platform/tizen/form.cpp index 10d51cc610..3f7b918102 100644 --- a/backends/platform/tizen/form.cpp +++ b/backends/platform/tizen/form.cpp @@ -11,7 +11,7 @@ * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License diff --git a/backends/platform/tizen/form.h b/backends/platform/tizen/form.h index e419c14d24..3e34b8989e 100644 --- a/backends/platform/tizen/form.h +++ b/backends/platform/tizen/form.h @@ -11,7 +11,7 @@ * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License diff --git a/backends/platform/tizen/fs.cpp b/backends/platform/tizen/fs.cpp index 8145cd5638..c6cd8f0a71 100644 --- a/backends/platform/tizen/fs.cpp +++ b/backends/platform/tizen/fs.cpp @@ -11,12 +11,13 @@ * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * */ #include "config.h" diff --git a/backends/platform/tizen/fs.h b/backends/platform/tizen/fs.h index 0356aaad33..8c1677fa7b 100644 --- a/backends/platform/tizen/fs.h +++ b/backends/platform/tizen/fs.h @@ -11,12 +11,13 @@ * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * */ #ifndef TIZEN_FILESYSTEM_H diff --git a/backends/platform/tizen/graphics.cpp b/backends/platform/tizen/graphics.cpp index 2cafb9f781..9b23e3fe78 100644 --- a/backends/platform/tizen/graphics.cpp +++ b/backends/platform/tizen/graphics.cpp @@ -11,7 +11,7 @@ * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License @@ -37,13 +37,13 @@ TizenGraphicsManager::TizenGraphicsManager(TizenAppForm *appForm) : _eglContext(EGL_NO_CONTEXT), _initState(true) { assert(appForm != NULL); - _videoMode.fullscreen = true; } TizenGraphicsManager::~TizenGraphicsManager() { logEntered(); if (_eglDisplay != EGL_NO_DISPLAY) { + notifyContextDestroy(); eglMakeCurrent(_eglDisplay, NULL, NULL, NULL); if (_eglContext != EGL_NO_CONTEXT) { eglDestroyContext(_eglDisplay, _eglContext); @@ -51,17 +51,34 @@ TizenGraphicsManager::~TizenGraphicsManager() { } } +result TizenGraphicsManager::Construct() { + // Initialize our OpenGL ES context. + loadEgl(); + + // Notify the OpenGL code about our context. + + // We default to RGB565 and RGBA5551 which is closest to the actual output + // mode we setup. + notifyContextCreate(Graphics::PixelFormat(2, 5, 6, 5, 0, 11, 5, 0, 0), Graphics::PixelFormat(2, 5, 5, 5, 1, 11, 6, 1, 0)); + + // Tell our size. + int x, y, width, height; + _appForm->GetBounds(x, y, width, height); + AppLog("screen size: %dx%d", width, height); + setActualScreenSize(width, height); + return E_SUCCESS; +} + const Graphics::Font *TizenGraphicsManager::getFontOSD() { return FontMan.getFontByUsage(Graphics::FontManager::kBigGUIFont); } bool TizenGraphicsManager::moveMouse(int16 &x, int16 &y) { - int16 currentX = _cursorState.x; - int16 currentY = _cursorState.y; + int16 currentX, currentY; + getMousePosition(currentX, currentY); // save the current hardware coordinates - _cursorState.x = x; - _cursorState.y = y; + setMousePosition(x, y); // return x/y as game coordinates adjustMousePosition(x, y); @@ -85,15 +102,17 @@ Common::List<Graphics::PixelFormat> TizenGraphicsManager::getSupportedFormats() } bool TizenGraphicsManager::hasFeature(OSystem::Feature f) { - bool result = (f == OSystem::kFeatureFullscreenMode || - f == OSystem::kFeatureVirtualKeyboard || + bool result = + (f == OSystem::kFeatureVirtualKeyboard || OpenGLGraphicsManager::hasFeature(f)); return result; } void TizenGraphicsManager::setFeatureState(OSystem::Feature f, bool enable) { - if (f == OSystem::kFeatureVirtualKeyboard && enable) { - _appForm->showKeypad(); + if (f == OSystem::kFeatureVirtualKeyboard) { + if (enable) { + _appForm->showKeypad(); + } } else { OpenGLGraphicsManager::setFeatureState(f, enable); } @@ -106,8 +125,9 @@ void TizenGraphicsManager::setReady() { } void TizenGraphicsManager::updateScreen() { - if (_transactionMode == kTransactionNone) { - internUpdateScreen(); + if (!_initState) { + OpenGLGraphicsManager::updateScreen(); + eglSwapBuffers(_eglDisplay, _eglSurface); } } @@ -133,10 +153,6 @@ bool TizenGraphicsManager::loadEgl() { eglBindAPI(EGL_OPENGL_ES_API); - if (_eglDisplay) { - unloadGFXMode(); - } - _eglDisplay = eglGetDisplay((EGLNativeDisplayType) EGL_DEFAULT_DISPLAY); if (EGL_NO_DISPLAY == _eglDisplay) { systemError("eglGetDisplay() failed"); @@ -178,65 +194,12 @@ bool TizenGraphicsManager::loadEgl() { systemError("eglMakeCurrent() failed"); return false; } - if (!_initState) { - _appForm->GetVisualElement()->SetShowState(true); - } logLeaving(); return true; } -bool TizenGraphicsManager::loadGFXMode() { - logEntered(); - - if (!loadEgl()) { - unloadGFXMode(); - return false; - } - - int x, y, width, height; - _appForm->GetBounds(x, y, width, height); - _videoMode.overlayWidth = _videoMode.hardwareWidth = width; - _videoMode.overlayHeight = _videoMode.hardwareHeight = height; - _videoMode.scaleFactor = 4; // for proportional sized cursor in the launcher - - AppLog("screen size: %dx%d", _videoMode.hardwareWidth, _videoMode.hardwareHeight); - return OpenGLGraphicsManager::loadGFXMode(); -} - -void TizenGraphicsManager::loadTextures() { - logEntered(); - OpenGLGraphicsManager::loadTextures(); -} - -void TizenGraphicsManager::internUpdateScreen() { - if (!_initState) { - OpenGLGraphicsManager::internUpdateScreen(); - eglSwapBuffers(_eglDisplay, _eglSurface); - } -} - -void TizenGraphicsManager::unloadGFXMode() { - logEntered(); - _appForm->GetVisualElement()->SetShowState(false); - - if (_eglDisplay != EGL_NO_DISPLAY) { - eglMakeCurrent(_eglDisplay, NULL, NULL, NULL); - - if (_eglContext != EGL_NO_CONTEXT) { - eglDestroyContext(_eglDisplay, _eglContext); - _eglContext = EGL_NO_CONTEXT; - } - - if (_eglSurface != EGL_NO_SURFACE) { - eglDestroySurface(_eglDisplay, _eglSurface); - _eglSurface = EGL_NO_SURFACE; - } - - eglTerminate(_eglDisplay); - _eglDisplay = EGL_NO_DISPLAY; - } - - _eglConfig = NULL; - OpenGLGraphicsManager::unloadGFXMode(); - logLeaving(); +bool TizenGraphicsManager::loadVideoMode(uint requestedWidth, uint requestedHeight, const Graphics::PixelFormat &format) { + // We get this whenever a new resolution is requested. Since Tizen is + // using a fixed output size we do nothing like that here. + return true; } diff --git a/backends/platform/tizen/graphics.h b/backends/platform/tizen/graphics.h index 27e5a6aaeb..f1d4498650 100644 --- a/backends/platform/tizen/graphics.h +++ b/backends/platform/tizen/graphics.h @@ -11,7 +11,7 @@ * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License @@ -39,28 +39,31 @@ using namespace Tizen::Graphics; using namespace Tizen::Graphics::Opengl; using namespace Tizen::App; -class TizenGraphicsManager : public OpenGLGraphicsManager { +class TizenGraphicsManager : public OpenGL::OpenGLGraphicsManager { public: TizenGraphicsManager(TizenAppForm *appForm); virtual ~TizenGraphicsManager(); + result Construct(); + Common::List<Graphics::PixelFormat> getSupportedFormats() const; bool hasFeature(OSystem::Feature f); - void updateScreen(); void setFeatureState(OSystem::Feature f, bool enable); + void updateScreen(); + void setReady(); bool isReady() { return !_initState; } - const Graphics::Font *getFontOSD(); + bool moveMouse(int16 &x, int16 &y); -private: - void internUpdateScreen(); - bool loadGFXMode(); - void loadTextures(); - void unloadGFXMode(); +protected: void setInternalMousePosition(int x, int y) {} - void showSplash(); + bool loadVideoMode(uint requestedWidth, uint requestedHeight, const Graphics::PixelFormat &format); + + const Graphics::Font *getFontOSD(); + +private: bool loadEgl(); TizenAppForm *_appForm; EGLDisplay _eglDisplay; diff --git a/backends/platform/tizen/main.cpp b/backends/platform/tizen/main.cpp index b12cc3adc9..50baa5b977 100644 --- a/backends/platform/tizen/main.cpp +++ b/backends/platform/tizen/main.cpp @@ -11,7 +11,7 @@ * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License diff --git a/backends/platform/tizen/missing.cpp b/backends/platform/tizen/missing.cpp index 5ac55d0f6c..f24ba5655c 100644 --- a/backends/platform/tizen/missing.cpp +++ b/backends/platform/tizen/missing.cpp @@ -11,7 +11,7 @@ * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License diff --git a/backends/platform/tizen/portdefs.h b/backends/platform/tizen/portdefs.h index 050ce7d1e0..f5efe85f92 100644 --- a/backends/platform/tizen/portdefs.h +++ b/backends/platform/tizen/portdefs.h @@ -11,7 +11,7 @@ * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License diff --git a/backends/platform/tizen/sscanf.cpp b/backends/platform/tizen/sscanf.cpp index 75f009cc61..b52389c91c 100644 --- a/backends/platform/tizen/sscanf.cpp +++ b/backends/platform/tizen/sscanf.cpp @@ -11,7 +11,7 @@ * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License diff --git a/backends/platform/tizen/system.cpp b/backends/platform/tizen/system.cpp index 3448dc1421..a235456670 100644 --- a/backends/platform/tizen/system.cpp +++ b/backends/platform/tizen/system.cpp @@ -11,7 +11,7 @@ * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License @@ -266,8 +266,8 @@ result TizenSystem::initModules() { return E_OUT_OF_MEMORY; } - _graphicsManager = (GraphicsManager *)new TizenGraphicsManager(_appForm); - if (!_graphicsManager) { + _graphicsManager = new TizenGraphicsManager(_appForm); + if (!_graphicsManager || getGraphics()->Construct() != E_SUCCESS) { return E_OUT_OF_MEMORY; } diff --git a/backends/platform/tizen/system.h b/backends/platform/tizen/system.h index b38940cc95..3f668baf34 100644 --- a/backends/platform/tizen/system.h +++ b/backends/platform/tizen/system.h @@ -11,7 +11,7 @@ * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License @@ -73,7 +73,7 @@ public: bool isClosing() { return _appForm->isClosing(); } TizenGraphicsManager *getGraphics() { - return (TizenGraphicsManager *)_graphicsManager; + return dynamic_cast<TizenGraphicsManager *>(_graphicsManager); } private: diff --git a/backends/platform/webos/main.cpp b/backends/platform/webos/main.cpp index 43c7ba18af..70b3fe1674 100644 --- a/backends/platform/webos/main.cpp +++ b/backends/platform/webos/main.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/webos/webos.cpp b/backends/platform/webos/webos.cpp index fc18628235..da60b27713 100644 --- a/backends/platform/webos/webos.cpp +++ b/backends/platform/webos/webos.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/webos/webos.h b/backends/platform/webos/webos.h index dda56a70da..a2535ddc08 100644 --- a/backends/platform/webos/webos.h +++ b/backends/platform/webos/webos.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/wii/main.cpp b/backends/platform/wii/main.cpp index affe053b6a..35d800a527 100644 --- a/backends/platform/wii/main.cpp +++ b/backends/platform/wii/main.cpp @@ -8,15 +8,16 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * */ #define FORBIDDEN_SYMBOL_EXCEPTION_chdir @@ -225,7 +226,8 @@ int main(int argc, char *argv[]) { printf("shutdown\n"); SYS_UnregisterResetFunc(&resetinfo); - fatUnmountDefault(); + fatUnmount("usb:/"); + fatUnmount("sd:/"); if (res) show_console(res); diff --git a/backends/platform/wii/options.cpp b/backends/platform/wii/options.cpp index ede81343ca..731e979ec0 100644 --- a/backends/platform/wii/options.cpp +++ b/backends/platform/wii/options.cpp @@ -16,7 +16,7 @@ * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. * */ diff --git a/backends/platform/wii/options.h b/backends/platform/wii/options.h index 9b500ef29f..1fa4acd50e 100644 --- a/backends/platform/wii/options.h +++ b/backends/platform/wii/options.h @@ -16,7 +16,7 @@ * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. * */ diff --git a/backends/platform/wii/osystem.cpp b/backends/platform/wii/osystem.cpp index 9d3a7473e3..ab2f2c6f0f 100644 --- a/backends/platform/wii/osystem.cpp +++ b/backends/platform/wii/osystem.cpp @@ -8,15 +8,16 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * */ #define FORBIDDEN_SYMBOL_ALLOW_ALL diff --git a/backends/platform/wii/osystem.h b/backends/platform/wii/osystem.h index 287c70ad6b..f1591614bf 100644 --- a/backends/platform/wii/osystem.h +++ b/backends/platform/wii/osystem.h @@ -8,15 +8,16 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * */ #ifndef _WII_OSYSTEM_H_ diff --git a/backends/platform/wii/osystem_events.cpp b/backends/platform/wii/osystem_events.cpp index 3ba66aed89..2da1d80917 100644 --- a/backends/platform/wii/osystem_events.cpp +++ b/backends/platform/wii/osystem_events.cpp @@ -8,15 +8,16 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * */ #define FORBIDDEN_SYMBOL_EXCEPTION_printf @@ -188,7 +189,7 @@ void OSystem_Wii::initEvents() { _padAcceleration = 9 - ConfMan.getInt("wii_pad_acceleration"); #ifdef USE_WII_KBD - _kbd_active = KEYBOARD_Init() >= 0; + _kbd_active = KEYBOARD_Init(NULL) >= 0; #endif } diff --git a/backends/platform/wii/osystem_gfx.cpp b/backends/platform/wii/osystem_gfx.cpp index 92c890b0a9..bb91242f98 100644 --- a/backends/platform/wii/osystem_gfx.cpp +++ b/backends/platform/wii/osystem_gfx.cpp @@ -8,15 +8,16 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * */ #define FORBIDDEN_SYMBOL_EXCEPTION_printf @@ -716,8 +717,8 @@ void OSystem_Wii::setMouseCursor(const void *buf, uint w, uint h, int hotspotX, u16 *d = (u16 *) tmp; for (u16 y = 0; y < h; ++y) { for (u16 x = 0; x < w; ++x) { - if (*s++ != _mouseKeyColor) - *d++ |= 7 << 12; + if (*s++ == _mouseKeyColor) + *d++ &= ~(7 << 12); else d++; } diff --git a/backends/platform/wii/osystem_sfx.cpp b/backends/platform/wii/osystem_sfx.cpp index 2e658e47aa..70a440a600 100644 --- a/backends/platform/wii/osystem_sfx.cpp +++ b/backends/platform/wii/osystem_sfx.cpp @@ -8,15 +8,16 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * */ #define FORBIDDEN_SYMBOL_EXCEPTION_printf diff --git a/backends/platform/wii/wii.mk b/backends/platform/wii/wii.mk index 7d2db68b4e..99ef46338c 100644 --- a/backends/platform/wii/wii.mk +++ b/backends/platform/wii/wii.mk @@ -17,10 +17,10 @@ geckoupload: $(WII_EXE_STRIPPED) $(DEVKITPPC)/bin/geckoupload $< wiigdb: - $(DEVKITPPC)/bin/powerpc-gekko-gdb -n $(EXECUTABLE) + $(DEVKITPPC)/bin/powerpc-eabi-gdb -n $(EXECUTABLE) wiidebug: - $(DEVKITPPC)/bin/powerpc-gekko-gdb -n $(EXECUTABLE) -x $(srcdir)/backends/platform/wii/gdb.txt + $(DEVKITPPC)/bin/powerpc-eabi-gdb -n $(EXECUTABLE) -x $(srcdir)/backends/platform/wii/gdb.txt # target to create a Wii snapshot wiidist: all diff --git a/backends/platform/wince/CEActionsPocket.cpp b/backends/platform/wince/CEActionsPocket.cpp index 5980a41caa..09286f2e9f 100644 --- a/backends/platform/wince/CEActionsPocket.cpp +++ b/backends/platform/wince/CEActionsPocket.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. @@ -236,7 +236,7 @@ CEActionsPocket::~CEActionsPocket() { bool CEActionsPocket::perform(GUI::ActionType action, bool pushed) { static bool keydialogrunning = false, quitdialog = false; - _graphicsMan = ((WINCESdlGraphicsManager *)((OSystem_SDL *)g_system)->getGraphicsManager()); + _graphicsMan = dynamic_cast<WINCESdlGraphicsManager *>(((OSystem_SDL *)g_system)->getGraphicsManager()); if (!pushed) { switch (action) { diff --git a/backends/platform/wince/CEActionsPocket.h b/backends/platform/wince/CEActionsPocket.h index e1f52b6b88..f2952c059a 100644 --- a/backends/platform/wince/CEActionsPocket.h +++ b/backends/platform/wince/CEActionsPocket.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/wince/CEActionsSmartphone.cpp b/backends/platform/wince/CEActionsSmartphone.cpp index 2cce288323..95957707e3 100644 --- a/backends/platform/wince/CEActionsSmartphone.cpp +++ b/backends/platform/wince/CEActionsSmartphone.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. @@ -202,7 +202,7 @@ CEActionsSmartphone::~CEActionsSmartphone() { bool CEActionsSmartphone::perform(GUI::ActionType action, bool pushed) { static bool keydialogrunning = false, quitdialog = false; - _graphicsMan = ((WINCESdlGraphicsManager *)((OSystem_SDL *)g_system)->getGraphicsManager()); + _graphicsMan = dynamic_cast<WINCESdlGraphicsManager *>(((OSystem_SDL *)g_system)->getGraphicsManager()); if (!pushed) { switch (action) { diff --git a/backends/platform/wince/CEActionsSmartphone.h b/backends/platform/wince/CEActionsSmartphone.h index 3da46d3923..46529bbd99 100644 --- a/backends/platform/wince/CEActionsSmartphone.h +++ b/backends/platform/wince/CEActionsSmartphone.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/wince/CEDevice.cpp b/backends/platform/wince/CEDevice.cpp index 640b1e9169..ffadfeb993 100644 --- a/backends/platform/wince/CEDevice.cpp +++ b/backends/platform/wince/CEDevice.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/wince/CEDevice.h b/backends/platform/wince/CEDevice.h index b9f815ac71..2032b7fb27 100644 --- a/backends/platform/wince/CEDevice.h +++ b/backends/platform/wince/CEDevice.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/wince/CEException.cpp b/backends/platform/wince/CEException.cpp index 4a03354112..46bb618e39 100644 --- a/backends/platform/wince/CEException.cpp +++ b/backends/platform/wince/CEException.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/wince/CEException.h b/backends/platform/wince/CEException.h index 3d4616f282..8ce6bd7dc0 100644 --- a/backends/platform/wince/CEException.h +++ b/backends/platform/wince/CEException.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/wince/CELauncherDialog.cpp b/backends/platform/wince/CELauncherDialog.cpp index dd6076e0af..f7795dfdef 100644 --- a/backends/platform/wince/CELauncherDialog.cpp +++ b/backends/platform/wince/CELauncherDialog.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. @@ -65,12 +65,12 @@ public: }; CELauncherDialog::CELauncherDialog() : GUI::LauncherDialog() { - ((WINCESdlGraphicsManager *)((OSystem_SDL *)g_system)->getGraphicsManager())->reset_panel(); + dynamic_cast<WINCESdlGraphicsManager *>(((OSystem_SDL *)g_system)->getGraphicsManager())->reset_panel(); } void CELauncherDialog::handleCommand(CommandSender *sender, uint32 cmd, uint32 data) { if ((cmd == 'STRT') || (cmd == kListItemActivatedCmd) || (cmd == kListItemDoubleClickedCmd)) { - ((WINCESdlGraphicsManager *)((OSystem_SDL *)g_system)->getGraphicsManager())->init_panel(); + dynamic_cast<WINCESdlGraphicsManager *>(((OSystem_SDL *)g_system)->getGraphicsManager())->init_panel(); } LauncherDialog::handleCommand(sender, cmd, data); if (cmd == 'ABOU') { diff --git a/backends/platform/wince/CELauncherDialog.h b/backends/platform/wince/CELauncherDialog.h index ac84cd3e21..9f69b8500f 100644 --- a/backends/platform/wince/CELauncherDialog.h +++ b/backends/platform/wince/CELauncherDialog.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/wince/CEScaler.cpp b/backends/platform/wince/CEScaler.cpp index 66f7809a3a..321bdd92a9 100644 --- a/backends/platform/wince/CEScaler.cpp +++ b/backends/platform/wince/CEScaler.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/wince/CEScaler.h b/backends/platform/wince/CEScaler.h index de001f7348..fc6540a33c 100644 --- a/backends/platform/wince/CEScaler.h +++ b/backends/platform/wince/CEScaler.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/wince/CEgui/CEGUI.h b/backends/platform/wince/CEgui/CEGUI.h index 8b2e3528e3..8b6db6b099 100644 --- a/backends/platform/wince/CEgui/CEGUI.h +++ b/backends/platform/wince/CEgui/CEGUI.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/wince/CEgui/GUIElement.cpp b/backends/platform/wince/CEgui/GUIElement.cpp index c8e68b87fd..e33e7f7f9d 100644 --- a/backends/platform/wince/CEgui/GUIElement.cpp +++ b/backends/platform/wince/CEgui/GUIElement.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/wince/CEgui/GUIElement.h b/backends/platform/wince/CEgui/GUIElement.h index 44c4b3f275..6695029877 100644 --- a/backends/platform/wince/CEgui/GUIElement.h +++ b/backends/platform/wince/CEgui/GUIElement.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/wince/CEgui/ItemAction.cpp b/backends/platform/wince/CEgui/ItemAction.cpp index 7d6316748b..89ca48efdc 100644 --- a/backends/platform/wince/CEgui/ItemAction.cpp +++ b/backends/platform/wince/CEgui/ItemAction.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/wince/CEgui/ItemAction.h b/backends/platform/wince/CEgui/ItemAction.h index 7b36eaf11a..8de0046d4c 100644 --- a/backends/platform/wince/CEgui/ItemAction.h +++ b/backends/platform/wince/CEgui/ItemAction.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/wince/CEgui/ItemSwitch.cpp b/backends/platform/wince/CEgui/ItemSwitch.cpp index 444826201c..7bb0a23a7b 100644 --- a/backends/platform/wince/CEgui/ItemSwitch.cpp +++ b/backends/platform/wince/CEgui/ItemSwitch.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/wince/CEgui/ItemSwitch.h b/backends/platform/wince/CEgui/ItemSwitch.h index 724d31363c..e54b4b1b99 100644 --- a/backends/platform/wince/CEgui/ItemSwitch.h +++ b/backends/platform/wince/CEgui/ItemSwitch.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/wince/CEgui/Panel.cpp b/backends/platform/wince/CEgui/Panel.cpp index 0853bae8f2..273d06a054 100644 --- a/backends/platform/wince/CEgui/Panel.cpp +++ b/backends/platform/wince/CEgui/Panel.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/wince/CEgui/Panel.h b/backends/platform/wince/CEgui/Panel.h index 514ee5b8af..db38751073 100644 --- a/backends/platform/wince/CEgui/Panel.h +++ b/backends/platform/wince/CEgui/Panel.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/wince/CEgui/PanelItem.cpp b/backends/platform/wince/CEgui/PanelItem.cpp index 2849e256fb..186b5161ef 100644 --- a/backends/platform/wince/CEgui/PanelItem.cpp +++ b/backends/platform/wince/CEgui/PanelItem.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/wince/CEgui/PanelItem.h b/backends/platform/wince/CEgui/PanelItem.h index 8305311ff2..a0a72c2525 100644 --- a/backends/platform/wince/CEgui/PanelItem.h +++ b/backends/platform/wince/CEgui/PanelItem.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/wince/CEgui/PanelKeyboard.cpp b/backends/platform/wince/CEgui/PanelKeyboard.cpp index cab02150c5..34ba8d6473 100644 --- a/backends/platform/wince/CEgui/PanelKeyboard.cpp +++ b/backends/platform/wince/CEgui/PanelKeyboard.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/wince/CEgui/PanelKeyboard.h b/backends/platform/wince/CEgui/PanelKeyboard.h index 69d6a89bd2..a0daca81e3 100644 --- a/backends/platform/wince/CEgui/PanelKeyboard.h +++ b/backends/platform/wince/CEgui/PanelKeyboard.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/wince/CEgui/SDL_ImageResource.cpp b/backends/platform/wince/CEgui/SDL_ImageResource.cpp index 507f9ad7fe..ec430fc848 100644 --- a/backends/platform/wince/CEgui/SDL_ImageResource.cpp +++ b/backends/platform/wince/CEgui/SDL_ImageResource.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/wince/CEgui/SDL_ImageResource.h b/backends/platform/wince/CEgui/SDL_ImageResource.h index 08807a5c1f..4fd7932743 100644 --- a/backends/platform/wince/CEgui/SDL_ImageResource.h +++ b/backends/platform/wince/CEgui/SDL_ImageResource.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/wince/CEgui/Toolbar.cpp b/backends/platform/wince/CEgui/Toolbar.cpp index 0e8e82f1f4..9e04a30210 100644 --- a/backends/platform/wince/CEgui/Toolbar.cpp +++ b/backends/platform/wince/CEgui/Toolbar.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/wince/CEgui/Toolbar.h b/backends/platform/wince/CEgui/Toolbar.h index c7e62bb3d9..d0ac2cdcb3 100644 --- a/backends/platform/wince/CEgui/Toolbar.h +++ b/backends/platform/wince/CEgui/Toolbar.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/wince/CEgui/ToolbarHandler.cpp b/backends/platform/wince/CEgui/ToolbarHandler.cpp index f3e42e11fa..534b338cdb 100644 --- a/backends/platform/wince/CEgui/ToolbarHandler.cpp +++ b/backends/platform/wince/CEgui/ToolbarHandler.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/wince/CEgui/ToolbarHandler.h b/backends/platform/wince/CEgui/ToolbarHandler.h index 5709cf3f1a..36f4022bd8 100644 --- a/backends/platform/wince/CEgui/ToolbarHandler.h +++ b/backends/platform/wince/CEgui/ToolbarHandler.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/wince/CEkeys/CEKeys.h b/backends/platform/wince/CEkeys/CEKeys.h index cf71b982f3..31f5ba839c 100644 --- a/backends/platform/wince/CEkeys/CEKeys.h +++ b/backends/platform/wince/CEkeys/CEKeys.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/wince/CEkeys/EventsBuffer.cpp b/backends/platform/wince/CEkeys/EventsBuffer.cpp index c993798dc8..b4fdc0010d 100644 --- a/backends/platform/wince/CEkeys/EventsBuffer.cpp +++ b/backends/platform/wince/CEkeys/EventsBuffer.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/wince/CEkeys/EventsBuffer.h b/backends/platform/wince/CEkeys/EventsBuffer.h index 235a3e7afd..6c1b12cc24 100644 --- a/backends/platform/wince/CEkeys/EventsBuffer.h +++ b/backends/platform/wince/CEkeys/EventsBuffer.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/wince/missing/missing.cpp b/backends/platform/wince/missing/missing.cpp index ba35f15bb7..0355f35a69 100644 --- a/backends/platform/wince/missing/missing.cpp +++ b/backends/platform/wince/missing/missing.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/wince/portdefs.h b/backends/platform/wince/portdefs.h index 289406c2a4..3304ee0893 100644 --- a/backends/platform/wince/portdefs.h +++ b/backends/platform/wince/portdefs.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/wince/stub.cpp b/backends/platform/wince/stub.cpp index 9f42dc76aa..aba3fb973e 100644 --- a/backends/platform/wince/stub.cpp +++ b/backends/platform/wince/stub.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. diff --git a/backends/platform/wince/wince-sdl.cpp b/backends/platform/wince/wince-sdl.cpp index 3897731db4..96c9313c5d 100644 --- a/backends/platform/wince/wince-sdl.cpp +++ b/backends/platform/wince/wince-sdl.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. @@ -422,7 +422,7 @@ void OSystem_WINCE3::initBackend() { if (_graphicsManager == 0) _graphicsManager = new WINCESdlGraphicsManager(_eventSource); - ((WINCESdlEventSource *)_eventSource)->init((WINCESdlGraphicsManager *)_graphicsManager); + ((WINCESdlEventSource *)_eventSource)->init(dynamic_cast<WINCESdlGraphicsManager *>(_graphicsManager)); // Call parent implementation of this method OSystem_SDL::initBackend(); @@ -486,15 +486,16 @@ void OSystem_WINCE3::swap_sound_master() { //WINCESdlGraphicsManager _graphicsManager - if (((WINCESdlGraphicsManager *)_graphicsManager)->_toolbarHandler.activeName() == NAME_MAIN_PANEL) - ((WINCESdlGraphicsManager *)_graphicsManager)->_toolbarHandler.forceRedraw(); // redraw sound icon + WINCESdlGraphicsManager *graphicsManager = dynamic_cast<WINCESdlGraphicsManager *>(_graphicsManager); + if (graphicsManager->_toolbarHandler.activeName() == NAME_MAIN_PANEL) + graphicsManager->_toolbarHandler.forceRedraw(); // redraw sound icon } void OSystem_WINCE3::engineInit() { check_mappings(); // called here to initialize virtual keys handling - ((WINCESdlGraphicsManager *)_graphicsManager)->update_game_settings(); + dynamic_cast<WINCESdlGraphicsManager *>(_graphicsManager)->update_game_settings(); // finalize mixer init _mixerManager->init(); } @@ -563,7 +564,7 @@ void OSystem_WINCE3::setGraphicsModeIntern() { void OSystem_WINCE3::initSDL() { // Check if SDL has not been initialized if (!_initedSDL) { - uint32 sdlFlags = SDL_INIT_EVENTTHREAD; + uint32 sdlFlags = SDL_INIT_EVENTTHREAD | SDL_INIT_VIDEO; if (ConfMan.hasKey("disable_sdl_parachute")) sdlFlags |= SDL_INIT_NOPARACHUTE; @@ -576,9 +577,6 @@ void OSystem_WINCE3::initSDL() { if (SDL_Init(sdlFlags) == -1) error("Could not initialize SDL: %s", SDL_GetError()); - // Enable unicode support if possible - SDL_EnableUNICODE(1); - _initedSDL = true; } } diff --git a/backends/platform/wince/wince-sdl.h b/backends/platform/wince/wince-sdl.h index b4f323c9e2..2d5a02a23d 100644 --- a/backends/platform/wince/wince-sdl.h +++ b/backends/platform/wince/wince-sdl.h @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. |