Commit Graph

100 Commits

Author SHA1 Message Date
cutealien
e7143ef977 Make CImageLoaderJPG thread safe. Thanks @ Edoardo Lolletti for report and patch (patch #324)
Replace a static variable which was used in error-reporting but wasn't thread-safe.

git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6220 dfc29bdd-3216-0410-991c-e03cc46cb475
2021-06-11 15:09:02 +00:00
cutealien
224d7c5e2c Vertex texture sampling support in Direct3D 9 now controlled via texture-flag ETCF_SUPPORT_VERTEXT_TEXTURE
It's no longer enabled by default as it causes some costs to all texture switches.
Thanks @ edo9300 for reporting (http://irrlicht.sourceforge.net/forum/viewtopic.php?f=7&t=52721)

git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6219 dfc29bdd-3216-0410-991c-e03cc46cb475
2021-06-04 12:17:01 +00:00
cutealien
ca48a1ac69 CGUIListBox now serializes the state of 'Selected'.
Feature wish by chronologicaldot (http://irrlicht.sourceforge.net/forum/viewtopic.php?f=2&t=52719)


git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6218 dfc29bdd-3216-0410-991c-e03cc46cb475
2021-06-01 11:05:54 +00:00
cutealien
f31c1be792 Remove CD3D9Driver::getViewPort overload which did the exact same thing as base class.
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6217 dfc29bdd-3216-0410-991c-e03cc46cb475
2021-05-31 13:36:25 +00:00
cutealien
f103ea3dac Bugfix: Changing focus with tab-keys now also work when elements are inside a modal screen.
Event got eaten before. It passes it now on partly (enough to arrive at CGUIEnvironment) when the focus will stay inside the modal screen.


git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6215 dfc29bdd-3216-0410-991c-e03cc46cb475
2021-05-26 13:57:12 +00:00
cutealien
9147d4ade8 COBJMeshFileLoader using a bit more exact color conversion for 0-1 to 0-255 range
Same now as SColorf::toSColor


git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6214 dfc29bdd-3216-0410-991c-e03cc46cb475
2021-05-07 12:41:57 +00:00
cutealien
e611f2c571 Speedup for COBJMeshWriter
Avoiding some memory allocations.


git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6213 dfc29bdd-3216-0410-991c-e03cc46cb475
2021-05-06 15:01:05 +00:00
cutealien
678e06baeb Add blinkMode parameter to IGUIEnvironment::addModalScreen, so blinking can be suppressed
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6212 dfc29bdd-3216-0410-991c-e03cc46cb475
2021-05-05 13:22:02 +00:00
engineer_apple
1766fc7060 reduce warning.
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6208 dfc29bdd-3216-0410-991c-e03cc46cb475
2021-04-17 23:02:44 +00:00
cutealien
451134322d Add changes to Makefile
Add -fPIC to linker flags (additional to compiler flags).
This is sometimes necessary as chronologicaldot reported in the forum: 
http://irrlicht.sourceforge.net/forum/viewtopic.php?f=2&t=52708
Also gcc manual says this about the -shared flag: 
"For predictable results, you must also specify the same set of options used for compilation (-fpic, -fPIC, or model suboptions) when you specify this linker option."
Add TODO for this about sharedlib_osx as I can't test that.

Add documentation when "make clean" is needed. So far we only have a single set of .o files written in the same folder.
So this has to be called basically on all changes.

Use CPPFLAGS instead of CFLAGS, CXXFLAGS in a few places for options which should be used for all files.

Add CFLAGS and CXXFLAGS for dependency files (not 100% certain about those, just seems to make more sense to me)



git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6207 dfc29bdd-3216-0410-991c-e03cc46cb475
2021-04-17 13:57:33 +00:00
cutealien
bfaffe1171 Speedup: Avoid string copy in CXMLReaderImpl::getAttributeByName
string has operator== for char_type which can save a lot of string allocations when loading xml's.

git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6206 dfc29bdd-3216-0410-991c-e03cc46cb475
2021-04-16 12:59:29 +00:00
cutealien
1c14ae8988 Change default meaning of SIrrlichtCreationParameters::WindowResizable == 2 to meaning no resizing.
Otherwise I probably break AmigaOS again (which was the reason to add this parameter in first place)


git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6197 dfc29bdd-3216-0410-991c-e03cc46cb475
2021-03-06 15:58:05 +00:00
cutealien
c83eaa654c SIrrlichtCreationParameters::WindowResizable no longer bool but has 3 states.
New default is that the system decides itself.
Reason is that X11 didn't like the last change (disabling it on start) too much and we got messed up title-bars.
Or at least on some Window Managers. Which makes sense as X11 really requires Windows to be resizable in Windowed mode.


git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6196 dfc29bdd-3216-0410-991c-e03cc46cb475
2021-03-06 15:49:43 +00:00
cutealien
155c7f7592 Prevent crash in CIrrDeviceMacOSX::setWindowCaption with cyrillic strings.
Thanks @Maksym Hamarnyk for proposing a patch and testing some changes.
May break OSX 10.5 and older (lack of test-system, but probably not much used anymore).


git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6194 dfc29bdd-3216-0410-991c-e03cc46cb475
2021-02-21 19:07:46 +00:00
cutealien
cb2aaf8255 Trying to fix compiling for Apple silicon.
Thanks at Maksim Gamarnik for patch:
599631f5bd
See bug #452 https://sourceforge.net/p/irrlicht/bugs/452


git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6192 dfc29bdd-3216-0410-991c-e03cc46cb475
2021-02-21 16:19:44 +00:00
engineer_apple
12a94ed5b7 BurningVideo: remove align 16 byte on win32
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6191 dfc29bdd-3216-0410-991c-e03cc46cb475
2021-02-13 21:49:03 +00:00
cutealien
748510300d Remove redundant compile flags -fstrict-aliasing -fexpensive-optimizations
Both are already included in -O2 (which is in included in the -O3 we use)
Thanks @randomMesh for reporting: http://irrlicht.sourceforge.net/forum/viewtopic.php?f=7&t=52692
Note: -fstrict-aliasing also gets removed in debug now where it also was enabled.

git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6190 dfc29bdd-3216-0410-991c-e03cc46cb475
2021-02-12 11:29:53 +00:00
cutealien
81a392928b Simplify touch-event handling a bit.
Discussion to this in https://sourceforge.net/p/irrlicht/patches/322
Basically last solution caused problems as it send fake-mouse events on top of touch-events.
For now we can probably just enable touch-events and clear masks for everything else for all devices
as we only use the XInput2 events for touch-event handling and nothing else.
At least not noticing conflicts with rest of X11 input so far and user TheBrokenRail said this works for him.


git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6184 dfc29bdd-3216-0410-991c-e03cc46cb475
2021-01-06 14:43:37 +00:00
cutealien
af380df28f Make previous touch-input patch for X11 a bit more similar to other event code.
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6179 dfc29bdd-3216-0410-991c-e03cc46cb475
2020-12-30 14:59:45 +00:00
cutealien
e92ed55afa Add optional multitouch support to X11.
Thanks @TheBrokenRail for a patch proposal based on example code from esjeon (patch #322).
See https://sourceforge.net/p/irrlicht/patches/322
Original example code here: https://github.com/esjeon/xinput2-touch
Users have to enable _IRR_LINUX_X11_XINPUT2_ in IrrCompileConfig and link with Xi to make this work.
I rewrote the patch a bit and have no system for testing here, so this still needs some testing.
I also backported EET_TOUCH_INPUT_EVENT for this from the ogl-es branch.


git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6178 dfc29bdd-3216-0410-991c-e03cc46cb475
2020-12-29 02:15:27 +00:00
cutealien
0e56aca052 Fix compiling png on arm platforms.
Thx @TheBrokenRail for report and patch.
Hidden in comments of patch #322: https://sourceforge.net/p/irrlicht/patches/322
(patch is for es branch, so only part of it applied for now)


git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6176 dfc29bdd-3216-0410-991c-e03cc46cb475
2020-12-22 21:26:39 +00:00
cutealien
e8e38b5095 Slightly changed close window handling on X11
Optimized and avoids problems on Phosh shell
Thanks @TheBrokenRail for a patch (was a tiny part of patch #322).
https://sourceforge.net/p/irrlicht/patches/322
Changed patch slighlty to unify with rest of Irrlicht code.


git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6174 dfc29bdd-3216-0410-991c-e03cc46cb475
2020-12-21 21:59:34 +00:00
cutealien
7f76377bad Merge branch releases/1.8 revisions r6168 through r6170 into trunk.
- Updates libpng to 1.6.37 (from 1.6.23) 
Note: Seems svn can't merge it automatic when a folder was removed and readded with same name. 
Easier to update libs by deleting all files - copying new ones over and then check svn stat for differences
and resolve them manually.


git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6171 dfc29bdd-3216-0410-991c-e03cc46cb475
2020-12-19 14:35:50 +00:00
cutealien
4d13cab50e Merge branch releases/1.8 revisions r6138 through r6166 into trunk
- Fix comment spelling


git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6167 dfc29bdd-3216-0410-991c-e03cc46cb475
2020-12-12 00:29:13 +00:00
cutealien
c90238e87f Add getActiveColor functions to IGUIStaticText and IGUIButton
Returns currently used color - depending on state and if override color is set.
Note: Not adding this to editbox for now as it's a bit more tricky there (selection changing color, so it has no single color).


git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6165 dfc29bdd-3216-0410-991c-e03cc46cb475
2020-12-10 14:45:30 +00:00
cutealien
bd2b44aa1c Add IGUIEnvironment::addToDeletionQueue to allow save removal of gui elements while iterating over them
Basically same as ISceneManager::addToDeletionQueue.

git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6164 dfc29bdd-3216-0410-991c-e03cc46cb475
2020-12-09 16:26:25 +00:00
cutealien
0368c5b09d IGUIEnvironment::drawAll has now a parameter to allow disabling the automatic resize to driver screensize.
That makes it easier to use partial screens, while using automatic alignment. 
Default is still automatic resizing as before, thought it got changed a bit as it looked a bit strange.
Before it only set the lower-right corner, but compared to driver screensizes, so it behaved a bit strange
when the leftTop corner of the rootGuiElement was changed (different than when the rightBottom corner was set).
Could be the idea before was that only clipping matters.

git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6163 dfc29bdd-3216-0410-991c-e03cc46cb475
2020-12-01 13:42:44 +00:00
cutealien
ba8de14e83 Avoid access allocation when CGUIContextMenu::setSubMenu receives a nullptr for menu.
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6162 dfc29bdd-3216-0410-991c-e03cc46cb475
2020-11-14 17:09:39 +00:00
cutealien
4cb289fc91 Code cleanup
Prefer static_cast to reinterpret_cast.
Declare variables later with init values to avoid having uninitialized variables around.

git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6161 dfc29bdd-3216-0410-991c-e03cc46cb475
2020-11-14 16:56:16 +00:00
cutealien
7d679469b1 Avoid const cast
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6159 dfc29bdd-3216-0410-991c-e03cc46cb475
2020-11-14 16:00:33 +00:00
engineer_apple
1a19b84384 Burningsvideo 0.52 Linux Warnings
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6158 dfc29bdd-3216-0410-991c-e03cc46cb475
2020-11-10 20:42:20 +00:00
engineer_apple
0b4a0b2977 Burningsvideo 0.52 Linux Warnings
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6157 dfc29bdd-3216-0410-991c-e03cc46cb475
2020-11-10 20:39:59 +00:00
engineer_apple
1170f08dae Burningsvideo 0.52 Linux Warnings
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6156 dfc29bdd-3216-0410-991c-e03cc46cb475
2020-11-10 20:29:55 +00:00
engineer_apple
e21ef3d169 Burningsvideo 0.52 Linux Warnings
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6155 dfc29bdd-3216-0410-991c-e03cc46cb475
2020-11-10 19:06:45 +00:00
engineer_apple
5cb28ea357 Burningsvideo 0.52
- scissor for 2D
- downscaled internal rendertargets,interlaced drawing
- supertuxkart gui ok

git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6154 dfc29bdd-3216-0410-991c-e03cc46cb475
2020-11-10 18:49:39 +00:00
cutealien
6805226b5b Add _IRR_OVERRIDE_ to cursor functions in CIrrDeviceOSX.h
Thx @ Maksym for reporting.


git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6153 dfc29bdd-3216-0410-991c-e03cc46cb475
2020-11-05 20:22:03 +00:00
cutealien
7c0253dd82 Fixes for OSX compiling. Thanks @Maksym Hamarnyk.
Origin: 421b17f5d6


git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6144 dfc29bdd-3216-0410-991c-e03cc46cb475
2020-10-28 17:53:24 +00:00
cutealien
6f7578b374 Fix member intialization order to avoid warning on gcc.
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6143 dfc29bdd-3216-0410-991c-e03cc46cb475
2020-10-26 19:55:38 +00:00
cutealien
91cb559caa Bugfix: FPS camera animator on X11 no longer tries grabbing mouse events.
Basically behavior about that is back to how it was in Irrlicht 1.8 - not perfect, but useable.
So window still jumps a bit when dragging toolbar, but no longer outside the sreen. And it's possible again to alt+tab to other windows.
The problem was caused by a combination of FPS camera changes and that we stopped doing mouse-coordinate clipping in the Linux device in r5593.
Basically that clipping had the side-effect that the fps-camera never considered a mouse "outside" on Linux.
Now on Linux we only update after we get a mouse-event (which we still get when the mouse is outside the window).
On Windows we still grab the mouse in the camera, thought that's likely _not_ the best way to do that. Windows has some mouse-grabbing support, 
and I suppose we could use that (or camera should check if that is used as it also can be set by users I think). So maybe in future this can be further improved.
Other operating systems (OSX) should behave like in 1.8 I hope, but as usual I can't test.

Also did a few minor cleanups in the camera.
- Back to using animateNode time instead of real-time. That's because that was not causing the problems I thought back then it might cause as time is only used for keyboard input and not mouse input.
- Moved updating CursorPos to the rest of the code checking CursorControl

Note: A future improvement would be to add support for systems without CursorControl object (could still use mouse-events to get it working usually).

git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6142 dfc29bdd-3216-0410-991c-e03cc46cb475
2020-10-26 19:50:18 +00:00
engineer_apple
08ae93126c BurningVideo: update Test Cases
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6141 dfc29bdd-3216-0410-991c-e03cc46cb475
2020-10-25 15:06:10 +00:00
cutealien
bb9b047568 Use same CLANG_CXX_LANGUAGE_STANDARD flags in debug/release for XCode.
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6139 dfc29bdd-3216-0410-991c-e03cc46cb475
2020-09-20 15:31:48 +00:00
cutealien
f478272392 No longer try to set WM_QUIT when using an external Window on Win32.
Thx @Marko Mahnič for the patch (https://sourceforge.net/p/irrlicht/bugs/449)

git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6135 dfc29bdd-3216-0410-991c-e03cc46cb475
2020-08-11 19:17:24 +00:00
cutealien
f0043ebc36 Tiny refactoring in ply mesh loader.
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6134 dfc29bdd-3216-0410-991c-e03cc46cb475
2020-07-22 22:30:25 +00:00
cutealien
a1b9e8c2ed ply meshloader now also supports textures with names texture_u/texture_v.
Thx @acy for bugreport and test-model (http://irrlicht.sourceforge.net/forum/viewtopic.php?f=4&t=52646)


git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6133 dfc29bdd-3216-0410-991c-e03cc46cb475
2020-07-22 22:12:05 +00:00
cutealien
d7a1a35339 Fix MacOS 10.15 only rendering to quarter of window.
Thanks @bridgeco for the patch: http://irrlicht.sourceforge.net/forum/viewtopic.php?f=7&t=52644

git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6132 dfc29bdd-3216-0410-991c-e03cc46cb475
2020-07-16 17:24:18 +00:00
cutealien
0073ef7cce Update XCode project to XCode 8.
Previously project file was at 3.2 which seems to no longer work with newer XCode versions.
Patch is from Maksym Hamarnyk, no testing from my side for this.


git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6131 dfc29bdd-3216-0410-991c-e03cc46cb475
2020-06-27 14:51:54 +00:00
cutealien
54f5ac4982 Remove 'register' keyword in all c++ code.
It's never really done much in c++, was deprecated in c++11 and is reserved since c++17.
Thanks @Maksym Hamarnyk for remdinding me about this.
Note: there are few more register commands in third library .c code. It's still a valid keyword there.


git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6130 dfc29bdd-3216-0410-991c-e03cc46cb475
2020-06-21 11:38:31 +00:00
cutealien
2c593614cb Fix another compile problem in COpenGLExtensionHandler when compiling older GL versions without extensions.
Thanks @Maksym Hamarnyk for reporting.


git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6129 dfc29bdd-3216-0410-991c-e03cc46cb475
2020-06-21 11:26:40 +00:00
cutealien
340bc7fcbe Add some headers to xcode project file.
Thanks @Maksym Hamarnyk for patch.


git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6127 dfc29bdd-3216-0410-991c-e03cc46cb475
2020-06-20 14:56:45 +00:00
cutealien
6d4dec4054 Compile fixed for COpenGLExtensionHandler compiled on older GL versions without extensions
Thanks @Maksym Hamarnyk for report and patch proposal.


git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6126 dfc29bdd-3216-0410-991c-e03cc46cb475
2020-06-20 12:50:38 +00:00