Commit Graph

227 Commits

Author SHA1 Message Date
fe5dd01595 linear ipo curves were still using their handles to calculate an extrapolated value.
It would only work when the bezier point had its handles set to auto before changing to a linear IpoCurve since the handles were being recalculated during transform.
2008-09-27 10:08:19 +00:00
d2c13039ed svn merge -r 16320:16369 https://svn.blender.org/svnroot/bf-blender/trunk/blender 2008-09-05 00:12:01 +00:00
cb89decfdc Merge of first part of changes from the apricot branch, especially
the features that are needed to run the game. Compile tested with
scons, make, but not cmake, that seems to have an issue not related
to these changes. The changes include:

* GLSL support in the viewport and game engine, enable in the game
  menu in textured draw mode.
* Synced and merged part of the duplicated blender and gameengine/
  gameplayer drawing code.
* Further refactoring of game engine drawing code, especially mesh
  storage changed a lot.
* Optimizations in game engine armatures to avoid recomputations.
* A python function to get the framerate estimate in game.

* An option take object color into account in materials.
* An option to restrict shadow casters to a lamp's layers.
* Increase from 10 to 18 texture slots for materials, lamps, word.
  An extra texture slot shows up once the last slot is used.

* Memory limit for undo, not enabled by default yet because it
  needs the .B.blend to be changed.
* Multiple undo for image painting.

* An offset for dupligroups, so not all objects in a group have to
  be at the origin.
2008-09-04 20:51:28 +00:00
8cf385a93d svn merge -r 16222:16320 https://svn.blender.org/svnroot/bf-blender/trunk/blender 2008-08-31 21:00:20 +00:00
25c116e80a Fixing typo to make compile working again 2008-08-30 23:12:01 +00:00
Nathan Letwory
ff0aab05b2 patch for bug #17553: material emit is allowed to go from 0.0 to 2.0; however curves only make it go to 1.0
reported and patched by slikdigit
2008-08-30 21:41:02 +00:00
5dafc1a553 svn merge -r 16060:16222 https://svn.blender.org/svnroot/bf-blender/trunk/blender 2008-08-22 09:31:32 +00:00
57d1a1eac2 New things for particle effectors:
- For newtonian particles a "self effect" button in particle extras makes the particles be effected by themselves if a particle effector is defined for this system, currently this is a brute force method so things start getting slow with more than ~100 particles, but this will hopefully change in the future.
- Two new effector types: charge and a Lennard-Jones potential based force (inter-molecular forces for example).
   -Charge is similar to spherical field except it changes behavior (attract/repulse) based on the effected particles charge field (negative/positive) like real particles with a charge.
   -The Lennard-Jones field is a very short range force with a behavior determined by the sizes of the effector and effected particle. At a distance smaller than the combined sizes the field is very repulsive and after that distance it's attractive. It tries to keep the particles at an equilibrium distance from each other. Particles need to be at a close proximity to each other to be effected by this field at all.
- Particle systems can now have two effector fields (two slots in the fields panel). This allows to create particles which for example have both a charge and a Lennard-Jones potential.
2008-08-21 21:12:27 +00:00
a6514f0c39 Animateable (ipos) power and fall-off for particle effectors. 2008-08-16 16:21:01 +00:00
e409c2463d WIP commit to introduce channels 2008-07-07 14:36:33 +00:00
6d7a43dd54 Fix for bug #13757: camera lens minimum value for ipo's was
different than the button.
2008-06-29 21:06:18 +00:00
205d06f5f4 Fix for bug #11002: particle ipo clump did not allow negative values
like the button in the user interface.
2008-05-08 08:41:56 +00:00
Chris Want
5d0a207ecb Patch from GSR that a) fixes a whole bunch of GPL/BL license
blocks that were previously missed; and b) greatly increase my
ohloh stats!
2008-04-16 22:40:48 +00:00
Chris Want
5e3cffc64a Patch to change license to GPL only, from GSR. 2008-01-07 19:13:47 +00:00
372ee054c0 Some notes for those who try to follow this :)
- first work on getting area/screen handling back
- added structure for where to put stuff, is still under
  review, wait a bit for docs?

Campbell is working on removing every bad level include from
sources, so we can safely rebuild the src/ directory.
2008-01-01 18:29:19 +00:00
58bf29e389 removed blenderdef.h, BIF_*, BDR_* and BSE_* header files (except for BIF_gl.h and BIF_glutil.h) 2008-01-01 18:16:10 +00:00
146b0aec14 == Sequencer ==
Fixed IPO calculation for threaded prefetch rendering. (do_seq_ipo used
global CFRA tststs...)
2007-12-23 21:27:12 +00:00
1e32ec2000 minor update, "Draw Handles" wasnt working when disabled everywhere and replaced some magic numbers 2007-12-01 23:25:00 +00:00
45c41ffb69 Two fixes:
- new option for Local Constraint Ipos did not set user counter in
  Ipo at file reading, causing data to get lost (not saved).

- Driver feature: the channels "Loc X Y Z" now also use the result
  of constraints, but transformed back into local space, as if it 
  was action X Y Z. Nice stuff for those who understand this... 
  it means you can drive something with a bone that has constraints.
2007-12-01 10:48:33 +00:00
7da56f4a9b Particles
=========

Merge of the famous particle patch by Janne Karhu, a full rewrite
of the Blender particle system. This includes:

- Emitter, Hair and Reactor particle types.
- Newtonian, Keyed and Boids physics.
- Various particle visualisation and rendering types.
- Vertex group and texture control for various properties.
- Interpolated child particles from parents.
- Hair editing with combing, growing, cutting, .. .
- Explode modifier.
- Harmonic, Magnetic fields, and multiple falloff types.

.. and lots of other things, some more info is here:

http://wiki.blender.org/index.php/BlenderDev/Particles_Rewrite
http://wiki.blender.org/index.php/BlenderDev/Particles_Rewrite_Doc

The new particle system cannot be backwards compatible. Old particle
systems are being converted to the new system, but will require
tweaking to get them looking the same as before.

Point Cache
===========

The new system to replace manual baking, based on automatic caching
on disk. This is currently used by softbodies and the particle system.

See the Cache API section on:
http://wiki.blender.org/index.php/BlenderDev/PhysicsSprint

Documentation
=============

These new features still need good docs for the release logs, help
for this is appreciated.
2007-11-26 22:09:57 +00:00
89317afbdf Patch #7767: Constraint Subtargets can now target anywhere on a bone, not just the head or tail
Patch by: Roland Hess (harkyman)

For example, a constraint can be sub-targeted at the 50% (or 31.2% or 85% etc.) point of its target bone, giving you enormous rigging flexibility and removing the need for complex contraptions to do such things as:

- A bone whose base slides only between to points on a rig (CopyLoc with a variable, animated subtarget point)
- Bones that attach to multiple points along another bone (CopyLocs, each with a different head/tail percentage)
- Bones that need to stretch to a point midway between specific spots on two other bones (old way: too crazy to mention; new way: stretch bone between points on end bones, then another stretch to the midpoint of the first stretch)

It is only used for the constraint types for which it is relevant: CopyLoc, TrackTo, StretchTo and MinMax, TrackTo, and Floor.

Notes:
- This is accessed by the Head/Tail number-slider. 
- This value can be animated per constraint
- The old "Copy Bone Tail" option for the CopyLoc constraint has been automatically converted to 1.0 Head/Bone values for the affected constraints
- In the code, this value is in the bConstraint struct, so it is available for all constraints, even though only a few implement it.
2007-11-12 04:17:03 +00:00
044ae7f82f A different approach for the new driver option: it now uses pose-space
instead of bone-space. This makes it visual easier to use. For the todo:
a large array of buttons for users to pick what kind of 'space' is used?
2007-11-04 19:41:21 +00:00
f996607632 New driver option for the poor suffering riggers:
"Rotation Difference"

This option, for Bones, allows the angle between two Bones to be
the driver for another Ipo channel. This angle now is hardcoded 
based on the Bone-space orientation (without parenting rotation).

Thanks to nathan for poking and test!
2007-11-04 17:14:39 +00:00
0cc2de1b37 == Action Editor Bugfixes (BugReport #7049) ==
This commit fixes several issues related to using the Action Editor with Shapekeys. I've known about most of them for a while, so now's the time to fix that.

1) When the shapekey anim data for an object comes from an Action (key's IPO block is linked to the "Shape" action-channel), the names of the individual shapekeys is now shown. They will only do so if the Action Editor is not pinned though.

2) Slider limits for the case described above should now be sane again

3) "Add New" option from the popup menu in the Action Editor header will now convert shapekey animation data from IPO to Action if the action editor is displaying Shapekey data at the time. Many users have often found the old way of having to toggle the "running man" in the IPO-editor header, too clumsy and confusing.
2007-08-15 10:04:45 +00:00
c4114780d4 Little code cleanup.
bsystem_time was being called with an extra variable, which was useless. Most of the places that called it, were passing NULL for that variable anyway.

I've also cleaned up that function a bit, but the underlying problems with that part of the code still exist (EVIL GLOBALS that are exported for frame_to_float), for mblur and fields rendering features. That remains for another time.
2007-08-05 09:21:29 +00:00
aad13c1b87 == IPO Muting ==
It is now possible to temporarily 'mute' and IPO-block or IPO-curve. This functionality has been requested by the Plumiferos team, and is based off Patch #6866 by Juho Vepsäläinen (bebraw).


Usage:
* In the IPO Editor header, there is a toggle button (open/closed eye used for Outliner Visibility restriction) beside the IPO-blocktype menu, when there is an active IPO-block in the IPO Editor.

* In the Action Editor, beside the 'lock' icon for channel protection on Action/Constraint channels, there is the open/closed 'eye' that can be toggled to set the mute status of said channel's IPO-block.

* Also in the Action Editor, you can mute individual IPO-curve channels in a similar manner.
2007-06-22 11:09:31 +00:00
Nathan Letwory
180d58430b Ortho type of camera is now also controlled by CAM_LENS ipo. 2007-05-02 16:45:13 +00:00
d0d9899e76 Bugfix #6201
Shape key drivers were not copied correctly, when choosing the option
"ADD NEW Scene -> Full copy".
2007-03-11 12:14:50 +00:00
c01aaac311 Two in one:
- Bugfix #5714
  New option "Save changed images" didn't respect relative file names

- Bugfix #5621
  New camera (shiftx, shifty) was missing in IpoWindow as animatable option
2007-01-15 12:44:45 +00:00
e61dec0767 Defocus Composite Node, by Alfredo de Greef
Log:
http://www.blender3d.org/cms/Composite__Defocus.836.0.html

An incredible quality composite effect, might be slow but worth waiting
for!
2006-12-21 18:11:07 +00:00
a720296999 Another 3-in-one commit:
- Unitialized variable in new shadow code caused Sun lamp shadow to not
  work.
- Ipo handle bug: when the handle was vertical it flipped around
- Loop select: unitialized variable caused it to work unpredictable in
  cases. Also found an unitialized var in collaps_edgeuvs().
2006-12-06 11:17:34 +00:00
d68d2528ac == Action Editor ==
Cleaned-up drawing code of keyframes. Code redundancy has been
reduced, and there should be slight performance gains (less looping,
no sorting of keys needed, possibly less memory usage).
2006-12-05 01:11:51 +00:00
342c900220 Proxy Objects revisited!
The first incarnation assumed that proxies were local objects per
definition. Unfortunately that makes it impossible to - for example -
reference-link an entire Scene with proxies, to be used as a special
character set.

This commit makes the proxy implementation also a bit more clear.

Related work: the scene-sets were not executed fully or correctly for
the dependency graph. That happens now (in 3d view) as well.
2006-11-30 15:54:21 +00:00
ed25eb9d9e Group Proxy: now drivers from proxy to Shape keys work :) 2006-11-14 21:06:11 +00:00
787ba4ea08 Bugfix #5085
An Ipo optimize commit of 2 months ago broke the Ipo "Linear" type for
extending.
2006-11-03 14:23:19 +00:00
a8461d2c40 DNA_ipo_types.h comments only
other are changes so calchandles_ipocurve only calc handels on a bezier line.
This makes bvh import faster but should also speed up internal IPO operations.
2006-08-04 14:08:21 +00:00
0458c50f63 Bug #4597
More Driver fixing...
Commit of over week ago to make drivers update correctly on cyclic
situations, forgot to fix another driver call... which then got called
always with 'current frame' set to zero.

Error only happened with animated (Ipos) Object-Object driver relations.

Also in this commit: when loading file, lattices with hooks were not
updated correctly.
2006-07-04 10:19:26 +00:00
1fa9af5dbc Plumiferos report: Ipo for material 'hardness' didn't go beyond 128
(Note; this value is stored in the curve when you make it, so you have
to remove the curve and insert it again...)
2006-06-26 16:57:44 +00:00
1aab013bcc Bugfix #4483
Fix for bugfix! The code added to solve Driver lag should not be called
when Bones in Armature are drivers (only when Objects are drivers).
2006-06-26 11:29:33 +00:00
03a1ee30b6 Bugfix #4420 + #3975
Found reasonable OK solution for a cyclic dependency that was bothering
a lot of (character) animators. They would like to drive bones with
Objects, but that lagged when you parent these Objects to the
armature, since that's a circular dependency.

Since Driver relations are only looking at local object properties (i.e.
it's local position/rotation) there's a simple way to solve it. In case
such Objects have an Ipo, it reads driver values directly from the
Object Ipo (on correct time) instead of Object values.
2006-06-23 12:15:22 +00:00
71f349e9dd Plumiferos bugfix:
The new (months ago) added option for "Local Constraint" always copied
and restored a PoseChannel quaternion, that disabled the required
normalizing of quaternions.

Only visible when you manually draw Ipo Curves, but it's probable that
it showed in other cases too.
2006-06-03 11:49:30 +00:00
e5b39b69d1 So! Finally time to work on finishing render pipeline project.
This commit brings back:

- Field Render
- MBlur Render (old style)
- Border render with or without cropping

Note: Field Render is not supported in Compositor yet. Blurring or filter
will destroy field information.
Both MotionBlur as Field render are done before Compositing happens.

Fixes:

- The "Save Buffers" option only worked on single frame renders, not for
  Anim render.
- Found an un-initalized variable in Render initialize... this might have
  caused the unknown random crashes with render.

Code restructure:

Cleaned up names and calls throughout the pipeline, more clearly telling
what goes on in functions.
This is visible in the updated first image of the Wiki doc:
http://mediawiki.blender.org/index.php/BlenderDev/RenderPipeline
2006-05-27 13:35:03 +00:00
89dab4397d Pydrivers: Ipo Drivers controlled by Python expressions
wiki with info: http://mediawiki.blender.org/index.php/BlenderDev/PyDrivers

(there are two sample .blends in the patch tracker entry, last link in
the wiki page)

Notes:

In usiblender.c I just made Python exit before the main library gets
freed. I found a situation with pydrivers where py's gc tried to del
objects on exit and their ID's were not valid anymore (so sigsegv).

Ton needs to check the depsgraph part.

For now pydrivers can reference their own object, something normal
ipodrivers can't. This seems to work fine and is quite useful, but if
tests prove the restriction is necessary, we just need to uncomment a
piece of code in EXPP_interface.c, marked with "XXX".

Thanks Ton for the ipodrivers code and adding the hooks for the py part
and Martin for the "Button Python Evaluation" patch from which I started
this one.

Anyone interested, please check the wiki, the .blends (they have
README's) and tell me about any issue.
2006-04-30 16:22:31 +00:00
2dce179e9d ==Sequencer==
This patch is mostly a usability patch for the sequencer, mainly written by
Anders Gudmundson and twisted a little bit by me.

- Lock Time to other windows
- Possibility to switch the X-Axis between frames and seconds-display
- IPO-Frame Locking for plugins (T-Key)
- Additional Popup to add HD-Sound and Movie at once
- In Timeline-Window: Sequencer windows only playback
- Make the IPOs a little bit IPO-Frame-Lock friendlier (doesn't jump;
  the frame that is drawn has the right dimension)
- Wheel-Mouse buttons make the sequencer window zoom again.
- The "This is not a sound/movie-file message" now reads "... or
  FFMPEG-support not compiled in!" since I learned some prominent
  people who complained, that hdaudio does not work for them ;-)
- Make SPACEKEY open up the "Add Strip"-Popup on the timeline and start
  playback in the preview window.
2006-03-26 21:36:42 +00:00
9a36e9b651 Sorry for the big commit, but I've been fixing many of these
issues in parallel... So this commit contains: an update of
the solver (e.g. moving objects), integration of blender IPOs,
improved rendering (motion blur, smoothed normals) and a first particle
test. In more detail:

Solver update:
- Moving objects using a relatively simple model, and not yet fully optimized - ok
  for box falling into water, water in a moving glass might cause trouble. Simulation
  times are influenced by overall no. of triangles of the mesh, scaling meshes up a lot
  might also cause slowdowns.
- Additional obstacle settings: noslip (as before), free slip (move along wall freely)
  and part slip (mix of both).
- Obstacle settings also added for domain boundaries now, the six walls of the domain are
  obstacles after all as well
- Got rid of templates, should make compiling for e.g. macs more convenient,
  for linux there's not much difference. Finally got rid of parser (and some other code
  parts), the simulation now uses the internal API to transfer data.
- Some unnecessary file were removed, the GUI now needs 3 settings buttons...
  This should still be changed (maybe by adding a new panel for domain objects).

IPOs:
- Animated params: viscosity, time and gravity for domains. In contrast
  to normal time IPO for Blender objects, the fluidsim one scales the time
  step size - so a constant 1 has no effect, values towards 0 slow it down,
  larger ones speed the simulation up (-> longer time steps, more compuations).
  The viscosity IPO is also only a factor for the selected viscosity (again, 1=no effect).
- For objects that are enabled for fluidsim, a new IPO type shows up. Inflow
  objects can use the velocity channels to animate the inflow. Obstacles, in/outflow
  objects can be switched on (Active IPO>0) and off (<0) during the simulation.
- Movement, rotation and scaling of those 3 types is exported from the normal
  Blender channels (Loc,dLoc,etc.).

Particles:
- This is still experimental, so it might be deactivated for a
  release... It should at some point be used to model smaller splashes,
  depending on the the realworld size and the particle generation
  settings particles are generated during simulation (stored in _particles_X.gz
  files).
- These are loaded by enabling the particle field for an arbitrary object,
  which should be given a halo material. For each frame, similar to the mesh
  loading, the particle system them loads the simulated particle positions.
- For rendering, I "abused" the part->rt field - I couldnt find any use
  for it in the code and it seems to work fine. The fluidsim particles
  store their size there.

Rendering:
- The fluidims particles use scaled sizes and alpha values to give a more varied
  appearance. In convertblender.c fluidsim particle systems use the p->rt field
  to scale up the size and down the alpha of "smaller particles". Setting the
  influence fields in the fluidims settings to 0 gives equally sized particles
  with same alpha everywhere. Higher values cause larger differences.
- Smoothed normals: for unmodified fluid meshes (e.g. no subdivision) the normals
  computed by the solver are used. This is basically done by switching off the
  normal recalculation in convertblender.c (the function calc_fluidsimnormals
  handles other mesh inits instead of calc_vertexnormals).
  This could also be used to e.g. modify mesh normals in a modifier...
- Another change is that fluidsim meshes load the velocities computed
  during the simulation for image based motion blur. This is inited in
  load_fluidsimspeedvectors for the vector pass (they're loaded during the
  normal load in DerivedMesh readBobjgz). Generation and loading can be switched
  off in the settings. Vector pass currently loads the fluidism meshes 3 times,
  so this should still be optimized.

Examples:
- smoothed normals versus normals from subdividing once:
  http://www10.informatik.uni-erlangen.de/~sinithue/temp/v060227_1smoothnorms.png
  http://www10.informatik.uni-erlangen.de/~sinithue/temp/v060227_2subdivnorms.png
- fluidsim particles, size/alpha influence 0:
  http://www10.informatik.uni-erlangen.de/~sinithue/temp/v060227_3particlesnorm.png
  size influence 1:
  http://www10.informatik.uni-erlangen.de/~sinithue/temp/v060227_4particlessize.png
  size & alpha influence 1:
  http://www10.informatik.uni-erlangen.de/~sinithue/temp/v060227_5particlesalpha.png
- the standard drop with motion blur and particles:
  http://www10.informatik.uni-erlangen.de/~sinithue/temp/elbeemupdate_t2new.mpg
  (here's how it looks without
  http://www10.informatik.uni-erlangen.de/~sinithue/temp/elbeemupdate_t1old.mpg)
- another inflow animation (moving, switched on/off) with a moving obstacle
  (and strong mblur :)
  http://www10.informatik.uni-erlangen.de/~sinithue/temp/elbeemupdate_t3ipos.mpg

Things still to fix:
- rotating & scaling domains causes wrong speed vectors
- get rid of SDL code for threading, use pthreads as well?
- update wiki documentation
- cool effects for rendering would be photon maps for caustics,
  and motion blur for particles :)
2006-02-27 11:45:42 +00:00
42d67ebd4f Enables sequencer ipos for effect plugins and audio-tracks
to be locked to frames instead of the range from 0-100.
Comes very handy on long timelines...
2006-02-05 19:13:44 +00:00
042d612df2 Giant commit!
A full detailed description of this will be done later... is several days
of work. Here's a summary:

Render:
- Full cleanup of render code, removing *all* globals and bad level calls
  all over blender. Render module is now not called abusive anymore
- API-fied calls to rendering
- Full recode of internal render pipeline. Is now rendering tiles by
  default, prepared for much smarter 'bucket' render later.
- Each thread now can render a full part
- Renders were tested with 4 threads, goes fine, apart from some lookup
  tables in softshadow and AO still
- Rendering is prepared to do multiple layers and passes
- No single 32 bits trick in render code anymore, all 100% floats now.

Writing images/movies
- moved writing images to blender kernel (bye bye 'schrijfplaatje'!)
- made a new Movie handle system, also in kernel. This will enable much
  easier use of movies in Blender

PreviewRender:
- Using new render API, previewrender (in buttons) now uses regular render
  code to generate images.
- new datafile 'preview.blend.c' has the preview scenes in it
- previews get rendered in exact displayed size (1 pixel = 1 pixel)

3D Preview render
- new; press Pkey in 3d window, for a panel that continuously renders
  (pkey is for games, i know... but we dont do that in orange now!)
- this render works nearly identical to buttons-preview render, so it stops
  rendering on any event (mouse, keyboard, etc)
- on moving/scaling the panel, the render code doesn't recreate all geometry
- same for shifting/panning view
- all other operations (now) regenerate the full render database still.
- this is WIP... but big fun, especially for simple scenes!

Compositor
- Using same node system as now in use for shaders, you can composit images
- works pretty straightforward... needs much more options/tools and integration
  with rendering still
- is not threaded yet, nor is so smart to only recalculate changes... will be
  done soon!
- the "Render Result" node will get all layers/passes as output sockets
- The "Output" node renders to a builtin image, which you can view in the Image
  window. (yes, output nodes to render-result, and to files, is on the list!)

The Bad News
- "Unified Render" is removed. It might come back in some stage, but this
  system should be built from scratch. I can't really understand this code...
  I expect it is not much needed, especially with advanced layer/passes
  control
- Panorama render, Field render, Motion blur, is not coded yet... (I had to
  recode every single feature in render, so...!)
- Lens Flare is also not back... needs total revision, might become composit
  effect though (using zbuffer for visibility)
- Part render is gone! (well, thats obvious, its default now).
- The render window is only restored with limited functionality... I am going
  to check first the option to render to a Image window, so Blender can become
  a true single-window application. :)
  For example, the 'Spare render buffer' (jkey) doesnt work.
- Render with border, now default creates a smaller image
- No zbuffers are written yet... on the todo!
- Scons files and MSVC will need work to get compiling again

OK... thats what I can quickly recall. Now go compiling!
2006-01-23 22:05:47 +00:00
e7285229b8 Tuesday merger of bf-blender into orange branch. 2006-01-10 22:10:14 +00:00
Nathan Letwory
b0d0c87a1f #3706 (patch tracker)
- Adds missing ipos for texture
   * color, contrast, brightness
- Adds IKey menu in the texture subcontext

#3711 (bug tracker)
- report and patch for missing blend types Halo and Radial

Patches by Levon Hudson
2006-01-06 13:33:20 +00:00
fae20e494e orange: animation baking code. also a patch to autokey, to only key the keys made. 2005-12-18 20:14:22 +00:00