diff --git a/bin/Win32-VisualStudio/readme.txt b/bin/Win32-VisualStudio/readme.txt new file mode 100644 index 00000000..d5c7b7b5 --- /dev/null +++ b/bin/Win32-VisualStudio/readme.txt @@ -0,0 +1,25 @@ +The Win32-VisualStudio version is currently (Irrlicht 1.8) compiled with VS 2010 using the Windows 7.1 SDK as platform toolset. +You might get the necessary Windows Platform SDK here: http://msdn.microsoft.com/en-us/windows/bb980924.aspx + +To link to that Irrlicht.dll you need to set platform toolset in your VS version to the same target or re-compile the Irrlicht.dll using another platform toolset. + +To re-compile Irrlicht for Win32-VisualStudio: +There are several project files for different VS versions in source/Irrlicht. +Irrlicht10.0.sln is for VS 2010 +Irrlicht11.0.sln is for VS 2012 +Irrlicht12.0.sln is for VS 2013 + +To compile Irrlicht + all examples and all tools check the BuildAllExamples_*.sln files in the examples folder. + +For newer VS versions you have update one of those projects (VS usually can do that automatically when you open an older solution file). + +Currently each of those solutions does set the platform toolset "Windows 7.1 SDK" (to be compatible to each other). +You might want to change that in the project settings and set it to your current version. +Make sure you use the same platform toolset in your application and in the engine. +Also when compiling examples each example has to use the same platform toolset as was used for the engine. + +Platform should be Win32 +Configuration is by default "Release" +But you can also chose "Debug" if you want Irrlicht with Debug information. +Static builds are possible but you have to additionally set the _IRR_STATIC_LIB_ define in the application when linking to a static Irrlicht.lib + diff --git a/bin/Win32-gcc/readme.txt b/bin/Win32-gcc/readme.txt new file mode 100644 index 00000000..f7294d9d --- /dev/null +++ b/bin/Win32-gcc/readme.txt @@ -0,0 +1,16 @@ +If you wish to compile Irrlicht for Win32-gcc you have several choices. + +1. You can work from within a MinGW shell. +Go to the folder source/Irrlicht and run the Makefile with: +make win32 +Examples can be build by going into the folder of the example (for example examples/01.HelloWorld) and running the Makefile with: +make all_win32 + +2. Use the Code::Blocks IDE +There is a project file called Irrlicht-gcc.cbp in source/Irrlicht to compile just the engine. +Be sure to select a Windows target like "Win32 - release - accurate math - dll" + +There is also Code::Blocks workspace file in the examples folder called BuildAllExamples.workspace +Again be sure to select a Windows target like "Win32 - release - accurate math - dll" +This workspace allows you to compile the engine together with all examples and tools. + diff --git a/bin/Win64-VisualStudio/readme.txt b/bin/Win64-VisualStudio/readme.txt index e2f88f47..063b5e71 100644 --- a/bin/Win64-VisualStudio/readme.txt +++ b/bin/Win64-VisualStudio/readme.txt @@ -1,3 +1,24 @@ -Sorry, I cannot provide procompiled binaries for Win64. -Please goto the \source directory, unzip the source.zip file -and compile them yourself, it will cost you about 3 minutes. :) \ No newline at end of file +The Win64-VisualStudio version is currently (Irrlicht 1.8) compiled with VS 2010 using the Windows 7.1 SDK as platform toolset. +You might get the necessary Windows Platform SDK here: http://msdn.microsoft.com/en-us/windows/bb980924.aspx + +To link to that Irrlicht.dll you need to set platform toolset in your VS version to the same target or re-compile the Irrlicht.dll using another platform toolset. + +To re-compile Irrlicht for Win32-VisualStudio: +There are several project files for different VS versions in source/Irrlicht. +Irrlicht10.0.sln is for VS 2010 +Irrlicht11.0.sln is for VS 2012 +Irrlicht12.0.sln is for VS 2013 + +To compile Irrlicht + all examples and all tools check the BuildAllExamples_*.sln files in the examples folder. + +For newer VS versions you have update one of those projects (VS usually can do that automatically when you open an older solution file). + +Currently each of those solutions does set the platform toolset "Windows 7.1 SDK" (to be compatible to each other). +You might want to change that in the project settings and set it to your current version. +Make sure you use the same platform toolset in your application and in the engine. +Also when compiling examples each example has to use the same platform toolset as was used for the engine. + +Platform should be Win64 +Configuration is by default "Release" +But you can also chose "Debug" if you want Irrlicht with Debug information. +Static builds are possible but you have to additionally set the _IRR_STATIC_LIB_ define in the application when linking to a static Irrlicht.lib diff --git a/changes.txt b/changes.txt index ecff8a64..8434095b 100644 --- a/changes.txt +++ b/changes.txt @@ -8,10 +8,14 @@ Changes in ogl-es (not yet released - will be merged with trunk at some point) -------------------------- Changes in 1.9 (not yet released) -- Several fixes for SceneNodeAnimatorCollisionResponse, based on http://irrlicht.sourceforge.net/forum/viewtopic.php?f=7&t=33098&p=290746 +- IWriteFile::write now returning size_t (like fwrite in c-lib). Also sizeToWrite parameter changed from u32 to size_t. +- IReadFile::read now returning size_t (like fread in c-lib). Also sizeToRead parameter changed from u32 to size_t. +- add clear function to strings. +- Collision manager now using const camera pointers. +- Several fixes for SceneNodeAnimatorCollisionResponse, based on http://irrlicht.sourceforge.net/forum/viewtopic.php?f=7&t=33098&p=290746 Thanks to all people who reported and to JLouisB and kinkreet for the patches: - Gravity is now fps independent - - Values of gravity now like documented (wasn't 1 unit = 1m before, had been 1m = current frames per second, so maybe 100 units = 1m). + - Values of gravity now like documented (wasn't 1 unit = 1m before, had been 1m = current frames per second, so maybe 100 units = 1m). Note that jump-values for fps-camera must also change when adapting gravity! Several examples got adapted for new ranges. - Pausing timer now pauses animator. Also doesn't reset values anymore with pauses. @@ -52,7 +56,7 @@ should now be fps independentn - Interface getMeshType moved from IAnimatedMesh up to IMesh. - Add b3d mesh-writer. Static writer written by Hendu, support for animated meshes added by JLouisB, testing and bugfixes by CuteAlien. - Node-collision functions of SceneCollisionManager like getSceneNodeFromScreenCoordinatesBB will now ignore collisions against empty boundingboxes. -- Cameras return again an empty boundingbox (at 0,0,0) instead of returning the frustum boundingbox (was changed in very old Irrlicht version). +- Cameras return again an empty boundingbox (at 0,0,0) instead of returning the frustum boundingbox (was changed in very old Irrlicht version). You can access the frustum boundingbox through the frustum itself. This means cameras no longer show up in the node-collision of the SceneCollisionManager (showing up there because of their frustum bounding-box was too confusing). - Fix problem in IrrlichtDevice::setResizable on X11 that caused window titlebars to hide occasionally under the taskbar in some systems (Ubuntu, Mint). @@ -61,8 +65,8 @@ should now be fps independentn - XBox support removed as it would need DX8 (this was about the original XBox). - Support for Direct3D 8 removed after svn revision 5052 due to lack of maintenance. - _IRR_IMPLEMENT_MANAGED_MARSHALLING_BUGFIX removed. This was a bugfix for VS2003 (in combination with .NET) which we haven't supported in a while. -- VS 2005 support removed after svn revision 5048. -- WinCE 6 supported removed after svn revision 5046. +- VS 2005 support removed after svn revision 5048. +- WinCE 6 supported removed after svn revision 5046. - NVidia CG support removed after svn revision 5045 due to lack of maintenance. NVidia has also stopped supporting this. - TA burningvideo: enabled triangle fan again so that skybox works.[need more testmeshes if other trianglefan than skybox doesn't work] @@ -154,7 +158,11 @@ should now be fps independentn - burningvideo: mipmaplevel adjusted ( not that bad bokeh...(sometimes) ) -------------------------- -Changes in 1.8.4 +Changes in 1.8.5 + - CImageLoaderJPG::isALoadableFileFormat uses a test which allows to load more jpg formats (for example uncompressed jpg's). Thx @Yaron Cohen-Tal for report, test-image and his help with the patch. + +-------------------------- +Changes in 1.8.4 (9th July 2016, svn r5321) - Tests on Unix now have a short pause between switching drivers to avoid certain X11 errors. - Fix CEnumAttribute::getInt() which could crash (thx @ luthyr for reporting) - No longer try to run tests for drivers not supported on a platform @@ -162,7 +170,7 @@ Changes in 1.8.4 - Deprecate CMatrix4::transformBox as the result is no longer a boundingbox. Use CMatrix4::transformBoxEx instead (which has been available for a long time). - Fix CSceneCollisionManager::getPickedNodeBB which could sometimes miss collisions. - Add -U__STRICT_ANSI__ option to c::b project files to allow compiling with -std=c++11 and add an error when trying to compile with Irrlicht with __STRICT_ANSI__ - - Update libpng to 1.6.21 + - Update libpng to 1.6.23 - Update zlib to 1.2.8 - Fix some compile warnings in aes which got handled as errors by some c++11 compilers. - Get rid of some misleading-indentation warnings in gcc6 @@ -658,7 +666,7 @@ Changes in 1.8 (7.11.2012) The following names can be queried for the given types: * MaxTextures (int) The maximum number of simultaneous textures supported by the driver. This can be less than the supported number of textures of the driver. Use _IRR_MATERIAL_MAX_TEXTURES_ to adapt the number. * MaxSupportedTextures (int) The maximum number of simultaneous textures supported by the fixed function pipeline of the (hw) driver. The actual supported number of textures supported by the engine can be lower. - * MaxLights (int) Number of hardware lights supported in the fixed function pipieline of the driver, typically 6-8. Use light manager or deferred shading for more. + * MaxLights (int) Number of hardware lights supported in the fixed function pipeline of the driver, typically 6-8. Use light manager or deferred shading for more. * MaxAnisotropy (int) Number of anisotropy levels supported for filtering. At least 1, max is typically at 16 or 32. * MaxUserClipPlanes (int) Number of additional clip planes, which can be set by the user via dedicated driver methods. * MaxAuxBuffers (int) Special render buffers, which are currently not really usable inside Irrlicht. Only supported by OpenGL @@ -1971,7 +1979,7 @@ Changes in 1.6 (23.09.2009) - Added support for Anti-Aliasing modes per material - - Added an ICollisionCallback to ISceneNodeAnimatorCollisionResponse, to inform the application that a collision has occured. Thanks to garrittg for this. + - Added an ICollisionCallback to ISceneNodeAnimatorCollisionResponse, to inform the application that a collision has occurred. Thanks to garrittg for this. - Added an startPosition parameter to createFlyCircleAnimator() to allow starting the animator at any position on the circle. @@ -2588,7 +2596,7 @@ Changes in version 1.4 (30 Nov 2007) to obtain an interface with which you can write out meshes. Currently, an own .irrmesh file format is supported as well as the COLLADA file format. - - fixed the keyboard autorepeat difference betwenn Linux and Windows. Thanks to denton we now have only KeyPressed events on both systems in case of autorepeat. + - fixed the keyboard autorepeat difference between Linux and Windows. Thanks to denton we now have only KeyPressed events on both systems in case of autorepeat. - Added several new particle emitters and affectors from IrrSpintz. Also some new getter and setter methods were added. @@ -3633,14 +3641,14 @@ Changes in version 0.12.0 (24 August 2005) to set the speed of the timer, a new time value, and to start and stop it. Also, all calls to getTime() will now return the same value within the same drawing frame. The timer will only advance when ITimer::tick() is called. IrrlichtDevice::run() will - call this method automaticly, but if you aren't using this method, and you are wondering + call this method automatically, but if you aren't using this method, and you are wondering why your scene is not animating anymore, just call Device->getTimer()->tick() before drawing your scene. If you need the system time, not the new virtual time, use ITimer::getRealTime(). - The material EMT_TRANSPARENT_ALPHA_CHANNEL now is using a configurable alpha ref value. The default value is 127, which means people who are using this material for drawing - things like grass, trees etc will get nice results automaticly when changing to 0.12.0. + things like grass, trees etc will get nice results automatically when changing to 0.12.0. To change to a different alpha ref value, just change SMaterial::MaterialTypeParam value. See EMT_TRANSPARENT_ALPHA_CHANNEL for details. Also, this fixes two bugs: @@ -3747,7 +3755,7 @@ Changes in version 0.11.0 (08 July 2005) - I'm no longer providing a Visual Studio 7.0 project/solution file for the Irrlicht Engine sourcecode, only 7.1 and 6.0 are supported. If you are using Visual Studio 7.0, - just open the .dsp file for Visual Studio 6.0, it will be converted automaticly. + just open the .dsp file for Visual Studio 6.0, it will be converted automatically. - Irrlicht.NET includes now all basic GUI Elements and can capture GUI events. There are still some features missing, but it is already enough to do simple things like showing @@ -3884,7 +3892,7 @@ Changes in version 0.10.0 (26 May 2005) - Added a new material type: EMT_TRANSPARENT_ALPHA_CHANNEL_REF. This draws a pixel of the material only when the alpha channel has a value greater than 128. It is ideal for drawing - for example leafes of plants and does not use alpha blending, so it is a lot faster than + for example leaves of plants and does not use alpha blending, so it is a lot faster than EMT_TRANSPARENT_ALPHA_CHANNEL. - There is now a createDeviceEx() method with which it is possible to create an Irrlicht Engine @@ -4276,7 +4284,7 @@ Changes in version 0.8 (19 Feb 2005) - The mixed fvf and vertex shader system in D3D8 caused a slight issue in Irrlicht ending up in really messed up render states sometimes. This is now fixed. -- A major bug with the OpenGL renderer which occured on some OpenGL implementations +- A major bug with the OpenGL renderer which occurred on some OpenGL implementations has been removed thanks to a bugfix by Murphy and a great report and some investigations by ElectroDruid. @@ -4339,7 +4347,7 @@ Changes in version 0.7: (11 Sep 2004) from C# and VisualBasic. - Low level vertex and pixel shader programming is now possible. There are - now some methods with wich you can write GPU programs in vertex/pixel shader assembler + now some methods with which you can write GPU programs in vertex/pixel shader assembler using Direct3D 8 and 9 and in ARB vertex and fragment program assembler for OpenGL. You can use the IGPUProgrammingServices interface which can be reached by IVideoDriver->getGPUProgrammingServices() for this. The new material types you can create @@ -4618,7 +4626,7 @@ Changes in version 0.5: (17 Feb 2004) linear/expontential) use IVideoDriver::setFog(); - With IrrlichtDevice::getOSOperator() a pointer to an interface is returned, with - wich it is possible to do some operation system specific operations. Currently + which it is possible to do some operation system specific operations. Currently there are only 3 methods supported, but more will be added in the future. - Mouse wheel input is now supported. @@ -4739,7 +4747,7 @@ Changes in version 0.4.2: (13 Dec 2003) - It is now possible to control what text is printed out to the console and the debug window of Visual Studio. By getting a pointer to the ILogger interface, is is possible to adjust if Warning, Error or Informational - texts should be printed out. In addition, now every text can be catched + texts should be printed out. In addition, now every text can be caught by the event receiver. - The engine is now capable of loading .PCX files. Only a few PCX formats @@ -4806,7 +4814,7 @@ Changes in version 0.4.2: (13 Dec 2003) - Linux support with multitexturing and mipmap generation has been improved. -- A bug was fixed wich caused the Engine not to run when compiled +- A bug was fixed which caused the Engine not to run when compiled as dynamic library under linux. Thanks to Shane Parker who pointed out the problem. @@ -4982,7 +4990,7 @@ Changes in version 0.4: (04 Sep 2003) - The addChild() method of the IAnimatedMeshSceneNode for adding SceneNodes to joints of skeletal animated meshes was removed. Instead there is now a new method: getMS3DJointNode(). This returns a pointer - to a child node, wich has the same transformation as the corrsesponding joint. + to a child node, which has the same transformation as the corresponding joint. In this way it is possible to do more advanced operations with joints and attaching scene nodes to joints. Also, the IAnimatedMeshMS3D interface now gives access to all joints. In this way, you can easily enumerate all names of all @@ -5022,7 +5030,7 @@ Changes in version 0.4: (04 Sep 2003) for making it possible to insert matrix transformations anywhere into the scene graph. -- Added a new SceneNode animator for deleting Scene nodes automaticly after some +- Added a new SceneNode animator for deleting Scene nodes automatically after some time. Create it with ISceneManager::createDeleteAnimator(). - The techdemo now is interactive. After a short non-interactive flight over @@ -5037,7 +5045,7 @@ Changes in version 0.4: (04 Sep 2003) wrong animations everywhere and the releasing of keys and mouse buttons was not sent as event. In addition, I placed a copy of the zlib.a and jpeglib.a into the /lib/Linux directory and changed the Makefiles of the examples and the source - of the engine for doing this automaticly in the future, so I hope there will be no + of the engine for doing this automatically in the future, so I hope there will be no problems with other versions of zlib and jpeglib anymore. - There are 2 new tutorials: One showing how to do collision detection and @@ -5102,7 +5110,7 @@ Changes in version 0.3: (18 Jul 2003) - Automatic culling has changed a little bit: It is now done by the SceneManager. Scene nodes now only need to return a valid, non transformed bounding box to be - culled automaticly. It is explaned in the CustomSceneNode Tutorial how this works. + culled automatically. It is explained in the CustomSceneNode Tutorial how this works. - It is now possible to use the engine easily for 2D graphics: There are now to new methods in the IVideoDriver, which create an 1bit alpha channel for textures diff --git a/doc/release_checklist.txt b/doc/release_checklist.txt index 3fa373c5..c228c921 100644 --- a/doc/release_checklist.txt +++ b/doc/release_checklist.txt @@ -50,7 +50,6 @@ RELEASING: Best create first a folder with a new name, copy stuff in there, test (just check the website), rename old folder and give new folder the "docu" name. Then you can delete the old folder if you want. -- - update changes.txt (also in /home/project-web/i/ir/irrlicht/htdocs) - - upload the zip by logging in to sourceforge and using the "Files" menu (needs admin privileges and it's the 'Files' menu between 'Summary' and 'Reviews'). The target is in one of the Irrlicht SDK subfolders. Then click the "i" beside diff --git a/examples/08.SpecialFX/main.cpp b/examples/08.SpecialFX/main.cpp index 5f0650c1..87a15163 100644 --- a/examples/08.SpecialFX/main.cpp +++ b/examples/08.SpecialFX/main.cpp @@ -6,7 +6,7 @@ surface scene node. We start like in some tutorials before. Please note that this time, the 'shadows' flag in createDevice() is set to true, for we want to have a dynamic -shadow casted from an animated character. If this example runs too slow, +shadow cast from an animated character. If this example runs too slow, set it to false. The Irrlicht Engine checks if your hardware doesn't support the stencil buffer, and disables shadows by itself, but just in case the demo runs slow on your hardware. @@ -236,7 +236,7 @@ int main() } /* - As our last special effect, we want a dynamic shadow be casted from an + As our last special effect, we want a dynamic shadow be cast from an animated character. For this we load a DirectX .x model and place it into our world. For creating the shadow, we simply need to call addShadowVolumeSceneNode(). The color of shadows is only adjustable diff --git a/examples/11.PerPixelLighting/main.cpp b/examples/11.PerPixelLighting/main.cpp index 337d4b3e..a4d8c5b0 100644 --- a/examples/11.PerPixelLighting/main.cpp +++ b/examples/11.PerPixelLighting/main.cpp @@ -270,7 +270,7 @@ int main() */ /* But just setting color and normal map is not everything. The - material we want to use needs some additional informations per + material we want to use needs some additional information per vertex like tangents and binormals. Because we are too lazy to calculate that information now, we let Irrlicht do this for us. That's why we call IMeshManipulator::createMeshWithTangents(). @@ -320,7 +320,7 @@ int main() //perform various task with the mesh manipulator scene::IMeshManipulator *manipulator = smgr->getMeshManipulator(); - // create mesh copy with tangent informations from original earth.x mesh + // create mesh copy with tangent information from original earth.x mesh scene::IMesh* tangentSphereMesh = manipulator->createMeshWithTangents(earthMesh->getMesh(0)); diff --git a/examples/23.SMeshHandling/main.cpp b/examples/23.SMeshHandling/main.cpp index 2baa1d95..2d413094 100644 --- a/examples/23.SMeshHandling/main.cpp +++ b/examples/23.SMeshHandling/main.cpp @@ -126,7 +126,7 @@ public: s is a scaling factor, which is necessary if the height units are different from the coordinate units; for example, if your map has - heights in metres and the coordinates are in units of a + heights in meters and the coordinates are in units of a kilometer. */ vector3df getnormal(u16 x, u16 y, f32 s) const @@ -201,7 +201,7 @@ public: const u32 mp = driver -> getMaximalPrimitiveCount(); Width = hm.width(); Height = hm.height(); - + const u32 sw = mp / (6 * Height); // the width of each piece u32 i=0; @@ -340,7 +340,7 @@ int main(int argc, char* argv[]) if(device == 0) return 1; - + IVideoDriver *driver = device->getVideoDriver(); ISceneManager *smgr = device->getSceneManager(); device->setWindowCaption(L"Irrlicht Example for SMesh usage."); diff --git a/examples/Demo/CMainMenu.cpp b/examples/Demo/CMainMenu.cpp index 3a41d120..7ad85415 100644 --- a/examples/Demo/CMainMenu.cpp +++ b/examples/Demo/CMainMenu.cpp @@ -107,7 +107,7 @@ bool CMainMenu::run(bool& outFullscreen, bool& outMusic, bool& outShadows, L"The Irrlicht Engine was written by me, Nikolaus Gebhardt. The models, "\ L"maps and textures were placed at my disposal by B.Collins, M.Cook and J.Marton. The music was created by "\ L"M.Rohde and is played back by irrKlang.\n"\ - L"For more informations, please visit the homepage of the Irrlicht engine:\nhttp://irrlicht.sourceforge.net"; + L"For more information, please visit the homepage of the Irrlicht engine:\nhttp://irrlicht.sourceforge.net"; guienv->addStaticText(text2, core::rect(10, 10, 230, 320), true, true, aboutTab); diff --git a/include/EDriverTypes.h b/include/EDriverTypes.h index f22f7646..9ad3cf47 100644 --- a/include/EDriverTypes.h +++ b/include/EDriverTypes.h @@ -15,7 +15,7 @@ namespace video //! An enum for all types of drivers the Irrlicht Engine supports. enum E_DRIVER_TYPE { - //! Null driver, useful for applications to run the engine without visualisation. + //! Null driver, useful for applications to run the engine without visualization. /** The null device is able to load textures, but does not render and display any graphics. */ EDT_NULL, @@ -62,8 +62,8 @@ namespace video //! No driver, just for counting the elements EDT_COUNT }; - - const c8* const DRIVER_TYPE_NAMES[] = + + const c8* const DRIVER_TYPE_NAMES[] = { "NullDriver", "Software Renderer", @@ -76,7 +76,7 @@ namespace video 0 }; - const c8* const DRIVER_TYPE_NAMES_SHORT[] = + const c8* const DRIVER_TYPE_NAMES_SHORT[] = { "null", "software", @@ -84,7 +84,7 @@ namespace video "d3d8", "d3d9", "opengl", - 0 + 0 }; } // end namespace video diff --git a/include/EMaterialTypes.h b/include/EMaterialTypes.h index 086ca345..513842f2 100644 --- a/include/EMaterialTypes.h +++ b/include/EMaterialTypes.h @@ -44,7 +44,7 @@ namespace video //! Material type with standard lightmap technique /** There should be 2 textures: The first texture layer is a diffuse map, the second is a light map. Dynamic light is - ignored. The texture colors are effectively multiplyied by 4 + ignored. The texture colors are effectively multiplied by 4 for brightening. Like known in DirectX as D3DTOP_MODULATE4X. */ EMT_LIGHTMAP_M4, @@ -61,7 +61,7 @@ namespace video /** The first texture is diffuse color map, the second is added to this and usually displayed with a bigger scale value so that it adds more detail. The detail map is added to the diffuse map - using ADD_SIGNED, so that it is possible to add and substract + using ADD_SIGNED, so that it is possible to add and subtract color from the diffuse map. For example a value of (127,127,127) will not change the appearance of the diffuse map at all. Often used for terrain rendering. */ @@ -105,7 +105,7 @@ namespace video pixel is written to the target, otherwise not. This material does not use alpha blending and is a lot faster than EMT_TRANSPARENT_ALPHA_CHANNEL. It is ideal for drawing - stuff like leafes of plants, because the borders are not + stuff like leaves of plants, because the borders are not blurry but sharp. Only first texture is used. If you are using this material with small textures and 3d object, it is a good idea to load the texture in 32 bit mode diff --git a/include/EMessageBoxFlags.h b/include/EMessageBoxFlags.h index 878db7f5..06468043 100644 --- a/include/EMessageBoxFlags.h +++ b/include/EMessageBoxFlags.h @@ -13,7 +13,7 @@ namespace gui //! enumeration for message box layout flags enum EMESSAGE_BOX_FLAG { - //! Flag for the ok button + //! Flag for the OK button EMBF_OK = 0x1, //! Flag for the cancel button diff --git a/include/EPrimitiveTypes.h b/include/EPrimitiveTypes.h index 6b082c14..bbd5d7fc 100644 --- a/include/EPrimitiveTypes.h +++ b/include/EPrimitiveTypes.h @@ -36,7 +36,7 @@ namespace scene //! Explicitly set all vertices for each triangle. EPT_TRIANGLES, - //! After the first two vertices each further tw vetices create a quad with the preceding two. + //! After the first two vertices each further two vertices create a quad with the preceding two. EPT_QUAD_STRIP, //! Every four vertices create a quad. diff --git a/include/ESceneNodeAnimatorTypes.h b/include/ESceneNodeAnimatorTypes.h index d3e0936a..f771d128 100644 --- a/include/ESceneNodeAnimatorTypes.h +++ b/include/ESceneNodeAnimatorTypes.h @@ -31,7 +31,7 @@ namespace scene //! Deletion scene node animator ESNAT_DELETION, - //! Collision respose scene node animator + //! Collision response scene node animator ESNAT_COLLISION_RESPONSE, //! FPS camera animator diff --git a/include/IAnimatedMesh.h b/include/IAnimatedMesh.h index d7dd77fe..b61065ce 100644 --- a/include/IAnimatedMesh.h +++ b/include/IAnimatedMesh.h @@ -56,7 +56,7 @@ namespace scene virtual IMesh* getMesh(s32 frame, s32 detailLevel=255, s32 startFrameLoop=-1, s32 endFrameLoop=-1) = 0; //! Returns the type of the animated mesh. - /** In most cases it is not neccessary to use this method. + /** In most cases it is not necessary to use this method. This is useful for making a safe downcast. For example, if getMeshType() returns EAMT_MD2 it's safe to cast the IAnimatedMesh to IAnimatedMeshMD2. diff --git a/include/IAnimatedMeshMD3.h b/include/IAnimatedMeshMD3.h index de825db1..08c897d0 100644 --- a/include/IAnimatedMeshMD3.h +++ b/include/IAnimatedMeshMD3.h @@ -287,7 +287,7 @@ namespace scene { public: - //! tune how many frames you want to render inbetween. + //! tune how many frames you want to render in between. virtual void setInterpolationShift(u32 shift, u32 loopMode) =0; //! get the tag list of the mesh. diff --git a/include/IAnimatedMeshSceneNode.h b/include/IAnimatedMeshSceneNode.h index 3ccd52dd..1652705c 100644 --- a/include/IAnimatedMeshSceneNode.h +++ b/include/IAnimatedMeshSceneNode.h @@ -42,7 +42,7 @@ namespace scene //! Will be called when the animation playback has ended. /** See IAnimatedMeshSceneNode::setAnimationEndCallback for - more informations. + more information. \param node: Node of which the animation has ended. */ virtual void OnAnimationEnd(IAnimatedMeshSceneNode* node) = 0; }; @@ -94,7 +94,7 @@ namespace scene /** The shadow can be rendered using the ZPass or the zfail method. ZPass is a little bit faster because the shadow volume creation is easier, but with this method there occur ugly - looking artifacs when the camera is inside the shadow volume. + looking artifacts when the camera is inside the shadow volume. These error do not occur with the ZFail method. \param shadowMesh: Optional custom mesh for shadow volume. \param id: Id of the shadow scene node. This id can be used to diff --git a/include/IAttributes.h b/include/IAttributes.h index 41101fee..283c9511 100644 --- a/include/IAttributes.h +++ b/include/IAttributes.h @@ -37,7 +37,7 @@ namespace io { class IXMLWriter; -//! Provides a generic interface for attributes and their values and the possiblity to serialize them +//! Provides a generic interface for attributes and their values and the possibility to serialize them class IAttributes : public virtual IReferenceCounted { public: @@ -734,7 +734,7 @@ public: */ - //! Adds an attribute as user pointner + //! Adds an attribute as user pointer virtual void addUserPointer(const c8* attributeName, void* userPointer) = 0; //! Sets an attribute as user pointer diff --git a/include/ICameraSceneNode.h b/include/ICameraSceneNode.h index e576256a..369d7847 100644 --- a/include/ICameraSceneNode.h +++ b/include/ICameraSceneNode.h @@ -152,7 +152,7 @@ namespace scene return IsOrthogonal; } - //! Binds the camera scene node's rotation to its target position and vice vera, or unbinds them. + //! Binds the camera scene node's rotation to its target position and vice versa, or unbinds them. /** When bound, calling setRotation() will update the camera's target position to be along its +Z axis, and likewise calling setTarget() will update its rotation so that its +Z axis will diff --git a/include/IColladaMeshWriter.h b/include/IColladaMeshWriter.h index c88b199c..8a9f779c 100644 --- a/include/IColladaMeshWriter.h +++ b/include/IColladaMeshWriter.h @@ -111,7 +111,7 @@ namespace scene virtual E_COLLADA_IRR_COLOR getColorMapping(const video::SMaterial & material, E_COLLADA_COLOR_SAMPLER cs) const = 0; //! Return custom colors for certain color types requested by collada. - /** Only used when getColorMapping returns ECIC_CUSTOM for the same paramters. */ + /** Only used when getColorMapping returns ECIC_CUSTOM for the same parameters. */ virtual video::SColor getCustomColor(const video::SMaterial & material, E_COLLADA_COLOR_SAMPLER cs) const = 0; //! Return the transparence color interpretation. @@ -268,10 +268,10 @@ namespace scene } //! Control when and how often a mesh is written - /** Optimally ECGI_PER_MESH would be always sufficent - writing geometry once per mesh. + /** Optimally ECGI_PER_MESH would be always sufficient - writing geometry once per mesh. Unfortunately many tools (at the time of writing this nearly all of them) have trouble on import when different materials are used per node. So when you override materials - per node and importing the resuling collada has materials problems in other tools try + per node and importing the resulting collada has materials problems in other tools try using other values here. \param writeStyle One of the E_COLLADA_GEOMETRY_WRITING settings. */ @@ -368,7 +368,7 @@ namespace scene protected: - // NOTE: You usually should also call setProperties with the same paraemter when using setDefaultProperties + // NOTE: You usually should also call setProperties with the same parameter when using setDefaultProperties virtual void setDefaultProperties(IColladaMeshWriterProperties * p) { if ( p == DefaultProperties ) @@ -380,7 +380,7 @@ namespace scene DefaultProperties = p; } - // NOTE: You usually should also call setNameGenerator with the same paraemter when using setDefaultProperties + // NOTE: You usually should also call setNameGenerator with the same parameter when using setDefaultProperties virtual void setDefaultNameGenerator(IColladaMeshWriterNames * p) { if ( p == DefaultNameGenerator ) diff --git a/include/IDynamicMeshBuffer.h b/include/IDynamicMeshBuffer.h index 72f20367..c4130ca1 100644 --- a/include/IDynamicMeshBuffer.h +++ b/include/IDynamicMeshBuffer.h @@ -144,14 +144,14 @@ namespace scene return getIndexBuffer().getType(); } - //! Get access to Indices. + //! Get access to indices. /** \return Pointer to indices array. */ virtual const u16* getIndices() const { return (u16*)getIndexBuffer().getData(); } - //! Get access to Indices. + //! Get access to indices. /** \return Pointer to indices array. */ virtual u16* getIndices() { diff --git a/include/IEventReceiver.h b/include/IEventReceiver.h index d967ef54..9fc94d93 100644 --- a/include/IEventReceiver.h +++ b/include/IEventReceiver.h @@ -71,7 +71,7 @@ namespace irr UserData1 and UserData2 members of the SUserEvent. Linux: send a ClientMessage via XSendEvent to the Irrlicht Window; the data.l[0] and data.l[1] members will be - casted to s32 and used as UserData1 and UserData2. + cast to s32 and used as UserData1 and UserData2. MacOS: Not yet implemented */ EET_USER_EVENT, @@ -239,7 +239,7 @@ namespace irr //! An element would like to close. /** Windows and context menus use this event when they would like to close, - this can be cancelled by absorbing the event. */ + this can be canceled by absorbing the event. */ EGET_ELEMENT_CLOSED, //! A button was clicked. diff --git a/include/IFileArchive.h b/include/IFileArchive.h index b55f3124..7c2ed866 100644 --- a/include/IFileArchive.h +++ b/include/IFileArchive.h @@ -14,7 +14,7 @@ namespace irr namespace io { -//! FileSystemType: which Filesystem should be used for e.g. browsing +//! FileSystemType: which filesystem should be used for e.g. browsing enum EFileSystemType { FILESYSTEM_NATIVE = 0, // Native OS FileSystem @@ -122,7 +122,7 @@ public: //! Check to see if the loader can create archives of this type. /** Check based on the archive type. \param fileType The archive type to check. - \return True if the archile loader supports this type, false if not */ + \return True if the archive loader supports this type, false if not */ virtual bool isALoadableFileFormat(E_FILE_ARCHIVE_TYPE fileType) const =0; //! Creates an archive from the filename diff --git a/include/IFileList.h b/include/IFileList.h index 4c2f8ea8..2d0af466 100644 --- a/include/IFileList.h +++ b/include/IFileList.h @@ -27,13 +27,13 @@ public: /** The path is not included in this name. Use getFullFileName for this. \param index is the zero based index of the file which name should be returned. The index must be less than the amount getFileCount() returns. - \return File name of the file. Returns 0, if an error occured. */ + \return File name of the file. Returns 0, if an error occurred. */ virtual const io::path& getFileName(u32 index) const = 0; //! Gets the full name of a file in the list including the path, based on an index. /** \param index is the zero based index of the file which name should be returned. The index must be less than the amount getFileCount() returns. - \return File name of the file. Returns 0 if an error occured. */ + \return File name of the file. Returns 0 if an error occurred. */ virtual const io::path& getFullFileName(u32 index) const = 0; //! Returns the size of a file in the file list, based on an index. diff --git a/include/IFileSystem.h b/include/IFileSystem.h index b9c27eb3..48e217ef 100644 --- a/include/IFileSystem.h +++ b/include/IFileSystem.h @@ -315,7 +315,7 @@ public: //! Determines if a file exists and could be opened. /** \param filename is the string identifying the file which should be tested for existence. - \return True if file exists, and false if it does not exist or an error occured. */ + \return True if file exists, and false if it does not exist or an error occurred. */ virtual bool existFile(const path& filename) const =0; //! Creates a XML Reader from a file which returns all parsed strings as wide characters (wchar_t*). diff --git a/include/IGPUProgrammingServices.h b/include/IGPUProgrammingServices.h index 596f0943..e5143a06 100644 --- a/include/IGPUProgrammingServices.h +++ b/include/IGPUProgrammingServices.h @@ -81,9 +81,9 @@ public: \param shaderLang a type of shading language used in current shader. \return Number of the material type which can be set in SMaterial::MaterialType to use the renderer. -1 is returned if an error - occured, e.g. if a shader program could not be compiled or a compile + occurred, e.g. if a shader program could not be compiled or a compile target is not reachable. The error strings are then printed to the - error log and can be catched with a custom event receiver. */ + error log and can be caught with a custom event receiver. */ virtual s32 addHighLevelShaderMaterial( const c8* vertexShaderProgram, const c8* vertexShaderEntryPointName, @@ -208,9 +208,9 @@ public: \param shaderLang a type of shading language used in current shader. \return Number of the material type which can be set in SMaterial::MaterialType to use the renderer. -1 is returned if an error - occured, e.g. if a shader program could not be compiled or a compile + occurred, e.g. if a shader program could not be compiled or a compile target is not reachable. The error strings are then printed to the - error log and can be catched with a custom event receiver. */ + error log and can be caught with a custom event receiver. */ virtual s32 addHighLevelShaderMaterialFromFiles( const io::path& vertexShaderProgramFileName, const c8* vertexShaderEntryPointName, @@ -333,9 +333,9 @@ public: \param shaderLang a type of shading language used in current shader. \return Number of the material type which can be set in SMaterial::MaterialType to use the renderer. -1 is returned if an - error occured, e.g. if a shader program could not be compiled or a + error occurred, e.g. if a shader program could not be compiled or a compile target is not reachable. The error strings are then printed to - the error log and can be catched with a custom event receiver. */ + the error log and can be caught with a custom event receiver. */ virtual s32 addHighLevelShaderMaterialFromFiles( io::IReadFile* vertexShaderProgram, const c8* vertexShaderEntryPointName, @@ -388,7 +388,7 @@ public: shader program. This can be 0 if no vertex program shall be used. For DX8 programs, the will always input registers look like this: v0: - position, v1: normal, v2: color, v3: texture cooridnates, v4: texture + position, v1: normal, v2: color, v3: texture coordinates, v4: texture coordinates 2 if available. For DX9 programs, you can manually set the registers using the dcl_ @@ -407,9 +407,9 @@ public: during the call. \return Returns the number of the material type which can be set in SMaterial::MaterialType to use the renderer. -1 is returned if an - error occured. -1 is returned for example if a vertex or pixel shader + error occurred. -1 is returned for example if a vertex or pixel shader program could not be compiled, the error strings are then printed out - into the error log, and can be catched with a custom event receiver. */ + into the error log, and can be caught with a custom event receiver. */ virtual s32 addShaderMaterial(const c8* vertexShaderProgram = 0, const c8* pixelShaderProgram = 0, IShaderConstantSetCallBack* callback = 0, @@ -431,9 +431,9 @@ public: during the call. \return Returns the number of the material type which can be set in SMaterial::MaterialType to use the renderer. -1 is returned if an - error occured. -1 is returned for example if a vertex or pixel shader + error occurred. -1 is returned for example if a vertex or pixel shader program could not be compiled, the error strings are then printed out - into the error log, and can be catched with a custom event receiver. */ + into the error log, and can be caught with a custom event receiver. */ virtual s32 addShaderMaterialFromFiles(io::IReadFile* vertexShaderProgram, io::IReadFile* pixelShaderProgram, IShaderConstantSetCallBack* callback = 0, @@ -456,9 +456,9 @@ public: during the call. \return Returns the number of the material type which can be set in SMaterial::MaterialType to use the renderer. -1 is returned if an - error occured. -1 is returned for example if a vertex or pixel shader + error occurred. -1 is returned for example if a vertex or pixel shader program could not be compiled, the error strings are then printed out - into the error log, and can be catched with a custom event receiver. */ + into the error log, and can be caught with a custom event receiver. */ virtual s32 addShaderMaterialFromFiles(const io::path& vertexShaderProgramFileName, const io::path& pixelShaderProgramFileName, IShaderConstantSetCallBack* callback = 0, diff --git a/include/IGUIComboBox.h b/include/IGUIComboBox.h index 72c41870..8d238341 100644 --- a/include/IGUIComboBox.h +++ b/include/IGUIComboBox.h @@ -62,7 +62,7 @@ namespace gui //! Set the maximal number of rows for the selection listbox virtual void setMaxSelectionRows(u32 max) = 0; - //! Get the maximimal number of rows for the selection listbox + //! Get the maximal number of rows for the selection listbox virtual u32 getMaxSelectionRows() const = 0; }; diff --git a/include/IGUIContextMenu.h b/include/IGUIContextMenu.h index c425e435..66237632 100644 --- a/include/IGUIContextMenu.h +++ b/include/IGUIContextMenu.h @@ -24,7 +24,7 @@ namespace gui //! call setVisible(false) ECMC_HIDE = 2 - // note to implementors - this is planned as bitset, so continue with 4 if you need to add further flags. + // note to implementers - this is planned as bitset, so continue with 4 if you need to add further flags. }; //! GUI Context menu interface. diff --git a/include/IGUIElement.h b/include/IGUIElement.h index 3b1316a6..d4edfe88 100644 --- a/include/IGUIElement.h +++ b/include/IGUIElement.h @@ -465,7 +465,7 @@ public: //! Returns true if element is enabled /** Currently elements do _not_ care about parent-states. - So if you want to affect childs you have to enable/disable them all. + So if you want to affect children you have to enable/disable them all. The only exception to this are sub-elements which also check their parent. */ virtual bool isEnabled() const @@ -728,7 +728,7 @@ public: you can overload this function and add a check for the type of the base-class additionally. This allows for checks comparable to the dynamic_cast of c++ with enabled rtti. Note that you can't do that by calling BaseClass::hasType(type), but you have to do an explicit - comparison check, because otherwise the base class usually just checks for the membervariable + comparison check, because otherwise the base class usually just checks for the member variable Type which contains the type of your derived class. */ virtual bool hasType(EGUI_ELEMENT_TYPE type) const @@ -1014,10 +1014,10 @@ protected: //! tooltip core::stringw ToolTipText; - //! users can set this for identificating the element by string + //! users can set this for identifying the element by string core::stringc Name; - //! users can set this for identificating the element by integer + //! users can set this for identifying the element by integer s32 ID; //! tab stop like in windows diff --git a/include/IGUIElementFactory.h b/include/IGUIElementFactory.h index 348038ab..a447c048 100644 --- a/include/IGUIElementFactory.h +++ b/include/IGUIElementFactory.h @@ -42,17 +42,17 @@ namespace gui //! Get amount of GUI element types this factory is able to create virtual s32 getCreatableGUIElementTypeCount() const = 0; - //! Get type of a createable element type + //! Get type of a creatable element type /** \param idx: Index of the element type in this factory. Must be a value between 0 and getCreatableGUIElementTypeCount() */ virtual EGUI_ELEMENT_TYPE getCreateableGUIElementType(s32 idx) const = 0; - //! Get type name of a createable GUI element type by index + //! Get type name of a creatable GUI element type by index /** \param idx: Index of the type in this factory. Must be a value between 0 and getCreatableGUIElementTypeCount() */ virtual const c8* getCreateableGUIElementTypeName(s32 idx) const = 0; - //! returns type name of a createable GUI element + //! returns type name of a creatable GUI element /** \param type: Type of GUI element. \return Name of the type if this factory can create the type, otherwise 0. */ virtual const c8* getCreateableGUIElementTypeName(EGUI_ELEMENT_TYPE type) const = 0; diff --git a/include/IGUIEnvironment.h b/include/IGUIEnvironment.h index 9618cdee..304c46ac 100644 --- a/include/IGUIEnvironment.h +++ b/include/IGUIEnvironment.h @@ -371,7 +371,7 @@ public: until this messagebox is removed. \param parent Parent gui element of the dialog. \param id Id to identify the gui element. - \param restoreCWD If set to true, the current workingn directory will be + \param restoreCWD If set to true, the current working directory will be restored after the dialog is closed in some way. Otherwise the working directory will be the one that the file dialog was last showing. \param startDir Optional path for which the file dialog will be opened. @@ -412,7 +412,7 @@ public: bool fillBackground = false) = 0; //! Adds an edit box. - /** Supports unicode input from every keyboard around the world, + /** Supports Unicode input from every keyboard around the world, scrolling, copying and pasting (exchanging data with the clipboard directly), maximum character amount, marking, and all shortcuts like ctrl+X, ctrl+V, ctrl+C, shift+Left, shift+Right, Home, End, and so on. diff --git a/include/IGUIImage.h b/include/IGUIImage.h index 09f46fdc..f9873aad 100644 --- a/include/IGUIImage.h +++ b/include/IGUIImage.h @@ -60,8 +60,8 @@ namespace gui //! Restrict drawing-area. /** This allows for example to use the image as a progress bar. Base for area is the image, which means: - - The original clippping area when the texture is scaled or there is no texture. - - The source-rect for an unscaled texture (but still restricted afterwards by the clipping area) + - The original clipping area when the texture is scaled or there is no texture. + - The source-rect for an unscaled texture (but still restricted afterward by the clipping area) Unlike normal clipping this does not affect the gui-children. \param drawBoundUVs: Coordinates between 0 and 1 where 0 are for left+top and 1 for right+bottom */ diff --git a/include/IGUIImageList.h b/include/IGUIImageList.h index f1f50c14..7f27a99e 100644 --- a/include/IGUIImageList.h +++ b/include/IGUIImageList.h @@ -24,7 +24,7 @@ public: //! Draws an image and clips it to the specified rectangle if wanted //! \param index: Index of the image //! \param destPos: Position of the image to draw - //! \param clip: Optional pointer to a rectalgle against which the text will be clipped. + //! \param clip: Optional pointer to a rectangle against which the text will be clipped. //! If the pointer is null, no clipping will be done. virtual void draw(s32 index, const core::position2d& destPos, const core::rect* clip = 0) = 0; diff --git a/include/IGUIListBox.h b/include/IGUIListBox.h index 227e4449..b76888c8 100644 --- a/include/IGUIListBox.h +++ b/include/IGUIListBox.h @@ -62,7 +62,7 @@ namespace gui virtual void removeItem(u32 index) = 0; //! get the the id of the item at the given absolute coordinates - /** \return The id of the listitem or -1 when no item is at those coordinates*/ + /** \return The id of the list item or -1 when no item is at those coordinates*/ virtual s32 getItemAt(s32 xpos, s32 ypos) const = 0; //! Returns the icon of an item diff --git a/include/IGUISpriteBank.h b/include/IGUISpriteBank.h index 74493d25..84816164 100644 --- a/include/IGUISpriteBank.h +++ b/include/IGUISpriteBank.h @@ -57,7 +57,7 @@ struct SGUISprite //! Sprite bank interface. -/** See http://irrlicht.sourceforge.net/phpBB2/viewtopic.php?t=25742&highlight=spritebank +/** See http://http://irrlicht.sourceforge.net/forum//viewtopic.php?f=9&t=25742 * for more information how to use the spritebank. */ class IGUISpriteBank : public virtual IReferenceCounted diff --git a/include/IGUIStaticText.h b/include/IGUIStaticText.h index 234e8d6d..b55bd95d 100644 --- a/include/IGUIStaticText.h +++ b/include/IGUIStaticText.h @@ -51,7 +51,7 @@ namespace gui /** \return: The override color */ virtual video::SColor getOverrideColor(void) const = 0; - //! Sets if the static text should use the overide color or the color in the gui skin. + //! Sets if the static text should use the override color or the color in the gui skin. /** \param enable: If set to true, the override color, which can be set with IGUIStaticText::setOverrideColor is used, otherwise the EGDC_BUTTON_TEXT color of the skin. */ diff --git a/include/IGUITabControl.h b/include/IGUITabControl.h index 58683873..9f7ace36 100644 --- a/include/IGUITabControl.h +++ b/include/IGUITabControl.h @@ -77,7 +77,7 @@ namespace gui virtual s32 getTabCount() const = 0; //! Returns a tab based on zero based index - /** \param idx: zero based index of tab. Is a value betwenn 0 and getTabcount()-1; + /** \param idx: zero based index of tab. Is a value between 0 and getTabcount()-1; \return Returns pointer to the Tab. Returns 0 if no tab is corresponding to this tab. */ virtual IGUITab* getTab(s32 idx) const = 0; diff --git a/include/IGUITable.h b/include/IGUITable.h index af8f981f..ea3afccc 100644 --- a/include/IGUITable.h +++ b/include/IGUITable.h @@ -94,7 +94,7 @@ namespace gui : IGUIElement(EGUIET_TABLE, environment, parent, id, rectangle) {} //! Adds a column - /** If columnIndex is outside the current range, do push new colum at the end */ + /** If columnIndex is outside the current range, do push new column at the end */ virtual void addColumn(const wchar_t* caption, s32 columnIndex=-1) = 0; //! remove a column from the table @@ -124,7 +124,7 @@ namespace gui //! columns can be resized by drag 'n drop virtual void setResizableColumns(bool resizable) = 0; - //! can columns be resized by dran 'n drop? + //! can columns be resized by drag 'n drop? virtual bool hasResizableColumns() const = 0; //! This tells the table control which ordering mode should be used when a column header is clicked. @@ -135,7 +135,7 @@ namespace gui //! Returns which row is currently selected virtual s32 getSelected() const = 0; - //! set wich row is currently selected + //! set which row is currently selected virtual void setSelected( s32 index ) = 0; //! Get amount of rows in the tabcontrol diff --git a/include/IGUITreeView.h b/include/IGUITreeView.h index e28cead9..8bcd824d 100644 --- a/include/IGUITreeView.h +++ b/include/IGUITreeView.h @@ -125,7 +125,7 @@ namespace gui void* data=0, IReferenceCounted* data2=0 ) =0; //! Adds a new node behind the other node. - /** The other node has also te be a child node from this node. + /** The other node has also to be a child node from this node. \param other Node to insert after \param text text of the new node \param icon icon text of the new node @@ -142,7 +142,7 @@ namespace gui void* data=0, IReferenceCounted* data2=0) =0; //! Adds a new node before the other node. - /** The other node has also te be a child node from this node. + /** The other node has also to be a child node from this node. \param other Node to insert before \param text text of the new node \param icon icon text of the new node @@ -188,11 +188,11 @@ namespace gui virtual bool deleteChild( IGUITreeViewNode* child ) = 0; //! Moves a child node one position up. - /** \return True if the node was found as achild node and was not already the first child. */ + /** \return True if the node was found as a child node and was not already the first child. */ virtual bool moveChildUp( IGUITreeViewNode* child ) = 0; //! Moves a child node one position down. - /** \return True if the node was found as achild node and was not already the last child. */ + /** \return True if the node was found as a child node and was not already the last child. */ virtual bool moveChildDown( IGUITreeViewNode* child ) = 0; //! Returns true if the node is expanded (children are visible). @@ -220,8 +220,8 @@ namespace gui //! Default tree view GUI element. - /** Displays a windows like tree buttons to expand/collaps the child - nodes of an node and optional tree lines. Each node consits of an + /** Displays a windows like tree buttons to expand/collapse the child + nodes of an node and optional tree lines. Each node consists of an text, an icon text and a void pointer for user data. */ class IGUITreeView : public IGUIElement { diff --git a/include/IImage.h b/include/IImage.h index 01057518..e034285a 100644 --- a/include/IImage.h +++ b/include/IImage.h @@ -169,7 +169,7 @@ public: } //! Use this to get a pointer to the image data. - /** + /** \return Pointer to the image data. What type of data is pointed to depends on the color format of the image. For example if the color format is ECF_A8R8G8B8, it is of u32. */ @@ -207,7 +207,7 @@ public: image. \param data A byte array with pixel color information \param ownForeignMemory If true, the image will use the data - pointer directly and own it afterwards. If false, the memory + pointer directly and own it afterward. If false, the memory will by copied internally. \param deleteMemory Whether the memory is deallocated upon destruction. */ @@ -283,7 +283,7 @@ public: const core::rect& sourceRect, const SColor &color, const core::rect* clipRect = 0) =0; - //! copies this surface into another, scaling it to fit, appyling a box filter + //! copies this surface into another, scaling it to fit, applying a box filter virtual void copyToScalingBoxFilter(IImage* target, s32 bias = 0, bool blend = false) = 0; //! fills the surface with given color diff --git a/include/IMaterialRenderer.h b/include/IMaterialRenderer.h index 145782a0..2f0c07d3 100644 --- a/include/IMaterialRenderer.h +++ b/include/IMaterialRenderer.h @@ -19,7 +19,7 @@ class IMaterialRendererServices; //! Interface for material rendering. /** Can be used to extend the engine with new materials. Refer to -IVideoDriver::addMaterialRenderer() for more informations on how to extend the +IVideoDriver::addMaterialRenderer() for more information on how to extend the engine with new materials. */ class IMaterialRenderer : public virtual IReferenceCounted { @@ -57,13 +57,13 @@ public: material set. This method will be called every time. This is useful for example for materials with shaders, which don't only set new renderstates but also shader constants. - \param service: Pointer to interface providing methos for setting + \param service: Pointer to interface providing methods for setting constants and other things. \param vtxtype: Vertex type with which the next rendering will be done. This can be used by the material renderer to set some specific optimized shaders or if this is an incompatible vertex type for this renderer, to refuse rendering for example. - \return Returns true if everything is ok, and false if nothing should + \return Returns true if everything is OK, and false if nothing should be rendered. The material renderer can choose to return false for example if he doesn't support the specified vertex type. This is actually done in D3D9 when using a normal mapped material with @@ -76,7 +76,7 @@ public: virtual void OnUnsetMaterial() {} //! Returns if the material is transparent. - /** The scene managment needs to know this + /** The scene management needs to know this for being able to sort the materials by opaque and transparent. */ virtual bool isTransparent() const { return false; } diff --git a/include/IMesh.h b/include/IMesh.h index 1650e595..93739a87 100644 --- a/include/IMesh.h +++ b/include/IMesh.h @@ -55,12 +55,12 @@ namespace scene //! generic skinned mesh EAMT_SKINNED, - + //! generig non-animated mesh EAMT_STATIC }; - - + + class IMeshBuffer; //! Class which holds the geometry of an object. @@ -105,7 +105,7 @@ namespace scene //! Set the hardware mapping hint /** This methods allows to define optimization hints for the hardware. This enables, e.g., the use of hardware buffers on - pltforms that support this feature. This can lead to noticeable + platforms that support this feature. This can lead to noticeable performance gains. */ virtual void setHardwareMappingHint(E_HARDWARE_MAPPING newMappingHint, E_BUFFER_TYPE buffer=EBT_VERTEX_AND_INDEX) = 0; @@ -114,11 +114,11 @@ namespace scene indices have changed. Otherwise, changes won't be updated on the GPU in the next render cycle. */ virtual void setDirty(E_BUFFER_TYPE buffer=EBT_VERTEX_AND_INDEX) = 0; - + //! Returns the type of the meshes. /** This is useful for making a safe downcast. For example, if getMeshType() returns EAMT_MD2 it's safe to cast the - IMesh to IAnimatedMeshMD2. + IMesh to IAnimatedMeshMD2. Note: It's no longer just about animated meshes, that name has just historical reasons. \returns Type of the mesh */ virtual E_ANIMATED_MESH_TYPE getMeshType() const diff --git a/include/IMeshBuffer.h b/include/IMeshBuffer.h index 44b865b8..44bcf27a 100644 --- a/include/IMeshBuffer.h +++ b/include/IMeshBuffer.h @@ -25,7 +25,7 @@ namespace scene Some mesh buffer implementations have limitations on the number of vertices the buffer can hold. In that case, logical grouping can help. Moreover, the number of vertices should be optimized for the GPU upload, - which often depends on the type of gfx card. Typial figures are + which often depends on the type of gfx card. Typical figures are 1000-10000 vertices per buffer. SMeshBuffer is a simple implementation of a MeshBuffer, which supports up to 65535 vertices. @@ -70,11 +70,11 @@ namespace scene /** \return Index type of this buffer. */ virtual video::E_INDEX_TYPE getIndexType() const =0; - //! Get access to Indices. + //! Get access to indices. /** \return Pointer to indices array. */ virtual const u16* getIndices() const = 0; - //! Get access to Indices. + //! Get access to indices. /** \return Pointer to indices array. */ virtual u16* getIndices() = 0; diff --git a/include/IMeshLoader.h b/include/IMeshLoader.h index b77419f4..f81f3307 100644 --- a/include/IMeshLoader.h +++ b/include/IMeshLoader.h @@ -70,7 +70,7 @@ public: } } - //! Get the texture loader used when this meshloder searches for textures. + //! Get the texture loader used when this meshloader searches for textures. /** NOTE: not all meshloaders support this interface so this can return NULL. */ virtual IMeshTextureLoader* getMeshTextureLoader() const diff --git a/include/IMeshManipulator.h b/include/IMeshManipulator.h index b48b336f..3dbbccc4 100644 --- a/include/IMeshManipulator.h +++ b/include/IMeshManipulator.h @@ -314,7 +314,7 @@ namespace scene - it's intended to be lossless - it has special care for the borders, which are useful with heightmap tiles - This function is thread-safe. Remember to weld afterwards - this + This function is thread-safe. Remember to weld afterward - this function only moves vertices, it does not weld. \param mb Meshbuffer to operate on. diff --git a/include/IMeshSceneNode.h b/include/IMeshSceneNode.h index fdffc03e..2fc70396 100644 --- a/include/IMeshSceneNode.h +++ b/include/IMeshSceneNode.h @@ -42,7 +42,7 @@ public: /** The shadow can be rendered using the ZPass or the zfail method. ZPass is a little bit faster because the shadow volume creation is easier, but with this method there occur ugly - looking artifacs when the camera is inside the shadow volume. + looking artifacts when the camera is inside the shadow volume. These error do not occur with the ZFail method. \param shadowMesh: Optional custom mesh for shadow volume. \param id: Id of the shadow scene node. This id can be used to diff --git a/include/IMeshWriter.h b/include/IMeshWriter.h index f7c1820a..8394c922 100644 --- a/include/IMeshWriter.h +++ b/include/IMeshWriter.h @@ -38,13 +38,13 @@ namespace scene /** \param file File handle to write the mesh to. \param mesh Pointer to mesh to be written. \param flags Optional flags to set properties of the writer. - \return True if sucessful */ + \return True if successful */ virtual bool writeMesh(io::IWriteFile* file, scene::IMesh* mesh, s32 flags=EMWF_NONE) = 0; // Writes an animated mesh // for future use, only b3d writer is able to write animated meshes currently and that was implemented using the writeMesh above. - /* \return Returns true if sucessful */ + /* \return Returns true if successful */ //virtual bool writeAnimatedMesh(io::IWriteFile* file, // scene::IAnimatedMesh* mesh, // s32 flags=EMWF_NONE) = 0; diff --git a/include/IOSOperator.h b/include/IOSOperator.h index 22fb691e..2ba04172 100644 --- a/include/IOSOperator.h +++ b/include/IOSOperator.h @@ -11,7 +11,7 @@ namespace irr { -//! The Operating system operator provides operation system specific methods and informations. +//! The Operating system operator provides operation system specific methods and information. class IOSOperator : public virtual IReferenceCounted { public: diff --git a/include/IParticleEmitter.h b/include/IParticleEmitter.h index 907cf7ba..4e54e85d 100644 --- a/include/IParticleEmitter.h +++ b/include/IParticleEmitter.h @@ -40,13 +40,13 @@ const c8* const ParticleEmitterTypeNames[] = }; //! A particle emitter for using with particle systems. -/** A Particle emitter emitts new particles into a particle system. +/** A Particle emitter emits new particles into a particle system. */ class IParticleEmitter : public virtual io::IAttributeExchangingObject { public: - //! Prepares an array with new particles to emitt into the system + //! Prepares an array with new particles to emit into the system /** \param now Current time. \param timeSinceLastCall Time elapsed since last call, in milliseconds. \param outArray Pointer which will point to the array with the new diff --git a/include/IParticleSystemSceneNode.h b/include/IParticleSystemSceneNode.h index 1a776159..b124cbc5 100644 --- a/include/IParticleSystemSceneNode.h +++ b/include/IParticleSystemSceneNode.h @@ -23,7 +23,7 @@ namespace irr namespace scene { -//! A particle system scene node for creating snow, fire, exlosions, smoke... +//! A particle system scene node for creating snow, fire, explosions, smoke... /** A scene node controlling a particle System. The behavior of the particles can be controlled by setting the right particle emitters and affectors. You can for example easily create a campfire by doing this: @@ -196,7 +196,7 @@ public: \return Pointer to the created particle emitter. To set this emitter as new emitter of this particle system, just call setEmitter(). Note that you'll have to drop() the returned pointer, after you don't need - it any more, see IReferenceCounted::drop() for more informations. */ + it any more, see IReferenceCounted::drop() for more information. */ virtual IParticleAnimatedMeshSceneNodeEmitter* createAnimatedMeshSceneNodeEmitter( scene::IAnimatedMeshSceneNode* node, bool useNormalDirection = true, const core::vector3df& direction = core::vector3df(0.0f,0.03f,0.0f), @@ -236,7 +236,7 @@ public: \return Pointer to the created particle emitter. To set this emitter as new emitter of this particle system, just call setEmitter(). Note that you'll have to drop() the returned pointer, after you don't need - it any more, see IReferenceCounted::drop() for more informations. */ + it any more, see IReferenceCounted::drop() for more information. */ virtual IParticleBoxEmitter* createBoxEmitter( const core::aabbox3df& box = core::aabbox3df(-10,28,-10,10,30,10), const core::vector3df& direction = core::vector3df(0.0f,0.03f,0.0f), @@ -280,7 +280,7 @@ public: \return Pointer to the created particle emitter. To set this emitter as new emitter of this particle system, just call setEmitter(). Note that you'll have to drop() the returned pointer, after you don't need - it any more, see IReferenceCounted::drop() for more informations. */ + it any more, see IReferenceCounted::drop() for more information. */ virtual IParticleCylinderEmitter* createCylinderEmitter( const core::vector3df& center, f32 radius, const core::vector3df& normal, f32 length, @@ -336,7 +336,7 @@ public: \return Pointer to the created particle emitter. To set this emitter as new emitter of this particle system, just call setEmitter(). Note that you'll have to drop() the returned pointer, after you don't need - it any more, see IReferenceCounted::drop() for more informations. */ + it any more, see IReferenceCounted::drop() for more information. */ virtual IParticleMeshEmitter* createMeshEmitter( scene::IMesh* mesh, bool useNormalDirection = true, const core::vector3df& direction = core::vector3df(0.0f,0.03f,0.0f), @@ -375,7 +375,7 @@ public: \return Pointer to the created particle emitter. To set this emitter as new emitter of this particle system, just call setEmitter(). Note that you'll have to drop() the returned pointer, after you don't need - it any more, see IReferenceCounted::drop() for more informations. */ + it any more, see IReferenceCounted::drop() for more information. */ virtual IParticlePointEmitter* createPointEmitter( const core::vector3df& direction = core::vector3df(0.0f,0.03f,0.0f), u32 minParticlesPerSecond = 5, @@ -417,7 +417,7 @@ public: \return Pointer to the created particle emitter. To set this emitter as new emitter of this particle system, just call setEmitter(). Note that you'll have to drop() the returned pointer, after you don't need - it any more, see IReferenceCounted::drop() for more informations. */ + it any more, see IReferenceCounted::drop() for more information. */ virtual IParticleRingEmitter* createRingEmitter( const core::vector3df& center, f32 radius, f32 ringThickness, const core::vector3df& direction = core::vector3df(0.0f,0.03f,0.0f), @@ -457,7 +457,7 @@ public: \return Pointer to the created particle emitter. To set this emitter as new emitter of this particle system, just call setEmitter(). Note that you'll have to drop() the returned pointer, after you don't need - it any more, see IReferenceCounted::drop() for more informations. */ + it any more, see IReferenceCounted::drop() for more information. */ virtual IParticleSphereEmitter* createSphereEmitter( const core::vector3df& center, f32 radius, const core::vector3df& direction = core::vector3df(0.0f,0.03f,0.0f), @@ -487,7 +487,7 @@ public: \return Pointer to the created particle affector. To add this affector as new affector of this particle system, just call addAffector(). Note that you'll have to drop() the returned pointer, after you don't need - it any more, see IReferenceCounted::drop() for more informations. */ + it any more, see IReferenceCounted::drop() for more information. */ virtual IParticleAttractionAffector* createAttractionAffector( const core::vector3df& point, f32 speed = 1.0f, bool attract = true, bool affectX = true, bool affectY = true, bool affectZ = true) = 0; @@ -510,12 +510,12 @@ public: targetColor is video::SColor(0,0,0,0): Particles are fading out into void with this setting. \param targetColor: Color whereto the color of the particle is changed. - \param timeNeededToFadeOut: How much time in milli seconds should the + \param timeNeededToFadeOut: How much time in milliseconds should the affector need to change the color to the targetColor. \return Pointer to the created particle affector. To add this affector as new affector of this particle system, just call addAffector(). Note that you'll have to drop() the returned pointer, after you don't need - it any more, see IReferenceCounted::drop() for more informations. */ + it any more, see IReferenceCounted::drop() for more information. */ virtual IParticleFadeOutAffector* createFadeOutParticleAffector( const video::SColor& targetColor = video::SColor(0,0,0,0), u32 timeNeededToFadeOut = 1000) = 0; @@ -523,16 +523,16 @@ public: //! Creates a gravity affector. /** This affector modifies the direction of the particle. It assumes that the particle is fired out of the emitter with huge force, but is - loosing this after some time and is catched by the gravity then. This + loosing this after some time and is caught by the gravity then. This affector is ideal for creating things like fountains. \param gravity: Direction and force of gravity. - \param timeForceLost: Time in milli seconds when the force of the + \param timeForceLost: Time in milliseconds when the force of the emitter is totally lost and the particle does not move any more. This is the time where gravity fully affects the particle. \return Pointer to the created particle affector. To add this affector as new affector of this particle system, just call addAffector(). Note that you'll have to drop() the returned pointer, after you don't need - it any more, see IReferenceCounted::drop() for more informations. */ + it any more, see IReferenceCounted::drop() for more information. */ virtual IParticleGravityAffector* createGravityAffector( const core::vector3df& gravity = core::vector3df(0.0f,-0.03f,0.0f), u32 timeForceLost = 1000) = 0; @@ -545,7 +545,7 @@ public: \return Pointer to the created particle affector. To add this affector as new affector of this particle system, just call addAffector(). Note that you'll have to drop() the returned pointer, after you don't need - it any more, see IReferenceCounted::drop() for more informations. */ + it any more, see IReferenceCounted::drop() for more information. */ virtual IParticleRotationAffector* createRotationAffector( const core::vector3df& speed = core::vector3df(5.0f,5.0f,5.0f), const core::vector3df& pivotPoint = core::vector3df(0.0f,0.0f,0.0f) ) = 0; diff --git a/include/IReadFile.h b/include/IReadFile.h index eeae96ba..790a1ae5 100644 --- a/include/IReadFile.h +++ b/include/IReadFile.h @@ -13,7 +13,7 @@ namespace irr namespace io { - //! Interface providing read acess to a file. + //! Interface providing read access to a file. class IReadFile : public virtual IReferenceCounted { public: @@ -21,7 +21,7 @@ namespace io /** \param buffer Pointer to buffer where read bytes are written to. \param sizeToRead Amount of bytes to read from the file. \return How many bytes were read. */ - virtual s32 read(void* buffer, u32 sizeToRead) = 0; + virtual size_t read(void* buffer, size_t sizeToRead) = 0; //! Changes position in file /** \param finalPos Destination position in the file. diff --git a/include/ISceneCollisionManager.h b/include/ISceneCollisionManager.h index 75c837f9..e43f1381 100644 --- a/include/ISceneCollisionManager.h +++ b/include/ISceneCollisionManager.h @@ -61,7 +61,7 @@ namespace scene \param hitPosition: Return value for the position of the collision \param outFalling: Is set to true if the ellipsoid is falling down, caused by gravity. - \param outNode: the node with which the ellipoid collided (if any) + \param outNode: the node with which the ellipsoid collided (if any) \param slidingSpeed: DOCUMENTATION NEEDED. \param gravityDirectionAndSpeed: Direction and force of gravity. \return New position of the ellipsoid. */ @@ -78,15 +78,15 @@ namespace scene const core::vector3df& gravityDirectionAndSpeed = core::vector3df(0.0f, 0.0f, 0.0f)) = 0; - //! Returns a 3d ray which would go through the 2d screen coodinates. + //! Returns a 3d ray which would go through the 2d screen coordinates. /** \param pos: Screen coordinates in pixels. \param camera: Camera from which the ray starts. If null, the active camera is used. \return Ray starting from the position of the camera and ending at a length of the far value of the camera at a position which - would be behind the 2d screen coodinates. */ + would be behind the 2d screen coordinates. */ virtual core::line3d getRayFromScreenCoordinates( - const core::position2d& pos, ICameraSceneNode* camera = 0) = 0; + const core::position2d& pos, const ICameraSceneNode* camera = 0) = 0; //! Calculates 2d screen position from a 3d position. /** \param pos: 3D position in world space to be transformed @@ -104,9 +104,9 @@ namespace scene method for drawing a decorator over a 3d object, it will be clipped by the screen borders. */ virtual core::position2d getScreenCoordinatesFrom3DPosition( - const core::vector3df& pos, ICameraSceneNode* camera=0, bool useViewPort=false) = 0; + const core::vector3df& pos, const ICameraSceneNode* camera=0, bool useViewPort=false) = 0; - //! Gets the scene node, which is currently visible under the given screencoordinates, viewed from the currently active camera. + //! Gets the scene node, which is currently visible under the given screen coordinates, viewed from the currently active camera. /** The collision tests are done using a bounding box for each scene node. You can limit the recursive search so just all children of the specified root are tested. \param pos: Position in pixel screen coordinates, under which @@ -142,11 +142,11 @@ namespace scene s32 idBitMask=0, bool bNoDebugObjects=false, ISceneNode* root=0) =0; //! Get the scene node, which the given camera is looking at and whose id matches the bitmask. - /** A ray is simply casted from the position of the camera to + /** A ray is simply cast from the position of the camera to the view target position, and all scene nodes are tested against this ray. The collision tests are done using a bounding box for each scene node. - \param camera: Camera from which the ray is casted. + \param camera: Camera from which the ray is cast. \param idBitMask: Only scene nodes with an id which matches at least one of the bits contained in this mask will be tested. However, if this parameter is 0, then all nodes are checked. @@ -158,13 +158,13 @@ namespace scene \return Scene node nearest to the camera, which collides with the ray and matches the idBitMask, if the mask is not null. If no scene node is found, 0 is returned. */ - virtual ISceneNode* getSceneNodeFromCameraBB(ICameraSceneNode* camera, + virtual ISceneNode* getSceneNodeFromCameraBB(const ICameraSceneNode* camera, s32 idBitMask=0, bool bNoDebugObjects = false) = 0; - //! Perform a ray/box and ray/triangle collision check on a heirarchy of scene nodes. + //! Perform a ray/box and ray/triangle collision check on a hierarchy of scene nodes. /** This checks all scene nodes under the specified one, first by ray/bounding box, and then by accurate ray/triangle collision, finding the nearest collision, - and the scene node containg it. It returns the node hit, and (via output + and the scene node containing it. It returns the node hit, and (via output parameters) the position of the collision, and the triangle that was hit. All scene nodes in the hierarchy tree under the specified node are checked. Only diff --git a/include/ISceneManager.h b/include/ISceneManager.h index b19b4134..e94f915e 100644 --- a/include/ISceneManager.h +++ b/include/ISceneManager.h @@ -129,14 +129,14 @@ namespace scene struct IShader; } // end namespace quake3 - //! The Scene Manager manages scene nodes, mesh recources, cameras and all the other stuff. + //! The Scene Manager manages scene nodes, mesh resources, cameras and all the other stuff. /** All Scene nodes can be created only here. There is a always growing list of scene nodes for lots of purposes: Indoor rendering scene nodes like the Octree (addOctreeSceneNode()) or the terrain renderer (addTerrainSceneNode()), different Camera scene nodes (addCameraSceneNode(), addCameraSceneNodeMaya()), scene nodes for Light (addLightSceneNode()), Billboards (addBillboardSceneNode()) and so on. - A scene node is a node in the hierachical scene graph. Every scene node + A scene node is a node in the hierarchical scene graph. Every scene node may have children, which are other scene nodes. Children move relative the their parents position. If the parent of a node is not visible, its children won't be visible, too. In this way, it is for example easily @@ -236,7 +236,7 @@ namespace scene * loader, I just changed some parts of it. Thanks to * Salvatore for his work and for allowing me to use his * code in Irrlicht and put it under Irrlicht's license. - * For newer and more enchanced versions of the loader, + * For newer and more enhanced versions of the loader, * take a look at delgine.com. * * @@ -281,7 +281,7 @@ namespace scene * Milkshape (.ms3d) * .MS3D files contain models and sometimes skeletal * animations from the Milkshape 3D modeling and animation - * software. Like the other skeletal mesh loaders, oints + * software. Like the other skeletal mesh loaders, joints * are exposed via the ISkinnedMesh animated mesh type. * * @@ -392,7 +392,7 @@ namespace scene IReferenceCounted::drop() for more information. */ virtual IAnimatedMesh* getMesh(io::IReadFile* file) = 0; - //! Get interface to the mesh cache which is shared beween all existing scene managers. + //! Get interface to the mesh cache which is shared between all existing scene managers. /** With this interface, it is possible to manually add new loaded meshes (if ISceneManager::getMesh() is not sufficient), to remove them and to iterate through already loaded meshes. */ @@ -441,7 +441,7 @@ namespace scene \param id: Id of the node. This id can be used to identify the scene node. \param position: Position of the space relative to its parent where the scene node will be placed. - \param rotation: Initital rotation of the scene node. + \param rotation: Initial rotation of the scene node. \param scale: Initial scale of the scene node. \return Pointer to the created test scene node. This pointer should not be dropped. See IReferenceCounted::drop() @@ -461,7 +461,7 @@ namespace scene \param id: Id of the node. This id can be used to identify the scene node. \param position: Position of the space relative to its parent where the scene node will be placed. - \param rotation: Initital rotation of the scene node. + \param rotation: Initial rotation of the scene node. \param scale: Initial scale of the scene node. \return Pointer to the created test scene node. This pointer should not be dropped. See IReferenceCounted::drop() @@ -478,7 +478,7 @@ namespace scene \param id: Id of the node. This id can be used to identify the scene node. \param position: Position of the space relative to its parent where the scene node will be placed. - \param rotation: Initital rotation of the scene node. + \param rotation: Initial rotation of the scene node. \param scale: Initial scale of the scene node. \param alsoAddIfMeshPointerZero: Add the scene node even if a 0 pointer is passed. \return Pointer to the created scene node. @@ -496,7 +496,7 @@ namespace scene \param id: Id of the node. This id can be used to identify the scene node. \param position: Position of the space relative to its parent where the scene node will be placed. - \param rotation: Initital rotation of the scene node. + \param rotation: Initial rotation of the scene node. \param scale: Initial scale of the scene node. \param alsoAddIfMeshPointerZero: Add the scene node even if a 0 pointer is passed. \return Pointer to the created scene node. @@ -512,13 +512,13 @@ namespace scene is used. \param waveHeight: Height of the water waves. \param waveSpeed: Speed of the water waves. - \param waveLength: Lenght of a water wave. + \param waveLength: Length of a water wave. \param mesh: Pointer to the loaded static mesh to be displayed with water waves on it. \param parent: Parent of the scene node. Can be NULL if no parent. \param id: Id of the node. This id can be used to identify the scene node. \param position: Position of the space relative to its parent where the scene node will be placed. - \param rotation: Initital rotation of the scene node. + \param rotation: Initial rotation of the scene node. \param scale: Initial scale of the scene node. \return Pointer to the created scene node. This pointer should not be dropped. See IReferenceCounted::drop() for more information. */ @@ -532,7 +532,7 @@ namespace scene //! Adds a scene node for rendering using a octree to the scene graph. /** This a good method for rendering - scenes with lots of geometry. The Octree is built on the fly from the mesh. + scenes with lots of geometry. The octree is built on the fly from the mesh. \param mesh: The mesh containing all geometry from which the octree will be build. If this animated mesh has more than one frames in it, the first frame is taken. \param parent: Parent node of the octree node. @@ -541,7 +541,7 @@ namespace scene If a node gets less polys than this value it will not be split into smaller nodes. \param alsoAddIfMeshPointerZero: Add the scene node even if a 0 pointer is passed. - \return Pointer to the Octree if successful, otherwise 0. + \return Pointer to the octree if successful, otherwise 0. This pointer should not be dropped. See IReferenceCounted::drop() for more information. */ virtual IMeshSceneNode* addOctreeSceneNode(IAnimatedMesh* mesh, ISceneNode* parent=0, s32 id=-1, s32 minimalPolysPerNode=512, bool alsoAddIfMeshPointerZero=false) = 0; @@ -556,7 +556,7 @@ namespace scene //! Adds a scene node for rendering using a octree to the scene graph. /** This a good method for rendering scenes with lots of - geometry. The Octree is built on the fly from the mesh, much + geometry. The octree is built on the fly from the mesh, much faster then a bsp tree. \param mesh: The mesh containing all geometry from which the octree will be build. \param parent: Parent node of the octree node. @@ -658,7 +658,7 @@ namespace scene camera = sceneManager->addCameraSceneNodeFPS(0, 100, 500, -1, keyMap, 8); \endcode \param parent: Parent scene node of the camera. Can be null. - \param rotateSpeed: Speed in degress with which the camera is + \param rotateSpeed: Speed in degrees with which the camera is rotated. This can be done only with the mouse. \param moveSpeed: Speed in units per millisecond with which the camera is moved. Movement is done with the cursor keys. @@ -778,14 +778,14 @@ namespace scene //! Adds a particle system scene node to the scene graph. /** \param withDefaultEmitter: Creates a default working point emitter - which emitts some particles. Set this to true to see a particle system + which emits some particles. Set this to true to see a particle system in action. If set to false, you'll have to set the emitter you want by calling IParticleSystemSceneNode::setEmitter(). \param parent: Parent of the scene node. Can be NULL if no parent. \param id: Id of the node. This id can be used to identify the scene node. \param position: Position of the space relative to its parent where the scene node will be placed. - \param rotation: Initital rotation of the scene node. + \param rotation: Initial rotation of the scene node. \param scale: Initial scale of the scene node. \return Pointer to the created scene node. This pointer should not be dropped. See IReferenceCounted::drop() for more information. */ @@ -821,7 +821,7 @@ namespace scene -2^LOD, so for LOD 1, the step taken is 2, for LOD 2, the step taken is 4, LOD 3 - 8, etc. The step can be no larger than the size of the patch, so having a LOD of 8, with a patch size - of 17, is asking the algoritm to generate indices every 2^8 ( + of 17, is asking the algorithm to generate indices every 2^8 ( 256 ) vertices, which is not possible with a patch size of 17. The maximum LOD for a patch size of 17 is 2^4 ( 16 ). So, with a MaxLOD of 5, you'll have LOD 0 ( full detail ), LOD 1 ( @@ -863,7 +863,7 @@ namespace scene //! Adds a terrain scene node to the scene graph. /** Just like the other addTerrainSceneNode() method, but takes an IReadFile - pointer as parameter for the heightmap. For more informations take a look + pointer as parameter for the heightmap. For more information take a look at the other function. \param heightMapFile: The file handle to read vertex data from. This should be a gray scale bitmap. @@ -960,9 +960,9 @@ namespace scene to be able to retrieve the mesh later with ISceneManager::getMesh(). \param tileSize: Size of a tile of the mesh. (10.0f, 10.0f) would be a good value to start, for example. - \param tileCount: Specifies how much tiles there will be. If you specifiy + \param tileCount: Specifies how much tiles there will be. If you specify for example that a tile has the size (10.0f, 10.0f) and the tileCount is - (10,10), than you get a field of 100 tiles which has the dimension 100.0fx100.0f. + (10,10), than you get a field of 100 tiles which has the dimension 100.0f x 100.0f. \param material: Material of the hill mesh. \param hillHeight: Height of the hills. If you specify a negative value you will get holes instead of hills. If the height is 0, no hills will be @@ -999,7 +999,7 @@ namespace scene of triangles created depends on the size of this texture, so use a small heightmap to increase rendering speed. \param stretchSize: Parameter defining how big a is pixel on the heightmap. - \param maxHeight: Defines how high a white pixel on the heighmap is. + \param maxHeight: Defines how high a white pixel on the heightmap is. \param defaultVertexBlockSize: Defines the initial dimension between vertices. \return Null if the creation failed. The reason could be that you specified some invalid parameters, that a mesh with that name already @@ -1016,7 +1016,7 @@ namespace scene \param vtxColorCylinder color of the cylinder \param vtxColorCone color of the cone \param tesselationCylinder Number of quads the cylinder side consists of - \param tesselationCone Number of triangles the cone's roof consits of + \param tesselationCone Number of triangles the cone's roof consists of \param height Total height of the arrow \param cylinderHeight Total height of the cylinder, should be lesser than total height \param widthCylinder Diameter of the cylinder @@ -1155,7 +1155,7 @@ namespace scene \param direction: Specifies the upvector used for alignment of the mesh. \param startPosition: The position on the circle where the animator will begin. Value is in multiples of a circle, i.e. 0.5 is half way around. (phase) - \param radiusEllipsoid: if radiusEllipsoid != 0 then radius2 froms a ellipsoid + \param radiusEllipsoid: if radiusEllipsoid != 0 then radius2 from a ellipsoid begin. Value is in multiples of a circle, i.e. 0.5 is half way around. (phase) \return The animator. Attach it to a scene node with ISceneNode::addAnimator() and the animator will animate it. @@ -1171,7 +1171,7 @@ namespace scene //! Creates a fly straight animator, which lets the attached scene node fly or move along a line between two points. /** \param startPoint: Start point of the line. \param endPoint: End point of the line. - \param timeForWay: Time in milli seconds how long the node should need to + \param timeForWay: Time in milliseconds how long the node should need to move from the start point to the end point. \param loop: If set to false, the node stops when the end point is reached. If loop is true, the node begins again at the start. @@ -1224,7 +1224,7 @@ namespace scene core::vector3df radius = box.MaxEdge - box.getCenter(); \endcode \param gravityPerSecond: Sets the gravity of the environment, as an acceleration in - units per second per second. If your units are equivalent to metres, then + units per second per second. If your units are equivalent to meters, then core::vector3df(0,-10.0f,0) would give an approximately realistic gravity. You can disable gravity by setting it to core::vector3df(0,0,0). \param ellipsoidTranslation: By default, the ellipsoid for collision detection is created around @@ -1245,9 +1245,9 @@ namespace scene //! Creates a follow spline animator. /** The animator modifies the position of - the attached scene node to make it follow a hermite spline. - It uses a subset of hermite splines: either cardinal splines - (tightness != 0.5) or catmull-rom-splines (tightness == 0.5). + the attached scene node to make it follow a Hermite spline. + It uses a subset of Hermite splines: either cardinal splines + (tightness != 0.5) or Catmull-Rom-splines (tightness == 0.5). The animator moves from one control point to the next in 1/speed seconds. This code was sent in by Matthias Gall. If you no longer need the animator, you should call ISceneNodeAnimator::drop(). @@ -1261,7 +1261,7 @@ namespace scene can be used for doing collision detection. Don't use this selector for a huge amount of triangles like in Quake3 maps. Instead, use for example ISceneManager::createOctreeTriangleSelector(). - Please note that the created triangle selector is not automaticly attached + Please note that the created triangle selector is not automatically attached to the scene node. You will have to call ISceneNode::setTriangleSelector() for this. To create and attach a triangle selector is done like this: \code @@ -1301,7 +1301,7 @@ namespace scene /** Triangle selectors can be used for doing collision detection. This triangle selector is optimized for huge amounts of triangle, it organizes them in an octree. - Please note that the created triangle selector is not automaticly attached + Please note that the created triangle selector is not automatically attached to the scene node. You will have to call ISceneNode::setTriangleSelector() for this. To create and attach a triangle selector is done like this: \code @@ -1310,12 +1310,12 @@ namespace scene yourSceneNode->setTriangleSelector(s); s->drop(); \endcode - For more informations and examples on this, take a look at the collision + For more information and examples on this, take a look at the collision tutorial in the SDK. \param mesh: Mesh of which the triangles are taken. \param node: Scene node of which visibility and transformation is used. \param minimalPolysPerNode: Specifies the minimal polygons contained a octree node. - If a node gets less polys the this value, it will not be splitted into + If a node gets less polys than this value, it will not be split into smaller nodes. \return The selector, or null if not successful. If you no longer need the selector, you should call ITriangleSelector::drop(). @@ -1397,14 +1397,14 @@ namespace scene virtual IMeshManipulator* getMeshManipulator() = 0; //! Adds a scene node to the deletion queue. - /** The scene node is immediatly + /** The scene node is immediately deleted when it's secure. Which means when the scene node does not execute animators and things like that. This method is for example used for deleting scene nodes by their scene node animators. In most other cases, a ISceneNode::remove() call is enough, using this deletion queue is not necessary. See ISceneManager::createDeleteAnimator() for details. - \param node: Node to detete. */ + \param node: Node to delete. */ virtual void addToDeletionQueue(ISceneNode* node) = 0; //! Posts an input event to the environment. @@ -1437,7 +1437,7 @@ namespace scene //! Adds a scene node factory to the scene manager. /** Use this to extend the scene manager with new scene node types which it should be - able to create automaticly, for example when loading data from xml files. */ + able to create automatically, for example when loading data from xml files. */ virtual void registerSceneNodeFactory(ISceneNodeFactory* factoryToAdd) = 0; //! Get amount of registered scene node factories. @@ -1455,7 +1455,7 @@ namespace scene //! Adds a scene node animator factory to the scene manager. /** Use this to extend the scene manager with new scene node animator types which it should be - able to create automaticly, for example when loading data from xml files. */ + able to create automatically, for example when loading data from xml files. */ virtual void registerSceneNodeAnimatorFactory(ISceneNodeAnimatorFactory* factoryToAdd) = 0; //! Get amount of registered scene node animator factories. diff --git a/include/ISceneNodeAnimator.h b/include/ISceneNodeAnimator.h index 307e23be..cdff7009 100644 --- a/include/ISceneNodeAnimator.h +++ b/include/ISceneNodeAnimator.h @@ -37,7 +37,7 @@ namespace scene //! Animates a scene node. /** \param node Node to animate. - \param timeMs Current time in milli seconds. */ + \param timeMs Current time in milliseconds. */ virtual void animateNode(ISceneNode* node, u32 timeMs) =0; //! Creates a clone of this animator. @@ -101,9 +101,9 @@ namespace scene //! Sets the enabled state of this element. /** \param enabled When set to false ISceneNodes will not update the animator anymore. - Animators themself usually don't care. So manual calls to animateNode still work. + Animators themselves usually don't care. So manual calls to animateNode still work. \param timeNow When set to values > 0 on enabling and disabling an internal timer will be increased by the time disabled time. - Animator decide themself how to handle that timer, but generally setting it will allow you to pause an animator, so it + Animator decide themselves how to handle that timer, but generally setting it will allow you to pause an animator, so it will continue at the same position when you enable it again. To use that pass irr::ITimer::getTime() as value. Animators with no timers will just ignore this. */ diff --git a/include/ISceneNodeAnimatorCameraMaya.h b/include/ISceneNodeAnimatorCameraMaya.h index 333e7137..a1dba263 100644 --- a/include/ISceneNodeAnimatorCameraMaya.h +++ b/include/ISceneNodeAnimatorCameraMaya.h @@ -15,7 +15,7 @@ namespace scene //! Special scene node animator for Maya-style cameras /** This scene node animator can be attached to a camera to make it act like a 3d - modelling tool. + modeling tool. The camera is moving relative to the target with the mouse, by pressing either of the three buttons. In order to move the camera, set a new target for the camera. The distance defines diff --git a/include/ISceneNodeAnimatorCollisionResponse.h b/include/ISceneNodeAnimatorCollisionResponse.h index 299c0a76..66334127 100644 --- a/include/ISceneNodeAnimatorCollisionResponse.h +++ b/include/ISceneNodeAnimatorCollisionResponse.h @@ -23,7 +23,7 @@ namespace scene { public: - //! Will be called when a collision occurrs. + //! Will be called when a collision occurs. /** See ISceneNodeAnimatorCollisionResponse::setCollisionCallback for more information. \param animator: Collision response animator in which the collision occurred. You can call this animator's methods to find the node, collisionPoint and/or collision triangle. diff --git a/include/ISceneNodeAnimatorFactory.h b/include/ISceneNodeAnimatorFactory.h index c3f5b3c3..a50703f2 100644 --- a/include/ISceneNodeAnimatorFactory.h +++ b/include/ISceneNodeAnimatorFactory.h @@ -45,17 +45,17 @@ namespace scene //! returns amount of scene node animator types this factory is able to create virtual u32 getCreatableSceneNodeAnimatorTypeCount() const = 0; - //! returns type of a createable scene node animator type + //! returns type of a creatable scene node animator type /** \param idx: Index of scene node animator type in this factory. Must be a value between 0 and getCreatableSceneNodeTypeCount() */ virtual ESCENE_NODE_ANIMATOR_TYPE getCreateableSceneNodeAnimatorType(u32 idx) const = 0; - //! returns type name of a createable scene node animator type + //! returns type name of a creatable scene node animator type /** \param idx: Index of scene node animator type in this factory. Must be a value between 0 and getCreatableSceneNodeAnimatorTypeCount() */ virtual const c8* getCreateableSceneNodeAnimatorTypeName(u32 idx) const = 0; - //! returns type name of a createable scene node animator type + //! returns type name of a creatable scene node animator type /** \param type: Type of scene node animator. \return: Returns name of scene node animator type if this factory can create the type, otherwise 0. */ virtual const c8* getCreateableSceneNodeAnimatorTypeName(ESCENE_NODE_ANIMATOR_TYPE type) const = 0; diff --git a/include/ISceneNodeFactory.h b/include/ISceneNodeFactory.h index 5359d2bc..43043bd2 100644 --- a/include/ISceneNodeFactory.h +++ b/include/ISceneNodeFactory.h @@ -44,17 +44,17 @@ namespace scene //! returns amount of scene node types this factory is able to create virtual u32 getCreatableSceneNodeTypeCount() const = 0; - //! returns type of a createable scene node type + //! returns type of a creatable scene node type /** \param idx: Index of scene node type in this factory. Must be a value between 0 and getCreatableSceneNodeTypeCount() */ virtual ESCENE_NODE_TYPE getCreateableSceneNodeType(u32 idx) const = 0; - //! returns type name of a createable scene node type by index + //! returns type name of a creatable scene node type by index /** \param idx: Index of scene node type in this factory. Must be a value between 0 and getCreatableSceneNodeTypeCount() */ virtual const c8* getCreateableSceneNodeTypeName(u32 idx) const = 0; - //! returns type name of a createable scene node type + //! returns type name of a creatable scene node type /** \param type: Type of scene node. \return: Returns name of scene node type if this factory can create the type, otherwise 0. */ virtual const c8* getCreateableSceneNodeTypeName(ESCENE_NODE_TYPE type) const = 0; diff --git a/include/ISkinnedMesh.h b/include/ISkinnedMesh.h index 03f5016f..783b26eb 100644 --- a/include/ISkinnedMesh.h +++ b/include/ISkinnedMesh.h @@ -76,7 +76,7 @@ namespace scene virtual void convertMeshToTangents() = 0; //! Allows to enable hardware skinning. - /* This feature is not implementated in Irrlicht yet */ + /* This feature is not implemented in Irrlicht yet */ virtual bool setHardwareSkinning(bool on) = 0; //! A vertex weight diff --git a/include/ITerrainSceneNode.h b/include/ITerrainSceneNode.h index 26160e9f..f367792f 100644 --- a/include/ITerrainSceneNode.h +++ b/include/ITerrainSceneNode.h @@ -41,7 +41,7 @@ namespace scene * of the indices to draw all the triangles at the max detail for a patch. As each LOD goes up by 1 * the step taken, in generating indices increases by - 2^LOD, so for LOD 1, the step taken is 2, for * LOD 2, the step taken is 4, LOD 3 - 8, etc. The step can be no larger than the size of the patch, - * so having a LOD of 8, with a patch size of 17, is asking the algoritm to generate indices every + * so having a LOD of 8, with a patch size of 17, is asking the algorithm to generate indices every * 2^8 ( 256 ) vertices, which is not possible with a patch size of 17. The maximum LOD for a patch * size of 17 is 2^4 ( 16 ). So, with a MaxLOD of 5, you'll have LOD 0 ( full detail ), LOD 1 ( every * 2 vertices ), LOD 2 ( every 4 vertices ), LOD 3 ( every 8 vertices ) and LOD 4 ( every 16 vertices ). diff --git a/include/ITexture.h b/include/ITexture.h index 29fa6df6..cbaaf0a3 100644 --- a/include/ITexture.h +++ b/include/ITexture.h @@ -86,9 +86,9 @@ enum E_TEXTURE_LOCK_MODE /** Often used to read back shader generated textures. */ ETLM_READ_ONLY, - //! Write only. The texture is not downloaded and might be uninitialised. + //! Write only. The texture is not downloaded and might be uninitialized. /** The updated texture is uploaded to the GPU. - Used for initialising the shader from the CPU. */ + Used for initializing the shader from the CPU. */ ETLM_WRITE_ONLY }; @@ -130,7 +130,7 @@ public: are done, you must call unlock(). Locks are not accumulating, hence one unlock will do for an arbitrary number of previous locks. You should avoid locking different levels without - unlocking inbetween, though, because only the last level locked will be + unlocking in between, though, because only the last level locked will be unlocked. The size of the i-th mipmap level is defined as max(getSize().Width>>i,1) and max(getSize().Height>>i,1) diff --git a/include/ITimer.h b/include/ITimer.h index de1cbff0..709db975 100644 --- a/include/ITimer.h +++ b/include/ITimer.h @@ -40,7 +40,7 @@ public: u32 Minute; // Second of the minute, due to extra seconds from 0 to 61 u32 Second; - // Year of the gregorian calender + // Year of the Gregorian calender s32 Year; // Month of the year, from 1 to 12 u32 Month; diff --git a/include/ITriangleSelector.h b/include/ITriangleSelector.h index e2a2256c..ecd4088e 100644 --- a/include/ITriangleSelector.h +++ b/include/ITriangleSelector.h @@ -20,7 +20,7 @@ class ISceneNode; //! Interface to return triangles with specific properties. /** Every ISceneNode may have a triangle selector, available with -ISceneNode::getTriangleScelector() or ISceneManager::createTriangleSelector. +ISceneNode::getTriangleSelector() or ISceneManager::createTriangleSelector. This is used for doing collision detection: For example if you know, that a collision may have happened in the area between (1,1,1) and (10,10,10), you can get all triangles of the scene node in this area with the diff --git a/include/IVideoDriver.h b/include/IVideoDriver.h index f2f0f3a8..178afd95 100644 --- a/include/IVideoDriver.h +++ b/include/IVideoDriver.h @@ -288,7 +288,7 @@ namespace video /** The following names can be queried for the given types: MaxTextures (int) The maximum number of simultaneous textures supported by the driver. This can be less than the supported number of textures of the driver. Use _IRR_MATERIAL_MAX_TEXTURES_ to adapt the number. MaxSupportedTextures (int) The maximum number of simultaneous textures supported by the fixed function pipeline of the (hw) driver. The actual supported number of textures supported by the engine can be lower. - MaxLights (int) Number of hardware lights supported in the fixed function pipieline of the driver, typically 6-8. Use light manager or deferred shading for more. + MaxLights (int) Number of hardware lights supported in the fixed function pipeline of the driver, typically 6-8. Use light manager or deferred shading for more. MaxAnisotropy (int) Number of anisotropy levels supported for filtering. At least 1, max is typically at 16 or 32. MaxUserClipPlanes (int) Number of additional clip planes, which can be set by the user via dedicated driver methods. MaxAuxBuffers (int) Special render buffers, which are currently not really usable inside Irrlicht. Only supported by OpenGL @@ -584,7 +584,7 @@ namespace video \param clearColor The clear color for the color buffer. \param clearDepth The clear value for the depth buffer. \param clearStencil The clear value for the stencil buffer. - \return True if sucessful and false if not. */ + \return True if successful and false if not. */ virtual bool setRenderTargetEx(IRenderTarget* target, u16 clearFlag, SColor clearColor = SColor(255,0,0,0), f32 clearDepth = 1.f, u8 clearStencil = 0) = 0; @@ -616,13 +616,13 @@ namespace video \param clearColor The clear color for the color buffer. \param clearDepth The clear value for the depth buffer. \param clearStencil The clear value for the stencil buffer. - \return True if sucessful and false if not. */ + \return True if successful and false if not. */ virtual bool setRenderTarget(ITexture* texture, u16 clearFlag=ECBF_COLOR|ECBF_DEPTH, SColor clearColor = SColor(255,0,0,0), f32 clearDepth = 1.f, u8 clearStencil = 0) = 0; - //! Sets a new render target. + //! Sets a new render target. // Prefer to use the setRenderTarget function taking flags as parameter as this one can't clear the stencil buffer. - // It's still offered for backward compatiblity. + // It's still offered for backward compatibility. _IRR_DEPRECATED_ bool setRenderTarget(ITexture* texture, bool clearBackBuffer, bool clearZBuffer, SColor color = SColor(255,0,0,0)) { u16 flag = 0; @@ -1272,7 +1272,7 @@ namespace video \param size Desired size of the image \param data A byte array with pixel color information \param ownForeignMemory If true, the image will use the data - pointer directly and own it afterwards. If false, the memory + pointer directly and own it afterward. If false, the memory will by copied internally. \param deleteMemory Whether the memory is deallocated upon destruction. @@ -1348,7 +1348,7 @@ namespace video \param name Optional name for the material renderer entry. \return The number of the material type which can be set in SMaterial::MaterialType to use the renderer. -1 is returned if - an error occured. For example if you tried to add an material + an error occurred. For example if you tried to add an material renderer to the software renderer or the null device, which do not accept material renderers. */ virtual s32 addMaterialRenderer(IMaterialRenderer* renderer, const c8* name =0) =0; @@ -1500,7 +1500,7 @@ namespace video virtual SOverrideMaterial& getOverrideMaterial() =0; //! Get the 2d override material for altering its values - /** The 2d override materual allows to alter certain render + /** The 2d override material allows to alter certain render states of the 2d methods. Not all members of SMaterial are honored, especially not MaterialType and Textures. Moreover, the zbuffer is always ignored, and lighting is always off. All diff --git a/include/IWriteFile.h b/include/IWriteFile.h index ddc147df..68eac14a 100644 --- a/include/IWriteFile.h +++ b/include/IWriteFile.h @@ -21,7 +21,7 @@ namespace io /** \param buffer Pointer to buffer of bytes to write. \param sizeToWrite Amount of bytes to write to the file. \return How much bytes were written. */ - virtual s32 write(const void* buffer, u32 sizeToWrite) = 0; + virtual size_t write(const void* buffer, size_t sizeToWrite) = 0; //! Changes position in file /** \param finalPos Destination position in the file. diff --git a/include/IXMLReader.h b/include/IXMLReader.h index 3f34cb87..7babb454 100644 --- a/include/IXMLReader.h +++ b/include/IXMLReader.h @@ -15,13 +15,13 @@ namespace io //! An xml reader for wide characters, derived from IReferenceCounted. /** This XML Parser can read any type of text files from any source Irrlicht can read. Just call IFileSystem::createXMLReader(). For more - informations on how to use the parser, see IIrrXMLReader */ + information on how to use the parser, see IIrrXMLReader */ typedef IIrrXMLReader IXMLReader; //! An xml reader for ASCII or UTF-8 characters, derived from IReferenceCounted. /** This XML Parser can read any type of text files from any source Irrlicht can read. Just call IFileSystem::createXMLReaderUTF8(). For - more informations on how to use the parser, see IIrrXMLReader */ + more information on how to use the parser, see IIrrXMLReader */ typedef IIrrXMLReader IXMLReaderUTF8; } // end namespace io diff --git a/include/IXMLWriter.h b/include/IXMLWriter.h index 653b92d3..a68cac9c 100644 --- a/include/IXMLWriter.h +++ b/include/IXMLWriter.h @@ -23,7 +23,7 @@ namespace io //! Writes an xml 1.0 header. /** Looks like <?xml version="1.0"?>. This should always be called before writing anything other, because also the text - file header for unicode texts is written out with this method. */ + file header for Unicode texts is written out with this method. */ virtual void writeXMLHeader() = 0; //! Writes an xml element with maximal 5 attributes like "" or @@ -62,7 +62,7 @@ namespace io //! Writes a text into the file. /** All occurrences of special characters such as - & (&), < (<), > (>), and " (") are automaticly + & (&), < (<), > (>), and " (") are automatically replaced. */ virtual void writeText(const wchar_t* text) = 0; diff --git a/include/IrrlichtDevice.h b/include/IrrlichtDevice.h index 6f77957d..8c4a41af 100644 --- a/include/IrrlichtDevice.h +++ b/include/IrrlichtDevice.h @@ -71,7 +71,7 @@ namespace irr DispatchMessage and whatever and simply don't use this method. But note that Irrlicht will not be able to fetch user input then. See irr::SIrrlichtCreationParameters::WindowId for more - informations and example code. + information and example code. */ virtual bool run() = 0; @@ -82,7 +82,7 @@ namespace irr //! Pause execution and let other processes to run for a specified amount of time. /** It may not wait the full given time, as sleep may be interrupted - \param timeMs: Time to sleep for in milisecs. + \param timeMs: Time to sleep for in milliseconds. \param pauseTimer: If true, pauses the device timer while sleeping */ virtual void sleep(u32 timeMs, bool pauseTimer=false) = 0; @@ -112,8 +112,8 @@ namespace irr virtual ILogger* getLogger() = 0; //! Gets a list with all video modes available. - /** You only need a null driver (ED_NULL) to access - those video modes. So you can get the available modes + /** You only need a null driver (ED_NULL) to access + those video modes. So you can get the available modes before starting any other video driver. \return Pointer to a list with all video modes supported by the gfx adapter. */ @@ -124,7 +124,7 @@ namespace irr //! Provides access to the operation system operator object. /** The OS operator provides methods for - getting system specific informations and doing system + getting system specific information and doing system specific operations, such as exchanging data with the clipboard or reading the operation system version. \return Pointer to the OS operator. */ diff --git a/include/SExposedVideoData.h b/include/SExposedVideoData.h index 73281739..35108f00 100644 --- a/include/SExposedVideoData.h +++ b/include/SExposedVideoData.h @@ -17,7 +17,7 @@ namespace video { //! structure for holding data describing a driver and operating system specific data. -/** This data can be retrived by IVideoDriver::getExposedVideoData(). Use this with caution. +/** This data can be retrieved by IVideoDriver::getExposedVideoData(). Use this with caution. This only should be used to make it possible to extend the engine easily without modification of its source. Note that this structure does not contain any valid data, if you are using the software or the null device. @@ -62,12 +62,12 @@ struct SExposedVideoData void* X11Context; unsigned long X11Window; }; - + struct SOpenGLOSX { //! The NSOpenGLContext object. void* Context; - + //! The NSWindow object. void* Window; }; diff --git a/include/SIrrCreationParameters.h b/include/SIrrCreationParameters.h index 6abf1b59..09c84f25 100644 --- a/include/SIrrCreationParameters.h +++ b/include/SIrrCreationParameters.h @@ -135,7 +135,7 @@ namespace irr Default: true. */ bool Stencilbuffer; - //! Specifies vertical syncronisation. + //! Specifies vertical synchronization. /** If set to true, the driver will wait for the vertical retrace period, otherwise not. May be silently ignored. Default: false */ @@ -151,7 +151,7 @@ namespace irr be a good idea to make it possible to switch this option off again by the user. The value is the maximal antialiasing factor requested for - the device. The cretion method will automatically try smaller + the device. The creation method will automatically try smaller values if no window can be created with the given value. Value one is usually the same as 0 (disabled), but might be a special value on some platforms. On D3D devices it maps to @@ -160,7 +160,7 @@ namespace irr u8 AntiAlias; //! Flag to enable proper sRGB and linear color handling - /** In most situations, it is desireable to have the color handling in + /** In most situations, it is desirable to have the color handling in non-linear sRGB color space, and only do the intermediate color calculations in linear RGB space. If this flag is enabled, the device and driver try to assure that all color input and output are color corrected @@ -175,7 +175,7 @@ namespace irr bool HandleSRGB; //! Whether the main framebuffer uses an alpha channel. - /** In some situations it might be desireable to get a color + /** In some situations it might be desirable to get a color buffer with an alpha channel, e.g. when rendering into a transparent window or overlay. If this flag is set the device tries to create a framebuffer with alpha channel. diff --git a/include/SMaterial.h b/include/SMaterial.h index 53c0bcee..2ef0457d 100644 --- a/include/SMaterial.h +++ b/include/SMaterial.h @@ -102,7 +102,7 @@ namespace video //! Source of the alpha value to take /** This is currently only supported in EMT_ONETEXTURE_BLEND. You can use an - or'ed combination of values. Alpha values are modulated (multiplicated). */ + or'ed combination of values. Alpha values are modulated (multiplied). */ enum E_ALPHA_SOURCE { //! Use no alpha, somewhat redundant with other settings @@ -247,7 +247,7 @@ namespace video 0 }; - //! Fine-tuning for SMaterial.ZWriteFineControl + //! Fine-tuning for SMaterial.ZWriteFineControl enum E_ZWRITE_FINE_CONTROL { //! Default. Only write zbuffer when When SMaterial::ZBuffer is true and SMaterial::isTransparent() returns false. @@ -275,7 +275,7 @@ namespace video PolygonOffsetFactor(0), PolygonOffsetDirection(EPO_FRONT), Wireframe(false), PointCloud(false), GouraudShading(true), Lighting(true), ZWriteEnable(true), BackfaceCulling(true), FrontfaceCulling(false), - FogEnable(false), NormalizeNormals(false), UseMipMaps(true), + FogEnable(false), NormalizeNormals(false), UseMipMaps(true), ZWriteFineControl(EZI_ONLY_NON_TRANSPARENT) { } @@ -445,7 +445,7 @@ namespace video u8 PolygonOffsetFactor:3; //! Flag defining the direction the polygon offset is applied to. - /** Can be to front or to back, specififed by values from E_POLYGON_OFFSET. */ + /** Can be to front or to back, specified by values from E_POLYGON_OFFSET. */ E_POLYGON_OFFSET PolygonOffsetDirection:1; //! Draw as wireframe or filled triangles? Default: false @@ -747,7 +747,7 @@ namespace video textureBlendFunc_hasAlpha(srcAlphaFact) || textureBlendFunc_hasAlpha(dstAlphaFact)) { return true; - } + } } return false; diff --git a/include/SMaterialLayer.h b/include/SMaterialLayer.h index b0bdac3d..5724d7d2 100644 --- a/include/SMaterialLayer.h +++ b/include/SMaterialLayer.h @@ -215,7 +215,7 @@ namespace video //! Texture Matrix /** Do not access this element directly as the internal - ressource management has to cope with Null pointers etc. */ + resource management has to cope with Null pointers etc. */ core::matrix4* TextureMatrix; }; diff --git a/include/SSharedMeshBuffer.h b/include/SSharedMeshBuffer.h index 5fbf032b..8cb78049 100644 --- a/include/SSharedMeshBuffer.h +++ b/include/SSharedMeshBuffer.h @@ -70,13 +70,13 @@ namespace scene return 0; } - //! returns pointer to Indices + //! returns pointer to indices virtual const u16* getIndices() const { return Indices.const_pointer(); } - //! returns pointer to Indices + //! returns pointer to indices virtual u16* getIndices() { return Indices.pointer(); @@ -217,7 +217,7 @@ namespace scene //! Shared Array of vertices core::array *Vertices; - //! Array of Indices + //! Array of indices core::array Indices; //! ID used for hardware buffer management diff --git a/include/SVertexManipulator.h b/include/SVertexManipulator.h index 6696ad01..b7894ccf 100644 --- a/include/SVertexManipulator.h +++ b/include/SVertexManipulator.h @@ -47,7 +47,7 @@ namespace scene private: u32 Alpha; }; - //! Vertex manipulator which invertes the RGB values + //! Vertex manipulator which inverts the RGB values class SVertexColorInvertManipulator : public IVertexManipulator { public: diff --git a/include/SViewFrustum.h b/include/SViewFrustum.h index 97e1a3d5..ee7db2b3 100644 --- a/include/SViewFrustum.h +++ b/include/SViewFrustum.h @@ -26,7 +26,7 @@ namespace scene { enum VFPLANES { - //! Far plane of the frustum. That is the plane farest away from the eye. + //! Far plane of the frustum. That is the plane furthest away from the eye. VF_FAR_PLANE = 0, //! Near plane of the frustum. That is the plane nearest to the eye. VF_NEAR_PLANE, diff --git a/include/aabbox3d.h b/include/aabbox3d.h index 1f2457b6..e1f1b5e8 100644 --- a/include/aabbox3d.h +++ b/include/aabbox3d.h @@ -226,7 +226,7 @@ class aabbox3d //! Check if this box is completely inside the 'other' box. /** \param other: Other box to check against. - \return True if this box is completly inside the other box, + \return True if this box is completely inside the other box, otherwise false. */ bool isFullInside(const aabbox3d& other) const { diff --git a/include/heapsort.h b/include/heapsort.h index 6f87665c..36211c4d 100644 --- a/include/heapsort.h +++ b/include/heapsort.h @@ -40,7 +40,7 @@ inline void heapsink(T*array, s32 element, s32 max) template inline void heapsort(T* array_, s32 size) { - // for heapsink we pretent this is not c++, where + // for heapsink we pretend this is not c++, where // arrays start with index 0. So we decrease the array pointer, // the maximum always +2 and the element always +1 diff --git a/include/irrArray.h b/include/irrArray.h index 99c87c7b..a46c6f8c 100644 --- a/include/irrArray.h +++ b/include/irrArray.h @@ -587,7 +587,7 @@ public: //! Swap the content of this array container with the content of another array - /** Afterwards this object will contain the content of the other object and the other + /** Afterward this object will contain the content of the other object and the other object will contain the content of this object. \param other Swap content with this object */ void swap(array& other) diff --git a/include/irrList.h b/include/irrList.h index 706cc61d..cbf3575e 100644 --- a/include/irrList.h +++ b/include/irrList.h @@ -382,8 +382,8 @@ public: } //! Swap the content of this list container with the content of another list - /** Afterwards this object will contain the content of the other object and the other - object will contain the content of this object. Iterators will afterwards be valid for + /** Afterward this object will contain the content of the other object and the other + object will contain the content of this object. Iterators will afterward be valid for the swapped object. \param other Swap content with this object */ void swap(list& other) diff --git a/include/irrMap.h b/include/irrMap.h index 3297f49f..e2fa23fd 100644 --- a/include/irrMap.h +++ b/include/irrMap.h @@ -123,7 +123,7 @@ class map public: typedef RBTree Node; - // We need the forwad declaration for the friend declaration + // We need the forward declaration for the friend declaration class ConstIterator; //! Normal Iterator @@ -227,9 +227,9 @@ class map else { // Current node neither is left child nor has a right child. - // Ie it is either right child or root + // I.e. it is either right child or root // The next higher node is the parent of the first non-right - // child (ie either a left child or the root) up in the + // child (i.e. either a left child or the root) up in the // hierarchy. Root's parent is 0. while(Cur->isRightChild()) Cur = Cur->getParent(); @@ -258,9 +258,9 @@ class map else { // Current node neither is right child nor has a left child. - // Ie it is either left child or root + // It is either left child or root // The next higher node is the parent of the first non-left - // child (ie either a right child or the root) up in the + // child (i.e. either a right child or the root) up in the // hierarchy. Root's parent is 0. while(Cur->isLeftChild()) @@ -375,9 +375,9 @@ class map else { // Current node neither is left child nor has a right child. - // Ie it is either right child or root + // It is either right child or root // The next higher node is the parent of the first non-right - // child (ie either a left child or the root) up in the + // child (i.e. either a left child or the root) up in the // hierarchy. Root's parent is 0. while(Cur->isRightChild()) Cur = Cur->getParent(); @@ -406,9 +406,9 @@ class map else { // Current node neither is right child nor has a left child. - // Ie it is either left child or root + // It is either left child or root // The next higher node is the parent of the first non-left - // child (ie either a right child or the root) up in the + // child (i.e. either a right child or the root) up in the // hierarchy. Root's parent is 0. while(Cur->isLeftChild()) @@ -497,7 +497,7 @@ class map } else { - // No children? Move up in the hierarcy until + // No children? Move up in the hierarchy until // we either reach 0 (and are finished) or // find a right uncle. while (Cur!=0) diff --git a/include/irrMath.h b/include/irrMath.h index b8a186e7..612fe632 100644 --- a/include/irrMath.h +++ b/include/irrMath.h @@ -322,7 +322,7 @@ namespace core } /* - float IEEE-754 bit represenation + float IEEE-754 bit representation 0 0x00000000 1.0 0x3f800000 @@ -402,7 +402,7 @@ namespace core #if defined(__BORLANDC__) || defined (__BCPLUSPLUS__) - // 8-bit bools in borland builder + // 8-bit bools in Borland builder //! conditional set based on mask and arithmetic shift REALINLINE u32 if_c_a_else_b ( const c8 condition, const u32 a, const u32 b ) @@ -441,7 +441,7 @@ namespace core */ REALINLINE void setbit_cond ( u32 &state, s32 condition, u32 mask ) { - // 0, or any postive to mask + // 0, or any positive to mask //s32 conmask = -condition >> 31; state ^= ( ( -condition >> 31 ) ^ state ) & mask; } @@ -536,9 +536,9 @@ namespace core // SSE Newton-Raphson reciprocal estimate, accurate to 23 significant // bi ts of the mantissa - // One Newtown-Raphson Iteration: + // One Newton-Raphson Iteration: // f(i+1) = 2 * rcpss(f) - f * rcpss(f) * rcpss(f) -#if defined(_MSC_VER) +#if defined(_MSC_VER) f32 rec; __asm rcpss xmm0, f // xmm0 = rcpss(f) __asm movss xmm1, f // xmm1 = f @@ -578,9 +578,9 @@ namespace core // SSE Newton-Raphson reciprocal estimate, accurate to 23 significant // bi ts of the mantissa - // One Newtown-Raphson Iteration: + // One Newton-Raphson Iteration: // f(i+1) = 2 * rcpss(f) - f * rcpss(f) * rcpss(f) -#if defined(_MSC_VER) +#if defined(_MSC_VER) f32 rec; __asm rcpss xmm0, f // xmm0 = rcpss(f) __asm movss xmm1, f // xmm1 = f diff --git a/include/irrString.h b/include/irrString.h index 33267ebe..737fe3d0 100644 --- a/include/irrString.h +++ b/include/irrString.h @@ -311,7 +311,7 @@ public: } - //! Constructor for unicode and ascii strings + //! Constructor for Unicode and ASCII strings template string(const B* const c) : array(0), allocated(0), used(0) @@ -357,7 +357,7 @@ public: } - //! Assignment operator for strings, ascii and unicode + //! Assignment operator for strings, ASCII and Unicode template string& operator=(const B* const c) { @@ -414,7 +414,7 @@ public: } - //! Append operator for strings, ascii and unicode + //! Append operator for strings, ASCII and Unicode template string operator+(const B* const c) const { @@ -510,6 +510,16 @@ public: return (size() == 0); } + void clear(bool releaseMemory=true) + { + if ( releaseMemory ) + { + reallocate(1); + } + array[0] = 0; + used = 1; + } + //! Returns character string /** \return pointer to C-style NUL terminated string. */ const T* c_str() const @@ -1387,7 +1397,7 @@ typedef string stringw; What the function does exactly depends on the LC_CTYPE of the current c locale. \param destination Wide-character string receiving the converted source \param source multibyte string -\return The number of wide characters written to destination, not including the eventual terminating null character. */ +\return The number of wide characters written to destination, not including the eventual terminating null character or -1 when conversion failed */ static inline size_t multibyteToWString(string& destination, const core::string& source) { return multibyteToWString(destination, source.c_str(), (u32)source.size()); @@ -1398,7 +1408,7 @@ static inline size_t multibyteToWString(string& destination, const core What the function does exactly depends on the LC_CTYPE of the current c locale. \param destination Wide-character string receiving the converted source \param source multibyte string -\return The number of wide characters written to destination, not including the eventual terminating null character. */ +\return The number of wide characters written to destination, not including the eventual terminating null character or -1 when conversion failed. */ static inline size_t multibyteToWString(string& destination, const char* source) { u32 s = source ? (u32)strlen(source) : 0; @@ -1419,13 +1429,22 @@ static size_t multibyteToWString(string& destination, const char* sourc #if defined(_MSC_VER) #pragma warning(pop) #endif - destination.used = (u32)written; - destination.array[destination.used] = 0; + if ( written != (size_t)-1 ) + { + destination.used = (u32)written+1; + destination.array[destination.used-1] = 0; + } + else + { + // Likely character which got converted until the invalid character was encountered are in destination now. + // And it seems even 0-terminated, but I found no documentation anywhere that this (the 0-termination) is guaranteed :-( + destination.clear(); + } return written; } else { - destination.empty(); + destination.clear(); return 0; } } diff --git a/include/irrTypes.h b/include/irrTypes.h index b7a4d23f..881e2901 100644 --- a/include/irrTypes.h +++ b/include/irrTypes.h @@ -150,7 +150,7 @@ namespace irr //! Type name for character type used by the file system. /** Should the wide character version of the FileSystem be used it is a -16 bit character variable. Used for unicode Filesystem and unicode strings. +16 bit character variable. Used for Unicode Filesystem and Unicode strings. Else it is a 8 bit character variable. Used for ansi Filesystem and non-unicode strings */ @@ -225,7 +225,7 @@ virtual void somefunc() _IRR_OVERRIDE_; #endif //! ignore VC8 warning deprecated -/** The microsoft compiler */ +/** The Microsoft compiler */ #if defined(_IRR_WINDOWS_API_) && defined(_MSC_VER) && (_MSC_VER >= 1400) //#pragma warning( disable: 4996) //#define _CRT_SECURE_NO_DEPRECATE 1 diff --git a/include/irrXML.h b/include/irrXML.h index 67ac76e9..5b4b7afe 100644 --- a/include/irrXML.h +++ b/include/irrXML.h @@ -22,7 +22,7 @@ irrXML is intended to be a high speed and easy-to-use XML Parser for C++, and this documentation is an important part of it. If you have any questions or suggestions, just send a email to the author of the engine, Nikolaus Gebhardt - (niko (at) irrlicht3d.org). For more informations about this parser, see \ref history. + (niko (at) irrlicht3d.org). For more information about this parser, see \ref history. \section features Features @@ -46,7 +46,7 @@ to use. - It has no external dependencies, it does not even need the STL. - Although irrXML has some strenghts, it currently also has the following limitations: + Although irrXML has some strengths, it currently also has the following limitations: - The input xml file is not validated and assumed to be correct. @@ -117,7 +117,7 @@ \section license License - The irrXML license is based on the zlib license. Basicly, this means you can do with + The irrXML license is based on the zlib license. Basically, this means you can do with irrXML whatever you want: Copyright (C) 2002-2012 Nikolaus Gebhardt @@ -232,7 +232,7 @@ namespace io /** If you need another class as base class for the xml reader, you can do this by creating the reader using for example new CXMLReaderImpl(yourcallback); The Irrlicht Engine for example needs IReferenceCounted as base class for every object to - let it automaticly reference countend, hence it replaces IXMLBase with IReferenceCounted. + let it automatically reference counted, hence it replaces IXMLBase with IReferenceCounted. See irrXML.cpp on how this can be done in detail. */ class IXMLBase { @@ -355,7 +355,7 @@ namespace io /** It is not necessary to use this method because the parser will convert the input file format to the format wanted by the user when creating the parser. This - method is useful to get/display additional informations. */ + method is useful to get/display additional information. */ virtual ETEXT_FORMAT getSourceFormat() const = 0; //! Returns format of the strings returned by the parser. @@ -375,7 +375,7 @@ namespace io xmlChar(char in) : c(static_cast(in)) {} xmlChar(wchar_t in) : c(static_cast(in)) {} #if defined(__BORLANDC__) - // Note - removing explicit for borland was to get it to even compile. + // Note - removing explicit for Borland was to get it to even compile. // There haven't been any kind of tests for that besides that. xmlChar(unsigned char in) : c(static_cast(in)) {} xmlChar(unsigned short in) : c(static_cast(in)) {} @@ -437,7 +437,7 @@ namespace io IFileSystem::createXMLReaderUTF8() instead. \param filename: Name of file to be opened. \return Returns a pointer to the created xml parser. This pointer should be - deleted using 'delete' after no longer needed. Returns 0 if an error occured + deleted using 'delete' after no longer needed. Returns 0 if an error occurred and the file could not be opened. */ IRRLICHT_API IrrXMLReader* IRRCALLCONV createIrrXMLReader(const char* filename); @@ -449,7 +449,7 @@ namespace io \param file: Pointer to opened file, must have been opened in binary mode, e.g. using fopen("foo.bar", "wb"); The file will not be closed after it has been read. \return Returns a pointer to the created xml parser. This pointer should be - deleted using 'delete' after no longer needed. Returns 0 if an error occured + deleted using 'delete' after no longer needed. Returns 0 if an error occurred and the file could not be opened. */ IRRLICHT_API IrrXMLReader* IRRCALLCONV createIrrXMLReader(FILE* file); @@ -462,9 +462,9 @@ namespace io callback to make the xml parser read in other things than just files. See IFileReadCallBack for more information about this. \param deleteCallback: if true, the callback will be deleted after the file - has been read. Otherwise the caller si responsible for cleaning it up. + has been read. Otherwise the caller is responsible for cleaning it up. \return Returns a pointer to the created xml parser. This pointer should be - deleted using 'delete' after no longer needed. Returns 0 if an error occured + deleted using 'delete' after no longer needed. Returns 0 if an error occurred and the file could not be opened. */ IRRLICHT_API IrrXMLReader* IRRCALLCONV createIrrXMLReader(IFileReadCallBack* callback, bool deleteCallback = false); @@ -477,7 +477,7 @@ namespace io IFileSystem::createXMLReader() instead. \param filename: Name of file to be opened. \return Returns a pointer to the created xml parser. This pointer should be - deleted using 'delete' after no longer needed. Returns 0 if an error occured + deleted using 'delete' after no longer needed. Returns 0 if an error occurred and the file could not be opened. */ IRRLICHT_API IrrXMLReaderUTF16* IRRCALLCONV createIrrXMLReaderUTF16(const char* filename); @@ -489,7 +489,7 @@ namespace io \param file: Pointer to opened file, must have been opened in binary mode, e.g. using fopen("foo.bar", "wb"); The file will not be closed after it has been read. \return Returns a pointer to the created xml parser. This pointer should be - deleted using 'delete' after no longer needed. Returns 0 if an error occured + deleted using 'delete' after no longer needed. Returns 0 if an error occurred and the file could not be opened. */ IRRLICHT_API IrrXMLReaderUTF16* IRRCALLCONV createIrrXMLReaderUTF16(FILE* file); @@ -502,9 +502,9 @@ namespace io callback to make the xml parser read in other things than just files. See IFileReadCallBack for more information about this. \param deleteCallback: if true, the callback will be deleted after the file - has been read. Otherwise the caller si responsible for cleaning it up. + has been read. Otherwise the caller is responsible for cleaning it up. \return Returns a pointer to the created xml parser. This pointer should be - deleted using 'delete' after no longer needed. Returns 0 if an error occured + deleted using 'delete' after no longer needed. Returns 0 if an error occurred and the file could not be opened. */ IRRLICHT_API IrrXMLReaderUTF16* IRRCALLCONV createIrrXMLReaderUTF16(IFileReadCallBack* callback, bool deleteCallback = false); @@ -517,7 +517,7 @@ namespace io IFileSystem::createXMLReader() instead. \param filename: Name of file to be opened. \return Returns a pointer to the created xml parser. This pointer should be - deleted using 'delete' after no longer needed. Returns 0 if an error occured + deleted using 'delete' after no longer needed. Returns 0 if an error occurred and the file could not be opened. */ IRRLICHT_API IrrXMLReaderUTF32* IRRCALLCONV createIrrXMLReaderUTF32(const char* filename); @@ -529,7 +529,7 @@ namespace io \param file: Pointer to opened file, must have been opened in binary mode, e.g. using fopen("foo.bar", "wb"); The file will not be closed after it has been read. \return Returns a pointer to the created xml parser. This pointer should be - deleted using 'delete' after no longer needed. Returns 0 if an error occured + deleted using 'delete' after no longer needed. Returns 0 if an error occurred and the file could not be opened. */ IRRLICHT_API IrrXMLReaderUTF32* IRRCALLCONV createIrrXMLReaderUTF32(FILE* file); @@ -543,9 +543,9 @@ namespace io callback to make the xml parser read in other things than just files. See IFileReadCallBack for more information about this. \param deleteCallback: if true, the callback will be deleted after the file - has been read. Otherwise the caller si responsible for cleaning it up. + has been read. Otherwise the caller is responsible for cleaning it up. \return Returns a pointer to the created xml parser. This pointer should be - deleted using 'delete' after no longer needed. Returns 0 if an error occured + deleted using 'delete' after no longer needed. Returns 0 if an error occurred and the file could not be opened. */ IRRLICHT_API IrrXMLReaderUTF32* IRRCALLCONV createIrrXMLReaderUTF32(IFileReadCallBack* callback, bool deleteCallback = false); diff --git a/include/irrlicht.h b/include/irrlicht.h index f5e8882e..a813a490 100644 --- a/include/irrlicht.h +++ b/include/irrlicht.h @@ -23,7 +23,7 @@ the Irrlicht Engine in your product, you must acknowledge somewhere in your documentation that you've used the IJG code. It would also be nice to mention that you use the Irrlicht Engine, the zlib and libPng. See the README files - in the jpeglib, the zlib and libPng for further informations. + in the jpeglib, the zlib and libPng for further information. */ #ifndef __IRRLICHT_H_INCLUDED__ @@ -268,7 +268,7 @@ * } * \endcode * - * Irrlicht can load a lot of file formats automaticly, see irr::scene::ISceneManager::getMesh() + * Irrlicht can load a lot of file formats automatically, see irr::scene::ISceneManager::getMesh() * for a detailed list. So if you would like to replace the simple blue screen background by * a cool Quake 3 Map, optimized by an octree, just insert this code * somewhere before the while loop: @@ -319,7 +319,7 @@ namespace irr \param stencilbuffer: Specifies if the stencil buffer should be enabled. Set this to true, if you want the engine be able to draw stencil buffer shadows. Note that not all devices are able to use the stencil buffer. If they don't no shadows will be drawn. - \param vsync: Specifies vertical syncronisation: If set to true, the driver will wait + \param vsync: Specifies vertical synchronization: If set to true, the driver will wait for the vertical retrace period, otherwise not. \param receiver: A user created event receiver. \return Returns pointer to the created IrrlichtDevice or null if the @@ -327,7 +327,7 @@ namespace irr */ extern "C" IRRLICHT_API IrrlichtDevice* IRRCALLCONV createDevice( video::E_DRIVER_TYPE deviceType = video::EDT_SOFTWARE, - // parantheses are necessary for some compilers + // parentheses are necessary for some compilers const core::dimension2d& windowSize = (core::dimension2d(640,480)), u32 bits = 32, bool fullscreen = false, diff --git a/include/line2d.h b/include/line2d.h index 80426247..6037bb1d 100644 --- a/include/line2d.h +++ b/include/line2d.h @@ -73,7 +73,8 @@ class line2d When set to false the function will check for the first intersection point when extending the lines. \param out: If there is an intersection, the location of the intersection will be stored in this vector. - \param ignoreCoincidentLines: When true coincident lines (lines above each other) are never considered as interesecting. When false the center of the overlapping part is returned. + \param ignoreCoincidentLines: When true coincident lines (lines above each other) are never considered as intersecting. + When false the center of the overlapping part is returned. \return True if there is an intersection, false if not. */ bool intersectWith(const line2d& l, vector2d& out, bool checkOnlySegments=true, bool ignoreCoincidentLines=false) const { diff --git a/include/line3d.h b/include/line3d.h index 4a6346ab..355c52f5 100644 --- a/include/line3d.h +++ b/include/line3d.h @@ -103,8 +103,8 @@ class line3d return start + v; } - //! Check if the line intersects with a shpere - /** \param sorigin: Origin of the shpere. + //! Check if the line intersects with a sphere + /** \param sorigin: Origin of the sphere. \param sradius: Radius of the sphere. \param outdistance: The distance to the first intersection point. \return True if there is an intersection. diff --git a/include/matrix4.h b/include/matrix4.h index a9b8ab1f..9d37f7ad 100644 --- a/include/matrix4.h +++ b/include/matrix4.h @@ -14,7 +14,7 @@ #include "irrString.h" // enable this to keep track of changes to the matrix -// and make simpler identity check for seldomly changing matrices +// and make simpler identity check for seldom changing matrices // otherwise identity check will always compare the elements //#define USE_MATRIX_TEST @@ -263,7 +263,7 @@ namespace core /** \param out: where result matrix is written to. */ bool getInversePrimitive ( CMatrix4& out ) const; - //! Gets the inversed matrix of this one + //! Gets the inverse matrix of this one /** \param out: where result matrix is written to. \return Returns false if there is no inverse matrix. */ bool getInverse(CMatrix4& out) const; @@ -873,7 +873,7 @@ namespace core /** This code was sent in by Chev. Note that it does not necessarily return the *same* Euler angles as those set by setRotationDegrees(), but the rotation will be equivalent, i.e. will have the same result when used to rotate a vector or node. - This code was orginally written by by Chev. + This code was originally written by by Chev. */ template inline core::vector3d CMatrix4::getRotationDegrees(const vector3d& scale_) const @@ -934,7 +934,7 @@ namespace core /** This code was sent in by Chev. Note that it does not necessarily return the *same* Euler angles as those set by setRotationDegrees(), but the rotation will be equivalent, i.e. will have the same result when used to rotate a vector or node. - This code was orginally written by by Chev. */ + This code was originally written by by Chev. */ template inline core::vector3d CMatrix4::getRotationDegrees() const { @@ -2068,7 +2068,7 @@ namespace core } - //! Builds a combined matrix which translate to a center before rotation and translate afterwards + //! Builds a combined matrix which translate to a center before rotation and translate afterward template inline void CMatrix4::setRotationCenter(const core::vector3df& center, const core::vector3df& translation) { diff --git a/include/quaternion.h b/include/quaternion.h index fa0c7634..6435a85a 100644 --- a/include/quaternion.h +++ b/include/quaternion.h @@ -38,10 +38,10 @@ class quaternion //! Constructor quaternion(f32 x, f32 y, f32 z, f32 w) : X(x), Y(y), Z(z), W(w) { } - //! Constructor which converts euler angles (radians) to a quaternion + //! Constructor which converts Euler angles (radians) to a quaternion quaternion(f32 x, f32 y, f32 z); - //! Constructor which converts euler angles (radians) to a quaternion + //! Constructor which converts Euler angles (radians) to a quaternion quaternion(const vector3df& vec); #ifndef IRR_TEST_BROKEN_QUATERNION_USE @@ -49,7 +49,7 @@ class quaternion quaternion(const matrix4& mat); #endif - //! Equalilty operator + //! Equality operator bool operator==(const quaternion& other) const; //! inequality operator @@ -88,10 +88,10 @@ class quaternion //! Sets new quaternion inline quaternion& set(f32 x, f32 y, f32 z, f32 w); - //! Sets new quaternion based on euler angles (radians) + //! Sets new quaternion based on Euler angles (radians) inline quaternion& set(f32 x, f32 y, f32 z); - //! Sets new quaternion based on euler angles (radians) + //! Sets new quaternion based on Euler angles (radians) inline quaternion& set(const core::vector3df& vec); //! Sets new quaternion from other quaternion @@ -172,7 +172,7 @@ class quaternion //! Fills an angle (radians) around an axis (unit vector) void toAngleAxis (f32 &angle, core::vector3df& axis) const; - //! Output this quaternion to an euler angle (radians) + //! Output this quaternion to an Euler angle (radians) void toEuler(vector3df& euler) const; //! Set quaternion to identity @@ -189,14 +189,14 @@ class quaternion }; -// Constructor which converts euler angles to a quaternion +// Constructor which converts Euler angles to a quaternion inline quaternion::quaternion(f32 x, f32 y, f32 z) { set(x,y,z); } -// Constructor which converts euler angles to a quaternion +// Constructor which converts Euler angles to a quaternion inline quaternion::quaternion(const vector3df& vec) { set(vec.X,vec.Y,vec.Z); @@ -459,7 +459,7 @@ inline quaternion& quaternion::set(f32 x, f32 y, f32 z, f32 w) } -// sets new quaternion based on euler angles +// sets new quaternion based on Euler angles inline quaternion& quaternion::set(f32 x, f32 y, f32 z) { f64 angle; @@ -489,7 +489,7 @@ inline quaternion& quaternion::set(f32 x, f32 y, f32 z) return normalize(); } -// sets new quaternion based on euler angles +// sets new quaternion based on Euler angles inline quaternion& quaternion::set(const core::vector3df& vec) { return set(vec.X, vec.Y, vec.Z); diff --git a/include/triangle3d.h b/include/triangle3d.h index f5f88ccd..dab52497 100644 --- a/include/triangle3d.h +++ b/include/triangle3d.h @@ -100,7 +100,7 @@ namespace core //! Check if a point is inside the triangle (border-points count also as inside) /** This method uses a barycentric coordinate system. It is faster than isPointInside but is more susceptible to floating point rounding - errors. This will especially be noticable when the FPU is in single precision mode + errors. This will especially be noticeable when the FPU is in single precision mode (which is for example set on default by Direct3D). \param p Point to test. Assumes that this point is already on the plane of the triangle. diff --git a/include/vector2d.h b/include/vector2d.h index 94e7f544..1e597f3c 100644 --- a/include/vector2d.h +++ b/include/vector2d.h @@ -15,7 +15,7 @@ namespace core //! 2d vector template class with lots of operators and methods. -/** As of Irrlicht 1.6, this class supercedes position2d, which should +/** As of Irrlicht 1.6, this class supersedes position2d, which should be considered deprecated. */ template class vector2d diff --git a/include/vector3d.h b/include/vector3d.h index c567e3c0..31d118bd 100644 --- a/include/vector3d.h +++ b/include/vector3d.h @@ -417,7 +417,7 @@ namespace core }; //! partial specialization for integer vectors - // Implementor note: inline keyword needed due to template specialization for s32. Otherwise put specialization into a .cpp + // Implementer note: inline keyword needed due to template specialization for s32. Otherwise put specialization into a .cpp template <> inline vector3d vector3d::operator /(s32 val) const {return core::vector3d(X/val,Y/val,Z/val);} template <> diff --git a/lib/Win64-visualStudio/readme.txt b/lib/Win64-visualStudio/readme.txt deleted file mode 100644 index 7260e145..00000000 --- a/lib/Win64-visualStudio/readme.txt +++ /dev/null @@ -1,11 +0,0 @@ -We don't provide a procompiled dll for Win64. - -Visual Studio Express does not come with a 64-bit compiler by default. -You'll have to download the Windows Platform SDK- - -http://msdn.microsoft.com/en-us/windows/bb980924.aspx - -When installing the platform SDK, make sure you install the x64 and -IA64 compilers from Developer Tools -> Visual C++ Compilers. -If you're using VC Express you will only be able to compile from the -command line. \ No newline at end of file diff --git a/readme.txt b/readme.txt index 5ee9fbe6..f426b027 100644 --- a/readme.txt +++ b/readme.txt @@ -75,7 +75,7 @@ The Irrlicht Engine SDK version 1.9 work as well, we simply didn't test them. * gcc 4.x - * Visual Studio 2008(9.0)-2012(11.0) + * Visual Studio 2010(10.0)-2013(12.0) * Code::Blocks (& gcc or visual studio toolkit) If you ever want to (re)compile the engine yourself (which means you don't @@ -170,7 +170,7 @@ The Irrlicht Engine SDK version 1.9 See http://irrlicht.sourceforge.net/author.html for more informations) Christian Stehno (hybrid) Contribution Coordinator/Developer - Michael Zeilfelder (cutealien) GUI Developer + Michael Zeilfelder (cutealien) Developer Patryk Nadrowski (Nadro) Developer Yoran Bosman (Yoran) Webserver administrator Gareth Davidson (bitplane) Developer/ Forum admin diff --git a/source/Irrlicht/CAttributeImpl.h b/source/Irrlicht/CAttributeImpl.h index d7096b60..569d6797 100644 --- a/source/Irrlicht/CAttributeImpl.h +++ b/source/Irrlicht/CAttributeImpl.h @@ -1686,11 +1686,11 @@ public: setString(value); } - CStringAttribute(const char* name, void* binaryData, s32 lenghtInBytes) + CStringAttribute(const char* name, void* binaryData, s32 lengthInBytes) { IsStringW=false; Name = name; - setBinary(binaryData, lenghtInBytes); + setBinary(binaryData, lengthInBytes); } virtual s32 getInt() _IRR_OVERRIDE_ @@ -1854,8 +1854,8 @@ class CBinaryAttribute : public CStringAttribute { public: - CBinaryAttribute(const char* name, void* binaryData, s32 lenghtInBytes) - : CStringAttribute(name, binaryData, lenghtInBytes) + CBinaryAttribute(const char* name, void* binaryData, s32 lengthInBytes) + : CStringAttribute(name, binaryData, lengthInBytes) { } diff --git a/source/Irrlicht/CCSMLoader.h b/source/Irrlicht/CCSMLoader.h index ecaddd7f..ed5fbda2 100644 --- a/source/Irrlicht/CCSMLoader.h +++ b/source/Irrlicht/CCSMLoader.h @@ -33,7 +33,7 @@ // * Presents the loaded file as irr::scene::IAnimatedMesh for easy creation of IOctreeSceneNode // * Loads the textures given the correct texture root. hence map and textures can be in separate directories // -// For more informations go to http://www.geocities.com/standard_template/irrcsm/downloads.html +// For more information go to http://www.geocities.com/standard_template/irrcsm/downloads.html #ifndef __CSM_LOADER_H_INCLUDED__ #define __CSM_LOADER_H_INCLUDED__ diff --git a/source/Irrlicht/CCameraSceneNode.h b/source/Irrlicht/CCameraSceneNode.h index b1cd13c8..6f16a99b 100644 --- a/source/Irrlicht/CCameraSceneNode.h +++ b/source/Irrlicht/CCameraSceneNode.h @@ -139,7 +139,7 @@ namespace scene //! Returns type of the scene node virtual ESCENE_NODE_TYPE getType() const _IRR_OVERRIDE_ { return ESNT_CAMERA; } - //! Binds the camera scene node's rotation to its target position and vice vera, or unbinds them. + //! Binds the camera scene node's rotation to its target position and vice versa, or unbinds them. virtual void bindTargetAndRotation(bool bound) _IRR_OVERRIDE_; //! Queries if the camera scene node's rotation and its target position are bound together. diff --git a/source/Irrlicht/CD3D9Driver.cpp b/source/Irrlicht/CD3D9Driver.cpp index f63c1254..220ab2a3 100644 --- a/source/Irrlicht/CD3D9Driver.cpp +++ b/source/Irrlicht/CD3D9Driver.cpp @@ -2848,7 +2848,7 @@ bool CD3D9Driver::reset() for (u32 j = 0; j < texArray.size(); ++j) { CD3D9Texture* tex = static_cast(texArray[j]); - + if (tex) tex->releaseTexture(); } @@ -2881,7 +2881,7 @@ bool CD3D9Driver::reset() // automatically in the next render cycle. removeAllHardwareBuffers(); - // reset render target usage informations. + // reset render target usage information. for (u32 i = 0; i < ActiveRenderTarget.size(); ++i) ActiveRenderTarget[i] = false; diff --git a/source/Irrlicht/CD3D9HLSLMaterialRenderer.cpp b/source/Irrlicht/CD3D9HLSLMaterialRenderer.cpp index 3e5c92e9..1ca26765 100644 --- a/source/Irrlicht/CD3D9HLSLMaterialRenderer.cpp +++ b/source/Irrlicht/CD3D9HLSLMaterialRenderer.cpp @@ -103,7 +103,7 @@ bool CD3D9HLSLMaterialRenderer::createHLSLVertexShader(const char* vertexShaderP #else - // compile shader and emitt some debug informations to + // compile shader and emit some debug information to // make it possible to debug the shader in visual studio static int irr_dbg_hlsl_file_nr = 0; @@ -205,7 +205,7 @@ bool CD3D9HLSLMaterialRenderer::createHLSLPixelShader(const char* pixelShaderPro #else - // compile shader and emitt some debug informations to + // compile shader and emit some debug information to // make it possible to debug the shader in visual studio static int irr_dbg_hlsl_file_nr = 0; diff --git a/source/Irrlicht/CD3D9MaterialRenderer.h b/source/Irrlicht/CD3D9MaterialRenderer.h index 010b786d..fb81391d 100644 --- a/source/Irrlicht/CD3D9MaterialRenderer.h +++ b/source/Irrlicht/CD3D9MaterialRenderer.h @@ -283,7 +283,7 @@ public: Driver->getBridgeCalls()->setBlend(false); } - //! Returns if the material is transparent. The scene managment needs to know this + //! Returns if the material is transparent. The scene management needs to know this //! for being able to sort the materials by opaque and transparent. virtual bool isTransparent() const _IRR_OVERRIDE_ { @@ -329,7 +329,7 @@ public: Driver->getBridgeCalls()->setBlend(false); } - //! Returns if the material is transparent. The scene managment needs to know this + //! Returns if the material is transparent. The scene management needs to know this //! for being able to sort the materials by opaque and transparent. virtual bool isTransparent() const _IRR_OVERRIDE_ { @@ -372,7 +372,7 @@ public: pID3DDevice->SetRenderState(D3DRS_ALPHATESTENABLE, FALSE); } - //! Returns if the material is transparent. The scene managment needs to know this + //! Returns if the material is transparent. The scene management needs to know this //! for being able to sort the materials by opaque and transparent. virtual bool isTransparent() const _IRR_OVERRIDE_ { @@ -560,7 +560,7 @@ public: Driver->getBridgeCalls()->setBlend(false); } - //! Returns if the material is transparent. The scene managment needs to know this + //! Returns if the material is transparent. The scene management needs to know this //! for being able to sort the materials by opaque and transparent. virtual bool isTransparent() const _IRR_OVERRIDE_ { diff --git a/source/Irrlicht/CD3D9ParallaxMapRenderer.cpp b/source/Irrlicht/CD3D9ParallaxMapRenderer.cpp index 2f4e6410..f036fb72 100644 --- a/source/Irrlicht/CD3D9ParallaxMapRenderer.cpp +++ b/source/Irrlicht/CD3D9ParallaxMapRenderer.cpp @@ -236,7 +236,7 @@ namespace video CallBack = this; - // basicly, this thing simply compiles these hardcoded shaders if the + // basically, this thing simply compiles these hardcoded shaders if the // hardware is able to do them, otherwise it maps to the base material if (!driver->queryFeature(video::EVDF_PIXEL_SHADER_1_4) || diff --git a/source/Irrlicht/CD3D9ShaderMaterialRenderer.cpp b/source/Irrlicht/CD3D9ShaderMaterialRenderer.cpp index ef3fe84c..fecc85fa 100644 --- a/source/Irrlicht/CD3D9ShaderMaterialRenderer.cpp +++ b/source/Irrlicht/CD3D9ShaderMaterialRenderer.cpp @@ -155,7 +155,7 @@ void CD3D9ShaderMaterialRenderer::OnUnsetMaterial() } -//! Returns if the material is transparent. The scene managment needs to know this +//! Returns if the material is transparent. The scene management needs to know this //! for being able to sort the materials by opaque and transparent. bool CD3D9ShaderMaterialRenderer::isTransparent() const { @@ -179,7 +179,7 @@ bool CD3D9ShaderMaterialRenderer::createPixelShader(const c8* pxsh) stubD3DXAssembleShader(pxsh, (UINT)strlen(pxsh), 0, 0, 0, &code, &errors); #else - // compile shader and emitt some debug informations to + // compile shader and emit some debug information to // make it possible to debug the shader in visual studio static int irr_dbg_file_nr = 0; @@ -239,7 +239,7 @@ bool CD3D9ShaderMaterialRenderer::createVertexShader(const char* vtxsh) #else - // compile shader and emitt some debug informations to + // compile shader and emit some debug information to // make it possible to debug the shader in visual studio static int irr_dbg_file_nr = 0; diff --git a/source/Irrlicht/CDefaultGUIElementFactory.cpp b/source/Irrlicht/CDefaultGUIElementFactory.cpp index 768d5136..d21fbd68 100644 --- a/source/Irrlicht/CDefaultGUIElementFactory.cpp +++ b/source/Irrlicht/CDefaultGUIElementFactory.cpp @@ -119,7 +119,7 @@ s32 CDefaultGUIElementFactory::getCreatableGUIElementTypeCount() const } -//! Returns the type of a createable element type. +//! Returns the type of a creatable element type. EGUI_ELEMENT_TYPE CDefaultGUIElementFactory::getCreateableGUIElementType(s32 idx) const { if (idx>=0 && idx=0 && idx& destPos, const core::rect* clip = 0 ) _IRR_OVERRIDE_; diff --git a/source/Irrlicht/CGUIStaticText.cpp b/source/Irrlicht/CGUIStaticText.cpp index 434f9257..3821668a 100644 --- a/source/Irrlicht/CGUIStaticText.cpp +++ b/source/Irrlicht/CGUIStaticText.cpp @@ -254,7 +254,7 @@ video::SColor CGUIStaticText::getOverrideColor() const } -//! Sets if the static text should use the overide color or the +//! Sets if the static text should use the override color or the //! color in the gui skin. void CGUIStaticText::enableOverrideColor(bool enable) { diff --git a/source/Irrlicht/CGUIStaticText.h b/source/Irrlicht/CGUIStaticText.h index 21746a9a..7ca74019 100644 --- a/source/Irrlicht/CGUIStaticText.h +++ b/source/Irrlicht/CGUIStaticText.h @@ -66,7 +66,7 @@ namespace gui //! Gets the override color virtual video::SColor getOverrideColor() const _IRR_OVERRIDE_; - //! Sets if the static text should use the overide color or the + //! Sets if the static text should use the override color or the //! color in the gui skin. virtual void enableOverrideColor(bool enable) _IRR_OVERRIDE_; diff --git a/source/Irrlicht/CGUITable.cpp b/source/Irrlicht/CGUITable.cpp index d21fa4cd..fac733b6 100644 --- a/source/Irrlicht/CGUITable.cpp +++ b/source/Irrlicht/CGUITable.cpp @@ -392,7 +392,7 @@ s32 CGUITable::getSelected() const return Selected; } -//! set wich row is currently selected +//! set which row is currently selected void CGUITable::setSelected( s32 index ) { Selected = -1; diff --git a/source/Irrlicht/CImage.h b/source/Irrlicht/CImage.h index 3433e3a8..97cef188 100644 --- a/source/Irrlicht/CImage.h +++ b/source/Irrlicht/CImage.h @@ -52,7 +52,7 @@ public: const core::rect& sourceRect, const SColor &color, const core::rect* clipRect = 0) _IRR_OVERRIDE_; - //! copies this surface into another, scaling it to fit, appyling a box filter + //! copies this surface into another, scaling it to fit, applying a box filter virtual void copyToScalingBoxFilter(IImage* target, s32 bias = 0, bool blend = false) _IRR_OVERRIDE_; //! fills the surface with given color diff --git a/source/Irrlicht/CImageLoaderJPG.cpp b/source/Irrlicht/CImageLoaderJPG.cpp index 80190776..6ebe4fc1 100644 --- a/source/Irrlicht/CImageLoaderJPG.cpp +++ b/source/Irrlicht/CImageLoaderJPG.cpp @@ -125,14 +125,11 @@ bool CImageLoaderJPG::isALoadableFileFormat(io::IReadFile* file) const return false; #else - if (!file) + if (!(file && file->seek(0))) return false; - - s32 jfif = 0; - file->seek(6); - file->read(&jfif, sizeof(s32)); - return (jfif == 0x4a464946 || jfif == 0x4649464a); - + unsigned char header[3]; + int headerLen = file->read(header, sizeof(header)); + return headerLen >= 3 && !memcmp(header, "\xFF\xD8\xFF", 3); #endif } diff --git a/source/Irrlicht/CImageLoaderPNG.cpp b/source/Irrlicht/CImageLoaderPNG.cpp index 23bb5517..feae1918 100644 --- a/source/Irrlicht/CImageLoaderPNG.cpp +++ b/source/Irrlicht/CImageLoaderPNG.cpp @@ -149,7 +149,7 @@ IImage* CImageLoaderPng::loadImage(io::IReadFile* file) const s32 BitDepth; s32 ColorType; { - // Use temporary variables to avoid passing casted pointers + // Use temporary variables to avoid passing cast pointers png_uint_32 w,h; // Extract info png_get_IHDR(png_ptr, info_ptr, @@ -201,7 +201,7 @@ IImage* CImageLoaderPng::loadImage(io::IReadFile* file) const // for proper processing of the RGBA type png_read_update_info(png_ptr, info_ptr); { - // Use temporary variables to avoid passing casted pointers + // Use temporary variables to avoid passing cast pointers png_uint_32 w,h; // Extract info png_get_IHDR(png_ptr, info_ptr, diff --git a/source/Irrlicht/CImageWriterBMP.cpp b/source/Irrlicht/CImageWriterBMP.cpp index 636664af..c5fe2b8d 100644 --- a/source/Irrlicht/CImageWriterBMP.cpp +++ b/source/Irrlicht/CImageWriterBMP.cpp @@ -103,7 +103,7 @@ bool CImageWriterBMP::writeImage(io::IWriteFile* file, IImage* image, u32 param) u32 row_stride = (pixel_size * imageHeader.Width); // length of one row in bytes, rounded up to nearest 4-byte boundary - s32 row_size = ((3 * imageHeader.Width) + 3) & ~3; + size_t row_size = ((3 * imageHeader.Width) + 3) & ~3; // allocate and clear memory for our scan line u8* row_pointer = new u8[row_size]; diff --git a/source/Irrlicht/CImageWriterJPG.cpp b/source/Irrlicht/CImageWriterJPG.cpp index c42615ac..3e3b4d57 100644 --- a/source/Irrlicht/CImageWriterJPG.cpp +++ b/source/Irrlicht/CImageWriterJPG.cpp @@ -72,7 +72,7 @@ static boolean jpeg_empty_output_buffer(j_compress_ptr cinfo) static void jpeg_term_destination(j_compress_ptr cinfo) { mem_dest_ptr dest = (mem_dest_ptr) cinfo->dest; - const s32 datacount = (s32)(OUTPUT_BUF_SIZE - dest->pub.free_in_buffer); + const size_t datacount = OUTPUT_BUF_SIZE - dest->pub.free_in_buffer; // for now just exit upon file error if (dest->file->write(dest->buffer, datacount) != datacount) ERREXIT (cinfo, JERR_FILE_WRITE); diff --git a/source/Irrlicht/CImageWriterPPM.cpp b/source/Irrlicht/CImageWriterPPM.cpp index aa821891..fd0db971 100644 --- a/source/Irrlicht/CImageWriterPPM.cpp +++ b/source/Irrlicht/CImageWriterPPM.cpp @@ -50,16 +50,22 @@ bool CImageWriterPPM::writeImage(io::IWriteFile *file, IImage *image, u32 param) size = snprintf_irr(cache, 70, "P6\n"); else size = snprintf_irr(cache, 70, "P3\n"); + if ( size < 0 ) + return false; - if (file->write(cache, size) != size) + if (file->write(cache, (size_t)size) != (size_t)size) return false; size = snprintf_irr(cache, 70, "%u %u\n", imageSize.Width, imageSize.Height); - if (file->write(cache, size) != size) + if ( size < 0 ) + return false; + if (file->write(cache, (size_t)size) != (size_t)size) return false; size = snprintf_irr(cache, 70, "255\n"); - if (file->write(cache, size) != size) + if ( size < 0 ) + return false; + if (file->write(cache, (size_t)size) != (size_t)size) return false; if (binary) @@ -88,7 +94,9 @@ bool CImageWriterPPM::writeImage(io::IWriteFile *file, IImage *image, u32 param) { const video::SColor& pixel = image->getPixel(c, h); size = snprintf_irr(cache, 70, "%.3u %.3u %.3u%s", pixel.getRed(), pixel.getGreen(), pixel.getBlue(), n % 5 == 4 ? "\n" : " "); - if (file->write(cache, size) != size) + if ( size < 0 ) + return false; + if (file->write(cache, (size_t)size) != (size_t)size) return false; } } diff --git a/source/Irrlicht/CImageWriterTGA.cpp b/source/Irrlicht/CImageWriterTGA.cpp index 34198cb1..e5632b5a 100644 --- a/source/Irrlicht/CImageWriterTGA.cpp +++ b/source/Irrlicht/CImageWriterTGA.cpp @@ -106,7 +106,7 @@ bool CImageWriterTGA::writeImage(io::IWriteFile *file, IImage *image,u32 param) u32 row_stride = (pixel_size * imageHeader.ImageWidth); // length of one output row in bytes - s32 row_size = ((imageHeader.PixelDepth / 8) * imageHeader.ImageWidth); + size_t row_size = ((imageHeader.PixelDepth / 8) * imageHeader.ImageWidth); // allocate a row do translate data into u8* row_pointer = new u8[row_size]; diff --git a/source/Irrlicht/CIrrDeviceOSX.mm b/source/Irrlicht/CIrrDeviceOSX.mm index 849506d0..363a84f7 100644 --- a/source/Irrlicht/CIrrDeviceOSX.mm +++ b/source/Irrlicht/CIrrDeviceOSX.mm @@ -47,147 +47,6 @@ #include #include -// only OSX 10.5 seems to not need these defines... -#if !defined(__MAC_10_5) || defined(__MAC_10_6) -// Contents from Events.h from Carbon/HIToolbox but we need it with Cocoa too -// and for some reason no Cocoa equivalent of these constants seems provided. -// So I'm doing like everyone else and using copy-and-paste. - -/* - * Summary: - * Virtual keycodes - * - * Discussion: - * These constants are the virtual keycodes defined originally in - * Inside Mac Volume V, pg. V-191. They identify physical keys on a - * keyboard. Those constants with "ANSI" in the name are labeled - * according to the key position on an ANSI-standard US keyboard. - * For example, kVK_ANSI_A indicates the virtual keycode for the key - * with the letter 'A' in the US keyboard layout. Other keyboard - * layouts may have the 'A' key label on a different physical key; - * in this case, pressing 'A' will generate a different virtual - * keycode. - */ -enum { - kVK_ANSI_A = 0x00, - kVK_ANSI_S = 0x01, - kVK_ANSI_D = 0x02, - kVK_ANSI_F = 0x03, - kVK_ANSI_H = 0x04, - kVK_ANSI_G = 0x05, - kVK_ANSI_Z = 0x06, - kVK_ANSI_X = 0x07, - kVK_ANSI_C = 0x08, - kVK_ANSI_V = 0x09, - kVK_ANSI_B = 0x0B, - kVK_ANSI_Q = 0x0C, - kVK_ANSI_W = 0x0D, - kVK_ANSI_E = 0x0E, - kVK_ANSI_R = 0x0F, - kVK_ANSI_Y = 0x10, - kVK_ANSI_T = 0x11, - kVK_ANSI_1 = 0x12, - kVK_ANSI_2 = 0x13, - kVK_ANSI_3 = 0x14, - kVK_ANSI_4 = 0x15, - kVK_ANSI_6 = 0x16, - kVK_ANSI_5 = 0x17, - kVK_ANSI_Equal = 0x18, - kVK_ANSI_9 = 0x19, - kVK_ANSI_7 = 0x1A, - kVK_ANSI_Minus = 0x1B, - kVK_ANSI_8 = 0x1C, - kVK_ANSI_0 = 0x1D, - kVK_ANSI_RightBracket = 0x1E, - kVK_ANSI_O = 0x1F, - kVK_ANSI_U = 0x20, - kVK_ANSI_LeftBracket = 0x21, - kVK_ANSI_I = 0x22, - kVK_ANSI_P = 0x23, - kVK_ANSI_L = 0x25, - kVK_ANSI_J = 0x26, - kVK_ANSI_Quote = 0x27, - kVK_ANSI_K = 0x28, - kVK_ANSI_Semicolon = 0x29, - kVK_ANSI_Backslash = 0x2A, - kVK_ANSI_Comma = 0x2B, - kVK_ANSI_Slash = 0x2C, - kVK_ANSI_N = 0x2D, - kVK_ANSI_M = 0x2E, - kVK_ANSI_Period = 0x2F, - kVK_ANSI_Grave = 0x32, - kVK_ANSI_KeypadDecimal = 0x41, - kVK_ANSI_KeypadMultiply = 0x43, - kVK_ANSI_KeypadPlus = 0x45, - kVK_ANSI_KeypadClear = 0x47, - kVK_ANSI_KeypadDivide = 0x4B, - kVK_ANSI_KeypadEnter = 0x4C, - kVK_ANSI_KeypadMinus = 0x4E, - kVK_ANSI_KeypadEquals = 0x51, - kVK_ANSI_Keypad0 = 0x52, - kVK_ANSI_Keypad1 = 0x53, - kVK_ANSI_Keypad2 = 0x54, - kVK_ANSI_Keypad3 = 0x55, - kVK_ANSI_Keypad4 = 0x56, - kVK_ANSI_Keypad5 = 0x57, - kVK_ANSI_Keypad6 = 0x58, - kVK_ANSI_Keypad7 = 0x59, - kVK_ANSI_Keypad8 = 0x5B, - kVK_ANSI_Keypad9 = 0x5C -}; - -/* keycodes for keys that are independent of keyboard layout*/ -enum { - kVK_Return = 0x24, - kVK_Tab = 0x30, - kVK_Space = 0x31, - kVK_Delete = 0x33, - kVK_Escape = 0x35, - kVK_Command = 0x37, - kVK_Shift = 0x38, - kVK_CapsLock = 0x39, - kVK_Option = 0x3A, - kVK_Control = 0x3B, - kVK_RightShift = 0x3C, - kVK_RightOption = 0x3D, - kVK_RightControl = 0x3E, - kVK_Function = 0x3F, - kVK_F17 = 0x40, - kVK_VolumeUp = 0x48, - kVK_VolumeDown = 0x49, - kVK_Mute = 0x4A, - kVK_F18 = 0x4F, - kVK_F19 = 0x50, - kVK_F20 = 0x5A, - kVK_F5 = 0x60, - kVK_F6 = 0x61, - kVK_F7 = 0x62, - kVK_F3 = 0x63, - kVK_F8 = 0x64, - kVK_F9 = 0x65, - kVK_F11 = 0x67, - kVK_F13 = 0x69, - kVK_F16 = 0x6A, - kVK_F14 = 0x6B, - kVK_F10 = 0x6D, - kVK_F12 = 0x6F, - kVK_F15 = 0x71, - kVK_Help = 0x72, - kVK_Home = 0x73, - kVK_PageUp = 0x74, - kVK_ForwardDelete = 0x75, - kVK_F4 = 0x76, - kVK_End = 0x77, - kVK_F2 = 0x78, - kVK_PageDown = 0x79, - kVK_F1 = 0x7A, - kVK_LeftArrow = 0x7B, - kVK_RightArrow = 0x7C, - kVK_DownArrow = 0x7D, - kVK_UpArrow = 0x7E -}; -#endif - struct JoystickComponent { IOHIDElementCookie cookie; // unique value which identifies element, will NOT change @@ -442,6 +301,147 @@ static void getJoystickDeviceInfo (io_object_t hidDevice, CFMutableDictionaryRef #endif // _IRR_COMPILE_WITH_JOYSTICK_EVENTS_ +// only OSX 10.5 seems to not need these defines... +#if !defined(__MAC_10_5) || defined(__MAC_10_6) +// Contents from Events.h from Carbon/HIToolbox but we need it with Cocoa too +// and for some reason no Cocoa equivalent of these constants seems provided. +// So I'm doing like everyone else and using copy-and-paste. + +/* + * Summary: + * Virtual keycodes + * + * Discussion: + * These constants are the virtual keycodes defined originally in + * Inside Mac Volume V, pg. V-191. They identify physical keys on a + * keyboard. Those constants with "ANSI" in the name are labeled + * according to the key position on an ANSI-standard US keyboard. + * For example, kVK_ANSI_A indicates the virtual keycode for the key + * with the letter 'A' in the US keyboard layout. Other keyboard + * layouts may have the 'A' key label on a different physical key; + * in this case, pressing 'A' will generate a different virtual + * keycode. + */ +enum { + kVK_ANSI_A = 0x00, + kVK_ANSI_S = 0x01, + kVK_ANSI_D = 0x02, + kVK_ANSI_F = 0x03, + kVK_ANSI_H = 0x04, + kVK_ANSI_G = 0x05, + kVK_ANSI_Z = 0x06, + kVK_ANSI_X = 0x07, + kVK_ANSI_C = 0x08, + kVK_ANSI_V = 0x09, + kVK_ANSI_B = 0x0B, + kVK_ANSI_Q = 0x0C, + kVK_ANSI_W = 0x0D, + kVK_ANSI_E = 0x0E, + kVK_ANSI_R = 0x0F, + kVK_ANSI_Y = 0x10, + kVK_ANSI_T = 0x11, + kVK_ANSI_1 = 0x12, + kVK_ANSI_2 = 0x13, + kVK_ANSI_3 = 0x14, + kVK_ANSI_4 = 0x15, + kVK_ANSI_6 = 0x16, + kVK_ANSI_5 = 0x17, + kVK_ANSI_Equal = 0x18, + kVK_ANSI_9 = 0x19, + kVK_ANSI_7 = 0x1A, + kVK_ANSI_Minus = 0x1B, + kVK_ANSI_8 = 0x1C, + kVK_ANSI_0 = 0x1D, + kVK_ANSI_RightBracket = 0x1E, + kVK_ANSI_O = 0x1F, + kVK_ANSI_U = 0x20, + kVK_ANSI_LeftBracket = 0x21, + kVK_ANSI_I = 0x22, + kVK_ANSI_P = 0x23, + kVK_ANSI_L = 0x25, + kVK_ANSI_J = 0x26, + kVK_ANSI_Quote = 0x27, + kVK_ANSI_K = 0x28, + kVK_ANSI_Semicolon = 0x29, + kVK_ANSI_Backslash = 0x2A, + kVK_ANSI_Comma = 0x2B, + kVK_ANSI_Slash = 0x2C, + kVK_ANSI_N = 0x2D, + kVK_ANSI_M = 0x2E, + kVK_ANSI_Period = 0x2F, + kVK_ANSI_Grave = 0x32, + kVK_ANSI_KeypadDecimal = 0x41, + kVK_ANSI_KeypadMultiply = 0x43, + kVK_ANSI_KeypadPlus = 0x45, + kVK_ANSI_KeypadClear = 0x47, + kVK_ANSI_KeypadDivide = 0x4B, + kVK_ANSI_KeypadEnter = 0x4C, + kVK_ANSI_KeypadMinus = 0x4E, + kVK_ANSI_KeypadEquals = 0x51, + kVK_ANSI_Keypad0 = 0x52, + kVK_ANSI_Keypad1 = 0x53, + kVK_ANSI_Keypad2 = 0x54, + kVK_ANSI_Keypad3 = 0x55, + kVK_ANSI_Keypad4 = 0x56, + kVK_ANSI_Keypad5 = 0x57, + kVK_ANSI_Keypad6 = 0x58, + kVK_ANSI_Keypad7 = 0x59, + kVK_ANSI_Keypad8 = 0x5B, + kVK_ANSI_Keypad9 = 0x5C +}; + +/* keycodes for keys that are independent of keyboard layout*/ +enum { + kVK_Return = 0x24, + kVK_Tab = 0x30, + kVK_Space = 0x31, + kVK_Delete = 0x33, + kVK_Escape = 0x35, + kVK_Command = 0x37, + kVK_Shift = 0x38, + kVK_CapsLock = 0x39, + kVK_Option = 0x3A, + kVK_Control = 0x3B, + kVK_RightShift = 0x3C, + kVK_RightOption = 0x3D, + kVK_RightControl = 0x3E, + kVK_Function = 0x3F, + kVK_F17 = 0x40, + kVK_VolumeUp = 0x48, + kVK_VolumeDown = 0x49, + kVK_Mute = 0x4A, + kVK_F18 = 0x4F, + kVK_F19 = 0x50, + kVK_F20 = 0x5A, + kVK_F5 = 0x60, + kVK_F6 = 0x61, + kVK_F7 = 0x62, + kVK_F3 = 0x63, + kVK_F8 = 0x64, + kVK_F9 = 0x65, + kVK_F11 = 0x67, + kVK_F13 = 0x69, + kVK_F16 = 0x6A, + kVK_F14 = 0x6B, + kVK_F10 = 0x6D, + kVK_F12 = 0x6F, + kVK_F15 = 0x71, + kVK_Help = 0x72, + kVK_Home = 0x73, + kVK_PageUp = 0x74, + kVK_ForwardDelete = 0x75, + kVK_F4 = 0x76, + kVK_End = 0x77, + kVK_F2 = 0x78, + kVK_PageDown = 0x79, + kVK_F1 = 0x7A, + kVK_LeftArrow = 0x7B, + kVK_RightArrow = 0x7C, + kVK_DownArrow = 0x7D, + kVK_UpArrow = 0x7E +}; +#endif + //------------------------------------------------------------------------------------------ Boolean GetDictionaryBoolean(CFDictionaryRef theDict, const void* key) { diff --git a/source/Irrlicht/CIrrDeviceWin32.cpp b/source/Irrlicht/CIrrDeviceWin32.cpp index 38d10fe5..1fd84b4c 100644 --- a/source/Irrlicht/CIrrDeviceWin32.cpp +++ b/source/Irrlicht/CIrrDeviceWin32.cpp @@ -1186,7 +1186,7 @@ void CIrrDeviceWin32::createDriver() { case video::DEPRECATED_EDT_DIRECT3D8_NO_LONGER_EXISTS: os::Printer::log("DIRECT3D8 Driver is no longer supported in Irrlicht. Try another one.", ELL_ERROR); - break; + break; case video::EDT_DIRECT3D9: #ifdef _IRR_COMPILE_WITH_DIRECT3D_9_ VideoDriver = video::createDirectX9Driver(CreationParams, FileSystem, HWnd); @@ -1500,7 +1500,7 @@ bool CIrrDeviceWin32::switchToFullScreen(bool reset) os::Printer::log("Switch to fullscreen: The graphics mode is not supported.", ELL_ERROR); break; default: - os::Printer::log("An unknown error occured while changing to fullscreen.", ELL_ERROR); + os::Printer::log("An unknown error occurred while changing to fullscreen.", ELL_ERROR); break; } return ret; diff --git a/source/Irrlicht/CLimitReadFile.cpp b/source/Irrlicht/CLimitReadFile.cpp index 51afaad4..f65b7004 100644 --- a/source/Irrlicht/CLimitReadFile.cpp +++ b/source/Irrlicht/CLimitReadFile.cpp @@ -37,18 +37,18 @@ CLimitReadFile::~CLimitReadFile() //! returns how much was read -s32 CLimitReadFile::read(void* buffer, u32 sizeToRead) +size_t CLimitReadFile::read(void* buffer, size_t sizeToRead) { -#if 1 if (0 == File) return 0; - s32 r = AreaStart + Pos; - s32 toRead = core::s32_min(AreaEnd, r + sizeToRead) - core::s32_max(AreaStart, r); +#if 1 + long r = AreaStart + Pos; + long toRead = core::min_(AreaEnd, r + (long)sizeToRead) - core::max_(AreaStart, r); if (toRead < 0) return 0; File->seek(r); - r = File->read(buffer, toRead); + r = (long)File->read(buffer, toRead); Pos += r; return r; #else diff --git a/source/Irrlicht/CLimitReadFile.h b/source/Irrlicht/CLimitReadFile.h index d1bacc3c..041c8883 100644 --- a/source/Irrlicht/CLimitReadFile.h +++ b/source/Irrlicht/CLimitReadFile.h @@ -30,7 +30,7 @@ namespace io virtual ~CLimitReadFile(); //! returns how much was read - virtual s32 read(void* buffer, u32 sizeToRead) _IRR_OVERRIDE_; + virtual size_t read(void* buffer, size_t sizeToRead) _IRR_OVERRIDE_; //! changes position in file, returns true if successful //! if relativeMovement==true, the pos is changed relative to current pos, diff --git a/source/Irrlicht/CMemoryFile.cpp b/source/Irrlicht/CMemoryFile.cpp index 256f7841..22c57e65 100644 --- a/source/Irrlicht/CMemoryFile.cpp +++ b/source/Irrlicht/CMemoryFile.cpp @@ -28,9 +28,9 @@ CMemoryReadFile::~CMemoryReadFile() //! returns how much was read -s32 CMemoryReadFile::read(void* buffer, u32 sizeToRead) +size_t CMemoryReadFile::read(void* buffer, size_t sizeToRead) { - s32 amount = static_cast(sizeToRead); + long amount = static_cast(sizeToRead); if (Pos + amount > Len) amount -= Pos + amount - Len; @@ -42,7 +42,7 @@ s32 CMemoryReadFile::read(void* buffer, u32 sizeToRead) Pos += amount; - return amount; + return static_cast(amount); } //! changes position in file, returns true if successful @@ -107,9 +107,9 @@ CMemoryWriteFile::~CMemoryWriteFile() //! returns how much was written -s32 CMemoryWriteFile::write(const void* buffer, u32 sizeToWrite) +size_t CMemoryWriteFile::write(const void* buffer, size_t sizeToWrite) { - s32 amount = static_cast(sizeToWrite); + long amount = (long)sizeToWrite; if (Pos + amount > Len) amount -= Pos + amount - Len; @@ -121,7 +121,7 @@ s32 CMemoryWriteFile::write(const void* buffer, u32 sizeToWrite) Pos += amount; - return amount; + return (size_t)amount; } diff --git a/source/Irrlicht/CMemoryFile.h b/source/Irrlicht/CMemoryFile.h index 6da8894f..71f95057 100644 --- a/source/Irrlicht/CMemoryFile.h +++ b/source/Irrlicht/CMemoryFile.h @@ -29,7 +29,7 @@ namespace io virtual ~CMemoryReadFile(); //! returns how much was read - virtual s32 read(void* buffer, u32 sizeToRead) _IRR_OVERRIDE_; + virtual size_t read(void* buffer, size_t sizeToRead) _IRR_OVERRIDE_; //! changes position in file, returns true if successful virtual bool seek(long finalPos, bool relativeMovement = false) _IRR_OVERRIDE_; @@ -66,7 +66,7 @@ namespace io virtual ~CMemoryWriteFile(); //! returns how much was written - virtual s32 write(const void* buffer, u32 sizeToWrite) _IRR_OVERRIDE_; + virtual size_t write(const void* buffer, size_t sizeToWrite) _IRR_OVERRIDE_; //! changes position in file, returns true if successful virtual bool seek(long finalPos, bool relativeMovement = false) _IRR_OVERRIDE_; diff --git a/source/Irrlicht/COSOperator.h b/source/Irrlicht/COSOperator.h index 9ea6356e..d913b863 100644 --- a/source/Irrlicht/COSOperator.h +++ b/source/Irrlicht/COSOperator.h @@ -12,7 +12,7 @@ namespace irr class CIrrDeviceLinux; -//! The Operating system operator provides operation system specific methods and informations. +//! The Operating system operator provides operation system specific methods and information. class COSOperator : public IOSOperator { public: diff --git a/source/Irrlicht/COgreMeshFileLoader.h b/source/Irrlicht/COgreMeshFileLoader.h index 4f93d058..c4c4e479 100644 --- a/source/Irrlicht/COgreMeshFileLoader.h +++ b/source/Irrlicht/COgreMeshFileLoader.h @@ -1,7 +1,7 @@ // Copyright (C) 2002-2012 Nikolaus Gebhardt // This file is part of the "Irrlicht Engine". // For conditions of distribution and use, see copyright notice in irrlicht.h -// orginally written by Christian Stehno, modified by Nikolaus Gebhardt +// originally written by Christian Stehno, modified by Nikolaus Gebhardt #ifndef __C_OGRE_MESH_FILE_LOADER_H_INCLUDED__ #define __C_OGRE_MESH_FILE_LOADER_H_INCLUDED__ diff --git a/source/Irrlicht/CQuake3ShaderSceneNode.cpp b/source/Irrlicht/CQuake3ShaderSceneNode.cpp index 7b7223c7..7a0fb830 100644 --- a/source/Irrlicht/CQuake3ShaderSceneNode.cpp +++ b/source/Irrlicht/CQuake3ShaderSceneNode.cpp @@ -1155,7 +1155,7 @@ void CQuake3ShaderSceneNode::animate( u32 stage,core::matrix4 &texture ) m2.setTextureScale( f[0], f[1] ); break; case ROTATE: - // tcmod rotate + // tcmod rotate m2.setTextureRotationCenter( getAsFloat( v.content, pos ) * core::DEGTORAD * TimeAbs diff --git a/source/Irrlicht/CReadFile.cpp b/source/Irrlicht/CReadFile.cpp index 62e02527..cf90f54b 100644 --- a/source/Irrlicht/CReadFile.cpp +++ b/source/Irrlicht/CReadFile.cpp @@ -29,12 +29,12 @@ CReadFile::~CReadFile() //! returns how much was read -s32 CReadFile::read(void* buffer, u32 sizeToRead) +size_t CReadFile::read(void* buffer, size_t sizeToRead) { if (!isOpen()) return 0; - return (s32)fread(buffer, 1, sizeToRead, File); + return fread(buffer, 1, sizeToRead, File); } diff --git a/source/Irrlicht/CReadFile.h b/source/Irrlicht/CReadFile.h index 784c64c2..090e30a2 100644 --- a/source/Irrlicht/CReadFile.h +++ b/source/Irrlicht/CReadFile.h @@ -27,7 +27,7 @@ namespace io virtual ~CReadFile(); //! returns how much was read - virtual s32 read(void* buffer, u32 sizeToRead) _IRR_OVERRIDE_; + virtual size_t read(void* buffer, size_t sizeToRead) _IRR_OVERRIDE_; //! changes position in file, returns true if successful virtual bool seek(long finalPos, bool relativeMovement = false) _IRR_OVERRIDE_; diff --git a/source/Irrlicht/CSceneCollisionManager.cpp b/source/Irrlicht/CSceneCollisionManager.cpp index 67ec0aec..41424761 100644 --- a/source/Irrlicht/CSceneCollisionManager.cpp +++ b/source/Irrlicht/CSceneCollisionManager.cpp @@ -332,10 +332,10 @@ void CSceneCollisionManager::getPickedNodeFromBBAndSelector( } -//! Returns the scene node, at which the overgiven camera is looking at and +//! Returns the scene node, at which the given camera is looking at and //! which id matches the bitmask. ISceneNode* CSceneCollisionManager::getSceneNodeFromCameraBB( - ICameraSceneNode* camera, s32 idBitMask, bool noDebugObjects) + const ICameraSceneNode* camera, s32 idBitMask, bool noDebugObjects) { if (!camera) return 0; @@ -517,7 +517,7 @@ bool CSceneCollisionManager::testTriangleIntersection(SCollisionData* colData, } } - // if we havent found a collision already we will have to sweep + // if we haven't found a collision already we will have to sweep // the sphere against points and edges of the triangle. Note: A // collision inside the triangle will always happen before a // vertex or edge collision. @@ -839,9 +839,9 @@ core::vector3df CSceneCollisionManager::collideWithWorld(s32 recursionDepth, } -//! Returns a 3d ray which would go through the 2d screen coodinates. +//! Returns a 3d ray which would go through the 2d screen coordinates. core::line3d CSceneCollisionManager::getRayFromScreenCoordinates( - const core::position2d & pos, ICameraSceneNode* camera) + const core::position2d & pos, const ICameraSceneNode* camera) { core::line3d ln(0,0,0,0,0,0); @@ -879,7 +879,7 @@ core::line3d CSceneCollisionManager::getRayFromScreenCoordinates( //! Calculates 2d screen position from a 3d position. core::position2d CSceneCollisionManager::getScreenCoordinatesFrom3DPosition( - const core::vector3df & pos3d, ICameraSceneNode* camera, bool useViewPort) + const core::vector3df & pos3d, const ICameraSceneNode* camera, bool useViewPort) { if (!SceneManager || !Driver) return core::position2d(-1000,-1000); @@ -918,7 +918,7 @@ core::position2d CSceneCollisionManager::getScreenCoordinatesFrom3DPosition } -inline bool CSceneCollisionManager::getLowestRoot(f32 a, f32 b, f32 c, f32 maxR, f32* root) +inline bool CSceneCollisionManager::getLowestRoot(f32 a, f32 b, f32 c, f32 maxR, f32* root) const { // check if solution exists const f32 determinant = b*b - 4.0f*a*c; diff --git a/source/Irrlicht/CSceneCollisionManager.h b/source/Irrlicht/CSceneCollisionManager.h index 984e62bb..017b4a95 100644 --- a/source/Irrlicht/CSceneCollisionManager.h +++ b/source/Irrlicht/CSceneCollisionManager.h @@ -36,9 +36,9 @@ namespace scene s32 idBitMask=0, bool bNoDebugObjects=false, ISceneNode* root=0) _IRR_OVERRIDE_; - //! Returns the scene node, at which the overgiven camera is looking at and + //! Returns the scene node, at which the given camera is looking at and //! which id matches the bitmask. - virtual ISceneNode* getSceneNodeFromCameraBB(ICameraSceneNode* camera, + virtual ISceneNode* getSceneNodeFromCameraBB(const ICameraSceneNode* camera, s32 idBitMask=0, bool bNoDebugObjects = false) _IRR_OVERRIDE_; //! Finds the collision point of a line and lots of triangles, if there is one. @@ -61,13 +61,13 @@ namespace scene f32 slidingSpeed, const core::vector3df& gravityDirectionAndSpeed) _IRR_OVERRIDE_; - //! Returns a 3d ray which would go through the 2d screen coodinates. + //! Returns a 3d ray which would go through the 2d screen coordinates. virtual core::line3d getRayFromScreenCoordinates( - const core::position2d & pos, ICameraSceneNode* camera = 0) _IRR_OVERRIDE_; + const core::position2d & pos, const ICameraSceneNode* camera = 0) _IRR_OVERRIDE_; //! Calculates 2d screen position from a 3d position. virtual core::position2d getScreenCoordinatesFrom3DPosition( - const core::vector3df & pos, ICameraSceneNode* camera=0, bool useViewPort=false) _IRR_OVERRIDE_; + const core::vector3df & pos, const ICameraSceneNode* camera=0, bool useViewPort=false) _IRR_OVERRIDE_; //! Gets the scene node and nearest collision point for a ray based on //! the nodes' id bitmasks, bounding boxes and triangle selectors. @@ -143,7 +143,7 @@ namespace scene core::vector3df collideWithWorld(s32 recursionDepth, SCollisionData &colData, const core::vector3df& pos, const core::vector3df& vel); - inline bool getLowestRoot(f32 a, f32 b, f32 c, f32 maxR, f32* root); + inline bool getLowestRoot(f32 a, f32 b, f32 c, f32 maxR, f32* root) const; ISceneManager* SceneManager; video::IVideoDriver* Driver; diff --git a/source/Irrlicht/CSceneManager.cpp b/source/Irrlicht/CSceneManager.cpp index f4a4e711..939d2bd3 100644 --- a/source/Irrlicht/CSceneManager.cpp +++ b/source/Irrlicht/CSceneManager.cpp @@ -179,6 +179,8 @@ #include "CGeometryCreator.h" +#include + namespace irr { namespace scene @@ -1132,7 +1134,7 @@ IAnimatedMesh* CSceneManager::addVolumeLightMesh(const io::path& name, } -//! Returns the root scene node. This is the scene node wich is parent +//! Returns the root scene node. This is the scene node which is parent //! of all scene nodes. The root scene node is a special scene node which //! only exists to manage all scene nodes. It is not rendered and cannot //! be removed from the scene. @@ -1740,7 +1742,7 @@ ISceneNodeAnimator* CSceneManager::createTextureAnimator(const core::array