Commit Graph

102 Commits (990d475fbbb2653c95b992937906eb49960d02fb)

Author SHA1 Message Date
cutealien 990d475fbb Merging r5686 through r5778 from trunk to ogl-es branch (part 2)
(was in wrong folder in last commit, so only source folder got checked in).
Also adapt ES1 and ES2 driver to remove texture from OGL texture cache
(that was fixed in GL driver in the parts that got merged).


git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@5780 dfc29bdd-3216-0410-991c-e03cc46cb475
2019-02-27 20:30:26 +00:00
cutealien ac376727d0 Merging r5678 from trunk to ogl-es branch
- Add global variable MATERIAL_MAX_TEXTURES_USED for texture limit
- COpenGLCoreFeature::TextureUnit renamed to COpenGLCoreFeature::MaxTextureUnits
Drivers for ES1, ES2 and WebGL also adapted.


git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@5685 dfc29bdd-3216-0410-991c-e03cc46cb475
2019-01-17 23:11:18 +00:00
cutealien 252abab03d Merging r5652 through r5663 from trunk to ogl-es.
This is mostly about cubemap changes. ES drivers compile, but not tested
if cubemaps work with them.


git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@5664 dfc29bdd-3216-0410-991c-e03cc46cb475
2018-11-25 15:44:47 +00:00
cutealien 248526d9d5 Apply fix from r5595 to correct LastMaterial in OpenGLDriver to the OGL ES drivers.
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@5598 dfc29bdd-3216-0410-991c-e03cc46cb475
2017-12-31 20:51:50 +00:00
cutealien 54ba627a72 Separate es2 and WebGL extension handlers. Should allow to get RTT's with depht buffers > 16bit to work.
While names of WebGL extensions are 90% identical to ES2, at some point the WebGL committee seems to have decided 
that it's better to give new names to the same stuff (RTT's with depth-buffer for example, but I'm sure they had a good reason?).
So we have to split this and now have mostly independent extension handlers. Still - WebGLDriver is lazy and derives from 
ES2Driver and that derives from ES2ExtensionHandler... so unfortunately WebGL driver has now 2 extension handlers.
The way it's solved for now is that extension strings are handled by the webgl extension handler and everything else
stays for now with the ES2ExtensionHandler. Maybe we can split/merge stuff later in a better way, but I see no easy to implement improvement.
Could be we could pass extension handlers as template paramter to drivers maybe, but that's just an idea for now.


git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@5556 dfc29bdd-3216-0410-991c-e03cc46cb475
2017-10-27 16:48:00 +00:00
cutealien b5d46535e7 Remove warnings in ES1 and ES2 getColorFormatParameters functions as was done in OpenGL before.
(warnings are now produced instead of places calling those functions).


git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@5540 dfc29bdd-3216-0410-991c-e03cc46cb475
2017-08-30 13:27:27 +00:00
cutealien c20dc5cc6f Add support for ECF_A16B16G16R16F and ECF_A32B32G32R32F color formats for es2.
Use emscripten headers now for es2 when compiling with emscripten (instead of our own extension headers).
Try enabling es2 extensions for emscripten (compiles, but not yet tested)


git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@5527 dfc29bdd-3216-0410-991c-e03cc46cb475
2017-08-23 14:56:35 +00:00
cutealien e4b8e7210f Fix compiling es2 driver on platforms without GL_EXT_texture_rg.
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@5526 dfc29bdd-3216-0410-991c-e03cc46cb475
2017-08-23 13:03:36 +00:00
cutealien 62ac2fd2e1 Implement queryTextureFormat for es1 and es2 drivers.
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@5525 dfc29bdd-3216-0410-991c-e03cc46cb475
2017-08-21 14:34:56 +00:00
cutealien 33bfe098e7 Add support for more formats on ES2 (with extensions): ECF_R8, ECF_R8G8, ECF_R16F, ECF_G16R16F
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@5522 dfc29bdd-3216-0410-991c-e03cc46cb475
2017-08-18 14:50:10 +00:00
cutealien 20418b3126 Unify GLES extension handling.
Update ES extensions (first 290 now recognized)
Get examples 2 to compile in c::b (most other examples still need to fix linker settings)


git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@5521 dfc29bdd-3216-0410-991c-e03cc46cb475
2017-08-18 13:28:20 +00:00
cutealien a3d31d7a48 Make internalFormat and pixelFormat identical in ES 2 driver.
Noticed some driver bugs in emscripten when using ECF_D16 which were not identical and 
it seems that since ES 2.0 those values have to match. Specification is slightly fuzzy 
on the term (says "match", not "identical" or "equal"), but found no other interpretation online.
If I understand it correctly this also means in ES 2 we have no guarantee which format is really used internally.


git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@5493 dfc29bdd-3216-0410-991c-e03cc46cb475
2017-07-03 17:00:23 +00:00
cutealien 380d186d3f Rolled back to r5490. Was likely a misunderstanding
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@5492 dfc29bdd-3216-0410-991c-e03cc46cb475
2017-07-03 16:37:29 +00:00
cutealien 3a2a0eede9 Remove getZBufferBits from ogl-es drivers.
It's never used. Also if I guess the intended use for it correctly (figuring out internFormat to use for depth-buffer textures)
then there will be a problem with that implementation as it only works for OpenGL that way (maybe also ES1.0, not sure there, but for ES2.0 it looks wrong).


git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@5491 dfc29bdd-3216-0410-991c-e03cc46cb475
2017-07-03 16:08:44 +00:00
cutealien 7766187be4 Use new zbuffer-test (which was already in OpenGL) in OGL-ES1 and OGL-ES2 drivers.
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@5477 dfc29bdd-3216-0410-991c-e03cc46cb475
2017-06-08 13:11:46 +00:00
cutealien 56e72da4a7 Merge revisions r5455:r5474 from trunk to ogl-es
Add color-mask fixes to ogles2 and webgl drivers.


git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@5475 dfc29bdd-3216-0410-991c-e03cc46cb475
2017-06-07 15:20:59 +00:00
cutealien c3ed02c8d0 setRenderStates3DMode in ES1 and ES2 now use setBlendFunc with (GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA) instead of (GL_ONE, GL_ONE_MINUS_SRC_COLOR).
This prevents color blending with background when we only want alpha blending (when EBO_ADD is set in materials).
It's something that was changed a few years ago in the OpenGL driver, but never made it into the ES drivers.
Note that transparency in ES1 _is_ currently broken - but it was broken before this patch already (so another bug to hunt).


git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@5473 dfc29bdd-3216-0410-991c-e03cc46cb475
2017-06-07 10:21:30 +00:00
cutealien b46adf170d Add line numbers to gl errors in es1 and es2 drivers.
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@5462 dfc29bdd-3216-0410-991c-e03cc46cb475
2017-05-25 14:57:27 +00:00
cutealien 9fb422b496 Make most variables in OGLES2Driver private again (had been changed while developing WebGL driver).
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@5446 dfc29bdd-3216-0410-991c-e03cc46cb475
2017-04-21 12:32:35 +00:00
cutealien b8cf4ca4bf Split ogles2 shader for 2D rendering into a texture and non-texture variant.
That's otherwise hard to do from user-code because 2d rendering works a little different than 3d.
This way it renders faster and also won't cause any warnings in WebGL.


git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@5445 dfc29bdd-3216-0410-991c-e03cc46cb475
2017-04-21 12:11:19 +00:00
cutealien c4e74c6350 Essential driver functions for GUI now working in WebGL driver.
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@5443 dfc29bdd-3216-0410-991c-e03cc46cb475
2017-04-20 12:28:11 +00:00
cutealien f2392c775b Remove debug code in OOGLES2Driver which got checked-in accidentally.
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@5442 dfc29bdd-3216-0410-991c-e03cc46cb475
2017-04-20 10:08:37 +00:00
cutealien 4a5eaeb45d Add support for (experimental) WebGL1 driver for emscripten (still work in process).
It's a reduced OGLES2 driver which tries to work only with bound buffers.
This allows emsripten to compile without "-s FULL_ES2=1" (the WebGL simulation) 
which is a lot faster. Driver can already run simply examples, but is not yet complete.


git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@5441 dfc29bdd-3216-0410-991c-e03cc46cb475
2017-04-19 17:30:37 +00:00
cutealien 3ac8d2649a ogles1 and ogles2 drivers now support meshbuffers with other primitives than just triangles.
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@5432 dfc29bdd-3216-0410-991c-e03cc46cb475
2017-04-18 12:30:57 +00:00
cutealien d16f529f18 Fix compiling (part 1 - still has some library troubles)
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@5290 dfc29bdd-3216-0410-991c-e03cc46cb475
2016-03-18 17:36:56 +00:00
nadro 9773157768 - Fixed issue with CurrentRenderTargetSize vs. CurrentRendertargetSize in OpenGL ES drivers. Thanks cheqnk for report.
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@5257 dfc29bdd-3216-0410-991c-e03cc46cb475
2016-02-13 11:13:44 +00:00
nadro 216af56b04 - Merged rev 5247 from trunk.
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@5248 dfc29bdd-3216-0410-991c-e03cc46cb475
2016-01-17 13:38:01 +00:00
nadro 27bf238aa5 - Fixed texture rendering in both OpenGL ES1 and ES2 drivers on iOS.
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@5234 dfc29bdd-3216-0410-991c-e03cc46cb475
2016-01-03 18:39:39 +00:00
nadro bf3273cb5f - Merged rev 5222-5223 from trunk.
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@5224 dfc29bdd-3216-0410-991c-e03cc46cb475
2015-12-17 19:48:24 +00:00
nadro 0200408475 - Fixed issue with depth color formats in OpenGL drivers (example no. 13 works properly at now).
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@5221 dfc29bdd-3216-0410-991c-e03cc46cb475
2015-12-17 12:44:24 +00:00
nadro e6fe1abc16 - Fixed texture rendering issues in OpenGL ES drivers.
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@5217 dfc29bdd-3216-0410-991c-e03cc46cb475
2015-12-14 22:51:01 +00:00
nadro 3fbea082cc - Fixed compilation issues on iOS.
- Rewrote from scratch class related to iOS device (Application delegate is hidden inside Irrlicht -> events will be exposed outside in upcoming commit).
- Added iOS example (at now example structure for iOS looks the same like for the other platforms - without application delegate).
- Integrated iOS projects with existing XCode projects.
- Added external context manager with support for EAGL.
- Removed *.xib dependencies from iOS project.
- Added missing _IRR_OVERRIDE_ for some methods.

git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@5213 dfc29bdd-3216-0410-991c-e03cc46cb475
2015-12-13 19:13:45 +00:00
nadro a660cd1d38 - Fixed compilation issues on Android.
- Fixed compilation issues when OpenGL ES1 driver is enabled. (there are still rendering issues related to multitexturing visible in a few examples).

Following features are still unavailable in ogl-es branch since rev 5181:
* Support for iOS
(If you need one of those features please use rev 5180)

git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@5204 dfc29bdd-3216-0410-991c-e03cc46cb475
2015-12-06 19:56:33 +00:00
nadro 58cba0b3c6 - Merged revision 5195-5197 from trunk.
Following features are still unavailable in ogl-es branch since rev 5181:
* OpenGL ES1
* Support for iOS
* Support for OSX
(If you need one of those features please use rev 5180)

git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@5198 dfc29bdd-3216-0410-991c-e03cc46cb475
2015-11-28 23:18:00 +00:00
nadro 0cc2e6dc45 - Merged revision 5185-5190 from trunk.
- Fixed cubemap texture support for OpenGL drivers.

Following features are still unavailable in ogl-es branch since rev 5181:
* OpenGL ES1
* Support for iOS
* Support for OSX
(If you need one of those features please use rev 5180)

git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@5191 dfc29bdd-3216-0410-991c-e03cc46cb475
2015-11-27 22:39:12 +00:00
nadro ce6b7562ce Merge revision 4977:5180 from trunk to ogl-es.
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@5181 dfc29bdd-3216-0410-991c-e03cc46cb475
2015-11-12 22:32:01 +00:00
cutealien 3dbf7c9de6 Return reference to a local static instead of a reference to 0 in an error cases (was undefined c++).
Thx @floriang for reporting at http://irrlicht.sourceforge.net/forum/viewtopic.php?f=7&t=50877



git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@5113 dfc29bdd-3216-0410-991c-e03cc46cb475
2015-07-30 21:53:21 +00:00
cutealien 831962cedb Give EMT_TRANSPARENT_ALPHA_CHANNEL it's own fragment shader. Fixes problem in q3 map reported by feelthat in the forum.
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@5033 dfc29bdd-3216-0410-991c-e03cc46cb475
2015-02-03 16:19:30 +00:00
nadro 971059c81c - Improved texture handling in OpenGL ES2.
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@4993 dfc29bdd-3216-0410-991c-e03cc46cb475
2014-12-09 18:41:49 +00:00
nadro bba02a5d20 - Fixed COGLES2Texture::lock method.
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@4992 dfc29bdd-3216-0410-991c-e03cc46cb475
2014-12-08 17:34:34 +00:00
nadro afec6508a8 - Solved issue with high memory usage by ITexture objects in OpenGL ES2 driver.
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@4990 dfc29bdd-3216-0410-991c-e03cc46cb475
2014-12-04 18:26:18 +00:00
cutealien 7ac215ee11 Just some cleanup (spelling, double breaks, Irrlicht variable style, static-cast instead of c-casts, fix intialize re-order warnings)
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@4976 dfc29bdd-3216-0410-991c-e03cc46cb475
2014-10-16 14:35:26 +00:00
cutealien bdbb6dffb6 Add profiling info for the es2 driver.
Adding profile info in functions used that starts being noticable in executation speed, so I've disabled profiling now by default (forgive me if enabling again continues to slip in once in a while - I profile a lot currently in this branch).


git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@4975 dfc29bdd-3216-0410-991c-e03cc46cb475
2014-10-15 22:50:34 +00:00
nadro d50be349ca Fixed issue with ECFN_DISABLED state in OGL ES and ES2 drivers.
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@4965 dfc29bdd-3216-0410-991c-e03cc46cb475
2014-10-11 09:37:30 +00:00
nadro f9806e994c - Fixed issue with texture matrices and built-in OpenGL ES2 materials.
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@4958 dfc29bdd-3216-0410-991c-e03cc46cb475
2014-10-02 18:22:36 +00:00
cutealien 0e9e909bed Add IVideoDriver::getAmbientLight function so shader callbacks can access global ambient light easier.
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@4941 dfc29bdd-3216-0410-991c-e03cc46cb475
2014-09-24 23:51:06 +00:00
nadro 53371c5611 - Optimized 2D drawing in OpenGL ES2 driver.
- Fixed issue with points drawing in OpenGL ES2 driver.

git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@4907 dfc29bdd-3216-0410-991c-e03cc46cb475
2014-07-28 17:49:05 +00:00
nadro 86cc2a9556 - Added stencil shadow support for OpenGL ES1 driver.
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@4906 dfc29bdd-3216-0410-991c-e03cc46cb475
2014-07-23 19:08:16 +00:00
nadro 5d7a5e76c1 - Improved 2D material renderer in OpenGL ES2 driver.
- Added stencil shadow support for OpenGL ES2 driver.

git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@4905 dfc29bdd-3216-0410-991c-e03cc46cb475
2014-07-22 21:45:38 +00:00
nadro 12a9df7e82 - Improved EMT_ONETEXTURE_BLEND material for OpenGL ES2.0 driver (it solve issue with black volume light in example no. 08).
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@4903 dfc29bdd-3216-0410-991c-e03cc46cb475
2014-07-15 18:30:46 +00:00