[Bf-blender-cvs] [fe6ae405c59] temp-bundled-assets: remove hardcoded path
Jacques Lucke
noreply at git.blender.org
Tue Jan 24 19:29:56 CET 2023
Commit: fe6ae405c5917da828c814d907ce4c304ef5bf49
Author: Jacques Lucke
Date: Wed Jan 18 16:22:07 2023 +0100
Branches: temp-bundled-assets
https://developer.blender.org/rBfe6ae405c5917da828c814d907ce4c304ef5bf49
remove hardcoded path
===================================================================
M source/blender/asset_system/intern/asset_bundled.cc
===================================================================
diff --git a/source/blender/asset_system/intern/asset_bundled.cc b/source/blender/asset_system/intern/asset_bundled.cc
index 76481ac33da..7e1d4dda009 100644
--- a/source/blender/asset_system/intern/asset_bundled.cc
+++ b/source/blender/asset_system/intern/asset_bundled.cc
@@ -4,13 +4,19 @@
* \ingroup asset_system
*/
+#include "BKE_appdir.h"
+
#include "AS_asset_bundled.hh"
namespace blender::asset_system {
StringRefNull bundled_assets_directory_path()
{
- return "/home/jacques/blender/build_release/bin/3.5/datafiles/assets/base_meshes";
+ static std::string path = []() {
+ const char *datafiles_path = BKE_appdir_folder_id(BLENDER_DATAFILES, "assets");
+ return datafiles_path;
+ }();
+ return path;
}
} // namespace blender::asset_system
More information about the Bf-blender-cvs
mailing list