Commit Graph

  • 97472da9c2 Add (commented-out) linker flag for SDL to Makefile. Just as minor hint to users when trying to link with SDL. master cutealien 2019-09-03 20:23:57 +0000
  • 0096ba7c7d Fix compilation with SDL device enabled and Windows device disabled. Thanks @kas1e for reporting (http://irrlicht.sourceforge.net/forum/viewtopic.php?f=7&t=52083&p=304892#p304892) Also did change some indention for readability. cutealien 2019-08-30 15:16:17 +0000
  • ea7efdde45 Fix comment. cutealien 2019-08-29 22:31:48 +0000
  • 3c31fb4730 Allow to override MaterialType in SOverrideMaterial. cutealien 2019-08-26 14:42:44 +0000
  • 40d14b7c5c Cleanup: Remove some no longer needed const-casts cutealien 2019-08-21 18:20:29 +0000
  • 004d250e8f Adding a few const's and relaxing the Irrlicht.ruleset. No more checking for all the VS specific annotation stuff in code analysis (we don't use this anyway). Also less const checks (arguably make code nicer, but not really helping finding suspcious code places, just lots of noise). cutealien 2019-08-21 17:37:28 +0000
  • eb02bd0c56 Code cleanup. Mainly making a few variables const and declaring variables at each place where they are used instead of once at top. cutealien 2019-08-17 20:19:00 +0000
  • ede858d56f Make S3DVertex::getType a static instead of const function. Same for other vertex classes. Hopefully this makes it more obvious that we're not dealing with a virtual function here (like all the other getType() functions in Irrlicht). Should maybe be renamed (classType or classTypeId?). Also vertexbuffers can now use it without having to create an object first. cutealien 2019-08-17 18:09:07 +0000
  • 32585c5ed0 Cleanup: Make some variables const. cutealien 2019-08-17 17:52:32 +0000
  • 5ff51c947e Cleanup: Avoid using identical variable names in outer and inner scopes. cutealien 2019-08-17 16:30:41 +0000
  • cc07570496 Let's not have a global variable called 'b'. cutealien 2019-08-17 15:03:24 +0000
  • a57584d320 Fix indention. cutealien 2019-08-17 14:26:36 +0000
  • b5f139f8a7 Use _IRR_OVERRIDE_throughout. cutealien 2019-08-17 14:00:50 +0000
  • 1d6ab9674f Add ruleset file for static code analysis in VS. Specific rules we should use for Irrlicht can be figured out later (probably too many enabled right now) cutealien 2019-08-17 12:43:36 +0000
  • c5286d77ac Fix signed/unsigned conversion warnings. cutealien 2019-08-17 09:55:07 +0000
  • f78e7b17f8 Avoid using identical variable name in inner and outer scope in SOverrideMaterial Wasn't a bug in this case, but I just got lucky. cutealien 2019-08-16 13:02:10 +0000
  • 1b4444e044 Remove E_GPU_SHADING_LANGUAGE in IGPUProgrammingServices. Thx @greenya for noticing this is no longer needed as it was only ever used for the CG shader language which we kicked out already. cutealien 2019-08-15 20:43:50 +0000
  • 3469582bac Make CD3D9RenderTarget::setTexture code more similar to COpenGLCoreRenderTarget::setTexture. Add log warnings when users try to set depth/stencil textures which have no depth color format. cutealien 2019-08-15 20:18:45 +0000
  • 8a33852395 SOverrideMaterial can now override layers, textures and the layer-flags can now be for more than just first layer. Just completing SOverrideMaterial somewhat (some values still can't be set as they have no flags...). cutealien 2019-08-15 16:27:17 +0000
  • 4d32f93c21 Add SOverrideMaterial.h to the VS project files. cutealien 2019-08-15 15:51:46 +0000
  • 53bc690af6 Minor optimization when creating opengl textures Delay switching back to previous active texture until mipmap generation is done. Avoids 4 GL calls in most cases (not really noticable for speed, but makes reading api-traces of GL calls a bit easier). cutealien 2019-08-08 13:35:44 +0000
  • fd155bead0 Add operator[] to vector2d and vector3d cutealien 2019-07-23 15:30:50 +0000
  • 2178368d71 Update mouse position for CSceneNodeAnimatorCameraMaya also on click events. Before it updated only on move events. That could lead to troubles when the camera was actived by click as it then started the rotation with the position of the last move event it had. cutealien 2019-07-11 15:25:54 +0000
  • 985b3ba3a2 Initialize COpenGLExtensionHandler::pGlActiveStencilFaceEXT to 0 cutealien 2019-07-07 15:18:29 +0000
  • 7aaf3cce9d Refactor COpenGLCoreRenderTarget::setTexture slightly. Just making it easier to see when DepthStencil can be set (we never have a depth texture format when we have no texture). cutealien 2019-07-04 21:54:57 +0000
  • 52e41751a8 Marks some function parameters (for internal functions) as const cutealien 2019-07-04 21:30:20 +0000
  • 56a037ff14 Fix wrong index used in CMatrix4<T>::transformVec4 Thx @Thomas Alten for reporting. cutealien 2019-07-04 20:13:49 +0000
  • 1dd0b4338e Bugfix: IrrlichtDevice::isWindowMinimized no longer returns true when it's maximized on Windows. SW_SHOWMINIMIZED isn't a bitflag as was probably assumed. cutealien 2019-07-03 13:53:13 +0000
  • c89676d042 Ignore degenerated faces in obj file loader when they would generate triangles where 2 vertices use identical indices. This mostly happens because we merge vertices by position in the meshloader. But such triangles tend to cause troubles and won't render, so kick them out. cutealien 2019-06-24 10:13:09 +0000
  • 29b2fa974e Documenation fixes. Thx @ greenya. cutealien 2019-06-23 15:47:34 +0000
  • 7d92f4c514 Set old values as default values in IGUIElement::deserializeAttributes. Thx @ chronologicaldot for reporting that this was missing (http://irrlicht.sourceforge.net/forum/viewtopic.php?f=2&t=52370) cutealien 2019-06-15 09:59:35 +0000
  • a57e1c07d2 Initialize new GL function pointers and re-order intialization. GenerateTextureMipmap had been forgotten in initialization when they got added recently. Re-ordering initialization to avoid compiler warnings. cutealien 2019-06-06 13:46:27 +0000
  • cb1d2f7706 Fix typos. Thanks @ greenya cutealien 2019-06-06 13:39:58 +0000
  • 949a1de2f2 Make aabbox3d::isValid const cutealien 2019-05-31 13:33:41 +0000
  • 5c10d53a20 Add aabbox3d::isValid() function to check if MaxEdge > MinEdge cutealien 2019-05-31 13:31:40 +0000
  • 294da48122 Add CMatrix4::transformVec4 to transform vectors with 4 elements Thx @devsh for noting this was missing. cutealien 2019-05-31 13:05:59 +0000
  • 8db58f1505 Add more GL functions and function-pointers to OpenGLExtensionHandler. Thx @ criss and devsh for this patch (got applied with minor adaptions). New functions are about functions using new direct state access functions from GL 4.5 And array textures. Not yet used internally in the engine (but possible to access it with some hacks from apps, we probably should make the extension handler public at some point). cutealien 2019-05-30 15:58:35 +0000
  • 1a6d8e2913 Replace polygon offsetting in SMaterial with a new implementation. Deprecate PolygonOffsetFactor and PolygonOffsetDirection in SMaterial. Replace it by PolygonOffsetDepthBias and PolygonOffsetSlopeScale. Old values still work for now (as well as they did), but will be removed after Irrlicht 1.9. The old implementation was based a lot on the way Direct3D8 had worked. - We only had values -1 and 1 for the slope bias before, but sometimes other values are necessary. - An int value for PolygonOffsetFactor couldn't worked for Direct3D9 which (unlike D3D8) uses a value range of -1 to 1. Thx @ Criss and devsh for implementing some code which showed that different slope scaling is sometimes needed. cutealien 2019-05-29 19:48:08 +0000
  • 93b308554d Set line-endings in new header to \n\r as usual in Irrlicht. (was still unix-style as I just copied this header from khronos). cutealien 2019-05-29 14:01:50 +0000
  • 6021b1c856 Updating OpenGL headers. Note: Khronos made glext.h now depend on a new file KHR/khrplatform.h The idea seems to be that some common types can be shared with other gl headers (for gles versions). But I run into some problem with that as it was included with <> instead of "" so Visual Studio wouldn't find it without adding include paths to all projects for new KHR folder. Didn't want that (can't test that for example on iOS), so I modified official khronos header by changing the include to using "". cutealien 2019-05-28 17:20:35 +0000
  • 3a39815633 Add COpenGLCoreCacheHandler::getDepthTest (thx@ Criss) While COpenGLCoreCacheHandler wasn't meant to be accessed externally, it is possible with some hacks (a few casts and including internal headers) and sometimes necessary. And that's one of the state-flags people have a need to know from outside the engine. cutealien 2019-05-28 15:00:54 +0000
  • dcfe4bcc0a Octree triangleselector nodes now release memory they don't need. Before they could get pretty large as each node used the maximum memory it started with. Also some changes to avoid unnecessary memory re-alloction when creating it. Thanks @Squarefox for reporting the problem and proposing a patch. See discussion at: http://irrlicht.sourceforge.net/forum/viewtopic.php?f=7&t=52484 cutealien 2019-05-26 16:03:08 +0000
  • 574357cb28 Reduce memory fragmentation in COctreeTriangleSelector. Thx@ Squarefox for reporting (http://irrlicht.sourceforge.net/forum/viewtopic.php?f=7&t=52484) Basically the loop was split into 2 loops so children do their allocations after the parent node has finished his. Otherwise we got fragmentation by chaotic allocation order where parents/childs switched all the time. Also indention of loop changed (sorry, should have done that before). cutealien 2019-05-26 15:45:19 +0000
  • 278f5f14e4 Enable broken cubescenenodes again. In r5805 they got broken when adding compile-flags for them. Copy-paste error, define was missing a '_' at the end in some places, sorry. cutealien 2019-05-01 10:32:24 +0000
  • b3a156b1bb Add ITexture::getOriginalColorFormat to access color format of images used to create a texture. We already had the variable, just no access function. cutealien 2019-04-30 15:59:41 +0000
  • 37ccfe58a2 Remove define _IRR_COMPILE_WITH_B3D_WRITER_ in CB3DMeshWriter. (probably was added accidental, as it was always enabled that way which kills it's original purpose). Thx@ LunaRebirth for report (http://irrlicht.sourceforge.net/forum/viewtopic.php?f=1&t=52471) cutealien 2019-04-24 21:03:35 +0000
  • 040aa5043a Add compileflags to allow removing specific scene-nodes from the engine. Following flags got added: _IRR_COMPILE_WITH_OCTREE_SCENENODE_ _IRR_COMPILE_WITH_TERRAIN_SCENENODE_ _IRR_COMPILE_WITH_SHADOW_VOLUME_SCENENODE_ _IRR_COMPILE_WITH_BILLBOARD_SCENENODE_ _IRR_COMPILE_WITH_WATER_SURFACE_SCENENODE_ _IRR_COMPILE_WITH_SKYDOME_SCENENODE_ _IRR_COMPILE_WITH_CUBE_SCENENODE_ _IRR_COMPILE_WITH_SPHERE_SCENENODE_ Also the corresponding _NO_IRR_COMPILE_WITH... flags certainly. More such flags might be added in future, but will test first if it really makes a difference for WebGL apps which were the main reason to add this. cutealien 2019-04-23 20:05:09 +0000
  • 4aa790812f Add new headers to c::b project file. cutealien 2019-03-30 14:06:55 +0000
  • 6b7b5204d1 Sorry, forgot to add new header IMemoryReadFile.h in last check-in. cutealien 2019-03-30 13:58:38 +0000
  • c87c63f31e Add IMemoryReadFile interface which allows direct access to memory block used as file. cutealien 2019-03-30 13:51:44 +0000
  • 0408c9eb52 Add IReadFile::getType() interface to all users to find out what kind of class implements that interface. cutealien 2019-03-30 13:38:19 +0000
  • 39e5fdc3e7 Merge branch releases/1.8 revisions r5633 through r5796 into trunk. - Fix for SViewFrustum::clipLine cutealien 2019-03-29 17:39:29 +0000
  • 0f3838b968 Minor cleanups (mostly comments) for examples 12 & 13. cutealien 2019-03-26 21:52:24 +0000
  • bc035b510f Tiny comment fixes and removing unused code in example 11. cutealien 2019-03-26 20:45:09 +0000
  • 917379f453 Collada loader now handles texture-names with escape characters. Names like "my%20texture.png" will now load "my texture.png". Collada filenames are in xs:anyURI format. xs:anyURI is used in more places, but we don't support any other file-loading inside Collada so far, so that was the most important place to fix. Also added/fixed a few comments. cutealien 2019-03-25 22:32:32 +0000
  • a450a0e391 Fix improved log-message from last commit. Sorry, copy-pasted wrong variable... didn't improve log last time. cutealien 2019-03-21 14:00:17 +0000
  • ecf74091ec Add more detailed log errors when glsl shaders fail to compile or link. cutealien 2019-03-21 13:51:20 +0000
  • 8e384e5c23 Bugfix: CNullDriver::createImage now checks always if texture can be locked() and returns 0 otherwise. Thx @Cycy for reporting (bugreport #437). cutealien 2019-03-16 21:24:20 +0000
  • dab3a624e8 Collada now writes image filenames in URL format with escaped spaces. CColladaMeshWriter::pathToURI tries to create now a correct name in xs::anyURI format (was more like xs::NCName before) Note that the Collada loader in Irrlicht doesn't handle escaped characters yet, so right now can't load textures with space in names anymore written by Irrlicht. That needs another fix in loader (it fails also when the .dae was written by other applications). cutealien 2019-03-15 13:31:37 +0000
  • 31652f6577 Add function string::insert. (more overloads for it can be added later). cutealien 2019-03-15 13:03:03 +0000
  • a336e62fca Add virtual and _IRR_OVERRIDE_ keywords in classes derived from IContextManager cutealien 2019-03-14 22:54:10 +0000
  • 58958c362a Handle restorePrimaryOnZero in CGLXManager::activateContext Done similar as it was done in CWGLManager::activateContext, thought not tested as I currently have no test-case for this on X11. cutealien 2019-03-14 22:45:55 +0000
  • ed6d0d58fc IContextManager::activateContext can now also be used to reset the context. The reset was prevented before, likely to make the use in beginScene easier. But it's necessary for using an OGL context from another thread. Only implemented for WGL so far, GLX implementation will follow soon. cutealien 2019-03-14 16:18:03 +0000
  • 3f0278bfe2 Allow EditBox to still overwrite characters when the text-length has reached max. cutealien 2019-03-12 20:14:51 +0000
  • cda81b1200 Prevent cursor-blinking if editbox is subelement of a disabled element (like in spinbox). cutealien 2019-03-12 19:54:20 +0000
  • a9554b1f58 Remove superfluous pointer check in COpenGLDriver::removeTexture cutealien 2019-02-27 20:32:44 +0000
  • 0a6eda9747 CNullDriver::removeTexture stops now after finding the texture to remove. If it ever has same texture twice in it's cache that would be a bug and this slows texture removing down unnecessarily. Also wasn't correct anyway as it would have missed it if there were 2 times in a row the same texture as the loop index wasn't adapted after the erase. cutealien 2019-02-27 13:18:20 +0000
  • 5a9423648c Bugfix: OpenGL prevented completely removing a texture when it was used in the actively set material. Basically the destructor tried to call a function to drop() itself, but that certainly prevented the constructor from being called in the first place as there still was a reference. No need to backport to 1.8, this was caused by some rewrites in Irrlicht 1.9 back when TextureCache for active materials got added to the driver. cutealien 2019-02-27 13:13:35 +0000
  • 0026ec7cdc Fix SViewFrustum::setFrom once more. SViewFrustum constructor with matrix also adapted. Last change (in r5766) fixed GL and messed up D3D. This needs to use a parameter to tell what the matrix does. Thx @DevSH for reporting. cutealien 2019-02-25 15:50:08 +0000
  • db89bbc2ce Fixing SViewFrustum::recalculateBoundingBox once more. Sorry, missed some points in last fix. cutealien 2019-02-25 14:44:36 +0000
  • ba391682b0 Update opengl test-file. The test which uses it is currently disabled as it has more problems (broken stencil), but this part is fine and probably just changed due to recent opengl fixes. cutealien 2019-02-23 17:48:00 +0000
  • d1bddcc1a2 Fixing SViewFrustum::recalculateBoundingBox and CMatrix4::transformPlane. SViewFrustum::recalculateBoundingBox no longer includes camera position in the bounding-box. Only using frustum corners now. Thx @DevSH for bugreport & patch. CMatrix4::transformPlane was calculating the wrong plane-normal before. It added the matrix translation and also didn't normalize the normal. planeMatrix tests had been checking for wrong results (did check calculations by hand now, so hopefully I got it right, anyone double-checking it for me would certainly be cool...) cutealien 2019-02-22 18:03:34 +0000
  • 7ebd410e0a Camera uses now OGL projection matrices with OpenGL driver. Fixes wrong near-plane values with OpenGL (showed too much before). cutealien 2019-02-21 18:20:33 +0000
  • 0a2ee246c3 Fix error in calculation in new opengl versions of matrix4::buildProjectionMatrixPerspective functions. Sorry, forgot some brackets around addition earlier on :-( cutealien 2019-02-21 17:36:42 +0000
  • a96b81dd4a Adapted orthoCam test to use OpenGL projection matrices with driver. It fails, but it failed before (test is outcommented since a long time, will have to check why) cutealien 2019-02-21 17:16:57 +0000
  • 45be145f9a Add a flag to buildProjectionMatrixPerspective functions to allow creating OpenGL style matrices. Can now have target range of -w to w instead of only 0 to w. cutealien 2019-02-21 16:39:51 +0000
  • 49b2e6fee1 buildProjectionMatrixOrthoLH and buildProjectionMatrixOrthoRH have a new parameter to allow creating OGL style matrices. Old projection matrices always projected z from 0 to 1. For OpenGL we want a -1 to 1 target instead. cutealien 2019-02-21 15:42:43 +0000
  • c310a8d6ae Bugfix: CCameraSceneNode resets the IsOrthogonal flag to false now when it recalculates a projection matrix. Note: It would likely be nicer if it wouldn't switch back to a projection matrix at all but stay with ortho-matrix. But until I get to that - this will at least return the correct flag. cutealien 2019-02-21 14:37:03 +0000
  • 3283b96087 Fix SViewFrustum::setFrom for OGL projection matrices. SViewFrustum::setFrom now sets the correct near clipping plane when the projection matrix doesn't use a target depth range of 0 to z, but for example -z to z. cutealien 2019-02-20 18:55:37 +0000
  • fc2e1bcfd7 Remove code to read boundingbox element in Collada reader as it's not in Collada specification. We also did just read that box and then dropped the info immediately, so it wasn't used anyway. Not sure what that code was about, I hope it was just accidental and not about support for some strange Collada files in the wild. cutealien 2019-02-11 22:02:21 +0000
  • abee25857f .dae/Collade reader now converts from Collada's right-handed to Irrlicht's left handed coordinate system. It already worked correct when Z_UP was set (we switched x/z in that case which also flips coordinate system) But for the default (Y_UP) it had been wrong before (that one is still right-handed in Collada). We do now convert all z to -z (so z coordinates do change, but it prevents objects from showing up mirrored). Note: For readLookAtNode I also added code to regard Z_UP, but have no test-case yet. Note: I have no test-case for readSkewNode, so not sure about that one. Note: No fix for readBboxNode as I'm going to kick that out next. I tested with Blender (which has no textures) and Collada (which needs manual adaptions in .dae files as Irrlicht can't read libraries order independent, but that's another problem). cutealien 2019-02-11 21:54:31 +0000
  • 93c597a72d Remove the #undef's for standard functions. isdigit, isspace and isupper had #undef's before them. But our own replacement implementations are in a namespace, so there shouldn't be any conflicts. And if there are compile conflicts they should show that the wrong implementation is used, so we would want to see them. cutealien 2019-02-02 16:52:29 +0000
  • b5c99752aa Fix compiling on MinGW/gcc. cutealien 2019-02-02 16:25:20 +0000
  • 47cebab98f Add IColladaMeshWriter::setUnit to allow exporting a unit-to-meter-ratio and name. cutealien 2019-02-01 15:52:29 +0000
  • 6ef7f7c07f Collada writer no longer writes out trailing zeros in (most) float numbers. Writing might be slightly slower, but has to write less on disk on the other hand. So loading the files later on will be faster. cutealien 2019-01-31 19:59:26 +0000
  • 9f7be6e42d Fix compile warning. cutealien 2019-01-31 19:40:58 +0000
  • 9a04806c45 Add irr::string::eraseTrailingFloatZeros to kick out trailing 0's for strings generated from floats. cutealien 2019-01-31 19:02:14 +0000
  • ff54728feb Add some tests for string::findLastCharNotInList. All worked out, was just checking ;-) cutealien 2019-01-31 18:08:34 +0000
  • c504e7d598 Fix conversion to right-handed matrix in Collada writer. cutealien 2019-01-30 15:47:30 +0000
  • 39bf558a78 Fix .dae/Collada writer to export a right-handed coordinate system as expected by Collada. Note: Right now our Collada loader can no longer load the files we write correctly as it also has to be fixed. cutealien 2019-01-30 15:16:36 +0000
  • 680d8f285d Simplify code in collada mesh writer. (just making it easier to read to prepare for some other changes). cutealien 2019-01-29 16:34:52 +0000
  • 8a5b18ac23 Spelling fix. cutealien 2019-01-29 15:35:08 +0000
  • 17503ad305 Collada writer no longer handles first and second texture uv's different. (first one is probably correct once we fix the rest of coordinates to a right-handed system) cutealien 2019-01-29 14:55:58 +0000
  • 62aed60aa0 Reduce code in Collada writer by replacing some case-switches for types by casts. cutealien 2019-01-29 14:40:17 +0000
  • 43f75cbd9f Add function IColladaMeshWriter::SetParamNamesUV. A workaround for broken Collada importers which insist on specific names. Seems SketchUp insists on UV's being called "S" "T" or it won't show textures. cutealien 2019-01-28 16:05:39 +0000
  • e4d2156531 Fix compile warnings caused by collada writer change to c8. cutealien 2019-01-26 10:41:23 +0000
  • 2f127c2773 Switch Collada writer to utf8 xml's. Reasons are that it's more typical to use utf8 for xml's and that it allows SketchUp (which doesn't support xml's with wide-chars) can import our Colladas now. cutealien 2019-01-25 20:57:39 +0000
  • 391dd912bd Add IXMLWriterUTF8 to allow writing utf8/ansi XML's. utf8 is usually the default for XML anyway. cutealien 2019-01-25 19:35:53 +0000
  • f6da59daf3 IColladaMeshWriter::writeScene got an additional flag to decide if root should be written. Default stays as it was - a roots is written when it's not the SceneManager root. cutealien 2019-01-24 15:39:45 +0000
  • eb14f13b53 Fix compilation on OSX and prevent capturing mouse cursor when Window is not on top. This is Patch#319 from Artem Shoobovych (https://sourceforge.net/p/irrlicht/patches/319/) Untested on my side due to lack of testing system. cutealien 2019-01-23 12:42:10 +0000