[vtkusers] isosurface of iron protein
sophia_t14
sophia_t14 at yahoo.com
Mon Nov 22 07:48:58 EST 2010
http://vtk.1045678.n5.nabble.com/file/n3275295/iron_protein.jpg
So sorry... The code are as follow....
vtkRenderer aRenderer
vtkRenderWindow renWin
renWin AddRenderer aRenderer
vtkRenderWindowInteractor iren
iren SetRenderWindow renWin
vtkStructuredPointsReader reader
reader SetFileName "$VTK_DATA_ROOT/Data/ironProt.vtk"
vtkContourFilter ironExtractor
ironExtractor SetInput [reader GetOutput]
ironExtractor SetValue 0 128
vtkPolyDataNormals ironNormals
ironNormals SetInput [ironExtractor GetOutput]
ironNormals SetFeatureAngle 45
vtkPolyDataMapper ironMapper
ironMapper SetInput [ironNormals GetOutput]
ironMapper ScalarVisibilityOff
vtkActor iron
iron SetMapper ironMapper
[iron GetProperty] SetDiffuseColor .68 .08 .12
vtkOutlineFilter outlineData
outlineData SetInput [reader GetOutput]
vtkPolyDataMapper mapOutline
mapOutline SetInput [outlineData GetOutput]
vtkActor outline
outline SetMapper mapOutline
[outline GetProperty] SetColor 0 0 0
vtkCamera aCamera
aCamera SetViewUp 0 0 -1
aCamera SetPosition 0.25 0.75 0.25
aCamera SetFocalPoint 0 0 0
aCamera ComputeViewPlaneNormal
aRenderer AddActor outline
aRenderer AddActor iron
aRenderer SetActiveCamera aCamera
aRenderer ResetCamera
aCamera Dolly 1.5
aRenderer SetBackground 1 1 1
renWin SetSize 640 480
aRenderer ResetCameraClippingRange
iren AddObserver UserEvent {wm deiconify .vtkInteract}
iren Initialize
wm withdraw .
--
View this message in context: http://vtk.1045678.n5.nabble.com/isosurface-of-iron-protein-tp3275278p3275295.html
Sent from the VTK - Users mailing list archive at Nabble.com.
More information about the vtkusers
mailing list