Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2018-01-29Fix: Disable leftover debug prints from earlier work on the rna path ↵Joshua Leung
renaming/fixing code
2018-01-16Cleanup: Naming of depsgraphSergey Sharybin
2018-01-11Cleanup: BKE naming conventions for datablock add/localizeCampbell Barton
Conventions were already followed nearly everywhere.
2017-12-15Move ID recalc flags into dedicated field in IDSergey Sharybin
Currently this is a no-visible-changes change, but the idea is to use this dedicated flag to tell which exact components of ID changed, make it more granular than just OBJECT and OBJECT_DATA. Allow setting this field based on what components new dependency graph flushed on evaluation.
2017-12-05Version patching fixes for F-Curves (as required for fixes for T48988 and ↵Joshua Leung
T52009) * For the T48988 fix (i.e. separate Ease In/Out properties for Bendy Bones in Edit vs Pose modes), old animation data needed to be patched to use the new property names. This is needed to partially fix some of the issues in T53356 (though the Rigify code itself still needs to be patched). * For the T52009 fix, old files needed to have the frame_start and frame_end properties on the FModifier (base-class) updated to match that of the FMod_Stepped type-specific class. This wasn't done in the earlier commit since it wasn't worth going through all animation data just for the sake of updating these relatively-rare settings, but since we're doing it anyway now, it makes sense to include this here.
2017-12-05Added BKE_fcurves_main_cb(), a wrapper around BKE_animdata_main_cb to make ↵Joshua Leung
it easier to apply fixes to all F-Curves in a file
2017-12-05Cleanup/Style Tweaks to fit rest of codeJoshua Leung
2017-08-28Make GS macro return proper IDType typeSergey Sharybin
Previously it was returning short, which was really easy to (a) compare against non-ID type value (b) forget to handle some specific value in switch statement. Both issues happened in the nearest past, so it's time to tighten some nuts here. Most of the change related on silencing strict compiler warning now, but there is also one tricky aspect: ID_NLA is not in the IDType enum. So there is still cast to short to handle that switch. If someone has better ideas how to deal with this please go ahead :)
2017-08-07Refactor ID copying (and to some extent, ID freeing).Bastien Montagne
This will allow much finer controll over how we copy data-blocks, from full copy in Main database, to "lighter" ones (out of Main, inside an already allocated datablock, etc.). This commit also transfers a llot of what was previously handled by per-ID-type custom code to generic ID handling code in BKE_library. Hopefully will avoid in future inconsistencies and missing bits we had all over the codebase in the past. It also adds missing copying handling for a few types, most notably Scene (which where using a fully customized handling previously). Note that the type of allocation used during copying (regular in Main, allocated but outside of Main, or not allocated by ID handling code at all) is stored in ID's, which allows to handle them correctly when freeing. This needs to be taken care of with caution when doing 'weird' unusual things with ID copying and/or allocation! As a final note, while rather noisy, this commit will hopefully not break too much existing branches, old 'API' has been kept for the main part, as a wrapper around new code. Cleaning it up will happen later. Design task : T51804 Phab Diff: D2714
2017-07-07Fix T50973: Directional blur node doesn't clamp value if using driverSergey Sharybin
The issue was caused by combination of following factors: - Blender Internal viewport render can not distinguish between which parts of main database changed, so it does full database re-sync when anything is tagged for an update. This way, if any NodeTree (including compositor) is changed, Blender Internal viewport is tagged for full render database update. - With old dependency graph, scene-level drivers are evaluated on every iteration of scene_update_tagged, even if nothing is tagged for an update. This causes compositor drivers be evaluated quite often. - Driver evaluation checks whether value was changed, and if so it tags corresponding ID type as updated (this is what was telling viewport to do render database update). This check was quite stupid: current property value was checked against the one coming from driver expression. This means, if driver value is outside of the hard limit range of the property, the property will always be considered updated. The fix is to compare current property value against clamped value from the driver.
2017-06-09Cleanup: get rid of some now unused animdata ID management custom functions.Bastien Montagne
That's the kind of commit that are nice to do - getting rid of half-working custom pieces of code, now that we have generic tools to do same thing. ;)
2017-01-16Cleanup/refactor: Add new BLI_string_util.Bastien Montagne
Things like `BLI_uniquename` had nothing, but really nothing to do in BLI_path_util files! Also, got rid of length limitation in `BLI_uniquename_cb`, we can use alloca here to avoid overhead of malloc while keeping free size (within reasonable limits of course).
2016-11-30Cleanup id->newid usage, initial work.Bastien Montagne
This aims at always ensuring that ID.newid (and relevant LIB_TAG_NEW) stay in clean (i.e. cleared) state by default. To achieve this, instead of clearing after all id copy call (would be horribly noisy, and bad for performances), we try to completely remove the setting of id->newid by default when copying a new ID. This implies that areas actually needing that info (mainly, object editing area (make single user...) and make local area) have to ensure they set it themselves as needed. This is far from simple change, many complex code paths to consider, so will need some serious testing. :/
2016-11-08Depsgraph: Use atomics to tag ID when evaluating driverSergey Sharybin
This is required since new dependency graph evaluates drivers in threads so it was possible to have some partially written ID tag there.
2016-08-16More fixes from coverity report.Bastien Montagne
2016-08-06Basic Alembic supportKévin Dietrich
All in all, this patch adds an Alembic importer, an Alembic exporter, and a new CacheFile data block which, for now, wraps around an Alembic archive. This data block is made available through a new modifier ("Mesh Sequence Cache") as well as a new constraint ("Transform Cache") to somewhat properly support respectively geometric and transformation data streaming from alembic caches. A more in-depth documentation is to be found on the wiki, as well as a guide to compile alembic: https://wiki.blender.org/index.php/ User:Kevindietrich/AlembicBasicIo. Many thanks to everyone involved in this little project, and huge shout out to "cgstrive" for the thorough testings with Maya, 3ds Max, Houdini and Realflow as well as @fjuhec, @jensverwiebe and @jasperge for the custom builds and compile fixes. Reviewers: sergey, campbellbarton, mont29 Reviewed By: sergey, campbellbarton, mont29 Differential Revision: https://developer.blender.org/D2060
2016-07-30Cleanup: minor changes from last commitCampbell Barton
Un-indent blocks, rename vars.
2016-07-30Py-Driver: add 'self' optionCampbell Barton
Drivers can use this to refer to the data which the driver is applied to, useful for objects, bones, to avoid having to create a variable pointing to its self.
2016-07-14Add option to id_make_local to force localization of datablock, even if not ↵Bastien Montagne
used locally. Will be used by link/append code.
2016-07-10Refactor/enhance BKE_action_make_local().Bastien Montagne
Now using modern features from libquery/libremap areas. Provides same kind of fixes/improvements as for BKE_object_make_local() (see rBd1a4ae3f395a6).
2016-07-10Cleanup/Refactor: pass Main pointer to all ID copy functions.Bastien Montagne
Also allows us to get rid of a few _copy_ex() versions...
2016-07-07Cleanup/fix animsys 'id_type_can_have_animdata()'.Bastien Montagne
This func now actually takes an ID type as argument, added new 'id_can_have_animdata()' to check whether a datablock may be animated or not.
2016-06-22ID-Remap - Step one: core work (cleanup and rework of generic ID datablock ↵Bastien Montagne
handling). This commit changes a lot of how IDs are handled internally, especially the unlinking/freeing processes. So far, this was very fuzy, to summarize cleanly deleting or replacing a datablock was pretty much impossible, except for a few special cases. Also, unlinking was handled by each datatype, in a rather messy and prone-to-errors way (quite a few ID usages were missed or wrongly handled that way). One of the main goal of id-remap branch was to cleanup this, and fatorize ID links handling by using library_query utils to allow generic handling of those, which is now the case (now, generic ID links handling is only "knwon" from readfile.c and library_query.c). This commit also adds backends to allow live replacement and deletion of datablocks in Blender (so-called 'remapping' process, where we replace all usages of a given ID pointer by a new one, or NULL one in case of unlinking). This will allow nice new features, like ability to easily reload or relocate libraries, real immediate deletion of datablocks in blender, replacement of one datablock by another, etc. Some of those are for next commits. A word of warning: this commit is highly risky, because it affects potentially a lot in Blender core. Though it was tested rather deeply, being totally impossible to check all possible ID usage cases, it's likely there are some remaining issues and bugs in new code... Please report them! ;) Review task: D2027 (https://developer.blender.org/D2027). Reviewed by campbellbarton, thanks a bunch.
2016-06-04Cleanup: avoid temp string editCampbell Barton
2016-06-03Fix T48234: Glitch w/ action constraints sharing an actionCampbell Barton
FCurve evaluation depended on FCurve.curval, which isn't threadsafe. Now only use this value for debug display, and pass the value instead of storing in the FCurve for all but debug-display.
2015-12-27Split id->flag in two, persistent flags and runtime tags.Bastien Montagne
This is purely internal sanitizing/cleanup, no change in behavior is expected at all. This change was also needed because we were getting short on ID flags, and future enhancement of 'user_one' ID behavior requires two new ones. id->flag remains for persistent data (fakeuser only, so far!), this also allows us 100% backward & forward compatibility. New id->tag is used for most flags. Though written in .blend files, its content is cleared at read time. Note that .blend file version was bumped, so that we can clear runtimeflags from old .blends, important in case we add new persistent flags in future. Also, behavior of tags (either status ones, or whether they need to be cleared before/after use) has been added as comments to their declaration. Reviewers: sergey, campbellbarton Differential Revision: https://developer.blender.org/D1683
2015-11-09Cleanup: avoid incrementing/decrementing id->us outside of BKE_library.Bastien Montagne
We have callbacks for that, they also do some checks and help ensure things are done correctly. Only place where this is assumed not true is blenloader (since here we may affect refcount of library IDs as well...).
2015-08-18Refactor translation code out of blenfontCampbell Barton
- Add blentranslation `BLT_*` module. - moved & split `BLF_translation.h` into (`BLT_translation.h`, `BLT_lang.h`). - moved `BLF_*_unifont` functions from `blf_translation.c` to new source file `blf_font_i18n.c`.
2015-05-12Depsgraph: Add evaluation callbacks for granular nodes updateSergey Sharybin
This commit only adds callbacks which then later be used with major dependency graph commit, keeping the upcoming commit more clean to follow. Should be no functional changes so far still.
2015-04-04Cleanup: use BKE_animdata_* prefixCampbell Barton
2015-03-28Fix for earlier commit - Turning off "animated" influence/time didn't workJoshua Leung
Reshuffled order that in which NLA Strip's F-Curves vs its automatic settings are evaluated so that the automatic settings can always override the custom settings, since it's not that easy to get things working correctly the other way around.
2015-03-28Fix T36385: Animated Strip-Time doesnt updateJoshua Leung
This commit implements proper evaluation + keyframing support for animating influence and time on NLA Strips (among other properties) by resolving a few long standing issues which prevented the original design for this from working. The original design for animating these properties (and/or some of the other settings on NLA Strips) is that NLA Strips actually have some of their own F-Curves that are used for animating settings which will affect how they are evaluated. As seen in this bug report, the alternative of having these animated as part of the stack (which the strips work above/outside/on-top of) means that glitches can occur. Although one of the original considerations for why this wasn't implemented earlier was that introducing keyframes there isn't so clean cut, and causes UI design issues for how we expose these via the animation editors for editing (NOTE: support for that is still to come). Another concern is that this sets a precedent for how FModifiers might get evaluated.
2015-02-28Fix for NLA Solo/Mute behaviourJoshua Leung
The Solo and Mute functionality for the NLA system should really be mutually exclusive features. They both affect whether a given track applies or not. The only difference is that the Solo option mutes all the others, while the Mute only does this on a per track basis. Before this fix, muting a strip and then making it solo meant that the solo'd track would not play at all, which isn't really what we want.
2015-01-26Cleanup: strcmp/strncmp -> STREQ/STREQLEN (in boolean usage).Bastien Montagne
Makes usage of those funcs much more clear, we even had mixed '!strcmp(foo, bar)' and 'strcmp(foo, bar) == 0' in several places...
2015-01-26Fix T38619: Confusing logic for Keying Set keyframing SettingsJoshua Leung
The logic used for determining whether certain keyframing settings (i.e. visual, only needed, xyz -> rgb) got applied was wonky. The original intention here was that the Keying Set settings would override the global settings, and the path settings would override what was used for the Keying Set. However, that was not happening in all cases previously, as it was only possible to add flags and not to turn them off. This commit fixes that by introducing separate toggles to control whether the Keying Set/Path's settings override the settings inherited from its parent (i.e. the Keying Set for the Path, and the User Prefs for the Keying Set). The icons used for these toggles could get revised a bit (we need something which communicates "override this"; the current one is the closest I could find) WARNING: If you have old keying sets, this may cause some breakage!
2015-01-22Fix: Joining armatures fixes up the drivers accordinglyJoshua Leung
Finally! At long last, I've gotten this working! This ended up being far trickier to get right than anticipated; the normal remapping API's cannot be used as-is as they will just clobber over subtleties whenever datablock changes are involved. So, for now, we have to duplicate the logic a bit.
2015-01-21Fix: Joining armatures loses driversJoshua Leung
Currently, when joining two armatures, the drivers of the armatures being merged in are lost. This commit introduces a new AnimData API function for merging animation data into another AnimData block. NOTE: * For now, this only copies the drivers over. As a result, manual effort will still be needed to go through and fix the drivers. I am working on automating that process, but it's more important that the drivers don't have to be created from scratch for now (since this is needed for the Goosberry rigging work).
2014-12-01Cleanup: more int->bool.Bastien Montagne
2014-11-30Grease Pencil - Storyboarding Features (merge from GPencil_EditStrokes branch)Joshua Leung
This merge-commit brings in a number of new features and workflow/UI improvements for working with Grease Pencil. While these were originally targetted at improving the workflow for creating 3D storyboards in Blender using the Grease Pencil, many of these changes should also prove useful in other workflows too. The main highlights here are: 1) It is now possible to edit Grease Pencil strokes - Use D Tab, or toggle the "Enable Editing" toggles in the Toolbar/Properties regions to enter "Stroke Edit Mode". In this mode, many common editing tools will operate on Grease Pencil stroke points instead. - Tools implemented include Select, Select All/Border/Circle/Linked/More/Less, Grab, Rotate, Scale, Bend, Shear, To Sphere, Mirror, Duplicate, Delete. - Proportional Editing works when using the transform tools 2) Grease Pencil stroke settings can now be animated NOTE: Currently drivers don't work, but if time allows, this may still be added before the release. 3) Strokes can be drawn with "filled" interiors, using a separate set of colour/opacity settings to the ones used for the lines themselves. This makes use of OpenGL filled polys, which has the limitation of only being able to fill convex shapes. Some artifacts may be visible on concave shapes (e.g. pacman's mouth will be overdrawn) 4) "Volumetric Strokes" - An alternative drawing technique for stroke drawing has been added which draws strokes as a series of screen-aligned discs. While this was originally a partial experimental technique at getting better quality 3D lines, the effects possible using this technique were interesting enough to warrant making this a dedicated feature. Best results when partial opacity and large stroke widths are used. 5) Improved Onion Skinning Support - Different colours can be selected for the before/after ghosts. To do so, enable the "colour wheel" toggle beside the Onion Skinning toggle, and set the colours accordingly. - Different numbers of ghosts can be shown before/after the current frame 6) Grease Pencil datablocks are now attached to the scene by default instead of the active object. - For a long time, the object-attachment has proved to be quite problematic for users to keep track of. Now that this is done at scene level, it is easier for most users to use. - An exception for old files (and for any addons which may benefit from object attachment instead), is that if the active object has a Grease Pencil datablock, that will be used instead. - It is not currently possible to choose object-attachment from the UI, but it is simple to do this from the console instead, by doing: context.active_object.grease_pencil = bpy.data.grease_pencil["blah"] 7) Various UI Cleanups - The layers UI has been cleaned up to use a list instead of the nested-panels design. Apart from saving space, this is also much nicer to look at now. - The UI code is now all defined in Python. To support this, it has been necessary to add some new context properties to make it easier to access these settings. e.g. "gpencil_data" for the datablock "active_gpencil_layer" and "active_gpencil_frame" for active data, "editable_gpencil_strokes" for the strokes that can be edited - The "stroke placement/alignment" settings (previously "Drawing Settings" at the bottom of the Grease Pencil panel in the Properties Region) is now located in the toolbar. These were more toolsettings than properties for how GPencil got drawn. - "Use Sketching Sessions" has been renamed "Continuous Drawing", as per a suggestion for an earlier discussion on developer.blender.org - By default, the painting operator will wait for a mouse button to be pressed before it starts creating the stroke. This is to make it easier to include this operator in various toolbars/menus/etc. To get it immediately starting (as when you hold down DKEy to draw), set "wait_for_input" to False. - GPencil Layers can be rearranged in the "Grease Pencil" mode of the Action Editor - Toolbar panels have been added to all the other editors which support these. 8) Pie menus for quick-access to tools A set of experimental pie menus has been included for quick access to many tools and settings. It is not necessary to use these to get things done, but they have been designed to help make certain common tasks easier. - Ctrl-D = The main pie menu. Reveals tools in a context sensitive and spatially stable manner. - D Q = "Quick Settings" pie. This allows quick access to the active layer's settings. Notably, colours, thickness, and turning onion skinning on/off.
2014-11-21Cleanup: typoCampbell Barton
2014-10-06Fix T40350: Some texture prop did not have visual feedback they were driven.Bastien Montagne
This is only a (hacky) partial fix, actually, since `RNA_property_animated()` will still not work in those cases... Better that than nothing, though. Thanks to Campbell for review.
2014-08-05SpellingCampbell Barton
2014-08-02SpellingCampbell Barton
2014-07-31Fix T41236: Rendered viewport doesn't update with material actionsSergey Sharybin
The issue was caused by NLA evaluation without actions not setting id's flag as updated (as that's happening when action writes data to the ID datablock). Added the same flag set for the NLA evaluation as what's happening for actions.
2014-07-19Defines: replace ELEM3-16 with ELEM(...), that can take varargsCampbell Barton
2014-07-06Code cleanupJoshua Leung
- Fixed incorrect section heading - Missed one place where short was still used when the specific enum type would be more appropriate
2014-06-21Fix T40727: Renaming nodes did not correctly fix animation paths.Lukas Tönne
2014-06-13Code cleanup: BLI_strdupn -> BLI_strdupCampbell Barton
2014-05-29Comments: Note direction in doxy argsCampbell Barton
2014-05-29Cleanup: Use doxy for more structured commentsCampbell Barton