August 2, 2018, 12:34 (GMT) |
Feature: Collada: Added new classes for The Animation exporter Actually the new classes are not depending on Collada itself. They coul dbe reused for other purposes as well, for example as a general helper tool for Animation export. |
August 2, 2018, 12:34 (GMT) |
Refactor Collada: Moved Classes into separate files Renamed AnimationCurveCache to BCAnimationCurveContainer because this is really not a cache but just a set of Data that prepares the export of FCurves. This container only lives during export and is otherwiose not used for anything else. The BCAnimationCurveContainer is not depending on Collada in any way. Theoretically it could be used also from Python, but this is another story. Additions in more detail: Classes: * BCAnimationCurve a wrapper for handling FCurves tied to an object within the Animation Exporter * BCAnimationCurveContainer A container to keep all FCurves in one place. It also maintains creation and deletion of temporary FCurves needed to export data without interfering with the User's production data in Blender. * BCMatrix Handy class for making float mat[4][4] a primetime resident in the code. Not necessary but nice. Support functions: * bc_get_children(std::vector<Object *> &child_set, Object *ob, Scene *scene) returns the immediate children of an object into a set * bc_string_after(const std::string& s, const char c) returns the string after the last occurance of char * bc_startswith(std::string const & value, std::string const & starting) returns true if the string starts with the starting sequence * bc_endswith(std::string const & value, std::string const & ending) returns true if the string ends with the ending sequence |
August 2, 2018, 12:31 (GMT) |
fix: Collada: changed scene update for sampling animation data According to a comment in physics_fluid.c it sounds like the function BKE_scene_update_for_newframe() does not work in all cases. According to the comment it seems better to use ED_update_for_newframe() instead. This change only affects the export of Animation Data. I make this change as a precaution. I am not aware that there was anything wrong here before. |
August 2, 2018, 12:28 (GMT) |
Cleanup: use dictionary for icon lookup |
August 2, 2018, 12:25 (GMT) |
Feature Collada: Added AnimationCurveCache for exporting sampled animations Details: When exporting sampled Animations to Collada we need to create sample data for every Animation curve. However it turns out to be extremely slow when we repeatedly step over the entire animation for each curve. The solution is to only step over the animation once but cache all needed animation data in a cache. Once the animation has been processed, all export information is located in the cache and can be easily read from there. The AnimationCurveCache is the first try to proof the concept. This is work in progres and may still change a lot. |
August 2, 2018, 12:25 (GMT) |
Feature Collada: Added new class files to CMakeLists.txt AnimationClipExporter.cpp and AnimationClipExporter.h both need to be added to CMakeLists.txt so they are actually built into Blender |
August 2, 2018, 12:25 (GMT) |
Feature Collada: Added new Enum and Mappings * BC_animation_transform_type Enum that Contains all animation types which can be exported * BC_ANIMATION_NAME_FROM_TYPE Map from transform_type to the name that is used in the exported data * BC_ANIMATION_TYPE_FROM_NAME Maps to get the animation transformtype from RNA Pathes and from collada names (also needed for the Importer later) These maps and Enums will later replace hard coded integer numbers which are currently used all over the place and make it really hard to understand what exactly is going on. |
August 2, 2018, 12:25 (GMT) |
Cleanup Collada: Added #ifdef to avoid duplicate include This avoids that the include file AnimationExporter.h gets included more than once. |
August 2, 2018, 12:25 (GMT) |
Feature Collada: Added new class for exporting Animation Clips. This class is work in progres and not yet used. It is also not yet largely tested and needs some improvements regarding which actions will be exported for which objects. |
August 2, 2018, 12:25 (GMT) |
Cleanup Collada: renamed parameters for better reading I tested and commited each of the documented changes separately and amended all changes into one single commit: None of the changes makes a functional change. All changes are in AnimationExporter.h and AnimationExporter.cpp * Renamed from transformName to channel_type * in create_sampled_animation(): renamed label to channel_type * in export_sampled_transrotloc_animation() in export_sampled_matrix_animation() in export_sampled_animation_set() in create_sampled_animation(): Renamed variable from times to frames * Fixed Indentation in AnimationExporter.h * break up function definition into multiple lines. |
August 2, 2018, 12:22 (GMT) |
Feature Collada: Support for Animation Clip export 1.) 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> 2.) Added support functions for this extra level: open_animation_container(bool has_container, Object *ob); close_animation_container(bool has_container); 3.) Added Function for organizing unassigned exported animations openAnimationWithClip() (not uesed yet) 4.) Added support function to check if a sampled matrix animation is actually animating bool is_flat_line() (not used yet) |
August 2, 2018, 12:20 (GMT) |
Cleanup: Fixed indentation and added white space lines Very minor change just for better reading |
August 2, 2018, 12:16 (GMT) |
Feature Collada: Prepare for exporting all actions of a scene bc_getSceneActions(Object *ob, bool all_actions) This function is supposed to return the list of actions to be exported for the given object. However the function is not yet used. Also it needs an improvement such that only actions which match the active object will be exported. This is still work in progress. |
August 2, 2018, 12:13 (GMT) |
Cleanup Collada: changed import stage names for better reading. The Collada Importer processes the imported files twice. It is still not clear to me why it needs to do that. However i renamed the Import stages for now to clarify a bit what really happens: General -> Fetching_Scene_data Controller -> Fetching_Controller_data This change makes it more clear that when the controller data is fetched these methods are not needed. Before it was much harder to understand what this is all about. |
August 2, 2018, 12:11 (GMT) |
Fix: Collada Exporter/Import break Object hierarchy Exporter: Children of Armatures where not exported as children but as sibblings. Importer: When an object is linked to an armature then the Importer unconditionally makes the child a direct child of Armature. Actually, if the child is already a child of the armature, then there is no need to reparent it. |
August 2, 2018, 12:11 (GMT) |
cleanup: Collada remove unused function This was a function introduced earlier, but it is no longer needed. |
August 2, 2018, 12:11 (GMT) |
Cleanup: Added comment to clarify The exporter does not export invisible and hidden objects! This may cause issues. I added the comment to make this clear in the code. This behavior may later be improved. |
August 2, 2018, 12:11 (GMT) |
Cleanup Collada: Added new low level functions for later usage bc_get_action_id() : To create unique Collada conform identifiers The following new functions handle conversions of matrices to various forms: bc_copy_darray_m4d() : Copy matrix to an array of floats bc_copy_v44_m4d() : Copy matrix to a vector of vectors of floats bc_copy_m4d_v44() : opposite of previous function Note: The vector<vector<double>> matrix is needed so that i later can easily store matrix data in another vector (containing matrix curves) |
August 2, 2018, 12:10 (GMT) |
UI: show all particle brush settings in topbar Also show particle brush in tool-properties panel. |
August 2, 2018, 12:09 (GMT) |
Collada: Added Option "All actions" for exporting animation libs This is work in progress. The follow up changes in the exporter will eventually make use of the new options. Currently the new option does nothing. |
|
|
|


Master Commits
MiikaHweb | 2003-2021