Commit Graph

655 Commits

Author SHA1 Message Date
7508540c53 svn merge -r41575:41602 ^/trunk/blender 2011-11-07 07:01:24 +00:00
d8717d2628 more macro --> bli math lib replacements. 2011-11-06 15:39:20 +00:00
46ae692710 Merge with trunk r41342 2011-10-28 17:00:53 +00:00
dbe1c4277a Fix "[#29036] Crash on solidify" and a few misc subsurf and derived mesh bugs that were blocking correct functionality of "apply modifier to editcage" when you have a subsurf + solidify modifier on the stack 2011-10-27 12:17:02 +00:00
15e6d6cd75 svn merge ^/trunk/blender -r41226:41227 . 2011-10-24 12:43:08 +00:00
ad1d3dd30f svn merge ^/trunk/blender -r41175:41200 --- will need to apply fix after 2011-10-24 07:56:42 +00:00
4a04f72069 remove $Id: tags after discussion on the mailign list: http://markmail.org/message/fp7ozcywxum3ar7n 2011-10-23 17:52:20 +00:00
d4541fd891 Merge with trunk r41197 2011-10-22 16:43:23 +00:00
74017cb020 header cleanup and typo's 2011-10-22 01:53:35 +00:00
4e118bb22f svn merge ^/trunk/blender -r40890:40950 2011-10-14 01:35:20 +00:00
7eadd540d4 svn merge ^/trunk/blender -r40872:40890 2011-10-13 22:50:01 +00:00
8be3249537 Merge with trunk r40991 2011-10-13 21:43:02 +00:00
fa5275cdfa - bpy.path.abspath(), added optional library argument since any paths from linked datablocks are relative to this, not the blend files path, this saves kludgy path code wherever libraries may be used.
- Image "Edit Externally" operator can now edit relative library images.

also minor edits to navmesh.
2011-10-11 04:09:11 +00:00
2de1bd7dc5 updates to navmesh
- 2 new navmesh operators, reset and clear navmesh data.
- rename operators to be more consistent with existing names.
- some minor edits to draw function, was getting the custom data for every index when it already had the array.
2011-10-10 07:21:42 +00:00
f0cd9f987d - for some reason navmesh wasnt drawing when VBO was enabled.
- fix navmesh crash (may well have been from own changes)
- changing VBO's now redraws all windows - useful for checking if VBO draws differently.
2011-10-10 02:56:26 +00:00
39c4e3ae3c fix for editmode opengl drawing (bug from own recent optimization), need to set glShadeModel() outside glBegin(GL_QUADS / GL_TRIANGLES). 2011-10-09 23:04:31 +00:00
17b66b46ad fix crash for recent navmesh edits when setting a non-mesh object to a navmesh.
also minor cleanup.
2011-10-09 21:43:13 +00:00
7306eb84f0 move NavMesh draw code out of being a modifier and into DerivedMesh drawing hack (which IMHO is less bad then mis-using a modifier only to override drawing calls). 2011-10-09 21:11:51 +00:00
e8bb972f3c Merge with trunk r40782 2011-10-04 11:42:44 +00:00
1f12740a82 make error prints more helpful & correct some comments for rip code. 2011-09-24 12:13:13 +00:00
4779b162ac fix for missing memfree with raddish merge, copy over changes from trunk for switching mode - Ctrl+Tab wasnt setting weight paint. 2011-09-24 11:42:11 +00:00
a189b71a28 some speedup for drawing mesh in texture mode.
- only pass if the mesh has vertex colors to drawParams() rather then the mcol its self, this saves a lookup on the color.
- drawing textures in editmode with no vertex colors would still lookup vertex colors on each face, instead cache this info for all faces.
2011-09-23 18:29:45 +00:00
f6510be5ac Fix a trunk->bmesh MSVC build break 2011-09-23 15:30:34 +00:00
d7a5429f42 svn merge ^/trunk/blender -r40491:40498 2011-09-23 13:55:06 +00:00
5bd83eede0 svn merge ^/trunk/blender -r40405:40431 2011-09-23 11:30:55 +00:00
7126a4699e svn merge ^/trunk/blender -r40367:40368 --- raddish weight paint merge 2011-09-22 16:09:27 +00:00
15cb47bf91 Merge with trunk r40409 2011-09-20 17:51:04 +00:00
8cf8fd7326 - translation scripts now run with py3.x
- added convenience make target 'make translations'
- some MEM_malloc strings were not unique enough, expanded them.
2011-09-20 17:07:33 +00:00
84d06f252e tag & comment unused vars with /* UNUSED */ 2011-09-20 08:48:48 +00:00
79c19590e9 fix for bug in do_version_tface(), was assigning 'tf->mode' before tf was defined, also comment unused var. 2011-09-20 04:54:13 +00:00
Dalai Felinto
b263aefb0e TexFace to Material Settings big patch
Summary:
========
The idea here is to move the texface options into the material panel.
For images with the change please visit:
http://code.blender.org/index.php/2011/09/bge-material-texface-changes

1 - Some of the legacy problems 2.49 and 2.5x has with the texface system:
==========================================================================
1.1) Shadow, Bilboard and Halo are mutual exclusive (in the code), yet you can
select a face to be more than one mode.
1.2) Sort only works for blend Alpha yet it's an option regardless of the
Transparency Blend you pick.
1.3) Shared doesn't affect anything in BGE.
1.4) ObColor only works for Text objects (old bitmap texts) when using Texture
Face Materials. (not address yet, I so far ignored obcolor)

2 - Notes:
============
2.1) Now "Use Face Textures" in material Option panel will work in Multitexture
even if there is no texture channel.

2.2) In FaceTexture mode it will use TexFace all the time, even if you don't
check the "Use Texture Face" option in the UI. It's a matter of decision, since
the code for either way is there. I decided by the solution that makes the
creation of a material fast - in this mode the user doesn't need to mess with
textures or this "Use Texture Face" option at all. I'm not strong in my opinion
here. But I think if we don't have this then what is the point of the Texture
Face mode?

2.3) I kept references for tface only when we need the image, UV or the tiling
setting. It should help later when/if we split the Image and UV layers from the
tface struct  (Campbell and Brecht proposal).

3 - Changes in a Nutshell:
==========================
3.1) "Texture Face" panel (in the Mesh/Object Data panel) no longer exists. Those settings are all part of the material properties, visible when Game Render is set.

3.2) "Texture Face" Shading mode (in the Render panel) is now called “Single Texture”, it needs a material for special settings (e.g. Billboard, Alpha Sort, …).

3.3) New options in the Material Panel
* Shadeless option in the Material panel is now supported for all three Shading modes.
* Physics is now toggleable, this is the old Collision option.
* Two Side (on) is now called Back Culling (off).
* Alpha Sort is one of the Alpha options, together (and mutually exclusive) to Alpha Blend, Alpha Clip, Add and Opaque (i.e. solid).
* Shadow, Billboard and Halo are grouped in the “Face Orientation” property.
* "Face Textures" and "Face Textures Alpha" (under Options) can be used for all but GLSL shading mode (to be supported in GLSL eventually).
* The backend in the game engine is still the same as before. The only changes are in the interface and in the way you need to think your materials. The bottomline is: It’s no longer possible to share materials between faces that do not share the same game properties.

4 - Acknowledgment:
==================
Mike Pan for the design discussions, and testing along the whole development process.
Vitor Balbio for the first hands-on code with the interface changes. That helped me a lot to push me into work on that.
Benoit Bolsee and Brecht van Lommel for patch review (* no one reviewed the whole patch, or the latest iteractions, so I still hold liability for any problems).
Blender artists that gave feedback and helped testing the patch.

Patch review and original documentation can be found here:
http://wiki.blender.org/index.php/User:Dfelinto/TexFace
http://codereview.appspot.com/4289041/
2011-09-19 19:55:59 +00:00
a89b253aa6 edits to radish before merge with trunk
- removed some unused functions.
- renamed vars to make more sense paint_vertex.c 'flags' --> 'lock_flags'
- some odd modifications were made in unrealted, commented code, copy these back from trunk.
- rename vertex_group_fix 'cp' property to 'accuracy'
- make style more consistant with trunk.
- remove 'Radish' comments.
2011-09-19 02:43:03 +00:00
73863a1da5 Split do_weight_paint_vertex() to isolate the simple case.
Added a tool-tip to the "fix deforms" op.

Removed code markers:
"Radish"
2011-09-18 17:10:28 +00:00
a9c99f58f4 Changed the branch code markers to say "Radish" in response to a review.
They weren't & aren't meant to show ownership, they just help me navigate my related code.
2011-09-18 03:49:00 +00:00
1b5d16f1bf I made multitude of fixes based on the comments provided online:
Removed the drawSelectedVerts and added drawSelectedVertices, which uses dm->foreachMappedVert.

In calc_weightpaint_vert_color():
Made the weight paint color black and return instead of input=-1

Made the pose bone selection normal when multi-paint is inactive.

Name fix for functions using mv instead of mvert.

Used vector functions provided by the math lib.

Changed some MEM_callocN references to be stacks.

Changed dm_deform_clear to use ob->derivedDeform primarily

Made the variable "float **changes" into "float (*changes)[2]"

Used CTX_data_active_object() in place of CTX_data_pointer_get_type()

Added the invert selection hotkey "Ctrl+I" to weight paint's vertex mask.
2011-09-18 01:09:18 +00:00
1ff373ef5b svn merge -r40166:40279 ^/trunk/blender 2011-09-17 04:59:14 +00:00
718f78d548 remove count_selected_defgroups() function and make get_selected_defgroups() return the total selected items.
also some variable renameing, no functional changes.
2011-09-14 05:56:25 +00:00
98961c9f19 initial cleanup for weight paint branch
- move get_selected_defgroups & count_selected_defgroups into blenkernel
- split calc_weightpaint_vert_color() logic so its more obvious whats default and multipaint behavior
2011-09-14 02:04:26 +00:00
ac51152ec5 svn merge -r40179:40195 https://svn.blender.org/svnroot/bf-blender/trunk/blender 2011-09-14 01:32:59 +00:00
1741269d30 resolve bad level calls from blenkenel/ into editors/ & remove editors from the include path from CMake & SCons.
* ED_curve_editnurbs --> curve_editnurbs
* ED_sculpt_modifiers_changed --> object_sculpt_modifiers_changed
2011-09-14 00:37:27 +00:00
7d02e66256 svn merge -r40000:40179 https://svn.blender.org/svnroot/bf-blender/trunk/blender 2011-09-13 10:05:30 +00:00
b310a76a1b svn merge -r39558:39800 https://svn.blender.org/svnroot/bf-blender/trunk/blender 2011-09-13 06:39:17 +00:00
fddc655aec svn merge -r40140:r40148 https://svn.blender.org/svnroot/bf-blender/trunk/blender 2011-09-12 04:57:20 +00:00
9a1f3c587e - fix for mesh_get_mapped_verts_nors copying short normals to floats without scaling.
- BL_SkinDeformer also did this though for that case its not a problem because the normals are later accumulated anyway.
2011-09-12 04:29:35 +00:00
64aa651b1b speedup for editmesh drawing.
- avoid needless context switching quad/tri, flat/smooth.
- dont call glNormal3vf() lighting is disabled.

gives ~2x speedup with a subdivided cube, but thats probably the best case, quad/tri smooth/flat mix will slow down a bit.
2011-09-11 10:23:26 +00:00
2936ca5d04 bmesh: proper sculpting on non-multires object
Problem was caused by unneeded call of CDDM_calc_normals when
creating derived mesh for object which duplicated mvert array.

It shouldn't happen unless object has got shapekeys or deformation
modifiers on the top of stack.
2011-09-07 12:47:23 +00:00
42faf7ae41 Merge with trunk r39928 2011-09-05 17:06:09 +00:00
88a538048b Fix #28347: VBO's highlights wrong faces when Mirror modifier is in use
Added callback to drawMappedFaces which checks if two faces have got equal draw options.

After discussion with Brecht we found it's nicest solution for now:
- Disabling VBOs in edit mode for this case wouldn't be nicer for this case -
  some additional flag stored in DM should be added in this case.
- Adding new callback in DM isn't nicer that this solution.
- Handling face selection in drawobject would lead to duplicated code
  which is also not nice.

Hopefully, this callback could handle all cases in the future.

Also, Brecht mentioned current VBO implementation isn't perfect, so maybe
when we'll redesign this area dealing with edit mode wouldn't be so tricky.
2011-08-29 16:07:44 +00:00
c5106fd097 Merge with trunk r39589 2011-08-21 19:37:19 +00:00
c58fb76f1a Merged 39338-39558 2011-08-19 17:15:30 +00:00