æ°å¹Žåã«åæ§ã®ç¶æ³ã§ãçŽç²ã«å¥œå¥å¿ã®ããã«Revitã®APIãæ€èšããããšã«æ±ºããå Žåãåé¡ã¯ãŸã£ãããããŸããã§ããããNanocadã§ã¯ããã»ã©ç°¡åã§ã¯ãããŸããã§ããã
ããã€ã«ã»ãã³ã©ãšãŽã£ããã«æ¬æãè¡šããŠããèžã«ç©ºæ°ãå ¥ããŠãã ããããšèšãããšãã§ããŸãããããã®ã¢ã¡ãªã«äººã¯ããããªãã¯ãã¡ã€ã³ã®ãµã€ãã«æçš¿ããŸãã... å§ããããã®æ瀺 ïŒ ãããã¯ãã¹ãŠäœã§ãã...äžè¬çã«ãããªãã¯ç解ããŠããŸããããã¯ããªããããã³ã¹ãã§åŒãä¿ã€ãããã§ã¯ãããŸããã
ããããç§ãã¡ã¯ããŸãšããªäººãšããŠãå®å šã«å¥å šãªè£œåãšéçºããŒã«ãžã®ã¢ã¯ã»ã¹ãç¡æã§æäŸããŠããã人ãscãã®ã§ã¯ãªããç¹ã«MultiCadã®ææ°ã®åºç以éãå°ãã§ãæå©ãããŠãã ããã NET APIã¯ãã»ãŒ2幎åã«Habré ã®Nanosoftã®ããã°ã«æ²èŒãããŠãããããå°ã空宀ãåããå¿ èŠããããŸãã
æ®å¿µãªããããã®åé¡ã®å®å šãªåå¿è ãšããŠãç§ã¯ããªãã«æ¬åœã«ãŸãšããªå質ã®è³æãæäŸããããšã¯ã§ããŸããããå°ãªããšãç§ã¯ããã«ãã®ã£ã°ãããã£ãåé¡ãæ€èšããŸãã Data Scienceã®æåŸã®ãµã€ã¯ã«ã®ããã« ãåå¿è ããåå¿è ãŸã§ã®èšäºã§ããããšãããããŸãã
èšç»ã¯æ¬¡ã®ãããªãã®ã§ããNanocadã«ã€ããŠå°ãèªããNanocadã®ããã°ã©ãã³ã°ã«ã€ããŠå°ã説æããæåŸã«MultiCAD .NET API 7ïŒNanocad 8.Xã®å ŽåïŒã䜿çšããŠããªããã£ãã³ãã³ããèšè¿°ããŸãã
ã ãããç§ãã¡ã¯çµµããã¥ãŒãã«é ãããã±ãããåãé€ããäžäºéã«ãã¿ãŒã³ã眮ããç«ã®äžã§ããªãã«æé¡ããŸãã
芪æãªãèªè ããããã®è¡ãèŠãããç¥ã£ãŠãã-ããªãã¯å€§ããªå±éºã«ãããããŠããŸãïŒ ç§ã®éå»ã®èšäºãå¶ç¶èªãã 人ã¯ãæè¿ãèžè¡çè¡šçŸåãé«ããããã«ãå®ååããããã®ã§èŠåºããè£å®ããæ ç»ããã¬ã€ããããšãããæŒå¥ããŠããããšãç¥ã£ãŠããŸãã
çç±ã¯ããããŸãããããã®èšäºãæžãå§ãããšããããã«ããŠã¹ããšãã¹ã¡ãããã©ããããã°ã©ã ã®é»éæ代ã®ç¬çœããã®æç²ã«è¿œå ããã ãã§ããããšã«æ°ä»ããŸããã ã§ãããããã®èšäºã¯åŒ·ã粟ç¥ãæã€äººã ã®ããã®ãã®ã§ãã
å 容ïŒ
ããŒãIïŒã圌ãã¯ç§ã«ãããæ¯æããªãïŒ ïŒã¯ããã«ïŒã
ããŒãIIïŒèŒžå ¥ä»£æ¿
ããŒãIIIïŒAPIãããã¥ã¡ã³ããéå§å Žæãžã®ã¢ã¯ã»ã¹ã
ããŒãIVïŒéçºç°å¢ãã»ããã¢ããããç°¡åãªã³ãã³ããæžã
ããŒãVïŒããã¯æ®å¿µã§ãïŒ ïŒçµè«ïŒ
1.æ¯æããåããŸããïŒ ïŒã¯ããã«ïŒ
ãããããNanosoftãšã¯äœã®é¢ä¿ããªãã圌ãã¯ç§ã«ãéãæã£ãŠããªãããšèšãã®ãé©åã ãããã ãããèšäºã«ããã®ã¯ç§ã®å人çãªæèŠã ãã ã
ãšããã§ããã®æèŠã¯éåžžã«è¯å®çã§ãã Nanocadãšã®å®å šãªç¥ãåãã¯ã Drzugrikãšç§ã®ååããŸã è¥ãã€ã³ã¿ãŒã³ã§ãããéåœãç§ãã¡ããæµ·è³çããœãããŠã§ã¢ã®äœ¿çšãåãå ¥ããããªãè¯ãäŒç€Ÿã«é£ããŠè¡ã£ããšãã«å§ãŸããŸããã åœç¶ãAutoCADã®ã©ã€ã»ã³ã¹ã¯2人ã®ãåŠçãã«ã¯èŠã€ãããŸããã§ããããããã§ã¯Nanocadã圹ã«ç«ã¡ãŸããã
確ãã«ã3.Xãã¡ããªã®ãã¹ãŠã®ç¡æããŒãžã§ã³ã«ã¯ãå€ãã®åŒãè£ããã髪ãšæ±ãèšèãããããŸãããããã®åŸãããŒãžã§ã³5.1ïŒ Nanocad Free ïŒããªãªãŒã¹ãããŸãããããã¯éåžžã«äŸ¿å©ãªãé»åã«ã«ãã³ãã§ãã ããã€ãã®åçŽãªãã¹ããŒã ããã¹ã±ããããå¿ èŠããããšããç§ã¯ãŸã ããã䜿çšããŸããäŸãã°ãããïŒ
ã芧ã®ãšãããã€ã³ã¿ãŒãã§ã€ã¹ã¯å€ãã¢ãŒãã®ãpre-continuousãAutoCADã«äŒŒãŠãããæ©èœã¯AutoCAD LTã®ããŒãã®çµãããã«äŒŒãŠããŸãã 確ãã«ãAutoCADã®LTããŒãžã§ã³ãšã¯ç°ãªããç¡æã®Nanocadeã§ã¯3Dã䜿çšããæ©äŒããããŸãããçåŸã説æçãªãžãªã¡ããªã§å²ãåœãŠãè¡ãããšãé€ããŠãããŸãã¡ãªããã¯ãããŸããïŒãã¥ãŒãšã¢ã€ãœã¡ãæç»ããèŠãŠããæç»ããŸãïŒã
ãŸãã建èšæ¥çåãã®2次å èšèšã®èŠ³ç¹ããã¯ãããªãŒããŒãžã§ã³ã®æ©èœã¯ãããªãŒã©ã³ãµãŒãå°èŠæš¡ãªèšèšå±ãSMRçµç¹ã«ãšã£ãŠã¯ååãªãã®ã«ãªãå¯èœæ§ããããŸãã
確ãã«ãçŸæç¹ã§ã¯Nanocad 8.5ã®ææçããããŸãããæ£çŽãªãšãããç§ã¯ãããæäŸããèªååã®åã³ããã¹ãŠå³ãã£ãããã§ã¯ãããŸããã ãããããThe NanoPathãžã®éããšããæ¬ïŒåŸã»ã©ïŒãä¿¡ãããªããããã¯æ¬åœã«äŸ¿å©ãªããã«æããŸãããå®éã«ã¯ãããèŠã€ããããšããããŸããã
3Dã®ææçã®ç¡æçãšã¯ç°ãªããç¶æ³ã¯æ¹åãããŠããããã«èŠããŸããã2Dãã©ã¡ãŒã¿ãŒåãš3Dã¢ããªã³ã°ã®å Žåã¯ãïŒNanocad Plusã®ã©ã€ã»ã³ã¹ã«å ããŠïŒå¥éè¿œå æéãæ¯æãå¿ èŠããããŸãã
å šäœçãªåé¡ã¯ãç§ãç解ããŠããããã«ãç§ãã¡ã®åœã§ã¯ãèšèšããã»ã¹ããè³¢æãã«èšå®ãããŠããäŒæ¥ã¯ããããããã¹ãŠããæšæ¥ããšãèã®äžã§ãè¡ãããã¹ããªãã£ã¹ããããŸã å°ãªãããšã§ããèªååã®å®è£ ã¯ç¥èãªéŠ¬é¹¿ã®ããã«èŠããŸãã ããã¯ç§ã®å人çãªæèŠã§ãããåæã«éåžžã«æ代é ãã§ãæããæªæ¥ããåºã®è¡ãããããŠããããã¹ãŠã§ãããããããç§ã¯ç¥åœã«éåžžã«æºè¶³ããŠããŸã=ïŒ
ããããNanocadã«æ»ããšãçŸåšã®äžççãªç¶æ³ã«ç §ãããŠããã·ã¢äŒæ¥ïŒåœæäŒæ¥ãå«ãïŒã«1ã€ã®ãããããããŸãã
2.ã€ã³ããŒã眮æ
人çã¯èœã¡çããŠããããå¶è£ãæ¡å€§ããŠããã®ã§ããã«ããŒã¶ãŒã䜿çšããŠDVDãã£ã¹ã¯ã®èªå¯ããããã£ã¹ããªãã¥ãŒã·ã§ã³ãããã·ã¥ããããšãããããŸãã
建èšå·¥åŠæ¥çã§ã¯ãªãŒããã¹ã¯è£œåãšååã®å åŒã®å§åçãªåªäœæ§ã§ããAsconïŒCompassïŒè£œåãäœããã®åœ¢ã§å®çããªãã£ãããšãæŽå²çã«çºçããããšã«æ³šæããŠãã ããããŸãèŠã€ãããŸããã ããã¯ç§ã®å人çãªæèŠã§ããããããªããŒããåŒãèµ·ãããªãããšãé¡ã£ãŠããŸãã
ããŠãAutoCADãšCompanyã«æ»ããšãäœããããŸããïŒ ãªãŒããã¹ã¯è£œåã¯é«å質ã§ãããé«äŸ¡ã§ãããç±³åœã«äžå€®ãªãã£ã¹ããããŸãã BricsCADãšZWCADãããããããã¯ç¢ºãã«å®äŸ¡ã§ãããäŸãã°ãåãBricsCADã¯ä»ãšæ¯èŒããŠããªãèªèº«ã«ã€ããŠå€ãã®å©ç¹ãæããŠãããŸãããããã§ãåœå ãªãã£ã¹ã®ååšã«ããããããããããã¯å€åœãšã¿ãªãããšãã§ããŸãã ãããã®ããã°ã©ã ã«ã¯ãã¡ã³ãããŸããããããã«ã€ããŠã¯äœãèšããŸãã-ç§ã¯ããã䜿ããŸããã§ããã
ãŸããDRAFTSIGHTããããŸããããã«ã¯ãå人çšã®Linuxçšã®ç¡æããŒãžã§ã³ããããŸããè¯ãç¹ãæªãç¹ãèšããŸããã30åã»ã©ãããããé·ãé䜿çšããŠããŸããã
ãã¡ãããArchiCADããããŸãããç§ã«ã¯å°ãç°ãªãã³ã³ã»ãããããããã§ãä»ã¯æ¯èŒããŸããã
åœå ã®ãã®ãå«ãä»ã®CADã·ã¹ãã ããããŸãããç§ã¯ãããã«ã€ããŠã»ãšãã©ãŸãã¯ãŸã£ããç¥ããŸããã
äž»ãªããšã¯ããªãŒãã³ãã¶ã€ã³ã¢ã©ã€ã¢ã³ã¹ãžã®äŸåã¯å¥ãšããŠãNanocadã¯ããããã建ç¯èšèšã®åéã«ããããªãŒããã¹ã¯è£œåã®ãèŒžå ¥ä»£æ¿åãã®æåã®åè£ã§ããããšã§ãã
ãã©ãããã©ãŒã ã«ã¯åçŽåã®ãœãªã¥ãŒã·ã§ã³ããããã¡ã«ããã¯ãããã¡ãã·ã§ããã«ãªBIMãŸã§ãããŸããŸãªå°éåéãèŠã€ããããšãã§ããããšã«æ³šæããŠãã ãããæ£çŽãªãšãããå®éã«ãããã«åºäŒã£ãããšã¯ãããŸãããããšãã°ãNanocad Engineering BIMãRevitã«åºã¥ãããœãªã¥ãŒã·ã§ã³ã眮ãæããããšãã§ãããã©ããã¯èšããŸãã
ãšããã§ããã©ãŒã©ã ã«ãããšãNanocadã®ç¡æçã®æŽæ°ã¯DWG圢åŒãDWG 2018ã«æŽæ°ããããšã«é¢é£ããŠããããããªãŒããã¹ã¯ã«æè¬ããã®ãé©åã§ãã ç¡æçãæŽæ°ããæ£ç¢ºãªã¿ã€ãã³ã°ã¯ãŸã äžæã§ãã
ãŸããææ補åã«å ããŠãFreeCadãLibreCADãQCADãªã©ã®ãªãŒãã³ãœãŒã¹ãœãªã¥ãŒã·ã§ã³ããã¡ããããããšãæãåºããŸã-å¿ãã圌ãã®æåãé¡ã£ãŠããŸãããå°ãªããšãä»ã®ãšãããããã«åºã¥ãããããžã§ã¯ãããžãã¹ãæ§ç¯ããåæ°ã¯ã»ãšãã©ãªããšæããŸãã
APIã®åé¡ã«ã¹ã ãŒãºã«åãæ¿ããããã«ãMultiCAD .NET APIã䜿çšãããšãçè«çã«ã¯NanocadãAutoCADãZWCADã§å®è¡ããããŠãããŒãµã«ã¢ããªã±ãŒã·ã§ã³ãäœæã§ããŸãã éãã€ãã£ããã©ãããã©ãŒã ã®å Žåãã©ã€ãã©ãªã¯ãœãããŠã§ã¢ã¬ã€ã€ãŒãä»ããŠèµ·åãããŸãã 確ãã«ãå®éã«ã¯ä»ã¯ç¢ºèªã§ããŸããã§ãããããªãã§ããïŒ ãã ããPCã«ã¯AutoCAD 2017ã®ã¿ãã€ã³ã¹ããŒã«ãããŠãããå©çšå¯èœãªãã¬ã€ã€ãŒãã¯éçºè ããŒã¿ã«ã§å©çšã§ããããããµããŒããããŠããŸããïŒå°åã¯AutoCAD 2016ã§ãïŒã ããã§ã¯ãéçºè ã®è¯å¿ã«èšŒæ ãæ®ããŸãããã
Nanocad APIããã¹ã¿ãŒããããšæ±ºå¿ããåå¿è éçºè ãééããåé¡ã«ãã€ãã«ã¹ã ãŒãºã«åãçµã¿å§ããŸããã
3. APIãããã¥ã¡ã³ããéå§å Žæãžã®ã¢ã¯ã»ã¹ã
ããããæãåççãªæ¹æ³ã¯ãNanocad Developer Clubã«ç»é²ããããšã§ãã ç°¡åãªã¢ã³ã±ãŒãã«èšå ¥ããæ¿èªãåŸ ã£ãŠïŒé©åã«èšå ¥ãããŠããã°åé¡ã¯ãªãã¯ãã§ãïŒããã®åŸãéçºãªãœãŒã¹ã«ã¢ã¯ã»ã¹ã§ããŸãã
ãããã®ãªãœãŒã¹ã¯äœã§ããïŒ
- äžéšã®ããŒã¿ããŒãžã§ã³ãå«ãNanocadã®ãªãªãŒã¹ããŒãžã§ã³ã®ã©ã€ã»ã³ã¹ãšãã£ã¹ããªãã¥ãŒã·ã§ã³ãžã®ã¢ã¯ã»ã¹ãããã³APIèªäœïŒSDKïŒãžã®çŽæ¥ã¢ã¯ã»ã¹ã
- éçºè åãã®ãã©ã€ããŒããã©ãŒã©ã ãžã®ã¢ã¯ã»ã¹ïŒ éåžžã®ãã©ãŒã©ã ãšæ··åããªãã§ãã ãã ïŒ
- éçºè ãšã®ã³ãã¥ãã±ãŒã·ã§ã³ãããã°ãã瀺ãæ©èœãŸãã¯ãæ©èœããèŠæ±ããæ©èœã
ãŸããèšèã§ã¯ãã¹ãŠãéåžžã«ããèŠããŸãããå®éã«ã¯ãã¡ããè¯ãã§ãããè»èã«ããšããããŸãã
ãã®æ¹åã¯ã³ã¢ã§ã¯ãªããåçåã§ããªããããããšãã°ãéçºè ããŒã¿ã«ã§ã¯ããŒã¿ããŒãžã§ã³8.5ã®ã¿ãå©çšå¯èœã«ãªã£ãŠããŸãããå®å šãªããŒãžã§ã³ã¯æ¢ã«äŒç€Ÿã®ããŒã¿ã«ã«æçš¿ãããŠããŸãããæ®ãããæ¹æ³ã§å¯ŸåŠããŠãããšæããŸãã åé¡ã¯ãã®ãã«ããŒãžã§ã³ãšããããšã§ãã ç§ã®æèŠã§ã¯ããµã€ãã¯SDKãªãã§è¡ãã®ã§ãããŒã¿çã®SDKã¯æçµçãšéåžžã«ç°ãªããšæããŸãã
ããŠãåè¿°ããããã«ãMultiCAD_AC_ZC_Enabler_2209_RUããã±ãŒãžïŒä»ã®CADã§APIãæäœããããã®ãã¬ã€ã€ãŒãã®ã»ããïŒãããããæŽæ°ãããŠããŸãããããŒã¿ã«ã«ã¯æ°ããããŒãžã§ã³ïŒAutoCAD 2017çšïŒã¯ãããŸããã
ããããããäžåºŠç¹°ãè¿ããŸãããããããšãããããŸãïŒ ãããã¯äºçŽ°ãªããšã§ããäž»ãªããšã¯ãããã°ã©ã ã®æ°ããããŒãžã§ã³ãšå€ãããŒãžã§ã³ã®ã©ã€ã»ã³ã¹ãååŸããã¢ããªã±ãŒã·ã§ã³ã®ãœãŒã€ã³ã°ãéå§ã§ããããšã§ãïŒã©ã€ã»ã³ã¹ã¯éçºçšã«ã®ã¿æäŸãããŸãïŒã
2çªç®ã®åé¡ã¯APIã®ããã¥ã¡ã³ãã§ããå€ãã®èšèªïŒçŽç²ãª.NET APIïŒMulticadã§ã¯ãªãïŒãC ++ãLispïŒã®APIããããŸãããä»æ¥ã¯MultiCAD API .NETã«ã€ããŠã®ã¿èª¬æããŸãã ãããã£ãŠãMicrosoftã®ãã€ãã£ãã©ã€ãã©ãªã®ã¯ã©ã¹ãã¡ãœãããããããã£ã®è©³çŽ°ãªèª¬æã«æ £ããŠããå Žåããã£ãšå€±æããããšã§ãããã ãã«ãå ã®èª¬æã®ã»ãšãã©ã¯èªåçã«çæãããããã§ãããã¯ã©ã¹ããŸã 説æãæãã€ãããšããããŸãã ããªããããšã«ããããã°ã©ããŒã§ã¯ãªããïŒç§ã®ããã«ïŒã§ãããšåæã«ãAPIã®ããžãã¯ãããã«è§£æããããã®åªç§ãªæ¢åµã§ã¯ãªãå Žåãå€éšããã®æ¯æŽãªãã§ã¯ã§ããªãããšãããããŸãã
ã©ãã§å©ããåŸãããšãã§ããŸããïŒ ãããŠãéçºè ãã©ãŒã©ã ãé€ããŠã»ãšãã©ã©ãã«ããããŸããã ããããå°ãåŸã®ãã©ãŒã©ã ã«ã€ããŠããããŠæåŠã«ã€ããŠã®ã¹ã¿ãŒãã®ããã«ã
æè²æåŠã§ã¯ããã¹ãŠãç°¡åã§ã-ã»ãšãã©ãããŸããïŒ APIããã¥ã¡ã³ãèªäœã«ã¯ããããžã§ã¯ãã®äœææ¹æ³ã«ã€ããŠã®ç°¡åãªèª¬æïŒæ¬¡ã®ç« ã§è©³ãã説æããŸãïŒãããã€ãã®çãã¡ã¢ãããã³ããã€ãã®äŸããããŸãã
ãthe nanoPath to nanoCADããšããæ¬ããããŸãããéåžžã«éã蟌ããããŠãããããã§ããç§ã¯ãããè³Œå ¥ããŸããïŒãšããã§ãå ¬åŒãŠã§ããµã€ããããå®ãèŠã€ããŸããïŒã æ¬èªäœã¯åªããŠããã1æ¥ãã¹ã¯ããŒã«ããŠãNanocad 8.Xã§ã§ããããšïŒã§ããªãããšïŒãšãAutoCADã䜿çšããŠã©ã®ããã«ãã°ãã転éã§ããããç¥ãããšãã§ããŸãã æ¬ã«ã¯ãNanocadã®åºæ¬çãªããã°ã©ãã³ã°æŠå¿µããŸãšãã第13ç« ããããŸãã ããããããã»ã©å€ãã®æ å ±ã¯ãªããããããå€ãã®ãmakeãäœãããšã¯ã§ããŸãããå®éãããã¯SDKã®å©ãã®èŠçŽ+ããã€ãã®è¯ãããªãã¯ãšèª¬æã§ãã
ä»ã«äœããããŸããïŒ Habréã®äŒç€Ÿã®ããã°ã«ã¯èšäºããããŸãããç§ã®æèŠã§ã¯ããã䟿å©ãªã®ã¯APIã«ããããã°ã®è±èªçã®åãèšäºã§ãïŒéçºã«é¢ä¿ã®ãªãèšäºãšæ··åããŸããïŒã èšäºã¯åªããŠããŸãããççŽã«èšã£ãŠå°æ°ã§ããã£ãã«åºãŠããŸãããåé ã§è¿°ã¹ãããã«ãæåŸã®èšäºã¯ã»ãŒ2幎åã«å ¬éãããŸããã
Nanocadã®ã³ãã¥ããã£ã¯å°ãããããæ®ã£ãŠããã®ã¯éçºè åãã®ãã©ãŒã©ã ã ãã§ãã äžæ¹ã§ã¯ããã©ãŒã©ã ã掻æ°ã«æºã¡ã掻æ°ã«æºã¡ãç掻ãããŠãããšèšãããšã¯æããã«äžå¯èœã§ãã äžæ¹ãæ¥äžã¯äŒç€Ÿã®å°é家ãéåžžã®è³ªåã«çããããšããŠããã®ã§ãæè¬ããŠããŸãã ãããããç°åžžãªãïŒæããªïŒè³ªåã§ã¯ãäºæ ã¯ããã«æªåãããããã«çãã人ã¯ããŸããïŒãããã£ãŠãç§ã¯æã ããã§èªåãšã³ãã¥ãã±ãŒã·ã§ã³ãåããŸãïŒã
äž»ãªåé¡ã¯ããã©ãŒã©ã ã«ç±å¿ãªäººãã»ãšãã©ããªãããšã ãšæããŸãã ãããä¿®æ£ããããã«ãç§ã¯ä»å·çäžã§ãããããªãã¯ãã®èšäºãèªãã§ããŸãã
ãã1ã€ã®éèŠãªãã€ã³ãã¯ãã©ã€ã»ã³ã¹ã§ãã
ãŸããéçºã¯ã©ãã«å ¥äŒãããšãåææžã«çœ²åããŸãïŒãåæããããã¿ã³ãæŒããšããæå³ã§ïŒãããã¯ãéãæ³åŸçšèªã§ãå¯èœã§ãããäžå¯èœã§ãããšèšããŸãã
ã¢ããªã±ãŒã·ã§ã³ïŒã©ã€ãã©ãªïŒã®æš©å©ã«é¢ãããã®å¥çŽã®è§£éã®è³ªåã¯ã ç§ãå«ãããŸããŸãªäººã ã«ãã£ãŠéçºè ã«å°ããããŸãã ã åçã®æå³ã¯æ¬¡ã®ãšããã§ããNanosoftã¯ãNanocadéçºããŒã«ã«åºã¥ãããã¹ããã©ã¯ãã£ã¹ã®ç¡æ䜿çšãšé åžãå¶éããŸããã
ããã«ãã¯ã©ãã«å ¥äŒããå¿ èŠããªãããšãç¥ãããã«ãããã°ã©ã ã®ãã¹ãŠã®ããŒãžã§ã³ïŒå°ãªããšãããŒãžã§ã³5以éïŒã®ã©ã€ã»ã³ã¹å¥çŽãèªãã§ãã ããã ãããã£ãŠãããšãã°ãç¡æããŒãžã§ã³5.1ã®SDKã¯é åžãããå ã§äœ¿çšã§ããŸãïŒå°ãªããšã以åã¯ããã§ããïŒãã€ãŸããååãšããŠã¯ã©ãã®ããã«èŠããåå ããå¿ èŠã¯ãããŸããããAPIã®ææ°ããŒãžã§ã³ã䜿çšããå ŽåïŒããã³NC5ã§ã¯.1ããã¯kutseeã§ãïŒãããããããªãã¯ãŸã å ¥åããå¿ èŠããããŸãã
ããããååãªããšãèšããšãäœã圹ã«ç«ã€ããšãããæãæ¥ãã®ã§ãèšäºå šäœãæ§æ³ãããéšåã«ç§»ããŸãããã
4.éçºç°å¢ãã»ããã¢ããããç°¡åãªã³ãã³ããäœæããŸã
å§ããåã«ãMultiCAD .NET APIãéžæããã®ã¯ããã®ãã¯ãã¹ãã©ãããã©ãŒã æ§ãã ãã§ãªãã ã«ã¹ã¿ã ããªããã£ããäœæããæ©èœãéžæããããšã§ãïŒãã ãããã®äŸã§ã¯äœæããŸããïŒã
ãã®ãããå·ŠåŽã®é¡ãæãããŒã ãäœæãã次ã«å³åŽã®åè«ãç¬ç«ããŠæç»ããŸãã Nanocad 8.1ã«çŠç¹ãåœãŠãŸãããã³ãŒãã¯åçŽã§ããã8.Xãã¡ããªã®ã©ã®ããŒãžã§ã³ã§ãåäœãããšæããŸãã
MS Visual Studioã§ã³ãŒããäœæããŠåéããŸãã ããŠãã©ã®ããŒãžã§ã³ãéžæããã®ã§ããïŒ ããã¯ãã¹ãŠç§ãã¡ã®ç®æšã«äŸåããŸãã ãããã£ãŠãNC 8ã®SDKã®äžéšã§ããäŸã¯ãMS Visual Studio 2012ã§ã³ã³ãã€ã«ãããŸãããããããæ°ããããŒãžã§ã³ã§éãããšãããšããœãªã¥ãŒã·ã§ã³æŽæ°ãŠã£ã¶ãŒãã衚瀺ãããå ŽåããããŸãã
æ®å¿µãªãããSDKããããã±ãŒãžå šäœãåéããããã§ã¯ãªãããããããžã§ã¯ãã®æ°ããããŒãžã§ã³ãããããããšã§ããã©ãŒãã³ã¹ã«åœ±é¿ããããã©ããã¯ããããŸããã ããããç¡æã®VS Express Desktop 2012ãããŠã³ããŒããããšãSDKã®ãããžã§ã¯ãã¯èªãããååãšããŠèœã¡çããŠçµã¿ç«ãŠãããšãã§ãããšç¢ºä¿¡ã§ããŸãã
ãšããã§ã ãã€ã¯ããœããã®Webãµã€ããã VS Express Desktop 2012ãããŠã³ããŒããããå Žåãæåãããšããäºå®ã§ã¯ãããŸãããç§ã®å ŽåãMSã¯æããã«ç§ãã¯ã¬ã€ãžãŒã ãšæã£ãŠãããããŠã³ããŒããç¶ç¶çã«è©Šã¿ãŠç§ããããã¯ããŸããã幞ããªããšã«ãã®ããŒãžã§ã³ã¯ãããã¯ãŒã¯ã§ãèŠã€ãããŸãç¹°ãè¿ããŸãããç»é²ãµãŒãã¹ã¯åæ¢ããããã§ãããã®ãããã³ãŒããæ€çŽ¢ããå¿ èŠããããŸãã
ãããã«ãããããããäœæãããµã³ãã«ã¯ãåŸã®ããŒãžã§ã³ã®Visual Studioã§åéã§ããŸãã ããšãã°ãVS 2015 Communityãšãã£ã·ã§ã³ã䜿çšããŸããã2013幎ãš2017幎ã«ãè¡ãã¹ãã ãšæããŸãã
æåã«è¡ãããšã¯ããããžã§ã¯ããäœæããããšã§ãïŒãã®æ å ±ã¯SDKã«ããããŸãïŒã
泚æã.NET Framework 4.0ãéžæããŠãã ããããã®ããŒãžã§ã³ã¯ãNC8ã®APIã§äœ¿çšãããŸãïŒNC 5.1ã®å Žåãããšãã°.NET Framework 3.5ïŒã 次ã«ãå¿ èŠãªãã®ãéžæã§ããã¯ã©ã¹ã©ã€ãã©ãªã®ååãéžæããŸãã
次ã«ãå³ã®ããã«ãMultiCAD .NET APIïŒmapimgd.dllããã³mapibasetypes.dllïŒããã©ã€ãã©ãªãæ¥ç¶ããå¿ èŠããããŸãã
ããããã£ã®ããŒã«ã«ã³ããŒãªãã·ã§ã³ãå¿ ãåé€ããŠãã ããã
Nanocadã§ã¢ã»ã³ããªãããã«éãããã«ãããã¬ãæ§æããŸãã æåã«ããããžã§ã¯ãã®ããããã£ã§ãnCad.exeïŒå³ã®ããã«ïŒãèµ·åããã¢ããªã±ãŒã·ã§ã³ãšããŠæå®ããŸãã
ã©ã€ãã©ãªãã¹ã¿ãŒãã¢ããã®ãªã¹ãã«å«ããŸãïŒãã®ãããæ¯ånetloadã³ãã³ããåŒã³åºããªãããã«ããŸãïŒã ãããè¡ãã«ã¯ïŒNC 8.1ã®å ŽåïŒãã¢ãã¬ã¹CïŒ\ ProgramData \ Nanosoft \ nanoCAD x64 Plus 8.1 \ DataRWã«ç§»åãã次ã®å 容ã®load.configãã¡ã€ã«ãèŠã€ãããäœæããŸãã
<root> <list> <module path="C:\Users\...\bin\Debug\nanoforhabr1.dll"/> </list> </root>
3ã€ã®ãããã®ä»£ããã«ããããžã§ã¯ããã©ã«ããŒãžã®å®å šãªã¢ãã¬ã¹ã¯åœç¶ã§ãã å°æ¥çã«1ã€ã®ã¬ã³ãŒãã«éå®ããå¿ èŠã¯ãããŸããããŸã ç¬èªã®ã©ã€ãã©ãªãããå Žåã¯ãå¥ã®1ã»ã¯ã·ã§ã³ãè¿œå ããããšãã§ããŸãã
ããã§ãF5ããŒãæŒããšããããžã§ã¯ããããã«Nanocadã«ã¢ããããŒããããæ®ãã¯ãã¹ãŠãäœæããããŒã ãå ¥åããã ãã§ãã
ãã€ãã®ããã«ããããæçã«è§£æãã GitHubã§å šæãå ¥æã§ããŸã ïŒaã* Csãã¡ã€ã«ã¯ãã®ã¢ãã¬ã¹ã§å©çšå¯èœã§ããå¿ èŠã«å¿ããŠãããžã§ã¯ããèªåã§äœæããŠãã ããïŒ
ããã§ã¯ããŸãæåã«ãå¿ èŠãªåå空éãæžããŸãããã
using System; using System.Collections.Generic; using Multicad.AplicationServices; using Multicad.Runtime; using Multicad.DatabaseServices; using Multicad.Geometry; using Multicad.DatabaseServices.StandardObjects; using System.Windows.Forms;
次ã«ãããŒã ãäœæããŸãã
namespace nanoforhabr1 { public class startfor81 { [CommandMethod("Dface", CommandFlags.NoCheck | CommandFlags.NoPrefix )] public void DrawFace() {
å±æ§[CommandMethodïŒ "Dface"ãCommandFlags.NoCheck | CommandFlags.NoPrefixïŒ]
NCã³ãã³ãã©ã€ã³ã«å ¥åããã³ãã³ãã®ååãå®çŸ©ãïŒãã®å Žåã¯DfaceïŒããã®åŸãã©ã°ã移åããŸãããã©ã°ã®æå³ã«ã€ããŠã¯ãŸã 説æã§ããŸããã ããããããã«ããããžãã¹ããžãã¯ããå®è£ ããã¯ã©ã¹ã®ååãä»»æã®ã¯ã©ã¹åã衚瀺ãããŸã-ããªãã®è£éã§ãpublic void DrawFaceïŒïŒ
次ã®ã»ã¯ã·ã§ã³ã§ã¯ãé¡ã®å·Šååãæç»ããŸãã
//We draw half of face // Draw eye DbCircle eye = new DbCircle(); eye.Radius = 100; eye.Center = new Point3d(200, 500,0); eye.DbEntity.AddToCurrentDocument(); //Draw nose DbLine nose = new DbLine(); nose.StartPoint= new Point3d(350, 400, 0); nose.EndPoint = new Point3d(350, 200, 0); nose.DbEntity.AddToCurrentDocument(); //Draw mouth DbPolyline mouth = new DbPolyline(); List<Point3d> mouthPoints = new List<Point3d>() { new Point3d(100, 150, 0), new Point3d(200, 100, 0), new Point3d(350, 100, 0) }; mouth.Polyline= new Polyline3d(mouthPoints); mouth.Polyline.SetClosed(false); mouth.DbEntity.Transform(McDocumentsManager.GetActiveDoc().UCS); //change coordinates from UCS to WCS for BD mouth.DbEntity.AddToCurrentDocument();
ããã§ã¯ãæ£ããç解ããŸãããã MultiCAD .NET APIã«ã¯ããžãªã¡ããªãªããžã§ã¯ããå®çŸ©ããŠå³é¢ã«è¡šç€ºããããã®ã¯ã©ã¹ããããç®ãäœæããŸããDbCircle eye = new DbCircleïŒïŒ; -åãªããžã§ã¯ããäœæãïŒã³ãã³ãã©ã€ã³ã®CIRCLEã³ãã³ããŸãã¯ããŒã«ããŒã®åãã¯ãªãã¯ããïŒãåã®ååŸãšäžå¿ã®åº§æšã調æŽããŸãã eye.DbEntity.AddToCurrentDocumentïŒïŒ; -å³é¢ã«ãªããžã§ã¯ããè¿œå ããŸãã
ç°¡åãªç·ã§ãç§ã¯ãã¹ãŠããšãŠãæ確ã ãšæããŸãïŒããã¯ç§ãã¡ã®éŒ»ã«ãªããŸãïŒã
次ã«å£ãåŒããŸãã ããªã©ã€ã³ãå®çŸ©ããDbPolyline mouth = new DbPolylineïŒïŒ; æ§ç¯ããããã€ã³ãïŒæç·ãšçŽç·ïŒãäœæããŸãã
List<Point3d> mouthPoints = new List<Point3d>() { new Point3d(100, 150, 0), new Point3d(200, 100, 0), new Point3d(350, 100, 0) };
mouth.Polyline = new Polyline3dïŒmouthPointsïŒ; -ãã€ã³ãã§ããŒã¿ããŒã¹ãªããžã§ã¯ãã«ãžãªã¡ããªãäœæããŸãã
mouth.Polyline.SetClosedïŒfalseïŒ; è¡ãéããå Žåã¯ãå€ãå€æŽããŸãã
mouth.DbEntity.Transform(McDocumentsManager.GetActiveDoc().UCS); //change coordinates from UCS to WCS for BD
-éçºè ãã©ãŒã©ã ã§ãã®è¡ãåããŸããããŠãŒã¶ãŒåº§æšç³»ãäžçã«æ£ç¢ºã«å€æŽããå¿ èŠããããã©ããã¯ããããŸãã=ïŒ
é¡ã®2çªç®ã®éšåãæç»ããŸã
//draw mirror half the face (2nd half) DbCircle eye2 = new DbCircle(); eye2.Radius = 100; eye2.Center = new Point3d(500, 500, 0); eye2.DbEntity.AddToCurrentDocument(); DbPolyline mouth2 = new DbPolyline(); mouth2.Polyline= mouth.Polyline.Mirror(new Plane3d(new Point3d(350, 100, 0), new Vector3d(200, 0, 0))) as Polyline3d; mouth2.DbEntity.AddToCurrentDocument();
ã¢ãããžãŒã«ãã£ãŠç¬¬2ã®ç®ãäœæããã ãã§ãã ããããå€æ§æ§ã®ããã«å£ã®åŸåã¯åæ ãããŸãã å®éããã©ãŒã³ãã³ãïŒãã©ãŒïŒã®é¡äŒŒç©ãäœæããŠããŸã
mouth2.Polyline= mouth.Polyline.Mirror(new Plane3d(new Point3d(350, 100, 0), new Vector3d(200, 0, 0))) as Polyline3d;
ãã®ã³ãã³ãã¯ãããŒã¹ãã€ã³ããšãã¬ãŒã³ããåå°ãããã©ã€ã³ã®æ°ãããã©ãŒã³ããŒãäœæããŸãïŒããŠã¹ãç»é¢ã«çªã£èŸŒãã§ããªããžã§ã¯ããåå°ãããã©ã€ã³ãæããããã«ãªããŸãïŒã
ããã€ãã®ã€ã³ã¿ã©ã¯ãã£ãæ©èœãè¿œå ããŸãã
//Get notification in command line McContext.ShowNotification("You need to enter data into the console"); //Get uaser input InputJig editorInput = new InputJig(); string name = editorInput.GetText("Input your name and press Enter");
æåã®ã»ã¯ã·ã§ã³ã¯ãããã¹ããã³ã³ãœãŒã«ïŒã³ãã³ããå ¥åãããŠã£ã³ããŠïŒã«éä¿¡ããã ãã§ãã 2çªç®ã®ã»ã¯ã·ã§ã³ã¯ãã³ã³ãœãŒã«ã«ããŒã¿ãå ¥åããããã®ãªããžã§ã¯ããäœæãããŠãŒã¶ãŒãå ¥åããå€ãåãåããŸãã ãã®å ŽåããŠãŒã¶ãŒã«èªå·±çŽ¹ä»ãšååã®ä¿åããé¡ãããŸãã
ããã¹ããªããžã§ã¯ããäœæããŸããããã¯ãããŒã ã®ãŠãŒã¢ã¢ã®ã»ãã®äžéšã§ãã
//Drawing face's text DbText spech = new DbText(); spech.Text = new TextGeom("Oh Master! Why I'm so ugly? Please remove me!", new Point3d(510, 15, 0), Vector3d.XAxis, "Standard", 15); spech.DbEntity.AddToCurrentDocument();
äœæãããã¬ã³ãŒãã«ãŠãŒã¶ãŒã®æ³šæãåŒããšåæã«ãããšãã°windows.formsã«å žåçãªãã¶ã€ã³ãã¢ããªã±ãŒã·ã§ã³ã«çµã¿èŸŒãããšãã§ããããšã瀺ããŸããã€ãŸããç¬èªã®ãã©ãŒã ãåŒã³åºããŠããŒã¿ãåŠçããããšãã§ããŸãã 以åã«ååŸãããŠãŒã¶ãŒåã衚瀺ããã ãã§ãã
//Get windows message box MessageBox.Show("Congratulation " + name +" you did it! But look, it want, to say something to you...");
ç§ãã¡ã®é¡ã¯ãã®ååšã«äžæºãããããã§ããåé€ããŸãããã
æåŸã®ã»ã¯ã·ã§ã³ã§ã¯ã2ã€ã®ããšãè¡ããŸãããåé€ãã³ãã³ããèªåçã«ãªã³ã«ãªã£ãããšã瀺ãããŒã«ãããããŠãŒã¶ãŒã«è¡šç€ºããããŒã ããå¥ã®ã³ãã³ããå®è¡ããŸãã
//Get popup help McContext.PopupNotification("Delete command has activated"); //Activate another command (Delete) McContext.ExecuteCommand("Delete"); } } }
F5ãæŒããŸãããã¹ãŠãæ£åžžã§ããã°ãåäœäžã®ããŒã ã確èªã§ããŸããã¹ã¯ãªãŒã³ã·ã§ããã®ããã«ããŒã åãå ¥åããããšãå¿ããªãã§ãã ããã
ãŸãããããã°æ å ±ãååããã«ã¯ãç¹å¥ãªç£èŠãŠãŒãã£ãªãã£ã䜿çšã§ããŸã ã
çªç¶éçºã¯ã©ãã«åå ããããªãããå®éã«äœæ¥ã®çµæã確èªãããå Žåã¯ãNC 8.5ãã¢ããŒãžã§ã³ãããŠã³ããŒãã§ããŸããSDKããã³ãã«ãããŠããªãããã§ãããåæºããããšã¯ãããŸããããã¡ãããmapimgd.dllããã³mapibasetypes.dllã©ã€ãã©ãªã¯ããã°ã©ã èªäœã®é ä¿¡ããã±ãŒãžã«å«ãŸããŠããããããããã¯binãã©ã«ããŒã«ãããŸãã
æ³åŸã®èŠ³ç¹ãããããå¯èœãã©ããã¯ããããŸããããåé¡ã¯ãªãã¯ãã§ãã
ããã§ãç§ã¯ããªããšç§ãçŸæç¹ã§ç¥ã£ãŠããã»ãšãã©ãã¹ãŠãå ±æããŸãããããã¯çµè«ãåºãããšã ãã«æ®ã£ãŠããŸãã
5.ããã¯æ®å¿µã§ãïŒçµè«ïŒ
ããŠãViktor Koklyushkinã¯äœãšèšã£ãã®ã§ããïŒãããã¯æ®å¿µã§ãã ææãªãããžã§ã¯ã-éåžžã«åãå ¥ããããå質ã®è£œåã¯ãå±éã§ãããããå±éããŸããã§ããã ããã¯ãã¡ããå¥åŠãªããšã§ããäœããã®æ¿åºã®æ¯æŽçããã£ãããã§ããç¡æçã§ã¯ãã¢ãã¿ãŒã«ã¬ã³ã¬ãæããããšãã欲æ±ãªãã«ãå®éã«ã·ã³ãã«ãªãã®ãæãããšãã§ããŸãããããã§ã補åã®åšãã«äœæãããç°å¢ã¯ãããããæªãã§ãã Nanocadã®éçºã«åå ãã人ãå¢ãããšãããã ã®æ¥œãã¿ãã ãã§ãªããNanosoftããã®éèŠãæãããã©ãŒã©ã ãå埩ããAPIã®ããã¥ã¡ã³ãåãå§ãŸãããã¡ã€ã«ãããé »ç¹ã«ã¬ã€ã¢ãŠããããããã«ãªããšæããŸãã ååãšããŠãç¡æçãæŽæ°ãããã®ãåŸ ã€ããšãçã«ããªã£ãŠããå Žåã¯ãå°æ¥çã«ãããªãå¯èœæ§ããããŸãã
ãããŸã§ã®éãNanocadã®éçºè ãšããã«ããŠã¹ãããã®ãžã§ãŒã¯ã«ããããããããã®èšäºãæåŸãŸã§ãã¹ã¿ãŒãããã¹ãŠã®äººã«æè¬ãšå¹žéãç¥ããŸãã
ããªãã®ä»äºã®é±ã«è¯ãã¹ã¿ãŒããåããŸãããïŒ