Commit Graph

57 Commits

Author SHA1 Message Date
kaosat.dev f4e3c948cb Merge branch 'main' into blenvy 2024-07-19 12:27:40 +02:00
Mark Moissette 9b50d77790
chore(v0.14): upgraded all current crates, examples, testing setup etc to Bevy 0.14 (#195)
* chore(v0.14): upgraded all current crates, examples, testing setup etc to Bevy 0.14
* chore(Blender tools): some minor fixed for Bevy 0.14 & version bump
2024-07-19 01:24:24 +02:00
kaosat.dev a618e0035e chore(crates): updated code from main to v0.14 compatibility for all old crates 2024-07-18 13:42:29 +02:00
kaosat.dev 70931ee163 chore(Blenvy:Bevy): more cleanups 2024-07-08 13:30:46 +02:00
kaosat.dev 459bb868e0 chore(Blenvy:Bevy): cargo fmt 2024-07-08 13:18:21 +02:00
kaosat.dev 959951bca4 feat(Blenvy:Bevy): experimentation with hot reload: it works !!
* but it is VERY VERY messy right now
 * BlenvyAssets => BlueprintAssets
 * lots of tweaks & experiments & related changes
2024-06-25 18:34:26 +02:00
kaosat.dev ed5dfeb3cd feat(Blenvy): removed local assets, as they are useless, renamed AllAssets to BlenvyAssets 2024-06-22 13:58:43 +02:00
kaosat.dev 00bf600ccf feat(Blenvy): updated (most) of the crates' code to bevy 0.14 (rc)
* tweaked & changed code where relevant
 * also added support for the new gltf_xxx_extras in bevy_gltf_components
 * animation support needs an overhaul given the extensive changes in v0.14 (wip)
 * still a giant mess, but works
 * examples not yet updated, will get overhauled
 * testing project is now independant from the "common" example code: ie no debug ui, no physics,
no bevy_asset_loader
 * testing project WORKS , even without any of the above, so asset loading (even if rough), is functional !
 * added VERY rough hierarchy/ components debug to testing project to visualize things
without bevy_editor_pls egui & co
 * related tweaks & changes
2024-06-18 22:30:59 +02:00
kaosat.dev 295c387132 refactor(Blenvy): BIG cleanup
* removed old blender add-ons, there is now only Blenvy !
 * updated most of the main docs accordingly
 * updated project name in main README
 * etc
 * related tweaks
2024-06-10 14:08:16 +02:00
kaosat.dev 2f7f3024d9 feat(bevy_gltf_blueprints): added back materials handling ,removing clutter
* removed format, materials library path, & library path from blueprints, obsoleted through "blueprints_path"
 * related cleanups
 * added back materials library support but using the assets path
2024-06-10 11:03:52 +02:00
kaosat.dev ed0c85b66e feat(Blenvy): more work done on materials handling overhaul (wip)
* split out materials scan from injection of materialInfo into objects
 * added material Asset injection into list of assets at scene level
 * related tweaks & cleanups
 * continued overhaul on the bevy side
2024-06-10 00:31:23 +02:00
kaosat.dev 1fdb45bab6 feat(Blenvy): basic working loading of levels & assets
* removed/ obsoleted blueprintsList
 * now using AllAssets (meh naming)
 * modified example & internals to enable loading levels as Blueprints as well
 * internals quite messy for now, needs a big cleanup still
 * disabled materials library for now, needs to be overhauled to make use of asset logic as well
 * added more mock assets for testing
 * related changes to blender & bevy side
2024-06-09 23:14:49 +02:00
kaosat.dev 2a74dedcb8 feat(Blenvy & crates):
* added injection of assets lists to blueprints at export time
 * assets & co related tweaks & experiments
 * tweaks on the bevy side
 * all wip !
2024-06-09 10:54:10 +02:00
kaosat.dev 37f4514b31 feat(bevy_gltf_blueprints): added new experimental asset structs
* also started moving code to a new "assets" mod in preparartion for bigger changes
2024-06-08 11:55:01 +02:00
kaosat.dev 49917e3b17 feat():
* cleaned up crate code
 * added duplicate named component to testing project to resolve issues with clashing short_names for bevy components
2024-04-30 11:58:03 +02:00
kaosat.dev 9138c81c60 refactor(): removed remains of legacy mode 2024-04-30 11:33:05 +02:00
kaosat.dev 742c5b19f0 chore(): some clippy changes 2024-04-15 22:54:25 +02:00
kaosat.dev 8683a6482f refactor(animation): renamed instancexxx to scenexxx (ie InstanceAnimations & InstancePlayerLinks) 2024-04-08 23:48:07 +02:00
kaosat.dev 1cf47d36b1 refactor(): cleanups 2024-04-05 10:52:14 +02:00
kaosat.dev 0998decb39 feat(animation): changes & some reverts of the latests experiments 2024-04-05 00:17:07 +02:00
kaosat.dev 66df7fae99 feat(animation):
* moved triggering of frame marker events to the blueprints crate
 * added additional handling of frame markers for blueprint animations (yikes is this convoluted)
 * added additional animated blueprint for testing blueprint animation markers
2024-04-01 00:26:23 +02:00
kaosat.dev 49dd0bc536 chore(): cargo fmt 2024-03-30 23:43:58 +01:00
kaosat.dev 2523691513 refactor(animation): cleanups , reorg & tweaks 2024-03-30 23:43:09 +01:00
kaosat.dev df3e335114 feat(animation):
* renamed Animated component to AnimationInfos, fleshed it out with additional
frame informations etc
 * restructured & cleaned up Bevy & Blender code in those areas a bit
 * various related minor tweaks
2024-03-30 18:29:43 +01:00
kaosat.dev c44d82e7dc feat(animation): added basic handling of animation markers
* added additional component on the Bevy side + experimented with handling the data in the testing setup
 * added parsing of animation markers on the Blender side + injection of custom property/ component
 * rough around the edges, but the basics work !
2024-03-30 02:40:52 +01:00
kaosat.dev ce473a357e feat(animation): split animation logic/components into Blueprint vs Instance animations
* renamed existing animation components with Blueprint prefix
 * added almost identical but seperate InstanceAnimations & InstanceAnimationPlayerLink
2024-03-22 13:59:01 +01:00
kaosat.dev 27201e5cd6 feat():
* sucessfull experiment with ways to animate world level objects, using
the same logic as the blueprint animations
 * made required changes
2024-03-22 11:11:45 +01:00
Mark Moissette bb4b07b7af
docs(bevy_gltf_blueprints): fixed missing link, minor cleanups (#172)
* the rest of fixes & cleanups was already done in a previous commit, closes #165
2024-03-21 23:07:57 +01:00
Mark Moissette f438116ece
chore(bevy_gltf_blueprints): version bump (#171) 2024-03-21 22:16:44 +01:00
Jan Hohenheim ada54450a5
fix(bevy_gltf_blueprints): fix occasional crash (#168)
* Fixes #156
* Fix post processing not affecting visibility of entities
2024-03-21 21:31:35 +01:00
kaosat.dev 4f50c4f6d2 feat():
* auto_export now injecting the list of available animations into the "Animated" component
  for any object with animations
 * modified bevy side struct to match
2024-03-21 15:25:50 +01:00
kaosat.dev c2f09fbf22 feat(): added 'animated' flag component (wip) to mark any worlds/blueprints entities that have animations
* allows to not be restricted by bevy's a bit weird logic for AnimationPlayers
 * updated crate & tooling
 * updated testing example with a bit more complex nesting cases for testing
2024-03-19 22:12:37 +01:00
Mark Moissette 9f21df035b
feat(): Asset preloading basics (#169)
* closes #80 
* preliminary work for further asset management from the Blender side without needing additional dependencies & boilerplate on the Bevy side 
* feat(auto_export): 
     * now injecting list/tree of sub blueprints to main scenes/levels & blueprints
     * made blueprints/asset list conditional on NOT legacy mode
* feat(gltf_blueprints): 
    * basics of dynamic loading of sub_blueprints
    * added same kind of logic to the loading of material files
    * also made a more generic variant of the BlueprintAssetLoadTracker 
    * added gltf file path for more informative error in case a gltf is missing
* refactor(): 
   * made the various gltf assets loaded by bevy_asset_loader optional (to handle the case where they are not present)
   * updated all examples accordingly
* chore(crates): fixed links, slight tweaks, bumped versions
2024-03-18 18:00:19 +01:00
Mark Moissette 09915f521d
chore(Bevy): Update to bevy 0.13 (#136)
* chore(crates): updated crates to Bevy 0.13
   * updated deps
   * updated / changed code where relevant
   * updated README files
   * bumped version numbers for upcoming release
   * updated rust-toolchain
   * updated assets where relevant
   * closes #132 
* feat(bevy_gltf_components): 
  * added GltfProcessed flag component to improve performance of iteration over added<gltfExtras>
  * closes #144 
  * light & shadow processing is now integrated,  to match  lights coming from Blender: you can now control whether 
  lights cast shadows, the cascade resolution , background color etc  from Blender
   * closes #155 

* feat(bevy_registry_export): added boilerplate to make registry path relative to assets folder 
  * closes #137 
* feat(tools): added boilerplate for internal tools
   * clean zip file generator for blender add-on releases
   * example gltf file generator
* feat(lighting): added components, exporter support & testing for blender-configurable shadows
   * added BlenderLightShadows component to bevy_gltf_components
   * added writing shadow information to gltf_auto_export
   * updated tests
   * closes #157 

Co-authored-by: Jan Hohenheim <jan@hohenheim.ch>
2024-03-04 22:16:31 +01:00
Mark Moissette 9cb9dda5d3
fix(bevy components): fix handling of unit/empty structs (#151)
* closes #133 
* fix(gltf_auto_export): corrected ron value for "spawnHere" components
* fix(bevy_components): fixed handling of empty/ unit structs
   * updated to/from prop_groups
   * updated tests/ expected files
   * bumped version
   * removed verbose "watching schema file for changes"
* fix(bevy_gltf_components): fixed issue of incorect handling of empty component values in non legacy mode:
   * aka: replacing empty component values (ron strings) with '()' should ONLY happen in legacy mode
   * even more aka: ron strings for component values should not be altered when not in legacy mode (provided ron
  strings should be valid)
* tests():
   * changed bevy_component tests to use testing/bevy_example as source for registry data
   * removed testing/bevy_registry_export, as it is redudant
   * related tweaks & cleanups
* chore(crates): bumped up versions because of breaking change
* chore(examples): updated registry export example to use up-to-date / fixed components data
* chore(bevy_gltf_components): added back warning about legacy mode, in a less spammy way
* docs(bevy_components): added notes about v0.3 breaking changes
2024-03-04 08:20:00 +01:00
Mark Moissette 1ceb5050f2
feat(bevy_gltf_components): testing a different approach using only gltf extras (#134)
* not using / tracking gltf files anymore (should avoid issues with scenes vs gltf files)
 * restructured accordingly
 * closes #102
 * closes #111
2024-02-19 22:43:27 +01:00
Mark Moissette 0d708b800e
chore(): cleanup & simplification pass (#122)
* closes #118 
* closes #110 
* closes #99
2024-02-07 14:07:17 +01:00
Mark Moissette cfbda24da7
feat(tools/bevy_blueprints): bevy plugin + blender addon for components UI to more easily create components (#70)
* adds a new crate: ```bevy_registry_export``` to be able to create a json import of the registered component/type definitions
* adds a new Blender addon: ```bevy_components``` that takes that json data to generate custom UIs for components , to be to add & edit components easily in Blender 
   * also adds component metadata per object for more advanced features
   * etc
* updates to bevy_gltf_components & bevy_gltf_blueprints to add legacy_mode to support the "old"/current style component definitions
* same with gltf_auto_export Blender add_on
* closes #60
2024-02-05 23:01:19 +01:00
GitGhillie 572a2b89a6
chore(CI): Add lint CI (#100)
* Add lint CI
* Clippy allow complex types, warn on some others
* bevy_gltf_blueprints use workspace lints
* Update toolchain for workspace wide lints
* Use workspace lints on the other crates as well
2024-01-19 22:23:47 +01:00
Mark Moissette 5429bf4779
feat(Save & load): new crate bevy_gltf_save_load + lots of upgrades & improvements (#95)
* feat(bevy_gltf_save_load): saving & loading implemented
   * created new crate for save & load features, uses & filters out blueprints for efficient loading
   * saving & loading, even with dynamically spawned nested hierarchies works 
   * component filter , resource filter & save path root are configurable
   * for saving: added removal & cleanup logic for children component with children
  that have been filtered out: ie no more invalid children getting stored in the save files !
   * added sending of event once saving is done

* feat(examples/save-load): example for the new crate
   * loading level static & dynamic data as blueprints
   * added a bit of ui when entering saving & loading states & cleanup when exiting

* feat(bevy_gltf_blueprints): significant rewrite of how the crate works
     * simplified spawning process, no more spawning children containing blueprints etc
     * simplified post process : instead of copying original entity  into blueprint root
      we now copy blueprint root data (components & children) into the original entity ! fixes #96 
     * much simpler code wise
     * solves issue with needing to register components that we only use on the bevy side (not gltf)
    since we are not copying the bevy data into the blueprints data
     * added **copyComponents** helper to copy components from one entity to another, excluding existing
     components on the target entity, & some bells & whistles
     * **Name** is now optional when spawning a blueprint: closes #97 
     * **Transform** is now optional when spawning a blueprint: closes #98 
     * removed transform from bundle (BREAKING change)
     * added (optional)  **NoInBlueprint** component to have finer control over whether to inject the **InBlueprint** component inside spawned blueprint entities
     * added (optional) **Library**  component, so we can override library path when we want
     * added (optional) **AddToGameWorld** component for convenience   to automatically add entities to the game world, if there is one

* chore(bevy_gltf_components): removed verbose output, cleaned it up a bit

* feat(tools/auto_export): added option to split out "dynamic" objects in main scenes
   * ie if a collection instance (or its original collection) has a "dynamic" (aka mutable, saveable etc)
     flag it can get exported to a seperate gltf file (essentially acting like an "initial save")
   * the rest of the levels (the "static" data) is exported without the dynamic objects and
     can be reused with save files !
2024-01-10 14:49:29 +01:00
Mark Moissette af94e49976
feat(Gltf auto export): multiple blend files workflow, combine modes, bugfixes and more ! (#83)
* feat(multiple blend files): added example of multi blend file workflow
* feat(tools/auto_export): 
 * added collection_instances_combine_mode superseeds  & replaces "export nested blueprints", with a lot more flexibilty
 * added preferences & ui settings
 * added (optional) use of marked assets as replacement for "autoExport" collection flag
 * added correct cleaning up of temporary sub_collections
* feat(tools/auto_export): change detection added for material changes
* feat(tools/auto_export): blueprints now also use the "combine" settings for nested collections
*  feat(tools/auto_export): added correct cleanup of data when removing hollow scenes, so that there is no orphan data left behind
* feat(tools/auto_export): changes to nested collections are now triggering change detection of root
 (exportable collections)
* feat(tools/auto_export):  now actually useful tracebacks using traceback.format_exc()
* various minor fixes, cleanups & UI description improvements
* docs(README): updated & fleshed out docs

* closes #87 
* closes #86
* closes #85 
* closes #79 
* closes #61 
* closes #68 
* closes #41
2024-01-01 22:35:21 +01:00
Mark Moissette 20b34dde20
feat(bevy_gltf_blueprints): improved error handling for clone_entity (#82)
* feat(bevy_gltf_blueprints): improved error handling for clone_entity
 * you will now get component name for components that have not been registered & thus cannot be cloned
* added a small example (in examples/bevy_gltf_blueprints/basic), just press 'U' at runtime to try to spawn an entity with unregistered components
* closes #81
2023-12-27 13:14:13 +01:00
Mark Moissette 6047959b3f
feat(nested_blueprints): added support for nested blueprints both in bevy_gltf_blueprints & in gltf_auto_export (#65)
* feat(bevy_gltf_blueprints): 
  * added support for nested blueprints
  * added example/test for nested blueprints with multiple levels of nesting
* feat(tools/gltf_auto_export): 
  * implemented functionality to export nested blueprints/collection instances
  * added add prefs to control nested blueprints export
  * experiments with nested blueprints merge modes
  * when exporting of nested blueprints is disabled, will not scan for nested blueprints
and thus no export them
* docs(): updated docs & added images for nested blueprints support
2023-12-22 00:37:52 +01:00
Mark Moissette 0aead0853c
feat(scene components) : added scene components to control ambient, bloom etc from Blender(#76)
* feat(tools):  scene component injection & export
 - ambient light, shadowmap resolution, bloom intensity, ambient occlusion are now directly settable from scene components that are injected automatically in the scene 
 - relaxed requirements for changes(aka when to export gltf) for main scenes,
so that render , background etc changes also trigger a save
 - added scene components examples
 - added additional proxies &  handling for camera & lights
 - in relevant cases, made sure that entity specific components are not overridden by scene components
 - added option to toggle scene level exports of params/ components
 - ambient colour/ intensity is now also set as background/clear colour
  - updated docs
2023-12-17 15:31:25 +01:00
Mark Moissette e1aa510457
feat(materials): Materials libraries tooling & bevy code for material/texture reuse (#71)
* updates both gltf_auto_export & bevy_gltf_blueprints to avoid duplicating common materials across blueprints
* feat(tools/gltf_auto_export): added materials library export !
 * export all materials in use by blueprints to a separate temporary scene with cubes (for now)
   with the materials assigned
 * injecting MaterialInfo components to each blueprint above with Material name + library name
 * generated gltf is named based on the project/blend file, so multiple blend file projects
   can each have their own material libraries
 * added preferences & ui & handling to be able to toggle material library exports
* feat(bevy_gltf_blueprints): added support for materials library!
 * material injection (toggleable via the plugin configuration)
 * added example
 * added materials library + texture files + updated assets
 * added physics debug toggling
* updated documentation
* closes #63
2023-12-12 13:21:53 +01:00
Mark Moissette 21ad422f46
fix(bevy_gltf_blueprints): fixed aabb caching issue (#59)
closes #58
2023-11-25 02:52:23 +01:00
Mark Moissette 9a765d5e12
feat(bevy_gltf_blueprints): added ability to generate blueprint/scene aabbs automatically (#57)
* settable via a config flag & systems won't run if the flag is not set
 * caches aabbs per blueprint name so they do not need to be recomputed multiple time for the same blueprint
 * closes #56
2023-11-25 02:35:48 +01:00
Mark Moissette 8e67f76d28
feat(bevy_gltf_blueprints): added ability to also load gltf files, not just glb (#55)
* settable via a new field in the plugin configuration
 * updated examples & README
* closes #55
2023-11-24 12:30:47 +01:00
Mark Moissette c4e83655f3
chore(bevy_gltf_components): Update to Bevy 0.12 (#32)
* chore(bevy_gltf_components): updated code for bevy_main/ v0.12
* refactor(examples): cleanups & tweaks
* added compatibility tables
2023-11-11 22:58:00 +01:00
Mark Moissette 4afa0f5d7d
feat(Animation): added code & example for animation support (#33)
* feat(animation): added example & boilerplate
  * moved animations specific code to a different module
  * added multiple robots & foxes
  * added example of controlling animation based on distance from the player
  * removed obsolete files
  * added information about animation to READMEs
  * updated dependencies

closes #26
2023-11-01 12:44:37 +01:00