Blender Git Commit Log
Git Commits -> Revision 322cf89
Revision 322cf89 by Gaia Clary (master) November 23, 2018, 16:08 (GMT) |
Partial rewrite of the Collada Module for Blender 2.8 Most important changes are in the Animation exporter and Animation Importer. There is still some cleaning up to be done. But the Exporter/Importer basically work within Blender 2.8 Some details: User Interface: The interface has been reorganized to look more like the FBX interface. New options in user interface: * keep_keyframes: When sampling the distance between 2 keyframes is defined by the sampling rate. Furthermore the keyframes defined in the FCurves are not exported. However when this option is enabled then also the defined keyframes will be added to the exported fcurves * keep_smooth_curves: When sampling we do not use FCurves. So we also have no Curve handles for smooth exporting. However when this option is enabled, Blender does its best to recreate the handles for export. This is a very experimental feature and it is know to break when: - the exported animated objects have parent inverse matrices different from the unit matrix - The exported objects have negative scaling There may be many other situations when this feature breaks. This needs to be further tested. It may be removed later or replaced by something less wonky. BlenderContext: is a new class that contains the bridge to Blender. It contains pointers to the current export/import context plus derived values of Depsgraph, Scene, Main Reporting: I reorganized the output on the Blender Console to become more informative and more readable Preservation of Item names: name attributes are now encoded with XML entities. This makes sure that i can export/import names exactly defined in the tool. This affects material names, bone names and object names. Hierarchy export: * Object and Bone Hierarchies are now exported correctly by taking the Blender parent/child hierarchy into account * Export also not selected intermediate objects Problem: When we export an Object Hierarchy, then we must export all elements of the hierarchy to maintain the transforms. This is especially important when exporting animated objects, because the animation curves are exported as relative curves based on the parent-child hierarchy. If an intermediate animated object is missing then the exported animation breaks. Solution: If the "Selected" Optioon is enabled, then take care to also export all objects which are not selected and hidden, but which are parents of selected objects. Node Based Material Importer (wip): Added basic support for Materials with diffuse color and diffuse textures. More properties (opacity, emission) need changes in the used shader. Note: Materials are all constructed by using the principled BSDF shader. Animation Exporter: * Massive optimization of the Animation Bake tool (Animation Sampler). Instead of sampling each fcurve separately, i now sample all exported fcurves simultaneously. So i avoid many (many!) scene updates during animation export. * Add support for Continuous Acceleration (Fcurve handles) This allows us to create smoother FCurves during importing Collada Animation curves. Possibly this should become an option ionstead of a fixed import feature. * Add support for sampling curves (to bake animations) * The animation sampler now can be used for any animation curve. Before the sampler only looked at curves which are supported by Standard Collada 1.4. However the Collada exporter currently ignores all animation curves which are not covered by the 1.4.1 Collada Standards. There is still some room for improvements here (work in progres) Known issues: * Some exports do currently not work reliably, among those are the camera animations, material animations and light animations those animations will be added back next (work in progres) * Exporting animation curves with keyframes (and tangents) sometimes results in odd curves (when parent inverse matrix is involved) This needs to be checked in more depth (probably it can not be solved). * Export of "all animations in scene" is disabled because the Collada Importer can not handle this reliably at the moment (work in progres). * Support for Animation Clip export Added one extra level to the exported animations such that now all scene animations are enclosed: <Animation name="id_name(ob)_Action"> <Animation>...</Animation> ... </Animation> Animation Importer: * Import of animations for objects with multiple materials When importing multiple materials for one object, the imported material animation curves have all been assigned to the first material in the object. Error handling (wip): The Importer was a bit confused as it sometimes ignored fatal parsing errors and continued to import. I did my best to unconfuse it, but i believe that this needs to be tested more. Refactoring: update : move generation of effect id names into own function update : adjust importer/exporter for no longer supported HEMI lights cleanup: Removed no lopnger existing attribute from the exporter presets cleanup: Removed not needed Context attribute from DocumentExporter fix : Avoid duplicate deletion of temporary items cleanup: fixed indentation and white space issues update : Make BCAnimation class more self contained cleanup: Renamed classes, updated comments for better reading cleanup: Moved static class functions to collada_utils cleanup: Moved typedefs to more intuitive locations cleanup: indentation and class method declarations cleanup: Removed no longer needed methods update : Moved Classes into separate files cleanup: Added comments cleanup: take care of name conventions ... : many more small changes, not helpful to list them all |
Commit Details:
Full Hash: 322cf89a1444c685219ed6b863c9c74d41b5d1d1
Parent Commit: 3bf7c84
Lines Changed: +5146, -2417
14 Added Paths:
/source/blender/collada/AnimationClipExporter.cpp (+55, -0) (View)
/source/blender/collada/AnimationClipExporter.h (+50, -0) (View)
/source/blender/collada/AnimationCurveCache.cpp (+391, -0) (View)
/source/blender/collada/AnimationCurveCache.h (+130, -0) (View)
/source/blender/collada/BCAnimationCurve.cpp (+679, -0) (View)
/source/blender/collada/BCAnimationCurve.h (+156, -0) (View)
/source/blender/collada/BCAnimationSampler.cpp (+645, -0) (View)
/source/blender/collada/BCAnimationSampler.h (+205, -0) (View)
/source/blender/collada/BCSampleData.cpp (+188, -0) (View)
/source/blender/collada/BCSampleData.h (+102, -0) (View)
/source/blender/collada/BlenderContext.cpp (+61, -0) (View)
/source/blender/collada/BlenderContext.h (+56, -0) (View)
/source/blender/collada/Materials.cpp (+329, -0) (View)
/source/blender/collada/Materials.h (+83, -0) (View)
/source/blender/collada/AnimationClipExporter.h (+50, -0) (View)
/source/blender/collada/AnimationCurveCache.cpp (+391, -0) (View)
/source/blender/collada/AnimationCurveCache.h (+130, -0) (View)
/source/blender/collada/BCAnimationCurve.cpp (+679, -0) (View)
/source/blender/collada/BCAnimationCurve.h (+156, -0) (View)
/source/blender/collada/BCAnimationSampler.cpp (+645, -0) (View)
/source/blender/collada/BCAnimationSampler.h (+205, -0) (View)
/source/blender/collada/BCSampleData.cpp (+188, -0) (View)
/source/blender/collada/BCSampleData.h (+102, -0) (View)
/source/blender/collada/BlenderContext.cpp (+61, -0) (View)
/source/blender/collada/BlenderContext.h (+56, -0) (View)
/source/blender/collada/Materials.cpp (+329, -0) (View)
/source/blender/collada/Materials.h (+83, -0) (View)
37 Modified Paths:
/release/scripts/presets/operator/wm.collada_export/sl_plus_open_sim_rigged.py (+0, -1) (Diff)
/source/blender/collada/AnimationExporter.cpp (+438, -1590) (Diff)
/source/blender/collada/AnimationExporter.h (+129, -72) (Diff)
/source/blender/collada/AnimationImporter.cpp (+41, -29) (Diff)
/source/blender/collada/AnimationImporter.h (+13, -13) (Diff)
/source/blender/collada/ArmatureExporter.cpp (+29, -20) (Diff)
/source/blender/collada/ArmatureExporter.h (+12, -10) (Diff)
/source/blender/collada/CMakeLists.txt (+12, -0) (Diff)
/source/blender/collada/collada.cpp (+34, -6) (Diff)
/source/blender/collada/collada.h (+0, -2) (Diff)
/source/blender/collada/collada_internal.cpp (+36, -4) (Diff)
/source/blender/collada/collada_internal.h (+3, -3) (Diff)
/source/blender/collada/collada_utils.cpp (+489, -17) (Diff)
/source/blender/collada/collada_utils.h (+120, -9) (Diff)
/source/blender/collada/ControllerExporter.cpp (+16, -13) (Diff)
/source/blender/collada/ControllerExporter.h (+3, -5) (Diff)
/source/blender/collada/DocumentExporter.cpp (+23, -18) (Diff)
/source/blender/collada/DocumentExporter.h (+6, -6) (Diff)
/source/blender/collada/DocumentImporter.cpp (+41, -161) (Diff)
/source/blender/collada/DocumentImporter.h (+4, -3) (Diff)
/source/blender/collada/EffectExporter.cpp (+93, -64) (Diff)
/source/blender/collada/EffectExporter.h (+13, -4) (Diff)
/source/blender/collada/ErrorHandler.cpp (+32, -13) (Diff)
/source/blender/collada/ExportSettings.h (+17, -1) (Diff)
/source/blender/collada/GeometryExporter.cpp (+7, -7) (Diff)
/source/blender/collada/GeometryExporter.h (+4, -8) (Diff)
/source/blender/collada/ImageExporter.cpp (+72, -94) (Diff)
/source/blender/collada/ImageExporter.h (+6, -7) (Diff)
/source/blender/collada/LightExporter.cpp (+1, -9) (Diff)
/source/blender/collada/MaterialExporter.cpp (+5, -5) (Diff)
/source/blender/collada/MaterialExporter.h (+1, -0) (Diff)
/source/blender/collada/MeshImporter.cpp (+2, -3) (Diff)
/source/blender/collada/SceneExporter.cpp (+130, -134) (Diff)
/source/blender/collada/SceneExporter.h (+6, -4) (Diff)
/source/blender/collada/SkinInfo.cpp (+4, -1) (Diff)
/source/blender/collada/TransformReader.cpp (+3, -1) (Diff)
/source/blender/editors/io/io_collada.c (+171, -80) (Diff)
/source/blender/collada/AnimationExporter.cpp (+438, -1590) (Diff)
/source/blender/collada/AnimationExporter.h (+129, -72) (Diff)
/source/blender/collada/AnimationImporter.cpp (+41, -29) (Diff)
/source/blender/collada/AnimationImporter.h (+13, -13) (Diff)
/source/blender/collada/ArmatureExporter.cpp (+29, -20) (Diff)
/source/blender/collada/ArmatureExporter.h (+12, -10) (Diff)
/source/blender/collada/CMakeLists.txt (+12, -0) (Diff)
/source/blender/collada/collada.cpp (+34, -6) (Diff)
/source/blender/collada/collada.h (+0, -2) (Diff)
/source/blender/collada/collada_internal.cpp (+36, -4) (Diff)
/source/blender/collada/collada_internal.h (+3, -3) (Diff)
/source/blender/collada/collada_utils.cpp (+489, -17) (Diff)
/source/blender/collada/collada_utils.h (+120, -9) (Diff)
/source/blender/collada/ControllerExporter.cpp (+16, -13) (Diff)
/source/blender/collada/ControllerExporter.h (+3, -5) (Diff)
/source/blender/collada/DocumentExporter.cpp (+23, -18) (Diff)
/source/blender/collada/DocumentExporter.h (+6, -6) (Diff)
/source/blender/collada/DocumentImporter.cpp (+41, -161) (Diff)
/source/blender/collada/DocumentImporter.h (+4, -3) (Diff)
/source/blender/collada/EffectExporter.cpp (+93, -64) (Diff)
/source/blender/collada/EffectExporter.h (+13, -4) (Diff)
/source/blender/collada/ErrorHandler.cpp (+32, -13) (Diff)
/source/blender/collada/ExportSettings.h (+17, -1) (Diff)
/source/blender/collada/GeometryExporter.cpp (+7, -7) (Diff)
/source/blender/collada/GeometryExporter.h (+4, -8) (Diff)
/source/blender/collada/ImageExporter.cpp (+72, -94) (Diff)
/source/blender/collada/ImageExporter.h (+6, -7) (Diff)
/source/blender/collada/LightExporter.cpp (+1, -9) (Diff)
/source/blender/collada/MaterialExporter.cpp (+5, -5) (Diff)
/source/blender/collada/MaterialExporter.h (+1, -0) (Diff)
/source/blender/collada/MeshImporter.cpp (+2, -3) (Diff)
/source/blender/collada/SceneExporter.cpp (+130, -134) (Diff)
/source/blender/collada/SceneExporter.h (+6, -4) (Diff)
/source/blender/collada/SkinInfo.cpp (+4, -1) (Diff)
/source/blender/collada/TransformReader.cpp (+3, -1) (Diff)
/source/blender/editors/io/io_collada.c (+171, -80) (Diff)