diff options
author | Nicholas Bishop <nicholasbishop@gmail.com> | 2008-07-22 03:41:01 +0400 |
---|---|---|
committer | Nicholas Bishop <nicholasbishop@gmail.com> | 2008-07-22 03:41:01 +0400 |
commit | b0b2a57e66a982ca714c667390f93eddc0f26653 (patch) | |
tree | 06f0da3a110fb1a9cc6af06caaf2bb2d9ab5acc6 /source/blender/src | |
parent | e84f5bdecf80a7981e4d830391631b8b59582f16 (diff) |
Started removing the old multires code. Also removed a few pointers in the DNA data that won't be needed for backwards-compat. Put a warning in the Python code as a reminder that it'll need to be updated to work with the new multires code.
Diffstat (limited to 'source/blender/src')
-rw-r--r-- | source/blender/src/buttons_editing.c | 67 | ||||
-rw-r--r-- | source/blender/src/multires.c | 22 |
2 files changed, 0 insertions, 89 deletions
diff --git a/source/blender/src/buttons_editing.c b/source/blender/src/buttons_editing.c index 38170182276..5cbeac2b0ca 100644 --- a/source/blender/src/buttons_editing.c +++ b/source/blender/src/buttons_editing.c @@ -6281,73 +6281,6 @@ static void editing_panel_mesh_uvautocalculation(void) uiBlockEndAlign(block); } -void editing_panel_mesh_multires() -{ - uiBlock *block; - uiBut *but; - Object *ob= OBACT; - Mesh *me= get_mesh(ob); - int cx= 100, cy= 0; - - block= uiNewBlock(&curarea->uiblocks, "editing_panel_mesh_multires", UI_EMBOSS, UI_HELV, curarea->win); - if(uiNewPanel(curarea, block, "Multires", "Editing", 500, 0, 318, 204)==0) return; - - uiSetButLock(object_data_is_libdata(ob), ERROR_LIBDATA_MESSAGE); - - if(!me->mr) { - but= uiDefBut(block,BUT,B_NOP,"Add Multires", cx,cy,268,19,0,0,0,0,0,"Allow editing of the mesh at multiple subdivision levels (disables distructive mesh editing)"); - uiButSetFunc(but,multires_make,ob,me); - } else { - char subsurfmenu[]= "Subsurf Type%t|Catmull-Clark%x0|Simple Subdiv.%x1"; - - but= uiDefBut(block,BUT,B_NOP,"Apply Multires", cx,cy,268,19,0,0,0,0,0,"Apply current multires level to mesh and the delete other levels"); - uiButSetFunc(but,multires_delete,ob,me); - cy-= 24; - - uiBlockBeginAlign(block); - but= uiDefBut(block,BUT,B_NOP,"Add Level", cx,cy,134,19,0,0,0,0,0,"Add a new level of subdivision at the end of the chain"); - uiButSetFunc(but, multires_subdivide, ob, me); - uiDefButC(block, MENU, B_NOP, subsurfmenu, cx + 134, cy, 134, 19, &G.scene->toolsettings->multires_subdiv_type, 0, 0, 0, 0, "Selects type of subdivision algorithm."); - cy-= 20; - - if(me->mr->level_count>1) { - but= uiDefBut(block,BUT,B_NOP,"Del Lower", cx,cy,134,19,0,0,0,0,0,"Remove all levels of subdivision below the current one"); - uiButSetFunc(but,multires_del_lower,ob,me); - but= uiDefBut(block,BUT,B_NOP,"Del Higher", cx+134,cy,134,19,0,0,0,0,0,"Remove all levels of subdivision above the current one"); - uiButSetFunc(but,multires_del_higher,ob,me); - cy-= 20; - - but= uiDefButC(block,NUM,B_NOP,"Level: ",cx,cy,268,19,(char *)&me->mr->newlvl,1.0,me->mr->level_count,0,0,""); - uiButSetFunc(but,multires_set_level_cb, ob, me); - cy-= 20; - - but= uiDefButC(block,NUM,B_NOP,"Edges: ",cx,cy,268,19,(char *)&me->mr->edgelvl,1.0,me->mr->level_count,0,0,"Set level of edges to display"); - uiButSetFunc(but,multires_edge_level_update_cb,ob,me); - cy-= 20; - uiBlockEndAlign(block); - - cy-= 5; - uiDefBut(block,LABEL,B_NOP,"Rendering",cx,cy,100,19,0,0,0,0,0,""); - cy-= 20; - - uiBlockBeginAlign(block); - uiDefButC(block,NUM,B_NOP,"Pin: ",cx,cy,268,19,(char *)&me->mr->pinlvl,1.0,me->mr->level_count,0,0,"Set level to apply modifiers to during render"); - cy-= 20; - - uiDefButC(block,NUM,B_NOP,"Render: ",cx,cy,268,19,(char *)&me->mr->renderlvl,1.0,me->mr->level_count,0,0,"Set level to render"); - cy-= 20; - - if(multires_modifier_warning()) { - char *tip= "One or more modifiers are enabled that modify mesh topology"; - uiDefIconBut(block,LABEL,B_NOP,ICON_ERROR, cx,cy,20,20, 0,0,0,0,0, tip); - uiDefBut(block,LABEL,B_NOP, "Cannot use render level", cx+20,cy,180,19, 0,0,0,0,0, tip); - } - } - } - - uiBlockEndAlign(block); -} - void particle_edit_buttons(uiBlock *block) { Object *ob=OBACT; diff --git a/source/blender/src/multires.c b/source/blender/src/multires.c index 64edfb5f6cc..abad36f05ce 100644 --- a/source/blender/src/multires.c +++ b/source/blender/src/multires.c @@ -362,28 +362,6 @@ void multires_finish_mesh_update(Object *ob) } } -void multires_subdivide(void *ob_v, void *me_v) -{ - Mesh *me = me_v; - - multires_check_state(); - - if(CustomData_number_of_layers(G.obedit ? &G.editMesh->fdata : &me->fdata, CD_MCOL) > 1) { - int ret= okee("Adding a level will delete all but the active vertex color layer, proceed?"); - if(!ret) - return; - } - - waitcursor(1); - multires_add_level(ob_v, me, G.scene->toolsettings->multires_subdiv_type); - multires_level_to_editmesh(ob_v, me, 0); - multires_finish_mesh_update(ob_v); - - allqueue(REDRAWBUTSEDIT, 0); - BIF_undo_push("Add multires level"); - waitcursor(0); -} - void multires_set_level_cb(void *ob, void *me) { waitcursor(1); |