Martin Gerhardy
f2c9137979
COMMON: removed foreach.h
...
now that we are using c++11 we don't need this wrapper anymore
2023-01-07 02:40:44 +02:00
Le Philousophe
e15aa92118
GRIM: Don't use unsafe strcat and strcpy
2022-10-23 22:46:19 +02:00
Paweł Kołodziejski
06902574b4
GRIM: Janitorial
2022-06-08 01:12:00 +02:00
Paweł Kołodziejski
20cb0ae228
ALL: Cleanup ResidualVM -> ScummVM
2021-12-26 21:19:38 +01:00
Eugene Sandulenko
abea37c9bb
ALL: Update ScummVM project license to GPLv3+
2021-12-26 18:48:43 +01:00
Pawel Kolodziejski
27e12d8a96
ALL: Eliminate LOCAL_PI macro
2020-09-23 23:20:23 +02:00
Bastien Bouclet
23339184ce
GRIM: Clean up float data loading
2018-04-14 11:49:35 +02:00
Vincent Pelletier
84f83fe6ea
ALL: Rename get_float to READ_LE_FLOAT
...
For consistency with other functions/macros from common/endian.h .
2017-05-12 13:57:16 +00:00
Bastien Bouclet
73e6ae888d
GRIM: Fix a memory leak in "SetShadow::loadBinary"
2016-07-12 06:06:37 +02:00
Vincent Pelletier
9bef2bd626
GRIM,EMI: SHADERS: Compute umbra angles cosine on set load instead of for each frame
...
Only benefits shaders renderer, as opengl/tinygl renderers leave such
details to the gl library.
Maintain saved-state compatibility by computing on restore.
2016-01-01 23:07:59 +01:00
Vincent Pelletier
ea8245696b
GRIM,EMI: Scale intensity on change instead of for each frame
...
Also uniformises intensity scaling factor implementation across renderers.
Maintain saved-state compatibility by computing on restore.
2016-01-01 23:07:59 +01:00
Dries Harnie
fb3bd8139a
JANITORIAL: Fix Coverity warnings
...
Fixes coverity warnings 1267220, 1256936, 1229470, 1224097, 1219766,
1054364, 1009896.
2015-05-12 08:49:19 +02:00
Christian Krause
ce3d8bd81d
EMI: Use static lights for overworld actors
...
Overworld actors, e.g. the load/save menu or the inventory wheel
should not use the lights of the current scene for lighting.
This fixes the bug that the screenshots of the load menu
were dimmed to various levels depending on the current scene.
2014-11-22 16:58:43 +01:00
Joseph Jezak
99fa91053c
MATH: Rename XYZ Rotation Functions to Euler to better describe the function.
2014-09-11 13:38:28 -04:00
Joel Teichroeb
6a852161c7
Merge pull request #999 from JoseJX/Camera
...
EMI: Keep camera as a rotation matrix and add Lua functions for changing it.
2014-08-19 17:21:43 -07:00
Joseph Jezak
32a41525ee
EMI: Implement Lua functions for getting camera rotation.
2014-08-19 18:35:32 -04:00
Joseph Jezak
ff9f26981c
EMI: Refactor to use a matrix for the camera.
2014-08-19 18:35:26 -04:00
Joel Teichroeb
e77f599f1c
Merge pull request #1026 from Akz-/emi-sortorder-fix
...
EMI: Sort order fixes
2014-08-19 15:22:13 -07:00
Joni Vähämäki
e2af14a6dd
EMI: Set sector sort order to 0 if the current sector does not specify a sort order.
2014-08-16 23:37:20 +03:00
Joni Vähämäki
d011f06b4f
EMI: Only return a sector sort order if the nearest point on a sector is closer than 0.01 units.
2014-08-16 13:55:16 +03:00
Joni Vähämäki
a37890b8f5
EMI: Get the sort order from the closest sector even if the current position is not contained within any sector.
...
This fixes Guybrush occasionally being visible through the buildings and foliage on Lucre island when walking at the edge of the walkable sectors. This happened because for positions at the edge of the walkable sector the method Sector::isPointInSector may not always return true.
2014-08-14 18:06:59 +03:00
Joni Vähämäki
2b2b12cf1d
EMI: Adjust attenuation of sounds to match the original game better.
2014-08-14 17:51:05 +03:00
Joni Vähämäki
896fd7cb42
EMI: Recalculate volume and balance for positioned sounds when the setup changes. Fixes #996
2014-08-14 17:50:58 +03:00
Joni Vähämäki
09b062acdd
EMI: Parse light name from shadow data.
2014-08-12 17:46:47 +03:00
Joseph Jezak
5c6b30adde
GRIM: Stop a segfault when saving.
2014-08-06 09:08:17 -04:00
Joni Vähämäki
a7a79aeb4e
EMI: Save and restore light falloff ranges. Fixes #997
2014-08-05 00:44:04 +03:00
Joni Vähämäki
fe87ce80cf
EMI: Initialize fields in Light and SetShadow.
2014-08-05 00:42:59 +03:00
Joni Vähämäki
8b754b0de5
EMI: Save and restore SetShadow data.
2014-08-02 20:43:02 +03:00
Joni Vähämäki
970fa79382
EMI: Read unknown bytes after shadow name.
2014-07-29 13:52:46 -07:00
Joseph Jezak
44dc44dd58
EMI: Fix shadows on Big Endian machines.
2014-07-29 10:01:08 -07:00
Joseph Jezak
474de51888
EMI: Fix actor lighting on Big Endian machines.
2014-07-29 10:01:00 -07:00
Joseph Jezak
0866354007
GRIM/EMI: Rename setupCamera to better describe what it does.
2014-07-22 23:28:00 -04:00
Joseph Jezak
6068e94938
EMI/GRIM: Remove unsused roll parameter from setupCamera calls.
2014-07-22 23:27:56 -04:00
Joni Vähämäki
1340771316
GRIM: Initialize _shadows to null.
2014-07-20 22:11:14 +03:00
Joni Vähämäki
1081471119
EMI: Implement projection shadows.
2014-07-20 21:46:14 +03:00
Joni Vähämäki
88ec1d5285
EMI: Implement lighting for OpenGL Shaders renderer.
2014-07-05 14:09:56 +03:00
Joseph Jezak
78772c999b
MATH: Rename getVector3d and add comments for the Vector3d class.
2014-07-01 11:27:02 -04:00
Joni Vähämäki
b5cdd1240f
EMI: Only draw models for actors inside the view frustum.
...
This adds math classes for doing frustum culling in software. These could be used for optimizing performance in many other places as well. For example, if an actor is outside the view frustum, it may not be necessary to do expensive keyframe animation and vertex skinning calculations for that actor.
2014-06-16 15:42:18 +03:00
Joni Vähämäki
8f9f541f17
EMI: Implemented dynamic lighting for models.
...
Lighting is done by calculating vertex colors in software, since the attenuation model used in EMI cannot be simulated with OpenGL fixed function lighting. The original game does the lighting this way as well. Ideally for the modern shader-based renderer a shader would be used for this instead.
2014-06-16 15:41:06 +03:00
Joel Teichroeb
0f3da43694
GRIM: Change NULL to nullptr.
2014-05-30 17:43:08 -07:00
Joseph Jezak josejx@gentoo.org
190dbfacb2
EMI: Load default room image when missing a background bitmap. Fixes #881 .
2014-05-22 22:24:39 -04:00
Pawel Kolodziejski
8759900b6a
ALL: synced with ScummVM
2014-04-05 18:18:42 +02:00
Einar Johan Trøan Sømåen
d741e0c1a5
GRIM: Initialize more members in Set's default constructor
2014-01-07 11:17:25 +01:00
Christian Krause
98e1375763
EMI: Correct cacluation of sound position
...
In GRIM the position, direction and the roll of the camera is set via
gluLookAt but in EMI the camera is steady and its view is adjusted via
matrix rotations.
This patch adjusts the calculation for EMI and refactors the code to
do the calculation in the separate function Set::calculateSoundPosition.
That function will be used for implementing the positional sounds in
EMI.
2013-12-01 23:30:21 +01:00
Joel Teichroeb
c0cb2f1f9c
GRIM: Use a consitent style for constructor initializers
2013-10-26 13:57:55 -07:00
Joel Teichroeb
f9f19a73f4
EMI: Properly print which lights are using the currently unknown light type
2013-07-10 16:31:06 -07:00
Joel Teichroeb
be41e30c00
GRIM: Make lights use an enum instead of checking against a string to get the type
2013-07-10 16:17:28 -07:00
Joel Teichroeb
3ac33abd8b
EMI: Load some of the light data
2013-07-10 15:04:46 -07:00
Einar Johan Trøan Sømåen
fe3883cecd
GRIM: Reformat code to be closer to convention.
2013-07-09 21:12:55 +02:00
Joel Teichroeb
8f27f43442
GRIM: Delete Set::_states without foreach as it could cause problems
2013-07-07 15:12:42 -07:00