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
2014-02-05Fix T35247: Particle texture behaves incorrectly after changing the number ↵Sergey Sharybin
of particles Root of the issue goes to the order of particle initialization which does texture evaluation (which does depend on particle coordinate) and particle birth coordinate calculation. So basically what happened is: * Changing number of particles re-allocated all the particles, which sets their coordinate to (0,0,0) * Texture evaluation used this non-initialized coordinate * Coordinates were calculated for particles Reshuffled code a bit so now texture evaluation happens after particles. coordinate calculation. Basically moved texture evaluation to particle reset function. Reset happens after initialization anyway and it does know particle coordinates. Also, if reset is being called without init then it's also kind of logical to re-evaluate texture because particle coordinates might change.
2014-02-05Fix T38476: incorrect hair draw type after editing particle system in edit mode.Brecht Van Lommel
2013-08-19Make lattice deform safe for threadingSergey Sharybin
Lattice deformation used to store some runtime data inside of lattice datablock itself. It's something which is REALLY bad. Ideally DNA shouldn't contain and runtime data. For now solved it in a way that initialization of lattice deform will create a structure which contains lattice object for which deformation is calculating and that runtime data which used to be stored in lattice datablock itself. It works really fine for mesh deform modifier, but there's still runtime data stored in particle system DNA, It didn't look something easy to be solved, so leaving this as-is for now. -- svn merge -r58277:58278 -r58795:58796 ^/branches/soc-2013-depsgraph_mt
2013-06-25Fix particle hair display percentage not properly getting restored afterBrecht Van Lommel
rendering. This used to happen in an unneeded frame change update which was removed. For heavy particle systems this could have a bad impact on viewport performance after rendering.
2013-05-19Fix #35407: different particle behavior compared to 2.66, reverted part of ↵Brecht Van Lommel
56073.
2013-04-16Random number generator: replace a bunch of usage of the global random numberBrecht Van Lommel
generator with a local one. It's not thread safe and will not give repeatable results, so in most cases it should not be used. Also fixes #34992 where the noise texture of a displacement modifier was not properly random in opengl animation render, because the seed got reset to a fixed value by an unrelated function while for final render it changed each frame.
2013-04-03code cleanup: unused functionsCampbell Barton
2013-03-26style cleanup:Campbell Barton
also rename mesh_getVertexCos() --> BKE_mesh_vertexCos_get() to match curve function.
2013-02-19Fix for [#34099] Particles leaking from moving meshesAlex Fraser
This was caused by a floating point precision error. During collision detection, Newton-Raphson iteration is used to find the exact time of the collision. But when using subframes, the initial Newton step was too small. Now the initial step is given in absolute units. When subframes = 0, this should behave almost the same as before. Thanks to Janne Karhu, Lukas Toenne and Ton Roosendaal for their help with this patch, and to AutoCRC for funding.
2013-02-02style cleanupCampbell Barton
2013-01-19style cleanupCampbell Barton
2012-12-14Adding a new SPH solver that is more physically accurate. See patch #29681Alex Fraser
http://projects.blender.org/tracker/index.php?func=detail&aid=29681&group_id=9&atid=127 The solver was mostly implemented by John Mansour at VPAC, with help from me and with funding from the AutoCRC. The SPH formulation is due to Gingold and Monaghan, and the smoothing kernel is due to Wendland. This solver does not replace the old one; it is available as an option. Note that the new solver uses different units than the old one. The patch page has a couple of attachments that can be used to test the new solver, particularly sphclassical_dam_s0.01_grav.blend (ignore the earlier tests). The simulation in that file compares well with a physical experimental dam break; details in a paper by Changhong Hu and Makoto Sueyoshi, also referred to on that page.
2012-12-11define the size of matrix args for both rows/cols.Campbell Barton
2012-10-20code cleanup:Campbell Barton
- define array sizes for functions that take vectors. - quiet some -Wshadow warnings. - some copy/paste error in readfile.c made it set the same particle recalc flag twice.
2012-05-13code cleanup: header cleanup and remove some duplicate defines.Campbell Barton
2012-05-05code cleanup: function naming, use BKE_*type* prefix.Campbell Barton
2012-04-21style cleanupCampbell Barton
2012-04-11code cleanup: float formatting was confusing in some cases - eg: (0.,0.,0.)Campbell Barton
2012-03-04style cleanup / comment formatting for bli/bke/bmeshCampbell Barton
2012-02-28code cleanup: use float vector size in function definitions, and const's ↵Campbell Barton
where the values are unchanged.
2012-02-17unify include guard defines, __$FILENAME__Campbell Barton
without the underscores these clogged up the namespace for autocompleation which was annoying.
2012-01-02Added OpenMP multithreading for SPH particle systems.Alex Fraser
2011-11-26minor edit - weight_to_rgb() and ramp_blend() now take a float vector rather ↵Campbell Barton
than 3 float pointers. also make particle draw use a float vec.
2011-11-06replace macros with bli math functions for particles codeCampbell Barton
2011-10-23remove $Id: tags after discussion on the mailign list: ↵Campbell Barton
http://markmail.org/message/fp7ozcywxum3ar7n
2011-09-25Committing patch #27442: Adaptive time step for fluid particles. The number ofAlex Fraser
subframes can now be altered automatically while an SPH (fluid particle) simulation is running.
2011-06-23More flexible size options for particle billboards. This adds scale factors ↵Lukas Toenne
for width and height of billboards, relative to the particle size. It's useful when the particle size is primarily used for collision and the like, so the billboard appearance can be adjusted independently. Also allows non-square billboards. In addition the billboards can be scaled by the particle velocity with optional head and tail factors (similar to line drawing options). This allows for pseudo-motionblur effects.
2011-06-12Bug fix: keyed physics didn't work properly if the first key wasn't the ↵Janne Karhu
keyed particle system itself * Also some nicer rotation handling for the explode modifier
2011-03-29Fix for [#26658] Permeable colliders stop particlesJanne Karhu
* Forgot this exception from the collisions rewrite. Don't check collisions with the same face twice.
2011-03-18New particle collisions code:Janne Karhu
* The old collisions code detected particle collisions by calculating the collision times analytically from the collision mesh faces. This was pretty accurate, but didn't support rotating/deforming faces at all, as the equations for these quickly become quite nasty. * The new code uses a simple "distance to plane/edge/vert" function and iterates this with the Newton-Rhapson method to find the closest particle distance during a simulation step. * The advantage in this is that the collision object can now move, rotate, scale or even deform freely and collisions are still detected reliably. * For some extreme movements the calculation errors could stack up so much that the detection fails, but this can be easily fixed by increasing the particle size or simulation substeps. * As a side note the algorithm doesn't really do point particles anymore, but uses a very small radius as the particle size when "size deflect" isn't selected. * I've also updated the collision response code a bit, so now the particles shouldn't leak even from tight corners. All in all the collisions code is now much cleaner and more robust than before!
2011-03-09Fix for [#26372] Objects as PS Hair displays and renders differentlyJanne Karhu
* Grid distribution isn't really suited for hair, so this is now disabled. * Setting a jittered distribution with particles/face = 1 now creates particles on the center of faces. * Quite a bit of cleanup of the whole particle distribution code.
2011-02-18doxygen: blenkernel under core as module.Nathan Letwory
2011-02-13Small update for billboards:Janne Karhu
* Renamed the old split uv's animate option "time" to "age" and added a new option to change the used split frame by frame. These are good changes were suggested/implied by Hannu Hoffren over 3 years ago in his tutorial video! (oh my how time flies) * Also cleaned up the billboard ui quite a bit. For example now the uv channels can be properly chosen from the existing channels.
2011-02-12Particles todo item: particle texturesJanne Karhu
* Effecting particle properties with textures was possible in 2.49, but not in 2.5 anymore. * Now particles have their own textures (available in texture panel for objects with particle systems), which are totally separate from the material textures. * Currently a basic set of particle properties is available for texture control. Some others could still be added, but the whole system is not intended as an "change anything with a texture" as this kind of functionality will be provided with node particles in the future much better. * Combined with the previously added "particle texture coordinates" this new functionality also solves the problem of animating particle properties through the particle lifetime nicely. * Currently the textures only use the intensity of the texture in "multiply" blending mode, so in order for the textures to effect a particle parameter there has to be a non-zero value defined for the parameter in the particle settings. Other blend modes can be added later if they're considered useful enough.
2011-01-17remove/comment unused defines, also zero FileGlobal.filename to quiet valgrind.Campbell Barton
2010-11-18Algorithm fix for fluid particles:Janne Karhu
* The SPH fluid particle algorithm was implemented a bit wrong. This problem could for example result in the fluid moving sideways after being dropped straight to a horizontal collision surface, a very big no-no as far as real world physics are concerned! * After some extensive code shuffling the algorithm is now much more true to the paper it was implemented from, and more importantly now the physics should be correct too! * The main thing was that fluids calculations can effect many particles simultaneously, so just a single loop through all particles can't work properly. As a side note this also means that the actual fluid algorithm can't be made threaded :( * To make things work I also had to reshuffle some general particle physics code, but there should be no functional changes what so ever to other physics types, so poke me immediately if something strange happens. Note to users: these changes will most probably effect the way previously done sph fluid simulations look, so some parameter tweaking will be needed to get things back looking the way they were.
2010-11-17use 'const char *' by default with RNA functions except when the value is ↵Campbell Barton
flagged as PROP_THICK_WRAP. Also use const char in many other parts of blenders code. Currently this gives warnings for setting operator id, label and description since these are an exception and allocated beforehand.
2010-11-03Oops, particle collisions didn't take simulation subframes into account at all.Janne Karhu
* This caused nearly all particles to leak through the collision surface if simulation subframes were used and the collision object was moving. * In addition to fixing this I also did some more cleanup of the collision code and refined some of the comments.
2010-09-02Fix for [#23298] Kill particle breaks when baking simulationJanne Karhu
* Cached particle die times are now read from cached data
2010-09-02"Fix" for [#23621] lattice modifier on particle hair when applied doesn't ↵Janne Karhu
apply it to the hair * Although not strictly a bug it is the expected behavior and won't mess anything else up. * Note: the lattice is applied to the actual hair keys instead of the calculated strands so the applied result will differ a bit from the original.
2010-07-17Revert part of commit 29079, cleanup of particle path drawing logicBrecht Van Lommel
This commit and other commits attempting to fix it broke various things. The main thing that changed was that instead of computing children/paths in advance as part of particle_system_update, this was moved to do it just before drawing or rendering. I've changed back that behavior and tried to keep the other fixes in the commit. When the new particle system was just committed, it also worked this way but gave various problems, and I had to remove that behavior to get things working stable. Basically it meant that you could get have a path cache that was outdated in various situations, and it doesn't fit well with dependency graph evaluation order. This fixes: #22823: Children Particle Rendering is broken #22733: Particle objects not displayed #22888: SigSegV when rending hair particles #22820: Another SigSegV when undo adding hairs in particel edit mode Some particle setups in dupligroups. The three bugs that the original commit fixed are now also still working in my tests: #21316: Hair weight drawing is wrong #21923: Consistent Crash When Rendering Particle Scene. #21950: Path rendering option for particles causes crash
2010-05-30Some cleanup of particle path drawing logic:Janne Karhu
* Path drawing now works for non hair particles. * Should fix the following bugs too: [#21316] Hair weight drawing is wrong [#21923] Consistent Crash When Rendering Particle Scene. [#21950] Path rendering option for particles causes crash
2010-03-10Fix for [#21411] Particles jitter when resting on a collision objectJanne Karhu
* Particle now take particle acceleration during collisions into account.
2010-02-12correct fsf addressCampbell Barton
2009-12-30Fix for [#20430] Boids options for Flying and climbing do not workJanne Karhu
* Boids didn't yet use global gravity
2009-11-28py/rna apiCampbell Barton
- object.modifiers.add()/remove() - armature.edit_bones.active wasnt named correctly
2009-10-15move view3d keymaps so edit&paint mode keymaps override removed workaround ↵Campbell Barton
that prevented switching directly from editmode to paint modes + other minor changes
2009-10-05General particle bug fixes + few small goodiesJanne Karhu
The goodies: * Curves can be used as normal dynamic effectors too with the new "curve" field shape. * Group visualization has optional duplication counts for each object in the specified group. * Object & group visualizations, which are done without taking the dupliobject's global position into account (unless the whole group is used). This is much nicer than the previous behavior, but I added a "Use Global Location" option for those who want to use it the old way. * The active particle system's particles are now drawn a with theme coloured outline instead of pure white. * Added object aligned velocity factors (buttons categorized and re-organized too). Bug fixes: * Absorption didn't work as the ui toggle button was forgotten. * Some other force field ui tweaks. * Crash after adding children and changing trails count. * Display types "cross" and "axis" crashed. * Particles weren't drawn with correct coloring. * Billboards didn't update properly in viewport to camera location changes. * Particle rotation wasn't recreated correctly from point cache. * Changing particles amount crashed sometimes. * Some files with child hair crashed on loading. * Compiler warning fixes. * Adding boids crashed on frame 1;
2009-10-01Unified effector functionality for particles, cloth and softbodyJanne Karhu
* Unified scene wide gravity (currently in scene buttons) instead of each simulation having it's own gravity. * Weight parameters for all effectors and an effector group setting. * Every effector can use noise. * Most effectors have "shapes" point, plane, surface, every point. - "Point" is most like the old effectors and uses the effector location as the effector point. - "Plane" uses the closest point on effectors local xy-plane as the effector point. - "Surface" uses the closest point on an effector object's surface as the effector point. - "Every Point" uses every point in a mesh effector object as an effector point. - The falloff is calculated from this point, so for example with "surface" shape and "use only negative z axis" it's possible to apply force only "inside" the effector object. * Spherical effector is now renamed as "force" as it's no longer just spherical. * New effector parameter "flow", which makes the effector act as surrounding air velocity, so the resulting force is proportional to the velocity difference of the point and "air velocity". For example a wind field with flow=1.0 results in proper non-accelerating wind. * New effector fields "turbulence", which creates nice random flow paths, and "drag", which slows the points down. * Much improved vortex field. * Effectors can now effect particle rotation as well as location. * Use full, or only positive/negative z-axis to apply force (note. the z-axis is the surface normal in the case of effector shape "surface") * New "force field" submenu in add menu, which adds an empty with the chosen effector (curve object for corve guides). * Other dynamics should be quite easy to add to the effector system too if wanted. * "Unified" doesn't mean that force fields give the exact same results for particles, softbody & cloth, since their final effect depends on many external factors, like for example the surface area of the effected faces. Code changes * Subversion bump for correct handling of global gravity. * Separate ui py file for common dynamics stuff. * Particle settings updating is flushed with it's id through DAG_id_flush_update(..). Known issues * Curve guides don't yet have all ui buttons in place, but they should work none the less. * Hair dynamics don't yet respect force fields. Other changes * Particle emission defaults now to frames 1-200 with life of 50 frames to fill the whole default timeline. * Many particles drawing related crashes fixed. * Sometimes particles didn't update on first frame properly. * Hair with object/group visualization didn't work properly. * Memory leaks with PointCacheID lists (Genscher, remember to free pidlists after use :).
2009-09-18Particles cleanup, optimizations and some small new stuff.Janne Karhu
New stuff - Bending springs for hair dynamics. Code cleanup & optimization - Disabled reactor particles temporarily for cleanup, it's a clumsy system that will be replaced with something better. - Removed child seams, something better will come here too :) - Normal particle drawing data is now saved between redraws if the particles don't move between redraws. * For example rotating the 3d view is now realtime even with 1M particles. - Many random values for particles now come from a lookup table making things much faster. - Most accessed small point cache functions are now much faster as macros. - Lot's of general code cleanup. - Nothing big should have changed so if something doesn't work like it used to it's probably just a typo somewhere :)