use strict; use VRML; my $vrml = new VRML(2); $vrml->Group->Shape( sub{$vrml->IndexedFaceSet( sub{$vrml->Coordinate('0 0 0', '0 0 1', '0 1 0', '0 1 1', '1 0 0', '1 0 1', '1 1 0', '1 1 1', )->insert('solid FALSE')}, ['0 1 3 2', '0 1 5 4', '0 4 6 2', '4 5 7 6', '2 3 7 6', '1 3 7 5'] )}, sub{$vrml->Appearance( sub{$vrml->Material( ambientIntensity => .5, diffuseColor => '1 0 0', emissiveColor => '.25 0 0' )} )} )->back; $vrml->print; $vrml->save; exec 'vrmlview /home/phil/usr/vrml_test.wrl'; #Substitute your own viewer and path info here.