Commit Graph

8997 Commits

Author SHA1 Message Date
Joshua Leung
f721ce13fb == Action Constraint ==
Now the Action Constraint can be applied to Objects as well as Bones!
2007-10-22 02:43:07 +00:00
Joshua Leung
6422a740c2 == Constraints System - Recode 2 ==
Once again, I've recoded the constraints system. This time, the goals were:
* To make it more future-proof by 'modernising' the coding style. The long functions filled with switch statements, have given way to function-pointers with smaller functions for specific purposes.
* To make it support constraints which use multiple targets more readily that it did. In the past, it was assumed that constraints could only have at most one target.

As a result, a lot of code has been shuffled around, and modified. Also, the subversion number has been bumped up.

Known issues:
* PyConstraints, which were the main motivation for supporting multiple-targets, are currently broken. There are some bimport() error that keeps causing problems. I've also temporarily removed the doDriver support, although it may return in another form soon. 
* Constraints BPy-API is currently has a few features which currently don't work yet
* Outliner currently only displays the names of the constraints instead of the fancy subtarget/target/constraint-name display it used to do. What gets displayed here needs further investigation, as the old way was certainly not that great (and is not compatible with the new system too)
2007-10-21 23:00:29 +00:00
Peter Schlaile
a4e8e87983 == Core ==
Tried to fix renderlayer crash, that was introduced with NTSC-patch
on 64bit platforms.
2007-10-21 20:18:54 +00:00
Peter Schlaile
af03bbe412 == Sequencer ==
Peach request: display last mapped frame in status bar of speed control
effect. (To come: auto-resize based on this information)
2007-10-21 20:05:01 +00:00
Peter Schlaile
477a8c30fa == Core ==
Fixed fixup code in readfile, that makes old files load with
correct FPS.
2007-10-21 19:19:53 +00:00
Campbell Barton
8bcfafa3d9 changed default nan_definitions.mk to use python 2.5 for linux (ai64 default was py 2.2 which probably wont even compile anymore)
pose.c - left a print here
export obj would ask about file overwriting twice.
2007-10-21 17:38:17 +00:00
Campbell Barton
373a1b05be own error, was returning the wrong python error type 2007-10-21 16:48:12 +00:00
Stephen Swaney
2ecc688e76 warning cleanup:
unused var
 return makes integer from pointer without cast
2007-10-21 16:43:21 +00:00
Andrea Weikert
c4218a810c added missing include dir from stampinfo patch to msvc project files and SConscript file. 2007-10-21 16:17:33 +00:00
Campbell Barton
969c3e1cf6 change in the include for stamping (image.c needs to call font drawing) 2007-10-21 15:48:09 +00:00
Peter Schlaile
a0390e5cc3 == Core ==
This adds fractional FPS support to blender and should finally
make NTSC work correctly.

NTSC has an FPS of 30.0/1.001 which is approximately 29.97 FPS.
Therefore, it is not enough to simply make frs_sec a float, since
you can't represent this accurately enough. 
I added a seperate variable frs_sec_base and FPS is now 
frs_sec / frs_sec_base.

I changed all the places, where frs_sec was used to my best knowledge.

For convenience sake, I added several macros, that should make life
easier in the future:

FRA2TIME(a) : convert frame number to a double precision time in seconds
TIME2FRA(a) : the same in the opposite direction
FPS         : return current FPS as a double precision number 
              (last resort)

This closes bug #6715 
Standard framerates not supported / breaks sync -- 23.967 29.967 etc.

https://projects.blender.org/tracker/?func=detail&aid=6715&group_id=9&atid=125

Please give this heavy testing with NTSC files, quicktime in/export
and the python interface.
Errors are most probably only spotted on longer timelines, so that is
also important.

The patch was tested by Troy Sobotka and me, so it most probably should
work out of the box, but wider testing is important, since errors are
very subtle.

Enjoy!
2007-10-21 15:42:08 +00:00
Campbell Barton
bacfc9eb91 fix for crash's in file selector.
- on unix BLI_diskfree was only using 100 chars for the dir name, and 
not checking if the name given was longer, increased to FILE_MAXDIR 
(160) and added a check, return -1 if its too long.

The file selector only allowed 80 chars to be typed into the directory 
entry.

Made the file selector check that the path is less then FILE_MIXDIR, if 
you try and enter a path thats longer it will tell you that the path is 
too long, before it was writing into other memory and crashing.
2007-10-21 09:32:18 +00:00
Campbell Barton
3a04520686 python api, slicing works differently on the 64bit ubuntu gutsy system, compared to the 32bit
install.
face.uv[:] was returning a blank list. and making smart UV projection script fail.

On one system Python is giving the slice function positive values, whereas on the 64bit system its 
passing negative which are then clamped to zero.
made mathutils types accept negative values for slicing. This is very odd because both systems are 
running ubuntu gutsy with python 2.5
2007-10-20 20:24:09 +00:00
Campbell Barton
30479e6912 adding the glalphaclip variable didnt allign on 32 bit linux but worked
in 64bits. added a pad value.
2007-10-20 18:57:40 +00:00
Campbell Barton
960eaed6cd added an option to adjust the alpha clipping value in the oprnGL preferenes. in some cases you might
want to use 0.5 to see through more of the texture. (less halo's with clipmaps), defailt is 0.0 so it 
will only clip 0 alpha.
2007-10-20 18:01:57 +00:00
Campbell Barton
bfbb350040 some mistakes in stamp commit 2007-10-20 16:58:48 +00:00
Campbell Barton
992bd025e7 allocating memory for the time line was still crashing blender (not sure why), added more checks and
I cant get it to crash anymore.
2007-10-20 16:47:07 +00:00
Campbell Barton
46deddcc62 Image Stamping patch by Diego (and peach request)- stamps image info into metadata and optionally
draws into the
frame.

This patch includes some changes I made...   
* use blenders bitmap fonts (rather then own fonts)
* select font size
* user interface layout changes
* Marker as another image stamp option

Also added some new API calls   
BMF_GetFontHeight(font);
BMF_DrawStringBuf(...);  - so we can draw text into an imbuf's image buffer.
get_frame_marker(frame) - get the last marker from the frame.
IMB_rectfill_area(...) - fill in an image buffer with a rectangle area of color.

TODO - draw stamp info in 3d view, at the moment it just displays in the animation.
2007-10-20 16:17:27 +00:00
Juho Vepsalainen
e5a9e0b12a Fix "Remove Doubles" of w menu and a couple of typos:
This commit makes "Remove Doubles" of w menu to work again.
Also renamed "AutoMarge" to "AutoMerge".
Added shortcut of "Select Inverse" to menus and renamed 
"Select/Deselect All" to be consistent with rest of Blender.
2007-10-20 12:16:54 +00:00
Campbell Barton
a4c8783153 made setting the pose_bone.poseMatrix possible, this does not set the matrix directly, only the pose
bones loc/size/rot, when dealing with an armature without constraints this works as expected. it uses 
the same code as Copy Visual Loc/Size/Rot.
2007-10-20 11:28:58 +00:00
Martin Poirier
0014fed54f Cosmetic change for Copy Attributes menu (Ctrl-C).
The "drawtype" options copies all the draw extra (x-ray, wire, ...) too, so I've renamed the menu entry "draw options".
2007-10-19 17:31:57 +00:00
Jens Ole Wund
d407f5ae81 added point to edge collision in case point to face missed
/* special hidden feature! shrink to fit */
if (G.rt > 500){
	scale = (G.rt - 500) / 100.0f;
}
-- shrink a T shirt to fit .. evil grin
-- by the way i did set up the rule 'if any *outer object* hits no *inner* will be regarded' ... pretty poor IMHO .. well but it works
2007-10-18 22:47:55 +00:00
Campbell Barton
5ea45a1385 Mesh edit option 'AutoMerge' - access from the mesh menu, basically runs remove doubles after transform. but only merges
unselected verts into selected verts, so it wont merge verts your not editing.
2007-10-18 21:47:55 +00:00
Campbell Barton
87b9283e1d (own mistake) transform markers wasnt working, bad memory use. 2007-10-18 20:43:39 +00:00
Campbell Barton
27d97b7124 (bad mistake) - didnt read docs and removed lib from Sequence struct 2007-10-18 20:03:12 +00:00
Campbell Barton
5beb232364 adding a sequence would grab the markers, workaround for this. 2007-10-18 19:40:59 +00:00
Campbell Barton
fde4edd1bd Use GL_ALPHA_TEST when drawing alpha faces in the 3d view, as suggested by Eskil, some scenes are unusable without this.
at the moment it wont draw totally transperent pixels, this may need to be adjusted or made into a preference.
2007-10-18 13:51:10 +00:00
Campbell Barton
6576464b03 Sequencer...
snapping to unselecrted strips didnt work (I didnt notice find_neighboring_sequence needed them to be touching, added find_next_prev_sequence to get the next/prev seq)
added select linked (L and Ctrl+L)
added Ctrl +/- select more/less
2007-10-18 12:35:58 +00:00
Matt Ebb
dac77c4749 * Fix for bug # 7396 "Refraction Pass Being added to combined when not told to"
For the record, I think the way these reflection and refraction passes are handled (as a difference against the diffuse pass) is not very useful - especially if you want to do colour corrections, blurring, etc. It would be much more practical for the passes to contain the ray result returned by the raytrace...
2007-10-18 09:18:04 +00:00
Campbell Barton
fce101e831 Sequencer
- snap to strips before and after the active strip,
- Made max handle draw size 40px, instead of 28 (somtimes its hard to 
select handles)
2007-10-18 07:06:01 +00:00
Campbell Barton
1ca2823b54 made sequence handle calculation into a function, (lines were being copied around) 2007-10-17 23:24:09 +00:00
Campbell Barton
abb8771ed3 Sequencer transform snap to marker, works with grab and extend, takes handle selection into account.
this will snap one if 2/4 points to the marker when transforming. the active sequences bounds and the bounds of all selected clips.
2007-10-17 22:31:59 +00:00
Brecht Van Lommel
2f515aaca1 Fix for bug #7331
Texture painting could crash due to missing check for valid imbuf.
2007-10-17 18:33:01 +00:00
Campbell Barton
2639404f34 Sequencer
- Draw a verticle line for markers
- Added an option to transform selected markers in the sequencer - useful for Extending time
2007-10-17 18:32:54 +00:00
Brecht Van Lommel
e844ee5e54 Bugfix:
The roll of a B-Bone relative to a previous regular bone was not matched
correctly.
2007-10-17 17:53:59 +00:00
Campbell Barton
4b6b27ea70 markers in the sequencer
- added a new redraw type - REDRAWMARKER, at the moment this draws the same windows as REDRAWANIM, but this may not always be true, and it is more explicit whats 
happening, This replaced 5 or so draw calls in quite a few places.
2007-10-17 15:27:38 +00:00
Campbell Barton
8bb97b6efa patch 7145 - Copy Select objects by PassIndex, Ctrl+C, Ctrl+G
Sequencer Feature, Split Image Sequence.
Splits a image sequence into strips. useful for importing frames for animatics.
 Also added undo calls in a few places that did not have it.
2007-10-17 11:17:11 +00:00
Campbell Barton
51ca77a114 patch, 7340 from frank richter add glPush/PopClientAttrib 2007-10-17 09:51:13 +00:00
Joshua Leung
919e5baba8 IPO-Transform Bugfix:
Peach/ideasman_42 report... 

After transforming sequence IPO's, there were occasional crashes.
2007-10-17 08:23:08 +00:00
Campbell Barton
5b755bade2 ipo error kept popping up and lock ipo didnt redraw the sequencer view (note, still not realtime, but at least it redraws now) 2007-10-16 18:04:56 +00:00
Campbell Barton
8e3b881181 sequencer,
simple fix for extend (aka ripple editing)
dont operate on metastrips makes them work as expected (since the seq's inside are moved).
2007-10-16 00:10:37 +00:00
Campbell Barton
e9c2aa691e updated pyconstraint template from nathan (cessen) which exposed some
bugs with pyconstraints, also added a missing decref from python (wasnt freeing the return value from the settings 
button).
2007-10-15 15:28:09 +00:00
Campbell Barton
15ad8e7e66 pyconstraints USE_TARGET wasnt being checked for true/false, was assumed True whenever it was assigned in the
script
2007-10-15 14:41:29 +00:00
Campbell Barton
4fa17b2eb4 pyconstraints doTarget function was getting an uninitialized matrix. 2007-10-15 14:19:11 +00:00
Brecht Van Lommel
565316909e Bugfix:
Object constraints with a driven influence ipo were not being evaluated
properly. The code for adding the depsgraph relation and updating without
time changes was simply missing.
2007-10-15 10:36:30 +00:00
Ken Hughes
ff5fd2eb38 Tools
-----
Bugfix #7493:  boolean difference operator was being applied in the wrong
order (difference modifier worked correctly).
2007-10-14 20:58:57 +00:00
Kent Mein
6fe98f19a9 This is patch [#7483] imbuf support for uncompressed DDS images
provided by Amorilia

NVIDIA updated the dds stuff so we get a nice new patch.

Kent
2007-10-12 16:09:59 +00:00
Peter Schlaile
3697e08524 == IMBuf fix ==
Fixed Campbell's patch for IMB_flipx:
- header file declaration is corrected
- reordered loops to make things faster (less cache misses 
  and no tests for float-buffers on a _per pixel basis_!)

(Campbell: it'd be nice, if you could check with me before patching
the sequencer. Or at least pay attention to compiler warnings :) )
2007-10-12 06:37:20 +00:00
Brecht Van Lommel
4f96108137 Fix for error in recent b-bone rest pose commit. 2007-10-10 23:36:58 +00:00
Campbell Barton
4a43099c5a Peach request
new option for the image sequencer's image strips, flip x/y, (useful when making animatics to test the direction characters walk across the screen)
added IMB_flipy was alredy there, needed to add IMB_flipx.
2007-10-10 23:34:40 +00:00