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
AgeCommit message (Collapse)Author
2015-08-24Fix editmesh GLSL tangent drawingCampbell Barton
The generic tangent calculation relied on CDDM arrays which aren't available in edit-mode. Add a tangent calculation callback, which has its own implementation for editmesh data.
2015-07-31Complete fix for T45618Antony Riakiotakis
Two issues here, normal update was not happening due to own sillyness in viewport refactor, also normal update code still used triangles. Now reused Campbell's poly normal recalculation code.
2015-07-31Don't initialize CDDM with MFace from MeshesCampbell Barton
Caused crash because MFace is no longer a layer which is added unless requested, causing CDDM to have numTessFaceData nonzero, but mface set to NULL.
2015-07-30Move tangents and baking to looptris:Antony Riakiotakis
Notes: * Code in rendering and in game engine will still convert tangents to a tessface representation. Added code that takes care of tangent layer only, might be removed when BGE and rendering goes full mlooptri mode. * Baking should work discovered some dead code while I was working on the patch, also tangents are broken when baking from multires (also in master), but those are separate issues that can be fixed later. This should fix T45491 as well
2015-07-29Fix T45605 crash with editmode selection on solidify modifier.Antony Riakiotakis
Looks like derivedmesh draw code always assumed a mesh is available. Make sure that if we use a bmesh, a flag is used to control that.
2015-07-28cdderivedmesh: don't prepare a normal buffer when selecting, evenAntony Riakiotakis
if we skip creating the selection color layer.
2015-07-27Use loop data instead of face dataCampbell Barton
Replace checks in various places
2015-07-25Convert CCGSubsurf VBO system to also sort hidden and visible faces.Antony Riakiotakis
It's not actually used during drawing though.
2015-07-25GPU Buffers:Antony Riakiotakis
This commit begins implementation of the idea about hidden face separation outlined in http://code.blender.org/2015/06/optimizing-blenders-real-time-mesh- We split hidden and visible faces to different parts of the triangle buffer. Mapped drawing will now skip iterating through hidden polys. Of course the final target, when all derived mesh types use VBO sorting, is to skip checking for hide flag per face completely. All faces will be pre-sorted anyway and we'll be able to draw them with one draw call.
2015-07-25GPU buffer materials:Antony Riakiotakis
Separate and reuse some shared code. Also avoid counting for information we already know, such as total loop triangles etc.
2015-07-24Fix yet another issue caused by my recent changes.Antony Riakiotakis
2015-07-24Fix out of bounds memory access when copying loose vertices in cddmAntony Riakiotakis
Caused by own fix for too much allocated memory not taking all code into account.
2015-07-20Use abstraction to unbind buffers, should avoid crashes in systems thatAntony Riakiotakis
don't support VBOs. Exposed by initialization error in GLEW, which should be fixed seperately.
2015-07-19Cleanup: styleCampbell Barton
Also 'com' as abbreviation for center-of-mass is a bit confusing, rename to 'center'.
2015-07-19Properly fix T45477Antony Riakiotakis
Code was actually skipping setting color selection indices and previous commit actually broke mask selection in texture painting. All should work now.
2015-07-17Avoid getting the original index if its not neededCampbell Barton
2015-07-17Absent-mindedness...Remove testing codeAntony Riakiotakis
2015-07-17Fix GLSL code not working correctly for Macs without VBO, again reportAntony Riakiotakis
by scorpion81 on irc
2015-07-17Fix issue reported by scorpion81 on irc: material mode + flat shadingAntony Riakiotakis
artifacts in cycles textured mode.
2015-07-17Fix another index error, made multimaterial mapped meshes drawAntony Riakiotakis
incorrectly.
2015-07-17Don't create MFace's when calculating normalsCampbell Barton
Instead only create MFace layer when its requested
2015-07-17Fix T45465Antony Riakiotakis
Easy one, we don't draw quads anymore. Also normal didn't use polygon index
2015-07-17Fix no longer being possible to display a suzanne with 8 levels ofAntony Riakiotakis
subdivision. Classic integet overflow/size_t substitution case. Machines are getting powerful enough to easily expose these kinds of error now.
2015-07-16Remove MTFace DM_paint_uvlayer_active_get funcCampbell Barton
2015-07-16Add tessellation data to DerivedMesh (LoopTri)Campbell Barton
This stores loop indices into the loop array giving easier acess to data such as vertex-colors and UV's, removing the need to store an MFace duplicate of custom-data. This doesn't yet move all internal code from MFace to LoopTri just yet. Only applies to: - opengl drawing - sculpting (pbvh) - vertex/weight paint Thanks to @psy-fi for review, fixes and improvements to drawing!
2015-07-16Sculpt draw code:Antony Riakiotakis
Remove legacy code completely, now dyntopo, multires et al even work on GL 1.1 for really hardcore users :p Real purpose here though is to be able to have fast multires drawing even with VBO off, since it requires using indices for vertex buffers. Also made own code elf puke an eaten normal update function which made multires not update normals in solid mode...sorry.
2015-07-15 VBO offscreen selection drawing, cdderivedmeshAntony Riakiotakis
Get rid of legacy drawing, it's only used for selection, in which case we can prepare a temporary color buffer and draw at once. Code is not complete here because we still redundantly set the draw color in the draw function and don't ommit hidden faces automatically. Still it works 100% without immediate mode now.
2015-07-15Fix autosmooth with recent DM optimizationsCampbell Barton
Also avoid multiple float->short conversions for the same normal.
2015-07-15DerivedMesh: minor changes to callback useCampbell Barton
- use void instead of float for array arg (cast in the switch statement) - remove unused args - use const for poly-mapping and user_data args
2015-07-15Cleanup: wsCampbell Barton
2015-07-15Cleanup: wsCampbell Barton
2015-07-15Fix overdrawing and errors with textured and mapped drawingAntony Riakiotakis
2015-07-14Display optimizations part 1.Antony Riakiotakis
This patch changes the way we draw meshes by introducing indexed drawing. This makes it possible to easily upload and rearrange faces ad lib according to any criteria. Currently we use material sorting but textured sorting and hiding will be added to optimize textured drawing and skip per face testing. It also adds support for vertex buffers for subsurf modifiers (Except from GLSL drawing), making drawing of subsurf much faster without need for bogus modifiers. Tests show that we gain approximately 20-25% performance by that for solid mode drawing with up to 50% gains for material drawing. Textured drawing should also have a small performance gain, but more substantial optimizations are possible there. Reviewers: campbellbarton Differential Revision: https://developer.blender.org/D1406
2015-07-14Correct last commitCampbell Barton
2015-07-14Move from MTFace to MTexPoly w/ texture checksCampbell Barton
Part of moving away from MFace.
2015-07-10CustomData: deprecate CD_ID_MCOLCampbell Barton
2015-07-07Minor simplification for uv edge drawingCampbell Barton
2015-06-23Fix edge drawing, total loose edges can only be determined -after- theAntony Riakiotakis
edge buffer has been setup (this is where they are counted)
2015-06-23Fix T45117: Dark dupli-face objects (regression)Campbell Barton
2015-06-22Fix T45136, only draw edges if there's something to draw.Antony Riakiotakis
2015-06-16Optimize drawing of outlines as wellAntony Riakiotakis
2015-06-16Drawing speedup:Antony Riakiotakis
We really don't need to iterate all edges of the mesh every frame to search for loose edges, this calculation can be cached when filling the edge index buffer.
2015-05-19BMesh: editmode drawing set every faces materialCampbell Barton
Check for changes in material (as other drawing code already does)
2015-04-15dyntopo: don't allocate tessfaces while sculptingCampbell Barton
Tessellation data isn't used for drawing or sculpting. This frees up some memory ~approx 10% in own tests. Also slight spee-up since it avoids calculating it in the first place.
2015-04-07Use BKE_edgehash_ensure_p where possibleCampbell Barton
2015-03-30Fix for invalid buffer access on zero-face meshesCampbell Barton
2015-03-11Fix really stupid issue reported by Campbell, code retry to renderAntony Riakiotakis
without VBOs would return prematurely and leak.
2015-03-11Fix T43342 bad rendering of normal maps on NVIDIAs on the MacOSAntony Riakiotakis
This is not limited to normal maps, it's just that normal maps cause a mix of interleaved vertex arrays + non interleaved vertex arrays + GLSL, which could confuse the GL. Possible explanation is that it may be clobbering the vertex index of the shader somehow but this is difficult to know without extensive tests and the Mac is needed by Francesco in the morning :). Do brute force solution instead, just force legacy drawing on Macs when VBOs is off. On the plus side VBOs work fine, so we should be fine when we update.
2015-02-05Add Custom Loop Normals.Bastien Montagne
This is the core code for it, tools (datatransfer and modifier) will come in next commits). RNA api is already there, though. See the code for details, but basically, we define, for each 'smooth fan' (which is a set of adjacent loops around a same vertex that are smooth, i.e. have a single same normal), a 'loop normal space' (or lnor space), using auto-computed normal and relevant edges, and store custom normal as two angular factors inside that space. This allows to have custom normals 'following' deformations of the geometry, and to only save two shorts per loop in new clnor CDLayer. Normal manipulation (editing, mixing, interpolating, etc.) shall always happen with plain 3D vectors normals, and be converted back into storage format at the end. Clnor computation has also been threaded (at least for Mesh case, not for BMesh), since the process can be rather heavy with high poly meshes. Also, bumping subversion, and fix mess in 2.70 versioning code.
2015-01-20De-duplicate large block of shared code for GL vert attribsNicholas Bishop
Code in ccgdm_draw_attrib_vertex() was entirely the same as the top portion of the code in cddm_draw_attrib_vertex(). Moved this code to a new function, DM_draw_attrib_vertex(). ccgdm_draw_attrib_vertex() was removed in favor of calling DM_draw_attrib_vertex(). cddm_draw_attrib_vertex() still does a couple extra things, so it still exists but calls DM_draw_attrib_vertex(). In the interest of easy code review, no changes made to the code in DM_draw_attrib_vertex() other than the new name and an added comment. Reviewers: campbellbarton Reviewed By: campbellbarton Differential Revision: https://developer.blender.org/D1010