honeybee-radiance 1.66.190__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of honeybee-radiance might be problematic. Click here for more details.
- honeybee_radiance/__init__.py +11 -0
- honeybee_radiance/__main__.py +4 -0
- honeybee_radiance/_extend_honeybee.py +93 -0
- honeybee_radiance/cli/__init__.py +88 -0
- honeybee_radiance/cli/dc.py +400 -0
- honeybee_radiance/cli/edit.py +529 -0
- honeybee_radiance/cli/glare.py +118 -0
- honeybee_radiance/cli/grid.py +859 -0
- honeybee_radiance/cli/lib.py +458 -0
- honeybee_radiance/cli/modifier.py +133 -0
- honeybee_radiance/cli/mtx.py +226 -0
- honeybee_radiance/cli/multiphase.py +1034 -0
- honeybee_radiance/cli/octree.py +640 -0
- honeybee_radiance/cli/postprocess.py +1186 -0
- honeybee_radiance/cli/raytrace.py +219 -0
- honeybee_radiance/cli/rpict.py +125 -0
- honeybee_radiance/cli/schedule.py +56 -0
- honeybee_radiance/cli/setconfig.py +63 -0
- honeybee_radiance/cli/sky.py +545 -0
- honeybee_radiance/cli/study.py +66 -0
- honeybee_radiance/cli/sunpath.py +331 -0
- honeybee_radiance/cli/threephase.py +255 -0
- honeybee_radiance/cli/translate.py +400 -0
- honeybee_radiance/cli/util.py +121 -0
- honeybee_radiance/cli/view.py +261 -0
- honeybee_radiance/cli/viewfactor.py +347 -0
- honeybee_radiance/config.json +6 -0
- honeybee_radiance/config.py +427 -0
- honeybee_radiance/dictutil.py +50 -0
- honeybee_radiance/dynamic/__init__.py +5 -0
- honeybee_radiance/dynamic/group.py +479 -0
- honeybee_radiance/dynamic/multiphase.py +557 -0
- honeybee_radiance/dynamic/state.py +718 -0
- honeybee_radiance/dynamic/stategeo.py +352 -0
- honeybee_radiance/geometry/__init__.py +13 -0
- honeybee_radiance/geometry/bubble.py +42 -0
- honeybee_radiance/geometry/cone.py +215 -0
- honeybee_radiance/geometry/cup.py +54 -0
- honeybee_radiance/geometry/cylinder.py +197 -0
- honeybee_radiance/geometry/geometrybase.py +37 -0
- honeybee_radiance/geometry/instance.py +40 -0
- honeybee_radiance/geometry/mesh.py +38 -0
- honeybee_radiance/geometry/polygon.py +174 -0
- honeybee_radiance/geometry/ring.py +214 -0
- honeybee_radiance/geometry/source.py +182 -0
- honeybee_radiance/geometry/sphere.py +178 -0
- honeybee_radiance/geometry/tube.py +46 -0
- honeybee_radiance/lib/__init__.py +1 -0
- honeybee_radiance/lib/_loadmodifiers.py +72 -0
- honeybee_radiance/lib/_loadmodifiersets.py +69 -0
- honeybee_radiance/lib/modifiers.py +58 -0
- honeybee_radiance/lib/modifiersets.py +63 -0
- honeybee_radiance/lightpath.py +204 -0
- honeybee_radiance/lightsource/__init__.py +1 -0
- honeybee_radiance/lightsource/_gendaylit.py +479 -0
- honeybee_radiance/lightsource/dictutil.py +49 -0
- honeybee_radiance/lightsource/ground.py +160 -0
- honeybee_radiance/lightsource/sky/__init__.py +7 -0
- honeybee_radiance/lightsource/sky/_skybase.py +177 -0
- honeybee_radiance/lightsource/sky/certainirradiance.py +232 -0
- honeybee_radiance/lightsource/sky/cie.py +378 -0
- honeybee_radiance/lightsource/sky/climatebased.py +501 -0
- honeybee_radiance/lightsource/sky/hemisphere.py +160 -0
- honeybee_radiance/lightsource/sky/skydome.py +113 -0
- honeybee_radiance/lightsource/sky/skymatrix.py +163 -0
- honeybee_radiance/lightsource/sky/strutil.py +34 -0
- honeybee_radiance/lightsource/sky/sunmatrix.py +212 -0
- honeybee_radiance/lightsource/sunpath.py +247 -0
- honeybee_radiance/modifier/__init__.py +3 -0
- honeybee_radiance/modifier/material/__init__.py +30 -0
- honeybee_radiance/modifier/material/absdf.py +477 -0
- honeybee_radiance/modifier/material/antimatter.py +54 -0
- honeybee_radiance/modifier/material/ashik2.py +51 -0
- honeybee_radiance/modifier/material/brtdfunc.py +81 -0
- honeybee_radiance/modifier/material/bsdf.py +292 -0
- honeybee_radiance/modifier/material/dielectric.py +53 -0
- honeybee_radiance/modifier/material/glass.py +431 -0
- honeybee_radiance/modifier/material/glow.py +246 -0
- honeybee_radiance/modifier/material/illum.py +51 -0
- honeybee_radiance/modifier/material/interface.py +49 -0
- honeybee_radiance/modifier/material/light.py +206 -0
- honeybee_radiance/modifier/material/materialbase.py +36 -0
- honeybee_radiance/modifier/material/metal.py +167 -0
- honeybee_radiance/modifier/material/metal2.py +41 -0
- honeybee_radiance/modifier/material/metdata.py +41 -0
- honeybee_radiance/modifier/material/metfunc.py +41 -0
- honeybee_radiance/modifier/material/mirror.py +340 -0
- honeybee_radiance/modifier/material/mist.py +86 -0
- honeybee_radiance/modifier/material/plasdata.py +58 -0
- honeybee_radiance/modifier/material/plasfunc.py +59 -0
- honeybee_radiance/modifier/material/plastic.py +354 -0
- honeybee_radiance/modifier/material/plastic2.py +58 -0
- honeybee_radiance/modifier/material/prism1.py +57 -0
- honeybee_radiance/modifier/material/prism2.py +48 -0
- honeybee_radiance/modifier/material/spotlight.py +50 -0
- honeybee_radiance/modifier/material/trans.py +518 -0
- honeybee_radiance/modifier/material/trans2.py +49 -0
- honeybee_radiance/modifier/material/transdata.py +50 -0
- honeybee_radiance/modifier/material/transfunc.py +53 -0
- honeybee_radiance/modifier/mixture/__init__.py +6 -0
- honeybee_radiance/modifier/mixture/mixdata.py +49 -0
- honeybee_radiance/modifier/mixture/mixfunc.py +54 -0
- honeybee_radiance/modifier/mixture/mixpict.py +52 -0
- honeybee_radiance/modifier/mixture/mixtext.py +66 -0
- honeybee_radiance/modifier/mixture/mixturebase.py +28 -0
- honeybee_radiance/modifier/modifierbase.py +40 -0
- honeybee_radiance/modifier/pattern/__init__.py +9 -0
- honeybee_radiance/modifier/pattern/brightdata.py +49 -0
- honeybee_radiance/modifier/pattern/brightfunc.py +47 -0
- honeybee_radiance/modifier/pattern/brighttext.py +81 -0
- honeybee_radiance/modifier/pattern/colordata.py +56 -0
- honeybee_radiance/modifier/pattern/colorfunc.py +47 -0
- honeybee_radiance/modifier/pattern/colorpict.py +54 -0
- honeybee_radiance/modifier/pattern/colortext.py +73 -0
- honeybee_radiance/modifier/pattern/patternbase.py +34 -0
- honeybee_radiance/modifier/texture/__init__.py +4 -0
- honeybee_radiance/modifier/texture/texdata.py +29 -0
- honeybee_radiance/modifier/texture/texfunc.py +26 -0
- honeybee_radiance/modifier/texture/texturebase.py +27 -0
- honeybee_radiance/modifierset.py +1091 -0
- honeybee_radiance/mutil.py +60 -0
- honeybee_radiance/postprocess/__init__.py +1 -0
- honeybee_radiance/postprocess/annual.py +108 -0
- honeybee_radiance/postprocess/annualdaylight.py +425 -0
- honeybee_radiance/postprocess/annualglare.py +201 -0
- honeybee_radiance/postprocess/annualirradiance.py +187 -0
- honeybee_radiance/postprocess/electriclight.py +119 -0
- honeybee_radiance/postprocess/en17037.py +261 -0
- honeybee_radiance/postprocess/leed.py +304 -0
- honeybee_radiance/postprocess/solartracking.py +90 -0
- honeybee_radiance/primitive.py +554 -0
- honeybee_radiance/properties/__init__.py +1 -0
- honeybee_radiance/properties/_base.py +390 -0
- honeybee_radiance/properties/aperture.py +197 -0
- honeybee_radiance/properties/door.py +198 -0
- honeybee_radiance/properties/face.py +123 -0
- honeybee_radiance/properties/model.py +1291 -0
- honeybee_radiance/properties/room.py +490 -0
- honeybee_radiance/properties/shade.py +186 -0
- honeybee_radiance/properties/shademesh.py +116 -0
- honeybee_radiance/putil.py +44 -0
- honeybee_radiance/reader.py +214 -0
- honeybee_radiance/sensor.py +166 -0
- honeybee_radiance/sensorgrid.py +1008 -0
- honeybee_radiance/view.py +1101 -0
- honeybee_radiance/writer.py +951 -0
- honeybee_radiance-1.66.190.dist-info/METADATA +89 -0
- honeybee_radiance-1.66.190.dist-info/RECORD +152 -0
- honeybee_radiance-1.66.190.dist-info/WHEEL +5 -0
- honeybee_radiance-1.66.190.dist-info/entry_points.txt +2 -0
- honeybee_radiance-1.66.190.dist-info/licenses/LICENSE +661 -0
- honeybee_radiance-1.66.190.dist-info/top_level.txt +1 -0
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
"""Radiance Mixdata Mixture.
|
|
2
|
+
|
|
3
|
+
http://radsite.lbl.gov/radiance/refer/ray.html#Mixdata
|
|
4
|
+
"""
|
|
5
|
+
from .mixturebase import Mixture
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
# TODO: Implement the class. It's currently only a generic Radiance Primitive
|
|
9
|
+
class Mixdata(Mixture):
|
|
10
|
+
"""Radiance Mixdata Material.
|
|
11
|
+
|
|
12
|
+
Mixdata combines two modifiers using an auxiliary data file:
|
|
13
|
+
|
|
14
|
+
.. code-block:: shell
|
|
15
|
+
|
|
16
|
+
mod mixdata id
|
|
17
|
+
5+n+
|
|
18
|
+
foreground background func datafile
|
|
19
|
+
funcfile x1 x2 .. xn transform
|
|
20
|
+
0
|
|
21
|
+
m A1 A2 .. Am
|
|
22
|
+
|
|
23
|
+
Args:
|
|
24
|
+
identifier: Text string for a unique Mixture ID. Must not contain spaces
|
|
25
|
+
or special characters. This will be used to identify the object across
|
|
26
|
+
a model and in the exported Radiance files.
|
|
27
|
+
modifier: Modifier. It can be primitive, mixture, texture or pattern.
|
|
28
|
+
(Default: None).
|
|
29
|
+
values: An array 3 arrays for primitive data. Each of the 3 sub-arrays
|
|
30
|
+
refer to a line number in the radiance primitive definitions and the
|
|
31
|
+
values in each array correspond to values occurring within each line.
|
|
32
|
+
is_opaque: A boolean to indicate whether this primitive is opaque.
|
|
33
|
+
dependencies: A list of primitives that this primitive depends on. This
|
|
34
|
+
argument is only useful for defining advanced primitives that are
|
|
35
|
+
defined based on other primitives. (Default: []).
|
|
36
|
+
|
|
37
|
+
Properties:
|
|
38
|
+
* identifier
|
|
39
|
+
* display_name
|
|
40
|
+
* values
|
|
41
|
+
* modifier
|
|
42
|
+
* dependencies
|
|
43
|
+
* is_modifier
|
|
44
|
+
* is_material
|
|
45
|
+
* is_opaque
|
|
46
|
+
"""
|
|
47
|
+
__slots__ = ()
|
|
48
|
+
|
|
49
|
+
pass
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
"""Radiance Mixfunc Mixture.
|
|
2
|
+
|
|
3
|
+
http://radsite.lbl.gov/radiance/refer/ray.html#Mixfunc
|
|
4
|
+
"""
|
|
5
|
+
from .mixturebase import Mixture
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
# TODO: Implement the class. It's currently only a generic Radiance Primitive
|
|
9
|
+
class Mixfunc(Mixture):
|
|
10
|
+
"""Radiance Mixfunc Material.
|
|
11
|
+
|
|
12
|
+
A mixfunc mixes two modifiers procedurally. It is specified as follows:
|
|
13
|
+
|
|
14
|
+
.. code-block:: shell
|
|
15
|
+
|
|
16
|
+
mod mixfunc id
|
|
17
|
+
4+ foreground background vname funcfile transform
|
|
18
|
+
0
|
|
19
|
+
n A1 A2 .. An
|
|
20
|
+
|
|
21
|
+
Foreground and background are modifier names that must be defined earlier in the
|
|
22
|
+
scene description. If one of these is a material, then the modifier of the mixfunc
|
|
23
|
+
must be "void". (Either the foreground or background modifier may be "void", which
|
|
24
|
+
serves as a form of opacity control when used with a material.) Vname is the
|
|
25
|
+
coefficient defined in funcfile that determines the influence of foreground. The
|
|
26
|
+
background coefficient is always (1-vname).
|
|
27
|
+
|
|
28
|
+
Args:
|
|
29
|
+
identifier: Text string for a unique Mixture ID. Must not contain spaces
|
|
30
|
+
or special characters. This will be used to identify the object across
|
|
31
|
+
a model and in the exported Radiance files.
|
|
32
|
+
modifier: Modifier. It can be primitive, mixture, texture or pattern.
|
|
33
|
+
(Default: None).
|
|
34
|
+
values: An array 3 arrays for primitive data. Each of the 3 sub-arrays
|
|
35
|
+
refer to a line number in the radiance primitive definitions and the
|
|
36
|
+
values in each array correspond to values occurring within each line.
|
|
37
|
+
is_opaque: A boolean to indicate whether this primitive is opaque.
|
|
38
|
+
dependencies: A list of primitives that this primitive depends on. This
|
|
39
|
+
argument is only useful for defining advanced primitives that are
|
|
40
|
+
defined based on other primitives. (Default: []).
|
|
41
|
+
|
|
42
|
+
Properties:
|
|
43
|
+
* identifier
|
|
44
|
+
* display_name
|
|
45
|
+
* values
|
|
46
|
+
* modifier
|
|
47
|
+
* dependencies
|
|
48
|
+
* is_modifier
|
|
49
|
+
* is_material
|
|
50
|
+
* is_opaque
|
|
51
|
+
"""
|
|
52
|
+
__slots__ = ()
|
|
53
|
+
|
|
54
|
+
pass
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
"""Radiance Mixpict Mixture.
|
|
2
|
+
|
|
3
|
+
http://radsite.lbl.gov/radiance/refer/ray.html#Mixpict
|
|
4
|
+
"""
|
|
5
|
+
from .mixturebase import Mixture
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
# TODO: Implement the class. It's currently only a generic Radiance Primitive
|
|
9
|
+
class Mixpict(Mixture):
|
|
10
|
+
"""Radiance Mixpict Material.
|
|
11
|
+
|
|
12
|
+
Mixpict combines two modifiers based on a picture:
|
|
13
|
+
|
|
14
|
+
.. code-block:: shell
|
|
15
|
+
|
|
16
|
+
mod mixpict id
|
|
17
|
+
7+
|
|
18
|
+
foreground background func pictfile
|
|
19
|
+
funcfile u v transform
|
|
20
|
+
0
|
|
21
|
+
m A1 A2 .. Am
|
|
22
|
+
|
|
23
|
+
The mixing coefficient function "func" takes three arguments, the red, green and
|
|
24
|
+
blue values corresponding to the pixel at (u,v).
|
|
25
|
+
|
|
26
|
+
Args:
|
|
27
|
+
identifier: Text string for a unique Mixture ID. Must not contain spaces
|
|
28
|
+
or special characters. This will be used to identify the object across
|
|
29
|
+
a model and in the exported Radiance files.
|
|
30
|
+
modifier: Modifier. It can be primitive, mixture, texture or pattern.
|
|
31
|
+
(Default: None).
|
|
32
|
+
values: An array 3 arrays for primitive data. Each of the 3 sub-arrays
|
|
33
|
+
refer to a line number in the radiance primitive definitions and the
|
|
34
|
+
values in each array correspond to values occurring within each line.
|
|
35
|
+
is_opaque: A boolean to indicate whether this primitive is opaque.
|
|
36
|
+
dependencies: A list of primitives that this primitive depends on. This
|
|
37
|
+
argument is only useful for defining advanced primitives that are
|
|
38
|
+
defined based on other primitives. (Default: []).
|
|
39
|
+
|
|
40
|
+
Properties:
|
|
41
|
+
* identifier
|
|
42
|
+
* display_name
|
|
43
|
+
* values
|
|
44
|
+
* modifier
|
|
45
|
+
* dependencies
|
|
46
|
+
* is_modifier
|
|
47
|
+
* is_material
|
|
48
|
+
* is_opaque
|
|
49
|
+
"""
|
|
50
|
+
__slots__ = ()
|
|
51
|
+
|
|
52
|
+
pass
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
"""Radiance Mixtext Mixture.
|
|
2
|
+
|
|
3
|
+
http://radsite.lbl.gov/radiance/refer/ray.html#Mixtext
|
|
4
|
+
"""
|
|
5
|
+
from .mixturebase import Mixture
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
# TODO: Implement the class. It's currently only a generic Radiance Primitive
|
|
9
|
+
class Mixtext(Mixture):
|
|
10
|
+
"""Radiance Mixtext Material.
|
|
11
|
+
|
|
12
|
+
Mixtext uses one modifier for the text foreground, and one for the background:
|
|
13
|
+
|
|
14
|
+
.. code-block:: shell
|
|
15
|
+
|
|
16
|
+
mod mixtext id
|
|
17
|
+
4 foreground background fontfile textfile
|
|
18
|
+
0
|
|
19
|
+
9+
|
|
20
|
+
Ox Oy Oz
|
|
21
|
+
Rx Ry Rz
|
|
22
|
+
Dx Dy Dz
|
|
23
|
+
[spacing]
|
|
24
|
+
|
|
25
|
+
or:
|
|
26
|
+
|
|
27
|
+
.. code-block:: shell
|
|
28
|
+
|
|
29
|
+
mod mixtext id
|
|
30
|
+
4+N
|
|
31
|
+
foreground background fontfile .
|
|
32
|
+
This is a line with N words ...
|
|
33
|
+
0
|
|
34
|
+
9+
|
|
35
|
+
Ox Oy Oz
|
|
36
|
+
Rx Ry Rz
|
|
37
|
+
Dx Dy Dz
|
|
38
|
+
[spacing]
|
|
39
|
+
|
|
40
|
+
Args:
|
|
41
|
+
identifier: Text string for a unique Mixture ID. Must not contain spaces
|
|
42
|
+
or special characters. This will be used to identify the object across
|
|
43
|
+
a model and in the exported Radiance files.
|
|
44
|
+
modifier: Modifier. It can be primitive, mixture, texture or pattern.
|
|
45
|
+
(Default: None).
|
|
46
|
+
values: An array 3 arrays for primitive data. Each of the 3 sub-arrays
|
|
47
|
+
refer to a line number in the radiance primitive definitions and the
|
|
48
|
+
values in each array correspond to values occurring within each line.
|
|
49
|
+
is_opaque: A boolean to indicate whether this primitive is opaque.
|
|
50
|
+
dependencies: A list of primitives that this primitive depends on. This
|
|
51
|
+
argument is only useful for defining advanced primitives that are
|
|
52
|
+
defined based on other primitives. (Default: []).
|
|
53
|
+
|
|
54
|
+
Properties:
|
|
55
|
+
* identifier
|
|
56
|
+
* display_name
|
|
57
|
+
* values
|
|
58
|
+
* modifier
|
|
59
|
+
* dependencies
|
|
60
|
+
* is_modifier
|
|
61
|
+
* is_material
|
|
62
|
+
* is_opaque
|
|
63
|
+
"""
|
|
64
|
+
__slots__ = ()
|
|
65
|
+
|
|
66
|
+
pass
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
"""Base Radiance Mixture class.
|
|
2
|
+
|
|
3
|
+
A mixture is a blend of one or more materials or textures and patterns. Blended
|
|
4
|
+
materials should not be light source types or virtual source types.
|
|
5
|
+
More information on Radiance Mixtures can be found at:
|
|
6
|
+
|
|
7
|
+
http://radsite.lbl.gov/radiance/refer/ray.html#Mixtures
|
|
8
|
+
"""
|
|
9
|
+
from ..modifierbase import Modifier
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
class Mixture(Modifier):
|
|
13
|
+
"""Base class for Radiance mixtures.
|
|
14
|
+
|
|
15
|
+
Properties:
|
|
16
|
+
* identifier
|
|
17
|
+
* display_name
|
|
18
|
+
* values
|
|
19
|
+
* modifier
|
|
20
|
+
* dependencies
|
|
21
|
+
* is_mixture
|
|
22
|
+
"""
|
|
23
|
+
__slots__ = ()
|
|
24
|
+
|
|
25
|
+
@property
|
|
26
|
+
def is_mixture(self):
|
|
27
|
+
"""Get a boolean noting whether this object is a mixture modifier."""
|
|
28
|
+
return True
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
"""Base Radiance Modifier class.
|
|
2
|
+
|
|
3
|
+
A modifier is anything that can be applied to geometry in order to modify its
|
|
4
|
+
reflectance, transmittance, etc. It includes Radiance materials as well as
|
|
5
|
+
patterns, textures and mixtures of other modifiers.
|
|
6
|
+
|
|
7
|
+
Modifiers can also be used to modify other modifiers in addition to modifying
|
|
8
|
+
geometry. More information on Radiance Modifiers can be found at:
|
|
9
|
+
|
|
10
|
+
https://floyd.lbl.gov/radiance/refer/ray.html
|
|
11
|
+
"""
|
|
12
|
+
from ..primitive import Primitive
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
class Modifier(Primitive):
|
|
16
|
+
"""Base class for Radiance modifiers.
|
|
17
|
+
|
|
18
|
+
Properties:
|
|
19
|
+
* identifier
|
|
20
|
+
* display_name
|
|
21
|
+
* values
|
|
22
|
+
* modifier
|
|
23
|
+
* dependencies
|
|
24
|
+
* is_modifier
|
|
25
|
+
* is_material
|
|
26
|
+
* is_texture
|
|
27
|
+
* is_pattern
|
|
28
|
+
* is_mixture
|
|
29
|
+
* is_opaque
|
|
30
|
+
"""
|
|
31
|
+
|
|
32
|
+
__slots__ = ()
|
|
33
|
+
|
|
34
|
+
@property
|
|
35
|
+
def is_modifier(self):
|
|
36
|
+
"""Get a boolean indicating whether this object is a Radiance modifier.
|
|
37
|
+
|
|
38
|
+
Modifiers include materials, mixtures, textures and patterns.
|
|
39
|
+
"""
|
|
40
|
+
return True
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
"""Radiance Patterns."""
|
|
2
|
+
|
|
3
|
+
from .brightdata import Brightdata
|
|
4
|
+
from .brightfunc import Brightfunc
|
|
5
|
+
from .brighttext import Brighttext
|
|
6
|
+
from .colordata import Colordata
|
|
7
|
+
from .colorfunc import Colorfunc
|
|
8
|
+
from .colorpict import Colorpict
|
|
9
|
+
from .colortext import Colortext
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
"""Radiance Brightdata Texture.
|
|
2
|
+
|
|
3
|
+
http://radsite.lbl.gov/radiance/refer/ray.html#Brightdata
|
|
4
|
+
"""
|
|
5
|
+
from .patternbase import Pattern
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
# TODO: Implement the class. It's currently only a generic Radiance Primitive
|
|
9
|
+
class Brightdata(Pattern):
|
|
10
|
+
"""Radiance Brightdata Material.
|
|
11
|
+
|
|
12
|
+
Brightdata is like colordata, except monochromatic.
|
|
13
|
+
|
|
14
|
+
.. code-block:: shell
|
|
15
|
+
|
|
16
|
+
mod brightdata id
|
|
17
|
+
3+n+
|
|
18
|
+
func datafile
|
|
19
|
+
funcfile x1 x2 .. xn transform
|
|
20
|
+
0
|
|
21
|
+
m A1 A2 .. Am
|
|
22
|
+
|
|
23
|
+
Args:
|
|
24
|
+
identifier: Text string for a unique Material ID. Must not contain spaces
|
|
25
|
+
or special characters. This will be used to identify the object across
|
|
26
|
+
a model and in the exported Radiance files.
|
|
27
|
+
modifier: Modifier. It can be primitive, mixture, texture or pattern.
|
|
28
|
+
(Default: None).
|
|
29
|
+
values: An array 3 arrays for primitive data. Each of the 3 sub-arrays
|
|
30
|
+
refer to a line number in the radiance primitive definitions and the
|
|
31
|
+
values in each array correspond to values occurring within each line.
|
|
32
|
+
is_opaque: A boolean to indicate whether this primitive is opaque.
|
|
33
|
+
dependencies: A list of primitives that this primitive depends on. This
|
|
34
|
+
argument is only useful for defining advanced primitives that are
|
|
35
|
+
defined based on other primitives. (Default: []).
|
|
36
|
+
|
|
37
|
+
Properties:
|
|
38
|
+
* identifier
|
|
39
|
+
* display_name
|
|
40
|
+
* values
|
|
41
|
+
* modifier
|
|
42
|
+
* dependencies
|
|
43
|
+
* is_modifier
|
|
44
|
+
* is_material
|
|
45
|
+
* is_opaque
|
|
46
|
+
"""
|
|
47
|
+
__slots__ = ()
|
|
48
|
+
|
|
49
|
+
pass
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
"""Radiance Brightfunc Pattern.
|
|
2
|
+
|
|
3
|
+
http://radsite.lbl.gov/radiance/refer/ray.html#Brightfunc
|
|
4
|
+
"""
|
|
5
|
+
from .patternbase import Pattern
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
# TODO: Implement the class. It's currently only a generic Radiance Primitive
|
|
9
|
+
class Brightfunc(Pattern):
|
|
10
|
+
"""Radiance Brightfunc Material.
|
|
11
|
+
|
|
12
|
+
A brightfunc is the same as a colorfunc, except it is monochromatic.
|
|
13
|
+
|
|
14
|
+
.. code-block:: shell
|
|
15
|
+
|
|
16
|
+
mod brightfunc id
|
|
17
|
+
2+ refl funcfile transform
|
|
18
|
+
0
|
|
19
|
+
n A1 A2 .. An
|
|
20
|
+
|
|
21
|
+
Args:
|
|
22
|
+
identifier: Text string for a unique Material ID. Must not contain spaces
|
|
23
|
+
or special characters. This will be used to identify the object across
|
|
24
|
+
a model and in the exported Radiance files.
|
|
25
|
+
modifier: Modifier. It can be primitive, mixture, texture or pattern.
|
|
26
|
+
(Default: None).
|
|
27
|
+
values: An array 3 arrays for primitive data. Each of the 3 sub-arrays
|
|
28
|
+
refer to a line number in the radiance primitive definitions and the
|
|
29
|
+
values in each array correspond to values occurring within each line.
|
|
30
|
+
is_opaque: A boolean to indicate whether this primitive is opaque.
|
|
31
|
+
dependencies: A list of primitives that this primitive depends on. This
|
|
32
|
+
argument is only useful for defining advanced primitives that are
|
|
33
|
+
defined based on other primitives. (Default: []).
|
|
34
|
+
|
|
35
|
+
Properties:
|
|
36
|
+
* identifier
|
|
37
|
+
* display_name
|
|
38
|
+
* values
|
|
39
|
+
* modifier
|
|
40
|
+
* dependencies
|
|
41
|
+
* is_modifier
|
|
42
|
+
* is_material
|
|
43
|
+
* is_opaque
|
|
44
|
+
"""
|
|
45
|
+
__slots__ = ()
|
|
46
|
+
|
|
47
|
+
pass
|
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
"""Radiance Brighttext Pattern.
|
|
2
|
+
|
|
3
|
+
http://radsite.lbl.gov/radiance/refer/ray.html#Brighttext
|
|
4
|
+
"""
|
|
5
|
+
from .patternbase import Pattern
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
# TODO: Implement the class. It's currently only a generic Radiance Primitive
|
|
9
|
+
class Brighttext(Pattern):
|
|
10
|
+
"""Radiance Brighttext Pattern.
|
|
11
|
+
|
|
12
|
+
Brighttext is like colortext, but the writing is monochromatic.
|
|
13
|
+
|
|
14
|
+
.. code-block:: shell
|
|
15
|
+
|
|
16
|
+
mod brighttext id
|
|
17
|
+
2 fontfile textfile
|
|
18
|
+
0
|
|
19
|
+
11+
|
|
20
|
+
Ox Oy Oz
|
|
21
|
+
Rx Ry Rz
|
|
22
|
+
Dx Dy Dz
|
|
23
|
+
foreground background
|
|
24
|
+
[spacing]
|
|
25
|
+
|
|
26
|
+
or:
|
|
27
|
+
|
|
28
|
+
.. code-block:: shell
|
|
29
|
+
|
|
30
|
+
mod brighttext id
|
|
31
|
+
2+N fontfile . This is a line with N words ...
|
|
32
|
+
0
|
|
33
|
+
11+
|
|
34
|
+
Ox Oy Oz
|
|
35
|
+
Rx Ry Rz
|
|
36
|
+
Dx Dy Dz
|
|
37
|
+
foreground background
|
|
38
|
+
[spacing]
|
|
39
|
+
|
|
40
|
+
By default, a uniform spacing algorithm is used that guarantees every character will
|
|
41
|
+
appear in a precisely determined position. Unfortunately, such a scheme results in
|
|
42
|
+
rather unattractive and difficult to read text with most fonts. The optional spacing
|
|
43
|
+
value defines the distance between characters for proportional spacing. A positive
|
|
44
|
+
value selects a spacing algorithm that preserves right margins and indentation, but
|
|
45
|
+
does not provide the ultimate in proportionally spaced text. A negative value insures
|
|
46
|
+
that characters are properly spaced, but the placement of words then varies
|
|
47
|
+
unpredictably. The choice depends on the relative importance of spacing versus
|
|
48
|
+
formatting. When presenting a section of formatted text, a positive spacing value is
|
|
49
|
+
usually preferred. A single line of text will often be accompanied by a negative
|
|
50
|
+
spacing value. A section of text meant to depict a picture, perhaps using a special
|
|
51
|
+
purpose font such as hexbit4x1.fnt, calls for uniform spacing. Reasonable magnitudes
|
|
52
|
+
for proportional spacing are between 0.1 (for tightly spaced characters) and 0.3 (for
|
|
53
|
+
wide spacing).
|
|
54
|
+
|
|
55
|
+
Args:
|
|
56
|
+
identifier: Text string for a unique Material ID. Must not contain spaces
|
|
57
|
+
or special characters. This will be used to identify the object across
|
|
58
|
+
a model and in the exported Radiance files.
|
|
59
|
+
modifier: Modifier. It can be primitive, mixture, texture or pattern.
|
|
60
|
+
(Default: None).
|
|
61
|
+
values: An array 3 arrays for primitive data. Each of the 3 sub-arrays
|
|
62
|
+
refer to a line number in the radiance primitive definitions and the
|
|
63
|
+
values in each array correspond to values occurring within each line.
|
|
64
|
+
is_opaque: A boolean to indicate whether this primitive is opaque.
|
|
65
|
+
dependencies: A list of primitives that this primitive depends on. This
|
|
66
|
+
argument is only useful for defining advanced primitives that are
|
|
67
|
+
defined based on other primitives. (Default: []).
|
|
68
|
+
|
|
69
|
+
Properties:
|
|
70
|
+
* identifier
|
|
71
|
+
* display_name
|
|
72
|
+
* values
|
|
73
|
+
* modifier
|
|
74
|
+
* dependencies
|
|
75
|
+
* is_modifier
|
|
76
|
+
* is_material
|
|
77
|
+
* is_opaque
|
|
78
|
+
"""
|
|
79
|
+
__slots__ = ()
|
|
80
|
+
|
|
81
|
+
pass
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
"""Radiance Colordata Pattern.
|
|
2
|
+
|
|
3
|
+
http://radsite.lbl.gov/radiance/refer/ray.html#Colordata
|
|
4
|
+
"""
|
|
5
|
+
from .patternbase import Pattern
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
# TODO: Implement the class. It's currently only a generic Radiance Primitive
|
|
9
|
+
class Colordata(Pattern):
|
|
10
|
+
"""Radiance Colordata Pattern.
|
|
11
|
+
|
|
12
|
+
Colordata uses an interpolated data map to modify a material's color. The map is
|
|
13
|
+
n-dimensional, and is stored in three auxiliary files, one for each color. The
|
|
14
|
+
coordinates used to look up and interpolate the data are defined in another auxiliary
|
|
15
|
+
file. The interpolated data values are modified by functions of one or three
|
|
16
|
+
variables. If the functions are of one variable, then they are passed the
|
|
17
|
+
corresponding color component (red or green or blue). If the functions are of three
|
|
18
|
+
variables, then they are passed the original red, green, and blue values as
|
|
19
|
+
parameters.
|
|
20
|
+
|
|
21
|
+
.. code-block:: shell
|
|
22
|
+
|
|
23
|
+
mod colordata id
|
|
24
|
+
7+n+
|
|
25
|
+
rfunc gfunc bfunc rdatafile gdatafile bdatafile
|
|
26
|
+
funcfile x1 x2 .. xn transform
|
|
27
|
+
0
|
|
28
|
+
m A1 A2 .. Am
|
|
29
|
+
|
|
30
|
+
Args:
|
|
31
|
+
identifier: Text string for a unique Material ID. Must not contain spaces
|
|
32
|
+
or special characters. This will be used to identify the object across
|
|
33
|
+
a model and in the exported Radiance files.
|
|
34
|
+
modifier: Modifier. It can be primitive, mixture, texture or pattern.
|
|
35
|
+
(Default: None).
|
|
36
|
+
values: An array 3 arrays for primitive data. Each of the 3 sub-arrays
|
|
37
|
+
refer to a line number in the radiance primitive definitions and the
|
|
38
|
+
values in each array correspond to values occurring within each line.
|
|
39
|
+
is_opaque: A boolean to indicate whether this primitive is opaque.
|
|
40
|
+
dependencies: A list of primitives that this primitive depends on. This
|
|
41
|
+
argument is only useful for defining advanced primitives that are
|
|
42
|
+
defined based on other primitives. (Default: []).
|
|
43
|
+
|
|
44
|
+
Properties:
|
|
45
|
+
* identifier
|
|
46
|
+
* display_name
|
|
47
|
+
* values
|
|
48
|
+
* modifier
|
|
49
|
+
* dependencies
|
|
50
|
+
* is_modifier
|
|
51
|
+
* is_material
|
|
52
|
+
* is_opaque
|
|
53
|
+
"""
|
|
54
|
+
__slots__ = ()
|
|
55
|
+
|
|
56
|
+
pass
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
"""Radiance Colorfunc Texture.
|
|
2
|
+
|
|
3
|
+
http://radsite.lbl.gov/radiance/refer/ray.html#Colorfunc
|
|
4
|
+
"""
|
|
5
|
+
from .patternbase import Pattern
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
# TODO: Implement the class. It's currently only a generic Radiance Primitive
|
|
9
|
+
class Colorfunc(Pattern):
|
|
10
|
+
"""Radiance Colorfunc Material.
|
|
11
|
+
|
|
12
|
+
A colorfunc is a procedurally defined color pattern. It is specified as follows:
|
|
13
|
+
|
|
14
|
+
.. code-block:: shell
|
|
15
|
+
|
|
16
|
+
mod colorfunc id
|
|
17
|
+
4+ red green blue funcfile transform
|
|
18
|
+
0
|
|
19
|
+
n A1 A2 .. An
|
|
20
|
+
|
|
21
|
+
Args:
|
|
22
|
+
identifier: Text string for a unique Material ID. Must not contain spaces
|
|
23
|
+
or special characters. This will be used to identify the object across
|
|
24
|
+
a model and in the exported Radiance files.
|
|
25
|
+
modifier: Modifier. It can be primitive, mixture, texture or pattern.
|
|
26
|
+
(Default: None).
|
|
27
|
+
values: An array 3 arrays for primitive data. Each of the 3 sub-arrays
|
|
28
|
+
refer to a line number in the radiance primitive definitions and the
|
|
29
|
+
values in each array correspond to values occurring within each line.
|
|
30
|
+
is_opaque: A boolean to indicate whether this primitive is opaque.
|
|
31
|
+
dependencies: A list of primitives that this primitive depends on. This
|
|
32
|
+
argument is only useful for defining advanced primitives that are
|
|
33
|
+
defined based on other primitives. (Default: []).
|
|
34
|
+
|
|
35
|
+
Properties:
|
|
36
|
+
* identifier
|
|
37
|
+
* display_name
|
|
38
|
+
* values
|
|
39
|
+
* modifier
|
|
40
|
+
* dependencies
|
|
41
|
+
* is_modifier
|
|
42
|
+
* is_material
|
|
43
|
+
* is_opaque
|
|
44
|
+
"""
|
|
45
|
+
__slots__ = ()
|
|
46
|
+
|
|
47
|
+
pass
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
"""Radiance Colorpict Pattern.
|
|
2
|
+
|
|
3
|
+
http://radsite.lbl.gov/radiance/refer/ray.html#Colorpict
|
|
4
|
+
"""
|
|
5
|
+
from .patternbase import Pattern
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
# TODO: Implement the class. It's currently only a generic Radiance Primitive
|
|
9
|
+
class Colorpict(Pattern):
|
|
10
|
+
"""Radiance Colorpict Pattern.
|
|
11
|
+
|
|
12
|
+
Colorpict is a special case of colordata, where the pattern is a two-dimensional
|
|
13
|
+
image stored in the RADIANCE picture format. The dimensions of the image data are
|
|
14
|
+
determined by the picture such that the smaller dimension is always 1, and the
|
|
15
|
+
other is the ratio between the larger and the smaller. For example, a 500x338
|
|
16
|
+
picture would have coordinates (u,v) in the rectangle between (0,0) and (1.48,1).
|
|
17
|
+
|
|
18
|
+
.. code-block:: shell
|
|
19
|
+
|
|
20
|
+
mod colorpict id
|
|
21
|
+
7+
|
|
22
|
+
rfunc gfunc bfunc pictfile
|
|
23
|
+
funcfile u v transform
|
|
24
|
+
0
|
|
25
|
+
m A1 A2 .. Am
|
|
26
|
+
|
|
27
|
+
Args:
|
|
28
|
+
identifier: Text string for a unique Material ID. Must not contain spaces
|
|
29
|
+
or special characters. This will be used to identify the object across
|
|
30
|
+
a model and in the exported Radiance files.
|
|
31
|
+
modifier: Modifier. It can be primitive, mixture, texture or pattern.
|
|
32
|
+
(Default: None).
|
|
33
|
+
values: An array 3 arrays for primitive data. Each of the 3 sub-arrays
|
|
34
|
+
refer to a line number in the radiance primitive definitions and the
|
|
35
|
+
values in each array correspond to values occurring within each line.
|
|
36
|
+
is_opaque: A boolean to indicate whether this primitive is opaque.
|
|
37
|
+
dependencies: A list of primitives that this primitive depends on. This
|
|
38
|
+
argument is only useful for defining advanced primitives that are
|
|
39
|
+
defined based on other primitives. (Default: []).
|
|
40
|
+
|
|
41
|
+
Properties:
|
|
42
|
+
* identifier
|
|
43
|
+
* display_name
|
|
44
|
+
* values
|
|
45
|
+
* modifier
|
|
46
|
+
* dependencies
|
|
47
|
+
* is_modifier
|
|
48
|
+
* is_material
|
|
49
|
+
* is_opaque
|
|
50
|
+
|
|
51
|
+
"""
|
|
52
|
+
__slots__ = ()
|
|
53
|
+
|
|
54
|
+
pass
|