Heilan X3D Browser

GhostImage

Type

ParentNode

Description

A node which renders all it's children twice: first to a texture, and then to the screen, with the texture overlaid, scaled and alpha blended according to the scale parameter. Note that the drawing of any visual nodes before this one in the X3D file heirarchy will be erased when GhostImage does its drawing.

Attributes

scale SFFloat (input) The scale and amount of alpha blending applied to the ghost texture (0 == no alpha, no scaling, 1 = full alpha, 4*scaling).

trigger SFFloat (input) Used to trigger a refresh of the ghost texture. Triggering happens when the value goes past 0.5. Once triggered, the scale parameter is interpolated from 0 to the current user-set scale value.

Example Use

<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE X3D>
<X3D profile="Full">
	<Scene>
		<NavigationInfo type="ANY"/>

		<GhostImage DEF="bob">
			<Transform translation="-1 0 -8">
				<Shape>
					<Appearance>
						<Material diffuseColor="1 0 0"/>
					</Appearance>
					<Box/>
				</Shape>
			</Transform>

			<Transform translation="2 0 -10">
				<Shape>
					<Appearance>
						<Material diffuseColor="0 0 1"/>
					</Appearance>
					<Box/>
				</Shape>
			</Transform>
		</GhostImage>
	</Scene>
</X3D>