TA的每日心情 | 奋斗 2025-2-18 09:05 |
---|
签到天数: 1197 天 [LV.10]以坛为家III
入门
- 积分
- 73
|
我试了一下,这个polyLine的设置,只能自己设置好,然后导入点数。这个程序只能自己先打开lighttools建一个sweepsolid,然后把curve type 设置为 polyline
具体程序如下:
%Create a handle for the assembly
asm = NET.addAssembly('C:\Program Files\Optical Research Associates\LightTools 2023.03\Utilities.NET\LTCOM64.dll')
%Create a handle for LTAPI functions. Assume the connection is made to the first running LightTools session.
lt=LTCOM64.LTAPIx;
%Update the LT pointer, no PID is specified here
lt.UpdateLTPointer
%Create a handle for JS functions
js=LTCOM64.JSNET2;
%Update the LT pointer. This call is necessary, at least once
js.UpdateLTPointer;
% SetSweptProfilePoints
pp=zeros(5,2);
for i=1:5
pp(i,1)=sqrt((i-1)*2);
pp(i,2)=i-1;
end
[retVal,stat]=lt.SetSweptProfilePoints('SOLID[1].SWEPT_PROFILE[1].POLYLINE_CURVE[1]',pp,5);
char(retVal)
|
|