July 5, 2013, 17:46 (GMT) |
Anchored brushes for texture paint. To support this I added size support to the RNA stroke so the stroke size can be calculated in the stroke system and passed on to paint systems. Also, the output mouse coordinate is directly modified now and the size is tweaked accordingly. Looks sculpt does not directly use this for anchored strokes as far as I have seen, but accidents could happen there so I hope there will be some artist testing. Also fixed error in texture coordinates for jittered strokes. |
July 5, 2013, 14:26 (GMT) |
Use undo tile colours and masks as projection pixel original colours and accumulation masks respectively. This will solve artifacts when painting on meshes where two faces reference the same region in UV space. Of course, painting on a multithreaded system is bound to create some conflicts if you paint with a brush that will put different colours on the same region (for instance a textured brush), but at least you don't get the final colour reset to the original due to a pixel still having a zero accumulated mask in screen space. For more correct results, synchronization (locking) on accululated mask writing should occur but I don't think this is too crucial and it will hurt performace somewhat if it is added. More tests are needed to assert that it is indeed not necessary. |
July 5, 2013, 13:10 (GMT) |
Keeps the operator stack synchronised with the undo stack so that the redo panel displays the right operator after an undo. N.B. This is an updated version of patch #35059 in the tracker, which had a nasty bug in it still. This patch aims to introduce functionality that keeps the two undo stacks (object mode, and edit mode) synchronised with the operator stack in the window manager. This allows for the operator redo panel to be initialised to the last operator that was performed to arrive at the current state after undos and redos are performed. This is achieved by keeping pointers to the operators in the UndoElem structs and rebuilding the wmWindowManager's operator stack after each undo or redo. The changes throughout the code aim to achieve that a) wmOperator structs are passed to the undo systems to be stored in the UndoElem structures (changes in undo_push_X functions), b) wmOperator structs that are referenced from UndoElem structs are only freed by the undo system, and that c) the operators that are repeated instead of redone (repeat last, repeat from history) are copied rather than moved to the back of the operator stack. Operators that have a flag OPTYPE_UNDO are registered in the undo system and the undo system is responsible only for these operators. Other operators are freed after application. Even though all OPTYPE_UNDO operators are registered in the undo system, only OPTYPE_REGISTER operators are included when generating the window managers operator stack. N.B. The following changes aren't very nice and I would like to point them out explicitly. - The undo system, which is part of blender's core, is now more strongly connected to window managing subsystem than before - The UndoElem structs (one for object mode undo, and one for edit mode undo) are not exposed, but mapped to a third UndoElem in wm.c. This was done to avoid bringing too much WM logic into blender.c. Better but more involved solutions exist. Further changes should include doing away with the operator stack entirely and use the undo system as the backend data model for it. |
July 4, 2013, 22:41 (GMT) |
Merged revisions 57870-57983 from trunk/blender |
July 4, 2013, 10:16 (GMT) |
svn merge -r57985:57990 ^/trunk/blender |
July 4, 2013, 06:20 (GMT) |
svn merge -r57643:57984 ^/trunk/blender |
July 4, 2013, 02:39 (GMT) |
Cleaning up the game engine level of detail logic to avoid crashes with levels that have no source object defined. |
July 3, 2013, 19:49 (GMT) |
Utilize the old undo push code to only actually push undo tiles that contains pixels that changed. Still haven't fixed original pixels being different than the original image, coming soon. This will also fix drag dot undo. |
July 3, 2013, 19:35 (GMT) |
Merge trunk -r57968 into soc-2013-paint |
July 3, 2013, 19:21 (GMT) |
Fix old undo issue for projective texture paint Undoing when faces accessed the same region in uv space could create artifacts. The issue here is that buckets get their original colour initialized with the colour that exists in the image at the point of initialization. If two faces on different buckets accessed the same region, then one bucket would get the modified colour as the original colour. The undo push code simply checked if the final colour was different than the original colour and as a result it could copy modified colours in the undo stack. Now simply push the undo stack when initializing the buckets. This ensures that the stack contains really original colours. Of course there is some overhead. Also added mask code creation as part of the undo tile creation. The accumulated mask should be in canvas space pixels, not on screen space bucket pixels. I will next hook up the projection pixels to reference this mask. This will hopefully solve cases like painting on mirrored meshes or meshes that the same canvas region is accessed by many faces. |
July 3, 2013, 19:21 (GMT) |
Fix doing too many invalidations of brush image cache. Having separate flags for mask/image helps here. |
July 3, 2013, 03:18 (GMT) |
The level of detail system now works in the game engine with group instances. This required the game engine to reimplement some of the level of detail logic, but not too much. |
July 2, 2013, 21:56 (GMT) |
Fix issue reported on blenderartists: 2d painting does not respect the brush strength when masking is off. I hope behaviour will at last be consistent in every case now. |
July 2, 2013, 01:01 (GMT) |
Add missing notification event for colour flipping |
July 1, 2013, 13:30 (GMT) |
merged trunk |
July 1, 2013, 09:12 (GMT) |
Starting support for mesh and material levels of detail in the game engine. They work for simple cases, but break in more advanced usage such as dupligroups. |
July 1, 2013, 09:10 (GMT) |
Changed BKE_object_lod_update to return a bool indicating if the lod level has changed. |
June 30, 2013, 11:07 (GMT) |
Fix sample color operator sampling brush colour. Temporarily turn brush display off while the operator is running. |
June 30, 2013, 09:55 (GMT) |
Optimizations for image paint undo stack for drag dot/anchored strokes * Skip copy of undo tile to temorary buffer when restoring. Gives a nice speedup. * When we restore the image from undo tiles, make tiles invalid. On undo push end, invalid tiles get deleted. This solves saving too many tiles in the case where user could happilly drag the dot all around the image. |
June 30, 2013, 08:29 (GMT) |
Moving the material level of detail switch to avoid problems with the material panel. |
|
|
|


Master Commits
MiikaHweb | 2003-2021