Yep - after "projecting" the rubbersheet surface to z==0 it works,
a macro which maps z-positions of points to a surface is attached
(perhaps its useful for somebody).

Thanx for your help.

Richard.

On Thu, 8 Feb 2001, Chris Pelkie wrote:

> You need to work with the 2D mesh that precedes Rubbersheet (whereupon it
> becomes 3D). I think Nancy's solution is correct but start with this mesh
> rather than the Rubbersheet. (You could start there, but you'd need to
> squash the Rubbersheet positions by stripping off the Z component, but why
> bother?)
>
> The idea as you see is that both the mapper and the mappee have to have the
> same dimensionality of positions. If mapped data doesn't not fall onto or
> into the map surface or volumetric elements, those points will be invalid,
> so it behooves you to ensure that the mapped data actually hits the
> surface, thus, the projection is guaranteed to do that. Then follow Nancy's
> directions to re-expand everything back to the 3D representation.
>
> Chris Pelkie
> Vice President/Scientific Visualization Producer
> Conceptual Reality Presentations, Inc.
> 30 West Meadow Drive
> Ithaca, NY 14850
> [EMAIL PROTECTED]
>
>

--
Richard Guenther <[EMAIL PROTECTED]>
WWW: http://www.anatom.uni-tuebingen.de/~richi/
The GLAME Project: http://www.glame.de/
//
// time: Thu Feb  8 16:51:44 2001
//
// version: 3.1.2 (format), 4.1.0 (DX)
//
//
// Begin MDF
// MODULE MapPointsToSurface
// CATEGORY Macros
// DESCRIPTION Maps a set of points to z-coordinate of a given surface
// INPUT Points; field; (none); Points to be (z-) mapped to the surface
// INPUT Surface; field; (none); Surface the points are (z-) mapped to
// OUTPUT Mapped_Points; field; 
// End MDF
// page assignment: MapPoints   order=2, windowed=0, showing=1
// workspace: width = 483, height = 735
// layout: snap = 0, width = 50, height = 50, align = NN
//
macro MapPointsToSurface(
 Points
,Surface
) -> (
 Mapped_Points
) {
    // 
    // node Input[2]: x = 181, y = 21, inputs = 0, label = Surface
    // page group: MapPoints
    // parameter: position = 2, name = 'Surface', value = '(none)', descriptive 
= 1, description = 'Surface the points are (z-) mapped to', required = 1, 
visible = 1
    //
MapPointsToSurface_Input_2_out_1 = Surface;
    // 
    // node Mark[5]: x = 260, y = 95, inputs = 2, label = Mark
    // input[2]: defaulting = 0, visible = 1, type = 32, value = "positions"
    // page group: MapPoints
    //
MapPointsToSurface_Mark_5_out_1 = 
    Mark(
    MapPointsToSurface_Input_2_out_1,
    "positions"
    ) [instance: 5, cache: 1];
    // 
    // node Compute[7]: x = 317, y = 97, inputs = 3, label = Compute
    // input[1]: defaulting = 0, visible = 0, type = 32, value = "[$0.x, $0.y]"
    // page group: MapPoints
    // expression: value = [a.x, a.y]
    // name[2]: value = a
    // name[3]: value = b
    //
MapPointsToSurface_Compute_7_out_1 = 
    Compute(
    "[$0.x, $0.y]",
    MapPointsToSurface_Mark_5_out_1,
    NULL
    ) [instance: 7, cache: 1];
    // 
    // node Mark[6]: x = 258, y = 175, inputs = 2, label = Mark
    // input[2]: defaulting = 0, visible = 1, type = 32, value = "positions"
    // page group: MapPoints
    //
MapPointsToSurface_Mark_6_out_1 = 
    Mark(
    MapPointsToSurface_Input_2_out_1,
    "positions"
    ) [instance: 6, cache: 1];
    // 
    // node Compute[8]: x = 314, y = 175, inputs = 3, label = Compute
    // input[1]: defaulting = 0, visible = 0, type = 32, value = "$0.z"
    // page group: MapPoints
    // expression: value = a.z
    // name[2]: value = a
    // name[3]: value = b
    //
MapPointsToSurface_Compute_8_out_1 = 
    Compute(
    "$0.z",
    MapPointsToSurface_Mark_6_out_1,
    NULL
    ) [instance: 8, cache: 1];
    // 
    // node Input[1]: x = 65, y = 20, inputs = 0, label = Points
    // page group: MapPoints
    // parameter: position = 1, name = 'Points', value = '(none)', descriptive 
= 1, description = 'Points to be (z-) mapped to the surface', required = 1, 
visible = 1
    //
MapPointsToSurface_Input_1_out_1 = Points;
    // 
    // node Mark[7]: x = 74, y = 119, inputs = 2, label = Mark
    // input[2]: defaulting = 0, visible = 1, type = 32, value = "positions"
    // page group: MapPoints
    //
MapPointsToSurface_Mark_7_out_1 = 
    Mark(
    MapPointsToSurface_Input_1_out_1,
    "positions"
    ) [instance: 7, cache: 1];
    // 
    // node Compute[9]: x = 66, y = 189, inputs = 3, label = Compute
    // input[1]: defaulting = 0, visible = 0, type = 32, value = "[$0.x, $0.y]"
    // page group: MapPoints
    // expression: value = [a.x, a.y]
    // name[2]: value = a
    // name[3]: value = b
    //
MapPointsToSurface_Compute_9_out_1 = 
    Compute(
    "[$0.x, $0.y]",
    MapPointsToSurface_Mark_7_out_1,
    NULL
    ) [instance: 9, cache: 1];
    // 
    // node Unmark[4]: x = 74, y = 260, inputs = 2, label = Unmark
    // page group: MapPoints
    //
MapPointsToSurface_Unmark_4_out_1 = 
    Unmark(
    MapPointsToSurface_Compute_9_out_1,
    NULL
    ) [instance: 4, cache: 1];
    // 
    // node Unmark[5]: x = 393, y = 97, inputs = 2, label = Unmark
    // page group: MapPoints
    //
MapPointsToSurface_Unmark_5_out_1 = 
    Unmark(
    MapPointsToSurface_Compute_7_out_1,
    NULL
    ) [instance: 5, cache: 1];
    // 
    // node Replace[4]: x = 387, y = 259, inputs = 4, label = Replace
    // page group: MapPoints
    //
MapPointsToSurface_Replace_4_out_1 = 
    Replace(
    MapPointsToSurface_Compute_8_out_1,
    MapPointsToSurface_Unmark_5_out_1,
    NULL,
    NULL
    ) [instance: 4, cache: 1];
    // 
    // node Map[2]: x = 255, y = 346, inputs = 4, label = Map
    // page group: MapPoints
    //
MapPointsToSurface_Map_2_out_1 = 
    Map(
    MapPointsToSurface_Unmark_4_out_1,
    MapPointsToSurface_Replace_4_out_1,
    NULL,
    NULL
    ) [instance: 2, cache: 1];
    // 
    // node Mark[8]: x = 267, y = 424, inputs = 2, label = Mark
    // input[2]: defaulting = 0, visible = 1, type = 32, value = "positions"
    // page group: MapPoints
    //
MapPointsToSurface_Mark_8_out_1 = 
    Mark(
    MapPointsToSurface_Map_2_out_1,
    "positions"
    ) [instance: 8, cache: 1];
    // 
    // node Compute[10]: x = 333, y = 424, inputs = 3, label = Compute
    // input[1]: defaulting = 0, visible = 0, type = 32, value = "[$0.x, $0.y, 
$1]"
    // page group: MapPoints
    // expression: value = [a.x, a.y, b]
    // name[2]: value = a
    // name[3]: value = b
    //
MapPointsToSurface_Compute_10_out_1 = 
    Compute(
    "[$0.x, $0.y, $1]",
    MapPointsToSurface_Mark_8_out_1,
    MapPointsToSurface_Map_2_out_1
    ) [instance: 10, cache: 1];
    // 
    // node Unmark[6]: x = 352, y = 502, inputs = 2, label = Unmark
    // page group: MapPoints
    //
MapPointsToSurface_Unmark_6_out_1 = 
    Unmark(
    MapPointsToSurface_Compute_10_out_1,
    NULL
    ) [instance: 6, cache: 1];
    // 
    // node Replace[5]: x = 165, y = 581, inputs = 4, label = Replace
    // page group: MapPoints
    //
MapPointsToSurface_Replace_5_out_1 = 
    Replace(
    MapPointsToSurface_Input_1_out_1,
    MapPointsToSurface_Unmark_6_out_1,
    NULL,
    NULL
    ) [instance: 5, cache: 1];
    // 
    // node Output[1]: x = 186, y = 673, inputs = 1, label = Points
    // page group: MapPoints
    // parameter: position = 1, name = 'Mapped_Points', value = '(NULL)', 
descriptive = 1, description = ' ', required = 0, visible = 1
    //
Mapped_Points = MapPointsToSurface_Replace_5_out_1;
// network: end of macro body
}
MapPointsToSurface_Input_2_out_1 = NULL;
MapPointsToSurface_Mark_5_out_1 = NULL;
MapPointsToSurface_Compute_7_out_1 = NULL;
MapPointsToSurface_Mark_6_out_1 = NULL;
MapPointsToSurface_Compute_8_out_1 = NULL;
MapPointsToSurface_Input_1_out_1 = NULL;
MapPointsToSurface_Mark_7_out_1 = NULL;
MapPointsToSurface_Compute_9_out_1 = NULL;
MapPointsToSurface_Unmark_4_out_1 = NULL;
MapPointsToSurface_Unmark_5_out_1 = NULL;
MapPointsToSurface_Replace_4_out_1 = NULL;
MapPointsToSurface_Map_2_out_1 = NULL;
MapPointsToSurface_Mark_8_out_1 = NULL;
MapPointsToSurface_Compute_10_out_1 = NULL;
MapPointsToSurface_Unmark_6_out_1 = NULL;
MapPointsToSurface_Replace_5_out_1 = NULL;

Reply via email to