Question-and-Answer Resource for the Building Energy Modeling Community
Get started with the Help page
Ask Your Question
2

How to generate the shade via Open Studio SDK? [closed]

asked 2015-11-19 02:19:17 -0600

zhengangzhu's avatar

updated 2018-05-19 12:43:54 -0600

I use following code trying to generate the shade

Point3dVector points = new Point3dVector();

points.Add(new Point3d(0,1,0));
points.Add(new Point3d(1,1,0));
points.Add(new Point3d(1,0,0));
points.Add(new Point3d(0,0,0));

ShadingSurface shadingSurface = new ShadingSurface(points, model);

but no vertexes set from the generated idf

Shading:Building:Detailed,

  RightFin-{e996d645-5c20-47cf-8df8-faa8b9745cba}, !- Name

  ,                                       !- Transmittance Schedule Name
  ;

Anything else needs to be set to successfully generate the shade?

edit retag flag offensive reopen merge delete

Closed for the following reason the question is answered, right answer was accepted by zhengangzhu
close date 2015-11-24 02:19:11.632116

Comments

@zhengangzhu please retag with the software, computer language, and existing tags. Thanks!

MatthewSteen's avatar MatthewSteen  ( 2015-11-19 07:29:21 -0600 )edit

1 Answer

Sort by ยป oldest newest most voted
4

answered 2015-11-19 09:00:22 -0600

With Ruby, the constructors would go something like:

points = OpenStudio::Point3dVector.new
points << OpenStudio::Point3d.new(0,1,0)
points << OpenStudio::Point3d.new(1,1,0)
points << OpenStudio::Point3d.new(1,0,0)
points << OpenStudio::Point3d.new(0,0,0)
shadingSurface = OpenStudio::Model::ShadingSurface.new(points, model)
edit flag offensive delete link more

Comments

It's the same with C#. Could you generate the shade in IDF using this code?

zhengangzhu's avatar zhengangzhu  ( 2015-11-19 18:45:10 -0600 )edit
1

If you look in the OSM file, does the shading surface exist? If the issue is that it is not being translated to IDF the issue may be that the shading surface is not a member of a shading surface group. Shading surfaces have to be in a shading surface group just like building surfaces have to be in a space.

macumber's avatar macumber  ( 2015-11-20 11:47:27 -0600 )edit

Yes. With the shading surface group added the shading can be generated in IDF. Thanks.

zhengangzhu's avatar zhengangzhu  ( 2015-11-24 02:18:03 -0600 )edit

Training Workshops

Careers

Question Tools

Stats

Asked: 2015-11-19 02:19:17 -0600

Seen: 186 times

Last updated: Nov 19 '15