init.py 1019 Bytes
Newer Older
1 2 3 4 5 6
importPlugin = schnapps.loadPlugin("ImportSurface");
renderPlugin = schnapps.loadPlugin("RenderD");
renderVectorPlugin = schnapps.loadPlugin("RenderVectorD");
differentialPropertiesPlugin = schnapps.loadPlugin("DifferentialProperties");
subdivisionPlugin = schnapps.loadPlugin("SubdivideSurface");
surfaceDeformationPlugin = schnapps.loadPlugin("SurfaceDeformation");
7
renderTopoSurface = schnapps.loadPlugin("RenderTopoSurface");
8

9
obj = importPlugin.importFromFile("/home/kraemer/Media/Data/surface/lowRes/iphi_good_9k.off");
10

11
v = schnapps.getView("view_0");
12

13 14 15
schnapps.linkViewAndPlugin(v.getName(), renderPlugin.getName());
schnapps.linkViewAndPlugin(v.getName(), renderVectorPlugin.getName());
schnapps.linkViewAndPlugin(v.getName(), surfaceDeformationPlugin.getName());
16
schnapps.linkViewAndPlugin(v.getName(), renderTopoSurface.getName());
17

18
schnapps.linkViewAndMap(v.getName(), obj.getName());
19

20 21
differentialPropertiesPlugin.computeNormal(obj.getName());
differentialPropertiesPlugin.computeCurvature(obj.getName());