Commit Graph

645 Commits

Author SHA1 Message Date
4ced91da47 svn merge ^/trunk/blender -r42778:42839 2011-12-23 08:41:53 +00:00
f9cf67a5f3 remove commented index drawing code (now its a debug option), and remove code in editmesh stat drawing which was left over from when text drawing was immediate rather then cached. 2011-12-22 05:52:31 +00:00
4537061e55 patch [#29673] Visualize Indices (developer aid)
by Howard Trickey (howardt)
2011-12-22 05:39:23 +00:00
921b2ee2d4 Merging r42723 through r42769 from trunk into soc-2011-tomato 2011-12-20 17:24:20 +00:00
57ed2fd1c1 svn merge ^/trunk/blender -r42757:42759 2011-12-20 10:59:56 +00:00
2f9925f913 Get rid of hardcoded structure definition in DM drawing callbacks
Structures passing to DM callbacks as userData used to be defined in both callee
and callbacks itself which made it difficult and unsafe to add new properties
to user data.

Added typedefs for this structures and use them in callbacks and callee functions.
2011-12-20 08:47:36 +00:00
737648a0bf Merging r42648 through r42722 from trunk into soc-2011-tomato 2011-12-19 10:39:40 +00:00
db6cb30941 svn merge ^/trunk/blender -r42669:42670 2011-12-16 23:50:55 +00:00
3311164b24 Math lib: matrix multiplication order fix for two functions that were
inconsistent with similar functions & math notation:

mul_m4_m4m4(R, B, A) => mult_m4_m4m4(R, A, B)
mul_m3_m3m4(R, B, A) => mult_m3_m3m4(R, A, B)

For branch maintainers, it should be relatively simple to fix things manually,
it's also possible run this script after merging to do automatic replacement:
http://www.pasteall.org/27459/python
2011-12-16 19:53:12 +00:00
8a9d901c81 Camera tracking: add camera to follow track and object solver constraint
Object used to be parented to active camera which isn't very convenient when
working with witness cameras.

Now parent camera can be specified in constraint (if it's not specified, active camera is used)
2011-12-15 20:38:23 +00:00
e534af906a Object tracking: various fixes and improvements
- Bundles selection is now available for object's bundles
- If bundles selection wasn't changed in 3D viewport, fallback to regular
  object selection, so objects behind bundles can be selected
- Snap cursor to selection now respects object's bundle selection
- Object and rack name now can be selected from list in constraint settings
- Added preset for tracks used for object tracking
2011-12-15 16:10:49 +00:00
53f37cd1ed Object tracking fixes:
- Do not draw bundles for object for opengl selection
- Display reconstruction info for active object in cache line and graph editor
2011-12-15 16:10:13 +00:00
ba16e7d631 Object tracking: object with object solver constraint is now parented to scene's camera
Made Object Solver operator parent object to scene's camera. Behavior is pretty much
familiar to Child Of constraint -- it stores inverted transformation matrix which gives
constant offset in parent's space.
Current files would open incorrect, to make object aligned well again, just press
"Set Inverse" button in Object Solver constraint.
Fixed orientation operators so now they should work in all cases.
Also changed behavior of Set Origin operator which now sets origin to the median
point of all selected tracks/
2011-12-15 16:09:57 +00:00
b865c0314f Merging r42533 through r42601 from trunk into soc-2011-tomato 2011-12-13 11:58:59 +00:00
30d129593b non functional changes & de-duplicate yet another face center function 2011-12-12 23:58:05 +00:00
65f3b93f14 svn merge ^/trunk/blender -r42521:42550 2011-12-10 05:38:00 +00:00
9d807eb6dd Mesh drawing optimization and fixes:
- Pass MFace, MTface and OrigIndex arrays via userData to compareDrawParams callback
  rather than looking up for this layers for each face
- This allowed to avoid massing DM to compare callback which seems like a bad-level pass
- Fixed crashes on some video cards when assigning different materials to different
  faces in edit mode. Both of intel and nvidia cards in my laptop were affected by
  this error
2011-12-09 11:46:48 +00:00
3717a4a9e1 Merging r42482 through r42532 from trunk into soc-2011-tomato 2011-12-09 10:02:01 +00:00
980e68175b svn merge ^/trunk/blender -r42495:42516 2011-12-08 17:32:37 +00:00
a5fb261016 Fix #29520: issue drawing with VBO + GLSL + alpha pass. Includes some refactoring
to hopefully make alpha material drawing code more clear.
2011-12-07 22:03:49 +00:00
35e80c5544 svn merge ^/trunk/blender -r42439:42466 2011-12-06 18:50:45 +00:00
6ac2bb8b94 Merging r42442 through r42457 from trunk into soc-2011-tomato 2011-12-06 09:27:18 +00:00
b44c82b4fd remove invalid NULL checks from own recent commit and minor pep8 edits. 2011-12-05 22:19:30 +00:00
9355cc5c39 Object tracking; initial commit
This commit implements basis stuff needed for object tracking,
use case isn't perfect now, interface also should be cleaned a bit.

- Added list of objects to be tracked. Default there's only one object called
  "Camera" which is used for solving camera motion. Other objects can be added
  and each of them will have it;s own list of tracks. Only one object can be used
  for camera solving at this moment.
- Added new constraint called "Object Tracking" which makes oriented object be
  moving in the save way as solved object motion.
- Scene orientation tools can be used for orienting object to bundles.
- All tools which works with list of tracks or reconstruction data now
  gets that lists from active editing object.
- All objects and their tracking data are available via python api.
2011-12-05 18:57:17 +00:00
f07df7287e manual sync with trunk - pulling in changes where the issues are not bmesh spesific
- some merges added lines in multiple times
- removed some NULL checks that were only in bmesh
- enable cycles by default (was disabled because it used not to work)
- make formatting match
2011-12-04 23:13:28 +00:00
eb233d9332 syncing some minor formatting edits from bmesh branch. 2011-12-04 23:04:43 +00:00
70ee572804 svn merge ^/trunk/blender -r42361:42372 2011-12-03 21:01:26 +00:00
03b807e7dc shorten very long lines in drawobject.c, (no functional changes) 2011-12-03 20:49:41 +00:00
f0b3ec33f6 fix for weight paint mode drawing selected verts even when it wasnt the active object. 2011-12-03 20:26:53 +00:00
15ad39e684 svn merge ^/trunk/blender -r42303:42329 2011-12-02 01:01:07 +00:00
b5332f293e Fixed issue with multiple textures and editmode when VBOs are enabled 2011-12-01 18:26:57 +00:00
c21f19374b Fixed crash caused by recent VBO's changes
Crash was caused by non-initialized original index passing to compareDrawOptions
callback. Due to in some cases it's enough to know indices of faces in final DM
(like for comparing if the same texture used for mesh drawing) assume this
callback receives index in final DM and if it's needed it will make conversion
to original index itself.

This should help reaching extra speed if textured object is affected by
bevel modifiers, i.e.
2011-12-01 18:26:48 +00:00
f6f7e270e3 Slight refactor of VBO code to deal with multiple textures.
Added compareDrawSettings callback to driver mesh's callbacks which are
drawing textured faces (mapped and not mapped). This new callback checks
if two faces are drawing with the same settings (testures, shading etc)
and if they not, flush of faces happens into ogl using glDrawArrays and
next face would be drawn with it's own settings.

Currently implemented compareDrawSettings is used to resolve issue from
bug report only, probably there are extra places where this callback is
needed, but haven't seen configuration where current logic will fail,
so it should be ok.

Also reordered arguments passing to drawMappedFaces DM's callbacks,
so now all drawing callback are accepting list of callbacks and then
userData, instead of using mixed order of callbacks and userData which
was a bit confusing to work with.

This commit fixes:
- #26410: VBO & multitexture doesnt work
- #29464: VBO enabled causes UV coruption
2011-12-01 12:12:39 +00:00
eb46f6bf0d More DM func renames, this one includes renames of the function pointer members of the DerivedMesh struct 2011-11-29 13:01:51 +00:00
4e86b48cbd Rename DM *_face_* funcs to be either *_tessface_* or *_poly_* to avoid confusion
This is the first step in a few changes to cleanup confusing/missing DM funcs
2011-11-29 05:09:54 +00:00
f2551ff799 - add BM_NGON_STACK_SIZE define to use wherever ngon stack arrays are used.
- renamed BM_Compute_Face_Center() to BM_Compute_Face_CenterBounds() and added BM_Compute_Face_CenterMean() since there was code inline to find the mean center in transform.
2011-11-29 04:11:17 +00:00
063dd4f60a svn merge ^/trunk/blender -r42197:42221 2011-11-28 17:09:13 +00:00
c126bfba82 view3d - replace magic numbers with an enum to be used with mesh_foreachScreenVert, mesh_foreachScreenEdge since it wasnt clear how the values are used.
also resolved use of un-initialized variable.
2011-11-28 16:44:17 +00:00
9c156c550f Fix #29434: Cone collision bounds is on the wrong axis
Because of strange reason, cone boundbox was rotated and it wasn't
reflecting physics engine which used "correct" cone boundbox.

Changed displaying of cone bounding box type.
2011-11-28 16:25:42 +00:00
3b5bcab09c svn merge ^/trunk/blender -r42139:42172 2011-11-26 16:29:14 +00:00
8ab167d33d pass args as vectors to opengl functions where possible. 2011-11-26 05:10:53 +00:00
af7288c407 minor edit - weight_to_rgb() and ramp_blend() now take a float vector rather than 3 float pointers.
also make particle draw use a float vec.
2011-11-26 03:13:54 +00:00
951c1798ab Do not use transparent rendering in 3d viewport for objects which are in edit mode
Transparent rendering can't be implemented in way it gives accurate shading in
3d viewport. It's acceptable for object mode, but when you're in edit mode
it gives more problems than benefits of seeing transparent faces.

This is possible fix for for weird polygons in [#29255] Object invisible and weird polygons appearance
2011-11-25 12:55:42 +00:00
ddf934dedf use enum for draw wire setting to be easier to read, no functional change. 2011-11-25 02:35:23 +00:00
f9e00b5c99 svn merge ^/trunk/blender -r42009:42053 2011-11-22 11:51:42 +00:00
Lukas Toenne
d4f27b7bf0 Yet another fix for crashes when drawing empty base mesh with constructive modifier. This crashed with ocean modifier (#29241). The previous fix was to avoid drawing mapped faces altogether for empty edit mesh, but that also disables the actual derived mesh display (#29346).
The real reason for this crash is that ocean modifier (in generative setting) does not properly set the derived mesh face ORIGINDEX data to ORIGINDEX_NONE. With this the previous fixes are not necessary.
2011-11-21 11:46:05 +00:00
3c8d86e117 svn merge ^/trunk/blender -r41961:41998 2011-11-20 01:14:33 +00:00
539c94a051 Camera: some code refactoring, use an intermediate CameraParams struct instead
of long list of variables everywhere. Intention is to also let 3d view use this
eventually, instead of duplicating code.
2011-11-18 15:52:00 +00:00
e6e265b2b5 svn merge -r41779:41847 ^/trunk/blender 2011-11-15 02:58:06 +00:00
e59ab6486f svn merge -r41751:41779 ^/trunk/blender 2011-11-15 02:05:32 +00:00