²é¿´: 3272  |  »Ø¸´: 3

sixulianyi

гæ (³õÈëÎÄ̳)

[ÇóÖú] ÀûÓÃLeditµÄCÓïÑԵĺê³ÌÐò»­ÓàÏÒSÍäÇúÏߣ¬ÄܺÍÈí¼þÁ¬½Óµ«ÊÇ»­²»³öͼ£¡£¡´úÂëÒѸ½ÉÏ ÒÑÓÐ1È˲ÎÓë

ÏëÔÚL-editÀïÃæ»­ÓàÏÒSÍäÇúÏߣ¬¹ÊдÁËÒ»¸öCÓïÑԵĺê³ÌÐò£¬ÔÚLeditÀïÃæÔËÐÐÁË£¬ÄÜÓëÈí¼þÁ¬½Ó£¬ÄÜÏÔʾ¹â±ê×ø±êλÖÃÒÔ¼°µ¯³ö²ÎÊýµÄ¶Ô»°¿ò£¬µ«ÊÇ»­²»³öÇúÏßͼ¡£´úÂëÈçÏÂÃæËùʾ¡£Óï¾äÉϰ´ÕÕÈí¼þµÄ˵Ã÷ÒÔ¼°×Ô´øµÄÀý×Ó¿´ÁËÒ»±éûÓдíÎó£¬ÊµÔÚÕÒ²»³öʲôԭÒò¡££¬ÇóÎÊȺÀïµÄ´óÉñÄÄÀï³ö´íÁË£¡£¡£¡
#include <stdlib.h>
#include <math.h>
#include <ldata.h>

void  SMacro ( void )
{
        /********************************************************************/
        /* ÓàÏÒSÍä */
        /********************************************************************/
        double       Height, Length,  Width, Deltax;
        long           P, Points_Total;
        double       PI = 3.141592654;
        LPoint        Points [ 1002 ];
        LObject      Polygon;
        LCell        Cell_Draw   = LCell_GetVisible( );
        LFile        File_Draw   = LCell_GetFile ( Cell_Draw );
        LPoint       pt = LCursor_GetPosition ( );
        LDialog_MsgBox( LFormat( "( %lf, %lf )", pt.x, pt.y) );
        LDialogItem  Dialog_Items [ 3 ] = { { "Height ", "50.0" },
        {"Length  ",  "1500"},
        { "Width  ", "5.0" } };
        /********************************************************************/

        if(LLayer_Find (File_Draw, "Poly" == NULL)
        {
                LDialog_AlertBox("There is no Poly layer.\nMake sure Poly is in the layer map!";
                return;
        }

        if( LDialog_MultiLineInputBox ( "S Properties", Dialog_Items, 3 ) )
        {
               Height   = atof ( Dialog_Items [ 0 ].value );
                Length   = atof ( Dialog_Items [ 1 ].value );
                Width    = atof ( Dialog_Items [ 3 ].value );
                return 1;
        }
        else
                return 0£»

    Deltax       = 3.0;

        for ( P = 0; P <= Points_Total; P++ )
        {       
            Points [ P ].x = pt.x +Deltax*P;
        Points [ P ].y = pt.y + Height/2*(1-cos(PI*( Deltax*P )/Length));
                Points [ 1002 - P ].x = Points [ P ].x ;
                Points [ 1002 - P ].y = Points [ P ].y +Width ;
        }

        Polygon = LPolygon_New ( Cell_Draw, LLayer_Find ( File_Draw, "Poly" ),
                                                Points, 1002 );

        LCell_SetView ( Cell_Draw, LCell_GetMbb ( Cell_Draw ) );
        LCell_MakeVisible ( Cell_Draw );
        LCell_HomeView ( Cell_Draw );
}

int  UPI_Entry_Point( void )
{
        LMacro_Register("S", "SMacro";
        return 1;
}
»Ø¸´´ËÂ¥

» ²ÂÄãϲ»¶

ÒÑÔÄ   »Ø¸´´ËÂ¥   ¹Ø×¢TA ¸øTA·¢ÏûÏ¢ ËÍTAºì»¨ TAµÄ»ØÌû

sixulianyi

гæ (³õÈëÎÄ̳)

³ÌÐòÊǸ´ÖÆÕ³ÌùÉÏÈ¥µÄ£¬ÊÇûÓбíÇéµÄ£¬ÄǼ¸¸ö±íÇé²»ÖªµÀÔõô»ØÊ£¬ÇëºöÂÔ
2Â¥2016-06-21 16:06:49
ÒÑÔÄ   »Ø¸´´ËÂ¥   ¹Ø×¢TA ¸øTA·¢ÏûÏ¢ ËÍTAºì»¨ TAµÄ»ØÌû

yuguofang

гæ (³õÈëÎÄ̳)

¡¾´ð°¸¡¿Ó¦Öú»ØÌû

ÎÒÊÔÁËһϣ¬¸Ä³ÉÕâÑù×ӾͿÉÒÔÁË
if( !LDialog_MultiLineInputBox ( "S Properties", Dialog_Items, 2 ) )
                 return ;
        //{
  Height   = atof ( Dialog_Items [ 0 ].value );
  Length   = atof ( Dialog_Items [ 1 ].value );
  Width      = atof ( Dialog_Items [ 2].value );
             //   return;
       // }
       // else
            //    return 0;
3Â¥2021-05-18 18:12:26
ÒÑÔÄ   »Ø¸´´ËÂ¥   ¹Ø×¢TA ¸øTA·¢ÏûÏ¢ ËÍTAºì»¨ TAµÄ»ØÌû

ÃΤιú¶È

¾èÖú¹ó±ö (ÎÄѧ̩¶·)

¹Ø×¢¸ßÈË
4Â¥2021-05-21 16:54:08
ÒÑÔÄ   »Ø¸´´ËÂ¥   ¹Ø×¢TA ¸øTA·¢ÏûÏ¢ ËÍTAºì»¨ TAµÄ»ØÌû
Ïà¹Ø°æ¿éÌø×ª ÎÒÒª¶©ÔÄÂ¥Ö÷ sixulianyi µÄÖ÷Ìâ¸üÐÂ
×î¾ßÈËÆøÈÈÌûÍÆ¼ö [²é¿´È«²¿] ×÷Õß »Ø/¿´ ×îºó·¢±í
[»ù½ðÉêÇë] Ϊʲô×ÊÖúÊý¸÷´ó¸ßУ¶¼´´Ð¸ߣ¬×Ô¼ºÉêÇëÔõô¾ÍÕâôÄÑ +8 Kittylucky 2026-08-27 8/400 2026-08-27 18:33 by raiy123
[½Ìʦ֮¼Ò] µ¼Ê¦Í²ۣºÎÒÔõô̯ÉÏÁËÕâô¸ö¼«Æ·Ñо¿Éú£¡ +7 ËÕ¶«ÆÂ¶þÊÀ 2026-08-23 7/350 2026-08-27 18:14 by ˲ϢÓîÖæ
[»ù½ðÉêÇë] Çà»ùÈçºÎÆÆ¾Ö +6 lyz123lyz 2026-08-27 7/350 2026-08-27 17:31 by Äþ¾²ÖÂÔ¶sy
[»ù½ðÉêÇë] ¹ú×ÔÈ»ÃæÉϸ´ÅÌ~»¶Ó­ÌÖÂÛ (½ð±Ò+5) +10 ÇçÌì¼ÓÓÍ 2026-08-26 11/550 2026-08-27 16:35 by msuhlx
[ÎÄѧ·¼²ÝÔ°] ÃÎÏë +3 myrtle 2026-08-26 3/150 2026-08-27 10:01 by angelyueyi
[»ù½ðÉêÇë] Ϊʲô ¹ú¼Ê(µØÇø)ºÏ×÷Óë½»Á÷ÏîÄ¿ ûÓзŰñ£¿ 10+3 majunge000 2026-08-26 11/550 2026-08-27 08:42 by ±±¾©À³Òð±à¼­
[˶²©¼ÒÔ°] ÊÛSCIÒ»ÇøT0PÎÄÕ£¬ÎÒ:8.O.55.1.O.54,¿ÆÄ¿ÆëÈ«,¿É+¼± +3 LIbGuocjEEYw 2026-08-26 4/200 2026-08-27 02:01 by Ie9AyIAvGbvs
[»ù½ðÉêÇë] 2026ÄêµÄ¹ú¼ÒÉç¿Æ»ù½ðÏîĿͨѶÆÀÉóµÄйæÔòÓëж¯Ïò¡¢ÐÂÌôÕ½ +7 process2012 2026-08-23 10/500 2026-08-26 19:23 by hmhminy
[»ù½ðÉêÇë] Ôõô²é°¡ +5 huang1991js 2026-08-26 5/250 2026-08-26 16:09 by Equinoxhua
[»ù½ðÉêÇë] ³öÀ´ÁË +9 trojank 2026-08-26 9/450 2026-08-26 14:25 by ±¦±´³æ×Ó
[»ù½ðÉêÇë] Ϊʲô¹ú×ÔÈ»²»ÄÜÖ±½Ó¹«²¼ +4 bjdxyxy 2026-08-26 4/200 2026-08-26 13:12 by qingmu1201
[»ù½ðÉêÇë] ¹ú¼ÊºÏ×÷¿É²éÁË£¬ÖÐÁËÃæÉÏ (EPI+1)(½ð±Ò+50) +18 Ldrop2023 2026-08-26 18/900 2026-08-26 11:15 by cmrandy
[»ù½ðÉêÇë] ϵͳ½ø²»È¥ +4 yanglien 2026-08-26 5/250 2026-08-26 11:10 by wenfengw83
[»ù½ðÉêÇë] ½ñÌìÎñί»á¿ªÍêÁË£¬Ã÷Ìì³ö½á¹ûÂð +19 angus9576 2026-08-25 23/1150 2026-08-26 10:03 by zp519
[Ö°³¡ÈËÉú] ѧÉúײ¼û¸¨µ¼Ô±ËÍÍâÂô£¬µÚ¶þÌìÈ«°à¶¼³ÁĬÁË +3 ¾¨ÓãÈÚ½ð_Õã½­_É 2026-08-22 3/150 2026-08-26 09:01 by zzuzxg
[»ù½ðÉêÇë] ÔÚ¼á±ù»¹¸Ç×ű±º£µÄʱºò£¬ÎÒ¿´µ½ÁËÅ­·ÅµÄ÷»¨¡£ (½ð±Ò+10) +6 ziyangfang 2026-08-25 9/450 2026-08-25 20:26 by huagongfeihu
[»ù½ðÉêÇë] ijЩ»ú¹¹£¬ÒÔЧÂʵÍΪÈÙ£¬ÒÔЧÂʵÍ×÷Ϊ´æÔڸР+9 yuleib84 2026-08-25 10/500 2026-08-25 17:14 by alexon
[»ù½ðÉêÇë] ÎÒÃæÉÏÍêµ°ÁË +13 ÇÒÌý»¢Ð¥ 2026-08-20 14/700 2026-08-25 09:10 by mrkang
[»ù½ðÉêÇë] ½¨Òé»ù½ð·¢²¼Ìáǰ¸ø³öÃ÷È·µÄʱ¼äµã +13 kulium 2026-08-21 16/800 2026-08-24 16:27 by superceng
[»ù½ðÉêÇë] Ó¦¸ÃÊÇÏÂÖÜÈý26ÈÕ¹«²¼Á˰ɣ¿ +4 ¹þ¹þ¸ò£¿ 2026-08-21 4/200 2026-08-21 10:58 by Vivilian
ÐÅÏ¢Ìáʾ
ÇëÌî´¦ÀíÒâ¼û