aboutsummaryrefslogtreecommitdiff
path: root/src/script/lua_api
Commit message (Expand)AuthorAge
...
* Add core.remove_detached_inventory (#7684)SmallJoker2018-10-10
* markAliasDeprecated: Fix MSVC buildSmallJoker2018-09-11
* Particles: Make collision with objects optional (#7682)Paramat2018-09-08
* Raycast: export exact pointing location (#6304)Dániel Juhász2018-08-16
* Replace auth.txt with SQLite auth database (#7279)Ben Deutsch2018-08-05
* LuaVoxelManip: Throw warning or error instead of silently doing nothing (#7567)HybridDog2018-08-02
* Add protocol_version and supported package types to ContentDB urlsrubenwardy2018-07-29
* Lua templating reading (part 4): s16, v2s16, v2f (#7512)Loïc Blot2018-07-08
* Log deprecated Lua function calls (#7491)SmallJoker2018-07-01
* Modernize lua read (part 2 & 3): C++ templating assurance (#7410)Loïc Blot2018-06-30
* Fix memory leaks in mod storage (#7500)red-0012018-06-30
* Fix world deletion (#7494)Vitaliy2018-06-30
* Fix a memleak before assertion in l_get_mod_storageLoic Blot2018-06-30
* Fix mod channels crash (#7481)red-0012018-06-27
* Rename CSM flavours to restrictionsSmallJoker2018-06-26
* Update to new ContentDB APIrubenwardy2018-06-18
* Fix narrow/utf8 difference in incoming/outcoming messagesnumber Zero2018-06-10
* Modernize lua read (part 1): C++ templating insurance (#7394)Loïc Blot2018-06-04
* Fix isNan on setYaw Lua call (#7380)Loïc Blot2018-05-31
* Fix missing ignore textures (#7326)you2018-05-20
* Add screenshots to online content browserrubenwardy2018-05-20
* Add updating to online content browserrubenwardy2018-05-16
* Allow damage for attached objects, add attach/detach callbacks (#6786)SmallJoker2018-04-30
* MetaDataRef: Add contains() and get() (#7214)rubenwardy2018-04-30
* Add online content repositoryrubenwardy2018-04-19
* Biome API / dungeons: Add biome-defined dungeon nodesParamat2018-04-07
* Add player:get_meta(), deprecate player attributes (#7202)rubenwardy2018-04-06
* Biome API / cavegen: Add definable cave liquid for a biome (#7192)Paramat2018-04-05
* Fix last clang-tidy reported problems for performance-type-promotion-in-math-fnLoic Blot2018-04-03
* Fix many issues reported by clang-tidy (#7189)Loïc Blot2018-04-02
* ObjectRef: Add add_velocity() (#3208)you2018-03-31
* Load dependencies and description from mod.confAndrew Ward2018-03-28
* Add reasons to on_dieplayer and on_hpchangeAndrew Ward2018-03-28
* Add formspec theming using prepended stringsAndrew Ward2018-03-28
* Mapgen: Remove unused mgv7 code and some unused biometypesParamat2018-03-26
* Cleanup sound manager class (#7158)Loïc Blot2018-03-24
* Biome API: Add 'get_biome_name(biome_id)' APIparamat2018-03-11
* Spawn level: Add 'get_spawn_level(x, z)' APIparamat2018-03-10
* Biomes: Add 'min_pos'/'max_pos' xyz biome limitsparamat2018-03-09
* Cleanup & bugfixLoic Blot2018-03-08
* Cleanup: drop Server::hudGetHotbarSelectedImage()Loic Blot2018-03-08
* Cleanup: drop Server::hudGetHotbarImage()Loic Blot2018-03-08
* Cleanup: drop Server::hudGetHotbarItemcount()Loic Blot2018-03-08
* Gennotify: Add 'minetest.get_decoration_id' APIparamat2018-03-03
* Place schematic (on vmanip): Enable use of 'place center' flagsparamat2018-02-27
* Find nodes in area (under air): Raise volume limit and document itparamat2018-02-21
* Check argument types inside MetaDataRef Lua API (#7045)sfan52018-02-18
* Node definition manager refactor (#7016)Dániel Juhász2018-02-10
* Add minetest.bulk_set_node call + optimize Environment::set_node call (#6958)Loïc Blot2018-01-30
* CSM: Remove screenshot APIred-0012018-01-23
(newTexture) { - glCompressedTexSubImage2D(GL_TEXTURE_2D, level, 0, 0, image->getDimension().Width, - image->getDimension().Height, PixelFormat, compressedImageSize, source); + if (IsCompressed) + { + glCompressedTexImage2D(GL_TEXTURE_2D, 0, InternalFormat, image->getDimension().Width, + image->getDimension().Height, 0, compressedImageSize, source); + } + else + glTexImage2D(GL_TEXTURE_2D, level, InternalFormat, image->getDimension().Width, + image->getDimension().Height, 0, PixelFormat, PixelType, source); } else - glTexSubImage2D(GL_TEXTURE_2D, level, 0, 0, image->getDimension().Width, - image->getDimension().Height, PixelFormat, PixelType, source); - } - - if (convert) - { - tmpImage->unlock(); - tmpImage->drop(); - } - else - image->unlock(); - - if (!level && newTexture) - { - if (IsCompressed && !mipmapData) { - if (image->hasMipMaps()) - mipmapData = static_cast<u8*>(image->lock())+compressedImageSize; + if (IsCompressed) + { + glCompressedTexSubImage2D(GL_TEXTURE_2D, level, 0, 0, image->getDimension().Width, + image->getDimension().Height, PixelFormat, compressedImageSize, source); + } else - HasMipMaps = false; + glTexSubImage2D(GL_TEXTURE_2D, level, 0, 0, image->getDimension().Width, + image->getDimension().Height, PixelFormat, PixelType, source); } - regenerateMipMapLevels(mipmapData); - - if (HasMipMaps) // might have changed in regenerateMipMapLevels + if (convert) { - // enable bilinear mipmap filter - GLint filteringMipMaps = GL_LINEAR_MIPMAP_NEAREST; - - if (filtering != GL_LINEAR) - filteringMipMaps = GL_NEAREST_MIPMAP_NEAREST; + tmpImage->unlock(); + tmpImage->drop(); + } + else + image->unlock(); + + if (glGetError() != GL_NO_ERROR) { + static bool warned = false; + if ((!retry) && (ColorFormat == ECF_A8R8G8B8)) { + + if (!warned) { + os::Printer::log("Your driver claims to support GL_BGRA but fails on trying to upload a texture, converting to GL_RGBA and trying again", ELL_ERROR); + warned = true; + } + } + else if (retry) { + os::Printer::log("Neither uploading texture as GL_BGRA nor, converted one using GL_RGBA succeeded", ELL_ERROR); + } + retry = !retry; + continue; + } else { + retry = false; + } - glTexParameteri( GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, filteringMipMaps); - glTexParameteri( GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, filtering); + if (!level && newTexture) + { + if (IsCompressed && !mipmapData) + { + if (image->hasMipMaps()) + mipmapData = static_cast<u8*>(image->lock())+compressedImageSize; + else + HasMipMaps = false; + } + + regenerateMipMapLevels(mipmapData); + + if (HasMipMaps) // might have changed in regenerateMipMapLevels + { + // enable bilinear mipmap filter + GLint filteringMipMaps = GL_LINEAR_MIPMAP_NEAREST; + + if (filtering != GL_LINEAR) + filteringMipMaps = GL_NEAREST_MIPMAP_NEAREST; + + glTexParameteri( GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, filteringMipMaps); + glTexParameteri( GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, filtering); + } } - } - if (Driver->testGLError()) - os::Printer::log("Could not glTexImage2D", ELL_ERROR); + if (Driver->testGLError()) + os::Printer::log("Could not glTexImage2D", ELL_ERROR); + } + while(retry); } --- irrlicht/source/Irrlicht/COGLESTexture.cpp.orig 2014-06-25 00:28:50.820501856 +0200 +++ irrlicht/source/Irrlicht/COGLESTexture.cpp 2014-06-25 00:08:37.712544692 +0200 @@ -422,6 +422,9 @@ source = dest; } + //clear old error + glGetError(); + if (newTexture) { if (IsCompressed)