下面由composer教程栏目给大家介绍关于composer根据name显示与隐藏,希望对需要的朋友有所帮助!
composer根据name显示与隐藏
//主要设置 模型的显示与隐藏 private void transmissionbydata_axsendselectionchange(string domname, bool isvisible) { system.threading.tasks.parallel.invoke(() => { try { if (isvisible) { axds3dviaplayeractivex1.setvisibility(clitselectionname(domname), cractorvisibility.cratvvisible, cractorvisibility.cratvkeepactorvisibility); } else { axds3dviaplayeractivex1.setvisibility(clitselectionname(domname), cractorvisibility.cratvinvisible, cractorvisibility.cratvkeepactorvisibility); } } catch (invalidcomobjectexception e) { console.writeline(e); } }); }
private string clitselectionname(string name) { return string.format("<clitselection name='' ><clitmodifiable name='{0}'/></clitselection>", name); } private void hightlightitem(string strid, axds3dviaplayeractivex objplayer) { try { objplayer.setpropertyset( objplayer.getallactorsonfilter("<clitpropertyset><actor.alpha value='255'/></clitpropertyset>", false), string.format("<clitpropertyset><actor.alpha value='{0}'/></clitpropertyset>", strhightlightalpha)); objplayer.setpropertyset( string.format("<clitselection name='' ident='-1'><clitmodifiable name='{0}'/></clitselection>", strid), "<clitpropertyset><actor.alpha value='255'/></clitpropertyset>"); } catch (invalidcomobjectexception e) { console.writeline(e); } } private void hightlightall(axds3dviaplayeractivex objplayer) { try { objplayer.setpropertyset( objplayer.getallactorsonfilter( string.format("<clitpropertyset><actor.alpha value='{0}'/></clitpropertyset>", strhightlightalpha), true), "<clitpropertyset><actor.alpha value='255'/></clitpropertyset>"); } catch (invalidcomobjectexception e) { console.writeline(e); } } private void setplayerselections(string[] stritemkeys, axds3dviaplayeractivex objplayer) { try { string strselection = ""; if (stritemkeys.length == 0) { strselection = "<clitselection name=\"\" ident=\"-1\"><clitmodifiable name=\"\"/></clitselection>"; } else { strselection = stritemkeys.aggregate("<clitselection name=\"\" ident=\"-1\">", (current, t) => current + string.format("<clitmodifiable name=\"{0}\"/>", t)); strselection += "</clitselection>"; } objplayer.selection = strselection; } catch (invalidcomobjectexception e) { console.writeline(e); } } //将player的选择项聚焦 private void setplayerselectionsfocus(axds3dviaplayeractivex objplayer) { try { objplayer.zoomselection(); } catch (invalidcomobjectexception e) { console.writeline(e); } }
在这里做个备注,防止下次忘记了..
以上就是关于composer根据name显示与隐藏的详细内容。