Rectangular perforations

Hello group!

I once found a cal file from Georg Mischler for circular perforations.
Now I wondered how to create rectangular perforations in a similar way.
Who has an idea (Georg?).

Iebele

···

-------------------------------------------------------------------------------

{
        perforate.cal
        Perforation function for approximately horizontal sufaces,
        for use in a mixfunc. Foreground is solid, background the holes.
        Set background to empty for a true perforation, or to a
different
        material for polka dots.

        Relative hole size is determined by A1.
    Size of single circle is 1 - scale as required (eg. 0.05m).

        x_hole cuts holes in x-direction (through the y-z plane)
        y_hole cuts holes in y-direction (through the x-z plane)
        z_hole cuts holes in z-direction (through the x-y plane)

    Georg Mischler 30. 04. 1993
}

`xn = mod(Px, 1) - 0.5;
`yn = mod(Py, 1) - 0.5;
`zn = mod(Pz, 1) - 0.5;

`outofcirc(x, y, r) = if(sqrt(x*x + y*y) - r, 1, 0);

z_hole = `outofcirc(`xn, `yn, A1);
x_hole = `outofcirc(`yn, `zn, A1);
y_hole = `outofcirc(`zn, `xn, A1);

Hello group,

Here I am again....
Nobody responded on my email, but a friend found the answer.
For those who are interested, here is the .cal file for rectangular perforations.

Iebele

{
        perforate.cal
        Perforation function for approximately horizontal sufaces,
        for use in a mixfunc. Foreground is solid, background the holes.
        Set background to empty for a true perforation, or to a different
        material for polka dots.

        Relative hole size is determined by A1.
        Size of single circle is 1 - scale as required (eg. 0.05m).

        x_hole cuts holes in x-direction (through the y-z plane)
        y_hole cuts holes in y-direction (through the x-z plane)
        z_hole cuts holes in z-direction (through the x-y plane)

       A1 is de schaal
       A2 XY size of hole ( 0.2 is small, 0.5 big )
       A3 YZ size of hole
       A4 XZ size of hole

        Abel Boerema 2004, n.a.v.Georg Mischler 30. 04. 1993
}

`xn = mod(Px, 1) - A2;
`yn = mod(Py, 1) - A3;
`zn = mod(Pz, 1) - A4;

`outofcirc(x, y, r) = if( (if ( x-r, 0, 1 )) * (if (y-r, 0, 1)) , 0, 1 );

z_hole = `outofcirc(`xn, `yn, A1);
x_hole = `outofcirc(`yn, `zn, A1);
y_hole = `outofcirc(`zn, `xn, A1);

···

----

"toren.com architectuur visualisaties" wrote:

Hello group!

I once found a cal file from Georg Mischler for circular perforations.
Now I wondered how to create rectangular perforations in a similar way.
Who has an idea (Georg?).

Iebele

-------------------------------------------------------------------------------

{
        perforate.cal
        Perforation function for approximately horizontal sufaces,
        for use in a mixfunc. Foreground is solid, background the holes.
        Set background to empty for a true perforation, or to a
different
        material for polka dots.

        Relative hole size is determined by A1.
    Size of single circle is 1 - scale as required (eg. 0.05m).

        x_hole cuts holes in x-direction (through the y-z plane)
        y_hole cuts holes in y-direction (through the x-z plane)
        z_hole cuts holes in z-direction (through the x-y plane)

    Georg Mischler 30. 04. 1993
}

`xn = mod(Px, 1) - 0.5;
`yn = mod(Py, 1) - 0.5;
`zn = mod(Pz, 1) - 0.5;

`outofcirc(x, y, r) = if(sqrt(x*x + y*y) - r, 1, 0);

z_hole = `outofcirc(`xn, `yn, A1);
x_hole = `outofcirc(`yn, `zn, A1);
y_hole = `outofcirc(`zn, `xn, A1);
_______________________________________________
Radiance-general mailing list
[email protected]
http://www.radiance-online.org/mailman/listinfo/radiance-general