diff options
author | lupoDharkael <izhe@hotmail.es> | 2020-04-02 01:20:12 +0200 |
---|---|---|
committer | lupoDharkael <izhe@hotmail.es> | 2020-04-02 13:38:00 +0200 |
commit | 95a1400a2ac9de1a29fa305f45b928ce8e3044bd (patch) | |
tree | be0cd59e5a90926e9d653fed9f3b1b77e735ca2f /modules/assimp/import_utils.h | |
parent | 5f11e1557156617366d2c316a97716172103980d (diff) |
Replace NULL with nullptr
Diffstat (limited to 'modules/assimp/import_utils.h')
-rw-r--r-- | modules/assimp/import_utils.h | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/modules/assimp/import_utils.h b/modules/assimp/import_utils.h index 30c00f8765..f78931add3 100644 --- a/modules/assimp/import_utils.h +++ b/modules/assimp/import_utils.h @@ -233,7 +233,7 @@ public: static Transform _get_global_assimp_node_transform(const aiNode *p_current_node) { aiNode const *current_node = p_current_node; Transform xform; - while (current_node != NULL) { + while (current_node != nullptr) { xform = assimp_matrix_transform(current_node->mTransformation) * xform; current_node = current_node->mParent; } @@ -319,7 +319,7 @@ public: */ static void set_texture_mapping_mode(aiTextureMapMode *map_mode, Ref<ImageTexture> texture) { ERR_FAIL_COND(texture.is_null()); - ERR_FAIL_COND(map_mode == NULL); + ERR_FAIL_COND(map_mode == nullptr); // FIXME: Commented out during Vulkan port. /* aiTextureMapMode tex_mode = map_mode[0]; @@ -358,13 +358,13 @@ public: print_verbose("Open Asset Import: Loading embedded texture " + filename); if (tex->mHeight == 0) { if (tex->CheckFormat("png")) { - ERR_FAIL_COND_V(Image::_png_mem_loader_func == NULL, Ref<Image>()); + ERR_FAIL_COND_V(Image::_png_mem_loader_func == nullptr, Ref<Image>()); Ref<Image> img = Image::_png_mem_loader_func((uint8_t *)tex->pcData, tex->mWidth); ERR_FAIL_COND_V(img.is_null(), Ref<Image>()); state.path_to_image_cache.insert(p_path, img); return img; } else if (tex->CheckFormat("jpg")) { - ERR_FAIL_COND_V(Image::_jpg_mem_loader_func == NULL, Ref<Image>()); + ERR_FAIL_COND_V(Image::_jpg_mem_loader_func == nullptr, Ref<Image>()); Ref<Image> img = Image::_jpg_mem_loader_func((uint8_t *)tex->pcData, tex->mWidth); ERR_FAIL_COND_V(img.is_null(), Ref<Image>()); state.path_to_image_cache.insert(p_path, img); @@ -440,7 +440,7 @@ public: String &path, AssimpImageData &image_state) { aiString ai_filename = aiString(); - if (AI_SUCCESS == ai_material->GetTexture(texture_type, 0, &ai_filename, NULL, NULL, NULL, NULL, image_state.map_mode)) { + if (AI_SUCCESS == ai_material->GetTexture(texture_type, 0, &ai_filename, nullptr, nullptr, nullptr, nullptr, image_state.map_mode)) { return CreateAssimpTexture(state, ai_filename, filename, path, image_state); } |