Age | Commit message (Collapse) | Author |
|
When loading a file with linked external scene, and that external scene
didnt exist anymore, and that scene was active in the file -> crash!
Render code; changed to use local 'puno' flag for threaded render.
|
|
Render:
- New; support for dual CPU render (SDL thread)
Currently only works with alternating scanlines, but gives excellent
performance. For both normal render as unified implemented.
Note the "mutex" locks on z-transp buffer render and imbuf loads.
- This has been made possible by major cleanups in render code, especially
getting rid of globals (example Tin Tr Tg Tb Ta for textures) or struct
OSA or using Materials or Texture data to write to.
- Made normal render fully 4x32 floats too, and removed all old optimizes
with chars or shorts.
- Made normal render and unified render use same code for sky and halo
render, giving equal (and better) results for halo render. Old render
now also uses PostProcess options (brightness, mul, gamma)
- Added option ("FBuf") in F10 Output Panel, this keeps a 4x32 bits buffer
after render. Using PostProcess menu you will note an immediate re-
display of image too (32 bits RGBA)
- Added "Hue" and "Saturation" sliders to PostProcess options
- Render module is still not having a "nice" API, but amount of dependencies
went down a lot. Next todo: remove abusive "previewrender" code.
The last main global in Render (struct Render) now can be re-used for fully
controlling a render, to allow multiple "instances" of render to open.
- Renderwindow now displays a smal bar on top with the stats, and keeps the
stats after render too. Including "spare" page support.
Not only easier visible that way, but also to remove the awkward code that
was drawing stats in the Info header (extreme slow on some ATIs too)
- Cleaned up blendef.h and BKE_utildefines.h, these two had overlapping
defines.
- I might have forgotten stuff... and will write a nice doc on the architecture!
|
|
or deleted without keeping track of spaces in names, causing in potential
loss of data.
Needs review!
|
|
Sequence editor crash when you delete Scenes which were used as a strip.
Related to that, file reading code didn't restore pointers for strips
correctly when you save with open "Meta" strip.
First bug 8 year old. Second 1 month. :)
|
|
Appending objects with constraints expands links to objects (according
code) but doesn't give such objects a link to Scene.
Apprently, somewhere in NaN days, someone commented a call, which
already invoked comments... here's the full code + comments now:
/* give a base to loose objects */
give_base_to_objects(G.scene, &(G.main->object));
/* has been removed... erm, why? (ton) */
/* 20040907: looks like they are give base already in append_named_part(); -Nathan L */
/* 20041208: put back. It only linked direct, not indirect objects (ton) */
:-)
|
|
oops code, having pointers to ID structs that are invalid.
This solves at least it crashing... oops needs to be refreshed once :)
(occurred on testing complex files, with conversion from nurbs=>mesh)
|
|
While going over the code, I found out the "nabla", the size of offset
vectors for calculating derivatives of a texture, is a built in constant.
Even worse, the value was different for new noise types (musgrave etc).
So I've added a new slider for it in the procedural texture panels, which
by default is set to 0.025, the value of the old constant. Also made sure
it works with equal effect in all procedurals.
NOTE: a small Nabla will give sharper, detailed bump, but the effect also
becomes smaller, correct that in the Mapping Panel of materials.
For better & compliant control over the bumpmapping, I've also included
the Colorband output in derivatives calculus, so the bump output then
matches the color created. It's also a nice tool to finetune output of
textures for bumpmapping in general.
Bug fix; clicking on the rightmose 'item' in ColorBand didn't activate it.
Found out the ColorBand was slightly drawn off (2 pixels).
|
|
channels to link texture to.
The amount of code changes seems large, but is mostly getting rind of
hardcoded values (6 and 8) for channels, replacing it with MAX_MTEX.
Further did some fixes;
- Ipo for Lamp showed too many mapping channels
- Texture MapTo buttons for lamp missed the slider to blend texture color
- Lamp texture mapping "View" only worked for Spot, now it uses lamp-
view vector for all types. (Nice for projections!)
|
|
When choosing "render engine" in Scene Buttons, the newly added or removed
Panels didn't invoke a re-alignment event yet.
Also added code that inserts new panels as good as possible on their
previous locations. This works reliable for 1 new panel, not for more, this
because a Panel only stores its old location, not the locations of all
Panels in a given configuration. Consider that minor issue...
|
|
On appending in posemoding, Blender could crash.
Found out the new 'select appended' also sets the 'active base/object'.
This isn't OK on that level of the code, 'active' exists (and needs to be
set) on UI code level in src/, not in the middle of file reading function.
Also removed weird negative bitflag that enforced 'select appended' to
be default. If you want that, set the flag itself in do_versions or so.
In my opinion it is best saved in .B.blend instead. Another time...
|
|
Appending or Linking data from other file always cleared scene scriptlinks,
due to having 1 line of code just on wrong location... is bug since 2.25,
so finally something again I didn't recently break in working code :)
|
|
- Nurbs objects didnt render ray-transp. Was caused by 1) wrong normal calc
and 2) quads with vertices on same locations. Solved it with nice code that
checks illegal quads and turns them into triangles
- Made 'physics engine' variable SUMO default
- Typo in toolbox fix; cyclic isn't F but C
|
|
removed calling function from src/ and added the few lines in readfile.c
|
|
localview got stuck after an Undo command, it now restores to normal view
when no localviewed objects are there.
Please note again; localview is UI, so actually not saved in the undo...
|
|
This was actually a wrong pointer check in fileread that caused no harm
in past, but with UI-less file save it wreaked havoc!
Decided to add undo in sequencer window after all... it also involved
saving Meta strip settings in files. Very nice :)
|
|
|
|
- themecolor for the 'bars' in NLA used signed char
- global undo, restore pointers for UI accidentally added user values for
oops and outliner, causing unused blocks to show used
- moved popup menus one pix up or down, it was overlapping the button
causing accidental selection of menus
|
|
(prevents crash reported by sgefant!)
- Selection outline for Curve objects didnt draw right after leave
editmode
- outliner now default when first viewing Oops window (dangerous?)
- Zoom with ctrl+middlemouse works in Oops again
|
|
Crash reported on combo of append object, do global undo, and re-append
same object. Appears to be an open filehandle...
|
|
- Undo in texteditor didnt work, event (ALT+U) was swallowed by new undo
menu (ALT+U too)
- global undo doesnt restore UI's as we know... so undo-ing with a text
editor active cannot always restore correct text block you were editing.
As extra service I added that when no restore is possible, it links to
the first block available.
|
|
because of a flag set which prevented drawing the objects.
|
|
Problem was dynamic linking of files with game logic. The links between
sensors/controllers/actuators got lost.
Never though i'd still understand the code, not too bad at all! :)
|
|
There's an ancient code in Blender to denote a projected vertex coordinate
is invisble, it sets the x coord at 3200. :)
This wasn't updated while coding loopselect, nor edge select. Causing in
extreme zoomed in situations vertex selecting go wrong.
Also added; option "don't load GUI" in fileselector doesn't get saved in
files.
|
|
The outliner is a hierarchical diagram displaying a list of data in Blender
and its dependencies. The 'databrowse' doesn't really show it, and Oops is
too chaotic still. And most of all, the former two don't offer much tools.
After discussions on irc, Matt came with this design proposal;
http://mke3.net/blender/interface/layout/outliner/
Which is closely followed for the implementation.
The current version only shows all 'library data' in Blender (objects,
meshes, ipos, etc) and not the 'direct data' such as vertex groups or NLA.
I decided to make it inside the Oopw window, as an option. You can find the
option in the "View" pulldown, or directly invoke it with ALT+SHIFT+F9
Here's a quick overview of the Outliner GUI:
- Header pulldown has options what it can show (Visible = in current layers)
- click on triangle arrow to open/close
- press AKEY to open/close all
- Leftmouse click on an item activates; and does based on type a couple of
extra things:
- activates a scene
- selects/activates the Object
- enters editmode (if clicked on Mesh, Curve, etc)
- shows the appropriate Shading buttons (Lamp, Material, Texture)
- sets the IpoWindow to the current IPO
- activates the Ipo-channel in an Action
- Selected and Active objects are drawn in its Theme selection color
- SHIFT+click on Object does extend-select
- Press DOTkey to get the current active data in center of view
TODO;
- rightmouse selection; for indicating operations like delete or duplicate
- showing more data types
- icon (re)design...
- lotsof options as described in Matts paper still...
|
|
from within mesh_modifiers (kernel deform.c). It copies vertices to a
temporal particle system (struct SoftBody with BodyPoint structs) to do
physics tricks with it.
For each frame change the delta movements (based on standard ipo anim or
even other deforms (later) are applied to the physics system. How to apply
and calculate satisfying results is not my thing... so here I'll commu-
nicate with others for.
Since it's in the modifier stack, the SoftBody code can run entirely on
original data (no displists!).
Right now I've implemented 2 things;
- "Goal" which is a per vertex value for how much the current position
should take into account (goal=1 is without physics). This is a powerful
method for artists to get control over what moves and not. Right now i
read the vertex color for it.
- And some spring stuff, which now only works based on force moving it to
the originial location. This doesnt work with 'goal'... erhm.
- You can re-use physics vars from engine, used right now is (in Object)
- damping
- springf (spring factor)
- softflag (to set types, or activate softbody for it
- The SoftBody pointer in struct Object is only runtime, nothing saved in
file
To prevent all users going to complain it doesn't work, I've hidden the
functionality. :)
The buttons to set softbody 'on' only show now (psst psst) when the object has
name "soft" as first 4 characters. You can find the buttons in the F7 Particle
Interaction Panel (which should be renamed 'physics properties' later or so.
Demo file:
http://www.blender.org/bf/softbody.blend
|
|
- Added transparent wires in solid draw for editmmode, to denote selecting
clicks "through". Switching this and the zbuf-clip mode is actually nice!
- little annoyance; removed object centerpoint drawing in editmode.
|
|
The changelog is very long... it's on the web too:
http://www.blender3d.org/cms/Mesh_editing_rewrite.425.0.html
EditMesh refactor notes (user)
**** New selection modes
When entering Edit Mode for a Mesh, you now have the choice for three selection modes. These are shown as icons in the 3D header (hotkey is being searched for!).
- Vertex Select
Select vertices as usual, fully compatible with how previous version work
- Edge Select
Vertices are not drawn anymore, and selections happen by default on the edges. It is a true edge select, meaning that you can select three out of four edges in a face, without automatic having the 4th edge selected.
- Face Select
Instead of vertices, now selection 'points' are drawn in the face centers. Selected faces also get a colored outline, like for edges. This also is true face select, for each face individual regardless selection status of its vertices or edges.
While holding SHIFT, and press a selection mode, you can also combine the above choices. Now selection becomes mixed, and will behave as expected.
For example; in Edge+Face select mode, selecting the 4 edges of a face will select the face too.
The selection modes and optional drawing modes (like transparant faces, normals, or solid drawing) all work together. All of Blender's mesh editing tools now react to the correct selection mode as well.
Most noticeable it's in:
**** Extrude
Extruding in Edge or Face Select mode allows much more precise control over what's extruded and what should be excluded. Try for example a checker pattern selection, and extrude it.
New is the fixed translation when faces are extruded. This always follows the (averaged) face normal(s) of the old face(s), enabling much easier working in 3D views . A single 'G' (Grab) or 'R' (Rotate) or 'S' (Scale) will change transform modus as usual.
**** Other things to note
- Hiding edges/faces will also behave different based on Select Mode.
- while editing, normals of faces are updated always now
- Border select (BKEY) has 2 different rules for edges; when one edge is fully inside of the border, it will only select edges that are fully inside. Otherwise it selects each edge intersecting with the border.
- in face mode, adding vertices, edges or a circle is invisible...
- "Add monkey" now works as a normal primitive (rotated and on 3d cursor)
- Mesh undo was fully recoded, hopefully solving issues now with Vertex Keys and Groups
- Going in and out of editmode was fully recoded. Especially on larger models you'll notice substantial speed gain.
**** Todo
Add 'FaceSelect mode' functionality in EditMode, including zbuffered selection, display and editing of UV texture.
EditMesh refactor notes (coder)
**** Usage of flags in general
The "->f" flags are reserved for the editmesh.c and editmesh_lib.c core functions. Actually only selection status is there now.
The "->f1" and "->f2" flags are free to use. They're available in vertex/edge/face structs. Since they're free, check carefully when calling other functions that use these flags... for example extrude() or subdivide() use them.
**** Selection flags
EditVert: eve->f & SELECT
EditEdge: eed->f & SELECT
EditFace: efa->f & SELECT
- Selection is only possible when not-hidden!
- Selection flags are always up-to-date, BUT:
if selection mode >= SELECT_EDGE vertex selection flags can be incorrect
if selection mode == SELECT_FACE vertex/edge selection flags can be incorrect
This because of shared vertices or edges.
- use for selecting vertices:
eve->f &= SELECT
- use for selecting edges always:
void EM_select_edge(eed, 1) // 1 = select, 0 = deselect
- use for selecting faces always:
void EM_select_face(efa, 1) // 1 = select, 0 = deselect
- To set the 'f' flags in all of the data:
void EM_set_flag_all(int flag);
void EM_clear_flag_all(int flag);
- the old faceselectedOR() and faceselectedAND() are still there, but only
to be used for evaluating its vertices
**** Code hints for handling selection
If the selectmode is 'face'; vertex or edge selections need to be flushed upward. Same is true for 'edge' selection mode. This means that you'll have to keep track of all selections while coding... selecting the four vertices in a face doesn't automatically select the face anymore.
However, by using the above calls, at least selections flush downward (to vertex level). You then can call:
void EM_selectmode_flush(void);
Which flushes selections back upward, based on the selectmode setting. This function does the following:
- if selectmode 'vertex': select edges/faces based on its selected vertices
- if selectmode 'edge': select faces based its selected edges
This works fine in nice controlled situations.
However, only changing the vertex selections then still doesn't select a face in face mode! If you really can't avoid only working with vertex selections, you can use this call:
void EM_select_flush(void);
Now selection is flushed upward regardless current selectmode. That can be destructive for special cases however, like checkerboard selected faces. So use this only when you know everything else was deselected (or deselect it). Example: adding primitives.
**** Hide flags
EditVert: eve->h
EditEdge: eed->h
EditFace: efa->h
- all hide flags are always up-to-date
- hidden vertices/edges/faces are always deselected. so when you operate on selection only, there's no need to check for hide flag.
**** Unified undo for editmode
New file: editmode_undo.h
A pretty nice function pointer handler style undo. Just code three functions, and your undo will fly! The c file has a good reference.
Also note that the old undo system has been replaced. It currently uses minimal dependencies on Meshes themselves (no abuse of going in/out editmode), and is restricted nicely to editmode functions.
**** Going in/out editmode
As speedup now all vertices/faces/edges are allocated in three big chunks. In vertices/faces/edges now tags are set to denote such data cannot be freed.
ALso the hashtable (lookup) for edges uses no mallocs at all anymore, but is part of the EditEdge itself.
|
|
- made undo/redo display of previewrender nice
|
|
- Made unified API for undo calls, to be found in space.c
BIF_undo_push(char *str)
BIF_undo(void)
BIF_redo(void)
These calls will do all undo levels, including editmode and vpaint.
The transition is work in progress, because mesh undo needs recode.
- New global hotkey CTR+Z for undo
Note: 'shaded draw mode' still is SHIFT+Z, the old CTRL+Z was to recalc
the lighting in shaded mode, which already became much more interactive,
like during/after any transform().
Recalc hotkey now is SHIFT+ALT+Z
CTRL+<any modifier>+Z is redo.
- For OSX users; the Apple-key ("Command") now maps to CTRL as well. This
disables the one-mouse-button hack for rightmouse btw, will be fixed in
next commit. At least we can use Apple-Z :)
- Old Ukey for undo is still there, as a training period... my preference is
to restore Ukey to "reload original data" as in past, and only use new
CTRL+Z for undo.
- Added undo_push() for all of editobject.c and editview.c. Meaning we can
start using/testing global undo in the 3d window. Please dont comment on
missing parts for now, first I want someone to volunteer to tackle all of
that.
- Since the global undo has a full 'file' in memory, it can save extremely
fast on exit to <temp dir>/quit.blend. That's default now when global undo
is enabled. It prints "Saved session recovery to ..." in console then.
- In file menu, a new option is added "Recover Last Session". Note that this
reads the undo-save, which is without UI.
- With such nice new features we then can also kill the disputed
Cancel/Confirm menu on Q-KEY.
- Added fix which initializes seam/normal theme color on saved themes.
They showed black now.... (Note: that's in usiblender.c!)
|
|
1) Curve deform
http://www.blender3d.org/cms/Curve_Deform.392.0.html
Works simple as expected, but keep track of the rotation axis
in F7 buttons (Track X Y Z)
Only Mesh deform supported now.
Code changes:
- centralized deformation calls in curve_modifiers() mesh_modifiers()
etcetera. Here also other effects can be added like wave. Now the
evaluation order is fixed, but should become optional. It also doesnt
use the Displist anymore as deform-input. That latter part is unfinished
yet.
This code also is used for Hooks and will be needed for softbody
- made convention stricter that displists are being checked on in
drawobject(), this to prevent routines to make new displists recursively
(like armature does). Now a freedisplist() is sufficient to signal that
a new displaylist should be made.
2) Object Hooks
http://www.blender3d.org/cms/Object_Hooks.391.0.html
Support for Hooks is added to Mesh, Lattice, Curve and Surface objects.
For Armatures this would require some more work & research.
Main goal for this feature is to provide quick & simple access to the
underlying geometry in Objects on Object level, supporting hierarchies and
Ipos etc.
|
|
1) append in current active layer (off by default)
2) append at 3d cursor (off by default). When more than one object is selected this will first calculate the bounding box of the centers of the objects, and then use the distance of the bounding box center to the 3d cursor to transform all objects.
|
|
|
|
Read today's meeting minutes for a description.
Bjornmose: We'll need some example and screenshots for the dev pages of blender3d.org. If you can do some, neat, if not, I'll do them.
Matt, Emilie and Chris: Please review UI addition. Pixel alignement and all that fun stuff has not be overly looked for (though I did some cleaning by adding alignment blocks).
|
|
|
|
|
|
|
|
- file-to-memory save
- incremental difference steps (compression)
everthing has been tightly coded to use minimum of memcpy or allocs. In
fact this system works with a single full buffer (=file) in memory, and undosteps as differences from it.
Speed gain is factor 4-8 faster. I've added it in CTRL+ALT+T timer menu for
a test. Please note the gain is especially in the undo-storing, not in
retrieving undo.
Also new: file read option to skip UI read (file menu). This now also is
default for the undo system.
|
|
Next to the "BevOb" button you now have a "TaperOb" button to give a name
of a curve object which defines the width of extrusion of the 'BevObj'
along the curve. The TaperOb curve typically is horizontal, where the
height denotes the width.
Important rules;
- Only the firste curve in TaperObj is evaluated
- the first width is left, last width is right
- it scales the width of normal extrusions based on evaluating the taper
curve; which means sharp corners in taper curve won't be easily visible
(That latter feature could be improved by extrusing based on the points
in the taper curve; this is a *lot* more work)
|
|
behaviour, by default it's enabled.
Feature requested by Bastian Salmela.
|
|
get_constraint_target_matrix since that's what it really does
Moved get_con_target from editconstraint to constraint kernel file and renamed to get_constraint_target
Make scene.c use constraint functions from kernel instead of doing the switch itself (regrouping specific constraint code in one file).
Add LockTrack as an option in the Make Track menu (Ctrl-T)
Adding fun for vortex forces in 3D window, the representation now match the orientation and direction of the force (this is code will need optimisation). I'll probably be slapped for mixing two things in one commit but some function calls needed to be fixed for the new spelling and since this is really isolated code I didn't feel like wasting time getting a fresh copy, doing the changes and then readded this after commiting.
Fixed some warning regarding implicit casts and constants (this last one is a MSVCism where you need to explicitely tell the compiler to use floats with an f. AFAIK, it doesn't affect/bother other compilers).
Removed a useless commented piece of code in readfile (there was an uncommented copy a couple of lines before)
|
|
files. (testers; note that you cannot save 2.34 yet!)
|
|
backend variable naming.
|
|
Apparently appending or linking from other files didn't call a proper
do_version() patch to initialize new variables correctly. Was result of
the streamgluing stuff in NaN period... fixed.
|
|
New objects were not created with correct 'ipowin' value, to denote the
default ipo to show. That caused sometimes wrong display with weird empty
menu button in header.
|
|
- now more than 31 channels possible for ipos
- added lotsa new channels all over
- Texture block has ipo now too
- recoded getname_ei functions
(Will ask nathan to give release log info when he's back!)
|
|
Edges in Mesh
- adds automatic when you use creases. For other situations; call the
void make_edges(Mesh *me) in mesh.c. Of course, once in editmode the
edges are automatically recreated.
- in F9 buttons you can add/remove edges too
- both for Mesh and DisplistMesh, so it speeds up drawing quite some in
wireframe
- render for edges can't work... edges have no material nor tface nor col..
so here still the faces are rendered in wire
Creases in Subsurf
- based on the code by Chris McFarlen
- main changes is that now edges are used, saving quite some data in file
- use SHIFT+E in editmode to set edges-sharpness. values go from 0-1
- in F9 buttons you can set draw-crease mode. It draws now blended from
wire color to edge-select color (as provided in Theme)
Known issue: setting sharpness on 1 cube (subdiv 2) gives weird results
with some values... Chris, can you check?
Further; code cleanups, changing 0 in NULL when needed, no warnings, etc etc
|
|
* Cleaned out IPO #defines
|
|
http://www.blender3d.org/cms/Ramp_Shaders.348.0.html
Material color and specular now can be defined by a Colorband. The actual
color then is defined during shading based on:
- shade value (like dotproduct)
- energy value (dot product plus light)
- normal
- result of all shading (useful for adding stuff in the end)
Special request from [A]ndy! :)
|
|
New is that objects can have a force field, and Meshes can even deflect
(collide) particles. This is in a new sub-menu in Object buttons F7
The full instructions where on the web, Leon mailed it me and I will put
it in CMS tomorrow. For those who like to play with it now, here are demo
files:
http://download.blender.org/demo/test/
Quite some changes where in the integration though... so previous created
particle deflectors will not work. Changes to mention now are:
- gravity is renamed to 'force field'
- force field and deflector options are in Object now, not in Mesh
- the options also have its own struct, doesnt add to Object by default
- force fields are possible for all object types, but only work on center.
So empty objects are typical for it.
Work to do:
- add draw method in 3d win to denote forcefield objects
- check on the UI (panel with different size?)
- add 'recalc' button in deflector panel
|
|
|