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
path: root/source
AgeCommit message (Collapse)Author
2003-10-23Cleaned up new constraint line drawing while grab/rot/scaleTon Roosendaal
- uses callback mechanism to tell main drawing routine what to do - for that reason it doesn't use frontbuffer drawing anymore and it shows up in all 3d windows as well - it uses the same colors as for the grid axes (I tweaked it a bit, this is based at themecolors, and also should work in different background and grid color) - I disabled drawing lines through every object or every vertex. The current display method is clear and not distracting - when in 'local' transform (double press X/Y/Z), it displays a nice axis in the center of transform for vertices. In object-mode, local transform differs per object, so constraint lines and axes are drawn for each individually... Also: - fixed an old bug in rotate transform(). Using a constraint for rotation (X, Y, Z) didn't work for multiple objects at all!
2003-10-23- fixed drawing of headers... they align now exactly with the 1 pixelTon Roosendaal
black edge between 'area windows'. the new ortho matrix seems to work for me... :)
2003-10-23- changed ortho2 calls by default... according the 'opengl correctness'Ton Roosendaal
chapter in 'opengl programming guide' you have to offset the matrix with 0.375 for exact & predictable cross platform pixel drawing. Blender used 0.5.... Committed for test among platforms... if you see weird drawing results (like polygons not aligning good with lines) just notify me.
2003-10-23- <blush> forgot to delete an old line:Ton Roosendaal
if(R.mat->septex) break; this caused the new per-channel switching only to work with 2 textures!
2003-10-23 Adjusted Layout in texture, texture_plugin, and texture_mapto panels.Robert Wenzlaff
2003-10-23BugFix: do_global_buttons() was split into do_global_buttons() and ↵Robert Wenzlaff
do_global_buttons2(), but do_butspace() still routed events for do_global_buttons2() to do_global_buttons(). This kept a lot of "Single User" buttond from working.
2003-10-23- themed all window types... phew!Ton Roosendaal
BTW: text colors don't work everywhere yet... but this state should be save to store themes in your .B.blend (CTRL+X) and some fixes: - leftmouse click now works in NLA and Action window to select a strip in the left part - faceselect+vpaint mode didnt show both panels
2003-10-23Small constraint loop detection and calculation fix that now allows two ↵Martin Poirier
objects to track each other (normal track or LockTrack). This is done by disabling the object position refresh call when calculating these constraints. From the tests I did, this doesn't cause any problem at all. The main point of this is to create pistons and the like. For coders: the detect_constraint_loop function now takes an additional parameter that determines the constraint type of the object it's looping from.
2003-10-23fixed a warning that slipped by :|Martin Poirier
2003-10-22- material editor: each texture channel can be individually switched,Ton Roosendaal
instead of the old 'septex' which only showed the active one - rendering: the 'stencil' option now works to stencil out normals as well (special requests from our manual master, s68)
2003-10-22- fixed bug: 'header select' themecolor had no alpha, causing antialiasedTon Roosendaal
lines not drawn (triangles in buttons for example) - correct colors for channels in texture buttons - fixed bug: using proportional editing, the extra wire draw had incorrect matrix - fixed bug: drawing in imagewindow didnt work anymore... was a very old one! the wrong pointer was read, and it accidentally went OK, until now - selecting vertices with multiple 3d wins open works again
2003-10-22More fixes in object drawing:Ton Roosendaal
- transparent faces in editmode don't write in zbuffer anymore (prevents drawing errors) but still read (so behind the subsurf faces for example) - improved drawing 'handles' for subsurf editing - going in editmode to Solid view, will draw extra wire always, including transparent faces when set - works in all combos... http://www.blender.org/docs/ton/subsurf.html - fixed error; padplus/padminus didnt work in buttonswindow anymore - improved buttonswin: when dragging window edge, the buttons dont rescale, but stay same size
2003-10-22Added mirror function to the code and to the Wkey menu (at the end)Martin Poirier
2003-10-22Added PADENTER confirmation to transform.Martin Poirier
2003-10-22 - Added PADENTER to knife confirm, to make it more consistantRobert Wenzlaff
with okee() et. al.
2003-10-22 - Preserved selections in undo.Robert Wenzlaff
- Fixed spurious "recalc norm" enties in Undo.
2003-10-22Numerical input in transformation modes (Grab, Rotate, Scale,Martin Poirier
Warp, Shear, Shrink/Fatten). It works with the transformations mode, it doesn't replace them, so just enter grab, scale or rotate mode as usual and start typing. Both numpad and non-numpad works for the numbers. Tab switches between axis (the axis that is being modified has parenthesis) Backspace clears the current axis. Twice clears all axis. Minus (-) switches between positive and negative value. The mouse is now disabled when you type (as soon as you use one of the numerical keys). You can use Nkey to switch between numerical and mouse driven mode. The minus key on the numpad still affects the PET in mouse-driven mode, but affects the sign of the number in numerical input.
2003-10-22- fixed error; the vertices didnt draw anymore in editmode with sold draw.Ton Roosendaal
was caused because i only tested the new cool 'draw wire extra'. :) - by default, in solid draw mode & editmode, it does a 'draw wire extra' now, giving nice clean editmesh drawing. - there's still a few quirks, i do a test now... this commit is to have a good working blender in cvs. the whole drawing system is such chaos...
2003-10-21A few bugfixes to the vgrouping methodsJoseph Gilbert
2003-10-21Axis constraint in transform for grab modeMartin Poirier
Axis constraint in size mode note: the original behavior when constraining with middle mouse in object mode is weird. I've leave it that way, but I think it would be a good time to fix it. Another thing: in object mode, you can only constrain size to local axis. Global axis would involve either screwing the matrix (which stinks) or modifying the vert coords directly (which is a no no) Please also note that this breaks the mirroring combo. I'll be commiting my edit mode mirror function soon to fix that. Coder note: You can now call the transform function with an additional parameter to constraint to an axis. example: transform('g'*'X') transform('s'*'y') transform('r'*'z') Capital axis letter for global axis, lower case for local axis
2003-10-21fixed warnings and errors in buttons_object.cMartin Poirier
2003-10-21Mesh drawing stuff!Ton Roosendaal
- in zbuffer mode, vertices will be blended 50% in... and when you increase vertex size larger than 2 pixels, it will draw them smaller - removed all 'wire extra' calls (there were dozens!) and replaced it with simple call where it belongs. This drawing mode is becoming nice & stable... maybe something to make default on for new objects? Makes selecting quite easier... - Subsurf: in editmode, with new 'Optimal' option set, the mesh itself will not draw, but instead it draws 'handles' to the vertices. Looks extremely clean! - matched drawing of default grid-floor (persp) to ortho grid - killed drawing vertices outside of main drawing loop, apart from the routine that uses mouse-selecting. (tekenvertices_ext()). It was an old optimize routine which became quite useless.
2003-10-21Helpline drawing in transform (semi broken in this commit)Martin Poirier
This is only usefull for rotate now, but the axis constraining code has a part that depended on this, so I commit this part first. For coders: void constline(float *center, float *dir, int col) Draw an infinite line on the screen. col is the color argument. It must be cpack compatible void project_short_infiniteline(float *vec, float *dir, short *adr1, short *adr2); clips infinite line to screen border
2003-10-21For coders:Martin Poirier
Axis CONST and variable rename in transform in preparation of further commits Parsing code to supply axis constraint with the mode (Broken knows what I'm talking about)
2003-10-21Constraint stuff from tuhopuu including (but probably not limited too):Martin Poirier
Axis options for TrackTo LockTrack FollowPath Auto creation of TrackTo constraint from Ctrl-T (old track still an option) Auto creation of FollowPath when parenting to path (Normal parent still an option) Backward compatibility stuff to convert the per object axis settings to per constraint when a Track constraint is present. Function to convert old track to constraint (commented out) Revamped the constraints interface with Matt's work from tuhopuu and the stuff we were discussing earlier. -------------------- For coders: unique_constraint_name and *new_constraint_data moved to the kernel (constraint.c) new Projf function in arithb gives the projection of a vector on another vector add_new_constraint now takes a constraint type (int) parameter add_constraint_to_object(bConstraint *con, Object *ob) to link a constraint to an object add_constraint_to_client(bConstraint *con) to link constraint to current client (object or bone) add_influence_key_to_constraint (bConstraint *con) to (eventually) add a keyframe to the influence IPO of a constraint
2003-10-21fixed bugs:Ton Roosendaal
- faceselect mode works again - selecting vertices for lattices, surfaces and curves works again - in previewrender sometimes a square was drawn, which was texture-crop
2003-10-21- forgot to set 'minimal theme' callback for sliders, causing a crash whenTon Roosendaal
displaying Constraint Panel in F7 menu.
2003-10-21- another formula for 'draw wire extra'. this time it doen't scale, butTon Roosendaal
only moves z-values in drawing in zbuffer. still matrix art I don't fully grasp... but it seems to work!
2003-10-21Made pupmenu() separators consistent with pulldownsMatt Ebb
TODO: same for popup menu buttons
2003-10-21Added a function to shade alpha as well as colourMatt Ebb
2003-10-21- Lots of tweaks to interface colours, shading, etc.Matt Ebb
- Fixed alignment/width of menus Still needs more work.
2003-10-21- fixed drawmode 'wire extra'.Ton Roosendaal
it was using some unsupported linewidth trick... I've been trying to get the official glPolygonOffset to working, but my silly Mac doesnt support it, it seems. So! I thought of another trick, and that's just moving the window matrix a little to the front. :) - for those interested; the code for glPolygonOffset is still there, commented out. (drawobject.c) - btw: the drawobject.c routines are a TOTAL mess!
2003-10-21- added new drawing type for subsurf editing. Is called 'Optimal' andTon Roosendaal
can be found under the 'SubSurf' button. Optimal drawing only shows the subdivided original edges. Quite nice! And; it's a load faster! - to evaluate: do we want this in editmode too?
2003-10-21added sequence editor pull-down menus.Simon Clitherow
TODO: fix "Enter/Exit Meta Strip" to work correctly for nested meta strips.
2003-10-20Exppython: small changes in NMesh internals and docsWillian Padovani Germano
2003-10-20- fixed correct themecolor for popup menusTon Roosendaal
2003-10-20- made a template function for editmesh enthusiasts.Ton Roosendaal
- goes in a loop, - draws current window - sets view transform to correct matrix - you can draw stuff - swapbuffers - event queue test to escape Test: CTRL+R in editmode. Right now it hilites the closest edge to to mouse cursor, just for fun! Goofster will use it for the loop-cutter tool later. But the template will remain there, commented out, for others to play with.
2003-10-20Another mega commit... loadsof restructure, and a pretty good one! :)Ton Roosendaal
- changed the BIF_DrawString() function. it used to work different for AA fonts as for default fonts. Now it's identical. Setting color for fonts can just be done with OpenGL, for both font types. Removed: BIF_DrawStringRGB() - added theme color options for Buttons - recoded DefButton, so it automatically chooses the right color. - had to remove a 1000 uiBlockSetCol() calls for that reason... - uiBlockSetCol() still works, to override automatic color - removed entirely the silly old color system (BIFColorID). All color calls can now be done with a BIF_ThemeColor() call, including fonts and buttons and opengl stuff - all buttons in button header have headercolor by default - recoded drawing icons, it was a really bad & old loop doing manually colorshading and blending... which was per pixel a load of code! Now it uses a single OpenGL call to blend or colorize. Quite faster! - (as test, for review) icons don't colorize anymore with button color, but have a different alpha to blend in (when not active) - recoded the entire interface_draw.c file...: - drawing buttons is separated in three parts: 1. main drawing function for text and icons 2. free definable callback for button itself 3. free definable callback for slider - removed a load of redundant code for this! - coded a minimal theme, and adjusted Matt's buttons to match new callback system - adding new drawing themes is piece of cake now - for coders, default 'themes' to be aware of: UI_EMBOSS : the themable drawing style UI_EMBOSSP: the pulldown menu system (apart from color not themable) UI_EMBOSSN: draw nothing, only text and/or icon UI_EMBOSSM: minimal theme, still in use for Logic and Constraintsa this can be set with uiBlockSetEmboss(block) or in the uiNewBlock() call. TODO: make UI API call for button alignment (plus removed another series of warnings from code...) Plus: fixed bug in Matts commit: he used a 'short' button for an 'int'
2003-10-20- Added nicer, smoother tooltip drawingMatt Ebb
2003-10-20- Cleaned, compacted the 3D View headerMatt Ebb
- Cleaned, compacted and slightly re-arranged 3D View edit menus - Added Undo and Knife Subdivide to 3D View menus - Added undo_push_mesh to a couple of menu entries to make them work properly with undo
2003-10-20AddedMatt Ebb
void selectall_type(short obtype); void selectall_layer(int layernum);
2003-10-20Object selection from tuhopuu2:Matt Ebb
Select All by Type / Select All by Layer User info: Found in (object mode) 3D View header menu > Select > Select All by Type selects all objects on visible layers of a certain type Select All by Layer selects all objects on a certain layer (visible / invisible) These used together are useful for managing a complex scene, for example quickly selecting all the lamps and moving them to a separate layer, or selecting the contents of a layer without having to disrupt the view configuration of visible/invisible layers. Coder Info: Added two functions in editview.c void selectall_type(short obtype); void selectall_layer(int layernum); I committed both of these together since the code/changes are both very similar.
2003-10-20Knifetool bugfix:Robert Wenzlaff
The call to headerprint left GL environment in wrong state to draw knife line in all but top view. Moved persp() call to after headerprint().
2003-10-20Dynamic Face/Vert/Halo/Lamp tables:Robert Wenzlaff
User Info: Hard coded limits on the total number of face, verts, halos, and lamps is gone. Blender now allocates the tables for these on an as needed basis. As long as your system can come up with the memory, you won't run out. As a bonus, it also uses slightly less memory on smaller scenes. Coder info: This has been in tuhopuu for a while, but I don't know how hard it has been tested. Since it now allocates only an initial 1024 tables (of 256 verts/faces/halos each), it seems like it has been put through it's paces. Lamps are allocated one at a time, and I start with 256. I rendered 2.5M Faces/Verts/Halos. 4444 lamps. None the less, I left a few printf's in the realocation to hunt bugs. I'll take them out just before the release freeze. Also, be on the lookout for other "sanity checks" that assume a limited number of the above items. I think I got them all, but you never know.
2003-10-20Unified renderer OSA sample clipping:Robert Wenzlaff
User info: This change limits the contribution of any OSA sample to 1.0 per color in the Unified renderer. Because color=1.0 gives fully saturated color, samples contributing more than 1.0 were overweighted in the OSA average causing aliasing (sometimes quite severe). Samples can contribute more than 1.0 because a material's spec and refl values are not normalized (In real world spec+refl <= 1.0). This solves a large class of aliasing problems in the unified renderer. Coder Info: None.
2003-10-20Editmesh Undo:Robert Wenzlaff
User Info: Pressing UKey in mesh edit mode now undoes only last step. Undo can save upto 64 steps of undo info. This is configurable under User Prefs-> Edit Methods. The default is 32. High numbers of undo steps use a lot of memory, since each step stores a copy of the mesh. Shift-U redoes the last undone step (Undoes the undo.) Alt-U brings up a menu of possible steps that can be undone. Selecting an item on the list undoes that item plus all items before it on the list. The top selection "Undo All" is identical to the old Ukey. It undoes all editing since entering Editmode, even if all regular undo steps are used up. Undo info is only saved for one object at a time. You can leave and re- enter editmode for the same object, and all undo steps for that object are preserved. Undo info for an object is lost once a different object is edited. Coder Info: In order for undo to work, a checkpoint save has to be made. This is done with a call to undo_push_mesh("name of step"). This should be done after the last quick abort for a function (typ. the "if (G.obedit==0) return;", or similar). the undo_push_mesh() does alter some flags, so don't try to be too tricky and call undo_push_mesh() too late. The step name is what shows up in the undo_menu. The name "U" is reserved.
2003-10-19Adding Knife tool as to be released in 2.3Robert Wenzlaff
User Info: To use this tool, select a group of verts, it can be larger than the desired cut as explained below. Then hit Shift-K. The tool will prompt for cut type (Exact line or Edge centers), Select, then use LMB to draw a "cut-line". Holding down LMB causes a freehand draw, clicking LMB causes a polyline draw. MMB locks the axis. When done press enter to divide mesh on cut line. Subdivide routines have been modified to produce fewer triangles as part of this tool. Edge Centers preserves UV info, Exact Line does not (it will be there, just slightly distorted). Since the cut line exists in 2D space, and does not make a persistant selection that can be modified in another 3D view, the knife selection is the AND of the vertex selection and the knife line, ie; the edge will be subdivided only if both verts are selected, and the knife line crosses the edge. Select your verts first, but you don't have to be overly precise. If you want to cut a few faces on the front of a sphere, you can select the whole front of the sphere, then knife the faces you want. Coder Info: KnifeSubdivide is called with 1 of 3 modes. KNIFE_PROMPT, KNIFE_EXACT, KNIFE_MIDPOINTS. The hotkey calls KNIFE_PROMPT. When adding to a menu or button, explicitly call out the mode. Part of the tool provides get_mouse_trail() that returns a CutCurve struct that defines a knife line. There are modes defined, but currently they are not implimented. Another part of this tool defines new behaviour for subdivideflag(). Setting beauty param to B_KNIFE tells subdivideflag() that the edges are preselected ans to skip the vert check. Also setting B_PERCENTSUB tells subdivideflag() to divide the edge at a percentage of the distance from eed->v1 to eed->v2. This percentage is passed in the eed->f1 flag as a short (ie, setting eed->f1 to 16384 cuts the edge half-way).
2003-10-19included "BLI_arithb.h" for normal calculations...Joseph Gilbert
2003-10-19- fix to prevent the following-mouse frame number displayMatt Ebb
from disappearing when mouse pointer is moved above the window space edge
2003-10-19- simplified Theme API. No need to include 'current active area' anymore.Ton Roosendaal
like: BIF_ThemeColor(TH_GRID); will be sufficient. Blender does the rest. - fixed bug in CTRL-X (reload home file) with themes - fixed bug in horizontal alignment of different height panels. Seems also to solve the drawing error with constraints...